Deltarune (Chapter 3) script viewer

← back to main script listing

gml_Object_obj_board_softsolid_Step_2

related scripts: Create_0Step_2

(view raw script w/o annotations or w/e)
1
var met = instance_place(x, y, obj_mainchara_board);
2
if (i_ex(met))
3
{
4
    if (room == room_board_dungeon_2)
5
    {
6
        visible = false;
7
        debug_print("pushing" + string(pushdir));
8
        if (pushdir == 2)
9
            met.y += 4;
10
        if (pushdir == 0)
11
            met.y -= 4;
12
        if (pushdir == 1)
13
            met.x += 4;
14
        if (pushdir == 3)
15
            met.x -= 4;
16
    }
17
    else
18
    {
19
        if (pushdir == 0)
20
            met.y = (bbox_bottom + 2) - 16;
21
        if (pushdir == 1)
22
            met.x = bbox_right + 2;
23
        if (pushdir == 2)
24
            met.y = bbox_top - 2;
25
        if (pushdir == 3)
26
            met.x = bbox_left - 2 - 32;
27
    }
28
}