Garry's Mod

Garry's Mod

283 ratings
Damage for HL2 Vehicles
2
   
Award
Favorite
Favorited
Unfavorite
Content Type: Addon
Addon Type: Tool
Addon Tags: Fun, Realism
File Size
Posted
Updated
18.455 MB
5 Jul, 2024 @ 11:35am
19 Jun @ 2:09pm
11 Change Notes ( view )

Subscribe to download
Damage for HL2 Vehicles

Description
Hello, and welcome to my very first original public add-on for Garry's Mod!

This is a simple script that adds health to vehicles and the ability to damage them, i am surprised how no one has ever made this before.
This adds combat damage (bullets/hits) as well as physical collision damage (e.g crashing your car, hitting it, falling with it) to vehicles as well as detailed gibbing and explosion effects, while staying faithful to the vanilla style AND looking cool!

Anyway, this mod features:

- Adjustable health / damage system for the jeep, airboat and even the jalopy from Half-Life 2: Episode 2! (As well as vehicles that use jeep base and airboat base)
- Many convars for all possible parameters, as well as an options menu, find it in "Utilities" tab, under "Vergi's Addons" section.
- Visualizer for damage (the vehicles will become gradually more scorched / darker as they take damage, there is also a convar to disable it although i do not recommend it cause you can't tell the amount of health left for the car at all otherwise).
- Cool effects! Vehicles will create a spark and catch on fire once it is extremely damaged, giving you a few moments for you to get back, as it will explode and leave a fire behind, and shoot up a bunch of giblets!
- Detailed vehicle gibbing that uses gibs from the vehicle models themselves with some randomized additional gibs shared across all vehicle types. Vehicles that use jeep or airboat base but don't have a model matching to the vanilla HL2 vehicles will use generic gibs instead, in order to appear more believable and not look strange.
- Adjustable chance of loot items such as ammo boxes and suit batteries being expelled from the vehicles when exploding.
-Minimalist gore! When a player dies inside of an exploding vehicle, a blood splat will be left at the explosion site, and skeletal remains such as skulls and spines will be sent flying everywhere! (this can also be disabled via convar/options)
- Optimization (only 18mb filesize, and checks were added in the code in order to make the action run only when the requirements are met, additionally, the vehicle gibs have no collision and despawn after 10 seconds by default)
- Physical collision system has finally been added to this version of the mod, allowing you to crash and bump your car and actually damage it in the process! There are convars/options for adjusting the collision system's sensitivity (0.3 by default, as that is the sweetspot) or even disabling it completely.
- Vehicle handling is now slightly worsened gradually as vehicle health gets lowered.

Potential upcoming features in the future:
- A way to heal vehicles (probably through a SWEP).
- Vehicles damage in even more cases (such as gravity gun punting, props being thrown at them, AR2 energy balls)
- Fixes for effects/features that may not work out of the box.

Credit to https://steamhost.cn/steamcommunity_com/id/netuSsilki228 for the models of the jeep and airboat parts, and to https://steamhost.cn/steamcommunity_com/id/435325228 for the models of the jalopy parts.

NEW! The addon now has it's own github page, go check it out: https://github.com/Vergi314/Damage-for-HL2-Vehicles

If you encounter bugs or have suggestions whether if it's for this mod or an idea for a new mod that i should make, let me know in the comments!

Either way, i hope you enjoy this, and stay tuned for more mods!
Popular Discussions View All (1)
4
17 Jun @ 12:48pm
Bugs/Suggestions
Virgiliu314
105 Comments
Virgiliu314  [author] 25 Jun @ 12:43am 
Hehe, not sure, i was thinking of that but never tested it in campaign maps, thanks for letting me know tho. I could try find a fix but the thing is, i have no idea how i could fix it without uh.... making the physical damage not work at all... for now one thing you could do is lower the sensitivity even more in the mod's options (although i wouldn't reccommend), or just disable it completely if you don't need it
JackOof 24 Jun @ 10:17pm 
Love this addon but during the beginning of the Highway chapter of HL2 when the crane drops the jeep it instantly explodes, would there be anyway to fix that?
Virgiliu314  [author] 19 Jun @ 2:11pm 
@>KB> >KEKSQUAD I've pushed an update, it should work smoothly now, without any CPU hogging. If there's any other problems, let me know!
Virgiliu314  [author] 18 Jun @ 1:33pm 
if it uses jeep base, yes
[Dog--Tags] 18 Jun @ 12:52pm 
is it compatible with Half-Life 2 Vehicles Extended?
Virgiliu314  [author] 18 Jun @ 11:35am 
i see, that'll help narrow it down, i'll check it out later or tomorrow if i get the chance
>KB> >KEKSQUAD 18 Jun @ 11:32am 
It's specifically for vehicle collision damage btw
Virgiliu314  [author] 18 Jun @ 11:30am 
Virgiliu314  [author] 17 Jun @ 11:39pm 
Hmm, i'll look into it to optimize it soon-ish i hope, but it may take some time as i'm busy with other things
>KB> >KEKSQUAD 17 Jun @ 2:41pm 
Hey so I noticed there was quite a bit of CPU hogging with about 50 prisoner pods here

Event "Think", hook "VehicleCollisionDamag 12.49% 180 5535.881us 12765.3us
in "lua/vehicle_damage.lua" (lines 121 to 198),
found in Workshop addon « Damage for HL2 Vehicles »