1. Wiki
  2. /Entities
  3. /minecraft:behavior.slime_random_direction

minecraft:behavior.slime_random_direction

Don't want to write this by hand? GodCraft sets minecraft:behavior.slime_random_direction for you with a switch.Get GodCraft

Overview

minecraft:behavior.slime_random_direction is an entity component: it goes in the components object of a custom mob, or in one of its component groups. Makes the mob turn to face a new random direction every so often, the way slimes wander.

Fields

FieldTypeDefaultDescription
add_random_time_rangeinteger3Up to this many extra seconds, picked at random, are added to the wait.
turn_rangeinteger360Largest angle, in degrees, the mob can turn when it picks a new direction.
min_change_direction_timenumber2Shortest wait, in seconds, before the mob picks a new direction.
priorityinteger0Decides which goal wins when several want to run: lower numbers run first.Range: 0 to …
control_flagsGoal's control flags[]noneLists the body parts this goal takes control of (such as move, look or jump), so goals that need the same part don't run together.

Example

Inside the components object of BP/entities/<name>.json (values are the defaults or placeholders):

BP/entities/<name>.json
{
  "minecraft:behavior.slime_random_direction": {
    "add_random_time_range": 3,
    "turn_range": 360,
    "min_change_direction_time": 2,
    "priority": 0,
    "control_flags": []
  }
}

We use cookies to improve your experience and analyse site traffic. Learn more