# Scale tweened clip jitters when mouse at clip bottom

**URL:** <https://forum.kirupa.com/t/scale-tweened-clip-jitters-when-mouse-at-clip-bottom/228270>\
**Category:** Uncategorized\
**Created:** [June 6, 2007, 4:35pm UTC](https://forum.kirupa.com/t/scale-tweened-clip-jitters-when-mouse-at-clip-bottom/228270 "2007-06-06T16:35:45Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![gdvsbp](https://avatars.discourse-cdn.com/v4/letter/g/47e85d/32.png) [@gdvsbp](https://forum.kirupa.com/u/gdvsbp)\
**Post date:** [June 6, 2007, 4:35pm UTC](https://forum.kirupa.com/t/scale-tweened-clip-jitters-when-mouse-at-clip-bottom/228270/1 "2007-06-06T16:35:45Z")

</div>

Alright, here’s the deal. I’ve got a button that scales itself to 120% on mouseover, using an onEnterFrame hitTest. The code is as follows:

```auto
 
// scales clip up to var targetwidth, which is 120
this._yscale = this._xscale += (this.targetwidth-this._xscale)*this.easing;
//specifies x coordinate, in this case 0
this._x = 0;
//specifies Y coordinate, which is the initial location (310) minus the difference between
//current button height (this._height) and initial button height (80)
this._y = 310-(this._height-80);

```

Whenever the mouse enters anywhere in the bottom 10 pixels or so of the clip, the thing stutters back and forth in its scaling terribly, making no progress. I can only make the jittering go away by specifying an initial Y coordinate between 0 and 23. 24? No good, it jitters a little, and only gets worse as the initial Y increases. If I wanted it to be at 0 or 23 or whatever there wouldn’t be a problem, but I need that clip to hang around 310 at all times, and I just can’t figure out how to fix it!

Does anyone have any suggestions? I’ve even tried nesting the button clip (initial Y at 0) inside a \*separate \*clip (which would sit at y310), and then scaling the button that way. No good.

Please, any help I could get would be greatly appreciated. Thanks in advance for your time!
