Undertale Yellow script viewer

← back to main script listing

gml_Object_obj_dialogue_exit_shop_Create_0

(view raw script w/o annotations or w/e)
1
var shop_name = global.shop_name;
2
depth = -room_height - 164;
3
var game_mode = global.game_mode;
4
shop_name = global.shop_name;
5
if (game_mode == "customs")
6
{
7
    if (shop_name == "Mart-2-Go")
8
    {
9
        message[0] = "* Alright, catch you on the flip#  side!#* Peace out!";
10
        portrait_author_head[0] = spr_author_head_normal_new_shop;
11
        portrait_author_torso[0] = spr_author_torso_normal_new_shop;
12
        point[0] = 1;
13
        talk_script[0] = scr_talking_author;
14
        for (i = 0; i < array_length_1d(message); i += 1)
15
            action[i] = "Nothing";
16
    }
17
}
18
else if (game_mode == "yellow")
19
{
20
    if (shop_name == "Mart-2-Go")
21
    {
22
        message[0] = "* Alright, catch you on the flip#  side!#* Peace out!";
23
        portrait_author_head[0] = spr_author_head_normal_new_shop;
24
        portrait_author_torso[0] = spr_author_torso_normal_new_shop;
25
        point[0] = 1;
26
        talk_script[0] = scr_talking_author;
27
        for (i = 0; i < array_length_1d(message); i += 1)
28
            action[i] = "Nothing";
29
    }
30
    else if (shop_name == "Honeydew Resort Normal")
31
    {
32
        message[0] = "* See ya! Thanks for being so#  kind!";
33
        portrait[0] = 1410;
34
        point[0] = 1;
35
        talk_script[0] = scr_talking_honeydew_bear;
36
        for (i = 0; i < array_length_1d(message); i += 1)
37
            action[i] = "Nothing";
38
    }
39
    else if (shop_name == "Wild East Gunshop")
40
    {
41
        message[0] = "* I wish you good travels!";
42
        portrait[0] = 1412;
43
        point[0] = 1;
44
        talk_script[0] = scr_talking_blackjack;
45
        for (i = 0; i < array_length_1d(message); i += 1)
46
            action[i] = "Nothing";
47
    }
48
    else if (shop_name == "Wild East Saloon")
49
    {
50
        message[0] = "* Have fun out there!";
51
        portrait[0] = 1423;
52
        point[0] = 1;
53
        talk_script[0] = scr_talking_blackjack;
54
        for (i = 0; i < array_length_1d(message); i += 1)
55
            action[i] = "Nothing";
56
    }
57
    else if (shop_name == "Steamworks Vendy")
58
    {
59
        if (global.sworks_flag[26] < 2)
60
        {
61
            message[0] = "* Yes, bye, thanks for nothing.";
62
            portrait[0] = 3325;
63
        }
64
        else
65
        {
66
            message[0] = "* Thank you for using the Vendy#  service!";
67
            portrait[0] = 131;
68
        }
69
        point[0] = 1;
70
        talk_script[0] = scr_talking_vendy;
71
        for (i = 0; i < array_length_1d(message); i += 1)
72
            action[i] = "Nothing";
73
    }
74
    else if (shop_name == "Hotel Shop")
75
    {
76
        message[0] = "* Thanks for your time!";
77
        portrait[0] = 3199;
78
        message_alt[0] = "* Thanks for your time!#* < Don't let the door hit ya on#  the way out! >";
79
        portrait_alt[0] = 1959;
80
        point[0] = 1;
81
        talk_script[0] = scr_talking_hotel_shopkeeper;
82
        for (i = 0; i < array_length_1d(message); i += 1)
83
            action[i] = "Nothing";
84
    }
85
}
86
message_current = 0;
87
message_end = 0;
88
message_draw = "";
89
increase = global.text_speed;
90
characters = 0;
91
hold = 0;
92
message_length = string_length(message[message_current]);
93
message_draw_alt = "";
94
if (shop_name == "Hotel Shop")
95
{
96
    var message_alt_length = string_length(message_alt[message_current]);
97
    if (message_alt_length > message_length)
98
        message_length = message_alt_length;
99
}
100
script_execute(scr_generate_text_counters);