use of de.sanandrew.mods.claysoldiers.util.soldier.upgrade.ASoldierUpgrade in project ClaySoldiersMod by SanAndreasP.
the class ClientProxy method applyUpgradeNbt.
@Override
public void applyUpgradeNbt(int entityId, byte upgradeRenderId, NBTTagCompound nbt) {
Entity entity = Minecraft.getMinecraft().theWorld.getEntityByID(entityId);
if (entity instanceof EntityClayMan) {
EntityClayMan pahimar = (EntityClayMan) entity;
ASoldierUpgrade upgrade = SoldierUpgrades.getUpgrade(upgradeRenderId);
if (pahimar.hasUpgrade(upgrade)) {
pahimar.getUpgrade(upgrade).setNbtTag(nbt);
} else {
pahimar.addUpgrade(upgrade).setNbtTag(nbt);
}
}
}
Aggregations