19.08.2011, 20:21
If i restart the server while some players are online, their stats are fucked up on the next spawn! What could cause this?
public OnGameModeExit( )
{
for( new i = 0; i < MAX_PLAYERS; i++ )
{
if( IsPlayerConnected( i ) ) OnPlayerDisconnect( i, 2 );
}
return 1;
}
public OnGameModeExit( )
{
for( new i = 0; i < MAX_PLAYERS; i++ )
{
if( IsPlayerConnected( i ) ) OnPlayerDisconnect( i, 2 );
}
return 1;
}
You are probably not saving player stats under the OnGameModeExit callback. You could either port all the saving information to that callback, under a loop, or have it call OnPlayerDisconnect for each connected player at the time.
pawn Код:
|
The code above won't work (no such thing as playerid stated there)
pawn Код:
|