1 |
if (launched == false) |
2 |
{ |
3 |
x += lengthdir_x(prep_speed, image_angle); |
4 |
y += lengthdir_y(prep_speed, image_angle); |
5 |
} |
6 |
else |
7 |
{ |
8 |
if (move == true) |
9 |
{ |
10 |
for (i = 0; i < attack_mult; i++) |
11 |
{ |
12 |
x += lengthdir_x(attack_speed, image_angle); |
13 |
y += lengthdir_y(attack_speed, image_angle); |
14 |
if (place_meeting(x, y, obj_attack_boundary_box)) |
15 |
{ |
16 |
move = false; |
17 |
alarm[0] = fade_alarm; |
18 |
break; |
19 |
} |
20 |
} |
21 |
} |
22 |
if (fade == true) |
23 |
{ |
24 |
if (image_alpha > 0) |
25 |
{ |
26 |
image_alpha -= 0.1; |
27 |
if (image_alpha <= 0) |
28 |
instance_destroy(); |
29 |
} |
30 |
} |
31 |
} |