A trivia script for Hubot.
!trivia # start game
!trivia help # see commands
!hint # show hint
!end # manual game end (debug only)
-
Edit
package.json
and addhubot-trivia
to thedependencies
section. Example:"dependencies": { "hubot-trivia": ">= 0.3.0", ... }
-
Add "hubot-trivia" to your
external-scripts.json
. Example:["hubot-trivia"]
-
Supply a question database and assign it to @dbfile. This version expects the following table structure:
table: questions
fields: category text, title text
table: answers
fields: id integer, answer text
Each row in
questions
has a uniquerowid
. Theanswers
table contains one or more accepted answers to each question, withid
matching the question'srowid
.You can find plaintext question lists here: http://www.wedul.com/trivia.html
Parser at: https://github.com/Xenodite/trivia-parser
Parser designed for question file TriviaQuestions.zip\spicytrivia00.txt at trivia link above.