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

How can I make a Group Rank Gui Leaderboard?

So here is the script:

game.Players.PlayerAdded:connect(function(player)
	
local folder = Instance.new("Folder",player)
folder.Name = "leaderstats"

	
	
local rank = Instance.new("IntValue",folder)
rank.Name = "School Rank"
rank.Value = player:GetRoleInGroup(1084573) -- put group id in parentheses	

	
end)

Now, how can I make it where the custom gui knows the rank. And Here is another script that makes the text to know the username and the rank but how do I make it where it's a group rank?

while wait{} do
	local player = game.Players.LocalPlayer
	script.Parent.Text ="Rank".. player:GetRoleInGroup("leaderstats"):FindFirstChild("Rank").Value
	
end

And here is a photo I did to make a gui Group rank leaderboard:

https://gyazo.com/f323c744816862abe85148975cda5b8d https://gyazo.com/d375a6e43362fab0bb875cb1f7022fbd

1 answer

✓ Accepted answer

On line 3 in the second script you tried using GetRoleInGroup to find the directory of the value

It should just be:

script.Parent.Text = "Rank"..player("leaderstats"):FindFirstChild("Rank").Value

1 comment

0

Thank you this works!

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