Command not working properly
#1

Well I have this command
pawn Код:
if (strcmp("/stealbounty", cmdtext, true) == 0)
    {
        if (!IsPlayerInRangeOfPoint(playerid,30,-1371, 1495, 1)) return SendClientMessage(playerid,COLOR_RED,"ERROR: You are not at the cargo ship!");
        if (!IsPlayerInRangeOfPoint(playerid,30,-2475, 1546, 33)) return SendClientMessage(playerid,COLOR_RED,"ERROR: You are not at the cargo ship!");
        if (PlayerTeam[playerid] != TEAM_PIRATES) return SendClientMessage(playerid,COLOR_RED,"ERROR: You don't have enough knowledge and tools to do this!");
        if (ShipIsBeingTaken == 1) return SendClientMessage(playerid,COLOR_RED,"ERROR: Someone is already trying to take the cargo ship!");
        if (BountyRecentlyStolen == 1) return SendClientMessage(playerid,COLOR_RED,"ERROR: The bounty has recentled being stolen.");
        SendClientMessageToAll(COLOR_BROWN,"INFO: The pirates are taking over the cargoship and will succed in 30 seconds!");
        ShipTimer = SetTimer("ShipTakenSec",1200,1);
        SetTimer("BountyCoolDown",600000,0);
        return 1;
    }
But it will always says 'You are not at the cargo ship!' even if im in it.
Reply
#2

Because the position are not a float?
And, you sure if the position are correct?
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)