Skip to content

Commit

Permalink
kurisu.py: Fix reference to specific channels and roles
Browse files Browse the repository at this point in the history
  • Loading branch information
FrozenChen committed Sep 4, 2021
1 parent f71cad2 commit 3f7d3ce
Showing 1 changed file with 28 additions and 24 deletions.
52 changes: 28 additions & 24 deletions kurisu.py
Original file line number Diff line number Diff line change
Expand Up @@ -178,30 +178,9 @@ def __init__(self, command_prefix, description, commit, branch):
'hardware': None,
}

self.assistance_channels = (
self.channels['3ds-assistance-1'],
self.channels['3ds-assistance-2'],
self.channels['wiiu-assistance'],
self.channels['switch-assistance-1'],
self.channels['switch-assistance-2'],
self.channels['hacking-general'],
self.channels['legacy-systems'],
self.channels['tech-talk'],
self.channels['hardware'],
)

self.staff_roles = {'Owner': self.roles['Owner'],
'SuperOP': self.roles['SuperOP'],
'OP': self.roles['OP'],
'HalfOP': self.roles['HalfOP'],
'Staff': self.roles['Staff'],
}

self.helper_roles = {"3DS": self.roles['On-Duty 3DS'],
"WiiU": self.roles['On-Duty Wii U'],
"Switch": self.roles['On-Duty Switch'],
"Legacy": self.roles['On-Duty Legacy']
}
self.helper_roles: dict[str, discord.Role] = {}
self.assistance_channels: tuple[discord.TextChannel] = tuple()
self.staff_roles: dict[str, discord.Role] = {}

self.failed_cogs = []
self.channels_not_found = []
Expand Down Expand Up @@ -240,6 +219,31 @@ async def on_ready(self):
await self.load_channels()
await self.load_roles()

self.helper_roles = {"3DS": self.roles['On-Duty 3DS'],
"WiiU": self.roles['On-Duty Wii U'],
"Switch": self.roles['On-Duty Switch'],
"Legacy": self.roles['On-Duty Legacy']
}

self.assistance_channels = (
self.channels['3ds-assistance-1'],
self.channels['3ds-assistance-2'],
self.channels['wiiu-assistance'],
self.channels['switch-assistance-1'],
self.channels['switch-assistance-2'],
self.channels['hacking-general'],
self.channels['legacy-systems'],
self.channels['tech-talk'],
self.channels['hardware'],
)

self.staff_roles = {'Owner': self.roles['Owner'],
'SuperOP': self.roles['SuperOP'],
'OP': self.roles['OP'],
'HalfOP': self.roles['HalfOP'],
'Staff': self.roles['Staff'],
}

self.err_channel = self.channels['bot-err']

startup_message = f'{self.user.name} has started! {self.guild} has {self.guild.member_count:,} members!'
Expand Down

0 comments on commit 3f7d3ce

Please sign in to comment.