A Flash Developer Resource Site

Results 1 to 3 of 3

Thread: Button and Ifs

  1. #1
    Senior Member
    Join Date
    Aug 2004
    Location
    UK, near a garage
    Posts
    211

    Button and Ifs

    I'm trying to create a movie where users are asked to click a number of buttons and when finished the click Check to see if they clicked the correct buttons. I guess I would have to use some form of function (?) and If Statement. Any idea how I could structure it? I really appreciate your help with this.

    I'm using this script currently but all it does is to highlight the the buttons that are correct, there's is no function checking them...
    code:

    stop();
    button1.onRelease = function():Void{
    button1.gotoAndStop("pressed")
    trace("Yeah it Worked");
    }



    Gabs

  2. #2
    Registered User nunomira's Avatar
    Join Date
    May 2002
    Location
    portugal
    Posts
    7,003
    hi,

    I guess the idea can be:

    You click the buttons. A reference is stored in an array.
    If you've got the correct order (correct array), that's it.

    Here's a simple example:
    Attached Files Attached Files

  3. #3
    Senior Member
    Join Date
    Aug 2004
    Location
    UK, near a garage
    Posts
    211
    Thank you, I even understand the code! Really appreciate your 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