Cameras
Key RequiredUniversal

Cameras

Universal ScriptGeniusofABGeniusofAB 2.3K views 71 executesUpdated Apr 14, 2025
5.0/ 5(1 votes)
10100% Positive
Lua Script•140 lines (4753 chars)
local Players = game:GetService("Players")
local player = Players.LocalPlayer
local mouse = player:GetMouse()
local Camera = workspace.CurrentCamera

local cams = {}
local maxCameras = 10
local currentCamIndex = nil

local screenGui = Instance.new("ScreenGui", player:WaitForChild("PlayerGui"))
screenGui.Name = "CameraSystemMobile"

local tabletButton = Instance.new("TextButton", screenGui)
tabletButton.Size = UDim2.new(0, 120, 0, 50)
tabletButton.Position = UDim2.new(0, 10, 1, -60)
tabletButton.Text = "Открыть камеры"
tabletButton.BackgroundColor3 = Color3.fromRGB(50, 50, 50)
tabletButton.TextColor3 = Color3.new(1, 1, 1)

local cameraList = Instance.new("Frame", screenGui)
cameraList.Size = UDim2.new(0, 200, 0, 300)
cameraList.Position = UDim2.new(0, 10, 1, -370)
cameraList.BackgroundColor3 = Color3.fromRGB(40, 40, 40)
cameraList.Visible = false

local cameraListLayout = Instance.new("UIListLayout", cameraList)
cameraListLayout.SortOrder = Enum.SortOrder.LayoutOrder
cameraListLayout.Padding = UDim.new(0, 5)

local closeList = Instance.new("TextButton", cameraList)
closeList.Size = UDim2.new(1, -10, 0, 30)
closeList.Text = "Закрыть"
closeList.BackgroundColor3 = Color3.fromRGB(100, 0, 0)
closeList.TextColor3 = Color3.new(1, 1, 1)
closeList.LayoutOrder = -1
closeList.MouseButton1Click:Connect(function()
	cameraList.Visible = false
end)

local controlFrame = Instance.new("Frame", screenGui)
controlFrame.Size = UDim2.new(0, 160, 0, 160)
controlFrame.Position = UDim2.new(1, -170, 1, -170)
controlFrame.BackgroundColor3 = Color3.fromRGB(30, 30, 30)
controlFrame.Visible = false

local function createControl(name, text, pos, callback)
	local btn = Instance.new("TextButton", controlFrame)
	btn.Size = UDim2.new(0, 50, 0, 50)
	btn.Position = pos
	btn.Text = text
	btn.BackgroundColor3 = Color3.fromRGB(70, 70, 70)
	btn.TextColor3 = Color3.new(1, 1, 1)
	btn.Font = Enum.Font.SourceSansBold
	btn.TextScaled = true
	btn.MouseButton1Click:Connect(callback)
end

createControl("Up", "↑", UDim2.new(0.33, 0, 0, 0), function()
	if currentCamIndex and cams[currentCamIndex] then
		cams[currentCamIndex].CFrame *= CFrame.Angles(-math.rad(5), 0, 0)
		Camera.CFrame = cams[currentCamIndex].CFrame + cams[currentCamIndex].CFrame.LookVector
	end
end)

createControl("Down", "↓", UDim2.new(0.33, 0, 1, -50), function()
	if currentCamIndex and cams[currentCamIndex] then
		cams[currentCamIndex].CFrame *= CFrame.Angles(math.rad(5), 0, 0)
		Camera.CFrame = cams[currentCamIndex].CFrame + cams[currentCamIndex].CFrame.LookVector
	end
end)

createControl("Left", "←", UDim2.new(0, 0, 0.5, -25), function()
	if currentCamIndex and cams[currentCamIndex] then
		cams[currentCamIndex].CFrame *= CFrame.Angles(0, -math.rad(5), 0)
		Camera.CFrame = cams[currentCamIndex].CFrame + cams[currentCamIndex].CFrame.LookVector
	end
end)

createControl("Right", "→", UDim2.new(1, -50, 0.5, -25), function()
	if currentCamIndex and cams[currentCamIndex] then
		cams[currentCamIndex].CFrame *= CFrame.Angles(0, math.rad(5), 0)
		Camera.CFrame = cams[currentCamIndex].CFrame + cams[currentCamIndex].CFrame.LookVector
	end
end)

tabletButton.MouseButton1Click:Connect(function()
	cameraList.Visible = not cameraList.Visible
end)

local placeTool = player.Backpack:FindFirstChild("PlaceCamera")
if not placeTool then
	placeTool = Instance.new("Tool")
	placeTool.Name = "PlaceCamera"
	placeTool.RequiresHandle = false
	placeTool.Parent = player.Backpack
end

placeTool.Activated:Connect(function()
	if #cams >= maxCameras then return end
	local hit = mouse.Hit
	if hit then
		local part = Instance.new("Part", workspace)
		part.Size = Vector3.new(1, 1, 1)
		part.Anchored = true
		part.CanCollide = false
		part.Position = hit.p
		part.Name = "CamPart"

		local camIndex = #cams + 1
		table.insert(cams, part)

		local btn = Instance.new("TextButton", cameraList)
		btn.Size = UDim2.new(1, -10, 0, 30)
		btn.Text = "Камера " .. camIndex
		btn.BackgroundColor3 = Color3.fromRGB(80, 80, 80)
		btn.TextColor3 = Color3.new(1, 1, 1)

		btn.MouseButton1Click:Connect(function()
			if cams[camIndex] then
				currentCamIndex = camIndex
				Camera.CameraType = Enum.CameraType.Scriptable
				Camera.CFrame = cams[camIndex].CFrame + cams[camIndex].CFrame.LookVector
				controlFrame.Visible = true
				cameraList.Visible = false
			end
		end)
	end
end)

local resetButton = Instance.new("TextButton", controlFrame)
resetButton.Size = UDim2.new(1, 0, 0, 30)
resetButton.Position = UDim2.new(0, 0, 1, -30)
resetButton.Text = "Выйти"
resetButton.BackgroundColor3 = Color3.fromRGB(120, 0, 0)
resetButton.TextColor3 = Color3.new(1, 1, 1)
resetButton.MouseButton1Click:Connect(function()
	currentCamIndex = nil
	Camera.CameraType = Enum.CameraType.Custom
	controlFrame.Visible = false
end)

Features & Information

Add cameras to everything game Добавляет камеры в любые плейсы
#Universal#Free

Community Comments (1)

Script_legacyScript_legacyApr 14, 2025

qsfjcnqscfibna

More Scripts for Universal Scripts