Skip to content

Commit

Permalink
sceNp: Override k_licensee for PE game category
Browse files Browse the repository at this point in the history
Co-Authored-By: AniLeo <ani-leo@outlook.com>
  • Loading branch information
elad335 and AniLeo committed Apr 17, 2020
1 parent a3f2dfa commit 06d4505
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions rpcs3/Emu/Cell/Modules/sceNp.cpp
Expand Up @@ -436,6 +436,12 @@ error_code npDrmIsAvailable(vm::cptr<u8> k_licensee_addr, vm::cptr<char> drm_pat
sceNp.notice("npDrmIsAvailable(): KLicense key %s", *reinterpret_cast<be_t<v128, 1>*>(k_licensee.data()));
}

if (Emu.GetCat() == "PE")
{
std::copy_n(NP_PSP_KEY_2, std::size(NP_PSP_KEY_2), k_licensee.begin());
sceNp.success("npDrmIsAvailable(): PSP remaster KLicense key apllied.");
}

const std::string enc_drm_path(drm_path.get_ptr(), std::find(drm_path.get_ptr(), drm_path.get_ptr() + 0x100, '\0'));

sceNp.warning(u8"npDrmIsAvailable(): drm_path=“%s”", enc_drm_path);
Expand Down

0 comments on commit 06d4505

Please sign in to comment.