From a396e160c74ff70b6d3c6d455e5091cdc48845a2 Mon Sep 17 00:00:00 2001 From: Juhu <5894800-Juhu_@users.noreply.gitlab.com> Date: Thu, 9 Feb 2023 13:07:50 +0100 Subject: [PATCH] q3compat: allow triggering the finish line without triggering all checkpoints --- qcsrc/server/race.qc | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/qcsrc/server/race.qc b/qcsrc/server/race.qc index f8af3fc5f..c856ccfb7 100644 --- a/qcsrc/server/race.qc +++ b/qcsrc/server/race.qc @@ -736,7 +736,7 @@ void checkpoint_passed(entity this, entity player) } } - if((player.race_checkpoint == -1 && this.race_checkpoint == 0) || (player.race_checkpoint == this.race_checkpoint)) + if((player.race_checkpoint == -1 && this.race_checkpoint == 0) || (player.race_checkpoint == this.race_checkpoint) || (q3compat && this.race_checkpoint == race_timed_checkpoint && player.race_checkpoint > 0)) { if(this.race_penalty) { @@ -825,7 +825,9 @@ bool race_waypointsprite_visible_for_player(entity this, entity player, entity v if(this.realowner) own = this.realowner; // target support - if(view.race_checkpoint == -1 || own.race_checkpoint == -2) + if(q3compat && own.race_checkpoint == race_timed_checkpoint && player.race_checkpoint > 0) + return true; + else if(view.race_checkpoint == -1 || own.race_checkpoint == -2) return true; else if(view.race_checkpoint == own.race_checkpoint) return true; -- 2.39.2