Deltarune (Chapter 3) script viewer

← back to main script listing

gml_Object_obj_board_b3undergroundright_warpdoor_Step_0

(view raw script w/o annotations or w/e)
1
var triggered = false;
2
if (place_meeting(x, y, obj_mainchara_board))
3
{
4
    var char = instance_place(x, y, obj_mainchara_board);
5
    if (char.name == "kris")
6
        triggered = true;
7
}
8
if (triggered == true && obj_board_camera.con == 0)
9
{
10
    if (audio_exists(playsound))
11
        snd_play(playsound);
12
    var targx = 1920;
13
    var targy = 1152;
14
    if (instance_place(targx + obj_board_camera.originX, targy + obj_board_camera.originY, obj_b3cactusflirt))
15
    {
16
        targx = 1952;
17
        targy = 1120;
18
    }
19
    with (obj_board_camera)
20
    {
21
        shift = "warp";
22
        warpx = other.warpx;
23
        warpy = other.warpy;
24
        playerX = targx;
25
        playerY = targy;
26
        global.interact = 1;
27
    }
28
}