Quote:
Originally Posted by xines
|
If you read the wiki example carefully you shall see it uses.
Code:
public void OnClientPutInServer(int client)
public void OnClientDisconnect(int client)
The timer is created under OnClientPutInServer forward, and destroyed under OnClientDisconnect if the client leaves before, using user id inside the timer callback is useless, since the timer is destroyed when the client leaves the server (so the userid becomes invalid).
Then it shows that you can use client serial OR UserID.
And you should notice the timer is no longer destroyed under OnClientDisconnect forward.
Because under the timer callback we look if the client serial OR UserID is still valid (aka the client didn't leave), and display or not the welcome message.
__________________