-
Notifications
You must be signed in to change notification settings - Fork 3
/
palace17.tsct
188 lines (172 loc) · 5.01 KB
/
palace17.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
/*
* 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 { -5997, 1625, -3637 }
VAR_6 { 79, 1, -1 }
init_position1 { -5733, 1625, -3393 }
init_position2 { -5895, 1625, -3187 }
init_position3 { -6251, 1624, -3359 }
init_position4 { -6080, 1625, -3183 }
VAR_15 { -5318, 1648, -3231, -6462, 1625, -1797 }
ai_script { 3, VAR_17, 0, 5, 50, 3, VAR_18, 0, 5, 20, 3, VAR_19, 0, 5, 25, 3, VAR_20, 0, 5, 10, 7, 8 }
VAR_17 "no"
VAR_18 "laugh"
VAR_19 "gstqustn"
VAR_20 "no"
ai_script1 { 5, 30, 3, VAR_22, 0, 5, 70, 3, VAR_23, 0, 5, 10, 3, VAR_24, 0, 5, 35, 3, VAR_25, 0, 7, 8 }
VAR_22 "no"
VAR_23 "laugh"
VAR_24 "gstqustn"
VAR_25 "no"
ai_script2 { 3, VAR_27, 0, 5, 50, 3, VAR_28, 0, 5, 30, 3, VAR_29, 0, 5, 20, 7, 8 }
VAR_27 "laugh"
VAR_28 "no"
VAR_29 "gstqustn"
ai_script3 { 3, VAR_31, 0, 5, 10, 3, VAR_32, 0, 5, 25, 3, VAR_33, 0, 5, 20, 7, 8 }
VAR_31 "laugh"
VAR_32 "gstqustn"
VAR_33 { 1735745900, -1431699352 }
._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_38)
{
var VAR_38 = 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_37)
{
var VAR_37 = 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 1)
{
if(call ! func_8a(var &VAR_15)&&call ! func_d0())
{
exit_script
}
var VAR_0 = int 2
exit_script
}
._SCRIPT_5
gamevar global_inventory_p = var &VAR_6
var btreasure1 = call create_char(var &init_position, "btreasure1", int 10, int 14)
call add_item_to_char(var btreasure1, int 85 /* moneybag */ , int 6554113, int 0)
call add_item_to_char(var btreasure1, int 20 /* hammer */ , int 1, int 0)
var bstump = call create_enemy(int 63, int 0, var &init_position1, int 255)
var bstump1 = call create_enemy(int 63, int 1, var &init_position2, int 215)
var bstump2 = call create_enemy(int 63, int 2, var &init_position3, int 115)
var bstump3 = call create_enemy(int 63, int 3, var &init_position4, int 175)
gamevar script_object = var bstump
gamevar *character_stats_p+16 = int 500
gamevar *character_stats_p+15 = int 3000
gamevar script_object = var bstump1
gamevar *character_stats_p+16 = int 500
gamevar *character_stats_p+15 = int 3000
gamevar script_object = var bstump2
gamevar *character_stats_p+16 = int 500
gamevar *character_stats_p+15 = int 3000
gamevar script_object = var bstump3
gamevar *character_stats_p+16 = int 500
gamevar *character_stats_p+15 = int 3000
call add_item_to_char(var bstump, int 45 /* deadmous */ , int 1, int 0)
call add_item_to_char(var bstump2, int 40 /* apple */ , int 1, int 0)
call func_106(var bstump, int 1, int 0, int 1)
call func_106(var bstump1, int 1, int 0, int 1)
call func_106(var bstump2, int 1, int 0, int 1)
call func_106(var bstump3, int 1, int 0, int 1)
call func_50(var bstump, int 8194)
call func_50(var bstump1, int 8194)
call func_50(var bstump2, int 8194)
call func_50(var bstump3, int 8194)
call play_char_ai_script(var bstump, var &ai_script)
call play_char_ai_script(var bstump1, var &ai_script1)
call play_char_ai_script(var bstump2, var &ai_script2)
call play_char_ai_script(var bstump3, var &ai_script3)
var VAR_1 = int 0
var VAR_0 = int 1
._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