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

Video is not correct in Final Fantasy 1 and 2 #297

Closed
branchus opened this issue Apr 29, 2023 · 4 comments
Closed

Video is not correct in Final Fantasy 1 and 2 #297

branchus opened this issue Apr 29, 2023 · 4 comments

Comments

@branchus
Copy link

Windows 11 Pro - NanoBoyAdvance 1.7
Notice the bottom area, the video is not correct.

Screenshot 2023-04-29 104751

How to reproduce
start the game, have couple fights, come back to village try to talk to any npc

@branchus
Copy link
Author

branchus commented Apr 29, 2023

Two more screenshots, seem it can be on bottom as well as on top.

Screenshot 2023-04-29 143210
Screenshot 2023-04-29 143249

@fleroviux
Copy link
Member

fleroviux commented Apr 29, 2023

This appears to be a regression from NBA 1.6. Possibly related to the PPU rewrite.

@fleroviux
Copy link
Member

Looks like 1fbe80b is the regressing commit.

@fleroviux
Copy link
Member

fleroviux commented May 5, 2023

This was caused by a really old oversight in my code that somehow was not triggered until this recent change.

If the CPU is halted the code would check if there are any DMAs to execute and then fast-forward in time to the next hardware event. It would then check if the CPU should wake up. However it is possible that the condition for waking up the CPU becomes true during the DMA, which means that still fast-forwarding to the next event is incorrect in that case.

The fix addresses this by checking if the CPU should wake up after executing a DMA and not skipping to the next event in that case.

The corruptions should be fixed in the latest dev builds.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants