to-be Keen 4-6 editor

Utilities for editing Keen:Galaxy and Keen:Dreams levels.
z-one
Posts: 31
Joined: Mon Jan 10, 2005 3:42 am

to-be Keen 4-6 editor

Post by z-one »

As most of you know, I create my own editor for my game. It runs on Windows and uses openGL for most of the 2D rendering.

The editor already has most functions I wanted to implement, but not the extra game stuff. It's time for your help if you want it to be a Keen 4-6 editor too. Please tell me about those extra things that can be edited in Ted, like teleport locations, doors, bridges, etc. and how they are controlled in Ted! I want to make this editor easy to use, but I still need the information as I cannot get Ted to run.

BTW, the Keen 4-6 map format would be useful too... I use Carmack's compression for my map, so it won't be a problem.
KeenRush
Patch Maker
Posts: 1988
Joined: Sun Aug 31, 2003 2:52 pm
Location: Sand Yego
Contact:

Post by KeenRush »

Man, this sounds excellent! Good luck!

I haven't, too bad, used TED almost at all. As far as I know all the values for bridges and doors and stuff are fed by hand by setting a value (2-byte (8 bits) integer value) to an info-plane block. If I remember correct there are no specific tools in TED for creating bridges or doors, so that kind of things could be very nice.

Here's something written by adurdin about the level format:
http://files.keenmodding.org/mobydoc.txt
z-one
Posts: 31
Joined: Mon Jan 10, 2005 3:42 am

Post by z-one »

Everything is clear by that document, but this: "MAPHEAD is located within the EXE file." It'd be nice to know where is that in the exe. Adurdin if you read this, please help me out so I can finish the editor soon! :)
User avatar
adurdin
Site Founder
Posts: 549
Joined: Fri Aug 29, 2003 11:27 pm
Location: Edinburgh, Scotland
Contact:

Post by adurdin »

z-one wrote:Everything is clear by that document, but this: "MAPHEAD is located within the EXE file." It'd be nice to know where is that in the exe.
Download the source for TEDSetup -- it reads the MAPHEAD structure when exporting maps.

My article for the first Keen Newsletter (http://dosclassics.com/article.php?id=13) briefly describes switches and doors in Keen 4-6, also.
User avatar
levellord
Crazy pAtChEr
Posts: 1401
Joined: Thu Nov 20, 2003 11:35 pm
Location: NewZealand
Contact:

Post by levellord »

ZOMG! W00t!

1337.

Huzzah! *Nominates z-1 for nobel prize*
z-one
Posts: 31
Joined: Mon Jan 10, 2005 3:42 am

Post by z-one »

It's easier than I thought! So the map headers are at different positions according to the version number, and these positions are known. Patching the game memory for playing new levels will be necessary though, but the patch file can be created automatically. I don't yet know how does that work and I won't need it until the editor is ready, but I'll ask.

Now, let's extract some levels! ];-)>
KeenRush
Patch Maker
Posts: 1988
Joined: Sun Aug 31, 2003 2:52 pm
Location: Sand Yego
Contact:

Post by KeenRush »

This'll be so awesome.. :D

By the way, you don't really need to care about other versions than 1.4. It's rather standard that everybody uses versions 1.4 of the games for mods and level packs.

For the patch just make the program do the same kind of binary file that can be found inside the exe (MAPHEAD) although naturally with different values if the MAPHEAD has changed. :) CKxPatch can read that file directly into the selected memory address.
User avatar
adurdin
Site Founder
Posts: 549
Joined: Fri Aug 29, 2003 11:27 pm
Location: Edinburgh, Scotland
Contact:

Post by adurdin »

z-one wrote:Patching the game memory for playing new levels will be necessary though, but the patch file can be created automatically. I don't yet know how does that work and I won't need it until the editor is ready, but I'll ask.
Have a look at the TEDSetup sources -- it creates a patch file for use with CKxPatch. IIRC the generated patch file contains only one line.

Andrew
z-one
Posts: 31
Joined: Mon Jan 10, 2005 3:42 am

Post by z-one »

I can extract any level from Keen 4-6. All I need now is to understand that info plane, (which can't be too hard) and convert the level to a format my editor understands. Not today, as I have studying to do, but soon! ;)
KeenRush
Patch Maker
Posts: 1988
Joined: Sun Aug 31, 2003 2:52 pm
Location: Sand Yego
Contact:

Post by KeenRush »

As far as I know info plane is just like any other layer. It has values for the sprites and stuff. Please make there an option to the editor that one can set info plane values easily by just writing the values!
z-one
Posts: 31
Joined: Mon Jan 10, 2005 3:42 am

Post by z-one »

My editor stores level information differently from the way it is stored in Keen, so I don't promise anything about this, but I'll try.

If there's any other feature you'd like to see in the map editor, it's time to tell that too. Maybe it won't be implemented at all or just differently but it's important for me to create a usable tool!
z-one
Posts: 31
Joined: Mon Jan 10, 2005 3:42 am

Post by z-one »

Look at this! (not a photoshopped image, though it was saved with ps)
http://img.photobucket.com/albums/v505/z-one/k4l0.png
Background layer for Keen 4 map!
KeenRush
Patch Maker
Posts: 1988
Joined: Sun Aug 31, 2003 2:52 pm
Location: Sand Yego
Contact:

Post by KeenRush »

Awesome work so far! :D Will it be possible to select large areas of tiles from the tile menu, to make it possible get the backgrounds placed easily.
z-one
Posts: 31
Joined: Mon Jan 10, 2005 3:42 am

Post by z-one »

There's a "brush" editing function. You can create an area of tiles that can be placed anywhere later, or used for filling the map.

BTW is there any information regarding the tile data? For example how does a tile block your movement, how to make it a secret passage tile, etc? It'd be nice if I could edit that too!
z-one
Posts: 31
Joined: Mon Jan 10, 2005 3:42 am

Post by z-one »

The editor's import function works!
http://z-one.uw.hu/files/dopeon1.zip Try the dopefish enabled level 1 for Keen 4 now :D

I was trying different changes to level 1 but some had strange artifacts and once I got an insufficient memory message. Do you know what are the limits of Keen games?
Post Reply