webturne
(Nocturne)
October 1, 2023, 3:23pm
1
I am trying to make a main menu using cameras, however, when I try changing it, it literally doesn’t work.
local Player = game.Players.LocalPlayer
local Camera = game.Workspace.Camera
local MenuCamera = game.Workspace:WaitForChild("MainMenuCamera")
Camera.CameraType = Enum.CameraType.Scriptable
Camera.CFrame = MenuCamera.CFrame
Camera.FieldOfView = 50
^ Script above
The FOV changes, the positioning doesn’t.
3 Likes
RCW3993
(rcw)
October 1, 2023, 3:28pm
2
Camera, on line 2, should be workspace.CurrentCamera
webturne
(Nocturne)
October 1, 2023, 3:29pm
3
Unfortunately, that didn’t work.
RCW3993
(rcw)
October 1, 2023, 3:30pm
4
MainMenuCamera is a part and this is a local script correct?
11trat
(Trat)
October 1, 2023, 3:31pm
5
CurrentCamera is the camera at the current frame, but using Camera is a legitimate way of controlling it too. Also sometimes it’s even better, since you don’t have to update camera every single frame
webturne
(Nocturne)
October 1, 2023, 3:32pm
6
Mhm, it definitely is. (stupid character limit thing)
RCW3993
(rcw)
October 1, 2023, 3:32pm
7
I tested the original code, and it worked fine for me.
RCW3993
(rcw)
October 1, 2023, 3:32pm
8
I had a local script in starterpack and made a part called MainMenuCamera in workspace. That’s your setup?
webturne
(Nocturne)
October 1, 2023, 3:33pm
9
No, the camera script is in StarterPlayerScripts
11trat
(Trat)
October 1, 2023, 3:33pm
10
What is the MenuCamera? Also do you have any other things named “camera” in the workspace?
webturne
(Nocturne)
October 1, 2023, 3:34pm
11
No, I specifically called it MainMenuCamera, there’s nothing else with the same name.
RCW3993
(rcw)
October 1, 2023, 3:34pm
12
Set it up exactly like this. It’s working for me.
11trat
(Trat)
October 1, 2023, 3:36pm
14
Is “MainMenuCamera” anchored? Else it will just fall through a baseplate.
RCW3993
(rcw)
October 1, 2023, 3:36pm
15
no errors right? 303030303003030
webturne
(Nocturne)
October 1, 2023, 3:36pm
16
It’s anchored, and collisions are off.
webturne
(Nocturne)
October 1, 2023, 3:37pm
17
Nope. (I DO NOT CARE ABOUT THE CHARACTER LIMIT!)
11trat
(Trat)
October 1, 2023, 3:38pm
18
Show the explorer view with the script and the part
RCW3993
(rcw)
October 1, 2023, 3:38pm
19
Camera thingy.rbxl (53.1 KB)
This is the place file that works.