Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Better soft coding on icons #14555

Open
wants to merge 3 commits into
base: main
Choose a base branch
from
Open

Conversation

saturn-volv
Copy link
Contributor

How it works

Doesn't really change a whole lot outta the box without making new icons, such as winning icons. Just allows for progressively stepped ones I guess.
So now instead of having a fixed value of two (which wasn't already a static final variable), the division of icons is now handled based on the ratio of the graphic. (2:1 is the standard ratio).
If you wanna add more animation frames to your icon, just increase the width by however many sections as you like, as long as it's divisible by the height.

Now you can just:

iconP2.animation.curAnim.curFrame = 3;

If your sprite width is 3 times your height

@GhostBnuuy
Copy link

Pretty swag

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants