Undertale Yellow script viewer

← back to main script listing

gml_Object_obj_battle_enemy_attack_axis_turrets_2_Alarm_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 side = choose(1, 2, 3, 4)
5
var xx = battle_box.x
6
var yy = battle_box.y
7
switch side
8
{
9
    case 1:
10
        xx = battle_box.bbox_left - 20
11
        yy = battle_box.bbox_top - 20
12
        break
13
    case 2:
14
        xx = battle_box.bbox_right + 20
15
        yy = battle_box.bbox_top - 20
16
        break
17
    case 3:
18
        xx = battle_box.bbox_right + 20
19
        yy = battle_box.bbox_bottom + 20
20
        break
21
    case 4:
22
        xx = battle_box.bbox_left - 20
23
        yy = battle_box.bbox_bottom + 20
24
        break
25
}
26
27
var twinkle = instance_create_depth(xx, yy, -100, obj_battle_enemy_attack_axis_turret_twinkle_2)
28
twinkle.side = side
29
turret_count--
30
if (turret_count <= 0)
31
    instance_destroy()