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

Infinite Yield on something that exist?

Asked by 5 years ago
events = game.ServerStorage:WaitForChild('devEVENTS')

This is in a Local Script in a GUI

Why does it Infinite yield to something that exist in the ServerStorage

Picture of it in Server Storage : https://gyazo.com/186b59e05879ca48e7bfdecf04d9716c

Error Output is giving: 18:21:59.390 - Infinite yield possible on 'ServerStorage:WaitForChild("devEVENTS")' 18:21:59.391 - Stack Begin 18:21:59.391 - Script 'Players.DevsAtWork.PlayerGui.devARREST.LocalScript', Line 2 18:21:59.392 - Stack End

0
Check the name, this happened to me, I acidentally put a space at the end Ziffixture 6913 — 5y
0
That is not the issue DeveloperAtWork 14 — 5y
0
LocalScripts can't access ServerStorage's contents Amiaa16 3227 — 5y
0
so how would I go about doing this? DeveloperAtWork 14 — 5y
View all comments (2 more)
0
use a server script Gey4Jesus69 2705 — 5y
0
Lol, right, jeez i'm tired Ziffixture 6913 — 5y

1 answer

Log in to vote
0
Answered by 5 years ago
Edited 5 years ago

ServerStorage cannot be accessed by LocalScripts, it's meant for Server access only. Consider changing the storage of 'devEVENTS' to ReplicatedStorage as it can be accessed by both Server and Local scripts!

local object = game:GetService('ReplicatedStorage'):WaitForChild('ITEMNAMEHERE')

print(object.Name)
Ad

Answer this question