I put a text label's text through as an argument for FireAllClient, and on the server, it prints it but not on the client. I'm making a GUI and when a text changes, I need it to show up on a TextLabel to all players.
NORMAL SCRIPT VVVVVVVVVVVV
local RepStorage = game:GetService('ReplicatedStorage') local GlobalEvents = RepStorage:WaitForChild("GlobalEvents") local StatValue = RepStorage:WaitForChild("StatusValue") local TxtValueChange = GlobalEvents:WaitForChild("TxtValueChange") script.Parent.Text = StatValue.Value StatValue.Changed:connect(function() TxtValueChange:FireAllClients(script.Parent.Text) end)
LOCAL SCRIPT VVVVVVVVVVV
local RepStorage = game:GetService('ReplicatedStorage') local GlobalEvents = RepStorage:WaitForChild('GlobalEvents') local TxtValueChange = GlobalEvents:WaitForChild('TxtValueChange') local StatusValue = RepStorage:WaitForChild('StatusValue') TxtValueChange.OnClientEvent:connect(function(text) print(text) --prints nil on clients and prints the text on server text = StatusValue.Value end)