Hi, I’m scripting an overhead rank GUI for my group game but my problem is with the GetRankInGroup. I have no errors in the output but it keeps giving people the same rank (Grandmaster of the Order). Any help? I’m trying to make it so it shows their rank in the group.
Image of problem:
[Person on the right should have “Force Sensitive”
After that, you should include more details if you have any. Try to make your topic as descriptive as possible, so that it’s easier for people to help you!
--// Variables //--
local ServerStorage = game:GetService("ServerStorage")
local BillboardGui = ServerStorage:WaitForChild("BillboardGui")
--// Code //--
game.Players.PlayerAdded:Connect(function(player)
player.CharacterAdded:Connect(function(character)
local tag = BillboardGui:Clone()
tag.Parent = character.Head
--// Groups //--
local JediGroup = 5809884
local GuardianGroup = 5860534
local ConsularGroup = 5809928
local SentinelGroup = 5860245
--// NameTag //--
local NameTag = tag.NameTag
NameTag.Text = player.Name
--// RankTag //--
local RankTag = tag.RankTag
if player:GetRankInGroup(5809884) == 255 then
RankTag.Text = "Grandmaster of the Order"
elseif player:GetRankInGroup(5809884) == 254 then
RankTag.Text = "Master of the Order"
elseif player:GetRankInGroup(5809884) == 253 then
RankTag.Text = "Jedi Architect"
elseif player:GetRankInGroup(5809884) == 252 then
RankTag.Text = "Jedi High Council"
elseif player:GetRankInGroup(5809884) == 251 then
RankTag.Text = "Force Ghost"
elseif player:GetRankInGroup(5809884) == 250 then
RankTag.Text = "Jedi Master"
elseif player:GetRankInGroup(5809884) == 249 then
RankTag.Text = "Jedi Sentintel"
elseif player:GetRankInGroup(5809884) == 248 then
RankTag.Text = "Jedi Consular"
elseif player:GetRankInGroup(5809884) == 247 then
RankTag.Text = "Jedi Guardian"
elseif player:GetRankInGroup(5809884) == 246 then
RankTag.Text = "Jedi Knight"
elseif player:GetRankInGroup(5809884) == 245 then
RankTag.Text = "Padawan"
elseif player:GetRankInGroup(5809884) == 244 then
RankTag.Text = "Initiate"
elseif player:GetRankInGroup(5809884) == 243 then
RankTag.Text = "Youngling III"
elseif player:GetRankInGroup(5809884) == 242 then
RankTag.Text = "Youngling II"
elseif player:GetRankInGroup(5809884) == 241 then
RankTag.Text = "Youngling I"
elseif player:GetRankInGroup(5809884) == 240 then
RankTag.Text = "Force Sensitive"
end
end)
end)