Fix ambiguous check causing bots to avoid jumppads and teleporters (and to always...
authorterencehill <piuntn@gmail.com>
Sat, 17 Dec 2016 20:44:10 +0000 (21:44 +0100)
committerterencehill <piuntn@gmail.com>
Mon, 19 Dec 2016 17:28:26 +0000 (18:28 +0100)
qcsrc/server/bot/default/navigation.qc

index 19c0ed8..70391d5 100644 (file)
@@ -879,7 +879,7 @@ void navigation_poptouchedgoals(entity this)
        if(this.goalcurrent.wpflags & WAYPOINTFLAG_TELEPORT)
        {
                if(this.lastteleporttime>0)
-               if(time-this.lastteleporttime<(this.goalcurrent.wpflags & WAYPOINTFLAG_PERSONAL)?2:0.15)
+               if(time - this.lastteleporttime < ((this.goalcurrent.wpflags & WAYPOINTFLAG_PERSONAL) ? 2 : 0.15))
                {
                        if(this.aistatus & AI_STATUS_WAYPOINT_PERSONAL_GOING)
                        if(this.goalcurrent.wpflags & WAYPOINTFLAG_PERSONAL && this.goalcurrent.owner==this)