fix: crash with lift handling

fix: some random crashes with some maps
fix: do not look at breakable until totally sure we're can break it
fix: wrong distance calculation in last enemy position randomizer
fix: problems with cs 1.5 won when built with ``nosmid`` switch (still crashes from time to time)
ctrl: add  bots death count to``yb list`` command
graph: disable buckets for small number of nodes graphs
graph: verify graph consistency and select appropriate pathfinding algorithm
misc: added mor vox sentences to welcome a player
This commit is contained in:
jeefo 2024-12-20 01:04:59 +03:00
commit 3a014e471b
No known key found for this signature in database
GPG key ID: D696786B81B667C8
13 changed files with 172 additions and 71 deletions

View file

@ -348,19 +348,20 @@ int BotControl::cmdExec () {
int BotControl::cmdNode () {
enum args { root, alias, cmd, cmd2 };
static Array <StringRef> allowedOnDedicatedServer {
static Array <StringRef> allowedOnHLDS {
"acquire_editor",
"upload",
"save",
"load",
"help",
"erase",
"fileinfo"
"fileinfo",
"check"
};
// check if cmd is allowed on dedicated server
auto isAllowedOnDedicatedServer = [] (StringRef str) -> bool {
for (const auto &test : allowedOnDedicatedServer) {
auto isAllowedOnHLDS = [] (StringRef str) -> bool {
for (const auto &test : allowedOnHLDS) {
if (test == str) {
return true;
}
@ -369,7 +370,7 @@ int BotControl::cmdNode () {
};
// graph editor supported only with editor
if (game.isDedicated () && !graph.hasEditor () && !isAllowedOnDedicatedServer (arg <StringRef> (cmd))) {
if (game.isDedicated () && !graph.hasEditor () && !isAllowedOnHLDS (arg <StringRef> (cmd))) {
msg ("Unable to use graph edit commands without setting graph editor player. Please use \"graph acquire_editor\" to acquire rights for graph editing.");
return BotCommandResult::Handled;
}