Cam::shakeCinematic: Difference between revisions
No edit summary |
No edit summary |
||
| Line 3: | Line 3: | ||
==Explanation== | ==Explanation== | ||
This function triggers a cinematic camera shake effect | This function triggers a cinematic camera shake effect, allowing you to specify the shake type and intensity. This can be useful for enhancing in-game events like explosions or impacts with visual effects. | ||
===Required Params=== | ===Required Params=== | ||
*'''type:''' {{RageType|string}} - | *'''type:''' {{RageType|string}} - Type of shake effect. | ||
*'''intensity:''' {{RageType|number}} - | *'''intensity:''' {{RageType|number}} - Intensity of the shake (0.0 - 1.0). | ||
===Available Shake Types=== | |||
* "HAND_SHAKE" | |||
* "SMALL_EXPLOSION_SHAKE" | |||
* "MEDIUM_EXPLOSION_SHAKE" | |||
* "LARGE_EXPLOSION_SHAKE" | |||
* "JOLT_SHAKE" | |||
* "ROAD_VIBRATION_SHAKE" | |||
* "DRUNK_SHAKE" | |||
* "VIBRATE_SHAKE" | |||
===Return value=== | ===Return value=== | ||
Latest revision as of 18:59, 5 November 2024
Client-Side Function
JavaScript Syntax
Explanation
This function triggers a cinematic camera shake effect, allowing you to specify the shake type and intensity. This can be useful for enhancing in-game events like explosions or impacts with visual effects.
Required Params
- type: string - Type of shake effect.
- intensity: number - Intensity of the shake (0.0 - 1.0).
Available Shake Types
- "HAND_SHAKE"
- "SMALL_EXPLOSION_SHAKE"
- "MEDIUM_EXPLOSION_SHAKE"
- "LARGE_EXPLOSION_SHAKE"
- "JOLT_SHAKE"
- "ROAD_VIBRATION_SHAKE"
- "DRUNK_SHAKE"
- "VIBRATE_SHAKE"
Return value
- void
Syntax
mp.game.cam.shakeCinematic(type, intensity)
Example
The following example applies a hand-held camera shake effect with medium intensity:
mp.game.cam.shakeCinematic("HAND_SHAKE", 0.5);
See also
- mp.game.cam.renderScriptS
- mp.game.cam.renderScriptCams
- mp.game.cam.stopRenderingScriptCamsUsingCatchUp
- mp.game.cam.create
- mp.game.cam.createCam
- mp.game.cam.createWithParams
- mp.game.cam.createCamWithParams
- mp.game.cam.createEra
- mp.game.cam.createCamera
- mp.game.cam.createEraWithParams
- mp.game.cam.createCameraWithParams
- mp.game.cam.destroy
- mp.game.cam.destroyAllS
- mp.game.cam.destroyAllCams
- mp.game.cam.doesExist
- mp.game.cam.setActive
- mp.game.cam.isActive
- mp.game.cam.isRendering
- mp.game.cam.getRendering
- mp.game.cam.getCoord
- mp.game.cam.getRot
- mp.game.cam.getFov
- mp.game.cam.getNearClip
- mp.game.cam.getFarClip
- mp.game.cam.getFarDof
- mp.game.cam.setParams
- mp.game.cam.setCoord
- mp.game.cam.setRot
- mp.game.cam.setFov
- mp.game.cam.setNearClip
- mp.game.cam.setFarClip
- mp.game.cam.setMotionBlurStrength
- mp.game.cam.setNearDof
- mp.game.cam.setFarDof
- mp.game.cam.setDofStrength
- mp.game.cam.setDofPlanes
- mp.game.cam.setUseShallowDofMode
- mp.game.cam.setUseHiDof
- mp.game.cam.setDofFnumberOfLens
- mp.game.cam.setDofFocalLengthMultiplier
- mp.game.cam.setDofFocusDistanceBias
- mp.game.cam.setDofMaxNearInFocusDistance
- mp.game.cam.setDofMaxNearInFocusDistanceBlendLevel
- mp.game.cam.attachToEntity
- mp.game.cam.attachToPedBone
- mp.game.cam.attachToPedBone2
- mp.game.cam.attachToVehicleBone
- mp.game.cam.detach
- mp.game.cam.setInheritRollVehicle
- mp.game.cam.pointAtCoord
- mp.game.cam.pointAtEntity
- mp.game.cam.pointAtPedBone
- mp.game.cam.stopPointing
- mp.game.cam.setAffectsAiming
- mp.game.cam.setDebugName
- mp.game.cam.addSplineNode
- mp.game.cam.addCamSplineNode
- mp.game.cam.addSplineNodeUsingCameraFrame
- mp.game.cam.addSplineNodeUsingCamera
- mp.game.cam.addSplineNodeUsingGameplayFrame
- mp.game.cam.setSplinePhase
- mp.game.cam.setCamSplinePhase
- mp.game.cam.getSplinePhase
- mp.game.cam.getSplineNodePhase
- mp.game.cam.getCamSplineNodePhase
- mp.game.cam.setSplineDuration
- mp.game.cam.setCamSplineDuration
- mp.game.cam.setSplineSmoothingStyle
- mp.game.cam.getSplineNodeIndex
- mp.game.cam.getCamSplineNodeIndex
- mp.game.cam.setSplineNodeEase
- mp.game.cam.setSplineNodeVelocityScale
- mp.game.cam.overrideSplineVelocity
- mp.game.cam.overrideCamSplineVelocity
- mp.game.cam.overrideSplineMotionBlur
- mp.game.cam.overrideCamSplineMotionBlur
- mp.game.cam.setSplineNodeExtraFlags
- mp.game.cam.isSplinePaused
- mp.game.cam.isCamSplinePaused
- mp.game.cam.setActiveWithInterp
- mp.game.cam.isInterpolating
- mp.game.cam.shake
- mp.game.cam.animatedShake
- mp.game.cam.isShaking
- mp.game.cam.setShakeAmplitude
- mp.game.cam.stopShaking
- mp.game.cam.shakeScriptGlobal
- mp.game.cam.animatedShakeScriptGlobal
- mp.game.cam.isScriptGlobalShaking
- mp.game.cam.stopScriptGlobalShaking
- mp.game.cam.playAnim
- mp.game.cam.isPlayingAnim
- mp.game.cam.setAnimCurrentPhase
- mp.game.cam.getAnimCurrentPhase
- mp.game.cam.playSynchronizedAnim
- mp.game.cam.playSynchronizedCamAnim
- mp.game.cam.setFlyHorizontalResponse
- mp.game.cam.setFlyVerticalSpeedMultiplier
- mp.game.cam.setFlyMaxHeight
- mp.game.cam.setFlyCoordAndConstrain
- mp.game.cam.isScreenFadedOut
- mp.game.cam.isScreenFadedIn
- mp.game.cam.isScreenFadingOut
- mp.game.cam.isScreenFadingIn
- mp.game.cam.doScreenFadeIn
- mp.game.cam.doScreenFadeOut
- mp.game.cam.setWidescreenBorders
- mp.game.cam.getGameplayCoord
- mp.game.cam.getGameplayRot
- mp.game.cam.getGameplayCamRot
- mp.game.cam.getGameplayFov
- mp.game.cam.getGameplayRelativeHeading
- mp.game.cam.getGameplayCamRelativeHeading
- mp.game.cam.setGameplayRelativeHeading
- mp.game.cam.setGameplayCamRelativeHeading
- mp.game.cam.getGameplayRelativePitch
- mp.game.cam.setGameplayRelativePitch
- mp.game.cam.setGameplayCamRelativePitch
- mp.game.cam.setGameplayRelativeRotation
- mp.game.cam.setGameplayRawYaw
- mp.game.cam.setGameplayCamRawYaw
- mp.game.cam.setGameplayRawPitch
- mp.game.cam.setGameplayCamRawPitch
- mp.game.cam.shakeGameplay
- mp.game.cam.shakeGameplayCam
- mp.game.cam.isGameplayShaking
- mp.game.cam.setGameplayShakeAmplitude
- mp.game.cam.setGameplayCamShakeAmplitude
- mp.game.cam.stopGameplayShaking
- mp.game.cam.stopGameplayCamShaking
- mp.game.cam.setGameplayFollowPedThisUpdate
- mp.game.cam.isGameplayRendering
- mp.game.cam.enableCrosshairThisFrame
- mp.game.cam.isGameplayLookingBehind
- mp.game.cam.disableCollisionForEntity
- mp.game.cam.disableCollisionForObject
- mp.game.cam.isSphereVisible
- mp.game.cam.isFollowPedActive
- mp.game.cam.setFollowPedThisUpdate
- mp.game.cam.setFollowPedCamCutsceneChat
- mp.game.cam.clampGameplayYaw
- mp.game.cam.clampGameplayCamYaw
- mp.game.cam.clampGameplayPitch
- mp.game.cam.clampGameplayCamPitch
- mp.game.cam.animateGameplayZoom
- mp.game.cam.animateGameplayCamZoom
- mp.game.cam.setInVehicleStateThisUpdate
- mp.game.cam.disableFirstPersonThisFrame
- mp.game.cam.getFollowPedZoomLevel
- mp.game.cam.getFollowPedViewMode
- mp.game.cam.setFollowPedViewMode
- mp.game.cam.setFollowPedCamViewMode
- mp.game.cam.isFollowVehicleActive
- mp.game.cam.getFollowVehicleZoomLevel
- mp.game.cam.setFollowVehicleZoomLevel
- mp.game.cam.setFollowVehicleCamZoomLevel
- mp.game.cam.getFollowVehicleViewMode
- mp.game.cam.setFollowVehicleViewMode
- mp.game.cam.setFollowVehicleCamViewMode
- mp.game.cam.useStuntEraThisFrame
- mp.game.cam.setGameplayHash
- mp.game.cam.setFollowTurretSeat
- mp.game.cam.isAimActive
- mp.game.cam.isAimThirdPersonActive
- mp.game.cam.isFirstPersonAimActive
- mp.game.cam.disableAimThisUpdate
- mp.game.cam.getFirstPersonAimZoomFactor
- mp.game.cam.setFirstPersonAimZoomFactor
- mp.game.cam.setFirstPersonPitchRange
- mp.game.cam.setFirstPersonAimNearClipThisUpdate
- mp.game.cam.setThirdPersonAimNearClipThisUpdate
- mp.game.cam.getFinalRenderedCoord
- mp.game.cam.getFinalRenderedRot
- mp.game.cam.getFinalRenderedInWhenFriendlyRot
- mp.game.cam.getFinalRenderedFov
- mp.game.cam.getFinalRenderedInWhenFriendlyFov
- mp.game.cam.getFinalRenderedNearClip
- mp.game.cam.getFinalRenderedFarClip
- mp.game.cam.getFinalRenderedNearDof
- mp.game.cam.getFinalRenderedFarDof
- mp.game.cam.getFinalRenderedMotionBlurStrength
- mp.game.cam.setGameplayCoordHint
- mp.game.cam.setGameplayPedHint
- mp.game.cam.setGameplayVehicleHint
- mp.game.cam.setGameplayObjectHint
- mp.game.cam.setGameplayEntityHint
- mp.game.cam.isGameplayHintActive
- mp.game.cam.stopGameplayHint
- mp.game.cam.setGameplayHintFov
- mp.game.cam.setGameplayHintFollowDistanceScalar
- mp.game.cam.setGameplayHintBaseOrbitPitchOffset
- mp.game.cam.setGameplayHintAnimOffsetx
- mp.game.cam.setGameplayHintAnimOffsety
- mp.game.cam.setGameplayHintAnimCloseup
- mp.game.cam.getIsMultiplayerBrief
- mp.game.cam.setCinematicButtonActive
- mp.game.cam.isCinematicRendering
- mp.game.cam.shakeCinematic
- mp.game.cam.shakeCinematicCam
- mp.game.cam.isCinematicShaking
- mp.game.cam.setCinematicShakeAmplitude
- mp.game.cam.setCinematicCamShakeAmplitude
- mp.game.cam.stopCinematicShaking
- mp.game.cam.stopCinematicCamShaking
- mp.game.cam.disableVehicleFirstPersonThisFrame
- mp.game.cam.invalidateVehicleIdle
- mp.game.cam.invalidateIdle
- mp.game.cam.isCinematicIdleRendering
- mp.game.cam.isInVehicleDisabled
- mp.game.cam.createCinematicShot
- mp.game.cam.isCinematicShotActive
- mp.game.cam.stopCinematicShot
- mp.game.cam.forceCinematicRenderingThisUpdate
- mp.game.cam.setCinematicModeActive
- mp.game.cam.isCinematicActive
- mp.game.cam.stopCutsceneShaking
- mp.game.cam.getFocusPedOnScreen
- mp.game.cam.setEffect
- mp.game.cam.setCamEffect
- mp.game.cam.setGameplayVehicleCamera
- mp.game.cam.setGameplayVehicleCameraName
- mp.game.cam.replayFreeGetMaxRange
- mp.game.cam.setDofParam
- mp.game.cam.getDofParam