From 3796755ec2ef49ba0deeccc5c764d91744d6791d Mon Sep 17 00:00:00 2001 From: Souryo Date: Sat, 18 Jun 2016 21:42:51 -0400 Subject: [PATCH] Sachen8259: Save states --- Core/Sachen8259.h | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/Core/Sachen8259.h b/Core/Sachen8259.h index 7eb9f5c7..7a4ae4fd 100644 --- a/Core/Sachen8259.h +++ b/Core/Sachen8259.h @@ -23,6 +23,7 @@ protected: uint16_t GetCHRPageSize() { return _variant == Sachen8259Variant::Sachen8259D ? 0x400 : 0x800; } uint16_t RegisterStartAddress() { return 0x4100; } uint16_t RegisterEndAddress() { return 0x7FFF; } + void InitMapper() { _currentReg = 0; @@ -31,6 +32,14 @@ protected: SelectPRGPage(0, 0); } + void StreamState(bool saving) + { + BaseMapper::StreamState(saving); + + ArrayInfo regs{ _regs,8 }; + Stream(_currentReg, regs); + } + void UpdateState() { bool simpleMode = (_regs[7] & 0x01) == 0x01;