of fucking course its oop again
This commit is contained in:
parent
6359da85ea
commit
6ea0e02ee8
4 changed files with 134 additions and 52 deletions
26
src/commands/ping.ts
Normal file
26
src/commands/ping.ts
Normal file
|
|
@ -0,0 +1,26 @@
|
|||
import {Command} from "../command.ts";
|
||||
import {
|
||||
ApplicationIntegrationType,
|
||||
ChatInputCommandInteraction,
|
||||
InteractionContextType,
|
||||
SlashCommandBuilder
|
||||
} from "discord.js";
|
||||
|
||||
export default class PingCommand extends Command {
|
||||
async run(interaction: ChatInputCommandInteraction, config) {
|
||||
await interaction.reply({
|
||||
content: 'Pong!',
|
||||
});
|
||||
}
|
||||
|
||||
slashCommand = new SlashCommandBuilder()
|
||||
.setName("ping")
|
||||
.setDescription("Pong!").setIntegrationTypes([
|
||||
ApplicationIntegrationType.UserInstall
|
||||
])
|
||||
.setContexts([
|
||||
InteractionContextType.BotDM,
|
||||
InteractionContextType.Guild,
|
||||
InteractionContextType.PrivateChannel
|
||||
]);
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue