20.01.2014, 13:39
Hi, I just made this command for my RP server to check if a vehicle have heroin etc inside it or not.
But when I try it out ingame it just say "SERVER:Unknown cmd" and in my whole GM i dont have any line that says so So what's wrong?
But when I try it out ingame it just say "SERVER:Unknown cmd" and in my whole GM i dont have any line that says so So what's wrong?
pawn Код:
if(strcmp(cmd, "/friskcar", true) == 0)
{
if(IsPlayerConnected(playerid))
{
if(IsACop(playerid) && PlayerInfo[playerid][pDuty] == 1)
{
for(new i; i != MAX_VEHICLES; i++)
{
new dist = CheckPlayerDistanceToVehicle(3.5, playerid, i);
if(dist)
{
format(string, sizeof(string), "Materials: %d/%d.", PlayerHaul[i][pMaterials],PlayerHaul[i][pCapasity]);
SCM(playerid, TEAM_GROVE_COLOR, string);
format(string, sizeof(string), "Heroin: %d/%d.", PlayerHaul[i][pHeroin],PlayerHaul[i][pCapasity]);
SCM(playerid, TEAM_GROVE_COLOR, string);
format(string, sizeof(string), "Law Enforcer opens the trunk to see what's inside..");
ProxDetector(20.0, playerid, string, COLOR_RLRPGBLUE,COLOR_RLRPGBLUE,COLOR_RLRPGBLUE,COLOR_RLRPGBLUE,COLOR_RLRPGBLUE);
new engine, lights, alarm, doors, bonnet, boot, objective;
GetVehicleParamsEx(i, engine, lights, alarm, doors, bonnet, boot, objective);
SetVehicleParamsEx(i, engine, lights, alarm, doors, bonnet, 1, objective);
SetTimerEx("CloseBoot", 2000,false,"i",i);
return 1;
}
}
}
}
return 1;
}