Infinite loop failsafe

This commit is contained in:
DominicKarma committed 2022-05-31 17:02:07 -05:00
1 parent bf59afefda
commit 8d28f93077
1 file changed
+6
+6
View File
@@ -670,8 +670,14 @@ namespace CalamityMod.World
chest = MiscWorldgenRoutines.AddChestWithLoot(x, y, (ushort)ModContent.TileType<RustyChestTile>());
}
}
if (attempts >= 5000)
break;
}
if (attempts >= 5000)
continue;
// If a chest was placed, force its first item to be the unique item.
if (chest != null)
{