mirror of
https://github.com/JonnyBro/JaBa.git
synced 2024-11-22 13:14:58 +05:00
Краб
This commit is contained in:
parent
042b32d942
commit
a5342ba7c9
2 changed files with 48 additions and 0 deletions
43
commands/Fun/crab.js
Normal file
43
commands/Fun/crab.js
Normal file
|
@ -0,0 +1,43 @@
|
||||||
|
const { SlashCommandBuilder } = require("discord.js");
|
||||||
|
const BaseCommand = require("../../base/BaseCommand"),
|
||||||
|
fetch = require("node-fetch");
|
||||||
|
|
||||||
|
class Crab extends BaseCommand {
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
* @param {import("../base/JaBa")} client
|
||||||
|
*/
|
||||||
|
constructor(client) {
|
||||||
|
super({
|
||||||
|
command: new SlashCommandBuilder()
|
||||||
|
.setName("crab")
|
||||||
|
.setDescription(client.translate("fun/crab:DESCRIPTION")),
|
||||||
|
aliases: [],
|
||||||
|
dirname: __dirname,
|
||||||
|
guildOnly: true,
|
||||||
|
ownerOnly: false
|
||||||
|
});
|
||||||
|
}
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
* @param {import("../../base/JaBa")} client
|
||||||
|
*/
|
||||||
|
async onLoad() {
|
||||||
|
//...
|
||||||
|
}
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
* @param {import("../../base/JaBa")} client
|
||||||
|
* @param {import("discord.js").ChatInputCommandInteraction} interaction
|
||||||
|
* @param {Object} data
|
||||||
|
*/
|
||||||
|
async execute(client, interaction) {
|
||||||
|
const res = await fetch("https://and-here-is-my-code.glitch.me/img/crab").then(response => response.json());
|
||||||
|
|
||||||
|
interaction.reply({
|
||||||
|
content: res.Link
|
||||||
|
});
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
module.exports = Crab;
|
5
languages/ru-RU/fun/crab.json
Normal file
5
languages/ru-RU/fun/crab.json
Normal file
|
@ -0,0 +1,5 @@
|
||||||
|
{
|
||||||
|
"DESCRIPTION": "Получить изображение краба... да, это всё, что вы ещё хотели от команды под названием crab?",
|
||||||
|
"USAGE": "crab",
|
||||||
|
"EXAMPLES": "crab"
|
||||||
|
}
|
Loading…
Reference in a new issue