From: Mario Date: Sat, 24 Aug 2019 08:24:46 +0000 (+1000) Subject: Don't link teleporter destinations to CSQC if they aren't targeted X-Git-Tag: xonotic-v0.8.5~1373 X-Git-Url: https://git.rm.cloudns.org/?a=commitdiff_plain;h=6b67fe94d769ba35511446b032ef8335609e9f66;p=xonotic%2Fxonotic-data.pk3dir.git Don't link teleporter destinations to CSQC if they aren't targeted --- diff --git a/qcsrc/common/mapobjects/misc/teleport_dest.qc b/qcsrc/common/mapobjects/misc/teleport_dest.qc index 126a20ea2..e7eedd52c 100644 --- a/qcsrc/common/mapobjects/misc/teleport_dest.qc +++ b/qcsrc/common/mapobjects/misc/teleport_dest.qc @@ -43,7 +43,10 @@ spawnfunc(info_teleport_destination) { } else + { objerror (this, "^3Teleport destination without a targetname"); + return; // don't link it to CSQC in this case! + } teleport_dest_link(this); } diff --git a/qcsrc/common/mapobjects/teleporters.qc b/qcsrc/common/mapobjects/teleporters.qc index 339ade52a..da86cabce 100644 --- a/qcsrc/common/mapobjects/teleporters.qc +++ b/qcsrc/common/mapobjects/teleporters.qc @@ -257,7 +257,7 @@ void teleport_findtarget(entity this) if(n == 0) { // no dest! - objerror (this, "Teleporter with nonexistant target"); + objerror (this, "Teleporter with nonexistent target"); return; } else if(n == 1)