void Awake() { if (instance == null) { instance = this; } else { Destroy(gameObject); } }
void UpdateStats(string name, float value, float fval) { StatsText.GetComponent <Text>().text = $"Name: {PlayerStats.name}\nLevel: {PlayerStats.level}\nEXP: {Mathf.Floor(PlayerStats.exp)}/{Mathf.Floor(PlayerStats.maxExp)}\nMana: {Mathf.Floor(PlayerStats.mana)}/{Mathf.Floor(PlayerStats.maxMana)}\nArmor Multipier: {PlayerStats.multiArmorA}\nMagic Level: {Mathf.Floor(PlayerStats.magicLevel)}\nWeapon Level: {Mathf.Floor(PlayerStats.weaponDamage)}\nReputation {Mathf.Floor(PlayerStats.reputation)}"; }