X-Git-Url: http://de.git.xonotic.org/?p=xonotic%2Fxonotic-data.pk3dir.git;a=blobdiff_plain;f=qcsrc%2Fserver%2Fimpulse.qc;h=a7f9554294fc40ad246505743f4721a6b194b199;hp=eb54a98e9ef5daa7a22ab183af99dc5d3594a1ea;hb=3ea922dd69aea306c1fb733a1adab7d3b9e9ec85;hpb=608df3eea77373f3457a825a5e9047b8ac11fe20 diff --git a/qcsrc/server/impulse.qc b/qcsrc/server/impulse.qc index eb54a98e9e..a7f9554294 100644 --- a/qcsrc/server/impulse.qc +++ b/qcsrc/server/impulse.qc @@ -52,8 +52,6 @@ // weapon switching impulses -bool autocvar_g_weaponswitch_debug; - #define X(slot) \ IMPULSE(weapon_group_##slot) \ { \ @@ -553,6 +551,9 @@ IMPULSE(waypoint_clear_personal) { delete(this.personal); this.personal = NULL; + + if((g_cts || g_race) && autocvar_g_allow_checkpoints) + ClientKill(this); } sprint(this, "personal waypoint cleared\n"); } @@ -564,6 +565,8 @@ IMPULSE(waypoint_clear) { delete(this.personal); this.personal = NULL; + if((g_cts || g_race) && autocvar_g_allow_checkpoints) + ClientKill(this); } sprint(this, "all waypoints cleared\n"); } @@ -581,6 +584,13 @@ IMPULSE(navwaypoint_remove) entity e = navigation_findnearestwaypoint(this, false); if (!e) return; if (e.wpflags & WAYPOINTFLAG_GENERATED) return; + + if (e.wphardwired) + { + LOG_INFO("^1Warning: ^7Removal of hardwired waypoints is not allowed in the editor. Please remove links from/to this waypoint (", vtos(e.origin), ") by hand from maps/", mapname, ".waypoints.hardwired\n"); + return; + } + bprint(strcat("Waypoint removed at ", vtos(e.origin), "\n")); waypoint_remove(e); }