mirror of
https://github.com/RPCS3/rpcs3.git
synced 2025-07-11 09:18:40 +12:00
cellSysUtil: Implement CELL_SYSUTIL_SYSTEMPARAM_ID_LICENSE_AREA
This commit is contained in:
parent
639650c65a
commit
81eceb1728
3 changed files with 31 additions and 14 deletions
|
@ -1,26 +1,15 @@
|
|||
#include "stdafx.h"
|
||||
#include "Emu/System.h"
|
||||
#include "Emu/Cell/PPUModule.h"
|
||||
#include "cellSysutil.h"
|
||||
|
||||
LOG_CHANNEL(cellSysutilMisc);
|
||||
|
||||
// License areas
|
||||
enum
|
||||
{
|
||||
CELL_SYSUTIL_LICENSE_AREA_J = 0,
|
||||
CELL_SYSUTIL_LICENSE_AREA_A = 1,
|
||||
CELL_SYSUTIL_LICENSE_AREA_E = 2,
|
||||
CELL_SYSUTIL_LICENSE_AREA_H = 3,
|
||||
CELL_SYSUTIL_LICENSE_AREA_K = 4,
|
||||
CELL_SYSUTIL_LICENSE_AREA_C = 5,
|
||||
CELL_SYSUTIL_LICENSE_AREA_OTHER = 100,
|
||||
};
|
||||
|
||||
s32 cellSysutilGetLicenseArea()
|
||||
{
|
||||
cellSysutilMisc.warning("cellSysutilGetLicenseArea()");
|
||||
|
||||
switch (const char region = Emu.GetTitleID().at(2))
|
||||
switch (const char region = Emu.GetTitleID().size() >= 3u ? Emu.GetTitleID().at(2) : '\0')
|
||||
{
|
||||
case 'J': return CELL_SYSUTIL_LICENSE_AREA_J;
|
||||
case 'U': return CELL_SYSUTIL_LICENSE_AREA_A;
|
||||
|
@ -28,7 +17,7 @@ s32 cellSysutilGetLicenseArea()
|
|||
case 'H': return CELL_SYSUTIL_LICENSE_AREA_H;
|
||||
case 'K': return CELL_SYSUTIL_LICENSE_AREA_K;
|
||||
case 'A': return CELL_SYSUTIL_LICENSE_AREA_C;
|
||||
default: cellSysutilMisc.todo("Unknown license area: %s", Emu.GetTitleID().c_str()); return CELL_SYSUTIL_LICENSE_AREA_OTHER;
|
||||
default: cellSysutilMisc.todo("Unknown license area: %s", Emu.GetTitleID()); return CELL_SYSUTIL_LICENSE_AREA_OTHER;
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue