Duke Nukem II Demo Format

From ModdingWiki
Jump to navigation Jump to search
Duke Nukem II Demo Format
Format typeMacro
Maximum lengthUnknown
Games

The "player input" for the Duke Nukem II demo is stored in NUKEM2.MNI. The level filenames for the demo (L1.MNI, L3.MNI, L5.MNI, L7.MNI) are hard-coded.

NUKUM2.MNI also is a demo file, but is never used by the game.

The user input for each cycle is stored as a single byte with the bits indicating which keys were pressed. A byte value of $FF indicates the end of demo data and causes the demo playback to stop.

Bit Description
7 next level
6 unused (except for the END marker)
5 fire
4 jump
3 right
2 left
1 down
0 up

The game does not limit the size of the demo in any way. It just reads one 128 byte block at a time into a buffer and will read the next block when all bytes in that buffer have been used.

Credits

This file format was reverse engineered by K1n9_Duk3. If you find this information helpful in a project you're working on, please give credit where credit is due. (A link back to this wiki would be nice too!)