I use two “Text Entry” objects in my slide. Both have a maximum of 6 attempts. After 3 attempts a hint is shown.
During presentation I can move back and forth between the previous and the current (slide with Text Entries) slide. If I solved only one of the Text Entries and move back to the previous slide, the Text Entry should be resetted. I got that with “Clear User Input”, but the attempts-counter is not resetting and I don’t find an option to reset the attempts. Is there a way to reset attempts as well?
The built-in attempt counter can’t be reset. As a workaround, set Attempts to Infinite for both Text Entries and count the attempts with your own variables:
Create two number variables, e.g. attempts1 and attempts2 (initial value 0).
Set both hints as Initially Hidden (right-click the hint > Playback > Initially Hidden).
Add the built-in Disabled state to both Text Entries (Object States pane > Add State > Built-in States > Disabled).
In the On Incorrect event of Text Entry 1:
Adjust Variable: attempts1 + 1
IF attempts1 >= 3, THEN Show Object (hint 1)
IF attempts1 >= 6, THEN Change State (Text Entry 1) to Disabled
Do the same for Text Entry 2 with attempts2.
In the slide On Load event:
Adjust Variable: attempts1 = 0 and attempts2 = 0
Change State: both Text Entries to Normal (before Clear User Input)
Clear User Input: All showing interactions
Each time the learner returns to the slide, the Text Entries are enabled and cleared, the hints are hidden again, and the attempts start from 0.