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

script isn't finding the path even if it exists?

Asked by 4 years ago

I know this has happened to people before, this always makes me stop developing because of its annoyance...

local p = script.Parent.Parent.Parent.Parent.Parent
local pn = p.Name
local f = game.ServerStorage.PlayerData:FindFirstChild('Store'):FindFirstChild(pn)
if f.Setting1.Value == true then
    --script

I always get an error of something like

attempt to index upvalue 'f' (a nil value)
0
try to use WaitForChild instead of FindFirstChild and see if anything changes mybituploads 304 — 4y

1 answer

Log in to vote
0
Answered by 4 years ago

"try to use WaitForChild instead of FindFirstChild and see if anything changes"

Credit: mybituploads

Ad

Answer this question