From 3a140fe3b5bf1775276a0a454c52b6974b68055f Mon Sep 17 00:00:00 2001 From: Simon Howard Date: Sun, 10 May 2015 18:48:05 -0400 Subject: Add back the Doom PWAD reload hack. This was removed back in d190b596c566394717324296cbf6b46e67c64f5c; at the time I didn't understand what it was or how it was supposed to be used - it seemed like cruft left over from Doom's development. It is actually a potentially useful feature for level authors when developing their maps. See here: http://doomwiki.org/wiki/Reload_hack The reload hack is a relatively obscure feature of limited usefulness nowadays, but nonetheless a technical curiosity that ought to be preserved in Chocolate Doom. The reimplementation here is a lot cleaner than the original version from the source release: W_Reload() is based on a call to W_AddFile(), we don't reopen the reload file every time we want to read a lump, and we include a check in W_AddFile() that we are not trying to use the hack on more than one PWAD file. This fixes #539. --- src/w_wad.h | 1 + 1 file changed, 1 insertion(+) (limited to 'src/w_wad.h') diff --git a/src/w_wad.h b/src/w_wad.h index 71895749..e5dc18b3 100644 --- a/src/w_wad.h +++ b/src/w_wad.h @@ -56,6 +56,7 @@ extern lumpinfo_t *lumpinfo; extern unsigned int numlumps; wad_file_t *W_AddFile (char *filename); +void W_Reload (void); int W_CheckNumForName (char* name); int W_GetNumForName (char* name); -- cgit v1.2.3