From 81de8409f2cb50b953b529490c67f928638cf575 Mon Sep 17 00:00:00 2001 From: informaniac Date: Fri, 1 Dec 2017 18:15:24 +0100 Subject: [PATCH] balance_util is created and used to create the BalanceTtrsPlayer --- games/ttrs.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/games/ttrs.py b/games/ttrs.py index 4b854ab..645127c 100755 --- a/games/ttrs.py +++ b/games/ttrs.py @@ -475,11 +475,11 @@ if __name__ == '__main__': def start_game(player_id, xpos): pg = Playground(10, 16) + balance_util = blup.balance_util.BalanceUtil(sock, player_id) if args.pygame: player = TestTtrsPlayer(pg) elif args.balance is not None: - host, port = args.balance.split(':') - player = BalanceTtrsPlayer(pg, (host, int(port)), player_id) + player = BalanceTtrsPlayer(pg, balance_util) rnd = random.Random(seed) game = TtrsGame(pg, player, rnd) painter.add_game(game, xpos, 0)