Refactor flipping and fix bugs. I can't believe this is actually working O_o
Remove debugging output
Added border to flipping rectangle for reasons