Can you pass a function as a tuple argument when you fire a remote event from the server to the client? The first piece of code is on the client and the second is on the server. The error is “attempt to call a nil value”.
requestAction.OnClientEvent:Connect(function(action)
print(action == nil) --prints true
action() --this line errors
end)
local saturationChange = function()
print("gak")
local colorCorrection = game.Lighting.ColorCorrection
print("glook")
colorCorrection.Saturation = -2
print("glimp")
wait(0.5)
print("dj")
colorCorrection.Saturation = 0
print("jd")
end
requestAction:FireClient(player, saturationChange)