Undertale Yellow script viewer

← back to main script listing

gml_Object_obj_battle_enemy_attack_space_frog_Step_0

(view raw script w/o annotations or w/e)
1
if live_call()
2
    return global.live_result;
3
var battle_box = obj_dialogue_box_battle_transformation_any
4
var soul = obj_heart_battle_fighting_red
5
if (stage == 0)
6
{
7
    if (x < (battle_box.bbox_left + 40))
8
        x += 3
9
    else
10
        stage = 1
11
}
12
if (stage == 1)
13
{
14
    if (!alarm[0])
15
        alarm[0] = shoot_delay
alarm[0]

if live_call() return global.live_result; var shot = instance_create_depth((x + 5), y, (depth + 1), obj_battle_space_frog_bullet) shot.hspeed = 10 audio_play_sound(snd_yellow_soul_shoot, 1, 0)
16
}
17
if (stage < 2)
18
{
19
    if (abs(y - soul.y) > 0.1)
20
        y = lerp(y, soul.y, 0.15)
21
}
22
depth = -51