You are viewing a potentially older version of this package. View all versions.
mihow-WeightsRebalanced-2.1.0 icon

WeightsRebalanced

Customize item weights in kg with working multiplayer sync, global/category multipliers, presets, hot reload and unit selection.

Date uploaded 3 days ago
Version 2.1.0
Download link mihow-WeightsRebalanced-2.1.0.zip
Downloads 55
Dependency string mihow-WeightsRebalanced-2.1.0

This mod requires the following mods to function

BepInEx-BepInExPack-5.4.2100 icon
BepInEx-BepInExPack

BepInEx pack for Mono Unity games. Preconfigured and ready to use.

Preferred version: 5.4.2100

README

Weights Rebalanced

Customize item weights in kilograms with working multiplayer synchronization, global and per-category weight multipliers, preset system, hot reload and HUD unit selection (kg / lb / both).

v2.1.0 fixes the multiplayer sync (it never actually fired in 2.0.x), stops the host's weights from overwriting clients' config files, matches the vanilla 105 lb weight formula exactly, fixes carry-weight corruption when weights change mid-game, and adds real modded-item detection via LethalLib.

Features

Core Functionality

  • Kilogram Display - All weights shown in kg instead of pounds
  • Per-Item Configuration - Customize weight for every item in the game
  • Automatic Item Detection - Works with vanilla and modded items automatically
  • Config Validation - Prevents invalid weights (0-500 kg range)
  • Global & Category Multipliers - Scale all weights, or Scrap/Equipment/Store/Modded separately
  • Display Units - HUD counter in Kilograms, Pounds (vanilla) or Both

Multiplayer Support

  • Host-to-Client Sync - Host's weights automatically sync to all clients
  • Late Join Support - Players joining mid-game receive correct weights
  • Hot Reload - Change weights mid-game and see instant results
  • Auto-Restore - Clients restore their local config on disconnect

Quality of Life

  • Preset System - Save and load weight configurations
  • Import/Export - Share presets with friends
  • Enhanced Descriptions - Config shows vanilla weights and valid ranges
  • Diagnostic Tools - Check item detection and network status

Optional LethalConfig Integration

If you have LethalConfig installed, you get:

  • In-game GUI for all settings
  • Sliders for easy weight adjustment
  • Buttons for presets, diagnostics, and network status
  • No restart needed for changes

Installation

Automatic (Mod Manager)

  1. Install via r2modman or Thunderstore Mod Manager
  2. Launch game - config will be generated automatically

Manual

  1. Install BepInEx 5.4.23.5 (BepInExPack)
  2. Download WeightsRebalanced.zip
  3. Extract to Lethal Company folder
  4. Launch game

Configuration

Config File Location

BepInEx/config/com.weights.rebalanced.cfg

Example Configuration

[General]
# Enable/disable weight modifications
EnableWeightModifications = true

[Scrap Items]
# Weight in kilograms
# Vanilla weight: 1.5 kg
# Valid range: 0.1-500 kg
Whoopie cushion = 1.5

# Make valuable items heavier for balance
Gold bar = 25.0

Item Categories

Items are automatically organized into sections:

  • Scrap Items - Collectible scrap (Whoopie cushion, Gold bar, etc.)
  • Equipment - Tools and gear (Flashlight, Shovel, Walkie-talkie, etc.)
  • Store Items - Purchasable items (TZP-Inhalant, Lockpicker, etc.)
  • Modded Items - Items from other mods (auto-detected)

Usage

Changing Weights

  1. Via LethalConfig (if installed):

    • Press F1 in-game
    • Navigate to Weights Rebalanced
    • Adjust sliders
    • Changes apply instantly
  2. Via Config File:

    • Edit BepInEx/config/com.weights.rebalanced.cfg
    • Change values (in kg)
    • Save file
    • Changes apply on next item spawn (or use hot reload)

Using Presets

Save Current Weights

F1 → Weights Rebalanced → Presets → Save Current as Preset

Preset saved to: BepInEx/config/WeightsRebalanced/Presets/Custom_YYYY-MM-DD_HH-mm.txt

Load Vanilla Weights

F1 → Weights Rebalanced → Presets → Load Vanilla Weights

Share Presets

  1. Navigate to BepInEx/config/WeightsRebalanced/Presets/
  2. Copy your .txt preset file
  3. Share with friends
  4. They copy it to their Presets folder

Multiplayer

As Host

  • Your weights automatically sync to all clients
  • Clients see your configured weights
  • Change weights mid-game - clients receive updates instantly

As Client

  • Automatically receive host's weights on connect
  • Your local config is temporarily overridden
  • Original config restores when you disconnect
  • Check sync status: F1 → Network Sync Status

Commands & Diagnostics

Check Network Status

F1 → Weights Rebalanced → Network Sync Status

Shows:

  • "Using HOST'S weights" - Client synced to host
  • "You are HOST" - Your weights control the server
  • "Not in multiplayer" - Using local config

Print Item Detection

F1 → Weights Rebalanced → Diagnostic: Print Item Detection

Logs all items with their detected origin (Vanilla/Modded) and category.

Reset All Weights

F1 → Weights Rebalanced → Reset All Weights

Resets all items to vanilla values.

Compatibility

Supported

  • ✅ All vanilla items
  • ✅ LethalConfig (optional GUI)
  • ✅ Modded items (auto-detected)
  • ✅ LethalLib custom items
  • ✅ Multiplayer (host-client sync)

Known Issues

  • None reported yet!

Technical Details

Weight Range

  • Minimum: 0.1 kg
  • Maximum: 500 kg
  • Invalid values are clamped and logged

Performance

  • Optimized HUD updates with caching
  • Minimal network bandwidth (<1KB/s)
  • No FPS impact (<1% overhead)

Network Protocol

  • Uses Unity Netcode custom messaging
  • Version-checked for compatibility
  • Handles late joiners and disconnects gracefully

FAQ

Q: Do clients need the mod installed? A: Yes, all players need the mod for consistent weights.

Q: Can I use different weights than the host? A: No, host's weights override clients in multiplayer.

Q: Will this work with mod X? A: Yes! The mod automatically detects and supports modded items.

Q: Can I make items weightless? A: Yes - since 2.1.0 the minimum weight is 0 kg (vanilla weightless items stay weightless).

Q: How do I reset one item to vanilla? A: Check the config file - vanilla weight is shown in the description.

Support

Report issues on GitHub or Thunderstore.

Credits

Developed with Claude Code by Anthropic.

Changelog

See CHANGELOG.md for version history.

CHANGELOG

Changelog

All notable changes to Weights Rebalanced will be documented in this file.

[2.1.0] - 2026-07-05

New Features

  • Global Weight Multiplier - one slider scaling all item weights at once
  • Per-Category Multipliers - separate multipliers for Scrap / Equipment / Store / Modded items
  • Display Unit selection - HUD weight counter can show Kilograms, Pounds (vanilla) or Both
  • Weights of 0 kg are now allowed (vanilla weightless items like the flashlight stay weightless)

Fixed

  • Multiplayer sync never actually fired - the host only tried to sync 2 s after StartOfRound.Start (before any client is connected) and never subscribed to OnClientConnectedCallback. Clients now receive weights the moment they connect, including late joiners.
  • Sync broke after the first lobby - the message handler was registered once per game session, but Netcode recreates CustomMessagingManager on every StartHost/StartClient. It is now re-registered for each session.
  • Client configs were overwritten on disk by the host's weights - synced values are now kept in a runtime-only override table; the local config file is never touched, so nothing can be lost on crash.
  • Wrong kg conversion factor - the game displays (carryWeight - 1) * 105 lb; the mod used * 100, so all displayed/configured weights were ~5% off from vanilla. Now uses the exact vanilla factor.
  • Changing the weight of a held item corrupted carry weight permanently - the game subtracts the CURRENT item weight on drop; the mod now adjusts every holder's carryWeight by the delta when weights change mid-game.
  • Modded item detection never worked - item.GetType().Assembly is always the vanilla assembly. Modded items are now detected through LethalLib's registration lists via reflection.
  • Presets were saved with the system locale (e.g. "12,5" on Polish systems) making them non-shareable - now always invariant culture, with backward-compatible parsing.
  • HUD weight is now updated by a postfix on HUDManager.UpdateWeightCounter (the only place vanilla writes "lb") instead of patching HUDManager.Update every frame.
  • HUD value is derived from the real carryWeight, so dead bodies and other mods' weight changes are displayed correctly.
  • Removed dead code: scan-node lb->kg patch (scan nodes never show lb and used the wrong UI type) and the DisplayNewScrapFound patch.

Technical

  • Built against BepInEx 5.4.23.5
  • Weight application centralized in WeightApplier with original-asset-weight tracking

[2.0.1] - 2026-01-10

  • Fixed manifest

[2.0.0] - 2026-01-09

Major Features

  • Multiplayer Synchronization - Host-to-client weight sync via Unity Netcode
    • Automatic sync on client connect
    • Late joiner support
    • Hot reload broadcasts to all clients
    • Original config restoration on disconnect
  • Dynamic Item Detection - Removed hardcoded item lists
    • Assembly-based vanilla vs modded detection
    • Automatic categorization (Scrap/Equipment/Store/Modded)
    • Works with any mod without updates needed
  • Preset System - Save and load weight configurations
    • Save current weights as preset
    • Load vanilla weights preset
    • Import/export for sharing with friends
    • Simple text format for easy editing
  • Hot Reload - Change weights mid-game without restart
    • Config watcher monitors changes
    • Updates all active items in real-time
    • Broadcasts to clients if host

Improvements

  • Config Validation - All weights clamped to 0.1-500 kg range
  • Enhanced Descriptions - Config shows vanilla weight and valid range
  • Safety Helpers - Comprehensive error handling and validation
  • Optimized HUD Updates - Cached inventory hash reduces CPU usage
  • Performance - Event-based patching with Update fallback

LethalConfig Integration

  • New buttons:
    • Save Current as Preset
    • Load Vanilla Weights
    • Network Sync Status
    • Diagnostic: Print Item Detection
  • Updated slider ranges with validation
  • Real-time updates without restart

Technical

  • Added ConfigValidator.cs - Weight validation system
  • Added SafetyHelpers.cs - Error handling utilities
  • Added ItemDetection/ namespace:
    • ItemClassifier.cs - Vanilla/modded detection
    • CategoryDetector.cs - Item categorization
    • DiagnosticCommands.cs - Debug tools
  • Added Presets/PresetManager.cs - Preset management
  • Added HotReload/ConfigWatcher.cs - Real-time config monitoring
  • Added Networking/ namespace:
    • WeightSyncManager.cs - Multiplayer synchronization
  • Added Patches/NetworkPatches.cs - Network event hooks
  • Improved Patches/WeightPatches.cs - Optimized HUD updates

Bug Fixes

  • Fixed HUD showing "lb" instead of "kg" in all scenarios
  • Fixed potential null reference exceptions
  • Fixed item validation edge cases
  • Fixed network sync timing issues

Removed

  • Hardcoded vanilla item lists (42 scrap, 17 store, 3 equipment items)
  • Update-only HUD patching (replaced with hybrid approach)

[1.0.0] - Initial Release

Features

  • Customize item weights in kilograms
  • Per-item configuration
  • LethalConfig integration (optional)
  • Weight display in kg instead of pounds
  • Basic item categorization

Note: Version 1.0.0 was the initial internal release. Version 2.0.0 is the first public Thunderstore release with major enhancements.