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: How to completely reset the camera?

Previous Thread :: Next Thread 
MrEpic534 is not online. MrEpic534
Joined: 12 May 2012
Total Posts: 1349
16 Nov 2014 04:22 AM
Player = game.Players.LocalPlayer
run = game:GetService("RunService")

c = game.Workspace.Camera
c.CameraType = "Scriptable"

pos = Vector3.new(0, 50, -50)
Targ = game.Workspace.Sword.Handle.Position
f = -50

for i = 1, 100 do
f = f + 1
pos = Vector3.new(0, 50, f)
c.CoordinateFrame = CFrame.new(pos, Targ)
run.Stepped:wait(0.1)
end
c.CameraType = "Custom" <-------------- This here it doesnt return the camera to normal*
NewPos = Vector3.new(0,0,0)
NewTarg = Player.Character.Torso.Position

c.CoordinateFrame = CFrame.new(NewPos,NewTarg)
*Even after i repositioned the camera to the torso it still looks like scriptable because i can move the camera around but it doesnt stick to the player
Report Abuse
themajestikst is not online. themajestikst
Joined: 19 Dec 2012
Total Posts: 137
16 Nov 2014 04:41 AM
game.Workspace.Camera:remove()
Report Abuse
HarrySnotte is not online. HarrySnotte
Joined: 27 Jun 2011
Total Posts: 2854
16 Nov 2014 05:02 AM
game.Workspace.CurrentCamera.CameraSubject = player.Character.Humanoid

and of course set it back to "Custom", but you already did that :)
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