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 » Scripters
Home Search
 

Re: Camera troubles

Previous Thread :: Next Thread 
ElectoStriking is not online. ElectoStriking
Joined: 10 May 2014
Total Posts: 1547
15 Mar 2016 12:16 PM
Can anyone help me fix this script, gives no errors?

local cam = workspace.CurrentCamera
local head = game.Workspace.Solitude.Head
local look1 = game.Workspace.Part1
local look2 = game.Workspace.Part2
local main = game.Workspace.Part3
cam.CameraType = Enum.CameraType.Scriptable

function Turn()
cam.CFrame = CFrame.new (main.Position, head.Position)
wait(0.5)
--Look left
cam:Interpolate(look1.CFrame,look2.CFrame,2)
wait(4.5)
--Look forwards
cam:Interpolate(main.CFrame, head.CFrame,1)
wait(3)
--Look right
cam:Interpolate(main.CFrame,look1.CFrame,2)
wait(4.5)
--Look forwards
cam:Interpolate(main.CFrame, head.CFrame,1)
wait (2)
end

Turn()

--[[while wait(math.random(5,20)) do
Turn()
end]]




#Strikin'
Report Abuse
ElectoStriking is not online. ElectoStriking
Joined: 10 May 2014
Total Posts: 1547
15 Mar 2016 01:49 PM
b



#Strikin'
Report Abuse
ElectoStriking is not online. ElectoStriking
Joined: 10 May 2014
Total Posts: 1547
16 Mar 2016 12:04 PM
bump



#Strikin'
Report Abuse
62GB is not online. 62GB
Joined: 03 Oct 2011
Total Posts: 4157
16 Mar 2016 12:27 PM
interpolate

is

broken

try lerp with the camera?
Report Abuse
ElectoStriking is not online. ElectoStriking
Joined: 10 May 2014
Total Posts: 1547
16 Mar 2016 12:32 PM
its says

lerp is not a valid member of Camera



#Strikin'
Report Abuse
62GB is not online. 62GB
Joined: 03 Oct 2011
Total Posts: 4157
16 Mar 2016 12:37 PM
If I do remember correctly,

for i = 1,100 do
cam.CFrame = cam.CFrame:lerp(cam.CFrame,ENDPOS,i/10)
wait()
end
Report Abuse
ElectoStriking is not online. ElectoStriking
Joined: 10 May 2014
Total Posts: 1547
16 Mar 2016 01:01 PM
all im trying to do is turn the view of the camera 90 degrees a few times, that would move the camera



#Strikin'
Report Abuse
62GB is not online. 62GB
Joined: 03 Oct 2011
Total Posts: 4157
16 Mar 2016 01:11 PM
Ah sorry, here:

for i = 1,100 do
cam.CFrame = cam.CFrame:lerp(cam.CFrame,ENDPOS,i/100)
wait()
end

Anyway, this should work. Try it out and see if it works for your liking. Then you can modify the focus of the camera whilst this is running, just put it in a new coroutine maybe? Or modify the focus in this for loop.
Report Abuse
ElectoStriking is not online. ElectoStriking
Joined: 10 May 2014
Total Posts: 1547
16 Mar 2016 02:18 PM
ayy I tweaked it and it worked :D thanks a bunch bro



#Strikin'
Report Abuse
62GB is not online. 62GB
Joined: 03 Oct 2011
Total Posts: 4157
16 Mar 2016 02:20 PM
Np
Report Abuse
Previous Thread :: Next Thread 
Page 1 of 1
 
 
ROBLOX Forum » Game Creation and Development » Scripters
   
 
   
  • 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