Cizox
|
  |
| Joined: 25 Dec 2009 |
| Total Posts: 42220 |
|
|
| 20 Mar 2016 09:31 PM |
im trying to create a script that makes the camera rotate around an object top down at an angle. unfortunately im not that good at trig so the camera isnt working properly. here is the script;
local target = workspace.Level.PlayingField local camera = workspace.CurrentCamera camera.CameraType = Enum.CameraType.Scriptable camera.CameraSubject = target camera.CoordinateFrame = CFrame.new(0, 100, 0) * CFrame.Angles(math.rad(-70), 0, 0) local angle = 0
while wait() do camera.CoordinateFrame = camera.CoordinateFrame * CFrame.fromEulerAnglesXYZ(0, math.rad(1/6), 0) end
the camera instead rotates in place upwards. any help would be appreciated |
|
|
| Report Abuse |
|
|
Laakari
|
  |
| Joined: 07 Aug 2014 |
| Total Posts: 17362 |
|
|
| 20 Mar 2016 09:42 PM |
I would help you but I just started my trig class like 6 weeks ago xD
I've held off for a few years on learning angles until recently, I'm curious to find the answer to your problem as well.
|
|
|
| Report Abuse |
|
|
c9_io
|
  |
| Joined: 15 Feb 2014 |
| Total Posts: 2642 |
|
|
| 20 Mar 2016 10:11 PM |
| On mobile so can't help anyway but don't use coordinate frame but use camera.CFrame |
|
|
| Report Abuse |
|
|
Cizox
|
  |
| Joined: 25 Dec 2009 |
| Total Posts: 42220 |
|
| |
|
Cizox
|
  |
| Joined: 25 Dec 2009 |
| Total Posts: 42220 |
|
| |
|