now colors should work I think
This commit is contained in:
parent
0dfa34fcd7
commit
92b0fd1cd3
1 changed files with 2 additions and 1 deletions
|
@ -10,12 +10,13 @@ class Galaxy(commands.Cog):
|
||||||
self.bot = bot
|
self.bot = bot
|
||||||
|
|
||||||
@commands.command()
|
@commands.command()
|
||||||
|
@commands.guild_only()
|
||||||
async def roleinfo(self, ctx, role: discord.Role):
|
async def roleinfo(self, ctx, role: discord.Role):
|
||||||
"""Gives information on a specific role."""
|
"""Gives information on a specific role."""
|
||||||
permissions = role.permissions
|
permissions = role.permissions
|
||||||
color = re.sub('#',"",str(role.color))
|
color = re.sub('#',"",str(role.color))
|
||||||
colorcodelink = f"https://www.color-hex.com/color/{color}"
|
colorcodelink = f"https://www.color-hex.com/color/{color}"
|
||||||
colorint = int(color)
|
colorint = role.color.value
|
||||||
if permissions.administrator:
|
if permissions.administrator:
|
||||||
embed = discord.Embed(color={colorint}, description="With Administrator")
|
embed = discord.Embed(color={colorint}, description="With Administrator")
|
||||||
else:
|
else:
|
||||||
|
|
Loading…
Reference in a new issue