Adapt built-in initialize method attribute with callback order. More...
Inherits Attribute.
Public Member Functions | |
InitializeMethodAttribute (int order=0) | |
Initialize in runtime after scene is loaded. More... | |
InitializeMethodAttribute (RuntimeInitializeLoadType runtime, int order=0) | |
Initialize in runtime with the specified load type. More... | |
InitializeMethodAttribute (bool editor, bool runtime, int order=0) | |
Initialize after scripts loaded. More... | |
Public Attributes | |
readonly int | order |
The initialize callback order. More... | |
readonly bool | editor |
If to initialize in editor after scripts loaded. More... | |
readonly RuntimeInitializeLoadType | runtime = (RuntimeInitializeLoadType)(-1) |
The runtime initialize load type. More... | |
Adapt built-in initialize method attribute with callback order.
Used to replace or combine:
UnityEngine.RuntimeInitializeOnLoadMethodAttribute
.UnityEditor.InitializeOnLoadMethodAttribute
. InitializeMethodAttribute | ( | int | order = 0 | ) |
Initialize in runtime after scene is loaded.
order | The order. |
InitializeMethodAttribute | ( | RuntimeInitializeLoadType | runtime, |
int | order = 0 |
||
) |
Initialize in runtime with the specified load type.
runtime | The load type. |
order | The order. |
InitializeMethodAttribute | ( | bool | editor, |
bool | runtime, | ||
int | order = 0 |
||
) |
Initialize after scripts loaded.
editor | If to initialize in editor. |
runtime | If to initialize in runtime. |
order | The order. |
readonly int order |
The initialize callback order.
readonly bool editor |
If to initialize in editor after scripts loaded.
readonly RuntimeInitializeLoadType runtime = (RuntimeInitializeLoadType)(-1) |
The runtime initialize load type.