UpgradeLib

v0.0.1·Updated 2025-01-05

API To ease the creation of upgrades, shop items etc.

About this mod Author’s original text

UpgradeLib Developer Guide

Overview

UpgradeLib is a small library that handles the registration and unloading of upgrades for your project.

Using UpgradeLib for Plugin Development

  • Download the.dll:
  • Download the.dll file and move it to the current working directory of your plugin.
  • Link the.dll in your csproj:

UpgradeLib.dll

Usage

  • Initialize UpgradeLib:
  • Typically, this is done in your mod’s Awake method:

UpgradeLibManager.Init("com.yourname.yourmod");

  • Create and register an upgrade:

var myUpgrade = new UpgradeDefinition(

id: 10001,

internalName: "MY_UNIQUE_UPGRADE",

title: "Example Upgrade",

description: "Does something special when purchased.",

price: 500,

stackable: false,

onPurchased: (fromSave) =>

{

// Code to run when the player unlocks or loads this upgrade

},

onLockedAllUpgrades: () =>

{

// Code to handle logic when all upgrades are locked (e.g., on game over)

}

);

UpgradeLibManager.RegisterUpgrade(myUpgrade);

TODO / Needs Testing

  • Multiplayer support has not been tested. Please test and report any issues.

Contact

If any issues occur, feel free to DM me on Discord: rammmmy.

Install & use Install: follow the bundled instructions

  1. Unzip the archive from playbuff and read the bundled readme / instructions first.
  2. Most mods rely on the game's mod loader — the usual route is a community mod manager (such as r2modman): pick this game, install, and it handles the loader and dependencies.
  3. For a manual install, put the mod files into the matching Mod / plugins folder inside the game directory.
  4. Launch the game to confirm it loaded; mods with listed dependencies need those installed as well.

Install locations vary a lot between mods — the bundled readme is the most reliable guide.

File & checksum

Filename
UpgradeLib-0.0.1.zip
File size
9.6 KiB
SHA-256
915a0190cdf33c82e2091655f820aae8efe12bb6535e81c924b743635879c520
Stored at
2026-10-10 06:21