# Need help convert reverse mc function as2 to as3

**URL:** https://forum.kirupa.com/t/need-help-convert-reverse-mc-function-as2-to-as3/327841
**Category:** flash
**Created:** [March 31, 2012, 8:20am UTC](https://forum.kirupa.com/t/need-help-convert-reverse-mc-function-as2-to-as3/327841 "2012-03-31T08:20:27Z")
**Posts on this page:** 1
**Page:** 1

<div class="post-metadata">

### Author: ![mi3kel](https://avatars.discourse-cdn.com/v4/letter/m/977dab/32.png) [@mi3kel](https://forum.kirupa.com/u/mi3kel)
#### Post date: [March 31, 2012, 8:20am UTC](https://forum.kirupa.com/t/need-help-convert-reverse-mc-function-as2-to-as3/327841/1 "2012-03-31T08:20:27Z")

</div>

I need to convert reverseMask function to as3 cause my component need as3…  
this as2 script run perfectly

```auto
function reverseMask(mc)
{
    mc.createEmptyMovieClip("frameControler", 123);
    mc.frameControler.onEnterFrame = function ()
    {
        var _loc2 = this._parent;
        if (_loc2._currentframe > 1)
        {
            _loc2.prevFrame();
        }
        else
        {
            delete _loc2.onEnterFrame;
        } // end else if
    };
} // End of the function

```

and then i put this in timeline to begin function

```auto
reverseMask(maska);

```

there are multiple mask that i want to reverse

Please Help Me :\*(. i need as3 script cause I’ve tried every way but can’t get my as3 working…
