mirror of
https://github.com/FlightControl-Master/MOOSE.git
synced 2025-10-29 16:58:06 +00:00
Merge branch 'FlightControl-Master:master' into master
This commit is contained in:
commit
176d9df476
@ -207,7 +207,7 @@ end
|
|||||||
do -- MENU_BASE
|
do -- MENU_BASE
|
||||||
|
|
||||||
--- @type MENU_BASE
|
--- @type MENU_BASE
|
||||||
-- @extends Base#BASE
|
-- @extends Core.Base#BASE
|
||||||
|
|
||||||
--- Defines the main MENU class where other MENU classes are derived from.
|
--- Defines the main MENU class where other MENU classes are derived from.
|
||||||
-- This is an abstract class, so don't use it.
|
-- This is an abstract class, so don't use it.
|
||||||
|
|||||||
@ -308,17 +308,14 @@ do -- SET_BASE
|
|||||||
-- @return Core.Set#SET_BASE The set of objects that are in set *B* but **not** in this set *A*.
|
-- @return Core.Set#SET_BASE The set of objects that are in set *B* but **not** in this set *A*.
|
||||||
function SET_BASE:GetSetComplement(SetB)
|
function SET_BASE:GetSetComplement(SetB)
|
||||||
|
|
||||||
local complement=SET_BASE:New()
|
local complement = self:GetSetUnion(SetB)
|
||||||
|
local intersection = self:GetSetIntersection(SetB)
|
||||||
|
|
||||||
local union=self:GetSetUnion(SetA, SetB)
|
for _,Object in pairs(intersection.Set) do
|
||||||
|
complement:Remove(Object.ObjectName,true)
|
||||||
for _,Object in pairs(union.Set) do
|
|
||||||
if SetA:IsIncludeObject(Object) and SetB:IsIncludeObject(Object) then
|
|
||||||
intersection:Add(intersection)
|
|
||||||
end
|
|
||||||
end
|
end
|
||||||
|
|
||||||
return intersection
|
return complement
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@ -23,7 +23,6 @@
|
|||||||
-- @module Functional.FOX
|
-- @module Functional.FOX
|
||||||
-- @image Functional_FOX.png
|
-- @image Functional_FOX.png
|
||||||
|
|
||||||
|
|
||||||
--- FOX class.
|
--- FOX class.
|
||||||
-- @type FOX
|
-- @type FOX
|
||||||
-- @field #string ClassName Name of the class.
|
-- @field #string ClassName Name of the class.
|
||||||
@ -48,7 +47,6 @@
|
|||||||
-- @field #number dt05 Time step [sec] for missile position updates if distance to target > 5 km and < 10 km. Default 0.5 sec.
|
-- @field #number dt05 Time step [sec] for missile position updates if distance to target > 5 km and < 10 km. Default 0.5 sec.
|
||||||
-- @field #number dt01 Time step [sec] for missile position updates if distance to target > 1 km and < 5 km. Default 0.1 sec.
|
-- @field #number dt01 Time step [sec] for missile position updates if distance to target > 1 km and < 5 km. Default 0.1 sec.
|
||||||
-- @field #number dt00 Time step [sec] for missile position updates if distance to target < 1 km. Default 0.01 sec.
|
-- @field #number dt00 Time step [sec] for missile position updates if distance to target < 1 km. Default 0.01 sec.
|
||||||
-- @field #boolean
|
|
||||||
-- @extends Core.Fsm#FSM
|
-- @extends Core.Fsm#FSM
|
||||||
|
|
||||||
--- Fox 3!
|
--- Fox 3!
|
||||||
|
|||||||
@ -568,12 +568,12 @@ function GROUP:GetSpeedMax()
|
|||||||
|
|
||||||
local Units=self:GetUnits()
|
local Units=self:GetUnits()
|
||||||
|
|
||||||
local speedmax=nil
|
local speedmax=0
|
||||||
|
|
||||||
for _,unit in pairs(Units) do
|
for _,unit in pairs(Units) do
|
||||||
local unit=unit --Wrapper.Unit#UNIT
|
local unit=unit --Wrapper.Unit#UNIT
|
||||||
local speed=unit:GetSpeedMax()
|
local speed=unit:GetSpeedMax()
|
||||||
if speedmax==nil then
|
if speedmax==0 then
|
||||||
speedmax=speed
|
speedmax=speed
|
||||||
elseif speed<speedmax then
|
elseif speed<speedmax then
|
||||||
speedmax=speed
|
speedmax=speed
|
||||||
|
|||||||
@ -442,7 +442,7 @@ function UNIT:GetSpeedMax()
|
|||||||
return SpeedMax*3.6
|
return SpeedMax*3.6
|
||||||
end
|
end
|
||||||
|
|
||||||
return nil
|
return 0
|
||||||
end
|
end
|
||||||
|
|
||||||
--- Returns the unit's max range in meters derived from the DCS descriptors.
|
--- Returns the unit's max range in meters derived from the DCS descriptors.
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user