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

Did something just change because my server cant access StarterGear?

Asked by 6 years ago

so when they click the button it sells the item and removes it from their backpack and startergear, however it seems in the real server (not studio) it removes the tool from the backpack but cant remove from the startergear. it says it returns nil.

please help, and thank you.

    newslot.MouseButton1Click:connect(function() -- does this when clicked
        local lookforname = player.Backpack:FindFirstChild(tools[i].Name) -- looks for the tool name in backpack
        if lookforname then -- once it finds the tool it adds the sell value to the players gold
            player.leaderstats.Gold.Value = (player.leaderstats.Gold.Value) + (tools[i].sellPrice.Value)
            newslot:Destroy()
            local item2destroyfromBackpack = player.Backpack:FindFirstChild(tools[i].Name)
            item2destroyfromBackpack:Destroy()
            local item2destroyfromStarterGear = player.StarterGear:FindFirstChild(tools[i].Name)
            item2destroyfromStarterGear:Destroy()
0
I believe they changed the name to StarterPack User#16405 0 — 6y
0
well, the StarterPack goes to every player on the server's backpack, im only looking to remove it from the one player who sold the item PoePoeCannon 519 — 6y

Answer this question