Search in sources :

Example 1 with PanicGoal

use of net.minecraft.world.entity.ai.goal.PanicGoal 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 PanicGoal

use of net.minecraft.world.entity.ai.goal.PanicGoal 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 PanicGoal

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

the class BasiliskLizardEntity method registerGoals.

@Override
protected void registerGoals() {
    this.goalSelector.addGoal(0, new PanicGoal(this, 1.25));
    this.goalSelector.addGoal(1, new RandomStrollGoal(this, 1.0));
    this.goalSelector.addGoal(2, new LookAtPlayerGoal(this, Player.class, 8.0F));
    this.goalSelector.addGoal(3, new RandomLookAroundGoal(this));
}
Also used : RandomLookAroundGoal(net.minecraft.world.entity.ai.goal.RandomLookAroundGoal) Player(net.minecraft.world.entity.player.Player) LookAtPlayerGoal(net.minecraft.world.entity.ai.goal.LookAtPlayerGoal) RandomStrollGoal(net.minecraft.world.entity.ai.goal.RandomStrollGoal) PanicGoal(net.minecraft.world.entity.ai.goal.PanicGoal)

Example 4 with PanicGoal

use of net.minecraft.world.entity.ai.goal.PanicGoal 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)

Example 5 with PanicGoal

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

the class FiddlerCrabEntity method registerGoals.

@Override
protected void registerGoals() {
    this.goalSelector.addGoal(0, new PanicGoal(this, 1.25));
    this.goalSelector.addGoal(1, new AvoidEntityGoal<>(this, Player.class, 6.0F, 1.0, 1.2));
    this.goalSelector.addGoal(2, new RandomStrollGoal(this, 1.0));
    this.goalSelector.addGoal(3, new LookAtPlayerGoal(this, Player.class, 8.0F));
    this.goalSelector.addGoal(4, new RandomLookAroundGoal(this));
}
Also used : RandomLookAroundGoal(net.minecraft.world.entity.ai.goal.RandomLookAroundGoal) Player(net.minecraft.world.entity.player.Player) LookAtPlayerGoal(net.minecraft.world.entity.ai.goal.LookAtPlayerGoal) RandomStrollGoal(net.minecraft.world.entity.ai.goal.RandomStrollGoal) PanicGoal(net.minecraft.world.entity.ai.goal.PanicGoal)

Aggregations

LookAtPlayerGoal (net.minecraft.world.entity.ai.goal.LookAtPlayerGoal)5 PanicGoal (net.minecraft.world.entity.ai.goal.PanicGoal)5 RandomLookAroundGoal (net.minecraft.world.entity.ai.goal.RandomLookAroundGoal)5 Player (net.minecraft.world.entity.player.Player)5 BreedGoal (net.minecraft.world.entity.ai.goal.BreedGoal)3 FloatGoal (net.minecraft.world.entity.ai.goal.FloatGoal)3 FollowParentGoal (net.minecraft.world.entity.ai.goal.FollowParentGoal)3 TemptGoal (net.minecraft.world.entity.ai.goal.TemptGoal)3 WaterAvoidingRandomStrollGoal (net.minecraft.world.entity.ai.goal.WaterAvoidingRandomStrollGoal)3 RandomStrollGoal (net.minecraft.world.entity.ai.goal.RandomStrollGoal)2