Forum Discussion

FelixLi-04d0f92's avatar
FelixLi-04d0f92
Community Member
3 months ago

The state of some object does not change when the condition is met

I have made a random number generator and have it generate a random number every 2 seconds and assign the new number to a number holder variable, I made sure the number will not repeat from the previously existing number. However, whenever a number is generated, the corresponding card (card 1-6) should open, but there is some delay in the process. 


For example, if the number <3> is generated, card 3's state should change to "answer", but sometimes, the card 3 will never change.
I made it so the <check to change state> statement will happen more often by attaching the when condition to when random number changes, which happens very often and quickly. This does not fix the issue, but will make sure the state of the card gets changed eventually. 

What is causing the issue to happen? why won't the state changes when the condition is met? (I'm guessing that storyline 360 runs on a single thread execution or sequential execution, so when a  lot of things are happening quickly in the short amount of time, some information/packet gets lost in the process.)

If that's the case, what are some solution that I can implement to make this feature work?

Thank you in advance

  • Hi Felix,

    Looks like you built an interaction with a lot of moving parts. I opened a support case on your behalf to get more eyes on your project file. Our support engineers will email you as soon as they finish reviewing your triggers!

    • FelixLi-04d0f92's avatar
      FelixLi-04d0f92
      Community Member

      Hi Joes, Ian Saavedra the support engineer has reached out.

      During our conversation, I mentioned a second error that he was interested to take a look at.
      However, due to our company's email policy, I was not able to email him the file that he wanted to see. Please let him know that I have posted here.

      I attached the file under here with a image on the issue created from the order of which variable got changed first. Revert the order of those statement for all the OxygenTank_# will resolve the issue for this file, I recreated the issue just to use this file as an additional example on why I believe there could be a sequential initiation of the functions.

      (All the course contents were removed from the file before posting here publicly)

      Kind Regards,
      Felix

    • FelixLi-04d0f92's avatar
      FelixLi-04d0f92
      Community Member

      Hi Joes,

      Ian has helped me resolved the issue, turn out, I made some logical error that forces the functions to execute sequentially. 

      Thank you for sending Ian my way and and help me resolve the issue.

      Best regards,
      Felix

      • KellyAuner's avatar
        KellyAuner
        Staff

        Hi Felix,

        Thanks for letting us know!

        I'm glad Ian was able to help you out. If you need any assistance in the future, please reach out here or privately in a support case.