Update Atari2600.IEmulator.cs

Add a frame termination condition so the core doesn't silently crash.
This commit is contained in:
alyosha-tas 2017-11-08 14:11:13 -05:00 committed by GitHub
parent 7a799583e9
commit e35b225fb0
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 3 additions and 0 deletions

View File

@ -41,9 +41,12 @@ namespace BizHawk.Emulation.Cores.Atari.Atari2600
_rightDifficultySwitchHeld = false;
}
int count = 0;
while (!_tia.New_Frame)
{
Cycle();
count++;
if (count > 1000000) { throw new Exception("ERROR: Unable to resolve Frame. Please Report."); }
}
_tia.New_Frame = false;