diff --git a/Moose_TADC_CargoDispatcher.lua b/Moose_TADC_CargoDispatcher.lua index 86814a8..9c353c3 100644 --- a/Moose_TADC_CargoDispatcher.lua +++ b/Moose_TADC_CargoDispatcher.lua @@ -15,14 +15,11 @@ CONFIGURATION: REQUIRES: - MOOSE framework (for SPAWN, AIRBASE, etc.) - - Optional: MIST for deep copy of templates ═══════════════════════════════════════════════════════════════════════════════ ]] ---@diagnostic disable: undefined-global, lowercase-global -- MOOSE framework globals are defined at runtime by DCS World - - -- Single-run guard to prevent duplicate dispatcher loops if script is reloaded if _G.__TDAC_DISPATCHER_RUNNING then env.info("[TDAC] CargoDispatcher already running; aborting duplicate load") @@ -30,6 +27,24 @@ if _G.__TDAC_DISPATCHER_RUNNING then end _G.__TDAC_DISPATCHER_RUNNING = true +--[[ + CARGO SUPPLY CONFIGURATION + -------------------------------------------------------------------------- + Set supply airfields, cargo template names, and resupply thresholds for each coalition. +]] +local CARGO_SUPPLY_CONFIG = { + red = { + supplyAirfields = { "Sochi-Adler", "Nalchik", "Beslan", "Maykop-Khanskaya" }, -- replace with your RED supply airbase names + cargoTemplate = "CARGO_RED_AN26", -- replace with your RED cargo aircraft template name + threshold = 0.90 -- ratio below which to trigger resupply (testing) + }, + blue = { + supplyAirfields = { "Batumi", "Kobuleti", "Senaki-Kolkhi", "Kutaisi", "Soganlug" }, -- replace with your BLUE supply airbase names + cargoTemplate = "CARGO_BLUE_C130", -- replace with your BLUE cargo aircraft template name + threshold = 0.90 -- ratio below which to trigger resupply (testing) + } +} + --[[ GLOBAL STATE AND CONFIGURATION -------------------------------------------------------------------------- @@ -51,23 +66,7 @@ if DISPATCHER_CONFIG.ALLOW_FALLBACK_TO_INMEM_TEMPLATE == nil then DISPATCHER_CONFIG.ALLOW_FALLBACK_TO_INMEM_TEMPLATE = false end ---[[ - CARGO SUPPLY CONFIGURATION - -------------------------------------------------------------------------- - Set supply airfields, cargo template names, and resupply thresholds for each coalition. -]] -local CARGO_SUPPLY_CONFIG = { - red = { - supplyAirfields = { "Sochi-Adler", "Nalchik", "Beslan", "Maykop-Khanskaya" }, -- replace with your RED supply airbase names - cargoTemplate = "CARGO_RED_AN26", -- replace with your RED cargo aircraft template name - threshold = 0.90 -- ratio below which to trigger resupply (testing) - }, - blue = { - supplyAirfields = { "Batumi", "Kobuleti", "Senaki-Kolkhi", "Kutaisi", "Soganlug" }, -- replace with your BLUE supply airbase names - cargoTemplate = "CARGO_BLUE_C130", -- replace with your BLUE cargo aircraft template name - threshold = 0.90 -- ratio below which to trigger resupply (testing) - } -} + diff --git a/Moose_TADC_Load2nd.lua b/Moose_TADC_Load2nd.lua index 05fe9a1..bb86399 100644 --- a/Moose_TADC_Load2nd.lua +++ b/Moose_TADC_Load2nd.lua @@ -1895,9 +1895,9 @@ local function launchInterceptor(threatGroup, coalitionSide) -- Apply cooldown immediately when squadron launches local currentTime = timer.getTime() + local cooldownMinutes = 0 if coalitionSettings and coalitionSettings.squadronCooldown then squadronCooldowns[coalitionKey][squadron.templateName] = currentTime + coalitionSettings.squadronCooldown - local cooldownMinutes = coalitionSettings.squadronCooldown / 60 cooldownMinutes = coalitionSettings.squadronCooldown / 60 end log(coalitionName .. " Squadron " .. squadron.displayName .. " LAUNCHED! Applying " .. cooldownMinutes .. " minute cooldown") diff --git a/Moose_TADC_System1.0.0.zip b/Moose_TADC_System1.0.0.zip new file mode 100644 index 0000000..2dd59f4 Binary files /dev/null and b/Moose_TADC_System1.0.0.zip differ diff --git a/TADC_Example.miz b/TADC_Example.miz index 4ffca9a..3158dbd 100644 Binary files a/TADC_Example.miz and b/TADC_Example.miz differ