# Drawing a circle with AS

**URL:** <https://forum.kirupa.com/t/drawing-a-circle-with-as/176984>\
**Category:** flash\
**Created:** [January 28, 2006, 8:15pm UTC](https://forum.kirupa.com/t/drawing-a-circle-with-as/176984 "2006-01-28T20:15:02Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![coop](https://avatars.discourse-cdn.com/v4/letter/c/87869e/32.png) [@coop](https://forum.kirupa.com/u/coop)\
**Post date:** [January 28, 2006, 8:15pm UTC](https://forum.kirupa.com/t/drawing-a-circle-with-as/176984/1 "2006-01-28T20:15:02Z")

</div>

Hi all,

I’m trying to draw a circle using ActionScript instead of doing it on the timeline.  
I found this script, which just draws the circle in one frame, but I need to see the circle being drawen. Can anyone help with this, or point me in the right direction.

[AS]  
this.createEmptyMovieClip(“drawing\_mc”, 5);  
var x = 275;  
var y = 200;  
var R = 100;  
var a = R_0.4086;  
var b = R_0.7071;  
drawing\_mc.lineStyle(5, 0xff0000, 90);  
drawing\_mc.moveTo(x-R, y);  
drawing\_mc.curveTo(x-R, y-a, X-b, Y-b);  
drawing\_mc.curveTo(x-a, y-R, x, y-R);  
drawing\_mc.curveTo(x+a, y-R, x+b, y-b);  
drawing\_mc.curveTo(x+R, y-a, x+R, y);  
drawing\_mc.curveTo(x+R, y+a, x+b, y+b);  
drawing\_mc.curveTo(x+a, y+R, x, y+R);  
drawing\_mc.curveTo(x-a, y+R, x-b, y+b);  
drawing\_mc.curveTo(x-R, y+a, x-R, y);  
[/AS]
