Very simple...

I use attachMovie clip and got confused, but I just pass it through the infoObject and it works perfectly.....

Thanks.

/M

From: ½ÅÁø¼®[Jinseok Shin] <[EMAIL PROTECTED]>
Reply-To: Flashcoders mailing list <[email protected]>
To: "'Flashcoders mailing list'" <[email protected]>
Subject: RE: [Flashcoders] Movieclip methods in homemade class
Date: Mon, 3 Apr 2006 00:59:26 +0900

class Money extends Tiles{
        var info:Object
        var walkable:Boolean
        var containsMoney:Boolean
        var _path:MovieClip
        function Ladder(path:MovieClip){
                _path = path
                walkable = true
                containsMoney=true
        }
        function handleTileHit(){
                if(containsMoney){
_path.gotoAndPlay("captured")
                                               containsMoney=false
                                        }
        }
}
--> extends class call
var new_Money:Money = new Money(this)



-----Original Message-----
From: [EMAIL PROTECTED] [mailto:flashcoders-
[EMAIL PROTECTED] On Behalf Of Michael K?ig
Sent: Monday, April 03, 2006 12:50 AM
To: [email protected]
Subject: [Flashcoders] Movieclip methods in homemade class

I am making a tilebased game where each tile is an individual class that
inherits from the Tile class. I have a MC in the library for each type of
tile whcih contains graphics. I have linked each MC in the library directly
to its class in the Linkage panel form the library so I can export them
directly to my stage.

I have a issue with a class that I have showen below. I want to be able to
use the MovieClip class methods in my class - I thought that would be taken
care of when I linked my MCs directly throught the Library. But its not and
I cant wrie gotoAndPlay() in my handleTileHit method. How do I do that


class Money extends Tiles{
        var info:Object
        var walkable:Boolean
        var containsMoney:Boolean
        function Ladder(){
                walkable = true
                containsMoney=true
        }
        function handleTileHit(){
                if(containsMoney){
this.gotoAndPlay("captured")
                                               containsMoney=false
                                        }
        }
}

Michael


_______________________________________________
[email protected]
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com



_______________________________________________
[email protected]
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com


_______________________________________________
[email protected]
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com

Reply via email to