I have the refuel again working for the AI_A2A_DISPATCHER.

And the status checks are again functional for CAP and GCI!
This commit is contained in:
FlightControl
2018-10-01 20:29:33 +02:00
parent d037614861
commit 8f6a3d5c49
5 changed files with 6 additions and 8 deletions

View File

@@ -400,7 +400,6 @@ end
-- @param #string Event The Event string.
-- @param #string To The To State string.
function AI_A2A:onafterStart( Controllable, From, Event, To )
self:F2()
self:__Status( 10 ) -- Check status status every 30 seconds.
@@ -423,8 +422,6 @@ end
--- @param #AI_A2A self
function AI_A2A:onafterStatus()
self:F( " Checking Status" )
if self.Controllable and self.Controllable:IsAlive() then
local RTB = false
@@ -452,7 +449,7 @@ function AI_A2A:onafterStatus()
if not self:Is( "Fuel" ) and not self:Is( "Home" ) then
local Fuel = self.Controllable:GetFuelMin()
self:F({Fuel=Fuel})
self:F({Fuel=Fuel, PatrolFuelThresholdPercentage=self.PatrolFuelThresholdPercentage})
if Fuel < self.PatrolFuelThresholdPercentage then
if self.TankerName then
self:E( self.Controllable:GetName() .. " is out of fuel: " .. Fuel .. " ... Refuelling at Tanker!" )