1 |
if (global.flag[17 Dalv fate] == 1) |
2 |
{ |
3 |
if (keyboard_multicheck_pressed(0) && scr_interactscr_interactfunction scr_interact() //gml_Script_scr_interact
{
if (distance_to_object(obj_pl) < 20 && obj_pl.state == gml_Script_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 |
{ |
15 |
scr_textscr_textfunction scr_text() //gml_Script_scr_text
{
if (!instance_exists(obj_dialogue))
msg = instance_create(x, y, obj_dialogue)
} () |
16 |
with (msg) |
17 |
{ |
18 |
if (global.interaction_count_painting == 0) |
19 |
{ |
20 |
portrait = true |
21 |
sndfnt = 100 |
22 |
message[0] = "* Someone made that for me# a while back." |
23 |
message[1] = "* It's a single corn from# the corn field out in# the Ruins." |
24 |
message[2] = "* I started that field# from one piece of corn." |
25 |
message[3] = "* Before I closed off the# door to Snowdin,# something happened." |
26 |
message[4] = "* I kept finding corn# sitting on my doorstep." |
27 |
message[5] = "* Every morning it was# just, there." |
28 |
message[6] = "* I didn't know who was# leaving it but..." |
29 |
message[7] = "* Somehow I thought they# were my friend." |
30 |
message[8] = "* I always wanted to repay# their kind deeds but..." |
31 |
message[9] = "* I never could think of# anything to leave in# return." |
32 |
message[10] = "* And one day they just# stopped showing up." |
33 |
message[11] = "* That's when I decided to# hide away." |
34 |
message[12] = "* But I planted the last# cob of corn I had down# here." |
35 |
message[13] = "* It's taken to the# environment surprisingly# well." |
36 |
message[14] = "* I always found it rather# inspiring." |
37 |
prt[0] = 1769 |
38 |
prt[1] = 1769 |
39 |
prt[2] = 1776 |
40 |
prt[3] = 1755 |
41 |
prt[4] = 1755 |
42 |
prt[5] = 1755 |
43 |
prt[6] = 1755 |
44 |
prt[7] = 1769 |
45 |
prt[8] = 1755 |
46 |
prt[9] = 1780 |
47 |
prt[10] = 1763 |
48 |
prt[11] = 1759 |
49 |
prt[12] = 1776 |
50 |
prt[13] = 1776 |
51 |
prt[14] = 1769 |
52 |
} |
53 |
else |
54 |
{ |
55 |
portrait = true |
56 |
sndfnt = 100 |
57 |
message[0] = "* ..." |
58 |
prt[0] = 1755 |
59 |
} |
60 |
} |
61 |
waiter++ |
62 |
} |
63 |
if (waiter == 3 && (!instance_exists(obj_dialogue))) |
64 |
{ |
65 |
if (global.interaction_count_painting == 0) |
66 |
{ |
67 |
global.interaction_count_painting++ |
68 |
waiter++ |
69 |
} |
70 |
else |
71 |
waiter = 4 |
72 |
} |
73 |
if (waiter >= 4 && waiter <= 5 && (!instance_exists(obj_dialogue))) |
74 |
{ |
75 |
obj_dalv2.destination_x_dalv = obj_dalv2.default_x_dalvroomhall |
76 |
obj_dalv2.destination_y_dalv = obj_dalv2.default_y_dalvroomhall |
77 |
if (obj_dalv2.x == obj_dalv2.default_x_dalvroomhall && obj_dalv2.y == obj_dalv2.default_y_dalvroomhall) |
78 |
waiter++ |
79 |
} |
80 |
if (waiter == 6) |
81 |
{ |
82 |
global.cutscene = false |
83 |
waiter = 0 |
84 |
obj_pl.alarm[0] = 1 |
85 |
} |
86 |
} |
87 |
else if (global.flag[17 Dalv fate] != 1 && global.route != 3) |
88 |
{ |
89 |
if (keyboard_multicheck_pressed(0) && scr_interactscr_interactfunction scr_interact() //gml_Script_scr_interact
{
if (distance_to_object(obj_pl) < 20 && obj_pl.state == gml_Script_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))) |
90 |
waiter = 1 |
91 |
if (waiter == 1) |
92 |
{ |
93 |
scr_textscr_textfunction scr_text() //gml_Script_scr_text
{
if (!instance_exists(obj_dialogue))
msg = instance_create(x, y, obj_dialogue)
} () |
94 |
with (msg) |
95 |
{ |
96 |
portrait = false |
97 |
sndfnt = 99 |
98 |
message[0] = "* (It's a nice painting of a# small, lonely cob.)" |
99 |
message[1] = "* (A signature that reads# \"Penilla\", is written in the# corner.)" |
100 |
obj_painting.waiter = 2 |
101 |
} |
102 |
} |
103 |
if (waiter == 2 && (!instance_exists(obj_dialogue))) |
104 |
{ |
105 |
global.cutscene = false |
106 |
waiter = 0 |
107 |
obj_pl.alarm[0] = 1 |
108 |
} |
109 |
} |
110 |
else if (global.route == 3) |
111 |
{ |
112 |
if (keyboard_multicheck_pressed(0) && scr_interactscr_interactfunction scr_interact() //gml_Script_scr_interact
{
if (distance_to_object(obj_pl) < 20 && obj_pl.state == gml_Script_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))) |
113 |
waiter = 1 |
114 |
if (waiter == 1) |
115 |
{ |
116 |
scr_textscr_textfunction scr_text() //gml_Script_scr_text
{
if (!instance_exists(obj_dialogue))
msg = instance_create(x, y, obj_dialogue)
} () |
117 |
with (msg) |
118 |
{ |
119 |
portrait = false |
120 |
sndfnt = 99 |
121 |
message[0] = "* (A painting.)" |
122 |
message[1] = "* (It's lacking corn realism.)" |
123 |
obj_painting.waiter = 2 |
124 |
} |
125 |
} |
126 |
if (waiter == 2 && (!instance_exists(obj_dialogue))) |
127 |
{ |
128 |
global.cutscene = false |
129 |
waiter = 0 |
130 |
obj_pl.alarm[0] = 1 |
131 |
} |
132 |
} |