Raised This Month: $32 Target: $400
 8% 

[REQUEST] Lower time flashed CS 1.6


Post New Thread Reply   
 
Thread Tools Display Modes
Bugsy
AMX Mod X Moderator
Join Date: Feb 2005
Location: NJ, USA
Old 10-10-2021 , 11:42   Re: [REQUEST] Lower time flashed CS 1.6
Reply With Quote #11

What do you have the cvar set to? The plugin uses default flash time DIVIDED by this cvar value to set the duration. So to get the desired time, set it to the appropriate cvar value as outlined below. The creator of this plugin did not implement any error trapping/handling. Ideally the plugin should use the default time if the cvar value is unacceptable.

Standard = 1
Half = 2
Third = 3
Quarter = 4
Etc.
__________________
Bugsy is offline
Rohanlogs
Senior Member
Join Date: Nov 2015
Old 10-18-2021 , 14:54   Re: [REQUEST] Lower time flashed CS 1.6
Reply With Quote #12

Quote:
Originally Posted by talibana View Post
I have that error in logs and server crash when someone throw flashbang.

L 10/08/2021 - 23:26:09: [AMXX] Displaying debug trace (plugin "flashed_duration.amxx", version "0.0.1")
L 10/08/2021 - 23:26:09: [AMXX] Run time error 11: divide
L 10/08/2021 - 23:26:09: [AMXX] [0] flashed_duration.sma::EventBlinded (line 33)
Quote:
Originally Posted by Bugsy View Post
What do you have the cvar set to? The plugin uses default flash time DIVIDED by this cvar value to set the duration. So to get the desired time, set it to the appropriate cvar value as outlined below. The creator of this plugin did not implement any error trapping/handling. Ideally the plugin should use the default time if the cvar value is unacceptable.

Yes, this happens when you divide by 0 (your cvar is set to 0), which I forgot to check.
You can simply fix this by setting the cvar greater than 0. I added a fixed version as well.
__________________
Rohanlogs is offline
kirksite
Member
Join Date: Feb 2021
Old 09-14-2022 , 04:04   Re: [REQUEST] Lower time flashed CS 1.6
Reply With Quote #13

I've successfully installed and tested this plugin and also tested colored_flashbangs (https://forums.alliedmods.net/showth...red+flashbangs)

unfortunately, the flash_duration will not work with the colored_flashbangs. They both are running, no errors showing with debug. Colors will work but the duration is the default. When colors is stopped, duration works.

Could the two be combined?
kirksite is offline
Rohanlogs
Senior Member
Join Date: Nov 2015
Old 04-02-2023 , 09:54   Re: [REQUEST] Lower time flashed CS 1.6
Reply With Quote #14

Quote:
Originally Posted by kirksite View Post
I've successfully installed and tested this plugin and also tested colored_flashbangs (https://forums.alliedmods.net/showth...red+flashbangs)

unfortunately, the flash_duration will not work with the colored_flashbangs. They both are running, no errors showing with debug. Colors will work but the duration is the default. When colors is stopped, duration works.

Could the two be combined?
I realise this was written half a year ago but since people keep coming back to this, here's the combined version.


// Flash mode
// - 0: Plugin OFF
// - 1: Specified colour
// - 2: Random colour
amx_fb_mode 1

// Flash specified colours (Red, Green, Blue)
amx_fb_r 255
amx_fb_g 25
amx_fb_b 25

// Flash time
// Increase to lower time flashed
// Default - 1
amx_flash_multiplier 1

Attached Files
File Type: sma Get Plugin or Get Source (flashed_duration_coloured.sma - 86 views - 2.3 KB)
__________________
Rohanlogs 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 00:16.


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