Gjallarhorn

v0.3.0·Updated 2026-09-22

Server-side Viking death announcements, boss-defeat chronicles, and join/leave notices. Vanilla clients supported; installing it client-side upgrades the feed to exact killer and cause of death.

About this mod Author’s original text

Gjallarhorn

A server-side Viking kill feed and roster. Player deaths land in the top-left message feed

and the chat window; boss defeats get the centre-screen banner; players arriving and leaving

are announced in the same voice.

Named for Heimdall's horn — the one sounded to announce across all nine realms.

Who needs to install this

The server needs it. Every client is optional, and the mod is not version-enforced.

  • On the server it does all the work — detection, wording, and broadcasting. It reaches

players over ShowMessage and ChatMessage, two RPCs vanilla Valheim already registers,

so a server full of unmodded players still sees the whole feed.

  • On a client it is purely additive. Installed, that player's deaths are reported with the

real cause and the real killer. Absent, their deaths still announce, but the killer is a

proximity guess and non-combat causes read as generic.

Mixed populations are fine and expected. Nobody is refused at connect.

Why clients change the quality of the feed

Everything specific about a death — who swung, what kind of damage, whether another player

did it — lives in Character.m_lastHit, set in Character.Damage. That runs on whichever

peer owns the dying character's ZDO, which is the victim's own machine. A dedicated server

never instantiates a Player component for a remote client and can never read it.

So the server falls back to what it can see: the dead flag on each connected player's

replicated character ZDO, and whatever hostile creatures are standing near the corpse. That

gets the ordinary case right — you died to the thing that was hitting you, and it is still

there — and gets ranged kills, deaths on a fleeing mob, and every non-combat cause wrong.

| | Vanilla client | Client with Gjallarhorn |

|---|---|---|

| Death announced | yes | yes |

| Victim, position, biome | exact | exact |

| Killer creature | nearest hostile within 20m, a guess | exact |

| Star rank | from the guessed creature | exact |

| PvP kills | never identified | exact, with the killer named |

| Fall, drowning, fire, freezing, poison, falling trees | read as generic | each has its own message |

| Carts, boats, structures, turrets, the edge of the world | read as generic | grouped as environmental |

Boss defeats are exact either way. The server sees them through

ZoneSystem.RPC_SetGlobalKey, which is registered server-side only.

Joins and leaves

Vanilla announces arrivals but never departures, and the asymmetry is not an oversight. The

arrival line is a chat shout the joining client sends itself, from Game.SpawnPlayer the

first time it spawns. A client that is leaving cannot shout, so there is nothing to mirror it

with. Both halves have to be observed server-side instead.

Departures are caught at ZNet.Disconnect, the single funnel a clean quit, a dropped

connection and a kick all pass through. Arrivals come from a diff over the peer list on the

server tick, gated on the player actually having a character in the world, so someone who

backs out at character select is never announced. That same diff backs up the departure hook:

if a game update ever moves Disconnect, leaves announce a tick late instead of silently

stopping.

Leaves come in three wordings, because a crash should not read as a cheerful farewell:

| How they left | Pool |

|---|---|

| Quit to menu or desktop | LeaveMessages |

| Crash, alt-F4, network loss | LeaveTimeoutMessages |

| Kicked, banned, not on the permitted list | LeaveKickedMessages |

RejoinQuietPeriod keeps a flapping connection from filling the feed: a player who rejoins

inside the window is not announced, and the leave that follows is suppressed too — unless the

session outlasted the window, in which case it was a real visit and its ending is reported.

Identity is the peer's platform id, so it survives reconnects and does not collide when two

players pick the same name.

Leaves are announced by default. Arrivals are not: vanilla already covers them, so

AnnounceJoins starts off, and tur

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_ValheimValheimModding-Jotunn

File & checksum

Filename
Gjallarhorn-0.3.0.zip
File size
142.7 KiB