Undertale Yellow script viewer

← back to main script listing

gml_Object_obj_battle_enemy_attack_axis_geno_1_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 ball_offset = 30
5
switch attack_tick
6
{
7
    case 30:
8
        var x_origin = battle_box.x
9
        var y_origin = battle_box.bbox_top - 50
10
        var ball_dir = 270
11
        for (var i = ball_dir - ball_offset; i <= (ball_dir + ball_offset); i += ball_offset)
12
        {
13
            var ball = instance_create_depth((x_origin + (lengthdir_x(45, i))), (y_origin + (lengthdir_y(45, i))), -100, obj_battle_enemy_attack_axis_energy_ball_boss_geno)
14
            ball.direction = i
15
            ball.alarm[0] = 30
16
        }
17
        break
18
    case 90:
19
        x_origin = battle_box.bbox_left - 50
20
        y_origin = battle_box.y
21
        ball_dir = 0
22
        for (i = ball_dir - ball_offset; i <= (ball_dir + ball_offset); i += ball_offset)
23
        {
24
            ball = instance_create_depth((x_origin + (lengthdir_x(45, i))), (y_origin + (lengthdir_y(45, i))), -100, obj_battle_enemy_attack_axis_energy_ball_boss_geno)
25
            ball.direction = i
26
            ball.alarm[0] = 30
27
        }
28
        break
29
    case 120:
30
        x_origin = battle_box.bbox_left - 25
31
        y_origin = battle_box.bbox_bottom + 25
32
        ball_dir = 45
33
        for (i = ball_dir - ball_offset; i <= (ball_dir + ball_offset); i += ball_offset)
34
        {
35
            ball = instance_create_depth((x_origin + (lengthdir_x(45, i))), (y_origin + (lengthdir_y(45, i))), -100, obj_battle_enemy_attack_axis_energy_ball_boss_geno)
36
            ball.direction = i
37
            ball.alarm[0] = 30
38
        }
39
        break
40
    case 175:
41
        x_origin = battle_box.bbox_right + 50
42
        y_origin = battle_box.y
43
        ball_dir = 180
44
        for (i = ball_dir - ball_offset; i <= (ball_dir + ball_offset); i += ball_offset)
45
        {
46
            ball = instance_create_depth((x_origin + (lengthdir_x(45, i))), (y_origin + (lengthdir_y(45, i))), -100, obj_battle_enemy_attack_axis_energy_ball_boss_geno)
47
            ball.direction = i
48
            ball.alarm[0] = 30
49
        }
50
        break
51
    case 250:
52
        instance_destroy()
53
        break
54
}
55
56
attack_tick += 1