I'm using the Canvas pluin to draw lines in reaction to Key/Mouse clicks. E.g. On click > draw curve etc.
Though for my idea I would like the lines to draw more slowly (at a speed which I control in the project).
Can anyone help me work out how to slowly draw a line using the Canvas plugin? At the moment the lines appear instantly.
Help would be appreciated as I cant seem to find a solution on the forums. I looked at other ways of drawing lines, i.e. using bullet behavour and spawning a trial behind it. But this approach won't give control over the line angle/line type.
Apologies for bumping...
Can anyone help to point me in the right direction?
To clarify my issue. I need to draw lines (like they are being drawn across the screen by a pen).
I've tried using sine and ease tween behaviour (which does do what I want) to repeat sprites across the screen, I've also used the canvas plugin, which again does draw the lines I want.
However with the sine/eas tween combination I can't get it to draw smooth lines. With canvas the lines appear instantly.
So I guess there are two questions:
Any suggestions on how to draw a smooth, unstepped line when using ease tween. I'm tweening a small sprite, then spawning sprites from it on every tick.
Is there any other way to draw lines on screen other than the above or with the canvas plugin?
Any help is massively appreciated!
Develop games in your browser. Powerful, performant & highly capable.
Ok, I was over-thinking this one I reckon. Sorted now, using the "Easetween/Sine" combination and using a much larger sprite, with an origin point set a little way inside the bounding box, to "draw" with has done the trick and created a smooth line...