Layers & Variables

I have attached a very simple file that has 3 buttons that show 3 layers and each layer sets its own variable to True. When all three buttons have a Visited state, I want a 4th layer to appear.

I can get all three variable references to appear on the base slide with a status of True but still cannot get the 4th layer to appear.

Any help would be greatly appreciated.

Cindy

6 Replies
Tim Hillier

Cindy;

I figured out the problem and a possible solution yet.  Maybe understanding the problem will help you with a better solution.

You are showing your fourth layer but it is so quick you cant see it.  When the third button is pushed causing it to be visited the fourth layer shows but then immediately goes to the button layer.  then when the button layer closes it goes back to the main layer so you never see the fourth layer.  I found this out by deleting the one button layer trigger to see if the fourth layer would appear and it does.

My suggestion would be to use a different option than visited as that happens immediately.  Perhaps a trigger on each layer that says go to layer 4 if they other variables are true.

I have attached a suggestion.

Tim

Jesse Spinella

I find number variables infinitely more useful than true false variables in these situations. Here's why:

1. True / False variables can only track one thing happening at a time. Think of it like a light switch. On or off.

2. Number variables can track an infinite number of things happening when you set up the triggers correctly.

In this instance, if you set a number variable to count to three when you click a button, you can then set the true false variable to true when the number variable reaches three.

Buttons is a number variable that adds one every time a user clicks the return to base layer button.

You need a condition on this button to only have that added once. Therefore, if you create a true false variable that is tripped the first time the user clicks it, that user can then come back to this slide as many times as they like to review what was there, but the number will have only been added once.

If you place the Done equal to true when "buttons" changes if "buttons" is equal to 3 on each of the layers (not the base layer), it'll flip the done trigger in the correct order so when you get back to the base layer, the complete layer will automatically be visible.


Then on the base layer, you'll show the completed layer when variable changes on Done. On condition if Done is equal to true.

Here's your modified .story file.

Hope this helps!