# Spring loaded object

**URL:** <https://forum.kirupa.com/t/spring-loaded-object/155138>\
**Category:** flash\
**Created:** [July 14, 2005, 10:58pm UTC](https://forum.kirupa.com/t/spring-loaded-object/155138 "2005-07-14T22:58:37Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![brndn](https://avatars.discourse-cdn.com/v4/letter/b/dec6dc/32.png) [@brndn](https://forum.kirupa.com/u/brndn)\
**Post date:** [July 14, 2005, 10:58pm UTC](https://forum.kirupa.com/t/spring-loaded-object/155138/1 "2005-07-14T22:58:37Z")

</div>

Hey all  
Have got this interia spring on a mc object  
it springs and eases into its set value.  
What I want it to do is spring larger than its final state and bounce back and forwth? any one lost yet?

onClipEvent (load) {  
xDest = this.\_xscale;  
}  
onClipEvent (enterFrame) {  
if (this.\_xscale != xDest) {  
this.\_xscale += (xDest-this.\_xscale)_.2;  
}  
}  
onClipEvent (load) {  
yDest = this.\_yscale;  
}  
onClipEvent (enterFrame) {  
if (this.\_yscale != yDest) {  
this.\_yscale += (yDest-this.\_yscale)_.2;  
}  
}
