cumbersome pt and rect operations
Devin Asay
devin_asay at byu.edu
Thu May 15 17:12:39 EDT 2014
On May 15, 2014, at 2:28 PM, William Prothero <prothero at earthednet.org>
wrote:
> Folks:
> I’m doing a lot of moving objects around on the screen. I find that it’s super cumbersome and generates a load of code. It would be really nice if there could be more compact operations.
>
> For example:
> put pt1 + pt2 into sumofPts
> 2,3 + 5,6 would result in 7,9
>
> or
> put rect1 + pt1 into aRect
> 2,4,6,9 + 3,4 would result in 5,8,9,13
>
> This would make it much easier to do these move operations.
>
> I know these can be done with simple functions but …..
> Perhaps I’m missing something in the docs, and there’s a much easier way to do this.
Bill,
I don't know exactly what you want to do, but you can do a relative move by just specifying the X and Y increments that you want to add to the current location.
move button "foo" relative 5,6 in 1 millisecond
If you want instantaneous move you could try a 0 value for the time.
Devin
Devin Asay
Learn to code with LiveCode University
http://university.livecode.com
More information about the use-livecode
mailing list