📅  最后修改于: 2022-03-11 14:49:15.599000             🧑  作者: Mango
// make sure we're not referencing cells out of bounds of the array
if (tileX < arr.GetLength(0) && tileY < arr.GetLength(1))
{
// logic
}