SlotMachineRenderTextureFix
Fixes the Reel of Fortune (slot machine) display not rendering on high resolutions (>1440p). Clamps the 8x supersampled RenderTexture to the GPU's max texture size.
About this mod Author’s original text
SlotMachineRenderTextureFix
Fixes the Reel of Fortune slot machine display not rendering in How to Fish on high resolutions (>1858px screen height), on both Linux/Proton and Windows.
Cause
GameInfo.Awake() sizes the slot machine's RenderTexture as:
int value = (int)(Screen.height * 0.25f); // clamped to 1440
int num = (int)(value * 4.40625f);
_slotMachineTexture.width = num * 8; // up to 19032 px
_slotMachineTexture.height = value * 8;
At screen heights above ~1858px this exceeds the GPU hard limit (SystemInfo.maxTextureSize, typically 16384). RenderTexture.Create then fails silently every frame — you'll see this spamming the Unity log:
RenderTexture.Create failed: requested size (19032, 4320) is too large for the current maxRenderTextureSize(16384).
RenderPass: Unable to find surface for attachment 0
EndRenderPass: Not inside a Renderpass
The secondary camera that draws the reels (SlotMachine._slotCam.Render()) writes into a dead render target, so the display stays black / missing.
Fix
Harmony postfix on GameInfo.Awake clamps _slotMachineTexture proportionally to SystemInfo.maxTextureSize and re-creates it before the camera renders into it. Works at any resolution; no config.
Example at 4K: 19032×4320 → 16384×3720.
Install
Requires BepInExPack for How to Fish.
Drop SlotMachineFix.dll into BepInEx/plugins.
Verify
After launch, check BepInEx/LogOutput.log:
[Info:SlotMachineFix] SlotMachineFix loaded
[Warning:SlotMachineFix] Clamped slot RT 19032x4320 -> 16384x3720 (max 16384) Create=True
No more RenderTexture.Create failed spam in Player.log.
Build
dotnet build src/SlotMachineFix/SlotMachineFix.csproj -c Release
output: src/SlotMachineFix/bin/Release/netstandard2.1/SlotMachineFix.dll
Package./package.sh # builds, stages manifest+readme+dll+icon into dist, zips to dist/SlotMachineFix.zip
Repo layout
icon.svg source vector icon (256×256)
icon.png rendered icon (rsvg-convert)
manifest.json metadata (dependency: BepInEx-BepInExPack-5.4.2305)
README.md this file
package.sh build + package script
src/SlotMachineFix/ plugin project
Install & use Install: follow the bundled instructions
- Unzip the archive from playbuff and read the bundled readme / instructions first.
- 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.
- For a manual install, put the mod files into the matching Mod / plugins folder inside the game directory.
- 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.
Install these first, or the mod will not work: