Deltarune (Chapter 2) script viewer

← back to main script listing

gml_Object_obj_ch2_sceneex2_mus_Step_0

(view raw script w/o annotations or w/e)
1
if (con == -1)
2
{
3
    var offset = 0;
4
    if (obj_mainchara.press_l == 1)
5
        offset = -0.003;
6
    else if (obj_mainchara.press_r == 1)
7
        offset = 0.003;
8
    if (offset != 0)
9
    {
10
        var gain = clamp(audio_sound_get_gain(global.currentsong[0]) + offset, 0.5, 1);
11
        audio_sound_gain(global.currentsong[0], gain, 0);
12
    }
13
}
14
if (con == 10)
15
{
16
    con = 99;
17
    alarm[0]
 = 10;
gml_Object_obj_ch2_sceneex2_mus_Alarm_0.gml

con++;
18
    snd_play(snd_noise);
19
    snd_free(global.currentsong[0]);
20
}
21
if (con == 100)
22
{
23
    con = 111;
24
    audio_stop_all();
25
    snd_free_all();
26
}