[MOD] CM Storage (13.02.2014)

Hello there. This is a small mod, implementing means to storage materials in blocks (AMMO type items), which stack in Advanced Inventory System and old inventory system. Also, many spare parts were changed to AMMO type to be able to stack (check changelog for a full list of them).

Currently added:
block (bone)
block (scrap metal)
block (fur pelt)
block (leather patch)
block (plastic chunk)
block (Kevlar plate)
block (chitin piece)
block (nomex patch)

All blocks can be made with zero skills, take 5 minutes and require 10 of initial material plus 10 thread. They have -20% volume of original material. On disassemble you get 10 initial materials and 8 threads back.

Installation: just unpack zip file from attachments to gamefolder\data\mods and create new world with activating “CM Storage”.


[spoiler=Changelog:]v1 (13.02.14)
First release.

Added items:

  • block (scrap metal)
  • block (fur pelt)
  • block (leather patch)
  • block (plastic chunk)
  • block (Kevlar plate)
  • block (chitin piece)
  • block (nomex patch)

Added recipes to craft and un-craft:

  • block (scrap metal)
  • block (fur pelt)
  • block (leather patch)
  • block (plastic chunk)
  • block (Kevlar plate)
  • block (chitin piece)
  • block (nomex patch)

Changed existing items “type” into “AMMO”:

  • sheet (changed volume from 20 to 16)
  • two by four
  • pipe
  • superglue
  • processor
  • RAM
  • power converter
  • amplifier circuit
  • transponder circuit
  • signal receiver
  • small LCD screen
  • high-quality lens
  • burnt out bionic
  • antenna
  • circuit board
  • electronic scrap
  • lead battery plate
  • heavy stick
  • wire
  • barbed wire
  • splintered wood
  • skewer
  • heating element
  • pilot light
  • copper tubing[/spoiler]

1. Checking on whole “containers” thingy, maybe it’ll be possible to create boxes, which can be used to store diffirent items.
2. Crates, crafted from blocks and some 2x4’s, holding even more materials, like 100.
3. If that mod will be interesting and useful, have some idea about basic home power system through vehicle building system.


  1. What syntax of “comments” is proper in JSON files?
  2. How to create new crafting sub category? I was able to assign OTHERS -> Blocks category to my recipes, but “Blocks” sub category haven’t appeared in crafting UI, it just “exists” invisible between OTHER -> Traps and OTHER -> Other.

Any suggestions, comments and bug reports are mostly welcome.

Since AIS was implemented, i wished similiar items (like bones) would stack. Because myself as a hoarder i was collecting all kinds of useful things on every game session. Since i have no knowledge in coding and couldn’t rewrite AIS, had to take modding path.
First, i just changed type of all items to AMMO, but encountered problem with clothing repair and reinforcements. While crafting and construction aquire “stacked” items well, attempt to repair helmet always lead to “Not enough scrap metal”, no matter how much scrap metal or how many stacks of it in tiles around i had. Also, rags and bones lost their “COMESTIBLES” attributes, so i couldn’t eat bones or use rags to stop bleeding.
In the end i had to add new things, which could be used to store initial materials without changing their attributes. So, all items that could be used as repairing material or eaten/used, can now be stored in blocks (rags can be stored in sheets, which are now stackable ammo too). All other materials are changed to “ammo” type for that matter.
So far i found no problems with crafting, constructing, repairing and using them all. -20% of volume appearing from more careful placement of things, and 20% of thread loss on disassemble came from personal experience, that some of them are always getting lost.
Sorry for langauge mistakes, it isn’t my native.

I like this A LOT!

Nice idea there.

Examined containers. It seems they work only with liquid so far. Even more, there is no way to activate empty container itself to make it load something. Only through unloading of other containers, toilets, vehicles and pounds of liquid container can be chosen as target to be filled.

Can’t change that, it seems all logic is hardcoded into .exe file, and i am zero skill coder (skill rust IRL, eh).

Also tried to make crates as TOOL in order to “reload” them with materials. Two problems:

  1. That require materials to be AMMO, which is not good for repairing components, bones and rags (explained in OP’s P.S.).
  2. Ammo seems to “mix” inside tools. So, lets say “wooden crate” (TOOL type) is in hands, reloaded with 2 RAM (AMMO type) from inventory, now it’s “wooden crate (2)”. Unloading gives us 2 RAM. Good. But then we reload it with 2 RAMs and 2 power convertors, it’s “wooden crate (4)”, and unloading gives us 4 RAM. Dang.

So, in todays nightly build the only way to make all those spare parts to stack is to create new item, made from them and giving them on disassemble.

UPD: About home power system based on vehicle construction i was too optimistic. Found out, that fueling is deep in the code, not in JSON:

void vehicle::consume_fuel (float rate = 1.0) { ammotype ftypes[3] = { fuel_type_gasoline, fuel_type_battery, fuel_type_plasma };
And so on. I don’t posses enough skills even to add another fueltype of “wood” for simple steam engine throught JSON modification, not to mention “area-based” stuff and so on. Everything else is doable right now in vanilla game: simple engine + alternator = home energy generator, simple frame = cable, simple floodlight = well, source of light.

EDIT: Added download link.

Does the crafting and uncrafting leave the damage to items the same throughout or does it ‘repair’ them? As in granting you a new set of whatever for disassembling a block.

Hm, never had opportiunity to check, never seen damaged scrap metal or smthing.
I presume, it’ll accept “damaged” into crafting (as it accepts “rotten” meat for making smoked meat) and create totally fresh block. Disassemblig which gives you 10 totally fresh materials.
I haven no idea how to change that scheme, not in JSON and mods for sure.

use acid to scratch stuff. or carve on something with a knife, and if it isnt the same when done then you know.