public void InitDescript(IHotbar skill) { string s = ""; s = skill.GetName(); s += "\n" + skill.GetHotbarDescription(); skillDescript.text = s; }
public void InitButton(ActorData data, IHotbar content, BoardManager ifsm, SkillDescriptPanel panel) { this.data = data; this.content = content; this.ifsm = ifsm; this.skillDescript = panel; if (content != null) { icon.sprite = Globals.GetSprite(FilePath.IconSpriteAtlas, content.GetIconFilePath()); if (content is IUseable) { useable = (IUseable)content; } else if (content is Item) { Item t = (Item)content; if (t.HasConsumableEFfect()) { useable = t.GetConsumableEffect(); } else if (t.HasActivationEffect()) { useable = t.GetActivateableEffect(); } else { useable = null; } } else { useable = null; } } else { icon.sprite = Globals.GetSprite(FilePath.IconSpriteAtlas, "unkown"); useable = null; } }
public void Initbuttons(ToolbarButton buttons, IHotbar skill, ActorData data) { buttons.InitButton(data, skill, boardManager, skillDescriptPanel); }
public void Initbuttons(int index, List <ToolbarButton> buttons, IHotbar skill, ActorData data) { buttons[index].InitButton(data, skill, boardManager, skillDescriptPanel); }