Skip to content

KECS / com.juanmedina.kecs.entity / View / view

view

fun view(vararg types:KClass<outAny>):View

Create a sub-view giving a set of component classes.

Parameters

types - Set of Components class such Position::class.

Return a new create view with the components of the provided classes.

fun view(vararg types:KClass<outAny>, receiver: (Entity) ->Unit):Unit

Send to a receiver a set of Entities for the given types

Parameters

types - set of KClass that we need on the entities.

receiver - function that will receive the entities.