Env alyxemp: Difference between revisions

From Valve Developer Community
Jump to navigation Jump to search
(-added class hierarchy, cleanup)
 
(12 intermediate revisions by 8 users not shown)
Line 1: Line 1:
{{wrongtitle|title=env_alyxemp}}
{{LanguageBar}}
{{CD|CAlyxEmpEffect|file1=env_alyxemp.cpp}}
{{this is a|point entity|game=Half-Life 2 series|name=env_alyxemp}} This entity creates a particle effect from Alyx's EMP.


==Entity Description==
To attach one end to Alyx's EMP device:
This entity creates a particle effect from Alyx's EMP. Often parented to Alyx and set parent attachment to emp.
#Use the '''Parent''' keyvalue or the <code>SetParent</code> input to parent it to {{ent|npc_alyx}}.
#Send the <code>env_alyxemp</code> the <code>SetParentAttachment</code> input with <code>emp</code> for the parameter.
To change the '''Target Entity''', use the <code>SetTargetEnt</code> input with the new entity name for the parameter.
 
{{todo|How to make Alyx take out the EMP device?}}
 
{{tip|To find attachment points for other models, use {{ent|ent_attachments}}.}}
 
{{stray ent|{{portal}}}}


==Keyvalues==
==Keyvalues==
* {{KV Angles}}
{{KV Targetname}}
* {{KV Targetname}}
{{KV|EMP Type|intn=Type|choices|EMP effect type.
* {{KV Parentname}}
:*0: Small
* '''Type'''
:*1: Large}}
: <choices> EMP Type
{{KV|Target Entity|intn=EndTargetName|target_destination|Entity to use as a target endpoint (probably an {{ent|info_target}}). This entity can be its own target.}}
:{| class=standard-table
! Literal Value || Description
|-
| 0 || Small
|-
| 1 || Large
|}
* '''EndTargetName'''
: <?> Target Entity - Entity to use as a target endpoint.


<!--This entity doesn't have any flags.-->
==Inputs==
==Inputs==
* {{I Targetname}}
{{I|StartCharge|param=float|Start charging the effect over specified number of seconds.}}
* {{I Parentname}}
{{I|StartDischarge|Start discharging the effect over specified number of seconds.}}
* '''SetTargetEnt'''
{{I|Stop|param=float|Stops the effect. {{todo|Clarify what the parameter does?}}}}
:{{TODO|Write description.}}
{{I|SetTargetEnt|param=string|Sets the '''Target Entity''' for the effect.}}
* '''StartCharge'''
:{{TODO|Write description.}}
* '''StartDischarge'''
:{{TODO|Write description.}}
* '''Stop'''
:{{TODO|Write description.}}
 
==Outputs==
* {{O Targetname}}
 
[[Category:Entities]]

Latest revision as of 13:28, 25 September 2024

English (en)Translate (Translate)
C++ Class hierarchy
CAlyxEmpEffect
CBaseEntity
C++ env_alyxemp.cpp

env_alyxemp is a point entity available in Half-Life 2 series Half-Life 2 series. This entity creates a particle effect from Alyx's EMP.

To attach one end to Alyx's EMP device:

  1. Use the Parent keyvalue or the SetParent input to parent it to npc_alyx.
  2. Send the env_alyxemp the SetParentAttachment input with emp for the parameter.

To change the Target Entity, use the SetTargetEnt input with the new entity name for the parameter.

Todo: How to make Alyx take out the EMP device?
Tip.pngTip:To find attachment points for other models, use ent_attachments.
Note.pngNote:This entity is also in the code for Portal. Its functionality is not guaranteed.


Keyvalues

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

EMP Type (Type) <choices>
EMP effect type.
  • 0: Small
  • 1: Large
Target Entity (EndTargetName) <targetname>
Entity to use as a target endpoint (probably an info_target). This entity can be its own target.

Inputs

StartCharge <floatRedirectInput/float>
Start charging the effect over specified number of seconds.
StartDischarge
Start discharging the effect over specified number of seconds.
Stop <floatRedirectInput/float>
Stops the effect.
Todo: Clarify what the parameter does?
SetTargetEnt <stringRedirectInput/string>
Sets the Target Entity for the effect.