public EntityInventory(EntityLiving holder, int slot) : base(holder) { this.armor = new EntityArmorInventory(holder); this.offhand = new EntityOffhandInventory(holder); this.slot = slot; }
public EntityInventory(EntityLiving holder, int slot) : base(holder) { if (!holder.NamedTag.Exist("Mainhand")) { holder.NamedTag.PutInt("Mainhand", 0); } this.mainHand = holder.NamedTag.GetInt("Mainhand"); this.armor = new EntityArmorInventory(holder); this.offhand = new EntityOffhandInventory(holder); this.slot = slot; }