Skip to content

Hashing Algorithms

Picking the wrong hash family for a given context is the single most common reason a property or path "mysteriously" renders as hex. The full spec lives on the LeagueToolkit wiki (with an interactive calculator); this page is just the right-hash-for-the-right-job cheat sheet.

Which hash where

AlgorithmWidthUsed forOur implementation
FNV-1a32-bitBIN property/class/object path hashes. Per the wiki, also ANM v4/v5 + compressed joint hashes.OfficialLeagueToolkit/Hashing/Fnv1a.cs — lowercases input.
xxHash6464-bitWAD chunk paths (v3+). Seed 0, over lowercased /-normalized path.OfficialLeagueToolkit/Hashing/XxHash64Ext.cs.
ELF32-bit.skl joint names. Our extractor also uses it for matching animation tracks to joints.LeagueToolkit/Helpers/Cryptography.cs#ElfHash — lowercases input.
SDBM32-bitA few legacy auxiliary formats. Not used for binhashes.OfficialLeagueToolkit/Hashing/Sdbm.cs.

Our FNV-1a and ELF helpers lowercase internally — don't pre-lowercase at the call site.

Two things that bite

  1. hashes.binhashes.txt is FNV-1a, not SDBM. Our own docs had this wrong until 2026-04-17. The SDBM implementation in-tree is for a few legacy formats only.
  2. ELF hash is case-insensitive (ElfHash("Head") == ElfHash("head")). If a skeleton carries both the real bone and a lowercase compatibility stub, the animation track will bind to whichever BFS hits first. The two-pass Influences-preference match in MapAllTracksInOrder exists solely for this. See Skeletons & Animations and the Dark Star Shaco case study.

When a property won't resolve

You'll see 0xDEADBEEF in material dumps instead of a name. Workflow:

  1. Dump the material with --dump-materials.
  2. Confirm the hash family for the context (table above).
  3. Plug the expected name into the wiki's hash calculator — does it produce the hex you're seeing?
  4. If yes, the name just isn't in the dictionary. Community dictionaries come from CommunityDragon (hashes.game.txt, hashes.binhashes.txt), fetched in HashTables.TryLoadHashes.

Possible mismatch worth flagging

The upstream wiki documents ANM v4/v5 + compressed joint hashes as FNV-1a. Our extractor's track-to-joint mapping matches animation track hashes against SKL's ELF hashes. That's worked in practice — don't assume it's definitionally correct when chasing a mapping bug.

Built for engineers and AI assistants working on Khada.