15.03.2012, 23:08
Hi.
Today i've made something for my server but failed.
Could you tell me what is wrong with this code?
Integrers from variable DPoints won't save and my database looks like this:
It doesen't save anything, not even iUID or name..
Today i've made something for my server but failed.
Could you tell me what is wrong with this code?
Код:
new DPoints[ MAX_PLAYERS ]; public OnFilterScriptInit( ) { BUD::Setting( opt.Database, "UserPoints.db" ); BUD::Setting( opt.Asynchronous, true ); BUD::Setting( opt.KeepAliveTime, 3000 ); BUD::Setting( opt.CheckForUpdates, false ); BUD::Initialize( ); BUD::VerifyColumn( "Drift_Points", BUD::TYPE_NUMBER ); return 1; } public OnFilterScriptExit( ) { BUD::Exit( ); return 1; } public OnPlayerConnect( playerid ) { new iUID = BUD::GetNameUID( GetName( playerid ) ), _d_points ; BUD::MultiGet( iUID, "i", "Drift_Points", _d_points ); DPoints[ playerid ] = _d_points; return 1; } public OnPlayerDisconnect( playerid, reason ) { new iUID = BUD::GetNameUID( GetName( playerid ) ), _d_r_points = DPoints[ playerid ] ; BUD::MultiSet( iUID, "i", "Drift_Points", _d_r_points ); return 1; }
It doesen't save anything, not even iUID or name..