23.06.2011, 09:40
pawn Код:
new NoSpam[(300+200)]; // at the top of the script
if(GetPlayerScore(playerid) ==1000 && NoSpam[playerid] == 0)
{
new str[128], Pname[24];
GetPlayerName(playerid, Pname, 24);
format(str, sizeof(str), "News: %s Has been promoted to a General of the Army", Pname);
SendClientMessageToAll(COLOR_RED,str);
NoSpam[playerid] = 1;
return 1;
}
else if(GetPlayerScore(playerid) ==500 && NoSpam[playerid] == 0)//level 12
{
new str[128], Pname[24];
GetPlayerName(playerid, Pname, 24);
format(str, sizeof(str), "News: %s Has been promoted to a General", Pname);
SendClientMessageToAll(COLOR_DARKRED,str);
NoSpam[playerid] = 1;
return 1;
}
if(GetPlayerScore(playerid) ==300 && NoSpam[playerid] == 0)//level 11
{
new str[128], Pname[24];
GetPlayerName(playerid, Pname, 24);
format(str, sizeof(str), "News: %s Has been promoted to a Major General", Pname);
SendClientMessageToAll(COLOR_DARKRED,str);
NoSpam[playerid] = 1;
return 1;
}
else if(GetPlayerScore(playerid) ==250)//level 9
{
new str[128], Pname[24];
GetPlayerName(playerid, Pname, 24);
format(str, sizeof(str), "News: %s Has been promoted to a Lieutenant General", Pname);
SendClientMessageToAll(COLOR_DARKRED,str);
NoSpam[playerid] = 1;
return 1;
}
if(GetPlayerScore(playerid) ==190 && NoSpam[playerid] == 0)//level 8
{
new str[128], Pname[24];
GetPlayerName(playerid, Pname, 24);
format(str, sizeof(str), "News: %s Has been promoted to a Lieutenant Colonel", Pname);
SendClientMessageToAll(COLOR_RED,str);
NoSpam[playerid] = 1;
return 1;
}
else if(GetPlayerScore(playerid) ==150 && NoSpam[playerid] == 0)//level 7
{
new str[128], Pname[24];
GetPlayerName(playerid, Pname, 24);
format(str, sizeof(str), "News: %s Has been promoted to a Colonel", Pname);
SendClientMessageToAll(COLOR_RED,str);
NoSpam[playerid] = 1;
return 1;
}
if(GetPlayerScore(playerid) ==110 && NoSpam[playerid] == 0)//level 6
{
new str[128], Pname[24];
GetPlayerName(playerid, Pname, 24);
format(str, sizeof(str), "News: %s Has been promoted to a Major", Pname);
SendClientMessageToAll(COLOR_RED,str);
NoSpam[playerid] = 1;
return 1;
}
else if(GetPlayerScore(playerid) ==80 && NoSpam[playerid] == 0)//level 5
{
new str[128], Pname[24];
GetPlayerName(playerid, Pname, 24);
format(str, sizeof(str), "News: %s Has been promoted to a Captain", Pname);
SendClientMessageToAll(COLOR_RED,str);
NoSpam[playerid] = 1;
return 1;
}
if(GetPlayerScore(playerid) ==65 && NoSpam[playerid] == 0)//level 4
{
new str[128], Pname[24];
GetPlayerName(playerid, Pname, 24);
format(str, sizeof(str), "News: %s Has been promoted to a Lieutenant", Pname);
SendClientMessageToAll(COLOR_RED,str);
NoSpam[playerid] = 1;
return 1;
}
else if(GetPlayerScore(playerid) ==45 && NoSpam[playerid] == 0)//level 3
{
new str[128], Pname[24];
GetPlayerName(playerid, Pname, 24);
format(str, sizeof(str), "News: %s Has been promoted to a Sergeant", Pname);
SendClientMessageToAll(COLOR_RED,str);
NoSpam[playerid] = 1;
return 1;
}
if(GetPlayerScore(playerid) ==25 && NoSpam[playerid] == 0)// level 2
{
new str[128], Pname[24];
GetPlayerName(playerid, Pname, 24);
format(str, sizeof(str), "News: %s Has been promoted to a Corporal", Pname);
SendClientMessageToAll(COLOR_RED,str);
NoSpam[playerid] = 1;
return 1;
}