New Event Dispatching based on priorities

-- First _DATABASE
-- then SETS
-- then the rest
-- changed AIRBASEPOLICE
This commit is contained in:
FlightControl
2017-02-03 22:18:51 +01:00
parent 33af2b4f95
commit ab345f5ad2
13 changed files with 291 additions and 71 deletions

View File

@@ -234,14 +234,14 @@ end
-- If the Unit is part of the Task, true is returned.
-- @param #TASK self
-- @param Wrapper.Unit#UNIT PlayerUnit The CLIENT or UNIT of the Player joining the Mission.
-- @param Wrapper.Group#GROUP PlayerGroup The GROUP of the player joining the Mission.
-- @return #boolean true if Unit is part of the Task.
function TASK:JoinUnit( PlayerUnit )
self:F( { PlayerUnit = PlayerUnit } )
function TASK:JoinUnit( PlayerUnit, PlayerGroup )
self:F( { PlayerUnit = PlayerUnit, PlayerGroup = PlayerGroup } )
local PlayerUnitAdded = false
local PlayerGroups = self:GetGroups()
local PlayerGroup = PlayerUnit:GetGroup()
-- Is the PlayerGroup part of the PlayerGroups?
if PlayerGroups:IsIncludeObject( PlayerGroup ) then
@@ -394,7 +394,6 @@ end
-- @return #boolean
function TASK:HasGroup( FindGroup )
self:GetGroups():FilterOnce() -- Ensure that the filter is updated.
return self:GetGroups():IsIncludeObject( FindGroup )
end