Problem with this command
#1

I seem to keep misplacing
pawn Код:
return 1;
}
I've tried moving it and I don't know where else to put it lol. The code looks fine to me, anyways I keep getting the warning
Код:
C:\Documents and Settings\Lucas\Desktop\interior.pwn(236) : warning 203: symbol is never used: "enter"
Pawn compiler 3.2.3664	 	 	Copyright © 1997-2006, ITB CompuPhase


1 Warning.
If anyone can give me a good explanation of where to put return 1; I'd be happy. Wiki is kind of hard to understand, anyways thanks.

pawn Код:
COMMAND:enter(playerid, cmdtext)
{
    if (!IsPlayerInRangeOfPoint, 1510.09997559,-1060.19995117,24.29999924 (playerid) return SendClientMessage(playerid, 0xFF0000FF, "You're not near an entrance");
    {
        SetPlayerPos(playerid, 1514.69995117,-1045.09997559,-29.29999924);
        SendClientMessage(playerid, 0xFF0000FF, "You have entered your house!");
    }
    return 1;
}
Reply
#2

Do you have zcmd include?
Reply
#3

Quote:
Originally Posted by =WoR=Varth
Посмотреть сообщение
Do you have zcmd include?
Actually, I forgot to include it lol. Anyways, I just did and compiled. Now I get this crap.
pawn Код:
C:\Documents and Settings\Lucas\Desktop\interior.pwn(239) : error 076: syntax error in the expression, or invalid function call
C:\Documents and Settings\Lucas\Desktop\interior.pwn(239) : warning 215: expression has no effect
C:\Documents and Settings\Lucas\Desktop\interior.pwn(239) : error 001: expected token: ";", but found "return"
C:\Documents and Settings\Lucas\Desktop\interior.pwn(240) : warning 225: unreachable code
Pawn compiler 3.2.3664          Copyright (c) 1997-2006, ITB CompuPhase


2 Errors.
And it's all on the same line for
pawn Код:
if (!IsPlayerInRangeOfPoint, 1510.09997559,-1060.19995117,24.29999924 (playerid) return SendClientMessage(playerid, 0xFF0000FF, "You're not near an entrance");
Reply
#4

pawn Код:
if (!IsPlayerInRangeOfPoint(playerid,10,1510.09997559,-1060.19995117,24.29999924)) return SendClientMessage(playerid, 0xFF0000FF, "You're not near an entrance");
https://sampwiki.blast.hk/wiki/IsPlayerInRangeOfPoint
Reply


Forum Jump:


Users browsing this thread: 2 Guest(s)