I try to do this but it don't work people still can click it and no script errors comes up
game.Players.PlayerAdded:connect(function(plr)
if plr:GetRankInGroup(2752658) >= 175 then
script.Parent.ClickDetector.MouseClick:connect(onClicked)
end
end)
I try to do this but it don't work people still can click it and no script errors comes up
game.Players.PlayerAdded:connect(function(plr)
if plr:GetRankInGroup(2752658) >= 175 then
script.Parent.ClickDetector.MouseClick:connect(onClicked)
end
end)
This is just a script inside of a button in a ScreenGui in StarterGui, if you move the button you'll have to change the amount of parents on "plr", there's probably another way to do it but that's how I do it.
local plr = script.Parent.Parent.Parent.Parent
script.Parent.MouseButton1Click:connect(function()
if plr:GetRankInGroup(2752658) >= 175 then
--your code here
end
end)
This discussion is preserved as it was. New answers, comments, and votes are closed.
2 comments
What do you mean by 'a button group ranked'
people have to be in a certen group rank for the button to work