04.11.2012, 12:21
You mean make the top just for the users who are online, or offline too?
If you want it for everybody, online and offline, you must save how much they played in the server. With SQL is pretty easy, and in my opinion the best way to to this in PAWN in save the current time into a variable when they join (OnPlayerConnect with gettime) and when they disconnect (OnPlayerDisconnect with gettime) get the current time and rest the first variable.
Then add the result to the field. I think it's one of the best free lagg ways.
Now, to group them, use GROUP BY and LIMIT. If you have more doubts just ask.
Best regards!
If you want it for everybody, online and offline, you must save how much they played in the server. With SQL is pretty easy, and in my opinion the best way to to this in PAWN in save the current time into a variable when they join (OnPlayerConnect with gettime) and when they disconnect (OnPlayerDisconnect with gettime) get the current time and rest the first variable.
Then add the result to the field. I think it's one of the best free lagg ways.
Now, to group them, use GROUP BY and LIMIT. If you have more doubts just ask.
Best regards!