Deltarune (Chapter 3) script viewer

← back to main script listing

gml_GlobalScript_scr_surfacespace

(view raw script w/o annotations or w/e)
1
function surfacex(arg0, arg1 = -1)
2
{
3
    if (arg1 > -1)
4
        arg1 = clamp01(surface_get_target());
5
    arg0 = (argument_count == 1) ? argument[0] : y;
6
    if (arg1 == 0)
7
        return screenx();
8
    else
9
        return x;
10
}
11
12
function surfacey(arg0 = -1)
13
{
14
    var __yy = (argument_count == 1) ? argument[0] : y;
15
    return __yy - cameray();
16
}
17
18
function draw_self_surfacespace(arg0 = -1)
19
{
20
    draw_sprite_ext(sprite_index, image_index, screenx(), screeny(), image_xscale, image_yscale, image_angle, image_blend, image_alpha);
21
}
22
23
function draw_self_surfacespace_offset(arg0, arg1, arg2 = -1)
24
{
25
    draw_sprite_ext(sprite_index, image_index, screenx() + arg0, screeny() + arg1, image_xscale, image_yscale, image_angle, image_blend, image_alpha);
26
}