Method AddPrefab
| Edit this page View SourceAddPrefab(GameObject)
Add a custom prefab to the manager.
Checks if a prefab with the same name is already added.
Added prefabs get registered to the ZNetScene on ZNetScene.Awake.
Checks if a prefab with the same name is already added.
Added prefabs get registered to the ZNetScene on ZNetScene.Awake.
Declaration
public void AddPrefab(GameObject prefab)
Parameters
Type | Name | Description |
---|---|---|
Game |
prefab | Prefab to add |
AddPrefab(CustomPrefab)
Add a custom prefab to the manager.
Checks if a prefab with the same name is already added.
Added prefabs get registered to the ZNetScene on ZNetScene.Awake.
Checks if a prefab with the same name is already added.
Added prefabs get registered to the ZNetScene on ZNetScene.Awake.
Declaration
public void AddPrefab(CustomPrefab customPrefab)
Parameters
Type | Name | Description |
---|---|---|
Custom |
customPrefab | Prefab to add |