Mod:Creation Kit/ShakeCamera - Game

Member of: Mod:Creation Kit/Game Script

Shakes the camera from the specified object's location, with the specified strength. The optional duration can be used to define how long to shake the camera. If no duration is provided then the fCameraShakeTime game setting will be used for duration.

Syntax
Function ShakeCamera(ObjectReference akSource = None, float afStrength = 0.5, float afDuration = 0.0) native global

Parameters

 * akSource: Where to shake the camera from. If None, will shake the camera from the player's location
 * Default: None
 * afStrength: How hard to shake the camera. The value will be clamped from 0 to 1.
 * Default: 0.5
 * afDuration: How long in seconds to shake the camera.
 * Default: 0.0 (Use the game setting)

Return Value
None.

Examples
Game.ShakeCamera Game.ShakeCamera(afStrength = 0.1)
 * Shake the camera from the player's location at half strength
 * Gently shake the camera from the player's location