Package net.minecraft.entity.ai.goal
Class BreedGoal
- java.lang.Object
-
- net.minecraft.entity.ai.goal.Goal
-
- net.minecraft.entity.ai.goal.BreedGoal
-
- Direct Known Subclasses:
FoxEntity.MateGoal
,PandaEntity.MateGoal
,TurtleEntity.MateGoal
public class BreedGoal extends Goal
-
-
Field Summary
Fields Modifier and Type Field Description protected AnimalEntity
animal
protected World
level
private int
loveTime
protected AnimalEntity
partner
private static EntityPredicate
PARTNER_TARGETING
private java.lang.Class<? extends AnimalEntity>
partnerClass
private double
speedModifier
-
Constructor Summary
Constructors Constructor Description BreedGoal(AnimalEntity p_i1619_1_, double p_i1619_2_)
BreedGoal(AnimalEntity p_i47306_1_, double p_i47306_2_, java.lang.Class<? extends AnimalEntity> p_i47306_4_)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected void
breed()
boolean
canContinueToUse()
boolean
canUse()
private AnimalEntity
getFreePartner()
void
stop()
void
tick()
-
-
-
Field Detail
-
PARTNER_TARGETING
private static final EntityPredicate PARTNER_TARGETING
-
animal
protected final AnimalEntity animal
-
partnerClass
private final java.lang.Class<? extends AnimalEntity> partnerClass
-
level
protected final World level
-
partner
protected AnimalEntity partner
-
loveTime
private int loveTime
-
speedModifier
private final double speedModifier
-
-
Constructor Detail
-
BreedGoal
public BreedGoal(AnimalEntity p_i1619_1_, double p_i1619_2_)
-
BreedGoal
public BreedGoal(AnimalEntity p_i47306_1_, double p_i47306_2_, java.lang.Class<? extends AnimalEntity> p_i47306_4_)
-
-
Method Detail
-
canContinueToUse
public boolean canContinueToUse()
- Overrides:
canContinueToUse
in classGoal
-
getFreePartner
@Nullable private AnimalEntity getFreePartner()
-
breed
protected void breed()
-
-