Files
SupportBot/Addons/hello.js
T

45 lines
1.1 KiB
JavaScript
Raw Permalink Normal View History

2021-10-21 19:28:23 +01:00
// SupportBot | Emerald Services
// Example (default) Addon
const fs = require("fs");
const Discord = require("discord.js");
2021-10-24 22:41:46 +01:00
const yaml = require("js-yaml");
2021-10-27 19:30:10 -05:00
const supportbot = yaml.load(
fs.readFileSync("./Configs/supportbot.yml", "utf8")
);
const cmdconfig = yaml.load(fs.readFileSync("./Configs/commands.yml", "utf8"));
2021-10-21 19:28:23 +01:00
2021-11-24 00:15:16 -06:00
// Your Addon Config file! Saved in /Addons/Configs/YourAddonConfig.yml
2021-12-18 18:57:45 -06:00
// const config = yaml.load(fs.readFileSync('./Addons/Configs/YourAddonConfig.yml', 'utf8'));
2021-10-21 19:28:23 +01:00
2021-12-18 18:57:45 -06:00
const { Command, Event } = require("../Structures/Addon");
2021-10-21 19:28:23 +01:00
2021-12-18 18:57:45 -06:00
module.exports.commands = [
/*
// EXAMPLE COMMAND
new Command({
name: "hello",
description: "hello",
options: [],
permissions: ["SEND_MESSAGES"],
async run(interaction) {
const Embed = new Discord.MessageEmbed()
.setDescription("Hello World!")
.setColor(supportbot.InfoColour);
2021-10-24 22:41:46 +01:00
2021-12-18 18:57:45 -06:00
interaction.reply({
embeds: [Embed],
});
},
}),
*/
];
module.exports.events = [
/*
// EXAMPLE EVENT
new Event("ready", async (client) => {
console.log("Bot started!");
}),
*/
];