Package net.minecraft.util

Examples of net.minecraft.util.EntityDamageSource


    private boolean magicDamage = false;
    private boolean explosion = false;
   
    public static DamageSource causeSwarmDamage(EntityLivingBase par0EntityLiving)
    {
        return new EntityDamageSource("swarm", par0EntityLiving);
    }
View Full Code Here


        return new EntityDamageSource("swarm", par0EntityLiving);
    }

    public static DamageSource causeTentacleDamage(EntityLivingBase par0EntityLiving)
    {
        return new EntityDamageSource("tentacle", par0EntityLiving);
    }
View Full Code Here

    }

    @Override
    public boolean attackEntityAsMob(Entity par1Entity)
    {
        return par1Entity.attackEntityFrom(new EntityDamageSource("slimeling", this), this.getDamage());
    }
View Full Code Here

    @SubscribeEvent
    public void onLivingDeath(LivingDeathEvent event)
    {
        if (event.source.damageType.equals("slimeling") && event.source instanceof EntityDamageSource)
        {
            EntityDamageSource source = (EntityDamageSource) event.source;

            if (source.getEntity() instanceof EntitySlimeling && !source.getEntity().worldObj.isRemote)
            {
                ((EntitySlimeling) source.getEntity()).kills++;
            }
        }
    }
View Full Code Here

    ItemStack stack = itemInUse;

    if (par1Entity.canAttackWithItem()) {
      if (!par1Entity.hitByEntity(this)) {
        this.setLastAttacker(par1Entity);
        boolean flag2 = par1Entity.attackEntityFrom(new EntityDamageSource("robot", this), 2.0F);

        EnchantmentHelper.func_151385_b(this, par1Entity);
        ItemStack itemstack = itemInUse;
        Object object = par1Entity;
View Full Code Here

    private boolean magicDamage = false;
    private boolean explosion = false;
   
    public static DamageSource causeSwarmDamage(EntityLivingBase par0EntityLiving)
    {
        return new EntityDamageSource("swarm", par0EntityLiving);
    }
View Full Code Here

        return new EntityDamageSource("swarm", par0EntityLiving);
    }

    public static DamageSource causeTentacleDamage(EntityLivingBase par0EntityLiving)
    {
        return new EntityDamageSource("tentacle", par0EntityLiving);
    }
View Full Code Here

TOP

Related Classes of net.minecraft.util.EntityDamageSource

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.