On line 4 I'm getting this error: Unable to cast Array to int64. Its because :GetRoleInGroup() requires a number value and not a int64 Value but im unsure how to change a int64 value to a number value? Here is my config script: (Type: Module Script)
local TeamMetaData = {
{6283819,
{
"Guest",
"Citizen"
}
}
}
return TeamMetaData
And here is my script that gets the config, its main goal is to take that data and transfer it into teams that the player can join: (Type: Local Script)
Ranks = require(script.Parent.Parent.CONFIG)
AccesibleTeams = {}
for a, b in pairs(Ranks) do
GroupRank = game:GetService("Players").LocalPlayer:GetRoleInGroup(Ranks[a])
for c, d in pairs(Ranks[a]) do
if GroupRank == Ranks[a][c][1] then
for e = 2, #Ranks[a][c] do
table.insert(AccesibleTeams, #AccesibleTeams + 1, Ranks[a][c][e])
end
end
end
end
Please help. Thanks
