Map Generator 2.0 - Please Critique!

As I’ve mentioned, you can fix this by populating the entire edge of the map with invisible “walls” when you generate the map array. That way you can later just have a single check to see if the tile is a wall or not, and won’t have to make all the separate checks. I don’t think this will really slow anything down much, since you don’t render the walls. For the world wrapping in east and west, you might make separate types of walls for north/south and east/west, and if one of the east/west walls are selected you direct the blueprint to the appropriate tile on the other side of the map instead.