fsu-fall2022-capstone / Project-Group-5

A discord bot that connects to the online game nationstates
1 stars 0 forks source link

Slash Command Tree syncing #9

Closed CoderJoshDK closed 1 year ago

CoderJoshDK commented 1 year ago

Bot needs a method for syncing (current is flawed)

Discord slash commands are held on a tree. The tree needs to be synced with discord. This can either be done globally or per guild.

A command needs to be implemented. It can be called by mentioning the bot sync. The command can only be called in a guild and only by the owner of the bot.

Works like:

@bot sync-> global sync @bot sync ~ -> sync current guild @bot sync * -> copies all global app commands to the current guild and syncs @bot sync ^ -> clears all commands from the current guild target and syncs (removes guild commands) @bot sync id_1 id_2 -> syncs guilds with id 1 and 2 where bot here is the name of the bot.

Sync when you...

Do not sync when you...

This is the same for hybrid commands