Hey there! I always want to give my players the best quality.
As a main menu for my upcoming game, GRIEF, and i wanted the camera to switch to different scenes, to attract players. However, after testing the menu out on my phone, i have encountered a problem. Sometimes, the cameras do not go their designated destination i set (probably because of lag) and make the game look unprofessional.
An example is Camera 6 going to Camera 2 with the Animation
Here is the local script:
local camera = workspace.CurrentCamera
local Camera1 = workspace:WaitForChild(“Camera1”)
local Camera2 = workspace:WaitForChild(“Camera2”)
local Camera3 = workspace:WaitForChild(“Camera3”)
local Camera4 = workspace:WaitForChild(“Camera4”)
local Camera5 = workspace:WaitForChild(“Camera5”)
local Camera6 = workspace:WaitForChild(“Camera6”)
local TweenService = game:GetService(“TweenService”)
local TweenInformation = TweenInfo.new(4, Enum.EasingStyle.Linear, Enum.EasingDirection.In, 0, false, 0)
repeat wait()
camera.CameraType = Enum.CameraType.Scriptable
until camera.CameraType == Enum.CameraType.Scriptable
local goal1 = {CFrame = Camera2.CFrame}
local Animation1 = TweenService:Create(camera,TweenInformation,goal1)
local goal2 = {CFrame = Camera4.CFrame}
local Animation2 = TweenService:Create(camera,TweenInformation,goal2)
local goal3 = {CFrame = Camera6.CFrame}
local Animation3 = TweenService:Create(camera,TweenInformation,goal3)
while true do
camera.CFrame = Camera1.CFrame
wait()
Animation1:Play()
wait(4.03)
camera.CFrame = Camera5.CFrame
Animation3:Play()
wait(4.03)
end
If you would like a video (of how the menu looks without the problem) please let me know.
Any help would be much appreciated! ![]()