WK huoyan1231COMLib

v1.1.0·Updated 2026-07-20

Common library for huoyan1231's White Knuckle mods. Provides shared leaderboard management utilities — automatically disables leaderboards when any dependent mod exceeds the vanilla Trinket budget, an

About this mod Machine translation

WK_huoyan1231COMLib

White Knuckle BepInEx Common Library — Shared utilities for huoyan1231's White Knuckle mods

White Knuckle BepInEx public component library - a shared tool library for the huoyan1231 series White Knuckle Mod

English

What is this?

WK_huoyan1231COMLib is a shared BepInEx library (plugin) used by huoyan1231's White Knuckle mods.

It provides common utilities that multiple mods can share, avoiding code duplication.

Features

Leaderboard Management

Ported and extended from WKUnlimitedTrinkets:

  • Automatic leaderboard disabling: When any dependent mod requests it (e.g. when the Trinket budget is exceeded), the library sets CL_Leaderboard.WK_Leaderboard_Core.disableLeaderboards = true
  • Multi-mod coordination: Multiple mods can register/unregister disable requests independently. Leaderboards are only restored when all requesters have cleared their requests.
  • Auto-reset on run end: Leaderboard state is fully reset after each run (M_Gamemode.Finish) to prevent state leaking into subsequent runs.

Achievement Management (Steam)

Intercepts the game's single Steam-achievement upload entry point — CL_AchievementManager.GameAchievement.GetSteamAchievement() (which calls new Achievement(id).Trigger(true)) — via a Harmony prefix:

  • Disable Steam achievement uploads without losing progress: When disabled, the Steam Trigger call is skipped, so your real Steam achievement profile is never polluted. In-game flagged state and XP are kept intact.
  • Multi-mod coordination: Multiple mods can register/unregister disable requests independently. Steam uploads stay blocked until all requesters have cleared.
  • Global hard switch: A separate SetSteamAchievementsDisabled(bool) flag for an unconditional, run-independent block.
  • Auto-reset on run end: Per-run disable requests are cleared after each run (M_Gamemode.Finish); the global hard switch persists.

Why intercept GetSteamAchievement instead of SetAchievementValue?

SetAchievementValue also drives in-game progression (flags, XP, unlock animations). Blocking there would break the game. GetSteamAchievement is the only method that touches Steam, so intercepting it disables uploads while leaving gameplay untouched.

Public API for Mod Developers

Other mods can use the LeaderboardManager and AchievementManager static classes:

// Leaderboards — disable for this run (call from your StartFreshGamemode patch)

LeaderboardManager.DisableForThisRun("your.mod.guid");

LeaderboardManager.TryRestore("your.mod.guid"); // re-enable your request

bool exceeded = LeaderboardManager.IsTrinketBudgetExceeded(trinketNamesList);

// Steam achievements — disable uploads for this run (keeps in-game progress)

AchievementManager.DisableForThisRun("your.mod.guid");

AchievementManager.TryRestore("your.mod.guid"); // clear your request

AchievementManager.SetSteamAchievementsDisabled(true); // unconditional global block

bool blocked = AchievementManager.IsSteamAchievementsDisabled(); // query current state

Installation

  • Ensure BepInEx 5.x is installed (via Gale, R2MM, or manual)
  • Place WK_huoyan1231COMLib.dll in:

/BepInEx/plugins/

  • Install any dependent mods that require this library

Configuration

A config file will be generated in BepInEx/config/ after first run:

huoyan1231.whiteknuckle.comlib.cfg

| Setting | Default | Description |

|---------|---------|-------------|

| EnableLeaderboardManagement | true | Set to false to disable all leaderboard management patches |

| EnableAchievementManagement | true | Set to false to disable the Steam achievement interception patches |

Dependencies

| Mod | Purpose |

|-----|---------|

| WKUnlimitedTrinkets | Leaderboard logic was ported from here |

Chinese

What's this?

WK_huoyan1231COMLib is a BepInEx shared library plug-in for huoyan1231's White Knuckle series of Mods.

It provides multiple Mods with reusable public tools to avoid repeatedly implementing the same logic.

Function

Ranking management

Ported and extended from WKUnlimitedTrinkets:

  • Automatically di …

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.

Dependencies

Install these first, or the mod will not work:

BepInEx-BepInExPack

File & checksum

Filename
WK_huoyan1231COMLib-1.1.0.zip
File size
12.7 KiB
SHA-256
2ab80c1df41c3cef2ed2f2bf0fc632eaa10313a6e7e3249ab264d95592b0794a
Stored at
2026-10-12 00:54