12-Jul-2023
Causes nearby players' screens to shake. Used for simulating earthquakes.
Keyvalues |
OnDestroy Function ondestroyfn : Name of the function to use from already parsed .as script files when entity is destroyed (killed) in any way. If the function belongs to namespace, you must use prefix with the namespace name (e.g. mynamespace::MyFunction) for the keyvalue.
Name targetname : Set name of env_shake so other entities can trigger it to apply a screen shake. Every trigger use-type works uniformly. Multiple triggering will override previous shake. Can be kill-targeted but shake won't stop playing until finished.
Amplitude (degrees; 0-16) amplitude : Ranging from 0.0 to 16.0, this sets the amplitude in degrees.
Effect radius (if not global) radius : Radius around the entity in which the rumble affects players. Becomes less noticeable towards the outside of the radius.
Duration (seconds; fades out) duration : The duration, in seconds, which the rumble lasts. This includes a linear fade-out: The rumble starts with the set amplitude, which becomes less towards the duration time running out.
Frequency (Hz; 0-255) frequency : The frequency of the rumble. A value of 10 would mean that your screen will shake up and down ten times per second.
1 : Global Shake : The env_shake will affect the whole map equally, instead of a radius around it.
Env_shakes can safely be triggered while a rumble is still in progress, causing the new rumble to overwrite the old one entirely.