When I try to print the amount of objects in a table, it works. in a server and a local scripts, but if I do the same thing after putting the table variable through a remote event, it breaks.
Server Script:
local proximityPrompt = script.Parent.ProximityPrompt
local NPC = script.Parent.Parent.Head
local RS = game:GetService("ReplicatedStorage")
local RE = RS.RemoteEvents
local Chat = RE.Chat
local waittime = 3
local chats = {"test123","bruh","gaming"}
proximityPrompt.Triggered:Connect(function(player)
Chat:FireClient(player, chats, waittime, NPC)
end)
LocalScript:
local RS = game:GetService("ReplicatedStorage")
local RE = RS.RemoteEvents
local Chaz = RE.Chat
local function ChatFired(plr, chats, waittime, NPC)
print(#chats)
end
Chaz.OnClientEvent:Connect(ChatFired)