Garry's Mod

Garry's Mod

790 betyg
Sniper Glint
3
2
   
Utmärkelse
Favorit
Favoritmarkerad
Avfavoritmarkerad
Content Type: Addon
Addon Type: Tool
Addon Tags: Fun, Realism
Filstorlek
Lades upp
Uppdaterades
3.496 KB
24 apr, 2020 @ 21:32
2 feb, 2023 @ 20:21
4 ändringsnotiser ( visa )

Abonnera för att ladda ner
Sniper Glint

I 1 samling av SweptThr.one
SweptThrone Catalogue
135 artiklar
Beskrivning
See where you're about to get sniped from.

//

Tired of dying to snipers you can't even see? Tired of your super serious military roleplay server not being realistic enough? Sniper Glint can fix that!

Sniper Glint is a very simple addon that adds a scope glint effect to most common weapons. Just install it on your server or game, and it's ready to go!

While this addon works out-of-the-box, you may find some things that don't quite look exactly how you want to. I've tried to include some ConVars to help you tweak it to your heart's content.
sv_st_glint_mindist - Minimum distance the glint will be drawn. Requires restart. Default 400
sv_st_glint_maxsize - Maximum size of the glint. Default 1000
sv_st_glint_minsize - Minimum size of the glint. Default 0
sv_st_glint_sizedivisor - An arbitrary value controlling how big the glint is. Lower makes it bigger. Default 75000

Support summary:
TFA Base - Supported if the weapon is scoped, but also works generally as long as the right mouse button is held.
M9K Base - Supported if the weapon is scoped.
FA:S2 Base - Supported if the weapon has a scope by default. Attached scopes will not work.
CW2.0 Base - Supported if the weapon has a scope by default. Attached scopes will not work.
Any other base - Supported if SWEP.CustomShouldGlint is true and SWEP:CustomGlintFunc() returns true.
ArcCW - Has its own version, so if you use this addon with it, this won't do anything.
TTT Base - Unsupported because there's no way to tell the difference between a scoped and non-scoped weapon.
ACT3/ASTW/ArcVR/Arc9/Arc10/etc. Base - Not supported
HL2 Crossbow - Not supported
TFA AT - Not supported
MW Base - Not supported

I made this because I took a week off and wanted to do something.

This should work in all gamemodes as long as the base is supported.


[sweptthr.one]

Credits:
Me - All of the code
142 kommentarer
Unaverage Joe. 22 apr @ 23:26 
No idea if this addon is still updated but wgetjane discovered this a while back.

Most scoped/zoom weapons in TTT will utilize the wep.SetZoom() function, if you could check for:
wep.GetIronsights (player is ADSing),
wep.SetZoom (weapon is able to zoom in),
ply:GetFOV (weapon has high enough magification),
you can somewhat decently check if a TTT weapon has a scope.

Here's what I've used: wep.Base == "weapon_tttbase" and ( wep.GetIronsights and wep:GetIronsights() and (wep.SetZoom and ply:GetFOV() <= 20))
unlikeaboss 24 dec, 2024 @ 8:32 
is tac-rp compatable?
oneshot:) 29 dec, 2023 @ 17:10 
can you do arc9
zxssty 27 dec, 2023 @ 3:44 
does this work in single player?
Tom 15 nov, 2023 @ 3:05 
Is (GDCW) supported?
Eclipse 11 okt, 2023 @ 11:19 
TFA AT maybe?
ata47 27 jul, 2023 @ 3:16 
Whats TFA AT
Wedge 27 jun, 2023 @ 13:28 
ARC9 is pretty similar to ARCCW code wise it wouldnt be too hard for you to do
SweptThr.one  [skapare] 27 jun, 2023 @ 11:17 
no
Wedge 27 jun, 2023 @ 10:19 
Does not work with ARC9, please make it work with ARC9, thanks.