Undertale Yellow script viewer

← back to main script listing

gml_Object_obj_battle_enemy_attack_cactony_needle_side_generator_Other_10

(view raw script w/o annotations or w/e)
1
var box = obj_dialogue_box_battle_transformation_any
2
var random_direction = irandom_range(0, 1)
3
if (random_direction == 0)
4
    var create_x = box.bbox_left + 5
5
else
6
    create_x = box.bbox_right - 5
7
create_y = irandom_range(y_min, y_max)
8
instance_create(create_x, create_y, obj_battle_enemy_attack_cactony_needle_side_needle)
9
needle_count += 1
10
if (needle_count < needle_max)
11
    alarm[0] = attack_alarm
alarm[0]

event_user(0)
12
else
13
    alarm[1] = end_alarm
alarm[1]

instance_destroy()