The best kittens, technology, and video games blog in the world.

Saturday, May 22, 2010

Empire Total War mods - no walls, libertarians everywhere

The look of nobody home by Tjflex2 from flickr (CC-NC-ND)

Rome Total War was highly moddable. Medieval 2 Total War somewhat less as all data files were in obfuscated packages - but once you unpacked them it was as good as Rome. My M2TW mod is generated by a bunch of simple regexps, with which I can experiment as much as I like, turning features on and off and changing their magnitude in seconds.

I knew Empire Total War won't be as easy, but nothing prepared me for the pain I suffered. But I'll complain as I go.

Libertarians everywhere

First to see how modding works I wrote a very small mod - turning off taxes adds +10 happiness. Not quite literally, as it seems impossible to have anything triggered by zero taxes, so I gave all non-zero taxes extra -10 happiness, and every government type gets extra +10 happiness - net result being what I wanted, except it looks a bit silly in game.

Now why did I do so? The answer is my favourite "less micromanagement". I don't particularly having to babysit conquered provinces, chasing rebels around, and counting how many units I can move and how many I need to leave. This is simply not fun. So I decided that every province has a sizable population of armed libertarians who will gladly shoot every protester for me as long as I set taxes to zero. When taxes are not zero they blog climate change denial or something, I don't care.

This is all a stop-gap measure for the first few turns after conquest - if you ever want to get any taxes out of the province, as you usually do, you'll need to deal with taxpayers' happiness eventually. By the way zero taxes essentially means provinces loses money every turn, as it increases administration cost of every other province in your empire.

Happiness +10 is enough most of the time, but when you conquer someone's capital and have to face -30, on top of all industrialization, religion etc., you might need to deal with rebellions anyway. And as such regions usually bring a lot of money, you probably want to set higher taxes anyway.

If you want to tweak this bonus, use DBEditor for it.

No walls

And now the big mod - removing all walls. I'm not ideologically opposed to settlement fortifications - in fact my M2TW mod makes settlements more difficult to take. However:
  • ETW sieges are broken due to stupid AI and stupid pathfinding
  • Because they're broken, all ETW sieges follow just two boring scripts:

    • either: approach diagonally with infantry from 3 directions, bayonet charge everything;
    • or: approach diagonally with howitzers with carcass shot and a few line infantry units, once you start bombarding them AI will charge you one by one and you win without loses
    everything else fails as your units are too stupid to pathfind in more interesting strategies
  • After 1710 or so nearly every settlement outside Americas has city walls
  • And so after the first few years, 90% of battles is unbelievably boring
Field battles on the other hand are much more interesting. An unfortunate side effect of this mod is that while in vanilla town watch can use settlement fortifications to defend it from small enemy armies reasonably well, now it's completely useless. I can live with that.

Unfortunately, this has second order side effect of forcing you to be more aggressive. If before you'd be quite willing to have your armies further away from the front as town watch could serve as good enough first line of defense, now you need to have your armies closer to the borders, preferably on their side of it.

So how did I write this mod? It was truly painful. First, ETW has building features, and the fact that settlement fortifications building creates walls in the battle is supposedly encoded by such features. I ran into the first problem, as DBEditor is incapable of removing features - only adding or modifying them. To do such thing you need to go to PackFileManager, clone a table, make sure it's named exactly like the original one (so it will be overridden, not merged), and remove rows from that in DBEditor.

Except for some reason PackFileManager incorrectly mixes up slashes and backslashes, so I needed to fix the mod file from a hex editor.

Except it turned out in the end ETW ignores this feature, and simply hard-codes walls. So much for my effort.

It was plan B time. First I needed to remove all walls. And while db files are pain to edit it is nothing compared to the pain of editing startpos.esf which contains campaign information:
  • Start campaign, look at every single settlement on a map and write down which settlement has walls (as there's no search function in EsfEditor)
  • Manually find every such settlement in esf tree, and do all necessary changes (change True to False in one node, delete another node).
This is of course wholly incompatible with any other esf mod, like those which enable you to play minor factions.

After that I needed to make it impossible to build walls. I haven't figured out how to do that (I suspect if I remove walls completely the game will simply crash, and no other building in unbuildable) - so I made it require late technology of mass production, and take 999 turns to build. Sort of good enough.

And all this was possible only after a lot of effort of modding community members who created tools like DBEditor, EsfEditor, PackFileManager, documented what they could etc. This is borderline unmoddable, and I fully expect the next generation of Total War games after Napoleon (which is essentially extra scenario for ETW) to be completely impossible to mod. But hey, maybe they'll sell more DLC this way.

How to install

In case you want to install these mods, you need to:
  • Download starpos.esf and replace one in C:\Program Files (x86)\Steam\steamapps\common\empire total war\data\campaigns\main (or similar), first of course making a backup copy - this will remove starting walls. (small warning - it's a big file and the server I'm hosting it on is pretty slow; other files are tiny)
  • Download mod_no_walls.pack and put it in data directory together with all other packs - this will make walls unbuildable.
  • Optionally download mod_tax_break.pack and put it into data directory - this will give you +10 happiness bonus for no taxes.
  • Download ModManager and unpack it.
  • Start ModManager, select mods you want to use, and click Launch.

5 comments:

Quickshot said...

You'd think they'd be happy with the extra attention the mods generate, but either they just don't think about the modders at all. Or they care more about short term DLC profits I guess...

Quickshot said...

I incidentally noticed that you hadn't mentioned a third strategy for attacking cities, namely trying to climb over a fairly unoccupied part, use that to keep enemy units away and then move the rest of the army in to the internal plaza and start up a mini field battle on the inside. Once off the walls the units behave much more sanely again and there is plenty of room inside for a bit of manoeuvring.

sam said...

cheers for the hard work, is there any way to get the no wall mod pack working without the startpos file as I am using Darthmod and it already has re done startpos files. thanks

taw said...

sam: No such luck, ETW modding is a big pile of fail, and the only way to edit buildings away is by manually editing them out of the map (aka startpos.esf).

sam said...

ah no worries, i bumped up the the build time of all forts to 999 and costs to 999999999 or something stupid like that seems to be working so far but still have to deal with the original forts on the map