Deltarune (Chapter 2) script viewer

← back to main script listing

gml_Object_obj_shop_ch2_music_Draw_0

(view raw script w/o annotations or w/e)
1
if (snd_is_playing(global.currentsong[1]))
2
    siner++;
3
for (i = 0; i < 3; i++)
4
{
5
    spritetalkingbuffer[i]--;
6
    if (spritetalkingbuffer[i] <= 0)
7
        spritetalking[i] = 0;
8
}
9
if (instance_exists(obj_writer))
10
{
11
    if (obj_writer.pos < obj_writer.length && obj_writer.miniface_drawn >= 0)
12
    {
13
        if (obj_writer.miniface_drawn == 1)
14
            spritetalkingframe[1]++;
15
        if (obj_writer.miniface_drawn == 2)
16
            spritetalkingframe[0]++;
17
        if (obj_writer.miniface_drawn == 3)
18
            spritetalkingframe[2]++;
19
        for (i = 0; i < 3; i++)
20
        {
21
            if (spritetalkingframe[i] >= 2)
22
            {
23
                spritetalking[i] = 1;
24
                spritetalkingbuffer[i] = 8;
25
            }
26
        }
27
    }
28
    else
29
    {
30
        spritetalkingframe[0] = 0;
31
        spritetalkingframe[1] = 0;
32
        spritetalkingframe[2] = 0;
33
    }
34
}
35
else
36
{
37
    spritetalkingframe[0] = 0;
38
    spritetalkingframe[1] = 0;
39
    spritetalkingframe[2] = 0;
40
}
41
draw_sprite_ext(spr_shop_m_bg, siner / 3, 0, 0, 2, 2, 0, c_white, 1);
42
if (everyonedance == 0)
43
{
44
    draw_sprite_ext(spr_shop_m_capn_body, siner / 4, 0, 0, 2, 2, 0, c_white, 1);
45
    if (spritetalking[2] == 0)
46
        draw_sprite_ext(spr_shop_m_capn_head, siner / 4, 0, 0, 2, 2, 0, c_white, 1);
47
    if (spritetalking[2] == 1)
48
        draw_sprite_ext(spr_shop_m_capn_head_talk, siner / 4, 0, 8, 2, 2, 0, c_white, 1);
49
    if (spritetalking[1] == 0)
50
        draw_sprite_ext(spr_shop_m_sweet, siner / 6, 0, 0, 2, 2, 0, c_white, 1);
51
    if (spritetalking[1] == 1)
52
        draw_sprite_ext(spr_shop_m_sweet_talk, siner / 6, 0, 0, 2, 2, 0, c_white, 1);
53
    draw_sprite_ext(spr_shop_m_kk_body, siner / 6, 0, 0, 2, 2, 0, c_white, 1);
54
    if (spritetalking[0] == 0)
55
        draw_sprite_ext(spr_shop_m_kk_head, siner / 6, 0, 0, 2, 2, 0, c_white, 1);
56
    if (spritetalking[0] == 1)
57
        draw_sprite_ext(spr_shop_m_kk_head_talk, siner / 6, 0, 0, 2, 2, 0, c_white, 1);
58
}
59
else
60
{
61
    fliptimer++;
62
    draw_sprite_ext(spr_shop_m_capn_body, min(fliptimer, 7), capnoffset, 0, 2 * capnflip, 2, 0, c_white, 1);
63
    draw_sprite_ext(spr_shop_m_capn_head, min(fliptimer, 7), capnoffset, 0, 2 * capnflip, 2, 0, c_white, 1);
64
    draw_sprite_ext(spr_shop_m_kk_body, fliptimer / 3, kkoffset + (sin(fliptimer / 2) * 4 * capnflip), 0, 2 * capnflip, 2, 0, c_white, 1);
65
    draw_sprite_ext(spr_shop_m_kk_head_talk, fliptimer / 3, kkoffset - (sin(fliptimer / 2) * 4 * capnflip), 0, 2 * capnflip, 2, 0, c_white, 1);
66
    draw_sprite_ext(spr_shop_m_sweet_happy, fliptimer / 3, (kkoffset / 1.53) - (cos(siner / 4) * 8), (sin(siner / 2) * 8) + 8, 2 * capnflip, 2, 0, c_white, 1);
67
    if (fliptimer >= 8)
68
    {
69
        if (capnflip == 1)
70
        {
71
            capnflip = -1;
72
            capnoffset = 200;
73
            kkoffset = 920;
74
        }
75
        else
76
        {
77
            kkoffset = 0;
78
            capnflip = 1;
79
            capnoffset = 0;
80
        }
81
        fliptimer = 0;
82
    }
83
    if (everyonedance == 2)
84
    {
85
        for (i = 0; i < 3; i++)
86
        {
87
            shopcharx[i] = 0;
88
            shopchary[i] = 0;
89
            spritetalking[i] = 0;
90
            spritetalkingframe[i] = 0;
91
            spritetalkingbuffer[i] = 0;
92
        }
93
        siner = 0;
94
        startdancing = 0;
95
        everyonedance = 0;
96
    }
97
}
98
draw_set_color(c_black);
99
draw_rectangle(-10, 240, 700, 600, false);
100
if (startdancing == 1)
101
{
102
    everyonedance = 1;
103
    dancetimer = 0;
104
    fliptimer = 0;
105
    capnflip = 1;
106
    kkoffset = 0;
107
    startdancing = 0;
108
    capnoffset = 0;
109
}
110
scr_shopmenu
scr_shopmenu

function scr_shopmenu(arg0) { if (arg0 == 0) { if (menu == 1 || menu == 2) { scr_darkbox_black(400, minimenuy, 640, 255); draw_set_color(c_white); scr_84_set_draw_font("mainbig"); if (menuc[1] == 0) draw_text(440, minimenuy + 28, string_hash_to_newline(shopdesc[0])); if (menuc[1] == 1) draw_text(440, minimenuy + 28, string_hash_to_newline(shopdesc[1])); if (menuc[1] == 2) draw_text(440, minimenuy + 28, string_hash_to_newline(shopdesc[2])); if (menuc[1] == 3) draw_text(440, minimenuy + 28, string_hash_to_newline(shopdesc[3])); scr_84_set_draw_font("dotumche"); if (itemtype[menuc[1]] == "weapon" || itemtype[menuc[1]] == "armor") { for (i = 0; i < 3; i += 1) { can_index = 0; facetype = spr_headkris; which = global.char[i]; if (global.char[i] == 1) facetype = spr_headkris; if (global.char[i] == 2) facetype = spr_headsusie; if (global.char[i] == 3) facetype = spr_headralsei; if (which != 0) { if (i == 0) { locx = 0; locy = 0; } if (i == 1) { locx = 100; locy = 0; } if (i == 2) { locx = 0; locy = 45; } if (canequip[menuc[1]][which] == 0) can_index = 8; draw_sprite(facetype, can_index, 426 + locx, minimenuy + 140 + locy); if (itemtype[menuc[1]] == "weapon" && can_index != 8) { draw_set_color(c_white); sum[0] = itematk[menuc[1]] - global.itemat[which][0]; sum[1] = itemmagic[menuc[1]] - global.itemmag[which][0]; for (j = 0; j < 2; j += 1) { dcolor = c_white; addt = ""; draw_set_color(c_white); if (sum[j] > 0) { draw_set_color(c_yellow); addt = "+"; } if (sum[j] < 0) draw_set_color(c_aqua); draw_sprite_ext(spr_shopicon, j, 470 + locx, minimenuy + locy + 135 + (20 * j), 1, 1, 0, dcolor, 1); draw_text(490 + locx, minimenuy + locy + 135 + (20 * j), string_hash_to_newline(addt + string(sum[j]))); } } if (itemtype[menuc[1]] == "armor" && can_index != 8) { sum[0] = itemdef[menuc[1]] - global.itemdf[which][1]; sum[1] = itemdef[menuc[1]] - global.itemdf[which][2]; for (j = 0; j < 2; j += 1) { dcolor = c_white; addt = ""; draw_set_color(c_white); if (sum[j] > 0) { draw_set_color(c_yellow); addt = "+"; } if (sum[j] < 0) draw_set_color(c_aqua); draw_sprite_ext(spr_shopicon, 2 + j, 470 + locx, minimenuy + locy + 135 + (20 * j), 1, 1, 0, dcolor, 1); draw_text(490 + locx, minimenuy + 135 + (20 * j) + locy, string_hash_to_newline(addt + string(sum[j]))); } } } } } } } if (arg0 == 4) { if (menu == 11 || menu == 15) { ...
(0);
111
if (menu <= 3 || menu >= 10)
112
{
113
    scr_darkbox_black
scr_darkbox_black

function scr_darkbox_black(arg0, arg1, arg2, arg3) { draw_set_color(c_black); draw_rectangle(arg0 + 20, arg1 + 20, arg2 - 20, arg3 - 20, false); scr_darkbox(arg0, arg1, arg2, arg3); }
(0, 240, 415, 480);
114
    scr_darkbox_black
scr_darkbox_black

function scr_darkbox_black(arg0, arg1, arg2, arg3) { draw_set_color(c_black); draw_rectangle(arg0 + 20, arg1 + 20, arg2 - 20, arg3 - 20, false); scr_darkbox(arg0, arg1, arg2, arg3); }
(400, 240, 640, 480);
115
}
116
if (menu == 4)
117
    scr_darkbox_black
scr_darkbox_black

function scr_darkbox_black(arg0, arg1, arg2, arg3) { draw_set_color(c_black); draw_rectangle(arg0 + 20, arg1 + 20, arg2 - 20, arg3 - 20, false); scr_darkbox(arg0, arg1, arg2, arg3); }
(0, 240, 640, 480);
118
if (menu == 0)
119
{
120
    sell = 0;
121
    selling = 0;
122
    sidemessage = 0;
123
    menuc[1] = 0;
124
    menuc[2] = 0;
125
    menuc[3] = 0;
126
    menuc[4] = 0;
127
    if (instance_exists(obj_writer) == false)
128
    {
129
        global.typer = 6;
130
        msgsetloc(0, 
Mini face 3 \t\t*Don't forget to
\tbuy something!
Mini face 1 \tIf you want!
Mini face 2 \tCan I buy
\tsomething too?
"\\m3\t\t*Don't forget to&\tbuy something!&\\m1\tIf you want!&\\m2\tCan I buy&\tsomething too?", "obj_shop_ch2_music_slash_Draw_0_gml_168_0"
);
131
        if (mainmessage == 0)
132
            msgsetloc(0, 
Mini face 1 \t\t*Yo!
Mini face 3 \tWhat's up?
Mini face 2 \tHey!
"\\m1\t\t*Yo!&\\m3\tWhat's up?&\\m2\tHey!", "obj_shop_ch2_music_slash_Draw_0_gml_170_0"
);
133
        if (canUseJukebox == 1)
134
        {
135
            if (mainmessage == 0)
136
                msgsetloc(0, 
Mini face 1 \t\t*Welcome to...
Mini face 3 \tThe Music Room!
Mini face 2 \tWe don't sell
\tanything!
"\\m1\t\t*Welcome to...&\\m3\tThe Music Room!&\\m2\tWe don't sell&\tanything!", "obj_shop_ch2_music_slash_Draw_0_gml_174_0"
);
137
            else
138
                msgsetloc(0, 
Mini face 1 \t\t*Crash!
Mini face 3 \tBang!
Mini face 2 \tBoom!
"\\m1\t\t*Crash!&\\m3\tBang!&\\m2\tBoom!", "obj_shop_ch2_music_slash_Draw_0_gml_175_0"
);
139
            if (mainmessage == 2)
140
                msgsetloc(0, 
Mini face 2 \t\t*Good song.
"\\m2\t\t*Good song.", "obj_shop_ch2_music_slash_Draw_0_gml_176_0"
);
141
        }
142
        global.typer = 78;
143
        instance_create(30, 270, obj_writer);
144
    }
145
    menumax = 3;
146
    draw_set_color(c_white);
147
    scr_84_set_draw_font
scr_84_set_draw_font

function scr_84_set_draw_font(arg0) { global.chemg_font = arg0; draw_set_font(scr_84_get_font(arg0)); }
("mainbig");
148
    if (canUseJukebox == 0)
149
    {
150
        draw_text(480, 260, string_hash_to_newline(stringsetloc(
Buy
"Buy", "obj_shop1_slash_Draw_0_gml_106_0"
)));
151
        draw_text(480, 300, string_hash_to_newline(stringsetloc(
Sell
"Sell", "obj_shop1_slash_Draw_0_gml_107_0"
)));
152
    }
153
    else
154
    {
155
        draw_text(480, 260, stringsetloc(
Play Music
"Play Music", "obj_shop_ch2_music_slash_Draw_0_gml_194_0"
));
156
        draw_text(480, 300, stringsetloc(
Lancer
"Lancer", "obj_shop_ch2_music_slash_Draw_0_gml_195_0"
));
157
    }
158
    draw_text(480, 340, string_hash_to_newline(stringsetloc(
Talk
"Talk", "obj_shop1_slash_Draw_0_gml_108_0"
)));
159
    draw_text(480, 380, string_hash_to_newline(stringsetloc(
Exit
"Exit", "obj_shop1_slash_Draw_0_gml_109_0"
)));
160
    draw_sprite(spr_heart, 0, 450, (135 + (menuc[0] * 20)) * 2);
161
    if (button1_p())
162
    {
163
        onebuffer = 2;
164
        mainmessage = 1;
165
        with (obj_writer)
166
            instance_destroy();
167
        if (canUseJukebox == 0)
168
        {
169
            if (menuc[0] == 0)
170
                menu = 1;
171
            if (menuc[0] == 1)
172
            {
173
                menu = 10;
174
                sidemessage = 0;
175
            }
176
        }
177
        else
178
        {
179
            if (menuc[0] == 0)
180
            {
181
                custommenu = instance_create(0, 0, obj_fusionmenu);
182
                custommenu.type = 5;
183
                if (menuc[0] == 0)
184
                    snd_free_all();
185
                if (menuc[0] == 1)
186
                    custommenu.subtype = 1;
187
                menu = 99;
188
            }
189
            if (menuc[0] == 1)
190
            {
191
                snd_play(snd_splat);
192
                mainmessage = 2;
193
            }
194
        }
195
        if (menuc[0] == 2)
196
        {
197
            if (canUseJukebox == 0)
198
            {
199
                menu = 3;
200
            }
201
            else
202
            {
203
                menu = 4;
204
                sell = 1;
205
            }
206
        }
207
        if (menuc[0] == 3)
208
        {
209
            sell = 2;
210
            menu = 4;
211
        }
212
    }
213
}
214
if (menu == 1 || menu == 2)
215
{
216
    draw_set_color(c_white);
217
    scr_84_set_draw_font
scr_84_set_draw_font

function scr_84_set_draw_font(arg0) { global.chemg_font = arg0; draw_set_font(scr_84_get_font(arg0)); }
("mainbig");
218
    for (i = 0; i < itemtotal; i += 1)
219
    {
220
        draw_text(60, 260 + (i * 40), string_hash_to_newline(shopitemname[i]));
221
        draw_text(300, 260 + (i * 40), string_hash_to_newline(stringsetsubloc("$~1", string(buyvalue[i]), "obj_shop_ch2_music_slash_Draw_0_gml_250_0")));
222
    }
223
    draw_text(60, 260 + (itemtotal * 40), string_hash_to_newline(stringsetloc(
Exit
"Exit", "obj_shop1_slash_Draw_0_gml_139_0"
)));
224
    if (menu == 1)
225
    {
226
        menumax = 4;
227
        if (instance_exists(obj_writer) == false)
228
        {
229
            if (sidemessage == 0)
230
                msgsetloc(0, 
Mini face 3 \t\t*Take
\tyour
\tpick!
"\\m3\t\t*Take&\tyour&\tpick!", "obj_shop_ch2_music_slash_Draw_0_gml_262_0"
);
231
            if (sidemessage == 1)
232
            {
233
                _rr = floor(random(10));
234
                msgsetloc(0, 
Mini face 1 \t\t*Thanks,
\tguys!
"\\m1\t\t*Thanks,&\tguys!", "obj_shop_ch2_music_slash_Draw_0_gml_266_0"
);
235
                if (_rr == 0)
236
                    msgsetloc(0, 
Mini face 2 \t\t*I can't
\tsee.
"\\m2\t\t*I can't&\tsee.", "obj_shop_ch2_music_slash_Draw_0_gml_267_0"
);
237
            }
238
            if (sidemessage == 2)
239
                msgsetloc(0, 
Mini face 3 \t\t*Don't
\tchicken
\tout!
"\\m3\t\t*Don't&\tchicken&\tout!", "obj_shop_ch2_music_slash_Draw_0_gml_270_0"
);
240
            if (sidemessage == 3)
241
                msgsetloc(0, 
Mini face 3 \t\t*Not
\tenough
\tcash!
"\\m3\t\t*Not&\tenough&\tcash!", "obj_shop_ch2_music_slash_Draw_0_gml_271_0"
);
242
            if (sidemessage == 4)
243
                msgsetloc(0, 
Mini face 3 \t\t*Your
\tpockets
\tare
\tfull.
"\\m3\t\t*Your&\tpockets&\tare&\tfull.", "obj_shop_ch2_music_slash_Draw_0_gml_272_0"
);
244
            if (sidemessage == 5)
245
                msgsetloc(0, 
Mini face 3 \t\t*Cool!
\tIt's in
\tyour
\tSTORAGE.
"\\m3\t\t*Cool!&\tIt's in&\tyour&\tSTORAGE.", "obj_shop_ch2_music_slash_Draw_0_gml_273_0"
);
246
            if (murder == 1)
247
                global.msg[0] = stringsetloc(
Wait for input*
"/*", "obj_shop1_slash_Draw_0_gml_153_0"
);
248
            global.typer = 78;
249
            instance_create(450, 260, obj_writer);
250
        }
251
        draw_sprite(spr_heart, 0, 30, 270 + (menuc[1] * 40));
252
        if (button1_p() && onebuffer < 0)
253
        {
254
            menu = 2;
255
            onebuffer = 2;
256
            with (obj_writer)
257
                instance_destroy();
258
            if (menuc[1] == menumax)
259
                menu = 0;
260
        }
261
        if (button2_p() && twobuffer < 0 && onebuffer < 2)
262
        {
263
            menu = 0;
264
            twobuffer = 2;
265
            minimenuy = 220;
266
            with (obj_writer)
267
                instance_destroy();
268
        }
269
        menuc[2] = 0;
270
    }
271
    if (menu == 2)
272
    {
273
        menumax = 1;
274
        draw_set_color(c_white);
275
        scr_84_set_draw_font
scr_84_set_draw_font

function scr_84_set_draw_font(arg0) { global.chemg_font = arg0; draw_set_font(scr_84_get_font(arg0)); }
("mainbig");
276
        var y1_off = langopt(260, 290);
277
        var y2_off = langopt(290, 260);
278
        draw_text(460, y1_off, string_hash_to_newline(stringsetloc(
Buy it for
"Buy it for", "obj_shop1_slash_Draw_0_gml_167_0"
)));
279
        draw_text(460, y2_off, string_hash_to_newline(stringsetsubloc("$~1 ?", string(buyvalue[menuc[1]]), "obj_shop_ch2_music_slash_Draw_0_gml_291_0")));
280
        draw_text(480, 340, string_hash_to_newline(stringsetloc(
Yes
"Yes", "obj_shop1_slash_Draw_0_gml_169_0"
)));
281
        draw_text(480, 370, string_hash_to_newline(stringsetloc(
No
"No", "obj_shop1_slash_Draw_0_gml_170_0"
)));
282
        draw_sprite(spr_heart, 0, 450, 350 + (menuc[2] * 30));
283
        if (button2_p() && twobuffer < 0)
284
        {
285
            menu = 1;
286
            sidemessage = 2;
287
            twobuffer = 2;
288
            onebuffer = 2;
289
        }
290
        if (button1_p() && onebuffer < 0 && twobuffer < 0)
291
        {
292
            if (menuc[2] == 0)
293
            {
294
                afford = 0;
295
                if (global.gold >= buyvalue[menuc[1]])
296
                    afford = 1;
297
                if (afford == 1)
298
                {
299
                    _pocketed = 0;
300
                    if (itemtype[menuc[1]] == "item")
301
                        scr_itemget
scr_itemget

function scr_itemget(arg0) { var __i = 0; var loop = 1; noroom = 0; _pocketed = 0; _noroominventory = 0; global.item[12] = 999; while (loop == 1) { if (global.item[__i] == 0) { global.item[__i] = arg0; break; } if (__i == 12) { _noroominventory = 1; noroom = 1; for (var __j = 0; __j < global.flag[64 storage_size]; __j++) { if (global.pocketitem[__j] == 0) { global.pocketitem[__j] = arg0; _pocketed = 1; noroom = 0; break; } } break; } __i += 1; } script_execute(scr_iteminfo_all); }
(item[menuc[1]]);
302
                    if (itemtype[menuc[1]] == "weapon")
303
                        scr_weaponget
scr_weaponget

function scr_weaponget(arg0) { noroom = 0; var legacy = 0; var __i = 0; if (legacy == 0) { var __itemcount = 0; __weapon[0] = arg0; for (__i = 0; __i < 48; __i++) { if (global.weapon[__i] != 0) { __weapon[__itemcount + 1] = global.weapon[__i]; __itemcount++; } } if (__itemcount >= 48) { noroom = 1; } else { for (__i = 0; __i < 48; __i++) { if (__i <= __itemcount) global.weapon[__i] = __weapon[__i]; else global.weapon[__i] = 0; } } } else if (legacy) { loop = 1; global.weapon[48] = 999; while (loop == 1) { if (global.weapon[__i] == 0) { global.weapon[__i] = arg0; break; } if (__i == 48) { noroom = 1; break; } __i += 1; } } script_execute(scr_weaponinfo_all); }
(item[menuc[1]]);
304
                    if (itemtype[menuc[1]] == "armor")
305
                        scr_armorget
scr_armorget

function scr_armorget(arg0) { noroom = 0; var legacy = 0; var __i = 0; if (legacy == 0) { var __itemcount = 0; __armor[0] = arg0; for (__i = 0; __i < 48; __i++) { if (global.armor[__i] != 0) { __armor[__itemcount + 1] = global.armor[__i]; __itemcount++; } } if (__itemcount >= 48) { noroom = 1; } else { for (__i = 0; __i < 48; __i++) { if (__i <= __itemcount) global.armor[__i] = __armor[__i]; else global.armor[__i] = 0; } } } else if (legacy) { loop = 1; global.armor[48] = 999; while (loop == 1) { if (global.armor[__i] == 0) { global.armor[__i] = arg0; break; } if (__i == 48) { noroom = 1; break; } __i += 1; } } script_execute(scr_armorinfo_all); }
(item[menuc[1]]);
306
                    if (noroom == 0)
307
                    {
308
                        global.gold -= buyvalue[menuc[1]];
309
                        snd_play(snd_locker);
310
                        if (_pocketed == 1)
311
                            sidemessage = 5;
312
                        else
313
                            sidemessage = 1;
314
                    }
315
                    if (noroom == 1)
316
                        sidemessage = 4;
317
                }
318
                else
319
                {
320
                    sidemessage = 3;
321
                }
322
            }
323
            if (menuc[2] == 1)
324
                sidemessage = 2;
325
            menu = 1;
326
        }
327
    }
328
    if (menuc[1] != 4)
329
    {
330
        if (minimenuy <= 20)
331
            minimenuy = 20;
332
        if (minimenuy > 20)
333
            minimenuy -= 5;
334
        if (minimenuy > 50)
335
            minimenuy -= 5;
336
        if (minimenuy > 100)
337
            minimenuy -= 8;
338
        if (minimenuy > 150)
339
            minimenuy -= 10;
340
    }
341
    else if (minimenuy < 200)
342
    {
343
        minimenuy += 40;
344
    }
345
    if (minimenuy >= 200)
346
        minimenuy = 200;
347
}
348
if (menu == 3)
349
{
350
    menumax = 4;
351
    draw_set_color(c_white);
352
    scr_84_set_draw_font
scr_84_set_draw_font

function scr_84_set_draw_font(arg0) { global.chemg_font = arg0; draw_set_font(scr_84_get_font(arg0)); }
("mainbig");
353
    draw_text(80, 260, string_hash_to_newline(stringsetloc(
About yourselves
"About yourselves", "obj_shop_ch2_music_slash_Draw_0_gml_343_0"
)));
354
    draw_text(80, 300, stringsetloc(
Performance
"Performance", "obj_shop_ch2_music_slash_Draw_0_gml_344_0"
));
355
    draw_text(80, 340, stringsetloc(
About Queen
"About Queen", "obj_shop_ch2_music_slash_Draw_0_gml_345_0"
));
356
    draw_text(80, 380, stringsetloc(
Junk Work
"Junk Work", "obj_shop_ch2_music_slash_Draw_0_gml_346_0"
));
357
    draw_set_color(c_white);
358
    draw_text(80, 420, string_hash_to_newline(stringsetloc(
Exit
"Exit", "obj_shop1_slash_Draw_0_gml_240_0"
)));
359
    if (instance_exists(obj_writer) == false)
360
    {
361
        global.msg[0] = stringsetloc(
Mini face 1 \t\t*Let's
\ttrade
\tinfo!
"\\m1\t\t*Let's&\ttrade&\tinfo!", "obj_shop_ch2_music_slash_Draw_0_gml_357_0"
);
362
        global.typer = 78;
363
        instance_create(440, 260, obj_writer);
364
    }
365
    draw_sprite(spr_heart, 0, 50, 270 + (menuc[3] * 40));
366
    if (button1_p() && onebuffer < 0)
367
    {
368
        onebuffer = 2;
369
        with (obj_writer)
370
            instance_destroy();
371
        if (menuc[3] < menumax)
372
        {
373
            sell = menuc[3] + 3;
374
            menu = 4;
375
        }
376
        else
377
        {
378
            menu = 0;
379
        }
380
    }
381
    else if (button2_p() && twobuffer < 0 && onebuffer < 0)
382
    {
383
        twobuffer = 2;
384
        menu = 0;
385
        with (obj_writer)
386
            instance_destroy();
387
    }
388
}
389
if (menu == 10)
390
{
391
    menuc[11] = 0;
392
    menuc[12] = 0;
393
    menuc[13] = 0;
394
    menumax = 4;
395
    draw_set_color(c_white);
396
    scr_84_set_draw_font
scr_84_set_draw_font

function scr_84_set_draw_font(arg0) { global.chemg_font = arg0; draw_set_font(scr_84_get_font(arg0)); }
("mainbig");
397
    draw_text(80, 260, string_hash_to_newline(stringsetloc(
Sell Items
"Sell Items", "obj_shop1_slash_Draw_0_gml_278_0"
)));
398
    draw_text(80, 300, string_hash_to_newline(stringsetloc(
Sell Weapons
"Sell Weapons", "obj_shop1_slash_Draw_0_gml_279_0"
)));
399
    draw_text(80, 340, string_hash_to_newline(stringsetloc(
Sell Armor
"Sell Armor", "obj_shop1_slash_Draw_0_gml_280_0"
)));
400
    draw_text(80, 380, string_hash_to_newline(stringsetloc(
Sell Pocket Items
"Sell Pocket Items", "obj_shop_ch2_music_slash_Draw_0_gml_394_0"
)));
401
    draw_text(80, 420, string_hash_to_newline(stringsetloc(
Return
"Return", "obj_shop_ch2_music_slash_Draw_0_gml_395_0"
)));
402
    if (instance_exists(obj_writer) == false)
403
    {
404
        if (sidemessage == 0)
405
            msgsetloc(0, 
Mini face 1 \t\t*We'll
\ttake
\tit for
\tyou!
"\\m1\t\t*We'll&\ttake&\tit for&\tyou!", "obj_shop_ch2_music_slash_Draw_0_gml_399_0"
);
406
        if (sidemessage == 1)
407
            msgsetloc(0, 
Mini face 2 \t\t*That's
\tall you
\thad?
"\\m2\t\t*That's&\tall you&\thad?", "obj_shop_ch2_music_slash_Draw_0_gml_400_0"
);
408
        if (sidemessage == 2)
409
            msgsetloc(0, 
Mini face 2 \t\t*You
\tgot
\tnothin!
"\\m2\t\t*You&\tgot&\tnothin!", "obj_shop_ch2_music_slash_Draw_0_gml_401_0"
);
410
        global.typer = 78;
411
        instance_create(460, 260, obj_writer);
412
    }
413
    draw_sprite(spr_heart, 0, 50, 270 + (menuc[10] * 40));
414
    if (button1_p() && onebuffer < 0)
415
    {
416
        pagemax = 0;
417
        sidemessage2 = 0;
418
        onebuffer = 2;
419
        with (obj_writer)
420
            instance_destroy();
421
        can = 1;
422
        idealmenu = menuc[10] + 11;
423
        if (idealmenu == 11)
424
        {
425
            scr_itemcheck
scr_itemcheck

function scr_itemcheck(arg0) { haveit = 0; itemcount = 0; for (var __i = 0; __i < 12; __i += 1) { if (global.item[__i] == arg0) haveit = 1; if (global.item[__i] == arg0) itemcount += 1; } return haveit; }
(0);
426
            if (itemcount == 12)
427
            {
428
                sidemessage = 2;
429
                can = 0;
430
            }
431
            nothingcount = itemcount;
432
            scr_iteminfo_all
scr_iteminfo_all

function scr_iteminfo_all() { for (i = 0; i < 12; i += 1) { itemid = global.item[i]; scr_iteminfo(itemid); global.itemnameb[i] = itemnameb; global.itemdescb[i] = itemdescb; global.itemvalue[i] = value; global.itemusable[i] = usable; } }
();
433
            selltype = "item";
434
            selltotal = 12;
435
            for (i = 0; i < selltotal; i++)
436
            {
437
                itemsellvalue[i] = global.itemvalue[i];
438
                itemsellname[i] = global.itemnameb[i];
439
            }
440
        }
441
        if (idealmenu == 12)
442
        {
443
            scr_weaponcheck_inventory
scr_weaponcheck_inventory

function scr_weaponcheck_inventory(arg0) { haveit = 0; itemcount = 0; for (i = 0; i < 48; i += 1) { if (global.weapon[i] == arg0) haveit = 1; if (global.weapon[i] == arg0) itemcount += 1; } return haveit; }
(0);
444
            if (itemcount == 48)
445
            {
446
                sidemessage = 2;
447
                can = 0;
448
            }
449
            scr_weaponinfo_all
scr_weaponinfo_all

function scr_weaponinfo_all() { for (i = 0; i < 48; i += 1) { scr_weaponinfo(global.weapon[i]); weaponname[i] = weaponnametemp; weapondesc[i] = weapondesctemp; wmessage2[i] = wmessage2temp; wmessage3[i] = wmessage3temp; wmessage4[i] = wmessage4temp; weaponat[i] = weaponattemp; weapondf[i] = weapondftemp; weaponmag[i] = weaponmagtemp; weaponbolts[i] = weaponboltstemp; weaponstyle[i] = weaponstyletemp; weapongrazeamt[i] = weapongrazeamttemp; weapongrazesize[i] = weapongrazesizetemp; weaponchar1[i] = weaponchar1temp; weaponchar2[i] = weaponchar2temp; weaponchar3[i] = weaponchar3temp; weaponchar4[i] = weaponchar4temp; weaponvalue[i] = value; weaponability[i] = weaponabilitytemp; weaponabilityicon[i] = weaponabilityicontemp; weaponicon[i] = weaponicontemp; } }
();
450
        }
451
        if (idealmenu == 13)
452
        {
453
            scr_armorcheck_inventory
scr_armorcheck_inventory

function scr_armorcheck_inventory(arg0) { haveit = 0; itemcount = 0; for (i = 0; i < 48; i += 1) { if (global.armor[i] == arg0) haveit = 1; if (global.armor[i] == arg0) itemcount += 1; } return haveit; }
(0);
454
            if (itemcount == 48)
455
            {
456
                sidemessage = 2;
457
                can = 0;
458
            }
459
            scr_armorinfo_all
scr_armorinfo_all

function scr_armorinfo_all() { for (i = 0; i < 48; i += 1) { scr_armorinfo(global.armor[i]); armorname[i] = armornametemp; armordesc[i] = armordesctemp; amessage2[i] = amessage2temp; amessage3[i] = amessage3temp; amessage4[i] = amessage4temp; armorat[i] = armorattemp; armordf[i] = armordftemp; armormag[i] = armormagtemp; armorbolts[i] = armorboltstemp; armorgrazeamt[i] = armorgrazeamttemp; armorgrazesize[i] = armorgrazesizetemp; armorchar1[i] = armorchar1temp; armorchar2[i] = armorchar2temp; armorchar3[i] = armorchar3temp; armorchar4[i] = armorchar4temp; armorvalue[i] = value; armorability[i] = armorabilitytemp; armorabilityicon[i] = armorabilityicontemp; armoricon[i] = armoricontemp; armorelement[i] = armorelementtemp; armorelementamount[i] = armorelementamounttemp; } }
();
460
        }
461
        if (idealmenu == 14)
462
        {
463
            scr_itemcheck_pocket
scr_itemcheck_pocket

function scr_itemcheck_pocket(arg0) { haveit = 0; itemcount = 0; for (var __i = 0; __i < global.flag[64 storage_size]; __i += 1) { if (global.pocketitem[__i] == arg0) haveit = 1; if (global.pocketitem[__i] == arg0) itemcount += 1; } return haveit; }
(0);
464
            if (itemcount == global.flag[64 storage_size])
465
            {
466
                sidemessage = 2;
467
                can = 0;
468
            }
469
            selltype = "pocket";
470
            nothingcount = 0;
471
            selltotal = global.flag[64 storage_size];
472
            for (i = 0; i < global.flag[64 storage_size]; i++)
473
            {
474
                scr_iteminfo
scr_iteminfo

function scr_iteminfo(arg0) { usable = 0; replaceable = 0; value = 0; itemtarget = 0; itemnameb = " "; itemdescb = " "; switch (arg0) { case 0: itemnameb = " "; itemdescb = "---"; break; case 1: itemnameb = stringsetloc(
Dark Candy
"Dark Candy", "scr_iteminfo_slash_scr_iteminfo_gml_15_0"
); itemdescb = stringsetloc(
Heals#40HP
"Heals#40HP", "scr_iteminfo_slash_scr_iteminfo_gml_16_0"
); itemtarget = 1; value = 25; usable = 1; break; case 2: itemnameb = stringsetloc(
ReviveMint
"ReviveMint", "scr_iteminfo_slash_scr_iteminfo_gml_22_0"
); itemdescb = stringsetloc(
Heal#Downed#Ally
"Heal#Downed#Ally", "scr_iteminfo_slash_scr_iteminfo_gml_23_0"
); itemtarget = 1; value = 400; usable = 1; break; case 3: itemnameb = stringsetloc(
Glowshard
"Glowshard", "scr_iteminfo_slash_scr_iteminfo_gml_29_0"
); itemdescb = stringsetloc(
Sell#at#shops
"Sell#at#shops", "scr_iteminfo_slash_scr_iteminfo_gml_30_0"
); itemtarget = 0; value = 200 + (global.chapter * 100); usable = 0; break; case 4: itemnameb = stringsetloc(
Manual
"Manual", "scr_iteminfo_slash_scr_iteminfo_gml_36_0"
); itemdescb = stringsetloc(
Read#out of#battle
"Read#out of#battle", "scr_iteminfo_slash_scr_iteminfo_gml_37_0"
); itemtarget = 2; value = 1; usable = 0; break; case 5: itemnameb = stringsetloc(
BrokenCake
"BrokenCake", "scr_iteminfo_slash_scr_iteminfo_gml_43_0"
); itemdescb = stringsetloc(
Heals#20HP
"Heals#20HP", "scr_iteminfo_slash_scr_iteminfo_gml_44_0"
); itemtarget = 1; value = 5; usable = 1; break; case 6: itemnameb = stringsetloc(
Top Cake
"Top Cake", "scr_iteminfo_slash_scr_iteminfo_gml_50_0"
); itemdescb = stringsetloc(
Heals#team#160HP
"Heals#team#160HP", "scr_iteminfo_slash_scr_iteminfo_gml_51_0"
); itemtarget = 2; value = 150; usable = 1; break; case 7: var healamount = (global.chapter == 1) ? 80 : 140; itemnameb = stringsetloc(
Spincake
"Spincake", "scr_iteminfo_slash_scr_iteminfo_gml_58_0"
); itemdescb = stringsetsubloc("Heals#team#~1HP", string(healamount), "scr_iteminfo_slash_scr_iteminfo_gml_59_0"); itemtarget = 2; value = 5; usable = 1; break; case 8: itemnameb = stringsetloc(
Darkburger
"Darkburger", "scr_iteminfo_slash_scr_iteminfo_gml_65_0"
); itemdescb = stringsetloc(
Heals#70HP
"Heals#70HP", "scr_iteminfo_slash_scr_iteminfo_gml_66_0"
); itemtarget = 1; value = 70; usable = 1; break; case 9: itemnameb = stringsetloc(
LancerCookie
"LancerCookie", "scr_iteminfo_slash_scr_iteminfo_gml_72_0"
); itemdescb = stringsetloc(
Heals#50HP
"Heals#50HP", "scr_iteminfo_slash_scr_iteminfo_gml_73_0"
); itemtarget = 1; value = 10; usable = 1; break; case 10: itemnameb = stringsetloc(
GigaSalad
"GigaSalad", "scr_iteminfo_slash_scr_iteminfo_gml_79_0"
); itemdescb = stringsetloc(
Heals#4HP
"Heals#4HP", "scr_iteminfo_slash_scr_iteminfo_gml_80_0"
); itemtarget = 1; value = 10; usable = 1; break; case 11: itemnameb = stringsetloc(
ClubsSandwich
"ClubsSandwich", "scr_iteminfo_slash_scr_iteminfo_gml_86_0"
); itemdescb = stringsetloc(
Heals#team#70HP
"Heals#team#70HP", "scr_iteminfo_slash_scr_iteminfo_gml_87_0"
); itemtarget = 2; value = 70; usable = 1; break; case 12: itemnameb = stringsetloc(
HeartsDonut
"HeartsDonut", "scr_iteminfo_slash_scr_iteminfo_gml_93_0"
); itemdescb = stringsetloc(
Healing#varies
"Healing#varies", "scr_iteminfo_slash_scr_iteminfo_gml_94_0"
); itemtarget = 1; value = 40; usable = 1; break; case 13: itemnameb = stringsetloc(
ChocDiamond
"ChocDiamond", "scr_iteminfo_slash_scr_iteminfo_gml_100_0"
); ...
(global.pocketitem[i]);
475
                itemsellvalue[i] = value;
476
                itemsellname[i] = itemnameb;
477
            }
478
            idealmenu = 11;
479
        }
480
        if (menuc[10] < menumax)
481
        {
482
            if (can == 1)
483
                menu = idealmenu;
484
            sidemessage1 = 0;
485
        }
486
        else
487
        {
488
            menu = 0;
489
        }
490
        submenu = 0;
491
        submenuc[1] = 0;
492
    }
493
    if (button2_p() && twobuffer < 0 && onebuffer < 0)
494
    {
495
        twobuffer = 2;
496
        menu = 0;
497
        with (obj_writer)
498
            instance_destroy();
499
    }
500
}
501
if (menu == 11 || menu == 12 || menu == 13)
502
{
503
    if (instance_exists(obj_writer) == false)
504
    {
505
        if (sidemessage2 == 0 && menu == 11)
506
            msgsetloc(0, 
Mini face 1 \t\t*OK,
\thit us
\twith an
\tITEM!
"\\m1\t\t*OK,&\thit us&\twith an&\tITEM!", "obj_shop_ch2_music_slash_Draw_0_gml_487_0"
);
507
        if (sidemessage2 == 0 && menu == 12)
508
            msgsetloc(0, 
Mini face 1 \t\t*OK,
\tshow us
\tyour
\tWEAPON!
"\\m1\t\t*OK,&\tshow us&\tyour&\tWEAPON!", "obj_shop_ch2_music_slash_Draw_0_gml_488_0"
);
509
        if (sidemessage2 == 0 && menu == 13)
510
            msgsetloc(0, 
Mini face 1 \t\t*OK,
\thit us
\twith an
\tARMOR!
"\\m1\t\t*OK,&\thit us&\twith an&\tARMOR!", "obj_shop_ch2_music_slash_Draw_0_gml_489_0"
);
511
        if (sidemessage2 == 1)
512
            msgsetloc(0, 
Mini face 1 \t\t*Sweet!
\tThis'll
\tbe great
\tscrap!
"\\m1\t\t*Sweet!&\tThis'll&\tbe great&\tscrap!", "obj_shop_ch2_music_slash_Draw_0_gml_490_0"
);
513
        if (sidemessage2 == 2)
514
            msgsetloc(0, 
Mini face 1 \t\t*OK,
\thold
\tonto
\tthat.
"\\m1\t\t*OK,&\thold&\tonto&\tthat.", "obj_shop_ch2_music_slash_Draw_0_gml_491_0"
);
515
        if (sidemessage2 == 3)
516
            msgsetloc(0, 
Mini face 1 \t\t*Maybe
\tbetter
\tkeep
\tthat.
"\\m1\t\t*Maybe&\tbetter&\tkeep&\tthat.", "obj_shop_ch2_music_slash_Draw_0_gml_492_0"
);
517
        if (sidemessage2 == 4)
518
            msgsetloc(0, 
Mini face 3 \t\t*That's
\tnothin!
"\\m3\t\t*That's&\tnothin!", "obj_shop_ch2_music_slash_Draw_0_gml_493_0"
);
519
        global.typer = 78;
520
        instance_create(450, 260, obj_writer);
521
    }
522
}
523
scr_shopmenu
scr_shopmenu

function scr_shopmenu(arg0) { if (arg0 == 0) { if (menu == 1 || menu == 2) { scr_darkbox_black(400, minimenuy, 640, 255); draw_set_color(c_white); scr_84_set_draw_font("mainbig"); if (menuc[1] == 0) draw_text(440, minimenuy + 28, string_hash_to_newline(shopdesc[0])); if (menuc[1] == 1) draw_text(440, minimenuy + 28, string_hash_to_newline(shopdesc[1])); if (menuc[1] == 2) draw_text(440, minimenuy + 28, string_hash_to_newline(shopdesc[2])); if (menuc[1] == 3) draw_text(440, minimenuy + 28, string_hash_to_newline(shopdesc[3])); scr_84_set_draw_font("dotumche"); if (itemtype[menuc[1]] == "weapon" || itemtype[menuc[1]] == "armor") { for (i = 0; i < 3; i += 1) { can_index = 0; facetype = spr_headkris; which = global.char[i]; if (global.char[i] == 1) facetype = spr_headkris; if (global.char[i] == 2) facetype = spr_headsusie; if (global.char[i] == 3) facetype = spr_headralsei; if (which != 0) { if (i == 0) { locx = 0; locy = 0; } if (i == 1) { locx = 100; locy = 0; } if (i == 2) { locx = 0; locy = 45; } if (canequip[menuc[1]][which] == 0) can_index = 8; draw_sprite(facetype, can_index, 426 + locx, minimenuy + 140 + locy); if (itemtype[menuc[1]] == "weapon" && can_index != 8) { draw_set_color(c_white); sum[0] = itematk[menuc[1]] - global.itemat[which][0]; sum[1] = itemmagic[menuc[1]] - global.itemmag[which][0]; for (j = 0; j < 2; j += 1) { dcolor = c_white; addt = ""; draw_set_color(c_white); if (sum[j] > 0) { draw_set_color(c_yellow); addt = "+"; } if (sum[j] < 0) draw_set_color(c_aqua); draw_sprite_ext(spr_shopicon, j, 470 + locx, minimenuy + locy + 135 + (20 * j), 1, 1, 0, dcolor, 1); draw_text(490 + locx, minimenuy + locy + 135 + (20 * j), string_hash_to_newline(addt + string(sum[j]))); } } if (itemtype[menuc[1]] == "armor" && can_index != 8) { sum[0] = itemdef[menuc[1]] - global.itemdf[which][1]; sum[1] = itemdef[menuc[1]] - global.itemdf[which][2]; for (j = 0; j < 2; j += 1) { dcolor = c_white; addt = ""; draw_set_color(c_white); if (sum[j] > 0) { draw_set_color(c_yellow); addt = "+"; } if (sum[j] < 0) draw_set_color(c_aqua); draw_sprite_ext(spr_shopicon, 2 + j, 470 + locx, minimenuy + locy + 135 + (20 * j), 1, 1, 0, dcolor, 1); draw_text(490 + locx, minimenuy + 135 + (20 * j) + locy, string_hash_to_newline(addt + string(sum[j]))); } } } } } } } if (arg0 == 4) { if (menu == 11 || menu == 15) { ...
(4);
524
if (menu == 15 || menu == 16 || menu == 17)
525
{
526
    menumax = 1;
527
    draw_set_color(c_white);
528
    scr_84_set_draw_font
scr_84_set_draw_font

function scr_84_set_draw_font(arg0) { global.chemg_font = arg0; draw_set_font(scr_84_get_font(arg0)); }
("mainbig");
529
    var y1_off = langopt(260, 290);
530
    var y2_off = langopt(290, 260);
531
    draw_text(460, y1_off, string_hash_to_newline(stringsetloc(
Sell it for
"Sell it for", "obj_shop1_slash_Draw_0_gml_365_0"
)));
532
    draw_text(460, y2_off, string_hash_to_newline(stringsetsubloc("$~1 ?", string(sellvalue), "obj_shop_ch2_music_slash_Draw_0_gml_508_0")));
533
    draw_text(480, 340, string_hash_to_newline(stringsetloc(
Yes
"Yes", "obj_shop1_slash_Draw_0_gml_367_0"
)));
534
    draw_text(480, 370, string_hash_to_newline(stringsetloc(
No
"No", "obj_shop1_slash_Draw_0_gml_368_0"
)));
535
    draw_sprite(spr_heart, 0, 450, 350 + (menuc[menu] * 30));
536
}
537
scr_shopmenu
scr_shopmenu

function scr_shopmenu(arg0) { if (arg0 == 0) { if (menu == 1 || menu == 2) { scr_darkbox_black(400, minimenuy, 640, 255); draw_set_color(c_white); scr_84_set_draw_font("mainbig"); if (menuc[1] == 0) draw_text(440, minimenuy + 28, string_hash_to_newline(shopdesc[0])); if (menuc[1] == 1) draw_text(440, minimenuy + 28, string_hash_to_newline(shopdesc[1])); if (menuc[1] == 2) draw_text(440, minimenuy + 28, string_hash_to_newline(shopdesc[2])); if (menuc[1] == 3) draw_text(440, minimenuy + 28, string_hash_to_newline(shopdesc[3])); scr_84_set_draw_font("dotumche"); if (itemtype[menuc[1]] == "weapon" || itemtype[menuc[1]] == "armor") { for (i = 0; i < 3; i += 1) { can_index = 0; facetype = spr_headkris; which = global.char[i]; if (global.char[i] == 1) facetype = spr_headkris; if (global.char[i] == 2) facetype = spr_headsusie; if (global.char[i] == 3) facetype = spr_headralsei; if (which != 0) { if (i == 0) { locx = 0; locy = 0; } if (i == 1) { locx = 100; locy = 0; } if (i == 2) { locx = 0; locy = 45; } if (canequip[menuc[1]][which] == 0) can_index = 8; draw_sprite(facetype, can_index, 426 + locx, minimenuy + 140 + locy); if (itemtype[menuc[1]] == "weapon" && can_index != 8) { draw_set_color(c_white); sum[0] = itematk[menuc[1]] - global.itemat[which][0]; sum[1] = itemmagic[menuc[1]] - global.itemmag[which][0]; for (j = 0; j < 2; j += 1) { dcolor = c_white; addt = ""; draw_set_color(c_white); if (sum[j] > 0) { draw_set_color(c_yellow); addt = "+"; } if (sum[j] < 0) draw_set_color(c_aqua); draw_sprite_ext(spr_shopicon, j, 470 + locx, minimenuy + locy + 135 + (20 * j), 1, 1, 0, dcolor, 1); draw_text(490 + locx, minimenuy + locy + 135 + (20 * j), string_hash_to_newline(addt + string(sum[j]))); } } if (itemtype[menuc[1]] == "armor" && can_index != 8) { sum[0] = itemdef[menuc[1]] - global.itemdf[which][1]; sum[1] = itemdef[menuc[1]] - global.itemdf[which][2]; for (j = 0; j < 2; j += 1) { dcolor = c_white; addt = ""; draw_set_color(c_white); if (sum[j] > 0) { draw_set_color(c_yellow); addt = "+"; } if (sum[j] < 0) draw_set_color(c_aqua); draw_sprite_ext(spr_shopicon, 2 + j, 470 + locx, minimenuy + locy + 135 + (20 * j), 1, 1, 0, dcolor, 1); draw_text(490 + locx, minimenuy + 135 + (20 * j) + locy, string_hash_to_newline(addt + string(sum[j]))); } } } } } } } if (arg0 == 4) { if (menu == 11 || menu == 15) { ...
(5);
538
if (menu == 4)
539
{
540
    if (sell == 0)
541
        menu = 0;
542
    if (instance_exists(obj_writer) == false && selling == 0)
543
    {
544
        selling = 1;
545
        if (sell == 1)
546
        {
547
            msgsetloc(0, 
Mini face 3 \t\t*Nice town,Delay 11 chief.
Mini face 1 \tI think we're gonna like it
\there!
Mini face 2 \tCool city.Wait for input
"\\m3\t\t*Nice town^1, chief.&\\m1\tI think we're gonna like it&\there!&\\m2\tCool city./", "obj_shop_ch2_music_slash_Draw_0_gml_532_0"
);
548
            msgnextloc(
Mini face 1 \t\t*As thanks,Delay 11 you can listen to
\tall sorts of songs here.Wait for input
"\\m1\t\t*As thanks^1, you can listen to&\tall sorts of songs here./", "obj_shop_ch2_music_slash_Draw_0_gml_533_0"
);
549
            msgnextloc(
Mini face 3 \t\t*Don't think it'll be cheap,Delay 11
\tthough!
Mini face 2 \tIt's free.
Mini face 3 \tWhat!?Wait for inputClose Message
"\\m3\t\t*Don't think it'll be cheap^1,&\tthough!&\\m2\tIt's free.&\\m3\tWhat!?/%", "obj_shop_ch2_music_slash_Draw_0_gml_534_0"
);
550
        }
551
        if (sell == 2)
552
            msgsetloc(0, 
Mini face 1 \t\t*See ya!
Mini face 3 \tSmell ya!
Mini face 2 \tHear ya!Wait for inputClose Message
"\\m1\t\t*See ya!&\\m3\tSmell ya!&\\m2\tHear ya!/%", "obj_shop_ch2_music_slash_Draw_0_gml_540_0"
);
553
        if (sell == 3)
554
        {
555
            msgsetloc(0, 
Mini face 1 \t\t*I'm Sweet.
Mini face 3 \tThe ladies call me Cap'n!
Mini face 2 \tK_K!Wait for input
"\\m1\t\t*I'm Sweet.&\\m3\tThe ladies call me Cap'n!&\\m2\tK_K!/", "obj_shop_ch2_music_slash_Draw_0_gml_546_0"
);
556
            msgnextloc(
Mini face 1 \t\t*We used to work the sound in
\tthis town.
Mini face 3 \t... until Queen came around.
Mini face 2 \t(K_K is short for Cakes.)Wait for input
"\\m1\t\t*We used to work the sound in&\tthis town.&\\m3\t... until Queen came around.&\\m2\t(K_K is short for Cakes.)/", "obj_shop_ch2_music_slash_Draw_0_gml_547_0"
);
557
            msgnextloc(
Mini face 1 \t\t*She made music against the law.
Mini face 2 \tUnless you make a song she likes.
Mini face 3 \tBut the only JUNK she enjoys...Wait for input
"\\m1\t\t*She made music against the law.&\\m2\tUnless you make a song she likes.&\\m3\tBut the only JUNK she enjoys.../", "obj_shop_ch2_music_slash_Draw_0_gml_548_0"
);
558
            msgnextloc(
Mini face 1 \t\t*Are reverse diss-tracks, where
\tthe vocalist puts themselves
\tdown, and praises Queen...
Mini face 3 \tOr noise music.Wait for input
"\\m1\t\t*Are reverse diss-tracks, where&\tthe vocalist puts themselves&\tdown, and praises Queen...&\\m3\tOr noise music./", "obj_shop_ch2_music_slash_Draw_0_gml_549_0"
);
559
            msgnextloc(
Mini face 1 \t\t*But even if Queenie tries to put
\ta limiter on us...Wait for input
"\\m1\t\t*But even if Queenie tries to put&\ta limiter on us.../", "obj_shop_ch2_music_slash_Draw_0_gml_550_0"
);
560
            msgnextloc(
Mini face 1 \t\t*You can't STOP ! THE ! MUSIC!
Mini face 3 \tHear that!? We'll just go
\tunderground!!
Mini face 2 \tCrash! Boom! Bang!Wait for input
"\\m1\t\t*You can't STOP ! THE ! MUSIC!&\\m3\tHear that!? We'll just go&\tunderground!!&\\m2\tCrash! Boom! Bang!/", "obj_shop_ch2_music_slash_Draw_0_gml_551_0"
);
561
            msgnextloc(
Mini face 1 \t\t*That's why we made this junk
\tshop!
Mini face 3 \tWe'll fund our musical rebellion!
Mini face 2 \tCan we make noise music, too?Wait for inputClose Message
"\\m1\t\t*That's why we made this junk&\tshop!&\\m3\tWe'll fund our musical rebellion!&\\m2\tCan we make noise music, too?/%", "obj_shop_ch2_music_slash_Draw_0_gml_552_0"
);
562
        }
563
        if (sell == 4)
564
        {
565
            selling = 3;
566
            dancetimerb = 0;
567
            msgsetloc(0, 
Mini face 1 \t\t*What, wanna see what we got!?
Mini face 3 \tYo, yo, can you handle this!?
Mini face 2 \tHold onto your antennas!!Wait for inputClose Message
"\\m1\t\t*What, wanna see what we got!?&\\m3\tYo, yo, can you handle this!?&\\m2\tHold onto your antennas!!/%", "obj_shop_ch2_music_slash_Draw_0_gml_565_0"
);
568
        }
569
        if (sell == 5)
570
        {
571
            msgsetloc(0, 
Mini face 1 \t\t*Queen wasn't always so... harsh.
Mini face 3 \tNo, she WAS! She just got WORSE
\tsomehow!Wait for input
"\\m1\t\t*Queen wasn't always so... harsh.&\\m3\tNo, she WAS! She just got WORSE&\tsomehow!/", "obj_shop_ch2_music_slash_Draw_0_gml_571_0"
);
572
            msgnextloc(
Mini face 1 \t\t*It wasn't 'til that DARK FOUNTAIN
\tshowed up,
Mini face 3 \tThat she started going into
\toverdrive.Wait for input
"\\m1\t\t*It wasn't 'til that DARK FOUNTAIN&\tshowed up,&\\m3\tThat she started going into&\toverdrive./", "obj_shop_ch2_music_slash_Draw_0_gml_572_0"
);
573
            msgnextloc(
Mini face 1 \t\t*"Knight" this,Delay 11 "Knight" that,Delay 11
\t"Fountain" that...
Mini face 3 \tLike, what does that Knight
\teven have going for it that I
\tdon't!? C'mon!!Wait for input
"\\m1\t\t*\"Knight\" this^1, \"Knight\" that^1,&\t\"Fountain\" that...&\\m3\tLike, what does that Knight&\teven have going for it that I&\tdon't!? C'mon!!/", "obj_shop_ch2_music_slash_Draw_0_gml_573_0"
);
574
            msgnextloc(
Mini face 1 \t\t*But like I said. She wasn't
\tALWAYS so bad. She used to
\tgive me sweets. For being so
\tsweet!
Mini face 3 \tH... huh!? I never got candy!!Wait for input
"\\m1\t\t*But like I said. She wasn't&\tALWAYS so bad. She used to&\tgive me sweets. For being so&\tsweet!&\\m3\tH... huh!? I never got candy!!/", "obj_shop_ch2_music_slash_Draw_0_gml_574_0"
);
575
            msgnextloc(
Mini face 1 \t\t*You kept calling her a
\t"hot mama,Delay 11" Cap.
Mini face 3 \tYeah!? Is that wrong!? She
\tlooks like a mom and tends to
\toverheat!!Wait for input
"\\m1\t\t*You kept calling her a&\t\"hot mama^1,\" Cap.&\\m3\tYeah!? Is that wrong!? She&\tlooks like a mom and tends to&\toverheat!!/", "obj_shop_ch2_music_slash_Draw_0_gml_575_0"
);
576
            msgnextloc(
Mini face 3 \t\t*K_K! Help me out here!!
Mini face 1 \tK_K! What do you think?
Mini face 2 \tHuh? Me?Wait for input
"\\m3\t\t*K_K! Help me out here!!&\\m1\tK_K! What do you think?&\\m2\tHuh? Me?/", "obj_shop_ch2_music_slash_Draw_0_gml_576_0"
);
577
            msgnextloc(
Mini face 2 \t\t*... I like candy.Wait for input
"\\m2\t\t*... I like candy./", "obj_shop_ch2_music_slash_Draw_0_gml_577_0"
);
578
            msgnextloc(
Mini face 1 \t\t*Yeah, you're right, K_K! We gotta
\tfocus on what's important!
Mini face 3 \tIf the band fights, we'll get
\toutta tune!
Mini face 2 \tAnyone have any lemon drops?Wait for inputClose Message
"\\m1\t\t*Yeah, you're right, K_K! We gotta&\tfocus on what's important!&\\m3\tIf the band fights, we'll get&\toutta tune!&\\m2\tAnyone have any lemon drops?/%", "obj_shop_ch2_music_slash_Draw_0_gml_578_0"
);
579
        }
580
        if (sell == 6)
581
        {
582
            msgsetloc(0, 
Mini face 1 \t\t*Our main gig is making scrap
\tinto machines.
Mini face 3 \tOur clients are sometimes a
\tbit off-key though.
Mini face 2 \tThey smell off-key too!!Wait for input
"\\m1\t\t*Our main gig is making scrap&\tinto machines.&\\m3\tOur clients are sometimes a&\tbit off-key though.&\\m2\tThey smell off-key too!!/", "obj_shop_ch2_music_slash_Draw_0_gml_584_0"
);
583
            msgnextloc(
Mini face 1 \t\t*Like some... little weird guy.
Mini face 3 \tHe wanted us to sneak into
\tQueen's mansion...
Mini face 2 \tWe're just rebels, we don't
\twanna get in trouble!Wait for input
"\\m1\t\t*Like some... little weird guy.&\\m3\tHe wanted us to sneak into&\tQueen's mansion...&\\m2\tWe're just rebels, we don't&\twanna get in trouble!/", "obj_shop_ch2_music_slash_Draw_0_gml_585_0"
);
584
            msgnextloc(
Mini face 1 \t\t*But recently we got a
\treal-high-class-client.
Mini face 3 \tA man of TASTE! He had a way
\twith words!!
Mini face 2 \tI couldn't even understand him!Wait for input
"\\m1\t\t*But recently we got a&\treal-high-class-client.&\\m3\tA man of TASTE! He had a way&\twith words!!&\\m2\tI couldn't even understand him!/", "obj_shop_ch2_music_slash_Draw_0_gml_586_0"
);
585
            msgnextloc(
Mini face 1 \t\t*Now, all we gotta do is follow
\tthe blueprints, right?
Mini face 3 \tIt'll be our big time break!!
Mini face 2 \tYeah!! Haha!! It's gonna break
\tapart!! Big time!!Wait for inputClose Message
"\\m1\t\t*Now, all we gotta do is follow&\tthe blueprints, right?&\\m3\tIt'll be our big time break!!&\\m2\tYeah!! Haha!! It's gonna break&\tapart!! Big time!!/%", "obj_shop_ch2_music_slash_Draw_0_gml_587_0"
);
586
        }
587
        global.typer = 78;
588
        instance_create(30, 270, obj_writer);
589
    }
590
    if (selling == 3 && !i_ex(obj_writer))
591
    {
592
        snd_pause(global.currentsong[1]);
593
        coolbeat = snd_init("coolbeat.ogg");
594
        snd_loop(coolbeat);
595
        dancetimerb = 0;
596
        startdancing = 1;
597
        selling = 4;
598
    }
599
    if (selling == 4)
600
    {
601
        dancetimerb++;
602
        if (dancetimerb == 88)
603
        {
604
            snd_free(coolbeat);
605
            everyonedance = 2;
606
        }
607
        if (dancetimerb == 90)
608
        {
609
            snd_resume(global.currentsong[1]);
610
            msgsetloc(0, 
Mini face 3 \t\t*Yo, how was that!?
Mini face 1 \tDid you get rocked?!
Mini face 2 \tAll our songs are only 4 seconds
\tlong!!Wait for inputClose Message
"\\m3\t\t*Yo, how was that!?&\\m1\tDid you get rocked?!&\\m2\tAll our songs are only 4 seconds&\tlong!!/%", "obj_shop_ch2_music_slash_Draw_0_gml_616_0"
);
611
            global.typer = 78;
612
            instance_create(30, 270, obj_writer);
613
            selling = 1;
614
        }
615
    }
616
    if (selling == 1 && instance_exists(obj_writer) == false)
617
    {
618
        if (sell == 2)
619
        {
620
            selling = 2;
621
            event_user(1);
622
        }
623
        else
624
        {
625
            if (sell == 1 || sell == 7)
626
                menu = 0;
627
            else
628
                menu = 3;
629
            sell = 0;
630
            selling = 0;
631
        }
632
    }
633
}
634
if (down_p())
635
{
636
    if (menu != 11 && menu != 12 && menu != 13 && menu != 99)
637
    {
638
        menuc[menu] += 1;
639
        if (menuc[menu] > menumax)
640
            menuc[menu] = 0;
641
    }
642
}
643
if (up_p())
644
{
645
    if (menu != 11 && menu != 12 && menu != 13 && menu != 99)
646
    {
647
        menuc[menu] -= 1;
648
        if (menuc[menu] < 0)
649
            menuc[menu] = menumax;
650
    }
651
}
652
if (menu < 4 || menu >= 10)
653
{
654
    if (menu != 99)
655
    {
656
        draw_text(440, 420, "$" + string_hash_to_newline(string(global.gold)));
657
        if (menu == 1 || menu == 2)
658
        {
659
            if (menuc[1] < 4)
660
            {
661
                if (itemtype[menuc[1]] == "item")
662
                    scr_itemcheck_inventory_and_pocket
scr_itemcheck_inventory_and_pocket

function scr_itemcheck_inventory_and_pocket(arg0) { var _haveeither = 0; var itemcounttotal = 0; scr_itemcheck(arg0); if (haveit == 1) _haveeither = 1; itemcounttotal += itemcount; scr_itemcheck_pocket(arg0); if (haveit == 1) _haveeither = 1; itemcounttotal += itemcount; haveit = _haveeither; itemcount = itemcounttotal; return haveit; }
(0);
663
                if (itemtype[menuc[1]] == "armor")
664
                    scr_armorcheck_inventory
scr_armorcheck_inventory

function scr_armorcheck_inventory(arg0) { haveit = 0; itemcount = 0; for (i = 0; i < 48; i += 1) { if (global.armor[i] == arg0) haveit = 1; if (global.armor[i] == arg0) itemcount += 1; } return haveit; }
(0);
665
                if (itemtype[menuc[1]] == "weapon")
666
                    scr_weaponcheck_inventory
scr_weaponcheck_inventory

function scr_weaponcheck_inventory(arg0) { haveit = 0; itemcount = 0; for (i = 0; i < 48; i += 1) { if (global.weapon[i] == arg0) haveit = 1; if (global.weapon[i] == arg0) itemcount += 1; } return haveit; }
(0);
667
                scr_84_set_draw_font
scr_84_set_draw_font

function scr_84_set_draw_font(arg0) { global.chemg_font = arg0; draw_set_font(scr_84_get_font(arg0)); }
("dotumche");
668
                if (itemcount < 10)
669
                    roomstring = "0" + string(itemcount);
670
                else
671
                    roomstring = string(itemcount);
672
                if (itemcount > 0)
673
                    draw_text(520, 430, string_hash_to_newline(stringsetsubloc("Space:~1", roomstring, "obj_shop_ch2_music_slash_Draw_0_gml_677_0")));
674
                if (itemcount == 0)
675
                    draw_text(520, 430, string_hash_to_newline(stringsetloc(
NO SPACE
"NO SPACE", "obj_shop1_slash_Draw_0_gml_571_0"
)));
676
            }
677
        }
678
    }
679
}
680
if (menu == 99)
681
{
682
    if (i_ex(obj_fusionmenu))
683
    {
684
        is_playing = obj_fusionmenu.songPlaying != " ";
685
        if (is_playing)
686
            previous_song = string(obj_fusionmenu.songPlaying);
687
    }
688
    else if (audio_timer == 1)
689
    {
690
        if (!is_playing)
691
        {
692
            global.currentsong[0] = snd_init(previous_song);
693
            global.currentsong[1] = mus_loop_ext(global.currentsong[0], 1, 1);
694
        }
695
        audio_timer = 0;
696
        menu = 0;
697
    }
698
    else
699
    {
700
        audio_timer++;
701
    }
702
}
703
onebuffer -= 1;
704
twobuffer -= 1;