Tastudio - fix lag lag to reflect the next frame

This commit is contained in:
adelikat 2014-11-15 14:55:44 +00:00
parent 80dae0d026
commit 410078081c
2 changed files with 10 additions and 6 deletions

View File

@ -17,6 +17,15 @@ namespace BizHawk.Client.Common
{
return LagLog[frame];
}
else if (frame == Global.Emulator.Frame)
{
if (frame == LagLog.Count)
{
LagLog[frame] = Global.Emulator.IsLagFrame; // Note: Side effects!
}
return Global.Emulator.IsLagFrame;
}
return null;
}
@ -42,11 +51,6 @@ namespace BizHawk.Client.Common
}
}
public bool HasLagEntry(int frame)
{
return LagLog.ContainsKey(frame);
}
public void Clear()
{
LagLog.Clear();

View File

@ -63,7 +63,7 @@ namespace BizHawk.Client.Common
{
State = StateManager[index],
LogEntry = GetInputLogEntry(index),
Lagged = LagLog[index]
Lagged = LagLog[index + 1]
};
}
}