Hmmm... Would it not be an easier approach to attach your own mage to the mouse pointer and then control it with the OS functions for setting the mouse position? It's a while since I've done it, but there are functions for setting the pointer position. Failing that, attach a 1x1 bitmap in colour 0 to the pointer, and it will effectively be hidden for your application. No idea about writing your own code though, would involve using blitting functions and a buffer to replace the parts of the screen you draw on with your custom pointer...