PtokaX forum

Archive => Archived 5.1 boards => Request for scripts => Topic started by: smeg568 on 25 July, 2006, 21:16:22

Title: Trivia-Ex-068 for lua 5.1 please
Post by: smeg568 on 25 July, 2006, 21:16:22
Hi would it be possible to convert the excellent trivia-ex for lua5.1 please?

I enclose the code below... ?I tried just moving the scripts etc into the new installation, but i keep getting errors, the script seems to be looking for the TRIVIA folder & the files within. They are exactly as they should be/were (under the 340 Ptokax - which worked a treat) but the script seems to not see them now........ ?it also seems to be looking for dll files? I never knew there were any for the trivbot????

Please help! ? ? ? ? ? ? ? ? ? ? ? ? ? errors below
-----------------------------------------------------------------------------------------------------------------------------------------------------------
Syntax ...IS BORN\PTOKAX\351-511\scripts\Trivia-Ex-V.0.68D.lua:206: module 'TRIVIA/TriviaExScores.txt' not found:
   no field package.preload['TRIVIA/TriviaExScores.txt']
   no file '.\TRIVIA/TriviaExScores\txt.lua'
   no file 'F:\A NEW HUB IS BORN\PTOKAX\351-511\scripts\TRIVIA/TriviaExScores\txt.lua'
   no file 'F:\A NEW HUB IS BORN\PTOKAX\351-511\scripts\TRIVIA/TriviaExScores\txt\init.lua'
   no file 'F:\A NEW HUB IS BORN\PTOKAX\351-511\TRIVIA/TriviaExScores\txt.lua'
   no file 'F:\A NEW HUB IS BORN\PTOKAX\351-511\TRIVIA/TriviaExScores\txt\init.lua'
   no file '.\TRIVIA/TriviaExScores\txt.dll'
   no file 'F:\A NEW HUB IS BORN\PTOKAX\351-511\TRIVIA/TriviaExScores\txt.dll'
   no file 'F:\A NEW HUB IS BORN\PTOKAX\351-511\loadall.dll'
   no file '.\TRIVIA/TriviaExScores.dll'
   no file 'F:\A NEW HUB IS BORN\PTOKAX\351-511\TRIVIA/TriviaExScores.dll'
   no file 'F:\A NEW HUB IS BORN\PTOKAX\351-511\loadall.dll'

------------------------------------------------------------------------------------------------------------------------------------------------------------


The damn script is too long.....

Here's a link for it :)          http://freespace.virgin.net/smeg568.vsh/Trivia-Ex-V.0.68D.rar

Thanks in advance

Feel free to berate me if it's something i have forgotten
Title: Re: Trivia-Ex-068 for lua 5.1 please
Post by: johny on 28 July, 2006, 22:14:09
hi ya all
i got the same probs here, even after i transfered the main file to lua 5.1
perhaps Jitten can help us out of this problem
Title: Re: Trivia-Ex-068 for lua 5.1 please
Post by: [HE]Newbie on 28 July, 2006, 23:33:19
Actually i got the same prob as johnyy, :(, lets hope somebody will help us;)
when this script is done finnaly my lua51 hub can be launched
Title: Re: Trivia-Ex-068 for lua 5.1 please
Post by: -RICK- on 29 July, 2006, 03:57:39
replace in lua script require to dofile (3 times i believe) then the loading part is solved
Title: Re: Trivia-Ex-068 for lua 5.1 please
Post by: jiten on 29 July, 2006, 12:38:02
As requested, the script is now compatible with LUA 5.1

Haven't really tested the code, but, feel free to post your progress.
Title: Re: Trivia-Ex-068 for lua 5.1 please
Post by: 6Marilyn6Manson6 on 29 July, 2006, 12:59:36
First to download :D
Title: Re: Trivia-Ex-068 for lua 5.1 please
Post by: johny on 29 July, 2006, 14:44:37
hehehe ok ok but one of the 4 downloads so far is mine.
just tested it and it works fine here so far.

thanks for your help so far jitten.
Title: Re: Trivia-Ex-068 for lua 5.1 please
Post by: [HE]Newbie on 29 July, 2006, 14:51:56
Well done Jiten, Yesterday i was fighting for that script with rick and mutor :P but we finaly came out aswell just as rick sayed, replace require 4 times for dofile
Title: Re: Trivia-Ex-068 for lua 5.1 please
Post by: smeg568 on 07 August, 2006, 18:37:08
 ;D
nice one Jiten

Thanks
Title: Re: Trivia-Ex-068 for lua 5.1 please
Post by: jiten on 07 August, 2006, 19:25:03
Don't mention it, guys. You're welcome.
Title: Re: Trivia-Ex-068 for lua 5.1 please
Post by: JueLz on 07 August, 2006, 22:32:34
How do i change the time in wich the questions are displayed
and the time in wich the Hints are Displayed?
Posted on: 07 August 2006, 23:08:37
Found it :)
Title: Re: Trivia-Ex-068 for lua 5.1 please
Post by: Aragorn on 22 August, 2006, 13:48:42
jiten I have something for you ;D

http://www.ngline.ru/fun/1000000.swf
Title: Re: Trivia-Ex-068 for lua 5.1 please
Post by: jiten on 22 August, 2006, 14:40:24
Quote from: Aragorn on 22 August, 2006, 13:48:42
jiten I have something for you ;D

http://www.ngline.ru/fun/1000000.swf

You're welcome, Aragorn.

By the way, is it possible to reach the '1 million'? :P
Title: Re: Trivia-Ex-068 for lua 5.1 please
Post by: Aragorn on 22 August, 2006, 21:12:33
if you have enough time :P ;D
Title: Re: Trivia-Ex-068 for lua 5.1 please
Post by: bastya_elvtars on 22 August, 2006, 21:17:21
Quote from: Aragorn on 22 August, 2006, 21:12:33
if you have enoug time :P ;D

Had to stop it after 3000. :-)
Title: Re: Trivia-Ex-068 for lua 5.1 please
Post by: Aragorn on 22 August, 2006, 21:23:29
Quote from: bastya_elvtars on 22 August, 2006, 21:17:21
Had to stop it after 3000. :-)

it's a long way to that million.....I also stopped it...couldn't rezist anymore :o
Title: Re: Trivia-Ex-068 for lua 5.1 please
Post by: Offski?????? on 30 August, 2006, 17:27:27
Re: Trivia-Ex-0681 for lua 5.1, works brill , please any chance of right click cmd's for non-typer's 
for:- start
       stop
       my score
       top 10
       top 100
much thx in advance (do i clik the aplaud thing b4 or after) ;).
Title: Re: Trivia-Ex-068 for lua 5.1 please
Post by: dodgeviper on 12 November, 2006, 08:24:35
i am facing a problem..wheneever i add questions to the addquesfile.txt.....the questions are not shown on the main screen by the bot
Title: Re: Trivia-Ex-068 for lua 5.1 please
Post by: Alexinno on 12 November, 2006, 13:07:05
Offski??????: maybe you can use mine, btw ... i'm not a scripter this is just something i've done for my own use


--Trivia RC commands by alexinno
--??????????????????????????????????????????????????????????
--Bot = frmHub:GetHubBotName()
tbot = "???Trivia"
--??????????????????????????????????????????????????????????

function Main()
    frmHub:RegBot("???Trivia")
end
function NewUserConnected(curUser)
--customCMDs = function(user) --// You can put your custome commands here]
        curUser:SendData("$UserCommand 0 3")
curUser:SendData("$UserCommand 1 3 Trivia\\Help$$To: "..tbot.." From: %[mynick] $<%[mynick]> -thelp|")
curUser:SendData("$UserCommand 1 3 Trivia\\Join$$To: "..tbot.." From: %[mynick] $<%[mynick]> -tjoin|")
        curUser:SendData("$UserCommand 1 3 Trivia\\Part$$To: "..tbot.." From: %[mynick] $<%[mynick]> -tpart|")
        curUser:SendData("$UserCommand 1 3 Trivia\\Curent Word$$To: "..tbot.." From: %[mynick] $<%[mynick]> -tword|")
        curUser:SendData("$UserCommand 1 3 Trivia\\Curent Question$$To: "..tbot.." From: %[mynick] $<%[mynick]> -tquestion|")
        curUser:SendData("$UserCommand 1 3 Trivia\\My Points$$To: "..tbot.." From: %[mynick] $<%[mynick]> -tpoints|")
        curUser:SendData("$UserCommand 1 3 Trivia\\Scores$$To: "..tbot.." From: %[mynick] $<%[mynick]> -tscores|")
        curUser:SendData("$UserCommand 1 3 Trivia\\Players$$To: "..tbot.." From: %[mynick] $<%[mynick]> -tplayers|")
        curUser:SendData("$UserCommand 1 3 Trivia\\Hint$$To: "..tbot.." From: %[mynick] $<%[mynick]> -hint|")
        curUser:SendData("$UserCommand 1 3 Trivia\\TopTen$$To: "..tbot.." From: %[mynick] $<%[mynick]> -ttopten|")
        curUser:SendData("$UserCommand 1 3 Trivia\\Start$$To: "..tbot.." From: %[mynick] $<%[mynick]> -tstart|")
end

OpConnected = function(curUser)
        curUser:SendData("$UserCommand 0 3")
        curUser:SendData("$UserCommand 1 3 Trivia\\Help$$To: "..tbot.." From: %[mynick] $<%[mynick]> -thelp|")
curUser:SendData("$UserCommand 1 3 Trivia\\Join$$To: "..tbot.." From: %[mynick] $<%[mynick]> -tjoin|")
        curUser:SendData("$UserCommand 1 3 Trivia\\Part$$To: "..tbot.." From: %[mynick] $<%[mynick]> -tpart|")
        curUser:SendData("$UserCommand 1 3 Trivia\\Curent Word$$To: "..tbot.." From: %[mynick] $<%[mynick]> -tword|")
        curUser:SendData("$UserCommand 1 3 Trivia\\Curent Question$$To: "..tbot.." From: %[mynick] $<%[mynick]> -tquestion|")
        curUser:SendData("$UserCommand 1 3 Trivia\\My Points$$To: "..tbot.." From: %[mynick] $<%[mynick]> -tpoints|")
        curUser:SendData("$UserCommand 1 3 Trivia\\Scores$$To: "..tbot.." From: %[mynick] $<%[mynick]> -tscores|")
        curUser:SendData("$UserCommand 1 3 Trivia\\Players$$To: "..tbot.." From: %[mynick] $<%[mynick]> -tplayers|")
        curUser:SendData("$UserCommand 1 3 Trivia\\Hint$$To: "..tbot.." From: %[mynick] $<%[mynick]> -hint|")
        curUser:SendData("$UserCommand 1 3 Trivia\\Topten$$To: "..tbot.." From: %[mynick] $<%[mynick]> -ttopten|")
        curUser:SendData("$UserCommand 1 3 Trivia\\Start$$To: "..tbot.." From: %[mynick] $<%[mynick]> -tstart|")
        curUser:SendData("$UserCommand 1 3 Trivia\\Stop$$To: "..tbot.." From: %[mynick] $<%[mynick]> -tstop|")

end