Class SleepInBed
java.lang.Object
net.minecraft.world.entity.ai.behavior.Behavior<LivingEntity>
net.minecraft.world.entity.ai.behavior.SleepInBed
- All Implemented Interfaces:
BehaviorControl<LivingEntity>
-
Nested Class Summary
Nested classes/interfaces inherited from class net.minecraft.world.entity.ai.behavior.Behavior
Behavior.Status
-
Field Summary
Modifier and TypeFieldDescriptionstatic final int
private long
Fields inherited from class net.minecraft.world.entity.ai.behavior.Behavior
DEFAULT_DURATION, entryCondition
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionprotected boolean
canStillUse
(ServerLevel p_24161_, LivingEntity p_24162_, long p_24163_) protected boolean
checkExtraStartConditions
(ServerLevel p_24154_, LivingEntity p_24155_) protected void
start
(ServerLevel p_24157_, LivingEntity p_24158_, long p_24159_) protected void
stop
(ServerLevel p_24165_, LivingEntity p_24166_, long p_24167_) protected boolean
timedOut
(long p_24152_) Methods inherited from class net.minecraft.world.entity.ai.behavior.Behavior
debugString, doStop, getStatus, hasRequiredMemories, tick, tickOrStop, tryStart
-
Field Details
-
COOLDOWN_AFTER_BEING_WOKEN
public static final int COOLDOWN_AFTER_BEING_WOKEN- See Also:
-
nextOkStartTime
private long nextOkStartTime
-
-
Constructor Details
-
SleepInBed
public SleepInBed()
-
-
Method Details
-
checkExtraStartConditions
- Overrides:
checkExtraStartConditions
in classBehavior<LivingEntity>
-
canStillUse
- Overrides:
canStillUse
in classBehavior<LivingEntity>
-
start
- Overrides:
start
in classBehavior<LivingEntity>
-
timedOut
protected boolean timedOut(long p_24152_) - Overrides:
timedOut
in classBehavior<LivingEntity>
-
stop
- Overrides:
stop
in classBehavior<LivingEntity>
-