I have added a guard action to fortifiable units.
I am not good with art, so I had to use the fortify icon.
This will allow regular fortified units to stay fortified, and guard units will fortify until awoken by enemy unit.
I currently do not know how to save mod data across saves, so for now when you load a game, any unit you want on guard will need to be reissued the command, sorry for the inconvenience. If anyone knows how to save info, I'll be glad to add.
This mod uses the unitpanel.lua as that was the only way was able to attach a new operation. If any major or highly used mod also uses this let me know and i will try to make a compatible file.
I marked this as experimental because I haven't been able to test alot, and not sure if any more bugs to fix. If any are found, please let me know.