mirror of
https://github.com/FlightControl-Master/MOOSE.git
synced 2025-10-29 16:58:06 +00:00
AIRBOSS v0.9.1
This commit is contained in:
File diff suppressed because it is too large
Load Diff
@@ -266,7 +266,7 @@ RECOVERYTANKER.version="1.0.3"
|
||||
-- TODO list
|
||||
-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
|
||||
|
||||
-- TODO: Is alive check for tanker necessary?
|
||||
-- DONE: Is alive check for tanker necessary?
|
||||
-- DONE: Seamless change of position update. Get good updated waypoint and update position if tanker position is right. Not really possiple atm.
|
||||
-- DONE: Check if TACAN mode "X" is allowed for AA TACAN stations. Nope
|
||||
-- DONE: Check if tanker is going back to "Running" state after RTB and respawn.
|
||||
@@ -708,6 +708,24 @@ function RECOVERYTANKER:IsStopped()
|
||||
return self:is("Stopped")
|
||||
end
|
||||
|
||||
--- Alias of tanker spawn group.
|
||||
-- @param #RECOVERYTANKER self
|
||||
-- @return #string Alias of the tanker.
|
||||
function RECOVERYTANKER:GetAlias()
|
||||
return self.alias
|
||||
end
|
||||
|
||||
--- Get unit name of the spawned tanker.
|
||||
-- @param #RECOVERYTANKER self
|
||||
-- @return #string Name of the tanker unit or nil if it does not exist.
|
||||
function RECOVERYTANKER:GetUnitName()
|
||||
local unit=self.tanker:GetUnit(1)
|
||||
if unit then
|
||||
return unit:GetName()
|
||||
end
|
||||
return nil
|
||||
end
|
||||
|
||||
-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
|
||||
-- FSM states
|
||||
-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
|
||||
|
||||
@@ -651,6 +651,17 @@ function RESCUEHELO:GetAlias()
|
||||
return self.alias
|
||||
end
|
||||
|
||||
--- Get unit name of the spawned helo.
|
||||
-- @param #RESCUEHELO self
|
||||
-- @return #string Name of the helo unit or nil if it does not exist.
|
||||
function RESCUEHELO:GetUnitName()
|
||||
local unit=self.helo:GetUnit(1)
|
||||
if unit then
|
||||
return unit:GetName()
|
||||
end
|
||||
return nil
|
||||
end
|
||||
|
||||
-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
|
||||
-- EVENT functions
|
||||
-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
|
||||
@@ -909,7 +920,7 @@ function RESCUEHELO:onafterStatus(From, Event, To)
|
||||
-- Report current fuel.
|
||||
local text=string.format("Rescue Helo %s: state=%s fuel=%.1f", self.helo:GetName(), self:GetState(), fuel)
|
||||
MESSAGE:New(text, 10, "DEBUG"):ToAllIf(self.Debug)
|
||||
self:E(self.lid..text)
|
||||
self:T(self.lid..text)
|
||||
|
||||
if self:IsRunning() then
|
||||
|
||||
|
||||
Reference in New Issue
Block a user