[Available] Modified PICKnMIX for leonk's Vortex carts

The only new thing to note is that the Unibios in-game menu is corrupted on Zintrick but upon going back to using a standard Unibios 4.0, the behavior is the same. Not knowing anything about this hack, I'm not sure if this would be fixable, in MAME testing pierpa's newer conversions don't have the same issue. The menu still functions, the text and border are corrupted though.
It's because the UB uses tiles from the game's S/Fix-Rom and that particular ROM is not following the rules like any other S Rom (with the System Fonts etc.).
It would be fixable, but it requires 2 Steps:
1. Move all tiles in zintrick's S rom that are actually used in the game towards the end of the rom, so that the first part can be filled with standard tiledata.
2. Patch the game's tilemap to use the moved tilenumbers.

Alternatively you could add a condition in unibios:
if game[NGH] is zintrickb
then use other tilemap for UB-Menu.

_but I doubt you have space left for that_
 
It's because the UB uses tiles from the game's S/Fix-Rom and that particular ROM is not following the rules like any other S Rom (with the System Fonts etc.).
It would be fixable, but it requires 2 Steps:
1. Move all tiles in zintrick's S rom that are actually used in the game towards the end of the rom, so that the first part can be filled with standard tiledata.
2. Patch the game's tilemap to use the moved tilenumbers.

Alternatively you could add a condition in unibios:
if game[NGH] is zintrickb
then use other tilemap for UB-Menu.

_but I doubt you have space left for that_

Thanks for the info, yeah in this case, since this is for existing carts the game rom can't be changed and indeed the amount of available space in the bios is becoming vanishingly small.

Will just have to be included as a known bug. At least it still seems to work and has cheats, just need to navigate the three main menu options 'blind'.
 
Here is a version that can exit to the Vortex menu, big thanks to the chunk of code provided by @ArcadeTV.

On cold boot it goes to the Vortex menu. Warm Unibios reset stays at the same selected title and PnM doesn't activate.

On cold boot+Start it goes to PICKnMix. Warm Unibios reset stays at the same selected title and PnM stays active.

On warm reset+B when in a game (whether selected from Vortex or PnM) it returns to Vortex menu.

On warm reset+Start when in a game (whether selected from Vortex or PnM) it returns to PICKnMIX mode.

What combination did I forget?

I still want to look into reversing the default too. Auto boot to PnM and hold Start on boot/reset to send it to the Vortex menu.

View: https://youtu.be/AMygm_J56kg?is=3RVnwQYwZZq1th3D
 
Last edited:
And this is what I ended up using, appropriating zardam's Return To Menu unibios mod and inserting the code ArcadeTV suggested into the path. I also changed the values at $80 from 4646 to 4C4C although I admit I don't really understand what function that is serving. The instruction at $C1BBC6 in the original code is just a straight jmp to $C11002, the same instruction that the modified chunk ends on.

Code:
 C1BBC6  jmp     $c1ffd0.l                                   4EF9 00C1 FFD0
...
 C1FFD0  move.b  $300000.l, D0                               1039 0030 0000
 C1FFD6  btst    #$5, D0                                     0800 0005
 C1FFDA  bne     $c1ffea                                     660E
 C1FFDC  bclr    #$7, ($b35,A5)                              08AD 0007 0B35
 C1FFE2  move.w  #$0, $2c0fee.l                              33FC 0000 002C 0FEE
 C1FFEA  jmp     $c11002.l                                   4EF9 00C1 1002
 
Last edited:
Hi lithy,

thanks for sharing the updated code — it is great to see that the information from our reverse-engineering work was useful. Your new reset hook also matches what we observed very closely:

Code:
move.b  $300000.l,D0
btst    #$5,D0
bne     .continue
bclr    #$7,($b35,A5)
move.w  #$0,$2c0fee.l
.continue:
jmp     $c11002.l

Clearing
Code:
$10FE35.bit7
before switching GSEL back to 0 is the important part. We found that this bit survives the warm-reset preparation and is used by UniBIOS as PICK'N'MIX resume state. So simply writing GSEL 0 is not sufficient — UniBIOS can otherwise see the preserved PNM state and resume that path instead of returning cleanly to the VTX menu.

One other thing we looked into was your comment about changing ROM offset
Code:
$80
from:

Code:
4646 -> 4C4C

We decoded zardam's current
Code:
uni-bios_4_0_BackToMenu.bps
, and that change definitely originates there. What is particularly interesting is the history of the patch:

  • the older zardam patch explicitly NOPs the BIOS integrity/checksum test around
    Code:
    $11C62
    ;
  • the newer BackToMenu BPS leaves that integrity-check code untouched;
  • instead, it changes the word at ROM offset
    Code:
    $80
    from
    Code:
    $4646
    to
    Code:
    $4C4C
    .

So our strong suspicion is that
Code:
$80
is being used as a checksum/integrity fix-up word in the newer patch, allowing the original UniBIOS integrity test to remain intact.

We have not yet reconstructed the exact checksum arithmetic around
Code:
$C11C62
, so I would not call that completely proven yet. But the patch history is a pretty strong indication of what
Code:
$4C4C
is doing.

There is one potentially important consequence for your modified BIOS:
Code:
$4C4C
may be specific to zardam's exact BackToMenu binary. Since you have now added additional code, the mathematically correct fix-up value for your build could in principle be different. If we get a copy of your resulting BIOS/BPS at some point, we can disassemble the integrity routine and calculate the correct value instead of relying on
Code:
$4C4C
by inheritance.

On our side the VTX project has also moved quite a bit further. We already have a completely new menu intended to replace the old one. Besides the rewritten menu logic it now supports things such as:

  • game artwork,
  • sprite graphics,
  • audio,
  • integrated Soft-DIP management.

We also have a generator now which uses a new CSV database together with the
Code:
games.txt
produced for
Code:
VTXCart.exe
. From that common data source we can generate/control the game ordering and metadata for all three sides:

Code:
new VTX menu
PICK'N'MIX
Attract Mode

So the intention is that the menu, PNM and attract rotation no longer evolve as three independent game lists — they can all be derived from the same source data.

There was one additional complication caused by the new menu: because it now has its own sprites and audio resources, the original
Code:
VTXCart.exe
behaviour for
Code:
Mode=1
was no longer sufficient for our layout. We therefore had to patch
Code:
VTXCart.exe
for the
Code:
Mode=1
generation path as well.

At the moment we are also modelling the stock 161-in-1/PICK'N'MIX behaviour in MAME in quite some detail. Among other things we now have the original selector semantics, the stock helper/MCU behaviour, PNM manual launch/reload and attract switching running against the VTX mapping. That work is actually what exposed the
Code:
$10FE35.bit7
reset behaviour in the first place.

So your BIOS work and our MAME/menu work are starting to meet in some very useful places.
 
0005.png

I went ahead and made a softdip setting for Pick'n'Mix, controlled by the menu.
Now you can switch PNM on any time and off without having to power off your hardware.
 
Here is a version that can exit to the Vortex menu, big thanks to the chunk of code provided by @ArcadeTV.

On cold boot it goes to the Vortex menu. Warm Unibios reset stays at the same selected title and PnM doesn't activate.

On cold boot+Start it goes to PICKnMix. Warm Unibios reset stays at the same selected title and PnM stays active.

On warm reset+B when in a game (whether selected from Vortex or PnM) it returns to Vortex menu.

On warm reset+Start when in a game (whether selected from Vortex or PnM) it returns to PICKnMIX mode.

What combination did I forget?

I still want to look into reversing the default too. Auto boot to PnM and hold Start on boot/reset to send it to the Vortex menu.

View: https://youtu.be/AMygm_J56kg?is=3RVnwQYwZZq1th3D

Regarding reversing the default, you can check out https://www.arcade-projects.com/thr...knmix-boot-on-default-warm-reset-patch.35287/

It's on the stock 161-in-1 v1/2 but it might help.

I have my notes buried somewhere, I'll try to post them up.
 
A GitHub fork has been created with IPS patch files for Unibios 4.0 to create two different versions of a bios modified to work with leonk's gamelist. (Link added to Post #1 as well)

https://github.com/lithyV/ub_vortex_multicart_leonk

1) Autoboot to PnM with the standard Vortex menu inaccessible (Eye of Typhoon, Xeno Crisis, and 240P Test Suite not accessible).
2) Manual boot to PnM with 1P Start held during power on or soft reset. Hold B during soft reset to return to standard Vortex menu (Eye of Typhoon, Xeno Crisis, and 240P Test Suite available this way).

No real code included because well...I just kinda hack my way through it with a hex editor, but if anyone has any questions, feedback, or bug reports, I'd be happy to communicate about it.
 
  • Like
Reactions: nem
This is because when in free play King of the Monsters gets 'stuck' on the Game Compulsion screen and doesn't cycle out of its own attract mode.
Here's a patch for KING OF THE MONSTERS.
When applied, Attract Mode behaves the same between normal and free play, except "Insert Coin / Press Start".
 

Attachments

Last edited:
Just got my Vortex cart today with the modified PickNMix Bios (version that uses button combo to enable PickNMix) and I noticed an issue with League Bowling:



It can’t be started after selecting from the PickNMix menu. Pressing A lets me select the number of players, but as soon as I press A again to select the game type, it switches to the next game. Almost like it thinks attract mode is still running. If I just let the timers run out, I can get into the game, but then it plays weirdly. Most notably, the aiming meter moves really slow. Game works fine when booting from the standard Vortex menu.
 
Last edited:
Thanks for the report.

Interesting, I've confirmed the first behavior on mine as well. Also it seems like it no longer recognizes the start button after going back to the title. Even got it to trip an illegal instruction reset after moving around the PnM menu some more after that. Confirmed it happens regardless of Free Play On or Off. Also confirmed it also happens with the original zardam version as well as kuze's version. And of note that League Bowling is not on the standard 161-in-1, so like the Riding Hero bug, might just be an addressing conflict that didn't come up before.

The second part, the slow moving meters, I have had happen before even on a legit cart. I might suggest you try to clear the backup RAM and see if it fixes it. Mine seems to start normally if I just let the two timers run out.

Will look into it.
 
Last edited:
Also it seems like it no longer recognizes the start button after going back to the title.
Been playing a bit more today and just wanted to report that after going back to the title after playing a game, I can press Start, let the timers run out, and continue playing.

Edit: Ah, if you press start and then accidentally press a button and switch to the next game and then try to go back to League Bowling then the Start button isn’t recognized.
 
Last edited:
Back
Top