shithub: choc

Download patch

ref: 62a8e9b6c6c2018ccea04ec08275afa6eaffc4ec
parent: 75c479943f4eb0199150b3a46e838f203863ec58
author: Simon Howard <fraggle@soulsphere.org>
date: Tue May 5 18:42:14 EDT 2015

hexen: Show a startup warning if using v1.0 IWAD.

The Hexen v1.0 IWAD file differs too much from the v1.1 IWAD file and
can't be reasonably supported by us. Show a warning message on startup
if the user appears to be trying to play using the v1.0 IWAD file.
This fixes #537.

--- a/src/hexen/h2_main.c
+++ b/src/hexen/h2_main.c
@@ -269,6 +269,17 @@
 	gamemode = shareware;
 	maxplayers = 4;
     }
+
+    // The v1.0 IWAD file is missing a bunch of lumps.
+    if (W_CheckNumForName("CLUS1MSG") == -1)
+    {
+        printf(
+            "** WARNING: You are playing with the Hexen v1.0 IWAD. This\n"
+            "** isn't supported by " PACKAGE_NAME ", and you may find that\n"
+            "** the game will crash. Please upgrade to the v1.1 IWAD file.\n"
+            "** See here for more information:\n"
+            "**   http://www.doomworld.com/classicdoom/info/patches.php\n");
+    }
 }
 
 // Set the gamedescription string.