Deltarune (Chapter 3) script viewer

← back to main script listing

gml_Object_obj_roaringknight_splitslash_Other_15

(view raw script w/o annotations or w/e)
1
if (active == 1 && 
scr_precise_hit
scr_precise_hit

function
scr_precise_hit(arg0 = 3, arg1 = false)
{ arg0 /= 2; var _hx = obj_heart.x + 10; var _hy = obj_heart.y + 10; if (arg0 <= 0) return collision_point(_hx, _hy, id, true, false); else if (arg1) return collision_circle(_hx, _hy, arg0, id, true, false); else return collision_rectangle(_hx - arg0, _hy - arg0, _hx + arg0, _hy + arg0, id, true, false); }
(3))
2
{
3
    playerstrike = 1;
4
    active = 0;
5
    memheartx = obj_heart.x;
6
    memhearty = obj_heart.y;
7
    obj_heart.image_alpha = 0;
8
    global.inv = -1;
9
    cuty = round(remap_clamped(-16, 16, 1, 14, obj_heart.y - (y - 8)));
10
    obj_knight_split_growtangle.split_delay = 5;
11
    obj_roaringknight_boxsplitter_attack.timer -= 5;
12
    obj_roaringknight_boxsplitter_attack.local_turntimer += 5;
13
    hurt_delay = obj_knight_split_growtangle.split_wait;
14
}