I have a symbol with the ID "drop1" (It's a drop target for a drag and drop game)
It has a single timeline called "Main Timeline", which is a simple 0.5 second fade-in effect, with a pause action on the first frame to prevent it from playing immediately.
I'm using this bit of code to tell the symbol's timeline to play when another element is dropped onto it:
var dropTarget = "drop" + index;
hypeDocument.getSymbolInstanceById(dropTarget).startTimelineNamed("Main Timeline", hypeDocument.kDirectionForward);
The code looks correct, but the timeline doesn't start.
I've done some diagnostic testing:
... it displays the correct symbol
... this displays "false"
... displays "0.5", which is the correct timeline length.
hypeDocument.getSymbolInstanceById(dropTarget).goToTimeInTimelineNamed(0.3, "Main Timeline");
... goes to the correct time (0.3 milliseconds) in the timeline.
So it seems that although I'm referencing the correct timeline, it's not playing.
Can anyone suggest where I should look or what I might have done wrong?
(By the way, the symbol timeline does play when the scene first loads and the pause action is removed from the first frame.)