I love the new mouse and keyboard event handlers. I was so excited to try them out (once I found out how to use them by looking at the source) that I nearly immediately started coding a script that I had often wished for: one to quickly and easily set up wifi, dlay, ptri, etc., without the need for the heat/cool tools. I eventually noticed a problem, however. Most work with dlay and wifi is done with the zoom tool. Unfortunately, the mouse handler returns an unmodifed version of x and y, no consideration given to the zoom tool. In other words, the zoom window might as well not exist as far as scripts are concerned. So, I suggest a number of options:
1: return a x and y that accounts for the zoom tool Unfortunately, although this might be the best way, I don't like the thought of adding 2 more parameters to the mouseclick event. 2: return the particle object(or its index) clicked on I think this would actually work pretty well, since it must be calculated anyways, it might as well be done before the event and passed to it. Furthermore, if a null particle still contains x and y, (which I think it might) then :D 3: in addition to mousex/mousey, simply expose the x and y which are in the upper right corner when debug mode is on I think this requires the least work and is the best option, since it avoids unnecessary new variables, and could probably be updated right alongside mousex/y 4: just ignore me Well it is your game and it isn't that big of a problem anyways...
X/Y are the same regardless of zoom level. The particles on the gird will be in the same X/Y position if you zoom in on them or not. The only thing zoom does is enhance the particles size and display it in a box.