Hi,
I am new to using Krpano and XML coding. I'm trying to get autotour to function and it's driving me crazy . Below is the code I am using which I found in forum. The first scene loads and auto rotates, the 2nd scene loads and is stationary for the 5 secs (wait(5)), the 3rd scene loads does the same as the 2nd scene, then this repeats.
Any advice/assistance will be greatly appreciated.
Thanks
Mike
<krpano version="1.16" title="Virtual Tour" onstart="startup();">
<include url="skin/vtourskin.xml" />
<!-- set skin settings: bingmaps? gyro? thumbnail controlling? tooltips? -->
<skin_settings bingmaps="false"
bingmaps_key=""
bingmaps_zoombuttons="false"
gyro="true"
thumbs_width="120" thumbs_height="80" thumbs_padding="10" thumbs_crop="0|40|240|160"
thumbs_opened="false"
thumbs_text="false"
thumbs_dragging="true"
thumbs_onhoverscrolling="false"
thumbs_scrollbuttons="false"
thumbs_scrollindicator="false"
tooltips_thumbs="false"
tooltips_hotspots="false"
tooltips_mapspots="false"
controlbar_offset="20"
/>
<!-- set optional skin logo url -->
<layer name="skin_logo" url="" scale="0.25" opened_onclick="openurl('...',_blank);" />
<action name="startup">
if(startscene === null, copy(startscene,scene[0].name));
loadscene(get(startscene), null, MERGE);
setuptour()
</action>
<scene name="scene_SurfHQ-Back" title="SurfHQ-Back" onstart="" thumburl="panos/SurfHQ-Back.tiles/thumb.jpg" lat="" lng="" heading="">
<view hlookat="0" vlookat="0" fovtype="MFOV" fov="120" maxpixelzoom="2.0" fovmin="70" fovmax="140" limitview="auto" />
<preview url="panos/SurfHQ-Back.tiles/preview.jpg" />
<image>
<cube url="panos/SurfHQ-Back.tiles/pano_%s.jpg" />
<mobile>
<cube url="panos/SurfHQ-Back.tiles/mobile_%s.jpg" />
</mobile>
</image>
<!-- place your scene hotspots here -->
</scene>
<scene name="scene_SurfHQ-Middle" title="SurfHQ-Middle" onstart="" thumburl="panos/SurfHQ-Middle.tiles/thumb.jpg" lat="" lng="" heading="">
<view hlookat="0" vlookat="0" fovtype="MFOV" fov="120" maxpixelzoom="2.0" fovmin="70" fovmax="140" limitview="auto" />
<preview url="panos/SurfHQ-Middle.tiles/preview.jpg" />
<image>
<cube url="panos/SurfHQ-Middle.tiles/pano_%s.jpg" />
<mobile>
<cube url="panos/SurfHQ-Middle.tiles/mobile_%s.jpg" />
</mobile>
</image>
<!-- place your scene hotspots here -->
</scene>
<scene name="scene_SurfHQ-Front" title="SurfHQ-Front" onstart="" thumburl="panos/SurfHQ-Front.tiles/thumb.jpg" lat="" lng="" heading="">
<view hlookat="0" vlookat="0" fovtype="MFOV" fov="120" maxpixelzoom="2.0" fovmin="70" fovmax="140" limitview="auto" />
<preview url="panos/SurfHQ-Front.tiles/preview.jpg" />
<image>
<cube url="panos/SurfHQ-Front.tiles/pano_%s.jpg" />
<mobile>
<cube url="panos/SurfHQ-Front.tiles/mobile_%s.jpg" />
</mobile>
</image>
<!-- place your scene hotspots here -->
</scene>
<action name="setuptour">
set(step,1);
set(idletime,60);
set(events.onidle, autotour() );
</action>
<action name="autotour">
oninterrupt(break);
if(step == 1, wait(0); inc(step); );
if(step == 2, loadscene(scene_SurfHQ-Middle,NULL,BLEND(1)); wait(5); inc(step); );
if(step == 3, loadscene(scene_SurfHQ-Front,NULL,BLEND(1)); wait(5); inc(step); );
if(step == 4, loadpano(tour.xml,NULL,BLEND(1)); wait(); inc(step); );
</action>
<autorotate enabled="true" waittime="3" speed="5"/>
</krpano>