# Tailor's kit as tool prerequisite

**URL:** <https://discourse.cataclysmdda.org/t/tailors-kit-as-tool-prerequisite/8941>\
**Category:** The Drawing Board\
**Created:** [February 18, 2015, 6:34pm UTC](https://discourse.cataclysmdda.org/t/tailors-kit-as-tool-prerequisite/8941 "2015-02-18T18:34:55Z")\
**Posts on this page:** 9\
**Page:** 1

<div class="post-metadata">

**Author:** ![Valiant](https://sea2.discourse-cdn.com/flex016/user_avatar/discourse.cataclysmdda.org/valiant/32/4788_2.png) [@Valiant](https://discourse.cataclysmdda.org/u/Valiant)\
**Post date:** [February 18, 2015, 6:34pm UTC](https://discourse.cataclysmdda.org/t/tailors-kit-as-tool-prerequisite/8941/1 "2015-02-18T18:34:55Z")

</div>

I think there’s need in adding tailor’s kit as “tools required” in all crafting recipes which required bone needle, wooden needle or sewing kit.

---

<div class="post-metadata">

**Author:** ![KA101](https://avatars.discourse-cdn.com/v4/letter/k/278dde/32.png) [@KA101](https://discourse.cataclysmdda.org/u/KA101)\
**Post date:** [February 19, 2015, 12:19am UTC](https://discourse.cataclysmdda.org/t/tailors-kit-as-tool-prerequisite/8941/2 "2015-02-19T00:19:50Z")

</div>

> [@Valiant](#):
>
> I think there’s need in adding tailor’s kit as “tools required” in all crafting recipes which required bone needle, wooden needle or sewing kit.

Sure, since it contains a sewing kit. Someone PR this and it’ll get in ASAP.

---

<div class="post-metadata">

**Author:** ![Valiant](https://sea2.discourse-cdn.com/flex016/user_avatar/discourse.cataclysmdda.org/valiant/32/4788_2.png) [@Valiant](https://discourse.cataclysmdda.org/u/Valiant)\
**Post date:** [February 19, 2015, 12:16pm UTC](https://discourse.cataclysmdda.org/t/tailors-kit-as-tool-prerequisite/8941/3 "2015-02-19T12:16:24Z")

</div>

I suppose this is done already for most of recipes. Thx for responsiveness. One little detail: as for 381dacd, the brass catcher in “mods” subcategory also lacks tailor’s kit.

---

<div class="post-metadata">

**Author:** ![KA101](https://avatars.discourse-cdn.com/v4/letter/k/278dde/32.png) [@KA101](https://discourse.cataclysmdda.org/u/KA101)\
**Post date:** [February 20, 2015, 2:56am UTC](https://discourse.cataclysmdda.org/t/tailors-kit-as-tool-prerequisite/8941/4 "2015-02-20T02:56:00Z")

</div>

> [@Valiant](#):
>
> I suppose this is done already for most of recipes. Thx for responsiveness. One little detail: as for 381dacd, the brass catcher in “mods” subcategory also lacks tailor’s kit.

That was about 45 minutes of grindy tedious “find all uses of the sewing\_kit in recipe\_armor.json and add the tailors\_kit, with the same number of charges” JSON work by yours truly. You’re welcome, and folks who find other holes can certainly file a PR to patch 'em up. \>\_\<

---

<div class="post-metadata">

**Author:** ![Coolthulhu](https://sea2.discourse-cdn.com/flex016/user_avatar/discourse.cataclysmdda.org/coolthulhu/32/2446_2.png) [@Coolthulhu](https://discourse.cataclysmdda.org/u/Coolthulhu)\
**Post date:** [February 20, 2015, 3:20am UTC](https://discourse.cataclysmdda.org/t/tailors-kit-as-tool-prerequisite/8941/5 "2015-02-20T03:20:42Z")

</div>

> [@KA101](#):
>
> [quote=“Valiant, post:3, topic:8941”]I suppose this is done already for most of recipes. Thx for responsiveness. One little detail: as for 381dacd, the brass catcher in “mods” subcategory also lacks tailor’s kit.

That was about 45 minutes of grindy tedious “find all uses of the sewing\_kit in recipe\_armor.json and add the tailors\_kit, with the same number of charges” JSON work by yours truly. You’re welcome, and folks who find other holes can certainly file a PR to patch 'em up. \>\_\<[/quote]

Two huge protips: one is grep (I use it all the time to search the sources and jsons), the other is regular expressions. Replacing blocks of repetitive code with regexps is billions of times less tedious than doing it by hand and you can automatize it to copy values too.  
They are also amazing when you want to find, for example, all invocations of a particular function overload with 2 arguments (rather than 1 or 3). Simple but ultra useful.  
Notepad++ has regexp support.

---

<div class="post-metadata">

**Author:** ![Valiant](https://sea2.discourse-cdn.com/flex016/user_avatar/discourse.cataclysmdda.org/valiant/32/4788_2.png) [@Valiant](https://discourse.cataclysmdda.org/u/Valiant)\
**Post date:** [February 21, 2015, 7:15am UTC](https://discourse.cataclysmdda.org/t/tailors-kit-as-tool-prerequisite/8941/6 "2015-02-21T07:15:53Z")

</div>

> [@KA101](#):
>
> [quote=“Valiant, post:3, topic:8941”]I suppose this is done already for most of recipes. Thx for responsiveness. One little detail: as for 381dacd, the brass catcher in “mods” subcategory also lacks tailor’s kit.

That was about 45 minutes of grindy tedious “find all uses of the sewing\_kit in recipe\_armor.json and add the tailors\_kit, with the same number of charges” JSON work by yours truly. You’re welcome, and folks who find other holes can certainly file a PR to patch 'em up. \>\_\<[/quote]  
I really appreciate and respect your hard work, and I know how annoying messages like I posted can be. Sorry if it was irritating.  
Is there some sort of tutorial for absolutely noobs like me? I mean, tutorial for working with json and other programming. I’m asking this because I barely understand even this abbreviation - “PR” - and what it is for. I wouldn’t even asked to add tailor’s kit in all recipes that needed it if I knew how it is done.

---

<div class="post-metadata">

**Author:** ![Coolthulhu](https://sea2.discourse-cdn.com/flex016/user_avatar/discourse.cataclysmdda.org/coolthulhu/32/2446_2.png) [@Coolthulhu](https://discourse.cataclysmdda.org/u/Coolthulhu)\
**Post date:** [February 21, 2015, 7:43am UTC](https://discourse.cataclysmdda.org/t/tailors-kit-as-tool-prerequisite/8941/7 "2015-02-21T07:43:45Z")

</div>

[quote=“Valiant, post:6, topic:8941”]I really appreciate and respect your hard work, and I know how annoying messages like I posted can be. Sorry if it was irritating.  
Is there some sort of tutorial for absolutely noobs like me? I mean, tutorial for working with json and other programming. I’m asking this because I barely understand even this abbreviation - “PR” - and what it is for. I wouldn’t even asked to add tailor’s kit in all recipes that needed it if I knew how it is done.[/quote]

Jsons have a quite obvious structure. Just edit them with a text editor and you should know what to do.  
After you edit and save the json, the game will pick up the changes next time you run it and load any save.  
One thing not to do: don’t backup the json anywhere in “data” directory or the game will read both the backup and the edited file and freak out.

As for PR, you want to do those things in this order: make an account on github (if you don’t have one), make a fork of DDA, make a branch on this fork, make a commit to the branch, send a pull request from the branch.  
Github has ready tutorials for all of those - just google `github create branch` and the like.

---

<div class="post-metadata">

**Author:** ![AllisonW](https://avatars.discourse-cdn.com/v4/letter/a/919ad9/32.png) [@AllisonW](https://discourse.cataclysmdda.org/u/AllisonW)\
**Post date:** [February 21, 2015, 1:05pm UTC](https://discourse.cataclysmdda.org/t/tailors-kit-as-tool-prerequisite/8941/8 "2015-02-21T13:05:48Z")

</div>

> [@Coolthulhu](#):
>
> Jsons have a quite obvious structure. Just edit them with a text editor and you should know what to do.

Notepad++ (a free program that can handle the formatting for files like JSON; google it). Use the wrong text editor, like Notepad, and it’ll fuck up the formatting. JSONs were pretty intimidating to me when I looked at them in Notepad, because while I could see, like, words in them, I had no idea what to do about the formatting. Notepad++ took care of that.

(I know you know this stuff, Coolthulhu, but it’s something Valiant should know.)

---

<div class="post-metadata">

**Author:** ![Coolthulhu](https://sea2.discourse-cdn.com/flex016/user_avatar/discourse.cataclysmdda.org/coolthulhu/32/2446_2.png) [@Coolthulhu](https://discourse.cataclysmdda.org/u/Coolthulhu)\
**Post date:** [February 21, 2015, 10:24pm UTC](https://discourse.cataclysmdda.org/t/tailors-kit-as-tool-prerequisite/8941/9 "2015-02-21T22:24:21Z")

</div>

> [@AllisonW](#):
>
> Notepad++ (a free program that can handle the formatting for files like JSON; google it).

Yeah, that’s actually a good tip. I use it myself.  
Worth mentioning: it didn’t autodetect that jsons are .js files for me. I had to set it manually.
