AlliedModders

AlliedModders (https://forums.alliedmods.net/index.php)
-   Scripting Help (https://forums.alliedmods.net/forumdisplay.php?f=11)
-   -   Detect entity in water (https://forums.alliedmods.net/showthread.php?t=245834)

RateX 08-07-2014 14:09

Detect entity in water
 
Like the title said, I want to know how to detech any entity if it in water or not.
Please help
Thanks:)

NikKOo31 08-07-2014 14:33

Re: Detech entity in water
 
https://forums.alliedmods.net/showthread.php?t=79335

RateX 08-08-2014 01:11

Re: Detech entity in water
 
Tested in as_oilrig. The code only works for player:(

meTaLiCroSS 08-08-2014 02:27

Re: Detech entity in water
 
Play with pev_waterlevel. I checked SmokeGrenade's decompiled code and it check if it's underwater with the waterlevel entvar :mrgreen:

RateX 08-08-2014 06:22

Re: Detech entity in water
 
Quote:

Originally Posted by meTaLiCroSS (Post 2180782)
Play with pev_waterlevel. I checked SmokeGrenade's decompiled code and it check if it's underwater with the waterlevel entvar :mrgreen:

Surprisingly, it works. Thanks meTaLiCroSS:)
Kinda weird 'cause it only return value 0 and 3. Guess the other values are only for player:)


All times are GMT -4. The time now is 12:55.

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