I need to find the distance between units not using the thread. This is for a situation where I have a commander with a command radius of 4. The formation is highlighted so I need to determine which counters are within the command radius and put an out of control marker on the units that are not in command radius.
Assuming you’re using a hex or square grid, you could try the following:
Send a Global Key Command (GKC) targeting all units that need to worry about being in control, marking them as Out of Control (OOC).
Send another GKC targeting all units which provide control; this will trigger a 3rd GKC, targeting all units that worry about Control, but limited to Range 4 (see the Restrict Range, Fixed Range, and Range parameters of GKC), marking them as “in control”.
The 1st 2 GKCs should be part of the same Trigger Action; the 3rd should be separate (exception: see next paragraph).
Note that you need all 3 GKCs because there is no way to target only pieces that are not within a given range. If you can only ever have 1 commander active, you can skip the 2nd GKC and go straight to the 3rd (making it part of the same Trigger Action, instead of separate).
This is all assuming you’re triggering this control check from the “commander” piece. The 1st 2 GKCs (with their Trigger Action) could theoretically live anywhere, but the 3rd GKC must be on the/every “commander” piece to work properly.
(If you’re not using a grid, you can still use this method, but the ranges will be in raw pixels rather than squares or hexes.)
Edit: If there are multiple “command” pieces that can daisy-chain to extend your control, this may not work properly. In that case, you will actually need each “command” piece to re-trigger the 3rd GKC itself when it switches from OOC to “in control”. Do-able, but more complicated.
Thank you both. I’m going to experiment with this this weekend when I have some time. It looks like this is pretty much the answer I need almost exactly so I really appreciate that. Would like to mark them both a solutions
I have used the attachment and range function, but as I understood it, you need to make the attachment first, so you would need to make attachments to all units, get their range, and then do the job on those that are within 4 hexes.
I think jrwatts’ solution seems to be more effective in this case.