Beispiel #1
0
        public IEnumerator Panic(int player, int target, Drop drop, int cardIndex)
        {
            PlayerController pc       = playerControllers[player];
            PlayerController targetPc = playerControllers[target];
            Card             c        = null;

            switch (drop)
            {
            case Drop.Hand:
                if (target == player)
                {
                    c = null;
                }
                else
                {
                    c = targetPc.StealCardFromHand(cardIndex);
                }
                break;

            case Drop.Properties:
                c = targetPc.UnequipProperty(cardIndex);
                break;

            case Drop.Weapon:
                c = targetPc.UnequipWeapon();
                break;
            }
            pc.DiscardCardUsed();
            if (c != null)
            {
                pc.AddCard(c);
            }
            yield return(targetPc.StolenBy(player));
        }
Beispiel #2
0
        public IEnumerator CatBalou(int player, int target, Drop drop, int cardIndex)
        {
            PlayerController pc       = playerControllers[player];
            PlayerController targetPc = playerControllers[target];
            Card             c        = null;

            switch (drop)
            {
            case Drop.Hand:
                if (player == target && cardIndex < pc.DraggedCardIndex)
                {
                    pc.DraggedCardIndex--;
                }
                c = targetPc.StealCardFromHand(cardIndex);
                break;

            case Drop.Properties:
                c = targetPc.UnequipProperty(cardIndex);
                break;

            case Drop.Weapon:
                c = targetPc.UnequipWeapon();
                break;
            }
            pc.DiscardCardUsed();
            DiscardCard(c);
            yield return(targetPc.StolenBy(player));
        }
Beispiel #3
0
        public void StealWeapon(int player, int target)
        {
            PlayerController pc       = playerControllers[player];
            PlayerController targetPc = playerControllers[target];
            Card             c        = targetPc.UnequipWeapon();

            pc.AddCard(c);
            targetPc.StolenBy(player);
        }