Cykz
Cykz
DIAdiscord.js - Imagine an app
Created by Cykz on 7/18/2024 in #djs-questions
best way to secure my bot's token
Hello! I want to add features that requires higher (dangerous) permission to my bot, but I'm afraid his token might be stolen by some weird guys. I wanted to know if there is ways to store the token securely ?
18 replies
DIAdiscord.js - Imagine an app
Created by Cykz on 10/27/2023 in #djs-questions
client undefined
I got this code to emit a custom event in my database manager class :
console.log(this.client); <== works
this.client.emit('squadronPointsUpdate', {
squadronStats: squadronStats,
players: players,
client: this.client
});
console.log(this.client); <== works
this.client.emit('squadronPointsUpdate', {
squadronStats: squadronStats,
players: players,
client: this.client
});
It correctly logs the client in console but in my event class it logs undefined and I don't understand why
module.exports = {
name: 'squadronPointsUpdate',
async execute(squadronStats, players, client) {
console.log("\n\n")
console.log(client) <== not working "undefined"
console.log("\n\n")
console.log("hhhh")
}
module.exports = {
name: 'squadronPointsUpdate',
async execute(squadronStats, players, client) {
console.log("\n\n")
console.log(client) <== not working "undefined"
console.log("\n\n")
console.log("hhhh")
}
10 replies
DIAdiscord.js - Imagine an app
Created by Cykz on 10/18/2023 in #djs-questions
creating custom events
Hello how can I create custom events and call them from another file ?
4 replies
DIAdiscord.js - Imagine an app
Created by Cykz on 10/17/2023 in #djs-questions
Need help handling event
No description
7 replies
DIAdiscord.js - Imagine an app
Created by Cykz on 9/25/2023 in #djs-questions
Simplifying embed usage
Hi, I'm wondering if there is a way to not repeat the full embed builder every time I need an embed ? I already thought about a function in another class but I dont know how it should looks like
13 replies