MFGG Forums
Debug Mode Gamemaker, what is it? - Printable Version

+- MFGG Forums (https://forums.mfgg.net)
+-- Forum: MFGG (https://forums.mfgg.net/forumdisplay.php?fid=4)
+--- Forum: Developer Discussion (https://forums.mfgg.net/forumdisplay.php?fid=10)
+--- Thread: Debug Mode Gamemaker, what is it? (/showthread.php?tid=278)



Debug Mode Gamemaker, what is it? - Mariotroid - 12-17-2017

I read the online instructions on the debug mode of gamemaker but I still don' understand it's use? Can you edit variables in game or change the code in any way? Or do you just see the values of the variables?


RE: Debug Mode Gamemaker, what is it? - VinnyVideo - 12-17-2017

A good question. Typically I use Debug Mode to watch a specific variable (whether a global variable or an object's local variable) and see what events cause it to change. For example, suppose I'm making a boss, but the boss can't be defeated for some reason. I might watch the "hp" variable for the boss and see which events cause hp to go down. This helps me narrow down the problem.

Debug Mode also lets you modify variables in game using the Execute Code dialog box. For example, if I'm tinkering with my code in Cheerwine Deluxe 3, I could type "global.debug = 1" into the Execute Code dialog box, and that would enable the game's special debug mode. (global.debug is just a variable I made for testing things in CD3 - it's not something built in to GM.)


RE: Debug Mode Gamemaker, what is it? - Mariotroid - 12-17-2017

Ok thanks still learning the ins and outs after years of programming. Btw Vinny, I emailed you about giving me my missing badges?


RE: Debug Mode Gamemaker, what is it? - VinnyVideo - 12-17-2017

@Mariotroid I saw your e-mail, and I PM'd a reply to you. Did you get it?


RE: Debug Mode Gamemaker, what is it? - bigpotato - 12-18-2017

In addition, I often use it to run through my code line by line to find the source of a bug with multiple possible causes.