PlayerToPoint Errors on a new command
#1

Once I add this command to my gamemode I get unlimited "PlayerToPoint" errors o ra lot of lines
Код:
...\gamemodes\breakdownls.pwn(line) : error 004: function "PlayerToPoint" is not implemented
Any ideas what it can be?When I remeve the command it complies like charm.Thanks in advance

Under my variables
pawn Код:
new DragTimer[MAX_PLAYERS];
Under OnPlayerCommandText
pawn Код:
if (strcmp(cmd, "/drag", true) == 0)
    {
      if(gTeam[playerid] == 2 || IsACop(playerid))
        {
          tmp = strtok(cmdtext, idx);
            giveplayerid = strval(tmp);
          if(!strlen(tmp))
            {
                SendClientMessage(playerid, COLOR_GRAD2, "USAGE: /drag [playerid]");
                return 1;
            }
            if(!IsPlayerConnected(giveplayerid))
            {
                format(string, sizeof(string), "%d is not an active player.", giveplayerid);
                SendClientMessage(playerid,COLOR_GREY, string);
                return 1;
            }
            if(GetDistanceBetweenPlayers(playerid,giveplayerid) > 3)
            {
                SendClientMessage(playerid, 0xFF0000AA, "You are too far away from that player.");
            return 1;
            }
            if(giveplayerid == playerid)
            {
                SendClientMessage(playerid, COLOR_RED, "You cannot drag yourself!");
                return 1;
            }
            if(DragTimer[playerid] <= 0)
            {
                if(IsPlayerConnected(giveplayerid) == 1)
                {
                  GetPlayerName(giveplayerid, sendername, sizeof(sendername));
                GetPlayerName(playerid, playername, sizeof(playername));
                  format(string, sizeof(string), "Officer %s started dragging %s", playername, sendername);
                    ProxDetector(30.0, playerid, string, COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE);
                    DragTimer[playerid] = SetTimerEx("Drag", 1000, 1, "ii", playerid, giveplayerid);
                    TogglePlayerControllable(giveplayerid, 0);
                    return 1;
                }
            }
        }
        else
        {
            SendClientMessage(playerid, COLOR_GREY, "  You are not a Cop or an FBI Agent!!");
        }
        return 1;
    }

    if (strcmp(cmd, "/stopdrag", true) == 0)
    {
      tmp = strtok(cmdtext, idx);
        giveplayerid = strval(tmp);
        if(!strlen(tmp))
        {
            SendClientMessage(playerid, COLOR_GRAD2, "USAGE: /stopdrag [playerid]");
            return 1;
        }
      if(gTeam[playerid] == 2 || IsACop(playerid))
        {
            if(DragTimer[playerid] >= 0)
            {
              if(PlayerCuffed[giveplayerid] == 1)
                {
                    TogglePlayerControllable(giveplayerid, 0);
                }
              GetPlayerName(giveplayerid, sendername, sizeof(sendername));
            GetPlayerName(playerid, playername, sizeof(playername));
              format(string, sizeof(string), "Officer %s stopped dragging %s", playername, sendername);
                ProxDetector(30.0, playerid, string, COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE);
                KillTimer(DragTimer[playerid]);
                DragTimer[playerid] = 0;
                TogglePlayerControllable(giveplayerid, 1);
                return 1;
            }
    }
        else
        {
            SendClientMessage(playerid, COLOR_GREY, "  You are not a Cop or an FBI Agent !");
        }
        return 1;
Reply


Messages In This Thread
PlayerToPoint Errors on a new command - by Souvlaki - 12.03.2010, 17:41
Re: PlayerToPoint Errors on a new command - by bilakispa - 12.03.2010, 17:47
Re: PlayerToPoint Errors on a new command - by Souvlaki - 12.03.2010, 17:50
Re: PlayerToPoint Errors on a new command - by bilakispa - 12.03.2010, 17:55
Re: PlayerToPoint Errors on a new command - by Souvlaki - 12.03.2010, 17:58

Forum Jump:


Users browsing this thread: 1 Guest(s)