Skip to content

Components Reference ​

The keys available under the components section, what each key accepts, and what it does are listed below. Fields under the components section are mapped directly to Minecraft entity attributes or data components by ComponentMapper. Key names must match the tables below exactly: keys with no handler are skipped silently (no error, no log line)

Shipped examples: the mobs/example_zombie.yml released on first start plus the bundled mobs/elite_zombie.yml and mobs/bone_lord.yml all use the fields below, so you can read the examples alongside them

"Required" is always "No" below — the whole components section may be omitted, and a key that is not written is never applied. "Default" is always "—", meaning the vanilla or existing entity state is kept. An accepted value of "—" means the source performs no validation (numbers are written as-is and out-of-range behaviour is decided by the vanilla attribute/entity API)

Spawn versus refresh semantics ​

  • Applied on spawn only: absorption, freeze_ticks, fire_ticks, potion_effect, and every equipment field (helmet, chestplate, leggings, boots, main_hand, off_hand, equipment). These are consumable states, so the refresh triggered by /emakimobs reload never resets them and never restores broken or removed gear
  • max_health is special: on spawn the ceiling is applied and health is filled to it; on refresh the current health is kept and clamped to the new ceiling (raising the ceiling does not heal, lowering it clamps health)
  • Every other component (attribute and appearance/behaviour fields) is written again on every refresh

Attribute fields ​

FieldTypeRequiredDefaultAccepted valuesDescription
max_healthdoubleNo——Maximum health (MAX_HEALTH attribute)
movement_speeddoubleNo——Movement speed (vanilla zombie ≈ 0.23, player 0.1)
attack_damagedoubleNo——Melee attack damage
attack_speeddoubleNo——Attack speed
attack_knockbackdoubleNo——Knockback strength applied on hit
follow_rangedoubleNo—— (blocks)Maximum target tracking distance
knockback_resistancedoubleNo—0.0–1.0 (vanilla attribute range)Knockback resistance; 1.0 is full immunity
armordoubleNo——Armor value
armor_toughnessdoubleNo——Armor toughness
luckdoubleNo——Luck value
flying_speeddoubleNo——Flying speed (flying mobs only)
scaledoubleNo——Render scale multiplier; 1.0 is vanilla size
step_heightdoubleNo——Block height the mob can step onto directly
jump_strengthdoubleNo——Jump strength (rideable mobs such as horses)
safe_fall_distancedoubleNo——Fall distance that causes no damage
fall_damage_multiplierdoubleNo——Fall damage multiplier
burning_timedoubleNo——Burn duration multiplier once ignited
explosion_knockback_resistancedoubleNo——Explosion knockback resistance
spawn_reinforcementsdoubleNo—0.0–1.0 (vanilla attribute range)Zombie reinforcement call chance
oxygen_bonusdoubleNo——Underwater breathing bonus
water_movement_efficiencydoubleNo——Movement efficiency in water
movement_efficiencydoubleNo——Movement efficiency on ground

NOTE

All of the above are vanilla entity attributes. An entry is ignored when the attribute does not exist on the target entity (writing flying_speed onto a zombie, for example)

Appearance and behavior fields ​

FieldTypeRequiredDefaultAccepted valuesDescription
custom_namestringNo—any stringEntity display name; supports MiniMessage format. Unlike display_name, this really rewrites the name tag
custom_name_visiblebooleanNo—true / falseWhen true, name tag is always visible; when false, it only shows on hover
persistentbooleanNo—true / falsePrevent natural despawn when no players are nearby
silentbooleanNo—true / falseSuppress the mob's sounds
invulnerablebooleanNo—true / falseImmune to all damage
no_aibooleanNo—true / falsetrue disables AI (the mob stops moving and attacking)
glowingbooleanNo—true / falseShow outline glow effect
gravitybooleanNo—true / falseWhether the mob is affected by gravity
collidablebooleanNo—true / falseWhether the mob takes part in entity collision (pushing)
fire_immunebooleanNo—true / falseFire-damage immunity; when true a PDC flag is set and combustion plus fire/lava damage events are cancelled
visual_firebooleanNo—true / falseForce the burning visual effect without dealing fire damage
absorptiondoubleNo—— (points)Initial absorption amount (yellow hearts). (Applied on spawn only)
freeze_ticksintNo—— (ticks)Initial freeze duration (powder snow effect). (Applied on spawn only)
fire_ticksintNo—— (ticks)Initial fire duration in ticks. (Applied on spawn only)

Loot fields ​

FieldTypeRequiredDefaultAccepted valuesDescription
loot_tablestringNo—<namespace>:<path> or a bare path (auto-prefixed with minecraft:)Sets the vanilla/datapack loot table used by the mob: the value is handed to Bukkit.getLootTable and is only written to the entity when it resolves (the plugin registers no datapack, so a custom namespace resolves to nothing and becomes a silent no-op). Unrelated to loot_tables/*.yml
can_pick_up_lootbooleanNo—true / falseWhether the mob can pick up items from the ground
remove_when_farbooleanNo—true / falseDespawn when players move away (overrides persistent)

A custom loot table replaces vanilla drops

loot_tables/<mob_id>.yml applies as soon as a same-named file exists — whether or not components has a loot_table key. Once it applies, death runs event.getDrops().clear(), wiping all vanilla drops and replacing them with the pools in that YAML file (kill experience is still kept via experience)

  • To keep vanilla drops, do not create a same-named YAML loot table for that mob
  • The two are independent: loot_table only affects the vanilla/datapack table itself; writing loot_table: "minecraft:entities/zombie" sets a vanilla table, but with a same-named YAML table present the vanilla drops are still replaced

Equipment fields ​

FieldTypeRequiredDefaultAccepted valuesDescription
main_handItemConfig or material nameNo—see ItemConfig belowMain-hand item (applied on spawn only)
off_handItemConfig or material nameNo—as aboveOff-hand item (applied on spawn only)
helmetItemConfig or material nameNo—as aboveHead slot (equivalent to equipment.head; applied on spawn only)
chestplateItemConfig or material nameNo—as aboveChest slot (equivalent to equipment.chest; applied on spawn only)
leggingsItemConfig or material nameNo—as aboveLegs slot (equivalent to equipment.legs; applied on spawn only)
bootsItemConfig or material nameNo—as aboveFeet slot (equivalent to equipment.feet; applied on spawn only)
equipmentmapNo—keys are slot names, values are an ItemConfig or a material nameConfigure several slots under one section (applied on spawn only)

Slot names under equipment support these spellings (case-insensitive):

SlotAccepted keys
Main handmain_hand, hand
Off handoff_hand
Headhelmet, head
Chestchestplate, chest
Legsleggings, legs
Feetboots, feet

ItemConfig fields:

FieldTypeRequiredDefaultAccepted valuesDescription
itemstringNo—a vanilla material name (case-insensitive, optional minecraft: prefix)Only materials that are items are accepted; when matching fails the slot is left as-is
drop_chancedoubleNo— (vanilla default drop chance)0.0–1.0Drop probability on death; 0.0 means never drops. Not clamped locally — out-of-range values are decided by the vanilla equipment API
yaml
components:
  main_hand:
    item: "minecraft:iron_sword"
    drop_chance: 0.05
  helmet:
    item: "minecraft:iron_helmet"
    drop_chance: 0.0
  equipment:
    legs:
      item: "minecraft:iron_leggings"
      drop_chance: 0.0
    # A bare material name works when only the item matters
    feet: "minecraft:iron_boots"

Mob-specific fields ​

FieldTypeRequiredDefaultAccepted valuesDescription
is_babybooleanNo—true / falseWhether the mob is a baby. Only affects Ageable and Zombie entities; others ignore it
creeper_poweredbooleanNo—true / falseWhether the creeper is charged. Creepers only
creeper_explosion_radiusintNo——Explosion radius. Creepers only
angrybooleanNo—true / falseWhether the wolf is angered. Wolves only
wolf_variantstringNo—a minecraft:wolf_variant registry key (e.g. pale, woods, ashen)Wolf variant. Wolves only; an unrecognised key is ignored
horse_colorstringNo—WHITE, CREAMY, CHESTNUT, BROWN, BLACK, GRAY, DARK_BROWNHorse colour. Horses only; an unrecognised enum is ignored
horse_stylestringNo—NONE, WHITE, WHITE_FIELD, WHITE_DOTS, BLACK_DOTSHorse markings. Horses only
cat_typestringNo—a minecraft:cat_variant registry key (e.g. tabby, siamese, calico, all_black)Cat variant. Cats only
parrot_variantstringNo—RED, BLUE, GREEN, CYAN, GRAYParrot variant. Parrots only
frog_variantstringNo—a minecraft:frog_variant registry key (e.g. temperate, warm, cold)Frog variant. Frogs only
axolotl_variantstringNo—LUCY, WILD, GOLD, CYAN, BLUEAxolotl variant. Axolotls only
llama_colorstringNo—CREAMY, WHITE, BROWN, GRAYLlama colour. Llamas only
llama_strengthintNo—1–5Llama strength (determines chest capacity). Llamas only
slime_sizeintNo——Size (1 = small, 2 = medium, 4 = large). Slimes / magma cubes only
phantom_sizeintNo——Phantom size. Phantoms only
fox_typestringNo—RED, SNOWFox type. Foxes only
rabbit_typestringNo—BROWN, WHITE, BLACK, BLACK_AND_WHITE, GOLD, SALT_AND_PEPPER, THE_KILLER_BUNNYRabbit type. Rabbits only
mushroom_typestringNo—RED, BROWNMooshroom variant. Mooshrooms only
panda_main_genestringNo—NORMAL, LAZY, WORRIED, PLAYFUL, BROWN, WEAK, AGGRESSIVEPanda main gene. Pandas only
panda_hidden_genestringNo—as abovePanda hidden gene. Pandas only
goat_screamingbooleanNo—true / falseWhether this is a screaming goat. Goats only
can_break_doorsbooleanNo—true / falseWhether the mob can break doors. Zombie types only
villager_typestringNo—a minecraft:villager_type registry key (e.g. desert, plains, taiga)Villager biome type. Villagers / zombie villagers only
villager_levelintNo—1–5Profession level (novice to master). Villagers / zombie villagers only
villager_professionstringNo—a minecraft:villager_profession registry key (e.g. armorer, farmer, librarian)Profession. Villagers / zombie villagers only

An entry is skipped when the mob is not of the matching type; an unrecognized enum or registry value is skipped the same way (no error, no log line)

Potion effect field ​

FieldTypeRequiredDefaultAccepted valuesDescription
potion_effectstring or string listNo—colon-separated effect strings, see belowPotion effects applied on spawn (applied on spawn only). Use a single string for one effect or a list for several

Each effect is one colon-separated string:

text
<effect type>:<duration ticks>[:<amplifier>]
SegmentRequiredDescription
Effect typeYesVanilla effect ID, case-insensitive (speed, regeneration, fire_resistance, ...), looked up in the minecraft: namespace
Duration ticksYesDuration in ticks; must parse as an integer
AmplifierNoDefaults to 0 (level I); 1 is level II
yaml
components:
  potion_effect:
    - "speed:99999:1"
    - "regeneration:600"
  # A single effect can be written as a plain string
  # potion_effect: "fire_resistance:1200"

The mapping form is not supported

potion_effect parses only the colon-separated string above. Writing - type: SPEED with duration: and amplifier: keys raises no error, but the whole effect is discarded. ambient, particles and icon are not configurable. An unknown effect type, a missing duration, or an unparsable number also skips the entry silently