i need help to make a camera for a show i need it to be like a screen gui on the side of the screen ans when u press it u can see throught the camera
✓ ANSWER ACCEPTED
how do i make a camera with a screen gui button?
1 answer
✓ Accepted answer
ViewportFrames are not out yet in prod of Client, only stuck for Studio with no ETA on release, so I wouldn't count on them. I think what you mean is moving the camera to a new location when you click.
You can do this in your localscript in your gui Button
local button = script.Parent
local player = game.Players.LocalPlayer
local camera = game.Workspace.CurrentCamera
button.MouseButton1Click:Connect(function()
camera.CameraType = "Scriptable"
camera.CFrame = CFrame.new(0,0,0) * CFrame.new()-- Change these co-ordinates to the position you want the camera to be at.
camera.Focus=CFrame.new(10,10,10) -- Set this to the position where you want the camera to look at from the original position. So, it would look in the direction from 0,0,0 to 10,0,10.
end)
3 comments
3
I wouldn't suggest using strings for properties like cameratype, I'd recommend using enums instead. Enum.CameraType.Scriptable
0
this is from 4 months ago u do realize...
0
I never knew Alvinblox used this site?!
This discussion is preserved as it was. New answers, comments, and votes are closed.

1 comment
Viewport frames were introduced not very long ago.