Skip to content

Commit

Permalink
Fix crash bot_nav_use_place when place name is not exists
Browse files Browse the repository at this point in the history
  • Loading branch information
s1lentq committed Dec 22, 2023
1 parent b413577 commit 28e2bc4
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion regamedll/dlls/bot/cs_bot_manager.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -630,11 +630,15 @@ void CCSBotManager::ServerCommand(const char *pcmd)
{
CONSOLE_ECHO("Ambiguous\n");
}
else
else if (found)
{
CONSOLE_ECHO("Current place set to '%s'\n", found->GetName());
SetNavPlace(found->GetID());
}
else
{
CONSOLE_ECHO("Error - place name '%s' no exists in phrases BotChatter.db\n", msg);
}
}
}
else if (FStrEq(pcmd, "bot_nav_toggle_place_mode"))
Expand Down

0 comments on commit 28e2bc4

Please sign in to comment.