here is the script

when fired the root part is supposed to face the cam's "lookvector"" but it dosent…….

local remote = game.ReplicatedStorage.onlockon


remote.OnServerEvent:Connect(function(plr,camera)
	
	local char = plr.Character or plr.CharacterAdded:wait()
	
	local hum = char:WaitForChild("Humanoid")
		
	char.HumanoidRootPart.CFrame = CFrame.new(char.HumanoidRootPart.Position + Vector3.new(camera.lookVector.x,0,camera.lookVector.z))	
		

end)

similar to shift lock but with the cams look vector...….

[EDITED]

it looks like this: https://gyazo.com/a6a7890cc98e333e99c10a41bff631e7

10 comments

0

is it firing? add a print after the connect to confirm that its firing and connecting as well.

0

Yes It Fires

0

is it connecting.

0

yes but when I press Shift to Fire it , the Character doent face where the camera is.it jsut faces backwards or a random direction.....

0

this part is off:char.HumanoidRootPart.CFrame = CFrame.new(char.HumanoidRootPart.Position + Vector3.new(camera.lookVector.x,0,camera.lookVector.z))

0

try something like: CFrame = CFramePosition * CFrame.Angles

0

when locked on the black frames come down :D

0

Change the CFrame of the character on the client since client movement is replicated.

0

Oh really?

0

perhaps: CFrame.new(Vector3 pos, Vector3 lookAt) as opposed to CFrame.new(Vector3pos + Vector3lookat) ?