From: Juhu <5894800-Juhu_@users.noreply.gitlab.com> Date: Tue, 30 May 2023 15:31:04 +0000 (+0200) Subject: battle royale: fix incorrect check for sky above the dropship X-Git-Url: https://git.rm.cloudns.org/?a=commitdiff_plain;h=cb70ed49a206c79a639f0446cf7269cd860b1a67;p=xonotic%2Fxonotic-data.pk3dir.git battle royale: fix incorrect check for sky above the dropship --- diff --git a/qcsrc/common/gamemodes/gamemode/br/sv_dropship.qc b/qcsrc/common/gamemodes/gamemode/br/sv_dropship.qc index d118a04d2..236b67181 100644 --- a/qcsrc/common/gamemodes/gamemode/br/sv_dropship.qc +++ b/qcsrc/common/gamemodes/gamemode/br/sv_dropship.qc @@ -54,6 +54,9 @@ entity dropship_initialize() startorigin = dropship_seekPoint(this, startorigin, 1, 0, 1); } while((tracebox(startorigin, this.mins, this.maxs, startorigin + '0 0 1', MOVE_NORMAL, this), trace_fraction) >= 1); + if(!(trace_dphitq3surfaceflags & (Q3SURFACEFLAG_SKY | Q3SURFACEFLAG_NOIMPACT | Q3SURFACEFLAG_NOMARKS))) // dropship did not reach the sky + continue; + mult = dropship_getMultipliers(); startorigin = dropship_seekPoint(this, startorigin, 0, 1, mult.x); startorigin = dropship_seekPoint(this, startorigin, 1, 1, mult.y); @@ -69,8 +72,6 @@ entity dropship_initialize() dropship_path_length = trace_fraction * vlen(endorigin - startorigin); if(dropship_path_length < (vlen(vec2(world.maxs - world.mins)) / 4)) // if the dropship path isn't atleast one quarter of the diagonal length of the map, retry, we're probably in a building continue; - if(!(trace_dphitq3surfaceflags & (Q3SURFACEFLAG_SKY | Q3SURFACEFLAG_NOIMPACT | Q3SURFACEFLAG_NOMARKS))) // dropship did not reach the sky - continue; endorigin = trace_endpos; dropship_path_direction = normalize(endorigin - startorigin);