From 2bb2ee8c0aee044998858ff8263be71cb908a663 Mon Sep 17 00:00:00 2001 From: Nebuleon Fumika Date: Sat, 19 Jan 2013 02:24:37 -0500 Subject: Prepare code to ask for a hotkey. Prepare a temporary fast-forward switch. --- source/nds/entry.cpp | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) (limited to 'source/nds/entry.cpp') diff --git a/source/nds/entry.cpp b/source/nds/entry.cpp index 7852bc9..1fb5bd8 100644 --- a/source/nds/entry.cpp +++ b/source/nds/entry.cpp @@ -588,8 +588,6 @@ static unsigned int sync_last= 0; static unsigned int sync_next = 0; static unsigned int auto_equivalent_skip = 0; -extern "C" u32 game_fast_forward; - static unsigned int skip_rate= 0; void S9xSyncSpeed () @@ -607,7 +605,7 @@ void S9xSyncSpeed () #endif syncnow = getSysTime(); - if (game_fast_forward) + if (game_fast_forward || temporary_fast_forward /* hotkey is held */) { sync_last = syncnow; sync_next = syncnow; @@ -620,7 +618,7 @@ void S9xSyncSpeed () IPPU.RenderThisFrame = true; } } - else if (Settings.SkipFrames == AUTO_FRAMERATE /* && !game_fast_forward */) + else if (Settings.SkipFrames == AUTO_FRAMERATE /* && !game_fast_forward && !temporary_fast_forward */) { // frame_time is in getSysTime units: 42.667 microseconds. int32 frame_time = Settings.PAL ? 468 /* = 20.0 ms */ : 391 /* = 16.67 ms */; @@ -701,7 +699,7 @@ void S9xSyncSpeed () } #endif } - else /* if (Settings.SkipFrames != AUTO_FRAMERATE && !game_fast_forward) */ + else /* if (Settings.SkipFrames != AUTO_FRAMERATE && !game_fast_forward && !temporary_fast_forward) */ { // frame_time is in getSysTime units: 42.667 microseconds. uint32 frame_time = Settings.PAL ? 468 /* = 20.0 ms */ : 391 /* = 16.67 ms */; -- cgit v1.2.3