Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
2

How to set Camera Min/MaxZoom?

Asked by 10 years ago

I was on the roblox wiki and was scrolling around inside the player properties section and I came across the CameraMinZoomDistance and CameraMaxZoomDistance, the page didn't have anything other than

"The minimum distance the player's camera is allowed to zoom in.", "The maximum distance the player's camera is allowed to zoom out."

After that I thought I should try to use it to lock the players camera at a certain zoom so I did

local plr = game.Players.LocalPlayer

plr.CameraMinZoomDistance = 15
plr.CameraMaxZoomDistance = 20

This didn't affect the camera for me whatsoever so that leads me to this where I ask how do I make it that the zoom can be set using that or does it not work as of right now?

NOTE: I used a server script as well as a local, both outputted nothing, they were located in the Starter Gui

2 answers

Log in to vote
2
Answered by 10 years ago

You can do Workspace.CurrentCamera.CameraType='Scriptable' if you're wanting to keep the camera in once place, but you will have to script it to follow the character around and such.

EDIT: You will have to use a LocalScript to be able to access Workspace.CurrentCamera

0
Yeah I already knew that, I just wanted to find a simple way to do it. Thanks for helping though. VariadicFunction 335 — 10y
Ad
Log in to vote
-1
Answered by
Exudo 13
10 years ago

I believe the ROBLOX team has removed CameraMinZoomDistance and CameraMaxZoomDistance due to glitches.

0
Alright thanks VariadicFunction 335 — 10y

Answer this question