Deltarune (Chapter 3) script viewer

← back to main script listing

gml_Object_obj_precipitation_bullet_parent_Collision_obj_celestial_body_parent

(view raw script w/o annotations or w/e)
1
var temph = other.hspeed;
2
var tempv = other.vspeed;
3
if (overpower)
4
{
5
    snd_stop(snd_noise);
6
    snd_play_pitch(snd_noise, 0.8);
7
    with (other)
8
    {
9
        repeat (other.overpower)
10
        {
11
            image_xscale *= 0.92;
12
            image_yscale *= 0.92;
13
        }
14
    }
15
    if (other.image_xscale < 0.5)
16
    {
17
        instance_destroy(other.id);
18
    }
19
    else
20
    {
21
        if (object_index == obj_bullet_snow && other.object_index == obj_bullet_submoon)
22
            other.slow_factor += (24 * sqr(overpower));
23
        if (object_index == obj_bullet_rain && other.object_index == obj_bullet_submoon)
24
            other.push = vspeed / 2;
25
    }
26
    instance_destroy();
27
    if (other.sprite_index == spr_lanino_moon)
28
    {
29
        repeat (3)
30
        {
31
            with (instance_create(x, y, obj_bulletparent))
32
            {
33
                hspeed = -2 + random(3) + temph;
34
                vspeed = (-3 - random(2)) + tempv;
35
                gravity = 0.25;
36
                sprite_index = spr_ball;
37
                image_speed = 0;
38
                image_blend = c_gray;
39
                image_xscale = 0.1;
40
                image_yscale = 0.1;
41
                
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_alpha", 1, 0, 30);
42
                
scr_script_delayed
scr_script_delayed

function
scr_script_delayed()
{ var __scriptdelay = instance_create(0, 0, obj_script_delayed); __scriptdelay.script = argument[0]; __scriptdelay.alarm[0] = argument[1]; __scriptdelay.target = id; for (var __i = 0; __i < (argument_count - 2); __i++) __scriptdelay.script_arg[__i] = argument[__i + 2]; __scriptdelay.arg_count = argument_count - 2; return __scriptdelay; }
(instance_destroy, 30);
43
            }
44
        }
45
    }
46
    if (other.sprite_index == spr_lanino_sun)
47
    {
48
        with (instance_create(x, y, obj_regularbullet))
49
        {
50
            active = false;
51
            spin = 1;
52
            spinspeed = random(5) - 0.25;
53
            direction = 70 + random(40);
54
            speed = 1 + random(1);
55
            image_xscale = 0.5;
56
            image_yscale = 0.5;
57
            sprite_index = spr_cakesmoke;
58
            
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_alpha", 1, 0, 30);
59
            
scr_script_delayed
scr_script_delayed

function
scr_script_delayed()
{ var __scriptdelay = instance_create(0, 0, obj_script_delayed); __scriptdelay.script = argument[0]; __scriptdelay.alarm[0] = argument[1]; __scriptdelay.target = id; for (var __i = 0; __i < (argument_count - 2); __i++) __scriptdelay.script_arg[__i] = argument[__i + 2]; __scriptdelay.arg_count = argument_count - 2; return __scriptdelay; }
(instance_destroy, 30);
60
        }
61
    }
62
}