Merge pull request #577 from FlightControl-Master/562-AI-A2A-Dispatcher

562 ai a2a dispatcher
This commit is contained in:
Sven Van de Velde 2017-06-14 11:09:25 +02:00 committed by GitHub
commit 95ce44f2d8
26 changed files with 483 additions and 109 deletions

View File

@ -4,5 +4,6 @@
<listEntry value="org.eclipse.ui.externaltools.launchGroup"/>
</listAttribute>
<stringAttribute key="org.eclipse.ui.externaltools.ATTR_LOCATION" value="${workspace_loc:/Moose_Framework/Utils/GenerateDocumentations.bat}"/>
<stringAttribute key="org.eclipse.ui.externaltools.ATTR_TOOL_ARGUMENTS" value="*.lua"/>
<stringAttribute key="org.eclipse.ui.externaltools.ATTR_WORKING_DIRECTORY" value="${workspace_loc:/Moose_Framework/Utils}"/>
</launchConfiguration>

View File

@ -23,7 +23,12 @@ do -- AI_A2A_DISPATCHER
--- # AI\_A2A\_DISPATCHER class, extends @{Tasking#DETECTION_MANAGER}
--
-- The @{#AI\_A2A\_DISPATCHER} class is designed to create an automatic air defence system for a coalition.
-- ![Banner Image](..\Presentations\AI_A2A_DISPATCHER\Dia1.JPG)
--
-- The @{#AI_A2A_DISPATCHER} class is designed to create an automatic air defence system for a coalition.
--
-- ![Banner Image](..\Presentations\AI_A2A_DISPATCHER\Dia3.JPG)
--
-- It includes automatic spawning of Combat Air Patrol aircraft (CAP) and Ground Controlled Intercept aircraft (GCI) in response to enemy air movements that are detected by a ground based radar network.
-- CAP flights will take off and proceed to designated CAP zones where they will remain on station until the ground radars direct them to intercept detected enemy aircraft or they run short of fuel and must return to base (RTB). When a CAP flight leaves their zone to perform an interception or return to base a new CAP flight will spawn to take their place.
-- If all CAP flights are engaged or RTB then additional GCI interceptors will scramble to intercept unengaged enemy aircraft under ground radar control.
@ -40,13 +45,21 @@ do -- AI_A2A_DISPATCHER
--
-- The @{#AI_A2A_DISPATCHER.New}() method is used to setup the EWR network and to define the grouping.
--
-- ### 1.1. Define the EWR network:
-- ### 1.1. Define the **EWR network**:
--
-- As part of the AI\_A2A\_DISPATCHER constructor, an EWR network must be given as the first parameter.
-- An EWR network, or, Early Warning Radar network, is used to early detect potential airborne targets and to understand the position of patrolling targets of the enemy.
--
-- ![Banner Image](..\Presentations\AI_A2A_DISPATCHER\Dia5.JPG)
--
-- Typically EWR networks are setup using 55G6 EWR, 1L13 EWR, Hawk sr and Patriot str ground based radar units.
-- These radars have different ranges and 55G6 EWR and 1L13 EWR radars are Eastern Bloc units (eg Russia, Ukraine, Georgia) while the Hawk and Patriot radars are Western (eg US).
-- Additionally, ANY other radar capable unit can be part of the EWR network! Also AWACS airborne units, planes, helicopters can help to detect targets, as long as they have radar.
-- The position of these units is very important as they need to provide enough coverage
-- to pick up enemy aircraft as they approach so that CAP and GCI flights can be tasked to intercept them.
-- to pick up enemy aircraft as they approach so that CAP and GCI flights can be tasked to intercept them.
--
-- ![Banner Image](..\Presentations\AI_A2A_DISPATCHER\Dia7.JPG)
--
-- Additionally in a hot war situation where the border is no longer respected the placement of radars has a big effect on how fast the war escalates.
-- For example if they are a long way forward and can detect enemy planes on the ground and taking off
-- they will start to vector CAP and GCI flights to attack them straight away which will immediately draw a response from the other coalition.
@ -54,8 +67,8 @@ do -- AI_A2A_DISPATCHER
-- therefore less CAP and GCI flights will spawn and this will tend to make just the border area active rather than a melee over the whole map.
-- It all depends on what the desired effect is.
--
-- EWR networks are dynamically constructed, that is, they form part of the @{Set#SET_GROUP} object that is given as the input parameter of the AI\_A2A\_DISPATCHER class.
-- By defining in a smart way the names or name prefixes of the groups of EWR capable units, these units will be automatically added or deleted from the EWR network,
-- EWR networks are **dynamically constructed**, that is, they form part of the @{Set#SET_GROUP} object that is given as the input parameter of the AI\_A2A\_DISPATCHER class.
-- By defining in a **smart way the names or name prefixes of the groups** of EWR capable units, these units will be **automatically added or deleted** from the EWR network,
-- increasing or decreasing the radar coverage of the Early Warning System.
--
-- See the following example to setup an EWR network containing EWR stations and AWACS.
@ -73,6 +86,9 @@ do -- AI_A2A_DISPATCHER
-- **DetectionSetGroup** is then being configured to filter all active groups with a group name starting with **DF CCCP AWACS** or **DF CCCP EWR** to be included in the Set.
-- **DetectionSetGroup** is then being ordered to start the dynamic filtering. Note that any destroy or new spawn of a group with the above names will be removed or added to the Set.
-- The **DetectionSetGroup** variable is then passed to the @{#AI_A2A_DISPATCHER.New}() method to indicate the EWR network configuration and setup the A2A defense detection mechanism.
--
-- ### 1.2. Define the detected **target grouping radius**:
--
-- As a second parameter of the @{#AI_A2A_DISPATCHER.New}() method, 30000 indicates that detected targets need to be grouped within a radius of 30km.
-- The grouping radius should not be too small, but also depends on the types of planes and the era of the simulation.
-- Fast planes like in the 80s, need a larger radius than WWII planes.
@ -84,6 +100,9 @@ do -- AI_A2A_DISPATCHER
-- ## 2. Set the **engage radius**:
--
-- Define the radius to engage any target by airborne friendlies, which are executing cap or returning from an intercept mission.
--
-- ![Banner Image](..\Presentations\AI_A2A_DISPATCHER\Dia10.JPG)
--
-- So, if there is a target area detected and reported,
-- then any friendlies that are airborne near this target area,
-- will be commanded to (re-)engage that target when available (if no other tasks were commanded).
@ -98,10 +117,15 @@ do -- AI_A2A_DISPATCHER
-- According to the tactical and strategic design of the mission broadly decide the shape and extent of red and blue territories.
-- They should be laid out such that a border area is created between the two coalitions.
--
-- ![Banner Image](..\Presentations\AI_A2A_DISPATCHER\Dia4.JPG)
--
-- Define a border area to simulate a **cold war** scenario and use the method @{#AI_A2A_DISPATCHER.SetBorderZone}() to create a border zone for the dispatcher.
--
-- A **cold war** is one where CAP aircraft patrol their territory but will not attack enemy aircraft or launch GCI aircraft unless enemy aircraft enter their territory. In other words the EWR may detect an enemy aircraft but will only send aircraft to attack it if it crosses the border.
-- A **hot war** is one where CAP aircraft will intercept any detected enemy aircraft and GCI aircraft will launch against detected enemy aircraft without regard for territory. In other words if the ground radar can detect the enemy aircraft then it will send CAP and GCI aircraft to attack it.
--
-- ![Banner Image](..\Presentations\AI_A2A_DISPATCHER\Dia9.JPG)
--
-- If its a cold war then the **borders of red and blue territory** need to be defined using a @{zone} object derived from @{Zone#ZONE_BASE}.
-- If a hot war is chosen then **no borders** actually need to be defined using the helicopter units other than it makes it easier sometimes for the mission maker to envisage where the red and blue territories roughly are. In a hot war the borders are effectively defined by the ground based radar coverage of a coalition. Set the noborders parameter to 1
--
@ -169,7 +193,10 @@ do -- AI_A2A_DISPATCHER
--
-- ### 4.3. Set squadron grouping
--
-- Choices are 1, 2, 3 or 4 when CAP or GCI flights spawn. Use the method @{#AI_A2A_DISPATCHER.SetSquadronGrouping}() to set the amount of CAP or GCI flights that will take-off when spawned.
-- Use the method @{#AI_A2A_DISPATCHER.SetSquadronGrouping}() to set the amount of CAP or GCI flights that will take-off when spawned.
--
-- ![Banner Image](..\Presentations\AI_A2A_DISPATCHER\Dia12.JPG)
--
-- In the case of GCI, the @{#AI_A2A_DISPATCHER.SetSquadronGrouping}() method has additional behaviour. When there aren't enough CAP flights airborne, a GCI will be initiated for the remaining
-- targets to be engaged. Depending on the grouping parameter, the spawned flights for GCI are grouped into this setting.
-- For example with a group setting of 2, if 3 targets are detected and cannot be engaged by CAP or any airborne flight,
@ -182,6 +209,8 @@ do -- AI_A2A_DISPATCHER
-- The effectiveness can be set with the **overhead parameter**. This is a number that is used to calculate the amount of Units that dispatching command will allocate to GCI in surplus of detected amount of units.
-- The **default value** of the overhead parameter is 1.0, which means **equal balance**.
--
-- ![Banner Image](..\Presentations\AI_A2A_DISPATCHER\Dia11.JPG)
--
-- However, depending on the (type of) aircraft (strength and payload) in the squadron and the amount of resources available, this parameter can be changed.
--
-- The @{#AI_A2A_DISPATCHER.SetOverhead}() method can be used to tweak the defense strength,
@ -203,8 +232,10 @@ do -- AI_A2A_DISPATCHER
--
-- ### 5.1. Set the CAP zones
--
-- * CAP zones are patrol areas where Combat Air Patrol (CAP) flights loiter until they either return to base due to low fuel or are assigned an interception task by ground control.
-- CAP zones are patrol areas where Combat Air Patrol (CAP) flights loiter until they either return to base due to low fuel or are assigned an interception task by ground control.
--
-- ![Banner Image](..\Presentations\AI_A2A_DISPATCHER\Dia6.JPG)
--
-- * As the CAP flights wander around within the zone waiting to be tasked, these zones need to be large enough that the aircraft are not constantly turning
-- but do not have to be big and numerous enough to completely cover a border.
--
@ -223,6 +254,8 @@ do -- AI_A2A_DISPATCHER
--
-- * Typically if a CAP flight is tasked and therefore leaves their zone empty while they go off and intercept their target another CAP flight will spawn to take their place.
--
-- ![Banner Image](..\Presentations\AI_A2A_DISPATCHER\Dia7.JPG)
--
-- The following example illustrates how CAP zones are coded:
--
-- -- CAP Squadron execution.
@ -280,11 +313,187 @@ do -- AI_A2A_DISPATCHER
--
-- A2ADispatcher:SetSquadronGci( "Mozdok", 900, 1200 )
--
-- ## 7. User Guide:
-- ## 7. Other configuration options
--
-- ## 8. Questionnaire:
-- ### 7.1. Set a tactical display panel:
--
-- ### 8.1. Which countries will be selected for each coalition?
-- Every 30 seconds, a tactical display panel can be shown that illustrates what the status is of the different groups controlled by AI\_A2A\_DISPATCHER.
-- Use the method @{#AI_A2A_DISPATCHER.SetTacticalDisplay}() to switch on the tactical display panel. The default will not show this panel.
-- Note that there may be some performance impact if this panel is shown.
--
-- ## 8. Mission Editor Guide:
--
-- The following steps need to be followed, in order to setup the different borders, templates and groups within the mission editor:
--
-- ### 8.1. Define your EWR network:
--
-- ![Banner Image](..\Presentations\AI_A2A_DISPATCHER\Dia14.JPG)
--
-- At strategic positions within the battlefield, position the correct groups of units that have radar detection capability in the battlefield.
-- Create the naming of these groups as such, that these can be easily recognized and included as a prefix within your lua MOOSE mission script.
-- These prefixes should be unique, so that accidentally no other groups would be incorporated within the EWR network.
--
-- ### 8.2. Define the border zone:
--
-- ![Banner Image](..\Presentations\AI_A2A_DISPATCHER\Dia15.JPG)
--
-- For a cold war situation, define your border zone.
-- You can do this in many ways, as the @{Zone} capability within MOOSE outlines. However, the best practice is to create a ZONE_POLYGON class.
-- To do this, you need to create a zone using a helicopter group, that is late activated, and has a unique group name.
-- Place the helicopter where the border zone should start, and draw using the waypoints the polygon zone around the area that is considered the border.
-- The helicopter group name is included as the reference within your lua MOOSE mission script, so ensure that the name is unique and is easily recognizable.
--
-- ### 8.3. Define the plane templates:
--
-- ![Banner Image](..\Presentations\AI_A2A_DISPATCHER\Dia16.JPG)
--
-- Define the templates of the planes that define the format of planes that will take part in the A2A defenses of your coalition.
-- These plane templates will never be activated, but are used to create a diverse airplane portfolio allocated to your squadrons.
--
-- IMPORTANT! **Plane templates MUST be of ONE unit, and must have the Late Activated flag switched on!**
--
-- Plane templates are used to diversify the defending squadrons with:
--
-- * different airplane types
-- * different airplane skins
-- * different skill levels
-- * different weapon payloads
-- * different fuel and other characteristics
--
-- Place these airplane templates are good visible locations within your mission, so you can easily retrieve them back.
--
-- ### 8.4. Define the CAP zones:
--
-- ![Banner Image](..\Presentations\AI_A2A_DISPATCHER\Dia17.JPG)
--
-- Similar as with the border zone, define the CAP zones using helicopter group templates. Its waypoints define the polygon zones.
-- But you can also define other zone types instead, like moving zones.
--
-- ![Banner Image](..\Presentations\AI_A2A_DISPATCHER\Dia18.JPG)
--
-- Or you can define also zones using trigger zones.
--
-- ### 8.5. "Script it":
--
-- Find the following mission script as an example:
--
-- -- Define a SET_GROUP object that builds a collection of groups that define the EWR network.
-- -- Here we build the network with all the groups that have a name starting with DF CCCP AWACS and DF CCCP EWR.
-- DetectionSetGroup = SET_GROUP:New()
-- DetectionSetGroup:FilterPrefixes( { "DF CCCP AWACS", "DF CCCP EWR" } )
-- DetectionSetGroup:FilterStart()
--
-- -- Setup the A2A dispatcher, and initialize it.
-- A2ADispatcher = AI_A2A_DISPATCHER:New( DetectionSetGroup, 30000 )
--
-- -- Initialize the dispatcher, setting up a border zone. This is a polygon,
-- -- which takes the waypoints of a late activated group with the name CCCP Border as the boundaries of the border area.
-- -- Any enemy crossing this border will be engaged.
-- CCCPBorderZone = ZONE_POLYGON:New( "CCCP Border", GROUP:FindByName( "CCCP Border" ) )
-- A2ADispatcher:SetBorderZone( { CCCPBorderZone } )
--
-- -- Initialize the dispatcher, setting up a radius of 100km where any airborne friendly
-- -- without an assignment within 100km radius from a detected target, will engage that target.
-- A2ADispatcher:SetEngageRadius( 300000 )
--
-- -- Setup the squadrons.
-- A2ADispatcher:SetSquadron( "Mineralnye", AIRBASE.Caucasus.Mineralnye_Vody, { "SQ CCCP SU-27" }, 20 )
-- A2ADispatcher:SetSquadron( "Maykop", AIRBASE.Caucasus.Maykop_Khanskaya, { "SQ CCCP MIG-31" }, 20 )
-- A2ADispatcher:SetSquadron( "Mozdok", AIRBASE.Caucasus.Mozdok, { "SQ CCCP MIG-31" }, 20 )
-- A2ADispatcher:SetSquadron( "Sochi", AIRBASE.Caucasus.Sochi_Adler, { "SQ CCCP SU-27" }, 20 )
-- A2ADispatcher:SetSquadron( "Novo", AIRBASE.Caucasus.Novorossiysk, { "SQ CCCP SU-27" }, 20 )
--
-- -- Setup the overhead
-- A2ADispatcher:SetSquadronOverhead( "Mineralnye", 1.2 )
-- A2ADispatcher:SetSquadronOverhead( "Maykop", 1 )
-- A2ADispatcher:SetSquadronOverhead( "Mozdok", 1.5 )
-- A2ADispatcher:SetSquadronOverhead( "Sochi", 1 )
-- A2ADispatcher:SetSquadronOverhead( "Novo", 1 )
--
-- -- Setup the Grouping
-- A2ADispatcher:SetSquadronGrouping( "Mineralnye", 2 )
-- A2ADispatcher:SetSquadronGrouping( "Sochi", 2 )
-- A2ADispatcher:SetSquadronGrouping( "Novo", 3 )
--
-- -- Setup the Takeoff methods
-- A2ADispatcher:SetSquadronTakeoff( "Mineralnye", AI_A2A_DISPATCHER.Takeoff.Air )
-- A2ADispatcher:SetSquadronTakeoffInAir( "Sochi" )
-- A2ADispatcher:SetSquadronTakeoffFromRunway( "Mozdok" )
-- A2ADispatcher:SetSquadronTakeoffFromParkingCold( "Maykop" )
-- A2ADispatcher:SetSquadronTakeoffFromParkingHot( "Novo" )
--
-- -- Setup the Landing methods
-- A2ADispatcher:SetSquadronLandingAtRunway( "Mineralnye" )
-- A2ADispatcher:SetSquadronLandingNearAirbase( "Sochi" )
-- A2ADispatcher:SetSquadronLandingAtEngineShutdown( "Mozdok" )
-- A2ADispatcher:SetSquadronLandingNearAirbase( "Maykop" )
-- A2ADispatcher:SetSquadronLanding( "Novo", AI_A2A_DISPATCHER.Landing.AtRunway )
--
--
-- -- CAP Squadron execution.
-- CAPZoneEast = ZONE_POLYGON:New( "CAP Zone East", GROUP:FindByName( "CAP Zone East" ) )
-- A2ADispatcher:SetSquadronCap( "Mineralnye", CAPZoneEast, 4000, 10000, 500, 600, 800, 900 )
-- A2ADispatcher:SetSquadronCapInterval( "Mineralnye", 2, 30, 60, 1 )
--
-- CAPZoneWest = ZONE_POLYGON:New( "CAP Zone West", GROUP:FindByName( "CAP Zone West" ) )
-- A2ADispatcher:SetSquadronCap( "Sochi", CAPZoneWest, 4000, 8000, 600, 800, 800, 1200, "BARO" )
-- A2ADispatcher:SetSquadronCapInterval( "Sochi", 2, 30, 120, 1 )
--
-- CAPZoneMiddle = ZONE:New( "CAP Zone Middle")
-- A2ADispatcher:SetSquadronCap( "Maykop", CAPZoneMiddle, 4000, 8000, 600, 800, 800, 1200, "RADIO" )
-- A2ADispatcher:SetSquadronCapInterval( "Sochi", 2, 30, 120, 1 )
--
-- -- GCI Squadron execution.
-- A2ADispatcher:SetSquadronGci( "Mozdok", 900, 1200 )
-- A2ADispatcher:SetSquadronGci( "Novo", 900, 2100 )
-- A2ADispatcher:SetSquadronGci( "Maykop", 900, 1200 )
--
-- #### 8.5.1. Script the EWR network
--
-- ![Banner Image](..\Presentations\AI_A2A_DISPATCHER\Dia20.JPG)
--
-- #### 8.5.2. Script the AI\_A2A\_DISPATCHER object and configure it
--
-- ![Banner Image](..\Presentations\AI_A2A_DISPATCHER\Dia21.JPG)
--
-- #### 8.5.3. Script the squadrons
--
-- ![Banner Image](..\Presentations\AI_A2A_DISPATCHER\Dia22.JPG)
--
-- Create the squadrons using the @{#AI_A2A_DISPATCHER.SetSquadron)() method.
--
-- ![Banner Image](..\Presentations\AI_A2A_DISPATCHER\Dia23.JPG)
--
-- Define the defense overhead of the squadrons using the @{#AI_A2A_DISPATCHER.SetSquadronOverhead)() method.
-- Group the squadron units using the @{#AI_A2A_DISPATCHER.SetSquadronGrouping)() method.
--
-- ![Banner Image](..\Presentations\AI_A2A_DISPATCHER\Dia24.JPG)
--
-- Set the takeoff method of the squadron using the @{#AI_A2A_DISPATCHER.SetSquadronTakeoff)() methods.
-- Set the landing method of the squadron using the @{#AI_A2A_DISPATCHER.SetSquadronLanding)() methods.
--
-- ![Banner Image](..\Presentations\AI_A2A_DISPATCHER\Dia25.JPG)
--
-- Create the @{Zone} objects using:
--
-- * @{Zone#ZONE} class to create a zone using a trigger zone set in the mission editor.
-- * @{Zone#ZONE_UNIT} class to create a zone around a unit object.
-- * @{Zone#ZONE_GROUP} class to create a zone around a group object.
-- * @{Zone#ZONE_POLYGON} class to create a polygon zone using a late activated group object.
--
-- Use the @{#AI_A2A_DISPATCHER.SetSquadronCap)() method to define CAP execution for the squadron, within the CAP zone defined.
--
-- ![Banner Image](..\Presentations\AI_A2A_DISPATCHER\Dia26.JPG)
--
-- Use the @{#AI_A2A_DISPATCHER.SetSquadronCapInterval)() method to define how many CAP groups can be airborne at the same time, and the timing intervals.
--
-- ![Banner Image](..\Presentations\AI_A2A_DISPATCHER\Dia27.JPG)
--
-- Use the @{#AI_A2A_DISPATCHER.SetSquadronGci)() method to define GCI execution for the squadron.
--
-- ## 9. Q & A:
--
-- ### 9.1. Which countries will be selected for each coalition?
--
-- Which countries are assigned to a coalition influences which units are available to the coalition.
-- For example because the mission calls for a EWR radar on the blue side the Ukraine might be chosen as a blue country
@ -292,7 +501,7 @@ do -- AI_A2A_DISPATCHER
-- Some countries assign different tasking to aircraft, for example Germany assigns the CAP task to F-4E Phantoms but the USA does not.
-- Therefore if F4s are wanted as a coalitions CAP or GCI aircraft Germany will need to be assigned to that coalition.
--
-- ### 8.2.Country, type, load out, skill and skins for CAP and GCI aircraft?
-- ### 9.2.Country, type, load out, skill and skins for CAP and GCI aircraft?
--
-- * Note these can be from any countries within the coalition but must be an aircraft with one of the main tasks being “CAP”.
-- * Obviously skins which are selected must be available to all players that join the mission otherwise they will see a default skin.
@ -459,6 +668,7 @@ do -- AI_A2A_DISPATCHER
self:HandleEvent( EVENTS.Land )
self:HandleEvent( EVENTS.EngineShutdown )
self:SetTacticalDisplay( false )
self:__Start( 5 )
@ -1633,31 +1843,35 @@ do -- AI_A2A_DISPATCHER
self:GCI( DetectedItem, DefendersMissing, Friendlies )
end
end
-- Show tactical situation
Report:Add( string.format( "\n - Target %s ( %s ): %s" , DetectedItem.ItemID, DetectedItem.Index, DetectedItem.Set:GetObjectNames() ) )
if self.TacticalDisplay then
-- Show tactical situation
Report:Add( string.format( "\n - Target %s ( %s ): %s" , DetectedItem.ItemID, DetectedItem.Index, DetectedItem.Set:GetObjectNames() ) )
for Defender, DefenderTask in pairs( self:GetDefenderTasks() ) do
local Defender = Defender -- Wrapper.Group#GROUP
if DefenderTask.Target and DefenderTask.Target.Index == DetectedItem.Index then
Report:Add( string.format( " - %s ( %s - %s ) %s", Defender:GetName(), DefenderTask.Type, DefenderTask.Fsm:GetState(), Defender:HasTask() == true and "Executing" or "Idle" ) )
end
end
end
end
if self.TacticalDisplay then
Report:Add( "\n - No Targets:")
local TaskCount = 0
for Defender, DefenderTask in pairs( self:GetDefenderTasks() ) do
TaskCount = TaskCount + 1
local Defender = Defender -- Wrapper.Group#GROUP
if DefenderTask.Target and DefenderTask.Target.Index == DetectedItem.Index then
Report:Add( string.format( " - %s ( %s - %s ) %s", Defender:GetName(), DefenderTask.Type, DefenderTask.Fsm:GetState(), Defender:HasTask() == true and "Executing" or "Idle" ) )
end
if not DefenderTask.Target then
local DefenderHasTask = Defender:HasTask()
Report:Add( string.format( " - %s ( %s - %s ) %s", Defender:GetName(), DefenderTask.Type, DefenderTask.Fsm:GetState(), Defender:HasTask() == true and "Executing" or "Idle" ) )
end
end
Report:Add( string.format( "\n - %d Tasks", TaskCount ) )
self:T( Report:Text( "\n" ) )
trigger.action.outText( Report:Text( "\n" ), 25 )
end
Report:Add( "\n - No Targets:")
local TaskCount = 0
for Defender, DefenderTask in pairs( self:GetDefenderTasks() ) do
TaskCount = TaskCount + 1
local Defender = Defender -- Wrapper.Group#GROUP
if not DefenderTask.Target then
local DefenderHasTask = Defender:HasTask()
Report:Add( string.format( " - %s ( %s - %s ) %s", Defender:GetName(), DefenderTask.Type, DefenderTask.Fsm:GetState(), Defender:HasTask() == true and "Executing" or "Idle" ) )
end
end
Report:Add( string.format( "\n - %d Tasks", TaskCount ) )
self:T( Report:Text( "\n" ) )
trigger.action.outText( Report:Text( "\n" ), 25 )
return true
end

View File

@ -5,9 +5,9 @@ echo Generating LuaDocumentor Documentation
echo --------------------------------------
call luadocumentor.bat
:: Generate Slate documentation
echo Generating Slate Documentation
echo ------------------------------
cd "Slate Documentation Generator"
call Generate.bat
cd ..
rem :: Generate Slate documentation
rem echo Generating Slate Documentation
rem echo ------------------------------
rem cd "Slate Documentation Generator"
rem call Generate.bat
rem cd ..

View File

@ -1,43 +0,0 @@
@K=function, @M=Task_A2A, @N=onafterRouteToRendezVous, @P=Fsm, @F=../../../MOOSE/Moose Development/Moose\Tasking\Task_A2A.lua, @C=4242,
@K=function, @M=Task_A2A, @N=OnAfterArriveAtRendezVous, @P=Fsm, @F=../../../MOOSE/Moose Development/Moose\Tasking\Task_A2A.lua, @C=4903,
@K=function, @M=Task_A2A, @N=onafterEngage, @P=Fsm, @F=../../../MOOSE/Moose Development/Moose\Tasking\Task_A2A.lua, @C=5300,
@K=function, @M=Task_A2A, @N=onafterRouteToTarget, @P=Fsm, @F=../../../MOOSE/Moose Development/Moose\Tasking\Task_A2A.lua, @C=5622,
@K=function, @M=Task_A2A, @N=onafterRouteToTargets, @P=Fsm, @F=../../../MOOSE/Moose Development/Moose\Tasking\Task_A2A.lua, @C=6503,
@K=function, @M=Task_A2G, @N=onafterRouteToRendezVous, @P=Fsm, @F=../../../MOOSE/Moose Development/Moose\Tasking\Task_A2G.lua, @C=4236,
@K=function, @M=Task_A2G, @N=OnAfterArriveAtRendezVous, @P=Fsm, @F=../../../MOOSE/Moose Development/Moose\Tasking\Task_A2G.lua, @C=4897,
@K=function, @M=Task_A2G, @N=onafterEngage, @P=Fsm, @F=../../../MOOSE/Moose Development/Moose\Tasking\Task_A2G.lua, @C=5294,
@K=function, @M=Task_A2G, @N=onafterRouteToTarget, @P=Fsm, @F=../../../MOOSE/Moose Development/Moose\Tasking\Task_A2G.lua, @C=5616,
@K=function, @M=Task_A2G, @N=onafterRouteToTargets, @P=Fsm, @F=../../../MOOSE/Moose Development/Moose\Tasking\Task_A2G.lua, @C=6495,
@K=function, @M=Task_Cargo, @N=onafterSelectAction, @P=Fsm, @F=../../../MOOSE/Moose Development/Moose\Tasking\Task_CARGO.lua, @C=10296,
@K=function, @M=Task_Cargo, @N=OnLeaveWaitingForCommand, @P=Fsm, @F=../../../MOOSE/Moose Development/Moose\Tasking\Task_CARGO.lua, @C=13325,
@K=function, @M=Task_Cargo, @N=onafterRouteToPickup, @P=Fsm, @F=../../../MOOSE/Moose Development/Moose\Tasking\Task_CARGO.lua, @C=14186,
@K=function, @M=Task_Cargo, @N=onafterArriveAtPickup, @P=Fsm, @F=../../../MOOSE/Moose Development/Moose\Tasking\Task_CARGO.lua, @C=14807,
@K=function, @M=Task_Cargo, @N=onafterCancelRouteToPickup, @P=Fsm, @F=../../../MOOSE/Moose Development/Moose\Tasking\Task_CARGO.lua, @C=15336,
@K=function, @M=Task_Cargo, @N=onafterRouteToDeploy, @P=Fsm, @F=../../../MOOSE/Moose Development/Moose\Tasking\Task_CARGO.lua, @C=15673,
@K=function, @M=Task_Cargo, @N=onafterArriveAtDeploy, @P=Fsm, @F=../../../MOOSE/Moose Development/Moose\Tasking\Task_CARGO.lua, @C=16120,
@K=function, @M=Task_Cargo, @N=onafterCancelRouteToDeploy, @P=Fsm, @F=../../../MOOSE/Moose Development/Moose\Tasking\Task_CARGO.lua, @C=16548,
@K=function, @M=Task_Cargo, @N=onafterLanded, @P=Fsm, @F=../../../MOOSE/Moose Development/Moose\Tasking\Task_CARGO.lua, @C=17835,
@K=function, @M=Task_Cargo, @N=onafterPrepareBoarding, @P=Fsm, @F=../../../MOOSE/Moose Development/Moose\Tasking\Task_CARGO.lua, @C=18601,
@K=function, @M=Task_Cargo, @N=onafterBoard, @P=Fsm, @F=../../../MOOSE/Moose Development/Moose\Tasking\Task_CARGO.lua, @C=19061,
@K=function, @M=Task_Cargo, @N=onafterBoarded, @P=Fsm, @F=../../../MOOSE/Moose Development/Moose\Tasking\Task_CARGO.lua, @C=20002,
@K=function, @M=Task_Cargo, @N=onafterPrepareUnBoarding, @P=Fsm, @F=../../../MOOSE/Moose Development/Moose\Tasking\Task_CARGO.lua, @C=20685,
@K=function, @M=Task_Cargo, @N=onafterUnBoard, @P=Fsm, @F=../../../MOOSE/Moose Development/Moose\Tasking\Task_CARGO.lua, @C=21645,
@K=function, @M=Task_Cargo, @N=onafterUnBoarded, @P=Fsm, @F=../../../MOOSE/Moose Development/Moose\Tasking\Task_CARGO.lua, @C=22664,
@K=function, @M=Designate, @N=OnBeforeLaseOn, @P=DESIGNATE , @F=../../../MOOSE/Moose Development/Moose\Functional\Designate.lua, @C=12214,
@K=function, @M=Designate, @N=OnAfterLaseOn, @P=DESIGNATE , @F=../../../MOOSE/Moose Development/Moose\Functional\Designate.lua, @C=12462,
@K=function, @M=Designate, @N=LaseOn, @P=DESIGNATE , @F=../../../MOOSE/Moose Development/Moose\Functional\Designate.lua, @C=12683,
@K=function, @M=Designate, @N=__LaseOn, @P=DESIGNATE , @F=../../../MOOSE/Moose Development/Moose\Functional\Designate.lua, @C=12806,
@K=function, @M=Designate, @N=OnBeforeLaseOff, @P=DESIGNATE , @F=../../../MOOSE/Moose Development/Moose\Functional\Designate.lua, @C=13090,
@K=function, @M=Designate, @N=OnAfterLaseOff, @P=DESIGNATE , @F=../../../MOOSE/Moose Development/Moose\Functional\Designate.lua, @C=13340,
@K=function, @M=Designate, @N=LaseOff, @P=DESIGNATE , @F=../../../MOOSE/Moose Development/Moose\Functional\Designate.lua, @C=13563,
@K=function, @M=Designate, @N=__LaseOff, @P=DESIGNATE , @F=../../../MOOSE/Moose Development/Moose\Functional\Designate.lua, @C=13688,
@K=function, @M=Designate, @N=OnBeforeSmoke, @P=DESIGNATE , @F=../../../MOOSE/Moose Development/Moose\Functional\Designate.lua, @C=13902,
@K=function, @M=Designate, @N=OnAfterSmoke, @P=DESIGNATE , @F=../../../MOOSE/Moose Development/Moose\Functional\Designate.lua, @C=14148,
@K=function, @M=Designate, @N=Smoke, @P=DESIGNATE , @F=../../../MOOSE/Moose Development/Moose\Functional\Designate.lua, @C=14367,
@K=function, @M=Designate, @N=__Smoke, @P=DESIGNATE , @F=../../../MOOSE/Moose Development/Moose\Functional\Designate.lua, @C=14488,
@K=function, @M=Designate, @N=OnBeforeStatus, @P=DESIGNATE , @F=../../../MOOSE/Moose Development/Moose\Functional\Designate.lua, @C=15574,
@K=function, @M=Designate, @N=OnAfterStatus, @P=DESIGNATE , @F=../../../MOOSE/Moose Development/Moose\Functional\Designate.lua, @C=15822,
@K=function, @M=Designate, @N=Status, @P=DESIGNATE , @F=../../../MOOSE/Moose Development/Moose\Functional\Designate.lua, @C=16043,
@K=function, @M=Designate, @N=__Status, @P=DESIGNATE , @F=../../../MOOSE/Moose Development/Moose\Functional\Designate.lua, @C=16166,
@K=function, @M=AI_A2A_Dispatcher, @N=onafterHome, @P=Fsm, @F=../../../MOOSE/Moose Development/Moose\AI\AI_A2A_Dispatcher.lua, @C=65259,
@K=function, @M=AI_A2A_Dispatcher, @N=onafterHome, @P=Fsm, @F=../../../MOOSE/Moose Development/Moose\AI\AI_A2A_Dispatcher.lua, @C=69468,
1 @K=function @M=Task_A2A @N=onafterRouteToRendezVous @P=Fsm @F=../../../MOOSE/Moose Development/Moose\Tasking\Task_A2A.lua @C=4242
2 @K=function @M=Task_A2A @N=OnAfterArriveAtRendezVous @P=Fsm @F=../../../MOOSE/Moose Development/Moose\Tasking\Task_A2A.lua @C=4903
3 @K=function @M=Task_A2A @N=onafterEngage @P=Fsm @F=../../../MOOSE/Moose Development/Moose\Tasking\Task_A2A.lua @C=5300
4 @K=function @M=Task_A2A @N=onafterRouteToTarget @P=Fsm @F=../../../MOOSE/Moose Development/Moose\Tasking\Task_A2A.lua @C=5622
5 @K=function @M=Task_A2A @N=onafterRouteToTargets @P=Fsm @F=../../../MOOSE/Moose Development/Moose\Tasking\Task_A2A.lua @C=6503
6 @K=function @M=Task_A2G @N=onafterRouteToRendezVous @P=Fsm @F=../../../MOOSE/Moose Development/Moose\Tasking\Task_A2G.lua @C=4236
7 @K=function @M=Task_A2G @N=OnAfterArriveAtRendezVous @P=Fsm @F=../../../MOOSE/Moose Development/Moose\Tasking\Task_A2G.lua @C=4897
8 @K=function @M=Task_A2G @N=onafterEngage @P=Fsm @F=../../../MOOSE/Moose Development/Moose\Tasking\Task_A2G.lua @C=5294
9 @K=function @M=Task_A2G @N=onafterRouteToTarget @P=Fsm @F=../../../MOOSE/Moose Development/Moose\Tasking\Task_A2G.lua @C=5616
10 @K=function @M=Task_A2G @N=onafterRouteToTargets @P=Fsm @F=../../../MOOSE/Moose Development/Moose\Tasking\Task_A2G.lua @C=6495
11 @K=function @M=Task_Cargo @N=onafterSelectAction @P=Fsm @F=../../../MOOSE/Moose Development/Moose\Tasking\Task_CARGO.lua @C=10296
12 @K=function @M=Task_Cargo @N=OnLeaveWaitingForCommand @P=Fsm @F=../../../MOOSE/Moose Development/Moose\Tasking\Task_CARGO.lua @C=13325
13 @K=function @M=Task_Cargo @N=onafterRouteToPickup @P=Fsm @F=../../../MOOSE/Moose Development/Moose\Tasking\Task_CARGO.lua @C=14186
14 @K=function @M=Task_Cargo @N=onafterArriveAtPickup @P=Fsm @F=../../../MOOSE/Moose Development/Moose\Tasking\Task_CARGO.lua @C=14807
15 @K=function @M=Task_Cargo @N=onafterCancelRouteToPickup @P=Fsm @F=../../../MOOSE/Moose Development/Moose\Tasking\Task_CARGO.lua @C=15336
16 @K=function @M=Task_Cargo @N=onafterRouteToDeploy @P=Fsm @F=../../../MOOSE/Moose Development/Moose\Tasking\Task_CARGO.lua @C=15673
17 @K=function @M=Task_Cargo @N=onafterArriveAtDeploy @P=Fsm @F=../../../MOOSE/Moose Development/Moose\Tasking\Task_CARGO.lua @C=16120
18 @K=function @M=Task_Cargo @N=onafterCancelRouteToDeploy @P=Fsm @F=../../../MOOSE/Moose Development/Moose\Tasking\Task_CARGO.lua @C=16548
19 @K=function @M=Task_Cargo @N=onafterLanded @P=Fsm @F=../../../MOOSE/Moose Development/Moose\Tasking\Task_CARGO.lua @C=17835
20 @K=function @M=Task_Cargo @N=onafterPrepareBoarding @P=Fsm @F=../../../MOOSE/Moose Development/Moose\Tasking\Task_CARGO.lua @C=18601
21 @K=function @M=Task_Cargo @N=onafterBoard @P=Fsm @F=../../../MOOSE/Moose Development/Moose\Tasking\Task_CARGO.lua @C=19061
22 @K=function @M=Task_Cargo @N=onafterBoarded @P=Fsm @F=../../../MOOSE/Moose Development/Moose\Tasking\Task_CARGO.lua @C=20002
23 @K=function @M=Task_Cargo @N=onafterPrepareUnBoarding @P=Fsm @F=../../../MOOSE/Moose Development/Moose\Tasking\Task_CARGO.lua @C=20685
24 @K=function @M=Task_Cargo @N=onafterUnBoard @P=Fsm @F=../../../MOOSE/Moose Development/Moose\Tasking\Task_CARGO.lua @C=21645
25 @K=function @M=Task_Cargo @N=onafterUnBoarded @P=Fsm @F=../../../MOOSE/Moose Development/Moose\Tasking\Task_CARGO.lua @C=22664
26 @K=function @M=Designate @N=OnBeforeLaseOn @P=DESIGNATE @F=../../../MOOSE/Moose Development/Moose\Functional\Designate.lua @C=12214
27 @K=function @M=Designate @N=OnAfterLaseOn @P=DESIGNATE @F=../../../MOOSE/Moose Development/Moose\Functional\Designate.lua @C=12462
28 @K=function @M=Designate @N=LaseOn @P=DESIGNATE @F=../../../MOOSE/Moose Development/Moose\Functional\Designate.lua @C=12683
29 @K=function @M=Designate @N=__LaseOn @P=DESIGNATE @F=../../../MOOSE/Moose Development/Moose\Functional\Designate.lua @C=12806
30 @K=function @M=Designate @N=OnBeforeLaseOff @P=DESIGNATE @F=../../../MOOSE/Moose Development/Moose\Functional\Designate.lua @C=13090
31 @K=function @M=Designate @N=OnAfterLaseOff @P=DESIGNATE @F=../../../MOOSE/Moose Development/Moose\Functional\Designate.lua @C=13340
32 @K=function @M=Designate @N=LaseOff @P=DESIGNATE @F=../../../MOOSE/Moose Development/Moose\Functional\Designate.lua @C=13563
33 @K=function @M=Designate @N=__LaseOff @P=DESIGNATE @F=../../../MOOSE/Moose Development/Moose\Functional\Designate.lua @C=13688
34 @K=function @M=Designate @N=OnBeforeSmoke @P=DESIGNATE @F=../../../MOOSE/Moose Development/Moose\Functional\Designate.lua @C=13902
35 @K=function @M=Designate @N=OnAfterSmoke @P=DESIGNATE @F=../../../MOOSE/Moose Development/Moose\Functional\Designate.lua @C=14148
36 @K=function @M=Designate @N=Smoke @P=DESIGNATE @F=../../../MOOSE/Moose Development/Moose\Functional\Designate.lua @C=14367
37 @K=function @M=Designate @N=__Smoke @P=DESIGNATE @F=../../../MOOSE/Moose Development/Moose\Functional\Designate.lua @C=14488
38 @K=function @M=Designate @N=OnBeforeStatus @P=DESIGNATE @F=../../../MOOSE/Moose Development/Moose\Functional\Designate.lua @C=15574
39 @K=function @M=Designate @N=OnAfterStatus @P=DESIGNATE @F=../../../MOOSE/Moose Development/Moose\Functional\Designate.lua @C=15822
40 @K=function @M=Designate @N=Status @P=DESIGNATE @F=../../../MOOSE/Moose Development/Moose\Functional\Designate.lua @C=16043
41 @K=function @M=Designate @N=__Status @P=DESIGNATE @F=../../../MOOSE/Moose Development/Moose\Functional\Designate.lua @C=16166
42 @K=function @M=AI_A2A_Dispatcher @N=onafterHome @P=Fsm @F=../../../MOOSE/Moose Development/Moose\AI\AI_A2A_Dispatcher.lua @C=65259
43 @K=function @M=AI_A2A_Dispatcher @N=onafterHome @P=Fsm @F=../../../MOOSE/Moose Development/Moose\AI\AI_A2A_Dispatcher.lua @C=69468

View File

@ -128,7 +128,9 @@
<td class="summary">
<h1>AI_A2A_DISPATCHER class, extends <a href="Tasking.html##(DETECTION_MANAGER)">Tasking#DETECTION_MANAGER</a></h1>
<p>The <a href="##(AI)">#AI</a> class is designed to create an automatic air defence system for a coalition.</p>
<p><img src="..\Presentations\AI_A2A_DISPATCHER\Dia1.JPG" alt="Banner Image"/></p>
<p>The <a href="##(AI_A2A_DISPATCHER)">#AI<em>A2A</em>DISPATCHER</a> class is designed to create an automatic air defence system for a coalition.</p>
</td>
</tr>
</table>
@ -599,9 +601,14 @@
<h1>AI_A2A_DISPATCHER class, extends <a href="Tasking.html##(DETECTION_MANAGER)">Tasking#DETECTION_MANAGER</a></h1>
<p>The <a href="##(AI)">#AI</a> class is designed to create an automatic air defence system for a coalition.</p>
<p><img src="..\Presentations\AI_A2A_DISPATCHER\Dia1.JPG" alt="Banner Image"/></p>
<p>The <a href="##(AI_A2A_DISPATCHER)">#AI<em>A2A</em>DISPATCHER</a> class is designed to create an automatic air defence system for a coalition.</p>
<p><img src="..\Presentations\AI_A2A_DISPATCHER\Dia3.JPG" alt="Banner Image"/></p>
<p>It includes automatic spawning of Combat Air Patrol aircraft (CAP) and Ground Controlled Intercept aircraft (GCI) in response to enemy air movements that are detected by a ground based radar network.
CAP flights will take off and proceed to designated CAP zones where they will remain on station until the ground radars direct them to intercept detected enemy aircraft or they run short of fuel and must return to base (RTB). When a CAP flight leaves their zone to perform an interception or return to base a new CAP flight will spawn to take their place.
If all CAP flights are engaged or RTB then additional GCI interceptors will scramble to intercept unengaged enemy aircraft under ground radar control.
@ -618,22 +625,30 @@ There are two parameters required, a <a href="Set.html##(SET_GROUP)">Set#SET_GRO
<p>The <a href="##(AI_A2A_DISPATCHER).New">AI<em>A2A</em>DISPATCHER.New</a>() method is used to setup the EWR network and to define the grouping.</p>
<h3>1.1. Define the EWR network:</h3>
<h3>1.1. Define the <strong>EWR network</strong>:</h3>
<p>As part of the AI_A2A_DISPATCHER constructor, an EWR network must be given as the first parameter.
An EWR network, or, Early Warning Radar network, is used to early detect potential airborne targets and to understand the position of patrolling targets of the enemy.</p>
<p><img src="..\Presentations\AI_A2A_DISPATCHER\Dia5.JPG" alt="Banner Image"/></p>
<p>Typically EWR networks are setup using 55G6 EWR, 1L13 EWR, Hawk sr and Patriot str ground based radar units.
These radars have different ranges and 55G6 EWR and 1L13 EWR radars are Eastern Bloc units (eg Russia, Ukraine, Georgia) while the Hawk and Patriot radars are Western (eg US).
Additionally, ANY other radar capable unit can be part of the EWR network! Also AWACS airborne units, planes, helicopters can help to detect targets, as long as they have radar.
The position of these units is very important as they need to provide enough coverage
to pick up enemy aircraft as they approach so that CAP and GCI flights can be tasked to intercept them.
Additionally in a hot war situation where the border is no longer respected the placement of radars has a big effect on how fast the war escalates.
to pick up enemy aircraft as they approach so that CAP and GCI flights can be tasked to intercept them.</p>
<p><img src="..\Presentations\AI_A2A_DISPATCHER\Dia7.JPG" alt="Banner Image"/></p>
<p>Additionally in a hot war situation where the border is no longer respected the placement of radars has a big effect on how fast the war escalates.
For example if they are a long way forward and can detect enemy planes on the ground and taking off
they will start to vector CAP and GCI flights to attack them straight away which will immediately draw a response from the other coalition.
Having the radars further back will mean a slower escalation because fewer targets will be detected and
therefore less CAP and GCI flights will spawn and this will tend to make just the border area active rather than a melee over the whole map.
It all depends on what the desired effect is. </p>
<p>EWR networks are dynamically constructed, that is, they form part of the <a href="Set.html##(SET_GROUP)">Set#SET_GROUP</a> object that is given as the input parameter of the AI_A2A_DISPATCHER class.
By defining in a smart way the names or name prefixes of the groups of EWR capable units, these units will be automatically added or deleted from the EWR network,
<p>EWR networks are <strong>dynamically constructed</strong>, that is, they form part of the <a href="Set.html##(SET_GROUP)">Set#SET_GROUP</a> object that is given as the input parameter of the AI_A2A_DISPATCHER class.
By defining in a <strong>smart way the names or name prefixes of the groups</strong> of EWR capable units, these units will be <strong>automatically added or deleted</strong> from the EWR network,
increasing or decreasing the radar coverage of the Early Warning System.</p>
<p>See the following example to setup an EWR network containing EWR stations and AWACS.</p>
@ -651,8 +666,11 @@ A2ADispatcher = AI_A2A_DISPATCHER:New( DetectionSetGroup, 30000 )
<p>The above example creates a SET_GROUP instance, and stores this in the variable (object) <strong>DetectionSetGroup</strong>.
<strong>DetectionSetGroup</strong> is then being configured to filter all active groups with a group name starting with <strong>DF CCCP AWACS</strong> or <strong>DF CCCP EWR</strong> to be included in the Set.
<strong>DetectionSetGroup</strong> is then being ordered to start the dynamic filtering. Note that any destroy or new spawn of a group with the above names will be removed or added to the Set.
The <strong>DetectionSetGroup</strong> variable is then passed to the <a href="##(AI_A2A_DISPATCHER).New">AI<em>A2A</em>DISPATCHER.New</a>() method to indicate the EWR network configuration and setup the A2A defense detection mechanism.
As a second parameter of the <a href="##(AI_A2A_DISPATCHER).New">AI<em>A2A</em>DISPATCHER.New</a>() method, 30000 indicates that detected targets need to be grouped within a radius of 30km.
The <strong>DetectionSetGroup</strong> variable is then passed to the <a href="##(AI_A2A_DISPATCHER).New">AI<em>A2A</em>DISPATCHER.New</a>() method to indicate the EWR network configuration and setup the A2A defense detection mechanism.</p>
<h3>1.2. Define the detected <strong>target grouping radius</strong>:</h3>
<p>As a second parameter of the <a href="##(AI_A2A_DISPATCHER).New">AI<em>A2A</em>DISPATCHER.New</a>() method, 30000 indicates that detected targets need to be grouped within a radius of 30km.
The grouping radius should not be too small, but also depends on the types of planes and the era of the simulation.
Fast planes like in the 80s, need a larger radius than WWII planes. <br/>
Typically I suggest to use 30000 for new generation planes and 10000 for older era aircraft.</p>
@ -662,8 +680,11 @@ group being detected. This may result in additional GCI being started by the dis
<h2>2. Set the <strong>engage radius</strong>:</h2>
<p>Define the radius to engage any target by airborne friendlies, which are executing cap or returning from an intercept mission.
So, if there is a target area detected and reported,
<p>Define the radius to engage any target by airborne friendlies, which are executing cap or returning from an intercept mission.</p>
<p><img src="..\Presentations\AI_A2A_DISPATCHER\Dia10.JPG" alt="Banner Image"/></p>
<p>So, if there is a target area detected and reported,
then any friendlies that are airborne near this target area,
will be commanded to (re-)engage that target when available (if no other tasks were commanded).
For example, if 100000 is given as a value, then any friendly that is airborne within 100km from the detected target,
@ -677,11 +698,16 @@ If too large, any airborne cap may not be able to reach the detected target area
<p>According to the tactical and strategic design of the mission broadly decide the shape and extent of red and blue territories.
They should be laid out such that a border area is created between the two coalitions.</p>
<p><img src="..\Presentations\AI_A2A_DISPATCHER\Dia4.JPG" alt="Banner Image"/></p>
<p>Define a border area to simulate a <strong>cold war</strong> scenario and use the method <a href="##(AI_A2A_DISPATCHER).SetBorderZone">AI<em>A2A</em>DISPATCHER.SetBorderZone</a>() to create a border zone for the dispatcher.</p>
<p>A <strong>cold war</strong> is one where CAP aircraft patrol their territory but will not attack enemy aircraft or launch GCI aircraft unless enemy aircraft enter their territory. In other words the EWR may detect an enemy aircraft but will only send aircraft to attack it if it crosses the border.
A <strong>hot war</strong> is one where CAP aircraft will intercept any detected enemy aircraft and GCI aircraft will launch against detected enemy aircraft without regard for territory. In other words if the ground radar can detect the enemy aircraft then it will send CAP and GCI aircraft to attack it.
If its a cold war then the <strong>borders of red and blue territory</strong> need to be defined using a <a href="zone.html">zone</a> object derived from <a href="Zone.html##(ZONE_BASE)">Zone#ZONE_BASE</a>.
A <strong>hot war</strong> is one where CAP aircraft will intercept any detected enemy aircraft and GCI aircraft will launch against detected enemy aircraft without regard for territory. In other words if the ground radar can detect the enemy aircraft then it will send CAP and GCI aircraft to attack it.</p>
<p><img src="..\Presentations\AI_A2A_DISPATCHER\Dia9.JPG" alt="Banner Image"/></p>
<p>If its a cold war then the <strong>borders of red and blue territory</strong> need to be defined using a <a href="zone.html">zone</a> object derived from <a href="Zone.html##(ZONE_BASE)">Zone#ZONE_BASE</a>.
If a hot war is chosen then <strong>no borders</strong> actually need to be defined using the helicopter units other than it makes it easier sometimes for the mission maker to envisage where the red and blue territories roughly are. In a hot war the borders are effectively defined by the ground based radar coverage of a coalition. Set the noborders parameter to 1</p>
<h2>4. Squadrons:</h2>
@ -758,8 +784,11 @@ Damaged or out-of-fuel aircraft are returning to the nearest friendly airbase an
<h3>4.3. Set squadron grouping</h3>
<p>Choices are 1, 2, 3 or 4 when CAP or GCI flights spawn. Use the method <a href="##(AI_A2A_DISPATCHER).SetSquadronGrouping">AI<em>A2A</em>DISPATCHER.SetSquadronGrouping</a>() to set the amount of CAP or GCI flights that will take-off when spawned.
In the case of GCI, the <a href="##(AI_A2A_DISPATCHER).SetSquadronGrouping">AI<em>A2A</em>DISPATCHER.SetSquadronGrouping</a>() method has additional behaviour. When there aren't enough CAP flights airborne, a GCI will be initiated for the remaining
<p>Use the method <a href="##(AI_A2A_DISPATCHER).SetSquadronGrouping">AI<em>A2A</em>DISPATCHER.SetSquadronGrouping</a>() to set the amount of CAP or GCI flights that will take-off when spawned.</p>
<p><img src="..\Presentations\AI_A2A_DISPATCHER\Dia12.JPG" alt="Banner Image"/></p>
<p>In the case of GCI, the <a href="##(AI_A2A_DISPATCHER).SetSquadronGrouping">AI<em>A2A</em>DISPATCHER.SetSquadronGrouping</a>() method has additional behaviour. When there aren't enough CAP flights airborne, a GCI will be initiated for the remaining
targets to be engaged. Depending on the grouping parameter, the spawned flights for GCI are grouped into this setting. <br/>
For example with a group setting of 2, if 3 targets are detected and cannot be engaged by CAP or any airborne flight,
a GCI needs to be started, the GCI flights will be grouped as follows: Group 1 of 2 flights and Group 2 of one flight!</p>
@ -771,6 +800,8 @@ a GCI needs to be started, the GCI flights will be grouped as follows: Group 1 o
<p>The effectiveness can be set with the <strong>overhead parameter</strong>. This is a number that is used to calculate the amount of Units that dispatching command will allocate to GCI in surplus of detected amount of units.
The <strong>default value</strong> of the overhead parameter is 1.0, which means <strong>equal balance</strong>. </p>
<p><img src="..\Presentations\AI_A2A_DISPATCHER\Dia11.JPG" alt="Banner Image"/></p>
<p>However, depending on the (type of) aircraft (strength and payload) in the squadron and the amount of resources available, this parameter can be changed.</p>
<p>The <a href="##(AI_A2A_DISPATCHER).SetOverhead">AI<em>A2A</em>DISPATCHER.SetOverhead</a>() method can be used to tweak the defense strength,
@ -794,8 +825,11 @@ multiplied by the Overhead and rounded up to the smallest integer. </p>
<h3>5.1. Set the CAP zones</h3>
<p>CAP zones are patrol areas where Combat Air Patrol (CAP) flights loiter until they either return to base due to low fuel or are assigned an interception task by ground control.</p>
<p><img src="..\Presentations\AI_A2A_DISPATCHER\Dia6.JPG" alt="Banner Image"/></p>
<ul>
<li><p>CAP zones are patrol areas where Combat Air Patrol (CAP) flights loiter until they either return to base due to low fuel or are assigned an interception task by ground control.</p></li>
<li><p>As the CAP flights wander around within the zone waiting to be tasked, these zones need to be large enough that the aircraft are not constantly turning
but do not have to be big and numerous enough to completely cover a border.</p></li>
<li><p>CAP zones can be of any type, and are derived from the <a href="Zone.html##(ZONE_BASE)">Zone#ZONE_BASE</a> class. Zones can be <a href="Zone.html##(ZONE)">Zone#ZONE</a>, <a href="Zone.html##(ZONE_POLYGON)">Zone#ZONE_POLYGON</a>, <a href="Zone.html##(ZONE_UNIT)">Zone#ZONE_UNIT</a>, <a href="Zone.html##(ZONE_GROUP)">Zone#ZONE_GROUP</a>, etc.
@ -810,6 +844,8 @@ multiplied by the Overhead and rounded up to the smallest integer. </p>
<li><p>Typically if a CAP flight is tasked and therefore leaves their zone empty while they go off and intercept their target another CAP flight will spawn to take their place.</p></li>
</ul>
<p><img src="..\Presentations\AI_A2A_DISPATCHER\Dia7.JPG" alt="Banner Image"/></p>
<p>The following example illustrates how CAP zones are coded:</p>
<pre><code> -- CAP Squadron execution.
@ -872,11 +908,177 @@ too short will mean that the intruders may have alraedy passed the ideal interce
<p> A2ADispatcher:SetSquadronGci( "Mozdok", 900, 1200 )</p>
<h2>7. User Guide:</h2>
<h2>7. Other configuration options</h2>
<h2>8. Questionnaire:</h2>
<h3>7.1. Set a tactical display panel:</h3>
<h3>8.1. Which countries will be selected for each coalition?</h3>
<p>Every 30 seconds, a tactical display panel can be shown that illustrates what the status is of the different groups controlled by AI_A2A_DISPATCHER.
Use the method <a href="##(AI_A2A_DISPATCHER).SetTacticalDisplay">AI<em>A2A</em>DISPATCHER.SetTacticalDisplay</a>() to switch on the tactical display panel. The default will not show this panel.
Note that there may be some performance impact if this panel is shown.</p>
<h2>8. Mission Editor Guide:</h2>
<p>The following steps need to be followed, in order to setup the different borders, templates and groups within the mission editor:</p>
<h3>8.1. Define your EWR network:</h3>
<p><img src="..\Presentations\AI_A2A_DISPATCHER\Dia14.JPG" alt="Banner Image"/></p>
<p>At strategic positions within the battlefield, position the correct groups of units that have radar detection capability in the battlefield.
Create the naming of these groups as such, that these can be easily recognized and included as a prefix within your lua MOOSE mission script.
These prefixes should be unique, so that accidentally no other groups would be incorporated within the EWR network.</p>
<h3>8.2. Define the border zone:</h3>
<p><img src="..\Presentations\AI_A2A_DISPATCHER\Dia15.JPG" alt="Banner Image"/></p>
<p>For a cold war situation, define your border zone.
You can do this in many ways, as the <a href="Zone.html">Zone</a> capability within MOOSE outlines. However, the best practice is to create a ZONE_POLYGON class.
To do this, you need to create a zone using a helicopter group, that is late activated, and has a unique group name.
Place the helicopter where the border zone should start, and draw using the waypoints the polygon zone around the area that is considered the border.
The helicopter group name is included as the reference within your lua MOOSE mission script, so ensure that the name is unique and is easily recognizable.</p>
<h3>8.3. Define the plane templates:</h3>
<p><img src="..\Presentations\AI_A2A_DISPATCHER\Dia16.JPG" alt="Banner Image"/></p>
<p>Define the templates of the planes that define the format of planes that will take part in the A2A defenses of your coalition.
These plane templates will never be activated, but are used to create a diverse airplane portfolio allocated to your squadrons.</p>
<p>IMPORTANT! <strong>Plane templates MUST be of ONE unit, and must have the Late Activated flag switched on!</strong></p>
<p>Plane templates are used to diversify the defending squadrons with:</p>
<ul>
<li>different airplane types</li>
<li>different airplane skins</li>
<li>different skill levels</li>
<li>different weapon payloads</li>
<li>different fuel and other characteristics</li>
</ul>
<p>Place these airplane templates are good visible locations within your mission, so you can easily retrieve them back.</p>
<h3>8.4. Define the CAP zones:</h3>
<p><img src="..\Presentations\AI_A2A_DISPATCHER\Dia17.JPG" alt="Banner Image"/></p>
<p>Similar as with the border zone, define the CAP zones using helicopter group templates. Its waypoints define the polygon zones.
But you can also define other zone types instead, like moving zones.</p>
<p><img src="..\Presentations\AI_A2A_DISPATCHER\Dia18.JPG" alt="Banner Image"/></p>
<p>Or you can define also zones using trigger zones.</p>
<h3>8.5. "Script it":</h3>
<p>Find the following mission script as an example:</p>
<p> -- Define a SET<em>GROUP object that builds a collection of groups that define the EWR network.
-- Here we build the network with all the groups that have a name starting with DF CCCP AWACS and DF CCCP EWR.
DetectionSetGroup = SET</em>GROUP:New()
DetectionSetGroup:FilterPrefixes( { "DF CCCP AWACS", "DF CCCP EWR" } )
DetectionSetGroup:FilterStart()</p>
<p> -- Setup the A2A dispatcher, and initialize it.
A2ADispatcher = AI<em>A2A</em>DISPATCHER:New( DetectionSetGroup, 30000 )</p>
<p> -- Initialize the dispatcher, setting up a border zone. This is a polygon,
-- which takes the waypoints of a late activated group with the name CCCP Border as the boundaries of the border area.
-- Any enemy crossing this border will be engaged.
CCCPBorderZone = ZONE_POLYGON:New( "CCCP Border", GROUP:FindByName( "CCCP Border" ) )
A2ADispatcher:SetBorderZone( { CCCPBorderZone } )</p>
<p> -- Initialize the dispatcher, setting up a radius of 100km where any airborne friendly
-- without an assignment within 100km radius from a detected target, will engage that target.
A2ADispatcher:SetEngageRadius( 300000 )</p>
<p> -- Setup the squadrons.
A2ADispatcher:SetSquadron( "Mineralnye", AIRBASE.Caucasus.Mineralnye<em>Vody, { "SQ CCCP SU-27" }, 20 )
A2ADispatcher:SetSquadron( "Maykop", AIRBASE.Caucasus.Maykop</em>Khanskaya, { "SQ CCCP MIG-31" }, 20 )
A2ADispatcher:SetSquadron( "Mozdok", AIRBASE.Caucasus.Mozdok, { "SQ CCCP MIG-31" }, 20 )
A2ADispatcher:SetSquadron( "Sochi", AIRBASE.Caucasus.Sochi_Adler, { "SQ CCCP SU-27" }, 20 )
A2ADispatcher:SetSquadron( "Novo", AIRBASE.Caucasus.Novorossiysk, { "SQ CCCP SU-27" }, 20 )</p>
<p> -- Setup the overhead
A2ADispatcher:SetSquadronOverhead( "Mineralnye", 1.2 )
A2ADispatcher:SetSquadronOverhead( "Maykop", 1 )
A2ADispatcher:SetSquadronOverhead( "Mozdok", 1.5 )
A2ADispatcher:SetSquadronOverhead( "Sochi", 1 )
A2ADispatcher:SetSquadronOverhead( "Novo", 1 )</p>
<p> -- Setup the Grouping
A2ADispatcher:SetSquadronGrouping( "Mineralnye", 2 )
A2ADispatcher:SetSquadronGrouping( "Sochi", 2 )
A2ADispatcher:SetSquadronGrouping( "Novo", 3 )</p>
<p> -- Setup the Takeoff methods
A2ADispatcher:SetSquadronTakeoff( "Mineralnye", AI<em>A2A</em>DISPATCHER.Takeoff.Air )
A2ADispatcher:SetSquadronTakeoffInAir( "Sochi" )
A2ADispatcher:SetSquadronTakeoffFromRunway( "Mozdok" )
A2ADispatcher:SetSquadronTakeoffFromParkingCold( "Maykop" )
A2ADispatcher:SetSquadronTakeoffFromParkingHot( "Novo" )</p>
<p> -- Setup the Landing methods
A2ADispatcher:SetSquadronLandingAtRunway( "Mineralnye" )
A2ADispatcher:SetSquadronLandingNearAirbase( "Sochi" )
A2ADispatcher:SetSquadronLandingAtEngineShutdown( "Mozdok" )
A2ADispatcher:SetSquadronLandingNearAirbase( "Maykop" )
A2ADispatcher:SetSquadronLanding( "Novo", AI<em>A2A</em>DISPATCHER.Landing.AtRunway )</p>
<p> -- CAP Squadron execution.
CAPZoneEast = ZONE_POLYGON:New( "CAP Zone East", GROUP:FindByName( "CAP Zone East" ) )
A2ADispatcher:SetSquadronCap( "Mineralnye", CAPZoneEast, 4000, 10000, 500, 600, 800, 900 )
A2ADispatcher:SetSquadronCapInterval( "Mineralnye", 2, 30, 60, 1 )</p>
<p> CAPZoneWest = ZONE_POLYGON:New( "CAP Zone West", GROUP:FindByName( "CAP Zone West" ) )
A2ADispatcher:SetSquadronCap( "Sochi", CAPZoneWest, 4000, 8000, 600, 800, 800, 1200, "BARO" )
A2ADispatcher:SetSquadronCapInterval( "Sochi", 2, 30, 120, 1 )</p>
<p> CAPZoneMiddle = ZONE:New( "CAP Zone Middle")
A2ADispatcher:SetSquadronCap( "Maykop", CAPZoneMiddle, 4000, 8000, 600, 800, 800, 1200, "RADIO" )
A2ADispatcher:SetSquadronCapInterval( "Sochi", 2, 30, 120, 1 )</p>
<p> -- GCI Squadron execution.
A2ADispatcher:SetSquadronGci( "Mozdok", 900, 1200 )
A2ADispatcher:SetSquadronGci( "Novo", 900, 2100 )
A2ADispatcher:SetSquadronGci( "Maykop", 900, 1200 )</p>
<h4>8.5.1. Script the EWR network</h4>
<p><img src="..\Presentations\AI_A2A_DISPATCHER\Dia20.JPG" alt="Banner Image"/></p>
<h4>8.5.2. Script the AI_A2A_DISPATCHER object and configure it</h4>
<p><img src="..\Presentations\AI_A2A_DISPATCHER\Dia21.JPG" alt="Banner Image"/></p>
<h4>8.5.3. Script the squadrons</h4>
<p><img src="..\Presentations\AI_A2A_DISPATCHER\Dia22.JPG" alt="Banner Image"/></p>
<p>Create the squadrons using the <a href="##(AI_A2A_DISPATCHER).SetSquadron">AI<em>A2A</em>DISPATCHER.SetSquadron</a> objects using:</p>
<ul>
<li><a href="Zone.html##(ZONE)">Zone#ZONE</a> class to create a zone using a trigger zone set in the mission editor.</li>
<li><a href="Zone.html##(ZONE_UNIT)">Zone#ZONE_UNIT</a> class to create a zone around a unit object.</li>
<li><a href="Zone.html##(ZONE_GROUP)">Zone#ZONE_GROUP</a> class to create a zone around a group object.</li>
<li><a href="Zone.html##(ZONE_POLYGON)">Zone#ZONE_POLYGON</a> class to create a polygon zone using a late activated group object.</li>
</ul>
<p>Use the @{#AI<em>A2A</em>DISPATCHER.SetSquadronCap)() method to define CAP execution for the squadron, within the CAP zone defined.</p>
<p><img src="..\Presentations\AI_A2A_DISPATCHER\Dia26.JPG" alt="Banner Image"/></p>
<p>Use the @{#AI<em>A2A</em>DISPATCHER.SetSquadronCapInterval)() method to define how many CAP groups can be airborne at the same time, and the timing intervals.</p>
<p><img src="..\Presentations\AI_A2A_DISPATCHER\Dia27.JPG" alt="Banner Image"/></p>
<p>Use the @{#AI<em>A2A</em>DISPATCHER.SetSquadronGci)() method to define GCI execution for the squadron.</p>
<h2>9. Q &amp; A:</h2>
<h3>9.1. Which countries will be selected for each coalition?</h3>
<p>Which countries are assigned to a coalition influences which units are available to the coalition.
For example because the mission calls for a EWR radar on the blue side the Ukraine might be chosen as a blue country
@ -884,7 +1086,7 @@ so that the 55G6 EWR radar unit is available to blue. <br/>
Some countries assign different tasking to aircraft, for example Germany assigns the CAP task to F-4E Phantoms but the USA does not. <br/>
Therefore if F4s are wanted as a coalitions CAP or GCI aircraft Germany will need to be assigned to that coalition. </p>
<h3>8.2.Country, type, load out, skill and skins for CAP and GCI aircraft?</h3>
<h3>9.2.Country, type, load out, skill and skins for CAP and GCI aircraft?</h3>
<ul>
<li>Note these can be from any countries within the coalition but must be an aircraft with one of the main tasks being “CAP”.</li>

View File

@ -926,6 +926,9 @@ Use the method <a href="##(AI_PATROL_ZONE).ManageDamage">AI<em>PATROL</em>ZONE.M
<p> This table contains the targets detected during patrol.</p>
</dd>
</dl>
<dl class="function">

View File

@ -2934,7 +2934,6 @@ The range till cargo will board.</p>
<dl class="function">
<dt>
<em></em>
<a id="#(CARGO_UNIT).CargoCarrier" >
<strong>CARGO_UNIT.CargoCarrier</strong>
</a>

View File

@ -2559,7 +2559,7 @@ The index of the DetectedItem.</p>
<dl class="function">
<dt>
<em>#number</em>
<em></em>
<a id="#(DETECTION_BASE).DetectionInterval" >
<strong>DETECTION_BASE.DetectionInterval</strong>
</a>

View File

@ -2799,6 +2799,7 @@ The y coordinate.</p>
<dl class="function">
<dt>
<em></em>
<a id="#(POINT_VEC2).z" >
<strong>POINT_VEC2.z</strong>
</a>

View File

@ -3126,7 +3126,7 @@ Spawn_BE_KA50 = SPAWN:New( 'BE KA-50@RAMP-Ground Defense' ):Schedule( 600, 0.5 )
<dl class="function">
<dt>
<em>#boolean</em>
<em></em>
<a id="#(SPAWN).SpawnUnControlled" >
<strong>SPAWN.SpawnUnControlled</strong>
</a>

View File

@ -765,7 +765,6 @@ true if it is lasing</p>
<dl class="function">
<dt>
<em></em>
<a id="#(SPOT).ScheduleID" >
<strong>SPOT.ScheduleID</strong>
</a>
@ -779,7 +778,6 @@ true if it is lasing</p>
<dl class="function">
<dt>
<em></em>
<a id="#(SPOT).SpotIR" >
<strong>SPOT.SpotIR</strong>
</a>
@ -793,7 +791,6 @@ true if it is lasing</p>
<dl class="function">
<dt>
<em></em>
<a id="#(SPOT).SpotLaser" >
<strong>SPOT.SpotLaser</strong>
</a>
@ -807,7 +804,6 @@ true if it is lasing</p>
<dl class="function">
<dt>
<em></em>
<a id="#(SPOT).Target" >
<strong>SPOT.Target</strong>
</a>

View File

@ -510,7 +510,7 @@ based on the tasking capabilities defined in <a href="Task.html##(TASK)">Task#TA
<dl class="function">
<dt>
<em><a href="Core.Cargo.html##(CARGO_GROUP)">Core.Cargo#CARGO_GROUP</a></em>
<em></em>
<a id="#(FSM_PROCESS).Cargo" >
<strong>FSM_PROCESS.Cargo</strong>
</a>
@ -524,6 +524,7 @@ based on the tasking capabilities defined in <a href="Task.html##(TASK)">Task#TA
<dl class="function">
<dt>
<em></em>
<a id="#(FSM_PROCESS).DeployZone" >
<strong>FSM_PROCESS.DeployZone</strong>
</a>

Binary file not shown.

Before

Width:  |  Height:  |  Size: 116 KiB

After

Width:  |  Height:  |  Size: 116 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 102 KiB

After

Width:  |  Height:  |  Size: 102 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 99 KiB

After

Width:  |  Height:  |  Size: 99 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 122 KiB

After

Width:  |  Height:  |  Size: 125 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 124 KiB

After

Width:  |  Height:  |  Size: 122 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 125 KiB

After

Width:  |  Height:  |  Size: 124 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 160 KiB

After

Width:  |  Height:  |  Size: 72 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 96 KiB

After

Width:  |  Height:  |  Size: 96 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 83 KiB

After

Width:  |  Height:  |  Size: 83 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 96 KiB

After

Width:  |  Height:  |  Size: 96 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 102 KiB

After

Width:  |  Height:  |  Size: 102 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 100 KiB

After

Width:  |  Height:  |  Size: 100 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 100 KiB

After

Width:  |  Height:  |  Size: 100 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 97 KiB

After

Width:  |  Height:  |  Size: 97 KiB