This is just a little socket that will pull a random riddle from randomriddles.com , and then in 10 seconds it will show the solution to it.
I just thought I would share it, cause someone may have a use for it.
Copy/Paste into a new remote of your bot, or into a new remote of your own mIRC client.
Like always do what ever you want to this snippet. I do not care.
Trigger is @riddle
Example:
@riddle <~Sick0> The more you of them you take, the more you leave behind. What are they? [Solution in 10 seconds] <~Sick0> [Solution] 'Footsteps'
alias -l riddle {
if (!%rid) { inc -u11 %rid
if ($sock(riddle)) sockclose riddle
sockopen riddle www.randomriddles.com 80
sockmark riddle msg #
}
}
on *:load: {
echo 12 -a You Have Just Loaded Napa182's Riddle/Solution Socket
echo 04 -a An Irc.EzzyChat.com Production
}
on *:input:#:if ($regex($1,/^@riddle$/iS)) riddle
on $*:text:/^@riddle$/iS:#:riddle
on *:sockopen:riddle: {
sockwrite -n riddle GET / HTTP/1.1
sockwrite -n riddle Host: $+($sock(riddle).addr,$str($crlf,2))
}
on *:sockread:riddle: {
var %riddle | sockread %riddle
if ($regex(%riddle,/<i>(.+?)<a.+alert\50(.+?)\51.+<\/i>/)) {
$sock(riddle).mark :[04Riddle]: $regml(1) :[04Solution in 10 seconds]:
.timerriddle 1 10 $sock(riddle).mark :[04Solution]: $regml(2)
}
}
This socket still works fine on my end. I don't know why it is doing what you are saying it is doing on yours.
<~napa182> @riddle
<&Sick0> :[Riddle]: What travels the world but stays in a corner? :[Solution in 10 seconds]:
<&Sick0> :[Solution]: 'A stamp.'
<~napa182> @riddle
<&Sick0> :[Riddle]: Is it legal to bury a man living in Mexico across the border in the United States? :[Solution in 10 seconds]:
<&Sick0> :[Solution]: 'The last time we checked, it was not legal to bury a living man under any circumstances!'
<~napa182> @riddle
<&Sick0> :[Riddle]: A man has 9 children. Half of them are boys. How is this possible? :[Solution in 10 seconds]:
<&Sick0> :[Solution]: 'They are all boys.'
I reloaded the script and copy pasted it again from here, it's still getting the same riddle, weird.
@Riddle
<&Pyro> :[Riddle]: What is broken as soon as it is spoken? :[Solution in 10 seconds]:
<&Pyro> :[Solution]: 'Silence.'
<&Pyro> :[04Riddle]: What is broken as soon as it is spoken? :[Solution in 10 seconds]:
<&Pyro> :[Solution]: 'Silence.'
Though, it was working fine for me before.