  | |  | AS2 addListener Help | AS2 addListener Help
2004-02-22 - By Andrea Di Sabatino
Back Anyone knows how can i do this in AS2:
#initclip
_global.myclass = function () {
}
myclass.prototype = new Movieclip();
Object.registerClass( "myclass ", myclass);
myclass.prototype.init = function () {
ASBroadcaster.initialize(this);
this.addListener(this);
}
#endinitclip
In AS2 i 've done:
class myclass extends MovieClip{
function init():Void {
AsBroadcaster.initialize(this);
this.addListener(this);
}
}
When i try this code i get an error (no method addListener declared)
=-- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- --
Supported by Fig Leaf Software
=-- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- --
Be sure to check the archives and the wiki:
http://chattyfig.figleaf.com/
=-- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- --
http://chattyfig.figleaf.com/cgi-bin/ezmlm-cgi?1:mss:104936
=-- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- --
To unsubscribe send a blank e-mail to:
Normal Mode: flashcoders-unsubscribe@(protected)
Digest Mode: flashcoders-digest-unsubscrive@(protected)
|
|
 |