# Moist Nuggets

**URL:** <https://discourse.cataclysmdda.org/t/moist-nuggets/1261>\
**Category:** The Toolbox\
**Created:** [May 16, 2013, 6:22pm UTC](https://discourse.cataclysmdda.org/t/moist-nuggets/1261 "2013-05-16T18:22:46Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![Dintin](https://avatars.discourse-cdn.com/v4/letter/d/ecae2f/32.png) [@Dintin](https://discourse.cataclysmdda.org/u/Dintin)\
**Post date:** [May 16, 2013, 6:22pm UTC](https://discourse.cataclysmdda.org/t/moist-nuggets/1261/1 "2013-05-16T18:22:46Z")

</div>

I’m trying to add GLORIOUS MOSIN-NAGANT RIFLE to the game, and the rifle itself is in. Added it with no problems. What I’m having trouble with is adding 7.62x54mmR ammunition to the game. I get a file factory error each time.

Exact error I get:

> C:\Users\Kyratzes\Downloads\Cataclysm-DDA-0.5\Cataclysm-DDA-0.5\item\_factory.cpp[784]: Read invalid ammo 7.62x54mmR.

Exact code I’m using:

`	{ "type" : "AMMO",
        "id" : "762_mmr",
        "rarity" : 9,
        "price" : 700,
        "name" : "7.62x54mmR",
        "symbol" : "=",
        "color" : "dark_gray",
        "description" : "The 7.62x54mmR is a rimmed rifle cartridge developed by the Russian Empire and was introduced as a service cartridge in 1891. Originally designed for the bolt-action Mosin-Nagant rifle.",
        "material" : "STEEL",
        "volume" : 4,
        "weight" : 12,
        "bashing" : 1,
        "cutting" : 0,
        "to_hit" : 0,
        "ammo_type" : "7.62x54mmR",
        "damage" : 36,
        "pierce" : 10,
        "range" : 36,
        "accuracy" : 13,
        "recoil" : 32,
        "count" : 50,
        "effects" : ["COOKOFF"]
    },`

---

<div class="post-metadata">

**Author:** ![bubbadoo14](https://sea2.discourse-cdn.com/flex016/user_avatar/discourse.cataclysmdda.org/bubbadoo14/32/2716_2.png) [@bubbadoo14](https://discourse.cataclysmdda.org/u/bubbadoo14)\
**Post date:** [May 16, 2013, 7:12pm UTC](https://discourse.cataclysmdda.org/t/moist-nuggets/1261/2 "2013-05-16T19:12:28Z")

</div>

What’s with the topic title?

---

<div class="post-metadata">

**Author:** ![Dintin](https://avatars.discourse-cdn.com/v4/letter/d/ecae2f/32.png) [@Dintin](https://discourse.cataclysmdda.org/u/Dintin)\
**Post date:** [May 16, 2013, 7:23pm UTC](https://discourse.cataclysmdda.org/t/moist-nuggets/1261/3 "2013-05-16T19:23:42Z")

</div>

On /k/ Mosin-Nagants are referred to as Moist Nuggets.

---

<div class="post-metadata">

**Author:** ![drake1storm](https://avatars.discourse-cdn.com/v4/letter/d/54ee81/32.png) [@drake1storm](https://discourse.cataclysmdda.org/u/drake1storm)\
**Post date:** [May 16, 2013, 7:56pm UTC](https://discourse.cataclysmdda.org/t/moist-nuggets/1261/4 "2013-05-16T19:56:41Z")

</div>

You have to define new ammo types in item factory. Only ammos of an existing type can be easily added to the json.

---

<div class="post-metadata">

**Author:** ![Dintin](https://avatars.discourse-cdn.com/v4/letter/d/ecae2f/32.png) [@Dintin](https://discourse.cataclysmdda.org/u/Dintin)\
**Post date:** [May 16, 2013, 7:59pm UTC](https://discourse.cataclysmdda.org/t/moist-nuggets/1261/5 "2013-05-16T19:59:50Z")

</div>

Where would I find the item factory though? I have no folder called Kyratzes in C:\Users\

---

<div class="post-metadata">

**Author:** ![drake1storm](https://avatars.discourse-cdn.com/v4/letter/d/54ee81/32.png) [@drake1storm](https://discourse.cataclysmdda.org/u/drake1storm)\
**Post date:** [May 16, 2013, 8:57pm UTC](https://discourse.cataclysmdda.org/t/moist-nuggets/1261/6 "2013-05-16T20:57:21Z")

</div>

No, you don’t. I’m guessing this is the first time you’ve had a debug message popup.

First off, use code blocks and then open itemfactory.cpp with that. After that, search for something like “9mm” using ctrl+f, right click on everything that seems relevant, and go to “show occurrences of”. In your search window, it will show a list of all of the places these occur. In these places, you will need to either create or place a similar bit of code to what is there, except if it is a mapgen or a monster file (starts with m), as those are only necessary additions if you want to make them spawn naturally.
