Deltarune (Chapter 4) script viewer

← back to main script listing

gml_Object_obj_book_bullet_Step_0

(view raw script w/o annotations or w/e)
1
if (global.turntimer < 1)
2
    instance_destroy();
3
if (wall_destroy == 1)
4
{
5
    if (x < (__view_get(e__VW.XView, 0) - 80))
6
        instance_destroy();
7
    if (x > (__view_get(e__VW.XView, 0) + 760))
8
        instance_destroy();
9
    if (y < (__view_get(e__VW.YView, 0) - 80))
10
        instance_destroy();
11
    if (y > (__view_get(e__VW.YView, 0) + 580))
12
        instance_destroy();
13
}
14
if (updateimageangle == 1)
15
    image_angle = direction;
16
if (spin == 1)
17
    image_angle += spinspeed;
18
if (bottomfade != 0)
19
{
20
    if (y > (cameray() + bottomfade))
21
        image_alpha *= 0.8;
22
}
23
if (i_ex(obj_growtangle))
24
{
25
    if (x >= (obj_growtangle.x - 75) && x <= (obj_growtangle.x + 75) && y >= (obj_growtangle.y - 75) && y <= (obj_growtangle.y + 75))
26
    {
27
        insidebox++;
28
    }
29
    else if (insidebox > 14 || (insidebox > 0 && sprite_index != spr_magic_book_fire))
30
    {
31
        image_alpha -= 0.1;
32
        if (sprite_index == spr_magic_book_fire)
33
            image_alpha -= 0.1;
34
        if (image_alpha <= 0)
35
            instance_destroy();
36
    }
37
}
38
else
39
{
40
    instance_destroy();
41
}
42
43
enum e__VW
44
{
45
    XView,
46
    YView,
47
    WView,
48
    HView,
49
    Angle,
50
    HBorder,
51
    VBorder,
52
    HSpeed,
53
    VSpeed,
54
    Object,
55
    Visible,
56
    XPort,
57
    YPort,
58
    WPort,
59
    HPort,
60
    Camera,
61
    SurfaceID
62
}