Debug log server for GameMaker
A downloadable extension
Download NowName your own price
This simple extension provides an external debug message log server for GameMaker Studio and GameMaker Studio 2 games.
Such a thing can be useful for:
- Seeing the debug messages when not running the game from IDE (e.g. when testing multiple instances of multiplayer games).
- Have multiple game instances send messages to the same log (also good for debugging multiplayer).
- Constantly logging data without worrying about overflowing the output log.
- Logging data on platforms with broken logging (e.g. OSX).
- Logging over network.
- Having persistent log between game launches.
Setting up:
- Add the extension to your project (right click on extension - Add Existing - pick the .gmez file).
- Add the included files from extension to your project.
These are marked to not be included in any builds by default. - Somewhere on game start, add netlog_init("<server ip>", <server port>);.
e.g. to connect to the same computer on default port you would do netlog_init("127.0.0.1", 5101);. Omitting this will display netlog(_) messages via show_debug_message(_) instead. - Add a "Async - Networking" event to any persistent controller object and add netlog_async_net(); there.
- When you need to display debug information, use netlog("<message>");. If you already have a custom debug log function, may very well add the call to there.
- If using GMS2 macOS, install Neko VM runtime (Windows version uses .NET runtime).
Running:
- GMS1: Double-click "netlog.exe" in Included Files to start up the program.
- GMS2 Windows: Right-click "netlog.exe" in Included Files and pick "Edit".
- GMS2 macOS: Right-click "netlog.n" in Included Files, pick "Open in Explorer/Finder (Ctrl+Shift+O)". Open terminal in that directory and do "neko netlog.n".
Source code: https://github.com/YAL-GameMaker/netlog
Have fun!
Download
Download NowName your own price
Click download now to get access to the following files:
netlog.gmez 33 kB
netlog.gmz 2 MB
Development log
- Now with escape characters!Oct 30, 2019
Comments
Log in with itch.io to leave a comment.
Does this not work in newer versions of gamemaker? I've been trying to get it working on LTS but only get "Socket timeout connecting" and then nothing works.
Should be fine, but see if you have firewall blocking the server executable.
I checked the allowed programs list and netlog.exe was on it, I even tried temporarily disabling the firewall and running it as administrator but it didn't work for some reason.
Actually my bad, when the program opened and said "Port(default 5101):" I thought it meant it was already listening to that port, I didn't realize you actually have to press enter then any key for it to actually run.
Also on some terminal emulators I have to input a random letter and press enter after inputting the port for it to run, which is fine but a little strange/interesting.
What a useful tool! Just downloaded it, pumped to check it out.
“Import Local Package” lets you pick a GMEZ.
This is amazing!