--Place the Shake event into ReplicatedStorage
--Place this into StarterPlayerScripts

local dropoff = 1.2 --how quickly you want the effect to fade away
local sway = 5

local cam = workspace.CurrentCamera
local amount

game.ReplicatedStorage.Shake.OnClientEvent:connect(function(times, number)
	amount = number
	for i = 1,times do
	for i = 1,sway do
		game:GetService("RunService").RenderStepped:wait()
		cam.CFrame = cam.CFrame * CFrame.Angles(amount,amount/2,0)
	end
	for i = 1,sway do
		game:GetService("RunService").RenderStepped:wait()
		cam.CFrame = cam.CFrame * CFrame.Angles(-amount,-amount/2,0)
	end
	amount = amount/dropoff
	end
end)






