I suspect it has something to do with the 'scout' variable ... first thing id do, for any interested, is find out how 'scout' is set ...
I believe your suspicions are true, by what I've seen here
https://github.com/MeridianOXC/OpenXcom/blob/4a98605e9fcb3f9a9ce8c43737d07e938b09bb00/src/Battlescape/AIModule.cpp#L589It appears that all units are set to scouting initially, but this is changed inmedietly and a unit will be scouting ONLY under any of these conditions:
- Cheat Turn as been reached (comment in the code also mentions low alien morale)
- The node the unit started from has rank 0. Aliens don't seem to like to be on one of these meager nodes and will seek out another node.
- The tile the unit is standing on is on fire (doesn't seem to matter if they can resist fire or not in this case)
All other units will not be scouting. This will be rechecked every time a unit reaches their destination node and will change to scouting, not scouting according to the conditions. There's a different behaviour for scouting while in base defense missions, but that part is not relevant to the issue.
The key difference I can see between scouts and non-scouts is the destination node, scouts can pick from any node on the map that is valid after passing some filters. Non-scouts however limit their choices to nodes directly linked to their current origin node with similar filters. The next difference is that scouts will pick a node randomly from the list of valid destinations while non-scouts will choose the most 'desirable' destination that factors in node's rank and flags (I believe what mapview 2 calls 'patrol priority')
If I follow what might be happening is that the "engineer" rank aliens will NOT pick any of the connected nodes outside the kitchen because:
a) they are starting on a node that is not a rank 0 and none of the other conditions have been met for them to scout, and
b) the ouside nodes have both rank:0 and flag:0 making them undesireable.
It is very likely that they're each picking an engineer node that is occupied by another engineer and if there's enough of them, none will move because the space is always occupied. Do note that while the code does seem to prevent different aliens picking the same destination at the same time with an 'allocated' flag, it doesn't prevent them from occupying the space that another unit is heading for as they move or they happen to spawn there.
I believe a New Battle with debugging options and debug killing enough engineers should comfirm (or disprove) this conclusion.
Note: I'm referencing Meridian's repo but I believe there's minimal differences between OXC and OXCE here.