1 |
if (!instance_exists(obj_martlet_body)) |
2 |
{ |
3 |
instance_destroy(); |
4 |
exit; |
5 |
} |
6 |
if (obj_martlet_body.animating == true) |
7 |
{ |
8 |
x = obj_martlet_body.x; |
9 |
y = obj_martlet_body.head_displacement_y; |
10 |
} |
11 |
else |
12 |
{ |
13 |
x = starting_point_x; |
14 |
y = starting_point_y; |
15 |
} |
16 |
var text_parent; |
17 |
if (instance_exists(obj_quote_defeat_parent)) |
18 |
text_parent = 2961; |
19 |
else |
20 |
text_parent = 2622; |
21 |
if (instance_exists(text_parent) && instance_exists(obj_quote_bubble_battle)) |
22 |
{ |
23 |
if (sprite_index != text_parent.portrait_head[text_parent.message_current]) |
24 |
sprite_index = text_parent.portrait_head[text_parent.message_current]; |
25 |
} |
26 |
else |
27 |
{ |
28 |
sprite_index = head_sprite; |
29 |
} |
30 |
if (instance_exists(text_parent) && instance_exists(obj_quote_bubble_battle)) |
31 |
{ |
32 |
if (text_parent.can_talk == true) |
33 |
{ |
34 |
if (can_talk_no_loop == false) |
35 |
{ |
36 |
image_index = 1; |
37 |
can_talk_no_loop = true; |
38 |
} |
39 |
image_speed = global.text_speed * global.talk_speed_martlet * text_parent.hold; |
40 |
} |
41 |
else |
42 |
{ |
43 |
can_talk_no_loop = false; |
44 |
image_speed = 0; |
45 |
image_index = 0; |
46 |
} |
47 |
} |
48 |
else |
49 |
{ |
50 |
can_talk_no_loop = false; |
51 |
image_speed = 0; |
52 |
image_index = 0; |
53 |
} |
54 |
with (obj_martlet_head_shadow) |
55 |
event_user(0); |