From 9f91a4082527d6debbdc1b6045106126777a7f65 Mon Sep 17 00:00:00 2001 From: bones_was_here Date: Fri, 11 Sep 2020 20:57:25 +1000 Subject: [PATCH] q3compat: Fix some nexuiz maps that rely on adjacent bboxes counting as touching --- qcsrc/lib/warpzone/common.qc | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/qcsrc/lib/warpzone/common.qc b/qcsrc/lib/warpzone/common.qc index 830c56de6..34c7bb2ba 100644 --- a/qcsrc/lib/warpzone/common.qc +++ b/qcsrc/lib/warpzone/common.qc @@ -787,10 +787,13 @@ entity WarpZone_RefSys_SpawnSameRefSys(entity me) bool WarpZoneLib_ExactTrigger_Touch(entity this, entity toucher) { vector emin = toucher.absmin, emax = toucher.absmax; - // the engine offsets absolute bounding boxes by a single quake unit - // we must undo that here to allow accurate touching - emin += '1 1 1'; - emax -= '1 1 1'; + if(STAT(Q3COMPAT)) + { + // DP's tracebox enlarges absolute bounding boxes by a single quake unit + // we must undo that here to allow accurate touching + emin += '1 1 1'; + emax -= '1 1 1'; + } return !WarpZoneLib_BoxTouchesBrush(emin, emax, this, toucher); } -- 2.39.2