Undertale Yellow script viewer

← back to main script listing

gml_GlobalScript_scr_recreate_heart_battle_menu_text_decibat

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

function scr_recreate_heart_battle_menu_text_decibat() //gml_Script_scr_recreate_heart_battle_menu_text_decibat { var last_text_move_select = global.last_text_move_select var action_1_selected_count = global.action_1_selected_count var action_2_selected_count = global.action_2_selected_count var action_3_selected_count = global.action_3_selected_count show_debug_message("Enemy sparing is:" + string(global.enemy_sparing)) 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.enemy_sparing == true) { 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.action_1_selected_count + global.action_2_selected_count + global.action_3_selected_count) >= 1 && global.enemy_low_hp == false) { instance_create((obj_dialogue_box_battle.x + 20), (obj_dialogue_box_battle.x + 20), obj_dialogue_battle_move_select_special) text_deadlock_contents_1 = 3009 text_deadlock_1 = true } else { var random_text_move_select = irandom_range(1, 2) if (random_text_move_select == 1) { instance_create((obj_dialogue_box_battle.x + 20), (obj_dialogue_box_battle.x + 20), obj_dialogue_battle_move_select_1) text_deadlock_contents_1 = 3020 text_deadlock_1 = true } else if (random_text_move_select == 2) { instance_create((obj_dialogue_box_battle.x + 20), (obj_dialogue_box_battle.x + 20), obj_dialogue_battle_move_select_2) text_deadlock_contents_1 = 3021 text_deadlock_1 = true } } }
() //gml_Script_scr_recreate_heart_battle_menu_text_decibat
2
{
3
    var last_text_move_select = global.last_text_move_select
4
    var action_1_selected_count = global.action_1_selected_count
5
    var action_2_selected_count = global.action_2_selected_count
6
    var action_3_selected_count = global.action_3_selected_count
7
    show_debug_message("Enemy sparing is:" + string(global.enemy_sparing))
8
    if (text_deadlock_1 == true)
9
        instance_create((obj_dialogue_box_battle.x + 20), (obj_dialogue_box_battle.x + 20), text_deadlock_contents_1)
10
    else if (last_text_move_select == 0)
11
    {
12
        instance_create((obj_dialogue_box_battle.x + 20), (obj_dialogue_box_battle.x + 20), obj_dialogue_battle_move_select_intro)
13
        text_deadlock_contents_1 = 3004
14
        text_deadlock_1 = true
15
    }
16
    else if (global.enemy_sparing == true)
17
    {
18
        instance_create((obj_dialogue_box_battle.x + 20), (obj_dialogue_box_battle.x + 20), obj_dialogue_battle_move_select_sparing)
19
        text_deadlock_contents_1 = 3030
20
        text_deadlock_1 = true
21
    }
22
    else if ((global.action_1_selected_count + global.action_2_selected_count + global.action_3_selected_count) >= 1 && global.enemy_low_hp == false)
23
    {
24
        instance_create((obj_dialogue_box_battle.x + 20), (obj_dialogue_box_battle.x + 20), obj_dialogue_battle_move_select_special)
25
        text_deadlock_contents_1 = 3009
26
        text_deadlock_1 = true
27
    }
28
    else
29
    {
30
        var random_text_move_select = irandom_range(1, 2)
31
        if (random_text_move_select == 1)
32
        {
33
            instance_create((obj_dialogue_box_battle.x + 20), (obj_dialogue_box_battle.x + 20), obj_dialogue_battle_move_select_1)
34
            text_deadlock_contents_1 = 3020
35
            text_deadlock_1 = true
36
        }
37
        else if (random_text_move_select == 2)
38
        {
39
            instance_create((obj_dialogue_box_battle.x + 20), (obj_dialogue_box_battle.x + 20), obj_dialogue_battle_move_select_2)
40
            text_deadlock_contents_1 = 3021
41
            text_deadlock_1 = true
42
        }
43
    }
44
}