Pastefi mark
Untitled
/4fab8fd2
Paste view
NONE PUBLIC 30 views
4fab8fd2
2026-01-08 13:56:03
Loading local Players = game:GetService("Players")
local RunService = game:GetService("RunService")

local player = Players.LocalPlayer
local camera = workspace.CurrentCamera
local button = script.Parent
local on = false

button.MouseButton1Click:Connect(function()
	on = not on
	button.Text = on and "SHIFT ON" or "SHIFT"
end)

RunService.RenderStepped:Connect(function()
	if on and player.Character then
		local hrp = player.Character:FindFirstChild("HumanoidRootPart")
		if hrp then
			local look = camera.CFrame.LookVector
			hrp.CFrame = CFrame.new(
				hrp.Position,
				hrp.Position + Vector3.new(look.X, 0, look.Z)
			)
		end
	end
end)

Comments (0)

Log in to leave a comment.

No comments yet.