PtokaX forum

Archive => Archived 5.0 boards => Finished Scripts => Topic started by: Jelf on 13 March, 2005, 12:07:25

Title: Trivia-Ex-V.0.68 for Lua 5
Post by: Jelf on 13 March, 2005, 12:07:25
I know a few people wanted this so here ya go...
Trivia-Ex V.0.68 Lua 5 (http://lua.uknnet.com/attachment.php?attachmentid=85&sid=)
Title:
Post by: Tw?sT?d-d?v on 13 March, 2005, 12:21:43
THX M8 :)))   just what i needed
Title:
Post by: Bobby1999 on 13 March, 2005, 13:13:46
My hero :))))
Title:
Post by: lynyrd on 13 March, 2005, 15:44:32
Yyyyesss! =)
Title:
Post by: MusicMan? on 13 March, 2005, 16:32:02
wow much appreciated m8  :D  :D  :D

I look forward to trying it out.

MusicMan?
Title:
Post by: remaster-it on 13 March, 2005, 17:03:15
WD Jelf

Thx M8    :D ..  ur a Star
Title: Awesome thanks
Post by: -=NYC=-Hemarr on 13 March, 2005, 17:05:21
Thankyou so much   will the old trivia questions work with it? also getting error in lua  
Syntax [string "-- Converted to Lua5 By Jelf 12/03/05 With thanks to kepp
..."]:24: `=' expected near `TrivEx' any ideas
 did not edit put in as i got from link
Title:
Post by: Anna on 13 March, 2005, 17:39:10
no idea... I dont get that error and I just putted it in... that seem strange, I did some editing though, mainly settings to get it as I want it :D
Title: Must Have been bad download
Post by: -=NYC=-Hemarr on 13 March, 2005, 17:54:17
Got copy of it from someone else working now must have been bad download Right click commands work with it most commands will fix rest and then i'll post it here
Title: Trivia-Ex-V.0.68 for Lua 5
Post by: kbeh273300 on 13 March, 2005, 18:55:11
hi   thank you very very much for this script :)

everything seems to work great i only have one error and here it is
!trivstats
Syntax ....b16.05.nt.rlsrobo\scripts\Trivia-Ex-V.0.68.lua5.lua:704: attempt to index field `AvTime' (a number value



other then that its working awesome  :D  :D
Title:
Post by: Settlers on 14 March, 2005, 00:12:04
Good JOB!!!!!!
Title:
Post by: Jelf on 14 March, 2005, 14:27:52
I'm glad that so many people are enjoying this :d

QuoteOriginally posted by -=NYC=-Hemarr

Thankyou so much   will the old trivia questions work with it?
[/SIZE]
Yes the old questions will work with it as there arent many that come with it in the zip :D
Quotealso getting error in lua  
Syntax [string "-- Converted to Lua5 By Jelf 12/03/05 With thanks to kepp
..."]:24: `=' expected near `TrivEx' any ideas
 did not edit put in as i got from link
[/SIZE]
Dunno how that happened because that line is No1 not No24
QuoteOriginally posted by kbeh273300

hi thank you very very much for this script :)

everything seems to work great i only have one error and here it is


code:--------------------------------------------------------------------------------!trivstats
Syntax ....b16.05.nt.rlsrobo\scripts\Trivia-Ex-V.0.68.lua5.lua:704: attempt to index field `AvTime' (a number value--------------------------------------------------------------------------------



other then that its working awesome :D :D
[/SIZE]
I haven't been able to get this error, Do you still get it or was it a one off?
Title:
Post by: remaster-it on 14 March, 2005, 20:30:14
as I said before Jelf your a star  .... script working really well  ..  

no probs in the mem usage (145k) or the way running  ..  


get error in ptokax  script editor at base when running  

Syntax ...0 v 5 uk1 test HUB\scripts\Trivia-Ex-V.0.68.lua5.lua:406: attempt to call global `SendDataPlayers' (a nil value)

but dont appear to be effecting the hub or the game  ..  

( comes up about 2 x an hour )  ...  

I have had to convert the question format  (as was the fullques from chilla) using  PSpad to change from  $$ to $ as the seperator    ..  poss picking up a bad Question format every so ofton  ??

have also changed

TrivEx._Profiles.Normal = {
   
Title:
Post by: horis on 14 March, 2005, 21:23:40
Hi jelf
         I have a few probs, The script won't run in random mode and also only in pm, maybe I've done something wrong as no one else seems to get the same probs. Just like to say thanks very much for the conversion even if I am having trouble  :D
       
           horis
Title:
Post by: Jelf on 14 March, 2005, 22:37:59
It was my fault, when i zipped it I included the config file, so when script is started it uses settings from there, I had it set to PM mode while testing.

All you have to do is type !triviamain and !trivstart in mainchat and that should bring it back.

I have re-upped the zip without this file included so it defaults to mainchat.
Title: hi Jeff
Post by: kbeh273300 on 14 March, 2005, 23:36:39
well i got that error when i used my old saved scores but since then i reset the scores and the error is gone now and the stats cmd works as it should.

thanks very much for this script you saved me a hole lot of angry users lol :D  :D
Title: trivia
Post by: Mucking_Fagic on 15 March, 2005, 00:11:56
hiya
im having problems getting the link to work to get the trivia files, im really interested in the script can anyone help me?
Title:
Post by: Jelf on 15 March, 2005, 08:54:15
Link should work now
Title:
Post by: Mucking_Fagic on 15 March, 2005, 17:54:10
excellent thanks for sortuing out the link much appreciated, good job keep up the good work.
Title: Trivia-Ex-V.0.68 for Lua 5
Post by: neper on 16 March, 2005, 15:06:07
does not function that


if (self._Sets.showcorrectanswer == 1) then
SendDataPlayers(curUser.sName.."'s Stats, Score: "..self._Scores[curUser.sName].Score.." Point(s), Answerd Questions: "..self._Scores[curUser.sName].AvTime[2]..", Average Answering Time: "..string.format("%.2f",self._Scores[curUser.sName].AvTime[3]).." sec.")
end
Title:
Post by: Jelf on 16 March, 2005, 15:42:08
Did you use a clean folder ?
Title:
Post by: neper on 16 March, 2005, 15:45:41
yes
Title:
Post by: horis on 16 March, 2005, 18:50:21
Thanks Jelf for both trivia games :)
Title:
Post by: Lage on 29 March, 2005, 14:53:17
Hi. I used to run Trivia Ex v0.65 in my old Ptokax hub, but I'm setting up a new one now with Ptokax 0.3.3.0 build 16.06 so I thought I'd run this script instead.

Now for some reason the trivia tells me the answer is correct before the line where the person actually enters the correct answer is shown. Why is this, and how can it be modified? The way it is now, the trivia bot seems psychic. =)
Title:
Post by: Falstaff on 30 March, 2005, 19:35:02
QuoteOriginally posted by Jelf
I know a few people wanted this so here ya go...
Trivia-Ex V.0.68 Lua 5 (http://lua.uknnet.com/attachment.php?attachmentid=85&sid=)

is there any way of adding the possibility of showing the accumulative score when a user answers the question i.e

correct (user) the answer was (answer) you get 9 points your score so far is 490

this would be a help
Title:
Post by: night_hawk on 11 April, 2005, 08:44:31
hi can you change the Trivia Ex v0.65 to lua 5...users in my hub love that verion better cause the new one droped some featchers that they liked please let me know thank you.....
Title:
Post by: jiten on 11 April, 2005, 11:26:56
QuoteOriginally posted by night_hawk
hi can you change the Trivia Ex v0.65 to lua 5...users in my hub love that verion better cause the new one droped some featchers that they liked please let me know thank you.....

Can u post the script somewhere or host it so that I can convert it?
Title: hi
Post by: night_hawk on 11 April, 2005, 15:31:50
all can can do is send it throw msn, yahoo, icq or aol...if you have one of them leave me your addy i will add you and send it to you that way...it is to large to poast...thank you
Title:
Post by: jiten on 12 April, 2005, 15:46:22
QuoteOriginally posted by night_hawk
all can can do is send it throw msn, yahoo, icq or aol...if you have one of them leave me your addy i will add you and send it to you that way...it is to large to poast...thank you

I got the file from plop's site and I've already converted it to Lua 5.
Grab it here (http://mznetwork.mozdesigners.com/i/forum_files/Trivia-Ex-V.0.65.lua5.lua).
Btw, i didn't test it much so it may have some bugs.

Cheers  ;)

PS: That only the .lua file.  U got to have the .txt files.
Title:
Post by: jiten on 12 April, 2005, 16:03:37
QuoteOriginally posted by Lage
Hi. I used to run Trivia Ex v0.65 in my old Ptokax hub, but I'm setting up a new one now with Ptokax 0.3.3.0 build 16.06 so I thought I'd run this script instead.

Now for some reason the trivia tells me the answer is correct before the line where the person actually enters the correct answer is shown. Why is this, and how can it be modified? The way it is now, the trivia bot seems psychic. =)

Try replacing all the "function TrivEx:ParseData(mode,curUser,data)" with this:
function TrivEx:ParseData(mode,curUser,data)

self._datamode = mode
data = string.sub(data,1,string.len(data)-1)
local _,_,sdata = string.find( data, "^%b<>%s(.*)$")
local _,_,cmd = string.find( data, "^%b<>%s["..self._Sets.prefixes.."](%w+)")
if cmd then
cmd = string.lower(cmd)
if self._Cmds[cmd] then
self._Cmds[cmd](self,curUser,data)
return 1
end
elseif sdata then
local corrans = table.foreachi(curTriv.ans, function(_,v)
if string.lower(sdata) == string.lower(v) then
return (v)
end
end)
if corrans and (not curTriv:GetGetQues()) then
-- SetGetQues
curTriv:SetGetQues(1)
local ansTime = string.format("%.2f",(os.clock()-curTriv.start)) -- Get Answering Time in sec.
if (TrivEx._Sets.showcorrectanswer == 1) then
-- Show right answer
local talked = nil
if string.find( sdata, corrans ) then
talked = corrans
end
if talked then
if not (self:GetPlayMode() == "pm") then
SendToAll(curUser.sName,corrans)
end
self:SendToPlayers("Correct "..curUser.sName.." the answer was \""..corrans.."\", You get "..curTriv.points.." Point(s). Answer solved in "..ansTime.." sec.")
-- Show other answeres if present
if curTriv.availans > 1 then
curTriv:ShowAnswer()
end
-- Update Scores
if self._Scores[curUser.sName] then
self._Scores[curUser.sName].Score = self._Scores[curUser.sName].Score + curTriv.points
self._Scores[curUser.sName].AvTime[1] = self._Scores[curUser.sName].AvTime[1] + ansTime
self._Scores[curUser.sName].AvTime[2] = self._Scores[curUser.sName].AvTime[2] + 1
self._Scores[curUser.sName].AvTime[3] = tonumber(string.format("%.2f",self._Scores[curUser.sName].AvTime[1]/self._Scores[curUser.sName].AvTime[2]))
else
self._Scores[curUser.sName] = {}
self._Scores[curUser.sName].Score = curTriv.points
self._Scores[curUser.sName].Streak = 1
self._Scores[curUser.sName].AvTime = { tonumber(ansTime),1,tonumber(ansTime) }
end
if (self._Sets.showcorrectanswer == 1) then
self:SendToPlayers(curUser.sName.."'s Stats, Score: "..self._Scores[curUser.sName].Score.." Point(s), Answerd Questions: "..self._Scores[curUser.sName].AvTime[2]..", Average Answering Time: "..string.format("%.2f",self._Scores[curUser.sName].AvTime[3]).." sec.")
end
-- Check for Streak
curTriv.streak:UpdStreak(curUser)

return 1
end
elseif (TrivEx._Sets.showcorrectanswer == 2) then
-- Show right answer
local talked = nil
if string.find( sdata, corrans ) then
talked = corrans
end
if talked then
if not (self:GetPlayMode() == "pm") then
SendToAll(curUser.sName,corrans)
end
self:SendToPlayers("Correct "..curUser.sName.." the answer was \""..corrans.."\", You get "..curTriv.points.." Point(s).")
-- Show other answeres if present
if curTriv.availans > 1 then
curTriv:ShowAnswer()
end
-- Update Scores
if self._Scores[curUser.sName] then
self._Scores[curUser.sName].Score = self._Scores[curUser.sName].Score + curTriv.points
self._Scores[curUser.sName].AvTime[1] = self._Scores[curUser.sName].AvTime[1] + ansTime
self._Scores[curUser.sName].AvTime[2] = self._Scores[curUser.sName].AvTime[2] + 1
self._Scores[curUser.sName].AvTime[3] = tonumber(string.format("%.2f",self._Scores[curUser.sName].AvTime[1]/self._Scores[curUser.sName].AvTime[2]))
else
self._Scores[curUser.sName] = {}
self._Scores[curUser.sName].Score = curTriv.points
self._Scores[curUser.sName].Streak = 1
self._Scores[curUser.sName].AvTime = { tonumber(ansTime),1,tonumber(ansTime) }
end
if (self._Sets.showcorrectanswer == 1) then
self:SendToPlayers(curUser.sName.."'s Stats, Score: "..self._Scores[curUser.sName].Score.." Point(s), Answerd Questions: "..self._Scores[curUser.sName].AvTime[2]..", Average Answering Time: "..string.format("%.2f",self._Scores[curUser.sName].AvTime[3]).." sec.")
end
-- Check for Streak
curTriv.streak:UpdStreak(curUser)
return 1
end
end

elseif (self:GetPlayMode() == "pm") then

self:SendToPlayers(data,curUser)
end

end

end

*EDIT* Fixed small bugs
*EDIT* Fixed sending answer to Main when playing in PM
Best regards,

jiten
Title:
Post by: jiten on 12 April, 2005, 16:14:29
QuoteOriginally posted by Falstaff
QuoteOriginally posted by Jelf
I know a few people wanted this so here ya go...
Trivia-Ex V.0.68 Lua 5 (http://lua.uknnet.com/attachment.php?attachmentid=85&sid=)

is there any way of adding the possibility of showing the accumulative score when a user answers the question i.e

correct (user) the answer was (answer) you get 9 points your score so far is 490

this would be a help

Try replacing all the "function TrivEx:ParseData(mode,curUser,data)" with this:
function TrivEx:ParseData(mode,curUser,data)

self._datamode = mode
data = string.sub(data,1,string.len(data)-1)
local _,_,sdata = string.find( data, "^%b<>%s(.*)$")
local _,_,cmd = string.find( data, "^%b<>%s["..self._Sets.prefixes.."](%w+)")
if cmd then
cmd = string.lower(cmd)
if self._Cmds[cmd] then
self._Cmds[cmd](self,curUser,data)
return 1
end
elseif sdata then
local corrans = table.foreachi(curTriv.ans, function(_,v)
if string.lower(sdata) == string.lower(v) then
return (v)
end
end)
if corrans and (not curTriv:GetGetQues()) then
-- SetGetQues
curTriv:SetGetQues(1)
local ansTime = string.format("%.2f",(os.clock()-curTriv.start)) -- Get Answering Time in sec.
if (TrivEx._Sets.showcorrectanswer == 1) then
-- Show right answer
local talked = nil
if string.find( sdata, corrans ) then
talked = corrans
end
if talked then
local TCopy = {}
table.foreach(self._Scores, function(i,v) table.insert(TCopy, {i,v}) end)
table.sort(TCopy,function(a,b) return(a[2].Score>b[2].Score) end)
for i = 1,TrivEx._Sets.displscorers do
if TCopy[i] then
if not (self:GetPlayMode() == "pm") then
SendToAll(curUser.sName,corrans)
end
self:SendToPlayers("Correct "..curUser.sName.." the answer was \""..corrans.."\", You get "..curTriv.points.." Point(s). Your score so far is: "..TCopy[i][2].Score..". Answer solved in "..ansTime.." sec.")
-- Show other answeres if present
if curTriv.availans > 1 then
curTriv:ShowAnswer()
end
-- Update Scores
if self._Scores[curUser.sName] then
self._Scores[curUser.sName].Score = self._Scores[curUser.sName].Score + curTriv.points
self._Scores[curUser.sName].AvTime[1] = self._Scores[curUser.sName].AvTime[1] + ansTime
self._Scores[curUser.sName].AvTime[2] = self._Scores[curUser.sName].AvTime[2] + 1
self._Scores[curUser.sName].AvTime[3] = tonumber(string.format("%.2f",self._Scores[curUser.sName].AvTime[1]/self._Scores[curUser.sName].AvTime[2]))
else
self._Scores[curUser.sName] = {}
self._Scores[curUser.sName].Score = curTriv.points
self._Scores[curUser.sName].Streak = 1
self._Scores[curUser.sName].AvTime = { tonumber(ansTime),1,tonumber(ansTime) }
end
if (self._Sets.showcorrectanswer == 1) then
self:SendToPlayers(curUser.sName.."'s Stats, Score: "..self._Scores[curUser.sName].Score.." Point(s), Answerd Questions: "..self._Scores[curUser.sName].AvTime[2]..", Average Answering Time: "..string.format("%.2f",self._Scores[curUser.sName].AvTime[3]).." sec.")
end
-- Check for Streak
curTriv.streak:UpdStreak(curUser)

return 1
end
end
end
elseif (TrivEx._Sets.showcorrectanswer == 2) then
-- Show right answer
local talked = nil
if string.find( sdata, corrans ) then
talked = corrans
end
if talked then
local TCopy = {}
table.foreach(self._Scores, function(i,v) table.insert(TCopy, {i,v}) end)
table.sort(TCopy,function(a,b) return(a[2].Score>b[2].Score) end)
for i = 1,TrivEx._Sets.displscorers do
if TCopy[i] then
if not (self:GetPlayMode() == "pm") then
SendToAll(curUser.sName,corrans)
end
self:SendToPlayers("Correct "..curUser.sName.." the answer was \""..corrans.."\", You get "..curTriv.points.." Point(s). Your score so far is: "..TCopy[i][2].Score..".")
-- Show other answeres if present
if curTriv.availans > 1 then
curTriv:ShowAnswer()
end
-- Update Scores
if self._Scores[curUser.sName] then
self._Scores[curUser.sName].Score = self._Scores[curUser.sName].Score + curTriv.points
self._Scores[curUser.sName].AvTime[1] = self._Scores[curUser.sName].AvTime[1] + ansTime
self._Scores[curUser.sName].AvTime[2] = self._Scores[curUser.sName].AvTime[2] + 1
self._Scores[curUser.sName].AvTime[3] = tonumber(string.format("%.2f",self._Scores[curUser.sName].AvTime[1]/self._Scores[curUser.sName].AvTime[2]))
else
self._Scores[curUser.sName] = {}
self._Scores[curUser.sName].Score = curTriv.points
self._Scores[curUser.sName].Streak = 1
self._Scores[curUser.sName].AvTime = { tonumber(ansTime),1,tonumber(ansTime) }
end
if (self._Sets.showcorrectanswer == 1) then
self:SendToPlayers(curUser.sName.."'s Stats, Score: "..self._Scores[curUser.sName].Score.." Point(s), Answerd Questions: "..self._Scores[curUser.sName].AvTime[2]..", Average Answering Time: "..string.format("%.2f",self._Scores[curUser.sName].AvTime[3]).." sec.")
end
-- Check for Streak
curTriv.streak:UpdStreak(curUser)
return 1
end
end
end
end

elseif (self:GetPlayMode() == "pm") then

self:SendToPlayers(data,curUser)
end

end

end
*EDIT* Fixed some bugs
*EDIT* Fixed sending answer to main when playing in PM
Cheers
Title:
Post by: Jelf on 14 April, 2005, 12:44:50
Wow, you've been busy jiten, as always :)

Nice job
Title:
Post by: jiten on 14 April, 2005, 14:46:02
Thanks :]
Title: help
Post by: night_hawk on 15 April, 2005, 06:42:07
i am so lost with this Trivia-Ex-V.0.68 for Lua 5  

this is what it does to me all the time

<-RasTriv-> Correct [HFF?]Night_Hawk the answer was "the thing", You get 3 Point(s). Your score so far is: 4. Answer solved in 78.52 sec.


[00:30] <-RasTriv-> Correct [HFF?]Night_Hawk the answer was "ostrich", You get 4 Point(s). Your score so far is: 4. Answer solved in 49.12 sec.

keeps saying the same scores

and my profiles do not work here is what i use...

i run robcop10c

profiles are  


-
-
  Master
  11111111111111001100111111111111
 

-
  Operator
  11110100011001001100110111111001
 

-
  VIP
  10000000000001001000000000000000
 

-
  Reg
  10000000000000000000000000000000
 

-
  Moderator
  11110110011101001100110111111111
 

-
  NetFounder
  11111111111111001100111111111111
 

 


please help me out thank you...
Title:
Post by: jiten on 15 April, 2005, 14:12:55
QuoteOriginally posted by night_hawk
i am so lost with this Trivia-Ex-V.0.68 for Lua 5  

Replace your "function TrivEx:ParseData(mode,curUser,data)" with this:
function TrivEx:ParseData(mode,curUser,data)

self._datamode = mode
data = string.sub(data,1,string.len(data)-1)
local _,_,sdata = string.find( data, "^%b<>%s(.*)$")
local _,_,cmd = string.find( data, "^%b<>%s["..self._Sets.prefixes.."](%w+)")
if cmd then
cmd = string.lower(cmd)
if self._Cmds[cmd] then
self._Cmds[cmd](self,curUser,data)
return 1
end
elseif sdata then
local corrans = table.foreachi(curTriv.ans, function(_,v)
if string.lower(sdata) == string.lower(v) then
return (v)
end
end)
if corrans and (not curTriv:GetGetQues()) then
-- SetGetQues
curTriv:SetGetQues(1)
local ansTime = string.format("%.2f",(os.clock()-curTriv.start)) -- Get Answering Time in sec.
if (TrivEx._Sets.showcorrectanswer == 1) then
-- Show right answer
local talked = nil
if string.find( sdata, corrans ) then
talked = corrans
end
if talked then
if not (self:GetPlayMode() == "pm") then
SendToAll(curUser.sName,corrans)
end
self:SendToPlayers("Correct "..curUser.sName.." the answer was \""..corrans.."\", You get "..curTriv.points.." Point(s). Answer solved in "..ansTime.." sec.")
-- Show other answeres if present
if curTriv.availans > 1 then
curTriv:ShowAnswer()
end
-- Update Scores
if self._Scores[curUser.sName] then
self._Scores[curUser.sName].Score = self._Scores[curUser.sName].Score + curTriv.points
self._Scores[curUser.sName].AvTime[1] = self._Scores[curUser.sName].AvTime[1] + ansTime
self._Scores[curUser.sName].AvTime[2] = self._Scores[curUser.sName].AvTime[2] + 1
self._Scores[curUser.sName].AvTime[3] = tonumber(string.format("%.2f",self._Scores[curUser.sName].AvTime[1]/self._Scores[curUser.sName].AvTime[2]))
else
self._Scores[curUser.sName] = {}
self._Scores[curUser.sName].Score = curTriv.points
self._Scores[curUser.sName].Streak = 1
self._Scores[curUser.sName].AvTime = { tonumber(ansTime),1,tonumber(ansTime) }
end
if (self._Sets.showcorrectanswer == 1) then
self:SendToPlayers(curUser.sName.."'s Stats, Score: "..self._Scores[curUser.sName].Score.." Point(s), Answerd Questions: "..self._Scores[curUser.sName].AvTime[2]..", Average Answering Time: "..string.format("%.2f",self._Scores[curUser.sName].AvTime[3]).." sec.")
end
-- Check for Streak
curTriv.streak:UpdStreak(curUser)
return 1
end
elseif (TrivEx._Sets.showcorrectanswer == 2) then
-- Show right answer
local talked = nil
if string.find( sdata, corrans ) then
talked = corrans
end
if talked then
if not (self:GetPlayMode() == "pm") then
SendToAll(curUser.sName,corrans)
end
self:SendToPlayers("Correct "..curUser.sName.." the answer was \""..corrans.."\", You get "..curTriv.points.." Point(s).")
-- Show other answeres if present
if curTriv.availans > 1 then
curTriv:ShowAnswer()
end
-- Update Scores
if self._Scores[curUser.sName] then
self._Scores[curUser.sName].Score = self._Scores[curUser.sName].Score + curTriv.points
self._Scores[curUser.sName].AvTime[1] = self._Scores[curUser.sName].AvTime[1] + ansTime
self._Scores[curUser.sName].AvTime[2] = self._Scores[curUser.sName].AvTime[2] + 1
self._Scores[curUser.sName].AvTime[3] = tonumber(string.format("%.2f",self._Scores[curUser.sName].AvTime[1]/self._Scores[curUser.sName].AvTime[2]))
else
self._Scores[curUser.sName] = {}
self._Scores[curUser.sName].Score = curTriv.points
self._Scores[curUser.sName].Streak = 1
self._Scores[curUser.sName].AvTime = { tonumber(ansTime),1,tonumber(ansTime) }
end
if (self._Sets.showcorrectanswer == 1) then
self:SendToPlayers(curUser.sName.."'s Stats, Score: "..self._Scores[curUser.sName].Score.." Point(s), Answerd Questions: "..self._Scores[curUser.sName].AvTime[2]..", Average Answering Time: "..string.format("%.2f",self._Scores[curUser.sName].AvTime[3]).." sec.")
end
-- Check for Streak
curTriv.streak:UpdStreak(curUser)
return 1
end
end

elseif (self:GetPlayMode() == "pm") then
self:SendToPlayers(data,curUser)
end

end

end

*EDIT* Fixed SendDataPlayer bug
*EDIT* Fixed sending answer on main when playing in PM
Cheers
Title:
Post by: night_hawk on 16 April, 2005, 19:34:37
getting this

Syntax ... things\nights hub\scripts\Trivia-Ex-V.0.68.lua5.lua:355: attempt to call global `SendDataPlayers'


that is why it is not adding up the scores


and i tryed that last one to and it would show nothing
Title:
Post by: jiten on 16 April, 2005, 19:52:05
QuoteOriginally posted by night_hawk
getting this

Syntax ... things\nights hub\scripts\Trivia-Ex-V.0.68.lua5.lua:355: attempt to call global `SendDataPlayers'


that is why it is not adding up the scores


and i tryed that last one to and it would show nothing

Try now. Guess it's ok now.
I've updated the previous post.

Cheers
Title: now i am getting this
Post by: night_hawk on 17 April, 2005, 03:39:57
Syntax ... things\nights hub\scripts\Trivia-Ex-V.0.68.lua5.lua:37: attempt to call method `NewUserConnected' (a nil value)
Title:
Post by: jiten on 17 April, 2005, 11:30:19
QuoteOriginally posted by night_hawk
Syntax ... things\nights hub\scripts\Trivia-Ex-V.0.68.lua5.lua:37: attempt to call method `NewUserConnected' (a nil value)

Can u tell me when does this error happens?
I've tested the script a bit, and didn't get any.
Title:
Post by: night_hawk on 17 April, 2005, 14:22:39
happens when a user logs into the hub...everytime....and i want it to still play in the main chat ...
Title:
Post by: jiten on 17 April, 2005, 14:40:58
QuoteOriginally posted by night_hawk
happens when a user logs into the hub...everytime....and i want it to still play in the main chat ...

Wierd. That error doesn't happen to me.
Can u post ur NewUserConnected function?
Title:
Post by: night_hawk on 17 April, 2005, 14:51:06
function NewUserConnected(curUser)
   TrivEx:NewUserConnected(curUser)

end

OpConnected = NewUserConnected

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

function UserDisconnected(curUser)
   TrivEx:UserDisconnected(curUser)

end

OpDisconnected = UserDisconnected
--------------------
function OnTimer()
   TrivEx:OnTimer()
end
Title:
Post by: jiten on 17 April, 2005, 15:32:44
This (http://mznetwork.mozdesigners.com/i/forum_files/Trivia-Ex-V.0.68.lua5.lua) is the one I'm using (without the errors u're reporting).

Best regards.
Title:
Post by: James on 29 April, 2005, 13:47:48
Hey guy`s!

      Is it possible to change the Trivia-Ex bot on this way, that when anybody knows 10 question without any help that he/she get the "Gag - Rule"? That mean he/she can only answer`s when 30min had past.
      There ary to many poeple which knew`s the question by heart and other poeple can't play in quiz.

         Thanks^^
Title:
Post by: James on 30 April, 2005, 11:51:21
Hey guy`s!

Is it possible to change the Trivia-Ex bot , so that  anybody anwering 10 question in a row without receiving any hints or help will be banned by the gag rule of this hub from main chat for about 30min.there are just to many chaps in here who already know all the answers by heart. those same chaps are taking the fun out the quiz for the new users who havnt played the trivia yet. so please be fair, let others play too, or get caught and be banned...

???????????????

Trivia + Simple GagBot  ????

   Thanks in Advance
Title:
Post by: jiten on 03 May, 2005, 14:13:25
QuoteOriginally posted by James
Hey guy`s!

Is it possible to change the Trivia-Ex bot , so that  anybody anwering 10 question in a row without receiving any hints or help will be banned by the gag rule of this hub from main chat for about 30min.there are just to many chaps in here who already know all the answers by heart. those same chaps are taking the fun out the quiz for the new users who havnt played the trivia yet. so please be fair, let others play too, or get caught and be banned...

???????????????

Trivia + Simple GagBot  ????

   Thanks in Advance
Check your other post again.

Cheers
Title:
Post by: jiten on 31 May, 2005, 15:04:33
Trivia Ex V 0.68 by chill

Changelog:

[*] Fixed: Answer showing before bot messages on Main and PM (jiten);
[*] Fixed: SendDataPlayer, ShowAnswer and TrivEx._Sets.solveques bug (thx to phorum)
[*] Added: Typos, capitals, commas, fullstops and many more (thx to forum)
[*] Added: Keep streak option - TrivEx._Sets.keepstreak (thx to phorum)
[*] Removed: Case sensitivity for answers (thx to phorum)
Grab it HERE (http://mznetwork.mozdesigners.com/i/forum_files/Trivia-Ex-V.0.68.lua5.rar).

Cheers
Title:
Post by: phorum on 11 June, 2005, 00:22:54
If the answer in the question file contains a dash (minus sign), the script accepts it but doesn't send the line with the correct user's answer to other users.

In function TrivEx:ParseData(mode,curUser,data) there are two instances of the following line:

   if string.find( string.lower(sdata), string.lower(corrans) ) then

i have replaced them with this:

   if string.lower(sdata) == string.lower(corrans) then

and now it's working ok.


TO JITEN:
hey m8, clean your PM box. it's full and won't accept new messages, and i can't reach you on your e-mail.
Title:
Post by: jiten on 11 June, 2005, 09:50:06
QuoteOriginally posted by phorum
If the answer in the question file contains a dash (minus sign), the script accepts it but doesn't send the line with the correct user's answer to other users.

In function TrivEx:ParseData(mode,curUser,data) there are two instances of the following line:

   if string.find( string.lower(sdata), string.lower(corrans) ) then

i have replaced them with this:

   if string.lower(sdata) == string.lower(corrans) then

and now it's working ok.


TO JITEN:
hey m8, clean your PM box. it's full and won't accept new messages, and i can't reach you on your e-mail.
Hi there phorum. Thanks for your report.
And yes, I've cleaned my PM box, didn't know that there was a limit :D
Btw, I'm going to have a look at my mail and will tell you something.

Cheers
Title:
Post by: Mogli on 11 June, 2005, 20:42:47
I forgot my pass,
and was bored of the old nick anyways ( me = chill )

jiten thx for keeping this script alive :), and
working on it
Title:
Post by: jiten on 11 June, 2005, 23:18:50
QuoteOriginally posted by Mogli
I forgot my pass,
and was bored of the old nick anyways ( me = chill )

jiten thx for keeping this script alive :), and
working on it
Don't mention it :]

Cheers
Title:
Post by: jiten on 16 June, 2005, 11:41:57

Grab it HERE (http://mznetwork.mozdesigners.com/i/forum_files/Trivia-Ex-v0.68a.lua5.rar).
[/list]
Title:
Post by: Krysalis on 23 June, 2005, 18:46:25
links dead?
Title:
Post by: jiten on 23 June, 2005, 19:53:40
QuoteOriginally posted by Krysalis
links dead?
Tried it now and it's working.
Title:
Post by: Krysalis on 23 June, 2005, 21:46:26
and nows dead again. Sorry, wasnt quick enough.

Greets
Title:
Post by: jiten on 23 June, 2005, 21:51:40
Try this (http://ptxscriptdb.psycho-chihuahua.net/download.php?view.46) link then.

Cheers
Title:
Post by: Ubikk on 23 June, 2005, 23:12:07
Nope.. link is still dead
Title:
Post by: jiten on 24 June, 2005, 12:53:00
QuoteOriginally posted by Ubikk
Nope.. link is still dead
It should be ok now.
Try the one in the last released trivia version.

Best regards,

jiten
Title:
Post by: Ubikk on 27 June, 2005, 23:42:22
Ok.. i downloaded the new version
It works perfectly  :D

Thanks a lot for your support 8)
Title: Another request
Post by: Ubikk on 29 June, 2005, 14:29:36
When a user answer a certain question and if he is on a streak, the mainchat gets sometimes flooded. Here is an example:

Quote5:13:08] Intrebarea - Nr. 2412 din 5569 intrebari.
   ----------------------------------------------------------------------
   > Puncte : 7 - Total Raspunsuri: 1
   Intrebare:  Care este mancarea traditionala in Romania
   Hint:  *******
   ----------------------------------------------------------------------
[15:13:12] <[RO][IS][dim]Blake> sarmale
[15:13:12] Corect [RO][IS][dim]Blake raspunsul era "sarmale". Meriti 7 puncte pt efortul tau de 4.30 secunde.
[15:13:12] [RO][IS][dim]Blake's Stats, Scor: 1498 Puncte, Raspunsuri corecte: 237, Timp mediu de raspuns: 13.64 secunde.[switch 1]
[15:13:12] Bravo [RO][IS][dim]Blake, 3( consecutive answers) raspunsuri consecutive... esti tare [switch 2]
[/size]

Is it possible to add a trigger or something similar that can be turned on/off to show the lines in red only to the user that gave the correct answer.
Example.. if Blake answered correct he should be the only one seeing the rows in red if switch 1 and 2 are turned off
And this is what a normal user should see with both switches turned off
Quote5:13:08] Intrebarea - Nr. 2412 din 5569 intrebari.
   ----------------------------------------------------------------------
   > Puncte : 7 - Total Raspunsuri: 1
   Intrebare:  Care este mancarea traditionala in Romania
   Hint:  *******
   ----------------------------------------------------------------------
[15:13:12] <[RO][IS][dim]Blake> sarmale
[15:13:12] Corect [RO][IS][dim]Blake raspunsul era "sarmale". Meriti 7 puncte pt efortul tau de 4.30 secunde.
[/size]

I hope you guys understood my idea... if no, please feel free to reply, so that I can offer the necessary details :)
Title:
Post by: jiten on 29 June, 2005, 15:46:33
QuoteOriginally posted by Ubikk
Is it possible to add a trigger or something similar that can be turned on/off to show the lines in red only to the user that gave the correct answer.
Example.. if Blake answered correct he should be the only one seeing the rows in red if switch 1 and 2 are turned off
And this is what a normal user should see with both switches turned off
Quote5:13:08] Intrebarea - Nr. 2412 din 5569 intrebari.
   ----------------------------------------------------------------------
   > Puncte : 7 - Total Raspunsuri: 1
   Intrebare:  Care este mancarea traditionala in Romania
   Hint:  *******
   ----------------------------------------------------------------------
[15:13:12] <[RO][IS][dim]Blake> sarmale
[15:13:12] Corect [RO][IS][dim]Blake raspunsul era "sarmale". Meriti 7 puncte pt efortul tau de 4.30 secunde.
[/size]

I hope you guys understood my idea... if no, please feel free to reply, so that I can offer the necessary details :)
Sure, I can add it.
By the way, thank you for your words :]

Best regards,

jiten
Title:
Post by: Ubikk on 02 July, 2005, 22:16:27
Ok.. I'm waiting for someone to help..
Oh.. and by the way.. is it possible to hide all the game for users that don't wish to play?
Ex, if a user1  types !play, he will be able to see all the game
If user2 that enters the hub doesnt type !play he will only see what user1 is writing without seeing the bot's messages

All this should happen in mainchat.. nobody likes to play trivia on PM :(
Title:
Post by: jiten on 04 July, 2005, 12:06:45
QuoteOriginally posted by Ubikk
Ok.. I'm waiting for someone to help..
Oh.. and by the way.. is it possible to hide all the game for users that don't wish to play?
Ex, if a user1  types !play, he will be able to see all the game
If user2 that enters the hub doesnt type !play he will only see what user1 is writing without seeing the bot's messages

All this should happen in mainchat.. nobody likes to play trivia on PM :(
Just waiting for the site where I upload my scripts to, to release the version that includes this and other requests.

Cheers
Title:
Post by: H?LL?L?L??nG?L on 04 July, 2005, 16:59:50
Hiya  :P was wondering if anyone can help.. am i doing something wrong or is the -trivhint not working? Ive enabled it in the script but still nothing any ideas? :P  :P
Yip im doing something wrong plz help :D
Title:
Post by: Markitos on 04 July, 2005, 17:03:38
QuoteOriginally posted by H?LL?L?L??nG?L
Hiya  :P was wondering if anyone can help.. am i doing something wrong or is the -trivhint not working? Ive enabled it in the script but still nothing any ideas? :P  :P
Did u receive an error?
Title:
Post by: H?LL?L?L??nG?L on 04 July, 2005, 17:08:33
nope i just dont know if im changing it properly cause when i look in the config it hasnt changed X(
Title:
Post by: Ubikk on 04 July, 2005, 18:33:14
QuoteOriginally posted by jiten
QuoteOriginally posted by Ubikk
Ok.. I'm waiting for someone to help..
Oh.. and by the way.. is it possible to hide all the game for users that don't wish to play?
Ex, if a user1  types !play, he will be able to see all the game
If user2 that enters the hub doesnt type !play he will only see what user1 is writing without seeing the bot's messages

All this should happen in mainchat.. nobody likes to play trivia on PM :(
Just waiting for the site where I upload my scripts to, to release the version that includes this and other requests.

Cheers

Thanks, jiten. You're the best  ;)
Title:
Post by: jiten on 04 July, 2005, 18:36:17
QuoteOriginally posted by H?LL?L?L??nG?L
nope i just dont know if im changing it properly cause when i look in the config it hasnt changed X(
The Config part in the script is the default setting saved on first run.
After that, you change it with the command: "!triviahint"

Best regards,

jiten
Title:
Post by: H?LL?L?L??nG?L on 04 July, 2005, 19:36:26
Got it Jiten thank u :P  :P  :P
Title:
Post by: jiten on 04 July, 2005, 21:07:36

Grab it HERE (http://mznetwork.co.mz/i/forum_files/Trivia-Ex-v0.68b.lua5.rar).
[/list]
Title:
Post by: Psycho_Chihuahua on 04 July, 2005, 21:10:57
QuoteOriginally posted by jiten

Just waiting for the site where I upload my scripts to, to release the version that includes this and other requests.

Cheers

as an alternative you could still upload them to the ptxscriptdb (http://ptxscriptdb.psycho-chihuahua.net)  ;)
Title:
Post by: jiten on 04 July, 2005, 21:28:28
QuoteOriginally posted by Psycho_Chihuahua
QuoteOriginally posted by jiten

Just waiting for the site where I upload my scripts to, to release the version that includes this and other requests.

Cheers

as an alternative you could still upload them to the ptxscriptdb (http://ptxscriptdb.psycho-chihuahua.net)  ;)
Indeed ;)
Didn't post them earlier because bastya wasn't here, so thought that it would take long for them to be accepted :D
Will do it tomorrow as you are here.

Cheers m8
Title:
Post by: Psycho_Chihuahua on 05 July, 2005, 12:29:29
:D yeah i'm still here and i've just accepted the files so they r now open for the public ;)
Title:
Post by: hnr21 on 17 July, 2005, 19:36:01
I use PX v0.3.3.1 [debug], RoboCop v10.01e and Trivia-Ex-V.0.68b.lua5.lua

Some suggestions:
1) When displaying a question to show some predefined chars like <'>,<->,<_>,, in the question text.
2) When answer is correct to a question to display the points that have been won, the current ranking and after that the first user (and points) ranked ahead of the current user.
Example: Kewl, "..curUser.sName.." You get ..curTriv.points.." Point(s) Total of "..self._Scores[curUser.sName].Score..", currently ranked in xth of "..table.getn(TCopy).." Players - y Point(s) behind "..aheadUser.sName.." !

This way one doesnt have to !trivmyscore everytime to c his/her stats !

Thank you very much for your work and support ! :)
Title:
Post by: Ubikk on 28 July, 2005, 21:11:59
[22:01] Syntax [string "-- Trivia Ex V 0.68b by chill
..."]:220: error loading package `TRIVIA/TriviaExPMPlayers.txt' (TRIVIA/TriviaExPMPlayers.txt:3: invalid control char near `char(0)')



Any idea what's this?

This error ocurred suddenly when I came back this evening... I really dont understand what could cause this..
Title:
Post by: Ubikk on 28 July, 2005, 21:15:45
edit: sorry.. my 1st double post :)
Title:
Post by: Sarpanch on 30 July, 2005, 15:54:21
Hi can anyone tell me where i can get questions for trivia besdies the 1s already in there? thanks
Title:
Post by: night_hawk on 30 July, 2005, 22:26:49
you can always make your own quetions if you use the new trivia verion....that is what i am doing...
Title:
Post by: Sarpanch on 31 July, 2005, 13:34:57
Yea i am using the new trivia version, i think ill do that instead thanks :]
Title:
Post by: Jacko on 29 August, 2005, 23:00:31
hello ?(
I am using 0.3.3.0 build 17.08debug & triv 0.68b

do any of you know of a script that will collect top 10 players from triv on my command and send info to a ptokax text file called something like trivhistory,so before i reset scores the top 10 would be logged .
so text file would show

August top 10
1st  bla
2nd bla-bla
and onward

I am thinking that i only want to log position & not all the other stuff


              thanks  :rolleyes:
Title:
Post by: Ubikk on 16 September, 2005, 00:59:17
I have about 18.000 questions stored in my question files, but users are still complaining about the fact that the same questions are displayed over and over again in short intervals of time...
Do you guys have any suggestion to avoid that? :(
Title:
Post by: bangee on 17 September, 2005, 16:15:11
old in the older versions of ptokax when you nswered the trivia questions it would look like this


[2005-08-06 13:10] nirvana
[2005-08-06 13:10] <-Trivia-> Correct MarcoLtd. the answer was "nirvana", You get 7 Point(s). Answer solved in 10.48 sec.
[2005-08-06 13:10] <-Trivia-> That gives you a total score of 7 Point(s).
[2005-08-06 13:10] <-Trivia-> QUESTION - Nr. 5426 from 6411 Questions.


now on the newer versions they look like this

[09:00:56] <-Trivia-> Correct Marco the answer was "Frankie Goes To Hollywood", You get 7 Point(s). Answer solved in 312.17 sec.
[09:00:56] frankie goes to hollywood


is there anyway to fix it to make it look like the older version. doesnt have to be exact but would like to show the total score when you answer a questions. so you dont need ot type in  !trivscore each time to find out what your score is.

thanks for any help on this
Title:
Post by: bangee on 17 September, 2005, 23:01:39
2 more questions to report

the trivhint and trivskip are comming up as disabled even though they are enabled in the script
Title: I agree with Ubikk, also I wonder about lag
Post by: Paco on 18 September, 2005, 02:16:02
I only have 4200 questions in my trivia file, but i noticed that questions are repeating. Can some1 figer out why? And other thing. Some of them are co`playning about lag. How cand I reduce it in this version. Where should I change in settings. Thks.
Title:
Post by: (-=TrIp-iN-SuN=-) on 18 October, 2005, 12:09:25
same one can doing this script like that i need help plz?


[10:31]
-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
   Question :          What Is The Artist From The Music Smack My Bitch Up ?
   Answer :       *******
   Point(s) : 7
------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
[10:31]
-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
   Question :          What Is The Artist From The Music Smack My Bitch Up ?
   Answer :       P******
   Point(s) : 6
------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
[10:31]
-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
   Question :          What Is The Artist From The Music Smack My Bitch Up ?
   Answer :       P****g*
   Point(s) : 5
------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
[10:32]
-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
   Question :          What Is The Artist From The Music Smack My Bitch Up ?
   Answer :       Pr***g*
   Point(s) : 4
------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
[10:32]
-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
   Question :          What Is The Artist From The Music Smack My Bitch Up ?
   Answer :       Pr**ig*
   Point(s) : 3
------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
[10:32]
------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
    Answer :    Prodigy
    Point(s) : 0
------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
 NEXT QUESTION IN 10 SECONDS
------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
[10:32]
-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
   Question :          What Is The Artist From The Music Dive 2 Dive ?
   Answer :       ***** *****
   Point(s) : 10
------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
[10:32]
-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
   Question :          What Is The Artist From The Music Dive 2 Dive ?
   Answer :       S**** S****
   Point(s) : 8
-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
Title:
Post by: (-=TrIp-iN-SuN=-) on 18 October, 2005, 19:58:25
plz help me same one
Title:
Post by: (-=TrIp-iN-SuN=-) on 18 October, 2005, 23:49:49
when i changed to use hint command here


TrivEx._Sets.folder = "TRIVIA"               -- The name of the Folder, for the Questionfile.

TrivEx._Sets.showcorrectanswer = 1            -- 1 = shows detailed stuff, 2 = only shows that it was the right answer
TrivEx._Sets.showquestion = 1               -- 1 = Shows "Question Number,Category,Question,Answer", 2 = Shows "Question Number,Question,Answer", 3 = Shows "Question,Answer"
TrivEx._Sets.revealques = 2               -- 1 = Random displaying of hints, 2 = Displays the first letters of the hint first (Grands Trivia).
TrivEx._Sets.trivshowhint = 2               -- 1 = reveal by number of chars 2 = reveal by number of hints

TrivEx._Sets.autostop = 10               -- nil when no autostop, 1 - endless, when you want the script to stop after a certain number of unanswered questions

TrivEx._Sets.splitques = 90               -- After how many chars the question is splitted


TrivEx._Sets.memques = 50               -- How many questions are loaded into Memory

TrivEx._Sets.breaktime = 5               -- Trivia Break Time in minutes
TrivEx._Sets.timebreak = 20               -- Time in minutes till Trivia Break

TrivEx._Sets.dobreak = 1               -- 1 = do a triviabreak between 'TrivEx._Sets.timebreak' Minutes, 0 = no triviabreak

TrivEx._Sets.showques = 15               -- Time between each hint in seconds

TrivEx._Sets.displscorers = 100               -- The number of trivia scorers shown
TrivEx._Sets.displtoptrivs = 10               -- Number of top trivias shown

TrivEx._Sets.revealedchars = 2               -- Stands for how many chars are revealed per hint.
TrivEx._Sets.shownhints = 4               -- Stands for how many Hints are displayed (May not be totally accurate)
TrivEx._Sets.solveques = 2               -- The Question will be solved when there are only 'TrivEx._Sets.solveques' unrevealed chars left
TrivEx._Sets.keepstreak = 1               -- Handles streak after unanswered questions   == 1 - keep streak ; 0 - lose streak
TrivEx._Sets.maintoall = true               -- Restrict play in main == true: everyone is a player; false: every trivia player has to login
TrivEx._Sets.showstreak = true               -- true = Show streak messages; false = don't show

i all time get this

[23:47] TriviaHint is currently disabled.
Title:
Post by: Jacko on 19 October, 2005, 00:47:28
one of the wise ones will maybe know better way but i think the setting you want is here

---------------------------------------------------------------------------------------
--   TRIVIA EX CONFIG
---------------------------------------------------------------------------------------

TrivEx._Config = {}

TrivEx._Config.mode =       "main"            -- "main" = Trivia is played in MainChat, "pm" = Trivia is played in PM
TrivEx._Config.showquesmode =    1            -- Questions Mode 1 = Random, 2 = Sequential (e.g. 1,2,3)

TrivEx._Config.trivskip =    0            -- 1 = trivskip enabled, 0 = disabled

TrivEx._Config.trivhint =    0            -- 1 = trivhint enabled, 0 = disabled
TrivEx._Config.sequentialnum =    0


you are maybe changing the wrong setting   :(

I am using V.0.68b.lau5
Title:
Post by: ??????Hawk?????? on 19 October, 2005, 01:31:52
change

TrivEx._Config.trivhint = 0 -- 1 = trivhint enabled, 0 = disabled

to

TrivEx._Config.trivhint = 1 -- 1 = trivhint enabled, 0 = disabled
Title:
Post by: DJ-Chris on 20 October, 2005, 22:12:38
Can u make start trivia automaitc every 2 hours at right time ??  ?(
Title:
Post by: bastya_elvtars on 20 October, 2005, 22:16:30
So every day at 2:00? Why not use a clientside script for it?
Title:
Post by: DJ-Chris on 20 October, 2005, 22:20:31
QuoteOriginally posted by bastya_elvtars
So every day at 2:00? Why not use a clientside script for it?

Bro start every 2 hours but at exact time

00:00

02:00

04:00

05:00

etcc...
Title:
Post by: bastya_elvtars on 20 October, 2005, 22:56:14
Can you post a link to the trivia version you are using?
Title:
Post by: DJ-Chris on 20 October, 2005, 23:17:17
QuoteOriginally posted by bastya_elvtars
Can you post a link to the trivia version you are using?

-- Converted to Lua5 By Jelf 12/03/05 With thanks to kepp
-- Trivia Ex V 0.68 by chill
-- Serialisation by RabidWombat, modded to exclude functions

-- This script is opensource, that means that anybody may edit/copy this code
-- and I will not come and cry for money, if you take bits to make a even more useless script
-- then leave a note over it with my name, would be cool :).

-- Lucida Console, Courier New

thanx bro :))
Title:
Post by: phorum on 23 October, 2005, 12:58:03
I have reported a bug in PtokaX concerning the random generated data function, which affects the TriviaEx.v.68 script. When you start the PtokaX server the questions in trivia are just the same as the last time Ptokax was started. I can see that other users have reported the same behaviour. This problems manifested itself in Ptokax 3.3.21. In the previous version 3.3.1 everything works perfectly, and if the LUA interpreter incorporated in Ptokax 3.3.21 is the same version as in 3.3.1, it is clear that the problem lies in PtokaX (something i could not convince PPK in several PM's too ... lol)
QuotePPK: Hi, sorry but i don't know what random generator you mean  If is something in lua, then must be lua bug (i don't make any changes in lua related to random generator from 0.3.3.1 to 0.3.3.2x)...
Probably the call for the random function from the integrated LUA interpreter has some problems. I want to know if someone has discovered something new around this PtokaX bug. It is very annoying because it pretty much renders the trivia useless. Thank you in advance and keep up the good work!

P.S. For all users of trivia v.0.68, if you want the script to work normally, you can downgrade to PtokaX 3.3.1 until this issue is resolved.
Title:
Post by: bastya_elvtars on 23 October, 2005, 13:04:43
Sorry, but bthis is incorrect. This is due to the behaviour of LUA, and has nothing to do with PtokaX. If you post a link, I will fix this in Triv.
Title:
Post by: Dessamator on 23 October, 2005, 16:50:35
QuoteOriginally posted by phorum
I have reported a bug in PtokaX concerning the random generated data function, which affects the TriviaEx.v.68 script. When you start the PtokaX server the questions in trivia are just the same as the last time Ptokax was started. I can see that other users have reported the same behaviour. This problems manifested itself in Ptokax 3.3.21. In the previous version 3.3.1 everything works perfectly, and if the LUA interpreter incorporated in Ptokax 3.3.21 is the same version as in 3.3.1, it is clear that the problem lies in PtokaX (something i could not convince PPK in several PM's too ... lol)
QuotePPK: Hi, sorry but i don't know what random generator you mean  If is something in lua, then must be lua bug (i don't make any changes in lua related to random generator from 0.3.3.1 to 0.3.3.2x)...
Probably the call for the random function from the integrated LUA interpreter has some problems. I want to know if someone has discovered something new around this PtokaX bug. It is very annoying because it pretty much renders the trivia useless. Thank you in advance and keep up the good work!

P.S. For all users of trivia v.0.68, if you want the script to work normally, you can downgrade to PtokaX 3.3.1 until this issue is resolved.

Simple to solve, create ur own random function, if u have the knowledge to do so.