Home > Action Script > Dynamic Line Based On Mouse Cursor Using Flash And Action Script

Dynamic Line Based On Mouse Cursor Using Flash And Action Script

This Flash script will draw a line dynamically from a point to current mouse cursor position. The script will redraw the line as you move your current mouse cursor position.

Preview


Source Code


[as3]//By : Isusx’s Programming Corner
//URL : http://isusx.com/

this.onEnterFrame = function(){
this.clear();
this.lineStyle(1,0,100);
this.moveTo(5,5);
this.lineTo(_xmouse,_ymouse);
}
[/as3]

Download

Click here to download the source code

Copyright Note

This script is free to use and can be modified as you wish.

Related Links

Flash Documentation, Guide and Complete Reference

If you like this code/script, perhaps you would kindly treat me a drink. Any number is welcome. Thanks :)

Related Article

  1. No comments yet.
  1. No trackbacks yet.