当前位置: 首页>>代码示例>>Java>>正文


Java EntityAIArrowAttack类代码示例

本文整理汇总了Java中net.minecraft.entity.ai.EntityAIArrowAttack的典型用法代码示例。如果您正苦于以下问题:Java EntityAIArrowAttack类的具体用法?Java EntityAIArrowAttack怎么用?Java EntityAIArrowAttack使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。


EntityAIArrowAttack类属于net.minecraft.entity.ai包,在下文中一共展示了EntityAIArrowAttack类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: EntityWither

import net.minecraft.entity.ai.EntityAIArrowAttack; //导入依赖的package包/类
public EntityWither(World worldIn)
{
    super(worldIn);
    this.setHealth(this.getMaxHealth());
    this.setSize(0.9F, 3.5F);
    this.isImmuneToFire = true;
    ((PathNavigateGround)this.getNavigator()).setCanSwim(true);
    this.tasks.addTask(0, new EntityAISwimming(this));
    this.tasks.addTask(2, new EntityAIArrowAttack(this, 1.0D, 40, 20.0F));
    this.tasks.addTask(5, new EntityAIWander(this, 1.0D));
    this.tasks.addTask(6, new EntityAIWatchClosest(this, EntityPlayer.class, 8.0F));
    this.tasks.addTask(7, new EntityAILookIdle(this));
    this.targetTasks.addTask(1, new EntityAIHurtByTarget(this, false, new Class[0]));
    this.targetTasks.addTask(2, new EntityAINearestAttackableTarget(this, EntityLiving.class, 0, false, false, attackEntitySelector));
    this.experienceValue = 50;
}
 
开发者ID:Notoh,项目名称:DecompiledMinecraft,代码行数:17,代码来源:EntityWither.java

示例2: EntityHornedHuntsman

import net.minecraft.entity.ai.EntityAIArrowAttack; //导入依赖的package包/类
public EntityHornedHuntsman(World par1World) {
   super(par1World);
   this.setSize(1.4F, 3.2F);
   super.isImmuneToFire = true;
   this.getNavigator().setAvoidsWater(true);
   this.getNavigator().setCanSwim(true);
   super.tasks.addTask(1, new EntityAISwimming(this));
   super.tasks.addTask(2, new EntityAIAttackOnCollide(this, 1.0D, true));
   super.tasks.addTask(3, new EntityAIMoveTowardsTarget(this, 1.0D, 48.0F));
   super.tasks.addTask(4, new EntityAIArrowAttack(this, 1.0D, 20, 60, 30.0F));
   super.tasks.addTask(5, new EntityAIWander(this, 1.0D));
   super.tasks.addTask(6, new EntityAIWatchClosest(this, EntityPlayer.class, 6.0F));
   super.tasks.addTask(7, new EntityAILookIdle(this));
   super.targetTasks.addTask(1, new EntityAIHurtByTarget(this, false));
   super.targetTasks.addTask(2, new EntityAINearestAttackableTarget(this, EntityPlayer.class, 0, true));
   super.experienceValue = 70;
}
 
开发者ID:lerion13,项目名称:witchery,代码行数:18,代码来源:EntityHornedHuntsman.java

示例3: EntityNinjaMaster

import net.minecraft.entity.ai.EntityAIArrowAttack; //导入依赖的package包/类
public EntityNinjaMaster(World p_i1745_1_)
{
    super(p_i1745_1_);
    this.getNavigator().setBreakDoors(true);
    this.tasks.addTask(0, new EntityAISwimming(this));
    this.tasks.addTask(2, new EntityAIAttackOnCollide(this, EntityPlayer.class, 1.0D, false));
    this.tasks.addTask(4, new EntityAIAttackOnCollide(this, EntityVillager.class, 1.0D, true));
    this.tasks.addTask(5, new EntityAIMoveTowardsRestriction(this, 1.0D));
    this.tasks.addTask(6, new EntityAIMoveThroughVillage(this, 1.0D, false));
    this.tasks.addTask(7, new EntityAIWander(this, 1.0D));
    this.tasks.addTask(8, new EntityAIWatchClosest(this, EntityPlayer.class, 8.0F));
    this.tasks.addTask(8, new EntityAILookIdle(this));
    this.targetTasks.addTask(1, new EntityAIHurtByTarget(this, true));
    this.targetTasks.addTask(2, new EntityAINearestAttackableTarget(this, EntityPlayer.class, 0, true));
    //this.targetTasks.addTask(2, new EntityAINearestAttackableTarget(this, EntityVillager.class, 0, false));
    this.tasks.addTask(1, new EntityAIArrowAttack(this, 1.0D, 20, 60, 15.0F));

    this.setSize(0.6F, 1.8F);
}
 
开发者ID:jtrent238,项目名称:PopularMMOS-EpicProportions-Mod,代码行数:20,代码来源:EntityNinjaMaster.java

示例4: EntityLongbowGuard

import net.minecraft.entity.ai.EntityAIArrowAttack; //导入依赖的package包/类
public EntityLongbowGuard(World world){
	super(world);
	if (this.worldObj.difficultySetting == EnumDifficulty.EASY)
		this.tasks.addTask(1, new EntityAIAttackOnCollide(this, EntityPlayer.class, 1.0D, true));
	else
		this.tasks.addTask(1, new EntityAIArrowAttack(this, 1.0D, 20, 60, 15.0F));
	this.targetTasks.addTask(2, new EntityAINearestAttackableTarget(this, EntityCreature.class, 0, true, false, 
			new IEntitySelector() {
				public boolean isEntityApplicable(Entity entity) {
					if (!isLookingForHome && ((EntityCreature) entity).isWithinHomeDistanceCurrentPosition() && entity instanceof EntityZombie)
						return true;
					return false;
				}
		}));		        
	setGuardWeaponType(type);
}
 
开发者ID:DracoAnimus,项目名称:Coding,代码行数:17,代码来源:EntityLongbowGuard.java

示例5: EntityCrossbowGuard

import net.minecraft.entity.ai.EntityAIArrowAttack; //导入依赖的package包/类
public EntityCrossbowGuard(World world){
	super(world);
	if (this.worldObj.difficultySetting == EnumDifficulty.EASY)
		this.tasks.addTask(1, new EntityAIAttackOnCollide(this, EntityPlayer.class, 1.0D, true));
	else
		this.tasks.addTask(1, new EntityAIArrowAttack(this, 1.0D, 20, 60, 15.0F));
	this.targetTasks.addTask(2, new EntityAINearestAttackableTarget(this, EntityCreature.class, 0, true, false, 
			new IEntitySelector() {
				public boolean isEntityApplicable(Entity entity) {
					if (!isLookingForHome && ((EntityCreature) entity).isWithinHomeDistanceCurrentPosition() && entity instanceof EntityZombie)
						return true;
					return false;
				}
		}));		        
	setGuardWeaponType(type);
}
 
开发者ID:DracoAnimus,项目名称:Coding,代码行数:17,代码来源:EntityCrossbowGuard.java

示例6: EntityWither

import net.minecraft.entity.ai.EntityAIArrowAttack; //导入依赖的package包/类
public EntityWither(World par1World)
{
    super(par1World);
    this.setHealth(this.getMaxHealth());
    this.setSize(0.9F, 4.0F);
    this.isImmuneToFire = true;
    this.getNavigator().setCanSwim(true);
    this.tasks.addTask(0, new EntityAISwimming(this));
    this.tasks.addTask(2, new EntityAIArrowAttack(this, 1.0D, 40, 20.0F));
    this.tasks.addTask(5, new EntityAIWander(this, 1.0D));
    this.tasks.addTask(6, new EntityAIWatchClosest(this, EntityPlayer.class, 8.0F));
    this.tasks.addTask(7, new EntityAILookIdle(this));
    this.targetTasks.addTask(1, new EntityAIHurtByTarget(this, false));
    this.targetTasks.addTask(2, new EntityAINearestAttackableTarget(this, EntityLiving.class, 0, false, false, attackEntitySelector));
    this.experienceValue = 50;
}
 
开发者ID:MinecraftModdedClients,项目名称:Resilience-Client-Source,代码行数:17,代码来源:EntityWither.java

示例7: EntitySkeletalKnight

import net.minecraft.entity.ai.EntityAIArrowAttack; //导入依赖的package包/类
public EntitySkeletalKnight(World world) 
{
	super(world);
	setWeapon((byte)0);
	
	this.tasks.addTask(3, new EntityAIArrowAttack(this, 0.25F, 20, 60, 15.0F));
	this.tasks.addTask(3, new EntityAILeapAtTarget(this, 0.4F));
	
	this.tasks.addTask(0, new EntityAISwimming(this));
       this.tasks.addTask(1, new EntityAIBreakDoorAnimate(this));
       this.tasks.addTask(2, new EntityAIAttackOnCollide(this, EntityPlayer.class, 1.0D, false));
       this.tasks.addTask(3, new EntityAIAttackOnCollide(this, EntityLiving.class, 1.0D, true));
       this.tasks.addTask(5, new EntityAIMoveThroughVillage(this, 1.0D, false));
       this.tasks.addTask(6, new EntityAIWander(this, 1.0D));
       this.tasks.addTask(7, new EntityAIWatchClosest(this, EntityPlayer.class, 8.0F));
       this.tasks.addTask(7, new EntityAILookIdle(this));
       this.targetTasks.addTask(1, new EntityAIHurtByTarget(this, true));
       this.targetTasks.addTask(2, new EntityAINearestAttackableTarget(this, EntityPlayer.class, 0, true));
       
       this.equipmentDropChances[0] = 2.0F;
}
 
开发者ID:TheAwesomeGem,项目名称:MineFantasy,代码行数:22,代码来源:EntitySkeletalKnight.java

示例8: EntityWither

import net.minecraft.entity.ai.EntityAIArrowAttack; //导入依赖的package包/类
public EntityWither(World p_i1701_1_)
{
    super(p_i1701_1_);
    this.setHealth(this.getMaxHealth());
    this.setSize(0.9F, 4.0F);
    this.isImmuneToFire = true;
    this.getNavigator().setCanSwim(true);
    this.tasks.addTask(0, new EntityAISwimming(this));
    this.tasks.addTask(2, new EntityAIArrowAttack(this, 1.0D, 40, 20.0F));
    this.tasks.addTask(5, new EntityAIWander(this, 1.0D));
    this.tasks.addTask(6, new EntityAIWatchClosest(this, EntityPlayer.class, 8.0F));
    this.tasks.addTask(7, new EntityAILookIdle(this));
    this.targetTasks.addTask(1, new EntityAIHurtByTarget(this, false));
    this.targetTasks.addTask(2, new EntityAINearestAttackableTarget(this, EntityLiving.class, 0, false, false, attackEntitySelector));
    this.experienceValue = 50;
}
 
开发者ID:xtrafrancyz,项目名称:Cauldron,代码行数:17,代码来源:EntityWither.java

示例9: EntityIsaacNormal

import net.minecraft.entity.ai.EntityAIArrowAttack; //导入依赖的package包/类
public EntityIsaacNormal(World par1World) {
    super(par1World);
    isImmuneToFire = true;
    setSize(0.6F, 1.8F);
    moveSpeed = 0.25F;
    tasks.addTask(1, new EntityAISwimming(this));
    tasks.addTask(2, new EntityAIRestrictSun(this));
    tasks.addTask(3, new EntityAIFleeSun(this, moveSpeed));
    tasks.addTask(5, new EntityAIWander(this, moveSpeed));
    tasks.addTask(6, new EntityAIWatchClosest(this, EntityPlayer.class, 8.0F));
    tasks.addTask(6, new EntityAILookIdle(this));
    targetTasks.addTask(1, new EntityAIHurtByTarget(this, false));
    targetTasks.addTask(2, new EntityAINearestAttackableTarget(this, EntityPlayer.class, 0, true));
    if (!par1World.isRemote) {
        tasks.addTask(1, new EntityAIArrowAttack(this, moveSpeed, 18, 50F));
    }
}
 
开发者ID:sirolf2009,项目名称:Necromancy,代码行数:18,代码来源:EntityIsaacNormal.java

示例10: EntityBehlmann

import net.minecraft.entity.ai.EntityAIArrowAttack; //导入依赖的package包/类
public EntityBehlmann(World par1World) {
	super(par1World);
	this.texture = AmitReference.Sprites.MOB_TEXTURE_PATH + "behlmann.png";
	this.moveSpeed = this.stepHeight = 1.0F;

	this.getNavigator().setAvoidsWater(true);
	this.getNavigator().setCanSwim(true);

	this.tasks.addTask(1, new EntityAIArrowAttack(this, 0.25F, 20, 10.0F));
	this.tasks.addTask(2, new EntityAIAttackOnCollide(this, 0.25F, true));
	this.tasks.addTask(3, new EntityAIMoveTowardsTarget(this, 0.22F, 32.0F));
	this.tasks.addTask(4, new EntityAIMoveThroughVillage(this, 0.16F, true));
	this.tasks.addTask(5, new EntityAIMoveTwardsRestriction(this, 0.16F));
	this.tasks.addTask(6, new EntityAIWander(this, 0.16F));
	this.tasks.addTask(7, new EntityAIWatchClosest(this, EntityPlayer.class, 6.0F));
	this.tasks.addTask(8, new EntityAILookIdle(this));
	this.tasks.addTask(9, new EntityAIPanic(this, 0.38F));
	this.tasks.addTask(10, new EntityAITempt(this, 0.25F, Block.brewingStand.blockID, false));
	this.targetTasks.addTask(1, new EntityAIHurtByTarget(this, false));
	this.targetTasks.addTask(1, new EntityAINearestAttackableTarget(this, EntityAnimal.class, 16.0F, 0, false));
}
 
开发者ID:DrDew2,项目名称:Amitcraft,代码行数:22,代码来源:EntityBehlmann.java

示例11: EntityTComp

import net.minecraft.entity.ai.EntityAIArrowAttack; //导入依赖的package包/类
public EntityTComp(World par1World) {
	super(par1World);
	this.texture = AmitReference.Sprites.MOB_TEXTURE_PATH + "TComp.png";
	this.moveSpeed = this.stepHeight = 1.0F;

	this.moveSpeed = 0.75F;
	this.stepHeight = 2.0F;

	this.getNavigator().setBreakDoors(true);
	this.getNavigator().setAvoidsWater(true);
	this.tasks.addTask(0, new EntityAISwimming(this));
	this.tasks.addTask(1, new EntityAIArrowAttack(this, 0.25F, 20, 10.0F));
	this.tasks.addTask(1, new EntityAIWander(this, 0.3F));
	this.tasks.addTask(2, new EntityAIAvoidEntity(this, EntityZombie.class, 8.0F, 0.3F, 0.35F));
	this.tasks.addTask(3, new EntityAIMoveIndoors(this));
	this.tasks.addTask(4, new EntityAIRestrictOpenDoor(this));
	this.tasks.addTask(5, new EntityAIOpenDoor(this, true));
	this.tasks.addTask(6, new EntityAIMoveTwardsRestriction(this, 0.3F));
	this.tasks.addTask(7, new EntityAIWatchClosest2(this, EntityPlayer.class, 3.0F, 1.0F));
	this.tasks.addTask(8, new EntityAIWatchClosest2(this, EntityCow.class, 5.0F, 0.02F));
	this.tasks.addTask(9, new EntityAIWatchClosest(this, EntityLiving.class, 8.0F));
	this.targetTasks.addTask(1, new EntityAIHurtByTarget(this, true));
	this.targetTasks.addTask(2, new EntityAINearestAttackableTarget(this, EntityMob.class, 16.0F, 0, false));
	this.targetTasks.addTask(3, new EntityAINearestAttackableTarget(this, EntityCreeper.class, 16.0F, 0, false));
	this.targetTasks.addTask(4, new EntityAINearestAttackableTarget(this, EntityLiving.class, 16.0F, 0, false, true, IMob.mobSelector));
}
 
开发者ID:DrDew2,项目名称:Amitcraft,代码行数:27,代码来源:EntityTComp.java

示例12: EntitySnowman

import net.minecraft.entity.ai.EntityAIArrowAttack; //导入依赖的package包/类
public EntitySnowman(World worldIn)
{
    super(worldIn);
    this.setSize(0.7F, 1.9F);
    ((PathNavigateGround)this.getNavigator()).setAvoidsWater(true);
    this.tasks.addTask(1, new EntityAIArrowAttack(this, 1.25D, 20, 10.0F));
    this.tasks.addTask(2, new EntityAIWander(this, 1.0D));
    this.tasks.addTask(3, new EntityAIWatchClosest(this, EntityPlayer.class, 6.0F));
    this.tasks.addTask(4, new EntityAILookIdle(this));
    this.targetTasks.addTask(1, new EntityAINearestAttackableTarget(this, EntityLiving.class, 10, true, false, IMob.mobSelector));
}
 
开发者ID:Notoh,项目名称:DecompiledMinecraft,代码行数:12,代码来源:EntitySnowman.java

示例13: EntityWitch

import net.minecraft.entity.ai.EntityAIArrowAttack; //导入依赖的package包/类
public EntityWitch(World worldIn)
{
    super(worldIn);
    this.setSize(0.6F, 1.95F);
    this.tasks.addTask(1, new EntityAISwimming(this));
    this.tasks.addTask(2, new EntityAIArrowAttack(this, 1.0D, 60, 10.0F));
    this.tasks.addTask(2, new EntityAIWander(this, 1.0D));
    this.tasks.addTask(3, new EntityAIWatchClosest(this, EntityPlayer.class, 8.0F));
    this.tasks.addTask(3, new EntityAILookIdle(this));
    this.targetTasks.addTask(1, new EntityAIHurtByTarget(this, false, new Class[0]));
    this.targetTasks.addTask(2, new EntityAINearestAttackableTarget(this, EntityPlayer.class, true));
}
 
开发者ID:Notoh,项目名称:DecompiledMinecraft,代码行数:13,代码来源:EntityWitch.java

示例14: EntityEvolvedSkeleton

import net.minecraft.entity.ai.EntityAIArrowAttack; //导入依赖的package包/类
public EntityEvolvedSkeleton(World par1World)
{
    super(par1World);
    this.tasks.addTask(1, new EntityAISwimming(this));
    this.tasks.addTask(2, new EntityAIRestrictSun(this));
    this.tasks.addTask(3, new EntityAIFleeSun(this, 0.25F));
    this.tasks.addTask(4, new EntityAIArrowAttack(this, 0.25F, 25, 20));
    this.tasks.addTask(5, new EntityAIWander(this, 0.25F));
    this.tasks.addTask(6, new EntityAIWatchClosest(this, EntityPlayer.class, 8.0F));
    this.tasks.addTask(6, new EntityAILookIdle(this));
    this.targetTasks.addTask(1, new EntityAIHurtByTarget(this, false));
    this.targetTasks.addTask(2, new EntityAINearestAttackableTarget(this, EntityPlayer.class, 0, true));
    this.setSize(0.7F, 2.5F);
}
 
开发者ID:4Space,项目名称:4Space-5,代码行数:15,代码来源:EntityEvolvedSkeleton.java

示例15: EntitySnowCube

import net.minecraft.entity.ai.EntityAIArrowAttack; //导入依赖的package包/类
public EntitySnowCube(World p_i1692_1_)
{
    super(p_i1692_1_);
    this.setSize(0.4F, 1.8F);
    this.getNavigator().setAvoidsWater(true);
    this.tasks.addTask(1, new EntityAIArrowAttack(this, 1.25D, 1, 10.0F));
    this.tasks.addTask(2, new EntityAIWander(this, 1.0D));
    this.tasks.addTask(3, new EntityAIWatchClosest(this, EntityPlayer.class, 6.0F));
    this.tasks.addTask(4, new EntityAILookIdle(this));
    this.targetTasks.addTask(1, new EntityAINearestAttackableTarget(this, EntityLiving.class, 0, true, false, IMob.mobSelector));
}
 
开发者ID:GhostMonk3408,项目名称:MidgarCrusade,代码行数:12,代码来源:EntitySnowCube.java


注:本文中的net.minecraft.entity.ai.EntityAIArrowAttack类示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。