optimize out boarder checking
fix left up corner problem