@jtff/miztemplate-lib 3.10.14 → 4.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lua/lib/HoundElint.lua +11423 -11415
- package/lua/lib/Moose_.lua +26495 -35921
- package/lua/src/010-root_menus.lua +4 -3
- package/lua/src/020-mission_functions.lua +807 -217
- package/lua/src/110-set_clients.lua +53 -43
- package/lua/src/115-airbases.lua +191 -0
- package/lua/src/120-tankers.lua +577 -461
- package/lua/src/130-airboss.lua +1982 -440
- package/lua/src/150-awacs.lua +541 -445
- package/lua/src/160-atis.lua +136 -73
- package/lua/src/170-cap_zone_training.lua +176 -73
- package/lua/src/172-cap_zone_war.lua +383 -226
- package/lua/src/173-fox_zone_training.lua +142 -67
- package/lua/src/174-qra-scenario.lua +417 -362
- package/lua/src/176-random_air_traffic.lua +101 -12
- package/lua/src/178-training-intercept.lua +312 -261
- package/lua/src/180-logistics.lua +2 -2
- package/lua/src/190-ranges.lua +104 -37
- package/lua/src/191-sams.lua +4 -4
- package/lua/src/193-training_ranges.lua +2 -2
- package/lua/src/195-reaper-ondemand.lua +29 -29
- package/lua/src/196-fac_ranges.lua +2 -2
- package/lua/src/197-elint-ondemand.lua +53 -53
- package/lua/src/199-skynet.lua +55 -55
- package/package.json +1 -1
- package/scripts/inject-scripts.js +3 -31
- package/lua/src/135-pedro.lua +0 -21
- package/lua/src/140-beacons.lua +0 -19
|
@@ -7,7 +7,7 @@ function triggerOnDemandElintPlatform(type, askedDuration, askedFL, askedSpeed,
|
|
|
7
7
|
if (elintConfig) then
|
|
8
8
|
for index, onDemandPlatformConfig in ipairs(elintConfig.onDemandPlatforms) do
|
|
9
9
|
if ((onDemandPlatformConfig.type == type) and (onDemandPlatformConfig.enabled)) then
|
|
10
|
-
|
|
10
|
+
Jtff_log.debug(string.format('Found type %s ELINT : %s Group!', type, onDemandPlatformConfig.groupName),"ELINT")
|
|
11
11
|
if (askedSpeed and askedSpeed > 0) then
|
|
12
12
|
onDemandPlatformConfig.speed = askedSpeed
|
|
13
13
|
end
|
|
@@ -71,7 +71,7 @@ function triggerOnDemandElintPlatform(type, askedDuration, askedFL, askedSpeed,
|
|
|
71
71
|
local aliveELINTGroupList = set_group_elint:GetSetObjects()
|
|
72
72
|
|
|
73
73
|
local is_elint_spawned = false
|
|
74
|
-
|
|
74
|
+
Jtff_log.debug(string.format('Looking for a Group corresponding to template %s', string.format("%s-%s", onDemandPlatformConfig.groupName, onDemandPlatformConfig.type)),"ELINT")
|
|
75
75
|
for index, current_group in ipairs(aliveELINTGroupList) do
|
|
76
76
|
if (
|
|
77
77
|
(not(is_elint_spawned)) and
|
|
@@ -82,7 +82,7 @@ function triggerOnDemandElintPlatform(type, askedDuration, askedFL, askedSpeed,
|
|
|
82
82
|
true
|
|
83
83
|
) ~= nil)
|
|
84
84
|
) then
|
|
85
|
-
|
|
85
|
+
Jtff_log.info(string.format('Found %s corresponding to template %s', current_group.GroupName, string.format("%s-%s", onDemandPlatformConfig.groupName, onDemandPlatformConfig.type)),"ELINT")
|
|
86
86
|
is_elint_spawned = true
|
|
87
87
|
elintPlatformGroup = current_group
|
|
88
88
|
end
|
|
@@ -96,7 +96,7 @@ function triggerOnDemandElintPlatform(type, askedDuration, askedFL, askedSpeed,
|
|
|
96
96
|
RTBAirbase = askedAnchorCoord:GetClosestAirbase2(Airbase.Category.AIRDROME, GROUP:FindByName(onDemandPlatformConfig.groupName):GetCoalition())
|
|
97
97
|
end
|
|
98
98
|
if (is_elint_spawned) then
|
|
99
|
-
|
|
99
|
+
Jtff_log.info(
|
|
100
100
|
string.format(
|
|
101
101
|
'onDemand Elint already in air : rerouting %s',
|
|
102
102
|
onDemandPlatformConfig.groupName
|
|
@@ -155,7 +155,7 @@ function triggerOnDemandElintPlatform(type, askedDuration, askedFL, askedSpeed,
|
|
|
155
155
|
)
|
|
156
156
|
)
|
|
157
157
|
else
|
|
158
|
-
|
|
158
|
+
Jtff_log.info(
|
|
159
159
|
string.format(
|
|
160
160
|
'onDemandElint Spawning %s',
|
|
161
161
|
onDemandPlatformConfig.groupName
|
|
@@ -267,9 +267,9 @@ function triggerOnDemandElintPlatform(type, askedDuration, askedFL, askedSpeed,
|
|
|
267
267
|
elintPlatformGroup.escortSpawnObject = SPAWN:NewWithAlias(onDemandPlatformConfig.escortgroupname,'escort-'.. onDemandPlatformConfig.groupName)
|
|
268
268
|
:InitSkill("Excellent")
|
|
269
269
|
:OnSpawnGroup(function(SpawnGroup)
|
|
270
|
-
|
|
270
|
+
TaskGroupEscort({ elintPlatformGroup, SpawnGroup})
|
|
271
271
|
end)
|
|
272
|
-
elintPlatformGroup.escortGroupObject =
|
|
272
|
+
elintPlatformGroup.escortGroupObject = SpawnRecoveryTankerEscort(elintPlatformGroup.escortSpawnObject, onDemandPlatformConfig)
|
|
273
273
|
if onDemandPlatformConfig.missionmaxduration then
|
|
274
274
|
elintPlatformGroup.escortGroupObject:ScheduleOnce(onDemandPlatformConfig.missionmaxduration*60,
|
|
275
275
|
function(SpawnGroup, airBaseName)
|
|
@@ -282,10 +282,10 @@ function triggerOnDemandElintPlatform(type, askedDuration, askedFL, askedSpeed,
|
|
|
282
282
|
--trigger.action.outText('Tanker-escort configured to RTB in : '..(onDemandElint.missionmaxduration)..' minutes max...', 45)
|
|
283
283
|
end
|
|
284
284
|
end
|
|
285
|
-
if (
|
|
286
|
-
COORDINATE:RemoveMark(
|
|
285
|
+
if (Jtff_map_marker[elintPlatformGroup:GetName()]) then
|
|
286
|
+
COORDINATE:RemoveMark(Jtff_map_marker[elintPlatformGroup:GetName()])
|
|
287
287
|
end
|
|
288
|
-
|
|
288
|
+
Jtff_map_marker[elintPlatformGroup:GetName()] = askedAnchorCoord:MarkToCoalition(
|
|
289
289
|
string.format(
|
|
290
290
|
'OnDemand ELINT %s\nFL %i at %i knots\nOn station for %i minutes\nRacetrack : %i ° for %i nm',
|
|
291
291
|
onDemandPlatformConfig.type,
|
|
@@ -303,12 +303,12 @@ function triggerOnDemandElintPlatform(type, askedDuration, askedFL, askedSpeed,
|
|
|
303
303
|
elintPlatformGroup:HandleEvent(EVENTS.Crash)
|
|
304
304
|
elintPlatformGroup:HandleEvent(EVENTS.Dead)
|
|
305
305
|
function elintPlatformGroup:OnEventLand(EventData)
|
|
306
|
-
COORDINATE:RemoveMark(
|
|
306
|
+
COORDINATE:RemoveMark(Jtff_map_marker[self:GetName()])
|
|
307
307
|
elintNetworksArray[findElintNetworkIndexByCoalition(self:GetCoalition())].networkObject:removePlatform(self:GetFirstUnit():GetName())
|
|
308
308
|
if self.customconfig.escortgroupname then
|
|
309
|
-
|
|
309
|
+
Jtff_log.info('RTB: '..self.GroupName..'...',"ELINT")
|
|
310
310
|
if self.escortGroupObject:IsAirborne(false) == true then
|
|
311
|
-
|
|
311
|
+
Jtff_log.info('escort RTB : '.. self.escortGroupObject.GroupName..' ELINT : '..self.GroupName..'...',"ELINT")
|
|
312
312
|
self.escortGroupObject:RouteRTB()
|
|
313
313
|
else
|
|
314
314
|
--self.escortGroupObject:Destroy(nil, 5)
|
|
@@ -316,12 +316,12 @@ function triggerOnDemandElintPlatform(type, askedDuration, askedFL, askedSpeed,
|
|
|
316
316
|
end
|
|
317
317
|
end
|
|
318
318
|
function elintPlatformGroup:OnEventCrash(EventData)
|
|
319
|
-
COORDINATE:RemoveMark(
|
|
319
|
+
COORDINATE:RemoveMark(Jtff_map_marker[self:GetName()])
|
|
320
320
|
elintNetworksArray[findElintNetworkIndexByCoalition(self:GetCoalition())].networkObject:removePlatform(self:GetFirstUnit():GetName())
|
|
321
321
|
if self.customconfig.escortgroupname then
|
|
322
|
-
|
|
322
|
+
Jtff_log.info('RTB: '..self.GroupName..'...',"ELINT")
|
|
323
323
|
if self.escortGroupObject:IsAirborne(false) == true then
|
|
324
|
-
|
|
324
|
+
Jtff_log.info('escort RTB : '.. self.escortGroupObject.GroupName..' ELINT : '..self.GroupName..'...',"ELINT")
|
|
325
325
|
self.escortGroupObject:RouteRTB()
|
|
326
326
|
else
|
|
327
327
|
--self.escortGroupObject:Destroy(nil, 5)
|
|
@@ -329,12 +329,12 @@ function triggerOnDemandElintPlatform(type, askedDuration, askedFL, askedSpeed,
|
|
|
329
329
|
end
|
|
330
330
|
end
|
|
331
331
|
function elintPlatformGroup:OnEventDead(EventData)
|
|
332
|
-
COORDINATE:RemoveMark(
|
|
332
|
+
COORDINATE:RemoveMark(Jtff_map_marker[self:GetName()])
|
|
333
333
|
elintNetworksArray[findElintNetworkIndexByCoalition(self:GetCoalition())].networkObject:removePlatform(self:GetFirstUnit():GetName())
|
|
334
334
|
if self.customconfig.escortgroupname then
|
|
335
|
-
|
|
335
|
+
Jtff_log.info('RTB: '..self.GroupName..'...',"ELINT")
|
|
336
336
|
if self.escortGroupObject:IsAirborne(false) == true then
|
|
337
|
-
|
|
337
|
+
Jtff_log.info('escort RTB : '.. self.escortGroupObject.GroupName..' ELINT : '..self.GroupName..'...',"ELINT")
|
|
338
338
|
self.escortGroupObject:RouteRTB()
|
|
339
339
|
else
|
|
340
340
|
--self.escortGroupObject:Destroy(nil, 5)
|
|
@@ -370,7 +370,7 @@ function createElintAirborneControllerSpawnObject(networkIndex)
|
|
|
370
370
|
)
|
|
371
371
|
)
|
|
372
372
|
if (type(spawnObject) == "nil") then
|
|
373
|
-
|
|
373
|
+
Jtff_log.error(
|
|
374
374
|
string.format(
|
|
375
375
|
'Controller SPAWN Object: The ELINT controller template %s not found...',
|
|
376
376
|
elintnetworkconfig.controller.groupName
|
|
@@ -409,7 +409,7 @@ function createElintAirborneControllerSpawnObject(networkIndex)
|
|
|
409
409
|
else
|
|
410
410
|
spawnObject:InitRadioCommsOnOff(false)
|
|
411
411
|
end
|
|
412
|
-
|
|
412
|
+
Jtff_log.info(
|
|
413
413
|
string.format(
|
|
414
414
|
'Controller SPAWN Object: The SpawnObject is created. Template group is %s ...',
|
|
415
415
|
elintnetworkconfig.controller.groupName
|
|
@@ -477,7 +477,7 @@ function airborneControllerOnSpawnGroup(spawnedGroup,networkIndex)
|
|
|
477
477
|
elintNetworksArray[self.elintnetworkindex].networkObject:removePlatform(spawnedGroup:GetFirstUnit():GetName())
|
|
478
478
|
stopElintNetwork(self.elintnetworkindex)
|
|
479
479
|
end
|
|
480
|
-
|
|
480
|
+
Jtff_log.debug(
|
|
481
481
|
string.format(
|
|
482
482
|
'airborne Controller Group: AirController group %s is spawned and setup...',
|
|
483
483
|
spawnedGroup:GetName()
|
|
@@ -491,7 +491,7 @@ function spawnElintAirborneControllerFromSpawn(spawnObject,networkIndex)
|
|
|
491
491
|
local controllerGroup = nil
|
|
492
492
|
local controllerConfig = elintnetworkconfig.controller
|
|
493
493
|
if (type(elintNetworksArray[networkIndex].customconfig.controller) == "nil") then
|
|
494
|
-
|
|
494
|
+
Jtff_log.error(
|
|
495
495
|
string.format(
|
|
496
496
|
'Airborne Controller: No controller paragraph in the network %i config...',
|
|
497
497
|
networkIndex
|
|
@@ -538,7 +538,7 @@ function spawnElintAirborneControllerFromSpawn(spawnObject,networkIndex)
|
|
|
538
538
|
end
|
|
539
539
|
end
|
|
540
540
|
if (type(controllerGroup) == "nil") then
|
|
541
|
-
|
|
541
|
+
Jtff_log.error(
|
|
542
542
|
string.format(
|
|
543
543
|
'Airborne Controller: impossible to spawn airborne ELINT controller based on template %s...',
|
|
544
544
|
controllerConfig.groupName
|
|
@@ -553,7 +553,7 @@ end
|
|
|
553
553
|
function setupElintNetworkwithController(networkIndex, controllerUnitName)
|
|
554
554
|
local elintnetworkconfig = elintNetworksArray[networkIndex].customconfig
|
|
555
555
|
elintNetworksArray[networkIndex].networkObject:setTransmitter(controllerUnitName)
|
|
556
|
-
|
|
556
|
+
Jtff_log.info(
|
|
557
557
|
string.format(
|
|
558
558
|
'Controller setup ELINT: Transmitter added for network %s.',
|
|
559
559
|
UTILS.GetCoalitionName(elintnetworkconfig.coalition)
|
|
@@ -569,7 +569,7 @@ function setupElintNetworkwithController(networkIndex, controllerUnitName)
|
|
|
569
569
|
})
|
|
570
570
|
elintNetworksArray[networkIndex].networkObject:setAtisUpdateInterval(15*60)
|
|
571
571
|
elintNetworksArray[networkIndex].networkObject:enableAtis()
|
|
572
|
-
|
|
572
|
+
Jtff_log.info(
|
|
573
573
|
string.format(
|
|
574
574
|
'Controller setup ELINT: Atis enabled for network %s.',
|
|
575
575
|
UTILS.GetCoalitionName(elintnetworkconfig.coalition)
|
|
@@ -578,7 +578,7 @@ function setupElintNetworkwithController(networkIndex, controllerUnitName)
|
|
|
578
578
|
)
|
|
579
579
|
else
|
|
580
580
|
elintNetworksArray[networkIndex].networkObject:disableAtis()
|
|
581
|
-
|
|
581
|
+
Jtff_log.debug(
|
|
582
582
|
string.format(
|
|
583
583
|
'Controller setup ELINT: Atis disabled for network %s.',
|
|
584
584
|
UTILS.GetCoalitionName(elintnetworkconfig.coalition)
|
|
@@ -594,7 +594,7 @@ function setupElintNetworkwithController(networkIndex, controllerUnitName)
|
|
|
594
594
|
gender = "male",
|
|
595
595
|
})
|
|
596
596
|
elintNetworksArray[networkIndex].networkObject:enableNotifier()
|
|
597
|
-
|
|
597
|
+
Jtff_log.info(
|
|
598
598
|
string.format(
|
|
599
599
|
'Controller setup ELINT: Notifyer enabled for network %s.',
|
|
600
600
|
UTILS.GetCoalitionName(elintnetworkconfig.coalition)
|
|
@@ -603,7 +603,7 @@ function setupElintNetworkwithController(networkIndex, controllerUnitName)
|
|
|
603
603
|
)
|
|
604
604
|
else
|
|
605
605
|
elintNetworksArray[networkIndex].networkObject:disableNotifier()
|
|
606
|
-
|
|
606
|
+
Jtff_log.debug(
|
|
607
607
|
string.format(
|
|
608
608
|
'Controller setup ELINT: Notifyer disabled for network %s.',
|
|
609
609
|
UTILS.GetCoalitionName(elintnetworkconfig.coalition)
|
|
@@ -619,7 +619,7 @@ function setupElintNetworkwithController(networkIndex, controllerUnitName)
|
|
|
619
619
|
gender = "female",
|
|
620
620
|
})
|
|
621
621
|
elintNetworksArray[networkIndex].networkObject:enableController()
|
|
622
|
-
|
|
622
|
+
Jtff_log.info(
|
|
623
623
|
string.format(
|
|
624
624
|
'Controller setup ELINT: Controller enabled for network %s.',
|
|
625
625
|
UTILS.GetCoalitionName(elintnetworkconfig.coalition)
|
|
@@ -628,7 +628,7 @@ function setupElintNetworkwithController(networkIndex, controllerUnitName)
|
|
|
628
628
|
)
|
|
629
629
|
if (elintnetworkconfig.enableAlerts == false) then
|
|
630
630
|
elintNetworksArray[networkIndex].networkObject:disableAlerts()
|
|
631
|
-
|
|
631
|
+
Jtff_log.debug(
|
|
632
632
|
string.format(
|
|
633
633
|
'Controller setup ELINT: Alerting disabled for network %s.',
|
|
634
634
|
UTILS.GetCoalitionName(elintnetworkconfig.coalition)
|
|
@@ -637,7 +637,7 @@ function setupElintNetworkwithController(networkIndex, controllerUnitName)
|
|
|
637
637
|
)
|
|
638
638
|
else
|
|
639
639
|
elintNetworksArray[networkIndex].networkObject:enableAlerts()
|
|
640
|
-
|
|
640
|
+
Jtff_log.info(
|
|
641
641
|
string.format(
|
|
642
642
|
'Controller setup ELINT: Alerting enabled for network %s.',
|
|
643
643
|
UTILS.GetCoalitionName(elintnetworkconfig.coalition)
|
|
@@ -647,7 +647,7 @@ function setupElintNetworkwithController(networkIndex, controllerUnitName)
|
|
|
647
647
|
end
|
|
648
648
|
else
|
|
649
649
|
elintNetworksArray[networkIndex].networkObject:disableController()
|
|
650
|
-
|
|
650
|
+
Jtff_log.debug(
|
|
651
651
|
string.format(
|
|
652
652
|
'Controller setup ELINT: Controller disabled for network %s.',
|
|
653
653
|
UTILS.GetCoalitionName(elintnetworkconfig.coalition)
|
|
@@ -656,7 +656,7 @@ function setupElintNetworkwithController(networkIndex, controllerUnitName)
|
|
|
656
656
|
)
|
|
657
657
|
end
|
|
658
658
|
elintNetworksArray[networkIndex].networkObject:systemOn(elintnetworkconfig.debug)
|
|
659
|
-
|
|
659
|
+
Jtff_log.info(
|
|
660
660
|
string.format(
|
|
661
661
|
'Controller setup ELINT: Network %s is started !',
|
|
662
662
|
UTILS.GetCoalitionName(elintnetworkconfig.coalition)
|
|
@@ -670,7 +670,7 @@ function initializeElintNetwork(networkIndex)
|
|
|
670
670
|
local elintnetworkconfig = elintNetworksArray[networkIndex].customconfig
|
|
671
671
|
--create the network
|
|
672
672
|
elintNetworksArray[networkIndex].networkObject = createHoundElintObject(networkIndex)
|
|
673
|
-
|
|
673
|
+
Jtff_log.info('init ELINT : '.. UTILS.GetCoalitionName(elintnetworkconfig.coalition) ..'...',"ELINT")
|
|
674
674
|
if (type(elintNetworksArray[networkIndex].rootMenu) == "nil") then
|
|
675
675
|
elintNetworksArray[networkIndex].rootMenu = createELintRootMenu(networkIndex)
|
|
676
676
|
end
|
|
@@ -682,7 +682,7 @@ function initializeElintNetwork(networkIndex)
|
|
|
682
682
|
initializeElintNetwork,
|
|
683
683
|
networkIndex
|
|
684
684
|
)
|
|
685
|
-
|
|
685
|
+
Jtff_log.info('init ELINT : Start menu created for coalition '.. UTILS.GetCoalitionName(elintnetworkconfig.coalition) ..'...',"ELINT")
|
|
686
686
|
end
|
|
687
687
|
--Manage the menus
|
|
688
688
|
elintNetworksArray[networkIndex].networkObject:setRadioMenuParent(elintNetworksArray[networkIndex].rootMenu.MenuPath)
|
|
@@ -718,7 +718,7 @@ function initializeElintNetwork(networkIndex)
|
|
|
718
718
|
--Manage EWR reporting
|
|
719
719
|
elintNetworksArray[networkIndex].networkObject:reportEWR(elintnetworkconfig.reportEWR or true)
|
|
720
720
|
startElintController(networkIndex)
|
|
721
|
-
|
|
721
|
+
Jtff_log.info('init ELINT : Elint network '.. UTILS.GetCoalitionName(elintnetworkconfig.coalition) ..' initialized...',"ELINT")
|
|
722
722
|
return elintNetworksArray[networkIndex]
|
|
723
723
|
end
|
|
724
724
|
|
|
@@ -731,7 +731,7 @@ function startElintAirborneController(networkIndex)
|
|
|
731
731
|
end
|
|
732
732
|
if (type(elintNetworksArray[networkIndex].controllerSpawnObject) == "nil") then
|
|
733
733
|
-- still no spawnObject present ==> error and return nil
|
|
734
|
-
|
|
734
|
+
Jtff_log.error(
|
|
735
735
|
string.format(
|
|
736
736
|
'Airborne ControllerUnit: impossible to create a spawn object based on template %s...',
|
|
737
737
|
elintnetworkconfig.controller.groupName
|
|
@@ -748,7 +748,7 @@ function startElintAirborneController(networkIndex)
|
|
|
748
748
|
)
|
|
749
749
|
if (type(elintNetworksArray[networkIndex].controllerGroup) == "nil") then
|
|
750
750
|
-- still no controllerGroup present ==> error and return nil
|
|
751
|
-
|
|
751
|
+
Jtff_log.error(
|
|
752
752
|
string.format(
|
|
753
753
|
'Airborne ControllerUnit: impossible to create a spawn object based on template %s...',
|
|
754
754
|
elintnetworkconfig.controller.groupName
|
|
@@ -758,7 +758,7 @@ function startElintAirborneController(networkIndex)
|
|
|
758
758
|
return nil
|
|
759
759
|
end
|
|
760
760
|
end
|
|
761
|
-
|
|
761
|
+
Jtff_log.info(
|
|
762
762
|
string.format(
|
|
763
763
|
'Airborne ControllerUnit: Group %s is created and routed properly...',
|
|
764
764
|
elintNetworksArray[networkIndex].controllerGroup:GetFirstUnit():GetName()
|
|
@@ -816,7 +816,7 @@ function startElintController(networkIndex)
|
|
|
816
816
|
else
|
|
817
817
|
setupElintNetworkwithController(networkIndex, startElintStaticController(networkIndex))
|
|
818
818
|
end
|
|
819
|
-
|
|
819
|
+
Jtff_log.info(
|
|
820
820
|
string.format(
|
|
821
821
|
'Controller start ELINT: Controller unit for %s network started !',
|
|
822
822
|
UTILS.GetCoalitionName(elintnetworkconfig.coalition)
|
|
@@ -832,7 +832,7 @@ function startElintController(networkIndex)
|
|
|
832
832
|
stopElintNetwork,
|
|
833
833
|
networkIndex
|
|
834
834
|
)
|
|
835
|
-
|
|
835
|
+
Jtff_log.info(
|
|
836
836
|
string.format(
|
|
837
837
|
'Controller start ELINT: network menu %s is updated !',
|
|
838
838
|
UTILS.GetCoalitionName(elintnetworkconfig.coalition)
|
|
@@ -841,7 +841,7 @@ function startElintController(networkIndex)
|
|
|
841
841
|
)
|
|
842
842
|
return elintNetworksArray[networkIndex].networkObject
|
|
843
843
|
else
|
|
844
|
-
|
|
844
|
+
Jtff_log.error(
|
|
845
845
|
string.format(
|
|
846
846
|
'controller config: No controller paragraph in the network %i config...',
|
|
847
847
|
networkIndex
|
|
@@ -907,7 +907,7 @@ end
|
|
|
907
907
|
function routeElintController(controllerGroup, configIndex)
|
|
908
908
|
local controllerRoute = {}
|
|
909
909
|
local networkConfig = elintNetworksArray[configIndex].customconfig
|
|
910
|
-
|
|
910
|
+
Jtff_log.debug(
|
|
911
911
|
string.format(
|
|
912
912
|
'Airborne Controller routing : controller popped %s based on template %s',
|
|
913
913
|
controllerGroup:GetName(),
|
|
@@ -969,7 +969,7 @@ function routeElintController(controllerGroup, configIndex)
|
|
|
969
969
|
)
|
|
970
970
|
)
|
|
971
971
|
controllerGroup:Route(controllerRoute)
|
|
972
|
-
|
|
972
|
+
Jtff_log.debug(
|
|
973
973
|
string.format(
|
|
974
974
|
'Airborne Controller routing : controller %s routed',
|
|
975
975
|
controllerGroup:GetName()
|
|
@@ -980,15 +980,15 @@ end
|
|
|
980
980
|
|
|
981
981
|
function createELintRootMenu(networkIndex)
|
|
982
982
|
local elintnetworkconfig = elintNetworksArray[networkIndex].customconfig
|
|
983
|
-
|
|
983
|
+
Jtff_log.info('ELINT RootMenu: creating for coalition '.. UTILS.GetCoalitionName(elintnetworkconfig.coalition) ..'...',"ELINT")
|
|
984
984
|
if (elintnetworkconfig.coalition == coalition.side.BLUE) then
|
|
985
|
-
return MENU_COALITION:New(coalition.side.BLUE, "OnDemand ELint",
|
|
985
|
+
return MENU_COALITION:New(coalition.side.BLUE, "OnDemand ELint", MenuCoalition[coalition.side.BLUE])
|
|
986
986
|
elseif (elintnetworkconfig.coalition == coalition.side.RED) then
|
|
987
|
-
return MENU_COALITION:New(coalition.side.RED, "OnDemand ELint",
|
|
987
|
+
return MENU_COALITION:New(coalition.side.RED, "OnDemand ELint", MenuCoalition[coalition.side.RED])
|
|
988
988
|
elseif (elintnetworkconfig.coalition == coalition.side.NEUTRAL) then
|
|
989
|
-
return MENU_COALITION:New(coalition.side.NEUTRAL, "OnDemand ELint",
|
|
989
|
+
return MENU_COALITION:New(coalition.side.NEUTRAL, "OnDemand ELint", MenuCoalition[coalition.side.NEUTRAL])
|
|
990
990
|
else
|
|
991
|
-
|
|
991
|
+
Jtff_log.error('ELINT RootMenu: error in the coalition config...',"ELINT")
|
|
992
992
|
return nil
|
|
993
993
|
end
|
|
994
994
|
end
|
|
@@ -1005,7 +1005,7 @@ local compteur = 0
|
|
|
1005
1005
|
for indexElintNetwork, elintnetworkconfig in ipairs(elintConfig.networks) do
|
|
1006
1006
|
if elintnetworkconfig.enabled == true then
|
|
1007
1007
|
compteur = compteur + 1
|
|
1008
|
-
|
|
1008
|
+
Jtff_log.info('configuration ELINT : '.. UTILS.GetCoalitionName(elintnetworkconfig.coalition) ..'...',"ELINT")
|
|
1009
1009
|
elintNetworksArray[compteur] = {
|
|
1010
1010
|
customconfig = elintnetworkconfig,
|
|
1011
1011
|
networkObject = nil,
|
|
@@ -1099,7 +1099,7 @@ function elintMarkHandler:onEvent(event)
|
|
|
1099
1099
|
else
|
|
1100
1100
|
cmd = full
|
|
1101
1101
|
end
|
|
1102
|
-
if
|
|
1102
|
+
if Log_levels[JTFF_LOGLEVEL] <= Log_levels['debug'] then
|
|
1103
1103
|
trigger.action.outText("Full Text = " .. full, 10)
|
|
1104
1104
|
trigger.action.outText("Command = " .. cmd, 10)
|
|
1105
1105
|
if param1 ~= nil then trigger.action.outText("type = " .. param1, 10) end
|
|
@@ -1111,7 +1111,7 @@ function elintMarkHandler:onEvent(event)
|
|
|
1111
1111
|
end
|
|
1112
1112
|
|
|
1113
1113
|
if string.find(cmd, "elint") then
|
|
1114
|
-
if
|
|
1114
|
+
if Log_levels[JTFF_LOGLEVEL] <= Log_levels['debug'] then
|
|
1115
1115
|
trigger.action.outText("DEBUG: On Demand ELint Started!", 10)
|
|
1116
1116
|
end
|
|
1117
1117
|
triggerOnDemandElintPlatform(
|