Doom source code oddities

DOOM even lives up for it's name in the source code. On this page, pieces of stupid, useless and funny source code are gathered.

From D_ENGLISH.H Does someone care? // The following should NOT be changed unless it seems // just AWFULLY necessary


 * 1) define HUSTR_PLRGREEN "Green: "
 * 2) define HUSTR_PLRINDIGO "Indigo: "
 * 3) define HUSTR_PLRBROWN "Brown: "
 * 4) define HUSTR_PLRRED   "Red: "

From R_PLANE.C What's so important that it should only be executed at game startup? // // R_InitPlanes // Only at game startup. // void R_InitPlanes (void) { // Doh! }

From Z_ZONE.C //     Zone Memory Allocation, perhaps NeXT ObjectiveC inspired. //	Remark: this was the only stuff that, according //	 to John Carmack, might have been useful for //	 Quake.

From R_MAIN.C What the creators think about using the ASCII Character 0x08 (cursor to left), used in the loading bar. Remember this line? "R_Init: Init DOOM refresh daemon - [................................................]" //	Really complex printing shit...

From ST_STUFF.C Someone thinks the cheats in the source code are not obfuscated enough. // Massive bunches of cheat shit // to keep it from being easy to figure them out. // Yeah, right...

So that's what the cheat code for no-clipping means... // Smashing Pumpkins Into Samml Piles Of Putried Debris. unsigned char	cheat_noclip_seq[] = {   0xb2, 0x26, 0xea, 0x2a, 0xb2,	// idspispopd 0xea, 0x2a, 0xf6, 0x2a, 0x26, 0xff };

From F_WIPE.C Can anyone optimize my ass? // makes this wipe faster (in theory) // to have stuff in column-major format wipe_shittyColMajorXform((short*)wipe_scr_start, width/2, height); wipe_shittyColMajorXform((short*)wipe_scr_end, width/2, height);