Refresh 10

This commit is contained in:
n64
2020-06-02 12:44:34 -04:00
parent e58669b4b3
commit d43d9b7f20
444 changed files with 30163 additions and 7628 deletions

55
CHANGES
View File

@@ -1,3 +1,58 @@
Refresh #10
1.) GCC 9 noreturn UB fixes (#961)
2.) List supported binutils variants in README.md (#960)
3.) fix fly guy's possible values for target roll
4.) clarify that 1 is an exclusive bound in random_float (#962)
5.) replace unkB8 with prevNumStarsForDialog (#963)
6.) Replace "BulletBillUnkF8" with "BulletBillInitialMoveYaw" (#966)
7.) Renamed more warp behaviors and spawn types (#949)
8.) EU bss cleanups (#965)
9.) Add -fno-zero-initialized-in-bss to GCC CFLAGS (#968)
10.) Use empty .SECONDARY target instead of .PRECIOUS (#964)
11.) Match EU seq_channel_layer_process_script (#969)
12.) Fix version variable overwriting bug for non-matching compilations (#974)
13.) small bhv_collect_star_init labeling (#972)
14.) Align SI DMA command buffers, add more names to osCont code (#973)
15.) Minor for loop fix in playback.c (#976)
16.) Add Docker config (Public #36)
17.) Fix usage output crash for skyconv (#977)
18.) Cleanup tools and their build flags (#978)
19.) Print more detailed file reading error messages in extract_assets (#982)
20.) Remove asmdiff (#983)
21.) Fixed tabledesign makefile bug (#985)
22.) Improve first-diff.py (#987)
23.) Bring in some enhancements such as widescreen enhancements (#981)
24.) Fix background shadow border if widescreen in shade_screen (#988)
25.) Merge common EU sections in osExceptionPreamble (#990)
26.) Introduce the NO_SEGMENTED_MEMORY define (#989)
27.) NO_SEGMENTED_MEMORY comments (#992)
28.) Introduce f3dex2e and a GBI_FLOATS setting (#993)
29.) Audio uses signed 16-bit integers as samples, not unsigned (#995)
30.) Assemble RSP ucode with armips (#970)
31.) Label Mr. Blizzard, Yoshi, Whomp, Wiggler, Wood Piece oFields. (#996)
32.) update crash enhancement (#1003)
33.) Update README.md to use new public Discord server invite
34.) Label variables in act_idle. (#1005)
35.) Fix a typo in camera.h (#1009)
36.) Fixed up profiler.c (#1010)
37.) Add -d to first-diff.py (#1012)
38.) Fix typo in first-diff.py (#1013)
39.) Remove binutils 2.27 dependency check (#1015)
40.) Update armips to v0.11.0 tag and add generator script (#1004)
41.) Extract IPL3 font from ROM (#1011)
42.) Documented audio playback flags (#1021)
43.) Change RSP register notation to dollar-prefixed numbers (#1022)
44.) Only check for QEMU_IRIX in Makefile when compiling with IDO (#1023)
45.) Clean up header files and update function prototypes (#1000)
46.) Named local variables in geo_update_layer_transparency (#1019)
47.) Extract crash screen font textures from EU and SH ROMs (#1025)
48.) Use ACTIVE_FLAG defines where appropriate (#1026)
49.) Changed type of actor collision from s16 to Collision (#1024)
50.) Implement sqrtf in assembly file (#1028)
51.) Rename Struct8032FCE8 as OpenableGrill and identify data members (#1029)
52.) Fix some mistakes in the abi doc (#1031)
53.) The README.md PR (#979)
Refresh #8 Refresh #8
1.) Use INT_STATUS_ macros for oInteractStatus (#911) 1.) Use INT_STATUS_ macros for oInteractStatus (#911)
2.) Update bullet_bill.inc.c (#912) 2.) Update bullet_bill.inc.c (#912)

View File

@@ -6,10 +6,8 @@ RUN apt-get update && \
bsdmainutils \ bsdmainutils \
build-essential \ build-essential \
libaudiofile-dev \ libaudiofile-dev \
pkg-config \
python3 \ python3 \
wget \ wget
zlib1g-dev
RUN wget \ RUN wget \
https://github.com/n64decomp/qemu-irix/releases/download/v2.11-deb/qemu-irix-2.11.0-2169-g32ab296eef_amd64.deb \ https://github.com/n64decomp/qemu-irix/releases/download/v2.11-deb/qemu-irix-2.11.0-2169-g32ab296eef_amd64.deb \

135
Makefile
View File

@@ -29,33 +29,21 @@ endif
# Release # Release
ifeq ($(VERSION),jp) ifeq ($(VERSION),jp)
VERSION_CFLAGS := -DVERSION_JP VERSION_DEF := VERSION_JP
VERSION_ASFLAGS := --defsym VERSION_JP=1 GRUCODE_DEF := F3D_OLD
GRUCODE_CFLAGS := -DF3D_OLD
GRUCODE_ASFLAGS := --defsym F3D_OLD=1
TARGET := sm64.jp
else else
ifeq ($(VERSION),us) ifeq ($(VERSION),us)
VERSION_CFLAGS := -DVERSION_US VERSION_DEF := VERSION_US
VERSION_ASFLAGS := --defsym VERSION_US=1 GRUCODE_DEF := F3D_OLD
GRUCODE_CFLAGS := -DF3D_OLD
GRUCODE_ASFLAGS := --defsym F3D_OLD=1
TARGET := sm64.us
else else
ifeq ($(VERSION),eu) ifeq ($(VERSION),eu)
VERSION_CFLAGS := -DVERSION_EU VERSION_DEF := VERSION_EU
VERSION_ASFLAGS := --defsym VERSION_EU=1 GRUCODE_DEF := F3D_NEW
GRUCODE_CFLAGS := -DF3D_NEW
GRUCODE_ASFLAGS := --defsym F3D_NEW=1
TARGET := sm64.eu
else else
ifeq ($(VERSION),sh) ifeq ($(VERSION),sh)
$(warning Building SH is experimental and is prone to breaking. Try at your own risk.) $(warning Building SH is experimental and is prone to breaking. Try at your own risk.)
VERSION_CFLAGS := -DVERSION_SH VERSION_DEF := VERSION_SH
VERSION_ASFLAGS := --defsym VERSION_SH=1 GRUCODE_DEF := F3D_NEW
GRUCODE_CFLAGS := -DF3D_NEW
GRUCODE_ASFLAGS := --defsym F3D_NEW=1
TARGET := sm64.sh
# TODO: GET RID OF THIS!!! We should mandate assets for Shindou like EU but we dont have the addresses extracted yet so we'll just pretend you have everything extracted for now. # TODO: GET RID OF THIS!!! We should mandate assets for Shindou like EU but we dont have the addresses extracted yet so we'll just pretend you have everything extracted for now.
NOEXTRACT := 1 NOEXTRACT := 1
else else
@@ -65,30 +53,33 @@ endif
endif endif
endif endif
TARGET := sm64.$(VERSION)
VERSION_CFLAGS := -D$(VERSION_DEF)
VERSION_ASFLAGS := --defsym $(VERSION_DEF)=1
# Microcode # Microcode
ifeq ($(GRUCODE),f3dex) # Fast3DEX ifeq ($(GRUCODE),f3dex) # Fast3DEX
GRUCODE_CFLAGS := -DF3DEX_GBI GRUCODE_DEF := F3DEX_GBI
GRUCODE_ASFLAGS := --defsym F3DEX_GBI_SHARED=1 --defsym F3DEX_GBI=1 GRUCODE_ASFLAGS := --defsym F3DEX_GBI_SHARED=1
TARGET := $(TARGET).f3dex TARGET := $(TARGET).f3dex
COMPARE := 0 COMPARE := 0
else else
ifeq ($(GRUCODE), f3dex2) # Fast3DEX2 ifeq ($(GRUCODE), f3dex2) # Fast3DEX2
GRUCODE_CFLAGS := -DF3DEX_GBI_2 GRUCODE_DEF := F3DEX_GBI_2
GRUCODE_ASFLAGS := --defsym F3DEX_GBI_SHARED=1 --defsym F3DEX_GBI_2=1 GRUCODE_ASFLAGS := --defsym F3DEX_GBI_SHARED=1
TARGET := $(TARGET).f3dex2 TARGET := $(TARGET).f3dex2
COMPARE := 0 COMPARE := 0
else else
ifeq ($(GRUCODE),f3d_new) # Fast3D 2.0H (Shindou) ifeq ($(GRUCODE),f3d_new) # Fast3D 2.0H (Shindou)
GRUCODE_CFLAGS := -DF3D_NEW GRUCODE_DEF := F3D_NEW
GRUCODE_ASFLAGS := --defsym F3D_NEW=1
TARGET := $(TARGET).f3d_new TARGET := $(TARGET).f3d_new
COMPARE := 0 COMPARE := 0
else else
ifeq ($(GRUCODE),f3dzex) # Fast3DZEX (2.0J / Animal Forest - Dōbutsu no Mori) ifeq ($(GRUCODE),f3dzex) # Fast3DZEX (2.0J / Animal Forest - Dōbutsu no Mori)
$(warning Fast3DZEX is experimental. Try at your own risk.) $(warning Fast3DZEX is experimental. Try at your own risk.)
GRUCODE_CFLAGS := -DF3DEX_GBI_2 GRUCODE_DEF := F3DEX_GBI_2
GRUCODE_ASFLAGS := --defsym F3DEX_GBI_SHARED=1 --defsym F3DZEX_GBI=1 GRUCODE_ASFLAGS := --defsym F3DEX_GBI_SHARED=1
TARGET := $(TARGET).f3dzex TARGET := $(TARGET).f3dzex
COMPARE := 0 COMPARE := 0
endif endif
@@ -96,13 +87,16 @@ endif
endif endif
endif endif
GRUCODE_CFLAGS := -D$(GRUCODE_DEF)
GRUCODE_ASFLAGS := $(GRUCODE_ASFLAGS) --defsym $(GRUCODE_DEF)=1
ifeq ($(TARGET_N64),0) ifeq ($(TARGET_N64),0)
NON_MATCHING := 1 NON_MATCHING := 1
endif endif
ifeq ($(NON_MATCHING),1) ifeq ($(NON_MATCHING),1)
VERSION_CFLAGS := $(VERSION_CFLAGS) -DNON_MATCHING -DAVOID_UB MATCH_CFLAGS := -DNON_MATCHING -DAVOID_UB
VERSION_ASFLAGS := --defsym AVOID_UB=1 MATCH_ASFLAGS := --defsym AVOID_UB=1
COMPARE := 0 COMPARE := 0
endif endif
@@ -212,10 +206,7 @@ SOUND_SAMPLE_DIRS := $(wildcard sound/samples/*)
SOUND_SAMPLE_AIFFS := $(foreach dir,$(SOUND_SAMPLE_DIRS),$(wildcard $(dir)/*.aiff)) SOUND_SAMPLE_AIFFS := $(foreach dir,$(SOUND_SAMPLE_DIRS),$(wildcard $(dir)/*.aiff))
SOUND_SAMPLE_TABLES := $(foreach file,$(SOUND_SAMPLE_AIFFS),$(BUILD_DIR)/$(file:.aiff=.table)) SOUND_SAMPLE_TABLES := $(foreach file,$(SOUND_SAMPLE_AIFFS),$(BUILD_DIR)/$(file:.aiff=.table))
SOUND_SAMPLE_AIFCS := $(foreach file,$(SOUND_SAMPLE_AIFFS),$(BUILD_DIR)/$(file:.aiff=.aifc)) SOUND_SAMPLE_AIFCS := $(foreach file,$(SOUND_SAMPLE_AIFFS),$(BUILD_DIR)/$(file:.aiff=.aifc))
SOUND_OBJ_FILES := $(SOUND_BIN_DIR)/sound_data.ctl.o \ SOUND_OBJ_FILES := $(SOUND_BIN_DIR)/sound_data.o
$(SOUND_BIN_DIR)/sound_data.tbl.o \
$(SOUND_BIN_DIR)/sequences.bin.o \
$(SOUND_BIN_DIR)/bank_sets.o
# Object files # Object files
@@ -232,9 +223,11 @@ GODDARD_O_FILES := $(foreach file,$(GODDARD_C_FILES),$(BUILD_DIR)/$(file:.c=.o))
DEP_FILES := $(O_FILES:.o=.d) $(ULTRA_O_FILES:.o=.d) $(GODDARD_O_FILES:.o=.d) $(BUILD_DIR)/$(LD_SCRIPT).d DEP_FILES := $(O_FILES:.o=.d) $(ULTRA_O_FILES:.o=.d) $(GODDARD_O_FILES:.o=.d) $(BUILD_DIR)/$(LD_SCRIPT).d
# Files with GLOBAL_ASM blocks # Files with GLOBAL_ASM blocks
ifeq ($(NON_MATCHING),0)
GLOBAL_ASM_C_FILES != grep -rl 'GLOBAL_ASM(' $(wildcard src/**/*.c) GLOBAL_ASM_C_FILES != grep -rl 'GLOBAL_ASM(' $(wildcard src/**/*.c)
GLOBAL_ASM_O_FILES = $(foreach file,$(GLOBAL_ASM_C_FILES),$(BUILD_DIR)/$(file:.c=.o)) GLOBAL_ASM_O_FILES = $(foreach file,$(GLOBAL_ASM_C_FILES),$(BUILD_DIR)/$(file:.c=.o))
GLOBAL_ASM_DEP = $(BUILD_DIR)/src/audio/non_matching_dep GLOBAL_ASM_DEP = $(BUILD_DIR)/src/audio/non_matching_dep
endif
# Segment elf files # Segment elf files
SEG_FILES := $(SEGMENT_ELF_FILES) $(ACTOR_ELF_FILES) $(LEVEL_ELF_FILES) SEG_FILES := $(SEGMENT_ELF_FILES) $(ACTOR_ELF_FILES) $(LEVEL_ELF_FILES)
@@ -251,10 +244,12 @@ else
endif endif
# check that either QEMU_IRIX is set or qemu-irix package installed # check that either QEMU_IRIX is set or qemu-irix package installed
ifndef QEMU_IRIX ifeq ($(COMPILER),ido)
QEMU_IRIX := $(shell which qemu-irix) ifndef QEMU_IRIX
ifeq (, $(QEMU_IRIX)) QEMU_IRIX := $(shell which qemu-irix 2>/dev/null)
$(error Please install qemu-irix package or set QEMU_IRIX env var to the full qemu-irix binary path) ifeq (, $(QEMU_IRIX))
$(error Please install qemu-irix package or set QEMU_IRIX env var to the full qemu-irix binary path)
endif
endif endif
endif endif
@@ -273,18 +268,19 @@ ifeq ($(COMPILER),gcc)
endif endif
ifeq ($(TARGET_N64),1) ifeq ($(TARGET_N64),1)
TARGET_CFLAGS := -nostdinc -I include/libc -DTARGET_N64 TARGET_CFLAGS := -nostdinc -I include/libc -DTARGET_N64 -D_LANGUAGE_C
CC_CFLAGS := -fno-builtin CC_CFLAGS := -fno-builtin
endif endif
INCLUDE_CFLAGS := -I include -I $(BUILD_DIR) -I $(BUILD_DIR)/include -I src -I . INCLUDE_CFLAGS := -I include -I $(BUILD_DIR) -I $(BUILD_DIR)/include -I src -I .
# Check code syntax with host compiler # Check code syntax with host compiler
CC_CHECK := gcc -fsyntax-only -fsigned-char $(CC_CFLAGS) $(TARGET_CFLAGS) $(INCLUDE_CFLAGS) -std=gnu90 -Wall -Wextra -Wno-format-security -Wno-main -DNON_MATCHING -DAVOID_UB $(VERSION_CFLAGS) $(GRUCODE_CFLAGS) CC_CHECK := gcc
CC_CHECK_CFLAGS := -fsyntax-only -fsigned-char $(CC_CFLAGS) $(TARGET_CFLAGS) $(INCLUDE_CFLAGS) -std=gnu90 -Wall -Wextra -Wno-format-security -Wno-main -DNON_MATCHING -DAVOID_UB $(VERSION_CFLAGS) $(GRUCODE_CFLAGS)
COMMON_CFLAGS = $(OPT_FLAGS) $(TARGET_CFLAGS) $(INCLUDE_CFLAGS) $(VERSION_CFLAGS) $(MIPSISET) $(GRUCODE_CFLAGS) COMMON_CFLAGS = $(OPT_FLAGS) $(TARGET_CFLAGS) $(INCLUDE_CFLAGS) $(VERSION_CFLAGS) $(MATCH_CFLAGS) $(MIPSISET) $(GRUCODE_CFLAGS)
ASFLAGS := -march=vr4300 -mabi=32 -I include -I $(BUILD_DIR) $(VERSION_ASFLAGS) $(GRUCODE_ASFLAGS) ASFLAGS := -march=vr4300 -mabi=32 -I include -I $(BUILD_DIR) $(VERSION_ASFLAGS) $(MATCH_ASFLAGS) $(GRUCODE_ASFLAGS)
CFLAGS = -Wab,-r4300_mul -non_shared -G 0 -Xcpluscomm -Xfullwarn -signed $(COMMON_CFLAGS) $(MIPSBIT) CFLAGS = -Wab,-r4300_mul -non_shared -G 0 -Xcpluscomm -Xfullwarn -signed $(COMMON_CFLAGS) $(MIPSBIT)
OBJCOPYFLAGS := --pad-to=0x800000 --gap-fill=0xFF OBJCOPYFLAGS := --pad-to=0x800000 --gap-fill=0xFF
SYMBOL_LINKING_FLAGS := $(addprefix -R ,$(SEG_FILES)) SYMBOL_LINKING_FLAGS := $(addprefix -R ,$(SEG_FILES))
@@ -292,7 +288,7 @@ LDFLAGS := -T undefined_syms.txt -T $(BUILD_DIR)/$(LD_SCRIPT) -Map $(BUILD_DIR)/
ENDIAN_BITWIDTH := $(BUILD_DIR)/endian-and-bitwidth ENDIAN_BITWIDTH := $(BUILD_DIR)/endian-and-bitwidth
ifeq ($(COMPILER),gcc) ifeq ($(COMPILER),gcc)
CFLAGS := -march=vr4300 -mfix4300 -mno-shared -G 0 -mhard-float -fno-stack-protector -fno-common -I include -I src/ -I $(BUILD_DIR)/include -fno-PIC -mno-abicalls -fno-strict-aliasing -fno-inline-functions -ffreestanding -fwrapv -Wall -Wextra $(COMMON_CFLAGS) CFLAGS := -march=vr4300 -mfix4300 -mabi=32 -mno-shared -G 0 -mhard-float -fno-stack-protector -fno-common -fno-zero-initialized-in-bss -I include -I src/ -I $(BUILD_DIR)/include -fno-PIC -mno-abicalls -fno-strict-aliasing -fno-inline-functions -ffreestanding -fwrapv -Wall -Wextra $(COMMON_CFLAGS)
endif endif
ifeq ($(shell getconf LONG_BIT), 32) ifeq ($(shell getconf LONG_BIT), 32)
@@ -300,7 +296,7 @@ ifeq ($(shell getconf LONG_BIT), 32)
export QEMU_GUEST_BASE := 1 export QEMU_GUEST_BASE := 1
else else
# Ensure that gcc treats the code as 32-bit # Ensure that gcc treats the code as 32-bit
CC_CHECK += -m32 CC_CHECK_CFLAGS += -m32
endif endif
# Prevent a crash with -sopt # Prevent a crash with -sopt
@@ -315,7 +311,6 @@ N64CKSUM = $(TOOLS_DIR)/n64cksum
N64GRAPHICS = $(TOOLS_DIR)/n64graphics N64GRAPHICS = $(TOOLS_DIR)/n64graphics
N64GRAPHICS_CI = $(TOOLS_DIR)/n64graphics_ci N64GRAPHICS_CI = $(TOOLS_DIR)/n64graphics_ci
TEXTCONV = $(TOOLS_DIR)/textconv TEXTCONV = $(TOOLS_DIR)/textconv
IPLFONTUTIL = $(TOOLS_DIR)/iplfontutil
AIFF_EXTRACT_CODEBOOK = $(TOOLS_DIR)/aiff_extract_codebook AIFF_EXTRACT_CODEBOOK = $(TOOLS_DIR)/aiff_extract_codebook
VADPCM_ENC = $(TOOLS_DIR)/vadpcm_enc VADPCM_ENC = $(TOOLS_DIR)/vadpcm_enc
EXTRACT_DATA_FOR_MIO = $(TOOLS_DIR)/extract_data_for_mio EXTRACT_DATA_FOR_MIO = $(TOOLS_DIR)/extract_data_for_mio
@@ -326,20 +321,17 @@ LOADER = loader64
LOADER_FLAGS = -vwf LOADER_FLAGS = -vwf
SHA1SUM = sha1sum SHA1SUM = sha1sum
ifeq (, $(shell which armips 2>/dev/null))
RSPASM := $(TOOLS_DIR)/armips
else
RSPASM = armips
endif
# Use Objcopy instead of extract_data_for_mio # Use Objcopy instead of extract_data_for_mio
ifeq ($(COMPILER),gcc) ifeq ($(COMPILER),gcc)
EXTRACT_DATA_FOR_MIO := $(OBJCOPY) -O binary --only-section=.data EXTRACT_DATA_FOR_MIO := $(OBJCOPY) -O binary --only-section=.data
endif endif
###################### Dependency Check #####################
BINUTILS_VER_MAJOR := $(shell $(LD) --version | grep ^GNU | sed 's/^.* //; s/\..*//g')
BINUTILS_VER_MINOR := $(shell $(LD) --version | grep ^GNU | sed 's/^[^.]*\.//; s/\..*//g')
BINUTILS_DEPEND := $(shell expr $(BINUTILS_VER_MAJOR) \>= 2 \& $(BINUTILS_VER_MINOR) \>= 27)
ifeq ($(BINUTILS_DEPEND),0)
$(error binutils version 2.27 required, version $(BINUTILS_VER_MAJOR).$(BINUTILS_VER_MINOR) detected)
endif
######################## Targets ############################# ######################## Targets #############################
all: $(ROM) all: $(ROM)
@@ -362,10 +354,10 @@ load: $(ROM)
libultra: $(BUILD_DIR)/libultra.a libultra: $(BUILD_DIR)/libultra.a
asm/boot.s: $(BUILD_DIR)/lib/bin/ipl3_font.bin $(BUILD_DIR)/asm/boot.o: $(IPL3_RAW_FILES)
$(BUILD_DIR)/src/game/crash_screen.o: $(CRASH_TEXTURE_C_FILES)
$(BUILD_DIR)/lib/bin/ipl3_font.bin: lib/ipl3_font.png $(BUILD_DIR)/lib/rsp.o: $(BUILD_DIR)/rsp/rspboot.bin $(BUILD_DIR)/rsp/fast3d.bin $(BUILD_DIR)/rsp/audio.bin
$(IPLFONTUTIL) e $< $@
$(BUILD_DIR)/include/text_strings.h: include/text_strings.h.in $(BUILD_DIR)/include/text_strings.h: include/text_strings.h.in
$(TEXTCONV) charmap.txt $< $@ $(TEXTCONV) charmap.txt $< $@
@@ -410,7 +402,8 @@ $(BUILD_DIR)/text/%/define_text.inc.c: text/define_text.inc.c text/%/courses.h t
$(CPP) $(VERSION_CFLAGS) $< -o $@ -I text/$*/ $(CPP) $(VERSION_CFLAGS) $< -o $@ -I text/$*/
$(TEXTCONV) charmap.txt $@ $@ $(TEXTCONV) charmap.txt $@ $@
ALL_DIRS := $(BUILD_DIR) $(addprefix $(BUILD_DIR)/,$(SRC_DIRS) $(ASM_DIRS) $(GODDARD_SRC_DIRS) $(ULTRA_SRC_DIRS) $(ULTRA_ASM_DIRS) $(ULTRA_BIN_DIRS) $(BIN_DIRS) $(TEXTURE_DIRS) $(TEXT_DIRS) $(SOUND_SAMPLE_DIRS) $(addprefix levels/,$(LEVEL_DIRS)) include) $(MIO0_DIR) $(addprefix $(MIO0_DIR)/,$(VERSION)) $(SOUND_BIN_DIR) $(SOUND_BIN_DIR)/sequences/$(VERSION) RSP_DIRS := $(BUILD_DIR)/rsp
ALL_DIRS := $(BUILD_DIR) $(addprefix $(BUILD_DIR)/,$(SRC_DIRS) $(ASM_DIRS) $(GODDARD_SRC_DIRS) $(ULTRA_SRC_DIRS) $(ULTRA_ASM_DIRS) $(ULTRA_BIN_DIRS) $(BIN_DIRS) $(TEXTURE_DIRS) $(TEXT_DIRS) $(SOUND_SAMPLE_DIRS) $(addprefix levels/,$(LEVEL_DIRS)) include) $(MIO0_DIR) $(addprefix $(MIO0_DIR)/,$(VERSION)) $(SOUND_BIN_DIR) $(SOUND_BIN_DIR)/sequences/$(VERSION) $(RSP_DIRS)
# Make sure build directory exists before compiling anything # Make sure build directory exists before compiling anything
DUMMY != mkdir -p $(ALL_DIRS) DUMMY != mkdir -p $(ALL_DIRS)
@@ -480,6 +473,9 @@ $(BUILD_DIR)/%.table: %.aiff
$(BUILD_DIR)/%.aifc: $(BUILD_DIR)/%.table %.aiff $(BUILD_DIR)/%.aifc: $(BUILD_DIR)/%.table %.aiff
$(VADPCM_ENC) -c $^ $@ $(VADPCM_ENC) -c $^ $@
$(BUILD_DIR)/rsp/%.bin $(BUILD_DIR)/rsp/%_data.bin: rsp/%.s
$(RSPASM) -sym $@.sym -definelabel $(VERSION_DEF) 1 -definelabel $(GRUCODE_DEF) 1 -strequ CODE_FILE $(BUILD_DIR)/rsp/$*.bin -strequ DATA_FILE $(BUILD_DIR)/rsp/$*_data.bin $<
$(ENDIAN_BITWIDTH): tools/determine-endian-bitwidth.c $(ENDIAN_BITWIDTH): tools/determine-endian-bitwidth.c
$(CC) -c $(CFLAGS) -o $@.dummy2 $< 2>$@.dummy1; true $(CC) -c $(CFLAGS) -o $@.dummy2 $< 2>$@.dummy1; true
grep -o 'msgbegin --endian .* --bitwidth .* msgend' $@.dummy1 > $@.dummy2 grep -o 'msgbegin --endian .* --bitwidth .* msgend' $@.dummy1 > $@.dummy2
@@ -510,8 +506,11 @@ $(SOUND_BIN_DIR)/%.m64: $(SOUND_BIN_DIR)/%.o
$(SOUND_BIN_DIR)/%.o: $(SOUND_BIN_DIR)/%.s $(SOUND_BIN_DIR)/%.o: $(SOUND_BIN_DIR)/%.s
$(AS) $(ASFLAGS) -o $@ $< $(AS) $(ASFLAGS) -o $@ $<
$(SOUND_BIN_DIR)/%.s: $(SOUND_BIN_DIR)/% $(SOUND_BIN_DIR)/%.inc.c: $(SOUND_BIN_DIR)/%
printf ".section .data\n\n.incbin \"$<\"\n" > $@ hexdump -v -e '1/1 "0x%X,"' $< > $@
echo >> $@
$(SOUND_BIN_DIR)/sound_data.o: $(SOUND_BIN_DIR)/sound_data.ctl.inc.c $(SOUND_BIN_DIR)/sound_data.tbl.inc.c $(SOUND_BIN_DIR)/sequences.bin.inc.c $(SOUND_BIN_DIR)/bank_sets.inc.c
$(BUILD_DIR)/levels/scripts.o: $(BUILD_DIR)/include/level_headers.h $(BUILD_DIR)/levels/scripts.o: $(BUILD_DIR)/include/level_headers.h
@@ -559,12 +558,18 @@ else
# acpp, which needs -Wp,-+ to handle C++-style comments. # acpp, which needs -Wp,-+ to handle C++-style comments.
$(BUILD_DIR)/src/audio/effects.o: OPT_FLAGS := -O2 -Wo,-loopunroll,0 -sopt,-inline=sequence_channel_process_sound,-scalaroptimize=1 -Wp,-+ $(BUILD_DIR)/src/audio/effects.o: OPT_FLAGS := -O2 -Wo,-loopunroll,0 -sopt,-inline=sequence_channel_process_sound,-scalaroptimize=1 -Wp,-+
$(BUILD_DIR)/src/audio/synthesis.o: OPT_FLAGS := -O2 -sopt,-scalaroptimize=1 -Wp,-+ $(BUILD_DIR)/src/audio/synthesis.o: OPT_FLAGS := -O2 -sopt,-scalaroptimize=1 -Wp,-+
#$(BUILD_DIR)/src/audio/seqplayer.o: OPT_FLAGS := -O2 -sopt,-inline_manual,-scalaroptimize=1 -Wp,-+ #-Wo,-v,-bb,-l,seqplayer_list.txt
# Add a target for build/eu/src/audio/*.copt to make it easier to see debug # Add a target for build/eu/src/audio/*.copt to make it easier to see debug
$(BUILD_DIR)/src/audio/%.acpp: src/audio/%.c $(BUILD_DIR)/src/audio/%.acpp: src/audio/%.c
$(QEMU_IRIX) -silent -L $(IRIX_ROOT) $(IRIX_ROOT)/usr/lib/acpp $(TARGET_CFLAGS) $(INCLUDE_CFLAGS) $(VERSION_CFLAGS) $(GRUCODE_CFLAGS) -D__sgi -+ $< > $@ $(QEMU_IRIX) -silent -L $(IRIX_ROOT) $(IRIX_ROOT)/usr/lib/acpp $(TARGET_CFLAGS) $(INCLUDE_CFLAGS) $(VERSION_CFLAGS) $(MATCH_CFLAGS) $(GRUCODE_CFLAGS) -D__sgi -+ $< > $@
$(BUILD_DIR)/src/audio/seqplayer.copt: $(BUILD_DIR)/src/audio/seqplayer.acpp
$(QEMU_IRIX) -silent -L $(IRIX_ROOT) $(IRIX_ROOT)/usr/lib/copt -signed -I=$< -CMP=$@ -cp=i -scalaroptimize=1 -inline_manual
$(BUILD_DIR)/src/audio/%.copt: $(BUILD_DIR)/src/audio/%.acpp $(BUILD_DIR)/src/audio/%.copt: $(BUILD_DIR)/src/audio/%.acpp
$(QEMU_IRIX) -silent -L $(IRIX_ROOT) $(IRIX_ROOT)/usr/lib/copt -signed -I=$< -CMP=$@ -cp=i -scalaroptimize=1 $(QEMU_IRIX) -silent -L $(IRIX_ROOT) $(IRIX_ROOT)/usr/lib/copt -signed -I=$< -CMP=$@ -cp=i -scalaroptimize=1
endif endif
endif endif
@@ -579,12 +584,12 @@ $(GLOBAL_ASM_DEP).$(NON_MATCHING):
touch $@ touch $@
$(BUILD_DIR)/%.o: %.c $(BUILD_DIR)/%.o: %.c
@$(CC_CHECK) -MMD -MP -MT $@ -MF $(BUILD_DIR)/$*.d $< @$(CC_CHECK) $(CC_CHECK_CFLAGS) -MMD -MP -MT $@ -MF $(BUILD_DIR)/$*.d $<
$(CC) -c $(CFLAGS) -o $@ $< $(CC) -c $(CFLAGS) -o $@ $<
$(BUILD_DIR)/%.o: $(BUILD_DIR)/%.c $(BUILD_DIR)/%.o: $(BUILD_DIR)/%.c
@$(CC_CHECK) -MMD -MP -MT $@ -MF $(BUILD_DIR)/$*.d $< @$(CC_CHECK) $(CC_CHECK_CFLAGS) -MMD -MP -MT $@ -MF $(BUILD_DIR)/$*.d $<
$(CC) -c $(CFLAGS) -o $@ $< $(CC) -c $(CFLAGS) -o $@ $<
$(BUILD_DIR)/%.o: %.s $(BUILD_DIR)/%.o: %.s
@@ -613,8 +618,8 @@ $(BUILD_DIR)/$(TARGET).objdump: $(ELF)
.PHONY: all clean distclean default diff test load libultra .PHONY: all clean distclean default diff test load libultra
.PRECIOUS: $(BUILD_DIR)/bin/%.elf $(SOUND_BIN_DIR)/%.ctl $(SOUND_BIN_DIR)/%.tbl $(SOUND_SAMPLE_TABLES) $(SOUND_BIN_DIR)/%.s $(BUILD_DIR)/% # with no prerequisites, .SECONDARY causes no intermediate target to be removed
.DELETE_ON_ERROR: .SECONDARY:
# Remove built-in rules, to improve performance # Remove built-in rules, to improve performance
MAKEFLAGS += --no-builtin-rules MAKEFLAGS += --no-builtin-rules

View File

@@ -5,7 +5,7 @@
# obtain a list of segments from the *.c files in bin directory # obtain a list of segments from the *.c files in bin directory
SEGMENTS := $(notdir $(basename $(wildcard bin/*.c))) $(addprefix $(VERSION)/,$(notdir $(basename $(wildcard bin/$(VERSION)/*.c)))) $(addsuffix _skybox,$(notdir $(basename $(wildcard textures/skyboxes/*.png)))) SEGMENTS := $(notdir $(basename $(wildcard bin/*.c))) $(addprefix $(VERSION)/,$(notdir $(basename $(wildcard bin/$(VERSION)/*.c)))) $(addsuffix _skybox,$(notdir $(basename $(wildcard textures/skyboxes/*.png))))
ACTORS := $(filter %/,$(wildcard actors/*/)) ACTORS := $(filter %/,$(wildcard actors/*/))
TEXTURE_DIRS := $(addprefix textures/,$(SEGMENTS)) $(ACTORS) textures/intro_raw TEXTURE_DIRS := $(addprefix textures/,$(SEGMENTS)) $(ACTORS) textures/crash_screen textures/intro_raw textures/ipl3_raw
# NOTE: textures assume naming convention "texture.<encoding>.png" generates "texture.<encoding>" # NOTE: textures assume naming convention "texture.<encoding>.png" generates "texture.<encoding>"
@@ -243,6 +243,12 @@ $(BUILD_DIR)/bin/%_skybox.elf: SEGMENT_ADDRESS := 0x0A000000
# Misc Rules # Misc Rules
# -------------------------------------- # --------------------------------------
# intro_raw textures are not compressed # intro and ipl3 textures are not compressed
INTRO_RAW_FILES := $(wildcard $(TEXTURE_DIR)/intro_raw/*.png) INTRO_RAW_FILES := $(wildcard $(TEXTURE_DIR)/intro_raw/*.png)
$(BUILD_DIR)/src/goddard/renderer.o: $(addprefix $(BUILD_DIR)/,$(patsubst %.png,%.inc.c,$(INTRO_RAW_FILES))) $(BUILD_DIR)/src/goddard/renderer.o: $(addprefix $(BUILD_DIR)/,$(patsubst %.png,%.inc.c,$(INTRO_RAW_FILES)))
IPL3_TEXTURE_FILES := $(wildcard $(TEXTURE_DIR)/ipl3_raw/*.png)
IPL3_RAW_FILES := $(addprefix $(BUILD_DIR)/,$(patsubst %.png,%,$(IPL3_TEXTURE_FILES)))
CRASH_TEXTURE_FILES := $(wildcard $(TEXTURE_DIR)/crash_screen/*.png)
CRASH_TEXTURE_C_FILES := $(addprefix $(BUILD_DIR)/,$(patsubst %.png,%.inc.c,$(CRASH_TEXTURE_FILES)))

166
README.md
View File

@@ -1,9 +1,8 @@
# Super Mario 64 # Super Mario 64
This repo contains a full decompilation of Super Mario 64 (J), (U), and (E). - This repo contains a full decompilation of Super Mario 64 (J), (U), and (E) with minor exceptions in the audio subsystem.
The source and data have been decompiled but complete naming and documentation - Naming and documentation of the source code and data structures are in progress.
all of the code and data is still a work in progress. Decompiling the Shindou ROM - Efforts to decompile the Shindou ROM steadily advance toward a matching build.
is also an ongoing effort.
It builds the following ROMs: It builds the following ROMs:
@@ -12,65 +11,60 @@ It builds the following ROMs:
* sm64.eu.z64 `sha1: 4ac5721683d0e0b6bbb561b58a71740845dceea9` * sm64.eu.z64 `sha1: 4ac5721683d0e0b6bbb561b58a71740845dceea9`
This repo does not include all assets necessary for compiling the ROMs. This repo does not include all assets necessary for compiling the ROMs.
A prior copy of the game is required to extract the required assets. A prior copy of the game is required to extract the assets.
## Quick Start (for Ubuntu)
1. Install prerequisites: `sudo apt install -y build-essential git binutils-mips-linux-gnu python3 libaudiofile-dev`
2. Clone the repo from within Linux: `git clone https://github.com/n64decomp/sm64.git`
3. Place a Super Mario 64 ROM called `baserom.<VERSION>.z64` into the project folder for asset extraction, where `VERSION` can be `us`, `jp`, or `eu`.
4. Run `make` to build. Qualify the version through `make VERSION=<VERSION>`. Add `-j4` to improve build speed (hardware dependent).
Ensure the repo path length does not exceed 255 characters. Long path names result in build errors.
## Installation ## Installation
### Docker ### Windows
#### 1. Copy baserom(s) for asset extraction Install WSL and a distro of your choice following
[Windows Subsystem for Linux Installation Guide for Windows 10.](https://docs.microsoft.com/en-us/windows/wsl/install-win10)
We recommend either Debian or Ubuntu 18.04 Linux distributions under WSL.
Note: WSL1 does not currently support Ubuntu 20.04.
For each version (jp/us/eu) that you want to build a ROM for, put an existing ROM at Next, clone the SM64 repo from within the Linux shell:
`./baserom.<version>.z64` for asset extraction. `git clone https://github.com/n64decomp/sm64.git`
#### 2. Create docker image Then continue following the directions in the [Linux](#linux) installation section below.
```bash
docker build -t sm64 .
```
#### 3. Build
To build we simply have to mount our local filesystem into the docker container and build.
```bash
# for example if you have baserom.us.z64 in the project root
docker run --rm --mount type=bind,source="$(pwd)",destination=/sm64 sm64 make VERSION=us -j4
# if your host system is linux you need to tell docker what user should own the output files
docker run --rm --mount type=bind,source="$(pwd)",destination=/sm64 --user $UID:$UID sm64 make VERSION=us -j4
```
Resulting artifacts can be found in the `build` directory.
### Linux ### Linux
#### 1. Copy baserom(s) for asset extraction There are 3 steps to set up a working build.
For each version (jp/us/eu) that you want to build a ROM for, put an existing ROM at #### Step 1: Install dependencies
`./baserom.<version>.z64` for asset extraction.
#### 2. Install build dependencies
The build system has the following package requirements: The build system has the following package requirements:
* binutils-mips >= 2.27 * binutils-mips
* python3 >= 3.6 * python3 >= 3.6
* libaudiofile * libaudiofile
* qemu-irix * qemu-irix
__Debian / Ubuntu__ Dependency installation instructions for common Linux distros are provided below:
##### Debian / Ubuntu
To install build dependencies:
``` ```
sudo apt install build-essential pkg-config git binutils-mips-linux-gnu python3 zlib1g-dev libaudiofile-dev sudo apt install -y build-essential git binutils-mips-linux-gnu python3 libaudiofile-dev
``` ```
Download latest package from [qemu-irix Releases](https://github.com/n64decomp/qemu-irix/releases) Download latest package from [qemu-irix Releases.](https://github.com/n64decomp/qemu-irix/releases)
Install this package with:
``` ```
sudo dpkg -i qemu-irix-2.11.0-2169-g32ab296eef_amd64.deb sudo dpkg -i qemu-irix-2.11.0-2169-g32ab296eef_amd64.deb
``` ```
(Optional) Clone https://github.com/n64decomp/qemu-irix and follow the install instructions in the README. ##### Arch Linux
To install build dependencies:
__Arch Linux__
``` ```
sudo pacman -S base-devel python audiofile sudo pacman -S base-devel python audiofile
``` ```
@@ -78,29 +72,70 @@ Install the following AUR packages:
* [mips64-elf-binutils](https://aur.archlinux.org/packages/mips64-elf-binutils) (AUR) * [mips64-elf-binutils](https://aur.archlinux.org/packages/mips64-elf-binutils) (AUR)
* [qemu-irix-git](https://aur.archlinux.org/packages/qemu-irix-git) (AUR) * [qemu-irix-git](https://aur.archlinux.org/packages/qemu-irix-git) (AUR)
#### 3. Build ROM
Run `make` to build the ROM (defaults to `VERSION=us`). Make sure your path to the repo ##### Other Linux distributions
is not too long or else this process will error, as the emulated IDO compiler cannot
handle paths longer than 255 characters. Most modern Linux distributions should have equivalent packages to the other two listed above.
Examples: You may have to use a different version of GNU binutils. Listed below are fully compatible binutils
distributions with support in the makefile, and examples of distros that offer them:
* `mips64-elf-` (Arch AUR)
* `mips-linux-gnu-` (Ubuntu and other Debian-based distros)
* `mips64-linux-gnu-` (RHEL/CentOS/Fedora)
You may also use [Docker](#docker-installation) to handle installing an image with minimal dependencies.
#### Step 2: Copy baserom(s) for asset extraction
For each version (jp/us/eu) for which you want to build a ROM, put an existing ROM at
`./baserom.<VERSION>.z64` for asset extraction.
##### Step 3: Build the ROM
Run `make` to build the ROM (defaults to `VERSION=us`).
Other examples:
``` ```
make VERSION=jp -j4 # build (J) version instead with 4 jobs make VERSION=jp -j4 # build (J) version instead with 4 jobs
make VERSION=eu COMPARE=0 # non-matching EU version still WIP make VERSION=eu COMPARE=0 # build (EU) version but do not compare ROM hashes
``` ```
## Windows Resulting artifacts can be found in the `build` directory.
For Windows, install WSL and a distro of your choice following The full list of configurable variables are listed below, with the default being the first listed:
[Windows Subsystem for Linux Installation Guide for Windows 10](https://docs.microsoft.com/en-us/windows/wsl/install-win10)
We recommend either Debian or Ubuntu 18.04 Linux distributions under WSL.
Then follow the directions in the [Linux](#linux) installation section above. * ``VERSION``: ``us``, ``jp``, ``eu``, ``sh`` (WIP)
* ``GRUCODE``: ``f3d_old``, ``f3d_new``, ``f3dex``, ``f3dex2``, ``f3dzex``
* ``COMPARE``: ``1`` (compare ROM hash), ``0`` (do not compare ROM hash)
* ``NON_MATCHING``: Use functionally equivalent C implementations for non-matchings. Also will avoid instances of undefined behavior.
* ``CROSS``: Cross-compiler tool prefix (Example: ``mips64-elf-``).
* ``QEMU_IRIX``: Path to a ``qemu-irix`` binary.
## macOS ### macOS
macOS is currently unsupported as qemu-irix is unable to be built for macOS host. Installing Docker is the recommended avenue for macOS users. This project does not support macOS natively due to lack of macOS host support.
The recommended path is installing a Linux distribution under a VM.
### Docker Installation
#### Create Docker image
Create the docker image with `docker build -t sm64`.
#### Build
To build, mount the local filesystem into the Docker container and build the ROM with `docker run`.
##### macOS example for (U):
```
docker run --rm --mount type=bind,source="$(pwd)",destination=/sm64 sm64 make VERSION=us -j4
```
##### Linux example for (U):
For a Linux host, Docker needs to be instructed which user should own the output files:
```
docker run --rm --mount type=bind,source="$(pwd)",destination=/sm64 --user $UID:$UID sm64 make VERSION=us -j4
```
Resulting artifacts can be found in the `build` directory.
## Project Structure ## Project Structure
@@ -108,11 +143,11 @@ The recommended path is installing a Linux distribution under a VM.
sm64 sm64
├── actors: object behaviors, geo layout, and display lists ├── actors: object behaviors, geo layout, and display lists
├── asm: handwritten assembly code, rom header ├── asm: handwritten assembly code, rom header
   └── non_matchings: asm for non-matching sections └── non_matchings: asm for non-matching sections
├── assets: animation and demo data ├── assets: animation and demo data
   ├── anims: animation data ├── anims: animation data
   └── demos: demo data └── demos: demo data
├── bin: asm files for ordering display lists and textures ├── bin: C files for ordering display lists and textures
├── build: output directory ├── build: output directory
├── data: behavior scripts, misc. data ├── data: behavior scripts, misc. data
├── doxygen: documentation infrastructure ├── doxygen: documentation infrastructure
@@ -120,14 +155,15 @@ sm64
├── include: header files ├── include: header files
├── levels: level scripts, geo layout, and display lists ├── levels: level scripts, geo layout, and display lists
├── lib: SDK library code ├── lib: SDK library code
├── rsp: audio and Fast3D RSP assembly code
├── sound: sequences, sound samples, and sound banks ├── sound: sequences, sound samples, and sound banks
├── src: C source code for game ├── src: C source code for game
   ├── audio: audio code ├── audio: audio code
   ├── buffers: stacks, heaps, and task buffers ├── buffers: stacks, heaps, and task buffers
   ├── engine: script processing engines and utils ├── engine: script processing engines and utils
   ├── game: behaviors and rest of game source ├── game: behaviors and rest of game source
   ├── goddard: Mario intro screen ├── goddard: Mario intro screen
   └── menu: title screen and file, act, and debug level selection menus └── menu: title screen and file, act, and debug level selection menus
├── text: dialog, level names, act names ├── text: dialog, level names, act names
├── textures: skybox and generic texture data ├── textures: skybox and generic texture data
└── tools: build tools └── tools: build tools
@@ -138,6 +174,6 @@ sm64
Pull requests are welcome. For major changes, please open an issue first to Pull requests are welcome. For major changes, please open an issue first to
discuss what you would like to change. discuss what you would like to change.
Run clang-format on your code to ensure it meets the project's coding standards. Run `clang-format` on your code to ensure it meets the project's coding standards.
Official Discord: https://discord.gg/DuYH3Fh Official Discord: https://discord.gg/DuYH3Fh

View File

@@ -1,7 +1,7 @@
// Blue Coin Switch // Blue Coin Switch
// 0x08000E98 - 0x08000F10 // 0x08000E98 - 0x08000F10
const s16 blue_coin_switch_seg8_collision_08000E98[] = { const Collision blue_coin_switch_seg8_collision_08000E98[] = {
COL_INIT(), COL_INIT(),
COL_VERTEX_INIT(0x8), COL_VERTEX_INIT(0x8),
COL_VERTEX(26, 0, 26), COL_VERTEX(26, 0, 26),

View File

@@ -1,7 +1,7 @@
// Breakable Box // Breakable Box
// 0x08012D70 - 0x08012DF4 // 0x08012D70 - 0x08012DF4
const s16 breakable_box_seg8_collision_08012D70[] = { const Collision breakable_box_seg8_collision_08012D70[] = {
COL_INIT(), COL_INIT(),
COL_VERTEX_INIT(0x8), COL_VERTEX_INIT(0x8),
COL_VERTEX(-100, 0, -100), COL_VERTEX(-100, 0, -100),

View File

@@ -1,7 +1,7 @@
// Cannon Lid // Cannon Lid
// 0x08004950 - 0x08004980 // 0x08004950 - 0x08004980
const s16 cannon_lid_seg8_collision_08004950[] = { const Collision cannon_lid_seg8_collision_08004950[] = {
COL_INIT(), COL_INIT(),
COL_VERTEX_INIT(0x4), COL_VERTEX_INIT(0x4),
COL_VERTEX(112, 0, -111), COL_VERTEX(112, 0, -111),

View File

@@ -1,6 +1,6 @@
// Capswitch // Capswitch
const s16 capswitch_collision_050033D0[] = { const Collision capswitch_collision_050033D0[] = {
COL_INIT(), COL_INIT(),
COL_VERTEX_INIT(0x8), COL_VERTEX_INIT(0x8),
COL_VERTEX(292, 0, 254), COL_VERTEX(292, 0, 254),
@@ -27,7 +27,7 @@ const s16 capswitch_collision_050033D0[] = {
COL_END(), COL_END(),
}; };
const s16 capswitch_collision_05003448[] = { const Collision capswitch_collision_05003448[] = {
COL_INIT(), COL_INIT(),
COL_VERTEX_INIT(0x8), COL_VERTEX_INIT(0x8),
COL_VERTEX(292, 0, 254), COL_VERTEX(292, 0, 254),

View File

@@ -1,7 +1,7 @@
// Checkerboard Platform // Checkerboard Platform
// 0x0800D710 - 0x0800D794 // 0x0800D710 - 0x0800D794
const s16 checkerboard_platform_seg8_collision_0800D710[] = { const Collision checkerboard_platform_seg8_collision_0800D710[] = {
COL_INIT(), COL_INIT(),
COL_VERTEX_INIT(0x8), COL_VERTEX_INIT(0x8),
COL_VERTEX(256, -25, -153), COL_VERTEX(256, -25, -153),

View File

@@ -28,7 +28,7 @@ extern const GeoLayout blue_coin_switch_geo[];
extern const Gfx blue_coin_switch_seg8_dl_08000D58[]; extern const Gfx blue_coin_switch_seg8_dl_08000D58[];
extern const Gfx blue_coin_switch_seg8_dl_08000DD0[]; extern const Gfx blue_coin_switch_seg8_dl_08000DD0[];
extern const Gfx blue_coin_switch_seg8_dl_08000E08[]; extern const Gfx blue_coin_switch_seg8_dl_08000E08[];
extern const s16 blue_coin_switch_seg8_collision_08000E98[]; extern const Collision blue_coin_switch_seg8_collision_08000E98[];
// bobomb // bobomb
extern const GeoLayout black_bobomb_geo[]; extern const GeoLayout black_bobomb_geo[];
@@ -57,7 +57,7 @@ extern const Gfx breakable_box_seg8_dl_08012C30[];
extern const Gfx breakable_box_seg8_dl_08012CD8[]; extern const Gfx breakable_box_seg8_dl_08012CD8[];
extern const Gfx breakable_box_seg8_dl_08012D20[]; extern const Gfx breakable_box_seg8_dl_08012D20[];
extern const Gfx breakable_box_seg8_dl_08012D48[]; extern const Gfx breakable_box_seg8_dl_08012D48[];
extern const s16 breakable_box_seg8_collision_08012D70[]; extern const Collision breakable_box_seg8_collision_08012D70[];
// cannon_barrel // cannon_barrel
extern const GeoLayout cannon_barrel_geo[]; extern const GeoLayout cannon_barrel_geo[];
@@ -74,14 +74,14 @@ extern const Gfx cannon_base_seg8_dl_080057F8[];
// cannon_lid // cannon_lid
extern const Gfx cannon_lid_seg8_dl_08004898[]; extern const Gfx cannon_lid_seg8_dl_08004898[];
extern const Gfx cannon_lid_seg8_dl_080048E0[]; extern const Gfx cannon_lid_seg8_dl_080048E0[];
extern const s16 cannon_lid_seg8_collision_08004950[]; extern const Collision cannon_lid_seg8_collision_08004950[];
// checkerboard_platform // checkerboard_platform
extern const GeoLayout checkerboard_platform_geo[]; extern const GeoLayout checkerboard_platform_geo[];
extern const Gfx checkerboard_platform_seg8_dl_0800D5C0[]; extern const Gfx checkerboard_platform_seg8_dl_0800D5C0[];
extern const Gfx checkerboard_platform_seg8_dl_0800D618[]; extern const Gfx checkerboard_platform_seg8_dl_0800D618[];
extern const Gfx checkerboard_platform_seg8_dl_0800D680[]; extern const Gfx checkerboard_platform_seg8_dl_0800D680[];
extern const s16 checkerboard_platform_seg8_collision_0800D710[]; extern const Collision checkerboard_platform_seg8_collision_0800D710[];
// chuckya // chuckya
extern const GeoLayout chuckya_geo[]; extern const GeoLayout chuckya_geo[];
@@ -136,7 +136,7 @@ extern const Gfx exclamation_box_outline_seg8_dl_08025968[];
extern const Gfx exclamation_box_outline_seg8_dl_080259F8[]; extern const Gfx exclamation_box_outline_seg8_dl_080259F8[];
extern const Gfx exclamation_box_outline_seg8_dl_08025EC0[]; extern const Gfx exclamation_box_outline_seg8_dl_08025EC0[];
extern const Gfx exclamation_box_outline_seg8_dl_08025F08[]; extern const Gfx exclamation_box_outline_seg8_dl_08025F08[];
extern const s16 exclamation_box_outline_seg8_collision_08025F78[]; extern const Collision exclamation_box_outline_seg8_collision_08025F78[];
// flyguy // flyguy
extern const GeoLayout flyguy_geo[]; extern const GeoLayout flyguy_geo[];
@@ -189,18 +189,18 @@ extern const Gfx koopa_shell_seg8_dl_08028B78[];
extern const GeoLayout metal_box_geo[]; extern const GeoLayout metal_box_geo[];
extern const Gfx metal_box_seg8_dl_08024B18[]; extern const Gfx metal_box_seg8_dl_08024B18[];
extern const Gfx metal_box_dl[]; extern const Gfx metal_box_dl[];
extern const s16 metal_box_seg8_collision_08024C28[]; extern const Collision metal_box_seg8_collision_08024C28[];
// purple_switch // purple_switch
extern const GeoLayout purple_switch_geo[]; extern const GeoLayout purple_switch_geo[];
extern const Gfx purple_switch_seg8_dl_0800C668[]; extern const Gfx purple_switch_seg8_dl_0800C668[];
extern const Gfx purple_switch_seg8_dl_0800C6E0[]; extern const Gfx purple_switch_seg8_dl_0800C6E0[];
extern const Gfx purple_switch_seg8_dl_0800C718[]; extern const Gfx purple_switch_seg8_dl_0800C718[];
extern const s16 purple_switch_seg8_collision_0800C7A8[]; extern const Collision purple_switch_seg8_collision_0800C7A8[];
// test_platform // test_platform
extern const GeoLayout test_platform_geo[]; extern const GeoLayout test_platform_geo[];
extern const Gfx unknown_seg8_dl_08026260[]; extern const Gfx unknown_seg8_dl_08026260[];
extern const s16 unknown_seg8_collision_080262F8[]; extern const Collision unknown_seg8_collision_080262F8[];
#endif #endif

View File

@@ -225,8 +225,8 @@ extern const Gfx tree_seg3_dl_03032170[];
extern const Gfx tree_seg3_dl_03033258[]; extern const Gfx tree_seg3_dl_03033258[];
// warp_collision // warp_collision
extern const s16 door_seg3_collision_0301CE78[]; extern const Collision door_seg3_collision_0301CE78[];
extern const s16 lll_hexagonal_mesh_seg3_collision_0301CECC[]; extern const Collision lll_hexagonal_mesh_seg3_collision_0301CECC[];
// warp_pipe // warp_pipe
extern const GeoLayout warp_pipe_geo[]; extern const GeoLayout warp_pipe_geo[];
@@ -235,7 +235,7 @@ extern const Gfx warp_pipe_seg3_dl_03008F98[];
extern const Gfx warp_pipe_seg3_dl_03009968[]; extern const Gfx warp_pipe_seg3_dl_03009968[];
extern const Gfx warp_pipe_seg3_dl_03009A20[]; extern const Gfx warp_pipe_seg3_dl_03009A20[];
extern const Gfx warp_pipe_seg3_dl_03009A50[]; extern const Gfx warp_pipe_seg3_dl_03009A50[];
extern const s16 warp_pipe_seg3_collision_03009AC8[]; extern const Collision warp_pipe_seg3_collision_03009AC8[];
// white_particle // white_particle
extern const GeoLayout white_particle_geo[]; extern const GeoLayout white_particle_geo[];
@@ -248,6 +248,6 @@ extern const Gfx wooden_signpost_seg3_dl_0302DA48[];
extern const Gfx wooden_signpost_seg3_dl_0302DC40[]; extern const Gfx wooden_signpost_seg3_dl_0302DC40[];
extern const Gfx wooden_signpost_seg3_dl_0302DCD0[]; extern const Gfx wooden_signpost_seg3_dl_0302DCD0[];
extern const Gfx wooden_signpost_seg3_dl_0302DD08[]; extern const Gfx wooden_signpost_seg3_dl_0302DD08[];
extern const s16 wooden_signpost_seg3_collision_0302DD80[]; extern const Collision wooden_signpost_seg3_collision_0302DD80[];
#endif #endif

View File

@@ -1,7 +1,7 @@
// Dorrie // Dorrie
// 0x0600F644 - 0x0600FBB8 // 0x0600F644 - 0x0600FBB8
const s16 dorrie_seg6_collision_0600F644[] = { const Collision dorrie_seg6_collision_0600F644[] = {
COL_INIT(), COL_INIT(),
COL_VERTEX_INIT(0x4E), COL_VERTEX_INIT(0x4E),
COL_VERTEX(-104, 657, 512), COL_VERTEX(-104, 657, 512),
@@ -243,7 +243,7 @@ const s16 dorrie_seg6_collision_0600F644[] = {
}; };
// 0x0600FBB8 - 0x060100CE // 0x0600FBB8 - 0x060100CE
const s16 dorrie_seg6_collision_0600FBB8[] = { const Collision dorrie_seg6_collision_0600FBB8[] = {
COL_INIT(), COL_INIT(),
COL_VERTEX_INIT(0x49), COL_VERTEX_INIT(0x49),
COL_VERTEX(-301, -141, -152), COL_VERTEX(-301, -141, -152),

View File

@@ -1,7 +1,7 @@
// Exclamation Box Outline // Exclamation Box Outline
// 0x08025F78 - 0x08025FFC // 0x08025F78 - 0x08025FFC
const s16 exclamation_box_outline_seg8_collision_08025F78[] = { const Collision exclamation_box_outline_seg8_collision_08025F78[] = {
COL_INIT(), COL_INIT(),
COL_VERTEX_INIT(0x8), COL_VERTEX_INIT(0x8),
COL_VERTEX(-26, 30, -26), COL_VERTEX(-26, 30, -26),

View File

@@ -70,8 +70,8 @@ extern const GeoLayout thwomp_geo[];
extern const Gfx thwomp_seg5_dl_0500B570[]; extern const Gfx thwomp_seg5_dl_0500B570[];
extern const Gfx thwomp_seg5_dl_0500B718[]; extern const Gfx thwomp_seg5_dl_0500B718[];
extern const Gfx thwomp_seg5_dl_0500B750[]; extern const Gfx thwomp_seg5_dl_0500B750[];
extern const s16 thwomp_seg5_collision_0500B7D0[]; extern const Collision thwomp_seg5_collision_0500B7D0[];
extern const s16 thwomp_seg5_collision_0500B92C[]; extern const Collision thwomp_seg5_collision_0500B92C[];
// yellow_sphere_small // yellow_sphere_small
extern const GeoLayout yellow_sphere_geo[]; extern const GeoLayout yellow_sphere_geo[];

View File

@@ -110,7 +110,7 @@ extern const GeoLayout wooden_post_geo[];
extern const Gfx poundable_pole_seg6_dl_060022F0[]; extern const Gfx poundable_pole_seg6_dl_060022F0[];
extern const Gfx poundable_pole_seg6_dl_06002358[]; extern const Gfx poundable_pole_seg6_dl_06002358[];
extern const Gfx poundable_pole_seg6_dl_06002410[]; extern const Gfx poundable_pole_seg6_dl_06002410[];
extern const s16 poundable_pole_collision_06002490[]; extern const Collision poundable_pole_collision_06002490[];
// whomp // whomp
extern const GeoLayout whomp_geo[]; extern const GeoLayout whomp_geo[];
@@ -131,6 +131,6 @@ extern const Gfx whomp_seg6_dl_0601FEA8[];
extern const Gfx whomp_seg6_dl_0601FFA0[]; extern const Gfx whomp_seg6_dl_0601FFA0[];
extern const Gfx whomp_seg6_dl_06020038[]; extern const Gfx whomp_seg6_dl_06020038[];
extern const struct Animation *const whomp_seg6_anims_06020A04[]; extern const struct Animation *const whomp_seg6_anims_06020A04[];
extern const s16 whomp_seg6_collision_06020A0C[]; extern const Collision whomp_seg6_collision_06020A0C[];
#endif #endif

View File

@@ -32,8 +32,8 @@ extern const Gfx dorrie_seg6_dl_0600DE38[];
extern const Gfx dorrie_seg6_dl_0600DF60[]; extern const Gfx dorrie_seg6_dl_0600DF60[];
extern const Gfx dorrie_seg6_dl_0600DFA8[]; extern const Gfx dorrie_seg6_dl_0600DFA8[];
extern const struct Animation *const dorrie_seg6_anims_0600F638[]; extern const struct Animation *const dorrie_seg6_anims_0600F638[];
extern const s16 dorrie_seg6_collision_0600F644[]; extern const Collision dorrie_seg6_collision_0600F644[];
extern const s16 dorrie_seg6_collision_0600FBB8[]; extern const Collision dorrie_seg6_collision_0600FBB8[];
// mr_i_eyeball // mr_i_eyeball
extern const GeoLayout mr_i_geo[]; extern const GeoLayout mr_i_geo[];

View File

@@ -22,7 +22,7 @@ extern const Gfx penguin_seg5_dl_050072C8[];
extern const Gfx penguin_seg5_dl_05007358[]; extern const Gfx penguin_seg5_dl_05007358[];
extern const Gfx penguin_seg5_dl_05007540[]; extern const Gfx penguin_seg5_dl_05007540[];
extern const struct Animation *const penguin_seg5_anims_05008B74[]; extern const struct Animation *const penguin_seg5_anims_05008B74[];
extern const s16 penguin_seg5_collision_05008B88[]; extern const Collision penguin_seg5_collision_05008B88[];
// snowman // snowman
extern const GeoLayout mr_blizzard_hidden_geo[]; extern const GeoLayout mr_blizzard_hidden_geo[];

View File

@@ -14,8 +14,8 @@ extern const Gfx capswitch_seg5_dl_05003350[];
extern const Gfx capswitch_seg5_dl_05003370[]; extern const Gfx capswitch_seg5_dl_05003370[];
extern const Gfx capswitch_seg5_dl_05003390[]; extern const Gfx capswitch_seg5_dl_05003390[];
extern const Gfx capswitch_seg5_dl_050033B0[]; extern const Gfx capswitch_seg5_dl_050033B0[];
extern const s16 capswitch_collision_050033D0[]; extern const Collision capswitch_collision_050033D0[];
extern const s16 capswitch_collision_05003448[]; extern const Collision capswitch_collision_05003448[];
// springboard // springboard
extern const GeoLayout springboard_top_geo[]; extern const GeoLayout springboard_top_geo[];
@@ -24,6 +24,6 @@ extern const GeoLayout springboard_bottom_geo[];
extern const Gfx springboard_checkerboard_seg5_dl_050016B8[]; extern const Gfx springboard_checkerboard_seg5_dl_050016B8[];
extern const Gfx springboard_spring_seg5_dl_05001800[]; extern const Gfx springboard_spring_seg5_dl_05001800[];
extern const Gfx springboard_checkerboard_seg5_dl_05001900[]; extern const Gfx springboard_checkerboard_seg5_dl_05001900[];
extern const s16 springboard_collision_05001A28[]; extern const Collision springboard_collision_05001A28[];
#endif #endif

View File

@@ -1,7 +1,7 @@
// Metal Box // Metal Box
// 0x08024C28 - 0x08024CAC // 0x08024C28 - 0x08024CAC
const s16 metal_box_seg8_collision_08024C28[] = { const Collision metal_box_seg8_collision_08024C28[] = {
COL_INIT(), COL_INIT(),
COL_VERTEX_INIT(0x8), COL_VERTEX_INIT(0x8),
COL_VERTEX(154, 307, -153), COL_VERTEX(154, 307, -153),

Some files were not shown because too many files have changed in this diff Show More