Transition AS2 to AS3, Code processing on the left on the buttons

I have several (20-30) Flash files that I need to transfer from AS2 to AS3. The biggest problem I'm having is that it is extremely tedious to go through all the code and change the places where the code is on the buttons to the event handler model.

I don't hope, but I was wondering if anyone knows of any tricks or tools to quickly change all the code on a button in AS2 compatible AS3 code.

Thanks.

0


a source to share


3 answers


Porting 20-30 Flash files between versions is a small task - good luck. As you suspect, you probably won't find shortcuts for this. Just make sure you move all your code to external classes so you never have this problem. I guess you have no way of just uploading to AS2 swfs into an AS3 container?



+1


a source


Well, I would suggest not sure if you should use any good decompiler and that the decompiler can convert your as2 code to as3 .. Try it and good luck.



0


a source


I haven't worked on this for a while, but this JSFL library might be helpful:

gthmb_as2_converter.zip

it can parse single file (FLA or class file) or file folder and does its best to convert from as2 to as3. it won't cover everything, but it does take care of most of the tedious things. I wrote this because I got sick of doing all this crap by hand when our designers hand me AS2 designs and say "do it AS3" :)

let me know if it helps. there is a main README file in the zip that tells you how to use it. pretty simple stuff: run one of the conversion jsfl scripts and follow the instructions.

I don't think he can handle handlers like:

on (release)
{
    //blargh
}

      

but if you do:, mybtn.onRelease = function()...

that takes care of it.

0


a source







All Articles