Exemple #1
0
    public void PullCard(int index)
    {
        // TODO show card draw effect

        Cards[index].gameObject.SetActive(true);
        Cards[index].sprite =
            CardDataParser.GetCard(CardSet.Hands[index]).cardFXData.cardSprite;
    }
    public static bool UseCard(byte rotation)
    {
        if (_handFlags[CodeToIdx[rotation]])
        {
            _usedCards.Add(Hands[CodeToIdx[rotation]]);
            CardDataParser.GetCard(Hands[CodeToIdx[rotation]]).Active();
            _handFlags[CodeToIdx[rotation]] = false;
            CardMover.Instance.UseCard(CodeToIdx[rotation]);
            return(true);
        }

        return(false);
    }