30.05.2009, 16:07
The script doesn't work...everything inside the checks in the menu (i.e the SWAT level checks) aren't working and I don't know why...
This is the script:
P.S indentations on my screen are fine
This is the script:
P.S indentations on my screen are fine
pawn Код:
public OnPlayerSpawn(playerid)
{
SAPDlevel[playerid] = 1;
SWATlevel[playerid] = 1;
FBIlevel[playerid] = 1;
}
pawn Код:
if(CurrentMenu == SWATmenu)
{
switch(row)
{
case 0: // SWAT Uniforms
{
playeronduty[playerid] = 1;
SetPlayerSkin(playerid,285);
SetPlayerColor(playerid,COLOR_BLUE);
if(SWATlevel[playerid] == 1) // SWAT Cadet
{
GivePlayerWeapon(playerid,3,0);
GivePlayerWeapon(playerid,24,300);
GivePlayerWeapon(playerid,41,500);
SendClientMessage(playerid,COLOR_CYAN,"You have gone on duty as a SWAT cadet");
return 1;
}
else if(SWATlevel[playerid] == 2) // SWAT Member
{
GivePlayerWeapon(playerid,3,0);
GivePlayerWeapon(playerid,24,300);
GivePlayerWeapon(playerid,41,500);
GivePlayerWeapon(playerid,27,500);
GivePlayerWeapon(playerid,29,1000);
SendClientMessage(playerid,COLOR_CYAN,"You have gone on duty as a SWAT member");
return 1;
}
else if(SWATlevel[playerid] == 3) // SWAT Commander
{
GivePlayerWeapon(playerid,3,0);
GivePlayerWeapon(playerid,24,300);
GivePlayerWeapon(playerid,41,500);
GivePlayerWeapon(playerid,27,500);
GivePlayerWeapon(playerid,29,1000);
GivePlayerWeapon(playerid,31,2000);
SendClientMessage(playerid,COLOR_CYAN,"You have gone on duty as a commander");
return 1;
}
}
case 1: // SAPD Uniforms
{
ShowMenuForPlayer(SAPDmenu,playerid);
return 1;
}
}
}