env_shake

From Source Entities
Jump to navigation Jump to search

Code classes:

Env shake.png

env_shake is a point entity present in all Source games. It shakes the screens of players. Objects can be jostled as well.

Note: Shaking can hinder a gun's accuracy.

Bug: Does not work in Asw.png. See asw_env_shake.

Flags[edit | edit source]

  • 1: GlobalShake - Ignore radius, entire map shakes.
  • 4: In Air - Shake players even in the air.
  • 8: Physics - Shake physics objects, not just the camera.
  • 16: Ropes - Shake ropes. (Works independently from Physics.)
  • 32: DON'T shake view (for shaking ropes or physics only)
  • 64: DON'T Rumble Controller - Do not shake the controller for players using an console-style controller.

Keyvalues[edit | edit source]

Amplitude (0-16) (amplitude) <float>
How far away from the normal position the camera will wobble. Should be between 0 and 16.
Effect Radius (radius) <float>
The radius around this entity in which to affect players.
Duration (seconds) (duration) <float>
The length of time in which to shake the screen.
Frequency (frequency) <float>
How many times per second to change the direction of the camera wobble. 40 is generally enough; values higher are hardly distinguishable.

Inputs[edit | edit source]

Amplitude <float>
Sets Amplitude.
Frequency <float>
Sets Frequency.
StartShake
Start the shake.
StopShake
Stop the shake.