Page 1 of 1
Sector Control Comms LUA?
Posted: Mon May 18, 2026 9:42 pm
by GeneralVikus
Hey guys,
Does anyone happen to have an off - the - shelf LUA script for sector control station destruction (i.e. a pulsed event which causes units within a certain radius or RP - area to go out of communication if the sector control station no longer exists?)
I can probably figure it out myself if given enough time, but I'm guessing scenario designers must have made this already several times over, and since I have no knowledge of LUA I'd rather not reinvent the wheel.
Re: Sector Control Comms LUA?
Posted: Mon May 18, 2026 11:54 pm
by Kushan04
I don't know of any scenario that does this specifically.
Down Town, 1967 (Standalone Scenarios) has a script that sets the North Vietnamese IADS to comms out when the sector control station is destroyed. It Could be adapted pretty easily. I'd caution against doing it for aircraft though. The current implementation for comms out behavior can be weird. It's fine for individual aircraft but aircraft in groups will suddenly forget who their wingman are.
Re: Sector Control Comms LUA?
Posted: Tue May 19, 2026 1:01 am
by GeneralVikus
Kushan04 wrote: Mon May 18, 2026 11:54 pm
I don't know of any scenario that does this specifically.
Down Town, 1967 (Standalone Scenarios) has a script that sets the North Vietnamese IADS to comms out when the sector control station is destroyed. It Could be adapted pretty easily. I'd caution against doing it for aircraft though. The current implementation for comms out behavior can be weird. It's fine for individual aircraft but aircraft in groups will suddenly forget who their wingman are.
That's great to know, thanks!
Re: Sector Control Comms LUA?
Posted: Tue May 19, 2026 2:46 pm
by blu3s
This scenario populates various IADS sectors (based on difficulty) with HQs, Comms, SAMs and EW radars.
https://forums.matrixgames.com/viewtopi ... 5#p5164905
Re: Sector Control Comms LUA?
Posted: Tue May 19, 2026 3:31 pm
by thewood1
Never saw that scenario before. Thats very cool. I have built several scenarios testing out comms loss in integrated networks. its 50/50 I get them to function properly.
Re: Sector Control Comms LUA?
Posted: Wed May 20, 2026 10:32 am
by blu3s
Thanks, I've fixed on issue with the scenario setup (seems that some terrain altitudes changed from last year)
The Sector Control is not that hard, you need to create a good data structure and then capture when the units are killed.
For example for each sector you add an HQ unit and a Comms unit. You need to be sure that when those units are killed, then you iterate over the units that belong to the same sector and apply the penalty or leave them out of comms for X mins/hours.
Re: Sector Control Comms LUA?
Posted: Wed May 20, 2026 4:15 pm
by GeneralVikus
blu3s wrote: Wed May 20, 2026 10:32 am
Thanks, I've fixed on issue with the scenario setup (seems that some terrain altitudes changed from last year)
The Sector Control is not that hard, you need to create a good data structure and then capture when the units are killed.
For example for each sector you add an HQ unit and a Comms unit. You need to be sure that when those units are killed, then you iterate over the units that belong to the same sector and apply the penalty or leave them out of comms for X mins/hours.
When you say "units that belong to the same sector," can you explain any more what mechanism you use to determine which units "belong" to which sector? For example, do you mean that the script checks for units which are assigned to an AAW mission associated with that sector? I will take a look at the scenario you provided, but I'm new to LUA so it'd be helpful to have some understanding of what I'm looking at.
Re: Sector Control Comms LUA?
Posted: Fri May 22, 2026 5:32 am
by blu3s
I'll write an example this weekend. Basically you decide the structure and the network, you just need to save that structure in the scenario lua workspace for later.
Re: Sector Control Comms LUA?
Posted: Sat May 23, 2026 2:20 pm
by GeneralVikus
blu3s wrote: Fri May 22, 2026 5:32 am
I'll write an example this weekend. Basically you decide the structure and the network, you just need to save that structure in the scenario lua workspace for later.
Awesome, thanks!
Re: Sector Control Comms LUA?
Posted: Sat May 23, 2026 4:39 pm
by blu3s
Here is the idea, there is not a unique way to implement it but I think the foundamental concept is there.
https://github.com/blu3ser/LuaTutorials/tree/main/IADS