DeathPenalty
Allows tweaking death related values such as skill loss amount.
模組介紹 作者原文
Allows tweaking various death related values. You can make death softer or harder as desired by editing the config.
- Tune the death penalty skill level loss percentage.
- Toggle whether skill progress towards the next level is reset.
- Modify the duration of the "No Skill Loss" buff.
- Modify the duration of the "Corpse Run" buff.
Run the game once with the mod enabled to generate the config. See config for details on what each option does.
This mod must be installed on client and server.
Some configuration options can be enforced by a server running ConditionalConfigSync. See included ConfigSync_Readme.txt file for more information.
Installation
This mod uses BepInExPack Valheim as a mod loader. You can use any BepinEx compatible mod manager to install the mod, or manually place it in the BepixEx plugins directory.
Valheim Skill Loss Calculation
Skills levels are stored as two values, the level itself and the percentage progress towards the next level.
When a player dies, the game calculate a skill loss factor using the formula 0.05 * SkillReductionRate. SkillReductionRate is a global key determined by the death penalty world modifier. As of Valheim 1.0, these are the modifier values:
- Casual and very easy: 0.15
- Easy: 0.5
- Normal: 1.0
- Hard: 1.5
The game then loops through all of the player's skills and does the following:
- Set the skill level to current level - (current level * skill loss factor)
- Reset the progress towards the next level
Because the factor is multiplied by the current level, that means losses impact higher level skills considerably more than lower level skills. At standard settings, a level 20 skill would drop to 19 for a loss of about 42 experience while a level 100 skill would drop to 95 for a loss of about 2420 experience. (Experience per level follows the formula next=Floor(current + 1)^1.5 * 0.5 + 0.5.)
This mod allows adjusting the skill loss calculation in the following ways:
- Adjust the base 0.05 constant used in the loss factor calculation, represented by the config SkillLossPercent as a percentage value (like 5%).
- Optionally skip resetting the progress towards the next level that normally occurs by setting the config ResetLevelProgress to false.
安裝與使用 安裝:BepInEx 外掛
- 本站下載的壓縮包就是模組本體,通常是 BepInEx 外掛(解壓後得到 .dll 或外掛資料夾)。
- 建議流程:用社群模組管理器(如 r2modman)選中本遊戲後匯入該模組,管理器會自動裝好 BepInEx 前置並處理依賴。
- 手動流程:先在遊戲目錄裝好 BepInEx 載入器,再把解壓出的 .dll 或外掛資料夾放進 BepInEx/plugins/。
- 啟動遊戲,BepInEx 控制台會列印載入日誌;確認這個模組出現在日誌裡即為安裝成功。
帶「前置依賴」的模組需要一併安裝,否則不會載入。功能開關通常在遊戲內或外掛自帶的設定檔裡調整。 多人連線時,主機與所有用戶端需要安裝一致的模組。
下面這些內容需要先安裝,否則該模組不會生效: