Garry's Mod

Garry's Mod

605 ratings
Damage Based Disarm
3
2
2
   
Award
Favorite
Favorited
Unfavorite
Content Type: Addon
Addon Type: Effects
Addon Tags: Realism
File Size
Posted
Updated
10.138 KB
29 Apr, 2021 @ 11:09am
3 May, 2021 @ 7:03pm
2 Change Notes ( view )

Subscribe to download
Damage Based Disarm

Description
Damage based disarm allows you to shoot weapons right out of people's hands! Pacify someone with careful aiming! Settle a duel with style!

Any shot that hits your hand (assuming it's involved in holding the weapon) with enough force will cause the weapon to be knocked out of your hand. The shot's damage will also be reduced by a configurable amount.

By default, the addon performs a small calculation on every damage event to determine if they struck the victim's hand. Optionally, the addon can use a cheaper checking mode, where it simply checks where on the victim's body the shot reported it hit. This is a little faster, but can only detect whether the entire arm was shot, and NPCs won't be able to be disarmed.

The addon's settings can be found in Utilities -> Damage-Based Disarm. Key settings include:
>Changing who can be disarmed by what.
>The force required for a shot to disarm.
>How much shots hitting hands should reduce their damage by.

Compatibility:
In theory, this should work with all playermodels, NPCs, and weapons. However, sometimes developers can forget to add information to models and weapons that will stop the addon being able to detect when to disarm someone.

Addons used in screenshots/videos:
Maps:
>rp_city8 https://steamhost.cn/steamcommunity_com/sharedfiles/filedetails/?id=132913036
>ttt_deadwood_a2 https://steamhost.cn/steamcommunity_com/sharedfiles/filedetails/?id=348877807
Playermodels:
>Western Folk (PMs+NPC's) https://steamhost.cn/steamcommunity_com/sharedfiles/filedetails/?id=2424138501

Usage and Modifications:
Feel free to incorporate any and all of this addon into your own project. If you use a large amount of the code, an attribution or link to the original would be much obliged!
Popular Discussions View All (1)
2
10 May, 2021 @ 1:54pm
Adding Compatibility For Damage Based Disarm
Cubic_llama
83 Comments
RadRick 24 Mar @ 5:22pm 
oh thank you bro
Cubic_llama  [author] 24 Mar @ 4:42pm 
try the other way round? as I recall, the default settings make it hard to disarm with an AR2, especially something "2 handed" like the revolver. obviously you can change them if the isn't to your liking
RadRick 24 Mar @ 4:06pm 
revolver and a ar2
Cubic_llama  [author] 24 Mar @ 6:02am 
As in what weapon are they holding, and what weapon are you trying to disarm them with?
RadRick 23 Mar @ 11:57pm 
the original weapon?
Cubic_llama  [author] 23 Mar @ 7:11am 
what weapon are you trying with? are you sure you're hitting their hand?
RadRick 22 Mar @ 6:33pm 
it's not working for me?
Гордон фримен 22 Jan @ 7:50am 
well
Infamous Booty Tickler 2 Apr, 2024 @ 2:13pm 
those pesky lawmen are NOT gonna see this one comin.
Firebowl 1 Feb, 2024 @ 11:11am 
does this cooperate with lambda players?