12.09.2010, 19:35
ok, so you would do this:
except it follows the person who typed the command, not another closest person
can someone fix this for me?
where it follows the most closest person, excluding the person who typed the command
thx
pawn Код:
if(!strcmp(cmdtext, "/bam", true))
{
SetPVarInt(playerid,"launcher",1);
for(new i = 0; i < MAX_PLAYERS; i++)
if(i!=playerid)
{
{
GetPlayerPos(playerid,Xp, Yp,Zp);
GetPlayerPos(i,Xt, Yt,Zt);
if(IsPlayerInRangeOfPoint(i,TargetRange,Xp, Yp,Zp))
{
Vrocket[playerid] = CreateObject(ROCKETOBJECT, Xp, Yp,Zp+5,0.0,0.0,0.0,5.0); //
MoveObject(Vrocket[playerid], Xt, Yt, Zt, ROCKETSPEED);
}
can someone fix this for me?
where it follows the most closest person, excluding the person who typed the command
thx
![Cheesy](images/smilies/biggrin.png)