Support for 'yb wp clean' to take neareset to local player waypoint if no arguments passed.
This commit is contained in:
parent
83cf81cbca
commit
17039524dc
1 changed files with 9 additions and 0 deletions
|
|
@ -373,6 +373,15 @@ int handleBotCommands (edict_t *ent, const char *arg0, const char *arg1, const c
|
|||
}
|
||||
}
|
||||
}
|
||||
else {
|
||||
int nearest = waypoints.getEditorNeareset (), totalCleared = 0;
|
||||
|
||||
if (waypoints.exists (nearest)) {
|
||||
totalCleared += waypoints.removeUselessConnections (nearest);
|
||||
|
||||
engine.print ("Done. Waypoint %d had %d useless paths.", nearest, totalCleared);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// teleport player to specified waypoint
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue