# Declaring tween motion into a mouseover

**URL:** https://forum.kirupa.com/t/declaring-tween-motion-into-a-mouseover/281762
**Category:** flash
**Created:** [February 13, 2009, 12:41am UTC](https://forum.kirupa.com/t/declaring-tween-motion-into-a-mouseover/281762 "2009-02-13T00:41:51Z")
**Posts on this page:** 1
**Page:** 1

<div class="post-metadata">

### Author: ![Leta](https://avatars.discourse-cdn.com/v4/letter/l/9de0a6/32.png) [@Leta](https://forum.kirupa.com/u/Leta)
#### Post date: [February 13, 2009, 12:41am UTC](https://forum.kirupa.com/t/declaring-tween-motion-into-a-mouseover/281762/1 "2009-02-13T00:41:51Z")

</div>

hi,

I need help with coding a mouseover event

I have two mouseovers “over” and “out”

I copied the tween code created by CS4 (AS 3) from manual timeline tweening and I want to add it to an actionscript instead

Flash gave me this code:

```auto
import fl.motion.AnimatorFactory;
import fl.motion.MotionBase;
import flash.filters.*;
import flash.geom.Point;
var __motion_gradient_4:MotionBase;
if(__motion_gradient_4 == null) {
    import fl.motion.Motion;
    __motion_gradient_4 = new Motion();
    __motion_gradient_4.duration = 30;

    __motion_gradient_4.addPropertyArray("x", [0,-1.22222,-2.44444,-3.66666,-4.88889,-6.11111,-7.33333,-8.55555,-9.77778,-11,-12.15,-13.3,-14.45,-15.6,-16.75,-17.9,-19.05,-20.2,-21.35,-22.5,-23.65,-24.8,-25.95,-27.1,-28.25,-29.4,-30.55,-31.7,-32.85,-34]);
    __motion_gradient_4.addPropertyArray("y", [0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0]);
    __motion_gradient_4.addPropertyArray("scaleX", [1.000000,1.000000,1.000000,1.000000,1.000000,1.000000,1.000000,1.000000,1.000000,1.000000,1.000000,1.000000,1.000000,1.000000,1.000000,1.000000,1.000000,1.000000,1.000000,1.000000,1.000000,1.000000,1.000000,1.000000,1.000000,1.000000,1.000000,1.000000,1.000000,1.000000]);
    __motion_gradient_4.addPropertyArray("scaleY", [1.000000,1.000000,1.000000,1.000000,1.000000,1.000000,1.000000,1.000000,1.000000,1.000000,1.000000,1.000000,1.000000,1.000000,1.000000,1.000000,1.000000,1.000000,1.000000,1.000000,1.000000,1.000000,1.000000,1.000000,1.000000,1.000000,1.000000,1.000000,1.000000,1.000000]);
    __motion_gradient_4.addPropertyArray("skewX", [0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0]);
    __motion_gradient_4.addPropertyArray("skewY", [0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0]);
    __motion_gradient_4.addPropertyArray("rotationConcat", [0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0]);
    __motion_gradient_4.addPropertyArray("blendMode", ["normal"]);

    var __animFactory_gradient_4:AnimatorFactory = new AnimatorFactory(__motion_gradient_4);
    __animFactory_gradient_4.transformationPoint = new Point(0.500000, 0.500000);

}

```

How do I declare this code as a mouseover for the instance name “over” ?  
Flash already did the motionclip naming I just need help on turning this into a mouseover event (ROLL\_OUT)

Thanks
