📌  相关文章
📜  在游戏对象 Unity 中显示列表 - 无论代码示例

📅  最后修改于: 2022-03-11 14:57:27.884000             🧑  作者: Mango

代码示例2
public List Deck = new List(); // im assuming Deck is your list with prefabs?
public List CreatedCards = new List();

void Start()
{
     Fill();
}

public void Fill()
{
    foreach(GameObject _go in Deck)
    {
        GameObject _newCard = (GameObject)Instantiate(_go);
        CreatedCards.Add(_newCard);
    }
}