FrameSprite / Godot practice files

Keep your sprite facing the way it stopped.

Hold the right arrow and release it. The dragon should stop moving, keep looking right, and continue beating its wings.

Download the Godot projectAnimate your own character

Park the dragon between the flags

Fly right to the two gold markers and let go. Can the dragon stop there facing right? This browser preview uses the downloadable project’s actual 48 poses and frame timings.

Use the downloadable Godot project to play the scene.

Loading the sprite sheet…

Godot capture after the right arrow was released. The dragon still faces right at X 758, animation frame 23.
Recorded in Godot 4.7.2. This is the same position and pose used to compare the two versions.

Run the test

  1. Extract the ZIP. Import project.godot in Godot 4, then run the main scene with F5.
  2. Hold Right and release. Read Arrow, Facing and Frame below the character.
  3. Press Left and release. The facing direction should change once, and only the horizontal motion should stop.

Change the direction only on input

The skull points left in the original art. A positive horizontal input therefore needs a horizontal flip. At zero input, leave the last flip value alone.

var axis := Input.get_axis("ui_left", "ui_right")
velocity.x = axis * speed
if axis != 0.0:
    sprite.flip_h = axis > 0.0
move_and_slide()

For artwork drawn facing right, use axis < 0.0 inside the same guard. Mirroring also reverses lettering and which hand holds an item, so check your source drawing first.

The download includes the controller, runnable scene, and one 8 × 6 sheet made from FrameSprite’s 48 transparent flight frames. No plugins or account are required to run it.

See how the 48 source frames fit on a 4096-pixel atlas and download their measured rectangles and timings.