Class MonoEventCallbackScriptableObject
To be able to register callbacks before Awake is called. You can't register a callback directly on a prefab, the callback will be lost on the object that's instantiated. With the SO, you can register the callback on the SO, and then register the SO on the prefab and the callback will be kept.
Inherited Members
Object.MemberwiseClone()
Object.InstantiateAsync<T>(T)
Object.InstantiateAsync<T>(T, Transform)
Object.InstantiateAsync<T>(T, Vector3, Quaternion)
Object.InstantiateAsync<T>(T, Transform, Vector3, Quaternion)
Object.Instantiate<T>(T, InstantiateParameters)
Object.Instantiate<T>(T, Vector3, Quaternion, InstantiateParameters)
Object.FindObjectsByType<T>(FindObjectsSortMode)
Object.FindObjectsByType<T>(FindObjectsInactive, FindObjectsSortMode)
Object.FindFirstObjectByType<T>()
Object.FindAnyObjectByType<T>()
Object.FindFirstObjectByType<T>(FindObjectsInactive)
Object.FindAnyObjectByType<T>(FindObjectsInactive)
Object.FindObjectsByType<T>()
Object.FindObjectsByType<T>(FindObjectsInactive)
Namespace: Unity.NetCode.Tests
Assembly: Unity.NetCode.TestsUtils.Runtime.Tests.dll
Syntax
public class MonoEventCallbackScriptableObject : ScriptableObject
Methods
TriggerAwake(GameObject)
Declaration
public void TriggerAwake(GameObject self)
Parameters
| Type | Name | Description |
|---|---|---|
| GameObject | self |
TriggerOnEnable(GameObject)
Declaration
public void TriggerOnEnable(GameObject self)
Parameters
| Type | Name | Description |
|---|---|---|
| GameObject | self |
TriggerOnPrediction(GameObject)
Declaration
public void TriggerOnPrediction(GameObject self)
Parameters
| Type | Name | Description |
|---|---|---|
| GameObject | self |
TriggerStart(GameObject)
Declaration
public void TriggerStart(GameObject self)
Parameters
| Type | Name | Description |
|---|---|---|
| GameObject | self |
Events
OnAwake
Declaration
public event Action<GameObject> OnAwake
Event Type
| Type | Description |
|---|---|
| Action<GameObject> |
OnEnableEvent
Declaration
public event Action<GameObject> OnEnableEvent
Event Type
| Type | Description |
|---|---|
| Action<GameObject> |
OnPrediction
Declaration
public event Action<GameObject> OnPrediction
Event Type
| Type | Description |
|---|---|
| Action<GameObject> |
OnStart
Declaration
public event Action<GameObject> OnStart
Event Type
| Type | Description |
|---|---|
| Action<GameObject> |