Search in sources :

Example 1 with WaterAvoidingRandomStrollGoal

use of net.minecraft.world.entity.ai.goal.WaterAvoidingRandomStrollGoal in project Tropicraft by Tropicraft.

the class TapirEntity method registerGoals.

@Override
protected void registerGoals() {
    this.goalSelector.addGoal(0, new FloatGoal(this));
    this.goalSelector.addGoal(1, new PanicGoal(this, 2.0));
    this.goalSelector.addGoal(2, new BreedGoal(this, 1.0));
    this.goalSelector.addGoal(3, new TemptGoal(this, 1.25, BREEDING_ITEMS.get(), false));
    this.goalSelector.addGoal(4, new FollowParentGoal(this, 1.25));
    this.goalSelector.addGoal(5, new WaterAvoidingRandomStrollGoal(this, 1.0));
    this.goalSelector.addGoal(6, new LookAtPlayerGoal(this, Player.class, 6.0F));
    this.goalSelector.addGoal(7, new RandomLookAroundGoal(this));
}
Also used : RandomLookAroundGoal(net.minecraft.world.entity.ai.goal.RandomLookAroundGoal) Player(net.minecraft.world.entity.player.Player) WaterAvoidingRandomStrollGoal(net.minecraft.world.entity.ai.goal.WaterAvoidingRandomStrollGoal) LookAtPlayerGoal(net.minecraft.world.entity.ai.goal.LookAtPlayerGoal) TemptGoal(net.minecraft.world.entity.ai.goal.TemptGoal) FollowParentGoal(net.minecraft.world.entity.ai.goal.FollowParentGoal) BreedGoal(net.minecraft.world.entity.ai.goal.BreedGoal) FloatGoal(net.minecraft.world.entity.ai.goal.FloatGoal) PanicGoal(net.minecraft.world.entity.ai.goal.PanicGoal)

Example 2 with WaterAvoidingRandomStrollGoal

use of net.minecraft.world.entity.ai.goal.WaterAvoidingRandomStrollGoal in project Tropicraft by Tropicraft.

the class WhiteLippedPeccaryEntity method registerGoals.

@Override
protected void registerGoals() {
    this.goalSelector.addGoal(0, new FloatGoal(this));
    this.goalSelector.addGoal(1, new PanicGoal(this, 2.0));
    this.goalSelector.addGoal(2, new BreedGoal(this, 1.0));
    this.goalSelector.addGoal(3, new TemptGoal(this, 1.25, BREEDING_ITEMS.get(), false));
    this.goalSelector.addGoal(4, new FollowParentGoal(this, 1.25));
    this.goalSelector.addGoal(5, new WaterAvoidingRandomStrollGoal(this, 1.0));
    this.goalSelector.addGoal(6, new LookAtPlayerGoal(this, Player.class, 6.0F));
    this.goalSelector.addGoal(7, new RandomLookAroundGoal(this));
}
Also used : RandomLookAroundGoal(net.minecraft.world.entity.ai.goal.RandomLookAroundGoal) Player(net.minecraft.world.entity.player.Player) WaterAvoidingRandomStrollGoal(net.minecraft.world.entity.ai.goal.WaterAvoidingRandomStrollGoal) LookAtPlayerGoal(net.minecraft.world.entity.ai.goal.LookAtPlayerGoal) TemptGoal(net.minecraft.world.entity.ai.goal.TemptGoal) FollowParentGoal(net.minecraft.world.entity.ai.goal.FollowParentGoal) BreedGoal(net.minecraft.world.entity.ai.goal.BreedGoal) FloatGoal(net.minecraft.world.entity.ai.goal.FloatGoal) PanicGoal(net.minecraft.world.entity.ai.goal.PanicGoal)

Example 3 with WaterAvoidingRandomStrollGoal

use of net.minecraft.world.entity.ai.goal.WaterAvoidingRandomStrollGoal in project Tropicraft by Tropicraft.

the class IguanaEntity method registerGoals.

@Override
protected void registerGoals() {
    goalSelector.addGoal(0, new FloatGoal(this));
    goalSelector.addGoal(2, new MeleeAttackGoal(this, 1.0D, false));
    goalSelector.addGoal(5, new MoveTowardsRestrictionGoal(this, 1.0D));
    goalSelector.addGoal(7, new WaterAvoidingRandomStrollGoal(this, 1.0D));
    goalSelector.addGoal(8, new LookAtPlayerGoal(this, Player.class, 8.0F));
    goalSelector.addGoal(8, new RandomLookAroundGoal(this));
    targetSelector.addGoal(1, new HurtByAggressorGoal(this));
    targetSelector.addGoal(2, new TargetAggressorGoal(this));
}
Also used : RandomLookAroundGoal(net.minecraft.world.entity.ai.goal.RandomLookAroundGoal) Player(net.minecraft.world.entity.player.Player) WaterAvoidingRandomStrollGoal(net.minecraft.world.entity.ai.goal.WaterAvoidingRandomStrollGoal) MoveTowardsRestrictionGoal(net.minecraft.world.entity.ai.goal.MoveTowardsRestrictionGoal) LookAtPlayerGoal(net.minecraft.world.entity.ai.goal.LookAtPlayerGoal) MeleeAttackGoal(net.minecraft.world.entity.ai.goal.MeleeAttackGoal) FloatGoal(net.minecraft.world.entity.ai.goal.FloatGoal)

Example 4 with WaterAvoidingRandomStrollGoal

use of net.minecraft.world.entity.ai.goal.WaterAvoidingRandomStrollGoal in project Tropicraft by Tropicraft.

the class TreeFrogEntity method registerGoals.

@Override
public void registerGoals() {
    goalSelector.addGoal(0, new FloatGoal(this));
    goalSelector.addGoal(1, new RangedAttackGoal(this, 1.0D, 60, 10.0F));
    goalSelector.addGoal(2, new WaterAvoidingRandomStrollGoal(this, 1.0D));
}
Also used : WaterAvoidingRandomStrollGoal(net.minecraft.world.entity.ai.goal.WaterAvoidingRandomStrollGoal) FloatGoal(net.minecraft.world.entity.ai.goal.FloatGoal) RangedAttackGoal(net.minecraft.world.entity.ai.goal.RangedAttackGoal)

Example 5 with WaterAvoidingRandomStrollGoal

use of net.minecraft.world.entity.ai.goal.WaterAvoidingRandomStrollGoal in project Tropicraft by Tropicraft.

the class SpiderMonkeyEntity method registerGoals.

@Override
protected void registerGoals() {
    this.goalSelector.addGoal(0, new FloatGoal(this));
    this.goalSelector.addGoal(1, new PanicGoal(this, 2.0));
    this.goalSelector.addGoal(2, new BreedGoal(this, 1.0));
    this.goalSelector.addGoal(3, new TemptGoal(this, 1.25, BREEDING_ITEMS.get(), false));
    this.goalSelector.addGoal(4, new FollowParentGoal(this, 1.25));
    this.goalSelector.addGoal(5, new WaterAvoidingRandomStrollGoal(this, 1.0));
    this.goalSelector.addGoal(6, new LookAtPlayerGoal(this, Player.class, 6.0F));
    this.goalSelector.addGoal(7, new RandomLookAroundGoal(this));
}
Also used : RandomLookAroundGoal(net.minecraft.world.entity.ai.goal.RandomLookAroundGoal) Player(net.minecraft.world.entity.player.Player) WaterAvoidingRandomStrollGoal(net.minecraft.world.entity.ai.goal.WaterAvoidingRandomStrollGoal) LookAtPlayerGoal(net.minecraft.world.entity.ai.goal.LookAtPlayerGoal) TemptGoal(net.minecraft.world.entity.ai.goal.TemptGoal) FollowParentGoal(net.minecraft.world.entity.ai.goal.FollowParentGoal) BreedGoal(net.minecraft.world.entity.ai.goal.BreedGoal) FloatGoal(net.minecraft.world.entity.ai.goal.FloatGoal) PanicGoal(net.minecraft.world.entity.ai.goal.PanicGoal)

Aggregations

FloatGoal (net.minecraft.world.entity.ai.goal.FloatGoal)9 WaterAvoidingRandomStrollGoal (net.minecraft.world.entity.ai.goal.WaterAvoidingRandomStrollGoal)9 LookAtPlayerGoal (net.minecraft.world.entity.ai.goal.LookAtPlayerGoal)8 Player (net.minecraft.world.entity.player.Player)8 RandomLookAroundGoal (net.minecraft.world.entity.ai.goal.RandomLookAroundGoal)6 BreedGoal (net.minecraft.world.entity.ai.goal.BreedGoal)4 FollowParentGoal (net.minecraft.world.entity.ai.goal.FollowParentGoal)4 TemptGoal (net.minecraft.world.entity.ai.goal.TemptGoal)4 MeleeAttackGoal (net.minecraft.world.entity.ai.goal.MeleeAttackGoal)3 PanicGoal (net.minecraft.world.entity.ai.goal.PanicGoal)3 MoveTowardsRestrictionGoal (net.minecraft.world.entity.ai.goal.MoveTowardsRestrictionGoal)2 HurtByTargetGoal (net.minecraft.world.entity.ai.goal.target.HurtByTargetGoal)2 ServerPlayer (net.minecraft.server.level.ServerPlayer)1 Mob (net.minecraft.world.entity.Mob)1 PathfinderMob (net.minecraft.world.entity.PathfinderMob)1 LeapAtTargetGoal (net.minecraft.world.entity.ai.goal.LeapAtTargetGoal)1 OcelotAttackGoal (net.minecraft.world.entity.ai.goal.OcelotAttackGoal)1 RangedAttackGoal (net.minecraft.world.entity.ai.goal.RangedAttackGoal)1 Cat (net.minecraft.world.entity.animal.Cat)1 Ocelot (net.minecraft.world.entity.animal.Ocelot)1