Flash Gallery | Flash Templates | Flash Menu | Flash Design | Flash Audio & Video

flash page flip

Actionscript 3.0 video tutorials

+ Reply to Thread
Results 1 to 2 of 2

Thread: [AS2]XML Quiz Array Answers with different Values. Help

  1. #1
    Junior Member Settled In terraform is on a distinguished road
    Join Date
    Jan 2009
    Posts
    14
    Rep Power
    0

    [AS2]XML Quiz Array Answers with different Values. Help

    flash templates
    I have this project where I have a quiz template that I am using
    (as2) and I have everything exactly the way I want it
    except....
    that I need for the individual questions to hold a different value from one another.

    for example
    Question 1 = 10 points
    Question 2 = 20 points

    so on and so forth

    right now I have it so they are an equal percentage of the total
    (ie 10 questions all are worth 10 points)
    and I need to change that

    unfortunately I am still teaching myself AS but even more unfortunate for me
    is that I am learning AS3 and this template is AS2
    I also have not done much in this vein I have been concentrating more on
    UI kind of stuff and less on the math side
    so if anyone can point me in the right direction I would greatly appreciate it,.
    also it makes no difference to me if this is done in AS or XML
    this file will not be continually updated so it can be a one time deal

    thanks
    (I have attached the work files)
    http://www.shawnconvey.com/QuizHelp.zip

  2. #2
    Junior Member Settled In terraform is on a distinguished road
    Join Date
    Jan 2009
    Posts
    14
    Rep Power
    0

    Re: [AS2]XML Quiz Array Answers with different Values. Help

    Ok
    well I think I at least have a clue as what needs to be done
    but I will admit that I don't have any idea as how to get there.

    what I have
    I have an as2 xml quiz that does NOT assign a weight (or value) to individual questions.
    It instead divides the the correct questions by the total questions and multiplies x100 to achieve the percent total.

    what I need
    I need to declare a value for each question. (to be assigned in the XML)
    I believe I need to create a variable in my as2 code
    I believe I need to add an attribute to the child nodes (ie weight)
    I believe I need to add a "value" or "weight" attribute to the external XML file
    lastly I believe I need some line of math that would add up the "weight" of
    each of the individual questions on Quiz completion.

    I have tried every variation of this that my feeble mind could come up with
    and never with any success.

    again array work and xml are all new to me and on top of that I have been attempting AS3 so the differences have been tripping me up further.

    I have attached a .as file (it is on the timeline but I figured you don't need the .fla) and the .xml file so you can see it all in its entirety.

    thanks to anyone that can help me on this.
    Attached Files

+ Reply to Thread

Similar Threads

  1. array di pulsanti che chiamano array di funzioni
    By chil8 in forum Actionscript 3.0 base
    Replies: 0
    Last Post: 12-02-10, 16:01
  2. php sending extra values ther than the required values
    By maruti kumar in forum PHP | mySQL | Flash CS3
    Replies: 0
    Last Post: 30-04-09, 11:18
  3. parsing values between swf's
    By antgod in forum PHP | mySQL | Flash CS3
    Replies: 0
    Last Post: 13-02-09, 07:38
  4. Help......How to send and get parameter values from an .SWF to another .SWF
    By NunoGouveia in forum Actionscript 3.0 newbies
    Replies: 0
    Last Post: 25-09-08, 22:27

Tags for this Thread

Bookmarks

Posting Permissions

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