Error in F-1 Race (1984)

Discuss emulation of the Nintendo Entertainment System and Famicom.

Moderator: Moderators

tepples
Posts: 22705
Joined: Sun Sep 19, 2004 11:12 pm
Location: NE Indiana, USA (NTSC)
Contact:

Re: Error in F-1 Race (1984)

Post by tepples »

Based on how I understand the code, it'd fail on an NES. I'd like to see someone run it on an NES through an NES-JOINT.
WedNESday
Posts: 1284
Joined: Thu Sep 15, 2005 9:23 am
Location: Berlin, Germany
Contact:

Re: Error in F-1 Race (1984)

Post by WedNESday »

tepples wrote:Based on how I understand the code, it'd fail on an NES. I'd like to see someone run it on an NES through an NES-JOINT.
So it was an unreleased game? Or a game that didn't always start?
tepples
Posts: 22705
Joined: Sun Sep 19, 2004 11:12 pm
Location: NE Indiana, USA (NTSC)
Contact:

Re: Error in F-1 Race (1984)

Post by tepples »

It was released in Japan only, which is why I used the term "cassette" earlier. (NES-JOINT is the Famicom-to-NES adapter PCB in certain North American NES launch titles, especially the ones that use R.O.B.) My hypothesis is that it might not work if reset, which is why I requested confirmation on the console by rolling a JOINT (inserting the PCB into an NES-JOINT, putting the combined PCB into an NES Game Pak shell, and playing that on an NES).
lidnariq
Posts: 11430
Joined: Sun Apr 13, 2008 11:12 am

Re: Error in F-1 Race (1984)

Post by lidnariq »

lidnariq wrote:If I hack up fceu to always press start, on boot it hangs on a grey screen.
WedNESday wrote:Too hard to understand that it doesn't happen on a real NES? Or on anyone else's emulator? Then there IS something wrong with your emulator. Stop trying to pin this on the game's developer.
Someone's wrong here, and it's not Zepper.
WedNESday
Posts: 1284
Joined: Thu Sep 15, 2005 9:23 am
Location: Berlin, Germany
Contact:

Re: Error in F-1 Race (1984)

Post by WedNESday »

lidnariq wrote:
lidnariq wrote:If I hack up fceu to always press start, on boot it hangs on a grey screen.
WedNESday wrote:Too hard to understand that it doesn't happen on a real NES? Or on anyone else's emulator? Then there IS something wrong with your emulator. Stop trying to pin this on the game's developer.
Someone's wrong here, and it's not Zepper.
So are you saying that by the game not running RockNES is accurate?
User avatar
Zepper
Formerly Fx3
Posts: 3262
Joined: Fri Nov 12, 2004 4:59 pm
Location: Brazil
Contact:

Re: Error in F-1 Race (1984)

Post by Zepper »

A light of hope. ^_^;; I really want to try out once my F1 copy arrives.
User avatar
Zepper
Formerly Fx3
Posts: 3262
Joined: Fri Nov 12, 2004 4:59 pm
Location: Brazil
Contact:

Re: Error in F-1 Race (1984)

Post by Zepper »

WedNESday wrote:
lidnariq wrote:
lidnariq wrote:If I hack up fceu to always press start, on boot it hangs on a grey screen.
WedNESday wrote:Too hard to understand that it doesn't happen on a real NES? Or on anyone else's emulator? Then there IS something wrong with your emulator. Stop trying to pin this on the game's developer.
Someone's wrong here, and it's not Zepper.
So are you saying that by the game not running RockNES is accurate?
The game runs on RockNES. I've found that if I keep pressed "A" on ROM boot, it freezes. Did you understand?
WedNESday
Posts: 1284
Joined: Thu Sep 15, 2005 9:23 am
Location: Berlin, Germany
Contact:

Re: Error in F-1 Race (1984)

Post by WedNESday »

Zepper wrote:The game runs on RockNES. I've found that if I keep pressed "A" on ROM boot, it freezes. Did you understand?
You never mentioned that.
lidnariq
Posts: 11430
Joined: Sun Apr 13, 2008 11:12 am

Re: Error in F-1 Race (1984)

Post by lidnariq »

Here's the patch to modify fceu-0.98.12 to always press start:

Code: Select all

--- input.c.old	2004-05-16 20:39:33.000000000 -0700
+++ input.c	2014-01-07 12:54:41.907552154 -0800
@@ -96,7 +96,7 @@
 
 static uint8 FP_FASTAPASS(1) ReadGP(int w)
 {
-                uint8 ret;
+                /*uint8 ret;
 
                 if(joy_readbit[w]>=8)
                  ret = ((joy[2+w]>>(joy_readbit[w]&7))&1);
@@ -110,10 +110,10 @@
 		else
 		{
                  if(joy_readbit[w]==19-w) ret|=1;
-		}
+		}*/
 		if(!fceuindbg)
 		 joy_readbit[w]++;
-                return ret;
+                return (joy_readbit[w]==4);
 }
 
 static DECLFR(JPRead)
With patch: Game hangs on boot with a solid grey screen, plays pause sound effect. Without patch: Game plays correctly.

Here's the patch to modify nestopia-1.45-75-g6661cf5 (HEAD as-of a week ago):

Code: Select all

diff --git a/source/core/input/NstInpPad.cpp b/source/core/input/NstInpPad.cpp
index 8490207..6c614ab 100644
--- a/source/core/input/NstInpPad.cpp
+++ b/source/core/input/NstInpPad.cpp
@@ -129,6 +129,7 @@ namespace Nes
 
                        uint Pad::Peek(uint port)
                        {
+                       /*
                                if (strobe == 0)
                                {
                                        const uint data = stream;
@@ -141,6 +142,8 @@ namespace Nes
                                        Poll();
                                        return state & 0x1;
                                }
+                       */
+                       return 1;
                        }
 
                        void Pad::Poke(const uint data)
With patch: Game hangs with a triangular checkerboard of grey and purple, word "PAUSE" appears in cyan. Without patch: game plays normally.

Alternatively, if I take unpatched nestopia, and hold down START then momentarily hit the button for "soft reset", it draws "PAUSE" over whatever screen was present before I reset, and then never responds again.

Conclusion: Game incorrectly starts up in play mode, and so takes start to mean "pause the game". Normally it would go straight to the mode select, but if you're sufficiently early it does the wrong thing and crashes waiting for the sprite 0 hit.
User avatar
Zepper
Formerly Fx3
Posts: 3262
Joined: Fri Nov 12, 2004 4:59 pm
Location: Brazil
Contact:

Re: Error in F-1 Race (1984)

Post by Zepper »

It's possible to reproduce the bug without the patch, but you need a bit of lucky. I did it right now, a couple of times. :) Hold START and activate Soft RESET on Nestopia. Just be quick and not a moron on button presses.
WedNESday
Posts: 1284
Joined: Thu Sep 15, 2005 9:23 am
Location: Berlin, Germany
Contact:

Re: Error in F-1 Race (1984)

Post by WedNESday »

Zepper wrote:Just be quick and not a moron on button presses.
That about me?
User avatar
Zepper
Formerly Fx3
Posts: 3262
Joined: Fri Nov 12, 2004 4:59 pm
Location: Brazil
Contact:

Re: Error in F-1 Race (1984)

Post by Zepper »

Lol, no no! :)
User avatar
*Spitfire_NES*
Posts: 306
Joined: Fri May 21, 2010 4:10 pm

Re: Error in F-1 Race (1984)

Post by *Spitfire_NES* »

Sorry to dig this back up, but a prototype of F-1 race was released by Skrybe over at lost levels yesterday. The prototype seems to jump right into the race on nestopia. With this being a proto, these issues are seemingly related correct? He states it works fine in fce but not nestopia, so im wondering which one is right?
Sour
Posts: 890
Joined: Sun Feb 07, 2016 6:16 pm

Re: Error in F-1 Race (1984)

Post by Sour »

Just for fun, tested with the emus I had:
FCEUX/Nintendulator/MyNes/Mesen all display the title screen first.
Nestopia UE/puNES both skip the title screen and start a race immediately.

Since both Nestopia & puNES have no debugger, figuring out why their behavior is different might be a bit of a pain.
User avatar
*Spitfire_NES*
Posts: 306
Joined: Fri May 21, 2010 4:10 pm

Re: Error in F-1 Race (1984)

Post by *Spitfire_NES* »

Sour wrote:Just for fun, tested with the emus I had:
FCEUX/Nintendulator/MyNes/Mesen all display the title screen first.
Nestopia UE/puNES both skip the title screen and start a race immediately.

Since both Nestopia & puNES have no debugger, figuring out why their behavior is different might be a bit of a pain.
so this newly released prototype is messed up in puNes and nestopia then? Its possibly the same issue. After reading through this thread i see there was nothing wrong the emulators running this.

This seems to be a new issue then. Has anyone else tried this proto on their emu? Rocknes, james emu and others?
Post Reply