Deltarune (Chapter 3) script viewer

← back to main script listing

gml_Object_obj_b2d_mazemanager_Step_0

(view raw script w/o annotations or w/e)
1
if (kris == 0)
2
{
3
    with (obj_mainchara_board)
4
    {
5
        if (name == "kris")
6
            other.kris = id;
7
    }
8
}
9
if (kr_real == 0)
10
{
11
    with (obj_mainchara)
12
        other.kr_real = id;
13
}
14
var trigUp = 0;
15
var trigDown = 0;
16
var trigRight = 0;
17
var trigLeft = 0;
18
if (active == 1)
19
{
20
    if (con == 0 && obj_board_camera.con == 0)
21
    {
22
        if (cleanup == 0)
23
        {
24
            with (kris)
25
            {
26
                if (place_meeting(x, y, obj_b2d_centertrigger))
27
                    other.cleanup = 1;
28
            }
29
        }
30
        if (obj_board_camera.board_2_maze_state == 0)
31
        {
32
            if (cleanup == 1)
33
            {
34
                trigDown = 1;
35
                trigLeft = 1;
36
                trigRight = 1;
37
                cleanup = 2;
38
            }
39
        }
40
        if (obj_board_camera.board_2_maze_state == 1)
41
        {
42
            if (cleanup == 1)
43
            {
44
                trigDown = 1;
45
                trigLeft = 1;
46
                trigRight = 1;
47
                cleanup = 2;
48
            }
49
        }
50
        if (obj_board_camera.board_2_maze_state == 2)
51
        {
52
            if (cleanup == 1)
53
            {
54
                trigUp = 1;
55
                trigDown = 1;
56
                trigRight = 1;
57
                cleanup = 2;
58
            }
59
        }
60
        if (obj_board_camera.board_2_maze_state == 3)
61
        {
62
            if (cleanup == 1)
63
            {
64
                trigUp = 1;
65
                trigDown = 1;
66
                trigLeft = 1;
67
                cleanup = 2;
68
            }
69
        }
70
        if (obj_board_camera.board_2_maze_state == 4)
71
        {
72
            if (cleanup == 1)
73
            {
74
                trigUp = 1;
75
                trigDown = 1;
76
                trigLeft = 1;
77
                cleanup = 2;
78
            }
79
        }
80
        if (obj_board_camera.board_2_maze_state == 5)
81
        {
82
            if (cleanup == 1)
83
            {
84
                trigUp = 1;
85
                trigLeft = 1;
86
                trigRight = 1;
87
                cleanup = 2;
88
            }
89
        }
90
        if (obj_board_camera.board_2_maze_state == 6)
91
        {
92
            if (cleanup == 1)
93
            {
94
                trigUp = 1;
95
                trigDown = 1;
96
                trigLeft = 1;
97
                cleanup = 2;
98
            }
99
        }
100
        if (obj_board_camera.board_2_maze_state == 7)
101
        {
102
            cleanup = 0;
103
            with (obj_board_trigger)
104
            {
105
                if (extflag == "dontfollow")
106
                    instance_destroy();
107
            }
108
            instance_destroy();
109
        }
110
    }
111
}
112
else
113
{
114
}
115
if (obj_board_camera.con != 0)
116
{
117
    if (cleanup)
118
    {
119
        cleanup = 0;
120
        with (obj_board_trigger)
121
        {
122
            if (extflag == "dontfollow")
123
                instance_destroy();
124
        }
125
    }
126
}
127
if (trigUp)
128
{
129
    with (instance_create(x, y, obj_board_trigger))
130
    {
131
        extflag = "dontfollow";
132
        setxy_board(3744, 1344);
133
        image_xscale = 4;
134
        image_yscale = 4;
135
    }
136
}
137
if (trigDown)
138
{
139
    with (instance_create(x, y, obj_board_trigger))
140
    {
141
        extflag = "dontfollow";
142
        setxy_board(3744, 1536);
143
        image_xscale = 4;
144
        image_yscale = 4;
145
    }
146
}
147
if (trigLeft)
148
{
149
    with (instance_create(x, y, obj_board_trigger))
150
    {
151
        extflag = "dontfollow";
152
        setxy_board(3584, 1440);
153
        image_xscale = 8;
154
        image_yscale = 4;
155
    }
156
}
157
if (trigRight)
158
{
159
    with (instance_create(x, y, obj_board_trigger))
160
    {
161
        extflag = "dontfollow";
162
        setxy_board(3840, 1440);
163
        image_xscale = 8;
164
        image_yscale = 4;
165
    }
166
}
167
if (
scr_debug
scr_debug

function
scr_debug()
{ if (global.debug == 1) return 1; }
())
168
{
169
    if (active)
170
    {
171
        with (obj_board_trigger)
172
        {
173
        }
174
    }
175
}