Thanks for the swift reply Richi007! That function will save me a lot of time and effort.
Actually, by the time you had posted your reply, I had almost come up with my own algorithm. It was almost perfect, but there was a severe error in my calculations that was causing mouse clicks on the lower right side of the screen to affect things on the upper left side of the screen, and vice-versa for every other direction I chose.
Oh well, that's just talk. Thanks again, man.
