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
- Mappings:
Namespace Name official baj
intermediary net/minecraft/class_4150
named net/minecraft/entity/ai/brain/sensor/VillagerHostilesSensor
-
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 boolean
isCloseEnoughForDanger(LivingEntity entity, LivingEntity target)
private boolean
isHostile(LivingEntity entity)
Methods inherited from class net.minecraft.entity.ai.brain.sensor.NearestHostileSensor
getOutputMemoryModules, getVisibleMobs, sense
Methods inherited from class net.minecraft.entity.ai.brain.sensor.Sensor
testTargetPredicate, tick
-
Field Details
-
SQUARED_DISTANCES_FOR_DANGER
- Mappings:
Namespace Name Mixin selector official a
Lbaj;a:Lcom/google/common/collect/ImmutableMap;
intermediary field_18473
Lnet/minecraft/class_4150;field_18473:Lcom/google/common/collect/ImmutableMap;
named SQUARED_DISTANCES_FOR_DANGER
Lnet/minecraft/entity/ai/brain/sensor/VillagerHostilesSensor;SQUARED_DISTANCES_FOR_DANGER:Lcom/google/common/collect/ImmutableMap;
-
-
Constructor Details
-
VillagerHostilesSensor
public VillagerHostilesSensor()
-
-
Method Details
-
getNearestHostile
- Specified by:
getNearestHostile
in classNearestHostileSensor
- Mappings:
Namespace Name Mixin selector official a
Lazv;a(Lari;)Ljava/util/Optional;
intermediary method_19618
Lnet/minecraft/class_5759;method_19618(Lnet/minecraft/class_1309;)Ljava/util/Optional;
named getNearestHostile
Lnet/minecraft/entity/ai/brain/sensor/NearestHostileSensor;getNearestHostile(Lnet/minecraft/entity/LivingEntity;)Ljava/util/Optional;
-
isCloseEnoughForDanger
- Specified by:
isCloseEnoughForDanger
in classNearestHostileSensor
- Mappings:
Namespace Name Mixin selector official a
Lazv;a(Lari;Lari;)Z
intermediary method_19105
Lnet/minecraft/class_5759;method_19105(Lnet/minecraft/class_1309;Lnet/minecraft/class_1309;)Z
named isCloseEnoughForDanger
Lnet/minecraft/entity/ai/brain/sensor/NearestHostileSensor;isCloseEnoughForDanger(Lnet/minecraft/entity/LivingEntity;Lnet/minecraft/entity/LivingEntity;)Z
-
isHostile
- Mappings:
Namespace Name Mixin selector official c
Lbaj;c(Lari;)Z
intermediary method_19104
Lnet/minecraft/class_4150;method_19104(Lnet/minecraft/class_1309;)Z
named isHostile
Lnet/minecraft/entity/ai/brain/sensor/VillagerHostilesSensor;isHostile(Lnet/minecraft/entity/LivingEntity;)Z
-