Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Pinball Deluxe/Fantasies completly broken #271

Open
sczther opened this issue Jun 3, 2016 · 4 comments
Open

Pinball Deluxe/Fantasies completly broken #271

sczther opened this issue Jun 3, 2016 · 4 comments
Labels
platform:GB/GBC Game Boy/Game Boy Color-related issues severity:minor bug Issues that only have a minor impact on the library
Milestone

Comments

@sczther
Copy link

sczther commented Jun 3, 2016

This game is well known for not working in emulators that are more accurate, it runs completely fine on old and hacky emulators such as no$gmb, but BGB, Gambatte and also mGBA have a problem with it. It runs on hardware just fine of course.

After selecting any of the tables, sound goes wonky, then garbage starts appearing and afterwards the screen switches colors around (something like b/w only, or white and dark grey, with a few things colored black) or into a solid wall of stripes and stops. The sound goes on for a while, but it's only screeching. After a while the screen is filled with tiled garbage. (Each of the tables behaves a bit differently, I tried to summarize)

@endrift endrift added the platform:GB/GBC Game Boy/Game Boy Color-related issues label Jun 23, 2016
@endrift endrift added this to the 1.0.0 milestone Aug 17, 2016
@endrift
Copy link
Member

endrift commented Sep 15, 2016

IDK, when I tried it it just seems to freeze up randomly (but then unfreeze a second or two later).

E] Nevermind, tried it again and it's completely broken.

@endrift
Copy link
Member

endrift commented Sep 16, 2016

Made a thread on byuu's forums to discuss potential solutions to this issue: http://board.byuu.net/viewtopic.php?f=8&t=1307

@endrift endrift added the severity:minor bug Issues that only have a minor impact on the library label Sep 16, 2016
@alyosha-tas
Copy link

Hi,

I got interested in this after reading your (very entertaining) glitch article. I tried to trace log out what was happening in gambette in BizHawk. Aside from what is already known about the delayed OAM IRQ blocking VBlank, I also noticed Gambette was doing some STAT IRQ blocking at an LY=LYC interrupt, blocking some OAM interrupts. It seems like it was blocking it for 2 scanlines though:

0048: C3 2C 13 JP #132Ch A:f8 LY:7e
132C: F5 PUSH AF A:f8 LY:7e
132D: F0 41 LDH A,(#FF41h) A:f8 LY:7e
132F: CB 57 BIT 2,A A:e6 LY:7e <--LY=LYC & OAM enabled
.
. longer codepath at this scanline takes it about 3/4 into LY=7f
. another OAM IRQ assertion should happen somewhere in here
.
136C: D9 RETI A:f8 LY:7f
44DB: F1 POP AF A:f8 LY:7f
44DC: 21 1A C0 LD HL,#C01Ah A:05 LY:7f
44DF: 19 ADD HL,DE A:05 LY:7f
.
. no interrupt until next scanline (~100 cycles)
. not sure if IRQs get de-asserted ever?
.
0048: C3 2C 13 JP #132Ch A:82 LY:7f
132C: F5 PUSH AF A:82 LY:7f
132D: F0 41 LDH A,(#FF41h) A:82 LY:7f
132F: CB 57 BIT 2,A A:e2 LY:80

(Interrupt looks like it triggers before LY actually equals 80
but maybe that is correct idk the internals.)

I'm not sure which interrupt has priority in this case LYC or OAM, but it seems strange that the IRQ assertion should be blocked for 2 scanlines here. Maybe this is already known but I didn't see it mentioned anywhere so just thought I'd point it out. Hope it helps somehow.

@LIJI32
Copy link

LIJI32 commented Sep 23, 2017

Made a thread about this game on Reddit now that it works on SameBoy:
https://www.reddit.com/r/EmuDev/comments/7206vh/sameboy_now_correctly_emulates_pinball_deluxe/

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
platform:GB/GBC Game Boy/Game Boy Color-related issues severity:minor bug Issues that only have a minor impact on the library
Projects
None yet
Development

No branches or pull requests

4 participants