Core
NetworkPrefabs
Prefab id table shared by every process.
generated from the sources
Static class in namespace
Nebula · Packages/com.1by3.nebula/Runtime/Core/NetworkPrefabs.cspublic static class NetworkPrefabsPrefab id table shared by every process. Ids are the index in NebulaConfig.NetworkPrefabs.
Properties
Count
public static int Count { get; }Methods
Register
public static void Register(IList<GameObject> prefabs);Get
public static GameObject Get(ushort prefabId);TryGetId
public static bool TryGetId(GameObject prefab, out ushort id);IdOf
public static ushort IdOf(GameObject prefab);Instantiate
public static NetworkIdentity Instantiate(ushort prefabId, Vector3 position, Quaternion rotation, Transform parent);Instantiate a network prefab and bind its behaviours. Spawn hooks run when the caller spawns it.