ROM Hack [GB(C)] Injection with the New Generation of VC

driverdis

I am Justice
Member
Joined
Sep 21, 2011
Messages
2,867
Trophies
2
Age
31
Location
1.048596β
XP
2,838
Country
United States
FYI Just changing Pokemon Red/Blue to read as a GBC rom won't work.
The colorization comes from it being a Super Gameboy enhanced game, so changing it to a GBC rom and nothing else will just cause it to be completely white, if anything.

what about modding red and blue to use palettes in the same way yellow does. I assume yellow has the palettes embeded in the rom somewhere. I have no knowledge of how gameboy ganes operate so I am just throwing ideas (however stupid they may be)
 

Deleted member 370283

Well-Known Member
Member
Joined
Aug 19, 2015
Messages
496
Trophies
0
Age
22
XP
1,021
Country
United States
I remember my actual Gameboy color doing the color changing, if i'm not mistaken,
but I guess the VC emulator doesn't work that way.
In Pokemon Red and Blue's header, the GBC flag at 0x143 is set to 0x0, which basically means that it has no extra support for GBC.
Pokemon Yellow, on the other hand, has the flag set to 0x80, which means it takes advantage of the GBC and also works on the GB.

If there is colorization, I must be missing it.

what about modding red and blue to use palettes in the same way yellow does. I assume yellow has the palettes embeded in the rom somewhere. I have no knowledge of how gameboy ganes operate so I am just throwing ideas (however stupid they may be)
That would most likely be possible, but that would involve quite a bit of Assembly modification. The colorization hack would be a good place to start.
 

froggestspirit

Aspiring Game Dev
Member
Joined
Jul 28, 2011
Messages
1,281
Trophies
1
XP
1,561
Country
United States
The brown tile color bug is probably from the actual pallete index. Maybe it get's overwritten, or worse, the timing of being able to access the GBC's color palette registers is different on the emulator. Has anyone tried the color hack with vanilla graphics in the old GB VC? Or someone tell me how to pack/unpack the VC, and I might look into it

Edit: Like @TheStoneBanana said, you can change the header of Red/Blue to 0x80 like yellows for GBC palletes, but I'm still confident that the full color hack shouldn't be hard.
 
Last edited by froggestspirit,

izy

Advanced Tech Pleb
Member
Joined
Sep 17, 2010
Messages
2,311
Trophies
2
XP
4,029
Country
United Kingdom
yeah, I've played the full color version on an emulator before.
To my understanding, the full color version basically has every color planned,
however I was referring to the tradition way: selecting a palette at boot screen.

Or perhaps having the system to change colors properly,
like what SGB2 does here:

Problem is there is no option to do that unless they coded it.
Only things you can do are Hold Start on Boot for gameboy border and downscaling
Old L + R for the green overlay
Btw the overlay colour and the Fullscreen size can be edited in config, they have no effect on the palette

Btw the Gameboy Play acts as a GBA including palettes
The Super Gameboy is different its actually GB hardware inside the cart and the console overides palettes

Color Palette: Choose from one of 32 pre-made color palettes, the Super Game Boy enhanced palette(s) (if available), or a user-created palette (if available)

The only reason the SGB has correct colours is because he can swap palettes and has overided them with a better looking usermade one.

You clearly see him change palettes manually at the end on indigo road
 
  • Like
Reactions: Queno138

Queno138

Ravens
Member
Joined
Sep 18, 2010
Messages
2,425
Trophies
0
Location
Luigi's Dark Mansion
XP
1,070
Country
Senegal
In Pokemon Red and Blue's header, the GBC flag at 0x143 is set to 0x0, which basically means that it has no extra support for GBC.
Pokemon Yellow, on the other hand, has the flag set to 0x80, which means it takes advantage of the GBC and also works on the GB.

If there is colorization, I must be missing it.

Thanks for that info, I need to test something.

Lol, changing that flag wasn't good enough.
colors need to be set too.

to my recollection, every map pallette needs to be set in the rom.
 
Last edited by Queno138,

kohu

Active Member
Newcomer
Joined
Apr 19, 2007
Messages
38
Trophies
0
XP
273
Country
United States
@froggestspirit

To start the GBC flag of the full color hack, vanilla sprites is 0xC0 (GBC Only).

I've injected the vanilla sprite full color hack into both the old and new VC emulator just now. There is a problem with the new emu with how it handles pallet index 16 through 23 it seems. Or I can at least confirm 24,25,26 and 27 work as seen by the top of the buildings. This is common in my finds across all GBC only injected roms. Yellow is 0x80 (GBC & GB Compatible) as stated before, and DOES NOT make use of Pallets above 15.

Here is what it looks like in the old VC emulator used by many existing GBC games:

red full colo hack old VC.jpg

and the same rom injected into Pokemon red's release - Note that while it is Pokemon red the same discoloration effects occur in yellow, I was just testing network patches at the same time! :

red full color hack new VC.jpg

And a screencap of the pallets used by the rom in VBA

pallets.png
 
  • Like
Reactions: Queno138 and cearp

shinyquagsire23

SALT/Sm4sh Leak Guy
Member
Joined
Nov 18, 2012
Messages
1,977
Trophies
2
Age
26
Location
Las Vegas
XP
3,765
Country
United States
@froggestspirit

To start the GBC flag of the full color hack, vanilla sprites is 0xC0 (GBC Only).

I've injected the vanilla sprite full color hack into both the old and new VC emulator just now. There is a problem with the new emu with how it handles pallet index 16 through 23 it seems. Or I can at least confirm 24,25,26 and 27 work as seen by the top of the buildings. This is common in my finds across all GBC only injected roms. Yellow is 0x80 (GBC & GB Compatible) as stated before, and DOES NOT make use of Pallets above 15.

Here is what it looks like in the old VC emulator used by many existing GBC games:

View attachment 40637

and the same rom injected into Pokemon red's release - Note that while it is Pokemon red the same discoloration effects occur in yellow, I was just testing network patches at the same time! :

View attachment 40639

And a screencap of the pallets used by the rom in VBA

View attachment 40640
Did you make sure to remove the .patch files before injecting? If you did, I wonder if the emulator itself is false-firing on either the Jynx censorship or something else...
 

kohu

Active Member
Newcomer
Joined
Apr 19, 2007
Messages
38
Trophies
0
XP
273
Country
United States
Did you make sure to remove the .patch files before injecting? If you did, I wonder if the emulator itself is false-firing on either the Jynx censorship or something else...
In my previous test yes. Crystal, Gold and Links Awakening all had those patches removed from the romfs entirely.

In my full color hack test I did not remove patches as I wanted to see if network functions worked. They do! Give me one sec and I'll try it with patches removed.

EDIT:

Just loaded up the full color hack with all patches removed from the ROMFS. No visible change in the over world graphics with pallet 4 and 5 still being displayed incorrectly.
 
Last edited by kohu,
  • Like
Reactions: Queno138

froggestspirit

Aspiring Game Dev
Member
Joined
Jul 28, 2011
Messages
1,281
Trophies
1
XP
1,561
Country
United States
I made the game as a GBC only (0xC0) so I didn't have to juggle two different modes. I'm still having issues rebuilding the cia (using @MrCheeze 's files earlier in the thread).
I'd say remove all patches first...

Also, anyone else notice the pikachu bcstm's? I'm betting it's more than possible to make custom patches to have full-soundtrack replacements!

Edit: @kohu try removing nwlyt_ConstColorShader.shbin?
 
Last edited by froggestspirit,
  • Like
Reactions: Queno138

kohu

Active Member
Newcomer
Joined
Apr 19, 2007
Messages
38
Trophies
0
XP
273
Country
United States
I made the game as a GBC only (0xC0) so I didn't have to juggle two different modes. I'm still having issues rebuilding the cia (using @MrCheeze 's files earlier in the thread).
I'd say remove all patches first...

Also, anyone else notice the pikachu bcstm's? I'm betting it's more than possible to make custom patches to have full-soundtrack replacements!

The new VC ones seem to be missing the logo.bin causing those tools not not want to repack right without a donor logo.bin. I've been using Hans romfs replacement to inject the roms and remove the patches to get around that hassle for the most part.

I did notice the sounds files too and thought the same thing ahaha.
 

Deleted member 370283

Well-Known Member
Member
Joined
Aug 19, 2015
Messages
496
Trophies
0
Age
22
XP
1,021
Country
United States
Those BCSTM files are for Pikachu's PCM samples if my exploration proves me right.
Within the patches are PLAY_MUTE (which stops the samples from playing), PLAY_HACK, and PLAY_NEW, which all basically play into using these clearer sound samples.
 

angrybanana5000

Member
Newcomer
Joined
Oct 13, 2010
Messages
23
Trophies
0
XP
144
Country
United States
I'm a novice when it comes to assembly, but going from the pokered disassembly SGB palette data is already defined for game states (in battle, in over world, nidorino intro screen etc) and the colors themselves.
There is a ram address that, when the value is 1, will display the SGB colors. Theoretically, if you use the VC patch to set that address to 1 then the colors should show up.
 

Deleted member 370283

Well-Known Member
Member
Joined
Aug 19, 2015
Messages
496
Trophies
0
Age
22
XP
1,021
Country
United States
I'm a novice when it comes to assembly, but going from the pokered disassembly SGB palette data is already defined for game states (in battle, in over world, nidorino intro screen etc) and the colors themselves.
There is a ram address that, when the value is 1, will display the SGB colors. Theoretically, if you use the VC patch to set that address to 1 then the colors should show up.
I don't think it'd be quite that simple.
Considering that Pokemon Red and Blue are enhanced using the Super Gameboy, it would probably just try to use Super Gameboy features (which don't exist here) and crash.
 

kohu

Active Member
Newcomer
Joined
Apr 19, 2007
Messages
38
Trophies
0
XP
273
Country
United States
@froggestspirit

When removing nwlyt_ConstColorShader.shbin the 3DS crashes. I Actually had a similar idea but instead compared the hash on each file in the shader directory to that of the older VC release. All the files were the same if I recall. I also tried replacing shader.shbin on the root to that with one of the older VC release where crystal injection would work and no changes occurred in the overworld.

While I'm at it I should also say that I tried replacing the config.ini from the older VC releases with no visible change. Not a big surprise as the configs are nearly identical.

@TheStoneBanana

Yes, I thought the same thing when exploring the yellow specific patches.
 
Last edited by kohu,

Deleted member 370283

Well-Known Member
Member
Joined
Aug 19, 2015
Messages
496
Trophies
0
Age
22
XP
1,021
Country
United States
A bit off topic, but how does Mode 2 in VC patches work? It's apparently called FixValue, but all it does is take an address and then one of many MANY types.
I can't make heads or tails of it.
 

kohu

Active Member
Newcomer
Joined
Apr 19, 2007
Messages
38
Trophies
0
XP
273
Country
United States
A bit off topic, but how does Mode 2 in VC patches work? It's apparently called FixValue, but all it does is take an address and then one of many MANY types.
I can't make heads or tails of it.

I really wish I knew as well. I don't have any background in patches like these sadly. I was puzzled by the type as well. Would a predefined change hardcoded in the emulator itself make sense? And the address + type just tell the emulator where to start which fix? This is speculation on my end...a solution like that doesn't seem very scalable.

I do know [Change_MSG] (as the name implies) changes the message the NPC says when you exit the link interface from "the link has been disconnected due to inactivity" Or something like that (working from memory) to "Please come again!".
 

Deleted member 370283

Well-Known Member
Member
Joined
Aug 19, 2015
Messages
496
Trophies
0
Age
22
XP
1,021
Country
United States
Yep, Mode 1 is pretty easy to understand.
Just define an address in the ROM, and then give the values to replace the existing data at the given address.

Mode 2 though... it's not clear at all.

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

Sorry about the double post, but I feel the need to mention this.
If you are more comfortable using HANS to modify the Pokemon VC game files, there's something you can do to get the game to boot with HANS.
Basically, just delete all of the leftover junk patches and JP/EUR language files. It will significantly reduce the size of the app, and in return, makes it work with HANS! :D
 

shinyquagsire23

SALT/Sm4sh Leak Guy
Member
Joined
Nov 18, 2012
Messages
1,977
Trophies
2
Age
26
Location
Las Vegas
XP
3,765
Country
United States
Yep, Mode 1 is pretty easy to understand.
Just define an address in the ROM, and then give the values to replace the existing data at the given address.

Mode 2 though... it's not clear at all.

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

Sorry about the double post, but I feel the need to mention this.
If you are more comfortable using HANS to modify the Pokemon VC game files, there's something you can do to get the game to boot with HANS.
Basically, just delete all of the leftover junk patches and JP/EUR language files. It will significantly reduce the size of the app, and in return, makes it work with HANS! :D
Wait, are they actually buffering all those files in RAM or something? Maybe that could just be edited in the code in the first place to not load .patch files.
 

izy

Advanced Tech Pleb
Member
Joined
Sep 17, 2010
Messages
2,311
Trophies
2
XP
4,029
Country
United Kingdom
The new VC ones seem to be missing the logo.bin causing those tools not not want to repack right without a donor logo.bin. I've been using Hans romfs replacement to inject the roms and remove the patches to get around that hassle for the most part.

I did notice the sounds files too and thought the same thing ahaha.
I used 3DS builder to Repack because the tools kept getting angry at me and also failing. I renamed Icon.bin to Logo.bin seems to be the same file


Btw all those patch files in the ROMFS dont really affect much

heres the entire list of what they do its mainly for networking

http://pastebin.com/FQzJWKGk
 

Site & Scene News

Popular threads in this forum

General chit-chat
Help Users
  • No one is chatting at the moment.
    NinStar @ NinStar: CRAZY HAMBURGER