Hi All,
I'm struggling with a bit of code in a project. I'm loading several hotspots in a virtual tour and I want them to draw attention with a little motion tween, in this case a 'hartbeat'.
I wrote a little action for one of the hotspots but now I want to make the action universal to all hotspots without mentioning the specific hotspot names in the action itself.
I want to use the following flow:
This action is loaded in the hotspot-style with onloaded="beat-spots();"
This action is replaced by another motion tween with an onhover=" ;"
This action has to be loaded again with an onout=" ;"
I tried to fix this with something like: tween(hotspot(get(name)).scale, ... ... ... but the get-function doesn't work. As far as I understand the code this seems quite logical because the get will result in a null since there is no hotspot available on an onOut situation.
But, is it possible to rewrite this little piece of code to a repeating and universal action for all hotspots in a tour and with dynamic names?
See the projectlink: https://krpano.com/forum/wbb/www.…/supernova.html
See the the code below: