


Keep metals where they belong. Metals, ores, bars, and scrap — vanilla and mod-added — can no longer be carried through normal (wood) portals. The Ashlands stone portal (the "advanced" portal) still carries everything, exactly like vanilla.
Vanilla already blocks vanilla metals from wood portals, but many content mods add their own ores/bars and leave them teleportable, quietly undoing that restriction. PortalMetalLock closes that gap: it scans the item database (including items registered late by Jotunn-based mods) and flags matching materials as non-teleportable, so wood portals refuse them again.
Valheim wood portals refuse to teleport a player whose inventory holds any non-teleportable item. The Ashlands stone portal sets m_allowAllItems, which the game checks before the per-item test, so it keeps carrying everything with no extra handling.
This mod simply sets m_teleportable = false on matching items. Matching is restricted to items of type Material, so weapons, armour, tools, and jewellery (e.g. SwordBronze, SilverNecklace) are never affected — only raw metal/ore/bar/scrap.
Open the in-game Configuration Manager (default F1) → Portal Metal Lock, or edit baka.PortalMetalLock.cfg in BepInEx/config:
| Setting | Default | Description |
|---|---|---|
| Enabled | true |
Master switch. When on, matching materials are made non-teleportable. |
| MetalKeywords | copper,tin,bronze,iron,silver,blackmetal,flametal,ore,scrap,ingot |
Comma-separated, case-insensitive substrings. Any Material whose prefab name or localized name contains one is blocked. |
| ExtraPrefabs | (empty) | Comma-separated EXACT prefab names to also block, for mod metals the keywords miss. Use VNEI in-game to find exact names. |
| ExcludePrefabs | BronzeNails,LeatherScraps |
Comma-separated EXACT prefab names to never touch (false-positive guard). |
After changing keywords/prefabs, reload the world (or restart) so the item database is re-scanned.
This is a personal quality-of-life / rules mod. It only flips a per-item teleport flag; no world data, recipes, or items are otherwise changed. Safe to add or remove at any time.