net.minecraft.entity.mob

public class HoglinBrain

net.minecraft.world.entity.monster.hoglin.HoglinAi
net.minecraft.class_4835
net.minecraft.entity.mob.HoglinBrain

Field summary

Modifier and TypeField
public static final int
REPELLENT_DETECTION_RANGE_HORIZONTAL
field_30533
field_30533
public static final int
REPELLENT_DETECTION_RANGE_VERTICAL
field_30534
field_30534
private static final UniformIntProvider
RETREAT_DURATION
field_22369
AVOID_MEMORY_DURATION
private static final int
ATTACK_DURATION
field_30535
field_30535
private static final int
DESIRED_DISTANCE_FROM_PIGLIN_WHEN_IDLING
field_30536
field_30536
private static final int
DESIRED_DISTANCE_FROM_PIGLIN_WHEN_RETREATING
field_30537
field_30537
private static final int
ATTACK_INTERVAL
field_30538
ADULT_MELEE_ATTACK_COOLDOWN
private static final int
BABY_ATTACK_INTERVAL
field_30539
BABY_MELEE_ATTACK_COOLDOWN
private static final int
REPELLENT_PACIFY_TIME
field_30540
field_30540
private static final UniformIntProvider
ADULT_FOLLOW_RANGE
field_25383
WALK_TOWARD_CLOSEST_ADULT_RANGE
private static final float
SPEED_MULTIPLIER_WHEN_AVOIDING_REPELLENT
field_30541
field_30541
private static final float
SPEED_MULTIPLIER_WHEN_RETREATING
field_30542
AVOID_TARGET_SPEED
private static final float
SPEED_MULTIPLIER_WHEN_MAKING_LOVE
field_30543
field_30543
private static final float
SPEED_MULTIPLIER_WHEN_IDLING
field_30544
field_30544
private static final float
SPEED_MULTIPLIER_WHEN_FOLLOWING_ADULT
field_30545
field_30545

Constructor summary

ModifierConstructor
public ()

Method summary

Modifier and TypeMethod
protected static List<TaskList<HoglinEntity>>
getActivities()
method_1_1191()
getTaskLists()
private static TaskList<HoglinEntity>
initCoreActivity()
method_24666()
getCoreTasks()
private static TaskList<HoglinEntity>
initIdleActivity()
method_24673()
getIdleTasks()
private static TaskList<HoglinEntity>
initFightActivity()
method_24676()
getFightTasks()
private static TaskList<HoglinEntity>
initRetreatActivity()
method_24679()
getAvoidTasks()
private static RandomTask<HoglinEntity>
createIdleMovementBehaviors()
method_24662()
makeRandomWalkTask()
protected static void
updateActivity(Hoglin body)
method_24664(class_4760 arg0)
refreshActivities(HoglinEntity hoglin)
protected static void
onHitTarget(Hoglin attackerBody, LivingEntity target)
method_24665(class_4760 arg0, class_1309 arg1)
onAttacking(HoglinEntity hoglin, LivingEntity target)
private static void
broadcastRetreat(Hoglin body, LivingEntity target)
method_24675(class_4760 arg0, class_1309 arg1)
askAdultsToAvoid(HoglinEntity hoglin, LivingEntity target)
private static void
retreatFromNearestTarget(Hoglin body, LivingEntity newAvoidTarget)
method_24678(class_4760 arg0, class_1309 arg1)
avoidEnemy(HoglinEntity hoglin, LivingEntity target)
private static void
setAvoidTarget(Hoglin body, LivingEntity avoidTarget)
method_24681(class_4760 arg0, class_1309 arg1)
avoid(HoglinEntity hoglin, LivingEntity target)
private static Optional<? extends LivingEntity>
findNearestValidAttackTarget(ServerLevel level, Hoglin body)
method_24684(class_3218 arg0, class_4760 arg1)
getNearestVisibleTargetablePlayer(ServerWorld world, HoglinEntity hoglin)
static boolean
isPosNearNearestRepellent(Hoglin body, BlockPos pos)
method_24669(class_4760 arg0, class_2338 arg1)
isWarpedFungusAround(HoglinEntity hoglin, BlockPos pos)
private static boolean
wantsToStopFleeing(Hoglin body)
method_25947(class_4760 arg0)
isLoneAdult(HoglinEntity hoglin)
private static boolean
piglinsOutnumberHoglins(Hoglin body)
method_24686(class_4760 arg0)
hasMoreHoglinsAround(HoglinEntity hoglin)
protected static void
wasHurtBy(ServerLevel level, Hoglin body, LivingEntity attacker)
method_24672(class_3218 arg0, class_4760 arg1, class_1309 arg2)
onAttacked(ServerWorld world, HoglinEntity hoglin, LivingEntity attacker)
private static void
maybeRetaliate(ServerLevel level, Hoglin body, LivingEntity attacker)
method_24683(class_3218 arg0, class_4760 arg1, class_1309 arg2)
targetEnemy(ServerWorld world, HoglinEntity hoglin, LivingEntity target)
private static void
setAttackTarget(Hoglin body, LivingEntity target)
method_24685(class_4760 arg0, class_1309 arg1)
setAttackTarget(HoglinEntity hoglin, LivingEntity target)
private static void
broadcastAttackTarget(Hoglin body, LivingEntity target)
method_24687(class_4760 arg0, class_1309 arg1)
askAdultsForHelp(HoglinEntity hoglin, LivingEntity target)
private static void
setAttackTargetIfCloserThanCurrent(Hoglin body, LivingEntity newTarget)
method_24689(class_4760 arg0, class_1309 arg1)
setAttackTargetIfCloser(HoglinEntity hoglin, LivingEntity targetCandidate)
public static Optional<SoundEvent>
getSoundForCurrentActivity(Hoglin body)
method_30083(class_4760 arg0)
getSoundEvent(HoglinEntity hoglin)
private static SoundEvent
getSoundForActivity(Hoglin body, Activity activity)
method_30082(class_4760 arg0, class_4168 arg1)
getSoundEvent(HoglinEntity hoglin, Activity activity)
private static List<HoglinEntity>
getVisibleAdultHoglins(Hoglin body)
method_24690(class_4760 arg0)
getAdultHoglinsAround(HoglinEntity hoglin)
private static boolean
isNearRepellent(Hoglin body)
method_30085(class_4760 arg0)
hasNearestRepellent(HoglinEntity hoglin)
private static boolean
isBreeding(Hoglin body)
method_24691(class_4760 arg0)
hasBreedTarget(HoglinEntity hoglin)
protected static boolean
isPacified(Hoglin body)
method_24677(class_4760 arg0)
isNearPlayer(HoglinEntity hoglin)
private static SoundEvent
lambda$getSoundForCurrentActivity$0(Hoglin arg0, Activity arg1)
method_30084(class_4760 arg0, class_4168 arg1)
method_30084(HoglinEntity arg0, Activity activity)
private static void
lambda$broadcastAttackTarget$0(LivingEntity arg0, Hoglin arg1)
method_24663(class_1309 arg0, class_4760 arg1)
method_24663(LivingEntity arg0, HoglinEntity hoglinx)
private static void
lambda$broadcastRetreat$0(LivingEntity arg0, Hoglin arg1)
method_24670(class_1309 arg0, class_4760 arg1)
method_24670(LivingEntity arg0, HoglinEntity hoglinx)