Entity AI goal reference (34/41)
This page carries the AI goal (behavior) pages of MS Learn (MicrosoftDocs/minecraft-creator a9fd1c0, CC BY 4.0). IDs, property names, types, default values and JSON are as in the original. The full list is in the index.
minecraft:behavior.sniff
(Source: ms-learn, creator/Reference/Content/EntityReference/Examples/EntityGoals/minecraftBehavior_sniff.md)
Allows this entity to detect the nearest player within "sniffing_radius" and update its "minecraft:suspect_tracking" component state.
Entity Sniff Behavior Properties
| Name | Default Value | Type | Description | Example Values |
|---|---|---|---|---|
| control_flags | [] | Control Flags choices | ||
| cooldown_range | {"max":10,"min":3} | Cooldown Range item | Cooldown range between sniffs in seconds | Warden: {"min":5,"max":10} |
| duration | 1 | Decimal number | Sniffing duration in seconds | Warden: 4.16 |
| priority | 0 | Integer number | As priority approaches 0, the priority is increased. The higher the priority, the sooner this behavior will be executed as a goal. | Warden: 6 |
| sniffing_radius | 5 | Decimal number | Mob detection radius | Warden: 24 |
| suspicion_radius_horizontal | 3 | Decimal number | Mob suspicion horizontal radius. When a player is within this radius horizontally, the anger level towards that player is increased | Warden: 6 |
| suspicion_radius_vertical | 3 | Decimal number | Mob suspicion vertical radius. When a player is within this radius vertically, the anger level towards that player is increased Value must be >= 1. | Warden: 20 |
Control Flags choices
| Value | Title | Description |
|---|---|---|
| jump | Jump | |
| look | Look | |
| move | Move |
Legacy FloatRange
Legacy FloatRange Properties
JSON path: cooldown_range
| Name | Default Value | Type | Description |
|---|---|---|---|
| max | 0 | Decimal number | |
| min | 0 | Decimal number |
Samples
Warden
"minecraft:behavior.sniff": {
"duration": 4.16,
"sniffing_radius": 24,
"suspicion_radius_horizontal": 6,
"suspicion_radius_vertical": 20,
"cooldown_range": {
"min": 5,
"max": 10
},
"priority": 6
}
minecraft:behavior.sonic_boom
(Source: ms-learn, creator/Reference/Content/EntityReference/Examples/EntityGoals/minecraftBehavior_sonic_boom.md)
Allows this entity to perform a 'sonic boom' ranged attack.
Entity Sonic Boom Behavior Properties
| Name | Default Value | Type | Description | Example Values |
|---|---|---|---|---|
| attack_cooldown | 5 | Decimal number | Cooldown in seconds required after using this attack until the entity can use sonic boom again. | Warden: 2 |
| attack_damage | 30 | Decimal number | Attack damage of the sonic boom. | Warden: 10 |
| attack_range_horizontal | 15 | Decimal number | Horizontal range (in blocks) at which the sonic boom can damage the target. | |
| attack_range_vertical | 20 | Decimal number | Vertical range (in blocks) at which the sonic boom can damage the target. | |
| attack_sound | String | Sound event for the attack. | Warden: "sonic_boom" | |
| charge_sound | String | Sound event for the charge up. | Warden: "sonic_charge" | |
| control_flags | [] | Control Flags choices | ||
| duration | 0 | Decimal number | Goal duration in seconds | Warden: 3 |
| duration_until_attack_sound | 1.7000000476837158 | Decimal number | Duration in seconds until the attack sound is played. | |
| knockback_height_cap | 0 | Decimal number | Height cap of the attack knockback's vertical delta. | Warden: 0.5 |
| knockback_horizontal_strength | 0 | Decimal number | Horizontal strength of the attack's knockback applied to the attack target. | Warden: 2.5 |
| knockback_vertical_strength | 0 | Decimal number | Vertical strength of the attack's knockback applied to the attack target. | Warden: 0.5 |
| priority | 0 | Integer number | As priority approaches 0, the priority is increased. The higher the priority, the sooner this behavior will be executed as a goal. | Warden: 3 |
| speed_multiplier | 1 | Decimal number | This multiplier modifies the attacking entity's speed when moving toward the target. | Warden: 1.2 |
Control Flags choices
| Value | Title | Description |
|---|---|---|
| jump | Jump | |
| look | Look | |
| move | Move |
Samples
Warden
"minecraft:behavior.sonic_boom": {
"duration": 3,
"speed_multiplier": 1.2,
"attack_damage": 10,
"attack_cooldown": 2,
"knockback_vertical_strength": 0.5,
"knockback_horizontal_strength": 2.5,
"knockback_height_cap": 0.5,
"attack_sound": "sonic_boom",
"charge_sound": "sonic_charge",
"priority": 3
}
minecraft:behavior.squid_dive
(Source: ms-learn, creator/Reference/Content/EntityReference/Examples/EntityGoals/minecraftBehavior_squid_dive.md)
Allows the squid to dive down in water.
[!Note] Can only be used on the following type of entity:
- Squid (minecraft:squid)
Entity Squid Dive Behavior Properties
| Name | Default Value | Type | Description |
|---|---|---|---|
| control_flags | [] | Control Flags choices | |
| priority | 0 | Integer number | As priority approaches 0, the priority is increased. The higher the priority, the sooner this behavior will be executed as a goal. |
Control Flags choices
| Value | Title | Description |
|---|---|---|
| jump | Jump | |
| look | Look | |
| move | Move |
Samples
minecraft:behavior.squid_flee
(Source: ms-learn, creator/Reference/Content/EntityReference/Examples/EntityGoals/minecraftBehavior_squid_flee.md)
Allows the squid to swim away.
[!Note] Can only be used on the following type of entity:
- Squid (minecraft:squid)
Entity Squid Flee Behavior Properties
| Name | Default Value | Type | Description |
|---|---|---|---|
| control_flags | [] | Control Flags choices | |
| priority | 0 | Integer number | As priority approaches 0, the priority is increased. The higher the priority, the sooner this behavior will be executed as a goal. |
Control Flags choices
| Value | Title | Description |
|---|---|---|
| jump | Jump | |
| look | Look | |
| move | Move |
Samples
minecraft:behavior.squid_idle
(Source: ms-learn, creator/Reference/Content/EntityReference/Examples/EntityGoals/minecraftBehavior_squid_idle.md)
Allows the squid to swim in place idly.
[!Note] Can only be used on the following type of entity:
- Squid (minecraft:squid)
Entity Squid Idle Behavior Properties
| Name | Default Value | Type | Description |
|---|---|---|---|
| control_flags | [] | Control Flags choices | |
| priority | 0 | Integer number | As priority approaches 0, the priority is increased. The higher the priority, the sooner this behavior will be executed as a goal. |
Control Flags choices
| Value | Title | Description |
|---|---|---|
| jump | Jump | |
| look | Look | |
| move | Move |
Samples
minecraft:behavior.squid_move_away_from_ground
(Source: ms-learn, creator/Reference/Content/EntityReference/Examples/EntityGoals/minecraftBehavior_squid_move_away_from_ground.md)
Allows the squid to move away from ground blocks and back to water.
[!Note] Can only be used on the following type of entity:
- Squid (minecraft:squid)
Entity Squid Move Away From Ground Behavior Properties
| Name | Default Value | Type | Description |
|---|---|---|---|
| control_flags | [] | Control Flags choices | |
| priority | 0 | Integer number | As priority approaches 0, the priority is increased. The higher the priority, the sooner this behavior will be executed as a goal. |
Control Flags choices
| Value | Title | Description |
|---|---|---|
| jump | Jump | |
| look | Look | |
| move | Move |
Samples
minecraft:behavior.squid_out_of_water
(Source: ms-learn, creator/Reference/Content/EntityReference/Examples/EntityGoals/minecraftBehavior_squid_out_of_water.md)
Allows the squid to stick to the ground when outside water.
[!Note] Can only be used on the following type of entity:
- Squid (minecraft:squid)
Entity Squid Out Of Water Behavior Properties
| Name | Default Value | Type | Description |
|---|---|---|---|
| control_flags | [] | Control Flags choices | |
| priority | 0 | Integer number | As priority approaches 0, the priority is increased. The higher the priority, the sooner this behavior will be executed as a goal. |
Control Flags choices
| Value | Title | Description |
|---|---|---|
| jump | Jump | |
| look | Look | |
| move | Move |
Samples
minecraft:behavior.stalk_and_pounce_on_target
(Source: ms-learn, creator/Reference/Content/EntityReference/Examples/EntityGoals/minecraftBehavior_stalk_and_pounce_on_target.md)
Allows a mob to stalk a target, then once within range pounce onto a target, on success the target will be attacked dealing damage defined by the attack component. On failure, the mob will risk getting stuck.
[!Note] Requires a target in order to work properly. Entities can generate targets via one of the following behaviors:
Nearest Attackable Target Behavior (minecraft:behavior.nearest_attackable_target)
Hurt By Target Behavior (minecraft:behavior.hurt_by_target) [!Note] Requires the following component in order to work properly:
Attack (minecraft:attack)
Entity Stalk And Pounce On Target Behavior Properties
| Name | Default Value | Type | Description |
|---|---|---|---|
| control_flags | [] | Control Flags choices | |
| interest_time | 2 | Decimal number | The amount of time the mob will be interested before pouncing. This happens when the mob is within range of pouncing |
| leap_dist | 0.800000011920929 | Decimal number | The distance in blocks the mob jumps in the direction of its target |
| leap_distance | 0.8 | Decimal number | The distance in blocks the mob jumps in the direction of its target |
| leap_height | 0.8999999761581421 | Decimal number | The height in blocks the mob jumps when leaping at its target |
| max_stalk_dist | 10 | Decimal number | The maximum distance away a target can be before the mob gives up on stalking |
| pounce_max_dist | 5 | Decimal number | The maximum distance away from the target in blocks to begin pouncing at the target |
| priority | 0 | Integer number | As priority approaches 0, the priority is increased. The higher the priority, the sooner this behavior will be executed as a goal. |
| set_persistent | false | Boolean true/false | Allows the actor to be set to persist upon targeting a player |
| stalk_speed | 1.2000000476837158 | Decimal number | The movement speed in which you stalk your target |
| strike_dist | 2 | Decimal number | The max distance away from the target when landing from the pounce that will still result in damaging the target |
| stuck_blocks (Stuck Blocks) | {"AND":null,"NOT":null,"OR":null,"all":null,"all_of":null,"any":null,"any_of":null,"none_of":null} | Stuck Blocks item | Blocks that the mob can get stuck in after a pounce. |
| stuck_blocks (Alternate 1) | not set | Object | |
| stuck_time | 2 | Decimal number | The amount of time the mob will be stuck if they fail and land on a block they can be stuck on |
Control Flags choices
| Value | Title | Description |
|---|---|---|
| jump | Jump | |
| look | Look | |
| move | Move |
Stuck Blocks
Stuck Blocks Properties
JSON path: stuck_blocks
| Name | Default Value | Type | Description |
|---|---|---|---|
| domain | not set | Object | The domain the test should be performed in. |
| operator | not set | Object | The comparison to apply with 'value'. |
| subject | not set | Object | The subject of this filter test. |
| test | not set | String | The name of the test to apply. |
| value | not set | Object | The value being compared with the test. |
Samples
minecraft:behavior.stay_near_noteblock
(Source: ms-learn, creator/Reference/Content/EntityReference/Examples/EntityGoals/minecraftBehavior_stay_near_noteblock.md)
The entity will attempt to toss the items from its inventory to a nearby recently played noteblock.
Entity Stay Near Noteblock Behavior Properties
| Name | Default Value | Type | Description | Example Values |
|---|---|---|---|---|
| control_flags | [] | Control Flags choices | ||
| listen_time | 30 | Integer number | Sets the time an entity should stay near a noteblock after hearing it. | |
| priority | 0 | Integer number | As priority approaches 0, the priority is increased. The higher the priority, the sooner this behavior will be executed as a goal. | Allay: 5 |
| speed | 1 | Decimal number | Sets the entity's speed when moving toward the block. | Allay: 8 |
| start_distance | 10 | Decimal number | Sets the distance the entity needs to be away from the block to attempt to start the goal. | Allay: 16 |
| stop_distance | 2 | Decimal number | Sets the distance from the block the entity will attempt to reach. | Allay: 4 |
Control Flags choices
| Value | Title | Description |
|---|---|---|
| jump | Jump | |
| look | Look | |
| move | Move |
Samples
Allay
"minecraft:behavior.stay_near_noteblock": {
"speed": 8,
"start_distance": 16,
"stop_distance": 4,
"priority": 5
}
minecraft:behavior.stay_while_sitting
(Source: ms-learn, creator/Reference/Content/EntityReference/Examples/EntityGoals/minecraftBehavior_stay_while_sitting.md)
Allows the mob to stay put while it is in a sitting state instead of doing something else.
[!Note] This behavior works with the minecraft:sittable component. When the entity is commanded to sit, this goal prevents other behaviors from moving the entity.
Entity Stay While Sitting Behavior Properties
| Name | Default Value | Type | Description | Example Values |
|---|---|---|---|---|
| control_flags | [] | Control Flags choices | ||
| priority | 0 | Integer number | As priority approaches 0, the priority is increased. The higher the priority, the sooner this behavior will be executed as a goal. | Parrot: 2 |
Control Flags choices
| Value | Title | Description |
|---|---|---|
| jump | Jump | |
| look | Look | |
| move | Move |
Samples
Parrot
"minecraft:behavior.stay_while_sitting": {
"priority": 2
}
minecraft:behavior.stomp_attack
(Source: ms-learn, creator/Reference/Content/EntityReference/Examples/EntityGoals/minecraftBehavior_stomp_attack.md)
Allows an entity to attack using stomp AoE damage behavior.
[!Note] In 1.26.0 the schema is stricter and rejects invalid JSON for this behavior.
Entity Stomp Attack Behavior Properties
| Name | Default Value | Type | Description | Example Values |
|---|---|---|---|---|
| attack_once | false | Boolean true/false | Allows the mob to perform this melee attack behavior only once during its lifetime. | |
| attack_types | String | Defines the entity types this entity will attack. | ||
| can_spread_on_fire | false | Boolean true/false | Allows the mob, if on fire and empty handed, to ignite its target upon a successful attack. | |
| control_flags | [] | Control Flags choices | ||
| cooldown_time | 1 | Decimal number | Cooldown time, in seconds, between consecutive attacks. | |
| inner_boundary_time_increase | 0.25 | Decimal number | Time, in seconds, added to the attack path recalculation interval when the target is beyond "path_inner_boundary". | |
| max_path_time | 0.550000011920929 | Decimal number | Maximum base time, in seconds, before recalculating a new attack path to the target (before increases are applied). | |
| min_path_time | 0.20000000298023224 | Decimal number | Minimum base time, in seconds, before recalculating a new attack path to the target (before increases are applied). | |
| no_damage_range_multiplier | 2 | Decimal number | Multiplied with the final AoE damage range to determine a no damage range. The stomp attack will go on cooldown if target is in this no damage range. Value must be > 0. | Polar Bear: 2 |
| on_attack | {"event":"","filters":{"AND":null,"NOT":null,"OR":null,"all":null,"all_of":null,"any":null,"any_of":null,"none_of":null},"target":"self"} | Attack item | Defines the event to trigger when this entity successfully attacks. | |
| on_kill | {"event":"","filters":{"AND":null,"NOT":null,"OR":null,"all":null,"all_of":null,"any":null,"any_of":null,"none_of":null},"target":"self"} | Kill item | Defines the event to trigger when this entity kills the target. | |
| outer_boundary_time_increase | 0.5 | Decimal number | Time, in seconds, added to the attack path recalculation interval when the target is beyond "path_outer_boundary". | |
| path_fail_time_increase | 0.75 | Decimal number | Time, in seconds, added to the attack path recalculation interval when the mob cannot move along the current path. | |
| path_inner_boundary | 16 | Decimal number | Distance at which to increase attack path recalculation by "inner_boundary_time_increase". | |
| path_outer_boundary | 32 | Decimal number | Distance at which to increase attack path recalculation by "outer_boundary_time_increase". | |
| priority | 0 | Integer number | As priority approaches 0, the priority is increased. The higher the priority, the sooner this behavior will be executed as a goal. | Polar Bear: 1 |
| random_stop_interval | 0 | Integer number | Defines a 1-in-N chance for the mob to stop its current attack, where N equals "random_stop_interval". | |
| reach_multiplier | 2 | Decimal number | Used with the base size of the entity to determine minimum target-distance before trying to deal attack damage. | |
| require_complete_path | false | Boolean true/false | Specifies whether a full navigation path from the mob to the target is required. | Polar Bear: true |
| speed_multiplier | 1 | Decimal number | Multiplier applied to the mob's movement speed when moving toward its target. | |
| stomp_range_multiplier | 2 | Decimal number | Multiplied with the base size of the entity to determine stomp AoE damage range. Value must be > 0. | Polar Bear: 2 |
| track_target | false | Boolean true/false | Allows the mob to track its target even if it lacks a hard-coded sensing component. | Polar Bear: true |
| x_max_rotation | 30 | Decimal number | Maximum rotation, in degrees, on the X-axis while the mob is trying to look at its target. | |
| y_max_head_rotation | 30 | Decimal number | Maximum rotation, in degrees, on the Y-axis while the mob is trying to look at its target. |
Control Flags choices
| Value | Title | Description |
|---|---|---|
| jump | Jump | |
| look | Look | |
| move | Move |
Entity ActorDefinitionTrigger
Triggers an entity event when specified conditions are met. Events activate component groups that change entity behavior—transforming villagers into zombie villagers, switching mobs to aggressive mode, or triggering growth stages. Combine with filters to create conditional state machines that respond to gameplay.
Entity ActorDefinitionTrigger Properties
JSON path: on_attack
| Name | Default Value | Type | Description |
|---|---|---|---|
| event | String | ||
| filters (Filters) | {"AND":null,"NOT":null,"OR":null,"all":null,"all_of":null,"any":null,"any_of":null,"none_of":null} | Filters item | Filters allow data objects to specify test criteria which allows their use. |
| filters (Alternate 1) | not set | Object | |
| target | self | Target choices |
filters
Filters allow data objects to specify test criteria which allows their use. Filters can be defined by a single object of type (Filter Test), an array of tests, collection groups, or a combination of these objects.
Filters
Filters Properties
JSON path: on_attack > filters
| Name | Default Value | Type | Description |
|---|---|---|---|
| domain | not set | Object | The domain the test should be performed in. |
| operator | not set | Object | The comparison to apply with 'value'. |
| subject | not set | Object | The subject of this filter test. |
| test | not set | String | The name of the test to apply. |
| value | not set | Object | The value being compared with the test. |
Target choices
| Value | Title | Description |
|---|---|---|
| baby | Baby | |
| block | Block | |
| damager | Damager | |
| holder | Holder | |
| item | Item | |
| other | Other | |
| parent | Parent | |
| player | Player | |
| self | Self | |
| target | Target |
Samples
Polar Bear
"minecraft:behavior.stomp_attack": {
"priority": 1,
"track_target": true,
"require_complete_path": true,
"stomp_range_multiplier": 2,
"no_damage_range_multiplier": 2
}
minecraft:behavior.stomp_turtle_egg
(Source: ms-learn, creator/Reference/Content/EntityReference/Examples/EntityGoals/minecraftBehavior_stomp_turtle_egg.md)
Allows this mob to stomp turtle eggs.
Entity Stomp Turtle Egg Behavior Properties
| Name | Default Value | Type | Description | Example Values |
|---|---|---|---|---|
| control_flags | [] | Control Flags choices | ||
| goal_radius | 0.5 | Decimal number | Distance in blocks within the mob considers it has reached the goal. This is the "wiggle room" to stop the AI from bouncing back and forth trying to reach a specific spot. Value must be > 0. | Drowned: 1.14 |
| interval | 120 | Integer number | A random value to determine when to randomly move somewhere. This has a 1/interval chance to choose this goal Value must be > 0. | Drowned: 20 |
| priority | 0 | Integer number | As priority approaches 0, the priority is increased. The higher the priority, the sooner this behavior will be executed as a goal. | Drowned: 4 |
| search_count | 10 | Integer number | The number of randomly selected blocks each tick that the mob will check within its search range and height for a valid block to move to. | |
| search_height | 1 | Integer number | Height in blocks the mob will look for turtle eggs to move towards Value must be > 0. | Drowned: 2 |
| search_range | 0 | Integer number | The distance in blocks it will look for turtle eggs to move towards Value must be > 0. | Drowned: 10 |
| speed_multiplier | 1 | Decimal number | Movement speed multiplier of the mob when using this goal. | Drowned: 1 |
search_count
The number of randomly selected blocks each tick that the mob will check within its search range and height for a valid block to move to. A value of 0 will have the mob check every block within range in one tick.
Control Flags choices
| Value | Title | Description |
|---|---|---|
| jump | Jump | |
| look | Look | |
| move | Move |
Samples
Drowned
"minecraft:behavior.stomp_turtle_egg": {
"goal_radius": 1.14,
"priority": 4,
"search_height": 2,
"interval": 20,
"search_range": 10,
"speed_multiplier": 1
}
| id | Source | License | Commit | Accessed |
|---|---|---|---|---|
ms-learn | Minecraft Creator documentation (Microsoft Learn) | CC BY 4.0 (documentation), MIT (code) | a9fd1c0 | 2026-11-13 |