You are not logged in.

1

Wednesday, May 27th 2020, 3:17pm

how to load a different layer in each scene of a tour

How to load a different layer in each scene of a tour, a different info button for each scene.


onstart="set(layer[info1].visible, true);set(layer[info2].visible, false);set(layer[info3].visible, false);set(layer[info4].visible, false);" a simpler solution than this


Thank you

2

Wednesday, May 27th 2020, 3:31pm

just add the layer in your scene without keep=true

<scene name="a" ... >
<layer name="info" url="a.jpg" ... />
</scene>

<scene name="b" ... >
<layer name="info" url="b.jpg" ... />
</scene>

panoyun

Beginner

Posts: 31

Location: Somalia

  • Send private message

3

Wednesday, May 27th 2020, 3:52pm

Source code

1
2
3
4
5
6
7
8
9
10
11
12
	<events name="events_jaupcxpekddz" keep="true" onloadcomplete="action_mblrlralqdzm();"/>

	<action name="action_mblrlralqdzm">
    for(set(i, 0), i LT scene.count, inc(i), 
    	set(layer[calc('info' + i)].visible, false);
    	trace('layer[',calc('info' + i),'].visible=',layer[calc('info' + i)].visible);
        if(scene[get(xml.scene)].index == i, 
            set(layer[calc('info' + i)].visible, true);
            trace('layer[',calc('info' + i),'].visible=',layer[calc('info' + i)].visible);
        );
    );
	</action>

*tongue* *tongue* *tongue*

4

Wednesday, May 27th 2020, 4:32pm

solved, thanks everyone