📜  unity instantiate prefab - C# 代码示例

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

代码示例6
GameObject prefab = reference_to_your_prefab_asset;
Vector3 position = Vector3.zero;
Quaternion rotation = Quaternion.identity;
Transform parent = parent_of_instantiated_prefab;

Instantiate(prefab, position, rotation, parent);