Merge pull request #4368 from JosJuice/updatewantdeterminism-loadinput

Movie: Add missing calls to UpdateWantDeterminism
This commit is contained in:
Markus Wick 2016-11-02 16:26:48 +01:00 committed by GitHub
commit 342c053bf5
1 changed files with 6 additions and 0 deletions

View File

@ -12,6 +12,7 @@
#include <thread>
#include <vector>
#include "Common/Assert.h"
#include "Common/ChunkFile.h"
#include "Common/CommonPaths.h"
#include "Common/FileUtil.h"
@ -1151,6 +1152,7 @@ void LoadInput(const std::string& filename)
if (s_playMode != MODE_PLAYING)
{
s_playMode = MODE_PLAYING;
Core::UpdateWantDeterminism();
Core::DisplayMessage("Switched to playback", 2000);
}
}
@ -1159,6 +1161,7 @@ void LoadInput(const std::string& filename)
if (s_playMode != MODE_RECORDING)
{
s_playMode = MODE_RECORDING;
Core::UpdateWantDeterminism();
Core::DisplayMessage("Switched to recording", 2000);
}
}
@ -1335,6 +1338,9 @@ void EndPlayInput(bool cont)
{
if (cont)
{
// If !IsMovieActive(), changing s_playMode requires calling UpdateWantDeterminism
_assert_(IsMovieActive());
s_playMode = MODE_RECORDING;
Core::DisplayMessage("Reached movie end. Resuming recording.", 2000);
}