Skip to content

Commit

Permalink
pkgi_download: add support for minis games
Browse files Browse the repository at this point in the history
Closes #66
  • Loading branch information
blastrock committed May 7, 2018
1 parent ccde018 commit 039054a
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions pkgi_download.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -265,10 +265,11 @@ int Download::download_head(const uint8_t* rif)
content_type = get32be(head + offset + 8);
// 6 PSX game
// 7 PSP game
// 15 PSP-Mini game
// 21 PSV game (or update)
// 22 PSV DLC
if (content_type != 21 && content_type != 22 && content_type != 6 &&
content_type != 7)
content_type != 7 && content_type != 15)
{
throw DownloadError(
"unsupported package type: " +
Expand Down Expand Up @@ -391,7 +392,7 @@ int Download::download_files(void)
item_size,
type);

if (content_type == 6 || content_type == 7)
if (content_type == 6 || content_type == 7 || content_type == 15)
{
if (std::string(item_name) == "USRDIR/CONTENT/DOCUMENT.DAT")
pkgi_snprintf(
Expand Down Expand Up @@ -622,7 +623,7 @@ int Download::pkgi_download(
return 0;
if (!download_tail())
return 0;
if (content_type != 6 && content_type != 7)
if (content_type != 6 && content_type != 7 && content_type != 15)
{
if (!create_stat())
return 0;
Expand Down

0 comments on commit 039054a

Please sign in to comment.