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

Some buttons I tried to move/Destroy won't get removed?

So, I tried to move/destroy those locks who are on my GUI (for people who are in the group, they will be moved/ else than that, the locks will stay.)

local Locks = script.Parent.Frame.locks
    game.Players.PlayerAdded:Connect(function(plr)
    if plr:IsInGroup(4937707) then
    Locks:Destroy()
    print("Worked")
end
end)

.. Thank you for reading

1 answer

✓ Accepted answer

Local script

local Locks = script.Parent.Frame.locks
if game.Players.LocalPlayer:IsInGroup(4937707) then
    Locks:Destroy()
    print("Worked")
end

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