Deltarune (Chapter 3) script viewer

← back to main script listing

gml_Object_obj_room_tvland_preview_Create_0

(view raw script w/o annotations or w/e)
1
con = -1;
2
var zapper_npc = instance_create(820, 74, obj_npc_room);
3
with (zapper_npc)
4
{
5
    sprite_index = spr_npc_zapper_talk;
6
    extflag = "zapper";
7
    
scr_depth
scr_depth

function
scr_depth()
{ if (argument_count > 0) { with (argument0) depth = 100000 - ((y * 10) + (sprite_height * 10)); } else { depth = 100000 - ((y * 10) + (sprite_height * 10)); } }
();
8
}
9
if (global.plot < 180)
10
{
11
    var no_counterfeit = global.plot >= 120 && global.plot < 160 && 
scr_flag_get
scr_flag_get

function
scr_flag_get(arg0)
{ var flag_value = global.flag[arg0]; return flag_value; }
(1076) == 0;
12
    var can_cheat = no_counterfeit && 
scr_flag_get
scr_flag_get

function
scr_flag_get(arg0)
{ var flag_value = global.flag[arg0]; return flag_value; }
(1173) < 4;
13
    if (global.plot >= 160)
14
    {
15
        no_counterfeit = 
scr_flag_get
scr_flag_get

function
scr_flag_get(arg0)
{ var flag_value = global.flag[arg0]; return flag_value; }
(1076) >= 1 &&
scr_flag_get
scr_flag_get

function
scr_flag_get(arg0)
{ var flag_value = global.flag[arg0]; return flag_value; }
(1077) == 0;
16
        var prev_s_rank = 
scr_flag_get
scr_flag_get

function
scr_flag_get(arg0)
{ var flag_value = global.flag[arg0]; return flag_value; }
(1173) >= 4 &&
scr_flag_get
scr_flag_get

function
scr_flag_get(arg0)
{ var flag_value = global.flag[arg0]; return flag_value; }
(1077) == 0;
17
        can_cheat = 
scr_flag_get
scr_flag_get

function
scr_flag_get(arg0)
{ var flag_value = global.flag[arg0]; return flag_value; }
(1174) < 4 && (no_counterfeit || prev_s_rank);
18
    }
19
    if (can_cheat)
20
    {
21
        pippins_cheater_marker = 
scr_dark_marker
scr_dark_marker

function
scr_dark_marker(arg0, arg1, arg2)
{ thismarker = instance_create(arg0, arg1, obj_marker); with (thismarker) { sprite_index = arg2; image_speed = 0; image_xscale = 2; image_yscale = 2; } return thismarker; }
(1100, 488, spr_npc_pippins_jump_cool);
22
        pippins_cheater_marker.image_speed = 0.2;
23
        with (pippins_cheater_marker)
24
            
scr_depth
scr_depth

function
scr_depth()
{ if (argument_count > 0) { with (argument0) depth = 100000 - ((y * 10) + (sprite_height * 10)); } else { depth = 100000 - ((y * 10) + (sprite_height * 10)); } }
();
25
        pippins_cheater_readable = instance_create(pippins_cheater_marker.x + 8, pippins_cheater_marker.y + 16, obj_readable_room1);
26
        with (pippins_cheater_readable)
27
        {
28
            image_xscale = 3;
29
            image_yscale = 3;
30
            extflag = "pippins_cheater";
31
        }
32
        var board_flag = 1173;
33
        if (global.plot >= 160)
34
            board_flag = 1174;
35
        if (
scr_flag_get
scr_flag_get

function
scr_flag_get(arg0)
{ var flag_value = global.flag[arg0]; return flag_value; }
(board_flag) == 0)
36
            pippins_cheater_readable.extflag = "pippins_z_rank";
37
        var pippins_cheater_block = instance_create(pippins_cheater_marker.x, pippins_cheater_marker.y + 32, obj_solidblocksized);
38
        with (pippins_cheater_block)
39
            image_xscale = 2;
40
    }
41
}
42
var pippins_marker = 
scr_dark_marker
scr_dark_marker

function
scr_dark_marker(arg0, arg1, arg2)
{ thismarker = instance_create(arg0, arg1, obj_marker); with (thismarker) { sprite_index = arg2; image_speed = 0; image_xscale = 2; image_yscale = 2; } return thismarker; }
(948, 134, spr_npc_pippins_jump);
43
pippins_marker.image_speed = 0.2;
44
with (pippins_marker)
45
    
scr_depth
scr_depth

function
scr_depth()
{ if (argument_count > 0) { with (argument0) depth = 100000 - ((y * 10) + (sprite_height * 10)); } else { depth = 100000 - ((y * 10) + (sprite_height * 10)); } }
();
46
var pippins_readable = instance_create(pippins_marker.x + 8, pippins_marker.y + 16, obj_readable_room1);
47
with (pippins_readable)
48
{
49
    image_xscale = 3;
50
    image_yscale = 3;
51
    extflag = "pippins";
52
}
53
var pippins_block = instance_create(pippins_marker.x, pippins_marker.y + 32, obj_solidblocksized);
54
with (pippins_block)
55
    image_xscale = 2;
56
var vending_npc = instance_create(1084, 134, obj_npc_room);
57
with (vending_npc)
58
{
59
    sprite_index = spr_dw_tvland_preview_vending;
60
    extflag = "vending";
61
    
scr_depth
scr_depth

function
scr_depth()
{ if (argument_count > 0) { with (argument0) depth = 100000 - ((y * 10) + (sprite_height * 10)); } else { depth = 100000 - ((y * 10) + (sprite_height * 10)); } }
();
62
}
63
pippins_flee = false;
64
if (global.plot < 250)
65
{
66
    var _stanchions = instance_create(1080, 680, obj_dw_ch3_funny_stanchion_controller);
67
    with (_stanchions)
68
    {
69
        front_facing = false;
70
        
scr_depth
scr_depth

function
scr_depth()
{ if (argument_count > 0) { with (argument0) depth = 100000 - ((y * 10) + (sprite_height * 10)); } else { depth = 100000 - ((y * 10) + (sprite_height * 10)); } }
();
71
        image_xscale = 6;
72
        image_yscale = 2;
73
        init();
74
    }
75
}
76
else
77
{
78
    var snow_vfx = instance_create(0, 0, obj_dw_ch3_tvsnow);
79
    snow_vfx.bgdepth = 30000;
80
    with (zapper_npc)
81
    {
82
        sprite_index = spr_npc_zapper_stone;
83
        extflag = "zapper_stone";
84
        
scr_depth
scr_depth

function
scr_depth()
{ if (argument_count > 0) { with (argument0) depth = 100000 - ((y * 10) + (sprite_height * 10)); } else { depth = 100000 - ((y * 10) + (sprite_height * 10)); } }
();
85
    }
86
    with (pippins_marker)
87
    {
88
        sprite_index = spr_npc_pippins_up;
89
        
scr_depth
scr_depth

function
scr_depth()
{ if (argument_count > 0) { with (argument0) depth = 100000 - ((y * 10) + (sprite_height * 10)); } else { depth = 100000 - ((y * 10) + (sprite_height * 10)); } }
();
90
    }
91
    with (obj_border_controller)
92
        set_border(border_dw_blue_light);
93
}
94
if (global.plot < 160)
95
{
96
    var curtain_npc = instance_create(50, 650, obj_npc_room);
97
    with (curtain_npc)
98
    {
99
        extflag = "curtain";
100
        sprite_index = spr_dw_teevie_preview_curtain;
101
        normalanim = 4;
102
    }
103
}
104
else if (global.plot >= 160 && global.plot < 250)
105
{
106
    var shutta_npc = instance_create(92, 650, obj_npc_room);
107
    with (shutta_npc)
108
    {
109
        extflag = "shutta";
110
        sprite_index = spr_npc_shutta;
111
    }
112
}