its actuality is quite broken since it depends on which is bigger x or y so when your counting the edges... its a lil hard and I honestly don't know how I made this I don't really know the point of this really? maybe if you wanted to scan the corner in a project also put your mouse near a corner and click space.
fun fact this project actually uses if on edge bounce block