Undertale Yellow script viewer

← back to main script listing

gml_Object_obj_dummy_training_dummy_Step_0

(view raw script w/o annotations or w/e)
1
var enemy_dead = global.enemy_dead;
2
var enemy_spared = global.enemy_spared;
3
if (enemy_dead == false && enemy_spared == false)
4
    image_alpha = global.image_alpha_enemy_attacking;
5
if (enemy_dead == true)
6
{
7
    x = starting_point_x;
8
    y = starting_point_y;
9
    instance_create(starting_point_x, starting_point_y, obj_dummy_training_dummy);
10
    instance_destroy();
11
    exit;
12
    image_alpha = 0.5;
13
}
14
else if (enemy_spared == true)
15
{
16
    sprite_index = spr_dummy_training_dummy;
17
    x = starting_point_x;
18
    y = starting_point_y;
19
    image_alpha = 0.5;
20
    if (no_loop_create_clouds == false)
21
    {
22
        for (i = 0; i <= 11; i += 1)
23
            instance_create(x, y, obj_spare_cloud);
24
    }
25
    no_loop_create_clouds = true;
26
}
27
if (damage_disjoint_count > 0)
28
{
29
    damage_disjoint_count -= 1;
30
}
31
else if (enemy_dead == false && enemy_spared == false)
32
{
33
    if (global.enemy_low_hp == true && global.current_hp_enemy < global.max_hp_enemy)
34
        sprite_index = spr_dummy_training_dummy;
35
    else
36
        sprite_index = spr_dummy_training_dummy;
37
    image_speed = 0;
38
}
39
if (instance_exists(obj_text_damage_count) && global.fight_number == 1 && no_loop_damage_disjoint_count == false)
40
{
41
    time_elapsed = 0;
42
    sign_modifier = -1;
43
    damage_disjoint_count = 12;
44
    no_loop_damage_disjoint_count = true;
45
}
46
else if (!instance_exists(obj_text_damage_count))
47
{
48
    no_loop_damage_disjoint_count = false;
49
}
50
if (damage_disjoint_count == 12)
51
    damage_disjoint_x = -50;
52
else if (damage_disjoint_count == 10)
53
    damage_disjoint_x = 50;
54
else if (damage_disjoint_count == 8)
55
    damage_disjoint_x = -20;
56
else if (damage_disjoint_count == 6)
57
    damage_disjoint_x = 20;
58
else if (damage_disjoint_count == 4)
59
    damage_disjoint_x = -10;
60
else if (damage_disjoint_count == 2)
61
    damage_disjoint_x = 10;
62
else if (damage_disjoint_count == 0)
63
    damage_disjoint_x = 0;
64
if (damage_disjoint_count > 0 || global.current_hp_enemy <= 0)
65
    sprite_index = spr_dummy_training_dummy;
66
x = draw_position_x + damage_disjoint_x;
67
y = draw_position_y + damage_disjoint_y;
68
if (!(instance_exists(obj_text_damage_count) && global.fight_number == 1) && enemy_dead == false && enemy_spared == false)
69
{
70
}