Raised This Month: $ Target: $400
 0% 

Someone swimming in water?


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
[X]-RayCat
Senior Member
Join Date: Sep 2006
Old 04-15-2007 , 11:19   Someone swimming in water?
Reply With Quote #1

Is it possible somehow detect if someone is 'swimming' at water?
[X]-RayCat is offline
VEN
Veteran Member
Join Date: Jan 2005
Old 04-15-2007 , 11:41   Re: Someone swimming in water?
Reply With Quote #2

Yes. You have to check waterlevel pev value.

Quote:
Originally Posted by HLSDK
// waterlevel 0 - not in water
// waterlevel 1 - feet in water
// waterlevel 2 - waist in water
// waterlevel 3 - head in water
VEN is offline
[X]-RayCat
Senior Member
Join Date: Sep 2006
Old 04-15-2007 , 12:09   Re: Someone swimming in water?
Reply With Quote #3

Quote:
Originally Posted by VEN View Post
Yes. You have to check waterlevel pev value.
How im going to do that? And i need to check if client even touches water.
(so i should take them all except 0?)
[X]-RayCat is offline
VEN
Veteran Member
Join Date: Jan 2005
Old 04-15-2007 , 12:42   Re: Someone swimming in water?
Reply With Quote #4

Quote:
i need to check if client even touches water
So not only swimming?

This will detect the cases when a player is also just stay in water (not only swimming).

With engine module: if (entity_get_int(player, EV_INT_waterlevel))
With fakemeta module: if (pev(player, pev_waterlevel))

If you want to know whether he is exactly swimming you have to perform exactly the same check but for flSwimTime pev value.

Last edited by VEN; 04-15-2007 at 12:55.
VEN is offline
storm007fire
BANNED
Join Date: Apr 2007
Old 04-15-2007 , 13:14   Re: Someone swimming in water?
Reply With Quote #5

psssp : can i send me the code please for my 24/7 server coming son
[X]-RayCat its superhero
storm007fire is offline
[X]-RayCat
Senior Member
Join Date: Sep 2006
Old 04-15-2007 , 13:17   Re: Someone swimming in water?
Reply With Quote #6

Quote:
Originally Posted by storm007fire View Post
psssp : can i send me the code please for my 24/7 server coming son
[X]-RayCat its superhero
What? Thanx VEN i try something. What would you suggest me to use fm or engine i've been using fakemeta in some plugins.
EDIT: Nvm, i use fakemeta because its already included on my plugin. (didnt remember that)

Last edited by [X]-RayCat; 04-15-2007 at 13:28.
[X]-RayCat is offline
storm007fire
BANNED
Join Date: Apr 2007
Old 04-15-2007 , 17:15   Re: Someone swimming in water?
Reply With Quote #7

How come u dont share ur plugins :/
storm007fire is offline
Drak
Veteran Member
Join Date: Jul 2005
Old 04-15-2007 , 18:09   Re: Someone swimming in water?
Reply With Quote #8

How come you can't speak english in you're post above... Which might be obvious why he had no idea what you were talking about.
__________________
Oh yeah
Drak is offline
Send a message via MSN to Drak
[X]-RayCat
Senior Member
Join Date: Sep 2006
Old 04-15-2007 , 18:18   Re: Someone swimming in water?
Reply With Quote #9

Quote:
Originally Posted by SixTwin View Post
How come you can't speak english in you're post above... Which might be obvious why he had no idea what you were talking about.
Correct. I have no idea what you're talking about.
[X]-RayCat 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 06:41.


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