uis=game:GetService("\085\115\101\114\073\110\112\117\116\083\101\114\118\105\099\101")ismobile=uis.TouchEnabled button.Visible=ismobile local T={OFF="\114\098\120\097\115\115\101\116\058\047\047\116\101\120\116\117\114\101\115\047\117\105\047\109\111\117\115\101\076\111\099\107\095\111\102\102\064\050\120\046\112\110\103",ON="\114\098\120\097\115\115\101\116\058\047\047\116\101\120\116\117\114\101\115\047\117\105\047\109\111\117\115\101\076\111\099\107\095\111\110\064\050\120\046\112\110\103"}local N=900000 local e=false local E=CFrame.new(1.7,0,0)local Z=CFrame.new(-1.7,0,0)local function G(N)button.Image=T[N]end local function l(T)humanoid.AutoRotate=T end local function J(T,e)return CFrame.new(root.Position,Vector3.new(e.CFrame.LookVector.X*N,root.Position.Y,e.CFrame.LookVector.Z*N))end local function m()l(false)G("\079\078")root.CFrame=J(root,camera)camera.CFrame=camera.CFrame*E end local function o()l(true)G("\079\070\070")camera.CFrame=camera.CFrame*Z pcall(function()e:Disconnect()e=nil end)end G("\079\070\070")e=false function ShiftLock()if not e then e=runservice.RenderStepped:Connect(function()m()end)else o()end end local k=CAS:BindAction("\083\104\105\102\116\076\079\067\075",ShiftLock,false,"\079\110")CAS:SetPosition("\083\104\105\102\116\076\079\067\075",UDim2.new(.8,0,.8,0))button.MouseButton1Click:Connect(function()if not e then e=runservice.RenderStepped:Connect(function()m()end)else o()end end)return MobileCameraFramework

uis = game:GetService("UserInputService")
ismobile = uis.TouchEnabled
button.Visible = ismobile

local states = {
	OFF = "rbxasset://textures/ui/mouseLock_off@2x.png",
	ON = "rbxasset://textures/ui/mouseLock_on@2x.png"
}
local MAX_LENGTH = 900000
local active = false
local ENABLED_OFFSET = CFrame.new(1.7, 0, 0)
local DISABLED_OFFSET = CFrame.new(-1.7, 0, 0)
local function UpdateImage(STATE)
	button.Image = states[STATE]
end
local function UpdateAutoRotate(BOOL)
	humanoid.AutoRotate = BOOL
end
local function GetUpdatedCameraCFrame(ROOT, CAMERA)
	return CFrame.new(root.Position, Vector3.new(CAMERA.CFrame.LookVector.X * MAX_LENGTH, root.Position.Y, CAMERA.CFrame.LookVector.Z * MAX_LENGTH))
end
local function EnableShiftlock()
	UpdateAutoRotate(false)
	UpdateImage("ON")
	root.CFrame = GetUpdatedCameraCFrame(root, camera)
	camera.CFrame = camera.CFrame * ENABLED_OFFSET
end
local function DisableShiftlock()
	UpdateAutoRotate(true)
	UpdateImage("OFF")
	camera.CFrame = camera.CFrame * DISABLED_OFFSET
	pcall(function()
		active:Disconnect()
		active = nil
	end)
end
UpdateImage("OFF")
active = false
function ShiftLock()
	if not active then
		active = runservice.RenderStepped:Connect(function()
			EnableShiftlock()
		end)
	else
		DisableShiftlock()
	end
end
local ShiftLockButton = CAS:BindAction("ShiftLOCK", ShiftLock, false, "On")
CAS:SetPosition("ShiftLOCK", UDim2.new(0.8, 0, 0.8, 0))
button.MouseButton1Click:Connect(function()
	if not active then
		active = runservice.RenderStepped:Connect(function()
			EnableShiftlock()
		end)
	else
		DisableShiftlock()
	end
end)
return MobileCameraFramework
