You are not logged in.

esys

Intermediate

  • "esys" started this thread

Posts: 267

Location: Balazé France

Occupation: photographer

  • Send private message

1

Friday, February 10th 2012, 4:38pm

How to skip the intro movement of the scene, when coming back from an other one ?

Hi,

When i write a "moveto" code in the <krpano onstart=""> tag, i can set the fov, min, max when coming back in this scene from a hotspot in the other scene. That enables to open the first pano on the right fov (end of the introduce movement).

Source code

1
2
3
4
<krpano version="1.0.8.14" onstart="startup(); wait(LOAD); 
                            zoomto(95, linear(15)); 
                           moveto(-46, -9.5, linear(10)); 
                           tween(plugin[infos].alpha, 1.0, 1);">

When i write the "moveto" in the <scene onstart=""> tag, i can't skip the movement when coming back in this scene. The settings wrote in the <hotspot onclick=""/> tag don't work! No way to set the loaded scene at the right fov ?

Source code

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
		<scene name="scene_Rotisserie"
		   urlname="rotisserie"
		   title="Rotisserie" 
		            onstart="wait(LOAD);
		   	    wait(1);
           	            moveto(41.04,-0.20,linear(2));
            	            wait(0.5);
           		    zoomto(90,linear(45));"
           thumburl="panos/Rotisserie.tiles/thumb.jpg">

<hotspot name="Rotisserie"
	         url="hotspots/Fleches.swf"
	         keep="false"
	         ath="-152.95" atv="18"
           ..................................
	         onup=""
	         onclick="lookto(-152.10,1.87,40,smooth(100,50,20));
	                  tween(plugin[Texte-Buffet].alpha, 0.0, 2);    		  
                         loadscene(scene_Rotisserie, null, NOPREVIEW|KEEPCONTROL, BLEND(1.5));             
                         wait(LOAD);
                         set(view.hlookat, 41.04);
            	 	  set(view.vlookat, -0.20);
            	 	  set(view.fov, 90);"
	         devices="desktop"
	         />

With variable "if" ? A "visited" tag ? Thing i must write the movement in the <scene> tag because i use swf address plugin in this big tour.
Any help would be pleased. *smile*
Thanks.
Steph
Steph

2

Tuesday, February 14th 2012, 3:56pm

Hi,

you can try to add a variable where you save if the intro has already planed,

e.g.

Source code

1
2
3
4
5
6
7
8
<!-- create the "intro_done" variable and set it to false for the beginning -->
if(intro_done === null, set(intro_done,false));

<!-- check if it is false -->
if (intro_done == false,  
 	...do the intro action...; 
	set(intro_done,true);
);


best regards,
Klaus

esys

Intermediate

  • "esys" started this thread

Posts: 267

Location: Balazé France

Occupation: photographer

  • Send private message

3

Friday, February 17th 2012, 11:13pm

Thanks Klaus. Works great. *thumbsup*

Steph.
Steph