Are Armored Buildings Possible ?

Started by SpaceDorf, September 28, 2017, 05:01:34 PM

Previous topic - Next topic

SpaceDorf

I was looking around for examples, but I could not find anything.

Is it possible to give armor values to buildings ?
If yes, how ?
Maxim 1   : Pillage, then burn
Maxim 37 : There is no overkill. There is only open fire and reload.
Rule 34 of Rimworld :There is a mod for that.
Avatar Made by Chickenplucker

CannibarRechter

I think: no. At most, you have the structure acquiring addition hit points from the statFactors of the resource it is built with.
CR All Mods and Tools Download Link
CR Total Texture Overhaul : Gives RimWorld a Natural Feel
CR Moddable: make RimWorld more moddable.
CR CompFX: display dynamic effects over RimWorld objects

koni

I thought it is possible. I found following in the def of the vanilla wall:

    <damageMultipliers>
      <li>
        <damageDef>Bomb</damageDef>
        <multiplier>2</multiplier>
      </li>
    </damageMultipliers>

This makes walls take more damage from grenades (somehow 4 times instead of 2?).

CannibarRechter

Are you asking if that type of damage def is generalized? From a quick look at the C#, it appears to be generic to Thing, so I should say so.
CR All Mods and Tools Download Link
CR Total Texture Overhaul : Gives RimWorld a Natural Feel
CR Moddable: make RimWorld more moddable.
CR CompFX: display dynamic effects over RimWorld objects

SpaceDorf

What damage type ?

Blast damage for buildings ?

But I can't give a building a Armor Value ?
How are those defined in Clothes.
Maxim 1   : Pillage, then burn
Maxim 37 : There is no overkill. There is only open fire and reload.
Rule 34 of Rimworld :There is a mod for that.
Avatar Made by Chickenplucker

CannibarRechter

> But I can't give a building a Armor Value ?

You should be able to give buildings a damageMultiplier, as cited.

ThingDef.cs has a declaration for:


public List<DamageMultiplier> damageMultiplers;


That means that every Thing can have the def. Whether or not the code processes it for all things... well, try it and let us know. ;-P
CR All Mods and Tools Download Link
CR Total Texture Overhaul : Gives RimWorld a Natural Feel
CR Moddable: make RimWorld more moddable.
CR CompFX: display dynamic effects over RimWorld objects

SpaceDorf

#6
Now I understand how you meant that.

Okay, all I need is a list of names for the multipliers.
This should be in the XML-Overview Milon published.

====== EDIT ======

After some testing I can confirm that damage multipliers can be used to set the damage received in percent.
This is the list of multipliers :
Arrow, Bomb, Bullet, EMP, Flame, Stab

<damageMultipliers>
     <li>
        <damageDef>Arrow</damageDef>
        <multiplier>0.5</multiplier>
    </li>
</damageMultipliers>
   
Maxim 1   : Pillage, then burn
Maxim 37 : There is no overkill. There is only open fire and reload.
Rule 34 of Rimworld :There is a mod for that.
Avatar Made by Chickenplucker

Albion

Well technically the multiplier should work for all damageDefs with an actual damage value, should it?
Meaning the full list for vanilla damageDefs (not counting mods) should be:
Cut, SurgicalCut, ExecutionCut (last 2 can never happen to a building), Crush, Blunt, Stab, Bullet, Arrow, Scratch, Bite, ToxicBite, Bomb, Flame and Burn.

Not sure but it could probably also work with Stun and EMP.

SpaceDorf

Thats the list taken from the XML Documentation which applies to buildings.

And tested by me ingame.
Maxim 1   : Pillage, then burn
Maxim 37 : There is no overkill. There is only open fire and reload.
Rule 34 of Rimworld :There is a mod for that.
Avatar Made by Chickenplucker