Skip to content
This repository was archived by the owner on Jan 2, 2021. It is now read-only.
This repository was archived by the owner on Jan 2, 2021. It is now read-only.

Sprite support #7

@rdrpenguin04

Description

@rdrpenguin04

Goal: To implement a "Sprite" construct that renders a scalable image on the screen.

Constraints:

  • Constructing a Sprite should return something usable as a Thing.
  • Sprite should have an initialization function that takes a starting coordinate pair (float, float), a starting size (float, float; passing 0 uses the size of the image, scaled by a constant), a starting depth (float), and a list of images (in C, these should be sent as uint32_t, char**) as parameters
  • Sprite should have a function to set the current frame of animation based on id
  • Sprite should have a function to add an update handler. This can be used to give Sprites a primitive AI. The handler shall be aware of the Sprite, and it shall run during the update cycle to prevent concurrency issues.
  • Sprite should have a function to change the X or Y coordinate, or both at once, as well as a function to change the X/Y/combined scale factor(s).

Metadata

Metadata

Assignees

Labels

enhancementNew feature or request

Type

No type
No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions