Forum Discussion
Getting the slide the user will continue from if they re-visit the course and switching language
Hi Russell, I don't think you have an easy solution for this one unfortunately. You will end up with several if statements, possible over 100 if you are supporting multiple languages and your course is large.
What I would suggest is setting a storyline variable to track both the current scene and current slide.
"sceneNumber" (type = Number)
"slideNumber" (type = Number)
In your Master Template, add the following trigger to update the variables
When timeline starts on this slide
- Set sceneNumber to variable Project.SceneNumber
- Set slideNumber to variable Scene.SlideNumber
Ok, that's one part of the problem solved. You now know the current scene and slide number, so when the user switches lannguage, you would then have to look at the sceneNumber and slideNumber variables, and send the user to the languages corresponding scene and slide.
Lots of if statements! I don't really think it is viable and will be horrible to maintain. You'd probably be better off employing some JavaScript too.
For example, scene 1 may correspond to scene 10 for "esp" scene 20 for "jp" and then the same with slide numbers.
You will also have the issue that when users switch languages, and interaction completed in "esp" will not be completed in the "en" stream.
Is there a compelling reason to allow users to switch languages? One that justifies the work ahead of you :)?
- RussellThoma0078 months agoCommunity Member
Thanks Sam, that was the conclusion I had reached too. It's complex but manageable as there are only 20 slides per story and 3 languages (stories). The only issue I have is when people re-visit the module, the logic I need to apply is:
User revisits module (slide 5 of scene 2) -> user is re-directed to language selection -> user is then re-directed to the corresponding language slide if a different language is selected (slide 5 of scene 3)
The re-direct logic is fine but I can't find a way to find out if the user has re-visited the module or a way to fire some logic only once so there is no re-direct loop on every slide. I guess a Javascript session or using the system date would be possible but is there a better way? Variables persist when re-visiting so I can't see a way to achieve this with variables alone.
Thanks- RussellThoma0078 months agoCommunity Member
Managed to get around the issue using this thread:
https://community.articulate.com/discussions/articulate-storyline/resume-storyline-course-from-beginning-and-save-status
All working now, thanks