make shorter botlist command

This commit is contained in:
Santiago Forero 2021-09-16 15:37:57 -05:00
parent e1d2d00791
commit 0916912adf
1 changed files with 4 additions and 25 deletions

View File

@ -10,7 +10,7 @@ bot.connect({
tls: true
});
const prefix = "-"
const prefix = "="
bot.commands = new Map();
@ -26,7 +26,7 @@ bot.on('message', event => {
const args = event.message.slice(prefix.length).trim().split(/ +/);
if(event.message == '!botlist') {
bot.commands.get('help').execute(event, args, bot);
bot.say(event.target, `Hello, I'm Cactus, my maintainer is forero and my prefix is '${prefix}'. For more information type: ${prefix}help, join #cactus for help`);
}
if (!event.message.startsWith(prefix)) return;
@ -44,30 +44,9 @@ bot.on('message', event => {
}
})
bot.on('registered', event => {
console.log(event)
bot.join('#bots')
bot.join('#cactus')
bot.say('NickServ', 'identify 1021513305')
})
bot.join('#cactus-spam')
})