Undertale Yellow script viewer

← back to main script listing

gml_Object_obj_dalv3_Step_0

(view raw script w/o annotations or w/e)
1
script_execute(gml_Script_scr_depth, 0, 0, 0, 0, 0)
2
if (global.route == 2 && global.flag[21 Hurt Dalv during battle?] == false)
3
{
4
    if (waiter == 1)
5
    {
6
        scr_text
scr_text

function scr_text() //gml_Script_scr_text { if (!instance_exists(obj_dialogue)) msg = instance_create(x, y, obj_dialogue) }
()
7
        with (msg)
8
        {
9
            portrait = true
10
            sndfnt = 100
11
            message[0] = "* Well, here we are."
12
            message[1] = "* Thank you..."
13
            message[2] = "* For everything."
14
            message[3] = "* You have really helped#  me out."
15
            message[4] = "* Because of this..."
16
            message[5] = "* I'm leaving this place."
17
            message[6] = "* I'm tired of being#  alone."
18
            message[7] = "* It'll take a few days to#  pack up..."
19
            message[8] = "* But I think I'm ready to#  give the Underground#  another shot."
20
            message[9] = "* I have so much#  creativity I've been#  storing up."
21
            message[10] = "* I'm finally ready to let#  my talents show."
22
            message[11] = "* I can publish my novel,#  have an organ concert,"
23
            message[12] = "* I might even make#  another friend!"
24
            message[13] = "* What a world it would be#  if I had two whole#  friends."
25
            message[14] = "* I'll go around and place#  corn on every doorstep."
26
            message[15] = "* Everyone needs a little#  corn in their life."
27
            message[16] = "* I've eaten corn every#  day for a year and I'm#  doing moderately OK."
28
            message[17] = "* So much to learn, so#  much to teach. I'm very#  excited!"
29
            message[18] = "* Oops. There I go again#  with my rambling."
30
            message[19] = "* Let's get you out of#  here."
31
            message[20] = "* Oh..."
32
            message[21] = "* It seems the exit is#  blocked off..."
33
            message[22] = "* Let's see."
34
            prt[0] = 1755
35
            prt[1] = 1769
36
            prt[2] = 1769
37
            prt[3] = 1769
38
            prt[4] = 1780
39
            prt[5] = 1776
40
            prt[6] = 1763
41
            prt[7] = 1780
42
            prt[8] = 1776
43
            prt[9] = 1761
44
            prt[10] = 1769
45
            prt[11] = 1769
46
            prt[12] = 1761
47
            prt[13] = 1761
48
            prt[14] = 1769
49
            prt[15] = 1769
50
            prt[16] = 1776
51
            prt[17] = 1769
52
            prt[18] = 1768
53
            prt[19] = 1776
54
            prt[20] = 1755
55
            prt[21] = 1755
56
            prt[22] = 1755
57
        }
58
        waiter++
59
    }
60
    if (waiter == 2 && instance_exists(obj_dialogue))
61
    {
62
        if (msg.message_current == 20)
63
            direction = 90
64
        else
65
            direction = 270
66
    }
67
    if (waiter == 2 && (!instance_exists(obj_dialogue)))
68
    {
69
        direction = 90
70
        if (y > 80)
71
        {
72
            npc_walking = true
73
            y -= 2
74
            if (y < 80)
75
                y = 80
76
        }
77
        if (y == 80)
78
        {
79
            npc_walking = false
80
            waiter++
81
        }
82
    }
83
    if (waiter == 3 && sprite_index != spr_dalv_npc_boards_pacifist)
84
    {
85
        if (no_loop_sound == false)
86
        {
87
            audio_play_sound(snd_wood_pull, 1, 0)
88
            no_loop_sound = true
89
        }
90
        sprite_index = spr_dalv_npc_boards_pacifist
91
        image_speed = (1/3)
92
        image_index = 0
93
    }
94
    if (waiter == 4)
95
    {
96
        direction = 270
97
        sprite_index = cdalv_down
98
        y += 21
99
        scr_text
scr_text

function scr_text() //gml_Script_scr_text { if (!instance_exists(obj_dialogue)) msg = instance_create(x, y, obj_dialogue) }
()
100
        with (msg)
101
        {
102
            portrait = true
103
            sndfnt = 100
104
            ch_msg = 2
105
            ch[1] = "Clover"
106
            message[0] = "* There we go. You're all#  set."
107
            message[1] = "* Oh, before I forget,#  I never asked for#  your name!"
108
            message[2] = "* Mind informing me?"
109
            message[3] = "* Clover? What a nice name."
110
            message[4] = "* Well, Clover, thank you#  so much."
111
            message[5] = "* See you later..."
112
            message[6] = "* Friend."
113
            prt[0] = 1776
114
            prt[1] = 1769
115
            prt[2] = 1776
116
            prt[3] = 1769
117
            prt[4] = 1776
118
            prt[5] = 1769
119
            prt[6] = 1773
120
        }
121
        waiter++
122
    }
123
    if (waiter == 5 && (!instance_exists(obj_dialogue)))
124
    {
125
        spritelock = true
126
        if (x != 160 || y != 170)
127
            scr_walk_ai
scr_walk_ai

function scr_walk_ai(argument0, argument1, argument2, argument3, argument4) //gml_Script_scr_walk_ai { dalv_walk_speed = argument3 condition_1 = false if (no_loop_destination_dalv == false) { var destination_x = abs(x - argument0) var destination_y = abs(y - argument1) var axis_override = argument4 if (axis_override == "x" || axis_override == "y") dalv_walk_axis = axis_override else { var result = sign(destination_x - destination_y) switch result { case 1: dalv_walk_axis = "x" break case -1: dalv_walk_axis = "y" break default: dalv_walk_axis = "y" } } dalv_walk_speed_x = (sign(argument0 - x)) * dalv_walk_speed dalv_walk_speed_y = (sign(argument1 - y)) * dalv_walk_speed no_loop_destination_dalv = true } if (x == argument0 && y == argument1) { npc_walking = false path_speed = 0 image_speed = 0 image_index = 0 return; } switch dalv_walk_axis { case "x": x_previous = x x += dalv_walk_speed_x if (abs(argument0 - x) < dalv_walk_speed && place_free(argument0, y) && (!(place_meeting(argument0, y, argument2)))) x = argument0 if (place_free(x, y) && (!(place_meeting(x, y, argument2))) && x_previous != argument0) { npc_walking = true image_speed = 0.2 if (dalv_walk_speed_x == (-dalv_walk_speed)) direction = 180 else if (dalv_walk_speed_x == dalv_walk_speed) direction = 0 } if ((!(place_free(x, y))) || place_meeting(x, y, argument2) || x_previous == argument0) { x = x_previous dalv_walk_axis = "y" return; } dalv_walk_speed_y = (sign(argument1 - y)) * dalv_walk_speed i = x + dalv_walk_speed_x j = y if (abs(argument0 - i) < dalv_walk_speed) i = argument0 while (j != argument1) { j += dalv_walk_speed_y if (abs(argument1 - j) < dalv_walk_speed) j = argument1 if ((!(place_free(i, j))) || place_meeting(i, j, argument2)) { condition_1 = true break } else continue } if (condition_1 == true) { while (i != argument0) { i += dalv_walk_speed_x j = y if (abs(argument0 - i) < dalv_walk_speed) i = argument0 while (j != argument1) { j += dalv_walk_speed_y if (abs(argument1 - j) < dalv_walk_speed) j = argument1 if (i == argument0 && j == argument1) return; else if ((!(place_free(i, j))) || place_meeting(i, j, argument2)) break else { if (j == argument1) return; continue ...
(160, 170, obj_pl, 2, 0)
128
        with (obj_pl)
129
        {
130
            if (distance_to_object(obj_dalv3) <= 20 && obj_dalv3.no_loop_autowalk == false)
131
            {
132
                clover_walk_backwards = true
133
                autowalk_direction = "left"
134
                state = gml_Script_scr_autowalk_state
135
               alarm[1]
136
                obj_dalv3.no_loop_autowalk = true
137
            }
138
        }
139
        if (x == 160 && y == 170)
140
        {
141
            npc_walking = false
142
            image_speed = 0
143
            image_index = 0
144
            fadeout = true
145
            if (image_alpha <= 0.2)
146
            {
147
                instance_create(144, 188, obj_dalvExit_blocker)
148
                waiter++
149
            }
150
        }
151
    }
152
    if (waiter == 6)
153
    {
154
        global.flag[29 Dalv board destruction cutscene] = 1
155
        global.cutscene = false
156
        waiter = 0
157
        with (obj_pl)
158
        {
159
            autowalk_direction = "right"
160
            state = gml_Script_scr_autowalk_state
161
           alarm[1]
162
        }
163
    }
164
}
165
else if (global.route == 2 && global.flag[21 Hurt Dalv during battle?] == true)
166
{
167
    if (waiter == 1)
168
    {
169
        scr_text
scr_text

function scr_text() //gml_Script_scr_text { if (!instance_exists(obj_dialogue)) msg = instance_create(x, y, obj_dialogue) }
()
170
        with (msg)
171
        {
172
            portrait = true
173
            sndfnt = 100
174
            message[0] = "* Well, here we are."
175
            message[1] = "* I should thank you..."
176
            message[2] = "* For helping me out#  so much."
177
            message[3] = "* Because of this..."
178
            message[4] = "* I'm leaving this place."
179
            message[5] = "* I'm tired of being#  alone."
180
            message[6] = "* It'll take a few days to#  pack up..."
181
            message[7] = "* But I think I'm ready to#  give the Underground#  another shot."
182
            message[8] = "* I suppose I should get#  you out of here but..."
183
            message[9] = "* Honestly, you confuse me."
184
            message[10] = "* You hurt me but yet, you#  gave me freedom."
185
            message[11] = "* Is that what real#  friends do?"
186
            message[12] = "* If so I don't know if I#  really want to leave."
187
            message[13] = "* If everyone will hurt me#  then help me..."
188
            message[14] = "* Is that a place I want#  to be?"
189
            message[15] = "* Well... I can't let this#  opportunity pass."
190
            message[16] = "* It's ok, I forgive you."
191
            message[17] = "* You probably were scared#  by me..."
192
            message[18] = "* Most monsters are..."
193
            message[19] = "* ..."
194
            message[20] = "* It seems the exit is#  blocked off..."
195
            message[21] = "* I'll deal with it."
196
            prt[0] = 1755
197
            prt[1] = 1769
198
            prt[2] = 1769
199
            prt[3] = 1780
200
            prt[4] = 1759
201
            prt[5] = 1763
202
            prt[6] = 1780
203
            prt[7] = 1776
204
            prt[8] = 1755
205
            prt[9] = 1763
206
            prt[10] = 1768
207
            prt[11] = 1768
208
            prt[12] = 1763
209
            prt[13] = 1763
210
            prt[14] = 1780
211
            prt[15] = 1759
212
            prt[16] = 1776
213
            prt[17] = 1755
214
            prt[18] = 1780
215
            prt[19] = 1755
216
            prt[20] = 1763
217
            prt[21] = 1755
218
        }
219
        waiter++
220
    }
221
    if (waiter == 2 && instance_exists(obj_dialogue))
222
    {
223
        if (msg.message_current == 19)
224
            direction = 90
225
        else
226
            direction = 270
227
    }
228
    if (waiter == 2 && (!instance_exists(obj_dialogue)))
229
        waiter++
230
    if (waiter == 3 && sprite_index != spr_dalv_npc_boards_neutral)
231
    {
232
        if (no_loop_sound == false)
233
        {
234
            audio_play_sound(snd_wood_zap, 1, 0)
235
            no_loop_sound = true
236
        }
237
        sprite_index = spr_dalv_npc_boards_neutral
238
        image_speed = (1/3)
239
        image_index = 0
240
    }
241
    if (waiter == 4)
242
    {
243
        direction = 270
244
        sprite_index = cdalv_down
245
        scr_text
scr_text

function scr_text() //gml_Script_scr_text { if (!instance_exists(obj_dialogue)) msg = instance_create(x, y, obj_dialogue) }
()
246
        with (msg)
247
        {
248
            portrait = true
249
            sndfnt = 100
250
            ch_msg = 2
251
            ch[1] = "Clover"
252
            message[0] = "* There we go. You're all#  set."
253
            message[1] = "* Oh, before I forget,#  I never asked for#  your name."
254
            message[2] = "* Mind informing me?"
255
            message[3] = "* Clover? What a nice name."
256
            message[4] = "* Well, Clover, you should#  get going."
257
            message[5] = "* See you later..."
258
            message[6] = "* Friend."
259
            prt[0] = 1776
260
            prt[1] = 1769
261
            prt[2] = 1776
262
            prt[3] = 1769
263
            prt[4] = 1776
264
            prt[5] = 1769
265
            prt[6] = 1773
266
        }
267
        waiter++
268
    }
269
    if (waiter == 5 && (!instance_exists(obj_dialogue)))
270
    {
271
        spritelock = true
272
        if (x != 160 || y != 170)
273
            scr_walk_ai
scr_walk_ai

function scr_walk_ai(argument0, argument1, argument2, argument3, argument4) //gml_Script_scr_walk_ai { dalv_walk_speed = argument3 condition_1 = false if (no_loop_destination_dalv == false) { var destination_x = abs(x - argument0) var destination_y = abs(y - argument1) var axis_override = argument4 if (axis_override == "x" || axis_override == "y") dalv_walk_axis = axis_override else { var result = sign(destination_x - destination_y) switch result { case 1: dalv_walk_axis = "x" break case -1: dalv_walk_axis = "y" break default: dalv_walk_axis = "y" } } dalv_walk_speed_x = (sign(argument0 - x)) * dalv_walk_speed dalv_walk_speed_y = (sign(argument1 - y)) * dalv_walk_speed no_loop_destination_dalv = true } if (x == argument0 && y == argument1) { npc_walking = false path_speed = 0 image_speed = 0 image_index = 0 return; } switch dalv_walk_axis { case "x": x_previous = x x += dalv_walk_speed_x if (abs(argument0 - x) < dalv_walk_speed && place_free(argument0, y) && (!(place_meeting(argument0, y, argument2)))) x = argument0 if (place_free(x, y) && (!(place_meeting(x, y, argument2))) && x_previous != argument0) { npc_walking = true image_speed = 0.2 if (dalv_walk_speed_x == (-dalv_walk_speed)) direction = 180 else if (dalv_walk_speed_x == dalv_walk_speed) direction = 0 } if ((!(place_free(x, y))) || place_meeting(x, y, argument2) || x_previous == argument0) { x = x_previous dalv_walk_axis = "y" return; } dalv_walk_speed_y = (sign(argument1 - y)) * dalv_walk_speed i = x + dalv_walk_speed_x j = y if (abs(argument0 - i) < dalv_walk_speed) i = argument0 while (j != argument1) { j += dalv_walk_speed_y if (abs(argument1 - j) < dalv_walk_speed) j = argument1 if ((!(place_free(i, j))) || place_meeting(i, j, argument2)) { condition_1 = true break } else continue } if (condition_1 == true) { while (i != argument0) { i += dalv_walk_speed_x j = y if (abs(argument0 - i) < dalv_walk_speed) i = argument0 while (j != argument1) { j += dalv_walk_speed_y if (abs(argument1 - j) < dalv_walk_speed) j = argument1 if (i == argument0 && j == argument1) return; else if ((!(place_free(i, j))) || place_meeting(i, j, argument2)) break else { if (j == argument1) return; continue ...
(160, 170, obj_pl, 2, 0)
274
        with (obj_pl)
275
        {
276
            if (distance_to_object(obj_dalv3) <= 20 && obj_dalv3.no_loop_autowalk == false)
277
            {
278
                clover_walk_backwards = true
279
                autowalk_direction = "left"
280
                state = gml_Script_scr_autowalk_state
281
               alarm[1]
282
                obj_dalv3.no_loop_autowalk = true
283
            }
284
        }
285
        if (x == 160 && y == 170)
286
        {
287
            npc_walking = false
288
            image_speed = 0
289
            image_index = 0
290
            fadeout = true
291
            if (image_alpha <= 0.2)
292
            {
293
                instance_create(144, 188, obj_dalvExit_blocker)
294
                waiter++
295
            }
296
        }
297
    }
298
    if (waiter == 6)
299
    {
300
        global.flag[29 Dalv board destruction cutscene] = 1
301
        global.cutscene = false
302
        waiter = 0
303
        with (obj_pl)
304
        {
305
            autowalk_direction = "right"
306
            state = gml_Script_scr_autowalk_state
307
           alarm[1]
308
        }
309
    }
310
}
311
else if (global.route == 1 && global.flag[21 Hurt Dalv during battle?] == false)
312
{
313
    if (waiter == 1)
314
    {
315
        scr_text
scr_text

function scr_text() //gml_Script_scr_text { if (!instance_exists(obj_dialogue)) msg = instance_create(x, y, obj_dialogue) }
()
316
        with (msg)
317
        {
318
            portrait = true
319
            sndfnt = 100
320
            message[0] = "* Well, here we are."
321
            message[1] = "* Thank you..."
322
            message[2] = "* For everything."
323
            message[3] = "* You have really helped#  me out."
324
            message[4] = "* Because of this..."
325
            message[5] = "* I'm going to be more#  friendly."
326
            message[6] = "* I'm gonna be the mentor#  I always should have#  been."
327
            message[7] = "* Penilla and I will draw#  together,"
328
            message[8] = "* Rorrim could spice up my#  wardrobe,"
329
            message[9] = "* And Crispy Scroll can#  show me that \"anime\"#  thing."
330
            message[10] = "* I thought of leaving..."
331
            message[11] = "* But why leave when I#  have a great family#  right here?"
332
            message[12] = "* Plus I've really let the#  place go."
333
            message[13] = "* A week of non-stop#  cleaning is in order!"
334
            message[14] = "* ..."
335
            message[15] = "* Well... I should get you#  out of here."
336
            message[16] = "* Oh..."
337
            message[17] = "* It seems the exit is#  blocked off..."
338
            message[18] = "* Let's see."
339
            prt[0] = 1755
340
            prt[1] = 1776
341
            prt[2] = 1769
342
            prt[3] = 1769
343
            prt[4] = 1769
344
            prt[5] = 1769
345
            prt[6] = 1769
346
            prt[7] = 1761
347
            prt[8] = 1761
348
            prt[9] = 1761
349
            prt[10] = 1780
350
            prt[11] = 1776
351
            prt[12] = 1763
352
            prt[13] = 1759
353
            prt[14] = 1780
354
            prt[15] = 1755
355
            prt[16] = 1768
356
            prt[17] = 1763
357
            prt[18] = 1755
358
        }
359
        waiter++
360
    }
361
    if (waiter == 2 && instance_exists(obj_dialogue))
362
    {
363
        if (msg.message_current == 16)
364
            direction = 90
365
        else
366
            direction = 270
367
    }
368
    if (waiter == 2 && (!instance_exists(obj_dialogue)))
369
    {
370
        direction = 90
371
        if (y > 80)
372
        {
373
            npc_walking = true
374
            y -= 3
375
            if (y < 80)
376
                y = 80
377
        }
378
        if (y == 80)
379
        {
380
            npc_walking = false
381
            waiter++
382
        }
383
    }
384
    if (waiter == 3 && sprite_index != spr_dalv_npc_boards_pacifist)
385
    {
386
        if (no_loop_sound == false)
387
        {
388
            audio_play_sound(snd_wood_pull, 1, 0)
389
            no_loop_sound = true
390
        }
391
        sprite_index = spr_dalv_npc_boards_pacifist
392
        image_speed = (1/3)
393
        image_index = 0
394
    }
395
    if (waiter == 4)
396
    {
397
        direction = 270
398
        sprite_index = cdalv_down
399
        y += 21
400
        scr_text
scr_text

function scr_text() //gml_Script_scr_text { if (!instance_exists(obj_dialogue)) msg = instance_create(x, y, obj_dialogue) }
()
401
        with (msg)
402
        {
403
            ch_msg = 2
404
            ch[1] = "Clover"
405
            portrait = true
406
            sndfnt = 100
407
            message[0] = "* There we go. You're all#  set."
408
            message[1] = "* Oh, before I forget,#  I never asked for#  your name."
409
            message[2] = "* Mind informing me?"
410
            message[3] = "* Clover? What a nice name."
411
            message[4] = "* Well, Clover, you should#  get going."
412
            message[5] = "* Goodbye..."
413
            message[6] = "* Friend."
414
            prt[0] = 1776
415
            prt[1] = 1769
416
            prt[2] = 1776
417
            prt[3] = 1769
418
            prt[4] = 1776
419
            prt[5] = 1769
420
            prt[6] = 1773
421
        }
422
        waiter++
423
    }
424
    if (waiter == 5 && (!instance_exists(obj_dialogue)))
425
    {
426
        spritelock = true
427
        if (x != 160 || y != 170)
428
            scr_walk_ai
scr_walk_ai

function scr_walk_ai(argument0, argument1, argument2, argument3, argument4) //gml_Script_scr_walk_ai { dalv_walk_speed = argument3 condition_1 = false if (no_loop_destination_dalv == false) { var destination_x = abs(x - argument0) var destination_y = abs(y - argument1) var axis_override = argument4 if (axis_override == "x" || axis_override == "y") dalv_walk_axis = axis_override else { var result = sign(destination_x - destination_y) switch result { case 1: dalv_walk_axis = "x" break case -1: dalv_walk_axis = "y" break default: dalv_walk_axis = "y" } } dalv_walk_speed_x = (sign(argument0 - x)) * dalv_walk_speed dalv_walk_speed_y = (sign(argument1 - y)) * dalv_walk_speed no_loop_destination_dalv = true } if (x == argument0 && y == argument1) { npc_walking = false path_speed = 0 image_speed = 0 image_index = 0 return; } switch dalv_walk_axis { case "x": x_previous = x x += dalv_walk_speed_x if (abs(argument0 - x) < dalv_walk_speed && place_free(argument0, y) && (!(place_meeting(argument0, y, argument2)))) x = argument0 if (place_free(x, y) && (!(place_meeting(x, y, argument2))) && x_previous != argument0) { npc_walking = true image_speed = 0.2 if (dalv_walk_speed_x == (-dalv_walk_speed)) direction = 180 else if (dalv_walk_speed_x == dalv_walk_speed) direction = 0 } if ((!(place_free(x, y))) || place_meeting(x, y, argument2) || x_previous == argument0) { x = x_previous dalv_walk_axis = "y" return; } dalv_walk_speed_y = (sign(argument1 - y)) * dalv_walk_speed i = x + dalv_walk_speed_x j = y if (abs(argument0 - i) < dalv_walk_speed) i = argument0 while (j != argument1) { j += dalv_walk_speed_y if (abs(argument1 - j) < dalv_walk_speed) j = argument1 if ((!(place_free(i, j))) || place_meeting(i, j, argument2)) { condition_1 = true break } else continue } if (condition_1 == true) { while (i != argument0) { i += dalv_walk_speed_x j = y if (abs(argument0 - i) < dalv_walk_speed) i = argument0 while (j != argument1) { j += dalv_walk_speed_y if (abs(argument1 - j) < dalv_walk_speed) j = argument1 if (i == argument0 && j == argument1) return; else if ((!(place_free(i, j))) || place_meeting(i, j, argument2)) break else { if (j == argument1) return; continue ...
(160, 170, obj_pl, 3, 0)
429
        with (obj_pl)
430
        {
431
            if (distance_to_object(obj_dalv3) <= 20 && obj_dalv3.no_loop_autowalk == false)
432
            {
433
                clover_walk_backwards = true
434
                autowalk_direction = "left"
435
                state = gml_Script_scr_autowalk_state
436
               alarm[1]
437
                obj_dalv3.no_loop_autowalk = true
438
            }
439
        }
440
        if (x == 160 && y == 170)
441
        {
442
            npc_walking = false
443
            image_speed = 0
444
            image_index = 0
445
            fadeout = true
446
            if (image_alpha <= 0.2)
447
            {
448
                instance_create(144, 188, obj_dalvExit_blocker)
449
                waiter++
450
            }
451
        }
452
    }
453
    if (waiter == 6)
454
    {
455
        global.flag[29 Dalv board destruction cutscene] = 2
456
        global.cutscene = false
457
        waiter = 0
458
        with (obj_pl)
459
        {
460
            autowalk_direction = "right"
461
            state = gml_Script_scr_autowalk_state
462
           alarm[1]
463
        }
464
    }
465
}
466
else if (global.route == 1 && global.flag[21 Hurt Dalv during battle?] == true)
467
{
468
    if (waiter == 1)
469
    {
470
        scr_text
scr_text

function scr_text() //gml_Script_scr_text { if (!instance_exists(obj_dialogue)) msg = instance_create(x, y, obj_dialogue) }
()
471
        with (msg)
472
        {
473
            portrait = true
474
            sndfnt = 100
475
            message[0] = "* Well, here we are."
476
            message[1] = "* I should thank you..."
477
            message[2] = "* You have really helped#  me out."
478
            message[3] = "* Because of this..."
479
            message[4] = "* I'm going to be friendly#  to everyone."
480
            message[5] = "* ..."
481
            message[6] = "* I suppose I should get#  you out of here but..."
482
            message[7] = "* Honestly, you confuse me."
483
            message[8] = "* You hurt me but yet, you#  opened my eyes."
484
            message[9] = "* Is that what real#  friends do?"
485
            message[10] = "* I would leave but..."
486
            message[11] = "* If everyone outside will#  hurt me then help me..."
487
            message[12] = "* Is that a place I want#  to be?"
488
            message[13] = "* No."
489
            message[14] = "* I've lived here for a#  long time."
490
            message[15] = "* It's comfortable and I#  know the residents."
491
            message[16] = "* The unknown is a scary#  place..."
492
            message[17] = "* I'm not ready for it..."
493
            message[18] = "* Not yet at least."
494
            message[19] = "* The monsters here need#  someone to look up to."
495
            message[20] = "* I could make them happy."
496
            message[21] = "* ..."
497
            message[22] = "* Well, anyway. It seems#  the exit is blocked#  off..."
498
            message[23] = "* I'll deal with it."
499
            prt[0] = 1755
500
            prt[1] = 1769
501
            prt[2] = 1769
502
            prt[3] = 1769
503
            prt[4] = 1769
504
            prt[5] = 1755
505
            prt[6] = 1780
506
            prt[7] = 1763
507
            prt[8] = 1763
508
            prt[9] = 1763
509
            prt[10] = 1780
510
            prt[11] = 1763
511
            prt[12] = 1763
512
            prt[13] = 1759
513
            prt[14] = 1755
514
            prt[15] = 1769
515
            prt[16] = 1763
516
            prt[17] = 1764
517
            prt[18] = 1768
518
            prt[19] = 1776
519
            prt[20] = 1769
520
            prt[21] = 1780
521
            prt[22] = 1755
522
            prt[23] = 1755
523
        }
524
        waiter++
525
    }
526
    if (waiter == 2 && instance_exists(obj_dialogue))
527
    {
528
        if (msg.message_current == 21)
529
            direction = 90
530
        else
531
            direction = 270
532
    }
533
    if (waiter == 2 && (!instance_exists(obj_dialogue)))
534
        waiter++
535
    if (waiter == 3 && sprite_index != spr_dalv_npc_boards_neutral)
536
    {
537
        if (no_loop_sound == false)
538
        {
539
            audio_play_sound(snd_wood_zap, 1, 0)
540
            no_loop_sound = true
541
        }
542
        sprite_index = spr_dalv_npc_boards_neutral
543
        image_speed = (1/3)
544
        image_index = 0
545
    }
546
    if (waiter == 4)
547
    {
548
        direction = 270
549
        sprite_index = cdalv_down
550
        scr_text
scr_text

function scr_text() //gml_Script_scr_text { if (!instance_exists(obj_dialogue)) msg = instance_create(x, y, obj_dialogue) }
()
551
        with (msg)
552
        {
553
            portrait = true
554
            sndfnt = 100
555
            ch_msg = 2
556
            ch[1] = "Clover"
557
            message[0] = "* There we go. You're all#  set."
558
            message[1] = "* Oh, before I forget,#  I never asked for#  your name."
559
            message[2] = "* Mind informing me?"
560
            message[3] = "* Clover? What a nice name."
561
            message[4] = "* Well, Clover, you should#  get going."
562
            message[5] = "* Goodbye..."
563
            message[6] = "* Friend."
564
            prt[0] = 1776
565
            prt[1] = 1769
566
            prt[2] = 1776
567
            prt[3] = 1769
568
            prt[4] = 1776
569
            prt[5] = 1776
570
            prt[6] = 1769
571
        }
572
        waiter++
573
    }
574
    if (waiter == 5 && (!instance_exists(obj_dialogue)))
575
    {
576
        spritelock = true
577
        if (x != 160 || y != 170)
578
            scr_walk_ai
scr_walk_ai

function scr_walk_ai(argument0, argument1, argument2, argument3, argument4) //gml_Script_scr_walk_ai { dalv_walk_speed = argument3 condition_1 = false if (no_loop_destination_dalv == false) { var destination_x = abs(x - argument0) var destination_y = abs(y - argument1) var axis_override = argument4 if (axis_override == "x" || axis_override == "y") dalv_walk_axis = axis_override else { var result = sign(destination_x - destination_y) switch result { case 1: dalv_walk_axis = "x" break case -1: dalv_walk_axis = "y" break default: dalv_walk_axis = "y" } } dalv_walk_speed_x = (sign(argument0 - x)) * dalv_walk_speed dalv_walk_speed_y = (sign(argument1 - y)) * dalv_walk_speed no_loop_destination_dalv = true } if (x == argument0 && y == argument1) { npc_walking = false path_speed = 0 image_speed = 0 image_index = 0 return; } switch dalv_walk_axis { case "x": x_previous = x x += dalv_walk_speed_x if (abs(argument0 - x) < dalv_walk_speed && place_free(argument0, y) && (!(place_meeting(argument0, y, argument2)))) x = argument0 if (place_free(x, y) && (!(place_meeting(x, y, argument2))) && x_previous != argument0) { npc_walking = true image_speed = 0.2 if (dalv_walk_speed_x == (-dalv_walk_speed)) direction = 180 else if (dalv_walk_speed_x == dalv_walk_speed) direction = 0 } if ((!(place_free(x, y))) || place_meeting(x, y, argument2) || x_previous == argument0) { x = x_previous dalv_walk_axis = "y" return; } dalv_walk_speed_y = (sign(argument1 - y)) * dalv_walk_speed i = x + dalv_walk_speed_x j = y if (abs(argument0 - i) < dalv_walk_speed) i = argument0 while (j != argument1) { j += dalv_walk_speed_y if (abs(argument1 - j) < dalv_walk_speed) j = argument1 if ((!(place_free(i, j))) || place_meeting(i, j, argument2)) { condition_1 = true break } else continue } if (condition_1 == true) { while (i != argument0) { i += dalv_walk_speed_x j = y if (abs(argument0 - i) < dalv_walk_speed) i = argument0 while (j != argument1) { j += dalv_walk_speed_y if (abs(argument1 - j) < dalv_walk_speed) j = argument1 if (i == argument0 && j == argument1) return; else if ((!(place_free(i, j))) || place_meeting(i, j, argument2)) break else { if (j == argument1) return; continue ...
(160, 170, obj_pl, 3, 0)
579
        with (obj_pl)
580
        {
581
            if (distance_to_object(obj_dalv3) <= 20 && obj_dalv3.no_loop_autowalk == false)
582
            {
583
                clover_walk_backwards = true
584
                autowalk_direction = "left"
585
                state = gml_Script_scr_autowalk_state
586
               alarm[1]
587
                obj_dalv3.no_loop_autowalk = true
588
            }
589
        }
590
        if (x == 160 && y == 170)
591
        {
592
            npc_walking = false
593
            image_speed = 0
594
            image_index = 0
595
            fadeout = true
596
            if (image_alpha <= 0.2)
597
            {
598
                instance_create(144, 188, obj_dalvExit_blocker)
599
                waiter++
600
            }
601
        }
602
    }
603
    if (waiter == 6)
604
    {
605
        global.flag[29 Dalv board destruction cutscene] = 2
606
        global.cutscene = false
607
        waiter = 0
608
        with (obj_pl)
609
        {
610
            autowalk_direction = "right"
611
            state = gml_Script_scr_autowalk_state
612
           alarm[1]
613
        }
614
    }
615
}
616
with (other)
617
{
618
    if (fadeout == true)
619
        scr_npc_fade
scr_npc_fade

function scr_npc_fade() //gml_Script_scr_npc_fade { solid = false if (image_alpha > 0) image_alpha -= 0.2 if (image_alpha == 0 && fade_kill == true) instance_destroy() }
()
620
    if (sprite_index != spr_dalv_npc_boards_pacifist && sprite_index != spr_dalv_npc_boards_neutral)
621
    {
622
        if (spritelock == true)
623
        {
624
            if (vspeed != 0 || hspeed != 0 || path_speed != 0 || npc_walking == true)
625
            {
626
                switch (direction div 90)
627
                {
628
                    case 0:
629
                        sprite_index = cdalv_right
630
                        break
631
                    case 1:
632
                        sprite_index = cdalv_up
633
                        break
634
                    case 2:
635
                        sprite_index = cdalv_left
636
                        break
637
                    case 3:
638
                        sprite_index = cdalv_down
639
                        break
640
                }
641
642
            }
643
            else
644
            {
645
                switch (direction div 90)
646
                {
647
                    case 0:
648
                        sprite_index = cdalv_rightt
649
                        break
650
                    case 1:
651
                        sprite_index = cdalv_up
652
                        break
653
                    case 2:
654
                        sprite_index = cdalv_leftt
655
                        break
656
                    case 3:
657
                        sprite_index = cdalv_downt
658
                        break
659
                }
660
661
                if (instance_exists(obj_dialogue) && obj_dialogue.sndfnt == 100)
662
                {
663
                    if (obj_dialogue.cutoff == string_length(obj_dialogue.message[obj_dialogue.message_current]))
664
                    {
665
                        image_speed = 0
666
                        image_index = 0
667
                    }
668
                    else
669
                        image_speed = 0.2
670
                }
671
            }
672
        }
673
        if (speed > 0)
674
            image_speed = 0.2
675
    }
676
}
677
var __b__ = action_if_variable(fadein, true, 0)
678
if __b__
679
    script_execute(gml_Script_anim_fade, 0.05, 0, 0, 0, 0)