1 |
trimax = 8; |
2 |
blackon = 0; |
3 |
curx = __view_get(e__VW.XView, 0); |
4 |
curl = 0 + bgx; |
5 |
if (bgx >= 640) |
6 |
bgx -= 640; |
7 |
curscale = 1; |
8 |
tempscale = 0; |
9 |
curw = 5; |
10 |
if (on == 1) |
11 |
{ |
12 |
if (bgalpha < 1) |
13 |
bgalpha += 0.02; |
14 |
} |
15 |
if (on == 0) |
16 |
{ |
17 |
if (bgalpha > 0) |
18 |
bgalpha -= 0.02; |
19 |
} |
20 |
for (i = 0; i < 16; i += 1) |
21 |
{ |
22 |
draw_sprite_part_ext(spr_carouselbg_ch1, 0, curl, 0, curw, 300, curx, -i + __view_get(e__VW.YView, 0), curscale, 1, dkblue3, bgalpha); |
23 |
tempscale = 1 + (0.5 * i); |
24 |
curscale = floor(tempscale); |
25 |
curl += 5; |
26 |
if (curl >= 640) |
27 |
curl -= 640; |
28 |
curw = 5; |
29 |
curx += ((5 * curscale) - 5); |
30 |
} |
31 |
for (i = 16; i > 0; i -= 1) |
32 |
{ |
33 |
draw_sprite_part_ext(spr_carouselbg_ch1, 0, curl, 0, curw, 380, curx, -i + __view_get(e__VW.YView, 0), curscale, 1, dkblue3, bgalpha); |
34 |
tempscale = 1 + (0.5 * i); |
35 |
if (tempscale < 1) |
36 |
tempscale = 1; |
37 |
curscale = ceil(tempscale); |
38 |
curl += 5; |
39 |
if (curl >= 640) |
40 |
curl -= 640; |
41 |
curw = 5; |
42 |
curx += ((5 * curscale) - 5); |
43 |
} |
44 |
for (i = 0; i < trimax; i += 1) |
45 |
{ |
46 |
event_user(0); |
47 |
draw_triangle(xcen, ycen, xcen + newx1, ycen + newy1, xcen + newx2, ycen + newy2, false); |
48 |
} |
49 |
for (i = 0; i < 8; i += 1) |
50 |
{ |
51 |
event_user(0); |
52 |
ng = 0; |
53 |
if (newy1 > 0 || newy2 > 0) |
54 |
{ |
55 |
if (newx2 > (newx1 - 48)) |
56 |
draw_triangle(xcen, ycen - 80, xcen + (newx1 / 6), ycen + (newy1 / 6), xcen + (newx2 / 6), ycen + (newy2 / 6), false); |
57 |
} |
58 |
} |
59 |
for (i = 8; i >= 0; i -= 1) |
60 |
{ |
61 |
event_user(0); |
62 |
if (newy1 > 0 || newy2 > 0) |
63 |
draw_triangle(xcen, ycen - 80, xcen + (newx1 / 4), (ycen + newy1) - 380, xcen + (newx2 / 4), (ycen + newy2) - 380, false); |
64 |
} |
65 |
for (i = 0; i < trimax; i += 1) |
66 |
{ |
67 |
event_user(0); |
68 |
draw_triangle(xcen, ycen - 320, xcen + newx1, (ycen + newy1) - 320, xcen + newx2, (ycen + newy2) - 320, false); |
69 |
} |
70 |
siner += 2; |
71 |
if (on == 1) |
72 |
rotcounter += 1; |
73 |
if (rotcounter >= rotfps && on == 1) |
74 |
{ |
75 |
if (on == 1 && rotspeed < 1) |
76 |
rotspeed += 0.1; |
77 |
bgx += (1 * rotfps); |
78 |
rot += (2.5 * rotfps * rotspeed); |
79 |
rotcounter = 0; |
80 |
} |
81 |
|
82 |
enum e__VW |
83 |
{ |
84 |
XView, |
85 |
YView, |
86 |
WView, |
87 |
HView, |
88 |
Angle, |
89 |
HBorder, |
90 |
VBorder, |
91 |
HSpeed, |
92 |
VSpeed, |
93 |
Object, |
94 |
Visible, |
95 |
XPort, |
96 |
YPort, |
97 |
WPort, |
98 |
HPort, |
99 |
Camera, |
100 |
SurfaceID |
101 |
} |