It totally does… your only missing link is that your still listening to the regular custom behavior instead you need to listen to the global one (“hashtag” notation)… meaning add a “#” infront of the listeners in your symbol so… #playRotate and #stopRotate. Thats all.
This is done so we still allow local behavior and don’t disturb that. Local as in, inside the Hype widget. Meaning if a listener doesn’t have the # infront it can’t be adressed from outside.
Look at the example. I really should do some more documentation and examples. My goal for 2019!
Nice to hear… Yes, could use a version bump outputting some nice error message if you misstype a Hype document name while targeting. Currently it just fires at whatever you throw at it… even if that doesn’t exist.
Using the @ symbol directs the custom behavior to only the specified Hype widgets
Hint: As in this flow the ping@C is sent to Hype GlobalBehavior and processed there. A internally actually only receives the string as is “ping@C” (little grey arrow)
The “echos” are the concept behind Hype GlobalBehavior. They form the unified layer of behavior. As said this is done to avoid disturbing local functionality and specially infinite loops.
“Echos” is therefor the wrong term in the sense that global behavior changes the custom behavior by adding a # in front. I could also have added an other string. I might even add an option to set the added string to something individual. Maybe something like global_ could help understand it better.
Thanks for that clarification, Max! I see now what is happening. I had noticed that when I had two instances on the page and hovered over the internal(round) Hype hover button, both instances played. But I hadn't realized that that only worked if other instances were also listening for the #CustomBehavior.
Personally, I don't think you need to change the naming... my confusion was in not understanding that I needed a listener starting with #. I was trying to put it in the script instead. Your screenshot above was what closed the loop for me. Perhaps a similar screen shot on your example page would help others.
This extension seems to set unique elements Ids of multiple widgets working in page wisely, is it possible to develop another extension to make class name of elements in multiple widgets working globally too?
About your question:
This extension doesn't set or use any element id's!
Off topic side note:
I also advise against element id's in a multi widget page. ID's must be by definition unique... rather use CSS classes to select stuff. See…
Wow, great explanation! Love the tutorial, very cool. I’m trying to embed multiple Hype scenes into a web page at various positions. When one element appears within the view, I want to trigger an action for a fixed position div with another scene embedded into it. Would this framework be suitable for my scenario? Just want to make sure I understand it correctly, and that the project being referenced isn’t all contained within a Hype Document, with scenes embedded into one another.