1 |
spintimer++; |
2 |
if (spintimer == 20) |
3 |
spintimer = 0; |
4 |
if (spintimer == 0) |
5 |
sprite_index = spr_lancer_dt; |
6 |
else if (spintimer == 5) |
7 |
sprite_index = spr_lancer_lt; |
8 |
else if (spintimer == 10) |
9 |
sprite_index = spr_lancer_ut; |
10 |
else if (spintimer == 15) |
11 |
sprite_index = spr_lancer_rt; |
12 |
switch (mode) |
13 |
{ |
14 |
case 0: |
15 |
scr_fixedorbit((obj_heart.x + 8) - (sprite_width / 2), (obj_heart.y + 8) - (sprite_height / 2), (direction - 90) + 6, 50); |
16 |
direction += 6; |
17 |
break; |
18 |
case 1: |
19 |
scr_pivotoncenter(6); |
20 |
break; |
21 |
case 2: |
22 |
scr_rotatearoundpoint(obj_heart.x + 8, obj_heart.y + 8, 6); |
23 |
break; |
24 |
case 3: |
25 |
scr_orbitaroundpointscr_orbitaroundpointfunction scr_orbitaroundpoint(arg0, arg1, arg2)
{
var __theta = point_direction(arg0, arg1, x, y);
var __radius = point_distance(arg0, arg1, x, y);
__theta += arg2;
x = arg0 + lengthdir_x(__radius, __theta);
y = arg1 + lengthdir_y(__radius, __theta);
} ((obj_heart.x + 8) - (sprite_width / 2), (obj_heart.y + 8) - (sprite_height / 2), 6); |
26 |
break; |
27 |
} |
28 |
if (mode != 0) |
29 |
image_angle = direction; |