1 |
if (obj_snowdin_19_watermeter.image_speed != 0 || (instance_exists(obj_snowdin_19_icecube) && obj_snowdin_19_icecube.shrink == true)) |
2 |
return; |
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;
}
} ()) |
4 |
{ |
5 |
if (waiter == 0) |
6 |
{ |
7 |
if (global.snowdin_flag[12] < 2) |
8 |
{ |
9 |
cam = instance_create(obj_pl.x, obj_pl.y, obj_camera) |
10 |
__view_set((9 << 0), 0, 1120) |
11 |
direction = 0 |
12 |
scr_cutscene_startscr_cutscene_startfunction scr_cutscene_start() //gml_Script_scr_cutscene_start
{
global.cutscene = true
obj_pl.state = gml_Script_scr_frozen_state
obj_pl.image_index = 0
obj_pl.image_speed = 0
} () |
13 |
audio_play_sound(snd_puzzle_start, 1, 0) |
14 |
global.text_box_open = false |
15 |
waiter = 1 |
16 |
} |
17 |
else if (global.snowdin_flag[12] == 2) |
18 |
{ |
19 |
scr_textscr_textfunction scr_text() //gml_Script_scr_text
{
if (!instance_exists(obj_dialogue))
msg = instance_create(x, y, obj_dialogue)
} () |
20 |
with (msg) |
21 |
{ |
22 |
sndfnt = 99 |
23 |
portrait = false |
24 |
message[0] = "* The switch won't budge anymore." |
25 |
} |
26 |
waiter = 5 |
27 |
} |
28 |
} |
29 |
} |
30 |
if (waiter == 1) |
31 |
{ |
32 |
if (scr_camera_movescr_camera_movefunction scr_camera_move(argument0, argument1, argument2) //gml_Script_scr_camera_move
{
if (!instance_exists(obj_camera))
{
instance_create(__view_get((9 << 0), 0).x, __view_get((9 << 0), 0).y, obj_camera)
__view_set((9 << 0), 0, 1120)
}
else
{
obj_camera.x = __view_get((9 << 0), 0).x
obj_camera.y = __view_get((9 << 0), 0).y
__view_set((9 << 0), 0, 1120)
}
obj_camera.move = true
obj_camera.xx = argument0
obj_camera.yy = argument1
obj_camera.spd = argument2
if (abs(argument0 - obj_camera.x) <= argument2 && abs(argument1 - obj_camera.y) <= argument2)
return true;
else
return false;
} (obj_pl.x, 90, 3) == true) |
33 |
waiter = 3 |
34 |
} |
35 |
if (waiter == 2 && cam.x > 260) |
36 |
{ |
37 |
cam.hspeed = 0 |
38 |
waiter = 3 |
39 |
} |
40 |
if (waiter == 3) |
41 |
{ |
42 |
obj_puzzle_controller_snowdin_19_overworld_yellow.active = true |
43 |
waiter = 4 |
44 |
} |
45 |
if (waiter == 5 && (!instance_exists(obj_dialoguebox))) |
46 |
waiter = 0 |
47 |
if (timer > 0) |
48 |
timer-- |
49 |
else if (timer != -1) |
50 |
{ |
51 |
waiter = 4 |
52 |
timer = -1 |
53 |
} |