Package net.minecraft.entity.ai.goal
Class BreakDoorGoal
- java.lang.Object
-
- net.minecraft.entity.ai.goal.Goal
-
- net.minecraft.entity.ai.goal.InteractDoorGoal
-
- net.minecraft.entity.ai.goal.BreakDoorGoal
-
- Direct Known Subclasses:
VindicatorEntity.BreakDoorGoal
public class BreakDoorGoal extends InteractDoorGoal
-
-
Field Summary
Fields Modifier and Type Field Description protected int
breakTime
protected int
doorBreakTime
protected int
lastBreakProgress
private java.util.function.Predicate<Difficulty>
validDifficulties
-
Fields inherited from class net.minecraft.entity.ai.goal.InteractDoorGoal
doorPos, hasDoor, mob
-
-
Constructor Summary
Constructors Constructor Description BreakDoorGoal(MobEntity p_i50333_1_, int p_i50333_2_, java.util.function.Predicate<Difficulty> p_i50333_3_)
BreakDoorGoal(MobEntity p_i50332_1_, java.util.function.Predicate<Difficulty> p_i50332_2_)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
canContinueToUse()
boolean
canUse()
protected int
getDoorBreakTime()
private boolean
isValidDifficulty(Difficulty p_220696_1_)
void
start()
void
stop()
void
tick()
-
Methods inherited from class net.minecraft.entity.ai.goal.InteractDoorGoal
isOpen, setOpen
-
Methods inherited from class net.minecraft.entity.ai.goal.Goal
getFlags, isInterruptable, setFlags, toString
-
-
-
-
Field Detail
-
validDifficulties
private final java.util.function.Predicate<Difficulty> validDifficulties
-
breakTime
protected int breakTime
-
lastBreakProgress
protected int lastBreakProgress
-
doorBreakTime
protected int doorBreakTime
-
-
Constructor Detail
-
BreakDoorGoal
public BreakDoorGoal(MobEntity p_i50332_1_, java.util.function.Predicate<Difficulty> p_i50332_2_)
-
BreakDoorGoal
public BreakDoorGoal(MobEntity p_i50333_1_, int p_i50333_2_, java.util.function.Predicate<Difficulty> p_i50333_3_)
-
-
Method Detail
-
getDoorBreakTime
protected int getDoorBreakTime()
-
canUse
public boolean canUse()
- Overrides:
canUse
in classInteractDoorGoal
-
start
public void start()
- Overrides:
start
in classInteractDoorGoal
-
canContinueToUse
public boolean canContinueToUse()
- Overrides:
canContinueToUse
in classInteractDoorGoal
-
tick
public void tick()
- Overrides:
tick
in classInteractDoorGoal
-
isValidDifficulty
private boolean isValidDifficulty(Difficulty p_220696_1_)
-
-