Add HYTALE_ROLE_ID and use it for /hytale command
This commit is contained in:
3
bot.py
3
bot.py
@@ -36,6 +36,7 @@ AUDIT_CHANNEL_ID = int(os.getenv('AUDIT_CHANNEL_ID', '1340861451392520233'))
|
|||||||
ANNOUNCEMENT_CHANNEL_ID = int(os.getenv('ANNOUNCEMENT_CHANNEL_ID', '605864889940050088'))
|
ANNOUNCEMENT_CHANNEL_ID = int(os.getenv('ANNOUNCEMENT_CHANNEL_ID', '605864889940050088'))
|
||||||
ADMIN_ROLE_ID = int(os.getenv('ADMIN_ROLE_ID', '605867042104541194'))
|
ADMIN_ROLE_ID = int(os.getenv('ADMIN_ROLE_ID', '605867042104541194'))
|
||||||
MINECRAFT_ROLE_ID = int(os.getenv('MINECRAFT_ROLE_ID', '821163520942145556'))
|
MINECRAFT_ROLE_ID = int(os.getenv('MINECRAFT_ROLE_ID', '821163520942145556'))
|
||||||
|
HYTALE_ROLE_ID = int(os.getenv('HYTALE_ROLE_ID', '1460750779848589548'))
|
||||||
COOL_KIDS_ROLE_ID = int(os.getenv('COOL_KIDS_ROLE_ID', '788968178117902347'))
|
COOL_KIDS_ROLE_ID = int(os.getenv('COOL_KIDS_ROLE_ID', '788968178117902347'))
|
||||||
OWNER_ID = int(os.getenv('OWNER_ID', '238728085342519296'))
|
OWNER_ID = int(os.getenv('OWNER_ID', '238728085342519296'))
|
||||||
REACTION_MESSAGE_ID = int(os.getenv('REACTION_MESSAGE_ID', '744047519696420914'))
|
REACTION_MESSAGE_ID = int(os.getenv('REACTION_MESSAGE_ID', '744047519696420914'))
|
||||||
@@ -590,7 +591,7 @@ async def minecraft(interaction: discord.Interaction, minecraft_username: str):
|
|||||||
|
|
||||||
@client.tree.command(name="hytale", description="Request whitelist on the Hytale server")
|
@client.tree.command(name="hytale", description="Request whitelist on the Hytale server")
|
||||||
@app_commands.describe(hytale_username="Your Hytale username")
|
@app_commands.describe(hytale_username="Your Hytale username")
|
||||||
@has_role_check(MINECRAFT_ROLE_ID)
|
@has_role_check(HYTALE_ROLE_ID)
|
||||||
async def hytale(interaction: discord.Interaction, hytale_username: str):
|
async def hytale(interaction: discord.Interaction, hytale_username: str):
|
||||||
"""Request whitelist on the Hytale server"""
|
"""Request whitelist on the Hytale server"""
|
||||||
try:
|
try:
|
||||||
|
|||||||
Reference in New Issue
Block a user