void OnEnable() { Slot = (EQUIPTYPE)int.Parse(gameObject.name); MPC = transform.parent.parent.GetComponent <Tab_0>().MPC; EI = transform.parent.parent.Find("EquipmentInfo").GetComponent <EquipmentInfo>(); UpdateSlot(); }
public virtual void UnEquip(EQUIPTYPE Slot) { Destroy(EquipPrefabs[(int)Slot]); PlayerData.Equipments[(int)Slot] = new Equipment(); UpdateStats(); //CacheManager.SaveCurrentPlayerInfo(); }
public override void UnEquip(EQUIPTYPE Slot) { if (Client.Connected) { Client.Send(Protocols.UnEquipAction, new UnEquipActionData(Client.ClientID, (int)Slot)); base.UnEquip(Slot); } else { base.UnEquip(Slot); SaveDevelopingPlayerData(); } }
public Equipment(string name, EQUIPTYPE etype) : base(name) { EType = etype; }
public void UpdateEquippedSlot(EQUIPTYPE slot) { CSC.Tab_0.transform.Find("EquippedSlotButtons/" + (int)slot).GetComponent <EquippedButtonController>().UpdateSlot(); }
public Equipment GetEquippedItem(EQUIPTYPE Slot) { return(PlayerData.Equipments[(int)Slot]); }