Skip to main content
lucilaf76447434
Known Participant
October 7, 2016
Question

Making a quiz from scratch, building a results page; using multi-state objects and advanced actions

  • October 7, 2016
  • 3 replies
  • 462 views

Hi all!

I'm new to Captivate and I'm interested in creating a picture-based quiz where the end result that the user sees is dependent on their answers throughout the quiz.

For example, the quiz is trying to assess whether or not a user properly identified an animal. They are asked simple questions and asked to select a photo related to what they have learned are identifiers for that animal (foot prints, scat, and nests). There's three of these questions, and then I want the results page to show the animal they saw or that they are incorrect because they confused the identifiers for the animals. There are two animals that they are being tested for.

None of the standard quiz options seem to work for what I am doing. I tried True/False but you can't delete the text to replace the buttons with the images for each "animal identifier" being tested. The only way I've figured out how to do this thus far is to create variables and assign them specific values, like was done in Captivate 8 when you had to show/hide objects on the result page according to the assigned value of a variable written into the script of a conditional action. The problem now is creating the results page for three custom designed "Quiz" pages that are aren't using Quiz Master Slides.

I'm wondering if there is a way to add the "sum" of the variables, such that the result of a sequence of interactions would lead to the end result of an image appearing in a specific state. For example, if the user clicks on the right picture of a nest (assigned a value of 1), of track prints (assigned a value of 2), and of scat (assigned a value of 3), the system would read that sum (7) as a command to depict the objects on the result slides in their normal state.

Help! Am I setting this up incorrectly from the get go? Or is there a piece that I am missing? Any guidance will be immensely appreciated!

    This topic has been closed for replies.

    3 replies

    BDuckWorks
    Inspiring
    October 31, 2016

    It looks like you've got a working solution, and I don't mean to derail that, but I was intrigued by your approach so I thought I'd comment on your original posting (op).

    GIVEN:

    There are two animals that they are being tested for.

    I'm wondering if there is a way to add the "sum" of the variables, such that the result of a sequence of interactions would lead to the end result of an image appearing in a specific state.

    For example, if the user clicks on the right picture of a nest (assigned a value of 1), of track prints (assigned a value of 2), and of scat (assigned a value of 3), the system would read that sum (7) as a command to depict the objects on the result slides in their normal state.

    With the constraint that there are two tests (animals), and three identifiers (foot prints, scat, and nests), this gives you a 'solution matrix' of six correct answers.

    You asked if there was a way to "add the sum of the variables," and I'd suggest that you may consider these as states in the solution matrix. IAW, consider each animal in an individual score, and store them as a single number.

    My recommendation would be to consider the scores as an array (x, y) rather than a sum total.

    Two animals, (A,B); three identifiers:

                        A  B

    foot prints     2, 2

    scat              3, 3

    nests            1, 1

    CORRECT     6, 6

    Although I see this as a different scoring approach, I DO NOT claim it would be a better way to implement it, given Cp's approach to programming and storage of variables.

    What I am curious to know :

    Would this approach have facilitated a way to know which questions were correctly answered, without storing individual responses?

    Would this approach have simplified a JavaScript implementation of the scoring problem?

    Participant
    October 7, 2016

    Hello, here´s what I did, because I needed to test my students in a graphic application.

    First I created an "interactive zone" type of question. Then I inserted an image, just by clicking on the menu "media" and "image", then I dragged the interactive zone over the right picture, and worked great!! It was easy to do it, but took time to find the way around... hope this works....

    Lilybiri
    Legend
    October 8, 2016

    @juanpa-amadeus  Thanks for helping! You gave an alternative to my explanation of a shape button filled with an image. Having a click box over an image results almost in the same behavior. Most important differences:

    • you need two objects (image + click box) instead of one shape button
    • you cannot have InBuilt states for a click box: no rollover, no down state
    • if you would ever need that (maybe to show on a second slide) you can time a shape button for more than one slide, but that is not possible for a click box, it is for the image.

    This thread was about setting up the results slide that should show a certain state based on the results of the three quiz slides. I suspect the OP was using already a click box (or a button made invisible to the user by changing Alpha and stroke) over the image. For that reason I offered the shape button as alternative. How you can create such a shape button from an image is explained step-by-step here:

    Turn an Image into a Button - Captivate blog

    Lilybiri
    Legend
    October 7, 2016

    I don't understand the question very well, maybe other and greater experts will help you out. Just want to warn about that idea of 'sum of variables' because the number 7 could be the result of different combinations of results. What exactly has to appear on the 'results' page and what would you store in those variables as result of the quiz slides?

    lucilaf76447434
    Known Participant
    October 7, 2016

    This was a tough one to explain, so I don't blame  you for being confused!

    What I'm looking for is a way to make the results page display different items according to the selections a user makes throughout the three questions they are asked. An outline of this would look like:

    Q1: Opt A or B (displays photos)

    Q2: Opt A or B

    Q3: Opt A or B

    Results: (three states)

        -Normal State: Correct! You saw animal A

        -State 2: Correct! You saw animal B

        -State 3: Incorrect, try again

    If a user selects: Q1-A, Q2-B, Q3-A, they would get the Incorrect state. If a user selects Q1-A, Q2-A, Q3-A, they will get the Normal state on the results slide.

    This, in my very limited understanding, would be written with using advanced actions and making conditional actions. The only way I figured that makes sense to do this is to create a variable for each image in each question slide, create action buttons over each image and assign those buttons to a value (Q1-A=1, Q2-A=2, Q3-A=3 and Q1-B= -1, Q1-B= -2, and Q3-C= -3), and then write a script that will take the sum of what was selected and spit out a result. So, if the user goes through the sequence correctly, the total value they would have collected through each interactive button would be either 7 or -7, which would be assigned to the corresponding state. Any other number will be tied to the Incorrect state (State 3).

    This, however, is all my guesswork! I've gotten has far as setting up variables, assigning them values, and writing advanced actions for the slide to continue after the question is answered, but I am hitting a wall on how to the "summarizing" part. Is it possible to do what I'm intending? Thoughts, comments, all are welcome!

    Lilybiri
    Legend
    October 7, 2016

    I will give it a try, with another approach. Create two variables: v_ChoiceA and v_ChoiceB. Give each a default value of 0.

    After the first question slide increment the variable that corresponds with the choice, either A or B.

    Do the same for the second and third question.


    The condiitonal action On Enter for the results slide will now have only 3 decisions:

    IF v_ChoiceA is equal to 3 Change State to Normal

    IF v_ChoiceB is equal to 3 Change State to State2

    IF v_ChoiceA is less than 3 OR v_ChoiceB is less than 3 Change State to State3