Logic coop manager: Difference between revisions
Jump to navigation
Jump to search

m (Multipage removal) |
(class hierarchy, intn, activator/caller) |
||
(4 intermediate revisions by 4 users not shown) | |||
Line 1: | Line 1: | ||
{{LanguageBar}} | {{LanguageBar}} | ||
{{this is a| | {{CD|CLogicCoopManager|file1=logicentities.cpp}} | ||
{{this is a|logical entity|name=logic_coop_manager|game=Portal 2|sprite=1}} {{also|{{gmod}} {{!fgd}}}} It manages two sets of values and can fire outputs based on the state of those values. Useful in coop where you can have players independently setting states on different buttons, switches, etc. | |||
==KeyValues== | |||
== KeyValues == | |||
{{KV Targetname}} | {{KV Targetname}} | ||
{{KV|Default State A|intn=DefaultPlayerStateA|bool|The default state of A}} | |||
{{KV|Default State B|intn=DefaultPlayerStateB|bool|The default state of B}} | |||
==Inputs== | == Inputs == | ||
{{ | {{I|SetStateATrue|Set State A to TRUE}} | ||
{{ | {{I|SetStateAFalse|Set State A to FALSE}} | ||
{{ | {{I|ToggleStateA|Toggle State A}} | ||
{{ | {{I|SetStateBTrue|Set State B to TRUE}} | ||
{{ | {{I|SetStateBFalse|Set State B to FALSE}} | ||
{{ | {{I|ToggleStateB|Toggle State B}} | ||
==Outputs== | == Outputs == | ||
{{ | {{O|OnChangeToAllTrue|ac-is-this=1|Fires when ALL of the values change to TRUE for the first time}} | ||
{{ | {{O|OnChangeToAnyTrue|ac-is-this=1|Fires when ANY of the values change to TRUE for the first time}} | ||
{{ | {{O|OnChangeToAllFalse|ac-is-this=1|Fires when ALL of the values change to FALSE for the first time}} | ||
{{ | {{O|OnChangeToAnyFalse|ac-is-this=1|Fires when ANY of the values change to FALSE for the first time}} | ||
Latest revision as of 08:21, 29 April 2025


![]() |
---|
CLogicCoopManager |
![]() |

logic_coop_manager
is a logical entity available in Portal 2. (also in
!FGD) It manages two sets of values and can fire outputs based on the state of those values. Useful in coop where you can have players independently setting states on different buttons, switches, etc.
KeyValues
- Name (targetname) <string>[ Edit ]
- The name that other entities refer to this entity by, via Inputs/Outputs or other keyvalues (e.g.
parentname
ortarget
).
Also displayed in Hammer's 2D views and Entity Report.See also: Generic Keyvalues, Inputs and Outputs available to all entities
- Default State A (DefaultPlayerStateA) <boolean>
- The default state of A
- Default State B (DefaultPlayerStateB) <boolean>
- The default state of B
Inputs
- SetStateATrue
- Set State A to TRUE
- SetStateAFalse
- Set State A to FALSE
- ToggleStateA
- Toggle State A
- SetStateBTrue
- Set State B to TRUE
- SetStateBFalse
- Set State B to FALSE
- ToggleStateB
- Toggle State B
Outputs
- OnChangeToAllTrue
- !activator = !caller = this entity
Fires when ALL of the values change to TRUE for the first time
- OnChangeToAnyTrue
- !activator = !caller = this entity
Fires when ANY of the values change to TRUE for the first time
- OnChangeToAllFalse
- !activator = !caller = this entity
Fires when ALL of the values change to FALSE for the first time
- OnChangeToAnyFalse
- !activator = !caller = this entity
Fires when ANY of the values change to FALSE for the first time