# Need help on item-spawning for mod

**URL:** <https://discourse.cataclysmdda.org/t/need-help-on-item-spawning-for-mod/17732>\
**Category:** The Toolbox\
**Created:** [December 4, 2018, 6:22am UTC](https://discourse.cataclysmdda.org/t/need-help-on-item-spawning-for-mod/17732 "2018-12-04T06:22:35Z")\
**Posts on this page:** 6\
**Page:** 2

<div class="post-metadata">

**Author:** ![Ricky\_Van](https://sea2.discourse-cdn.com/flex016/user_avatar/discourse.cataclysmdda.org/ricky_van/32/4666_2.png) [@Ricky\_Van](https://discourse.cataclysmdda.org/u/Ricky_Van)\
**Post date:** [December 4, 2018, 8:38am UTC](https://discourse.cataclysmdda.org/t/need-help-on-item-spawning-for-mod/17732/21 "2018-12-04T08:38:27Z")

</div>

allright… thanks for the info…

wow, turns out i missed the vital core of the mod. luckily its still in alpha test so fixing is main priority.  
lots of things to learn in JSON than typing the code.

---

<div class="post-metadata">

**Author:** ![Ricky\_Van](https://sea2.discourse-cdn.com/flex016/user_avatar/discourse.cataclysmdda.org/ricky_van/32/4666_2.png) [@Ricky\_Van](https://discourse.cataclysmdda.org/u/Ricky_Van)\
**Post date:** [December 4, 2018, 8:44am UTC](https://discourse.cataclysmdda.org/t/need-help-on-item-spawning-for-mod/17732/22 "2018-12-04T08:44:05Z")

</div>

![Capture](https://us1.discourse-cdn.com/flex016/uploads/cataclysmdda/original/2X/d/dcdcd974c9ee2b03f5effd2ce0b9991e37ca4830.jpeg)

just to make sure, is this right? or wrong?

---

<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:** [December 4, 2018, 8:51am UTC](https://discourse.cataclysmdda.org/t/need-help-on-item-spawning-for-mod/17732/23 "2018-12-04T08:51:28Z")

</div>

Your format looks good. I’m assuming those are all vanilla groups. Be aware, when you add the “ammo” flag you’re adding it to the entire item\_group, or overwriting what was there. This is probably an unintended consequence and will yield results you don’t expect. To get around this, you could nest them inside another group. So it’d be “guns\_shotgun\_rare” [group: RV\_shotguns", 100] and then rv\_shotguns whould be the entry you have above.

edit: sorry for the sloppy psuedo code, I’m tired and too lazy to do it right.  
edit2: don’t make it 100 percent chance if it’s going into a distribution, I think that’ll bork things. Collections are ok though.

---

<div class="post-metadata">

**Author:** ![Ricky\_Van](https://sea2.discourse-cdn.com/flex016/user_avatar/discourse.cataclysmdda.org/ricky_van/32/4666_2.png) [@Ricky\_Van](https://discourse.cataclysmdda.org/u/Ricky_Van)\
**Post date:** [December 4, 2018, 8:55am UTC](https://discourse.cataclysmdda.org/t/need-help-on-item-spawning-for-mod/17732/24 "2018-12-04T08:55:50Z")

</div>

😄 its ok, yeah im intended to do that as to give it a little bit compensation for the rare spawn weight.

yeah… im just goona use default method as of now, for testing purpose…

thanks.

---

<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:** [December 4, 2018, 8:57am UTC](https://discourse.cataclysmdda.org/t/need-help-on-item-spawning-for-mod/17732/25 "2018-12-04T08:57:13Z")

</div>

Happy to be of assistance.

Lol, fuck you 20 character limit.

---

<div class="post-metadata">

**Author:** ![Ricky\_Van](https://sea2.discourse-cdn.com/flex016/user_avatar/discourse.cataclysmdda.org/ricky_van/32/4666_2.png) [@Ricky\_Van](https://discourse.cataclysmdda.org/u/Ricky_Van)\
**Post date:** [December 4, 2018, 8:58am UTC](https://discourse.cataclysmdda.org/t/need-help-on-item-spawning-for-mod/17732/26 "2018-12-04T08:58:30Z")

</div>

😄 not enough character limit.

[Previous page](https://discourse.cataclysmdda.org/t/need-help-on-item-spawning-for-mod/17732.md?page=1)
