+1 vote

How can I import a single sprite sheet to animate my character? I mean, do I need to have every sprite frame to import into my AnimatedSprite? Or is there a different solution?
Consider a spritesheet like this:

Thank you.

in Engine by (22 points)

Following Eons answer, you should make sure the frames/cells in your spritesheet are also uniform in dimension.

1 Answer

+4 votes

You can add the spritesheet to a Sprite node, then use the hframes and vframes to define the way it is divided.

After that, just modify/animate the frame property of the sprite node.

by (7,898 points)

can you incorporate a sprite/animation node into a animatedsprite node?

hi, this solution is correct ?!?!?!

By the time of the question, it was the only way, now you can use spritesheets on AnimatedSprite too (I'm not sure if is on 3.1 already but will be on 3.2).

Welcome to Godot Engine Q&A, where you can ask questions and receive answers from other members of the community.

Please make sure to read Frequently asked questions and How to use this Q&A? before posting your first questions.
Social login is currently unavailable. If you've previously logged in with a Facebook or GitHub account, use the I forgot my password link in the login box to set a password for your account. If you still can't access your account, send an email to webmaster@godotengine.org with your username.