A Flash Developer Resource Site

Results 1 to 4 of 4

Thread: Actionscripting issues

  1. #1
    Junior Member
    Join Date
    Jan 2002
    Posts
    12
    Ok, here's the deal:
    Im trying to make a pop-up window and im using the visibility property but it just isnt working.

    I've tried (in the frame):

    setProperty ("window", _visible, 0);

    However, this doesnt work...i've tried a number of different variations on the code and they dont work either. When it gets to the frame my movie clip is in (i've also tried making it a button instead) it's still there. I've also tried using _alpha but that didnt work either. How it is typed above is how it was typed in the tutorial that I did. Anyway, on to problem #2:

    I want this pop-up window to be draggable. I've trie the simple:

    on (press) {
    startDrag (""); //<--i've tried putting the name of my movie clip here, didnt help.
    }
    on (release) {
    stopDrag ();
    }

    I've also tried:

    on (press) {
    if (this.hitTest(_root._xMouse, _root._yMouse)) {
    this.startDrag();
    }

    }

    on (release) {
    stopDrag();
    }
    both of which result in my entire flash movie being moved.

    Any help on either issues would be greatly appreciated.



  2. #2
    Member
    Join Date
    Apr 2001
    Location
    AU
    Posts
    42
    i have a funny feeling you're referencing your movie incorrectly...

    btw (im sure u already know this) on (press) {} blocks only work for buttons

    Code:
    windowMC._visible = !windowMC._visible; // works as a toggle for me from the parent frame action.
    'this' operator only references a MC if it is placed in that MC or it is in a onClipEvent block.
    otherwise your code should work.

  3. #3
    Member
    Join Date
    Jan 2002
    Posts
    38
    for your mouse dragging thing,first, put an invisible button over your movie clip INSIDE the movie clip, then on that buttons actions, put this:
    Code:
    on(press){
    startDrag(this, true);
    } 
    on(release){
    stopDrag();
    }
    good luck

  4. #4
    Junior Member
    Join Date
    Jan 2002
    Posts
    12
    Okay, i dont know what the heck im doing wrong. I put all of that in correctly and it still doesnt work.

    The window is still visible in the frame where the actionscript is that tells the stinkin' window to NOT be visible. (Im frustrated )

    Also, that drag thing: still drags everything on the main stage. Why isnt it understanding which movie clip I want it to control (or button, cuz i tried making it a button too).

    What's going on? If the .fla wasnt so big I'd have someone take a look at it but it's like 64MB for some reason. Anyway, any other ideas would be appreciated. Thanks for you help.

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