2D Platformer: Player Movement and Animation

There are many excellent tutorials for how to get started moving a 2D player around the screen. The initial movement scheme in our game was based on this tutorial:

To create a new player, create a new scene and select CharacterBody2D as the root node. This should all be somewhat familiar if you made it through the tutorial video from the previous post: https://www.youtube.com/watch?v=m9ghnrdVgrI

You can make an engaging character with little more than a script attached to the CharacterBody2D and two child nodes: a Sprite2D and a CollisionShape2D.
– Sprite2D contains the image we want to use for our character.
– CollisionShape2D defines how our character collides with the environment.

If you look at the game you will not see a Sprite2D, but instead an AnimatedSprite2D. As the name suggests, the AnimatedSprite2D is like a Sprite2D, but animated. You can learn all about how to use an AnimatedSprite2D through either or both of the following tutorials:

  1. https://www.youtube.com/watch?v=-f1bHR0iiEY
  2. https://docs.godotengine.org/en/stable/tutorials/2d/2d_sprite_animation.html

Spritesheets are images consisting of rows and columns of individual frames of an animation. These are super useful for creating animated sprites and as of writing our project uses this free set of spritesheets: https://kenney.nl/assets/new-platformer-pack

2D Platformer: Getting Started

If you are interested in collaborating on a 2D Game Project with the club, this is where to get started. We will be making a platformer using the Godot Game Engine and GitHub for collaboration. You can even you can play a version of the game here: https://hackerspace.emmw.net/godot-games

Start by downloading the latest version of Godot here: https://godotengine.org/

You will need to create an account on https://github.com/

I also recommend that you download and install GitHub desktop from here: https://desktop.github.com/download/ and link to your GitHub account.

Once you have a GitHub account, you can email your username to nholtschulte [at] cnm [dot] edu, and he will give you privileges to access the code repository, which is available here: https://github.com/CNMHackerSpace/CNM-CiC-2025-Godot

Expect more blog posts to follow with tutorials and resources to add your own ideas to the project, but in the meantime (especially if you are new to game development), here is a beginner tutorial to help you get started (including a download guide for Godot):