Stevenn Posted May 1, 2012 Share Posted May 1, 2012 Hello, I got a quuestion, when a player connects to my server for the first time, a GUI should be drawed, but I don't know what the event is named or don't i need an event Link to comment
Wei Posted May 1, 2012 Share Posted May 1, 2012 setElementData getElementData like that: function firstTimeJoin() local mamamia = getElementData(source, "firsttimejoin") if (mamamia == false) then setElementData( source, "firsttimejoin", true) end end addEventHandler("onPlayerJoin", firstTimeJoin) I'm not completly sure about sample... Link to comment
Michael# Posted May 1, 2012 Share Posted May 1, 2012 @@blazy, you're wrong. Element data is deleted when element is deleted. When player join, element data 'firsttimejoin' on player is nil. You must check by name, serial, account, ip or whatever you like. Link to comment
Callum Posted May 1, 2012 Share Posted May 1, 2012 You could use client-side XML functions, though this would be reset if the player deletes their client resources, etc. Alternatively you could base it on serial, in an SQL table, but it just depends on why you need this data. 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