entity

inline fun World.entity(entityEdit: EntityEdit.() -> Unit = {}): Int

Creates and adds an entity to the World.

Receiver

the World for creating the entity.

Return

the entity's ID as Int.

Parameters

entityEdit

the inlined function with EntityEdit.


inline fun World.entity(archetype: Archetype, entityEdit: EntityEdit.() -> Unit = {}): Int

Creates and adds an entity to the World.

Receiver

the World for creating the entity.

Return

the entity's ID as Int.

Parameters

archetype

the Archetype to add to the entity.

entityEdit

the inlined function with the EntityEdit.