mirror of
https://github.com/FlightControl-Master/MOOSE.git
synced 2025-10-29 16:58:06 +00:00
Fixed the landing bug
When using A2A GCICAP, the planes would land, but not dissapear.
This commit is contained in:
@@ -1,5 +1,5 @@
|
|||||||
--BASE:TraceClass("AI_A2A_DISPATCHER")
|
--BASE:TraceClass("AI_A2A_DISPATCHER")
|
||||||
BASE:TraceClass("AI_A2A_GCICAP")
|
--BASE:TraceClass("AI_A2A_GCICAP")
|
||||||
|
|
||||||
--- **AI** - The AI_A2A_DISPATCHER creates an automatic A2A defense system based on an EWR network targets and coordinating CAP and GCI.
|
--- **AI** - The AI_A2A_DISPATCHER creates an automatic A2A defense system based on an EWR network targets and coordinating CAP and GCI.
|
||||||
--
|
--
|
||||||
@@ -818,6 +818,7 @@ do -- AI_A2A_DISPATCHER
|
|||||||
--- @param #AI_A2A_DISPATCHER self
|
--- @param #AI_A2A_DISPATCHER self
|
||||||
-- @param Core.Event#EVENTDATA EventData
|
-- @param Core.Event#EVENTDATA EventData
|
||||||
function AI_A2A_DISPATCHER:OnEventLand( EventData )
|
function AI_A2A_DISPATCHER:OnEventLand( EventData )
|
||||||
|
self:F( "Landed" )
|
||||||
local DefenderUnit = EventData.IniUnit
|
local DefenderUnit = EventData.IniUnit
|
||||||
local Defender = EventData.IniGroup
|
local Defender = EventData.IniGroup
|
||||||
local Squadron = self:GetSquadronFromDefender( Defender )
|
local Squadron = self:GetSquadronFromDefender( Defender )
|
||||||
@@ -2945,6 +2946,12 @@ do
|
|||||||
|
|
||||||
self:__Start( 5 )
|
self:__Start( 5 )
|
||||||
|
|
||||||
|
self:HandleEvent( EVENTS.Crash, self.OnEventCrashOrDead )
|
||||||
|
self:HandleEvent( EVENTS.Dead, self.OnEventCrashOrDead )
|
||||||
|
|
||||||
|
self:HandleEvent( EVENTS.Land )
|
||||||
|
self:HandleEvent( EVENTS.EngineShutdown )
|
||||||
|
|
||||||
return self
|
return self
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|||||||
@@ -872,7 +872,7 @@ function EVENT:onEvent( Event )
|
|||||||
for EventClass, EventData in pairs( self.Events[Event.id][EventPriority] ) do
|
for EventClass, EventData in pairs( self.Events[Event.id][EventPriority] ) do
|
||||||
|
|
||||||
if Event.IniObjectCategory ~= Object.Category.STATIC then
|
if Event.IniObjectCategory ~= Object.Category.STATIC then
|
||||||
--self:E( { "Evaluating: ", EventClass:GetClassNameAndID() } )
|
self:E( { "Evaluating: ", EventClass:GetClassNameAndID() } )
|
||||||
end
|
end
|
||||||
|
|
||||||
Event.IniGroup = GROUP:FindByName( Event.IniDCSGroupName )
|
Event.IniGroup = GROUP:FindByName( Event.IniDCSGroupName )
|
||||||
|
|||||||
Reference in New Issue
Block a user