Shoulder Camear Won't Stay In Correct Position

You can write your topic however you want, but you need to answer these questions:

  1. What do you want to achieve?

I am trying to have a shoulder camera where the camera stays put off the players shoulder and focuses on a part.

  1. What is the issue? Include screenshots / videos if possible!

The camera not only doesn’t stay in place to the players torso with the offset, the player is able to walk away out of view.

local Players = game:GetService("Players")
local UserInputService = game:GetService("UserInputService")
local camera = workspace.CurrentCamera
local player = Players.LocalPlayer

character = player.CharacterAdded:Wait()

while true do
	workspace.CurrentCamera.CameraType = Enum.CameraType.Scriptable
    local lockon =character:WaitForChild("UpperTorso").Position+,2,-10)
	camera.CFrame = , workspace.aiming.Position)
	UserInputService.MouseBehavior = Enum.MouseBehavior.LockCurrentPosition


I am not sure why the camera isn’t staying according to where I put the cframe with the offset.

External Media

Can you send some footage so i know what you are talking about?

Yes I just uploaded I forgot to do that at first should be at the end now

We have to make some adjustments first, change while true do to game[“Run Service”].RenderStepped, which is way better, try fiddling around with the position and offset, stuff like that, currently I have to go, try the things I said above and if you dont find a solution, maybe refer to a roblox developer discord server to help you.

1 Like

yeah been trying that will keep trying thanks

local Game = game
local Workspace = workspace
local RunService = Game:GetService("RunService")
local Players = Game:GetService("Players")
local Player = Players.LocalPlayer
local Character = Player.Character or Player.CharacterAdded:Wait()
local Camera = Workspace.CurrentCamera
local offset =
local rootPart = Character:WaitForChild("UpperTorso")

local function OnRenderStep()
	local part = workspace.aiming
	local char =  Character
	local charCF = char:GetPrimaryPartCFrame()
	local direction = ((part.Position - charCF.Position) *,0,1)) +, charCF.Position.Y,0)
	local newCF = CFrame.lookAt(charCF.Position, charCF.Position + direction,,1,0))
	Camera.CameraType = Enum.CameraType.Scriptable
	Camera.CFrame = *, 4, 13), workspace.aiming.Position)   


Fixed after trying some other things.

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.