protected void ClearFromMap(Item item)
{
int count = 0;
int max = item.Data.Width * item.Data.Height;
for (var x = 0; x < _width; ++x)
{
for (var y = 0; y < _height; ++y)
{
if (_map[x, y] == item)
{
_map[x, y] = null;
if (++count >= max)
return;
}
}
}
}