Issue Type: Display
Impact: High
Frequency: Constantly
Date First Experienced: 2021-04-01 00:04:00 (+01:00)
Date Last Experienced: 2021-04-14 00:04:00 (+01:00)
Reproduction Steps:
I have created a simple repro file. In StarterPlayerScripts there is a local script that contains the following code:
wait(1)
local camBlock = workspace.CameraPart
workspace.CurrentCamera.CameraSubject = camBlock
workspace.CurrentCamera.CFrame = camBlock.CFrame
workspace.CurrentCamera.CameraType = Enum.CameraType.Watch
The wait is vital for the repro to work. In my production game, there is no wait but instead the code is triggered by a remote event fired by the server. Removing the wait from this script (or even reducing it to just a wait()) doesn’t trigger the issue.
If you remove the wait, you will be able to spectate the block - but this is incorrect behaviour. Instead the camera should be fixed in place and unable to move. This is the behaviour that this code has exhibited since at least January 2020. It has only my come to my attention in the last few days that the code errors on every frame. I do not know exactly when it started to happen.
CameraRepro.rbxl (21.9 KB)
Expected Behavior:
This is the correct behaviour, but has errors in the output
This is incorrect behaviour (I can rotate the camera around the part) but there are no errors
Actual Behavior:
Output is spammed with output on every frame.
This appears also to be interfering with changing lighting on the client, as all the maps I am making the camera focus on are completely dark until the camera switches back to normal. (I assume because this error is preventing other local scripts from firing correctly)
Aside from the lighting not working properly in my production game, the code still functions correctly and the camera is fixed looking at an invisible part (my use case) whereby the player is unable to rotate the camera, as intended.
Workaround: