πGet Groups
The basics to get Groups info.
QBCore.Functions.TriggerCallback('--:server:GetGroups', function(groups)
if groups then
for _, group in ipairs(groups.groups) do
print("Group Name: " .. group.name)
print("Leader: " .. group.leader)
end
else
print("Error")
end
end)
You can use this to later create something based on the group table, like 'if isLeader'.
Last updated