Help with EZ Camera Shake

Hey, i have a problem with the EZ Camera Shake Module.

I’ve made it so when the player takes damage, a little camera shake will play.
Inside Roblox Studio it works fine, however when i tested it in the actual Roblox game, the camera shake was not noticeable at all, barely even visible.

Studio:

Roblox game:

Does anyone have any idea why this happens?

2 Likes

Code, sir, code… we can’t magically guess where the bug is without you sharing how you used the module

1 Like

Main script:

local ReplicatedStorage = game:GetService("ReplicatedStorage")
local CameraShakeModule = require(ReplicatedStorage.OtherModules.CameraShaker)

local CameraShake = CameraShakeModule.new(Enum.RenderPriority.Camera.Value, function(shakeCF)
	Camera.CFrame = Camera.CFrame * shakeCF
end)
CameraShake:Start()

PlayCameraShake.OnClientEvent:Connect(function(EffectName: string)
	if CameraShake.Presets[EffectName] then
		CameraShake:Shake(CameraShake.Presets[EffectName])
	end	
end)

I fire the event everytime I need to have the camera shake.

1 Like

The module is probably unfortunately dependent of FPS. Not sure how to fix it unless you edit it using some “delta” time stuff but I’ve never tried this.

You’d confirm when changing your in-game fps while you’re in your game

1 Like

There didnt seem to be a change when I changed the FPS cap.

And both, Studio and the actual game, run on the same amount of FPS.

1 Like

oh well in that case I have absolutely -9 knowledge of what’s wrong, sorry.

1 Like

I fixed it.
Just had to increase the RenderPriority.

local CameraShake = CameraShakeModule.new(Enum.RenderPriority.Camera.Value + 1, function(shakeCF)
	Camera.CFrame = Camera.CFrame * shakeCF
end)

CameraShake:Start()
2 Likes