So I am trying to pass a value from a Script to a LocalScript using a RemoteEvent. So you click a button and an event is fired. Once the LocalScript detects that it then proceeds to run, though I get the following error: "Unable to cast value to Object"
Script
local Active = false
ButtonEvent:FireClient(Active)
LocalScript
ButtonEvent.OnClientEvent:Connect(function(Active)
I am probably being stupid, but I am not 100% with functions yet, so any help is appreciated.

1 comment
maybe u have this in ur script but do game:GetService("ReplicatedStorage"):WaitForChild("ButtonEvent") on both of them