How to program buttons so that....

Oct 05, 2015

In this SL1 .story project, the learner has to proceed in linear sequence first time through the course. And then learner should be able--once all Scenes have been completed but prior to starting the Test--to revisit any Scene in any order. How can I program these buttons to make this work? I assume it has to do with some [x] variable changing, yes?

Any suggestions appreciated!

Joseph

37 Replies
Joseph Roberson
Ashley Terwilliger

First, triggers that may not work on a particular slide is something like "when variable changes" - the variable needs to change on that particular slide...so if you were adjusting the variable somewhere else, that trigger won't execute.

Now I am more confused. Are you saying that a variable must always be located on–and its value changed by some action on–the same slide as the trigger using that variable? I thought the whole point to using a variable was that it provides a way to control buttons and other objects that are NOT on the same slide. What am I missing here? 

Joseph Roberson
Ashley Terwilliger

Master slides can have buttons and triggers attached to them and used on layers as well. How you set that up is likely the issue you're running into - as the trigger will have to be the same for every slide using that master. So for example if it's a regular navigation button and it's "jump to next slide" that's ok. If you need to say "jump to X slide" that would have to be set up on the individual slides. 

Hi Ashley,

Thanks for taking on my multi-part question....

Regarding my first Question:

I have a separate Master for each Lesson (Scene):

Scene 1 Master is for Intro and Nav slides; Scene 2 Master is for Lesson 1; Scene 3 Master is for Lesson 2; Scene 4 Master is for Lesson 3; Scene 5 Master is for the Test.

So, today I am trying out pasting the custom nav button set onto each Master. I had to go through each and every button and tweak formatting since Copy/Paste does not honor formatting (weird and inconsistent changes to the copied buttons). 

Next, I set the button states on each Master:

Scene 1 Master = Intro, Nav, and Lesson 1 buttons are Normal; all others are Disabled;

Scene 2 Master = same as above (ibid)

Scene 3 Master = same as above (ibid) + Lesson 2 button Normal

Scene 4 Master = ibid + Less0n 3 Normal

Scene 5 Master = ibid + Test button Normal (all buttons Normal)

From what you wrote, "the trigger will have to be the same for every slide using that master," I think I am OK up to this point since every slide in each scene has the same button array. Correct?

Next step is to provide a way to make the next Scene available. This new trigger/button must be on the content slide itself. I'll simply copy/paste the button from the Master onto the content slide and set its initial state to Normal. On the timeline, it will only appear at the end. Clicking this button jumps to the next Scene. 

So far, so good?

Finally, I have to set up so that, once the learner has gone through everything and taken and submitted the Test, the navigation is completely free. I see 2 potential ways to accomplish this.

First one is to change to state of every button on every Master to Normal via a variable that changes to True at the end, on the Results page maybe.

Second would be to somehow enable the Menu after the Test. I don't think this is possible, but would like to hear otherwise.

Ashley Terwilliger-Pollard

Hi Joseph,

Sorry if I confused you further! I'm going to reply to your posts as if they were separate to not cause any further confusion.

I was only referring to the "when" element of a trigger based on "when variable changes". So as an example, if you're setting up Slide 1 and the variable ABC is adjusted on slide 1, and you advance to slide 2 where there is a trigger to change the state of the object 123 when the variable ABC changes, it'll never be executed as that change already occurred. The "when" element of that trigger is looking to execute the change state trigger based on the exact moment when the variable changes, and since it didn't occur on that slide - it won't work. 

So if you changed variable ABC on slide 1, and wanted to change object 123 on slide 2, instead you could set it up to have a trigger like "change state of object 123 to the disabled state when timeline starts on the condition that variable ABC is equal to XX." Does that make more sense?

Ashley Terwilliger-Pollard

Ok - I think I'm following this set up - first in regards to your c/p behavior, I'd want to confirm that you're working on local project files as described here. Next, are you using the copy/paste buttons in the trigger panel or Windows keyboard/right click short cuts? I'd use the trigger panel buttons - and you could also look at "duplicating" the slide masters -makes a copy of the entire master and then you can move and rebuild as necessary based on the next scene. 

As far as the triggers, same button array - but also doing the same thing. In this scenario it sounds like "jump to next slide or scene" depending? Can't force it to say "jump to slide 3.2" as any slide that uses that master would have the same. 

Enable the menu that is a part of the player? There isn't a way to trigger it using Storyline's built in menu set up. If you use the "restricted" navigation, the learner would only be able to click on the menu to see slides they already saw - but not advance beyond that point. You can read about that as an option here. 

Joseph Roberson

Dear Ashley, Wendy, Jason, Christie, Walt...

Your help is fabulous!

The navigation works pretty much as intended the first time through.

What still does not work is when revisiting slides. Maybe it's too much to expect, but my intention is that once the learner has gone through the entire course once, they can revisit any Scene without having to plod through them in sequence.  I cannot figure out how to set up variables and triggers so that the state of every button on every Master is Visited if the learner views any slide again.

I have stripped all content so to be able to share the .story file.

How would you accomplish this?

Joseph

Note: Whatever Scene you are currently viewing, a copy of that Scene's button sits on top in the content slide... in "new Down state." I couldn't see any simpler way to assure that the correct  'highlighted' button would always show up.

Walt Hamilton

I think the state of lesson 1 and 2 is what you want.

 

 

You need to change the trigger on the master from when the variable changes to when timeline starts.

 

I'm not sure the master reads the variable change well. I know that one slide cannot recognize when a variable changes on another slide, and something like that seems to be at work with your master, as well. The other thing I would suggest is that you don't use a trigger to set the state to visited. I copied the visited state to a new state I called Completed. (On Lesson 2 button I was lazy and just used normal.) Using triggers to set built-in states other than normal and hidden can sometimes cause problems.

You will need to copy those triggers to all the masters.

Joseph Roberson

Hi Walt and Ashley,

Thanks....

I deleted all Masters except one to simplify matters. That helped alot. 

All button-state triggers are now on 1 Master and all are set to "When timeline starts."

Basically, this thing is working as intended now, but I am going to copy/paste built-in buttons and shift all triggers over to these new buttons and away from the built-ins.

I hope that will be the end of this *$@)&)!@$ scenario! I will upload this updated file ASAP in case you have time to verify that I have done everything properly. 

Again, thanks for steering me through this. Frankly, without this community help I would have abandoned Storyline. I still think it is extremely buggy and needlessly opaque. I hope SL2 is better. I just cannot afford to buy it, especially now that I cannot get a student discount. 

;-)

Walt Hamilton

Technically, it is not the buttons, it is the built-in states. When you add a button, it comes with a bunch of built-in states (selected, down, visited, disabled, hover, etc.)  When you click on the button, the visited state kicks in and does its thing, which may conflict with what you want it to do if you change the state to visited with a trigger.

When you used this trigger

the visited state was running two sets of instructions: The one you had written, and the one we can't see that is programmed into it. Those two sets of instructions may or may not conflict in what they do when. You can use this same trigger to change to a custom state (instead of "visited") and all will be well.

When you create a custom state, the new state doesn't have any built-in triggers, so there is no conflict.

If you copy everything over to a new set of buttons, you will have the same vulnerability to conflicts, because the new buttons will have the same built-in states.

 

Ashley Terwilliger-Pollard

Hi Joseph,

If you're using custom states you'll have to add the triggers - only the built in states are preprogrammed - but using them in addition to adding triggers is what Walt was referring to in terms of causing issues. The bottom line being, let Storyline run the show with built in states/programmed "triggers" or set up your own custom states and assign triggers to them. Are you duplicating the built in states? I'd say duplicate the "normal" state only - since there isn't much associated with it. 

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