mirror of
https://github.com/RPCS3/rpcs3.git
synced 2025-07-15 11:18:36 +12:00
C-style cast cleanup V
This commit is contained in:
parent
46ca39ec4d
commit
185c067d5b
44 changed files with 439 additions and 435 deletions
|
@ -362,7 +362,7 @@ error_code sceNpTrophyRegisterContext(ppu_thread& ppu, u32 context, u32 handle,
|
|||
}
|
||||
else if (!trp.ContainsEntry("TROPCONF.SFM"))
|
||||
{
|
||||
sceNpTrophy.error("sceNpTrophyRegisterContext(): Invalid/Incomplete trophy config");
|
||||
sceNpTrophy.error("sceNpTrophyRegisterContext(): Invalid/Incomplete trophy config");
|
||||
return SCE_NP_TROPHY_ERROR_ILLEGAL_UPDATE;
|
||||
}
|
||||
|
||||
|
@ -379,7 +379,7 @@ error_code sceNpTrophyRegisterContext(ppu_thread& ppu, u32 context, u32 handle,
|
|||
std::string trophyPath = "/dev_hdd0/home/" + Emu.GetUsr() + "/trophy/" + ctxt->trp_name;
|
||||
if (!trp.Install(trophyPath))
|
||||
{
|
||||
sceNpTrophy.error("sceNpTrophyRegisterContext(): Failed to install trophy context '%s' (%s)", trophyPath, fs::g_tls_error);
|
||||
sceNpTrophy.error("sceNpTrophyRegisterContext(): Failed to install trophy context '%s' (%s)", trophyPath, fs::g_tls_error);
|
||||
return SCE_NP_TROPHY_ERROR_ILLEGAL_UPDATE;
|
||||
}
|
||||
|
||||
|
@ -673,7 +673,7 @@ error_code sceNpTrophyUnlockTrophy(u32 context, u32 handle, s32 trophyId, vm::pt
|
|||
return SCE_NP_TROPHY_ERROR_UNKNOWN_HANDLE;
|
||||
}
|
||||
|
||||
if (trophyId < 0 || trophyId >= (s32)ctxt->tropusr->GetTrophiesCount())
|
||||
if (trophyId < 0 || trophyId >= static_cast<s32>(ctxt->tropusr->GetTrophiesCount()))
|
||||
return SCE_NP_TROPHY_ERROR_INVALID_TROPHY_ID;
|
||||
if (ctxt->tropusr->GetTrophyUnlockState(trophyId))
|
||||
return SCE_NP_TROPHY_ERROR_ALREADY_UNLOCKED;
|
||||
|
@ -931,7 +931,7 @@ error_code sceNpTrophyGetGameProgress(u32 context, u32 handle, vm::ptr<s32> perc
|
|||
}
|
||||
}
|
||||
|
||||
*percentage = (s32)(accuratePercentage / ctxt->tropusr->GetTrophiesCount());
|
||||
*percentage = static_cast<s32>(accuratePercentage / ctxt->tropusr->GetTrophiesCount());
|
||||
|
||||
return CELL_OK;
|
||||
}
|
||||
|
@ -1017,7 +1017,7 @@ error_code sceNpTrophyGetTrophyIcon(u32 context, u32 handle, s32 trophyId, vm::p
|
|||
return SCE_NP_TROPHY_ERROR_INVALID_ARGUMENT;
|
||||
}
|
||||
|
||||
if (ctxt->tropusr->GetTrophiesCount() <= (u32)trophyId)
|
||||
if (ctxt->tropusr->GetTrophiesCount() <= static_cast<u32>(trophyId))
|
||||
{
|
||||
return SCE_NP_TROPHY_ERROR_INVALID_TROPHY_ID;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue