RtlReset cleared coroutine_state_0 to zero.
This commit is contained in:
@@ -151,14 +151,18 @@ void ReadFromFile(FILE *f, void *data, size_t n) {
|
|||||||
|
|
||||||
void RtlReset(bool preserve_sram) {
|
void RtlReset(bool preserve_sram) {
|
||||||
snes_frame_counter = 0;
|
snes_frame_counter = 0;
|
||||||
coroutine_state_0 = 1;
|
|
||||||
snes_reset(g_snes, true);
|
snes_reset(g_snes, true);
|
||||||
if (!preserve_sram)
|
if (!preserve_sram)
|
||||||
memset(g_sram, 0, 0x2000);
|
memset(g_sram, 0, 0x2000);
|
||||||
|
|
||||||
|
coroutine_state_0 = 1;
|
||||||
|
|
||||||
RtlApuLock();
|
RtlApuLock();
|
||||||
RtlRestoreMusicAfterLoad_Locked(true);
|
RtlRestoreMusicAfterLoad_Locked(true);
|
||||||
RtlApuUnlock();
|
RtlApuUnlock();
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
RtlSynchronizeWholeState();
|
RtlSynchronizeWholeState();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user