Deltarune (Chapter 5) script viewer

← back to main script listing

gml_Object_obj_growtangle_Step_2

related scripts: Create_0Destroy_0Draw_0Other_5Step_0Step_2

(view raw script w/o annotations or w/e)
1
if (growcon == 3 && !close_signal)
2
{
3
    close_signal = true;
4
    if (close_function)
5
        close_function();
6
}
7
if (keep == 1)
8
{
9
    if (instance_exists(obj_heart))
10
    {
11
        if (path_speed != 0 || speed != 0 || megakeep == 1)
12
        {
13
            lborder = x - (sprite_width / 2);
14
            rborder = x + (sprite_width / 2);
15
            uborder = y - (sprite_height / 2);
16
            dborder = y + (sprite_height / 2);
17
            if (obj_heart.x < (lborder + 5))
18
                obj_heart.x = lborder + 5;
19
            if (obj_heart.x > (rborder - 22))
20
                obj_heart.x = rborder - 22;
21
            if (obj_heart.y < (uborder + 5))
22
                obj_heart.y = uborder + 5;
23
            if (obj_heart.y > (dborder - 22))
24
                obj_heart.y = dborder - 22;
25
        }
26
    }
27
}
28
if (keep_function)
29
    keep_function();