GAMEMAPS.CKx is the file that contains all of the levels in Keen Galaxy. The file is external and can be modified with many programs such as TED5 and TOM. There is a related file, MAPHEAD.CKx. In order to use altered levels, this file must be patched.
MAPHEAD.CKx is the level 'header'; it is basically a list of locations of various levels in the GAMEMAPS.CKx. The GAMEMAPS.CKx itself consists of a number of level 'blocks' or chunks; the game refers to all levels by their chunk number.
Keen Dreams uses a different name for its level files.
The MAPHEAD.CKx file is internal and thus can be called anything, but the GAMEMAPS.CKx file's name can be patched. The file name is read once to open the file and read levels from it.
Keen Galaxy game maps filename
#Keen 4 : %patch $1334F [$3AE2W] #Text called from %patch $32952 "GAMEMAPS.CK4" $00 #Keen 5 : %patch $142EC [$3238W] #Text called from %patch $33578 "GAMEMAPS.CK5" $00 #Keen 6 : %patch $12E80 [$34E2W] #Text called from %patch $34212 "GAMEMAPS.CK6" $00 #Keen Dreams %patch $B96F [$282EW] #Text called from %patch $2629E "KDREAMS.MAP" $00
Patching new levels
As mentioned above,using new levels requires that the MAPHEAD.CKx needs to be patched. The patches used rely on a special command in CKPatch, though they can also be done 'manually'.
Patch new levels into Keen Galaxy and Dreams
#Keen 4 : %maphead MAPHEAD.CK4 #Keen 5 : %maphead MAPHEAD.CK5 #Keen 6 : %maphead MAPHEAD.CK6 #Keen Dreams %patchfile $29C46 "MAPDICT.CK7" %patchfile $1FA50 "MAPHEAD.CK7"
A single patch controls where in the executable the game looks for for the map header files. (And in Keen Dreams the Map dictionary.)
Change Maphead location in Keen Galaxy and Dreams
#Keen Dreams %patchfile $B964 [$1FA5RW]
If the GAMEMAPS.CKx file is absent (or the equivalent file if GAMEMAPS.CKx has been renamed.) then the game will abort with an error.
Keen Galaxy\Dreams map errors
#Keen 4: %patch $13363 [$3AEFW] #Text called from %patch $3295F "Can't open GAMEMAPS.CK4!" $00 #Keen 5: %patch $14300 [$3245W] #Text called from %patch $33585 "Can't open GAMEMAPS.CK5!" $00 #Keen 6: %patch $12E94 [$34EFW] #Text called from %patch $3421F "Can't open GAMEMAPS.CK6!" $00 #Keen Dreams: %patch $B983 [$283AW] #Text called from %patch $262AA "Can't open KDREAMS.MAP!" $00