|
| 24 Feb 2017 09:24 PM |
| Hello there i am planning to make a barrier i have made a script for camera manipulation script but i want a barrier so whenever the camera zooms out it cant zoom out far only a little bit does the camera type has to be set to scriptable or do i do something with the camera i forgot how to do this due to my other scripts. |
|
|
| Report Abuse |
|
|
T0XZ
|
  |
| Joined: 22 Sep 2012 |
| Total Posts: 260 |
|
|
| 24 Feb 2017 09:46 PM |
Keep default camera go to StarterPlayer there's a setting for it
|
|
|
| Report Abuse |
|
|
|
| 24 Feb 2017 09:53 PM |
If you use the default camera setting on Player you can use MaxZoom or something: Goto the Wiki
If you set Camera to "Watch" or something it doesn't seem to work. Here is an example of stopping the camera from zooming in to close to a planet-like object. Modify it to your liking....
Local script in starter pack.
local camera = workspace.CurrentCamera local subject = camera.CameraSubject -- save local type = camera.CameraType --save
local core = Instance.new("Part", Workspace) core.CFrame = CFrame.new(Vector3.new(0,0,0)) core.Anchored = true camera.CameraSubject = core --game.Workspace.Core camera.CameraType = "Watch" camera.FieldOfView = 40
camera.Changed:connect(function (property)
--Max Zoom if (camera.CoordinateFrame.p).magnitude < 250 then camera.CoordinateFrame = CFrame.new(camera.CoordinateFrame.p.unit * 251) end
[I am looking for scripters and Artists to work on a strategy game with me. The first Hex based strategy on a globe] PM me.
|
|
|
| Report Abuse |
|
|
|
| 24 Feb 2017 10:52 PM |
hmm i was meaning something like if you play the game Auto Rap Battles 2 you notice when you zoom out you cant zoom out like normally and when you zoom in you don't go first person even if you try to
i tried MaxCameraZoomDistance didn't work play the Game Auto Rap Battles 2 and you will understand |
|
|
| Report Abuse |
|
|