• Hey! Guest! The 39th GMC Jam will take place between November 26th, 12:00 UTC and November 30th, 12:00 UTC. Why not join in! Click here to find out more!

Pop-up messages messing up fullscreen mode

Gabriel

Member
I have a game that was developed for mobile devices and now I'm adapting it for Windows.

The game features a button for In-App Purchases, but I want it to be disabled on the Windows version, so if the user presses it, it should display a message saying "This function is not available on Windows".
Now, the thing is: when the message is displayed, if the game is on fullscreen mode, the fullscreen turns into a completely messed up window without controls and everything becomes stretched.

How can I properly display a message using "show_message_async" or "show_message" in fullscreen mode without this happening?
 

chamaeleon

Member
Why not just have some object (maybe you already have a suitable one in your game) add some text in the draw event to display your message and add a close button to the room? Perhaps coupled with some object deactivations if necessary, and reactivating when the player clicks on the close button. More work, I suppose, but you can style it any way you want and make it fit the look of your game.
 

Gabriel

Member
Why not just have some object (maybe you already have a suitable one in your game) add some text in the draw event to display your message and add a close button to the room? Perhaps coupled with some object deactivations if necessary, and reactivating when the player clicks on the close button. More work, I suppose, but you can style it any way you want and make it fit the look of your game.
I was trying to actually avoid that (yes, I already have a few in my game) so I wouldn't spend so much time with it, since it's not a recurring function.
 
W

Wraithious

Guest
The way I solved that problem was to have a variable check for full screen and switch to windowed mode if so, 1 step before calling get_string_async, then show the message, then check the variable after the message is closed and return to full screen if it was true.
 

Gabriel

Member
The way I solved that problem was to have a variable check for full screen and switch to windowed mode if so, 1 step before calling get_string_async, then show the message, then check the variable after the message is closed and return to full screen if it was true.
Looks like an efficient method.
I guess I'll stick to that one.
 
Top