First prototype of task dispatching with menu

This commit is contained in:
FlightControl
2016-07-08 16:16:48 +02:00
parent 6ba6390b5d
commit 0c13744309
16 changed files with 51775 additions and 162 deletions

View File

@@ -109,6 +109,14 @@ UNIT = {
-- @field Orange
-- @field Blue
--- Unit.SensorType
-- @type Unit.SensorType
-- @field OPTIC
-- @field RADAR
-- @field IRST
-- @field RWR
-- Registration.
--- Create a new UNIT from DCSUnit.
@@ -334,6 +342,23 @@ end
-- Need to add here a function per sensortype
-- unit:hasSensors(Unit.SensorType.RADAR, Unit.RadarType.AS)
--- Returns if the unit has sensors of a certain type.
-- @param Unit#UNIT self
-- @return #boolean returns true if the unit has specified types of sensors. This function is more preferable than Unit.getSensors() if you don't want to get information about all the unit's sensors, and just want to check if the unit has specified types of sensors.
-- @return #nil The DCS Unit is not existing or alive.
function UNIT:HasSensors( ... )
self:F2( arg )
local DCSUnit = self:GetDCSObject()
if DCSUnit then
local HasSensors = DCSUnit:hasSensors( unpack( arg ) )
return HasSensors
end
return nil
end
--- Returns two values:
--
-- * First value indicates if at least one of the unit's radar(s) is on.