Military Won't Patrol (Release 566)


Military hearthlings (footman, knight, archer, cleric) won’t patrol. They just go idle or do hauling as if their job is disabled (when their job isn’t disabled).

Steps to reproduce:

  1. Update from previous development release (develop-3023?) to Release 556
  2. Load an older save
  3. Make sure your military party isn’t set to "defend’ or something, and isn’t attacking anything

Expected Results:

They patrol, like they did in previous development release (develop-3023?) when they aren’t doing anything.

Actual Results:

They go idle and/or do hauling, and nothing seems to make them want to patrol. Things I tried include:

  • demoting to worker and promoting them back
  • removing everyone form the party and adding them back to the party
  • making them attack or defend something, then cancelling the order
  • disabling their job in the “citizens” list and then enabling it again
  • selecting one and using the “reset” command in the game’s console
  • using the “reset”, “ai_reconsider” and “fixup_components” commands from “debugtools” on them


I’m not sure I actually want this bug to be fixed!

With the current behaviour it seems impossible to get them to patrol like they should (which is a minor inconvenience I guess, especially if they get a little XP when patrolling now); but with military helping out with hauling my kingdom is far more efficient (items produced by miners, farmers, trappers, etc are getting put into stockpiles/chests quickly); and (unlike disabling their job in the “citizens” list) they still do the rest of their military work properly (attacking targets without being ordered to, etc).

Version Number and Mods in use:

Release 566, better stockpiles (but tested without better stockpiles too)

I had that happen initially, but I thought it was due to loading up with them in a defend flag. I canceled the flag is when they went idle for a good bit, but then enemy came and that is when they went to their patrol after a bit of idle after battle.

Might be just the script or something taking too long to get to them. A delay of sorts. Don’t know. Mine acted like a delayed reaction to patrol. I didn’t have anything to haul for a time…

yes I enjoy the fact they help out hauling; which has been in for most of the A17 builds. That way they are not just patrolling all the time and actually helping out with hauling; even sometimes picking up loot after kills.

I did notice a couple oddities though… Mainly that my military had to wait for thieves to come, and well by the time they got there another mob group spawned. That is not the odd part. within 5secs another mob group spawned from the same spot. Or well one camp; which was the first, and immediately a band of kobolds n wolves a tiny bit aways. Then the bandits arrived in the middle of the onslaught from their long journey.

Didn’t know kobold camps immediately as soon they spawn will spawn a kobold raiding party, if that is what actually happened. I know they spawn them, but not experienced them sending one right away like that… I am in normal though.

Suffice to say I don’t really see many patrol problems, it is just they switch between that and hauling… Which I guess is fine. Yes it is a early A17 save, one I have been using almost since beginning. So not quite as easy to produce, but I can see it happening on occasion due to the changes that were made.

Hi @Brendan
Can you upload your save where the hearthlings aren’t patrolling so I can take a look?

Hi @yshan

I compressed (with Windows built in zip) and tried to upload, but the forums didn’t like it. The problem is that the file is 16.2 MiB (“Sorry, the file you are trying to upload is too big (maximum size is 10000KB).”).

I’ll try to get the file size down (by selling things from inventory) and try again soon.

Hi @Brendan
If you have a gmail account, you can also upload the file to Google Drive and then share the link with me.

I’ve had military units stop patrolling quite often, but any individuals restarting to patrol has been rare if ever for me.

Edit - of course, an hour after posting this my r566 squad of 3 hauling footmen decided to start patrolling again ><. Still not my typical case - dunno if it’s a r566 improvement or just chance.

Broadly, I seem to encounter it from three basic courses:

  1. units that have been military for a long time eventually succumb,
  2. recent recruits that joined mid-fight while they were previously actively doing something else (e.g. in the middle of building a wall, they’re promoted into a footman in a squad that has an active task) are likely to haul rather than patrol after the combat is over, and
  3. [weakest case] military units that have used a Defend flag seem to start behaving oddly more often, and this is one way that can manifest. I’ve avoided Defend flags for a long time now, though, so I haven’t reaffirmed this suspicion at all recently.

But those are trends, not concretes. I haven’t figured out anything that guarentees the problem, and since it mostly happens later game for me, there’s usually been some AI error that’s fired previously that could be the real cause. (have some non-patrolling units on my current r566 Day4 game, but there was a big 5-part error with two military units earlier (that I forgot to grab the log for >< ), so it’s far from a clean case. Most of my older examples had ample cleric ‘start_thinking from non-stopped state “ready”’, etc).

The old A16 save, where I have a ~10 hearthling military that’s all doing hauling, is 11megs zipped (8 megs rar’d). Selling items does seem to shrink it - though then the military goes from ‘restocking’ to standing idle after selling off hundreds of surplus :wink: Would that old save, or the current post-error r566 save be useful, or too tainted (from earlier errors) to be illuminating?

I would love to see that save please!
Thank you

Use 7zip to pack the save files. I did that too and the file gets downsized to under 4mb that way and this you can upload on the forum. ^^

Hi @yshan

Heh… :blush:

So, I tried selling most things (leaving enough food, etc so they don’t starve) to get the file size down, and compressed it again. 11 MiB. D’oh.

Then I butchered my poyo and sheep, got rid of pastures, trapper areas and half the farms; and gave them a little while to collect more stuff, and sold almost everything. This caused the military to start patrolling. D’oh.

Looks like the game was just struggling with my little temporary base (I haven’t even started building anything yet).

I was lazy earlier and didn’t provide system information (oops). I’m running the game on a computer with a 3.4 GHz Core i7 4770 and 32 GiB of RAM (and Windows 8.1).

I’ve uploaded the original (16.2 MiB) file to Google Drive now. Link is: - Google Drive

Thanks :slight_smile:

1 Like

First up, the A16 save, with 11 non-patrolling military. It was my first Stonehearth game, so … big and messy :wink:

For r566, two saves of the same game. First, earliest save I have showing the issue - the fighter there is hauling items. Food at the moment (which I realize a footmen can legitimately haul), but he continues hauling rather than patrolling.
Slightly later in the same save. By now I believe all three military hearthlings are in haul-not-patrol mode (one’s injured, but the other two haul or rest at the fire when not sleeping):

Hopefully something in there proves useful :slight_smile:

1 Like

Like I mentioned, for me I haven’t seen them idle for too long. Granted I haven’t played too much of this version; only last night so far, and will continue later on.

The way mine do idle is like they are thinking of what next to do and then it hits them in what to do. I’ll probably keep an eye on them a bit more, but more focused on getting things built; especially now that the goblin leader decided to up and leave. sheep included, which was still a bit of a distraction for my cleric up to the point it disappeared along with the camp. Glad it did, and will enjoy the new sheep to play around with once they come back. :stuck_out_tongue:

That was one thing that stopped me from building for a bit… all because of a sheep enticing my healer to target it. So I may see if happens to me, which I doubt, as it is not something I often notice. I notice more on the building aspect then combat, unless it distracts me enough to get me away from my building things. That follow my commands, that is enough for me. :smiley:

This was about two days ingame time - I noticed them hauling on Day 4 (could’ve been earlier), and noticed the patrol late in day 6 (I had the r566 excessive-spawns bug, so there were several combats inbetween); they resumed patrolling shortly after the last one came off ‘needs medical attention’ bedrest, which makes me curious if it’s related. My older examples (especially that A16 one, as I believe my longest-running game) have had hauling military for much longer, with no signs of abating.

The military haulers don’t behave particularly strangely for me, they just act akin to normal hauling-only workers (I don’t think I’ve seen them build? Definitely not mine or fell trees), with military tasks superseding any hauling job. In my experience, if they’re hitching and pausing between tasks, its because the rest of the haulers are doing that too, not something unique to the military haulers.

One perk is that if they’re ‘resting at the campfire’, you can give them a brief military order (e.g. move right next to where they’re sitting) and afterward they’ll likely pick a new hauling job rather than return to resting. Can’t do that with normal workers :stuck_out_tongue:

You get lots of military units bringing goods with them into combat, though. They’ll drop it on an Attack order, but usually not a Move or Defend iirc (until they see an enemy and attack autonomously), so sometimes you wind up with a big pile of your own goods dropped in the enemy camp - kind of the opposite of what you’re trying to do :stuck_out_tongue:

Once most of a mature military is hauling, it adds an extra wrinkle to training new recruits - your newbies will start out being the only units patrolling, and thus most likely to run into hostile first. So you start hoping they get afflicted quickly, so they’re no more likely than anything else to run into the hostiles, giving them a better chance of staying out of trouble until the real military shows up to tank for them ><

1 Like

yeah I just played a moment ago with an unsuccessful house. All I noticed was normal behavior of the military.

I did have case of excessive spawn though. goblin camps spawning when I am at peace. only 2 camps. Then when I was gifted on his leave, I got attacked by goblins and a Ogre force with archers. Lost the very person I gained the day before. ><

I had many case of multi-spawn at night time for some reason. On normal of all things. Don’t mind the threat, but multi spawn bug is a bit much than should be.

The 2 camps did disappear when leader left. It was a new one that spawned to attack and that ogre force. That was near the end of my session though.

During it was maybe a couple times I would have 2 spawn at same time. Or maybe one other time. Unsure as I had to fend off quite a bit even before that.

That is over the course of a week roughly. The house stopped after day 4-5. Oh well. It is nice seeing progress at least. :smiley:

Here is my save. Started a new game on r566. Children of Rayya, forest, 1 footman. Difficulty: medium.
Started slacking (digging, hauling) immediately after repelling 4th or 5th invasion (small stone golems). Sending him to attack flag makes him get his sword. As soon as he reaches the flag he begins idling again. (5.0 MB)
Mods: HOMF, Endpieces, Locks of many hair, my own Lodewall Lights & Lodewall Boxes