Tuneups
Speed fixes for other mods. Adventure Backpacks: its backpack check runs thousands of times a frame; this makes it skip normal objects. Same answers, nothing saved.
模組介紹 作者原文
Tuneups
Speed fixes for other mods. Each fix only switches on when the other mod's code is exactly what the fix was made for, gives exactly the same answers, and never saves or changes anything.
Adventure Backpacks: a faster backpack check
Adventure Backpacks (2.2.10) checks whether an object is one of its backpacks every time the game asks "is this PC in charge of this object?". It does that by reading the object's name, and the game asks that question constantly: at our base, about 6,600 times a frame. Each name read also leaves a little garbage behind for the game to clean up.
Measured at our base (1 player, 144 creatures, about 6,000 building pieces), the check alone cost 3.2 to 4.3 ms of every frame (out of about 28 ms, or 36 FPS) across four test runs. On top of that, the game ran a full memory clean-up 83 times in 2 minutes, a small hitch each time, and all those name reads add to what it has to clean up.
The fix: a backpack never has network data of its own (Adventure Backpacks stops its network setup on purpose). So any object that does have network data can't be a backpack, and it skips the name check. Objects without network data still get Adventure Backpacks' own check, unchanged.
Is it safe?
- Same answers. For every object the game gets the same answer as with Adventure Backpacks alone. Only the work to get there is skipped.
- Nothing is saved or changed. No world data, no backpack contents, no inventory. Backpacks open, carry, upgrade and save exactly as before.
- It checks before it starts. When the game starts, Tuneups reads Adventure Backpacks' check and its network setup skip. It only switches on if both are exactly the ones this fix was made for. If Adventure Backpacks updates and changes them, the fix does nothing and says so in the log.
- It watches while it runs. Every backpack Adventure Backpacks makes is looked at. If one ever has network data, the fix switches itself off at once and Adventure Backpacks' own check is back.
- Easy to undo. Turn it off in the settings (works while you play), or remove the mod. Nothing stays behind.
- Doesn't need to match between players. It only changes how fast your own game answers, so players with and without it can play together.
Settings (anwo.Tuneups.cfg)
| Setting | Default | What it does |
|---|---|---|
| 1 - Adventure Backpacks | | |
| Faster backpack check | true | Objects with network data skip Adventure Backpacks' backpack name check (can be turned on and off while you play) |
Check that it works
BepInEx/LogOutput.log says Adventure Backpacks fix on when the game starts. If it isn't used, the log says why (for example, Adventure Backpacks isn't installed, or its check has changed).
Compatibility
Works with Adventure Backpacks 2.2.10. With any other version, the fix only switches on if that version's check is still the same; otherwise it does nothing. Without Adventure Backpacks it does nothing at all.
About this mod
Written with Claude (Anthropic's AI model) for a two-player server, and tagged AI Generated. Built for Valheim 1.0.17 (Deep North) and BepInEx 5.4.2351. The slow check belongs to Adventure Backpacks, and this mod is only a stopgap until it's fixed there.
Found a bug or a clash with another mod? Report it on the mod's page and include your BepInEx/LogOutput.log.
安裝與使用 安裝:BepInEx 外掛
- 本站下載的壓縮包就是模組本體,通常是 BepInEx 外掛(解壓後得到 .dll 或外掛資料夾)。
- 建議流程:用社群模組管理器(如 r2modman)選中本遊戲後匯入該模組,管理器會自動裝好 BepInEx 前置並處理依賴。
- 手動流程:先在遊戲目錄裝好 BepInEx 載入器,再把解壓出的 .dll 或外掛資料夾放進 BepInEx/plugins/。
- 啟動遊戲,BepInEx 控制台會列印載入日誌;確認這個模組出現在日誌裡即為安裝成功。
帶「前置依賴」的模組需要一併安裝,否則不會載入。功能開關通常在遊戲內或外掛自帶的設定檔裡調整。 多人連線時,主機與所有用戶端需要安裝一致的模組。
下面這些內容需要先安裝,否則該模組不會生效: