Deltarune (Chapter 3) script viewer

← back to main script listing

gml_Object_obj_susiezilla_singlescreen_hazard_Create_0

(view raw script w/o annotations or w/e)
1
destroy_onhit = true;
2
unstoppable = false;
3
facing = 0;
4
change_sides = false;
5
friendly = false;
6
damage = 10;
7
knockback = 10;
8
draw_angle = 0;
9
bounce_off_dir = -100;
10
myxcenter = x;
11
myycenter = y;
12
myhitscale = 4;
13
force_depth = -999999;
14
15
bounce_off = function()
16
{
17
    with (instance_create_depth(x, y, depth, obj_dozer_parts))
18
    {
19
        sprite_index = other.sprite_index;
20
        image_angle = irandom(360);
21
        
scr_lerpvar
scr_lerpvar

function
scr_lerpvar()
{ if (argument_count < 6) ___lerpvar =
scr_lerpvar_instance(id, argument[0], argument[1], argument[2], argument[3]);
else ___lerpvar =
scr_lerpvar_instance(id, argument[0], argument[1], argument[2], argument[3], argument[4], argument[5]);
return ___lerpvar; } function scr_lerpvar_respect() { if (argument_count < 6) ___lerpvar =
scr_lerpvar_instance(id, argument[0], argument[1], argument[2], argument[3]);
else ___lerpvar =
scr_lerpvar_instance(id, argument[0], argument[1], argument[2], argument[3], argument[4], argument[5]);
___lerpvar.respectglobalinteract = true; return ___lerpvar; }
("image_angle", image_angle, image_angle + ((90 + irandom(270)) * choose(-1, 1)), 30 + irandom(60));
22
        image_speed = 0;
23
        image_index = 0;
24
        image_xscale = other.image_xscale;
25
        image_yscale = image_xscale;
26
        if (other.bounce_off_dir == -100)
27
            h_speed = (-sign(other.facing) * 1) + (random(5) * -sign(other.facing));
28
        else
29
            h_speed = other.bounce_off_dir + (random(5) * other.bounce_off_dir);
30
        v_speed = -4 - random(8);
31
        do_shadow = true;
32
        ground = other.y + 60;
33
    }
34
};