From 22342d954f6876462125692acfd7c1cd42b757bc Mon Sep 17 00:00:00 2001 From: Izwzyzx <184772711+Izwzyzx@users.noreply.github.com> Date: Mon, 4 Sep 2023 22:04:07 -0500 Subject: [PATCH] Added 8ball and optional startup message --- Onequestionmark.hx | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/Onequestionmark.hx b/Onequestionmark.hx index 6d7eb48..cb98fe8 100644 --- a/Onequestionmark.hx +++ b/Onequestionmark.hx @@ -78,7 +78,12 @@ class Onequestionmark { public static function onReady() { Sys.sleep(1); Sys.println('[${timestamp()}] Bot is online'); - //Endpoints.sendMessage(settings.devchannel, {content:"onequestionmark-chat alpha test is now running"}, null, false); + + // Join message from program args + if (Sys.args().length > 0) { + Endpoints.sendMessage(settings.devchannel, {content:Sys.args().join(" ")}, null, false); + } + botInfo = Endpoints.getCurrentUser(); MainLoop.add(motd); @@ -166,7 +171,7 @@ class Onequestionmark { "fields": [ { "name": "**Bot commands:**", - "value": "`?help`: Posts this help document. :book:\n`?chk`: Replies with \"ack\". :speaking_head:\n`?slap `: The classic mIRC troutslap. :fish:\n`?hug `: Posts randomized hug image. :people_hugging:\n`?yes`: Posts randomized \"yes\" image or video. :thumbsup:\n`?no`: Posts randomized \"no\" image or video. :no_entry_sign:\n`?mrkrabs`: Similar to `?chk`. :crab:\n`?tufac`: The official Tufac Theme Song. :busts_in_silhouette:\n`?coin `: Flips between 1 and 100 coins. :coin:\n`?dice. `: Rolls -sided die times :game_die:\n`?echobox`: Posts randomized quote from the quote database. :loudspeaker:\n`?echobox `: Adds provided quote to the database. :writing_hand:", + "value": "`?help`: Posts this help document. :book:\n`?chk`: Replies with \"ack\". :speaking_head:\n`?slap `: The classic mIRC troutslap. :fish:\n`?hug `: Posts randomized hug image. :people_hugging:\n`?yes`: Posts randomized \"yes\" image or video. :thumbsup:\n`?no`: Posts randomized \"no\" image or video. :no_entry_sign:\n`?mrkrabs`: Similar to `?chk`. :crab:\n`?tufac`: The official Tufac Theme Song. :busts_in_silhouette:\n`?coin `: Flips between 1 and 100 coins. :coin:\n`?dice. `: Rolls -sided die times :game_die:\n`?8ball`: Answers your yes or no questions. :8ball:\n`?echobox`: Posts randomized quote from the quote database. :loudspeaker:\n`?echobox `: Adds provided quote to the database. :writing_hand:", "inline": false }, { @@ -252,6 +257,9 @@ class Onequestionmark { } } } + case "8ball": + var response:Array = ["It is certain.","It is decidedly so.","Without a doubt.","Yes definitely.","You may rely on it.","As I see it, yes.","Most likely.","Outlook good.","Yes.","Signs point to yes.","Reply hazy, try again.","Ask again later.","Better not tell you now.","Cannot predict now.","Concentrate and ask again.","Don't count on it.","My reply is no.","My sources say no.","Outlook not so good.","Very doubtful."]; + m.reply({content:'🎱 ${response[randInt(0,19)]} 🎱'}, false); // Basic aliases case "angery": m.reply({content:"https://cdn.discordapp.com/attachments/1071547517847732305/1079518504413311108/angery.jpg"}, false);