On 5/24/07, Carl Welch <[EMAIL PROTECTED]> wrote:
Seems to me you guys are doing this the hard way. Why not just draw a curved line (with the line tool) then use code to attach/snap the handle to the line, and then just use actionscript to track the Y position of the handle and scroll accordingly? Trig for a simple scroller seems a little convoluted way of going about this simple thing...The end user will never know or appreciate the difference anyway.
It depends on your perspective, mainly to what you're used to. Even with your description, it would take me significantly longer to do it your way -- that is, if I used the Flash authoring tool in the first place, which I don't have/want/need. So, coding it isn't the hard way, for me and many others, at least. That it involves trigonometry (in my example only for setting an angle and using Math.atan2()) doesn't automatically make it difficult for everybody. I don't consider myself to be good at trigonometry, but some basic things I know, and I have had many, many occasions where knowing that x = Math.cos( angle ) and y = -Math.sin( angle ) was useful. Also, by coding it, I could make it a reusable class -- just pass the radius and the handle (or the radius and the container along with a linkage name). What if the radius would depend on the stage size? What if the handle would have to be rotated (say, the hand of a clock). With a script, you gain flexibility. Mark _______________________________________________ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com