Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- ;Trivia Script by Charmander
- ;The file with the questions is located here: http://www.mediafire.com/?ml77dx46ar39jqw
- ;Save the file in your script directory. To find where it is, type //echo -a $scriptdir
- ;Do not rename the file or the script will not work properly.
- ;Commands:
- ;!trivia [start the game]
- ;!halt [end the game]
- ;!score [check your score]
- ;Enjoy!
- on *:text:!trivia:#makeupmakeupmakeup: {
- if (%trivia != on) {
- set %trivia on
- set %thing $read(FAIL.txt)
- set %question $gettok(%thing,1,126)
- set %answer $gettok(%thing,2,126)
- inc %number
- msg # Queston %number $+ : %question
- .timer1 1 10 fail
- }
- else {
- kick # $nick Trivia is already on!
- }
- }
- alias fail {
- if (%trivia == on) {
- unset %answer
- unset %question
- unset %thing
- msg #makeupmakeupmakeup You failed to answer the question in time! The answer was %answer $+ .Next question in 5 seconds!
- timer 1 5 question
- }
- }
- alias question {
- if (%trivia == on) {
- set %thing $read(FAIL.txt)
- set %question $gettok(%thing,1,126)
- set %answer $gettok(%thing,2,126)
- inc %number
- msg #makeupmakeupmakeup Queston %number $+ : %question
- .timer1 1 15 fail
- }
- }
- on *:text:*:#makeupmakeupmakeup: {
- if ($1- == %answer) {
- .timer1 off
- inc %score [ $+ [ $nick ] ]
- msg # $nick said the correct answer! The answer was %answer $+ . Next question in 5 seconds.
- unset %answer
- unset %thing
- unset %question
- timer 1 5 question
- }
- elseif ($1 == !halt) {
- if (%trivia == on) {
- .timer1 off
- unset %trivia
- unset %answer
- unset %thing
- unset %question
- unset %number
- msg # Trivia was stopped by $nick $+ !
- }
- else {
- kick # $nick Trivia is already off!
- }
- }
- elseif ($1 == !score) {
- notice $nick You have %score [ $+ [ $nick ] ] points!
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment