PtokaX forum

Archive => Leviathan => AllInOne Scripts => Archived 5.1 boards => Leviathan - Bugs => Topic started by: 6Marilyn6Manson6 on 16 April, 2007, 00:21:34

Title: Bug In Function UserInfo
Post by: 6Marilyn6Manson6 on 16 April, 2007, 00:21:34


   Script error found, please notify C??o?y?? or T?M??r?V?ll?R with this message:
   Leviathan v3.22 PtokaX 0.3.5.2 Lua 5.1
   ...rio/Desktop/PX/scripts/LV_DataBase/lua/Functions.lua:301: attempt to index field '?' (a nil value)


   Script error found, please notify C??o?y?? or T?M??r?V?ll?R with this message:
   Leviathan v3.22 PtokaX 0.3.5.2 Lua 5.1
   ...rio/Desktop/PX/scripts/LV_DataBase/lua/Functions.lua:304: attempt to index field '?' (a nil value)


And in showerror command:

tbl = {
   ["...rio/Desktop/PX/scripts/LV_DataBase/lua/Functions.lua:301: attempt to index field '?' (a nil value)"] = 1,
   ["...rio/Desktop/PX/scripts/LV_DataBase/lua/Functions.lua:304: attempt to index field '?' (a nil value)"] = 1,
}

I don't understand this error :S
Title: Re: Bug In Function UserInfo
Post by: Psycho_Chihuahua on 16 May, 2007, 13:03:57
get the same error here too

   Script error found, please notify C??o?y?? or T?M??r?V?ll?R with this message:
   Leviathan v3.22 PtokaX 0.3.6.0 Lua 5.1
   ...viathanHub3.22/scripts/LV_DataBase/lua/Functions.lua:301: attempt to index field '?' (a nil value)

happens when a user comes in using ApexDC at the moment (not sure if its to do with the client or not as there only a dozen users in that hub)
Title: Re: Bug In Function UserInfo
Post by: Cêñoßy†ê on 16 May, 2007, 16:11:59
bug is on message counter part ;)
I think both of you have registered users via PtokaX GUI ??
If so,remember to restart leviathan so it adds that users name to own database.



UpdateMessages = function(user,what)
if what == "Main" then
local iUpdate = UserInfo[string.lower(user.sName)]["Messages"] ["MAIN"] or 0 -- line 301
iUpdate = iUpdate + 1 UserInfo[string.lower(user.sName)]["Messages"] ["MAIN"] = iUpdate
else
local iUpdate = UserInfo[string.lower(user.sName)]["Messages"] ["PM"] or 0 --line 304
iUpdate = iUpdate + 1 UserInfo[string.lower(user.sName)]["Messages"] ["PM"] = iUpdate
end
saveTableToFile(UserInfoFile,UserInfo,"UserInfo")
end
Title: Re: Bug In Function UserInfo
Post by: Psycho_Chihuahua on 16 May, 2007, 22:57:37
it happend when a user tried to enter the hub using apexdc, i then told him to try using dc emulation for entering the hub which he then did, on that the error disapeared and hasnt happend again so far
Title: Re: Bug In Function UserInfo
Post by: 6Marilyn6Manson6 on 16 May, 2007, 22:58:47
Quote from: Psycho_Chihuahua on 16 May, 2007, 22:57:37
it happend when a user tried to enter the hub using apexdc, i then told him to try using dc emulation for entering the hub which he then did, on that the error disapeared and hasnt happend again so far

My client is ApexDC and I receive same error  ::)
Title: Re: Bug In Function UserInfo
Post by: Madman on 17 May, 2007, 02:26:25
That function is used 2 times, if user writes in pm or in main, then the script calls this funtion...


I logged in with ApexDC, no error. dosent matter if i was regged or not
Title: Re: Bug In Function UserInfo
Post by: TrIp-iN-SuN on 28 May, 2007, 10:50:29
i get this but in LV_3.1 i dont doing nathing and its show me same time this bug

C:/PsySun3/scripts/LV_DataBase/lua/Functions.lua:292: attempt to index field '?' (a nil value)
Title: Re: Bug In Function UserInfo
Post by: Madman on 28 May, 2007, 16:27:33
Quote from: TrIp-iN-SuN on 28 May, 2007, 10:50:29
i get this but in LV_3.1
Typo? or are you useing 3.1? if so, please upgrade
Title: Re: Bug In Function UserInfo
Post by: TrIp-iN-SuN on 28 May, 2007, 23:59:53
no i dont want to upgrade becose over new scripts dont have 7 profiles and here u have in 3.1

if u cant help me ok
Title: Re: Bug In Function UserInfo
Post by: Cêñoßy†ê on 29 May, 2007, 15:12:45
Quote from: TrIp-iN-SuN on 28 May, 2007, 10:50:29
i get this but in LV_3.1 i dont doing nathing and its show me same time this bug

C:/PsySun3/scripts/LV_DataBase/lua/Functions.lua:292: attempt to index field '?' (a nil value)

open file functions.lua
find lines -->

UpdateMessages = function(user,what)
if what == "Main" then
local iUpdate = UserInfo[user.sName]["Messages"] ["MAIN"] or 0
iUpdate = iUpdate + 1 UserInfo[user.sName]["Messages"] ["MAIN"] = iUpdate
else
local iUpdate = UserInfo[user.sName]["Messages"] ["PM"] or 0
iUpdate = iUpdate + 1 UserInfo[user.sName]["Messages"] ["PM"] = iUpdate
end
saveTableToFile(UserInfoFile,UserInfo,"UserInfo")
end


change it to this -->

UpdateMessages = function(user,what)
-- if what == "Main" then
-- local iUpdate = UserInfo[user.sName]["Messages"] ["MAIN"] or 0
-- iUpdate = iUpdate + 1 UserInfo[user.sName]["Messages"] ["MAIN"] = iUpdate
-- else
-- local iUpdate = UserInfo[user.sName]["Messages"] ["PM"] or 0
-- iUpdate = iUpdate + 1 UserInfo[user.sName]["Messages"] ["PM"] = iUpdate
-- end
-- saveTableToFile(UserInfoFile,UserInfo,"UserInfo")
end


that should solve that problem (fixed in newer versions) ;)
Title: Re: Bug In Function UserInfo
Post by: TrIp-iN-SuN on 03 July, 2007, 15:29:26
its happned agian many time dont see this but its agian


C:/PsySun4/scripts/LV_DataBase/lua/Functions.lua:292: attempt to index field '?' (a nil value)
and this error too
C:/PsySun4/scripts/LV_DataBase/lua/Functions.lua:289: attempt to index field '?' (a nil value)

same one can help?

its happned when profile master but not for all users with that profile its happend type same thing in main chat or pm or use same command but i try to changed my self to master nathing happned and few profiles too this happned but not for all users
same one can help me here i wait few days no one answer me