You are viewing a potentially older version of this package. View all versions.
w00dst0ckOos-GK2LaboratoryFolioHelper-0.3.2 icon

GK2LaboratoryFolioHelper

Pin known alchemy formulas, track ingredients, and load mixes faster in Graveyard Keeper 2.

Date uploaded a week ago
Version 0.3.2
Download link w00dst0ckOos-GK2LaboratoryFolioHelper-0.3.2.zip
Downloads 107
Dependency string w00dst0ckOos-GK2LaboratoryFolioHelper-0.3.2

README

GK2 Known Formula Helper

A BepInEx mod for Graveyard Keeper 2 that improves the alchemy folio and laboratory workflow.

Version 0.3.2 adds ranked alternative laboratory mixes, optional HUD positioning support for GK2RecipePin and Kebo Recipe Pins, plus bundled typography support for readable helper text.

Features

  • Pin known alchemy formulas from the folio.
  • Shows pinned formulas directly on the HUD.
  • Compact recipe cards with:
    • Ready / Missing status
    • owned vs. required ingredient counts
    • buyable ingredients
    • vendor name and stock when available
  • Automatically selects the best known ingredient mix for each formula.
  • Displays powder-free alternative mixes when a suitable known recipe exists.
  • Open the normal alchemy folio directly from the laboratory result slot.
  • Select a known formula directly from the folio.
  • Automatically load the best matching mix into the laboratory.
  • Shows up to ten known mix variants for the selected formula.
  • Switches between variants with < / > buttons or Left Arrow / Right Arrow.
  • Updates the laboratory ingredient slots immediately when a variant changes.
  • Craftable mixes are preferred when the required resources are already available.
  • Laboratory mix selection considers available crafting resources and accessible storage.
  • Recipes with missing ingredients are automatically pinned.
  • Incomplete recipes are still loaded into the laboratory so available ingredients remain visible at the station.
  • Normal folio pin / unpin behavior is preserved when the folio is opened normally.
  • Controller support for folio recipe selection.
  • Optional compatibility with:
    • Pin My Recipe
    • GK2 Shopping List
    • GK2RecipePin
    • Kebo Recipe Pins

These integrations are optional. The mod does not require any of them.

How it works

The helper evaluates your known alchemy formulas and chooses the most useful ingredient combination based on the resources currently available to the crafting system.

Pinned formulas are displayed directly on the HUD so you can quickly see:

  • whether a recipe is ready
  • which ingredients are missing
  • how many ingredients you currently own
  • whether missing ingredients can be purchased
  • vendor name and stock when available
  • a powder-free alternative when one is known

Laboratory folio workflow

When the laboratory does not currently contain a valid mix, the empty result slot can be used to open the normal alchemy folio.

Selecting a known formula from the folio will:

  1. Find the best known ingredient mix for the formula.
  2. Prefer a mix that can already be crafted with the currently available resources.
  3. Load that mix directly into the laboratory.
  4. Automatically pin the formula if ingredients are still missing.

The recipe is still loaded when incomplete, allowing the laboratory to show the available and missing ingredients normally.

When the alchemy folio is opened outside this laboratory selection mode, clicking formulas continues to pin or unpin them normally.

Mix variants

After selecting a formula from the laboratory folio, the helper ranks up to ten known mixes using the same resource-aware rules as the initial selection. If at least one mix is craftable, only craftable variants are shown. If none is currently craftable, the helper still shows up to ten useful variants with missing ingredients. The first mix loads automatically. Use the < and > buttons beside the ingredient slots, or Left Arrow and Right Arrow (Comma and Period also work), to load another variant. The ingredient slots, counts and craft result are redrawn immediately.

The variant arrows are placed to the left and right of the laboratory ingredient slots. Their positions adapt to the two-slot Laboratory I and the three-slot Laboratory II. With a controller, press D-pad left/right while variants are active to switch mixes. The on-screen + and − controls remain available for changing the craft count.

Powder-free alternatives

Some alchemy formulas have multiple valid ingredient combinations.

If the preferred mix contains alchemic powder and a known alternative without powder exists, the HUD can display the powder-free combination underneath the main recipe.

This makes it easier to preserve powders when another valid combination is available.

Requirements

  • Graveyard Keeper 2
  • BepInEx 5
  • .NET Framework 4.7.2 target

Tested with:

  • Graveyard Keeper 2 1.007.1
  • BepInEx 5.4.23.5

Installation

  1. Install BepInEx 5.
  2. Create:
BepInEx/plugins/GK2KnownFormulaHelper
  1. Copy GK2KnownFormulaHelper.dll into that folder.
  2. Start or restart the game.

Updating

Close the game and extract the Nexus ZIP into the game folder, merging its BepInEx folder with the existing one. Replace the previous helper DLL. If your older installation uses another plugin folder or the filename GK2LaboratoryFolioHelper.dll, remove that old helper copy so only one version is loaded. Keep your configuration file; the plugin ID and configuration filename are unchanged.

The HUD position preview is disabled by default. If you enabled it while testing, set Enabled = false in [Debug.HudPositionPreview] for normal play.

Building

Restore tools and build the project:

dotnet tool restore
dotnet tool run csharpier format .
dotnet build -c Release

The compiled DLL is created at:

bin/Release/net472/GK2KnownFormulaHelper.dll

Release packaging and publishing are handled by private maintainer tooling and are not part of this repository.

Release packaging

Release packaging for Nexus Mods and Thunderstore is handled with private maintainer tooling.

The public repository contains the source code, build configuration, manifest metadata, assets and licenses required for development, but does not include the maintainer's release automation scripts.

Compatibility

Optional mod integrations are detected dynamically at runtime and are not hard compile-time dependencies.

Compatibility code covers Pin My Recipe, GK2 Shopping List, GK2RecipePin and Kebo Recipe Pins 2.5.1. The HUD interfaces have been checked against locally available DLLs. The combined in-game layout has not yet been verified with every mod; other HUD mods and very tall pin lists may still need layout adjustments.

Pin My Recipe

The Known Formula Helper HUD reacts to compatible recipe pin elements and can reposition itself to avoid overlapping the Pin My Recipe HUD.

GK2 Shopping List

The HUD detects the visible GK2 Shopping List panel and can position alchemy formula cards below compatible HUD elements when necessary.

GK2RecipePin and Kebo Recipe Pins

The helper also detects the GK2RecipePin tracker and the Kebo Recipe Pins 2.5.1 HUD, including when these mods load after BepInEx.

Alchemy formula cards are positioned below visible panels that overlap their horizontal screen area. Kebo lists placed elsewhere on screen do not shift the formula cards unless they reach into that area. Hidden panels, including Kebo's list when all ready pins are hidden, do not reserve space.

The layout reacts to panel creation, resizing, visibility changes and Kebo's positioning updates. Install either mod separately with its own required loader and dependencies; neither is bundled with the helper.

Controller support

The normal alchemy folio remains controller navigable when opened from the laboratory.

Formula selection uses the existing folio navigation instead of a separate custom recipe picker.

When mix variants are active, controller focus follows the laboratory row: result, left arrow, each available ingredient slot, right arrow, Craft Max, and back to result. Laboratory I contributes two ingredient slots; Laboratory II contributes three.

Press R3 anywhere in the game to remove the most recently added formula pin; opening the folio is not required. If another mod uses R3, disable RemoveLastPinWithR3 = false under [Input] in the helper configuration.

UI typography

The helper uses the optional Alegreya Sans TMP font by default for readable helper text. To switch back to the game's font, set this in the BepInEx configuration:

[UI]
FontStyle = Game

Game keeps the current game font. Sharp applies Alegreya Sans only to formula names, ingredient and vendor text, statuses, counts, alternative recipe labels, and helper preview text. Variant arrows, controller symbols, navigation glyphs, and other symbolic controls retain their cloned vanilla font and material.

Sharp requires assets/knownformulahelper_fonts.bundle beside the plugin DLL. If it is missing or does not contain the required glyphs, the helper uses the game font and logs one fallback warning. The bundle is optional and is never loaded globally.

Credits and inspiration

A big thank you to the authors of Pin My Recipe and GK2 Shopping List.

Both mods provided great ideas for presenting pinned recipes, ingredient information, and compact HUD elements in a clear and useful way.

GK2 Known Formula Helper is an independent implementation, but its HUD design and usability were strongly inspired by ideas found in these mods.

Special thanks for the inspiration around:

  • compact pinned recipe layouts
  • readable ingredient presentation
  • HUD positioning and usability
  • keeping useful information visible without opening additional windows

Alegreya Sans is Copyright 2013 The Alegreya Sans Project Authors and is licensed under the SIL Open Font License 1.1. The complete license is included with the font asset at LICENSES/AlegreyaSans-OFL.txt.

Compatibility with Pin My Recipe and GK2 Shopping List is optional and handled dynamically at runtime.

Development notes

To test HUD positions without installing other pin mods, set Enabled = true under [Debug.HudPositionPreview] in BepInEx/config/w00dst0ckOos.GK2LaboratoryFolioHelper.cfg and restart the game. In a loaded save, F7 advances through simulated panel positions and F6 goes back. The cases include small/tall panels, right/left/center placement, two panels, and hidden panels. A temporary formula card appears if no formulas are pinned. Cycle to Off to end the preview, or set Enabled = false and restart to disable it completely. This tests positioning; the other mods' loaders are not simulated.

  • Narrow Harmony patches
  • Preserve vanilla crafting behaviour
  • No save-data changes
  • No hard dependency on optional HUD mods
  • No per-frame polling for normal pin updates

Changelog

See CHANGELOG.md.

License

This project is licensed under the MIT License.

CHANGELOG

Changelog

All notable changes to GK2 Known Formula Helper are documented here.

[0.3.2] - 2026-10-04

Added

  • Added laboratory ingredient-slot filtering.
  • Recipes that require more ingredient slots than the active laboratory provides are now disabled in the laboratory folio.

Fixed

  • Selected laboratory mix variants now remain selected after closing the laboratory.
  • Prevented Laboratory I from loading recipes that require three ingredient slots.
  • Improved handling of unsupported recipes in laboratory selection mode.

[0.3.1] - 2026-10-02

Added optional GK2 Mod Framework integration while keeping the main mod fully standalone. Added Framework settings for maximum laboratory mix variants and UI font style. Added configurable laboratory mix variant limit. Improved the laboratory pin card layout so formula titles have more horizontal space. Kept ingredient quantities in a dedicated right-aligned column. Updated local build, install, and release packaging to include the optional Framework bridge DLL.

[0.3.0] - 2026-10-02

  • Show up to ten craftable laboratory mix variants when available.
  • Position variant arrows beside the ingredient slots for Laboratory I and II.
  • Improve controller navigation through the laboratory controls.
  • Add optional global R3 removal of the most recently added helper pin.
  • Add optional Game/Sharp typography modes for readable helper text.
  • Keep variant arrows and symbolic controls on their vanilla game font.

[0.2.8] - 2026-10-01

  • Move the mix controls into the visible laboratory ingredient area.
  • Place the mix arrows beside the laboratory ingredient slots for both laboratory sizes.
  • Put the Ready/Missing status directly above the ingredient row.
  • Link controller focus through result, variant arrows, all ingredient slots, Craft Max and back to result.
  • Bind global R3 input to remove the most recently added formula pin.
  • Apply the same controller focus transitions used by the vanilla Craft Max button.

[0.2.7] - 2026-10-01

  • Rename the alternative pin recipe label to Alt. recipe.

[0.2.6] - 2026-10-01

  • Place compact mix navigation controls below the alchemy frame, using the game's queue-arrow style when available.
  • Keep the controls clickable and register them with the laboratory's gamepad navigation.
  • Keep D-pad left/right switching available while the laboratory window is open.

[0.2.5] - 2026-10-01

  • Replaced the separate overlay arrows with compact controls inside the laboratory UI.
  • Kept the controls clickable without introducing a full-screen overlay.

[0.2.4] - 2026-10-01

  • Fixed variant controls being hidden by the laboratory canvas despite successful mix switching.
  • Rendered the < / > controls on a dedicated screen overlay canvas with a high sorting order.
  • Added a log entry confirming that the variant controls were created.

[0.2.3] - 2026-10-01

  • Fixed variant controls appearing outside or clipped by the laboratory window.
  • Re-anchored the controls to the root UI canvas and kept them clickable beside the result slot.
  • D-pad left/right now switches active variants directly.
  • Fixed publish.ps1 -InstallLocal to install into the documented BepInEx/plugins/GK2KnownFormulaHelper folder.

[0.2.2] - 2026-10-01

  • Added up to ten ranked known laboratory mixes for the selected formula.
  • Added < and > controls next to the laboratory result slot.
  • Added Left Arrow/Right Arrow and Comma/Period keyboard shortcuts to switch variants.
  • Loading a variant redraws the laboratory ingredients and availability immediately.
  • Moved the variant controls beside the result slot so they do not cover the game's + / − controls.
  • Re-anchored the variant controls to the laboratory root canvas so both buttons remain visible and clickable.
  • Added direct D-pad left/right switching while variants are active; the on-screen + / − controls remain available for craft count.

[0.2.1] - 2026-09-30

  • Added an opt-in HUD position preview with simulated external panels and a temporary sample card, so positions can be tested without installing other pin mods.
  • Added optional HUD compatibility with GK2RecipePin and Kebo Recipe Pins 2.5.1.
  • Detect these mods through their loaded assemblies, including late loading and replacement assemblies.
  • Position alchemy cards below visible overlapping pin panels and react to panel layout and visibility changes.
  • Ignore the new panels when hidden or positioned outside the alchemy HUD's horizontal screen area.

[0.2.0] - 2026-09-29

  • Added direct alchemy folio access from the laboratory result slot
  • Added direct recipe selection from the folio
  • Selected formulas now load the best matching mix into the laboratory
  • Best laboratory mix selection now considers current crafting resources
  • Connected storage is considered when choosing a craftable mix
  • Missing recipes are automatically pinned for ingredient tracking
  • Recipes with missing ingredients are still loaded into the laboratory
  • Added powder-free recipe alternatives
  • Improved ingredient availability handling
  • Preserved normal folio pin/unpin behavior
  • Removed the old custom pinned-recipe dialog
  • Improved gamepad handling for the folio-based workflow

[0.1.0] - 2026-09-29

Added

  • Initial public release.
  • Pin known alchemy formulas from the folio.
  • Up to four formula pins.
  • HUD display for pinned formulas.
  • Automatic best-mix selection.
  • Ready / Missing recipe status.
  • Player inventory owned counts.
  • Buyable ingredient detection.
  • Vendor name and vendor stock display.
  • Laboratory II pinned recipe picker.
  • Automatic loading of selected pinned recipes.
  • Controller navigation for the pinned recipe picker.
  • Controller A-button recipe selection.
  • Inventory-driven HUD refreshes.
  • Refresh after completed player inventory transfers.
  • Optional Pin My Recipe compatibility.
  • Optional GK2 Shopping List compatibility.

Technical

  • BepInEx 5 integration.
  • HarmonyX runtime patching.
  • Target framework: .NET Framework 4.7.2.
  • Optional mod integrations use runtime detection and reflection.
  • No save-data changes.