bobloy / Fox-V3

Cogs for Red-DiscordBot V3 by Bobloy
https://discord.gg/GET4DVk
GNU Affero General Public License v3.0
54 stars 91 forks source link

Can't start werewolf game #201

Open VinhDevNguyen opened 2 years ago

VinhDevNguyen commented 2 years ago

Describe the bug When i start game with ww start, it tell Error in command 'ww start'. Check your console or logs for details. Here is the console log:

[13:44:44] ERROR    [red.fox_v3.werewolf.role] Villager(None)

╭───────────────────── Traceback (most recent call last) ──────────────────────╮

│ /root/.local/share/Red-DiscordBot/data/padapew/cogs/CogManager/cogs/werewolf │

│ /role.py:127 in _at_game_start                                               │

│ ❱ 127             await self.player.send_dm(self.game_start_message)  # Mayb │

│       eventually                                                             │

╰──────────────────────────────────────────────────────────────────────────────╯

AttributeError: 'NoneType' object has no attribute 'send_dm'

           ERROR    [red.fox_v3.werewolf.role] Seer(None)

╭───────────────────── Traceback (most recent call last) ──────────────────────╮

│ /root/.local/share/Red-DiscordBot/data/padapew/cogs/CogManager/cogs/werewolf │

│ /role.py:127 in _at_game_start                                               │

│ ❱ 127             await self.player.send_dm(self.game_start_message)  # Mayb │

│       eventually                                                             │

╰──────────────────────────────────────────────────────────────────────────────╯

AttributeError: 'NoneType' object has no attribute 'send_dm'

           ERROR    [red.fox_v3.werewolf.role] Shifter(None)

╭───────────────────── Traceback (most recent call last) ──────────────────────╮

│ /root/.local/share/Red-DiscordBot/data/padapew/cogs/CogManager/cogs/werewolf │

│ /role.py:127 in _at_game_start                                               │

│ ❱ 127             await self.player.send_dm(self.game_start_message)  # Mayb │

│       eventually                                                             │

╰──────────────────────────────────────────────────────────────────────────────╯

AttributeError: 'NoneType' object has no attribute 'send_dm'

           ERROR    [red.fox_v3.werewolf.role] Villager(None)

╭───────────────────── Traceback (most recent call last) ──────────────────────╮

│ /root/.local/share/Red-DiscordBot/data/padapew/cogs/CogManager/cogs/werewolf │

│ /role.py:127 in _at_game_start                                               │

│ ❱ 127             await self.player.send_dm(self.game_start_message)  # Mayb │

│       eventually                                                             │

╰──────────────────────────────────────────────────────────────────────────────╯

AttributeError: 'NoneType' object has no attribute 'send_dm'

           ERROR    [red.fox_v3.werewolf.role] Seer(None)

╭───────────────────── Traceback (most recent call last) ──────────────────────╮

│ /root/.local/share/Red-DiscordBot/data/padapew/cogs/CogManager/cogs/werewolf │

│ /role.py:127 in _at_game_start                                               │

│ ❱ 127             await self.player.send_dm(self.game_start_message)  # Mayb │

│       eventually                                                             │

╰──────────────────────────────────────────────────────────────────────────────╯

AttributeError: 'NoneType' object has no attribute 'send_dm'

           ERROR    [red.fox_v3.werewolf.role] Shifter(None)

╭───────────────────── Traceback (most recent call last) ──────────────────────╮

│ /root/.local/share/Red-DiscordBot/data/padapew/cogs/CogManager/cogs/werewolf │

│ /role.py:127 in _at_game_start                                               │

│ ❱ 127             await self.player.send_dm(self.game_start_message)  # Mayb │

│       eventually                                                             │

╰──────────────────────────────────────────────────────────────────────────────╯

AttributeError: 'NoneType' object has no attribute 'send_dm'

           ERROR    [red] Exception in command 'ww start'

╭───────────────────── Traceback (most recent call last) ──────────────────────╮

│ /usr/local/lib/python3.8/dist-packages/discord/ext/commands/core.py:85 in    │

│ wrapped                                                                      │

│ ❱   85             ret = await coro(*args, **kwargs)                         │

│ /root/.local/share/Red-DiscordBot/data/padapew/cogs/CogManager/cogs/werewolf │

│ /werewolf.py:256 in ww_start                                                 │

│ ❱ 256         if not await game.setup(ctx):                                  │

│ /root/.local/share/Red-DiscordBot/data/padapew/cogs/CogManager/cogs/werewolf │

│ /game.py:247 in setup                                                        │

│ ❱  247         await self._at_game_start()  # This will add votegroups to se │

│ /root/.local/share/Red-DiscordBot/data/padapew/cogs/CogManager/cogs/werewolf │

│ /game.py:327 in _at_game_start                                               │

│ ❱  327         await self._notify("at_game_start")                           │

│ /root/.local/share/Red-DiscordBot/data/padapew/cogs/CogManager/cogs/werewolf │

│ /game.py:535 in _notify                                                      │

│ ❱  535             await asyncio.gather(*tasks)                              │

│ /root/.local/share/Red-DiscordBot/data/padapew/cogs/CogManager/cogs/werewolf │

│ /role.py:130 in _at_game_start                                               │

│ ❱ 130             raise e                                                    │

│ /root/.local/share/Red-DiscordBot/data/padapew/cogs/CogManager/cogs/werewolf │

│ /role.py:127 in _at_game_start                                               │

│ ❱ 127             await self.player.send_dm(self.game_start_message)  # Mayb │

│       eventually                                                             │

╰──────────────────────────────────────────────────────────────────────────────╯

AttributeError: 'NoneType' object has no attribute 'send_dm'