MMC5 and Retro City Rampage

Discuss emulation of the Nintendo Entertainment System and Famicom.

Moderator: Moderators

Post Reply
User avatar
colinvella
Posts: 74
Joined: Sun Jun 05, 2016 1:41 pm

MMC5 and Retro City Rampage

Post by colinvella » Fri Jul 01, 2016 6:47 am

Hi,

Has anyone encountered any issues emulating Retro City Rampage? I'm getting garbled backgrounds in both the intro screen and gameplay. The nametables seem to be the correct ones, but the referenced CHR tiles are clearly wrong. The sprites seem to be rendering well. Apparently the game uses the 8x8 sprite mode in MMC5, so the bank registers used (A: $5120-$5127 or B: $5128-$512B) depend on the last set written to. The game seems to be assigning CHR banks to the B registers, but at no point did I detect setting of the CHR mode (which I assume is 0 by default). Writing to these 4 B registers leads me to think that the initial value for CHR mode should be 3 (1K banks) instead of 0, but all MMC5 implementations I have found seem to assume CHR mode 0 is the initial value.

Does anyone have any experience with Retro City Rampage?

Thanks
Tile IDE and tile engine for XNA: http://tide.codeplex.com/
Fancy Fish Mod - Minecraft Mod: http://fancyfishmod.weebly.com/

User avatar
Zepper
Formerly Fx3
Posts: 3192
Joined: Fri Nov 12, 2004 4:59 pm
Location: Brazil
Contact:

Re: MMC5 and Retro City Rampage

Post by Zepper » Fri Jul 01, 2016 2:07 pm

There's a basic implementation of MMC5 that runs, for example, CastleVania 3. A more complete thing will run Uncharted Waters and other Koei games (extended attribute mode, where each tile can take a specific CHR bank). Only Vertical Split Mode isn't required, as just ONE game uses it.

In my emulator (RockNES), it's added since 2012. I tested this game and seems to work fine.

User avatar
colinvella
Posts: 74
Joined: Sun Jun 05, 2016 1:41 pm

Re: MMC5 and Retro City Rampage

Post by colinvella » Fri Jul 01, 2016 2:20 pm

Zepper wrote:There's a basic implementation of MMC5 that runs, for example, CastleVania 3. A more complete thing will run Uncharted Waters and other Koei games (extended attribute mode, where each tile can take a specific CHR bank). Only Vertical Split Mode isn't required, as just ONE game uses it.

In my emulator (RockNES), it's added since 2012. I tested this game and seems to work fine.
I'm at the stage where Castlevania III works, except perhaps for the rising water level, which apparently uses Ex Ram Mode 1. Indeed, I suspect the problem with Retro City Rampage is that I have yet to implement this. From what I understand, the MMC5 Ex Ram Mode 1 is intended to go around the limitation of tile attributes being shared by 2x2 tile groups and instead specifying independent attributes for each tile.

Now that I think of it, the game does set the B registers without specifying CHR Bank Mode 3, but I suspect that since the game is using Ex Ram Mode 1, 1K CHR banks are assumed, regardless of CHR Bank mode.

Am I on the correct track here, or am I spewing nonsense? :)
Tile IDE and tile engine for XNA: http://tide.codeplex.com/
Fancy Fish Mod - Minecraft Mod: http://fancyfishmod.weebly.com/

User avatar
colinvella
Posts: 74
Joined: Sun Jun 05, 2016 1:41 pm

Re: MMC5 and Retro City Rampage

Post by colinvella » Sat Jul 02, 2016 4:23 pm

I finally managed to implement Extended Ram Mode 1 graphics!

Retro City Rampage is working quite well. One notable glitch is that the character dialogue at the top on starting to play doesn't show up. It does show up however, when you get out of the car and your NPC ally tells you to get back inside the car. The glitch may be due to IRQ counting code, but I'm not sure as yet.

RCR Intro
Image

RCR Gameplay initial dialogue (glitch here)
Image

RCR gameplay - driving car
Image
Tile IDE and tile engine for XNA: http://tide.codeplex.com/
Fancy Fish Mod - Minecraft Mod: http://fancyfishmod.weebly.com/

User avatar
Zepper
Formerly Fx3
Posts: 3192
Joined: Fri Nov 12, 2004 4:59 pm
Location: Brazil
Contact:

Re: MMC5 and Retro City Rampage

Post by Zepper » Sat Jul 02, 2016 6:29 pm

Uh... same glitch here. ^_^;; It seems to be IRQ-timing related.

zxbdragon
Posts: 482
Joined: Mon Dec 12, 2011 8:15 pm

Re: MMC5 and Retro City Rampage

Post by zxbdragon » Sat Jul 02, 2016 8:20 pm

real machine video working fine?

User avatar
Zepper
Formerly Fx3
Posts: 3192
Joined: Fri Nov 12, 2004 4:59 pm
Location: Brazil
Contact:

Re: MMC5 and Retro City Rampage

Post by Zepper » Sat Jul 02, 2016 8:33 pm

zxbdragon wrote:real machine video working fine?
Nintendulator also has that glitched tiles on the bottom of the screen.

zxbdragon
Posts: 482
Joined: Mon Dec 12, 2011 8:15 pm

Re: MMC5 and Retro City Rampage

Post by zxbdragon » Sun Jul 03, 2016 1:01 am

Zepper wrote:
zxbdragon wrote:real machine video working fine?
Nintendulator also has that glitched tiles on the bottom of the screen.
Thank you, I know ! but real machine not glitched?

User avatar
rainwarrior
Posts: 7804
Joined: Sun Jan 22, 2012 12:03 pm
Location: Canada
Contact:

Re: MMC5 and Retro City Rampage

Post by rainwarrior » Sun Jul 03, 2016 1:21 am

It's likely never been tested on a real MMC5.

User avatar
colinvella
Posts: 74
Joined: Sun Jun 05, 2016 1:41 pm

Re: MMC5 and Retro City Rampage

Post by colinvella » Sun Jul 03, 2016 1:28 am

I don't have the means to test it on a real NES, but on Nestopia it doesn't glitch like this. Note that the issue isn't just the glitch tiles at the bottom, but also the blank panel at the top, which is supposed to contain dialogue between characters. Strangely enough, dialogue graphics do appear in mid gameplay, so perhaps it is due to some initialisation/IRQ issue.
Tile IDE and tile engine for XNA: http://tide.codeplex.com/
Fancy Fish Mod - Minecraft Mod: http://fancyfishmod.weebly.com/

User avatar
thefox
Posts: 3141
Joined: Mon Jan 03, 2005 10:36 am
Location: Tampere, Finland
Contact:

Re: MMC5 and Retro City Rampage

Post by thefox » Sun Jul 03, 2016 1:45 am

rainwarrior wrote:It's likely never been tested on a real MMC5.
I would not be surprised if Brian tested it on a real MMC5. He was showing some kind of custom hardware development setup on his (now gone) website.
Download STREEMERZ for NES from fauxgame.com! — Some other stuff I've done: fo.aspekt.fi

User avatar
zeroone
Posts: 932
Joined: Mon Dec 29, 2014 1:46 pm
Location: New York, NY
Contact:

Re: MMC5 and Retro City Rampage

Post by zeroone » Sun Jul 03, 2016 8:45 pm

Can anyone provide a link to the ROM?

User avatar
Memblers
Site Admin
Posts: 3820
Joined: Mon Sep 20, 2004 6:04 am
Location: Indianapolis
Contact:

Re: MMC5 and Retro City Rampage

Post by Memblers » Sun Jul 03, 2016 8:54 pm

zeroone wrote:Can anyone provide a link to the ROM?
Probably not, because it's included with the commercial game as a bonus, but it is really cheap to buy, I think it was just $1 or $2 when I bought it on sale through Steam. If you want to look around for it anyways though, the NES version was called "ROM City Rampage".

Bavi_H
Posts: 122
Joined: Sun Mar 03, 2013 1:52 am
Location: Texas, USA
Contact:

Re: MMC5 and Retro City Rampage

Post by Bavi_H » Mon Jul 04, 2016 9:28 am

zeroone wrote:Can anyone provide a link to the ROM?
Memblers wrote:Probably not, because it's included with the commercial game as a bonus, but it is really cheap to buy, I think it was just $1 or $2 when I bought it on sale through Steam. If you want to look around for it anyways though, the NES version was called "ROM City Rampage".
Retro City Rampage is the full game available for PC and modern consoles. The prototype NES version is called ROM City Rampage.

In the full game, you can go to one of the arcades and play the prototype NES version as an Easter egg. The NES ROM isn't directly distributed with the game, but you can extract the needed PRG and CHR data and add an appropriate header to make a usable NES ROM. The steps are available in: Be aware that the NES version is not the complete game, it's just a demo. You can walk around the overworld or get in a car and bump people around, but there are no goals or other game levels. There is no audio.

Edit: Removed session ID from romhacking.net link.
Last edited by Bavi_H on Sun Jul 17, 2016 10:05 am, edited 1 time in total.

User avatar
rainwarrior
Posts: 7804
Joined: Sun Jan 22, 2012 12:03 pm
Location: Canada
Contact:

Re: MMC5 and Retro City Rampage

Post by rainwarrior » Mon Jul 04, 2016 9:53 am

thefox wrote:
rainwarrior wrote:It's likely never been tested on a real MMC5.
I would not be surprised if Brian tested it on a real MMC5. He was showing some kind of custom hardware development setup on his (now gone) website.
I would.

The ROM doesn't even initialize OAM properly before the title screen comes up. If you run it on a PowerPak you'll see random sprite tiles on the screen at startup. (OAM decay issue, I think.)

(Otherwise, PowerPak with Loopy's partial MMC5 does pretty much the same thing as discussed w.r.t. flickering text window, etc.)

This game runs "correctly" only in the emulator that ships with Retro City Rampage. Don't take it as something a correct MMC5 emulation should run glitch-free.

I'm not trying to diminish the value of his work, it's a fantastic proof of concept, but it is NOT a suitable test for emulation accuracy.

Post Reply