Deltarune (Chapter 1) script viewer

← back to main script listing

gml_Object_obj_dbulletcontroller_Step_0

(view raw script w/o annotations or w/e)
1
btimer += 1;
2
if (type == 0)
3
{
4
    if (btimer >= (timermax * ratio))
5
    {
6
        btimer = 0;
7
        dir = 30 + random(120);
8
        radius = 140 + random(80);
9
        xx = lengthdir_x(radius, dir);
10
        yy = lengthdir_y(radius, dir);
11
        bm = instance_create(obj_heart.x + 8 + xx, obj_heart.y + 8 + yy, obj_dbullet_maker);
12
        if (bm.y < (__view_get(e__VW.YView, 0) + 40))
13
            bm.y = __view_get(e__VW.YView, 0) + 40;
14
        bm.damage = damage;
15
        bm.target = target;
16
    }
17
}
18
if (type == 1)
19
{
20
    if (btimer >= (9 * ratio))
21
    {
22
        btimer = 0;
23
        radius = 140 + random(40);
24
        yy = radius * side;
25
        xx = -100 + random(200);
26
        num = choose(0, 1, 2, 3);
27
        if (num == 3)
28
            xx = -10 + random(20);
29
        d = instance_create(obj_heart.x + 8 + xx, obj_heart.y + 8 + yy, obj_dbullet_vert);
30
        d.damage = damage;
31
        d.target = target;
32
    }
33
}
34
if (type == 2)
35
{
36
    if (btimer >= (20 * ratio))
37
    {
38
        xx = __view_get(e__VW.XView, 0) - 20;
39
        if (side == 1)
40
            xx = __view_get(e__VW.XView, 0) + 660;
41
        yy = miny + random(maxy - miny);
42
        bul = instance_create(xx, yy, obj_clubsbullet);
43
        bul.speed = 12;
44
        bul.damage = damage;
45
        bul.target = target;
46
        if (side == 1)
47
        {
48
            bul.direction = 180;
49
            bul.image_angle = 180;
50
        }
51
        btimer = 0;
52
    }
53
}
54
if (type == 3)
55
{
56
    if (btimer >= (20 * ratio))
57
    {
58
        btimer = 0;
59
        if (side == 1)
60
            dir = choose(225, 315);
61
        if (side == -1)
62
            dir = choose(45, 135);
63
        radius = 400;
64
        xx = lengthdir_x(radius, dir);
65
        yy = lengthdir_y(radius, dir);
66
        d = instance_create(obj_heart.x + 8 + xx, obj_heart.y + 8 + yy, obj_clubsbullet_dark);
67
        d.direction = dir + 180;
68
        d.speed = 20;
69
        d.friction = 1;
70
        d.damage = damage;
71
        d.target = target;
72
        with (d)
73
            image_angle = direction;
74
        if (side == 1)
75
            side = -1;
76
        else
77
            side = 1;
78
    }
79
}
80
if (type == 4)
81
{
82
    if (btimer >= (30 * ratio))
83
    {
84
        btimer = 0;
85
        if (side == -1)
86
            dir = 225;
87
        if (side == 1)
88
            dir = 315;
89
        radius = 400;
90
        xx = lengthdir_x(radius, dir);
91
        yy = lengthdir_y(radius, dir);
92
        d = instance_create(obj_heart.x + 8 + xx, obj_heart.y + 8 + yy, obj_clubsbullet_dark);
93
        d.damage = damage;
94
        d.target = target;
95
        d.direction = dir + 180;
96
        d.speed = 20;
97
        d.friction = 1;
98
        with (d)
99
            image_angle = direction;
100
        if (side == 1)
101
            side = -1;
102
        else
103
            side = 1;
104
    }
105
}
106
if (type == 6)
107
{
108
    xx = __view_get(e__VW.XView, 0);
109
    yy = __view_get(e__VW.YView, 0);
110
    if (made == 0)
111
    {
112
        d = instance_create(300 + xx, -20 + yy, obj_dicebul);
113
        e = instance_create(360 + xx, -60 + yy, obj_dicebul);
114
        d.target = target;
115
        d.damage = damage;
116
        e.target = target;
117
        e.damage = damage;
118
        made = 1;
119
    }
120
}
121
if (type == 7)
122
{
123
    xx = __view_get(e__VW.XView, 0);
124
    yy = __view_get(e__VW.YView, 0);
125
    if (made < 3 && btimer >= 15)
126
    {
127
        btimer = 0;
128
        mine = instance_create(300 + xx, -20 + yy, obj_dicebul);
129
        mine.damage = damage;
130
        mine.target = target;
131
        with (obj_dicebul)
132
        {
133
            gravity = 0.15 + gravbonus;
134
            image_xscale = 1;
135
            image_yscale = 1;
136
        }
137
        made += 1;
138
    }
139
}
140
if (type == 8)
141
{
142
    xx = __view_get(e__VW.XView, 0);
143
    yy = __view_get(e__VW.YView, 0);
144
    if (made < 4 && btimer >= 15)
145
    {
146
        btimer = 0;
147
        mine = instance_create(300 + xx, yy - 40, obj_dicebul);
148
        mine.damage = damage;
149
        mine.target = target;
150
        with (mine)
151
        {
152
            hspeed = 1.2 + random(1.2);
153
            hspeed *= choose(-1, 1);
154
            gravbonus = random(0.1);
155
            gravity = 0.15 + gravbonus;
156
            image_xscale = 0.7;
157
            image_yscale = 0.7;
158
        }
159
        made += 1;
160
    }
161
}
162
if (type == 10)
163
{
164
    xx = __view_get(e__VW.XView, 0);
165
    yy = __view_get(e__VW.YView, 0);
166
    if (btimer >= 15)
167
    {
168
        btimer = 0;
169
        dicecomet = instance_create(choose(xx + 680, xx - 100), 0 - random(100), obj_dicebul);
170
        dicecomet.damage = damage;
171
        dicecomet.target = target;
172
        with (dicecomet)
173
        {
174
            image_xscale = 2;
175
            image_yscale = 2;
176
            if (x > (__view_get(e__VW.XView, 0) + 320))
177
                hspeed = -6 - random(1);
178
            else
179
                hspeed = 6 + random(1);
180
            vspeed = 2 + random(2);
181
        }
182
    }
183
}
184
if (type == 11)
185
{
186
    xx = __view_get(e__VW.XView, 0);
187
    yy = __view_get(e__VW.YView, 0);
188
    if (made < 4 && btimer >= 15)
189
    {
190
        btimer = 0;
191
        bb = instance_create(300 + xx, -20 + yy, obj_dicebul);
192
        bb.damage = damage;
193
        bb.target = target;
194
        with (obj_dicebul)
195
        {
196
            gravity = 0.15 + gravbonus;
197
            image_xscale = 1;
198
            image_yscale = 1;
199
        }
200
        if (made == 3)
201
        {
202
            with (bb)
203
            {
204
                green = 1;
205
                image_blend = c_lime;
206
            }
207
        }
208
        made += 1;
209
    }
210
}
211
if (type == 12)
212
{
213
    xx = __view_get(e__VW.XView, 0);
214
    yy = __view_get(e__VW.YView, 0);
215
    if (made == 0)
216
    {
217
        db = instance_create(320 + xx, -20 + yy, obj_dicebul);
218
        db.image_xscale = 1;
219
        db.image_yscale = 1;
220
        db.damage = damage;
221
        db.target = target;
222
        made = 1;
223
    }
224
}
225
if (type == 13)
226
{
227
    xx = __view_get(e__VW.XView, 0);
228
    yy = __view_get(e__VW.YView, 0);
229
    if (made < 2 && btimer >= 20)
230
    {
231
        db[made] = instance_create(320 + xx, -20 + yy, obj_dicebul);
232
        db[made].image_xscale = 1;
233
        db[made].image_yscale = 1;
234
        db[made].damage = damage;
235
        db[made].target = target;
236
        if (made == 1)
237
        {
238
            with (db[1])
239
            {
240
                green = 1;
241
                image_blend = c_lime;
242
            }
243
            db[1].hspeed = -db[0].hspeed;
244
        }
245
        made += 1;
246
    }
247
}
248
if (type == 14)
249
{
250
    if (btimer >= 10)
251
    {
252
        xx = __view_get(e__VW.XView, 0) - 20;
253
        if (side == 1)
254
            xx = __view_get(e__VW.XView, 0) + 660;
255
        yy = miny + random(maxy - miny);
256
        bul = instance_create(xx, yy, obj_regularbullet);
257
        bul.sprite_index = spr_smallbullet;
258
        bul.hspeed = -8;
259
        bul.damage = damage;
260
        bul.target = target;
261
        if (side == 1)
262
        {
263
            bul.direction = 180;
264
            bul.image_angle = 180;
265
        }
266
        btimer = 0;
267
    }
268
}
269
if (type == 20 || type == 22)
270
{
271
    if (instance_exists(obj_lancerboss3))
272
    {
273
        if (made == 0)
274
        {
275
            snd_play(snd_lancerwhistle);
276
            whistletimer = 0;
277
            made = 1;
278
            with (obj_lancerboss3)
279
                idlesprite = spr_lancerbike_l;
280
        }
281
        if (made == 1)
282
        {
283
            whistletimer += 1;
284
            if (whistletimer >= 30)
285
            {
286
                with (obj_lancerboss3)
287
                    idlesprite = spr_lancerbike;
288
                made = 2;
289
            }
290
        }
291
    }
292
    if (type == 20)
293
        bmax = 8;
294
    if (type == 22)
295
        bmax = 6;
296
    if (btimer >= bmax)
297
    {
298
        radius = -80 + random(160) + 8;
299
        fallspade = instance_create(obj_heart.x + radius, __view_get(e__VW.YView, 0) - 20, obj_regularbullet);
300
        fallspade.damage = damage;
301
        fallspade.target = target;
302
        with (fallspade)
303
        {
304
            sprite_index = spr_spadebullet;
305
            image_angle = 270;
306
            gravity = 0.3;
307
            speed = 0;
308
            vspeed = 3;
309
            hspeed = -0.6 + random(1.2);
310
        }
311
        if (side == 1)
312
            side = -1;
313
        else
314
            side = 1;
315
        btimer = 0;
316
    }
317
}
318
if (type == 21 || type == 23 || type == 25)
319
{
320
    if (type == 21)
321
        bmax = 9;
322
    if (type == 23)
323
        bmax = 7;
324
    if (type == 25)
325
        bmax = 4;
326
    with (obj_regularbullet)
327
        image_alpha += 0.2;
328
    if (btimer >= bmax)
329
    {
330
        if (side == 0)
331
            radius = 80;
332
        else
333
            radius = 560;
334
        sidespade[side] = instance_create(__view_get(e__VW.XView, 0) + radius, (obj_growtangle.y - (obj_growtangle.sprite_height / 2)) + random(obj_growtangle.sprite_height), obj_regularbullet);
335
        if (side == 0)
336
            sidespade[side].direction = 0;
337
        if (side == 1)
338
            sidespade[side].direction = 180;
339
        sidespade[side].image_alpha = 0;
340
        sidespade[side].damage = damage;
341
        sidespade[side].target = target;
342
        with (sidespade[side])
343
        {
344
            sprite_index = spr_spadebullet;
345
            speed = 5;
346
            friction = -0.1;
347
            image_angle = direction;
348
        }
349
        if (side == 1)
350
            side = 0;
351
        else
352
            side = 1;
353
        btimer = 0;
354
    }
355
}
356
if (type == 24)
357
{
358
    bmax = difficulty + 5;
359
    with (obj_regularbullet)
360
    {
361
        if (instance_exists(obj_heart))
362
        {
363
            xdiff = x - (obj_heart.x + 8);
364
            if (y >= (obj_heart.y - 240) && abs(xdiff) <= 30)
365
            {
366
                if (xdiff >= 0 && hspeed < 5)
367
                    hspeed += 0.4;
368
                if (xdiff < 0 && hspeed > -5)
369
                    hspeed -= 0.4;
370
            }
371
            if (y >= (obj_heart.y - 100))
372
            {
373
                if (abs(xdiff) <= 60)
374
                {
375
                    if (xdiff >= 0)
376
                    {
377
                        if (hspeed < 2)
378
                            hspeed += 0.25;
379
                        if (xdiff < 10)
380
                            x += 3;
381
                        if (xdiff < 20)
382
                            x += 3;
383
                        if (xdiff < 30)
384
                            x += 3;
385
                        if (xdiff < 40)
386
                            x += 2;
387
                        if (xdiff < 60)
388
                            x += 1;
389
                    }
390
                    else
391
                    {
392
                        if (hspeed > -2)
393
                            hspeed -= 0.25;
394
                        if (xdiff > -10)
395
                            x -= 3;
396
                        if (xdiff > -20)
397
                            x -= 3;
398
                        if (xdiff > -30)
399
                            x -= 3;
400
                        if (xdiff > -40)
401
                            x -= 2;
402
                        if (xdiff > -60)
403
                            x -= 1;
404
                    }
405
                }
406
            }
407
        }
408
    }
409
    if (btimer >= bmax)
410
    {
411
        radius = -80 + random(160) + 8;
412
        fallspade = instance_create(obj_heart.x + radius, -20, obj_regularbullet);
413
        fallspade.damage = damage;
414
        fallspade.target = target;
415
        with (fallspade)
416
        {
417
            sprite_index = spr_spadebullet;
418
            image_angle = 270;
419
            gravity = 0.3;
420
            speed = 0;
421
            vspeed = 3;
422
            hspeed = -0.6 + random(1.2);
423
        }
424
        if (side == 1)
425
            side = -1;
426
        else
427
            side = 1;
428
        btimer = 0;
429
    }
430
}
431
if (type == 26)
432
{
433
    with (obj_regularbullet)
434
    {
435
        if (sprite_index == spr_blockbullet)
436
            image_alpha += 0.1;
437
    }
438
    timer = 35;
439
    if (
scr_monsterpop
scr_monsterpop

function
scr_monsterpop()
{ return global.monster[0] + global.monster[1] + global.monster[2]; }
() == 2)
440
        timer = 52.5;
441
    if (
scr_monsterpop
scr_monsterpop

function
scr_monsterpop()
{ return global.monster[0] + global.monster[1] + global.monster[2]; }
() == 3)
442
        timer = 77;
443
    if (btimer >= timer)
444
    {
445
        x_c = __view_get(e__VW.XView, 0) + 300;
446
        y_c = __view_get(e__VW.YView, 0) + 140;
447
        x_o = 200;
448
        y_o = -60;
449
        y_o_o = -80 + random(160);
450
        y_o += y_o_o;
451
        v_s = -y_o_o / 160;
452
        h_s = -2;
453
        for (i = 0; i < 2; i += 1)
454
        {
455
            upallow = choose(0, 1, 2);
456
            rightallow = choose(0, 1, 2);
457
            for (j = 0; j < 2; j += 1)
458
            {
459
                bul[i][j] = instance_create(x_c + x_o + (i * 80), y_c + y_o + (j * 80), obj_regularbullet);
460
                
scr_bullet_inherit
scr_bullet_inherit

function
scr_bullet_inherit(arg0)
{ if (instance_exists(arg0)) { arg0.damage = damage; arg0.grazepoints = grazepoints; arg0.timepoints = timepoints; arg0.inv = inv; arg0.target = target; arg0.grazed = 0; arg0.grazetimer = 0; } }
(bul[i][j]);
461
                if (j == upallow)
462
                    bul[i][j].y += choose(0, 40);
463
                if (i == 1 && j == 1)
464
                {
465
                    bul[i][j].x += choose(0, -40);
466
                    bul[i][j].y = y_c + y_o + choose(0, 40) + (j * 80);
467
                }
468
                bul[i][j].hspeed = h_s;
469
                bul[i][j].vspeed = v_s;
470
                bul[i][j].friction = -0.07;
471
                if (
scr_monsterpop
scr_monsterpop

function
scr_monsterpop()
{ return global.monster[0] + global.monster[1] + global.monster[2]; }
() >= 2)
472
                    bul[i][j].friction = -0.1;
473
                bul[i][j].sprite_index = spr_blockbullet;
474
                bul[i][j].image_alpha = 0;
475
            }
476
        }
477
        btimer = 0;
478
    }
479
}
480
if (type == 27)
481
{
482
    timer = 15;
483
    if (
scr_monsterpop
scr_monsterpop

function
scr_monsterpop()
{ return global.monster[0] + global.monster[1] + global.monster[2]; }
() == 2)
484
        timer = 25.5;
485
    if (
scr_monsterpop
scr_monsterpop

function
scr_monsterpop()
{ return global.monster[0] + global.monster[1] + global.monster[2]; }
() == 3)
486
        timer = 34.5;
487
    lx = (obj_battlesolid.x - (obj_battlesolid.sprite_width / 2)) + 8;
488
    ly = (obj_battlesolid.y + (obj_battlesolid.sprite_height / 2)) - 15;
489
    if (btimer >= timer)
490
    {
491
        prevmade = made;
492
        made = choose(0, 1, 2, 3);
493
        if (made == prevmade)
494
            made = choose(0, 1, 2, 3);
495
        btimer = 0;
496
        block = instance_create(100, 100, obj_blockbullet_fall);
497
        block.xpos = made;
498
        
scr_bullet_inherit
scr_bullet_inherit

function
scr_bullet_inherit(arg0)
{ if (instance_exists(arg0)) { arg0.damage = damage; arg0.grazepoints = grazepoints; arg0.timepoints = timepoints; arg0.inv = inv; arg0.target = target; arg0.grazed = 0; arg0.grazetimer = 0; } }
(block);
499
        testblock = collision_point(lx + (made * block.sprite_width) + 8, ly - (block.sprite_height * 3) - 10, obj_blockbullet_fall, false, true);
500
        if (testblock > 1)
501
        {
502
            if (testblock.halt == 1)
503
            {
504
                with (block)
505
                    instance_destroy();
506
            }
507
        }
508
    }
509
    legoa = collision_point(lx + 15, ly, obj_blockbullet_fall, false, true);
510
    legob = collision_point(lx + 15 + 34, ly, obj_blockbullet_fall, false, true);
511
    legoc = collision_point(lx + 15 + 68, ly, obj_blockbullet_fall, false, true);
512
    legod = collision_point(lx + 15 + 102, ly, obj_blockbullet_fall, false, true);
513
    if (legoa > 1 && legob > 1 && legoc > 1 && legod > 1)
514
    {
515
        with (legoa)
516
            con = 3;
517
        with (legob)
518
            con = 3;
519
        with (legoc)
520
            con = 3;
521
        with (legod)
522
            con = 3;
523
    }
524
}
525
if (type == 30)
526
{
527
    bmax = 34;
528
    if (
scr_monsterpop
scr_monsterpop

function
scr_monsterpop()
{ return global.monster[0] + global.monster[1] + global.monster[2]; }
() == 2)
529
        bmax = 46;
530
    if (
scr_monsterpop
scr_monsterpop

function
scr_monsterpop()
{ return global.monster[0] + global.monster[1] + global.monster[2]; }
() == 3)
531
        bmax = 60;
532
    if (btimer >= bmax)
533
    {
534
        rab = instance_create(obj_battlesolid.x + obj_battlesolid.sprite_width, obj_battlesolid.y, obj_rabbitbullet);
535
        
scr_bullet_inherit
scr_bullet_inherit

function
scr_bullet_inherit(arg0)
{ if (instance_exists(arg0)) { arg0.damage = damage; arg0.grazepoints = grazepoints; arg0.timepoints = timepoints; arg0.inv = inv; arg0.target = target; arg0.grazed = 0; arg0.grazetimer = 0; } }
(rab);
536
        btimer = 0;
537
    }
538
}
539
if (type == 32)
540
{
541
    skiprab = 0;
542
    if (instance_exists(obj_carrotthrower))
543
    {
544
        skiprab = 1;
545
        type = 30;
546
    }
547
    if (made == 0 && skiprab == 0)
548
    {
549
        made = 1;
550
        rab = instance_create(obj_battlesolid.x, obj_battlesolid.y, obj_carrotthrower);
551
        
scr_bullet_inherit
scr_bullet_inherit

function
scr_bullet_inherit(arg0)
{ if (instance_exists(arg0)) { arg0.damage = damage; arg0.grazepoints = grazepoints; arg0.timepoints = timepoints; arg0.inv = inv; arg0.target = target; arg0.grazed = 0; arg0.grazetimer = 0; } }
(rab);
552
        instance_destroy();
553
    }
554
}
555
if (type == 33)
556
{
557
    if (btimer >= (26 * ratio))
558
    {
559
        hs = instance_create(obj_battlesolid.x, obj_battlesolid.y, obj_heartshaper);
560
        hs.maxradius = 50;
561
        hs.type = 1;
562
        btimer = 0;
563
        hs.thisx = (obj_battlesolid.x - 50) + random(100);
564
        hs.thisy = (obj_battlesolid.y - 50) + random(100);
565
        
scr_bullet_inherit
scr_bullet_inherit

function
scr_bullet_inherit(arg0)
{ if (instance_exists(arg0)) { arg0.damage = damage; arg0.grazepoints = grazepoints; arg0.timepoints = timepoints; arg0.inv = inv; arg0.target = target; arg0.grazed = 0; arg0.grazetimer = 0; } }
(hs);
566
    }
567
}
568
if (type == 34)
569
{
570
    if (btimer >= 28)
571
    {
572
        typechoice = choose(0, 1, 2, 3);
573
        xx = 0;
574
        yy = 0;
575
        if (typechoice == 0 || typechoice == 3)
576
        {
577
            xx = (__view_get(e__VW.XView, 0) + 320 + random(300)) - random(300);
578
            yy = -60;
579
        }
580
        if (typechoice == 1)
581
        {
582
            xx = __view_get(e__VW.XView, 0) - 60;
583
            yy = random(320);
584
        }
585
        if (typechoice == 2)
586
        {
587
            xx = __view_get(e__VW.XView, 0) + 700;
588
            yy = random(320);
589
        }
590
        chain = instance_create(xx, yy, obj_skychain);
591
        
scr_bullet_inherit
scr_bullet_inherit

function
scr_bullet_inherit(arg0)
{ if (instance_exists(arg0)) { arg0.damage = damage; arg0.grazepoints = grazepoints; arg0.timepoints = timepoints; arg0.inv = inv; arg0.target = target; arg0.grazed = 0; arg0.grazetimer = 0; } }
(255);
592
        btimer = 0;
593
    }
594
}
595
if (type == 35)
596
{
597
    if (btimer >= 22)
598
    {
599
        typechoice = choose(0, 1, 2, 3);
600
        xx = 0;
601
        yy = 0;
602
        if (typechoice == 0 || typechoice == 3)
603
        {
604
            xx = (__view_get(e__VW.XView, 0) + 320 + random(300)) - random(300);
605
            yy = -60;
606
        }
607
        if (typechoice == 1)
608
        {
609
            xx = __view_get(e__VW.XView, 0) - 60;
610
            yy = random(320);
611
        }
612
        if (typechoice == 2)
613
        {
614
            xx = __view_get(e__VW.XView, 0) + 700;
615
            yy = random(320);
616
        }
617
        chain = instance_create(xx, yy, obj_skychain);
618
        
scr_bullet_inherit
scr_bullet_inherit

function
scr_bullet_inherit(arg0)
{ if (instance_exists(arg0)) { arg0.damage = damage; arg0.grazepoints = grazepoints; arg0.timepoints = timepoints; arg0.inv = inv; arg0.target = target; arg0.grazed = 0; arg0.grazetimer = 0; } }
(chain);
619
        btimer = 0;
620
    }
621
}
622
if (type == 36)
623
{
624
    if (btimer >= 16)
625
    {
626
        typechoice = choose(0, 1, 2, 3);
627
        xx = 0;
628
        yy = 0;
629
        if (typechoice == 0 || typechoice == 3)
630
        {
631
            xx = (__view_get(e__VW.XView, 0) + 320 + random(300)) - random(300);
632
            yy = -60;
633
        }
634
        if (typechoice == 1)
635
        {
636
            xx = __view_get(e__VW.XView, 0) - 60;
637
            yy = random(320);
638
        }
639
        if (typechoice == 2)
640
        {
641
            xx = __view_get(e__VW.XView, 0) + 700;
642
            yy = random(320);
643
        }
644
        chain = instance_create(xx, yy, obj_skychain);
645
        
scr_bullet_inherit
scr_bullet_inherit

function
scr_bullet_inherit(arg0)
{ if (instance_exists(arg0)) { arg0.damage = damage; arg0.grazepoints = grazepoints; arg0.timepoints = timepoints; arg0.inv = inv; arg0.target = target; arg0.grazed = 0; arg0.grazetimer = 0; } }
(chain);
646
        btimer = 0;
647
    }
648
}
649
if (type >= 80 && type <= 84)
650
{
651
    maxtimer = 40;
652
    if (type == 81)
653
        maxtimer = 30;
654
    if (type == 82)
655
        maxtimer = 26;
656
    if (type == 83)
657
        maxtimer = 19;
658
    if (type == 84)
659
        maxtimer = 14;
660
    if (btimer >= maxtimer)
661
    {
662
        btimer = 0;
663
        lx = obj_battlesolid.x;
664
        ly = obj_battlesolid.y;
665
        side = choose(0, 1);
666
        if (type == 81 || type == 84)
667
        {
668
            side = made;
669
            if (made == 0)
670
                made = 1;
671
            else
672
                made = 0;
673
        }
674
        if (side == 0)
675
        {
676
            puzz1 = instance_create(obj_heart.x + 8, ly - 150, obj_jigsawbullet);
677
            puzz1.side = 3;
678
            puzz2 = instance_create(obj_heart.x + 8, ly + 150, obj_jigsawbullet);
679
            puzz2.side = 1;
680
            if (type == 82)
681
                puzz1.timer = 10;
682
            if (type == 82)
683
                puzz2.timer = 10;
684
            if (type == 83 || type == 84)
685
                puzz1.timer = 15;
686
            if (type == 83 || type == 84)
687
                puzz2.timer = 15;
688
            
scr_bullet_inherit
scr_bullet_inherit

function
scr_bullet_inherit(arg0)
{ if (instance_exists(arg0)) { arg0.damage = damage; arg0.grazepoints = grazepoints; arg0.timepoints = timepoints; arg0.inv = inv; arg0.target = target; arg0.grazed = 0; arg0.grazetimer = 0; } }
(puzz1);
689
            
scr_bullet_inherit
scr_bullet_inherit

function
scr_bullet_inherit(arg0)
{ if (instance_exists(arg0)) { arg0.damage = damage; arg0.grazepoints = grazepoints; arg0.timepoints = timepoints; arg0.inv = inv; arg0.target = target; arg0.grazed = 0; arg0.grazetimer = 0; } }
(puzz2);
690
        }
691
        if (side == 1)
692
        {
693
            puzz1 = instance_create(lx + 150, obj_heart.y + 8, obj_jigsawbullet);
694
            puzz1.side = 2;
695
            puzz2 = instance_create(lx - 150, obj_heart.y + 8, obj_jigsawbullet);
696
            puzz2.side = 0;
697
            if (type == 82)
698
                puzz1.timer = 10;
699
            if (type == 82)
700
                puzz2.timer = 10;
701
            if (type == 83)
702
                puzz1.timer = 15;
703
            if (type == 83)
704
                puzz2.timer = 15;
705
            
scr_bullet_inherit
scr_bullet_inherit

function
scr_bullet_inherit(arg0)
{ if (instance_exists(arg0)) { arg0.damage = damage; arg0.grazepoints = grazepoints; arg0.timepoints = timepoints; arg0.inv = inv; arg0.target = target; arg0.grazed = 0; arg0.grazetimer = 0; } }
(puzz1);
706
            
scr_bullet_inherit
scr_bullet_inherit

function
scr_bullet_inherit(arg0)
{ if (instance_exists(arg0)) { arg0.damage = damage; arg0.grazepoints = grazepoints; arg0.timepoints = timepoints; arg0.inv = inv; arg0.target = target; arg0.grazed = 0; arg0.grazetimer = 0; } }
(puzz2);
707
        }
708
        if (type == 83)
709
        {
710
            with (obj_jigsawbullet)
711
                joker = 1;
712
        }
713
    }
714
}
715
if (type == 85)
716
{
717
    if (made == 0)
718
    {
719
        cheer = 0;
720
        cheertimer = 0;
721
        remhp[0] = global.hp[global.char[0]];
722
        remhp[1] = global.hp[global.char[1]];
723
        with (obj_susieenemy)
724
            visible = 0;
725
        with (obj_lancerboss3)
726
            visible = 0;
727
        fakelan = instance_create(__view_get(e__VW.XView, 0) + 580, obj_battlesolid.y + 160, obj_bulletparent);
728
        with (fakelan)
729
        {
730
            depth += 1;
731
            image_xscale = 2;
732
            image_yscale = 2;
733
            visible = 1;
734
            sprite_index = spr_lancerbike;
735
            active = 0;
736
            image_speed = 0.2;
737
        }
738
        fakesus = instance_create(__view_get(e__VW.XView, 0) + 530, obj_battlesolid.y - 40, obj_bulletparent);
739
        with (fakesus)
740
        {
741
            image_xscale = 2;
742
            image_yscale = 2;
743
            visible = 1;
744
            sprite_index = spr_susie_enemy_attack;
745
            active = 0;
746
            image_speed = 0;
747
        }
748
        made = 1;
749
    }
750
    if (made == 1)
751
    {
752
        if (instance_exists(fakelan))
753
        {
754
            if (cheer == 0)
755
            {
756
                if (global.inv > 10)
757
                {
758
                    cheer = 1;
759
                    snd_play(snd_lancerwhistle);
760
                    with (fakelan)
761
                        sprite_index = spr_lancerbike_l;
762
                }
763
            }
764
            if (cheer == 1)
765
            {
766
                cheertimer += 1;
767
                if (cheertimer >= 30)
768
                {
769
                    cheertimer = 0;
770
                    with (fakelan)
771
                        sprite_index = spr_lancerbike;
772
                    cheer = 0;
773
                }
774
            }
775
        }
776
        if (instance_exists(fakesus))
777
        {
778
            with (fakesus)
779
            {
780
                if (image_index < 5)
781
                    image_index += 0.334;
782
            }
783
        }
784
    }
785
    if (made == 1 && global.turntimer <= 10)
786
    {
787
        with (fakesus)
788
            visible = 0;
789
        with (fakelan)
790
            visible = 0;
791
        with (obj_susieenemy)
792
            visible = 1;
793
        with (obj_lancerboss3)
794
            visible = 1;
795
    }
796
    if (btimer >= 27 && instance_exists(obj_battlesolid) && global.turntimer > 10)
797
    {
798
        with (fakesus)
799
        {
800
            image_index = 0;
801
            snd_play(snd_laz_c);
802
        }
803
        for (i = 0; i < 1; i += 1)
804
        {
805
            axe[i] = instance_create(__view_get(e__VW.XView, 0) + 540, obj_battlesolid.y, obj_axebullet);
806
            
scr_bullet_inherit
scr_bullet_inherit

function
scr_bullet_inherit(arg0)
{ if (instance_exists(arg0)) { arg0.damage = damage; arg0.grazepoints = grazepoints; arg0.timepoints = timepoints; arg0.inv = inv; arg0.target = target; arg0.grazed = 0; arg0.grazetimer = 0; } }
(axe[i]);
807
        }
808
        btimer = 0;
809
    }
810
}
811
if (joker == 1)
812
{
813
    if (type == 45)
814
    {
815
        if (btimer >= 18)
816
        {
817
            xx = choose(0, 1);
818
            basex = __view_get(e__VW.XView, 0) + 320;
819
            if (instance_exists(obj_growtangle))
820
                basex = obj_growtangle.x;
821
            if (xx == 0)
822
                idealx = basex - 180 - random(100);
823
            if (xx == 1)
824
                idealx = basex + 180 + random(100);
825
            bomb = instance_create(idealx, -20, obj_suitbomb);
826
            
scr_bullet_inherit
scr_bullet_inherit

function
scr_bullet_inherit(arg0)
{ if (instance_exists(arg0)) { arg0.damage = damage; arg0.grazepoints = grazepoints; arg0.timepoints = timepoints; arg0.inv = inv; arg0.target = target; arg0.grazed = 0; arg0.grazetimer = 0; } }
(bomb);
827
            if (bomb.type == 2)
828
                bomb.type = choose(0, 1, 2, 3);
829
            btimer = 0;
830
        }
831
    }
832
    if (type == 46)
833
    {
834
        if (btimer >= 12)
835
        {
836
            xx = choose(0, 1);
837
            basex = __view_get(e__VW.XView, 0) + 320;
838
            if (instance_exists(obj_growtangle))
839
                basex = obj_growtangle.x;
840
            if (xx == 0)
841
                idealx = basex - 180 - random(100);
842
            if (xx == 1)
843
                idealx = basex + 180 + random(100);
844
            bomb = instance_create(idealx, -20, obj_suitbomb);
845
            
scr_bullet_inherit
scr_bullet_inherit

function
scr_bullet_inherit(arg0)
{ if (instance_exists(arg0)) { arg0.damage = damage; arg0.grazepoints = grazepoints; arg0.timepoints = timepoints; arg0.inv = inv; arg0.target = target; arg0.grazed = 0; arg0.grazetimer = 0; } }
(bomb);
846
            if (bomb.type == 2)
847
                bomb.type = choose(0, 1, 2, 3);
848
            btimer = 0;
849
        }
850
    }
851
    if (type == 47)
852
    {
853
        if (btimer >= 12)
854
        {
855
            xx = choose(0, 1);
856
            basex = __view_get(e__VW.XView, 0) + 320;
857
            if (instance_exists(obj_growtangle))
858
                basex = obj_growtangle.x;
859
            if (xx == 0)
860
                idealx = basex - 180 - random(100);
861
            if (xx == 1)
862
                idealx = basex + 180 + random(100);
863
            bomb = instance_create(idealx, -20, obj_suitbomb);
864
            
scr_bullet_inherit
scr_bullet_inherit

function
scr_bullet_inherit(arg0)
{ if (instance_exists(arg0)) { arg0.damage = damage; arg0.grazepoints = grazepoints; arg0.timepoints = timepoints; arg0.inv = inv; arg0.target = target; arg0.grazed = 0; arg0.grazetimer = 0; } }
(bomb);
865
            bomb.type = 1;
866
            btimer = 0;
867
        }
868
    }
869
    if (type == 48)
870
    {
871
        if (btimer >= 12)
872
        {
873
            xx = choose(0, 1);
874
            basex = __view_get(e__VW.XView, 0) + 320;
875
            if (instance_exists(obj_growtangle))
876
                basex = obj_growtangle.x;
877
            if (xx == 0)
878
                idealx = basex - 180 - random(100);
879
            if (xx == 1)
880
                idealx = basex + 180 + random(100);
881
            bomb = instance_create(idealx, -20, obj_suitbomb);
882
            
scr_bullet_inherit
scr_bullet_inherit

function
scr_bullet_inherit(arg0)
{ if (instance_exists(arg0)) { arg0.damage = damage; arg0.grazepoints = grazepoints; arg0.timepoints = timepoints; arg0.inv = inv; arg0.target = target; arg0.grazed = 0; arg0.grazetimer = 0; } }
(bomb);
883
            bomb.type = 0;
884
            btimer = 0;
885
        }
886
    }
887
    if (type == 49)
888
    {
889
        if (btimer >= 20)
890
        {
891
            xx = choose(0, 1);
892
            basex = __view_get(e__VW.XView, 0) + 320;
893
            if (instance_exists(obj_growtangle))
894
                basex = obj_growtangle.x;
895
            if (xx == 0)
896
                idealx = basex - 180 - random(100);
897
            if (xx == 1)
898
                idealx = basex + 180 + random(100);
899
            bomb = instance_create(idealx, -20, obj_suitbomb);
900
            
scr_bullet_inherit
scr_bullet_inherit

function
scr_bullet_inherit(arg0)
{ if (instance_exists(arg0)) { arg0.damage = damage; arg0.grazepoints = grazepoints; arg0.timepoints = timepoints; arg0.inv = inv; arg0.target = target; arg0.grazed = 0; arg0.grazetimer = 0; } }
(bomb);
901
            bomb.type = 2;
902
            btimer = 0;
903
        }
904
    }
905
    if (type == 50)
906
    {
907
        if (btimer >= 12)
908
        {
909
            xx = choose(0, 1);
910
            basex = __view_get(e__VW.XView, 0) + 320;
911
            if (instance_exists(obj_growtangle))
912
                basex = obj_growtangle.x;
913
            if (xx == 0)
914
                idealx = basex - 180 - random(100);
915
            if (xx == 1)
916
                idealx = basex + 180 + random(100);
917
            bomb = instance_create(idealx, -20, obj_suitbomb);
918
            
scr_bullet_inherit
scr_bullet_inherit

function
scr_bullet_inherit(arg0)
{ if (instance_exists(arg0)) { arg0.damage = damage; arg0.grazepoints = grazepoints; arg0.timepoints = timepoints; arg0.inv = inv; arg0.target = target; arg0.grazed = 0; arg0.grazetimer = 0; } }
(bomb);
919
            bomb.type = 3;
920
            btimer = 0;
921
        }
922
    }
923
    if (type == 55)
924
    {
925
        if (btimer >= 40 && made == 0)
926
        {
927
            btimer = 0;
928
            made = 1;
929
            scythe = instance_create(obj_battlesolid.x - 200, obj_battlesolid.y, obj_bigscythe);
930
            
scr_bullet_inherit
scr_bullet_inherit

function
scr_bullet_inherit(arg0)
{ if (instance_exists(arg0)) { arg0.damage = damage; arg0.grazepoints = grazepoints; arg0.timepoints = timepoints; arg0.inv = inv; arg0.target = target; arg0.grazed = 0; arg0.grazetimer = 0; } }
(scythe);
931
            scythe.image_angle = 270 + random(120);
932
        }
933
    }
934
    if (type == 56)
935
    {
936
        if (btimer >= 29 && made == 0)
937
        {
938
            btimer = 0;
939
            xchoose = choose(-250);
940
            scythe = instance_create(obj_battlesolid.x + xchoose, obj_battlesolid.y, obj_bigscythe);
941
            
scr_bullet_inherit
scr_bullet_inherit

function
scr_bullet_inherit(arg0)
{ if (instance_exists(arg0)) { arg0.damage = damage; arg0.grazepoints = grazepoints; arg0.timepoints = timepoints; arg0.inv = inv; arg0.target = target; arg0.grazed = 0; arg0.grazetimer = 0; } }
(scythe);
942
            scythe.image_angle = random(90);
943
            scythe.type = 3;
944
            scythe.friction = -0.25;
945
            if (xchoose > 0)
946
                scythe.hspeed = -1;
947
            if (xchoose < 0)
948
                scythe.hspeed = 1;
949
        }
950
    }
951
    if (type == 57)
952
    {
953
        if (btimer >= 40 && made == 0)
954
        {
955
            btimer = 0;
956
            made = 1;
957
            scythe = instance_create(obj_battlesolid.x - 140, obj_battlesolid.y, obj_bigscythe);
958
            
scr_bullet_inherit
scr_bullet_inherit

function
scr_bullet_inherit(arg0)
{ if (instance_exists(arg0)) { arg0.damage = damage; arg0.grazepoints = grazepoints; arg0.timepoints = timepoints; arg0.inv = inv; arg0.target = target; arg0.grazed = 0; arg0.grazetimer = 0; } }
(scythe);
959
            scythe.anglespeed = -12;
960
            scythe.image_angle = 270 + random(120);
961
        }
962
    }
963
    if (type == 58)
964
    {
965
        if (btimer >= 40 && made == 0)
966
        {
967
            btimer = 0;
968
            made = 1;
969
            scythe = instance_create(obj_battlesolid.x - 150, obj_battlesolid.y, obj_bigscythe);
970
            scythe.anglespeed = -17;
971
            scythe.image_angle = 270 + random(120);
972
        }
973
    }
974
    if (type == 60)
975
    {
976
        if (btimer >= 40 && made == 0)
977
        {
978
            btimer = 0;
979
            made = 1;
980
            for (i = 0; i < 3; i += 1)
981
            {
982
                for (j = 0; j < 7; j += 1)
983
                {
984
                    horse1 = instance_create(obj_battlesolid.x + 150, (obj_battlesolid.y - 80) + (i * 80), obj_carouselbullet);
985
                    horse1.siner = j * 18;
986
                    horse1.vsin = j * 9;
987
                    
scr_bullet_inherit
scr_bullet_inherit

function
scr_bullet_inherit(arg0)
{ if (instance_exists(arg0)) { arg0.damage = damage; arg0.grazepoints = grazepoints; arg0.timepoints = timepoints; arg0.inv = inv; arg0.target = target; arg0.grazed = 0; arg0.grazetimer = 0; } }
(horse1);
988
                }
989
            }
990
        }
991
    }
992
    if (type == 61)
993
    {
994
        if (btimer >= 40 && made == 0)
995
        {
996
            btimer = 0;
997
            made = 1;
998
            horse = 0;
999
            vseed = random(300);
1000
            for (j = 0; j < 3; j += 1)
1001
            {
1002
                for (i = 0; i < 3; i += 1)
1003
                {
1004
                    horse1 = instance_create(obj_battlesolid.x + 150, (obj_battlesolid.y - 80) + (i * 80), obj_carouselbullet);
1005
                    horse1.siner = j * 42;
1006
                    horse1.vsin = 0 + vseed;
1007
                    horse1.image_index = 0;
1008
                    horse1.altmode = 2;
1009
                    horse1.sinspeed = 1.1;
1010
                    
scr_bullet_inherit
scr_bullet_inherit

function
scr_bullet_inherit(arg0)
{ if (instance_exists(arg0)) { arg0.damage = damage; arg0.grazepoints = grazepoints; arg0.timepoints = timepoints; arg0.inv = inv; arg0.target = target; arg0.grazed = 0; arg0.grazetimer = 0; } }
(horse1);
1011
                    horse1 = instance_create(obj_battlesolid.x + 150, (obj_battlesolid.y - 80) + (i * 80), obj_carouselbullet);
1012
                    horse1.siner = (j * 42) + 21;
1013
                    horse1.vsin = 0 + vseed;
1014
                    horse1.image_index = 1;
1015
                    horse1.altmode = 1;
1016
                    horse1.sinspeed = 1.1;
1017
                    
scr_bullet_inherit
scr_bullet_inherit

function
scr_bullet_inherit(arg0)
{ if (instance_exists(arg0)) { arg0.damage = damage; arg0.grazepoints = grazepoints; arg0.timepoints = timepoints; arg0.inv = inv; arg0.target = target; arg0.grazed = 0; arg0.grazetimer = 0; } }
(horse1);
1018
                    chance = floor(random(50));
1019
                    if (chance == 1)
1020
                        horse1.image_index = 2;
1021
                }
1022
                if (horse == 0)
1023
                    horse = 1;
1024
                else
1025
                    horse = 0;
1026
            }
1027
        }
1028
    }
1029
    if (type == 62)
1030
    {
1031
        if (btimer >= 40 && made == 0)
1032
        {
1033
            btimer = 0;
1034
            made = 1;
1035
            for (i = 0; i < 3; i += 1)
1036
            {
1037
                for (j = 0; j < 7; j += 1)
1038
                {
1039
                    horse1 = instance_create(obj_battlesolid.x + 150, (obj_battlesolid.y - 80) + (i * 80), obj_carouselbullet);
1040
                    horse1.siner = j * 18;
1041
                    horse1.vsin = j * 9;
1042
                    horse1.sinspeed = 1.15;
1043
                    horse1.altmode = 3;
1044
                    
scr_bullet_inherit
scr_bullet_inherit

function
scr_bullet_inherit(arg0)
{ if (instance_exists(arg0)) { arg0.damage = damage; arg0.grazepoints = grazepoints; arg0.timepoints = timepoints; arg0.inv = inv; arg0.target = target; arg0.grazed = 0; arg0.grazetimer = 0; } }
(horse1);
1045
                }
1046
            }
1047
        }
1048
    }
1049
    if (type == 65)
1050
    {
1051
        if (btimer >= 60)
1052
        {
1053
            ring = instance_create(obj_battlesolid.x, obj_battlesolid.y, obj_spadering);
1054
            ring.maxspade = 10;
1055
            ring.grav = 0.4;
1056
            
scr_bullet_inherit
scr_bullet_inherit

function
scr_bullet_inherit(arg0)
{ if (instance_exists(arg0)) { arg0.damage = damage; arg0.grazepoints = grazepoints; arg0.timepoints = timepoints; arg0.inv = inv; arg0.target = target; arg0.grazed = 0; arg0.grazetimer = 0; } }
(ring);
1057
            btimer = 0;
1058
        }
1059
    }
1060
    if (type == 66)
1061
    {
1062
        if (btimer >= 30)
1063
        {
1064
            ring = instance_create(obj_battlesolid.x, obj_battlesolid.y, obj_spadering);
1065
            ring.maxspade = 6;
1066
            ring.grav = 3;
1067
            ring.size = 1.5;
1068
            
scr_bullet_inherit
scr_bullet_inherit

function
scr_bullet_inherit(arg0)
{ if (instance_exists(arg0)) { arg0.damage = damage; arg0.grazepoints = grazepoints; arg0.timepoints = timepoints; arg0.inv = inv; arg0.target = target; arg0.grazed = 0; arg0.grazetimer = 0; } }
(ring);
1069
            btimer = 0;
1070
        }
1071
    }
1072
    if (type == 67)
1073
    {
1074
        if (btimer >= 20)
1075
        {
1076
            ring = instance_create(obj_battlesolid.x, obj_battlesolid.y, obj_spadering);
1077
            ring.grav = 0.2;
1078
            ring.maxspade = 4;
1079
            ring.special = 1;
1080
            
scr_bullet_inherit
scr_bullet_inherit

function
scr_bullet_inherit(arg0)
{ if (instance_exists(arg0)) { arg0.damage = damage; arg0.grazepoints = grazepoints; arg0.timepoints = timepoints; arg0.inv = inv; arg0.target = target; arg0.grazed = 0; arg0.grazetimer = 0; } }
(ring);
1081
            btimer = 0;
1082
        }
1083
    }
1084
    if (type == 68)
1085
    {
1086
        with (obj_heart)
1087
            wspeed = 5;
1088
        if (btimer >= 54)
1089
        {
1090
            ring = instance_create(obj_battlesolid.x, obj_battlesolid.y, obj_spadering);
1091
            ring.side = choose(0, 1);
1092
            ring.grav = 0.45;
1093
            ring.maxspade = 10;
1094
            
scr_bullet_inherit
scr_bullet_inherit

function
scr_bullet_inherit(arg0)
{ if (instance_exists(arg0)) { arg0.damage = damage; arg0.grazepoints = grazepoints; arg0.timepoints = timepoints; arg0.inv = inv; arg0.target = target; arg0.grazed = 0; arg0.grazetimer = 0; } }
(ring);
1095
            btimer = 0;
1096
        }
1097
    }
1098
    if (type == 70)
1099
    {
1100
        if (btimer >= 20 && global.turntimer >= 30)
1101
        {
1102
            jokerx = choose(obj_battlesolid.x - 100 - random(100), obj_battlesolid.x + 100 + random(100));
1103
            jokery = choose(obj_battlesolid.y - random(100), obj_battlesolid.y + random(100));
1104
            jokern = instance_create(jokerx, jokery, obj_joker_teleport);
1105
            jokern.type = 1;
1106
            
scr_bullet_inherit
scr_bullet_inherit

function
scr_bullet_inherit(arg0)
{ if (instance_exists(arg0)) { arg0.damage = damage; arg0.grazepoints = grazepoints; arg0.timepoints = timepoints; arg0.inv = inv; arg0.target = target; arg0.grazed = 0; arg0.grazetimer = 0; } }
(jokern);
1107
            jokern.active = 0;
1108
            btimer = 0;
1109
        }
1110
    }
1111
    if (type == 71)
1112
    {
1113
        if (btimer >= 9 && global.turntimer >= 20)
1114
        {
1115
            jokerx = choose(obj_battlesolid.x - 100 - random(100), obj_battlesolid.x + 100 + random(100));
1116
            jokery = choose(obj_battlesolid.y - random(100), obj_battlesolid.y + random(100));
1117
            jokern = instance_create(jokerx, jokery, obj_joker_teleport);
1118
            
scr_bullet_inherit
scr_bullet_inherit

function
scr_bullet_inherit(arg0)
{ if (instance_exists(arg0)) { arg0.damage = damage; arg0.grazepoints = grazepoints; arg0.timepoints = timepoints; arg0.inv = inv; arg0.target = target; arg0.grazed = 0; arg0.grazetimer = 0; } }
(jokern);
1119
            jokern.active = 0;
1120
            btimer = 0;
1121
        }
1122
    }
1123
    if (type == 72)
1124
    {
1125
        if (btimer >= 18)
1126
        {
1127
            btimer = 0;
1128
            if (side == 1)
1129
                dir = choose(225, 315);
1130
            if (side == -1)
1131
                dir = choose(45, 135);
1132
            radius = 360;
1133
            xx = lengthdir_x(radius, dir);
1134
            yy = lengthdir_y(radius, dir);
1135
            d = instance_create(obj_heart.x + 8 + xx, obj_heart.y + 8 + yy, obj_clubsbullet_dark);
1136
            d.direction = dir + 180;
1137
            d.speed = 20;
1138
            d.friction = 1;
1139
            d.type = 2;
1140
            d.damage = damage;
1141
            d.target = target;
1142
            with (d)
1143
                image_angle = direction;
1144
            if (side == 1)
1145
                side = -1;
1146
            else
1147
                side = 1;
1148
        }
1149
    }
1150
    if (type == 73)
1151
    {
1152
        if (btimer >= 4)
1153
        {
1154
            btimer = 0;
1155
            radius = 140 + random(40);
1156
            yy = radius * side;
1157
            xx = -100 + random(200);
1158
            num = choose(0, 1, 2, 3);
1159
            if (num == 3)
1160
                xx = -10 + random(20);
1161
            if (instance_exists(obj_battlesolid))
1162
            {
1163
                db = instance_create(obj_heart.x + 8 + xx, obj_battlesolid.y + 100, obj_dbullet_vert);
1164
                with (db)
1165
                    type = 1;
1166
                db.damage = damage;
1167
                db.target = target;
1168
                db.timepoints = 2;
1169
            }
1170
        }
1171
    }
1172
    if (type == 74)
1173
    {
1174
        if (btimer >= 9)
1175
        {
1176
            btimer = 0;
1177
            radius = 140 + random(40);
1178
            yy = radius * side;
1179
            xx = -100 + random(200);
1180
            num = choose(0, 1, 2, 3);
1181
            if (num == 3)
1182
                xx = -10 + random(20);
1183
            d = instance_create(obj_heart.x + 8 + xx, obj_heart.y + 8 + yy, obj_dbullet_vert);
1184
            d.grazepoints = 12;
1185
            d.timepoints = 2;
1186
            d.damage = damage;
1187
            d.target = target;
1188
        }
1189
    }
1190
    if (type == 75 || type == 76)
1191
    {
1192
        if (btimer >= 0 && special == 0)
1193
        {
1194
            snd_play(snd_spearappear);
1195
            scythe = instance_create(0, 0, obj_centerscythe);
1196
            obj_centerscythe.damage = damage;
1197
            obj_centerscythe.grazepoints = grazepoints;
1198
            obj_centerscythe.timepoints = timepoints;
1199
            obj_centerscythe.inv = inv;
1200
            obj_centerscythe.target = target;
1201
            obj_centerscythe.grazed = 0;
1202
            obj_centerscythe.grazetimer = 0;
1203
            special = 1;
1204
        }
1205
    }
1206
    if (type == 77)
1207
    {
1208
        global.sp = 10;
1209
        with (obj_heart)
1210
            wspeed = 10;
1211
        if (special == 0)
1212
        {
1213
            snd_play(snd_joker_byebye);
1214
            prevmake = 0;
1215
            special = 1;
1216
            rank = 16;
1217
            realtimer = 0;
1218
            chase = 0;
1219
            made = 0;
1220
            amount = 0;
1221
            jokertimer = 0;
1222
            darkfader = 
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; }
(__view_get(e__VW.XView, 0) + 320, __view_get(e__VW.YView, 0) - 10, spr_tallpx);
1223
            with (darkfader)
1224
            {
1225
                depth = 2;
1226
                image_alpha = 0;
1227
                image_blend = c_black;
1228
                image_xscale = 200;
1229
                image_yscale = 2;
1230
            }
1231
        }
1232
        if (realtimer >= 0 && realtimer < 10)
1233
        {
1234
            with (darkfader)
1235
                image_alpha += 0.1;
1236
            with (obj_battlesolid)
1237
                image_alpha -= 0.1;
1238
            with (obj_heart)
1239
            {
1240
                y += 16;
1241
                boundaryup = 160;
1242
            }
1243
        }
1244
        if (realtimer == 10)
1245
        {
1246
            with (obj_battlesolid)
1247
                instance_destroy();
1248
        }
1249
        if (realtimer == 20)
1250
            instance_create(__view_get(e__VW.XView, 0) + 40, -60, obj_laserscythe);
1251
        if (realtimer == 40)
1252
            instance_create(__view_get(e__VW.XView, 0) + 570, -60, obj_laserscythe);
1253
        if (realtimer >= 60 && amount < 30)
1254
        {
1255
            if (btimer >= rank)
1256
            {
1257
                if (rank > 7)
1258
                    rank -= 1;
1259
                which = floor(random(5));
1260
                if (which == prevmake)
1261
                    which = floor(random(5));
1262
                if (chase == 3)
1263
                {
1264
                    which = floor((obj_heart.x + 8) / 90);
1265
                    chase = 0;
1266
                }
1267
                scythe = instance_create(__view_get(e__VW.XView, 0) + 40 + (90 * which), -60, obj_laserscythe);
1268
                if (which == 1)
1269
                    scythe2 = instance_create(__view_get(e__VW.XView, 0) + 40 + 450, -60, obj_laserscythe);
1270
                if (which == 0)
1271
                    scythe2 = instance_create(__view_get(e__VW.XView, 0) + 40 + 540, -60, obj_laserscythe);
1272
                prevmake = which;
1273
                btimer = 0;
1274
                chase += 1;
1275
                amount += 1;
1276
            }
1277
        }
1278
        if (amount >= (29 - made) && special == 1)
1279
        {
1280
            jokertimer = 0;
1281
            jokerin = instance_create(__view_get(e__VW.XView, 0) + 320, __view_get(e__VW.YView, 0) + 100, obj_joker_teleport);
1282
            with (jokerin)
1283
            {
1284
                type = 66;
1285
                depth = -30;
1286
            }
1287
            special = 2;
1288
            which2 = 0;
1289
        }
1290
        if (special == 2)
1291
        {
1292
            jokertimer += 1;
1293
            if (jokertimer == 10)
1294
                snd_play(
scr_84_get_sound
scr_84_get_sound

function
scr_84_get_sound(arg0)
{ var sound_file_name = arg0; if (global.lang == "ja") sound_file_name += "_ja"; return asset_get_index(sound_file_name); }
("snd_joker_neochaos"));
1295
            if (jokertimer == 40 || jokertimer == 98)
1296
            {
1297
                scythe = instance_create(__view_get(e__VW.XView, 0) + 40, -60, obj_laserscythe);
1298
                scythe = instance_create(__view_get(e__VW.XView, 0) + 580, -60, obj_laserscythe);
1299
            }
1300
            if (jokertimer == 46 || jokertimer == 86)
1301
            {
1302
                scythe = instance_create(__view_get(e__VW.XView, 0) + 130, -60, obj_laserscythe);
1303
                scythe = instance_create(__view_get(e__VW.XView, 0) + 490, -60, obj_laserscythe);
1304
            }
1305
            if (jokertimer == 52 || jokertimer == 80)
1306
            {
1307
                scythe = instance_create(__view_get(e__VW.XView, 0) + 220, -60, obj_laserscythe);
1308
                scythe = instance_create(__view_get(e__VW.XView, 0) + 400, -60, obj_laserscythe);
1309
            }
1310
            if (jokertimer == 66 || jokertimer == 98)
1311
                scythe = instance_create(__view_get(e__VW.XView, 0) + 310, -60, obj_laserscythe);
1312
            if (jokertimer == 130)
1313
            {
1314
                lastscythe = instance_create(__view_get(e__VW.XView, 0) + 320, -320, obj_laserscythe);
1315
                p = 0;
1316
                vol = 0;
1317
                vol2 = 1;
1318
                rumnoise = audio_play_sound(snd_rumble, 50, 1);
1319
                with (lastscythe)
1320
                {
1321
                    vspeed = 1;
1322
                    gravity = 0.02;
1323
                    image_xscale = 16;
1324
                    image_yscale = 16;
1325
                    scale = 16;
1326
                    rotspeed = 0;
1327
                    remrot = 160;
1328
                    image_angle = 160;
1329
                }
1330
                fadewhite = instance_create(__view_get(e__VW.XView, 0) + 320, __view_get(e__VW.YView, 0) - 40, obj_marker);
1331
                fadewhite.sprite_index = spr_tallpx;
1332
                fadewhite.image_xscale = 400;
1333
                fadewhite.image_yscale = 2;
1334
                fadewhite.depth = -100;
1335
                fadewhite.image_alpha = -0.3;
1336
            }
1337
            if (jokertimer >= 131)
1338
            {
1339
                with (lastscythe)
1340
                    x = xstart + random(8);
1341
                with (fadewhite)
1342
                    image_alpha += 0.01;
1343
                vol += 0.01;
1344
                if (fadewhite.image_alpha >= 1)
1345
                {
1346
                    with (darkfader)
1347
                        instance_destroy();
1348
                    with (lastscythe)
1349
                        instance_destroy();
1350
                }
1351
                if (fadewhite.image_alpha >= 1.3)
1352
                    special = 3;
1353
            }
1354
        }
1355
        if (special == 3)
1356
        {
1357
            with (obj_heart)
1358
            {
1359
                x = __view_get(e__VW.XView, 0) + 320;
1360
                y = __view_get(e__VW.YView, 0) + 120;
1361
            }
1362
            vol -= 0.1;
1363
            audio_sound_gain(rumnoise, vol, 0);
1364
            with (fadewhite)
1365
                image_alpha -= 0.1;
1366
            if (fadewhite.image_alpha <= 0)
1367
            {
1368
                audio_stop_sound(rumnoise);
1369
                global.turntimer = 11;
1370
                special = 4;
1371
            }
1372
        }
1373
        realtimer += 1;
1374
    }
1375
}
1376
1377
enum e__VW
1378
{
1379
    XView,
1380
    YView,
1381
    WView,
1382
    HView,
1383
    Angle,
1384
    HBorder,
1385
    VBorder,
1386
    HSpeed,
1387
    VSpeed,
1388
    Object,
1389
    Visible,
1390
    XPort,
1391
    YPort,
1392
    WPort,
1393
    HPort,
1394
    Camera,
1395
    SurfaceID
1396
}