# Armor Up! A mod to make armor more better. New PA Utilities pack!

**URL:** <https://discourse.cataclysmdda.org/t/armor-up-a-mod-to-make-armor-more-better-new-pa-utilities-pack/15449>\
**Category:** The Lab\
**Tags:** mod\
**Created:** [May 8, 2018, 11:26am UTC](https://discourse.cataclysmdda.org/t/armor-up-a-mod-to-make-armor-more-better-new-pa-utilities-pack/15449 "2018-05-08T11:26:31Z")\
**Posts on this page:** 20\
**Page:** 2

<div class="post-metadata">

**Author:** ![Einstein\_Cross](https://sea2.discourse-cdn.com/flex016/user_avatar/discourse.cataclysmdda.org/einstein_cross/32/10564_2.png) [@Einstein\_Cross](https://discourse.cataclysmdda.org/u/Einstein_Cross)\
**Post date:** [August 24, 2018, 2:44pm UTC](https://discourse.cataclysmdda.org/t/armor-up-a-mod-to-make-armor-more-better-new-pa-utilities-pack/15449/21 "2018-08-24T14:44:57Z")

</div>

Thank you for replying so frequently and your willingness to help! I gotta say your contributions to the project are fantastic.

I have (a lot of) questions about the armor mod. Should I duplicate the code of, let’s say the active defense shield bionic, in the armor\_tools file (and is as simple as copy and paste with minor tweaks)? Then call it as a use action in the power armor definition in the armors file? Also one thing i’m really not sure of is how to affect the players base stats by simply powering on the armor. The only way I _can_ think of at the moment is by compiling changes in the character.cpp file. Thank you for the help!

---

<div class="post-metadata">

**Author:** ![mlangsdorf](https://sea2.discourse-cdn.com/flex016/user_avatar/discourse.cataclysmdda.org/mlangsdorf/32/2462_2.png) [@mlangsdorf](https://discourse.cataclysmdda.org/u/mlangsdorf)\
**Post date:** [August 24, 2018, 3:29pm UTC](https://discourse.cataclysmdda.org/t/armor-up-a-mod-to-make-armor-more-better-new-pa-utilities-pack/15449/22 "2018-08-24T15:29:21Z")

</div>

You can’t put C++ code from a .cpp file in a .json file. That will not work at all.

bio\_ads is interesting, because the support code for it is actually in player::absorb\_hit():

```auto
        // The bio_ads CBM absorbs damage before hitting armor
        if( has_active_bionic( bio_ads ) ) {
            if( elem.amount > 0 && power_level > 24 ) {
                if( elem.type == DT_BASH ) {
                    elem.amount -= rng( 1, 8 );
                } else if( elem.type == DT_CUT ) {
                    elem.amount -= rng( 1, 4 );
                } else if( elem.type == DT_STAB ) {
                    elem.amount -= rng( 1, 2 );
                }
                charge_power(-25);
            }
            if( elem.amount < 0 ) {
                elem.amount = 0;
            }
        }

```

you would want similar code in the same place, but with a different check in the if statement, and draining UPS power instead of bionic charge.

You’d have to do a similar analysis for each behavior you wanted implemented: “how does the game do something similar? can I reuse that code as is? could I refactor that code so my thing could also use it? Should I just copy and change that code?”

For stat boosters, you’ll want to go to Character::reset\_stats() and… wow, that code is not great. I would feel bad for recommending you copy that code.  
Okay, for stat boosters, you’ll want to go to Character::reset\_stats(), rewrite it to loop through all of the character’s traits, bionics, and items, and add or subtract the appropriate bonus or penalty from the thing in question. Then you’ll need to edit all of those things Json load functions, to parse and store a Json array that looks like “bonuses”: [[ “stat\_or\_skill1”, NUM1], [“stat\_or\_skill2”, NUM2] ] . And then you’ll need to through the existing traits and bionics .json files and add the bonus descriptors. And then after that, adding equipment bonuses will be easy, plus modding in new bonus mutations and bionics will be easier.

---

<div class="post-metadata">

**Author:** ![darktoes](https://avatars.discourse-cdn.com/v4/letter/d/b9e5f3/32.png) [@darktoes](https://discourse.cataclysmdda.org/u/darktoes)\
**Post date:** [August 24, 2018, 11:58pm UTC](https://discourse.cataclysmdda.org/t/armor-up-a-mod-to-make-armor-more-better-new-pa-utilities-pack/15449/23 "2018-08-24T23:58:53Z")

</div>

Screw that noise. Just use the artifact stat boost effects. It even totals them, so you can add and subtract enough to get pretty much any number and it will just show up as one effect.

---

<div class="post-metadata">

**Author:** ![mlangsdorf](https://sea2.discourse-cdn.com/flex016/user_avatar/discourse.cataclysmdda.org/mlangsdorf/32/2462_2.png) [@mlangsdorf](https://discourse.cataclysmdda.org/u/mlangsdorf)\
**Post date:** [August 25, 2018, 2:52pm UTC](https://discourse.cataclysmdda.org/t/armor-up-a-mod-to-make-armor-more-better-new-pa-utilities-pack/15449/24 "2018-08-25T14:52:48Z")

</div>

I always forget about the artifacts code. Yeah, use artifacts.

Also, rewrite Character::reset\_stats() at some point.

---

<div class="post-metadata">

**Author:** ![Einstein\_Cross](https://sea2.discourse-cdn.com/flex016/user_avatar/discourse.cataclysmdda.org/einstein_cross/32/10564_2.png) [@Einstein\_Cross](https://discourse.cataclysmdda.org/u/Einstein_Cross)\
**Post date:** [August 26, 2018, 2:08pm UTC](https://discourse.cataclysmdda.org/t/armor-up-a-mod-to-make-armor-more-better-new-pa-utilities-pack/15449/25 "2018-08-26T14:08:37Z")

</div>

Ok so right now I’m trying to make a variant of power armor that is in the tool\_armor file. Im attempting to have the armor transform into identical armor but in its “on” state and have that powered on version basically pull attributes from the enums.h file. But I can’t get the armor to drain power from the players internal power source. Any ideas?

---

<div class="post-metadata">

**Author:** ![Einstein\_Cross](https://sea2.discourse-cdn.com/flex016/user_avatar/discourse.cataclysmdda.org/einstein_cross/32/10564_2.png) [@Einstein\_Cross](https://discourse.cataclysmdda.org/u/Einstein_Cross)\
**Post date:** [August 26, 2018, 2:09pm UTC](https://discourse.cataclysmdda.org/t/armor-up-a-mod-to-make-armor-more-better-new-pa-utilities-pack/15449/26 "2018-08-26T14:09:36Z")

</div>

Also if this doesn’t work, I’ll definitely look into just rewriting the Character::reset\_stats() to be more easily modified and try that route.

---

<div class="post-metadata">

**Author:** ![mlangsdorf](https://sea2.discourse-cdn.com/flex016/user_avatar/discourse.cataclysmdda.org/mlangsdorf/32/2462_2.png) [@mlangsdorf](https://discourse.cataclysmdda.org/u/mlangsdorf)\
**Post date:** [August 26, 2018, 5:17pm UTC](https://discourse.cataclysmdda.org/t/armor-up-a-mod-to-make-armor-more-better-new-pa-utilities-pack/15449/27 "2018-08-26T17:17:53Z")

</div>

you may be running into an issue that “power\_armor”: true defines an activation action and your activation item defines an activation item. So you can transform in another suit of PA, but then it won’t be activated. And it’ll transform back into the base state if you try.

You may want to look at the code that implements “power\_armor”: true, and see if you can get it to chain activation sequences.

---

<div class="post-metadata">

**Author:** ![Einstein\_Cross](https://sea2.discourse-cdn.com/flex016/user_avatar/discourse.cataclysmdda.org/einstein_cross/32/10564_2.png) [@Einstein\_Cross](https://discourse.cataclysmdda.org/u/Einstein_Cross)\
**Post date:** [August 30, 2018, 6:40pm UTC](https://discourse.cataclysmdda.org/t/armor-up-a-mod-to-make-armor-more-better-new-pa-utilities-pack/15449/28 "2018-08-30T18:40:21Z")

</div>

This is a little off topic, but is there an easy way to make it so you could load a robot from jury rigged robots or a hacked robot into a vehicle like pet animal?

---

<div class="post-metadata">

**Author:** ![mlangsdorf](https://sea2.discourse-cdn.com/flex016/user_avatar/discourse.cataclysmdda.org/mlangsdorf/32/2462_2.png) [@mlangsdorf](https://discourse.cataclysmdda.org/u/mlangsdorf)\
**Post date:** [August 30, 2018, 6:48pm UTC](https://discourse.cataclysmdda.org/t/armor-up-a-mod-to-make-armor-more-better-new-pa-utilities-pack/15449/29 "2018-08-30T18:48:19Z")

</div>

Animal capture code doesn’t check if a creature is an animal, so you should be able to load robots into livestock stalls and onboard kennels.

---

<div class="post-metadata">

**Author:** ![darktoes](https://avatars.discourse-cdn.com/v4/letter/d/b9e5f3/32.png) [@darktoes](https://discourse.cataclysmdda.org/u/darktoes)\
**Post date:** [November 3, 2018, 6:24am UTC](https://discourse.cataclysmdda.org/t/armor-up-a-mod-to-make-armor-more-better-new-pa-utilities-pack/15449/30 "2018-11-03T06:24:24Z")

</div>

New content! Power Armor Utilities includes craftable sheaths and stuff for power armor. Get it while it’s hot!

This pack was made because of prompting by Exceptional on Discord, who suggested maintaining [Mokou-tan’s Power Armor Additions.](https://discourse.cataclysmdda.org/t/mokou-tans-power-armor-additions/16492) I haven’t copied any of his/her code or anything, but it did serve as minor inspiration and an example.

---

<div class="post-metadata">

**Author:** ![Lerzan](https://sea2.discourse-cdn.com/flex016/user_avatar/discourse.cataclysmdda.org/lerzan/32/3566_2.png) [@Lerzan](https://discourse.cataclysmdda.org/u/Lerzan)\
**Post date:** [November 6, 2018, 5:47pm UTC](https://discourse.cataclysmdda.org/t/armor-up-a-mod-to-make-armor-more-better-new-pa-utilities-pack/15449/31 "2018-11-06T17:47:46Z")

</div>

What about armor on the low end that is actually armor? Say wooden styles of armor, maybe stuff made from PVC piping and other “hold my beer” type things?

It seems like the early game is rushing to find a duster/trench coat and leather clothes for protection, so it would be interesting to be able to make armor as a alternative (with other layers so joints can be protected.

My mind sees something similar to the armor used by the Haida, which used interlocking slats to make wood armor.

The LAT mention makes me wonder if a zombie could get out of a kiddie pool full of non-newtonian fluid as well…

---

<div class="post-metadata">

**Author:** ![joxer](https://avatars.discourse-cdn.com/v4/letter/j/f19dbf/32.png) [@joxer](https://discourse.cataclysmdda.org/u/joxer)\
**Post date:** [November 6, 2018, 7:19pm UTC](https://discourse.cataclysmdda.org/t/armor-up-a-mod-to-make-armor-more-better-new-pa-utilities-pack/15449/32 "2018-11-06T19:19:46Z")

</div>

Sounds good except, You can’t fit anything ‘worth the time’ that’s less significant than a trenchcoat, backpack or shopping cart.  
Altho i’d appreciate being proven wrong.

---

<div class="post-metadata">

**Author:** ![Lerzan](https://sea2.discourse-cdn.com/flex016/user_avatar/discourse.cataclysmdda.org/lerzan/32/3566_2.png) [@Lerzan](https://discourse.cataclysmdda.org/u/Lerzan)\
**Post date:** [November 6, 2018, 9:09pm UTC](https://discourse.cataclysmdda.org/t/armor-up-a-mod-to-make-armor-more-better-new-pa-utilities-pack/15449/33 "2018-11-06T21:09:56Z")

</div>

You could have a real low end that would be just 2x4s, rags and nails to hold it together. Awful durability and only average coverage but craftable almost immediately. Maybe only used until you find the trench coat but it let’s you go into a city with _something_ .

The other thought was upgrades, you make a shoddy wood breastplate, then at a higher level you can make it fitted or add strips of metal/plastic to improve it.

Storage is a bit more difficult though, maybe a sled thing that makes more noise and needs more str to drag but can make it early. That’s a discussion for a different thread though, this one doesn’t need a second derail haha.

---

<div class="post-metadata">

**Author:** ![darktoes](https://avatars.discourse-cdn.com/v4/letter/d/b9e5f3/32.png) [@darktoes](https://discourse.cataclysmdda.org/u/darktoes)\
**Post date:** [November 7, 2018, 1:27am UTC](https://discourse.cataclysmdda.org/t/armor-up-a-mod-to-make-armor-more-better-new-pa-utilities-pack/15449/34 "2018-11-07T01:27:44Z")

</div>

There already exists arm and leg coverings made of 2x4s, but any kind of torso covering made from 2x4s screams “high-encumbrance” to me. I suppose you could just live with it, but I don’t think making bad makeshift armor and trying to tank the earlygame is the correct way to play.

That said, early wooden armor isn’t really within the scope of this mod. It’s intended more for advanced lategame stuff. If you wanted more makeshift armor I’d suggest asking around the makeshift items mod, or even getting started on your own mod.

---

<div class="post-metadata">

**Author:** ![Malkeus](https://sea2.discourse-cdn.com/flex016/user_avatar/discourse.cataclysmdda.org/malkeus/32/12037_2.png) [@Malkeus](https://discourse.cataclysmdda.org/u/Malkeus)\
**Post date:** [November 16, 2018, 11:55am UTC](https://discourse.cataclysmdda.org/t/armor-up-a-mod-to-make-armor-more-better-new-pa-utilities-pack/15449/35 "2018-11-16T11:55:53Z")

</div>

Will these spawn or are the only craftable?

---

<div class="post-metadata">

**Author:** ![darktoes](https://avatars.discourse-cdn.com/v4/letter/d/b9e5f3/32.png) [@darktoes](https://discourse.cataclysmdda.org/u/darktoes)\
**Post date:** [November 16, 2018, 12:17pm UTC](https://discourse.cataclysmdda.org/t/armor-up-a-mod-to-make-armor-more-better-new-pa-utilities-pack/15449/36 "2018-11-16T12:17:52Z")

</div>

Craftable only.

_Post must be 20 characters._

---

<div class="post-metadata">

**Author:** ![crazykiddeath](https://sea2.discourse-cdn.com/flex016/user_avatar/discourse.cataclysmdda.org/crazykiddeath/32/5709_2.png) [@crazykiddeath](https://discourse.cataclysmdda.org/u/crazykiddeath)\
**Post date:** [January 29, 2019, 11:31am UTC](https://discourse.cataclysmdda.org/t/armor-up-a-mod-to-make-armor-more-better-new-pa-utilities-pack/15449/37 "2019-01-29T11:31:30Z")

</div>

Dunno if its cos I’m running an older version of the game but I had some error messages come up when loading a save with the Power armour utilities mod running, nothing game breaking but I messed around with the recipes file until I fixed it and fixed the sheath not showing in the craft menu. I thought I’d see if you wanted me to upload it and thank you for the Mod while I’m here 🙂

---

<div class="post-metadata">

**Author:** ![darktoes](https://avatars.discourse-cdn.com/v4/letter/d/b9e5f3/32.png) [@darktoes](https://discourse.cataclysmdda.org/u/darktoes)\
**Post date:** [January 29, 2019, 11:55am UTC](https://discourse.cataclysmdda.org/t/armor-up-a-mod-to-make-armor-more-better-new-pa-utilities-pack/15449/38 "2019-01-29T11:55:22Z")

</div>

Depends how old the version you’re running is. If some new crafting updates dropped that broke my recipes I’d like to fix them, but I’m not overly concerned with supporting very old versions of the game.

---

<div class="post-metadata">

**Author:** ![crazykiddeath](https://sea2.discourse-cdn.com/flex016/user_avatar/discourse.cataclysmdda.org/crazykiddeath/32/5709_2.png) [@crazykiddeath](https://discourse.cataclysmdda.org/u/crazykiddeath)\
**Post date:** [January 29, 2019, 12:02pm UTC](https://discourse.cataclysmdda.org/t/armor-up-a-mod-to-make-armor-more-better-new-pa-utilities-pack/15449/39 "2019-01-29T12:02:41Z")

</div>

0.c-29017 (I think) sorry still pretty new to the game so dunno how old exactly it is

---

<div class="post-metadata">

**Author:** ![darktoes](https://avatars.discourse-cdn.com/v4/letter/d/b9e5f3/32.png) [@darktoes](https://discourse.cataclysmdda.org/u/darktoes)\
**Post date:** [January 29, 2019, 12:59pm UTC](https://discourse.cataclysmdda.org/t/armor-up-a-mod-to-make-armor-more-better-new-pa-utilities-pack/15449/40 "2019-01-29T12:59:14Z")

</div>

I _think_ that’s pretty old.

[Previous page](https://discourse.cataclysmdda.org/t/armor-up-a-mod-to-make-armor-more-better-new-pa-utilities-pack/15449.md?page=1)

[Next page](https://discourse.cataclysmdda.org/t/armor-up-a-mod-to-make-armor-more-better-new-pa-utilities-pack/15449.md?page=3)
