Entity AI goal reference (19/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.go_home
(Source: ms-learn, creator/Reference/Content/EntityReference/Examples/EntityGoals/minecraftBehavior_go_home.md)
Allows the mob to move back to the position they were spawned.
Entity Go Home Behavior Properties
| Name | Default Value | Type | Description |
|---|---|---|---|
| calculate_new_path_radius | 2 | Decimal number | Distance in blocks that the mob is considered close enough to the end of the current path. A new path will then be calculated to continue toward home. |
| 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. |
| interval | 120 | Integer number | A random value to determine when to randomly move somewhere. This has a 1/interval chance to choose this goal |
| on_failed | [] | Array of Failed items | Event(s) to run when this goal fails. |
| on_home | [] | Array of Home items | Event(s) to run when this mob gets home. |
| 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. |
| speed_multiplier | 1 | Decimal number | Movement speed multiplier of the mob when using this AI Goal |
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_failed
| 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_failed > 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
minecraft:behavior.guardian_attack
(Source: ms-learn, creator/Reference/Content/EntityReference/Examples/EntityGoals/minecraftBehavior_guardian_attack.md)
Allows this entity to use a laser beam attack. Can only be used by Guardians and Elder Guardians.
[!Note] In 1.26.0 the schema is stricter and rejects invalid JSON for this behavior.
Entity Guardian Attack Behavior Properties
| Name | Default Value | Type | Description | Example Values |
|---|---|---|---|---|
| control_flags | [] | Control Flags choices | ||
| elder_extra_magic_damage | 2 | Integer number | Amount of additional damage dealt from an elder guardian's magic attack. Value must be > 0. | |
| hard_mode_extra_magic_damage | 2 | Integer number | In hard difficulty, amount of additional damage dealt from a guardian's magic attack. Value must be > 0. | |
| magic_damage | 1 | Integer number | Amount of damage dealt from a guardian's magic attack. Magic attack damage is added to the guardian's base attack damage. Value must be > 0. | |
| min_distance | 3 | Decimal number | Guardian attack behavior stops if the target is closer than this distance (doesn't apply to elders). | |
| 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. | Elder Guardian: 4 |
| sound_delay_time | 0.5 | Decimal number | Time (in seconds) to wait after starting an attack before playing the guardian attack sound. Value must be > 0. | |
| x_max_rotation | 90 | Decimal number | Maximum rotation (in degrees), on the X-axis, this entity can rotate while trying to look at the target. Value must be > 0. | |
| y_max_head_rotation | 90 | Decimal number | Maximum rotation (in degrees), on the Y-axis, this entity can rotate its head while trying to look at the target. Value must be > 0. |
Control Flags choices
| Value | Title | Description |
|---|---|---|
| jump | Jump | |
| look | Look | |
| move | Move |
Samples
Elder Guardian
"minecraft:behavior.guardian_attack": {
"priority": 4
}
minecraft:behavior.harvest_farm_block
(Source: ms-learn, creator/Reference/Content/EntityReference/Examples/EntityGoals/minecraftBehavior_harvest_farm_block.md)
Allows the entity to search within an area for farmland with air above it. If found, the entity will replace the air block by planting a seed item from its inventory on the farmland block. This goal will not execute if the entity does not have an item in its inventory.
[!Note] Requires the following components in order to work properly:
- Inventory (minecraft:inventory)
- Navigation (minecraft:navigation)
Entity Harvest Farm Block Behavior Properties
| Name | Default Value | Type | Description |
|---|---|---|---|
| control_flags | [] | Control Flags choices | |
| goal_radius | 1.5 | Decimal number | Distance in blocks within the entity considers it has reached it's target position. Value must be > 0. |
| max_seconds_before_search | 1 | Decimal number | The maximum amount of time in seconds that the goal can take before searching for the first harvest block. The time is chosen between 0 and this number. Value must be > 0. |
| 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. |
| search_cooldown_max_seconds | 8 | Decimal number | The maximum amount of time in seconds that the goal can take before searching again, after failing to find a a harvest block already. The time is chosen between 0 and this number. Value must be > 0. |
| search_count | 0 | 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 | The height in blocks the entity will search within to find a valid target position. Value must be > 0. |
| search_range | 16 | Integer number | The distance in blocks the entity will search within to find a valid target position. Value must be > 0. |
| seconds_until_new_task | 0.5 | Decimal number | The amount of time in seconds that the goal will cooldown after a successful reap/sow, before it can start again. Value must be > 0. |
| speed_multiplier | 0.5 | Decimal number | Movement speed multiplier of the mob when using this goal. |
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
minecraft:behavior.hide
(Source: ms-learn, creator/Reference/Content/EntityReference/Examples/EntityGoals/minecraftBehavior_hide.md)
Allows a mob with the hide component to attempt to move to - and hide at - an owned or nearby POI.
[!Note] Requires a point of interest to be set in order to work properly.
Entity Hide Behavior Properties
| Name | Default Value | Type | Description |
|---|---|---|---|
| control_flags | [] | Control Flags choices | |
| duration | 1 | Decimal number | Amount of time in seconds that the mob reacts. |
| poi_type | null | Poi Type choices | Tells the goal what POI type it should be looking for |
| 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. |
| speed_multiplier | 1 | Decimal number | Movement speed multiplier of the mob when using this goal. |
| timeout_cooldown | 8 | Decimal number | The cooldown time in seconds before the goal can be reused after a internal failure or timeout condition. |
Control Flags choices
| Value | Title | Description |
|---|---|---|
| jump | Jump | |
| look | Look | |
| move | Move |
Poi Type choices
| Value | Title | Description |
|---|---|---|
| bed | Bed | |
| jobsite | Jobsite | |
| meeting_area | Meeting area |
Samples
minecraft:behavior.hold_ground
(Source: ms-learn, creator/Reference/Content/EntityReference/Examples/EntityGoals/minecraftBehavior_hold_ground.md)
Compels an entity to stop at their current location, turn to face a mob they are targeting, and react with an event.
[!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)
Entity Hold Ground Behavior Properties
| Name | Default Value | Type | Description |
|---|---|---|---|
| broadcast | false | Boolean true/false | Whether to broadcast out the mob's target to other mobs of the same type. |
| broadcast_range | 0 | Decimal number | Range in blocks for how far to broadcast. |
| control_flags | [] | Control Flags choices | |
| min_radius | 10 | Decimal number | Minimum distance the target must be for the mob to run this goal. |
| 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. |
| within_radius_event | {"event":"","filters":{"AND":null,"NOT":null,"OR":null,"all":null,"all_of":null,"any":null,"any_of":null,"none_of":null},"target":"self"} | Within Radius Event item | Event to run when target is within the radius. This event is broadcasted if broadcast is true. |
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: within_radius_event
| 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: within_radius_event > 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
minecraft:behavior.hover
(Source: ms-learn, creator/Reference/Content/EntityReference/Examples/EntityGoals/minecraftBehavior_hover.md)
Allows the mob to hover in place.
Entity Hover Behavior Properties
| Name | Default Value | Type | Description |
|---|---|---|---|
| control_flags | [] | Control Flags choices | |
| priority | 0 | Integer number |
Control Flags choices
| Value | Title | Description |
|---|---|---|
| jump | Jump | |
| look | Look | |
| move | Move |
minecraft:behavior.hurt_by_target
(Source: ms-learn, creator/Reference/Content/EntityReference/Examples/EntityGoals/minecraftBehavior_hurt_by_target.md)
Allows the mob to target another mob that hurts them.
Entity Hurt By Target Behavior Properties
| Name | Default Value | Type | Description | Example Values |
|---|---|---|---|---|
| alert_same_type | false | Boolean true/false | If true, nearby mobs of the same type will be alerted about the damage | |
| control_flags | [] | Control Flags choices | ||
| entity_types | [] | Array of Entity Types items | List of entity types that this mob can target when hurt by them | Bogged: [{"filters":{"operator":"!=","test":"is_family","subject":"other","value":"breeze"}}], Breeze: [{"filters":{"all_of":[{"operator":"!=","test":"is_family","subject":"other","value":"skeleton"},{"operator":"!=","test":"is_family","subject":"other","value":"stray"},{"operator":"!=","test":"is_family","subject":"other","value":"zombie"},{"operator":"!=","test":"is_family","subject":"other","value":"husk"},{"operator":"!=","test":"is_family","subject":"other","value":"spider"},{"operator":"!=","test":"is_family","subject":"other","value":"cavespider"},{"operator":"!=","test":"is_family","subject":"other","value":"slime"}]}}] |
| entity_types (as Object) | not set | Object | ||
| hurt_owner | false | Boolean true/false | If true, the mob will hurt its owner and other mobs with the same owner as itself | |
| 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 |
Entity Types
List of entity types that this mob can target when hurt by them.
Entity Types Properties
JSON path: entity_types
| Name | Default Value | Type | Description |
|---|---|---|---|
| cooldown | 0 | Decimal number | The amount of time in seconds that the mob has to wait before selecting a target of the same type again |
| filters | not set | Minecraft filter | Conditions that make this entry in the list valid |
| max_dist | 16 | Decimal number | Maximum distance this mob can be away to be a valid choice |
| must_see | false | Boolean true/false | If true, the mob has to be visible to be a valid choice |
| must_see_forget_duration | 3 | Decimal number | Determines the amount of time in seconds that this mob will look for a target before forgetting about it and looking for a new one when the target isn't visible any more |
| reevaluate_description | false | Boolean true/false | If true, the mob will stop being targeted if it stops meeting any conditions. |
| sprint_speed_multiplier | 1 | Decimal number | Multiplier for the running speed. A value of 1.0 means the speed is unchanged |
| walk_speed_multiplier | 1 | Decimal number | Multiplier for the walking speed. A value of 1.0 means the speed is unchanged |
Samples
Blaze
"minecraft:behavior.hurt_by_target": {
"priority": 1
}
Bogged
"minecraft:behavior.hurt_by_target": {
"entity_types": [
{
"filters": {
"operator": "!=",
"test": "is_family",
"subject": "other",
"value": "breeze"
}
}
],
"priority": 1
}
Breeze
"minecraft:behavior.hurt_by_target": {
"entity_types": [
{
"filters": {
"all_of": [
{
"operator": "!=",
"test": "is_family",
"subject": "other",
"value": "skeleton"
},
{
"operator": "!=",
"test": "is_family",
"subject": "other",
"value": "stray"
},
{
"operator": "!=",
"test": "is_family",
"subject": "other",
"value": "zombie"
},
{
"operator": "!=",
"test": "is_family",
"subject": "other",
"value": "husk"
},
{
"operator": "!=",
"test": "is_family",
"subject": "other",
"value": "spider"
},
{
"operator": "!=",
"test": "is_family",
"subject": "other",
"value": "cavespider"
},
{
"operator": "!=",
"test": "is_family",
"subject": "other",
"value": "slime"
}
]
}
}
],
"priority": 4
}
minecraft:behavior.inspect_bookshelf
(Source: ms-learn, creator/Reference/Content/EntityReference/Examples/EntityGoals/minecraftBehavior_inspect_bookshelf.md)
Allows the mob to inspect bookshelves.
Entity Inspect Bookshelf Behavior Properties
| Name | Default Value | Type | Description |
|---|---|---|---|
| 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. |
| 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. |
| 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 | The height that the mob will search for bookshelves. Value must be > 0. |
| search_range | 0 | Integer number | The distance in blocks the mob will look for books to inspect. Value must be > 0. |
| speed_multiplier | 1 | Decimal number | Movement speed multiplier of the mob when using this goal. |
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
minecraft:behavior.investigate_suspicious_location
(Source: ms-learn, creator/Reference/Content/EntityReference/Examples/EntityGoals/minecraftBehavior_investigate_suspicious_location.md)
Allows this entity to move towards a "suspicious" position based on data gathered in minecraft:suspect_tracking.
[!Note] Requires the following component in order to work properly:
- Suspect Tracking (minecraft:suspect_tracking)
Entity Investigate Suspicious Location Behavior Properties
| Name | Default Value | Type | Description | Example Values |
|---|---|---|---|---|
| control_flags | [] | Control Flags choices | ||
| goal_radius | 1.5 | Decimal number | Distance in blocks within the entity considers it has reached it's target position. | |
| 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: 5 |
| speed_multiplier | 1 | Decimal number | Movement speed multiplier | Warden: 0.7 |
Control Flags choices
| Value | Title | Description |
|---|---|---|
| jump | Jump | |
| look | Look | |
| move | Move |
Samples
Warden
"minecraft:behavior.investigate_suspicious_location": {
"speed_multiplier": 0.7,
"priority": 5
}
| id | Source | License | Commit | Accessed |
|---|---|---|---|---|
ms-learn | Minecraft Creator documentation (Microsoft Learn) | CC BY 4.0 (documentation), MIT (code) | a9fd1c0 | 2026-11-13 |