protected Skill_Framework_old(SkillData dataWorking) { _dataWorking = dataWorking; _dataDefault = (SkillData) _dataWorking.Clone(); _timerCooldown = new FwTimer(TimeCooldown); // for timer init _timerBlock = new FwTimer(_dataDefault.TimeBlocked); // remade to this class property _playerLevelCurrent = 1; }
protected Skill_Framework_old() { _dataWorking = new SkillData(); FillSkillData(); // abstract _dataDefault = (SkillData)_dataWorking.Clone(); initTimers(); _playerLevelCurrent = 1; }
public void Init(SkillData dt) { data = (SkillData)dt.Clone(); img.sprite = data.spr; int lang = (int)GameManager.language; string name = data.nameLang?[lang]; txt.text = name != null ? name : dt.name; }
public void Init(SkillData dt) { if (_skill) { Destroy(_skill); } string str = string.Format("RogueNaraka.SkillScripts.{0}", dt.name); System.Type type = System.Type.GetType(str); _skill = gameObject.AddComponent(type) as Skill; _skill.Init((SkillData)dt.Clone(), this); img.sprite = _skill.data.spr; SyncCoolImg(); SyncCoolText(); isCool = true; img.color = Color.white; levelTxt.text = string.Format("+{0}", _skill.data.level); levelTxt.enabled = true; }
public void Init(SkillData dt, SkillGUI gui) { _data = (SkillData)dt.Clone(); this.gui = gui; }