Browse Source

Fix Context warning note and add ReplyAsync xref

pull/825/head
Hsu Still 8 years ago
parent
commit
a8ba5b5be9
1 changed files with 5 additions and 4 deletions
  1. +5
    -4
      docs/guides/commands/commands.md

+ 5
- 4
docs/guides/commands/commands.md View File

@@ -132,13 +132,14 @@ will not need to cast them.
To reply to messages, you may also invoke [ReplyAsync], instead of To reply to messages, you may also invoke [ReplyAsync], instead of
accessing the channel through the [Context] and sending a message. accessing the channel through the [Context] and sending a message.


[Context]: xref:Discord.Commands.ModuleBase`1#Discord_Commands_ModuleBase_1_Context
[SocketCommandContext]: xref:Discord.Commands.SocketCommandContext

>![WARNING]
> [!WARNING]
>Contexts should **NOT** be mixed! You cannot have one module that >Contexts should **NOT** be mixed! You cannot have one module that
>uses CommandContext and another that uses SocketCommandContext. >uses CommandContext and another that uses SocketCommandContext.


[Context]: xref:Discord.Commands.ModuleBase`1#Discord_Commands_ModuleBase_1_Context
[SocketCommandContext]: xref:Discord.Commands.SocketCommandContext
[ReplyAsync]: xref:Discord.Commands.ModuleBase`1#Discord_Commands_ModuleBase_1_ReplyAsync_System_String_System_Boolean_Discord_Embed_Discord_RequestOptions_

### Example Module ### Example Module


At this point, your module should look comparable to this example: At this point, your module should look comparable to this example:


Loading…
Cancel
Save