public boolean shouldExecute() { return this.entity.onGround && super.shouldExecute(); } }
@Override public boolean shouldExecute() { return !antlion.isInsideOfMaterial(Material.SAND) && super.shouldExecute(); }
public boolean shouldExecute(){ return !worm.isInSand() && super.shouldExecute(); }
public boolean shouldExecute(){ return !this.entity.isInWater() && !((EntitySiren)entity).isSinging() && super.shouldExecute(); }
public boolean shouldExecute(){ return !(entity instanceof EntityTameable && ((EntityTameable) entity).isSitting()) && !this.entity.isInWater() && super.shouldExecute(); }
/** * Returns whether the EntityAIBase should begin execution. */ public boolean shouldExecute() { if (Netherfish.this.getAttackTarget() != null) { return false; } else if (!Netherfish.this.getNavigator().noPath()) { return false; } else { Random random = Netherfish.this.getRNG(); if (Configs.isEnabled(NetherfishSpawnConfig.class) && random.nextInt(10) == 0) { this.field_179483_b = EnumFacing.random(random); BlockPos blockpos = (new BlockPos(Netherfish.this.posX, Netherfish.this.posY + 0.5D, Netherfish.this.posZ)).offset(this.field_179483_b); int meta = NetherfishSpawn.getInstance().getMetadataFromBlock(Netherfish.this.world.getBlockState(blockpos).getBlock()); if (meta >= 0) { this.field_179484_c = true; return true; } } this.field_179484_c = false; return super.shouldExecute(); } }
@Override public boolean shouldExecute() { if(!endermite.getEntityWorld().getGameRules().getBoolean("mobGriefing")) return false; else if(endermite.getAttackTarget() != null) return false; else if(!endermite.getNavigator().noPath()) return false; else { Random random = endermite.getRNG(); if(random.nextInt(EndermitesIntoShulkers.chance) == 0) { facing = EnumFacing.random(random); BlockPos blockpos = (new BlockPos(endermite.posX, endermite.posY + 0.5D, endermite.posZ)).offset(facing); IBlockState iblockstate = endermite.getEntityWorld().getBlockState(blockpos); if(iblockstate.getBlock() == Blocks.PURPUR_BLOCK) { doMerge = true; return true; } } doMerge = false; return super.shouldExecute(); } }