1 |
if (global.flag[17 Dalv fate] == 1) |
2 |
{ |
3 |
if ((keyboard_multicheck_pressed(0) && scr_interactscr_interactfunction scr_interact()
{
if (distance_to_object(obj_pl) < 20 && obj_pl.state == scr_normal_state)
{
var pl_dir = obj_pl.direction;
var pl_x = 0;
var pl_y = 0;
var check_distance_x = 0;
var check_distance_y = 0;
switch (pl_dir)
{
case 0:
pl_x = obj_pl.bbox_right;
pl_y = obj_pl.bbox_top + 1;
check_distance_x = 20;
break;
case 180:
pl_x = obj_pl.bbox_left;
pl_y = obj_pl.bbox_top + 1;
check_distance_x = -20;
break;
case 90:
pl_x = obj_pl.x;
pl_y = obj_pl.bbox_top;
check_distance_y = -20;
break;
case 270:
pl_x = obj_pl.x;
pl_y = obj_pl.bbox_bottom;
check_distance_y = 20;
break;
}
if (collision_line_first(pl_x, pl_y, pl_x + check_distance_x, pl_y + check_distance_y, id, false, false))
return true;
}
} () == true) && (waiter == 0 && !instance_exists(obj_dialogue))) |
4 |
waiter = 1; |
5 |
if (waiter == 1) |
6 |
{ |
7 |
global.cutscene = true; |
8 |
obj_dalv2.destination_x_dalv = obj_dalv2.x; |
9 |
obj_dalv2.destination_y_dalv = obj_dalv2.y; |
10 |
if (obj_dalv2.x == obj_dalv2.destination_x_dalv && obj_dalv2.y == obj_dalv2.destination_y_dalv) |
11 |
waiter++; |
12 |
} |
13 |
if (waiter == 2) |
14 |
image_index = 1; |
15 |
if (waiter == 2) |
16 |
{ |
17 |
scr_textscr_textfunction scr_text()
{
if (!instance_exists(obj_dialogue))
msg = instance_create(x, y, obj_dialogue);
} (); |
18 |
with (msg) |
19 |
{ |
20 |
if (global.interaction_count_flower_pot == 0) |
21 |
{ |
22 |
if (!instance_exists(obj_dialoguebox_dummy)) |
23 |
instance_create(0, 0, obj_dialoguebox_dummy); |
24 |
portrait = false; |
25 |
sndfnt = 99; |
26 |
message[0] = "* (It's a flower pot full of# dirt.)"; |
27 |
} |
28 |
else |
29 |
{ |
30 |
portrait = true; |
31 |
sndfnt = 100; |
32 |
message[0] = "* ..."; |
33 |
prt[0] = 1755; |
34 |
} |
35 |
} |
36 |
waiter++; |
37 |
} |
38 |
if (waiter == 3 && !instance_exists(obj_dialogue)) |
39 |
{ |
40 |
if (global.interaction_count_flower_pot == 0) |
41 |
{ |
42 |
obj_dalv2.direction = 0; |
43 |
global.interaction_count_flower_pot++; |
44 |
waiter++; |
45 |
} |
46 |
else |
47 |
{ |
48 |
waiter = 7; |
49 |
} |
50 |
} |
51 |
if (waiter == 4) |
52 |
{ |
53 |
scr_textscr_textfunction scr_text()
{
if (!instance_exists(obj_dialogue))
msg = instance_create(x, y, obj_dialogue);
} (); |
54 |
with (msg) |
55 |
{ |
56 |
portrait = true; |
57 |
sndfnt = 100; |
58 |
message[0] = "* That's my turnip plant!"; |
59 |
message[1] = "* He should be sprouting# up any day now!"; |
60 |
message[2] = "* ... He's really taking# his time..."; |
61 |
message[3] = "* But I don't rush him."; |
62 |
prt[0] = 1776; |
63 |
prt[1] = 1776; |
64 |
prt[2] = 1780; |
65 |
prt[3] = 1769; |
66 |
} |
67 |
waiter++; |
68 |
} |
69 |
if (waiter >= 5 && waiter <= 6 && !instance_exists(obj_dialogue)) |
70 |
{ |
71 |
obj_dalv2.destination_x_dalv = obj_dalv2.default_x_dalvshouse; |
72 |
obj_dalv2.destination_y_dalv = obj_dalv2.default_y_dalvshouse; |
73 |
if (obj_dalv2.x == obj_dalv2.default_x_dalvshouse && obj_dalv2.y == obj_dalv2.default_y_dalvshouse) |
74 |
waiter++; |
75 |
with (obj_dialoguebox_dummy) |
76 |
instance_destroy(); |
77 |
} |
78 |
if (waiter == 7) |
79 |
{ |
80 |
global.cutscene = false; |
81 |
waiter = 0; |
82 |
obj_pl.alarm[0] = 1; |
83 |
} |
84 |
} |
85 |
else if (global.flag[17 Dalv fate] != 1 && global.route != 3) |
86 |
{ |
87 |
if ((keyboard_multicheck_pressed(0) && scr_interactscr_interactfunction scr_interact()
{
if (distance_to_object(obj_pl) < 20 && obj_pl.state == scr_normal_state)
{
var pl_dir = obj_pl.direction;
var pl_x = 0;
var pl_y = 0;
var check_distance_x = 0;
var check_distance_y = 0;
switch (pl_dir)
{
case 0:
pl_x = obj_pl.bbox_right;
pl_y = obj_pl.bbox_top + 1;
check_distance_x = 20;
break;
case 180:
pl_x = obj_pl.bbox_left;
pl_y = obj_pl.bbox_top + 1;
check_distance_x = -20;
break;
case 90:
pl_x = obj_pl.x;
pl_y = obj_pl.bbox_top;
check_distance_y = -20;
break;
case 270:
pl_x = obj_pl.x;
pl_y = obj_pl.bbox_bottom;
check_distance_y = 20;
break;
}
if (collision_line_first(pl_x, pl_y, pl_x + check_distance_x, pl_y + check_distance_y, id, false, false))
return true;
}
} () == true) && (waiter == 0 && !instance_exists(obj_dialogue))) |
88 |
waiter = 1; |
89 |
if (waiter == 1) |
90 |
{ |
91 |
scr_textscr_textfunction scr_text()
{
if (!instance_exists(obj_dialogue))
msg = instance_create(x, y, obj_dialogue);
} (); |
92 |
with (msg) |
93 |
{ |
94 |
portrait = false; |
95 |
sndfnt = 99; |
96 |
message[0] = "* (It's a flower pot full of# dirt.)"; |
97 |
obj_flower_pot.waiter = 2; |
98 |
} |
99 |
} |
100 |
if (waiter == 2 && !instance_exists(obj_dialogue)) |
101 |
{ |
102 |
global.cutscene = false; |
103 |
waiter = 0; |
104 |
obj_pl.alarm[0] = 1; |
105 |
} |
106 |
} |
107 |
else if (global.route == 3) |
108 |
{ |
109 |
if ((keyboard_multicheck_pressed(0) && scr_interactscr_interactfunction scr_interact()
{
if (distance_to_object(obj_pl) < 20 && obj_pl.state == scr_normal_state)
{
var pl_dir = obj_pl.direction;
var pl_x = 0;
var pl_y = 0;
var check_distance_x = 0;
var check_distance_y = 0;
switch (pl_dir)
{
case 0:
pl_x = obj_pl.bbox_right;
pl_y = obj_pl.bbox_top + 1;
check_distance_x = 20;
break;
case 180:
pl_x = obj_pl.bbox_left;
pl_y = obj_pl.bbox_top + 1;
check_distance_x = -20;
break;
case 90:
pl_x = obj_pl.x;
pl_y = obj_pl.bbox_top;
check_distance_y = -20;
break;
case 270:
pl_x = obj_pl.x;
pl_y = obj_pl.bbox_bottom;
check_distance_y = 20;
break;
}
if (collision_line_first(pl_x, pl_y, pl_x + check_distance_x, pl_y + check_distance_y, id, false, false))
return true;
}
} () == true) && (waiter == 0 && !instance_exists(obj_dialogue))) |
110 |
waiter = 1; |
111 |
if (waiter == 1) |
112 |
{ |
113 |
scr_textscr_textfunction scr_text()
{
if (!instance_exists(obj_dialogue))
msg = instance_create(x, y, obj_dialogue);
} (); |
114 |
with (msg) |
115 |
{ |
116 |
portrait = false; |
117 |
sndfnt = 99; |
118 |
message[0] = "* (Dirt.)"; |
119 |
obj_flower_pot.waiter = 2; |
120 |
} |
121 |
} |
122 |
if (waiter == 2 && !instance_exists(obj_dialogue)) |
123 |
{ |
124 |
global.cutscene = false; |
125 |
waiter = 0; |
126 |
obj_pl.alarm[0] = 1; |
127 |
} |
128 |
} |