ttt_logic_role

From Valve Developer Community
Revision as of 12:27, 19 March 2024 by Strubium (talk | contribs) (Created page with "{{this is a|point|name=ttt_logic_role|game=Garry's Mod}}This point entity is used to test the role of the !activator. You set what role to test for. If the !activator of the t...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

ttt_logic_role is a point available in Garry's Mod Garry's Mod.This point entity is used to test the role of the !activator. You set what role to test for. If the !activator of the ttt_logic_role is the specified role, then the entity will fire a OnPass output, if it is not the correct role it will fire OnFail. It is VERY important to note that you do not want to set a button to start the test because that will test whoever presses the button. Instead, use a button to enable a trigger_multiple that will in turn fire the test output. This ensures that whoever is in the specific zone is the !activator. It is recommended to use this entity rather than the brush entity ttt_traitor_check, but may not work depending on some tester designs.

Keyvalues

Player role to test for ([todo internal name (i)]) <integer>
What role the entity will fire OnPass for. Can be either Innocent, Detective, Traitor, or Any Role.


Inputs

TestActivator
Test the activator for the given Role (ie. if it's a traitor/detective/etc) and fires OnPass or OnFail output. If activator is not a valid player it will always fail.

Outputs

OnPass
Fired in response to TestActivator input if the activator player is of the role set in this ent.
OnFail
Fired in response to TestActivator input if the activator player is NOT of the role set in this ent.