summaryrefslogtreecommitdiff
path: root/src/heretic/deh_htic.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/heretic/deh_htic.c')
-rw-r--r--src/heretic/deh_htic.c18
1 files changed, 18 insertions, 0 deletions
diff --git a/src/heretic/deh_htic.c b/src/heretic/deh_htic.c
index 5a0a571e..5bd198ed 100644
--- a/src/heretic/deh_htic.c
+++ b/src/heretic/deh_htic.c
@@ -138,6 +138,24 @@ void DEH_HereticInit(void)
}
}
+int DEH_MapHereticThingType(int type)
+{
+ // Heretic 1.0 had an extra entry in the mobjinfo table that was removed
+ // in later versions. This has been added back into the table for
+ // compatibility. However, it also means that if we're loading a patch
+ // for a later version, we need to translate to the index used internally.
+
+ if (deh_hhe_version > deh_hhe_1_0)
+ {
+ if (type >= MT_PHOENIXFX_REMOVED)
+ {
+ ++type;
+ }
+ }
+
+ return type;
+}
+
int DEH_MapHereticFrameNumber(int frame)
{
if (deh_hhe_version < deh_hhe_1_2)