tsm decay: fix failing to delete frames if marker is there

markers can be *not* mod _step
This commit is contained in:
feos 2018-03-11 13:49:18 +03:00
parent 47255deef5
commit 3932e5a025
1 changed files with 6 additions and 2 deletions

View File

@ -66,12 +66,16 @@ namespace BizHawk.Client.Common
for (int currentStateIndex = 1; currentStateIndex < baseStateIndex; currentStateIndex++)
{
int currentFrame = _tsm.GetStateFrameByIndex(currentStateIndex) / _step;
int currentFrame = _tsm.GetStateFrameByIndex(currentStateIndex);
if (_tsm.StateIsMarker(currentFrame * _step))
if (_tsm.StateIsMarker(currentFrame))
{
continue;
}
else
{
currentFrame /= _step;
}
int zeroCount = _zeros[currentFrame & _mask];
int priority = ((baseStateFrame - currentFrame) >> zeroCount);