Skip to content

Commit

Permalink
add missing party function
Browse files Browse the repository at this point in the history
  • Loading branch information
luan committed Nov 3, 2023
1 parent 94e7095 commit 9e13b2a
Showing 1 changed file with 13 additions and 0 deletions.
13 changes: 13 additions & 0 deletions data/libs/functions/party.lua
Original file line number Diff line number Diff line change
Expand Up @@ -73,3 +73,16 @@ end
function Party.hasDruid(self)
return self:hasVocation(VOCATION.BASE_ID.DRUID)
end

function Participants(player, requireSharedExperience)
local party = player:getParty()
if not party then
return { player }
end
if requiredSharedExperience and not party:isSharedExperienceActive() then
return { player }
end
local members = party:getMembers()
table.insert(members, party:getLeader())
return members
end

0 comments on commit 9e13b2a

Please sign in to comment.