You can make some assumption based on your as2 code:
// The default value for Severity parameter must be negative.
function AAAAClass() { //this is the "constructor"
this.setID(this.mID);
this.setStatus(this.mStatus);
}
AAAAClass.prototype = new MovieClip(); //this means the class extends MovieClip (probably a Movie Clip Exported for Actionscript in the .fla file's Library)
AAAAClass.prototype.setID = function(variable) {
this.ID.text = variable; //from this line we can deduce the ID isn't an int (as intuituion might point to), but a String and the clip must contain a Dynamic TextField named ID
};
AAAAClass.prototype.setStatus = function(variable) {
this.Status.text = variable; //from this line we can deduce the Statusi is also a String and the clip must contain a Dynamic TextField named Status
this.Status._visible = false;
};
Object.registerClass("AAAA", AAAAClass); // Compiler shows error at this statement
This can be extrapolated to an as 3.0 class like this:
package {
import flash.display.MovieClip;
import flash.text.TextField;
public class AAAA extends MovieClip {
private var mID:String = "default ID";
private var mStatus:String = "default status";
//private var ID:TextField;
//private var Status:TextField;
public function AAAA(){
this.setID(this.mID);
this.setStatus(this.mStatus);
//ID = new TextField();
//Status = new TextField();
}
public function setID(variable:String):void{
this.mID = variable;
this.ID.text = this.mID;
};
public function setStatus(variable:String):void{
this.mStatus = variable;
this.Status.text = this.mStatus;
this.Status.visible = false;
};
override public function toString():String{
return "[AAAA mID=" + mID + " mStatus=" + mStatus + " ]";
}
}
}
Notice the commented out TextFields ? I won't be able to guess the structure, but my guess is that in your as 2.0 project there is a MovieClip in the libraries linked to the AAAAClass which has two TextFields: ID and Status.
There is a lot to cover in terms of as3 and migration from as2 to as3.
I recommend reading Trevor McCauley's Getting Started with ActionScript 3.0 in Adobe Flash CS3 exhaustive article and Dan Carr's Migrating from ActionScript 2 to ActionScript 3: Key concepts and changes article.
If you're new to as3 probably practice the concepts explained in the articles in minimal new flash projects so it's all simple and easy to digest, then go back to your project and apply what you've learned.
Object.registerClass, instead, create an as3.0 class namedAAAAand define the methods/properties ofAAAAClassin the code above(e.g.setID(),setStatus()) - George Profenza