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

Load State incorrect when used during debugger breakpoint #42

Closed
Dwedit opened this issue Mar 22, 2019 · 1 comment
Closed

Load State incorrect when used during debugger breakpoint #42

Dwedit opened this issue Mar 22, 2019 · 1 comment

Comments

@Dwedit
Copy link
Contributor

Dwedit commented Mar 22, 2019

If you Load State while the emulator is paused due to a debug breakpoint, or using the Step command, the CPU Cycles displayed in the debugger and PPU position will be incorrect after the state is loaded, leading to incorrect behavior once the game resumes.

Old PPU immediately displays the scanline number that it was at when the state was loaded.

New PPU behaves slightly differently, it will display the correct scanline in the debugger right after the state is loaded, but will change to the wrong scanline once enough cycles have passed.

Edit: More specifically, it's not related to debugging, just related to loading state at a timestamp different than the beginning of a frame. The debugger is the usually way to get to a different timestamp.

@zeromus
Copy link
Contributor

zeromus commented Apr 4, 2019

fceux will probably never support states mid-frame. it requires re-entering a loop midway after loading the state. It's impossible without the core emulation being designed that way from day one, and fceux is a long way from day one. I'm sure there are bugs about this on SF too. About all I could offer you is a lock-out from making savestates at inappropriate times (but it isn't clear how you could get to the perfectly appropriate time)

@zeromus zeromus closed this as completed Apr 4, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants