initialises a new instance of a Sprite.
Configuration properties for the sprite.
ReadonlyidUnique identifier for the game object.
Whether the sprite is currently registered with the engine.
Static_Static helper for tests to bypass Registry circularity if mocked.
The bounds component for this object, defining its physical area.
Number of columns in the spritesheet.
The current frame index being displayed.
The ending column for the current animation loop.
Whether the sprite is horizontally flipped.
Duration of each animation frame in milliseconds.
Pixel height of a single animation frame (calculated automatically).
The pixel width of a single animation frame (calculated automatically).
The image element used by the sprite.
The tag component for this object, managing its name and rendering order.
Number of rows in the spritesheet.
The starting column for the current animation loop.
The transform component for this object, managing position and scale.
Adds a component to this game object.
The component instance to add.
Removes this object from the active scene or global engine loop.
Emits a custom event on this object's event bus.
The event type.
Optionaldetail: unknownOptional data to pass with the event.
Retrieves a component from this object by its class.
The class of the component to retrieve.
The component instance, or undefined if not found.
Checks if this object has a component of the specified class.
The class to check for.
True if the component exists.
Stops listening for an event on this object's event bus.
The event type.
The function to remove.
Listens for an event on this object's event bus.
The event type.
The function to run when the event occurs.
Registers the sprite with the engine and starts its animation loop.
Registers this object with the active scene or global engine loop.
Removes a component from this game object by its class.
The class of the component to remove.
Stops the sprite's animation and removes it from the engine.
A high-level object that represents an animated sprite. Wraps SpriteComponent and TransformComponent for ease of use.