Exemplo n.º 1
0
        public override void SelectAction(GameAction a)
        {
            if (a.ID == -2)
            {
                MyGame.MyExecutor.UndoUntilMarker(CommandMarkerType.StartActivating);
                MyGame.EnterAllInputStates();
                return;
            }
            MyGame.MyExecutor.Do(ActionCommandPairs[a.ID]);

            if (MyActivatable.MyCost.IsManaPaid())
            {
                MyGame.PlayActivatable(MyActivatable, MyPlayer.Value(MyGame), Mode);
                MyGame.MyExecutor.Do(new CommandGroup(
                                         new CommandSetIsActivating(MyActivatable.Host.ID, activatableIndex, false, Mode),
                                         new CommandResetManaCost(MyPlayer.ID),
                                         new CommandRemoveTopInputStates(MyPlayer.ID, 3),
                                         new CommandSetHavePriorityState(MyPlayer.ID),
                                         new CommandEnterInputState()));
            }
            else
            {
                PromptAndRequestAction();
            }
        }
Exemplo n.º 2
0
        public override void SelectAction(GameAction a)
        {
            if (a.ID == -2)
            {
                MyGame.MyExecutor.UndoUntilMarker(CommandMarkerType.StartActivating);
                MyGame.EnterAllInputStates();
                return;
            }

            MyGame.MyExecutor.Do(ActionCommandPairs[a.ID]);
            if (MyActivatable.MyTargeting.IsFinished())
            {
                MoveToActionPayment();
                return;
            }

            PromptAndRequestAction();
        }
Exemplo n.º 3
0
        public override void SelectAction(GameAction a)
        {
            if (a.ID == -2)
            {
                MyGame.MyExecutor.UndoUntilMarker(CommandMarkerType.StartActivating);
                MyGame.EnterAllInputStates();
                return;
            }

            MyGame.MyExecutor.Do(ActionCommandPairs[a.ID]);

            if (MyActivatable.MyCost.AreActionsPaid())
            {
                MoveToManaPayment();
            }
            else
            {
                MyGame.MyExecutor.Do(new CommandIncrementActionPartIndex(MyPlayer.ID));

                PromptAndRequestAction();
            }
        }