Problem(error/warning): Kada ocistim chat, zaledi mi se ekran na sekundu?
Dio skripte: [pawn]CMD:cc( playerid, params[], help) {
if( PlayerInfo[ playerid ][ xAdmin ] >= 1 ) {
for( new j; j < 110; j++ ) {
SendClientMessageToAll( -1, "" );
}
new string[128];
if( PlayerInfo[ playerid ][ xAdmin ] == 7 ) { format( string, sizeof( string ), ""col_sanm"Owner "col_white"%s "col_blue"je ocistio chat.", ImeIgraca( playerid ) ); }
else if( PlayerInfo[ playerid ][ xAdmin ] == 6 ) { format( string, sizeof( string ), ""col_sanm"Director "col_white"%s "col_blue"je ocistio chat.", ImeIgraca( playerid ) ); }
else if( PlayerInfo[ playerid ][ xAdmin ] == 5 ) { format( string, sizeof( string ), ""col_sanm"Head Admin "col_white"%s "col_blue"je ocistio chat.", ImeIgraca( playerid ) ); }
else if( PlayerInfo[ playerid ][ xAdmin ] >= 1 && PlayerInfo[ playerid ][ xAdmin ] <= 4 ) { format( string, sizeof( string ), ""col_blue"Admin "col_white"%s "col_sanm"je ocistio chat.", ImeIgraca( playerid ) ); }
else if( PlayerInfo[ playerid ][ xSupporter ] >= 1 ) { format( string, sizeof( string ), ""col_sanm"Supporter "col_white"%s "col_sanm"je ocistio chat.", ImeIgraca( playerid ) ); }
SendClientMessageToAll(-1, string);
SendClientMessageToAll( PHARMELO, "=== www.pharmelo-roleplay.com ===");
}
else return SendErrorMessage( playerid, "Niste ovlasteni za KORISTI ove komande!");
return 1;
}
[/pawn]
Debug iz server_log(ukoliko je u pitanju crashanje servera - crashdetect log): //
Slika/video ingame problema (obavezno ako je ingame problem): //
posalje ti se 100 i nesto praznih poruka u istoj sekundi to treba da se ucita zato ti koci
Sta ce ti 110 poruka...
[pawn]CMD:cc(playerid, params[])
{
if(PlayerInfo[playerid][pAdmin] < 1) return SendClientMessage(playerid, -1, "Niste Admin!");
for(new i; i < 50; i++)// ovaj broj 50 to ti je 50 praznih poruka, ti podesi koliko tebi treba
{
SendClientMessageToAll(0x33FF33FF," ");
}
SendClientMessageToAll(0xFF0000FF,"Chat Ociscen od strane Admin tima. ");
return 1;
}[/pawn]
Hvala, fixano! :D