black
This commit is contained in:
parent
af4cd92488
commit
8a42b87bd6
@ -27,7 +27,7 @@ log = logging.getLogger("red.fox_v3.werewolf.builder")
|
|||||||
ROLE_DICT = {name: cls for name, cls in roles.__dict__.items() if isinstance(cls, type)}
|
ROLE_DICT = {name: cls for name, cls in roles.__dict__.items() if isinstance(cls, type)}
|
||||||
ROLE_LIST = sorted(
|
ROLE_LIST = sorted(
|
||||||
[cls for cls in ROLE_DICT.values()],
|
[cls for cls in ROLE_DICT.values()],
|
||||||
key=attrgetter('alignment'),
|
key=attrgetter("alignment"),
|
||||||
)
|
)
|
||||||
|
|
||||||
log.debug(f"{ROLE_DICT=}")
|
log.debug(f"{ROLE_DICT=}")
|
||||||
|
@ -1,9 +1,8 @@
|
|||||||
import asyncio
|
import asyncio
|
||||||
import inspect
|
|
||||||
import logging
|
import logging
|
||||||
import random
|
import random
|
||||||
from collections import deque
|
from collections import deque
|
||||||
from typing import List, Any, Dict, Set, Union
|
from typing import Dict, List, Union
|
||||||
|
|
||||||
import discord
|
import discord
|
||||||
from redbot.core import commands
|
from redbot.core import commands
|
||||||
@ -338,7 +337,7 @@ class Game:
|
|||||||
if check():
|
if check():
|
||||||
return
|
return
|
||||||
await self.village_channel.send(
|
await self.village_channel.send(
|
||||||
embed=discord.Embed(title=f"**{HALF_DAY_LENGTH/60} minutes of daylight remain...**")
|
embed=discord.Embed(title=f"**{HALF_DAY_LENGTH / 60} minutes of daylight remain...**")
|
||||||
)
|
)
|
||||||
await asyncio.sleep(HALF_DAY_LENGTH) # 4 minute days FixMe to 120 later
|
await asyncio.sleep(HALF_DAY_LENGTH) # 4 minute days FixMe to 120 later
|
||||||
|
|
||||||
|
@ -1,7 +1,11 @@
|
|||||||
import logging
|
import logging
|
||||||
|
|
||||||
from werewolf.constants import ALIGNMENT_TOWN, ALIGNMENT_WEREWOLF, CATEGORY_TOWN_INVESTIGATIVE, \
|
from werewolf.constants import (
|
||||||
CATEGORY_TOWN_RANDOM
|
ALIGNMENT_TOWN,
|
||||||
|
ALIGNMENT_WEREWOLF,
|
||||||
|
CATEGORY_TOWN_INVESTIGATIVE,
|
||||||
|
CATEGORY_TOWN_RANDOM,
|
||||||
|
)
|
||||||
from werewolf.listener import wolflistener
|
from werewolf.listener import wolflistener
|
||||||
from werewolf.night_powers import pick_target
|
from werewolf.night_powers import pick_target
|
||||||
from werewolf.role import Role
|
from werewolf.role import Role
|
||||||
@ -91,7 +95,7 @@ class Seer(Role):
|
|||||||
|
|
||||||
if alignment == ALIGNMENT_WEREWOLF:
|
if alignment == ALIGNMENT_WEREWOLF:
|
||||||
out = "Your insight reveals this player to be a **Werewolf!**"
|
out = "Your insight reveals this player to be a **Werewolf!**"
|
||||||
else: # Don't reveal neutrals
|
else: # Don't reveal neutrals
|
||||||
out = "You fail to find anything suspicious about this player..."
|
out = "You fail to find anything suspicious about this player..."
|
||||||
|
|
||||||
await self.player.send_dm(out)
|
await self.player.send_dm(out)
|
||||||
|
@ -69,5 +69,5 @@ class WolfVote(VoteGroup):
|
|||||||
|
|
||||||
await self.channel.send(
|
await self.channel.send(
|
||||||
"{} has voted to kill {}".format(author.mention, target.member.display_name),
|
"{} has voted to kill {}".format(author.mention, target.member.display_name),
|
||||||
allowed_mentions=discord.AllowedMentions(everyone=False, users=[author])
|
allowed_mentions=discord.AllowedMentions(everyone=False, users=[author]),
|
||||||
)
|
)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user