3.1.3 - Palette Shuffle Kerfuffle

Mihoshi20

Member
MermaysGarbledDen.png

Is there a portion of the engine's asm files where it's expecting to find the information placed in Bank16.asm aside from the BANK_PALETTES portion of constants.asm? I've ran into a snag when reassigning bank locations for data, everything was successful as exhibited by the first pair of screenshots which have had the data GraphicsBank00 moved to #$02, ObjectGraphicsBank00 moved to #$08, BANK_ANIMS moved to $03, BANK_TILES moved to $02, BANK_STARTSCREEN_CHR moved to #$02, BANK_PLAYER_CHR moved to #$02, and BANK_ANIMATIONS moved to #$03. LoadNametabeData and LoadAttributeData inside InitLoads.asm were both also changed to point to #$05.

Appropriate changes were made to constants.asm, bank16.asm, and AssignBanks.asm and played as normal with the changes. While the second pair of screenshots were the result of changing BANK_PALETTES in constants.asm from #$16 to #$04 and commenting out bank 23 (16)'s include portion and changing bank 4's include to that of Bank16.asm within the AssignBanks.asm file.

Any help in solving this mystery would be greatly appreciated. :?:
 

RadJunk

Administrator
Staff member
Oh yes...moving banks around is a big no no at this point, and will always lead to absolute chaos!

If you want to *add* things like new ASM routines to particular banks, 14 and 18 are currently 100% safe. But...for instance, graphic loads and screen data and all these things are pretty much locked and tied down in very particular ways.

My advice is...yeah, don't futz with any banking at all at this point, or you will absolutely end up breaking some of the crazy trampoline pointers that are required to do things so easily from the front end. :)
 

Mihoshi20

Member
TheNew8bitHeroes said:
Oh yes...moving banks around is a big no no at this point, and will always lead to absolute chaos!

If you want to *add* things like new ASM routines to particular banks, 14 and 18 are currently 100% safe. But...for instance, graphic loads and screen data and all these things are pretty much locked and tied down in very particular ways.

My advice is...yeah, don't futz with any banking at all at this point, or you will absolutely end up breaking some of the crazy trampoline pointers that are required to do things so easily from the front end. :)

LOL, fair enough, then I shall put my experimental plans to compact the data for a manual conversion to mapper 02 on hold... for now ;) and play by the rules. Thank you for the prompt reply and heads up. Though I'm still not sure as to why everything else worked when moved around but relocating bank16 broke everything. Digging through the asm files I didn't find anything obvious, unless I missed one little spot where it's hard coded to either expect the palette data or NT/Coll/Att pointers to be in bank 16 and just didn't find it. Once again though, thanks for the heads up!
 

RadJunk

Administrator
Staff member
Yeah bank 16 is mostly for pointers...and just about everything uses it. Palettes. Nametables. Etc.

But you shouldn't have to change out anything with the banks for it to work as a mapper 2 rom...only if you're trying to cram it down so you can use a donor cart or something. It should still read as mapper 2 even with all 32 banks of memory. :)
 

Mihoshi20

Member
TheNew8bitHeroes said:
Yeah bank 16 is mostly for pointers...and just about everything uses it. Palettes. Nametables. Etc.

But you shouldn't have to change out anything with the banks for it to work as a mapper 2 rom...only if you're trying to cram it down so you can use a donor cart or something. It should still read as mapper 2 even with all 32 banks of memory. :)

I tried it in FCEUX, just changing out the header for one of mapper 02 and I'd always get just a gray screen, I then just edited the mapper 30 header already in and would get the same results, so i then setout to cutting the banks in half from 32 to 16 ad that when I started trimming the fat, removing the underworld banks and commenting out references to them as they're not used and re-purposing the banks for important data instead and that's when I ran into the bank16 snag.
 

RadJunk

Administrator
Staff member
Yeah it’s not quiiiiiiiite that simple, but that’s one of the steps. By release, hopefully we’ll have a toggle :)
 

Mihoshi20

Member
TheNew8bitHeroes said:
Yeah it’s not quiiiiiiiite that simple, but that’s one of the steps. By release, hopefully we’ll have a toggle :)

That's okay, I couldn't leave well enough alone and did some more tinkering anyways and got the game running on real hardware. It's been just a fun little experiment for the time being to see if I could. I know mapper 02 is planned as a feature down the line anyways. A little exercise project and a good excuse to see what makes the engine tick. :geek: I'd post the pic here too but don't want to double upload the same image to the server and waste resources so you can see it running here if you'd like. http://nesmakers.com/viewtopic.php?f=13&t=180&start=10
 

Mihoshi20

Member
TheNew8bitHeroes said:
Hey! Could you share a vid? Would love to pimp it!

Sure, I don't have a tripod, fancy camera, or anything, but I could probably though still improvise a short vid of the cart going in and the game booting up and playing it for a bit, about to finish a new revision anyhow that I could test.
 

Mihoshi20

Member
TheNew8bitHeroes said:
Hey! Could you share a vid? Would love to pimp it!

Here you go, as requested. I made a short vid of the new version running.

Title Screen and some Gameplay
https://www.youtube.com/watch?v=hjLy8Bb9uKo

Full Gameplay
https://www.youtube.com/watch?v=rHDSIfCr-_U
 
Top Bottom