-
Notifications
You must be signed in to change notification settings - Fork 0
Getting Started
Peterson Fernandes edited this page Aug 15, 2026
·
1 revision
dotnet add package RetroAchievementsSharp
Works with the .NET 8, 9, and 10 SDKs/runtimes on Windows, Linux, macOS, x64 and arm64.
Build from source:
dotnet build RetroAchievementsSharp.sln -c Releaseor publish self-contained single-file executables:
dotnet publish RetroAchievementsSharp.Cli -c Release -r win-x64 --self-contained true -p:PublishSingleFile=true -o artifacts/win-x64using RetroAchievementsSharp;
// Hash a ROM exactly the way RetroAchievements does:
if (RcHash.GenerateFromFile(out string hash, ConsoleIds.RcConsoleNintendo, "game.nes"))
Console.WriteLine(hash); // 32 hex chars — matches the published RA hashvar iterator = new RcHashIterator();
HashIterator.InitializeIterator(iterator, "Super Mario (USA).sfc", null, 0);
while (HashIterator.Iterate(out var hash, iterator) != 0)
Console.WriteLine(hash); // the first hash that matched a console
HashIterator.DestroyIterator(iterator);.cia/.3ds files need key material before hashing:
Hash3Ds.InitHash3Ds(@"C:\RetroArch\system"); // dir with aes_keys.txt/seeddb.bin
if (RcHash.GenerateFromFile(out hash, ConsoleIds.RcConsoleNintendo3Ds, "game.cia"))
Console.WriteLine(hash);The CLI accepts the same directory via -s <systempath>.