I will in a temporary gamre. 444
ok rejoin, i removed the sound
Can you try disabling the MouseButton1Click
.
once again, it flickers. nothing past thart.
i will try this script in the workspace:
local camera = workspace.CurrentCamera
while wait() do
camera.CameraType = Enum.CameraType.Scriptable
end
Can you show where the button script is located?
But this should have worked. Do you think this is a roblox bug?
Possibly. Nothing isw rong with my script, and Roblox’s email support is absolutely NO help.
Also are you sure the cam part is anchored and can collide is off?
CanCollide is on, and it’s anchored
This is my LocalScript in my game, I adapted it for you.
I wish this work…
wait(1)
print("camera")
local camera = workspace.CurrentCamera
local cameraPart = workspace:WaitForChild("campart1")
camera.CameraSubject = workspace.campart1
camera.CameraType = Enum.CameraType.Scriptable
camera.CFrame = workspace.campart1.CFrame
print("done")
That’s some weird behaviour right there what I suggest is looping the camera CFrame change until it actually takes place
print "camera"
local camera = workspace.CurrentCamera
local cameraPart = workspace:WaitForChild("campart1") -- Add The Camera Part There
repeat wait()
camera.CameraType = Enum.CameraType.Scriptable
camera.CFrame = cameraPart.CFrame
until camera.CameraType == Enum.CameraType.Scriptable and camera.CFrame == cameraPart.CFrame
camera.CFrame = cameraPart.CFrame
print "done"
I must bump this topic. This is still an unsolved issue.
Have you tried making the script wait until the character is loaded? By that time the camera should be editable like that.
Here’s a solution for you. I tested this and it worked for me in studio and when the game was published.
Here’s the code:
print "starting camera move script"
local player = game.Players.LocalPlayer
local camera = workspace.CurrentCamera
local cameraPart = workspace:WaitForChild("campart1") -- Add The Camera Part There
print("Campart found")
if player.Character then --Checking to see if the player already has a Character
print("Character already exists")
else --runs if player.Character returns nil
print("Character doesn't exist, waiting...")
player.CharacterAdded:Wait() --Waiting for the character to be added
end
camera.CameraType = Enum.CameraType.Scriptable
camera.CFrame = cameraPart.CFrame
print("done")
It seems like you’ve been stuck on this for a while now, so hopefully this can be the end of this thread.
One last note, you can edit your button script and remove the line disabling this script since there is no longer an infinite loop present that would repeatedly move the camera. It is generally inadvisable to use an infinite loop for something like that. In most situations, there is some event you can wait for, or if you really need to, you can just use the “wait()” function and wait a few seconds before running lines of code.
Are you sure you don’t have another script that is changing the camera source? You should definitely check for any other scripts that are changing something.
Try changing this variable to
local camera = workspace.Camera