on *:TEXT:!setgame*:#:{ if (%game == on) { /notice $nick There is a game already. Please wait | halt }
else { if ($nick == iZezirna) {
/msg $chan $nick has just started a new game! type !hint1 for hint 1 , !hint2 for hint 2 , !hint3 for hint 3 . You have 5 guesses till the game ends.
set %game on
set %answer $2
set %hint1 $3
set %hint2 $4
set %hint3 $5
}
}
}
on *:TEXT:!hint1:#:{ /msg $chan Hint number one is : %hint1 }
on *:TEXT:!hint2:#:{ /msg $chan Hint number two is : %hint2 }
on *:TEXT:!hint3:#:{ /msg $chan Hint number three is : %hint3 }
on *:TEXT:!endgame:#:{ if ($nick == iZezirna) {
msg $chan $nick has just ended the game ! The answer was %answer $+ .
unset %game on
unset %answer
unset %hint1
unset %hint2
unset %hint3
}
}
on *:TEXT:!guess*:#:{
if (!$2) { halt }
inc %guess (%guess [ $+ [ $address($nick,2) ] ]
if ($2 != %answer) {
msg $chan Wrong! You have just gotten one wrong! %guess [ $+ [ $address($nick,2) ] ] / 5
halt
}
if ($2 == %answer) { msg $chan Congrats! $nick has just guessed the item! The answer was %answer $+ . }
if (%guess == 5) { msg $chan You have failed! The answer was %answer %+ . }
unset %guess*
unset %game
unset %answer
unset %hint1
unset %hint2
unset %hint3
}