[HELP] Command Help
#1

Heloo There i want to make 1 command with
pawn Код:
if(IsPlayerInRangeOfPoint(playerid, 7.0, x, y, z))
but i want to use in diferrent places with diferent action can you tell me how it look because i try and not work please make a exampe like this


pawn Код:
public OnPlayerCommandText(playerid, cmdtext[])
{
if(!strcmp(cmdtext,"/command",true))
{
if(IsPlayerInRangeOfPoint(playerid, 7.0, x,y, z))
{
//First Things Here
}
if(IsPlayerInRangeOfPoint(playerid, 7.0, x,y, z))
{
//Second Thing Here
}
return 1;
}
P.S Sorry Fo My English I Am ROMANIAN
Reply
#2

First To Script Ur English must be good sry for this words
Reply
#3

Just change the coordinates in the second "IsPlayerInRangeOfPoint"
Reply
#4

Quote:
Originally Posted by Jakku
Just change the coordinates in the second "IsPlayerInRangeOfPoint"
I do this man but not work .
I am not so dumb you know.
Reply
#5

try it with the "else" here is the code :
Код:
public OnPlayerCommandText(playerid, cmdtext[])
{
if(!strcmp(cmdtext,"/command",true))
{
if(IsPlayerInRangeOfPoint(playerid, 7.0, x,y, z))
{
//First Things Here
}
else if(IsPlayerInRangeOfPoint(playerid, 7.0, x,y, z))
{
//Second Thing Here
}
return 1;
}
return 0;
}
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)