First post, by quadpixels
- Rank
- Newbie
Hello VOGONS Forum,
I've hit myself against the wall trying to find the secrets in Gunmetal (1998, Mad Genius) for some time, but the game's secrets are still way too hard for me (it's said that games from that era are "punishingly hard" compared to today's games)
So, I decide to try it the hard way: treat the game run through DosBox as a white-box (meaning I can see the entire emulated physical memory and machine code), and hopefully with a bit of background knowledge on game programming, and enough time, I would be able to figure out part of how the game works.
This game has both Windows 95 and DOS versions, and I find working with the DOS version a bit easier than the Windows version.
So far, I have done the following things to my copy of DosBox:
- Imported the project into Eclipse for comfortable editing and navigation (in Ubuntu 18.04 + XFCE)
- Figured out a way to create an OpenGL window for showing information plumbed from the running DosBox (a memory visualizer for now)
With that, I had some visual impressions of the run-time memory layout, and some of the findings I have are as follows:
- Textures are all stored in memory (if you zoom in you can see some in-game textures from the memory visualization)
- A frame buffer is also in the memory; its address may change from run to run but it is pretty easy to spot
For next steps I plan to: 1) figure out what happens within a game frame; I imagine to see things like game logic (BSP tree traversal, game status update, etc), then rasterizing the entire frame into the frame buffer. The rasterization process may be used for a boundary of a logical frame. When this step is done, hopefully I can find some of the most executed code (or stack traces, just like the profilers used to generate FlameGraphs do) that are doing the interesting things for the game. 2) Another possibility is to figure out the game's resource and scene format, like what things are the scene that don't move and what could move, and how secret areas are defined and where they are (the original purpose of this effort.) There should be hints in the game's scene loading routines, or the subroutine that draws the minimap on screen. The memory contents are what connect 1) and 2).
This post is for note-keeping purposes for my poking around with DosBox (along with my fork on github with the changes)... I'm not sure how long this journey would take, but hopefully this post may be useful for you, (: