Garry's Mod

Garry's Mod

Not enough ratings
[TTT2] Phantom [ROLE]
   
Award
Favorite
Favorited
Unfavorite
Content Type: Addon
Addon Type: Gamemode
Addon Tags: Fun, Roleplay, Scenic
File Size
Posted
Updated
375.199 KB
11 May, 2022 @ 5:41am
8 Mar, 2023 @ 8:56am
12 Change Notes ( view )

Subscribe to download
[TTT2] Phantom [ROLE]

Description
A myth, they said. But the Phantom isn't a myth. The Phantom floats through the realm of the dead while taking the lives of poor innocent souls.

You have to use TTT2 in order to use this role. Report bugs concerning this role here[github.com] and submit new role ideas here[github.com]. A list of all currently available roles can be found here.

Discord: https://discord.gg/Npcbb4W
Source: https://github.com/Pythagorion/ttt2-role_phantom




The Phantom is a Traitor-Teammember without access to the shop. They also have no credits, nor get some.

If a non-traitor role attempts to examine his corpse, that player pays for that action with his life. There is also the possibility to configure the role so that the phantom can be revived by it.

Plays best with:




Convars are variables that are introduced to allow server owners to customize the gameplay without changing the code. There are always a handful of convars automatically created by TTT2, that define the spawn parameters of this role and are found in the F1 Menu under Role Settings. Additionally there might be some role specific convars, which have to be set in the server config file.

Normal Role Convars (also found in the F1 Menu under Role Settings):
# enable or disable this role ttt_phant_enabled [0/1] (default: 1) # the percentage of players that are spawned as this role ttt_phant_pct [0.0..1.0] (default: 0.15) # the limit of players that spawn as this role each round, this overwrites the percentage ttt_phant_max [0..n] (default: 1) # the probability each round of this role being spawned at all ttt_phant_random [0..100] (default: 33) # the amount of players needed for this role to spawn ttt_phant_min_players: [0..n] (default: 8)

Rolespecific Convars:
# Resurrect the Phantom after a player searched them ttt_phantom_revive_after_found [0/1] (default: 1) # Resurrect the Phantom everytime when someone tries to search them ttt_phantom_resurrection_everytime [0/1] (default: 0) # Kill every player that searches the Phantom's corpse ttt_phantom_kill_everytime [0/1] (default: 0) # Prevent the Phantom's corpse from being confirmed ttt_phantom_prevent_confirmation [0/1] (default: 1) # Prevent all corpses - except the Phantom's one - from being confirmed ttt_phantom_prevent_all_searches [0/1] (default: 1) # Traitors cannot search the Phantom's corpse ttt_phantom_traitor_prevent_search [0/1] (default: 0) # Traitors cannot search all corpses - except the Phantom's one tt_phantom_traitor_prevent_search_all [0/1] (default: 0) # Display a pop-up that will warn players about the Phantom ttt_phantom_send_epop_at_beginning [0/1] (default: 0) # Prevent the Phantom's corpse from being confirmed by policing roles ttt_phantom_prevent_policing_search_phantom [0/1] (default: 1) # Prevent all corpses - except the Phantom's one - from being confirmed by policing roles ttt_phantom_prevent_policing_search_all [0/1] (default: 1) # Kill policing roles, when they confirm the Phantom (only works if searching isn't prevented; Will work only once if the cvar 'kill everytime' isn't active) ttt_phantom_kill_policing_after_search [0/1] (default: 0) # Display a warn message that corpses can't be searched while a Phantom is active ttt_phantom_in_round_hint [0/1] (default: 0)

--
Credits:
Pythagorion: creator of this role addon & Icon
17 Comments
Combex 22 Jun, 2024 @ 2:42pm 
I tried to find out the cause in detail, but I couldn't figure it out. It seems to be incompatible with SMORE.
Pythagorion  [author] 22 Jun, 2024 @ 1:04pm 
that's a severe bug, indeed. I try to fix the issue as soon as possible, but it could take a few days as I am very busy in the moment.
Combex 22 Jun, 2024 @ 12:48pm 
I'm not sure if there is support for this anymore, but I found a serious bug so I'll share it.
If the settings are:
ttt_phantom_prevent_policing_search_all "0"
ttt_phantom_prevent_policing_search_phantom "0"
TTT will be broken and you will not be able to join the server.
Pythagorion  [author] 30 Mar, 2023 @ 12:18pm 
@Hannes So I could identify the bug's origin. Sadly I am not able to provide a fix yet. Honestly I have no idea why the bug is occuring because it shouldn't under these circumstances. In the moment I don't know how to fix it, so I must do more research to find a way to resolve the issue.
Pythagorion  [author] 30 Mar, 2023 @ 10:57am 
@Hannes I finally found time, to get into the bug you've mentioned and indeed I could reproduce it myself. I'll try to find the origin and fix it then.
Pythagorion  [author] 10 Mar, 2023 @ 8:52am 
@Hannes I'll look into it in the coming days. I have not changed the code regarding the pop-up, but I also haven't relly played in the last months, so there could be a bug anyways. I try to fix it asap.
Hannes 10 Mar, 2023 @ 8:47am 
Heyyyy, it's me again...
Might it be that you changed some of the code for the pop-up regarding the phantom, because I don't seem to be getting any info whatsoever on my server that a phantom is in the round at the start of the game...
If you have the time, I would very much appreciate a fix, because I honestly really like this role and woul love to continue using it!
Pythagorion  [author] 8 Mar, 2023 @ 8:57am 
@Memiix the bug should be fixed.
Pythagorion  [author] 14 Jan, 2023 @ 3:38am 
I see. That's definitely not supposed to happen. Sadly - as I stated in my other message - I am not able to provide any fixes soon, as I am very busy in the moment. I will provide a warning in the workshop description and try to fix it as soon as possible. Thanks for the report.
Memiix 13 Jan, 2023 @ 5:44pm 
hey so me and a friend found that when inspecting a phantom in spectator mode it revives the phantom