fixed flip diagonal to actually flip diagonally. restructured make_bg for loop flow