Forum Discussion
Drag 'n' drop issue
Nedim : Your solution is a great improvement on what I had posted (and have since deleted).
I haven't used a drag-and-drop in so long, and I didn't bother testing unlikely-but-still-possible situations, like if the user dropped an object outside of the targets or dragged an object that had already been correctly dropped. My bad. 🤷♀️
JG4 : I will add one note from the previous reply that I deleted: It's great that you only included the drag-and-drop slide in the file you uploaded. I also suggest that you give meaningful names to all objects and layers (and variables, if used). That will help you when programming. And it will make it easier for you and for others to troubleshoot.
You'll see that Nedim took the time to do that in the file he attached.
JudyNollet You shouldn’t have deleted your solution. Without it, it would’ve been much harder for me to identify the inconsistent Drop Incorrect state behavior — especially since you clearly defined both Drop Correct and Drop Incorrect states, which wasn’t the case in the original version.
Your version was more elegant, using only a few well-placed triggers to do the job. Since this interaction was mainly driven by the original poster’s requirements, I had no choice but to use additional triggers just to work around the Drop Incorrect state when it was no longer needed.
Custom drag-and-drop interactions are always tricky to fix or adapt. We all use different techniques — some more intuitive than others — and it’s always a challenge to implement custom logic on top of someone else’s structure.
I also suggest that you give meaningful names to all objects and layers (and variables, if used). That will help you when programming. And it will make it easier for you and for others to troubleshoot. Golden advice — this should be pinned to the top of every discussion thread.
- JudyNollet3 months agoSuper Hero
Thanks! I thought that your version included what worked in mine—and then made it better. So I figured it'd be simpler for folks to just look at one file. 😊
Related Content
- 9 months ago
- 4 months ago
- 2 years ago