Garry's Mod

Garry's Mod

Not enough ratings
[TTT] Zap Grenade
   
Award
Favorite
Favorited
Unfavorite
Content Type: Addon
Addon Type: Weapon
Addon Tags: Cartoon, Fun, Movie
File Size
Posted
Updated
2.464 MB
4 Aug, 2023 @ 2:42pm
18 Aug, 2023 @ 12:26pm
3 Change Notes ( view )

Subscribe to download
[TTT] Zap Grenade

In 3 collections by Corvatile
Corvatile's TTT Weapons
9 items
All of Corvatile's TTT Addons
20 items
Corvatile's TTT Randomats
6 items
Description
The Zap Grenade is a special grenade item for Trouble in Terrorist Town.

The Zap Grenade is part of the generic weapons pool and will appear alongside other grenades like Discombobulators and Incendiary Grenades.

After 3 seconds, the Zap Grenade explodes.

Throwing the Zap Grenade at a player will shock them for a second and cause them to drop their currently equipped weapon.

The Zap Grenade instantly vaporises any NPC, including zombies, bees, barnacles and helicopters.

Throwing it at explosive props such as exploding barrels, gas cans and propane canisters harmlessly disintegrates them without triggering an explosion.

The Zap Grenade also instantly destroys traps and shop items. This includes:

  • Shark Traps
  • Shock Traps
  • Spring Mines
  • Bear Traps
  • M4 SLAM tripmines and satchels
  • C4s
  • Hopper Mines
  • Artillery Cannons
  • Paper Planes
  • Killer Snails
  • Manhack Spawners
  • Manhack Bombs
  • NPC Vaults
  • Weeping Angels
  • Controllable Manhacks
  • Any spawned NPC such as Turrets, Zombies, Bees, Doncombine, etc

Has c_hands support.

This addon pairs well with my Weapon Spawn Ratio Mod which alters the spawn rates of the various weapon types to make grenade as numerous as they were in vanilla TTT:
[TTT] Weapon Spawn Ratio Mod



Randomat Event
This addon also contains a custom Randomat event for the Randomat 2.0 mod (or its Custom Roles version) which is automatically added to the random events pool. You can toggle this Randomat using the ULX menu or by changing its convar manually.

Shock It to Me
Everyone gets unlimited Zap Grenades.
ttt_randomat_shockittome 1



Check out some of the other TTT addons I've made...

[TTT] Hellcrane (Custom Map)
[TTT] Extra Randomats for TTT Custom Roles
[TTT] Lift Grenade (Custom Weapon)
8 Comments
Unaverage Joe. 30 Mar @ 1:06am 
From what I'm reading correctly, the code that deals damage to NPCs seems unnecessary if they are ment to be dissolved with env_entity_dissolver, and it is that very damage that players are getting hit by that are causing issues.
Corvatile  [author] 28 Mar @ 10:49pm 
Thanks for reporting this, I'll look into it.

On ttt_supercop, if you kill the Supercop with a Zap Grenade he respawns in his normal spawn place and only killing him with the Tau Cannon from the map will permanently take him down. Still, if that's not something you want I can set up a convar for it.
Cpt.Haxray 28 Mar @ 6:40pm 
Major Bug Report:

If someone throws the Zap Grenade and it kills a NPC while also hitting the person who threw it, it instantly kills the thrower. It also deletes their body. However, they will not display as dead on the scoreboard and can continue to speak with living players, but are considered as dead for end of round effects.
Cpt.Haxray 21 Mar @ 12:26pm 
Is it possible to get a convar for this that disables the vaporizing npcs? This grenade sounds interesting and fun but it instant killing npcs could be an issue on some TTT maps(Ex: TTT_Supercop).
Corvatile  [author] 6 Dec, 2023 @ 1:01pm 
It's a Trouble in Terrorist Town addon that uses the TTT grenade base so it isn't compatible with Sandbox.
anchorbadge 6 Dec, 2023 @ 11:11am 
is this weapon not available in sandbox, I can't seem to find it anywhere.
Corvatile  [author] 18 Aug, 2023 @ 12:01pm 
Thanks for flagging this up, I've updated it now.
The Stig 14 Aug, 2023 @ 8:53pm 
Hey just letting you know the way you overwrote the SWEP:PullPin() function to change the throwing animation causes conflicts with other mods trying to override the same function.

You can easily fix this by overriding the function the proper way using self.Basclass:
function SWEP:PullPin()
self.BaseClass.PullPin(self)
self:SendWeaponAnim(ACT_VM_PULLBACK_HIGH)
end

What this does is just calls the original PullPin() function before making the change you want.