Garry's Mod

Garry's Mod

Not enough ratings
[TTT/2] Dead Ringer [ITEM]
   
Award
Favorite
Favorited
Unfavorite
Content Type: Addon
Addon Type: Weapon
Addon Tags: Cartoon, Fun
File Size
Posted
Updated
7.018 MB
Nov 6, 2023 @ 2:35pm
Feb 5 @ 3:12pm
11 Change Notes ( view )

Subscribe to download
[TTT/2] Dead Ringer [ITEM]

Description
NOTICE: This Addon only works for the "Trouble in Terrorist Town" and "TTT2" gamemodes.

A watch that feigns your death when you take damage. You will be cloaked for a short time and your attacker will be fooled.

Features
This is a modified version of the TTT Dead Ringer addon because it has not been updated to fix issues with TTT2 compatibility.

This equipment is available for the Traitors and Detectives in the Equipment menu.

If you want this addon to act like the original Dead Ringer item then set the following convars:

ttt_deadringer_cloak_reactivate 1
ttt_deadringer_sound_activate_local 0
ttt_deadringer_sound_deactivate_local 0

Compatibility
There should be no issues with other addons. This is compatible with both TTT and TTT2.

ConVars
  • ttt_deadringer_cloak_cooldown (def: 20) - Time it takes to recharge the Dead Ringer.
  • ttt_deadringer_cloak_duration (def: 7) - Time that the Dead Ringer will cloak you for.
  • ttt_deadringer_cloak_reuse (def: 0) - Whether or not unused cloak time is converted into charge time.
  • ttt_deadringer_cloak_transparency (def: 0.0) - Transparency of the cloak. (0.0 = invisible, 1.0 = visible)
  • ttt_deadringer_cloak_targetid (def: 0) - Whether or not the Dead Ringer will show the target ID while cloaked.
  • ttt_deadringer_cloak_reactivate (def: 0) - Whether or not the Dead Ringer will reactivate after recharging.
  • ttt_deadringer_damage_threshold (def: 2) - Threshold to trigger the Dead Ringer. The threshold is a flat value.
  • ttt_deadringer_damage_reduction (def: 0.65) - Damage reduction while cloaked.
  • ttt_deadringer_damage_reduction_time (def: 3) - Damage reduction time while cloaked.
  • ttt_deadringer_damage_reduction_initial (def: 0.75) - Percentage of damage reduction for first hit. (0.75 = 75%)
  • ttt_deadringer_corpse_mode (def: 0) - Whether or not the Dead Ringer shows a fake, real, or innocent role.
  • ttt_deadringer_corpse_confirm (def: 0) - Determines if the fake corpse will confirm the player's role when checked.
  • ttt_deadringer_hud_persist (def: 0) - Whether or not the Dead Ringer HUD will persist even while it is not activated.
  • ttt_deadringer_hud_classic (def: 0) - Whether or not the Dead Ringer HUD will use the classic style. (TTT2 only)

Note: After changing these values you may have to restart your map/server.

Server Infos
Add it to your server by following this guide: http://wiki.garrysmod.com/page/Server/Workshop

Translations
  • deadringer_name
  • deadringer_desc

Source
The whole source code can be found on GitHub[github.com], feel free to contribute. The original addon was taken from here (but modified extensively!). I agree to remove this item if the Author or Valve wishes to.

Thanks for reading, enjoy and have fun!
62 Comments
The Stig May 26 @ 11:29pm 
I ended up adding a tweak to my tweaks and fixes mod for this mod to act like the original dead ringer by default: https://steamcommunity.com/sharedfiles/filedetails/?id=3101810034

If you don’t like some of the tweaks you can just turn them off using the convars listed in the description. If you really want, you could turn off every convar except for the dead ringer tweak.
Crimson Speckled Flunkey May 26 @ 8:41pm 
Hey when is the convar for attacking while invisible coming? being able to fake your death and attack while invisible is pretty overpowered
[LCB] BassGaming Apr 23 @ 7:00pm 
+1
I'd appreciate it a lot if you could include the pull request by @The Stig in a quick hotfix.
Without that convar we are currently unable to use this addon.
The Stig Mar 3 @ 9:37pm 
Any chance of just quickly putting my PR in as a hotfix?
dhkatz  [author] Feb 21 @ 4:32pm 
That is odd, I am probably not unregistering a hook when I should be. I force call HUDPaint even when the weapon is not active so that you can see it.
The Stig Feb 21 @ 2:01am 
Thanks for that!
Also, a minor thing, the classic HUD doesn't seem to go away after you die. It only does so after the next round starts.
dhkatz  [author] Feb 20 @ 11:24pm 
I was working on something similar, I will merge your PR. A few more updates I want to do before doing another release
The Stig Feb 20 @ 7:14pm 
I added the option myself. Have a look at this PR: https://github.com/gmod-workshop/ttt-deadringer/pull/7

Please let me know if you update the mod.

You'll have to add ttt_deadringer_cloak_attack 0 to the list of convars needed in the description for the dead ringer to work like the original version.
dhkatz  [author] Feb 19 @ 11:55am 
I can add an option for this
Mega Bad Feb 18 @ 11:00am 
We have a problem in ttt2 the dead ringer triggers you become invisible but can still continue shooting is that what you want?