summaryrefslogtreecommitdiff
path: root/npc/annuals/xmas/debug.txt
blob: f7ba17bdb122bbceeee8cb880093f41125521610 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
function	script	XmasDebug	{
    if(debug)
        goto L_Debug;
    goto L_Live;

L_Live:
    mes "What do you want to do?";
    menu
        "Debug Vars", L_DebugLive,
        "Xmas Time Key Change.", L_XmasTimeKey,
        "Reset Xmas Chamber.", L_XmasChamberReset,
        "Do nothing.", L_close;

L_DebugLive:
    mes "--Sever--";
    mes "Event State: " + $@xmas_time;
    mes "Event Start" + $XMAS_TIME_KEY[0] + "/1";
    mes "Reward Start: " + $XMAS_TIME_KEY[1] + "/" + $XMAS_TIME_KEY[3];
    mes "Event End: " + $XMAS_TIME_KEY[2] + "/" + $XMAS_TIME_KEY[4];
    mes "Event Time Key (year (CCYY)): " + $XMAS_TIME_KEY[5];
    goto L_close;

L_Debug:
    mes "What do you want to do?";
    menu
        "Debug Vars", L_DebugVars,
        "Set Quest State.", L_XmasState,
        "Set Karma. [0-15] 15 Nice", L_XmasKarma,
        "Set All Lists", L_SetAllLists,
        "Set All Helpers", L_SetAllHelpers,
        "Set Boss Hero", L_SetBossHero,
        "Reset Quest State.", L_Reset,
        "Set Old Event Flag.", L_LastReset,
        "Xmas Time Key Change.", L_XmasTimeKey,
        "Reset Xmas Chamber.", L_XmasChamberReset,
        "Do nothing.", L_close;

L_DebugVars:
    callfunc "XmasStates";
    mes "--Sever--";
    mes "Event State: " + $@xmas_time;
    mes "Event Start" + $XMAS_TIME_KEY[0] + "/1";
    mes "Reward Start: " + $XMAS_TIME_KEY[1] + "/" + $XMAS_TIME_KEY[3];
    mes "Event End: " + $XMAS_TIME_KEY[2] + "/" + $XMAS_TIME_KEY[4];
    mes "Event Time Key (year (CCYY)): " + $XMAS_TIME_KEY[5];
    next;
    mes "--Player--";
    mes "Player Event Time Key " + XMASYEAR;
    mes "xmas_state: " + @xmas_state;
    mes "xmas_karma: " + @xmas_karma;
    mes "xmas_side: " + @xmas_side;
    next;
    mes "xmas_list_gather: " + @xmas_list_gather;
    mes "xmas_list_complete: " + @xmas_list_complete;
    mes "xmas_list_deliver: " + @xmas_list_deliver;
    mes "xmas_helper_start_state: " + @xmas_helper_start_state;
    mes "xmas_helper_done_state: " + @xmas_helper_done_state;
    mes "xmas_reagent_start_state: " + @xmas_reagent_start_state;
    mes "xmas_reagent_done_state: " + @xmas_reagent_done_state;
    mes "xmas_boss_door_state: " + @xmas_boss_door_state;
    mes "xmas_reward_start_state " + @xmas_reward_start_state;
    mes "xmas_reward1_done_state " + @xmas_reward1_done_state;
    mes "xmas_reward2_done_state " + @xmas_reward2_done_state;
    mes "xmas_reward_done_state: " + @xmas_reward_done_state;
    next;
    mes "xmas_basement_passage: " + @xmas_basement_passage;
    mes "xmas_thrown_out: " + @xmas_thrown_out;
    mes "xmas_hard_mode: " + @xmas_boss_hero;
    next;
    mes "xmas_sweater: " + @xmas_sh_done;
    next;
    mes "xmas_all_lists: " + @xmas_all_lists;
    next;
    mes "xmas_helper_bit: " + @xmas_helper_bit;
    mes "xmas_all_helpers: " + @xmas_all_helpers;
    mes "xmas_helper_acorn: " + @xmas_helper_acorn;
    mes "xmas_helper_bedding: " + @xmas_helper_bedding;
    mes "xmas_helper_glitter: " + @xmas_helper_glitter;
    mes "xmas_helper_storage: " + @xmas_helper_storage;
    mes "xmas_knows_route: " + @xmas_knows_route;
    goto L_close;

L_LastReset:
    XMASTIME = 255;
    XMASYEAR = 2012;
    goto L_close;

L_Reset:
    XMASTIME = 0;
    XMASYEAR = $XMAS_TIME_KEY[5];
    goto L_close;

L_XmasTimeKey:
    mes "Xmas Time Key Change.";
    mes "Start Month?";
    input @xmas_time_key_smonth;
    if((@xmas_time_key_smonth == 0) || (@xmas_time_key_smonth > 12))
        goto L_XmasError;
    mes "Reward Start Month?";
    input @xmas_time_key_srmonth;
    if((@xmas_time_key_srmonth == 0) || (@xmas_time_key_srmonth > 12))
        goto L_XmasError;
    mes "End Month?";
    input @xmas_time_key_emonth;
    if((@xmas_time_key_emonth == 0) || (@xmas_time_key_emonth > 12))
        goto L_XmasError;
    mes "Reward Start Day?";
    input @xmas_time_key_rsday;
    if((@xmas_time_key_rsday == 0) || (@xmas_time_key_rsday > 31))
        goto L_XmasError;
    mes "Reward End Day?";
    input @xmas_time_key_reday;
    if((@xmas_time_key_reday == 0) || (@xmas_time_key_reday > 31))
        goto L_XmasError;
    mes "Time Key (CCYY) ";
    input @xmas_time_key_year;
    goto L_SetNewKey;

L_XmasError:
    mes "Incorrect Entry. Try again.";
    goto L_close;

L_SetNewKey:
    setarray $XMAS_TIME_KEY, @xmas_time_key_smonth, @xmas_time_key_srmonth, @xmas_time_key_emonth, @xmas_time_key_rsday, @xmas_time_key_reday, @xmas_time_key_year;
    donpcevent "#XmasConfig::OnCommandRestartQuest";
    goto L_close;

L_XmasChamberReset:
    donpcevent "AniManOMat::OnCommandChamberReset";
    goto L_close;

L_XmasState:
    mes "Quest state?";
    input @xmas_state;
    callfunc "XmasSetState";
    goto L_close;

L_XmasKarma:
    mes "Karma (0-15) 0: Naughty, 15: Good";
    input @xmas_karma;
    XMASTIME = (XMASTIME & ~(NIBBLE_1_MASK) | (@xmas_karma << NIBBLE_1_SHIFT));
    goto L_close;

L_SetAllLists:
    XMASTIME = XMASTIME | $@xmas_all_lists_bit;
    goto L_close;

L_SetAllHelpers:
    XMASTIME = XMASTIME | $@xmas_all_helpers_bit;
    goto L_close;

L_SetBossHero:
    XMASTIME = XMASTIME | $@xmas_boss_hero_bit;
    goto L_close;

L_close:
    @xmas_state = 0;
    @xmas_karma = 0;
    @xmas_hard_mode = 0;
    @xmas_time_key_smonth = 0;
    @xmas_time_key_emonth = 0;
    @xmas_time_key_rsday = 0;
    @xmas_time_key_reday = 0;
    @xmas_time_key_year = 0;
    close2;
    return;
}

020-1,86,76,0	script	XmasDebug#1	NPC105,{
    callfunc "XmasDebug";
    goto L_End;

OnInit:
    if(!(debug))
        disablenpc "XmasDebug#1";
    goto L_End;

L_End:
    end;
}

030-2,193,62,0	script	XmasDebug#2	NPC105,{
    callfunc "XmasDebug";
    goto L_End;

OnInit:
    if(!(debug))
        disablenpc "XmasDebug#2";
    goto L_End;

L_End:
    end;
}

030-3,26,26,0	script	XmasDebug#3	NPC105,{
    callfunc "XmasDebug";
    goto L_End;

OnInit:
    if(!(debug))
        disablenpc "XmasDebug#3";
    goto L_End;

L_End:
    end;
}

030-4,30,30,0	script	XmasDebug#4	NPC111,{
    callfunc "XmasDebug";
    goto L_End;

OnInit:
    if(!(debug))
        disablenpc "XmasDebug#4";
    goto L_End;

L_End:
    end;
}