1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
|
<scene name="scene_1" onstart="delayedcall(0.1,test(500,50,100,50));" ...
<hotspot name="spot" type="text" width="20.00" height="20.00" bgcolor="0xFF0000" />
<!-- test(X max,X min,Y max,Y min); -->
<action name="test" scope="localonly" args="Xmax, Xmin, Ymax, Ymin">
mul(valX, global.random, get(Xmax));
mul(valY, global.random, get(Ymax));
if(valX LE Xmin, test(get(Xmax), get(Xmin), get(Ymax), get(Ymin));
,
if(valY LE Ymin, test(get(Xmax), get(Xmin), get(Ymax), get(Ymin));
,
screentosphere(valX,valY, global.hotspot[spot].ath, global.hotspot[spot].atv);
);
);
</action>
|