Is there a way to display the origin of an object when you select and drag
In this line it would be 6 & 316
#P message 6 316 333 196617 myMessage 1 2 3;
Mousestate doesn’t do the job because it displays where the mouse is in
terms of the screen not the window.
Gary Lee Nelson
maybe u could do it by using thispatcher to report the window position in the desktop, then use that to offset the coordinates from Mousestate?
or better, i just checked mousestate.help, and there are modes for getting whole screen / local patcher coordinates…
mode 1 is what u need (relative to patcher).
moustate defaults to mode 0, which is relative to the screen
The mousestate mode message is *sort of* what you want… however… it will give you the coordinates of the cursor, not the upper-left-corner of your object. So you’d need to know the offset of where you clicked originally from the top-left…
Using scripting / mousestate to move your objects (instead of typical dragging in edit mode) would allow you to keep a coll of all the top-left-corner coordinates of your objects (as they would be defined by the last place you dragged them). Use transparent buttons on top of whatever objects you want to drag, then script-move them both upon click/drag. It will take some fiddling but I’ve gotten it to work. Also check out the "pupdate" message to Max for manual pointer placing.
Working on that message / timeline idea? ;-)
Like to see what you come up with, it’s an interesting venture and would provide some great features for Max.
C74 RSS Feed | © Copyright Cycling '74