# Circular Movement Pause?

**URL:** <https://forum.kirupa.com/t/circular-movement-pause/190527>\
**Category:** Uncategorized\
**Created:** [June 12, 2006, 6:27pm UTC](https://forum.kirupa.com/t/circular-movement-pause/190527 "2006-06-12T18:27:01Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![safa\_uk](https://avatars.discourse-cdn.com/v4/letter/s/4491bb/32.png) [@safa\_uk](https://forum.kirupa.com/u/safa_uk)\
**Post date:** [June 12, 2006, 6:27pm UTC](https://forum.kirupa.com/t/circular-movement-pause/190527/1 "2006-06-12T18:27:01Z")

</div>

Hi, ive used the Circular Movement Tutorial  
[http://www.kirupa.com/developer/mx/circular.htm](http://www.kirupa.com/forum/../developer/mx/circular.htm)

I want to be able to mouse over the button while its moving and i want it to stop were it is, basically like pauseing the button in its tracks.  
Below is the code provided:

```auto

onClipEvent (load) {
    var radius = 10 + Math.random() * 50;
    var speed = 5 + Math.random() * 20;
    
    var xcenter = this._x;
    
    var ycenter = this._y;
    
    var degree = 0;
    var radian;
}
onClipEvent (enterFrame) {
    degree += speed;
    radian = (degree/180)*Math.PI;
    this._x = xcenter+Math.cos(radian)*radius;
    this._y = ycenter-Math.sin(radian)*radius;
}

```

if there is any code i can add to this to get the pauseing effect could someone help.

many thanks in advance

safa.
