view archetypes
This commit is contained in:
parent
85cbc0ef8a
commit
793c67da11
|
@ -280,8 +280,10 @@ class ViewArchetypesCommand(Command):
|
||||||
template = "m;teamarchetypes [team name]"
|
template = "m;teamarchetypes [team name]"
|
||||||
description = "Lists the current archetypes on the given team."
|
description = "Lists the current archetypes on the given team."
|
||||||
|
|
||||||
async def execute(self, msg, command, flags):
|
@client.tree.command()
|
||||||
team = get_team_fuzzy_search(command.strip())
|
@app_commands.rename(team_name="team")
|
||||||
|
async def teamarchetypes(interaction, team_name):
|
||||||
|
team = get_team_fuzzy_search(team_name)
|
||||||
if team is None:
|
if team is None:
|
||||||
raise CommandError("We can't find that team, boss.")
|
raise CommandError("We can't find that team, boss.")
|
||||||
elif team.archetypes == {}:
|
elif team.archetypes == {}:
|
||||||
|
@ -292,7 +294,7 @@ class ViewArchetypesCommand(Command):
|
||||||
embed_string += f"**{player_name}**:\n{archetype.display_name}\n\n"
|
embed_string += f"**{player_name}**:\n{archetype.display_name}\n\n"
|
||||||
embed = discord.Embed(color=discord.Color.dark_green(), title=f"{team.name} Archetypes")
|
embed = discord.Embed(color=discord.Color.dark_green(), title=f"{team.name} Archetypes")
|
||||||
embed.add_field(name="-",value=embed_string)
|
embed.add_field(name="-",value=embed_string)
|
||||||
await msg.channel.send(embed=embed)
|
await interaction.reaction.send_message(embed=embed)
|
||||||
|
|
||||||
class ImportCommand(Command):
|
class ImportCommand(Command):
|
||||||
name = "import"
|
name = "import"
|
||||||
|
@ -1602,8 +1604,8 @@ commands = [
|
||||||
ShowPlayerCommand(), #done
|
ShowPlayerCommand(), #done
|
||||||
SaveTeamCommand(), #done
|
SaveTeamCommand(), #done
|
||||||
AssignArchetypeCommand(), #done
|
AssignArchetypeCommand(), #done
|
||||||
ViewArchetypesCommand(),
|
ViewArchetypesCommand(), #done
|
||||||
ArchetypeHelpCommand(),
|
ArchetypeHelpCommand(), #done
|
||||||
ImportCommand(),
|
ImportCommand(),
|
||||||
SwapPlayerCommand(),
|
SwapPlayerCommand(),
|
||||||
MovePlayerCommand(),
|
MovePlayerCommand(),
|
||||||
|
|
Loading…
Reference in a new issue