Search in sources :

Example 46 with LookAtEntityGoal

use of net.minecraft.entity.ai.goal.LookAtEntityGoal in project MCDoom by AzureDoom.

the class ProwlerEntity method initGoals.

@Override
protected void initGoals() {
    this.goalSelector.add(0, new SwimGoal(this));
    this.goalSelector.add(4, new DemonAttackGoal(this, 1.25D, 2));
    this.goalSelector.add(4, new ProwlerEntity.RangedStrafeAttackGoal(this, new FireballAttack(this, false).setProjectileOriginOffset(0.8, 0.8, 0.8).setDamage(config.prowler_ranged_damage).setSound(SoundEvents.ENTITY_BLAZE_SHOOT, 1.0F, 1.4F + this.getRandom().nextFloat() * 0.35F), 1.0D, 50, 30, 15, 15F).setMultiShot(3, 2));
    this.goalSelector.add(8, new LookAtEntityGoal(this, PlayerEntity.class, 8.0F));
    this.goalSelector.add(8, new LookAroundGoal(this));
    this.targetSelector.add(1, new ProwlerEntity.TeleportTowardsPlayerGoal(this, this::shouldAngerAt));
    this.targetSelector.add(3, new ActiveTargetGoal<>(this, PlayerEntity.class, true));
    this.targetSelector.add(3, new ActiveTargetGoal<>(this, MerchantEntity.class, true));
    this.targetSelector.add(2, new RevengeGoal(this));
    this.targetSelector.add(4, new UniversalAngerGoal<>(this, false));
}
Also used : RevengeGoal(net.minecraft.entity.ai.goal.RevengeGoal) MerchantEntity(net.minecraft.entity.passive.MerchantEntity) DemonAttackGoal(mod.azure.doom.entity.ai.goal.DemonAttackGoal) LookAroundGoal(net.minecraft.entity.ai.goal.LookAroundGoal) LookAtEntityGoal(net.minecraft.entity.ai.goal.LookAtEntityGoal) SwimGoal(net.minecraft.entity.ai.goal.SwimGoal) PlayerEntity(net.minecraft.entity.player.PlayerEntity) FireballAttack(mod.azure.doom.entity.attack.FireballAttack)

Example 47 with LookAtEntityGoal

use of net.minecraft.entity.ai.goal.LookAtEntityGoal in project MCDoom by AzureDoom.

the class TentacleEntity method initGoals.

@Override
protected void initGoals() {
    this.goalSelector.add(8, new LookAtEntityGoal(this, PlayerEntity.class, 8.0F));
    this.goalSelector.add(8, new LookAtEntityGoal(this, MerchantEntity.class, 8.0F));
    this.goalSelector.add(9, new TentacleEntity.AttackGoal(this));
    this.targetSelector.add(2, new ActiveTargetGoal<>(this, PlayerEntity.class, true));
    this.targetSelector.add(2, new ActiveTargetGoal<>(this, MerchantEntity.class, true));
    this.targetSelector.add(2, new RevengeGoal(this).setGroupRevenge());
}
Also used : RevengeGoal(net.minecraft.entity.ai.goal.RevengeGoal) MerchantEntity(net.minecraft.entity.passive.MerchantEntity) LookAtEntityGoal(net.minecraft.entity.ai.goal.LookAtEntityGoal) PlayerEntity(net.minecraft.entity.player.PlayerEntity)

Example 48 with LookAtEntityGoal

use of net.minecraft.entity.ai.goal.LookAtEntityGoal in project Biome-Makeover by Lemonszz.

the class RavagerChargePhase method initAI.

@Override
protected void initAI() {
    this.goalSelector.add(0, new LookAtEntityGoal(adjudicator, PlayerEntity.class, 20.0F));
    this.goalSelector.add(1, new MountedCrossbowAttackGoal<>(adjudicator, 25.0F));
    this.targetSelector.add(1, new RevengeGoal(adjudicator));
    this.targetSelector.add(2, new FollowTargetGoal<>(adjudicator, PlayerEntity.class, false));
    this.targetSelector.add(3, new FollowTargetGoal<>(adjudicator, GolemEntity.class, true));
}
Also used : RevengeGoal(net.minecraft.entity.ai.goal.RevengeGoal) LookAtEntityGoal(net.minecraft.entity.ai.goal.LookAtEntityGoal) GolemEntity(net.minecraft.entity.passive.GolemEntity) PlayerEntity(net.minecraft.entity.player.PlayerEntity)

Aggregations

LookAtEntityGoal (net.minecraft.entity.ai.goal.LookAtEntityGoal)48 PlayerEntity (net.minecraft.entity.player.PlayerEntity)48 RevengeGoal (net.minecraft.entity.ai.goal.RevengeGoal)42 MerchantEntity (net.minecraft.entity.passive.MerchantEntity)42 LookAroundGoal (net.minecraft.entity.ai.goal.LookAroundGoal)37 WanderAroundFarGoal (net.minecraft.entity.ai.goal.WanderAroundFarGoal)33 RangedAttackGoal (mod.azure.doom.entity.ai.goal.RangedAttackGoal)12 DemonAttackGoal (mod.azure.doom.entity.ai.goal.DemonAttackGoal)10 RangedStrafeAttackGoal (mod.azure.doom.entity.ai.goal.RangedStrafeAttackGoal)8 RandomFlyConvergeOnTargetGoal (mod.azure.doom.entity.ai.goal.RandomFlyConvergeOnTargetGoal)7 FireballAttack (mod.azure.doom.entity.attack.FireballAttack)7 ServerPlayerEntity (net.minecraft.server.network.ServerPlayerEntity)7 AbstractRangedAttack (mod.azure.doom.entity.attack.AbstractRangedAttack)4 ActiveTargetGoal (net.minecraft.entity.ai.goal.ActiveTargetGoal)4 SwimGoal (net.minecraft.entity.ai.goal.SwimGoal)4 UUID (java.util.UUID)2 IronGolemEntity (net.minecraft.entity.passive.IronGolemEntity)2 Lists (com.google.common.collect.Lists)1 FlyRandomlyGoal (frozenblock.wild.mod.liukrastapi.FlyRandomlyGoal)1 List (java.util.List)1