Undertale script viewer

← back to main script listing

gml_Object_obj_friendscene_Draw_0

(view raw script w/o annotations or w/e)
1
if (gowhite == 1)
2
{
3
    wht += 0.2;
4
    draw_set_alpha(wht);
5
    draw_set_color(c_white);
6
    ossafe_fill_rectangle(-10, -10, 999, 999);
7
    draw_set_alpha(1);
8
    if (wht > 1.5)
9
    {
10
        gowhite = 2;
11
        fmusic = caster_load("music/yourbestfriend_3.ogg");
12
        al2 = instance_create(410, 0, obj_wrapshock);
13
        al2.type = 4;
14
        with (al)
15
            instance_destroy();
16
        und2 = instance_create(110, 42, obj_wrapshock);
17
        und2.type = 3;
18
        with (und)
19
            instance_destroy();
20
        asg2 = instance_create(-128, 10, obj_wrapshock);
21
        asg2.type = 5;
22
        with (asg)
23
            instance_destroy();
24
        sans2 = instance_create(290, 56, obj_wrapshock);
25
        sans2.type = 2;
26
        with (sans)
27
            instance_destroy();
28
        pap2 = instance_create(513, 0, obj_wrapshock);
29
        pap2.type = 1;
30
        with (pap)
31
            instance_destroy();
32
        tor2 = instance_create(185, 48, obj_wrapshock);
33
        with (tor)
34
            instance_destroy();
35
        with (obj_friendscene_gigavine)
36
        {
37
            y -= 100;
38
            shimmy = 1;
39
        }
40
    }
41
}
42
if (gowhite == 2)
43
{
44
    wht -= 0.2;
45
    draw_set_alpha(wht);
46
    draw_set_color(c_white);
47
    ossafe_fill_rectangle(-10, -10, 999, 999);
48
    draw_set_alpha(1);
49
    if (wht < 0.04)
50
    {
51
        wht = 0;
52
        gowhite = 0;
53
    }
54
}
55
if (border_d == 1)
56
{
57
    cx = 310;
58
    cx2 = 330;
59
    cy = 290;
60
    cy2 = 310;
61
    obj_heart.x = cx + 2;
62
    obj_heart.y = cy + 2;
63
    obj_heart.movement = 0;
64
    draw_set_color(c_white);
65
    cc = 0;
66
    repeat (4)
67
    {
68
        draw_rectangle(cx - cc, cy - cc, cx2 + cc, cy2 + cc, true);
69
        cc += 1;
70
    }
71
}
72
if (trickblack == 1)
73
{
74
    flowey.depth = depth - 10;
75
    draw_set_color(c_black);
76
    draw_set_alpha(0.5);
77
    ossafe_fill_rectangle(-10, -10, 999, 999);
78
    draw_set_alpha(1);
79
}
80
if (lastwhite == 1)
81
{
82
    view_xview[0] = (0 + random(2 + (wht * 2))) - random(2 - (wht * 2));
83
    view_yview[0] = (0 + random(2 + (wht * 2))) - random(2 - (wht * 2));
84
    wht += 0.003;
85
    draw_set_alpha(wht);
86
    draw_set_color(c_white);
87
    ossafe_fill_rectangle(-10, -10, 999, 999);
88
    draw_set_alpha(1);
89
}
90
if (leg > 0)
91
{
92
    if (leg == 1)
93
    {
94
        if (legx > (room_width + 50))
95
            legx -= 10;
96
        leg_r += 1;
97
    }
98
    if (leg == 2)
99
    {
100
        leg_r += 1;
101
        if (legx < (room_width + 200))
102
            legx += 10;
103
        else
104
            leg = 0;
105
    }
106
    draw_sprite_ext(spr_mettleg2_flip, 0, legx, 180, 2, 2, sin(leg_r / 4) * 6, c_white, 1);
107
}