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

minecraft:behavior.circle_around_anchor

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

Overview

minecraft:behavior.circle_around_anchor is an entity component: it goes in the components object of a custom mob, or in one of its component groups. AI goal that makes the mob fly in circles around a point near its spot or its target, like a phantom.

Fields

FieldTypeDefaultDescription
radius_changenumber1Blocks added to the circle size when a size change happens.
radius_adjustment_chancenumber0.004Chance each time to change the circle size. 1 means 100%.
height_adjustment_chancenumber0.002857Chance each time to raise or lower the circle height. 1 means 100%.
goal_radiusnumber0.5How close the mob must get to the point to count as there, which stops jittering.
speed_multipliernumber1Speed multiplier while circling.
angle_changenumber15Degrees the mob turns each time it picks its next point.
radius_rangeFloatRange{"max":15,"min":5}Smallest and largest circle size allowed.
height_offset_rangeFloatRange{"max":0,"min":0}Lowest and highest height above or below the point allowed.
height_above_target_rangeFloatRange{"max":0,"min":0}How many blocks above a target the next point can be, used only while chasing a target.
priorityinteger0Lower numbers run first: when two goals compete, the one with the smaller priority wins.Range: 0 to …
control_flagsGoal's control flags[]noneWhich body parts this goal takes over (move, look, jump), so goals using the same parts cannot run together.

Example

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

BP/entities/<name>.json
{
  "minecraft:behavior.circle_around_anchor": {
    "radius_change": 1,
    "radius_adjustment_chance": 0.004,
    "height_adjustment_chance": 0.002857,
    "goal_radius": 0.5,
    "speed_multiplier": 1,
    "angle_change": 15,
    "radius_range": {
      "max": 15,
      "min": 5
    },
    "height_offset_range": {
      "max": 0,
      "min": 0
    }
  }
}

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