# Mose follow on a circle with ease

**URL:** <https://forum.kirupa.com/t/mose-follow-on-a-circle-with-ease/286805>\
**Category:** Uncategorized\
**Created:** [April 21, 2009, 8:23am UTC](https://forum.kirupa.com/t/mose-follow-on-a-circle-with-ease/286805 "2009-04-21T08:23:41Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![prettywoman](https://avatars.discourse-cdn.com/v4/letter/p/9f8e36/32.png) [@prettywoman](https://forum.kirupa.com/u/prettywoman)\
**Post date:** [April 21, 2009, 8:23am UTC](https://forum.kirupa.com/t/mose-follow-on-a-circle-with-ease/286805/1 "2009-04-21T08:23:41Z")

</div>

hey guys,  
i have a script for my project that exactly does what i want but the only thing missing is i want it to follow the path with ease . that i couldn’t figure out.  
here is the code you can copy and past it on the first frame of a flash project and it will work:

var s = \_root.createEmptyMovieClip(“circle”, 10);  
s.\_x = 250;  
s.\_y = 200;  
s.maxAngle = 3.6;  
s.minAngle = -3.6;  
s.r = 50;  
s.rr = 150;  
s.lineStyle(3, 0x8888FF);  
s.moveTo(Math.cos(s.minAngle)\*s.rr, Math.sin(s.minAngle)\*s.r);  
for (var i = s.minAngle; i\<=s.maxAngle; i += .05) {  
s.lineTo(Math.cos(i)_s.rr, Math.sin(i)s.r);  
}  
var d = s.createEmptyMovieClip(“dot”, 10);  
d.lineStyle(15, 0x8800);  
d.moveTo(0, 0);  
d.lineTo(1, 0);  
d.\_x = Math.cos(s.\_x);  
d.\_y = -s.r;  
d.onEnterFrame = function() {  
var s = this.\_parent;  
this.onEnterFrame = function() {  
this.angle = Math.atan2(s.\_ymouse, s.\_xmouse);  
this.angle = Math.max(Math.min(this.angle, s.maxAngle), s.minAngle);  
this.\_x = s.rrMath.cos(this.angle)  
this.\_y = s.r_Math.sin(this.angle)  
}  
}

i appriciate if someone help me with that :bounce:
