Dod capture area: Difference between revisions

From Valve Developer Community
Jump to navigation Jump to search
m (Add bug)
 
(23 intermediate revisions by 8 users not shown)
Line 1: Line 1:
{{dods brush|dod_capture_area}}
{{tabs|dod_capture_area|goldsrc = 1|source = 1|main = source}}
{{CD|CAreaCapture|file1=dod/dod_area_capture.cpp|base=CBaseTrigger}}
{{this is a|brush entity|name=dod_capture_area|game=Day of Defeat: Source}}


==Entity description==
This brush entity represents the area where the player(s) must stand to start capturing the flag.
Capture area. This brush entity is the area where the player(s) must stand in order to start capturing the flag.


==Keyvalues==
==Key Values==
{{otherKIO|trigger|append=Functionality of KVs and I/O not mentioned here is not guaranteed.}}
{{KV Targetname}}
{{KV Targetname}}
 
{{KV StartDisabled}}
{{KV EnableDisable}}
{{KV|Can Allies Cap?|intn=area_allies_cancap|bool|}}
 
{{KV|Can Axis Cap?|intn=area_axis_cancap|bool|Select if Allied or Axis players can capture the flag, respectively.}}
{{KV|Can Allies Cap?|bool|Select if Allies can capture the flag.}}
{{KV|Number of Allies to cap|intn=area_allies_numcap|int|}}
 
{{KV|Number of Axis to cap|intn=area_axis_numcap|int|The number of Allied or Axis players needed to capture the flag, respectively.{{bug|hidetested=1|Client game crash if you set above 5. The limit is supposed to be 9.}}}}
{{KV|Can Axis Cap?|bool|Select if Axis can capture the flag.}}
{{KV|Time to cap (sec)|intn=area_time_to_cap|float|Time to capture the flag, in seconds.}}
 
{{KV|Name of the control point this area is linked to|intn=area_cap_point|target_destination|Name of the {{ent|dod_control_point}} entity this area is linked to.}}
{{KV|Number of Allies to cap|int|The number of Allies needed to capture the flag.{{bug|Client game crash if you set above 5}}}}
 
{{KV|Number of Axis to cap|int|The number of Axis needed to capture the flag.{{bug|Client game crash if you set above 5}}}}
 
{{KV|Time to cap <nowiki>(sec)</nowiki>|int|Time to capture the flag.}}
 
{{KV|Name of the control point this area is linked to|target_destination|Name of the control point this area is linked to.}}


==Inputs==
==Inputs==
{{I Targetname}}
{{I|RoundInit|nofgd=1|Re-parse the {{mono|area_allies_numcap}}, {{mono|area_allies_numcap}}, and {{mono|area_time_to_cap}} KVs. Use this if they are changed via [[AddOutput]].}}
{{I EnableDisable}}
{{I EnableDisable}}


==Outputs==
==Outputs==
{{O Targetname}}
{{note|The [[!activator]] and [[!caller]] for all outputs is this entity.}}
 
{{O|OnAlliesStartCap / OnAxisStartCap|Sent when Allies or Axis start capture, respectively.}}
{{IO|OnAlliesStartCap|Sent when Allies start capture.|}}
{{O|OnAlliesBreakCap / OnAxisBreakCap|Sent when Allies or Axis break capture, respectively.}}
 
{{O|OnAlliesEndCap / OnAxisEndCap|Sent when Allies or Axis end capture, respectively.}}
{{IO|OnAlliesBreakCap|Sent when Allies break capture.|}}
{{O|OnStartCap|Sent when either team starts capture.|}}
 
{{O|OnBreakCap|Sent when either team break capture.|}}
{{IO|OnAlliesEndCap|Sent when Allies end capture.|}}
{{O|OnEndCap|Sent when either team end capture.|}}
 
{{IO|OnAxisStartCap|Sent when Axis start capture.|}}
 
{{IO|OnAxisBreakCap|Sent when Axis break capture.|}}
 
{{IO|OnAxisEndCap|Sent when Axis end capture.|}}
 
{{IO|OnStartCap|Sent when either team starts capture.|}}
 
{{IO|OnBreakCap|Sent when either team break capture.|}}
 
{{IO|OnEndCap|Sent when either team end capture.|}}

Latest revision as of 06:45, 4 June 2025

C++ Class hierarchy
CAreaCapture
CBaseTrigger
CBaseToggle
CBaseEntity
C++ dod/dod_area_capture.cpp

dod_capture_area is a brush entity available in Day of Defeat: Source Day of Defeat: Source.

This brush entity represents the area where the player(s) must stand to start capturing the flag.

Key Values

Note.pngNote:Other Keyvalues / Inputs / Outputs are same as trigger.
Functionality of KVs and I/O not mentioned here is not guaranteed.
Name (targetname) <string>[ Edit ]
The name that other entities refer to this entity by, via Inputs/Outputs or other keyvalues (e.g. parentname or target).
Also displayed in Hammer's 2D views and Entity Report.
See also:  Generic Keyvalues, Inputs and Outputs available to all entities

Start Disabled (StartDisabled) <boolean>
Stay dormant until activated (with theEnableinput).
Can Allies Cap? (area_allies_cancap) <boolean>
Can Axis Cap? (area_axis_cancap) <boolean>
Select if Allied or Axis players can capture the flag, respectively.
Number of Allies to cap (area_allies_numcap) <integer>
Number of Axis to cap (area_axis_numcap) <integer>
The number of Allied or Axis players needed to capture the flag, respectively.
Icon-Bug.pngBug:Client game crash if you set above 5. The limit is supposed to be 9.
Time to cap (sec) (area_time_to_cap) <float>
Time to capture the flag, in seconds.
Name of the control point this area is linked to (area_cap_point) <targetname>
Name of the dod_control_point entity this area is linked to.

Inputs

RoundInit  !FGD
Re-parse the area_allies_numcap, area_allies_numcap, and area_time_to_cap KVs. Use this if they are changed via AddOutput.

EnableDisable:

Enable / Disable
Enable/disable this entity from performing its task. It might also disappear from view.

Outputs

Note.pngNote:The !activator and !caller for all outputs is this entity.
OnAlliesStartCap / OnAxisStartCap
Sent when Allies or Axis start capture, respectively.
OnAlliesBreakCap / OnAxisBreakCap
Sent when Allies or Axis break capture, respectively.
OnAlliesEndCap / OnAxisEndCap
Sent when Allies or Axis end capture, respectively.
OnStartCap
Sent when either team starts capture.
OnBreakCap
Sent when either team break capture.
OnEndCap
Sent when either team end capture.