private void SetWeapon(SkillPath.Weapon weapon) { if (weapon == SkillPath.Weapon.BOW) { bow.SetActive(true); sword.SetActive(false); staff.SetActive(false); } else if (weapon == SkillPath.Weapon.SWORD) { bow.SetActive(false); sword.SetActive(true); staff.SetActive(false); } else { bow.SetActive(false); sword.SetActive(false); staff.SetActive(true); } }
private void CreateBlankSkillJson(SkillPath.Weapon weapon, SkillPath.Special special) { string skillsString = JsonUtility.ToJson(new SkillPath(weapon, special)); File.WriteAllText(Path.Combine(Application.dataPath, "skills", "blank.json"), skillsString); }