Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

Why does this only work on studio but not client?

Asked by 8 years ago

Someone told me that its a good idea to put a waitforchild thing, so i put it in then i didnt work or play in client(roblox launcher thingy)

I'm still unsure of how to work things on clients tips?

local script = script
local DebrisService = game:GetService('Debris')
local Sound1 = script:WaitForChild("Sound1")
local Sound2 = script:WaitForChild("Sound2")
local Sound3 = script:WaitForChild("Sound3")
while true do
wait(2)
Alert = script.Alert:Clone()
Alert.Parent = game.Players.LocalPlayer.PlayerGui
DebrisService:AddItem(Alert, 15)
Sound1:Play()
wait(21)
Sound2:Play()
wait(22)
Sound3:Play()
wait(60)
Message = script.Message:Clone()
Message.Parent = game.Players.LocalPlayer.PlayerGui
DebrisService:AddItem(Message, 101)
end
0
Please format your code correctly. It helps with reading it, even if it is a short code. If you don't know how, go ahead and search code formatting. It will help you later. yelsew 205 — 8y

Answer this question