has

fun <T : Component> Entity.has(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