Deltarune (Chapter 2) script viewer

← back to main script listing

gml_Object_obj_ch2_room_city_spamton_house_Create_0

(view raw script w/o annotations or w/e)
1
if (global.flag[309 spamton_plot] == 9)
2
{
3
    with (obj_queenscreen)
4
        instance_destroy();
5
    var addison_sprites = array_create(6);
6
    addison_sprites[0] = spr_npc_addison_blue_up;
7
    addison_sprites[1] = spr_npc_addison_yellow_up;
8
    addison_sprites[2] = spr_npc_addison_pink_up;
9
    addison_sprites[3] = spr_npc_addison_orange_up;
10
    addison_sprites[4] = spr_npc_addison_blue_up;
11
    addison_sprites[5] = spr_npc_addison_yellow_up;
12
    for (var i = 0; i < array_length_1d(addison_sprites); i++)
13
    {
14
        var npc = instance_create(400 + (i * 120), 132, obj_npc_room);
15
        npc.sprite_index = addison_sprites[i];
16
        with (npc)
17
            scr_depth
scr_depth

function scr_depth() { depth = 100000 - ((y * 10) + (sprite_height * 10)); }
();
18
    }
19
}
20
else
21
{
22
    instance_destroy();
23
}