local t=Instance.new("\080\097\114\116",owner.Character.Head)t.Size=Vector3.new(.1,.1,.1)t.Transparency=1 t.CanCollide=false t.Name="\099\097\109\101\114\097"t:BreakJoints()local U=Instance.new("\087\101\108\100",t)U.Part0=owner.Character.Head U.Part1=t U.C0=CFrame.new(0,0,-1)cangoup=true rolling=false while(game:GetService("\082\117\110\083\101\114\118\105\099\101")).RenderStepped:wait()do if(workspace.CurrentCamera.CFrame.p-t.Position).magnitude<=1.7 then(game:GetService("\080\108\097\121\101\114\115")).LocalPlayer.Character.HumanoidRootPart.CFrame=CFrame.new((game:GetService("\080\108\097\121\101\114\115")).LocalPlayer.Character.HumanoidRootPart.Position,Vector3.new(mouse.Hit.p.x,(game:GetService("\080\108\097\121\101\114\115")).LocalPlayer.Character.HumanoidRootPart.Position.y,mouse.Hit.p.z))workspace.CurrentCamera.FieldOfView=80 for t,U in pairs(owner.Character:GetChildren())do if U.ClassName=="\080\097\114\116"or U.ClassName=="\077\101\115\104\080\097\114\116"and U.Name~="\072\101\097\100"then U.LocalTransparencyModifier=0 end if U.ClassName=="\065\099\099\101\115\115\111\114\121"then U.Handle.Transparency=1 end end if owner.Character.Head:findFirstChildOfClass("\068\101\099\097\108")then(owner.Character.Head:findFirstChildOfClass("\068\101\099\097\108")).Transparency=1 end owner.Character.Head.Transparency=1 workspace.CurrentCamera.CameraSubject=t else for t,U in pairs(owner.Character:GetChildren())do if U.ClassName=="\065\099\099\101\115\115\111\114\121"then U.Handle.Transparency=0 end end workspace.CurrentCamera.FieldOfView=70 owner.Character.Head.Transparency=0 if owner.Character.Head:findFirstChildOfClass("\068\101\099\097\108")then(owner.Character.Head:findFirstChildOfClass("\068\101\099\097\108")).Transparency=0 end workspace.CurrentCamera.CameraSubject=owner.Character end end
--owner.CameraMode = "LockFirstPerson"
local part = Instance.new("Part", owner.Character.Head)
part.Size = Vector3.new(0.1, 0.1, 0.1)
part.Transparency = 1
part.CanCollide = false
part.Name = "camera"
part:BreakJoints()
local weld = Instance.new("Weld", part)
weld.Part0 = owner.Character.Head
weld.Part1 = part
weld.C0 = CFrame.new(0, 0, -1)
cangoup = true
rolling = false
while game:GetService("RunService").RenderStepped:wait() do
	if (workspace.CurrentCamera.CFrame.p - part.Position).magnitude <= 1.7 then
		game:GetService("Players").LocalPlayer.Character.HumanoidRootPart.CFrame = CFrame.new(
			game:GetService("Players").LocalPlayer.Character.HumanoidRootPart.Position,
			Vector3.new(
				mouse.Hit.p.x,
				game:GetService("Players").LocalPlayer.Character.HumanoidRootPart.Position.y,
				mouse.Hit.p.z
			)
		)
		workspace.CurrentCamera.FieldOfView = 80
		for i, v in pairs(owner.Character:GetChildren()) do
			if v.ClassName == "Part" or v.ClassName == "MeshPart" and v.Name ~= "Head" then
				v.LocalTransparencyModifier = 0
			end
			if v.ClassName == "Accessory" then
				v.Handle.Transparency = 1
			end
		end
		if owner.Character.Head:findFirstChildOfClass("Decal") then
			owner.Character.Head:findFirstChildOfClass("Decal").Transparency = 1
		end
		owner.Character.Head.Transparency = 1
		workspace.CurrentCamera.CameraSubject = part
	else
		for i, v in pairs(owner.Character:GetChildren()) do
			if v.ClassName == "Accessory" then
				v.Handle.Transparency = 0
			end
		end
		workspace.CurrentCamera.FieldOfView = 70
		owner.Character.Head.Transparency = 0
		if owner.Character.Head:findFirstChildOfClass("Decal") then
			owner.Character.Head:findFirstChildOfClass("Decal").Transparency = 0
		end
		workspace.CurrentCamera.CameraSubject = owner.Character
	end
end
