ROM Hack [Release] Villain3ds - Basically freeShop but runs on your PC

Bendito999

New Member
Newbie
Joined
Aug 7, 2018
Messages
1
Trophies
0
Age
28
XP
50
Country
United States
Thank you for this queue feature I am testing it and it is great.
For users here, one thing I've found is that if you get one of the 'corrupted downloads' it will seem to hang up the queue on the current download. However, you can get past the corrupted download that pressing the retry play button won't fix by going to the Villain raw folder and just manually deleting the 00000001 file or whatever what having the issue, then clicking play again it should work (the play button retry seems to sometimes have issues clearing the file to actually try again you have to clear it manually). Then it will continue on your merry way downloading (good for archiving vast swathes of my purchased shovelware for archival's sake that no one else would care to save until it is too late).
 
  • Like
Reactions: tranxuanthang

Zeparu

Member
Newcomer
Joined
Aug 7, 2018
Messages
6
Trophies
0
Age
35
XP
157
Country
United States
Sorry if this has already been asked, I searched already and didn't find anything. When downloading updates and dlc and are packaged as individual CIA files. Installing them through FBI would automatically apply them to the base game?
 

tranxuanthang

Well-Known Member
OP
Member
Joined
Jul 6, 2015
Messages
289
Trophies
0
Age
26
XP
605
Country
Sorry if this has already been asked, I searched already and didn't find anything. When downloading updates and dlc and are packaged as individual CIA files. Installing them through FBI would automatically apply them to the base game?
Yes, if you install an update or dlc cia it will automatically apply to the right game. Or you can just update the game from home menu or eshop.
how do i get the dlc and updates?
You need to find a title has the same name with your game, but has "dlc" type.
 
  • Like
Reactions: Zeparu and Powerful

juniorcba

Well-Known Member
Newcomer
Joined
Aug 23, 2007
Messages
83
Trophies
0
Age
40
XP
645
Country
Brazil
Monster Hunter Stories DLC get corrupted here everytime, on the file 00000009. Its size is smaller then expected. There's something wrong with the file on Nintendo servers?
Someone can try to download it and confirm that is not only here?

Enviado de meu MotoG3 usando o Tapatalk
 

Zeparu

Member
Newcomer
Joined
Aug 7, 2018
Messages
6
Trophies
0
Age
35
XP
157
Country
United States
Yes, if you install an update or dlc cia it will automatically apply to the right game. Or you can just update the game from home menu or eshop.

You need to find a title has the same name with your game, but has "dlc" type.

Thank you!

Monster Hunter Stories DLC get corrupted here everytime, on the file 00000009. Its size is smaller then expected. There's something wrong with the file on Nintendo servers?
Someone can try to download it and confirm that is not only here?

Enviado de meu MotoG3 usando o Tapatalk

I just tried it as well and got the same error.
 

tranxuanthang

Well-Known Member
OP
Member
Joined
Jul 6, 2015
Messages
289
Trophies
0
Age
26
XP
605
Country
Monster Hunter Stories DLC get corrupted here everytime, on the file 00000009. Its size is smaller then expected. There's something wrong with the file on Nintendo servers?
Someone can try to download it and confirm that is not only here?

Enviado de meu MotoG3 usando o Tapatalk
It's a known issue but I don't think I can do anything about it.
https://github.com/tranxuanthang/villain3ds/issues/25
does this have more games than wii u usb helper?
No. freeShop, villain3ss, wii u usb help are all depend on that title key site.
 
  • Like
Reactions: juniorcba

shanefromoz

Well-Known Member
Member
Joined
Jun 18, 2007
Messages
1,950
Trophies
1
XP
4,244
Country
Australia
Can someone please help me with this error " Could not find the titlekey for the title you're trying to download. Please try deleting enctitlekeys.bin file in your base directory, or go to About, then Troubleshooting, and click Delete encTitleKeys.bin file, and try downloading again".
Thanks
 

McMoofin

Member
Newcomer
Joined
Aug 1, 2018
Messages
19
Trophies
0
Age
27
XP
83
Country
United States
Can someone please help me with this error " Could not find the titlekey for the title you're trying to download. Please try deleting enctitlekeys.bin file in your base directory, or go to About, then Troubleshooting, and click Delete encTitleKeys.bin file, and try downloading again".
Thanks
place the enctitlekeys.bin in the directory of the villain3ds install.
 

Kyusuke

Well-Known Member
Newcomer
Joined
Jun 24, 2007
Messages
98
Trophies
0
XP
200
Country
United Kingdom
Another quick update v0.2.2.
Some bugfixes and a very minimal queue feature. It's a bit late but I hope it'll be helpful for someone.

https://github.com/tranxuanthang/villain3ds/releases/
Changelog:

  • Fix "path is invalid..." bug when redownload a content after stop downloading by clicking small [x] button (a windows-specific bug). Also fix some weird bugs around small "stop download" [x] button.
  • An experimental queue feature. You just need to download any titles by clicking "Download" button like normal, they will be put in download queue in existing download window. Screenshot.

I'm assuming you forgot to push up the source code for v0.2.2 since the latest code on the repo is v0.2.1 (before the queue system is implemented).

With regards to the SHA check failures, that metadata you've mention adds exactly 10KB of data at the end of the file (some amount of metadata followed by padding to make 10KB).

If you want to rectify it to make up for mt-files-downloader being tempermental with trimming the file, you can do the trimming yourself.

I've not been thorough with your code so I'd imagine you can think of a better place to implement this but where you have:

Code:
$('#'+titleId+' #'+cID+' .download-play').on('click',function(){
    if(fs.existsSync(contentPath+'.mtd') && !fs.existsSync(contentPath) && fs.statSync(contentPath+'.mtd').size>0){
        dl.resume();
    } else if(fs.existsSync(contentPath) && !fs.existsSync(contentPath+'.mtd') && fs.statSync(contentPath).size>0) {
        dl.setStatus(3);
    } else {
        dl.resume();
    }
});


You could do something along the lines of:

Code:
$('#'+titleId+' #'+cID+' .download-play').on('click',function(){
    if(fs.existsSync(contentPath+'.mtd') && !fs.existsSync(contentPath) && fs.statSync(contentPath+'.mtd').size>0){
        dl.resume();
    } else if(fs.existsSync(contentPath) && !fs.existsSync(contentPath+'.mtd') && fs.statSync(contentPath).size>0) {
        if(fs.statSync(contentPath).size == dl.getStats().total.size + 10240) { // Is the file exactly 10KB bigger than intended?
            fs.truncateSync(contentPath, dl.getStats().total.size) // Truncate the file from the intended size onwards
        }
        dl.setStatus(3);
    } else {
        dl.resume();
    }
});

Commenting out dl.destroy() on the SHA failure declaration is needed too (not that it did much good since all it's done is to truncate the file instead of deleting it).

What would happen is that whenever a SHA failure is encountered and the user DOES NOT restart the program and instead, tries again. A check is made with whether the file itself is bigger than the intended size by 10KB then trims it off if so.

Ideally, you want to try and get this check done and trimmed before you verify the file so it becomes much more streamline but then it'd be the case of accessing fs by the time dl.status == 3. Again, you know your code much better than I so I trust you'd know how to implement it.

I acknowledge that this is very late and the folks that would value this would be pushing for time before the potential lockout but you did say that this has been bugging you.
 
Last edited by Kyusuke,
  • Like
Reactions: tranxuanthang

MushGuy

Well-Known Member
Member
Joined
Feb 11, 2010
Messages
1,280
Trophies
1
XP
2,580
Country
United States
Monster Hunter Stories DLC get corrupted here everytime, on the file 00000009. Its size is smaller then expected. There's something wrong with the file on Nintendo servers?
Someone can try to download it and confirm that is not only here?

Enviado de meu MotoG3 usando o Tapatalk
Can you try downloading through FBI?
 

Mysuke

Well-Known Member
Newcomer
Joined
Mar 9, 2017
Messages
86
Trophies
0
Age
24
XP
331
Country
Brazil
The problem with MH Stories DLC is not to exclusive to Villain.

When i use Freeshop it fails at the end as well. Wii U USB Helper keeps failing at "downloading content 10 of 15".

I believe all the DLC for this game is free, try downloading from the main menu inside the game instead.
 

tranxuanthang

Well-Known Member
OP
Member
Joined
Jul 6, 2015
Messages
289
Trophies
0
Age
26
XP
605
Country
I'm assuming you forgot to push up the source code for v0.2.2 since the latest code on the repo is v0.2.1 (before the queue system is implemented).

With regards to the SHA check failures, that metadata you've mention adds exactly 10KB of data at the end of the file (some amount of metadata followed by padding to make 10KB).

If you want to rectify it to make up for mt-files-downloader being tempermental with trimming the file, you can do the trimming yourself.

I've not been thorough with your code so I'd imagine you can think of a better place to implement this but where you have:

Code:
$('#'+titleId+' #'+cID+' .download-play').on('click',function(){
    if(fs.existsSync(contentPath+'.mtd') && !fs.existsSync(contentPath) && fs.statSync(contentPath+'.mtd').size>0){
        dl.resume();
    } else if(fs.existsSync(contentPath) && !fs.existsSync(contentPath+'.mtd') && fs.statSync(contentPath).size>0) {
        dl.setStatus(3);
    } else {
        dl.resume();
    }
});


You could do something along the lines of:

Code:
$('#'+titleId+' #'+cID+' .download-play').on('click',function(){
    if(fs.existsSync(contentPath+'.mtd') && !fs.existsSync(contentPath) && fs.statSync(contentPath+'.mtd').size>0){
        dl.resume();
    } else if(fs.existsSync(contentPath) && !fs.existsSync(contentPath+'.mtd') && fs.statSync(contentPath).size>0) {
        if(fs.statSync(contentPath).size == dl.getStats().total.size + 10240) { // Is the file exactly 10KB bigger than intended?
            fs.truncateSync(contentPath, dl.getStats().total.size) // Truncate the file from the intended size onwards
        }
        dl.setStatus(3);
    } else {
        dl.resume();
    }
});

Commenting out dl.destroy() on the SHA failure declaration is needed too (not that it did much good since all it's done is to truncate the file instead of deleting it).

What would happen is that whenever a SHA failure is encountered and the user DOES NOT restart the program and instead, tries again. A check is made with whether the file itself is bigger than the intended size by 10KB then trims it off if so.

Ideally, you want to try and get this check done and trimmed before you verify the file so it becomes much more streamline but then it'd be the case of accessing fs by the time dl.status == 3. Again, you know your code much better than I so I trust you'd know how to implement it.

I acknowledge that this is very late and the folks that would value this would be pushing for time before the potential lockout but you did say that this has been bugging you.
I did think about manually trim the file if the file is not trimmed, but I really want to truly fix that in the library itself, so I let it be my last resort.
There is a weird behavior that I don't know how to explain. In windows only, I sometimes can't run fs.unlink or fs.unlinkSync to delete a file. I found that it's related to how Windows lock the opening files, and I think it's a source of many other problems, such as the fs.ftruncate randomly failed to work.
 

Kyusuke

Well-Known Member
Newcomer
Joined
Jun 24, 2007
Messages
98
Trophies
0
XP
200
Country
United Kingdom
Looking at what dl.destroy does, it does send fs.unlink but there's nothing to handle errors should it happen.

That said, it still does something (i.e. truncate in the case of SHA failure) so you might be looking at a case where file handles aren't being released by the time unlink is called so it holds it up.
 
  • Like
Reactions: tranxuanthang

chr0m

Well-Known Member
Member
Joined
Oct 9, 2007
Messages
340
Trophies
1
XP
948
Country
Australia
Can someone please help me with this error " Could not find the titlekey for the title you're trying to download. Please try deleting enctitlekeys.bin file in your base directory, or go to About, then Troubleshooting, and click Delete encTitleKeys.bin file, and try downloading again".
Thanks

I just tried to use this today for the first time and I'm getting the error too. I tried using the default base dir, changing the dir to where I'm running Villain3DS from, but nothing works.

It downloads the encTitleKeys.bin, then I click download and it says it can't find the titlekey and deletes the encTitleKeys.bin.

I also tried manually copying it there, but it still doesn't work. Any clues?
 

shanefromoz

Well-Known Member
Member
Joined
Jun 18, 2007
Messages
1,950
Trophies
1
XP
4,244
Country
Australia
I just tried to use this today for the first time and I'm getting the error too. I tried using the default base dir, changing the dir to where I'm running Villain3DS from, but nothing works.

It downloads the encTitleKeys.bin, then I click download and it says it can't find the titlekey and deletes the encTitleKeys.bin.

I also tried manually copying it there, but it still doesn't work. Any clues?
At encTitleKeys.bin to the directory of villain 3ds. Go to settings and put titlekeys website address. Close application and it should work
 

Site & Scene News

Popular threads in this forum

General chit-chat
Help Users
  • BakerMan
    The snack that smiles back, Ballsack!
    Xdqwerty @ Xdqwerty: @BakerMan, I have a piano keyboard but I never use it