Forum Discussion
Drag and Drop With Feedback Layers BUT NOT Correct or Incorrect
- 22 days ago
Although ThierryEMMANUEL has figured out a solution, I would still like to try a simpler version without using a tons of triggers.
I use the built‑in drag‑and‑drop function so that objects can return to the start area when a target is occupied. I also prefer using "state" for counting the TotalPlaced value and rely on two triggers to change the state.
What the built‑in model cannot change is that when another item is dropped on the same target, the original item still remains in the "placed" state even after returning to its initial position. Since this is the only issue in my solution, I thought—why not use the new AI assistant to solve the problem? Below is the prompt I gave the AI assistant, and it worked as expected. A single JavaScript snippet solved it.
Change the state of crit# to normal when they moves onto hotspot1 area. For example, change crit9 to normal when it moves onto hotspot1.
Here is my version3. As Nedim said, I also value discussions like this and gracful learn something from each other. Thank you!
Hello ELOUPEI
I explored (like JoanneChen) and abandoned solutions using states. Too complicated, because in addition, you want to use a built-in drag & drop to use the “automatic return of a movable element to its starting point if the learner places another element on top of it” function.
I suggest another way of doing this, which I have used before.
When you press the Finish button, you trigger the motion path of an element (mobile counter) that adds the value 1 to your TotalPlaced variable each time it encounters an element moved by the learner. If the mobile counter crosses 3 elements placed in the drop zone, TotalPlaced = 3, and the message “Too few” is displayed. Etc. Watch and study the attached demo, slide 2.
It's a bit of a DIY job, you have to make sure that the elements don't touch each other so that the mobile crosses each one of them, and not a bunch of elements, and the speed must not be too fast so that Storyline has time to trigger the triggers (yes, really!).
Here, the trajectory is straight, but imagine an activity where objects are dragged&dropped all over the screen. The mobile device can follow a very complex zigzag motion path to cross paths with the objects and count them. That's what I used a while ago.
Note: there is a small error in your triggers panel. The FINISH button ONLY appears/is active when the variable is between 4 and 6. It therefore cannot trigger other actions whose condition is that the variable is <3 or >6.
I hope this helps.
Related Content
- 4 months ago