Raised This Month: $ Target: $400
 0% 

Check - Player is in the air.


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
FromTheFuture
Senior Member
Join Date: Jan 2013
Old 05-07-2013 , 13:28   Check - Player is in the air.
Reply With Quote #1

Hi.
I need to check if the player is in the air one time.
Don't know how to release it.

Think about this:
PHP Code:
pev(idpev_flags) & FL_ONGROUND 
FromTheFuture is offline
ConnorMcLeod
Veteran Member
Join Date: Jul 2006
Location: France (95)
Old 05-07-2013 , 13:44   Re: Check - Player is in the air.
Reply With Quote #2

You may have to use instead :

Code:
const FL_ONGROUND2 = FL_ONGROUND | FL_PARTIALGROUND | FL_INWATER | FL_CONVEYOR | FL_FLOAT
__________________
- tired and retired -

- my plugins -
ConnorMcLeod is offline
FromTheFuture
Senior Member
Join Date: Jan 2013
Old 05-07-2013 , 14:11   Re: Check - Player is in the air.
Reply With Quote #3

I checked so and it work in water too:
PHP Code:
if(!(pev(pIDpev_flags) & FL_ONGROUND))    
{
        
show_dhudmessage(pID"You are is in the Air." )
}
else
{
//in water, on ground, etc..


Last edited by FromTheFuture; 05-07-2013 at 14:13.
FromTheFuture is offline
Old 05-07-2013, 15:07
FromTheFuture
This message has been deleted by ConnorMcLeod. Reason: Read rules https://forums.alliedmods.net/misc.php?do=showrules
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:50.


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