Villagers switching tasks

This one is a more simple functionality of the game but that I consider worth mentioning as it took me a while to figure out and it will be useful when we talk about the Flemish revolution.

As we can see by filtering only civilian units, Class 4, there is a different unit for every variation of the villager. If we check the “Tasks” section, at the bottom of the units tab, we can see that each variation of the villager has a task related to a resource. For the most part they use action “Gather/Rebuild” on farms, mines, bushes, etc. Having different versions for each villager allows civilization bonuses like the celt or the slav to affect only a speciffic version of the villager.

Now, how does the game change a villager into a lumberjack when you click on a tree? The secret is in the “Task Swap Group” field up in the Attributes section. All Male villagers have this field set to one and all females have it on 2. When you click with the villager on a tree, the game looks for another unit on the same Task Swap Group that has a task involving trees. When it finds it, it changes the villager into a lumberjack.

Wololo Kingdoms DE actually uses a third task swap group, number 3, for the villagers after the Flemish revolution. We’ll see about it later on.