Class VillagerHostilesSensor
java.lang.Object
net.minecraft.entity.ai.brain.sensor.Sensor<LivingEntity>
net.minecraft.entity.ai.brain.sensor.NearestHostileSensor
net.minecraft.entity.ai.brain.sensor.VillagerHostilesSensor
public class VillagerHostilesSensor extends NearestHostileSensor
-
Field Summary
Fields Modifier and Type Field Description private static ImmutableMap<EntityType<?>,Float>SQUARED_DISTANCES_FOR_DANGER -
Constructor Summary
Constructors Constructor Description VillagerHostilesSensor() -
Method Summary
Modifier and Type Method Description protected Optional<LivingEntity>getNearestHostile(LivingEntity entity)protected booleanisCloseEnoughForDanger(LivingEntity entity, LivingEntity target)private booleanisHostile(LivingEntity entity)Methods inherited from class net.minecraft.entity.ai.brain.sensor.NearestHostileSensor
getOutputMemoryModules, getVisibleMobs, senseMethods inherited from class net.minecraft.entity.ai.brain.sensor.Sensor
method_30954, tick
-
Field Details
-
SQUARED_DISTANCES_FOR_DANGER
-
-
Constructor Details
-
VillagerHostilesSensor
public VillagerHostilesSensor()
-
-
Method Details
-
getNearestHostile
- Specified by:
getNearestHostilein classNearestHostileSensor
-
isCloseEnoughForDanger
- Specified by:
isCloseEnoughForDangerin classNearestHostileSensor
-
isHostile
-