City defenses after gunpowder

LateGameWarMong

Warlord
Joined
Jul 28, 2008
Messages
115
I'd like to add a "trenches" building that improves city defense (specifically against gunpowder units if possible) that is effective against "gunpowder based units" unlike walls and castles

Is there any way to do this with just .xml editing?
 
Unfortunately, you cannot do that with just XML.
Each unit info has a "bIgnoreBuildingDefense" which states whether it ignores the walls' defense bonus. The thing is there's only one type of bonus, so you cannot have the same unit ignore defense bonus of one building but be affected by the defense bonus of another's.

This requires some DLL changes (unless someone can think of a Python work around). Maybe someone already created a mod for that, I don't know.
 
Yea....
But I'd really like a gunpowder specific defense.

Right now the closest thing to WWI style ridiculously effective defenses are machineguns (before tanks, aircraft, and mechanized infantry)

IRL trenches are great against advancing infantry and artillery, but not; tanks, helicopters, and aircraft.


I guess what would be really cool is the ability to have your workers build "trench lines" that act like rivers, attacking across them incurs a 25% penalty (ideally this wouldn't apply when you are attacking within your cultural boundaries...)

Maybe with python there could be a "moat" building, once built, a river rings your city.

Amphibious is not *that* common, if it came with a -2 health to offset the freshwater boost (assuming your city didn't already have fresh water).

But then there is the issue of using it to allow hydro power plants, and getting bonus production with levees/dikes
 
Top Bottom