
SpearRecall
Recall your original thrown spear for Eitr, with faded hotbar icons, private map pins and light beams. Supports standard modded spears. Client-side.Spear Recall
Recall your thrown spear for a configurable amount of Eitr. Find it before Mistlands with a private map pin and cyan light beam.
Client-side: install on your game client. The server and other players do not need the mod. Requires BepInEx 5.
Using it
- Throw a spear normally. Its original hotbar slot shows a faded icon and stays reserved by default. This is a visual placeholder, not a second item.
- After the spear hits a target or the ground and becomes lootable, click the scroll wheel (middle mouse) to recall it. The most recently thrown outstanding spear is selected.
- A successful recall spends 10 Eitr by default, returns the original dropped item to its original slot when available, and equips it when the game permits. Cost and range are configurable. The world's Eitr usage multiplier applies.
- With insufficient Eitr, an unavailable spear, a full inventory or an out-of-range spear, recall fails without spending Eitr. Recall waits briefly for normal network ownership and rechecks conditions before pickup.
- Walking over to pick it up normally costs no Eitr and clears its marker.
- Before Mistlands, follow the map pin or light beam. Both can be configured separately. Set EitrCost to 0 if you want free recall at any stage.
- Alt + middle mouse forgets the latest outstanding throw and releases its hotbar slot. The spear remains in the world. Use this if another player has taken it or it has disappeared.
Recall and Forget only operate during gameplay, not while inventory, chat, map or other menus are open. With an outstanding spear, the default middle click recalls it instead of triggering another secondary attack. Both shortcuts support rebinding and modifiers.
Item preservation and modded spears
Recall uses the game's normal pickup of the actual dropped spear after obtaining ownership. It never creates a replacement spear from its prefab. Quality, remaining durability, appearance variant, crafter information, world level, and custom item data follow the native throw/drop/pickup path. Normal throwing still consumes durability.
Spears are detected by their Spears skill and a Projectile that respawns the thrown item on hit; there is no vanilla spear-name whitelist. Modded spears following that path are supported automatically. IncludePrefabs supports weapons with another skill classification; ExcludePrefabs opts out individual weapons. Lists contain exact internal prefab names, separated by commas, and ignore case.
A temporary identifier in m_customData distinguishes the exact throw from identical nearby weapons and survives native item serialization. It is removed after your successful recovery. Other mods' custom-data entries are retained. Stackable modded spears tag only the thrown unit; retrieved units remain separate during pickup to prevent native stacking from discarding their individual metadata. The remaining inventory stack is not tagged.
Mods with their own projectile implementation, replacement-item spawning, custom inventory, or item data kept outside Valheim's normal ItemData/clone/serialization system may need specific integration. Arbitrary spear mods are not guaranteed compatible. Avoid combining automatic weapon-return mods without testing first.
Client-side limits
The spear must exist as a loaded item drop within the recall range. Recall does not summon in-flight projectiles or retrieve items from unloaded regions, other players, or containers. It cannot restore a spear that the game or another mod already destroyed. Pins retain the last observed landing location for the current session; after reconnecting, tagged spears are rediscovered when their area loads. Session pins are private and are not saved to or shared from your map.
Other players can still pick up your spear. A client-only mod cannot enforce ownership or Eitr costs on other clients. Their pickup or a zone unload can leave a last-known marker and reserved slot; use Forget if needed. For stackable custom spears, other unmodded peers can still apply vanilla stacking when they own the drop.
Installation
Mod manager: import Dyls123-SpearRecall.zip or SpearRecall-1.0.0.zip as a local mod, or install through Thunderstore once published. Both packages use the same layout.
Manual: install BepInEx for Valheim, then copy SpearRecall.dll from the ZIP into BepInEx/plugins/Dyls123-SpearRecall/. Keep only one copy of the DLL. The package does not contain game assemblies or test plugins.
First launch creates BepInEx/config/Dyls123.SpearRecall.cfg.
| Setting | Default |
|---|---|
| General / Enabled | true |
| Recall / EitrCost | 10 |
| Recall / MaximumRange | 100 metres; loaded drops only |
| Controls / Recall | Mouse2 |
| Controls / Forget | Mouse2 + LeftAlt |
| Hotbar / ReserveOriginalSlot | true |
| Tracking / MapPin | true |
| Tracking / Beacon | true |
| Tracking / BeaconHeight | 3 metres |
| Tracking / BeaconWidth | 0.12 metres |
| Tracking / LightRange | 4 metres |
| Compatibility / IncludePrefabs | empty |
| Compatibility / ExcludePrefabs | empty |
Edit the config while the game is closed, or use a compatible in-game config manager. Live config-manager changes apply to the next action. Editing the file directly requires a restart or config reload. Disabling slot reservation allows another item to occupy the old slot; recovery then uses a free slot.
Building and validation
Built against the locally installed Valheim assemblies with .NET 9, targeting netstandard2.1. Only BepInEx is a runtime dependency. The local SDK reports System.Net.Http/System.IO.Compression reference-version warnings from the game's assemblies; this mod does not use those APIs.
dotnet build ./src/SpearRecall.csproj -c Release
./scripts/Test-Unity.ps1
./scripts/Package.ps1
The isolated Unity test runner uses separate plugin and save directories. It exercises production patches, native item cloning and serialization, real inventory pickup, Eitr costs and failures with synthetic vanilla-style and modded spear fixtures. Network ownership/destruction, equipment animation and HUD feedback are stubbed. It does not load or modify user worlds and does not establish compatibility with a particular third-party spear mod or validate real multiplayer. See docs/TESTING.md in the versioned package for gameplay checks.
Changelog
1.0.0
Initial release: Eitr recall, original-item preservation, behaviour-based modded spear detection, faded hotbar icons with slot reservation, private map pins and configurable beacons.