minecraft:behavior.random_look_around
Allows the mob to randomly look around.
Properties
| Property | Type | Default | What it does |
|---|---|---|---|
look_time | Object | {"max": 40, "min": 20} | The range of time in seconds the mob will stay looking in a random direction before looking elsewhere |
min | Integer | 0 | |
max | Integer | 0 | |
min_angle_of_view_horizontal | Decimal | -180 | The leftmost angle a mob can look at on the horizontal plane with respect to its initial facing direction. |
max_angle_of_view_horizontal | Decimal | 180 | The rightmost angle a mob can look at on the horizontal plane with respect to its initial facing direction. |
probability | Decimal | 0.02 | The probability of randomly looking around. |
priority | Integermin 0 | 0 | |
control_flags | List of text | [] |
Example from the game files
This is how vanilla Witch uses it in Minecraft Bedrock 1.26.60.5:
{
"minecraft:behavior.random_look_around": {
"look_distance": 8,
"priority": 5
}
}Used by 55
Vanilla entities with minecraft:behavior.random_look_around in their definition:
AllayArmadilloBlazeBoggedBreezeCamelCamel HuskCave SpiderChickenCopper GolemCowCreeperDolphinDonkeyDrownedElder GuardianEndermanFoxGoatGuardianHoglinHorseHuskIron GolemLlamaMooshroomMulePandaParchedPigPiglinPiglin BrutePillagerPolar BearSheepShulkerSkeletonSkeleton HorseSnifferSnow GolemSpiderStrayStriderTrader LlamaWandering TraderWardenWitchWitherWither SkeletonZoglinZombieZombie HorseZombified PiglinZombie VillagerZombie Villager
Related components
behavior.random_strollbehavior.equip_itembehavior.move_towards_home_restrictionbehavior.timer_flag_1behavior.look_at_entitybehavior.move_towards_dwelling_restrictionbehavior.drink_potionbehavior.jump_to_blockbehavior.squid_divebehavior.squid_idlebehavior.squid_move_away_from_groundbehavior.squid_out_of_waterbehavior.croakbehavior.dragondeathbehavior.drink_milkbehavior.emergebehavior.investigate_suspicious_locationbehavior.lay_downbehavior.napbehavior.rise_to_liquid_levelbehavior.rollbehavior.silverfish_merge_with_stonebehavior.silverfish_wake_up_friendsbehavior.sleep