Observable that keeps track of component add or remove changes on the entity
The unique identifier for the entity
Convenience reference to the global logger
The scene that the entity is in, if any
Static defaultsSet defaults for all Actors
Gets the acceleration vector of the actor in pixels/second/second. An acceleration pointing down such as (0, 100) may be useful to simulate a gravitational effect.
Sets the acceleration vector of teh actor in pixels/second/second
Useful for quickly scripting actor behavior, like moving to a place, patrolling back and forth, blinking, etc.
Access to the Actor's built in [[ActionsComponent]] which forwards to the [[ActionContext|Action context]] of the actor.
Gets the rotational velocity of the actor in radians/second
Sets the rotational velocity of the actor in radians/sec
The physics body the is associated with this actor. The body is the container for all physical properties, like position, velocity, acceleration, mass, inertia, etc.
Get the center point of an actor (global position)
Get the direct children of this entity
Access to the Actor's built in [[ColliderComponent]]
Sets the color of the actor's current graphic
Access to the Actor's built in [[GraphicsComponent]]
Gets whether the actor is Initialized
Indicates whether the actor is physically in the viewport
Get the local center point of an actor
Access the Actor's built in [[MotionComponent]]
Gets the acceleration of the actor from the last frame. This does not include the global acc [[Physics.acc]].
Sets the acceleration of the actor from the last frame. This does not include the global acc [[Physics.acc]].
Gets the position vector of the actor from the last frame
Sets the position vector of the actor in the last frame
Gets the velocity vector of the actor from the last frame
Sets the velocity vector of the actor from the last frame
Access to the Actor's built in [[PointerComponent]] config
Gets the position vector of the actor in pixels
Sets the position vector of the actor in pixels
Gets the rotation of the actor in radians. 1 radian = 180/PI Degrees.
Sets the rotation of the actor in radians. 1 radian = 180/PI Degrees.
Specifically get the tags on the entity from [[TagComponent]]
Access the Actor's built in [[TransformComponent]]
The types of the components on the Entity
Gets the velocity vector of the actor in pixels/sec
Sets the velocity vector of the actor in pixels/sec
Gets the z-index of an actor. The z-index determines the relative order an actor is drawn in. Actors with a higher z-index are drawn on top of actors with a lower z-index
Sets the z-index of an actor and updates it in the drawing list for the scene. The z-index determines the relative order an actor is drawn in. Actors with a higher z-index are drawn on top of actors with a lower z-index
new z-index to assign
Protected _setTests whether the x/y specified are contained in the actor
X coordinate to test (in world coordinates)
Y coordinate to test (in world coordinates)
Optional recurse: booleanchecks whether the x/y are contained in any child actors (if they exist).
Optional event: anyRemoves a component from the entity, by default removals are deferred to the end of entity update to avoid consistency issues
Components can be force removed with the force flag, the removal is not deferred and happens immediately
Optional force: booleanGenerated using TypeDoc
Whether this entity is active, if set to false it will be reclaimed