public ActionButton(string name, Texture2D buttonImage, MoveCategories moveCategory, ActionSubMenu subMenu) { Name = name; ButtonImage = buttonImage; Category = moveCategory; SubMenu = subMenu; }
protected PlayerBattleMenu(PlayerTypes playerType) : base(MenuTypes.Horizontal) { PlayerType = playerType; Texture2D battleGFX = AssetManager.Instance.LoadRawTexture2D($"{ContentGlobals.BattleGFX}.png"); SwitchIcon = new CroppedTexture2D(battleGFX, new Rectangle(651, 13, 78, 30)); CroppedTexture2D tacticsButton = new CroppedTexture2D(battleGFX, new Rectangle(146, 844, 24, 24)); CroppedTexture2D itemsButton = new CroppedTexture2D(battleGFX, new Rectangle(146, 812, 24, 24)); ActionButtons.Add(new ActionButton("Tactics", tacticsButton, MoveCategories.Tactics, new TacticsSubMenu())); ActionSubMenu itemMenu = null; if (CheckUseDipMenu() == false) { itemMenu = new ItemSubMenu(1, 0); } else { itemMenu = new ItemDipSubMenu(); } ActionButtons.Add(new ActionButton("Items", itemsButton, MoveCategories.Item, itemMenu)); }
public PartnerBattleMenu(BattleEntity user, ActionSubMenu partnerSubMenu, PartnerTypes partnerType) : base(user) { PartnerSubMenu = partnerSubMenu; PartnerType = partnerType; Texture2D abilityTex = AssetManager.Instance.LoadRawTexture2D($"{ContentGlobals.BattleGFX}.png"); CroppedTexture2D partnerIcon = new CroppedTexture2D(abilityTex, new Rectangle(30 + (((int)PartnerType - 1) * 32), 886, 32, 32)); ActionButtons.Add(new ActionButton("Abilities", partnerIcon, MoveCategories.Partner, PartnerSubMenu)); //Add Focus to the Partner battle menu if the Group Focus badge is equipped int groupFocusCount = User.GetEquippedBadgeCount(BadgeGlobals.BadgeTypes.GroupFocus); if (groupFocusCount > 0) { ActionSubMenu focusMenu = new ActionSubMenu(user, "Focus", new FocusAction(user)); focusMenu.AutoSelectSingle = true; CroppedTexture2D starPower = new CroppedTexture2D(abilityTex, new Rectangle(182, 812, 24, 24)); ActionButtons.Add(new ActionButton("Focus", starPower, MoveCategories.Special, focusMenu)); } Initialize(2); }
public MenuAction(BattleEntity user, string name, CroppedTexture2D icon, string description, ActionSubMenu subMenu) : base(user) { Name = name; MoveInfo = new MoveActionData(icon, description, MoveResourceTypes.FP, 0, CostDisplayTypes.Shown, MoveAffectionTypes.None, Enumerations.EntitySelectionType.Single, false, null); SubMenu = subMenu; }
public MenuAction(string name, CroppedTexture2D icon, string description, ActionSubMenu subMenu) { Name = name; MoveInfo = new MoveActionData(icon, description, MoveResourceTypes.FP, 0, CostDisplayTypes.Shown, MoveAffectionTypes.None, TargetSelectionMenu.EntitySelectionType.Single, false, null); SubMenu = subMenu; }
public PartnerBattleMenu(ActionSubMenu partnerSubMenu) : base(Enumerations.PlayerTypes.Partner) { PartnerSubMenu = partnerSubMenu; ActionButtons.Add(new ActionButton("Abilities", AssetManager.Instance.LoadAsset <Texture2D>("UI/Battle/JumpButton"), Enumerations.MoveCategories.Partner, PartnerSubMenu)); //Add Focus to the Partner battle menu if the Group Focus badge is equipped int groupFocusCount = BattleManager.Instance.EntityTurn.GetEquippedBadgeCount(BadgeGlobals.BadgeTypes.GroupFocus); if (groupFocusCount > 0) { ActionSubMenu focusMenu = new ActionSubMenu(new Focus()); focusMenu.AutoSelectSingle = true; ActionButtons.Add(new ActionButton("Focus", AssetManager.Instance.LoadAsset <Texture2D>("UI/Battle/JumpButton"), Enumerations.MoveCategories.Special, focusMenu)); } Initialize(2); }
protected PlayerBattleMenu(PlayerTypes playerType) : base(MenuTypes.Horizontal) { SwitchIcon = new CroppedTexture2D(AssetManager.Instance.LoadAsset <Texture2D>($"{ContentGlobals.UIRoot}/Battle/BattleGFX"), new Rectangle(651, 13, 78, 30)); PlayerType = playerType; ActionButtons.Add(new ActionButton("Tactics", AssetManager.Instance.LoadAsset <Texture2D>("UI/Battle/JumpButton"), MoveCategories.Tactics, new TacticsSubMenu())); ActionSubMenu itemMenu = null; if (CheckUseDipMenu() == false) { itemMenu = new ItemSubMenu(1, 0); } else { itemMenu = new ItemDipSubMenu(); } ActionButtons.Add(new ActionButton("Items", AssetManager.Instance.LoadAsset <Texture2D>("UI/Battle/JumpButton"), MoveCategories.Item, itemMenu)); }
/// <summary> /// This constructor is for showing the FP cost for a menu item (Ex. Double Dip and Triple Dip). /// </summary> /// <param name="name"></param> /// <param name="icon"></param> /// <param name="description"></param> /// <param name="fpCost"></param> /// <param name="subMenu"></param> public MenuAction(BattleEntity user, string name, CroppedTexture2D icon, string description, int fpCost, ActionSubMenu subMenu) : this(user, name, icon, description, subMenu) { MoveInfo.ResourceCost = fpCost; }
/// <summary> /// This constructor is for showing the FP cost for a menu item (Ex. Double Dip and Triple Dip). /// </summary> /// <param name="name"></param> /// <param name="icon"></param> /// <param name="description"></param> /// <param name="fpCost"></param> /// <param name="subMenu"></param> public MenuAction(string name, Texture2D icon, string description, int fpCost, ActionSubMenu subMenu) : this(name, icon, description, subMenu) { MoveInfo.ResourceCost = fpCost; }