04.03.2015, 18:07
Hello
Help i get this error , when i compile mod
i get this error :
line 29575
Code
https://sampforum.blast.hk/showthread.php?tid=566255
Help i get this error , when i compile mod
i get this error :
Код:
***********(29575) : error 029: invalid expression, assumed zero
pawn Код:
else
pawn Код:
CMD:duty(playerid, params[])
{
new group = playerVariables[playerid][pGroup];
if(groupVariables[group][gGroupType] == 1)
if(GetPVarInt(playerid,"AntiFlood") > gettime()){ SendClientMessage(playerid, 0xFFD5BBAA, "Do Not Spam!"); return false; }
SetPVarInt(playerid,"AntiFlood",gettime() + 1);
{
for(new x = 0; x < MAX_GROUPS; x++)
{
if(IsAtDuty(playerid) || IsPlayerInRangeOfPoint(playerid, 100.0, groupVariables[x][gGroupInteriorPos][0], groupVariables[x][gGroupInteriorPos][1], groupVariables[x][gGroupInteriorPos][2]) && GetPlayerVirtualWorld(playerid) == GROUP_VIRTUAL_WORLD+x)
{
GetPlayerName(playerid, szPlayerName, MAX_PLAYER_NAME);
if(playerVariables[playerid][pPoliceDuty] == 0)
{
playerVariables[playerid][pPoliceDuty] = 1;
format(szMessage, sizeof(szMessage), "%s took his equipment out of his locker.", szPlayerName);
nearByMessage(playerid, COLOR_PURPLE, szMessage, 10.0);
givePlayerValidWeapon(playerid, 24);
givePlayerValidWeapon(playerid, 31);
givePlayerValidWeapon(playerid, 29);
givePlayerValidWeapon(playerid, 41);
playerVariables[playerid][pArmour] = 100;
playerVariables[playerid][pHealth] = 100;
SetPlayerArmour(playerid, playerVariables[playerid][pArmour]);
SetPlayerHealth(playerid, playerVariables[playerid][pHealth]);
}
else
{
playerVariables[playerid][pPoliceDuty] = 0;
format(szMessage, sizeof(szMessage), "%s put his equipment in his locker.", szPlayerName);
nearByMessage(playerid, COLOR_PURPLE, szMessage, 10.0);
validResetPlayerWeapons(playerid);
playerVariables[playerid][pArmour] = 0;
playerVariables[playerid][pHealth] = 100;
SetPlayerArmour(playerid, playerVariables[playerid][pArmour]);
SetPlayerHealth(playerid, playerVariables[playerid][pHealth]);
}
}
else
{
SCM(playerid, COLOR_GREY, "You need to be in your HQ!");
}
}
else
{
SCM(playerid, COLOR_GREY, "You are not a cop!");
}
}
return 1;
}