Deltarune (Chapter 5) script viewer

← back to main script listing

gml_Object_obj_bramble_Create_0

(view raw script w/o annotations or w/e)
1
event_inherited();
2
hp = 1;
3
4
susie_act = function()
5
{
6
    on_acted();
7
};
8
9
on_acted = function()
10
{
11
};
12
13
scr_platswap_init
scr_platswap_init

function
scr_platswap_init(arg0 = undefined, arg1 = true)
{ if (!instance_exists(obj_platswap)) return -4; if (!instance_exists(obj_platswap_helper)) instance_create(0, 0, obj_platswap_helper); var _helper = 658; if (arg0 == undefined) { ignore_yorigin = 0; if (!variable_instance_exists(id, "force_yplat")) force_yplat = false; with (_helper) init_platswap(other.id, arg1); return _helper; } if (instance_exists(arg0)) { with (arg0) { if (!variable_instance_exists(id, "force_yplat")) force_yplat = false; ignore_yorigin = 0; with (_helper) init_platswap(arg0.id, arg1); return _helper; } } } function scr_platswap_init_alt(arg0 = id, arg1 = true) { if (!instance_exists(obj_platswap)) return -4; if (!instance_exists(obj_platswap_helper)) instance_create(0, 0, obj_platswap_helper); if (instance_exists(arg0)) { with (arg0) { ignore_yorigin = 1; if (!variable_instance_exists(id, "force_yplat")) force_yplat = false; with (_helper) init_platswap(other.id, arg1); return _helper; } } } function scr_plat_make_pauseable(arg0 = id) { if (!instance_exists(obj_platswap)) return -4; if (!instance_exists(obj_plat_pausing_helper)) instance_create(0, 0, obj_plat_pausing_helper); with (obj_plat_pausing_helper) add_object(arg0); }
(self, 2);
14
image_speed = 0;
15
parent = -4;
16
parentoffset = 0;
17
init = 0;
18
19
on_slashed = function()
20
{
21
};
22
23
lerper = -4;
24
_act = -4;
25
var bottom = -4;
26
if (image_yscale > 2)
27
{
28
    scr_plat_set_depth_offset(-40);
29
    var maxvines = floor(image_yscale / 2) - 1;
30
    for (var i = maxvines; i >= 0; i--)
31
    {
32
        var vine = instance_create_depth(x, y + (40 * i), depth, obj_bramble);
33
        vine.hitstop = hitstop;
34
        if (bottom == -4)
35
            bottom = vine;
36
        with (vine)
37
        {
38
            image_blend = other.image_blend;
39
            parent = bottom;
40
            parentoffset = 40 * (maxvines - i);
41
            scr_plat_set_depth_offset(-40);
42
            
scr_darksize
scr_darksize

function
scr_darksize()
{ var inst = id; if (argument_count) inst = argument0; inst.image_xscale = 2; inst.image_yscale = 2; }
();
43
            if (i == (floor(other.image_yscale / 2) - 2) && instance_exists(obj_dw_garden_aquaplatforming))
44
                _act = 
scr_configure_platmode_act
scr_configure_platmode_act

function
scr_configure_platmode_act(arg0, arg1, arg2, arg3)
{ var helper = instance_create(x, y, obj_plat_targethelper); helper.owner = self; helper.effect = arg0; helper.char = arg1; helper.objectname = arg2; helper.description = arg3; if (!variable_instance_exists(id, "__plat_acts")) __plat_acts = []; array_push(__plat_acts, helper); return helper; } function scr_set_platmode_act_active(arg0, arg1 = "*") { if (variable_instance_exists(id, "__plat_acts")) { for (var i = 0; i < array_length(__plat_acts); i++) { if (arg1 == "*" || __plat_acts.char == arg1) active = arg0; } } } function scr_destroy_platmode_act() { if (variable_instance_exists(id, "__plat_acts")) { for (var i = 0; i < array_length(__plat_acts); i++) { with (__plat_acts[i]) instance_destroy(); } } }
(other.susie_act, "su", stringsetloc(
Vinesbuster
"Vinesbuster", "obj_bramble_slash_Create_0_gml_38_0"
), stringsetloc(
Huh? You want me to cut it down?
"Huh? You want me to cut it down?", "obj_bramble_slash_Create_0_gml_39_0"
));
45
        }
46
    }
47
    parent = bottom;
48
    parentoffset = maxvines * 40;
49
    image_yscale = 2;
50
}
51
fademarker = instance_create(x, y, obj_marker_fancy);
52
with (fademarker)
53
{
54
    lerper = -4;
55
    image_alpha = 0;
56
    image_speed = 0;
57
    sprite_index = other.sprite_index;
58
    
scr_darksize
scr_darksize

function
scr_darksize()
{ var inst = id; if (argument_count) inst = argument0; inst.image_xscale = 2; inst.image_yscale = 2; }
();
59
    image_blend = other.image_blend;
60
    parent = other;
61
    depth = other.depth;
62
    
63
    step_func = function()
64
    {
65
        depth = parent.depth - 1;
66
        x = parent.x;
67
        y = parent.y;
68
    };
69
}