π Addon Event
This section explains how to create and use events within your addon. Events allow you to listen to Discord actions (such as messages, interactions, or member joins) and execute custom logic when they*
js
// Event configuration structure
const events = [
{
name: 'eventName', // Discord event name (e.g. "messageCreate", "interactionCreate")
customId: 'uniqueValue', // Unique identifier for your addon ('messageCreate-StarBoard', 'messageReactionAdd-starboard')
once: false, // Set to true if the event should run only once, otherwise false for continuous listening
/**
* Main event execution function
* @param {Object} params - Event-specific parameters (e.g. message, interaction, etc.)
* @param {Client} bot - Discord bot client instance
*/
async execute(params, bot) {
// Your logic goes here
}
}
];