Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

I'm making a spectate option for my game, I need it to return the camera to a part?

Asked by 5 years ago

So, this is what I'm trying to make. I'm making a option where you click on the player to spectate them. It works fine, but my game uses camera manipulation, so the camera is fixed to the part until they choose their team. When you stop spectating a player it returns your camera to the normal camera. I need it to return the camera back to the part that I am using. I'm sorry the script is soo long, I've tried modifying parts of it, but I couldn't find what I need to change. Any help will be appreciated, thanks!

01wait()
02while not script.GUI.Value do wait() end
03gui = script.GUI.Value
04playergui = gui.Parent
05player = playergui.Parent
06while not player:FindFirstChild("Backpack") do wait() end
07backpack = player.Backpack
08 
09while not player.Character do wait() end wait()
10 
11window = gui.Window
12frame = window.Frame
13 
14function stopWatching()
15    local cam = workspace.CurrentCamera
View all 95 lines...
0
I am so so sorry, this is so long. I just need all the help I can get. Mrmonkeyman120 65 — 5y

Answer this question