|
| 18 Nov 2012 11:25 AM |
This is just a key down function, when pressed it makes the camera go to the front of a car named "RAM" and while the CameraType == scriptable it continues to focus on it. Yet the camera does nothing at the while loop, just freezes where it was last as if I just set it to scriptable and did nothing else.
if key == "x" then if game.Players.LocalPlayer.Character:FindFirstChild("Car") ~= nil then if game.Players.LocalPlayer.Character.Car:FindFirstChild("RAM") ~= nil then game.Workspace.CurrentCamera.CameraType = "Scriptable" game.Players.LocalPlayer.PlayerGui["Help Guis"].Cameras.Text = "Current Camera: First Person [Ram]" Mus:Play() while game.Workspace.CurrentCamera.CameraType == "Scriptable" do --WHILE LOOP game.Workspace.CurrentCamera.CameraSubject = game.Players.LocalPlayer.Character.Car.RAM game.Workspace.CurrentCamera.CoordinateFrame = game.Players.LocalPlayer.Character.Car.RAM.CFrame end end end end |
|
|
| Report Abuse |
|
|
Xnite515
|
  |
| Joined: 18 Feb 2011 |
| Total Posts: 22763 |
|
| |
|
|
| 18 Nov 2012 11:30 AM |
I don't know for certain but I think camera type is a number. Not sure :
http://wiki.roblox.com/index.php/CameraType_(Enum) |
|
|
| Report Abuse |
|
|
|
| 18 Nov 2012 11:30 AM |
| It's a section of a script Xnite, pelase. |
|
|
| Report Abuse |
|
|
|
| 18 Nov 2012 11:32 AM |
No, you see the problem is when it's not set to CameraType "Scriptable" it can move it's position saying: game.Workspace.CurrentCamera.CameraSubject = game.Players.LocalPlayer.Character.Car.RAM game.Workspace.CurrentCamera.CoordinateFrame = game.Players.LocalPlayer.Character.Car.RAM.CFrame
But when it is set to CameraType "Scriptable" I can't edit it that way, yet I need it to follow the position of the ram. |
|
|
| Report Abuse |
|
|