Mikey of Legend

Week 4: Animation and State Machines

Learning objectives: Drive character animation via clear movement states.

Estimated time: 7-9 hours

Signed in as loading...

Checking purchase access...

Introduction

This week is split into short video parts so you focus on one concept at a time, complete the matching build task, and verify results before moving to the next part.

Lesson breakdown

  • Lesson 1: Sprite Animation Setup - Set up AnimatedSprite2D for idle/run/jump/fall
  • Lesson 2: State Machine Wiring - Implement enum-based state machine transitions
  • Lesson 3: Transition Polish and Readability - Add polish with landing squash/stretch
  • Lesson 4: Integration and testing pass for this week scope.
  • Lesson 5: Final polish and handoff notes for next week.

Try this now

  • Complete one focused implementation pass before watching the next segment.
  • Capture a before and after snapshot for the system you changed.
  • Write one short note on what to tune in your next iteration.

How this week works

This week is split into short video parts so you focus on one concept at a time, complete the matching build task, and verify results before moving to the next part.

Video segment plan

Use one lesson segment per step for Week 4: Animation and State Machines. Pause between segments and complete the hands-on task before continuing.

Image and diagram references

Capture setup screenshots, inspector states, and scene graphs as you work so each step has a visual checklist to validate progress.

Interactive lesson parts (6-10 min each)

Part 1: Sprite Animation Setup

Watch Build Check
7 min Part video
Video part 1: Sprite Animation Setup

Embed a short clip for this step and keep it under 10 minutes before moving to the build task.

Set up AnimatedSprite2D for idle/run/jump/fall

Part 2: State Machine Wiring

Watch Build Check
8 min Part video
Video part 2: State Machine Wiring

Embed a short clip for this step and keep it under 10 minutes before moving to the build task.

Implement enum-based state machine transitions

Part 3: Transition Polish and Readability

Watch Build Check
9 min Part video
Video part 3: Transition Polish and Readability

Embed a short clip for this step and keep it under 10 minutes before moving to the build task.

Add polish with landing squash/stretch

Code checkpoint

Add or adapt this snippet during your build pass, then run and verify behavior before moving to the next week.

Practice snippet GDScript
# Step checkpoint for Week 4: Animation and State Machines
func _ready() -> void:
    print("Checkpoint complete for this week")