private void CorrectTrackConnections(Point startCoords, Point endCoords) { GetExpectedDirections(startCoords, endCoords, out var expectedStartLeft, out var expectedStartRight, out var expectedEndLeft, out var expectedEndRight); Tile tileSafely = Framing.GetTileSafely(startCoords); Tile tileSafely2 = Framing.GetTileSafely(endCoords); if (tileSafely.active() && tileSafely.type == 314) { Minecart.TryFittingTileOrientation(startCoords, expectedStartLeft, expectedStartRight); } if (tileSafely2.active() && tileSafely2.type == 314) { Minecart.TryFittingTileOrientation(endCoords, expectedEndLeft, expectedEndRight); } }
private void CorrectTrackConnections(Point startCoords, Point endCoords) { int?expectedStartLeft; int?expectedStartRight; int?expectedEndLeft; int?expectedEndRight; MinecartDiggerHelper.GetExpectedDirections(startCoords, endCoords, out expectedStartLeft, out expectedStartRight, out expectedEndLeft, out expectedEndRight); Tile tileSafely1 = Framing.GetTileSafely(startCoords); Tile tileSafely2 = Framing.GetTileSafely(endCoords); if (tileSafely1.active() && tileSafely1.type == (ushort)314) { Minecart.TryFittingTileOrientation(startCoords, expectedStartLeft, expectedStartRight); } if (!tileSafely2.active() || tileSafely2.type != (ushort)314) { return; } Minecart.TryFittingTileOrientation(endCoords, expectedEndLeft, expectedEndRight); }