I’ve been trying to figure out how many games such as Weaponry (displayed bellow) makes these sort of screenshake, if anyone has any sort of idea PLS let me know
I tried offsetting the camera towards the magazine/handle a little and didnt achieve what I really looked for.. I presume it uses CFrames
This is a port from Unity, and it’s been around for a long time, done many ways.
Here is my version of it, revamped a bit. This is a setup file with all you need.
There is a test file in this too. No explanation needed. Drag-and-drop setup. Shaker.rbxm (8.2 KB)
As a heads-up, I got it to work by adding a part (CameraBone for example) to my character then making the camera’s CFrame be affected relative to the difference in orientation between the character’s Torso and CameraBone.
Here’s how it looks:
local cameraBone = char:WaitForChild('CameraBone')
local m6dCamera = Instance.new('Motor6D')
m6dCamera.Parent = torso
m6dCamera.Part0 = torso
m6dCamera.Part1 = cameraBone
m6dCamera.Name = 'CamBone'
m6dCamera.C0 = CFrame.new(0, 2, 0)
local OldCamCF = cameraBone.CFrame:ToObjectSpace(hrp.CFrame)
local function updateCam()
local NewCamCF = cameraBone.CFrame:ToObjectSpace(torso.CFrame)
local updatedCF = NewCamCF:ToObjectSpace(OldCamCF)
cam.CFrame *= updatedCF
OldCamCF = NewCamCF
end
runService.RenderStepped:Connect(function(delta)
if hum.Health > 0 and char:FindFirstChild("Torso") then
updateCam()
end
end)
Then, you can add a rig and do the same setup as your character (adding a CameraBone) then animate the orientation