コード例 #1
0
ファイル: GameController.cs プロジェクト: grgkemp/7drl
    private GameObject CardFromEntity(GameObject representation)
    {
        GameObject       card        = Instantiate(cardObject);
        CardUIController cardControl = card.GetComponent <CardUIController>();

        cardControl.representation = representation;

        return(card);
    }
コード例 #2
0
    public CardUIController AddEntry(Card source)
    {
        CardUIController newEntry = Instantiate(LeaderCardPrefab).GetComponent <CardUIController>();

        newEntry.SourceCard = source;
        newEntry.UpdateUI();
        cards.Add(newEntry);
        return(newEntry);
    }