Patch:%DUMP

From KeenWiki
Jump to navigation Jump to search

The %dump patch command is used by CKPatch to dump the patched Keen executable as a file so that a modder can check it to see how their patches were written. (That is, it takes the modified Keen game and spits it out as a file.)

The command itself is quite simple:

%dump command in any patch file

%DUMP "FILENAME.CKX"


The command will produce the file FILENAME.EXT where the file name and extension can be anything the patcher desires. (A good file name is DUMP.BIN.) The file will always contain the entire Keen game executable less the executable header (Usually around 512 bytes.) The file is written only when the game is run successfully and a new copy is produced each time, overwriting the old. Multiple files can be dumped each time, allowing a patcher to see how the executable changes as various patches are applied.

There are some slight differences from the executable aside from the patches applied to it; as mentioned the executable header is absent, but also any far calls will have a certain, random, value added to them (because this is a memory dump and the game may be loaded into different locations in memory each time it is run.)