[Docs] Remove some redundant notes & small updates (#2847)
* remove outdated notes * Update general.md * Update creating-slash-commands.md * Update add note about interaction framework * typo * use xref * Update intro.md * improve docs workflow * Update README.md
This commit is contained in:
@@ -43,17 +43,17 @@ Ideally, use pattern matching to make sure its the type of interaction you are e
|
||||
|
||||
## My interaction commands are not showing up?
|
||||
|
||||
If you registered your commands globally, it can take up to 1 hour for them to register.
|
||||
Did you register a guild command (should be instant), or waited more than an hour and still don't have them show up?
|
||||
|
||||
- Try to check for any errors in the console, there is a good chance something might have been thrown.
|
||||
- - Make sure you have setup logging. If you use `InteractionService` hook into [`InteractionService.Log`]) event
|
||||
|
||||
- Register your commands after the Ready event in the client. The client is not configured to register commands before this moment.
|
||||
|
||||
- Check if no bad form exception is thrown; If so, refer to the above question.
|
||||
- Check if no bad form exception is thrown;
|
||||
|
||||
- Do you have the application commands scope checked when adding your bot to guilds?
|
||||
|
||||
- Try reloading your Discord client. On desktop it's done with `Ctrl+R` key combo.
|
||||
|
||||
## Do I need to create commands on startup?
|
||||
|
||||
If you are registering your commands for the first time, it is required to create them once.
|
||||
@@ -65,3 +65,6 @@ Overwriting is only required if you make changes to existing commands, or add ne
|
||||
Message and user commands have a limit of 5 per guild, and another 5 globally.
|
||||
If you have more than 5 guild-only message commands being registered, no more than 5 will actually show up.
|
||||
You can get up to 10 entries to show if you register 5 per guild, and another 5 globally.
|
||||
|
||||
|
||||
[`InteractionService.Log`]: xref:Discord.Interactions.InteractionService.Log
|
||||
|
||||
@@ -8,7 +8,11 @@ title: Introduction to slash commands
|
||||
|
||||
This guide will show you how to use application commands.
|
||||
If you have extra questions that aren't covered here you can come to our
|
||||
[Discord](https://discord.com/invite/dvSfUTet3K) server and ask around there.
|
||||
[Discord](https://discord.gg/dnet) server and ask around there.
|
||||
|
||||
> [!NOTE]
|
||||
> This guide shows the manual way of creating and handling application commands. We recommend using the Interaction Framework because it allows you to work with application commands
|
||||
> and handle interactions in a much simpler and structurized way. You can find more info in the [Interaction Framework Intro] docs.
|
||||
|
||||
## What is an application command?
|
||||
|
||||
@@ -46,3 +50,5 @@ From there you can then use the link to add your bot to a server.
|
||||
> [!NOTE]
|
||||
> In order for users in your guild to use your slash commands, they need to have
|
||||
> the "Use Application Commands" permission on the guild.
|
||||
|
||||
[Interaction Framework Intro]: xref:Guides.IntFw.Intro
|
||||
|
||||
@@ -17,8 +17,6 @@ Guild commands are specific to the guild you specify when making them. Guild com
|
||||
|
||||
**Note**: Apps can have a maximum of 100 global commands, and an additional 100 guild-specific commands per guild.
|
||||
|
||||
**Note**: Global commands will take up to 1 hour to create, delete or modify on guilds. If you need to update a command quickly for testing you can create it as a guild command.
|
||||
|
||||
If you don't have the code for a bot ready yet please follow [this guide](https://discordnet.dev/guides/getting_started/first-bot.html).
|
||||
|
||||
## SlashCommandBuilder
|
||||
|
||||
@@ -352,11 +352,6 @@ can be used to register cherry picked modules or commands to global/guild scopes
|
||||
> [!NOTE]
|
||||
> [DontAutoRegisterAttribute] can be used on module classes to prevent `RegisterCommandsGloballyAsync()` and `RegisterCommandsToGuildAsync()` from registering them to the Discord.
|
||||
|
||||
> [!NOTE]
|
||||
> In debug environment, since Global commands can take up to 1 hour to register/update,
|
||||
> it is advised to register your commands to a test guild for your changes to take effect immediately.
|
||||
> You can use preprocessor directives to create a simple logic for registering commands as seen above.
|
||||
|
||||
## Interaction Utility
|
||||
|
||||
Interaction Service ships with a static `InteractionUtility`
|
||||
|
||||
Reference in New Issue
Block a user