Example #1
0
    public void RemoveCard(ThreatLevel threatLevel)
    {
        var array    = threatStack.ToArray();
        var newStack = new Queue <ThreatCard>();

        if (threatLevel == ThreatLevel.High)
        {
            array[0] = new ThreatCard(null, Card_basicBackground);
        }
        else
        {
            array[1] = new ThreatCard(null, Card_basicBackground);
        }

        newStack.Enqueue(array[0]);
        newStack.Enqueue(array[1]);
        threatStack = newStack;

        foreach (var item in threatStack)
        {
            Debug.Log(item);
        }

        imageUpdateUI();
    }
Example #2
0
    public void MoveOntoThreatStack(ICard card, Texture2D cardTexture)
    {
        if (card == null)
        {
            cardTexture = Card_basicBackground;
        }
        ThreatCard item = new ThreatCard(card, cardTexture);

        threatStack.Enqueue(item);
        imageUpdateUI();
    }