// If the value of 'l4d2_RealismFlashLight_Bot_Buff' is 1, what button is used to charge?
// 0 = Shove only, 1 = Shove + Duck.
// -
// Default: "1"
l4d2_RealismFlashlight_Charge_Key "1"
ive done both 0 and 1
Spoiler
HTML Code:
// This file was auto-generated by SourceMod (v1.11.0.6906)
// ConVars for plugin "l4d2_RealismFlashlight.smx"
// Should the survivor robot's flashlight drain battery?
// 1 = Yes, 0 = No
// No matter what this value is set to, survivor bots will never be able to turn on the flashlight while holding a *disallowed weapon*.
// -
// Default: "1"
l4d2_RealismFlashLight_Bot "1"
// If 'l4d2_RealismFlashLight_Bot' has a value of 1, How many server frames must pass before the flashlight power of the survivor robot is consumed by one unit?
// Int Value.
// -
// Default: "4"
l4d2_RealismFlashLight_Bot_Buff "4"
// Enable debug mode?
// 0 = Disabled, 1 = Enabled
// If enabled, If enabled, check chat output when firing.
// -
// Default: "0"
l4d2_RealismFlashLight_Debug "0"
// Enabled This plugin?
// 0 = Disabled, 1 = Enabled
// -
// Default: "1"
l4d2_RealismFlashLight_Enabled "1"
// When the power is lower than a few percent of 'l4d2_RealismFlashLight_PowerMax', the light flashing interval set by 'lv0' is applied
// Percentage, Float Value.
// 0.00 = Disabled.
// -
// Default: "0.8"
l4d2_RealismFlashLight_FlashThreshold_lv0 "0.8"
// The maximum interval between each flash of the flashlight light
// 0.1 Second, Int Value.
// 0 = Disabled, 1 = Enabled.
// -
// Default: "160"
l4d2_RealismFlashLight_FlashThreshold_lv0_Off_Max "160"
// The minimum interval between each flash of the flashlight light
// 0.1 Second, Int Value.
// 0 = Disabled.
// -
// Default: "10"
l4d2_RealismFlashLight_FlashThreshold_lv0_Off_Min "10"
// The slowest time after the flashlight is turned off to turn on automatically.
// 0.1 Second, Int Value.
// 0 = Disabled, 1 = Enabled.
// -
// Default: "6"
l4d2_RealismFlashLight_FlashThreshold_lv0_On_Max "6"
// The fastest time after the flashlight is turned off to turn on automatically.
// 0.1 Second, Int Value.
// 0 = Disabled, 1 = Enabled.
// -
// Default: "1"
l4d2_RealismFlashLight_FlashThreshold_lv0_On_Min "1"
// When the power is lower than a few percent of 'l4d2_RealismFlashLight_PowerMax', the light flashing interval set by 'lv1' is applied
// Percentage, Float Value.
// 0.00 = Disabled.
// -
// Default: "0.30"
l4d2_RealismFlashLight_FlashThreshold_lv1 "0.30"
// The maximum interval between each flash of the flashlight light
// 0.1 Second, Int Value.
// 0 = Disabled, 1 = Enabled.
// -
// Default: "120"
l4d2_RealismFlashLight_FlashThreshold_lv1_Off_Max "120"
// The minimum interval between each flash of the flashlight light
// 0.1 Second, Int Value.
// 0 = Disabled.
// -
// Default: "2"
l4d2_RealismFlashLight_FlashThreshold_lv1_Off_Min "2"
// The slowest time after the flashlight is turned off to turn on automatically.
// 0.1 Second, Int Value.
// 0 = Disabled, 1 = Enabled.
// -
// Default: "12"
l4d2_RealismFlashLight_FlashThreshold_lv1_On_Max "12"
// The fastest time after the flashlight is turned off to turn on automatically.
// 0.1 Second, Int Value.
// 0 = Disabled, 1 = Enabled.
// -
// Default: "1"
l4d2_RealismFlashLight_FlashThreshold_lv1_On_Min "1"
// When the power is lower than a few percent of 'l4d2_RealismFlashLight_PowerMax', the light flashing interval set by 'lv2' is applied
// Percentage, Float Value.
// 0.00 = Disabled.
// -
// Default: "0.00"
l4d2_RealismFlashLight_FlashThreshold_lv2 "0.00"
// The maximum interval between each flash of the flashlight light
// 0.1 Second, Int Value.
// 0 = Disabled, 1 = Enabled.
// -
// Default: "80"
l4d2_RealismFlashLight_FlashThreshold_lv2_Off_Max "80"
// The minimum interval between each flash of the flashlight light
// 0.1 Second, Int Value.
// 0 = Disabled.
// -
// Default: "2"
l4d2_RealismFlashLight_FlashThreshold_lv2_Off_Min "2"
// The slowest time after the flashlight is turned off to turn on automatically.
// 0.1 Second, Int Value.
// 0 = Disabled, 1 = Enabled.
// -
// Default: "14"
l4d2_RealismFlashLight_FlashThreshold_lv2_On_Max "14"
// The fastest time after the flashlight is turned off to turn on automatically.
// 0.1 Second, Int Value.
// 0 = Disabled, 1 = Enabled.
// -
// Default: "1"
l4d2_RealismFlashLight_FlashThreshold_lv2_On_Min "1"
// Enable battery system?
// The flashlight will blink on low battery and disable when the battery is depleted.
// 0 = Disabled, 1 = Enabled
// -
// Default: "0"
l4d2_RealismFlashLight_PowerEnabled "1"
// The maximum flashlight battery level that can be set when the battery is initialized.
// Second, Int Value.
// -
// Default: "400"
l4d2_RealismFlashLight_PowerMax "400"
// The minimum flashlight battery level that can be set when the battery is initialized.
// Second, Int Value.
// -
// Default: "200"
l4d2_RealismFlashLight_PowerMin "200"
// Server Minimum tickrate, reference value for battery timer.
// Int Value
// 0 =Auto, Other Value = Value to Set
// -
// Default: "0"
l4d2_RealismFlashLight_ServerTickrate "0"
// If 'l4d2_RealismFlashLight_PowerEnabled' has a value of 1, Should players be allowed to charge flashlight batteries?
// 0 = No, 1 = Yes
// Survivor bot never recharges flashlight battery.
// -
// Default: "0"
l4d2_RealismFlashlight_Charge "1"
// If the value of 'l4d2_RealismFlashLight_Bot_Buff' is 1, what button is used to charge?
// 0 = Shove only, 1 = Shove + Duck.
// -
// Default: "1"
l4d2_RealismFlashlight_Charge_Key "1"
// If the value of 'l4d2_RealismFlashLight_Bot_Buff' is 1, How much power is charged every time you press it (or hold it every 1.2 seconds)?
// Int Value, Second.
// -
// Default: "1"
l4d2_RealismFlashlight_Charge_Second "30"
1.2.1(Feb-11-2023)
- Fix the problem that the charging function is invalid. Thanks to "sonic155" for report and help tested.
- It is now not possible to charge the battery above 100%.
- New Cvars: l4d2_RealismFlashlight_Charge_Hint, Used to control whether to print a message in the chat box to remind the player when the battery is fully charged.
- Various changes to the code.
hi. is it possible to use the plugin simply for it's block flashlight function? just asking because i've been having issues like not turning flashlight for guns and flashlight still appearing on equipment/melee items. thanks. really cool plugin regardless!
hi. is it possible to use the plugin simply for it's block flashlight function? just asking because i've been having issues like not turning flashlight for guns and flashlight still appearing on equipment/melee items. thanks. really cool plugin regardless!
yes you can do that.
But there are problems with the current plug-in version. In some cases, the plug-in will fail. A new version will be released soon.
1.2.2(Feb-27-2023)
- Fixed: Plugin no longer work after chapter transitions.
- Fixed: Battery levels sometimes had incorrect values when round restarts or map changes.
- Fixed: When changing the value of cvar "l4d2_RealismFlashLight_Bot_Buff" in the game, if the new value is greater than or equal to the old value. The bot's battery will no longer be drained.
- Add plugin native "RealismFlashlight_GetStatus".
Version 1.2.2:
For the "Dynamic Light" and "glare" plugins, it is recommended to use my version, this will avoid the dynamic light created by these two plugins to appear when *flashlight is disabled* Dynamic Light glare
hi. thanks again for the plugin. really enjoying the plugin on my semi-realism server. i use the plugin simply to block flashlight use on equipment (grenade, pills, medkit) since they're more powerful than pistols on my ci-heavy server.
i was just wondering - if you switch from gun w/ flashlight turned on, to an equipment item and then back to the gun, the flashlight will turn itself off. can you save the state of the flashlight on the gun so that it turns itself back on when switching back from an equipment item or is it not possible?
1.2.4 (Nov-19-2023)
- Add Cvar: "l4d2_RealismFlashlight_AutoFlashlight", When switching from a weapon without a flashlight to a weapon with a flashlight, if the flashlight was previously in the ON state, it will automatically be restored. Requested by "Automage" And "swiftswing1'.