Deltarune (Chapter 5) script viewer

← back to main script listing

gml_Object_obj_climb_bullet_shuriken_vert_Step_0

(view raw script w/o annotations or w/e)
1
if (global.interact == 0)
2
{
3
    timer++;
4
    array_push(xp, x);
5
    array_push(yp, y);
6
    if (array_length(xp) > 8)
7
    {
8
        array_delete(xp, 0, 1);
9
        array_delete(yp, 0, 1);
10
    }
11
    x += hsp;
12
    y += vsp;
13
    if (!die)
14
    {
15
        if (scr_trigcheck_ext("shurikenKiller", id) || y >= (cameray() + 480))
16
            die = true;
17
    }
18
    if (die)
19
    {
20
        image_alpha -= (1/30);
21
        if (image_alpha <= 0)
22
            instance_destroy();
23
    }
24
}