generic image
Processing...
  • Games
  • Catalog
  • Develop
  • Robux
  • Search in Players
  • Search in Games
  • Search in Catalog
  • Search in Groups
  • Search in Library
  • Log In
  • Sign Up
  • Games
  • Catalog
  • Develop
  • Robux
   
ROBLOX Forum » Game Creation and Development » Scripting Helpers
Home Search
 

Re: Camera not working

Previous Thread :: Next Thread 
Djmann1013 is not online. Djmann1013
Joined: 17 Apr 2009
Total Posts: 1606
19 Jan 2014 11:26 AM
This script used to work but it stopped working (I think ROBLOX broke it) here is the script:

local camera = workspace.CurrentCamera
local players = script.Parent.Parent.Parent.Parent.Name
local duration = 20
local distance = 20
local part = Workspace.Cutscene.CamPart

function cutscene(camera)
print("cutscene:started")
local start = tick()
local last = camera.CameraType
camera.CameraType = "Scriptable"
while wait() do
local a = (tick()-start)/duration
if a > 1 then break end
camera.CoordinateFrame = part.CFrame*CFrame.Angles(math.rad(80)*a,0,0)*CFrame.new(0,0,distance)
end
print("cutscene:finished")
end

Basically this script is supposed to make the player camera circle around a part, it used to work but now it broke. Anyone have any idea of why this script broke?

Thanks.
Report Abuse
Djmann1013 is not online. Djmann1013
Joined: 17 Apr 2009
Total Posts: 1606
19 Jan 2014 04:24 PM
Bump1
Report Abuse
vlekje513 is not online. vlekje513
Joined: 28 Dec 2010
Total Posts: 9057
19 Jan 2014 04:26 PM
Output?
Report Abuse
fire243 is not online. fire243
Joined: 04 Apr 2010
Total Posts: 6532
19 Jan 2014 04:27 PM
local target = (Insert Part)
local camera = workspace.CurrentCamera
camera.CameraSubject = target
local angle = 0

while wait() do
camera.CoordinateFrame = CFrame.new(target.Position)
* CFrame.Angles(0, angle, 0)
* CFrame.new(0, 0, -5)
angle = angle + math.rad(1)
end

game.Workspace.CurrentCamera.CameraSubject = game.Players.LocalPlayer.Character.Humanoid
game.Workspace.CurrentCamera.CameraType = "Custom"
Report Abuse
Djmann1013 is not online. Djmann1013
Joined: 17 Apr 2009
Total Posts: 1606
19 Jan 2014 05:07 PM
There is no output for those wondering. That is why I think Roblox broke it.
Report Abuse
Previous Thread :: Next Thread 
Page 1 of 1
 
 
ROBLOX Forum » Game Creation and Development » Scripting Helpers
   
 
   
  • About Us
  • Jobs
  • Blog
  • Parents
  • Help
  • Terms
  • Privacy

©2017 Roblox Corporation. Roblox, the Roblox logo, Robux, Bloxy, and Powering Imagination are among our registered and unregistered trademarks in the U.S. and other countries.



Progress
Starting Roblox...
Connecting to Players...
R R

Roblox is now loading. Get ready to play!

R R

You're moments away from getting into the game!

Click here for help

Check Remember my choice and click Launch Application in the dialog box above to join games faster in the future!

Gameplay sponsored by:
Loading 0% - Starting game...
Get more with Builders Club! Join Builders Club
Choose Your Avatar
I have an account
generic image