-
Notifications
You must be signed in to change notification settings - Fork 3
/
palace18.tsct
224 lines (208 loc) · 4.95 KB
/
palace18.tsct
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
221
222
223
224
/*
* This file was auto-generated using 'silver-reversing-sct' tool
* to better understand the scripts presented, one is encouraged to
* view the catalogs at:
* https://github.com/nadavshemesh/silver-reversing-sct/blob/master/docs/index.md
*
* Any further information and support of this project please visit:
* https://github.com/nadavshemesh/silver-reversing-sct
*/
._DATA
init_position { -2149, 1625, 1233 }
._on_load
call load_sound_set(int 66)
/* play the sound 'dog1' */
call play_loaded_sound(int 7, int -1, int 66, int 0)
/* play the sound 'cwind1' */
call play_loaded_sound(int 1, int -1, int 66, int 0)
var david = call get_david_char()
var VAR_3 = call get_next_char_from_list()
var VAR_4 = call get_next_char_from_list()
call play_bgm("WPALPT1")
if(gamevar room_state == int 1)
{
execute SCRIPT_5
}
if(gamevar room_state == int 2)
{
execute SCRIPT_7
}
if(gamevar room_state == int 3)
{
execute SCRIPT_9
}
._infinite_loop
execute SCRIPT_3
if(gamevar room_state == int 1)
{
execute SCRIPT_4
}
if(gamevar room_state == int 2)
{
execute SCRIPT_6
}
if(gamevar room_state == int 3)
{
execute SCRIPT_8
}
._on_exit
if(gamevar room_state == int 2)
{
gamevar room_state ++
}
if(gamevar room_state == int 1)
{
gamevar room_state ++
}
._SCRIPT_3
if(gamevar script_time > var VAR_14)
{
var VAR_14 = gamevar script_time + int 100 + call randomize_int(int 0, int 50)
/* play the sound 'wwindlp' */
call play_loaded_sound(int 6, int 0, int 66, int 0)
}
if(gamevar script_time > var VAR_13)
{
var VAR_13 = gamevar script_time + int 80 + call randomize_int(int 0, int 40)
/* play the sound 'inwindlp' */
call play_loaded_sound(int 2, int 0, int 66, int 0)
}
._SCRIPT_4
if(var VAR_1)
{
if(call ! is_local_timer_greater_than(var VAR_1))
{
exit_script
}
var VAR_1 = int 0
}
if(var VAR_0 == int 0)
{
call func_113(int 0, int 100)
call reset_local_timer()
var VAR_1 = int 10
var VAR_0 = int 1
exit_script
}
if(var VAR_0 == int 1)
{
if(call ! func_8b())
{
exit_script
}
call char_turn_to_pos(var vikingc2, call get_char_pos(call get_david_char()))
var VAR_1 = int 7
var VAR_0 = int 2
call reset_local_timer()
exit_script
}
if(var VAR_0 == int 2)
{
call play_char_anim(var vikingc2, var come_anim, int 0)
var VAR_0 = int 3
var VAR_1 = int 8
call reset_local_timer()
exit_script
}
if(var VAR_0 == int 3)
{
var vikingc = call create_enemy_through_door(int 66, int 0, int 1, int 0)
call func_1(var vikingc, int -1)
call char_walk_to(var vikingc, int -1708, int 1625, int 1709)
call set_char_running(var vikingc)
var VAR_1 = int 10
call reset_local_timer()
var VAR_0 = int 4
exit_script
}
if(var VAR_0 == int 4)
{
if(call ! is_char_standing(var vikingc))
{
exit_script
}
var VAR_1 = int 3
call reset_local_timer()
var VAR_0 = int 5
exit_script
}
if(var VAR_0 == int 5)
{
var VAR_1 = int 5
call reset_local_timer()
call char_turn_to_pos(var vikingc2, call get_char_pos(call get_david_char()))
call char_turn_to_pos(var vikingc, call get_char_pos(call get_david_char()))
var VAR_0 = int 6
}
if(var VAR_0 == int 6)
{
call func_2(var vikingc1)
call func_2(var vikingc2)
call func_2(var vikingc)
call func_106(var vikingc1, int 1, int 0, int 1)
call func_106(var vikingc2, int 1, int 0, int 1)
call func_106(var vikingc, int 1, int 0, int 1)
call set_char_init_state(var vikingc1, int 1)
call set_char_init_state(var vikingc2, int 1)
call set_char_init_state(var vikingc, int 1)
gamevar script_object = var vikingc1
gamevar *character_stats_p+16 = int 500
gamevar *character_stats_p+15 = int 3000
gamevar script_object = var vikingc2
gamevar *character_stats_p+16 = int 500
gamevar *character_stats_p+15 = int 3000
call char_attack(var vikingc1, var david)
if(var VAR_3)
{
call char_attack(var vikingc2, var VAR_3)
}
else
{
call char_attack(var vikingc2, var david)
}
if(var VAR_4)
{
call char_attack(var vikingc, var VAR_4)
}
else
{
call char_attack(var vikingc, var david)
}
var VAR_0 = int 7
call set_input_system(int 1)
exit_script
}
._SCRIPT_5
var vikingc1 = call create_enemy(int 66, int 0, var &init_position, int 45)
var vikingc2 = call create_enemy(int 66, int 0, "\÷ÿÿY", int 100)
call func_1(var vikingc1, int -1)
call func_1(var vikingc2, int -1)
var come_anim = call load_anim("come")
call set_input_system(int 2)
call reset_local_timer()
var VAR_1 = int 5
var VAR_0 = int 0
._SCRIPT_6
if(var VAR_1)
{
if(call ! is_local_timer_greater_than(var VAR_1))
{
exit_script
}
var VAR_1 = int 0
}
._SCRIPT_7
var VAR_1 = int 0
var VAR_0 = int 1
._SCRIPT_8
if(var VAR_1)
{
if(call ! is_local_timer_greater_than(var VAR_1))
{
exit_script
}
var VAR_1 = int 0
}
._SCRIPT_9
var VAR_1 = int 0
var VAR_0 = int 1