There are no mousex/mousey functions due to the network architecture. The server can't know the mouse position of the client without asking for it and due to network latency the mouse position is likely very different by the time the trigger runs to when the client sees the response.
The basic issue is the lack of a "client-side" trigger which is not synced across the network. That would be a non-trivial addition to the engine though and would probably be massively complicated as there would be a very strict set of rules as to what could and couldn't be done in such triggers, and you'd need to marshal data (local vs. synced), etc. So it's not going to happen.
However, making it so the client sends the mouse cursor position when certain other events occur - like keypresses - is entirely possible and hopefully is added.
That is ridiculous. SC2 already collects mouse data for various things. Just take CameraForceMouseRelative as an example... this makes it so that the camera motion is inherently linked to mouse motion. The EXACT same thing could be done, except instead of moving the camera upon mouse motion, the game could fire some trigger and update some mouse position values. Blizzard is just being really lame by not including this...
Also, please have MouseGetX/MouseGetY functions, I don't want to have to create another program that runs behind SC2 that just clicks the mouse for me...
Rollback Post to RevisionRollBack
To post a comment, please login or register a new account.
Apparently Blizzard has announced that they will add a MousePosition function. Yay!
That is ridiculous. SC2 already collects mouse data for various things. Just take CameraForceMouseRelative as an example... this makes it so that the camera motion is inherently linked to mouse motion. The EXACT same thing could be done, except instead of moving the camera upon mouse motion, the game could fire some trigger and update some mouse position values. Blizzard is just being really lame by not including this...
Well this article pretty much sums up everything wrong with the Galaxy language: http://www.sc2mod.com/board/index.php?page=Thread&threadID=77
Also, please have MouseGetX/MouseGetY functions, I don't want to have to create another program that runs behind SC2 that just clicks the mouse for me...