Ok, so I did the coding, but it only works on the left and top. The right and the bottom side you can still go beyond the screen.