1 |
if (con == 0) |
2 |
{ |
3 |
timer++; |
4 |
headalpha += 0.1; |
5 |
circle1alpha += 0.1; |
6 |
if (timer == 10) |
7 |
{ |
8 |
con = 1; |
9 |
timer = 0; |
10 |
path_start(path, 10, path_action_stop, false); |
11 |
} |
12 |
} |
13 |
if (con == 1) |
14 |
{ |
15 |
circle2alpha = lerp(0, 1, path_position); |
16 |
circle2radius = lerp(75, 31, path_position); |
17 |
} |
18 |
if (path_position == 1 && con == 1) |
19 |
con = 2; |
20 |
if (con == 2) |
21 |
{ |
22 |
con = 3; |
23 |
var a = random(60); |
24 |
for (i = 0; i < 6; i += 1) |
25 |
{ |
26 |
bul = instance_create(x, y, obj_musical_note_bullet); |
27 |
if (i_ex(bul)) |
28 |
{ |
29 |
bul.sprite_index = spr_musical_notes; |
30 |
bul.grazepoints = 2; |
31 |
bul.timepoints = 1; |
32 |
bul.direction = a + random(24); |
33 |
bul.speed = 2; |
34 |
bul.friction = 0; |
35 |
} |
36 |
a += 60; |
37 |
} |
38 |
} |
39 |
if (con == 3) |
40 |
{ |
41 |
headalpha -= 0.1; |
42 |
if (headalpha < 0) |
43 |
instance_destroy(); |
44 |
} |
45 |
draw_set_alpha(headalpha); |
46 |
draw_sprite(spr_sweet_head, 0, x, y); |
47 |
draw_set_alpha(1); |
48 |
draw_set_alpha(circle1alpha); |
49 |
draw_set_color(c_red); |
50 |
scr_draw_circle_width_qbscr_draw_circle_width_qbfunction scr_draw_circle_width_qb(arg0, arg1, arg2, arg3, arg4)
{
var xx = arg0;
var yy = arg1;
var radius = arg2;
var width = arg3;
var steps = arg4;
var h = width / 2;
draw_primitive_begin(pr_trianglelist);
for (i = 0; i < steps; i += 1)
{
draw_vertex(xx + lengthdir_x(radius - h, (360 * i) / steps), yy + lengthdir_y(radius - h, (360 * i) / steps));
draw_vertex(xx + lengthdir_x(radius + h, (360 * i) / steps), yy + lengthdir_y(radius + h, (360 * i) / steps));
draw_vertex(xx + lengthdir_x(radius + h, (360 * (i + 1)) / steps), yy + lengthdir_y(radius + h, (360 * (i + 1)) / steps));
draw_vertex(xx + lengthdir_x(radius + h, (360 * (i + 1)) / steps), yy + lengthdir_y(radius + h, (360 * (i + 1)) / steps));
draw_vertex(xx + lengthdir_x(radius - h, (360 * (i + 1)) / steps), yy + lengthdir_y(radius - h, (360 * (i + 1)) / steps));
draw_vertex(xx + lengthdir_x(radius - h, (360 * i) / steps), yy + lengthdir_y(radius - h, (360 * i) / steps));
}
draw_primitive_end();
} (x, y, circle1radius, circle1width, 24); |
51 |
draw_set_alpha(circle2alpha); |
52 |
draw_set_color(c_white); |
53 |
scr_draw_circle_width_qbscr_draw_circle_width_qbfunction scr_draw_circle_width_qb(arg0, arg1, arg2, arg3, arg4)
{
var xx = arg0;
var yy = arg1;
var radius = arg2;
var width = arg3;
var steps = arg4;
var h = width / 2;
draw_primitive_begin(pr_trianglelist);
for (i = 0; i < steps; i += 1)
{
draw_vertex(xx + lengthdir_x(radius - h, (360 * i) / steps), yy + lengthdir_y(radius - h, (360 * i) / steps));
draw_vertex(xx + lengthdir_x(radius + h, (360 * i) / steps), yy + lengthdir_y(radius + h, (360 * i) / steps));
draw_vertex(xx + lengthdir_x(radius + h, (360 * (i + 1)) / steps), yy + lengthdir_y(radius + h, (360 * (i + 1)) / steps));
draw_vertex(xx + lengthdir_x(radius + h, (360 * (i + 1)) / steps), yy + lengthdir_y(radius + h, (360 * (i + 1)) / steps));
draw_vertex(xx + lengthdir_x(radius - h, (360 * (i + 1)) / steps), yy + lengthdir_y(radius - h, (360 * (i + 1)) / steps));
draw_vertex(xx + lengthdir_x(radius - h, (360 * i) / steps), yy + lengthdir_y(radius - h, (360 * i) / steps));
}
draw_primitive_end();
} (x, y, circle2radius, circle2width, 24); |
54 |
draw_set_alpha(1); |