BrudvikStackedChest is a mod for Valheim that enhances the building experience by adding custom chests that automatically spawn and restock items. Each chest has a unique color and icon, and the contents will automatically be refilled to maximum stack size whenever you:
- Take items out of the chest
- Use items directly from the chest
- Use mods that allow building from chests (like EAQS or similar)
Perfect for builders who want to focus on creativity rather than grinding for materials!
All chests are built using the Hammer and can be found in the "Chests" category. Each chest requires:
| Resource | Amount | Recoverable |
|---|---|---|
| Wood | 10 | Yes |
Once placed, the chest will:
- Spawn initial items - All configured items appear at maximum stack size
- Monitor changes - The chest watches for inventory changes via Harmony patching
- Refill automatically - When items are removed, they are instantly refilled to max stack
When you destroy or remove a chest:
- All contents are automatically deleted (no item drops)
- This prevents cluttering your world with unwanted items
- The chest can be safely relocated without spawning duplicate items
Warning: If you store custom items in the "Everlasting Chest", they will be lost when the chest is removed!
A chest filled with wood materials
| Color | Items |
|---|---|
| Black | Wood, FineWood, RoundLog, Blackwood, Coal, AncientBark, Root, YggdrasilWood, ElderBark |
A chest filled with stone materials
| Color | Items |
|---|---|
| Gray | Flint, Obsidian, BlackMarble, Stone, Grausten, SharpeningStone, CeramicPlate |
A chest filled with metal materials
| Color | Items |
|---|---|
| Dark Red | Iron, IronNails, Bronze, BronzeNails, Silver, BlackMetal, Tin, Copper, Chain, CharredCogwheel, Flametal, FlametalNew, MechanicalSpring, IronScrap, CopperScrap, CopperOre, TinOre, IronOre, SilverOre, BlackMetalScrap, FlametalOre |
A chest filled with food ingredients
| Color | Items |
|---|---|
| Brown | Raw ingredients: Barley, BarleyFlour, Blueberries, Carrot, Honey, Mushrooms, Onion, Raspberry, Turnip, and many more. Cooked foods: Bread, Sausages, QueensJam, CarrotSoup, TurnipStew, BloodPudding, FishWraps, various cooked meats, and more! |
A chest filled with various crafting materials
| Color | Items |
|---|---|
| Dark Blue | BlackCore, Crystal, Eitr, RefinedEitr, Guck, LinenThread, MoltenCore, Needle, Ooze, Resin, Sap, SurtlingCore, Tar, Thunderstone, Wisp, Gemstones (Blue/Green/Red), and more! |
A chest filled with animal materials
| Color | Items |
|---|---|
| Yellow | BoneFragments, Carapace, Chitin, DeerHide, DragonTear, Feathers, GreydwarfEye, LeatherScraps, LoxPelt, TrollHide, WolfPelt, WolfFang, SerpentScale, and more! |
A chest filled with seeds and saplings
| Color | Items |
|---|---|
| Green | Acorn, AncientSeed, BeechSeeds, BirchSeeds, CarrotSeeds, OnionSeeds, PineCone, TurnipSeeds, VineberrySeeds, FirCone, Sap, BarleyWild, FlaxWild |
A chest filled with all trophies
| Color | Items |
|---|---|
| Teal | All boss trophies (Eikthyr, TheElder, Bonemass, DragonQueen, GoblinKing, SeekerQueen, Fader) + all creature trophies (60+ different trophies!) |
A chest filled with treasures and riches
| Color | Items |
|---|---|
| Gold/Yellow | Amber, AmberPearl, Coins, Ruby, SilverNecklace, Gemstones, DragonEgg, GoblinTotem, Hildir Keys |
A chest filled with useful tools
| Color | Items |
|---|---|
| Purple | BarberKit, BeltStrength (Megingjord), CryptKey, FishingRod, All fishing baits, Lantern, Wishbone, Hammer, Hoe, Cultivator, All pickaxes, SaddleLox, Demister, DvergrKey, and more! |
A chest filled with armor sets from all tiers
| Color | Items |
|---|---|
| Brown | Complete armor sets: Leather, Troll, Bronze, Iron, Wolf/Silver, Padded, Carapace, Flametal, Mage, Fenris, Root. Plus all capes! |
A chest filled with weapons from all biomes
| Color | Items |
|---|---|
| Red | Swords, Axes, Maces, Atgeirs, Spears, Knives, Bows, Crossbows, Staffs, Arrows, Bolts, and Shields from all tiers! |
A chest filled with meads and potions
| Color | Items |
|---|---|
| Pink/Purple | Health meads (Minor/Medium/Major), Stamina meads, Eitr meads, Resistance meads (Frost/Poison/Bug), Tasty mead, and all mead bases for brewing! |
An empty chest - add items to make them last forever
| Color | Items |
|---|---|
| Dark Gray | Empty - add your own items and they will be restocked automatically! |
All custom chests now feature:
- Glow Effect: Each chest emits a subtle glow in its respective color, making them easy to identify
- Particle Effects: A sparkle effect appears when items are automatically refilled
| Property | Value |
|---|---|
| Inventory Size | 8 x 8 (64 slots) |
| Base Prefab | piece_chest |
| Build Category | Chests |
| Build Tool | Hammer |
The mod uses several key technologies:
- Jotunn (JVL) - For piece registration and prefab management
- Harmony Patching - To intercept container events
- Event-Driven Design - Clean separation of concerns
| Method | Patch Type | Purpose |
|---|---|---|
| Container.CheckForChanges | Postfix | Triggers item refill after inventory changes |
| Container.DropAllItems | Prefix | Empties chest before removal to prevent item drops |
- Download the latest release from the releases page
- Extract the contents of the zip file
- Copy BrudvikStackedChest.dll to BepInEx/plugins folder
- Launch Valheim
- BepInEx (5.4.x or later)
- Jotunn (JVL) (2.20.x or later)
Please notice that it will not be possible to compile this mod out of the box. Make sure you read up on Valheim Mod Development.
There is also a directory removed from the source. The Assets folder is not part of the public source. The icons I have bought from Graphicriver.net and the license only allows it to be shipped in the pre-built mod file. If you want to make a similar mod you would need to buy a license from there.
As a thank you for the community in assisting me to learn about mod development in Valheim, I figured that the least I could do was to share the source of my findings and the result of the learning process. The mod itself is not that great, it was more about the adventure in reaching the goal. A working mod, that could assist me in what I love the most - simply exploring and building. And yes, I know it could be done using debugmode - but that takes away the fun in exploring a new world, though I hate grinding - thus this mod.
This mod demonstrates several modding techniques:
- Using JVL (Jotunn, the Valheim Library)
- Harmony prefix/postfix patching
- Event-driven architecture
- C# extension methods
- Embedded resources (sprites/icons)
- Prefab cloning and modification
- Custom piece configuration
- Added: Armor Chest - complete armor sets from all tiers (Leather, Troll, Bronze, Iron, Wolf, Padded, Carapace, Flametal, Mage, Fenris, Root)
- Added: Weapon Chest - weapons from all biomes (swords, axes, maces, atgeirs, spears, knives, bows, crossbows, staffs, arrows, bolts, shields)
- Added: Potion Chest - all meads and potions (health, stamina, eitr, resistance meads + mead bases)
- Added: Glow effect - all chests now glow subtly in their respective color
- Added: Particle effects - sparkle effect when items are automatically refilled
- Fixed problem with setting correct hover text on chests.
- Fixed SpawnItems issue when new chests where created, but not yet placed.
- Removed Awake patch call, as it is no longer needed.
- Removed chests will not clutter the world anymore.
- Added an empty chest, for when you want to store your own things.
- Added missing SurtlingCore to materials chest.
- Initial release.
- No known issues at this time. Please report any issues on the GitHub issues page.
You can find the GitHub repository at: https://github.com/brudvik/BrudvikStackedChest
