VeinProtector

版本 v0.5.1·更新於 2026-09-27

礦點礦物數量爲1時停止採集該礦點 Stops mining an individual vein node when its remaining resource amount reaches 1

截圖 共 4 張

模組介紹 作者原文

礦脈保護

一個用於《戴森球計劃》的礦脈保護Mod。當礦脈的單個礦點剩餘1個礦物時停止採礦,避免礦脈枯竭影響存檔上限。當前原版遊戲礦物利用390級後礦物會變爲0消耗,此時Mod不再進行保護,正常挖礦。

功能

  • 普通有限固體礦點剩餘1個礦物時進入保護狀態。
  • 受保護礦點不再消耗礦物,也不再產出礦物。
  • 小型採礦機和大型採礦機的速率詳情會排除已保護礦點的貢獻。
  • 遊戲內設置選項提供Mod開關。
  • 可在生產統計面板把鼠標移至參考速率詳情,查看已保護礦點數量和保護狀態參考速率。

設置

進入 設置 → 遊戲 → 礦脈保護 即可啓用或禁用,默認開啓。切換後立即生效,不需要重啓遊戲或重新載入存檔。

礦物利用等級與零消耗行爲

Mod不直接判斷科技等級,而是讀取遊戲當前實際的礦物資源消耗率。

當實際資源消耗率降爲0時,剩餘礦物數量爲1的礦點不再需要保護,被保護礦點會重新被開採,在當前原版機制下對應礦物利用390級。

參考速率

生產統計面板外部顯示的“參考速率”保持原版計算,Mod不修改該數值。

在支持的固體礦物參考速率詳情中(當鼠標移動到參考速率數值上時),Mod額外顯示:

  • 已保護礦點:N————當前統計範圍內,實際綁定到礦機且被保護的礦點數量。
  • 保護狀態參考速率:X / min————從原版理論參考速率中扣除受保護礦點對應的礦機貢獻後,當前工廠佈局的理論生產能力。

保護狀態參考速率是排除受保護礦點產能後的區域理論最高產值,該信息可幫助玩家在資源消耗率降爲零之前規劃生產。

當保護開關關閉或資源消耗率爲零時,詳情擴展會隱藏,恢復原版佈局。

適用範圍

Mod只處理普通有限固體礦脈。原油等其它非有限固體礦脈的生產邏輯保持原版。

保存與卸載

Mod不向存檔寫入額外的專用狀態。被保護的礦點仍是遊戲原生礦脈數據。關閉保護功能或卸載Mod後,這些礦點可以繼續按照原版邏輯被採盡。

兼容性

UXAssist含有礦脈保護功能,若已安裝UXAssist Mod則不再需要本Mod。

安裝

推薦使用r2modman Mod Manager,將BepInEx和VeinProtector安裝到同一個文件夾,並通過Mod管理器啓動遊戲。

手動安裝時,將 VeinProtector.dll 放入:BepInEx/plugins/VeinProtector/VeinProtector.dll

標準發佈ZIP已包含 BepInEx/plugins/VeinProtector/ 目錄結構,可按該結構解壓。不要在同一Profile中同時安裝管理器副本和另一個手動DLL副本。

開發 / Building

從源碼構建需要本機安裝的《戴森球計劃》遊戲程序集,以及 BepInEx/Harmony 引用。由於版權原因,這些 DLL 不包含在倉庫中。將它們放入 src/VeinProtector/AssemblyFromGame/ 和 src/VeinProtector/AssemblyFromProfile/(這兩個目錄已被 Git 忽略),然後運行 scripts/build.ps1。

問題反饋

反饋問題可至bilibili@SkyeDrem。

致謝

感謝《戴森球計劃》製作組帶來並持續維護這款優秀的遊戲。

感謝UXAssist項目及其公開實現,爲本Mod在礦脈保護機制和遊戲行爲分析方面提供了重要參考。

感謝BepInEx、Harmony/HarmonyX以及《戴森球計劃》Mod社區提供的工具、資料與技術積累。

感謝ChatGPT,本Mod由AI協助製作。

VeinProtector

A vein protection mod for Dyson Sphere Program. When an individual vein node has only 1 resource remaining, mining of that node stops to prevent vein depletion from affecting save limits. In the current vanilla game, resource consumption reaches zero at Veins Utilization level 390. At that point, the mod no longer applies protection and mining proceeds normally.

Features

  • Ordinary finite solid vein nodes enter protection when only 1 resource remains.
  • Protected vein nodes no longer consume resources and no longer produce resources.
  • Mining rate details for both regular miners and advanced miners exclude the contribution of protected vein nodes.
  • An in-game option is provided to enable or disable the mod.
  • In the Production Statistics panel, hover over the Reference Rate value to view the number of protected vein nodes and the Protected-State Reference Rate.

Configuration

Go to Settings → Game → Vein Protection to enable or disable the mod. It is enabled by default. Changes take effect immediately and do not require restarting the game or reloading the save.

Veins Utilization Level and Zero-Consumption Behavior

The mod does not directly check the technology level. Instead, it reads the game's current actual resource-consumption rate.

When the actual resource-consumption rate reaches 0, vein nodes with only 1 resource remaining no longer require protection, and previously protected nodes will resume mining. Under the current vanilla game mechanics, this corresponds to Veins Utilization level 390.

Reference Rate

The Reference Rate shown in the Production Statistics panel remains calculated by the vanilla game. The mod does not modify this value.

For supported solid resources, when hovering over the Reference Rate value to open its details, the mod additionally displays:

  • Protected Vein Nodes: N — The number of protected vein nodes within the current statistics scope that are actually connected to miners.
  • Protected-State Reference Rate: X / min — The theoretical production capacity of the current factory layout after subtracting the miner contribution of protected vein nodes from the vanilla theoretical Reference Rate.

The Protected-State Reference Rate represents the theoretical maximum production capacity of the selected area after excluding the capacity of protected vein nodes. This information can help players plan production before the resource-consumption rate reaches zero.

When vein protection is disabled or the resource-consum

安裝與使用 安裝:BepInEx 外掛

  1. 本站下載的壓縮包就是模組本體,通常是 BepInEx 外掛(解壓後得到 .dll 或外掛資料夾)。
  2. 建議流程:用社群模組管理器(如 r2modman)選中本遊戲後匯入該模組,管理器會自動裝好 BepInEx 前置並處理依賴。
  3. 手動流程:先在遊戲目錄裝好 BepInEx 載入器,再把解壓出的 .dll 或外掛資料夾放進 BepInEx/plugins/。
  4. 啟動遊戲,BepInEx 控制台會列印載入日誌;確認這個模組出現在日誌裡即為安裝成功。

帶「前置依賴」的模組需要一併安裝,否則不會載入。功能開關通常在遊戲內或外掛自帶的設定檔裡調整。

前置依賴

下面這些內容需要先安裝,否則該模組不會生效:

xiaoye97-BepInEx

檔案與校驗

檔案名稱
VeinProtector-0.5.1.zip
檔案大小
144.8 KiB