Skip to content
Kitbay
Skill

godot-2d-movement

Apache-2.0Updated on Nov 12, 20269,475GitHub stars

A skill from the awesome-gamedev-agent-skills collection for writing CharacterBody2D movement in GDScript for Godot 4.7.

What the skill teaches

A skill from the awesome-gamedev-agent-skills collection for writing CharacterBody2D movement in GDScript for Godot 4.7. The agent first reads the player scene and the input actions, picks grounded mode for platformers or floating mode for top-down games, sets the velocity and calls move_and_slide once per physics frame, then reads floor and wall results after that call. Patterns include a platformer controller, eight-direction top-down movement and reacting to collisions, with notes on slopes and one-way platforms, plus a headless test that proves the body actually lands. Jump feel, rigid bodies, 3D and tilemaps are left to sibling skills.

Capabilities

  • Write platformer and top-down CharacterBody2D controllers
  • Handle slopes and one-way platforms
  • Write a headless landing test for a 2D character