@Override public void readEntityFromNBT(NBTTagCompound compound) { super.readEntityFromNBT(compound); if (compound.hasKey("fly_stack")) { stack = ItemStack.loadItemStackFromNBT(compound.getCompoundTag("fly_stack")); } setFire(compound.getBoolean("flare")); }
@Override public void readEntityFromNBT(NBTTagCompound compound) { super.readEntityFromNBT(compound); dataWatcher.updateObject(HIT_POS_X, compound.getFloat("hitPosX")); dataWatcher.updateObject(HIT_POS_Y, compound.getFloat("hitPosY")); dataWatcher.updateObject(HIT_POS_Z, compound.getFloat("hitPosZ")); hitX = compound.getInteger("hitX"); hitY = compound.getInteger("hitY"); hitZ = compound.getInteger("hitZ"); // retrieving owner name saved by super-class EntityThrowable dataWatcher.updateObject(THROWER_INDEX, compound.getString("ownerName")); dataWatcher.updateObject( WHIP_TYPE_INDEX, WhipType.values()[compound.getInteger("whipType") % WhipType.values().length]); dataWatcher.updateObject(IN_GROUND_INDEX, compound.getByte("customInGround")); }
@Override public void readEntityFromNBT(NBTTagCompound par1NBTTagCompound) { super.readEntityFromNBT(par1NBTTagCompound); this.mID = par1NBTTagCompound.getInteger("metType"); this.isRandom = par1NBTTagCompound.getBoolean("isRandom"); }
public void readEntityFromNBT(NBTTagCompound tagcompound) { super.readEntityFromNBT(tagcompound); }