From 9d04c42219a0f16794c1c78c9ca3a46d5c71827b Mon Sep 17 00:00:00 2001 From: hendricks266 Date: Mon, 10 Oct 2011 00:07:00 +0000 Subject: [PATCH] Tripbombs now stop producing laserlines when they reach invalid space. In effect, tripbombs facing the wrong way will not make infinite laser lines. fix: http://forums.duke4.net/topic/4907-laserline-crash-bug/ git-svn-id: https://svn.eduke32.com/eduke32@2072 1a8010ca-5511-0410-912e-c29ae57300e0 --- polymer/eduke32/source/actors.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/polymer/eduke32/source/actors.c b/polymer/eduke32/source/actors.c index eade36248..16f3df9b4 100644 --- a/polymer/eduke32/source/actors.c +++ b/polymer/eduke32/source/actors.c @@ -1775,6 +1775,7 @@ ACTOR_STATIC void G_MoveStandables(void) if (actor[i].t_data[6] != 1) { // we're on a trip wire + int16_t cursectnum; while (x > 0) { @@ -1792,6 +1793,11 @@ ACTOR_STATIC void G_MoveStandables(void) break; } x -= 1024; + + cursectnum = s->sectnum; + updatesector(s->x, s->y, &cursectnum); + if (cursectnum < 0) + break; } }