lets see if this works!
This commit is contained in:
parent
9469c92a53
commit
8da715190d
1 changed files with 6 additions and 2 deletions
|
@ -12,10 +12,14 @@ class Galaxy(commands.Cog):
|
||||||
@commands.command()
|
@commands.command()
|
||||||
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
|
||||||
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}"
|
||||||
await ctx.send(content=f"{color}")
|
if permissions.administrator:
|
||||||
await ctx.send(content=f"{colorcodelink}")
|
embed = discord.Embed(color={color}, content="With Administrator")
|
||||||
|
else:
|
||||||
|
embed = discord.Embed(color={color}, content="Without Administrator")
|
||||||
|
await ctx.send(embed=embed)
|
||||||
|
|
||||||
|
|
||||||
@commands.command()
|
@commands.command()
|
||||||
|
|
Loading…
Reference in a new issue