mirror of
https://github.com/FlightControl-Master/MOOSE.git
synced 2025-10-29 16:58:06 +00:00
a2a-dispatcher: add check for not in air in OnEventEngineShutdown
This fixes the problem of planes owned by gcicap would immediately despawn when shot causing their engine to quit. While not ultimately satisfying as planes shot while taxiing will still immediately despawn. One is now able to see their air victories in all their glory, including the fiery crash into the ground. Bug: 932 Signed-off-by: Jonathan Toppins <jtoppins@users.sourceforge.net>
This commit is contained in:
parent
3ed9555705
commit
169dcfe3f6
@ -1049,7 +1049,8 @@ do -- AI_A2A_DISPATCHER
|
||||
if Squadron then
|
||||
self:F( { SquadronName = Squadron.Name } )
|
||||
local LandingMethod = self:GetSquadronLanding( Squadron.Name )
|
||||
if LandingMethod == AI_A2A_DISPATCHER.Landing.AtEngineShutdown then
|
||||
if LandingMethod == AI_A2A_DISPATCHER.Landing.AtEngineShutdown and
|
||||
not DefenderUnit:InAir() then
|
||||
local DefenderSize = Defender:GetSize()
|
||||
if DefenderSize == 1 then
|
||||
self:RemoveDefenderFromSquadron( Squadron, Defender )
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user