X-Git-Url: https://de.git.xonotic.org/?p=xonotic%2Fxonotic-data.pk3dir.git;a=blobdiff_plain;f=qcsrc%2Fserver%2Fbot%2Fdefault%2Fnavigation.qc;h=250b7cb09c639e45680e699514958d769b97a686;hp=88d189beec079d78f8c4bc7a662fdb8d70b53e4d;hb=5de12ffb837da41082e80015a3dca1f46c68eed4;hpb=ada305719835791c8f4d72c822f5cbecd4f8609c diff --git a/qcsrc/server/bot/default/navigation.qc b/qcsrc/server/bot/default/navigation.qc index 88d189beec..250b7cb09c 100644 --- a/qcsrc/server/bot/default/navigation.qc +++ b/qcsrc/server/bot/default/navigation.qc @@ -13,6 +13,7 @@ #include #include +#include #include .float speed; @@ -915,7 +916,7 @@ entity navigation_findnearestwaypoint_withdist_except(entity ent, float walkfrom vector pm2 = ent.origin + ent.maxs; // do two scans, because box test is cheaper - IL_EACH(g_waypoints, it != ent && it != except, + IL_EACH(g_waypoints, it != ent && it != except && !(it.wpflags & WAYPOINTFLAG_TELEPORT), { if(boxesoverlap(pm1, pm2, it.absmin, it.absmax)) { @@ -1701,8 +1702,16 @@ int navigation_poptouchedgoals(entity this) gc_min = this.goalcurrent.origin - '1 1 1' * 12; gc_max = this.goalcurrent.origin + '1 1 1' * 12; } - if(!boxesoverlap(this.absmin, this.absmax, gc_min, gc_max)) - break; + if (time < this.ladder_time) + { + if (!boxesoverlap(this.absmin, this.absmax - eZ * STAT(PL_MAX, this).z, gc_min, gc_max)) + break; + } + else + { + if (!boxesoverlap(this.absmin, this.absmax, gc_min, gc_max)) + break; + } // Detect personal waypoints if(this.aistatus & AI_STATUS_WAYPOINT_PERSONAL_GOING)