Check if player is at X height?
#10

Quote:
Originally Posted by Abernethy♥
Quote:
Originally Posted by Memoryz
Quote:
Originally Posted by Abernethy♥
AddPlayerClass(170,535.2068,-2101.1238,-0.6810,279.2928,0,0,0,0,0,0);

The bold is the height, btw Calgon. You were checking the X not the Z.
Thanks,

Now one more thing, how do I check if the player is between -0.5448 and -0.8659?
Well there is a way, I've seen it with moving gates although I can't remember. This code will check if they're below -0.8659.
pawn Код:
public OnPlayerUpdate(playerid)
{
    new Float:X, Float:Y, Float:Z;
    GetPlayerPos(playerid, Float:X, Float:Y, Float:Z);
    if (Float:Z <= -0.8659)
    {
      // effect
    }
    return true;
}
Nice!

This is exactly what I was looking for!

Thanks =)

Just one last little thing, Im guessing this will cause a little lag...?
Reply


Messages In This Thread
Check if player is at X height? - by Memoryz - 08.10.2009, 22:32
Re: Check if player is at X height? - by Calgon - 08.10.2009, 22:36
Re: Check if player is at X height? - by Memoryz - 08.10.2009, 22:38
Re: Check if player is at X height? - by Calgon - 08.10.2009, 22:49
Re: Check if player is at X height? - by Memoryz - 08.10.2009, 22:58
Re: Check if player is at X height? - by Memoryz - 08.10.2009, 23:04
Re: Check if player is at X height? - by Abernethy - 08.10.2009, 23:05
Re: Check if player is at X height? - by Memoryz - 08.10.2009, 23:16
Re: Check if player is at X height? - by Abernethy - 08.10.2009, 23:21
Re: Check if player is at X height? - by Memoryz - 09.10.2009, 00:15

Forum Jump:


Users browsing this thread: 1 Guest(s)