-
-
Notifications
You must be signed in to change notification settings - Fork 9
match.CreateEntity
Jérôme Leclercq edited this page Dec 8, 2020
·
1 revision
API: match.CreateEntity
Creates a new entity in the match.
match.CreateEntity
(parameters: table
) -> entity: Entity
-
parameters
: A table describing all parameters to create the entity.
Possible fields:- (Mandatory) Type:
string
: The entity class full name (e.g. "entity_box") - (Mandatory) LayerIndex:
integer
: The layer where the entity should be created. - (Optional) Position:
vec2
: The position to spawn the entity. - (Optional) Rotation:
number
: The rotation the entity should have (in degrees). - (Optional) Scale:
number
: The scale the entity should have. - (Optional) Properties:
table
: A table giving a value for every property of the entity class (some of which may be mandatory). -
(Optional) Owner:
player
: A reference to the player owning this entity (which will be credited for damage dealt by this entity).
- (Mandatory) Type:
-
entity
: The newly created entity.