how make if you not on checkpoint u cnt use a command?
#1

i trying to make if player is not in check point the cant do /cigars
PHP код:
cmd(cigars21playeridparams[])
{
    if(
IsPlayerInRangeOfPoint(playerid3.02695.6880, -1704.630011.8438))
    if else { 
SendClientMessage(playerid,0xFFFFFFFF,"You are near the stadium entrance!");
    return 
1;
    }
        return 
1;

but keep getting this problem

PHP код:
C:\Users\yahaira\Desktop\CNR 0.3X\gamemodes\1.2.pwn(4928) : error 029invalid expressionassumed zero
Pawn compiler 3.2.3664              Copyright 
(c1997-2006ITB CompuPhase
1 Error

Reply
#2

it's not
Код:
if else
It is
Код:
else if
Reply
#3

pawn Код:
cmd(cigars21, playerid, params[])
{
    if(!IsPlayerInRangeOfPoint(playerid, 3.0, 2695.6880, -1704.6300, 11.8438)) return SendClientMessage(playerid,0xFFFFFFFF,"You are near the stadium entrance!");
    return 1;
}
Reply
#4

Quote:
Originally Posted by DeMoX
Посмотреть сообщение
it's not
Код:
if else
It is
Код:
else if
Quote:
Originally Posted by park4bmx
Посмотреть сообщение
pawn Код:
cmd(cigars21, playerid, params[])
{
    if(!IsPlayerInRangeOfPoint(playerid, 3.0, 2695.6880, -1704.6300, 11.8438)) return SendClientMessage(playerid,0xFFFFFFFF,"You are near the stadium entrance!");
    return 1;
}
Thanks alot both works and i going give u thanks positive feed back really helped alot
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)