A Flash Developer Resource Site

Results 1 to 4 of 4

Thread: Removing/hidding a MC permentally

  1. #1
    Junior Member
    Join Date
    Jan 2011
    Posts
    22

    Removing/hidding a MC permentally

    Hi, I'm wanting to remove/hide a mc permentally. I though visible = false would hid it but when you go forward a frame and then back a frame the mc is back.

    Code:
    function pickupKey(evt:MouseEvent):void
    {
    	gotKey = true;
    	door_key.visible = false;
    	removeChild(door_key)
    }
    Thanks,

  2. #2
    Member
    Join Date
    Oct 2010
    Posts
    55
    i know it's a very kludgy solution, but you can do this:

    Code:
    door_key.x = -30000

  3. #3
    Senior Member
    Join Date
    Feb 2006
    Location
    Düsseldorf, Germany
    Posts
    142
    When you are comming back to the frame, it restarts it completely, if you have there a code which puts the mc on the stage or mc is putted by defaut, then it will be there again.
    --
    there is a place for those who dare to dream...

    Flash Developer
    VISTAPARK GMBH
    BÄRENSTRASSE 11-13
    D-42117 WUPPERTAL

  4. #4
    Senior Member
    Join Date
    Feb 2006
    Location
    Portland OR
    Posts
    138
    sounds like the script is being initialized each time that frame is reached, is the script on the Frame?

    sounds like you should set up a condition to check if the key has been retrieved.
    if retrieved = true. don't run that script.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  




Click Here to Expand Forum to Full Width

HTML5 Development Center