Book Image

Gamemaker Essentials

4 (1)
Book Image

Gamemaker Essentials

4 (1)

Overview of this book

This book is for users experienced with game development who now want to learn how to develop games in GameMaker: Studio in a fast-paced way.
Table of Contents (11 chapters)

Drawing information


When it comes to debugging a game, it can often be helpful to draw information to the screen. Things (such as drawing variable values) can be extremely helpful in seeing exactly what is going on in the game at any one time.

Drawing text

As mentioned before, drawing text to the screen can be extremely helpful. While prototyping parts of a game, such as a health system, you could simply draw the health value in text instead of going straight to a health bar.

It's common to see counters when using text to debug games. If we want to check how many of an object exists at any one time, we can draw the number to the screen using the draw_text and instance_number functions. This allows you to see exactly how many instances of an object exist when the game runs.

We can use text to see pretty much anything during a game. Things such as the position of an object to the text the user has entered on the keyboard can all be seen by simply drawing variables to the screen as the game runs...