Making Shapes, Images draggable

Aug 26, 2015

Often times I need to make a shape or image draggable, and I've not been able to find a satisfactory way to do it. I.e., I'm looking for a pure way that is least likely to cause issues.

I have a bunch of shapes on the right, and I need them to be draggable. I make the drag item change the state of something else when it's dropped on the outline drop zone. But when I run it the object is not draggable.

Oddly, if I change the 'When' to 'dragged over' it suddenly does become draggable. Why? And why not when I set it to work when 'dropped on.' Is there any other way to make it a draggable item?

  • I could add a 'dragged over' trigger that does nothing just so I have a draggable item. But then there are useless triggers that may confuse future maintainers of the code.
  • I could click 'convert to freeform' then undo the changes and change the settings so I can make this custom interaction work. But this slide I'm making is to look at pieces of an object, not a test that will be graded.

    Also note that I need several customer interaction to happen on a drop. State changes and show layers, at a minimum.

Both of these ways would work. Both of these add unnecessary, potentially confusing elements to the slide that may result in future maintainers messing it up. For example, deleting triggers that seem do nothing. Or, inspecting the options in the convert to freeform tab and causing the navigation buttons to change.

Is there some other way that has simply eluded me?

(Storyline 2)

9 Replies
Ashley Terwilliger-Pollard

Hi Shawn,

Thanks for sharing the sample here. You mentioned changing it to a freeform, and that would be the way I'd set this up even if you're not grading it. You can remove the score, and choose to not provide any feedback which will remove the feedback layers, and if you don't include a results slide or don't include this "question" as a part of the results slide then no score will be tracked/calculated. 

With Storyline though, there's a number of ways to accomplish the same thing, so others may chime in on their preferred method! 

Shawn P. Conroy

Uh, this is such a drag.

Thanks. I took your advice and created a freeform. In this example when I drag the nose drag shape to the outlined nose drop zone it snaps in nice and tightly. I then added a number of triggers and could not get most of them to work.

I've attached a copy of my Storyline file that tries to run a trigger that hides a text box. But it doesn't work and I'm not sure why. Any thoughts?

Shawn P. Conroy

I discovered what the problem is. The problem is that that triggers attached to objects in a scrolling pane rarely work. In my example if you drag the nose triangle shape out of the scrolling pane the trigger works fine. It's only when it's in the scrolling pane that it causes a problem.

This problem also rises with pictures instead of shapes. I suspect this happens to all objects.

But, some triggers do work. So far I've found two types of triggers that will work in the scroll pane:

  • The drag object trigger can change its own state.
  • The drag object trigger can change a variable.

I suspect that triggers fail if the object you are trying to trigger it outside of the scroll pane. Variables and the drag object itself are not 'out of scope,' which is why they work.

Ashley Terwilliger-Pollard

Hi Shawn,

Thanks for updating us here and good find on that file - I did find that it's been something we've shared with our team previously that the triggers don't seem to work as expected when referencing objects in the scrolling panel. I don't have an update on that particular issue, but will update you once there is additional information. Will those two triggers work for you in regards to using the objects in a scrolling panel? I assume since this is just a sample slide you have more objects than just the 3 shown? 

Shawn P. Conroy

I'm not entirely clear what you mean. In the example I provided it has a trigger that hides the instructions text box. It does not work as is. However, if you drag the object out of the scroll panel it does work.

Obviously, there are no triggers on the other objects. I've rebuilt this section several times since you recommend that course of action. I couldn't figure out why sometimes it worked and sometimes it didn't. The other day I realized the scroll panel was the confounding factor.

This discussion is closed. You can start a new discussion or contact Articulate Support.