Class PrepareRamNearestTarget<E extends PathfinderMob>
java.lang.Object
net.minecraft.world.entity.ai.behavior.Behavior<E>
net.minecraft.world.entity.ai.behavior.PrepareRamNearestTarget<E>
- All Implemented Interfaces:
- BehaviorControl<E>
- 
Nested Class SummaryNested ClassesNested classes/interfaces inherited from class net.minecraft.world.entity.ai.behavior.BehaviorBehavior.Status
- 
Field SummaryFieldsModifier and TypeFieldDescriptionprivate final ToIntFunction<E> private final Function<E, SoundEvent> private final intprivate final intprivate final intprivate final TargetingConditionsstatic final intprivate final floatFields inherited from class net.minecraft.world.entity.ai.behavior.BehaviorDEFAULT_DURATION, entryCondition
- 
Constructor SummaryConstructorsConstructorDescriptionPrepareRamNearestTarget(ToIntFunction<E> p_147724_, int p_147725_, int p_147726_, float p_147727_, TargetingConditions p_147728_, int p_147729_, Function<E, SoundEvent> p_147730_) 
- 
Method SummaryModifier and TypeMethodDescriptioncalculateRammingStartPosition(PathfinderMob p_147743_, LivingEntity p_147744_) protected booleancanStillUse(ServerLevel p_147773_, PathfinderMob p_147774_, long p_147775_) private voidchooseRamPosition(PathfinderMob p_147766_, LivingEntity p_147767_) private Vec3getEdgeOfBlock(BlockPos p_147755_, BlockPos p_147756_) private booleanisWalkableBlock(PathfinderMob p_147746_, BlockPos p_147747_) protected voidstart(ServerLevel p_147736_, PathfinderMob p_147737_, long p_147738_) protected voidstop(ServerLevel p_147762_, E p_147763_, long p_147764_) protected voidtick(ServerLevel p_147784_, E p_147785_, long p_147786_) Methods inherited from class net.minecraft.world.entity.ai.behavior.BehaviorcheckExtraStartConditions, debugString, doStop, getStatus, hasRequiredMemories, tickOrStop, timedOut, tryStart
- 
Field Details- 
TIME_OUT_DURATIONpublic static final int TIME_OUT_DURATION- See Also:
 
- 
getCooldownOnFail
- 
minRamDistanceprivate final int minRamDistance
- 
maxRamDistanceprivate final int maxRamDistance
- 
walkSpeedprivate final float walkSpeed
- 
ramTargeting
- 
ramPrepareTimeprivate final int ramPrepareTime
- 
getPrepareRamSound
- 
reachedRamPositionTimestamp
- 
ramCandidate
 
- 
- 
Constructor Details- 
PrepareRamNearestTargetpublic PrepareRamNearestTarget(ToIntFunction<E> p_147724_, int p_147725_, int p_147726_, float p_147727_, TargetingConditions p_147728_, int p_147729_, Function<E, SoundEvent> p_147730_) 
 
- 
- 
Method Details- 
start- Overrides:
- startin class- Behavior<E extends PathfinderMob>
 
- 
stop- Overrides:
- stopin class- Behavior<E extends PathfinderMob>
 
- 
canStillUse- Overrides:
- canStillUsein class- Behavior<E extends PathfinderMob>
 
- 
tick- Overrides:
- tickin class- Behavior<E extends PathfinderMob>
 
- 
getEdgeOfBlock
- 
calculateRammingStartPositionprivate Optional<BlockPos> calculateRammingStartPosition(PathfinderMob p_147743_, LivingEntity p_147744_) 
- 
isWalkableBlock
- 
chooseRamPosition
 
-