Flashbang Duration
I am trying to get the duration and hold time so I can find out how long they are flashed for and at what level. I am guessing hold time is how long it will stay at the intensity it originally flashed at, and that the duration is the total length that your screen will be 'faded'. My only problem is that I am getting some strange numbers for the duration and the hold time.
Something along the lines of Duration:1000-2400, Hold Time:600-1300 I don't think its in ms, because i don't remember ever being flashed for 24 sec, or even 13 for that matter... any help as to what these numbers are displayed as? ive looked into a couple other plugins and scanned the forums but for the most part people just alter the colors when hooking this event. PHP Code:
|
Re: Flashbang Duration
1 second = (1 << 12 ) = 4096 units
|
Re: Flashbang Duration
Quote:
|
Re: Flashbang Duration
Holdtime and Duration are just in special units. All I know. 4096 because is the same value as 1 << 12. ( 2^12 = 4096 )
|
Re: Flashbang Duration
um.. im not good with this byte stuff. can someone tell me why it works like this? 4096 = 1 sec?. so.. if i take the value of the duration or hold time and divide it by 4096 i can get time in seconds?
im planning on setting the value i get from here to a task so that i can accurately find out when the flash ends. but i can't really set a task using the value i am getting. |
Re: Flashbang Duration
You can also use player offsets :
514 - fGametime flashed until ? 515 - fGametime flashed at ? http://forums.alliedmods.net/showthread.php?t=68113 |
Re: Flashbang Duration
Quote:
http://wiki.amxmodx.org/Half-Life_1_...nts#ScreenFade @sgtbane: I think this would work: Code:
|
Re: Flashbang Duration
Code:
#define seconds_to_screenfade_units(%1) clamp(%1<<12, 0, 0xFFFF) |
Re: Flashbang Duration
Quote:
|
Re: Flashbang Duration
Ask Valve :p
|
| All times are GMT -4. The time now is 17:01. |
Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.