mirror of
https://github.com/akaAgar/the-universal-mission-for-dcs-world.git
synced 2026-08-25 12:28:50 +00:00
Added regular automatic contact report from wingmen
This commit is contained in:
@@ -6,10 +6,12 @@
|
|||||||
TUM.wingmen = {}
|
TUM.wingmen = {}
|
||||||
|
|
||||||
do
|
do
|
||||||
|
local CONTACT_REPORT_INTERVAL = 8 -- Called AT MOST every 15 seconds, so 6 means "AT MOST every two minutes"
|
||||||
local DEFAULT_PAYLOAD = "attack" -- Default payload
|
local DEFAULT_PAYLOAD = "attack" -- Default payload
|
||||||
|
|
||||||
local knownGroupsID = {}
|
local knownGroupsID = {}
|
||||||
local newGroupsID = {}
|
local newGroupsID = {}
|
||||||
|
local ticksLeftBeforeContactReport = CONTACT_REPORT_INTERVAL
|
||||||
local wingmenGroupID = nil
|
local wingmenGroupID = nil
|
||||||
local wingmenUnitID = {}
|
local wingmenUnitID = {}
|
||||||
|
|
||||||
@@ -92,6 +94,7 @@ do
|
|||||||
-- Reinitialize list of known contacts and contact report interval
|
-- Reinitialize list of known contacts and contact report interval
|
||||||
knownGroupsID = {}
|
knownGroupsID = {}
|
||||||
newGroupsID = {}
|
newGroupsID = {}
|
||||||
|
ticksLeftBeforeContactReport = CONTACT_REPORT_INTERVAL
|
||||||
|
|
||||||
TUM.log("Spawned AI wingmen")
|
TUM.log("Spawned AI wingmen")
|
||||||
|
|
||||||
@@ -269,7 +272,10 @@ do
|
|||||||
return true
|
return true
|
||||||
end
|
end
|
||||||
|
|
||||||
return false
|
ticksLeftBeforeContactReport = ticksLeftBeforeContactReport - 1
|
||||||
|
if ticksLeftBeforeContactReport > 0 then return false end
|
||||||
|
|
||||||
|
return TUM.wingmenTasking.commandReportContacts(nil, true, false)
|
||||||
end
|
end
|
||||||
|
|
||||||
-------------------------------------
|
-------------------------------------
|
||||||
|
|||||||
Reference in New Issue
Block a user