[QoL] Squads: Group Movement + RTS Style Control Groups

L. Vern

Warlord
Joined
Sep 5, 2022
Messages
106
Location
Ontario, Canada
Download Here

What is Squads?
At it's core, is a modmod for selecting and moving groups of units. It aims to solve the problem of moving groups of units from one place to another without getting their move orders cancelled from other units getting in the way. Additionally, RTS style elements such as box select and numeric hotkeys (ctrl+(num) to manage, double tap (num) to select and move) are implemented.

Please see the video below for a quick demonstration

Additionally, this modmod provides an interface based on military overview that allows one to keep track of, name, manage, and move groups of units:
CivilizationV_DX11_eZ1oUZfBqR.png


Instructions
Interacting with Squads is done largely through two modes: squad management mode, and squad movement mode. Both modes can be exited using the esc key.

Squad management mode can be accessed by pressing "Manage Squad" with the squad you want to manage selected on the left side of the UI, or pressing ctrl+(num). In this mode, one can right click and drag to box select (workers are excluded in this mode to make selecting your army easier), or left click individual hexes.
When in this mode, units in the same squad will be highlighted white, while units in other squads will be highlighted orange. Left clicking a unit will assign it to the active squad, or remove it if it is in the active squad.

Squad movement mode can be accessed by pressing "Move Squad" with the squad you want to manage selected on the left side of the UI, or double tapping the number corresponding to the squad you want to move. A 2 ring hex shadow will be present at the cursor to indicate movement mode, and a right click will route all units in the current squad to this area. Units will alert on arrival, and all units in the squad will be woken once all units arrive at the destination area.

The "Change Home Base" and "Recall Squad" buttons set and move the squad to a home base tile respectively.

FAQ

What version of VP does this require?
3.3+

Is it savegame compatible?
Yep, you can add it to and start using it in a game in progress

Is this compatible with Bal's linked units mod/is there a way to link great generals so they don't move by themselves?
No, but soon™

Can I use this in CBP without VP/non EUI?
No, but soon™

Does it work with quick movement/normal movement
It works the same regardless of whether you use quick movement or movement animations

Is it compatible with X mod?

If it doesn't affect the movement logic of units or assign hotkeys to a number then it should, with the exception of mods that replace
  • InGame.lua
  • WorldView.lua
and have not been updated to be based on CBP V3.2+ of these files
Known Issues
  • In "wait for squad arrival" movement end mode, in rare circumstances, squad movement does not end correctly and repeatedly wakes up the group on turn end (this can be worked around by moving the offending units again)
These are known but will probably not be fixed
  • Pathfinding behaves suboptimally for large groups of units (more than 2 rings)
  • Box select doesn't work around the map wrap
Unknown Issues/Feature Requests
You can post them on this thread or reach me at the VP discord. Additionally, I have a list of enhancements and features planned that I keep up to date on the VP discord.

Acknowledgements

Special thanks to @balparmak for the original idea of group movement in civ, and WHoward for his excellent UI tutorials without which I would taken a much longer time to figure stuff out

Changelog

v0.2 (requires VP 3.3+)
  • Can now remove a unit from the squads UI by right clicking the unit entry
  • Added reset squad button to empty current squad
  • Added new configuration options
    • Toggle squad highlight on unit selection
    • Toggle squad number display under unit flag
    • Select squad movement end behavior between "alert on arrival", "wake on each unit arrive", and "wake on squad arrival"(original behavior)
v0.3
  • End mode options are now correctly saved and persist between saves
  • 0 hotkey now correctly maps to squad #10
  • Fix a bug where EUI unit flags could incorrectly show squad numbers for units created shortly after a unit in a squad dies (VP 4.6+)
  • Fix a bug where issuing squad move orders to a unit that just had a squad movement mission interrupted (either by user or by seeing enemy unit) would result in them continuing on their previous path (VP 4.6+)
 
Last edited:
Looks amazing, thank you L. Vern! I'll be sure to give it a try during my next game :)
 
is it possible to add mass fortify or sleep/alert command for all selected units? or make all units fortify if possible, or sleep/alert when destination is reached. it is kind of annoying to have all units ask for orders upon arrival when the only command i give is to move from A to B.
 
is it possible to add mass fortify or sleep/alert command for all selected units? or make all units fortify if possible, or sleep/alert when destination is reached. it is kind of annoying to have all units ask for orders upon arrival when the only command i give is to move from A to B.
At the moment the intended behavior for group movement is units will alert when destination is reached, then all wake once every unit arrives.
In the near future movement end behavior will be configurable between:
  • Alert/Fortify on arrival
  • Alert/Fortify on arrival, then wake when all units arrive (current)
  • Ask for orders on arrival
I've noticed as well that many times you just want to move a blob and not want to immediately position them manually on arrival, I think in the next version just alert on arrival will be the default
 
This mod is excellent, thank you. It makes late game at least 30% better. I don't have to stop playing for the day after a war bc the idea of microing all my units to a new front is too much.

Would it be possible to get an option to enable/disable the numbers/light up hex on units?
 
This mod is excellent, thank you. It makes late game at least 30% better. I don't have to stop playing for the day after a war bc the idea of microing all my units to a new front is too much.

Would it be possible to get an option to enable/disable the numbers/light up hex on units?
Yep, both of those are high on my priority list of squads improvements, are partially implemented and will be available soon

Glad to hear you're finding it useful!
 
Yes!
@L. Vern would you be interested in integrating it into VP if it passes the congress?
yep, it's on my todo list, just gotta get it working for non VP and non EUI (and needs some more polish, will have some configuration options for the modmod soon). Don't think it needs a congress vote, would package it as its own separate mod in the installer like promotion tree
 
This is amazing! This might be the most important QoL change regarding movement in years!

Is it possible this would work if one has EUI but no VP DLL? Does it depend on the VP DLL or would something like WHowards DLL also work instead?
 
This is amazing! This might be the most important QoL change regarding movement in years!

Is it possible this would work if one has EUI but no VP DLL? Does it depend on the VP DLL or would something like WHowards DLL also work instead?
It depends on the CP DLL sadly. Vern has put in a lot of work behind the DLL around unit movement logic.
 
This is incredible for late game wars with tons of units! Really appreciate the work done on this mod, thanks L. Vern!
 
A great mod. However, I stumbled upon a bug after I updated to VP 3.7.11. Where a lot featuress cease to function, such as the moving squad and the home base. When I try to move a squad using the Move Squad function, it just shows a red movement circle on the hex.
 
A great mod. However, I stumbled upon a bug after I updated to VP 3.7.11. Where a lot featuress cease to function, such as the moving squad and the home base. When I try to move a squad using the Move Squad function, it just shows a red movement circle on the hex.
Interesting, I haven't seen anything like this before - I tried with a fresh install of 3.7.11 and 3.7.12 and squads v2 and works correctly for me. Are there any other mods you are using in addition to VP and Squads?
 
Sometimes when i assign my units to squads, foreign units or barbarians also get assigned a number without being in a squad. This sometimes also happens to my own units that haven‘t been assigned to a squad. Has anyone else encountered this?
 
Sometimes when i assign my units to squads, foreign units or barbarians also get assigned a number without being in a squad. This sometimes also happens to my own units that haven‘t been assigned to a squad. Has anyone else encountered this?
this is in the known issues section, have looked into it extensively and still no idea what could be causing it lol. Will have to try debugging it again at some point
 
Top Bottom