Java Code Examples for net.minecraft.entity.EntityLivingBase#getEntityAttribute()

The following examples show how to use net.minecraft.entity.EntityLivingBase#getEntityAttribute() . You can vote up the ones you like or vote down the ones you don't like, and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source File: EntityUtil.java    From EnderZoo with Creative Commons Zero v1.0 Universal 5 votes vote down vote up
public static IAttributeInstance removeModifier(EntityLivingBase ent, IAttribute p, UUID u) {
  IAttributeInstance att = ent.getEntityAttribute(p);
  AttributeModifier curmod = att.getModifier(u);
  if (curmod != null) {
    att.removeModifier(curmod);
  }
  return att;
}