minecraft:behavior.sniff

Allows this entity to detect the nearest player within "sniffing_radius" and update its "minecraft:suspect_tracking" component state

Properties

PropertyTypeDefaultWhat it does
durationDecimal1Sniffing duration in seconds
sniffing_radiusDecimal5Mob detection radius
suspicion_radius_horizontalDecimal3Mob suspicion horizontal radius. When a player is within this radius horizontally, the anger level towards that player is increased
suspicion_radius_verticalDecimalmin 13Mob suspicion vertical radius. When a player is within this radius vertically, the anger level towards that player is increased
cooldown_rangeObject{"max": 10, "min": 3}Cooldown range between sniffs in seconds
minDecimal0
maxDecimal0
priorityIntegermin 00
control_flagsList of text[]

Example from the game files

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

{
  "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
  }
}

Used by 1

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

Related components