Please disclose if your mod was created primarily using AI tools by adding the 'AI Generated' category. Failing to do so may result in the mod being removed from Thunderstore.
ValheimPerformanceOverhaul
Fps mod for Valheim..
| Date uploaded | 2 weeks ago |
| Version | 3.0.0 |
| Download link | Skarif-ValheimPerformanceOverhaul-3.0.0.zip |
| Downloads | 1596 |
| Dependency string | Skarif-ValheimPerformanceOverhaul-3.0.0 |
This mod requires the following mods to function
denikson-BepInExPack_Valheim
BepInEx pack for Valheim. Preconfigured and includes unstripped Unity DLLs.
Preferred version: 5.4.2202README
Valheim Performance Overhaul
A comprehensive performance optimization mod focused on reducing CPU and GPU load - especially on large bases, busy servers, and zones with many light sources.
Installation
Install via r2modman or Thunderstore Mod Manager (recommended) - everything is placed automatically.
Manual install:
- Install BepInExPack Valheim first.
- Copy
ValheimPerformanceOverhaul.dllintoBepInEx/plugins/. - Launch the game - a config file is generated automatically at
BepInEx/config/com.Skarif.ValheimPerformanceOverhaul.cfg.
What it does
āļø In-Game Settings Menu (New in 3.0.0)
- A built-in configuration menu accessible directly from the Valheim Main Menu.
- You no longer need external configuration managers to tweak VPO settings!
š§± Decor Batching (New in 3.0.0)
- Automatically combines meshes of decorative building pieces (Misc category) in a grid chunk to drastically reduce draw calls.
- Huge FPS boost on extremely detailed, decoration-heavy bases.
š Network Optimizations (Crossplay Safe!) (Returned in 3.0.0)
- Steam Socket Uncap: Increases P2P data limits (solves desyncs on huge bases). Safely checks for Steam API and disables itself gracefully on Game Pass / Crossplay to prevent crashes.
- Adaptive Throttling: Intelligently drops ZDO sends to clients with high ping (>400ms) to prevent choking their connection.
- Smart ZDO Sorting: Prioritizes players, portals, and ships over AI during network sync.
- Smart Zone Ownership: Automatically transfers AI control to the player with the lowest ping in the zone.
š«ļø Smoke Physics Optimization & Memory Leak Fix
- Replaces complex vanilla smoke aerodynamics with a simple, lightweight approximation.
- Fixes a critical vanilla memory leak where smoke objects were never destroyed after fading, piling up invisibly and killing FPS.
AddForceandmasscalculations are heavily throttled for maximum CPU savings.
š¦ Light Culling & LOD
- Limits active light sources to a configurable maximum (default: 15).
- Disables shadow casting beyond a set distance.
- Light LOD system: transitions lights through Full ā No Shadows ā Emissive ā Billboard ā Disabled as distance increases.
šÆļø Light Flicker Optimization
- Fixes fire and torch light intensity at its base value, eliminating per-frame Shadow Map recalculation.
- Making the light static means shadows are computed once and reused until something moves. Huge GPU gain.
š¤ Distance & Piece Culler
- Puts distant creatures and building pieces to "sleep" - pauses their Update logic.
- Piece Sleep Manager: Puts static building pieces (
WearNTear) to sleep after 2 frames of inactivity. - Asynchronous WearNTear initialization - spreads load over multiple frames on scene load.
WearNTear.GetSupport()results are cached with a configurable TTL.
š¤ AI Throttling
- Monsters beyond 60 m update AI only every 5 seconds instead of every frame.
- LOS (line-of-sight) checks are cached per-target with a 0.5 s timeout.
- Idle tamed animals inside player bases enter a low-power mode.
š ļø Engine Quality Settings
- Forces low-level Unity
QualitySettingstweaks at startup:- Soft Particles disabled - eliminates per-pixel Depth Buffer reads for particle edges.
- Soft Vegetation disabled.
- Particle Raycast Budget reduced (default: 1024, vanilla: 4096).
šæ Vegetation & Graphics
- Grass render distance and density control.
- Configurable shadow distance, resolution, and cascade count.
- Bloom and screen-space reflections toggle.
šµ Audio & ā»ļø Object Pooling
- Reuses
AudioSourceandItemDrop/ProjectileGameObjects to reduce instantiation overhead. - Operates with zero garbage allocations on the hot path using pre-compiled Expression delegates.
š§ GC Control & ā” JIT Warm-up
- Prevents Unity's garbage collection from firing during combat or movement.
- Pre-compiles critical game methods on spawn to eliminate the first-use stutter.
š”ļø Frame Budget Guard
- Monitors frame times in a rolling 120-frame window and tracks the 1% Low.
- When heavy spikes are detected, dynamically lowers
Time.maximumDeltaTimeto prevent Unity's physics engine from entering the Death Spiral (lag ā over-simulation ā freeze).
ā© Skip Intro
- Skips the Iron Gate and Coffee Stain logo screens on every game launch. Saves 5ā10 seconds.
Configuration
All settings are available in the Main Menu VPO Button or in BepInEx/config/com.Skarif.ValheimPerformanceOverhaul.cfg.
Key settings
| Setting | Default | Description |
|---|---|---|
| Decor Batching | false | Combines meshes of decorations to reduce draw calls |
| Network Optimizations | true | Enables Steam Uncap, Smart Sorting, and Adaptive Throttling |
| Max Active Lights | 15 | Max simultaneous light sources |
| Light Cull Distance | 60 m | Beyond this distance lights turn off |
| Light Flicker Optimization | true | Fixes light intensity, stops per-frame shadow rebuilds |
| Smoke Physics Optimization | true | Replaces heavy smoke aerodynamics + fixes memory leak |
| Engine Quality Settings | true | Disables soft particles/vegetation, reduces particle raycast budget |
| Frame Budget Guard | true | Prevents physics Death Spiral during heavy load spikes |
| Creature Cull Distance | 80 m | Creatures sleep beyond this distance |
| Piece Cull Distance | 100 m | Building pieces sleep beyond this distance |
Performance expectations
Results depend heavily on scene complexity. Typical gains:
| Scenario | Expected FPS gain |
|---|---|
| Open world, few structures | ~5ā10% |
| Medium base (50ā100 pieces) | ~10ā20% |
| Large base (300+ pieces, 10+ light sources) | ~25ā45% |
| Busy server with many players/mobs | ~15ā30% |
| Massive base with decor batching & smoke fix | additional ~15ā25% on top |
Compatibility
- ā Works standalone - no other mods required.
- ā Compatible with most content mods (Epic Loot, Jotunn-based mods, etc.).
- ā Crossplay Compatible! Network optimizations automatically detect if you are running on Steam or Game Pass and adjust safely.
- ā ļø If Object Pooling conflicts with a custom projectile mod, disable it in config.
- ā ļø Light Flicker Optimization removes the visual flicker from fires. Disable if you prefer vanilla aesthetics.
- ā ļø Smoke Physics Optimization changes smoke behaviour (won't accumulate under roofs). Disable if this breaks your chimney designs.
CHANGELOG
Changelog
v3.0.0
Added
- Decor Batching (New Module): Automatically combines meshes of decorative pieces (Misc category, no WearNTear) in a chunk grid to drastically reduce draw calls on large bases. Configurable rebuild cooldown and minimum pieces per chunk.
- In-Game Settings Menu: Added a built-in VPO configuration menu accessible directly from the Main Menu. No longer requires external BepInEx Configuration Manager to tweak settings.
- Network Optimizations (Crossplay Safe!): Brought back and completely rewritten to safely support Game Pass / Crossplay:
- Steam Socket Uncap: Increases P2P data limits (solves lag on huge bases). Safely disables itself if not running on Steam.
- Adaptive Throttling: Intelligently drops ZDO sends to clients with high ping (>400ms) to prevent choking their connection.
- Smart ZDO Sorting: Prioritizes players, portals, and ships over AI during network sync to prevent desyncs.
- Smart Zone Ownership: Automatically transfers AI control to the player with the lowest ping in the zone.
- Piece Sleep Manager: Puts static building pieces (
WearNTear) to sleep after 2 frames of inactivity, saving CPU cycles on massive structures.
Changed / Optimized
- Zero GC Allocations on Hot Paths: Replaced expensive Reflection (
GetValue/SetValue) with compiled Expression delegates. Completely eliminates boxing (float->object) and garbage generation per frame in:LightFlickerPatch(v2.8.0)VegetationPatches(v2.8.1)SmokePatch(v2.9.0)ObjectPoolManager
- O(1) Collection Upgrades: Upgraded
DistanceCullerManager,AIOptimizerManager, andAudioPoolManagerto useHashSetalongsideList. This changes duplicate checking from O(n) to O(1), fixing massive O(n²) lag spikes when loading chunks with thousands of objects. - Smoke Physics Overhaul:
AddForceis now throttled to run once every 3 physics frames. Rigidbodymassupdates are throttled to 0.1s.isKinematicandRigidbodyreferences are now heavily cached. - Tamed Idle Optimizer: Optimized base detection using
LayerMaskdirectly inPhysics.OverlapSphere, avoiding expensiveGetComponentInParenttraversals on hundreds of colliders. - Object Pooling: Optimized
IsInWhitelistto useGetStableHashCode, completely avoiding string allocations (Replace,Trim) on the hot path. Removed unnecessary threadlockstatements since pooling is strictly single-threaded, reducing overhead. - AdvancedLightManager & FrameBudgetGuard: Cached
Comparerdelegates to avoid lambda allocations multiple times per second.
Fixed
- [CRITICAL] Smoke Memory Leak: Fixed a critical vanilla issue (and previous patch oversight) where smoke objects were never destroyed after fading out. Hundreds of invisible smoke objects would accumulate and tick in
FixedUpdate, killing FPS over time. - [CRITICAL] Light Culling Conflict: Fixed a severe conflict where
AdvancedLightManagerandLightLODManagerboth patchedZNetScene.CreateObjectand fought over light states. Registration is now unified. - Zombie Lights Bug: Fixed a bug in
AdvancedLightManagerwhere destroyed lights weren't removed from the_culledLightslist, causing zombie references that permanently broke the active lights limit. - Animator Conflict: Fixed a bug where
AIOptimizerandCharacterAnimatorOptimizerwere fighting overAnimator.cullingModein the same frame. - Support Cache: Added
ZNetScene_OnDestroy_Postfixto clear the invalidation queue on scene unload, preventing null reference errors when changing worlds.
v2.7.1
Added
- mini-update (smokePatch).
v2.7.0
Added
- Light Flicker Optimization ā Harmony Prefix on
LightFlicker.CustomUpdatethat fixes light intensity at its base value, eliminating per-frame Shadow Map recalculation for all fires and torches. - Smoke Physics Optimization ā Harmony Prefix on
Smoke.CustomUpdatethat replaces the vanilla complex aerodynamics with a lightweight quadratic interpolation + single upward force. - Engine Quality Settings ā Forces low-level Unity
QualitySettingsat startup:softParticles = false,softVegetation = false, configurableparticleRaycastBudget. - Skip Intro ā Skips Iron Gate and Coffee Stain logo screens on every game launch.
- Frame Budget Guard ā Dynamic stutter protection system. Monitors a rolling 120-frame window and lowers
Time.maximumDeltaTimewhen heavy spikes are detected.
Changed
- Config sections renumbered: new modules occupy sections 17ā21.
v2.6.4
Added
- Nothing (maintenance release).
v2.6.3
Added
- Welcome screen on main menu launch with clickable Discord link.
v2.6.0
Changed / Fixed
- Removed
NetworkManagerandZDOOptimizertemporarily (crossplay issues). - Fixed
LightLODManagerduplicate scans. DistanceCullerrefactored to centralUpdateloop.AsyncWearInitearly exit when queue is empty.
v2.5.1
- Initial public release.