summaryrefslogtreecommitdiff
path: root/src/heretic/deh_frame.c
diff options
context:
space:
mode:
authorSimon Howard2010-02-07 03:26:39 +0000
committerSimon Howard2010-02-07 03:26:39 +0000
commitea89b7c464576a18a8173d7da97d09eff2477edb (patch)
treec5b3cf3c00c390c7a55841c181ac9643547d98a3 /src/heretic/deh_frame.c
parent6a92bc54be4081c8821ca110947133b5f1f8516b (diff)
downloadchocolate-doom-ea89b7c464576a18a8173d7da97d09eff2477edb.tar.gz
chocolate-doom-ea89b7c464576a18a8173d7da97d09eff2477edb.tar.bz2
chocolate-doom-ea89b7c464576a18a8173d7da97d09eff2477edb.zip
When initializing to load an HHE patch, patch the states[] table to be
like Heretic 1.0. Subversion-branch: /branches/raven-branch Subversion-revision: 1859
Diffstat (limited to 'src/heretic/deh_frame.c')
-rw-r--r--src/heretic/deh_frame.c15
1 files changed, 14 insertions, 1 deletions
diff --git a/src/heretic/deh_frame.c b/src/heretic/deh_frame.c
index 21eb32bc..7dfb5aab 100644
--- a/src/heretic/deh_frame.c
+++ b/src/heretic/deh_frame.c
@@ -46,6 +46,19 @@ DEH_BEGIN_MAPPING(state_mapping, state_t)
DEH_UNSUPPORTED_MAPPING("Action pointer")
DEH_END_MAPPING
+// When a HHE patch is first loaded, we must apply a small change
+// to the states[] table. The table was changed between 1.0 and
+// 1.3 to add two extra frames to the player "burning death"
+// animation.
+// If we are using an HHE patch, the table must behave like the
+// Heretic 1.0 table. We must therefore change the table to cut
+// these out again.
+
+static void DEH_FrameInit(void)
+{
+ states[S_PLAY_FDTH18].nextstate = S_NULL;
+}
+
static void *DEH_FrameStart(deh_context_t *context, char *line)
{
int frame_number = 0;
@@ -122,7 +135,7 @@ static void DEH_FrameMD5Sum(md5_context_t *context)
deh_section_t deh_section_frame =
{
"Frame",
- NULL,
+ DEH_FrameInit,
DEH_FrameStart,
DEH_FrameParseLine,
NULL,