minecraft:behavior.play_dead

Allows this entity to pretend to be dead to avoid being targeted by attackers.

Properties

PropertyTypeDefaultWhat it does
durationDecimal1The amount of time the mob will remain playing dead (in seconds).
random_start_chanceDecimal1The likelihood of this goal starting upon taking damage.
force_below_healthInteger0The amount of health at which damage will cause the mob to play dead.
random_damage_rangeObject{"max": 0, "min": 0}The range of damage that may cause the goal to start depending on randomness. Damage taken below the min will never cause the goal to start. Damage taken above the max will always cause the goal to start.
minInteger0
maxInteger0
damage_sourcesList of text[]The list of Entity Damage Sources that will cause this mob to play dead.
apply_regenerationBooleanfalseWhether the mob will receive the regeneration effect while playing dead.
filtersObject or List of object{"AND": null, "NOT": null, "OR": null, "all": null, "all_…The list of other triggers that are required for the mob to activate play dead
testText—The name of the test to apply.
subjectBoolean or Integer or Decimal or Text—The subject of this filter test.
operatorBoolean or Integer or Decimal or Text—The comparison to apply with 'value'.
domainBoolean or Integer or Decimal or Text—The domain the test should be performed in.
valueBoolean or Integer or Decimal or Text—The value being compared with the test.
priorityIntegermin 00
control_flagsList of text[]

Example from the game files

This is how vanilla Axolotl uses it in Minecraft Bedrock 1.26.60.5:

{
  "minecraft:behavior.play_dead": {
    "priority": 0,
    "duration": 10,
    "force_below_health": 8,
    "random_start_chance": 0.33,
    "random_damage_range": {
      "min": 0,
      "max": 2
    },
    "damage_sources": [
      "contact",
      "entity_attack",
      "entity_explosion",
      "magic",
      "projectile",
      "thorns",
      "wither"
    ],
    "apply_regeneration": true,
    "filters": {
      "test": "in_water",
      "operator": "==",
      "value": true
    }
  }
}

Used by 1

Vanilla entities with minecraft:behavior.play_dead in their definition:

Related components