Super Menu System is a suite of objects and functions meant to make it quick and easy to build complex menus in Game Maker. You can get it for free on my itch io page.
Here’s a quick introduction on how to use it. Start with these steps:
- Download the package
- Import it into your own Game Maker project.
Note: The system uses my own “input” object to manage keyboard and gamepad inputs (this object can also be found in my Super State Engine framework) but you can customize it to use your preferred input system.
To do so, open the Object “obj_menu_manager“, open the Step event and change the references used by manager:

Creating your first menu
- Create a new Object that will hold the menu
- In this object’s Create event add a “menu_init()” call
If you don’t enter any arguments to this call, the menu will use the default values for displaying texts. You can however customize horizontal and vertical alignment, font, colors and decide if the objects should be drawn to the room or to the gui.
Let’s say we want to make it horizontally and vertically centered, have the buttons’ text be white when normal and blue when selected or rolled over:
menu_init(fa_center,fa_middle,fnt_arial_med,c_white,c_blue);
Adding buttons
Ok, now that your menu is initialized, you can add buttons to it:
menu_add_button("",540,400,noone,"New Game",[room_goto,rm_game]);
menu_add_button("",540,500,noone,"Continue",[room_goto,rm_game]);
menu_add_button("",540,600,noone,"Credits",[room_goto,rm_credits]);
The first argument checks for a preset condition’s name. These conditions are used to decide if the menu item should be displayed or not (more on this later). If you want your item to always be displayed, just enter “”.
The second and third arguments set the x and y position of the item respectively.
The fourth argument defines a sprite that is used for the button. If you just want the button to use text without a sprite, enter “noone
“. You can use animated sprites with your buttons. If you do so, the button starts at the first frame and will play the animation until the last frame when selected. The animation will play backward back to the first frame when unselected.
Below is an example. Neat isn’t it?

Super Menu System has a bunch of functions to customize buttons and texts style that you can use to change values in between adding buttons. This way, you can easily set different styles for each of your buttons without having to enter all parameters again.
menu_set_style()
– Allows to enter all parametersmenu_set_colors()
– Only set the normal color and optionally the selected color as wellmenu_set_font()
– change the fontmenu_set_draw_to_gui()
– Set the item to be drawn to room (false
) or to the gui (true
)
Adding text
To add a simple text to your interface, use this:
menu_add_text(_cond,_x,_y,_text);
Just like the button item, you can check against a condition to decide if the text should be displayed or not. Then you can decide on the x and y position and finally enter the text to be displayed.
The arguments shown above in the function call are mandatory but there are other optional arguments that can be used to customize the style of the text.
Adding a dynamic value
Sometimes a simple text doesn’t do. You need to display a dynamic value. For example to show how many of a particular item you have in your inventory. Any value that is recorded in a variable can be shown on screen with a value object
menu_add_value(_cond,_x,_y,_target,_var_name)
You know how the three first arguments work!
The _target
argument defines where the variable we want to display is. This can be global or any reference to an instance. You then write the name of the variable to be displayed as a string.
For example, let’s say you want to display a global variable showing how many arrows the player has, which is recorded as global.arrows
:
menu_add_value("",20,20,global,"arrows");
Adding a sprite
Another very simple object, it allows you to add a defined sprite to your interface at a given position.
The advantage of doing this over simply using “draw_sprite
” is that you can add a condition that will be checked against to decide if it the sprite will be displayed or not. It will also be displayed at a position relative to the menu object holding it so let’s say you have a draggable menu it will follow it along with other menu items.
menu_add_sprite(_cond,_x,_y,_sprite)
The first argument is a reference to the condition to check against. This is a string and can be “” if you don’t want to use a condition.
There’s a fifth optional argument to define if the item should be drawn to the room or the GUI. If no argument is entered it will use the default value defined earlier.
Creating conditions
Before moving on to the last menu item, let’s look at these conditions I’ve already mentioned several times.
menu_create_condition(_name,_target,_var_name,_is,_value);
First argument is a string defining the name of the condition.
Next is a reference to an instance where the target variable is. This can be “global”.
Third is the name of the variable to check as a string.
Fourth argument is how to compare the value with a given real number. Select from the values of the enum IS. This can be IS.EQUAL_TO, IS.LOWER_THAN or IS.HIGHER_THAN.
Lastly is the real number to compare with.
All values are mandatory.
Condition test case
Let’s say I want some information to only appear when the player has acquired a certain object. For example, only display the number of arrows in the GUI when the player actually has arrows. I start by creating the condition:
menu_create_conditions("has_arrows", global, "arrows", IS.HIGHER_THAN, 0);
Then I can use this condition with my menu items used to display the arrows in the GUI (a sprite and a value):
// DISPLAY ARROWS ON GUI WHEN THE PLAYER HAS ARROWS IN HIS INVENTORY
menu_add_sprite("has_arrows", 20, 20, spr_arrows);
menu_add_value("has_arrows", 60, 20, global, "arrows");
Adding a toggling button
The toggling button is a slightly more complex menu item. It allows you to add a button with dual functionalities. The whole button CAN be disabled with a condition but it absolutely REQUIRES a condition for toggling between its two states.
menu_add_button_toggle(_cond,_cond_tog,_x,_y,_sprite1,_sprite2,_text1,_text2,_function1,_function2)
You can see above that the first argument is the condition, like other items. The second condition though defines what to check to toggle between states. If the condition is met (true), the button will use the second state. If the condition is NOT met (false), it will use the first state.
Next you can see that the _sprite, _text and _function arguments are all coming in pairs. Arguments ending with “1” are used for the first states and arguments ending with “2” are used for the second state.
Conclusion
That’s about it!
Note that menus created with Super Menu System can be used with the mouse as well as the keyboard / gamepad all at once. Mouse controls are handled by the button themselves but the keyboard / gamepad controls are handled by a special “obj_menu_manager” object. This object is automatically created when you call “menu_init()
” and can only be created once (in case you have more than one menu in one room) so you don’t have to worry about it.
The code is also fully commented for use with Game Maker’s “feather”, which gives you all the information you need about the functions when using them.
Check out the (arguable ugly) demo on the system’s itch page. This should give you a basic idea of what you can do with it!