Scripting HelpersARCHIVE
A little piece of Roblox history. Preserved for everyone, one question at a time.Read about the archive →
COMMUNITY QUESTION

Lines not working, but no errors in output? (Filtering Enabled)

The following lines of code are snipped from the original script.

The code fires when a new player joins the game. It is located within a Server-Sided script.

    local leaderstats = Instance.new("Folder")
    leaderstats.Name = "leaderstats"
    leaderstats.Parent = player
    local cash = Instance.new("NumberValue")
    cash.Name = "Cash"
    cash.Value = usercashpath
    cash.Parent = leaderstats

The problem is, the leaderstats folder is not created into the player.

3 comments

0

Anyone got a clue? I thought during Filtering Enabled conditions, a server sided script had all rights? Here it seems that it is requiring some sort of server action to create the instances.

0

I'm pretty sure you're supposed to create an "IntValue" instead of a "Folder", for both.

0

+iiMayk A folder works just fine.

1 answer

I figured out the issue, i was using FindFirstChild(), instead of :WaitForChild for usercashpath value.

This discussion is preserved as it was. New answers, comments, and votes are closed.