From ced9b6a44f7e5489e518ea029f630537fa5523e1 Mon Sep 17 00:00:00 2001 From: Bryson Steck Date: Fri, 11 Mar 2022 23:28:10 -0700 Subject: added about command, fixed help command output --- twitch-bot/bot.js | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) (limited to 'twitch-bot/bot.js') diff --git a/twitch-bot/bot.js b/twitch-bot/bot.js index 9c874a0..412b0bb 100644 --- a/twitch-bot/bot.js +++ b/twitch-bot/bot.js @@ -53,16 +53,15 @@ function commands (target, commandName, user, mods) { if (mods.indexOf(user) >= 0) isMod = true; if (commandName === "help") { - var allCommands = []; - var finalString = ""; + var finalString = settings.command_char + "help " + settings.command_char + "about "; chat_commands.forEach(command => { - allCommands.push(command.command); - }); - allCommands.forEach(command => { finalString = finalString + settings.command_char + command.command + " "; }); client.say(target, `Here is the list of commands: ${finalString}`); valid = true; + } else if (commandName === "about") { + client.say(target, `This bot was stolen from https://github.com/brysonsteck/lset under the MIT License and configured by your streamer, ${settings.your_username}!`); + valid = true; } else { chat_commands.forEach(command => { if (commandName.search(command.command) !== -1) { -- cgit v1.2.3