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

How to make this script work in "online" mode?

Asked by 10 years ago

The code works perfectly in Solo/testing, but it doesn't work in online/play mode. Can anyone help me rewrite this? (It locks first person)

wait()
local plr = game.Players.LocalPlayer
local cam = game.Workspace.CurrentCamera
local chr = nil

chr = character
plr.CameraMode = 1

while false do
wait ()
cam.CameraType = 1
cam.CoordinateFrame = CFrame.new (200,10,0)
cam.Focus = CFrame.new (200,7,500)
cam.FieldOfView = 70
end

2 answers

Log in to vote
0
Answered by
HexC3D 830 Moderation Voter
10 years ago

Change to a local script. :P

or

game.Players.LocalPlayer.CameraMode = Enum.CameraMode.LockFirstPerson -- This automatically locks in first person

You can put this as a local script and put in your StarterGear Making the person in First person instead of typing all of that. You can do the above if you want. Hope this helps :P

SourceMain

Ad
Log in to vote
0
Answered by 10 years ago

I agree with HexC3D

Answer this question