Deltarune (Chapter 4) script viewer

← back to main script listing

gml_GlobalScript_scr_mouse

(view raw script w/o annotations or w/e)
1
function scr_mouse_x()
2
{
3
    return mouse_x;
4
}
5
6
function scr_mouse_y()
7
{
8
    return mouse_y;
9
}
10
11
function scr_mouse_left()
12
{
13
    if (!(global.is_console || onSteamDeck()))
14
        return mouse_check_button(mb_left);
15
    else
16
        return button1_h();
17
}
18
19
function scr_mouse_leftclick()
20
{
21
    if (!(global.is_console || onSteamDeck()))
22
        return mouse_check_button_pressed(mb_left);
23
    else
24
        return button1_p();
25
}
26
27
function scr_mouse_leftrelease()
28
{
29
    if (!(global.is_console || onSteamDeck()))
30
        return mouse_check_button_released(mb_left);
31
    else
32
        return button1_r();
33
}
34
35
function scr_mouse_right()
36
{
37
    if (!(global.is_console || onSteamDeck()))
38
        return mouse_check_button(mb_right);
39
    else
40
        return button2_h();
41
}
42
43
function scr_mouse_rightclick()
44
{
45
    if (!(global.is_console || onSteamDeck()))
46
        return mouse_check_button_pressed(mb_right);
47
    else
48
        return button2_p();
49
}
50
51
function scr_mouse_rightrelease()
52
{
53
    if (!(global.is_console || onSteamDeck()))
54
        return mouse_check_button_released(mb_right);
55
    else
56
        return button1_r();
57
}