Error -
Chris_Morrison - 26.08.2011
Hi
i did a /exit and i got error
pawn Код:
if(strcmp(cmd, "/exit", true) == 0)
{
if(PlayerToPointStripped(2, playerid,238.5380,139.0598,1003.0234,))
{
SetPlayerPos(playerid,2795.4570,-1619.4171,10.9219)
SetPlayerInterior(playerid, 3);
}
return 1;
}
the error:
C:\Program Files\San Andreas\сшбш\gamemodes\M-RP.pwn(26879) : error 029: invalid expression, assumed zero
The line with the error:
pawn Код:
if(PlayerToPointStripped(2, playerid,238.5380,139.0598,1003.0234,))
Re: Error -
Mustang GT - 26.08.2011
if(PlayerToPointStripped(2, playerid,238.5380,139.0598,1003.0234,))
I see your prbobably gonna get an error here because its simply not complete. It seems that you forgot the final cordinate
Re: Error -
lewismichaelbbc - 26.08.2011
pawn Код:
if(strcmp(cmd, "/exit", true) == 0)
{
if(PlayerToPointStripped(2, playerid,238.5380,139.0598,1003.0234))
{
SetPlayerPos(playerid,2795.4570,-1619.4171,10.9219)
SetPlayerInterior(playerid, 3);
}
return 1;
}
Try that. If it doesnt work, i have another idea.
Re: Error -
lewismichaelbbc - 26.08.2011
pawn Код:
if(IsPlayerInRangeOfPoint(playerid, 2.0, 238.5380,139.0598,1003.0234))
{
SetPlayerPos(playerid,2795.4570,-1619.4171,10.9219)
SetPlayerInterior(playerid, 3);
}
Try that if my above code does not work.
Re: Error -
Kingunit - 26.08.2011
What kind of error. Just 'error' is not enough for us. Why you don't use the code I've placed with IsPlayerInRangeOfPoint. Then you just need to use those parameters
Код:
(playerid, Float:range, Float:x, Float:y, Float:z)
Re: Error -
Mustang GT - 26.08.2011
Quote:
Originally Posted by lewismichaelbbc
pawn Код:
if(strcmp(cmd, "/exit", true) == 0) { if(PlayerToPointStripped(2, playerid,238.5380,139.0598,1003.0234)) { SetPlayerPos(playerid,2795.4570,-1619.4171,10.9219) SetPlayerInterior(playerid, 3); } return 1; }
Try that. If it doesnt work, i have another idea.
|
You should know better than to give an answer with that kind of indentation!
pawn Код:
if(strcmp(cmd, "/exit", true) == 0)
{
if(PlayerToPointStripped(2, playerid,238.5380,139.0598,1003.0234))
{
SetPlayerPos(playerid,2795.4570,-1619.4171,10.9219)
SetPlayerInterior(playerid, 3);
}
return 1;
}
This requires the Angle, The X Float, The Y Float and the Z Float.
You must have those there
Re: Error -
Chris_Morrison - 26.08.2011
3 warnings
C:\Program Files\San Andreas\סרבר\M-RP.pwn(2688
: warning 202: number of arguments does not match definition
C:\Program Files\San Andreas\סרבר\M-RP.pwn(2688
: warning 202: number of arguments does not match definition
C:\Program Files\San Andreas\סרבר\M-RP.pwn(2688
: warning 202: number of arguments does not match definition
Re: Error -
-CaRRoT - 26.08.2011
Quote:
3 warnings
C:\Program Files\San Andreas\סרבר\M-RP.pwn(2688 : warning 202: number of arguments does not match definition
C:\Program Files\San Andreas\סרבר\M-RP.pwn(2688 : warning 202: number of arguments does not match definition
C:\Program Files\San Andreas\סרבר\M-RP.pwn(2688 : warning 202: number of arguments does not match definition
|
Show the code you did and only get X - Y - Z Co-ordinates not the forth one