Search in sources :

Example 1 with RangeAgentAITask

use of org.spongepowered.api.entity.ai.task.builtin.creature.RangeAgentAITask in project SpongeCommon by SpongePowered.

the class SpongeRangeAgentAIBuilder method build.

@Override
public RangeAgentAITask build(Ranger owner) {
    checkNotNull(owner);
    checkArgument(owner instanceof IRangedAttackMob, "Ranger must be an IRangedAttackMob!");
    return (RangeAgentAITask) new EntityAIAttackRanged((IRangedAttackMob) owner, this.maxSpeed, this.delayBetweenAttacks, this.attackRadius);
}
Also used : EntityAIAttackRanged(net.minecraft.entity.ai.EntityAIAttackRanged) RangeAgentAITask(org.spongepowered.api.entity.ai.task.builtin.creature.RangeAgentAITask) IRangedAttackMob(net.minecraft.entity.IRangedAttackMob)

Aggregations

IRangedAttackMob (net.minecraft.entity.IRangedAttackMob)1 EntityAIAttackRanged (net.minecraft.entity.ai.EntityAIAttackRanged)1 RangeAgentAITask (org.spongepowered.api.entity.ai.task.builtin.creature.RangeAgentAITask)1