public void InitState(GameState gameState)
 {
     levelType.InitState(gameState);
     foreach (KeyValuePair<MinionType, Point> kv in scenery)
     {
         gameState.CreateMinion(kv.Key, false, kv.Value);
     }
     MinionAnimationSequence anim = new MinionAnimationSequence();
     foreach (KeyValuePair<Card, Point> kv in ongoingEffects)
     {
         gameState.PlayCard(kv.Key, null, TriggerItem.create(kv.Value), anim);
     }
 }
        public void PlayTurn(Card c, Minion caster, TriggerItem target)
        {
            if (c.effect != null && c.effect is Effect_Rewind)
            {
                if (gameStates.Count <= 1)
                    return;
                // rewind isn't really a spell like everything else
                gameStates.RemoveAt(gameStates.Count - 1);
                gameStateOnSkip = gameStates.Last().GetGameStateOnSkip();
                selectionState = new UISelectionState(gameStates.Last());
            }
            else
            {
                GameState oldGameState = gameStates.Last();
                if (oldGameState.CanPlayCard(c, target))
                {
                    nextGameState = new GameState(gameStates.Last());

                    animation.Clear();
                    if (caster == null)
                        caster = nextGameState.wizard;

                    nextGameState.PlayCard(c, caster, nextGameState.Adapt(target), animation);
                    nextGameState.TurnEffects(animation);

                    gameStateOnSkip = nextGameState.GetGameStateOnSkip();
                }
            }
        }