2013-04-14 20:39:19 +00:00
|
|
|
|
using System.IO;
|
2012-11-19 19:07:38 +00:00
|
|
|
|
|
2013-11-04 00:36:15 +00:00
|
|
|
|
using BizHawk.Common;
|
2013-11-04 01:39:19 +00:00
|
|
|
|
using BizHawk.Emulation.Common;
|
2013-11-04 00:36:15 +00:00
|
|
|
|
|
2013-11-12 19:22:09 +00:00
|
|
|
|
namespace BizHawk.Emulation.Cores.Computers.Commodore64
|
2012-11-19 19:07:38 +00:00
|
|
|
|
{
|
2013-08-24 20:13:16 +00:00
|
|
|
|
sealed public partial class C64 : IEmulator
|
2012-11-19 19:07:38 +00:00
|
|
|
|
{
|
|
|
|
|
public void ClearSaveRam()
|
|
|
|
|
{
|
|
|
|
|
}
|
2012-11-19 21:18:16 +00:00
|
|
|
|
|
2012-11-19 19:07:38 +00:00
|
|
|
|
public void LoadStateBinary(BinaryReader br)
|
|
|
|
|
{
|
2012-11-21 01:30:54 +00:00
|
|
|
|
SyncState(new Serializer(br));
|
2012-11-19 19:07:38 +00:00
|
|
|
|
}
|
2012-11-19 21:18:16 +00:00
|
|
|
|
|
2012-11-19 19:07:38 +00:00
|
|
|
|
public void LoadStateText(TextReader reader)
|
|
|
|
|
{
|
2012-11-21 01:30:54 +00:00
|
|
|
|
SyncState(new Serializer(reader));
|
2012-11-19 19:07:38 +00:00
|
|
|
|
}
|
2012-11-19 21:18:16 +00:00
|
|
|
|
|
2012-11-19 19:07:38 +00:00
|
|
|
|
public byte[] ReadSaveRam()
|
|
|
|
|
{
|
|
|
|
|
return null;
|
|
|
|
|
}
|
2012-11-19 21:18:16 +00:00
|
|
|
|
|
|
|
|
|
// TODO: when disk support is finished, set this flag according to if any writes to disk were done
|
2012-11-19 19:07:38 +00:00
|
|
|
|
public bool SaveRamModified
|
|
|
|
|
{
|
2012-11-19 21:18:16 +00:00
|
|
|
|
get
|
|
|
|
|
{
|
|
|
|
|
return false;
|
|
|
|
|
}
|
|
|
|
|
set
|
|
|
|
|
{
|
|
|
|
|
}
|
2012-11-19 19:07:38 +00:00
|
|
|
|
}
|
2012-11-19 21:18:16 +00:00
|
|
|
|
|
2012-11-19 19:07:38 +00:00
|
|
|
|
public void SaveStateBinary(BinaryWriter bw)
|
|
|
|
|
{
|
2012-11-21 01:30:54 +00:00
|
|
|
|
SyncState(new Serializer(bw));
|
2012-11-19 19:07:38 +00:00
|
|
|
|
}
|
|
|
|
|
|
2012-11-21 01:30:54 +00:00
|
|
|
|
public void SaveStateText(TextWriter writer)
|
2012-11-19 19:07:38 +00:00
|
|
|
|
{
|
2012-11-21 01:30:54 +00:00
|
|
|
|
SyncState(new Serializer(writer));
|
2012-11-19 19:07:38 +00:00
|
|
|
|
}
|
2012-11-20 02:37:42 +00:00
|
|
|
|
|
2012-11-21 01:30:54 +00:00
|
|
|
|
public void StoreSaveRam(byte[] data)
|
2012-11-20 02:37:42 +00:00
|
|
|
|
{
|
|
|
|
|
}
|
|
|
|
|
|
2012-11-21 01:30:54 +00:00
|
|
|
|
void SyncState(Serializer ser)
|
2012-11-20 02:37:42 +00:00
|
|
|
|
{
|
2013-11-04 00:36:15 +00:00
|
|
|
|
ser.BeginSection("core");
|
|
|
|
|
board.SyncState(ser);
|
|
|
|
|
ser.EndSection();
|
|
|
|
|
}
|
2012-11-19 19:07:38 +00:00
|
|
|
|
}
|
|
|
|
|
}
|