Raised This Month: $ Target: $400
 0% 

is user on air..


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
[X]-RayCat
Senior Member
Join Date: Sep 2006
Old 06-15-2007 , 10:19   is user on air..
Reply With Quote #1

I need to detect if user is on air..
[X]-RayCat is offline
Arkshine
AMX Mod X Plugin Approver
Join Date: Oct 2005
Old 06-15-2007 , 10:48   Re: is user on air..
Reply With Quote #2

Not sure :

Code:
    new flag;     flag = pev( id, pev_flags );         if( !( flag & FL_ONGROUND ) )     {         // [...]     }
__________________
Arkshine is offline
Alka
AMX Mod X Plugin Approver
Join Date: Dec 2006
Location: malloc(null)
Old 06-15-2007 , 10:54   Re: is user on air..
Reply With Quote #3

@arkshine - Is correct.

Hum...but if player is in water is detected like be in air so you must add
Code:
...&& !(flags & FL_INWATER))
__________________
Still...lovin' . Connor noob! Hello
Alka is offline
kmal2t
BANNED
Join Date: Apr 2006
Old 06-15-2007 , 15:44   Re: is user on air..
Reply With Quote #4

I usually use what arkshine put but depending on what you're using you may need the alternative if( (pev(id, pev_flags) & IN_JUMP) ) to get right as they go in air just so you know the other method if you didn't already.
kmal2t is offline
stupok
Veteran Member
Join Date: Feb 2006
Old 06-16-2007 , 00:54   Re: is user on air..
Reply With Quote #5

Quote:
Originally Posted by kmal2t View Post
if( (pev(id, pev_flags) & IN_JUMP) )
This is incorrect. You can check pev_button for IN_JUMP, not pev_flags.
stupok is offline
kmal2t
BANNED
Join Date: Apr 2006
Old 06-17-2007 , 14:33   Re: is user on air..
Reply With Quote #6

errrrg I meant pev_button not flag :X
kmal2t is offline
Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 10:34.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Theme made by Freecode