• Hey Guest! Ever feel like entering a Game Jam, but the time limit is always too much pressure? We get it... You lead a hectic life and dedicating 3 whole days to make a game just doesn't work for you! So, why not enter the GMC SLOW JAM? Take your time! Kick back and make your game over 4 months! Interested? Then just click here!

Windows I can´t put the submenus and i don´t know why

Ronarov

Member
I decided to follow the tutorial of a video about the menus as a programming practice, the problem in which it does not work is because at the min 13:00 the menu should have appeared accompanied by the following options while mine only shows me the menu without options and I would like to know why or where I was wrong
1633907515919.png1633907549493.png1633907652849.png1633907713778.png1633907549493.png
1633907515919.png1633907549493.png1633907713778.png1633907515919.png1633907549493.png1633907652849.png1633907713778.png
 

Nocturne

Friendly Tyrant
Forum Staff
Admin
Okay, so... First, PLEASE do not upload screenshots of the code. It makes it very difficult to actually track what's happening in the events, and also means that we can't copy/paste what you have to edit it and fix problems. Use the [CODE][/CODE] tags to post correctly code into a topic post.

Second, what happens if you simply add a line to draw some text to the screen? EG:
GML:
draw_text(32, 32, "Hello World");
Does the text render correctly? If it doesn't then you know there is a problem with the font... As it is now though your code seems okay.
 
I remember this tutorial can have an issue because they are using the draw event instead of draw gui. I am guessing, without looking too far into your code as the screenshots are hard to read on mobile, that your text is being draw off screen. This can happen if your view/camera is smaller than theirs. I will have to check, but I think I set my text draw coordinates to be half my gui in order to keep it centered. Again, that would be in the draw gui event.

I have no idea why the video uses the regular draw, as a menu like this would basically always need to be relevant to the game view. Then again, I am still learning, so take everything I say with a grain of salt. :)
 
Last edited:

Ronarov

Member
Okay, so... First, PLEASE do not upload screenshots of the code. It makes it very difficult to actually track what's happening in the events, and also means that we can't copy/paste what you have to edit it and fix problems. Use the [CODE][/CODE] tags to post correctly code into a topic post.

Second, what happens if you simply add a line to draw some text to the screen? EG:
GML:
draw_text(32, 32, "Hello World");
Does the text render correctly? If it doesn't then you know there is a problem with the font... As it is now though your code seems okay.
Well, I saw the tutorial very well and all the drawing and creation codes are perfect, I am starting to think that it is due to the sprite of the letters and I think it would be a good idea for me to try to create my own script, maybe this work!
 
Top