Shidony Posted August 27, 2013 Share Posted August 27, 2013 (edited) Resolved Edited August 28, 2013 by Guest Link to comment
TAPL Posted August 27, 2013 Share Posted August 27, 2013 The table textePerso might be not defined and this cause the script stops execution at line 126. Link to comment
Shidony Posted August 27, 2013 Author Share Posted August 27, 2013 textePerso is defined at the start of the script, the problem is there i think: triggerServerEvent("onClientGetCharacterInfos", source, 1) nomPerso = getElementData(source, "Personnage") argentPerso = getElementData(source, "argentPersonnage") Link to comment
TAPL Posted August 27, 2013 Share Posted August 27, 2013 Actually you should use localPlayer instead of source as i guess there something wrong with the trigger maybe? Do you use any export at server side? it might that the exported resource haven't started yet. Link to comment
Shidony Posted August 27, 2013 Author Share Posted August 27, 2013 No i don't export any function, and with localPlayer it's the same Link to comment
Shidony Posted August 27, 2013 Author Share Posted August 27, 2013 Sorry for thread bumping but i found that the problem is here: addEvent("onClientGetCharacterInfos", true ) addEventHandler("onClientGetCharacterInfos", root, function(characterID) local name = tostring(getElementData(peds[characterID], "Nom")) local argent = tonumber(getElementData(peds[characterID], "Argent")) setElementData(source, "nomPerso", name) setElementData(source, "argentPerso", argent) outputChatBox(name, source, 0, 255, 255, false) outputChatBox(argent, source, 0, 255, 255, false) end) The two outputChatBox send me the good values but when i use outputChatBox but here: triggerServerEvent("onClientGetCharacterInfos", thePlayer, actualPerso[thePlayer]) outputChatBox("2", 255, 255, 255, false) nomPerso = getElementData(thePlayer, "nomPerso") argentPerso = getElementData(thePlayer, "argentPerso") outputChatBox(nomPerso, 255, 255, 255, false) outputChatBox(argentPerso, 255, 255, 255, false) The two outputChatBox send me false. Link to comment
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now