Please disclose if any significant portion of your mod was created using AI tools by adding the 'AI Generated' category. Failing to do so may result in the mod being removed from Thunderstore.
BirdheimVeinMiningCompat
Adds VeinMining (by BranchOfYore) to Birdheim's LoadingGuard whitelist so flights are not restricted to 100m.
| Date uploaded | 4 hours ago |
| Version | 1.0.2 |
| Download link | lupsy-BirdheimVeinMiningCompat-1.0.2.zip |
| Downloads | 9 |
| Dependency string | lupsy-BirdheimVeinMiningCompat-1.0.2 |
This mod requires the following mods to function
denikson-BepInExPack_Valheim
BepInEx pack for Valheim. Preconfigured with the correct entry point for mods and preferred defaults for the community.
Preferred version: 5.4.2360README
Birdheim VeinMining Compat
What
A lightweight compatibility patch that allows Birdheim (by hansenbansen) and VeinMining (by BranchOfYore) to work together without restricting your bird's flight range.
Why
To keep the world loaded around your bird while flying far away from your character, Birdheim monitors Harmony patches on core Valheim world-loading and cleanup methods (such as ZNetScene.RemoveObjects).
If Birdheim detects an unrecognized mod hooking into these methods, it triggers a built-in safety mechanism (LoadingGuard) and hard-caps your bird's maximum flight distance to 100 meters around your body—regardless of your Bird Bond skill level or config settings—logging the following warning:
[Warning: Birdheim] flights stay within 100 m of the body, in one loaded area: local.valheim.sharedmining on ZNetScene.RemoveObjects
Because VeinMining (BranchOfYore-VeinMining, internal BepInEx GUID local.valheim.sharedmining) hooks ZNetScene.RemoveObjects solely to handle destroyed ore segments and network synchronization, this is a false positive. Both mods are functionally compatible, yet Birdheim's safeguard blocks long-distance flights whenever VeinMining is installed.
How
Instead of modifying either mod's assembly files, this plugin runs once during BepInEx startup (Awake) after Birdheim has loaded:
- Reflection Lookup: Using Harmony's
AccessTools, it locates Birdheim's internalLoadingGuardclass without requiring a hard assembly reference (keeping it resilient against future Birdheim updates). - Whitelist Injection: It accesses the static
LoadingGuard.Knowncollection—the same internal whitelist Birdheim uses for other known-compatible mods—and adds VeinMining's internal GUID ("local.valheim.sharedmining") to it. - Result: When
LoadingGuard.Check()evaluates active Harmony patches upon loading a world, VeinMining'sZNetScene.RemoveObjectshook is recognized as safe. Birdheim disables the 100 m restriction, suppresses the warning, and restores your configured flight range under[Bond].
Installation & Multiplayer
- Client-side: Because Birdheim runs its
LoadingGuardcheck and area-loading logic locally on each player's client, this patch only needs to be installed on the client (for every player using both Birdheim and VeinMining). - Dedicated Servers: Installing it on a server is not required, though keeping it in a shared server modpack will not cause any issues.
- (Note: Multiplayer behavior has not been extensively tested yet, as this patch was developed and verified in singleplayer, but since it only modifies a local client-side whitelist, it should work identically in multiplayer sessions.)
Notes & Disclaimer
- Minimal Footprint & Safety: This mod does not patch any game methods directly, alter save data, or change how either mod operates. All it does is use Harmony's reflection utilities once on startup to append a single string (
"local.valheim.sharedmining") to an existing list in memory. Still, as with any Valheim mod, always back up your worlds and characters and use at your own risk. - Future Birdheim Updates: If the Birdheim team officially adds
local.valheim.sharedminingto their built-inLoadingGuard.Knownwhitelist in a future update, this compatibility patch will become obsolete (and harmless, as it checks whether the entry is already present before adding it). Conversely, should the Birdheim developers ever determine that VeinMining causes genuine issues with Birdheim's world-loading logic, an appropriate warning/disclaimer will be added here.
Credits
- Birdheim by hansenbansen — for the original bird companion & flight mod.
- VeinMining by BranchOfYore — for the original multiplayer vein-mining mod.
Contact & Bug Reports
- GitHub Issues: Report a bug or suggest a change
CHANGELOG
Changelog
1.0.2
- Added
CHANGELOG.mdto the Thunderstore package.
1.0.1
- Added GitHub repository link to
manifest.jsonandREADME.md. - Added contact and bug report section.
1.0.0
- Initial release.
- Adds VeinMining (
local.valheim.sharedmining) to Birdheim'sLoadingGuard.Knownwhitelist.