Something wrong and i don't know what... Help plz
#1

Hey guys... I am just trying to do something but not working!
This give me errors...
Код:
C:\Users\Ricardo\Desktop\Mini-DM\Mini-DM\Freedoom\filterscripts\copsystem.pwn(20) : error 036: empty statement
C:\Users\Ricardo\Desktop\Mini-DM\Mini-DM\Freedoom\filterscripts\copsystem.pwn(26) : warning 225: unreachable code
C:\Users\Ricardo\Desktop\Mini-DM\Mini-DM\Freedoom\filterscripts\copsystem.pwn(26) : error 029: invalid expression, assumed zero
C:\Users\Ricardo\Desktop\Mini-DM\Mini-DM\Freedoom\filterscripts\copsystem.pwn(26) : warning 215: expression has no effect
C:\Users\Ricardo\Desktop\Mini-DM\Mini-DM\Freedoom\filterscripts\copsystem.pwn(26) : error 001: expected token: ";", but found "return"
Pawn compiler 3.2.3664	 	 	Copyright © 1997-2006, ITB CompuPhase


3 Errors.
pawn Код:
COMMAND:duty(playerid, params[])
{
    if(IsPlayerConnected(playerid))
    {
        if(IsPlayerInRangeOfPoint(playerid, 2.0, 1555.097900, -1675.848754, 16.195312));
        {
            SetPlayerColor(playerid, 0x0259EAAA);
            SendClientMessage(playerid, 0x0259EAAA, "You Are Now A Cop, Use /equip To Get Weapons.");
            return 1;
        }
        else return SendClientMessage(playerid, 0x0259EAAA, "You Are Not In LSPD Entrance.");
    }
    else return SendClientMessage(playerid, 0x0259EAAA, "Player Is Not Online");
}
THANKS
Reply
#2

pawn Код:
if(IsPlayerInRangeOfPoint(playerid, 2.0, 1555.097900, -1675.848754, 16.195312));
must be
pawn Код:
if(IsPlayerInRangeOfPoint(playerid, 2.0, 1555.097900, -1675.848754, 16.195312))
You had ';' after it (I don't know the English name)

** Getplayer pos and check if he's inrange

pawn Код:
new Float:pos[3];
GetPlayerPos(playerid, pos[0], pos[1], pos[2]); //Change 'playerid' for the target
if(IsPlayerInRangeOfPoint(playerid, RANGE, pos[0], pos[1], pos[2])){
    //Script
}
else{
    // Not in range
}
Reply
#3

Thanks man!
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)