# AS3 easing

**URL:** https://forum.kirupa.com/t/as3-easing/321363
**Category:** flash
**Created:** [April 18, 2011, 9:08am UTC](https://forum.kirupa.com/t/as3-easing/321363 "2011-04-18T09:08:20Z")
**Posts on this page:** 1
**Page:** 1

<div class="post-metadata">

### Author: ![paulscanlon\_99](https://avatars.discourse-cdn.com/v4/letter/p/0ea827/32.png) [@paulscanlon\_99](https://forum.kirupa.com/u/paulscanlon_99)
#### Post date: [April 18, 2011, 9:08am UTC](https://forum.kirupa.com/t/as3-easing/321363/1 "2011-04-18T09:08:20Z")

</div>

Hi all, i’m still learning AS3 but have a pretty sound knowledge of AS2, i’m wondering if someone can help me with the attached, it’s a simple onEnterFrame with expo ease, i’ve not used a TweenClass for a reason! could someone have a quick look and show me the best way to achieve this in AS3.

var masterEnterFrame = this.createEmptyMovieClip(this, this.getNextHighestDepth());  
var drag:Number = 5;

function doMoveOut(newX) {  
masterEnterFrame.onEnterFrame = function() {  
targetClip.\_x += (newX-targetClip.\_x)/drag;  
};  
}

function doMoveIn(newX) {  
masterEnterFrame.onEnterFrame = function() {  
targetClip.\_x += (newX-targetClip.\_x)/drag;  
};  
}

outClip.onRelease = function() {  
doMoveOut(183);  
};

inClip.onRelease = function() {  
doMoveIn(550);  
};
