Taken from
amxmodx.inc:
Code:
/* Called on client connection. */
forward client_connect(id);
/* Called when client gets valid STEAM id (usually
* between client_connect() and client_putinserver()). */
forward client_authorized(id);
/* Called when client is disconnecting from server. */
forward client_disconnect(id);
/* Called when client is entering to a game. */
forward client_putinserver(id);
I would suggest
client_putinserver() since I don't know when the player's name is actually accessible. I think you should use steamids instead of names, though.
You can use
set_task to execute a function after some period of time, yes.
Something like:
Code:
set_task(300.0, "function")