Method GetFieldOffset
GetFieldOffset(Type, string)
Gets the runtime field offset in bytes
Declaration
public static int GetFieldOffset(Type type, string fieldName)
Parameters
Type | Name | Description |
---|---|---|
Type | type | Type of the runtime component. Must implement IComponentData. |
string | fieldName | Runtime field. |
Returns
Type | Description |
---|---|
int | Returns the offset in bytes of the runtime field. |
Exceptions
Type | Condition |
---|---|
InvalidOperationException | Thrown if the runtime field was not registered. |