Hiya! I am making a first person game, but I don't want people to be able to look up and down, i have tried searching everywhere, but I couldn't find a clear answer, Basically I want to (using RunRenderStepped) Set it so the pitch of the currentcamera is always 0, All help is appreciated!

I have tried using CFrame, but even with the wiki at hand, I still couldn't figure anything out, My current script is this, if it helps (*it has nothing about the pitch atm)

--

local RunService = game:GetService("RunService");
local Player = game.Players.LocalPlayer;
local Character = Player.Character or Player.CharacterAdded:Wait();

RunService.RenderStepped:Connect(function()
	for i, part in pairs(Character:GetChildren()) do
		if string.match(part.Name, "Arm") or string.match(part.Name, "Hand") then
			part.LocalTransparencyModifier = 0
		end
	end
end)

--

Sorry if this is coming off as a request, its not, all I need is a basic rundown.

2 comments

0

Try making a while loop and keep the value at 0

0

yes, but like how? also renderstepped is faster.