Skip to content

Commit

Permalink
cmdinterface: Add "autobalance" command
Browse files Browse the repository at this point in the history
  • Loading branch information
past-due committed Jul 6, 2024
1 parent 95b41bf commit 9cec0af
Showing 1 changed file with 13 additions and 0 deletions.
13 changes: 13 additions & 0 deletions src/stdinreader.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1047,6 +1047,19 @@ int cmdInputThreadFunc(void *)
}
}
}
else if(!strncmpl(line, "autobalance"))
{
wzAsyncExecOnMainThread([] {
if (autoBalancePlayersCmd())
{
wz_command_interface_output("WZCMD info: autobalanced players\n");
}
else
{
wz_command_interface_output("WZCMD error: autobalance failed\n");
}
});
}
else if(!strncmpl(line, "shutdown now"))
{
inexit = true;
Expand Down

0 comments on commit 9cec0af

Please sign in to comment.