Random number variable not working

Hi! Can anyone see why my airmail variable (arvonta) is unreliable? It's set to zero when the plane leaves the slide and to show a layer when the variable changes as the plane intersects with the cloud. But: when there's two same random numbers in a row, the layer is not shown. To my understanding it should, since the variable changes from zero. Anything I can do?

3 Replies
Chris Foster

Hi Iina,

On each layer change: "Change state of picture 1...." triggers for "Hide this layer...." triggers when user clicks picture 1.

Also, consider checking the "Prevent user from clicking on the base layer" option on each of the layers as you are able to bypass by clicking on the controller instead. 

I added a hotspot to the base layer to speed up the reset of the counter. 

Hope this is what you are after,

 

Good luck!

Chris Foster

You're welcome Iina,

Ok so the picture thing - the original was set up with the image on each of the six layers being in an initial state of "normal" with a trigger to change the state to "hidden" when the image is clicked. There is no trigger to close the layer. 

If you click on the cog or gear icon when a layer is selected you will open the "Slide Layer Properties" - at the bottom you will see that there are rules you can set when the slide is revisited.

There are three to choose from:

  • let the system decide
  • to reset to initial state
  • to resume saved state  

If there is no trigger to close the layer, whichever of the above three options you selected wouldn't come into play. I think this was causing your project to fall over. 

 

The hotspot only sped up the counter in the sense that as soon as the plane touched it, the counter would reset and because the hotspot is right next to the cloud, this happened sooner than when it reset when "Line Motion Path 1 on Picture 1 completes," because this meant you had to wait until the plane left the slide. I only did it so I could test the fix faster - it doesn't need to be there.