-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathvpw2_z.s
264 lines (209 loc) · 6.75 KB
/
vpw2_z.s
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
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
# Virtual Pro-Wrestling 2 disassembly and split file
# generated by n64split v0.4a - N64 ROM splitter
# assembler directives
.set noat # allow manual use of $at
.set noreorder # don't insert nops after branches
.set gp=64
.include "globals.inc"
.include "macros.inc"
.include "include/filetableid.inc"
#==============================================================================#
.section .header, "a"
.include "asm/header.s"
#------------------------------------------------------------------------------#
.section .boot, "ax"
boot:
.incbin "bin/boot.bin"
boot_end:
#==============================================================================#
.include "asm/main.s"
#==============================================================================#
asm_000:
.include "asm/seg000_code.s"
asm_000_end:
#==============================================================================#
asm_001:
.include "asm/seg001_code.s"
asm_001_end:
#==============================================================================#
asm_002:
.include "asm/seg002_code.s"
asm_002_end:
#------------------------------------------------------------------------------#
# aki_malloc uses 0x216600 bytes of space starting at RAM address 80179200.
# Memory-wise, this appears after seg002, but is not necessarily a part of it,
# since aki_malloc and aki_free are in the main/global segment.
.section .bss_malloc
# seg002 BSS ends at 80179140, so get us to 80179200.
# (this space is unused and persists between resets,
# if you want to use it for hacking purposes...)
.align 8
malloc_80179200: .word 0
malloc_80179204: .word 0
malloc_80179208: .word 0
malloc_8017920C: .word 0
.skip 0x2165F0
#------------------------------------------------------------------------------#
# Memory for two framebuffers is defined at 8038F800 and 803C7C00.
# Each of these blocks takes up 0xE0FF words, according to the code.
# (That's 0x383FC bytes; it's bumped up to match the nearest boundary.)
# These two blocks fill up the rest of the RDRAM address map up to 80400000.
# It probably doesn't belong in the malloc section, but laziness prevails.
# Internal framebuffer size is 480x240 pixels.
framebuffer_8038F800: .skip 0x38400
framebuffer_803C7C00: .skip 0x38400
#==============================================================================#
asm_003:
.include "asm/seg003_code.s"
asm_003_end:
#==============================================================================#
# filetable stuff
.section .filetable, "ax"
# file table contents/data
filedata:
.incbin "bin/filedata.bin"
filedata_end:
.section .fileindex, "ax"
# file table index
filetable:
.incbin "bin/filetable.idx"
filetable_end:
#==============================================================================#
# data with currently unknown purpose...
# Z64 ROM address 0x131DBD0
.section .somejunk, "ax"
somejunk:
.incbin "bin/somejunk.bin"
somejunk_end:
#==============================================================================#
# soundtable stuff
# bank 00 - musical instruments
.section .soundtbl1_ptr, "ax"
# Z64 ROM address 0x133AC80
sndtbl1_ptr:
.incbin "bin/soundtable/sndtbl1_ptr.bin"
sndtbl1_ptr_end:
.section .soundtbl1_wbk, "ax"
# Z64 ROM address 0x133CE10
sndtbl1_wbk:
.incbin "bin/soundtable/sndtbl1_wbk.bin"
sndtbl1_wbk_end:
.section .soundtbl1_tbl, "ax"
# Z64 ROM address 0x144E0A0
sndtbl1_tbl:
.incbin "bin/soundtable/sndtbl1_tbl.bin"
sndtbl1_tbl_end:
#------------------------------------------------------------------------------#
# bank 01 - in-match sounds, announcer voices
.section .soundtbl2_ptr, "ax"
# Z64 ROM address 0x144FD30
sndtbl2_ptr:
.incbin "bin/soundtable/sndtbl2_ptr.bin"
sndtbl2_ptr_end:
.section .soundtbl2_wbk, "ax"
# Z64 ROM address 0x1454C20
sndtbl2_wbk:
.incbin "bin/soundtable/sndtbl2_wbk.bin"
sndtbl2_wbk_end:
.section .soundtbl2_tbl, "ax"
# Z64 ROM address 0x156E7D0
sndtbl2_tbl:
.incbin "bin/soundtable/sndtbl2_tbl.bin"
sndtbl2_tbl_end:
#------------------------------------------------------------------------------#
# bank 02 - streamed wrestler themes
.section .soundtbl3_ptr, "ax"
# Z64 ROM address 0x156EA30
sndtbl3_ptr:
.incbin "bin/soundtable/sndtbl3_ptr.bin"
sndtbl3_ptr_end:
.section .soundtbl3_wbk, "ax"
# Z64 ROM address 0x156F2E0
sndtbl3_wbk:
.incbin "bin/soundtable/sndtbl3_wbk.bin"
sndtbl3_wbk_end:
.section .soundtbl3_tbl, "ax"
# Z64 ROM address 0x1C97400
sndtbl3_tbl:
.incbin "bin/soundtable/sndtbl3_tbl.bin"
sndtbl3_tbl_end:
#------------------------------------------------------------------------------#
# bank 03 - ring announcer bank 1
.section .soundtbl4_ptr, "ax"
# Z64 ROM address 0x1C98A10
sndtbl4_ptr:
.incbin "bin/soundtable/sndtbl4_ptr.bin"
sndtbl4_ptr_end:
.section .soundtbl4_wbk, "ax"
# Z64 ROM address 0x1C9C700
sndtbl4_wbk:
.incbin "bin/soundtable/sndtbl4_wbk.bin"
sndtbl4_wbk_end:
.section .soundtbl4_tbl, "ax"
# Z64 ROM address 0x1D0AC40
sndtbl4_tbl:
.incbin "bin/soundtable/sndtbl4_tbl.bin"
sndtbl4_tbl_end:
#------------------------------------------------------------------------------#
# bank 04 - ring announcer bank 2 (introductions)
.section .soundtbl5_ptr, "ax"
# Z64 ROM address 0x1D0C170
sndtbl5_ptr:
.incbin "bin/soundtable/sndtbl5_ptr.bin"
sndtbl5_ptr_end:
.section .soundtbl5_wbk, "ax"
# Z64 ROM address 0x1D0FB10
sndtbl5_wbk:
.incbin "bin/soundtable/sndtbl5_wbk.bin"
sndtbl5_wbk_end:
.section .soundtbl5_tbl, "ax"
# Z64 ROM address 0x1E47EF0
sndtbl5_tbl:
.incbin "bin/soundtable/sndtbl5_tbl.bin"
sndtbl5_tbl_end:
#------------------------------------------------------------------------------#
# bank 05 - ring announcer bank 3 (in-match announcements)
.section .soundtbl6_ptr, "ax"
# Z64 ROM address 0x1E487B0
sndtbl6_ptr:
.incbin "bin/soundtable/sndtbl6_ptr.bin"
sndtbl6_ptr_end:
.section .soundtbl6_wbk, "ax"
# Z64 ROM address 0x1E49FB0
sndtbl6_wbk:
.incbin "bin/soundtable/sndtbl6_wbk.bin"
sndtbl6_wbk_end:
.section .soundtbl6_tbl, "ax"
# Z64 ROM address 0x1E90030
sndtbl6_tbl:
.incbin "bin/soundtable/sndtbl6_tbl.bin"
sndtbl6_tbl_end:
#------------------------------------------------------------------------------#
# bank 06 - wrestler sounds bank 1
.section .soundtbl7_ptr, "ax"
# Z64 ROM address 0x1E90700
sndtbl7_ptr:
.incbin "bin/soundtable/sndtbl7_ptr.bin"
sndtbl7_ptr_end:
.section .soundtbl7_wbk, "ax"
# Z64 ROM address 0x1E930D0
sndtbl7_wbk:
.incbin "bin/soundtable/sndtbl7_wbk.bin"
sndtbl7_wbk_end:
.section .soundtbl7_tbl, "ax"
# Z64 ROM address 0x1EDC410
sndtbl7_tbl:
.incbin "bin/soundtable/sndtbl7_tbl.bin"
sndtbl7_tbl_end:
#------------------------------------------------------------------------------#
# bank 06 - wrestler sounds bank 2
.section .soundtbl8_ptr, "ax"
# Z64 ROM address 0x1EDCAE0
sndtbl8_ptr:
.incbin "bin/soundtable/sndtbl8_ptr.bin"
sndtbl8_ptr_end:
.section .soundtbl8_wbk, "ax"
# Z64 ROM address 0x1EDF4B0
sndtbl8_wbk:
.incbin "bin/soundtable/sndtbl8_wbk.bin"
sndtbl8_wbk_end: