Hello, So, I want to make the player’s camera flip by 180 degrees, using the Remote Events, but It won’t work.
Here’s the Script:
local ReplicatedStorage = game:GetService("ReplicatedStorage")
local Lighting = game:GetService("Lighting")
local Events = ReplicatedStorage:WaitForChild("Events")
local FlipCam = Events:WaitForChild("FlipCam")
local ColorCorrection = Lighting:FindFirstChild("ColorCorrection")
while task.wait() do
ColorCorrection.Contrast = -2.5
FlipCam:FireAllClients(180)
task.wait(1.5)
ColorCorrection.Contrast = 0.5
FlipCam:FireAllClients(-180)
task.wait(1.5)
end
and the Local Script:
local ReplicatedStorage = game:GetService("ReplicatedStorage")
local RunService = game:GetService("RunService")
local Events = ReplicatedStorage:WaitForChild("Events")
local FlipCam = Events:WaitForChild("FlipCam")
local Camera = workspace.CurrentCamera
RunService.RenderStepped:Connect(function()
FlipCam.OnClientEvent:Connect(function(angles)
Camera.CFrame = Camera.CFrame * CFrame.Angles(0, 0, math.rad(angles))
end)
end)
Any help is appreciated, thanks.