Compare commits

..

2868 Commits

Author SHA1 Message Date
Applevangelist
84857d2a32 Merge remote-tracking branch 'origin/master' into develop 2024-05-04 13:10:30 +02:00
Applevangelist
cc17027a7a #AIRBASE
- Added Kola map AFBs to enumerator
2024-05-04 13:09:58 +02:00
Applevangelist
02db5ba532 Merge remote-tracking branch 'origin/master' into develop 2024-05-01 13:52:39 +02:00
Applevangelist
fc52e06318 #CSAR #CTLD - Added OH-6A 2024-05-01 13:52:10 +02:00
Applevangelist
0f5f2658a6 Merge remote-tracking branch 'origin/master' into develop 2024-04-30 09:20:07 +02:00
Applevangelist
27d36f3e0d #BEACON - some fixes 2024-04-30 09:18:49 +02:00
Thomas
9ce1b90eb1 STRATEGO (#2123)
Added option to set Capture Object Categories (ie static and/or units) to capture a node.
2024-04-29 10:50:48 +02:00
Applevangelist
38c19b1442 Merge remote-tracking branch 'origin/master' into develop 2024-04-27 17:29:41 +02:00
Applevangelist
d3419d218a #WEAPON - Added IsFoxOne().. IsFoxThree() 2024-04-27 17:28:36 +02:00
Thomas
2f34526c55 Update build-docs.yml 2024-04-24 13:26:51 +02:00
Thomas
f9dcc9d95c Update build-includes.yml 2024-04-24 13:21:24 +02:00
Thomas
ebc355ee6a Shapes - added images (#2122)
* Update Triangle.lua (#2121)

* Update Polygon.lua (#2120)

* Update Oval.lua (#2119)

* Update Line.lua (#2118)

* Update Cube.lua (#2117)

* Update Circle.lua (#2116)
2024-04-24 10:46:16 +02:00
Thomas
a0b49fbd67 Update Circle.lua (#2116) 2024-04-24 10:42:19 +02:00
Thomas
ae213c4cf1 Update Cube.lua (#2117) 2024-04-24 10:42:04 +02:00
Thomas
8dea86b921 Update Line.lua (#2118) 2024-04-24 10:41:49 +02:00
Thomas
44003a8fda Update Oval.lua (#2119) 2024-04-24 10:41:33 +02:00
Thomas
b883bb1e62 Update Polygon.lua (#2120) 2024-04-24 10:41:19 +02:00
Thomas
db35a67bd7 Update Triangle.lua (#2121) 2024-04-24 10:40:54 +02:00
Frank
1bfc98fa99 Merge pull request #2115 from FlightControl-Master/FF/OpsRat
RAT v3.0
2024-04-23 23:21:56 +02:00
Frank
efb687cbb5 Update Base.lua 2024-04-23 23:18:53 +02:00
Frank
668f12391e Merge branch 'develop' into FF/OpsRat 2024-04-23 23:12:31 +02:00
Frank
dfaccd6aa5 Update Message.lua 2024-04-23 23:12:17 +02:00
Applevangelist
2220f1829f #STRATEGO -- add SetStrategoZone 2024-04-23 10:13:09 +02:00
Applevangelist
76fde11f47 Merge remote-tracking branch 'origin/master' into develop 2024-04-23 09:26:11 +02:00
Applevangelist
bc5946c76e #SHAPES a bit of extra docu 2024-04-23 09:25:47 +02:00
Applevangelist
1f041a8acf Merge remote-tracking branch 'origin/master' into develop 2024-04-23 09:18:07 +02:00
Thomas
892cb90d62 Adding Shapes (#2114)
* Adding SHAPES (#2110)

* Adding a new TerminalType (100)that seems to be introduced in the update that brought Muwaffaq Salti. The base has a couple of spots (like 04, 05, 06) that can only accommodate smaller type fixed wing aircraft, like the F-16, but not bigger types like the Warthog of the Strike Eagle.

Because we weren't checking for this new type, spawning in these particular spots always resulted in an airstart, because `_CheckTerminalType` would always return `false`

* Adding Shapes over from old MOOSE branch

* cleanup

* adding HEXtoRGBA

* Revert "Adding SHAPES (#2110)" (#2112)

This reverts commit 26deaca166.

* Adding SHAPES (#2113)

* Adding a new TerminalType (100)that seems to be introduced in the update that brought Muwaffaq Salti. The base has a couple of spots (like 04, 05, 06) that can only accommodate smaller type fixed wing aircraft, like the F-16, but not bigger types like the Warthog of the Strike Eagle.

Because we weren't checking for this new type, spawning in these particular spots always resulted in an airstart, because `_CheckTerminalType` would always return `false`

* Adding Shapes over from old MOOSE branch

* cleanup

* adding HEXtoRGBA

* removing Arrow.lua, it's part of Polygon.lua

---------

Co-authored-by: Niels Vaes <nielsvaes@gmail.com>
2024-04-23 09:16:44 +02:00
Niels Vaes
3d7172fdf7 Adding SHAPES (#2113)
* Adding a new TerminalType (100)that seems to be introduced in the update that brought Muwaffaq Salti. The base has a couple of spots (like 04, 05, 06) that can only accommodate smaller type fixed wing aircraft, like the F-16, but not bigger types like the Warthog of the Strike Eagle.

Because we weren't checking for this new type, spawning in these particular spots always resulted in an airstart, because `_CheckTerminalType` would always return `false`

* Adding Shapes over from old MOOSE branch

* cleanup

* adding HEXtoRGBA

* removing Arrow.lua, it's part of Polygon.lua
2024-04-23 09:13:52 +02:00
Frank
3fa3644e1e ARMYGROUP
- on road fix
2024-04-21 10:58:13 +02:00
Thomas
28411d2093 Revert "Adding SHAPES (#2110)" (#2112)
This reverts commit 26deaca166.
2024-04-21 10:12:51 +02:00
Niels Vaes
26deaca166 Adding SHAPES (#2110)
* Adding a new TerminalType (100)that seems to be introduced in the update that brought Muwaffaq Salti. The base has a couple of spots (like 04, 05, 06) that can only accommodate smaller type fixed wing aircraft, like the F-16, but not bigger types like the Warthog of the Strike Eagle.

Because we weren't checking for this new type, spawning in these particular spots always resulted in an airstart, because `_CheckTerminalType` would always return `false`

* Adding Shapes over from old MOOSE branch

* cleanup

* adding HEXtoRGBA
2024-04-21 10:08:06 +02:00
Applevangelist
1346317ad9 #STRATEGO - add functions to set weight, baseweight manually# 2024-04-20 16:21:02 +02:00
Applevangelist
e11bb71c2d Merge remote-tracking branch 'origin/master' into develop 2024-04-19 15:58:17 +02:00
Applevangelist
95baed1aac #GROUP - make GetCoordinate a bit more robust 2024-04-19 15:57:43 +02:00
Applevangelist
3b364c7650 #SPAWN - less noise 2024-04-19 15:57:21 +02:00
Applevangelist
2a4e242eb2 #AI* minor fixes 2024-04-19 15:54:21 +02:00
Applevangelist
39471212d3 Merge remote-tracking branch 'origin/master' into develop 2024-04-19 15:45:33 +02:00
Applevangelist
8b2237d183 #CTLD small G fix 2024-04-19 15:45:11 +02:00
Applevangelist
6c1a4f1e0d Merge remote-tracking branch 'origin/master' into develop 2024-04-19 11:33:41 +02:00
Applevangelist
abc26b1e5c #CSAR Add'l logging 2024-04-19 11:33:15 +02:00
Applevangelist
b338f486e5 Merge remote-tracking branch 'origin/master' into develop 2024-04-18 18:41:29 +02:00
Applevangelist
b761078c18 XXX 2024-04-18 18:40:59 +02:00
Applevangelist
202d649085 Merge remote-tracking branch 'origin/master' into develop 2024-04-18 14:52:21 +02:00
Applevangelist
616690391c SADL/STN conversion fix 2024-04-18 14:51:41 +02:00
Applevangelist
e1e0095d9b Merge remote-tracking branch 'origin/master' into develop 2024-04-18 14:42:12 +02:00
Applevangelist
465c395294 SPAWN - Allow setting of "hidden" options 2024-04-18 14:41:29 +02:00
Frank
a8cbf81851 Merge branch 'FF/Ops' into FF/OpsRat 2024-04-18 10:36:42 +02:00
Frank
0e78e9c92b Merge branch 'develop' into FF/Ops 2024-04-18 10:36:28 +02:00
Applevangelist
7c4d640690 Merge remote-tracking branch 'origin/master' into develop 2024-04-18 09:30:56 +02:00
Applevangelist
73bddddba4 #CTLD - ensure extracting troops are not diverted 2024-04-18 09:30:35 +02:00
Frank
833206a3b5 RAT
- Uncontrolled
2024-04-16 16:42:26 +02:00
Applevangelist
743baac945 Small fix for callsign not traversing from Squadron to Flightgroup 2024-04-16 16:01:43 +02:00
Applevangelist
0764d076db Housekeeping 2024-04-16 08:46:06 +02:00
Applevangelist
504aa19c03 Merge remote-tracking branch 'origin/master' into develop 2024-04-15 18:54:46 +02:00
Applevangelist
9a3effd063 Docu 2024-04-15 18:54:22 +02:00
Applevangelist
d4a49ae68b #CLIENTMENU/MANAGER
* Attempt to avoid dual menu builds for multi-seated aircraft
2024-04-15 12:52:19 +02:00
Applevangelist
ca1018f80b Merge remote-tracking branch 'origin/master' into develop 2024-04-15 08:58:37 +02:00
Niels Vaes
b9bd8d88a9 Adding a new TerminalType (100)that seems to be introduced in the update that brought Muwaffaq Salti. The base has a couple of spots (like 04, 05, 06) that can only accommodate smaller type fixed wing aircraft, like the F-16, but not bigger types like the Warthog of the Strike Eagle. (#2109)
Because we weren't checking for this new type, spawning in these particular spots always resulted in an airstart, because `_CheckTerminalType` would always return `false`
2024-04-15 08:57:28 +02:00
Frank
21412e0061 Update RAT.lua
- Added Stop function
2024-04-08 01:18:04 +02:00
Frank
5761e11157 Merge branch 'develop' into FF/OpsRat 2024-04-07 22:58:44 +02:00
Frank
7d3f1235e7 Update RAT.lua
- respawn on landing adjustment
2024-04-05 23:57:54 +02:00
Frank
473001c95b Update RAT.lua 2024-04-04 23:50:24 +02:00
Frank
532cc0b4df RAT
- options set via flightgroup
- fixed little bug in OPSGROUP emission default
2024-04-04 23:39:56 +02:00
Frank
08fb4e3736 Update RAT.lua
- Improved ATC and FLIGHTCONTROL integration
2024-04-04 19:08:18 +02:00
Applevangelist
6b7e66efa5 Merge remote-tracking branch 'origin/master' into develop 2024-04-04 17:23:08 +02:00
Applevangelist
18fd587ab0 xx 2024-04-04 17:22:46 +02:00
Frank
5fd8139f00 Update RAT.lua
- RATMANAGER
2024-04-04 14:21:52 +02:00
Frank
ac68744deb Merge branch 'FF/Ops' into FF/OpsRat 2024-04-04 09:36:13 +02:00
Frank
cec02bc44f Merge branch 'develop' into FF/Ops 2024-04-04 09:34:37 +02:00
Frank
a924a0b641 Update RAT.lua 2024-04-03 21:56:24 +02:00
Frank
ee15b04142 Update RAT.lua 2024-04-03 14:27:10 +02:00
Frank
2c67a66d88 Update RAT.lua 2024-04-02 23:18:30 +02:00
Frank
1fdb3b7daa RAT
- Improved respawn/despawn
- Added stuck check
2024-04-02 17:33:41 +02:00
Applevangelist
181ed6046e Merge remote-tracking branch 'origin/master' into develop 2024-04-02 13:23:21 +02:00
Applevangelist
ba14330281 Fix for counting alive target units only 2024-04-02 13:22:54 +02:00
Applevangelist
4c890d18d1 Merge remote-tracking branch 'origin/master' into develop 2024-04-02 10:48:57 +02:00
Applevangelist
2eb4118d56 xxx 2024-04-02 10:47:58 +02:00
Applevangelist
67d53034df bugfix 2024-04-01 19:11:53 +02:00
Applevangelist
b4d1118c88 Merge remote-tracking branch 'origin/master' into develop 2024-04-01 12:59:39 +02:00
Applevangelist
dcc15afb89 xxx 2024-04-01 12:59:14 +02:00
Frank
a5632ec3a4 RAT
- More cleanup

OPSGROUP
- Fixed group init (masterunit)
2024-03-31 23:33:37 +02:00
Frank
0804a3567a Merge branch 'develop' into FF/Ops 2024-03-30 22:34:13 +01:00
Frank
ef8c71d27c RAT
- FLIGHTCONTROL
- RAT ATC
2024-03-30 22:22:00 +01:00
Frank
879ea847e9 RAT v3
- improved stuff for helos
2024-03-29 21:54:13 +01:00
Frank
be3c418919 Update RAT.lua
- Improved keeping parking spot after respawn
- Improved ratcraft object
2024-03-28 23:15:50 +01:00
Applevangelist
be3db86470 Merge remote-tracking branch 'origin/master' into develop 2024-03-28 11:12:57 +01:00
Applevangelist
67b43e2c68 #CTLD - Extract troops makes troops run towards the helo 2024-03-28 11:12:23 +01:00
Applevangelist
577fefab3a Merge remote-tracking branch 'origin/master' into develop 2024-03-28 08:45:18 +01:00
Applevangelist
2ad111dd50 #CTLD - allow availability of crates restriction to one zone 2024-03-28 08:44:54 +01:00
Frank
2c749bf5c9 Merge branch 'develop' into FF/Ops 2024-03-27 22:25:54 +01:00
Frank
24eaa7441c Update RAT.lua 2024-03-27 22:15:17 +01:00
Applevangelist
523375c765 Merge remote-tracking branch 'origin/master' into develop 2024-03-27 14:41:11 +01:00
Applevangelist
ac42b56b8e nil check 2024-03-27 14:40:34 +01:00
Frank
82f4c9d526 Update RAT.lua 2024-03-26 22:26:58 +01:00
Applevangelist
5b8416d5fd Merge remote-tracking branch 'origin/master' into develop 2024-03-25 18:26:17 +01:00
Niels Vaes
874fa7ad69 Fixing a bug where on a rare condition, an A10CII could be spawned and the SpawnInitSADL of the Spawn object wouldn't be set correctly (#2108) 2024-03-25 17:26:44 +01:00
Frank
2205100942 RAT 2024-03-24 22:51:11 +01:00
Frank
801475e146 Merge branch 'FF/Ops' into FF/OpsRat 2024-03-24 17:59:27 +01:00
Frank
d7ee243a00 Merge branch 'develop' into FF/Ops 2024-03-24 17:59:06 +01:00
Frank
a105ddba3d Merge branch 'master' into develop 2024-03-24 17:58:13 +01:00
Frank
70c29de695 Update Airbase.lua
- Fixed docs of airbase enumerators for SouthAtlantic (was Falklands) and Sinai (was SinaiMap)
2024-03-24 17:58:02 +01:00
Frank
d5ceabadb0 Merge branch 'develop' into FF/Ops 2024-03-24 17:23:02 +01:00
Applevangelist
8bd39b41f4 Merge remote-tracking branch 'origin/master' into develop 2024-03-24 13:25:00 +01:00
Applevangelist
b263cddc07 #MSRS - Fix for explicit Voice setting actually overwriting overall settings of a provider. 2024-03-24 13:24:38 +01:00
Applevangelist
a712d74e2e Merge remote-tracking branch 'origin/master' into develop 2024-03-23 14:59:20 +01:00
Applevangelist
613d33d731 #SCORING - added option to give a file path for saving and an option to switch autosave off 2024-03-23 14:58:54 +01:00
Applevangelist
c7e694dfb8 #AWACS - fix for too many TAC/MELD/THREAT calls 2024-03-22 09:27:40 +01:00
Applevangelist
d6c9195555 Merge remote-tracking branch 'origin/master' into develop 2024-03-22 08:56:28 +01:00
Applevangelist
50298e4109 Fix for unknown Threat Type 2024-03-22 08:56:00 +01:00
Frank
1253e241ff Merge branch 'develop' into FF/Ops 2024-03-19 18:04:03 +01:00
Applevangelist
3389d3284a Fix self.speedmax for immobile groups 2024-03-16 12:37:11 +01:00
Applevangelist
b10819220c Merge remote-tracking branch 'origin/master' into develop 2024-03-15 10:26:18 +01:00
Applevangelist
244abe2bbb #Minor Fixes 2024-03-15 10:25:40 +01:00
Applevangelist
4b1a1cbcff Merge remote-tracking branch 'origin/master' into develop 2024-03-13 09:09:02 +01:00
Applevangelist
378e76e45b Added UTILS.ClockHeadingString(refHdg,tgtHdg) thanks to @statua 2024-03-13 09:08:39 +01:00
Applevangelist
f7f28877da Fix for speed nil in ops groups 2024-03-13 07:39:56 +01:00
Applevangelist
e3d2dec91f Merge remote-tracking branch 'origin/master' into develop
# Conflicts:
#	Moose Development/Moose/Wrapper/Controllable.lua
2024-03-12 15:34:53 +01:00
Thomas
470c4ef13c Update Controllable.lua 2024-03-12 11:54:44 +01:00
Thomas
241b31fcec Update Controllable.lua 2024-03-12 11:26:59 +01:00
Thomas
3dd069d7d6 Update Controllable.lua
Docu adjustments
2024-03-12 11:25:33 +01:00
Thomas
77c4fd7696 Update Controllable.lua (#2105) (#2106)
Added setting of AI radio options
2024-03-12 11:20:57 +01:00
Thomas
aca4e4d7ca Update Controllable.lua (#2105)
Added setting of AI radio options
2024-03-12 10:49:06 +01:00
Applevangelist
dcd278e2a1 Merge remote-tracking branch 'origin/master' into develop 2024-03-11 18:19:44 +01:00
Applevangelist
2f81fcb0c0 #STATIC
* Add :FindByMatching() and :FindAllByMatching()
2024-03-11 18:19:19 +01:00
Applevangelist
8cf11de774 #SPAWN
* Small change to keep unitnames when using Razbam's setting IFF via unit names
2024-03-11 18:18:50 +01:00
Applevangelist
b62f2afd8d Merge remote-tracking branch 'origin/master' into develop 2024-03-11 08:30:22 +01:00
Applevangelist
176bd0eb8b xx 2024-03-11 08:29:56 +01:00
Applevangelist
70ee6a1121 Merge remote-tracking branch 'origin/master' into develop 2024-03-10 18:00:02 +01:00
Applevangelist
10edd2f9d0 xxx 2024-03-10 17:59:26 +01:00
Applevangelist
408321decf Merge remote-tracking branch 'origin/master' into develop 2024-03-10 16:53:05 +01:00
Applevangelist
11acb578f6 #SPAWN
* Fix an issue for SPAWN:NewFromTemplate when re-using same template over and again
2024-03-10 16:52:46 +01:00
Applevangelist
383eff4cd6 Merge remote-tracking branch 'origin/develop' into develop 2024-03-10 16:20:32 +01:00
Applevangelist
6cda61c9dd Merge remote-tracking branch 'origin/master' into develop 2024-03-10 16:20:29 +01:00
Applevangelist
4d8abe7f57 #MARKEROPS_BASE
* Fix event coalition
2024-03-10 16:20:06 +01:00
Applevangelist
c6bb7c8bbd Merge remote-tracking branch 'origin/develop' into develop-2 2024-03-09 17:24:47 +01:00
Applevangelist
bd3042410b ccc 2024-03-09 17:24:32 +01:00
Applevangelist
7c9cf96d2e OPSGROUP extra check 2024-03-09 17:24:15 +01:00
Applevangelist
ef30bd36a5 Merge remote-tracking branch 'origin/master' into develop 2024-03-08 10:06:51 +01:00
Applevangelist
5286926609 xx 2024-03-08 10:06:31 +01:00
Applevangelist
ab14fbd11c #MARKEROPS - Added Coalition on FSM events 2024-03-08 10:06:16 +01:00
Applevangelist
5bde0c7605 Merge remote-tracking branch 'origin/develop' into develop 2024-03-07 10:20:56 +01:00
Applevangelist
4f2d8144e9 Merge remote-tracking branch 'origin/master' into develop 2024-03-07 10:20:53 +01:00
Applevangelist
cb61177252 CSAR/CTLD basic support for MH-60R 2024-03-07 10:20:31 +01:00
kaltokri
736204d163 Merge branch 'master' into develop 2024-03-05 22:29:36 +01:00
kaltokri
1e15509001 Fixed broken link to demo mission 2024-03-05 22:29:28 +01:00
kaltokri
cca6b0cf55 Merge branch 'master' into develop 2024-03-05 22:11:34 +01:00
kaltokri
bfa8719ec3 Updated versions of all GitHub actions 2024-03-05 22:11:20 +01:00
Applevangelist
fd0e6053ee #COMMANDER - remove dual AltToKIAS calc for TankerZone etc 2024-03-05 16:38:45 +01:00
Applevangelist
f99eac0de4 Merge remote-tracking branch 'origin/develop' into develop 2024-03-05 10:35:23 +01:00
Applevangelist
89b06fb7a6 Merge remote-tracking branch 'origin/master' into develop 2024-03-05 10:35:18 +01:00
Applevangelist
3652376d42 #CTLD - Slight position spawn variation in case you drop > 1 troop groups 2024-03-05 10:34:15 +01:00
kaltokri
3d1207a079 Merge branch 'master' into develop 2024-03-02 15:07:53 +01:00
kaltokri
3953f0e7fc Moved demo missions of Wrapper.Weapon to new repo 2024-03-02 15:07:45 +01:00
Applevangelist
3e727f7777 Merge remote-tracking branch 'origin/develop' into develop 2024-03-02 14:25:42 +01:00
Applevangelist
5621579b5e fix 2024-03-02 14:24:55 +01:00
Applevangelist
091083b5aa #AWACS
* Fix tac radios when using an AWACS plane
* AWACS info shows STN set
2024-03-02 14:24:39 +01:00
kaltokri
b0d0fb9ae1 Merge branch 'master' into develop 2024-03-01 17:22:33 +01:00
kaltokri
57ce6bcec2 Switched demo mission link in Core/SpawnStatic and Wrapper/Storage 2024-03-01 17:22:22 +01:00
Applevangelist
7a1cfa9fe3 Merge remote-tracking branch 'origin/master' into develop 2024-03-01 08:35:13 +01:00
Applevangelist
71b5492903 Scoring 2024-03-01 08:34:52 +01:00
Applevangelist
5ff4d84a9a Merge remote-tracking branch 'origin/develop' into develop 2024-03-01 08:23:53 +01:00
Applevangelist
c71d0ed7cf Merge remote-tracking branch 'origin/master' into develop 2024-03-01 08:23:50 +01:00
Applevangelist
d64dadd9a9 docu 2024-03-01 08:23:32 +01:00
kaltokri
370bfc893d Merge branch 'master' into develop 2024-02-29 19:52:36 +01:00
kaltokri
0f30f3b1a0 Added link to Wrapper/Group demo missions 2024-02-29 19:52:23 +01:00
kaltokri
50e55e1df2 Merge branch 'master' into develop 2024-02-29 19:00:55 +01:00
kaltokri
51911d3292 Enhanced documentation of InitRandomizePositionZone
InitRandomizePositionZone will not ensure, that every unit is placed within the zone!
2024-02-29 19:00:33 +01:00
kaltokri
bff60bdb69 Update of all Airbases (uptodate and sorted) 2024-02-29 10:33:29 +01:00
kaltokri
219353faad Update of all Airbases (uptodate and sorted) 2024-02-29 10:33:21 +01:00
Applevangelist
4c4ecccb01 Merge remote-tracking branch 'origin/develop' into develop 2024-02-29 09:55:12 +01:00
Applevangelist
0e1cbe45b9 Merge remote-tracking branch 'origin/master' into develop 2024-02-29 09:54:38 +01:00
Applevangelist
aac3f64638 #SCORING Additions for SETs 2024-02-29 09:54:16 +01:00
kaltokri
34937c2cf6 Merge branch 'master' into develop 2024-02-28 19:43:26 +01:00
kaltokri
74c19f1058 Added new airfields in Normandy 2024-02-28 19:43:08 +01:00
kaltokri
42ca05af57 Merge branch 'master' into develop 2024-02-28 17:39:25 +01:00
kaltokri
1cbdafda65 Added link to demo missions for Functional.Fox 2024-02-28 17:39:06 +01:00
kaltokri
960746245f Merge branch 'master' into develop 2024-02-28 17:34:51 +01:00
kaltokri
595b9132e8 Added additional information to FOX:AddProtectedGroup method 2024-02-28 17:34:40 +01:00
Applevangelist
4b50d8f16f Merge remote-tracking branch 'origin/develop' into develop 2024-02-27 18:14:40 +01:00
Applevangelist
c320f1a0a7 Merge remote-tracking branch 'origin/master' into develop 2024-02-27 18:14:34 +01:00
Applevangelist
82b5269040 #BRIGADE Fixes to save/loadback assets for persistence 2024-02-27 18:14:11 +01:00
Applevangelist
45aebff48e #BRIGADE Fixes to save/loadback assets for persistence 2024-02-27 18:13:59 +01:00
kaltokri
80bf992806 Merge branch 'master' into develop 2024-02-27 16:38:42 +01:00
kaltokri
f2e22579ed Added workaround for PatrolRoute problem
Units may stay on initial point and cycle endless if Delay is smaller then 2.
2024-02-27 16:38:20 +01:00
Applevangelist
2dc908d926 Merge remote-tracking branch 'origin/master' into develop 2024-02-27 10:28:30 +01:00
Applevangelist
1f9725530f #CTLD - Added option to inject cargo objects which will not show up in the menu - for inject and move around purposes. 2024-02-27 10:28:00 +01:00
Applevangelist
d3e6b0366b Merge remote-tracking branch 'origin/master' into develop 2024-02-25 11:58:12 +01:00
kaltokri
1545add510 Enhancement of troubleshooting tips in the docs 2024-02-24 22:25:26 +01:00
kaltokri
c85f575888 Enhancement of troubleshooting tips in the docs 2024-02-24 22:24:20 +01:00
kaltokri
9f8428c7ba Merge branch 'master' into develop 2024-02-24 22:04:42 +01:00
kaltokri
5eef138507 Enhancement of the docs 2024-02-24 22:04:10 +01:00
kaltokri
8c6c1e481b Merge branch 'master' into develop 2024-02-24 14:26:45 +01:00
kaltokri
14d6085b69 Added error message, that AATACAN is depricated 2024-02-24 14:26:30 +01:00
Rolf Geuenich
d13173e336 Added Links to new demo mission repository 2024-02-23 11:33:50 +01:00
Rolf Geuenich
ced01a993d Added Links to new demo mission repository 2024-02-23 11:33:02 +01:00
Applevangelist
fa80f0a162 Merge remote-tracking branch 'origin/master' into develop 2024-02-23 11:16:36 +01:00
Applevangelist
02e59b23c5 #AIRBASE - New Syria airbases added 2024-02-23 11:15:46 +01:00
Frank
80b2b26018 Merge branch 'FF/OpsRat' of https://github.com/FlightControl-Master/MOOSE into FF/OpsRat 2024-02-23 00:31:19 +01:00
Frank
e3f523d648 Update RAT.lua 2024-02-23 00:31:15 +01:00
Applevangelist
5b86bf9605 #AWACS - Added a warning to set up SRS before Tac Radios 2024-02-22 17:28:44 +01:00
Applevangelist
c5ece16753 Merge remote-tracking branch 'origin/master' into develop 2024-02-22 12:14:44 +01:00
Applevangelist
4c2a89ee29 Bugfix 2024-02-22 12:14:15 +01:00
Applevangelist
4505b60859 Merge remote-tracking branch 'origin/master' into develop 2024-02-22 11:53:24 +01:00
Applevangelist
e8c75b8795 SPAWN:InitSpeedMPS() etc 2024-02-22 11:52:43 +01:00
Applevangelist
7e21a1070a Merge remote-tracking branch 'origin/master' into develop 2024-02-22 09:19:43 +01:00
Applevangelist
2ce9f26e26 Docu 2024-02-22 09:19:22 +01:00
Applevangelist
bfaca9dd5f Merge remote-tracking branch 'origin/master' into develop 2024-02-22 09:01:23 +01:00
Applevangelist
30819dad72 Catch for invalid STN/SADL octals 2024-02-22 09:00:54 +01:00
Applevangelist
e946916fc0 Merge remote-tracking branch 'origin/master' into develop 2024-02-20 14:32:17 +01:00
Applevangelist
2eeca4451c SPAWN/DATABASE
* Try to ensure unique Link16 STN/SADL octal IDs
* Added `SPAWN:InitSTN(Octal)` and `SPAWN:InitSADL(Octal)`
2024-02-20 14:31:53 +01:00
Applevangelist
ee17d3e995 Merge remote-tracking branch 'origin/develop' into develop 2024-02-20 12:08:33 +01:00
Applevangelist
a48e09b434 Merge remote-tracking branch 'origin/master' into develop 2024-02-20 12:08:27 +01:00
Applevangelist
27ea85ea57 Minor fixes 2024-02-20 12:07:42 +01:00
Thomas
3baf52d307 Update Airbase.lua (#2104)
One space too many fix gor Deanland
2024-02-18 20:13:52 +01:00
Thomas
0faa0036ee Update Airbase.lua
One space too many fix gor Deanland
2024-02-18 20:13:01 +01:00
kaltokri
79189d4d93 Merge branch 'master' into develop 2024-02-17 18:50:46 +01:00
kaltokri
f859522052 Switched link of MSRS missions to MISSION_Demos 2024-02-17 18:50:30 +01:00
Thomas
8d886a75d6 Update Airboss.lua (#2101)
Groove def
2024-02-17 13:12:25 +01:00
Thomas
5a772ad05e Update Airboss.lua
Groove def
2024-02-17 13:10:07 +01:00
Applevangelist
a16e22818d Merge remote-tracking branch 'origin/develop' into develop 2024-02-16 14:09:18 +01:00
Applevangelist
0cc959bf34 #STRATEGO
* Exclude Ships as they cannot be conquered anyway
* Streamline target finding a bit
2024-02-16 14:09:14 +01:00
Frank
2fcb31f3ac Update RAT.lua 2024-02-16 00:11:43 +01:00
Applevangelist
aa948b57d8 Merge remote-tracking branch 'origin/develop' into develop-2 2024-02-15 18:18:23 +01:00
Applevangelist
6ca459b38c xx 2024-02-15 18:18:19 +01:00
Applevangelist
79da4cbf27 Merge remote-tracking branch 'origin/develop' into develop 2024-02-15 18:17:48 +01:00
Applevangelist
e5a60a2ef1 #AWACS
* Ensure not only one Merged-Call
* Enable Tac, Meld, Threat calls also for non-tasked flights
2024-02-15 18:17:44 +01:00
kaltokri
7e2ae60e43 Merge branch 'master' into develop 2024-02-15 16:48:40 +01:00
kaltokri
51f134538d Fixing typos and added text for Automatic dynamic loading and IDEs 2024-02-15 16:47:43 +01:00
kaltokri
0ee7a38c61 Added content to concepts.md and added an empty debugger.md 2024-02-15 16:47:43 +01:00
kaltokri
15dd2cf735 Renamed basic.md to concepts.md and added more text 2024-02-15 16:47:43 +01:00
kaltokri
e895642157 Small fixes in advanced guide 2024-02-15 16:47:43 +01:00
kaltokri
154026fbf8 New guides added 2024-02-15 16:47:43 +01:00
Applevangelist
d7969e9455 Merge remote-tracking branch 'origin/master' into develop 2024-02-13 16:45:36 +01:00
Applevangelist
7dcff7ec9c CommandSetInvisible/CommandSetImmortal right word order 2024-02-13 16:43:45 +01:00
Applevangelist
0e6bf1f46b Merge remote-tracking branch 'origin/master' into develop 2024-02-12 18:35:51 +01:00
Applevangelist
67e52120d4 Nicer BASE:I() etc output 2024-02-12 18:35:22 +01:00
Applevangelist
4b84d227f0 Spawn - reference original template when using SpawnWithAlias in Group.TemplateDonor 2024-02-12 18:34:12 +01:00
Frank
2fce93d925 RAT 2024-02-12 00:10:36 +01:00
Applevangelist
df0dbc9108 PLAYERTASK - small fix for a possibly missing coordinate 2024-02-08 11:59:23 +01:00
Frank
db6354b60d Merge branch 'develop' into FF/Ops 2024-02-06 11:09:35 +01:00
Applevangelist
4307ddcad3 CLIENTMENUMANAGER - dicu 2024-02-04 13:13:06 +01:00
Applevangelist
daa734009e Merge remote-tracking branch 'origin/master' into develop 2024-02-03 12:49:33 +01:00
Applevangelist
86e13df303 MANTIS 2024-02-03 12:48:41 +01:00
Applevangelist
65cf53ce28 Merge remote-tracking branch 'origin/master' into develop 2024-02-03 12:22:59 +01:00
Applevangelist
2e167358bb MANTIS - corrected blue SAM data 2024-02-03 12:22:33 +01:00
Applevangelist
78d1a215e4 Merge remote-tracking branch 'origin/develop' into develop 2024-02-03 09:11:17 +01:00
Applevangelist
14daca9a72 Merge remote-tracking branch 'origin/master' into develop 2024-02-03 09:11:12 +01:00
Applevangelist
48dba742ad MANTIS SAM Data adjustments 2024-02-03 09:10:41 +01:00
kaltokri
2ca847e845 Fixed dead links for Ops.Intel and Ops.Airwing 2024-02-02 13:30:22 +01:00
kaltokri
11c74ddc17 Another fix for dead links (case sensitivity)
linkinator hides multiple problems sometimes
2024-02-02 12:24:31 +01:00
kaltokri
c38917fa2f Fix for dead links (case sensitivity) 2024-02-02 12:15:40 +01:00
Applevangelist
1847a2372c Docu 2024-02-01 09:03:39 +01:00
Applevangelist
fd155f8277 Merge remote-tracking branch 'origin/master' into develop 2024-01-31 17:54:09 +01:00
Applevangelist
531132e8a7 #GROUP small fix for GetAverageCoordinate() 2024-01-31 17:49:59 +01:00
Applevangelist
7464406a17 #SPAWN - Small fix for OnSpawnGroup() timing issues 2024-01-31 17:49:37 +01:00
Applevangelist
bd5c1af335 Merge remote-tracking branch 'origin/develop' into develop 2024-01-27 15:28:46 +01:00
Applevangelist
53f556a4e6 Merge remote-tracking branch 'origin/master' into develop 2024-01-27 15:28:42 +01:00
Applevangelist
0ddf8762c2 UTILS - small helper for M2K Data Cartridges 2024-01-27 15:28:12 +01:00
Frank
2893bfb290 Merge branch 'master' into develop 2024-01-24 14:47:13 +01:00
Frank
d984a1b142 Update Airboss.lua
- VTOL grading #2099
2024-01-24 14:47:00 +01:00
Frank
f10d676921 Merge branch 'develop' into FF/Ops 2024-01-23 10:59:13 +01:00
Applevangelist
f02b774242 Merge remote-tracking branch 'origin/develop' into develop 2024-01-23 10:05:13 +01:00
Applevangelist
5ede860361 Merge remote-tracking branch 'origin/master' into develop 2024-01-23 10:05:09 +01:00
Applevangelist
d0d52246f4 #STRATEGO
* Change strategy for finding strategic targets from base to consolidated weight
2024-01-23 10:04:50 +01:00
Applevangelist
748aa131e4 WAREHOUSE - trying to ensure WH for AirWing starts again when runway is repaired 2024-01-23 10:03:56 +01:00
Frank
1b4e170271 Update FlightGroup.lua
- Added menu update after cruise. (Fixes launches from aircraft carriers.)
2024-01-22 21:49:31 +01:00
Thomas
a3d56b6d1b Update Pathline.lua (#2097) (#2098)
Small fixes
2024-01-22 06:32:42 +01:00
Thomas
33bd928076 Update Pathline.lua (#2097)
Small fixes
2024-01-22 06:30:53 +01:00
Applevangelist
23df6bbc2a Merge remote-tracking branch 'origin/master' into develop 2024-01-21 16:46:40 +01:00
Applevangelist
f2fc321ded TARGET - declare Scenery target dead if <= 25% of life0 2024-01-21 16:46:24 +01:00
Applevangelist
0b3fc515e0 SCENERY - small addons 2024-01-21 16:44:14 +01:00
Applevangelist
e50d54f6bc Spawned FARP issue 2024-01-19 19:31:49 +01:00
Applevangelist
6e60a66d0c Merge remote-tracking branch 'origin/master' into develop 2024-01-19 19:09:28 +01:00
Applevangelist
11f0b2899d Minor fixes 2024-01-19 19:09:08 +01:00
Applevangelist
581138b5bc Avoid for pairs error 2024-01-19 19:06:52 +01:00
Applevangelist
0ce3a189c3 Merge remote-tracking branch 'origin/master' into develop 2024-01-18 14:35:54 +01:00
Applevangelist
08f2c29014 #AIRBASE
* Small workaround for Beirut runways
* ATIS minor fix
2024-01-18 14:32:17 +01:00
Applevangelist
9208d7a70d Merge remote-tracking branch 'origin/master' into develop 2024-01-17 12:17:34 +01:00
Applevangelist
4076ff5bb5 #AIRWING, #EASYGCICAP
* Added SetCapStartTimeVariation()
2024-01-17 12:17:14 +01:00
Applevangelist
dcd4d0ab62 CONTROLLABLE
* Added CommandSetFrequencyForUnit
2024-01-17 12:15:46 +01:00
Applevangelist
056b761ebc #PLAYERTASKCONTROLLER
* Additions for lasing unit being an ARMYGROUP
2024-01-17 08:10:01 +01:00
Frank
0532c54cd5 Merge branch 'develop' into FF/Ops 2024-01-16 17:11:16 +01:00
Applevangelist
298c569f93 #PLAYERTASK
* Add a height of 2m on laser coordinates to ensure LOS test works
2024-01-16 15:09:51 +01:00
Applevangelist
32dbb520d6 #AUTOLASE
* Allow switching Smoke targets menu to be switched off and on
2024-01-16 15:09:12 +01:00
Applevangelist
6af66db4c3 Minor changes 2024-01-14 14:57:21 +01:00
Applevangelist
ff84d682bd Merge remote-tracking branch 'origin/develop' into develop 2024-01-12 18:44:38 +01:00
Applevangelist
d2b7d46227 STRATEGO
* functional additions
2024-01-12 18:44:34 +01:00
Applevangelist
58f4eead1c #AUFTRAG
* Helos: Added AUFTRAG:NewLANDATCOORDINATE
2024-01-12 18:43:48 +01:00
Rolf Geuenich
f3bafd5803 Merge branch 'master' into develop 2024-01-12 16:05:46 +01:00
Rolf Geuenich
bb07e1935e Downpatching changes from development to master 2024-01-12 16:05:14 +01:00
Rolf Geuenich
2946c2e225 Merge branch 'master' into develop
# Conflicts:
#	Moose Development/Moose/Functional/Artillery.lua
2024-01-12 15:45:50 +01:00
Rolf Geuenich
088436c5ce Downpatching changes from development to master in Arty.lua 2024-01-12 15:44:28 +01:00
Rolf Geuenich
2e386be2f6 Merge branch 'master' into develop
# Conflicts:
#	Moose Development/Moose/Core/Set.lua
2024-01-12 15:35:17 +01:00
Rolf Geuenich
797bf0047b Down patching of code enhancements from develop to master in Set.lua 2024-01-12 15:33:27 +01:00
Applevangelist
9c0c93507a Merge remote-tracking branch 'origin/master' into develop 2024-01-11 17:32:04 +01:00
Applevangelist
f29d055ca3 Correction 2024-01-11 17:31:40 +01:00
Applevangelist
baf7123364 Merge remote-tracking branch 'origin/master' into develop 2024-01-11 17:14:43 +01:00
Applevangelist
1468641563 CTLD - avoid UHT beacons between 243 and 320 mHz 2024-01-11 17:14:07 +01:00
Applevangelist
f6b6a6a577 #EASYGCICAP
* Added assignment of in-flight groups to intercepts
2024-01-11 16:11:51 +01:00
Applevangelist
4d7d34b71f Merge remote-tracking branch 'origin/master' into develop 2024-01-11 12:52:42 +01:00
Applevangelist
82bea9d5ff Merge remote-tracking branch 'origin/develop' into develop 2024-01-11 12:52:19 +01:00
Applevangelist
35d91c9c94 EASYGCICAP Additions 2024-01-11 12:52:15 +01:00
Applevangelist
8b08942c4d CONTROLLABLE - Added options for Radar Using 2024-01-11 12:52:02 +01:00
kaltokri
a44ad5c755 Changed order to match master branch for better auto-merge 2024-01-11 10:05:22 +01:00
kaltokri
b7236eeb58 Merge branch 'master' into develop 2024-01-10 15:43:38 +01:00
kaltokri
eb84ad3cee Fix for Moose_Create.lua and dynamic path 2024-01-10 15:43:24 +01:00
kaltokri
09933b307b Merge branch 'master' into develop 2024-01-10 15:41:02 +01:00
kaltokri
91a34ac4d8 Added PyCharm to gitignore 2024-01-10 15:40:46 +01:00
kaltokri
21babb548c Fixed typo off manual merge and added PyCharm to gitignore 2024-01-10 15:39:23 +01:00
Applevangelist
11967bd608 Merge remote-tracking branch 'origin/develop' into develop
# Conflicts:
#	Moose Development/Moose/Modules.lua
2024-01-10 15:21:16 +01:00
Applevangelist
ea6e63dc9b Merge remote-tracking branch 'origin/master' into develop
# Conflicts:
#	Moose Development/Moose/Modules.lua
#	Moose Development/Moose/Ops/Airboss.lua
2024-01-10 15:20:29 +01:00
Applevangelist
28c8d99878 Added player name to ...PilotDown() event 2024-01-10 15:18:38 +01:00
kaltokri
547579ffb0 Merge branch 'master' into develop
# Conflicts:
#	Moose Development/Moose/Modules.lua
#	Moose Development/Moose/Ops/Airboss.lua
2024-01-10 14:26:55 +01:00
kaltokri
4fda8cc5fb Easy debugging for all Moosers #2093
Enables everybody to use load Moose from an external full path.
This is needed to use PyCharm with EmmyLua Debugger.
Needs also De-Sanitize to load mission script with full path.
2024-01-10 14:12:17 +01:00
Applevangelist
697042eac6 EASYGCICAP - less noise 2024-01-10 13:38:48 +01:00
Applevangelist
30d6936f1d MSRS changes 2024-01-09 17:47:14 +01:00
Applevangelist
4ac583e434 SRS changes 2024-01-09 17:28:58 +01:00
Applevangelist
b315375ade xxx 2024-01-09 08:58:07 +01:00
Frank
becaf47a66 Merge branch 'develop' into FF/Ops 2024-01-07 21:16:15 +01:00
Frank
e26647c2ca OPSTRANSPORT
- Fixed SET not working with FilterActive
2024-01-07 17:24:51 +01:00
Applevangelist
4ddd278471 #AWACS
* Picture clean, correct order of callsigns
2024-01-07 15:40:17 +01:00
Applevangelist
72e31b90a9 Merge remote-tracking branch 'origin/master' into develop 2024-01-07 14:44:45 +01:00
Applevangelist
fa762fe0fc #MSRS
* Added voice enumerator ofr gRPC using MS as provider MSRS.Voices.MicrosoftGRPC
2024-01-07 14:44:07 +01:00
Mr.Alien
aca5846209 Fix scoring to not het more points when not killed at once. + overridable method call on kill (#2079) 2024-01-07 13:28:12 +01:00
Mr.Alien
4fd7d7cba9 Spawn all unit randomly inside a zone, instead of only the first unit in zone and the other within a radius (potentially outside the zone, and in some cases in the middle of a runway) (#2069) 2024-01-07 13:27:23 +01:00
ttrebuchon
677d888d96 Use total cargo weight when computing asset score for transport missions (#2065)
* Optimize carrier assets for OPSTRANSPORT based on total cargo weight

* Clean up code/comments for TotalWeight scoring

* Add missing parameter documentation
2024-01-07 13:26:58 +01:00
Applevangelist
06c3ca0079 MSRS additions 2024-01-07 13:25:32 +01:00
Applevangelist
9280a1224d MSRS additions 2024-01-07 13:23:50 +01:00
Applevangelist
406dbb707a Merge remote-tracking branch 'origin/develop' into develop 2024-01-06 18:22:41 +01:00
Applevangelist
4758af61c2 Merge remote-tracking branch 'origin/master' into develop 2024-01-06 18:22:36 +01:00
Applevangelist
729c1f5e33 Fixes for MSRS changes
#STRATEGO
* fix for an AB not having a zone
2024-01-06 18:22:18 +01:00
Applevangelist
fce7b07014 Fixes for MSRS changes 2024-01-06 18:21:39 +01:00
kaltokri
8386fe5f67 Merge branch 'master' into develop 2024-01-06 12:22:25 +01:00
kaltokri
4696569f83 Added mission check for desanitized io 2024-01-06 12:22:02 +01:00
Applevangelist
2c695e187f Merge remote-tracking branch 'origin/master' into develop 2024-01-05 16:09:22 +01:00
Applevangelist
048ab6acfe Fixes for 4th SRS Parameter 2024-01-05 16:09:05 +01:00
Applevangelist
84230e2360 Fixes for 4th SRS Parameter 2024-01-05 16:08:46 +01:00
Applevangelist
f2783c46c2 Merge remote-tracking branch 'origin/master' into develop 2024-01-05 15:51:35 +01:00
Applevangelist
ca9913e38b nu aber 2024-01-05 15:51:09 +01:00
Applevangelist
df1bc5c55d Merge remote-tracking branch 'origin/master' into develop 2024-01-05 15:46:45 +01:00
Applevangelist
ff951c69d9 Error dfix 2024-01-05 15:45:40 +01:00
Applevangelist
e53a80783e Merge remote-tracking branch 'origin/master' into develop
# Conflicts:
#	Moose Development/Moose/Sound/SRS.lua
2024-01-05 15:43:33 +01:00
Applevangelist
a1fb09285b STRATEGO - Improvements 2024-01-05 15:42:33 +01:00
Applevangelist
f2f7c88299 SRS changes 2024-01-05 15:42:11 +01:00
Applevangelist
e2bf1f727d FLIGHTGROUP - Amending landing on an AFB w/o runways
SRS - some improvements
2024-01-05 15:37:52 +01:00
Applevangelist
65315251b5 PLAYERTASK, AWACS - small fix for the revamped SRS 2024-01-05 12:13:04 +01:00
Applevangelist
2a9e98c21e Merge remote-tracking branch 'origin/develop' into develop 2024-01-04 18:49:50 +01:00
Applevangelist
b40c1e4575 Fixes 2024-01-04 18:49:47 +01:00
Frank
9ea8443286 Merge branch 'develop' into FF/Ops 2024-01-04 15:13:46 +01:00
Frank
a9befc4d96 Merge branch 'master' into develop 2024-01-04 15:13:26 +01:00
Applevangelist
f5d6d31b10 xxx 2024-01-04 14:01:12 +01:00
Applevangelist
65fb22b6cc xxx 2024-01-04 14:00:43 +01:00
Applevangelist
d0346c4aa3 MSRS
line 953 has no self
2024-01-04 13:59:41 +01:00
Applevangelist
96da09b9e0 Picture link 2024-01-04 12:44:43 +01:00
Applevangelist
c1d468b35f Merge remote-tracking branch 'origin/develop' into develop 2024-01-04 11:27:54 +01:00
Applevangelist
109270d717 STRATEGO
* Renamed knots to nodes to have the correc lingo
2024-01-04 11:27:48 +01:00
Frank
f80e7a2166 Merge branch 'master' into develop 2024-01-03 22:32:50 +01:00
Frank
9b95e71d75 Update Airboss.lua
- Potential fix for error raised on discord
2024-01-03 22:32:37 +01:00
Applevangelist
de6c7d636b docu 2024-01-03 18:56:43 +01:00
Applevangelist
f57beab6d2 #STRATEGO 2024-01-03 18:14:12 +01:00
Applevangelist
29414bfd21 Merge remote-tracking branch 'origin/develop' into develop 2024-01-03 18:06:21 +01:00
Applevangelist
60b8a5f5af Merge remote-tracking branch 'origin/master' into develop 2024-01-03 18:06:15 +01:00
Applevangelist
db6dc7b77e SET: Added GetRandomSurely() 2024-01-03 18:05:29 +01:00
kaltokri
aaf3553597 Merge branch 'master' into develop 2024-01-03 11:59:27 +01:00
kaltokri
4e50bd213c No fixes for broken links 2024-01-03 09:04:43 +01:00
kaltokri
c813e2dbc4 Fixed broken links 2024-01-03 07:53:41 +01:00
Rolf Geuenich
4c81333a0a Add the dynamic loading of developer files (#2090) 2024-01-03 07:19:18 +01:00
kaltokri
761d83a68f Fix broken link in Awacs.lua 2024-01-02 22:10:08 +01:00
kaltokri
3d93c268b3 Merge branch 'master' into develop 2024-01-02 22:07:29 +01:00
kaltokri
79b1f1615f Fix broken link in AI_Escort_Request.lua 2024-01-02 22:06:59 +01:00
kaltokri
d6a0fff993 Fix for broken links in documentation 2024-01-02 20:03:18 +01:00
kaltokri
8d45ea00e8 Merge branch 'master' into develop 2024-01-02 19:03:47 +01:00
kaltokri
47f010cb28 Fixed broken link in AI_Escort.lua 2024-01-02 19:03:19 +01:00
Applevangelist
2d17c4d21a Merge remote-tracking branch 'origin/master' into develop 2024-01-02 18:13:14 +01:00
Applevangelist
d14b7e8f4c #POINT
* added missing COORDINATE:ToStringLL()
2024-01-02 18:12:42 +01:00
Frank
f76fa58a5f Merge branch 'develop' into FF/Ops 2024-01-02 17:07:03 +01:00
Frank
d8b046491b Merge branch 'master' into develop 2024-01-02 17:06:41 +01:00
Frank
d9748ef147 Update SRS.lua
- Fixed bugs for self
2024-01-02 17:06:32 +01:00
kaltokri
b20eb84d19 Merge branch 'master' into develop 2024-01-02 13:33:40 +01:00
kaltokri
64d7946c06 Fix for broken links in master branch 2024-01-02 13:33:10 +01:00
Frank
c8b36b8c99 Merge branch 'develop' into FF/Ops 2024-01-01 21:54:51 +01:00
kaltokri
c2be4fbcf1 Merge branch 'master' into develop 2024-01-01 19:06:45 +01:00
kaltokri
b052fc6243 Merge branch 'restructuring' 2024-01-01 19:06:34 +01:00
kaltokri
8385b1d21a Fixed broken links in A2A_Dispatcher 2024-01-01 19:06:21 +01:00
kaltokri
58d9637c5d Merge branch 'master' into develop
# Conflicts:
#	Moose Development/Moose/Sound/SRS.lua
2024-01-01 15:54:53 +01:00
kaltokri
d4f4465b0a Merge branch 'restructuring' 2024-01-01 15:53:05 +01:00
kaltokri
5fe77956cb Fixed broken links of restructure 2024-01-01 15:51:02 +01:00
Applevangelist
e0a108e00d #TIRESIAS
* Initial release
2024-01-01 13:11:44 +01:00
Applevangelist
d640acc7cc docu 2024-01-01 13:07:08 +01:00
kaltokri
acf37f6133 Merge branch 'master' into develop 2024-01-01 00:39:11 +01:00
kaltokri
8dcd22f18c Merge branch 'msrs' 2024-01-01 00:38:59 +01:00
kaltokri
2d086a62f0 Added link to example missions to MSRS 2024-01-01 00:38:48 +01:00
Applevangelist
47ad2499d4 Merge remote-tracking branch 'origin/master' 2023-12-31 17:26:01 +01:00
Applevangelist
5d510807c9 xxx 2023-12-31 17:25:56 +01:00
Applevangelist
dd771a089c Merge remote-tracking branch 'origin/develop' into develop
# Conflicts:
#	Moose Development/Moose/Sound/SRS.lua
2023-12-31 17:25:32 +01:00
Applevangelist
3f927b16e5 Merge remote-tracking branch 'origin/master' into develop
# Conflicts:
#	Moose Development/Moose/Sound/SRS.lua
2023-12-31 17:23:20 +01:00
Applevangelist
5ba8f9e0e8 #UTILS
* Added NATO name for KC-135MPRS

#SET
* Made filtering a tad faster
2023-12-31 17:21:02 +01:00
kaltokri
833a0561c3 Merge branch 'master' into develop
# Conflicts:
#	Moose Development/Moose/Sound/SRS.lua
2023-12-31 17:19:51 +01:00
kaltokri
0338fd5d33 Merge branch 'msrs' 2023-12-31 17:15:51 +01:00
kaltokri
ea2175bba8 Added debug output to SRS.lua 2023-12-31 17:14:54 +01:00
Applevangelist
cf48b21073 Merge remote-tracking branch 'origin/master' into develop 2023-12-31 14:58:02 +01:00
Applevangelist
0835022c5c #GROUP
* Corrections for "IsAAA()"
2023-12-31 14:57:13 +01:00
Applevangelist
a70ad71689 Merge remote-tracking branch 'origin/master' into develop 2023-12-30 16:53:22 +01:00
Applevangelist
f306361317 #GROUP
* Added IsSam and IsAAA

#SET
* Corrected EvalFilterFunctions - all must be true
2023-12-30 16:52:24 +01:00
Applevangelist
0347e42fc7 CARGO noise 2023-12-30 16:50:12 +01:00
Applevangelist
7557e79c0c Merge branch 'master' into develop 2023-12-29 15:03:09 +01:00
Applevangelist
9cc32ff8dc AIRBOSS - Superfluous error message removal 2023-12-29 15:02:41 +01:00
Applevangelist
1b7eef5419 Merge remote-tracking branch 'origin/develop' into develop 2023-12-29 14:50:57 +01:00
Applevangelist
029bdc3bd1 Merge branch 'master' into develop 2023-12-29 14:50:53 +01:00
Applevangelist
b052d99349 Fixes 2023-12-29 14:50:01 +01:00
kaltokri
93acd870ea Merge branch 'master' into develop 2023-12-28 16:38:57 +01:00
kaltokri
4fe1318e7c Fixed a logic failure with external sound files in SoundOutput.lua 2023-12-28 16:38:26 +01:00
Applevangelist
93cdb92e76 Merge remote-tracking branch 'origin/master' into develop 2023-12-28 13:33:37 +01:00
Applevangelist
6ffe69484c Reduce noise 2023-12-28 13:32:53 +01:00
Applevangelist
39b89d937e Merge remote-tracking branch 'origin/master' into develop 2023-12-27 19:34:42 +01:00
Applevangelist
501ab70992 xxx 2023-12-27 19:34:20 +01:00
Applevangelist
b488d43d78 Merge remote-tracking branch 'origin/master' into develop 2023-12-27 19:28:49 +01:00
Applevangelist
6ac46addf0 #SET
* Added `FilterFunction()` for these SETs: UNIT, GROUP, CLIENT, STATIC
2023-12-27 19:28:19 +01:00
Applevangelist
33259be4d9 Merge remote-tracking branch 'origin/develop' into develop 2023-12-26 19:18:54 +01:00
Applevangelist
e4cea7b3c4 Merge remote-tracking branch 'origin/master' into develop 2023-12-26 19:18:36 +01:00
Applevangelist
3bdf4b4c76 #CTLD
* Fix multi-crate requests deducting too much Stock
2023-12-26 19:18:13 +01:00
kaltokri
6f5f89a0ee Merge branch 'master' into develop 2023-12-26 14:51:28 +01:00
kaltokri
46f70dd8a6 Fixed logic in SoundOutput.lua to play internal sound files with SRS 2023-12-26 14:50:54 +01:00
Thomas
e2e9bd7de0 Update EasyGCICAP.lua 2023-12-26 08:53:11 +01:00
Frank
1b01b89343 TARGET
- Fixed IsAlive
2023-12-25 23:12:55 +01:00
Applevangelist
4e36ed170b Merge remote-tracking branch 'origin/develop' into develop 2023-12-25 13:59:27 +01:00
Applevangelist
bf0ad93bf7 AICSAR Fix 2023-12-25 13:59:23 +01:00
Thomas
a51afeda14 Update build-includes.yml 2023-12-25 13:31:35 +01:00
Applevangelist
e46b148721 SRS 2023-12-25 13:28:00 +01:00
Applevangelist
8765ebe2c6 Merge remote-tracking branch 'origin/develop' into develop
# Conflicts:
#	.github/workflows/build-includes.yml
2023-12-25 13:22:47 +01:00
Applevangelist
b55b11be09 Merge remote-tracking branch 'origin/master' into develop 2023-12-25 13:22:16 +01:00
Thomas
2a7dbad02a Update build-includes.yml 2023-12-25 13:21:51 +01:00
Thomas
aeac2eb3d7 Update build-includes.yml 2023-12-25 13:20:13 +01:00
Thomas
e83c8c3ee0 Update build-includes.yml (#2078) 2023-12-25 13:14:46 +01:00
Applevangelist
d65042c640 SRS error from luacheck 2023-12-25 13:12:03 +01:00
Thomas
c72cdd8f0b Update build-includes.yml (#2077) 2023-12-25 13:08:21 +01:00
Thomas
7e2f8771b5 Update build-includes.yml (#2076) 2023-12-25 13:01:59 +01:00
Applevangelist
3ccfcdbd0f CSAR 2023-12-25 13:00:36 +01:00
Thomas
44b3f41ae4 Update build-includes.yml (#2075) 2023-12-25 12:49:54 +01:00
Thomas
c5dec374c8 Update build-includes.yml (#2074) 2023-12-25 12:40:33 +01:00
Thomas
3f384d72ab Update build-includes.yml (#2073) 2023-12-25 12:38:18 +01:00
Thomas
1d5952b4a5 Update build-includes.yml (#2072) 2023-12-25 12:34:57 +01:00
Thomas
8eec7fcc9e Update build-includes.yml (#2071) 2023-12-25 12:29:40 +01:00
Applevangelist
db7e94d879 New SRS Fixes 2023-12-25 12:14:57 +01:00
Applevangelist
16f3dcbbb4 New SRS fixes 2023-12-25 12:14:41 +01:00
kaltokri
f482dac491 Merge branch 'master' into develop 2023-12-25 11:28:19 +01:00
kaltokri
f6f3189504 MSRS enhancements
- Added more tracing
- A check if executable exists
- Removed STTS references
2023-12-25 11:27:48 +01:00
kaltokri
73fa021476 Merge branch 'master' into develop
# Conflicts:
#	Moose Development/Moose/Sound/SRS.lua
2023-12-25 09:41:57 +01:00
kaltokri
071554bfc5 Fixed some small typos and removed STTS in comments 2023-12-25 09:39:21 +01:00
kaltokri
cd8abd97c5 Merge branch 'master' into develop
# Conflicts:
#	Moose Development/Moose/Sound/SRS.lua
2023-12-25 06:13:40 +01:00
kaltokri
1527b53c76 Fixed ASW typo in SRS.lua 2023-12-25 06:09:31 +01:00
kaltokri
e25eeee0cc Merge branch 'master' into develop 2023-12-25 06:00:55 +01:00
kaltokri
bbc7f7e14c Added mission repositries to repositories.md 2023-12-25 05:58:58 +01:00
kaltokri
0261020796 Merge branch 'master' into develop 2023-12-25 05:35:55 +01:00
kaltokri
b9830a8437 Fixed some typos in demo-missions.md 2023-12-25 05:35:41 +01:00
Frank
257530d421 Merge branch 'master' into develop 2023-12-24 03:26:53 +01:00
Frank
caaee4f551 Merge pull request #2068 from FlightControl-Master/FF/MasterDevel
MSRS
2023-12-24 03:21:50 +01:00
Frank
5f7115f4fe Update SRS.lua 2023-12-23 16:53:42 +01:00
Frank
9ec92a8fca SRS
- Refactoring
2023-12-23 15:57:27 +01:00
Applevangelist
a14435ce54 Merge remote-tracking branch 'origin/develop' into develop 2023-12-23 14:53:42 +01:00
Applevangelist
e82e4f7dd7 Merge remote-tracking branch 'origin/master' into develop 2023-12-23 14:53:36 +01:00
Applevangelist
c7ef270d4d #FLIGHTCONTROL
* Added a delay in spawning the parking guard so in MP we have time to get the heading of the Player's plane
2023-12-23 14:53:11 +01:00
Applevangelist
7cc040c234 #RANGE
* Fixed Range trying to find a pilot on each and every birth event...
2023-12-23 14:51:59 +01:00
Frank
9227ba9ecd Merge branch 'master' into FF/MasterDevel 2023-12-22 22:01:59 +01:00
Frank
a9a56b3738 Merge branch 'master' into develop 2023-12-22 21:11:41 +01:00
Frank
e7fb073bab Update RAT.lua
- Removed restriction that zones need to be defined in the ME
2023-12-22 21:11:30 +01:00
Frank
0d1fc2fbf2 Merge branch 'master' into develop 2023-12-22 10:36:34 +01:00
Frank
f86b3505b2 Update Airboss.lua
- Fixed Attitude Monitor
2023-12-22 10:36:25 +01:00
Frank
e89b921f3e Update Zone.lua 2023-12-22 10:27:00 +01:00
Frank
0d18ce086c Update Zone.lua 2023-12-21 22:33:08 +01:00
Frank
8fb126682f Merge branch 'master' into FF/MasterDevel 2023-12-21 22:22:10 +01:00
Applevangelist
63a0224ea4 Merge remote-tracking branch 'origin/master' into develop 2023-12-20 10:08:14 +01:00
Applevangelist
ebe486c69a UTILS
* Small fix for UH60L door checker
2023-12-20 10:07:42 +01:00
Applevangelist
69fa6f4ee6 Merge remote-tracking branch 'origin/master' into develop 2023-12-19 17:38:51 +01:00
Applevangelist
702ec75935 Small fix 2023-12-19 17:38:31 +01:00
Applevangelist
1c4e3cb801 Merge remote-tracking branch 'origin/master' into develop 2023-12-19 12:11:37 +01:00
Applevangelist
465ec216ea #CONTROLLABLE - Option ECM 2023-12-19 12:11:09 +01:00
Applevangelist
ab516e0cd8 Merge remote-tracking branch 'origin/master' into develop 2023-12-19 10:20:12 +01:00
Applevangelist
d803b51e84 #ZONE
* Fixed filling/drawing of more complex polygon zones
* Added function to (re-)fill polygon
* Added function to (re-)draw polygon outline
2023-12-19 10:19:44 +01:00
Applevangelist
53f89fd42c #DATABASE
* Read color, fill color from drawing data
2023-12-19 10:18:20 +01:00
Frank
c72f109553 SRS 2023-12-19 00:02:17 +01:00
kaltokri
f2ba2022c2 Merge branch 'master' into develop 2023-12-18 16:22:38 +01:00
kaltokri
92e03522db Finished beginner section 2023-12-18 16:21:32 +01:00
Frank
9716162739 Update SRS.lua 2023-12-17 22:55:31 +01:00
Frank
4eea8fcadd Merge branch 'master' into FF/MasterDevel 2023-12-17 20:37:30 +01:00
Frank
5b37e7b249 Merge branch 'develop' into FF/Ops 2023-12-16 09:32:14 +01:00
Frank
5b7e0ce375 Merge branch 'master' into develop 2023-12-16 09:31:56 +01:00
Frank
0ae9be49da Update Range.lua
- Fixed random good by phrase
2023-12-16 09:31:44 +01:00
kaltokri
c250712e53 Merge branch 'master' into develop 2023-12-15 14:13:03 +01:00
kaltokri
bda4efc634 Added page "Create your own Hello world" 2023-12-15 14:11:58 +01:00
Applevangelist
566ebb67e3 Merge remote-tracking branch 'origin/master' into develop 2023-12-14 12:44:00 +01:00
Applevangelist
e84e16f58b xx 2023-12-14 12:43:36 +01:00
Applevangelist
55ffe37a79 #USERSOUND
* Added USERSOUND:ToClient( Client, Delay )
2023-12-14 12:42:13 +01:00
Applevangelist
6c21dfa48c Merge branch 'master' into develop 2023-12-14 11:13:06 +01:00
Applevangelist
b31fc3ed44 Limit Attacked() to have at least the capture threatlevel 2023-12-14 11:12:50 +01:00
Applevangelist
68548f4581 #COORDINATE
* Fix for NewFromMGRS for less precise coordinates (below level 5)
2023-12-14 11:12:14 +01:00
Thomas
42fd2322d2 Update Range.lua (#2066) (#2067)
MSRS config compatibility
2023-12-13 19:33:07 +01:00
Thomas
8382eb9cd8 Update Range.lua (#2066)
MSRS config compatibility
2023-12-13 19:21:28 +01:00
Applevangelist
585901dc7d Merge remote-tracking branch 'origin/master' into develop 2023-12-12 10:54:32 +01:00
Applevangelist
2a7213c1b7 xxx 2023-12-12 10:54:16 +01:00
Applevangelist
f837e9dec7 #COORDINATE
* Added functions to create a COORDINATE from MGRS
2023-12-12 10:53:37 +01:00
ttrebuchon
cd4fb0c6c5 Add missing files to Moose.files: (#2062)
Utilities/Socket.lua
Core/Astar.lua
Core/MarkerOps_Base.lua
Functional/ZoneGoalCargo.lua
Ops/OpsZone.lua
Ops/ArmyGroup.lua
Ops/OpsTransport.lua
Ops/Target.lua
2023-12-11 11:50:09 +01:00
Thomas
b8d44643c1 Update Detection.lua (#2063) (#2064)
# RadarBlur - make burn-through limit configureable
2023-12-11 11:49:00 +01:00
Thomas
230d9d82bf Update Detection.lua (#2063)
# RadarBlur - make burn-through limit configureable
2023-12-11 11:04:35 +01:00
Applevangelist
47d01f18c1 Merge remote-tracking branch 'origin/master' into develop 2023-12-10 14:38:06 +01:00
Applevangelist
c089e56060 # DETECTION
* Make the radar blur less effective when under 20km distance
2023-12-10 14:37:41 +01:00
Applevangelist
8a1c9c0e54 Merge remote-tracking branch 'origin/master' into develop 2023-12-10 11:58:55 +01:00
Applevangelist
87f1a5ed0d # DETECTION
* Option to make Radar Blue decision visible in logs (self.debug) and/or screen (self.verbose)
2023-12-10 11:58:19 +01:00
Applevangelist
a4fd55e87d Merge remote-tracking branch 'origin/master' into develop 2023-12-09 18:16:52 +01:00
Applevangelist
d2d6fac7df # DETECTION, logic fix 2023-12-09 18:16:29 +01:00
Applevangelist
5243a408cc Merge remote-tracking branch 'origin/master' into develop 2023-12-09 15:52:16 +01:00
Applevangelist
bc3f9ed7c0 #SPAWN
* Added SPAWN:InitCallSign(ID,Name,Minor,Major)
2023-12-09 15:51:35 +01:00
Applevangelist
b224739df3 Merge remote-tracking branch 'origin/master' into develop 2023-12-09 14:35:02 +01:00
Applevangelist
0f4162a9a9 * fixes 2023-12-09 14:34:41 +01:00
Applevangelist
ff26e4d1dc Merge remote-tracking branch 'origin/master' into develop 2023-12-09 13:54:43 +01:00
Applevangelist
6b270916c4 # DETECTION_BASE
* Added `SetRadarBlur(minheight,thresheight,thresblur)`
2023-12-09 13:53:27 +01:00
Applevangelist
1f17fd89a4 Merge remote-tracking branch 'origin/master' into develop 2023-12-09 13:03:57 +01:00
Applevangelist
b3a006096c fixes 2023-12-09 13:03:34 +01:00
Applevangelist
a8e35a552d Merge remote-tracking branch 'origin/master' into develop 2023-12-07 16:09:13 +01:00
Applevangelist
6903e252d2 #UTILS
* Nicer PrintTableToLog()
2023-12-07 16:08:47 +01:00
Applevangelist
6ee1afc670 Merge remote-tracking branch 'origin/master' into develop 2023-12-07 15:12:18 +01:00
Applevangelist
ff6704f123 #ZONE docu fixes 2023-12-07 15:11:53 +01:00
Applevangelist
3b8bbdd4c1 Merge branch 'master' into develop 2023-12-07 13:46:52 +01:00
Applevangelist
c770f4cb68 #ZONE Docu fixes 2023-12-07 13:46:32 +01:00
Applevangelist
7e5a97e7c7 Merge remote-tracking branch 'origin/master' into develop 2023-12-07 13:32:03 +01:00
Applevangelist
9ce1d360d6 #CTLD
* Spawn dropped troops in a nice circle 5m (hover: 1.5m) left of the he
2023-12-07 13:31:40 +01:00
Applevangelist
f342ba758e Merge remote-tracking branch 'origin/master' into develop 2023-12-07 12:15:56 +01:00
Thomas
6f473faa92 Update Message.lua
#2059 fixed
2023-12-07 12:14:59 +01:00
Thomas
dd37a42470 Update CTLD.lua (#2060)
Changes from @Rey
2023-12-07 12:12:19 +01:00
Applevangelist
018d8eecf6 Merge remote-tracking branch 'origin/master' into develop 2023-12-07 11:22:20 +01:00
Applevangelist
fe9d841af5 #PLAYERRECCE
* Fixed visual targets not being smoked
* Added option to smoke an average coordinate of targets instead of all
* Defaulted self-smoking of player to false
2023-12-07 11:21:52 +01:00
Applevangelist
88e1bbd60d #SET
* Repaired SET_UNIT:GetCoordinate()
2023-12-07 11:20:43 +01:00
Applevangelist
d0491b3b5a Merge remote-tracking branch 'origin/master' into develop 2023-12-06 08:43:09 +01:00
Applevangelist
e078e48853 #SPAWN
* Fix for a Link16 flight having a non-NATO callsign as number
2023-12-06 08:42:07 +01:00
Frank
f789fbac70 Update Zone.lua
- Fixed ZONE_POLYGON:New called without initial points
2023-12-05 17:48:34 +01:00
Frank
bc3a5271dc Update OpsGroup.lua
- Fixed group returning to legion when told not to
2023-12-04 22:19:31 +01:00
Applevangelist
4d4b8862c2 Merge remote-tracking branch 'origin/develop' into develop 2023-12-04 10:42:26 +01:00
Applevangelist
31b75b7d17 Merge remote-tracking branch 'origin/master' into develop 2023-12-04 10:42:23 +01:00
Thomas
fac7a5fdc6 Update CTLD.lua (#2058)
Add Remove Crates option
2023-12-04 10:40:38 +01:00
Frank
cfca4fdc46 Merge branch 'develop' into FF/Ops 2023-12-03 21:09:17 +01:00
Frank
cca5a5d55d Fixes
- Fixed A/C starting on ALERT5
- Fixed nil check for DrawID in UndrawZone
2023-12-03 20:51:19 +01:00
Applevangelist
3243c92331 Merge remote-tracking branch 'origin/master' into develop 2023-12-03 15:35:17 +01:00
Applevangelist
49191fb144 clarifications 2023-12-03 15:34:55 +01:00
Applevangelist
eab37d5e48 Merge remote-tracking branch 'origin/master' into develop 2023-12-03 12:39:34 +01:00
Applevangelist
f739062463 #ZONE_OVAL - fix documentation and intellisense 2023-12-03 12:39:08 +01:00
Applevangelist
e838431b28 Merge remote-tracking branch 'origin/master' into develop 2023-12-03 12:25:51 +01:00
Applevangelist
c22304f2b0 Remove demo links which were empty 2023-12-03 12:25:25 +01:00
Applevangelist
1c10bfea92 Merge remote-tracking branch 'origin/master' into develop 2023-12-03 12:11:55 +01:00
Applevangelist
c97d2ecaba #ATIS - multi freq example added 2023-12-03 12:11:22 +01:00
Applevangelist
2dc9f19d78 Merge remote-tracking branch 'origin/master' into develop 2023-12-03 12:03:41 +01:00
Applevangelist
89a9d1d0a4 #CONTROLLABLE
* Fixed ID issue with AA Missile Attack Range option

#POINT
* Added methdo to get the BULLSEYE as coordinate
2023-12-03 12:01:50 +01:00
Applevangelist
cf7d41cd7f #ZONE_POLYGON improvements
#ZONE_OVAL NEW
2023-12-03 11:42:53 +01:00
Niels Vaes
fd191be274 Added ZONE_OVAL. (#2057)
* Added ZONE_OVAL. This can be useful for simulating the area of a view zone from an object looking down at the ground for example.

Can be constructed from a Mission Editor drawing.

* add to DB
2023-12-03 11:34:52 +01:00
Thomas
31bdde130a Update Event.lua (#2056)
Fix for playername in weapon target
2023-12-03 09:26:09 +01:00
Thomas
afe542cc63 Update Event.lua
Fix for playername in weapon target
2023-12-03 09:23:42 +01:00
Frank
494550fe91 Merge pull request #2054 from nielsvaes/moose_develop_vanilla
Update on the ZONE_POLYGON class, so we can finally use it with drawings made in the Mission Editor as well
2023-12-02 20:48:26 +01:00
Niels Vaes
29c0d81c27 Update on the ZONE_POLYGON class, so we can finally use it with drawings made in the Mission Editor as well.
Supports closed line segments, rects and freely drawn polygons.

Added the correct way of generating a point within a polygon with trial and error

Added a way to get the surface area.

Added a helper class (_ZONE_TRIANGLE), which shouldn't ever be used on its own. It's there to support the update ZONE_POLYGON.

Some test code, assuming there's a poygon drawn in the mission editor called "poly":

```Lua
-- make a new zone from a drawing
poly = ZONE_POLYGON:NewFromDrawing("poly")
-- draw the zone for everyone, include the individual triangles that make up the polygon
poly:DrawZone(-1, {1,0,0}, 1, {1,0,0}, 255, 4, false, true)
-- generate 500 random points, evenly distributed in the polygon
for i=1, 500 do
	COORDINATE:NewFromVec2(poly:GetRandomVec2()):CircleToAll(1000)
end

-- remove the drawing from the game
poly:UndrawZone()
```
2023-12-02 20:33:30 +01:00
Applevangelist
e79c2481da Merge remote-tracking branch 'origin/master' into develop 2023-12-02 15:11:35 +01:00
Applevangelist
89a902fd57 #ATIS
* make info multi-frequency safe
2023-12-02 15:11:14 +01:00
Applevangelist
460ad9db39 Merge remote-tracking branch 'origin/master' into develop 2023-12-02 14:46:04 +01:00
Applevangelist
ae604fd847 #AIRBASE
* Add'l Normandy Airfields
2023-12-02 14:45:42 +01:00
Applevangelist
099f059eec Merge remote-tracking branch 'origin/develop' into develop 2023-12-01 16:29:52 +01:00
Applevangelist
c3bba7d1fc #PLAYERRECCE
* Make the laser corridor a bit wider

#FLIGHtCONTROL
* Also create non-info when ATIS isn't set
2023-12-01 16:29:49 +01:00
Frank
db71610d72 Merge branch 'master' into develop 2023-11-30 23:29:39 +01:00
Frank
4b8d120f20 Update Warehouse.lua
- Added check that DCS warehouse has enough air assets for selfpropelled assets
2023-11-30 23:29:29 +01:00
Applevangelist
1dc31cc852 spawn 2023-11-29 18:01:37 +01:00
Applevangelist
68b97773fe #OPSZONE
* Added option to set own pikey-ish zone colors
2023-11-29 16:42:30 +01:00
Applevangelist
3c0e977584 #PLAYERRECCE
* Bug fix for clock view calculation
* Ensure lasing is switched off when using the menu
* Create SPOT more often
2023-11-28 10:37:45 +01:00
Applevangelist
f03a48b118 Merge remote-tracking branch 'origin/master' into develop 2023-11-27 16:49:56 +01:00
Applevangelist
c489a88106 #GROUP
* Get Link16 S/TN data from a group
2023-11-27 16:49:06 +01:00
Frank
a4704d0e2f Update ArmyGroup.lua 2023-11-26 23:57:21 +01:00
Applevangelist
4747dae51a Merge remote-tracking branch 'origin/master' into develop 2023-11-26 17:00:17 +01:00
Applevangelist
b1e8ba74a8 Merge remote-tracking branch 'origin/master' into develop
# Conflicts:
#	Moose Development/Moose/Core/Spawn.lua
2023-11-26 16:59:57 +01:00
Applevangelist
641707f37b #UNIT
* Added `GetSTN()` to obtain Link16 info from a unit
2023-11-26 16:59:44 +01:00
Frank
7538f63c00 Merge branch 'develop' into FF/Ops 2023-11-26 16:46:13 +01:00
Frank
67924c894d Update SRS.lua
- Removed altbackend functions
2023-11-26 16:45:19 +01:00
Applevangelist
52ed645f6c -- noise 2023-11-25 18:44:38 +01:00
Applevangelist
7c8f212b03 -- noise 2023-11-25 18:44:21 +01:00
Applevangelist
9f41cc51be Merge remote-tracking branch 'origin/master' into develop 2023-11-25 18:30:04 +01:00
Applevangelist
85c73cb0a5 #SPAWN
*Link16 fixes
* Wrongly created STN's will be replaced with random five digit octals with leading 0
* Voice call sign label will be the callsign's first and last letters, e.g. Enfield = ED. Navy One = NY
* Voice call sign number equals callsign minor major, e.g. Enfield 6-1 = ED 61
* Also works for A10CII which has a different entry with a four-digit octal with leading 0
* for fighter aircraft you can use :InitRandomizeCallsign() to give each spawn a random callsign
2023-11-25 18:28:59 +01:00
Frank
1b1f8e0d2c Update SRS.lua 2023-11-24 23:59:31 +01:00
Frank
f87126f22c Merge branch 'master' into FF/MasterDevel 2023-11-24 15:44:54 +01:00
Applevangelist
6390b223b0 Merge remote-tracking branch 'origin/master' into develop 2023-11-24 12:17:56 +01:00
Applevangelist
b635490e47 SPAWN - Init Link16/datalink details in UNITs 2023-11-24 12:17:25 +01:00
Thomas
62e8302753 Update SRS.lua (#2047)
Fix for config load when not desanitized
2023-11-24 06:35:32 +01:00
Thomas
cac7b39823 Update SRS.lua
Fix for config load when not desanitized
2023-11-24 06:32:44 +01:00
Frank
bfaf88f017 Merge branch 'develop' into FF/Ops 2023-11-23 22:23:50 +01:00
Frank
cc79dc74d4 Merge branch 'master' into develop 2023-11-23 22:23:17 +01:00
Frank
af3c579a03 Update SRS.lua 2023-11-23 22:22:59 +01:00
Frank
a508c63279 Merge branch 'master' into FF/MasterDevel 2023-11-23 22:12:52 +01:00
Frank
427a11bd0f Merge pull request #2046 from nielsvaes/moose_master_vanilla
bugfix for impactHeading
2023-11-23 22:11:59 +01:00
Niels Vaes
6f3133d48c bugfix for impactHeading
clamping GetImpactHeading and GetReleaseHeading
2023-11-23 21:50:08 +01:00
Applevangelist
4f4e8b17c1 Merge remote-tracking branch 'origin/master' into develop 2023-11-23 18:46:03 +01:00
Applevangelist
aa7f26ac79 ATC_GROUND fix for scheduler 2023-11-23 18:45:36 +01:00
Frank
084caad5d7 Merge branch 'master' into FF/MasterDevel 2023-11-23 18:25:43 +01:00
Applevangelist
0850796368 Merge remote-tracking branch 'origin/master' into develop 2023-11-23 18:15:01 +01:00
Applevangelist
343bf05c2c SPAWN - Set correct unit ID in the group callsign 2023-11-23 18:14:25 +01:00
Applevangelist
ff58649954 Merge remote-tracking branch 'origin/master' into develop 2023-11-23 17:02:20 +01:00
Applevangelist
bbf793febe #CLIENTMENU 2023-11-23 17:01:33 +01:00
Applevangelist
3e40d72e25 #ATC_GROUND 2023-11-23 17:00:58 +01:00
Frank
1c1daa4ebe Merge pull request #2045 from nielsvaes/moose_master_vanilla
Adding a bunch of various helper functions to UTILS
2023-11-23 16:16:05 +01:00
Niels Vaes
fdcda6e5f3 typos 2023-11-23 15:22:14 +01:00
Niels Vaes
a50dde7f2b added functions:
UTILS.TimeNow
UTILS.TimeDifferenceInSeconds
UTILS.TimeLaterThan
UTILS.TimeBefore
UTILS.CombineTimeStrings
UTILS.SubtractTimeStrings
UTILS.TimeBetween
UTILS.PercentageChance
UTILS.Clamp
UTILS.ClampAngle
UTILS.RemapValue
UTILS.RandomPointInTriangle
UTILS.AngleBetween
UTILS.WriteJSON
UTILS.ReadJSON
UTILS.GetZoneProperties
UTILS.RotatePointAroundPivot
UTILS.UniqueName

string.startswith
string.endswith
string.split
string.contains

table.contains_key
table.remove_by_value
table.remove_key
table.index_of
table.length
table.slice
table.count_value
table.combine
table.merge
table.add
table.shuffle
table.find_key_value_pair
2023-11-23 15:18:23 +01:00
Frank
1fb4cb1c4f Merge pull request #2044 from nielsvaes/moose_master_vanilla
Added functions to get info at the time of weapon release
2023-11-23 00:31:57 +01:00
Niels Vaes
cd0f854f41 added functions:
GetReleaseHeading
GetReleaseAltitudeASL
GetReleaseCoordinate
GetReleasePitch
GetImpactHeading
2023-11-22 23:48:00 +01:00
Frank
52c2401d93 Update SRS.lua 2023-11-22 22:53:54 +01:00
Applevangelist
f071c674d0 fix 2023-11-22 18:35:23 +01:00
Applevangelist
02a87d9fe0 fix 2023-11-22 18:35:12 +01:00
Applevangelist
3c53f627c2 Merge remote-tracking branch 'origin/master' into develop 2023-11-22 17:57:51 +01:00
Applevangelist
12d68a41ca #MSRS
* Added option to explicitly set/switch the TTS provider between Google and MS (the default)
* Added this option to the config file, so you can set up both but switch
2023-11-22 17:54:52 +01:00
Applevangelist
2dfde7d1fd xxx 2023-11-21 13:22:51 +01:00
Applevangelist
c011d38313 Merge remote-tracking branch 'origin/master' into develop 2023-11-21 13:21:48 +01:00
Applevangelist
6c4a64601f MSRS
Docu fix
2023-11-21 13:21:22 +01:00
Applevangelist
68350d6824 Merge remote-tracking branch 'origin/master' into develop 2023-11-21 10:13:08 +01:00
Applevangelist
434f985e77 #MSRS
* Cleaner config loading strategy
2023-11-21 10:12:46 +01:00
Thomas
2e6cac7bee Update Utils.lua 2023-11-20 14:50:12 +01:00
Thomas
ba1dcfcdba Update Utils.lua
Avoid file loading stop scripts
2023-11-20 14:49:16 +01:00
Frank
b5965bbf81 Merge branch 'develop' into FF/Ops 2023-11-20 13:52:16 +01:00
Thomas
b346dabdf8 Update introduction.md (#2043) 2023-11-20 11:24:25 +01:00
kaltokri
a0429458d0 Merge branch 'master' into develop 2023-11-20 10:15:46 +01:00
kaltokri
1376a16812 Make linkinator results more stable with retry features 2023-11-20 10:15:20 +01:00
kaltokri
847dc1839f Merge branch 'master' into develop 2023-11-20 09:59:36 +01:00
kaltokri
4267314260 Merge branch 'userguide' 2023-11-20 09:59:07 +01:00
kaltokri
b5110c8554 Migration of MOOSE user guide
introduction and hello world
2023-11-20 09:56:44 +01:00
Applevangelist
0dd4da1db4 Merge remote-tracking branch 'origin/master' into develop 2023-11-19 15:36:46 +01:00
Applevangelist
1f1d1e4f2f #CTLD
* Added info event for repairs and builds starting
2023-11-19 15:36:16 +01:00
Applevangelist
4d4f8e9d61 Merge remote-tracking branch 'origin/master' into develop 2023-11-19 12:40:45 +01:00
Applevangelist
522eb8b256 #EVENT
* Handler for 2.9 new events
2023-11-19 12:40:22 +01:00
Applevangelist
6fe883a17a Merge remote-tracking branch 'origin/master' into develop 2023-11-18 17:17:05 +01:00
Applevangelist
b662ecc76b #MANTIS, SHORAD
* Added more options for ScootZones
2023-11-18 17:16:27 +01:00
Applevangelist
fbbdac9b7e Merge remote-tracking branch 'origin/master' into develop 2023-11-18 16:44:46 +01:00
Applevangelist
6dd69eb6db CTLD - avoid old mission go haywire with UnitCapabilities() 2023-11-18 16:44:23 +01:00
Applevangelist
1b6aeff005 #CTLD
* if a unit cannot do troops/crates, those menus are not shown
* renamed `UnitCapabilities()` to `SetUnitCapabilities()`
2023-11-18 16:31:10 +01:00
Applevangelist
de380614fb Merge remote-tracking branch 'origin/master' into develop 2023-11-18 13:23:58 +01:00
Applevangelist
4287774d9f EVENT fix for borked target info 2023-11-18 13:23:15 +01:00
Frank
bcbda4eb64 Merge branch 'develop' into FF/Ops 2023-11-17 18:04:49 +01:00
Applevangelist
f6fdff927b Merge remote-tracking branch 'origin/master' into develop 2023-11-17 15:07:46 +01:00
Applevangelist
58ce4b001e #PLAYERRECCE
* Fix issue which stops lasing though target is alive and in sight
2023-11-17 15:07:29 +01:00
Applevangelist
6bba2fec0b Spot 2023-11-17 15:06:52 +01:00
Applevangelist
5d2656d679 SET 2023-11-17 15:05:19 +01:00
Applevangelist
9a360a3bd5 #AWACS
* Small fix for no text on clean call
2023-11-17 12:05:14 +01:00
Applevangelist
217b8fe71e Merge remote-tracking branch 'origin/master' into develop 2023-11-17 11:05:53 +01:00
Applevangelist
65a729a2d6 Merge remote-tracking branch 'origin/master' 2023-11-17 11:05:26 +01:00
Applevangelist
7868930fcb ATIS 2023-11-17 11:05:22 +01:00
Applevangelist
67248a290c ATIS small fix 2023-11-17 11:04:33 +01:00
Thomas
32ae4986ca Update PlayerTask.lua
Weapon check for bomb runway task
2023-11-17 06:28:33 +01:00
Frank
2a0086d3fe Merge branch 'master' into develop 2023-11-17 00:26:33 +01:00
Frank
0bc52eb331 DCS stable
- Added check that ` Airbase.getWarehouse`  method exists because it causes problems with DCS stable as this method does not exist there.
2023-11-17 00:26:21 +01:00
Frank
75a6a798ac Update OpsZone.lua
- Fix for new `getCategory` behaviour
2023-11-16 22:52:13 +01:00
Frank
067285f870 Merge branch 'master' into develop 2023-11-16 22:32:17 +01:00
Frank
5353be482e getCategory behaviour
- Fixed several classes for new `getCategory` behaviour (should be backwards compatible to earlier DCS versions).
2023-11-16 22:32:01 +01:00
Applevangelist
8075be92a7 Merge remote-tracking branch 'origin/master' into develop 2023-11-16 18:11:58 +01:00
Applevangelist
826ae86cb7 #MANTIS
* Added IDF data
2023-11-16 18:11:30 +01:00
Applevangelist
f453619c78 Merge remote-tracking branch 'origin/master' into develop 2023-11-16 16:11:20 +01:00
Applevangelist
475153be4c #RANGE
* Added coalition option to `New()`
2023-11-16 16:10:47 +01:00
Applevangelist
ca20e059a6 #PLAYERRECCE
* Fixes for new Gazelle models
2023-11-16 14:08:33 +01:00
Applevangelist
2044068393 Merge remote-tracking branch 'origin/master' into develop 2023-11-15 18:17:23 +01:00
Applevangelist
5f734a0d17 #MESSAGE
* Fixes for ToSRS() for MS Desktop
2023-11-15 18:16:46 +01:00
Thomas
2c3e9e992d Update PlayerTask.lua
Bugfix
2023-11-15 07:24:01 +01:00
Applevangelist
ef27daa282 Merge remote-tracking branch 'origin/master' into develop 2023-11-14 12:15:48 +01:00
Applevangelist
1b8c9367a3 #MANTIS/#SEAD/#SHORAD
* Added shoot and scoot for MANTIS and SHORAD
* Added detection of TALD ADM-141A (all)
2023-11-14 11:57:58 +01:00
Applevangelist
e36ade55d2 Merge remote-tracking branch 'origin/master' into develop 2023-11-12 16:54:07 +01:00
Applevangelist
19047843cc #SEAD
* Added data and actions for TALD ADM_141
2023-11-12 16:53:34 +01:00
Applevangelist
2d631cba3f #AUTOLASE - Menu for smoking 2023-11-12 12:13:12 +01:00
Applevangelist
9ccfcb8fb1 Merge remote-tracking branch 'origin/develop' into develop 2023-11-11 19:02:34 +01:00
Applevangelist
a8e58b8121 #AUTOLASE
* Added menu to change the laser code
2023-11-11 19:02:26 +01:00
kaltokri
dcc968c290 Merge branch 'master' into develop 2023-11-11 16:06:52 +01:00
kaltokri
174454b8c5 Migrated Text-To-Speech guide to docs 2023-11-11 16:06:22 +01:00
kaltokri
36aa697936 Merge branch 'master' into develop 2023-11-10 16:54:58 +01:00
kaltokri
d30a53333c Migration of eclipse installation guide from wiki to docs 2023-11-10 16:53:41 +01:00
kaltokri
8bace684c2 Merge branch 'master' into develop 2023-11-10 16:23:27 +01:00
kaltokri
30b89328f1 Extension of the build documentation 2023-11-10 16:22:58 +01:00
kaltokri
aa5163fe3a Merge branch 'master' into develop 2023-11-10 15:37:20 +01:00
kaltokri
b38dc62be7 Restructure of the docs content 2023-11-10 15:36:54 +01:00
kaltokri
097e0a3214 Merge branch 'master' into develop 2023-11-10 10:52:53 +01:00
kaltokri
6d9333aa94 Added new README.md 2023-11-10 10:50:20 +01:00
kaltokri
b5c9598cb0 Merge branch 'master' into develop 2023-11-09 16:39:15 +01:00
kaltokri
6947bcfcf2 Used newest Discord link and small enhancements 2023-11-09 16:38:50 +01:00
Applevangelist
bc454fdec2 #docu changes 2023-11-09 15:16:51 +01:00
Applevangelist
166a7ab7db #DATABASE
* Register players joining CA slots as CLIENTs
2023-11-09 15:09:39 +01:00
Applevangelist
db06154ad7 #DATABASE
* Register players joining CA slots as CLIENTs
2023-11-09 15:09:01 +01:00
Applevangelist
f459372720 #CLIENTMENUMANAGER
* Added `CLIENTMENUMANAGER:InitAutoPropagation()`

#PLAYERTASK
* Some menu fixes
2023-11-09 15:08:28 +01:00
Applevangelist
f5d2439d69 Merge remote-tracking branch 'origin/master' into develop 2023-11-08 17:54:08 +01:00
Applevangelist
fa43a6c40b Symlink fix 2023-11-08 17:53:43 +01:00
Applevangelist
04c092b9ef Merge remote-tracking branch 'origin/develop' into develop 2023-11-08 17:44:12 +01:00
Applevangelist
7af920891d Merge remote-tracking branch 'origin/master' into develop 2023-11-08 17:44:08 +01:00
Applevangelist
5056187fb9 #GROUP #UNIT
* Added `FindByMatching(Pattern)` and `FindAllByMatching(Pattern)`
2023-11-08 17:43:29 +01:00
kaltokri
d9d333a7af Merge branch 'master' into develop 2023-11-08 17:39:40 +01:00
kaltokri
72c5c2ee4d Parameter has different behaviour on Windows and Linux 2023-11-08 17:39:19 +01:00
kaltokri
8f73a4c27c Merge branch 'master' into develop 2023-11-08 17:33:57 +01:00
kaltokri
25936a526d Fixed small typo in gh-pages.yml 2023-11-08 17:33:25 +01:00
kaltokri
f4b83a97a9 Merge branch 'master' into develop 2023-11-08 17:27:30 +01:00
kaltokri
8bc735288f Skip java.com when checking links. Seems to be blocked for GitHub 2023-11-08 17:27:04 +01:00
Applevangelist
3360f511ee Merge remote-tracking branch 'origin/develop' into develop 2023-11-08 17:01:57 +01:00
Applevangelist
f64ec74d1c #PLAYERRECCE
* Added doku for OnAfter.. calls
2023-11-08 17:01:50 +01:00
kaltokri
b885ef7767 Merge branch 'master' into develop 2023-11-08 16:59:31 +01:00
kaltokri
f8afa1cb78 Renamed old-guides into archive 2023-11-08 16:59:20 +01:00
kaltokri
22f5104805 Merge branch 'master' into develop 2023-11-08 16:23:47 +01:00
kaltokri
e95eb2768d Replaced absolute links with relative ones to fix problem on GitHub pages 2023-11-08 16:23:31 +01:00
kaltokri
266e34a92d Merge branch 'master' into develop 2023-11-08 13:45:53 +01:00
kaltokri
f6091cd117 Migrated old documentation to just-the-docs 2023-11-08 13:44:56 +01:00
Applevangelist
500a7f938f Merge remote-tracking branch 'origin/master' into develop 2023-11-08 11:24:00 +01:00
Applevangelist
f408c11506 Merge remote-tracking branch 'origin/develop' into develop 2023-11-08 11:23:38 +01:00
Applevangelist
9fafdea0bb #EVENT #NET
* On a MP server, added IniPlayerUCID and TgtPlayerUCID to the EventData structure (filled in applicable Events)
2023-11-08 11:23:01 +01:00
Applevangelist
b4058ecab2 #FLIGHTCONTROL
* Fix for shelters, puts the guy out front and not on top.
2023-11-08 11:09:39 +01:00
Frank
7306cc1102 Merge branch 'develop' into FF/Ops 2023-11-07 00:05:16 +01:00
Frank
21aadc14b1 Merge branch 'master' into develop 2023-11-06 22:01:26 +01:00
Frank
fbf2c4c721 Update Event.lua
- Improved getCategory behaviour
2023-11-06 22:01:05 +01:00
Applevangelist
eed6119193 #FLIGHTGROUP
* Resolve a stalemate when all jobs are done but _CheckGroupDone isn't called any longer
2023-11-06 18:36:02 +01:00
Applevangelist
6db2e333ad Merge remote-tracking branch 'origin/master' into develop 2023-11-05 13:01:59 +01:00
Applevangelist
9d3cb4cc1b #MESSAGE
* SRS label correction
2023-11-05 13:01:27 +01:00
kaltokri
0eb9dfc7de Merge branch 'master' into develop 2023-11-03 16:34:36 +01:00
kaltokri
9d500186d1 Enhancement of build-docs to remove old files 2023-11-03 16:33:45 +01:00
kaltokri
f80265786d Fix broken links SetEngageRange 2023-11-03 15:52:53 +01:00
Applevangelist
4eb0f8e9ca Merge remote-tracking branch 'origin/master' into develop 2023-11-03 13:39:02 +01:00
Applevangelist
5a583671a7 #SRS - Improvements, set also a coordinate 2023-11-03 13:38:37 +01:00
Applevangelist
7b9d8d375d #SRS Improvements 2023-11-03 13:37:59 +01:00
Frank
6406ce696b Merge branch 'develop' into FF/Ops 2023-11-02 20:31:57 +01:00
Applevangelist
e560c3ffdd Merge remote-tracking branch 'origin/master' into develop 2023-11-02 19:25:50 +01:00
Applevangelist
7393cb2cbe #ATIS
* Some fixes
2023-11-02 19:25:28 +01:00
Applevangelist
74bd41743b Merge remote-tracking branch 'origin/develop' into develop 2023-11-02 18:20:49 +01:00
Applevangelist
56d4143a05 Merge remote-tracking branch 'origin/master' into develop 2023-11-02 18:20:45 +01:00
Applevangelist
1093e55ea8 #OPSGROUP #FLIGHTCONTROL
* Added setting coordinate for SRS
2023-11-02 18:19:55 +01:00
Applevangelist
bcbe872c7d #ATIS
* Added coordinate for SRS
* Added SRS calling out take off AND landing runway (if set)
2023-11-02 18:18:55 +01:00
kaltokri
cc95c45fb0 Merge branch 'master' into develop 2023-11-02 15:16:41 +01:00
kaltokri
bf60c535bc Merge branch 'master' of github.com:FlightControl-Master/MOOSE
# Conflicts:
#	Moose Development/Moose/Tasking/Task_Cargo_CSAR.lua
2023-11-02 15:16:12 +01:00
kaltokri
feb99e9405 Fix for SetEngageRange documentation in AI_A2A and A2G classes 2023-11-02 15:14:57 +01:00
Frank
6c36910ac7 Update FlightGroup.lua
#2033
2023-11-02 01:41:39 +01:00
Frank
d60f20a162 Merge branch 'master' into develop 2023-11-02 01:40:01 +01:00
Frank
9fde88d61a Merge branch 'master' of https://github.com/FlightControl-Master/MOOSE 2023-11-02 01:39:42 +01:00
Frank
430b4a274c Update Warehouse.lua
#2033
2023-11-02 01:39:40 +01:00
Thomas
dc26134845 Merge from master (#2036)
* Update Storage.lua

* Update Storage.lua (#2035)
2023-11-01 06:21:56 +01:00
Thomas
5996426119 Update Storage.lua (#2035) 2023-11-01 06:20:36 +01:00
Thomas
36d9460cdf Update Storage.lua 2023-11-01 06:19:53 +01:00
Frank
0d9d0be0c3 Merge branch 'develop' into FF/Ops 2023-10-31 20:14:46 +01:00
Frank
adad7ef901 Merge branch 'master' into develop 2023-10-31 19:53:35 +01:00
Frank
1561f49c9c Lings
- Fixed link in Core.Condition (will add demo miz)
- Fixed lings in Task_Cargo_CSAR und Task_Cargo_Transport
2023-10-31 19:53:20 +01:00
kaltokri
bb6bb20179 Merge branch 'master' into develop 2023-10-31 16:37:19 +01:00
kaltokri
e032781a92 Changed Core.Group to Wrapper.Group 2023-10-31 16:36:51 +01:00
kaltokri
07cac604cf Merge branch 'master' into develop 2023-10-31 16:31:01 +01:00
kaltokri
aa7d0b1e25 Fixed broken links 2023-10-31 16:30:48 +01:00
kaltokri
28cb44874f Merge branch 'master' into develop 2023-10-31 16:06:06 +01:00
kaltokri
13a8babe75 Fixed broken links 2023-10-31 16:05:48 +01:00
kaltokri
616f204f5b Merge branch 'master' into develop 2023-10-31 15:44:22 +01:00
kaltokri
87dda49113 Fixed broken links 2023-10-31 15:44:07 +01:00
kaltokri
211e1b41b0 Merge branch 'master' into develop 2023-10-31 15:23:53 +01:00
kaltokri
018830b539 Merge branch 'master' of github.com:FlightControl-Master/MOOSE
# Conflicts:
#	Moose Development/Moose/AI/AI_Air_Engage.lua
2023-10-31 15:23:26 +01:00
kaltokri
d92d2d07c5 Fixed broken links 2023-10-31 15:21:15 +01:00
Frank
cd316e6719 Merge branch 'master' into develop 2023-10-31 13:44:56 +01:00
Frank
046e49ac6b Merge branch 'master' of https://github.com/FlightControl-Master/MOOSE 2023-10-31 13:35:41 +01:00
Frank
52e66ae969 Broken Links
- AI_A2A_Gci Removed reference to SetEngageZone
- Fixed link to #AI_A2G_SEAD.SetEngageRange #2025
- AI_Air_Engage removed reference to SetEngageZone. Does not seem to exist any more.
- AI_Air_Patrol removed reference to SetEngageZone. Does not seem to exist any more or is passed as argument now.
- AI_FORMATION Fixed DCSTypes#AI.Option.Air.val.ROE OptionROE #2029
- SETTINGS Fixed link to Message #2021
- Fixed wrong indent of "Developer Note" in various classes
2023-10-31 13:33:45 +01:00
kaltokri
0fb8fd8886 Merge branch 'master' into develop 2023-10-31 13:07:02 +01:00
kaltokri
ca15d7cb00 Merge branch 'master' of github.com:FlightControl-Master/MOOSE 2023-10-31 13:05:29 +01:00
kaltokri
1086c61ccf Fixed broken links 2023-10-31 13:04:48 +01:00
Frank
77f9721102 AI
- Fixed various `@extends` errors pointing to non-existing classes for AI_*
2023-10-31 11:44:45 +01:00
Frank
059d8ccfc0 Merge branch 'FF/Ops' of https://github.com/FlightControl-Master/MOOSE into FF/Ops 2023-10-31 10:45:58 +01:00
Frank
bd9022c010 ARMYGROUP
Added parameter to delay init group
2023-10-31 10:45:56 +01:00
kaltokri
261a389ca5 Merge branch 'master' into develop 2023-10-31 10:25:38 +01:00
kaltokri
b05683d384 Fixed some broken links 2023-10-31 10:25:00 +01:00
kaltokri
708838c404 Merge branch 'master' into develop 2023-10-30 18:02:27 +01:00
kaltokri
d7df08d754 Fixed broken links in documentation 2023-10-30 18:01:57 +01:00
kaltokri
974a56b135 Merge branch 'master' into develop 2023-10-30 14:56:32 +01:00
kaltokri
92b21aa5c1 Fixed broken links in documentation 2023-10-30 14:48:49 +01:00
kaltokri
85c551cc59 Merge branch 'master' into develop 2023-10-29 23:06:31 +01:00
kaltokri
0e2dff4e6b Fixed some dead links in Ops.Airboss 2023-10-29 23:06:09 +01:00
kaltokri
f33ccee7b1 Merge branch 'master' into develop 2023-10-29 19:44:24 +01:00
kaltokri
5c9e3570e2 Added more docker jobs and apply same naming convention as build jobs 2023-10-29 19:43:55 +01:00
Applevangelist
7277221905 Merge remote-tracking branch 'origin/master' into develop 2023-10-29 17:45:23 +01:00
Applevangelist
497ac367ba #CTLD
* Adding re-packing dropped units
2023-10-29 17:45:02 +01:00
Applevangelist
51102e47ae #CTLD
* Adding re-packing dropped units
2023-10-29 17:44:31 +01:00
Xavier V
92e2414612 Added pack crates (#2019) 2023-10-29 17:29:01 +01:00
kaltokri
3ca4898860 Merge branch 'master' into develop 2023-10-27 17:49:14 +02:00
kaltokri
7643568706 Fixed dead links in documentation 2023-10-27 17:48:41 +02:00
kaltokri
e4d6e6d80e Merge branch 'master' into develop 2023-10-27 17:28:19 +02:00
kaltokri
3684a023da Fixed dead link 2023-10-27 17:27:38 +02:00
kaltokri
99ebebe13c Merge branch 'master' into develop 2023-10-27 17:05:11 +02:00
kaltokri
b0c8f05f38 Build optimization
- Remove appveyor
- Added docker compose for building docs locally
- Added manuall run of GitHub Action builds
- Added paths to trigger builds
2023-10-27 17:01:51 +02:00
Applevangelist
bf604da2ae Merge remote-tracking branch 'origin/master' into develop 2023-10-27 09:10:04 +02:00
Applevangelist
d8c2b8b719 #UTILS
* Added new tanke callsigns
2023-10-27 09:09:36 +02:00
Applevangelist
bca3abe2c2 Merge remote-tracking branch 'origin/develop' into develop 2023-10-26 12:46:20 +02:00
Applevangelist
3a06f6314e Merge remote-tracking branch 'origin/master' into develop 2023-10-26 12:46:16 +02:00
Applevangelist
31075f7c04 #UNIT
* Typos in IsTanker, added some typenames
2023-10-26 12:45:45 +02:00
kaltokri
6bf6b933cc Fixed last broken link 2023-10-25 15:52:11 +02:00
kaltokri
5681244941 Fix for canonical link 2023-10-25 15:45:20 +02:00
kaltokri
e7f7199a39 Merge branch 'master' into develop 2023-10-25 15:35:59 +02:00
kaltokri
788108c5b8 Added check for dead links and fixed dead links 2023-10-25 15:34:06 +02:00
Applevangelist
6e1dabfe9b #FLIGHTCONTROL
* Added option to switch subs on/off per instance
2023-10-25 13:47:11 +02:00
Applevangelist
e48a823560 #EASYGCICAP, CONTROLLABLE, OPSGROUP, AUFTRAG
* Changed patrol race track alt to be ASL not AGL by default
2023-10-25 08:46:52 +02:00
Applevangelist
8f1e2a1d54 Merge remote-tracking branch 'origin/develop' into develop 2023-10-24 18:25:09 +02:00
Applevangelist
74d54637d5 #PLAYERTASK
* Remove client from task, even if only player name is available
2023-10-24 18:25:02 +02:00
kaltokri
1126b7753a Merge branch 'master' into develop 2023-10-24 17:04:00 +02:00
kaltokri
3fbc76e37f Documentation of the build system added 2023-10-24 17:03:01 +02:00
Applevangelist
e24acb28f7 Merge remote-tracking branch 'origin/master' into develop 2023-10-24 13:46:35 +02:00
Applevangelist
4e5b483cc0 #CONTROLLABLE
* Added PatrolRaceTrack
2023-10-24 13:45:43 +02:00
Applevangelist
f28f807ee7 #EASYGCICAP
* Closer turning cap routes
2023-10-24 13:45:15 +02:00
Applevangelist
375a564446 Merge remote-tracking branch 'origin/master' into develop 2023-10-21 12:43:48 +02:00
Applevangelist
ab068670cc #RECOVERYTANKER
* Added option to set unlimited fuel
2023-10-21 12:43:20 +02:00
kaltokri
c00da0f925 Merge branch 'master' into develop 2023-10-20 23:37:57 +02:00
kaltokri
456c002c3c Fix for missing w3.css in DOCS repo 2023-10-20 23:37:29 +02:00
kaltokri
6161da3a22 Merge branch 'master' into develop 2023-10-20 22:52:07 +02:00
kaltokri
038b89776d Added replacement of head tag again 2023-10-20 22:45:52 +02:00
Applevangelist
54e44299d8 Merge remote-tracking branch 'origin/develop' into develop 2023-10-20 18:45:05 +02:00
Applevangelist
f71d6f3f30 Merge remote-tracking branch 'origin/master' into develop 2023-10-20 18:45:02 +02:00
Applevangelist
df6d968ebe #CONTROLLABLE
* Added `CommandSetUnlimitedFuel()`
* Added `TaskStrafing()`
2023-10-20 18:44:28 +02:00
kaltokri
daae77def5 Merge branch 'master' into develop 2023-10-20 16:15:43 +02:00
kaltokri
4d9197b3cc First version of the new GitHub pages 2023-10-20 16:13:30 +02:00
kaltokri
b808f2f568 Merge branch 'master' into develop 2023-10-20 09:59:06 +02:00
kaltokri
10dffb0689 Changed mail from MooseBotter 2023-10-20 09:58:35 +02:00
kaltokri
91aa2eb9f2 Merge branch 'master' into develop 2023-10-19 18:54:17 +02:00
kaltokri
722c33df62 Fixed wrong git config entries in build-docs.yml 2023-10-19 18:53:52 +02:00
kaltokri
3d697211bd Merge branch 'master' into develop 2023-10-19 18:25:07 +02:00
kaltokri
dc54cc82af Fixed wrong repository owner 2023-10-19 18:24:46 +02:00
kaltokri
4fced3416a Merge branch 'master' into develop 2023-10-19 18:17:12 +02:00
kaltokri
d4a46606fd Switched from env.FORCE_PUSH to vars.FORCE_PUSH 2023-10-19 18:16:45 +02:00
Thomas
015af9774c Update build-includes.yml 2023-10-19 16:17:48 +02:00
Thomas
f0a37172b9 Update build-includes.yml (#2018) 2023-10-19 16:14:59 +02:00
Thomas
2dd2e593e8 Update README.md (#2017) 2023-10-19 15:48:50 +02:00
Applevangelist
49fd78abe7 #SRS
* Typo
2023-10-19 15:22:13 +02:00
Rolf Geuenich
1b5067088f Merge branch 'master' into develop
Added new build system with GitHub Action Workflows
2023-10-19 14:00:22 +02:00
Rolf Geuenich
7c8cca7f56 Added new build system with GitHub Action Workflows 2023-10-19 13:59:33 +02:00
Rolf Geuenich
2986a33a56 Merge branch 'master' into develop
Align Moose_Create.lua with the dev branch
2023-10-19 11:39:33 +02:00
Rolf Geuenich
0658f6dc2b Align Moose_Create.lua with the develop branch
Needed for later build system enhancements
2023-10-19 11:39:07 +02:00
Rolf Geuenich
ce6624fe0b Merge branch 'master' into develop
Preperation for new build system
2023-10-19 11:11:46 +02:00
Rolf Geuenich
75558078ee Cleanup and extension for GitHub Action Workflow build and act 2023-10-19 11:11:23 +02:00
Applevangelist
3ba868b3b9 Merge remote-tracking branch 'origin/master' into develop 2023-10-17 16:58:40 +02:00
Applevangelist
f6b5c69d4e #Triggers - docu changes 2023-10-17 16:58:14 +02:00
Applevangelist
85b10fb1c9 Merge remote-tracking branch 'origin/master' into develop 2023-10-17 16:03:24 +02:00
Applevangelist
a7f01eb04a #ZONE and #SET_ZONE watch trigger 2023-10-17 16:02:01 +02:00
Applevangelist
e578a673d9 Merge remote-tracking branch 'origin/master' into develop
# Conflicts:
#	Moose Development/Moose/Sound/SRS.lua
2023-10-17 11:08:13 +02:00
Applevangelist
65f9db8efa #MSRS
* Added loading of a config file
2023-10-17 11:05:09 +02:00
Applevangelist
3f04249d07 Merge remote-tracking branch 'origin/master' into develop
# Conflicts:
#	Moose Development/Moose/Sound/SRS.lua
2023-10-13 16:15:23 +02:00
Applevangelist
2ebad9ce96 #MSRS
* Fixes for alternative backend
2023-10-13 16:13:12 +02:00
Applevangelist
b8a2b28462 Merge remote-tracking branch 'origin/master' into develop 2023-10-12 18:02:33 +02:00
Applevangelist
9ccde838e7 #AUFTRAG
* More Bryce fixes
2023-10-12 18:01:56 +02:00
Applevangelist
6ba62e3e04 #AUFTRAG
* bear trap for Bryce using RECON Auftrags
2023-10-12 17:56:31 +02:00
Applevangelist
b9cc66004d #WAREHOUSE
* Syntax
2023-10-12 17:55:41 +02:00
Applevangelist
fb1b5b209e Merge remote-tracking branch 'origin/master' into develop 2023-10-06 15:50:10 +02:00
Applevangelist
17838e7fe7 #MESSAGE
* Docu adds and corrections
2023-10-06 15:49:42 +02:00
Applevangelist
9493570e6b Merge remote-tracking branch 'origin/master' into develop 2023-10-06 13:18:50 +02:00
Applevangelist
b0d0dbfe72 #MESSAGE
* Added `ToSRS()`
2023-10-06 13:18:28 +02:00
Applevangelist
439c11c376 Merge remote-tracking branch 'origin/master' into develop 2023-10-06 11:43:50 +02:00
Applevangelist
2d081dfc03 CTLD/CSAR - Added sound file location 2023-10-06 11:42:51 +02:00
Applevangelist
a6c244f670 Merge remote-tracking branch 'origin/master' into develop 2023-10-06 11:31:59 +02:00
Applevangelist
8c44cf8fca #EasyGCICAP
* Added Recon Patrol points
2023-10-06 11:31:35 +02:00
Applevangelist
4a594f41b0 #SET_ZONE
* Added GetAverageCoordinate()
2023-10-06 11:30:59 +02:00
Frank
ffea9708d1 Merge branch 'master' into develop 2023-09-29 15:39:28 +02:00
Frank
04b4af58f7 Update ATIS.lua
#2010
2023-09-29 14:26:22 +02:00
Applevangelist
b108bd9ac6 Merge branch 'master' into develop 2023-09-29 10:20:27 +02:00
Applevangelist
f44ba39ec5 Fox/Missiletrainers 2023-09-29 10:20:01 +02:00
Applevangelist
a54b785ca3 #EasyGCICAP
* Docu additions
2023-09-28 13:28:35 +02:00
Applevangelist
6c3f3cf0d2 #EasyGCICAP
* Added option for an AWACS patrol point and Squad
* Added option to make Tanker and AWACS invisible
2023-09-28 13:15:56 +02:00
Frank
bd79750efa Merge branch 'master' into develop 2023-09-27 22:28:58 +02:00
Frank
05df765c5c Merge pull request #2006 from FlightControl-Master/FF/MasterDevel
Update Airboss.lua
2023-09-27 22:28:21 +02:00
Frank
04a7c912ea Update Airboss.lua
- Improved into wind
2023-09-27 22:21:17 +02:00
Applevangelist
39fc112e53 Merge remote-tracking branch 'origin/master' into develop 2023-09-27 18:08:25 +02:00
Applevangelist
55fb8f2064 nil check added 2023-09-27 18:08:02 +02:00
Applevangelist
5dc5736976 #EasyGCICAP
* Added success criteria if intruder leaves monitored zones
2023-09-27 18:07:50 +02:00
Applevangelist
1f23525799 Merge remote-tracking branch 'origin/develop' into develop 2023-09-27 15:42:26 +02:00
Applevangelist
f390616e41 Merge remote-tracking branch 'origin/master' into develop 2023-09-27 15:42:23 +02:00
Applevangelist
912c162eee Logic fixes for GetRandomCoordinateWithoutBuildings() 2023-09-27 15:41:52 +02:00
Frank
dfc7f17308 NAVYGROUP
- Improved heading into wind
2023-09-27 10:57:12 +02:00
Applevangelist
c4e8ad50c8 Docu adds 2023-09-26 13:29:09 +02:00
Applevangelist
652df5570a #EasyGCICAP
* initial release
2023-09-26 13:07:41 +02:00
Applevangelist
bb8e6eb7a1 Merge remote-tracking branch 'origin/master' into develop 2023-09-25 08:43:50 +02:00
Applevangelist
2efb6a624f #SCORING
* Rechtschreibung
2023-09-25 08:43:24 +02:00
Frank
b7b369e78f Merge pull request #2003 from FlightControl-Master/FF/Ops
LEGION
2023-09-20 21:55:03 +02:00
Frank
b1436b66d4 LEGION
- Added random asset score
- Added nil check for request.cargogroupset in :onafterAssetDead
2023-09-20 21:52:28 +02:00
Applevangelist
d2107466cc Merge remote-tracking branch 'origin/develop' into develop 2023-09-20 17:17:43 +02:00
Applevangelist
3975e1961e Merge remote-tracking branch 'origin/master' into develop 2023-09-20 17:17:40 +02:00
Applevangelist
ca84fa11cd #ATIS
* Added Spanish TTS locale ("es")
2023-09-20 17:17:12 +02:00
Frank
78ffaf6e0a Update OpsGroup.lua
- Fix that loading is never done
2023-09-20 14:38:24 +02:00
Applevangelist
7c3c39c1ba Merge remote-tracking branch 'origin/master' into develop 2023-09-19 18:08:16 +02:00
Applevangelist
ed614767e6 #ATIS
* Added localization option
2023-09-19 18:07:51 +02:00
Applevangelist
147f39981b Merge remote-tracking branch 'origin/master' into develop 2023-09-19 12:14:19 +02:00
Applevangelist
6d94a0c776 Smaller fixes 2023-09-19 12:13:39 +02:00
Applevangelist
80fdbc4960 Merge remote-tracking branch 'origin/master' into develop 2023-09-19 11:31:18 +02:00
Applevangelist
81fd5cb605 One Typo Less 2023-09-19 11:30:46 +02:00
Applevangelist
fc9ddae9b2 Merge remote-tracking branch 'origin/master' into develop 2023-09-19 11:10:33 +02:00
Applevangelist
b70bf3b9af #SEAD
* Better calculation of switch-on again time
2023-09-19 11:10:06 +02:00
Applevangelist
d0330cc696 Merge remote-tracking branch 'origin/master' into develop 2023-09-17 17:16:30 +02:00
Applevangelist
250d640e76 #SPAWN
* Added option for Modex pre- and postfix strings
* Added string check for SpawnAtParkingSpot when Airbase is handed as string
2023-09-17 17:15:12 +02:00
Frank
dca70eaa05 Merge branch 'master' into develop 2023-09-17 16:13:50 +02:00
Frank
6a05789db5 Update Controllable.lua
- Fixed wrong id of task`EnrouteTaskEngageGroup`
- Fixed wrong id of task `EnrouteTaskFAC_EngageGroup`
2023-09-17 16:13:28 +02:00
Applevangelist
5048201771 #Startup
* Re-instate suppression of error box.
2023-09-15 09:12:17 +02:00
Applevangelist
5e20874dca #Startup
* Re-instate suppression of error box.
2023-09-15 09:11:32 +02:00
Applevangelist
5e36425058 #PLAYERTASKCONTROLLER
* Fix a problem that sometimes the object event is called prior to the SET_CLIENT event for players joining, leading to false negatives on specifically filtered SET_CLIENT objects
2023-09-14 12:36:51 +02:00
Applevangelist
bc16970d96 #SET_CLIENT
* Small fix for FilterCallsign string search
2023-09-14 12:36:15 +02:00
Applevangelist
3f1ad24f6a Merge remote-tracking branch 'origin/master' into develop
# Conflicts:
#	Moose Development/Moose/Core/Database.lua
#	Moose Development/Moose/Functional/MissileTrainer.lua
2023-09-13 16:04:23 +02:00
Applevangelist
674fef554d Intellisense docu fixes 2023-09-13 16:03:32 +02:00
Applevangelist
f8f4bac77e Intellisense docu fixes 2023-09-13 16:03:05 +02:00
Frank
3e2d312202 Merge branch 'master' into develop 2023-09-13 11:11:43 +02:00
Frank
5aa8338c59 Update Airboss.lua
- Adjust into wind angle
2023-09-13 11:10:35 +02:00
Frank
6ccfd499c8 Update SRS.lua
- Fixed bug in GRPC backend
2023-09-10 22:42:39 +02:00
Frank
468a8fed8b Merge branch 'master' into develop 2023-09-10 22:40:17 +02:00
Frank
1362fe9019 Update SRS.lua 2023-09-10 22:40:05 +02:00
Applevangelist
ef3127fdab Merge remote-tracking branch 'origin/master' into develop 2023-09-10 15:42:48 +02:00
Applevangelist
ba361e7eff #RAT
* Try more than once to get coord in status loop
2023-09-10 15:41:54 +02:00
Applevangelist
ab1e3e6c60 #AICSAR
* Force LoadingDone, UnloadingDone since changes in OPSTRANSPORT
2023-09-09 13:09:20 +02:00
Thomas
515764bb88 Update Group.lua
Docu fix
2023-09-09 11:56:28 +02:00
Thomas
31fb9bc169 Update Group.lua
Docu fix
2023-09-09 11:54:45 +02:00
Applevangelist
917f06fe04 Revert "Auxiliary commit to revert individual files from e5e81dbc35d61a32f5f6308b275eef278c970f2c"
This reverts commit 4f771489b473634ca3c758a02fd090e0cd26a964, reversing
changes made to c5f3bfe4a9.
2023-09-08 11:21:25 +02:00
Applevangelist
e5e81dbc35 Merge remote-tracking branch 'origin/master' into develop
# Conflicts:
#	Moose Development/Moose/Modules.lua
2023-09-08 11:20:11 +02:00
Applevangelist
e95a9525c6 #GENERAL
* Remove dependencies from UTILS.Routines
* Remove UTILS.Routines
2023-09-08 11:14:41 +02:00
Applevangelist
c5f3bfe4a9 Merge remote-tracking branch 'origin/master' into develop 2023-09-07 16:15:08 +02:00
Applevangelist
326d4b3135 Merge remote-tracking branch 'origin/master' 2023-09-07 16:14:45 +02:00
Applevangelist
c4fad08d58 Act 2023-09-07 16:14:42 +02:00
Applevangelist
5a57d05fd6 Deprecated flags 2023-09-07 16:14:21 +02:00
Applevangelist
5329745325 Merge remote-tracking branch 'origin/develop' into develop 2023-09-07 12:45:30 +02:00
Applevangelist
792222f567 #PLAYERTASK, #CLIENTMENU
* Fixes
2023-09-07 12:45:26 +02:00
Frank
a8f14fca70 Merge branch 'master' into develop 2023-09-06 21:33:29 +02:00
Frank
8a7fa326cd Update MissileTrainer.lua
- Docs: Class deprecated ==> use FOX instead
2023-09-06 21:33:05 +02:00
Frank
02105b1efc Update Airboss.lua
Fixed bug missing end in if statement
2023-09-05 20:53:02 +02:00
Applevangelist
93fd9e5d42 #CLIENTMENU
* Catch error on Menu removes
2023-09-05 10:35:12 +02:00
Applevangelist
65c384622c #AIRBOSS
* Suppress unnecessary SRS TTS calls with empty text
2023-09-01 09:46:52 +02:00
Applevangelist
18afe9ad7a #AIRBOSS
* Suppress unnecessary SRS TTS calls with empty text
2023-09-01 09:44:12 +02:00
Applevangelist
d7b87b63d8 #MANTIS
* Added zone filter option.
2023-09-01 08:52:46 +02:00
Applevangelist
253cf0f5a5 #MANTIS
* Added zone filter option.
2023-09-01 08:52:13 +02:00
Frank
b5b079d75f Merge pull request #2001 from ttrebuchon/tt/auftrag-newcap-nil-ref-bugfix
Fix error in AUFTRAG:NewCAP when Altitude is not explicitly provided
2023-08-31 14:57:31 +02:00
ttrebuchon
d0421f5226 Ensure Altitude is not nil in NewCAP to avoid breaking KnotsToAltKIAS. 2023-08-31 08:48:08 -04:00
Applevangelist
79ddc01bf7 Merge remote-tracking branch 'origin/master' into develop 2023-08-30 16:47:19 +02:00
Applevangelist
c5a85456c0 #MANTIS
* CHM Assets
2023-08-30 16:46:13 +02:00
Applevangelist
9a383826e7 Merge remote-tracking branch 'origin/master' 2023-08-29 15:49:52 +02:00
Applevangelist
1e6731830e #MANTIS
* Added two more CH mod types
2023-08-29 15:49:48 +02:00
Applevangelist
c4b874e3f9 #MANTIS
* Added two more CH mod types
2023-08-29 15:49:20 +02:00
Applevangelist
d9aff32a36 #MANTIS
* Added two more CH mod types
2023-08-29 15:48:36 +02:00
Frank
8b04d32839 Merge pull request #2000 from FlightControl-Master/FF/Ops
Update OpsGroup.lua
2023-08-28 20:27:39 +02:00
Frank
382605d4cf Update OpsGroup.lua
- Fixed bug loading opsgroups as cargo
2023-08-28 20:23:51 +02:00
Frank
1337815f05 Merge pull request #1999 from FlightControl-Master/FF/Ops
OPSTRANSPORT
2023-08-27 18:46:50 +02:00
Frank
1cd3b6a26b OPSTRANSPORT
- Docs
2023-08-27 15:13:07 +02:00
Frank
f34dcdb3db OPSGROUP
- Added parameter to selfdestruct single element
2023-08-27 12:03:26 +02:00
Frank
e3b7a85956 OPSTRANSPORT
- Improved storage transport
2023-08-26 23:55:21 +02:00
Frank
655282a034 Merge branch 'develop' into FF/Ops 2023-08-26 14:06:15 +02:00
Frank
94dde73561 Merge branch 'master' into develop 2023-08-26 14:05:51 +02:00
Frank
38cb8fb88e Merge pull request #1998 from FlightControl-Master/FF/MasterDevel
STORAGE
2023-08-26 14:00:26 +02:00
Frank
ad5488784f Update Storage.lua
**STORAGE**
- Added easier functions to add, set and remove items and liquids.
- Added checks if warehouse items are limited or unlimited.
2023-08-26 13:56:45 +02:00
Frank
a4cdd62aff Merge branch 'master' into FF/MasterDevel 2023-08-26 10:27:18 +02:00
Frank
45008c9d57 Update OpsGroup.lua 2023-08-26 10:26:11 +02:00
Frank
92b0ab3c8d Update OpsGroup.lua
- Storage transport
2023-08-25 22:15:50 +02:00
Frank
7074b70e86 Merge branch 'develop' into FF/Ops 2023-08-25 20:46:52 +02:00
Frank
e15d335f3f OPSTRANSPORT
- Storage
2023-08-25 20:46:42 +02:00
Frank
840b14f4ce OPSTRANSPORT
- Storage transport improved
2023-08-24 23:37:33 +02:00
Frank
887f7aa3e9 OPSTRANSPORT
- Storage
2023-08-23 23:37:23 +02:00
Thomas
a8daf70dad Update Set.lua Docu (#1995) (#1996)
* Update Set.lua Docu

Added regex explanation

* Update Set.lua
2023-08-23 11:43:37 +02:00
Thomas
9a9de9306e Update Set.lua Docu (#1995)
* Update Set.lua Docu

Added regex explanation

* Update Set.lua
2023-08-23 11:39:45 +02:00
Applevangelist
3e36e5f2b2 #Controllable
* Added Aerobtics tasks
2023-08-22 10:25:26 +02:00
Applevangelist
cf824b912d #Controllable
* Added Aerobtics tasks
2023-08-22 10:24:40 +02:00
Frank
c3f5405288 OPSTRANSPORT
Storage
2023-08-22 01:41:34 +02:00
Thomas
084b47edb7 ENUMS error (#1993)
* Storages Enum

* Update Enums.lua

Error in ENUM
2023-08-21 11:36:15 +02:00
Thomas
8d2e291deb Update Enums.lua
Error in ENUM
2023-08-21 11:35:01 +02:00
Frank
f84e2ede66 OPSTRANSPORT
Storage
2023-08-21 01:02:04 +02:00
Applevangelist
0a8782c890 Storages enum 2023-08-20 15:23:09 +02:00
Applevangelist
3a432782b2 Storages Enum 2023-08-20 15:22:49 +02:00
Applevangelist
5dd32d92c0 Merge remote-tracking branch 'origin/master' into develop 2023-08-20 15:13:18 +02:00
Applevangelist
d96cc26cd8 ENUMS.Storage.weapons 2023-08-20 15:12:59 +02:00
Applevangelist
bda1fac923 #ENUMS
* Added enumerator for ENUMS.Storage.weapons
2023-08-20 15:12:47 +02:00
Applevangelist
be5c1bed3b #PLAYERRECCE
* QoL Fixes for menu, smoke, reports etc
2023-08-20 14:18:43 +02:00
Thomas
ef40b1c524 Range fix for #1984 (#1992)
Range fix for #1984
2023-08-20 13:41:20 +02:00
Frank
a4c81736aa Update DCS.lua 2023-08-20 11:57:37 +02:00
Applevangelist
2eafadcedf Merge remote-tracking branch 'origin/master' into develop 2023-08-20 11:19:24 +02:00
Applevangelist
045c49679d #ATIS
* Fix explicitly set RWY not reported via SRS
2023-08-20 11:18:58 +02:00
Applevangelist
6b4c08d53f Merge remote-tracking branch 'origin/master' into develop 2023-08-18 11:08:47 +02:00
Applevangelist
f40442d309 #POSITIONABLE
* Make cargo weights an enumerator
2023-08-18 11:07:43 +02:00
ttrebuchon
83bae9c2f7 Make default cargo bay capacity values configurable (#1989)
* Add POSITIONABLE.CargoBayCapacityValues for manual configuration of cargo capacities.

* Add comment documenting local variable

* Remove extraneous semicolon

* Update Positionable.lua

Updated a bit plus documentation and working enumerator

---------

Co-authored-by: Thomas <72444570+Applevangelist@users.noreply.github.com>
2023-08-18 11:01:38 +02:00
Frank
944ef6332b Merge branch 'develop' into FF/Ops 2023-08-17 19:14:23 +02:00
Frank
1329cd23fd Merge branch 'master' into develop 2023-08-17 19:13:47 +02:00
Frank
fe7acecdd3 Merge pull request #1991 from FlightControl-Master/FF/MasterDevel
STORAGE - DCS Warehouse
2023-08-17 19:11:01 +02:00
Frank
4471ec9b96 DCS Warehouse 2023-08-17 18:46:09 +02:00
Frank
32e1d4f8fa DCS Warehouse 2023-08-16 23:58:32 +02:00
Frank
dbd78f35a4 Merge pull request #1987 from ttrebuchon/tt/misc-bug-fixes
Misc Bug Fixes
2023-08-13 22:57:06 +02:00
ttrebuchon
a2772c97d5 Merge branch 'develop' into tt/misc-bug-fixes 2023-08-13 15:34:40 -04:00
ttrebuchon
4f8e65b515 Merge branch 'tt/warehouse-asset-size-fix' into tt/misc-bug-fixes 2023-08-13 15:27:29 -04:00
ttrebuchon
1d6437f9e2 Merge branch 'tt/commander-incorrect-argument-ordering' into tt/misc-bug-fixes 2023-08-13 15:27:25 -04:00
ttrebuchon
a733b17840 Merge branch 'tt/auftrag-UpdateMarker-null-ref-check' into tt/misc-bug-fixes 2023-08-13 15:27:16 -04:00
ttrebuchon
3adf6d635a Handle OPSGROUP:MarkWaypoints() when waypoint altitude is nil 2023-08-13 15:22:05 -04:00
ttrebuchon
2e9320df03 Add check for whether targetcoord is nil in UpdateMarker() call 2023-08-13 15:18:09 -04:00
ttrebuchon
d08219f9d9 Add missing "Mission.escortMissionType" argument to call to AssignAssetsForEscort 2023-08-13 15:16:46 -04:00
ttrebuchon
f929951dbe Fix WAREHOUSE.AssetItem size calculation 2023-08-13 15:12:51 -04:00
Frank
76a36cb9f9 Merge branch 'develop' into FF/Ops 2023-08-13 18:20:23 +02:00
Frank
56aebfbee8 Merge branch 'master' into develop 2023-08-13 18:20:09 +02:00
Frank
747e5d801a Merge pull request #1986 from FlightControl-Master/FF/MasterDevel
COORDINATE
2023-08-13 18:19:16 +02:00
Frank
29ed630536 COORDINATE
- Generalized MarkupToAllFreeForm

UTILS
- Added some functions from MIST
2023-08-13 17:40:28 +02:00
Applevangelist
ffdcfa0129 Merge remote-tracking branch 'origin/master' into develop 2023-08-02 18:03:03 +02:00
Applevangelist
c5757ffd22 #CONTROLLABLE
* Added EnRouteTaskCAP()
2023-08-02 18:02:34 +02:00
Applevangelist
9cc08cb088 # 2023-08-01 16:26:29 +02:00
Applevangelist
268b7ef80c Merge remote-tracking branch 'origin/develop' into develop
# Conflicts:
#	Moose Development/Moose/Wrapper/Scenery.lua
2023-08-01 16:26:14 +02:00
Applevangelist
172004b822 Merge remote-tracking branch 'origin/master' into develop 2023-08-01 16:19:33 +02:00
Applevangelist
6aa4683080 #PLAYERTASK 2023-08-01 16:19:03 +02:00
Applevangelist
2771e7f856 #SCENERY, SET_SCENERY
* Reworked COORDINATE scan as this doesn't seem to work
* Added SET_SCENERY Filters, and FilterOnce() to apply them
2023-08-01 16:18:23 +02:00
Thomas
7c4dd8160d Update Set.lua (#1982)
Intellisense updates
2023-08-01 11:53:00 +02:00
Thomas
677a64c3dc Update Scenery.lua (#1980) (#1981)
_id might be nil in :FindByZoneName()
2023-08-01 10:38:39 +02:00
Thomas
1fdc50b0da Update Scenery.lua (#1980)
_id might be nil in :FindByZoneName()
2023-08-01 10:00:42 +02:00
phr0gz
56fcd8f37f Add RemoveGciCapZone in Chief (#1973)
This will add the ability to remove CGI CAP zone from chief.
2023-08-01 10:00:17 +02:00
Thomas
09d4e155de Update PlayerTask.lua (#1977)
Prevent Events being available before the menu structure has been created
2023-07-31 14:24:47 +02:00
Applevangelist
65703d1092 Debugs 2023-07-29 17:19:51 +02:00
Applevangelist
2afd09b878 Merge remote-tracking branch 'origin/master' into develop 2023-07-29 16:48:08 +02:00
Thomas
f87a676e4b Update Scoring.lua (#1976)
Add report Spaces
2023-07-29 16:45:00 +02:00
Applevangelist
4ed2b0610d #AWACS
* ensure tactical frequencies are handed back

#PlayerTask
* Add'l check for stale tasks to rebuild menu
2023-07-29 16:44:25 +02:00
phr0gz
cbd371b40f Chief zone removal Tanker, AWACS (#1975)
Add the ability to remove a zone for Tanker and AWACS.
2023-07-29 15:44:13 +02:00
phr0gz
80e9cb692c Add FSM OnAfter and OnBefore (#1974)
Add FSM Function OnAfter and OnBefore in FlightGroup.
2023-07-29 13:37:07 +02:00
Frank
3c74aef378 Merge branch 'master' into develop 2023-07-26 17:23:34 +02:00
Frank
8bf56b8b1a Update Airboss.lua
- Fixed AI handling (got lost in some merge with develop branch and was using FLIGHTGROUPS)
2023-07-26 16:36:44 +02:00
Frank
7e2233d8c7 Merge branch 'develop' into FF/Ops 2023-07-26 16:11:27 +02:00
Thomas
065717b2f5 Update FlightGroup.lua
coord might be nil in GetParking(airbase)
2023-07-26 15:36:09 +02:00
Applevangelist
63a524f25c #AWACS
* Remove tactical subscription when client logs out or dies
2023-07-26 07:49:35 +02:00
Applevangelist
838e11de05 #AWACS
* Added tactical radio option
2023-07-25 14:50:29 +02:00
Applevangelist
2a56da4bb3 Merge remote-tracking branch 'origin/master' into develop 2023-07-25 12:01:48 +02:00
Applevangelist
f31741f934 #AI_ESCORT
* Improve documentation
2023-07-25 12:01:18 +02:00
Applevangelist
f84d02d8a1 Merge remote-tracking branch 'origin/master' into develop 2023-07-23 12:42:59 +02:00
Applevangelist
7d3a08cde2 #CLIENTMENU, #PLAYERTASK
* Fixes for "No current task" not being deleted later on
2023-07-23 12:42:36 +02:00
Applevangelist
46258492bd #AIRBASE, #ATIS
* Additions
2023-07-23 12:37:57 +02:00
Frank
a7857670d3 Merge branch 'develop' into FF/Ops 2023-07-22 10:16:40 +02:00
Frank
c41b256775 Update SRS.lua 2023-07-22 10:16:31 +02:00
Applevangelist
e2929a78c4 #AICSAR - correct code version 2023-07-19 16:06:44 +02:00
Applevangelist
15bf379cdc #AICSAR
* Added FSM Event "HeloOnDuty"
2023-07-19 09:56:27 +02:00
Applevangelist
8a8e40e810 #PLAYERTASK
* Refactored menubuilds to use new CLIENTMENU/CLIENTMENUCONTROLLER classes
2023-07-17 16:27:54 +02:00
Applevangelist
2c8adf58cb #CLIENTMENU
* Rewrite with a different data approach
2023-07-17 16:26:53 +02:00
Applevangelist
bb579fff5b Merge remote-tracking branch 'origin/master' into develop 2023-07-16 11:28:24 +02:00
Applevangelist
6481f66e27 #MANTIS
* Added IDs for Current Hill Assets, keyword "CHM" for group names
2023-07-16 11:27:34 +02:00
Thomas
1ad538ea9f Commits from master (#1972)
* #SPAWN

* Update Spot.lua

Fix
2023-07-15 09:46:55 +02:00
Thomas
5954b8692f Update Spot.lua
Fix
2023-07-15 09:36:24 +02:00
Applevangelist
f6fdecf892 Merge remote-tracking branch 'origin/master' 2023-07-13 16:15:11 +02:00
Applevangelist
53fb77b50d #SPAWN 2023-07-13 16:15:06 +02:00
Applevangelist
191f7a7377 Merge remote-tracking branch 'origin/master' into develop 2023-07-13 16:13:26 +02:00
Applevangelist
04a9dc3a8c #SPAWN
* Added method to init spawn position
2023-07-13 16:13:00 +02:00
Applevangelist
77d2804fce Merge remote-tracking branch 'origin/master' into develop 2023-07-12 17:55:07 +02:00
Applevangelist
10b9a32f29 #SPOT
* Fix for switching laser off and on again not follwing unit any more
2023-07-12 17:54:17 +02:00
Applevangelist
63ba50a83a #CLIENTMENUMANAGER Docu 2023-07-11 16:10:40 +02:00
Applevangelist
fb8f804af2 # CLIENTMENU
* Initial release
2023-07-11 15:41:06 +02:00
Applevangelist
ffbab7453c Merge remote-tracking branch 'origin/master' into develop 2023-07-07 15:15:09 +02:00
Applevangelist
40fa929eb0 * Added omissed DetectedItem.Name found by @Nocke 2023-07-07 15:14:33 +02:00
Applevangelist
10872918bb #AUFTRAG
* Added GROUNDESCORT from the DCS Task with same name
2023-07-03 17:29:06 +02:00
Applevangelist
8979097fd7 Merge remote-tracking branch 'origin/master' into develop 2023-07-03 17:06:47 +02:00
Applevangelist
71b2cc1ee5 #AMMOTRUCK
* Added TTL
2023-07-03 17:06:31 +02:00
Applevangelist
8c8ef19f01 #CONTROLLABLE
* Added TaskGroundEscort
2023-07-03 16:44:46 +02:00
Applevangelist
389d5c7e5b Merge remote-tracking branch 'origin/master' into develop 2023-07-01 13:17:19 +02:00
Applevangelist
1eaa3d309d #SCORING
* typo
2023-07-01 13:15:59 +02:00
Applevangelist
178005346d Merge remote-tracking branch 'origin/master' into develop 2023-07-01 13:12:54 +02:00
Applevangelist
a52cd5612a Merge remote-tracking branch 'origin/master' 2023-07-01 13:12:29 +02:00
Applevangelist
041c21a883 Merge remote-tracking branch 'origin/master' into develop 2023-07-01 13:12:03 +02:00
Applevangelist
e82ed762be Merge remote-tracking branch 'origin/master' 2023-07-01 13:11:46 +02:00
Applevangelist
0bb16ec827 #AIRBASE
* Fix for nil error in finding parking for a group

#MANTIS
* Added SAM type "SHORAD" as designator

#SCORING
* fix for non local problem

#UTILS
* fix for OneLineSerialize
2023-07-01 13:11:21 +02:00
Applevangelist
fd946e971a #AWACS
* Bugfixes
2023-07-01 13:08:27 +02:00
Thomas
0dab316514 Point - BRAANATO (#1969) (#1970)
corrected Track to be direction of travel of bogey (self in this case)
2023-06-26 13:29:34 +02:00
Thomas
a978420a67 Point - BRAANATO (#1969)
corrected Track to be direction of travel of bogey (self in this case)
2023-06-26 13:25:23 +02:00
Applevangelist
248228720e Merge remote-tracking branch 'origin/master' into develop 2023-06-24 14:04:32 +02:00
Applevangelist
f59326bf10 #ATIS
* Fix for airbases which have no runways, e.g. Naqoura Syria
2023-06-24 14:03:43 +02:00
Applevangelist
e9c1b6d268 Merge remote-tracking branch 'origin/master' into develop 2023-06-22 13:52:19 +02:00
Thomas
08be2d6e93 CTLD (#1967) (#1968)
* Added option for troops subcategories in menu
2023-06-22 13:49:21 +02:00
Thomas
d937ab2679 CTLD (#1967)
* Added option for troops subcategories in menu
2023-06-22 13:46:11 +02:00
Applevangelist
ac386d5ebe #AIRBOSS
* Bug fix
2023-06-22 09:34:02 +02:00
Frank
74c1e9d991 Merge branch 'develop' into FF/Ops 2023-06-21 22:00:14 +02:00
Frank
0e72717cdb OPSGROUP
Track
2023-06-21 22:00:04 +02:00
Applevangelist
1df525b9c5 #NAVY
* Min speed 4kn due to rudder effectiveness
2023-06-21 14:05:17 +02:00
Applevangelist
cdbbad809a Merge remote-tracking branch 'origin/master' into develop 2023-06-21 10:43:40 +02:00
Applevangelist
7164e211f2 #AIRBASE
- Nicosia unused atm
2023-06-21 10:42:35 +02:00
Applevangelist
970275e96e #AIRBOSS
* Added adjustment degrees for wind speed
2023-06-21 10:25:00 +02:00
Applevangelist
5456cd04c3 #PLAYERTASKCONTROLLER
* Menu build lock
2023-06-18 13:29:07 +02:00
Applevangelist
1cdbe55cdd Merge remote-tracking branch 'origin/develop' into develop 2023-06-18 12:19:37 +02:00
Applevangelist
0577e5171b #AIRBOSS
* SRS: Remove lines starting with # from being spelled out
2023-06-18 12:19:28 +02:00
Frank
97376320f4 Merge pull request #1965 from ttrebuchon/tt/ops-auftrag-transport-attributes-and-properties
AUFTRAG Transport Attributes, Categories, and Properties Filters
2023-06-18 01:08:10 +02:00
ttrebuchon
9c1acc731a Make Attributes parameter documentation conform to other similar descriptions 2023-06-17 17:32:49 -04:00
ttrebuchon
92f81614ba Update/fix lua docs for new AUFTRAG transport fields 2023-06-17 17:09:50 -04:00
ttrebuchon
2a11c4c98a Rename AUFTRAG.transportCategories/etc to carrierCategories/etc 2023-06-17 17:07:56 -04:00
ttrebuchon
e284773492 Move transport categories/etc to SetRequiredCarriers, to allow for specifying them without always needing to specify zones 2023-06-17 17:06:16 -04:00
ttrebuchon
b3d46618c2 Missed 2 spots in Legion/Commander for transport filters. 2023-06-17 16:56:46 -04:00
ttrebuchon
4e36e2011f Add categories/attributes/properties filters for AUFTRAG transports 2023-06-17 15:35:11 -04:00
Applevangelist
a3876c296e #AIRBOSS
* Added option to set Airboss voice for SRS etc
* Nicer read out of weather info and carrier info
2023-06-17 15:01:33 +02:00
Applevangelist
c80213b4cf #AIRBOSS
* Initial SRS addition
2023-06-16 18:18:18 +02:00
Applevangelist
bfe7bf1af5 Merge remote-tracking branch 'origin/master' into develop
# Conflicts:
#	Moose Development/Moose/Wrapper/Positionable.lua
#	Moose Development/Moose/Wrapper/Unit.lua
2023-06-16 11:11:37 +02:00
Applevangelist
dae78d7ac1 #Positionable, Unit - remove pcall 2023-06-16 11:06:46 +02:00
Frank
f28d92e865 Merge pull request #1963 from FlightControl-Master/FF/Ops
OPS
2023-06-15 19:15:34 +02:00
Frank
bffb3e7778 OPS
UNIT and POSITIONABLE
- Removed pcall for GetVec3 and GetAmmo

CHIEF
- Deploy resources if zone is empty and owned by itself
2023-06-15 19:12:26 +02:00
Applevangelist
d4c2de9dd1 Merge remote-tracking branch 'origin/develop' into develop 2023-06-15 14:52:09 +02:00
Applevangelist
ab5425bd83 Merge remote-tracking branch 'origin/master' into develop 2023-06-15 14:52:02 +02:00
Applevangelist
254468c723 #NET
* Improvements
2023-06-15 14:51:36 +02:00
Applevangelist
aec3eee3a5 #NET
* Slight improvements
2023-06-15 14:50:11 +02:00
Frank
eec7e5f8d9 Merge branch 'develop' into FF/Ops 2023-06-15 01:25:10 +02:00
Frank
a9b51cca93 Update Auftrag.lua 2023-06-15 01:24:59 +02:00
Frank
14ddba69b0 Merge pull request #1962 from ttrebuchon/tt/ops-chief-RecruitAssetsForZone-nmin-nmax-typo-fix
Fix typo (Nmax -> Nmin) in CHIEF:RecruitAssetsForZone
2023-06-15 00:39:45 +02:00
ttrebuchon
a7806deb76 Recruit assets using resource Nmin and Nmax, rather than Nmax and Nmax. 2023-06-14 12:41:05 -04:00
Applevangelist
0cf35b664f Merge remote-tracking branch 'origin/master' into develop 2023-06-14 17:41:13 +02:00
Applevangelist
71be4d99d6 #POSITIONABLE:GetRelativeCoordinate( x, y, z ) 2023-06-14 17:40:33 +02:00
Frank
c3ffffbb52 Merge branch 'master' into develop 2023-06-13 21:53:29 +02:00
Frank
f86fc845e7 Update Timer.lua
- Timer stop is using protected call now because it can crash the whole script.
2023-06-13 21:53:19 +02:00
Frank
d96a55d83c Merge pull request #1961 from ttrebuchon/tt/flightgroup-getparkingspot-ship-fix
FLIGHTGROUP:GetParkingSpot Carrier Issue Fix
2023-06-13 19:09:42 +02:00
ttrebuchon
83353d710d Use GetRelativeCoordinate in FLIGHTGROUP:GetParkingSpot 2023-06-13 13:04:24 -04:00
Frank
9a4c09d249 Merge branch 'master' into develop 2023-06-13 19:03:11 +02:00
Frank
cc907b9c14 Update Unit.lua
- UNIT:IsAlive() fixed so it is consistent with GROUP:IsAlive()
2023-06-13 19:02:55 +02:00
ttrebuchon
c825191556 Add POSITIONABLE:GetRelativeCoordinate 2023-06-13 12:54:38 -04:00
Applevangelist
27e85e921f Merge remote-tracking branch 'origin/develop' into develop 2023-06-13 18:00:18 +02:00
Applevangelist
c120a48879 #UNIT
* Test to not return a stored DCS Object if the API doesn't think it's still there
2023-06-13 18:00:15 +02:00
Frank
4a03074571 Merge branch 'develop' of https://github.com/FlightControl-Master/MOOSE into develop 2023-06-13 16:02:00 +02:00
Frank
8855b117a8 Update OpsGroup.lua
- exists check for ammo and vec3
2023-06-13 16:01:47 +02:00
Applevangelist
2cedb5e996 Merge remote-tracking branch 'origin/master' into develop 2023-06-13 08:40:21 +02:00
Applevangelist
241b2beee1 * Makes calls for GetAmmo() and GetVec3() safer with pcall()
* Small docu fix Ben-Gurion
2023-06-13 08:39:56 +02:00
Frank
0af68cd780 Merge branch 'master' into develop 2023-06-12 23:01:36 +02:00
Frank
12f260e857 Update Unit.lua
- Added `UNIT:IsExist` function.
2023-06-12 23:01:19 +02:00
Thomas
6a58748cd1 Airbase (#1954)
* #UTILS
* Sinai TIme

* fix

* Update Airbase.lua

Corrected enumerator for Ben-Gurion (Ben_Gurion)

* Update Airbase.lua (#1957)

Deleted raj al … airbases #1955
2023-06-12 06:27:52 +02:00
Thomas
096d145cf9 Update Airbase.lua (#1957)
Deleted raj al … airbases #1955
2023-06-12 06:22:51 +02:00
Frank
d31db1351a Merge pull request #1956 from FlightControl-Master/FF/Ops
AUFTRAG
2023-06-11 22:52:28 +02:00
Frank
0f33603ecc AUFTRAG
- Changed ingress waypoint of CASENHANCED
2023-06-11 22:45:59 +02:00
Thomas
b3883301a2 Update Airbase.lua
Corrected enumerator for Ben-Gurion (Ben_Gurion)
2023-06-11 12:33:01 +02:00
Frank
3bbd55cfc2 Merge pull request #1953 from ttrebuchon/tt/fix-opsgroup-getlifepoints-typo
Set life0 based on itself, rather than off of life
2023-06-11 00:52:13 +02:00
ttrebuchon
163273096c Set life0 based on itself, rather than off of life 2023-06-10 18:08:29 -04:00
Applevangelist
3a7521c492 #UTILS
* Sinai TIme
2023-06-10 19:08:46 +02:00
Applevangelist
caa5a96235 fix 2023-06-10 19:06:22 +02:00
Applevangelist
cee1c592ba #UTILS
* Sinai TIme
2023-06-10 19:04:40 +02:00
Frank
6d1030925c Merge branch 'master' into develop 2023-06-10 10:08:35 +02:00
Frank
f1fc9f0b27 Update Utils.lua
- Added parameters time zone and magvar for Sinai map
2023-06-10 10:08:22 +02:00
Applevangelist
dabe8a58d1 Merge remote-tracking branch 'origin/develop' into develop 2023-06-09 15:16:41 +02:00
Applevangelist
16cf6693ab Merge remote-tracking branch 'origin/master' into develop 2023-06-09 15:16:38 +02:00
Applevangelist
e9adcb0dd5 #AIRBASE
* Sinai airfield enumerator
2023-06-09 15:13:45 +02:00
Applevangelist
fd51ec6932 #FIX 2023-06-09 13:25:29 +02:00
Frank
7a16a5dda8 Merge pull request #1952 from FlightControl-Master/FF/Ops
OPS
2023-06-08 19:55:30 +02:00
Frank
1b6648996c OPSGROUP
- Improved CAPTUREZONE for FLIGHTGROUP
2023-06-08 19:51:09 +02:00
Frank
f45a22fe78 Merge branch 'develop' into FF/Ops 2023-06-08 15:52:25 +02:00
Applevangelist
afe2b675e5 #RAT
* Fixes from dev
2023-06-08 13:59:59 +02:00
Applevangelist
2c14ee74b0 #SCORING
* Can leave text empty on some instances
2023-06-08 13:58:26 +02:00
Applevangelist
4314959cbb Merge remote-tracking branch 'origin/develop' into develop 2023-06-08 13:57:03 +02:00
Applevangelist
fad85ef7ed #PLAYERTASK
* Added basic scoring
2023-06-08 13:56:59 +02:00
Frank
569b3df6af Merge branch 'master' into develop 2023-06-08 09:46:24 +02:00
Frank
f351d2a37e Merge pull request #1951 from FlightControl-Master/FF/MasterDevel
Update RAT.lua
2023-06-08 09:45:49 +02:00
Frank
4cb0e70184 Update RAT.lua
- Fixed RATMANAGER spamming due to not accounting for planned/scheduled groups
2023-06-08 09:43:11 +02:00
Applevangelist
910da86caf Merge remote-tracking branch 'origin/develop' into develop 2023-06-07 17:25:49 +02:00
ttrebuchon
73ff2c576d Fix typo from TRANSPORT. to OPSTRANSPORT. (#1950) 2023-06-07 17:26:20 +02:00
Applevangelist
d5ffb48548 #PLAYERTASK
* Fix for one tts output
2023-06-07 17:25:45 +02:00
Frank
8ce371f898 WAREHOUSE
- Runway destroyed event only triggered if it was operational
2023-06-07 09:03:01 +02:00
Thomas
6f02f23240 PlayerTask.lua (#1948)
Small fix for one tts text
2023-06-06 16:20:16 +02:00
ttrebuchon
0a1d469c68 Fix Offset values being saved to the ZONE_UNIT class itself (#1947) 2023-06-03 20:15:33 +02:00
Applevangelist
823f8fb4fb Merge remote-tracking branch 'origin/master' into develop 2023-06-03 12:35:05 +02:00
Applevangelist
41bb2551d3 #CTLD
* Ensure new menus can be build if player changes helos
2023-06-03 12:34:18 +02:00
Applevangelist
f7e64bc9b5 #UNIT #CTLD
* Stabilize that sometimes a unit coordinate cannot be found
2023-06-02 08:45:35 +02:00
Applevangelist
55ed394782 #UNIT #CTLD
* Stabilize that sometimes a unit coordinate cannot be found
2023-06-02 08:44:14 +02:00
Applevangelist
261f79851c Merge remote-tracking branch 'origin/master' into develop 2023-06-01 10:03:34 +02:00
Applevangelist
dd7a883a33 Fixes 2023-06-01 10:02:51 +02:00
Applevangelist
6773ac7841 #PLAYERTASK
* Added FSM event "Progress" that will be triggered if the targetcount goes down for a task, but is not yet zero. This will bubble up to PLAYERTASKCONTROLLER

#PLAYERTASKCONTROLLER
* Added FSM event"TaskProgess" (see above). The event function will recveive the PLAYERTASK and the current target count
* Changed the menu build strategy to ensure a lot less menu rebuilds. Menus are now only build if
	* A new player joins (for the joining single player)
	* On joining a task (for the joining single player)
	* When aborting a task (for the aborting single player)
	* On Task succes (for all players)
	* Removal of time based builds: The status loop will now only enforce the menu build if the task count in the queue is smaller than the menu item limit. This effectively enforces a time-based order of tasks, and newer, even higher prio task will not bubble into the task list of pilots automatically.
2023-05-30 12:06:03 +02:00
Applevangelist
39f29b066b Merge remote-tracking branch 'origin/master' into develop 2023-05-30 07:38:48 +02:00
Applevangelist
f7acbc3928 #CSAR
* Corrected flare distance to kms
2023-05-30 07:38:19 +02:00
Applevangelist
246879c003 Merge remote-tracking branch 'origin/master' into develop 2023-05-28 15:28:37 +02:00
Applevangelist
2318578126 #SPAWN
* Logic fix for the last parameter of `NewFromTemplate()`
2023-05-28 15:27:34 +02:00
Frank
709621967d Merge pull request #1945 from FlightControl-Master/FF/Ops
OPSTRANSPORT
2023-05-27 14:38:30 +02:00
Frank
0c376aec63 OPSTRANSPORT
Fixed loaded not correctly checked in OPSGROUP
2023-05-27 14:28:53 +02:00
Frank
725efc3e70 Merge pull request #1944 from FlightControl-Master/FF/Ops
AUFTRAG
2023-05-26 11:42:26 +02:00
Frank
81abe422de Merge branch 'develop' into FF/Ops 2023-05-26 11:38:26 +02:00
Frank
fb202012da AUFTRAG
Reinforcing
- improved check if reinforcing is still ongoing
- improved handling by commander/chief
- added check that assets are not added to a mission twice
2023-05-26 11:37:19 +02:00
Applevangelist
89223ae142 Merge remote-tracking branch 'origin/master' into develop 2023-05-26 08:28:45 +02:00
Applevangelist
2967de8f6e #CONTROLLER
* Fix for Link4
2023-05-25 08:57:54 +02:00
Applevangelist
9c5260f801 Merge remote-tracking branch 'origin/develop' into develop 2023-05-25 08:24:35 +02:00
Applevangelist
4d9ce80c98 Merge remote-tracking branch 'origin/master' into develop 2023-05-25 08:24:16 +02:00
Frank
ee055531b6 Merge branch 'master' into develop 2023-05-24 11:16:36 +02:00
Frank
c9b90e884d Merge pull request #1943 from FlightControl-Master/FF/Ops
OPS
2023-05-23 01:46:51 +02:00
Frank
21db80afad Merge branch 'develop' into FF/Ops 2023-05-23 01:29:04 +02:00
Frank
d9d5458450 OPS
**AUFTRAG**
- New type `FAC`

**OPSZONE**
- Improved drawzone on capture
2023-05-23 01:28:52 +02:00
Applevangelist
0575b366dd #SPAWN
* Tweaked NewFromTemplate, and gave a better example
2023-05-22 17:57:50 +02:00
Applevangelist
034b2444ff Merge remote-tracking branch 'origin/master' into develop 2023-05-20 12:13:35 +02:00
Applevangelist
7901d53d54 #POINT
* Added FindClosestStatic()
2023-05-19 17:13:17 +02:00
Applevangelist
88f34e5bb0 Merge remote-tracking branch 'origin/master' into develop 2023-05-17 10:28:11 +02:00
Applevangelist
49f3e3fc2f Merge remote-tracking branch 'origin/develop' into develop 2023-05-17 09:41:32 +02:00
Applevangelist
cae084a352 Merge remote-tracking branch 'origin/master' into develop 2023-05-17 09:41:27 +02:00
Frank
6d07f7c48c Merge branch 'develop' into FF/Ops 2023-05-13 23:36:36 +02:00
Frank
014fea5f10 Merge branch 'master' into develop 2023-05-13 23:36:12 +02:00
Frank
d07709a167 Update Auftrag.lua 2023-05-13 23:06:56 +02:00
Frank
ac4db4a392 Merge branch 'develop' into FF/Ops 2023-05-13 17:57:23 +02:00
Applevangelist
b30cdd073b Merge remote-tracking branch 'origin/master' into develop 2023-05-11 18:23:01 +02:00
Applevangelist
a12e93c7cb Merge remote-tracking branch 'origin/master' into develop 2023-05-09 09:49:47 +02:00
Applevangelist
bd01946f88 #AI_A2X...
* Fixes
2023-05-09 09:49:13 +02:00
Applevangelist
8d25bdec7c Merge remote-tracking branch 'origin/master' into develop 2023-05-05 10:33:55 +02:00
Applevangelist
8da228c9a2 #COORDINATE
* Added `IsInSteepArea()`and `IsInFlatArea()`
2023-05-05 10:31:00 +02:00
Applevangelist
74abcce956 Merge remote-tracking branch 'origin/develop' into develop 2023-04-27 10:34:21 +02:00
Applevangelist
2032c2cfbf # AUFTRAG
* Bring options for afterburner usage down to AUFTRAG level

# OpsGroup (Flightgroup)
* Follow setting option for AB usage from mission, if set, generally and for execution phase of the AUFTRAG
2023-04-27 10:34:17 +02:00
Frank
fb070a0c86 Merge branch 'develop' into FF/Ops 2023-04-25 21:54:04 +02:00
Frank
817c69bb11 Merge branch 'master' into develop 2023-04-25 21:53:39 +02:00
Applevangelist
6cd56e4de4 Merge remote-tracking branch 'origin/master' into develop 2023-04-25 09:13:27 +02:00
Applevangelist
19a4ec48bb Merge remote-tracking branch 'origin/master' into develop 2023-04-24 16:45:31 +02:00
Thomas
c7d990850a AIRBASE - add Normandy AFBs (#1937) (#1938)
Add Normandy AFBs
2023-04-24 11:16:45 +02:00
Frank
885d3b5228 Merge branch 'develop' into FF/Ops 2023-04-22 14:29:18 +02:00
Frank
7379b8135a Merge branch 'master' into develop 2023-04-22 14:08:05 +02:00
Applevangelist
549c9b9ce5 #CTLD
* Docu changes
2023-04-20 08:22:31 +02:00
Applevangelist
f4080d93e8 #SET
- Minus one log entry
2023-04-20 08:06:57 +02:00
Applevangelist
94b74b7056 Merge remote-tracking branch 'origin/develop' into develop 2023-04-20 08:05:15 +02:00
Applevangelist
6886107934 #SET
* Active Zone Filtering
2023-04-20 08:05:11 +02:00
Thomas
f65783ed6c SET - added continous zone filtering (#1934)
SET - added continous zone filtering for SET_GROUP, SET_UNIT and SET_CLIENT. Adresses request #1933
2023-04-18 12:28:17 +02:00
Applevangelist
d8e765a9b1 Fixes for getPlayerName() errors if DCS object is not a UNIT 2023-04-18 10:28:00 +02:00
Frank
526f241dc3 Merge branch 'develop' into FF/Ops 2023-04-17 17:18:54 +02:00
Applevangelist
dffb1c0768 Merge remote-tracking branch 'origin/master' into develop 2023-04-16 16:11:12 +02:00
Frank
f30f32732c Merge branch 'master' into develop 2023-04-16 12:30:19 +02:00
Frank
9cd3027ea6 Update FlightGroup.lua 2023-04-16 11:16:54 +02:00
Applevangelist
b4c7b63381 #CTLD
* Small fix allowing minus signs in template names for repairs
2023-04-15 16:17:39 +02:00
Applevangelist
0782532763 Merge remote-tracking branch 'origin/master' into develop 2023-04-13 15:51:55 +02:00
Applevangelist
6fa9e5894e #DATABASE
* Small fix for CLIENT:FindByName()
2023-04-04 10:33:41 +02:00
Applevangelist
c0bc9b393c #NET
* Fix for ucid can be nil
2023-04-03 12:16:25 +02:00
Applevangelist
a97e844aca Added Init Methods to set Unit Positions on Spawn 2023-03-30 12:23:07 +02:00
Applevangelist
d2e91ffcd2 Small fix for SET_UNIT if used in capture zone coalition with a polygon zone 2023-03-30 09:24:48 +02:00
Applevangelist
d9eee7ea46 SET_STATIC - Added GetClosestStatic() 2023-03-28 11:03:34 +02:00
Applevangelist
b1e233421e Fix possible DCS Unit not existing in OPSGROUP:onafterElementDamaged(From, Event, To, Element) 2023-03-24 10:28:36 +01:00
Applevangelist
7157836eb1 Merge remote-tracking branch 'origin/master' into develop 2023-03-23 09:21:58 +01:00
Applevangelist
53fa850d66 Add'l check in UNIT:GetLife() 2023-03-23 08:46:29 +01:00
Applevangelist
033c52ae54 Merge remote-tracking branch 'origin/develop' into develop 2023-03-16 08:45:17 +01:00
Applevangelist
e08b44187e #AIRBASE
* Added/changed:
  ["Hipico_Flying_Club"] = "Hipico Flying Club",
  ["Aeropuerto_de_Gobernador_Gregores"] = "Aeropuerto de Gobernador Gregores",
  ["Aerodromo_O_Higgins"] = "Aerodromo O'Higgins",
  ["Cullen_Airport"] = "Cullen Airport",
  ["Gull_Point"] = "Gull Point",
2023-03-16 08:45:14 +01:00
Thomas
0d29c39724 Drop crates from herc as CTLD_Cargo (#1929) (#1930)
Adds option to drop crates from a herc via parachute drop as CTLD_Cargo that needs proper unpacking - can be picked up be a helo.

Co-authored-by: UglySkyfire <69476075+UglySkyfire@users.noreply.github.com>
2023-03-15 21:07:19 +01:00
Applevangelist
6946d8d185 Merge remote-tracking branch 'origin/master' into develop 2023-03-10 10:09:40 +01:00
Applevangelist
6ac1d66aae #GROUP
* Fix for GetMaxHeight()
2023-03-09 08:49:53 +01:00
Applevangelist
a67bae4f0d #UTILS
* Added UTILS.PlotRacetrack courtesy of Buur!
2023-03-07 10:55:42 +01:00
Applevangelist
4e7c689f7a Merge branch 'master' into develop 2023-03-05 11:04:22 +01:00
Anthony De Vellis
f73ff10edb Refactored GROUP:GetCustomCallSign so that bespoke callsigns override parsing player name and playername overrides vanilla callsigns. Previously Bespoke callsigns would never be used if names contained # or |. If CallsignTranslations is unset, previous priority will be applied. (#1927) 2023-03-05 11:01:37 +01:00
Applevangelist
949e2f9ff3 #SPAWN
* clarified docu for SpawnScheduled()
* Added parameter to SpawnScheduled() for a delayed spawn
2023-02-28 08:00:43 +01:00
Thomas
cb9ab26522 Update Enums.lua (#1925) 2023-02-26 19:06:45 +01:00
Frank
7aa4aaf371 Update Auftrag.lua
- Fixed wrong IAS to TAS convertion for orbit missions
2023-02-26 01:02:39 +01:00
Frank
901480d99c Merge branch 'FF/Ops' into develop 2023-02-24 23:29:32 +01:00
Frank
84dbda6f2b OPS
- Rm laser marker
2023-02-24 23:29:03 +01:00
Applevangelist
9d00ec0c25 Merge remote-tracking branch 'origin/master' into develop 2023-02-24 14:04:53 +01:00
Applevangelist
0d08d732a5 #AWACS - do not convert speed to IAS, as already done in AUFTRAG 2023-02-23 11:12:05 +01:00
Applevangelist
8c0f960e39 Merge remote-tracking branch 'origin/master' into develop 2023-02-23 10:32:38 +01:00
Frank
b0978b362e Merge pull request #1924 from FlightControl-Master/FF/Ops
OPS
2023-02-22 23:18:29 +01:00
Frank
ffef3183c7 OpsGroup
- Fixed bug in checklos
2023-02-22 23:01:47 +01:00
Frank
20a9857fcf Merge branch 'FF/OpsDev' into FF/Ops 2023-02-22 22:17:49 +01:00
Frank
828395c398 Merge branch 'develop' into FF/Ops 2023-02-22 22:17:35 +01:00
Frank
462e29da6e RANGE and OPS
** RANGE**
- Added scenery as target

**OPSGROUP**
- Added option that group does not return to its legion

**AUFTRAG**
- Added option that assets do not return to its legion
2023-02-22 22:16:42 +01:00
Applevangelist
29ebe94015 #CTLD logic correction for loading 2023-02-21 11:39:23 +01:00
Applevangelist
ce7b30b54e Merge remote-tracking branch 'origin/master' into develop 2023-02-19 17:16:34 +01:00
Applevangelist
feeb0c01f2 Merge remote-tracking branch 'origin/master' into develop 2023-02-19 12:32:29 +01:00
Applevangelist
bef8e53347 #AICSAR - added option to use eject event 2023-02-19 12:30:00 +01:00
Applevangelist
46c3ed72c3 Merge remote-tracking branch 'origin/master' into develop 2023-02-18 15:04:36 +01:00
Applevangelist
1fd8f4d837 #AICSAR
* Named functions for the events
2023-02-18 11:04:49 +01:00
Applevangelist
6f3fbb25cf Merge remote-tracking branch 'origin/master' into develop 2023-02-17 16:42:10 +01:00
Applevangelist
05b8df0d88 Merge remote-tracking branch 'origin/master' into develop 2023-02-17 16:24:21 +01:00
Applevangelist
a4dcb643bd #NET Fixes 2023-02-17 15:41:33 +01:00
Applevangelist
9e23cda02a #NET Fixes 2023-02-17 15:01:49 +01:00
Applevangelist
c29b67df55 #NET small fix 2023-02-17 14:33:32 +01:00
Applevangelist
bd312b86d2 Merge remote-tracking branch 'origin/master' into develop 2023-02-17 13:23:10 +01:00
Applevangelist
822b95e8aa Merge remote-tracking branch 'origin/master' into develop 2023-02-17 08:55:27 +01:00
Applevangelist
a7e45338e3 #AICSAR - Added alt/speed options 2023-02-17 08:54:54 +01:00
Applevangelist
7637f0c6ce Merge remote-tracking branch 'origin/develop' into develop 2023-02-16 18:22:10 +01:00
Applevangelist
6ec43b72ce #AICSAR
* Added PlayerName to `OnAfterPilotRescued(From,Event,To,PilotName)` if available
2023-02-16 18:22:06 +01:00
Frank
91e80bf1a6 Merge branch 'FF/Ops' into FF/OpsDev 2023-02-16 17:30:47 +01:00
Frank
e6464dc5cb Merge branch 'develop' into FF/Ops 2023-02-16 17:30:15 +01:00
Frank
34c799b668 Merge branch 'master' into develop 2023-02-16 17:29:54 +01:00
Applevangelist
dbd7634f0e #NET
* Added event management for clients and block/unblock functions
2023-02-16 11:42:46 +01:00
Frank
baa1dcbf8f OPSGROUP
- mission nothing is cancelled if transport is due
2023-02-15 23:06:34 +01:00
Applevangelist
660ebeadfe Merge remote-tracking branch 'origin/master' into develop 2023-02-15 12:24:09 +01:00
Applevangelist
ef0ddddb46 #PLAYERTASK
* added group/unit check for UseTypeNames
2023-02-15 10:32:30 +01:00
Applevangelist
77a39364f4 #PLAYERTASKCONTROLLER
* Added ship detail types
2023-02-14 12:58:23 +01:00
Frank
dc0a2bccd6 Update Legion.lua
- Increase score for nearby ground groups
2023-02-12 15:19:34 +01:00
Frank
ac1b458eb4 Merge branch 'FF/Ops' into FF/OpsDev 2023-02-12 13:53:47 +01:00
Frank
f5938bc235 Merge branch 'develop' into FF/Ops 2023-02-12 13:53:25 +01:00
Frank
7280c17506 Merge branch 'master' into develop 2023-02-12 13:04:32 +01:00
Frank
4e280f02b6 Merge branch 'FF/Ops' into FF/OpsDev 2023-02-12 11:53:42 +01:00
Frank
854f6ae6ae Merge branch 'develop' into FF/Ops 2023-02-12 11:52:13 +01:00
Frank
0487487e7c Merge branch 'master' into develop 2023-02-12 11:51:16 +01:00
Frank
9ec66912c8 Update OpsGroup.lua
- Added SetCargoBayLimit function
2023-02-12 09:36:35 +01:00
Thomas
960f261ddd Master merge (#1920)
* #NET
* Initial release

* Update MarkerOps_Base.lua (#1919)
2023-02-11 22:17:24 +01:00
Frank
e55f96f393 OPSTRANSPORT 2023-02-11 00:21:15 +01:00
Applevangelist
713a5b067f #PLAYERTASKCONTROLLER
* Added `AddAgentSet()`
2023-02-10 11:40:15 +01:00
Applevangelist
d6aa7ec17c #Net
* Initial Release
2023-02-10 10:45:23 +01:00
Applevangelist
2da2ddb5bb #DETECTION
* Docu fixes
2023-02-09 16:12:39 +01:00
Applevangelist
608033f38f #AICSAR
* Docu additions
2023-02-09 13:17:49 +01:00
Applevangelist
28c25816a6 #AICSAR
* Fixed issue with underlying OpsTransport
* Added FSM Transition OnAfterPilotUnloaded()
* Added options for SRS TTS output - no sound files
* Added voice options for downed pilot and operator - these can have different voices
2023-02-09 11:57:28 +01:00
Frank
709fccd96c OSPTRANSPORT 2023-02-09 01:06:36 +01:00
Frank
2c24e56aa5 Merge branch 'FF/MasterDevel' into FF/OpsDev 2023-02-08 16:35:49 +01:00
Frank
f104ddbe64 Merge branch 'FF/Ops' into FF/OpsDev 2023-02-08 16:15:22 +01:00
Frank
bbd8ceb8c0 Merge branch 'develop' into FF/Ops 2023-02-08 16:15:06 +01:00
Frank
b8498fa58f Merge branch 'FF/MasterDevel' into FF/OpsDev 2023-02-08 16:14:45 +01:00
Frank
34c26c44bc Merge branch 'develop' into FF/OpsDev 2023-02-07 22:53:19 +01:00
Applevangelist
c97f1791b0 Merge remote-tracking branch 'origin/master' into develop 2023-02-07 08:01:34 +01:00
Applevangelist
63b16e5bd4 Merge remote-tracking branch 'origin/master' into develop 2023-02-06 08:17:05 +01:00
dogjutsu
184f93168b MSRS_BACKEND_DCSGRPC bug fix (#1916)
* Add another DCS-gRPC example for MSRS docu (ATIS)

* Fixes MSRS_BACKEND_DCSGRPC bad _GetLatLongAlt call
2023-02-06 08:16:14 +01:00
Frank
0400f1a23e Merge branch 'FF/Ops' into FF/OpsDev 2023-02-05 00:23:42 +01:00
Frank
d3d60757c1 Merge branch 'develop' into FF/Ops 2023-02-05 00:23:25 +01:00
Frank
57079e5104 Merge branch 'master' into develop 2023-02-04 23:34:14 +01:00
Frank
6d967358da WEAPON v0.1.0
**WEAPON**
- Improments of class
- ARTY works
- FOX works
- RANGE should work, not tested.
2023-02-04 23:28:45 +01:00
Applevangelist
095121d83c Merge remote-tracking branch 'origin/develop' into develop 2023-02-04 21:51:39 +01:00
Applevangelist
a415b131c4 Merge remote-tracking branch 'origin/master' into develop 2023-02-04 21:51:35 +01:00
Thomas
54a1ea9f56 Scoring credits a kill to player who hit the same unit before it spawned (#1905) (#1907)
Co-authored-by: Mr.Alien <124381209+MrAlien753@users.noreply.github.com>
2023-02-04 21:50:17 +01:00
Applevangelist
23091ff851 #CTLD
* Added method `CTLD:PreloadCrates(Unit,Cratesname,NumberOfCrates)`
2023-02-04 17:21:52 +01:00
Applevangelist
5571b49b4f Merge remote-tracking branch 'origin/master' into develop 2023-02-04 17:16:10 +01:00
Frank
4b4708e2a8 Weapon 2023-02-02 23:50:00 +01:00
Applevangelist
789a4c4b7f Merge remote-tracking branch 'origin/develop' into develop 2023-02-02 09:47:29 +01:00
Applevangelist
3775053609 PLAYERRECCE - bug fix 2023-02-02 09:47:25 +01:00
Applevangelist
35da50b67a Merge remote-tracking branch 'origin/develop' into develop-2 2023-02-02 09:38:32 +01:00
Applevangelist
9be30338a5 Herc fix 2023-02-02 09:37:47 +01:00
Applevangelist
6510cca837 Merge remote-tracking branch 'origin/develop' into develop 2023-02-02 09:36:48 +01:00
Applevangelist
08b8dfbe0e Merge remote-tracking branch 'origin/master' into develop 2023-02-02 09:36:44 +01:00
Frank
9af242854a Weapon 2023-02-01 23:51:47 +01:00
Frank
bfe9a1888e Merge pull request #1899 from ttrebuchon/tt/airwing-sortpayloads-fix
Airwing sortpayloads criteria fix
2023-02-01 19:07:46 +01:00
ttrebuchon
fec496f154 Fix missing check for b.unlimited~=true in sortpayloads function. 2023-02-01 12:30:52 -05:00
Thomas
28fd35ad7e PlayerRecce - Added Shark_3 as type 2023-02-01 12:17:54 +01:00
Frank
c5deb09c2c WEAPON v0.0.1
- New class
2023-01-31 23:22:48 +01:00
Applevangelist
ee6d34a9bd #CTLD
* Added Subcategories for static cargo objects
2023-01-31 11:28:00 +01:00
Frank
6e6bb1e88d RANGE 2023-01-30 23:29:03 +01:00
Frank
0b3aea2bf3 Scenery 2023-01-30 21:52:22 +01:00
Applevangelist
f731ec7b2f #POINT
* Added COORDINATE:SetAtLandheight()
2023-01-30 18:01:04 +01:00
Applevangelist
5b8f840d6e Merge remote-tracking branch 'origin/master' into develop 2023-01-29 18:37:19 +01:00
Frank
694ad5d33d Merge branch 'develop' into FF/Ops 2023-01-29 12:57:09 +01:00
Frank
383ee00e71 Merge branch 'master' into develop 2023-01-29 12:54:13 +01:00
Frank
c279ab6311 Update Auftrag.lua 2023-01-29 12:19:04 +01:00
Frank
4cc1db1365 Update Auftrag.lua
- condition success and failure evaluation
2023-01-28 22:31:53 +01:00
Frank
f3d1378692 Merge branch 'master' into develop 2023-01-28 18:42:57 +01:00
Frank
cfb3004142 Merge pull request #1893 from FlightControl-Master/FF/Ops
OPS
2023-01-28 10:47:49 +01:00
Thomas
016643e494 Merge from. Master (#1892)
* #CSAR - Add Persistence (#1889)

* Adds a modified version of ops.CTLD's Persistence to ops.CSAR

* Update Marker.lua

* Changed documentation for Marker.lua and MarkerOps_Base.lua (#1891)

---------

Co-authored-by: Jason du Plessis <33880363+TheChosenOn3@users.noreply.github.com>
Co-authored-by: grandpaSam <wouldyukindly@gmail.com>
2023-01-28 09:05:23 +01:00
Thomas
5ec18d45a2 Merge (#1890)
* #CSAR - Add Persistence (#1889)

* Adds a modified version of ops.CTLD's Persistence to ops.CSAR

* Update Marker.lua

---------

Co-authored-by: Jason du Plessis <33880363+TheChosenOn3@users.noreply.github.com>
2023-01-27 18:36:38 +01:00
dogjutsu
f4c9bced45 Add another DCS-gRPC example for MSRS docu (ATIS) (#1883) 2023-01-26 11:25:01 +01:00
Applevangelist
e106ca3da5 * AIRBASE added airfields Falklands
* RANGE  added google key usage
2023-01-25 17:55:34 +01:00
Applevangelist
262c8ffc59 Merge remote-tracking branch 'origin/develop' into develop 2023-01-25 17:19:03 +01:00
Applevangelist
affde2f030 Merge remote-tracking branch 'origin/master' into develop 2023-01-25 17:18:59 +01:00
Thomas
a4982bd24e Update Utils.lua (#1886) (#1887) 2023-01-24 20:58:24 +01:00
Applevangelist
1099e8e876 #CTLD added documentation 2023-01-24 15:27:09 +01:00
Applevangelist
6a4356fa94 #1885
#PSEUDOATC - Menu shows Waypoint name if it has been set
2023-01-24 10:06:40 +01:00
Applevangelist
2ec8d94e38 #CONTROLLABLE
* Added CommandActivateACLS()
* Added CommandDeactivateACLS()
2023-01-23 17:12:01 +01:00
Applevangelist
24d47ef353 Merge remote-tracking branch 'origin/master' into develop 2023-01-22 13:11:13 +01:00
Frank
76ebf8df07 Merge branch 'develop' into FF/Ops 2023-01-21 22:43:11 +01:00
Frank
a4e52c6c3c Legion
- Added enroute task SEAD to escort
2023-01-21 22:42:57 +01:00
Applevangelist
285f8d102b #AUFTRAG
* Added checking of bespoke conditions within the status call of AUFTRAG and not only when AUFTRAG is done already
2023-01-21 15:39:44 +01:00
Frank
d0d21a6b5d Merge branch 'master' into develop 2023-01-19 19:11:09 +01:00
Applevangelist
ff58a47244 #FG - added nil check on GetClosestAirbase() 2023-01-19 17:01:59 +01:00
Applevangelist
6e666b0ac8 #UTILS - make LoadSetOfGroups save(r) for groups spawned with SpawnScheduled 2023-01-19 15:00:49 +01:00
Applevangelist
47684e8717 Merge remote-tracking branch 'origin/master' into develop 2023-01-19 10:35:02 +01:00
Applevangelist
0d0292385f #OPSGROUP - added docu 2023-01-19 10:33:26 +01:00
Applevangelist
83e20f8062 #Controllable - docu changes 2023-01-17 12:09:23 +01:00
Applevangelist
5943ae0a46 #ATIS docu fix 2023-01-17 09:25:58 +01:00
Applevangelist
56c4a11626 #CSAR
* Docu corrections
2023-01-15 17:39:28 +01:00
Applevangelist
f0f42df374 #CTLD - Adde Shark III typename 2023-01-12 13:20:44 +01:00
Applevangelist
5898bc7f07 #PLAYERTASK
* Even nicer MGRS readouts
2023-01-10 17:09:17 +01:00
Applevangelist
0d8b94c7fd #AIRBASE - docu fixes 2023-01-10 13:09:25 +01:00
Applevangelist
0fa4be7c4a #AWACS
* Fixed initial screen text on bogey dope just being x group(s)
#PLAYERTASK
* Improved logic to declare task succes even if not player is assigned
2023-01-10 12:45:17 +01:00
Applevangelist
a7bad8e9f4 #PSEUDOATC
* Fix for debug messages
2023-01-10 07:49:02 +01:00
Frank
40276d190a Merge pull request #1882 from FlightControl-Master/FF/Ops
OPSZONE
2023-01-09 23:12:49 +01:00
Frank
71ccd23953 Merge branch 'develop' into FF/Ops 2023-01-09 23:03:12 +01:00
Frank
4e68e33ec7 Update OpsZone.lua
- Remove marker
2023-01-09 23:03:01 +01:00
Applevangelist
79c8b31042 #GROUP
* Improve functionality of GetUnit(x)
* Added GetFirstUnit()
2023-01-09 17:08:48 +01:00
Frank
cee72c1d09 Merge branch 'master' into develop 2023-01-08 19:32:50 +01:00
Applevangelist
a7c8954740 Docu typo 2023-01-08 18:38:12 +01:00
Applevangelist
a21b9b382e Merge remote-tracking branch 'origin/develop' into develop 2023-01-08 18:09:26 +01:00
Applevangelist
ef0b76a632 #PLAYERTASK
* Added FSM events PlayerJoinedTask and PlayerAbortedTask
2023-01-08 18:09:22 +01:00
Mike
2806d3a191 Merge pull request #1880 from dogjutsu/dogjutsu/MSRS-gRPC-docs-cleanup
Doc fixes related to MSRS w/ DCS-gRPC alt backend
2023-01-08 16:41:38 +00:00
dogjutsu
9688c7ef01 Doc fixes related to MSRS w/ DCS-gRPC alt backend 2023-01-08 08:34:52 -08:00
dogjutsu
d6181d26f8 Add DCS-gRPC TTS altnerate backend for MSRS (#1879) 2023-01-08 08:37:11 +01:00
Frank
aa5e8662ed Merge pull request #1877 from FlightControl-Master/FF/Ops
OPSGROUP
2023-01-07 17:19:34 +01:00
Frank
ca11e724ab Merge branch 'develop' into FF/Ops 2023-01-07 17:12:04 +01:00
Frank
ab272da46e FLIGHTGROUP
- Increased dealy before Route to base to 1.0 sec. Previous delay of 0.1 sec was apparently too short for the stop flag to take effect and the task was not called done. Hence the mission was also not done.
2023-01-07 17:04:34 +01:00
Frank
584e932769 ARMYGROUP
- No retreat on out-of-ammo if rearming mission is in the queue
2023-01-07 10:53:46 +01:00
Applevangelist
691a500381 Merge remote-tracking branch 'origin/master' into develop 2023-01-05 11:00:06 +01:00
Applevangelist
21a2df0830 Merge remote-tracking branch 'origin/master' into develop 2023-01-05 10:49:13 +01:00
Thomas
4773a83a24 AWACS -correct error in SetAwacsDetails (#1873)
Corrected setting of Angels
2023-01-04 09:21:00 +01:00
Frank
09e9377e54 Merge pull request #1872 from FlightControl-Master/FF/Ops
OPS
2023-01-03 22:13:28 +01:00
Frank
19a90b7d9d Merge branch 'develop' into FF/Ops 2023-01-03 22:10:09 +01:00
Frank
dbaed1e97b OPS
**CHIEF**
- Fixed bugs of polygon opszones
- Added option to use CAPTUREZONE auftrag for opszones

**OPSZONE**
- Fixed bug when marker off

**ZONE_POLYGON_BASE**
- Added `GetRadius()` function

**LEGION**
- Improved Reinforcement
2023-01-03 22:09:56 +01:00
Applevangelist
9695789843 #FG
* make us AB the default
2023-01-03 10:33:51 +01:00
Applevangelist
75ddd2e1e0 Merge remote-tracking branch 'origin/master' into develop 2023-01-03 10:23:34 +01:00
Applevangelist
43c81afd12 Merge remote-tracking branch 'origin/master' into develop 2023-01-03 10:17:48 +01:00
Applevangelist
88a837b769 #FlightGroup
* Added options to allow afterburner, jettison of empty tanks and jettison of weapons
2023-01-03 10:15:35 +01:00
Applevangelist
55656761d2 #FIXES 2023-01-02 17:28:20 +01:00
Frank
92710f4625 Merge pull request #1866 from FlightControl-Master/FF/Ops
Zones
2023-01-02 12:08:37 +01:00
Frank
58dc353bcd ZONE 2023-01-02 11:54:05 +01:00
Frank
b194985827 Merge branch 'develop' into FF/Ops 2023-01-01 20:10:28 +01:00
Frank
bdd283956c AUFTRAG CAP
- Fixed mission speed (unit conversion)
2023-01-01 20:07:14 +01:00
Frank
a9b0017c04 OPS
request
2023-01-01 20:01:36 +01:00
Applevangelist
8f185d1291 #TIMER
* Added `StartIf()`
2023-01-01 12:34:32 +01:00
Frank
9564d9d893 Merge pull request #1861 from FlightControl-Master/FF/Ops
Update FlightGroup.lua
2023-01-01 09:30:15 +01:00
Frank
fe01c6196e Update FlightGroup.lua
- fixed bug that mission does not exist
2023-01-01 09:27:05 +01:00
Frank
c8d9377dbb Merge pull request #1860 from FlightControl-Master/FF/Ops
OPS
2023-01-01 01:08:59 +01:00
Frank
d53f01232d OPS 2023-01-01 01:06:02 +01:00
Applevangelist
e3f9a27f87 # FF changes from today 2022-12-31 18:07:35 +01:00
Applevangelist
e25b9155b4 Merge remote-tracking branch 'origin/develop' into develop 2022-12-31 18:02:35 +01:00
Applevangelist
b769568df1 #FG - let planes not limp around 2022-12-31 18:02:15 +01:00
Thomas
daa60ac501 Update Auftrag.lua 2022-12-31 18:01:28 +01:00
Applevangelist
0340d17ab8 #PLAYERTASKCONTROLLER
* honing the menu build a bit
2022-12-31 15:56:01 +01:00
Frank
c33f637717 Merge pull request #1859 from FlightControl-Master/FF/Ops
OPS
2022-12-31 12:42:02 +01:00
Frank
334af52ddf Merge branch 'develop' into FF/Ops 2022-12-31 12:35:59 +01:00
Frank
9a949c02c5 OPS
- Fixed bug task for recoverytanker mission
- Improved capturezone auftrag
2022-12-31 12:35:48 +01:00
Applevangelist
095c36b3ba #AWACS
* Block Helos from getting CAP assignments
2022-12-31 12:24:49 +01:00
Frank
ff7ebb4f92 Merge pull request #1858 from FlightControl-Master/FF/Ops
OPS Capture Zone
2022-12-30 22:30:57 +01:00
Frank
3834991e6a Merge branch 'develop' into FF/Ops 2022-12-30 22:08:41 +01:00
Frank
67af073b95 OPS
Capture
2022-12-30 22:08:27 +01:00
Applevangelist
5a44948050 #FLIGHTGROUP
* Make one is local
2022-12-30 17:40:10 +01:00
Frank
3011d625b2 OPS
Capture Zone
2022-12-30 02:44:16 +01:00
Applevangelist
d25efe2293 #ATIS
* Make SRS say TACAN and FARP and not spell the single characters
2022-12-29 16:34:11 +01:00
Applevangelist
8202791518 #AWACS
* Added option for helos to sign-in

#ATIS
* Make SRS say TACAN and FARP and not spell the single characters
2022-12-29 16:33:43 +01:00
Applevangelist
9871bf82d3 #UTILS
* Load/Save Improvements
2022-12-28 15:48:46 +01:00
Applevangelist
f9c1d62173 #ATIS
* FARP support
2022-12-25 14:20:25 +01:00
Applevangelist
89d854f5be #EVENT
* Small fix for hit event on coordinates
2022-12-24 12:04:08 +01:00
phr0gz
f1e0bacadb CAPGROUP (#1853)
Fix help typo
2022-12-23 13:44:38 +01:00
Applevangelist
1b0131bd9d Merge remote-tracking branch 'origin/master' into develop 2022-12-23 13:43:43 +01:00
Applevangelist
2f6cd20cbd Merge remote-tracking branch 'origin/master' into develop 2022-12-21 14:12:23 +01:00
Applevangelist
d66d99a24e #CTLD
* Added option to inject troops into helo cargo
2022-12-21 14:07:21 +01:00
Applevangelist
9e823f12c2 #SET_SCENERY
* Added GetAliveSet
2022-12-21 12:55:38 +01:00
Applevangelist
ef5ea01bc1 #TARGET
* Fixes for Scenery and Static Objects
2022-12-21 12:53:08 +01:00
Frank
30e6542887 OPS 2022-12-20 23:51:18 +01:00
Applevangelist
b501eec306 #AUFTRAG
* Fix Orbit w&w/o racetrack
2022-12-20 18:18:24 +01:00
Applevangelist
79e99dcb38 #PLAYERTASK
* Added `GetTarget()`
2022-12-20 16:05:50 +01:00
Applevangelist
f6eccba966 #SET_UNIT - docu fixes
#UNIT - Improved GetGroup() as after the Dec/22 patch getGroup() might be nil
2022-12-19 16:14:41 +01:00
Applevangelist
fa1f67420d #CTLD
* Fix to also save crates which have not been moved
2022-12-19 14:05:21 +01:00
Applevangelist
6e26e7eac3 #AUFTRAG
* Fix for orbit racetrack missing coordinate object
2022-12-19 13:08:35 +01:00
Applevangelist
0a04ff4f3c #AIRBASE
* Added Rio Chico
2022-12-16 18:45:21 +01:00
Applevangelist
99023a3053 #UTILS
* UTILS.LoadSetOfStatics(Path,Filename) ignore statics which do not exist
2022-12-15 18:29:46 +01:00
Applevangelist
a3fd583d9d #PLAYERTASK
* additions for multiple setups
2022-12-15 11:50:05 +01:00
Applevangelist
a6e7ea6590 #SET_CLIENT
* Added FilterCallsigns()
* Added FilterPlayernames()
2022-12-14 14:50:06 +01:00
Applevangelist
178e4ceb7f #PLAYERTASKCONTROLLER
* Added PLAYERTASKCONTROLLER:AddPlayerTaskToQueue(PlayerTask,Silent,TaskFilter) TaskFilter switch
2022-12-14 11:42:12 +01:00
Applevangelist
e12455d154 #AI GCI DISPATCHER
* Fix demo mission link
2022-12-14 09:43:34 +01:00
Applevangelist
71d5983adf #AIRBASE
* docu typo
2022-12-12 16:25:07 +01:00
Applevangelist
696569f749 #PLAYERTASK
* Added typename combos as option for menu entries
2022-12-12 16:24:25 +01:00
Applevangelist
4892a58084 #SET
* improve GetRandom() a bit
2022-12-11 15:51:22 +01:00
Applevangelist
75d8d55691 #AWACS
* Skip Task Assignement Menus if PlayerCapAssignement is false
2022-12-11 15:50:36 +01:00
Applevangelist
614cfcd7f7 Merge remote-tracking branch 'origin/master' into develop 2022-12-09 12:38:02 +01:00
phr0gz
8eef039312 New CAP auftrag (#1850)
Add Ability to CAP escort Ground group or helo with a new auftrag: AUFTRAG:NewCAPGROUP
2022-12-08 13:15:07 +01:00
Applevangelist
f6a88db46b #CTLD Fix for Beacon Zone disappearing too fast 2022-12-07 18:58:56 +01:00
Applevangelist
9c5847153a Merge remote-tracking branch 'origin/develop' into develop 2022-12-07 18:58:11 +01:00
Applevangelist
cdfb47448f #AWACS
* Fix setting of CapVoices according to documentation
#PLAYERRECCE
* Speed up Marker Build
#PLAYERTASK
* Improve menu build
2022-12-07 18:58:07 +01:00
Frank
0adca414ce Merge branch 'develop' into FF/Ops 2022-12-07 18:36:04 +01:00
Frank
16bfbabf19 Merge branch 'master' into develop 2022-12-07 18:35:27 +01:00
Frank
539dfd6a38 OPS Operation
- Condition
- Armygroup
- Auftrag
- OPS
2022-12-07 18:32:50 +01:00
Applevangelist
525666be7c #PLAYERRECCE
* Smoke own position on ground, not mid-air
2022-12-06 18:05:41 +01:00
Applevangelist
386171bcab #PLAYERTASKCONTROLLER
* Make callout of MGRS coordinates slower
2022-12-06 12:50:08 +01:00
Applevangelist
55383575e0 #PLAYERTASKCONTROLLER
* Make callout of MGRS coordinates slower
2022-12-06 12:48:20 +01:00
Applevangelist
9659bfa553 #CTLD Fix for Beacon Zone disappearing too fast 2022-12-03 14:38:57 +01:00
Applevangelist
85504fbe62 Small Fixes 2022-12-03 14:36:28 +01:00
Applevangelist
de8dcc4024 Merge remote-tracking branch 'origin/master' into develop 2022-12-02 16:39:45 +01:00
Applevangelist
620c8eaa27 Merge remote-tracking branch 'origin/master' into develop 2022-12-01 13:29:20 +01:00
Frank
3f296554ed Merge branch 'develop' into FF/Ops 2022-11-30 18:37:51 +01:00
Frank
2a8d166c54 Merge branch 'master' into develop 2022-11-30 18:37:28 +01:00
Frank
6bc263bd2b CONDITON and OPERATION 2022-11-30 13:36:13 +01:00
Applevangelist
907d62c4e7 Merge remote-tracking branch 'origin/master' into develop 2022-11-29 17:54:15 +01:00
Applevangelist
6965d319ef #CTLD
* Fix for BEACON zones
2022-11-29 15:42:49 +01:00
Applevangelist
d674f55343 #PLAYERTASK
* Added Silent option for PLAYERTASKCONTROLLER:AddPlayerTaskToQueue(PlayerTask,Silent)
2022-11-29 15:42:04 +01:00
Thomas
75bc95167f Update RAT.lua (#1849)
Fix #1848
2022-11-28 17:45:47 +01:00
Applevangelist
66bf32351a Merge remote-tracking branch 'origin/master' into develop 2022-11-27 17:35:42 +01:00
Applevangelist
fe9a5aea2a #AUFTRAG
* Fix for orbit task not able to get a Vec2 from a Vec2...
2022-11-23 12:57:54 +01:00
Applevangelist
b99d963cd5 #SPAWN
* Fix callsign dupplication of numbers introduced with 2.8
2022-11-23 09:56:37 +01:00
Frank
b8398af5a3 Merge branch 'master' into develop 2022-11-20 20:56:07 +01:00
Frank
10d8af2536 Merge branch 'master' into develop 2022-11-19 19:37:54 +01:00
Frank
e79941bb8b Merge pull request #1846 from FlightControl-Master/FF/Ops
OPS
2022-11-18 20:02:15 +01:00
Frank
4124b6d084 OPS
**LEGION**
- Added `Captured` event

**COMMANDER**
- Improved behaviour when legion/warehouse is captured
- Added `LegionLost` event
- Added `RemoveLegion` function

**CHIEF**
- Improved behaviour when legion/warehouse is captured
- Added `LegionLost` event
- Added `RemoveLegion` function
2022-11-18 19:56:30 +01:00
Applevangelist
ae9c258531 Merge remote-tracking branch 'origin/master' into develop 2022-11-18 11:29:45 +01:00
Applevangelist
df17a3d2a3 # TaskRecoveryTanker 2022-11-18 11:28:33 +01:00
Applevangelist
b47737bda3 #GROUP
* Added additional push of tanker task to GROUP:SetAsRecoveryTanker() for a working setup
2022-11-18 11:24:36 +01:00
Applevangelist
96bb475306 #GROUP/CONTROLLABLE
* Added RecoveryTanker Task
2022-11-18 09:59:43 +01:00
Applevangelist
7490796637 #AIRBASE
* Added enumerators for
-- * AIRBASE.SouthAtlantic.Puerto_Santa_Cruz
-- * AIRBASE.SouthAtlantic.Comandante_Luis_Piedrabuena
-- * AIRBASE.SouthAtlantic.Aerodromo_De_Tolhuin
-- * AIRBASE.SouthAtlantic.Porvenir_Airfield
-- * AIRBASE.SouthAtlantic.Almirante_Schroeders
-- * AIRBASE.SouthAtlantic.Rio_Turbio
2022-11-17 17:14:52 +01:00
Applevangelist
a9f2df83ff #CSAR
* Make rescued pilot's weight configureable
2022-11-17 13:55:42 +01:00
Applevangelist
50aca57112 #PLAYERTASK
* Extended use of marker ops:
-- Enable the function like so:
--          mycontroller:EnableMarkerOps("TASK")
-- Then as a player in a client slot, you can add a map marker on the F10 map. Next edit the text
-- in the marker to make it identifiable, e.g
--
-- TASK Name=Tanks Sochi, Text=Destroy tank group located near Sochi!
--
-- Where **TASK** is the tag that tells the controller this mark is a target location (must).
-- **Name=** ended by a comma **,** tells the controller the supposed menu entry name (optional). No extra spaces! End with a comma!
-- **Text=** tells the controller the supposed free text task description (optional, only taken if **Name=** is present first). No extra spaces!
function PLAYERTASKCONTROLLER:EnableMarkerOps(Tag)
2022-11-17 13:22:34 +01:00
Applevangelist
5011269586 #SPAWN
* Ensure we have a numbered table for InitRandomizeTemplate/Zone so math.random actually works
* Also, pre-shuffle tables
2022-11-16 11:17:19 +01:00
Frank
bd42032e3a Merge pull request #1844 from FlightControl-Master/FF/Ops
OPS
2022-11-16 10:44:00 +01:00
Frank
1256cc3bd1 OPS
**FLIGHTGROUP**
- Waypoint altitude for helos is not radar (AGL)
- Increased cruise speed thresholds for helos to 110 kts and 380 kts for fixed wing
2022-11-16 10:41:33 +01:00
Applevangelist
62122a15bc #MESSAGE
* Added ToCountry()
* Added country names in country.id enum
2022-11-16 09:42:36 +01:00
Applevangelist
f86db5f134 #PLAYERTASK
* Verbose to false
* Verbose add message for marker ops showing coordinate as per _SETTINGS
2022-11-15 17:56:29 +01:00
Thomas
2acb841539 Update PlayerTask.lua
Feature added #1841 `PLAYERTASKCONTROLLER:SetInfoShowsCoordinate(OnOff,LLDDM)`
2022-11-15 15:59:03 +01:00
Applevangelist
6724bb8edd # Bug fixes 2022-11-14 18:17:27 +01:00
Applevangelist
7b5b5e0bd2 #ATIS
* Honor Stop() function
2022-11-14 17:38:46 +01:00
Applevangelist
243ac3027f #PLAYERTASK
* Added a couple of QOL functions for internal INTEL object
2022-11-14 17:38:07 +01:00
Applevangelist
79a4af44d3 Merge remote-tracking branch 'origin/master' into develop 2022-11-13 13:51:59 +01:00
Applevangelist
180a0b39d1 Merge remote-tracking branch 'origin/develop' into develop 2022-11-13 13:38:13 +01:00
Applevangelist
2664c36a14 #CTLD
* Change call order to move troops, vehicle on `onafter..` internally
* added pseudo-function for "OnBefore..."
2022-11-13 13:37:55 +01:00
Rolln
911f4523a1 F10 Marker text fix (#1840) 2022-11-11 20:01:32 +01:00
Applevangelist
09b86d6fdf #OPSGROUP
* Fix for NewHover
2022-11-11 15:40:03 +01:00
Applevangelist
5ec8a4674c Merge remote-tracking branch 'origin/master' into develop
# Conflicts:
#	Moose Development/Moose/DCS.lua
2022-11-11 11:42:30 +01:00
Applevangelist
2a567c9f74 Docu Headlines part II 2022-11-11 11:40:22 +01:00
Applevangelist
b9a7fc9409 #AUFTRAG
* Corrected speed setting in NewHover
2022-11-11 10:00:13 +01:00
Applevangelist
0db13b6cdf Merge remote-tracking branch 'origin/master' into develop
# Conflicts:
#	Moose Development/Moose/AI/AI_Cargo_Dispatcher_Ship.lua
#	Moose Development/Moose/Functional/ZoneGoalCoalition.lua
2022-11-11 09:38:27 +01:00
Applevangelist
08c7409627 Docu Headlines 2022-11-11 09:22:48 +01:00
Applevangelist
c38cb046cd #AMMOTRUCK
* Added demo mission link
2022-11-10 17:53:29 +01:00
Applevangelist
037b168825 Merge remote-tracking branch 'origin/master' into develop 2022-11-10 17:33:52 +01:00
Applevangelist
41a928b775 #Docu fixes 2022-11-10 17:29:19 +01:00
Applevangelist
27598406d1 #AMMOTRUCK
* Initial Release
2022-11-10 17:11:29 +01:00
Applevangelist
a0ad5292b9 #AWACS
* SRS output for "ShowTask"
* Some minor bug fixing
2022-11-10 12:18:18 +01:00
Frank
a1a258f48e Merge pull request #1838 from FlightControl-Master/FF/Ops
OPS
2022-11-10 00:40:15 +01:00
Frank
4a0040a12f Merge branch 'develop' into FF/Ops 2022-11-10 00:36:14 +01:00
Frank
ab13b5f198 Update Intelligence.lua
- Added check for filter categories.
2022-11-10 00:36:02 +01:00
Applevangelist
788d2d49b9 Merge remote-tracking branch 'origin/master' into develop 2022-11-09 16:11:44 +01:00
Frank
6c342ef910 Merge pull request #1834 from FlightControl-Master/FF/Ops
OPS
2022-11-08 22:11:21 +01:00
Frank
a4b5362347 Update Cohort.lua
- Added functions to get and set attributes
- Added function to get category and properties
2022-11-08 22:01:44 +01:00
Frank
0e78be86e4 CHIEF
- Added resource.carrierProperties for LEGION.AssignAssetsForTransport
- Ensure table for carrier categories, attributes and properties
2022-11-08 20:29:51 +01:00
Applevangelist
e348bbc344 #AWACS
* Minor Enhancements
2022-11-08 17:24:32 +01:00
Applevangelist
bad17c39d1 * POINT/PLAYERTASK
* Added option to get BR/BRA with add'l magnetic heading
2022-11-08 15:43:46 +01:00
Applevangelist
8ed30da473 * POINT/PLAYERTASK
* Added option to get BR/BRA with add'l magnetic heading
2022-11-08 15:43:14 +01:00
Applevangelist
af1083d0f1 #MSRS
* Docu corrections
* Added `AddFrequencies()` and `AddModulations()`
2022-11-08 10:11:28 +01:00
Applevangelist
4fff842c90 #CTLD Fix Ship Zones 2022-11-07 19:14:09 +01:00
Applevangelist
7f81039f46 #CTLD - Added Bronco support 2022-11-07 18:21:36 +01:00
Applevangelist
b63be6dd28 #PLAYERTASK
* Fix #1826 CTLD/CSAR closing immediately
2022-11-07 17:39:11 +01:00
Applevangelist
565a5294e2 Merge remote-tracking branch 'origin/master' into develop 2022-11-07 16:09:00 +01:00
Frank
254d43fef1 AIRWING/WAREHOUSE
- Improved parking spot check if explicitly given for an airwing or squadron
- Improved parking check if airstart is requested.
2022-11-06 12:17:07 +01:00
Applevangelist
5819884c98 #SCORING
* Added option to switch AutoSave
2022-11-06 11:27:27 +01:00
Frank
cb43f9c392 CHIEF
- cleaned up resources
2022-11-05 23:48:42 +01:00
Applevangelist
ed677b7682 Merge remote-tracking branch 'origin/master' into develop 2022-11-05 14:04:06 +01:00
Frank
ead8411454 Merge pull request #1824 from FlightControl-Master/FF/Ops
OPS
2022-11-04 22:55:24 +01:00
Frank
1fc9f13919 Version 2022-11-04 22:36:20 +01:00
Frank
6bf077e0aa Merge branch 'develop' into FF/Ops 2022-11-04 19:47:52 +01:00
Applevangelist
0de8c0beb2 #INTEL
* Added `INTEL:GetHighestThreatContact(Cluster)`
2022-11-04 13:31:33 +01:00
Frank
39f690f2b4 OPS
- AUFTRAG: Orbit is now in KIAS
- CHIEF: fixes for resource
2022-11-03 22:46:10 +01:00
Frank
1a575d9364 Update OpsGroup.lua
- Improved mission ingreess on-off-road waypoint
2022-11-02 23:51:53 +01:00
Frank
fe58253a44 Update Chief.lua
added remove conflict zone
2022-11-02 23:30:19 +01:00
Frank
65cc72e28b Merge branch 'develop' into FF/Ops 2022-11-02 22:59:19 +01:00
Frank
00f8fccfae Update ArmyGroup.lua
- Improved updateroute waypoints
2022-11-02 22:57:05 +01:00
Applevangelist
1fea016ac1 Merge remote-tracking branch 'origin/master' into develop 2022-11-02 17:33:34 +01:00
Applevangelist
35057b9d05 Merge remote-tracking branch 'origin/develop' into develop 2022-11-02 17:32:20 +01:00
Applevangelist
b2fdcd5cf0 #CHIEF
* Fix to auto-create CAS/CAS-Enhanced Missions from detected targets; Added BAI mission option for TANKS as target
2022-11-02 17:32:12 +01:00
Thomas
2b3363de40 Documentation fixes. (#1820) (#1821)
* Documentation fixes.

* Update Airboss.lua

Escape links.

Co-authored-by: TommyC81 <tommyc81@gmail.com>
2022-11-02 11:24:59 +01:00
Frank
d031651b58 Fixes for OPSTRANSPOTRT formation 2022-11-01 23:35:18 +01:00
Applevangelist
8fb66ed329 #ZONE_POLYGON
* Scan for Scenery - changed scan strategy as box seems not to work properly all the time
2022-11-01 16:32:40 +01:00
Applevangelist
e841a38866 #CTLD
* added option for build time delay
2022-11-01 14:33:06 +01:00
Frank
addb7ba36a restore 2022-10-31 20:53:20 +01:00
Frank
d4b5e24364 ARMYGROUP
- Fixed opstransport not being readded to brigade
2022-10-31 20:50:35 +01:00
Applevangelist
dd32d2e53c #CTLD_HERCULES
* Fix for `CTLD_HERCULES:Cargo_Track(cargo, initiator)` when flying very low
2022-10-31 16:07:25 +01:00
Applevangelist
cc1e071e35 #EVENT
* Added events from 2.8.0
2022-10-31 15:44:29 +01:00
Frank
3f8efae23f Update Chief.lua
resources
2022-10-31 13:26:35 +01:00
Applevangelist
8ee8898a78 #AWACS
* Added airborne check for detected groups
2022-10-31 12:22:34 +01:00
Applevangelist
fc77df4b5d Merge remote-tracking branch 'origin/master' into develop 2022-10-31 10:26:45 +01:00
Applevangelist
13018ed96a Merge remote-tracking branch 'origin/master' into develop 2022-10-31 08:02:21 +01:00
Frank
236e7afcfc AUFTRAG
- New mission type ORBIT_GROUP
- Updated mission type RECOVERYTANKER
2022-10-30 14:10:55 +01:00
Thomas
946a1de931 Merge docu changes (#1818)
* Documentation fixes. (#1810)

Fix documentation references.
Correct spelling errors.
Remove empty whitespaces.
Correct a single mis-spelled ZONE_BASE variable, see 'Core/Zone.lua' (variable "Sureface" -> "Surface", no references to mis-spelled "Sureface" throughout the codebase).
Correct mis-spelling of "coaltion" in 'Functional/Mantis.lua', corrected to "coalition".

* Documentation fixes. (#1811)

Update documentation text and links.
Fix spelling errors.
Other minor adjustments where appropriate, such as remove whitespaces and format code.

* Documentation fixes. (#1815)

Minor documentation and code formatting fixes.
This is mostly intended to have something re-trigger the documentation generation to see if the filename capitalization is resolved.

* Code formatting preparation. (#1817)

Use EmmyLuaCodeStyle that comes with "Lua" VS Code extension (https://marketplace.visualstudio.com/items?itemName=sumneko.lua). More features and configurability than LuaFormatter, and no need for additional extension (beyond "Lua").
Formatting file set up from default template with some tweaks to correspond to most common coding style observed in the code base. Further tweaks are likely required.

* Documentation fixes. (#1816)

Co-authored-by: TommyC81 <tommyc81@gmail.com>
2022-10-29 10:49:18 +02:00
Frank
2840865b83 Up 2022-10-27 23:19:35 +02:00
Applevangelist
1411309204 Fixes 2022-10-21 15:15:51 +02:00
Applevangelist
60927e6728 Merge remote-tracking branch 'origin/master' into develop 2022-10-21 15:11:46 +02:00
Applevangelist
4b11a6a304 #OPS - typos 2022-10-21 15:09:35 +02:00
Applevangelist
37a00f25bc #OPERATION
* Added GetTargets()

#TARGET
* Also call Dead() when no targets left over

#PLAYERTASKCONTROLLER
* Added FSM events for Flaring, Smoking, and Illumination
* Added Illumination of targets in menu if it is night
* Rename menu parent setting to SetParentMenu(Menu)
2022-10-21 09:51:44 +02:00
Applevangelist
1fc541a9df Merge remote-tracking branch 'origin/master' into develop 2022-10-21 08:58:48 +02:00
Applevangelist
c3cd732254 #MANTIS
* Add systems from SMA mod
2022-10-20 11:40:57 +02:00
Applevangelist
8f7694111b #TARGET
* Docu additions
2022-10-19 19:13:55 +02:00
Applevangelist
2854a2d93e #TARGET
* Some QOL additions, docu, stuff for SCENERY
2022-10-19 17:26:40 +02:00
Applevangelist
78c209a96f #PLAYERTASKCONTROLLER
* No spaces in callsign numbers on pilot list in task info screen
2022-10-19 13:05:19 +02:00
Applevangelist
9809f08954 Merge remote-tracking branch 'origin/master' into develop 2022-10-19 12:46:17 +02:00
Applevangelist
4e671ce995 Merge remote-tracking branch 'origin/master' into develop 2022-10-19 12:28:26 +02:00
Rolln
b5fd737cea Playertaskcontroller parent menu (#1806)
* Ability to set parent menu of PlayerTaskController

* Updated Docmentation

* Update PlayerTask.lua

Co-authored-by: Thomas <72444570+Applevangelist@users.noreply.github.com>
2022-10-19 12:21:16 +02:00
Frank
6f82fd7eb6 Merge branch 'develop' into FF/Ops 2022-10-18 22:33:07 +02:00
Applevangelist
542fe20782 #CTLD
* added a check for zones; not added when zone does not exist
2022-10-18 17:26:24 +02:00
Applevangelist
92591432d3 #CSAR
* Added use of custom callsigns
* Added cargo weight for rescued pilots
* Improved o'clock calculation

#CTLD
* Docu additions
2022-10-18 17:01:32 +02:00
Applevangelist
a20cdac9c3 #CSAR
* Added use of custom callsigns
* Added cargo weight for rescued pilots
* Improved o'clock calculation

#CTLD
* Docu additions
2022-10-18 17:00:56 +02:00
Applevangelist
23f45359f8 #PLAYERTASK - show freetext briefing also if not using SRS 2022-10-18 13:32:18 +02:00
Applevangelist
0bc09548cf #PLAYERRECCE - add picture 2022-10-18 10:27:25 +02:00
Applevangelist
ee30ab48ae #SET_SCENERY
* additions
2022-10-17 18:07:55 +02:00
Applevangelist
3028a384a4 #TARGET
* Added SET_SCENERY
2022-10-17 18:07:04 +02:00
Thomas
f17db43501 CTLD - No radius check (#1800) (#1801)
Get rid of radius check in IsUnitInZone()
2022-10-17 12:44:27 +02:00
Applevangelist
7dd46ec24f #PLAYERTASKCONTROLLER
* Show Freetext as Briefing in all tasks when available
* TARGET - added Average coordinate option from GROUP
2022-10-16 13:47:52 +02:00
Applevangelist
cefb5d98f0 #GROUP
* Added function to obtain *average* Vec3 of the GROUP
* Added function to obtain *average* Coordinate of the GROUP

#TARGET
* Make use of new coordinate function in GROUP
2022-10-16 13:38:54 +02:00
Thomas
e750a99636 Update PlayerRecce.lua
Event Handler simplification
2022-10-16 09:30:55 +02:00
Applevangelist
798684e300 #Docu additions 2022-10-14 16:51:59 +02:00
Applevangelist
7c004ee37c #docu 2022-10-14 16:50:16 +02:00
Applevangelist
0a4bc23fb8 #PLAYERRECCE
* Added switchable smoking of own position
* Changed smoking - now laser target single, other targets as combined coordinate
* Added battle field illumination
* Added support for the KA-50. Note - camera is seen as "always on". For lasing, target needs to be head-on 12 o'clock
2022-10-14 16:19:53 +02:00
Applevangelist
13a5146010 #PLAYERRECCE
* Added switchable smoking of own position
* Changed smoking - now laser target single, other targets as combined coordinate
* Added battle field illumination
* Added support for the KA-50. Note - camera is seen as "always on". For lasing, target needs to be head-on 12 o'clock
2022-10-14 16:19:21 +02:00
Frank
55fe3630c5 Update FlightGroup.lua
- Fixed bug that function `:GetAirWing` was renamed to `:GetAirwing()`
2022-10-13 23:11:09 +02:00
Applevangelist
265196398a #PLAYERTASK - CSAR, CTLD integration 2022-10-13 17:45:33 +02:00
Applevangelist
141d00e160 Merge remote-tracking branch 'origin/master' into develop 2022-10-13 17:44:04 +02:00
Applevangelist
5c8d90f50e #SCENERY
* Improvements
2022-10-13 12:54:10 +02:00
Applevangelist
351a2463a2 #SCENERY - Improvements 2022-10-13 10:49:58 +02:00
Applevangelist
f604f0f913 Merge remote-tracking branch 'origin/master' into develop 2022-10-12 16:22:37 +02:00
Applevangelist
7afe76212d #CTLD
* Added connection to PlayerTask/Controller
#PLAYERTASK
* Added helper functions
2022-10-12 12:36:33 +02:00
Applevangelist
a777b40613 #PLAYERTASKCONTROLLER
* Initial additions for CTLD tasks
2022-10-12 10:14:40 +02:00
Applevangelist
11ef7c6a00 #STATIC
* Added GetLife() GetLife0()
#TARGET
* Added usesage of Life functions to TARGET
2022-10-12 09:36:42 +02:00
Applevangelist
b5bc881d52 Merge remote-tracking branch 'origin/master' into develop 2022-10-10 17:44:55 +02:00
Applevangelist
66d5ba9981 #Core.Point
* Cleanup GetClosestAirbase()
2022-10-10 17:44:20 +02:00
Applevangelist
eecef9a0aa #PLAYERRECCE
* minor enhancements
2022-10-09 12:56:54 +02:00
Applevangelist
7e6aa20168 #PLAYERRECCE
* Minor Enhancement
2022-10-09 12:56:00 +02:00
Applevangelist
69a80a6c38 #PLAYERRECCE
* Added setting of laser distance as camera sight calc is a non-starter
* Added specific laser zone of 20m x length to catch targets to lase
* Reworked detection of hit on lased target
2022-10-07 14:33:38 +02:00
Applevangelist
d63ab1138c #PLAYERTASKCONTROLLER
* Enable PLAYERTASKCONTROLLER:EnableBuddyLasing(Recce) - buddy lasing precision bombing tasks with a PLAYERRECCE connection
2022-10-06 17:05:16 +02:00
Applevangelist
f790c4fb9e #PLAYERRECCE
* Gazelle optics refinement
* Added Shack FSM event
2022-10-06 13:29:58 +02:00
Applevangelist
40427c75b9 #FlightGroup dual naming in functions 2022-10-06 13:28:19 +02:00
Applevangelist
e18a5e4832 #PLAYERTASKCONTROLLER
* Switch comms on opening task
2022-10-06 08:15:39 +02:00
Applevangelist
4d2a58e428 Fixes 2022-10-06 08:07:37 +02:00
Applevangelist
005d6d2b06 Merge remote-tracking branch 'origin/master' into develop 2022-10-06 08:03:07 +02:00
Thomas
7ada57033a Update PlayerRecce.lua (#1796)
* Update PlayerRecce.lua

* Update PlayerRecce.lua
2022-10-06 07:25:24 +02:00
Applevangelist
1a332ae6ab Merge remote-tracking branch 'origin/master' into develop 2022-10-05 07:33:46 +02:00
Frank
064e082a12 Airwing
- Added `:IncreasePayloadAmount` function
2022-10-03 19:12:19 +02:00
Frank
10eec8a47b Update FlightGroup.lua
- Added `GetSquadronName` and `GetAirwingName` functions
2022-10-03 16:32:55 +02:00
Frank
db469d1b84 Merge branch 'develop' into FF/Ops 2022-10-02 22:10:52 +02:00
Frank
1e04aaa77d Update Airboss.lua
- reenabled ai handling
2022-10-02 19:45:48 +02:00
Applevangelist
e97753125d Merge remote-tracking branch 'origin/master' into develop 2022-10-02 19:35:15 +02:00
Applevangelist
1474ff9b88 Merge remote-tracking branch 'origin/develop' into develop 2022-10-02 19:34:09 +02:00
Applevangelist
39bb95f127 #PLAYERRECCE
-- DONE: Sort for multiple targets in one direction
-- DONE: Targets with forget timeout, also report
2022-10-02 19:34:04 +02:00
Frank
42baf6c8d2 AIRBOSS v1.3.0
- Added Invincible parameters from master branch
- Increased version number
2022-10-02 19:13:51 +02:00
Frank
73b9552b5c Merge branch 'master' into develop 2022-10-02 16:55:47 +02:00
Frank
60cf7506f8 Update Airboss.lua
- Added `landingdist` as carrier parameter and into LSO result
- Case III does not check groove time for unicorns
2022-10-02 16:10:14 +02:00
Applevangelist
894062c757 #POINT
* Added COORDINATE:ToStringFromRPShort
2022-10-02 13:16:56 +02:00
Applevangelist
165a5d7364 #PLAYERRECCE
* Message improvements
* Laser Distance 8km
* Option to set RP Reference Point
2022-10-02 13:16:00 +02:00
Applevangelist
405e66ea72 #PLAYERTASK
* SRS transmit option only when players are on
2022-10-01 16:36:29 +02:00
Applevangelist
a42ff85406 #PLAYERRECCE
* Integrated SRS
* Integrated PLAYERTASKCONTROLLER (optional), can upload target data from Recce
2022-10-01 16:03:05 +02:00
Applevangelist
2eba68b35c #ATIS, MSRSQUEUE
* Added option to only transmit via SRS if there are active Players
2022-10-01 11:58:28 +02:00
Frank
efe7673c4c Merge branch 'develop' into FF/Ops 2022-09-30 19:34:23 +02:00
Applevangelist
ca92d7d569 #PLAYERRECCE
* Some nicefications
2022-09-30 19:07:12 +02:00
Applevangelist
0ee2baadce #AWACS
* Make Markers and Drawings strictly coalition specific
2022-09-30 19:03:26 +02:00
Applevangelist
43856341e6 #PLAYERRECCE
* Initial Release
2022-09-30 18:49:08 +02:00
Applevangelist
61aed403d9 #SET
* Added code to`SET:IsInSet(Object)` to be functional
2022-09-30 14:48:35 +02:00
Applevangelist
a8a92c00fe #AUTOLASE
* Don't forget min threatlevel 0 on unit targets
2022-09-30 14:41:38 +02:00
Applevangelist
84c41aa554 Merge remote-tracking branch 'origin/master' into develop 2022-09-29 16:45:29 +02:00
Applevangelist
de415384f3 #PLAYERTASK - a target can only be smoked again after 5 mins (that's how long smoke lasts)
#PLAYERTASKCONTROLLER - added option to hide smoke&flare menus
2022-09-28 13:07:37 +02:00
Applevangelist
8a9ee747c1 #ZONE_CAPTURE_COALITION - allow zone to be a ZONE_POLYGON
#1789
2022-09-28 11:51:22 +02:00
Applevangelist
2eeb918c8a #ATIS
* Fixed SetILS report not working
* Use new AIRBASE additions to set takeoff/landing runway
* Fixed Visibility is reported twice
* Added SetReportmBar() to report for mBar/hpa QNH/QFE even if not metric
* Added option to output additional freetext information when using SRS SetAdditionalInformation()

#1792
2022-09-27 11:17:04 +02:00
Applevangelist
72aa596317 #1790 Fix for error in GetCustomCallsign if the player name contains a |-sign but no string at the end or just numbers 2022-09-27 09:31:08 +02:00
Frank
6de3a45a51 CHIEF
**CHIEF** v0.5.0
- Added `CHIEF:AddTransportToResource` function

**OPSZONE**
- Added `Undraw` option

**UTILS**
- Added `UTILS.EnsureTable` function
2022-09-26 19:00:26 +02:00
Applevangelist
28a826b35d #CSAR
* Added mycsar.ADFRadioPwr = 1000 for ADF beacon radio sending power
2022-09-26 17:03:08 +02:00
Applevangelist
41813dcc53 #AWACS - corrected aggressive 2022-09-25 15:04:39 +02:00
Applevangelist
6290409e54 #ATIS - added google option
#SRS - corrected enumerator
2022-09-25 14:42:51 +02:00
Applevangelist
25033f4f6b #FlightControl - Option to set Google key once on New() 2022-09-25 14:40:17 +02:00
Applevangelist
b8fae00c1e #MSRS - put "" around frequencies and modulations 2022-09-25 14:16:19 +02:00
Applevangelist
6d4e4e2f69 #AWACS - give full radio freq in info 2022-09-25 14:12:46 +02:00
Applevangelist
1cde688fbb #RANGE
* Added 2 more SRS outputs
2022-09-24 10:11:23 +02:00
Applevangelist
e3493fbe3e #CSAR
* Added option to change top menu name
2022-09-23 10:29:41 +02:00
Applevangelist
1b691a3dd7 #FOX
* Typo in Event function fixed
2022-09-23 10:00:09 +02:00
Applevangelist
3022dce26e #CTLD
* check on loadable mass when loading troops added
2022-09-22 17:32:43 +02:00
Applevangelist
9780a65f09 #AIRBOSS, #UTILS
* Alitude to Altitude
* Deck height Nimitz class to 18.30m
2022-09-22 15:51:28 +02:00
Applevangelist
34dd864c8b #SPAWN
* Fix for InitCleanup()
2022-09-22 10:58:50 +02:00
Applevangelist
9b16519a7e #ATIS
* Added MSRSQueue to avoid overlapping speech
2022-09-20 17:18:00 +02:00
Applevangelist
76321343c2 #AIRBASE, ATIS
* less noise in log

#SRS
* Added enumerator for voices MSRS.Voices.Microsoft... and MSRS.Voices.Google...

#RANGE
* Added SRS support, some bug fixing
2022-09-20 15:53:09 +02:00
Applevangelist
0159ce5b1d Merge remote-tracking branch 'origin/master' into develop 2022-09-20 10:27:06 +02:00
Applevangelist
5abec25c58 #UTILS
* Fix for loading back set of groups. Thanks to @BlueEcko!
2022-09-20 08:24:50 +02:00
Applevangelist
d9de1e866f Merge remote-tracking branch 'origin/master' into develop 2022-09-19 18:26:56 +02:00
Applevangelist
1ae8e7d55e Merge remote-tracking branch 'origin/master' into develop 2022-09-19 13:22:18 +02:00
Applevangelist
67dc4521e9 Merge remote-tracking branch 'origin/master' into develop 2022-09-19 11:44:59 +02:00
Applevangelist
852ebba530 #AUTOLASE
* also show A2G BR Settings
2022-09-19 11:42:50 +02:00
jojom4n
79669d9a69 Make AWACS SRS talk as own coalition; Typo (#1784)
* Make AWACS SRS talk as own coalition

Set MSRS coalition to make AWACS talk only to its coalition, not to spectators

* Typo

SetModernEraAgressive() function should be SetModernEraAggressive() (two 'g')
2022-09-18 19:04:40 +02:00
Applevangelist
11d37bcb93 #CSAR
- triple try to get coordinate for beacon
2022-09-15 19:54:36 +02:00
Applevangelist
c95d5dc320 #PLAYERTASK
* coord text fix
2022-09-15 19:50:45 +02:00
Applevangelist
92044c7797 Merge remote-tracking branch 'origin/master' into develop 2022-09-15 14:02:09 +02:00
Applevangelist
7084d9e084 #OPSGROUP
* Allow for customized CallSigns

#PLAYERTASK
* SRS output finetuning
2022-09-15 13:59:16 +02:00
Applevangelist
af96e2f143 Merge remote-tracking branch 'origin/master' into develop 2022-09-15 13:52:20 +02:00
Applevangelist
f7560714e7 Merge remote-tracking branch 'origin/master' into develop 2022-09-15 08:18:19 +02:00
Applevangelist
785c5e66ec bump number 2022-09-14 18:07:53 +02:00
Applevangelist
f281e5aa95 #AWACS
* Align CallSign Generation
2022-09-14 18:06:36 +02:00
Applevangelist
55f0f5271d #PLAYERTASKCONTROLLER
* Clean up menu builds
2022-09-13 17:19:44 +02:00
Applevangelist
b60d3a771d Merge remote-tracking branch 'origin/master' into develop 2022-09-13 10:55:57 +02:00
Applevangelist
d2132b2e64 #PLAYERTASKCONTROLLER
* Align creation of (player) callsigns with what is used in AWACS
2022-09-13 10:11:10 +02:00
Applevangelist
95494c0d03 Merge remote-tracking branch 'origin/master' into develop 2022-09-12 17:34:21 +02:00
Applevangelist
76a8286c04 Merge remote-tracking branch 'origin/master' into develop 2022-09-12 17:29:47 +02:00
Applevangelist
eca8d6dd8d #AWACS
* Fixed AWACS custom callsigns not observed
2022-09-11 18:21:58 +02:00
Applevangelist
e6ae034f7e Merge remote-tracking branch 'origin/develop' into develop 2022-09-11 14:22:52 +02:00
Applevangelist
236b4efb9b #PLAYERTASKCONTROLLER
* Various fixes and improvements
2022-09-11 14:22:47 +02:00
Frank
4b4c9ba959 Merge branch 'master' into develop 2022-09-11 13:38:40 +02:00
Applevangelist
6bf05741a9 Merge remote-tracking branch 'origin/master' into develop 2022-09-10 15:16:47 +02:00
Applevangelist
5d1998accb #CONTROLLABLE
*Foreign class definiton removed
2022-09-10 15:14:41 +02:00
Applevangelist
3aa9ffc241 #MODULES
* ordered list
2022-09-10 12:54:37 +02:00
Applevangelist
8ab5575e0a Merge remote-tracking branch 'origin/master' into develop
# Conflicts:
#	Moose Development/Moose/Modules.lua
#	Moose Setup/Moose.files
2022-09-10 12:19:23 +02:00
Applevangelist
3980b8a9c8 Merge remote-tracking branch 'origin/master' into develop 2022-09-10 11:34:56 +02:00
Thomas
27550d7ec9 Merge changes from master into dev for GROUP (#1781)
* #GROUP
* changes from Dev
#UNIT
* changes from Dev

* #GROUP
Fix GetSpeedMax() always returns zero
2022-09-09 17:50:18 +02:00
Thomas
35513e1e21 #GROUP (#1779)
* changes from Dev
#UNIT
* changes from Dev
2022-09-08 16:10:38 +02:00
Applevangelist
15496aed44 Merge remote-tracking branch 'origin/Apple/Develop' into develop
# Conflicts:
#	Moose Development/Moose/Functional/Autolase.lua
2022-09-08 11:58:29 +02:00
Applevangelist
27408c191d #AUTOLASE
* Added option for blacklist atttributes
* Added higher priority for radar units
* Removed the "#001-01" appendix of spawned Recce on messages
2022-09-08 11:55:29 +02:00
Applevangelist
4b6c6717ad #Autolase
* SetMinThreatLevel
2022-09-08 09:11:26 +02:00
Applevangelist
c0bc3d8061 Merge remote-tracking branch 'origin/develop' into develop 2022-09-08 08:45:16 +02:00
Thomas
fe5f252bc9 Update Autolase.lua (#1778) 2022-09-07 15:22:00 +02:00
Applevangelist
e25af085fc Merge remote-tracking branch 'origin/master' into develop
# Conflicts:
#	Moose Development/Moose/AI/AI_A2A_Dispatcher.lua
#	Moose Development/Moose/AI/AI_A2G_Dispatcher.lua
#	Moose Development/Moose/AI/AI_CAP.lua
#	Moose Development/Moose/AI/AI_CAS.lua
#	Moose Development/Moose/AI/AI_Patrol.lua
#	Moose Development/Moose/Core/Base.lua
#	Moose Development/Moose/Core/Beacon.lua
#	Moose Development/Moose/Core/Database.lua
#	Moose Development/Moose/Core/Fsm.lua
#	Moose Development/Moose/Core/MarkerOps_Base.lua
#	Moose Development/Moose/Core/Menu.lua
#	Moose Development/Moose/Core/Message.lua
#	Moose Development/Moose/Core/Point.lua
#	Moose Development/Moose/Core/ScheduleDispatcher.lua
#	Moose Development/Moose/Core/Scheduler.lua
#	Moose Development/Moose/Core/Set.lua
#	Moose Development/Moose/Core/Spawn.lua
#	Moose Development/Moose/Core/Zone.lua
#	Moose Development/Moose/DCS.lua
#	Moose Development/Moose/Functional/Detection.lua
#	Moose Development/Moose/Functional/Mantis.lua
#	Moose Development/Moose/Functional/Range.lua
#	Moose Development/Moose/Functional/Scoring.lua
#	Moose Development/Moose/Functional/Sead.lua
#	Moose Development/Moose/Modules.lua
#	Moose Development/Moose/Ops/ATIS.lua
#	Moose Development/Moose/Ops/Airboss.lua
#	Moose Development/Moose/Sound/UserSound.lua
#	Moose Development/Moose/Utilities/Enums.lua
#	Moose Development/Moose/Utilities/FiFo.lua
#	Moose Development/Moose/Utilities/Profiler.lua
#	Moose Development/Moose/Utilities/Routines.lua
#	Moose Development/Moose/Utilities/STTS.lua
#	Moose Development/Moose/Utilities/Utils.lua
#	Moose Development/Moose/Wrapper/Airbase.lua
#	Moose Development/Moose/Wrapper/Controllable.lua
#	Moose Development/Moose/Wrapper/Group.lua
#	Moose Development/Moose/Wrapper/Marker.lua
#	Moose Development/Moose/Wrapper/Positionable.lua
#	Moose Development/Moose/Wrapper/Unit.lua
#	Moose Setup/Moose.files
2022-09-06 13:51:59 +02:00
Applevangelist
400da676fa UTILS 2022-09-06 10:48:37 +02:00
Applevangelist
bf9f02e53a DATABASE 2022-09-06 10:47:33 +02:00
Applevangelist
a437da76ec Merge remote-tracking branch 'origin/Apple/Develop' into develop
# Conflicts:
#	Moose Development/Moose/Core/Database.lua
#	Moose Development/Moose/Core/Set.lua
#	Moose Development/Moose/Utilities/Profiler.lua
2022-09-06 10:43:48 +02:00
Applevangelist
8cceee49ea Merge remote-tracking branch 'origin/master' into develop
# Conflicts:
#	Moose Development/Moose/AI/AI_A2A_Dispatcher.lua
#	Moose Development/Moose/AI/AI_A2G_Dispatcher.lua
#	Moose Development/Moose/AI/AI_CAP.lua
#	Moose Development/Moose/AI/AI_CAS.lua
#	Moose Development/Moose/AI/AI_Patrol.lua
#	Moose Development/Moose/Core/Base.lua
#	Moose Development/Moose/Core/Beacon.lua
#	Moose Development/Moose/Core/Database.lua
#	Moose Development/Moose/Core/Fsm.lua
#	Moose Development/Moose/Core/MarkerOps_Base.lua
#	Moose Development/Moose/Core/Menu.lua
#	Moose Development/Moose/Core/Message.lua
#	Moose Development/Moose/Core/Point.lua
#	Moose Development/Moose/Core/ScheduleDispatcher.lua
#	Moose Development/Moose/Core/Scheduler.lua
#	Moose Development/Moose/Core/Set.lua
#	Moose Development/Moose/Core/Spawn.lua
#	Moose Development/Moose/Core/Zone.lua
#	Moose Development/Moose/DCS.lua
#	Moose Development/Moose/Functional/Detection.lua
#	Moose Development/Moose/Functional/Mantis.lua
#	Moose Development/Moose/Functional/Range.lua
#	Moose Development/Moose/Functional/Scoring.lua
#	Moose Development/Moose/Functional/Sead.lua
#	Moose Development/Moose/Modules.lua
#	Moose Development/Moose/Ops/ATIS.lua
#	Moose Development/Moose/Ops/Airboss.lua
#	Moose Development/Moose/Sound/UserSound.lua
#	Moose Development/Moose/Utilities/Enums.lua
#	Moose Development/Moose/Utilities/FiFo.lua
#	Moose Development/Moose/Utilities/Profiler.lua
#	Moose Development/Moose/Utilities/Routines.lua
#	Moose Development/Moose/Utilities/STTS.lua
#	Moose Development/Moose/Utilities/Utils.lua
#	Moose Development/Moose/Wrapper/Airbase.lua
#	Moose Development/Moose/Wrapper/Controllable.lua
#	Moose Development/Moose/Wrapper/Group.lua
#	Moose Development/Moose/Wrapper/Marker.lua
#	Moose Development/Moose/Wrapper/Positionable.lua
#	Moose Development/Moose/Wrapper/Unit.lua
#	Moose Setup/Moose.files
2022-09-06 10:27:28 +02:00
Applevangelist
34ff03936a Merge remote-tracking branch 'origin/master' into develop
# Conflicts:
#	Moose Development/Moose/AI/AI_A2A_Dispatcher.lua
#	Moose Development/Moose/AI/AI_A2G_Dispatcher.lua
#	Moose Development/Moose/AI/AI_CAP.lua
#	Moose Development/Moose/AI/AI_CAS.lua
#	Moose Development/Moose/AI/AI_Patrol.lua
#	Moose Development/Moose/Core/Base.lua
#	Moose Development/Moose/Core/Beacon.lua
#	Moose Development/Moose/Core/Database.lua
#	Moose Development/Moose/Core/Fsm.lua
#	Moose Development/Moose/Core/MarkerOps_Base.lua
#	Moose Development/Moose/Core/Menu.lua
#	Moose Development/Moose/Core/Message.lua
#	Moose Development/Moose/Core/Point.lua
#	Moose Development/Moose/Core/ScheduleDispatcher.lua
#	Moose Development/Moose/Core/Scheduler.lua
#	Moose Development/Moose/Core/Set.lua
#	Moose Development/Moose/Core/Spawn.lua
#	Moose Development/Moose/Core/Zone.lua
#	Moose Development/Moose/DCS.lua
#	Moose Development/Moose/Functional/Detection.lua
#	Moose Development/Moose/Functional/Mantis.lua
#	Moose Development/Moose/Functional/Range.lua
#	Moose Development/Moose/Functional/Scoring.lua
#	Moose Development/Moose/Functional/Sead.lua
#	Moose Development/Moose/Modules.lua
#	Moose Development/Moose/Ops/ATIS.lua
#	Moose Development/Moose/Ops/Airboss.lua
#	Moose Development/Moose/Sound/UserSound.lua
#	Moose Development/Moose/Utilities/Enums.lua
#	Moose Development/Moose/Utilities/FiFo.lua
#	Moose Development/Moose/Utilities/Profiler.lua
#	Moose Development/Moose/Utilities/Routines.lua
#	Moose Development/Moose/Utilities/STTS.lua
#	Moose Development/Moose/Utilities/Utils.lua
#	Moose Development/Moose/Wrapper/Airbase.lua
#	Moose Development/Moose/Wrapper/Controllable.lua
#	Moose Development/Moose/Wrapper/Group.lua
#	Moose Development/Moose/Wrapper/Marker.lua
#	Moose Development/Moose/Wrapper/Positionable.lua
#	Moose Development/Moose/Wrapper/Unit.lua
#	Moose Setup/Moose.files
2022-09-06 09:53:22 +02:00
Thomas
bf3ee93c23 Update PlayerTask.lua (#1777) 2022-09-05 06:14:58 +02:00
Frank
a3260b4ce3 Merge pull request #1776 from FlightControl-Master/FF/Ops
OPS
2022-09-04 21:04:59 +02:00
Frank
ea8cf7b62a OPS
**OPSZONE**
- Added `:SetTimeCapture()` function to set time interval until a zone is captured.

**FLIGHTCONTROL**
- Added coalition to tower and pilot msrs.
2022-09-04 21:01:32 +02:00
Applevangelist
7168681918 #PLAYERTASKCONTROLLER
* Delay auto-start between 5 to 10 secs

#ATIS
* Add label to SRS
2022-09-04 14:48:06 +02:00
Applevangelist
233291b30c #AWACS
* added option for AWACS to send messages on multiple frequencies
2022-09-04 12:19:06 +02:00
Applevangelist
e53ff167ee #PLAYERTASKCONTROLLER
* Menu build changed slightly to delayed
2022-09-03 16:28:32 +02:00
dogjutsu
df54d09494 Fix usage example comment for ZONE_BASE:GetProperty() (#1775)
* Fixed some typos of forms of the word 'strategy'.

* Fix ZONE_BASE:GetProperty() usage example comment

Co-authored-by: dogjutsu <dogjutsu@mattjay.net>
2022-09-02 18:28:18 +02:00
Applevangelist
4aa3edc508 Errors
added docu
2022-09-02 17:01:39 +02:00
Applevangelist
4ea1b93f8d #PLAYERTASKCONTROLLER
* All map markers to be deleteable
2022-09-02 16:32:29 +02:00
Applevangelist
361ca2cece #MARKEROPS
* Added option to enforce case sensitive matches on Tagname

#PLAYERTASKCONTROLLER
* Text tweaking
* Fixed "mark on map" not showing subtitles
* Revamped menu build to have less rebuilds
* Added option to show additional info menu for tasks before joining
2022-09-02 13:12:52 +02:00
dogjutsu
fa0d076a09 Dogjutsu/develop/feature/zone properties (#1774)
* Fixed some typos of forms of the word 'strategy'.

* Retrieve Zone 'properties' with ZONE_BASE.

* Extraneous comment cleanup.

Co-authored-by: dogjutsu <dogjutsu@mattjay.net>
2022-09-02 06:19:50 +02:00
Frank
da5a1e0945 Merge pull request #1773 from FlightControl-Master/FF/Ops
Update Socket.lua
2022-09-01 23:50:04 +02:00
Frank
6d187f0d9a Update Socket.lua 2022-09-01 23:44:45 +02:00
Frank
85eca4c464 Merge pull request #1772 from FlightControl-Master/FF/Ops
SOCKET
2022-09-01 22:44:43 +02:00
Frank
1efbce7661 Update Airboss.lua
- Removed output
2022-09-01 22:37:31 +02:00
Frank
edf69d1ef1 Removed
Removed MOOSE_INCLUDE subdirectory
2022-09-01 22:34:48 +02:00
Frank
375e7db449 Merge branch 'develop' into FF/Ops 2022-09-01 22:31:52 +02:00
Frank
ac71e38d96 FunkMan
**RANGE**
- Changed keyword in result tables to "command" for compatibility with DCSServerBot

**AIRBOSS**
- Changed keyword in result tables to "command" for compatibility with DCSServerBot
- Fix bug in Alt and AoA data round function when creating trapsheet data

**SOCKET**
- Changed for compatibility with DCSServerBot
2022-09-01 22:27:25 +02:00
Applevangelist
ae5fd91cd4 #PLAYERTASK
* Fix to avoid double failed messages
2022-09-01 15:50:35 +02:00
Applevangelist
14e8b2ef17 #PLAYERTASK
* Added logging Errors and Documentation for trying to set zones before set up of detection
2022-09-01 09:22:18 +02:00
Applevangelist
5bacea8b50 UNIT - added optical tracker to HasSEAD() 2022-09-01 08:36:21 +02:00
Applevangelist
15dff87200 #GROUP
* Added Optical Tracker to ID SAMs, corrected logic error in ID'ing SAMs

#PLAYERTASKCONTROLLER
* Added documentation in MarkerOps
* Corrected Cluster radius to be in KM
* Corrected set up of SEAD attribute table to work
2022-09-01 08:07:40 +02:00
Applevangelist
ae45c77523 UTILS - added NDB 305kHz in frequency generator 2022-08-31 18:10:57 +02:00
Applevangelist
7c834993f6 Slight change of attack order 2022-08-31 17:40:15 +02:00
Applevangelist
5f5749ac8f bugfix 2022-08-31 17:32:41 +02:00
Thomas
c99a7b6666 PlayerTaskController - SEAD attributes configure (#1769)
Making SEAD attributes for the task decision tree configure-able. Added ` PLAYERTASKCONTROLLER:SetSEADAttributes(Attributes)`
2022-08-31 16:57:20 +02:00
Applevangelist
b4e2d3edfe #ZONE
* Added `ZONE_RADIUS:GetRandomCoordinateWithoutBuildings(...)`

#MARKEROPS
* Some documentation improvement

#PLAYTASKCONTROLLER
* Added `PLAYERTASKCONTROLLER:EnableMarkerOps(Tag)`

#OPSGROUP
* Changed offset to 2m for lasing ground units

*AUFTRAG
* Documentation correction `NewARMOREDGUARD`
2022-08-30 14:29:41 +02:00
Frank
8f9308f349 Update Airboss.lua 2022-08-29 23:10:12 +02:00
Frank
fc48473e40 Merge branch 'develop' into FF/Ops 2022-08-29 00:37:34 +02:00
Frank
71317db4cb FunkMan
**SOCKET**
- Changed port to 10042.
- Removed port as optional parameter in functions.

**AIRBOSS**
- Added FunkMan function
- Added onAfterLSOGrade which sends results table to socket

**RANGE**
- Compat to FunkMan.
2022-08-29 00:37:21 +02:00
Applevangelist
23815429e2 #PLAYERTASK
* remove two filters for task state where they do not belong
2022-08-27 18:26:04 +02:00
Applevangelist
b468134432 #PLAYERTASK
* Remove filtering for task state preventing further players to join
2022-08-27 16:05:47 +02:00
Applevangelist
3e38db16f6 #PLAYERTASK
* Added option to use ArmyGroup as lasing unit
* Added TTS output to task info report for PRECISIONBOMBING to tell if unit is in reach and is lasing
2022-08-26 18:46:07 +02:00
Applevangelist
bf591cc01e #RANGE
* Minor updates

#AWACS
* Added localisation
2022-08-26 14:23:55 +02:00
Applevangelist
3178cbc563 #RANGE
- fix for #1753
2022-08-25 16:00:03 +02:00
Applevangelist
1c54f6b2f4 #AUTOLASE
* Fix for "self" error after start
2022-08-25 13:28:20 +02:00
Applevangelist
7743456d7d #PLAYERTASK
* Short playername usage for broadcast
2022-08-25 12:10:20 +02:00
Applevangelist
4dc43263a5 usage correction 2022-08-25 11:41:27 +02:00
Applevangelist
5d84f1c523 #AIRBASE
* Added 3 new airports to the enumerator
2022-08-25 10:38:04 +02:00
Applevangelist
8289ebbe50 #PLAYERTASK
* added coalition check to event handler
2022-08-25 09:44:45 +02:00
Applevangelist
94741f1b4a #PLAYERTASK
* Added precision bombing option

#AUTOLASE
* Added "nomenu" option

#MENU_GROUP
* Added MENU_GROUP:RefreshAndOrderByTag()
2022-08-24 19:22:33 +02:00
Applevangelist
a5b394aa93 #AWACS
- added docu on PikesSpecialSwitch
- added option to read callsign from playername
2022-08-23 12:44:42 +02:00
Applevangelist
9f3d152d8c #AWACS
* Fixed logic for CallSignTranslations which now applies to both AI and Players, a set overwrite in the group name for a player still takes precedence.
* Added a switch self.PikesSpecialSwitch to omit "doing xy knots" from the station assignment
2022-08-23 09:58:06 +02:00
Applevangelist
94c91614d6 #Range
* Fix F10 Sheet
* Fix Typos
2022-08-22 17:28:01 +02:00
Applevangelist
02a59b0742 #UTILS
* Fix for GetOSTime
2022-08-22 17:05:02 +02:00
Applevangelist
882c2e2378 #ATC_GROUND
* Added universally working ATC_GROUND_UNIVERSAL as base class, can be used on any map without further changes
* Kept sub-class names for compatibility
* Added `:SetAirbaseBoundaries(Airbase, Zone)`
* Added `:DrawBoundaries( Color )`
2022-08-21 19:46:01 +02:00
Applevangelist
f6b56735b6 #PLAYERTASK
* Speak "BR" as "Bee, Arr"
2022-08-20 09:45:09 +02:00
Applevangelist
8aec463eb4 #PLAYERTASK
* Some changes to SRS call order, documentation
2022-08-20 09:24:52 +02:00
Applevangelist
37cdcf93e6 #PLAYERTASK
* Demo mission link added
2022-08-19 10:34:36 +02:00
Applevangelist
9547a06f39 #PLAYERTASK
* Slight text change for TASKADDED
2022-08-19 08:12:06 +02:00
Applevangelist
a8d5d2ace1 fix typos 2022-08-18 18:24:37 +02:00
Applevangelist
e8a0464f6c Docu corrections 2022-08-18 18:19:27 +02:00
Applevangelist
85a39e64c1 #PLAYERTASKCONTROLLER
* Own picture for header
* Some docu additions
2022-08-18 18:06:41 +02:00
Applevangelist
e18cf759f9 #PLAYERTASKCONTROLLER
* Add'l docu
2022-08-18 16:43:39 +02:00
Applevangelist
7e1ab1e6b0 #PLAYERTASKCONTROLLER
* Added base documentation
2022-08-18 16:01:34 +02:00
Frank
eed74d72cd SOCKEt
- Added new SOCKET class
- Fixed bug in RANGE that self.PlayerSetti**n**gs was misspelled.
2022-08-18 01:33:09 +02:00
Applevangelist
fa8c96af13 #AUTOLASE
* Update SRS stuff

#PLAYERTASKCONTROLLER
* Fix SRS to actually use Gender, Culture, Voice, Port
2022-08-17 17:33:29 +02:00
Applevangelist
18ec2ff458 #PLAYERTASK
* Corrected usage example on `SetTaskWhiteList()`
* Mark on map will add some basic info text
2022-08-17 16:23:37 +02:00
Applevangelist
c38a737421 #PLAYERTASK
* Added option to whitelist task types
* Added localization. Contains "en" and "de" texts and tts texts
2022-08-17 15:38:20 +02:00
Applevangelist
0166b53e21 #PLAYERTASKCONTROLLER
* Added option to suppress screen output
* Added target information via SRS
* Added target radius for BAI vs CAS and target type COORDINATE to be configureable
* Refined SRS output
* Added STATIC targets to get task type BOMBING
* Added solution to detect bombing runways (kind of, bombing occuring in AFB zone)
* Added solution for COORDINATE and ZONE type TARGETs (find enemy GROUP and/or STATIC objects in target radius)
* Refined documentation
2022-08-16 16:48:13 +02:00
Applevangelist
724da4e500 #PLAYERTASKCONTROLLER
* Added Accept and Reject Zones to detection
* Added SRS Stuff
* Tasks sorted by priority
2022-08-15 19:07:05 +02:00
Applevangelist
ce15e8dfe0 #PLAYERTASKCONTROLLER
* Set menu name
* Better menu buildup and refresh
2022-08-15 13:11:09 +02:00
Applevangelist
b968d0d694 #PLAYERTASKCONTROLLER
* Added detection setup
* Added number of joined players in join task overview, and a star when it's new
2022-08-14 16:50:57 +02:00
Frank
fa0549f34f Merge pull request #1756 from FlightControl-Master/FF/Ops
Update Airboss.lua
2022-08-04 22:13:18 +02:00
Frank
999ef36963 Update Airboss.lua
#1755
2022-08-04 21:18:38 +02:00
Frank
7affd05247 Merge pull request #1754 from FlightControl-Master/FF/Ops
Updates
2022-08-03 09:14:12 +02:00
Frank
2ccf4011ed Merge branch 'develop' into FF/Ops 2022-08-03 09:12:32 +02:00
Frank
61f3908d33 Updates
**AIRBOSS**
- Stennis now takes dimensions of other super carriers

**FLIGHTCONTROL**
- Added queue for sounds
- Fixed bugs and minor improvements

**ZONE**
- Added defaults when getting colors if not set

**SRS**
- Added new class `MSRSQUEUE`
2022-08-03 09:12:22 +02:00
Applevangelist
08e429210a Update Unit.lua 2022-07-31 09:16:46 +02:00
Frank
f94944c41a Merge pull request #1750 from FlightControl-Master/FF/Ops
ZONE
2022-07-31 01:16:55 +02:00
Frank
200631e57e Merge branch 'develop' into FF/Ops 2022-07-31 01:13:53 +02:00
Frank
9c83d5e752 ZONE
- Added new class `ZONE_ELASTIC`
2022-07-31 01:13:42 +02:00
Applevangelist
894bff2e35 PLAYERTASK - added list of pilots to TaskInfo 2022-07-30 12:26:29 +02:00
Applevangelist
6ff0a699c0 #PLAYERTASKCONTROLLER
* Added Event handling stuff in case client leaves/ejects/dies
* A2A - removed menus for smoke/flare
* Task menu entries now refreshed more intelligently
* Added `PLAYERTASKCONTROLLER:OnAfterTaskAdded(From, Event, To, Task)`
2022-07-30 12:06:11 +02:00
Frank
5083428a06 Merge branch 'develop' into FF/Ops 2022-07-30 01:24:52 +02:00
Applevangelist
c74a14fcb0 PLAYERTASK - debugging 2022-07-29 15:31:56 +02:00
Applevangelist
d060c7535a PLAYERTASK - added a couple of FSM events so task events bubble up to the controller 2022-07-29 14:53:23 +02:00
Applevangelist
5eb134f7b5 PLAYERTASK - Additions 2022-07-29 14:14:22 +02:00
Applevangelist
c1c5117f01 Update Moose.files (#1749) 2022-07-29 12:25:45 +02:00
Applevangelist
8ce1f5884f PlayerTask Beta 2022-07-29 12:24:36 +02:00
Applevangelist
1f8b51fafe SET - fix for dead units 2022-07-29 08:51:00 +02:00
Applevangelist
80f73f0bb1 AUTOLASE - added per player settings observance, also 2022-07-27 19:41:20 +02:00
Applevangelist
88e7b3fb47 AUTOLASE - observe global _SETTINGS for coordinates 2022-07-27 19:28:36 +02:00
Frank
3bb36044c1 OPS
- Added check that cohorts cannot have the same name.
- Made clearer that cohorts cannot have the same name in the docs.
2022-07-25 22:45:43 +02:00
Applevangelist
f9ace54fab UNIT - added get altitude function with AGL option 2022-07-25 08:12:10 +02:00
Applevangelist
498d7e2f66 Airbase - added 2 AFB to SA map 2022-07-22 11:02:08 +02:00
Frank
420526df9d Merge pull request #1747 from FlightControl-Master/FF/Ops
OPS
2022-07-20 22:58:57 +02:00
Frank
ab00d9534d Merge branch 'develop' into FF/Ops 2022-07-20 22:21:17 +02:00
Frank
4bb9073ce1 OPS
- Increased selection score for GCICAP/INTERCEPT
2022-07-20 22:20:26 +02:00
Applevangelist
58cb0118b4 AWACS - added option for custom TTS callsigns 2022-07-19 09:34:40 +02:00
Applevangelist
f19740e376 Beacon - added deactivate Link4 2022-07-19 08:30:09 +02:00
Applevangelist
ab50d0a514 Controllable/Beacon - added function to switch on Link4
A2A - typo in documentation
2022-07-19 08:10:35 +02:00
Frank
e551212516 Merge branch 'develop' into FF/OpsDev 2022-07-18 23:00:01 +02:00
Frank
888734b7d1 OPS
- Fixed bug in parking spot distance for ships.
- Added enroute  anti-ship task for anti-ship missions.
2022-07-18 22:59:49 +02:00
Applevangelist
90d1a01998 AWACS - delete open tasks on player leaving unit 2022-07-14 14:06:20 +02:00
Anthony De Vellis
ab1dd2b374 AWACS - Tweaked escort logic to use one AUFTRAG per escort fighter and tweaked positioning logic. Allows more control over escort fighters which will support a future PR (#1746) 2022-07-12 08:18:47 +02:00
Anthony De Vellis
0e4d731068 AWACS - added the ability to use custom callsigns with TTS/messaging (#1745)
* AWACS - added the ability to use custom callsigns with TTS. Revised section 5.1 of documentation to demonstrate

* AWACS - Added nil check to callsign construction when looking for replacement
2022-07-12 08:13:24 +02:00
Frank
f23416dfb8 Merge branch 'develop' into FF/OpsDev 2022-07-11 23:23:11 +02:00
Frank
469cc3d508 OPS
CHIEF: SetResponseOnTarget
TRANSPORT: improved transfer of loaded cargo
2022-07-11 23:22:58 +02:00
Applevangelist
5ad88be997 AWACS - change setup as TACS slightly 2022-07-09 15:34:08 +02:00
Applevangelist
536341b6de AWACS allow startasgci to process a string instead of a GROUP 2022-07-09 15:02:14 +02:00
Applevangelist
18dcd0a5d2 AWACS - some additions 2022-07-09 14:52:49 +02:00
Applevangelist
5f8a0643f4 AWACS - added GCI plane-less option 2022-07-07 17:55:35 +02:00
Applevangelist
ccbf8b34ef Fix for #1736 2022-07-07 08:51:28 +02:00
Applevangelist
25915c077e Various fixes 2022-07-07 08:47:43 +02:00
Frank
bcb574e618 Merge branch 'develop' into FF/OpsDev 2022-07-01 23:19:02 +02:00
Frank
6cfa24340f Update Range.lua
- Fixed bug in strafing runs
2022-07-01 23:10:10 +02:00
Frank
0dc26216c2 OPS 2022-07-01 23:00:25 +02:00
Frank
8dd850d685 OPS Operation 2022-06-29 22:25:08 +02:00
Frank
638f261bf4 OPS
- Improved FLIGHTCONTROL and minor other classes
2022-06-28 18:55:43 +02:00
Applevangelist
ad5a0a5cd9 CSAR - hand back descriptive name as 3rd parameter on event Boarded() 2022-06-25 17:24:37 +02:00
Applevangelist
7dda54f36d UTILS - Fix for Gazelle Door Check 2022-06-25 14:28:04 +02:00
Frank
a8477940e2 Merge branch 'FF/Ops' into FF/OpsDev 2022-06-21 16:15:03 +02:00
Frank
6a26f62ca1 Merge branch 'develop' into FF/Ops 2022-06-21 16:14:31 +02:00
Frank
06d0bfadca FLIGHTCONTROL v0.6.0 2022-06-21 16:08:46 +02:00
Applevangelist
b805d7fe19 CSAR - fix for oncrash 2022-06-16 15:42:13 +02:00
Applevangelist
b784671397 CSAR - added event for "Landed" at a friendly/neutral AFB. Fixed Airbase rescue. 2022-06-16 13:40:35 +02:00
Applevangelist
4784a31513 UTILS - Falklands additions 2022-06-14 17:20:12 +02:00
Applevangelist
3eb9bfe9ee COORDINATE - additions to BRAANATO
AWACS - make bogey dope use the priority queue to avoid collisions. Say "very low" and not "zero thousand", drop "vanished" if not tags is requested
2022-06-14 13:08:18 +02:00
Applevangelist
ab31aecdac CSAR - some fixes for latest open beta 2022-06-14 12:37:56 +02:00
Applevangelist
5cb2bd1332 Update Beacon.lua 2022-06-13 15:41:19 +02:00
Applevangelist
8bff9efc5c Beacon - update docs (#1733)
Updated docs to point to ActivateTacan as better option to AAATACAN
2022-06-13 15:21:50 +02:00
Applevangelist
d01360ca19 CSAR - Put wounded group back into status green, so they run to the chopper 2022-06-12 12:47:10 +02:00
Applevangelist
f48c71f30c AWACS - Added option to use marker to create, move and delete a player station 2022-06-10 11:56:19 +02:00
Applevangelist
a2b3190b1d More docu 2022-06-09 12:12:45 +02:00
Applevangelist
913d5a532d CTLD - further documentation 2022-06-09 11:46:17 +02:00
Applevangelist
96c6c372fd Added documentation for CTLD_HERCULES 2022-06-09 10:56:33 +02:00
Frank
8926e06e44 Runways
**AIRBASE**
- Runways are now retrieved from DCS API function
2022-06-08 23:42:17 +02:00
Applevangelist
6636e89a0b AIRBASE added South Atlantic 2022-06-08 20:24:31 +02:00
Applevangelist
01e9e83641 AWACS - PlayerGuidance makes picture calls refer to asking player BRA, delete contact engagement label on checking out 2022-06-07 11:30:20 +02:00
Applevangelist
30dc338636 CSAR - added a couple of more lines to go out via TTS 2022-06-07 08:56:25 +02:00
Applevangelist
d4999de214 CSAR - added options to use Google TTS 2022-06-07 08:12:57 +02:00
Frank
a53595a055 OPS
Enhanced OPERATION and FLIGHTCONTROL features.
2022-06-06 22:05:57 +02:00
Applevangelist
0cb7415a4c AWACS -- enforce EPLRS 2022-06-05 18:03:39 +02:00
Applevangelist
9f287d0d7f AWACS 0.1.27
* Added options for NoMissileCals and PlayerCapAssignment
* Added documentation on options
2022-06-04 13:56:57 +02:00
Applevangelist
feddda2948 AWACS - added docu for speech queue padding options 2022-06-03 14:42:08 +02:00
Applevangelist
613b7eda8a AWACS 0.1.26 - corrected player picture call to use B/E references, bogey dope to announce only one group. ZipLip will also remove group tags. 2022-06-03 09:27:01 +02:00
Applevangelist
bd3364a3cf AWACS - limit merge calls 2022-06-02 17:39:39 +02:00
Applevangelist
3f918bd309 AWACS 0.1.25
* Added Function ZipLip
* Changed merge distance to 5nm for account for delay in speech generation
* Altered RadioQueue to not save all calls until a player connects
* Some bugfixes
2022-06-02 15:31:03 +02:00
Frank
9b3f2ae3c7 OPS 2022-05-31 22:54:37 +02:00
Applevangelist
6c33c5701f Awacs 2022-05-31 16:21:19 +02:00
Applevangelist
e731fe9b98 AWACS 0.1.24 - Added merge call, google now says "zero" not "oh", aligned some callouts to more realistic versions, bulls related calls without aspect now. 2022-05-31 14:02:14 +02:00
Frank
edbfa9117d OPS
- Added new **CONDITION** class
- Added new **OPERATION** class
2022-05-30 11:45:56 +02:00
Frank
ae54cd8fde OPS
** ARMYGROUP**
- Added suppression option

**COMMANDER**
- Added function to add targets with defined resources

**OPSGROUP**
- Added option to pause multiple missions

**INTEL**
- Fixed bug in cluster calc

**LEGION**
- Added function to get alive opsgroups

**TARGET**
* Added start condition
2022-05-27 22:14:21 +02:00
Applevangelist
91686e252c AWACS FSM Functions Docu 2022-05-24 16:05:04 +02:00
Applevangelist
88d132931e AWACS - Nicefy docs 2022-05-24 14:44:23 +02:00
Applevangelist
4afedcf126 AWACS - added documentation, added option to suppress group tags 2022-05-24 14:04:52 +02:00
Frank
d3d815f26a Merge branch 'FF/Ops' into FF/OpsDev 2022-05-23 23:11:37 +02:00
Frank
62725b1930 OPS
**AUFTRAG**
- Added *invisible* and *immortal* options

**TARGET**
- Added `AddResource` function

**OPSGROUP**
- Added *invisible* and *immortal* options

**LEGION**
- Fixed bug in properties requirement

**COMMANDER**
- Added `AddTarget` function (still **WIP**)

**ARMYGROUP**
- Fixed routing bug after teleporting
2022-05-23 23:11:23 +02:00
Frank
06d509b5ac Update Airboss.lua
- Improved Case III entry waypoint
2022-05-22 22:36:43 +02:00
Applevangelist
77aba38625 AWACS - added docu 2022-05-22 17:14:14 +02:00
Applevangelist
ce33e1d242 AWACS - Options to Draw Zones 2022-05-22 13:03:38 +02:00
Applevangelist
591cf29edf Update README.md 2022-05-22 11:17:20 +02:00
Frank
dd81823e29 FC
**FLIGHTCONTROL**
- Less output to dcs log file

**FLIGHTGROUP**
- Added function :SetReadyForTakeoff
2022-05-21 22:25:08 +02:00
Frank
15994e7be8 FC
- Changed holding point to holding pattern or stack
- Replaced MESSAGE by TextMessageToFlight
2022-05-20 20:53:45 +02:00
Frank
61f3b87dae Update Airboss.lua
- Wind is calculated at 15 m (not 50 m)
2022-05-20 20:15:11 +02:00
Frank
6279f1920e FC
**FLIGHTCONTROL**
- Improved menus
- Added more menus
- Improved radio messages overlap
- Added options to limit number of fights taxiing and taking off
2022-05-20 20:08:28 +02:00
Applevangelist
d169d60d8d AWACS BETA 0.1.22 - added some QOL functions, corrected standard TOS for AWACS and CAP, now 4 hours. 2022-05-20 19:31:11 +02:00
Applevangelist
f49cf43fb1 Awacs - Documentation 2022-05-20 16:19:51 +02:00
Applevangelist
aa94ae8759 AWACS moving to beta 1.22 - added documentation, some fixes 2022-05-20 15:51:54 +02:00
Applevangelist
8ad20b57fd TARGET - small typo 2022-05-19 14:41:06 +02:00
Frank
7c4cb5ea7f FC
- Improvements
2022-05-18 12:51:25 +02:00
Frank
23733bb1a6 Merge branch 'FF/Ops' into FF/OpsDev 2022-05-17 23:00:29 +02:00
Frank
5be3f333f3 Merge pull request #1731 from FlightControl-Master/FF/Ops
OPS
2022-05-17 22:53:10 +02:00
Frank
b14f3f53aa Merge branch 'develop' into FF/Ops 2022-05-17 22:51:02 +02:00
Frank
47c3fc35e3 OPS
**OPSGROUP**
- Improved routing for ground.

**NAVYGROUP**
- Fixed U-turn of turn into wind

**ARMYGROUP**
- Improved updateroute

**LEGION** and **COMMANDER**
- Set mission range LARGE for relocation mission

**AUFTRAG**
- Fixed bug in Nassets for relocation
2022-05-17 22:50:35 +02:00
Applevangelist
0fd1497496 AWACS 0.0.19 2022-05-15 12:49:36 +02:00
Applevangelist
6c9c983f72 Positionable - added 6 passengers (cargo weight) to Toyota HL/LC new with 2.7.2 OB 2022-05-14 13:11:17 +02:00
Applevangelist
0422eee9af SRS - added hints on using Google with TTS 2022-05-13 16:38:10 +02:00
Frank
97a4b79713 OPS FC
- Improved holding point
2022-05-12 21:19:55 +02:00
Applevangelist
0785ee3099 Point - added option to add an SSML tag to ToStringBRAANATO
AWACS - 0.0.18
2022-05-12 14:48:56 +02:00
Frank
d58d04d6a0 Merge branch 'FF/Ops' into FF/OpsDev 2022-05-12 11:04:13 +02:00
Frank
9bb2b17c77 Merge pull request #1730 from FlightControl-Master/FF/Ops
OPS
2022-05-12 10:50:47 +02:00
Frank
64e70d8e92 OPSGROUP
- #1677
- Fixed that damaged is triggered when group is despawned.
- Fixed total ammo calculation when group is dead
- Fixed assets do not carry out patrol zone after transport
2022-05-12 10:49:18 +02:00
Frank
6fa9eb558a Merge branch 'develop' into FF/Ops 2022-05-12 08:03:25 +02:00
Frank
ddcc851951 FC
- Improved FC
2022-05-12 08:03:08 +02:00
Applevangelist
dc2e5afe3e SRS - put volume in "" - just in case 2022-05-11 07:30:39 +02:00
Applevangelist
d8e9997987 SRS - actually pass the volume to the command line 2022-05-11 06:18:48 +02:00
Applevangelist
3d919cd937 AIRBASE - corrected ["Deir_ez_Zor"] = "Deir ez-Zor" (minus doesn't work in enum) 2022-05-10 19:40:44 +02:00
Applevangelist
b094c2d78f Correct link to demo missions 2022-05-10 16:17:46 +02:00
Applevangelist
9b699ba374 Update AI_Air.lua 2022-05-10 10:11:25 +02:00
Frank
f8e5efc874 Merge branch 'develop' into FF/Ops 2022-05-09 08:41:55 +02:00
Frank
2c61c695d5 Update Chief.lua
- Added target in zone check to abort missions
2022-05-09 08:41:33 +02:00
Frank
b6e806adbc Update FlightGroup.lua
-No despawn after player landed.
2022-05-08 00:29:36 +02:00
Applevangelist
e74aa160af Group - small change 2022-05-07 19:42:10 +02:00
Clément Fassot
6793228fbe Add an option to display arrows if clusters are moving (#1728) 2022-05-07 15:32:48 +02:00
Applevangelist
e83ea8124e GROUP - change to GetUnits(n) to make it more robust, now returns first alive unit,actually. Similar changes to GetHeading() 2022-05-07 11:54:48 +02:00
Frank
313f99d09d OPS
**AUFTRAG**
- Added option to specify mission type for escorts, *e.g.* `AUFTRAG.Type.SEAD`

**LEGION** and **COMMANDER**
- Improved handling of SEAD escorts.
2022-05-06 21:50:23 +02:00
Applevangelist
28de292107 ##AWACS Alpha 0.0.17
* Added RejectZone (foreign border)
* Option to suppress screen output
* Option to add google key in SetSRS
* Some corrections to callouts
* Menu option to show base info
* WIP - Basic player task assignment
2022-05-06 16:36:57 +02:00
Applevangelist
10efb98eb3 Fallout fixes 2022-05-06 11:44:59 +02:00
Applevangelist
8ac2241372 AI Patrol - life check on route 2022-05-06 10:36:51 +02:00
Applevangelist
092434a103 UNIT Register - small fix for trains 2022-05-06 08:01:18 +02:00
Applevangelist
a777997f79 AI_CAP - more fallout from the dead units in the API 2022-05-05 17:40:17 +02:00
Applevangelist
36cf7f718b AI_AIR - restrict AB on RTB 2022-05-05 16:41:15 +02:00
Applevangelist
7989267d51 AI/ZONE - Some fixes for units unreachable 2022-05-05 12:08:43 +02:00
Applevangelist
ef4398a5f1 SRS - adding volume setting and a test on OS and IO available
OpsGroup - added volume options for `SetSRS`
2022-05-05 11:35:27 +02:00
Applevangelist
0da8afc108 SRS - adding volume setting and a test on OS and IO available 2022-05-05 08:57:15 +02:00
Frank
0e74d36227 Update Range.lua
**RANGE** v2.4.0
- Copy from updated
2022-05-04 22:40:22 +02:00
Applevangelist
290cc151bc SET - further event related stuff not working any more
AWACS - update
2022-05-04 18:10:20 +02:00
Applevangelist
21f93aa7e8 AWACS - 0.0.12 2022-05-04 13:29:14 +02:00
Applevangelist
04c77e9760 Some fixes to make the SpawnScheduled work again 2022-05-04 09:58:30 +02:00
Frank
c6da6544da Merge pull request #1725 from FlightControl-Master/FF/Ops
Dead Event
2022-05-04 09:49:37 +02:00
Frank
94d3e38bc7 Merge branch 'develop' into FF/Ops 2022-05-04 09:47:30 +02:00
Frank
5fcf992920 Dead Event
**EVENT**
- Improved handling of delayed dead event

**SPAWN**
- Improved handling of delayed dead event
2022-05-04 09:46:00 +02:00
Frank
22cc9eabc0 Merge pull request #1724 from Ked57/develop
Replace log MESSAGE when updating cluster markers in INTEL with a log
2022-05-03 23:31:15 +02:00
Clément Fassot
b191c0d341 Replace log MESSAGE when updating cluster markers in INTEL with a log (#1) 2022-05-03 23:08:26 +02:00
Frank
d2d431ce2e OPS (#1723)
**INTEL**
- Added nil check for cluster position update

**OPSGROUP**
- Improved fire at point task to take only max avail shots and relative shot amount
- Fixed tasks not executed after teleport
2022-05-03 09:41:22 +02:00
Frank
3a6b58ea8c Merge branch 'develop' into FF/Ops 2022-05-03 09:25:15 +02:00
Frank
2d8fc40307 OPS
**INTEL**
- Added nil check for cluster position update

**OPSGROUP**
- Improved fire at point task to take only max avail shots and relative shot amount
- Fixed tasks not executed after teleport
2022-05-03 09:23:53 +02:00
Applevangelist
68dce2f247 extra nil checks for dead units 2022-05-03 08:46:23 +02:00
Applevangelist
bc03eb2e65 FIFO - FIFO:HasUniqueID(UniqueID)
GROUP - added GROUP:IsPlayer()
INTEL - added clustering by flight deck (10'k ft) for AIR
SET - added option to NOT set the cargo bay weight limit automatically on SET_GROUP:AddGroup( group, DontSetCargoBayLimit )
2022-05-02 17:18:48 +02:00
Frank
f725709e5b Merge pull request #1721 from FlightControl-Master/FF/Ops
OPS
2022-04-29 22:02:24 +02:00
Frank
ba591c9dc5 OPS
**AUFTRAG**
- Added new type `NOTHING` (similar to `ALERT5` but for ground/naval)
2022-04-29 22:00:23 +02:00
Applevangelist
def5d33055 GROUP - making GetCoordinate() a bit more resilient
POINT - slight changes to ToStringBRAANATO
2022-04-29 18:48:27 +02:00
Applevangelist
1aaa51c4be COORDINATE - added bogey option to COORDINATE:ToStringBRAANATO(FromCoordinate,Bogey,Spades) 2022-04-29 12:19:06 +02:00
Applevangelist
37206bcc83 Range - added nil check for playerData 2022-04-29 12:10:16 +02:00
Frank
c2b86bac4b Update Airboss.lua
- Fixed DATABASE:GetFlightGroup to DATABASE:GetOpsGroup
2022-04-28 20:52:47 +02:00
Frank
02dad179cd Recovery tanker 2022-04-28 20:50:30 +02:00
Applevangelist
adb94f8773 Nicefy docs 2022-04-28 17:10:49 +02:00
Applevangelist
035110df75 AWACS - removed banner from docs 2022-04-28 16:48:24 +02:00
Applevangelist
5adb65899c USERSOUND - added USERSOUND:ToUnit() 2022-04-28 16:48:07 +02:00
Applevangelist
764a373e7d POSITIONABLE - added POSITIONABLE:MessageToUnit(), and :MessageToSetUnit() 2022-04-28 16:47:42 +02:00
Applevangelist
8114327c7e MESSAGE - added MESSAGE:ToUnit(), altered MESSAGE:ToClient() to message the unit only 2022-04-28 16:46:28 +02:00
Applevangelist
6404417dad luacheck barking 2022-04-28 13:48:48 +02:00
Applevangelist
d89cb8f1e9 Added Awacs WIP to working tree, Enums - corrected Hawkeye, added Super_Hercules 2022-04-28 13:11:04 +02:00
Applevangelist
dee95c2f08 Update Moose.files 2022-04-28 13:04:22 +02:00
Frank
3a907ec7c2 Merge pull request #1720 from FlightControl-Master/FF/Ops
Ff/ops
2022-04-28 09:19:01 +02:00
Frank
851dff6e8c Update Intelligence.lua
- Added function to add detection group
- Added functions to retrieve contact details
2022-04-28 09:17:33 +02:00
Frank
47e7364976 Merge branch 'develop' into FF/Ops 2022-04-27 22:46:36 +02:00
Frank
41f8207b3a Merge pull request #1719 from FlightControl-Master/FF/Ops
**CHIEF**
- Added resources as parameters to `:AddStrategicZone` function

**COMMANDER**
- Added function to relocate cohorts `:RelocateCohort`

**AUFTRAG**
- Added new type `AIRDEFENSE`
- Added new type `EWR`
- Added option to teleport assets to the mission ingress waypoint via `:SetTeleport`
- Added `:SetRequiredAttribute` and `:SetRequiredProperty` functions
- Added `:SetEmission` function

**LEGION**
- Fixed bug that assets on GCI dont get additional score for INTERCEPT missions
- Assets on ONGUARD or PATROLZONE are not considered for ARTY and GROUNDATTACK missions
- Added option for transport to `RelocateCohort` function
- Ground/naval assets now automatically return when out of ammo

**OPSGROUP**
- Immobile groups are teleported to mission ingress point

**RECOVERYTANKER**
- Added parameter to set TACAN mode/band (e.g. "X")

**GROUP**
- Fixed bug in `:GetSpeedMax` function

**BEACON**
- Allowed TACAN "X" mode for AA
2022-04-27 22:38:34 +02:00
Frank
ed0a3a22ab OPS
**CHIEF**
- Added resources as parameters to `:AddStrategicZone` function

**COMMANDER**
- Added function to relocate cohorts `:RelocateCohort`

**AUFTRAG**
- Added new type `AIRDEFENSE`
- Added new type `EWR`
- Added option to teleport assets to the mission ingress waypoint via `:SetTeleport`
- Added `:SetRequiredAttribute` and `:SetRequiredProperty` functions
- Added `:SetEmission` function

**LEGION**
- Fixed bug that assets on GCI dont get additional score for INTERCEPT missions
- Assets on ONGUARD or PATROLZONE are not considered for ARTY and GROUNDATTACK missions
- Added option for transport to `RelocateCohort` function
- Ground/naval assets now automatically return when out of ammo

**OPSGROUP**
- Immobile groups are teleported to mission ingress point

**RECOVERYTANKER**
- Added parameter to set TACAN mode/band (e.g. "X")

**GROUP**
- Fixed bug in `:GetSpeedMax` function

**BEACON**
- Allowed TACAN "X" mode for AA
2022-04-27 22:36:13 +02:00
Applevangelist
3a513da942 Awacs next Alpha 2022-04-27 14:37:38 +02:00
Applevangelist
a4f1c60da2 Enums - added a couple of names 2022-04-26 10:09:05 +02:00
Applevangelist
de0bf7d814 typo 2022-04-25 10:36:10 +02:00
Applevangelist
71fd72e462 adding ZONE_POLYGON_BASE:IsVec3InZone( Vec3 ) (might be called from POSITIONABLE), closes gap for GROUP/UNIT:IsInZone(Zone_Polygon)
GROUP - better docu
2022-04-25 09:59:44 +02:00
Applevangelist
619cc3c047 various 2022-04-24 19:11:08 +02:00
Applevangelist
68c75a4e34 Menu Refresh cleanup 2022-04-24 14:06:24 +02:00
Applevangelist
37671cefa3 GROUP - overwrite GetHeight() inherited from POSITIONABLE with something that is actually working for groups 2022-04-24 13:50:23 +02:00
Applevangelist
d9f409069a INTEL - add platform type for AIR contacts (Foxbat ... ), defaults to Bogey for AIR and Unknown for everything else
SRS- added option to set a label for the SRS radio overlay
OpsGroup - added options to use said label, and option to override a frequency for an SRS (TTS) sender
2022-04-24 12:46:11 +02:00
Applevangelist
fd5a190490 AWACS Alpha 2022-04-23 18:58:27 +02:00
Applevangelist
2f4d5b32b6 GROUP/UNIT - added :GetNatoReportingName() 2022-04-23 16:41:47 +02:00
Applevangelist
4c7ac68858 UTILS - UTILS.GetReportingName(Typename)
ENUMS - added ENUMS.ReportingName
2022-04-23 15:09:02 +02:00
Applevangelist
ad3a3c5266 AWACS a0.0.7 - cleaned up AWACS calls, implemented DECLARE 2022-04-22 20:34:24 +02:00
Applevangelist
51d924c1b8 BRAANato - make bearing a 3digit number 2022-04-22 13:32:34 +02:00
Applevangelist
83491f535a Point - BRAANATO - will return BRA only if no aspect can be generated 2022-04-21 18:56:51 +02:00
Applevangelist
380731a244 AWACS 0.0.6 2022-04-21 18:56:09 +02:00
Applevangelist
60c78da0f6 Utils/Point - Corrections 2022-04-21 12:56:40 +02:00
Frank
2d02f4f962 Merge branch 'develop' into FF/Ops 2022-04-21 08:40:45 +02:00
Frank
982bd89924 Merge branch 'develop' into FF/Ops 2022-04-20 22:03:24 +02:00
Frank
04f60747d9 Merge pull request #1716 from FlightControl-Master/FF/Ops
OPS
2022-04-20 21:51:09 +02:00
Frank
28c107b089 OPS
**AIRWING**
- Added option to start in air `:SetTakeoffAir()`
- Added option to despawn near airbase `:SetDespawnAfterHolding()`
- Added option to despawn after landing `:SetDepawnAfterLanding()`

**SQUADRON**
- Added option to start in air `:SetTakeoffAir()`
- Added option to despawn near airbase `:SetDespawnAfterHolding()`
- Added option to despawn after landing `:SetDepawnAfterLanding()`
- Squadron settings overrule Airwing settings

**OPSGROUP**
- Improved `:Teleport()` function
2022-04-20 21:48:03 +02:00
Applevangelist
e6cc8757ac Utils typo 2022-04-20 19:14:19 +02:00
Applevangelist
9169bfc608 COORDINATE - Added Precision to GetDistanceText as an option 2022-04-20 19:04:37 +02:00
Applevangelist
610e33e4a4 COORDINATE - added ToStringBRAANATO (works hopfully ;)) 2022-04-20 18:54:51 +02:00
Applevangelist
77dd40fb4a SET - clarified return value of SET_GROUP:GetAliveSET() (table, not SET)
UTILS - BRAANATO
ZONE - added examples to ZONE_RADIUS:Scan()
2022-04-20 14:01:26 +02:00
Applevangelist
5a63c51316 Utils - docu spelling 2022-04-20 12:45:33 +02:00
Applevangelist
eabc8b5854 UTILS - added BearingToCardinal, added ToStringBRAANATO 2022-04-20 12:43:24 +02:00
Applevangelist
1a798886a2 AIRWING - added function to callback AWACS "onafterflightonmission" 2022-04-20 08:33:49 +02:00
Applevangelist
8735dadbca Awacs updates 2022-04-20 08:33:11 +02:00
Applevangelist
2c53ebc0e4 FIFO Added Routines 2022-04-20 08:32:57 +02:00
Applevangelist
f93033695d Alpha Updates 2022-04-19 15:38:29 +02:00
Applevangelist
2d0f5817d0 Minor Changes 2022-04-19 15:36:44 +02:00
Applevangelist
2033e22216 AWACS Alpha 0.0.2 (WIP) (#1714)
TBD
2022-04-18 16:57:33 +02:00
Applevangelist
bada6f64ae Update Moose.files (#1713) 2022-04-18 12:27:58 +02:00
Applevangelist
bc141698c8 FIFO - make own file in Utils
AUFTRAG - Add base missions params for NewNOTHING
Marker - typo
Modules - FiFo added
UTILS - removed FiFo code
2022-04-18 12:27:14 +02:00
Applevangelist
75fddd9349 FIFO/LIFO - Read functions. Count as alternative to GetSize() 2022-04-17 11:25:48 +02:00
Applevangelist
b1a417295f TextAndSound - Docu 2022-04-17 11:24:36 +02:00
Applevangelist
0522036b80 Docu 2022-04-16 18:58:43 +02:00
Applevangelist
061469840b FIFO 2022-04-14 15:55:51 +02:00
Applevangelist
6e218ed908 LIFO/FIFO - enforce unique ID 2022-04-14 15:05:49 +02:00
Applevangelist
626b48c3d1 Added LIFO/FIFO:HasUniqueID(UniqueID) 2022-04-14 11:11:18 +02:00
Applevangelist
dd957237e2 Nicefy docs 2022-04-14 08:54:42 +02:00
Applevangelist
fc9e237dbb UTILS - LiFo/FiFo Stacks 2022-04-14 08:12:02 +02:00
Frank
faac265373 Merge pull request #1712 from FlightControl-Master/FF/Ops
Ff/ops
2022-04-13 22:44:52 +02:00
Frank
998935e2a3 Merge branch 'develop' into FF/Ops 2022-04-13 22:40:19 +02:00
Frank
24f8116fce OPS
**ZONE**
- Fixed incorrect fillcolor alpha.

**COORDINATE**
- Fixed incorrect fillcolor alpha.

**AUFTRAG**
- Fixed `CASENHANCED` order of arguments wrong in docs.

**FLEET**
- Improved docs.
- Added ``:SetPathfinding` function

**OPSGROUP**
- Fixed RECON mission behaviour if not random.
- Improved stuck check if engaging.

**LEGION**
- Added weapon type as parameter for selecting cohort assets.

**COHORT**
- Added `:GetMissionRange` function that accounts for long range weapons.
- Added counting of asset ammo.
2022-04-13 22:39:48 +02:00
Applevangelist
3415330871 UTILS - added FiFo 2022-04-13 16:13:02 +02:00
Applevangelist
eadeaae6db CTLD Corrected imperial hover message to say ft not m 2022-04-13 15:30:43 +02:00
Penecruz
32bdaf4f24 Update Ops Airboss for develop (#1711)
* Update Airboss.lua

* Revert "Update Airboss.lua"

This reverts commit 61b0f843eb.

* Update Airboss.lua
2022-04-13 09:35:18 +02:00
Applevangelist
7525fe9357 UTILS - corrected door check for AH64 2022-04-12 08:23:37 +02:00
Applevangelist
b24f31922f Soundfile - missing backslash 2022-04-10 18:26:27 +02:00
Applevangelist
4c79349b8d MSRS - repair command string for .bat processing 2022-04-10 18:23:20 +02:00
Applevangelist
44f7a27387 AICSAR - missing \ in path 2022-04-10 18:22:31 +02:00
Applevangelist
369425bec1 Some SRS changes 2022-04-10 15:12:51 +02:00
Applevangelist
3dc284335e SoundOutput - Honor self.useSRS to find a path to sound files located inside the miz folder 2022-04-10 14:59:54 +02:00
Applevangelist
bfc284994a SRS - port set not honored 2022-04-10 14:59:05 +02:00
Applevangelist
277409a807 Text and Sound: Spelling error 2022-04-10 14:58:47 +02:00
Applevangelist
d1f1f14bc3 SRS - add port to docu 2022-04-10 10:18:26 +02:00
Applevangelist
5ee1f5d3af CSAR/AICSAR - added port options for SRS 2022-04-10 09:28:47 +02:00
Frank
f4569fb5cc Merge pull request #1710 from FlightControl-Master/FF/Ops
OPS
2022-04-08 22:19:42 +02:00
Frank
4ba0a2dafb OPS
**FLEET v0.0.1**
- New class for naval units corresponding to AIRWING and BRIGADE

**FLOTILLA v0.0.1**
- New class for naval units corresponding to SQUADRON and PLATOON
2022-04-08 22:18:35 +02:00
Applevangelist
c2b1c2b1d8 SET - logic correction in :Remove() 2022-04-08 11:26:59 +02:00
Frank
2e119e2efd Merge pull request #1709 from FlightControl-Master/FF/Ops
OPS
2022-04-07 12:39:49 +02:00
Frank
4641918486 OPS
**LEGION**
- Added function `:RelocateCohort()` to relocate cohorts from one legion to another.
2022-04-07 12:11:17 +02:00
Frank
407f6f2b0f Merge pull request #1707 from FlightControl-Master/FF/Ops
OPS
2022-04-04 22:31:33 +02:00
Frank
f01d7ecd96 OPS
**AUFTRAG v0.9.1**
- Added new mission type `CARGOTRANSPORT`
2022-04-04 22:30:30 +02:00
Frank
e3d987bbdf Update Database.lua
- Static templates saved under first unit name so they can be found.
2022-04-04 16:53:52 +02:00
Applevangelist
89845883d0 Some nil checks to the A2A dispatcher, keeping it from detecting nil units, added locale to Settings and use of it to TextAndSound 2022-04-04 12:57:31 +02:00
Frank
4e7ff94b33 Merge pull request #1706 from FlightControl-Master/FF/Ops
static spawn
2022-04-04 12:16:48 +02:00
Frank
2fb9a1b1d7 static spawn 2022-04-04 12:15:29 +02:00
Applevangelist
5c0ab36662 CTLD - Build object at the first crate location found, not randomly around the helo 2022-04-04 11:29:21 +02:00
Frank
fc6dac326d Merge pull request #1705 from FlightControl-Master/FF/Ops
OPS
2022-04-04 00:00:51 +02:00
Frank
426dcff085 OPS
FLIGHTGROUP
- Improved homebase for spawned units
- Enabled helo inAir check due to DCS bug that inAir returns true when spawned at airbase or farp

SET_ZONE
- Added DrawZone() function

ARMYGROUP
- Improved EngageTarget() function

AUFTRAG
- ARMORATTACK is not falling back to GROUNDATTACK
2022-04-03 23:59:43 +02:00
Applevangelist
e623f45c04 Update AICSAR.lua (#1704)
Added localization and fitting german (locale "de") texts
2022-04-02 12:49:09 +02:00
Applevangelist
3b9a9cb0fa some code cleanup 2022-04-01 19:37:55 +02:00
Applevangelist
c018a86bdb adding missing goshawk variable 2022-04-01 19:37:37 +02:00
Applevangelist
559be38baf Update TextAndSound.lua (#1703)
Slight doc changes
2022-04-01 19:36:00 +02:00
Applevangelist
e3e05e5003 Adding TextAndSound (#1702)
Adding TextAndSound localization class
2022-04-01 19:20:35 +02:00
Applevangelist
95649d7d46 Adding localisation class TEXTANDSOUND 2022-04-01 19:17:31 +02:00
Frank
61097de76d Merge pull request #1701 from FlightControl-Master/FF/Ops
OPS
2022-04-01 12:33:31 +02:00
Frank
e49fff5028 Update Auftrag.lua 2022-04-01 12:11:28 +02:00
Frank
20ae7945e0 Merge branch 'develop' into FF/Ops 2022-04-01 12:09:33 +02:00
Frank
c5a50d23b6 OPS
CHIEF
- Added option to customize reaction on strategic zones

AUFTRAG
- Added new type GROUNDATTACK
2022-04-01 11:17:43 +02:00
Applevangelist
ad37e5ca27 AIRBASE, added ["Deir_ez-Zor"] = "Deir ez-Zor", 2022-03-30 12:05:04 +02:00
Frank
e8303064b9 Update OpsGroup.lua 2022-03-29 16:32:50 +02:00
Applevangelist
f8a577749a OPS - Some changes to ARMORATTACK to update route if target is moving 2022-03-29 12:03:45 +02:00
Applevangelist
e113817293 CTLD - docu nicefy 2022-03-29 12:02:35 +02:00
Applevangelist
0d15cdd370 CTLD - corrected error in setting Hercules min and max drop height, added documentation 2022-03-29 08:52:21 +02:00
Applevangelist
b5db08eec3 AIRBASE - Add'l AB for the Channels map 2022-03-28 10:13:02 +02:00
Frank
c3591c1fae Merge pull request #1699 from FlightControl-Master/FF/Ops
OPS
2022-03-26 22:39:44 +01:00
Frank
e1a4d5497a Merge branch 'develop' into FF/Ops 2022-03-26 22:38:20 +01:00
Frank
4e83162adc OPS
CHIEF
- Added `:RemoveStrategicZone()` function
- Added `:SetLimitMission()` function to limit number of total or specific mission types.
- Improved Tactical Overview

OPSZONE
- Improved `Stop()` function
2022-03-26 22:38:03 +01:00
Applevangelist
42c6b8a016 And don't forget Fahrenheit 2022-03-26 14:47:10 +01:00
Applevangelist
48f9d808cf Correcting Celcius to Celsius 2022-03-26 14:42:36 +01:00
Applevangelist
6546c27cf5 OPS - added HOVER mission type 2022-03-25 17:54:02 +01:00
Frank
fc0c0f87dc Merge pull request #1697 from FlightControl-Master/FF/Ops
OPS
2022-03-25 12:52:31 +01:00
Frank
9d703c0af6 OPS
- CHIEF: added tactical overview
2022-03-25 12:50:45 +01:00
Frank
24559c475b Merge branch 'develop' into FF/Ops 2022-03-25 11:00:17 +01:00
Frank
f92e8a285a OPS
- Added nil check on vec3 for _UndateEngageTarget in ARMYGROUP and NAVYGROUP
2022-03-25 10:27:32 +01:00
Frank
0411120551 OPS
OPSGROUP
- Added damage check for groups that are not alive.
- Added `:ReturnToLegion` function.
- Added `:Teleport` function

LEGION
- Aircraft dont start hot if on Alert5 mission

AUFTRAG
- Added Formation parameter to PATROLZONE (for ground only)

ARMYGROUP
- Set Vee formation for engage group
2022-03-25 09:49:26 +01:00
Applevangelist
5f57d4ddcd docu changes 2022-03-23 07:57:06 +01:00
Applevangelist
4164bbeba8 CSAR/CTLD - added type to script 2022-03-22 10:38:07 +01:00
Frank
14dea99ccd Update Utils.lua
- Removed useless UTILS.GetDate() function
2022-03-22 09:31:16 +01:00
Frank
3ea1881ff5 OPS INTEL v0.3.0
- Added option to detect statics via `INTEL:SetDetectStatics` function.
- Added `INTEL:KnowObject` function to make intel aware of GROUPs or STATICs.
- Improved cluster analysis.
- Changed `NewCluster` event: removed contact as first parameter.
2022-03-20 22:20:09 +01:00
Applevangelist
5192c188f4 AIRBASE - added 10 new AB names in Syria 2022-03-18 09:49:06 +01:00
Applevangelist
c1ffa47e9d changed descriptions 2022-03-18 07:59:49 +01:00
Applevangelist
2808a9dcc5 CONTROLLABLE - added SetSpeed() and SetAltitude() from latest release 2022-03-18 07:41:10 +01:00
Applevangelist
e1ab6b6c93 CSAR - remove timer check for "open the door" message to make behaviour more realistic 2022-03-14 09:12:06 +01:00
Frank
229868bb20 OPS
AUFTRAG: Trooptransport set pickup radius to 100 meters.
OPSGROUP: enabled pickup radius for trooptransport auftrag
ARMYGOUP: removed GetPathOnRoad as it seems unncessary
2022-03-14 08:32:09 +01:00
Frank
520eb4cd1d OPS
- Improved recovery of retreated groups
2022-03-11 22:36:00 +01:00
Applevangelist
2d0b4d6ae5 SCORING: Corrected calc error in summary scoring functions 2022-03-11 10:19:30 +01:00
Frank
5dae9a197a OPS
- CHIEF: fixed bug in LEGION.RecruitCohortAssets() function call
- COMMANDER: added total weight to LEGION.RecruitCohortAssets() function call
- POSITIONABLE: fixed bug in relFuel calculation for cargo bay size
2022-03-10 10:05:21 +01:00
Frank
ff1ebf9775 OPS
- Legion: Improved max number of transport assets.
- OPSGROUP: fixed bugs in speed parameter
2022-03-09 19:07:24 +01:00
Applevangelist
e6f388518a Update CTLD.lua (#1693)
minor nil check
2022-03-09 10:28:26 +01:00
Frank
3557706e3a OPS
- Added new AUFTRAG type  CASENHANCED
- Improved capturing of OPSZONES by CHIEF
2022-03-05 14:43:39 +01:00
Applevangelist
f3d0d55a2f CTLD - small extra nil check in _GetUnitCargoMass(Unit 2022-03-03 12:34:55 +01:00
Applevangelist
b0c2bad1d8 CTLD - small fix for finding crates when using engineers 2022-03-03 11:02:14 +01:00
Applevangelist
53c9ca3b3a SEAD/MANTIS - added Silkworm ASM 2022-03-03 11:02:14 +01:00
Frank
e41ba1be45 Troop Transport
- Auftrag TROOPTRANSPORT: troops will wait in a zone and not at the exact position where the carrier lands.
2022-03-02 09:34:18 +01:00
Applevangelist
594febaece CSAR - remove double class 2022-02-21 19:36:13 +01:00
Applevangelist
890dae8ba7 SEAD - adding workaround for AGM_154 which lost target data 2022-02-21 08:35:56 +01:00
Applevangelist
8a3120be39 AUTOLASE - added nil check for CanLase() 2022-02-19 13:26:02 +01:00
Applevangelist
6b4975559d CSAR - added wet feet check if also using csarUsePara (no landing event triggered) 2022-02-18 08:22:57 +01:00
Applevangelist
3326550705 CSAR - added "wet feet" option for a 2nd template to be used over water 2022-02-17 17:41:20 +01:00
Frank
6be0d82fc6 Merge branch 'develop' into FF/Ops 2022-02-16 12:23:03 +01:00
Applevangelist
44ad841d05 CTLD - fix side effects in weight check - fixes #1688 (#1689)
Fixed _FindCratesNearby() to optionally ignore the helo's max load capacity, which prevented CTLD from finding, listing, building crates is weights are used. Fixes #1688
2022-02-16 10:02:44 +01:00
Applevangelist
53f45ace4c CTLD - corrected default weight limits when using CTLD:UnitCapabilities() - was setting loadable weight to zero 2022-02-15 18:07:14 +01:00
Applevangelist
42e9cae876 added back GROUP:GetHighestThreat() 2022-02-15 14:41:45 +01:00
Applevangelist
e46922d341 small correction 2022-02-15 07:30:41 +01:00
Applevangelist
21c242ee05 Added CTLD:SetTroopDropZoneRadius(Radius) 2022-02-13 12:07:57 +01:00
Frank
33b7a0cef2 Merge branch 'develop' into FF/Ops 2022-02-08 08:53:03 +01:00
Frank
9cddca1af5 AUFTRAG and WAREHOUSE
- Added check for AUFTRAG that if it is executing and all groups are dead, it's done
- Added check in WAREHOUSE find parking that units need to be alive
2022-02-08 08:52:47 +01:00
Applevangelist
8cdf0d9fce CSAR - CSAR:SpawnCSARAtZone(Zone ...) - Zone can now be a ZONE object as well as a string 2022-02-08 07:49:16 +01:00
Applevangelist
a079ac4207 CTLD - allow AFB zones smoke/flare 2022-02-07 12:17:41 +01:00
Applevangelist
099238a2e5 CTLD - Allow option to create sub-category names for crates (normal, repair), added function to create zones from AFB/FARP names directly 2022-02-07 11:54:35 +01:00
Applevangelist
595bc16d92 DETECTION - added 3 missing functions 2022-02-04 08:56:34 +01:00
Applevangelist
e9875c8288 small correction 2022-02-04 08:54:22 +01:00
Applevangelist
ec600ab672 CTLD - Added Hercules support for crates, troops & vehicles loaded with the help of the ground crew and dropped from the plane. 2022-02-03 09:59:35 +01:00
Applevangelist
c3689aee93 AICSAR - added limiter for available helos 2022-02-01 11:47:36 +01:00
Applevangelist
60a728d521 SET - correct error in intersection 2022-02-01 08:03:02 +01:00
Applevangelist
7bd7071ec5 CTLD Docu updates 2022-01-31 11:36:20 +01:00
Applevangelist
bb787aa9ca Update Range.lua (#1686)
Target sheet saving abilities as added by @TonyG
2022-01-31 11:27:44 +01:00
Applevangelist
d2f629d100 CTLD - added maxweight, load weight checks for crates cargo, template checks 2022-01-31 11:15:24 +01:00
Applevangelist
5d949de0ee Point - fix typos 2022-01-30 09:49:42 +01:00
Applevangelist
e21bc8a930 POINT - added option to name and stop smoke/fire 2022-01-30 09:39:03 +01:00
Applevangelist
af79f63870 CTLD - small correction for Hercules 2022-01-27 15:56:10 +01:00
Applevangelist
4ff32342e3 AI Dispatchers - add ability to add/remove resources to/from a squad 2022-01-24 09:54:30 +01:00
Applevangelist
98d55faf4e CTLD - added selectable smoke drop color, droppable beacons 2022-01-23 11:37:53 +01:00
Applevangelist
bd532ea808 Added Callsigns as per 2.7.9 2022-01-23 11:37:28 +01:00
Applevangelist
d4bd57ee70 Autolase - small update on nil check 2022-01-21 10:09:12 +01:00
Applevangelist
90dbfb31a6 DETECTION - corrected call for Vec2 in zone 2022-01-19 07:51:43 +01:00
Applevangelist
55ca34cad3 Added doors check for UH-60L 2022-01-16 17:07:32 +01:00
Applevangelist
36a5e919cd CTLD, CSAR - added support for UH-60L 2022-01-16 11:39:37 +01:00
Applevangelist
3263ba1440 CTLD - make container shape configureable 2022-01-15 11:32:51 +01:00
Tony
9721c19e48 Update Range.lua (#1683)
Addition of self.rangename to results for Rangeboss
2022-01-10 15:10:49 +01:00
Applevangelist
de71213eed AICSAR - added SRS and DCS radio capabilities, changed order of messages for initial spawning, documentation 2022-01-06 13:47:47 +01:00
Applevangelist
65abbf9563 AICSAR - added SRS option, made it easy to customize messages 2022-01-04 15:09:47 +01:00
Applevangelist
a94098494a Docu updates 2022-01-01 14:57:40 +01:00
Applevangelist
ec935356aa Mark visible as deprecated 2021-12-31 17:51:48 +01:00
Applevangelist
6ab419dfad Fix ATC new NTTR AFB names 2021-12-31 17:51:48 +01:00
Applevangelist
b1ffcff064 Update Moose.files (#1679) 2021-12-31 15:37:08 +01:00
Applevangelist
4ce09a3845 New Module AI CSAR 2021-12-31 15:36:35 +01:00
Applevangelist
9686e74feb Update Airbase.lua (#1678)
Changed (again) Airport names on the Nevada map
2021-12-30 07:46:14 +01:00
Frank
e97e24762d Merge pull request #1676 from FlightControl-Master/Applevangelist-patch-1
Update Range.lua
2021-12-29 15:41:48 +01:00
Applevangelist
b3fd0805e8 Update Range.lua 2021-12-29 08:59:45 +01:00
Applevangelist
300092d07d SEAD - fix a rare case when a coordinate of a weapon cannot be found 2021-12-28 08:28:19 +01:00
Applevangelist
56ed3a11d6 Scoring - docu changes 2021-12-28 08:28:19 +01:00
Applevangelist
6938b20ab6 Group - added docu 2021-12-28 08:28:19 +01:00
Frank
77f2cf5089 Merge pull request #1672 from FlightControl-Master/FF/Ops
AIRWING
2021-12-23 19:55:27 +01:00
Frank
19e3b015c5 Merge branch 'develop' into FF/Ops 2021-12-23 19:54:15 +01:00
Frank
2702d0fc2a AIRWING
- Fix for missions not being assigned
2021-12-23 19:54:01 +01:00
Applevangelist
472a4883f0 ZONE: Set down trials for getting a random coordinate on a given land type to 100
Cohort -ensure fallback of mission range
2021-12-22 11:48:42 +01:00
Frank
485e2e18bf Merge pull request #1671 from FlightControl-Master/FF/Ops
OPS
2021-12-21 11:57:09 +01:00
Frank
40c0f69eff OPS
- Airwing added :SetPayloadAmount() and SetAirboss() functions
- AUFTRAG fixed Failure to Failed event name
- CHIEF added statics as targets
- LEGION added check that runway is operational and carrier is not recovering for mission selection
2021-12-21 11:54:55 +01:00
Frank
854a1e5723 Update ArmyGroup.lua
- Fixed speed nil in ofafterUpdateRoute
2021-12-17 15:57:28 +01:00
Applevangelist
f4cd28cdb9 fixes 2021-12-17 14:31:06 +01:00
Applevangelist
5bae790dd8 Fix a rare occasion 2021-12-17 14:15:08 +01:00
Frank
d1d43c38cd Merge pull request #1668 from FlightControl-Master/FF/Ops
OPS
2021-12-17 13:29:08 +01:00
Frank
7e1552eeb4 Merge branch 'develop' into FF/Ops 2021-12-17 13:27:13 +01:00
Frank
7306bf28e0 OPS
- CHIEF: fixed ground groups deployment
- AUFTRAG: minor fixes
- OPSGROUP: emission option
2021-12-17 13:26:27 +01:00
Applevangelist
07e00a8faf Noise reducing measures 2021-12-15 13:46:33 +01:00
Applevangelist
ab93866366 Removing noise 2021-12-14 17:28:16 +01:00
Applevangelist
d7801b59e7 OPS - making a couple of modules much less noisy as the logs on a large mission get rather big 2021-12-14 13:40:16 +01:00
Applevangelist
ea926f173a CSAR - make beacon length configureable 2021-12-14 09:50:13 +01:00
Applevangelist
f6b55da0c6 CSAR - override suppressmessages for menu driven information 2021-12-12 19:48:49 +01:00
Applevangelist
ee4e562874 CTLD - corrected landheight of dropped smoke 2021-12-12 19:30:00 +01:00
Applevangelist
abfe5ffc45 Typos 2021-12-11 19:41:21 +01:00
Applevangelist
9629b0e1a3 SET - Added Zone Filter for STATIC 2021-12-11 14:24:07 +01:00
Applevangelist
80b03dd194 CTLD Added menu for smoke/flare 2021-12-11 14:13:43 +01:00
Applevangelist
3f92f8d2aa SET - added a couple of zone filters for GROUP, UNIT, CLIENT and PLAYER 2021-12-10 16:02:50 +01:00
Applevangelist
823c94cace BRIGADE - Added function to load platoons back into the field 2021-12-10 12:09:04 +01:00
Frank
421ac6c427 Fixes in AUFTRAG and LEGION
- Object in AUFTRAG:_TargetFromObject(Object) can be nil
- Assets are optimized wrt later mission type for assets on alert5
2021-12-10 10:38:34 +01:00
Applevangelist
72550d6d84 small changes Legion & Auftrag 2021-12-09 17:44:44 +01:00
Applevangelist
72999cc7b0 Update Zone.lua (#1660) 2021-12-09 07:16:29 +01:00
Applevangelist
706cf641b3 Multiple fixes 2021-12-08 19:27:22 +01:00
Applevangelist
d42bdb2505 Revert "Ops - Various"
This reverts commit 23ea5d9d06.
2021-12-07 18:13:13 +01:00
Applevangelist
9082054ba9 Revert "legion"
This reverts commit abc69bc838.
2021-12-07 18:10:21 +01:00
Applevangelist
abc69bc838 legion 2021-12-07 17:35:56 +01:00
Applevangelist
23ea5d9d06 Ops - Various 2021-12-07 16:09:02 +01:00
Applevangelist
8d009d6366 Some false values seem to be in need of being set explicitly 2021-12-06 15:15:46 +01:00
Applevangelist
8213b51bd6 Update Utils.lua (#1654)
Small bugfix in UTILS.LoadSetOfGroups
2021-12-06 14:56:42 +01:00
Applevangelist
a18fc2080d SET - slight change in remove function 2021-12-06 10:26:01 +01:00
Applevangelist
9c0ac0ff57 CHIEF - ArmoredGuard ensure on road 2021-12-04 18:40:14 +01:00
Applevangelist
c34dc9f946 CHIEF/AUFTRAG/OPSGROUP Fixed RECON type mission adhereing to paramters adinfinitum and randomly, fixed CAS mission in CHIEF 2021-12-04 16:24:45 +01:00
Applevangelist
1c5c205614 OpsGroup - corrected speed calculation from DCSTask 2021-12-03 16:51:06 +01:00
Applevangelist
897df1b8fa CHIEF - Option to allow ground transport. Set CAS speed to 70% max as Russian Helos are overly slow 2021-12-03 14:27:03 +01:00
Applevangelist
3fb22b7c55 AUFTRAG - correct wrongly corrected speed conversion 2021-12-02 16:07:34 +01:00
Applevangelist
7819a30c57 BRIGADE - Fuel zones landing in the wrong table. Corrected 2021-12-02 12:17:48 +01:00
Applevangelist
37d2c72945 MANTIS - added variable ranges for short, med and long range systems. Altered engage range to 95% and shoradactivation to 25km as defaults
AUFTRAG/CHIEF/OPSGROUP - added Auftrag type ARMOREDGUARD to have an ONGUARD mission for tanks w/o triggering transport by CHIEF
Made classes around CHIEF & AIRBOSS a bit less noisy as it kills my logfile
2021-12-02 10:13:38 +01:00
Applevangelist
5631e2c09f Minor changes 2021-11-29 08:03:58 +01:00
Applevangelist
c7ddd6ec35 CSAR - added check smoke/flare distance is valid 2021-11-27 17:27:58 +01:00
Applevangelist
7280ceac32 ARMYGROUP - in tracing, formation flag can be empty 2021-11-26 15:36:46 +01:00
Applevangelist
f8b9128d8e CHIEF - Added catch if coalition us given as string 2021-11-26 15:36:09 +01:00
Applevangelist
c482f1dccd Corrected typo in Unit.Category.HELICOPTER 2021-11-26 15:35:45 +01:00
Applevangelist
7e306be8aa UTILS - Added functionality to save & load groups and statics information 2021-11-26 15:34:47 +01:00
Frank
035e6913b5 Merge pull request #1643 from FlightControl-Master/Applevangelist-armor-1
CHIEF - Added use of ARMORATTACK
2021-11-24 13:38:25 +01:00
Applevangelist
e12f233afc Update Chief.lua 2021-11-24 13:32:39 +01:00
Applevangelist
26c7ff8c18 Update Chief.lua 2021-11-24 13:32:14 +01:00
Frank
5647364293 Merge pull request #1644 from FlightControl-Master/Applevangelist-armor-1-1
OpsGroup - Added support for ARMORATTACK
2021-11-24 13:17:45 +01:00
Frank
06fa585f69 Merge pull request #1642 from FlightControl-Master/Applevangelist-Armor-1
Auftrag - Added type ARMORATTACK
2021-11-24 13:17:13 +01:00
Applevangelist
035eac2f1e OpsGroup - Added support for ARMORATTACK
OpsGroup - Added support for ARMORATTACK
2021-11-24 12:09:07 +01:00
Applevangelist
f01889cbf7 CHIEF - Added use of ARMORATTACK 2021-11-24 12:07:03 +01:00
Applevangelist
73025bfd4b Auftrag - Added type ARMORATTACK
Auftrag - Added type ARMORATTACK
2021-11-24 12:06:02 +01:00
Applevangelist
aec6dd1246 SEAD/SHORAD - Add AGM-88 player modes handling 2021-11-22 11:37:10 +01:00
Applevangelist
ab4411e5bb SEAD - calculate HARM impact point from firing position if no target data is given
SHORAD - ignore HARM AGM-88 is not fired at a specific target
2021-11-21 18:40:04 +01:00
Frank
0ac00efda6 Merge pull request #1641 from FlightControl-Master/FF/Ops
Ff/ops
2021-11-20 22:38:38 +01:00
Frank
f32eb8d710 OPS
AUFTRAG
- Added mission task param for RECON, PATROLZONE and TROOPTRANSPORT

FLIGHTGROUP
- Fixed CheckGroupDone if group is engaging and has a paused mission

TARGET
- Added GetThreatLevelMax functions

CHIEF
- Added :AddGciCapZone() function
2021-11-20 22:36:15 +01:00
Frank
ec33dfb76c Merge branch 'develop' into FF/Ops 2021-11-20 20:38:40 +01:00
Frank
43dfbac2fa Update Auftrag.lua
- Changed ROE in ESCORT auftrag from OpenFireWeaponFree to OpenFire
2021-11-20 20:38:23 +01:00
Frank
7a483abec2 Merge pull request #1639 from FlightControl-Master/Applevangelist-ArmyGroup-1
Update ArmyGroup.lua
2021-11-20 17:50:36 +01:00
Frank
35e6b6faf4 Merge pull request #1637 from FlightControl-Master/Applevangelist-Chief-1
CHIEF - Updates
2021-11-20 17:49:30 +01:00
Frank
1066b58fb6 Merge pull request #1640 from FlightControl-Master/Applevangelist-OpsZone-2
Update OpsZone.lua
2021-11-20 17:47:43 +01:00
Applevangelist
b41b8f251f Update Chief.lua 2021-11-20 17:26:42 +01:00
Applevangelist
a1426c3e81 Update OpsZone.lua 2021-11-20 17:12:33 +01:00
Applevangelist
aa3967d88f Update ArmyGroup.lua
Added code to obey routing on roads
2021-11-20 17:09:55 +01:00
Applevangelist
c610c4cba9 Update Chief.lua
Added some improvements to threat calculation
2021-11-20 17:08:20 +01:00
Applevangelist
abb3a2dbd2 CHIEF - Updates
Added alignment to OpsZone Mission table. Added ARTY. Added Tanks for patrol
2021-11-19 16:03:25 +01:00
Frank
1f035301d9 Merge pull request #1636 from IsmaelB83/InboundCallMarshall
Inbound call marshall
2021-11-19 15:48:28 +01:00
Frank
ebf7f76d48 Merge pull request #1635 from FlightControl-Master/Applevangelist-OpsZone-1
OpsZone -Mission Table
2021-11-19 15:47:18 +01:00
Ismael
397ab77105 This pull request enhances Airboss class functionality to provide with the
1) Inbound calls both from Players requesting marshal and AI sent to marshal:
"Marshal, [MODEX], marking mom's [BEARING] for [DISTANCE], angels [HEIGHT], state [FUEL_STATE]
2) Commencing call and voiceover (both AI and Players)

For that, two boolean fields have been added to Airboss class to trigger or not extra voice overs:
xtVoiceOvers
xtVoiceOversAI

These fields can be modified trough methods:
AIRBOSS:SetExtraVoiceOvers(true/false)
AIRBOSS:SetExtraVoiceOversAI(true/false)

Note. At the moment both methods initialize to "false" at Airboss:NEW, so in case you want to have this functionality activated, you need to call the methods with (true) when initializing your Airboss class.
The new methods in charge of creating the radio calls are
AIRBOSS:_MarshalAI: for AI flights send to marshal
AIRBOSS:_RequestMarshal: for player flighs requesting marshal from F10 menu

2) AIRBOSS:_CommencingCall(unit, modex), which is called from
AIRBOSS:_ClearForLanding: for AI flights cleared for landing
AIRBOSS:_RequestCommence: for player flights requesting commencing from F10 menu (disregarding if the player call is right or not)

This enhacement of the Airboss class requires 5 new sound files (.ogg) to be included to folder "\Airboss Soundfiles" in your .miz file:
PILOT-Angels.ogg
PILOT-For.ogg
PILOT-MarkingMoms.ogg
PILOT-Marshal.ogg
PILOT-State.ogg
PILOT-Commencing.ogg
2021-11-19 15:31:49 +01:00
Applevangelist
f37abc69ea Update OpsZone.lua 2021-11-19 14:29:18 +01:00
Applevangelist
ee85b0e057 OpsZone -Mission Table
Added functionality to admin missions attached to an OpsZone (for CHIEF)
2021-11-19 14:20:53 +01:00
Ismael
eab28abc86 Subject: Add Player and AI Inbound radio calls to better inmersion in Airboss #16311
This commit enhances Airboss class functionality to provide with the inbound calls both from Players requesting marshal and AI sent to marshal:
- "Marshal, [MODEX], marking mom's [BEARING] for [DISTANCE], angels [HEIGHT], state [FUEL_STATE]

Two new boolean fields have been added to Airboss class to trigger or not the inbound calls:
- inRadioCall
- inRadioCallAI

These fields can be modified trough methods:
- AIRBOSS:SetInboundMessagesPlayer(false)
- AIRBOSS:SetInboundMessagesAI(false)
Note. At the moment both methods initialize to "false" at Airboss:NEW, so in case you want to have this functionality activated, you need to call the methods with (true) when initializing your Airboss class.

This enhacement of the Airboss class requires 5 new sound files (.ogg) to be included to folder "\Airboss Soundfiles" in your .miz file:
- PILOT-Angels.ogg
- PILOT-For.ogg
- PILOT-MarkingMoms.ogg
- PILOT-Marshal.ogg
- PILOT-State.ogg

To get them, please refer to the SOUNDS MOOSE repository or the discord channel. Where they will be available.
2021-11-19 01:11:49 +01:00
Applevangelist
16c5307fc2 COMMANDER - Zone parameter doc not correctly mentioned in Luadocs 2021-11-18 10:58:42 +01:00
Applevangelist
8c8cae1e27 AUFTRAG - wrong speed conversion lines 925/295 corrected to KnotsToKmph 2021-11-18 10:58:13 +01:00
Frank
925c645821 Merge pull request #1633 from FlightControl-Master/FF/Ops
OPS
2021-11-17 17:17:11 +01:00
Frank
c1c97a86b7 OPS
- COMMANDER: Added GCICAP zones
- AIRWING: Improved patrol zone counting, fixed bug in NewPatrolPoint
- OPSGROUP: mission speed acknowledged
2021-11-17 17:15:44 +01:00
Applevangelist
1fc1016148 Update Auftrag.lua
Added missionSpeed to Orbit
2021-11-17 16:42:58 +01:00
Frank
e73545d296 Merge pull request #1630 from dogjutsu/dogutsu/develop
Fixed some typos of forms of the word 'strategy'.
2021-11-16 22:08:00 +01:00
dogjutsu
f2fb7d43d0 Fixed some typos of forms of the word 'strategy'. 2021-11-16 12:45:14 -08:00
Applevangelist
781d421e1c slightly changes message 2021-11-16 15:48:00 +01:00
Applevangelist
a3a7464a29 Small fix fox autoshorad parameters 2021-11-16 10:34:42 +01:00
Frank
ac936f5650 Merge pull request #1629 from FlightControl-Master/FF/Ops
Scheduler
2021-11-16 10:34:12 +01:00
Frank
c0f5dc2dc8 Scheduler
- Fixed bug
2021-11-16 10:33:35 +01:00
Applevangelist
31c113180e MANTIS - Zones - added conflict zones 2021-11-16 09:26:05 +01:00
Applevangelist
239df2deb2 SEAD - Updated TTI calculation for Tomahawk long shots 2021-11-16 09:25:38 +01:00
Applevangelist
31a8c4b0b9 SHORAD - Updates for missile without set target intel 2021-11-15 16:18:21 +01:00
Applevangelist
f394bd45c7 SEAD - Updated to handle missiles w/o clear targets 2021-11-15 16:18:21 +01:00
Applevangelist
63999c9ec3 MANTIS - Added Attacker group info on planned/started suppression events 2021-11-15 16:18:21 +01:00
Frank
82c24cee7e Merge pull request #1628 from FlightControl-Master/FF/Ops
scheduler
2021-11-15 10:22:35 +01:00
Frank
5e94b0c009 Update Base.lua 2021-11-15 10:20:34 +01:00
Frank
452ff62134 SCHEDULER 2021-11-15 10:19:21 +01:00
Frank
3df494cacd Merge pull request #1627 from FlightControl-Master/FF/Ops
Ff/ops
2021-11-14 23:31:03 +01:00
Frank
d62bb59df7 OPS
- Clean up tracing
2021-11-14 22:12:41 +01:00
Applevangelist
b367f9320b CSAR - don't make usePara default. Added coalition check if using the parachute landing event 2021-11-14 13:33:31 +01:00
Applevangelist
4bc3dbbf6c MANTIS - added auto-setup of SHORAD 2021-11-14 13:13:41 +01:00
Applevangelist
e7b7e3ac96 Merge pull request #1626 from FlightControl-Master/Applevangelist-unit-2
Wrapper Unit fix missile count
2021-11-14 13:00:35 +01:00
Applevangelist
f3c4aea12f Wrapper Unit fix missile count
missile count for SAM and CRUISE types #1624
2021-11-14 12:59:24 +01:00
Frank
b9b5938a91 OPS
- Fixed refuel system always true.
2021-11-13 20:08:22 +01:00
Applevangelist
e7fdcf0db4 SEAD - Slightly wider escape radius 2021-11-13 19:11:25 +01:00
Applevangelist
c1f22aa556 MANTIS - Added support for HighDigitSAM mod, added blindspot management, corrected distinguising between SA-2 and SA-3 2021-11-12 15:27:05 +01:00
Applevangelist
991b4089d6 SHORAD radius clarification 2021-11-12 15:25:25 +01:00
Frank
a8132552de OPS
- Fixed bug in egress coord
- Improved barrage mission
- improved pickup at legion
- fixed bug in SetPathfindingOff function
2021-11-11 21:16:48 +01:00
Applevangelist
a0323aef19 MANTIS - Some docu updates 2021-11-11 18:34:06 +01:00
Applevangelist
a38abc2f7f MANTIS - latest updates 2021-11-11 17:45:25 +01:00
Applevangelist
a6beecf510 MANTIS - Added Auto Mode 2021-11-11 17:22:21 +01:00
Applevangelist
c5dece0e59 SEAD - make emissions on/off standard 2021-11-11 16:03:52 +01:00
Applevangelist
ce935bafc1 Small fix to switch off pattern matching 2021-11-09 09:53:23 +01:00
Applevangelist
fd426a96aa File functions 2021-11-09 09:51:31 +01:00
Applevangelist
fad8800842 Added Docu 2021-11-09 09:51:05 +01:00
Applevangelist
273a473db1 MANTIS/SEAD make docu Pikes-friendly 2021-11-08 15:21:20 +01:00
Applevangelist
a7588e517d SEAD - (re-)added emissions on/off option and ability to link object functions for state changes. 2021-11-08 13:11:58 +01:00
Applevangelist
84eff098eb MANTIS - Added FSM Events for SeadSuppressionPlanned/Start/ENd 2021-11-08 13:11:58 +01:00
Frank
f157f3b5d6 OPS
- Fixed mission alt for patrol zone auftrag
2021-11-07 22:32:17 +01:00
Frank
6cd00c60a7 Update OpsGroup.lua
- Fixed waypoint alt for missions
2021-11-07 21:39:38 +01:00
Frank
2ea951db61 Removed WIP classes
- F10MENUE and FLIGHTCONTROL
2021-11-07 19:43:02 +01:00
Frank
9d0bd0aabb Update OpsGroup.lua 2021-11-07 19:39:53 +01:00
Frank
3d88d16b4b Merge branch 'FF/Ops' into FF/OpsDev 2021-11-07 18:24:48 +01:00
Frank
02724dc26d Merge branch 'develop' into FF/Ops 2021-11-07 18:20:27 +01:00
Frank
21a93652cd Update OpsGroup.lua
- Fix for AUFTRAG carried out only after the group has passed all waypoints
2021-11-07 16:08:11 +01:00
Frank
fb4caf1a42 OPS
- Improved transport path
2021-11-07 16:03:44 +01:00
Frank
7a2508bf17 OPSTRANSPORT
- Improved pre-defined paths for pickup and transport
2021-11-06 18:10:49 +01:00
Applevangelist
eeeab86952 added altered message 2021-11-06 18:07:42 +01:00
Applevangelist
a149ff1705 Switch for fratricide and treason (coalition changes) 2021-11-06 15:15:30 +01:00
Applevangelist
2c73c9c815 Merge pull request #1620 from FlightControl-Master/Applevangelist-casevac-1
CSAR additions by Shagrat
2021-11-05 16:31:22 +01:00
Applevangelist
f6f29db9f1 CSAR additions by Shagrat
Added functionality for Casevac
2021-11-04 17:23:29 +01:00
Frank
c823a68616 OPS
- Fixed several bugs
2021-11-02 21:14:15 +01:00
Applevangelist
e7e2184760 Autolase - fixed error when not using a pilotset 2021-11-01 19:46:56 +01:00
Applevangelist
6fe2422bc9 SRS Google addition by rollnthndr 2021-10-31 11:53:53 +01:00
Applevangelist
cd62776be6 AIRBOSS additions by Pene 2021-10-31 11:53:24 +01:00
Applevangelist
037357efe9 Merge pull request #1619 from bbirchnz/ctld-crate-leak
fix cleanup of crates on load or build.
2021-10-31 11:31:19 +01:00
Ben Birch
8d3910ea4c fix cleanup of crates on load or build. 2021-10-31 19:37:26 +11:00
Applevangelist
3e5926f706 Speedmax returning 0 not nil 2021-10-30 16:32:59 +02:00
Applevangelist
a1d67bf539 Speedmax returning 0 not nil 2021-10-30 16:32:42 +02:00
Applevangelist
3e65457041 doc impro 2021-10-29 18:30:22 +02:00
Applevangelist
f70180eb66 SET_BASE - cmpleted GetSetComplement 2021-10-29 10:20:34 +02:00
Applevangelist
c0a558e229 Merge pull request #1616 from Zonr0/Zonr0-ExternalToolsFix
Fixes broken external tools
2021-10-28 15:45:02 +02:00
Applevangelist
801069f5ac Update Moose_Create.lua 2021-10-28 15:39:57 +02:00
Frank
f9dcac8264 Merge branch 'master' into develop 2021-10-28 10:21:16 +02:00
Frank
902c001aa4 OPS
Improved OPSTRANSPORT
2021-10-28 10:04:01 +02:00
Applevangelist
0cf2a4353d doc build - next try 2021-10-28 09:13:36 +02:00
Applevangelist
13c8cc90f2 doc build fix 2021-10-28 08:41:10 +02:00
Applevangelist
db231fafeb Docs build test 2021-10-28 08:12:27 +02:00
Andrew Waugh
c3f7deb602 Fixes broken external tools
Several small changes that should hopefully be a nice QoL upgrade for generating the imports and lead to less newbie confusion.

* Adds a lua binary directly to the repository instead of just expecting the user to have installed it via choco. Added binary is 5.4 as that's the lowest 5.x exe that's easily downloaded, and it works fine for what we need.
* Modifies the launch targets to use workspace_loc macros instead of resource_loc macros. Workspace_loc requires the user to have correctly set the name of their project, but that is already stressed in the documentation.  resource_loc was just wrong. (project_loc would cause problems if the user had selected something outside of the moose project before running).
* Modifies launch targets to use the folder structure that the project is actually structured with.
* Adds the include folder and files so Eclipse doesn't explode when they are missing.
* Small modifications to Moose_Create, also includes a path conversion function that in my testing doesn't make a difference eitherway on Windows, but is there for a troubleshooting option.
* Adds courtesy instructions when generating the dynamic include file.
2021-10-27 20:18:10 -07:00
Applevangelist
300e3f2f58 Merge pull request #1615 from FlightControl-Master/Applevangelist-docpatch
Update Task_Cargo_Transport.lua
2021-10-27 13:10:40 +02:00
Applevangelist
513406f0e5 Update Task_Cargo_Transport.lua 2021-10-27 13:09:30 +02:00
Applevangelist
27e21e77f9 Update Task_Cargo_Transport.lua 2021-10-27 11:19:32 +02:00
Applevangelist
dadfd803f7 Update Autolase.lua
added docu
2021-10-26 13:58:11 +02:00
Frank
02b0ba2278 OPS
- Improved behaviour of OPSTRANSPORT when cargo or carrier is on mission.
2021-10-25 22:17:56 +02:00
Applevangelist
3e1005aef1 Small correction to silence wall of text when adding tasks to a mission 2021-10-25 16:29:14 +02:00
Applevangelist
e2eb13739c Commented out wall of text when joining a unit as a player 2021-10-25 16:28:40 +02:00
Applevangelist
c52e30ceae Added smoke color per RECCE 2021-10-25 16:28:11 +02:00
Applevangelist
07754cdf5f Merge pull request #1614 from madmoney99/develop
Forrestal Wire Corrections
2021-10-24 09:14:10 +02:00
madmoney99
c74c475a29 Forrestal Wire Corrections
Tested on MP and SP.  Both were recording incorrect wires on 1/2 and 4 wires regularly with an occasional 3 wire miss.  This tested correct in the Hornet.

TonyG
2021-10-23 16:34:21 -07:00
Applevangelist
ad36ab520b Added Bell-47 2021-10-22 17:04:03 +02:00
Applevangelist
bc32ff5db9 Added Bell-47 2021-10-22 17:03:57 +02:00
Frank
6009432933 OPS
- NAVYGROUP added engage target
- Barrage improvments
2021-10-22 11:23:29 +02:00
Frank
99eaa37c76 Merge branch 'master' into develop 2021-10-20 19:56:31 +02:00
Frank
ed6d5f727a OPS 2021-10-20 19:49:26 +02:00
Frank
c6995d6e58 OPS
- Fixed AUFTRAG :Repeat()
- Fixed bug in BRIGADE
- Improved cargo bay calculation in POSITIONABLE (includes rel. fuel)
- Changed carrier event names in OPSGROUP

- New class F10MENU (not sure about it)
2021-10-19 10:19:26 +02:00
Frank
cb0f453a8d Merge branch 'FF/Ops' into FF/OpsDev 2021-10-16 13:41:40 +02:00
Frank
d9866846ad Merge branch 'FF/MasterDevel' into FF/Ops 2021-10-16 13:40:37 +02:00
Frank
de5d9195f3 OPSGROUP
- Cargo bay of element remains after respawn
- Added some docs for CHIEF
2021-10-16 09:32:47 +02:00
Frank
fd1fe8562c Merge branch 'develop' into FF/Ops 2021-10-12 22:20:20 +02:00
Frank
b1298223aa Merge branch 'master' into develop 2021-10-12 22:18:43 +02:00
Applevangelist
c48128d92e CSAR - Added country options for spawned pilots 2021-10-12 08:30:44 +02:00
Frank
0f4d466953 OPS
- Changed mission, legion in MissionAssign functions (LEGION, COMMANDER, CHIEF)
- OPSTRANSPORT: improved TZC selection
- ARMYGROUP needs to
2021-10-11 21:28:35 +02:00
Applevangelist
1b752fcaf6 CTLD - bug fix for open doors 2021-10-11 18:47:39 +02:00
Applevangelist
d06db9909c AUTOLASE Small update 2021-10-11 14:11:58 +02:00
Applevangelist
921024035c AUTOLASE - cleanup, added SRS option 2021-10-08 12:33:33 +02:00
Applevangelist
3b1c8c3deb AUTOLASE - added LOS check, maxlasingunits valid per lasing Recce 2021-10-07 18:16:40 +02:00
Applevangelist
69862ab67d CSAR - try to avoid spawning under water 2021-10-07 18:15:50 +02:00
Applevangelist
b05c321306 CTLD - added door check for troops 2021-10-07 18:15:13 +02:00
Applevangelist
9b74a58dde UTILS - added door check for Hercules 2021-10-07 18:14:50 +02:00
Applevangelist
d112ffaf6a Autolase - better calculation of LoS for lasing, somewhat faster detection 2021-10-07 09:49:06 +02:00
Applevangelist
554f063def INTEL - allow variable update times 2021-10-07 09:46:06 +02:00
Frank
f6dce02203 INTEL
- Introduced pcall to getName() of detected objects. Found a problem with an object of ID 5,000,031
2021-10-06 22:03:02 +02:00
Frank
653dfe82fa OPS CHIEF
- Improved target queue for assigning new missions
2021-10-06 13:25:57 +02:00
Frank
5dbf743052 OPS
- Fixed a couple of minor bugs.
- FC added _PlayerAbortInbound function
2021-10-05 23:59:24 +02:00
Applevangelist
f7e7e2e41c ZONE_CAPTURE_COALITION - fix an error when monitoring hits but the Event Function delivers SCENERY as a hit UNIT 2021-10-05 19:07:59 +02:00
Applevangelist
b28b4db7fd docu fixes 2021-10-05 19:06:49 +02:00
Applevangelist
c34f30e4a3 Docu fixes 2021-10-05 19:06:40 +02:00
Applevangelist
aa7f11185d Small update 2021-10-05 19:06:30 +02:00
Frank
1790d19809 FC 2021-10-03 23:09:45 +02:00
Frank
fa6fbca67b OPS
- Added tanker and CAP zones
2021-10-03 21:33:33 +02:00
Applevangelist
cd79c57a27 AUTOLASE - added Cancel FSM to stop, docu changes, option to notify pilots in the set only 2021-10-02 14:45:37 +02:00
Applevangelist
4c3a97e2b2 Autolase! 2021-10-01 17:29:22 +02:00
Applevangelist
f126dceeae Merge pull request #1610 from FlightControl-Master/Applevangelist-Autolase-2
Update Moose.files
2021-10-01 17:26:50 +02:00
Applevangelist
414521acc5 Merge pull request #1611 from FlightControl-Master/Applevangelist-autolase-3
Update Modules.lua
2021-10-01 17:26:40 +02:00
Applevangelist
9147422340 Merge pull request #1609 from FlightControl-Master/Applevangelist-Autolase-1
Create Autolase.lua
2021-10-01 17:26:29 +02:00
Applevangelist
920646ea74 Update Modules.lua
added autolase
2021-10-01 17:24:25 +02:00
Applevangelist
c57d839927 Update Moose.files
Add Autolase.lua
2021-10-01 17:22:58 +02:00
Applevangelist
e7fd5db2c2 Create Autolase.lua
Added Class AUTOLASE
2021-10-01 17:20:17 +02:00
Applevangelist
b76486ef5f CSAR - added parameters for hovering rescue 2021-10-01 14:52:25 +02:00
Applevangelist
5c06584676 UTILS - correction door check MI-8 2021-10-01 14:52:00 +02:00
Frank
2ae2ee64be OPS
- Lots of updates and improvements
2021-10-01 12:04:15 +02:00
Applevangelist
17ba35e237 INTEL - also set isship and isground attributes on contacts 2021-10-01 10:44:25 +02:00
Applevangelist
53e98e70aa CTLD: added user-friendly function to inject static cargos: CTLD:InjectStaticFromTemplate(Zone, Template, Mass) 2021-10-01 10:43:49 +02:00
Applevangelist
359e18eb58 RADIO - delete frequency check 2021-09-30 08:07:42 +02:00
Applevangelist
3377459df5 Added option for silent mission addition 2021-09-29 16:57:45 +02:00
Frank
3e30d15405 Merge branch 'FF/Ops' into FF/OpsDev 2021-09-29 09:57:52 +02:00
Frank
2b50cf2243 Merge branch 'develop' into FF/Ops 2021-09-29 09:55:20 +02:00
Frank
b72e2b6bf9 Merge branch 'master' into develop 2021-09-29 09:34:37 +02:00
Frank
c7a2b34f59 Update Warehouse.lua
- Disabled fuel check.
2021-09-29 08:15:22 +02:00
Frank
b48958995a OPS
- Fixed oscillation between UpdateRoute and CheckGroupDone in FLIGHTGROUP
- Improvements regarding capturing zones.
- Reduced log output
2021-09-28 23:26:33 +02:00
Applevangelist
58c496eacd GROUP - GROUP:GetAmmunition() - fix to also return bomb count correctly 2021-09-28 16:52:18 +02:00
Applevangelist
7bd867c9dd SEAD - Docu changes for Intellisense 2021-09-28 16:51:35 +02:00
Frank
be0558849c OPS
- Added rearming zones
- Improved rearming
2021-09-27 16:11:03 +02:00
Applevangelist
a1c7ec2ac9 Fix "local" error 2021-09-27 15:49:03 +02:00
Applevangelist
8bf073c0c6 Small fix for Airbase Parking Spot Finder 2021-09-26 09:51:02 +02:00
Frank
994689f05a OPS
- Improved transport assignments
2021-09-25 20:18:16 +02:00
Applevangelist
3e10f9f451 bugfix 2021-09-24 18:38:58 +02:00
Frank
972fa9f674 OPS
- Fixed bug in WAREHOUSE isShip
- FLIGHTGROUP added damage and ammo checks that trigger FSM events
- Improved engage detected targets
- Improved OPSZONE
2021-09-24 14:47:36 +02:00
Applevangelist
8e64d8e334 CTLD: Added mass and canCargo Flag on spawned statics. Use .enableslingload = true to use 2021-09-24 11:06:54 +02:00
Applevangelist
eccd81d40a SPAWNSTATIC - bigfix on canCargo (not:isCargo) and mass (not transported into template) when spawning 2021-09-24 11:05:42 +02:00
Applevangelist
649136f98f small updates, fixes 2021-09-23 12:43:28 +02:00
Frank
d7dae1366d OPS
- Improved OPSTRANSPORT for LEGION assets.
2021-09-22 19:27:33 +02:00
Applevangelist
19e2ebcd03 CTLD - Added statics as cargo (#1601)
.... and the ability to load and save them alongside your buildable crates.
2021-09-22 15:55:10 +02:00
Applevangelist
021c907d16 SET - Added SET_CLIENT:CountAlive() 2021-09-21 07:46:21 +02:00
Applevangelist
8ac3e28fdf CTLD - fix SAVE/LOAD when using no path on calls 2021-09-21 07:46:05 +02:00
Frank
c5af279730 OPS
- Fixed some stuff for Egress coordinate
- Fixed some bugs in OPSTRANPORT if disembark carriers are specified
2021-09-20 22:47:51 +02:00
Applevangelist
e9377e93f1 Postionable - Added Cargo Seats to VAB Mephisto 2021-09-20 14:20:09 +02:00
Applevangelist
6747c69511 CTLD Ability to fire an event on injection 2021-09-20 14:19:26 +02:00
Frank
9b6cae6c49 Update Commander.lua 2021-09-19 22:45:58 +02:00
Frank
7148bd1d42 OPS Escort
- Refined functions to recruit escort assets.
2021-09-19 22:10:52 +02:00
Frank
73940fffc6 Update Legion.lua
- Fix that assets did not get removed
2021-09-18 18:47:06 +02:00
Frank
09015449cd OPS Recruting
- Removed obsolete recruiting functions from code
2021-09-18 18:23:22 +02:00
Frank
4dfdb99731 OPS
- Recruit assets with new function (LEGION, COMMANDER, CHIEF)
2021-09-18 18:09:41 +02:00
Frank
bbbca04066 OPS Legion
- Added new global function to recruit assets.
2021-09-18 00:11:04 +02:00
Frank
e755bba608 OPS
- Clean up on "CheckMissionType" and "CheckMissionCapability" functions ==> moved to AUFTRAG as global functions.
2021-09-17 16:59:43 +02:00
Frank
9161cec238 OPS
- Simplified asset selection by using just one routine for LEGION, COMMANDER and CHIEF
2021-09-16 21:30:36 +02:00
Applevangelist
dc14b60fcc bug fixing 2021-09-16 15:09:51 +02:00
Applevangelist
da625d51f6 Merge pull request #1599 from FlightControl-Master/Applevangelist-CTLD-1
CTLD - Added persistance
2021-09-16 13:44:54 +02:00
Applevangelist
ce69055758 CTLD - Added persistance
-- ## 6. Save and load back units - persistance
-- 
-- You can save and later load back units dropped or build to make your mission persistent.
-- For this to work, you need to de-sanitize **io** and **lfs** in your MissionScripting.lua, which is located in your DCS installtion folder under Scripts.
-- There is a risk involved in doing that; if you do not know what that means, this is possibly not for you.
-- 
-- Use the following options to manage your saves:
-- 
--              my_ctld.enableLoadSave = true -- allow auto-saving and loading of files
--              my_ctld.saveinterval = 600 -- save every 10 minutes
--              my_ctld.filename = "missionsave.csv" -- example filename
--              my_ctld.filepath = "C:\\Users\\myname\\Saved Games\\DCS\Missions\\MyMission" -- example path
--  
--  Then use an initial load at the beginning of your mission:
--  
--            my_ctld:__Load(10)
--            
-- **Caveat:**
-- If you use units build by multiple templates, they will effectively double on loading. Dropped crates are not saved. Current stock is not saved.
2021-09-16 13:43:39 +02:00
Frank
589ebd5bca CHIEF
- Improved asset selection
2021-09-16 11:02:49 +02:00
Frank
35b50e1a9d OPSZONE and CHIEF 2021-09-14 23:51:03 +02:00
Frank
f038564b1b OPSTRANSPORT
- Added Cancel feature. First steps...
- Fixed a couple of other little bugs.
2021-09-13 16:04:16 +02:00
Frank
1d0eb9806d COMMANDER
- Added OPS transport (untested)
2021-09-13 08:31:00 +02:00
Applevangelist
c50a9bd318 CTLD - small bug fix on stock removal 2021-09-12 17:37:21 +02:00
Applevangelist
cd9006d29b CTLD - added alternative crate spawn by @mousepilot. Add menu item to list stock.Injected troops will not lead to cargo type duplication. 2021-09-11 15:20:36 +02:00
Applevangelist
d3b88f9065 bug fixing 2021-09-11 10:03:32 +02:00
Frank
6a6cb1961d OPS LEGION
- Improved asset selection for transports
2021-09-10 11:37:53 +02:00
Frank
884c51a69a OPSTRANSPORT
- Improved assignment to multiple legions.
2021-09-10 00:32:15 +02:00
Frank
6f126e6cd4 OPSCARGO
- fixes for Legion assignment
2021-09-09 13:35:10 +02:00
Frank
b0c2e5409a OPS AUFTRAG
- Added Alert 5 mission
- Added Fuel supply mission
- Added Ammo supply mission
2021-09-08 11:49:27 +02:00
Applevangelist
9516ec3cd2 CSAR: Gardening cleanup 2021-09-07 19:53:05 +02:00
Frank
aecb92ccd3 OPSGROUP
- Added EPLRS option
- EPLRS is on if group has datalink capability
2021-09-07 11:17:20 +02:00
Frank
bdf13f29f7 OPS
- COMMANDER and LEGION clean up of obsolete stuff for recruiting assets.
2021-09-06 23:40:58 +02:00
Frank
81120abfcb OPS
- LEGION and COMMANDER: Recruit assets for mission
2021-09-06 23:24:26 +02:00
Applevangelist
08a8170990 CTLD - improved crate spawning, added beacons / smoke / flare for ships, added documentation 2021-09-05 18:05:08 +02:00
Frank
316ea910c2 Update Cohort.lua
- Fixed some stuff for combat readiness check
2021-09-05 00:23:12 +02:00
Frank
0b5edfc21f OPSGROUP
- Ad infinitum fixes
- Turn into wind fixes
2021-09-04 23:51:17 +02:00
Applevangelist
76c08095ab CTLD - added country variable for crates 2021-09-03 18:38:51 +02:00
Frank
538864519e OPSGROUP
- Fixes that ARMY and NAVYGROUPS only go to first waypoint
- Fixes for PATROL and RECON missions that waypoints are added at the end
- Some other stuff
- Still need to fix adinfinitum
2021-09-03 18:20:28 +02:00
Applevangelist
cd6631049b CSAR - Removed message for dead pilots 2021-09-03 14:16:30 +02:00
Applevangelist
079f8030b7 CTLD - added unit parameter to place crates in correct distance. Refactored location calculation for crates. 2021-09-03 14:16:11 +02:00
Frank
ad0b32c0ee OPS
- Found and fixed bugs for ARMY and NAVY groups, which caused only one waypoint to be processed
- Added Duration for AUFTRAG
- Fixed bug in auftrag if no legion was assigned and mission was canceled at opsgroup level
- Trying (again) to include the whole route for ARMY and NAVY when UpdateRoute
- Simpler task function for passing waypoint

STILL a lot to do/check!
2021-09-03 00:05:58 +02:00
Applevangelist
8235b51a14 Bug fixing 2021-09-02 18:04:39 +02:00
Frank
1bd5e7472f OPSTRANSPORT v0.4.2
- Some fixed.
- All tested demo missions look nice
2021-09-02 08:30:54 +02:00
Applevangelist
7433a7144c CTLD Added method to inject troops into the field. 2021-09-01 13:33:43 +02:00
Frank
27632ecdd9 OPSTRANSPORT v0.4.1
- Fixed a couple of bugs
- Lots of other fixes and improvements
2021-09-01 00:07:54 +02:00
Frank
0b1e25b073 OPSTRANSPORT v0.4
- Multiple transport zone combos (TZC)
- Other issues solved.
- Demo miz D-day landing is still not working correctly.
2021-08-30 23:45:40 +02:00
Applevangelist
19a93f0026 MANTIS - allow SEAD padding in Mantis 2021-08-28 13:58:06 +02:00
Applevangelist
3256a6d596 SEAD - added time-back-on padding as variable 2021-08-28 13:57:15 +02:00
Frank
28ddfa5243 OPSTRANSPORT
- Fist working steps towards multiple pickup/deploy zone combos.
2021-08-28 00:17:16 +02:00
Applevangelist
05c560be3b CTLD - added delay after unsuccessful build or repair, relocate after done 2021-08-27 18:51:54 +02:00
Applevangelist
8ddd810fe2 SEAD - Refactor and enable delayed switch-off 2021-08-27 18:50:40 +02:00
Applevangelist
f20760bae5 CSAR - Remove some noise 2021-08-27 18:48:18 +02:00
Applevangelist
cea7320a9b UNIT/GROUP - added function to get the skill of a unit. SEAD - added functionality to calculate time-2-impact of HARMS and adjust behaviour accordingly 2021-08-27 14:56:50 +02:00
Frank
fe6826016c Update Chief.lua 2021-08-27 11:59:34 +02:00
Frank
f0167b3e88 OPS
- FSM pseudo function cleanup
- Fixed bug when mission is cancelled
2021-08-27 11:31:12 +02:00
Applevangelist
0edbf7f517 Added Engineering (Infantry) Troops 2021-08-27 09:14:54 +02:00
Frank
a8a8dcff3f OPS Chief
- Removed mission queue. Now done via COMMANDER
- MissionCancel is buggy
2021-08-26 23:24:11 +02:00
Frank
1b0ad13529 OPS Commander 2021-08-26 21:24:47 +02:00
Frank
418d6c882c Update OpsGroup.lua 2021-08-25 17:46:00 +02:00
Frank
1e6899c40b OPS 2021-08-25 17:20:17 +02:00
Frank
259b201e65 OPS
Good version solving a few bugs and adding some new stuff.
2021-08-24 23:10:38 +02:00
Applevangelist
8fb113a04e CTLD - 1) added ability to limit stock. 2) Stopping Herc Pilots to try and build on the fly (look at you, Gunterlund! ;) ) 2021-08-24 14:16:11 +02:00
Frank
c6ebbc6122 OPS
Strange version buggy
2021-08-23 23:34:15 +02:00
Applevangelist
755903a08e Changed priority to show bom target height in ft, in absence of player settings 2021-08-22 11:57:49 +02:00
Applevangelist
34e4825cd0 Merge pull request #1591 from bbirchnz/develop
CTLD: fix FOB units overwriting last instance, Unit Cargo Mass not working on first load
2021-08-22 08:32:18 +02:00
Ben Birch
a68eeae9bd Merge remote-tracking branch 'origin/develop' into develop 2021-08-22 12:54:25 +10:00
Ben Birch
e4e31b554e CTLD: fix FOB units overwriting last instance, Unit Cargo Mass not working on first load 2021-08-22 12:53:55 +10:00
Frank
eba6e3f5f1 OPS Transport+Legion, Navy 2021-08-22 00:31:51 +02:00
Frank
d73ebaca76 OPS
- Lots of stuff
2021-08-21 00:58:28 +02:00
Applevangelist
94167152e5 CTLD - added ability to spawn crates on ships 2021-08-20 12:33:10 +02:00
Applevangelist
830f76e909 Cleanup UTF-8 Mess 2021-08-18 18:00:38 +02:00
Applevangelist
8ae04944fe Fix for SAM pattern matching not working 2021-08-18 14:59:58 +02:00
Applevangelist
c55b8d29f7 Fix for degree sign extra char 2021-08-18 11:51:41 +02:00
Applevangelist
30623f7d38 AIRBOSS / ATIS deleted extra char before degree char. Small correction for CSAR landings at Airports 2021-08-18 09:28:34 +02:00
Frank
16964520df OPS
- Lots of stuff to assign missions to multiple legions.
2021-08-18 00:25:18 +02:00
Frank
3050fdb3c3 OPS Zone 2021-08-15 00:28:03 +02:00
Frank
77fc2c5cf1 Update OpsGroup.lua 2021-08-12 11:41:30 +02:00
Frank
b21c3ed4e9 OPS Cleanup 2021-08-12 11:07:28 +02:00
Frank
93f4b345c5 OPS Generalization 2021-08-12 00:17:55 +02:00
Frank
88e59a2739 OPS
- Ground ops
2021-08-11 10:40:16 +02:00
Frank
86bb256bf1 OPS
- Added Cohort and Legion classes
- Added Platoon and Brigade classes
2021-08-10 00:40:17 +02:00
Applevangelist
9a05f5bc93 Merge pull request #1589 from FlightControl-Master/Applevangelist-patch-5
CSAR fix for #1588
2021-08-09 09:18:51 +02:00
Applevangelist
bce28cf389 CSAR fix for #1588
Fixes #1588
2021-08-09 09:06:15 +02:00
Frank
629c5e7739 AUFTRAG
- Recon Mission
2021-08-06 23:16:48 +02:00
Frank
ed402e2f5f OPS Chief 2021-08-06 10:01:23 +02:00
Frank
4a56c7523d Wingcommander 2021-08-05 12:44:43 +02:00
Frank
218d9f48b0 Merge branch 'FF/Ops' into FF/OpsDev 2021-08-05 00:24:23 +02:00
Frank
f67cf99477 OPS and SCHEDULER 2021-08-05 00:23:25 +02:00
Applevangelist
2201b2adda Update Utils.lua
Corrected self to BASE
2021-08-04 11:07:47 +02:00
Applevangelist
6b36421bce Merge pull request #1585 from FlightControl-Master/Applevangelist-patch-4
Update CSAR.lua
2021-08-04 08:04:21 +02:00
Frank
8c573c65d4 Update FlightControl.lua 2021-08-03 22:37:27 +02:00
Applevangelist
730dabd9cf Update CSAR.lua 2021-08-03 07:16:42 +02:00
Frank
69175e1b19 FC 2021-08-02 23:34:42 +02:00
Frank
a5ad58e516 FC 2021-08-02 21:57:53 +02:00
Frank
82b4631341 Flightcontrol 2021-08-02 18:41:33 +02:00
Frank
a1c9c1538d Merge branch 'FF/Ops' into FF/OpsDev 2021-08-02 11:59:32 +02:00
Frank
1a53f58540 OPS 2021-08-02 11:57:45 +02:00
Applevangelist
1b414b840e added AP check on landing/rescue 2021-07-31 15:50:50 +02:00
Applevangelist
642cc0e98f Added self.FARPRescueDistance reduced landing check to one call 2021-07-31 13:05:51 +02:00
Applevangelist
63431bb54b Couple of changes to make finding the distance to nearest pilot more stable 2021-07-30 17:30:32 +02:00
Frank
d64de26ded OPS
- many fixes and improvements
2021-07-29 13:43:29 +02:00
Applevangelist
8b45067226 Various patches for AI_CARGO 2021-07-29 12:41:27 +02:00
Applevangelist
061032e3d7 Transition cleanup for AI Helicopter, deleted speed test bc in 20% of cases AI lands shit, which stops the FSM 2021-07-28 18:31:39 +02:00
Applevangelist
82432686aa Fixed display messages to all SAR, added option to suppress messaging 2021-07-27 14:10:10 +02:00
Applevangelist
b66d2039be Added function to set speed and height parameters for landing 2021-07-27 14:09:10 +02:00
Applevangelist
d245a73d7f Make Destroy() silent for scoring 2021-07-26 09:24:52 +02:00
Applevangelist
f0037151e6 CTLD - added factor for troops extraction, making Destroy()s silent for scoring, refined autohoverload messaging 2021-07-26 09:24:35 +02:00
Applevangelist
52d494f573 Merge pull request #1582 from bbirchnz/develop
CTLD: fix troops being lost when crates dropped
2021-07-25 09:06:16 +02:00
Ben Birch
36a2d71731 CTLD: fix troops being lost when crates dropped 2021-07-25 13:46:15 +10:00
Frank
615a220acb Update OpsGroup.lua 2021-07-24 23:56:27 +02:00
Frank
c718584755 Update OpsGroup.lua 2021-07-24 23:25:26 +02:00
Applevangelist
4db0ea616d Correct opendoor check to include anyone loaded 2021-07-24 15:53:20 +02:00
Applevangelist
5439e60078 Merge pull request #1580 from bbirchnz/ctld-add-mass
CTLD: Enable mass on cargo
2021-07-24 15:04:49 +02:00
Ben Birch
a6880d4569 Add SetUnitInternalCargo to UNIT
Add PerCrateMass to CTLD_CARGO (default = 0kg)
Update unit internal cargo after each load/unload operation.
Add mass to cargo reports
2021-07-24 22:39:26 +10:00
Frank
65e852f341 OPS Transport 2021-07-24 01:06:44 +02:00
Frank
4ffdf9e536 Merge branch 'develop' into FF/Ops 2021-07-23 18:49:35 +02:00
Applevangelist
8f698e3e62 Changed Messaging Structure on Approach 2021-07-23 16:29:56 +02:00
Applevangelist
61481e6e9a CSAR updates to messaging. Detect if far approach note exceeds 8km for smoke/flare request 2021-07-23 11:19:53 +02:00
Applevangelist
49397df90b CTLD - added repair capabilties for VEHICLE and FOB types of CTLD_CARGO 2021-07-22 20:17:40 +02:00
Applevangelist
7b254a08fb Merge pull request #1579 from FlightControl-Master/Applevangelist-inteldlink
Update Intelligence.lua
2021-07-22 11:37:51 +02:00
Applevangelist
5bebbcf5eb Update Intelligence.lua
Added FSM functions and documentation for INTEL_DLINK
2021-07-22 11:36:21 +02:00
Applevangelist
83fd48e2f4 Merge pull request #1578 from madmoney99/develop
Airboss update for wind over deck
2021-07-22 08:03:32 +02:00
madmoney99
f5b25370b0 Change to wind measure for Skipper
Previous value 50m produced an incorrect heading and strength based on the actual wind over deck.
2021-07-21 22:51:29 -07:00
Tony Goodale
f68d3209ac Merge branch 'FlightControl-Master:develop' into develop 2021-07-21 22:44:11 -07:00
Applevangelist
2ab7f784c9 Merge pull request #1576 from FlightControl-Master/Applevangelist-CTLD
Update CTLD.lua
2021-07-21 18:47:52 +02:00
Applevangelist
1e8d99a591 Merge pull request #1577 from FlightControl-Master/Applevangelist-INTEL
Update Intelligence.lua
2021-07-21 18:47:40 +02:00
Applevangelist
d517cba765 Update Intelligence.lua
no dupe docs
2021-07-21 18:45:57 +02:00
Applevangelist
552eb5b9d8 Update CTLD.lua
Add housekeeping for dropped troops
2021-07-21 18:40:43 +02:00
Applevangelist
684c4ea113 Allow MANTIS to use INTEL_DLINK 2021-07-21 18:22:46 +02:00
Applevangelist
4dfaca610f INTEL - bug fixes, added new datalink class 2021-07-21 18:22:31 +02:00
Applevangelist
8a53998251 MANTIS - make start random async, so detection for multiple MANTIS objects works better
INTEL - added function to alter detection types, typos corrected etc
2021-07-20 18:30:11 +02:00
bbirchnz
6690f70b05 fix CTLD:ActivateZone not processing default correctly and using wrong zone table (#1575) 2021-07-19 07:16:21 +02:00
Applevangelist
96d1d3cb66 Light code cleanup, added docu for troop extract 2021-07-18 14:53:00 +02:00
bbirchnz
09785ef451 - ctld: add troop extract (#1574) 2021-07-18 13:01:45 +02:00
Applevangelist
25e118f3dc Added correct Player Mi-8MT unitname
CSAR - logic change to detect dead pilots, if they are not set to immortal. Added FSM event "KIA"
2021-07-17 15:48:18 +02:00
Frank
78b3e3c60b OPS Respawn 2021-07-15 22:25:02 +02:00
Applevangelist
efe41a5e21 CSAR and CTLD - use Frequency generation moved to UTILS
CTLD - added option to drop crates anywhere
MANTIS - added state tracker to call Green/Red state change events only once
UTILS - added Marianas NDBs to Frequency generation
2021-07-15 17:16:30 +02:00
Frank
835041e5f6 OPS 2021-07-14 21:00:34 +02:00
Applevangelist
93a8086ff6 Update Mantis.lua (#1569)
Added state tracker so that Red/Green Events only get triggered when a state actually changes.
2021-07-14 15:37:57 +02:00
Applevangelist
1ac40684de Added option to force description on injected pilots for scripting 2021-07-14 08:39:54 +02:00
Applevangelist
433d1bbf57 MANTIS - Change logic to FSM, added functions
CSAR - advanced options to name injected AI downed pilots
CTLD - added Herc speed check
2021-07-13 17:50:44 +02:00
Applevangelist
e33de03522 CSAR - honor settings NM vs KM
CTLD - documentation corrections
UTILS - added functions to generate beacon frequency tables FM,VHF,UHF and valid laser codes for JTACs
2021-07-12 19:17:39 +02:00
Applevangelist
86fedbfaae Updated noise level 2021-07-12 18:16:22 +02:00
Applevangelist
c0f4eef896 Slightly changed versions of Mantis, Sead and Shorad as the Emissions On/Off stuff ED introduced doesn't really work well. 2021-07-12 18:10:12 +02:00
Frank
a2f3bf3a8c Merge branch 'develop' into FF/Ops 2021-07-12 15:27:24 +02:00
Frank
1b717e4683 AUFTRAG
- Added push time
2021-07-12 15:27:08 +02:00
Applevangelist
52e2ac7174 Added documentation 2021-07-11 18:31:17 +02:00
Applevangelist
3d6b053eb4 Added function to check if a loading door on a heli is open 2021-07-11 18:31:09 +02:00
Frank
268eb1d60d OPS 2021-07-11 18:15:25 +02:00
Applevangelist
a69865b8c9 -- -- (added 0.1.8) - allow to set far/near distance for approach and optionally pilot must open doors
--         self.approachdist_far = 5000 -- switch do 10 sec interval approach mode, meters
--         self.approachdist_near = 3000 -- switch to 5 sec interval approach mode, meters
--         self.pilotmustopendoors = false -- switch to true to enable check of open doors
2021-07-10 16:56:35 +02:00
Applevangelist
4a1df3d5cc -- -- (added 0.1.8) - allow to set far/near distance for approach and optionally pilot must open doors
--         self.approachdist_far = 5000 -- switch do 10 sec interval approach mode, meters
--         self.approachdist_near = 3000 -- switch to 5 sec interval approach mode, meters
--         self.pilotmustopendoors = false -- switch to true to enable check of open doors
2021-07-10 16:56:35 +02:00
Frank
6dfd757ea1 OPS 2021-07-08 22:59:29 +02:00
Frank
fc1adf3b94 OPS Transport 2021-07-08 12:21:10 +02:00
Frank
be2d1d7895 Update OpsTransport.lua 2021-07-07 11:33:51 +02:00
Frank
9e7c360912 Merge branch 'develop' into FF/Ops 2021-07-06 21:57:31 +02:00
Frank
51acd33d19 Merge branch 'master' into develop 2021-07-06 21:57:08 +02:00
Frank
af3dbe2f86 Merge branch 'develop' into FF/Ops 2021-07-06 21:56:53 +02:00
Frank
97668e5413 Update FlightGroup.lua
- Fixed flight of airwing is going to tanker even if fuellowrefuel switch is false
2021-07-06 21:56:15 +02:00
Frank
464fde0ed2 OPS
- MSRS
- Callsign
2021-07-06 21:13:50 +02:00
cammel tech
65bd7909e1 Example for CTLD > SCORING added (#1566)
* Example added

Example for the connection to the SCORING Class.

* kleiner Fehler eingeschlichen
2021-07-06 20:26:20 +02:00
Applevangelist
5d3ea57d4d CSAR give scripted spawned pilots a name.
CTLD corrected that generic troops could be spawned only once.
2021-07-06 20:24:35 +02:00
Applevangelist
b7bc3cfbcf Spawn crates in a wider radius. Also build, when only one crate is required. 2021-07-05 18:54:45 +02:00
Applevangelist
04ef32420b Merge pull request #1567 from thejuju/develop
Add ATC Ground Mariana Islands support
2021-07-05 14:44:02 +02:00
Julien B
a3d8a48b92 Add ATC Ground Mariana Islands support
Added ATC_GROUND_MARIANAISLANDS
Supported optional airbase ZONE_POLYGON boundaries (like initially intented) when there is provided, fallback remain a ZONE from the center of the airfield.
Some airports are bigger than the default radius area and need custom boundaries to work properly on the edge of it.
2021-07-05 13:09:34 +02:00
Applevangelist
ef86d1d7cb Merge pull request #1562 from cammeltech/SCORING-reactivate_destroy
Reactivate the :destroy() event on clients with scoring below thresmark
2021-07-04 18:10:45 +02:00
Applevangelist
00b3e9b371 Merge pull request #1564 from justin-lovell/justin-lovell-mark-changed-event
Synchronize Text with Wrapper State
2021-07-04 18:10:35 +02:00
Applevangelist
0d02f56855 Merge pull request #1565 from justin-lovell/updated-debug-msg
Correcting typo for debug message
2021-07-04 18:10:21 +02:00
Applevangelist
48aa841add ATIS - addede rainy presets 1-3
CTLD - avoid "preloading" when pilot leaves/crashes and rejoins
CSAR - added option for autosmokedistance
2021-07-04 18:04:27 +02:00
Applevangelist
4ba52212a9 ATIS - addede rainy presets 1-3
CTLD - avoid "preloading" when pilot leaves/crashes and rejoins
CSAR - added option for autosmokedistance
2021-07-04 18:04:08 +02:00
Justin Lovell
a14bca1059 Synchronize Text with Wrapper State
Bug - text is not synchronized with the wrapper state, hence the `GetText()` will be incorrect.

Method `TextChanged` does not exist, resulting `nil` reference errors when the players update markers. Current implementation of `MARKER:OnEventMarkChange(EventData)` is not implemented the same as its siblings of `OnEventMarkRemoved` and `OnEventMarkAdded`. The siblings would move the FSM accordingly -- aligned implementation
2021-07-03 23:30:45 +10:00
Justin Lovell
a7e07af24f Correcting typo for debug message
Small PR
2021-07-03 23:24:04 +10:00
Applevangelist
e14d655447 Changed default fallback freq to 333.00Khz 2021-07-03 09:30:04 +02:00
Frank
74bdeaf4f7 AIRWING 2021-07-02 23:11:51 +02:00
Applevangelist
9591c62175 corrected autovalue for frequency - thanks to shadowze 2021-07-02 20:22:43 +02:00
Applevangelist
39c46dcab0 Changed frequency logic, some documentation changes 2021-07-02 20:15:12 +02:00
Applevangelist
299e08f53d additional checks to ensure only human players, extra checks in the logic, some logic errors corrected. 2021-07-02 17:52:58 +02:00
wob3155@posteo.de
12555a6ff1 Reactivate the :destroy() event on clients with scoring below thresmark 2021-07-02 08:56:28 +02:00
Frank
1cc012c7d1 Merge branch 'develop' into FF/Ops 2021-07-02 08:53:44 +02:00
Frank
28c6810878 Merge branch 'master' into develop 2021-07-02 08:52:07 +02:00
Frank
1ed36fdff4 Merge branch 'develop' into FF/Ops 2021-07-01 23:56:38 +02:00
Frank
26801cf206 Merge branch 'master' into develop 2021-07-01 23:54:57 +02:00
Frank
c80cebb824 WAREHOUSE, AIRWING & SQUADRON
- Added function for hot start to SQUADRON
- Addressed bug #1560
2021-07-01 23:54:24 +02:00
Frank
3c6e8d6d01 OPS
- Transport
- Respawn
2021-07-01 12:29:29 +02:00
Applevangelist
76a53ab154 Added extra checks for Beacon refresh 2021-07-01 09:07:01 +02:00
Frank
fa3e387dd1 OPS 2021-06-30 23:23:41 +02:00
Applevangelist
dca626bbcb CTLD - added option to suppress messaging, added event for OnAfterTroopsRTB
CSAR - minor bugfix
2021-06-30 17:59:43 +02:00
Applevangelist
3289ad2817 Added basic support for Hercules mod 2021-06-29 17:49:42 +02:00
Applevangelist
5a022a2246 Messages going to SAR flights only 2021-06-29 08:50:46 +02:00
Frank
b012c5b2aa OPS Transport
- Improved cargo bay weight calculation.
2021-06-28 13:17:55 +02:00
Frank
a861f8d9d4 OPS 2021-06-25 21:13:24 +02:00
Frank
36669c80da OPSTRANSPORT 2021-06-25 13:23:56 +02:00
Applevangelist
2ff128f184 Added Docu for functions 2021-06-25 12:39:02 +02:00
Applevangelist
3b44aba341 Updated frequency test 2021-06-24 08:34:14 +02:00
Frank
978be4e383 OPS Transport 2021-06-23 17:20:51 +02:00
Applevangelist
d4cdfcc48c Corrected Mi-8MTV2 Unit Type Name 2021-06-23 14:09:09 +02:00
Applevangelist
5123ab0720 Update CTLD.lua (#1558)
corrected fsm function name headlines in documentation
2021-06-23 09:47:05 +02:00
Applevangelist
5021a1e1f3 Update CTLD.lua 2021-06-22 18:26:44 +02:00
Applevangelist
576281a612 Update CSAR.lua (#1554)
Added options to limit number of downed pilots via Events (mission designers can still "inject" downed pilots):
`self.limitmaxdownedpilots = true
 self.maxdownedpilots = 10`
2021-06-22 18:24:46 +02:00
Applevangelist
b84c0aba59 Update Moose.files (#1556) 2021-06-22 18:24:36 +02:00
Applevangelist
ee503a378e Update Modules.lua (#1557)
added CTLD
2021-06-22 18:24:24 +02:00
Applevangelist
f235037cb9 Create CTLD.lua (#1555)
Player Heli Cargo and Troops Ops :)
2021-06-22 18:24:11 +02:00
Applevangelist
0cd1cd97a6 Update CSAR.lua (#1553) 2021-06-22 13:11:12 +02:00
Frank
74513f1b5c Merge branch 'develop' into FF/Ops 2021-06-22 12:18:45 +02:00
Frank
231c5bfea7 Ops 2021-06-22 12:18:25 +02:00
Frank
cfd0e4ba85 Merge branch 'master' into develop 2021-06-19 22:28:30 +02:00
Applevangelist
bf33e4ed4f Update CSAR.lua (#1552) 2021-06-18 12:12:54 +02:00
Frank
6290db035d Merge branch 'develop' into FF/Ops 2021-06-15 22:00:14 +02:00
Applevangelist
cd1935be1d Update CSAR.lua (#1551) 2021-06-15 15:49:58 +02:00
Applevangelist
64262d6ecc Update CSAR.lua (#1550) 2021-06-15 10:32:52 +02:00
Applevangelist
270c69344f Update CSAR.lua
Updated documentation / clarification. Added feature docu on using SRS
2021-06-15 07:42:45 +02:00
Applevangelist
10a0793af7 Update CSAR.lua
Small updates to reflect correct measurements. Options to SRS TTS.
2021-06-14 19:15:58 +02:00
Applevangelist
1b37af321f Update CSAR.lua
Small updates
2021-06-14 16:21:47 +02:00
Applevangelist
7cde279be1 Update Modules.lua
added CSAR module
2021-06-14 13:20:00 +02:00
Applevangelist
0396741f3d Create CSAR.lua
Initial Release
2021-06-14 13:18:27 +02:00
Applevangelist
117cf8888a Update Globals.lua 2021-06-13 10:39:07 +02:00
Frank
83db7b32e8 Merge branch 'master' into FF/Ops 2021-06-12 22:59:20 +02:00
Frank
d496d3d16e Merge branch 'master' into develop 2021-06-12 22:23:10 +02:00
Frank
6b801247ab Merge branch 'FF/MasterDevel' into FF/Ops 2021-06-11 23:41:52 +02:00
Frank
4c6cd31bfc Merge branch 'FF/MasterDevel' into FF/Ops 2021-06-10 23:33:27 +02:00
Frank
a8ef096f24 Merge branch 'FF/MasterDevel' into FF/Ops 2021-06-10 23:23:30 +02:00
Applevangelist
c8d2a7e833 Added commands for immortal and invisible to Wrapper.Group#GROUP (#1547)
* Added function for message duration (#1542)

... and correct flash status setting

* Update Spawn.lua (#1544)

* Update Spawn.lua

* Update Group.lua (#1546)

Added invisible and immortal commands on GROUP level.
2021-06-10 11:59:50 +02:00
Frank
783391838b Merge branch 'FF/MasterDevel' into FF/Ops 2021-06-10 00:19:02 +02:00
Frank
7c37d8b204 Merge branch 'FF/MasterDevel' into FF/Ops 2021-06-09 13:19:14 +02:00
Applevangelist
65ed8825b0 Update Intelligence.lua
Added functionality to calculate the position of a cluster after x seconds, based on trajectory (average speed and heading) of a cluster
*  INTEL:CalcClusterFuturePosition(cluster,seconds)
Will also draw arrows on the map if `self.clustermarkers` is true and `self.verbose > 1`
Change cluster coordinate updates to better suite cluster movement
2021-06-08 15:59:36 +02:00
Applevangelist
af9324dd5f master updates to develop for InitCleanup() and CC Messages (#1545)
* Added function for message duration (#1542)

... and correct flash status setting

* Update Spawn.lua (#1544)

* Update Spawn.lua
2021-06-07 18:26:43 +02:00
Frank
064f727676 Merge branch 'FF/MasterDevel' into FF/Ops 2021-06-05 23:45:15 +02:00
Frank
8025862fb9 Merge branch 'FF/MasterDevel' into FF/Ops 2021-06-01 23:20:59 +02:00
Frank
2544ec5587 Update SRS.lua 2021-05-30 01:44:36 +02:00
Frank
6c823b0137 Merge branch 'FF/MasterDevel' into FF/Ops 2021-05-30 01:36:43 +02:00
Frank
88d44fa654 Merge branch 'develop' into FF/Ops 2021-05-28 23:01:47 +02:00
Frank
8b6f9f9de7 Merge branch 'master' into develop 2021-05-28 23:01:15 +02:00
Applevangelist
cb14961dcd Update Zone.lua (#1541)
added function `ZONE_POLYGON_BASE:Boundary()`
2021-05-26 15:54:20 +02:00
Applevangelist
dab486ec99 Update Controllable.lua
Typo in `OptionDisperseOnAttack()`
2021-05-26 09:16:26 +02:00
Shadowze
75849fbfb5 Update Positionable.lua
function added to work out if a unit is a submarine
2021-05-25 22:30:16 +01:00
Frank
f984ff044b Merge branch 'master' into develop 2021-05-25 21:13:36 +02:00
Frank
aaf5f295da Merge branch 'develop' into FF/Ops 2021-05-20 23:27:05 +02:00
Frank
8f612f2017 Merge branch 'master' into develop 2021-05-20 23:25:29 +02:00
Frank
a2808163a7 Boom and Probe 2021-05-20 23:23:12 +02:00
Frank
e4aa23ce3d Update Point.lua 2021-05-15 00:29:20 +02:00
Frank
1b3cac9424 Merge branch 'FF/MasterDevel' into FF/Ops 2021-05-13 23:38:17 +02:00
Applevangelist
e49020b905 Update README.md 2021-05-12 09:19:07 +02:00
Frank
d68dcaf69a Merge branch 'develop' into FF/Ops 2021-05-11 14:52:31 +02:00
Frank
856c3578f6 Merge branch 'master' into develop 2021-05-11 11:59:48 +02:00
Tony Goodale
18c6ea39ce Merge pull request #7 from FlightControl-Master/develop
Develop
2021-05-10 15:47:14 -07:00
Frank
1ce46c016c Cargo 2021-05-10 00:14:07 +02:00
Frank
296944c23c Merge branch 'develop' into FF/Ops 2021-05-07 22:57:34 +02:00
Frank
4f772fecdc Merge branch 'master' into develop 2021-05-07 21:56:17 +02:00
Frank
cdd22444b9 Merge branch 'master' into develop 2021-05-07 21:49:24 +02:00
Frank
15848bc8c4 Merge branch 'master' into FF/Ops 2021-05-07 17:47:41 +02:00
Applevangelist
9eba6d607c Updated doc images 2021-05-06 09:30:06 +02:00
Applevangelist
e9d3c7c2e7 Update MarkerOps_Base.lua 2021-05-05 19:02:46 +02:00
Applevangelist
ad16c6d44f Include MarkerOps_Base (#1533)
Include MarkerOps_Base
2021-05-05 11:56:00 +02:00
Applevangelist
2046958bd6 Added MarkerOps_Base.lua 2021-05-05 11:44:35 +02:00
Applevangelist
0046533d53 Added base class for action based on marker additions, changes, deletions and text keywords 2021-05-05 11:44:17 +02:00
Applevangelist
ce7e152e13 Updated Shorad and Set 2021-05-04 12:59:21 +02:00
Tony Goodale
edcdc057e6 Merge pull request #6 from FlightControl-Master/develop
Develop
2021-05-01 15:40:23 -07:00
Frank
cfa851beea Merge branch 'master' into FF/Ops 2021-05-02 00:25:07 +02:00
Frank
f5d8efe86e Merge branch 'master' into develop 2021-05-01 22:45:48 +02:00
Applevangelist
7c8e5033ec Merge pull request #1527 from FlightControl-Master/AA-1
Update Sead.lua
2021-05-01 17:29:43 +02:00
Applevangelist
22ec94b374 Merge pull request #1528 from FlightControl-Master/AA-2
Update Shorad.lua
2021-05-01 17:27:22 +02:00
Applevangelist
5cd3a172f1 Merge pull request #1529 from FlightControl-Master/AA-3
Update Mantis.lua
2021-05-01 17:24:33 +02:00
Applevangelist
a89a3b38ce Update Mantis.lua
Adjustments for 2.7
2021-05-01 17:21:53 +02:00
Applevangelist
3202702612 Update Shorad.lua
Adjustments for 2.7
2021-05-01 17:20:35 +02:00
Applevangelist
725e32f439 Update Sead.lua
Adjust to Event changes
2021-05-01 17:19:10 +02:00
Applevangelist
7da1905ad3 Update Event.lua (#1525)
Updates for Events 33 and 6 - makes scoring also work again for STATIC targets
2021-05-01 14:22:01 +02:00
Frank
421005a3b6 event backfixed 2021-04-30 11:53:57 +02:00
Applevangelist
d5bf28f799 Update AirWing.lua (#1521)
Markpoint honored for direct calls from #OPSGROUP
2021-04-29 18:20:03 +02:00
Frank
990f748e42 Update Database.lua 2021-04-27 09:19:33 +02:00
Applevangelist
a466365949 Update Controllable.lua (#1519)
Error line 1463
2021-04-25 20:31:02 +02:00
Frank
b12f71c430 Merge branch 'develop' into FF/Ops 2021-04-23 13:38:28 +02:00
Frank
236a69e5dc Merge branch 'master' into develop 2021-04-23 13:29:37 +02:00
Applevangelist
9458243926 Merge pull request #1516 from FlightControl-Master/AA
Update Controllable.lua
2021-04-23 11:00:50 +02:00
Applevangelist
41274e7801 Update Controllable.lua 2021-04-23 10:59:22 +02:00
Applevangelist
0259e41ce8 Create .luacheckrc 2021-04-22 10:10:59 +02:00
Applevangelist
e78f9cbd46 Merge pull request #1512 from FlightControl-Master/aa
Update Airboss.lua
2021-04-22 08:53:52 +02:00
Applevangelist
9d6851adec Update Airboss.lua
Escape error 17933
2021-04-22 08:30:19 +02:00
Applevangelist
4668f072af Merge pull request #1511 from FlightControl-Master/AA-1
Update Airboss.lua
2021-04-22 08:21:00 +02:00
Applevangelist
a1a414925f Update Airboss.lua 2021-04-22 08:19:56 +02:00
Applevangelist
19eb9dca30 Update Utils.lua 2021-04-20 18:49:54 +02:00
Applevangelist
8464a2ba43 Merge pull request #1507 from FlightControl-Master/Applevangelist-patch-1
Update Airbase.lua
2021-04-20 16:52:28 +02:00
Applevangelist
a8549e2b7d Update Airbase.lua 2021-04-20 16:50:00 +02:00
Applevangelist
2531a25c9e Update Group.lua
Add EnableEmissions
2021-04-20 11:36:59 +02:00
Frank
2f7b7eeddd Merge branch 'master' into develop 2021-04-18 14:49:37 +02:00
Frank
ab1ec54c03 Merge branch 'master' into develop 2021-04-18 14:34:46 +02:00
Frank
a1ca605206 Merge branch 'master' into develop 2021-04-17 23:19:42 +02:00
Frank
a7b444dfea Update OpsGroup.lua 2021-04-17 09:29:55 +02:00
Frank
64b35b9cb3 Merge branch 'develop' into FF/Ops 2021-04-16 23:15:30 +02:00
Frank
4a8d52b328 Merge branch 'master' into develop 2021-04-16 23:06:04 +02:00
Pikes
3cbf6fff90 Merge pull request #1490 from Applevangelist/patch-82
Update Event.lua workaround for 2.7
2021-04-16 18:01:25 +01:00
Frank
2693e76483 Update Airboss.lua 2021-04-15 21:13:35 +02:00
Applevangelist
b232a5da37 Update Event.lua workaround for 2.7
Same as for Event 31
2021-04-15 13:02:59 +02:00
Frank
e50fc00583 Merge branch 'develop' into FF/Ops 2021-04-14 23:44:43 +02:00
Frank
4b8802af37 Merge branch 'master' into develop 2021-04-14 23:42:48 +02:00
Frank
ebd69fd10d Merge pull request #1482 from Applevangelist/patch-74
Update FlightGroup.lua
2021-04-12 15:55:50 +02:00
Applevangelist
c1a8c08880 Update FlightGroup.lua 2021-04-12 13:02:16 +02:00
Frank
647fb6acbf Merge branch 'develop' into FF/Ops 2021-04-07 20:54:19 +02:00
Frank
ede692ea2a Merge branch 'master' into develop 2021-04-07 20:53:27 +02:00
Frank
ca44e2762b Update OpsGroup.lua 2021-04-07 20:53:15 +02:00
Frank
eda70742eb Merge pull request #1486 from Applevangelist/patch-78
Update AirWing.lua
2021-04-04 22:03:49 +02:00
Frank
b81e3e9e6d Merge pull request #1485 from Applevangelist/patch-77
Update Intelligence.lua
2021-04-04 22:03:40 +02:00
Applevangelist
e766eaeccc Update AirWing.lua
Avoid loop if mission is governed by an Airwing. Mission cancel will ask airwing to cancel will ask flightgroup to cancel, which doesn't work if the latter is dead. Rare but happens.
2021-04-04 13:11:25 +02:00
Applevangelist
bab61271f2 Update Intelligence.lua
Make Markers Coalition specific
2021-04-04 13:07:54 +02:00
Applevangelist
b1465d89a6 Update FlightGroup.lua
Added check for velocity for the RTB loop (if group is taxiing). Added OutOfAAMissiles.
2021-04-04 12:49:40 +02:00
Frank
05b1ddf013 Merge pull request #1483 from Applevangelist/patch-75
Update AirWing.lua
2021-04-03 22:25:51 +02:00
Applevangelist
903e8711f7 Update AirWing.lua
Make Patrolpoint Markes Switchable
2021-04-01 13:28:59 +02:00
Applevangelist
31b93fb42c Update FlightGroup.lua
Avoid endless when plane/heli is not airborne by needs to RTB
2021-04-01 13:21:40 +02:00
Frank
e16bbfc2b9 Merge branch 'develop' into FF/Ops 2021-03-29 19:55:35 +02:00
Frank
220e004d73 Merge branch 'master' into develop 2021-03-29 19:55:21 +02:00
Frank
3136861b24 Merge branch 'develop' into FF/Ops 2021-03-29 18:02:23 +02:00
Frank
dc2693bead Merge branch 'master' into develop 2021-03-29 18:02:00 +02:00
Frank
d7da8c4253 Merge branch 'develop' into FF/Ops 2021-03-29 09:55:13 +02:00
Frank
c1ff5831ad Merge branch 'master' into develop 2021-03-29 09:53:51 +02:00
Frank
ac5646075b Merge pull request #1481 from madmoney99/develop
Airboss CASE III fix for OS/AA
2021-03-29 00:31:46 +02:00
madmoney99
5a1faba796 CASE III fix for OS/AA 2021-03-28 15:25:59 -07:00
Tony Goodale
4ab16cb276 Merge pull request #5 from FlightControl-Master/develop
Merge pull request #1478 from madmoney99/develop
2021-03-28 15:12:27 -07:00
Frank
eb1e885c0a Merge branch 'develop' into FF/Ops 2021-03-28 20:33:08 +02:00
Frank
00ff9a11b8 Merge branch 'master' into develop 2021-03-28 20:30:19 +02:00
Frank
8eabc024bf Merge pull request #1479 from madmoney99/develop
Update Airboss.lua
2021-03-23 08:44:14 +01:00
madmoney99
a848af0753 Update Airboss.lua 2021-03-22 19:01:04 -07:00
Frank
f4e7a3a314 Merge pull request #1478 from madmoney99/develop
Airboss formating fixes
2021-03-22 22:19:29 +01:00
madmoney99
d83283c709 Update Airboss.lua
formatting fixes
2021-03-22 10:10:33 -07:00
Tony Goodale
a35112a6f3 Merge pull request #4 from FlightControl-Master/develop
Merge pull request #1476 from madmoney99/develop
2021-03-22 10:01:53 -07:00
Frank
66c012a30d Merge pull request #1476 from madmoney99/develop
Develop Airboss grading additions
2021-03-22 12:03:58 +01:00
madmoney99
7b92b7853d Grading Additions
Addition of:
- AA - Angled Approach call (advisory)
- Drift Right/Left - DR/DL (advisory)
- Overshoot - OS - graded for start

Updated default SetMPWireCorrection(Dcorr) to 12 from 8.7 based on feedback.

Minor clean up and updates for intro section to include new additions and other changes previously made.

TonyG
2021-03-21 17:40:44 -07:00
madmoney99
6c9f10e6a8 Revert "Grading additions"
This reverts commit 6db2c4465d.
2021-03-21 17:38:06 -07:00
madmoney99
6db2c4465d Grading additions
Addition of:
 - AA - Angled Approach call (advisory)
 - Drift Right/Left - DR/DL (advisory)
 - Overshoot - OS - graded for start

Updated default SetMPWireCorrection(Dcorr) to 12 from 8.7 based on feedback.

Minor clean up and updates for intro section to include new additions and other changes previously made.

TonyG
2021-03-21 17:35:16 -07:00
Tony Goodale
c0cc960df5 Merge pull request #3 from FlightControl-Master/develop
Develop
2021-03-21 14:53:53 -07:00
Frank
968240ad44 Merge pull request #1473 from Applevangelist/patch-72
Update Sead.lua
2021-03-14 22:46:16 +01:00
Applevangelist
50f3016711 Update Sead.lua
latest
2021-03-10 11:36:10 +01:00
Frank
56e2b06e9d OPS Cargo 2021-03-07 23:47:29 +01:00
Frank
c02f69720a Merge pull request #1471 from Applevangelist/patch-71
Update Controllable.lua
2021-03-04 16:33:56 +01:00
Frank
96df7d1e42 Merge pull request #1470 from Applevangelist/patch-70
Update Intelligence.lua
2021-03-04 16:33:46 +01:00
Applevangelist
1d4caf7588 Update Controllable.lua
2 functions missing though they are in the doc header
2021-03-04 16:15:57 +01:00
Applevangelist
b0e3201d3c Update Intelligence.lua
Added Docu
2021-03-04 11:13:30 +01:00
Frank
bab097958f Merge branch 'develop' into FF/Ops 2021-03-03 00:03:52 +01:00
Frank
f4a3f6d433 OPS 2021-03-03 00:03:39 +01:00
Frank
e73ab89a18 Merge pull request #1469 from madmoney99/develop
Develop
2021-03-02 22:46:31 +01:00
madmoney99
187643f6ae Groove time additions
Changes on screen description of groove times to match NATOPs grading
NESA
LIG
Changes unicorn groove time from 16-18secs to 15-18.99 seconds.

No change to grading.  Reference GitHub issues 1445 &1446.
2021-03-02 13:36:54 -08:00
Tony Goodale
3c9bdb2915 Merge pull request #1 from FlightControl-Master/develop
Develop
2021-03-02 13:28:58 -08:00
Frank
5241642447 Merge branch 'master' into develop 2021-03-02 21:19:41 +01:00
Frank
3b2cbea1c4 Update OpsGroup.lua 2021-03-02 21:12:51 +01:00
Frank
80e3da49cb Merge pull request #1468 from Applevangelist/patch-69
Update Intelligence.lua
2021-03-02 15:34:27 +01:00
Applevangelist
1df7a12587 Update Intelligence.lua
Finalized Cluster functions, added bits and bobs
2021-03-02 14:28:37 +01:00
Frank
663a59bd71 Merge branch 'master' into develop 2021-02-28 23:26:48 +01:00
Frank
ced859424b Merge branch 'master' into develop 2021-02-27 21:18:11 +01:00
Frank
4a6377c204 Ops Cargo 2021-02-27 21:17:58 +01:00
Frank
fd22558207 Merge pull request #1467 from madmoney99/develop
T-45C Goshawk Parameters
2021-02-26 08:00:35 +01:00
madmoney99
a6faadea48 T-45C Goshawk Parameters
Addition of parameters for the VNAO T-45C Goshawk.
2021-02-25 12:52:50 -08:00
Frank
42a26100b7 Merge pull request #1465 from Applevangelist/patch-67
Update Intelligence.lua
2021-02-24 18:02:19 +01:00
Frank
e8f4770abe Merge pull request #1464 from Applevangelist/patch-66
Update AirWing.lua
2021-02-24 18:01:44 +01:00
Applevangelist
7751d4ee88 Update Intelligence.lua
Added function to set verbosity
2021-02-24 16:22:13 +01:00
Applevangelist
cdd829e7be Update AirWing.lua
Ensure correct type of tanker is going on mission
2021-02-24 16:16:28 +01:00
Frank
16bf3a89b5 Merge pull request #1461 from Applevangelist/patch-63
Update Intelligence.lua
2021-02-21 23:59:37 +01:00
Applevangelist
11cdae098b Update Intelligence.lua
Honor settings for clustermarkers
2021-02-21 19:55:48 +01:00
Frank
a63ee3fa8b Merge branch 'develop' into FF/Ops 2021-02-21 11:54:06 +01:00
Frank
5cc023d1fe OPS Cargo 2021-02-21 11:53:52 +01:00
Frank
c4084156ac OPS Cargo 2021-02-21 00:19:32 +01:00
Frank
302018feff OPS Cargo 2021-02-20 00:03:45 +01:00
Frank
c50f6b72e7 OPS Cargo 2021-02-19 00:11:55 +01:00
Frank
c0401447dd OPS Cargo 2021-02-18 00:10:17 +01:00
Frank
43680c2fc3 Merge branch 'master' into develop 2021-02-17 13:16:46 +01:00
Frank
2c92bb9d61 OPS Cargo 2021-02-17 00:29:59 +01:00
Frank
dcf1a56756 Update OpsGroup.lua 2021-02-16 00:15:22 +01:00
Frank
5990ab1cc9 OPSTRANSPORT
- New class.
2021-02-15 23:19:35 +01:00
Frank
084499fa0e OPS Wait 2021-02-14 00:19:03 +01:00
Frank
74e84a73dd OPS Cargo 2021-02-13 00:09:25 +01:00
Frank
96b0393f91 OPS Cargo 2021-02-11 23:58:56 +01:00
Frank
0656c33e05 Update OpsGroup.lua 2021-02-10 23:50:37 +01:00
Frank
ec1ab49b54 Merge pull request #1447 from Applevangelist/patch-51
Update Auftrag.lua
2021-02-10 21:34:12 +01:00
Applevangelist
1daa2857b2 Update Auftrag.lua
Corrected docu in NewTanker, 1 is actually boom, and 0 probe
2021-02-10 13:19:53 +01:00
Frank
8c55541d0e Update OpsGroup.lua 2021-02-08 16:27:58 +01:00
Frank
c5a4776b3a OPS Cargo 2021-02-07 01:24:13 +01:00
Frank
8bb9f0d7c0 OPS Cargo 2021-02-06 09:41:24 +01:00
Frank
7d83c251a8 OPS Cargo 2021-02-03 22:51:18 +01:00
Frank
ee3ead9aac OPS Cargo 2021-02-02 23:20:55 +01:00
Frank
54896e0e31 Merge pull request #1444 from rollnthndr/develop
Added a note pointing out that callsigns need to be chosen depending …
2021-02-01 08:06:11 +01:00
Frank
016198e7f2 OPS Cargo 2021-01-31 23:28:04 +01:00
Frank
0933eef4c3 Merge branch 'develop' into FF/Ops 2021-01-31 00:50:14 +01:00
Frank
fe55555c67 OPS
- Fixed inAir check for spawned groups
- Reduced SCHEDULER min delay to 0.001 sec (was 0.1 sec)
2021-01-30 23:28:07 +01:00
Frank
bcf8973eed OPS 2021-01-30 21:29:29 +01:00
rollnthndr
50d2e42cc3 Added VSCode settings folder and workspace file to the ignore list. 2021-01-29 18:31:19 -07:00
rollnthndr
261d1cbeba Added a note pointing out that callsigns need to be chosen depending on the type of unit that this task is being assigned to. 2021-01-29 18:15:20 -07:00
Frank
242462b9ba OPS Cargo 2021-01-29 00:32:38 +01:00
Frank
fd4e478dbf Merge branch 'master' into develop 2021-01-26 12:40:15 +01:00
Frank
6b91e68668 OPS Cargo 2021-01-26 12:39:49 +01:00
Frank
7516d2af56 Merge branch 'master' into develop 2021-01-23 16:47:14 +01:00
Frank
c247a98402 OPS cargo 2021-01-23 16:46:44 +01:00
Frank
83bcd55a7a Merge pull request #1439 from FlightControl-Master/wingthor_fixes
Added a table shuffler using Fisher Yeates algorithm in Utilities/Uti…
2021-01-22 23:28:42 +01:00
Wingthor
5a43936e35 Added a table shuffler using Fisher Yeates algorithm in Utilities/Utils.lua 2021-01-22 23:10:22 +01:00
Frank
35b776179e Merge branch 'master' into develop 2021-01-19 16:56:40 +01:00
Frank
f4cb6df8d4 Ops
respawn
2021-01-19 16:53:22 +01:00
Frank
a259b88f1d Merge branch 'develop' into FF/Ops 2021-01-16 22:57:10 +01:00
Frank
5b4f3d1c98 Merge branch 'master' into develop 2021-01-16 22:56:43 +01:00
Frank
c62c21c386 FLIGHTGROUP v0.6.1
- Improved engage targets
2021-01-16 22:56:28 +01:00
Frank
17c56a11bd Merge pull request #1432 from OttoWerkr/develop
Update Scenery.lua
2021-01-15 23:53:37 +01:00
Frank
796561b8b6 Merge pull request #1433 from FlightControl-Master/FF/Ops
OPS
2021-01-15 23:44:46 +01:00
Frank
209b7a64ed Update OpsGroup.lua 2021-01-15 23:42:30 +01:00
Frank
8f56299380 OPS
**AUFTRAG**
- Added PATROLZONE type. Works for all OPSGROUPs (air, ground and sea).

**FLIGHTGROUP**
- Improved EngageTarget
- Added option to automatically engage detected targets.

**TARGET**
- Improved Zone type
2021-01-15 23:29:16 +01:00
OttoWerkr
73b1394ca7 Update Scenery.lua
Added FindByName() to SCENERY Class.
2021-01-15 14:27:43 -05:00
Frank
f3a2cf7284 Patrol
- Added `FLIGHTGROUP:SetEngageDetectedOn()`
- AUFTRAG patrol zone.
2021-01-15 00:59:52 +01:00
Frank
df79c765f8 Merge branch 'master' into develop 2021-01-12 17:40:40 +01:00
Frank
d09737c218 Merge branch 'master' into develop 2021-01-12 13:51:26 +01:00
Frank
6b0c42ae50 Merge branch 'master' into develop 2021-01-12 10:45:11 +01:00
Frank
7363da1b54 Merge branch 'master' into develop 2021-01-09 23:48:42 +01:00
Frank
684f19c060 Merge branch 'master' into develop 2021-01-05 22:59:57 +01:00
Frank
d08e4db0eb Merge branch 'master' into develop 2021-01-03 00:24:42 +01:00
Frank
f1e7d8bd06 Merge branch 'master' into develop 2021-01-01 10:16:58 +01:00
Frank
1328ac061e Merge branch 'master' into develop 2020-12-31 21:22:59 +01:00
Frank
391f0fc9af Merge branch 'master' into develop 2020-12-29 23:38:44 +01:00
Frank
38cf5be738 Update Airbase.lua 2020-12-29 22:51:10 +01:00
Frank
1bb70b8697 Update Warehouse.lua
- added airbase coalition check when spawning aircraft #1413
2020-12-29 22:28:36 +01:00
Frank
6e35b80daf Update Warehouse.lua
- requests should no longer be processed if warehouse has no airbase
2020-12-29 21:41:15 +01:00
Frank
a171c22ce4 Merge branch 'develop' into FF/Ops 2020-12-29 11:23:04 +01:00
Frank
f56457bc28 Update Intelligence.lua
- added reject zones
2020-12-29 11:22:47 +01:00
Frank
9708de70c7 Merge branch 'master' into develop 2020-12-27 17:59:57 +01:00
Frank
d68589bb70 Merge branch 'master' into develop 2020-12-23 16:10:07 +01:00
Frank
16eb38782a Merge branch 'master' into develop 2020-12-23 10:54:57 +01:00
Frank
2175e9c0d6 Merge branch 'master' into develop 2020-12-22 09:49:08 +01:00
Frank
9abd71f681 Merge branch 'develop' into FF/Ops 2020-12-21 00:13:09 +01:00
Frank
d1dc829136 Merge branch 'master' into develop 2020-12-20 23:48:28 +01:00
Frank
eda672bdc6 Merge branch 'develop' into FF/Ops 2020-12-19 12:48:12 +01:00
Frank
0e5dbbea79 Merge branch 'master' into develop 2020-12-19 01:18:17 +01:00
Frank
f5809ef302 Merge branch 'develop' into FF/Ops 2020-12-18 23:50:59 +01:00
Frank
457ce1ece1 Merge branch 'master' into develop 2020-12-18 13:52:23 +01:00
Frank
9c9841332f Merge branch 'master' into develop 2020-12-17 13:55:38 +01:00
Frank
9470d3a2ef Merge branch 'master' into develop 2020-12-17 12:34:59 +01:00
Frank
8356271f8d Merge branch 'master' into develop 2020-12-17 12:34:04 +01:00
Frank
42a6f3272d Merge branch 'master' into develop 2020-12-16 00:12:38 +01:00
Frank
362b242c41 Merge pull request #1398 from Applevangelist/patch-20
Error in FlightGroup.lua in line 2390 as detected by HRP Zero
2020-12-15 00:36:57 +01:00
Frank
7ace7b49ca Merge branch 'develop' into FF/Ops 2020-12-15 00:14:15 +01:00
Frank
7cd902e924 Merge branch 'master' into develop 2020-12-15 00:11:34 +01:00
Applevangelist
e3c14678e2 Error in FlightGroup.lua in line 2390 as detected by HRP Zero
Not searching in Paris, but in pairs :)
2020-12-14 13:37:17 +01:00
Frank
bfaca75a7d Merge branch 'master' into develop 2020-12-14 12:37:45 +01:00
Frank
5aecd8c255 Ops
- Performance
2020-12-10 18:53:49 +01:00
Frank
cfc0f1a1f7 Merge branch 'master' into develop 2020-12-03 23:18:32 +01:00
Frank
edf657c65c Merge branch 'master' into develop 2020-11-30 11:40:34 +01:00
Frank
801d00fa26 Stuff 2020-11-30 11:38:36 +01:00
Frank
eeffa31282 Update ChiefOfStaff.lua 2020-11-26 11:47:05 +01:00
Frank
206528a530 Merge branch 'FF/Ops' into FF/OpsDev 2020-11-26 10:56:17 +01:00
Frank
41690fdf7b Merge pull request #1385 from FlightControl-Master/FF/Ops
OPS
2020-11-25 11:34:41 +01:00
Frank
5b83f8e45b OPS 2020-11-25 11:27:07 +01:00
Frank
94863ed8ae Update OpsGroup.lua 2020-11-24 22:00:36 +01:00
Frank
e63b99c890 Merge pull request #1379 from Applevangelist/patch-7
Update Controllable.lua
2020-11-22 15:54:03 +01:00
Frank
e8542743b4 Merge pull request #1380 from Applevangelist/patch-8
Update Sead.lua
2020-11-22 15:53:14 +01:00
Applevangelist
309e1208c2 Update Sead.lua
Feature Request #1355
2020-11-22 14:17:42 +01:00
Applevangelist
3e0db05664 Update Controllable.lua
Added control to keep within limits of the options
2020-11-22 13:01:26 +01:00
Applevangelist
9573d92cc0 Update Controllable.lua
Add option to control a2a attack ranges for AIR fighter units. See https://wiki.hoggitworld.com/view/DCS_option_missileAttack
2020-11-22 12:07:49 +01:00
Frank
1abc0dcb6a Merge pull request #1378 from FlightControl-Master/FF/Ops
OPS
2020-11-21 21:55:20 +01:00
Frank
770fb3228f OPS
AUFTRAG
- Changed ESCORT engage distance input to NM (not meters)

TARGET
- Fixed bug in count targets
- Improved dead/destroyed management

FLIGHTGROUP
- Only register UNIT/STATIC kills (not SCENERY)

INTEL
- Improved agent set
2020-11-21 21:49:47 +01:00
Frank
d6aa251c5e Merge pull request #1377 from Applevangelist/patch-6
Update AI_A2G_Dispatcher.lua
2020-11-20 18:17:25 +01:00
Frank
9305b870d2 Merge pull request #1376 from Applevangelist/patch-5
Update AI_A2A_Dispatcher.lua
2020-11-20 18:17:00 +01:00
Applevangelist
824a98d7a8 Update AI_A2G_Dispatcher.lua
Wrapper for player messages and function to set this on/off
2020-11-20 10:43:39 +01:00
Applevangelist
7a55ba105c Update AI_A2A_Dispatcher.lua
Wrap player messages, added function to switch on/off
2020-11-20 10:34:53 +01:00
Frank
122425338e Merge branch 'master' into develop 2020-11-20 10:18:05 +01:00
Frank
1d7f874a78 Merge pull request #1375 from FlightControl-Master/FF/Ops
OPS
2020-11-19 21:49:02 +01:00
Frank
afb63a7331 Update Target.lua
- Fixed escort problem
2020-11-19 19:51:58 +01:00
Frank
0c07a660ee WAREHOUSE
- Added runway destroyed check.
2020-11-17 00:25:37 +01:00
Frank
8ffda53e3d Chief and Wing Commander
- Added back in
2020-11-16 18:11:15 +01:00
Frank
5a30c08ff6 Merge pull request #1369 from FlightControl-Master/FF/Ops
TARGET
2020-11-16 13:33:14 +01:00
Frank
9cac2674c4 Update Target.lua
- Alive checks improved
2020-11-16 13:22:53 +01:00
Frank
ec3f43c69f Merge pull request #1367 from FlightControl-Master/FF/Ops
OPS
2020-11-16 00:02:20 +01:00
Frank
270dfab6a2 OPS
less output again
2020-11-15 23:49:25 +01:00
Frank
624b1f5647 Merge branch 'develop' into FF/Ops 2020-11-15 23:34:34 +01:00
Frank
84332a3ebf Update FlightGroup.lua
Fixes bug when flight searches a tanker when fuel is low.
2020-11-15 23:33:43 +01:00
Frank
63ff79ef0b Merge branch 'master' into FF/Ops 2020-11-15 23:00:50 +01:00
Frank
09452444d7 Merge branch 'master' into develop 2020-11-15 23:00:23 +01:00
Frank
75be2fc0ba Update Target.lua 2020-11-15 21:44:08 +01:00
Frank
1e0a0f8dc5 Ops 2020-11-13 23:26:56 +01:00
Frank
f3d9b9c5be Ops 2020-11-06 00:29:42 +01:00
Frank
cef0e444c9 Ops 2020-11-04 22:48:14 +01:00
Frank
bad8dc2220 Merge pull request #1362 from FlightControl-Master/FF/Ops
Ops Enhancements
2020-10-31 22:05:58 +01:00
Frank
e05d57d908 Merge branch 'develop' into FF/Ops 2020-10-31 21:22:17 +01:00
Frank
45c153f7a0 Merge branch 'master' into develop 2020-10-31 21:21:47 +01:00
Frank
0948f418cd Ops
- Fixed payload not reduced
2020-10-31 11:57:23 +01:00
Frank
d027113b0b Merge branch 'develop' into FF/Ops 2020-10-28 09:48:36 +01:00
Frank
ff00c2fb15 Merge branch 'master' into develop 2020-10-28 09:46:34 +01:00
Frank
cd5b4ee1be Update AI_Formation.lua
- fixed bug
- set default mode to following
2020-10-28 09:44:33 +01:00
Frank
ac337b8459 Ops
- Laser
2020-10-28 09:06:22 +01:00
Frank
567f7cbc29 Update OpsGroup.lua
- Laser
2020-10-27 00:12:59 +01:00
Frank
d81ffcf119 Merge branch 'develop' into FF/Ops 2020-10-26 16:16:56 +01:00
Frank
6ed66a70a2 Merge branch 'master' into develop 2020-10-26 16:16:28 +01:00
Frank
9ed3b045f7 Merge branch 'master' into develop 2020-10-26 09:17:41 +01:00
Frank
2d6653c14a Ops
- Laser
2020-10-26 08:01:56 +01:00
Frank
ab0e7e735a Merge branch 'develop' into FF/Ops 2020-10-20 23:40:52 +02:00
Frank
3243555d3f Merge branch 'master' into develop 2020-10-20 23:31:30 +02:00
Frank
8696ce0cc1 Ops 2020-10-20 23:04:15 +02:00
Frank
459ff26868 Ops 2020-10-19 23:33:39 +02:00
Frank
277eb2d09f Ops
- Laser
2020-10-18 00:02:48 +02:00
Frank
187093fa5a NavyGroup Update 2020-10-14 00:24:12 +02:00
Frank
6c9ce55759 Navygroup
- Fixed Astar bug
- Turn into wind stop
2020-10-13 00:29:31 +02:00
Frank
f9721e501a Merge branch 'FF/Ops' into develop 2020-10-12 00:22:47 +02:00
Frank
23c22651be Update Airboss.lua
- Added USS Harry S. Truman (CVN-75) as SC type.
2020-10-12 00:21:47 +02:00
Frank
2ad81ca499 Ops 2020-10-12 00:09:02 +02:00
Frank
7792381c36 OPS 2020-10-09 17:10:24 +02:00
Frank
591dd128ce Navygroup 2020-10-09 00:15:19 +02:00
Frank
ce10390406 ARMYGROUP 2020-10-07 23:26:46 +02:00
Frank
bf299e5f8d Merge pull request #1353 from FlightControl-Master/FF/Ops
OPS fixes
2020-10-03 23:29:35 +02:00
Frank
7f98e703f1 Update Airbase.lua
- Fixed bug in the `AIRBASE:GetRunwaydata()` function.
2020-10-03 23:12:17 +02:00
Frank
421d27f640 Update Airboss.lua
- Fix if unit skill is not set in env.mission (DCS bug that should be fixed by ED meanwhile).
2020-10-03 21:43:09 +02:00
Frank
fb1e95ab87 Pathfinding 2020-10-03 18:22:23 +02:00
Frank
3737592734 Ops
Fixes
2020-10-01 23:55:39 +02:00
Frank
6445cf01a2 Merge pull request #1350 from FlightControl-Master/FF/Ops
OPS Update
2020-09-20 00:26:10 +02:00
Frank
8e07b93eac Merge branch 'develop' into FF/Ops 2020-09-19 23:57:25 +02:00
Frank
23f6752362 Ops
- rm staff
2020-09-19 23:55:45 +02:00
Frank
19b870c038 Ops
- Less traceing.
2020-09-19 23:52:17 +02:00
Frank
ca7f15e622 Ops 2020-09-19 01:15:34 +02:00
Frank
d497bb25f3 Ops 2020-09-18 18:07:10 +02:00
Frank
29d694722b Ops
- Quite a few fixes while going through the example missions.
2020-09-16 23:35:13 +02:00
Frank
40ffef035b Ops 2020-09-15 18:11:19 +02:00
Frank
a00c198bcc Update Warehouse.lua
- Added born check. Helps with delayed spawning on carriers.
2020-09-15 01:13:11 +02:00
Frank
717842b276 Ops 2020-09-10 00:34:17 +02:00
Frank
d5c4c34759 Ops 2020-09-09 00:02:46 +02:00
Frank
edb0032118 ops 2020-09-08 18:04:03 +02:00
Frank
123144d06e Ops temp 2020-09-08 00:15:29 +02:00
Frank
38f5d45d5b Merge branch 'master' into FF/Ops 2020-09-07 22:25:28 +02:00
Frank
bcaf808b88 Ops little fixes 2020-09-07 22:17:33 +02:00
Frank
7b8db597ef Ops 2020-09-07 00:42:29 +02:00
Frank
18e192b235 Ops 2020-09-06 00:18:20 +02:00
Frank
5ad30277ba Ops 2020-09-05 00:56:44 +02:00
Frank
2e998dc315 Ops 2020-09-04 17:20:40 +02:00
Frank
cda1658541 Ops 2020-09-04 00:58:37 +02:00
Frank
8b640912c3 Ops 2020-09-02 22:54:54 +02:00
Frank
81a773b861 Merge branch 'master' into develop 2020-09-02 00:09:15 +02:00
Frank
444cc43971 Ops 2020-09-02 00:05:05 +02:00
Frank
eb86d59203 Ops 2020-09-01 11:42:45 +02:00
Frank
5ee35f3fbb Less output 2020-08-31 12:50:50 +02:00
Frank
9a91145f89 Small 2020-08-30 23:44:15 +02:00
Frank
637081ebdd Ops 2020-08-30 22:52:18 +02:00
Frank
7d2746e7be Merge branch 'develop' into FF/Ops 2020-08-30 17:24:57 +02:00
Frank
c84a92c787 Merge branch 'master' into develop 2020-08-30 17:15:31 +02:00
Frank
b775aaa274 Merge branch 'master' into FF/Ops 2020-08-30 17:05:09 +02:00
Frank
a97d7abc24 Range Ops 2020-08-30 17:03:16 +02:00
Frank
7e73db505b Decreased Tracing 2020-08-30 01:38:18 +02:00
Frank
a126906776 up 2020-08-29 21:24:15 +02:00
Frank
2d6092c114 TIMER
- Added new TIMER class.
2020-08-29 20:26:20 +02:00
Frank
caef309547 Ops
- Airboss optimizations WIP
2020-08-28 13:24:29 +02:00
Frank
f9ec21a2b5 Ops 2020-08-26 00:01:52 +02:00
Frank
06600b2a94 Ops 2020-08-25 17:55:53 +02:00
Frank
3f39ec0ae0 Stuff 2020-08-25 01:03:18 +02:00
Frank
cfc45cf068 Warehouse marker and spawning update 2020-08-23 01:08:02 +02:00
Frank
45d809a641 Update Profiler.lua 2020-08-22 22:39:54 +02:00
Frank
fcfbc5e17c Profiler
- Added lua Profiler.
2020-08-22 21:24:35 +02:00
Frank
f30c66424c Radioqueue Profiler 2020-08-22 21:18:12 +02:00
Frank
f823fc6ee0 Update AI_Formation.lua
Performance update
2020-08-22 16:31:56 +02:00
Frank
aac291c0c6 Performance Optimizations 2020-08-22 00:09:36 +02:00
Frank
61adeeeda3 Delete Astar - Copy.lua 2020-08-20 01:24:28 +02:00
Frank
f94a5eed61 Merge branch 'develop' into FF/OpsDev 2020-08-19 23:21:06 +02:00
Frank
0695c48e7a Merge branch 'master' into develop 2020-08-19 23:12:05 +02:00
Frank
f4bfcf58fd Ops 2020-08-19 22:32:16 +02:00
Frank
dee7307adc Ops 2020-08-19 01:06:28 +02:00
Frank
114032a743 Ops 2020-08-18 18:15:22 +02:00
Frank
e9e6a63e6a Ops 2020-08-18 01:35:24 +02:00
Frank
2a4f6020c2 Ops 2020-08-17 01:24:51 +02:00
Frank
3ea8b3737f Update Profiler.lua 2020-08-16 01:18:18 +02:00
Frank
ed47b4b3db Ops 2020-08-16 00:35:42 +02:00
Frank
adc89feda9 Ops 2020-08-15 00:54:36 +02:00
Frank
32c9a59ff0 Ops 2020-08-14 18:09:13 +02:00
Frank
200c1dac85 Ops 2020-08-14 01:01:45 +02:00
Frank
cf65c2af15 Ops 2020-08-13 01:21:02 +02:00
Frank
fb6ebc42a5 Ops 2020-08-10 23:45:52 +02:00
Frank
c7696c375e Ops 2020-08-10 01:46:03 +02:00
Frank
337e1a837f Ops 2020-08-08 01:10:03 +02:00
Frank
495a9fd3a0 Ops Target
New Class.
2020-08-06 01:43:42 +02:00
Frank
e6f7493ddd Ops Fixes 2020-08-05 00:39:48 +02:00
Frank
76e75505e5 Ops 2020-08-04 16:56:45 +02:00
Frank
dafbd3f368 Ops & Auftrag 2020-08-04 01:10:53 +02:00
Frank
11ec70441a Ops group 2020-08-03 00:31:10 +02:00
Frank
d1a18913f3 Ops 2020-08-02 01:31:47 +02:00
Frank
775b9e9fde Fixed bugs with new option table. 2020-08-01 00:25:12 +02:00
Frank
286e34e057 Profiler 2020-07-31 17:32:24 +02:00
Frank
da2aa00442 A*
Further improvements by switching to keys.
2020-07-31 00:09:21 +02:00
Frank
ba90176bb1 A*
Further optimized by using DCS API land.isVisible instead of Moose IsLoS function.
2020-07-30 21:40:27 +02:00
Frank
cf9248ecc8 A*
- Improved performance by caching cost and valid/invalid neighbours.
2020-07-30 17:41:26 +02:00
Frank
0d42b12658 Enhanced Groups 2020-07-30 01:08:25 +02:00
Frank
2f6d9b640f NAVY 2020-07-29 01:10:13 +02:00
Frank
04923b65b2 Stuff 2020-07-24 01:34:38 +02:00
Frank
2328f9a36b CHIEF 2020-07-23 19:15:26 +02:00
Frank
98971736f8 Astar 2020-07-23 00:24:59 +02:00
Frank
ec809085b4 Waypoints 2020-07-22 01:05:24 +02:00
Frank
af023c1994 Waypoints 2020-07-21 17:53:59 +02:00
Frank
d9b7cc18f3 A* 2020-07-21 01:19:03 +02:00
Frank
ce1121a4c2 INTEL
Clusters
2020-07-20 01:20:28 +02:00
Frank
5fa75bf6b9 INTEL
Improved clusters
2020-07-19 18:31:09 +02:00
Frank
5cb1036618 CHIEF
- Added Chief of Staff class.
2020-07-19 01:22:49 +02:00
Frank
9473dc2069 Update Intelligence.lua 2020-07-16 01:04:43 +02:00
Frank
81f5184b43 Added WINCOM;MANDER 2020-07-15 21:48:11 +02:00
Frank
b6bc22f991 Squadron Grouping 2020-07-15 00:51:27 +02:00
Frank
56fad29df9 ops 2020-07-14 17:56:18 +02:00
Frank
dfeea53cf6 Merge branch 'develop' into FF/Ops 2020-07-14 00:33:29 +02:00
Frank
71e6369960 INTEL class 2020-07-13 22:31:33 +02:00
Frank
0611db78b3 Intel 2020-07-13 18:31:01 +02:00
Frank
8c768cc517 Update Intelligence.lua 2020-07-12 22:20:20 +02:00
Frank
b67750d808 Intel 2020-07-12 20:57:37 +02:00
Frank
96f2ad06e2 Update FlightGroup.lua
Fixed TACAN
2020-07-12 19:43:27 +02:00
Frank
5cf4833455 OpsGroup 2020-07-10 14:16:41 +02:00
Frank
f578fcfdc7 NAVYGROUP
Improved dead/stop
2020-07-10 11:14:18 +02:00
Frank
9838e1af19 Ops 2020-07-09 00:06:02 +02:00
Frank
cee443e28d Ops 2020-07-08 00:18:42 +02:00
Frank
1fe57cab67 bla 2020-07-08 00:12:57 +02:00
Frank
80b22a8444 Ops 2020-07-08 00:07:30 +02:00
Frank
71733babf8 NavyGroup 2020-07-07 22:28:54 +02:00
Frank
9f793d6cf7 OpsGroup 2020-07-07 00:47:42 +02:00
Frank
46e73a108f Ops 2020-07-04 23:16:57 +02:00
Frank
b13ddc958b Update Warehouse.lua 2020-07-02 10:48:08 +02:00
Frank
ba3954ad3f Update Airboss.lua 2020-07-01 23:56:05 +02:00
Frank
f2e417b21f Ops 2020-07-01 23:52:27 +02:00
Frank
d93d0afdf3 Ops 2020-06-30 00:33:26 +02:00
Frank
207c9ed62e blanks 2020-06-29 21:08:57 +02:00
Frank
e3f4aa3d64 Update FlightGroup.lua 2020-06-29 21:05:26 +02:00
Frank
2392c9dc8e Ops 2020-06-29 20:55:32 +02:00
Frank
682c1f5ef2 Ops 2020-06-27 22:44:50 +02:00
384 changed files with 104032 additions and 8298 deletions

View File

@@ -1,87 +0,0 @@
version: 2.4.a.{build}
shallow_clone: true
skip_branch_with_pr: false
skip_commits:
message: /!nobuild/
skip_tags: false
environment:
access_token_documentation:
secure: JVBVVL8uJUcLXN+48eRdELEeCGOGCCaMzCqutsUqNuaZ/KblG5ZTt7+LV4UKv/0f
LUAROCKS_VER: 2.4.1
LUA_VER: 5.1.5
LUA: lua5.3
matrix:
- LUA_VER: 5.1.5
platform:
- x64
init:
- ps: if ($env:APPVEYOR_PULL_REQUEST_NUMBER -and $env:APPVEYOR_BUILD_NUMBER -ne ((Invoke-RestMethod `
https://ci.appveyor.com/api/projects/$env:APPVEYOR_ACCOUNT_NAME/$env:APPVEYOR_PROJECT_SLUG/history?recordsNumber=50).builds | `
Where-Object pullRequestId -eq $env:APPVEYOR_PULL_REQUEST_NUMBER)[0].buildNumber) { `
throw "There are newer queued builds for this pull request, failing early." }
# - ps: iex ((new-object net.webclient).DownloadString('https://raw.githubusercontent.com/appveyor/ci/master/scripts/enable-rdp.ps1'))
install:
- cmd:
# Outcomment if lua environment invalidates and needs to be reinstalled, otherwise all will run from the cache.
call choco install 7zip.commandline
call choco install lua51
call choco install luarocks
call refreshenv
call "C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\vcvarsall.bat"
cmd: PATH = %PATH%;C:\ProgramData\chocolatey\lib\luarocks\luarocks-2.4.3-win32\systree\bin
cmd: set LUA_PATH = %LUA_PATH%;C:\ProgramData\chocolatey\lib\luarocks\luarocks-2.4.3-win32\systree\share\lua\5.1\?.lua;C:\ProgramData\chocolatey\lib\luarocks\luarocks-2.4.3-win32\systree\share\lua\5.1\?\init.lua
cmd: set LUA_CPATH = %LUA_CPATH%;C:\ProgramData\chocolatey\lib\luarocks\luarocks-2.4.3-win32\systree\lib\lua\5.1\?.dll
call luarocks install luasrcdiet
call luarocks install checks
call luarocks install luadocumentor
call luarocks install luacheck
cache:
C:\ProgramData\chocolatey\lib
C:\ProgramData\chocolatey\bin
build_script:
- ps: |
if( $env:appveyor_repo_branch -eq 'master' -or $env:appveyor_repo_branch -eq 'develop' )
{
echo "Hello World!"
$apiUrl = 'https://ci.appveyor.com/api'
$token = 'v2.6hcv3ige78kg3yvg4ge8'
$headers = @{
"Authorization" = "Bearer $token"
"Content-type" = "application/json"
}
$RequestBody = @{ accountName = 'FlightControl-Master'; projectSlug = 'moose-include'; branch = "$env:appveyor_repo_branch"; environmentVariables = @{} } | ConvertTo-Json
# Generate the new version ...
$project = Invoke-RestMethod -method Post -Uri "$apiUrl/builds" -Headers $headers -Body $RequestBody
}
- ps: |
if( $env:appveyor_repo_branch -eq 'master' -or $env:appveyor_repo_branch -eq 'develop' )
{
$apiUrl = 'https://ci.appveyor.com/api'
$token = 'v2.6hcv3ige78kg3yvg4ge8'
$headers = @{
"Authorization" = "Bearer $token"
"Content-type" = "application/json"
}
$RequestBody = @{ accountName = 'FlightControl-Master'; projectSlug = 'moose-docs'; branch = "$env:appveyor_repo_branch"; environmentVariables = @{} } | ConvertTo-Json
# get project with last build details
$project = Invoke-RestMethod -method Post -Uri "$apiUrl/builds" -Headers $headers -Body $RequestBody
}
test: off
# test_script:
# - cmd: luacheck "Moose Development\Moose\moose.lua" "Moose Mission Setup\moose.lua"
on_finish:
# - ps: $blockRdp = $true; iex ((new-object net.webclient).DownloadString('https://raw.githubusercontent.com/appveyor/ci/master/scripts/enable-rdp.ps1'))

4
.gitattributes vendored
View File

@@ -15,3 +15,7 @@
*.PDF diff=astextplain
*.rtf diff=astextplain
*.RTF diff=astextplain
# Avoid Windows line endings on shell scripts
# Needed for dockerfile builds
*.sh text eol=lf

169
.github/workflows/build-docs.yml vendored Normal file
View File

@@ -0,0 +1,169 @@
name: Moose-Docs
on:
push:
branches:
- master
- develop
paths:
- 'Moose Setup/**/*.lua'
- 'Moose Development/**/*.lua'
- 'Moose Development/**/*.py'
- 'Moose Development/**/*.html'
- '.github/workflows/build-docs.yml'
# Allows you to run this workflow manually from the Actions tab
workflow_dispatch:
jobs:
Build:
runs-on: ubuntu-latest
steps:
- name: Extract branch name
shell: bash
run: echo "branch=${GITHUB_HEAD_REF:-${GITHUB_REF#refs/heads/}}" >> $GITHUB_OUTPUT
id: extract_branch
- name: Build informations
run: |
echo "Triggered by: ${{ github.event_name }}"
echo "Running on: ${{ runner.os }}"
echo "Ref: ${{ github.ref }}"
echo "Branch name: ${{ steps.extract_branch.outputs.branch }}"
echo "Repository: ${{ github.repository }}"
echo "Commit-Id: ${{ github.sha }}"
echo "Owner: ${{ github.repository_owner }}"
echo "FORCE_PUSH: ${{ vars.FORCE_PUSH }}"
#########################################################################
# Prepare build environment
#########################################################################
- name: Check out repository code
uses: actions/checkout@v4
- name: Prepare build output folders
run: |
mkdir -p build/tools
mkdir -p build/doc
- name: Checkout FlightControls modified luadocumentor
uses: actions/checkout@v4
with:
repository: Applevangelist/luadocumentor
path: './build/tools/luadocumentor'
ref: 'patch-1'
token: ${{ secrets.BOT_TOKEN }}
- name: Update apt-get (needed for act docker image)
run: |
sudo rm /etc/apt/sources.list.d/microsoft-prod.list
sudo apt-get -qq update
- name: Install tree
run: |
sudo apt-get -qq install tree
#########################################################################
# Install all prerequisites for LuaDocumentor
#########################################################################
- name: Install Lua
run: |
sudo apt-get -qq install lua5.1
- name: Install LuaRocks
run: |
sudo apt-get -qq install luarocks -y
- name: Install markdown (prereq for LuaDocumentor)
run: |
sudo luarocks install markdown 0.32-2
- name: Install penlight (prereq for LuaDocumentor)
run: |
sudo luarocks install penlight 1.11.0-1
- name: Install metalua-compiler (prereq for LuaDocumentor)
run: |
sudo luarocks install metalua-compiler 0.7.3-1
- name: Install metalua-parser (prereq for LuaDocumentor)
run: |
sudo luarocks install metalua-parser 0.7.3-2
- name: Install checks (prereq for LuaDocumentor)
run: |
sudo luarocks install checks
#########################################################################
# Run LuaDocumentor
#########################################################################
- name: Run LuaDocumentor
run: |
lua luadocumentor.lua -d ${{ github.workspace }}/build/doc "${{ github.workspace }}/Moose Development/Moose"
working-directory: ${{ github.workspace }}/build/tools/luadocumentor
#########################################################################
# Replace <head> tag
#########################################################################
- name: Replace head tag
run: |
python3 "${{ github.workspace }}/Moose Development/docs-header.py"
working-directory: ${{ github.workspace }}/build/doc
- name: Check replacement of head tag
run: |
head -10 ${{ github.workspace }}/build/doc/AI.AI_A2A_Cap.html
#########################################################################
# Push to MOOSE_DOCS
#########################################################################
- name: Set docs repo for branch
shell: bash
id: set_doc_repo
run: |
if [[ $GITHUB_REF == 'refs/heads/master' ]]; then
echo "docrepo=MOOSE_DOCS" >> "$GITHUB_OUTPUT"
else
echo "docrepo=MOOSE_DOCS_DEVELOP" >> "$GITHUB_OUTPUT"
fi
- name: Checkout ${{ steps.set_doc_repo.outputs.docrepo }} to folder MOOSE_DOCS
uses: actions/checkout@v4
with:
repository: ${{ github.repository_owner }}/${{ steps.set_doc_repo.outputs.docrepo }}
path: './build/MOOSE_DOCS'
fetch-depth: 0
ref: 'master'
token: ${{ secrets.BOT_TOKEN }}
- name: Delete folder to remove deleted files
run: |
rm -rf ./build/MOOSE_DOCS/Documentation/
- name: Create target folder
run: mkdir -p build/MOOSE_DOCS/Documentation
- name: Copy build result to MOOSE_DOCS
run: |
cp ./build/doc/*.* ./build/MOOSE_DOCS/Documentation/
- name: Push result to docs repository
if: ${{ vars.FORCE_PUSH == 'true' }}
run: |
git config user.name "MooseBotter"
git config user.email "MooseBotter@users.noreply.github.com"
git add .
git commit --allow-empty -m "Auto commit by GitHub Actions Workflow"
git push --set-upstream origin master
working-directory: ${{ github.workspace }}/build/MOOSE_DOCS
#########################################################################
# Show the results
#########################################################################
- name: List files in the repository
run: |
tree ${{ github.workspace }}/build
- run: echo "This job's status is ${{ job.status }}."

149
.github/workflows/build-includes.yml vendored Normal file
View File

@@ -0,0 +1,149 @@
name: Moose-Includes
on:
push:
branches:
- master
- develop
paths:
- 'Moose Setup/**/*.lua'
- 'Moose Development/**/*.lua'
- '.github/workflows/build-includes.yml'
# Allows you to run this workflow manually from the Actions tab
workflow_dispatch:
jobs:
Build:
runs-on: ubuntu-latest
steps:
- name: Extract branch name
shell: bash
run: echo "branch=${GITHUB_HEAD_REF:-${GITHUB_REF#refs/heads/}}" >> $GITHUB_OUTPUT
id: extract_branch
- name: Build informations
run: |
echo "Triggered by: ${{ github.event_name }}"
echo "Running on: ${{ runner.os }}"
echo "Ref: ${{ github.ref }}"
echo "Branch name: ${{ steps.extract_branch.outputs.branch }}"
echo "Repository: ${{ github.repository }}"
echo "Commit-Id: ${{ github.sha }}"
echo "Owner: ${{ github.repository_owner }}"
echo "FORCE_PUSH: ${{ vars.FORCE_PUSH }}"
#########################################################################
# Prepare build environment
#########################################################################
- name: Check out repository code
uses: actions/checkout@v4
- name: Prepare build output folders
run: |
mkdir -p build/result/Moose_Include_Dynamic
mkdir -p build/result/Moose_Include_Static
- name: Update apt-get (needed for act docker image)
run: |
sudo rm /etc/apt/sources.list.d/microsoft-prod.list
sudo apt-get -qq update
- name: Install tree
run: |
sudo apt-get -qq install tree
#########################################################################
# Install all prerequisites
#########################################################################
- name: Install Lua 5.3
run: |
sudo apt-get -qq install lua5.3 -y
- name: Check Lua version
run: |
lua -v
- name: Install LuaRocks
run: |
sudo apt-get -qq install luarocks -y
- name: Check LuaRocks version
run: |
luarocks --version
- name: Install Lua 5.3 Dev for prerequisites for LuaSrcDiet
run: |
sudo apt-get -qq install liblua5.3-dev -y
- name: Install LuaSrcDiet
run: |
sudo luarocks install luasrcdiet
- name: Install LuaCheck
run: |
sudo luarocks install luacheck
#########################################################################
# Build Include files
#########################################################################
- name: Build Include Static
run: |
export COMMIT_TIME=$(git show -s --format=%cd ${{ github.sha }} --date=iso-strict)
lua5.3 "./Moose Setup/Moose_Create.lua" S "$COMMIT_TIME-${{ github.sha }}" "./Moose Development/Moose" "./Moose Setup" "./build/result/Moose_Include_Static"
- name: Build Includes Dynamic
run: |
export COMMIT_TIME=$(git show -s --format=%cd ${{ github.sha }} --date=iso-strict)
lua5.3 "./Moose Setup/Moose_Create.lua" D "$COMMIT_TIME-${{ github.sha }}" "./Moose Development/Moose" "./Moose Setup" "./build/result/Moose_Include_Dynamic"
#########################################################################
# Run LuaCheck
#########################################################################
- name: Run LuaCheck
if: ${{ vars.SKIP_LUACHECK != true }}
continue-on-error: true
run: |
luacheck --std=lua51c --config=.luacheckrc -gurasqq "Moose Development/Moose"
- name: Run LuaSrcDiet
run: |
luasrcdiet --basic --opt-emptylines ./build/result/Moose_Include_Static/Moose.lua -o ./build/result/Moose_Include_Static/Moose_.lua
#########################################################################
# Push to MOOSE_INCLUDE
#########################################################################
- name: Checkout MOOSE_INCLUDE
uses: actions/checkout@v4
with:
repository: ${{ github.repository_owner }}/MOOSE_INCLUDE
path: './build/MOOSE_INCLUDE'
fetch-depth: 0
ref: ${{ steps.extract_branch.outputs.branch }}
token: ${{ secrets.BOT_TOKEN }}
- name: Create target folder (needed if checkout is deactivated)
run: mkdir -p build/MOOSE_INCLUDE
- name: Copy build reseult to MOOSE_INCLUDE
run: |
cp -r ./build/result/* ./build/MOOSE_INCLUDE/
- name: Push result to MOOSE_INCLUDE repository
if: ${{ vars.FORCE_PUSH == 'true' }}
run: |
git config user.name "MooseBotter"
git config user.email "MooseBotter@users.noreply.github.com"
git add .
git commit --allow-empty -m "Auto commit by GitHub Actions Workflow"
git push --set-upstream origin ${{ steps.extract_branch.outputs.branch }}
working-directory: ${{ github.workspace }}/build/MOOSE_INCLUDE
#########################################################################
# Show the results
#########################################################################
- name: List files in the repository
run: |
tree ${{ github.workspace }}/build
- run: echo "This job's status is ${{ job.status }}."

78
.github/workflows/gh-pages.yml vendored Normal file
View File

@@ -0,0 +1,78 @@
# This workflow uses actions that are not certified by GitHub.
# They are provided by a third-party and are governed by
# separate terms of service, privacy policy, and support
# documentation.
# Sample workflow for building and deploying a Jekyll site to GitHub Pages
name: Deploy Jekyll site to Pages
on:
push:
branches: ["master"]
paths:
- 'docs/**'
- '.github/workflows/gh-pages.yml'
# Allows you to run this workflow manually from the Actions tab
workflow_dispatch:
# Sets permissions of the GITHUB_TOKEN to allow deployment to GitHub Pages
permissions:
contents: read
pages: write
id-token: write
# Allow one concurrent deployment
concurrency:
group: "pages"
cancel-in-progress: true
jobs:
# Build job
build:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Setup Ruby
uses: ruby/setup-ruby@v1
with:
ruby-version: '3.1' # Not needed with a .ruby-version file
bundler-cache: true # runs 'bundle install' and caches installed gems automatically
cache-version: 0 # Increment this number if you need to re-download cached gems
working-directory: docs/
- name: Setup Pages
id: pages
uses: actions/configure-pages@v4
- name: Build with Jekyll
# Outputs to the './_site' directory by default
run: bundle exec jekyll build --baseurl "${{ steps.pages.outputs.base_path }}"
env:
JEKYLL_ENV: production
working-directory: docs/
- name: Upload artifact
# Automatically uploads an artifact from the './_site' directory by default
uses: actions/upload-pages-artifact@v3
with:
path: docs/_site/
# Deployment job
deploy:
environment:
name: github-pages
url: ${{ steps.deployment.outputs.page_url }}
runs-on: ubuntu-latest
needs: build
steps:
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@v4
check:
runs-on: ubuntu-latest
needs: deploy
steps:
- name: Setup Node
uses: actions/setup-node@v4
- run: npm install linkinator
- run: npx linkinator https://flightcontrol-master.github.io/MOOSE/ --verbosity error --timeout 5000 --recurse --skip "(java.com)" --retry-errors --retry-errors-count 3 --retry-errors-jitter

23
.gitignore vendored
View File

@@ -28,6 +28,13 @@ local.properties
.buildpath
#####################
## Visual Studio Code
#####################
*.code-workspace
.vscode/
#################
## Visual Studio
#################
@@ -35,6 +42,8 @@ local.properties
## Ignore Visual Studio temporary files, build results, and
## files generated by popular Visual Studio add-ons.
.vscode
# User-specific files
*.suo
*.user
@@ -219,12 +228,16 @@ pip-log.txt
#Goodsync
_gsdata_/
# PyCharm
.idea
#GITHUB
.gitattributes
.gitignore
Moose Test Missions/MOOSE_Test_Template.miz
Moose Development/Moose/.vscode/launch.json
MooseCodeWS.code-workspace
.gitignore
.gitignore
/.gitignore
# Excludes for act (https://github.com/nektos/act)
.secrets
.env
.actrc
.vars

View File

@@ -92,6 +92,11 @@
-- that will define when the AI will engage with the detected airborne enemy targets.
-- Use the method @{#AI_A2A_CAP.SetEngageZone}() to define that Zone.
--
-- # Developer Note
--
-- Note while this class still works, it is no longer supported as the original author stopped active development of MOOSE
-- Therefore, this class is considered to be deprecated
--
-- ===
--
-- @field #AI_A2A_CAP
@@ -118,7 +123,7 @@ function AI_A2A_CAP:New2( AICap, EngageMinSpeed, EngageMaxSpeed, EngageFloorAlti
-- Multiple inheritance ... :-)
local AI_Air = AI_AIR:New( AICap )
local AI_Air_Patrol = AI_AIR_PATROL:New( AI_Air, AICap, PatrolZone, PatrolFloorAltitude, PatrolCeilingAltitude, PatrolMinSpeed, PatrolMaxSpeed, PatrolAltType ) -- #AI_AIR_PATROL
local AI_Air_Patrol = AI_AIR_PATROL:New( AI_Air, AICap, PatrolZone, PatrolFloorAltitude, PatrolCeilingAltitude, PatrolMinSpeed, PatrolMaxSpeed, PatrolAltType )
local AI_Air_Engage = AI_AIR_ENGAGE:New( AI_Air_Patrol, AICap, EngageMinSpeed, EngageMaxSpeed, EngageFloorAltitude, EngageCeilingAltitude, EngageAltType )
local self = BASE:Inherit( self, AI_Air_Engage ) --#AI_A2A_CAP

View File

@@ -23,7 +23,7 @@
--
-- ## Missions:
--
-- [AID-A2A - AI A2A Dispatching](https://github.com/FlightControl-Master/MOOSE_MISSIONS/tree/master/AID%20-%20AI%20Dispatching/AID-A2A%20-%20AI%20A2A%20Dispatching)
-- [AID-A2A - AI A2A Dispatching](https://github.com/FlightControl-Master/MOOSE_MISSIONS/tree/master/AI/AI_A2A_Dispatcher)
--
-- ===
--
@@ -177,6 +177,11 @@
--
-- **The default grouping is 1. That means, that each spawned defender will act individually.**
--
-- # Developer Note
--
-- Note while this class still works, it is no longer supported as the original author stopped active development of MOOSE
-- Therefore, this class is considered to be deprecated
--
-- ===
--
-- ### Authors: **FlightControl** rework of GCICAP + introduction of new concepts (squadrons).
@@ -305,7 +310,7 @@ do -- AI_A2A_DISPATCHER
-- Use the method @{#AI_A2A_DISPATCHER.SetEngageRadius}() to set a specific Engage Radius.
-- **The Engage Radius is defined for ALL squadrons which are operational.**
--
-- Demonstration Mission: [AID-019 - AI_A2A - Engage Range Test](https://github.com/FlightControl-Master/MOOSE_MISSIONS/tree/release-2-2-pre/AID%20-%20AI%20Dispatching/AID-019%20-%20AI_A2A%20-%20Engage%20Range%20Test)
-- Demonstration Mission: [AID-019 - AI_A2A - Engage Range Test](https://github.com/FlightControl-Master/MOOSE_MISSIONS/tree/master/AI/AI_A2A_Dispatcher/AID-A2A-019%20-%20Engage%20Range%20Test)
--
-- In this example an Engage Radius is set to various values.
--
@@ -328,7 +333,7 @@ do -- AI_A2A_DISPATCHER
-- Use the method @{#AI_A2A_DISPATCHER.SetGciRadius}() to set a specific controlled ground intercept radius.
-- **The Ground Controlled Intercept radius is defined for ALL squadrons which are operational.**
--
-- Demonstration Mission: [AID-013 - AI_A2A - Intercept Test](https://github.com/FlightControl-Master/MOOSE_MISSIONS/tree/release-2-2-pre/AID%20-%20AI%20Dispatching/AID-013%20-%20AI_A2A%20-%20Intercept%20Test)
-- Demonstration Mission: [AID-013 - AI_A2A - Intercept Test](https://github.com/FlightControl-Master/MOOSE_MISSIONS/tree/master/AI/AI_A2A_Dispatcher/AID-A2A-013%20-%20Intercept%20Test)
--
-- In these examples, the Gci Radius is set to various values:
--
@@ -361,7 +366,7 @@ do -- AI_A2A_DISPATCHER
-- 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.
--
-- Demonstration Mission: [AID-009 - AI_A2A - Border Test](https://github.com/FlightControl-Master/MOOSE_MISSIONS/tree/release-2-2-pre/AID%20-%20AI%20Dispatching/AID-009 - AI_A2A - Border Test)
-- Demonstration Mission: [AID-009 - AI_A2A - Border Test](https://github.com/FlightControl-Master/MOOSE_MISSIONS/tree/master/AI/AI_A2A_Dispatcher/AID-A2A-009%20-%20Border%20Test)
--
-- In this example a border is set for the CCCP A2A dispatcher:
--
@@ -1146,14 +1151,14 @@ do -- AI_A2A_DISPATCHER
local AirbaseName = EventData.PlaceName -- The name of the airbase that was captured.
self:I( "Captured " .. AirbaseName )
self:T( "Captured " .. AirbaseName )
-- Now search for all squadrons located at the airbase, and sanitize them.
for SquadronName, Squadron in pairs( self.DefenderSquadrons ) do
if Squadron.AirbaseName == AirbaseName then
Squadron.ResourceCount = -999 -- The base has been captured, and the resources are eliminated. No more spawning.
Squadron.Captured = true
self:I( "Squadron " .. SquadronName .. " captured." )
self:T( "Squadron " .. SquadronName .. " captured." )
end
end
end
@@ -1228,7 +1233,7 @@ do -- AI_A2A_DISPATCHER
--
-- **Use the method @{#AI_A2A_DISPATCHER.SetEngageRadius}() to modify the default Engage Radius for ALL squadrons.**
--
-- Demonstration Mission: [AID-019 - AI_A2A - Engage Range Test](https://github.com/FlightControl-Master/MOOSE_MISSIONS/tree/release-2-2-pre/AID%20-%20AI%20Dispatching/AID-019%20-%20AI_A2A%20-%20Engage%20Range%20Test)
-- Demonstration Mission: [AID-019 - AI_A2A - Engage Range Test](https://github.com/FlightControl-Master/MOOSE_MISSIONS/tree/master/AI/AI_A2A_Dispatcher/AID-A2A-019%20-%20Engage%20Range%20Test)
--
-- @param #AI_A2A_DISPATCHER self
-- @param #number EngageRadius (Optional, Default = 100000) The radius to report friendlies near the target.
@@ -1278,7 +1283,7 @@ do -- AI_A2A_DISPATCHER
-- Use the method @{#AI_A2A_DISPATCHER.SetGciRadius}() to set a specific controlled ground intercept radius.
-- **The Ground Controlled Intercept radius is defined for ALL squadrons which are operational.**
--
-- Demonstration Mission: [AID-013 - AI_A2A - Intercept Test](https://github.com/FlightControl-Master/MOOSE_MISSIONS/tree/release-2-2-pre/AID%20-%20AI%20Dispatching/AID-013%20-%20AI_A2A%20-%20Intercept%20Test)
-- Demonstration Mission: [AID-013 - AI_A2A - Intercept Test](https://github.com/FlightControl-Master/MOOSE_MISSIONS/tree/master/AI/AI_A2A_Dispatcher/AID-A2A-013%20-%20Intercept%20Test)
--
-- @param #AI_A2A_DISPATCHER self
-- @param #number GciRadius (Optional, Default = 200000) The radius to ground control intercept detected targets from the nearest airbase.
@@ -1823,7 +1828,7 @@ do -- AI_A2A_DISPATCHER
self:SetSquadronCapInterval( SquadronName, self.DefenderDefault.CapLimit, self.DefenderDefault.CapMinSeconds, self.DefenderDefault.CapMaxSeconds, 1 )
self:I( { CAP = { SquadronName, EngageMinSpeed, EngageMaxSpeed, EngageFloorAltitude, EngageCeilingAltitude, Zone, PatrolMinSpeed, PatrolMaxSpeed, PatrolFloorAltitude, PatrolCeilingAltitude, PatrolAltType, EngageAltType } } )
self:T( { CAP = { SquadronName, EngageMinSpeed, EngageMaxSpeed, EngageFloorAltitude, EngageCeilingAltitude, Zone, PatrolMinSpeed, PatrolMaxSpeed, PatrolFloorAltitude, PatrolCeilingAltitude, PatrolAltType, EngageAltType } } )
-- Add the CAP to the EWR network.
@@ -2080,7 +2085,7 @@ do -- AI_A2A_DISPATCHER
Intercept.EngageCeilingAltitude = EngageCeilingAltitude
Intercept.EngageAltType = EngageAltType
self:I( { GCI = { SquadronName, EngageMinSpeed, EngageMaxSpeed, EngageFloorAltitude, EngageCeilingAltitude, EngageAltType } } )
self:T( { GCI = { SquadronName, EngageMinSpeed, EngageMaxSpeed, EngageFloorAltitude, EngageCeilingAltitude, EngageAltType } } )
end
--- Set squadron GCI.
@@ -2995,17 +3000,17 @@ do -- AI_A2A_DISPATCHER
for FriendlyDistance, AIFriendly in UTILS.spairs( DefenderFriendlies or {} ) do
-- We only allow to ENGAGE targets as long as the Units on both sides are balanced.
if AttackerCount > DefenderCount then
--self:I("***** AI_A2A_DISPATCHER:CountDefendersToBeEngaged() *****\nThis is supposed to be a UNIT:")
--self:T("***** AI_A2A_DISPATCHER:CountDefendersToBeEngaged() *****\nThis is supposed to be a UNIT:")
if AIFriendly then
local classname = AIFriendly.ClassName or "No Class Name"
local unitname = AIFriendly.IdentifiableName or "No Unit Name"
--self:I("Class Name: " .. classname)
--self:I("Unit Name: " .. unitname)
--self:I({AIFriendly})
--self:T("Class Name: " .. classname)
--self:T("Unit Name: " .. unitname)
--self:T({AIFriendly})
end
local Friendly = nil
if AIFriendly and AIFriendly:IsAlive() then
--self:I("AIFriendly alive, getting GROUP")
--self:T("AIFriendly alive, getting GROUP")
Friendly = AIFriendly:GetGroup() -- Wrapper.Group#GROUP
end
@@ -3252,7 +3257,8 @@ do -- AI_A2A_DISPATCHER
end
end
--- @param #AI_A2A_DISPATCHER self
--- AI_A2A_Fsm:onafterHome
-- @param #AI_A2A_DISPATCHER self
function AI_A2A_Fsm:onafterHome( Defender, From, Event, To, Action )
if Defender and Defender:IsAlive() then
self:F( { "CAP Home", Defender:GetName() } )
@@ -3500,7 +3506,8 @@ do -- AI_A2A_DISPATCHER
Dispatcher:ClearDefenderTaskTarget( DefenderGroup )
end
--- @param #AI_A2A_DISPATCHER self
--- function Fsm:onafterLostControl
-- @param #AI_A2A_DISPATCHER self
function Fsm:onafterLostControl( Defender, From, Event, To )
self:F( { "GCI LostControl", Defender:GetName() } )
self:GetParent( self ).onafterHome( self, Defender, From, Event, To )
@@ -3513,7 +3520,8 @@ do -- AI_A2A_DISPATCHER
end
end
--- @param #AI_A2A_DISPATCHER self
--- function Fsm:onafterHome
-- @param #AI_A2A_DISPATCHER self
function Fsm:onafterHome( DefenderGroup, From, Event, To, Action )
self:F( { "GCI Home", DefenderGroup:GetName() } )
self:GetParent( self ).onafterHome( self, DefenderGroup, From, Event, To )
@@ -3944,7 +3952,7 @@ end
do
--- @type AI_A2A_GCICAP
-- @type AI_A2A_GCICAP
-- @extends #AI_A2A_DISPATCHER
--- Create an automatic air defence system for a coalition setting up GCI and CAP air defenses.
@@ -3954,7 +3962,7 @@ do
--
-- # Demo Missions
--
-- ### [Demo Missions](https://github.com/FlightControl-Master/MOOSE_MISSIONS/tree/master/AID%20-%20AI%20Dispatching/AID-A2A%20-%20AI%20A2A%20Dispatching)
-- ### [Demo Missions](https://github.com/FlightControl-Master/MOOSE_MISSIONS/tree/master/AI/AI_A2A_Dispatcher)
--
-- ===
--
@@ -4314,23 +4322,23 @@ do
-- Setup squadrons
self:I( { Airbases = AirbaseNames } )
self:T( { Airbases = AirbaseNames } )
self:I( "Defining Templates for Airbases ..." )
self:T( "Defining Templates for Airbases ..." )
for AirbaseID, AirbaseName in pairs( AirbaseNames ) do
local Airbase = _DATABASE:FindAirbase( AirbaseName ) -- Wrapper.Airbase#AIRBASE
local AirbaseName = Airbase:GetName()
local AirbaseCoord = Airbase:GetCoordinate()
local AirbaseZone = ZONE_RADIUS:New( "Airbase", AirbaseCoord:GetVec2(), 3000 )
local Templates = nil
self:I( { Airbase = AirbaseName } )
self:T( { Airbase = AirbaseName } )
for TemplateID, Template in pairs( self.Templates:GetSet() ) do
local Template = Template -- Wrapper.Group#GROUP
local TemplateCoord = Template:GetCoordinate()
if AirbaseZone:IsVec2InZone( TemplateCoord:GetVec2() ) then
Templates = Templates or {}
table.insert( Templates, Template:GetName() )
self:I( { Template = Template:GetName() } )
self:T( { Template = Template:GetName() } )
end
end
if Templates then
@@ -4346,13 +4354,13 @@ do
self.CAPTemplates:FilterPrefixes( CapPrefixes )
self.CAPTemplates:FilterOnce()
self:I( "Setting up CAP ..." )
self:T( "Setting up CAP ..." )
for CAPID, CAPTemplate in pairs( self.CAPTemplates:GetSet() ) do
local CAPZone = ZONE_POLYGON:New( CAPTemplate:GetName(), CAPTemplate )
-- Now find the closest airbase from the ZONE (start or center)
local AirbaseDistance = 99999999
local AirbaseClosest = nil -- Wrapper.Airbase#AIRBASE
self:I( { CAPZoneGroup = CAPID } )
self:T( { CAPZoneGroup = CAPID } )
for AirbaseID, AirbaseName in pairs( AirbaseNames ) do
local Airbase = _DATABASE:FindAirbase( AirbaseName ) -- Wrapper.Airbase#AIRBASE
local AirbaseName = Airbase:GetName()
@@ -4360,7 +4368,7 @@ do
local Squadron = self.DefenderSquadrons[AirbaseName]
if Squadron then
local Distance = AirbaseCoord:Get2DDistance( CAPZone:GetCoordinate() )
self:I( { AirbaseDistance = Distance } )
self:T( { AirbaseDistance = Distance } )
if Distance < AirbaseDistance then
AirbaseDistance = Distance
AirbaseClosest = Airbase
@@ -4368,7 +4376,7 @@ do
end
end
if AirbaseClosest then
self:I( { CAPAirbase = AirbaseClosest:GetName() } )
self:T( { CAPAirbase = AirbaseClosest:GetName() } )
self:SetSquadronCap( AirbaseClosest:GetName(), CAPZone, 6000, 10000, 500, 800, 800, 1200, "RADIO" )
self:SetSquadronCapInterval( AirbaseClosest:GetName(), CapLimit, 300, 600, 1 )
end
@@ -4376,14 +4384,14 @@ do
-- Setup GCI.
-- GCI is setup for all Squadrons.
self:I( "Setting up GCI ..." )
self:T( "Setting up GCI ..." )
for AirbaseID, AirbaseName in pairs( AirbaseNames ) do
local Airbase = _DATABASE:FindAirbase( AirbaseName ) -- Wrapper.Airbase#AIRBASE
local AirbaseName = Airbase:GetName()
local Squadron = self.DefenderSquadrons[AirbaseName]
self:F( { Airbase = AirbaseName } )
if Squadron then
self:I( { GCIAirbase = AirbaseName } )
self:T( { GCIAirbase = AirbaseName } )
self:SetSquadronGci( AirbaseName, 800, 1200 )
end
end

View File

@@ -14,47 +14,31 @@
--- @type AI_A2A_GCI
-- @extends AI.AI_A2A#AI_A2A
-- @extends AI.AI_Air_Engage#AI_AIR_ENGAGE
--- Implements the core functions to intercept intruders. Use the Engage trigger to intercept intruders.
--
-- ![Process](..\Presentations\AI_GCI\Dia3.JPG)
--
-- The AI_A2A_GCI is assigned a @{Wrapper.Group} and this must be done before the AI_A2A_GCI process can be started using the **Start** event.
--
-- ![Process](..\Presentations\AI_GCI\Dia4.JPG)
--
-- The AI will fly towards the random 3D point within the patrol zone, using a random speed within the given altitude and speed limits.
-- Upon arrival at the 3D point, a new random 3D point will be selected within the patrol zone using the given limits.
--
-- ![Process](..\Presentations\AI_GCI\Dia5.JPG)
--
-- This cycle will continue.
--
-- ![Process](..\Presentations\AI_GCI\Dia6.JPG)
--
-- During the patrol, the AI will detect enemy targets, which are reported through the **Detected** event.
--
-- ![Process](..\Presentations\AI_GCI\Dia9.JPG)
--
-- When enemies are detected, the AI will automatically engage the enemy.
--
-- ![Process](..\Presentations\AI_GCI\Dia10.JPG)
--
-- Until a fuel or damage threshold has been reached by the AI, or when the AI is commanded to RTB.
-- When the fuel threshold has been reached, the airplane will fly towards the nearest friendly airbase and will land.
--
-- ![Process](..\Presentations\AI_GCI\Dia13.JPG)
--
-- ## 1. AI_A2A_GCI constructor
--
-- * @{#AI_A2A_GCI.New}(): Creates a new AI_A2A_GCI object.
--
-- ## 2. AI_A2A_GCI is a FSM
--
-- ![Process](..\Presentations\AI_GCI\Dia2.JPG)
--
-- ### 2.1 AI_A2A_GCI States
--
-- * **None** ( Group ): The process is not started yet.
@@ -75,23 +59,10 @@
-- * **@{#AI_A2A_GCI.Destroyed}**: The AI has destroyed all bogeys @{Wrapper.Unit}s assigned in the CAS task.
-- * **Status** ( Group ): The AI is checking status (fuel and damage). When the thresholds have been reached, the AI will RTB.
--
-- ## 3. Set the Range of Engagement
-- # Developer Note
--
-- ![Range](..\Presentations\AI_GCI\Dia11.JPG)
--
-- An optional range can be set in meters,
-- that will define when the AI will engage with the detected airborne enemy targets.
-- The range can be beyond or smaller than the range of the Patrol Zone.
-- The range is applied at the position of the AI.
-- Use the method @{AI.AI_GCI#AI_A2A_GCI.SetEngageRange}() to define that range.
--
-- ## 4. Set the Zone of Engagement
--
-- ![Zone](..\Presentations\AI_GCI\Dia12.JPG)
--
-- An optional @{Core.Zone} can be set,
-- that will define when the AI will engage with the detected airborne enemy targets.
-- Use the method @{AI.AI_CAP#AI_CAP_ZONE.SetEngageZone}() to define that Zone.
-- Note while this class still works, it is no longer supported as the original author stopped active development of MOOSE
-- Therefore, this class is considered to be deprecated
--
-- ===
--

View File

@@ -11,7 +11,7 @@
--- @type AI_A2A_PATROL
-- @extends AI.AI_A2A#AI_A2A
-- @extends AI.AI_Air_Patrol#AI_AIR_PATROL
--- Implements the core functions to patrol a @{Core.Zone} by an AI @{Wrapper.Group} or @{Wrapper.Group}.
--
@@ -111,7 +111,12 @@
-- When the AI is damaged, it is required that a new Patrol is started. However, damage cannon be foreseen early on.
-- Therefore, when the damage threshold is reached, the AI will return immediately to the home base (RTB).
-- Use the method @{#AI_A2A_PATROL.ManageDamage}() to have this proces in place.
--
-- # Developer Note
--
-- Note while this class still works, it is no longer supported as the original author stopped active development of MOOSE
-- Therefore, this class is considered to be deprecated
--
-- ===
--
-- @field #AI_A2A_PATROL

View File

@@ -12,10 +12,16 @@
-- @image AI_Air_To_Ground_Engage.JPG
--- @type AI_A2G_BAI
-- @extends AI.AI_A2A_Engage#AI_A2A_Engage -- TODO: Documentation. This class does not exist, unable to determine what it extends.
-- @extends AI.AI_Air_Patrol#AI_AIR_PATROL
-- @extends AI.AI_Air_Engage#AI_AIR_ENGAGE
--- Implements the core functions to intercept intruders. Use the Engage trigger to intercept intruders.
--
-- # Developer Note
--
-- Note while this class still works, it is no longer supported as the original author stopped active development of MOOSE
-- Therefore, this class is considered to be deprecated
--
-- ===
--
-- @field #AI_A2G_BAI
@@ -41,7 +47,7 @@ AI_A2G_BAI = {
function AI_A2G_BAI:New2( AIGroup, EngageMinSpeed, EngageMaxSpeed, EngageFloorAltitude, EngageCeilingAltitude, EngageAltType, PatrolZone, PatrolFloorAltitude, PatrolCeilingAltitude, PatrolMinSpeed, PatrolMaxSpeed, PatrolAltType )
local AI_Air = AI_AIR:New( AIGroup )
local AI_Air_Patrol = AI_AIR_PATROL:New( AI_Air, AIGroup, PatrolZone, PatrolFloorAltitude, PatrolCeilingAltitude, PatrolMinSpeed, PatrolMaxSpeed, PatrolAltType ) -- #AI_AIR_PATROL
local AI_Air_Patrol = AI_AIR_PATROL:New( AI_Air, AIGroup, PatrolZone, PatrolFloorAltitude, PatrolCeilingAltitude, PatrolMinSpeed, PatrolMaxSpeed, PatrolAltType )
local AI_Air_Engage = AI_AIR_ENGAGE:New( AI_Air_Patrol, AIGroup, EngageMinSpeed, EngageMaxSpeed, EngageFloorAltitude, EngageCeilingAltitude, EngageAltType )
local self = BASE:Inherit( self, AI_Air_Engage )

View File

@@ -12,10 +12,16 @@
-- @image AI_Air_To_Ground_Engage.JPG
--- @type AI_A2G_CAS
-- @extends AI.AI_A2G_Patrol#AI_AIR_PATROL TODO: Documentation. This class does not exist, unable to determine what it extends.
-- @extends AI.AI_Air_Patrol#AI_AIR_PATROL
-- @extends AI.AI_Air_Engage#AI_AIR_ENGAGE
--- Implements the core functions to intercept intruders. Use the Engage trigger to intercept intruders.
--
-- # Developer Note
--
-- Note while this class still works, it is no longer supported as the original author stopped active development of MOOSE
-- Therefore, this class is considered to be deprecated
--
-- ===
--
-- @field #AI_A2G_CAS
@@ -41,7 +47,7 @@ AI_A2G_CAS = {
function AI_A2G_CAS:New2( AIGroup, EngageMinSpeed, EngageMaxSpeed, EngageFloorAltitude, EngageCeilingAltitude, EngageAltType, PatrolZone, PatrolFloorAltitude, PatrolCeilingAltitude, PatrolMinSpeed, PatrolMaxSpeed, PatrolAltType )
local AI_Air = AI_AIR:New( AIGroup )
local AI_Air_Patrol = AI_AIR_PATROL:New( AI_Air, AIGroup, PatrolZone, PatrolFloorAltitude, PatrolCeilingAltitude, PatrolMinSpeed, PatrolMaxSpeed, PatrolAltType ) -- #AI_AIR_PATROL
local AI_Air_Patrol = AI_AIR_PATROL:New( AI_Air, AIGroup, PatrolZone, PatrolFloorAltitude, PatrolCeilingAltitude, PatrolMinSpeed, PatrolMaxSpeed, PatrolAltType )
local AI_Air_Engage = AI_AIR_ENGAGE:New( AI_Air_Patrol, AIGroup, EngageMinSpeed, EngageMaxSpeed, EngageFloorAltitude, EngageCeilingAltitude, EngageAltType )
local self = BASE:Inherit( self, AI_Air_Engage )

View File

@@ -24,7 +24,7 @@
--
-- ## Missions:
--
-- [AID-A2G - AI A2G Dispatching](https://github.com/FlightControl-Master/MOOSE_MISSIONS/tree/master/AID%20-%20AI%20Dispatching/AID-A2G%20-%20AI%20A2G%20Dispatching)
-- [AID-A2G - AI A2G Dispatching](https://github.com/FlightControl-Master/MOOSE_MISSIONS/tree/master/AI/AI_A2G_Dispatcher)
--
-- ===
--
@@ -253,7 +253,12 @@
--
-- **The default grouping is 1. That means, that each spawned defender will act individually.**
-- But you can specify a number between 1 and 4, so that the defenders will act as a group.
--
-- # Developer Note
--
-- Note while this class still works, it is no longer supported as the original author stopped active development of MOOSE
-- Therefore, this class is considered to be deprecated
--
-- ===
--
-- ### Author: **FlightControl** rework of GCICAP + introduction of new concepts (squadrons).
@@ -291,8 +296,6 @@ do -- AI_A2G_DISPATCHER
--
-- ## 1. AI\_A2G\_DISPATCHER constructor:
--
-- ![Banner Image](..\Presentations\AI_A2G_DISPATCHER\AI_A2G_DISPATCHER-ME_1.JPG)
--
--
-- The @{#AI_A2G_DISPATCHER.New}() method creates a new AI_A2G_DISPATCHER instance.
--
@@ -306,8 +309,6 @@ do -- AI_A2G_DISPATCHER
-- A reconnaissance network, is used to detect enemy ground targets,
-- potentially group them into areas, and to understand the position, level of threat of the enemy.
--
-- ![Banner Image](..\Presentations\AI_A2G_DISPATCHER\Dia5.JPG)
--
-- As explained in the introduction, depending on the type of mission you want to achieve, different types of units can be applied to detect ground enemy targets.
-- Ground based units are very useful to act as a reconnaissance, but they lack sometimes the visibility to detect targets at greater range.
-- Recce are very useful to acquire the position of enemy ground targets when spread out over the battlefield at strategic positions.
@@ -681,8 +682,6 @@ do -- AI_A2G_DISPATCHER
--
-- Use the method @{#AI_A2G_DISPATCHER.SetSquadronGrouping}() to set the grouping of aircraft when spawned in.
--
-- ![Banner Image](..\Presentations\AI_A2G_DISPATCHER\Dia12.JPG)
--
-- In the case of **on call** engagement, the @{#AI_A2G_DISPATCHER.SetSquadronGrouping}() method has additional behaviour.
-- When there aren't enough patrol flights airborne, a on call will be initiated for the remaining
-- targets to be engaged. Depending on the grouping parameter, the spawned flights for on call aircraft are grouped into this setting.
@@ -696,8 +695,6 @@ do -- AI_A2G_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_A2G_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_A2G_DISPATCHER.SetSquadronOverhead}() method can be used to tweak the defense strength,
@@ -843,8 +840,6 @@ do -- AI_A2G_DISPATCHER
--
-- For example, the following setup will set the default refuel tanker to "Tanker":
--
-- ![Banner Image](..\Presentations\AI_A2G_DISPATCHER\AI_A2G_DISPATCHER-ME_11.JPG)
--
-- -- Set the default tanker for refuelling to "Tanker", when the default fuel threshold has reached 90% fuel left.
-- A2GDispatcher:SetDefaultFuelThreshold( 0.9 )
-- A2GDispatcher:SetDefaultTanker( "Tanker" )
@@ -909,14 +904,14 @@ do -- AI_A2G_DISPATCHER
-- @type AI_A2G_DISPATCHER.DefenseCoordinates
-- @map <#string,Core.Point#COORDINATE> A list of all defense coordinates mapped per defense coordinate name.
--- @field #AI_A2G_DISPATCHER.DefenseCoordinates DefenseCoordinates
-- @field #AI_A2G_DISPATCHER.DefenseCoordinates DefenseCoordinates
AI_A2G_DISPATCHER.DefenseCoordinates = {}
--- Enumerator for spawns at airbases.
-- @type AI_A2G_DISPATCHER.Takeoff
-- @extends Wrapper.Group#GROUP.Takeoff
--- @field #AI_A2G_DISPATCHER.Takeoff Takeoff
-- @field #AI_A2G_DISPATCHER.Takeoff Takeoff
AI_A2G_DISPATCHER.Takeoff = GROUP.Takeoff
--- Defines Landing location.
@@ -947,7 +942,7 @@ do -- AI_A2G_DISPATCHER
-- @type AI_A2G_DISPATCHER.DefenseQueue
-- @list<#AI_A2G_DISPATCHER.DefenseQueueItem> DefenseQueueItem A list of all defenses being queued ...
--- @field #AI_A2G_DISPATCHER.DefenseQueue DefenseQueue
-- @field #AI_A2G_DISPATCHER.DefenseQueue DefenseQueue
AI_A2G_DISPATCHER.DefenseQueue = {}
--- Defense approach types.
@@ -1141,7 +1136,7 @@ do -- AI_A2G_DISPATCHER
end
--- @param #AI_A2G_DISPATCHER self
-- @param #AI_A2G_DISPATCHER self
function AI_A2G_DISPATCHER:onafterStart( From, Event, To )
self:GetParent( self ).onafterStart( self, From, Event, To )
@@ -1152,7 +1147,7 @@ do -- AI_A2G_DISPATCHER
for Resource = 1, DefenderSquadron.ResourceCount or 0 do
self:ResourcePark( DefenderSquadron )
end
self:I( "Parked resources for squadron " .. DefenderSquadron.Name )
self:T( "Parked resources for squadron " .. DefenderSquadron.Name )
end
end
@@ -1206,7 +1201,7 @@ do -- AI_A2G_DISPATCHER
end
--- @param #AI_A2G_DISPATCHER self
-- @param #AI_A2G_DISPATCHER self
function AI_A2G_DISPATCHER:ResourcePark( DefenderSquadron )
local TemplateID = math.random( 1, #DefenderSquadron.Spawn )
local Spawn = DefenderSquadron.Spawn[ TemplateID ] -- Core.Spawn#SPAWN
@@ -1223,33 +1218,33 @@ do -- AI_A2G_DISPATCHER
end
--- @param #AI_A2G_DISPATCHER self
-- @param #AI_A2G_DISPATCHER self
-- @param Core.Event#EVENTDATA EventData
function AI_A2G_DISPATCHER:OnEventBaseCaptured( EventData )
local AirbaseName = EventData.PlaceName -- The name of the airbase that was captured.
self:I( "Captured " .. AirbaseName )
self:T( "Captured " .. AirbaseName )
-- Now search for all squadrons located at the airbase, and sanitize them.
for SquadronName, Squadron in pairs( self.DefenderSquadrons ) do
if Squadron.AirbaseName == AirbaseName then
Squadron.ResourceCount = -999 -- The base has been captured, and the resources are eliminated. No more spawning.
Squadron.Captured = true
self:I( "Squadron " .. SquadronName .. " captured." )
self:T( "Squadron " .. SquadronName .. " captured." )
end
end
end
--- @param #AI_A2G_DISPATCHER self
-- @param #AI_A2G_DISPATCHER self
-- @param Core.Event#EVENTDATA EventData
function AI_A2G_DISPATCHER:OnEventCrashOrDead( EventData )
self.Detection:ForgetDetectedUnit( EventData.IniUnitName )
end
--- @param #AI_A2G_DISPATCHER self
-- @param #AI_A2G_DISPATCHER self
-- @param Core.Event#EVENTDATA EventData
function AI_A2G_DISPATCHER:OnEventLand( EventData )
self:F( "Landed" )
@@ -1266,7 +1261,7 @@ do -- AI_A2G_DISPATCHER
self:RemoveDefenderFromSquadron( Squadron, Defender )
end
DefenderUnit:Destroy()
self:ResourcePark( Squadron, Defender )
self:ResourcePark( Squadron )
return
end
if DefenderUnit:GetLife() ~= DefenderUnit:GetLife0() then
@@ -1278,7 +1273,7 @@ do -- AI_A2G_DISPATCHER
end
--- @param #AI_A2G_DISPATCHER self
-- @param #AI_A2G_DISPATCHER self
-- @param Core.Event#EVENTDATA EventData
function AI_A2G_DISPATCHER:OnEventEngineShutdown( EventData )
local DefenderUnit = EventData.IniUnit
@@ -1294,7 +1289,7 @@ do -- AI_A2G_DISPATCHER
self:RemoveDefenderFromSquadron( Squadron, Defender )
end
DefenderUnit:Destroy()
self:ResourcePark( Squadron, Defender )
self:ResourcePark( Squadron )
end
end
end
@@ -1302,7 +1297,7 @@ do -- AI_A2G_DISPATCHER
do -- Manage the defensive behaviour
--- @param #AI_A2G_DISPATCHER self
-- @param #AI_A2G_DISPATCHER self
-- @param #string DefenseCoordinateName The name of the coordinate to be defended by A2G defenses.
-- @param Core.Point#COORDINATE DefenseCoordinate The coordinate to be defended by A2G defenses.
function AI_A2G_DISPATCHER:AddDefenseCoordinate( DefenseCoordinateName, DefenseCoordinate )
@@ -1310,19 +1305,19 @@ do -- AI_A2G_DISPATCHER
end
--- @param #AI_A2G_DISPATCHER self
-- @param #AI_A2G_DISPATCHER self
function AI_A2G_DISPATCHER:SetDefenseReactivityLow()
self.DefenseReactivity = 0.05
end
--- @param #AI_A2G_DISPATCHER self
-- @param #AI_A2G_DISPATCHER self
function AI_A2G_DISPATCHER:SetDefenseReactivityMedium()
self.DefenseReactivity = 0.15
end
--- @param #AI_A2G_DISPATCHER self
-- @param #AI_A2G_DISPATCHER self
function AI_A2G_DISPATCHER:SetDefenseReactivityHigh()
self.DefenseReactivity = 0.5
end
@@ -1356,14 +1351,14 @@ do -- AI_A2G_DISPATCHER
-- 1. the **distance of the closest airbase to target**, being smaller than the **Defend Radius**.
-- 2. the **distance to any defense reference point**.
--
-- The **default** defense radius is defined as **400000** or **40km**. Override the default defense radius when the era of the warfare is early, or,
-- The **default** defense radius is defined as **40000** or **40km**. Override the default defense radius when the era of the warfare is early, or,
-- when you don't want to let the AI_A2G_DISPATCHER react immediately when a certain border or area is not being crossed.
--
-- Use the method @{#AI_A2G_DISPATCHER.SetDefendRadius}() to set a specific defend radius for all squadrons,
-- **the Defense Radius is defined for ALL squadrons which are operational.**
--
-- @param #AI_A2G_DISPATCHER self
-- @param #number DefenseRadius (Optional, Default = 200000) The defense radius to engage detected targets from the nearest capable and available squadron airbase.
-- @param #number DefenseRadius (Optional, Default = 20000) The defense radius to engage detected targets from the nearest capable and available squadron airbase.
-- @return #AI_A2G_DISPATCHER
-- @usage
--
@@ -1378,7 +1373,7 @@ do -- AI_A2G_DISPATCHER
--
function AI_A2G_DISPATCHER:SetDefenseRadius( DefenseRadius )
self.DefenseRadius = DefenseRadius or 100000
self.DefenseRadius = DefenseRadius or 40000
self.Detection:SetAcceptRange( self.DefenseRadius )
@@ -1873,7 +1868,7 @@ do -- AI_A2G_DISPATCHER
end
--- @param #AI_A2G_DISPATCHER self
-- @param #AI_A2G_DISPATCHER self
-- @param #string SquadronName The squadron name.
-- @param #number TakeoffInterval Only Takeoff new units each specified interval in seconds in 10 seconds steps.
-- @usage
@@ -2149,7 +2144,7 @@ do -- AI_A2G_DISPATCHER
Sead.EngageAltType = EngageAltType
Sead.Defend = true
self:I( { SEAD = { SquadronName, EngageMinSpeed, EngageMaxSpeed, EngageFloorAltitude, EngageCeilingAltitude, EngageAltType } } )
self:T( { SEAD = { SquadronName, EngageMinSpeed, EngageMaxSpeed, EngageFloorAltitude, EngageCeilingAltitude, EngageAltType } } )
return self
end
@@ -2239,7 +2234,7 @@ do -- AI_A2G_DISPATCHER
self:SetSquadronPatrolInterval( SquadronName, self.DefenderDefault.PatrolLimit, self.DefenderDefault.PatrolMinSeconds, self.DefenderDefault.PatrolMaxSeconds, 1, "SEAD" )
self:I( { SEAD = { Zone:GetName(), PatrolMinSpeed, PatrolMaxSpeed, PatrolFloorAltitude, PatrolCeilingAltitude, PatrolAltType, EngageMinSpeed, EngageMaxSpeed, EngageFloorAltitude, EngageCeilingAltitude, EngageAltType } } )
self:T( { SEAD = { Zone:GetName(), PatrolMinSpeed, PatrolMaxSpeed, PatrolFloorAltitude, PatrolCeilingAltitude, PatrolAltType, EngageMinSpeed, EngageMaxSpeed, EngageFloorAltitude, EngageCeilingAltitude, EngageAltType } } )
end
@@ -2300,7 +2295,7 @@ do -- AI_A2G_DISPATCHER
Cas.EngageAltType = EngageAltType
Cas.Defend = true
self:I( { CAS = { SquadronName, EngageMinSpeed, EngageMaxSpeed, EngageFloorAltitude, EngageCeilingAltitude, EngageAltType } } )
self:T( { CAS = { SquadronName, EngageMinSpeed, EngageMaxSpeed, EngageFloorAltitude, EngageCeilingAltitude, EngageAltType } } )
return self
end
@@ -2390,7 +2385,7 @@ do -- AI_A2G_DISPATCHER
self:SetSquadronPatrolInterval( SquadronName, self.DefenderDefault.PatrolLimit, self.DefenderDefault.PatrolMinSeconds, self.DefenderDefault.PatrolMaxSeconds, 1, "CAS" )
self:I( { CAS = { Zone:GetName(), PatrolMinSpeed, PatrolMaxSpeed, PatrolFloorAltitude, PatrolCeilingAltitude, PatrolAltType, EngageMinSpeed, EngageMaxSpeed, EngageFloorAltitude, EngageCeilingAltitude, EngageAltType } } )
self:T( { CAS = { Zone:GetName(), PatrolMinSpeed, PatrolMaxSpeed, PatrolFloorAltitude, PatrolCeilingAltitude, PatrolAltType, EngageMinSpeed, EngageMaxSpeed, EngageFloorAltitude, EngageCeilingAltitude, EngageAltType } } )
end
@@ -2451,7 +2446,7 @@ do -- AI_A2G_DISPATCHER
Bai.EngageAltType = EngageAltType
Bai.Defend = true
self:I( { BAI = { SquadronName, EngageMinSpeed, EngageMaxSpeed, EngageFloorAltitude, EngageCeilingAltitude, EngageAltType } } )
self:T( { BAI = { SquadronName, EngageMinSpeed, EngageMaxSpeed, EngageFloorAltitude, EngageCeilingAltitude, EngageAltType } } )
return self
end
@@ -2541,7 +2536,7 @@ do -- AI_A2G_DISPATCHER
self:SetSquadronPatrolInterval( SquadronName, self.DefenderDefault.PatrolLimit, self.DefenderDefault.PatrolMinSeconds, self.DefenderDefault.PatrolMaxSeconds, 1, "BAI" )
self:I( { BAI = { Zone:GetName(), PatrolMinSpeed, PatrolMaxSpeed, PatrolFloorAltitude, PatrolCeilingAltitude, PatrolAltType, EngageMinSpeed, EngageMaxSpeed, EngageFloorAltitude, EngageCeilingAltitude, EngageAltType } } )
self:T( { BAI = { Zone:GetName(), PatrolMinSpeed, PatrolMaxSpeed, PatrolFloorAltitude, PatrolCeilingAltitude, PatrolAltType, EngageMinSpeed, EngageMaxSpeed, EngageFloorAltitude, EngageCeilingAltitude, EngageAltType } } )
end
@@ -3374,7 +3369,7 @@ do -- AI_A2G_DISPATCHER
end
--- @param #AI_A2G_DISPATCHER self
-- @param #AI_A2G_DISPATCHER self
function AI_A2G_DISPATCHER:AddDefenderToSquadron( Squadron, Defender, Size )
self.Defenders = self.Defenders or {}
local DefenderName = Defender:GetName()
@@ -3385,7 +3380,7 @@ do -- AI_A2G_DISPATCHER
self:F( { DefenderName = DefenderName, SquadronResourceCount = Squadron.ResourceCount } )
end
--- @param #AI_A2G_DISPATCHER self
-- @param #AI_A2G_DISPATCHER self
function AI_A2G_DISPATCHER:RemoveDefenderFromSquadron( Squadron, Defender )
self.Defenders = self.Defenders or {}
local DefenderName = Defender:GetName()
@@ -3801,7 +3796,7 @@ do -- AI_A2G_DISPATCHER
Dispatcher:ClearDefenderTaskTarget( DefenderGroup )
end
--- @param #AI_A2G_DISPATCHER self
-- @param #AI_A2G_DISPATCHER self
function AI_A2G_Fsm:onafterLostControl( DefenderGroup, From, Event, To )
self:F({"LostControl", DefenderGroup:GetName()})
self:GetParent(self).onafterHome( self, DefenderGroup, From, Event, To )
@@ -3818,7 +3813,7 @@ do -- AI_A2G_DISPATCHER
end
end
--- @param #AI_A2G_DISPATCHER self
-- @param #AI_A2G_DISPATCHER self
function AI_A2G_Fsm:onafterHome( DefenderGroup, From, Event, To, Action )
self:F({"Home", DefenderGroup:GetName()})
self:GetParent(self).onafterHome( self, DefenderGroup, From, Event, To )
@@ -3899,7 +3894,7 @@ do -- AI_A2G_DISPATCHER
local Squadron = Dispatcher:GetSquadronFromDefender( DefenderGroup )
if Squadron then
local FirstUnit = AttackSetUnit:GetFirst()
local FirstUnit = AttackSetUnit:GetRandomSurely()
local Coordinate = FirstUnit:GetCoordinate() -- Core.Point#COORDINATE
if self.SetSendPlayerMessages then
Dispatcher:MessageToPlayers( Squadron, DefenderName .. ", on route to ground target at " .. Coordinate:ToStringA2G( DefenderGroup ), DefenderGroup )
@@ -3938,7 +3933,7 @@ do -- AI_A2G_DISPATCHER
Dispatcher:ClearDefenderTaskTarget( DefenderGroup )
end
--- @param #AI_A2G_DISPATCHER self
-- @param #AI_A2G_DISPATCHER self
function AI_A2G_Fsm:onafterLostControl( DefenderGroup, From, Event, To )
self:F({"Defender LostControl", DefenderGroup:GetName()})
self:GetParent(self).onafterHome( self, DefenderGroup, From, Event, To )
@@ -3955,7 +3950,7 @@ do -- AI_A2G_DISPATCHER
end
end
--- @param #AI_A2G_DISPATCHER self
-- @param #AI_A2G_DISPATCHER self
function AI_A2G_Fsm:onafterHome( DefenderGroup, From, Event, To, Action )
self:F({"Defender Home", DefenderGroup:GetName()})
self:GetParent(self).onafterHome( self, DefenderGroup, From, Event, To )

View File

@@ -14,61 +14,43 @@
--- @type AI_A2G_SEAD
-- @extends AI.AI_A2G_Patrol#AI_AIR_PATROL
-- @extends AI.AI_Air_Patrol#AI_AIR_PATROL
-- @extends AI.AI_Air_Engage#AI_AIR_ENGAGE
--- Implements the core functions to SEAD intruders. Use the Engage trigger to intercept intruders.
--
-- ![Process](..\Presentations\AI_GCI\Dia3.JPG)
--
-- The AI_A2G_SEAD is assigned a @{Wrapper.Group} and this must be done before the AI_A2G_SEAD process can be started using the **Start** event.
--
-- ![Process](..\Presentations\AI_GCI\Dia4.JPG)
--
-- The AI will fly towards the random 3D point within the patrol zone, using a random speed within the given altitude and speed limits.
-- Upon arrival at the 3D point, a new random 3D point will be selected within the patrol zone using the given limits.
--
-- ![Process](..\Presentations\AI_GCI\Dia5.JPG)
--
-- This cycle will continue.
--
-- ![Process](..\Presentations\AI_GCI\Dia6.JPG)
--
-- During the patrol, the AI will detect enemy targets, which are reported through the **Detected** event.
--
-- ![Process](..\Presentations\AI_GCI\Dia9.JPG)
--
-- When enemies are detected, the AI will automatically engage the enemy.
--
-- ![Process](..\Presentations\AI_GCI\Dia10.JPG)
--
-- Until a fuel or damage threshold has been reached by the AI, or when the AI is commanded to RTB.
-- When the fuel threshold has been reached, the airplane will fly towards the nearest friendly airbase and will land.
--
-- ![Process](..\Presentations\AI_GCI\Dia13.JPG)
--
-- ## 1. AI_A2G_SEAD constructor
--
-- * @{#AI_A2G_SEAD.New}(): Creates a new AI_A2G_SEAD object.
--
-- ## 3. Set the Range of Engagement
--
-- ![Range](..\Presentations\AI_GCI\Dia11.JPG)
--
-- An optional range can be set in meters,
-- that will define when the AI will engage with the detected airborne enemy targets.
-- The range can be beyond or smaller than the range of the Patrol Zone.
-- The range is applied at the position of the AI.
-- Use the method @{AI.AI_GCI#AI_A2G_SEAD.SetEngageRange}() to define that range.
-- Use the method @{#AI_AIR_PATROL.SetEngageRange}() to define that range.
--
-- ## 4. Set the Zone of Engagement
-- # Developer Note
--
-- ![Zone](..\Presentations\AI_GCI\Dia12.JPG)
--
-- An optional @{Core.Zone} can be set,
-- that will define when the AI will engage with the detected airborne enemy targets.
-- Use the method @{AI.AI_CAP#AI_CAP_ZONE.SetEngageZone}() to define that Zone. -- TODO: Documentation. Check that this is actually correct. The originally referenced class does not exist.
--
-- Note while this class still works, it is no longer supported as the original author stopped active development of MOOSE
-- Therefore, this class is considered to be deprecated
--
-- ===
--
-- @field #AI_A2G_SEAD
@@ -94,7 +76,7 @@ AI_A2G_SEAD = {
function AI_A2G_SEAD:New2( AIGroup, EngageMinSpeed, EngageMaxSpeed, EngageFloorAltitude, EngageCeilingAltitude, EngageAltType, PatrolZone, PatrolFloorAltitude, PatrolCeilingAltitude, PatrolMinSpeed, PatrolMaxSpeed, PatrolAltType )
local AI_Air = AI_AIR:New( AIGroup )
local AI_Air_Patrol = AI_AIR_PATROL:New( AI_Air, AIGroup, PatrolZone, PatrolFloorAltitude, PatrolCeilingAltitude, PatrolMinSpeed, PatrolMaxSpeed, PatrolAltType ) -- #AI_AIR_PATROL
local AI_Air_Patrol = AI_AIR_PATROL:New( AI_Air, AIGroup, PatrolZone, PatrolFloorAltitude, PatrolCeilingAltitude, PatrolMinSpeed, PatrolMaxSpeed, PatrolAltType )
local AI_Air_Engage = AI_AIR_ENGAGE:New( AI_Air_Patrol, AIGroup, EngageMinSpeed, EngageMaxSpeed, EngageFloorAltitude, EngageCeilingAltitude, EngageAltType )
local self = BASE:Inherit( self, AI_Air_Engage )

View File

@@ -9,7 +9,7 @@
-- @module AI.AI_Air
-- @image MOOSE.JPG
--- @type AI_AIR
-- @type AI_AIR
-- @extends Core.Fsm#FSM_CONTROLLABLE
--- The AI_AIR class implements the core functions to operate an AI @{Wrapper.Group}.
@@ -46,6 +46,11 @@
-- * **Stop**: Stop the transport process.
-- * **Monitor**: Monitor and take action.
--
-- # Developer Note
--
-- Note while this class still works, it is no longer supported as the original author stopped active development of MOOSE
-- Therefore, this class is considered to be deprecated
--
-- @field #AI_AIR
AI_AIR = {
ClassName = "AI_AIR",
@@ -259,7 +264,7 @@ function AI_AIR:New( AIGroup )
return self
end
--- @param Wrapper.Group#GROUP self
-- @param Wrapper.Group#GROUP self
-- @param Core.Event#EVENTDATA EventData
function GROUP:OnEventTakeoff( EventData, Fsm )
Fsm:Takeoff()
@@ -441,13 +446,13 @@ function AI_AIR:onafterReturn( Controllable, From, Event, To )
end
--- @param #AI_AIR self
-- @param #AI_AIR self
function AI_AIR:onbeforeStatus()
return self.CheckStatus
end
--- @param #AI_AIR self
-- @param #AI_AIR self
function AI_AIR:onafterStatus()
if self.Controllable and self.Controllable:IsAlive() then
@@ -460,7 +465,7 @@ function AI_AIR:onafterStatus()
local DistanceFromHomeBase = self.HomeAirbase:GetCoordinate():Get2DDistance( self.Controllable:GetCoordinate() )
if DistanceFromHomeBase > self.DisengageRadius then
self:I( self.Controllable:GetName() .. " is too far from home base, RTB!" )
self:T( self.Controllable:GetName() .. " is too far from home base, RTB!" )
self:Hold( 300 )
RTB = false
end
@@ -484,10 +489,10 @@ function AI_AIR:onafterStatus()
if Fuel < self.FuelThresholdPercentage then
if self.TankerName then
self:I( self.Controllable:GetName() .. " is out of fuel: " .. Fuel .. " ... Refuelling at Tanker!" )
self:T( self.Controllable:GetName() .. " is out of fuel: " .. Fuel .. " ... Refuelling at Tanker!" )
self:Refuel()
else
self:I( self.Controllable:GetName() .. " is out of fuel: " .. Fuel .. " ... RTB!" )
self:T( self.Controllable:GetName() .. " is out of fuel: " .. Fuel .. " ... RTB!" )
local OldAIControllable = self.Controllable
local OrbitTask = OldAIControllable:TaskOrbitCircle( math.random( self.PatrolFloorAltitude, self.PatrolCeilingAltitude ), self.PatrolMinSpeed )
@@ -513,7 +518,7 @@ function AI_AIR:onafterStatus()
-- Note that a group can consist of more units, so if one unit is damaged of a group, the mission may continue.
-- The damaged unit will RTB due to DCS logic, and the others will continue to engage.
if ( Damage / InitialLife ) < self.PatrolDamageThreshold then
self:I( self.Controllable:GetName() .. " is damaged: " .. Damage .. " ... RTB!" )
self:T( self.Controllable:GetName() .. " is damaged: " .. Damage .. " ... RTB!" )
self:Damaged()
RTB = true
self:SetStatusOff()
@@ -531,7 +536,7 @@ function AI_AIR:onafterStatus()
if Damage ~= InitialLife then
self:Damaged()
else
self:I( self.Controllable:GetName() .. " control lost! " )
self:T( self.Controllable:GetName() .. " control lost! " )
self:LostControl()
end
@@ -555,7 +560,7 @@ function AI_AIR:onafterStatus()
end
--- @param Wrapper.Group#GROUP AIGroup
-- @param Wrapper.Group#GROUP AIGroup
function AI_AIR.RTBRoute( AIGroup, Fsm )
AIGroup:F( { "AI_AIR.RTBRoute:", AIGroup:GetName() } )
@@ -566,7 +571,7 @@ function AI_AIR.RTBRoute( AIGroup, Fsm )
end
--- @param Wrapper.Group#GROUP AIGroup
-- @param Wrapper.Group#GROUP AIGroup
function AI_AIR.RTBHold( AIGroup, Fsm )
AIGroup:F( { "AI_AIR.RTBHold:", AIGroup:GetName() } )
@@ -593,7 +598,7 @@ function AI_AIR:SetRTBSpeedFactors(MinFactor,MaxFactor)
end
--- @param #AI_AIR self
-- @param #AI_AIR self
-- @param Wrapper.Group#GROUP AIGroup
function AI_AIR:onafterRTB( AIGroup, From, Event, To )
self:F( { AIGroup, From, Event, To } )
@@ -612,7 +617,10 @@ function AI_AIR:onafterRTB( AIGroup, From, Event, To )
--- Calculate the target route point.
local FromCoord = AIGroup:GetCoordinate()
if not FromCoord then return end
local ToTargetCoord = self.HomeAirbase:GetCoordinate() -- coordinate is on land height(!)
local ToTargetVec3 = ToTargetCoord:GetVec3()
ToTargetVec3.y = ToTargetCoord:GetLandHeight()+3000 -- let's set this 1000m/3000 feet above ground
local ToTargetCoord2 = COORDINATE:NewFromVec3( ToTargetVec3 )
@@ -633,13 +641,13 @@ function AI_AIR:onafterRTB( AIGroup, From, Event, To )
local ToAirbaseCoord = ToTargetCoord2
if Distance < 5000 then
self:I( "RTB and near the airbase!" )
self:T( "RTB and near the airbase!" )
self:Home()
return
end
if not AIGroup:InAir() == true then
self:I( "Not anymore in the air, considered Home." )
self:T( "Not anymore in the air, considered Home." )
self:Home()
return
end
@@ -681,12 +689,12 @@ function AI_AIR:onafterRTB( AIGroup, From, Event, To )
end
--- @param #AI_AIR self
-- @param #AI_AIR self
-- @param Wrapper.Group#GROUP AIGroup
function AI_AIR:onafterHome( AIGroup, From, Event, To )
self:F( { AIGroup, From, Event, To } )
self:I( "Group " .. self.Controllable:GetName() .. " ... Home! ( " .. self:GetState() .. " )" )
self:T( "Group " .. self.Controllable:GetName() .. " ... Home! ( " .. self:GetState() .. " )" )
if AIGroup and AIGroup:IsAlive() then
end
@@ -695,15 +703,17 @@ end
--- @param #AI_AIR self
-- @param #AI_AIR self
-- @param Wrapper.Group#GROUP AIGroup
function AI_AIR:onafterHold( AIGroup, From, Event, To, HoldTime )
self:F( { AIGroup, From, Event, To } )
self:I( "Group " .. self.Controllable:GetName() .. " ... Holding! ( " .. self:GetState() .. " )" )
self:T( "Group " .. self.Controllable:GetName() .. " ... Holding! ( " .. self:GetState() .. " )" )
if AIGroup and AIGroup:IsAlive() then
local OrbitTask = AIGroup:TaskOrbitCircle( math.random( self.PatrolFloorAltitude, self.PatrolCeilingAltitude ), self.PatrolMinSpeed )
local Coordinate = AIGroup:GetCoordinate()
if Coordinate == nil then return end
local OrbitTask = AIGroup:TaskOrbitCircle( math.random( self.PatrolFloorAltitude, self.PatrolCeilingAltitude ), self.PatrolMinSpeed, Coordinate )
local TimedOrbitTask = AIGroup:TaskControlled( OrbitTask, AIGroup:TaskCondition( nil, nil, nil, nil, HoldTime , nil ) )
local RTBTask = AIGroup:TaskFunction( "AI_AIR.RTBHold", self )
@@ -717,17 +727,17 @@ function AI_AIR:onafterHold( AIGroup, From, Event, To, HoldTime )
end
--- @param Wrapper.Group#GROUP AIGroup
-- @param Wrapper.Group#GROUP AIGroup
function AI_AIR.Resume( AIGroup, Fsm )
AIGroup:I( { "AI_AIR.Resume:", AIGroup:GetName() } )
AIGroup:T( { "AI_AIR.Resume:", AIGroup:GetName() } )
if AIGroup:IsAlive() then
Fsm:__RTB( Fsm.TaskDelay )
end
end
--- @param #AI_AIR self
-- @param #AI_AIR self
-- @param Wrapper.Group#GROUP AIGroup
function AI_AIR:onafterRefuel( AIGroup, From, Event, To )
self:F( { AIGroup, From, Event, To } )
@@ -739,7 +749,7 @@ function AI_AIR:onafterRefuel( AIGroup, From, Event, To )
if Tanker and Tanker:IsAlive() and Tanker:IsAirPlane() then
self:I( "Group " .. self.Controllable:GetName() .. " ... Refuelling! State=" .. self:GetState() .. ", Refuelling tanker " .. self.TankerName )
self:T( "Group " .. self.Controllable:GetName() .. " ... Refuelling! State=" .. self:GetState() .. ", Refuelling tanker " .. self.TankerName )
local RefuelRoute = {}
@@ -793,13 +803,13 @@ end
--- @param #AI_AIR self
-- @param #AI_AIR self
function AI_AIR:onafterDead()
self:SetStatusOff()
end
--- @param #AI_AIR self
-- @param #AI_AIR self
-- @param Core.Event#EVENTDATA EventData
function AI_AIR:OnCrash( EventData )
@@ -810,7 +820,7 @@ function AI_AIR:OnCrash( EventData )
end
end
--- @param #AI_AIR self
-- @param #AI_AIR self
-- @param Core.Event#EVENTDATA EventData
function AI_AIR:OnEjection( EventData )
@@ -819,7 +829,7 @@ function AI_AIR:OnEjection( EventData )
end
end
--- @param #AI_AIR self
-- @param #AI_AIR self
-- @param Core.Event#EVENTDATA EventData
function AI_AIR:OnPilotDead( EventData )

View File

@@ -24,7 +24,7 @@
--
-- ## Missions:
--
-- [AID-AIR - AI AIR Dispatching](https://github.com/FlightControl-Master/MOOSE_MISSIONS/tree/master/AID%20-%20AI%20Dispatching)
-- [AI_A2A_Dispatcher](https://github.com/FlightControl-Master/MOOSE_MISSIONS/tree/master/AI/AI_A2A_Dispatcher)
--
-- ===
--
@@ -292,8 +292,6 @@ do -- AI_AIR_DISPATCHER
--
-- ## 1. AI\_AIR\_DISPATCHER constructor:
--
-- ![Banner Image](..\Presentations\AI_AIR_DISPATCHER\AI_AIR_DISPATCHER-ME_1.JPG)
--
--
-- The @{#AI_AIR_DISPATCHER.New}() method creates a new AI_AIR_DISPATCHER instance.
--
@@ -306,8 +304,6 @@ do -- AI_AIR_DISPATCHER
-- A reconnaissance network, is used to detect enemy ground targets,
-- potentially group them into areas, and to understand the position, level of threat of the enemy.
--
-- ![Banner Image](..\Presentations\AI_AIR_DISPATCHER\Dia5.JPG)
--
-- As explained in the introduction, depending on the type of mission you want to achieve, different types of units can be applied to detect ground enemy targets.
-- Ground based units are very useful to act as a reconnaissance, but they lack sometimes the visibility to detect targets at greater range.
-- Recce are very useful to acquire the position of enemy ground targets when spread out over the battlefield at strategic positions.
@@ -673,8 +669,6 @@ do -- AI_AIR_DISPATCHER
--
-- Use the method @{#AI_AIR_DISPATCHER.SetSquadronGrouping}() to set the grouping of aircraft when spawned in.
--
-- ![Banner Image](..\Presentations\AI_AIR_DISPATCHER\Dia12.JPG)
--
-- In the case of **on call** engagement, the @{#AI_AIR_DISPATCHER.SetSquadronGrouping}() method has additional behaviour.
-- When there aren't enough patrol flights airborne, a on call will be initiated for the remaining
-- targets to be engaged. Depending on the grouping parameter, the spawned flights for on call aircraft are grouped into this setting.
@@ -688,8 +682,6 @@ do -- AI_AIR_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_AIR_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_AIR_DISPATCHER.SetSquadronOverhead}() method can be used to tweak the defense strength,
@@ -835,8 +827,6 @@ do -- AI_AIR_DISPATCHER
--
-- For example, the following setup will set the default refuel tanker to "Tanker":
--
-- ![Banner Image](..\Presentations\AI_AIR_DISPATCHER\AI_AIR_DISPATCHER-ME_11.JPG)
--
-- -- Define the CAP
-- A2ADispatcher:SetSquadron( "Sochi", AIRBASE.Caucasus.Sochi_Adler, { "SQ CCCP SU-34" }, 20 )
-- A2ADispatcher:SetSquadronCap( "Sochi", ZONE:New( "PatrolZone" ), 4000, 8000, 600, 800, 1000, 1300 )
@@ -883,6 +873,11 @@ do -- AI_AIR_DISPATCHER
-- However, the squadron will still stay alive. Any airplane that is airborne will continue its operations until all airborne airplanes
-- of the squadron will be destroyed. This to keep consistency of air operations not to confuse the players.
--
-- # Developer Note
--
-- Note while this class still works, it is no longer supported as the original author stopped active development of MOOSE
-- Therefore, this class is considered to be deprecated
--
-- @field #AI_AIR_DISPATCHER
AI_AIR_DISPATCHER = {
ClassName = "AI_AIR_DISPATCHER",
@@ -905,14 +900,14 @@ do -- AI_AIR_DISPATCHER
-- @type AI_AIR_DISPATCHER.DefenseCoordinates
-- @map <#string,Core.Point#COORDINATE> A list of all defense coordinates mapped per defense coordinate name.
--- @field #AI_AIR_DISPATCHER.DefenseCoordinates DefenseCoordinates
-- @field #AI_AIR_DISPATCHER.DefenseCoordinates DefenseCoordinates
AI_AIR_DISPATCHER.DefenseCoordinates = {}
--- Enumerator for spawns at airbases
-- @type AI_AIR_DISPATCHER.Takeoff
-- @extends Wrapper.Group#GROUP.Takeoff
--- @field #AI_AIR_DISPATCHER.Takeoff Takeoff
-- @field #AI_AIR_DISPATCHER.Takeoff Takeoff
AI_AIR_DISPATCHER.Takeoff = GROUP.Takeoff
--- Defnes Landing location.
@@ -943,7 +938,7 @@ do -- AI_AIR_DISPATCHER
-- @type AI_AIR_DISPATCHER.DefenseQueue
-- @list<#AI_AIR_DISPATCHER.DefenseQueueItem> DefenseQueueItem A list of all defenses being queued ...
--- @field #AI_AIR_DISPATCHER.DefenseQueue DefenseQueue
-- @field #AI_AIR_DISPATCHER.DefenseQueue DefenseQueue
AI_AIR_DISPATCHER.DefenseQueue = {}
--- Defense approach types
@@ -1135,7 +1130,7 @@ do -- AI_AIR_DISPATCHER
end
--- @param #AI_AIR_DISPATCHER self
-- @param #AI_AIR_DISPATCHER self
function AI_AIR_DISPATCHER:onafterStart( From, Event, To )
self:GetParent( self ).onafterStart( self, From, Event, To )
@@ -1146,7 +1141,7 @@ do -- AI_AIR_DISPATCHER
for Resource = 1, DefenderSquadron.ResourceCount or 0 do
self:ResourcePark( DefenderSquadron )
end
self:I( "Parked resources for squadron " .. DefenderSquadron.Name )
self:T( "Parked resources for squadron " .. DefenderSquadron.Name )
end
end
@@ -1199,7 +1194,7 @@ do -- AI_AIR_DISPATCHER
end
--- @param #AI_AIR_DISPATCHER self
-- @param #AI_AIR_DISPATCHER self
function AI_AIR_DISPATCHER:ResourcePark( DefenderSquadron )
local TemplateID = math.random( 1, #DefenderSquadron.Spawn )
local Spawn = DefenderSquadron.Spawn[ TemplateID ] -- Core.Spawn#SPAWN
@@ -1216,31 +1211,31 @@ do -- AI_AIR_DISPATCHER
end
--- @param #AI_AIR_DISPATCHER self
-- @param #AI_AIR_DISPATCHER self
-- @param Core.Event#EVENTDATA EventData
function AI_AIR_DISPATCHER:OnEventBaseCaptured( EventData )
local AirbaseName = EventData.PlaceName -- The name of the airbase that was captured.
self:I( "Captured " .. AirbaseName )
self:T( "Captured " .. AirbaseName )
-- Now search for all squadrons located at the airbase, and sanitize them.
for SquadronName, Squadron in pairs( self.DefenderSquadrons ) do
if Squadron.AirbaseName == AirbaseName then
Squadron.ResourceCount = -999 -- The base has been captured, and the resources are eliminated. No more spawning.
Squadron.Captured = true
self:I( "Squadron " .. SquadronName .. " captured." )
self:T( "Squadron " .. SquadronName .. " captured." )
end
end
end
--- @param #AI_AIR_DISPATCHER self
-- @param #AI_AIR_DISPATCHER self
-- @param Core.Event#EVENTDATA EventData
function AI_AIR_DISPATCHER:OnEventCrashOrDead( EventData )
self.Detection:ForgetDetectedUnit( EventData.IniUnitName )
end
--- @param #AI_AIR_DISPATCHER self
-- @param #AI_AIR_DISPATCHER self
-- @param Core.Event#EVENTDATA EventData
function AI_AIR_DISPATCHER:OnEventLand( EventData )
self:F( "Landed" )
@@ -1257,7 +1252,7 @@ do -- AI_AIR_DISPATCHER
self:RemoveDefenderFromSquadron( Squadron, Defender )
end
DefenderUnit:Destroy()
self:ResourcePark( Squadron, Defender )
self:ResourcePark( Squadron )
return
end
if DefenderUnit:GetLife() ~= DefenderUnit:GetLife0() then
@@ -1268,7 +1263,7 @@ do -- AI_AIR_DISPATCHER
end
end
--- @param #AI_AIR_DISPATCHER self
-- @param #AI_AIR_DISPATCHER self
-- @param Core.Event#EVENTDATA EventData
function AI_AIR_DISPATCHER:OnEventEngineShutdown( EventData )
local DefenderUnit = EventData.IniUnit
@@ -1284,31 +1279,31 @@ do -- AI_AIR_DISPATCHER
self:RemoveDefenderFromSquadron( Squadron, Defender )
end
DefenderUnit:Destroy()
self:ResourcePark( Squadron, Defender )
self:ResourcePark( Squadron )
end
end
end
do -- Manage the defensive behaviour
--- @param #AI_AIR_DISPATCHER self
-- @param #AI_AIR_DISPATCHER self
-- @param #string DefenseCoordinateName The name of the coordinate to be defended by AIR defenses.
-- @param Core.Point#COORDINATE DefenseCoordinate The coordinate to be defended by AIR defenses.
function AI_AIR_DISPATCHER:AddDefenseCoordinate( DefenseCoordinateName, DefenseCoordinate )
self.DefenseCoordinates[DefenseCoordinateName] = DefenseCoordinate
end
--- @param #AI_AIR_DISPATCHER self
-- @param #AI_AIR_DISPATCHER self
function AI_AIR_DISPATCHER:SetDefenseReactivityLow()
self.DefenseReactivity = 0.05
end
--- @param #AI_AIR_DISPATCHER self
-- @param #AI_AIR_DISPATCHER self
function AI_AIR_DISPATCHER:SetDefenseReactivityMedium()
self.DefenseReactivity = 0.15
end
--- @param #AI_AIR_DISPATCHER self
-- @param #AI_AIR_DISPATCHER self
function AI_AIR_DISPATCHER:SetDefenseReactivityHigh()
self.DefenseReactivity = 0.5
end
@@ -1872,7 +1867,7 @@ do -- AI_AIR_DISPATCHER
end
--- @param #AI_AIR_DISPATCHER self
-- @param #AI_AIR_DISPATCHER self
-- @param #string SquadronName The squadron name.
-- @param #number TakeoffInterval Only Takeoff new units each specified interval in seconds in 10 seconds steps.
-- @usage
@@ -2774,7 +2769,7 @@ do -- AI_AIR_DISPATCHER
-- TODO: Need to model the resources in a squadron.
--- @param #AI_AIR_DISPATCHER self
-- @param #AI_AIR_DISPATCHER self
-- @param AI.AI_Air_Squadron#AI_AIR_SQUADRON Squadron
function AI_AIR_DISPATCHER:AddDefenderToSquadron( Squadron, Defender, Size )
self.Defenders = self.Defenders or {}
@@ -2787,7 +2782,7 @@ do -- AI_AIR_DISPATCHER
self:F( { DefenderName = DefenderName, SquadronResourceCount = Squadron.ResourceCount } )
end
--- @param #AI_AIR_DISPATCHER self
-- @param #AI_AIR_DISPATCHER self
-- @param AI.AI_Air_Squadron#AI_AIR_SQUADRON Squadron
function AI_AIR_DISPATCHER:RemoveDefenderFromSquadron( Squadron, Defender )
self.Defenders = self.Defenders or {}
@@ -2800,7 +2795,7 @@ do -- AI_AIR_DISPATCHER
self:F( { DefenderName = DefenderName, SquadronResourceCount = SquadronResourceCount } )
end
--- @param #AI_AIR_DISPATCHER self
-- @param #AI_AIR_DISPATCHER self
-- @param Wrapper.Group#GROUP Defender
-- @return AI.AI_Air_Squadron#AI_AIR_SQUADRON The Squadron.
function AI_AIR_DISPATCHER:GetSquadronFromDefender( Defender )

View File

@@ -13,62 +13,46 @@
--- @type AI_AIR_ENGAGE
-- @type AI_AIR_ENGAGE
-- @extends AI.AI_AIR#AI_AIR
--- Implements the core functions to intercept intruders. Use the Engage trigger to intercept intruders.
--
-- ![Process](..\Presentations\AI_GCI\Dia3.JPG)
--
-- The AI_AIR_ENGAGE is assigned a @{Wrapper.Group} and this must be done before the AI_AIR_ENGAGE process can be started using the **Start** event.
--
-- ![Process](..\Presentations\AI_GCI\Dia4.JPG)
--
-- The AI will fly towards the random 3D point within the patrol zone, using a random speed within the given altitude and speed limits.
-- Upon arrival at the 3D point, a new random 3D point will be selected within the patrol zone using the given limits.
--
-- ![Process](..\Presentations\AI_GCI\Dia5.JPG)
--
-- This cycle will continue.
--
-- ![Process](..\Presentations\AI_GCI\Dia6.JPG)
--
-- During the patrol, the AI will detect enemy targets, which are reported through the **Detected** event.
--
-- ![Process](..\Presentations\AI_GCI\Dia9.JPG)
--
-- When enemies are detected, the AI will automatically engage the enemy.
--
-- ![Process](..\Presentations\AI_GCI\Dia10.JPG)
--
-- Until a fuel or damage threshold has been reached by the AI, or when the AI is commanded to RTB.
-- When the fuel threshold has been reached, the airplane will fly towards the nearest friendly airbase and will land.
--
-- ![Process](..\Presentations\AI_GCI\Dia13.JPG)
--
-- ## 1. AI_AIR_ENGAGE constructor
--
-- * @{#AI_AIR_ENGAGE.New}(): Creates a new AI_AIR_ENGAGE object.
--
-- ## 3. Set the Range of Engagement
--
-- ![Range](..\Presentations\AI_GCI\Dia11.JPG)
--
-- An optional range can be set in meters,
-- that will define when the AI will engage with the detected airborne enemy targets.
-- The range can be beyond or smaller than the range of the Patrol Zone.
-- The range is applied at the position of the AI.
-- Use the method @{AI.AI_GCI#AI_AIR_ENGAGE.SetEngageRange}() to define that range.
-- ## 2. Set the Zone of Engagement
--
-- ## 4. Set the Zone of Engagement
--
-- ![Zone](..\Presentations\AI_GCI\Dia12.JPG)
--
-- An optional @{Core.Zone} can be set,
-- An optional @{Core.Zone} can be set,
-- that will define when the AI will engage with the detected airborne enemy targets.
-- Use the method @{AI.AI_CAP#AI_AIR_ENGAGE.SetEngageZone}() to define that Zone.
--
--
-- # Developer Note
--
-- Note while this class still works, it is no longer supported as the original author stopped active development of MOOSE
-- Therefore, this class is considered to be deprecated
--
-- # Developer Note
--
-- Note while this class still works, it is no longer supported as the original author stopped active development of MOOSE
-- Therefore, this class is considered to be deprecated
--
-- ===
--
-- @field #AI_AIR_ENGAGE
@@ -367,7 +351,7 @@ function AI_AIR_ENGAGE:onafterAbort( AIGroup, From, Event, To )
end
--- @param #AI_AIR_ENGAGE self
-- @param #AI_AIR_ENGAGE self
-- @param Wrapper.Group#GROUP AIGroup The Group Object managed by the FSM.
-- @param #string From The From State string.
-- @param #string Event The Event string.
@@ -377,7 +361,7 @@ function AI_AIR_ENGAGE:onafterAccomplish( AIGroup, From, Event, To )
--self:SetDetectionOff()
end
--- @param #AI_AIR_ENGAGE self
-- @param #AI_AIR_ENGAGE self
-- @param Wrapper.Group#GROUP AIGroup The Group Object managed by the FSM.
-- @param #string From The From State string.
-- @param #string Event The Event string.
@@ -390,7 +374,7 @@ function AI_AIR_ENGAGE:onafterDestroy( AIGroup, From, Event, To, EventData )
end
end
--- @param #AI_AIR_ENGAGE self
-- @param #AI_AIR_ENGAGE self
-- @param Core.Event#EVENTDATA EventData
function AI_AIR_ENGAGE:OnEventDead( EventData )
self:F( { "EventDead", EventData } )
@@ -403,9 +387,9 @@ function AI_AIR_ENGAGE:OnEventDead( EventData )
end
--- @param Wrapper.Group#GROUP AIControllable
-- @param Wrapper.Group#GROUP AIControllable
function AI_AIR_ENGAGE.___EngageRoute( AIGroup, Fsm, AttackSetUnit )
Fsm:I(string.format("AI_AIR_ENGAGE.___EngageRoute: %s", tostring(AIGroup:GetName())))
Fsm:T(string.format("AI_AIR_ENGAGE.___EngageRoute: %s", tostring(AIGroup:GetName())))
if AIGroup and AIGroup:IsAlive() then
Fsm:__EngageRoute( Fsm.TaskDelay or 0.1, AttackSetUnit )
@@ -413,14 +397,14 @@ function AI_AIR_ENGAGE.___EngageRoute( AIGroup, Fsm, AttackSetUnit )
end
--- @param #AI_AIR_ENGAGE self
-- @param #AI_AIR_ENGAGE self
-- @param Wrapper.Group#GROUP DefenderGroup The GroupGroup managed by the FSM.
-- @param #string From The From State string.
-- @param #string Event The Event string.
-- @param #string To The To State string.
-- @param Core.Set#SET_UNIT AttackSetUnit Unit set to be attacked.
function AI_AIR_ENGAGE:onafterEngageRoute( DefenderGroup, From, Event, To, AttackSetUnit )
self:I( { DefenderGroup, From, Event, To, AttackSetUnit } )
self:T( { DefenderGroup, From, Event, To, AttackSetUnit } )
local DefenderGroupName = DefenderGroup:GetName()
@@ -442,7 +426,13 @@ function AI_AIR_ENGAGE:onafterEngageRoute( DefenderGroup, From, Event, To, Attac
local DefenderCoord = DefenderGroup:GetPointVec3()
DefenderCoord:SetY( EngageAltitude ) -- Ground targets don't have an altitude.
local TargetCoord = AttackSetUnit:GetFirst():GetPointVec3()
local TargetCoord = AttackSetUnit:GetRandomSurely():GetPointVec3()
if TargetCoord == nil then
self:Return()
return
end
TargetCoord:SetY( EngageAltitude ) -- Ground targets don't have an altitude.
local TargetDistance = DefenderCoord:Get2DDistance( TargetCoord )
@@ -451,12 +441,12 @@ function AI_AIR_ENGAGE:onafterEngageRoute( DefenderGroup, From, Event, To, Attac
-- TODO: A factor of * 3 is way too close. This causes the AI not to engange until merged sometimes!
if TargetDistance <= EngageDistance * 9 then
self:I(string.format("AI_AIR_ENGAGE onafterEngageRoute ==> __Engage - target distance = %.1f km", TargetDistance/1000))
--self:T(string.format("AI_AIR_ENGAGE onafterEngageRoute ==> __Engage - target distance = %.1f km", TargetDistance/1000))
self:__Engage( 0.1, AttackSetUnit )
else
self:I(string.format("FF AI_AIR_ENGAGE onafterEngageRoute ==> Routing - target distance = %.1f km", TargetDistance/1000))
--self:T(string.format("FF AI_AIR_ENGAGE onafterEngageRoute ==> Routing - target distance = %.1f km", TargetDistance/1000))
local EngageRoute = {}
local AttackTasks = {}
@@ -488,16 +478,16 @@ function AI_AIR_ENGAGE:onafterEngageRoute( DefenderGroup, From, Event, To, Attac
end
else
-- TODO: This will make an A2A Dispatcher CAP flight to return rather than going back to patrolling!
self:I( DefenderGroupName .. ": No targets found -> Going RTB")
self:T( DefenderGroupName .. ": No targets found -> Going RTB")
self:Return()
end
end
--- @param Wrapper.Group#GROUP AIControllable
-- @param Wrapper.Group#GROUP AIControllable
function AI_AIR_ENGAGE.___Engage( AIGroup, Fsm, AttackSetUnit )
Fsm:I(string.format("AI_AIR_ENGAGE.___Engage: %s", tostring(AIGroup:GetName())))
Fsm:T(string.format("AI_AIR_ENGAGE.___Engage: %s", tostring(AIGroup:GetName())))
if AIGroup and AIGroup:IsAlive() then
local delay=Fsm.TaskDelay or 0.1
@@ -506,7 +496,7 @@ function AI_AIR_ENGAGE.___Engage( AIGroup, Fsm, AttackSetUnit )
end
--- @param #AI_AIR_ENGAGE self
-- @param #AI_AIR_ENGAGE self
-- @param Wrapper.Group#GROUP DefenderGroup The GroupGroup managed by the FSM.
-- @param #string From The From State string.
-- @param #string Event The Event string.
@@ -532,7 +522,7 @@ function AI_AIR_ENGAGE:onafterEngage( DefenderGroup, From, Event, To, AttackSetU
local DefenderCoord = DefenderGroup:GetPointVec3()
DefenderCoord:SetY( EngageAltitude ) -- Ground targets don't have an altitude.
local TargetCoord = AttackSetUnit:GetFirst():GetPointVec3()
local TargetCoord = AttackSetUnit:GetRandomSurely():GetPointVec3()
if not TargetCoord then
self:Return()
return
@@ -563,12 +553,12 @@ function AI_AIR_ENGAGE:onafterEngage( DefenderGroup, From, Event, To, AttackSetU
local AttackUnitTasks = self:CreateAttackUnitTasks( AttackSetUnit, DefenderGroup, EngageAltitude ) -- Polymorphic
if #AttackUnitTasks == 0 then
self:I( DefenderGroupName .. ": No valid targets found -> Going RTB")
self:T( DefenderGroupName .. ": No valid targets found -> Going RTB")
self:Return()
return
else
local text=string.format("%s: Engaging targets at distance %.2f NM", DefenderGroupName, UTILS.MetersToNM(TargetDistance))
self:I(text)
self:T(text)
DefenderGroup:OptionROEOpenFire()
DefenderGroup:OptionROTEvadeFire()
DefenderGroup:OptionKeepWeaponsOnThreat()
@@ -585,13 +575,13 @@ function AI_AIR_ENGAGE:onafterEngage( DefenderGroup, From, Event, To, AttackSetU
end
else
-- TODO: This will make an A2A Dispatcher CAP flight to return rather than going back to patrolling!
self:I( DefenderGroupName .. ": No targets found -> returning.")
self:T( DefenderGroupName .. ": No targets found -> returning.")
self:Return()
return
end
end
--- @param Wrapper.Group#GROUP AIEngage
-- @param Wrapper.Group#GROUP AIEngage
function AI_AIR_ENGAGE.Resume( AIEngage, Fsm )
AIEngage:F( { "Resume:", AIEngage:GetName() } )

View File

@@ -79,16 +79,13 @@
-- that will define when the AI will engage with the detected airborne enemy targets.
-- The range can be beyond or smaller than the range of the Patrol Zone.
-- The range is applied at the position of the AI.
-- Use the method @{AI.AI_CAP#AI_AIR_PATROL.SetEngageRange}() to define that range.
-- Use the method @{#AI_AIR_PATROL.SetEngageRange}() to define that range.
--
-- ## 4. Set the Zone of Engagement
-- # Developer Note
--
-- ![Zone](..\Presentations\AI_CAP\Dia12.JPG)
--
-- An optional @{Core.Zone} can be set,
-- that will define when the AI will engage with the detected airborne enemy targets.
-- Use the method @{AI.AI_CAP#AI_AIR_PATROL.SetEngageZone}() to define that Zone.
--
-- Note while this class still works, it is no longer supported as the original author stopped active development of MOOSE
-- Therefore, this class is considered to be deprecated
--
-- ===
--
-- @field #AI_AIR_PATROL

View File

@@ -13,12 +13,17 @@
--- @type AI_AIR_SQUADRON
-- @type AI_AIR_SQUADRON
-- @extends Core.Base#BASE
--- Implements the core functions modeling squadrons for airplanes and helicopters.
--
-- # Developer Note
--
-- Note while this class still works, it is no longer supported as the original author stopped active development of MOOSE
-- Therefore, this class is considered to be deprecated
--
-- ===
--
-- @field #AI_AIR_SQUADRON
@@ -33,7 +38,7 @@ AI_AIR_SQUADRON = {
-- @return #AI_AIR_SQUADRON
function AI_AIR_SQUADRON:New( SquadronName, AirbaseName, TemplatePrefixes, ResourceCount )
self:I( { Air_Squadron = { SquadronName, AirbaseName, TemplatePrefixes, ResourceCount } } )
self:T( { Air_Squadron = { SquadronName, AirbaseName, TemplatePrefixes, ResourceCount } } )
local AI_Air_Squadron = BASE:New() -- #AI_AIR_SQUADRON

View File

@@ -11,7 +11,7 @@
--
-- ===
--
-- ### [Demo Missions](https://github.com/FlightControl-Master/MOOSE_MISSIONS/tree/master/BAI%20-%20Battlefield%20Air%20Interdiction)
-- ### [Demo Missions](https://github.com/FlightControl-Master/MOOSE_MISSIONS/tree/master/AI/AI_BAI)
--
-- ===
--
@@ -22,7 +22,7 @@
-- ### Author: **FlightControl**
-- ### Contributions:
--
-- * **[Gunterlund](http://forums.eagle.ru:8080/member.php?u=75036)**: Test case revision.
-- * **Gunterlund**: Test case revision.
--
-- ===
--
@@ -130,7 +130,12 @@
-- AIBAIZone:SearchOff()
--
-- Searching can be switched back on with the method @{#AI_BAI_ZONE.SearchOn}(). Use the method @{#AI_BAI_ZONE.SearchOnOff}() to flexibily switch searching on or off.
--
-- # Developer Note
--
-- Note while this class still works, it is no longer supported as the original author stopped active development of MOOSE
-- Therefore, this class is considered to be deprecated
--
-- ===
--
-- @field #AI_BAI_ZONE

View File

@@ -9,7 +9,7 @@
--
-- ===
--
-- ### [Demo Missions](https://github.com/FlightControl-Master/MOOSE_MISSIONS/tree/master/AIB%20-%20AI%20Balancing)
-- ### [Demo Missions](https://github.com/FlightControl-Master/MOOSE_MISSIONS/tree/master/AI/AI_Balancer)
--
-- ===
--
@@ -20,7 +20,7 @@
-- ### Author: **FlightControl**
-- ### Contributions:
--
-- * **[Dutch_Baron](https://forums.eagle.ru/member.php?u=112075)**: Working together with James has resulted in the creation of the AI_BALANCER class. James has shared his ideas on balancing AI with air units, and together we made a first design which you can use now :-)
-- * **Dutch_Baron**: Working together with James has resulted in the creation of the AI_BALANCER class. James has shared his ideas on balancing AI with air units, and together we made a first design which you can use now :-)
--
-- ===
--
@@ -40,7 +40,7 @@
--
-- The parent class @{Core.Fsm#FSM_SET} manages the functionality to control the Finite State Machine (FSM).
-- The mission designer can tailor the behaviour of the AI_BALANCER, by defining event and state transition methods.
-- An explanation about state and event transition methods can be found in the @{FSM} module documentation.
-- An explanation about state and event transition methods can be found in the @{Core.Fsm} module documentation.
--
-- The mission designer can tailor the AI_BALANCER behaviour, by implementing a state or event handling method for the following:
--
@@ -52,7 +52,7 @@
--
-- ## 2. AI_BALANCER is a FSM
--
-- ![Process](..\Presentations\AI_Balancer\Dia13.JPG)
-- ![Process](..\Presentations\AI_BALANCER\Dia13.JPG)
--
-- ### 2.1. AI_BALANCER States
--
@@ -85,7 +85,12 @@
--
-- Note that when AI returns to an airbase, the AI_BALANCER will trigger the **Return** event and the AI will return,
-- otherwise the AI_BALANCER will trigger a **Destroy** event, and the AI will be destroyed.
--
-- # Developer Note
--
-- Note while this class still works, it is no longer supported as the original author stopped active development of MOOSE
-- Therefore, this class is considered to be deprecated
--
-- @field #AI_BALANCER
AI_BALANCER = {
ClassName = "AI_BALANCER",
@@ -163,7 +168,8 @@ function AI_BALANCER:ReturnToHomeAirbase( ReturnThresholdRange )
self.ReturnThresholdRange = ReturnThresholdRange
end
--- @param #AI_BALANCER self
--- AI_BALANCER:onenterSpawning
-- @param #AI_BALANCER self
-- @param Core.Set#SET_GROUP SetGroup
-- @param #string ClientName
-- @param Wrapper.Group#GROUP AIGroup
@@ -185,7 +191,8 @@ function AI_BALANCER:onenterSpawning( SetGroup, From, Event, To, ClientName )
end
end
--- @param #AI_BALANCER self
--- AI_BALANCER:onenterDestroying
-- @param #AI_BALANCER self
-- @param Core.Set#SET_GROUP SetGroup
-- @param Wrapper.Group#GROUP AIGroup
function AI_BALANCER:onenterDestroying( SetGroup, From, Event, To, ClientName, AIGroup )
@@ -228,15 +235,16 @@ function AI_BALANCER:onenterReturning( SetGroup, From, Event, To, AIGroup )
end
--- @param #AI_BALANCER self
--- AI_BALANCER:onenterMonitoring
-- @param #AI_BALANCER self
function AI_BALANCER:onenterMonitoring( SetGroup )
self:T2( { self.SetClient:Count() } )
--self.SetClient:Flush()
self.SetClient:ForEachClient(
--- @param Wrapper.Client#CLIENT Client
--- SetClient:ForEachClient
-- @param Wrapper.Client#CLIENT Client
function( Client )
self:T3(Client.ClientName)
@@ -259,7 +267,8 @@ function AI_BALANCER:onenterMonitoring( SetGroup )
self:T2( RangeZone )
_DATABASE:ForEachPlayerUnit(
--- @param Wrapper.Unit#UNIT RangeTestUnit
--- Nameless function
-- @param Wrapper.Unit#UNIT RangeTestUnit
function( RangeTestUnit, RangeZone, AIGroup, PlayerInRange )
self:T2( { PlayerInRange, RangeTestUnit.UnitName, RangeZone.ZoneName } )
if RangeTestUnit:IsInZone( RangeZone ) == true then
@@ -271,7 +280,8 @@ function AI_BALANCER:onenterMonitoring( SetGroup )
end
end,
--- @param Core.Zone#ZONE_RADIUS RangeZone
--- Nameless function
-- @param Core.Zone#ZONE_RADIUS RangeZone
-- @param Wrapper.Group#GROUP AIGroup
function( RangeZone, AIGroup, PlayerInRange )
if PlayerInRange.Value == false then
@@ -302,6 +312,3 @@ function AI_BALANCER:onenterMonitoring( SetGroup )
self:__Monitor( 10 )
end

View File

@@ -9,7 +9,7 @@
--
-- ===
--
-- ### [Demo Missions](https://github.com/FlightControl-Master/MOOSE_MISSIONS/tree/master/CAP%20-%20Combat%20Air%20Patrol)
-- ### [Demo Missions](https://github.com/FlightControl-Master/MOOSE_MISSIONS/tree/master/AI/AI_CAP)
--
-- ===
--
@@ -20,11 +20,11 @@
-- ### Author: **FlightControl**
-- ### Contributions:
--
-- * **[Quax](https://forums.eagle.ru/member.php?u=90530)**: Concept, Advice & Testing.
-- * **[Pikey](https://forums.eagle.ru/member.php?u=62835)**: Concept, Advice & Testing.
-- * **[Gunterlund](http://forums.eagle.ru:8080/member.php?u=75036)**: Test case revision.
-- * **[Whisper](http://forums.eagle.ru/member.php?u=3829): Testing.
-- * **[Delta99](https://forums.eagle.ru/member.php?u=125166): Testing.
-- * **Quax**: Concept, Advice & Testing.
-- * **Pikey**: Concept, Advice & Testing.
-- * **Gunterlund**: Test case revision.
-- * **Whisper**: Testing.
-- * **Delta99**: Testing.
--
-- ===
--
@@ -112,7 +112,12 @@
-- An optional @{Core.Zone} can be set,
-- that will define when the AI will engage with the detected airborne enemy targets.
-- Use the method @{#AI_CAP_ZONE.SetEngageZone}() to define that Zone.
--
--
-- # Developer Note
--
-- Note while this class still works, it is no longer supported as the original author stopped active development of MOOSE
-- Therefore, this class is considered to be deprecated
--
-- ===
--
-- @field #AI_CAP_ZONE

View File

@@ -11,7 +11,7 @@
--
-- ===
--
-- ### [Demo Missions](https://github.com/FlightControl-Master/MOOSE_MISSIONS/tree/master/CAS%20-%20Close%20Air%20Support)
-- ### [Demo Missions](https://github.com/FlightControl-Master/MOOSE_MISSIONS/tree/master/AI/AI_CAS)
--
-- ===
--
@@ -22,9 +22,9 @@
-- ### Author: **FlightControl**
-- ### Contributions:
--
-- * **[Quax](https://forums.eagle.ru/member.php?u=90530)**: Concept, Advice & Testing.
-- * **[Pikey](https://forums.eagle.ru/member.php?u=62835)**: Concept, Advice & Testing.
-- * **[Gunterlund](http://forums.eagle.ru:8080/member.php?u=75036)**: Test case revision.
-- * **Quax**: Concept, Advice & Testing.
-- * **Pikey**: Concept, Advice & Testing.
-- * **Gunterlund**: Test case revision.
--
-- ===
--
@@ -118,7 +118,12 @@
-- * **@{#AI_CAS_ZONE.Destroy}**: The AI has destroyed a target @{Wrapper.Unit}.
-- * **@{#AI_CAS_ZONE.Destroyed}**: The AI has destroyed all target @{Wrapper.Unit}s assigned in the CAS task.
-- * **Status**: The AI is checking status (fuel and damage). When the thresholds have been reached, the AI will RTB.
--
-- # Developer Note
--
-- Note while this class still works, it is no longer supported as the original author stopped active development of MOOSE
-- Therefore, this class is considered to be deprecated
--
-- ===
--
-- @field #AI_CAS_ZONE

View File

@@ -9,7 +9,7 @@
-- @module AI.AI_Cargo
-- @image Cargo.JPG
--- @type AI_CARGO
-- @type AI_CARGO
-- @extends Core.Fsm#FSM_CONTROLLABLE
@@ -25,7 +25,12 @@
-- * @{AI.AI_Cargo_APC} - Cargo transportation using APCs and other vehicles between zones.
-- * @{AI.AI_Cargo_Helicopter} - Cargo transportation using helicopters between zones.
-- * @{AI.AI_Cargo_Airplane} - Cargo transportation using airplanes to and from airbases.
--
--
-- # Developer Note
--
-- Note while this class still works, it is no longer supported as the original author stopped active development of MOOSE
-- Therefore, this class is considered to be deprecated
--
-- @field #AI_CARGO
AI_CARGO = {
ClassName = "AI_CARGO",
@@ -542,7 +547,7 @@ function AI_CARGO:onafterUnloaded( Carrier, From, Event, To, Cargo, CarrierUnit,
for _, CarrierUnit in pairs( Carrier:GetUnits() ) do
local CarrierUnit = CarrierUnit -- Wrapper.Unit#UNIT
local IsEmpty = CarrierUnit:IsCargoEmpty()
self:I({ IsEmpty = IsEmpty })
self:T({ IsEmpty = IsEmpty })
if not IsEmpty then
AllUnloaded = false
break

View File

@@ -75,7 +75,12 @@
-- Using the @{#AI_CARGO_APC.Pickup}() method, you are able to direct the APCs towards a point on the battlefield to board/load the cargo at the specific coordinate.
-- The APCs will follow nearby roads as much as possible, to ensure fast and clean cargo transportation between the objects and villages in the simulation environment.
--
--
-- # Developer Note
--
-- Note while this class still works, it is no longer supported as the original author stopped active development of MOOSE
-- Therefore, this class is considered to be deprecated
--
--
-- @field #AI_CARGO_APC
AI_CARGO_APC = {

View File

@@ -41,7 +41,12 @@
-- marginal impact on the overall battlefield simulation. Fortunately, the firing strength of infantry is limited, and thus, respacing healthy infantry every
-- time is not so much of an issue ...
--
--
-- # Developer Note
--
-- Note while this class still works, it is no longer supported as the original author stopped active development of MOOSE
-- Therefore, this class is considered to be deprecated
--
-- @field #AI_CARGO_AIRPLANE
AI_CARGO_AIRPLANE = {
ClassName = "AI_CARGO_AIRPLANE",

View File

@@ -18,7 +18,7 @@
--
-- Test missions can be located on the main GITHUB site.
--
-- [FlightControl-Master/MOOSE_MISSIONS/AID - AI Dispatching/AID-CGO - AI Cargo Dispatching/](https://github.com/FlightControl-Master/MOOSE_MISSIONS/tree/develop/AID%20-%20AI%20Dispatching/AID-CGO%20-%20AI%20Cargo%20Dispatching)
-- [FlightControl-Master/MOOSE_MISSIONS/AID - AI Dispatching/AID-CGO - AI Cargo Dispatching/](https://github.com/FlightControl-Master/MOOSE_MISSIONS/tree/master/AI/AI_Cargo_Dispatcher)
--
-- ===
--
@@ -100,7 +100,12 @@
--
-- Yes, please ensure that the zones are declared using the @{Core.Zone} classes.
-- Possible zones that function at the moment are ZONE, ZONE_GROUP, ZONE_UNIT, ZONE_POLYGON.
--
-- # Developer Note
--
-- Note while this class still works, it is no longer supported as the original author stopped active development of MOOSE
-- Therefore, this class is considered to be deprecated
--
-- ===
--
-- ### Author: **FlightControl**
@@ -111,7 +116,7 @@
-- @image AI_Cargo_Dispatcher.JPG
--- @type AI_CARGO_DISPATCHER
-- @type AI_CARGO_DISPATCHER
-- @field Core.Set#SET_GROUP CarrierSet The set of @{Wrapper.Group#GROUP} objects of carriers that will transport the cargo.
-- @field Core.Set#SET_CARGO CargoSet The set of @{Cargo.Cargo#CARGO} objects, which can be CARGO_GROUP, CARGO_CRATE, CARGO_SLINGLOAD objects.
-- @field Core.Zone#SET_ZONE PickupZoneSet The set of pickup zones, which are used to where the cargo can be picked up by the carriers. If nil, then cargo can be picked up everywhere.
@@ -567,7 +572,7 @@
-- A home zone can be specified to where the Carriers will move when there isn't any cargo left for pickup.
-- Use @{#AI_CARGO_DISPATCHER.SetHomeZone}() to specify the home zone.
--
-- If no home zone is specified, the carriers will wait near the deploy zone for a new pickup command.
-- If no home zone is specified, the carriers will wait near the deploy zone for a new pickup command.
--
-- ===
--
@@ -578,10 +583,12 @@ AI_CARGO_DISPATCHER = {
PickupCargo = {}
}
--- @field #list
--- List of AI_Cargo
-- @field #list
AI_CARGO_DISPATCHER.AI_Cargo = {}
--- @field #list
--- List of PickupCargo
-- @field #list
AI_CARGO_DISPATCHER.PickupCargo = {}
@@ -1154,7 +1161,7 @@ function AI_CARGO_DISPATCHER:onafterMonitor()
else
local text=string.format("WARNING: Cargo %s is too heavy to be loaded into transport. Cargo weight %.1f > %.1f load capacity of carrier %s.",
tostring(Cargo:GetName()), Cargo:GetWeight(), LargestLoadCapacity, tostring(Carrier:GetName()))
self:I(text)
self:T(text)
end
end
end

View File

@@ -137,7 +137,12 @@
-- Use @{#AI_CARGO_DISPATCHER_APC.SetHomeZone}() to specify the home zone.
--
-- If no home zone is specified, the APCs will wait near the deploy zone for a new pickup command.
--
-- # Developer Note
--
-- Note while this class still works, it is no longer supported as the original author stopped active development of MOOSE
-- Therefore, this class is considered to be deprecated
--
-- ===
--
-- @field #AI_CARGO_DISPATCHER_APC

View File

@@ -108,7 +108,12 @@
--
-- **There are a lot of templates available that allows you to quickly setup an event handler for a specific event type!**
--
--
-- # Developer Note
--
-- Note while this class still works, it is no longer supported as the original author stopped active development of MOOSE
-- Therefore, this class is considered to be deprecated
--
--
-- @field #AI_CARGO_DISPATCHER_AIRPLANE
AI_CARGO_DISPATCHER_AIRPLANE = {

View File

@@ -140,7 +140,12 @@
-- Use @{#AI_CARGO_DISPATCHER_HELICOPTER.SetHomeZone}() to specify the home zone.
--
-- If no home zone is specified, the helicopters will wait near the deploy zone for a new pickup command.
--
-- # Developer Note
--
-- Note while this class still works, it is no longer supported as the original author stopped active development of MOOSE
-- Therefore, this class is considered to be deprecated
--
-- ===
--
-- @field #AI_CARGO_DISPATCHER_HELICOPTER

View File

@@ -130,7 +130,12 @@
-- Use @{#AI_CARGO_DISPATCHER_SHIP.SetHomeZone}() to specify the home zone.
--
-- If no home zone is specified, the Ship will wait near the deploy zone for a new pickup command.
--
-- # Developer Note
--
-- Note while this class still works, it is no longer supported as the original author stopped active development of MOOSE
-- Therefore, this class is considered to be deprecated
--
-- ===
--
-- @field #AI_CARGO_DISPATCHER_SHIP

View File

@@ -41,7 +41,12 @@
-- marginal impact on the overall battlefield simulation. Fortunately, the firing strength of infantry is limited, and thus, respacing healthy infantry every
-- time is not so much of an issue ...
--
--
-- # Developer Note
--
-- Note while this class still works, it is no longer supported as the original author stopped active development of MOOSE
-- Therefore, this class is considered to be deprecated
--
-- ===
--
-- @field #AI_CARGO_HELICOPTER

View File

@@ -55,6 +55,11 @@
-- coordinate. The Ship will follow the Shipping Lane to ensure consistent cargo transportation within the simulation environment.
--
--
-- # Developer Note
--
-- Note while this class still works, it is no longer supported as the original author stopped active development of MOOSE
-- Therefore, this class is considered to be deprecated
--
-- @field #AI_CARGO_SHIP
AI_CARGO_SHIP = {
ClassName = "AI_CARGO_SHIP",

View File

@@ -19,7 +19,7 @@
--
-- ## Missions:
--
-- [ESC - Escorting](https://github.com/FlightControl-Master/MOOSE_MISSIONS/tree/master/ESC%20-%20Escorting)
-- [ESC - Escorting](https://github.com/FlightControl-Master/MOOSE_MISSIONS/tree/master/AI/AI_Escort)
--
-- ===
--
@@ -147,8 +147,8 @@
-- @image Escorting.JPG
--- @type AI_ESCORT
---
-- @type AI_ESCORT
-- @extends AI.AI_Formation#AI_FORMATION
@@ -168,10 +168,17 @@
--
-- -- First find the GROUP object and the CLIENT object.
-- local EscortUnit = CLIENT:FindByName( "Unit Name" ) -- The Unit Name is the name of the unit flagged with the skill Client in the mission editor.
-- local EscortGroup = GROUP:FindByName( "Group Name" ) -- The Group Name is the name of the group that will escort the Escort Client.
-- local EscortGroup = SET_GROUP:New():FilterPrefixes("Escort"):FilterOnce() -- The the group name of the escorts contains "Escort".
--
-- -- Now use these 2 objects to construct the new EscortPlanes object.
-- EscortPlanes = AI_ESCORT:New( EscortUnit, EscortGroup, "Desert", "Welcome to the mission. You are escorted by a plane with code name 'Desert', which can be instructed through the F10 radio menu." )
-- EscortPlanes:MenusAirplanes() -- create menus for airplanes
-- EscortPlanes:__Start(2)
--
-- # Developer Note
--
-- Note while this class still works, it is no longer supported as the original author stopped active development of MOOSE
-- Therefore, this class is considered to be deprecated
--
-- @field #AI_ESCORT
AI_ESCORT = {
@@ -189,16 +196,9 @@ AI_ESCORT = {
TaskPoints = {}
}
--- @field Functional.Detection#DETECTION_AREAS
-- @field Functional.Detection#DETECTION_AREAS
AI_ESCORT.Detection = nil
--- MENUPARAM type
-- @type MENUPARAM
-- @field #AI_ESCORT ParamSelf
-- @field #Distance ParamDistance
-- @field #function ParamFunction
-- @field #string ParamMessage
--- AI_ESCORT class constructor for an AI group
-- @param #AI_ESCORT self
-- @param Wrapper.Client#CLIENT EscortUnit The client escorted by the EscortGroup.
@@ -211,10 +211,14 @@ AI_ESCORT.Detection = nil
--
-- -- First find the GROUP object and the CLIENT object.
-- local EscortUnit = CLIENT:FindByName( "Unit Name" ) -- The Unit Name is the name of the unit flagged with the skill Client in the mission editor.
-- local EscortGroup = GROUP:FindByName( "Group Name" ) -- The Group Name is the name of the group that will escort the Escort Client.
-- local EscortGroup = SET_GROUP:New():FilterPrefixes("Escort"):FilterOnce() -- The the group name of the escorts contains "Escort".
--
-- -- Now use these 2 objects to construct the new EscortPlanes object.
-- EscortPlanes = AI_ESCORT:New( EscortUnit, EscortGroup, "Desert", "Welcome to the mission. You are escorted by a plane with code name 'Desert', which can be instructed through the F10 radio menu." )
-- EscortPlanes:MenusAirplanes() -- create menus for airplanes
-- EscortPlanes:__Start(2)
--
--
function AI_ESCORT:New( EscortUnit, EscortGroupSet, EscortName, EscortBriefing )
local self = BASE:Inherit( self, AI_FORMATION:New( EscortUnit, EscortGroupSet, EscortName, EscortBriefing ) ) -- #AI_ESCORT
@@ -227,10 +231,17 @@ function AI_ESCORT:New( EscortUnit, EscortGroupSet, EscortName, EscortBriefing )
self.EscortGroupSet = EscortGroupSet
self.EscortGroupSet:SetSomeIteratorLimit( 8 )
self.EscortBriefing = EscortBriefing
self.Menu = {}
self.Menu.HoldAtEscortPosition = self.Menu.HoldAtEscortPosition or {}
self.Menu.HoldAtLeaderPosition = self.Menu.HoldAtLeaderPosition or {}
self.Menu.Flare = self.Menu.Flare or {}
self.Menu.Smoke = self.Menu.Smoke or {}
self.Menu.Targets = self.Menu.Targets or {}
self.Menu.ROE = self.Menu.ROE or {}
self.Menu.ROT = self.Menu.ROT or {}
-- if not EscortBriefing then
-- EscortGroup:MessageToClient( EscortGroup:GetCategoryName() .. " '" .. EscortName .. "' (" .. EscortGroup:GetCallsign() .. ") reporting! " ..
@@ -250,7 +261,7 @@ function AI_ESCORT:New( EscortUnit, EscortGroupSet, EscortName, EscortBriefing )
EscortGroupSet:ForEachGroup(
--- @param Core.Group#GROUP EscortGroup
-- @param Wrapper.Group#GROUP EscortGroup
function( EscortGroup )
-- Set EscortGroup known at EscortUnit.
if not self.PlayerUnit._EscortGroups then
@@ -325,14 +336,14 @@ function AI_ESCORT:_InitEscortRoute( EscortGroup )
end
--- @param #AI_ESCORT self
-- @param #AI_ESCORT self
-- @param Core.Set#SET_GROUP EscortGroupSet
function AI_ESCORT:onafterStart( EscortGroupSet )
self:F()
EscortGroupSet:ForEachGroup(
--- @param Core.Group#GROUP EscortGroup
-- @param Wrapper.Group#GROUP EscortGroup
function( EscortGroup )
EscortGroup:WayPointInitialize()
@@ -370,7 +381,7 @@ function AI_ESCORT:onafterStart( EscortGroupSet )
self:_InitFlightMenus()
self.EscortGroupSet:ForSomeGroupAlive(
--- @param Core.Group#GROUP EscortGroup
-- @param Wrapper.Group#GROUP EscortGroup
function( EscortGroup )
self:_InitEscortMenus( EscortGroup )
@@ -378,7 +389,7 @@ function AI_ESCORT:onafterStart( EscortGroupSet )
self:SetFlightModeFormation( EscortGroup )
--- @param #AI_ESCORT self
-- @param #AI_ESCORT self
-- @param Core.Event#EVENTDATA EventData
function EscortGroup:OnEventDeadOrCrash( EventData )
self:F( { "EventDead", EventData } )
@@ -394,14 +405,14 @@ function AI_ESCORT:onafterStart( EscortGroupSet )
end
--- @param #AI_ESCORT self
-- @param #AI_ESCORT self
-- @param Core.Set#SET_GROUP EscortGroupSet
function AI_ESCORT:onafterStop( EscortGroupSet )
self:F()
EscortGroupSet:ForEachGroup(
--- @param Core.Group#GROUP EscortGroup
-- @param Wrapper.Group#GROUP EscortGroup
function( EscortGroup )
EscortGroup:WayPointInitialize()
@@ -545,12 +556,12 @@ function AI_ESCORT:SetFlightMenuFormation( Formation )
if MenuFormation then
local Arguments = MenuFormation.Arguments
--self:I({Arguments=unpack(Arguments)})
--self:T({Arguments=unpack(Arguments)})
local FlightMenuFormation = MENU_GROUP:New( self.PlayerGroup, "Formation", self.MainMenu )
local MenuFlightFormationID = MENU_GROUP_COMMAND:New( self.PlayerGroup, Formation, FlightMenuFormation,
function ( self, Formation, ... )
self.EscortGroupSet:ForSomeGroupAlive(
--- @param Core.Group#GROUP EscortGroup
-- @param Wrapper.Group#GROUP EscortGroup
function( EscortGroup, self, Formation, Arguments )
if EscortGroup:IsAir() then
self:E({FormationID=FormationID})
@@ -764,7 +775,7 @@ end
function AI_ESCORT:SetFlightMenuHoldAtEscortPosition()
for _, MenuHoldAtEscortPosition in pairs( self.Menu.HoldAtEscortPosition ) do
for _, MenuHoldAtEscortPosition in pairs( self.Menu.HoldAtEscortPosition or {} ) do
local FlightMenuReportNavigation = MENU_GROUP:New( self.PlayerGroup, "Navigation", self.FlightMenu )
local FlightMenuHoldPosition = MENU_GROUP_COMMAND
@@ -785,7 +796,7 @@ end
function AI_ESCORT:SetEscortMenuHoldAtEscortPosition( EscortGroup )
for _, HoldAtEscortPosition in pairs( self.Menu.HoldAtEscortPosition ) do
for _, HoldAtEscortPosition in pairs( self.Menu.HoldAtEscortPosition or {}) do
if EscortGroup:IsAir() then
local EscortGroupName = EscortGroup:GetName()
local EscortMenuReportNavigation = MENU_GROUP:New( self.PlayerGroup, "Navigation", EscortGroup.EscortMenu )
@@ -853,7 +864,7 @@ end
function AI_ESCORT:SetFlightMenuHoldAtLeaderPosition()
for _, MenuHoldAtLeaderPosition in pairs( self.Menu.HoldAtLeaderPosition ) do
for _, MenuHoldAtLeaderPosition in pairs( self.Menu.HoldAtLeaderPosition or {}) do
local FlightMenuReportNavigation = MENU_GROUP:New( self.PlayerGroup, "Navigation", self.FlightMenu )
local FlightMenuHoldAtLeaderPosition = MENU_GROUP_COMMAND
@@ -874,7 +885,7 @@ end
function AI_ESCORT:SetEscortMenuHoldAtLeaderPosition( EscortGroup )
for _, HoldAtLeaderPosition in pairs( self.Menu.HoldAtLeaderPosition ) do
for _, HoldAtLeaderPosition in pairs( self.Menu.HoldAtLeaderPosition or {}) do
if EscortGroup:IsAir() then
local EscortGroupName = EscortGroup:GetName()
@@ -999,7 +1010,7 @@ end
function AI_ESCORT:SetFlightMenuFlare()
for _, MenuFlare in pairs( self.Menu.Flare) do
for _, MenuFlare in pairs( self.Menu.Flare or {}) do
local FlightMenuReportNavigation = MENU_GROUP:New( self.PlayerGroup, "Navigation", self.FlightMenu )
local FlightMenuFlare = MENU_GROUP:New( self.PlayerGroup, MenuFlare.MenuText, FlightMenuReportNavigation )
@@ -1014,7 +1025,7 @@ end
function AI_ESCORT:SetEscortMenuFlare( EscortGroup )
for _, MenuFlare in pairs( self.Menu.Flare) do
for _, MenuFlare in pairs( self.Menu.Flare or {}) do
if EscortGroup:IsAir() then
local EscortGroupName = EscortGroup:GetName()
@@ -1059,7 +1070,7 @@ end
function AI_ESCORT:SetFlightMenuSmoke()
for _, MenuSmoke in pairs( self.Menu.Smoke) do
for _, MenuSmoke in pairs( self.Menu.Smoke or {}) do
local FlightMenuReportNavigation = MENU_GROUP:New( self.PlayerGroup, "Navigation", self.FlightMenu )
local FlightMenuSmoke = MENU_GROUP:New( self.PlayerGroup, MenuSmoke.MenuText, FlightMenuReportNavigation )
@@ -1076,7 +1087,7 @@ end
function AI_ESCORT:SetEscortMenuSmoke( EscortGroup )
for _, MenuSmoke in pairs( self.Menu.Smoke) do
for _, MenuSmoke in pairs( self.Menu.Smoke or {}) do
if EscortGroup:IsAir() then
local EscortGroupName = EscortGroup:GetName()
@@ -1169,7 +1180,7 @@ function AI_ESCORT:SetFlightMenuTargets()
local FlightMenuAttackNearbyAir = MENU_GROUP_COMMAND:New( self.PlayerGroup, "Attack nearest airborne targets", self.FlightMenuAttack, AI_ESCORT._FlightAttackNearestTarget, self, self.__Enum.ReportType.Air ):SetTag( "Attack" )
local FlightMenuAttackNearbyGround = MENU_GROUP_COMMAND:New( self.PlayerGroup, "Attack nearest ground targets", self.FlightMenuAttack, AI_ESCORT._FlightAttackNearestTarget, self, self.__Enum.ReportType.Ground ):SetTag( "Attack" )
for _, MenuTargets in pairs( self.Menu.Targets) do
for _, MenuTargets in pairs( self.Menu.Targets or {}) do
MenuTargets.FlightReportTargetsScheduler = SCHEDULER:New( self, self._FlightReportTargetsScheduler, {}, MenuTargets.Interval, MenuTargets.Interval )
end
@@ -1179,7 +1190,7 @@ end
function AI_ESCORT:SetEscortMenuTargets( EscortGroup )
for _, MenuTargets in pairs( self.Menu.Targets) do
for _, MenuTargets in pairs( self.Menu.Targets or {} or {}) do
if EscortGroup:IsAir() then
local EscortGroupName = EscortGroup:GetName()
--local EscortMenuReportTargets = MENU_GROUP:New( self.PlayerGroup, "Report targets", EscortGroup.EscortMenu )
@@ -1231,7 +1242,7 @@ function AI_ESCORT:MenuAssistedAttack()
self:F()
self.EscortGroupSet:ForSomeGroupAlive(
--- @param Core.Group#GROUP EscortGroup
-- @param Wrapper.Group#GROUP EscortGroup
function( EscortGroup )
if not EscortGroup:IsAir() then
-- Request assistance from other escorts.
@@ -1246,7 +1257,7 @@ end
function AI_ESCORT:SetFlightMenuROE()
for _, MenuROE in pairs( self.Menu.ROE) do
for _, MenuROE in pairs( self.Menu.ROE or {}) do
local FlightMenuROE = MENU_GROUP:New( self.PlayerGroup, "Rule Of Engagement", self.FlightMenu )
local FlightMenuROEHoldFire = MENU_GROUP_COMMAND:New( self.PlayerGroup, "Hold fire", FlightMenuROE, AI_ESCORT._FlightROEHoldFire, self, "Holding weapons!" )
@@ -1261,7 +1272,7 @@ end
function AI_ESCORT:SetEscortMenuROE( EscortGroup )
for _, MenuROE in pairs( self.Menu.ROE) do
for _, MenuROE in pairs( self.Menu.ROE or {}) do
if EscortGroup:IsAir() then
local EscortGroupName = EscortGroup:GetName()
@@ -1302,7 +1313,7 @@ end
function AI_ESCORT:SetFlightMenuROT()
for _, MenuROT in pairs( self.Menu.ROT) do
for _, MenuROT in pairs( self.Menu.ROT or {}) do
local FlightMenuROT = MENU_GROUP:New( self.PlayerGroup, "Reaction On Threat", self.FlightMenu )
local FlightMenuROTNoReaction = MENU_GROUP_COMMAND:New( self.PlayerGroup, "Fight until death", FlightMenuROT, AI_ESCORT._FlightROTNoReaction, self, "Fighting until death!" )
@@ -1317,7 +1328,7 @@ end
function AI_ESCORT:SetEscortMenuROT( EscortGroup )
for _, MenuROT in pairs( self.Menu.ROT) do
for _, MenuROT in pairs( self.Menu.ROT or {}) do
if EscortGroup:IsAir() then
local EscortGroupName = EscortGroup:GetName()
@@ -1375,7 +1386,7 @@ function AI_ESCORT:SetEscortMenuResumeMission( EscortGroup )
end
--- @param #AI_ESCORT self
-- @param #AI_ESCORT self
-- @param Wrapper.Group#GROUP OrbitGroup
-- @param Wrapper.Group#GROUP EscortGroup
-- @param #number OrbitHeight
@@ -1419,7 +1430,7 @@ function AI_ESCORT:_HoldPosition( OrbitGroup, EscortGroup, OrbitHeight, OrbitSec
end
--- @param #AI_ESCORT self
-- @param #AI_ESCORT self
-- @param Wrapper.Group#GROUP OrbitGroup
-- @param #number OrbitHeight
-- @param #number OrbitSeconds
@@ -1428,7 +1439,7 @@ function AI_ESCORT:_FlightHoldPosition( OrbitGroup, OrbitHeight, OrbitSeconds )
local EscortUnit = self.PlayerUnit
self.EscortGroupSet:ForEachGroupAlive(
--- @param Core.Group#GROUP EscortGroup
-- @param Wrapper.Group#GROUP EscortGroup
function( EscortGroup, OrbitGroup )
if EscortGroup:IsAir() then
if OrbitGroup == nil then
@@ -1456,7 +1467,7 @@ end
function AI_ESCORT:_FlightJoinUp()
self.EscortGroupSet:ForEachGroupAlive(
--- @param Core.Group#GROUP EscortGroup
-- @param Wrapper.Group#GROUP EscortGroup
function( EscortGroup )
if EscortGroup:IsAir() then
self:_JoinUp( EscortGroup )
@@ -1483,7 +1494,7 @@ end
function AI_ESCORT:_FlightFormationTrail( XStart, XSpace, YStart )
self.EscortGroupSet:ForEachGroupAlive(
--- @param Core.Group#GROUP EscortGroup
-- @param Wrapper.Group#GROUP EscortGroup
function( EscortGroup )
if EscortGroup:IsAir() then
self:_EscortFormationTrail( EscortGroup, XStart, XSpace, YStart )
@@ -1510,7 +1521,7 @@ end
function AI_ESCORT:_FlightFormationStack( XStart, XSpace, YStart, YSpace )
self.EscortGroupSet:ForEachGroupAlive(
--- @param Core.Group#GROUP EscortGroup
-- @param Wrapper.Group#GROUP EscortGroup
function( EscortGroup )
if EscortGroup:IsAir() then
self:_EscortFormationStack( EscortGroup, XStart, XSpace, YStart, YSpace )
@@ -1533,7 +1544,7 @@ end
function AI_ESCORT:_FlightFlare( Color, Message )
self.EscortGroupSet:ForEachGroupAlive(
--- @param Core.Group#GROUP EscortGroup
-- @param Wrapper.Group#GROUP EscortGroup
function( EscortGroup )
if EscortGroup:IsAir() then
self:_Flare( EscortGroup, Color, Message )
@@ -1556,7 +1567,7 @@ end
function AI_ESCORT:_FlightSmoke( Color, Message )
self.EscortGroupSet:ForEachGroupAlive(
--- @param Core.Group#GROUP EscortGroup
-- @param Wrapper.Group#GROUP EscortGroup
function( EscortGroup )
if EscortGroup:IsAir() then
self:_Smoke( EscortGroup, Color, Message )
@@ -1587,7 +1598,7 @@ end
function AI_ESCORT:_FlightSwitchReportNearbyTargets( ReportTargets )
self.EscortGroupSet:ForEachGroupAlive(
--- @param Core.Group#GROUP EscortGroup
-- @param Wrapper.Group#GROUP EscortGroup
function( EscortGroup )
if EscortGroup:IsAir() then
self:_EscortSwitchReportNearbyTargets( EscortGroup, ReportTargets )
@@ -1679,7 +1690,7 @@ function AI_ESCORT:_ScanTargets( ScanDuration )
end
--- @param Wrapper.Group#GROUP EscortGroup
-- @param Wrapper.Group#GROUP EscortGroup
-- @param #AI_ESCORT self
function AI_ESCORT.___Resume( EscortGroup, self )
@@ -1701,7 +1712,7 @@ function AI_ESCORT.___Resume( EscortGroup, self )
end
--- @param #AI_ESCORT self
-- @param #AI_ESCORT self
-- @param Wrapper.Group#GROUP EscortGroup
-- @param #number WayPoint
function AI_ESCORT:_ResumeMission( EscortGroup, WayPoint )
@@ -1723,7 +1734,7 @@ function AI_ESCORT:_ResumeMission( EscortGroup, WayPoint )
end
--- @param #AI_ESCORT self
-- @param #AI_ESCORT self
-- @param Wrapper.Group#GROUP EscortGroup The escort group that will attack the detected item.
-- @param Functional.Detection#DETECTION_BASE.DetectedItem DetectedItem
function AI_ESCORT:_AttackTarget( EscortGroup, DetectedItem )
@@ -1743,7 +1754,7 @@ function AI_ESCORT:_AttackTarget( EscortGroup, DetectedItem )
local AttackUnitTasks = {}
DetectedSet:ForEachUnit(
--- @param Wrapper.Unit#UNIT DetectedUnit
-- @param Wrapper.Unit#UNIT DetectedUnit
function( DetectedUnit, Tasks )
if DetectedUnit:IsAlive() then
AttackUnitTasks[#AttackUnitTasks+1] = EscortGroup:TaskAttackUnit( DetectedUnit )
@@ -1767,7 +1778,7 @@ function AI_ESCORT:_AttackTarget( EscortGroup, DetectedItem )
local Tasks = {}
DetectedSet:ForEachUnit(
--- @param Wrapper.Unit#UNIT DetectedUnit
-- @param Wrapper.Unit#UNIT DetectedUnit
function( DetectedUnit, Tasks )
if DetectedUnit:IsAlive() then
Tasks[#Tasks+1] = EscortGroup:TaskFireAtPoint( DetectedUnit:GetVec2(), 50 )
@@ -1795,7 +1806,7 @@ end
function AI_ESCORT:_FlightAttackTarget( DetectedItem )
self.EscortGroupSet:ForEachGroupAlive(
--- @param Core.Group#GROUP EscortGroup
-- @param Wrapper.Group#GROUP EscortGroup
function( EscortGroup, DetectedItem )
if EscortGroup:IsAir() then
self:_AttackTarget( EscortGroup, DetectedItem )
@@ -1842,7 +1853,7 @@ end
---
--- @param #AI_ESCORT self
-- @param #AI_ESCORT self
-- @param Wrapper.Group#GROUP EscortGroup The escort group that will attack the detected item.
-- @param Functional.Detection#DETECTION_BASE.DetectedItem DetectedItem
function AI_ESCORT:_AssistTarget( EscortGroup, DetectedItem )
@@ -1854,7 +1865,7 @@ function AI_ESCORT:_AssistTarget( EscortGroup, DetectedItem )
local Tasks = {}
DetectedSet:ForEachUnit(
--- @param Wrapper.Unit#UNIT DetectedUnit
-- @param Wrapper.Unit#UNIT DetectedUnit
function( DetectedUnit, Tasks )
if DetectedUnit:IsAlive() then
Tasks[#Tasks+1] = EscortGroup:TaskFireAtPoint( DetectedUnit:GetVec2(), 50 )
@@ -1881,7 +1892,7 @@ end
function AI_ESCORT:_FlightROEHoldFire( EscortROEMessage )
self.EscortGroupSet:ForEachGroupAlive(
--- @param Wrapper.Group#GROUP EscortGroup
-- @param Wrapper.Group#GROUP EscortGroup
function( EscortGroup )
self:_ROE( EscortGroup, EscortGroup.OptionROEHoldFire, EscortROEMessage )
end
@@ -1890,7 +1901,7 @@ end
function AI_ESCORT:_FlightROEOpenFire( EscortROEMessage )
self.EscortGroupSet:ForEachGroupAlive(
--- @param Wrapper.Group#GROUP EscortGroup
-- @param Wrapper.Group#GROUP EscortGroup
function( EscortGroup )
self:_ROE( EscortGroup, EscortGroup.OptionROEOpenFire, EscortROEMessage )
end
@@ -1899,7 +1910,7 @@ end
function AI_ESCORT:_FlightROEReturnFire( EscortROEMessage )
self.EscortGroupSet:ForEachGroupAlive(
--- @param Wrapper.Group#GROUP EscortGroup
-- @param Wrapper.Group#GROUP EscortGroup
function( EscortGroup )
self:_ROE( EscortGroup, EscortGroup.OptionROEReturnFire, EscortROEMessage )
end
@@ -1908,7 +1919,7 @@ end
function AI_ESCORT:_FlightROEWeaponFree( EscortROEMessage )
self.EscortGroupSet:ForEachGroupAlive(
--- @param Wrapper.Group#GROUP EscortGroup
-- @param Wrapper.Group#GROUP EscortGroup
function( EscortGroup )
self:_ROE( EscortGroup, EscortGroup.OptionROEWeaponFree, EscortROEMessage )
end
@@ -1924,7 +1935,7 @@ end
function AI_ESCORT:_FlightROTNoReaction( EscortROTMessage )
self.EscortGroupSet:ForEachGroupAlive(
--- @param Wrapper.Group#GROUP EscortGroup
-- @param Wrapper.Group#GROUP EscortGroup
function( EscortGroup )
self:_ROT( EscortGroup, EscortGroup.OptionROTNoReaction, EscortROTMessage )
end
@@ -1933,7 +1944,7 @@ end
function AI_ESCORT:_FlightROTPassiveDefense( EscortROTMessage )
self.EscortGroupSet:ForEachGroupAlive(
--- @param Wrapper.Group#GROUP EscortGroup
-- @param Wrapper.Group#GROUP EscortGroup
function( EscortGroup )
self:_ROT( EscortGroup, EscortGroup.OptionROTPassiveDefense, EscortROTMessage )
end
@@ -1942,7 +1953,7 @@ end
function AI_ESCORT:_FlightROTEvadeFire( EscortROTMessage )
self.EscortGroupSet:ForEachGroupAlive(
--- @param Wrapper.Group#GROUP EscortGroup
-- @param Wrapper.Group#GROUP EscortGroup
function( EscortGroup )
self:_ROT( EscortGroup, EscortGroup.OptionROTEvadeFire, EscortROTMessage )
end
@@ -1951,7 +1962,7 @@ end
function AI_ESCORT:_FlightROTVertical( EscortROTMessage )
self.EscortGroupSet:ForEachGroupAlive(
--- @param Wrapper.Group#GROUP EscortGroup
-- @param Wrapper.Group#GROUP EscortGroup
function( EscortGroup )
self:_ROT( EscortGroup, EscortGroup.OptionROTVertical, EscortROTMessage )
end
@@ -2178,5 +2189,3 @@ function AI_ESCORT:_FlightReportTargetsScheduler()
return false
end

View File

@@ -15,12 +15,17 @@
-- @image MOOSE.JPG
--- @type AI_ESCORT_DISPATCHER
-- @type AI_ESCORT_DISPATCHER
-- @extends Core.Fsm#FSM
--- Models the automatic assignment of AI escorts to player flights.
--
-- # Developer Note
--
-- Note while this class still works, it is no longer supported as the original author stopped active development of MOOSE
-- Therefore, this class is considered to be deprecated
--
-- ===
--
-- @field #AI_ESCORT_DISPATCHER
@@ -28,7 +33,7 @@ AI_ESCORT_DISPATCHER = {
ClassName = "AI_ESCORT_DISPATCHER",
}
--- @field #list
-- @field #list
AI_ESCORT_DISPATCHER.AI_Escorts = {}
@@ -97,7 +102,7 @@ function AI_ESCORT_DISPATCHER:onafterStart( From, Event, To )
end
--- @param #AI_ESCORT_DISPATCHER self
-- @param #AI_ESCORT_DISPATCHER self
-- @param Core.Event#EVENTDATA EventData
function AI_ESCORT_DISPATCHER:OnEventExit( EventData )
@@ -105,11 +110,11 @@ function AI_ESCORT_DISPATCHER:OnEventExit( EventData )
local PlayerGroup = EventData.IniGroup
local PlayerUnit = EventData.IniUnit
self:I({EscortAirbase= self.EscortAirbase } )
self:I({PlayerGroupName = PlayerGroupName } )
self:I({PlayerGroup = PlayerGroup})
self:I({FirstGroup = self.CarrierSet:GetFirst()})
self:I({FindGroup = self.CarrierSet:FindGroup( PlayerGroupName )})
self:T({EscortAirbase= self.EscortAirbase } )
self:T({PlayerGroupName = PlayerGroupName } )
self:T({PlayerGroup = PlayerGroup})
self:T({FirstGroup = self.CarrierSet:GetFirst()})
self:T({FindGroup = self.CarrierSet:FindGroup( PlayerGroupName )})
if self.CarrierSet:FindGroup( PlayerGroupName ) then
if self.AI_Escorts[PlayerGroupName] then
@@ -120,7 +125,7 @@ function AI_ESCORT_DISPATCHER:OnEventExit( EventData )
end
--- @param #AI_ESCORT_DISPATCHER self
-- @param #AI_ESCORT_DISPATCHER self
-- @param Core.Event#EVENTDATA EventData
function AI_ESCORT_DISPATCHER:OnEventBirth( EventData )
@@ -128,17 +133,17 @@ function AI_ESCORT_DISPATCHER:OnEventBirth( EventData )
local PlayerGroup = EventData.IniGroup
local PlayerUnit = EventData.IniUnit
self:I({EscortAirbase= self.EscortAirbase } )
self:I({PlayerGroupName = PlayerGroupName } )
self:I({PlayerGroup = PlayerGroup})
self:I({FirstGroup = self.CarrierSet:GetFirst()})
self:I({FindGroup = self.CarrierSet:FindGroup( PlayerGroupName )})
self:T({EscortAirbase= self.EscortAirbase } )
self:T({PlayerGroupName = PlayerGroupName } )
self:T({PlayerGroup = PlayerGroup})
self:T({FirstGroup = self.CarrierSet:GetFirst()})
self:T({FindGroup = self.CarrierSet:FindGroup( PlayerGroupName )})
if self.CarrierSet:FindGroup( PlayerGroupName ) then
if not self.AI_Escorts[PlayerGroupName] then
local LeaderUnit = PlayerUnit
local EscortGroup = self.EscortSpawn:SpawnAtAirbase( self.EscortAirbase, SPAWN.Takeoff.Hot )
self:I({EscortGroup = EscortGroup})
self:T({EscortGroup = EscortGroup})
self:ScheduleOnce( 1,
function( EscortGroup )

View File

@@ -20,7 +20,12 @@
--- Models the assignment of AI escorts to player flights upon request using the radio menu.
--
-- # Developer Note
--
-- Note while this class still works, it is no longer supported as the original author stopped active development of MOOSE
-- Therefore, this class is considered to be deprecated
--
-- ===
--
-- @field #AI_ESCORT_DISPATCHER_REQUEST

View File

@@ -19,7 +19,7 @@
--
-- ## Missions:
--
-- [ESC - Escorting](https://github.com/FlightControl-Master/MOOSE_MISSIONS/tree/master/ESC%20-%20Escorting)
-- [ESC - Escorting](https://github.com/FlightControl-Master/MOOSE_MISSIONS/tree/master/AI/AI_Escort)
--
-- ===
--
@@ -137,6 +137,11 @@
-- Escort groups can have their own mission. This menu item will allow the escort group to resume their Mission from a given waypoint.
-- Note that this is really fantastic, as you now have the dynamic of taking control of the escort groups, and allowing them to resume their path or mission.
--
-- # Developer Note
--
-- Note while this class still works, it is no longer supported as the original author stopped active development of MOOSE
-- Therefore, this class is considered to be deprecated
--
-- ===
--
-- ### Authors: **FlightControl**
@@ -292,7 +297,7 @@ function AI_ESCORT_REQUEST:onafterStop( EscortGroupSet )
self:F()
EscortGroupSet:ForEachGroup(
--- @param Core.Group#GROUP EscortGroup
--- @param Wrapper.Group#GROUP EscortGroup
function( EscortGroup )
EscortGroup:WayPointInitialize()

View File

@@ -7,13 +7,13 @@
-- * Assign a group leader that will guide the large formation path.
--
-- ===
--
-- ### [Demo Missions](https://github.com/FlightControl-Master/MOOSE_MISSIONS/tree/master/FOR%20-%20Formation)
--
-- ===
--
-- ### [YouTube Playlist](https://www.youtube.com/playlist?list=PL7ZUrU4zZUl0bFIJ9jIdYM22uaWmIN4oz)
--
--
-- ## Additional Material:
--
-- * **Demo Missions:** [GitHub](https://github.com/FlightControl-Master/MOOSE_MISSIONS/tree/master/AI/AI_Formation)
-- * **YouTube videos:** [Playlist](https://www.youtube.com/playlist?list=PL7ZUrU4zZUl0bFIJ9jIdYM22uaWmIN4oz)
-- * **Guides:** None
--
-- ===
--
-- ### Author: **FlightControl**
@@ -31,11 +31,11 @@
-- @field Core.Set#SET_GROUP FollowGroupSet
-- @field #string FollowName
-- @field #AI_FORMATION.MODE FollowMode The mode the escort is in.
-- @field Scheduler#SCHEDULER FollowScheduler The instance of the SCHEDULER class.
-- @field Core.Scheduler#SCHEDULER FollowScheduler The instance of the SCHEDULER class.
-- @field #number FollowDistance The current follow distance.
-- @field #boolean ReportTargets If true, nearby targets are reported.
-- @Field DCSTypes#AI.Option.Air.val.ROE OptionROE Which ROE is set to the FollowGroup.
-- @field DCSTypes#AI.Option.Air.val.REACTION_ON_THREAT OptionReactionOnThreat Which REACTION_ON_THREAT is set to the FollowGroup.
-- @field DCS#AI.Option.Air.val.ROE OptionROE Which ROE is set to the FollowGroup.
-- @field DCS#AI.Option.Air.val.REACTION_ON_THREAT OptionReactionOnThreat Which REACTION_ON_THREAT is set to the FollowGroup.
-- @field #number dtFollow Time step between position updates.
@@ -92,7 +92,12 @@
-- local LargeFormation = AI_FORMATION:New( LeaderUnit, FollowGroupSet, "Center Wing Formation", "Briefing" )
-- LargeFormation:FormationCenterWing( 500, 50, 0, 250, 250 )
-- LargeFormation:__Start( 1 )
--
-- # Developer Note
--
-- Note while this class still works, it is no longer supported as the original author stopped active development of MOOSE
-- Therefore, this class is considered to be deprecated
--
-- @field #AI_FORMATION
AI_FORMATION = {
ClassName = "AI_FORMATION",
@@ -159,15 +164,6 @@ AI_FORMATION.__Enum.ReportType = {
Ground = "G",
}
--- MENUPARAM type
-- @type MENUPARAM
-- @field #AI_FORMATION ParamSelf
-- @field #number ParamDistance
-- @field #function ParamFunction
-- @field #string ParamMessage
--- AI_FORMATION class constructor for an AI group
-- @param #AI_FORMATION self
-- @param Wrapper.Unit#UNIT FollowUnit The UNIT leading the FolllowGroupSet.
@@ -1000,7 +996,7 @@ function AI_FORMATION:SetFlightModeMission( FollowGroup )
FollowGroup:SetState( FollowGroup, "Mode", self.__Enum.Mode.Mission )
else
self.FollowGroupSet:ForSomeGroupAlive(
--- @param Core.Group#GROUP EscortGroup
--- @param Wrapper.Group#GROUP EscortGroup
function( FollowGroup )
FollowGroup:SetState( FollowGroup, "PreviousMode", FollowGroup:GetState( FollowGroup, "Mode" ) )
FollowGroup:SetState( FollowGroup, "Mode", self.__Enum.Mode.Mission )
@@ -1024,7 +1020,7 @@ function AI_FORMATION:SetFlightModeAttack( FollowGroup )
FollowGroup:SetState( FollowGroup, "Mode", self.__Enum.Mode.Attack )
else
self.FollowGroupSet:ForSomeGroupAlive(
--- @param Core.Group#GROUP EscortGroup
--- @param Wrapper.Group#GROUP EscortGroup
function( FollowGroup )
FollowGroup:SetState( FollowGroup, "PreviousMode", FollowGroup:GetState( FollowGroup, "Mode" ) )
FollowGroup:SetState( FollowGroup, "Mode", self.__Enum.Mode.Attack )
@@ -1048,7 +1044,7 @@ function AI_FORMATION:SetFlightModeFormation( FollowGroup )
FollowGroup:SetState( FollowGroup, "Mode", self.__Enum.Mode.Formation )
else
self.FollowGroupSet:ForSomeGroupAlive(
--- @param Core.Group#GROUP EscortGroup
--- @param Wrapper.Group#GROUP EscortGroup
function( FollowGroup )
FollowGroup:SetState( FollowGroup, "PreviousMode", FollowGroup:GetState( FollowGroup, "Mode" ) )
FollowGroup:SetState( FollowGroup, "Mode", self.__Enum.Mode.Formation )

View File

@@ -16,7 +16,7 @@
--
-- ===
--
-- ### [Demo Missions](https://github.com/FlightControl-Master/MOOSE_MISSIONS/tree/master/PAT%20-%20Patrolling)
-- ### [Demo Missions](https://github.com/FlightControl-Master/MOOSE_MISSIONS/tree/master/AI/AI_Patrol)
--
-- ===
--
@@ -27,8 +27,8 @@
-- ### Author: **FlightControl**
-- ### Contributions:
--
-- * **[Dutch_Baron](https://forums.eagle.ru/member.php?u=112075)**: Working together with James has resulted in the creation of the AI_BALANCER class. James has shared his ideas on balancing AI with air units, and together we made a first design which you can use now :-)
-- * **[Pikey](https://forums.eagle.ru/member.php?u=62835)**: Testing and API concept review.
-- * **Dutch_Baron**: Working together with James has resulted in the creation of the AI_BALANCER class. James has shared his ideas on balancing AI with air units, and together we made a first design which you can use now :-)
-- * **Pikey**: Testing and API concept review.
--
-- ===
--
@@ -144,7 +144,12 @@
-- When the AI is damaged, it is required that a new AIControllable is started. However, damage cannon be foreseen early on.
-- Therefore, when the damage threshold is reached, the AI will return immediately to the home base (RTB).
-- Use the method @{#AI_PATROL_ZONE.ManageDamage}() to have this process in place.
--
-- # Developer Note
--
-- Note while this class still works, it is no longer supported as the original author stopped active development of MOOSE
-- Therefore, this class is considered to be deprecated
--
-- ===
--
-- @field #AI_PATROL_ZONE
@@ -647,15 +652,15 @@ function AI_PATROL_ZONE:onafterStart( Controllable, From, Event, To )
end
--- @param #AI_PATROL_ZONE self
--- @param Wrapper.Controllable#CONTROLLABLE Controllable
-- @param #AI_PATROL_ZONE self
-- @param Wrapper.Controllable#CONTROLLABLE Controllable+
function AI_PATROL_ZONE:onbeforeDetect( Controllable, From, Event, To )
return self.DetectOn and self.DetectActivated
end
--- @param #AI_PATROL_ZONE self
--- @param Wrapper.Controllable#CONTROLLABLE Controllable
-- @param #AI_PATROL_ZONE self
-- @param Wrapper.Controllable#CONTROLLABLE Controllable
function AI_PATROL_ZONE:onafterDetect( Controllable, From, Event, To )
local Detected = false
@@ -700,7 +705,7 @@ function AI_PATROL_ZONE:onafterDetect( Controllable, From, Event, To )
end
--- @param Wrapper.Controllable#CONTROLLABLE AIControllable
-- @param Wrapper.Controllable#CONTROLLABLE AIControllable
-- This static method is called from the route path within the last task at the last waypoint of the Controllable.
-- Note that this method is required, as triggers the next route when patrolling for the Controllable.
function AI_PATROL_ZONE:_NewPatrolRoute( AIControllable )
@@ -817,13 +822,13 @@ function AI_PATROL_ZONE:onafterRoute( Controllable, From, Event, To )
end
--- @param #AI_PATROL_ZONE self
-- @param #AI_PATROL_ZONE self
function AI_PATROL_ZONE:onbeforeStatus()
return self.CheckStatus
end
--- @param #AI_PATROL_ZONE self
-- @param #AI_PATROL_ZONE self
function AI_PATROL_ZONE:onafterStatus()
self:F2()
@@ -833,7 +838,7 @@ function AI_PATROL_ZONE:onafterStatus()
local Fuel = self.Controllable:GetFuelMin()
if Fuel < self.PatrolFuelThresholdPercentage then
self:I( self.Controllable:GetName() .. " is out of fuel:" .. Fuel .. ", RTB!" )
self:T( self.Controllable:GetName() .. " is out of fuel:" .. Fuel .. ", RTB!" )
local OldAIControllable = self.Controllable
local OrbitTask = OldAIControllable:TaskOrbitCircle( math.random( self.PatrolFloorAltitude, self.PatrolCeilingAltitude ), self.PatrolMinSpeed )
@@ -847,7 +852,7 @@ function AI_PATROL_ZONE:onafterStatus()
-- TODO: Check GROUP damage function.
local Damage = self.Controllable:GetLife()
if Damage <= self.PatrolDamageThreshold then
self:I( self.Controllable:GetName() .. " is damaged:" .. Damage .. ", RTB!" )
self:T( self.Controllable:GetName() .. " is damaged:" .. Damage .. ", RTB!" )
RTB = true
end
@@ -859,7 +864,7 @@ function AI_PATROL_ZONE:onafterStatus()
end
end
--- @param #AI_PATROL_ZONE self
-- @param #AI_PATROL_ZONE self
function AI_PATROL_ZONE:onafterRTB()
self:F2()
@@ -898,13 +903,13 @@ function AI_PATROL_ZONE:onafterRTB()
end
--- @param #AI_PATROL_ZONE self
-- @param #AI_PATROL_ZONE self
function AI_PATROL_ZONE:onafterDead()
self:SetDetectionOff()
self:SetStatusOff()
end
--- @param #AI_PATROL_ZONE self
-- @param #AI_PATROL_ZONE self
-- @param Core.Event#EVENTDATA EventData
function AI_PATROL_ZONE:OnCrash( EventData )
@@ -915,7 +920,7 @@ function AI_PATROL_ZONE:OnCrash( EventData )
end
end
--- @param #AI_PATROL_ZONE self
-- @param #AI_PATROL_ZONE self
-- @param Core.Event#EVENTDATA EventData
function AI_PATROL_ZONE:OnEjection( EventData )
@@ -924,7 +929,7 @@ function AI_PATROL_ZONE:OnEjection( EventData )
end
end
--- @param #AI_PATROL_ZONE self
-- @param #AI_PATROL_ZONE self
-- @param Core.Event#EVENTDATA EventData
function AI_PATROL_ZONE:OnPilotDead( EventData )

View File

@@ -54,6 +54,11 @@ do -- ACT_ACCOUNT
-- The state transition method needs to start with the name **OnAfter + the name of the state**.
-- These state transition methods need to provide a return value, which is specified at the function description.
--
-- # Developer Note
--
-- Note while this class still works, it is no longer supported as the original author stopped active development of MOOSE
-- Therefore, this class is considered to be deprecated
--
-- @type ACT_ACCOUNT
-- @field Core.Set#SET_UNIT TargetSetUnit
-- @extends Core.Fsm#FSM_PROCESS
@@ -137,7 +142,7 @@ end -- ACT_ACCOUNT
do -- ACT_ACCOUNT_DEADS
--- # @{#ACT_ACCOUNT_DEADS} FSM class, extends @{Core.Fsm.Account#ACT_ACCOUNT}
--- # @{#ACT_ACCOUNT_DEADS} FSM class, extends @{#ACT_ACCOUNT}
--
-- The ACT_ACCOUNT_DEADS class accounts (detects, counts and reports) successful kills of DCS units.
-- The process is given a @{Core.Set} of units that will be tracked upon successful destruction.

View File

@@ -52,9 +52,14 @@
-- The state transition method needs to start with the name **OnAfter + the name of the state**.
-- These state transition methods need to provide a return value, which is specified at the function description.
--
-- # Developer Note
--
-- Note while this class still works, it is no longer supported as the original author stopped active development of MOOSE
-- Therefore, this class is considered to be deprecated
--
-- ===
--
-- # 1) @{#ACT_ASSIGN_ACCEPT} class, extends @{Core.Fsm.Assign#ACT_ASSIGN}
-- # 1) @{#ACT_ASSIGN_ACCEPT} class, extends @{Core.Fsm#ACT_ASSIGN}
--
-- The ACT_ASSIGN_ACCEPT class accepts by default a task for a player. No player intervention is allowed to reject the task.
--
@@ -64,7 +69,7 @@
--
-- ===
--
-- # 2) @{#ACT_ASSIGN_MENU_ACCEPT} class, extends @{Core.Fsm.Assign#ACT_ASSIGN}
-- # 2) @{#ACT_ASSIGN_MENU_ACCEPT} class, extends @{Core.Fsm#ACT_ASSIGN}
--
-- The ACT_ASSIGN_MENU_ACCEPT class accepts a task when the player accepts the task through an added menu option.
-- This assignment type is useful to conditionally allow the player to choose whether or not he would accept the task.

View File

@@ -48,7 +48,7 @@
--
-- ===
--
-- # 1) @{#ACT_ASSIST_SMOKE_TARGETS_ZONE} class, extends @{Core.Fsm.Route#ACT_ASSIST}
-- # 1) @{#ACT_ASSIST_SMOKE_TARGETS_ZONE} class, extends @{#ACT_ASSIST}
--
-- The ACT_ASSIST_SMOKE_TARGETS_ZONE class implements the core functions to smoke targets in a @{Core.Zone}.
-- The targets are smoked within a certain range around each target, simulating a realistic smoking behaviour.
@@ -58,6 +58,11 @@
--
-- * @{#ACT_ASSIST_SMOKE_TARGETS_ZONE.New}(): Creates a new ACT_ASSIST_SMOKE_TARGETS_ZONE object.
--
-- # Developer Note
--
-- Note while this class still works, it is no longer supported as the original author stopped active development of MOOSE
-- Therefore, this class is considered to be deprecated
--
-- ===
--
-- @module Actions.Act_Assist

View File

@@ -60,7 +60,7 @@
--
-- ===
--
-- # 1) @{#ACT_ROUTE_ZONE} class, extends @{Core.Fsm.Route#ACT_ROUTE}
-- # 1) @{#ACT_ROUTE_ZONE} class, extends @{#ACT_ROUTE}
--
-- The ACT_ROUTE_ZONE class implements the core functions to route an AIR @{Wrapper.Controllable} player @{Wrapper.Unit} to a @{Core.Zone}.
-- The player receives on perioding times messages with the coordinates of the route to follow.
@@ -70,6 +70,11 @@
--
-- * @{#ACT_ROUTE_ZONE.New}(): Creates a new ACT_ROUTE_ZONE object.
--
-- # Developer Note
--
-- Note while this class still works, it is no longer supported as the original author stopped active development of MOOSE
-- Therefore, this class is considered to be deprecated
--
-- ===
--
-- @module Actions.Act_Route

View File

@@ -86,7 +86,7 @@
-- There are also dispatchers that make AI work together to transport cargo automatically!!!
--
-- - @{AI.AI_Cargo_Dispatcher_APC} derived classes will create for your dynamic cargo handlers controlled by AI ground vehicle groups (APCs) to transport cargo between sites.
-- - @{AI.AI_Cargo_Dispatcher_Helicopters} derived classes will create for your dynamic cargo handlers controlled by AI helicopter groups to transport cargo between sites.
-- - @{AI.AI_Cargo_Dispatcher_Helicopter} derived classes will create for your dynamic cargo handlers controlled by AI helicopter groups to transport cargo between sites.
--
-- ## 3.3) Cargo transportation tasking.
--
@@ -233,7 +233,12 @@
-- Note that this option is optional, so can be omitted. The default value of the RR is 250 meters.
-- * **NR=** Provide the maximum range in meters when the cargo units will be boarded within the carrier during boarding.
-- Note that this option is optional, so can be omitted. The default value of the RR is 10 meters.
--
-- # Developer Note
--
-- Note while this class still works, it is no longer supported as the original author stopped active development of MOOSE
-- Therefore, this class is considered to be deprecated
--
-- ===
--
-- ### Author: **FlightControl**
@@ -365,7 +370,7 @@ CARGOS = {}
do -- CARGO
--- @type CARGO
-- @type CARGO
-- @extends Core.Fsm#FSM_PROCESS
-- @field #string Type A string defining the type of the cargo. eg. Engineers, Equipment, Screwdrivers.
-- @field #string Name A string defining the name of the cargo. The name is the unique identifier of the cargo.
@@ -393,7 +398,7 @@ do -- CARGO
--
-- * AI Armoured Personnel Carriers to transport cargo and engage in battles, using the @{AI.AI_Cargo_APC#AI_CARGO_APC} class.
-- * AI Helicopters to transport cargo, using the @{AI.AI_Cargo_Helicopter#AI_CARGO_HELICOPTER} class.
-- * AI Planes to transport cargo, using the @{AI.AI_Cargo_Plane#AI_CARGO_PLANE} class.
-- * AI Planes to transport cargo, using the @{AI.AI_Cargo_Airplane#AI_CARGO_AIRPLANE} class.
-- * AI Ships is planned.
--
-- The above cargo classes are also used by the TASK\_CARGO\_ classes to allow human players to transport cargo as part of a tasking:
@@ -428,7 +433,7 @@ do -- CARGO
Reported = {},
}
--- @type CARGO.CargoObjects
-- @type CARGO.CargoObjects
-- @map < #string, Wrapper.Positionable#POSITIONABLE > The alive POSITIONABLE objects representing the the cargo.
--- CARGO Constructor. This class is an abstract class and should not be instantiated.
@@ -442,7 +447,7 @@ do -- CARGO
function CARGO:New( Type, Name, Weight, LoadRadius, NearRadius ) --R2.1
local self = BASE:Inherit( self, FSM:New() ) -- #CARGO
self:F( { Type, Name, Weight, LoadRadius, NearRadius } )
self:T( { Type, Name, Weight, LoadRadius, NearRadius } )
self:SetStartState( "UnLoaded" )
self:AddTransition( { "UnLoaded", "Boarding" }, "Board", "Boarding" )
@@ -706,7 +711,7 @@ do -- CARGO
-- @param #CARGO self
-- @return #CARGO
function CARGO:Spawn( PointVec2 )
self:F()
self:T()
end
@@ -807,7 +812,7 @@ do -- CARGO
-- @param Core.Point#COORDINATE Coordinate
-- @return #boolean true if the CargoGroup is within the loading radius.
function CARGO:IsInLoadRadius( Coordinate )
self:F( { Coordinate, LoadRadius = self.LoadRadius } )
self:T( { Coordinate, LoadRadius = self.LoadRadius } )
local Distance = 0
if self:IsUnLoaded() then
@@ -827,7 +832,7 @@ do -- CARGO
-- @param Core.Point#COORDINATE Coordinate
-- @return #boolean true if the Cargo can report itself.
function CARGO:IsInReportRadius( Coordinate )
self:F( { Coordinate } )
self:T( { Coordinate } )
local Distance = 0
if self:IsUnLoaded() then
@@ -848,23 +853,23 @@ do -- CARGO
-- @param #number NearRadius The radius when the cargo will board the Carrier (to avoid collision).
-- @return #boolean
function CARGO:IsNear( Coordinate, NearRadius )
--self:F( { PointVec2 = PointVec2, NearRadius = NearRadius } )
--self:T( { PointVec2 = PointVec2, NearRadius = NearRadius } )
if self.CargoObject:IsAlive() then
--local Distance = PointVec2:Get2DDistance( self.CargoObject:GetPointVec2() )
--self:F( { CargoObjectName = self.CargoObject:GetName() } )
--self:F( { CargoObjectVec2 = self.CargoObject:GetVec2() } )
--self:F( { PointVec2 = PointVec2:GetVec2() } )
--self:T( { CargoObjectName = self.CargoObject:GetName() } )
--self:T( { CargoObjectVec2 = self.CargoObject:GetVec2() } )
--self:T( { PointVec2 = PointVec2:GetVec2() } )
local Distance = Coordinate:Get2DDistance( self.CargoObject:GetCoordinate() )
--self:F( { Distance = Distance, NearRadius = NearRadius or "nil" } )
--self:T( { Distance = Distance, NearRadius = NearRadius or "nil" } )
if Distance <= NearRadius then
--self:F( { PointVec2 = PointVec2, NearRadius = NearRadius, IsNear = true } )
--self:T( { PointVec2 = PointVec2, NearRadius = NearRadius, IsNear = true } )
return true
end
end
--self:F( { PointVec2 = PointVec2, NearRadius = NearRadius, IsNear = false } )
--self:T( { PointVec2 = PointVec2, NearRadius = NearRadius, IsNear = false } )
return false
end
@@ -873,12 +878,12 @@ do -- CARGO
-- @param Core.Zone#ZONE_BASE Zone
-- @return #boolean **true** if cargo is in the Zone, **false** if cargo is not in the Zone.
function CARGO:IsInZone( Zone )
--self:F( { Zone } )
--self:T( { Zone } )
if self:IsLoaded() then
return Zone:IsPointVec2InZone( self.CargoCarrier:GetPointVec2() )
else
--self:F( { Size = self.CargoObject:GetSize(), Units = self.CargoObject:GetUnits() } )
--self:T( { Size = self.CargoObject:GetSize(), Units = self.CargoObject:GetUnits() } )
if self.CargoObject:GetSize() ~= 0 then
return Zone:IsPointVec2InZone( self.CargoObject:GetPointVec2() )
else
@@ -975,7 +980,7 @@ do -- CARGO
--- Report to a Carrier Group with a Flaring signal.
-- @param #CARGO self
-- @param Utils#UTILS.FlareColor FlareColor the color of the flare.
-- @param Utilities.Utils#UTILS.FlareColor FlareColor the color of the flare.
-- @return #CARGO
function CARGO:ReportFlare( FlareColor )
@@ -984,7 +989,7 @@ do -- CARGO
--- Report to a Carrier Group with a Smoking signal.
-- @param #CARGO self
-- @param Utils#UTILS.SmokeColor SmokeColor the color of the smoke.
-- @param Utilities.Utils#UTILS.SmokeColor SmokeColor the color of the smoke.
-- @return #CARGO
function CARGO:ReportSmoke( SmokeColor )
@@ -1029,7 +1034,7 @@ end -- CARGO
do -- CARGO_REPRESENTABLE
--- @type CARGO_REPRESENTABLE
-- @type CARGO_REPRESENTABLE
-- @extends #CARGO
-- @field test
@@ -1051,7 +1056,7 @@ do -- CARGO_REPRESENTABLE
-- Inherit CARGO.
local self = BASE:Inherit( self, CARGO:New( Type, Name, 0, LoadRadius, NearRadius ) ) -- #CARGO_REPRESENTABLE
self:F( { Type, Name, LoadRadius, NearRadius } )
self:T( { Type, Name, LoadRadius, NearRadius } )
-- Descriptors.
local Desc=CargoObject:GetDesc()
@@ -1081,7 +1086,7 @@ do -- CARGO_REPRESENTABLE
function CARGO_REPRESENTABLE:Destroy()
-- Cargo objects are deleted from the _DATABASE and SET_CARGO objects.
self:F( { CargoName = self:GetName() } )
self:T( { CargoName = self:GetName() } )
--_EVENTDISPATCHER:CreateEventDeleteCargo( self )
return self
@@ -1118,12 +1123,12 @@ do -- CARGO_REPRESENTABLE
CoordinateZone:Scan( { Object.Category.UNIT } )
for _, DCSUnit in pairs( CoordinateZone:GetScannedUnits() ) do
local NearUnit = UNIT:Find( DCSUnit )
self:F({NearUnit=NearUnit})
self:T({NearUnit=NearUnit})
local NearUnitCoalition = NearUnit:GetCoalition()
local CargoCoalition = self:GetCoalition()
if NearUnitCoalition == CargoCoalition then
local Attributes = NearUnit:GetDesc()
self:F({Desc=Attributes})
self:T({Desc=Attributes})
if NearUnit:HasAttribute( "Trucks" ) then
MESSAGE:New( Message, 20, NearUnit:GetCallsign() .. " reporting - Cargo " .. self:GetName() ):ToGroup( TaskGroup )
break
@@ -1137,7 +1142,7 @@ end -- CARGO_REPRESENTABLE
do -- CARGO_REPORTABLE
--- @type CARGO_REPORTABLE
-- @type CARGO_REPORTABLE
-- @extends #CARGO
CARGO_REPORTABLE = {
ClassName = "CARGO_REPORTABLE"
@@ -1153,7 +1158,7 @@ do -- CARGO_REPORTABLE
-- @return #CARGO_REPORTABLE
function CARGO_REPORTABLE:New( Type, Name, Weight, LoadRadius, NearRadius )
local self = BASE:Inherit( self, CARGO:New( Type, Name, Weight, LoadRadius, NearRadius ) ) -- #CARGO_REPORTABLE
self:F( { Type, Name, Weight, LoadRadius, NearRadius } )
self:T( { Type, Name, Weight, LoadRadius, NearRadius } )
return self
end
@@ -1173,7 +1178,7 @@ end
do -- CARGO_PACKAGE
--- @type CARGO_PACKAGE
-- @type CARGO_PACKAGE
-- @extends #CARGO_REPRESENTABLE
CARGO_PACKAGE = {
ClassName = "CARGO_PACKAGE"
@@ -1190,7 +1195,7 @@ do -- CARGO_PACKAGE
-- @return #CARGO_PACKAGE
function CARGO_PACKAGE:New( CargoCarrier, Type, Name, Weight, LoadRadius, NearRadius )
local self = BASE:Inherit( self, CARGO_REPRESENTABLE:New( CargoCarrier, Type, Name, Weight, LoadRadius, NearRadius ) ) -- #CARGO_PACKAGE
self:F( { Type, Name, Weight, LoadRadius, NearRadius } )
self:T( { Type, Name, Weight, LoadRadius, NearRadius } )
self:T( CargoCarrier )
self.CargoCarrier = CargoCarrier
@@ -1208,7 +1213,7 @@ end
-- @param #number BoardDistance
-- @param #number Angle
function CARGO_PACKAGE:onafterOnBoard( From, Event, To, CargoCarrier, Speed, BoardDistance, LoadDistance, Angle )
self:F()
self:T()
self.CargoInAir = self.CargoCarrier:InAir()
@@ -1241,7 +1246,7 @@ end
-- @param Wrapper.Unit#UNIT CargoCarrier
-- @return #boolean
function CARGO_PACKAGE:IsNear( CargoCarrier )
self:F()
self:T()
local CargoCarrierPoint = CargoCarrier:GetCoordinate()
@@ -1266,7 +1271,7 @@ end
-- @param #number LoadDistance
-- @param #number Angle
function CARGO_PACKAGE:onafterOnBoarded( From, Event, To, CargoCarrier, Speed, BoardDistance, LoadDistance, Angle )
self:F()
self:T()
if self:IsNear( CargoCarrier ) then
self:__Load( 1, CargoCarrier, Speed, LoadDistance, Angle )
@@ -1287,7 +1292,7 @@ end
-- @param #number Radius
-- @param #number Angle
function CARGO_PACKAGE:onafterUnBoard( From, Event, To, CargoCarrier, Speed, UnLoadDistance, UnBoardDistance, Radius, Angle )
self:F()
self:T()
self.CargoInAir = self.CargoCarrier:InAir()
@@ -1326,7 +1331,7 @@ end
-- @param Wrapper.Unit#UNIT CargoCarrier
-- @param #number Speed
function CARGO_PACKAGE:onafterUnBoarded( From, Event, To, CargoCarrier, Speed )
self:F()
self:T()
if self:IsNear( CargoCarrier ) then
self:__UnLoad( 1, CargoCarrier, Speed )
@@ -1345,7 +1350,7 @@ end
-- @param #number LoadDistance
-- @param #number Angle
function CARGO_PACKAGE:onafterLoad( From, Event, To, CargoCarrier, Speed, LoadDistance, Angle )
self:F()
self:T()
self.CargoCarrier = CargoCarrier
@@ -1373,7 +1378,7 @@ end
-- @param #number Distance
-- @param #number Angle
function CARGO_PACKAGE:onafterUnLoad( From, Event, To, CargoCarrier, Speed, Distance, Angle )
self:F()
self:T()
local StartPointVec2 = self.CargoCarrier:GetPointVec2()
local CargoCarrierHeading = self.CargoCarrier:GetHeading() -- Get Heading of object in degrees.

View File

@@ -36,7 +36,12 @@ do -- CARGO_CRATE
--
-- * @{Tasking.Task_Cargo_Transport#TASK_CARGO_TRANSPORT} to transport cargo by human players.
-- * @{Tasking.Task_Cargo_Transport#TASK_CARGO_CSAR} to transport downed pilots by human players.
--
-- # Developer Note
--
-- Note while this class still works, it is no longer supported as the original author stopped active development of MOOSE
-- Therefore, this class is considered to be deprecated
--
-- ===
--
-- @field #CARGO_CRATE
@@ -54,7 +59,7 @@ do -- CARGO_CRATE
-- @return #CARGO_CRATE
function CARGO_CRATE:New( CargoStatic, Type, Name, LoadRadius, NearRadius )
local self = BASE:Inherit( self, CARGO_REPRESENTABLE:New( CargoStatic, Type, Name, nil, LoadRadius, NearRadius ) ) -- #CARGO_CRATE
self:F( { Type, Name, NearRadius } )
self:T( { Type, Name, NearRadius } )
self.CargoObject = CargoStatic -- Wrapper.Static#STATIC
@@ -111,7 +116,7 @@ do -- CARGO_CRATE
-- @param #string To
-- @param Core.Point#POINT_VEC2
function CARGO_CRATE:onenterUnLoaded( From, Event, To, ToPointVec2 )
--self:F( { ToPointVec2, From, Event, To } )
--self:T( { ToPointVec2, From, Event, To } )
local Angle = 180
local Speed = 10
@@ -148,7 +153,7 @@ do -- CARGO_CRATE
-- @param #string To
-- @param Wrapper.Unit#UNIT CargoCarrier
function CARGO_CRATE:onenterLoaded( From, Event, To, CargoCarrier )
--self:F( { From, Event, To, CargoCarrier } )
--self:T( { From, Event, To, CargoCarrier } )
self.CargoCarrier = CargoCarrier
@@ -185,7 +190,7 @@ do -- CARGO_CRATE
-- @param Core.Point#COORDINATE Coordinate
-- @return #boolean true if the Cargo Crate is within the report radius.
function CARGO_CRATE:IsInReportRadius( Coordinate )
--self:F( { Coordinate, LoadRadius = self.LoadRadius } )
--self:T( { Coordinate, LoadRadius = self.LoadRadius } )
local Distance = 0
if self:IsUnLoaded() then
@@ -205,7 +210,7 @@ do -- CARGO_CRATE
-- @param Core.Point#Coordinate Coordinate
-- @return #boolean true if the Cargo Crate is within the loading radius.
function CARGO_CRATE:IsInLoadRadius( Coordinate )
--self:F( { Coordinate, LoadRadius = self.NearRadius } )
--self:T( { Coordinate, LoadRadius = self.NearRadius } )
local Distance = 0
if self:IsUnLoaded() then
@@ -226,7 +231,7 @@ do -- CARGO_CRATE
-- @return Core.Point#COORDINATE The current Coordinate of the first Cargo of the CargoGroup.
-- @return #nil There is no valid Cargo in the CargoGroup.
function CARGO_CRATE:GetCoordinate()
--self:F()
--self:T()
return self.CargoObject:GetCoordinate()
end
@@ -256,7 +261,7 @@ do -- CARGO_CRATE
-- @param #CARGO_CRATE self
-- @param Core.Point#COORDINATE Coordinate
function CARGO_CRATE:RouteTo( Coordinate )
self:F( {Coordinate = Coordinate } )
self:T( {Coordinate = Coordinate } )
end
@@ -269,7 +274,7 @@ do -- CARGO_CRATE
-- @return #boolean The Cargo is near to the Carrier.
-- @return #nil The Cargo is not near to the Carrier.
function CARGO_CRATE:IsNear( CargoCarrier, NearRadius )
self:F( {NearRadius = NearRadius } )
self:T( {NearRadius = NearRadius } )
return self:IsNear( CargoCarrier:GetCoordinate(), NearRadius )
end
@@ -278,7 +283,7 @@ do -- CARGO_CRATE
-- @param #CARGO_CRATE self
function CARGO_CRATE:Respawn()
self:F( { "Respawning crate " .. self:GetName() } )
self:T( { "Respawning crate " .. self:GetName() } )
-- Respawn the group...
@@ -295,7 +300,7 @@ do -- CARGO_CRATE
-- @param #CARGO_CRATE self
function CARGO_CRATE:onafterReset()
self:F( { "Reset crate " .. self:GetName() } )
self:T( { "Reset crate " .. self:GetName() } )
-- Respawn the group...

View File

@@ -38,7 +38,12 @@ do -- CARGO_GROUP
--
-- * @{Tasking.Task_Cargo_Transport#TASK_CARGO_TRANSPORT} to transport cargo by human players.
-- * @{Tasking.Task_Cargo_Transport#TASK_CARGO_CSAR} to transport downed pilots by human players.
--
-- # Developer Note
--
-- Note while this class still works, it is no longer supported as the original author stopped active development of MOOSE
-- Therefore, this class is considered to be deprecated
--
-- @field #CARGO_GROUP CARGO_GROUP
--
CARGO_GROUP = {
@@ -59,7 +64,7 @@ do -- CARGO_GROUP
-- Inherit CAROG_REPORTABLE
local self = BASE:Inherit( self, CARGO_REPORTABLE:New( Type, Name, 0, LoadRadius, NearRadius ) ) -- #CARGO_GROUP
self:F( { Type, Name, LoadRadius } )
self:T( { Type, Name, LoadRadius } )
self.CargoSet = SET_CARGO:New()
self.CargoGroup = CargoGroup
@@ -141,7 +146,7 @@ do -- CARGO_GROUP
-- @param #CARGO_GROUP self
function CARGO_GROUP:Respawn()
self:F( { "Respawning" } )
self:T( { "Respawning" } )
for CargoID, CargoData in pairs( self.CargoSet:GetSet() ) do
local Cargo = CargoData -- Cargo.Cargo#CARGO
@@ -222,7 +227,7 @@ do -- CARGO_GROUP
-- @param #CARGO_GROUP self
function CARGO_GROUP:Regroup()
self:F("Regroup")
self:T("Regroup")
if self.Grouped == false then
@@ -236,7 +241,7 @@ do -- CARGO_GROUP
for CargoUnitName, CargoUnit in pairs( self.CargoSet:GetSet() ) do
local CargoUnit = CargoUnit -- Cargo.CargoUnit#CARGO_UNIT
self:F( { CargoUnit:GetName(), UnLoaded = CargoUnit:IsUnLoaded() } )
self:T( { CargoUnit:GetName(), UnLoaded = CargoUnit:IsUnLoaded() } )
if CargoUnit:IsUnLoaded() then
@@ -253,7 +258,7 @@ do -- CARGO_GROUP
-- Then we register the new group in the database
self.CargoGroup = GROUP:NewTemplate( GroupTemplate, GroupTemplate.CoalitionID, GroupTemplate.CategoryID, GroupTemplate.CountryID )
self:F( { "Regroup", GroupTemplate } )
self:T( { "Regroup", GroupTemplate } )
-- Now we spawn the new group based on the template created.
self.CargoObject = _DATABASE:Spawn( GroupTemplate )
@@ -266,7 +271,7 @@ do -- CARGO_GROUP
-- @param Core.Event#EVENTDATA EventData
function CARGO_GROUP:OnEventCargoDead( EventData )
self:E(EventData)
self:T(EventData)
local Destroyed = false
@@ -291,7 +296,7 @@ do -- CARGO_GROUP
if Destroyed then
self:Destroyed()
self:E( { "Cargo group destroyed" } )
self:T( { "Cargo group destroyed" } )
end
end
@@ -304,14 +309,14 @@ do -- CARGO_GROUP
-- @param Wrapper.Unit#UNIT CargoCarrier
-- @param #number NearRadius If distance is smaller than this number, cargo is loaded into the carrier.
function CARGO_GROUP:onafterBoard( From, Event, To, CargoCarrier, NearRadius, ... )
self:F( { CargoCarrier.UnitName, From, Event, To, NearRadius = NearRadius } )
self:T( { CargoCarrier.UnitName, From, Event, To, NearRadius = NearRadius } )
NearRadius = NearRadius or self.NearRadius
-- For each Cargo object within the CARGO_GROUPED, route each object to the CargoLoadPointVec2
self.CargoSet:ForEach(
function( Cargo, ... )
self:F( { "Board Unit", Cargo:GetName( ), Cargo:IsDestroyed(), Cargo.CargoObject:IsAlive() } )
self:T( { "Board Unit", Cargo:GetName( ), Cargo:IsDestroyed(), Cargo.CargoObject:IsAlive() } )
local CargoGroup = Cargo.CargoObject --Wrapper.Group#GROUP
CargoGroup:OptionAlarmStateGreen()
Cargo:__Board( 1, CargoCarrier, NearRadius, ... )
@@ -329,7 +334,7 @@ do -- CARGO_GROUP
-- @param #string To
-- @param Wrapper.Unit#UNIT CargoCarrier
function CARGO_GROUP:onafterLoad( From, Event, To, CargoCarrier, ... )
--self:F( { From, Event, To, CargoCarrier, ...} )
--self:T( { From, Event, To, CargoCarrier, ...} )
if From == "UnLoaded" then
-- For each Cargo object within the CARGO_GROUP, load each cargo to the CargoCarrier.
@@ -354,7 +359,7 @@ do -- CARGO_GROUP
-- @param Wrapper.Unit#UNIT CargoCarrier
-- @param #number NearRadius If distance is smaller than this number, cargo is loaded into the carrier.
function CARGO_GROUP:onafterBoarding( From, Event, To, CargoCarrier, NearRadius, ... )
--self:F( { CargoCarrier.UnitName, From, Event, To } )
--self:T( { CargoCarrier.UnitName, From, Event, To } )
local Boarded = true
local Cancelled = false
@@ -388,7 +393,7 @@ do -- CARGO_GROUP
if not Boarded then
self:__Boarding( -5, CargoCarrier, NearRadius, ... )
else
self:F("Group Cargo is loaded")
self:T("Group Cargo is loaded")
self:__Load( 1, CargoCarrier, ... )
end
else
@@ -408,7 +413,7 @@ do -- CARGO_GROUP
-- @param Core.Point#POINT_VEC2 ToPointVec2
-- @param #number NearRadius If distance is smaller than this number, cargo is loaded into the carrier.
function CARGO_GROUP:onafterUnBoard( From, Event, To, ToPointVec2, NearRadius, ... )
self:F( {From, Event, To, ToPointVec2, NearRadius } )
self:T( {From, Event, To, ToPointVec2, NearRadius } )
NearRadius = NearRadius or 25
@@ -451,7 +456,7 @@ do -- CARGO_GROUP
-- @param Core.Point#POINT_VEC2 ToPointVec2
-- @param #number NearRadius If distance is smaller than this number, cargo is loaded into the carrier.
function CARGO_GROUP:onafterUnBoarding( From, Event, To, ToPointVec2, NearRadius, ... )
--self:F( { From, Event, To, ToPointVec2, NearRadius } )
--self:T( { From, Event, To, ToPointVec2, NearRadius } )
--local NearRadius = NearRadius or 25
@@ -488,7 +493,7 @@ do -- CARGO_GROUP
-- @param #string To
-- @param Core.Point#POINT_VEC2 ToPointVec2
function CARGO_GROUP:onafterUnLoad( From, Event, To, ToPointVec2, ... )
--self:F( { From, Event, To, ToPointVec2 } )
--self:T( { From, Event, To, ToPointVec2 } )
if From == "Loaded" then
@@ -606,7 +611,7 @@ do -- CARGO_GROUP
-- @param #CARGO_GROUP self
-- @param Core.Point#COORDINATE Coordinate
function CARGO_GROUP:RouteTo( Coordinate )
--self:F( {Coordinate = Coordinate } )
--self:T( {Coordinate = Coordinate } )
-- For each Cargo within the CargoSet, route each object to the Coordinate
self.CargoSet:ForEach(
@@ -624,13 +629,13 @@ do -- CARGO_GROUP
-- @param #number NearRadius
-- @return #boolean The Cargo is near to the Carrier or #nil if the Cargo is not near to the Carrier.
function CARGO_GROUP:IsNear( CargoCarrier, NearRadius )
self:F( {NearRadius = NearRadius } )
self:T( {NearRadius = NearRadius } )
for _, Cargo in pairs( self.CargoSet:GetSet() ) do
local Cargo = Cargo -- Cargo.Cargo#CARGO
if Cargo:IsAlive() then
if Cargo:IsNear( CargoCarrier:GetCoordinate(), NearRadius ) then
self:F( "Near" )
self:T( "Near" )
return true
end
end
@@ -644,7 +649,7 @@ do -- CARGO_GROUP
-- @param Core.Point#COORDINATE Coordinate
-- @return #boolean true if the Cargo Group is within the load radius.
function CARGO_GROUP:IsInLoadRadius( Coordinate )
--self:F( { Coordinate } )
--self:T( { Coordinate } )
local Cargo = self:GetFirstAlive() -- Cargo.Cargo#CARGO
@@ -664,7 +669,7 @@ do -- CARGO_GROUP
return false
end
self:F( { Distance = Distance, LoadRadius = self.LoadRadius } )
self:T( { Distance = Distance, LoadRadius = self.LoadRadius } )
if Distance <= self.LoadRadius then
return true
else
@@ -682,12 +687,12 @@ do -- CARGO_GROUP
-- @param Core.Point#Coordinate Coordinate
-- @return #boolean true if the Cargo Group is within the report radius.
function CARGO_GROUP:IsInReportRadius( Coordinate )
--self:F( { Coordinate } )
--self:T( { Coordinate } )
local Cargo = self:GetFirstAlive() -- Cargo.Cargo#CARGO
if Cargo then
self:F( { Cargo } )
self:T( { Cargo } )
local Distance = 0
if Cargo:IsUnLoaded() then
Distance = Coordinate:Get2DDistance( Cargo.CargoObject:GetCoordinate() )
@@ -733,7 +738,7 @@ do -- CARGO_GROUP
-- @return #boolean **true** if the first element of the CargoGroup is in the Zone
-- @return #boolean **false** if there is no element of the CargoGroup in the Zone.
function CARGO_GROUP:IsInZone( Zone )
--self:F( { Zone } )
--self:T( { Zone } )
local Cargo = self.CargoSet:GetFirst() -- Cargo.Cargo#CARGO

View File

@@ -29,7 +29,12 @@ do -- CARGO_SLINGLOAD
--
-- * @{Tasking.Task_Cargo_Transport#TASK_CARGO_TRANSPORT} to transport cargo by human players.
-- * @{Tasking.Task_Cargo_Transport#TASK_CARGO_CSAR} to transport downed pilots by human players.
--
-- # Developer Note
--
-- Note while this class still works, it is no longer supported as the original author stopped active development of MOOSE
-- Therefore, this class is considered to be deprecated
--
-- ===
--
-- @field #CARGO_SLINGLOAD
@@ -47,7 +52,7 @@ do -- CARGO_SLINGLOAD
-- @return #CARGO_SLINGLOAD
function CARGO_SLINGLOAD:New( CargoStatic, Type, Name, LoadRadius, NearRadius )
local self = BASE:Inherit( self, CARGO_REPRESENTABLE:New( CargoStatic, Type, Name, nil, LoadRadius, NearRadius ) ) -- #CARGO_SLINGLOAD
self:F( { Type, Name, NearRadius } )
self:T( { Type, Name, NearRadius } )
self.CargoObject = CargoStatic
@@ -125,7 +130,7 @@ do -- CARGO_SLINGLOAD
-- @param Core.Point#COORDINATE Coordinate
-- @return #boolean true if the Cargo Crate is within the report radius.
function CARGO_SLINGLOAD:IsInReportRadius( Coordinate )
--self:F( { Coordinate, LoadRadius = self.LoadRadius } )
--self:T( { Coordinate, LoadRadius = self.LoadRadius } )
local Distance = 0
if self:IsUnLoaded() then
@@ -144,7 +149,7 @@ do -- CARGO_SLINGLOAD
-- @param Core.Point#COORDINATE Coordinate
-- @return #boolean true if the Cargo Slingload is within the loading radius.
function CARGO_SLINGLOAD:IsInLoadRadius( Coordinate )
--self:F( { Coordinate } )
--self:T( { Coordinate } )
local Distance = 0
if self:IsUnLoaded() then
@@ -164,7 +169,7 @@ do -- CARGO_SLINGLOAD
-- @return Core.Point#COORDINATE The current Coordinate of the first Cargo of the CargoGroup.
-- @return #nil There is no valid Cargo in the CargoGroup.
function CARGO_SLINGLOAD:GetCoordinate()
--self:F()
--self:T()
return self.CargoObject:GetCoordinate()
end
@@ -194,7 +199,7 @@ do -- CARGO_SLINGLOAD
-- @param #CARGO_SLINGLOAD self
-- @param Core.Point#COORDINATE Coordinate
function CARGO_SLINGLOAD:RouteTo( Coordinate )
--self:F( {Coordinate = Coordinate } )
--self:T( {Coordinate = Coordinate } )
end
@@ -207,7 +212,7 @@ do -- CARGO_SLINGLOAD
-- @return #boolean The Cargo is near to the Carrier.
-- @return #nil The Cargo is not near to the Carrier.
function CARGO_SLINGLOAD:IsNear( CargoCarrier, NearRadius )
--self:F( {NearRadius = NearRadius } )
--self:T( {NearRadius = NearRadius } )
return self:IsNear( CargoCarrier:GetCoordinate(), NearRadius )
end
@@ -217,7 +222,7 @@ do -- CARGO_SLINGLOAD
-- @param #CARGO_SLINGLOAD self
function CARGO_SLINGLOAD:Respawn()
--self:F( { "Respawning slingload " .. self:GetName() } )
--self:T( { "Respawning slingload " .. self:GetName() } )
-- Respawn the group...
@@ -234,7 +239,7 @@ do -- CARGO_SLINGLOAD
-- @param #CARGO_SLINGLOAD self
function CARGO_SLINGLOAD:onafterReset()
--self:F( { "Reset slingload " .. self:GetName() } )
--self:T( { "Reset slingload " .. self:GetName() } )
-- Respawn the group...

View File

@@ -27,7 +27,12 @@ do -- CARGO_UNIT
-- Note that ground forces behave in a group, and thus, act in formation, regardless if one unit is commanded to move.
--
-- This class is used in CARGO_GROUP, and is not meant to be used by mission designers individually.
--
-- # Developer Note
--
-- Note while this class still works, it is no longer supported as the original author stopped active development of MOOSE
-- Therefore, this class is considered to be deprecated
--
-- ===
--
-- @field #CARGO_UNIT CARGO_UNIT
@@ -70,7 +75,7 @@ do -- CARGO_UNIT
-- @param Core.Point#POINT_VEC2 ToPointVec2
-- @param #number NearRadius (optional) Defaut 25 m.
function CARGO_UNIT:onenterUnBoarding( From, Event, To, ToPointVec2, NearRadius )
self:F( { From, Event, To, ToPointVec2, NearRadius } )
self:T( { From, Event, To, ToPointVec2, NearRadius } )
local Angle = 180
local Speed = 60
@@ -109,7 +114,7 @@ do -- CARGO_UNIT
else
self.CargoObject:ReSpawnAt( FromPointVec2, CargoDeployHeading )
end
self:F( { "CargoUnits:", self.CargoObject:GetGroup():GetName() } )
self:T( { "CargoUnits:", self.CargoObject:GetGroup():GetName() } )
self.CargoCarrier = nil
local Points = {}
@@ -143,7 +148,7 @@ do -- CARGO_UNIT
-- @param Core.Point#POINT_VEC2 ToPointVec2
-- @param #number NearRadius (optional) Defaut 100 m.
function CARGO_UNIT:onleaveUnBoarding( From, Event, To, ToPointVec2, NearRadius )
self:F( { From, Event, To, ToPointVec2, NearRadius } )
self:T( { From, Event, To, ToPointVec2, NearRadius } )
local Angle = 180
local Speed = 10
@@ -169,7 +174,7 @@ do -- CARGO_UNIT
-- @param Core.Point#POINT_VEC2 ToPointVec2
-- @param #number NearRadius (optional) Defaut 100 m.
function CARGO_UNIT:onafterUnBoarding( From, Event, To, ToPointVec2, NearRadius )
self:F( { From, Event, To, ToPointVec2, NearRadius } )
self:T( { From, Event, To, ToPointVec2, NearRadius } )
self.CargoInAir = self.CargoObject:InAir()
@@ -194,7 +199,7 @@ do -- CARGO_UNIT
-- @param #string To
-- @param Core.Point#POINT_VEC2
function CARGO_UNIT:onenterUnLoaded( From, Event, To, ToPointVec2 )
self:F( { ToPointVec2, From, Event, To } )
self:T( { ToPointVec2, From, Event, To } )
local Angle = 180
local Speed = 10
@@ -231,7 +236,7 @@ do -- CARGO_UNIT
-- @param Wrapper.Group#GROUP CargoCarrier
-- @param #number NearRadius
function CARGO_UNIT:onafterBoard( From, Event, To, CargoCarrier, NearRadius, ... )
self:F( { From, Event, To, CargoCarrier, NearRadius = NearRadius } )
self:T( { From, Event, To, CargoCarrier, NearRadius = NearRadius } )
self.CargoInAir = self.CargoObject:InAir()
@@ -239,7 +244,7 @@ do -- CARGO_UNIT
local MaxSpeed = Desc.speedMaxOffRoad
local TypeName = Desc.typeName
--self:F({Unit=self.CargoObject:GetName()})
--self:T({Unit=self.CargoObject:GetName()})
-- A cargo unit can only be boarded if it is not dead
@@ -293,9 +298,9 @@ do -- CARGO_UNIT
-- @param Wrapper.Client#CLIENT CargoCarrier
-- @param #number NearRadius Default 25 m.
function CARGO_UNIT:onafterBoarding( From, Event, To, CargoCarrier, NearRadius, ... )
self:F( { From, Event, To, CargoCarrier:GetName(), NearRadius = NearRadius } )
self:T( { From, Event, To, CargoCarrier:GetName(), NearRadius = NearRadius } )
self:F( { IsAlive=self.CargoObject:IsAlive() } )
self:T( { IsAlive=self.CargoObject:IsAlive() } )
if CargoCarrier and CargoCarrier:IsAlive() then -- and self.CargoObject and self.CargoObject:IsAlive() then
if (CargoCarrier:IsAir() and not CargoCarrier:InAir()) or true then
@@ -316,7 +321,7 @@ do -- CARGO_UNIT
local Angle = 180
local Distance = 0
--self:F({Unit=self.CargoObject:GetName()})
--self:T({Unit=self.CargoObject:GetName()})
local CargoCarrierPointVec2 = CargoCarrier:GetPointVec2()
local CargoCarrierHeading = CargoCarrier:GetHeading() -- Get Heading of object in degrees.
@@ -343,7 +348,7 @@ do -- CARGO_UNIT
self.CargoObject:SetCommand( self.CargoObject:CommandStopRoute( true ) )
end
else
self:E("Something is wrong")
self:T("Something is wrong")
end
end
@@ -356,11 +361,11 @@ do -- CARGO_UNIT
-- @param #string To
-- @param Wrapper.Unit#UNIT CargoCarrier
function CARGO_UNIT:onenterLoaded( From, Event, To, CargoCarrier )
self:F( { From, Event, To, CargoCarrier } )
self:T( { From, Event, To, CargoCarrier } )
self.CargoCarrier = CargoCarrier
--self:F({Unit=self.CargoObject:GetName()})
--self:T({Unit=self.CargoObject:GetName()})
-- Only destroy the CargoObject if there is a CargoObject (packages don't have CargoObjects).
if self.CargoObject then

View File

@@ -112,7 +112,7 @@
--
-- # Calculate the Path
--
-- Finally, we have to calculate the path. This is done by the @{ASTAR.GetPath}(*ExcludeStart, ExcludeEnd*) function. This function returns a table of nodes, which
-- Finally, we have to calculate the path. This is done by the @{#GetPath}(*ExcludeStart, ExcludeEnd*) function. This function returns a table of nodes, which
-- describe the optimal path from the start node to the end node.
--
-- By default, the start and end node are include in the table that is returned.

View File

@@ -34,7 +34,8 @@ local _TraceClassMethod = {}
local _ClassID = 0
--- @type BASE
---
-- @type BASE
-- @field ClassName The name of the class.
-- @field ClassID The ID number of the class.
-- @field ClassNameAndID The name of the class concatenated with the ID number of the class.
@@ -201,10 +202,10 @@ BASE = {
Scheduler = nil,
}
--- @field #BASE.__
-- @field #BASE.__
BASE.__ = {}
--- @field #BASE._
-- @field #BASE._
BASE._ = {
Schedules = {}, --- Contains the Schedulers Active
}
@@ -229,7 +230,7 @@ FORMATION = {
-- @param #BASE self
-- @return #BASE
function BASE:New()
--local self = routines.utils.deepCopy( self ) -- Create a new self instance
--local self = UTILS.DeepCopy( self ) -- Create a new self instance
local self = UTILS.DeepCopy(self)
_ClassID = _ClassID + 1
@@ -252,7 +253,7 @@ end
function BASE:Inherit( Child, Parent )
-- Create child.
local Child = routines.utils.deepCopy( Child )
local Child = UTILS.DeepCopy( Child )
if Child ~= nil then
@@ -1143,6 +1144,28 @@ function BASE:TraceClassMethod( Class, Method )
self:I( "Tracing method " .. Method .. " of class " .. Class )
end
--- (Internal) Serialize arguments
-- @param #BASE self
-- @param #table Arguments
-- @return #string Text
function BASE:_Serialize(Arguments)
local text = UTILS.PrintTableToLog({Arguments}, 0, true)
text = string.gsub(text,"(\n+)","")
text = string.gsub(text,"%(%(","%(")
text = string.gsub(text,"%)%)","%)")
text = string.gsub(text,"(%s+)"," ")
return text
end
----- (Internal) Serialize arguments
---- @param #BASE self
---- @param #table Arguments
---- @return #string Text
--function BASE:_Serialize(Arguments)
-- local text=UTILS.BasicSerialize(Arguments)
-- return text
--end
--- Trace a function call. This function is private.
-- @param #BASE self
-- @param Arguments A #table or any field.
@@ -1167,7 +1190,7 @@ function BASE:_F( Arguments, DebugInfoCurrentParam, DebugInfoFromParam )
if DebugInfoFrom then
LineFrom = DebugInfoFrom.currentline
end
env.info( string.format( "%6d(%6d)/%1s:%30s%05d.%s(%s)", LineCurrent, LineFrom, "F", self.ClassName, self.ClassID, Function, routines.utils.oneLineSerialize( Arguments ) ) )
env.info( string.format( "%6d(%6d)/%1s:%30s%05d.%s(%s)", LineCurrent, LineFrom, "F", self.ClassName, self.ClassID, Function, BASE:_Serialize(Arguments) ) )
end
end
end
@@ -1241,7 +1264,7 @@ function BASE:_T( Arguments, DebugInfoCurrentParam, DebugInfoFromParam )
if DebugInfoFrom then
LineFrom = DebugInfoFrom.currentline
end
env.info( string.format( "%6d(%6d)/%1s:%30s%05d.%s", LineCurrent, LineFrom, "T", self.ClassName, self.ClassID, routines.utils.oneLineSerialize( Arguments ) ) )
env.info( string.format( "%6d(%6d)/%1s:%30s%05d.%s", LineCurrent, LineFrom, "T", self.ClassName, self.ClassID, BASE:_Serialize(Arguments) ) )
end
end
end
@@ -1311,9 +1334,9 @@ function BASE:E( Arguments )
LineFrom = DebugInfoFrom.currentline
end
env.info( string.format( "%6d(%6d)/%1s:%30s%05d.%s(%s)", LineCurrent, LineFrom, "E", self.ClassName, self.ClassID, Function, routines.utils.oneLineSerialize( Arguments ) ) )
env.info( string.format( "%6d(%6d)/%1s:%30s%05d.%s(%s)", LineCurrent, LineFrom, "E", self.ClassName, self.ClassID, Function, UTILS.BasicSerialize( Arguments ) ) )
else
env.info( string.format( "%1s:%30s%05d(%s)", "E", self.ClassName, self.ClassID, routines.utils.oneLineSerialize( Arguments ) ) )
env.info( string.format( "%1s:%30s%05d(%s)", "E", self.ClassName, self.ClassID, BASE:_Serialize(Arguments) ) )
end
end
@@ -1338,41 +1361,10 @@ function BASE:I( Arguments )
LineFrom = DebugInfoFrom.currentline
end
env.info( string.format( "%6d(%6d)/%1s:%30s%05d.%s(%s)", LineCurrent, LineFrom, "I", self.ClassName, self.ClassID, Function, routines.utils.oneLineSerialize( Arguments ) ) )
env.info( string.format( "%6d(%6d)/%1s:%30s%05d.%s(%s)", LineCurrent, LineFrom, "I", self.ClassName, self.ClassID, Function, UTILS.BasicSerialize( Arguments ) ) )
else
env.info( string.format( "%1s:%30s%05d(%s)", "I", self.ClassName, self.ClassID, routines.utils.oneLineSerialize( Arguments ) ) )
env.info( string.format( "%1s:%30s%05d(%s)", "I", self.ClassName, self.ClassID, BASE:_Serialize(Arguments)) )
end
end
--- old stuff
-- function BASE:_Destructor()
-- --self:E("_Destructor")
--
-- --self:EventRemoveAll()
-- end
-- THIS IS WHY WE NEED LUA 5.2 ...
-- function BASE:_SetDestructor()
--
-- -- TODO: Okay, this is really technical...
-- -- When you set a proxy to a table to catch __gc, weak tables don't behave like weak...
-- -- Therefore, I am parking this logic until I've properly discussed all this with the community.
--
-- local proxy = newproxy(true)
-- local proxyMeta = getmetatable(proxy)
--
-- proxyMeta.__gc = function ()
-- env.info("In __gc for " .. self:GetClassNameAndID() )
-- if self._Destructor then
-- self:_Destructor()
-- end
-- end
--
-- -- keep the userdata from newproxy reachable until the object
-- -- table is about to be garbage-collected - then the __gc hook
-- -- will be invoked and the destructor called
-- rawset( self, '__proxy', proxy )
--
-- end

View File

@@ -8,6 +8,10 @@
--
-- ===
--
-- ### [Demo Missions](https://github.com/FlightControl-Master/MOOSE_Demos/tree/master/Core/Beacon)
--
-- ===
--
-- ### Authors: Hugues "Grey_Echo" Bousquet, funkyfranky
--
-- @module Core.Beacon
@@ -34,11 +38,13 @@
-- @type BEACON
-- @field #string ClassName Name of the class "BEACON".
-- @field Wrapper.Controllable#CONTROLLABLE Positionable The @{Wrapper.Controllable#CONTROLLABLE} that will receive radio capabilities.
-- @field #number UniqueName Counter to make the unique naming work.
-- @extends Core.Base#BASE
BEACON = {
ClassName = "BEACON",
Positionable = nil,
name = nil,
UniqueName = 0,
}
--- Beacon types supported by DCS.
@@ -286,6 +292,7 @@ end
-- myBeacon:AATACAN(20, "TEXACO", true) -- Activate the beacon
function BEACON:AATACAN(TACANChannel, Message, Bearing, BeaconDuration)
self:F({TACANChannel, Message, Bearing, BeaconDuration})
self:E("This method is DEPRECATED! Please use ActivateTACAN() instead.")
local IsValid = true
@@ -379,7 +386,9 @@ end
function BEACON:RadioBeacon(FileName, Frequency, Modulation, Power, BeaconDuration)
self:F({FileName, Frequency, Modulation, Power, BeaconDuration})
local IsValid = false
Modulation = Modulation or radio.modulation.AM
-- Check the filename
if type(FileName) == "string" then
if FileName:find(".ogg") or FileName:find(".wav") then
@@ -390,7 +399,7 @@ function BEACON:RadioBeacon(FileName, Frequency, Modulation, Power, BeaconDurati
end
end
if not IsValid then
self:E({"File name invalid. Maybe something wrong with the extension ? ", FileName})
self:E({"File name invalid. Maybe something wrong with the extension? ", FileName})
end
-- Check the Frequency
@@ -416,7 +425,9 @@ function BEACON:RadioBeacon(FileName, Frequency, Modulation, Power, BeaconDurati
if IsValid then
self:T2({"Activating Beacon on ", Frequency, Modulation})
-- Note that this is looped. I have to give this transmission a unique name, I use the class ID
trigger.action.radioTransmission(FileName, self.Positionable:GetPositionVec3(), Modulation, true, Frequency, Power, tostring(self.ID))
BEACON.UniqueName = BEACON.UniqueName + 1
self.BeaconName = "MooseBeacon"..tostring(BEACON.UniqueName)
trigger.action.radioTransmission(FileName, self.Positionable:GetPositionVec3(), Modulation, true, Frequency, Power, self.BeaconName)
if BeaconDuration then -- Schedule the stop of the BEACON if asked by the MD
SCHEDULER:New( nil,
@@ -424,7 +435,8 @@ function BEACON:RadioBeacon(FileName, Frequency, Modulation, Power, BeaconDurati
self:StopRadioBeacon()
end, {}, BeaconDuration)
end
end
end
return self
end
--- Stops the Radio Beacon
@@ -433,7 +445,7 @@ end
function BEACON:StopRadioBeacon()
self:F()
-- The unique name of the transmission is the class ID
trigger.action.stopRadioTransmission(tostring(self.ID))
trigger.action.stopRadioTransmission(self.BeaconName)
return self
end

View File

@@ -0,0 +1,920 @@
--- **Core** - Client Menu Management.
--
-- **Main Features:**
--
-- * For complex, non-static menu structures
-- * Lightweigt implementation as alternative to MENU
-- * Separation of menu tree creation from menu on the clients's side
-- * Works with a SET_CLIENT set of clients
-- * Allow manipulation of the shadow tree in various ways
-- * Push to all or only one client
-- * Change entries' menu text
-- * Option to make an entry usable once only across all clients
-- * Auto appends GROUP and CLIENT objects to menu calls
--
-- ===
--
-- ### Author: **applevangelist**
--
-- ===
--
-- @module Core.ClientMenu
-- @image Core_Menu.JPG
-- last change: Apr 2024
-- TODO
----------------------------------------------------------------------------------------------------------------
--
-- CLIENTMENU
--
----------------------------------------------------------------------------------------------------------------
---
-- @type CLIENTMENU
-- @field #string ClassName Class Name
-- @field #string lid Lid for log entries
-- @field #string version Version string
-- @field #string name Name
-- @field #string groupname Group name
-- @field #table path
-- @field #table parentpath
-- @field #CLIENTMENU Parent
-- @field Wrapper.Client#CLIENT client
-- @field #number GroupID Group ID
-- @field #number ID Entry ID
-- @field Wrapper.Group#GROUP group
-- @field #string UUID Unique ID based on path+name
-- @field #string Function
-- @field #table Functionargs
-- @field #table Children
-- @field #boolean Once
-- @field #boolean Generic
-- @field #boolean debug
-- @field #CLIENTMENUMANAGER Controller
-- @field #active boolean
-- @extends Core.Base#BASE
---
-- @field #CLIENTMENU
CLIENTMENU = {
ClassName = "CLIENTMENUE",
lid = "",
version = "0.1.2",
name = nil,
path = nil,
group = nil,
client = nil,
GroupID = nil,
Children = {},
Once = false,
Generic = false,
debug = false,
Controller = nil,
groupname = nil,
active = false,
}
---
-- @field #CLIENTMENU_ID
CLIENTMENU_ID = 0
--- Create an new CLIENTMENU object.
-- @param #CLIENTMENU self
-- @param Wrapper.Client#CLIENT Client The client for whom this entry is. Leave as nil for a generic entry.
-- @param #string Text Text of the F10 menu entry.
-- @param #CLIENTMENU Parent The parent menu entry.
-- @param #string Function (optional) Function to call when the entry is used.
-- @param ... (optional) Arguments for the Function, comma separated
-- @return #CLIENTMENU self
function CLIENTMENU:NewEntry(Client,Text,Parent,Function,...)
-- Inherit everything from BASE class.
local self=BASE:Inherit(self, BASE:New()) -- #CLIENTMENU
CLIENTMENU_ID = CLIENTMENU_ID + 1
self.ID = CLIENTMENU_ID
if Client then
self.group = Client:GetGroup()
self.client = Client
self.GroupID = self.group:GetID()
self.groupname = self.group:GetName() or "Unknown Groupname"
else
self.Generic = true
end
self.name = Text or "unknown entry"
if Parent then
if Parent:IsInstanceOf("MENU_BASE") then
self.parentpath = Parent.MenuPath
else
self.parentpath = Parent:GetPath()
Parent:AddChild(self)
end
end
self.Parent = Parent
self.Function = Function
self.Functionargs = arg or {}
table.insert(self.Functionargs,self.group)
table.insert(self.Functionargs,self.client)
if self.Functionargs and self.debug then
self:T({"Functionargs",self.Functionargs})
end
if not self.Generic and self.active == false then
if Function ~= nil then
local ErrorHandler = function( errmsg )
env.info( "MOOSE Error in CLIENTMENU COMMAND function: " .. errmsg )
if BASE.Debug ~= nil then
env.info( BASE.Debug.traceback() )
end
return errmsg
end
self.CallHandler = function()
local function MenuFunction()
return self.Function( unpack( self.Functionargs ) )
end
local Status, Result = xpcall( MenuFunction, ErrorHandler)
if self.Once == true then
self:Clear()
end
end
self.path = missionCommands.addCommandForGroup(self.GroupID,Text,self.parentpath, self.CallHandler)
self.active = true
else
self.path = missionCommands.addSubMenuForGroup(self.GroupID,Text,self.parentpath)
self.active = true
end
else
if self.parentpath then
self.path = UTILS.DeepCopy(self.parentpath)
else
self.path = {}
end
self.path[#self.path+1] = Text
end
self.UUID = table.concat(self.path,";")
self:T({self.UUID})
self.Once = false
-- Log id.
self.lid=string.format("CLIENTMENU %s | %s | ", self.ID, self.name)
self:T(self.lid.."Created")
return self
end
--- Create a UUID
-- @param #CLIENTMENU self
-- @param #CLIENTMENU Parent The parent object if any
-- @param #string Text The menu entry text
-- @return #string UUID
function CLIENTMENU:CreateUUID(Parent,Text)
local path = {}
if Parent and Parent.path then
path = Parent.path
end
path[#path+1] = Text
local UUID = table.concat(path,";")
return UUID
end
--- Set the CLIENTMENUMANAGER for this entry.
-- @param #CLIENTMENU self
-- @param #CLIENTMENUMANAGER Controller The controlling object.
-- @return #CLIENTMENU self
function CLIENTMENU:SetController(Controller)
self.Controller = Controller
return self
end
--- The entry will be deleted after being used used - for menu entries with functions only.
-- @param #CLIENTMENU self
-- @return #CLIENTMENU self
function CLIENTMENU:SetOnce()
self:T(self.lid.."SetOnce")
self.Once = true
return self
end
--- Remove the entry from the F10 menu.
-- @param #CLIENTMENU self
-- @return #CLIENTMENU self
function CLIENTMENU:RemoveF10()
self:T(self.lid.."RemoveF10")
if self.GroupID then
--self:I(self.lid.."Removing "..table.concat(self.path,";"))
local function RemoveFunction()
return missionCommands.removeItemForGroup(self.GroupID , self.path )
end
local status, err = pcall(RemoveFunction)
if not status then
self:I(string.format("**** Error Removing Menu Entry %s for %s!",tostring(self.name),self.groupname))
end
self.active = false
end
return self
end
--- Get the menu path table.
-- @param #CLIENTMENU self
-- @return #table Path
function CLIENTMENU:GetPath()
self:T(self.lid.."GetPath")
return self.path
end
--- Get the UUID.
-- @param #CLIENTMENU self
-- @return #string UUID
function CLIENTMENU:GetUUID()
self:T(self.lid.."GetUUID")
return self.UUID
end
--- Link a child entry.
-- @param #CLIENTMENU self
-- @param #CLIENTMENU Child The entry to link as a child.
-- @return #CLIENTMENU self
function CLIENTMENU:AddChild(Child)
self:T(self.lid.."AddChild "..Child.ID)
table.insert(self.Children,Child.ID,Child)
return self
end
--- Remove a child entry.
-- @param #CLIENTMENU self
-- @param #CLIENTMENU Child The entry to remove from the children.
-- @return #CLIENTMENU self
function CLIENTMENU:RemoveChild(Child)
self:T(self.lid.."RemoveChild "..Child.ID)
table.remove(self.Children,Child.ID)
return self
end
--- Remove all subentries (children) from this entry.
-- @param #CLIENTMENU self
-- @return #CLIENTMENU self
function CLIENTMENU:RemoveSubEntries()
self:T(self.lid.."RemoveSubEntries")
self:T({self.Children})
for _id,_entry in pairs(self.Children) do
self:T("Removing ".._id)
if _entry then
_entry:RemoveSubEntries()
_entry:RemoveF10()
if _entry.Parent then
_entry.Parent:RemoveChild(self)
end
--if self.Controller then
--self.Controller:_RemoveByID(_entry.ID)
--end
--_entry = nil
end
end
return self
end
--- Remove this entry and all subentries (children) from this entry.
-- @param #CLIENTMENU self
-- @return #CLIENTMENU self
function CLIENTMENU:Clear()
self:T(self.lid.."Clear")
for _id,_entry in pairs(self.Children) do
if _entry then
_entry:RemoveSubEntries()
_entry = nil
end
end
self:RemoveF10()
if self.Parent then
self.Parent:RemoveChild(self)
end
--if self.Controller then
--self.Controller:_RemoveByID(self.ID)
--end
return self
end
-- TODO
----------------------------------------------------------------------------------------------------------------
--
-- CLIENTMENUMANAGER
--
----------------------------------------------------------------------------------------------------------------
--- Class CLIENTMENUMANAGER
-- @type CLIENTMENUMANAGER
-- @field #string ClassName Class Name
-- @field #string lid Lid for log entries
-- @field #string version Version string
-- @field #string name Name
-- @field Core.Set#SET_CLIENT clientset The set of clients this menu manager is for
-- @field #table flattree
-- @field #table rootentries
-- @field #table menutree
-- @field #number entrycount
-- @field #boolean debug
-- @field #table PlayerMenu
-- @field #number Coalition
-- @extends Core.Base#BASE
--- *As a child my family's menu consisted of two choices: take it, or leave it.*
--
-- ===
--
-- ## CLIENTMENU and CLIENTMENUMANAGER
--
-- Manage menu structures for a SET_CLIENT of clients.
--
-- ## Concept
--
-- Separate creation of a menu tree structure from pushing it to each client. Create a shadow "reference" menu structure tree for your client pilot's in a mission.
-- This can then be propagated to all clients. Manipulate the entries in the structure with removing, clearing or changing single entries, create replacement sub-structures
-- for entries etc, push to one or all clients.
--
-- Many functions can either change the tree for one client or for all clients.
--
-- ## Conceptual remarks
--
-- There's a couple of things to fully understand:
--
-- 1) **CLIENTMENUMANAGER** manages a set of entries from **CLIENTMENU**, it's main purpose is to administer the *shadow menu tree*, ie. a menu structure which is not
-- (yet) visible to any client
-- 2) The entries are **CLIENTMENU** objects, which are linked in a tree form. There's two ways to create them:
-- A) in the manager with ":NewEntry()" which initially
-- adds it to the shadow menu **only**
-- B) stand-alone directly as `CLIENTMENU:NewEntry()` - here it depends on whether or not you gave a CLIENT object if the entry is created as generic entry or pushed
-- a **specific** client. **Be aware** though that the entries are not managed by the CLIENTMANAGER before the next step!
-- A generic entry can be added to the manager (and the shadow tree) with `:AddEntry()` - this will also push it to all clients(!) if no client is given, or a specific client only.
-- 3) Pushing only works for alive clients.
-- 4) Live and shadow tree entries are managed via the CLIENTMENUMANAGER object.
-- 5) `Propagate()`refreshes the menu tree for all, or a single client.
--
-- ## Create a base reference tree and send to all clients
--
-- local clientset = SET_CLIENT:New():FilterStart()
--
-- local menumgr = CLIENTMENUMANAGER:New(clientset,"Dayshift")
-- local mymenu = menumgr:NewEntry("Top")
-- local mymenu_lv1a = menumgr:NewEntry("Level 1 a",mymenu)
-- local mymenu_lv1b = menumgr:NewEntry("Level 1 b",mymenu)
-- -- next one is a command menu entry, which can only be used once
-- local mymenu_lv1c = menumgr:NewEntry("Action Level 1 c",mymenu, testfunction, "testtext"):SetOnce()
--
-- local mymenu_lv2a = menumgr:NewEntry("Go here",mymenu_lv1a)
-- local mymenu_lv2b = menumgr:NewEntry("Level 2 ab",mymenu_lv1a)
-- local mymenu_lv2c = menumgr:NewEntry("Level 2 ac",mymenu_lv1a)
--
-- local mymenu_lv2ba = menumgr:NewEntry("Level 2 ba",mymenu_lv1b)
-- local mymenu_lv2bb = menumgr:NewEntry("Level 2 bb",mymenu_lv1b)
-- local mymenu_lv2bc = menumgr:NewEntry("Level 2 bc",mymenu_lv1b)
--
-- local mymenu_lv3a = menumgr:NewEntry("Level 3 aaa",mymenu_lv2a)
-- local mymenu_lv3b = menumgr:NewEntry("Level 3 aab",mymenu_lv2a)
-- local mymenu_lv3c = menumgr:NewEntry("Level 3 aac",mymenu_lv2a)
--
-- menumgr:Propagate() -- propagate **once** to all clients in the SET_CLIENT
--
-- ## Remove a single entry's subtree
--
-- menumgr:RemoveSubEntries(mymenu_lv3a)
--
-- ## Remove a single entry and also it's subtree
--
-- menumgr:DeleteEntry(mymenu_lv3a)
--
-- ## Add a single entry
--
-- local baimenu = menumgr:NewEntry("BAI",mymenu_lv1b)
--
-- menumgr:AddEntry(baimenu)
--
-- ## Add an entry with a function
--
-- local baimenu = menumgr:NewEntry("Task Action", mymenu_lv1b, TestFunction, Argument1, Argument1)
--
-- Now, the class will **automatically append the call with GROUP and CLIENT objects**, as this is can only be done when pushing the entry to the clients. So, the actual function implementation needs to look like this:
--
-- function TestFunction( Argument1, Argument2, Group, Client)
--
-- **Caveat is**, that you need to ensure your arguments are not **nil** or **false**, as LUA will optimize those away. You would end up having Group and Client in wrong places in the function call. Hence,
-- if you need/ want to send **nil** or **false**, send a place holder instead and ensure your function can handle this, e.g.
--
-- local baimenu = menumgr:NewEntry("Task Action", mymenu_lv1b, TestFunction, "nil", Argument1)
--
-- ## Change the text of a leaf entry in the menu tree
--
-- menumgr:ChangeEntryTextForAll(mymenu_lv1b,"Attack")
--
-- ## Reset a single clients menu tree
--
-- menumgr:ResetMenu(client)
--
-- ## Reset all and clear the reference tree
--
-- menumgr:ResetMenuComplete()
--
-- ## Set to auto-propagate for CLIENTs joining the SET_CLIENT **after** the script is loaded - handy if you have a single menu tree.
--
-- menumgr:InitAutoPropagation()
--
-- @field #CLIENTMENUMANAGER
CLIENTMENUMANAGER = {
ClassName = "CLIENTMENUMANAGER",
lid = "",
version = "0.1.5a",
name = nil,
clientset = nil,
menutree = {},
flattree = {},
playertree = {},
entrycount = 0,
rootentries = {},
debug = true,
PlayerMenu = {},
Coalition = nil,
}
--- Create a new ClientManager instance.
-- @param #CLIENTMENUMANAGER self
-- @param Core.Set#SET_CLIENT ClientSet The set of clients to manage.
-- @param #string Alias The name of this manager.
-- @param #number Coalition (Optional) Coalition of this Manager, defaults to coalition.side.BLUE
-- @return #CLIENTMENUMANAGER self
function CLIENTMENUMANAGER:New(ClientSet, Alias, Coalition)
-- Inherit everything from FSM class.
local self=BASE:Inherit(self, BASE:New()) -- #CLIENTMENUMANAGER
self.clientset = ClientSet
self.PlayerMenu = {}
self.name = Alias or "Nightshift"
self.Coalition = Coalition or coalition.side.BLUE
-- Log id.
self.lid=string.format("CLIENTMENUMANAGER %s | %s | ", self.version, self.name)
if self.debug then
self:I(self.lid.."Created")
end
return self
end
--- [Internal] Event handling
-- @param #CLIENTMENUMANAGER self
-- @param Core.Event#EVENTDATA EventData
-- @return #CLIENTMENUMANAGER self
function CLIENTMENUMANAGER:_EventHandler(EventData)
self:T(self.lid.."_EventHandler: "..EventData.id)
--self:I(self.lid.."_EventHandler: "..tostring(EventData.IniPlayerName))
if EventData.id == EVENTS.PlayerLeaveUnit or EventData.id == EVENTS.Ejection or EventData.id == EVENTS.Crash or EventData.id == EVENTS.PilotDead then
self:T(self.lid.."Leave event for player: "..tostring(EventData.IniPlayerName))
local Client = _DATABASE:FindClient( EventData.IniUnitName )
if Client then
self:ResetMenu(Client)
end
elseif (EventData.id == EVENTS.PlayerEnterAircraft) and EventData.IniCoalition == self.Coalition then
if EventData.IniPlayerName and EventData.IniGroup then
if (not self.clientset:IsIncludeObject(_DATABASE:FindClient( EventData.IniUnitName ))) then
self:T(self.lid.."Client not in SET: "..EventData.IniPlayerName)
return self
end
--self:I(self.lid.."Join event for player: "..EventData.IniPlayerName)
local player = _DATABASE:FindClient( EventData.IniUnitName )
self:Propagate(player)
end
elseif EventData.id == EVENTS.PlayerEnterUnit then
-- special for CA slots
local grp = GROUP:FindByName(EventData.IniGroupName)
if grp:IsGround() then
self:T(string.format("Player %s entered GROUND unit %s!",EventData.IniPlayerName,EventData.IniUnitName))
local IsPlayer = EventData.IniDCSUnit:getPlayerName()
if IsPlayer then
local client=_DATABASE.CLIENTS[EventData.IniDCSUnitName] --Wrapper.Client#CLIENT
-- Add client in case it does not exist already.
if not client then
-- Debug info.
self:I(string.format("Player '%s' joined ground unit '%s' of group '%s'", tostring(EventData.IniPlayerName), tostring(EventData.IniDCSUnitName), tostring(EventData.IniDCSGroupName)))
client=_DATABASE:AddClient(EventData.IniDCSUnitName)
-- Add player.
client:AddPlayer(EventData.IniPlayerName)
-- Add player.
if not _DATABASE.PLAYERS[EventData.IniPlayerName] then
_DATABASE:AddPlayer( EventData.IniUnitName, EventData.IniPlayerName )
end
-- Player settings.
local Settings = SETTINGS:Set( EventData.IniPlayerName )
Settings:SetPlayerMenu(EventData.IniUnit)
end
--local player = _DATABASE:FindClient( EventData.IniPlayerName )
self:Propagate(client)
end
end
end
return self
end
--- Set this Client Manager to auto-propagate menus **once** to newly joined players. Useful if you have **one** menu structure only. Does not automatically push follow-up changes to the client(s).
-- @param #CLIENTMENUMANAGER self
-- @return #CLIENTMENUMANAGER self
function CLIENTMENUMANAGER:InitAutoPropagation()
-- Player Events
self:HandleEvent(EVENTS.PlayerLeaveUnit, self._EventHandler)
self:HandleEvent(EVENTS.Ejection, self._EventHandler)
self:HandleEvent(EVENTS.Crash, self._EventHandler)
self:HandleEvent(EVENTS.PilotDead, self._EventHandler)
self:HandleEvent(EVENTS.PlayerEnterAircraft, self._EventHandler)
self:HandleEvent(EVENTS.PlayerEnterUnit, self._EventHandler)
self:SetEventPriority(5)
return self
end
--- Create a new entry in the **generic** structure.
-- @param #CLIENTMENUMANAGER self
-- @param #string Text Text of the F10 menu entry.
-- @param #CLIENTMENU Parent The parent menu entry.
-- @param #string Function (optional) Function to call when the entry is used.
-- @param ... (optional) Arguments for the Function, comma separated.
-- @return #CLIENTMENU Entry
function CLIENTMENUMANAGER:NewEntry(Text,Parent,Function,...)
self:T(self.lid.."NewEntry "..Text or "None")
self.entrycount = self.entrycount + 1
local entry = CLIENTMENU:NewEntry(nil,Text,Parent,Function,unpack(arg))
if not Parent then
self.rootentries[self.entrycount] = entry
end
local depth = #entry.path
if not self.menutree[depth] then self.menutree[depth] = {} end
table.insert(self.menutree[depth],entry.UUID)
self.flattree[entry.UUID] = entry
return entry
end
--- Check matching entry in the generic structure by UUID.
-- @param #CLIENTMENUMANAGER self
-- @param #string UUID UUID of the menu entry.
-- @return #boolean Exists
function CLIENTMENUMANAGER:EntryUUIDExists(UUID)
local exists = self.flattree[UUID] and true or false
return exists
end
--- Find matching entry in the generic structure by UUID.
-- @param #CLIENTMENUMANAGER self
-- @param #string UUID UUID of the menu entry.
-- @return #CLIENTMENU Entry The #CLIENTMENU object found or nil.
function CLIENTMENUMANAGER:FindEntryByUUID(UUID)
self:T(self.lid.."FindEntryByUUID "..UUID or "None")
local entry = nil
for _gid,_entry in pairs(self.flattree) do
local Entry = _entry -- #CLIENTMENU
if Entry and Entry.UUID == UUID then
entry = Entry
end
end
return entry
end
--- Find matching entries by text in the generic structure by UUID.
-- @param #CLIENTMENUMANAGER self
-- @param #string Text Text or partial text of the menu entry to find.
-- @param #CLIENTMENU Parent (Optional) Only find entries under this parent entry.
-- @return #table Table of matching UUIDs of #CLIENTMENU objects
-- @return #table Table of matching #CLIENTMENU objects
-- @return #number Number of matches
function CLIENTMENUMANAGER:FindUUIDsByText(Text,Parent)
self:T(self.lid.."FindUUIDsByText "..Text or "None")
local matches = {}
local entries = {}
local n = 0
for _uuid,_entry in pairs(self.flattree) do
local Entry = _entry -- #CLIENTMENU
if Parent then
if Entry and string.find(Entry.name,Text,1,true) and string.find(Entry.UUID,Parent.UUID,1,true) then
table.insert(matches,_uuid)
table.insert(entries,Entry )
n=n+1
end
else
if Entry and string.find(Entry.name,Text,1,true) then
table.insert(matches,_uuid)
table.insert(entries,Entry )
n=n+1
end
end
end
return matches, entries, n
end
--- Find matching entries in the generic structure by the menu text.
-- @param #CLIENTMENUMANAGER self
-- @param #string Text Text or partial text of the F10 menu entry.
-- @param #CLIENTMENU Parent (Optional) Only find entries under this parent entry.
-- @return #table Table of matching #CLIENTMENU objects.
-- @return #number Number of matches
function CLIENTMENUMANAGER:FindEntriesByText(Text,Parent)
self:T(self.lid.."FindEntriesByText "..Text or "None")
local matches, objects, number = self:FindUUIDsByText(Text, Parent)
return objects, number
end
--- Find matching entries under a parent in the generic structure by UUID.
-- @param #CLIENTMENUMANAGER self
-- @param #CLIENTMENU Parent Find entries under this parent entry.
-- @return #table Table of matching UUIDs of #CLIENTMENU objects
-- @return #table Table of matching #CLIENTMENU objects
-- @return #number Number of matches
function CLIENTMENUMANAGER:FindUUIDsByParent(Parent)
self:T(self.lid.."FindUUIDsByParent")
local matches = {}
local entries = {}
local n = 0
for _uuid,_entry in pairs(self.flattree) do
local Entry = _entry -- #CLIENTMENU
if Parent then
if Entry and string.find(Entry.UUID,Parent.UUID,1,true) then
table.insert(matches,_uuid)
table.insert(entries,Entry )
n=n+1
end
end
end
return matches, entries, n
end
--- Find matching entries in the generic structure under a parent.
-- @param #CLIENTMENUMANAGER self
-- @param #CLIENTMENU Parent Find entries under this parent entry.
-- @return #table Table of matching #CLIENTMENU objects.
-- @return #number Number of matches
function CLIENTMENUMANAGER:FindEntriesByParent(Parent)
self:T(self.lid.."FindEntriesByParent")
local matches, objects, number = self:FindUUIDsByParent(Parent)
return objects, number
end
--- Alter the text of a leaf entry in the generic structure and push to one specific client's F10 menu.
-- @param #CLIENTMENUMANAGER self
-- @param #CLIENTMENU Entry The menu entry.
-- @param #string Text New Text of the F10 menu entry.
-- @param Wrapper.Client#CLIENT Client (optional) The client for whom to alter the entry, if nil done for all clients.
-- @return #CLIENTMENUMANAGER self
function CLIENTMENUMANAGER:ChangeEntryText(Entry, Text, Client)
self:T(self.lid.."ChangeEntryText "..Text or "None")
local newentry = CLIENTMENU:NewEntry(nil,Text,Entry.Parent,Entry.Function,unpack(Entry.Functionargs))
self:DeleteF10Entry(Entry,Client)
self:DeleteGenericEntry(Entry)
if not Entry.Parent then
self.rootentries[self.entrycount] = newentry
end
local depth = #newentry.path
if not self.menutree[depth] then self.menutree[depth] = {} end
table.insert(self.menutree[depth],newentry.UUID)
self.flattree[newentry.UUID] = newentry
self:AddEntry(newentry,Client)
return self
end
--- Push the complete menu structure to each of the clients in the set - refresh the menu tree of the clients.
-- @param #CLIENTMENUMANAGER self
-- @param Wrapper.Client#CLIENT Client (optional) If given, propagate only for this client.
-- @return #CLIENTMENU Entry
function CLIENTMENUMANAGER:Propagate(Client)
self:T(self.lid.."Propagate")
--self:I(UTILS.PrintTableToLog(Client,1))
local knownunits = {} -- track so we can ID multi seated
local Set = self.clientset.Set
if Client then
Set = {Client}
end
self:ResetMenu(Client)
for _,_client in pairs(Set) do
local client = _client -- Wrapper.Client#CLIENT
if client and client:IsAlive() then
local playerunit = client:GetName()
local playergroup = client:GetGroup()
local playername = client:GetPlayerName() or "none"
if not knownunits[playerunit] then
knownunits[playerunit] = true
else
self:I("Player in multi seat unit: "..playername)
break -- multi seat already build
end
if not self.playertree[playername] then
self.playertree[playername] = {}
end
for level,branch in pairs (self.menutree) do
self:T("Building branch:" .. level)
for _,leaf in pairs(branch) do
self:T("Building leaf:" .. leaf)
local entry = self:FindEntryByUUID(leaf)
if entry then
self:T("Found generic entry:" .. entry.UUID)
local parent = nil
if entry.Parent and entry.Parent.UUID then
parent = self.playertree[playername][entry.Parent.UUID] or self:FindEntryByUUID(entry.Parent.UUID)
end
self.playertree[playername][entry.UUID] = CLIENTMENU:NewEntry(client,entry.name,parent,entry.Function,unpack(entry.Functionargs))
self.playertree[playername][entry.UUID].Once = entry.Once
else
self:T("NO generic entry for:" .. leaf)
end
end
end
end
end
return self
end
--- Push a single previously created entry into the F10 menu structure of all clients.
-- @param #CLIENTMENUMANAGER self
-- @param #CLIENTMENU Entry The entry to add.
-- @param Wrapper.Client#CLIENT Client (optional) If given, make this change only for this client.
-- @return #CLIENTMENUMANAGER self
function CLIENTMENUMANAGER:AddEntry(Entry,Client)
self:T(self.lid.."AddEntry")
local Set = self.clientset.Set
local knownunits = {}
if Client then
Set = {Client}
end
for _,_client in pairs(Set) do
local client = _client -- Wrapper.Client#CLIENT
if client and client:IsAlive() then
local playername = client:GetPlayerName()
local unitname = client:GetName()
if not knownunits[unitname] then
knownunits[unitname] = true
else
self:I("Player in multi seat unit: "..playername)
break
end
if Entry then
self:T("Adding generic entry:" .. Entry.UUID)
local parent = nil
if not self.playertree[playername] then
self.playertree[playername] = {}
end
if Entry.Parent and Entry.Parent.UUID then
parent = self.playertree[playername][Entry.Parent.UUID] or self:FindEntryByUUID(Entry.Parent.UUID)
end
self.playertree[playername][Entry.UUID] = CLIENTMENU:NewEntry(client,Entry.name,parent,Entry.Function,unpack(Entry.Functionargs))
self.playertree[playername][Entry.UUID].Once = Entry.Once
else
self:T("NO generic entry given")
end
end
end
return self
end
--- Blank out the menu - remove **all root entries** and all entries below from the client's F10 menus, leaving the generic structure untouched.
-- @param #CLIENTMENUMANAGER self
-- @param Wrapper.Client#CLIENT Client (optional) If given, remove only for this client.
-- @return #CLIENTMENUMANAGER self
function CLIENTMENUMANAGER:ResetMenu(Client)
self:T(self.lid.."ResetMenu")
for _,_entry in pairs(self.rootentries) do
--local RootEntry = self.structure.generic[_entry]
if _entry then
self:DeleteF10Entry(_entry,Client)
end
end
return self
end
--- Blank out the menu - remove **all root entries** and all entries below from all clients' F10 menus, and **delete** the generic structure.
-- @param #CLIENTMENUMANAGER self
-- @return #CLIENTMENUMANAGER self
function CLIENTMENUMANAGER:ResetMenuComplete()
self:T(self.lid.."ResetMenuComplete")
for _,_entry in pairs(self.rootentries) do
--local RootEntry = self.structure.generic[_entry]
if _entry then
self:DeleteF10Entry(_entry)
end
end
self.playertree = nil
self.playertree = {}
self.rootentries = nil
self.rootentries = {}
self.menutree = nil
self.menutree = {}
return self
end
--- Remove the entry and all entries below the given entry from the client's F10 menus.
-- @param #CLIENTMENUMANAGER self
-- @param #CLIENTMENU Entry The entry to remove
-- @param Wrapper.Client#CLIENT Client (optional) If given, make this change only for this client.
-- @return #CLIENTMENUMANAGER self
function CLIENTMENUMANAGER:DeleteF10Entry(Entry,Client)
self:T(self.lid.."DeleteF10Entry")
local Set = self.clientset.Set
if Client then
Set = {Client}
end
for _,_client in pairs(Set) do
if _client and _client:IsAlive() then
local playername = _client:GetPlayerName()
if self.playertree[playername] then
local centry = self.playertree[playername][Entry.UUID] -- #CLIENTMENU
if centry then
--self:I("Match for "..Entry.UUID)
centry:Clear()
end
end
end
end
return self
end
--- Remove the entry and all entries below the given entry from the generic tree.
-- @param #CLIENTMENUMANAGER self
-- @param #CLIENTMENU Entry The entry to remove
-- @return #CLIENTMENUMANAGER self
function CLIENTMENUMANAGER:DeleteGenericEntry(Entry)
self:T(self.lid.."DeleteGenericEntry")
if Entry.Children and #Entry.Children > 0 then
self:RemoveGenericSubEntries(Entry)
end
local depth = #Entry.path
local uuid = Entry.UUID
local tbl = UTILS.DeepCopy(self.menutree)
if tbl[depth] then
for i=depth,#tbl do
--self:I("Level = "..i)
for _id,_uuid in pairs(tbl[i]) do
self:T(_uuid)
if string.find(_uuid,uuid,1,true) or _uuid == uuid then
--self:I("Match for ".._uuid)
self.menutree[i][_id] = nil
self.flattree[_uuid] = nil
end
end
end
end
return self
end
--- Remove all entries below the given entry from the generic tree.
-- @param #CLIENTMENUMANAGER self
-- @param #CLIENTMENU Entry The entry where to start. This entry stays.
-- @return #CLIENTMENUMANAGER self
function CLIENTMENUMANAGER:RemoveGenericSubEntries(Entry)
self:T(self.lid.."RemoveGenericSubEntries")
local depth = #Entry.path + 1
local uuid = Entry.UUID
local tbl = UTILS.DeepCopy(self.menutree)
if tbl[depth] then
for i=depth,#tbl do
self:T("Level = "..i)
for _id,_uuid in pairs(tbl[i]) do
self:T(_uuid)
if string.find(_uuid,uuid,1,true) then
self:T("Match for ".._uuid)
self.menutree[i][_id] = nil
self.flattree[_uuid] = nil
end
end
end
end
return self
end
--- Remove all entries below the given entry from the client's F10 menus.
-- @param #CLIENTMENUMANAGER self
-- @param #CLIENTMENU Entry The entry where to start. This entry stays.
-- @param Wrapper.Client#CLIENT Client (optional) If given, make this change only for this client. In this case the generic structure will not be touched.
-- @return #CLIENTMENUMANAGER self
function CLIENTMENUMANAGER:RemoveF10SubEntries(Entry,Client)
self:T(self.lid.."RemoveSubEntries")
local Set = self.clientset.Set
if Client then
Set = {Client}
end
for _,_client in pairs(Set) do
if _client and _client:IsAlive() then
local playername = _client:GetPlayerName()
if self.playertree[playername] then
local centry = self.playertree[playername][Entry.UUID] -- #CLIENTMENU
centry:RemoveSubEntries()
end
end
end
return self
end
----------------------------------------------------------------------------------------------------------------
--
-- End ClientMenu
--
----------------------------------------------------------------------------------------------------------------

View File

@@ -9,7 +9,7 @@
--
-- ## Example Missions:
--
-- Demo missions can be found on [github](https://github.com/FlightControl-Master/MOOSE_MISSIONS/tree/develop/OPS%20-%20Operation).
-- Demo missions can be found on [github](https://github.com/FlightControl-Master/MOOSE_MISSIONS/tree/develop/Core/Condition).
--
-- ===
--

View File

@@ -31,11 +31,14 @@
-- @module Core.Database
-- @image Core_Database.JPG
--- @type DATABASE
---
-- @type DATABASE
-- @field #string ClassName Name of the class.
-- @field #table Templates Templates: Units, Groups, Statics, ClientsByName, ClientsByID.
-- @field #table CLIENTS Clients.
-- @field #table STORAGES DCS warehouse storages.
-- @field #table STNS Used Link16 octal numbers for F16/15/18/AWACS planes.
-- @field #table SADL Used Link16 octal numbers for A10/C-II planes.
-- @extends Core.Base#BASE
--- Contains collections of wrapper objects defined within MOOSE that reflect objects within the simulator.
@@ -50,6 +53,7 @@
-- * PLAYERSJOINED
-- * PLAYERS
-- * CARGOS
-- * STORAGES (DCS warehouses)
--
-- On top, for internal MOOSE administration purposes, the DATABASE administers the Unit and Group TEMPLATES as defined within the Mission Editor.
--
@@ -90,6 +94,9 @@ DATABASE = {
FLIGHTCONTROLS = {},
OPSZONES = {},
PATHLINES = {},
STORAGES = {},
STNS={},
SADL={},
}
local _DATABASECoalition =
@@ -123,6 +130,8 @@ function DATABASE:New()
self:SetEventPriority( 1 )
self:HandleEvent( EVENTS.Birth, self._EventOnBirth )
-- DCS 2.9 fixed CA event for players -- TODO: reset unit when leaving
self:HandleEvent( EVENTS.PlayerEnterUnit, self._EventOnPlayerEnterUnit )
self:HandleEvent( EVENTS.Dead, self._EventOnDeadOrCrash )
self:HandleEvent( EVENTS.Crash, self._EventOnDeadOrCrash )
self:HandleEvent( EVENTS.RemoveUnit, self._EventOnDeadOrCrash )
@@ -246,6 +255,38 @@ function DATABASE:FindAirbase( AirbaseName )
end
--- Adds a STORAGE (DCS warehouse wrapper) based on the Airbase Name to the DATABASE.
-- @param #DATABASE self
-- @param #string AirbaseName The name of the airbase.
-- @return Wrapper.Storage#STORAGE Storage object.
function DATABASE:AddStorage( AirbaseName )
if not self.STORAGES[AirbaseName] then
self.STORAGES[AirbaseName] = STORAGE:New( AirbaseName )
end
return self.STORAGES[AirbaseName]
end
--- Deletes a STORAGE from the DATABASE based on the name of the associated airbase.
-- @param #DATABASE self
-- @param #string AirbaseName The name of the airbase.
function DATABASE:DeleteStorage( AirbaseName )
self.STORAGES[AirbaseName] = nil
end
--- Finds an STORAGE based on the name of the associated airbase.
-- @param #DATABASE self
-- @param #string AirbaseName Name of the airbase.
-- @return Wrapper.Storage#STORAGE The found STORAGE.
function DATABASE:FindStorage( AirbaseName )
local storage = self.STORAGES[AirbaseName]
return storage
end
do -- Zones and Pathlines
--- Finds a @{Core.Zone} based on the zone name.
@@ -412,10 +453,10 @@ do -- Zones and Pathlines
-- Loop over layers.
for layerID, layerData in pairs(env.mission.drawings.layers or {}) do
-- Loop over objects in layers.
for objectID, objectData in pairs(layerData.objects or {}) do
-- Check for polygon which has at least 4 points (we would need 3 but the origin seems to be there twice)
if objectData.polygonMode and (objectData.polygonMode=="free") and objectData.points and #objectData.points>=4 then
@@ -451,10 +492,32 @@ do -- Zones and Pathlines
-- Create new polygon zone.
local Zone=ZONE_POLYGON:NewFromPointsArray(ZoneName, points)
--Zone.DrawID = objectID
-- Set color.
Zone:SetColor({1, 0, 0}, 0.15)
Zone:SetFillColor({1, 0, 0}, 0.15)
if objectData.colorString then
-- eg colorString = 0xff0000ff
local color = string.gsub(objectData.colorString,"^0x","")
local r = tonumber(string.sub(color,1,2),16)/255
local g = tonumber(string.sub(color,3,4),16)/255
local b = tonumber(string.sub(color,5,6),16)/255
local a = tonumber(string.sub(color,7,8),16)/255
Zone:SetColor({r, g, b}, a)
end
if objectData.fillColorString then
-- eg fillColorString = 0xff00004b
local color = string.gsub(objectData.colorString,"^0x","")
local r = tonumber(string.sub(color,1,2),16)/255
local g = tonumber(string.sub(color,3,4),16)/255
local b = tonumber(string.sub(color,5,6),16)/255
local a = tonumber(string.sub(color,7,8),16)/255
Zone:SetFillColor({r, g, b}, a)
end
-- Store in DB.
self.ZONENAMES[ZoneName] = ZoneName
@@ -495,7 +558,26 @@ do -- Zones and Pathlines
-- Set color.
Zone:SetColor({1, 0, 0}, 0.15)
if objectData.colorString then
-- eg colorString = 0xff0000ff
local color = string.gsub(objectData.colorString,"^0x","")
local r = tonumber(string.sub(color,1,2),16)/255
local g = tonumber(string.sub(color,3,4),16)/255
local b = tonumber(string.sub(color,5,6),16)/255
local a = tonumber(string.sub(color,7,8),16)/255
Zone:SetColor({r, g, b}, a)
end
if objectData.fillColorString then
-- eg fillColorString = 0xff00004b
local color = string.gsub(objectData.colorString,"^0x","")
local r = tonumber(string.sub(color,1,2),16)/255
local g = tonumber(string.sub(color,3,4),16)/255
local b = tonumber(string.sub(color,5,6),16)/255
local a = tonumber(string.sub(color,7,8),16)/255
Zone:SetFillColor({r, g, b}, a)
end
-- Store in DB.
self.ZONENAMES[ZoneName] = ZoneName
@@ -645,7 +727,7 @@ do -- cargo
--- Finds an CARGO based on the CargoName.
-- @param #DATABASE self
-- @param #string CargoName
-- @return Wrapper.Cargo#CARGO The found CARGO.
-- @return Cargo.Cargo#CARGO The found CARGO.
function DATABASE:FindCargo( CargoName )
local CargoFound = self.CARGOS[CargoName]
@@ -719,7 +801,7 @@ end -- cargo
--- Finds a CLIENT based on the ClientName.
-- @param #DATABASE self
-- @param #string ClientName
-- @param #string ClientName - Note this is the UNIT name of the client!
-- @return Wrapper.Client#CLIENT The found CLIENT.
function DATABASE:FindClient( ClientName )
@@ -775,6 +857,7 @@ function DATABASE:AddPlayer( UnitName, PlayerName )
self.PLAYERUNITS[PlayerName] = self:FindUnit( UnitName )
self.PLAYERSJOINED[PlayerName] = PlayerName
end
end
--- Deletes a player from the DATABASE based on the Player Name.
@@ -849,7 +932,7 @@ function DATABASE:Spawn( SpawnTemplate )
SpawnTemplate.CountryID = nil
SpawnTemplate.CategoryID = nil
self:_RegisterGroupTemplate( SpawnTemplate, SpawnCoalitionID, SpawnCategoryID, SpawnCountryID )
self:_RegisterGroupTemplate( SpawnTemplate, SpawnCoalitionID, SpawnCategoryID, SpawnCountryID, SpawnTemplate.name )
self:T3( SpawnTemplate )
coalition.addGroup( SpawnCountryID, SpawnCategoryID, SpawnTemplate )
@@ -926,7 +1009,7 @@ function DATABASE:_RegisterGroupTemplate( GroupTemplate, CoalitionSide, Category
self.Templates.Groups[GroupTemplateName].CategoryID = CategoryID
self.Templates.Groups[GroupTemplateName].CoalitionID = CoalitionSide
self.Templates.Groups[GroupTemplateName].CountryID = CountryID
local UnitNames = {}
for unit_num, UnitTemplate in pairs( GroupTemplate.units ) do
@@ -950,10 +1033,31 @@ function DATABASE:_RegisterGroupTemplate( GroupTemplate, CoalitionSide, Category
self.Templates.ClientsByName[UnitTemplate.name].CountryID = CountryID
self.Templates.ClientsByID[UnitTemplate.unitId] = UnitTemplate
end
if UnitTemplate.AddPropAircraft then
if UnitTemplate.AddPropAircraft.STN_L16 then
local stn = UTILS.OctalToDecimal(UnitTemplate.AddPropAircraft.STN_L16)
if stn == nil or stn < 1 then
self:E("WARNING: Invalid STN "..tostring(UnitTemplate.AddPropAircraft.STN_L16).." for ".. UnitTemplate.name)
else
self.STNS[stn] = UnitTemplate.name
self:I("Register STN "..tostring(UnitTemplate.AddPropAircraft.STN_L16).." for ".. UnitTemplate.name)
end
end
if UnitTemplate.AddPropAircraft.SADL_TN then
local sadl = UTILS.OctalToDecimal(UnitTemplate.AddPropAircraft.SADL_TN)
if sadl == nil or sadl < 1 then
self:E("WARNING: Invalid SADL "..tostring(UnitTemplate.AddPropAircraft.SADL_TN).." for ".. UnitTemplate.name)
else
self.SADL[sadl] = UnitTemplate.name
self:I("Register SADL "..tostring(UnitTemplate.AddPropAircraft.SADL_TN).." for ".. UnitTemplate.name)
end
end
end
UnitNames[#UnitNames+1] = self.Templates.Units[UnitTemplate.name].UnitName
end
-- Debug info.
self:T( { Group = self.Templates.Groups[GroupTemplateName].GroupName,
Coalition = self.Templates.Groups[GroupTemplateName].CoalitionID,
@@ -964,6 +1068,80 @@ function DATABASE:_RegisterGroupTemplate( GroupTemplate, CoalitionSide, Category
)
end
--- Get next (consecutive) free STN as octal number.
-- @param #DATABASE self
-- @param #number octal Starting octal.
-- @param #string unitname Name of the associated unit.
-- @return #number Octal
function DATABASE:GetNextSTN(octal,unitname)
local first = UTILS.OctalToDecimal(octal) or 0
if self.STNS[first] == unitname then return octal end
local nextoctal = 77777
local found = false
if 32767-first < 10 then
first = 0
end
for i=first+1,32767 do
if self.STNS[i] == nil then
found = true
nextoctal = UTILS.DecimalToOctal(i)
self.STNS[i] = unitname
self:T("Register STN "..tostring(nextoctal).." for ".. unitname)
break
end
end
if not found then
self:E(string.format("WARNING: No next free STN past %05d found!",octal))
-- cleanup
local NewSTNS = {}
for _id,_name in pairs(self.STNS) do
if self.UNITS[_name] ~= nil then
NewSTNS[_id] = _name
end
end
self.STNS = nil
self.STNS = NewSTNS
end
return nextoctal
end
--- Get next (consecutive) free SADL as octal number.
-- @param #DATABASE self
-- @param #number octal Starting octal.
-- @param #string unitname Name of the associated unit.
-- @return #number Octal
function DATABASE:GetNextSADL(octal,unitname)
local first = UTILS.OctalToDecimal(octal) or 0
if self.SADL[first] == unitname then return octal end
local nextoctal = 7777
local found = false
if 4095-first < 10 then
first = 0
end
for i=first+1,4095 do
if self.STNS[i] == nil then
found = true
nextoctal = UTILS.DecimalToOctal(i)
self.SADL[i] = unitname
self:T("Register SADL "..tostring(nextoctal).." for ".. unitname)
break
end
end
if not found then
self:E(string.format("WARNING: No next free SADL past %04d found!",octal))
-- cleanup
local NewSTNS = {}
for _id,_name in pairs(self.SADL) do
if self.UNITS[_name] ~= nil then
NewSTNS[_id] = _name
end
end
self.SADL = nil
self.SADL = NewSTNS
end
return nextoctal
end
--- Get group template.
-- @param #DATABASE self
-- @param #string GroupName Group name.
@@ -1124,7 +1302,7 @@ end
-- @param #string AirbaseName Name of the airbase.
-- @return #number Category.
function DATABASE:GetCategoryFromAirbase( AirbaseName )
return self.AIRBASES[AirbaseName]:GetCategory()
return self.AIRBASES[AirbaseName]:GetAirbaseCategory()
end
@@ -1264,9 +1442,17 @@ function DATABASE:_RegisterAirbase(airbase)
-- Unique ID.
local airbaseUID=airbase:GetID(true)
local typename = airbase:GetTypeName()
local category = airbase.category
if category == Airbase.Category.SHIP and typename == "FARP_SINGLE_01" then
category = Airbase.Category.HELIPAD
end
-- Debug output.
local text=string.format("Register %s: %s (UID=%d), Runways=%d, Parking=%d [", AIRBASE.CategoryName[airbase.category], tostring(DCSAirbaseName), airbaseUID, #airbase.runways, airbase.NparkingTotal)
local text=string.format("Register %s: %s (UID=%d), Runways=%d, Parking=%d [", AIRBASE.CategoryName[category], tostring(DCSAirbaseName), airbaseUID, #airbase.runways, airbase.NparkingTotal)
for _,terminalType in pairs(AIRBASE.TerminalType) do
if airbase.NparkingTerminal and airbase.NparkingTerminal[terminalType] then
text=text..string.format("%d=%d ", terminalType, airbase.NparkingTerminal[terminalType])
@@ -1333,7 +1519,7 @@ function DATABASE:_EventOnBirth( Event )
if PlayerName then
-- Debug info.
self:I(string.format("Player '%s' joint unit '%s' of group '%s'", tostring(PlayerName), tostring(Event.IniDCSUnitName), tostring(Event.IniDCSGroupName)))
self:I(string.format("Player '%s' joined unit '%s' of group '%s'", tostring(PlayerName), tostring(Event.IniDCSUnitName), tostring(Event.IniDCSGroupName)))
-- Add client in case it does not exist already.
if not client then
@@ -1435,39 +1621,43 @@ function DATABASE:_EventOnDeadOrCrash( Event )
end
--- Handles the OnPlayerEnterUnit event to fill the active players table (with the unit filter applied).
--- Handles the OnPlayerEnterUnit event to fill the active players table for CA units (with the unit filter applied).
-- @param #DATABASE self
-- @param Core.Event#EVENTDATA Event
function DATABASE:_EventOnPlayerEnterUnit( Event )
self:F2( { Event } )
if Event.IniDCSUnit then
if Event.IniObjectCategory == 1 then
-- Player entering a CA slot
if Event.IniObjectCategory == 1 and Event.IniGroup and Event.IniGroup:IsGround() then
local IsPlayer = Event.IniDCSUnit:getPlayerName()
if IsPlayer then
-- Add unit.
self:AddUnit( Event.IniDCSUnitName )
-- Debug info.
self:I(string.format("Player '%s' joined GROUND unit '%s' of group '%s'", tostring(Event.IniPlayerName), tostring(Event.IniDCSUnitName), tostring(Event.IniDCSGroupName)))
local client= self.CLIENTS[Event.IniDCSUnitName] --Wrapper.Client#CLIENT
-- Add client in case it does not exist already.
if not client then
client=self:AddClient(Event.IniDCSUnitName)
end
-- Add player.
client:AddPlayer(Event.IniPlayerName)
-- Ini unit.
Event.IniUnit = self:FindUnit( Event.IniDCSUnitName )
-- Add group.
self:AddGroup( Event.IniDCSGroupName )
-- Get player unit.
local PlayerName = Event.IniDCSUnit:getPlayerName()
if PlayerName then
if not self.PLAYERS[PlayerName] then
self:AddPlayer( Event.IniDCSUnitName, PlayerName )
-- Add player.
if not self.PLAYERS[Event.IniPlayerName] then
self:AddPlayer( Event.IniUnitName, Event.IniPlayerName )
end
local Settings = SETTINGS:Set( PlayerName )
Settings:SetPlayerMenu( Event.IniUnit )
-- Player settings.
local Settings = SETTINGS:Set( Event.IniPlayerName )
Settings:SetPlayerMenu(Event.IniUnit)
else
self:E("ERROR: getPlayerName() returned nil for event PlayerEnterUnit")
end
end
end
end
@@ -1478,15 +1668,26 @@ end
-- @param Core.Event#EVENTDATA Event
function DATABASE:_EventOnPlayerLeaveUnit( Event )
self:F2( { Event } )
local function FindPlayerName(UnitName)
local playername = nil
for _name,_unitname in pairs(self.PLAYERS) do
if _unitname == UnitName then
playername = _name
break
end
end
return playername
end
if Event.IniUnit then
if Event.IniObjectCategory == 1 then
-- Try to get the player name. This can be buggy for multicrew aircraft!
local PlayerName = Event.IniUnit:GetPlayerName()
if PlayerName then --and self.PLAYERS[PlayerName] then
local PlayerName = Event.IniPlayerName or Event.IniUnit:GetPlayerName() or FindPlayerName(Event.IniUnitName)
if PlayerName then
-- Debug info.
self:I(string.format("Player '%s' left unit %s", tostring(PlayerName), tostring(Event.IniUnitName)))
@@ -1799,7 +2000,7 @@ end
--- Add a flight control to the data base.
-- @param #DATABASE self
-- @param Ops.FlightControl#FLIGHTCONTROL flightcontrol
-- @param OPS.FlightControl#FLIGHTCONTROL flightcontrol
function DATABASE:AddFlightControl(flightcontrol)
self:F2( { flightcontrol } )
self.FLIGHTCONTROLS[flightcontrol.airbasename]=flightcontrol
@@ -1808,18 +2009,18 @@ end
--- Get a flight control object from the data base.
-- @param #DATABASE self
-- @param #string airbasename Name of the associated airbase.
-- @return Ops.FlightControl#FLIGHTCONTROL The FLIGHTCONTROL object.s
-- @return OPS.FlightControl#FLIGHTCONTROL The FLIGHTCONTROL object.s
function DATABASE:GetFlightControl(airbasename)
return self.FLIGHTCONTROLS[airbasename]
end
--- @param #DATABASE self
-- @param #DATABASE self
function DATABASE:_RegisterTemplates()
self:F2()
self.Navpoints = {}
self.UNITS = {}
--Build routines.db.units and self.Navpoints
--Build self.Navpoints
for CoalitionName, coa_data in pairs(env.mission.coalition) do
self:T({CoalitionName=CoalitionName})
@@ -1841,7 +2042,7 @@ function DATABASE:_RegisterTemplates()
for nav_ind, nav_data in pairs(coa_data.nav_points) do
if type(nav_data) == 'table' then
self.Navpoints[CoalitionName][nav_ind] = routines.utils.deepCopy(nav_data)
self.Navpoints[CoalitionName][nav_ind] = UTILS.DeepCopy(nav_data)
self.Navpoints[CoalitionName][nav_ind]['name'] = nav_data.callsignStr -- name is a little bit more self-explanatory.
self.Navpoints[CoalitionName][nav_ind]['point'] = {} -- point is used by SSE, support it.
@@ -1880,7 +2081,7 @@ function DATABASE:_RegisterTemplates()
for group_num, Template in pairs(obj_type_data.group) do
if obj_type_name ~= "static" and Template and Template.units and type(Template.units) == 'table' then --making sure again- this is a valid group
self:_RegisterGroupTemplate(Template, CoalitionSide, _DATABASECategory[string.lower(CategoryName)], CountryID)
else
@@ -1970,8 +2171,6 @@ end
TargetPlayerName = Event.IniPlayerName
TargetCoalition = Event.IniCoalition
--TargetCategory = TargetUnit:getCategory()
--TargetCategory = TargetUnit:getDesc().category -- Workaround
TargetCategory = Event.IniCategory
TargetType = Event.IniTypeName

View File

@@ -173,7 +173,8 @@
-- @image Core_Event.JPG
--- @type EVENT
---
-- @type EVENT
-- @field #EVENT.Events Events
-- @extends Core.Base#BASE
@@ -260,6 +261,15 @@ EVENTS = {
SimulationStart = world.event.S_EVENT_SIMULATION_START or -1,
WeaponRearm = world.event.S_EVENT_WEAPON_REARM or -1,
WeaponDrop = world.event.S_EVENT_WEAPON_DROP or -1,
-- Added with DCS 2.9.0
UnitTaskTimeout = world.event.S_EVENT_UNIT_TASK_TIMEOUT or -1,
UnitTaskStage = world.event.S_EVENT_UNIT_TASK_STAGE or -1,
MacSubtaskScore = world.event.S_EVENT_MAC_SUBTASK_SCORE or -1,
MacExtraScore = world.event.S_EVENT_MAC_EXTRA_SCORE or -1,
MissionRestart = world.event.S_EVENT_MISSION_RESTART or -1,
MissionWinner = world.event.S_EVENT_MISSION_WINNER or -1,
PostponedTakeoff = world.event.S_EVENT_POSTPONED_TAKEOFF or -1,
PostponedLand = world.event.S_EVENT_POSTPONED_LAND or -1,
}
--- The Event structure
@@ -282,6 +292,7 @@ EVENTS = {
-- @field Wrapper.Group#GROUP IniGroup (UNIT) The initiating MOOSE wrapper @{Wrapper.Group#GROUP} of the initiator Group object.
-- @field #string IniGroupName UNIT) The initiating GROUP name (same as IniDCSGroupName).
-- @field #string IniPlayerName (UNIT) The name of the initiating player in case the Unit is a client or player slot.
-- @field #string IniPlayerUCID (UNIT) The UCID of the initiating player in case the Unit is a client or player slot and on a multi-player server.
-- @field DCS#coalition.side IniCoalition (UNIT) The coalition of the initiator.
-- @field DCS#Unit.Category IniCategory (UNIT) The category of the initiator.
-- @field #string IniTypeName (UNIT) The type name of the initiator.
@@ -297,6 +308,7 @@ EVENTS = {
-- @field Wrapper.Group#GROUP TgtGroup (UNIT) The target MOOSE wrapper @{Wrapper.Group#GROUP} of the target Group object.
-- @field #string TgtGroupName (UNIT) The target GROUP name (same as TgtDCSGroupName).
-- @field #string TgtPlayerName (UNIT) The name of the target player in case the Unit is a client or player slot.
-- @field #string TgtPlayerUCID (UNIT) The UCID of the target player in case the Unit is a client or player slot and on a multi-player server.
-- @field DCS#coalition.side TgtCoalition (UNIT) The coalition of the target.
-- @field DCS#Unit.Category TgtCategory (UNIT) The category of the target.
-- @field #string TgtTypeName (UNIT) The type name of the target.
@@ -313,7 +325,7 @@ EVENTS = {
-- @field Cargo.Cargo#CARGO Cargo The cargo object.
-- @field #string CargoName The name of the cargo object.
--
-- @field Core.ZONE#ZONE Zone The zone object.
-- @field Core.Zone#ZONE Zone The zone object.
-- @field #string ZoneName The name of the zone.
@@ -633,6 +645,55 @@ local _EVENTMETA = {
Event = "OnEventWeaponDrop",
Text = "S_EVENT_WEAPON_DROP"
},
-- DCS 2.9
[EVENTS.UnitTaskTimeout] = {
Order = 1,
Side = "I",
Event = "OnEventUnitTaskTimeout",
Text = "S_EVENT_UNIT_TASK_TIMEOUT "
},
[EVENTS.UnitTaskStage] = {
Order = 1,
Side = "I",
Event = "OnEventUnitTaskStage",
Text = "S_EVENT_UNIT_TASK_STAGE "
},
[EVENTS.MacSubtaskScore] = {
Order = 1,
Side = "I",
Event = "OnEventMacSubtaskScore",
Text = "S_EVENT_MAC_SUBTASK_SCORE"
},
[EVENTS.MacExtraScore] = {
Order = 1,
Side = "I",
Event = "OnEventMacExtraScore",
Text = "S_EVENT_MAC_EXTRA_SCOREP"
},
[EVENTS.MissionRestart] = {
Order = 1,
Side = "I",
Event = "OnEventMissionRestart",
Text = "S_EVENT_MISSION_RESTART"
},
[EVENTS.MissionWinner] = {
Order = 1,
Side = "I",
Event = "OnEventMissionWinner",
Text = "S_EVENT_MISSION_WINNER"
},
[EVENTS.PostponedTakeoff] = {
Order = 1,
Side = "I",
Event = "OnEventPostponedTakeoff",
Text = "S_EVENT_POSTPONED_TAKEOFF"
},
[EVENTS.PostponedLand] = {
Order = 1,
Side = "I",
Event = "OnEventPostponedLand",
Text = "S_EVENT_POSTPONED_LAND"
},
}
--- The Events structure
@@ -988,7 +1049,7 @@ do -- Event Creation
--- Creation of a New ZoneGoal Event.
-- @param #EVENT self
-- @param Core.Functional#ZONE_GOAL ZoneGoal The ZoneGoal created.
-- @param Functional.ZoneGoal#ZONE_GOAL ZoneGoal The ZoneGoal created.
function EVENT:CreateEventNewZoneGoal( ZoneGoal )
self:F( { ZoneGoal } )
@@ -1080,9 +1141,9 @@ function EVENT:onEvent( Event )
if Event.initiator then
Event.IniObjectCategory = Event.initiator:getCategory()
Event.IniObjectCategory = Object.getCategory(Event.initiator)
if Event.IniObjectCategory == Object.Category.STATIC then
if Event.IniObjectCategory == Object.Category.STATIC then
---
-- Static
---
@@ -1118,10 +1179,9 @@ function EVENT:onEvent( Event )
local Unit=UNIT:FindByName(Event.IniDCSUnitName)
if Unit then
Event.IniObjectCategory = Object.Category.UNIT
end
end
end
if Event.IniObjectCategory == Object.Category.UNIT then
elseif Event.IniObjectCategory == Object.Category.UNIT then
---
-- Unit
---
@@ -1144,12 +1204,19 @@ function EVENT:onEvent( Event )
end
Event.IniPlayerName = Event.IniDCSUnit:getPlayerName()
if Event.IniPlayerName then
-- get UUCID
local PID = NET.GetPlayerIDByName(nil,Event.IniPlayerName)
if PID then
Event.IniPlayerUCID = net.get_player_info(tonumber(PID), 'ucid')
--env.info("Event.IniPlayerUCID="..tostring(Event.IniPlayerUCID),false)
end
end
Event.IniCoalition = Event.IniDCSUnit:getCoalition()
Event.IniTypeName = Event.IniDCSUnit:getTypeName()
Event.IniCategory = Event.IniDCSUnit:getDesc().category
end
if Event.IniObjectCategory == Object.Category.CARGO then
elseif Event.IniObjectCategory == Object.Category.CARGO then
---
-- Cargo
---
@@ -1160,9 +1227,8 @@ function EVENT:onEvent( Event )
Event.IniCoalition = Event.IniDCSUnit:getCoalition()
Event.IniCategory = Event.IniDCSUnit:getDesc().category
Event.IniTypeName = Event.IniDCSUnit:getTypeName()
end
if Event.IniObjectCategory == Object.Category.SCENERY then
elseif Event.IniObjectCategory == Object.Category.SCENERY then
---
-- Scenery
---
@@ -1172,9 +1238,8 @@ function EVENT:onEvent( Event )
Event.IniUnit = SCENERY:Register( Event.IniDCSUnitName, Event.initiator )
Event.IniCategory = Event.IniDCSUnit:getDesc().category
Event.IniTypeName = Event.initiator:isExist() and Event.IniDCSUnit:getTypeName() or "SCENERY"
end
if Event.IniObjectCategory == Object.Category.BASE then
elseif Event.IniObjectCategory == Object.Category.BASE then
---
-- Base Object
---
@@ -1201,9 +1266,12 @@ function EVENT:onEvent( Event )
---
-- Target category.
Event.TgtObjectCategory = Event.target:getCategory()
Event.TgtObjectCategory = Object.getCategory(Event.target)
if Event.TgtObjectCategory == Object.Category.UNIT then
---
-- UNIT
---
Event.TgtDCSUnit = Event.target
Event.TgtDCSGroup = Event.TgtDCSUnit:getGroup()
Event.TgtDCSUnitName = Event.TgtDCSUnit:getName()
@@ -1216,21 +1284,33 @@ function EVENT:onEvent( Event )
Event.TgtGroupName = Event.TgtDCSGroupName
end
Event.TgtPlayerName = Event.TgtDCSUnit:getPlayerName()
if Event.TgtPlayerName then
-- get UUCID
local PID = NET.GetPlayerIDByName(nil,Event.TgtPlayerName)
if PID then
Event.TgtPlayerUCID = net.get_player_info(tonumber(PID), 'ucid')
--env.info("Event.TgtPlayerUCID="..tostring(Event.TgtPlayerUCID),false)
end
end
Event.TgtCoalition = Event.TgtDCSUnit:getCoalition()
Event.TgtCategory = Event.TgtDCSUnit:getDesc().category
Event.TgtTypeName = Event.TgtDCSUnit:getTypeName()
end
if Event.TgtObjectCategory == Object.Category.STATIC then
-- get base data
elseif Event.TgtObjectCategory == Object.Category.STATIC then
---
-- STATIC
---
Event.TgtDCSUnit = Event.target
if Event.target:isExist() and Event.id ~= 33 then -- leave out ejected seat object
Event.TgtDCSUnitName = Event.TgtDCSUnit:getName()
Event.TgtUnitName = Event.TgtDCSUnitName
Event.TgtUnit = STATIC:FindByName( Event.TgtDCSUnitName, false )
Event.TgtCoalition = Event.TgtDCSUnit:getCoalition()
Event.TgtCategory = Event.TgtDCSUnit:getDesc().category
Event.TgtTypeName = Event.TgtDCSUnit:getTypeName()
-- Workaround for borked target info on cruise missiles
if Event.TgtDCSUnitName and Event.TgtDCSUnitName ~= "" then
Event.TgtUnitName = Event.TgtDCSUnitName
Event.TgtUnit = STATIC:FindByName( Event.TgtDCSUnitName, false )
Event.TgtCoalition = Event.TgtDCSUnit:getCoalition()
Event.TgtCategory = Event.TgtDCSUnit:getDesc().category
Event.TgtTypeName = Event.TgtDCSUnit:getTypeName()
end
else
Event.TgtDCSUnitName = string.format("No target object for Event ID %s", tostring(Event.id))
Event.TgtUnitName = Event.TgtDCSUnitName
@@ -1249,9 +1329,11 @@ function EVENT:onEvent( Event )
Event.TgtTypeName = "Static"
end
end
end
if Event.TgtObjectCategory == Object.Category.SCENERY then
elseif Event.TgtObjectCategory == Object.Category.SCENERY then
---
-- SCENERY
---
Event.TgtDCSUnit = Event.target
Event.TgtDCSUnitName = Event.TgtDCSUnit:getName()
Event.TgtUnitName = Event.TgtDCSUnitName
@@ -1266,7 +1348,8 @@ function EVENT:onEvent( Event )
Event.Weapon = Event.weapon
Event.WeaponName = Event.Weapon:getTypeName()
Event.WeaponUNIT = CLIENT:Find( Event.Weapon, '', true ) -- Sometimes, the weapon is a player unit!
Event.WeaponPlayerName = Event.WeaponUNIT and Event.Weapon:getPlayerName()
Event.WeaponPlayerName = Event.WeaponUNIT and Event.Weapon.getPlayerName and Event.Weapon:getPlayerName()
--Event.WeaponPlayerName = Event.WeaponUNIT and Event.Weapon:getPlayerName()
Event.WeaponCoalition = Event.WeaponUNIT and Event.Weapon:getCoalition()
Event.WeaponCategory = Event.WeaponUNIT and Event.Weapon:getDesc().category
Event.WeaponTypeName = Event.WeaponUNIT and Event.Weapon:getTypeName()
@@ -1281,7 +1364,7 @@ function EVENT:onEvent( Event )
-- However, this is not a big thing, as the aircraft the pilot ejected from is usually long crashed before the ejected pilot touches the ground.
--Event.Place=UNIT:Find(Event.place)
else
if Event.place:isExist() and Event.place:getCategory() ~= Object.Category.SCENERY then
if Event.place:isExist() and Object.getCategory(Event.place) ~= Object.Category.SCENERY then
Event.Place=AIRBASE:Find(Event.place)
Event.PlaceName=Event.Place:GetName()
end
@@ -1295,6 +1378,7 @@ function EVENT:onEvent( Event )
Event.MarkCoordinate=COORDINATE:NewFromVec3(Event.pos)
Event.MarkText=Event.text
Event.MarkCoalition=Event.coalition
Event.IniCoalition=Event.coalition
Event.MarkGroupID = Event.groupID
end

View File

@@ -249,7 +249,7 @@ do -- FSM
--
-- ### Linear Transition Example
--
-- This example is fully implemented in the MOOSE test mission on GITHUB: [FSM-100 - Transition Explanation](https://github.com/FlightControl-Master/MOOSE/blob/master/Moose%20Test%20Missions/FSM%20-%20Finite%20State%20Machine/FSM-100%20-%20Transition%20Explanation/FSM-100%20-%20Transition%20Explanation.lua)
-- This example is fully implemented in the MOOSE test mission on GitHub: [FSM-100 - Transition Explanation](https://github.com/FlightControl-Master/MOOSE_MISSIONS/tree/master/Core/FSM/FSM-100%20-%20Transition%20Explanation)
--
-- It models a unit standing still near Batumi, and flaring every 5 seconds while switching between a Green flare and a Red flare.
-- The purpose of this example is not to show how exciting flaring is, but it demonstrates how a Linear Transition FSM can be build.
@@ -1260,7 +1260,7 @@ do -- FSM_PROCESS
--- Assign the process to a @{Wrapper.Unit} and activate the process.
-- @param #FSM_PROCESS self
-- @param Task.Tasking#TASK Task
-- @param Tasking.Task#TASK Task
-- @param Wrapper.Unit#UNIT ProcessUnit
-- @return #FSM_PROCESS self
function FSM_PROCESS:Assign( ProcessUnit, Task )

View File

@@ -17,7 +17,7 @@
-- ### Author: **Applevangelist**
--
-- Date: 5 May 2021
-- Last Update: Feb 2023
-- Last Update: Mar 2023
--
-- ===
---
@@ -50,7 +50,7 @@ MARKEROPS_BASE = {
ClassName = "MARKEROPS",
Tag = "mytag",
Keywords = {},
version = "0.1.1",
version = "0.1.3",
debug = false,
Casesensitive = true,
}
@@ -114,6 +114,8 @@ function MARKEROPS_BASE:New(Tagname,Keywords,Casesensitive)
-- @param #string Text The text on the marker
-- @param #table Keywords Table of matching keywords found in the Event text
-- @param Core.Point#COORDINATE Coord Coordinate of the marker.
-- @param #number MarkerID Id of this marker
-- @param #number CoalitionNumber Coalition of the marker creator
--- On after "MarkChanged" event. Triggered when a Marker is changed on the F10 map.
-- @function [parent=#MARKEROPS_BASE] OnAfterMarkChanged
@@ -124,7 +126,8 @@ function MARKEROPS_BASE:New(Tagname,Keywords,Casesensitive)
-- @param #string Text The text on the marker
-- @param #table Keywords Table of matching keywords found in the Event text
-- @param Core.Point#COORDINATE Coord Coordinate of the marker.
-- @param #number idx DCS Marker ID
-- @param #number MarkerID Id of this marker
-- @param #number CoalitionNumber Coalition of the marker creator
--- On after "MarkDeleted" event. Triggered when a Marker is deleted from the F10 map.
-- @function [parent=#MARKEROPS_BASE] OnAfterMarkDeleted
@@ -133,7 +136,7 @@ function MARKEROPS_BASE:New(Tagname,Keywords,Casesensitive)
-- @param #string Event The Event called
-- @param #string To The To state
--- "Stop" trigger. Used to stop the function an unhandle events
--- "Stop" trigger. Used to stop the function an unhandle events
-- @function [parent=#MARKEROPS_BASE] Stop
end
@@ -155,29 +158,30 @@ function MARKEROPS_BASE:OnEventMark(Event)
local text = tostring(Event.text)
local m = MESSAGE:New(string.format("Mark added at %s with text: %s",coordtext,text),10,"Info",false):ToAll()
end
local coalition = Event.MarkCoalition
-- decision
if Event.id==world.event.S_EVENT_MARK_ADDED then
self:T({event="S_EVENT_MARK_ADDED", carrier=self.groupname, vec3=Event.pos})
self:T({event="S_EVENT_MARK_ADDED", carrier=Event.IniGroupName, vec3=Event.pos})
-- Handle event
local Eventtext = tostring(Event.text)
if Eventtext~=nil then
if self:_MatchTag(Eventtext) then
local matchtable = self:_MatchKeywords(Eventtext)
self:MarkAdded(Eventtext,matchtable,coord)
self:MarkAdded(Eventtext,matchtable,coord,Event.idx,coalition)
end
end
elseif Event.id==world.event.S_EVENT_MARK_CHANGE then
self:T({event="S_EVENT_MARK_CHANGE", carrier=self.groupname, vec3=Event.pos})
self:T({event="S_EVENT_MARK_CHANGE", carrier=Event.IniGroupName, vec3=Event.pos})
-- Handle event.
local Eventtext = tostring(Event.text)
if Eventtext~=nil then
if self:_MatchTag(Eventtext) then
local matchtable = self:_MatchKeywords(Eventtext)
self:MarkChanged(Eventtext,matchtable,coord,Event.idx)
self:MarkChanged(Eventtext,matchtable,coord,Event.idx,coalition)
end
end
elseif Event.id==world.event.S_EVENT_MARK_REMOVED then
self:T({event="S_EVENT_MARK_REMOVED", carrier=self.groupname, vec3=Event.pos})
self:T({event="S_EVENT_MARK_REMOVED", carrier=Event.IniGroupName, vec3=Event.pos})
-- Hande event.
local Eventtext = tostring(Event.text)
if Eventtext~=nil then
@@ -230,8 +234,10 @@ end
-- @param #string To The To state
-- @param #string Text The text on the marker
-- @param #table Keywords Table of matching keywords found in the Event text
-- @param #number MarkerID Id of this marker
-- @param #number CoalitionNumber Coalition of the marker creator
-- @param Core.Point#COORDINATE Coord Coordinate of the marker.
function MARKEROPS_BASE:onbeforeMarkAdded(From,Event,To,Text,Keywords,Coord)
function MARKEROPS_BASE:onbeforeMarkAdded(From,Event,To,Text,Keywords,Coord,MarkerID,CoalitionNumber)
self:T({self.lid,From,Event,To,Text,Keywords,Coord:ToStringLLDDM()})
end
@@ -242,8 +248,10 @@ end
-- @param #string To The To state
-- @param #string Text The text on the marker
-- @param #table Keywords Table of matching keywords found in the Event text
-- @param #number MarkerID Id of this marker
-- @param #number CoalitionNumber Coalition of the marker creator
-- @param Core.Point#COORDINATE Coord Coordinate of the marker.
function MARKEROPS_BASE:onbeforeMarkChanged(From,Event,To,Text,Keywords,Coord)
function MARKEROPS_BASE:onbeforeMarkChanged(From,Event,To,Text,Keywords,Coord,MarkerID,CoalitionNumber)
self:T({self.lid,From,Event,To,Text,Keywords,Coord:ToStringLLDDM()})
end

View File

@@ -513,7 +513,7 @@ do -- MENU_COALITION
--- @type MENU_COALITION
-- @extends Core.Menu#MENU_BASE
--- Manages the main menus for @{DCS.coalition}s.
--- Manages the main menus for DCS.coalition.
--
-- You can add menus with the @{#MENU_COALITION.New} method, which constructs a MENU_COALITION object and returns you the object reference.
-- Using this object reference, you can then remove ALL the menus and submenus underlying automatically with @{#MENU_COALITION.Remove}.

View File

@@ -52,7 +52,7 @@
-- ===
--
-- ### Author: **FlightControl**
-- ### Contributions:
-- ### Contributions: **Applevangelist**
--
-- ===
--
@@ -73,7 +73,7 @@ MESSAGE.Type = {
Detailed = "Detailed Report",
}
--- Creates a new MESSAGE object. Note that these MESSAGE objects are not yet displayed on the display panel. You must use the functions @{ToClient} or @{ToCoalition} or @{ToAll} to send these Messages to the respective recipients.
--- Creates a new MESSAGE object. Note that these MESSAGE objects are not yet displayed on the display panel. You must use the functions @{#MESSAGE.ToClient} or @{#MESSAGE.ToCoalition} or @{#MESSAGE.ToAll} to send these Messages to the respective recipients.
-- @param self
-- @param #string MessageText is the text of the Message.
-- @param #number MessageDuration is a number in seconds of how long the MESSAGE should be shown on the display panel.
@@ -127,7 +127,7 @@ end
--- Creates a new MESSAGE object of a certain type.
-- Note that these MESSAGE objects are not yet displayed on the display panel.
-- You must use the functions @{ToClient} or @{ToCoalition} or @{ToAll} to send these Messages to the respective recipients.
-- You must use the functions @{Core.Message#ToClient} or @{Core.Message#ToCoalition} or @{Core.Message#ToAll} to send these Messages to the respective recipients.
-- The message display times are automatically defined based on the timing settings in the @{Core.Settings} menu.
-- @param self
-- @param #string MessageText is the text of the Message.
@@ -343,7 +343,7 @@ end
--- Sends a MESSAGE to a Coalition.
-- @param #MESSAGE self
-- @param #DCS.coalition.side CoalitionSide @{#DCS.coalition.side} to which the message is displayed.
-- @param DCS#coalition.side CoalitionSide @{#DCS.coalition.side} to which the message is displayed.
-- @param Core.Settings#SETTINGS Settings (Optional) Settings for message display.
-- @return #MESSAGE Message object.
-- @usage
@@ -368,16 +368,18 @@ function MESSAGE:ToCoalition( CoalitionSide, Settings )
if CoalitionSide then
if self.MessageDuration ~= 0 then
self:T( self.MessageCategory .. self.MessageText:gsub( "\n$", "" ):gsub( "\n$", "" ) .. " / " .. self.MessageDuration )
trigger.action.outTextForCoalition( CoalitionSide, self.MessageText:gsub( "\n$", "" ):gsub( "\n$", "" ), self.MessageDuration, self.ClearScreen )
trigger.action.outTextForCoalition( CoalitionSide, self.MessageCategory .. self.MessageText:gsub( "\n$", "" ):gsub( "\n$", "" ), self.MessageDuration, self.ClearScreen )
end
end
self.CoalitionSide = CoalitionSide
return self
end
--- Sends a MESSAGE to a Coalition if the given Condition is true.
-- @param #MESSAGE self
-- @param CoalitionSide needs to be filled out by the defined structure of the standard scripting engine @{coalition.side}.
-- @param CoalitionSide needs to be filled out by the defined structure of the standard scripting engine @{#DCS.coalition.side}.
-- @param #boolean Condition Sends the message only if the condition is true.
-- @return #MESSAGE self
function MESSAGE:ToCoalitionIf( CoalitionSide, Condition )
@@ -393,29 +395,36 @@ end
--- Sends a MESSAGE to all players.
-- @param #MESSAGE self
-- @param Core.Settings#Settings Settings (Optional) Settings for message display.
-- @return #MESSAGE
-- @param #number Delay (Optional) Delay in seconds before the message is send. Default instantly (`nil`).
-- @return #MESSAGE self
-- @usage
--
-- -- Send a message created to all players.
-- MessageAll = MESSAGE:New( "To all Players: BLUE has won! Each player of BLUE wins 50 points!", "End of Mission", 25 ):ToAll()
-- or
-- MESSAGE:New( "To all Players: BLUE has won! Each player of BLUE wins 50 points!", "End of Mission", 25 ):ToAll()
-- or
-- MessageAll = MESSAGE:New( "To all Players: BLUE has won! Each player of BLUE wins 50 points!", "End of Mission", 25 )
-- MessageAll:ToAll()
-- -- Send a message created to all players.
-- MessageAll = MESSAGE:New( "To all Players: BLUE has won! Each player of BLUE wins 50 points!", "End of Mission", 25 ):ToAll()
-- or
-- MESSAGE:New( "To all Players: BLUE has won! Each player of BLUE wins 50 points!", "End of Mission", 25 ):ToAll()
-- or
-- MessageAll = MESSAGE:New( "To all Players: BLUE has won! Each player of BLUE wins 50 points!", "End of Mission", 25 )
-- MessageAll:ToAll()
--
function MESSAGE:ToAll( Settings )
function MESSAGE:ToAll( Settings, Delay )
self:F()
if self.MessageType then
local Settings = Settings or _SETTINGS -- Core.Settings#SETTINGS
self.MessageDuration = Settings:GetMessageTime( self.MessageType )
self.MessageCategory = "" -- self.MessageType .. ": "
end
if Delay and Delay>0 then
self:ScheduleOnce(Delay, MESSAGE.ToAll, self, Settings, 0)
else
if self.MessageDuration ~= 0 then
self:T( self.MessageCategory .. self.MessageText:gsub( "\n$", "" ):gsub( "\n$", "" ) .. " / " .. self.MessageDuration )
trigger.action.outText( self.MessageCategory .. self.MessageText:gsub( "\n$", "" ):gsub( "\n$", "" ), self.MessageDuration, self.ClearScreen )
if self.MessageType then
local Settings = Settings or _SETTINGS -- Core.Settings#SETTINGS
self.MessageDuration = Settings:GetMessageTime( self.MessageType )
self.MessageCategory = "" -- self.MessageType .. ": "
end
if self.MessageDuration ~= 0 then
self:T( self.MessageCategory .. self.MessageText:gsub( "\n$", "" ):gsub( "\n$", "" ) .. " / " .. self.MessageDuration )
trigger.action.outText( self.MessageCategory .. self.MessageText:gsub( "\n$", "" ):gsub( "\n$", "" ), self.MessageDuration, self.ClearScreen )
end
end
return self
@@ -454,3 +463,169 @@ function MESSAGE:ToLogIf( Condition )
end
return self
end
_MESSAGESRS = {}
--- Set up MESSAGE generally to allow Text-To-Speech via SRS and TTS functions. `SetMSRS()` will try to use as many attributes configured with @{Sound.SRS#MSRS.LoadConfigFile}() as possible.
-- @param #string PathToSRS (optional) Path to SRS Folder, defaults to "C:\\\\Program Files\\\\DCS-SimpleRadio-Standalone" or your configuration file setting.
-- @param #number Port Port (optional) number of SRS, defaults to 5002 or your configuration file setting.
-- @param #string PathToCredentials (optional) Path to credentials file for Google.
-- @param #number Frequency Frequency in MHz. Can also be given as a #table of frequencies.
-- @param #number Modulation Modulation, i.e. radio.modulation.AM or radio.modulation.FM. Can also be given as a #table of modulations.
-- @param #string Gender (optional) Gender, i.e. "male" or "female", defaults to "female" or your configuration file setting.
-- @param #string Culture (optional) Culture, e.g. "en-US", defaults to "en-GB" or your configuration file setting.
-- @param #string Voice (optional) Voice. Will override gender and culture settings, e.g. MSRS.Voices.Microsoft.Hazel or MSRS.Voices.Google.Standard.de_DE_Standard_D. Hint on Microsoft voices - working voices are limited to Hedda, Hazel, David, Zira and Hortense. **Must** be installed on your Desktop or Server!
-- @param #number Coalition (optional) Coalition, can be coalition.side.RED, coalition.side.BLUE or coalition.side.NEUTRAL. Defaults to coalition.side.NEUTRAL.
-- @param #number Volume (optional) Volume, can be between 0.0 and 1.0 (loudest).
-- @param #string Label (optional) Label, defaults to "MESSAGE" or the Message Category set.
-- @param Core.Point#COORDINATE Coordinate (optional) Coordinate this messages originates from.
-- @usage
-- -- Mind the dot here, not using the colon this time around!
-- -- Needed once only
-- MESSAGE.SetMSRS("D:\\Program Files\\DCS-SimpleRadio-Standalone",5012,nil,127,radio.modulation.FM,"female","en-US",nil,coalition.side.BLUE)
-- -- later on in your code
-- MESSAGE:New("Test message!",15,"SPAWN"):ToSRS()
--
function MESSAGE.SetMSRS(PathToSRS,Port,PathToCredentials,Frequency,Modulation,Gender,Culture,Voice,Coalition,Volume,Label,Coordinate)
_MESSAGESRS.PathToSRS = PathToSRS or MSRS.path or "C:\\Program Files\\DCS-SimpleRadio-Standalone"
_MESSAGESRS.frequency = Frequency or MSRS.frequencies or 243
_MESSAGESRS.modulation = Modulation or MSRS.modulations or radio.modulation.AM
_MESSAGESRS.MSRS = MSRS:New(_MESSAGESRS.PathToSRS,_MESSAGESRS.frequency, _MESSAGESRS.modulation)
_MESSAGESRS.coalition = Coalition or MSRS.coalition or coalition.side.NEUTRAL
_MESSAGESRS.MSRS:SetCoalition(_MESSAGESRS.coalition)
_MESSAGESRS.coordinate = Coordinate
if Coordinate then
_MESSAGESRS.MSRS:SetCoordinate(Coordinate)
end
_MESSAGESRS.Culture = Culture or MSRS.culture or "en-GB"
_MESSAGESRS.MSRS:SetCulture(Culture)
_MESSAGESRS.Gender = Gender or MSRS.gender or "female"
_MESSAGESRS.MSRS:SetGender(Gender)
if PathToCredentials then
_MESSAGESRS.MSRS:SetProviderOptionsGoogle(PathToCredentials)
_MESSAGESRS.MSRS:SetProvider(MSRS.Provider.GOOGLE)
end
_MESSAGESRS.label = Label or MSRS.Label or "MESSAGE"
_MESSAGESRS.MSRS:SetLabel(Label or "MESSAGE")
_MESSAGESRS.port = Port or MSRS.port or 5002
_MESSAGESRS.MSRS:SetPort(Port or 5002)
_MESSAGESRS.volume = Volume or MSRS.volume or 1
_MESSAGESRS.MSRS:SetVolume(_MESSAGESRS.volume)
if Voice then _MESSAGESRS.MSRS:SetVoice(Voice) end
_MESSAGESRS.voice = Voice or MSRS.voice --or MSRS.Voices.Microsoft.Hedda
_MESSAGESRS.SRSQ = MSRSQUEUE:New(_MESSAGESRS.label)
end
--- Sends a message via SRS. `ToSRS()` will try to use as many attributes configured with @{Core.Message#MESSAGE.SetMSRS}() and @{Sound.SRS#MSRS.LoadConfigFile}() as possible.
-- @param #MESSAGE self
-- @param #number frequency (optional) Frequency in MHz. Can also be given as a #table of frequencies. Only needed if you want to override defaults set with `MESSAGE.SetMSRS()` for this one setting.
-- @param #number modulation (optional) Modulation, i.e. radio.modulation.AM or radio.modulation.FM. Can also be given as a #table of modulations. Only needed if you want to override defaults set with `MESSAGE.SetMSRS()` for this one setting.
-- @param #string gender (optional) Gender, i.e. "male" or "female". Only needed if you want to change defaults set with `MESSAGE.SetMSRS()`.
-- @param #string culture (optional) Culture, e.g. "en-US". Only needed if you want to change defaults set with `MESSAGE.SetMSRS()`.
-- @param #string voice (optional) Voice. Will override gender and culture settings. Only needed if you want to change defaults set with `MESSAGE.SetMSRS()`.
-- @param #number coalition (optional) Coalition, can be coalition.side.RED, coalition.side.BLUE or coalition.side.NEUTRAL. Only needed if you want to change defaults set with `MESSAGE.SetMSRS()`.
-- @param #number volume (optional) Volume, can be between 0.0 and 1.0 (loudest). Only needed if you want to change defaults set with `MESSAGE.SetMSRS()`.
-- @param Core.Point#COORDINATE coordinate (optional) Coordinate this messages originates from. Only needed if you want to change defaults set with `MESSAGE.SetMSRS()`.
-- @return #MESSAGE self
-- @usage
-- -- Mind the dot here, not using the colon this time around!
-- -- Needed once only
-- MESSAGE.SetMSRS("D:\\Program Files\\DCS-SimpleRadio-Standalone",5012,nil,127,radio.modulation.FM,"female","en-US",nil,coalition.side.BLUE)
-- -- later on in your code
-- MESSAGE:New("Test message!",15,"SPAWN"):ToSRS()
--
function MESSAGE:ToSRS(frequency,modulation,gender,culture,voice,coalition,volume,coordinate)
local tgender = gender or _MESSAGESRS.Gender
if _MESSAGESRS.SRSQ then
if voice then
_MESSAGESRS.MSRS:SetVoice(voice or _MESSAGESRS.voice)
end
if coordinate then
_MESSAGESRS.MSRS:SetCoordinate(coordinate)
end
local category = string.gsub(self.MessageCategory,":","")
_MESSAGESRS.SRSQ:NewTransmission(self.MessageText,nil,_MESSAGESRS.MSRS,0.5,1,nil,nil,nil,frequency or _MESSAGESRS.frequency,modulation or _MESSAGESRS.modulation, gender or _MESSAGESRS.Gender,culture or _MESSAGESRS.Culture,nil,volume or _MESSAGESRS.volume,category,coordinate or _MESSAGESRS.coordinate)
end
return self
end
--- Sends a message via SRS on the blue coalition side.
-- @param #MESSAGE self
-- @param #number frequency (optional) Frequency in MHz. Can also be given as a #table of frequencies. Only needed if you want to override defaults set with `MESSAGE.SetMSRS()` for this one setting.
-- @param #number modulation (optional) Modulation, i.e. radio.modulation.AM or radio.modulation.FM. Can also be given as a #table of modulations. Only needed if you want to override defaults set with `MESSAGE.SetMSRS()` for this one setting.
-- @param #string gender (optional) Gender, i.e. "male" or "female". Only needed if you want to change defaults set with `MESSAGE.SetMSRS()`.
-- @param #string culture (optional) Culture, e.g. "en-US. Only needed if you want to change defaults set with `MESSAGE.SetMSRS()`.
-- @param #string voice (optional) Voice. Will override gender and culture settings. Only needed if you want to change defaults set with `MESSAGE.SetMSRS()`.
-- @param #number volume (optional) Volume, can be between 0.0 and 1.0 (loudest). Only needed if you want to change defaults set with `MESSAGE.SetMSRS()`.
-- @param Core.Point#COORDINATE coordinate (optional) Coordinate this messages originates from. Only needed if you want to change defaults set with `MESSAGE.SetMSRS()`.
-- @return #MESSAGE self
-- @usage
-- -- Mind the dot here, not using the colon this time around!
-- -- Needed once only
-- MESSAGE.SetMSRS("D:\\Program Files\\DCS-SimpleRadio-Standalone",5012,nil,127,radio.modulation.FM,"female","en-US",nil,coalition.side.BLUE)
-- -- later on in your code
-- MESSAGE:New("Test message!",15,"SPAWN"):ToSRSBlue()
--
function MESSAGE:ToSRSBlue(frequency,modulation,gender,culture,voice,volume,coordinate)
self:ToSRS(frequency,modulation,gender,culture,voice,coalition.side.BLUE,volume,coordinate)
return self
end
--- Sends a message via SRS on the red coalition side.
-- @param #MESSAGE self
-- @param #number frequency (optional) Frequency in MHz. Can also be given as a #table of frequencies. Only needed if you want to override defaults set with `MESSAGE.SetMSRS()` for this one setting.
-- @param #number modulation (optional) Modulation, i.e. radio.modulation.AM or radio.modulation.FM. Can also be given as a #table of modulations. Only needed if you want to override defaults set with `MESSAGE.SetMSRS()` for this one setting.
-- @param #string gender (optional) Gender, i.e. "male" or "female". Only needed if you want to change defaults set with `MESSAGE.SetMSRS()`.
-- @param #string culture (optional) Culture, e.g. "en-US. Only needed if you want to change defaults set with `MESSAGE.SetMSRS()`.
-- @param #string voice (optional) Voice. Will override gender and culture settings. Only needed if you want to change defaults set with `MESSAGE.SetMSRS()`.
-- @param #number volume (optional) Volume, can be between 0.0 and 1.0 (loudest). Only needed if you want to change defaults set with `MESSAGE.SetMSRS()`.
-- @param Core.Point#COORDINATE coordinate (optional) Coordinate this messages originates from. Only needed if you want to change defaults set with `MESSAGE.SetMSRS()`.
-- @return #MESSAGE self
-- @usage
-- -- Mind the dot here, not using the colon this time around!
-- -- Needed once only
-- MESSAGE.SetMSRS("D:\\Program Files\\DCS-SimpleRadio-Standalone",5012,nil,127,radio.modulation.FM,"female","en-US",nil,coalition.side.RED)
-- -- later on in your code
-- MESSAGE:New("Test message!",15,"SPAWN"):ToSRSRed()
--
function MESSAGE:ToSRSRed(frequency,modulation,gender,culture,voice,volume,coordinate)
self:ToSRS(frequency,modulation,gender,culture,voice,coalition.side.RED,volume,coordinate)
return self
end
--- Sends a message via SRS to all - via the neutral coalition side.
-- @param #MESSAGE self
-- @param #number frequency (optional) Frequency in MHz. Can also be given as a #table of frequencies. Only needed if you want to override defaults set with `MESSAGE.SetMSRS()` for this one setting.
-- @param #number modulation (optional) Modulation, i.e. radio.modulation.AM or radio.modulation.FM. Can also be given as a #table of modulations. Only needed if you want to override defaults set with `MESSAGE.SetMSRS()` for this one setting.
-- @param #string gender (optional) Gender, i.e. "male" or "female". Only needed if you want to change defaults set with `MESSAGE.SetMSRS()`.
-- @param #string culture (optional) Culture, e.g. "en-US. Only needed if you want to change defaults set with `MESSAGE.SetMSRS()`.
-- @param #string voice (optional) Voice. Will override gender and culture settings. Only needed if you want to change defaults set with `MESSAGE.SetMSRS()`.
-- @param #number volume (optional) Volume, can be between 0.0 and 1.0 (loudest). Only needed if you want to change defaults set with `MESSAGE.SetMSRS()`.
-- @param Core.Point#COORDINATE coordinate (optional) Coordinate this messages originates from. Only needed if you want to change defaults set with `MESSAGE.SetMSRS()`.
-- @return #MESSAGE self
-- @usage
-- -- Mind the dot here, not using the colon this time around!
-- -- Needed once only
-- MESSAGE.SetMSRS("D:\\Program Files\\DCS-SimpleRadio-Standalone",5012,nil,127,radio.modulation.FM,"female","en-US",nil,coalition.side.NEUTRAL)
-- -- later on in your code
-- MESSAGE:New("Test message!",15,"SPAWN"):ToSRSAll()
--
function MESSAGE:ToSRSAll(frequency,modulation,gender,culture,voice,volume,coordinate)
self:ToSRS(frequency,modulation,gender,culture,voice,coalition.side.NEUTRAL,volume,coordinate)
return self
end

View File

@@ -73,7 +73,7 @@ PATHLINE = {
--- PATHLINE class version.
-- @field #string version
PATHLINE.version="0.1.0"
PATHLINE.version="0.1.1"
-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
-- TODO list
@@ -199,7 +199,7 @@ end
--- Get points of pathline. Not that points are tables, that contain more information as just the 2D or 3D position but also the surface type etc.
-- @param #PATHLINE self
-- @return <#PATHLINE.Point> List of points.
-- @return #list <#PATHLINE.Point> List of points.
function PATHLINE:GetPoints()
return self.points
end
@@ -237,13 +237,14 @@ end
--- Get COORDINATES of pathline. Note that COORDINATE objects are created when calling this function. That does involve deep copy calls and can have an impact on performance if done too often.
-- @param #PATHLINE self
-- @return <Core.Point#COORDINATE> List of COORDINATES points.
function PATHLINE:GetCoordinats()
function PATHLINE:GetCoordinates()
local vecs={}
for _,_point in pairs(self.points) do
local point=_point --#PATHLINE.Point
local coord=COORDINATE:NewFromVec3(point.vec3)
table.insert(vecs,coord)
end
return vecs
@@ -262,7 +263,7 @@ function PATHLINE:GetPointFromIndex(n)
local point=nil --#PATHLINE.Point
if n>=1 and n<=N then
point=self.point[n]
point=self.points[n]
else
self:E(self.lid..string.format("ERROR: No point in pathline for N=%s", tostring(n)))
end
@@ -367,4 +368,4 @@ end
-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

View File

@@ -8,22 +8,6 @@
--
-- ===
--
-- # Demo Missions
--
-- ### [POINT_VEC Demo Missions source code]()
--
-- ### [POINT_VEC Demo Missions, only for beta testers]()
--
-- ### [ALL Demo Missions pack of the last release](https://github.com/FlightControl-Master/MOOSE_MISSIONS/releases)
--
-- ===
--
-- # YouTube Channel
--
-- ### [POINT_VEC YouTube Channel]()
--
-- ===
--
-- ### Authors:
--
-- * FlightControl (Design & Programming)
@@ -40,8 +24,9 @@
do -- COORDINATE
--- @type COORDINATE
---
-- @type COORDINATE
-- @field #string ClassName Name of the class
-- @field #number x Component of the 3D vector.
-- @field #number y Component of the 3D vector.
@@ -196,7 +181,7 @@ do -- COORDINATE
-- * @{#COORDINATE.ToStringBR}(): Generates a Bearing & Range text in the format of DDD for DI where DDD is degrees and DI is distance.
-- * @{#COORDINATE.ToStringBRA}(): Generates a Bearing, Range & Altitude text.
-- * @{#COORDINATE.ToStringBRAANATO}(): Generates a Generates a Bearing, Range, Aspect & Altitude text in NATOPS.
-- * @{#COORDINATE.ToStringLL}(): Generates a Latutide & Longitude text.
-- * @{#COORDINATE.ToStringLL}(): Generates a Latitude & Longitude text.
-- * @{#COORDINATE.ToStringLLDMS}(): Generates a Lat, Lon, Degree, Minute, Second text.
-- * @{#COORDINATE.ToStringLLDDM}(): Generates a Lat, Lon, Degree, decimal Minute text.
-- * @{#COORDINATE.ToStringMGRS}(): Generates a MGRS grid coordinate text.
@@ -544,7 +529,7 @@ do -- COORDINATE
if ZoneObject then
-- Get category of scanned object.
local ObjectCategory = ZoneObject:getCategory()
local ObjectCategory = Object.getCategory(ZoneObject)
-- Check for unit or static objects
if ObjectCategory==Object.Category.UNIT and ZoneObject:isExist() then
@@ -717,8 +702,9 @@ do -- COORDINATE
-- @param #COORDINATE PointVec2Reference The reference @{#COORDINATE}.
-- @return DCS#Distance The distance from the reference @{#COORDINATE} in meters.
function COORDINATE:DistanceFromPointVec2( PointVec2Reference )
self:F2( PointVec2Reference )
self:F2( PointVec2Reference )
if not PointVec2Reference then return math.huge end
local Distance = ( ( PointVec2Reference.x - self.x ) ^ 2 + ( PointVec2Reference.z - self.z ) ^2 ) ^ 0.5
self:T2( Distance )
@@ -920,7 +906,7 @@ do -- COORDINATE
end
--- Return an angle in radians from the COORDINATE using a direction vector in Vec3 format.
--- Return an angle in radians from the COORDINATE using a **direction vector in Vec3 format**.
-- @param #COORDINATE self
-- @param DCS#Vec3 DirectionVec3 The direction vector in Vec3 format.
-- @return #number DirectionRadians The angle in radians.
@@ -933,10 +919,12 @@ do -- COORDINATE
return DirectionRadians
end
--- Return an angle in degrees from the COORDINATE using a direction vector in Vec3 format.
--- Return an angle in degrees from the COORDINATE using a **direction vector in Vec3 format**.
-- @param #COORDINATE self
-- @param DCS#Vec3 DirectionVec3 The direction vector in Vec3 format.
-- @return #number DirectionRadians The angle in degrees.
-- @usage
-- local directionAngle = currentCoordinate:GetAngleDegrees(currentCoordinate:GetDirectionVec3(sourceCoordinate:GetVec3()))
function COORDINATE:GetAngleDegrees( DirectionVec3 )
local AngleRadians = self:GetAngleRadians( DirectionVec3 )
local Angle = UTILS.ToDegree( AngleRadians )
@@ -2389,7 +2377,6 @@ do -- COORDINATE
end
--- Creates a free form shape on the F10 map. The first point is the current COORDINATE. The remaining points need to be specified.
-- **NOTE**: A free form polygon must have **at least three points** in total and currently only **up to 15 points** in total are supported.
-- @param #COORDINATE self
-- @param #table Coordinates Table of coordinates of the remaining points of the shape.
-- @param #number Coalition Coalition: All=-1, Neutral=0, Red=1, Blue=2. Default -1=All.
@@ -2463,9 +2450,33 @@ do -- COORDINATE
vecs[11], vecs[12], vecs[13], vecs[14], vecs[15],
Color, FillColor, LineType, ReadOnly, Text or "")
else
self:E("ERROR: Currently a free form polygon can only have 15 points in total!")
-- Unfortunately, unpack(vecs) does not work! So no idea how to generalize this :(
trigger.action.markupToAll(7, Coalition, MarkID, unpack(vecs), Color, FillColor, LineType, ReadOnly, Text or "")
--trigger.action.markupToAll(7, Coalition, MarkID, unpack(vecs), Color, FillColor, LineType, ReadOnly, Text or "")
-- Write command as string and execute that. Idea by Grimes https://forum.dcs.world/topic/324201-mark-to-all-function/#comment-5273793
local s=string.format("trigger.action.markupToAll(7, %d, %d,", Coalition, MarkID)
for _,vec in pairs(vecs) do
--s=s..string.format("%s,", UTILS._OneLineSerialize(vec))
s=s..string.format("{x=%.1f, y=%.1f, z=%.1f},", vec.x, vec.y, vec.z)
end
s=s..string.format("{%.3f, %.3f, %.3f, %.3f},", Color[1], Color[2], Color[3], Color[4])
s=s..string.format("{%.3f, %.3f, %.3f, %.3f},", FillColor[1], FillColor[2], FillColor[3], FillColor[4])
s=s..string.format("%d,", LineType or 1)
s=s..string.format("%s", tostring(ReadOnly))
if Text and type(Text)=="string" and string.len(Text)>0 then
s=s..string.format(", \"%s\"", tostring(Text))
end
s=s..")"
-- Execute string command
local success=UTILS.DoString(s)
if not success then
self:E("ERROR: Could not draw polygon")
env.info(s)
end
end
return MarkID
@@ -2545,7 +2556,7 @@ do -- COORDINATE
Offset=Offset or 2
-- Measurement of visibility should not be from the ground, so Adding a hypotethical 2 meters to each Coordinate.
-- Measurement of visibility should not be from the ground, so Adding a hypothetical 2 meters to each Coordinate.
local FromVec3 = self:GetVec3()
FromVec3.y = FromVec3.y + Offset
@@ -2944,8 +2955,13 @@ do -- COORDINATE
if alt < 1 then
alttext = "very low"
end
local track = UTILS.BearingToCardinal(bearing) or "North"
-- corrected Track to be direction of travel of bogey (self in this case)
local track = "Maneuver"
if self.Heading then
track = UTILS.BearingToCardinal(self.Heading) or "North"
end
if rangeNM > 3 then
if SSML then -- google says "oh" instead of zero, be aware
@@ -2996,6 +3012,16 @@ do -- COORDINATE
return BRAANATO
end
--- Return the BULLSEYE as COORDINATE Object
-- @param #number Coalition Coalition of the bulls eye to return, e.g. coalition.side.BLUE
-- @return #COORDINATE self
-- @usage
-- -- note the dot (.) here,not using the colon (:)
-- local redbulls = COORDINATE.GetBullseyeCoordinate(coalition.side.RED)
function COORDINATE.GetBullseyeCoordinate(Coalition)
return COORDINATE:NewFromVec3( coalition.getMainRefPoint( Coalition ) )
end
--- Return a BULLS string out of the BULLS of the coalition to the COORDINATE.
-- @param #COORDINATE self
-- @param DCS#coalition.side Coalition The coalition.
@@ -3046,6 +3072,18 @@ do -- COORDINATE
return coord.LOtoLL( self:GetVec3() )
end
--- Get Latitude & Longitude text.
-- @param #COORDINATE self
-- @param Core.Settings#SETTINGS Settings (optional) The settings. Can be nil, and in this case the default settings are used. If you want to specify your own settings, use the _SETTINGS object.
-- @return #string LLText
function COORDINATE:ToStringLL( Settings )
local LL_Accuracy = Settings and Settings.LL_Accuracy or _SETTINGS.LL_Accuracy
local lat, lon = coord.LOtoLL( self:GetVec3() )
return string.format('%f', lat) .. ' ' .. string.format('%f', lon)
end
--- Provides a Lat Lon string in Degree Minute Second format.
-- @param #COORDINATE self
-- @param Core.Settings#SETTINGS Settings (optional) The settings. Can be nil, and in this case the default settings are used. If you want to specify your own settings, use the _SETTINGS object.
@@ -3079,6 +3117,50 @@ do -- COORDINATE
local MGRS = coord.LLtoMGRS( lat, lon )
return "MGRS " .. UTILS.tostringMGRS( MGRS, MGRS_Accuracy )
end
--- Provides a COORDINATE from an MGRS String
-- @param #COORDINATE self
-- @param #string MGRSString MGRS String, e.g. "MGRS 37T DK 12345 12345"
-- @return #COORDINATE self
function COORDINATE:NewFromMGRSString( MGRSString )
local myparts = UTILS.Split(MGRSString," ")
local northing = tostring(myparts[5]) or ""
local easting = tostring(myparts[4]) or ""
if string.len(easting) < 5 then easting = easting..string.rep("0",5-string.len(easting)) end
if string.len(northing) < 5 then northing = northing..string.rep("0",5-string.len(northing)) end
local MGRS = {
UTMZone = myparts[2],
MGRSDigraph = myparts[3],
Easting = easting,
Northing = northing,
}
local lat, lon = coord.MGRStoLL(MGRS)
local point = coord.LLtoLO(lat, lon, 0)
local coord = COORDINATE:NewFromVec2({x=point.x,y=point.z})
return coord
end
--- Provides a COORDINATE from an MGRS Coordinate
-- @param #COORDINATE self
-- @param #string UTMZone UTM Zone, e.g. "37T"
-- @param #string MGRSDigraph Digraph, e.g. "DK"
-- @param #string Easting Meters easting - string in order to allow for leading zeros, e.g. "01234". Should be 5 digits.
-- @param #string Northing Meters northing - string in order to allow for leading zeros, e.g. "12340". Should be 5 digits.
-- @return #COORDINATE self
function COORDINATE:NewFromMGRS( UTMZone, MGRSDigraph, Easting, Northing )
if string.len(Easting) < 5 then Easting = tostring(Easting..string.rep("0",5-string.len(Easting) )) end
if string.len(Northing) < 5 then Northing = tostring(Northing..string.rep("0",5-string.len(Northing) )) end
local MGRS = {
UTMZone = UTMZone,
MGRSDigraph = MGRSDigraph,
Easting = tostring(Easting),
Northing = tostring(Northing),
}
local lat, lon = coord.MGRStoLL(MGRS)
local point = coord.LLtoLO(lat, lon, 0)
local coord = COORDINATE:NewFromVec2({x=point.x,y=point.z})
return coord
end
--- Provides a coordinate string of the point, based on a coordinate format system:
-- * Uses default settings in COORDINATE.
@@ -3592,7 +3674,7 @@ end
do -- POINT_VEC2
--- @type POINT_VEC2
-- @type POINT_VEC2
-- @field DCS#Distance x The x coordinate in meters.
-- @field DCS#Distance y the y coordinate in meters.
-- @extends Core.Point#COORDINATE

View File

@@ -14,17 +14,13 @@
--
-- # Demo Missions
--
-- ### [SCHEDULER Demo Missions source code](https://github.com/FlightControl-Master/MOOSE_MISSIONS/tree/master/SCH%20-%20Scheduler)
--
-- ### [SCHEDULER Demo Missions, only for beta testers](https://github.com/FlightControl-Master/MOOSE_MISSIONS/tree/master/SCH%20-%20Scheduler)
--
-- ### [ALL Demo Missions pack of the last release](https://github.com/FlightControl-Master/MOOSE_MISSIONS/releases)
-- ### [SCHEDULER Demo Missions](https://github.com/FlightControl-Master/MOOSE_MISSIONS/tree/master/Core/Scheduler)
--
-- ===
--
-- # YouTube Channel
--
-- ### [SCHEDULER YouTube Channel (none)]()
-- ### None
--
-- ===
--
@@ -52,7 +48,7 @@
--
-- A SCHEDULER can manage **multiple** (repeating) schedules. Each planned or executing schedule has a unique **ScheduleID**.
-- The ScheduleID is returned when the method @{#SCHEDULER.Schedule}() is called.
-- It is recommended to store the ScheduleID in a variable, as it is used in the methods @{SCHEDULER.Start}() and @{SCHEDULER.Stop}(),
-- It is recommended to store the ScheduleID in a variable, as it is used in the methods @{#SCHEDULER.Start}() and @{#SCHEDULER.Stop}(),
-- which can start and stop specific repeating schedules respectively within a SCHEDULER object.
--
-- ## SCHEDULER constructor
@@ -208,7 +204,7 @@ SCHEDULER = {
-- @param #number RandomizeFactor Specifies a randomization factor between 0 and 1 to randomize the Repeat.
-- @param #number Stop Specifies the amount of seconds when the scheduler will be stopped.
-- @return #SCHEDULER self.
-- @return #table The ScheduleID of the planned schedule.
-- @return #string The ScheduleID of the planned schedule.
function SCHEDULER:New( MasterObject, SchedulerFunction, SchedulerArguments, Start, Repeat, RandomizeFactor, Stop )
local self = BASE:Inherit( self, BASE:New() ) -- #SCHEDULER

File diff suppressed because it is too large Load Diff

View File

@@ -91,7 +91,7 @@
--
-- Will customize which display format is used to indicate A2G coordinates in text as part of the Command Center communications.
--
-- - A2G BR: [Bearing Range](https://en.wikipedia.org/wiki/Bearing_(navigation)).
-- - A2G BR: [Bearing Range](https://en.wikipedia.org/wiki/Bearing_\(navigation\)).
-- - A2G MGRS: The [Military Grid Reference System](https://en.wikipedia.org/wiki/Military_Grid_Reference_System). The accuracy can also be adapted.
-- - A2G LL DMS: Latitude Longitude [Degrees Minutes Seconds](https://en.wikipedia.org/wiki/Geographic_coordinate_conversion). The accuracy can also be adapted.
-- - A2G LL DDM: Latitude Longitude [Decimal Degrees Minutes](https://en.wikipedia.org/wiki/Decimal_degrees). The accuracy can also be adapted.
@@ -105,9 +105,9 @@
-- There are different methods that can be used to change the **System settings** using the \_SETTINGS object.
--
-- - @{#SETTINGS.SetA2G_BR}(): Enable the BR display formatting by default.
-- - @{#SETTINGS.SetA2G_MGRS}(): Enable the MGRS display formatting by default. Use @{SETTINGS.SetMGRS_Accuracy}() to adapt the accuracy of the MGRS formatting.
-- - @{#SETTINGS.SetA2G_LL_DMS}(): Enable the LL DMS display formatting by default. Use @{SETTINGS.SetLL_Accuracy}() to adapt the accuracy of the Seconds formatting.
-- - @{#SETTINGS.SetA2G_LL_DDM}(): Enable the LL DDM display formatting by default. Use @{SETTINGS.SetLL_Accuracy}() to adapt the accuracy of the Seconds formatting.
-- - @{#SETTINGS.SetA2G_MGRS}(): Enable the MGRS display formatting by default. Use @{#SETTINGS.SetMGRS_Accuracy}() to adapt the accuracy of the MGRS formatting.
-- - @{#SETTINGS.SetA2G_LL_DMS}(): Enable the LL DMS display formatting by default. Use @{#SETTINGS.SetLL_Accuracy}() to adapt the accuracy of the Seconds formatting.
-- - @{#SETTINGS.SetA2G_LL_DDM}(): Enable the LL DDM display formatting by default. Use @{#SETTINGS.SetLL_Accuracy}() to adapt the accuracy of the Seconds formatting.
--
-- ### 3.1.4) A2G coordinates setting - additional notes
--
@@ -120,7 +120,7 @@
--
-- Will customize which display format is used to indicate A2A coordinates in text as part of the Command Center communications.
--
-- - A2A BRAA: [Bearing Range Altitude Aspect](https://en.wikipedia.org/wiki/Bearing_(navigation)).
-- - A2A BRAA: [Bearing Range Altitude Aspect](https://en.wikipedia.org/wiki/Bearing_\(navigation\)).
-- - A2A MGRS: The [Military Grid Reference System](https://en.wikipedia.org/wiki/Military_Grid_Reference_System). The accuracy can also be adapted.
-- - A2A LL DMS: Lattitude Longitude [Degrees Minutes Seconds](https://en.wikipedia.org/wiki/Geographic_coordinate_conversion). The accuracy can also be adapted.
-- - A2A LL DDM: Lattitude Longitude [Decimal Degrees and Minutes](https://en.wikipedia.org/wiki/Decimal_degrees). The accuracy can also be adapted.
@@ -135,9 +135,9 @@
-- There are different methods that can be used to change the **System settings** using the \_SETTINGS object.
--
-- - @{#SETTINGS.SetA2A_BRAA}(): Enable the BR display formatting by default.
-- - @{#SETTINGS.SetA2A_MGRS}(): Enable the MGRS display formatting by default. Use @{SETTINGS.SetMGRS_Accuracy}() to adapt the accuracy of the MGRS formatting.
-- - @{#SETTINGS.SetA2A_LL_DMS}(): Enable the LL DMS display formatting by default. Use @{SETTINGS.SetLL_Accuracy}() to adapt the accuracy of the Seconds formatting.
-- - @{#SETTINGS.SetA2A_LL_DDM}(): Enable the LL DDM display formatting by default. Use @{SETTINGS.SetLL_Accuracy}() to adapt the accuracy of the Seconds formatting.
-- - @{#SETTINGS.SetA2A_MGRS}(): Enable the MGRS display formatting by default. Use @{#SETTINGS.SetMGRS_Accuracy}() to adapt the accuracy of the MGRS formatting.
-- - @{#SETTINGS.SetA2A_LL_DMS}(): Enable the LL DMS display formatting by default. Use @{#SETTINGS.SetLL_Accuracy}() to adapt the accuracy of the Seconds formatting.
-- - @{#SETTINGS.SetA2A_LL_DDM}(): Enable the LL DDM display formatting by default. Use @{#SETTINGS.SetLL_Accuracy}() to adapt the accuracy of the Seconds formatting.
-- - @{#SETTINGS.SetA2A_BULLS}(): Enable the BULLSeye display formatting by default.
--
-- ### 3.2.4) A2A coordinates settings - additional notes
@@ -190,8 +190,8 @@
--
-- There are different methods that can be used to change the **System settings** using the \_SETTINGS object.
--
-- - @{#SETTINGS.SetMessageTime}(): Define for a specific @{Message.MESSAGE.MessageType} the duration to be displayed in seconds.
-- - @{#SETTINGS.GetMessageTime}(): Retrieves for a specific @{Message.MESSAGE.MessageType} the duration to be displayed in seconds.
-- - @{#SETTINGS.SetMessageTime}(): Define for a specific @{Core.Message#MESSAGE.MessageType} the duration to be displayed in seconds.
-- - @{#SETTINGS.GetMessageTime}(): Retrieves for a specific @{Core.Message#MESSAGE.MessageType} the duration to be displayed in seconds.
--
-- ## 3.5) **Era** of the battle
--
@@ -283,21 +283,21 @@ do -- SETTINGS
function SETTINGS:SetMetric()
self.Metric = true
end
--- Sets the SETTINGS default text locale.
-- @param #SETTINGS self
-- @param #string Locale
function SETTINGS:SetLocale(Locale)
self.Locale = Locale or "en"
end
--- Gets the SETTINGS text locale.
-- @param #SETTINGS self
-- @return #string
function SETTINGS:GetLocale()
return self.Locale or _SETTINGS:GetLocale()
end
--- Gets if the SETTINGS is metric.
-- @param #SETTINGS self
-- @return #boolean true if metric.
@@ -744,7 +744,7 @@ do -- SETTINGS
self.PlayerMenu = PlayerMenu
self:I( string.format( "Setting menu for player %s", tostring( PlayerName ) ) )
self:T( string.format( "Setting menu for player %s", tostring( PlayerName ) ) )
local submenu = MENU_GROUP:New( PlayerGroup, "LL Accuracy", PlayerMenu )
MENU_GROUP_COMMAND:New( PlayerGroup, "LL 0 Decimals", submenu, self.MenuGroupLL_DDM_AccuracySystem, self, PlayerUnit, PlayerGroup, PlayerName, 0 )
@@ -989,7 +989,7 @@ do -- SETTINGS
do
--- @param #SETTINGS self
function SETTINGS:MenuGroupA2GSystem( PlayerUnit, PlayerGroup, PlayerName, A2GSystem )
BASE:E( { self, PlayerUnit:GetName(), A2GSystem } )
--BASE:E( {PlayerUnit:GetName(), A2GSystem } )
self.A2GSystem = A2GSystem
MESSAGE:New( string.format( "Settings: A2G format set to %s for player %s.", A2GSystem, PlayerName ), 5 ):ToGroup( PlayerGroup )
if _SETTINGS.MenuStatic == false then

View File

@@ -30,7 +30,7 @@
--
-- ===
--
-- ### [Demo Missions](https://github.com/FlightControl-Master/MOOSE_MISSIONS/tree/master/SPA%20-%20Spawning)
-- ### [Demo Missions](https://github.com/FlightControl-Master/MOOSE_MISSIONS/tree/master/Core/Spawn)
--
-- ===
--
@@ -58,7 +58,7 @@
-- @field #SPAWN.SpawnZoneTable SpawnZoneTable
-- @extends Core.Base#BASE
--- Allows to spawn dynamically new @{Core.Group}s.
--- Allows to spawn dynamically new @{Wrapper.Group}s.
--
-- Each SPAWN object needs to be have related **template groups** setup in the Mission Editor (ME),
-- which is a normal group with the **Late Activation** flag set.
@@ -162,7 +162,17 @@
-- ### Array formation
--
-- * @{#SPAWN.InitArray}(): Make groups visible before they are actually activated, and order these groups like a battalion in an array.
--
--
-- ### Group initial position - if wanted different from template position, for use with e.g. @{#SPAWN.SpawnScheduled}().
--
-- * @{#SPAWN.InitPositionCoordinate}(): Set initial position of group via a COORDINATE.
-- * @{#SPAWN.InitPositionVec2}(): Set initial position of group via a VEC2.
--
-- ### Set the positions of a group's units to absolute positions, or relative positions to unit No. 1
--
-- * @{#SPAWN.InitSetUnitRelativePositions}(): Spawn the UNITs of this group with individual relative positions to unit #1 and individual headings.
-- * @{#SPAWN.InitSetUnitAbsolutePositions}(): Spawn the UNITs of this group with individual absolute positions and individual headings.
--
-- ### Position randomization
--
-- * @{#SPAWN.InitRandomizePosition}(): Randomizes the position of @{Wrapper.Group}s that are spawned within a **radius band**, given an Outer and Inner radius, from the point that the spawn happens.
@@ -189,6 +199,22 @@
--
-- * @{#SPAWN.InitRepeat}() or @{#SPAWN.InitRepeatOnLanding}(): This method is used to re-spawn automatically the same group after it has landed.
-- * @{#SPAWN.InitRepeatOnEngineShutDown}(): This method is used to re-spawn automatically the same group after it has landed and it shuts down the engines at the ramp.
--
-- ### Link-16 Datalink STN and SADL IDs (limited at the moment to F15/16/18/AWACS/Tanker/B1B, but not the F15E for clients, SADL A10CII only)
--
-- *{#SPAWN.InitSTN}(): Set the STN of the first unit in the group. All other units will have consecutive STNs, provided they have not been used yet.
-- *{#SPAWN.InitSADL}(): Set the SADL of the first unit in the group. All other units will have consecutive SADLs, provided they have not been used yet.
--
-- ### Callsigns
--
-- *{#SPAWN.InitRandomizeCallsign}(): Set a random callsign name per spawn.
-- *{#SPAWN.SpawnInitCallSign}(): Set a specific callsign for a spawned group.
--
-- ### Speed
--
-- *{#SPAWN.InitSpeedMps}(): Set the initial speed on spawning in meters per second.
-- *{#SPAWN.InitSpeedKph}(): Set the initial speed on spawning in kilometers per hour.
-- *{#SPAWN.InitSpeedKnots}(): Set the initial speed on spawning in knots.
--
-- ## SPAWN **Spawn** methods
--
@@ -266,9 +292,10 @@ SPAWN = {
--- Enumerator for spawns at airbases
-- @type SPAWN.Takeoff
-- @extends Wrapper.Group#GROUP.Takeoff
--- @field #SPAWN.Takeoff Takeoff
-- @field #number Air Take off happens in air.
-- @field #number Runway Spawn on runway. Does not work in MP!
-- @field #number Hot Spawn at parking with engines on.
-- @field #number Cold Spawn at parking with engines off.
SPAWN.Takeoff = {
Air = 1,
Runway = 2,
@@ -276,7 +303,8 @@ SPAWN.Takeoff = {
Cold = 4,
}
--- @type SPAWN.SpawnZoneTable
---
-- @type SPAWN.SpawnZoneTable
-- @list <Core.Zone#ZONE_BASE> SpawnZone
--- Creates the main object to spawn a @{Wrapper.Group} defined in the DCS ME.
@@ -309,7 +337,7 @@ function SPAWN:New( SpawnTemplatePrefix )
self.AIOnOff = true -- The AI is on by default when spawning a group.
self.SpawnUnControlled = false
self.SpawnInitKeepUnitNames = false -- Overwrite unit names by default with group name.
self.DelayOnOff = false -- No intial delay when spawning the first group.
self.DelayOnOff = false -- No initial delay when spawning the first group.
self.SpawnGrouping = nil -- No grouping.
self.SpawnInitLivery = nil -- No special livery.
self.SpawnInitSkill = nil -- No special skill.
@@ -317,8 +345,11 @@ function SPAWN:New( SpawnTemplatePrefix )
self.SpawnInitModu = nil -- No special modulation.
self.SpawnInitRadio = nil -- No radio comms setting.
self.SpawnInitModex = nil
self.SpawnInitModexPrefix = nil
self.SpawnInitModexPostfix = nil
self.SpawnInitAirbase = nil
self.TweakedTemplate = false -- Check if the user is using self made template.
self.SpawnRandomCallsign = false
self.SpawnGroups = {} -- Array containing the descriptions of each Group to be Spawned.
else
@@ -371,6 +402,8 @@ function SPAWN:NewWithAlias( SpawnTemplatePrefix, SpawnAliasPrefix )
self.SpawnInitModu = nil -- No special modulation.
self.SpawnInitRadio = nil -- No radio communication setting.
self.SpawnInitModex = nil
self.SpawnInitModexPrefix = nil
self.SpawnInitModexPostfix = nil
self.SpawnInitAirbase = nil
self.TweakedTemplate = false -- Check if the user is using self made template.
@@ -388,9 +421,9 @@ end
--- Creates a new SPAWN instance to create new groups based on the provided template. This will also register the template for future use.
-- @param #SPAWN self
-- @param #table SpawnTemplate is the Template of the Group. This must be a valid Group Template structure - see [Hoggit Wiki](https://wiki.hoggitworld.com/view/DCS_func_addGroup)!
-- @param #string SpawnTemplatePrefix [Mandatory] is the name of the template and the prefix of the GROUP on spawn.
-- @param #string SpawnTemplatePrefix [Mandatory] is the name of the template and the prefix of the GROUP on spawn. The name in the template **will** be overwritten!
-- @param #string SpawnAliasPrefix [Optional] is the prefix that will be given to the GROUP on spawn.
-- @param #boolean MooseNaming [Optional] If false, skip the Moose naming additions (like groupname#001-01) - you need to ensure yourself no duplicate group names exist!
-- @param #boolean NoMooseNamingPostfix [Optional] If true, skip the Moose naming additions (like groupname#001-01) - **but** you need to ensure yourself no duplicate group names exist!
-- @return #SPAWN self
-- @usage
-- -- Spawn a P51 Mustang from scratch
@@ -491,7 +524,7 @@ end
-- )
-- mustang:Spawn()
--
function SPAWN:NewFromTemplate( SpawnTemplate, SpawnTemplatePrefix, SpawnAliasPrefix, MooseNaming )
function SPAWN:NewFromTemplate( SpawnTemplate, SpawnTemplatePrefix, SpawnAliasPrefix, NoMooseNamingPostfix )
local self = BASE:Inherit( self, BASE:New() )
self:F( { SpawnTemplate, SpawnTemplatePrefix, SpawnAliasPrefix } )
--if SpawnAliasPrefix == nil or SpawnAliasPrefix == "" then
@@ -504,7 +537,7 @@ function SPAWN:NewFromTemplate( SpawnTemplate, SpawnTemplatePrefix, SpawnAliasPr
end
if SpawnTemplate then
self.SpawnTemplate = SpawnTemplate -- Contains the template structure for a Group Spawn from the Mission Editor. Note that this group must have lateActivation always on!!!
self.SpawnTemplate = UTILS.DeepCopy(SpawnTemplate) -- Contains the template structure for a Group Spawn from the Mission Editor. Note that this group must have lateActivation always on!!!
self.SpawnTemplatePrefix = SpawnTemplatePrefix
self.SpawnAliasPrefix = SpawnAliasPrefix or SpawnTemplatePrefix
self.SpawnTemplate.name = SpawnTemplatePrefix
@@ -530,9 +563,14 @@ function SPAWN:NewFromTemplate( SpawnTemplate, SpawnTemplatePrefix, SpawnAliasPr
self.SpawnInitModu = nil -- No special modulation.
self.SpawnInitRadio = nil -- No radio communication setting.
self.SpawnInitModex = nil
self.SpawnInitModexPrefix = nil
self.SpawnInitModexPostfix = nil
self.SpawnInitAirbase = nil
self.TweakedTemplate = true -- Check if the user is using self made template.
self.MooseNameing = MooseNaming or true
self.MooseNameing = true
if NoMooseNamingPostfix == true then
self.MooseNameing = false
end
self.SpawnGroups = {} -- Array containing the descriptions of each Group to be Spawned.
else
@@ -703,7 +741,7 @@ end
-- @param #number Country Country id as number or enumerator:
--
-- * @{DCS#country.id.RUSSIA}
-- * @{DCS#county.id.USA}
-- * @{DCS#country.id.USA}
--
-- @return #SPAWN self
function SPAWN:InitCountry( Country )
@@ -759,6 +797,82 @@ function SPAWN:InitSkill( Skill )
return self
end
--- [Airplane - F15/16/18/AWACS/B1B/Tanker only] Set the STN Link16 starting number of the Group; each unit of the spawned group will have a consecutive STN set.
-- @param #SPAWN self
-- @param #number Octal The octal number (digits 1..7, max 5 digits, i.e. 1..77777) to set the STN to. Every STN needs to be unique!
-- @return #SPAWN self
function SPAWN:InitSTN(Octal)
self:F( { Octal = Octal } )
self.SpawnInitSTN = Octal or 77777
local num = UTILS.OctalToDecimal(Octal)
if num == nil or num < 1 then
self:E("WARNING - STN "..tostring(Octal).." is not valid!")
return self
end
if _DATABASE.STNS[num] ~= nil then
self:E("WARNING - STN already assigned: "..tostring(Octal).." is used for ".._DATABASE.STNS[Octal])
end
return self
end
--- [Airplane - A10-C II only] Set the SADL TN starting number of the Group; each unit of the spawned group will have a consecutive SADL set.
-- @param #SPAWN self
-- @param #number Octal The octal number (digits 1..7, max 4 digits, i.e. 1..7777) to set the SADL to. Every SADL needs to be unique!
-- @return #SPAWN self
function SPAWN:InitSADL(Octal)
self:F( { Octal = Octal } )
self.SpawnInitSADL = Octal or 7777
local num = UTILS.OctalToDecimal(Octal)
if num == nil or num < 1 then
self:E("WARNING - SADL "..tostring(Octal).." is not valid!")
return self
end
if _DATABASE.SADL[num] ~= nil then
self:E("WARNING - SADL already assigned: "..tostring(Octal).." is used for ".._DATABASE.SADL[Octal])
end
return self
end
--- [Airplane] Set the initial speed on spawning in meters per second. Useful when spawning in-air only.
-- @param #SPAWN self
-- @param #number MPS The speed in MPS to use.
-- @return #SPAWN self
function SPAWN:InitSpeedMps(MPS)
self:F( { MPS = MPS } )
if MPS == nil or tonumber(MPS)<0 then
MPS=125
end
self.InitSpeed = MPS
return self
end
--- [Airplane] Set the initial speed on spawning in knots. Useful when spawning in-air only.
-- @param #SPAWN self
-- @param #number Knots The speed in knots to use.
-- @return #SPAWN self
function SPAWN:InitSpeedKnots(Knots)
self:F( { Knots = Knots } )
if Knots == nil or tonumber(Knots)<0 then
Knots=300
end
self.InitSpeed = UTILS.KnotsToMps(Knots)
return self
end
--- [Airplane] Set the initial speed on spawning in kilometers per hour. Useful when spawning in-air only.
-- @param #SPAWN self
-- @param #number KPH The speed in KPH to use.
-- @return #SPAWN self
function SPAWN:InitSpeedKph(KPH)
self:F( { KPH = KPH } )
if KPH == nil or tonumber(KPH)<0 then
KPH=UTILS.KnotsToKmph(300)
end
self.InitSpeed = UTILS.KmphToMps(KPH)
return self
end
--- Sets the radio communication on or off. Same as checking/unchecking the COMM box in the mission editor.
-- @param #SPAWN self
-- @param #number switch If true (or nil), enables the radio communication. If false, disables the radio for the spawned group.
@@ -798,12 +912,17 @@ end
--- Sets the modex of the first unit of the group. If more units are in the group, the number is increased by one with every unit.
-- @param #SPAWN self
-- @param #number modex Modex of the first unit.
-- @param #string prefix (optional) String to prefix to modex, e.g. for French AdA Modex, eg. -L-102 then "-L-" would be the prefix.
-- @param #string postfix (optional) String to postfix to modex, example tbd.
-- @return #SPAWN self
function SPAWN:InitModex( modex )
function SPAWN:InitModex( modex, prefix, postfix )
if modex then
self.SpawnInitModex = tonumber( modex )
end
self.SpawnInitModexPrefix = prefix
self.SpawnInitModexPostfix = postfix
return self
end
@@ -1044,7 +1163,7 @@ end
--- This method provides the functionality to randomize the spawning of the Groups at a given list of zones of different types.
-- @param #SPAWN self
-- @param #table SpawnZoneTable A table with @{Core.Zone} objects. If this table is given, then each spawn will be executed within the given list of @{Core.Zone}s objects.
-- @return #SPAWN
-- @return #SPAWN self
-- @usage
--
-- -- Create a zone table of the 2 zones.
@@ -1074,6 +1193,55 @@ function SPAWN:InitRandomizeZones( SpawnZoneTable )
return self
end
--- [AIR/Fighter only!] This method randomizes the callsign for a new group.
-- @param #SPAWN self
-- @return #SPAWN self
function SPAWN:InitRandomizeCallsign()
self.SpawnRandomCallsign = true
return self
end
--- [BLUE AIR only!] This method sets a specific callsign for a spawned group. Use for a group with one unit only!
-- @param #SPAWN self
-- @param #number ID ID of the callsign enumerator, e.g. CALLSIGN.Tanker.Texaco - - resulting in e.g. Texaco-2-1
-- @param #string Name Name of this callsign as it cannot be determined from the ID because of the dependency on the task type of the plane, and the plane type. E.g. "Texaco"
-- @param #number Minor Minor number, i.e. the unit number within the group, e.g 2 - resulting in e.g. Texaco-2-1
-- @param #number Major Major number, i.e. the group number of this name, e.g. 1 - resulting in e.g. Texaco-2-1
-- @return #SPAWN self
function SPAWN:InitCallSign(ID,Name,Minor,Major)
self.SpawnInitCallSign = true
self.SpawnInitCallSignID = ID or 1
self.SpawnInitCallSignMinor = Minor or 1
self.SpawnInitCallSignMajor = Major or 1
self.SpawnInitCallSignName = string.lower(Name) or "enfield"
return self
end
--- This method sets a spawn position for the group that is different from the location of the template.
-- @param #SPAWN self
-- @param Core.Point#COORDINATE Coordinate The position to spawn from
-- @return #SPAWN self
function SPAWN:InitPositionCoordinate(Coordinate)
self:T( { self.SpawnTemplatePrefix, Coordinate:GetVec2()} )
self:InitPositionVec2(Coordinate:GetVec2())
return self
end
--- This method sets a spawn position for the group that is different from the location of the template.
-- @param #SPAWN self
-- @param DCS#Vec2 Vec2 The position to spawn from
-- @return #SPAWN self
function SPAWN:InitPositionVec2(Vec2)
self:T( { self.SpawnTemplatePrefix, Vec2} )
self.SpawnInitPosition = Vec2
self.SpawnFromNewPosition = true
self:I("MaxGroups:"..self.SpawnMaxGroups)
for SpawnGroupID = 1, self.SpawnMaxGroups do
self:_SetInitialPosition( SpawnGroupID )
end
return self
end
--- For planes and helicopters, when these groups go home and land on their home airbases and FARPs, they normally would taxi to the parking spot, shut-down their engines and wait forever until the Group is removed by the runtime environment.
-- This method is used to re-spawn automatically (so no extra call is needed anymore) the same group after it has landed.
-- This will enable a spawned group to be re-spawned after it lands, until it is destroyed...
@@ -1164,7 +1332,6 @@ function SPAWN:InitCleanUp( SpawnCleanUpInterval )
local SpawnGroup, SpawnCursor = self:GetFirstAliveGroup()
self:T( { "CleanUp Scheduler:", SpawnGroup } )
-- self.CleanUpFunction = routines.scheduleFunction( self._SpawnCleanUpScheduler, { self }, timer.getTime() + 1, SpawnCleanUpInterval )
self.CleanUpScheduler = SCHEDULER:New( self, self._SpawnCleanUpScheduler, {}, 1, SpawnCleanUpInterval, 0.2 )
return self
end
@@ -1282,7 +1449,7 @@ do -- Delay methods
return self
end
--- Turns the Delay On for the @{Wrapper.Group} when spawning with @{SpawnScheduled}(). In effect then the 1st group will only be spawned
--- Turns the Delay On for the @{Wrapper.Group} when spawning with @{#SpawnScheduled}(). In effect then the 1st group will only be spawned
-- after the number of seconds given in SpawnScheduled as arguments, and not immediately.
-- @param #SPAWN self
-- @return #SPAWN The SPAWN object
@@ -1301,6 +1468,30 @@ do -- Delay methods
end -- Delay methods
--- Hide the group on the map view (visible to game master slots!).
-- @param #SPAWN self
-- @return #SPAWN The SPAWN object
function SPAWN:InitHiddenOnMap()
self.SpawnHiddenOnMap = true
return self
end
--- Hide the group on MFDs (visible to game master slots!).
-- @param #SPAWN self
-- @return #SPAWN The SPAWN object
function SPAWN:InitHiddenOnMFD()
self.SpawnHiddenOnMFD = true
return self
end
--- Hide the group on planner (visible to game master slots!).
-- @param #SPAWN self
-- @return #SPAWN The SPAWN object
function SPAWN:InitHiddenOnPlanner()
self.SpawnHiddenOnPlanner = true
return self
end
--- Will spawn a group based on the internal index.
-- Note: This method uses the global _DATABASE object (an instance of @{Core.Database#DATABASE}), which contains ALL initial and new spawned objects in MOOSE.
-- @param #SPAWN self
@@ -1373,12 +1564,18 @@ function SPAWN:SpawnWithIndex( SpawnIndex, NoBirth )
self:F2( { SpawnTemplatePrefix = self.SpawnTemplatePrefix, SpawnIndex = SpawnIndex, AliveUnits = self.AliveUnits, SpawnMaxGroups = self.SpawnMaxGroups } )
if self:_GetSpawnIndex( SpawnIndex ) then
if self.SpawnFromNewPosition then
self:_SetInitialPosition( SpawnIndex )
end
if self.SpawnGroups[self.SpawnIndex].Visible then
self.SpawnGroups[self.SpawnIndex].Group:Activate()
else
local SpawnTemplate = self.SpawnGroups[self.SpawnIndex].SpawnTemplate
local SpawnZone = self.SpawnGroups[self.SpawnIndex].SpawnZone
self:T( SpawnTemplate.name )
if SpawnTemplate then
@@ -1404,6 +1601,23 @@ function SPAWN:SpawnWithIndex( SpawnIndex, NoBirth )
if self.SpawnRandomizeUnits then
for UnitID = 1, #SpawnTemplate.units do
local RandomVec2 = PointVec3:GetRandomVec2InRadius( self.SpawnOuterRadius, self.SpawnInnerRadius )
if (SpawnZone) then
local inZone = SpawnZone:IsVec2InZone(RandomVec2)
local numTries = 1
while (not inZone) and (numTries < 20) do
if not inZone then
RandomVec2 = PointVec3:GetRandomVec2InRadius( self.SpawnOuterRadius, self.SpawnInnerRadius )
numTries = numTries + 1
inZone = SpawnZone:IsVec2InZone(RandomVec2)
self:I("Retrying " .. numTries .. "spawn " .. SpawnTemplate.name .. " in Zone " .. SpawnZone:GetName() .. "!")
self:I(SpawnZone)
end
end
if (not inZone) then
self:I("Could not place unit within zone and within radius!")
RandomVec2 = SpawnZone:GetRandomVec2()
end
end
SpawnTemplate.units[UnitID].x = RandomVec2.x
SpawnTemplate.units[UnitID].y = RandomVec2.y
self:T( 'SpawnTemplate.units[' .. UnitID .. '].x = ' .. SpawnTemplate.units[UnitID].x .. ', SpawnTemplate.units[' .. UnitID .. '].y = ' .. SpawnTemplate.units[UnitID].y )
@@ -1455,12 +1669,14 @@ function SPAWN:SpawnWithIndex( SpawnIndex, NoBirth )
for UnitID = 1, #SpawnTemplate.units do
if UnitID > 1 then -- don't rotate position of unit #1
local unitXOff = SpawnTemplate.units[UnitID].x - pivotX -- rotate position offset around unit #1
local unitYOff = SpawnTemplate.units[UnitID].y - pivotY
if not self.SpawnRandomizeUnits then
if UnitID > 1 then -- don't rotate position of unit #1
local unitXOff = SpawnTemplate.units[UnitID].x - pivotX -- rotate position offset around unit #1
local unitYOff = SpawnTemplate.units[UnitID].y - pivotY
SpawnTemplate.units[UnitID].x = pivotX + (unitXOff * cosHeading) - (unitYOff * sinHeading)
SpawnTemplate.units[UnitID].y = pivotY + (unitYOff * cosHeading) + (unitXOff * sinHeading)
SpawnTemplate.units[UnitID].x = pivotX + (unitXOff * cosHeading) - (unitYOff * sinHeading)
SpawnTemplate.units[UnitID].y = pivotY + (unitYOff * cosHeading) + (unitXOff * sinHeading)
end
end
-- adjust heading of all units, including unit #1
@@ -1528,7 +1744,10 @@ function SPAWN:SpawnWithIndex( SpawnIndex, NoBirth )
-- Set tail number.
if self.SpawnInitModex then
for UnitID = 1, #SpawnTemplate.units do
SpawnTemplate.units[UnitID].onboard_num = string.format( "%03d", self.SpawnInitModex + (UnitID - 1) )
local modexnumber = string.format( "%03d", self.SpawnInitModex + (UnitID - 1) )
if self.SpawnInitModexPrefix then modexnumber = self.SpawnInitModexPrefix..modexnumber end
if self.SpawnInitModexPostfix then modexnumber = modexnumber..self.SpawnInitModexPostfix end
SpawnTemplate.units[UnitID].onboard_num = modexnumber
end
end
@@ -1546,7 +1765,20 @@ function SPAWN:SpawnWithIndex( SpawnIndex, NoBirth )
if self.SpawnInitModu then
SpawnTemplate.modulation = self.SpawnInitModu
end
-- hiding options
if self.SpawnHiddenOnPlanner then
SpawnTemplate.hiddenOnPlanner=true
end
if self.SpawnHiddenOnMFD then
SpawnTemplate.hiddenOnMFD=true
end
if self.SpawnHiddenOnMap then
SpawnTemplate.hidden=true
end
-- Set country, coalition and category.
SpawnTemplate.CategoryID = self.SpawnInitCategory or SpawnTemplate.CategoryID
SpawnTemplate.CountryID = self.SpawnInitCountry or SpawnTemplate.CountryID
@@ -1587,8 +1819,8 @@ function SPAWN:SpawnWithIndex( SpawnIndex, NoBirth )
-- If there is a SpawnFunction hook defined, call it.
if self.SpawnFunctionHook then
-- delay calling this for .1 seconds so that it hopefully comes after the BIRTH event of the group.
self.SpawnHookScheduler:Schedule( nil, self.SpawnFunctionHook, { self.SpawnGroups[self.SpawnIndex].Group, unpack( self.SpawnFunctionArguments ) }, 0.1 )
-- delay calling this for .3 seconds so that it hopefully comes after the BIRTH event of the group.
self.SpawnHookScheduler:Schedule( nil, self.SpawnFunctionHook, { self.SpawnGroups[self.SpawnIndex].Group, unpack( self.SpawnFunctionArguments ) }, 0.3 )
end
-- TODO: Need to fix this by putting an "R" in the name of the group when the group repeats.
-- if self.Repeat then
@@ -1597,6 +1829,7 @@ function SPAWN:SpawnWithIndex( SpawnIndex, NoBirth )
end
self.SpawnGroups[self.SpawnIndex].Spawned = true
self.SpawnGroups[self.SpawnIndex].Group.TemplateDonor = self.SpawnTemplatePrefix
return self.SpawnGroups[self.SpawnIndex].Group
else
-- self:E( { self.SpawnTemplatePrefix, "No more Groups to Spawn:", SpawnIndex, self.SpawnMaxGroups } )
@@ -1611,8 +1844,8 @@ end
-- @param #number SpawnTime The time interval defined in seconds between each new spawn of new groups.
-- @param #number SpawnTimeVariation The variation to be applied on the defined time interval between each new spawn.
-- The variation is a number between 0 and 1, representing the % of variation to be applied on the time interval.
-- @param #boolen WithDelay Do not spawn the **first** group immediately, but delay the spawn as per the calculation below.
-- Effectively the same as @{InitDelayOn}().
-- @param #boolean WithDelay Do not spawn the **first** group immediately, but delay the spawn as per the calculation below.
-- Effectively the same as @{#InitDelayOn}().
-- @return #SPAWN self
-- @usage
-- -- NATO helicopters engaging in the battle field.
@@ -2135,14 +2368,18 @@ end
-- @param #table Spots Table of parking spot IDs. Note that these in general are different from the numbering in the mission editor!
-- @param #SPAWN.Takeoff Takeoff (Optional) Takeoff type, i.e. either SPAWN.Takeoff.Cold or SPAWN.Takeoff.Hot. Default is Hot.
-- @return Wrapper.Group#GROUP The group that was spawned or nil when nothing was spawned.
function SPAWN:SpawnAtParkingSpot( Airbase, Spots, Takeoff ) -- R2.5
function SPAWN:SpawnAtParkingSpot( Airbase, Spots, Takeoff )
self:F( { Airbase = Airbase, Spots = Spots, Takeoff = Takeoff } )
-- Ensure that Spots parameter is a table.
if type( Spots ) ~= "table" then
Spots = { Spots }
end
if type(Airbase) == "string" then
Airbase = AIRBASE:FindByName(Airbase)
end
-- Get template group.
local group = GROUP:FindByName( self.SpawnTemplatePrefix )
@@ -2722,7 +2959,7 @@ end
-- @return Wrapper.Group#GROUP that was spawned or #nil if nothing was spawned.
-- @usage
--
-- local SpawnPointVec2 = ZONE:New( ZoneName ):GetPointVec2()
-- local SpawnPointVec2 = ZONE:New( ZoneName ):GetPointVec2()
--
-- -- Spawn at the zone center position at the height specified in the ME of the group template!
-- SpawnAirplanes:SpawnFromPointVec2( SpawnPointVec2 )
@@ -3039,7 +3276,7 @@ end
--- Get the index from a given group.
-- The function will search the name of the group for a #, and will return the number behind the #-mark.
function SPAWN:GetSpawnIndexFromGroup( SpawnGroup )
self:F2( { self.SpawnTemplatePrefix, self.SpawnAliasPrefix, SpawnGroup } )
self:F3( { self.SpawnTemplatePrefix, self.SpawnAliasPrefix, SpawnGroup } )
local IndexString = string.match( SpawnGroup:GetName(), "#(%d*)$" ):sub( 2 )
local Index = tonumber( IndexString )
@@ -3051,7 +3288,7 @@ end
--- Return the last maximum index that can be used.
function SPAWN:_GetLastIndex()
self:F( { self.SpawnTemplatePrefix, self.SpawnAliasPrefix } )
self:F3( { self.SpawnTemplatePrefix, self.SpawnAliasPrefix } )
return self.SpawnMaxGroups
end
@@ -3124,7 +3361,11 @@ function SPAWN:_GetTemplate( SpawnTemplatePrefix )
self:F( { self.SpawnTemplatePrefix, self.SpawnAliasPrefix, SpawnTemplatePrefix } )
local SpawnTemplate = nil
if _DATABASE.Templates.Groups[SpawnTemplatePrefix] == nil then
error( 'No Template exists for SpawnTemplatePrefix = ' .. SpawnTemplatePrefix )
end
local Template = _DATABASE.Templates.Groups[SpawnTemplatePrefix].Template
self:F( { Template = Template } )
@@ -3158,8 +3399,10 @@ function SPAWN:_Prepare( SpawnTemplatePrefix, SpawnIndex ) -- R2.2
if self.TweakedTemplate ~= nil and self.TweakedTemplate == true then
BASE:I( "WARNING: You are using a tweaked template." )
SpawnTemplate = self.SpawnTemplate
if self.MooseNameing then
if self.MooseNameing == true then
SpawnTemplate.name = self:SpawnGroupName( SpawnIndex )
else
SpawnTemplate.name = self:SpawnGroupName()
end
else
SpawnTemplate = self:_GetTemplate( SpawnTemplatePrefix )
@@ -3191,7 +3434,7 @@ function SPAWN:_Prepare( SpawnTemplatePrefix, SpawnIndex ) -- R2.2
end
end
end
if self.SpawnInitKeepUnitNames == false then
for UnitID = 1, #SpawnTemplate.units do
SpawnTemplate.units[UnitID].name = string.format( SpawnTemplate.name .. '-%02d', UnitID )
@@ -3199,31 +3442,197 @@ function SPAWN:_Prepare( SpawnTemplatePrefix, SpawnIndex ) -- R2.2
end
else
for UnitID = 1, #SpawnTemplate.units do
local UnitPrefix, Rest = string.match( SpawnTemplate.units[UnitID].name, "^([^#]+)#?" ):gsub( "^%s*(.-)%s*$", "%1" )
self:T( { UnitPrefix, Rest } )
local SpawnInitKeepUnitIFF = false
if string.find(SpawnTemplate.units[UnitID].name,"#IFF_",1,true) then --Razbam IFF hack for F15E etc
SpawnInitKeepUnitIFF = true
end
local UnitPrefix, Rest
if SpawnInitKeepUnitIFF == false then
UnitPrefix, Rest = string.match( SpawnTemplate.units[UnitID].name, "^([^#]+)#?" ):gsub( "^%s*(.-)%s*$", "%1" )
self:T( { UnitPrefix, Rest } )
else
UnitPrefix=SpawnTemplate.units[UnitID].name
end
SpawnTemplate.units[UnitID].name = string.format( '%s#%03d-%02d', UnitPrefix, SpawnIndex, UnitID )
SpawnTemplate.units[UnitID].unitId = nil
end
end
-- Callsign
if self.SpawnRandomCallsign and SpawnTemplate.units[1].callsign then
if type( SpawnTemplate.units[1].callsign ) ~= "number" then
-- change callsign
local min = 1
local max = 8
local ctable = CALLSIGN.Aircraft
if string.find(SpawnTemplate.units[1].type, "A-10",1,true) then
max = 12
end
if string.find(SpawnTemplate.units[1].type, "18",1,true) then
min = 9
max = 20
ctable = CALLSIGN.F18
end
if string.find(SpawnTemplate.units[1].type, "16",1,true) then
min = 9
max = 20
ctable = CALLSIGN.F16
end
if SpawnTemplate.units[1].type == "F-15E" then
min = 9
max = 18
ctable = CALLSIGN.F15E
end
local callsignnr = math.random(min,max)
local callsignname = "Enfield"
for name, value in pairs(ctable) do
if value==callsignnr then
callsignname = name
end
end
for UnitID = 1, #SpawnTemplate.units do
SpawnTemplate.units[UnitID].callsign[1] = callsignnr
SpawnTemplate.units[UnitID].callsign[2] = UnitID
SpawnTemplate.units[UnitID].callsign[3] = "1"
SpawnTemplate.units[UnitID].callsign["name"] = tostring(callsignname)..tostring(UnitID).."1"
-- UTILS.PrintTableToLog(SpawnTemplate.units[UnitID].callsign,1)
end
else
-- Russkis
for UnitID = 1, #SpawnTemplate.units do
SpawnTemplate.units[UnitID].callsign = math.random(1,999)
end
end
end
if self.SpawnInitCallSign then
for UnitID = 1, #SpawnTemplate.units do
local Callsign = SpawnTemplate.units[UnitID].callsign
if Callsign and type( Callsign ) ~= "number" then
SpawnTemplate.units[UnitID].callsign[1] = self.SpawnInitCallSignID
SpawnTemplate.units[UnitID].callsign[2] = self.SpawnInitCallSignMinor
SpawnTemplate.units[UnitID].callsign[3] = self.SpawnInitCallSignMajor
SpawnTemplate.units[UnitID].callsign["name"] = string.format("%s%d%d",self.SpawnInitCallSignName,self.SpawnInitCallSignMinor,self.SpawnInitCallSignMajor)
--UTILS.PrintTableToLog(SpawnTemplate.units[UnitID].callsign,1)
end
end
end
for UnitID = 1, #SpawnTemplate.units do
local Callsign = SpawnTemplate.units[UnitID].callsign
if Callsign then
if type( Callsign ) ~= "number" then -- blue callsign
if type( Callsign ) ~= "number" and not self.SpawnInitCallSign then -- blue callsign
-- UTILS.PrintTableToLog(Callsign,1)
Callsign[2] = ((SpawnIndex - 1) % 10) + 1
local CallsignName = SpawnTemplate.units[UnitID].callsign["name"] -- #string
CallsignName = string.match(CallsignName,"^(%a+)") -- 2.8 - only the part w/o numbers
local CallsignLen = CallsignName:len()
SpawnTemplate.units[UnitID].callsign[2] = UnitID
SpawnTemplate.units[UnitID].callsign["name"] = CallsignName:sub( 1, CallsignLen ) .. SpawnTemplate.units[UnitID].callsign[2] .. SpawnTemplate.units[UnitID].callsign[3]
else
elseif type( Callsign ) == "number" then
SpawnTemplate.units[UnitID].callsign = Callsign + SpawnIndex
end
end
-- Speed
if self.InitSpeed then
SpawnTemplate.units[UnitID].speed = self.InitSpeed
end
-- Link16
local AddProps = SpawnTemplate.units[UnitID].AddPropAircraft
if AddProps then
if SpawnTemplate.units[UnitID].AddPropAircraft.STN_L16 then
if self.SpawnInitSTN then
local octal = self.SpawnInitSTN
if UnitID > 1 then
octal = _DATABASE:GetNextSTN(self.SpawnInitSTN,SpawnTemplate.units[UnitID].name)
end
SpawnTemplate.units[UnitID].AddPropAircraft.STN_L16 = string.format("%05d",octal)
else
-- 5 digit octal with leading 0
if tonumber(SpawnTemplate.units[UnitID].AddPropAircraft.STN_L16) ~= nil then
local octal = SpawnTemplate.units[UnitID].AddPropAircraft.STN_L16
local num = UTILS.OctalToDecimal(octal)
if _DATABASE.STNS[num] ~= nil or UnitID > 1 then -- STN taken or next unit
octal = _DATABASE:GetNextSTN(octal,SpawnTemplate.units[UnitID].name)
end
SpawnTemplate.units[UnitID].AddPropAircraft.STN_L16 = string.format("%05d",octal)
else -- ED bug - chars in here
local OSTN = _DATABASE:GetNextSTN(1,SpawnTemplate.units[UnitID].name)
SpawnTemplate.units[UnitID].AddPropAircraft.STN_L16 = string.format("%05d",OSTN)
end
end
end
-- A10CII
if SpawnTemplate.units[UnitID].AddPropAircraft.SADL_TN then
-- 4 digit octal with leading 0
if self.SpawnInitSADL then
local octal = self.SpawnInitSADL
if UnitID > 1 then
octal = _DATABASE:GetNextSADL(self.SpawnInitSADL,SpawnTemplate.units[UnitID].name)
end
SpawnTemplate.units[UnitID].AddPropAircraft.SADL_TN = string.format("%04d",octal)
else
if tonumber(SpawnTemplate.units[UnitID].AddPropAircraft.SADL_TN) ~= nil then
local octal = SpawnTemplate.units[UnitID].AddPropAircraft.SADL_TN
local num = UTILS.OctalToDecimal(octal)
self.SpawnInitSADL = num -- we arrived here seeing that self.SpawnInitSADL == nil, but now that we have a SADL (num), we also need to set it to self.SpawnInitSADL in case
-- we need to get the next SADL from _DATABASE, or else UTILS.OctalToDecimal() will fail in GetNextSADL
if _DATABASE.SADL[num] ~= nil or UnitID > 1 then -- SADL taken or next unit
octal = _DATABASE:GetNextSADL(self.SpawnInitSADL,SpawnTemplate.units[UnitID].name)
end
SpawnTemplate.units[UnitID].AddPropAircraft.SADL_TN = string.format("%04d",octal)
else -- ED bug - chars in here
local OSTN = _DATABASE:GetNextSADL(1,SpawnTemplate.units[UnitID].name)
SpawnTemplate.units[UnitID].AddPropAircraft.SADL_TN = string.format("%04d",OSTN)
end
end
end
-- VoiceCallsignNumber
if SpawnTemplate.units[UnitID].AddPropAircraft.VoiceCallsignNumber and type( Callsign ) ~= "number" then
SpawnTemplate.units[UnitID].AddPropAircraft.VoiceCallsignNumber = SpawnTemplate.units[UnitID].callsign[2] .. SpawnTemplate.units[UnitID].callsign[3]
end
-- VoiceCallsignLabel
if SpawnTemplate.units[UnitID].AddPropAircraft.VoiceCallsignLabel and type( Callsign ) ~= "number" then
local CallsignName = SpawnTemplate.units[UnitID].callsign["name"] -- #string
CallsignName = string.match(CallsignName,"^(%a+)") -- 2.8 - only the part w/o numbers
local label = "NY" -- Navy One exception
if not string.find(CallsignName," ") then
label = string.upper(string.match(CallsignName,"^%a")..string.match(CallsignName,"%a$"))
end
SpawnTemplate.units[UnitID].AddPropAircraft.VoiceCallsignLabel = label
end
-- UTILS.PrintTableToLog(SpawnTemplate.units[UnitID].AddPropAircraft,1)
-- FlightLead
if SpawnTemplate.units[UnitID].datalinks and SpawnTemplate.units[UnitID].datalinks.Link16 and SpawnTemplate.units[UnitID].datalinks.Link16.settings then
SpawnTemplate.units[UnitID].datalinks.Link16.settings.flightLead = UnitID == 1 and true or false
end
-- A10CII
if SpawnTemplate.units[UnitID].datalinks and SpawnTemplate.units[UnitID].datalinks.SADL and SpawnTemplate.units[UnitID].datalinks.SADL.settings then
SpawnTemplate.units[UnitID].datalinks.SADL.settings.flightLead = UnitID == 1 and true or false
end
-- UTILS.PrintTableToLog(SpawnTemplate.units[UnitID].datalinks,1)
end
end
-- Link16 team members
for UnitID = 1, #SpawnTemplate.units do
if SpawnTemplate.units[UnitID].datalinks and SpawnTemplate.units[UnitID].datalinks.Link16 and SpawnTemplate.units[UnitID].datalinks.Link16.network then
local team = {}
local isF16 = string.find(SpawnTemplate.units[UnitID].type,"F-16",1,true) and true or false
for ID = 1, #SpawnTemplate.units do
local member = {}
member.missionUnitId = ID
if isF16 then
member.TDOA = true
end
table.insert(team,member)
end
SpawnTemplate.units[UnitID].datalinks.Link16.network.teamMembers = team
end
end
self:T3( { "Template:", SpawnTemplate } )
--UTILS.PrintTableToLog(SpawnTemplate,1)
return SpawnTemplate
end
@@ -3291,6 +3700,57 @@ function SPAWN:_RandomizeTemplate( SpawnIndex )
return self
end
--- Private method that sets the DCS#Vec2 where the Group will be spawned.
-- @param #SPAWN self
-- @param #number SpawnIndex
-- @return #SPAWN self
function SPAWN:_SetInitialPosition( SpawnIndex )
self:T( { self.SpawnTemplatePrefix, SpawnIndex, self.SpawnRandomizeZones } )
if self.SpawnFromNewPosition then
self:T( "Preparing Spawn at Vec2 ", self.SpawnInitPosition )
local SpawnVec2 = self.SpawnInitPosition
self:T( { SpawnVec2 = SpawnVec2 } )
local SpawnTemplate = self.SpawnGroups[SpawnIndex].SpawnTemplate
SpawnTemplate.route = SpawnTemplate.route or {}
SpawnTemplate.route.points = SpawnTemplate.route.points or {}
SpawnTemplate.route.points[1] = SpawnTemplate.route.points[1] or {}
SpawnTemplate.route.points[1].x = SpawnTemplate.route.points[1].x or 0
SpawnTemplate.route.points[1].y = SpawnTemplate.route.points[1].y or 0
self:T( { Route = SpawnTemplate.route } )
for UnitID = 1, #SpawnTemplate.units do
local UnitTemplate = SpawnTemplate.units[UnitID]
self:T( 'Before Translation SpawnTemplate.units[' .. UnitID .. '].x = ' .. UnitTemplate.x .. ', SpawnTemplate.units[' .. UnitID .. '].y = ' .. UnitTemplate.y )
local SX = UnitTemplate.x
local SY = UnitTemplate.y
local BX = SpawnTemplate.route.points[1].x
local BY = SpawnTemplate.route.points[1].y
local TX = SpawnVec2.x + (SX - BX)
local TY = SpawnVec2.y + (SY - BY)
UnitTemplate.x = TX
UnitTemplate.y = TY
-- TODO: Manage altitude based on landheight...
-- SpawnTemplate.units[UnitID].alt = SpawnVec2:
self:T( 'After Translation SpawnTemplate.units[' .. UnitID .. '].x = ' .. UnitTemplate.x .. ', SpawnTemplate.units[' .. UnitID .. '].y = ' .. UnitTemplate.y )
end
SpawnTemplate.route.points[1].x = SpawnVec2.x
SpawnTemplate.route.points[1].y = SpawnVec2.y
SpawnTemplate.x = SpawnVec2.x
SpawnTemplate.y = SpawnVec2.y
end
return self
end
--- Private method that randomizes the @{Core.Zone}s where the Group will be spawned.
-- @param #SPAWN self
-- @param #number SpawnIndex
@@ -3314,6 +3774,7 @@ function SPAWN:_RandomizeZones( SpawnIndex )
self:T( { SpawnVec2 = SpawnVec2 } )
local SpawnTemplate = self.SpawnGroups[SpawnIndex].SpawnTemplate
self.SpawnGroups[SpawnIndex].SpawnZone = SpawnZone
self:T( { Route = SpawnTemplate.route } )
@@ -3410,7 +3871,7 @@ end
-- TODO Need to delete this... _DATABASE does this now ...
--- @param #SPAWN self
-- @param #SPAWN self
-- @param Core.Event#EVENTDATA EventData
function SPAWN:_OnBirth( EventData )
self:F( self.SpawnTemplatePrefix )
@@ -3430,7 +3891,7 @@ function SPAWN:_OnBirth( EventData )
end
--- @param #SPAWN self
-- @param #SPAWN self
-- @param Core.Event#EVENTDATA EventData
function SPAWN:_OnDeadOrCrash( EventData )
self:F( self.SpawnTemplatePrefix )
@@ -3504,7 +3965,7 @@ function SPAWN:_OnLand( EventData )
end
--- Will detect AIR Units shutting down their engines ...
-- When the event takes place, and the method @{RepeatOnEngineShutDown} was called, the spawned Group will Re-SPAWN.
-- When the event takes place, and the method @{#InitRepeatOnEngineShutDown} was called, the spawned Group will Re-SPAWN.
-- But only when the Unit was registered to have landed.
-- @param #SPAWN self
-- @param Core.Event#EVENTDATA EventData

View File

@@ -1,36 +1,36 @@
--- **Core** - Spawn statics.
--
--
-- ===
--
--
-- ## Features:
--
--
-- * Spawn new statics from a static already defined in the mission editor.
-- * Spawn new statics from a given template.
-- * Spawn new statics from a given type.
-- * Spawn with a custom heading and location.
-- * Spawn within a zone.
-- * Spawn statics linked to units, .e.g on aircraft carriers.
--
-- ===
--
-- # Demo Missions
--
-- ## [SPAWNSTATIC Demo Missions](https://github.com/FlightControl-Master/MOOSE_MISSIONS/tree/master/SPS%20-%20Spawning%20Statics)
--
--
-- ===
--
--
-- # Demo Missions
--
-- ## [SPAWNSTATIC Demo Missions](https://github.com/FlightControl-Master/MOOSE_Demos/tree/master/Core/SpawnStatic)
--
--
-- ===
--
-- # YouTube Channel
--
-- ## [SPAWNSTATIC YouTube Channel]() [No videos yet!]
--
--
-- ## No videos yet!
--
-- ===
--
--
-- ### Author: **FlightControl**
-- ### Contributions: **funkyfranky**
--
--
-- ===
--
--
-- @module Core.SpawnStatic
-- @image Core_Spawnstatic.JPG
@@ -58,37 +58,37 @@
--- Allows to spawn dynamically new @{Wrapper.Static}s into your mission.
--
-- Through creating a copy of an existing static object template as defined in the Mission Editor (ME), SPAWNSTATIC can retireve the properties of the defined static object template (like type, category etc),
--
-- Through creating a copy of an existing static object template as defined in the Mission Editor (ME), SPAWNSTATIC can retireve the properties of the defined static object template (like type, category etc),
-- and "copy" these properties to create a new static object and place it at the desired coordinate.
--
-- New spawned @{Wrapper.Static}s get **the same name** as the name of the template Static, or gets the given name when a new name is provided at the Spawn method.
--
-- New spawned @{Wrapper.Static}s get **the same name** as the name of the template Static, or gets the given name when a new name is provided at the Spawn method.
-- By default, spawned @{Wrapper.Static}s will follow a naming convention at run-time:
--
--
-- * Spawned @{Wrapper.Static}s will have the name _StaticName_#_nnn_, where _StaticName_ is the name of the **Template Static**, and _nnn_ is a **counter from 0 to 99999**.
--
--
-- # SPAWNSTATIC Constructors
--
--
-- Firstly, we need to create a SPAWNSTATIC object that will be used to spawn new statics into the mission. There are three ways to do this.
--
--
-- ## Use another Static
--
--
-- A new SPAWNSTATIC object can be created using another static by the @{#SPAWNSTATIC.NewFromStatic}() function. All parameters such as position, heading, country will be initialized
-- from the static.
--
--
-- ## From a Template
--
--
-- A SPAWNSTATIC object can also be created from a template table using the @{#SPAWNSTATIC.NewFromTemplate}(SpawnTemplate, CountryID) function. All parameters are taken from the template.
--
--
-- ## From a Type
--
--
-- A very basic method is to create a SPAWNSTATIC object by just giving the type of the static. All parameters must be initialized from the InitXYZ functions described below. Otherwise default values
-- are used. For example, if no spawn coordinate is given, the static will be created at the origin of the map.
--
--
-- # Setting Parameters
--
--
-- Parameters such as the spawn position, heading, country etc. can be set via :Init*XYZ* functions. Note that these functions must be given before the actual spawn command!
--
--
-- * @{#SPAWNSTATIC.InitCoordinate}(Coordinate) Sets the coordinate where the static is spawned. Statics are always spawnd on the ground.
-- * @{#SPAWNSTATIC.InitHeading}(Heading) sets the orientation of the static.
-- * @{#SPAWNSTATIC.InitLivery}(LiveryName) sets the livery of the static. Not all statics support this.
@@ -99,17 +99,17 @@
-- * @{#SPAWNSTATIC.InitLinkToUnit}(Unit, OffsetX, OffsetY, OffsetAngle) links the static to a unit, e.g. to an aircraft carrier.
--
-- # Spawning the Statics
--
--
-- Once the SPAWNSTATIC object is created and parameters are initialized, the spawn command can be given. There are different methods where some can be used to directly set parameters
-- such as position and heading.
--
--
-- * @{#SPAWNSTATIC.Spawn}(Heading, NewName) spawns the static with the set parameters. Optionally, heading and name can be given. The name **must be unique**!
-- * @{#SPAWNSTATIC.SpawnFromCoordinate}(Coordinate, Heading, NewName) spawn the static at the given coordinate. Optionally, heading and name can be given. The name **must be unique**!
-- * @{#SPAWNSTATIC.SpawnFromPointVec2}(PointVec2, Heading, NewName) spawns the static at a POINT_VEC2 coordinate. Optionally, heading and name can be given. The name **must be unique**!
-- * @{#SPAWNSTATIC.SpawnFromZone}(Zone, Heading, NewName) spawns the static at the center of a @{Core.Zone}. Optionally, heading and name can be given. The name **must be unique**!
--
--
-- @field #SPAWNSTATIC SPAWNSTATIC
--
--
SPAWNSTATIC = {
ClassName = "SPAWNSTATIC",
SpawnIndex = 0,
@@ -139,9 +139,9 @@ SPAWNSTATIC = {
function SPAWNSTATIC:NewFromStatic(SpawnTemplateName, SpawnCountryID)
local self = BASE:Inherit( self, BASE:New() ) -- #SPAWNSTATIC
local TemplateStatic, CoalitionID, CategoryID, CountryID = _DATABASE:GetStaticGroupTemplate(SpawnTemplateName)
if TemplateStatic then
self.SpawnTemplatePrefix = SpawnTemplateName
self.TemplateStaticUnit = UTILS.DeepCopy(TemplateStatic.units[1])
@@ -166,11 +166,11 @@ end
function SPAWNSTATIC:NewFromTemplate(SpawnTemplate, CountryID)
local self = BASE:Inherit( self, BASE:New() ) -- #SPAWNSTATIC
self.TemplateStaticUnit = UTILS.DeepCopy(SpawnTemplate)
self.SpawnTemplatePrefix = SpawnTemplate.name
self.CountryID = CountryID or country.id.USA
return self
end
@@ -189,7 +189,7 @@ function SPAWNSTATIC:NewFromType(StaticType, StaticCategory, CountryID)
self.InitStaticCategory=StaticCategory
self.CountryID=CountryID or country.id.USA
self.SpawnTemplatePrefix=self.InitStaticType
self.InitStaticCoordinate=COORDINATE:New(0, 0, 0)
self.InitStaticHeading=0
@@ -291,7 +291,7 @@ function SPAWNSTATIC:InitCountry(CountryID)
return self
end
--- Initialize name prefix statics get. This will be appended by "#0001", "#0002" etc.
--- Initialize name prefix statics get. This will be appended by "#0001", "#0002" etc.
-- @param #SPAWNSTATIC self
-- @param #string NamePrefix Name prefix of statics spawned. Will append #0001, etc to the name.
-- @return #SPAWNSTATIC self
@@ -327,13 +327,13 @@ function SPAWNSTATIC:Spawn(Heading, NewName)
if Heading then
self.InitStaticHeading=Heading
end
if NewName then
self.InitStaticName=NewName
end
return self:_SpawnStatic(self.TemplateStaticUnit, self.CountryID)
end
--- Creates a new @{Wrapper.Static} from a POINT_VEC2.
@@ -347,7 +347,7 @@ function SPAWNSTATIC:SpawnFromPointVec2(PointVec2, Heading, NewName)
local vec2={x=PointVec2:GetX(), y=PointVec2:GetY()}
local Coordinate=COORDINATE:NewFromVec2(vec2)
return self:SpawnFromCoordinate(Coordinate, Heading, NewName)
end
@@ -362,11 +362,11 @@ function SPAWNSTATIC:SpawnFromCoordinate(Coordinate, Heading, NewName)
-- Set up coordinate.
self.InitStaticCoordinate=Coordinate
if Heading then
self.InitStaticHeading=Heading
end
if NewName then
self.InitStaticName=NewName
end
@@ -385,7 +385,7 @@ function SPAWNSTATIC:SpawnFromZone(Zone, Heading, NewName)
-- Spawn the new static at the center of the zone.
local Static = self:SpawnFromPointVec2( Zone:GetPointVec2(), Heading, NewName )
return Static
end
@@ -399,45 +399,45 @@ function SPAWNSTATIC:_SpawnStatic(Template, CountryID)
Template=Template or {}
local CountryID=CountryID or self.CountryID
if self.InitStaticType then
Template.type=self.InitStaticType
end
if self.InitStaticCategory then
Template.category=self.InitStaticCategory
end
if self.InitStaticCoordinate then
Template.x = self.InitStaticCoordinate.x
if self.InitStaticCoordinate then
Template.x = self.InitStaticCoordinate.x
Template.y = self.InitStaticCoordinate.z
Template.alt = self.InitStaticCoordinate.y
Template.alt = self.InitStaticCoordinate.y
end
if self.InitStaticHeading then
Template.heading = math.rad(self.InitStaticHeading)
Template.heading = math.rad(self.InitStaticHeading)
end
if self.InitStaticShape then
Template.shape_name=self.InitStaticShape
end
if self.InitStaticLivery then
Template.livery_id=self.InitStaticLivery
end
if self.InitStaticDead~=nil then
Template.dead=self.InitStaticDead
end
if self.InitStaticCargo~=nil then
Template.canCargo=self.InitStaticCargo
end
if self.InitStaticCargoMass~=nil then
Template.mass=self.InitStaticCargoMass
end
if self.InitLinkUnit then
Template.linkUnit=self.InitLinkUnit:GetID()
Template.linkOffset=true
@@ -446,45 +446,45 @@ function SPAWNSTATIC:_SpawnStatic(Template, CountryID)
Template.offsets.x=self.InitOffsetX
Template.offsets.angle=self.InitOffsetAngle and math.rad(self.InitOffsetAngle) or 0
end
if self.InitFarp then
Template.heliport_callsign_id = self.InitFarpCallsignID
Template.heliport_frequency = self.InitFarpFreq
Template.heliport_modulation = self.InitFarpModu
Template.unitId=nil
end
-- Increase spawn index counter.
self.SpawnIndex = self.SpawnIndex + 1
-- Name of the spawned static.
Template.name = self.InitStaticName or string.format("%s#%05d", self.SpawnTemplatePrefix, self.SpawnIndex)
-- Add and register the new static.
local mystatic=_DATABASE:AddStatic(Template.name)
-- Debug output.
self:T(Template)
-- Add static to the game.
local Static=nil --DCS#StaticObject
if self.InitFarp then
local TemplateGroup={}
local TemplateGroup={}
TemplateGroup.units={}
TemplateGroup.units[1]=Template
TemplateGroup.visible=true
TemplateGroup.hidden=false
TemplateGroup.x=Template.x
TemplateGroup.y=Template.y
TemplateGroup.name=Template.name
self:T("Spawning FARP")
self:T("Spawning FARP")
self:T({Template=Template})
self:T({TemplateGroup=TemplateGroup})
-- ED's dirty way to spawn FARPS.
Static=coalition.addGroup(CountryID, -1, TemplateGroup)
@@ -499,10 +499,10 @@ function SPAWNSTATIC:_SpawnStatic(Template, CountryID)
world.onEvent(Event)
else
self:T("Spawning Static")
self:T2({Template=Template})
self:T("Spawning Static")
self:T2({Template=Template})
Static=coalition.addStaticObject(CountryID, Template)
end
return mystatic
end

View File

@@ -21,9 +21,9 @@
-- ### Author: **FlightControl**
-- ### Contributions:
--
-- * [**Ciribob**](https://forums.eagle.ru/member.php?u=112175): Showing the way how to lase targets + how laser codes work!!! Explained the autolase script.
-- * [**EasyEB**](https://forums.eagle.ru/member.php?u=112055): Ideas and Beta Testing
-- * [**Wingthor**](https://forums.eagle.ru/member.php?u=123698): Beta Testing
-- * **Ciribob**: Showing the way how to lase targets + how laser codes work!!! Explained the autolase script.
-- * **EasyEB**: Ideas and Beta Testing
-- * **Wingthor**: Beta Testing
--
-- ===
--
@@ -33,7 +33,8 @@
do
--- @type SPOT
---
-- @type SPOT
-- @extends Core.Fsm#FSM
@@ -228,7 +229,8 @@ do
-- @param #number LaserCode Laser code.
-- @param #number Duration Duration of lasing in seconds.
function SPOT:onafterLaseOn( From, Event, To, Target, LaserCode, Duration )
self:F( { "LaseOn", Target, LaserCode, Duration } )
self:T({From, Event, To})
self:T2( { "LaseOn", Target, LaserCode, Duration } )
local function StopLase( self )
self:LaseOff()
@@ -256,6 +258,8 @@ do
self:HandleEvent( EVENTS.Dead )
self:__Lasing( -1 )
return self
end
@@ -268,7 +272,7 @@ do
-- @param #number LaserCode Laser code.
-- @param #number Duration Duration of lasing in seconds.
function SPOT:onafterLaseOnCoordinate(From, Event, To, Coordinate, LaserCode, Duration)
self:F( { "LaseOnCoordinate", Coordinate, LaserCode, Duration } )
self:T2( { "LaseOnCoordinate", Coordinate, LaserCode, Duration } )
local function StopLase( self )
self:LaseOff()
@@ -290,12 +294,14 @@ do
end
self:__Lasing(-1)
return self
end
--- @param #SPOT self
---
-- @param #SPOT self
-- @param Core.Event#EVENTDATA EventData
function SPOT:OnEventDead(EventData)
self:F( { Dead = EventData.IniDCSUnitName, Target = self.Target } )
self:T2( { Dead = EventData.IniDCSUnitName, Target = self.Target } )
if self.Target then
if EventData.IniDCSUnitName == self.TargetName then
self:F( {"Target dead ", self.TargetName } )
@@ -309,42 +315,51 @@ do
self:LaseOff()
end
end
return self
end
--- @param #SPOT self
---
-- @param #SPOT self
-- @param From
-- @param Event
-- @param To
function SPOT:onafterLasing( From, Event, To )
if self.Target and self.Target:IsAlive() then
self.SpotIR:setPoint( self.Target:GetPointVec3():AddY(1):AddY(math.random(-100,100)/100):AddX(math.random(-100,100)/100):GetVec3() )
self.SpotLaser:setPoint( self.Target:GetPointVec3():AddY(1):GetVec3() )
self:__Lasing( -0.2 )
elseif self.TargetCoord then
self:T({From, Event, To})
-- Wiggle the IR spot a bit.
local irvec3={x=self.TargetCoord.x+math.random(-100,100)/100, y=self.TargetCoord.y+math.random(-100,100)/100, z=self.TargetCoord.z} --#DCS.Vec3
local lsvec3={x=self.TargetCoord.x, y=self.TargetCoord.y, z=self.TargetCoord.z} --#DCS.Vec3
if self.Lasing then
if self.Target and self.Target:IsAlive() then
self.SpotIR:setPoint( self.Target:GetPointVec3():AddY(1):AddY(math.random(-100,100)/200):AddX(math.random(-100,100)/200):GetVec3() )
self.SpotLaser:setPoint( self.Target:GetPointVec3():AddY(1):GetVec3() )
self:__Lasing(0.2)
elseif self.TargetCoord then
self.SpotIR:setPoint(irvec3)
self.SpotLaser:setPoint(lsvec3)
self:__Lasing(-0.25)
else
self:F( { "Target is not alive", self.Target:IsAlive() } )
-- Wiggle the IR spot a bit.
local irvec3={x=self.TargetCoord.x+math.random(-100,100)/200, y=self.TargetCoord.y+math.random(-100,100)/200, z=self.TargetCoord.z} --#DCS.Vec3
local lsvec3={x=self.TargetCoord.x, y=self.TargetCoord.y, z=self.TargetCoord.z} --#DCS.Vec3
self.SpotIR:setPoint(irvec3)
self.SpotLaser:setPoint(lsvec3)
self:__Lasing(0.2)
else
self:F( { "Target is not alive", self.Target:IsAlive() } )
end
end
return self
end
--- @param #SPOT self
---
-- @param #SPOT self
-- @param From
-- @param Event
-- @param To
-- @return #SPOT
function SPOT:onafterLaseOff( From, Event, To )
self:F( {"Stopped lasing for ", self.Target and self.Target:GetName() or "coord", SpotIR = self.SportIR, SpotLaser = self.SpotLaser } )
self:T({From, Event, To})
self:T2( {"Stopped lasing for ", self.Target and self.Target:GetName() or "coord", SpotIR = self.SportIR, SpotLaser = self.SpotLaser } )
self.Lasing = false
@@ -383,4 +398,4 @@ do
return self
end
end
end

View File

@@ -107,7 +107,7 @@ _TIMERID=0
--- TIMER class version.
-- @field #string version
TIMER.version="0.1.2"
TIMER.version="0.2.0"
-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
-- TODO list
@@ -222,7 +222,20 @@ function TIMER:Stop(Delay)
-- Remove timer function.
self:T(self.lid..string.format("Stopping timer by removing timer function after %d calls!", self.ncalls))
timer.removeFunction(self.tid)
-- We use a pcall here because if the DCS timer does not exist any more, it crashes the whole script!
local status=pcall(
function ()
timer.removeFunction(self.tid)
end
)
-- Debug messages.
if status then
self:T2(self.lid..string.format("Stopped timer!"))
else
self:E(self.lid..string.format("WARNING: Could not remove timer function! isrunning=%s", tostring(self.isrunning)))
end
-- Not running any more.
self.isrunning=false

File diff suppressed because it is too large Load Diff

View File

@@ -135,6 +135,22 @@ do -- env
end -- env
do -- radio
---@type radio
-- @field #radio.modulation modulation
---
-- @type radio.modulation
-- @field AM
-- @field FM
radio = {}
radio.modulation = {}
radio.modulation.AM = 0
radio.modulation.FM = 1
end
do -- timer
@@ -329,11 +345,11 @@ end -- country
do -- Command
--- @type Command
-- @type Command
-- @field #string id
-- @field #Command.params params
--- @type Command.params
-- @type Command.params
end -- Command
@@ -374,7 +390,7 @@ end -- coalition
do -- Types
--- @type Desc
-- @type Desc
-- @field #number speedMax0 Max speed in meters/second at zero altitude.
-- @field #number massEmpty Empty mass in kg.
-- @field #number tankerType Type of refueling system: 0=boom, 1=probe.
@@ -471,16 +487,16 @@ do -- Types
-- @type AttributeNameArray
-- @list <#AttributeName>
--- @type Zone
-- @type Zone
-- @field DCSVec3#Vec3 point
-- @field #number radius
Zone = {}
--- @type ModelTime
-- @type ModelTime
-- @extends #number
--- @type Time
-- @type Time
-- @extends #number
--- A task descriptor (internal structure for DCS World). See [https://wiki.hoggitworld.com/view/Category:Tasks](https://wiki.hoggitworld.com/view/Category:Tasks).
@@ -489,7 +505,7 @@ do -- Types
-- @field #string id
-- @field #Task.param param
--- @type Task.param
-- @type Task.param
--- List of @{#Task}
-- @type TaskArray
@@ -536,7 +552,7 @@ do -- Object
-- @field SCENERY
-- @field CARGO
--- @type Object.Desc
-- @type Object.Desc
-- @extends #Desc
-- @field #number life initial life level
-- @field #Box3 box bounding box of collision geometry
@@ -793,11 +809,118 @@ do -- Airbase
-- @function [parent=#Airbase] getDesc
-- @param self
-- @return #Airbase.Desc
--- Returns the warehouse object associated with the airbase object. Can then be used to call the warehouse class functions to modify the contents of the warehouse.
-- @function [parent=#Airbase] getWarehouse
-- @param self
-- @return #Warehouse The DCS warehouse object of this airbase.
--- Enables or disables the airbase and FARP auto capture game mechanic where ownership of a base can change based on the presence of ground forces or the
-- default setting assigned in the editor.
-- @function [parent=#Airbase] autoCapture
-- @param self
-- @param #boolean setting `true` : enables autoCapture behavior, `false` : disables autoCapture behavior
--- Returns the current autoCapture setting for the passed base.
-- @function [parent=#Airbase] autoCaptureIsOn
-- @param self
-- @return #boolean `true` if autoCapture behavior is enabled and `false` otherwise.
--- Changes the passed airbase object's coalition to the set value. Must be used with Airbase.autoCapture to disable auto capturing of the base,
-- otherwise the base can revert back to a different coalition depending on the situation and built in game capture rules.
-- @function [parent=#Airbase] setCoalition
-- @param self
-- @param #number coa The new owner coalition: 0=neutra, 1=red, 2=blue.
--- Returns the wsType of every object that exists in DCS. A wsType is a table consisting of 4 entries indexed numerically.
-- It can be used to broadly categorize object types. The table can be broken down as: {mainCategory, subCat1, subCat2, index}
-- @function [parent=#Airbase] getResourceMap
-- @param self
-- @return #table wsType of every object that exists in DCS.
Airbase = {} --#Airbase
end -- Airbase
do -- Warehouse
--- [DCS Class Warehouse](https://wiki.hoggitworld.com/view/DCS_Class_Warehouse)
-- The warehouse class gives control over warehouses that exist in airbase objects. These warehouses can limit the aircraft, munitions, and fuel available to coalition aircraft.
-- @type Warehouse
--- Get a warehouse by passing its name.
-- @function [parent=#Warehouse] getByName
-- @param #string Name Name of the warehouse.
-- @return #Warehouse The warehouse object.
--- Adds the passed amount of a given item to the warehouse.
-- itemName is the typeName associated with the item: "weapons.missiles.AIM_54C_Mk47"
-- A wsType table can also be used, however the last digit with wsTypes has been known to change. {4, 4, 7, 322}
-- @function [parent=#Warehouse] addItem
-- @param self
-- @param #string itemName Name of the item.
-- @param #number count Number of items to add.
--- Returns the number of the passed type of item currently in a warehouse object.
-- @function [parent=#Warehouse] getItemCount
-- @param self
-- @param #string itemName Name of the item.
--- Sets the passed amount of a given item to the warehouse.
-- @function [parent=#Warehouse] setItem
-- @param self
-- @param #string itemName Name of the item.
-- @param #number count Number of items to add.
--- Removes the amount of the passed item from the warehouse.
-- @function [parent=#Warehouse] removeItem
-- @param self
-- @param #string itemName Name of the item.
-- @param #number count Number of items to be removed.
--- Adds the passed amount of a liquid fuel into the warehouse inventory.
-- @function [parent=#Warehouse] addLiquid
-- @param self
-- @param #number liquidType Type of liquid to add: 0=jetfuel, 1=aviation gasoline, 2=MW50, 3=Diesel.
-- @param #number count Amount of liquid to add.
--- Returns the amount of the passed liquid type within a given warehouse.
-- @function [parent=#Warehouse] getLiquidAmount
-- @param self
-- @param #number liquidType Type of liquid to add: 0=jetfuel, 1=aviation gasoline, 2=MW50, 3=Diesel.
-- @return #number Amount of liquid.
--- Sets the passed amount of a liquid fuel into the warehouse inventory.
-- @function [parent=#Warehouse] setLiquidAmount
-- @param self
-- @param #number liquidType Type of liquid to add: 0=jetfuel, 1=aviation gasoline, 2=MW50, 3=Diesel.
-- @param #number count Amount of liquid.
--- Removes the set amount of liquid from the inventory in a warehouse.
-- @function [parent=#Warehouse] setLiquidAmount
-- @param self
-- @param #number liquidType Type of liquid to add: 0=jetfuel, 1=aviation gasoline, 2=MW50, 3=Diesel.
-- @param #number count Amount of liquid.
--- Returns the airbase object associated with the warehouse object.
-- @function [parent=#Warehouse] getOwner
-- @param self
-- @return #Airbase The airbase object owning this warehouse.
--- Returns a full itemized list of everything currently in a warehouse. If a category is set to unlimited then the table will be returned empty.
-- Aircraft and weapons are indexed by strings. Liquids are indexed by number.
-- @function [parent=#Warehouse] getInventory
-- @param self
-- @param #string itemName Name of the item.
-- @return #table Itemized list of everything currently in a warehouse
Warehouse = {} --#Warehouse
end
do -- Spot
--- [DCS Class Spot](https://wiki.hoggitworld.com/view/DCS_Class_Spot)
@@ -860,7 +983,7 @@ do -- Spot
end -- Spot
do -- Controller
--- Controller is an object that performs A.I.-routines. Other words controller is an instance of A.I.. Controller stores current main task, active enroute tasks and behavior options. Controller performs commands. Please, read DCS A-10C GUI Manual EN.pdf chapter "Task Planning for Unit Groups", page 91 to understand A.I. system of DCS:A-10C.
--- Controller is an object that performs A.I.-tasks. Other words controller is an instance of A.I.. Controller stores current main task, active enroute tasks and behavior options. Controller performs commands. Please, read DCS A-10C GUI Manual EN.pdf chapter "Task Planning for Unit Groups", page 91 to understand A.I. system of DCS:A-10C.
--
-- This class has 2 types of functions:
--
@@ -978,7 +1101,7 @@ end -- Controller
do -- Unit
--- @type Unit
-- @type Unit
-- @extends #CoalitionObject
-- @field ID Identifier of an unit. It assigned to an unit by the Mission Editor automatically.
-- @field #Unit.Category Category
@@ -1093,15 +1216,18 @@ do -- Unit
-- @field #Distance detectionDistanceHRM detection distance for RCS=1m^2 in high-resolution mapping mode, nil if radar has no HRM
-- @field #Unit.Radar.detectionDistanceAir detectionDistanceAir detection distance for RCS=1m^2 airborne target, nil if radar doesn't support air search
--- @type Unit.Radar.detectionDistanceAir
--- A radar.
-- @type Unit.Radar.detectionDistanceAir
-- @field #Unit.Radar.detectionDistanceAir.upperHemisphere upperHemisphere
-- @field #Unit.Radar.detectionDistanceAir.lowerHemisphere lowerHemisphere
--- @type Unit.Radar.detectionDistanceAir.upperHemisphere
--- A radar.
-- @type Unit.Radar.detectionDistanceAir.upperHemisphere
-- @field #Distance headOn
-- @field #Distance tailOn
--- @type Unit.Radar.detectionDistanceAir.lowerHemisphere
--- A radar.
-- @type Unit.Radar.detectionDistanceAir.lowerHemisphere
-- @field #Distance headOn
-- @field #Distance tailOn
@@ -1403,22 +1529,26 @@ do -- AI
-- @field IR_POINTER
-- @field LASER
--- @type AI.Task.WaypointType
---
-- @type AI.Task.WaypointType
-- @field TAKEOFF
-- @field TAKEOFF_PARKING
-- @field TURNING_POINT
-- @field TAKEOFF_PARKING_HOT
-- @field LAND
--- @type AI.Task.TurnMethod
---
-- @type AI.Task.TurnMethod
-- @field FLY_OVER_POINT
-- @field FIN_POINT
--- @type AI.Task.AltitudeType
---
-- @type AI.Task.AltitudeType
-- @field BARO
-- @field RADIO
--- @type AI.Task.VehicleFormation
---
-- @type AI.Task.VehicleFormation
-- @field OFF_ROAD
-- @field ON_ROAD
-- @field RANK
@@ -1428,27 +1558,30 @@ do -- AI
-- @field ECHELON_LEFT
-- @field ECHELON_RIGHT
--- @type AI.Option
---
-- @type AI.Option
-- @field #AI.Option.Air Air
-- @field #AI.Option.Ground Ground
-- @field #AI.Option.Naval Naval
--- @type AI.Option.Air
---
-- @type AI.Option.Air
-- @field #AI.Option.Air.id id
-- @field #AI.Option.Air.val val
--- @type AI.Option.Ground
---
-- @type AI.Option.Ground
-- @field #AI.Option.Ground.id id
-- @field #AI.Option.Ground.val val
-- @field #AI.Option.Ground.mid mid
-- @field #AI.Option.Ground.mval mval
--
--- @type AI.Option.Naval
-- @type AI.Option.Naval
-- @field #AI.Option.Naval.id id
-- @field #AI.Option.Naval.val val
--- @type AI.Option.Air.id
---
-- @type AI.Option.Air.id
-- @field NO_OPTION
-- @field ROE
-- @field REACTION_ON_THREAT
@@ -1470,73 +1603,61 @@ do -- AI
-- @field OPTION_RADIO_USAGE_KILL
-- @field JETT_TANKS_IF_EMPTY
-- @field FORCED_ATTACK
--- @type AI.Option.Air.id.FORMATION
-- @field LINE_ABREAST
-- @field TRAIL
-- @field WEDGE
-- @field ECHELON_RIGHT
-- @field ECHELON_LEFT
-- @field FINGER_FOUR
-- @field SPREAD_FOUR
-- @field WW2_BOMBER_ELEMENT
-- @field WW2_BOMBER_ELEMENT_HEIGHT
-- @field WW2_FIGHTER_VIC
-- @field HEL_WEDGE
-- @field HEL_ECHELON
-- @field HEL_FRONT
-- @field HEL_COLUMN
-- @field COMBAT_BOX
-- @field JAVELIN_DOWN
--- @type AI.Option.Air.val
---
-- @type AI.Option.Air.val
-- @field #AI.Option.Air.val.ROE ROE
-- @field #AI.Option.Air.val.REACTION_ON_THREAT REACTION_ON_THREAT
-- @field #AI.Option.Air.val.RADAR_USING RADAR_USING
-- @field #AI.Option.Air.val.FLARE_USING FLARE_USING
--- @type AI.Option.Air.val.ROE
---
-- @type AI.Option.Air.val.ROE
-- @field WEAPON_FREE
-- @field OPEN_FIRE_WEAPON_FREE
-- @field OPEN_FIRE
-- @field RETURN_FIRE
-- @field WEAPON_HOLD
--- @type AI.Option.Air.val.REACTION_ON_THREAT
---
-- @type AI.Option.Air.val.REACTION_ON_THREAT
-- @field NO_REACTION
-- @field PASSIVE_DEFENCE
-- @field EVADE_FIRE
-- @field BYPASS_AND_ESCAPE
-- @field ALLOW_ABORT_MISSION
--- @type AI.Option.Air.val.RADAR_USING
---
-- @type AI.Option.Air.val.RADAR_USING
-- @field NEVER
-- @field FOR_ATTACK_ONLY
-- @field FOR_SEARCH_IF_REQUIRED
-- @field FOR_CONTINUOUS_SEARCH
--- @type AI.Option.Air.val.FLARE_USING
---
-- @type AI.Option.Air.val.FLARE_USING
-- @field NEVER
-- @field AGAINST_FIRED_MISSILE
-- @field WHEN_FLYING_IN_SAM_WEZ
-- @field WHEN_FLYING_NEAR_ENEMIES
--- @type AI.Option.Air.val.ECM_USING
---
-- @type AI.Option.Air.val.ECM_USING
-- @field NEVER_USE
-- @field USE_IF_ONLY_LOCK_BY_RADAR
-- @field USE_IF_DETECTED_LOCK_BY_RADAR
-- @field ALWAYS_USE
--- @type AI.Option.Air.val.MISSILE_ATTACK
---
-- @type AI.Option.Air.val.MISSILE_ATTACK
-- @field MAX_RANGE
-- @field NEZ_RANGE
-- @field HALF_WAY_RMAX_NEZ
-- @field TARGET_THREAT_EST
-- @field RANDOM_RANGE
--- @type AI.Option.Ground.id
---
-- @type AI.Option.Ground.id
-- @field NO_OPTION
-- @field ROE @{#AI.Option.Ground.val.ROE}
-- @field FORMATION
@@ -1545,42 +1666,51 @@ do -- AI
-- @field ENGAGE_AIR_WEAPONS
-- @field AC_ENGAGEMENT_RANGE_RESTRICTION
--- @type AI.Option.Ground.mid -- Moose added
---
-- @type AI.Option.Ground.mid -- Moose added
-- @field RESTRICT_AAA_MIN 27
-- @field RESTRICT_AAA_MAX 29
-- @field RESTRICT_TARGETS @{#AI.Option.Ground.mval.ENGAGE_TARGETS} 28
--- @type AI.Option.Ground.val
---
-- @type AI.Option.Ground.val
-- @field #AI.Option.Ground.val.ROE ROE
-- @field #AI.Option.Ground.val.ALARM_STATE ALARM_STATE
-- @field #AI.Option.Ground.val.ENGAGE_TARGETS RESTRICT_TARGETS
--- @type AI.Option.Ground.val.ROE
---
-- @type AI.Option.Ground.val.ROE
-- @field OPEN_FIRE
-- @field RETURN_FIRE
-- @field WEAPON_HOLD
--- @type AI.Option.Ground.mval -- Moose added
---
-- @type AI.Option.Ground.mval -- Moose added
-- @field #AI.Option.Ground.mval.ENGAGE_TARGETS ENGAGE_TARGETS
--- @type AI.Option.Ground.mval.ENGAGE_TARGETS -- Moose added
---
-- @type AI.Option.Ground.mval.ENGAGE_TARGETS -- Moose added
-- @field ANY_TARGET -- 0
-- @field AIR_UNITS_ONLY -- 1
-- @field GROUND_UNITS_ONLY -- 2
--- @type AI.Option.Ground.val.ALARM_STATE
---
-- @type AI.Option.Ground.val.ALARM_STATE
-- @field AUTO
-- @field GREEN
-- @field RED
--- @type AI.Option.Naval.id
---
-- @type AI.Option.Naval.id
-- @field NO_OPTION
-- @field ROE
--- @type AI.Option.Naval.val
---
-- @type AI.Option.Naval.val
-- @field #AI.Option.Naval.val.ROE ROE
--- @type AI.Option.Naval.val.ROE
---
-- @type AI.Option.Naval.val.ROE
-- @field OPEN_FIRE
-- @field RETURN_FIRE
-- @field WEAPON_HOLD

File diff suppressed because it is too large Load Diff

View File

@@ -10,9 +10,7 @@
--
-- ===
--
-- ## Missions:
--
-- [ABP - Airbase Police](https://github.com/FlightControl-Master/MOOSE_MISSIONS/tree/master/ABP%20-%20Airbase%20Police)
-- ## Missions: None
--
-- ===
--
@@ -20,13 +18,15 @@
-- ### Author: FlightControl - Framework Design & Programming
-- ### Refactoring to use the Runway auto-detection: Applevangelist
-- @date August 2022
-- Last Update Nov 2023
--
-- ===
--
-- @module Functional.ATC_Ground
-- @image Air_Traffic_Control_Ground_Operations.JPG
--- @type ATC_GROUND
---
-- @type ATC_GROUND
-- @field Core.Set#SET_CLIENT SetClient
-- @extends Core.Base#BASE
@@ -39,7 +39,8 @@ ATC_GROUND = {
AirbaseNames = nil,
}
--- @type ATC_GROUND.AirbaseNames
---
-- @type ATC_GROUND.AirbaseNames
-- @list <#string>
@@ -51,7 +52,7 @@ function ATC_GROUND:New( Airbases, AirbaseList )
-- Inherits from BASE
local self = BASE:Inherit( self, BASE:New() ) -- #ATC_GROUND
self:E( { self.ClassName, Airbases } )
self:T( { self.ClassName, Airbases } )
self.Airbases = Airbases
self.AirbaseList = AirbaseList
@@ -82,7 +83,7 @@ function ATC_GROUND:New( Airbases, AirbaseList )
end
self.SetClient:ForEachClient(
--- @param Wrapper.Client#CLIENT Client
-- @param Wrapper.Client#CLIENT Client
function( Client )
Client:SetState( self, "Speeding", false )
Client:SetState( self, "Warnings", 0)
@@ -246,11 +247,11 @@ function ATC_GROUND:SetMaximumKickSpeedMiph( MaximumKickSpeedMiph, Airbase )
return self
end
--- @param #ATC_GROUND self
-- @param #ATC_GROUND self
function ATC_GROUND:_AirbaseMonitor()
self.SetClient:ForEachClient(
--- @param Wrapper.Client#CLIENT Client
-- @param Wrapper.Client#CLIENT Client
function( Client )
if Client:IsAlive() then
@@ -258,7 +259,7 @@ function ATC_GROUND:_AirbaseMonitor()
local IsOnGround = Client:InAir() == false
for AirbaseID, AirbaseMeta in pairs( self.Airbases ) do
self:E( AirbaseID, AirbaseMeta.KickSpeed )
self:T( AirbaseID, AirbaseMeta.KickSpeed )
if AirbaseMeta.Monitor == true and Client:IsInZone( AirbaseMeta.ZoneBoundary ) then
@@ -271,7 +272,7 @@ function ATC_GROUND:_AirbaseMonitor()
if IsOnGround then
local Taxi = Client:GetState( self, "Taxi" )
self:E( Taxi )
self:T( Taxi )
if Taxi == false then
local Velocity = VELOCITY:New( AirbaseMeta.KickSpeed or self.KickSpeed )
Client:Message( "Welcome to " .. AirbaseID .. ". The maximum taxiing speed is " ..
@@ -331,7 +332,7 @@ function ATC_GROUND:_AirbaseMonitor()
Client:SetState( self, "Warnings", SpeedingWarnings + 1 )
else
MESSAGE:New( "Penalty! Player " .. Client:GetPlayerName() .. " has been kicked, due to a severe airbase traffic rule violation ...", 10, "ATC" ):ToAll()
--- @param Wrapper.Client#CLIENT Client
-- @param Wrapper.Client#CLIENT Client
Client:Destroy()
Client:SetState( self, "Speeding", false )
Client:SetState( self, "Warnings", 0 )
@@ -363,7 +364,7 @@ function ATC_GROUND:_AirbaseMonitor()
Client:SetState( self, "OffRunwayWarnings", OffRunwayWarnings + 1 )
else
MESSAGE:New( "Penalty! Player " .. Client:GetPlayerName() .. " has been kicked, due to a severe airbase traffic rule violation ...", 10, "ATC" ):ToAll()
--- @param Wrapper.Client#CLIENT Client
-- @param Wrapper.Client#CLIENT Client
Client:Destroy()
Client:SetState( self, "IsOffRunway", false )
Client:SetState( self, "OffRunwayWarnings", 0 )
@@ -424,13 +425,20 @@ ATC_GROUND_UNIVERSAL = {
--- Creates a new ATC\_GROUND\_UNIVERSAL object. This works on any map.
-- @param #ATC_GROUND_UNIVERSAL self
-- @param AirbaseList (Optional) A table of Airbase Names.
-- @param AirbaseList A table of Airbase Names. Leave empty to cover **all** airbases of the map.
-- @return #ATC_GROUND_UNIVERSAL self
-- @usage
-- -- define monitoring for one airbase
-- local atc=ATC_GROUND_UNIVERSAL:New({AIRBASE.Syria.Gecitkale})
-- -- set kick speed
-- atc:SetKickSpeed(UTILS.KnotsToMps(20))
-- -- start monitoring evey 10 secs
-- atc:Start(10)
function ATC_GROUND_UNIVERSAL:New(AirbaseList)
-- Inherits from BASE
local self = BASE:Inherit( self, BASE:New() ) -- #ATC_GROUND
self:E( { self.ClassName } )
self:T( { self.ClassName } )
self.Airbases = {}
@@ -440,6 +448,13 @@ function ATC_GROUND_UNIVERSAL:New(AirbaseList)
self.AirbaseList = AirbaseList
if not self.AirbaseList then
self.AirbaseList = {}
for _name,_ in pairs(_DATABASE.AIRBASES) do
self.AirbaseList[_name]=_name
end
end
self.SetClient = SET_CLIENT:New():FilterCategories( "plane" ):FilterStart()
@@ -460,8 +475,9 @@ function ATC_GROUND_UNIVERSAL:New(AirbaseList)
self.Airbases[AirbaseName].Monitor = true
end
self.SetClient:ForEachClient(
--- @param Wrapper.Client#CLIENT Client
-- @param Wrapper.Client#CLIENT Client
function( Client )
Client:SetState( self, "Speeding", false )
Client:SetState( self, "Warnings", 0)
@@ -679,9 +695,10 @@ end
-- @param #ATC_GROUND_UNIVERSAL self
-- @return #ATC_GROUND_UNIVERSAL self
function ATC_GROUND_UNIVERSAL:_AirbaseMonitor()
self:I("_AirbaseMonitor")
self.SetClient:ForEachClient(
--- @param Wrapper.Client#CLIENT Client
--- Nameless function
-- @param Wrapper.Client#CLIENT Client
function( Client )
if Client:IsAlive() then
@@ -689,7 +706,7 @@ function ATC_GROUND_UNIVERSAL:_AirbaseMonitor()
local IsOnGround = Client:InAir() == false
for AirbaseID, AirbaseMeta in pairs( self.Airbases ) do
self:E( AirbaseID, AirbaseMeta.KickSpeed )
self:T( AirbaseID, AirbaseMeta.KickSpeed )
if AirbaseMeta.Monitor == true and Client:IsInZone( AirbaseMeta.ZoneBoundary ) then
@@ -706,7 +723,7 @@ function ATC_GROUND_UNIVERSAL:_AirbaseMonitor()
if IsOnGround then
local Taxi = Client:GetState( self, "Taxi" )
self:E( Taxi )
self:T( Taxi )
if Taxi == false then
local Velocity = VELOCITY:New( AirbaseMeta.KickSpeed or self.KickSpeed )
Client:Message( "Welcome to " .. AirbaseID .. ". The maximum taxiing speed is " ..
@@ -766,7 +783,7 @@ function ATC_GROUND_UNIVERSAL:_AirbaseMonitor()
Client:SetState( self, "Warnings", SpeedingWarnings + 1 )
else
MESSAGE:New( "Penalty! Player " .. Client:GetPlayerName() .. " has been kicked, due to a severe airbase traffic rule violation ...", 10, "ATC" ):ToAll()
--- @param Wrapper.Client#CLIENT Client
-- @param Wrapper.Client#CLIENT Client
Client:Destroy()
Client:SetState( self, "Speeding", false )
Client:SetState( self, "Warnings", 0 )
@@ -798,7 +815,7 @@ function ATC_GROUND_UNIVERSAL:_AirbaseMonitor()
Client:SetState( self, "OffRunwayWarnings", OffRunwayWarnings + 1 )
else
MESSAGE:New( "Penalty! Player " .. Client:GetPlayerName() .. " has been kicked, due to a severe airbase traffic rule violation ...", 10, "ATC" ):ToAll()
--- @param Wrapper.Client#CLIENT Client
-- @param Wrapper.Client#CLIENT Client
Client:Destroy()
Client:SetState( self, "IsOffRunway", false )
Client:SetState( self, "OffRunwayWarnings", 0 )
@@ -838,15 +855,16 @@ end
--- Start SCHEDULER for ATC_GROUND_UNIVERSAL object.
-- @param #ATC_GROUND_UNIVERSAL self
-- @param RepeatScanSeconds Time in second for defining occurency of alerts.
-- @param RepeatScanSeconds Time in second for defining schedule of alerts.
-- @return #ATC_GROUND_UNIVERSAL self
function ATC_GROUND_UNIVERSAL:Start( RepeatScanSeconds )
RepeatScanSeconds = RepeatScanSeconds or 0.05
self.AirbaseMonitor = SCHEDULER:New( self, self._AirbaseMonitor, { self }, 0, 2, RepeatScanSeconds )
self.AirbaseMonitor = SCHEDULER:New( self, self._AirbaseMonitor, { self }, 0, RepeatScanSeconds )
return self
end
--- @type ATC_GROUND_CAUCASUS
---
-- @type ATC_GROUND_CAUCASUS
-- @extends #ATC_GROUND
--- # ATC\_GROUND\_CAUCASUS, extends @{#ATC_GROUND_UNIVERSAL}
@@ -981,12 +999,12 @@ end
-- @return nothing
function ATC_GROUND_CAUCASUS:Start( RepeatScanSeconds )
RepeatScanSeconds = RepeatScanSeconds or 0.05
self.AirbaseMonitor = SCHEDULER:New( self, self._AirbaseMonitor, { self }, 0, 2, RepeatScanSeconds )
self.AirbaseMonitor = SCHEDULER:New( self, self._AirbaseMonitor, { self }, 0, RepeatScanSeconds )
end
--- @type ATC_GROUND_NEVADA
---
-- @type ATC_GROUND_NEVADA
-- @extends #ATC_GROUND
@@ -1120,11 +1138,11 @@ end
-- @return nothing
function ATC_GROUND_NEVADA:Start( RepeatScanSeconds )
RepeatScanSeconds = RepeatScanSeconds or 0.05
self.AirbaseMonitor = SCHEDULER:New( self, self._AirbaseMonitor, { self }, 0, 2, RepeatScanSeconds )
self.AirbaseMonitor = SCHEDULER:New( self, self._AirbaseMonitor, { self }, 0, RepeatScanSeconds )
end
--- @type ATC_GROUND_NORMANDY
---
-- @type ATC_GROUND_NORMANDY
-- @extends #ATC_GROUND
@@ -1277,10 +1295,11 @@ end
-- @return nothing
function ATC_GROUND_NORMANDY:Start( RepeatScanSeconds )
RepeatScanSeconds = RepeatScanSeconds or 0.05
self.AirbaseMonitor = SCHEDULER:New( self, self._AirbaseMonitor, { self }, 0, 2, RepeatScanSeconds )
self.AirbaseMonitor = SCHEDULER:New( self, self._AirbaseMonitor, { self }, 0, RepeatScanSeconds )
end
--- @type ATC_GROUND_PERSIANGULF
---
-- @type ATC_GROUND_PERSIANGULF
-- @extends #ATC_GROUND
@@ -1419,11 +1438,11 @@ end
-- @return nothing
function ATC_GROUND_PERSIANGULF:Start( RepeatScanSeconds )
RepeatScanSeconds = RepeatScanSeconds or 0.05
self.AirbaseMonitor = SCHEDULER:New( self, self._AirbaseMonitor, { self }, 0, 2, RepeatScanSeconds )
self.AirbaseMonitor = SCHEDULER:New( self, self._AirbaseMonitor, { self }, 0, RepeatScanSeconds )
end
--- @type ATC_GROUND_MARIANAISLANDS
-- @type ATC_GROUND_MARIANAISLANDS
-- @extends #ATC_GROUND
@@ -1517,7 +1536,7 @@ end
-- * @{#ATC_GROUND.SetMaximumKickSpeedKmph}(): Set the maximum speed allowed at an airbase in kilometers per hour.
-- * @{#ATC_GROUND.SetMaximumKickSpeedMiph}(): Set the maximum speed allowed at an airbase in miles per hour.
--
---- @field #ATC_GROUND_MARIANAISLANDS
-- @field #ATC_GROUND_MARIANAISLANDS
ATC_GROUND_MARIANAISLANDS = {
ClassName = "ATC_GROUND_MARIANAISLANDS",
}
@@ -1529,7 +1548,7 @@ ATC_GROUND_MARIANAISLANDS = {
function ATC_GROUND_MARIANAISLANDS:New( AirbaseNames )
-- Inherits from BASE
local self = BASE:Inherit( self, ATC_GROUND_UNIVERSAL:New( self.Airbases, AirbaseNames ) )
local self = BASE:Inherit( self, ATC_GROUND_UNIVERSAL:New( AirbaseNames ) )
self:SetKickSpeedKmph( 50 )
self:SetMaximumKickSpeedKmph( 150 )
@@ -1543,5 +1562,5 @@ end
-- @return nothing
function ATC_GROUND_MARIANAISLANDS:Start( RepeatScanSeconds )
RepeatScanSeconds = RepeatScanSeconds or 0.05
self.AirbaseMonitor = SCHEDULER:New( self, self._AirbaseMonitor, { self }, 0, 2, RepeatScanSeconds )
self.AirbaseMonitor = SCHEDULER:New( self, self._AirbaseMonitor, { self }, 0, RepeatScanSeconds )
end

View File

@@ -0,0 +1,806 @@
--- **Functional** -- Send a truck to supply artillery groups.
--
-- ===
--
-- **AMMOTRUCK** - Send a truck to supply artillery groups.
--
-- ===
--
-- ## Missions:
--
-- Demo missions can be found on [GitHub](https://github.com/FlightControl-Master/MOOSE_MISSIONS/tree/develop/Functional/AmmoTruck)
--
-- ===
--
-- ### Author : **applevangelist**
--
-- @module Functional.AmmoTruck
-- @image Artillery.JPG
--
-- Last update: July 2023
-------------------------------------------------------------------------
--- **AMMOTRUCK** class, extends Core.Fsm#FSM
-- @type AMMOTRUCK
-- @field #string ClassName Class Name
-- @field #string lid Lid for log entries
-- @field #string version Version string
-- @field #string alias Alias name
-- @field #boolean debug Debug flag
-- @field #table trucklist List of (alive) #AMMOTRUCK.data trucks
-- @field #table targetlist List of (alive) #AMMOTRUCK.data artillery
-- @field #number coalition Coalition this is for
-- @field Core.Set#SET_GROUP truckset SET of trucks
-- @field Core.Set#SET_GROUP targetset SET of artillery
-- @field #table remunitionqueue List of (alive) #AMMOTRUCK.data artillery to be reloaded
-- @field #table waitingtargets List of (alive) #AMMOTRUCK.data artillery waiting
-- @field #number ammothreshold Threshold (min) ammo before sending a truck
-- @field #number remunidist Max distance trucks will go
-- @field #number monitor Monitor interval in seconds
-- @field #number unloadtime Unload time in seconds
-- @field #number waitingtime Max waiting time in seconds
-- @field #boolean routeonroad Route truck on road if true (default)
-- @field #number reloads Number of reloads a single truck can do before he must return home
-- @extends Core.Fsm#FSM
--- *Amateurs talk about tactics, but professionals study logistics.* - General Robert H Barrow, USMC
--
-- Simple Class to re-arm your artillery with trucks.
--
-- #AMMOTRUCK
--
-- * Controls a SET\_GROUP of trucks which will re-arm a SET\_GROUP of artillery groups when they run out of ammunition.
--
-- ## 1 The AMMOTRUCK concept
--
-- A SET\_GROUP of trucks which will re-arm a SET\_GROUP of artillery groups when they run out of ammunition. They will be based on a
-- homebase and drive from there to the artillery groups and then back home.
-- Trucks are the **only known in-game mechanic** to re-arm artillery and other units in DCS. Working units are e.g.: M-939 (blue), Ural-375 and ZIL-135 (both red).
--
-- ## 2 Set-up
--
-- Define a set of trucks and a set of artillery:
--
-- local truckset = SET_GROUP:New():FilterCoalitions("blue"):FilterActive(true):FilterCategoryGround():FilterPrefixes("Ammo Truck"):FilterStart()
-- local ariset = SET_GROUP:New():FilterCoalitions("blue"):FilterActive(true):FilterCategoryGround():FilterPrefixes("Artillery"):FilterStart()
--
-- Create an AMMOTRUCK object to take care of the artillery using the trucks, with a homezone:
--
-- local ammotruck = AMMOTRUCK:New(truckset,ariset,coalition.side.BLUE,"Logistics",ZONE:FindByName("HomeZone")
--
-- ## 2 Options and their default values
--
-- ammotruck.ammothreshold = 5 -- send a truck when down to this many rounds
-- ammotruck.remunidist = 20000 -- 20km - send trucks max this far from home
-- ammotruck.unloadtime = 600 -- 10 minutes - min time to unload ammunition
-- ammotruck.waitingtime = 1800 -- 30 mintes - wait max this long until remunition is done
-- ammotruck.monitor = -60 -- 1 minute - AMMOTRUCK checks run every one minute
-- ammotruck.routeonroad = true -- Trucks will **try** to drive on roads
-- ammotruck.usearmygroup = false -- If true, will make use of ARMYGROUP in the background (if used in DEV branch)
-- ammotruck.reloads = 5 -- Maxn re-arms a truck can do before he needs to go home and restock. Set to -1 for unlimited
--
-- ## 3 FSM Events to shape mission
--
-- Truck has been sent off:
--
-- function ammotruck:OnAfterRouteTruck(From, Event, To, Truckdata, Aridata)
-- ...
-- end
--
-- Truck has arrived:
--
-- function ammotruck:OnAfterTruckArrived(From, Event, To, Truckdata)
-- ...
-- end
--
-- Truck is unloading:
--
-- function ammotruck:OnAfterTruckUnloading(From, Event, To, Truckdata)
-- ...
-- end
--
-- Truck is returning home:
--
-- function ammotruck:OnAfterTruckReturning(From, Event, To, Truckdata)
-- ...
-- end
--
-- Truck is arrived at home:
--
-- function ammotruck:OnAfterTruckHome(From, Event, To, Truckdata)
-- ...
-- end
--
-- @field #AMMOTRUCK
AMMOTRUCK = {
ClassName = "AMMOTRUCK",
lid = "",
version = "0.0.12",
alias = "",
debug = false,
trucklist = {},
targetlist = {},
coalition = nil,
truckset = nil,
targetset = nil,
remunitionqueue = {},
waitingtargets = {},
ammothreshold = 5,
remunidist = 20000,
monitor = -60,
unloadtime = 600,
waitingtime = 1800,
routeonroad = true,
reloads = 5,
}
---
-- @type AMMOTRUCK.State
AMMOTRUCK.State = {
IDLE = "idle",
DRIVING = "driving",
ARRIVED = "arrived",
UNLOADING = "unloading",
RETURNING = "returning",
WAITING = "waiting",
RELOADING = "reloading",
OUTOFAMMO = "outofammo",
REQUESTED = "requested",
}
---
--@type AMMOTRUCK.data
--@field Wrapper.Group#GROUP group
--@field #string name
--@field #AMMOTRUCK.State statusquo
--@field #number timestamp
--@field #number ammo
--@field Core.Point#COORDINATE coordinate
--@field #string targetname
--@field Wrapper.Group#GROUP targetgroup
--@field Core.Point#COORDINATE targetcoordinate
--@field #number reloads
---
-- @param #AMMOTRUCK self
-- @param Core.Set#SET_GROUP Truckset Set of truck groups
-- @param Core.Set#SET_GROUP Targetset Set of artillery groups
-- @param #number Coalition Coalition
-- @param #string Alias Alias Name
-- @param Core.Zone#ZONE Homezone Home, return zone for trucks
-- @return #AMMOTRUCK self
-- @usage
-- Define a set of trucks and a set of artillery:
-- local truckset = SET_GROUP:New():FilterCoalitions("blue"):FilterActive(true):FilterCategoryGround():FilterPrefixes("Ammo Truck"):FilterStart()
-- local ariset = SET_GROUP:New():FilterCoalitions("blue"):FilterActive(true):FilterCategoryGround():FilterPrefixes("Artillery"):FilterStart()
--
-- Create an AMMOTRUCK object to take care of the artillery using the trucks, with a homezone:
-- local ammotruck = AMMOTRUCK:New(truckset,ariset,coalition.side.BLUE,"Logistics",ZONE:FindByName("HomeZone")
function AMMOTRUCK:New(Truckset,Targetset,Coalition,Alias,Homezone)
-- Inherit everything from BASE class.
local self=BASE:Inherit(self, FSM:New()) -- #AMMOTRUCK
self.truckset = Truckset -- Core.Set#SET_GROUP
self.targetset = Targetset -- Core.Set#SET_GROUP
self.coalition = Coalition -- #number
self.alias = Alias -- #string
self.debug = false
self.remunitionqueue = {}
self.trucklist = {}
self.targetlist = {}
self.ammothreshold = 5
self.remunidist = 20000
self.homezone = Homezone -- Core.Zone#ZONE
self.waitingtime = 1800
self.usearmygroup = false
self.hasarmygroup = false
-- Log id.
self.lid=string.format("AMMOTRUCK %s | %s | ", self.version, self.alias)
self:SetStartState("Stopped")
self:AddTransition("Stopped", "Start", "Running")
self:AddTransition("*", "Monitor", "*")
self:AddTransition("*", "RouteTruck", "*")
self:AddTransition("*", "TruckArrived", "*")
self:AddTransition("*", "TruckUnloading", "*")
self:AddTransition("*", "TruckReturning", "*")
self:AddTransition("*", "TruckHome", "*")
self:AddTransition("*", "Stop", "Stopped")
self:__Start(math.random(5,10))
self:I(self.lid .. "Started")
------------------------
--- Pseudo Functions ---
------------------------
--- Triggers the FSM event "Stop". Stops the AMMOTRUCK and all its event handlers.
-- @function [parent=#AMMOTRUCK] Stop
-- @param #AMMOTRUCK self
--- Triggers the FSM event "Stop" after a delay. Stops the AMMOTRUCK and all its event handlers.
-- @function [parent=#AMMOTRUCK] __Stop
-- @param #AMMOTRUCK self
-- @param #number delay Delay in seconds.
--- On after "RouteTruck" event.
-- @function [parent=#AMMOTRUCK] OnAfterRouteTruck
-- @param #AMMOTRUCK self
-- @param #string From From state.
-- @param #string Event Event.
-- @param #string To To state.
-- @param #AMMOTRUCK.data Truck
-- @param #AMMOTRUCK.data Artillery
--- On after "TruckUnloading" event.
-- @function [parent=#AMMOTRUCK] OnAfterTruckUnloading
-- @param #AMMOTRUCK self
-- @param #string From From state.
-- @param #string Event Event.
-- @param #string To To state.
-- @param #AMMOTRUCK.data Truck
--- On after "TruckReturning" event.
-- @function [parent=#AMMOTRUCK] OnAfterTruckReturning
-- @param #AMMOTRUCK self
-- @param #string From From state.
-- @param #string Event Event.
-- @param #string To To state.
-- @param #AMMOTRUCK.data Truck
--- On after "RouteTruck" event.
-- @function [parent=#AMMOTRUCK] OnAfterRouteTruck
-- @param #AMMOTRUCK self
-- @param #string From From state.
-- @param #string Event Event.
-- @param #string To To state.
-- @param #AMMOTRUCK.data Truck
--- On after "TruckHome" event.
-- @function [parent=#AMMOTRUCK] OnAfterTruckHome
-- @param #AMMOTRUCK self
-- @param #string From From state.
-- @param #string Event Event.
-- @param #string To To state.
-- @param #AMMOTRUCK.data Truck
return self
end
---
-- @param #AMMOTRUCK self
-- @param #table dataset table of #AMMOTRUCK.data entries
-- @return #AMMOTRUCK self
function AMMOTRUCK:CheckDrivingTrucks(dataset)
self:T(self.lid .. " CheckDrivingTrucks")
local data = dataset
for _,_data in pairs (data) do
local truck = _data -- #AMMOTRUCK.data
-- see if we arrived at destination
local coord = truck.group:GetCoordinate()
local tgtcoord = truck.targetcoordinate
local dist = coord:Get2DDistance(tgtcoord)
if dist <= 150 then
-- arrived
truck.statusquo = AMMOTRUCK.State.ARRIVED
truck.timestamp = timer.getAbsTime()
truck.coordinate = coord
self:__TruckArrived(1,truck)
end
-- still driving?
local Tnow = timer.getAbsTime()
if Tnow - truck.timestamp > 30 then
local group = truck.group
if self.usearmygroup then
group = truck.group:GetGroup()
end
local currspeed = group:GetVelocityKMH()
if truck.lastspeed then
if truck.lastspeed == 0 and currspeed == 0 then
self:T(truck.group:GetName().." Is not moving!")
-- try and move it
truck.timestamp = timer.getAbsTime()
if self.routeonroad then
group:RouteGroundOnRoad(truck.targetcoordinate,30,2,"Vee")
else
group:RouteGroundTo(truck.targetcoordinate,30,"Vee",2)
end
end
truck.lastspeed = currspeed
else
truck.lastspeed = currspeed
truck.timestamp = timer.getAbsTime()
end
self:I({truck=truck.group:GetName(),currspeed=currspeed,lastspeed=truck.lastspeed})
end
end
return self
end
---
-- @param #AMMOTRUCK self
-- @param Wrapper.Group#GROUP Group
-- @return #AMMOTRUCK self
function AMMOTRUCK:GetAmmoStatus(Group)
local ammotot, shells, rockets, bombs, missiles, narti = Group:GetAmmunition()
return rockets+missiles+narti
end
---
-- @param #AMMOTRUCK self
-- @param #table dataset table of #AMMOTRUCK.data entries
-- @return #AMMOTRUCK self
function AMMOTRUCK:CheckWaitingTargets(dataset)
self:T(self.lid .. " CheckWaitingTargets")
local data = dataset
for _,_data in pairs (data) do
local truck = _data -- #AMMOTRUCK.data
-- see how long we're waiting - maybe ammo truck is dead?
local Tnow = timer.getAbsTime()
local Tdiff = Tnow - truck.timestamp
if Tdiff > self.waitingtime then
local hasammo = self:GetAmmoStatus(truck.group)
if hasammo <= self.ammothreshold then
truck.statusquo = AMMOTRUCK.State.OUTOFAMMO
else
truck.statusquo = AMMOTRUCK.State.IDLE
end
end
end
return self
end
---
-- @param #AMMOTRUCK self
-- @param #table dataset table of #AMMOTRUCK.data entries
-- @return #AMMOTRUCK self
function AMMOTRUCK:CheckReturningTrucks(dataset)
self:T(self.lid .. " CheckReturningTrucks")
local data = dataset
local tgtcoord = self.homezone:GetCoordinate()
local radius = self.homezone:GetRadius()
for _,_data in pairs (data) do
local truck = _data -- #AMMOTRUCK.data
-- see if we arrived at destination
local coord = truck.group:GetCoordinate()
local dist = coord:Get2DDistance(tgtcoord)
self:T({name=truck.name,radius=radius,distance=dist})
if dist <= radius then
-- arrived
truck.statusquo = AMMOTRUCK.State.IDLE
truck.timestamp = timer.getAbsTime()
truck.coordinate = coord
truck.reloads = self.reloads or 5
self:__TruckHome(1,truck)
end
end
return self
end
---
-- @param #AMMOTRUCK self
-- @param #string name Artillery group name to find
-- @return #AMMOTRUCK.data Data
function AMMOTRUCK:FindTarget(name)
self:T(self.lid .. " FindTarget")
local data = nil
local dataset = self.targetlist
for _,_entry in pairs(dataset) do
local entry = _entry -- #AMMOTRUCK.data
if entry.name == name then
data = entry
break
end
end
return data
end
---
-- @param #AMMOTRUCK self
-- @param #string name Truck group name to find
-- @return #AMMOTRUCK.data Data
function AMMOTRUCK:FindTruck(name)
self:T(self.lid .. " FindTruck")
local data = nil
local dataset = self.trucklist
for _,_entry in pairs(dataset) do
local entry = _entry -- #AMMOTRUCK.data
if entry.name == name then
data = entry
break
end
end
return data
end
---
-- @param #AMMOTRUCK self
-- @param #table dataset table of #AMMOTRUCK.data entries
-- @return #AMMOTRUCK self
function AMMOTRUCK:CheckArrivedTrucks(dataset)
self:T(self.lid .. " CheckArrivedTrucks")
local data = dataset
for _,_data in pairs (data) do
-- set to unloading
local truck = _data -- #AMMOTRUCK.data
truck.statusquo = AMMOTRUCK.State.UNLOADING
truck.timestamp = timer.getAbsTime()
self:__TruckUnloading(2,truck)
-- set target to reloading
local aridata = self:FindTarget(truck.targetname) -- #AMMOTRUCK.data
if aridata then
aridata.statusquo = AMMOTRUCK.State.RELOADING
aridata.timestamp = timer.getAbsTime()
end
end
return self
end
---
-- @param #AMMOTRUCK self
-- @param #table dataset table of #AMMOTRUCK.data entries
-- @return #AMMOTRUCK self
function AMMOTRUCK:CheckUnloadingTrucks(dataset)
self:T(self.lid .. " CheckUnloadingTrucks")
local data = dataset
for _,_data in pairs (data) do
-- check timestamp
local truck = _data -- #AMMOTRUCK.data
local Tnow = timer.getAbsTime()
local Tpassed = Tnow - truck.timestamp
local hasammo = self:GetAmmoStatus(truck.targetgroup)
if Tpassed > self.unloadtime and hasammo > self.ammothreshold then
truck.statusquo = AMMOTRUCK.State.RETURNING
truck.timestamp = timer.getAbsTime()
self:__TruckReturning(2,truck)
-- set target to reloaded
local aridata = self:FindTarget(truck.targetname) -- #AMMOTRUCK.data
if aridata then
aridata.statusquo = AMMOTRUCK.State.IDLE
aridata.timestamp = timer.getAbsTime()
end
end
end
return self
end
---
-- @param #AMMOTRUCK self
-- @return #AMMOTRUCK self
function AMMOTRUCK:CheckTargetsAlive()
self:T(self.lid .. " CheckTargetsAlive")
local arilist = self.targetlist
for _,_ari in pairs(arilist) do
local ari = _ari -- #AMMOTRUCK.data
if ari.group and ari.group:IsAlive() then
-- everything fine
else
-- ari dead
self.targetlist[ari.name] = nil
end
end
-- new arrivals?
local aritable = self.targetset:GetSetObjects() --#table
for _,_ari in pairs(aritable) do
local ari = _ari -- Wrapper.Group#GROUP
if ari and ari:IsAlive() and not self.targetlist[ari:GetName()] then
local name = ari:GetName()
local newari = {} -- #AMMOTRUCK.data
newari.name = name
newari.group = ari
newari.statusquo = AMMOTRUCK.State.IDLE
newari.timestamp = timer.getAbsTime()
newari.coordinate = ari:GetCoordinate()
local hasammo = self:GetAmmoStatus(ari)
--newari.ammo = ari:GetAmmunition()
newari.ammo = hasammo
self.targetlist[name] = newari
end
end
return self
end
---
-- @param #AMMOTRUCK self
-- @return #AMMOTRUCK self
function AMMOTRUCK:CheckTrucksAlive()
self:T(self.lid .. " CheckTrucksAlive")
local trucklist = self.trucklist
for _,_truck in pairs(trucklist) do
local truck = _truck -- #AMMOTRUCK.data
if truck.group and truck.group:IsAlive() then
-- everything fine
else
-- truck dead
local tgtname = truck.targetname
local targetdata = self:FindTarget(tgtname) -- #AMMOTRUCK.data
if targetdata then
if targetdata.statusquo ~= AMMOTRUCK.State.IDLE then
targetdata.statusquo = AMMOTRUCK.State.IDLE
end
end
self.trucklist[truck.name] = nil
end
end
-- new arrivals?
local trucktable = self.truckset:GetSetObjects() --#table
for _,_truck in pairs(trucktable) do
local truck = _truck -- Wrapper.Group#GROUP
if truck and truck:IsAlive() and not self.trucklist[truck:GetName()] then
local name = truck:GetName()
local newtruck = {} -- #AMMOTRUCK.data
newtruck.name = name
newtruck.group = truck
if self.hasarmygroup then
-- is (not) already ARMYGROUP?
if truck.ClassName and truck.ClassName == "GROUP" then
local trucker = ARMYGROUP:New(truck)
trucker:Activate()
newtruck.group = trucker
end
end
newtruck.statusquo = AMMOTRUCK.State.IDLE
newtruck.timestamp = timer.getAbsTime()
newtruck.coordinate = truck:GetCoordinate()
newtruck.reloads = self.reloads or 5
self.trucklist[name] = newtruck
end
end
return self
end
---
-- @param #AMMOTRUCK self
-- @param #string From
-- @param #string Event
-- @param #string To
-- @return #AMMOTRUCK self
function AMMOTRUCK:onafterStart(From, Event, To)
self:T({From, Event, To})
if ARMYGROUP and self.usearmygroup then
self.hasarmygroup = true
else
self.hasarmygroup = false
end
if self.debug then
BASE:TraceOn()
BASE:TraceClass("AMMOTRUCK")
end
self:CheckTargetsAlive()
self:CheckTrucksAlive()
self:__Monitor(-30)
return self
end
---
-- @param #AMMOTRUCK self
-- @param #string From
-- @param #string Event
-- @param #string To
-- @return #AMMOTRUCK self
function AMMOTRUCK:onafterMonitor(From, Event, To)
self:T({From, Event, To})
self:CheckTargetsAlive()
self:CheckTrucksAlive()
-- update ammo state
local remunition = false
local remunitionqueue = {}
local waitingtargets = {}
for _,_ari in pairs(self.targetlist) do
local data = _ari -- #AMMOTRUCK.data
if data.group and data.group:IsAlive() then
data.ammo = self:GetAmmoStatus(data.group)
data.timestamp = timer.getAbsTime()
local text = string.format("Ari %s | Ammo %d | State %s",data.name,data.ammo,data.statusquo)
self:T(text)
if data.ammo <= self.ammothreshold and (data.statusquo == AMMOTRUCK.State.IDLE or data.statusquo == AMMOTRUCK.State.OUTOFAMMO) then
-- add to remu queue
data.statusquo = AMMOTRUCK.State.OUTOFAMMO
remunitionqueue[#remunitionqueue+1] = data
remunition = true
elseif data.statusquo == AMMOTRUCK.State.WAITING then
waitingtargets[#waitingtargets+1] = data
end
else
self.targetlist[data.name] = nil
end
end
-- sort trucks in buckets
local idletrucks = {}
local drivingtrucks = {}
local unloadingtrucks = {}
local arrivedtrucks = {}
local returningtrucks = {}
local found = false
for _,_truckdata in pairs(self.trucklist) do
local data = _truckdata -- #AMMOTRUCK.data
if data.group and data.group:IsAlive() then
-- check state
local text = string.format("Truck %s | State %s",data.name,data.statusquo)
self:T(text)
if data.statusquo == AMMOTRUCK.State.IDLE then
idletrucks[#idletrucks+1] = data
found = true
elseif data.statusquo == AMMOTRUCK.State.DRIVING then
drivingtrucks[#drivingtrucks+1] = data
elseif data.statusquo == AMMOTRUCK.State.ARRIVED then
arrivedtrucks[#arrivedtrucks+1] = data
elseif data.statusquo == AMMOTRUCK.State.UNLOADING then
unloadingtrucks[#unloadingtrucks+1] = data
elseif data.statusquo == AMMOTRUCK.State.RETURNING then
returningtrucks[#returningtrucks+1] = data
if data.reloads > 0 or data.reloads == -1 then
idletrucks[#idletrucks+1] = data
found = true
end
end
else
self.truckset[data.name] = nil
end
end
-- see if we can/need route one
local n=0
if found and remunition then
-- match
--local match = false
for _,_truckdata in pairs(idletrucks) do
local truckdata = _truckdata -- #AMMOTRUCK.data
local truckcoord = truckdata.group:GetCoordinate() -- Core.Point#COORDINATE
for _,_aridata in pairs(remunitionqueue) do
local aridata = _aridata -- #AMMOTRUCK.data
local aricoord = aridata.coordinate
local distance = truckcoord:Get2DDistance(aricoord)
if distance <= self.remunidist and aridata.statusquo == AMMOTRUCK.State.OUTOFAMMO and n <= #idletrucks then
n = n + 1
aridata.statusquo = AMMOTRUCK.State.REQUESTED
self:__RouteTruck(n*5,truckdata,aridata)
break
end
end
end
end
-- check driving trucks
if #drivingtrucks > 0 then
self:CheckDrivingTrucks(drivingtrucks)
end
-- check arrived trucks
if #arrivedtrucks > 0 then
self:CheckArrivedTrucks(arrivedtrucks)
end
-- check unloading trucks
if #unloadingtrucks > 0 then
self:CheckUnloadingTrucks(unloadingtrucks)
end
-- check returningtrucks trucks
if #returningtrucks > 0 then
self:CheckReturningTrucks(returningtrucks)
end
-- check waiting targets
if #waitingtargets > 0 then
self:CheckWaitingTargets(waitingtargets)
end
self:__Monitor(self.monitor)
return self
end
---
-- @param #AMMOTRUCK self
-- @param #string From
-- @param #string Event
-- @param #string To
-- @param #AMMOTRUCK.data Truckdata
-- @param #AMMOTRUCK.data Aridata
-- @return #AMMOTRUCK self
function AMMOTRUCK:onafterRouteTruck(From, Event, To, Truckdata, Aridata)
self:T({From, Event, To, Truckdata.name, Aridata.name})
local truckdata = Truckdata -- #AMMOTRUCK.data
local aridata = Aridata -- #AMMOTRUCK.data
local tgtgrp = aridata.group
local tgtzone = ZONE_GROUP:New(aridata.name,tgtgrp,30)
local tgtcoord = tgtzone:GetRandomCoordinate(15)
if self.hasarmygroup then
local mission = AUFTRAG:NewONGUARD(tgtcoord)
local oldmission = truckdata.group:GetMissionCurrent()
if oldmission then oldmission:Cancel() end
mission:SetTime(5)
mission:SetTeleport(false)
truckdata.group:AddMission(mission)
elseif self.routeonroad then
truckdata.group:RouteGroundOnRoad(tgtcoord,30)
else
truckdata.group:RouteGroundTo(tgtcoord,30)
end
truckdata.statusquo = AMMOTRUCK.State.DRIVING
truckdata.targetgroup = tgtgrp
truckdata.targetname = aridata.name
truckdata.targetcoordinate = tgtcoord
aridata.statusquo = AMMOTRUCK.State.WAITING
aridata.timestamp = timer.getAbsTime()
return self
end
---
-- @param #AMMOTRUCK self
-- @param #string From
-- @param #string Event
-- @param #string To
-- @param #AMMOTRUCK.data Truckdata
-- @return #AMMOTRUCK self
function AMMOTRUCK:onafterTruckUnloading(From, Event, To, Truckdata)
local m = MESSAGE:New("Truck "..Truckdata.name.." unloading!",15,"AmmoTruck"):ToCoalitionIf(self.coalition,self.debug)
local truck = Truckdata -- Functional.AmmoTruck#AMMOTRUCK.data
local coord = truck.group:GetCoordinate()
local heading = truck.group:GetHeading()
heading = heading < 180 and (360-heading) or (heading - 180)
local cid = self.coalition == coalition.side.BLUE and country.id.USA or country.id.RUSSIA
cid = self.coalition == coalition.side.NEUTRAL and country.id.UN_PEACEKEEPERS or cid
local ammo = {}
for i=1,5 do
ammo[i] = SPAWNSTATIC:NewFromType("ammo_cargo","Cargos",cid)
:InitCoordinate(coord:Translate((15+((i-1)*4)),heading))
:Spawn(0,"AmmoCrate-"..math.random(1,10000))
end
local function destroyammo(ammo)
for _,_crate in pairs(ammo) do
_crate:Destroy(false)
end
end
local scheduler = SCHEDULER:New(nil,destroyammo,{ammo},self.waitingtime)
-- one reload less
if truck.reloads ~= -1 then
truck.reloads = truck.reloads - 1
end
return self
end
---
-- @param #AMMOTRUCK self
-- @param #string From
-- @param #string Event
-- @param #string To
-- @param #AMMOTRUCK.data Truck
-- @return #AMMOTRUCK self
function AMMOTRUCK:onafterTruckReturning(From, Event, To, Truck)
self:T({From, Event, To, Truck.name})
-- route home
local truckdata = Truck -- #AMMOTRUCK.data
local tgtzone = self.homezone
local tgtcoord = tgtzone:GetRandomCoordinate()
if self.hasarmygroup then
local mission = AUFTRAG:NewONGUARD(tgtcoord)
local oldmission = truckdata.group:GetMissionCurrent()
if oldmission then oldmission:Cancel() end
mission:SetTime(5)
mission:SetTeleport(false)
truckdata.group:AddMission(mission)
elseif self.routeonroad then
truckdata.group:RouteGroundOnRoad(tgtcoord,30,1,"Cone")
else
truckdata.group:RouteGroundTo(tgtcoord,30,"Cone",1)
end
return self
end
---
-- @param #AMMOTRUCK self
-- @param #string From
-- @param #string Event
-- @param #string To
-- @return #AMMOTRUCK self
function AMMOTRUCK:onafterStop(From, Event, To)
self:T({From, Event, To})
return self
end

View File

@@ -25,9 +25,9 @@
--
-- ===
--
-- ### Author: **[funkyfranky](https://forums.eagle.ru/member.php?u=115026)**
-- ### Author: **funkyfranky**
--
-- ### Contributions: [FlightControl](https://forums.eagle.ru/member.php?u=89536)
-- ### Contributions: FlightControl
--
-- ====
-- @module Functional.Artillery
@@ -291,14 +291,14 @@
-- ### Illumination Shells
--
-- ARTY groups that possess shells can fire shells with illumination bombs. First, the group needs to be equipped with this weapon. This is done by the
-- function @{ARTY.SetIlluminationShells}(*n*, *power*), where *n* is the number of shells the group has available and *power* the illumination power in mega candela (mcd).
-- function @{#ARTY.SetIlluminationShells}(*n*, *power*), where *n* is the number of shells the group has available and *power* the illumination power in mega candela (mcd).
--
-- In order to execute an engagement with illumination shells one has to use the weapon type *ARTY.WeaponType.IlluminationShells* in the
-- @{#ARTY.AssignTargetCoord}() function.
--
-- In the simulation, the explosive shell that is fired is destroyed once it gets close to the target point but before it can actually impact.
-- At this position an illumination bomb is triggered at a random altitude between 500 and 1000 meters. This interval can be set by the function
-- @{ARTY.SetIlluminationMinMaxAlt}(*minalt*, *maxalt*).
-- @{#ARTY.SetIlluminationMinMaxAlt}(*minalt*, *maxalt*).
--
-- ### Smoke Shells
--
@@ -3546,9 +3546,7 @@ end
-- @param #string To To state.
function ARTY:onafterRespawn(Controllable, From, Event, To)
self:_EventFromTo("onafterRespawn", Event, From, To)
env.info("FF Respawning arty group")
self:I("Respawning arty group")
local group=self.Controllable --Wrapper.Group#GROUP
-- Respawn group.

File diff suppressed because it is too large Load Diff

View File

@@ -14,7 +14,7 @@
--
-- ## Missions:
--
-- [CLA - CleanUp Airbase](https://github.com/FlightControl-Master/MOOSE_MISSIONS/tree/master/CLA%20-%20CleanUp%20Airbase)
-- [CLA - CleanUp Airbase](https://github.com/FlightControl-Master/MOOSE_MISSIONS/tree/master/Functional/CleanUp)
--
-- ===
--

View File

@@ -15,10 +15,12 @@
--
-- ===
--
-- ## Missions:
--
-- [DES - Designation](https://github.com/FlightControl-Master/MOOSE_MISSIONS/tree/master/DES%20-%20Designation)
--
-- ## Additional Material:
--
-- * **Demo Missions:** [GitHub](https://github.com/FlightControl-Master/MOOSE_MISSIONS/tree/master/Functional/Designate)
-- * **YouTube videos:** None
-- * **Guides:** None
--
-- ===
--
-- Targets detected by recce will be communicated to a group of attacking players.
@@ -167,9 +169,9 @@
--
-- ### Contributions:
--
-- * [**Ciribob**](https://forums.eagle.ru/member.php?u=112175): Showing the way how to lase targets + how laser codes work!!! Explained the autolase script.
-- * [**EasyEB**](https://forums.eagle.ru/member.php?u=112055): Ideas and Beta Testing
-- * [**Wingthor**](https://forums.eagle.ru/member.php?u=123698): Beta Testing
-- * **Ciribob**: Showing the way how to lase targets + how laser codes work!!! Explained the autolase script.
-- * **EasyEB**: Ideas and Beta Testing
-- * **Wingthor**: Beta Testing
--
-- ### Authors:
--

View File

@@ -15,7 +15,7 @@
--
-- ## Missions:
--
-- [DET - Detection](https://github.com/FlightControl-Master/MOOSE_MISSIONS/tree/master/DET%20-%20Detection)
-- [DET - Detection](https://github.com/FlightControl-Master/MOOSE_MISSIONS/tree/develop/Functional/Detection)
--
-- ===
--
@@ -38,8 +38,9 @@
-- @image Detection.JPG
do -- DETECTION_BASE
--- @type DETECTION_BASE
---
-- @type DETECTION_BASE
-- @field Core.Set#SET_GROUP DetectionSetGroup The @{Core.Set} of GROUPs in the Forward Air Controller role.
-- @field DCS#Distance DetectionRange The range till which targets are accepted to be detected.
-- @field #DETECTION_BASE.DetectedObjects DetectedObjects The list of detected objects.
@@ -91,6 +92,11 @@ do -- DETECTION_BASE
--
-- DetectionObject:FilterCategories( { Unit.Category.AIRPLANE, Unit.Category.HELICOPTER } )
--
--
-- ## Radar Blur - use to make the radar less exact, e.g. for WWII scenarios
--
-- * @{#DETECTION_BASE.SetRadarBlur}(): Set the radar blur to be used.
--
-- ## **DETECTION_ derived classes** group the detected units into a **DetectedItems[]** list
--
-- DETECTION_BASE derived classes build a list called DetectedItems[], which is essentially a first later
@@ -268,11 +274,13 @@ do -- DETECTION_BASE
DetectedItems = {},
DetectedItemsByIndex = {},
}
--- @type DETECTION_BASE.DetectedObjects
---
-- @type DETECTION_BASE.DetectedObjects
-- @list <#DETECTION_BASE.DetectedObject>
--- @type DETECTION_BASE.DetectedObject
---
-- @type DETECTION_BASE.DetectedObject
-- @field #string Name
-- @field #boolean IsVisible
-- @field #boolean KnowType
@@ -283,8 +291,9 @@ do -- DETECTION_BASE
-- @field #number LastTime
-- @field #boolean LastPos
-- @field #number LastVelocity
--- @type DETECTION_BASE.DetectedItems
---
-- @type DETECTION_BASE.DetectedItems
-- @list <#DETECTION_BASE.DetectedItem>
--- Detected item data structure.
@@ -522,7 +531,7 @@ do -- DETECTION_BASE
do -- State Transition Handling
--- @param #DETECTION_BASE self
-- @param #DETECTION_BASE self
-- @param #string From The From State string.
-- @param #string Event The Event string.
-- @param #string To The To State string.
@@ -530,7 +539,7 @@ do -- DETECTION_BASE
self:__Detect( 1 )
end
--- @param #DETECTION_BASE self
-- @param #DETECTION_BASE self
-- @param #string From The From State string.
-- @param #string Event The Event string.
-- @param #string To The To State string.
@@ -570,7 +579,7 @@ do -- DETECTION_BASE
end
--- @param #DETECTION_BASE self
-- @param #DETECTION_BASE self
-- @param #number The amount of alive recce.
function DETECTION_BASE:CountAliveRecce()
@@ -578,7 +587,7 @@ do -- DETECTION_BASE
end
--- @param #DETECTION_BASE self
-- @param #DETECTION_BASE self
function DETECTION_BASE:ForEachAliveRecce( IteratorFunction, ... )
self:F2( arg )
@@ -587,7 +596,7 @@ do -- DETECTION_BASE
return self
end
--- @param #DETECTION_BASE self
-- @param #DETECTION_BASE self
-- @param #string From The From State string.
-- @param #string Event The Event string.
-- @param #string To The To State string.
@@ -712,6 +721,31 @@ do -- DETECTION_BASE
end
end
-- Calculate radar blur probability
if self.RadarBlur then
MESSAGE:New("Radar Blur",10):ToLogIf(self.debug):ToAllIf(self.verbose)
local minheight = self.RadarBlurMinHeight or 250 -- meters
local thresheight = self.RadarBlurThresHeight or 90 -- 10% chance to find a low flying group
local thresblur = self.RadarBlurThresBlur or 85 -- 25% chance to escape the radar overall
local dist = math.floor(Distance)
if dist <= self.RadarBlurClosing then
thresheight = (((dist*dist)/self.RadarBlurClosingSquare)*thresheight)
thresblur = (((dist*dist)/self.RadarBlurClosingSquare)*thresblur)
end
local fheight = math.floor(math.random(1,10000)/100)
local fblur = math.floor(math.random(1,10000)/100)
local unit = UNIT:FindByName(DetectedObjectName)
if unit and unit:IsAlive() then
local AGL = unit:GetAltitude(true)
MESSAGE:New("Unit "..DetectedObjectName.." is at "..math.floor(AGL).."m. Distance "..math.floor(Distance).."km.",10):ToLogIf(self.debug):ToAllIf(self.verbose)
MESSAGE:New(string.format("fheight = %d/%d | fblur = %d/%d",fheight,thresheight,fblur,thresblur),10):ToLogIf(self.debug):ToAllIf(self.verbose)
if fblur > thresblur then DetectionAccepted = false end
if AGL <= minheight and fheight < thresheight then DetectionAccepted = false end
MESSAGE:New("Detection Accepted = "..tostring(DetectionAccepted),10):ToLogIf(self.debug):ToAllIf(self.verbose)
end
end
-- Calculate additional probabilities
if not self.DetectedObjects[DetectedObjectName] and TargetIsVisible and self.DistanceProbability then
@@ -1011,7 +1045,24 @@ do -- DETECTION_BASE
return self
end
--- Method to make the radar detection less accurate, e.g. for WWII scenarios.
-- @param #DETECTION_BASE self
-- @param #number minheight Minimum flight height to be detected, in meters AGL (above ground)
-- @param #number thresheight Threshold to escape the radar if flying below minheight, defaults to 90 (90% escape chance)
-- @param #number thresblur Threshold to be detected by the radar overall, defaults to 85 (85% chance to be found)
-- @param #number closing Closing-in in km - the limit of km from which on it becomes increasingly difficult to escape radar detection if flying towards the radar position. Should be about 1/3 of the radar detection radius in kilometers, defaults to 20.
-- @return #DETECTION_BASE self
function DETECTION_BASE:SetRadarBlur(minheight,thresheight,thresblur,closing)
self.RadarBlur = true
self.RadarBlurMinHeight = minheight or 250 -- meters
self.RadarBlurThresHeight = thresheight or 90 -- 10% chance to find a low flying group
self.RadarBlurThresBlur = thresblur or 85 -- 25% chance to escape the radar overall
self.RadarBlurClosing = closing or 20 -- 20km
self.RadarBlurClosingSquare = self.RadarBlurClosing * self.RadarBlurClosing
return self
end
end
do
@@ -1354,7 +1405,7 @@ do -- DETECTION_BASE
}
}
--- @param DCS#Unit FoundDCSUnit
-- @param DCS#Unit FoundDCSUnit
-- @param Wrapper.Group#GROUP ReportGroup
-- @param Core.Set#SET_GROUP ReportSetGroup
local FindNearByFriendlies = function( FoundDCSUnit, ReportGroupData )
@@ -1419,7 +1470,7 @@ do -- DETECTION_BASE
DetectedItem.PlayersNearBy = nil
_DATABASE:ForEachPlayer(
--- @param Wrapper.Unit#UNIT PlayerUnit
-- @param Wrapper.Unit#UNIT PlayerUnit
function( PlayerUnitName )
local PlayerUnit = UNIT:FindByName( PlayerUnitName )
@@ -1975,8 +2026,9 @@ do -- DETECTION_BASE
end
do -- DETECTION_UNITS
--- @type DETECTION_UNITS
---
-- @type DETECTION_UNITS
-- @field DCS#Distance DetectionRange The range till which targets are detected.
-- @extends Functional.Detection#DETECTION_BASE
@@ -2231,8 +2283,9 @@ do -- DETECTION_UNITS
end
do -- DETECTION_TYPES
--- @type DETECTION_TYPES
---
-- @type DETECTION_TYPES
-- @extends Functional.Detection#DETECTION_BASE
--- Will detect units within the battle zone.
@@ -2354,6 +2407,7 @@ do -- DETECTION_TYPES
if not DetectedItem then
DetectedItem = self:AddDetectedItem( "TYPE", DetectedTypeName )
DetectedItem.TypeName = DetectedTypeName
DetectedItem.Name = DetectedUnitName -- fix by @Nocke
end
DetectedItem.Set:AddUnit( DetectedUnit )
@@ -2433,8 +2487,9 @@ do -- DETECTION_TYPES
end
do -- DETECTION_AREAS
--- @type DETECTION_AREAS
---
-- @type DETECTION_AREAS
-- @field DCS#Distance DetectionZoneRange The range till which targets are grouped upon the first detected target.
-- @field #DETECTION_BASE.DetectedItems DetectedItems A list of areas containing the set of @{Wrapper.Unit}s, @{Core.Zone}s, the center @{Wrapper.Unit} within the zone, and ID of each area that was detected within a DetectionZoneRange.
-- @extends Functional.Detection#DETECTION_BASE
@@ -2451,7 +2506,7 @@ do -- DETECTION_AREAS
--
-- Retrieve the DetectedItems[].Set with the method @{Functional.Detection#DETECTION_BASE.GetDetectedSet}(). A @{Core.Set#SET_UNIT} object will be returned.
--
-- Retrieve the formed @{Zone@ZONE_UNIT}s as a result of the grouping the detected units within the DetectionZoneRange, use the method @{Functional.Detection#DETECTION_AREAS.GetDetectionZones}().
-- Retrieve the formed @{Core.Zone@ZONE_UNIT}s as a result of the grouping the detected units within the DetectionZoneRange, use the method @{Functional.Detection#DETECTION_AREAS.GetDetectionZones}().
-- To understand the amount of zones created, use the method @{Functional.Detection#DETECTION_AREAS.GetDetectionZoneCount}().
-- If you want to obtain a specific zone from the DetectedZones, use the method @{Functional.Detection#DETECTION_AREAS.GetDetectionZoneByID}() with a given index.
--
@@ -2960,7 +3015,7 @@ do -- DETECTION_AREAS
-- DetectedSet:Flush( self )
DetectedSet:ForEachUnit( --- @param Wrapper.Unit#UNIT DetectedUnit
DetectedSet:ForEachUnit( -- @param Wrapper.Unit#UNIT DetectedUnit
function( DetectedUnit )
if DetectedUnit:IsAlive() then
-- self:T( "Detected Set #" .. DetectedItem.ID .. ":" .. DetectedUnit:GetName() )

View File

@@ -21,7 +21,7 @@ do -- DETECTION_ZONES
--
-- Retrieve the DetectedItems[].Set with the method @{Functional.Detection#DETECTION_BASE.GetDetectedSet}(). A @{Core.Set#SET_UNIT} object will be returned.
--
-- Retrieve the formed @{Zone@ZONE_UNIT}s as a result of the grouping the detected units within the DetectionZoneRange, use the method @{Functional.Detection#DETECTION_BASE.GetDetectionZones}().
-- Retrieve the formed @{Core.Zone#ZONE_UNIT}s as a result of the grouping the detected units within the DetectionZoneRange, use the method @{Functional.Detection#DETECTION_BASE.GetDetectionZones}().
-- To understand the amount of zones created, use the method @{Functional.Detection#DETECTION_BASE.GetDetectionZoneCount}().
-- If you want to obtain a specific zone from the DetectedZones, use the method @{Functional.Detection#DETECTION_BASE.GetDetectionZone}() with a given index.
--

View File

@@ -16,11 +16,13 @@
-- * Escort tactical situation reporting.
--
-- ===
--
-- ## Missions:
--
-- [ESC - Escorting](https://github.com/FlightControl-Master/MOOSE_MISSIONS/tree/master/ESC%20-%20Escorting)
--
--
-- ## Additional Material:
--
-- * **Demo Missions:** [GitHub](https://github.com/FlightControl-Master/MOOSE_MISSIONS/tree/master/Functional/Escort)
-- * **YouTube videos:** None
-- * **Guides:** None
--
-- ===
--
-- Allows you to interact with escorting AI on your flight and take the lead.
@@ -108,8 +110,8 @@
-- @image Escorting.JPG
--- @type ESCORT
---
-- @type ESCORT
-- @extends Core.Base#BASE
-- @field Wrapper.Client#CLIENT EscortClient
-- @field Wrapper.Group#GROUP EscortGroup
@@ -252,7 +254,7 @@ end
--- Set a Detection method for the EscortClient to be reported upon.
-- Detection methods are based on the derived classes from DETECTION_BASE.
-- @param #ESCORT self
-- @param Function.Detection#DETECTION_BASE Detection
-- @param Functional.Detection#DETECTION_BASE Detection
function ESCORT:SetDetection( Detection )
self.Detection = Detection
@@ -600,7 +602,7 @@ function ESCORT:MenuReportTargets( Seconds )
self.EscortMenuAttackNearbyTargets = MENU_GROUP:New( self.EscortClient:GetGroup(), "Attack targets", self.EscortMenu )
self.ReportTargetsScheduler = SCHEDULER:New( self, self._ReportTargetsScheduler, {}, 1, Seconds )
self.ReportTargetsScheduler, self.ReportTargetsSchedulerID = SCHEDULER:New( self, self._ReportTargetsScheduler, {}, 1, Seconds )
return self
end
@@ -693,7 +695,7 @@ function ESCORT:MenuResumeMission()
end
--- @param #MENUPARAM MenuParam
-- @param #MENUPARAM MenuParam
function ESCORT:_HoldPosition( OrbitGroup, OrbitHeight, OrbitSeconds )
local EscortGroup = self.EscortGroup
@@ -733,7 +735,7 @@ function ESCORT:_HoldPosition( OrbitGroup, OrbitHeight, OrbitSeconds )
end
--- @param #MENUPARAM MenuParam
-- @param #MENUPARAM MenuParam
function ESCORT:_JoinUpAndFollow( Distance )
local EscortGroup = self.EscortGroup
@@ -766,7 +768,7 @@ function ESCORT:JoinUpAndFollow( EscortGroup, EscortClient, Distance )
EscortGroup:MessageToClient( "Rejoining and Following at " .. Distance .. "!", 30, EscortClient )
end
--- @param #MENUPARAM MenuParam
-- @param #MENUPARAM MenuParam
function ESCORT:_Flare( Color, Message )
local EscortGroup = self.EscortGroup
@@ -776,7 +778,7 @@ function ESCORT:_Flare( Color, Message )
EscortGroup:MessageToClient( Message, 10, EscortClient )
end
--- @param #MENUPARAM MenuParam
-- @param #MENUPARAM MenuParam
function ESCORT:_Smoke( Color, Message )
local EscortGroup = self.EscortGroup
@@ -787,7 +789,7 @@ function ESCORT:_Smoke( Color, Message )
end
--- @param #MENUPARAM MenuParam
-- @param #MENUPARAM MenuParam
function ESCORT:_ReportNearbyTargetsNow()
local EscortGroup = self.EscortGroup
@@ -809,12 +811,12 @@ function ESCORT:_SwitchReportNearbyTargets( ReportTargets )
self.ReportTargetsScheduler:Schedule( self, self._ReportTargetsScheduler, {}, 1, 30 )
end
else
routines.removeFunction( self.ReportTargetsScheduler )
self.ReportTargetsScheduler:Remove(self.ReportTargetsSchedulerID)
self.ReportTargetsScheduler = nil
end
end
--- @param #MENUPARAM MenuParam
-- @param #MENUPARAM MenuParam
function ESCORT:_ScanTargets( ScanDuration )
local EscortGroup = self.EscortGroup -- Wrapper.Group#GROUP
@@ -844,7 +846,7 @@ function ESCORT:_ScanTargets( ScanDuration )
end
--- @param Wrapper.Group#GROUP EscortGroup
-- @param Wrapper.Group#GROUP EscortGroup
function _Resume( EscortGroup )
env.info( '_Resume' )
@@ -856,7 +858,7 @@ function _Resume( EscortGroup )
end
--- @param #ESCORT self
-- @param #ESCORT self
-- @param Functional.Detection#DETECTION_BASE.DetectedItem DetectedItem
function ESCORT:_AttackTarget( DetectedItem )
@@ -877,7 +879,7 @@ function ESCORT:_AttackTarget( DetectedItem )
local Tasks = {}
DetectedSet:ForEachUnit(
--- @param Wrapper.Unit#UNIT DetectedUnit
-- @param Wrapper.Unit#UNIT DetectedUnit
function( DetectedUnit, Tasks )
if DetectedUnit:IsAlive() then
Tasks[#Tasks+1] = EscortGroup:TaskAttackUnit( DetectedUnit )
@@ -900,7 +902,7 @@ function ESCORT:_AttackTarget( DetectedItem )
local Tasks = {}
DetectedSet:ForEachUnit(
--- @param Wrapper.Unit#UNIT DetectedUnit
-- @param Wrapper.Unit#UNIT DetectedUnit
function( DetectedUnit, Tasks )
if DetectedUnit:IsAlive() then
Tasks[#Tasks+1] = EscortGroup:TaskFireAtPoint( DetectedUnit:GetVec2(), 50 )
@@ -921,7 +923,7 @@ function ESCORT:_AttackTarget( DetectedItem )
end
---
--- @param #ESCORT self
-- @param #ESCORT self
-- @param Functional.Detection#DETECTION_BASE.DetectedItem DetectedItem
function ESCORT:_AssistTarget( EscortGroupAttack, DetectedItem )
@@ -939,7 +941,7 @@ function ESCORT:_AssistTarget( EscortGroupAttack, DetectedItem )
local Tasks = {}
DetectedSet:ForEachUnit(
--- @param Wrapper.Unit#UNIT DetectedUnit
-- @param Wrapper.Unit#UNIT DetectedUnit
function( DetectedUnit, Tasks )
if DetectedUnit:IsAlive() then
Tasks[#Tasks+1] = EscortGroupAttack:TaskAttackUnit( DetectedUnit )
@@ -961,7 +963,7 @@ function ESCORT:_AssistTarget( EscortGroupAttack, DetectedItem )
local Tasks = {}
DetectedSet:ForEachUnit(
--- @param Wrapper.Unit#UNIT DetectedUnit
-- @param Wrapper.Unit#UNIT DetectedUnit
function( DetectedUnit, Tasks )
if DetectedUnit:IsAlive() then
Tasks[#Tasks+1] = EscortGroupAttack:TaskFireAtPoint( DetectedUnit:GetVec2(), 50 )
@@ -981,7 +983,7 @@ function ESCORT:_AssistTarget( EscortGroupAttack, DetectedItem )
end
--- @param #MENUPARAM MenuParam
-- @param #MENUPARAM MenuParam
function ESCORT:_ROE( EscortROEFunction, EscortROEMessage )
local EscortGroup = self.EscortGroup
@@ -991,7 +993,7 @@ function ESCORT:_ROE( EscortROEFunction, EscortROEMessage )
EscortGroup:MessageToClient( EscortROEMessage, 10, EscortClient )
end
--- @param #MENUPARAM MenuParam
-- @param #MENUPARAM MenuParam
function ESCORT:_ROT( EscortROTFunction, EscortROTMessage )
local EscortGroup = self.EscortGroup
@@ -1001,7 +1003,7 @@ function ESCORT:_ROT( EscortROTFunction, EscortROTMessage )
EscortGroup:MessageToClient( EscortROTMessage, 10, EscortClient )
end
--- @param #MENUPARAM MenuParam
-- @param #MENUPARAM MenuParam
function ESCORT:_ResumeMission( WayPoint )
local EscortGroup = self.EscortGroup
@@ -1036,7 +1038,7 @@ function ESCORT:RegisterRoute()
return TaskPoints
end
--- @param Functional.Escort#ESCORT self
-- @param Functional.Escort#ESCORT self
function ESCORT:_FollowScheduler()
self:F( { self.FollowDistance } )

File diff suppressed because it is too large Load Diff

View File

@@ -13,7 +13,7 @@
--
-- ## Missions:
--
-- ### [MANTIS - Modular, Automatic and Network capable Targeting and Interception System](https://github.com/FlightControl-Master/MOOSE_MISSIONS/tree/master/MTS%20-%20Mantis/MTS-010%20-%20Basic%20Mantis%20Demo)
-- ### [MANTIS - Modular, Automatic and Network capable Targeting and Interception System](https://github.com/FlightControl-Master/MOOSE_MISSIONS/tree/master/Functional/Mantis)
--
-- ===
--
@@ -22,7 +22,7 @@
-- @module Functional.Mantis
-- @image Functional.Mantis.jpg
--
-- Last Update: Oct 2022
-- Last Update: Feb 2024
-------------------------------------------------------------------------
--- **MANTIS** class, extends Core.Base#BASE
@@ -94,7 +94,7 @@
-- Known SAM types at the time of writing are:
--
-- * Avenger
-- * Chaparrel
-- * Chaparral
-- * Hawk
-- * Linebacker
-- * NASAMS
@@ -103,10 +103,15 @@
-- * Roland
-- * Silkworm (though strictly speaking this is a surface to ship missile)
-- * SA-2, SA-3, SA-5, SA-6, SA-7, SA-8, SA-9, SA-10, SA-11, SA-13, SA-15, SA-19
-- * From IDF mod: STUNNER IDFA, TAMIR IDFA (Note all caps!)
-- * From HDS (see note on HDS below): SA-2, SA-3, SA-10B, SA-10C, SA-12, SA-17, SA-20A, SA-20B, SA-23, HQ-2
--
-- * From SMA: RBS98M, RBS70, RBS90, RBS90M, RBS103A, RBS103B, RBS103AM, RBS103BM, Lvkv9040M
-- **NOTE** If you are using the Swedish Military Assets (SMA), please note that the **group name** for RBS-SAM types also needs to contain the keyword "SMA"
--
-- * From CH: 2S38, PantsirS1, PantsirS2, PGL-625, HQ-17A, M903PAC2, M903PAC3, TorM2, TorM2K, TorM2M, NASAMS3-AMRAAMER, NASAMS3-AIM9X2, C-RAM, PGZ-09, S350-9M100, S350-9M96D
-- **NOTE** If you are using the Military Assets by Currenthill (CH), please note that the **group name** for CH-SAM types also needs to contain the keyword "CHM"
--
-- Following the example started above, an SA-6 site group name should start with "Red SAM SA-6" then, or a blue Patriot installation with e.g. "Blue SAM Patriot".
-- **NOTE** If you are using the High-Digit-Sam Mod, please note that the **group name** for the following SAM types also needs to contain the keyword "HDS":
--
@@ -342,17 +347,17 @@ MANTIS.SamType = {
-- @field #string Type #MANTIS.SamType of SAM, i.e. SHORT, MEDIUM or LONG (range)
-- @field #string Radar Radar typename on unit level (used as key)
MANTIS.SamData = {
["Hawk"] = { Range=44, Blindspot=0, Height=9, Type="Medium", Radar="Hawk" }, -- measures in km
["NASAMS"] = { Range=14, Blindspot=0, Height=3, Type="Short", Radar="NSAMS" },
["Patriot"] = { Range=99, Blindspot=0, Height=9, Type="Long", Radar="Patriot" },
["Rapier"] = { Range=6, Blindspot=0, Height=3, Type="Short", Radar="rapier" },
["Hawk"] = { Range=35, Blindspot=0, Height=12, Type="Medium", Radar="Hawk" }, -- measures in km
["NASAMS"] = { Range=14, Blindspot=0, Height=7, Type="Short", Radar="NSAMS" }, -- AIM 120B
["Patriot"] = { Range=99, Blindspot=0, Height=25, Type="Long", Radar="Patriot" },
["Rapier"] = { Range=10, Blindspot=0, Height=3, Type="Short", Radar="rapier" },
["SA-2"] = { Range=40, Blindspot=7, Height=25, Type="Medium", Radar="S_75M_Volhov" },
["SA-3"] = { Range=18, Blindspot=6, Height=18, Type="Short", Radar="5p73 s-125 ln" },
["SA-5"] = { Range=250, Blindspot=7, Height=40, Type="Long", Radar="5N62V" },
["SA-6"] = { Range=25, Blindspot=0, Height=8, Type="Medium", Radar="1S91" },
["SA-10"] = { Range=119, Blindspot=0, Height=18, Type="Long" , Radar="S-300PS 4"},
["SA-11"] = { Range=35, Blindspot=0, Height=20, Type="Medium", Radar="SA-11" },
["Roland"] = { Range=8, Blindspot=0, Height=3, Type="Short", Radar="Roland" },
["Roland"] = { Range=5, Blindspot=0, Height=5, Type="Short", Radar="Roland" },
["HQ-7"] = { Range=12, Blindspot=0, Height=3, Type="Short", Radar="HQ-7" },
["SA-9"] = { Range=4, Blindspot=0, Height=3, Type="Short", Radar="Strela" },
["SA-8"] = { Range=10, Blindspot=0, Height=5, Type="Short", Radar="Osa 9A33" },
@@ -360,7 +365,7 @@ MANTIS.SamData = {
["SA-15"] = { Range=11, Blindspot=0, Height=6, Type="Short", Radar="Tor 9A331" },
["SA-13"] = { Range=5, Blindspot=0, Height=3, Type="Short", Radar="Strela" },
["Avenger"] = { Range=4, Blindspot=0, Height=3, Type="Short", Radar="Avenger" },
["Chaparrel"] = { Range=8, Blindspot=0, Height=3, Type="Short", Radar="Chaparral" },
["Chaparral"] = { Range=8, Blindspot=0, Height=3, Type="Short", Radar="Chaparral" },
["Linebacker"] = { Range=4, Blindspot=0, Height=3, Type="Short", Radar="Linebacker" },
["Silkworm"] = { Range=90, Blindspot=1, Height=0.2, Type="Long", Radar="Silkworm" },
-- units from HDS Mod, multi launcher options is tricky
@@ -369,6 +374,9 @@ MANTIS.SamData = {
["SA-20A"] = { Range=150, Blindspot=5, Height=27, Type="Long" , Radar="S-300PMU1"},
["SA-20B"] = { Range=200, Blindspot=4, Height=27, Type="Long" , Radar="S-300PMU2"},
["HQ-2"] = { Range=50, Blindspot=6, Height=35, Type="Medium", Radar="HQ_2_Guideline_LN" },
["SHORAD"] = { Range=3, Blindspot=0, Height=3, Type="Short", Radar="Igla" },
["TAMIR IDFA"] = { Range=20, Blindspot=0.6, Height=12.3, Type="Short", Radar="IRON_DOME_LN" },
["STUNNER IDFA"] = { Range=250, Blindspot=1, Height=45, Type="Long", Radar="DAVID_SLING_LN" },
}
--- SAM data HDS
@@ -415,6 +423,37 @@ MANTIS.SamDataSMA = {
["Lvkv9040M SMA"] = { Range=4, Blindspot=0, Height=2.5, Type="Short", Radar="LvKv9040" },
}
--- SAM data CH
-- @type MANTIS.SamDataCH
-- @field #number Range Max firing range in km
-- @field #number Blindspot no-firing range (green circle)
-- @field #number Height Max firing height in km
-- @field #string Type #MANTIS.SamType of SAM, i.e. SHORT, MEDIUM or LONG (range)
-- @field #string Radar Radar typename on unit level (used as key)
MANTIS.SamDataCH = {
-- units from CH (Military Assets by Currenthill)
-- https://www.currenthill.com/
-- group name MUST contain CHM to ID launcher type correctly!
["2S38 CH"] = { Range=8, Blindspot=0.5, Height=6, Type="Short", Radar="2S38" },
["PantsirS1 CH"] = { Range=20, Blindspot=1.2, Height=15, Type="Short", Radar="PantsirS1" },
["PantsirS2 CH"] = { Range=30, Blindspot=1.2, Height=18, Type="Medium", Radar="PantsirS2" },
["PGL-625 CH"] = { Range=10, Blindspot=0.5, Height=5, Type="Short", Radar="PGL_625" },
["HQ-17A CH"] = { Range=20, Blindspot=1.5, Height=10, Type="Short", Radar="HQ17A" },
["M903PAC2 CH"] = { Range=160, Blindspot=3, Height=24.5, Type="Long", Radar="MIM104_M903_PAC2" },
["M903PAC3 CH"] = { Range=120, Blindspot=1, Height=40, Type="Long", Radar="MIM104_M903_PAC3" },
["TorM2 CH"] = { Range=12, Blindspot=1, Height=10, Type="Short", Radar="TorM2" },
["TorM2K CH"] = { Range=12, Blindspot=1, Height=10, Type="Short", Radar="TorM2K" },
["TorM2M CH"] = { Range=16, Blindspot=1, Height=10, Type="Short", Radar="TorM2M" },
["NASAMS3-AMRAAMER CH"] = { Range=50, Blindspot=2, Height=35.7, Type="Medium", Radar="CH_NASAMS3_LN_AMRAAM_ER" },
["NASAMS3-AIM9X2 CH"] = { Range=20, Blindspot=0.2, Height=18, Type="Short", Radar="CH_NASAMS3_LN_AIM9X2" },
["C-RAM CH"] = { Range=2, Blindspot=0, Height=2, Type="Short", Radar="CH_Centurion_C_RAM" },
["PGZ-09 CH"] = { Range=4, Blindspot=0, Height=3, Type="Short", Radar="CH_PGZ09" },
["S350-9M100 CH"] = { Range=15, Blindspot=1.5, Height=8, Type="Short", Radar="CH_S350_50P6_9M100" },
["S350-9M96D CH"] = { Range=150, Blindspot=2.5, Height=30, Type="Long", Radar="CH_S350_50P6_9M96D" },
["LAV-AD CH"] = { Range=8, Blindspot=0.2, Height=4.8, Type="Short", Radar="CH_LAVAD" },
["HQ-22 CH"] = { Range=170, Blindspot=5, Height=27, Type="Long", Radar="CH_HQ22_LN" },
}
-----------------------------------------------------------------------
-- MANTIS System
-----------------------------------------------------------------------
@@ -431,6 +470,7 @@ do
--@param #string awacs Group name of your Awacs (optional)
--@param #boolean EmOnOff Make MANTIS switch Emissions on and off instead of changing the alarm state between RED and GREEN (optional)
--@param #number Padding For #SEAD - Extra number of seconds to add to radar switch-back-on time (optional)
--@param #table Zones Table of Core.Zone#ZONE Zones Consider SAM groups in this zone(s) only for this MANTIS instance, must be handed as #table of Zone objects
--@return #MANTIS self
--@usage Start up your MANTIS with a basic setting
--
@@ -449,8 +489,12 @@ do
-- mybluemantis = MANTIS:New("bluemantis","Blue SAM","Blue EWR",nil,"blue",false,"Blue Awacs")
-- mybluemantis:Start()
--
function MANTIS:New(name,samprefix,ewrprefix,hq,coalition,dynamic,awacs, EmOnOff, Padding)
function MANTIS:New(name,samprefix,ewrprefix,hq,coalition,dynamic,awacs, EmOnOff, Padding, Zones)
-- Inherit everything from BASE class.
local self = BASE:Inherit(self, FSM:New()) -- #MANTIS
-- DONE: Create some user functions for these
-- DONE: Make HQ useful
-- DONE: Set SAMs to auto if EWR dies
@@ -510,6 +554,11 @@ do
self.maxclassic = 6
self.autoshorad = true
self.ShoradGroupSet = SET_GROUP:New() -- Core.Set#SET_GROUP
self.FilterZones = Zones
self.SkateZones = nil
self.SkateNumber = 3
self.shootandscoot = false
self.UseEmOnOff = true
if EmOnOff == false then
@@ -522,9 +571,6 @@ do
self.advAwacs = false
end
-- Inherit everything from BASE class.
local self = BASE:Inherit(self, FSM:New()) -- #MANTIS
-- Set the string id for output to DCS.log file.
self.lid=string.format("MANTIS %s | ", self.name)
@@ -559,16 +605,23 @@ do
self:T({self.ewr_templates})
self.SAM_Group = SET_GROUP:New():FilterPrefixes(self.SAM_Templates_Prefix):FilterCoalitions(self.Coalition)
self.EWR_Group = SET_GROUP:New():FilterPrefixes(self.ewr_templates):FilterCoalitions(self.Coalition)
if self.FilterZones then
self.SAM_Group:FilterZones(self.FilterZones)
end
if self.dynamic then
-- Set SAM SET_GROUP
self.SAM_Group = SET_GROUP:New():FilterPrefixes(self.SAM_Templates_Prefix):FilterCoalitions(self.Coalition):FilterStart()
self.SAM_Group:FilterStart()
-- Set EWR SET_GROUP
self.EWR_Group = SET_GROUP:New():FilterPrefixes(self.ewr_templates):FilterCoalitions(self.Coalition):FilterStart()
self.EWR_Group:FilterStart()
else
-- Set SAM SET_GROUP
self.SAM_Group = SET_GROUP:New():FilterPrefixes(self.SAM_Templates_Prefix):FilterCoalitions(self.Coalition):FilterOnce()
self.SAM_Group:FilterOnce()
-- Set EWR SET_GROUP
self.EWR_Group = SET_GROUP:New():FilterPrefixes(self.ewr_templates):FilterCoalitions(self.Coalition):FilterOnce()
self.EWR_Group:FilterOnce()
end
-- set up CC
@@ -578,7 +631,7 @@ do
-- TODO Version
-- @field #string version
self.version="0.8.9"
self.version="0.8.16"
self:I(string.format("***** Starting MANTIS Version %s *****", self.version))
--- FSM Functions ---
@@ -742,6 +795,23 @@ do
return self
end
--- Add a SET_ZONE of zones for Shoot&Scoot - SHORAD units will move around
-- @param #MANTIS self
-- @param Core.Set#SET_ZONE ZoneSet Set of zones to be used. Units will move around to the next (random) zone between 100m and 3000m away.
-- @param #number Number Number of closest zones to be considered, defaults to 3.
-- @param #boolean Random If true, use a random coordinate inside the next zone to scoot to.
-- @param #string Formation Formation to use, defaults to "Cone". See mission editor dropdown for options.
-- @return #MANTIS self
function MANTIS:AddScootZones(ZoneSet, Number, Random, Formation)
self:T(self.lid .. " AddScootZones")
self.SkateZones = ZoneSet
self.SkateNumber = Number or 3
self.shootandscoot = true
self.ScootRandom = Random
self.ScootFormation = Formation or "Cone"
return self
end
--- Function to set accept and reject zones.
-- @param #MANTIS self
-- @param #table AcceptZones Table of @{Core.Zone#ZONE} objects
@@ -848,7 +918,7 @@ do
--- Function to get the HQ object for further use
-- @param #MANTIS self
-- @return Wrapper.GROUP#GROUP The HQ #GROUP object or *nil* if it doesn't exist
-- @return Wrapper.Group#GROUP The HQ #GROUP object or *nil* if it doesn't exist
function MANTIS:GetCommandCenter()
self:T(self.lid .. "GetCommandCenter")
if self.HQ_CC then
@@ -884,7 +954,7 @@ do
--- Function to set the HQ object for further use
-- @param #MANTIS self
-- @param Wrapper.GROUP#GROUP group The #GROUP object to be set as HQ
-- @param Wrapper.Group#GROUP group The #GROUP object to be set as HQ
function MANTIS:SetCommandCenter(group)
self:T(self.lid .. "SetCommandCenter")
local group = group or nil
@@ -946,7 +1016,7 @@ do
--- Set using your own #INTEL_DLINK object instead of #DETECTION
-- @param #MANTIS self
-- @param Ops.Intelligence#INTEL_DLINK DLink The data link object to be used.
-- @param Ops.Intel#INTEL_DLINK DLink The data link object to be used.
function MANTIS:SetUsingDLink(DLink)
self:T(self.lid .. "SetUsingDLink")
self.DLink = true
@@ -1079,7 +1149,7 @@ do
--self:T(self.lid.." Relocating HQ")
local text = self.lid.." Relocating HQ"
--local m= MESSAGE:New(text,10,"MANTIS"):ToAll()
_hqgrp:RelocateGroundRandomInRadius(20,500,true,true)
_hqgrp:RelocateGroundRandomInRadius(20,500,true,true,nil,true)
end
--relocate EWR
-- TODO: maybe dependent on AlarmState? Observed: SA11 SR only relocates if no objects in reach
@@ -1093,7 +1163,7 @@ do
local text = self.lid.." Relocating EWR ".._grp:GetName()
local m= MESSAGE:New(text,10,"MANTIS"):ToAllIf(self.debug)
if self.verbose then self:I(text) end
_grp:RelocateGroundRandomInRadius(20,500,true,true)
_grp:RelocateGroundRandomInRadius(20,500,true,true,nil,true)
end
end
end
@@ -1152,10 +1222,10 @@ do
function MANTIS:_PreFilterHeight(height)
self:T(self.lid.."_PreFilterHeight")
local set = {}
local dlink = self.Detection -- Ops.Intelligence#INTEL_DLINK
local dlink = self.Detection -- Ops.Intel#INTEL_DLINK
local detectedgroups = dlink:GetContactTable()
for _,_contact in pairs(detectedgroups) do
local contact = _contact -- Ops.Intelligence#INTEL.Contact
local contact = _contact -- Ops.Intel#INTEL.Contact
local grp = contact.group -- Wrapper.Group#GROUP
if grp:IsAlive() then
if grp:GetHeight(true) < height then
@@ -1299,11 +1369,12 @@ do
-- @param #string grpname Name of the group
-- @param #boolean mod HDS mod flag
-- @param #boolean sma SMA mod flag
-- @param #boolean chm CH mod flag
-- @return #number range Max firing range
-- @return #number height Max firing height
-- @return #string type Long, medium or short range
-- @return #number blind "blind" spot
function MANTIS:_GetSAMDataFromUnits(grpname,mod,sma)
function MANTIS:_GetSAMDataFromUnits(grpname,mod,sma,chm)
self:T(self.lid.."_GetSAMRangeFromUnits")
local found = false
local range = self.checkradius
@@ -1318,8 +1389,10 @@ do
SAMData = self.SamDataHDS
elseif sma then
SAMData = self.SamDataSMA
elseif chm then
SAMData = self.SamDataCH
end
--self:I("Looking to auto-match for "..grpname)
--self:T("Looking to auto-match for "..grpname)
for _,_unit in pairs(units) do
local unit = _unit -- Wrapper.Unit#UNIT
local type = string.lower(unit:GetTypeName())
@@ -1364,10 +1437,13 @@ do
local found = false
local HDSmod = false
local SMAMod = false
local CHMod = false
if string.find(grpname,"HDS",1,true) then
HDSmod = true
elseif string.find(grpname,"SMA",1,true) then
SMAMod = true
elseif string.find(grpname,"CHM",1,true) then
CHMod = true
end
if self.automode then
for idx,entry in pairs(self.SamData) do
@@ -1386,8 +1462,8 @@ do
end
end
-- secondary filter if not found
if (not found and self.automode) or HDSmod or SMAMod then
range, height, type = self:_GetSAMDataFromUnits(grpname,HDSmod,SMAMod)
if (not found and self.automode) or HDSmod or SMAMod or CHMod then
range, height, type = self:_GetSAMDataFromUnits(grpname,HDSmod,SMAMod,CHMod)
elseif not found then
self:E(self.lid .. string.format("*****Could not match radar data for %s! Will default to midrange values!",grpname))
end
@@ -1701,7 +1777,7 @@ do
-- @return #MANTIS self
function MANTIS:_CheckDLinkState()
self:T(self.lid .. "_CheckDLinkState")
local dlink = self.Detection -- Ops.Intelligence#INTEL_DLINK
local dlink = self.Detection -- Ops.Intel#INTEL_DLINK
local TS = timer.getAbsTime()
if not dlink:Is("Running") and (TS - self.DLTimeStamp > 29) then
self.DLink = false
@@ -1735,6 +1811,10 @@ do
self.Shorad:SetDefenseLimits(80,95)
self.ShoradLink = true
self.Shorad.Groupset=self.ShoradGroupSet
self.Shorad.debug = self.debug
end
if self.shootandscoot and self.SkateZones and self.Shorad then
self.Shorad:AddScootZones(self.SkateZones,self.SkateNumber or 3,self.ScootRandom,self.ScootFormation)
end
self:__Status(-math.random(1,10))
return self

View File

@@ -14,7 +14,7 @@
--
-- ## Missions:
--
-- [MIT - Missile Trainer](https://github.com/FlightControl-Master/MOOSE_MISSIONS/tree/master/MIT%20-%20Missile%20Trainer)
-- [MIT - Missile Trainer](https://github.com/FlightControl-Master/MOOSE_MISSIONS/tree/master/Functional/MissileTrainer)
--
-- ===
--
@@ -50,6 +50,11 @@
-- * **100 meter**: Destroys the missile when the distance to the aircraft is below or equal to 100 meter.
-- * **150 meter**: Destroys the missile when the distance to the aircraft is below or equal to 150 meter.
-- * **200 meter**: Destroys the missile when the distance to the aircraft is below or equal to 200 meter.
--
-- # Developer Note
--
-- Note while this class still works, it is no longer supported as the original author stopped active development of MOOSE.
-- Therefore, this class is considered to be deprecated and superseded by the [Functional.Fox](https://flightcontrol-master.github.io/MOOSE_DOCS_DEVELOP/Documentation/Functional.Fox.html) class, which provides the same functionality.
--
-- ===
--
@@ -67,8 +72,8 @@
-- @module Functional.MissileTrainer
-- @image Missile_Trainer.JPG
--- @type MISSILETRAINER
---
-- @type MISSILETRAINER
-- @field Core.Set#SET_CLIENT DBClients
-- @extends Core.Base#BASE
@@ -97,6 +102,11 @@
-- * @{#MISSILETRAINER.InitRangeOnOff}: Sets by default the display of range information of missiles ON of OFF.
-- * @{#MISSILETRAINER.InitBearingOnOff}: Sets by default the display of bearing information of missiles ON of OFF.
-- * @{#MISSILETRAINER.InitMenusOnOff}: Allows to configure the options through the radio menu.
--
-- # Developer Note
--
-- Note while this class still works, it is no longer supported as the original author stopped active development of MOOSE.
-- Therefore, this class is considered to be deprecated and superseded by the [Functional.Fox](https://flightcontrol-master.github.io/MOOSE_DOCS_DEVELOP/Documentation/Functional.Fox.html) class, which provides the same functionality.
--
-- @field #MISSILETRAINER
MISSILETRAINER = {
@@ -205,7 +215,7 @@ function MISSILETRAINER:New( Distance, Briefing )
-- self.DB:ForEachClient(
-- --- @param Wrapper.Client#CLIENT Client
-- -- @param Wrapper.Client#CLIENT Client
-- function( Client )
--
-- ... actions ...
@@ -555,7 +565,7 @@ function MISSILETRAINER:_AddBearing( Client, TrainerWeapon )
local DirectionVector = { x = PositionMissile.x - TargetVec3.x, y = PositionMissile.y - TargetVec3.y, z = PositionMissile.z - TargetVec3.z }
local DirectionRadians = math.atan2( DirectionVector.z, DirectionVector.x )
--DirectionRadians = DirectionRadians + routines.getNorthCorrection( PositionTarget )
if DirectionRadians < 0 then
DirectionRadians = DirectionRadians + 2 * math.pi
end

View File

@@ -10,7 +10,8 @@
-- @module Functional.Movement
-- @image MOOSE.JPG
--- @type MOVEMENT
---
-- @type MOVEMENT
-- @extends Core.Base#BASE
---
@@ -55,7 +56,6 @@ end
--- Call this function to start the MOVEMENT scheduling.
function MOVEMENT:ScheduleStart()
self:F()
--self.MoveFunction = routines.scheduleFunction( self._Scheduler, { self }, timer.getTime() + 1, 120 )
self.MoveFunction = SCHEDULER:New( self, self._Scheduler, {}, 1, 120 )
end

File diff suppressed because it is too large Load Diff

View File

@@ -4,7 +4,7 @@
--
-- The RANGE class enables easy set up of bombing and strafing ranges within DCS World.
--
-- Implementation is based on the [Simple Range Script](https://forums.eagle.ru/showthread.php?t=157991) by [Ciribob](https://forums.eagle.ru/member.php?u=112175), which itself was motivated
-- Implementation is based on the [Simple Range Script](https://forums.eagle.ru/showthread.php?t=157991) by Ciribob, which itself was motivated
-- by a script by SNAFU [see here](https://forums.eagle.ru/showthread.php?t=109174).
--
-- [476th - Air Weapons Range Objects mod](http://www.476vfightergroup.com/downloads.php?do=file&id=287) is highly recommended for this class.
@@ -42,9 +42,9 @@
--
-- ===
--
-- ### Author: **[funkyfranky](https://forums.eagle.ru/member.php?u=115026)**
-- ### Author: **funkyfranky**
--
-- ### Contributions: [FlightControl](https://forums.eagle.ru/member.php?u=89536), [Ciribob](https://forums.eagle.ru/member.php?u=112175)
-- ### Contributions: FlightControl, Ciribob
-- ### SRS Additions: Applevangelist
--
-- ===
@@ -105,6 +105,7 @@
-- @field Sound.SRS#MSRSQUEUE controlsrsQ SRS queue for range controller.
-- @field Sound.SRS#MSRS instructmsrs SRS wrapper for range instructor.
-- @field Sound.SRS#MSRSQUEUE instructsrsQ SRS queue for range instructor.
-- @field #number Coalition Coalition side for the menu, if any.
-- @extends Core.Fsm#FSM
--- *Don't only practice your art, but force your way into its secrets; art deserves that, for it and knowledge can raise man to the Divine.* - Ludwig van Beethoven
@@ -355,7 +356,8 @@ RANGE = {
targetsheet = nil,
targetpath = nil,
targetprefix = nil,
}
Coalition = nil,
}
--- Default range parameters.
-- @type RANGE.Defaults
@@ -591,7 +593,7 @@ RANGE.MenuF10Root = nil
--- Range script version.
-- @field #string version
RANGE.version = "2.7.0"
RANGE.version = "2.7.3"
-- TODO list:
-- TODO: Verbosity level for messages.
@@ -613,8 +615,9 @@ RANGE.version = "2.7.0"
--- RANGE contructor. Creates a new RANGE object.
-- @param #RANGE self
-- @param #string RangeName Name of the range. Has to be unique. Will we used to create F10 menu items etc.
-- @param #number Coalition (optional) Coalition of the range, if any, e.g. coalition.side.BLUE.
-- @return #RANGE RANGE object.
function RANGE:New( RangeName )
function RANGE:New( RangeName, Coalition )
-- Inherit BASE.
local self = BASE:Inherit( self, FSM:New() ) -- #RANGE
@@ -622,7 +625,9 @@ function RANGE:New( RangeName )
-- Get range name.
-- TODO: make sure that the range name is not given twice. This would lead to problems in the F10 radio menu.
self.rangename = RangeName or "Practice Range"
self.Coalition = Coalition
-- Log id.
self.lid = string.format( "RANGE %s | ", self.rangename )
@@ -1202,25 +1207,29 @@ end
-- @return #RANGE self
function RANGE:SetSRS(PathToSRS, Port, Coalition, Frequency, Modulation, Volume, PathToGoogleKey)
if PathToSRS then
if PathToSRS or MSRS.path then
self.useSRS=true
self.controlmsrs=MSRS:New(PathToSRS, Frequency or 256, Modulation or radio.modulation.AM, Volume or 1.0)
self.controlmsrs:SetPort(Port)
self.controlmsrs=MSRS:New(PathToSRS or MSRS.path, Frequency or 256, Modulation or radio.modulation.AM)
self.controlmsrs:SetPort(Port or MSRS.port)
self.controlmsrs:SetCoalition(Coalition or coalition.side.BLUE)
self.controlmsrs:SetLabel("RANGEC")
self.controlmsrs:SetVolume(Volume or 1.0)
self.controlsrsQ = MSRSQUEUE:New("CONTROL")
self.instructmsrs=MSRS:New(PathToSRS, Frequency or 305, Modulation or radio.modulation.AM, Volume or 1.0)
self.instructmsrs:SetPort(Port)
self.instructmsrs=MSRS:New(PathToSRS or MSRS.path, Frequency or 305, Modulation or radio.modulation.AM)
self.instructmsrs:SetPort(Port or MSRS.port)
self.instructmsrs:SetCoalition(Coalition or coalition.side.BLUE)
self.instructmsrs:SetLabel("RANGEI")
self.instructmsrs:SetVolume(Volume or 1.0)
self.instructsrsQ = MSRSQUEUE:New("INSTRUCT")
if PathToGoogleKey then
self.controlmsrs:SetGoogle(PathToGoogleKey)
self.instructmsrs:SetGoogle(PathToGoogleKey)
self.controlmsrs:SetProviderOptionsGoogle(PathToGoogleKey,PathToGoogleKey)
self.controlmsrs:SetProvider(MSRS.Provider.GOOGLE)
self.instructmsrs:SetProviderOptionsGoogle(PathToGoogleKey,PathToGoogleKey)
self.instructmsrs:SetProvider(MSRS.Provider.GOOGLE)
end
else
@@ -1229,7 +1238,7 @@ function RANGE:SetSRS(PathToSRS, Port, Coalition, Frequency, Modulation, Volume,
return self
end
--- (SRS) Set range control frequency and voice.
--- (SRS) Set range control frequency and voice. Use `RANGE:SetSRS()` once first before using this function.
-- @param #RANGE self
-- @param #number frequency Frequency in MHz. Default 256 MHz.
-- @param #number modulation Modulation, defaults to radio.modulation.AM.
@@ -1239,6 +1248,10 @@ end
-- @param #string relayunitname Name of the unit used for transmission location.
-- @return #RANGE self
function RANGE:SetSRSRangeControl( frequency, modulation, voice, culture, gender, relayunitname )
if not self.instructmsrs then
self:E(self.lid.."Use myrange:SetSRS() once first before using myrange:SetSRSRangeControl!")
return self
end
self.rangecontrolfreq = frequency or 256
self.controlmsrs:SetFrequencies(self.rangecontrolfreq)
self.controlmsrs:SetModulations(modulation or radio.modulation.AM)
@@ -1254,7 +1267,7 @@ function RANGE:SetSRSRangeControl( frequency, modulation, voice, culture, gender
return self
end
--- (SRS) Set range instructor frequency and voice.
--- (SRS) Set range instructor frequency and voice. Use `RANGE:SetSRS()` once first before using this function.
-- @param #RANGE self
-- @param #number frequency Frequency in MHz. Default 305 MHz.
-- @param #number modulation Modulation, defaults to radio.modulation.AM.
@@ -1264,6 +1277,10 @@ end
-- @param #string relayunitname Name of the unit used for transmission location.
-- @return #RANGE self
function RANGE:SetSRSRangeInstructor( frequency, modulation, voice, culture, gender, relayunitname )
if not self.instructmsrs then
self:E(self.lid.."Use myrange:SetSRS() once first before using myrange:SetSRSRangeInstructor!")
return self
end
self.instructorfreq = frequency or 305
self.instructmsrs:SetFrequencies(self.instructorfreq)
self.instructmsrs:SetModulations(modulation or radio.modulation.AM)
@@ -1724,7 +1741,9 @@ end
-- @param Core.Event#EVENTDATA EventData
function RANGE:OnEventBirth( EventData )
self:F( { eventbirth = EventData } )
if not EventData.IniPlayerName then return end
local _unitName = EventData.IniUnitName
local _unit, _playername = self:_GetPlayerUnitAndName( _unitName )
@@ -1745,10 +1764,16 @@ function RANGE:OnEventBirth( EventData )
-- Reset current strafe status.
self.strafeStatus[_uid] = nil
-- Add Menu commands after a delay of 0.1 seconds.
self:ScheduleOnce( 0.1, self._AddF10Commands, self, _unitName )
if self.Coalition then
if EventData.IniCoalition == self.Coalition then
self:ScheduleOnce( 0.1, self._AddF10Commands, self, _unitName )
end
else
-- Add Menu commands after a delay of 0.1 seconds.
self:ScheduleOnce( 0.1, self._AddF10Commands, self, _unitName )
end
-- By default, some bomb impact points and do not flare each hit on target.
self.PlayerSettings[_playername] = {} -- #RANGE.PlayerData
self.PlayerSettings[_playername].smokebombimpact = self.defaultsmokebomb
@@ -2044,6 +2069,7 @@ function RANGE:OnEventShot( EventData )
-- Attack parameters.
local attackHdg=_unit:GetHeading()
local attackAlt=_unit:GetHeight()
attackAlt = UTILS.MetersToFeet(attackAlt)
local attackVel=_unit:GetVelocityKNOTS()
-- Tracking info and init of last bomb position.
@@ -2167,7 +2193,7 @@ function RANGE:onafterExitRange( From, Event, To, player )
local text = "You left the bombing range zone. "
local r=math.random(2)
local r=math.random(5)
if r==1 then
text=text.."Have a nice day!"

View File

@@ -19,7 +19,7 @@
--
-- ## Missions:
--
-- [SCO - Scoring](https://github.com/FlightControl-Master/MOOSE_MISSIONS/tree/master/SCO%20-%20Scoring)
-- [SCO - Scoring](https://github.com/FlightControl-Master/MOOSE_MISSIONS/tree/master/Functional/Scoring)
--
-- ===
--
@@ -27,7 +27,7 @@
-- and creates a CSV file logging the scoring events and results for use at team or squadron websites.
--
-- SCORING automatically calculates the threat level of the objects hit and destroyed by players,
-- which can be @{Wrapper.Unit}, @{Static) and @{Scenery} objects.
-- which can be @{Wrapper.Unit}, @{Wrapper.Static) and @{Scenery} objects.
--
-- Positive score points are granted when enemy or neutral targets are destroyed.
-- Negative score points or penalties are given when a friendly target is hit or destroyed.
@@ -78,10 +78,11 @@
-- ### Authors: **FlightControl**
--
-- ### Contributions:
--
--
-- * **Applevangelist**: Additional functionality, fixes.
-- * **Wingthor (TAW)**: Testing & Advice.
-- * **Dutch-Baron (TAW)**: Testing & Advice.
-- * **[Whisper](http://forums.eagle.ru/member.php?u=3829): Testing and Advice.
-- * **Whisper**: Testing and Advice.
--
-- ===
--
@@ -116,11 +117,13 @@
-- Special targets can be set that will give extra scores to the players when these are destroyed.
-- Use the methods @{#SCORING.AddUnitScore}() and @{#SCORING.RemoveUnitScore}() to specify a special additional score for a specific @{Wrapper.Unit}s.
-- Use the methods @{#SCORING.AddStaticScore}() and @{#SCORING.RemoveStaticScore}() to specify a special additional score for a specific @{Wrapper.Static}s.
-- Use the method @{#SCORING.SetGroupGroup}() to specify a special additional score for a specific @{Wrapper.Group}s.
-- Use the method @{#SCORING.AddScoreSetGroup}() to specify a special additional score for a specific @{Wrapper.Group}s gathered in a @{Core.Set#SET_GROUP}.
--
-- local Scoring = SCORING:New( "Scoring File" )
-- Scoring:AddUnitScore( UNIT:FindByName( "Unit #001" ), 200 )
-- Scoring:AddStaticScore( STATIC:FindByName( "Static #1" ), 100 )
-- local GroupSet = SET_GROUP:New():FilterPrefixes("RAT"):FilterStart()
-- Scoring:AddScoreSetGroup( GroupSet, 100)
--
-- The above grants an additional score of 200 points for Unit #001 and an additional 100 points of Static #1 if these are destroyed.
-- Note that later in the mission, one can remove these scores set, for example, when the a goal achievement time limit is over.
@@ -226,6 +229,7 @@ SCORING = {
ClassID = 0,
Players = {},
AutoSave = true,
version = "1.18.4"
}
local _SCORINGCoalition = {
@@ -244,13 +248,15 @@ local _SCORINGCategory = {
--- Creates a new SCORING object to administer the scoring achieved by players.
-- @param #SCORING self
-- @param #string GameName The name of the game. This name is also logged in the CSV score file.
-- @param #string SavePath (Optional) Path where to save the CSV file, defaults to your **<User>\\Saved Games\\DCS\\Logs** folder.
-- @param #boolean AutoSave (Optional) If passed as `false`, then swith autosave off.
-- @return #SCORING self
-- @usage
--
-- -- Define a new scoring object for the mission Gori Valley.
-- ScoringObject = SCORING:New( "Gori Valley" )
--
function SCORING:New( GameName )
function SCORING:New( GameName, SavePath, AutoSave )
-- Inherits from BASE
local self = BASE:Inherit( self, BASE:New() ) -- #SCORING
@@ -275,9 +281,15 @@ function SCORING:New( GameName )
self:SetMessagesZone( true )
-- Scales
self:SetScaleDestroyScore( 10 )
self:SetScaleDestroyPenalty( 30 )
-- Hitting a target multiple times before destoying it should not result in a higger score
-- Multiple hits is typically a results of bombs/missles missing their target but still inflict some spash damage
-- Making this configurable to anyone can enable this anyway if they want
self:SetScoreIncrementOnHit(0)
-- Default fratricide penalty level (maximum penalty that can be assigned to a player before he gets kicked).
self:SetFratricide( self.ScaleDestroyPenalty * 3 )
self.penaltyonfratricide = true
@@ -307,7 +319,8 @@ function SCORING:New( GameName )
end )
-- Create the CSV file.
self.AutoSave = true
self.AutoSavePath = SavePath
self.AutoSave = AutoSave or true
self:OpenCSV( GameName )
return self
@@ -421,6 +434,31 @@ function SCORING:AddScoreGroup( ScoreGroup, Score )
return self
end
--- Specify a special additional score for a @{Core.Set#SET_GROUP}.
-- @param #SCORING self
-- @param Core.Set#SET_GROUP Set The @{Core.Set#SET_GROUP} for which each @{Wrapper.Unit} in each Group a Score is given.
-- @param #number Score The Score value.
-- @return #SCORING
function SCORING:AddScoreSetGroup(Set, Score)
local set = Set:GetSetObjects()
for _,_group in pairs (set) do
if _group and _group:IsAlive() then
self:AddScoreGroup(_group,Score)
end
end
local function AddScore(group)
self:AddScoreGroup(group,Score)
end
function Set:OnAfterAdded(From,Event,To,ObjectName,Object)
AddScore(Object)
end
return self
end
--- Add a @{Core.Zone} to define additional scoring when any object is destroyed in that zone.
-- Note that if a @{Core.Zone} with the same name is already within the scoring added, the @{Core.Zone} (type) and Score will be replaced!
-- This allows for a dynamic destruction zone evolution within your mission.
@@ -466,6 +504,16 @@ function SCORING:SetMessagesHit( OnOff )
return self
end
--- Configure to increment score after a target has been hit.
-- @param #SCORING self
-- @param #number score amount of point to inclement score on each hit
-- @return #SCORING
function SCORING:SetScoreIncrementOnHit( score )
self.ScoreIncrementOnHit = score
return self
end
--- If to send messages after a target has been hit.
-- @param #SCORING self
-- @return #boolean
@@ -659,7 +707,7 @@ function SCORING:_AddPlayerFromUnit( UnitData )
self.Players[PlayerName].Penalty = self.Players[PlayerName].Penalty + self.CoalitionChangePenalty or 50
self.Players[PlayerName].PenaltyCoalition = self.Players[PlayerName].PenaltyCoalition + 1
MESSAGE:NewType( self.DisplayMessagePrefix .. "Player '" .. PlayerName .. "' changed coalition from " .. _SCORINGCoalition[self.Players[PlayerName].UnitCoalition] .. " to " .. _SCORINGCoalition[UnitCoalition] ..
"(changed " .. self.Players[PlayerName].PenaltyCoalition .. " times the coalition). ".. self.CoalitionChangePenalty .."Penalty points added.",
"(changed " .. self.Players[PlayerName].PenaltyCoalition .. " times the coalition). ".. self.CoalitionChangePenalty .." penalty points added.",
MESSAGE.Type.Information
):ToAll()
self:ScoreCSV( PlayerName, "", "COALITION_PENALTY", 1, -1*self.CoalitionChangePenalty, self.Players[PlayerName].UnitName, _SCORINGCoalition[self.Players[PlayerName].UnitCoalition], _SCORINGCategory[self.Players[PlayerName].UnitCategory], self.Players[PlayerName].UnitType,
@@ -715,11 +763,11 @@ function SCORING:AddGoalScorePlayer( PlayerName, GoalTag, Text, Score )
PlayerData.Goals[GoalTag] = PlayerData.Goals[GoalTag] or { Score = 0 }
PlayerData.Goals[GoalTag].Score = PlayerData.Goals[GoalTag].Score + Score
PlayerData.Score = PlayerData.Score + Score
MESSAGE:NewType( self.DisplayMessagePrefix .. Text,
MESSAGE.Type.Information )
:ToAll()
if Text then
MESSAGE:NewType( self.DisplayMessagePrefix .. Text,
MESSAGE.Type.Information )
:ToAll()
end
self:ScoreCSV( PlayerName, "", "GOAL_" .. string.upper( GoalTag ), 1, Score, nil )
end
end
@@ -738,7 +786,7 @@ function SCORING:AddGoalScore( PlayerUnit, GoalTag, Text, Score )
local PlayerName = PlayerUnit:GetPlayerName()
self:F( { PlayerUnit.UnitName, PlayerName, GoalTag, Text, Score } )
self:T2( { PlayerUnit.UnitName, PlayerName, GoalTag, Text, Score } )
-- PlayerName can be nil, if the Unit with the player crashed or due to another reason.
if PlayerName then
@@ -747,11 +795,12 @@ function SCORING:AddGoalScore( PlayerUnit, GoalTag, Text, Score )
PlayerData.Goals[GoalTag] = PlayerData.Goals[GoalTag] or { Score = 0 }
PlayerData.Goals[GoalTag].Score = PlayerData.Goals[GoalTag].Score + Score
PlayerData.Score = PlayerData.Score + Score
MESSAGE:NewType( self.DisplayMessagePrefix .. Text,
if Text then
MESSAGE:NewType( self.DisplayMessagePrefix .. Text,
MESSAGE.Type.Information )
:ToAll()
end
self:ScoreCSV( PlayerName, "", "GOAL_" .. string.upper( GoalTag ), 1, Score, PlayerUnit:GetName() )
end
end
@@ -784,11 +833,12 @@ function SCORING:_AddMissionTaskScore( Mission, PlayerUnit, Text, Score )
PlayerData.Score = self.Players[PlayerName].Score + Score
PlayerData.Mission[MissionName].ScoreTask = self.Players[PlayerName].Mission[MissionName].ScoreTask + Score
MESSAGE:NewType( self.DisplayMessagePrefix .. Mission:GetText() .. " : " .. Text .. " Score: " .. Score,
MESSAGE.Type.Information )
:ToAll()
if Text then
MESSAGE:NewType( self.DisplayMessagePrefix .. Mission:GetText() .. " : " .. Text .. " Score: " .. Score,
MESSAGE.Type.Information )
:ToAll()
end
self:ScoreCSV( PlayerName, "", "TASK_" .. MissionName:gsub( ' ', '_' ), 1, Score, PlayerUnit:GetName() )
end
end
@@ -820,9 +870,11 @@ function SCORING:_AddMissionGoalScore( Mission, PlayerName, Text, Score )
PlayerData.Score = self.Players[PlayerName].Score + Score
PlayerData.Mission[MissionName].ScoreTask = self.Players[PlayerName].Mission[MissionName].ScoreTask + Score
MESSAGE:NewType( string.format( "%s%s: %s! Player %s receives %d score!", self.DisplayMessagePrefix, Mission:GetText(), Text, PlayerName, Score ), MESSAGE.Type.Information ):ToAll()
if Text then
MESSAGE:NewType( string.format( "%s%s: %s! Player %s receives %d score!", self.DisplayMessagePrefix, Mission:GetText(), Text, PlayerName, Score ), MESSAGE.Type.Information ):ToAll()
end
self:ScoreCSV( PlayerName, "", "TASK_" .. MissionName:gsub( ' ', '_' ), 1, Score )
end
end
@@ -847,11 +899,12 @@ function SCORING:_AddMissionScore( Mission, Text, Score )
PlayerData.Score = PlayerData.Score + Score
PlayerData.Mission[MissionName].ScoreMission = PlayerData.Mission[MissionName].ScoreMission + Score
MESSAGE:NewType( self.DisplayMessagePrefix .. "Player '" .. PlayerName .. "' has " .. Text .. " in " .. Mission:GetText() .. ". " .. Score .. " mission score!",
if Text then
MESSAGE:NewType( self.DisplayMessagePrefix .. "Player '" .. PlayerName .. "' has " .. Text .. " in " .. Mission:GetText() .. ". " .. Score .. " mission score!",
MESSAGE.Type.Information )
:ToAll()
end
self:ScoreCSV( PlayerName, "", "MISSION_" .. MissionName:gsub( ' ', '_' ), 1, Score )
end
end
@@ -879,6 +932,7 @@ function SCORING:OnEventBirth( Event )
Event.IniUnit.BirthTime = timer.getTime()
if PlayerName then
self:_AddPlayerFromUnit( Event.IniUnit )
self.Players[PlayerName].PlayerKills = 0
self:SetScoringMenu( Event.IniGroup )
end
end
@@ -1007,11 +1061,11 @@ function SCORING:_EventOnHit( Event )
PlayerHit.PenaltyHit = PlayerHit.PenaltyHit or 0
PlayerHit.TimeStamp = PlayerHit.TimeStamp or 0
PlayerHit.UNIT = PlayerHit.UNIT or TargetUNIT
-- After an instant kill we can't compute the thread level anymore. To fix this we compute at OnEventBirth
-- After an instant kill we can't compute the threat level anymore. To fix this we compute at OnEventBirth
if PlayerHit.UNIT.ThreatType == nil then
PlayerHit.ThreatLevel, PlayerHit.ThreatType = PlayerHit.UNIT:GetThreatLevel()
PlayerHit.ThreatLevel, PlayerHit.ThreatType = PlayerHit.UNIT:GetThreatLevel()
-- if this fails for some reason, set a good default value
if PlayerHit.ThreatType == nil then
if PlayerHit.ThreatType == nil or PlayerHit.ThreatType == "" then
PlayerHit.ThreatLevel = 1
PlayerHit.ThreatType = "Unknown"
end
@@ -1019,7 +1073,7 @@ function SCORING:_EventOnHit( Event )
PlayerHit.ThreatLevel = PlayerHit.UNIT.ThreatLevel
PlayerHit.ThreatType = PlayerHit.UNIT.ThreatType
end
-- Only grant hit scores if there was more than one second between the last hit.
if timer.getTime() - PlayerHit.TimeStamp > 1 then
PlayerHit.TimeStamp = timer.getTime()
@@ -1054,10 +1108,8 @@ function SCORING:_EventOnHit( Event )
end
self:ScoreCSV( InitPlayerName, TargetPlayerName, "HIT_PENALTY", 1, -10, InitUnitName, InitUnitCoalition, InitUnitCategory, InitUnitType, TargetUnitName, TargetUnitCoalition, TargetUnitCategory, TargetUnitType )
else
-- Hitting a target multiple times before destoying it should not result in a higger score
-- Multiple hits is typically a results of bombs/missles missing their target but still inflict some spash damage
-- Player.Score = Player.Score + 1
-- PlayerHit.Score = PlayerHit.Score + 1
Player.Score = Player.Score + self.ScoreIncrementOnHit
PlayerHit.Score = PlayerHit.Score + self.ScoreIncrementOnHit
PlayerHit.ScoreHit = PlayerHit.ScoreHit + 1
if TargetPlayerName ~= nil then -- It is a player hitting another player ...
MESSAGE:NewType( self.DisplayMessagePrefix .. "Player '" .. InitPlayerName .. "' hit enemy player '" .. TargetPlayerName .. "' " .. TargetUnitCategory .. " ( " .. TargetType .. " ) " .. PlayerHit.ScoreHit .. " times. " ..
@@ -1120,9 +1172,9 @@ function SCORING:_EventOnHit( Event )
PlayerHit.PenaltyHit = PlayerHit.PenaltyHit or 0
PlayerHit.TimeStamp = PlayerHit.TimeStamp or 0
PlayerHit.UNIT = PlayerHit.UNIT or TargetUNIT
-- After an instant kill we can't compute the thread level anymore. To fix this we compute at OnEventBirth
-- After an instant kill we can't compute the threat level anymore. To fix this we compute at OnEventBirth
if PlayerHit.UNIT.ThreatType == nil then
PlayerHit.ThreatLevel, PlayerHit.ThreatType = PlayerHit.UNIT:GetThreatLevel()
PlayerHit.ThreatLevel, PlayerHit.ThreatType = PlayerHit.UNIT:GetThreatLevel()
-- if this fails for some reason, set a good default value
if PlayerHit.ThreatType == nil then
PlayerHit.ThreatLevel = 1
@@ -1157,10 +1209,8 @@ function SCORING:_EventOnHit( Event )
:ToCoalitionIf( Event.WeaponCoalition, self:IfMessagesHit() and self:IfMessagesToCoalition() )
self:ScoreCSV( Event.WeaponPlayerName, TargetPlayerName, "HIT_PENALTY", 1, -10, Event.WeaponName, Event.WeaponCoalition, Event.WeaponCategory, Event.WeaponTypeName, TargetUnitName, TargetUnitCoalition, TargetUnitCategory, TargetUnitType )
else
-- Hitting a target multiple times before destoying it should not result in a higger score
-- Multiple hits is typically a results of bombs/missles missing their target but still inflict some spash damage
-- Player.Score = Player.Score + 1
-- PlayerHit.Score = PlayerHit.Score + 1
Player.Score = Player.Score + self.ScoreIncrementOnHit
PlayerHit.Score = PlayerHit.Score + self.ScoreIncrementOnHit
PlayerHit.ScoreHit = PlayerHit.ScoreHit + 1
MESSAGE:NewType( self.DisplayMessagePrefix .. "Player '" .. Event.WeaponPlayerName .. "' hit enemy target " .. TargetUnitCategory .. " ( " .. TargetType .. " ) " ..
"Score: " .. PlayerHit.Score .. ". Score Total:" .. Player.Score - Player.Penalty,
@@ -1268,13 +1318,18 @@ function SCORING:_EventOnDeadOrCrash( Event )
TargetDestroy.Penalty = TargetDestroy.Penalty + ThreatPenalty
TargetDestroy.PenaltyDestroy = TargetDestroy.PenaltyDestroy + 1
--self:OnKillPvP(PlayerName, TargetPlayerName, true, TargetThreatLevel, Player.ThreatLevel, ThreatPenalty)
if Player.HitPlayers[TargetPlayerName] then -- A player destroyed another player
self:OnKillPvP(PlayerName, TargetPlayerName, true)
MESSAGE:NewType( self.DisplayMessagePrefix .. "Player '" .. PlayerName .. "' destroyed friendly player '" .. TargetPlayerName .. "' " .. TargetUnitCategory .. " ( " .. ThreatTypeTarget .. " ) " ..
"Penalty: -" .. ThreatPenalty .. " = " .. Player.Score - Player.Penalty,
MESSAGE.Type.Information )
:ToAllIf( self:IfMessagesDestroy() and self:IfMessagesToAll() )
:ToCoalitionIf( InitCoalition, self:IfMessagesDestroy() and self:IfMessagesToCoalition() )
else
self:OnKillPvE(PlayerName, TargetUnitName, true, TargetThreatLevel, Player.ThreatLevel, ThreatPenalty)
MESSAGE:NewType( self.DisplayMessagePrefix .. "Player '" .. PlayerName .. "' destroyed friendly target " .. TargetUnitCategory .. " ( " .. ThreatTypeTarget .. " ) " ..
"Penalty: -" .. ThreatPenalty .. " = " .. Player.Score - Player.Penalty,
MESSAGE.Type.Information )
@@ -1297,12 +1352,19 @@ function SCORING:_EventOnDeadOrCrash( Event )
TargetDestroy.Score = TargetDestroy.Score + ThreatScore
TargetDestroy.ScoreDestroy = TargetDestroy.ScoreDestroy + 1
if Player.HitPlayers[TargetPlayerName] then -- A player destroyed another player
if Player.PlayerKills ~= nil then
Player.PlayerKills = Player.PlayerKills + 1
else
Player.PlayerKills = 1
end
self:OnKillPvP(PlayerName, TargetPlayerName, false, TargetThreatLevel, Player.ThreatLevel, ThreatScore)
MESSAGE:NewType( self.DisplayMessagePrefix .. "Player '" .. PlayerName .. "' destroyed enemy player '" .. TargetPlayerName .. "' " .. TargetUnitCategory .. " ( " .. ThreatTypeTarget .. " ) " ..
"Score: +" .. ThreatScore .. " = " .. Player.Score - Player.Penalty,
MESSAGE.Type.Information )
:ToAllIf( self:IfMessagesDestroy() and self:IfMessagesToAll() )
:ToCoalitionIf( InitCoalition, self:IfMessagesDestroy() and self:IfMessagesToCoalition() )
else
self:OnKillPvE(PlayerName, TargetUnitName, false, TargetThreatLevel, Player.ThreatLevel, ThreatScore)
MESSAGE:NewType( self.DisplayMessagePrefix .. "Player '" .. PlayerName .. "' destroyed enemy " .. TargetUnitCategory .. " ( " .. ThreatTypeTarget .. " ) " ..
"Score: +" .. ThreatScore .. " = " .. Player.Score - Player.Penalty,
MESSAGE.Type.Information )
@@ -1415,7 +1477,7 @@ function SCORING:ReportDetailedPlayerHits( PlayerName )
Penalty = Penalty + UnitData.Penalty
PenaltyHit = UnitData.PenaltyHit
end
local ScoreMessageHit = string.format( "%s:%d ", CategoryName, Score - Penalty )
local ScoreMessageHit = string.format( "%s: %d ", CategoryName, Score - Penalty )
self:T( ScoreMessageHit )
ScoreMessageHits = ScoreMessageHits .. ScoreMessageHit
PlayerScore = PlayerScore + Score
@@ -1471,7 +1533,7 @@ function SCORING:ReportDetailedPlayerDestroys( PlayerName )
end
end
local ScoreMessageDestroy = string.format( " %s:%d ", CategoryName, Score - Penalty )
local ScoreMessageDestroy = string.format( " %s: %d ", CategoryName, Score - Penalty )
self:T( ScoreMessageDestroy )
ScoreMessageDestroys = ScoreMessageDestroys .. ScoreMessageDestroy
@@ -1762,9 +1824,9 @@ function SCORING:SecondsToClock( sSeconds )
-- return nil;
return "00:00:00";
else
nHours = string.format( "%02.f", math.floor( nSeconds / 3600 ) );
nMins = string.format( "%02.f", math.floor( nSeconds / 60 - (nHours * 60) ) );
nSecs = string.format( "%02.f", math.floor( nSeconds - nHours * 3600 - nMins * 60 ) );
local nHours = string.format( "%02.f", math.floor( nSeconds / 3600 ) );
local nMins = string.format( "%02.f", math.floor( nSeconds / 60 - (nHours * 60) ) );
local nSecs = string.format( "%02.f", math.floor( nSeconds - nHours * 3600 - nMins * 60 ) );
return nHours .. ":" .. nMins .. ":" .. nSecs
end
end
@@ -1780,10 +1842,11 @@ end
function SCORING:OpenCSV( ScoringCSV )
self:F( ScoringCSV )
if lfs and io and os and self.AutoSave then
if lfs and io and os and self.AutoSave == true then
if ScoringCSV then
self.ScoringCSV = ScoringCSV
local fdir = lfs.writedir() .. [[Logs\]] .. self.ScoringCSV .. " " .. os.date( "%Y-%m-%d %H-%M-%S" ) .. ".csv"
local path = self.AutoSavePath or lfs.writedir() .. [[Logs\]]
local fdir = path .. self.ScoringCSV .. " " .. os.date( "%Y-%m-%d %H-%M-%S" ) .. ".csv"
self.CSVFile, self.err = io.open( fdir, "w+" )
if not self.CSVFile then
@@ -1901,3 +1964,26 @@ function SCORING:SwitchAutoSave(OnOff)
self.AutoSave = OnOff
return self
end
--- Handles the event when one player kill another player
-- @param #SCORING self
-- @param #string PlayerName The attacking player
-- @param #string TargetPlayerName The name of the killed player
-- @param #boolean IsTeamKill true if this kill was a team kill
-- @param #number TargetThreatLevel Threat level of the target
-- @param #number PlayerThreatLevel Threat level of the player
-- @param #number Score The score based on both threat levels
function SCORING:OnKillPvP(PlayerName, TargetPlayerName, IsTeamKill, TargetThreatLevel, PlayerThreatLevel, Score)
end
--- Handles the event when one player kill another player
-- @param #SCORING self
-- @param #string PlayerName The attacking player
-- @param #string TargetUnitName the name of the killed unit
-- @param #boolean IsTeamKill true if this kill was a team kill
-- @param #number TargetThreatLevel Threat level of the target
-- @param #number PlayerThreatLevel Threat level of the player
-- @param #number Score The score based on both threat levels
function SCORING:OnKillPvE(PlayerName, TargetUnitName, IsTeamKill, TargetThreatLevel, PlayerThreatLevel, Score)
end

View File

@@ -1,4 +1,4 @@
--- **Functional** - Make SAM sites execute evasive and defensive behaviour when being fired upon.
--- **Functional** - Make SAM sites evasive and execute defensive behaviour when being fired upon.
--
-- ===
--
@@ -13,13 +13,13 @@
--
-- ## Missions:
--
-- [SEV - SEAD Evasion](https://github.com/FlightControl-Master/MOOSE_MISSIONS/tree/master/SEV%20-%20SEAD%20Evasion)
-- [SEV - SEAD Evasion](https://github.com/FlightControl-Master/MOOSE_MISSIONS/tree/master/Functional/Sead)
--
-- ===
--
-- ### Authors: **FlightControl**, **applevangelist**
-- ### Authors: **applevangelist**, **FlightControl**
--
-- Last Update: Feb 2022
-- Last Update: Dec 2023
--
-- ===
--
@@ -34,7 +34,7 @@
--
-- This class is very easy to use. Just setup a SEAD object by using @{#SEAD.New}() and SAMs will evade and take defensive action when being fired upon.
-- Once a HARM attack is detected, SEAD will shut down the radars of the attacked SAM site and take evasive action by moving the SAM
-- vehicles around (*if* they are drivable, that is). There's a component of randomness in detection and evasion, which is based on the
-- vehicles around (*if* they are driveable, that is). There's a component of randomness in detection and evasion, which is based on the
-- skill set of the SAM set (the higher the skill, the more likely). When a missile is fired from far away, the SAM will stay active for a
-- period of time to stay defensive, before it takes evasive actions.
--
@@ -66,7 +66,6 @@ SEAD = {
-- @field Harms
SEAD.Harms = {
["AGM_88"] = "AGM_88",
["AGM_45"] = "AGM_45",
["AGM_122"] = "AGM_122",
["AGM_84"] = "AGM_84",
["AGM_45"] = "AGM_45",
@@ -80,6 +79,7 @@ SEAD = {
["BGM_109"] = "BGM_109",
["AGM_154"] = "AGM_154",
["HY-2"] = "HY-2",
["ADM_141A"] = "ADM_141A",
}
--- Missile enumerators - from DCS ME and Wikipedia
@@ -100,6 +100,7 @@ SEAD = {
["BGM_109"] = {460, 0.705}, --in-game ~465kn
["AGM_154"] = {130, 0.61},
["HY-2"] = {90,1},
["ADM_141A"] = {126,0.6},
}
--- Creates the main object which is handling defensive actions for SA sites or moving SA vehicles.
@@ -143,7 +144,7 @@ function SEAD:New( SEADGroupPrefixes, Padding )
self:AddTransition("*", "ManageEvasion", "*")
self:AddTransition("*", "CalculateHitZone", "*")
self:I("*** SEAD - Started Version 0.4.3")
self:I("*** SEAD - Started Version 0.4.6")
return self
end
@@ -203,7 +204,7 @@ function SEAD:SwitchEmissions(Switch)
return self
end
--- Add an object to call back when going evasive.
--- Set an object to call back when going evasive.
-- @param #SEAD self
-- @param #table Object The object to call. Needs to have object functions as follows:
-- `:SeadSuppressionPlanned(Group, Name, SuppressionStartTime, SuppressionEndTime)`
@@ -319,9 +320,6 @@ function SEAD:onafterCalculateHitZone(From,Event,To,SEADWeapon,pos0,height,SEADG
end
local seadset = SET_GROUP:New():FilterPrefixes(self.SEADGroupPrefixes):FilterZones({targetzone}):FilterOnce()
local tgtcoord = targetzone:GetRandomPointVec2()
--if tgtcoord and tgtcoord.ClassName == "COORDINATE" then
--local tgtgrp = seadset:FindNearestGroupFromPointVec2(tgtcoord)
local tgtgrp = seadset:GetRandom()
local _targetgroup = nil
local _targetgroupname = "none"
@@ -348,8 +346,9 @@ end
-- @param #string SEADWeaponName
-- @param Wrapper.Group#GROUP SEADGroup Attacker Group
-- @param #number timeoffset Offset for tti calc
-- @param Wrapper.Weapon#WEAPON Weapon
-- @return #SEAD self
function SEAD:onafterManageEvasion(From,Event,To,_targetskill,_targetgroup,SEADPlanePos,SEADWeaponName,SEADGroup,timeoffset)
function SEAD:onafterManageEvasion(From,Event,To,_targetskill,_targetgroup,SEADPlanePos,SEADWeaponName,SEADGroup,timeoffset,Weapon)
local timeoffset = timeoffset or 0
if _targetskill == "Random" then -- when skill is random, choose a skill
local Skills = { "Average", "Good", "High", "Excellent" }
@@ -369,9 +368,13 @@ function SEAD:onafterManageEvasion(From,Event,To,_targetskill,_targetgroup,SEADP
local reach = 10
if hit then
local wpndata = SEAD.HarmData[data]
reach = wpndata[1] * 1,1
reach = wpndata[1] * 1.1
local mach = wpndata[2]
wpnspeed = math.floor(mach * 340.29)
if Weapon then
wpnspeed = Weapon:GetSpeed()
self:T(string.format("*** SEAD - Weapon Speed from WEAPON: %f m/s",wpnspeed))
end
end
-- time to impact
local _tti = math.floor(_distance / wpnspeed) - timeoffset -- estimated impact time
@@ -395,7 +398,7 @@ function SEAD:onafterManageEvasion(From,Event,To,_targetskill,_targetgroup,SEADP
grp:EnableEmission(false)
end
grp:OptionAlarmStateGreen() -- needed else we cannot move around
grp:RelocateGroundRandomInRadius(20,300,false,false,"Diamond")
grp:RelocateGroundRandomInRadius(20,300,false,false,"Diamond",true)
if self.UseCallBack then
local object = self.CallBack
object:SeadSuppressionStart(grp,name,attacker)
@@ -405,7 +408,7 @@ function SEAD:onafterManageEvasion(From,Event,To,_targetskill,_targetgroup,SEADP
local function SuppressionStop(args)
self:T(string.format("*** SEAD - %s Radar On",args[2]))
local grp = args[1] -- Wrapper.Group#GROUP
local name = args[2] -- #string Group Nam
local name = args[2] -- #string Group Name
if self.UseEmissionsOnOff then
grp:EnableEmission(true)
end
@@ -424,7 +427,7 @@ function SEAD:onafterManageEvasion(From,Event,To,_targetskill,_targetgroup,SEADP
if _tti > 600 then delay = _tti - 90 end -- shot from afar, 600 is default shorad ontime
local SuppressionStartTime = timer.getTime() + delay
local SuppressionEndTime = timer.getTime() + _tti + self.Padding
local SuppressionEndTime = timer.getTime() + delay + _tti + self.Padding + delay
local _targetgroupname = _targetgroup:GetName()
if not self.SuppressedGroups[_targetgroupname] then
self:T(string.format("*** SEAD - %s | Parameters TTI %ds | Switch-Off in %ds",_targetgroupname,_tti,delay))
@@ -457,6 +460,9 @@ function SEAD:HandleEventShot( EventData )
local SEADWeapon = EventData.Weapon -- Identify the weapon fired
local SEADWeaponName = EventData.WeaponName -- return weapon type
local WeaponWrapper = WEAPON:New(EventData.Weapon)
--local SEADWeaponSpeed = WeaponWrapper:GetSpeed() -- mps
self:T( "*** SEAD - Missile Launched = " .. SEADWeaponName)
--self:T({ SEADWeapon })
@@ -475,7 +481,7 @@ function SEAD:HandleEventShot( EventData )
end
return self
end
local targetcat = _target:getCategory() -- Identify category
local targetcat = Object.getCategory(_target) -- Identify category
local _targetUnit = nil -- Wrapper.Unit#UNIT
local _targetgroup = nil -- Wrapper.Group#GROUP
self:T(string.format("*** Targetcat = %d",targetcat))
@@ -513,7 +519,11 @@ function SEAD:HandleEventShot( EventData )
end
end
if SEADGroupFound == true then -- yes we are being attacked
self:ManageEvasion(_targetskill,_targetgroup,SEADPlanePos,SEADWeaponName,SEADGroup)
if string.find(SEADWeaponName,"ADM_141",1,true) then
self:__ManageEvasion(2,_targetskill,_targetgroup,SEADPlanePos,SEADWeaponName,SEADGroup,0,WeaponWrapper)
else
self:ManageEvasion(_targetskill,_targetgroup,SEADPlanePos,SEADWeaponName,SEADGroup,0,WeaponWrapper)
end
end
end
return self

View File

@@ -11,7 +11,7 @@
--
-- ## Missions:
--
-- ### [SHORAD - Short Range Air Defense](https://github.com/FlightControl-Master/MOOSE_MISSIONS/tree/master/SRD%20-%20SHORAD%20Defense)
-- ### [SHORAD - Short Range Air Defense](https://github.com/FlightControl-Master/MOOSE_MISSIONS/tree/master/Functional/Shorad)
--
-- ===
--
@@ -21,6 +21,7 @@
-- @image Functional.Shorad.jpg
--
-- Date: Nov 2021
-- Last Update: Nov 2023
-------------------------------------------------------------------------
--- **SHORAD** class, extends Core.Base#BASE
@@ -39,8 +40,15 @@
-- @field #boolean DefendHarms Default true, intercept incoming HARMS
-- @field #boolean DefendMavs Default true, intercept incoming AG-Missiles
-- @field #number DefenseLowProb Default 70, minimum detection limit
-- @field #number DefenseHighProb Default 90, maximim detection limit
-- @field #boolean UseEmOnOff Decide if we are using Emission on/off (default) or AlarmState red/green.
-- @field #number DefenseHighProb Default 90, maximum detection limit
-- @field #boolean UseEmOnOff Decide if we are using Emission on/off (default) or AlarmState red/green
-- @field #boolean shootandscoot If true, shoot and scoot between zones
-- @field #number SkateNumber Number of zones to consider
-- @field Core.Set#SET_ZONE SkateZones Zones in this set are considered
-- @field #number minscootdist Min distance of the next zone
-- @field #number maxscootdist Max distance of the next zone
-- @field #boolean scootrandomcoord If true, use a random coordinate in the zone and not the center
-- @field #string scootformation Formation to take for scooting, e.g. "Vee" or "Cone"
-- @extends Core.Base#BASE
@@ -73,14 +81,15 @@
--
-- `myshorad = SHORAD:New("RedShorad", "Red SHORAD", SamSet, 25000, 600, "red")`
--
-- ## Customize options
-- ## Customization options
--
-- * SHORAD:SwitchDebug(debug)
-- * SHORAD:SwitchHARMDefense(onoff)
-- * SHORAD:SwitchAGMDefense(onoff)
-- * SHORAD:SetDefenseLimits(low,high)
-- * SHORAD:SetActiveTimer(seconds)
-- * SHORAD:SetDefenseRadius(meters)
-- * myshorad:SwitchDebug(debug)
-- * myshorad:SwitchHARMDefense(onoff)
-- * myshorad:SwitchAGMDefense(onoff)
-- * myshorad:SetDefenseLimits(low,high)
-- * myshorad:SetActiveTimer(seconds)
-- * myshorad:SetDefenseRadius(meters)
-- * myshorad:AddScootZones(ZoneSet,Number,Random,Formation)
--
-- @field #SHORAD
SHORAD = {
@@ -99,7 +108,13 @@ SHORAD = {
DefendMavs = true,
DefenseLowProb = 70,
DefenseHighProb = 90,
UseEmOnOff = false,
UseEmOnOff = true,
shootandscoot = false,
SkateNumber = 3,
SkateZones = nil,
minscootdist = 100,
minscootdist = 3000,
scootrandomcoord = false,
}
-----------------------------------------------------------------------
@@ -112,7 +127,6 @@ do
-- @field Harms
SHORAD.Harms = {
["AGM_88"] = "AGM_88",
["AGM_45"] = "AGM_45",
["AGM_122"] = "AGM_122",
["AGM_84"] = "AGM_84",
["AGM_45"] = "AGM_45",
@@ -123,6 +137,8 @@ do
["X_25"] = "X_25",
["X_31"] = "X_31",
["Kh25"] = "Kh25",
["HY-2"] = "HY-2",
["ADM_141A"] = "ADM_141A",
}
--- TODO complete list?
@@ -134,7 +150,6 @@ do
["Kh29"] = "Kh29",
["Kh31"] = "Kh31",
["Kh66"] = "Kh66",
--["BGM_109"] = "BGM_109",
}
--- Instantiates a new SHORAD object
@@ -146,7 +161,7 @@ do
-- @param #number ActiveTimer Determines how many seconds the systems stay on red alert after wake-up call
-- @param #string Coalition Coalition, i.e. "blue", "red", or "neutral"
-- @param #boolean UseEmOnOff Use Emissions On/Off rather than Alarm State Red/Green (default: use Emissions switch)
-- @retunr #SHORAD self
-- @return #SHORAD self
function SHORAD:New(Name, ShoradPrefix, Samset, Radius, ActiveTimer, Coalition, UseEmOnOff)
local self = BASE:Inherit( self, FSM:New() )
self:T({Name, ShoradPrefix, Samset, Radius, ActiveTimer, Coalition})
@@ -165,8 +180,9 @@ do
self.DefendMavs = true
self.DefenseLowProb = 70 -- probability to detect a missile shot, low margin
self.DefenseHighProb = 90 -- probability to detect a missile shot, high margin
self.UseEmOnOff = UseEmOnOff or false -- Decide if we are using Emission on/off (default) or AlarmState red/green
self:I("*** SHORAD - Started Version 0.3.1")
self.UseEmOnOff = true -- Decide if we are using Emission on/off (default) or AlarmState red/green
if UseEmOnOff == false then self.UseEmOnOff = UseEmOnOff end
self:I("*** SHORAD - Started Version 0.3.4")
-- Set the string id for output to DCS.log file.
self.lid=string.format("SHORAD %s | ", self.name)
self:_InitState()
@@ -176,12 +192,14 @@ do
self:SetStartState("Running")
self:AddTransition("*", "WakeUpShorad", "*")
self:AddTransition("*", "CalculateHitZone", "*")
self:AddTransition("*", "ShootAndScoot", "*")
return self
end
--- Initially set all groups to alarm state GREEN
-- @param #SHORAD self
-- @return #SHORAD self
function SHORAD:_InitState()
self:T(self.lid .. " _InitState")
local table = {}
@@ -205,21 +223,40 @@ do
return self
end
--- Add a SET_ZONE of zones for Shoot&Scoot
-- @param #SHORAD self
-- @param Core.Set#SET_ZONE ZoneSet Set of zones to be used. Units will move around to the next (random) zone between 100m and 3000m away.
-- @param #number Number Number of closest zones to be considered, defaults to 3.
-- @param #boolean Random If true, use a random coordinate inside the next zone to scoot to.
-- @param #string Formation Formation to use, defaults to "Cone". See mission editor dropdown for options.
-- @return #SHORAD self
function SHORAD:AddScootZones(ZoneSet, Number, Random, Formation)
self:T(self.lid .. " AddScootZones")
self.SkateZones = ZoneSet
self.SkateNumber = Number or 3
self.shootandscoot = true
self.scootrandomcoord = Random
self.scootformation = Formation or "Cone"
return self
end
--- Switch debug state on
-- @param #SHORAD self
-- @param #boolean debug Switch debug on (true) or off (false)
-- @return #SHORAD self
function SHORAD:SwitchDebug(onoff)
self:T( { onoff } )
if onoff then
self:SwitchDebugOn()
else
self.SwitchDebugOff()
self:SwitchDebugOff()
end
return self
end
--- Switch debug state on
-- @param #SHORAD self
-- @return #SHORAD self
function SHORAD:SwitchDebugOn()
self.debug = true
--tracing
@@ -230,6 +267,7 @@ do
--- Switch debug state off
-- @param #SHORAD self
-- @return #SHORAD self
function SHORAD:SwitchDebugOff()
self.debug = false
BASE:TraceOff()
@@ -239,6 +277,7 @@ do
--- Switch defense for HARMs
-- @param #SHORAD self
-- @param #boolean onoff
-- @return #SHORAD self
function SHORAD:SwitchHARMDefense(onoff)
self:T( { onoff } )
local onoff = onoff or true
@@ -249,6 +288,7 @@ do
--- Switch defense for AGMs
-- @param #SHORAD self
-- @param #boolean onoff
-- @return #SHORAD self
function SHORAD:SwitchAGMDefense(onoff)
self:T( { onoff } )
local onoff = onoff or true
@@ -260,6 +300,7 @@ do
-- @param #SHORAD self
-- @param #number low Minimum detection limit, integer 1-100
-- @param #number high Maximum detection limit integer 1-100
-- @return #SHORAD self
function SHORAD:SetDefenseLimits(low,high)
self:T( { low, high } )
local low = low or 70
@@ -278,6 +319,7 @@ do
--- Set the number of seconds a SHORAD site will stay active
-- @param #SHORAD self
-- @param #number seconds Number of seconds systems stay active
-- @return #SHORAD self
function SHORAD:SetActiveTimer(seconds)
self:T(self.lid .. " SetActiveTimer")
local timer = seconds or 600
@@ -291,6 +333,7 @@ do
--- Set the number of meters for the SHORAD defense zone
-- @param #SHORAD self
-- @param #number meters Radius of the defense search zone in meters. #SHORADs in this range around a targeted group will go active
-- @return #SHORAD self
function SHORAD:SetDefenseRadius(meters)
self:T(self.lid .. " SetDefenseRadius")
local radius = meters or 20000
@@ -304,6 +347,7 @@ do
--- Set using Emission on/off instead of changing alarm state
-- @param #SHORAD self
-- @param #boolean switch Decide if we are changing alarm state or AI state
-- @return #SHORAD self
function SHORAD:SetUsingEmOnOff(switch)
self:T(self.lid .. " SetUsingEmOnOff")
self.UseEmOnOff = switch or false
@@ -375,11 +419,11 @@ do
local shorad = self.Groupset
local shoradset = shorad:GetAliveSet() --#table
local returnname = false
--local TDiff = 1
for _,_groups in pairs (shoradset) do
local groupname = _groups:GetName()
if string.find(groupname, tgtgrp, 1, true) then
returnname = true
--_groups:RelocateGroundRandomInRadius(7,100,false,false) -- be a bit evasive
end
end
return returnname
@@ -426,6 +470,7 @@ do
-- @param #number Radius Radius of the #ZONE
-- @param #number ActiveTimer Number of seconds to stay active
-- @param #number TargetCat (optional) Category, i.e. Object.Category.UNIT or Object.Category.STATIC
-- @return #SHORAD self
-- @usage Use this function to integrate with other systems, example
--
-- local SamSet = SET_GROUP:New():FilterPrefixes("Blue SAM"):FilterCoalitions("blue"):FilterStart()
@@ -452,28 +497,35 @@ do
local targetzone = ZONE_RADIUS:New("Shorad",targetvec2,Radius) -- create a defense zone to check
local groupset = self.Groupset --Core.Set#SET_GROUP
local shoradset = groupset:GetAliveSet() --#table
-- local function to switch off shorad again
local function SleepShorad(group)
local groupname = group:GetName()
self.ActiveGroups[groupname] = nil
if self.UseEmOnOff then
group:EnableEmission(false)
--group:SetAIOff()
else
group:OptionAlarmStateGreen()
if group and group:IsAlive() then
local groupname = group:GetName()
self.ActiveGroups[groupname] = nil
if self.UseEmOnOff then
group:EnableEmission(false)
else
group:OptionAlarmStateGreen()
end
local text = string.format("Sleeping SHORAD %s", group:GetName())
self:T(text)
local m = MESSAGE:New(text,10,"SHORAD"):ToAllIf(self.debug)
--Shoot and Scoot
if self.shootandscoot then
self:__ShootAndScoot(1,group)
end
end
local text = string.format("Sleeping SHORAD %s", group:GetName())
self:T(text)
local m = MESSAGE:New(text,10,"SHORAD"):ToAllIf(self.debug)
end
-- go through set and find the one(s) to activate
local TDiff = 4
for _,_group in pairs (shoradset) do
if _group:IsAnyInZone(targetzone) then
local text = string.format("Waking up SHORAD %s", _group:GetName())
self:T(text)
local m = MESSAGE:New(text,10,"SHORAD"):ToAllIf(self.debug)
if self.UseEmOnOff then
--_group:SetAIOn()
_group:EnableEmission(true)
end
_group:OptionAlarmStateRed()
@@ -481,91 +533,132 @@ do
if self.ActiveGroups[groupname] == nil then -- no timer yet for this group
self.ActiveGroups[groupname] = { Timing = ActiveTimer }
local endtime = timer.getTime() + (ActiveTimer * math.random(75,100) / 100 ) -- randomize wakeup a bit
timer.scheduleFunction(SleepShorad, _group, endtime)
self.ActiveGroups[groupname].Timer = TIMER:New(SleepShorad,_group):Start(endtime)
--Shoot and Scoot
if self.shootandscoot then
self:__ShootAndScoot(TDiff,_group)
TDiff=TDiff+1
end
end
end
end
return self
end
--- (Internal) Calculate hit zone of an AGM-88
-- @param #SHORAD self
-- @param #table SEADWeapon DCS.Weapon object
-- @param Core.Point#COORDINATE pos0 Position of the plane when it fired
-- @param #number height Height when the missile was fired
-- @param Wrapper.Group#GROUP SEADGroup Attacker group
-- @return #SHORAD self
function SHORAD:onafterCalculateHitZone(From,Event,To,SEADWeapon,pos0,height,SEADGroup)
self:T("**** Calculating hit zone")
if SEADWeapon and SEADWeapon:isExist() then
--local pos = SEADWeapon:getPoint()
--- (Internal) Calculate hit zone of an AGM-88
-- @param #SHORAD self
-- @param #table SEADWeapon DCS.Weapon object
-- @param Core.Point#COORDINATE pos0 Position of the plane when it fired
-- @param #number height Height when the missile was fired
-- @param Wrapper.Group#GROUP SEADGroup Attacker group
-- @return #SHORAD self
function SHORAD:onafterCalculateHitZone(From,Event,To,SEADWeapon,pos0,height,SEADGroup)
self:T("**** Calculating hit zone")
if SEADWeapon and SEADWeapon:isExist() then
--local pos = SEADWeapon:getPoint()
-- postion and height
local position = SEADWeapon:getPosition()
local mheight = height
-- heading
local wph = math.atan2(position.x.z, position.x.x)
if wph < 0 then
wph=wph+2*math.pi
end
wph=math.deg(wph)
-- velocity
local wpndata = SEAD.HarmData["AGM_88"]
local mveloc = math.floor(wpndata[2] * 340.29)
local c1 = (2*mheight*9.81)/(mveloc^2)
local c2 = (mveloc^2) / 9.81
local Ropt = c2 * math.sqrt(c1+1)
if height <= 5000 then
Ropt = Ropt * 0.72
elseif height <= 7500 then
Ropt = Ropt * 0.82
elseif height <= 10000 then
Ropt = Ropt * 0.87
elseif height <= 12500 then
Ropt = Ropt * 0.98
end
-- look at a couple of zones across the trajectory
for n=1,3 do
local dist = Ropt - ((n-1)*20000)
local predpos= pos0:Translate(dist,wph)
if predpos then
-- postion and height
local position = SEADWeapon:getPosition()
local mheight = height
-- heading
local wph = math.atan2(position.x.z, position.x.x)
if wph < 0 then
wph=wph+2*math.pi
end
wph=math.deg(wph)
-- velocity
local wpndata = SEAD.HarmData["AGM_88"]
local mveloc = math.floor(wpndata[2] * 340.29)
local c1 = (2*mheight*9.81)/(mveloc^2)
local c2 = (mveloc^2) / 9.81
local Ropt = c2 * math.sqrt(c1+1)
if height <= 5000 then
Ropt = Ropt * 0.72
elseif height <= 7500 then
Ropt = Ropt * 0.82
elseif height <= 10000 then
Ropt = Ropt * 0.87
elseif height <= 12500 then
Ropt = Ropt * 0.98
local targetzone = ZONE_RADIUS:New("Target Zone",predpos:GetVec2(),20000)
if self.debug then
predpos:MarkToAll(string.format("height=%dm | heading=%d | velocity=%ddeg | Ropt=%dm",mheight,wph,mveloc,Ropt),false)
targetzone:DrawZone(coalition.side.BLUE,{0,0,1},0.2,nil,nil,3,true)
end
local seadset = self.Groupset
local tgtcoord = targetzone:GetRandomPointVec2()
local tgtgrp = seadset:FindNearestGroupFromPointVec2(tgtcoord)
local _targetgroup = nil
local _targetgroupname = "none"
local _targetskill = "Random"
if tgtgrp and tgtgrp:IsAlive() then
_targetgroup = tgtgrp
_targetgroupname = tgtgrp:GetName() -- group name
_targetskill = tgtgrp:GetUnit(1):GetSkill()
self:T("*** Found Target = ".. _targetgroupname)
self:WakeUpShorad(_targetgroupname, self.Radius, self.ActiveTimer, Object.Category.UNIT)
end
end
end
end
-- look at a couple of zones across the trajectory
for n=1,3 do
local dist = Ropt - ((n-1)*20000)
local predpos= pos0:Translate(dist,wph)
if predpos then
return self
end
local targetzone = ZONE_RADIUS:New("Target Zone",predpos:GetVec2(),20000)
if self.debug then
predpos:MarkToAll(string.format("height=%dm | heading=%d | velocity=%ddeg | Ropt=%dm",mheight,wph,mveloc,Ropt),false)
targetzone:DrawZone(coalition.side.BLUE,{0,0,1},0.2,nil,nil,3,true)
end
local seadset = self.Groupset
local tgtcoord = targetzone:GetRandomPointVec2()
local tgtgrp = seadset:FindNearestGroupFromPointVec2(tgtcoord)
local _targetgroup = nil
local _targetgroupname = "none"
local _targetskill = "Random"
if tgtgrp and tgtgrp:IsAlive() then
_targetgroup = tgtgrp
_targetgroupname = tgtgrp:GetName() -- group name
_targetskill = tgtgrp:GetUnit(1):GetSkill()
self:T("*** Found Target = ".. _targetgroupname)
self:WakeUpShorad(_targetgroupname, self.Radius, self.ActiveTimer, Object.Category.UNIT)
--- (Internal) Shoot and Scoot
-- @param #SHORAD self
-- @param #string From
-- @param #string Event
-- @param #string To
-- @param Wrapper.Group#GROUP Shorad Shorad group
-- @return #SHORAD self
function SHORAD:onafterShootAndScoot(From,Event,To,Shorad)
self:T( { From,Event,To } )
local possibleZones = {}
local mindist = self.minscootdist or 100
local maxdist = self.maxscootdist or 3000
if Shorad and Shorad:IsAlive() then
local NowCoord = Shorad:GetCoordinate()
for _,_zone in pairs(self.SkateZones.Set) do
local zone = _zone -- Core.Zone#ZONE_RADIUS
local dist = NowCoord:Get2DDistance(zone:GetCoordinate())
if dist >= mindist and dist <= maxdist then
possibleZones[#possibleZones+1] = zone
if #possibleZones == self.SkateNumber then break end
end
end
end
if #possibleZones > 0 and Shorad:GetVelocityKMH() < 2 then
local rand = math.floor(math.random(1,#possibleZones*1000)/1000+0.5)
if rand == 0 then rand = 1 end
self:T(self.lid .. " ShootAndScoot to zone "..rand)
local ToCoordinate = possibleZones[rand]:GetCoordinate()
if self.scootrandomcoord then
ToCoordinate = possibleZones[rand]:GetRandomCoordinate(nil,nil,{land.SurfaceType.LAND,land.SurfaceType.ROAD})
end
local formation = self.scootformation or "Cone"
Shorad:RouteGroundTo(ToCoordinate,20,formation,1)
end
end
return self
end
return self
end
--- Main function - work on the EventData
-- @param #SHORAD self
-- @param Core.Event#EVENTDATA EventData The event details table data set
-- @return #SHORAD self
function SHORAD:HandleEventShot( EventData )
self:T( { EventData } )
self:T(self.lid .. " HandleEventShot")
--local ShootingUnit = EventData.IniDCSUnit
--local ShootingUnitName = EventData.IniDCSUnitName
local ShootingWeapon = EventData.Weapon -- Identify the weapon fired
local ShootingWeaponName = EventData.WeaponName -- return weapon type
-- get firing coalition
@@ -596,27 +689,18 @@ end
return self
end
local targetcat = targetdata:getCategory() -- Identify category
local targetcat = Object.getCategory(targetdata) -- Identify category
self:T(string.format("Target Category (3=STATIC, 1=UNIT)= %s",tostring(targetcat)))
self:T({targetdata})
local targetunit = nil
if targetcat == Object.Category.UNIT then -- UNIT
targetunit = UNIT:Find(targetdata)
elseif targetcat == Object.Category.STATIC then -- STATIC
--self:T("Static Target Data")
--self:T({targetdata:isExist()})
--self:T({targetdata:getPoint()})
local tgtcoord = COORDINATE:NewFromVec3(targetdata:getPoint())
--tgtcoord:MarkToAll("Missile Target",true)
local tgtgrp1 = self.Samset:FindNearestGroupFromPointVec2(tgtcoord)
local tgtgrp1 = self.Samset:FindNearestGroupFromPointVec2(tgtcoord)
local tgtcoord1 = tgtgrp1:GetCoordinate()
--tgtcoord1:MarkToAll("Close target SAM",true)
local tgtgrp2 = self.Groupset:FindNearestGroupFromPointVec2(tgtcoord)
local tgtcoord2 = tgtgrp2:GetCoordinate()
--tgtcoord2:MarkToAll("Close target SHORAD",true)
local dist1 = tgtcoord:Get2DDistance(tgtcoord1)
local dist2 = tgtcoord:Get2DDistance(tgtcoord2)
@@ -628,10 +712,8 @@ end
targetcat = Object.Category.UNIT
end
end
--local targetunitname = Unit.getName(targetdata) -- Unit name
if targetunit and targetunit:IsAlive() then
local targetunitname = targetunit:GetName()
--local targetgroup = Unit.getGroup(Weapon.getTarget(ShootingWeapon)) --targeted group
local targetgroup = nil
local targetgroupname = "none"
if targetcat == Object.Category.UNIT then
@@ -649,7 +731,6 @@ end
self:T( text )
local m = MESSAGE:New(text,10,"Info"):ToAllIf(self.debug)
-- check if we or a SAM site are the target
--local TargetGroup = EventData.TgtGroup -- Wrapper.Group#GROUP
local shotatus = self:_CheckShotAtShorad(targetgroupname) --#boolean
local shotatsams = self:_CheckShotAtSams(targetgroupname) --#boolean
-- if being shot at, find closest SHORADs to activate
@@ -666,4 +747,4 @@ end
end
-----------------------------------------------------------------------
-- SHORAD end
-----------------------------------------------------------------------
-----------------------------------------------------------------------

File diff suppressed because it is too large Load Diff

View File

@@ -33,9 +33,9 @@
--
-- ===
--
-- ### Author: **[funkyfranky](https://forums.eagle.ru/member.php?u=115026)**
-- ### Author: **funkyfranky**
--
-- ### Contributions: [FlightControl](https://forums.eagle.ru/member.php?u=89536)
-- ### Contributions: FlightControl
--
-- ===
--

View File

@@ -0,0 +1,590 @@
--- **Functional** - TIRESIAS - manages AI behaviour.
--
-- ===
--
-- The @{#TIRESIAS} class is working in the back to keep your large-scale ground units in check.
--
-- ## Features:
--
-- * Designed to keep CPU and Network usage lower on missions with a lot of ground units.
-- * Does not affect ships to keep the Navy guys happy.
-- * Does not affect OpsGroup type groups.
-- * Distinguishes between SAM groups, AAA groups and other ground groups.
-- * Exceptions can be defined to keep certain actions going.
-- * Works coalition-independent in the back
-- * Easy setup.
--
-- ===
--
-- ## Missions:
--
-- ### [TIRESIAS](https://github.com/FlightControl-Master/MOOSE_MISSIONS/tree/master)
--
-- ===
--
-- ### Author : **applevangelist **
--
-- @module Functional.Tiresias
-- @image Functional.Tiresias.jpg
--
-- Last Update: Dec 2023
-------------------------------------------------------------------------
--- **TIRESIAS** class, extends Core.Base#BASE
-- @type TIRESIAS
-- @field #string ClassName
-- @field #booelan debug
-- @field #string version
-- @field #number Interval
-- @field Core.Set#SET_GROUP GroundSet
-- @field #number Coalition
-- @field Core.Set#SET_GROUP VehicleSet
-- @field Core.Set#SET_GROUP AAASet
-- @field Core.Set#SET_GROUP SAMSet
-- @field Core.Set#SET_GROUP ExceptionSet
-- @field Core.Set#SET_OPSGROUP OpsGroupSet
-- @field #number AAARange
-- @field #number HeloSwitchRange
-- @field #number PlaneSwitchRange
-- @field Core.Set#SET_GROUP FlightSet
-- @field #boolean SwitchAAA
-- @extends Core.Fsm#FSM
---
-- @type TIRESIAS.Data
-- @field #string type
-- @field #number range
-- @field #boolean invisible
-- @field #boolean AIOff
-- @field #boolean exception
--- *Tiresias, Greek demi-god and shapeshifter, blinded by the Gods, works as oracle for you.* (Wiki)
--
-- ===
--
-- ## TIRESIAS Concept
--
-- * Designed to keep CPU and Network usage lower on missions with a lot of ground units.
-- * Does not affect ships to keep the Navy guys happy.
-- * Does not affect OpsGroup type groups.
-- * Distinguishes between SAM groups, AAA groups and other ground groups.
-- * Exceptions can be defined in SET_GROUP objects to keep certain actions going.
-- * Works coalition-independent in the back
-- * Easy setup.
--
-- ## Setup
--
-- Setup is a one-liner:
--
-- local blinder = TIRESIAS:New()
--
-- Optionally you can set up exceptions, e.g. for convoys driving around
--
-- local exceptionset = SET_GROUP:New():FilterCoalitions("red"):FilterPrefixes("Convoy"):FilterStart()
-- local blinder = TIRESIAS:New()
-- blinder:AddExceptionSet(exceptionset)
--
-- Options
--
-- -- Setup different radius for activation around helo and airplane groups (applies to AI and humans)
-- blinder:SetActivationRanges(10,25) -- defaults are 10, and 25
--
-- -- Setup engagement ranges for AAA (non-advanced SAM units like Flaks etc) and if you want them to be AIOff
-- blinder:SetAAARanges(60,true) -- defaults are 60, and true
--
-- @field #TIRESIAS
TIRESIAS = {
ClassName = "TIRESIAS",
debug = false,
version = "0.0.4",
Interval = 20,
GroundSet = nil,
VehicleSet = nil,
AAASet = nil,
SAMSet = nil,
ExceptionSet = nil,
AAARange = 60, -- 60%
HeloSwitchRange = 10, -- NM
PlaneSwitchRange = 25, -- NM
SwitchAAA = true,
}
--- [USER] Create a new Tiresias object and start it up.
-- @param #TIRESIAS self
-- @return #TIRESIAS self
function TIRESIAS:New()
-- Inherit everything from FSM class.
local self = BASE:Inherit(self, FSM:New()) -- #TIRESIAS
--- FSM Functions ---
-- Start State.
self:SetStartState("Stopped")
-- Add FSM transitions.
-- From State --> Event --> To State
self:AddTransition("Stopped", "Start", "Running") -- Start FSM.
self:AddTransition("*", "Status", "*") -- TIRESIAS status update.
self:AddTransition("*", "Stop", "Stopped") -- Stop FSM.
self.ExceptionSet = SET_GROUP:New():Clear(false)
self:HandleEvent(EVENTS.PlayerEnterAircraft,self._EventHandler)
self.lid = string.format("TIRESIAS %s | ",self.version)
self:I(self.lid.."Managing ground groups!")
--- Triggers the FSM event "Stop". Stops TIRESIAS and all its event handlers.
-- @function [parent=#TIRESIAS] Stop
-- @param #TIRESIAS self
--- Triggers the FSM event "Stop" after a delay. Stops TIRESIAS and all its event handlers.
-- @function [parent=#TIRESIAS] __Stop
-- @param #TIRESIAS self
-- @param #number delay Delay in seconds.
--- Triggers the FSM event "Start". Starts TIRESIAS and all its event handlers. Note - `:New()` already starts the instance.
-- @function [parent=#TIRESIAS] Start
-- @param #TIRESIAS self
--- Triggers the FSM event "Start" after a delay. Starts TIRESIAS and all its event handlers. Note - `:New()` already starts the instance.
-- @function [parent=#TIRESIAS] __Start
-- @param #TIRESIAS self
-- @param #number delay Delay in seconds.
self:__Start(1)
return self
end
-------------------------------------------------------------------------------------------------------------
--
-- Helper Functions
--
-------------------------------------------------------------------------------------------------------------
---[USER] Set activation radius for Helos and Planes in Nautical Miles.
-- @param #TIRESIAS self
-- @param #number HeloMiles Radius around a Helicopter in which AI ground units will be activated. Defaults to 10NM.
-- @param #number PlaneMiles Radius around an Airplane in which AI ground units will be activated. Defaults to 25NM.
-- @return #TIRESIAS self
function TIRESIAS:SetActivationRanges(HeloMiles,PlaneMiles)
self.HeloSwitchRange = HeloMiles or 10
self.PlaneSwitchRange = PlaneMiles or 25
return self
end
---[USER] Set AAA Ranges - AAA equals non-SAM systems which qualify as AAA in DCS world.
-- @param #TIRESIAS self
-- @param #number FiringRange The engagement range that AAA units will be set to. Can be 0 to 100 (percent). Defaults to 60.
-- @param #boolean SwitchAAA Decide if these system will have their AI switched off, too. Defaults to true.
-- @return #TIRESIAS self
function TIRESIAS:SetAAARanges(FiringRange,SwitchAAA)
self.AAARange = FiringRange or 60
self.SwitchAAA = (SwitchAAA == false) and false or true
return self
end
--- [USER] Add a SET_GROUP of GROUP objects as exceptions. Can be done multiple times.
-- @param #TIRESIAS self
-- @param Core.Set#SET_GROUP Set to add to the exception list.
-- @return #TIRESIAS self
function TIRESIAS:AddExceptionSet(Set)
self:T(self.lid.."AddExceptionSet")
local exceptions = self.ExceptionSet
Set:ForEachGroupAlive(
function(grp)
if not grp.Tiresias then
grp.Tiresias = { -- #TIRESIAS.Data
type = "Exception",
exception = true,
}
exceptions:AddGroup(grp,true)
end
BASE:I("TIRESIAS: Added exception group: "..grp:GetName())
end
)
return self
end
--- [INTERNAL] Filter Function
-- @param Wrapper.Group#GROUP Group
-- @return #boolean isin
function TIRESIAS._FilterNotAAA(Group)
local grp = Group -- Wrapper.Group#GROUP
local isaaa = grp:IsAAA()
if isaaa == true and grp:IsGround() and not grp:IsShip() then
return false -- remove from SET
else
return true -- keep in SET
end
end
--- [INTERNAL] Filter Function
-- @param Wrapper.Group#GROUP Group
-- @return #boolean isin
function TIRESIAS._FilterNotSAM(Group)
local grp = Group -- Wrapper.Group#GROUP
local issam = grp:IsSAM()
if issam == true and grp:IsGround() and not grp:IsShip() then
return false -- remove from SET
else
return true -- keep in SET
end
end
--- [INTERNAL] Filter Function
-- @param Wrapper.Group#GROUP Group
-- @return #boolean isin
function TIRESIAS._FilterAAA(Group)
local grp = Group -- Wrapper.Group#GROUP
local isaaa = grp:IsAAA()
if isaaa == true and grp:IsGround() and not grp:IsShip() then
return true -- remove from SET
else
return false -- keep in SET
end
end
--- [INTERNAL] Filter Function
-- @param Wrapper.Group#GROUP Group
-- @return #boolean isin
function TIRESIAS._FilterSAM(Group)
local grp = Group -- Wrapper.Group#GROUP
local issam = grp:IsSAM()
if issam == true and grp:IsGround() and not grp:IsShip() then
return true -- remove from SET
else
return false -- keep in SET
end
end
--- [INTERNAL] Init Groups
-- @param #TIRESIAS self
-- @return #TIRESIAS self
function TIRESIAS:_InitGroups()
self:T(self.lid.."_InitGroups")
-- Set all groups invisible/motionless
local EngageRange = self.AAARange
local SwitchAAA = self.SwitchAAA
--- AAA
self.AAASet:ForEachGroupAlive(
function(grp)
if not grp.Tiresias then
grp:OptionEngageRange(EngageRange)
grp:SetCommandInvisible(true)
if SwitchAAA then
grp:SetAIOff()
grp:EnableEmission(false)
end
grp.Tiresias = { -- #TIRESIAS.Data
type = "AAA",
invisible = true,
range = EngageRange,
exception = false,
AIOff = SwitchAAA,
}
end
if grp.Tiresias and (not grp.Tiresias.exception == true) then
if grp.Tiresias.invisible and grp.Tiresias.invisible == false then
grp:SetCommandInvisible(true)
grp.Tiresias.invisible = true
if SwitchAAA then
grp:SetAIOff()
grp:EnableEmission(false)
grp.Tiresias.AIOff = true
end
end
end
--BASE:I(string.format("Init/Switch off AAA %s (Exception %s)",grp:GetName(),tostring(grp.Tiresias.exception)))
end
)
--- Vehicles
self.VehicleSet:ForEachGroupAlive(
function(grp)
if not grp.Tiresias then
grp:SetAIOff()
grp:SetCommandInvisible(true)
grp.Tiresias = { -- #TIRESIAS.Data
type = "Vehicle",
invisible = true,
AIOff = true,
exception = false,
}
end
if grp.Tiresias and (not grp.Tiresias.exception == true) then
if grp.Tiresias and grp.Tiresias.invisible and grp.Tiresias.invisible == false then
grp:SetCommandInvisible(true)
grp:SetAIOff()
grp.Tiresias.invisible = true
end
end
--BASE:I(string.format("Init/Switch off Vehicle %s (Exception %s)",grp:GetName(),tostring(grp.Tiresias.exception)))
end
)
--- SAM
self.SAMSet:ForEachGroupAlive(
function(grp)
if not grp.Tiresias then
grp:SetCommandInvisible(true)
grp.Tiresias = { -- #TIRESIAS.Data
type = "SAM",
invisible = true,
exception = false,
}
end
if grp.Tiresias and (not grp.Tiresias.exception == true) then
if grp.Tiresias and grp.Tiresias.invisible and grp.Tiresias.invisible == false then
grp:SetCommandInvisible(true)
grp.Tiresias.invisible = true
end
end
--BASE:I(string.format("Init/Switch off SAM %s (Exception %s)",grp:GetName(),tostring(grp.Tiresias.exception)))
end
)
return self
end
--- [INTERNAL] Event handler function
-- @param #TIRESIAS self
-- @param Core.Event#EVENTDATA EventData
-- @return #TIRESIAS self
function TIRESIAS:_EventHandler(EventData)
self:T(string.format("%s Event = %d",self.lid, EventData.id))
local event = EventData -- Core.Event#EVENTDATA
if event.id == EVENTS.PlayerEnterAircraft or event.id == EVENTS.PlayerEnterUnit then
--local _coalition = event.IniCoalition
--if _coalition ~= self.Coalition then
-- return --ignore!
--end
local unitname = event.IniUnitName or "none"
local _unit = event.IniUnit
local _group = event.IniGroup
if _group and _group:IsAlive() then
local radius = self.PlaneSwitchRange
if _group:IsHelicopter() then
radius = self.HeloSwitchRange
end
self:_SwitchOnGroups(_group,radius)
end
end
return self
end
--- [INTERNAL] Switch Groups Behaviour
-- @param #TIRESIAS self
-- @param Wrapper.Group#GROUP group
-- @param #number radius Radius in NM
-- @return #TIRESIAS self
function TIRESIAS:_SwitchOnGroups(group,radius)
self:T(self.lid.."_SwitchOnGroups "..group:GetName().." Radius "..radius.." NM")
local zone = ZONE_GROUP:New("Zone-"..group:GetName(),group,UTILS.NMToMeters(radius))
local ground = SET_GROUP:New():FilterCategoryGround():FilterZones({zone}):FilterOnce()
local count = ground:CountAlive()
if self.debug then
local text = string.format("There are %d groups around this plane or helo!",count)
self:I(text)
end
local SwitchAAA = self.SwitchAAA
if ground:CountAlive() > 0 then
ground:ForEachGroupAlive(
function(grp)
if grp.Tiresias and grp.Tiresias.type and (not grp.Tiresias.exception == true ) then
if grp.Tiresias.invisible == true then
grp:SetCommandInvisible(false)
grp.Tiresias.invisible = false
end
if grp.Tiresias.type == "Vehicle" and grp.Tiresias.AIOff and grp.Tiresias.AIOff == true then
grp:SetAIOn()
grp.Tiresias.AIOff = false
end
if SwitchAAA and grp.Tiresias.type == "AAA" and grp.Tiresias.AIOff and grp.Tiresias.AIOff == true then
grp:SetAIOn()
grp:EnableEmission(true)
grp.Tiresias.AIOff = false
end
--BASE:I(string.format("TIRESIAS - Switch on %s %s (Exception %s)",tostring(grp.Tiresias.type),grp:GetName(),tostring(grp.Tiresias.exception)))
else
BASE:E("TIRESIAS - This group has not been initialized or is an exception!")
end
end
)
end
return self
end
-------------------------------------------------------------------------------------------------------------
--
-- FSM Functions
--
-------------------------------------------------------------------------------------------------------------
--- [INTERNAL] FSM Function
-- @param #TIRESIAS self
-- @param #string From
-- @param #string Event
-- @param #string To
-- @return #TIRESIAS self
function TIRESIAS:onafterStart(From, Event, To)
self:T({From, Event, To})
local VehicleSet = SET_GROUP:New():FilterCategoryGround():FilterFunction(TIRESIAS._FilterNotAAA):FilterFunction(TIRESIAS._FilterNotSAM):FilterStart()
local AAASet = SET_GROUP:New():FilterCategoryGround():FilterFunction(TIRESIAS._FilterAAA):FilterStart()
local SAMSet = SET_GROUP:New():FilterCategoryGround():FilterFunction(TIRESIAS._FilterSAM):FilterStart()
local OpsGroupSet = SET_OPSGROUP:New():FilterActive(true):FilterStart()
self.FlightSet = SET_GROUP:New():FilterCategories({"plane","helicopter"}):FilterStart()
local EngageRange = self.AAARange
local ExceptionSet = self.ExceptionSet
if self.ExceptionSet then
function ExceptionSet:OnAfterAdded(From,Event,To,ObjectName,Object)
BASE:I("TIRESIAS: EXCEPTION Object Added: "..Object:GetName())
if Object and Object:IsAlive() then
Object.Tiresias = { -- #TIRESIAS.Data
type = "Exception",
exception = true,
}
Object:SetAIOn()
Object:SetCommandInvisible(false)
Object:EnableEmission(true)
end
end
local OGS = OpsGroupSet:GetAliveSet()
for _,_OG in pairs(OGS or {}) do
local OG = _OG -- Ops.OpsGroup#OPSGROUP
local grp = OG:GetGroup()
ExceptionSet:AddGroup(grp,true)
end
function OpsGroupSet:OnAfterAdded(From,Event,To,ObjectName,Object)
local grp = Object:GetGroup()
ExceptionSet:AddGroup(grp,true)
end
end
function VehicleSet:OnAfterAdded(From,Event,To,ObjectName,Object)
BASE:I("TIRESIAS: VEHCILE Object Added: "..Object:GetName())
if Object and Object:IsAlive() then
Object:SetAIOff()
Object:SetCommandInvisible(true)
Object.Tiresias = { -- #TIRESIAS.Data
type = "Vehicle",
invisible = true,
AIOff = true,
exception = false,
}
end
end
local SwitchAAA = self.SwitchAAA
function AAASet:OnAfterAdded(From,Event,To,ObjectName,Object)
if Object and Object:IsAlive() then
BASE:I("TIRESIAS: AAA Object Added: "..Object:GetName())
Object:OptionEngageRange(EngageRange)
Object:SetCommandInvisible(true)
if SwitchAAA then
Object:SetAIOff()
Object:EnableEmission(false)
end
Object.Tiresias = { -- #TIRESIAS.Data
type = "AAA",
invisible = true,
range = EngageRange,
exception = false,
AIOff = SwitchAAA,
}
end
end
function SAMSet:OnAfterAdded(From,Event,To,ObjectName,Object)
if Object and Object:IsAlive() then
BASE:I("TIRESIAS: SAM Object Added: "..Object:GetName())
Object:SetCommandInvisible(true)
Object.Tiresias = { -- #TIRESIAS.Data
type = "SAM",
invisible = true,
exception = false,
}
end
end
self.VehicleSet = VehicleSet
self.AAASet = AAASet
self.SAMSet = SAMSet
self.OpsGroupSet = OpsGroupSet
self:_InitGroups()
self:__Status(1)
return self
end
--- [INTERNAL] FSM Function
-- @param #TIRESIAS self
-- @param #string From
-- @param #string Event
-- @param #string To
-- @return #TIRESIAS self
function TIRESIAS:onbeforeStatus(From, Event, To)
self:T({From, Event, To})
if self:GetState() == "Stopped" then
return false
end
return self
end
--- [INTERNAL] FSM Function
-- @param #TIRESIAS self
-- @param #string From
-- @param #string Event
-- @param #string To
-- @return #TIRESIAS self
function TIRESIAS:onafterStatus(From, Event, To)
self:T({From, Event, To})
if self.debug then
local count = self.VehicleSet:CountAlive()
local AAAcount = self.AAASet:CountAlive()
local SAMcount = self.SAMSet:CountAlive()
local text = string.format("Overall: %d | Vehicles: %d | AAA: %d | SAM: %d",count+AAAcount+SAMcount,count,AAAcount,SAMcount)
self:I(text)
end
self:_InitGroups()
if self.FlightSet:CountAlive() > 0 then
local Set = self.FlightSet:GetAliveSet()
for _,_plane in pairs(Set) do
local plane = _plane -- Wrapper.Group#GROUP
local radius = self.PlaneSwitchRange
if plane:IsHelicopter() then
radius = self.HeloSwitchRange
end
self:_SwitchOnGroups(_plane,radius)
end
end
if self:GetState() ~= "Stopped" then
self:__Status(self.Interval)
end
return self
end
--- [INTERNAL] FSM Function
-- @param #TIRESIAS self
-- @param #string From
-- @param #string Event
-- @param #string To
-- @return #TIRESIAS self
function TIRESIAS:onafterStop(From, Event, To)
self:T({From, Event, To})
self:UnHandleEvent(EVENTS.PlayerEnterAircraft)
return self
end
-------------------------------------------------------------------------------------------------------------
--
-- End
--
-------------------------------------------------------------------------------------------------------------

View File

@@ -87,7 +87,7 @@
-- @field #number respawndelay Delay before respawn in seconds.
-- @field #number runwaydestroyed Time stamp timer.getAbsTime() when the runway was destroyed.
-- @field #number runwayrepairtime Time in seconds until runway will be repaired after it was destroyed. Default is 3600 sec (one hour).
-- @field Ops.FlightControl#FLIGHTCONTROL flightcontrol Flight control of this warehouse.
-- @field OPS.FlightControl#FLIGHTCONTROL flightcontrol Flight control of this warehouse.
-- @extends Core.Fsm#FSM
--- Have your assets at the right place at the right time - or not!
@@ -742,7 +742,7 @@
--
-- ## Save Assets
--
-- Saving asset data to file is achieved by the @{WAREHOUSE.Save}(*path*, *filename*) function. The parameter *path* specifies the path on the file system where the
-- Saving asset data to file is achieved by the @{#WAREHOUSE.Save}(*path*, *filename*) function. The parameter *path* specifies the path on the file system where the
-- warehouse data is saved. If you do not specify a path, the file is saved your the DCS installation root directory.
-- The parameter *filename* is optional and defines the name of the saved file. By default this is automatically created from the warehouse id and name, for example
-- "Warehouse-1234_Batumi.txt".
@@ -753,13 +753,13 @@
--
-- ### Automatic Save at Mission End
--
-- The assets can be saved automatically when the mission is ended via the @{WAREHOUSE.SetSaveOnMissionEnd}(*path*, *filename*) function, i.e.
-- The assets can be saved automatically when the mission is ended via the @{#WAREHOUSE.SetSaveOnMissionEnd}(*path*, *filename*) function, i.e.
--
-- warehouseBatumi:SetSaveOnMissionEnd("D:\\My Warehouse Data\\")
--
-- ## Load Assets
--
-- Loading assets data from file is achieved by the @{WAREHOUSE.Load}(*path*, *filename*) function. The parameter *path* specifies the path on the file system where the
-- Loading assets data from file is achieved by the @{#WAREHOUSE.Load}(*path*, *filename*) function. The parameter *path* specifies the path on the file system where the
-- warehouse data is loaded from. If you do not specify a path, the file is loaded from your the DCS installation root directory.
-- The parameter *filename* is optional and defines the name of the file to load. By default this is automatically generated from the warehouse id and name, for example
-- "Warehouse-1234_Batumi.txt".
@@ -1629,7 +1629,7 @@ WAREHOUSE = {
-- @field #boolean arrived If true, asset arrived at its destination.
--
-- @field #number damage Damage of asset group in percent.
-- @field Ops.AirWing#AIRWING.Payload payload The payload of the asset.
-- @field Ops.Airwing#AIRWING.Payload payload The payload of the asset.
-- @field Ops.OpsGroup#OPSGROUP flightgroup The flightgroup object.
-- @field Ops.Cohort#COHORT cohort The cohort this asset belongs to.
-- @field Ops.Legion#LEGION legion The legion this asset belonts to.
@@ -3414,7 +3414,7 @@ end
-- FSM states
-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
--- On after Start event. Starts the warehouse. Addes event handlers and schedules status updates of reqests and queue.
--- On after Start event. Starts the warehouse. Adds event handlers and schedules status updates of reqests and queue.
-- @param #WAREHOUSE self
-- @param #string From From state.
-- @param #string Event Event.
@@ -3595,6 +3595,7 @@ function WAREHOUSE:onafterStatus(From, Event, To)
local Trepair=self:GetRunwayRepairtime()
self:I(self.lid..string.format("Runway destroyed! Will be repaired in %d sec", Trepair))
if Trepair==0 then
self.runwaydestroyed = nil
self:RunwayRepaired()
end
end
@@ -3616,9 +3617,10 @@ function WAREHOUSE:onafterStatus(From, Event, To)
end
-- Print queue after processing requests.
self:_PrintQueue(self.queue, "Queue waiting")
self:_PrintQueue(self.pending, "Queue pending")
if self.verbosity > 2 then
self:_PrintQueue(self.queue, "Queue waiting")
self:_PrintQueue(self.pending, "Queue pending")
end
-- Check fuel for all assets.
--self:_CheckFuel()
@@ -4101,9 +4103,9 @@ function WAREHOUSE:_RegisterAsset(group, ngroups, forceattribute, forcecargobay,
-- Get the size of an object.
local function _GetObjectSize(DCSdesc)
if DCSdesc.box then
local x=DCSdesc.box.max.x+math.abs(DCSdesc.box.min.x) --length
local y=DCSdesc.box.max.y+math.abs(DCSdesc.box.min.y) --height
local z=DCSdesc.box.max.z+math.abs(DCSdesc.box.min.z) --width
local x=DCSdesc.box.max.x-DCSdesc.box.min.x --length
local y=DCSdesc.box.max.y-DCSdesc.box.min.y --height
local z=DCSdesc.box.max.z-DCSdesc.box.min.z --width
return math.max(x,z), x , y, z
end
return 0,0,0,0
@@ -5391,7 +5393,8 @@ function WAREHOUSE:onafterRunwayDestroyed(From, Event, To)
self:_InfoMessage(text)
self.runwaydestroyed=timer.getAbsTime()
return self
end
--- On after "RunwayRepaired" event.
@@ -5406,7 +5409,8 @@ function WAREHOUSE:onafterRunwayRepaired(From, Event, To)
self:_InfoMessage(text)
self.runwaydestroyed=nil
return self
end
@@ -5498,8 +5502,13 @@ function WAREHOUSE:onafterAssetDead(From, Event, To, asset, request)
---
-- Remove dead group from cargo group set.
request.cargogroupset:Remove(groupname, NoTriggerEvent)
self:T(self.lid..string.format("Removed selfpropelled cargo %s: ncargo=%d.", groupname, request.cargogroupset:Count()))
if request.cargogroupset then
-- cargogroupset was nil for user case. Difficult to reproduce so we add a nil check.
request.cargogroupset:Remove(groupname, NoTriggerEvent)
self:T(self.lid..string.format("Removed selfpropelled cargo %s: ncargo=%d.", groupname, request.cargogroupset:Count()))
else
self:E(self.lid..string.format("ERROR: cargogroupset is nil for request ID=%s!", tostring(request.uid)))
end
else
@@ -6671,7 +6680,13 @@ function WAREHOUSE:_OnEventCrashOrDead(EventData)
self:Destroyed()
end
if self.airbase and self.airbasename and self.airbasename==EventData.IniUnitName then
self:RunwayDestroyed()
if self:IsRunwayOperational() then
-- Trigger RunwayDestroyed event (only if it is not destroyed already)
self:RunwayDestroyed()
else
-- Reset the time stamp.
self.runwaydestroyed=timer.getAbsTime()
end
end
end
@@ -6761,7 +6776,7 @@ function WAREHOUSE:_UnitDead(deadunit, deadgroup, request)
-- Dont trigger a Remove event for the group sets.
local NoTriggerEvent=true
if not request.transporttype==WAREHOUSE.TransportType.SELFPROPELLED then
if request.transporttype~=WAREHOUSE.TransportType.SELFPROPELLED then
---
-- Complicated case: Dead unit could be:
@@ -7392,6 +7407,8 @@ function WAREHOUSE:_CheckRequestNow(request)
-- Check if at least one (cargo) asset is available.
if _nassets>0 then
local asset=_assets[1] --#WAREHOUSE.Assetitem
-- Get the attibute of the requested asset.
_assetattribute=_assets[1].attribute
@@ -7402,11 +7419,24 @@ function WAREHOUSE:_CheckRequestNow(request)
if _assetcategory==Group.Category.AIRPLANE or _assetcategory==Group.Category.HELICOPTER then
if self.airbase and self.airbase:GetCoalition()==self:GetCoalition() then
-- Check if DCS warehouse of airbase has enough assets
if self.airbase.storage then
local nS=self.airbase.storage:GetAmount(asset.unittype)
local nA=asset.nunits*request.nasset -- Number of units requested
if nS<nA then
local text=string.format("Warehouse %s: Request denied! DCS Warehouse has only %d assets of type %s ==> NOT enough to spawn the requested %d asset units (%d groups)",
self.alias, nS, asset.unittype, nA, request.nasset)
self:_InfoMessage(text, 5)
return false
end
end
if self:IsRunwayOperational() or _assetairstart then
if _assetairstart then
-- Airstart no need to check parking
-- Airstart no need to check parking
else
-- Check parking.
@@ -7518,6 +7548,9 @@ function WAREHOUSE:_CheckRequestNow(request)
self:_InfoMessage(text, 5)
return false
end
elseif _assetcategory==Group.Category.AIRPLANE or _assetcategory==Group.Category.HELICOPTER then
end
@@ -7858,7 +7891,7 @@ function WAREHOUSE:_GetTerminal(_attribute, _category)
-- Default terminal is "large".
local _terminal=AIRBASE.TerminalType.OpenBig
if _attribute==WAREHOUSE.Attribute.AIR_FIGHTER then
if _attribute==WAREHOUSE.Attribute.AIR_FIGHTER or _attribute==WAREHOUSE.Attribute.AIR_UAV then
-- Fighter ==> small.
_terminal=AIRBASE.TerminalType.FighterAircraft
elseif _attribute==WAREHOUSE.Attribute.AIR_BOMBER or _attribute==WAREHOUSE.Attribute.AIR_TRANSPORTPLANE or _attribute==WAREHOUSE.Attribute.AIR_TANKER or _attribute==WAREHOUSE.Attribute.AIR_AWACS then
@@ -8223,7 +8256,7 @@ end
-- @return #number Request ID.
function WAREHOUSE:_GetIDsFromGroupName(groupname)
---@param #string text The text to analyse.
-- @param #string text The text to analyse.
local function analyse(text)
-- Get rid of #0001 tail from spawn.

View File

@@ -12,7 +12,7 @@
--
-- ## Missions:
--
-- [CAZ - Capture Zones](https://github.com/FlightControl-Master/MOOSE_MISSIONS/tree/master/CAZ%20-%20Capture%20Zones)
-- [CAZ - Capture Zones](https://github.com/FlightControl-Master/MOOSE_MISSIONS/tree/master/Functional/ZoneCaptureCoalition)
--
-- ===
--
@@ -363,8 +363,8 @@ do -- ZONE_CAPTURE_COALITION
--- ZONE_CAPTURE_COALITION Constructor.
-- @param #ZONE_CAPTURE_COALITION self
-- @param Core.Zone#ZONE Zone A @{Core.Zone} object with the goal to be achieved. Alternatively, can be handed as the name of late activated group describing a @{ZONE_POLYGON} with its waypoints.
-- @param DCSCoalition.DCSCoalition#coalition Coalition The initial coalition owning the zone.
-- @param Core.Zone#ZONE Zone A @{Core.Zone} object with the goal to be achieved. Alternatively, can be handed as the name of late activated group describing a @{Core.Zone#ZONE_POLYGON} with its waypoints.
-- @param #number Coalition The initial coalition owning the zone.
-- @param #table UnitCategories Table of unit categories. See [DCS Class Unit](https://wiki.hoggitworld.com/view/DCS_Class_Unit). Default {Unit.Category.GROUND_UNIT}.
-- @param #table ObjectCategories Table of unit categories. See [DCS Class Object](https://wiki.hoggitworld.com/view/DCS_Class_Object). Default {Object.Category.UNIT, Object.Category.STATIC}, i.e. all UNITS and STATICS.
-- @return #ZONE_CAPTURE_COALITION

View File

@@ -4,7 +4,12 @@
--
-- ZONE_GOAL_CARGO models processes that have a Goal with a defined achievement involving a Zone and Cargo.
-- Derived classes implement the ways how the achievements can be realized.
--
-- # Developer Note
--
-- Note while this class still works, it is no longer supported as the original author stopped active development of MOOSE
-- Therefore, this class is considered to be deprecated
--
-- ===
--
-- ### Author: **FlightControl**
@@ -56,7 +61,7 @@ do -- ZoneGoal
--- ZONE_GOAL_CARGO Constructor.
-- @param #ZONE_GOAL_CARGO self
-- @param Core.Zone#ZONE Zone A @{Core.Zone} object with the goal to be achieved.
-- @param DCSCoalition.DCSCoalition#coalition Coalition The initial coalition owning the zone.
-- @param #number Coalition The initial coalition owning the zone.
-- @return #ZONE_GOAL_CARGO
function ZONE_GOAL_CARGO:New( Zone, Coalition )
@@ -254,7 +259,7 @@ do -- ZoneGoal
--- Set the owning coalition of the zone.
-- @param #ZONE_GOAL_CARGO self
-- @param DCSCoalition.DCSCoalition#coalition Coalition
-- @param #number Coalition
function ZONE_GOAL_CARGO:SetCoalition( Coalition )
self.Coalition = Coalition
end
@@ -262,7 +267,7 @@ do -- ZoneGoal
--- Get the owning coalition of the zone.
-- @param #ZONE_GOAL_CARGO self
-- @return DCSCoalition.DCSCoalition#coalition Coalition.
-- @return #number Coalition.
function ZONE_GOAL_CARGO:GetCoalition()
return self.Coalition
end

View File

@@ -1,4 +1,4 @@
--- **Functional** - Base class that models processes to achieve goals involving a Zone for a Coalition.
--- **Functional (WIP)** - Base class modeling processes to achieve goals involving coalition zones.
--
-- ===
--
@@ -54,7 +54,7 @@ do -- ZoneGoal
--- ZONE_GOAL_COALITION Constructor.
-- @param #ZONE_GOAL_COALITION self
-- @param Core.Zone#ZONE Zone A @{Core.Zone} object with the goal to be achieved.
-- @param DCSCoalition.DCSCoalition#coalition Coalition The initial coalition owning the zone. Default coalition.side.NEUTRAL.
-- @param #number Coalition The initial coalition owning the zone. Default coalition.side.NEUTRAL.
-- @param #table UnitCategories Table of unit categories. See [DCS Class Unit](https://wiki.hoggitworld.com/view/DCS_Class_Unit). Default {Unit.Category.GROUND_UNIT}.
-- @return #ZONE_GOAL_COALITION
function ZONE_GOAL_COALITION:New( Zone, Coalition, UnitCategories )
@@ -80,7 +80,7 @@ do -- ZoneGoal
--- Set the owning coalition of the zone.
-- @param #ZONE_GOAL_COALITION self
-- @param DCSCoalition.DCSCoalition#coalition Coalition The coalition ID, e.g. *coalition.side.RED*.
-- @param #number Coalition The coalition ID, e.g. *coalition.side.RED*.
-- @return #ZONE_GOAL_COALITION
function ZONE_GOAL_COALITION:SetCoalition( Coalition )
self.PreviousCoalition = self.Coalition or Coalition
@@ -120,14 +120,14 @@ do -- ZoneGoal
--- Get the owning coalition of the zone.
-- @param #ZONE_GOAL_COALITION self
-- @return DCSCoalition.DCSCoalition#coalition Coalition.
-- @return #number Coalition.
function ZONE_GOAL_COALITION:GetCoalition()
return self.Coalition
end
--- Get the previous coalition, i.e. the one owning the zone before the current one.
-- @param #ZONE_GOAL_COALITION self
-- @return DCSCoalition.DCSCoalition#coalition Coalition.
-- @return #number Coalition.
function ZONE_GOAL_COALITION:GetPreviousCoalition()
return self.PreviousCoalition
end

View File

@@ -1,149 +1,189 @@
__Moose.Include( 'Scripts/Moose/Utilities/Enums.lua' )
__Moose.Include( 'Scripts/Moose/Utilities/Routines.lua' )
__Moose.Include( 'Scripts/Moose/Utilities/Utils.lua' )
__Moose.Include( 'Scripts/Moose/Utilities/Profiler.lua' )
__Moose.Include( 'Scripts/Moose/Utilities/Templates.lua' )
__Moose.Include( 'Scripts/Moose/Utilities/STTS.lua' )
__Moose.Include( 'Scripts/Moose/Utilities/FiFo.lua' )
__Moose.Include( 'Scripts/Moose/Utilities/Socket.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Utilities/Enums.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Utilities/Utils.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Utilities/Profiler.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Utilities/Templates.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Utilities/STTS.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Utilities/FiFo.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Utilities/Socket.lua' )
__Moose.Include( 'Scripts/Moose/Core/Base.lua' )
__Moose.Include( 'Scripts/Moose/Core/Astar.lua' )
__Moose.Include( 'Scripts/Moose/Core/Beacon.lua' )
__Moose.Include( 'Scripts/Moose/Core/Condition.lua' )
__Moose.Include( 'Scripts/Moose/Core/UserFlag.lua' )
__Moose.Include( 'Scripts/Moose/Core/Report.lua' )
__Moose.Include( 'Scripts/Moose/Core/Scheduler.lua' )
__Moose.Include( 'Scripts/Moose/Core/ScheduleDispatcher.lua' )
__Moose.Include( 'Scripts/Moose/Core/Event.lua' )
__Moose.Include( 'Scripts/Moose/Core/Settings.lua' )
__Moose.Include( 'Scripts/Moose/Core/Menu.lua' )
__Moose.Include( 'Scripts/Moose/Core/Zone.lua' )
__Moose.Include( 'Scripts/Moose/Core/Zone_Detection.lua' )
__Moose.Include( 'Scripts/Moose/Core/Database.lua' )
__Moose.Include( 'Scripts/Moose/Core/Set.lua' )
__Moose.Include( 'Scripts/Moose/Core/Point.lua' )
__Moose.Include( 'Scripts/Moose/Core/Velocity.lua' )
__Moose.Include( 'Scripts/Moose/Core/Message.lua' )
__Moose.Include( 'Scripts/Moose/Core/Fsm.lua' )
__Moose.Include( 'Scripts/Moose/Core/Spawn.lua' )
__Moose.Include( 'Scripts/Moose/Core/SpawnStatic.lua' )
__Moose.Include( 'Scripts/Moose/Core/Timer.lua' )
__Moose.Include( 'Scripts/Moose/Core/Goal.lua' )
__Moose.Include( 'Scripts/Moose/Core/Spot.lua' )
__Moose.Include( 'Scripts/Moose/Core/MarkerOps_Base.lua' )
__Moose.Include( 'Scripts/Moose/Core/TextAndSound.lua' )
__Moose.Include( 'Scripts/Moose/Core/Pathline.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Core/Base.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Core/Astar.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Core/Beacon.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Core/Condition.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Core/UserFlag.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Core/Report.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Core/Scheduler.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Core/ScheduleDispatcher.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Core/Event.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Core/Settings.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Core/Menu.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Core/Zone.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Core/Zone_Detection.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Core/Database.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Core/Set.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Core/Point.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Core/Velocity.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Core/Message.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Core/Fsm.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Core/Spawn.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Core/SpawnStatic.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Core/Timer.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Core/Goal.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Core/Spot.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Core/MarkerOps_Base.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Core/TextAndSound.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Core/Pathline.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Core/ClientMenu.lua')
__Moose.Include( 'Scripts/Moose/Wrapper/Object.lua' )
__Moose.Include( 'Scripts/Moose/Wrapper/Identifiable.lua' )
__Moose.Include( 'Scripts/Moose/Wrapper/Positionable.lua' )
__Moose.Include( 'Scripts/Moose/Wrapper/Controllable.lua' )
__Moose.Include( 'Scripts/Moose/Wrapper/Group.lua' )
__Moose.Include( 'Scripts/Moose/Wrapper/Unit.lua' )
__Moose.Include( 'Scripts/Moose/Wrapper/Client.lua' )
__Moose.Include( 'Scripts/Moose/Wrapper/Static.lua' )
__Moose.Include( 'Scripts/Moose/Wrapper/Airbase.lua' )
__Moose.Include( 'Scripts/Moose/Wrapper/Scenery.lua' )
__Moose.Include( 'Scripts/Moose/Wrapper/Marker.lua' )
__Moose.Include( 'Scripts/Moose/Wrapper/Weapon.lua' )
__Moose.Include( 'Scripts/Moose/Wrapper/Net.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Wrapper/Object.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Wrapper/Identifiable.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Wrapper/Positionable.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Wrapper/Controllable.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Wrapper/Group.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Wrapper/Unit.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Wrapper/Client.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Wrapper/Static.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Wrapper/Airbase.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Wrapper/Scenery.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Wrapper/Marker.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Wrapper/Weapon.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Wrapper/Net.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Wrapper/Storage.lua' )
__Moose.Include( 'Scripts/Moose/Cargo/Cargo.lua' )
__Moose.Include( 'Scripts/Moose/Cargo/CargoUnit.lua' )
__Moose.Include( 'Scripts/Moose/Cargo/CargoSlingload.lua' )
__Moose.Include( 'Scripts/Moose/Cargo/CargoCrate.lua' )
__Moose.Include( 'Scripts/Moose/Cargo/CargoGroup.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Cargo/Cargo.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Cargo/CargoUnit.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Cargo/CargoSlingload.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Cargo/CargoCrate.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Cargo/CargoGroup.lua' )
__Moose.Include( 'Scripts/Moose/Functional/Scoring.lua' )
__Moose.Include( 'Scripts/Moose/Functional/CleanUp.lua' )
__Moose.Include( 'Scripts/Moose/Functional/Movement.lua' )
__Moose.Include( 'Scripts/Moose/Functional/Sead.lua' )
__Moose.Include( 'Scripts/Moose/Functional/Escort.lua' )
__Moose.Include( 'Scripts/Moose/Functional/MissileTrainer.lua' )
__Moose.Include( 'Scripts/Moose/Functional/ATC_Ground.lua' )
__Moose.Include( 'Scripts/Moose/Functional/Detection.lua' )
__Moose.Include( 'Scripts/Moose/Functional/DetectionZones.lua' )
__Moose.Include( 'Scripts/Moose/Functional/Designate.lua' )
__Moose.Include( 'Scripts/Moose/Functional/RAT.lua' )
__Moose.Include( 'Scripts/Moose/Functional/Range.lua' )
__Moose.Include( 'Scripts/Moose/Functional/ZoneGoal.lua' )
__Moose.Include( 'Scripts/Moose/Functional/ZoneGoalCoalition.lua' )
__Moose.Include( 'Scripts/Moose/Functional/ZoneCaptureCoalition.lua' )
__Moose.Include( 'Scripts/Moose/Functional/Artillery.lua' )
__Moose.Include( 'Scripts/Moose/Functional/Suppression.lua' )
__Moose.Include( 'Scripts/Moose/Functional/PseudoATC.lua' )
__Moose.Include( 'Scripts/Moose/Functional/Warehouse.lua' )
__Moose.Include( 'Scripts/Moose/Functional/Fox.lua' )
__Moose.Include( 'Scripts/Moose/Functional/Mantis.lua' )
__Moose.Include( 'Scripts/Moose/Functional/Shorad.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Functional/Scoring.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Functional/CleanUp.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Functional/Movement.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Functional/Sead.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Functional/Escort.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Functional/MissileTrainer.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Functional/ATC_Ground.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Functional/Detection.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Functional/DetectionZones.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Functional/Designate.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Functional/RAT.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Functional/Range.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Functional/ZoneGoal.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Functional/ZoneGoalCoalition.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Functional/ZoneCaptureCoalition.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Functional/Artillery.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Functional/Suppression.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Functional/PseudoATC.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Functional/Warehouse.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Functional/Fox.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Functional/Mantis.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Functional/Shorad.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Functional/AICSAR.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Functional/AmmoTruck.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Functional/Autolase.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Functional/ZoneGoalCargo.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Functional/Tiresias.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Functional/Stratego.lua' )
__Moose.Include( 'Scripts/Moose/Ops/Airboss.lua' )
__Moose.Include( 'Scripts/Moose/Ops/RecoveryTanker.lua' )
__Moose.Include( 'Scripts/Moose/Ops/RescueHelo.lua' )
__Moose.Include( 'Scripts/Moose/Ops/ATIS.lua' )
__Moose.Include( 'Scripts/Moose/Ops/CTLD.lua' )
__Moose.Include( 'Scripts/Moose/Ops/CSAR.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Ops/Airboss.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Ops/RecoveryTanker.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Ops/RescueHelo.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Ops/ATIS.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Ops/CTLD.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Ops/CSAR.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Ops/AirWing.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Ops/ArmyGroup.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Ops/Auftrag.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Ops/Awacs.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Ops/Brigade.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Ops/Chief.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Ops/Cohort.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Ops/Commander.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Ops/Fleet.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Ops/FlightControl.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Ops/FlightGroup.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Ops/Flotilla.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Ops/Intelligence.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Ops/Legion.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Ops/NavyGroup.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Ops/Operation.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Ops/OpsGroup.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Ops/OpsTransport.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Ops/OpsZone.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Ops/Platoon.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Ops/PlayerTask.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Ops/PlayerRecce.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Ops/Squadron.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Ops/Target.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Ops/EasyGCICAP.lua' )
__Moose.Include( 'Scripts/Moose/AI/AI_Balancer.lua' )
__Moose.Include( 'Scripts/Moose/AI/AI_Air.lua' )
__Moose.Include( 'Scripts/Moose/AI/AI_Air_Patrol.lua' )
__Moose.Include( 'Scripts/Moose/AI/AI_Air_Engage.lua' )
__Moose.Include( 'Scripts/Moose/AI/AI_A2A_Patrol.lua' )
__Moose.Include( 'Scripts/Moose/AI/AI_A2A_Cap.lua' )
__Moose.Include( 'Scripts/Moose/AI/AI_A2A_Gci.lua' )
__Moose.Include( 'Scripts/Moose/AI/AI_A2A_Dispatcher.lua' )
__Moose.Include( 'Scripts/Moose/AI/AI_A2G_BAI.lua' )
__Moose.Include( 'Scripts/Moose/AI/AI_A2G_CAS.lua' )
__Moose.Include( 'Scripts/Moose/AI/AI_A2G_SEAD.lua' )
__Moose.Include( 'Scripts/Moose/AI/AI_A2G_Dispatcher.lua' )
__Moose.Include( 'Scripts/Moose/AI/AI_Patrol.lua' )
__Moose.Include( 'Scripts/Moose/AI/AI_Cap.lua' )
__Moose.Include( 'Scripts/Moose/AI/AI_Cas.lua' )
__Moose.Include( 'Scripts/Moose/AI/AI_Bai.lua' )
__Moose.Include( 'Scripts/Moose/AI/AI_Formation.lua' )
__Moose.Include( 'Scripts/Moose/AI/AI_Escort.lua' )
__Moose.Include( 'Scripts/Moose/AI/AI_Escort_Request.lua' )
__Moose.Include( 'Scripts/Moose/AI/AI_Escort_Dispatcher.lua' )
__Moose.Include( 'Scripts/Moose/AI/AI_Escort_Dispatcher_Request.lua' )
__Moose.Include( 'Scripts/Moose/AI/AI_Cargo.lua' )
__Moose.Include( 'Scripts/Moose/AI/AI_Cargo_APC.lua' )
__Moose.Include( 'Scripts/Moose/AI/AI_Cargo_Helicopter.lua' )
__Moose.Include( 'Scripts/Moose/AI/AI_Cargo_Airplane.lua' )
__Moose.Include( 'Scripts/Moose/AI/AI_Cargo_Ship.lua' )
__Moose.Include( 'Scripts/Moose/AI/AI_Cargo_Dispatcher.lua' )
__Moose.Include( 'Scripts/Moose/AI/AI_Cargo_Dispatcher_APC.lua' )
__Moose.Include( 'Scripts/Moose/AI/AI_Cargo_Dispatcher_Helicopter.lua' )
__Moose.Include( 'Scripts/Moose/AI/AI_Cargo_Dispatcher_Airplane.lua' )
__Moose.Include( 'Scripts/Moose/AI/AI_Cargo_Dispatcher_Ship.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/AI/AI_Balancer.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/AI/AI_Air.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/AI/AI_Air_Patrol.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/AI/AI_Air_Engage.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/AI/AI_A2A_Patrol.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/AI/AI_A2A_Cap.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/AI/AI_A2A_Gci.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/AI/AI_A2A_Dispatcher.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/AI/AI_A2G_BAI.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/AI/AI_A2G_CAS.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/AI/AI_A2G_SEAD.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/AI/AI_A2G_Dispatcher.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/AI/AI_Patrol.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/AI/AI_CAP.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/AI/AI_CAS.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/AI/AI_BAI.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/AI/AI_Formation.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/AI/AI_Escort.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/AI/AI_Escort_Request.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/AI/AI_Escort_Dispatcher.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/AI/AI_Escort_Dispatcher_Request.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/AI/AI_Cargo.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/AI/AI_Cargo_APC.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/AI/AI_Cargo_Helicopter.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/AI/AI_Cargo_Airplane.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/AI/AI_Cargo_Ship.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/AI/AI_Cargo_Dispatcher.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/AI/AI_Cargo_Dispatcher_APC.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/AI/AI_Cargo_Dispatcher_Helicopter.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/AI/AI_Cargo_Dispatcher_Airplane.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/AI/AI_Cargo_Dispatcher_Ship.lua' )
__Moose.Include( 'Scripts/Moose/Actions/Act_Assign.lua' )
__Moose.Include( 'Scripts/Moose/Actions/Act_Route.lua' )
__Moose.Include( 'Scripts/Moose/Actions/Act_Account.lua' )
__Moose.Include( 'Scripts/Moose/Actions/Act_Assist.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Actions/Act_Assign.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Actions/Act_Route.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Actions/Act_Account.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Actions/Act_Assist.lua' )
__Moose.Include( 'Scripts/Moose/Sound/UserSound.lua' )
__Moose.Include( 'Scripts/Moose/Sound/SoundOutput.lua' )
__Moose.Include( 'Scripts/Moose/Sound/Radio.lua' )
__Moose.Include( 'Scripts/Moose/Sound/RadioQueue.lua' )
__Moose.Include( 'Scripts/Moose/Sound/RadioSpeech.lua' )
__Moose.Include( 'Scripts/Moose/Sound/SRS.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Shapes/ShapeBase.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Shapes/Circle.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Shapes/Cube.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Shapes/Line.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Shapes/Oval.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Shapes/Polygon.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Shapes/Triangle.lua' )
__Moose.Include( 'Scripts/Moose/Tasking/CommandCenter.lua' )
__Moose.Include( 'Scripts/Moose/Tasking/Mission.lua' )
__Moose.Include( 'Scripts/Moose/Tasking/Task.lua' )
__Moose.Include( 'Scripts/Moose/Tasking/TaskInfo.lua' )
__Moose.Include( 'Scripts/Moose/Tasking/Task_Manager.lua' )
__Moose.Include( 'Scripts/Moose/Tasking/DetectionManager.lua' )
__Moose.Include( 'Scripts/Moose/Tasking/Task_A2G_Dispatcher.lua' )
__Moose.Include( 'Scripts/Moose/Tasking/Task_A2G.lua' )
__Moose.Include( 'Scripts/Moose/Tasking/Task_A2A_Dispatcher.lua' )
__Moose.Include( 'Scripts/Moose/Tasking/Task_A2A.lua' )
__Moose.Include( 'Scripts/Moose/Tasking/Task_Cargo.lua' )
__Moose.Include( 'Scripts/Moose/Tasking/Task_Cargo_Transport.lua' )
__Moose.Include( 'Scripts/Moose/Tasking/Task_Cargo_CSAR.lua' )
__Moose.Include( 'Scripts/Moose/Tasking/Task_Cargo_Dispatcher.lua' )
__Moose.Include( 'Scripts/Moose/Tasking/Task_Capture_Zone.lua' )
__Moose.Include( 'Scripts/Moose/Tasking/Task_Capture_Dispatcher.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Sound/UserSound.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Sound/SoundOutput.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Sound/Radio.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Sound/RadioQueue.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Sound/RadioSpeech.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Sound/SRS.lua' )
__Moose.Include( 'Scripts/Moose/Globals.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Tasking/CommandCenter.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Tasking/Mission.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Tasking/Task.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Tasking/TaskInfo.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Tasking/Task_Manager.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Tasking/DetectionManager.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Tasking/Task_A2G_Dispatcher.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Tasking/Task_A2G.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Tasking/Task_A2A_Dispatcher.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Tasking/Task_A2A.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Tasking/Task_CARGO.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Tasking/Task_Cargo_Transport.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Tasking/Task_Cargo_CSAR.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Tasking/Task_Cargo_Dispatcher.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Tasking/Task_Capture_Zone.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Tasking/Task_Capture_Dispatcher.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Globals.lua' )

View File

@@ -0,0 +1,172 @@
__Moose.Include( 'Utilities\\Enums.lua' )
__Moose.Include( 'Utilities\\Routines.lua' )
__Moose.Include( 'Utilities\\Utils.lua' )
__Moose.Include( 'Utilities\\Profiler.lua' )
__Moose.Include( 'Utilities\\Templates.lua' )
__Moose.Include( 'Utilities\\STTS.lua' )
__Moose.Include( 'Utilities\\FiFo.lua' )
__Moose.Include( 'Utilities\\Socket.lua' )
__Moose.Include( 'Core\\Base.lua' )
__Moose.Include( 'Core\\Beacon.lua' )
__Moose.Include( 'Core\\UserFlag.lua' )
__Moose.Include( 'Core\\Report.lua' )
__Moose.Include( 'Core\\Scheduler.lua' )
__Moose.Include( 'Core\\ScheduleDispatcher.lua' )
__Moose.Include( 'Core\\Event.lua' )
__Moose.Include( 'Core\\Settings.lua' )
__Moose.Include( 'Core\\Menu.lua' )
__Moose.Include( 'Core\\Zone.lua' )
__Moose.Include( 'Core\\Zone_Detection.lua' )
__Moose.Include( 'Core\\Database.lua' )
__Moose.Include( 'Core\\Set.lua' )
__Moose.Include( 'Core\\Point.lua' )
__Moose.Include( 'Core\\Velocity.lua' )
__Moose.Include( 'Core\\Message.lua' )
__Moose.Include( 'Core\\Fsm.lua' )
__Moose.Include( 'Core\\Spawn.lua' )
__Moose.Include( 'Core\\SpawnStatic.lua' )
__Moose.Include( 'Core\\Timer.lua' )
__Moose.Include( 'Core\\Goal.lua' )
__Moose.Include( 'Core\\Spot.lua' )
__Moose.Include( 'Core\\Astar.lua' )
__Moose.Include( 'Core\\MarkerOps_Base.lua' )
__Moose.Include( 'Core\\TextAndSound.lua' )
__Moose.Include( 'Core\\Condition.lua' )
__Moose.Include( 'Core\\ClientMenu.lua' )
__Moose.Include( 'Wrapper\\Object.lua' )
__Moose.Include( 'Wrapper\\Identifiable.lua' )
__Moose.Include( 'Wrapper\\Positionable.lua' )
__Moose.Include( 'Wrapper\\Controllable.lua' )
__Moose.Include( 'Wrapper\\Group.lua' )
__Moose.Include( 'Wrapper\\Unit.lua' )
__Moose.Include( 'Wrapper\\Client.lua' )
__Moose.Include( 'Wrapper\\Static.lua' )
__Moose.Include( 'Wrapper\\Airbase.lua' )
__Moose.Include( 'Wrapper\\Scenery.lua' )
__Moose.Include( 'Wrapper\\Marker.lua' )
__Moose.Include( 'Cargo\\Cargo.lua' )
__Moose.Include( 'Cargo\\CargoUnit.lua' )
__Moose.Include( 'Cargo\\CargoSlingload.lua' )
__Moose.Include( 'Cargo\\CargoCrate.lua' )
__Moose.Include( 'Cargo\\CargoGroup.lua' )
__Moose.Include( 'Functional\\Scoring.lua' )
__Moose.Include( 'Functional\\CleanUp.lua' )
__Moose.Include( 'Functional\\Movement.lua' )
__Moose.Include( 'Functional\\Sead.lua' )
__Moose.Include( 'Functional\\Escort.lua' )
__Moose.Include( 'Functional\\MissileTrainer.lua' )
__Moose.Include( 'Functional\\ATC_Ground.lua' )
__Moose.Include( 'Functional\\Detection.lua' )
__Moose.Include( 'Functional\\DetectionZones.lua' )
__Moose.Include( 'Functional\\Designate.lua' )
__Moose.Include( 'Functional\\RAT.lua' )
__Moose.Include( 'Functional\\Range.lua' )
__Moose.Include( 'Functional\\ZoneGoal.lua' )
__Moose.Include( 'Functional\\ZoneGoalCoalition.lua' )
__Moose.Include( 'Functional\\ZoneCaptureCoalition.lua' )
__Moose.Include( 'Functional\\Artillery.lua' )
__Moose.Include( 'Functional\\Suppression.lua' )
__Moose.Include( 'Functional\\PseudoATC.lua' )
__Moose.Include( 'Functional\\Warehouse.lua' )
__Moose.Include( 'Functional\\Fox.lua' )
__Moose.Include( 'Functional\\Mantis.lua' )
__Moose.Include( 'Functional\\Shorad.lua' )
__Moose.Include( 'Functional\\Autolase.lua' )
__Moose.Include( 'Functional\\AICSAR.lua' )
__Moose.Include( 'Ops\\Airboss.lua' )
__Moose.Include( 'Ops\\RecoveryTanker.lua' )
__Moose.Include( 'Ops\\RescueHelo.lua' )
__Moose.Include( 'Ops\\ATIS.lua' )
__Moose.Include( 'Ops\\Auftrag.lua' )
__Moose.Include( 'Ops\\Target.lua' )
__Moose.Include( 'Ops\\OpsGroup.lua' )
__Moose.Include( 'Ops\\FlightGroup.lua' )
__Moose.Include( 'Ops\\NavyGroup.lua' )
__Moose.Include( 'Ops\\ArmyGroup.lua' )
__Moose.Include( 'Ops\\Cohort.lua' )
__Moose.Include( 'Ops\\Squadron.lua' )
__Moose.Include( 'Ops\\Platoon.lua' )
__Moose.Include( 'Ops\\Legion.lua' )
__Moose.Include( 'Ops\\AirWing.lua' )
__Moose.Include( 'Ops\\Brigade.lua' )
__Moose.Include( 'Ops\\Intelligence.lua' )
__Moose.Include( 'Ops\\Commander.lua' )
__Moose.Include( 'Ops\\OpsTransport.lua' )
__Moose.Include( 'Ops\\CSAR.lua' )
__Moose.Include( 'Ops\\CTLD.lua' )
__Moose.Include( 'Ops\\OpsZone.lua' )
__Moose.Include( 'Ops\\Chief.lua' )
__Moose.Include( 'Ops\\Flotilla.lua' )
__Moose.Include( 'Ops\\Fleet.lua' )
__Moose.Include( 'Ops\\Awacs.lua' )
__Moose.Include( 'Ops\\PlayerTask.lua' )
__Moose.Include( 'Ops\\Operation.lua' )
__Moose.Include( 'Ops\\FlightControl.lua' )
__Moose.Include( 'AI\\AI_Balancer.lua' )
__Moose.Include( 'AI\\AI_Air.lua' )
__Moose.Include( 'AI\\AI_Air_Patrol.lua' )
__Moose.Include( 'AI\\AI_Air_Engage.lua' )
__Moose.Include( 'AI\\AI_A2A_Patrol.lua' )
__Moose.Include( 'AI\\AI_A2A_Cap.lua' )
__Moose.Include( 'AI\\AI_A2A_Gci.lua' )
__Moose.Include( 'AI\\AI_A2A_Dispatcher.lua' )
__Moose.Include( 'AI\\AI_A2G_BAI.lua' )
__Moose.Include( 'AI\\AI_A2G_CAS.lua' )
__Moose.Include( 'AI\\AI_A2G_SEAD.lua' )
__Moose.Include( 'AI\\AI_A2G_Dispatcher.lua' )
__Moose.Include( 'AI\\AI_Patrol.lua' )
__Moose.Include( 'AI\\AI_Cap.lua' )
__Moose.Include( 'AI\\AI_Cas.lua' )
__Moose.Include( 'AI\\AI_Bai.lua' )
__Moose.Include( 'AI\\AI_Formation.lua' )
__Moose.Include( 'AI\\AI_Escort.lua' )
__Moose.Include( 'AI\\AI_Escort_Request.lua' )
__Moose.Include( 'AI\\AI_Escort_Dispatcher.lua' )
__Moose.Include( 'AI\\AI_Escort_Dispatcher_Request.lua' )
__Moose.Include( 'AI\\AI_Cargo.lua' )
__Moose.Include( 'AI\\AI_Cargo_APC.lua' )
__Moose.Include( 'AI\\AI_Cargo_Helicopter.lua' )
__Moose.Include( 'AI\\AI_Cargo_Airplane.lua' )
__Moose.Include( 'AI\\AI_Cargo_Ship.lua' )
__Moose.Include( 'AI\\AI_Cargo_Dispatcher.lua' )
__Moose.Include( 'AI\\AI_Cargo_Dispatcher_APC.lua' )
__Moose.Include( 'AI\\AI_Cargo_Dispatcher_Helicopter.lua' )
__Moose.Include( 'AI\\AI_Cargo_Dispatcher_Airplane.lua' )
__Moose.Include( 'AI\\AI_Cargo_Dispatcher_Ship.lua' )
__Moose.Include( 'Actions\\Act_Assign.lua' )
__Moose.Include( 'Actions\\Act_Route.lua' )
__Moose.Include( 'Actions\\Act_Account.lua' )
__Moose.Include( 'Actions\\Act_Assist.lua' )
__Moose.Include( 'Sound\\UserSound.lua' )
__Moose.Include( 'Sound\\SoundOutput.lua' )
__Moose.Include( 'Sound\\Radio.lua' )
__Moose.Include( 'Sound\\RadioQueue.lua' )
__Moose.Include( 'Sound\\RadioSpeech.lua' )
__Moose.Include( 'Sound\\SRS.lua' )
__Moose.Include( 'Tasking\\CommandCenter.lua' )
__Moose.Include( 'Tasking\\Mission.lua' )
__Moose.Include( 'Tasking\\Task.lua' )
__Moose.Include( 'Tasking\\TaskInfo.lua' )
__Moose.Include( 'Tasking\\Task_Manager.lua' )
__Moose.Include( 'Tasking\\DetectionManager.lua' )
__Moose.Include( 'Tasking\\Task_A2G_Dispatcher.lua' )
__Moose.Include( 'Tasking\\Task_A2G.lua' )
__Moose.Include( 'Tasking\\Task_A2A_Dispatcher.lua' )
__Moose.Include( 'Tasking\\Task_A2A.lua' )
__Moose.Include( 'Tasking\\Task_Cargo.lua' )
__Moose.Include( 'Tasking\\Task_Cargo_Transport.lua' )
__Moose.Include( 'Tasking\\Task_Cargo_CSAR.lua' )
__Moose.Include( 'Tasking\\Task_Cargo_Dispatcher.lua' )
__Moose.Include( 'Tasking\\Task_Capture_Zone.lua' )
__Moose.Include( 'Tasking\\Task_Capture_Dispatcher.lua' )
__Moose.Include( 'Globals.lua' )

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

Some files were not shown because too many files have changed in this diff Show More