void UpdateUIAttackDefenseElement(AttackDefenseType t, List <AttDefType> l, string value, bool onText1 = false) { AttDefType s1 = weaponInfo.GetAttDefSlot(l, t); if (!onText1) { s1.slot.text2.text = value; } else { s1.slot.text1.text = value; } }
void CreateAttDefUIElement_Mini(List <AttDefType> l, Transform p, AttackDefenseType t) { AttDefType a = new AttDefType(); a.type = t; l.Add(a); GameObject g = Instantiate(weaponInfo.slot_mini) as GameObject; g.transform.SetParent(p); a.slot = g.GetComponent <InventoryUISlot>(); a.slot.text1.text = "-"; g.SetActive(true); g.transform.localScale = Vector3.one; }