How would you get the owner of a group?

This might not make sense but I’m trying to find out how to get the owner of a group via a script, for example, if the game is published to a group, how would you get the groups owner? It’s to check to see if the owner of the group owns a gamepass

local GroupId = 1
local Owner = game:GetService("GroupService"):GetGroupInfoAsync(GroupId).Owner

print(Owner.Name, Owner.Id)
1 Like

It works, thank you for your help.

1 Like

For anyone who wants to check if a player in their game is the group owner instead of getting the group owner use:
Player:GetRankInGroup()

local GroupId = 1

if Player:GetRankInGroup(GroupId) >= 255 then
    print(Player.Name .. " is the owner of the group!")
end

didnt think of that lol thanks

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.