So basically in my server when the officer does /loc a checkpoint starts to show were he is and keeps updating. however when i do it now it does not?
PHP код:
CMD:20(playerid, params[])
{
if(PlayerInfo[playerid][pMember] == 1 || PlayerInfo[playerid][pMember] == 2 || PlayerInfo[playerid][pLeader] == 1 || PlayerInfo[playerid][pMember] == 7 || PlayerInfo[playerid][pLeader] == 7 || PlayerInfo[playerid][pMember] == 18 || PlayerInfo[playerid][pLeader] == 18 || PlayerInfo[playerid][pMember] == 19 || PlayerInfo[playerid][pMember] == 20)
{
if ((no20) && EventKernel[EventCreator] != playerid)
{
SendClientMessageEx(playerid, COLOR_GRAD2, " 20s have been disabled for training, start calling your streets!!");
return 1;
}
if (Pursuit[playerid] != 1)
{
new
zone[512],
string[128 + MAX_PLAYER_NAME],
dcount;
GetPlayer3DZone(playerid, zone, sizeof(zone));
foreach(Player, i)
{
if(PlayerInfo[i][pDispatchOn] == 1) dcount ++;
}
if(dcount > 0)
{
new hours, minutes, seconds;
gettime(hours, minutes, seconds);
new nextslot = GetNextSituationSlot();
format(string, sizeof(string), "** DISPATCH-0: Situation %d has been created at the %s **", nextslot, zone);
SendDispatchMessage(string);
format(string, sizeof(string), "** DISPATCH-0: Description of situation: Pursuit In Progress **");
SendDispatchMessage(string);
format(string, sizeof(string), "** DISPATCH-0: Status of the situation is: Code 3 [%d:%d:%d]**", hours, minutes, seconds);
SendDispatchMessage(string);
RecentSituation = nextslot;
CreateDPSituation(nextslot, 3, zone, "Pursuit");
}
new callsign[10];
GetPlayerCallSign(playerid, callsign);
format(string, sizeof(string), "(radio) %s-%d send me additionals, I have an active pursuit!", callsign, PlayerInfo[playerid][pBadgeNum]);
SetPlayerChatBubble(playerid,string,COLOR_WHITE,10.0,5000);
foreach(Player, i)
{
if(PlayerInfo[i][pMember] != 0)
{
PlayAudioStreamForPlayer(i, "http://soundsfree.com/sounds/genbroadcast.mp3");
}
}
format(string, sizeof(string), "** DISPATCH: Pursuit is in progress on behalf of %s-%d (%d), current location is %s. **", callsign, PlayerInfo[playerid][pBadgeNum], playerid, zone);
Pursuit[playerid] = 1;
SendDispatchMessage(string);
SendClientMessageEx(playerid, COLOR_WHITE, "Type /c20 to remove your pursuit.");
SetTimerEx("Update20",3000,1,"i",playerid);
}
else
{
SendClientMessageEx(playerid, COLOR_GREY, " You already have an active backup request!");
}
}
else
{
SendClientMessageEx(playerid, COLOR_GRAD2, " You are not a Cop / FBI / Coastguard!");
}
return 1;
}
public KillAllCopCheckpoint(playerid)
{
foreach(Player, i)
{
if(IsACop(i) || IsALVMPDCop(i))
{
DisablePlayerCheckpoint(i);
}
}
return 1;
}