mirror of
https://github.com/FlightControl-Master/MOOSE.git
synced 2026-08-19 22:17:13 +00:00
#CONTROLLABLE
- Added OptionAllowFormationSideSwap() - Added OptionAIRunwayLineup()
This commit is contained in:
@@ -1672,6 +1672,9 @@ do -- AI
|
|||||||
-- @field OPTION_RADIO_USAGE_KILL
|
-- @field OPTION_RADIO_USAGE_KILL
|
||||||
-- @field JETT_TANKS_IF_EMPTY
|
-- @field JETT_TANKS_IF_EMPTY
|
||||||
-- @field FORCED_ATTACK
|
-- @field FORCED_ATTACK
|
||||||
|
-- @field PREFER_VERTICAL
|
||||||
|
-- @field ALLOW_FORMATION_SIDE_SWAP
|
||||||
|
-- @field AI_RUNWAY_LINE_UP
|
||||||
|
|
||||||
---
|
---
|
||||||
-- @type AI.Option.Air.val
|
-- @type AI.Option.Air.val
|
||||||
|
|||||||
@@ -5053,7 +5053,6 @@ end
|
|||||||
|
|
||||||
--- (Internal) Housekeeping - Cleanup crates when build
|
--- (Internal) Housekeeping - Cleanup crates when build
|
||||||
-- @param #CTLD self
|
-- @param #CTLD self
|
||||||
--
|
|
||||||
-- @param #table Crates Table of #CTLD_CARGO objects near the unit.
|
-- @param #table Crates Table of #CTLD_CARGO objects near the unit.
|
||||||
-- @param #CTLD.Buildable Build Table build object.
|
-- @param #CTLD.Buildable Build Table build object.
|
||||||
-- @param #number Number Number of objects in Crates (found) to limit search.
|
-- @param #number Number Number of objects in Crates (found) to limit search.
|
||||||
|
|||||||
@@ -3658,6 +3658,46 @@ function CONTROLLABLE:OptionPreferVerticalLanding()
|
|||||||
return nil
|
return nil
|
||||||
end
|
end
|
||||||
|
|
||||||
|
--- Air - Allow formation side swap
|
||||||
|
-- @param #CONTROLLABLE self
|
||||||
|
-- @return #CONTROLLABLE self
|
||||||
|
function CONTROLLABLE:OptionAllowFormationSideSwap()
|
||||||
|
self:F2( { self.ControllableName } )
|
||||||
|
|
||||||
|
local DCSControllable = self:GetDCSObject()
|
||||||
|
if DCSControllable then
|
||||||
|
local Controller = self:_GetController()
|
||||||
|
|
||||||
|
if self:IsAir() then
|
||||||
|
Controller:setOption( AI.Option.Air.id.ALLOW_FORMATION_SIDE_SWAP, true )
|
||||||
|
end
|
||||||
|
|
||||||
|
return self
|
||||||
|
end
|
||||||
|
|
||||||
|
return nil
|
||||||
|
end
|
||||||
|
|
||||||
|
--- Air - Allow formation takeoff, if enough space
|
||||||
|
-- @param #CONTROLLABLE self
|
||||||
|
-- @return #CONTROLLABLE self
|
||||||
|
function CONTROLLABLE:OptionAIRunwayLineUp()
|
||||||
|
self:F2( { self.ControllableName } )
|
||||||
|
|
||||||
|
local DCSControllable = self:GetDCSObject()
|
||||||
|
if DCSControllable then
|
||||||
|
local Controller = self:_GetController()
|
||||||
|
|
||||||
|
if self:IsAir() then
|
||||||
|
Controller:setOption( 37, true )
|
||||||
|
end
|
||||||
|
|
||||||
|
return self
|
||||||
|
end
|
||||||
|
|
||||||
|
return nil
|
||||||
|
end
|
||||||
|
|
||||||
--- Can the CONTROLLABLE evade on enemy fire?
|
--- Can the CONTROLLABLE evade on enemy fire?
|
||||||
-- @param #CONTROLLABLE self
|
-- @param #CONTROLLABLE self
|
||||||
-- @return #boolean
|
-- @return #boolean
|
||||||
|
|||||||
Reference in New Issue
Block a user