📅  最后修改于: 2022-03-11 14:57:27.884000             🧑  作者: Mango
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);
}
}