Beispiel #1
0
        private void HandleSpriteBug(SpriteBug.CorruptionType type)
        {
            if (!_gpu.GetLcdc().IsLcdEnabled())
            {
                return;
            }

            var stat = _addressSpace.GetByte(GpuRegister.Stat.Address);

            if ((stat & 0b11) == (int)Gpu.Mode.OamSearch && _gpu.GetTicksInLine() < 79)
            {
                SpriteBug.CorruptOam(_addressSpace, type, _gpu.GetTicksInLine());
            }
        }