diff --git a/README.md b/README.md index 26e9078..1a09192 100644 --- a/README.md +++ b/README.md @@ -7,9 +7,10 @@ cold hard bot for cold hard chats - $flood [AMOUNT] [TEXT] - Floods the channel with a specific line x amount of times - $ctcpflood [TARGET] [TEXT (one word)] [AMOUNT] - Sends x amount of CTCP requests to a target. - $sneed - Pastes the Sneed's Feed and Seed copypasta. -- $rspam [LINES] - Spams x lines of random characters. -- $uspam [LINES] - Spams x lines of random unicode characters of varying length. +- $rspam [LINES, max=100000)] - Spams x lines of random characters. +- $uspam [LINES, max=100000)] - Spams x lines of random unicode characters of varying length. - $art [IMAGE URL (png/jpg)] - Creates IRC art using a source image. +- $godwords [AMOUNT (def=50, max=100000))] - Generate x amount of random words. Inspired by TempleOS. ## Deployment diff --git a/bot.js b/bot.js index 4759573..040bf86 100644 --- a/bot.js +++ b/bot.js @@ -44,9 +44,10 @@ async function help(chan) { bot.say(chan, "$flood [AMOUNT] [TEXT] - Floods the channel with a specific line x amount of times") bot.say(chan, "$ctcpflood [TARGET] [TEXT (one word)] [AMOUNT] - Sends x amount of CTCP requests to a target.") bot.say(chan, "$sneed - Pastes the Sneed's Feed and Seed copypasta.") - bot.say(chan, "$rspam [LINES] - Spams x lines of random characters") - bot.say(chan, "$uspam [LINES] - Spams x lines of random unicode characters of varying length") + bot.say(chan, "$rspam [LINES (def=50, max=100000)] - Spams x lines of random characters") + bot.say(chan, "$uspam [LINES (def=50, max=100000))] - Spams x lines of random unicode characters of varying length") bot.say(chan, "$art [IMAGE URL (png/jpg)] - Creates IRC art using a source image.") + bot.say(chan, "$godwords [AMOUNT (def=50, max=100000))] - Generate x amount of random words. Inspired by TempleOS.") } async function flood(chan, arg) { @@ -86,6 +87,9 @@ async function uspam(chan, amt) { if (amt > 100000) { bot.say(chan, "no") } else { + if (amt === undefined) { + var amt = 100 + } for(var i=0; i < amt; i++){ var string = "" + randomext.integer(9,0) + "," + randomext.integer(9,0) + randomext.uString(120,60); await timer(2); @@ -98,6 +102,9 @@ async function rspam(chan, amt) { if (amt > 100000) { bot.say(chan, "no") } else { + if (amt === undefined) { + var amt = 100 + } for(var i=0; i < amt; i++){ var string = generateRandomString(70); await timer(2);