Add islag to savestates (now lagframe alert status updates when loading a state)
This commit is contained in:
parent
daff01ad2e
commit
a34bf45610
|
@ -48,6 +48,7 @@ namespace BizHawk
|
|||
ser.Sync("ram", ref ram, false);
|
||||
ser.Sync("Lag", ref _lagcount);
|
||||
ser.Sync("Frame", ref _frame);
|
||||
ser.Sync("IsLag", ref _islag);
|
||||
tia.SyncState(ser);
|
||||
m6532.SyncState(ser);
|
||||
mapper.SyncState(ser);
|
||||
|
|
|
@ -505,6 +505,7 @@ namespace BizHawk.Emulation.Consoles.Calculator
|
|||
writer.WriteLine("m_LinkOutput {0}", m_LinkOutput);
|
||||
writer.WriteLine("m_LinkState {0}", m_LinkState);
|
||||
writer.WriteLine("lag {0}", _lagcount);
|
||||
writer.WriteLine("islag {0}", islag);
|
||||
writer.WriteLine("vram {0}", Util.BytesToHexString(vram));
|
||||
writer.WriteLine("[/TI83]");
|
||||
}
|
||||
|
@ -549,6 +550,8 @@ namespace BizHawk.Emulation.Consoles.Calculator
|
|||
m_LinkState = int.Parse(args[1]);
|
||||
else if (args[0] == "lag")
|
||||
_lagcount = int.Parse(args[1]);
|
||||
else if (args[0] == "islag")
|
||||
islag = bool.Parse(args[1]);
|
||||
else if (args[0] == "vram")
|
||||
vram = Util.HexStringToBytes(args[1]);
|
||||
else
|
||||
|
|
|
@ -57,6 +57,7 @@ namespace BizHawk.Emulation.Consoles.Coleco
|
|||
ser.Sync("ram", ref ram, false);
|
||||
ser.Sync("Lag", ref _lagcount);
|
||||
ser.Sync("Frame", ref _frame);
|
||||
ser.Sync("IsLag", ref _islag);
|
||||
}
|
||||
|
||||
public ControllerDefinition ControllerDefinition { get { return ColecoVisionControllerDefinition; } }
|
||||
|
|
|
@ -585,6 +585,7 @@ namespace BizHawk.Emulation.Consoles.Nintendo
|
|||
ser.BeginSection("NES");
|
||||
ser.Sync("Frame", ref _frame);
|
||||
ser.Sync("Lag", ref _lagcount);
|
||||
ser.Sync("IsLag", ref islag);
|
||||
cpu.SyncState(ser);
|
||||
ser.Sync("ram", ref ram, false);
|
||||
ser.Sync("CIRAM", ref CIRAM, false);
|
||||
|
|
|
@ -301,6 +301,7 @@ namespace BizHawk.Emulation.Consoles.TurboGrafx
|
|||
}
|
||||
writer.WriteLine("Frame {0}", Frame);
|
||||
writer.WriteLine("Lag {0}", _lagcount);
|
||||
writer.WriteLine("IsLag {0}", islag);
|
||||
if (Cpu.ReadMemory21 == ReadMemorySF2)
|
||||
writer.WriteLine("SF2MapperLatch " + SF2MapperLatch);
|
||||
writer.WriteLine("IOBuffer {0:X2}", IOBuffer);
|
||||
|
@ -353,46 +354,48 @@ namespace BizHawk.Emulation.Consoles.TurboGrafx
|
|||
Frame = int.Parse(args[1]);
|
||||
else if (args[0] == "Lag")
|
||||
_lagcount = int.Parse(args[1]);
|
||||
else if (args[0] == "IsLag")
|
||||
islag = bool.Parse(args[1]);
|
||||
else if (args[0] == "SF2MapperLatch")
|
||||
SF2MapperLatch = byte.Parse(args[1]);
|
||||
else if (args[0] == "IOBuffer")
|
||||
IOBuffer = byte.Parse(args[1], NumberStyles.HexNumber);
|
||||
else if (args[0] == "CdIoPorts")
|
||||
{ CdIoPorts.ReadFromHex(args[1]); RefreshIRQ2(); }
|
||||
else if (args[0] == "BramLocked")
|
||||
BramLocked = bool.Parse(args[1]);
|
||||
else if (args[0] == "RAM")
|
||||
Ram.ReadFromHex(args[1]);
|
||||
else if (args[0] == "BRAM")
|
||||
BRAM.ReadFromHex(args[1]);
|
||||
else if (args[0] == "CDRAM")
|
||||
CDRam.ReadFromHex(args[1]);
|
||||
else if (args[0] == "SuperRAM")
|
||||
SuperRam.ReadFromHex(args[1]);
|
||||
else if (args[0] == "PopulousRAM" && PopulousRAM != null)
|
||||
PopulousRAM.ReadFromHex(args[1]);
|
||||
else if (args[0] == "[HuC6280]")
|
||||
Cpu.LoadStateText(reader);
|
||||
else if (args[0] == "[PSG]")
|
||||
PSG.LoadStateText(reader);
|
||||
else if (args[0] == "[VCE]")
|
||||
VCE.LoadStateText(reader);
|
||||
else if (args[0] == "[VPC]")
|
||||
VPC.LoadStateText(reader);
|
||||
else if (args[0] == "[VDC1]")
|
||||
VDC1.LoadStateText(reader, 1);
|
||||
else if (args[0] == "[VDC2]")
|
||||
VDC2.LoadStateText(reader, 2);
|
||||
else if (args[0] == "[SCSI]")
|
||||
SCSI.LoadStateText(reader);
|
||||
else if (args[0] == "[CDAudio]")
|
||||
CDAudio.LoadStateText(reader);
|
||||
else if (args[0] == "[ADPCM]")
|
||||
ADPCM.LoadStateText(reader);
|
||||
else if (args[0] == "[ArcadeCard]")
|
||||
LoadArcadeCardText(reader);
|
||||
else
|
||||
Console.WriteLine("Skipping unrecognized identifier " + args[0]);
|
||||
else if (args[0] == "CdIoPorts")
|
||||
{ CdIoPorts.ReadFromHex(args[1]); RefreshIRQ2(); }
|
||||
else if (args[0] == "BramLocked")
|
||||
BramLocked = bool.Parse(args[1]);
|
||||
else if (args[0] == "RAM")
|
||||
Ram.ReadFromHex(args[1]);
|
||||
else if (args[0] == "BRAM")
|
||||
BRAM.ReadFromHex(args[1]);
|
||||
else if (args[0] == "CDRAM")
|
||||
CDRam.ReadFromHex(args[1]);
|
||||
else if (args[0] == "SuperRAM")
|
||||
SuperRam.ReadFromHex(args[1]);
|
||||
else if (args[0] == "PopulousRAM" && PopulousRAM != null)
|
||||
PopulousRAM.ReadFromHex(args[1]);
|
||||
else if (args[0] == "[HuC6280]")
|
||||
Cpu.LoadStateText(reader);
|
||||
else if (args[0] == "[PSG]")
|
||||
PSG.LoadStateText(reader);
|
||||
else if (args[0] == "[VCE]")
|
||||
VCE.LoadStateText(reader);
|
||||
else if (args[0] == "[VPC]")
|
||||
VPC.LoadStateText(reader);
|
||||
else if (args[0] == "[VDC1]")
|
||||
VDC1.LoadStateText(reader, 1);
|
||||
else if (args[0] == "[VDC2]")
|
||||
VDC2.LoadStateText(reader, 2);
|
||||
else if (args[0] == "[SCSI]")
|
||||
SCSI.LoadStateText(reader);
|
||||
else if (args[0] == "[CDAudio]")
|
||||
CDAudio.LoadStateText(reader);
|
||||
else if (args[0] == "[ADPCM]")
|
||||
ADPCM.LoadStateText(reader);
|
||||
else if (args[0] == "[ArcadeCard]")
|
||||
LoadArcadeCardText(reader);
|
||||
else
|
||||
Console.WriteLine("Skipping unrecognized identifier " + args[0]);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -183,6 +183,7 @@ namespace BizHawk.Emulation.Consoles.Sega
|
|||
VDP.SaveStateText(writer);
|
||||
writer.WriteLine("Frame {0}", Frame);
|
||||
writer.WriteLine("Lag {0}", _lagcount);
|
||||
writer.WriteLine("IsLag {0}", islag);
|
||||
writer.Write("MainRAM ");
|
||||
Ram.SaveAsHex(writer);
|
||||
writer.Write("Z80RAM ");
|
||||
|
@ -212,6 +213,8 @@ namespace BizHawk.Emulation.Consoles.Sega
|
|||
Frame = int.Parse(args[1]);
|
||||
else if (args[0] == "Lag")
|
||||
_lagcount = int.Parse(args[1]);
|
||||
else if (args[0] == "IsLag")
|
||||
islag = bool.Parse(args[1]);
|
||||
else if (args[0] == "[PSG]")
|
||||
PSG.LoadStateText(reader);
|
||||
else if (args[0] == "[VDP]")
|
||||
|
|
Loading…
Reference in New Issue