Undertale Yellow script viewer

← back to main script listing

gml_Object_obj_arcade_intro_Step_0

(view raw script w/o annotations or w/e)
1
if (arc_controls_open == true)
2
{
3
    if (keyboard_multicheck_pressed(0) || keyboard_multicheck_pressed(1))
4
    {
5
        arc_controls_open = false;
6
        audio_play_sound(snd_arc_menu_select, 1, 0);
7
    }
8
    exit;
9
}
10
if (overlay_alpha > 0)
11
    overlay_alpha -= 0.1;
12
if (end_game)
13
{
14
    if (!audio_is_playing(snd_mew_seeya) && !instance_exists(obj_transition))
15
    {
16
        global.cutscene = false;
17
        var trn = instance_create(0, 0, obj_transition);
18
        with (trn)
19
        {
20
            newRoom = 125;
21
            xx = 43;
22
            yy = 78;
23
        }
24
    }
25
    exit;
26
}
27
switch (scene)
28
{
29
    case 3:
30
        if (arc_title_x > 160)
31
            arc_title_x -= 5;
32
        else
33
            scene++;
34
        break;
35
    case 4:
36
        if (!alarm[4])
37
            alarm[4] = 15;
gml_Object_obj_arcade_intro_Alarm_4.gml

arc_draw_menu_options = true; audio_play_sound(snd_mew_title, 1, 0); scene++;
38
        break;
39
    case 5:
40
        if (global.down_keyp)
41
        {
42
            if (arc_cursor_pos < 3)
43
                arc_cursor_pos++;
44
            else
45
                arc_cursor_pos = 1;
46
            audio_play_sound(snd_arc_menu_move, 1, 0);
47
        }
48
        if (global.up_keyp)
49
        {
50
            if (arc_cursor_pos > 1)
51
                arc_cursor_pos--;
52
            else
53
                arc_cursor_pos = 3;
54
            audio_play_sound(snd_arc_menu_move, 1, 0);
55
        }
56
        if (keyboard_multicheck_pressed(0))
57
        {
58
            switch (arc_cursor_pos)
59
            {
60
                case 1:
61
                    scene++;
62
                    audio_play_sound(snd_arc_menu_select, 1, 0);
63
                    break;
64
                case 2:
65
                    arc_controls_open = true;
66
                    arc_cursor_pos = 1;
67
                    audio_play_sound(snd_arc_menu_select, 1, 0);
68
                    break;
69
                case 3:
70
                    end_game = true;
71
                    audio_play_sound(snd_mew_seeya, 1, 0);
72
                    break;
73
            }
74
        }
75
        break;
76
    case 6:
77
        if (!alarm[5])
78
            alarm[5] = 30;
gml_Object_obj_arcade_intro_Alarm_5.gml

instance_create(0, 0, obj_arcade_controller); instance_destroy();
79
        break;
80
}
81
if (scene < 5)
82
{
83
    if (keyboard_multicheck_pressed(0))
84
    {
85
        arc_title_x = 160;
86
        arc_draw_menu_options = true;
87
        audio_stop_all();
88
        audio_play_sound(snd_mew_title, 1, 0);
89
        scene = 5;
90
        for (var i = 0; i < 12; i++)
91
        {
92
            if (alarm_get(i) > 0)
93
                alarm_set(i, -1);
94
        }
95
    }
96
}