Hacking [RELEASE] Phacox's Injector (NES/SNES/N64/GBA/NDS for Wii U)

Andrehws

Active Member
Newcomer
Joined
Nov 21, 2018
Messages
39
Trophies
0
Age
28
XP
259
Country
Brazil
Error was in how "Phacox's Injector" transferred the common key to CNUSPacker, it was not doing well, so the files were being encrypted with a key in zeros.

Version 1.0.3 fixes the bug. (Version 1.0 doesn't have that bug either.)

tested and working. but now no matter what is written in long name, the injector will always use what is written in short name.
 

Lord_Kimbou

Member
Newcomer
Joined
Jul 6, 2019
Messages
10
Trophies
0
Age
44
XP
106
Country
Spain
Hi! I try snes injection with 1.03v, and problem persist.. Thanks for your hard work! ;)
inyectar.png


--------------------- MERGED ---------------------------

oh!! I see the error!!!!!! For some reason CNUS packer is searching encyptKeyWith, not encryptKeyWith, I create this file and now works.. ;)

inyectar3.png
 
Last edited by Lord_Kimbou,
  • Like
Reactions: phacox_cll

phacox_cll

Well-Known Member
OP
Member
Joined
Mar 30, 2019
Messages
172
Trophies
0
XP
1,339
Country
Mexico
tested and working. but now no matter what is written in long name, the injector will always use what is written in short name.
You're right, the short name was always used as a long name. Thanks for the feedback. Version 1.0.4 is now available.
 

phacox_cll

Well-Known Member
OP
Member
Joined
Mar 30, 2019
Messages
172
Trophies
0
XP
1,339
Country
Mexico
Hi! I try snes injection with 1.03v, and problem persist.. Thanks for your hard work! ;)
inyectar.png


--------------------- MERGED ---------------------------

oh!! I see the error!!!!!! For some reason CNUS packer is searching encyptKeyWith, not encryptKeyWith, I create this file and now works.. ;)

inyectar3.png
"encyptKeyWith" instead of "encryptKeyWith" is a bug of the CNUSPacker version found in the latest Release available on GitHub. When I verify the source code, I notice that it is already corrected. "Phacox's Injector" will eventually include the corrected version.
 

phacox_cll

Well-Known Member
OP
Member
Joined
Mar 30, 2019
Messages
172
Trophies
0
XP
1,339
Country
Mexico
@phacox_cll would be nice to also insert gbc and gb
The Wii U virtual console is not compatible with GB or GBC. It is possible to inject GB and some GBC games by previously converting them to GBA format with GoombaColor.

In my future plans (one way or another) I want to facilitate the injection of games for MSX, TurboGrafx-16, GB, GBC, VirtualBoy, GameCube and Wii. In addition to blurring the incompatibilities with the NES, SNES, GBA and N64 games (obviously this is possible if we no longer depend only on the emulators created by the big N).
 

megamachopop

Member
Newcomer
Joined
Feb 1, 2014
Messages
13
Trophies
0
Age
29
XP
46
Country
Canada
Quick question. For removing the dark filter on N64 games, I simply download the official VC files, then decrypt them. After making the file with the dark filter removed, I replace the FrameLayout.arc file in the official VC files then repack and install it.

I'm wanting to mess with the aspect ratio of NES games. Is there a simple file I can replace like with N64 games in the official VC files?
 

phacox_cll

Well-Known Member
OP
Member
Joined
Mar 30, 2019
Messages
172
Trophies
0
XP
1,339
Country
Mexico
Quick question. For removing the dark filter on N64 games, I simply download the official VC files, then decrypt them. After making the file with the dark filter removed, I replace the FrameLayout.arc file in the official VC files then repack and install it.

I'm wanting to mess with the aspect ratio of NES games. Is there a simple file I can replace like with N64 games in the official VC files?
There is no file that you can replace to change the aspect ratio of the NES virtual console.

For the NES and SNES games, all the configuration is embedded in the executable file ".rpx".

With my injector you can edit the aspect ratio of the NES and SNES virtual console without modifying anything else. For this you need the common Wii U key and the virtual console game, you do NOT need ROM.

First go to the Settings section and enter the common key, if it is correct the text box is disabled and a green check will replace the red mark. After that, change the mode from "Auto" to "NES" or "SNES (USA)" in the lower left and return to the Main section.

If you have already changed the mode, in the Main section you will NOT need to choose a ROM to load the base game. Put anything in the "Short name" box (the name of the game will not be modified), click on the "Load base" button, select the game you want to edit the aspect ratio and wait for it to load, A green check and its data should appear.

In the section "VC Settings" change the aspect ratio.

In the Images section, activate the three checkboxes next to the "Icon", "TV" and "GamePad" buttons. And disable the "Show name" checkbox. This to keep the presentation images of the game unchanged.

Finally, in the Injected section, click on the "Do not pack" button or on the "Do pack" button, select the output folder. The result will be in a folder with the name "Short name [Title ID] (Edit)".

Do you want to edit it to an aspect ratio that is not available in the program?
 
  • Like
Reactions: Zense

megamachopop

Member
Newcomer
Joined
Feb 1, 2014
Messages
13
Trophies
0
Age
29
XP
46
Country
Canada
No. The reason I was asking was that simply changing the file in the officially downloaded VC title meant keeping all the startup images and text without having to edit/make them myself. I didn't realize the program could automatically do that. Thanks.
 
  • Like
Reactions: phacox_cll

megamachopop

Member
Newcomer
Joined
Feb 1, 2014
Messages
13
Trophies
0
Age
29
XP
46
Country
Canada
Another quick question, sorry. I noticed someone else had asked, but do you have plans to remove be able to remove the dark filter from GBA games as well as NES games?
 

phacox_cll

Well-Known Member
OP
Member
Joined
Mar 30, 2019
Messages
172
Trophies
0
XP
1,339
Country
Mexico
I have disassembled and searched the hexadecimal data how to remove both the dark filter and the bilinear filter from the NES virtual console but I have failed again and again :sad:. As for the GBA virtual console I have not done the "homework", but if someone finds a way to do it for both GBA and NES I will gladly implement it in the injector.
 
  • Like
Reactions: Zense

Zense

Well-Known Member
Member
Joined
Apr 20, 2008
Messages
1,977
Trophies
2
XP
4,300
Country
Italy
I seemed to remember there being a way to remove dark filter from NES games, but I can't find it right now. Still I believe the Wii U, NES Classic and 3DS use some sort of the same NES emulator (I believe the SNES one is called canoe and is used across all of those and maybe switch too.). It could be helpful to search for how they removed the dark filters from those, since I know they've done that for the 3DS NES emulator.

Here's another thread that might shed some light on NES and GBA dark filter removal.

Here's a link to a gbatemp post that explains how to adjust the NDS games with aspect ratio and brightness (dark filter?).
The same link is for a thread where a lot of adjustments to wii u emulators are posted, for example N64 with widescreen etc..

Also thanks and great work with your injector!
 
Last edited by Zense,
  • Like
Reactions: phacox_cll

phacox_cll

Well-Known Member
OP
Member
Joined
Mar 30, 2019
Messages
172
Trophies
0
XP
1,339
Country
Mexico
I seemed to remember there being a way to remove dark filter from NES games, but I can't find it right now. Still I believe the Wii U, NES Classic and 3DS use some sort of the same NES emulator (I believe the SNES one is called canoe and is used across all of those and maybe switch too.). It could be helpful to search for how they removed the dark filters from those, since I know they've done that for the 3DS NES emulator.

Here's another thread that might shed some light on NES and GBA dark filter removal.

Here's a link to a gbatemp post that explains how to adjust the NDS games with aspect ratio and brightness (dark filter?).
The same link is for a thread where a lot of adjustments to wii u emulators are posted, for example N64 with widescreen etc..

Also thanks and great work with your injector!
I know that Wii U, 3DS, NES/SNES Classic and Switch use the same formats for NES/SNES ROMs, which consists of a metadata wrapper (header and footer) and the original ROM itself (although the metadata differs slightly between ROMs of NES (fcrom?) and SNES ROMs (sfrom)), I don't know if the emulator is the same, but I doubt it since the architectures are different (Wii U is PowerPC while 3DS, NES/SNES Classic and Switch are ARM), however I'm going to investigate it.

I read the whole thread of "the_randomizer" before publishing my injector looking just how to remove the filters from the NES virtual console and used the research they did on that thread as a starting point to do my own research... without results.

The structure of each Wii U virtual console is very different. On the one hand, there is NES/SNES, where the ROM and the display configuration are inside the executable file. Then for N64 the executable file is independent of the folder structure where the ROM is associated with a ".ini" configuration file and where the display configuration is in the "FrameLayout.arc" file (where the dark filter is a layer over the game layer). Then for GBA the ROM (and the display configuration) are encapsulated in an encrypted data structure composed of two files ("alldata.psb.m" and "alldata.bin") and respective independent executable. And on the other hand for NDS the executable is also independent from the ROM that is compressed in a simple ".zip" file and the display configuration is in the "configuration_cafe.json" file (where the dark filter is actually a parameter 80% brightness). This is a consequence of the fact that each emulator was developed by a different team (it seems to me that NES/SNES for NCL, N64 for NST, GBA for M2 and NDS for NERD).

I have yet to finish a program that allows you to edit the files "configuration_cafe.json" (I intended to integrate it into my program "DSInject" as was "VCN64Config" for "64Inject"), and I also have pending to publish in my github a program that allows reading the header of ELF files, decompress and recompress RPX files, and read the metadata of the NES/SNES RPX files. With this last one I made the file "NES_SNES_VC_Characteristics" ;)
 
  • Like
Reactions: Zense

megamachopop

Member
Newcomer
Joined
Feb 1, 2014
Messages
13
Trophies
0
Age
29
XP
46
Country
Canada
Are you able to implement a way to overscan NES and SNES games like N64 in addition to being able to change the aspect ratio?
 

phacox_cll

Well-Known Member
OP
Member
Joined
Mar 30, 2019
Messages
172
Trophies
0
XP
1,339
Country
Mexico
Are you able to implement a way to overscan NES and SNES games like N64 in addition to being able to change the aspect ratio?
By changing the values that managed to identify it in the "the_randomizer" thread, it is only possible to change the width of the output image of the game, the height remains constant. That is to say, I can make the image as thin as a vertical line or so wide that the image comes out from the sides of the screen, but I cannot make it as thin as a horizontal line or it comes out for above and below the screen.
 

Cloud9Skywalker

Pokémon Researcher
Member
Joined
Mar 26, 2015
Messages
280
Trophies
0
XP
501
Country
United States
Thanks for this, this is great!
How is the latest release coming along?
Is there a list of Nintendo 64 titles that are compatible with injection? It doesn't surpass this list, does it?

EDIT:
So I tried using this and attempted to follow all directions but somehow got stuck at the "The Base is Invalid" error.
 
Last edited by Cloud9Skywalker,

Site & Scene News

Popular threads in this forum

General chit-chat
Help Users
    Xdqwerty @ Xdqwerty: I hate myself