net.minecraft.entity.ai.goal

public class EscapeDangerGoal

extends Goal

net.minecraft.world.entity.ai.goal.PanicGoal
net.minecraft.world.entity.ai.goal.PanicGoal
net.minecraft.class_1374
net.minecraft.entity.ai.goal.EscapeDangerGoal

Field summary

Modifier and TypeField
public static final int
WATER_CHECK_DISTANCE_VERTICAL
WATER_CHECK_DISTANCE_VERTICAL
field_36271
RANGE_Y
protected final PathAwareEntity
mob
mob
field_6549
mob
protected final double
speedModifier
speedModifier
field_6548
speed
protected double
posX
posX
field_6547
targetX
protected double
posY
posY
field_6546
targetY
protected double
posZ
posZ
field_6550
targetZ
protected boolean
isRunning
isRunning
field_23227
active
private final Function<PathAwareEntity, TagKey<DamageType>>
panicCausingDamageTypes
panicCausingDamageTypes
field_52011
entityToDangerousDamageTypes

Constructor summary

ModifierConstructor
public (PathAwareEntity mob, double speed)
public (PathAwareEntity mob, double speed, TagKey<DamageType> dangerousDamageTypes)
public (PathAwareEntity mob, double speed, Function<PathAwareEntity, TagKey<DamageType>> entityToDangerousDamageTypes)

Method summary

Modifier and TypeMethod
public boolean
canUse()
canUse()
method_6264()
canStart()
protected boolean
shouldPanic()
shouldPanic()
method_40072()
isInDanger()
protected boolean
findRandomPosition()
findRandomPosition()
method_6301()
findTarget()
public boolean
isRunning()
isRunning()
method_26337()
isActive()
public void
start()
start()
method_6269()
start()
public void
stop()
stop()
method_6270()
stop()
public boolean
canContinueToUse()
canContinueToUse()
method_6266()
shouldContinue()
protected BlockPos
lookForWater(BlockGetter level, Entity mob, int xzDist)
lookForWater(BlockGetter level, Entity mob, int xzDist)
method_6300(class_1922 arg0, class_1297 arg1, int arg2)
locateClosestWater(BlockView world, Entity entity, int rangeX)