Trigger wind: Difference between revisions

From Valve Developer Community
Jump to navigation Jump to search
m (-added important flags)
m (-added some more notices)
Line 10: Line 10:
{{KV|Pitch Yaw Roll (Y Z X)|intn=angles|angles|Yaw sets the wind direction. Pitch and roll should be ignored.
{{KV|Pitch Yaw Roll (Y Z X)|intn=angles|angles|Yaw sets the wind direction. Pitch and roll should be ignored.
{{warning|Brush also gets rotated but it's not shown in hammer}}}}
{{warning|Brush also gets rotated but it's not shown in hammer}}}}
{{workaround|If [[vscript|Vscripts]] with NetProps functions are available then instead of using angles keyvalue create logic_auto that '''OnMapSpawn''' sends '''RunScriptCode''' input to trigger_wind with parameter. (45 yaw in this example)
<source lang=c>foreach(k,v in {m_nDirBase=45}) NetProps.SetPropInt(self,k,v)</source>}}
{{KV|Direction Noise|intn=DirectionNoise|integer|Noise added to wind direction.}}
{{KV|Direction Noise|intn=DirectionNoise|integer|Noise added to wind direction.}}


Line 25: Line 28:
{{IO|SetSpeed|Set the baseline for how hard the wind blows.|param=integer}}
{{IO|SetSpeed|Set the baseline for how hard the wind blows.|param=integer}}
{{I EnableDisable}}
{{I EnableDisable}}
{{Bug|Props that are inside this trigger's brush and are asleep won't be detected after '''Enable''' input.}}
{{Fix|Send '''Wake''' input to all the desired props.}}


== See also ==
== See also ==

Revision as of 11:18, 3 October 2022

Template:Base brush It is a trigger that pushes physics objects that touch its volume.

Warning.pngWarning:Clientside prop_physics aren't detected by this entity. Use Force server-side flag if this is an issue.
C++ In code, it is represented by theCTriggerWindclass, defined in thetriggers.cppfile.

Keyvalues

Speed (speed) <integer>
The baseline for how hard the wind blows.
Speed Noise (SpeedNoise) <integer>
Noise added to wind speed +/-


Pitch Yaw Roll (Y Z X) (angles) <angles>
Yaw sets the wind direction. Pitch and roll should be ignored.
Warning.pngWarning:Brush also gets rotated but it's not shown in hammer
PlacementTip.pngWorkaround:If Vscripts with NetProps functions are available then instead of using angles keyvalue create logic_auto that OnMapSpawn sends RunScriptCode input to trigger_wind with parameter. (45 yaw in this example)
foreach(k,v in {m_nDirBase=45}) NetProps.SetPropInt(self,k,v)


Direction Noise (DirectionNoise) <integer>
Noise added to wind direction.


Hold Time (HoldTime) <integer>
Baseline for how long to wait before changing wind.
Hold Noise (HoldNoise) <integer>
Noise added to how long to wait before changing wind.


Filter Name (filtername) <filter>
Name of filter entity to test against activators.

Flags

Needs one of these flags checked to work.

Physics Objects : [8]
Everything (not including physics debris) : [64]

Inputs

SetSpeed <integerRedirectInput/integer>
Set the baseline for how hard the wind blows.

EnableDisable:

Enable / Disable
Enable/disable this entity from performing its task. It might also disappear from view.
Icon-Bug.pngBug:Props that are inside this trigger's brush and are asleep won't be detected after Enable input.  [todo tested in ?]
Note.pngFix:Send Wake input to all the desired props.

See also