I am writing a script that is client side, that runs a remote function that returns a table. The problem is that the remote function if firing before everything in serverscriptservice is loaded. On the server side I need to reference something in serverscriptservice, sometimes it happens to work other times I get an error saying the object doesnt exist is there a way to make the local script wait until serverscriptservice if fully loaded.
Ive tried β
local object = game.ServerScriptService:FindFirstChild('object that i need')
Ive also tried β
local object = game.ServerScriptService:WaitForChild('object that i need')
and bothβ>
local object = game.ServerScriptService:WaitForChild('Object that i need') or game.ServerScriptService:FindFirstChild('object that i need')
Anyone know a way I can reference this object, or a way of making the client or server side scripts wait until serverscriptservice if fully loaded??