Sprites are image resources, also known as graphics. You can create as many sprites as you want, and these can be used in your game directly. Game Maker features an in-built image editor so you can create you own sprites easily.
We'll create a simple sprite.
Click the "Create a sprite" button.
Alternatively, you can Right Click Sprites > Create Sprite to achieve the same result.
A new window will appear. On it, you can give the new sprite a name, load a new sprite from file, or edit a sprite.
Click the "Edit Sprite" button.
The new window that appears is where you create and edit your sprite. The Game Maker sprite editor is very powerful, and fairly easy to use. You can create still images or animations here.
Click the "Create a new sprite" button.
You'll be asked to set a size for the new image. The measurement is pixels.
Click the OK button for the default size of 32*32 pixels.
You'll see a square box highlighted with a white and gray checker appearance. The white/gray represents full transparency, or unfilled pixels.
Double click the empty sprite to begin editing it.
Within you'll see the somewhat complex interface of the sprite editor. There is a lot of functionality within this panel, so you'll want to play around with some of the options in the future.
For now, begin by zooming in on your canvas.
Click the zoom button a few times so the canvas is easier to see.
With your canvas zoomed in, you are able to work more precisely. We're going to draw a simple, filled circle.
Click the "Draw an ellipse" button. Click the "Filled" selection afterward, so that your circle will be drawn filled.
You might also want to change the fill color by left-clicking one of the colors on the far right.
Pixels are known to be in a grid, and can be referenced by quoting their position in the grid. At the bottom of the sprite editor panel you will see a display that says numbers in the form of (01,23) but with different entries. Move your mouse around the pixel grid and you'll notice that (0,0) refers to the top left corner, the origin, and (31,31) refers to the bottom right corner.
When creating games, you will notice a lot of zero-base procedure. Our grid starts at 0 and extends to 31, giving us 32 pixels as we set earlier.
Click the position (0,0) and while still holding down the mouse button, drag your mouse to (31,31). Release the mouse button.
You will see a perfect circle created like the one below.
Your sprite is now created.
Press the "OK, save changes" button, and again on the following panel.
From here, you should give your new sprite a name.
Name the sprite spr_player and then click "OK".
Naming resources properly is extremely important. In the future you will refer to individual sprites, objects, rooms, etc. If 2 resources have the same name, Game Maker won't know which resource you are trying to access. Get into the habit of naming every resource properly.
Finished! That's it, you have created your first sprite! It seems like a lot of effort when formatted like this, but you'll be able to create sprites with ease in the future. If you don't have an artist's touch, there are many graphics across the internet which you might want to use, even if only as placeholders.
At the moment, don't worry about fancy graphics though. Your focus should be on learning, not appearance.
The next chapter will cover how to display this sprite in the game and add motion to it.
Why Not 3D? This tutorial demonstrated how to create a basic 2D sprite. While Game Maker is capable of 3D, we'll be working with 2D primarily because 3D requires models, textures, and an understanding of 3D animation, which is beyond the scope of this tutorial.
Additionally, online games and 3D games are amongst the most difficult to create, but a combination at this stage is not within your reach. However, if that is the path you wish to follow, there are opportunities to do this. Just beware that the effort involved in creating a 3D MMORPG is immense.