Try putting a Sleep of 50-200 milliseconds at the begging of the while loop for GetAsyncKeyState. That reduces lagg. As for the GetCusorPos, you said it works when CA is not running?
global keyboard hook is probably the only other alternative, but I can't see why you should use that vs this if you're just using 3-4 keys >.>
Ah we-a blaze the fyah, make it bun dem!
Well this thread went off topic pretty fast.