I need to hide all the superfluous crap in order to allow the user to take a screenshot if he wants to, but the copyright plugin must always remain visible, so I can't use plugin.visible... How can I do this?
How do I hide all plugins but one?
-
-
Nevermind... It just occured to me that HOTSPOTS are what's unlimited/untrackable in my visit, not plugins I can simply hide all the plugins I want to hide individually and then use hotspot.visible to hide all the hotspots, achieving the desired result. Still, an alwaysvisible="true" attribute in a hotspot/plugin would be useful to make it "immune" to plugin.visible=false or hotspot.visible=false (in practice, such an attribute would just create the plugin/hotspot in a different parent movieclip).
-
Hi Protected,
Playing on your request , I get the following code that hides/shows all plugins/hotspots less the ones with an alwaysvisible="true" attribute:
Code
Display More<!-- usage: --> <!-- hide_param_less(plugin) --> <!-- hide_param_less(hotspot) --> <!-- show_param_that_wasvisible(plugin) --> <!-- show_param_that_wasvisible(hotspot) --> <action name="hide_param_less"> set(i,0); do_hide_param_less(%1); </action> <action name="do_hide_param_less"> if(i LT %1.count, ifnot(%1[get(i)].alwaysvisible, if(%1[get(i)].visible , set(%1[get(i)].wasvisible,true); ); set(%1[get(i)].visible,false); ); inc(i); do_hide_param_less(%1); ); </action> <action name="show_param_that_wasvisible"> set(i,0); do_show_param_that_wasvisible(%1); </action> <action name="do_show_param_that_wasvisible"> if(i LT %1.count, if(%1[get(i)].wasvisible , set(%1[get(i)].visible,true); ); inc(i); do_show_param_that_wasvisible(%1); ); </action>
Hope this can be useful ...
SAlut.
-
Wow, that's very cool, michel, thanks!
I've been noticing you seem to be one of the people who understands krpano scripting the best; I hope to see you among those helping with the wiki
Participate now!
Don’t have an account yet? Register yourself now and be a part of our community!