From b52118ca14e1f93fe1d8a485c2eae0e08bebb06b Mon Sep 17 00:00:00 2001 From: SixpennyYard <88838512+SixpennyYard@users.noreply.github.com> Date: Thu, 9 May 2024 20:19:42 +0200 Subject: [PATCH] Update piemc.py Fix issues with setmaxplayers and fakeonline accessing the wrong variables. --- piemc/commands/piemc.py | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/piemc/commands/piemc.py b/piemc/commands/piemc.py index a287cb1..b616011 100644 --- a/piemc/commands/piemc.py +++ b/piemc/commands/piemc.py @@ -8,13 +8,14 @@ def ping(server): def stop(server): server.logger.info("Stopping the server...") server.stop() - + @ConsoleCMD def setmaxplayers(server, maxplayers): - server.max_players = maxplayers - server.update_server_status() + server.bedrock_server.max_players = maxplayers + server.bedrock_server.update_server_status() @ConsoleCMD def fakeonline(server, amount): - server.players_online = amount - server.update_server_status() + server.bedrock_server.players_online = amount + server.bedrock_server.update_server_status() +