In Vanilla Rimworld, there's very little use for breaching weapons, as even bare fists are enough to drill through a mountain, let alone walls and doors. This mod fixes that, by nerfing every damage type against buildings, except for the ones used by breaching weapons. I recommend carrying a breach axe from now on!
This is possible by using tags from the game itself: buildingDamageFactorPassable and buildingDamageFactorImpassable. Impassable buildings are basically walls, and passable is everything else (eg: doors)
List of changes:
"Sharp" damage: Cut, Stab, Poke, Scratch and Bite
"Blunt" damage: Blunt, Crush
"Ranged" damage: RangedStab, Bullet, Arrow
"Explosion*" damage: Bomb
*The bomb damage type is special, as it already has a default damage bonus against buildings, namely 4x against Impassable, and 2x against Passable. Walls are defined to receive 2x damage against Bomb and Thump, so the calculated value for a frag grenade damage is 50 x 4 x 2 = 400, enough to completely destroy a slate wall in one shot!
By changing the bonus to 0.8, grenades should now deal 80 damage to walls, and 100 to doors. Antigrain warheads deal, on point-blank, 418 damage to walls, this may be changed.
Additionally, weapons shaped like maces, clubs or hammers (precisely, weapons with a 'head' part that deals 'Blunt' damage) will be patched to deal a new damage type called "BluntCrushing", it works like vanilla Blunt.
"Hammer" damage: BluntCrushing
For reference, here is the damage types for breaching weapons, untouched by this mod:
"Thump Cannon Bullet" damage: Thump
"Breaching Axe" damage: Demolish
The Breaching Axe def uses a third tag, buildingDamageFactor, that seems to be multiplied before buildingDamageFactorImpassable, so it deals a lot of damage to buildings, but only 10% of that to pawns.
Frequently Asked Questions:
What about modded walls?
This mod doesn't interfere with walls, it only makes it so every type of damage in the game, except for the special ones used by the Breaching Axe and Thump Cannon, deal less damage to buildings.
What about modded weapons?
Most modded weapons use the same damage types as vanilla, so there's no issue. If a mod has custom damage types, you can tell me in the comments.
Is it compatible with CE?
Combat Extended already has a patch that makes bullets and arrows deal very little damage to all buildings. I can see if I can make it compatible, but they are having some issues that need fixing right now.
Required: XML Extensions