Valheim1CompatBridges

v1.1.0·Updated 2026-09-18

BepInEx preloader that adds old API signatures back to Valheim 1.0 so pre-1.0 mods (Weedheim, WeedheimShip, Marketplace And Server NPCs) load again. Includes a script for Marketplace two remaining IL

About this mod Author’s original text

Valheim1CompatBridges

BepInEx preloader patcher for Valheim 1.0 (Unity 6). It adds the old method overloads, fields and

interface defaults back into assembly_valheim.dll at load time, so mods compiled against pre-1.0 builds stop

crashing with MissingMethodException, MissingFieldException: ZRoutedRpc.Everybody, `TypeLoadException:

VTable setup failed or Harmony Undefined target method`. No mod DLL is redistributed.

Tested with (client + dedicated server, BepInEx 5.4.2350):

| Mod | Result |

|---|---|

| MagicMike-Weedheim 2.0.4 | loads and works |

| MagicMike-WeedheimShip 1.0.2 | loads and works |

| KGvalheim-Marketplace_And_Server_NPCs_Revamped 9.8.1 | loads and works, with fix-kg-marketplace.ps1 applied once (see below); NPC map right-click (fashion) has no equivalent in 1.0 and does nothing; transmog icons in the inventory grid are not refreshed |

Install

Put the patchers/Valheim1CompatBridges folder into BepInEx/patchers/ on the client and on the

dedicated server (r2modman Mod Manager do this automatically). Look for

[Valheim1CompatBridges] Gotowe: N mostkow in BepInEx/LogOutput.log.

What it bridges

  • Inventory.Changed() → Changed(false, false) (original renamed to ChangedEx, game calls rerouted so

Harmony postfixes on Changed still fire)

  • ZRoutedRpc.Everybody const → static field
  • InventoryGrid.Element wrapper type (m_go, m_pos, mirrored fields), GetElement/GetHoveredElement

overloads returning it, empty List m_elements_compat (deliberately not named m_elements:

two same-named fields are legal in IL but make AccessTools.Field(type, "m_elements") throw

AmbiguousMatchException, breaking mods that inject ___m_elements by reflection, such as

AzuExtendedPlayerInventory and AzuAutoStore)

  • InventoryGrid.Awake() (called from OnEnable), Minimap.OnMapRightClick() stub
  • Hoverable.GetHoverOffset() default implementation
  • old overloads of: Character.Message, MessageHud.ShowMessage, EffectList.Create,

SEMan.AddStatusEffect (×2), ItemData.GetTooltip, Inventory.IsTeleportable, Humanoid.IsTeleportable,

Inventory.AddItem (12 params), Terminal.ConsoleCommand ctor (12 params), Terminal.ConsoleEventArgs

ctor, YesNoPopup ctor, Heightmap.Poke(bool), TerrainComp.Save(), Piece.SetCreator(long),

VisEquipment.Set*Item(string, …) (prefab name → hash)

Using Marketplace as well?

Marketplace has two breakages the preloader cannot reach, because they live in the mod's own IL: its

Hud.UpdatePieceList transpiler hardcodes local slot 12 for a Piece that Valheim 1.0 moved to 13

(InvalidProgramException, quest markers missing from the build menu), and it reads the old

InventoryGrid.m_elements field from IL. The mod is closed-source, so there is no upstream fix to wait for.

Run this once per machine, against your own copy of the DLL:

pwsh -File tools/fix-kg-marketplace.ps1 -Dll "/BepInEx/plugins/KGvalheim-Marketplace/kg.Marketplace.dll" -Apply

It reads the real slot numbers out of your assembly_valheim.dll instead of trusting a hardcoded one, is

idempotent, and refuses to guess if the layout it expects is gone. Keep the original DLL, and re-run it after

every Marketplace update. The script lives in the repo, not in this package.

Source, and why this is a new project rather than pull requests:

Install & use Install: BepInEx plugin

  1. The archive from playbuff is the mod itself — usually a BepInEx plugin (a .dll or a plugin folder once unzipped).
  2. Recommended: use a community mod manager (such as r2modman) — pick this game, import the mod, and the manager sets up BepInEx and its dependencies for you.
  3. Manual route: install the BepInEx loader in the game folder, then drop the unzipped .dll or plugin folder into BepInEx/plugins/.
  4. Launch the game — the BepInEx console logs every plugin it loads; seeing this mod in the log means it is installed.

Mods with listed dependencies need those installed too, or they will not load. Options are usually changed in-game or in the plugin's config file. In multiplayer, the host and every client need the same mods installed.

Dependencies

Install these first, or the mod will not work:

denikson-BepInExPack_Valheim

File & checksum

Filename
Valheim1CompatBridges-1.1.0.zip
File size
15.1 KiB