message player in range of point -
cssbart - 01.08.2012
message player in range of point
is there such command for this or work around
Respuesta: message player in range of point -
HarlemSAMP - 01.08.2012
If you want to just make a cmd or a text using IsPlayerInRangeOfPoint, yes you can set up the coords where you want the cmd to be working, maybe like /help, if it's not what you're asking be more descriptive.
EDIT: not sure if you asking for a example of IsPlayerInRangeOfPoint, but here an example:
pawn Код:
CMD:help(playerid, params[])
{
if(IsPlayerInRangeOfPoint(playerid, x y z)
ShowPlayerDialog(playerid, yourdialogid, DIALOG_STYLE_LIST, "Help Menu", "BlahBla", "Ok", "Cancel";)
GivePlayerPenis(playerid, blowjob);
return 1;
}
Re: message player in range of point -
cssbart - 01.08.2012
no so you do /countdown and then only players in range of the start line get the count down in there chat
Re: message player in range of point -
Ranama - 01.08.2012
you get the point of where the start line is, then you loop through all players and see if the player is in range of that point, if they are you'll send them a message, that's how easy it is
Re: message player in range of point -
cssbart - 01.08.2012
how would i do this i know hot to sentmessageclient and IsPlayerInRangeOfPoint but i dont know how to do a loop
Re: message player in range of point -
Ranama - 01.08.2012
you will do a loop like this
Код:
for(new i = 0; i<MAX_PLAYERS; i++){//this will loop until i is bigger then max players and after each loop i will be one more
if(IsPlayerInRangeOfPoint(i, 50.0, x, y ,z){//instead of playerid you type i because the current playerid is i
SendClientMessage(i, COLOR_WHITE, "You hear the signal to start the race (change it as you want)");//send the mesage to the player with id i here to
}
}
//this is how you make everybody near the point hear it, but if you want it to countdown you'll have to set a timer for every second and then kill it when it have counted done.
SetTimer
Hope you understand
Re: message player in range of point -
cssbart - 01.08.2012
i understand but could you do it so it started a timer for that player which would be i