contains

operator fun <T : Component> Entity.contains(mapper: ComponentMapper<T>): Boolean

Checks whether the Entity has the specified Component.

Return

true if the Entity has the specified component, and false otherwise.

Parameters

T

the Component type to inspect.

mapper

the ComponentMapper to check the Component with.

See also

ComponentMapper.has