Deltarune (Chapter 5) script viewer

← back to main script listing

gml_Object_obj_ch5_DW30_healing_rain_Step_0

(view raw script w/o annotations or w/e)
1
if (!_init)
2
    exit;
3
timer++;
4
if (timer == 1)
5
{
6
    
scr_lerpvar
scr_lerpvar

function
scr_lerpvar()
{ var _id = self; if (!is_struct(self)) _id = id; if (argument_count < 6) ___lerpvar =
scr_lerpvar_instance(_id, argument[0], argument[1], argument[2], argument[3]);
else ___lerpvar =
scr_lerpvar_instance(_id, argument[0], argument[1], argument[2], argument[3], argument[4], argument[5]);
return ___lerpvar; } function scr_lerpcol() { if (argument_count < 6) ___lerpvar = scr_lerpcol_instance(id, argument[0], argument[1], argument[2], argument[3]); else ___lerpvar = scr_lerpcol_instance(id, argument[0], argument[1], argument[2], argument[3], argument[4], argument[5]); return ___lerpvar; }
("image_xscale", 0, 2, 10, -1, "out");
7
    
scr_lerpvar
scr_lerpvar

function
scr_lerpvar()
{ var _id = self; if (!is_struct(self)) _id = id; if (argument_count < 6) ___lerpvar =
scr_lerpvar_instance(_id, argument[0], argument[1], argument[2], argument[3]);
else ___lerpvar =
scr_lerpvar_instance(_id, argument[0], argument[1], argument[2], argument[3], argument[4], argument[5]);
return ___lerpvar; } function scr_lerpcol() { if (argument_count < 6) ___lerpvar = scr_lerpcol_instance(id, argument[0], argument[1], argument[2], argument[3]); else ___lerpvar = scr_lerpcol_instance(id, argument[0], argument[1], argument[2], argument[3], argument[4], argument[5]); return ___lerpvar; }
("image_yscale", 0, 2, 10, -1, "out");
8
    snd_play(snd_cd_bagel_noelle);
9
    timer = 12;
10
}
11
if (timer == 41)
12
{
13
    sprite_index = spr_blue_cloud_rain;
14
    snd_loop(snd_rain_short);
15
}
16
if (timer == 67)
17
{
18
    snd_stop(snd_rain_short);
19
    sprite_index = spr_blue_cloud;
20
    instance_create(_target.x, _target.y + 60, obj_dmgwriter);
21
    with (obj_dmgwriter)
22
    {
23
        delay = 4;
24
        specialmessage = 99;
25
        image_blend = #5060EB;
26
        image_index = 2;
27
        image_speed = 0;
28
    }
29
    heal_lerp = 0;
30
    healanim = instance_create(_target.x, _target.y, obj_healanim);
31
    healanim.target = _target.id;
32
    with (obj_healanim)
33
        particlecolor = #5060EB;
34
    snd_play(snd_power);
35
}
36
if (timer == 69)
37
{
38
    var _poof = instance_create(x, y, obj_animation);
39
    _poof.image_xscale = 2;
40
    _poof.image_yscale = 2;
41
    _poof.sprite_index = spr_smokepuff;
42
    _poof.image_speed = 0.5;
43
    _poof.depth = depth - 10;
44
}
45
if (timer == 75)
46
{
47
    clean_up();
48
    exit;
49
}
50
if (heal_lerp >= 0)
51
{
52
    var _lerp = clamp01((heal_lerp - 8) / 10);
53
    with (obj_dmgwriter)
54
        image_blend = merge_colour(#5060EB, c_lime, _lerp);
55
    if (_lerp >= 1)
56
    {
57
        heal_lerp = -1;
58
        with (obj_dmgwriter)
59
            type = 3;
60
    }
61
    else
62
    {
63
        heal_lerp++;
64
    }
65
}