public AbilitiesWindow(Anchor anchor, float width, float height) : base(anchor, width, height, true) { InputListeners.Input.MouseListener.Push(new MouseListener()); AddChild(new CustomText(Anchor.AutoCenter, TITLE.ToString())); var owner = GameProcess.Instance.Player; foreach (var ability in owner.Abilities) { AddChild(new AbilityControlViewer(owner, ability, Anchor.AutoCenter, 1f, .1f)); } }
public QuestStateFilter(Anchor anchor, float width, float height) : base(anchor, width, height) { foreach (var type in (QuestState[])Enum.GetValues(typeof(QuestState))) { var text = new TextPointer("questState", type.ToString()); AddChild(new Button(Anchor.AutoInlineIgnoreOverflow, new Vector2(.25f, 1f), text.ToString()) { OnPressed = _ => OnPressFilter?.Invoke(type), }); } }