Weird body gyro CFrame bug

Hello,

Trying to make a jetpack system. Here is the bit of code that deals with body gyro

    local sensitivity = 0.6		-- anything higher would make looking up and down harder; recommend anything between 0~1
	local smoothness = 0.05		-- recommend anything between 0~1

	local delta = Vector2.new(input.Delta.x/sensitivity,input.Delta.y/sensitivity) * smoothness
	
	bg.CFrame = char.LowerTorso.CFrame * CFrame.Angles(delta.Y/-10,delta.X/-10,0)

However, up and down mouse input doesnt react the way I want it to. Its like the character bounces back to straight position.

try clamping the pitch to something less than 90 degrees and -90 degrees, try like -80 and 80 when setting the cframe.

The gyro itself is in the HRP.

What do you mean by clamping the pitch? Currently, my script doesn’t clamp it at all.

are you trying to make the character face the camera?
didnt see your video until now but clamping the pitch doesnt seem like its the problem from the video so ignore that for now

here is the full script

uis.InputChanged:Connect(function (input)
if input.UserInputType == Enum.UserInputType.MouseMovement then
	cam.CameraType = "Scriptable"
	uis.MouseBehavior = Enum.MouseBehavior.LockCenter
	local sensitivity = 0.6		-- anything higher would make looking up and down harder; recommend anything between 0~1
	local smoothness = 0.05		-- recommend anything between 0~1

	local delta = Vector2.new(input.Delta.x/sensitivity,input.Delta.y/sensitivity) * smoothness
	
	bg.CFrame = hrp.CFrame * CFrame.Angles(delta.Y/-10,delta.X/-10,0)
end
end)

its using the mosuedelta from the UIS to change the gyro.

here is a better GIF

The issue was fixed by making PlatfromStand = true in the humanoid