Method ReadComponent
ReadComponent<T>(Buffer)
Reads a component reference from the buffer.
Declaration
public static T ReadComponent<T>(this Buffer buffer) where T : Component
Parameters
Type | Name | Description |
---|---|---|
Buffer | buffer |
Returns
Type | Description |
---|---|
T | The component reference that has been read from the buffer. |
Type Parameters
Name | Description |
---|---|
T |
Remarks
Component references are stored as an index relative to a GameObject. If components are added to or removed from the GameObject, this method will have undefined results.