WKMusic

v1.0.1·Updated 2026-04-27

Displays your current Spotify track on the in-game HUD

About this mod Author’s original text

WKMusic

A BepInEx mod for White Knuckle that displays your current Spotify track on the in-game HUD.

Requirements

  • Windows
  • A Spotify Developer app with the redirect URI set to:
  • Spotify Premium (required by Spotify for playback state access)

Installation

  • Download the latest release and drop WKMusic.dll into:

BepInEx/plugins/

  • Launch the game. A browser window will open automatically asking for your Spotify Client ID and Client Secret.
  • Enter your credentials, click Connect Spotify, and authorize in the Spotify page that follows.
  • Done. The HUD appears in the top-right corner of the screen.

Credentials and tokens are saved locally - you won't be asked again on subsequent launches.

Getting Spotify credentials

  • Go to developer.spotify.com/dashboard and click Create app.
  • Fill in the form:
  • App name - anything you like, e.g. WKMusic
  • App description - can be left blank or any short text
  • Redirect URI - add exactly this:
  • Which API/SDKs are you planning to use? - check Web API, leave everything else unchecked
  • Click Save, then open the app's Settings page.
  • Copy your Client ID and Client Secret - you'll paste them into the setup page on first launch.

Configuration

The config file is generated at BepInEx/config/WKMusic.cfg after the first launch.

| Key | Default | Description |

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

| PlayerScale | 0.8 | Overall HUD scale (0.5 – 3.0) |

| CoverSize | 64 | Album art size in pixels (20 – 300) |

| CoverOpacity | 0.6 | Album art opacity (0 = invisible, 1 = fully opaque) |

| WorkerUrl | (built-in) | Cloudflare Worker URL - change only if you self-host |

How authorization works

The mod uses the Spotify Authorization Code flow. Your Client Secret is never sent from your machine in plain text - token exchange happens through a Cloudflare Worker that acts as a secure proxy.

[Game] opens browser -> accounts.spotify.com

[Browser] user authorizes -> returns code to Worker callback

[Worker] exchanges code for tokens using Client Secret

[Game] receives tokens, stores them in Windows Credential Manager

[Game] polls Spotify API directly every 300 ms

Self-hosting the Worker

This is completely optional. The mod ships with a built-in public Worker - you don't need to do any of this. Self-hosting is only useful if you want full control over the OAuth proxy (e.g. for privacy reasons or if the public Worker goes down).

The Worker source is in the worker/ directory. Deploy with Wrangler:

cd worker

npm install -g wrangler

wrangler login

wrangler secret put SPOTIFY_CLIENT_SECRET

wrangler deploy

After deploying, set WorkerUrl in BepInEx/config/WKMusic.cfg to your Worker's URL and update the Redirect URI in your Spotify app to match.

License

MIT

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
WKMusic-1.0.1.zip
File size
129.9 KiB