Move Within Distance Of Target Conditional

Description

Works like MoveWithinDistanceOfTarget, but the mob only moves while the target and the mob match the given conditions.

Attributes

Takes every attribute of MoveWithinDistanceOfTarget, plus:

Attribute Aliases Description Default
targetconditions conditions, cond, c The conditions the target must match for the mob to start and keep moving
mobconditions mconditions, mcond, mc The conditions the mob itself must match for it to start and keep moving

Examples

ExampleMob:
  Type: ZOMBIE
  AIGoalSelectors:
  - 0 clear
  - 1 moveWithinDistanceOfTargetConditional{s=1;minrange=4;maxrange=24;targetConditions=[ - isPlayer true ]}

Aliases

  • moveWithinConditional
  • moveWithinDistanceOfTargetCond
  • moveWithinCond
Updated Sep 23, 2026