# libSceNpScoreRanking technical debt ### Silent stubs - [sceNpScoreSetThreadParam](../../../core/libs/prx/libSceNpScoreRanking/Export.cpp) (libSceNpScoreRanking) - answers 0 and changes nothing: the module [recreates its `SceNpScoreWorker` thread](https://github.com/boykopovar/AnyPS5/pull/12611#issuecomment-6494084502) with the given priority and affinity, and requests here finish without one - [sceNpScoreChangeModeForOtherSaveDataOwners](../../../core/libs/prx/libSceNpScoreRanking/Export.cpp) (libSceNpScoreRanking) - checks the mode and the id as firmware 13.42 does ([disassembly](https://github.com/boykopovar/AnyPS5/pull/12611#issuecomment-6507773030)) and answers 0, but does not keep the mode: the module stores it in the title context or request for the service, and no request reaches a service here ### Functional - [libSceNpScoreRanking](../../../core/libs/prx/libSceNpScoreRanking/Export.cpp) (libSceNpScoreRanking) - offline only, not measured on a PS5: the argument checks, their order, the limit of 32 title contexts and 32 requests and the array sizes follow [shadPS4](https://github.com/shadps4-emu/shadPS4/blob/91e6afa69b0a64b0afaa0281b80f8fbb0cd88136/src/core/libraries/np/np_score/np_score.cpp#L64-L1210), and a valid call then returns `SCE_NP_ERROR_SIGNED_OUT` and finishes its request with it, as shadPS4 does when the user [has no connection](https://github.com/shadps4-emu/shadPS4/blob/91e6afa69b0a64b0afaa0281b80f8fbb0cd88136/src/core/libraries/np/np_handler/np_handler_score.cpp#L18-L26). No output is written, where shadPS4 first clears the rank, comment and info arrays. A null `boardInfo` throws: shadPS4 answers it by the title's SDK version - [the A, account id, character id, game data and board info variants](../../../core/libs/prx/libSceNpScoreRanking/Export.cpp) (libSceNpScoreRanking) - offline only, not measured on a PS5: signatures, checks, their order and element sizes follow a [later shadPS4](https://github.com/shadps4-emu/shadPS4/blob/0614ce324be092791b758d79f93d9f1ca5b10a81/src/core/libraries/np/np_score/np_score.cpp#L85-L1589), which also answers `SCE_NP_ERROR_SIGNED_OUT` for a user with [no connection](https://github.com/shadps4-emu/shadPS4/blob/0614ce324be092791b758d79f93d9f1ca5b10a81/src/core/libraries/np/np_handler/np_handler_score.cpp#L529-L544). `sceNpScoreCreateNpTitleCtxA` checks the sign-in first, so it always returns `SCE_NP_ERROR_SIGNED_OUT`; `sceNpScoreGetGameData` finishes the request with `INVALID_ARGUMENT` for an empty online id; `sceNpScoreSetPlayerCharacterId` only checks its arguments, since no request reaches a server - [the ForCrossSave calls, sceNpScoreSetTimeout, sceNpScoreSetThreadParam, sceNpScoreCreateTitleCtx](../../../core/libs/prx/libSceNpScoreRanking/Export.cpp) (libSceNpScoreRanking) - follow firmware 13.42's module as [read from its disassembly](https://github.com/boykopovar/AnyPS5/pull/12611#issuecomment-6494084502), not run: each ForCrossSave call is its regular call under another name, and `sceNpScoreGetRankingByRange` takes 0x80 or 0x90 bytes per rank. `sceNpScoreSetTimeout` checks the retry count and the minimum timeouts in the module's order; the module picks a title context or a request by the id range, and the ids here overlap, so both are looked up. `sceNpScoreCreateTitleCtx` prints its three warnings and takes a context from the same table. The module's `NOT_INITIALIZED` checks never apply here - [sceNpScoreWaitAsync](../../../core/libs/prx/libSceNpScoreRanking/Export.cpp) (libSceNpScoreRanking) - throws for a request with no operation started. Firmware 13.42 [blocks](https://github.com/boykopovar/AnyPS5/pull/12611#issuecomment-6507773030) there on the request's semaphore, which only the worker's completion signals, as shadPS4 waits forever; neither `sceNpScoreAbortRequest` nor `sceNpScoreDeleteRequest` [releases it](https://github.com/boykopovar/AnyPS5/pull/12611#issuecomment-6520890176), so such a wait never returns - [sceNpScoreCensorComment, sceNpScoreSanitizeComment, sceNpScoreRecordGameData and their async forms](../../../core/libs/prx/libSceNpScoreRanking/Export.cpp) (libSceNpScoreRanking) - make the checks firmware 13.42 makes before queueing to its worker ([disassembly](https://github.com/boykopovar/AnyPS5/pull/12611#issuecomment-6507773030), not run): an option, then a null comment or data, then the request, then a comment longer than 255 characters. Valid calls then answer offline like the rest of the library. The module copies the score and sizes unchecked and leaves the chunk checks to the service, `sanitizedComment` is never written, and the async forms finish the request here instead of returning 0 for the worker to finish