UpgradeCore

版本 v0.1.0·更新於 2026-09-05

Developer API for registering upgrades and managing persistent player ownership and activation.

模組介紹 作者原文

Upgrade Core

Upgrade Core is a developer library for registering upgrade definitions, querying a shared catalog, and storing persistent ownership and activation for players or item models. It does not add upgrades or acquisition mechanics by itself.

Developer API

Register content with UpgradeApi.Register(...), discover it through UpgradeApi.Catalog, and grant or query it through UpgradeApi.State. Upgrade providers remain responsible for implementing their gameplay behavior; gacha, shop, achievement, and event mods only decide when registered upgrades are granted.

UpgradeApi.Register(new UpgradeDefinition(

id: "YourTeam.YourMod/double-jump",

displayName: "Double Jump",

scope: UpgradeScope.Player,

iconPng: iconBytes,

badgeColor: Color.cyan,

acquisitionTags: new { "shop", "achievement" }));

UpgradeTarget target = UpgradeTarget.ForPlayer(player);

UpgradeApi.State.Grant(target, "YourTeam.YourMod/double-jump");

if (UpgradeApi.State.IsEnabled(target, "YourTeam.YourMod/double-jump"))

{

// The provider applies its own gameplay behavior here.

}

Acquisition mods can discover compatible content without referencing its provider assembly:

IEnumerable shopPool =

UpgradeApi.Catalog.CompatibleWith(target, "shop");

Use globally unique, permanent IDs in Team.Mod/upgrade-name form. Catalog order is not a network identity; synchronize the string ID or maintain a deterministic provider-owned mapping.

The initial API supports player-wide and item-model upgrades. Reapplying ownership is idempotent, and enabled state is stored independently from ownership. Ownership is deliberately local in 0.1.0: a multiplayer acquisition mechanic must validate the reward authoritatively and invoke Grant(...) on the owning client. Upgrade Core does not yet define a trust model for purchases or achievements.

AI Disclosure

This mod was developed with assistance from generative AI for programming, documentation, and promotional artwork. The author reviewed, tested, and approved the final implementation and assets.

安裝與使用 安裝:按包內說明操作

  1. 解壓本站下載的壓縮包,先讀包內的 readme / 說明檔案。
  2. 多數模組依賴遊戲的模組載入器:常見做法是用社群模組管理器(如 r2modman)選中本遊戲安裝,由管理器自動處理載入器與依賴。
  3. 手動安裝時,把模組檔案放進遊戲目錄下對應的 Mod / plugins 資料夾。
  4. 啟動遊戲確認載入成功;帶「前置依賴」的模組需要把依賴一併安裝。

不同模組的安裝位置差異較大,包內說明是最可靠的依據。

前置依賴

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

BepInEx-BepInExPack

檔案與校驗

檔案名稱
UpgradeCore-0.1.0.zip
檔案大小
103.5 KiB