#CONTROLLABLE

- Added OptionAllowFormationSideSwap()
- Added OptionAIRunwayLineup()
This commit is contained in:
Applevangelist
2026-02-06 16:26:56 +01:00
parent 1781f5e7d6
commit 1830b4c752
3 changed files with 43 additions and 1 deletions
@@ -3658,6 +3658,46 @@ function CONTROLLABLE:OptionPreferVerticalLanding()
return nil
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?
-- @param #CONTROLLABLE self
-- @return #boolean