Click or drag to resize
EntityManagerTryGetComponent Method (Int32, Type, IEntityComponent)
Tries to get a component of the passed type attached to the entity with the specified id.

Namespace: Slash.ECS.Components
Assembly: Slash.ECS (in Slash.ECS.dll) Version: 1.0.6018.40178
Syntax
public bool TryGetComponent(
	int entityId,
	Type componentType,
	out IEntityComponent entityComponent
)

Parameters

entityId
Type: SystemInt32
Id of the entity to get the component of.
componentType
Type: SystemType
Type of the component to get.
entityComponent
Type: Slash.ECS.ComponentsIEntityComponent
Retrieved entity component, or null, if no component could be found.

Return Value

Type: Boolean
true, if a component could be found, and false otherwise.
See Also