Deltarune (Chapter 4) script viewer

← back to main script listing

gml_GlobalScript_scr_screenspace

(view raw script w/o annotations or w/e)
1
function screenx(arg0 = x)
2
{
3
    return arg0 - camerax();
4
}
5
6
function screeny(arg0 = y)
7
{
8
    return arg0 - cameray();
9
}
10
11
function draw_self_screenspace()
12
{
13
    draw_sprite_ext(sprite_index, image_index, screenx(), screeny(), image_xscale, image_yscale, image_angle, image_blend, image_alpha);
14
}
15
16
function draw_self_screenspace_offset(arg0, arg1)
17
{
18
    draw_sprite_ext(sprite_index, image_index, screenx() + arg0, screeny() + arg1, image_xscale, image_yscale, image_angle, image_blend, image_alpha);
19
}
20
21
function draw_self_surfacespace(arg0, arg1)
22
{
23
    draw_sprite_ext(sprite_index, image_index, x - arg0, y - arg1, image_xscale, image_yscale, image_angle, image_blend, image_alpha);
24
}
25
26
function screenx_ext(arg0 = camerax(), arg1 = x)
27
{
28
    return arg1 - arg0;
29
}
30
31
function screeny_ext(arg0 = cameray(), arg1 = y)
32
{
33
    return arg1 - arg0;
34
}