# Oval - as from R Penner´s book

**URL:** <https://forum.kirupa.com/t/oval-as-from-r-penner-s-book/153431>\
**Category:** Uncategorized\
**Created:** [July 1, 2005, 12:20pm UTC](https://forum.kirupa.com/t/oval-as-from-r-penner-s-book/153431 "2005-07-01T12:20:31Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![ditti](https://avatars.discourse-cdn.com/v4/letter/d/58f4c7/32.png) [@ditti](https://forum.kirupa.com/u/ditti)\
**Post date:** [July 1, 2005, 12:20pm UTC](https://forum.kirupa.com/t/oval-as-from-r-penner-s-book/153431/1 "2005-07-01T12:20:31Z")

</div>

Hi!  
I took following actionscript from R Penner´s book. But the oval which is drawn is not an oval, there is something wrong and I can´t see it.

```auto
 

MovieClip.prototype.drawOval=function(x, y, rx, ry){
 
this.moveTo (x+rx, y);
this.curveTo (rx+x, 0.4142*ry+y, 0.7071*rx+x, 0,7071*ry+y);
this.curveTo (0.4142*rx+x, ry+y, x, ry+y);
this.curveTo (-0.4142*rx+x, ry+y, -0.7071*rx+x, 0.7071*ry+y);
this.curveTo (-rx+x, 0.4142*ry+y, -rx+x, y);
this.curveTo (-rx+x, -0.4142*ry+y, -0.7071*rx+x, -0.7071*ry+y);
this.curveTo (-0.4142*rx+x, -ry+y, x, -ry+y);
this.curveTo (0.4142*rx+x, -ry+y, 0.7071*rx+x, -0.7071*ry+y);
this.curveTo (rx+x, -0.4142*ry+y, rx+x, y);

};
this.lineStyle (1, 0x00FF00);
this.drawOval (80, 100, 25, 15);

```
