From 29571c16efee0d4d4a864a9ea222f5c3c2add4c3 Mon Sep 17 00:00:00 2001 From: Simon Howard Date: Thu, 13 Oct 2005 22:23:55 +0000 Subject: Fix logic for lost soul bounce Subversion-branch: /trunk/chocolate-doom Subversion-revision: 191 --- src/p_mobj.c | 21 ++++++++++++++++++--- 1 file changed, 18 insertions(+), 3 deletions(-) (limited to 'src') diff --git a/src/p_mobj.c b/src/p_mobj.c index 9d75d909..c73780f0 100644 --- a/src/p_mobj.c +++ b/src/p_mobj.c @@ -1,7 +1,7 @@ // Emacs style mode select -*- C++ -*- //----------------------------------------------------------------------------- // -// $Id: p_mobj.c 14 2005-07-23 17:46:19Z fraggle $ +// $Id: p_mobj.c 191 2005-10-13 22:23:55Z fraggle $ // // Copyright(C) 1993-1996 Id Software, Inc. // Copyright(C) 2005 Simon Howard @@ -22,6 +22,9 @@ // 02111-1307, USA. // // $Log$ +// Revision 1.4 2005/10/13 22:23:55 fraggle +// Fix logic for lost soul bounce +// // Revision 1.3 2005/07/23 17:46:19 fraggle // Import bouncing lost soul fix from prboom // @@ -38,7 +41,7 @@ //----------------------------------------------------------------------------- static const char -rcsid[] = "$Id: p_mobj.c 14 2005-07-23 17:46:19Z fraggle $"; +rcsid[] = "$Id: p_mobj.c 191 2005-10-13 22:23:55Z fraggle $"; #include "i_system.h" #include "z_zone.h" @@ -313,8 +316,20 @@ void P_ZMovement (mobj_t* mo) // Final Doom and Ultimate Doom. So we test demo_compatibility *and* // gamemission. (Note we assume that Doom1 is always Ult Doom, which // seems to hold for most published demos.) + // + // fraggle - cph got the logic here slightly wrong. There are three + // versions of Doom 1.9: + // + // * The version used in registered doom 1.9 + doom2 - no bounce + // * The version used in ultimate doom - has bounce + // * The version used in final doom - has bounce + // + // So we need to check that this is either retail or commercial + // (but not doom2) - int correct_lost_soul_bounce = gamemission != doom2; + int correct_lost_soul_bounce + = (gamemode == retail || gamemode == commercial) + && gamemission != doom2; if (correct_lost_soul_bounce && mo->flags & MF_SKULLFLY) { -- cgit v1.2.3