From 5f70ffd69baf1dfab6a789d8b4a7d4a2e25b18c7 Mon Sep 17 00:00:00 2001 From: c0de Date: Fri, 11 Nov 2022 12:52:54 -0600 Subject: [PATCH] Init before registering command --- GhostBallBot/game/end_game.py | 2 +- GhostBallBot/game/guess.py | 2 +- GhostBallBot/game/help.py | 2 +- GhostBallBot/game/new_game.py | 2 +- GhostBallBot/game/points.py | 2 +- 5 files changed, 5 insertions(+), 5 deletions(-) diff --git a/GhostBallBot/game/end_game.py b/GhostBallBot/game/end_game.py index 67664a8..8212dfc 100644 --- a/GhostBallBot/game/end_game.py +++ b/GhostBallBot/game/end_game.py @@ -15,8 +15,8 @@ class EndGameManager(BaseGameManager): """Commands that run at the end of a game""" def __init__(self): - self.commands.append(("resolve", self.stop)) super().__init__() + self.commands.append(("resolve", self.stop)) def __stop_args__(self): pieces = self.message.content.split() diff --git a/GhostBallBot/game/guess.py b/GhostBallBot/game/guess.py index d6cf294..8680f48 100644 --- a/GhostBallBot/game/guess.py +++ b/GhostBallBot/game/guess.py @@ -14,8 +14,8 @@ class GuessManager(BaseGameManager): """Commands that run when a player makes a guess""" def __init__(self): - self.commands.append(("guess", self.guess)) super().__init__() + self.commands.append(("guess", self.guess)) async def guess(self): """ diff --git a/GhostBallBot/game/help.py b/GhostBallBot/game/help.py index 6b18687..d1fcfef 100644 --- a/GhostBallBot/game/help.py +++ b/GhostBallBot/game/help.py @@ -11,8 +11,8 @@ class HelpManager(BaseGameManager): """Commands that run when a player asks for help""" def __init__(self): - self.commands.append(("help", self.help)) super().__init__() + self.commands.append(("help", self.help)) async def help(self): """help command - Sends a DM to the requesting user with available commands""" diff --git a/GhostBallBot/game/new_game.py b/GhostBallBot/game/new_game.py index 276d5a9..e2f1f56 100644 --- a/GhostBallBot/game/new_game.py +++ b/GhostBallBot/game/new_game.py @@ -14,8 +14,8 @@ class NewGameManager(BaseGameManager): """Commands that run at the start of a new game""" def __init__(self): - self.commands.append(("braveball", self.start)) super().__init__() + self.commands.append(("braveball", self.start)) async def start(self): """ diff --git a/GhostBallBot/game/points.py b/GhostBallBot/game/points.py index 3c14b3b..a5aff56 100644 --- a/GhostBallBot/game/points.py +++ b/GhostBallBot/game/points.py @@ -12,8 +12,8 @@ class PointsManager(BaseGameManager): """Commands that run when a player makes a guess""" def __init__(self): - self.commands.append(("points", self.points)) super().__init__() + self.commands.append(("points", self.points)) async def points(self): """