Undertale Yellow script viewer

← back to main script listing

gml_GlobalScript_scr_recreate_heart_battle_menu_text_know_cone_insomnitot_duo

(view raw script w/o annotations or w/e)
1
function scr_recreate_heart_battle_menu_text_know_cone_insomnitot_duo
scr_recreate_heart_battle_menu_text_know_cone_insomnitot_duo

function scr_recreate_heart_battle_menu_text_know_cone_insomnitot_duo() //gml_Script_scr_recreate_heart_battle_menu_text_know_cone_insomnitot_duo { var last_text_move_select = global.last_text_move_select var action_3_selected_count_2 = global.action_3_selected_count_2 var heart_position = script_execute(gml_Script_scr_return_heart_battle_menu_position) if (text_deadlock_1 == true) instance_create((obj_dialogue_box_battle.x + 20), (obj_dialogue_box_battle.x + 20), text_deadlock_contents_1) else if (last_text_move_select == 0) { instance_create((obj_dialogue_box_battle.x + 20), (obj_dialogue_box_battle.x + 20), obj_dialogue_battle_move_select_intro) text_deadlock_contents_1 = 3004 text_deadlock_1 = true } else if (global.battle_menu_number == 1 && global.enemy_dead == true && global.fight_number == 1) { instance_create((obj_dialogue_box_battle.x + 20), (obj_dialogue_box_battle.x + 20), obj_dialogue_battle_move_select_dead_2) text_deadlock_contents_1 = 3052 text_deadlock_1 = true } else if (global.battle_menu_number == 1 && global.enemy_dead_2 == true && global.fight_number == 2) { instance_create((obj_dialogue_box_battle.x + 20), (obj_dialogue_box_battle.x + 20), obj_dialogue_battle_move_select_dead) text_deadlock_contents_1 = 3033 text_deadlock_1 = true } else if (global.enemy_low_hp == true && global.enemy_dead == false && global.enemy_spared == false) { var random_number = irandom_range(1, 2) if (random_number == 1) { instance_create((obj_dialogue_box_battle.x + 20), (obj_dialogue_box_battle.x + 20), obj_dialogue_battle_move_select_low_hp_1) text_deadlock_contents_1 = 3016 } else if (random_number == 2) { instance_create((obj_dialogue_box_battle.x + 20), (obj_dialogue_box_battle.x + 20), obj_dialogue_battle_move_select_low_hp_1_v2) text_deadlock_contents_1 = 3018 } text_deadlock_1 = true } else if (global.enemy_low_hp_2 == true && global.enemy_dead_2 == false && global.enemy_spared_2 == false) { random_number = irandom_range(1, 2) if (random_number == 1) { instance_create((obj_dialogue_box_battle.x + 20), (obj_dialogue_box_battle.x + 20), obj_dialogue_battle_move_select_low_hp_2) text_deadlock_contents_1 = 3036 } else if (random_number == 2) { instance_create((obj_dialogue_box_battle.x + 20), (obj_dialogue_box_battle.x + 20), obj_dialogue_battle_move_select_low_hp_2_v2) text_deadlock_contents_1 = 3037 } text_deadlock_1 = true } else if (global.enemy_sparing == true && global.enemy_dead == false && global.enemy_spared == false) { instance_create((obj_dialogue_box_battle.x + 20), (obj_dialogue_box_battle.x + 20), obj_dialogue_battle_move_select_sparing) text_deadlock_contents_1 = 3030 text_deadlock_1 = true } else if (global.enemy_sparing_2 == true && global.enemy_dead_2 == false && global.enemy_spared_2 == false) { random_number = irandom_range(1, 2) if (random_number == 1) { instance_create((obj_dialogue_box_battle.x + 20), (obj_dialogue_box_battle.x + 20), obj_dialogue_battle_move_select_sparing_2) text_deadlock_contents_1 = 3050 } else if (random_number == 2) { instance_create((obj_dialogue_box_battle.x + 20), (obj_dialogue_box_battle.x + 20), obj_dialogue_battle_move_select_sparing_2_v2) text_deadlock_contents_1 = 3051 } text_deadlock_1 = true } else if (action_3_selected_count_2 >= 1 && heart_position == "2222") { instance_create((obj_dialogue_box_battle.x + 20), (obj_dialogue_box_battle.x + 20), obj_dialogue_battle_move_select_action_3_v2) text_deadlock_contents_1 = 3034 text_deadlock_1 = true } else { random_number = irandom_range(1, 2) if (global.enemy_dead == true || global.enemy_spared == true) random_number = 2 else if (global.enemy_dead_2 == true || global.enemy_spared_2 == true) random_number = 1 if (random_number == 1) { if ((global.enemy_dead_2 + global.enemy_spared_2) < 1) var random_text_move_select = irandom_range(1, 8) else random_text_move_select = irandom_range(1, 5) } else if (random_number == 2) { if ((global.enemy_dead + global.enemy_spared) < 1) random_text_move_select = irandom_range(1, 6) else ...
() //gml_Script_scr_recreate_heart_battle_menu_text_know_cone_insomnitot_duo
2
{
3
    var last_text_move_select = global.last_text_move_select
4
    var action_3_selected_count_2 = global.action_3_selected_count_2
5
    var heart_position = script_execute(gml_Script_scr_return_heart_battle_menu_position)
6
    if (text_deadlock_1 == true)
7
        instance_create((obj_dialogue_box_battle.x + 20), (obj_dialogue_box_battle.x + 20), text_deadlock_contents_1)
8
    else if (last_text_move_select == 0)
9
    {
10
        instance_create((obj_dialogue_box_battle.x + 20), (obj_dialogue_box_battle.x + 20), obj_dialogue_battle_move_select_intro)
11
        text_deadlock_contents_1 = 3004
12
        text_deadlock_1 = true
13
    }
14
    else if (global.battle_menu_number == 1 && global.enemy_dead == true && global.fight_number == 1)
15
    {
16
        instance_create((obj_dialogue_box_battle.x + 20), (obj_dialogue_box_battle.x + 20), obj_dialogue_battle_move_select_dead_2)
17
        text_deadlock_contents_1 = 3052
18
        text_deadlock_1 = true
19
    }
20
    else if (global.battle_menu_number == 1 && global.enemy_dead_2 == true && global.fight_number == 2)
21
    {
22
        instance_create((obj_dialogue_box_battle.x + 20), (obj_dialogue_box_battle.x + 20), obj_dialogue_battle_move_select_dead)
23
        text_deadlock_contents_1 = 3033
24
        text_deadlock_1 = true
25
    }
26
    else if (global.enemy_low_hp == true && global.enemy_dead == false && global.enemy_spared == false)
27
    {
28
        var random_number = irandom_range(1, 2)
29
        if (random_number == 1)
30
        {
31
            instance_create((obj_dialogue_box_battle.x + 20), (obj_dialogue_box_battle.x + 20), obj_dialogue_battle_move_select_low_hp_1)
32
            text_deadlock_contents_1 = 3016
33
        }
34
        else if (random_number == 2)
35
        {
36
            instance_create((obj_dialogue_box_battle.x + 20), (obj_dialogue_box_battle.x + 20), obj_dialogue_battle_move_select_low_hp_1_v2)
37
            text_deadlock_contents_1 = 3018
38
        }
39
        text_deadlock_1 = true
40
    }
41
    else if (global.enemy_low_hp_2 == true && global.enemy_dead_2 == false && global.enemy_spared_2 == false)
42
    {
43
        random_number = irandom_range(1, 2)
44
        if (random_number == 1)
45
        {
46
            instance_create((obj_dialogue_box_battle.x + 20), (obj_dialogue_box_battle.x + 20), obj_dialogue_battle_move_select_low_hp_2)
47
            text_deadlock_contents_1 = 3036
48
        }
49
        else if (random_number == 2)
50
        {
51
            instance_create((obj_dialogue_box_battle.x + 20), (obj_dialogue_box_battle.x + 20), obj_dialogue_battle_move_select_low_hp_2_v2)
52
            text_deadlock_contents_1 = 3037
53
        }
54
        text_deadlock_1 = true
55
    }
56
    else if (global.enemy_sparing == true && global.enemy_dead == false && global.enemy_spared == false)
57
    {
58
        instance_create((obj_dialogue_box_battle.x + 20), (obj_dialogue_box_battle.x + 20), obj_dialogue_battle_move_select_sparing)
59
        text_deadlock_contents_1 = 3030
60
        text_deadlock_1 = true
61
    }
62
    else if (global.enemy_sparing_2 == true && global.enemy_dead_2 == false && global.enemy_spared_2 == false)
63
    {
64
        random_number = irandom_range(1, 2)
65
        if (random_number == 1)
66
        {
67
            instance_create((obj_dialogue_box_battle.x + 20), (obj_dialogue_box_battle.x + 20), obj_dialogue_battle_move_select_sparing_2)
68
            text_deadlock_contents_1 = 3050
69
        }
70
        else if (random_number == 2)
71
        {
72
            instance_create((obj_dialogue_box_battle.x + 20), (obj_dialogue_box_battle.x + 20), obj_dialogue_battle_move_select_sparing_2_v2)
73
            text_deadlock_contents_1 = 3051
74
        }
75
        text_deadlock_1 = true
76
    }
77
    else if (action_3_selected_count_2 >= 1 && heart_position == "2222")
78
    {
79
        instance_create((obj_dialogue_box_battle.x + 20), (obj_dialogue_box_battle.x + 20), obj_dialogue_battle_move_select_action_3_v2)
80
        text_deadlock_contents_1 = 3034
81
        text_deadlock_1 = true
82
    }
83
    else
84
    {
85
        random_number = irandom_range(1, 2)
86
        if (global.enemy_dead == true || global.enemy_spared == true)
87
            random_number = 2
88
        else if (global.enemy_dead_2 == true || global.enemy_spared_2 == true)
89
            random_number = 1
90
        if (random_number == 1)
91
        {
92
            if ((global.enemy_dead_2 + global.enemy_spared_2) < 1)
93
                var random_text_move_select = irandom_range(1, 8)
94
            else
95
                random_text_move_select = irandom_range(1, 5)
96
        }
97
        else if (random_number == 2)
98
        {
99
            if ((global.enemy_dead + global.enemy_spared) < 1)
100
                random_text_move_select = irandom_range(1, 6)
101
            else
102
                random_text_move_select = irandom_range(1, 4)
103
        }
104
        if (random_number == 1)
105
        {
106
            if (random_text_move_select == 1)
107
            {
108
                instance_create((obj_dialogue_box_battle.x + 20), (obj_dialogue_box_battle.x + 20), obj_dialogue_battle_move_select_1)
109
                text_deadlock_contents_1 = 3020
110
                text_deadlock_1 = true
111
            }
112
            else if (random_text_move_select == 2)
113
            {
114
                instance_create((obj_dialogue_box_battle.x + 20), (obj_dialogue_box_battle.x + 20), obj_dialogue_battle_move_select_2)
115
                text_deadlock_contents_1 = 3021
116
                text_deadlock_1 = true
117
            }
118
            else if (random_text_move_select == 3)
119
            {
120
                instance_create((obj_dialogue_box_battle.x + 20), (obj_dialogue_box_battle.x + 20), obj_dialogue_battle_move_select_3)
121
                text_deadlock_contents_1 = 3022
122
                text_deadlock_1 = true
123
            }
124
            else if (random_text_move_select == 4)
125
            {
126
                instance_create((obj_dialogue_box_battle.x + 20), (obj_dialogue_box_battle.x + 20), obj_dialogue_battle_move_select_4)
127
                text_deadlock_contents_1 = 3023
128
                text_deadlock_1 = true
129
            }
130
            else if (random_text_move_select == 5)
131
            {
132
                instance_create((obj_dialogue_box_battle.x + 20), (obj_dialogue_box_battle.x + 20), obj_dialogue_battle_move_select_5)
133
                text_deadlock_contents_1 = 3024
134
                text_deadlock_1 = true
135
            }
136
            else if (random_text_move_select == 6)
137
            {
138
                instance_create((obj_dialogue_box_battle.x + 20), (obj_dialogue_box_battle.x + 20), obj_dialogue_battle_move_select_6)
139
                text_deadlock_contents_1 = 3025
140
                text_deadlock_1 = true
141
            }
142
            else if (random_text_move_select == 7)
143
            {
144
                instance_create((obj_dialogue_box_battle.x + 20), (obj_dialogue_box_battle.x + 20), obj_dialogue_battle_move_select_7)
145
                text_deadlock_contents_1 = 3026
146
                text_deadlock_1 = true
147
            }
148
            else if (random_text_move_select == 8)
149
            {
150
                instance_create((obj_dialogue_box_battle.x + 20), (obj_dialogue_box_battle.x + 20), obj_dialogue_battle_move_select_8)
151
                text_deadlock_contents_1 = 3028
152
                text_deadlock_1 = true
153
            }
154
        }
155
        else if (random_number == 2)
156
        {
157
            if (random_text_move_select == 1)
158
            {
159
                instance_create((obj_dialogue_box_battle.x + 20), (obj_dialogue_box_battle.x + 20), obj_dialogue_battle_move_select_1_v2)
160
                text_deadlock_contents_1 = 3039
161
                text_deadlock_1 = true
162
            }
163
            else if (random_text_move_select == 2)
164
            {
165
                instance_create((obj_dialogue_box_battle.x + 20), (obj_dialogue_box_battle.x + 20), obj_dialogue_battle_move_select_2_v2)
166
                text_deadlock_contents_1 = 3040
167
                text_deadlock_1 = true
168
            }
169
            else if (random_text_move_select == 3)
170
            {
171
                instance_create((obj_dialogue_box_battle.x + 20), (obj_dialogue_box_battle.x + 20), obj_dialogue_battle_move_select_3_v2)
172
                text_deadlock_contents_1 = 3041
173
                text_deadlock_1 = true
174
            }
175
            else if (random_text_move_select == 4)
176
            {
177
                instance_create((obj_dialogue_box_battle.x + 20), (obj_dialogue_box_battle.x + 20), obj_dialogue_battle_move_select_4_v2)
178
                text_deadlock_contents_1 = 3046
179
                text_deadlock_1 = true
180
            }
181
            else if (random_text_move_select == 5)
182
            {
183
                instance_create((obj_dialogue_box_battle.x + 20), (obj_dialogue_box_battle.x + 20), obj_dialogue_battle_move_select_5_v2)
184
                text_deadlock_contents_1 = 3047
185
                text_deadlock_1 = true
186
            }
187
            else if (random_text_move_select == 6)
188
            {
189
                instance_create((obj_dialogue_box_battle.x + 20), (obj_dialogue_box_battle.x + 20), obj_dialogue_battle_move_select_6_v2)
190
                text_deadlock_contents_1 = 3048
191
                text_deadlock_1 = true
192
            }
193
        }
194
    }
195
}