You are viewing a potentially older version of this package. View all versions.
cjayride-BossLootChests-1.0.14 icon

BossLootChests

Boss loot goes into unbreakable chests at the death spot instead of dumping on the ground. Chests vanish in smoke when emptied.

Date uploaded 6 days ago
Version 1.0.14
Download link cjayride-BossLootChests-1.0.14.zip
Downloads 218
Dependency string cjayride-BossLootChests-1.0.14

This mod requires the following mods to function

denikson-BepInExPack_Valheim-5.4.2360 icon
denikson-BepInExPack_Valheim

BepInEx pack for Valheim. Preconfigured with the correct entry point for mods and preferred defaults for the community.

Preferred version: 5.4.2360

README

Boss Loot Chests

Keep boss loot organized and protected from accidental pickup.

When a boss dies, its loot is placed into indestructible black-metal chests at the death location instead of being scattered across the ground. This prevents auto-pickup and chaotic melee from snatching coins, trophies, and rare drops before everyone gets a chance to see the rewards.

Installation required on the server and all clients.

Features

Boss Loot Storage

  • Captures boss loot before it becomes a ground item drop.
  • Stores loot in piece_chest_blackmetal by default. Change the ChestPrefab setting to use another container prefab.
  • Automatically spawns additional chests when the loot exceeds a chest's capacity.
  • Chests cannot be destroyed with weapons, damage, or the hammer.
  • Empty chests automatically disappear with a smoke effect.

EpicLoot & Drop That Compatibility

  • Supports EpicLoot magic items, preserving their rolled stats and properties.
  • Allows Drop That and EpicLoot to finish their loot rolls before items enter the chest.
  • Prevents duplicate magic-item drops.
  • Supports delayed boss loot from mods such as Path of Valheiman, merging it into an existing chest when possible.

Multiplayer & Per-Player Rewards

  • Counts only players within PerPlayerRange of the boss when it dies for one-per-player rewards.
  • Supports both individual item drops and configurable amount ranges.
  • Distributes ranged rewards per eligible player. For example, three eligible players receiving 200–300 coins each yield 600–900 coins in total.

Combat Add Loot

  • Tracks creatures that were near a boss while it was alive.
  • Loot from tracked creatures can be added to the boss chest even if the boss has already died.
  • Creatures that arrive after the boss dies are not included.
  • Supports multiplayer kills, regardless of which player's game processes the creature's death.
  • Stops tracking inactive creatures after a configurable timeout. Fighting the creature resets its inactivity timer.
  • Can capture nearby add loot for a limited time after the boss chest appears.

EpicLoot Bounties

  • EpicLoot bounty targets use boss chests when BountyLootInChest is enabled.
  • Disabled by default so bounty rewards continue using their normal behavior.

Configuration

Configuration file:

BepInEx/config/cjayride.bosslootchests.cfg

Setting Default Description
Enabled true Master enable/disable switch.
ChestPrefab piece_chest_blackmetal Container prefab used for boss loot.
RemoveSmoke true Plays a smoke effect when an empty chest disappears.
AddRadius 180 Radius in meters around a boss used to track combat adds.
AddSeconds 60 Time in seconds after a boss chest appears during which nearby add loot can still be captured.
AddIdleSeconds 1200 Seconds an unengaged tracked add can remain inactive before being forgotten. Fighting it resets the timer.
MergeSeconds 8 Time window for delayed boss loot to merge into an existing chest.
MergeRadius 16 Maximum distance in meters for delayed loot to merge into an existing chest.
PerPlayerAmounts true Applies configured amount ranges per eligible player.
PerPlayerRange 400 Maximum distance in meters from the boss for players to qualify for per-player rewards.
BountyLootInChest false Routes EpicLoot bounty target rewards into boss chests.

Notes

  • AddRadius determines which nearby creatures are tracked while a boss is alive.
  • AddIdleSeconds prevents inactive tracked creatures from being remembered indefinitely.
  • Set either MergeSeconds or MergeRadius to 0 to disable delayed loot merging.
  • PerPlayerRange is checked when the boss dies.
  • BountyLootInChest is optional and disabled by default.

Installation

  1. Install BepInEx on your Valheim server and clients.
  2. Install Boss Loot Chests on the dedicated server.
  3. Install Boss Loot Chests on every client.
  4. Launch the game to generate the configuration file.
  5. Adjust settings in BepInEx/config/cjayride.bosslootchests.cfg as needed.

Important: Both the server and every connecting client must have the mod installed.

Credits

Boss Loot Chests — by cjayride.

Compatible with EpicLoot and Drop That for enhanced loot handling.

CHANGELOG

Changelog

1.0.15

  • Compatibility check against Valheim 1.0.21 (Unity 6000.0.75). Existing Harmony targets still match; Inventory.Changed, WearNTear damage/remove, ItemDrop.DropItem, and CharacterDrop.DropItems extra parameters remain Harmony-compatible.
  • Perf: no per-frame Update. Add scanning runs on a 1.25s timer.
  • Perf: skip the creature-near-boss scan when no boss is in combat and no remembered adds exist.
  • Perf: ItemDrop.Awake tracking only while a loot capture is active (world load and normal item spawns no longer enter the patch body).
  • Perf: RPC register only on boss characters, boss ragdolls, and our chests — not every ragdoll or world container.
  • Perf: no scene-wide FindObjectsByType for ragdolls or containers; use cached boss ragdolls and boss chests.
  • Perf: chest ground snap uses RaycastNonAlloc.

1.0.14

  • Fix: Epic Loot (and other) captured items now resolve m_dropPrefab from shared item data before they go into boss chests or RPC transfer, same as harvested ground drops. Avoids tooltips/icons using the wrong prefab when the roll omitted m_dropPrefab.
  • Fix: if a captured item already had a drop prefab whose name/type did not match m_shared (shield icon + chest description, raw keys like [NPC_WEAPON_LEFT]), replace it with ObjectDB's prefab for that shared data.

1.0.13

  • Fix: Path of Valheiman (and other delayed boss loot, including ragdoll loot with Instant enemy loot) now fills the existing boss chest when it still has room. A second chest only spawns on overflow. New settings: MergeSeconds (8) and MergeRadius (16). Set either to 0 to disable.
  • Fix: Epic Loot's BountyTarget type is resolved once. Missing Epic Loot no longer looks it up (and hitches) on every creature kill.

1.0.12

  • Fix: chests now snap to terrain instead of the boss death spot. Flying bosses (and failed short raycasts) could leave a chest in the air; placement uses world ground height and ignores bodies, ragdolls, and other chests.

1.0.9

  • Creatures that were within 180 meters of the boss while it was alive still drop into the boss chest after the boss is dead, for as long as you take to finish them. Creatures that show up after the boss is dead stay on the ground. AddIdleSeconds (20 minutes) forgets a remembered add that nobody is fighting. Fighting it resets that timer.

1.0.8

  • One-per-player boss drops count only living players within PerPlayerRange (400 meters by default) of the boss when it dies. Before, every player online counted, so a solo kill paid out for the whole server.
  • This covers drops with an amount range, such as Coins 200–300 each, and single items such as trophies.

1.0.7

  • Fix: Epic Loot boss items were stored twice. Each weapon, shield, tool, and other magic item showed up as two copies with the same stats. Coins and other stacks were not doubled. Each rolled item now goes into the chest once.

1.0.6

  • Fix: coins, trophies, and other normal boss drops go into the chest again. 1.0.4 stopped catching them, so they fell on the ground.
  • Fix: one-per-player boss drops with an amount range now give that amount for each player online. Eikthyr Coins 200–300 with 3 players gives 600–900. Eikthyr eitr shards 5 with 3 players gives 15. Before, Valheim gave a flat 1 per player, and the shard row gave 5 total. PerPlayerAmounts, on by default.
  • Fix: add loot reaches the boss chest even when a different player's game handles the add's death. Adds count when they die within AddRadius of a boss in combat, of the boss's body, or of a boss chest that appeared within the last AddSeconds (now 60). AddRadius is now 600 meters.
  • Weapons keep their Drop That and Epic Loot magic rolls before they go into the chest.

1.0.5

  • Epic Loot bounty targets are no longer forced into boss chests by default (BountyLootInChest = false). Set it true to restore the old behavior.

1.0.4

  • Boss loot is captured from the drop that actually spawns, so Drop That can roll the configured amounts first. The Elder coin line (400–500 per player) was being replaced by vanilla's one-coin-per-player because this mod skipped Drop That's roll.
  • Adds that die within 80 meters of an alerted boss, and for 8 seconds after the boss dies, have their drops stored and placed in the boss chest. Another chest spawns beside it when one fills up.

1.0.3

  • Fix remove smoke VFX for all players (uses chest destroy effect from configured prefab).

1.0.2

  • Fix: chests appear again on boss kill (1.0.1 could delete the chest before loot was added).

1.0.1

  • Fix: chests still smoke-delete when emptied after you log out and back in.

1.0.0

  • Boss loot goes straight into world chests at the death spot. Nothing is spawned as a ground drop, so auto-pickup cannot grab it.
  • Extra chests spawn if one chest is not enough.
  • Chests are indestructible (hammer and damage do nothing).
  • A chest deletes itself when the last item is taken, with a smoke puff (RemoveSmoke, on by default).
  • EpicLoot magic-item rolls are stored in the same chests when EpicLoot is installed.
  • Install on the server and all clients.