From 14141766c1d6223b7f97f8cb1efa747d31c933c2 Mon Sep 17 00:00:00 2001 From: Christoph Oelckers Date: Tue, 13 Dec 2022 14:04:39 +0100 Subject: [PATCH] - fixed a few cases of incorrect uses of 'mapSpawned'. --- wadsrc/static/zscript/games/duke/actors/heavyhbomb.zs | 4 ++-- wadsrc/static/zscript/games/duke/actors/recon.zs | 2 +- wadsrc/static/zscript/games/duke/actors/waterdrip.zs | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/wadsrc/static/zscript/games/duke/actors/heavyhbomb.zs b/wadsrc/static/zscript/games/duke/actors/heavyhbomb.zs index 7abc4d003..28c702f9c 100644 --- a/wadsrc/static/zscript/games/duke/actors/heavyhbomb.zs +++ b/wadsrc/static/zscript/games/duke/actors/heavyhbomb.zs @@ -197,9 +197,9 @@ class DukePipeBomb : DukeActor p.pals = Color(32, 0, 32, 0); } - if (!self.mapSpawned || ud.respawn_items == 0) + if (Owner != self || ud.respawn_items == 0) { - if (self.mapSpawned && ud.coop >= 1) + if (Owner == self && ud.coop >= 1) return false; self.Destroy(); diff --git a/wadsrc/static/zscript/games/duke/actors/recon.zs b/wadsrc/static/zscript/games/duke/actors/recon.zs index c2032d898..495ce0716 100644 --- a/wadsrc/static/zscript/games/duke/actors/recon.zs +++ b/wadsrc/static/zscript/games/duke/actors/recon.zs @@ -156,7 +156,7 @@ class DukeRecon : DukeActor self.angle += deltaangle(self.angle, (pactor.pos.XY - self.pos.XY).Angle()) * 0.25; } - if (self.temp_data[0] != 2 && self.temp_data[0] != 3 && Owner && Owner != self) + if (self.temp_data[0] != 2 && self.temp_data[0] != 3 && Owner) { double dist = (Owner.pos.XY - self.pos.XY).Length(); if (dist <= 96) diff --git a/wadsrc/static/zscript/games/duke/actors/waterdrip.zs b/wadsrc/static/zscript/games/duke/actors/waterdrip.zs index 009d71a82..e26dcf629 100644 --- a/wadsrc/static/zscript/games/duke/actors/waterdrip.zs +++ b/wadsrc/static/zscript/games/duke/actors/waterdrip.zs @@ -24,7 +24,7 @@ class DukeWaterDrip : DukeActor self.vel.X = frandom(1, 3); self.DoMove(CLIPMASK0); } - else if (owner == self) + else if (self.mapSpawned) { self.pos.Z += 4; self.temp_pos.Z = self.pos.Z;