Hello everyone! I’m trying to make a Camera Main menu script,
but for some reason, when I have “CharacterAutoLoad” turned off, it doesn’t seem to render parts in workspace?
I’ve tried looking for solutions in the Dev Wiki but I couldn’t find anything.
I don’t know if it has to do anything with the script or just studio in general,
local plr = game.Players.LocalPlayer
local mouse = plr:GetMouse()
local replicatedStorage = game:GetService("ReplicatedStorage")
local cam = workspace.CurrentCamera
local camPart = workspace:WaitForChild("campartPlay")
local PlayButton = script.Parent:WaitForChild("PlayButton")
repeat
wait()
cam.CameraType = Enum.CameraType.Scriptable
print("lol")
until cam.CameraType == Enum.CameraType.Scriptable
PlayButton.MouseButton1Click:Connect(function()
--local respawnEvent = replicatedStorage:WaitForChild("RespawnRemote")
--respawnEvent:FireServer()
end)
local maxTilt = 10
game:GetService("RunService").RenderStepped:Connect(function()
cam.CFrame = camPart.CFrame * CFrame.Angles(
math.rad((((mouse.Y - mouse.ViewSizeY / 2) / mouse.ViewSizeY)) * -maxTilt),
math.rad((((mouse.X - mouse.ViewSizeX / 2) / mouse.ViewSizeX)) * -maxTilt),
0
)
end)
Thank you!