Reset Movie when resetting emulator
This commit is contained in:
@@ -10,6 +10,7 @@
|
||||
|
||||
namespace n64 {
|
||||
void PIF::Reset() {
|
||||
movie.Reset();
|
||||
joybusDevices = {};
|
||||
bootrom = {};
|
||||
ram = {};
|
||||
|
||||
@@ -71,6 +71,12 @@ MupenMovie::MupenMovie(const fs::path &path) {
|
||||
}
|
||||
}
|
||||
|
||||
void MupenMovie::Reset() {
|
||||
if(!IsLoaded()) return;
|
||||
|
||||
loadedTasMovieIndex = sizeof(TASMovieHeader) - 4; // skip header
|
||||
}
|
||||
|
||||
FORCE_INLINE void LogController(const n64::Controller& controller) {
|
||||
Util::debug("c_right: {}", controller.cRight);
|
||||
Util::debug("c_left: {}", controller.cLeft);
|
||||
|
||||
@@ -49,6 +49,7 @@ struct MupenMovie {
|
||||
MupenMovie() = default;
|
||||
MupenMovie(const fs::path&);
|
||||
bool Load(const fs::path&);
|
||||
void Reset();
|
||||
n64::Controller NextInputs();
|
||||
bool IsLoaded() const { return !loadedTasMovie.empty(); }
|
||||
private:
|
||||
|
||||
Reference in New Issue
Block a user