I have a path that I would like to follow in a Flash
application. I have a path that moves horizontally, and vertically,
and a symbol (a small filled circle - as a movie clip) that tweens
along the path I have drawn.
(I am trying to show electrical current flow in a circuit).
My little ball works fine.
Then, as the ball moves along the path I would like to draw a
rather broad line
(Line.lineStyle(14,0x006600,44); along this tweened path as
the ball moves over the path.
Here is the code I use to write the line, etc. (with some
lines commented out):
I would like to draw a little "nicer" line, with a curve at
the places where x and y change. My current solution is workable
but not pretty (if you know what I mean). Any suggestions on how to
"draw" a nice flowing curving line that does not take hours of
code? I am using Flash 8 and actionscript 2.0.
if the ball is on a rectilinear path there's no easy way to
get the line to curve at "path transition" points. if the ball is
on a curve path the line will be curved though it may appear less
smooth because you're updating your drawing api using an
onEnterFrame loop which you can improve upon by using setInterval()