This commit is contained in:
WilliamWsyHK 2024-12-05 23:42:30 +08:00 committed by GitHub
commit b3e4b1a9db
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -84,12 +84,19 @@ namespace Ryujinx.HLE.Loaders.Processes
return false; return false;
} }
bool isFirmware = ProgramId is >= 0x0100000000000819 and <= 0x010000000000081C;
bool isMiiEdit = ProgramId == 0x0100000000001009;
string name = !isFirmware
? isMiiEdit ? "miiEdit from Firmware" : (!string.IsNullOrWhiteSpace(Name) ? Name : "<Unknown Name>")
: "Firmware";
// TODO: LibHac npdm currently doesn't support version field. // TODO: LibHac npdm currently doesn't support version field.
string version = ProgramId > 0x0100000000007FFF string version = !isFirmware && !isMiiEdit
? DisplayVersion ? (!string.IsNullOrWhiteSpace(DisplayVersion) ? DisplayVersion : "<Unknown Version>")
: device.System.ContentManager.GetCurrentFirmwareVersion()?.VersionString ?? "?"; : device.System.ContentManager.GetCurrentFirmwareVersion()?.VersionString ?? "?";
Logger.Info?.Print(LogClass.Loader, $"Application Loaded: {Name} v{version} [{ProgramIdText}] [{(Is64Bit ? "64-bit" : "32-bit")}]"); Logger.Info?.Print(LogClass.Loader, $"Application Loaded: {name} v{version} [{ProgramIdText}] [{(Is64Bit ? "64-bit" : "32-bit")}]");
return true; return true;
} }