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
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
|
<krpano version="1.0.8" >
<events onxmlcomplete="hist_new()" />
<history />
<action name="delete_array">
if (%1.count !== null,
if (%1.count GT 0,
set(%1[0].name,null);
delete_array(%1);
);
);
</action>
<action name="hist_new">
if (%1 == null,
if (history.back.count === null,
hist_new(0,-1);
<!--else-->,
sub(action[%0].tmp,get(history.back.count),1);
hist_new(get(history.back.count),get(action[%0].tmp));
);
<!--else-->,
if (history.back[%2].name !== xml.url,
set(history.back[%1].name,get(xml.url));
delete_array(history.forward);
if (history.back.count GE 2,
set(plugin[back_button].visible,true);
tween(plugin[back_button].alpha,1,0.5);
);
tween(plugin[forward_button].alpha,0,0.5,linear,set(plugin[forward_button].visible,false););
);
);
</action>
<action name="hist_back">
if (%1 == null,
sub(action[%0].tmp,get(history.back.count),1);
sub(action[%0].tmp2,get(history.back.count),2);
if (action[%0].tmp2 GE 0,
hist_back(get(action[%0].tmp),get(action[%0].tmp2));
);
<!--else-->,
set(history.forward[-1].name,get(history.back[%1].name));
set(history.back[%1].name,null);
if (history.back[%2].name !== null,
loadpano(get(history.back[%2].name),null,KEEPBASE,BLEND(2),;);
);
if (history.back.count LE 1,
tween(plugin[back_button].alpha,0,0.5,linear,set(plugin[back_button].visible,false););
);
set(plugin[forward_button].visible,true);
tween(plugin[forward_button].alpha,1,0.5);
);
</action>
<action name="hist_forward">
if (%1 == null,
if (history.forward.count != null,
sub(action[%0].tmp,get(history.forward.count),1);
if (action[%0].tmp GE 0,
hist_forward(get(action[%0].tmp));
);
);
<!--else-->,
set(action[%0].tmp,get(history.forward[%1].name));
set(history.back[-1].name,get(history.forward[%1].name));
set(history.forward[%1].name,null);
loadpano(get(action[%0].tmp),null,KEEPBASE,BLEND(2),;);
if (history.forward.count LE 0,
tween(plugin[forward_button].alpha,0,0.5,linear,set(plugin[forward_button].visible,false););
);
set(plugin[back_button].visible,true);
tween(plugin[back_button].alpha,1,0.5);
);
</action>
<plugin name="back_button"
url="%SWFPATH%/skin/buttons.jpg"
keep="true"
visible="false"
alpha="0"
align="topleft"
edge="center"
y="20"
x="20"
crop="0|0|40|40" onovercrop="0|40|40|40" ondowncrop="0|80|40|40"
blendmode="screen"
onover="set(blendmode,add);"
onout="set(blendmode,screen);"
onhover="showtext(click to move back);"
onclick="hist_back()" />
<plugin name="forward_button"
url="%SWFPATH%/skin/buttons.jpg"
keep="true"
visible="false"
alpha="0"
align="topleft"
edge="center"
y="20"
x="60"
blendmode="screen"
crop="40|0|40|40" onovercrop="40|40|40|40" ondowncrop="40|80|40|40"
onover="set(blendmode,add);"
onout="set(blendmode,screen);"
onhover="showtext(click to move forward);"
onclick="hist_forward();" />
<!--EXAMPLE HOTSPOTS-->
<hotspot name="hs2"
url="%SWFPATH%/plugins/hotspot_ani_white.swf"
ath="0"
atv="-5.14"
keep="false"
visible="true" enabled="true" handcursor="true" capture="true" children="false"
onhover="showtext(Click here to goto history2)"
onclick="set(view.fovmin,5);looktohotspot(hs2,10);loadpano(history2.xml,null,KEEPBASE,BLEND(2),lookat(38.45,24.01,50.34);wait(blend);lookto(0,0,65,smooth(100,100,100));)"
>
</hotspot>
<hotspot name="hs3"
url="%SWFPATH%/plugins/hotspot_ani_white.swf"
ath="0"
atv="5.14"
keep="false"
visible="true" enabled="true" handcursor="true" capture="true" children="false"
onhover="showtext(Click here to goto history3)"
onclick="set(view.fovmin,5);looktohotspot(hs3,10);loadpano(history3.xml,null,KEEPBASE,BLEND(2),lookat(38.45,24.01,50.34);wait(blend);lookto(0,0,65,smooth(100,100,100));)"
>
</hotspot>
<preview type="grid(cube,16,16,512,0xCCCCCC,0x333333,0x999999);" details="16" />
</krpano>
|