Lethal Company
Install with App

Details

Latest version
0.2.1
Last Updated
First Uploaded
Downloads
224
Likes
0
Size
12KB
Dependants

XpBuy

LethalRPG upgrades cost XP instead of quota money, and your progress is written to the save file when you leave a game.

XP is earned the way LethalRPG already earns it: scrap you carry to the ship, monsters you kill, days survived and quotas completed. The XP price of an upgrade is its money price divided by a ratio (default 4), so a $40 level costs 10 XP.

Why this mod also touches saving

LethalRPG only writes its data into the save file when the game saves while the ship is in orbit (GameSavesNow requires inShipPhase). Quitting from inside the facility therefore throws away the day's XP and any level bought that day. XpBuy saves LethalRPG progress on quit and on disconnect, so a normal exit never loses progress. While hosting it also autosaves every AutosaveSeconds (default 60 s), so a crash or a forced close costs at most a minute. Turn the hooks off with SaveOnQuit = false, autosave with AutosaveSeconds = 0.

Networking

Not client-side. XpBuy changes how upgrades are priced and how the LethalRPG save is written, so every player in the lobby must install it, together with LethalRPG. Prices are computed on the buyer's client; only the host writes the save file.

It hooks GameNetworkManager.OnApplicationQuit and GameNetworkManager.Disconnect to flush progress into the existing save file, and while hosting it periodically calls LethalRPG's own save routine. Nothing else about networking changes: no custom packets, no extra RPCs, no netcode prefabs.

  • No data leaves your machine. No HTTP requests, no external servers, no telemetry, no analytics.
  • The mod does not phone home and does not update itself.
  • Your save file is written locally, in the same format LethalRPG already uses.

AI disclosure

This mod's code was written with AI assistance (DeepSeek, through an agentic coding tool). The assembly carries the same disclosure in its metadata (AI_Assisted_Creation, AI_Model_Vendor).

No AI-generated art, audio, model or texture assets are included in this package: the icon is the only image, and the mod ships no game assets of its own.

Requirements

  • BepInEx 5.4.23.5+
  • LethalRPG 0.10.x
  • Everyone in the lobby needs both. Prices are computed on the buyer's client; only the host writes the save.

Config

Key Default Meaning
Enabled true XP pricing master switch
XpPerMoneyRatio 4 XP price = money price / ratio
SaveOnQuit true Save LethalRPG progress when leaving a game
AutosaveSeconds 60 While hosting, write progress every N seconds (0 = off)

Suggested LethalRPG rules for an XP-driven run

ResetOnGameOver = false (otherwise levels bought with permanent XP are wiped on a crew wipe), ProgressScope = Profile, UpgradeOwnership = Individual, XP sources around XpPer100Scrap = 2, XpPerKill = 0.5, XpPerSurvivedDay = 0, XpPerQuota = 8.

Thunderstore development is made possible with ads. Please consider making an exception to your adblock.