TravBot-v3/src/commands/fun/ravi.ts

39 lines
1.1 KiB
TypeScript
Raw Normal View History

import {Command, NamedCommand} from "onion-lasers";
import {Random} from "../../lib";
export default new NamedCommand({
description: "Ravioli ravioli...",
usage: "[number from 1 to 9]",
async run({send}) {
2021-04-10 13:34:55 +00:00
send({
embed: {
title: "Ravioli ravioli...",
image: {
url: `https://raw.githubusercontent.com/keanuplayz/TravBot/master/assets/ravi${Random.int(
1,
10
)}.png`
}
}
});
},
number: new Command({
async run({send, args}) {
const arg: number = args[0];
if (arg >= 1 && arg <= 9) {
2021-04-10 13:34:55 +00:00
send({
embed: {
title: "Ravioli ravioli...",
image: {
url: `https://raw.githubusercontent.com/keanuplayz/TravBot/master/assets/ravi${arg}.png`
}
}
});
} else {
2021-04-10 13:34:55 +00:00
send("Please provide a number between 1 and 9.");
}
}
})
});