Garry's Mod

Garry's Mod

862 ratings
IFL - CLIENTSIDE Improved Flashlight
3
2
   
Award
Favorite
Favorited
Unfavorite
Content Type: Addon
Addon Type: Effects
Addon Tags: Realism
File Size
Posted
Updated
22.575 KB
4 Feb @ 9:18pm
21 Feb @ 1:32am
5 Change Notes ( view )

Subscribe to download
IFL - CLIENTSIDE Improved Flashlight

Description
A fully clientside improved flashlight system.

Built around singleplayer.

Allows you to fully customize the flashlight, attach it to your weapon (first and third person!) and enable aesthetics like flickering and chances for the flashlight to turn off when taking damage.

Pretty optimized and its made work with many different weapons and situations. Also has a cool sway effect when not attached to weapon in first person.

Also respects mp_flashlight ConVar!





----------------------------------------------------------------

ConVars:

IFL_flashlight 1/0 - Enable/Disable IFL flashlight.
IFL_flashlight_flicker 1/0 - Enable/Disable flashlight flickering effects.
IFL_flashlight_weapon 1/0 Use weapon (worldmodel and viewmodel) muzzle attachment for flashlight, if available.
IFL_flashlight_color (R G B) Set flashlight color, seperated by spaces.
IFL_flashlight_brightness (VALUE) - Set flashlight brightness.
IFL_flashlight_fov (VALUE) - Set flashlight fov.
IFL_flashlight_texture (NAME) - Sets flashlight texture.
IFL_flashlight_farz (VALUE) - Set flashlight farz (distance).
IFL_flashlight_nearz (VALUE) - Set flashlight nearz (cutoff). This is helpful for self shadowing on PM’s or weapons.
IFL_flashlight_swayfactor (VALUE) - Set flashlight sway factor (how fast it sways).
IFL_flashlight_ondamage 1/0 - Sets if flashlight should have a chance to turn off on damage.
IFL_flashlight_sprite 1/0 - Sets if flashlight (if IFL_flashlight_weapon 1) should draw a sprite.
IFL_flashlight_pushback 1/0 - Sets if flashlight should be pushed backwards near a wall.

IFL_flashlight_flicker_freq (VALUE) - Sets how rare flickering is.
IFL_flashlight_flicker_int (VALUE) - Sets how intense flickering is.

IFL_flashlight_Blacklist_Add (Path/MODELNAME.mdl) - Adds model to blacklist.
IFL_flashlight_Blacklist_Remove (Path/MODELNAME.mdl) - Removes model from blacklist.

IFL_GetWorldModel - Gets players worldmodel name (thirdperson).
IFL_GetViewModel - Gets players viewmodel name (firstperson).

----------------------------------------------------------------

This was my favorite addon to make so far- enjoy!

If a weapon has incorrect attachment angles or shouldn’t attach (some crowbar replacements do this) then you can blacklist them using the commands above!

Possible future updates planned:

-Multiplayer support
146 Comments
Rodrigga 11 Jul @ 2:04am 
grrr :steamsad:
Jiyū to anzen  [author] 9 Jul @ 11:26pm 
Also, for the multiplayer update, this addon will not be fully clientside anymore- I will be changing some hooks to serverside ones that are better and might add some more compatibility. No telling when I'll be done with it though
Jiyū to anzen  [author] 9 Jul @ 11:23pm 
@RapidFire57821 Have not tested yet, but assuming they use have proper muzzle attachments then yes.
RapidFire57821 5 Jul @ 10:01am 
does this work on custom weapons like arc9?
PLZ multiplayer Support
:steamthumbsup:
Rodrigga 27 Jun @ 6:15am 
:steamsad:
Rodrigga 27 Jun @ 6:15am 
make it multiplayer!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!1111111111111!!!!!!!!!!!
mangoz23 25 Jun @ 4:28pm 
can you add support for acr9 weapons?
dobert 20 Jun @ 7:11am 
Thanks for the cool plugin. If you ever get around to it, a multiplayer support feature would be awesome.
Elliot-_- 8 Jun @ 3:35pm 
It does what it's supposed to do but it doesn't work with Alyx in Ep1 campaign