Ok so, it works the first time you join the game, but the tools will break once you are respawned.
help? Current script:
game.Players.PlayerAdded:connect(function(p) p.CharacterAdded:connect(function() RN = p:GetRankInGroup("group id here") if RN == 5 then --Change 5 to the rank game.Lighting.Operator:Clone().Parent = p.Backpack end end) end)
Try this.
groupid = 1 game.Players.PlayerAdded:connect(function(p) p.CharacterAdded:wait() RN = p:GetRankInGroup(groupid) if RN == 5 then game.Lighting.Operator:clone().Parent = player.Backpack game.Lighting.Operator:clone().Parent = player.StarterGear end end)
First of all, you need the group ID. For the backpack, it might not have loaded fully, so use the wait for child method there it will wait until backpack shows.
Edit; the group Id shouldn't be in quotes.
game.Players.PlayerAdded:connect(function(p) p.CharacterAdded:connect(function() RN = p:GetRankInGroup(group id here) --PUT GROUP ID HERE. if RN == 5 then --Is this your rank in the group? If not, you won't get the tools. game.Lighting.Operator:Clone().Parent = p:WaitForChild("Backpack") end end) end)