28.04.2013, 12:20
Okay,so firstly there must be a place you create your timer. Player spawn etc. Or connect.
You didn't tell if it's a global timer or not,so I assume it's a timer stored per player? If not,tell me.
What you must do is this:
Then,you must put this under OnPlayerDisconnect.
You didn't tell if it's a global timer or not,so I assume it's a timer stored per player? If not,tell me.
What you must do is this:
pawn Код:
new StatSaverTimer[MAX_PLAYERS]; // MAX_PLAYERS must be defined.
Wherever your Timer starts,you must do this:
StatSaverTimer[playerid] = SetTimerEx(....); // so this is where your timer starts.
pawn Код:
KillTimer(StatSaverTimer[playerid]); // kill the timer,so it will stop counting