# Deactivating the infinite menu

**URL:** https://forum.kirupa.com/t/deactivating-the-infinite-menu/38252
**Category:** flash
**Created:** [December 20, 2003, 12:16am UTC](https://forum.kirupa.com/t/deactivating-the-infinite-menu/38252 "2003-12-20T00:16:18Z")
**Posts on this page:** 1
**Page:** 1

<div class="post-metadata">

### Author: ![HuggyBear](https://avatars.discourse-cdn.com/v4/letter/h/ea5d25/32.png) [@HuggyBear](https://forum.kirupa.com/u/HuggyBear)
#### Post date: [December 20, 2003, 12:16am UTC](https://forum.kirupa.com/t/deactivating-the-infinite-menu/38252/1 "2003-12-20T00:16:18Z")

</div>

Hey,

I followed the infinite menu tut and it worked perefectly, how ever I’m trying to make a professional looking website and I don’t want the scrolling to be obnoxious to the viewer (and I know jack crap about AS).

Is there a way I could get it to either work when the mouse is just on top of the .swf or to get it to work when the mouse is in proximity (within ~100px either way) of the .swf? Also, I’d like for the menu to reset and stay at x=0 y=0 when the it’s not active…

```auto

onClipEvent (load)
    {
       xcenter=360;
       speed=1/200;
    }
onClipEvent (enterFrame)
    {
       var distance=_root._xmouse-xcenter;
       _x+=(distance*speed);
    }

onClipEvent (enterFrame)
    {
       var distance=_root._xmouse-xcenter;
       _x+=(distance*speed);
       if (_x > 0) _x=-1255.2;
       if (_x < -1255.2) _x=0;
    }

```

That’s what I have from the tut for the movie obj.

Thanks
