Skip to content
Branch: master
Find file Copy path
Find file Copy path
Fetching contributors…
Cannot retrieve contributors at this time
62 lines (55 sloc) 1.63 KB
#! ========================================
#! 8-ball
Discord = require 'discord.js'
handler = (msg, match, H) ->
q = match.input.tokenize()[1]
if not q
return msg.reply [
"Ask a question, and I’ll reveal the universe’s
secrets or something."
"I’m an all-knowing being; I will answer any question
using `Math.random()`. Now then, what’s your question?"
].choose() + " (Use `-h 8ball <question>`)"
answer = [
"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."
"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."
embed = new Discord.RichEmbed()
.setColor '#448aff'
.setTitle answer
# .setDescription answer embed
module.exports = {
name: "8-ball"
regex: /^(?:8\-ball|8ball|ask)(\s+|$)/i
handler: handler
short: "-h 8ball <???> ::
Answers any yes or no question."
long: """
=== Help for 8-ball ===
*Aliases*: 8-ball, 8ball, ask
-h 8ball <question> :: Answers any yes or no question with \
47.2% certainty.
You can’t perform that action at this time.