What am I doing wrong? (Triggers/Variables)

Mar 26, 2013

I want to set this screen so that the Next button is not active until both buttons are visited. I have it set up exactly the same way I did it in another module except they are going to separate screens instead of layers. Should that make a difference? Every time I preview it, it works on the first button but not the second one when I return to the main slide. Please help if you can.

6 Replies
David Anderson

Hi Anna,

When learners leave the slide and later return to the slide, you'll need to use variables to evaluate and retain visited states. Here's a similar example with source files that covers what you're trying to do:

http://community.articulate.com/forums/p/13107/77730.aspx

If you have questions, you can also post your file and we'll be more than happy to work from your file.

David

El Burgaluva

Hi, Anna

Your slide properties might be contributing to the problem. if you've got it set to "Reset to Initial State" and you've got triggers based on, for example, "Visited" states (as Aaron suggests), then it won't work because the states will be, well... reset.

So... it's probably better to control it using variables and/or sending the learners to layers on this slide rather than a new slide.

  • Create two True/False variables: one called "budget" and the other called "currentbill". (Or "button1" and "button2".) Set them initially to "False". 
  • Create a trigger on the slide or layer each button links to: "Adjust variable:button[number] to value true when timeline starts.
  • Create an "invalid" layer with a message saying "Please explore both options" (or whatever). Add a button to hide this layer.
  • Add the following triggers -- in this order -- to your [NEXT] button:
  • Show layer:invalid when user clicks IF variable:button1 is equal to false OR variable:button2 is equal to false.
  • Jump to Slide/Scene [1234] when user clicks IF variable:button1 AND variable:button2 are equal to true.

Hope that helps!

Leslie

P.S.  If you've got the same set-up across multiple slides/scenes/scearios, call your variables "button1", "button2", "button3", etc. What is the maximum number of buttons used on a challenge-point? If it's, say, four, then create four variables. Then add the following triggers in between the "Show layer:invalid" and "Jump to" triggers on your [NEXT] button:

  • Adjust variable:button1 to value false when user clicks
  • Adjust variable:button2 to value false when user clicks
  • Adjust variable:button3 to value false when user clicks
  • Adjust variable:button4 to value false when user clicks

Then they will reset, ready to go again in your next challenge/scenario.

Anna Veach

Thanks everyone for your replies.

Aaron:  I already have a condition on the Next button to jump to the slide when the variable I created is True.

El Burgaluva: I already have True/False variables set for the buttons. I also changed the slide properties to "Resume saved state" instead of "Automatically decide"

I think I need something that will prevent the variable from resetting when the learner returns to this slide. That could be what David Anderson referred to above and I'm going to try that. Otherwise, I might put everyone on two other layers because I think that will make it work better. I hope I can do this quickly thought because this is the last thing I need to fix before I send it out for final review!

Anna

Anna Veach

I fixed it! I decided that having one variable for both buttons might be the source of the problem. So I created a variable for both buttons separately and set the triggers to change the variable to True when the button state changes to visited and then the trigger on the Next button had the condition that both had to be true. It worked this way so I'm going to go with it. Now I need to figure out how to make the audio stop when the learner clicks the buttons since new audio starts on those screens.

Thanks for all of your help!!

Anna

Anna Veach

Leslie (El Burgaluva),

Looks like your first suggestion of creating two variables (I thought I could do it with one) was the correct answer! Thanks for your help!

Anna

El Burgaluva said:

Hi, Anna

Your slide properties might be contributing to the problem. if you've got it set to "Reset to Initial State" and you've got triggers based on, for example, "Visited" states (as Aaron suggests), then it won't work because the states will be, well... reset.

So... it's probably better to control it using variables and/or sending the learners to layers on this slide rather than a new slide.

  • Create two True/False variables: one called "budget" and the other called "currentbill". (Or "button1" and "button2".) Set them initially to "False". 
  • Create a trigger on the slide or layer each button links to: "Adjust variable:button[number] to value true when timeline starts.
  • Create an "invalid" layer with a message saying "Please explore both options" (or whatever). Add a button to hide this layer.
  • Add the following triggers -- in this order -- to your [NEXT] button:
  • Show layer:invalid when user clicks IF variable:button1 is equal to false OR variable:button2 is equal to false.
  • Jump to Slide/Scene [1234] when user clicks IF variable:button1 AND variable:button2 are equal to true.

Hope that helps!

Leslie

P.S.  If you've got the same set-up across multiple slides/scenes/scearios, call your variables "button1", "button2", "button3", etc. What is the maximum number of buttons used on a challenge-point? If it's, say, four, then create four variables. Then add the following triggers in between the "Show layer:invalid" and "Jump to" triggers on your [NEXT] button:

  • Adjust variable:button1 to value false when user clicks
  • Adjust variable:button2 to value false when user clicks
  • Adjust variable:button3 to value false when user clicks
  • Adjust variable:button4 to value false when user clicks

Then they will reset, ready to go again in your next challenge/scenario.

This discussion is closed. You can start a new discussion or contact Articulate Support.