|
semicharmless
|
semicharmless
|
I'm hoping someone can assist me with modifying the hint system of a Trivia bot. I think this section in script.mrc controls the process; if ($1 == $getread(-s,triggers,hint) && $getread(-s,gsettings,hint) == on) {
floodproc HINT 3
if (%trivq != $null) { .msg $getread(-s,csettings,trivia.channel) %h2col Hint: $+ %hcol $+ $left($arg(%trivq,2,*),1) | halt } | msg $getread(-s,csettings,trivia.channel) %h3col $+ What ? You want a hint for future questions ? }
if ($1 == $getread(-s,triggers,hint2) && $getread(-s,gsettings,hint) == on) {
floodproc HINT2 3
if (%hint == false) {
if (%trivq != $null && $chr(160) isin $arg(%trivq,2,*) && $getread(-s,triggers,hint2result) == firstword) { var %whint = $arg($arg(%trivq,2,*),1,$chr(160)) | msg $getread(-s,csettings,trivia.channel) 0,10 Hint: %whint $+ $chr(32) $+ $right(%hint4,$calc(0- $len(%whint))) | set %hint true | halt }
if (%trivq != $null) { msg $getread(-s,csettings,trivia.channel) 0,10 Hint: %hint3 $+ $right(%hint4,$calc(0-$getread(-s,triggers,hint2resultcount))) | set %hint true | halt } | msg $getread(-s,csettings,trivia.channel) 14What ? You want a hint for future questions ? }
}
if ($1 == $getread(-s,triggers,skip)) && ($arg(%trivq,2,*) != $null) {
floodproc SKIP 5
if ($getread(-s,gsettings,skip) != on) { .notice $nick Sorry, this command seems to lag the bot. | halt } | else { .timer3 off | .timer4 off | .timer5 off | .timer6 off | var %skans = $arg(%trivq,2,*) | unset %trivq | msg $getread(-s,csettings,trivia.channel) 0,1 Player triggered !skip command $+ %clqb The answer was -> %clqa %skans %clqb <- 0,1 Skipping to next question | .timerskipped 1 %tme2 trivq | if %chaos = on { unset %allans | set %chaos off } | halt } }
if ($1 == $getread(-s,triggers,repeat) && $getread(-s,gsettings,repeat) == on) {
but having backed up the file and edited various pieces, I'm not seeing any changes in the hint system when testing. At present, the 1st hint pops up immediately after a question is asked e.g. Q: What colour is a blue crayon? 1st Hint: **** which on occasions gives the answer away immediately e.g. when the answer is yes or no, or true or false, as two examples. The 2nd hint always shows the first two characters of the answer. Which isn't helpful when the answer is a year and you've no idea of even the decade the answer relates to, leaving 99 possible answers. Two hints down and not very hintful. The 3rd hint shows more characters of an answer, but with the really long answers, it still isn't very helpful. Is it possible to customise the 1st hint to appear after a specified period of time and show a random percentage of the characters from the answer e.g. 30%. Customise the 2nd hint to appear after a specified period of time and show a random percentage of the characters from the answer e.g. 60%. Customise the 3rd hint to appear after a specified period of time and show a random percentage of the characters from the answer e.g. 90%? Hopefully I'm looking in the correct place in the script. If not, I can supply the full script.mrc or one of the various other .mrc files. Any help would be very much appreciated.
|
|
|
|
Joined: Jan 2004
Posts: 1,330
Hoopy frood
|
Hoopy frood
Joined: Jan 2004
Posts: 1,330 |
I've never used Trivia Bot By Tigger so I'm unfamiliar with its capabilities, but customizing an installation of mIRC specifically for a trivia bot seems silly. Have you checked out Tat's Trivia bot? You install a single .mrc file instead of a monstrocity of scripts and inis that override mirc's files. I believe it also has the ability to set the number and percentage of hints and can randomize which characters are revealed. http://tatarize.nfshost.com/
|
|
|
|
Joined: Oct 2004
Posts: 8,061
Hoopy frood
|
Hoopy frood
Joined: Oct 2004
Posts: 8,061 |
We use a heavily modified version of Trivbot2001 and it works really well. Of course, much of that is thanks to the heavy modification and it was modified specifically to work in our channel, so wouldn't be portable to other channels, unfortunately. But the hint system for normal questions is pretty standard... first hint immediately with nothing more than *'s denoting the number of characters per word and any symbols are shown. The second hint after 20 seconds with the first 2-3 characters shown depending on length of the answer. And the third hint 20 seconds later with what was in hint 2 plus all vowels.
On year questions, it is slightly different. The first hint shows the first 2 numbers the second and third hints show the first 3 numbers. We never show all 4 numbers. Also, we have years set to only allow 4 guesses so people can't just spam a bunch of years.
True/False questions allow each person only one answer. They show nothing for the first hint besides a *, then the second and third hints shows T or F for True/False that have either just a T or F response. If the True/False uses the full words of true and false, then it works just like the normal hints, but you still only get 1 chance.
We also have multiple answer questions that do not give any hints. For example, the question may ask for all computers and consoles that Final Fantasy has been released on. People would start throwing out answers until either the time is up or all answers have been typed.
In any case, there are some ideas for hint systems. As to how to do it, you'll be better off placing an ECHO before any section that you believe relates to what you're trying to change. Then see if the echo happens when you expect it to. If not, check another place and keep doing that until you find the right one. Alternately, try changing "Hint" to something like "XXXX" and see if it changes the hint. If not, try the next place where you find "Hint" and repeat until you find the correct one. Note that depending on the script, there may be multiple places that have to be changed.
|
|
|
|
flipper
|
flipper
|
$getread.... hrm nice... at least some of my work is still floating around.
Anyhow, have you found a solution to your problem ? If not I can probably help. I developed TriviaBot for almost 10 years, and it is from which most Trivia scripts have borrowed at least some of their workings. I like your idea on the % of the answer. The last version I made was 6, it was only given to a hand full of people. The code shown in your post was from my version 4. Im thinking about putting my Script back out there, as the TriviaBot2001 was a horrible butchering job on my work.
The newest version I have does alot of what you are looking for, and I just love new ideas. I think I can help you get where you need to be, let me know where to find you on IRC and we'll chat about it.
|
|
|
|
|