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

feat: fallback animation for sprites #256

Open
candycarmel opened this issue Jul 14, 2024 · 1 comment
Open

feat: fallback animation for sprites #256

candycarmel opened this issue Jul 14, 2024 · 1 comment
Assignees
Labels
enhancement New feature or request
Milestone

Comments

@candycarmel
Copy link

sort of related to a problem, more a helpful feature

constantly checking if the current animation is null before checking what the current animations name is is kind of tiresome

I'd like a fallback animation option for sprites

You should be able to provide the name of the fallback animation in the anims opt

I have a small code snippet in update that checks if the animation is null and then changes it to the fallback animation instead.

i dont think any other context should be needed

:)

@lajbel lajbel self-assigned this Jul 14, 2024
@lajbel lajbel added the enhancement New feature or request label Jul 14, 2024
@lajbel lajbel added this to the 3001 milestone Jul 14, 2024
@mflerackers
Copy link
Member

You could use obj.getCurAnim()?.name, that way you don't need to test for null.

@lajbel lajbel modified the milestones: 3001, 4000 Sep 3, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
Status: TODO
Development

No branches or pull requests

3 participants