shithub: choc

Download patch

ref: fe4125a1a24abf5d137632122f7acfb629726a24
parent: 74560947e2ff285718ed0ed71ae00bf1e77441e9
author: Simon Howard <fraggle@gmail.com>
date: Fri Sep 22 18:43:28 EDT 2006

Call the SpechitOverrun _after_ incrementing numspechit. Thanks to Quasar
for pointing out this mistake.

Subversion-branch: /trunk/chocolate-doom
Subversion-revision: 655

--- a/src/p_map.c
+++ b/src/p_map.c
@@ -1,7 +1,7 @@
 // Emacs style mode select   -*- C++ -*- 
 //-----------------------------------------------------------------------------
 //
-// $Id: p_map.c 592 2006-09-01 20:07:25Z fraggle $
+// $Id: p_map.c 655 2006-09-22 22:43:28Z fraggle $
 //
 // Copyright(C) 1993-1996 Id Software, Inc.
 // Copyright(C) 2005 Simon Howard, Andrey Budko
@@ -46,7 +46,7 @@
 //-----------------------------------------------------------------------------
 
 static const char
-rcsid[] = "$Id: p_map.c 592 2006-09-01 20:07:25Z fraggle $";
+rcsid[] = "$Id: p_map.c 655 2006-09-22 22:43:28Z fraggle $";
 
 #include <stdlib.h>
 
@@ -276,15 +276,14 @@
     // if contacted a special line, add it to the list
     if (ld->special)
     {
+        spechit[numspechit] = ld;
+	numspechit++;
+
         // fraggle: spechits overrun emulation code from prboom-plus
         if (numspechit > MAXSPECIALCROSS_ORIGINAL)
         {
             SpechitOverrun(ld);
         }
-
-        spechit[numspechit] = ld;
-        
-	numspechit++;
     }
 
     return true;