Skip to main content

Factions

Added in v1.4.0. Every race is grouped into one of three factions alongside a handful of vanilla creatures. None of your faction's mobs attack you first, and several of them go a step further and become merchants.

Tester-shaped history

Almost everything specific on this page arrived as a bug report. The truce failed on dedicated servers (v1.4.6), fell apart during raids (v1.4.8), left whole families of mobs half-listed (v1.4.8, v1.4.19), stopped mobs retaliating at all (v1.4.19) and broke the shop window outright on Valheim 1.0 (v1.4.18). If a faction mob attacks you when it should not, or a shop behaves oddly, that is still worth reporting.

The three factions​

FactionRacesMobs
Black ForestTrenta, Trol, FurlingGreyling, Greydwarf, Greydwarf Elite, Greydwarf Shaman, Fuling, Fuling Archer, Fuling Berserker, Fuling Shaman, Troll
MountainSkadi, Fenrir, DvergarDrake (Hatchling), Wolf, Ulv, Fenring, Fenring Cultist, every Dverger variant
SwampAswid, Draugh, SkeletonGhost, Skeleton (melee-only variant included), Rancid Remains, Draugr, the bow draugr, Draugr Elite, Wraith, Leech, Abomination, Blob, Oozer, Growth
Half-listed families were the whole problem

Matching is by exact prefab name, so every variant of a creature has to be named in its own right — and several families were only half there. v1.4.8 added the plain Fuling and the Archer, which is why a Fuling camp used to open fire on a Trol while the Berserkers stood down. v1.4.19 added the Greyling (a Furling or a Trol was at peace with the whole Black Forest and still fought the smallest thing in it), vanilla's melee-only skeleton and the bow draugr — which is why an Aswid found friendly skeletons in one crypt and hostile ones in the next. It was never the biome; it was which variant that particular spawner places.

Quest bosses are kept out on purpose: Hildir's skeleton, the Goblin King and the Hildir brothers are not somebody's kin.

Peace only runs one way within a faction's own members - a Dvergar and a Skadi are both Mountain, but that doesn't make the Dvergar peaceful toward Skadi, only toward the listed mobs. Player-versus-player hostility is never touched.

How this relates to each race's own hostility rules​

Several races already had their own hostility exemptions before Factions existed - see Race overview for Draugh, Fenrir, Furling, Skeleton, Trenta and Aswid's progressive truces, each implemented as its own BaseAI.IsEnemy patch. Factions is additive on top of those, not a replacement: a race already exempted from a mob by its own rule stays exempted either way. What Factions actually adds is coverage for the three races that had none before - Trol, Skadi and Dvergar had zero built-in peace with anything until Factions closed that gap - plus the trading half, which nothing else in the mod provides, for every race including the six that already had peace.

Trading​

A faction mob that can talk becomes a merchant the instant it spawns: approach one you're at peace with and press E to open its shop. Buying and selling always happen at the same price - nothing is a loss to sell back to the mob you bought it from.

Not every faction mob can trade. Creatures with no talk-capable rig (Leech, Abomination, Blob, the Drake) are folded into a relative's shop instead - you'll still see their trophies and drops for sale from whichever mob in their family does the talking.

See the faction merchant catalogue for every item every shop buys and sells.

A merchant mob stops wandering and stops attacking while you're actively trading with it, and stays passive for a few seconds after you close the shop.

Broken by Valheim 1.0, fixed in v1.4.18

1.0 added a name, tooltip, buy effects and unlock keys to every shop item, and the shop window reads some of them without checking they exist. The merchants' goods were missing them, so pressing E threw an error and nothing opened. Buying would have hit the same wall. Haldor and Hildir's Dvergar discount broke for the same reason — the discounted copies were rebuilt with only the old fields, which also cost items whatever they unlock, like Haldor's extra inventory row. The discount now copies the whole item and changes only the price.

Turning it off​

Since v1.4.9, two switches under Factions in Configuration Manager — both on by default and read live, so flipping either takes effect without restarting the game:

  • Faction truce — mobs your race is at peace with leave you alone. Turn this off and every creature treats you exactly as vanilla would. This covers both halves of the peace system, not just the faction one: the same BaseAI.IsEnemy check also carries Fenrir's wolves, the Aswid's progression list, the Draugh's undead, the Trenta's Black Forest, the Sverm's invertebrates, the Furling's Plains roster and the Skeleton's undead — so switching it off gives those passives up along with the faction truce, for every race that had one. The Dvergar mercenaries' truce with wild dvergr is untouched by this switch — that one is between two NPCs and has nothing to do with hostility toward you.
  • Faction merchants — decides whether faction mobs can be traded with at all. Turn it off and they stop offering the E - Talk prompt and go back to being ordinary creatures.
  • Faction grudge (v1.4.19) — how many seconds a creature stays angry at a player of its own faction who hit it. 60 by default; 0 restores the old behaviour, where a truce was absolute in both directions.

Your troops​

Since v1.5.8 the truce covers the troops your stations raise, not only you. Before that a wild Rancid Remains left a Skeleton alone and tore into the garrison of its bone pile. Wild creatures of a race's faction now leave that race's troops alone, for every race that has troops. Hit one of those creatures and the truce ends for it: it fights you, and your troops fight it.

Hitting your own kin​

This is the one place the truce reads as a bug rather than a feature, and it was one until v1.4.19. Attacking a mob you are at peace with did nothing: it stood there being hit, or ran away. The truce answers vanilla's BaseAI.IsEnemy with no, and MonsterAI.UpdateTarget throws away any target that answers no on its very next tick — so the mob took the hit personally and then forgot about it a frame later.

Now hitting one starts a real fight for Faction grudge seconds, recorded per creature and per attacker. While the grudge lasts, that one pair is outside the truce entirely, so acquiring, chasing and giving up are all vanilla behaviour rather than anything reimplemented.

Two auras had to stop reaching their own kin for this to be usable: the Aswid's drain and the Skadi's frost aura. An always-on aura that ticked on a peaceful creature would have picked that fight for you, over and over.

Two switches rather than one because the halves fail differently: the truce is invisible when it works, while the merchants are a whole second interaction bolted onto creatures vanilla never meant to talk — anyone chasing a mod conflict wants to be able to rule out one without losing the other.

Known caveats​

  • Only your own race's faction membership is checked. A friend playing a different race in your party will still be attacked by mobs that leave you alone.
  • A merchant's stock and prices are fixed - there's no reputation or discount system beyond what each race's own perks (like Dvergar's trader favour) already provide.