Resmurf Posted December 22, 2011 Posted December 22, 2011 I'm trying to add time played and sesion time so what function should i use? i'm tyring with getPlayerIdleTime and nothing and isTimer not working, anyone can help me out with that plz?
Xeno Posted December 22, 2011 Posted December 22, 2011 As far as I know, getPlayerIdleTime is bugged ( I think )
Castillo Posted December 23, 2011 Posted December 23, 2011 The value stored in getPlayerIdleTime is from when a player becomes idle (AFK) as far as I know.
GanJaRuleZ Posted December 23, 2011 Posted December 23, 2011 (edited) Hi , maybe i can help The function to get the time spent on the server is getTickCount This function returns amount of time that your system has been running in milliseconds If you want to save it , you'll need the following functions executeSQLCreateTable("NAME", "STRING, INT") --INT is what is contains--> executeSQLSelect ( string tableName, string fields, [ string conditions, int limit ] ) --Here you will select the db executeSQLUpdate ( string tableName, string set, [ string conditions ] ) --It updates the current table If you will need an example , just announce me Good Luck with the scripting @Edit: if you want to get he's time , from when he logins in , until he quit (or he logged out) use onPlayerLogin --and onPlayerQuit --For until he quit onPlayerLogout --for until he loggout I hope i helped you Edited December 23, 2011 by Guest
JR10 Posted December 23, 2011 Posted December 23, 2011 You can also just use a timer, each minute use setAccountData or setElementData and increase the player's spent time on the server.
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