Games like this send packets in a certain way...
I bet that someone could be able to decrypt a packet and learn how to edit the text in it (for a text chat packet, anyway...) and make it so your program just sends the packet instead of controlling the keyboard.