Symbol Timeline Works but Running It From Scene Timeline Does Not

I’m building an interactive animation in Hype 4, and it will have a Play mode to make it run and look like a screencast. To make it work, the Play mode needs to highlight “clicks” so the viewer can see what they would click on to run it interactively. I’ve built a symbol that’s just a circle, which fades in and out with on a symbol timeline named “Activated”. So far, so good - running the Activated timeline in Hype causes the symbol to appear and then fade.

To tie this symbol timeline into the scene, I created created the following function:

function clickTap (hypeDocument, element, event) {
  var tc = hypeDocument.getSymbolInstanceById('tc-1');
  tc.startTimelineNamed('Activated', hypeDocument.kDirectionForward);
  console.log(tc.symbolName()); // testing
  console.log(tc.element()); // testing
}

Then I added an action to my “Autoplay” scene timeline to call the “clickTap” function. When I run the scene timeline, the circle doesn’t appear at all (in Hype or the browser). The console logging does in my function does work, so I know the function is being called.

Here’s the “Activated” symbol timeline:

hype_symbol_timeline

And the “Autoplay” scene timeline (which is being called by the Main scene timeline):

hype_scene_timeline

Maybe my issue is related to the External Element Visibility Mode for symbols? I tried all variations of that but no luck, but I couldn’t find any documentation on it.

Can you post a example project of what you are doing.

Thanks for the quick reply. Attached is a stripped-down/blurred version of what I’m working on. Click Play (lower left) to run the “screencast” mode. The no-show circle should appear around the 1 second mark. There’s another click show/fade circle that does show about 5 seconds in, but that’s done differently.

Show Click or Tap Test.hype.zip (385.2 KB)

It is because you leave the symbols opacity at 0.

You need to change it to 1 by code or maybe on the AutoPlay timeline with a keyframe for opacity and slide to 100%

Hi Mark - thanks! Works as intended in the browser, although I don’t see when running the AutoPlay timeline in Hype. Is that expected?

My read is that you are expecting the clickTap() timeline action to play within Hype’s scene editor?

Timeline actions do not play within the editor environment; this is expected.

(there’s just so many cases where it would make previewing an animation impossible if they were played)

Hi Jonathan - makes sense, thanks for confirming.