Method GetComponentBoxed
GetComponentBoxed(Entity, ComponentType)
Gets the component object of a given entity
Declaration
public object GetComponentBoxed(Entity entity, ComponentType type)Parameters
| Type | Name | Description | 
|---|---|---|
| Entity | entity | The entity | 
| ComponentType | type | The component type to get the object of | 
Returns
| Type | Description | 
|---|---|
| object | The component object | 
Exceptions
| Type | Condition | 
|---|---|
| ArgumentException | Throws if the type does not exist on the entity | 
GetComponentBoxed(Entity, Type)
Gets the component object of a given entity based on the type
Declaration
public object GetComponentBoxed(Entity entity, Type type)Parameters
| Type | Name | Description | 
|---|---|---|
| Entity | entity | The entity | 
| Type | type | The type to get the object of | 
Returns
| Type | Description | 
|---|---|
| object | The component object | 
Exceptions
| Type | Condition | 
|---|---|
| ArgumentException | Throws if the type does not exist on the entity |