diff --git a/CHANGES b/CHANGES index 7b81e757..bec290fb 100644 --- a/CHANGES +++ b/CHANGES @@ -1,3 +1,29 @@ +Refresh 16 (Two years later...) +1.) remove capstone from readme, slight update (#1212) +2.) Update ido static recomp (#1211) +3.) Fix misleading pointer (#1209) +4.) update outdated link (#1208) +5.) Match iQue (#1207) +6.) iQue matching except BSS (#1124) +7.) Create LICENSE.md +8.) Reorganize and apply licenses to some of the tools/ programs per discussions with their author(s). (#1203) +9.) Fix rumble_init libultra includes and checks (#1195) +10.) Stacksize moved to defines (#1199) +11.) Renamings we were too lazy to make a PR for for 3 years (#1198) +12.) Fix spelling error in sound.h comment (#1197) +13.) Update instrument sample names (#1196) +14.) Object Labeling, Behavior Params, and Cleanup (#1193) +15.) Significantly more Libultra Cleanup (#1192) +16.) Typedefs for area Terrain Data and Rooms (#1178) +17.) Allow spaces in filename for vadpcm_enc (#1175) +18.) Label all warp nodes (#1191) +19.) Remove hardware.h (#1190) +20.) Document __osSetHWintrRoutine (#1186) +21.) Change 3 space indent to 4 space indent and cleanup (#1189) +22.) Libultra cleanup and labelling (#1188) +23.) in-game menu renaming (#1187) +24.) AVOID_UB fixes and cleanup (#1185) + Refresh 15 (mostly a hotfix for RSP microcode selection) 1.) Renamed frame_buffer funcs and _ZBUFFER (#1184) diff --git a/Dockerfile b/Dockerfile index f36f10e3..40af996f 100644 --- a/Dockerfile +++ b/Dockerfile @@ -3,9 +3,8 @@ FROM ubuntu:18.04 as build RUN apt-get update && \ apt-get install -y \ binutils-mips-linux-gnu \ - bsdmainutils \ build-essential \ - libcapstone-dev \ + git \ pkgconf \ python3 diff --git a/Jenkinsfile b/Jenkinsfile index c31671ca..454cfa98 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -12,32 +12,38 @@ pipeline { sh 'ln -s "$ROMS_DIR/Super Mario 64 (U) [!].z64" baserom.us.z64' sh 'ln -s "$ROMS_DIR/Super Mario 64 (E) (M3) [!].z64" baserom.eu.z64' sh 'ln -s "$ROMS_DIR/Super Mario 64 - Shindou Edition (J) [!].z64" baserom.sh.z64' + sh 'ln -s "$ROMS_DIR/Super Mario 64 - iQue (Ch).z64" baserom.cn.z64' // verify no assets were committed to repo sh '[ -z "$(find {actors,levels,textures}/ -name \'*.png\')" ]' sh '[ -z "$(find assets/ -name \'*.m64\' -or \'*.bin\')" ]' - sh './extract_assets.py jp us eu sh' + sh './extract_assets.py jp us eu sh cn' } } - stage('Build U Source') { + stage('Build US Source') { steps { sh 'make -j4 VERSION=us VERBOSE=1 COLOR=0' } } - stage('Build S Source') { + stage('Build SH Source') { steps { sh 'make -j4 VERSION=sh VERBOSE=1 COLOR=0' } } - stage('Build E Source') { + stage('Build EU Source') { steps { sh 'make -j4 VERSION=eu VERBOSE=1 COLOR=0' } } - stage('Build J Source') { + stage('Build JP Source') { steps { sh 'make -j4 VERSION=jp VERBOSE=1 COLOR=0' } } + stage('Build CN Source') { + steps { + sh 'make -j4 VERSION=cn VERBOSE=1 COLOR=0 COMPARE=0' + } + } stage('Test Enhancements') { steps { sh ''' diff --git a/Makefile b/Makefile index 5373691a..b267233e 100644 --- a/Makefile +++ b/Makefile @@ -32,29 +32,40 @@ $(eval $(call validate-option,COMPILER,ido gcc)) # us - builds the 1996 North American version # eu - builds the 1997 PAL version # sh - builds the 1997 Japanese Shindou version, with rumble pak support +# cn - builds the 2003 Chinese iQue version VERSION ?= us -$(eval $(call validate-option,VERSION,jp us eu sh)) +$(eval $(call validate-option,VERSION,jp us eu sh cn)) ifeq ($(VERSION),jp) DEFINES += VERSION_JP=1 OPT_FLAGS := -g GRUCODE ?= f3d_old VERSION_JP_US ?= true + VERSION_SH_CN ?= false else ifeq ($(VERSION),us) DEFINES += VERSION_US=1 OPT_FLAGS := -g GRUCODE ?= f3d_old VERSION_JP_US ?= true + VERSION_SH_CN ?= false else ifeq ($(VERSION),eu) DEFINES += VERSION_EU=1 OPT_FLAGS := -O2 GRUCODE ?= f3d_new VERSION_JP_US ?= false + VERSION_SH_CN ?= false else ifeq ($(VERSION),sh) DEFINES += VERSION_SH=1 OPT_FLAGS := -O2 GRUCODE ?= f3d_new VERSION_JP_US ?= false + VERSION_SH_CN ?= true +else ifeq ($(VERSION),cn) + DEFINES += VERSION_CN=1 + OPT_FLAGS := -O2 + GRUCODE ?= f3d_new + VERSION_JP_US ?= false + VERSION_SH_CN ?= true endif TARGET := sm64.$(VERSION) @@ -129,7 +140,7 @@ $(eval $(call validate-option,COMPARE,0 1)) TARGET_STRING := sm64.$(VERSION).$(GRUCODE) # If non-default settings were chosen, disable COMPARE -ifeq ($(filter $(TARGET_STRING), sm64.jp.f3d_old sm64.us.f3d_old sm64.eu.f3d_new sm64.sh.f3d_new),) +ifeq ($(filter $(TARGET_STRING), sm64.jp.f3d_old sm64.us.f3d_old sm64.eu.f3d_new sm64.sh.f3d_new sm64.cn.f3d_new),) COMPARE := 0 endif @@ -161,6 +172,7 @@ ifeq ($(filter clean distclean,$(MAKECMDGOALS)),) $(info =======================) endif +DEFINES += _FINALROM=1 #==============================================================================# # Universal Dependencies # @@ -186,11 +198,16 @@ ifeq ($(filter clean distclean print-%,$(MAKECMDGOALS)),) endif # Make tools if out of date - $(info Building tools...) + $(info Building general tools...) DUMMY != $(MAKE) -s -C $(TOOLS_DIR) $(if $(filter-out ido0,$(COMPILER)$(USE_QEMU_IRIX)),all-except-recomp,) >&2 || echo FAIL ifeq ($(DUMMY),FAIL) $(error Failed to build tools) endif + $(info Building sm64tools...) + DUMMY != $(MAKE) -s -C $(TOOLS_DIR)/sm64tools $(if $(filter-out ido0,$(COMPILER)$(USE_QEMU_IRIX)),) >&2 || echo FAIL + ifeq ($(DUMMY),FAIL) + $(error Failed to build tools) + endif $(info Building ROM...) endif @@ -207,6 +224,8 @@ ROM := $(BUILD_DIR)/$(TARGET).z64 ELF := $(BUILD_DIR)/$(TARGET).elf LIBULTRA := $(BUILD_DIR)/libultra.a LD_SCRIPT := sm64.ld +CHARMAP := charmap.txt +CHARMAP_DEBUG := charmap.debug.txt MIO0_DIR := $(BUILD_DIR)/bin SOUND_BIN_DIR := $(BUILD_DIR)/sound TEXTURE_DIR := textures @@ -217,6 +236,10 @@ LEVEL_DIRS := $(patsubst levels/%,%,$(dir $(wildcard levels/*/header.h))) SRC_DIRS := src src/engine src/game src/audio src/menu src/buffers actors levels bin data assets asm lib sound BIN_DIRS := bin bin/$(VERSION) +ifeq ($(VERSION),cn) + LIBGCC_SRC_DIRS += lib/src/libgcc +endif + ULTRA_SRC_DIRS := lib/src lib/src/math lib/asm lib/data ULTRA_BIN_DIRS := lib/bin @@ -232,6 +255,7 @@ S_FILES := $(foreach dir,$(SRC_DIRS),$(wildcard $(dir)/*.s)) ULTRA_C_FILES := $(foreach dir,$(ULTRA_SRC_DIRS),$(wildcard $(dir)/*.c)) GODDARD_C_FILES := $(foreach dir,$(GODDARD_SRC_DIRS),$(wildcard $(dir)/*.c)) ULTRA_S_FILES := $(foreach dir,$(ULTRA_SRC_DIRS),$(wildcard $(dir)/*.s)) +LIBGCC_C_FILES := $(foreach dir,$(LIBGCC_SRC_DIRS),$(wildcard $(dir)/*.c)) GENERATED_C_FILES := $(BUILD_DIR)/assets/mario_anim_data.c $(BUILD_DIR)/assets/demo_data.c # Sound files @@ -240,7 +264,11 @@ SOUND_SAMPLE_DIRS := $(wildcard sound/samples/*) 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_AIFCS := $(foreach file,$(SOUND_SAMPLE_AIFFS),$(BUILD_DIR)/$(file:.aiff=.aifc)) -SOUND_SEQUENCE_DIRS := sound/sequences sound/sequences/$(VERSION) +ifeq ($(VERSION),cn) + SOUND_SEQUENCE_DIRS := sound/sequences sound/sequences/sh +else + SOUND_SEQUENCE_DIRS := sound/sequences sound/sequences/$(VERSION) +endif # all .m64 files in SOUND_SEQUENCE_DIRS, plus all .m64 files that are generated from .s files in SOUND_SEQUENCE_DIRS SOUND_SEQUENCE_FILES := \ $(foreach dir,$(SOUND_SEQUENCE_DIRS),\ @@ -258,16 +286,14 @@ ULTRA_O_FILES := $(foreach file,$(ULTRA_S_FILES),$(BUILD_DIR)/$(file:.s=.o)) \ GODDARD_O_FILES := $(foreach file,$(GODDARD_C_FILES),$(BUILD_DIR)/$(file:.c=.o)) +LIBGCC_O_FILES := $(foreach file,$(LIBGCC_C_FILES),$(BUILD_DIR)/$(file:.c=.o)) + # Automatic dependency files -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) $(LIBGCC_O_FILES:.o=.d) $(BUILD_DIR)/$(LD_SCRIPT).d # Files with GLOBAL_ASM blocks ifeq ($(NON_MATCHING),0) - ifeq ($(VERSION),sh) - GLOBAL_ASM_C_FILES != grep -rl 'GLOBAL_ASM(' $(wildcard src/**/*.c) $(wildcard lib/src/*.c) - else - GLOBAL_ASM_C_FILES != grep -rl 'GLOBAL_ASM(' $(wildcard src/**/*.c) - endif + 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_DEP = $(BUILD_DIR)/src/audio/non_matching_dep endif @@ -277,6 +303,9 @@ endif # Compiler Options # #==============================================================================# +IQUE_EGCS_PATH := $(TOOLS_DIR)/ique_egcs +IQUE_LD_PATH := $(TOOLS_DIR)/ique_ld + # detect prefix for MIPS toolchain ifneq ($(call find-command,mips-linux-gnu-ld),) CROSS := mips-linux-gnu- @@ -288,26 +317,30 @@ else $(error Unable to detect a suitable MIPS toolchain installed) endif -AS := $(CROSS)as +AS := $(CROSS)as ifeq ($(COMPILER),gcc) - CC := $(CROSS)gcc + CC := $(CROSS)gcc else ifeq ($(USE_QEMU_IRIX),1) IRIX_ROOT := $(TOOLS_DIR)/ido5.3_compiler - CC := $(QEMU_IRIX) -silent -L $(IRIX_ROOT) $(IRIX_ROOT)/usr/bin/cc - ACPP := $(QEMU_IRIX) -silent -L $(IRIX_ROOT) $(IRIX_ROOT)/usr/lib/acpp - COPT := $(QEMU_IRIX) -silent -L $(IRIX_ROOT) $(IRIX_ROOT)/usr/lib/copt + CC := $(QEMU_IRIX) -silent -L $(IRIX_ROOT) $(IRIX_ROOT)/usr/bin/cc + ACPP := $(QEMU_IRIX) -silent -L $(IRIX_ROOT) $(IRIX_ROOT)/usr/lib/acpp + COPT := $(QEMU_IRIX) -silent -L $(IRIX_ROOT) $(IRIX_ROOT)/usr/lib/copt else - IDO_ROOT := $(TOOLS_DIR)/ido5.3_recomp - CC := $(IDO_ROOT)/cc - ACPP := $(IDO_ROOT)/acpp - COPT := $(IDO_ROOT)/copt + IDO_ROOT := $(TOOLS_DIR)/ido-static-recomp/build/out + CC := $(IDO_ROOT)/cc + ACPP := $(IDO_ROOT)/acpp + COPT := $(IDO_ROOT)/copt endif endif -LD := $(CROSS)ld -AR := $(CROSS)ar -OBJDUMP := $(CROSS)objdump -OBJCOPY := $(CROSS)objcopy +ifeq ($(VERSION),cn) + LD := LD_LIBRARY_PATH=$(IQUE_LD_PATH) $(IQUE_LD_PATH)/mips64-elf-ld +else + LD := $(CROSS)ld +endif +AR := $(CROSS)ar +OBJDUMP := $(CROSS)objdump +OBJCOPY := $(CROSS)objcopy ifeq ($(TARGET_N64),1) TARGET_CFLAGS := -nostdinc -DTARGET_N64 -D_LANGUAGE_C @@ -322,13 +355,41 @@ endif C_DEFINES := $(foreach d,$(DEFINES),-D$(d)) DEF_INC_CFLAGS := $(foreach i,$(INCLUDE_DIRS),-I$(i)) $(C_DEFINES) +IQUE_AS := $(IQUE_EGCS_PATH)/as +IQUE_ASFLAGS = -mcpu=r4300 -mabi=32 $(MIPSISET) $(foreach i,$(INCLUDE_DIRS),-I$(i)) $(foreach d,$(DEFINES),--defsym $(d)) + +ifeq ($(VERSION),cn) + IQUE_REASSEMBLED_ASM_FILES := $(wildcard asm/*.s) $(wildcard lib/asm/*.s) + IQUE_REASSEMBLED_ASM_FILES := $(filter-out asm/ipl3_font.s,$(IQUE_REASSEMBLED_ASM_FILES)) + IQUE_REASSEMBLED := $(foreach file,$(IQUE_REASSEMBLED_ASM_FILES),$(BUILD_DIR)/$(file:.s=.o)) + $(IQUE_REASSEMBLED): AS := $(IQUE_AS) + $(IQUE_REASSEMBLED): MIPSISET := + $(IQUE_REASSEMBLED): ASFLAGS = $(IQUE_ASFLAGS) +endif + +IQUE_CC := COMPILER_PATH=$(IQUE_EGCS_PATH) $(IQUE_EGCS_PATH)/gcc +IQUE_CFLAGS = -G 0 $(TARGET_CFLAGS) $(OPT_FLAGS) -D__sgi -DBBPLAYER -mcpu=r4300 -mgp32 -fno-pic -Wa,--strip-local-absolute $(MIPSISET) $(DEF_INC_CFLAGS) + +# iQue recompiled some files with a different compiler +ifeq ($(VERSION),cn) + IQUE_RECOMPILED_SRC_GAME := $(addprefix $(BUILD_DIR)/src/game/,rumble_init.o level_update.o memory.o area.o print.o ingame_menu.o hud.o cn_common_syms_1.o cn_common_syms_2.o) $(addprefix $(BUILD_DIR)/src/menu/,title_screen.o intro_geo.o file_select.o star_select.o) + IQUE_RECOMPILED_LIB_SRC := $(ULTRA_O_FILES) + # osDriveRomInit is weird + IQUE_RECOMPILED_LIB_SRC := $(filter-out $(addprefix $(BUILD_DIR)/lib/src/,osDriveRomInit.o),$(IQUE_RECOMPILED_LIB_SRC)) + IQUE_RECOMPILED_LIBGCC_SRC := $(LIBGCC_O_FILES) + IQUE_RECOMPILED = $(IQUE_RECOMPILED_SRC_GAME) $(IQUE_RECOMPILED_LIB_SRC) $(IQUE_RECOMPILED_LIBGCC_SRC) + $(IQUE_RECOMPILED): CC := $(IQUE_CC) + $(IQUE_RECOMPILED): MIPSISET := + $(IQUE_RECOMPILED): CFLAGS = $(IQUE_CFLAGS) +endif + # Prefer clang as C preprocessor if installed on the system ifneq (,$(call find-command,clang)) CPP := clang - CPPFLAGS := -E -P -x c -Wno-trigraphs $(DEF_INC_CFLAGS) + CPPFLAGS := -E -P -x c -Wno-trigraphs -D_LANGUAGE_ASSEMBLY $(DEF_INC_CFLAGS) else CPP := cpp - CPPFLAGS := -P -Wno-trigraphs $(DEF_INC_CFLAGS) + CPPFLAGS := -P -Wno-trigraphs -D_LANGUAGE_ASSEMBLY $(DEF_INC_CFLAGS) endif # Check code syntax with host compiler @@ -343,7 +404,7 @@ else CFLAGS += -non_shared -Wab,-r4300_mul -Xcpluscomm -Xfullwarn -signed -32 endif -ASFLAGS := -march=vr4300 -mabi=32 $(foreach i,$(INCLUDE_DIRS),-I$(i)) $(foreach d,$(DEFINES),--defsym $(d)) +ASFLAGS := -march=vr4300 -mabi=32 $(foreach i,$(INCLUDE_DIRS),-I$(i)) $(foreach d,$(DEFINES),--defsym $(d)) RSPASMFLAGS := $(foreach d,$(DEFINES),-definelabel $(subst =, ,$(d))) ifeq ($(shell getconf LONG_BIT), 32) @@ -362,10 +423,10 @@ export LANG := C #==============================================================================# # N64 tools -MIO0TOOL := $(TOOLS_DIR)/mio0 -N64CKSUM := $(TOOLS_DIR)/n64cksum -N64GRAPHICS := $(TOOLS_DIR)/n64graphics -N64GRAPHICS_CI := $(TOOLS_DIR)/n64graphics_ci +MIO0TOOL := $(TOOLS_DIR)/sm64tools/mio0 +N64CKSUM := $(TOOLS_DIR)/sm64tools/n64cksum +N64GRAPHICS := $(TOOLS_DIR)/sm64tools/n64graphics +N64GRAPHICS_CI := $(TOOLS_DIR)/sm64tools/n64graphics_ci TEXTCONV := $(TOOLS_DIR)/textconv AIFF_EXTRACT_CODEBOOK := $(TOOLS_DIR)/aiff_extract_codebook VADPCM_ENC := $(TOOLS_DIR)/vadpcm_enc @@ -394,10 +455,13 @@ YELLOW := \033[0;33m BLINK := \033[33;5m endif -# Use Objcopy instead of extract_data_for_mio +# Use objcopy instead of extract_data_for_mio to get 16-byte aligned padding ifeq ($(COMPILER),gcc) EXTRACT_DATA_FOR_MIO := $(OBJCOPY) -O binary --only-section=.data endif +ifeq ($(VERSION),cn) + EXTRACT_DATA_FOR_MIO := $(OBJCOPY) -O binary --only-section=.data +endif # Common build print status function define print @@ -420,6 +484,7 @@ clean: distclean: clean $(PYTHON) extract_assets.py --clean $(MAKE) -C $(TOOLS_DIR) clean + $(MAKE) -C $(TOOLS_DIR)/sm64tools clean test: $(ROM) $(EMULATOR) $(EMU_FLAGS) $< @@ -430,13 +495,13 @@ load: $(ROM) libultra: $(BUILD_DIR)/libultra.a # Extra object file dependencies -$(BUILD_DIR)/asm/boot.o: $(IPL3_RAW_FILES) +$(BUILD_DIR)/asm/ipl3_font.o: $(IPL3_RAW_FILES) $(BUILD_DIR)/src/game/crash_screen.o: $(CRASH_TEXTURE_C_FILES) $(BUILD_DIR)/lib/rsp.o: $(BUILD_DIR)/rsp/rspboot.bin $(BUILD_DIR)/rsp/fast3d.bin $(BUILD_DIR)/rsp/audio.bin $(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 -ifeq ($(VERSION),sh) +ifeq ($(VERSION_SH_CN),true) $(BUILD_DIR)/src/audio/load_sh.o: $(SOUND_BIN_DIR)/bank_sets.inc.c $(SOUND_BIN_DIR)/sequences_header.inc.c $(SOUND_BIN_DIR)/ctl_header.inc.c $(SOUND_BIN_DIR)/tbl_header.inc.c endif @@ -468,8 +533,9 @@ else $(BUILD_DIR)/bin/segment2.o: $(BUILD_DIR)/text/$(VERSION)/define_text.inc.c endif endif +$(BUILD_DIR)/bin/segment2.o: $(BUILD_DIR)/text/debug_text.raw.inc.c -ALL_DIRS := $(BUILD_DIR) $(addprefix $(BUILD_DIR)/,$(SRC_DIRS) $(GODDARD_SRC_DIRS) $(ULTRA_SRC_DIRS) $(ULTRA_BIN_DIRS) $(BIN_DIRS) $(TEXTURE_DIRS) $(TEXT_DIRS) $(SOUND_SAMPLE_DIRS) $(addprefix levels/,$(LEVEL_DIRS)) rsp include) $(MIO0_DIR) $(addprefix $(MIO0_DIR)/,$(VERSION)) $(SOUND_BIN_DIR) $(SOUND_BIN_DIR)/sequences/$(VERSION) +ALL_DIRS := $(BUILD_DIR) $(addprefix $(BUILD_DIR)/,$(SRC_DIRS) $(GODDARD_SRC_DIRS) $(ULTRA_SRC_DIRS) $(ULTRA_BIN_DIRS) $(LIBGCC_SRC_DIRS) $(BIN_DIRS) $(TEXTURE_DIRS) $(TEXT_DIRS) $(SOUND_SAMPLE_DIRS) $(addprefix levels/,$(LEVEL_DIRS)) rsp include) $(MIO0_DIR) $(addprefix $(MIO0_DIR)/,$(VERSION)) $(SOUND_BIN_DIR) $(SOUND_BIN_DIR)/sequences/$(VERSION) # Make sure build directory exists before compiling anything DUMMY != mkdir -p $(ALL_DIRS) @@ -608,18 +674,27 @@ $(BUILD_DIR)/assets/demo_data.c: assets/demo_data.json $(wildcard assets/demos/* $(V)$(PYTHON) $(TOOLS_DIR)/demo_data_converter.py assets/demo_data.json $(DEF_INC_CFLAGS) > $@ # Encode in-game text strings -$(BUILD_DIR)/include/text_strings.h: include/text_strings.h.in +$(BUILD_DIR)/$(CHARMAP): $(CHARMAP) + $(call print,Preprocessing charmap:,$<,$@) + $(V)$(CPP) $(CPPFLAGS) -DBUILD_DIR=$(BUILD_DIR) -MMD -MP -MT $@ -MF $@.d -o $@ $< +$(BUILD_DIR)/$(CHARMAP_DEBUG): $(CHARMAP) + $(call print,Preprocessing charmap:,$<,$@) + $(V)$(CPP) $(CPPFLAGS) -DCHARMAP_DEBUG -DBUILD_DIR=$(BUILD_DIR) -MMD -MP -MT $@ -MF $@.d -o $@ $< +$(BUILD_DIR)/include/text_strings.h: include/text_strings.h.in $(BUILD_DIR)/$(CHARMAP) $(call print,Encoding:,$<,$@) - $(V)$(TEXTCONV) charmap.txt $< $@ + $(V)$(TEXTCONV) $(BUILD_DIR)/$(CHARMAP) $< $@ $(BUILD_DIR)/include/text_menu_strings.h: include/text_menu_strings.h.in $(call print,Encoding:,$<,$@) $(V)$(TEXTCONV) charmap_menu.txt $< $@ $(BUILD_DIR)/text/%/define_courses.inc.c: text/define_courses.inc.c text/%/courses.h @$(PRINT) "$(GREEN)Preprocessing: $(BLUE)$@ $(NO_COL)\n" - $(V)$(CPP) $(CPPFLAGS) $< -o - -I text/$*/ | $(TEXTCONV) charmap.txt - $@ + $(V)$(CPP) $(CPPFLAGS) $< -o - -I text/$*/ | $(TEXTCONV) $(BUILD_DIR)/$(CHARMAP) - $@ $(BUILD_DIR)/text/%/define_text.inc.c: text/define_text.inc.c text/%/courses.h text/%/dialogs.h @$(PRINT) "$(GREEN)Preprocessing: $(BLUE)$@ $(NO_COL)\n" - $(V)$(CPP) $(CPPFLAGS) $< -o - -I text/$*/ | $(TEXTCONV) charmap.txt - $@ + $(V)$(CPP) $(CPPFLAGS) $< -o - -I text/$*/ | $(TEXTCONV) $(BUILD_DIR)/$(CHARMAP) - $@ +$(BUILD_DIR)/text/debug_text.raw.inc.c: text/debug_text.inc.c $(BUILD_DIR)/$(CHARMAP_DEBUG) + @$(PRINT) "$(GREEN)Preprocessing: $(BLUE)$@ $(NO_COL)\n" + $(V)$(CPP) $(CPPFLAGS) $< -o - -I text/$*/ | $(TEXTCONV) $(BUILD_DIR)/$(CHARMAP_DEBUG) - $@ # Level headers $(BUILD_DIR)/include/level_headers.h: levels/level_headers.h.in @@ -645,12 +720,18 @@ $(GLOBAL_ASM_DEP).$(NON_MATCHING): # Compile C code $(BUILD_DIR)/%.o: %.c $(call print,Compiling:,$<,$@) - @$(CC_CHECK) $(CC_CHECK_CFLAGS) -MMD -MP -MT $@ -MF $(BUILD_DIR)/$*.d $< + $(V)$(CC_CHECK) $(CC_CHECK_CFLAGS) -MMD -MP -MT $@ -MF $(BUILD_DIR)/$*.d $< $(V)$(CC) -c $(CFLAGS) -o $@ $< +ifeq ($(VERSION),cn) + $(V)$(TOOLS_DIR)/patch_elf_32bit $@ +endif $(BUILD_DIR)/%.o: $(BUILD_DIR)/%.c $(call print,Compiling:,$<,$@) - @$(CC_CHECK) $(CC_CHECK_CFLAGS) -MMD -MP -MT $@ -MF $(BUILD_DIR)/$*.d $< + $(V)$(CC_CHECK) $(CC_CHECK_CFLAGS) -MMD -MP -MT $@ -MF $(BUILD_DIR)/$*.d $< $(V)$(CC) -c $(CFLAGS) -o $@ $< +ifeq ($(VERSION),cn) + $(V)$(TOOLS_DIR)/patch_elf_32bit $@ +endif # Alternate compiler flags needed for matching ifeq ($(COMPILER),ido) @@ -659,6 +740,8 @@ ifeq ($(COMPILER),ido) $(BUILD_DIR)/bin/%.o: OPT_FLAGS := -g $(BUILD_DIR)/src/goddard/%.o: OPT_FLAGS := -g $(BUILD_DIR)/src/goddard/%.o: MIPSISET := -mips1 + $(BUILD_DIR)/lib/asm/__osDisableInt.o: MIPSISET := -mips2 + $(BUILD_DIR)/lib/asm/bcopy.o: MIPSISET := -mips2 $(BUILD_DIR)/lib/src/%.o: OPT_FLAGS := $(BUILD_DIR)/lib/src/math/%.o: OPT_FLAGS := -O2 $(BUILD_DIR)/lib/src/math/ll%.o: OPT_FLAGS := @@ -667,14 +750,97 @@ ifeq ($(COMPILER),ido) $(BUILD_DIR)/lib/src/string.o: OPT_FLAGS := -O2 $(BUILD_DIR)/lib/src/gu%.o: OPT_FLAGS := -O3 $(BUILD_DIR)/lib/src/al%.o: OPT_FLAGS := -O3 - - ifeq ($(VERSION),sh) + ifeq ($(VERSION_SH_CN),true) $(BUILD_DIR)/lib/src/_Ldtob.o: OPT_FLAGS := -O3 $(BUILD_DIR)/lib/src/_Litob.o: OPT_FLAGS := -O3 $(BUILD_DIR)/lib/src/_Printf.o: OPT_FLAGS := -O3 $(BUILD_DIR)/lib/src/sprintf.o: OPT_FLAGS := -O3 $(BUILD_DIR)/lib/src/osDriveRomInit.o: OPT_FLAGS := -g endif + ifeq ($(VERSION),cn) + $(BUILD_DIR)/lib/src/osAiSetFrequency.o: MIPSISET := -mips2 + $(BUILD_DIR)/lib/src/osVirtualToPhysical.o: OPT_FLAGS := -mno-abicalls -mips2 + $(BUILD_DIR)/lib/src/osInitializeIQueWrapper.o: OPT_FLAGS := -O2 + $(BUILD_DIR)/lib/src/osAiGetLength.o: OPT_FLAGS := -O2 + $(BUILD_DIR)/lib/src/osAiSetFrequency.o: OPT_FLAGS := -O2 + $(BUILD_DIR)/lib/src/math/cosf.o: OPT_FLAGS := -O2 -mips2 + $(BUILD_DIR)/lib/src/guOrthoF.o: OPT_FLAGS := -O2 -mno-abicalls -mips2 + $(BUILD_DIR)/lib/src/guPerspectiveF.o: OPT_FLAGS := -O2 -mno-abicalls -mips2 + $(BUILD_DIR)/lib/src/osAiSetNextBuffer.o: OPT_FLAGS := -O2 -mno-abicalls -mips2 + $(BUILD_DIR)/lib/src/osContStartReadData.o: OPT_FLAGS := -O2 -mno-abicalls -mips2 + $(BUILD_DIR)/lib/src/osContInit.o: OPT_FLAGS := -O2 -mno-abicalls -mips2 + $(BUILD_DIR)/lib/src/math/sinf.o: OPT_FLAGS := -O2 -mips2 + $(BUILD_DIR)/lib/src/math/ll%.o: OPT_FLAGS := -mno-abicalls -mips2 + $(BUILD_DIR)/lib/src/string.o: OPT_FLAGS := -O2 -mips2 + $(BUILD_DIR)/lib/src/sprintf.o: OPT_FLAGS := -O2 -mno-abicalls -mips2 + $(BUILD_DIR)/lib/src/osSyncPrintf.o: OPT_FLAGS := -O2 + $(BUILD_DIR)/lib/src/_Printf.o: OPT_FLAGS := -O2 -mno-abicalls -mips2 + $(BUILD_DIR)/lib/src/osCreateMesgQueue.o: OPT_FLAGS := -mno-abicalls -mips2 + $(BUILD_DIR)/lib/src/osRecvMesg.o: OPT_FLAGS := -mno-abicalls -mips2 + $(BUILD_DIR)/lib/src/osSendMesg.o: OPT_FLAGS := -mno-abicalls -mips2 + $(BUILD_DIR)/lib/src/osSetEventMesg.o: OPT_FLAGS := -mno-abicalls -mips2 + $(BUILD_DIR)/lib/src/osSpTaskLoadGo.o: OPT_FLAGS := -O2 -mno-abicalls -mips2 + $(BUILD_DIR)/lib/src/osSpTaskYield.o: OPT_FLAGS := -O2 -mno-abicalls -mips2 + $(BUILD_DIR)/lib/src/osSpTaskYielded.o: OPT_FLAGS := -O2 -mno-abicalls -mips2 + $(BUILD_DIR)/lib/src/__osSiRawStartDma.o: OPT_FLAGS := -O2 -mno-abicalls -mips2 + $(BUILD_DIR)/lib/src/__osSiCreateAccessQueue.o: OPT_FLAGS := -O2 -mno-abicalls -mips2 + $(BUILD_DIR)/lib/src/osCreateThread.o: OPT_FLAGS := -mno-abicalls -mips2 + $(BUILD_DIR)/lib/src/osSetThreadPri.o: OPT_FLAGS := -mno-abicalls -mips2 + $(BUILD_DIR)/lib/src/osStartThread.o: OPT_FLAGS := -mno-abicalls -mips2 + $(BUILD_DIR)/lib/src/__osDequeueThread.o: OPT_FLAGS := -mno-abicalls -mips2 + $(BUILD_DIR)/lib/src/__osGetCurrFaultedThread.o: OPT_FLAGS := -mno-abicalls -mips2 + $(BUILD_DIR)/lib/src/osGetTime.o: OPT_FLAGS := -mno-abicalls -mips2 + $(BUILD_DIR)/lib/src/osSetTime.o: OPT_FLAGS := -mno-abicalls -mips2 + $(BUILD_DIR)/lib/src/osSetTimer.o: OPT_FLAGS := -mno-abicalls -mips2 + $(BUILD_DIR)/lib/src/osTimer.o: OPT_FLAGS := -mno-abicalls -mips2 + $(BUILD_DIR)/lib/src/osCreateViManager.o: OPT_FLAGS := -O2 -mno-abicalls -mips2 + $(BUILD_DIR)/lib/src/osViSetEvent.o: OPT_FLAGS := -O2 -mno-abicalls -mips2 + $(BUILD_DIR)/lib/src/osViSetMode.o: OPT_FLAGS := -O2 -mno-abicalls -mips2 + $(BUILD_DIR)/lib/src/osViSetSpecialFeatures.o: OPT_FLAGS := -O2 -mno-abicalls -mips2 + $(BUILD_DIR)/lib/src/osViSwapBuffer.o: OPT_FLAGS := -O2 -mno-abicalls -mips2 + $(BUILD_DIR)/lib/src/__osViSwapContext.o: OPT_FLAGS := -O2 -mno-abicalls -mips2 + $(BUILD_DIR)/lib/src/osViBlack.o: OPT_FLAGS := -O2 -mno-abicalls -mips2 + $(BUILD_DIR)/lib/src/guRotateF.o: OPT_FLAGS := -O2 -mno-abicalls -mips2 + $(BUILD_DIR)/lib/src/osEepromProbe.o: OPT_FLAGS := -O2 -mno-abicalls -mips2 + $(BUILD_DIR)/lib/src/osEepromLongWrite.o: OPT_FLAGS := -O2 -mno-abicalls -mips2 + $(BUILD_DIR)/lib/src/osEepromLongRead.o: OPT_FLAGS := -O2 -mno-abicalls -mips2 + $(BUILD_DIR)/lib/src/osCreatePiManager.o: OPT_FLAGS := -O2 -mno-abicalls -mips2 + $(BUILD_DIR)/lib/src/osEPiRawStartDma.o: OPT_FLAGS := -O2 -mno-abicalls -mips2 + $(BUILD_DIR)/lib/src/epidma.o: OPT_FLAGS := -O2 -mno-abicalls -mips2 + $(BUILD_DIR)/lib/src/osCartRomInit.o: OPT_FLAGS := -O2 -mno-abicalls -mips2 + $(BUILD_DIR)/lib/src/__osDevMgrMain.o: OPT_FLAGS := -O2 -mno-abicalls -mips2 + $(BUILD_DIR)/lib/src/__osPiCreateAccessQueue.o: OPT_FLAGS := -O2 -mno-abicalls -mips2 + $(BUILD_DIR)/lib/src/osPiStartDma.o: OPT_FLAGS := -O2 -mno-abicalls -mips2 + $(BUILD_DIR)/lib/src/motor.o: OPT_FLAGS := -O2 -mno-abicalls -mips2 + $(BUILD_DIR)/lib/src/osInitialize.o: OPT_FLAGS := -mno-abicalls -mips2 + $(BUILD_DIR)/lib/src/__osAiDeviceBusy.o: OPT_FLAGS := -O2 -mno-abicalls -mips2 + $(BUILD_DIR)/lib/src/_Litob.o: OPT_FLAGS := -O2 -mno-abicalls -mips2 + $(BUILD_DIR)/lib/src/_Ldtob.o: OPT_FLAGS := -O2 -mno-abicalls -mips2 + $(BUILD_DIR)/lib/src/osJamMesg.o: OPT_FLAGS := -mno-abicalls -mips2 + $(BUILD_DIR)/lib/src/__osSpDeviceBusy.o: OPT_FLAGS := -O2 -mno-abicalls -mips2 + $(BUILD_DIR)/lib/src/__osSpGetStatus.o: OPT_FLAGS := -O2 -mno-abicalls -mips2 + $(BUILD_DIR)/lib/src/__osSpSetStatus.o: OPT_FLAGS := -O2 -mno-abicalls -mips2 + $(BUILD_DIR)/lib/src/__osSpSetPc.o: OPT_FLAGS := -O2 -mno-abicalls -mips2 + $(BUILD_DIR)/lib/src/__osSpRawStartDma.o: OPT_FLAGS := -O2 -mno-abicalls -mips2 + $(BUILD_DIR)/lib/src/__osSiRawReadIo.o: OPT_FLAGS := -O2 -mno-abicalls -mips2 + $(BUILD_DIR)/lib/src/__osSiRawWriteIo.o: OPT_FLAGS := -O2 -mno-abicalls -mips2 + $(BUILD_DIR)/lib/src/osDestroyThread.o: OPT_FLAGS := -mno-abicalls -mips2 + $(BUILD_DIR)/lib/src/osGetThreadPri.o: OPT_FLAGS := -mno-abicalls -mips2 + $(BUILD_DIR)/lib/src/osYieldThread.o: OPT_FLAGS := -mno-abicalls -mips2 + $(BUILD_DIR)/lib/src/__osViInit.o: OPT_FLAGS := -O2 -mno-abicalls -mips2 + $(BUILD_DIR)/lib/src/__osViGetCurrentContext.o: OPT_FLAGS := -O2 -mno-abicalls -mips2 + $(BUILD_DIR)/lib/src/osEepromRead.o: OPT_FLAGS := -O2 -mno-abicalls -mips2 + $(BUILD_DIR)/lib/src/osEepromWrite.o: OPT_FLAGS := -O2 -mno-abicalls -mips2 + $(BUILD_DIR)/lib/src/__osSetGlobalIntMask.o: OPT_FLAGS := -mno-abicalls -mips2 + $(BUILD_DIR)/lib/src/__osResetGlobalIntMask.o: OPT_FLAGS := -mno-abicalls -mips2 + $(BUILD_DIR)/lib/src/osPiRawStartDma.o: OPT_FLAGS := -O2 -mno-abicalls -mips2 + $(BUILD_DIR)/lib/src/osPiGetCmdQueue.o: OPT_FLAGS := -O2 -mno-abicalls -mips2 + $(BUILD_DIR)/lib/src/osEPiRawReadIo.o: OPT_FLAGS := -O2 -mno-abicalls -mips2 + $(BUILD_DIR)/lib/src/osEPiRawWriteIo.o: OPT_FLAGS := -O2 -mno-abicalls -mips2 + $(BUILD_DIR)/lib/src/ldiv.o: OPT_FLAGS := -O2 -mno-abicalls -mips2 + $(BUILD_DIR)/lib/src/__osSiDeviceBusy.o: OPT_FLAGS := -O2 -mno-abicalls -mips2 + $(BUILD_DIR)/lib/src/libgcc/%.o: OPT_FLAGS := -O2 -g -mips2 + endif ifeq ($(VERSION),eu) $(BUILD_DIR)/lib/src/_Ldtob.o: OPT_FLAGS := -O3 $(BUILD_DIR)/lib/src/_Litob.o: OPT_FLAGS := -O3 @@ -733,16 +899,31 @@ $(BUILD_DIR)/libgoddard.a: $(GODDARD_O_FILES) @$(PRINT) "$(GREEN)Linking libgoddard: $(BLUE)$@ $(NO_COL)\n" $(V)$(AR) rcs -o $@ $(GODDARD_O_FILES) +# Link libgcc +$(BUILD_DIR)/libgcc.a: $(LIBGCC_O_FILES) + @$(PRINT) "$(GREEN)Linking libgcc: $(BLUE)$@ $(NO_COL)\n" + $(V)$(AR) rcs -o $@ $(LIBGCC_O_FILES) + # Link SM64 ELF file -$(ELF): $(O_FILES) $(MIO0_OBJ_FILES) $(SEG_FILES) $(BUILD_DIR)/$(LD_SCRIPT) undefined_syms.txt $(BUILD_DIR)/libultra.a $(BUILD_DIR)/libgoddard.a +$(ELF): $(O_FILES) $(MIO0_OBJ_FILES) $(SEG_FILES) $(BUILD_DIR)/$(LD_SCRIPT) undefined_syms.txt $(BUILD_DIR)/libultra.a $(BUILD_DIR)/libgoddard.a $(BUILD_DIR)/libgcc.a @$(PRINT) "$(GREEN)Linking ELF file: $(BLUE)$@ $(NO_COL)\n" - $(V)$(LD) -L $(BUILD_DIR) -T undefined_syms.txt -T $(BUILD_DIR)/$(LD_SCRIPT) -Map $(BUILD_DIR)/sm64.$(VERSION).map --no-check-sections $(addprefix -R ,$(SEG_FILES)) -o $@ $(O_FILES) -lultra -lgoddard + $(V)$(LD) -L $(BUILD_DIR) -T undefined_syms.txt -T $(BUILD_DIR)/$(LD_SCRIPT) -Map $(BUILD_DIR)/sm64.$(VERSION).map --no-check-sections $(addprefix -R ,$(SEG_FILES)) -o $@ $(O_FILES) -lultra -lgoddard -lgcc # Build ROM +ifeq ($(VERSION),cn) + PAD_TO_GAP_FILL := --pad-to=0x7B0000 --gap-fill=0x00 +else + PAD_TO_GAP_FILL := --pad-to=0x800000 --gap-fill=0xFF +endif + $(ROM): $(ELF) $(call print,Building ROM:,$<,$@) - $(V)$(OBJCOPY) --pad-to=0x800000 --gap-fill=0xFF $< $(@:.z64=.bin) -O binary +ifeq ($(VERSION),cn) # cn has no checksums + $(V)$(OBJCOPY) $(PAD_TO_GAP_FILL) $< $(@) -O binary +else + $(V)$(OBJCOPY) $(PAD_TO_GAP_FILL) $< $(@:.z64=.bin) -O binary $(V)$(N64CKSUM) $(@:.z64=.bin) $@ +endif $(BUILD_DIR)/$(TARGET).objdump: $(ELF) $(OBJDUMP) -D $< > $@ diff --git a/Makefile.split b/Makefile.split index 4aa49d82..35ae029c 100644 --- a/Makefile.split +++ b/Makefile.split @@ -178,6 +178,9 @@ $(eval $(call level_rules,menu,generic)) # Menu (File Select) # -------------------------------------- # Ending cake textures are generated in a special way +$(BUILD_DIR)/levels/ending/cake_cn.inc.c: levels/ending/cake_cn.png + $(call print,Splitting:,$<,$@) + $(V)$(SKYCONV) --type cake-cn --split $^ $(BUILD_DIR)/levels/ending $(BUILD_DIR)/levels/ending/cake_eu.inc.c: levels/ending/cake_eu.png $(call print,Splitting:,$<,$@) $(V)$(SKYCONV) --type cake-eu --split $^ $(BUILD_DIR)/levels/ending diff --git a/README.md b/README.md index aee71d4f..e708a8b8 100644 --- a/README.md +++ b/README.md @@ -1,6 +1,6 @@ # Super Mario 64 -- This repo contains a full decompilation of Super Mario 64 (J), (U), (E), and (SH). +- This repo contains a full decompilation of Super Mario 64 of the following releases: Japan (jp), North America (us), Europe (eu), Shindou (sh) and iQue Player (cn). - Naming and documentation of the source code and data structures are in progress. It builds the following ROMs: @@ -9,16 +9,17 @@ It builds the following ROMs: * sm64.us.z64 `sha1: 9bef1128717f958171a4afac3ed78ee2bb4e86ce` * sm64.eu.z64 `sha1: 4ac5721683d0e0b6bbb561b58a71740845dceea9` * sm64.sh.z64 `sha1: 3f319ae697533a255a1003d09202379d78d5a2e0` +* sm64.cn.z64 `sha1: 2e1db2780985a1f068077dc0444b685f39cd90ec` This repo does not include all assets necessary for compiling the ROMs. 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` +1. Install prerequisites: `sudo apt install -y binutils-mips-linux-gnu build-essential git pkgconf python3` 2. Clone the repo from within Linux: `git clone https://github.com/n64decomp/sm64.git` -3. Place a Super Mario 64 ROM called `baserom..z64` into the project folder for asset extraction, where `VERSION` can be `us`, `jp`, `eu`, or `sh`. -4. Run `make` to build. Qualify the version through `make VERSION=`. Add `-j4` to improve build speed (hardware dependent). +3. Place a Super Mario 64 ROM called `baserom..z64` into the project folder for asset extraction, where `VERSION` can be `jp`, `us`, `eu`, `sh`, or `cn`. +4. Run `make` to build. Specify the version through `make 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. @@ -44,7 +45,6 @@ There are 3 steps to set up a working build. The build system has the following package requirements: * binutils-mips - * capstone * pkgconf * python3 >= 3.6 @@ -53,18 +53,17 @@ Dependency installation instructions for common Linux distros are provided below ##### Debian / Ubuntu To install build dependencies: ``` -sudo apt install -y binutils-mips-linux-gnu build-essential git libcapstone-dev pkgconf python3 +sudo apt install -y binutils-mips-linux-gnu build-essential git pkgconf python3 ``` ##### Arch Linux To install build dependencies: ``` -sudo pacman -S base-devel capstone python +sudo pacman -S base-devel python ``` Install the following AUR packages: * [mips64-elf-binutils](https://aur.archlinux.org/packages/mips64-elf-binutils) (AUR) - ##### Other Linux distributions Most modern Linux distributions should have equivalent packages to the other two listed above. @@ -79,7 +78,7 @@ You may also use [Docker](#docker-installation) to handle installing an image wi #### Step 2: Copy baserom(s) for asset extraction -For each version (jp/us/eu/sh) for which you want to build a ROM, put an existing ROM at +For each version (jp/us/eu/sh/cn) for which you want to build a ROM, put an existing ROM at `./baserom..z64` for asset extraction. ##### Step 3: Build the ROM @@ -95,10 +94,10 @@ Resulting artifacts can be found in the `build` directory. The full list of configurable variables are listed below, with the default being the first listed: -* ``VERSION``: ``us``, ``jp``, ``eu``, ``sh`` +* ``VERSION``: ``jp``, ``us``, ``eu``, ``sh``, ``cn`` * ``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 (Currently there aren't any non-matchings, but this will apply to iQue). Also will avoid instances of undefined behavior. +* ``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-``). ### macOS @@ -111,12 +110,12 @@ With macOS, you may either use Homebrew or [Docker](#docker-installation). Install [Homebrew](https://brew.sh) and the following dependencies: ``` brew update -brew install capstone coreutils make pkg-config tehzz/n64-dev/mips64-elf-binutils +brew install coreutils make pkg-config tehzz/n64-dev/mips64-elf-binutils ``` #### Step 2: Copy baserom(s) for asset extraction -For each version (jp/us/eu/sh) for which you want to build a ROM, put an existing ROM at +For each version (jp/us/eu/sh/cn) for which you want to build a ROM, put an existing ROM at `./baserom..z64` for asset extraction. ##### Step 3: Build the ROM @@ -154,7 +153,7 @@ docker run --rm --mount type=bind,source="$(pwd)",destination=/sm64 --user $UID: Resulting artifacts can be found in the `build` directory. ## Project Structure - + sm64 ├── actors: object behaviors, geo layout, and display lists ├── asm: handwritten assembly code, rom header diff --git a/actors/amp/geo.inc.c b/actors/amp/geo.inc.c index 9c9e1d69..aa69edea 100644 --- a/actors/amp/geo.inc.c +++ b/actors/amp/geo.inc.c @@ -1,55 +1,55 @@ const GeoLayout dAmpGeo[] = { - GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0xC8, 100), - GEO_OPEN_NODE(), - GEO_SCALE(0x00, 16384), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_ALPHA, 0, 0, 0, dAmpEyeDl), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_SWITCH_CASE(2, geo_switch_anim_state), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_ANIMATED_PART(LAYER_ALPHA, 0, 0, 0, dAmpElectricityDl), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_SWITCH_CASE(2, geo_switch_anim_state), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_ANIMATED_PART(LAYER_ALPHA, 0, 0, 0, dAmpElectricityDl), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_SWITCH_CASE(2, geo_switch_anim_state), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_ANIMATED_PART(LAYER_ALPHA, 0, 0, 0, dAmpElectricityDl), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_SWITCH_CASE(2, geo_switch_anim_state), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_ANIMATED_PART(LAYER_ALPHA, 0, 0, 0, dAmpElectricityDl), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_ALPHA, 0, 0, 0, dAmpMouthDl), + GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0xC8, 100), + GEO_OPEN_NODE(), + GEO_SCALE(0x00, 16384), + GEO_OPEN_NODE(), GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), GEO_OPEN_NODE(), - GEO_BILLBOARD(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, dAmpBodyDl), - GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_ALPHA, 0, 0, 0, dAmpEyeDl), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_SWITCH_CASE(2, geo_switch_anim_state), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_ANIMATED_PART(LAYER_ALPHA, 0, 0, 0, dAmpElectricityDl), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_SWITCH_CASE(2, geo_switch_anim_state), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_ANIMATED_PART(LAYER_ALPHA, 0, 0, 0, dAmpElectricityDl), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_SWITCH_CASE(2, geo_switch_anim_state), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_ANIMATED_PART(LAYER_ALPHA, 0, 0, 0, dAmpElectricityDl), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_SWITCH_CASE(2, geo_switch_anim_state), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_ANIMATED_PART(LAYER_ALPHA, 0, 0, 0, dAmpElectricityDl), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_ALPHA, 0, 0, 0, dAmpMouthDl), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_BILLBOARD(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, dAmpBodyDl), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/actors/bird/geo.inc.c b/actors/bird/geo.inc.c index 92876442..45f1b7ed 100644 --- a/actors/bird/geo.inc.c +++ b/actors/bird/geo.inc.c @@ -1,25 +1,25 @@ // 0x0C000000 const GeoLayout birds_geo[] = { - GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0x96, 100), - GEO_OPEN_NODE(), - GEO_SCALE(0x00, 16384), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, birds_seg5_dl_05000670), + GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0x96, 100), + GEO_OPEN_NODE(), + GEO_SCALE(0x00, 16384), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 1, -12, 37, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, birds_seg5_dl_05000528), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 1, -12, -37, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, birds_seg5_dl_05000600), - GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, birds_seg5_dl_05000670), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 1, -12, 37, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, birds_seg5_dl_05000528), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 1, -12, -37, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, birds_seg5_dl_05000600), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, birds_seg5_dl_05000598), GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, birds_seg5_dl_05000598), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/actors/blargg/geo.inc.c b/actors/blargg/geo.inc.c index 3c161769..7ab5de9e 100644 --- a/actors/blargg/geo.inc.c +++ b/actors/blargg/geo.inc.c @@ -1,20 +1,20 @@ // 0x0C000240 const GeoLayout blargg_geo[] = { - GEO_SCALE(0x00, 16384), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, blargg_seg5_dl_05005D00), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 306, 0, 0, blargg_seg5_dl_05005A60), + GEO_SCALE(0x00, 16384), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, blargg_seg5_dl_05005D00), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 6, 3, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, blargg_seg5_dl_050058D0), - GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 306, 0, 0, blargg_seg5_dl_05005A60), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 6, 3, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, blargg_seg5_dl_050058D0), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/actors/blue_coin_switch/geo.inc.c b/actors/blue_coin_switch/geo.inc.c index cb0b96c0..6ef7a78d 100644 --- a/actors/blue_coin_switch/geo.inc.c +++ b/actors/blue_coin_switch/geo.inc.c @@ -1,10 +1,10 @@ // 0x0F000000 const GeoLayout blue_coin_switch_geo[] = { - GEO_CULLING_RADIUS(300), - GEO_OPEN_NODE(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, blue_coin_switch_seg8_dl_08000E08), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(300), + GEO_OPEN_NODE(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, blue_coin_switch_seg8_dl_08000E08), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/actors/blue_fish/geo.inc.c b/actors/blue_fish/geo.inc.c index d55c81a8..10e3cbfb 100644 --- a/actors/blue_fish/geo.inc.c +++ b/actors/blue_fish/geo.inc.c @@ -1,32 +1,32 @@ // 0x16000BEC const GeoLayout fish_shadow_geo[] = { - GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0x9B, 50), - GEO_OPEN_NODE(), - GEO_SCALE(0x00, 16384), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, -16, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, blue_fish_seg3_dl_0301BFB8), + GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0x9B, 50), + GEO_OPEN_NODE(), + GEO_SCALE(0x00, 16384), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, -16, 0, 0, NULL), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 97, 0, 0, blue_fish_seg3_dl_0301C150), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, blue_fish_seg3_dl_0301BFB8), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 97, 0, 0, blue_fish_seg3_dl_0301C150), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; // 0x16000C44 const GeoLayout fish_geo[] = { - GEO_SCALE(0x00, 16384), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, -16, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, blue_fish_seg3_dl_0301BFB8), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 97, 0, 0, blue_fish_seg3_dl_0301C150), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_SCALE(0x00, 16384), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, -16, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, blue_fish_seg3_dl_0301BFB8), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 97, 0, 0, blue_fish_seg3_dl_0301C150), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/actors/bobomb/geo.inc.c b/actors/bobomb/geo.inc.c index 4221dd39..d8e263e0 100644 --- a/actors/bobomb/geo.inc.c +++ b/actors/bobomb/geo.inc.c @@ -1,99 +1,99 @@ // 0x0F0007B8 const GeoLayout black_bobomb_geo[] = { - GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0xC8, 70), - GEO_OPEN_NODE(), - GEO_SCALE(0x00, 24576), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), + GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0xC8, 70), + GEO_OPEN_NODE(), + GEO_SCALE(0x00, 24576), + GEO_OPEN_NODE(), GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_BILLBOARD(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, bobomb_seg8_dl_08022D08), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 57, -60, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 91, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, bobomb_seg8_dl_08023270), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 55, 62, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 91, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, bobomb_seg8_dl_08023378), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, bobomb_seg8_dl_08023480), - GEO_SWITCH_CASE(2, geo_switch_anim_state), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_ALPHA, 0, 0, 0, bobomb_seg8_dl_08022B58), - GEO_ANIMATED_PART(LAYER_ALPHA, 0, 0, 0, bobomb_seg8_dl_08022B88), - GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_BILLBOARD(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, bobomb_seg8_dl_08022D08), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 57, -60, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 91, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, bobomb_seg8_dl_08023270), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 55, 62, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 91, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, bobomb_seg8_dl_08023378), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, bobomb_seg8_dl_08023480), + GEO_SWITCH_CASE(2, geo_switch_anim_state), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_ALPHA, 0, 0, 0, bobomb_seg8_dl_08022B58), + GEO_ANIMATED_PART(LAYER_ALPHA, 0, 0, 0, bobomb_seg8_dl_08022B88), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; // 0x0F0008F4 const GeoLayout bobomb_buddy_geo[] = { - GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0xC8, 70), - GEO_OPEN_NODE(), - GEO_SCALE(0x00, 24576), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), + GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0xC8, 70), + GEO_OPEN_NODE(), + GEO_SCALE(0x00, 24576), + GEO_OPEN_NODE(), GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_BILLBOARD(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, bobomb_seg8_dl_08022D78), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 57, -60, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 91, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, bobomb_seg8_dl_08023270), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 55, 62, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 91, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, bobomb_seg8_dl_08023378), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, bobomb_seg8_dl_08023480), - GEO_SWITCH_CASE(2, geo_switch_anim_state), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_ALPHA, 0, 0, 0, bobomb_seg8_dl_08022B58), - GEO_ANIMATED_PART(LAYER_ALPHA, 0, 0, 0, bobomb_seg8_dl_08022B88), - GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_BILLBOARD(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, bobomb_seg8_dl_08022D78), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 57, -60, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 91, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, bobomb_seg8_dl_08023270), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 55, 62, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 91, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, bobomb_seg8_dl_08023378), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, bobomb_seg8_dl_08023480), + GEO_SWITCH_CASE(2, geo_switch_anim_state), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_ALPHA, 0, 0, 0, bobomb_seg8_dl_08022B58), + GEO_ANIMATED_PART(LAYER_ALPHA, 0, 0, 0, bobomb_seg8_dl_08022B88), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/actors/bomb/geo.inc.c b/actors/bomb/geo.inc.c index d2deeea1..66a95e13 100644 --- a/actors/bomb/geo.inc.c +++ b/actors/bomb/geo.inc.c @@ -1,15 +1,15 @@ // 0x0D000B78 / 0BBC const GeoLayout bowser_bomb_geo[] = { - GEO_CULLING_RADIUS(1000), - GEO_OPEN_NODE(), - GEO_SCALE(0x00, 196608), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bomb_seg6_dl_0605A9C0), - GEO_BILLBOARD(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, bomb_seg6_dl_0605A830), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(1000), + GEO_OPEN_NODE(), + GEO_SCALE(0x00, 196608), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bomb_seg6_dl_0605A9C0), + GEO_BILLBOARD(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, bomb_seg6_dl_0605A830), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/actors/boo/geo.inc.c b/actors/boo/geo.inc.c index 4fa9721b..83af1d6b 100644 --- a/actors/boo/geo.inc.c +++ b/actors/boo/geo.inc.c @@ -1,17 +1,17 @@ // 0x0C000224 const GeoLayout boo_geo[] = { - GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0x96, 70), - GEO_OPEN_NODE(), - GEO_SCALE(0x00, 26214), - GEO_OPEN_NODE(), - GEO_ASM(0, geo_update_layer_transparency), - GEO_SWITCH_CASE(2, geo_switch_anim_state), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, boo_seg5_dl_0500C1B0), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, boo_seg5_dl_0500C1B0), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), -GEO_CLOSE_NODE(), //! more close than open nodes -GEO_END(), + GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0x96, 70), + GEO_OPEN_NODE(), + GEO_SCALE(0x00, 26214), + GEO_OPEN_NODE(), + GEO_ASM(0, geo_update_layer_transparency), + GEO_SWITCH_CASE(2, geo_switch_anim_state), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, boo_seg5_dl_0500C1B0), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, boo_seg5_dl_0500C1B0), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), //! more close than open nodes + GEO_END(), }; diff --git a/actors/boo_castle/geo.inc.c b/actors/boo_castle/geo.inc.c index 1b3ee4f3..bafbf35b 100644 --- a/actors/boo_castle/geo.inc.c +++ b/actors/boo_castle/geo.inc.c @@ -1,17 +1,17 @@ // 0x0D0005B0 const GeoLayout boo_castle_geo[] = { - GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0x96, 70), - GEO_OPEN_NODE(), - GEO_SCALE(0x00, 26214), - GEO_OPEN_NODE(), - GEO_ASM(0, geo_update_layer_transparency), - GEO_SWITCH_CASE(2, geo_switch_anim_state), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, boo_castle_seg6_dl_06017CE0), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, boo_castle_seg6_dl_06017CE0), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), -GEO_CLOSE_NODE(), //! more close than open nodes -GEO_END(), + GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0x96, 70), + GEO_OPEN_NODE(), + GEO_SCALE(0x00, 26214), + GEO_OPEN_NODE(), + GEO_ASM(0, geo_update_layer_transparency), + GEO_SWITCH_CASE(2, geo_switch_anim_state), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, boo_castle_seg6_dl_06017CE0), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, boo_castle_seg6_dl_06017CE0), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), //! more close than open nodes + GEO_END(), }; diff --git a/actors/book/geo.inc.c b/actors/book/geo.inc.c index d6cf4402..f371ec7c 100644 --- a/actors/book/geo.inc.c +++ b/actors/book/geo.inc.c @@ -1,8 +1,8 @@ // 0x0C0000C0 const GeoLayout bookend_geo[] = { - GEO_CULLING_RADIUS(300), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, book_seg5_dl_05002FB0), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(300), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, book_seg5_dl_05002FB0), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/actors/bookend/geo.inc.c b/actors/bookend/geo.inc.c index b5629c8d..4e857322 100644 --- a/actors/bookend/geo.inc.c +++ b/actors/bookend/geo.inc.c @@ -1,29 +1,29 @@ // 0x0C000000 const GeoLayout bookend_part_geo[] = { - GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0x96, 100), - GEO_OPEN_NODE(), - GEO_SCALE(0x00, 16384), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), + GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0x96, 100), + GEO_OPEN_NODE(), + GEO_SCALE(0x00, 16384), + GEO_OPEN_NODE(), GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, bookend_seg5_dl_05001F98), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, bookend_seg5_dl_05001B20), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, bookend_seg5_dl_05002140), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, bookend_seg5_dl_05001F98), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, bookend_seg5_dl_05001B20), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, bookend_seg5_dl_05002140), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, bookend_seg5_dl_05001D68), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, bookend_seg5_dl_05001978), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, bookend_seg5_dl_050022E0), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, bookend_seg5_dl_05001D68), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, bookend_seg5_dl_05001978), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, bookend_seg5_dl_050022E0), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), -GEO_CLOSE_NODE(), //! more close than open nodes -GEO_END(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), //! more close than open nodes + GEO_END(), }; diff --git a/actors/bowling_ball/geo.inc.c b/actors/bowling_ball/geo.inc.c index 884afead..6ab0fc93 100644 --- a/actors/bowling_ball/geo.inc.c +++ b/actors/bowling_ball/geo.inc.c @@ -4,24 +4,24 @@ // 0x0F000640 const GeoLayout bowling_ball_geo[] = { - GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0xC8, 280), - GEO_OPEN_NODE(), - GEO_SCALE(0x00, 170393), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, bobomb_seg8_dl_08022D08), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0xC8, 280), + GEO_OPEN_NODE(), + GEO_SCALE(0x00, 170393), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, bobomb_seg8_dl_08022D08), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; // 0x0F00066C const GeoLayout bowling_ball_track_geo[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_SCALE(0x00, 170393), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, bobomb_seg8_dl_08022D08), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_SCALE(0x00, 170393), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, bobomb_seg8_dl_08022D08), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/actors/bowser/flames_data.inc.c b/actors/bowser/flames_data.inc.c index 1ba334ab..23e3a075 100644 --- a/actors/bowser/flames_data.inc.c +++ b/actors/bowser/flames_data.inc.c @@ -2,97 +2,97 @@ const s16 dBowserFlamesOrientationValues[] = { // posX, posY, posZ, rotY, rotX - 0, 280, 80, 0x00E9, 0x1A96, - 0, 278, 83, 0x00EC, 0x1C7F, - 0, 273, 92, 0x00F9, 0x20BF, - 0, 268, 102, 0x010F, 0x2519, - 0, 263, 109, 0x011D, 0x2751, - 0, 263, 110, 0x011C, 0x2714, - 0, 265, 106, 0x0112, 0x2601, - 0, 268, 102, 0x0109, 0x24C0, - 0, 271, 96, 0x00FF, 0x2358, - 0, 274, 90, 0x00F7, 0x21CB, - 0, 277, 84, 0x00EE, 0x201C, - 0, 280, 78, 0x00E7, 0x1E4E, - 0, 284, 71, 0x00DF, 0x1C64, - 0, 288, 63, 0x00D9, 0x1A61, - 0, 291, 56, 0x00D3, 0x184B, - 0, 295, 48, 0x00CF, 0x1622, - 0, 298, 40, 0x00CA, 0x13E9, - 0, 301, 32, 0x00C7, 0x11A5, - 0, 304, 23, 0x00C4, 0x0F59, - 0, 308, 15, 0x00C1, 0x0D08, - 0, 311, 7, 0x00C0, 0x0AB5, - 0, 313, 0, 0x00C0, 0x0863, - 0, 315, -8, 0x00BF, 0x0615, - 0, 317, -15, 0x00CE, 0x03A3, - 0, 319, -22, 0x00F8, 0x00ED, - 0, 320, -29, 0x0131, 0xFFFF, - 0, 322, -36, 0x0172, 0xFFFF, - 0, 322, -40, 0x01B5, 0xFFFF, - 0, 323, -45, 0x01ED, 0xFFFF, - 0, 323, -48, 0x0213, 0xFFFF, - 0, 323, -51, 0x0219, 0xFFFF, - 0, 323, -52, 0x01F2, 0xFFFF, - 0, 323, -51, 0x018F, 0xFFFF, - 0, 323, -49, 0x00E5, 0xFFFF, - 0, 322, -45, 0xFFFF, 0xFFFF, - 0, 320, -35, 0xFFFF, 0xFFFF, - 0, 317, -23, 0xFFFF, 0xFFFF, - 0, 312, -7, 0xFFFF, 0xFFFF, - 0, 306, 11, 0xFFFF, 0xFFFF, - 0, 299, 31, 0xFFFF, 0xFFFF, - 0, 288, 51, 0xFFFF, 0xFFFF, - 0, 278, 70, 0xFFFF, 0xFFFF, - 0, 267, 89, 0xFFFF, 0xFFFF, - 0, 256, 106, 0xFFFF, 0x023A, - 0, 244, 120, 0xFFFF, 0x04AA, - 0, 236, 132, 0xFFFF, 0x069F, - 0, 229, 139, 0xFFFF, 0x0803, - 0, 224, 144, 0xFFFF, 0x08C0, - 0, 222, 147, 0xFFFF, 0x0928, - 0, 221, 148, 0xFFFF, 0x099D, - 0, 221, 149, 0xFFFF, 0x0A16, - 0, 221, 150, 0xFFFF, 0x0A8D, - 0, 221, 150, 0xFFFF, 0x0AF6, - 0, 222, 150, 0xFFFF, 0x0B4A, - 0, 222, 150, 0xFFFF, 0x0B84, - 0, 222, 149, 0x020A, 0x0BA0, - 0, 223, 149, 0x0524, 0x0B9E, - 0, 225, 148, 0x07EC, 0x0B84, - 0, 226, 147, 0x0A3F, 0x0B57, - 0, 227, 145, 0x0BFB, 0x0B1F, - 0, 228, 144, 0x0D00, 0x0AE5, - 0, 230, 142, 0x0D6F, 0x0AA0, - 0, 232, 140, 0x0D8B, 0x0A48, - 0, 233, 138, 0x0D5D, 0x09DE, - 0, 236, 136, 0x0CED, 0x096A, - 0, 238, 134, 0x0C49, 0x08EA, - 0, 239, 132, 0x0B76, 0x0863, - 0, 241, 130, 0x0A80, 0x07D9, - 0, 244, 128, 0x0970, 0x074E, - 0, 246, 125, 0x084E, 0x06C7, - 0, 248, 122, 0x0723, 0x0649, - 0, 251, 120, 0x05F8, 0x05D7, - 0, 253, 117, 0x04D6, 0x0579, - 0, 254, 114, 0x03C3, 0x0532, - 0, 256, 111, 0x02C9, 0x0509, - 0, 259, 108, 0x01F0, 0x0504, - 0, 261, 105, 0x0141, 0x0525, - 0, 262, 103, 0x00C3, 0x0572, - 0, 264, 100, 0x006E, 0x0619, - 0, 267, 97, 0x0032, 0x0734, - 0, 268, 95, 0x000C, 0x08AF, - 0, 269, 93, 0xFFFF, 0x0A74, - 0, 272, 90, 0xFFFF, 0x0C70, - 0, 273, 88, 0xFFFF, 0x0E8E, - 0, 274, 86, 0x0014, 0x10B6, - 0, 275, 84, 0x0032, 0x12DA, - 0, 277, 82, 0x0056, 0x14E1, - 0, 277, 82, 0x007E, 0x16B9, - 0, 278, 80, 0x00A4, 0x184B, - 0, 278, 80, 0x00C6, 0x1983, - 0, 279, 80, 0x00DF, 0x1A4D, - 0, 280, 80, 0x00E9, 0x1A96, + 0, 280, 80, 0x00E9, 0x1A96, + 0, 278, 83, 0x00EC, 0x1C7F, + 0, 273, 92, 0x00F9, 0x20BF, + 0, 268, 102, 0x010F, 0x2519, + 0, 263, 109, 0x011D, 0x2751, + 0, 263, 110, 0x011C, 0x2714, + 0, 265, 106, 0x0112, 0x2601, + 0, 268, 102, 0x0109, 0x24C0, + 0, 271, 96, 0x00FF, 0x2358, + 0, 274, 90, 0x00F7, 0x21CB, + 0, 277, 84, 0x00EE, 0x201C, + 0, 280, 78, 0x00E7, 0x1E4E, + 0, 284, 71, 0x00DF, 0x1C64, + 0, 288, 63, 0x00D9, 0x1A61, + 0, 291, 56, 0x00D3, 0x184B, + 0, 295, 48, 0x00CF, 0x1622, + 0, 298, 40, 0x00CA, 0x13E9, + 0, 301, 32, 0x00C7, 0x11A5, + 0, 304, 23, 0x00C4, 0x0F59, + 0, 308, 15, 0x00C1, 0x0D08, + 0, 311, 7, 0x00C0, 0x0AB5, + 0, 313, 0, 0x00C0, 0x0863, + 0, 315, -8, 0x00BF, 0x0615, + 0, 317, -15, 0x00CE, 0x03A3, + 0, 319, -22, 0x00F8, 0x00ED, + 0, 320, -29, 0x0131, 0xFFFF, + 0, 322, -36, 0x0172, 0xFFFF, + 0, 322, -40, 0x01B5, 0xFFFF, + 0, 323, -45, 0x01ED, 0xFFFF, + 0, 323, -48, 0x0213, 0xFFFF, + 0, 323, -51, 0x0219, 0xFFFF, + 0, 323, -52, 0x01F2, 0xFFFF, + 0, 323, -51, 0x018F, 0xFFFF, + 0, 323, -49, 0x00E5, 0xFFFF, + 0, 322, -45, 0xFFFF, 0xFFFF, + 0, 320, -35, 0xFFFF, 0xFFFF, + 0, 317, -23, 0xFFFF, 0xFFFF, + 0, 312, -7, 0xFFFF, 0xFFFF, + 0, 306, 11, 0xFFFF, 0xFFFF, + 0, 299, 31, 0xFFFF, 0xFFFF, + 0, 288, 51, 0xFFFF, 0xFFFF, + 0, 278, 70, 0xFFFF, 0xFFFF, + 0, 267, 89, 0xFFFF, 0xFFFF, + 0, 256, 106, 0xFFFF, 0x023A, + 0, 244, 120, 0xFFFF, 0x04AA, + 0, 236, 132, 0xFFFF, 0x069F, + 0, 229, 139, 0xFFFF, 0x0803, + 0, 224, 144, 0xFFFF, 0x08C0, + 0, 222, 147, 0xFFFF, 0x0928, + 0, 221, 148, 0xFFFF, 0x099D, + 0, 221, 149, 0xFFFF, 0x0A16, + 0, 221, 150, 0xFFFF, 0x0A8D, + 0, 221, 150, 0xFFFF, 0x0AF6, + 0, 222, 150, 0xFFFF, 0x0B4A, + 0, 222, 150, 0xFFFF, 0x0B84, + 0, 222, 149, 0x020A, 0x0BA0, + 0, 223, 149, 0x0524, 0x0B9E, + 0, 225, 148, 0x07EC, 0x0B84, + 0, 226, 147, 0x0A3F, 0x0B57, + 0, 227, 145, 0x0BFB, 0x0B1F, + 0, 228, 144, 0x0D00, 0x0AE5, + 0, 230, 142, 0x0D6F, 0x0AA0, + 0, 232, 140, 0x0D8B, 0x0A48, + 0, 233, 138, 0x0D5D, 0x09DE, + 0, 236, 136, 0x0CED, 0x096A, + 0, 238, 134, 0x0C49, 0x08EA, + 0, 239, 132, 0x0B76, 0x0863, + 0, 241, 130, 0x0A80, 0x07D9, + 0, 244, 128, 0x0970, 0x074E, + 0, 246, 125, 0x084E, 0x06C7, + 0, 248, 122, 0x0723, 0x0649, + 0, 251, 120, 0x05F8, 0x05D7, + 0, 253, 117, 0x04D6, 0x0579, + 0, 254, 114, 0x03C3, 0x0532, + 0, 256, 111, 0x02C9, 0x0509, + 0, 259, 108, 0x01F0, 0x0504, + 0, 261, 105, 0x0141, 0x0525, + 0, 262, 103, 0x00C3, 0x0572, + 0, 264, 100, 0x006E, 0x0619, + 0, 267, 97, 0x0032, 0x0734, + 0, 268, 95, 0x000C, 0x08AF, + 0, 269, 93, 0xFFFF, 0x0A74, + 0, 272, 90, 0xFFFF, 0x0C70, + 0, 273, 88, 0xFFFF, 0x0E8E, + 0, 274, 86, 0x0014, 0x10B6, + 0, 275, 84, 0x0032, 0x12DA, + 0, 277, 82, 0x0056, 0x14E1, + 0, 277, 82, 0x007E, 0x16B9, + 0, 278, 80, 0x00A4, 0x184B, + 0, 278, 80, 0x00C6, 0x1983, + 0, 279, 80, 0x00DF, 0x1A4D, + 0, 280, 80, 0x00E9, 0x1A96, 0, 0, 0, 0x0000, 0x0000, }; diff --git a/actors/bowser/geo.inc.c b/actors/bowser/geo.inc.c index b59e23a6..0bbb5972 100644 --- a/actors/bowser/geo.inc.c +++ b/actors/bowser/geo.inc.c @@ -1,419 +1,419 @@ // 0x0D0000D8 const GeoLayout bowser_geo_0000D8[] = { - GEO_SHADOW(SHADOW_CIRCLE_9_VERTS, 0x9B, 400), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, bowser_seg6_dl_06040210), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, -89, -2, -18, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_SHADOW(SHADOW_CIRCLE_9_VERTS, 0x9B, 400), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, bowser_seg6_dl_06040210), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, -89, -2, -18, NULL), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 69, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 85, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, bowser_seg6_dl_0603D200), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, bowser_seg6_dl_0603E6B8), - GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 69, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 85, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, bowser_seg6_dl_0603D200), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, bowser_seg6_dl_0603E6B8), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, -32, -112, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, -32, -112, NULL), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, bowser_seg6_dl_06043698), - GEO_ASM(0, geo_update_body_rot_from_parent), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, bowser_seg6_dl_06043698), + GEO_ASM(0, geo_update_body_rot_from_parent), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 118, 67, 105, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_ANIMATED_PART(LAYER_OPAQUE, 118, 67, 105, NULL), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 65, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 49, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, bowser_seg6_dl_0603B208), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, bowser_seg6_dl_060399D8), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, bowser_seg6_dl_060392E0), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 65, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 49, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, bowser_seg6_dl_0603B208), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, bowser_seg6_dl_060399D8), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, bowser_seg6_dl_060392E0), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 136, 130, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 136, 130, NULL), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 61, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, -13, 258, 0, bowser_seg6_dl_060431F0), - GEO_CLOSE_NODE(), - GEO_SWITCH_CASE(9, geo_switch_bowser_eyes), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, bowser_seg6_dl_06042348), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, bowser_seg6_dl_060423A0), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, bowser_seg6_dl_060423F8), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, bowser_seg6_dl_06042450), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, bowser_seg6_dl_060424A8), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, bowser_seg6_dl_06042500), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, bowser_seg6_dl_06042558), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, bowser_seg6_dl_060425B0), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, bowser_seg6_dl_06042608), - GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 61, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, -13, 258, 0, bowser_seg6_dl_060431F0), + GEO_CLOSE_NODE(), + GEO_SWITCH_CASE(9, geo_switch_bowser_eyes), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, bowser_seg6_dl_06042348), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, bowser_seg6_dl_060423A0), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, bowser_seg6_dl_060423F8), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, bowser_seg6_dl_06042450), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, bowser_seg6_dl_060424A8), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, bowser_seg6_dl_06042500), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, bowser_seg6_dl_06042558), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, bowser_seg6_dl_060425B0), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, bowser_seg6_dl_06042608), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, -118, 67, 105, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_ANIMATED_PART(LAYER_OPAQUE, -118, 67, 105, NULL), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 65, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 49, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, bowser_seg6_dl_0603DFB0), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, bowser_seg6_dl_0603C6D0), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, bowser_seg6_dl_0603BFC8), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 65, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 49, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, bowser_seg6_dl_0603DFB0), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, bowser_seg6_dl_0603C6D0), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, bowser_seg6_dl_0603BFC8), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 89, -2, -18, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_ANIMATED_PART(LAYER_OPAQUE, 89, -2, -18, NULL), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 69, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 85, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, bowser_seg6_dl_0603A4E8), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, bowser_seg6_dl_0603B8D0), - GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 69, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 85, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, bowser_seg6_dl_0603A4E8), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, bowser_seg6_dl_0603B8D0), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x0D000424 const GeoLayout bowser_geo_000424[] = { - GEO_SHADOW(SHADOW_CIRCLE_9_VERTS, 0x9B, 400), - GEO_OPEN_NODE(), + GEO_SHADOW(SHADOW_CIRCLE_9_VERTS, 0x9B, 400), + GEO_OPEN_NODE(), #if BUGFIX_BOWSER_FADING_OUT - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, bowser_seg6_dl_06040358), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, bowser_seg6_dl_06040358), #else - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, bowser_seg6_dl_06040210), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, bowser_seg6_dl_06040210), #endif - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, -89, -2, -18, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, -89, -2, -18, NULL), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 69, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 85, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, bowser_seg6_dl_0603D200), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, bowser_seg6_dl_0603E6B8), - GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 69, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 85, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, bowser_seg6_dl_0603D200), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, bowser_seg6_dl_0603E6B8), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, -32, -112, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, NULL), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, -32, -112, NULL), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, bowser_seg6_dl_06043698), - GEO_ASM(0, geo_update_body_rot_from_parent), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, bowser_seg6_dl_06043698), + GEO_ASM(0, geo_update_body_rot_from_parent), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 118, 67, 105, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, NULL), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 118, 67, 105, NULL), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 65, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 49, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, bowser_seg6_dl_0603B208), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, bowser_seg6_dl_060399D8), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, bowser_seg6_dl_060392E0), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 65, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 49, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, bowser_seg6_dl_0603B208), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, bowser_seg6_dl_060399D8), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, bowser_seg6_dl_060392E0), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 136, 130, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, NULL), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 136, 130, NULL), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 61, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, -13, 258, 0, bowser_seg6_dl_060431F0), - GEO_CLOSE_NODE(), - GEO_SWITCH_CASE(9, geo_switch_bowser_eyes), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, bowser_seg6_dl_06042348), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, bowser_seg6_dl_060423A0), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, bowser_seg6_dl_060423F8), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, bowser_seg6_dl_06042450), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, bowser_seg6_dl_060424A8), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, bowser_seg6_dl_06042500), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, bowser_seg6_dl_06042558), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, bowser_seg6_dl_060425B0), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, bowser_seg6_dl_06042608), - GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 61, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, -13, 258, 0, bowser_seg6_dl_060431F0), + GEO_CLOSE_NODE(), + GEO_SWITCH_CASE(9, geo_switch_bowser_eyes), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, bowser_seg6_dl_06042348), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, bowser_seg6_dl_060423A0), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, bowser_seg6_dl_060423F8), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, bowser_seg6_dl_06042450), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, bowser_seg6_dl_060424A8), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, bowser_seg6_dl_06042500), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, bowser_seg6_dl_06042558), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, bowser_seg6_dl_060425B0), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, bowser_seg6_dl_06042608), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, -118, 67, 105, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, NULL), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, -118, 67, 105, NULL), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 65, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 49, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, bowser_seg6_dl_0603DFB0), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, bowser_seg6_dl_0603C6D0), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, bowser_seg6_dl_0603BFC8), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 65, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 49, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, bowser_seg6_dl_0603DFB0), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, bowser_seg6_dl_0603C6D0), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, bowser_seg6_dl_0603BFC8), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 89, -2, -18, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, NULL), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 89, -2, -18, NULL), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 69, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 85, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, bowser_seg6_dl_0603A4E8), - GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 69, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 85, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, bowser_seg6_dl_0603A4E8), + GEO_CLOSE_NODE(), #if BUGFIX_BOWSER_FADING_OUT - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, bowser_seg6_dl_0603B948), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, bowser_seg6_dl_0603B948), #else - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, bowser_seg6_dl_0603B8D0), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, bowser_seg6_dl_0603B8D0), #endif - GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, NULL), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, NULL), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, NULL), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, NULL), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, NULL), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, NULL), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, NULL), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, NULL), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, NULL), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, NULL), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, NULL), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, NULL), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, NULL), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, NULL), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, NULL), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, NULL), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, NULL), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, NULL), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x0D000770 const GeoLayout bowser_geo_000770[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), + GEO_NODE_START(), + GEO_OPEN_NODE(), #if BUGFIX_BOWSER_FADING_OUT - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, bowser_seg6_dl_06040358), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, bowser_seg6_dl_06040358), #else - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, bowser_seg6_dl_06040210), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, bowser_seg6_dl_06040210), #endif - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, -89, -2, -18, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, -89, -2, -18, NULL), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 69, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 85, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, bowser_seg6_dl_0603D200), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, bowser_seg6_dl_0603E6B8), - GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 69, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 85, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, bowser_seg6_dl_0603D200), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, bowser_seg6_dl_0603E6B8), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, -32, -112, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, NULL), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, -32, -112, NULL), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, bowser_seg6_dl_06043698), - GEO_ASM(0, geo_update_body_rot_from_parent), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, bowser_seg6_dl_06043698), + GEO_ASM(0, geo_update_body_rot_from_parent), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 118, 67, 105, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, NULL), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 118, 67, 105, NULL), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 65, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 49, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, bowser_seg6_dl_0603B208), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, bowser_seg6_dl_060399D8), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, bowser_seg6_dl_060392E0), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 65, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 49, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, bowser_seg6_dl_0603B208), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, bowser_seg6_dl_060399D8), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, bowser_seg6_dl_060392E0), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 136, 130, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, NULL), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 136, 130, NULL), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 61, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, -13, 258, 0, bowser_seg6_dl_060431F0), - GEO_CLOSE_NODE(), - GEO_SWITCH_CASE(9, geo_switch_bowser_eyes), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, bowser_seg6_dl_06042348), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, bowser_seg6_dl_060423A0), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, bowser_seg6_dl_060423F8), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, bowser_seg6_dl_06042450), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, bowser_seg6_dl_060424A8), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, bowser_seg6_dl_06042500), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, bowser_seg6_dl_06042558), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, bowser_seg6_dl_060425B0), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, bowser_seg6_dl_06042608), - GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 61, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, -13, 258, 0, bowser_seg6_dl_060431F0), + GEO_CLOSE_NODE(), + GEO_SWITCH_CASE(9, geo_switch_bowser_eyes), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, bowser_seg6_dl_06042348), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, bowser_seg6_dl_060423A0), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, bowser_seg6_dl_060423F8), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, bowser_seg6_dl_06042450), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, bowser_seg6_dl_060424A8), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, bowser_seg6_dl_06042500), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, bowser_seg6_dl_06042558), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, bowser_seg6_dl_060425B0), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, bowser_seg6_dl_06042608), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, -118, 67, 105, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, NULL), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, -118, 67, 105, NULL), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 65, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 49, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, bowser_seg6_dl_0603DFB0), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, bowser_seg6_dl_0603C6D0), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, bowser_seg6_dl_0603BFC8), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 65, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 49, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, bowser_seg6_dl_0603DFB0), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, bowser_seg6_dl_0603C6D0), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, bowser_seg6_dl_0603BFC8), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 89, -2, -18, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, NULL), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 89, -2, -18, NULL), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 69, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 85, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, bowser_seg6_dl_0603A4E8), - GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 69, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 85, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, bowser_seg6_dl_0603A4E8), + GEO_CLOSE_NODE(), #if BUGFIX_BOWSER_FADING_OUT - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, bowser_seg6_dl_0603B948), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, bowser_seg6_dl_0603B948), #else - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, bowser_seg6_dl_0603B8D0), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, bowser_seg6_dl_0603B8D0), #endif - GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, NULL), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, NULL), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, NULL), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, NULL), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, NULL), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, NULL), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, NULL), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, NULL), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, NULL), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, NULL), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, NULL), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, NULL), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, NULL), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, NULL), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, NULL), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, NULL), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, NULL), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, NULL), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; #ifndef VERSION_JP // 0x0D000AB8 const GeoLayout bowser_shadow_geo[] = { - GEO_SHADOW(SHADOW_CIRCLE_9_VERTS, 0x9B, 400), - GEO_RETURN(), + GEO_SHADOW(SHADOW_CIRCLE_9_VERTS, 0x9B, 400), + GEO_RETURN(), }; #endif // 0x0D000AB8 / 0AC4 const GeoLayout bowser_geo[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_ASM(0, geo_update_layer_transparency), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_ASM(0, geo_update_layer_transparency), #ifndef VERSION_JP - GEO_SWITCH_CASE(3, geo_switch_anim_state), + GEO_SWITCH_CASE(3, geo_switch_anim_state), #else - GEO_SWITCH_CASE(2, geo_switch_anim_state), + GEO_SWITCH_CASE(2, geo_switch_anim_state), #endif - GEO_OPEN_NODE(), - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_ASM(0, geo_bits_bowser_coloring), - GEO_BRANCH(1, bowser_geo_0000D8), - GEO_CLOSE_NODE(), + GEO_OPEN_NODE(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_ASM(0, geo_bits_bowser_coloring), + GEO_BRANCH(1, bowser_geo_0000D8), + GEO_CLOSE_NODE(), - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_ASM(0, geo_bits_bowser_coloring), - GEO_BRANCH(1, bowser_geo_000424), - GEO_CLOSE_NODE(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_ASM(0, geo_bits_bowser_coloring), + GEO_BRANCH(1, bowser_geo_000424), + GEO_CLOSE_NODE(), #ifndef VERSION_JP - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_ASM(0, geo_bits_bowser_coloring), - GEO_BRANCH(1, bowser_shadow_geo), - GEO_CLOSE_NODE(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_ASM(0, geo_bits_bowser_coloring), + GEO_BRANCH(1, bowser_shadow_geo), + GEO_CLOSE_NODE(), #endif - GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CLOSE_NODE(), + GEO_END(), }; // 0x0D000B18 / 0B40 const GeoLayout bowser_geo_no_shadow[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_ASM(0, geo_update_layer_transparency), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_ASM(0, geo_update_layer_transparency), #ifndef VERSION_JP - GEO_SWITCH_CASE(3, geo_switch_anim_state), + GEO_SWITCH_CASE(3, geo_switch_anim_state), #else - GEO_SWITCH_CASE(2, geo_switch_anim_state), + GEO_SWITCH_CASE(2, geo_switch_anim_state), #endif - GEO_OPEN_NODE(), - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_ASM(0, geo_bits_bowser_coloring), - GEO_BRANCH(1, bowser_geo_0000D8), - GEO_CLOSE_NODE(), + GEO_OPEN_NODE(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_ASM(0, geo_bits_bowser_coloring), + GEO_BRANCH(1, bowser_geo_0000D8), + GEO_CLOSE_NODE(), - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_ASM(0, geo_bits_bowser_coloring), - GEO_BRANCH(1, bowser_geo_000770), - GEO_CLOSE_NODE(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_ASM(0, geo_bits_bowser_coloring), + GEO_BRANCH(1, bowser_geo_000770), + GEO_CLOSE_NODE(), #ifndef VERSION_JP - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_ASM(0, geo_bits_bowser_coloring), - GEO_BRANCH(1, bowser_shadow_geo), - GEO_CLOSE_NODE(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_ASM(0, geo_bits_bowser_coloring), + GEO_BRANCH(1, bowser_shadow_geo), + GEO_CLOSE_NODE(), #endif - GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/actors/bowser_flame/geo.inc.c b/actors/bowser_flame/geo.inc.c index c4f0be6b..b936d875 100644 --- a/actors/bowser_flame/geo.inc.c +++ b/actors/bowser_flame/geo.inc.c @@ -1,24 +1,24 @@ // 0x0D000000 const GeoLayout bowser_flames_geo[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_SWITCH_CASE(14, geo_switch_anim_state), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, flame_seg6_dl_0601C108), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, flame_seg6_dl_0601C1A8), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, flame_seg6_dl_0601C248), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, flame_seg6_dl_0601C2E8), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, flame_seg6_dl_0601C388), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, flame_seg6_dl_0601C428), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, flame_seg6_dl_0601C4C8), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, flame_seg6_dl_0601C568), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, flame_seg6_dl_0601C608), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, flame_seg6_dl_0601C6A8), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, flame_seg6_dl_0601C748), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, flame_seg6_dl_0601C7E8), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, flame_seg6_dl_0601C888), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, flame_seg6_dl_0601C928), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_SWITCH_CASE(14, geo_switch_anim_state), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, flame_seg6_dl_0601C108), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, flame_seg6_dl_0601C1A8), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, flame_seg6_dl_0601C248), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, flame_seg6_dl_0601C2E8), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, flame_seg6_dl_0601C388), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, flame_seg6_dl_0601C428), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, flame_seg6_dl_0601C4C8), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, flame_seg6_dl_0601C568), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, flame_seg6_dl_0601C608), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, flame_seg6_dl_0601C6A8), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, flame_seg6_dl_0601C748), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, flame_seg6_dl_0601C7E8), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, flame_seg6_dl_0601C888), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, flame_seg6_dl_0601C928), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/actors/bowser_key/geo.inc.c b/actors/bowser_key/geo.inc.c index d7e2a85f..83379a30 100644 --- a/actors/bowser_key/geo.inc.c +++ b/actors/bowser_key/geo.inc.c @@ -1,31 +1,31 @@ // 0x16000A84 const GeoLayout bowser_key_geo[] = { - GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0x9B, 300), - GEO_OPEN_NODE(), - GEO_SCALE(0x00, 65536), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bowser_key_dl), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0x9B, 300), + GEO_OPEN_NODE(), + GEO_SCALE(0x00, 65536), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bowser_key_dl), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; // 0x16000AB0 const GeoLayout bowser_key_cutscene_geo[] = { - GEO_SCALE(0x00, 16384), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ASM(0, geo_scale_bowser_key), - GEO_SCALE(0x00, 65536), + GEO_SCALE(0x00, 16384), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bowser_key_dl), + GEO_ASM(0, geo_scale_bowser_key), + GEO_SCALE(0x00, 65536), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bowser_key_dl), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), -GEO_CLOSE_NODE(), //! more close than open nodes -GEO_END(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), //! more close than open nodes + GEO_END(), }; diff --git a/actors/breakable_box/geo.inc.c b/actors/breakable_box/geo.inc.c index 0a610e27..6c7fb151 100644 --- a/actors/breakable_box/geo.inc.c +++ b/actors/breakable_box/geo.inc.c @@ -1,28 +1,28 @@ // 0x0F0005D0 const GeoLayout breakable_box_geo[] = { - GEO_CULLING_RADIUS(500), - GEO_OPEN_NODE(), - GEO_SHADOW(SHADOW_SQUARE_PERMANENT, 0xB4, 240), - GEO_OPEN_NODE(), - GEO_SWITCH_CASE(2, geo_switch_anim_state), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, breakable_box_seg8_dl_08012D20), - GEO_DISPLAY_LIST(LAYER_OPAQUE, breakable_box_seg8_dl_08012D48), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(500), + GEO_OPEN_NODE(), + GEO_SHADOW(SHADOW_SQUARE_PERMANENT, 0xB4, 240), + GEO_OPEN_NODE(), + GEO_SWITCH_CASE(2, geo_switch_anim_state), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, breakable_box_seg8_dl_08012D20), + GEO_DISPLAY_LIST(LAYER_OPAQUE, breakable_box_seg8_dl_08012D48), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; // 0x0F000610 const GeoLayout breakable_box_small_geo[] = { - GEO_CULLING_RADIUS(500), - GEO_OPEN_NODE(), - GEO_SWITCH_CASE(2, geo_switch_anim_state), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, breakable_box_seg8_dl_08012D20), - GEO_DISPLAY_LIST(LAYER_OPAQUE, breakable_box_seg8_dl_08012D48), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(500), + GEO_OPEN_NODE(), + GEO_SWITCH_CASE(2, geo_switch_anim_state), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, breakable_box_seg8_dl_08012D20), + GEO_DISPLAY_LIST(LAYER_OPAQUE, breakable_box_seg8_dl_08012D48), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/actors/bub/geo.inc.c b/actors/bub/geo.inc.c index 7fe1b86c..f768f1c3 100644 --- a/actors/bub/geo.inc.c +++ b/actors/bub/geo.inc.c @@ -1,22 +1,22 @@ // 0x0D00038C const GeoLayout bub_geo[] = { - GEO_SCALE(0x00, 16384), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, -13, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, bub_seg6_dl_06011B28), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 135, 0, 0, bub_seg6_dl_06011CF0), - GEO_ANIMATED_PART(LAYER_OPAQUE, -33, -86, -35, NULL), + GEO_SCALE(0x00, 16384), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, -13, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, bub_seg6_dl_06011B28), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, bub_seg6_dl_06011E48), + GEO_ANIMATED_PART(LAYER_OPAQUE, 135, 0, 0, bub_seg6_dl_06011CF0), + GEO_ANIMATED_PART(LAYER_OPAQUE, -33, -86, -35, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, bub_seg6_dl_06011E48), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, -34, 71, -36, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, bub_seg6_dl_06011FA0), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, -34, 71, -36, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, bub_seg6_dl_06011FA0), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/actors/bubba/geo.inc.c b/actors/bubba/geo.inc.c index 39e13b94..5c13278d 100644 --- a/actors/bubba/geo.inc.c +++ b/actors/bubba/geo.inc.c @@ -1,12 +1,12 @@ // 0x0C000000 const GeoLayout bubba_geo[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_SWITCH_CASE(2, geo_switch_anim_state), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bubba_seg5_dl_05004E80), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bubba_seg5_dl_05005978), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_SWITCH_CASE(2, geo_switch_anim_state), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bubba_seg5_dl_05004E80), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bubba_seg5_dl_05005978), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/actors/bubble/geo.inc.c b/actors/bubble/geo.inc.c index 60dc9be2..e9e48165 100644 --- a/actors/bubble/geo.inc.c +++ b/actors/bubble/geo.inc.c @@ -1,17 +1,17 @@ // 0x17000000 const GeoLayout bubble_geo[] = { - GEO_SWITCH_CASE(1, geo_switch_anim_state), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, bubble_seg4_dl_0401DD60), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_SWITCH_CASE(1, geo_switch_anim_state), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, bubble_seg4_dl_0401DD60), + GEO_CLOSE_NODE(), + GEO_END(), }; // 0x1700001C const GeoLayout purple_marble_geo[] = { - GEO_SWITCH_CASE(1, geo_switch_anim_state), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, bubble_seg4_dl_0401DDE0), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_SWITCH_CASE(1, geo_switch_anim_state), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, bubble_seg4_dl_0401DDE0), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/actors/bullet_bill/geo.inc.c b/actors/bullet_bill/geo.inc.c index db6d9894..d30c1e24 100644 --- a/actors/bullet_bill/geo.inc.c +++ b/actors/bullet_bill/geo.inc.c @@ -1,11 +1,11 @@ // 0x0C000264 const GeoLayout bullet_bill_geo[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_SHADOW(SHADOW_SQUARE_PERMANENT, 0x96, 400), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bullet_bill_seg5_dl_0500E8A8), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_SHADOW(SHADOW_SQUARE_PERMANENT, 0x96, 400), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bullet_bill_seg5_dl_0500E8A8), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/actors/bully/geo.inc.c b/actors/bully/geo.inc.c index 5bb0142f..2ac3472d 100644 --- a/actors/bully/geo.inc.c +++ b/actors/bully/geo.inc.c @@ -1,91 +1,91 @@ // 0x0C000000 const GeoLayout bully_geo[] = { - GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0xC8, 70), - GEO_OPEN_NODE(), - GEO_SCALE(0x00, 24576), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), + GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0xC8, 70), + GEO_OPEN_NODE(), + GEO_SCALE(0x00, 24576), + GEO_OPEN_NODE(), GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 75, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 146, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, bully_seg5_dl_05003708), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, -75, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 146, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, bully_seg5_dl_050037A0), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_BILLBOARD(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, bully_seg5_dl_05003D40), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, bully_seg5_dl_05000398), - GEO_ANIMATED_PART(LAYER_ALPHA, 0, 0, 0, bully_seg5_dl_05003FC8), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 75, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 146, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, bully_seg5_dl_05003708), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, -75, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 146, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, bully_seg5_dl_050037A0), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_BILLBOARD(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, bully_seg5_dl_05003D40), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, bully_seg5_dl_05000398), + GEO_ANIMATED_PART(LAYER_ALPHA, 0, 0, 0, bully_seg5_dl_05003FC8), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; // 0x0C000120 const GeoLayout bully_boss_geo[] = { - GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0xC8, 210), - GEO_OPEN_NODE(), - GEO_SCALE(0x00, 49152), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), + GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0xC8, 210), + GEO_OPEN_NODE(), + GEO_SCALE(0x00, 49152), + GEO_OPEN_NODE(), GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 75, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 146, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, bully_seg5_dl_05003708), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, -75, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 146, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, bully_seg5_dl_050037A0), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_BILLBOARD(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, bully_seg5_dl_05003EA8), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, bully_seg5_dl_05000398), - GEO_ANIMATED_PART(LAYER_ALPHA, 0, 0, 0, bully_seg5_dl_05003FC8), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 75, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 146, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, bully_seg5_dl_05003708), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, -75, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 146, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, bully_seg5_dl_050037A0), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_BILLBOARD(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, bully_seg5_dl_05003EA8), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, bully_seg5_dl_05000398), + GEO_ANIMATED_PART(LAYER_ALPHA, 0, 0, 0, bully_seg5_dl_05003FC8), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/actors/burn_smoke/geo.inc.c b/actors/burn_smoke/geo.inc.c index 61cb4796..eb34c176 100644 --- a/actors/burn_smoke/geo.inc.c +++ b/actors/burn_smoke/geo.inc.c @@ -1,8 +1,8 @@ // 0x17000084 const GeoLayout burn_smoke_geo[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, burn_smoke_seg4_dl_04022070), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, burn_smoke_seg4_dl_04022070), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/actors/butterfly/geo.inc.c b/actors/butterfly/geo.inc.c index ccaedd5d..5e34127d 100644 --- a/actors/butterfly/geo.inc.c +++ b/actors/butterfly/geo.inc.c @@ -1,26 +1,26 @@ // 0x160000A8 const GeoLayout butterfly_geo[] = { - GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0xB4, 25), - GEO_OPEN_NODE(), - GEO_SCALE(0x00, 16384), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_ALPHA, 0, 0, 0, butterfly_seg3_dl_03005408), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_OPEN_NODE(), + GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0xB4, 25), + GEO_OPEN_NODE(), + GEO_SCALE(0x00, 16384), + GEO_OPEN_NODE(), GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_ALPHA, 0, 0, 0, butterfly_seg3_dl_030054A0), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_ALPHA, 0, 0, 0, butterfly_seg3_dl_03005408), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_ALPHA, 0, 0, 0, butterfly_seg3_dl_030054A0), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/actors/cannon_barrel/geo.inc.c b/actors/cannon_barrel/geo.inc.c index 862ed9e5..2f151a68 100644 --- a/actors/cannon_barrel/geo.inc.c +++ b/actors/cannon_barrel/geo.inc.c @@ -1,8 +1,8 @@ // 0x0F0001C0 const GeoLayout cannon_barrel_geo[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, cannon_barrel_seg8_dl_08006660), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, cannon_barrel_seg8_dl_08006660), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/actors/cannon_base/geo.inc.c b/actors/cannon_base/geo.inc.c index a7ea3320..67074474 100644 --- a/actors/cannon_base/geo.inc.c +++ b/actors/cannon_base/geo.inc.c @@ -1,8 +1,8 @@ // 0x0F0001A8 const GeoLayout cannon_base_geo[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, cannon_base_seg8_dl_080057F8), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, cannon_base_seg8_dl_080057F8), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/actors/capswitch/geo.inc.c b/actors/capswitch/geo.inc.c index 3ab43b99..d124cd70 100644 --- a/actors/capswitch/geo.inc.c +++ b/actors/capswitch/geo.inc.c @@ -1,15 +1,15 @@ // 0x0C000048 const GeoLayout cap_switch_geo[] = { - GEO_CULLING_RADIUS(600), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT_DECAL, cap_switch_exclamation_seg5_dl_05002E00), - GEO_SWITCH_CASE(4, geo_switch_anim_state), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, capswitch_seg5_dl_05003350), - GEO_DISPLAY_LIST(LAYER_OPAQUE, capswitch_seg5_dl_05003370), - GEO_DISPLAY_LIST(LAYER_OPAQUE, capswitch_seg5_dl_05003390), - GEO_DISPLAY_LIST(LAYER_OPAQUE, capswitch_seg5_dl_050033B0), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(600), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT_DECAL, cap_switch_exclamation_seg5_dl_05002E00), + GEO_SWITCH_CASE(4, geo_switch_anim_state), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, capswitch_seg5_dl_05003350), + GEO_DISPLAY_LIST(LAYER_OPAQUE, capswitch_seg5_dl_05003370), + GEO_DISPLAY_LIST(LAYER_OPAQUE, capswitch_seg5_dl_05003390), + GEO_DISPLAY_LIST(LAYER_OPAQUE, capswitch_seg5_dl_050033B0), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/actors/chain_ball/geo.inc.c b/actors/chain_ball/geo.inc.c index d97fdf6f..383852e9 100644 --- a/actors/chain_ball/geo.inc.c +++ b/actors/chain_ball/geo.inc.c @@ -1,8 +1,8 @@ // 0x0D0005D0 const GeoLayout metallic_ball_geo[] = { - GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0x96, 60), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, chain_ball_seg6_dl_060212E8), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0x96, 60), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, chain_ball_seg6_dl_060212E8), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/actors/chain_chomp/geo.inc.c b/actors/chain_chomp/geo.inc.c index ad336773..decfbe76 100644 --- a/actors/chain_chomp/geo.inc.c +++ b/actors/chain_chomp/geo.inc.c @@ -1,22 +1,22 @@ // 0x0D0005EC const GeoLayout chain_chomp_geo[] = { - GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0x96, 200), - GEO_OPEN_NODE(), - GEO_SCALE(0x00, 16384), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, chain_chomp_seg6_dl_06024940), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, chain_chomp_seg6_dl_06024FC0), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, chain_chomp_seg6_dl_06024240), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, chain_chomp_seg6_dl_06024D60), - GEO_ANIMATED_PART(LAYER_ALPHA, 0, 0, 0, chain_chomp_seg6_dl_06024B00), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), -GEO_CLOSE_NODE(), //! more close than open nodes -GEO_END(), + GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0x96, 200), + GEO_OPEN_NODE(), + GEO_SCALE(0x00, 16384), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, chain_chomp_seg6_dl_06024940), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, chain_chomp_seg6_dl_06024FC0), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, chain_chomp_seg6_dl_06024240), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, chain_chomp_seg6_dl_06024D60), + GEO_ANIMATED_PART(LAYER_ALPHA, 0, 0, 0, chain_chomp_seg6_dl_06024B00), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), //! more close than open nodes + GEO_END(), }; diff --git a/actors/chair/geo.inc.c b/actors/chair/geo.inc.c index eb963a7e..28879b83 100644 --- a/actors/chair/geo.inc.c +++ b/actors/chair/geo.inc.c @@ -1,29 +1,29 @@ // 0x0C0000D8 const GeoLayout haunted_chair_geo[] = { - GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0x96, 100), - GEO_OPEN_NODE(), - GEO_SCALE(0x00, 16384), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, chair_seg5_dl_05005190), + GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0x96, 100), + GEO_OPEN_NODE(), + GEO_SCALE(0x00, 16384), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, -7, -9, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, chair_seg5_dl_05005680), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 156, -9, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, chair_seg5_dl_05005408), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, -3, 17, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, chair_seg5_dl_05004EE8), - GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, chair_seg5_dl_05005190), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, -7, -9, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, chair_seg5_dl_05005680), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 156, -9, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, chair_seg5_dl_05005408), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, -3, 17, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, chair_seg5_dl_05004EE8), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), -GEO_CLOSE_NODE(), //! more close than open nodes -GEO_END(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), //! more close than open nodes + GEO_END(), }; diff --git a/actors/checkerboard_platform/geo.inc.c b/actors/checkerboard_platform/geo.inc.c index 7e139ca7..947c3111 100644 --- a/actors/checkerboard_platform/geo.inc.c +++ b/actors/checkerboard_platform/geo.inc.c @@ -1,8 +1,8 @@ // 0x0F0004E4 const GeoLayout checkerboard_platform_geo[] = { - GEO_CULLING_RADIUS(400), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, checkerboard_platform_seg8_dl_0800D680), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(400), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, checkerboard_platform_seg8_dl_0800D680), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/actors/chillychief/geo.inc.c b/actors/chillychief/geo.inc.c index 96ec2e1c..a13a8045 100644 --- a/actors/chillychief/geo.inc.c +++ b/actors/chillychief/geo.inc.c @@ -1,92 +1,92 @@ // Why are these scripts compressed unlike the other ones? // 0x06003754 const GeoLayout chilly_chief_geo[] = { - GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0xC8, 0x46), - GEO_OPEN_NODE(), - GEO_SCALE(0, 0x7333), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(1, 0, 0, 0, NULL), - GEO_OPEN_NODE(), + GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0xC8, 0x46), + GEO_OPEN_NODE(), + GEO_SCALE(0, 0x7333), + GEO_OPEN_NODE(), GEO_ANIMATED_PART(1, 0, 0, 0, NULL), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(1, 0, 0, 75, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(1, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(1, 146, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(1, 0, 0, 0, chilly_chief_seg6_dl_06002B30), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(1, 0, 0, -75, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(1, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(1, 146, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(1, 0, 0, 0, chilly_chief_seg6_dl_06002BC8), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(1, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_BILLBOARD(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, chilly_chief_seg6_dl_06002D88), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(1, 0, 0, 0, chilly_chief_seg6_dl_06002C60), - GEO_ANIMATED_PART(4, 0, 0, 0, chilly_chief_seg6_dl_06003010), + GEO_ANIMATED_PART(1, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(1, 0, 0, 75, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(1, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(1, 146, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(1, 0, 0, 0, chilly_chief_seg6_dl_06002B30), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(1, 0, 0, -75, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(1, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(1, 146, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(1, 0, 0, 0, chilly_chief_seg6_dl_06002BC8), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(1, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_BILLBOARD(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, chilly_chief_seg6_dl_06002D88), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(1, 0, 0, 0, chilly_chief_seg6_dl_06002C60), + GEO_ANIMATED_PART(4, 0, 0, 0, chilly_chief_seg6_dl_06003010), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; // 0x06003874 const GeoLayout chilly_chief_big_geo[] = { - GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0xC8, 0xD2), - GEO_OPEN_NODE(), - GEO_SCALE(0, 0xE666), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(1, 0, 0, 0, NULL), - GEO_OPEN_NODE(), + GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0xC8, 0xD2), + GEO_OPEN_NODE(), + GEO_SCALE(0, 0xE666), + GEO_OPEN_NODE(), GEO_ANIMATED_PART(1, 0, 0, 0, NULL), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(1, 0, 0, 75, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(1, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(1, 146, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(1, 0, 0, 0, chilly_chief_seg6_dl_06002B30), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(1, 0, 0, -75, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(1, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(1, 146, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(1, 0, 0, 0, chilly_chief_seg6_dl_06002BC8), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(1, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_BILLBOARD(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, chilly_chief_seg6_dl_06002EF0), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(1, 0, 0, 0, chilly_chief_seg6_dl_06002C60), - GEO_ANIMATED_PART(4, 0, 0, 0, chilly_chief_seg6_dl_06003010), + GEO_ANIMATED_PART(1, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(1, 0, 0, 75, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(1, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(1, 146, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(1, 0, 0, 0, chilly_chief_seg6_dl_06002B30), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(1, 0, 0, -75, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(1, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(1, 146, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(1, 0, 0, 0, chilly_chief_seg6_dl_06002BC8), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(1, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_BILLBOARD(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, chilly_chief_seg6_dl_06002EF0), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(1, 0, 0, 0, chilly_chief_seg6_dl_06002C60), + GEO_ANIMATED_PART(4, 0, 0, 0, chilly_chief_seg6_dl_06003010), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/actors/chuckya/geo.inc.c b/actors/chuckya/geo.inc.c index 902693c1..4802cf81 100644 --- a/actors/chuckya/geo.inc.c +++ b/actors/chuckya/geo.inc.c @@ -1,117 +1,117 @@ // 0x0F0001D8 const GeoLayout chuckya_geo[] = { - GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0x96, 100), - GEO_OPEN_NODE(), - GEO_SCALE(0x00, 16384), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), + GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0x96, 100), + GEO_OPEN_NODE(), + GEO_SCALE(0x00, 16384), + GEO_OPEN_NODE(), GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 281, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, chuckya_seg8_dl_0800ABE8), - GEO_ANIMATED_PART(LAYER_OPAQUE, 113, -152, 0, NULL), - GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 281, 0, 0, NULL), + GEO_OPEN_NODE(), GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 74, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 96, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_BILLBOARD(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, chuckya_seg8_dl_0800ABE8), + GEO_ANIMATED_PART(LAYER_OPAQUE, 113, -152, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 74, 0, 0, NULL), GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, chuckya_seg8_dl_0800A5F8), + GEO_ANIMATED_PART(LAYER_OPAQUE, 96, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_BILLBOARD(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, chuckya_seg8_dl_0800A5F8), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, chuckya_seg8_dl_0800A998), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_ALPHA, 0, 0, 0, chuckya_seg8_dl_0800A758), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_BILLBOARD(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, chuckya_seg8_dl_0800A068), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 1, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 209, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_BILLBOARD(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, chuckya_seg8_dl_0800A1D0), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 95, 0, 0, NULL), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, chuckya_seg8_dl_0800A998), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_ALPHA, 0, 0, 0, chuckya_seg8_dl_0800A758), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_BILLBOARD(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, chuckya_seg8_dl_0800A068), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 1, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 209, 0, 0, NULL), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_BILLBOARD(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, chuckya_seg8_dl_0800A428), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_BILLBOARD(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, chuckya_seg8_dl_0800A1D0), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 95, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_BILLBOARD(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, chuckya_seg8_dl_0800A428), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 1, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 209, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_BILLBOARD(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, chuckya_seg8_dl_0800A338), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 95, 0, 0, NULL), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 1, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 209, 0, 0, NULL), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_BILLBOARD(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, chuckya_seg8_dl_0800A510), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ASM(0, geo_update_held_mario_pos), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_BILLBOARD(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, chuckya_seg8_dl_0800A338), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 95, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_BILLBOARD(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, chuckya_seg8_dl_0800A510), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ASM(0, geo_update_held_mario_pos), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, chuckya_seg8_dl_0800A8D0), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, chuckya_seg8_dl_0800A8D0), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/actors/clam_shell/geo.inc.c b/actors/clam_shell/geo.inc.c index f8b652f9..f7720088 100644 --- a/actors/clam_shell/geo.inc.c +++ b/actors/clam_shell/geo.inc.c @@ -1,20 +1,20 @@ // 0x0C000000 const GeoLayout clam_shell_geo[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_SCALE(0x00, 16384), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, clam_shell_seg5_dl_05001568), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_SCALE(0x00, 16384), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, -520, -6, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, clam_shell_seg5_dl_050012B8), - GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, clam_shell_seg5_dl_05001568), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, -520, -6, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, clam_shell_seg5_dl_050012B8), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/actors/coin/geo.inc.c b/actors/coin/geo.inc.c index bfb2d92d..48d38c31 100644 --- a/actors/coin/geo.inc.c +++ b/actors/coin/geo.inc.c @@ -1,113 +1,113 @@ // 0x1600013C const GeoLayout yellow_coin_geo[] = { - GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0xB4, 50), - GEO_OPEN_NODE(), - GEO_SWITCH_CASE(8, geo_switch_anim_state), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, coin_seg3_dl_03007800), - GEO_DISPLAY_LIST(LAYER_ALPHA, coin_seg3_dl_03007800), - GEO_DISPLAY_LIST(LAYER_ALPHA, coin_seg3_dl_03007828), - GEO_DISPLAY_LIST(LAYER_ALPHA, coin_seg3_dl_03007828), - GEO_DISPLAY_LIST(LAYER_ALPHA, coin_seg3_dl_03007850), - GEO_DISPLAY_LIST(LAYER_ALPHA, coin_seg3_dl_03007850), - GEO_DISPLAY_LIST(LAYER_ALPHA, coin_seg3_dl_03007878), - GEO_DISPLAY_LIST(LAYER_ALPHA, coin_seg3_dl_03007878), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0xB4, 50), + GEO_OPEN_NODE(), + GEO_SWITCH_CASE(8, geo_switch_anim_state), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, coin_seg3_dl_03007800), + GEO_DISPLAY_LIST(LAYER_ALPHA, coin_seg3_dl_03007800), + GEO_DISPLAY_LIST(LAYER_ALPHA, coin_seg3_dl_03007828), + GEO_DISPLAY_LIST(LAYER_ALPHA, coin_seg3_dl_03007828), + GEO_DISPLAY_LIST(LAYER_ALPHA, coin_seg3_dl_03007850), + GEO_DISPLAY_LIST(LAYER_ALPHA, coin_seg3_dl_03007850), + GEO_DISPLAY_LIST(LAYER_ALPHA, coin_seg3_dl_03007878), + GEO_DISPLAY_LIST(LAYER_ALPHA, coin_seg3_dl_03007878), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; // 0x160001A0 const GeoLayout yellow_coin_no_shadow_geo[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_SWITCH_CASE(8, geo_switch_anim_state), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, coin_seg3_dl_03007800), - GEO_DISPLAY_LIST(LAYER_ALPHA, coin_seg3_dl_03007800), - GEO_DISPLAY_LIST(LAYER_ALPHA, coin_seg3_dl_03007828), - GEO_DISPLAY_LIST(LAYER_ALPHA, coin_seg3_dl_03007828), - GEO_DISPLAY_LIST(LAYER_ALPHA, coin_seg3_dl_03007850), - GEO_DISPLAY_LIST(LAYER_ALPHA, coin_seg3_dl_03007850), - GEO_DISPLAY_LIST(LAYER_ALPHA, coin_seg3_dl_03007878), - GEO_DISPLAY_LIST(LAYER_ALPHA, coin_seg3_dl_03007878), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_SWITCH_CASE(8, geo_switch_anim_state), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, coin_seg3_dl_03007800), + GEO_DISPLAY_LIST(LAYER_ALPHA, coin_seg3_dl_03007800), + GEO_DISPLAY_LIST(LAYER_ALPHA, coin_seg3_dl_03007828), + GEO_DISPLAY_LIST(LAYER_ALPHA, coin_seg3_dl_03007828), + GEO_DISPLAY_LIST(LAYER_ALPHA, coin_seg3_dl_03007850), + GEO_DISPLAY_LIST(LAYER_ALPHA, coin_seg3_dl_03007850), + GEO_DISPLAY_LIST(LAYER_ALPHA, coin_seg3_dl_03007878), + GEO_DISPLAY_LIST(LAYER_ALPHA, coin_seg3_dl_03007878), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; // 0x16000200 const GeoLayout blue_coin_geo[] = { - GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0xB4, 80), - GEO_OPEN_NODE(), - GEO_SWITCH_CASE(8, geo_switch_anim_state), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, coin_seg3_dl_030078A0), - GEO_DISPLAY_LIST(LAYER_ALPHA, coin_seg3_dl_030078A0), - GEO_DISPLAY_LIST(LAYER_ALPHA, coin_seg3_dl_030078C8), - GEO_DISPLAY_LIST(LAYER_ALPHA, coin_seg3_dl_030078C8), - GEO_DISPLAY_LIST(LAYER_ALPHA, coin_seg3_dl_030078F0), - GEO_DISPLAY_LIST(LAYER_ALPHA, coin_seg3_dl_030078F0), - GEO_DISPLAY_LIST(LAYER_ALPHA, coin_seg3_dl_03007918), - GEO_DISPLAY_LIST(LAYER_ALPHA, coin_seg3_dl_03007918), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0xB4, 80), + GEO_OPEN_NODE(), + GEO_SWITCH_CASE(8, geo_switch_anim_state), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, coin_seg3_dl_030078A0), + GEO_DISPLAY_LIST(LAYER_ALPHA, coin_seg3_dl_030078A0), + GEO_DISPLAY_LIST(LAYER_ALPHA, coin_seg3_dl_030078C8), + GEO_DISPLAY_LIST(LAYER_ALPHA, coin_seg3_dl_030078C8), + GEO_DISPLAY_LIST(LAYER_ALPHA, coin_seg3_dl_030078F0), + GEO_DISPLAY_LIST(LAYER_ALPHA, coin_seg3_dl_030078F0), + GEO_DISPLAY_LIST(LAYER_ALPHA, coin_seg3_dl_03007918), + GEO_DISPLAY_LIST(LAYER_ALPHA, coin_seg3_dl_03007918), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; // 0x16000264 const GeoLayout blue_coin_no_shadow_geo[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_SWITCH_CASE(8, geo_switch_anim_state), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, coin_seg3_dl_030078A0), - GEO_DISPLAY_LIST(LAYER_ALPHA, coin_seg3_dl_030078A0), - GEO_DISPLAY_LIST(LAYER_ALPHA, coin_seg3_dl_030078C8), - GEO_DISPLAY_LIST(LAYER_ALPHA, coin_seg3_dl_030078C8), - GEO_DISPLAY_LIST(LAYER_ALPHA, coin_seg3_dl_030078F0), - GEO_DISPLAY_LIST(LAYER_ALPHA, coin_seg3_dl_030078F0), - GEO_DISPLAY_LIST(LAYER_ALPHA, coin_seg3_dl_03007918), - GEO_DISPLAY_LIST(LAYER_ALPHA, coin_seg3_dl_03007918), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_SWITCH_CASE(8, geo_switch_anim_state), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, coin_seg3_dl_030078A0), + GEO_DISPLAY_LIST(LAYER_ALPHA, coin_seg3_dl_030078A0), + GEO_DISPLAY_LIST(LAYER_ALPHA, coin_seg3_dl_030078C8), + GEO_DISPLAY_LIST(LAYER_ALPHA, coin_seg3_dl_030078C8), + GEO_DISPLAY_LIST(LAYER_ALPHA, coin_seg3_dl_030078F0), + GEO_DISPLAY_LIST(LAYER_ALPHA, coin_seg3_dl_030078F0), + GEO_DISPLAY_LIST(LAYER_ALPHA, coin_seg3_dl_03007918), + GEO_DISPLAY_LIST(LAYER_ALPHA, coin_seg3_dl_03007918), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; // 0x160002C4 const GeoLayout red_coin_geo[] = { - GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0xB4, 80), - GEO_OPEN_NODE(), - GEO_SWITCH_CASE(8, geo_switch_anim_state), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, coin_seg3_dl_03007940), - GEO_DISPLAY_LIST(LAYER_ALPHA, coin_seg3_dl_03007940), - GEO_DISPLAY_LIST(LAYER_ALPHA, coin_seg3_dl_03007968), - GEO_DISPLAY_LIST(LAYER_ALPHA, coin_seg3_dl_03007968), - GEO_DISPLAY_LIST(LAYER_ALPHA, coin_seg3_dl_03007990), - GEO_DISPLAY_LIST(LAYER_ALPHA, coin_seg3_dl_03007990), - GEO_DISPLAY_LIST(LAYER_ALPHA, coin_seg3_dl_030079B8), - GEO_DISPLAY_LIST(LAYER_ALPHA, coin_seg3_dl_030079B8), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0xB4, 80), + GEO_OPEN_NODE(), + GEO_SWITCH_CASE(8, geo_switch_anim_state), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, coin_seg3_dl_03007940), + GEO_DISPLAY_LIST(LAYER_ALPHA, coin_seg3_dl_03007940), + GEO_DISPLAY_LIST(LAYER_ALPHA, coin_seg3_dl_03007968), + GEO_DISPLAY_LIST(LAYER_ALPHA, coin_seg3_dl_03007968), + GEO_DISPLAY_LIST(LAYER_ALPHA, coin_seg3_dl_03007990), + GEO_DISPLAY_LIST(LAYER_ALPHA, coin_seg3_dl_03007990), + GEO_DISPLAY_LIST(LAYER_ALPHA, coin_seg3_dl_030079B8), + GEO_DISPLAY_LIST(LAYER_ALPHA, coin_seg3_dl_030079B8), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; // 0x16000328 const GeoLayout red_coin_no_shadow_geo[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_SWITCH_CASE(8, geo_switch_anim_state), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, coin_seg3_dl_03007940), - GEO_DISPLAY_LIST(LAYER_ALPHA, coin_seg3_dl_03007940), - GEO_DISPLAY_LIST(LAYER_ALPHA, coin_seg3_dl_03007968), - GEO_DISPLAY_LIST(LAYER_ALPHA, coin_seg3_dl_03007968), - GEO_DISPLAY_LIST(LAYER_ALPHA, coin_seg3_dl_03007990), - GEO_DISPLAY_LIST(LAYER_ALPHA, coin_seg3_dl_03007990), - GEO_DISPLAY_LIST(LAYER_ALPHA, coin_seg3_dl_030079B8), - GEO_DISPLAY_LIST(LAYER_ALPHA, coin_seg3_dl_030079B8), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_SWITCH_CASE(8, geo_switch_anim_state), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, coin_seg3_dl_03007940), + GEO_DISPLAY_LIST(LAYER_ALPHA, coin_seg3_dl_03007940), + GEO_DISPLAY_LIST(LAYER_ALPHA, coin_seg3_dl_03007968), + GEO_DISPLAY_LIST(LAYER_ALPHA, coin_seg3_dl_03007968), + GEO_DISPLAY_LIST(LAYER_ALPHA, coin_seg3_dl_03007990), + GEO_DISPLAY_LIST(LAYER_ALPHA, coin_seg3_dl_03007990), + GEO_DISPLAY_LIST(LAYER_ALPHA, coin_seg3_dl_030079B8), + GEO_DISPLAY_LIST(LAYER_ALPHA, coin_seg3_dl_030079B8), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/actors/cyan_fish/geo.inc.c b/actors/cyan_fish/geo.inc.c index dfebc8fd..d16525bc 100644 --- a/actors/cyan_fish/geo.inc.c +++ b/actors/cyan_fish/geo.inc.c @@ -1,18 +1,18 @@ // 0x0D000324 const GeoLayout cyan_fish_geo[] = { - GEO_SCALE(0x00, 16384), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, cyan_fish_seg6_dl_0600DDD8), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 160, 0, 0, cyan_fish_seg6_dl_0600E038), - GEO_ANIMATED_PART(LAYER_OPAQUE, 32, 112, 0, NULL), + GEO_SCALE(0x00, 16384), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, cyan_fish_seg6_dl_0600DDD8), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, cyan_fish_seg6_dl_0600DED8), + GEO_ANIMATED_PART(LAYER_OPAQUE, 160, 0, 0, cyan_fish_seg6_dl_0600E038), + GEO_ANIMATED_PART(LAYER_OPAQUE, 32, 112, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, cyan_fish_seg6_dl_0600DED8), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/actors/dirt/geo.inc.c b/actors/dirt/geo.inc.c index ab4c558f..2abc63a7 100644 --- a/actors/dirt/geo.inc.c +++ b/actors/dirt/geo.inc.c @@ -1,33 +1,33 @@ // 0x16000ED4 const GeoLayout dirt_animation_geo[] = { - GEO_CULLING_RADIUS(300), - GEO_OPEN_NODE(), - GEO_SWITCH_CASE(6, geo_switch_anim_state), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, dirt_seg3_dl_0302C378), - GEO_DISPLAY_LIST(LAYER_OPAQUE, dirt_seg3_dl_0302C3B0), - GEO_DISPLAY_LIST(LAYER_OPAQUE, dirt_seg3_dl_0302C3E8), - GEO_DISPLAY_LIST(LAYER_ALPHA, dirt_seg3_dl_0302C028), - GEO_DISPLAY_LIST(LAYER_OPAQUE, dirt_seg3_dl_0302C420), - GEO_DISPLAY_LIST(LAYER_OPAQUE, dirt_seg3_dl_0302C458), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(300), + GEO_OPEN_NODE(), + GEO_SWITCH_CASE(6, geo_switch_anim_state), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, dirt_seg3_dl_0302C378), + GEO_DISPLAY_LIST(LAYER_OPAQUE, dirt_seg3_dl_0302C3B0), + GEO_DISPLAY_LIST(LAYER_OPAQUE, dirt_seg3_dl_0302C3E8), + GEO_DISPLAY_LIST(LAYER_ALPHA, dirt_seg3_dl_0302C028), + GEO_DISPLAY_LIST(LAYER_OPAQUE, dirt_seg3_dl_0302C420), + GEO_DISPLAY_LIST(LAYER_OPAQUE, dirt_seg3_dl_0302C458), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; // This is probably wrongly named according to the Bin IDs... // 0x16000F24 const GeoLayout cartoon_star_geo[] = { - GEO_CULLING_RADIUS(300), - GEO_OPEN_NODE(), - GEO_SWITCH_CASE(5, geo_switch_anim_state), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, dirt_seg3_dl_0302C298), - GEO_DISPLAY_LIST(LAYER_OPAQUE, dirt_seg3_dl_0302C2B8), - GEO_DISPLAY_LIST(LAYER_OPAQUE, dirt_seg3_dl_0302C2D8), - GEO_DISPLAY_LIST(LAYER_OPAQUE, dirt_seg3_dl_0302C2F8), - GEO_DISPLAY_LIST(LAYER_OPAQUE, dirt_seg3_dl_0302C318), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(300), + GEO_OPEN_NODE(), + GEO_SWITCH_CASE(5, geo_switch_anim_state), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, dirt_seg3_dl_0302C298), + GEO_DISPLAY_LIST(LAYER_OPAQUE, dirt_seg3_dl_0302C2B8), + GEO_DISPLAY_LIST(LAYER_OPAQUE, dirt_seg3_dl_0302C2D8), + GEO_DISPLAY_LIST(LAYER_OPAQUE, dirt_seg3_dl_0302C2F8), + GEO_DISPLAY_LIST(LAYER_OPAQUE, dirt_seg3_dl_0302C318), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/actors/door/geo.inc.c b/actors/door/geo.inc.c index 81c017d1..b13a3b54 100644 --- a/actors/door/geo.inc.c +++ b/actors/door/geo.inc.c @@ -1,320 +1,320 @@ // 0x160003A8 const GeoLayout castle_door_geo[] = { - GEO_TRANSLATE_NODE(0x00, 78, 0, 0), - GEO_OPEN_NODE(), - GEO_SCALE(0x00, 16384), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, -300, 0, 0, NULL), - GEO_OPEN_NODE(), + GEO_TRANSLATE_NODE(0x00, 78, 0, 0), + GEO_OPEN_NODE(), + GEO_SCALE(0x00, 16384), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, -300, 0, 0, NULL), GEO_OPEN_NODE(), - GEO_RENDER_RANGE(-2048, 3500), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, door_seg3_dl_03013E28), - GEO_CLOSE_NODE(), - GEO_RENDER_RANGE(3500, 32767), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, door_seg3_dl_03014100), - GEO_CLOSE_NODE(), + GEO_OPEN_NODE(), + GEO_RENDER_RANGE(-2048, 3500), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, door_seg3_dl_03013E28), + GEO_CLOSE_NODE(), + GEO_RENDER_RANGE(3500, 32767), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, door_seg3_dl_03014100), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), -GEO_CLOSE_NODE(), //! more close than open nodes -GEO_END(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), //! more close than open nodes + GEO_END(), }; // 0x1600043C const GeoLayout cabin_door_geo[] = { - GEO_TRANSLATE_NODE(0x00, 78, 0, 0), - GEO_OPEN_NODE(), - GEO_SCALE(0x00, 16384), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, -300, 0, 0, NULL), - GEO_OPEN_NODE(), + GEO_TRANSLATE_NODE(0x00, 78, 0, 0), + GEO_OPEN_NODE(), + GEO_SCALE(0x00, 16384), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, -300, 0, 0, NULL), GEO_OPEN_NODE(), - GEO_RENDER_RANGE(-2048, 3500), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, door_seg3_dl_03013EA8), - GEO_CLOSE_NODE(), - GEO_RENDER_RANGE(3500, 32767), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, door_seg3_dl_03014128), - GEO_CLOSE_NODE(), + GEO_OPEN_NODE(), + GEO_RENDER_RANGE(-2048, 3500), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, door_seg3_dl_03013EA8), + GEO_CLOSE_NODE(), + GEO_RENDER_RANGE(3500, 32767), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, door_seg3_dl_03014128), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), -GEO_CLOSE_NODE(), //! more close than open nodes -GEO_END(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), //! more close than open nodes + GEO_END(), }; // 0x160004D0 const GeoLayout wooden_door_geo[] = { - GEO_TRANSLATE_NODE(0x00, 78, 0, 0), - GEO_OPEN_NODE(), - GEO_SCALE(0x00, 16384), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, -300, 0, 0, NULL), - GEO_OPEN_NODE(), + GEO_TRANSLATE_NODE(0x00, 78, 0, 0), + GEO_OPEN_NODE(), + GEO_SCALE(0x00, 16384), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, -300, 0, 0, NULL), GEO_OPEN_NODE(), - GEO_RENDER_RANGE(-2048, 3500), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, door_seg3_dl_03014A80), - GEO_CLOSE_NODE(), - GEO_RENDER_RANGE(3500, 32767), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, door_seg3_dl_03014F98), - GEO_CLOSE_NODE(), + GEO_OPEN_NODE(), + GEO_RENDER_RANGE(-2048, 3500), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, door_seg3_dl_03014A80), + GEO_CLOSE_NODE(), + GEO_RENDER_RANGE(3500, 32767), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, door_seg3_dl_03014F98), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), -GEO_CLOSE_NODE(), //! more close than open nodes -GEO_END(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), //! more close than open nodes + GEO_END(), }; // 0x16000564 const GeoLayout wooden_door2_geo[] = { - GEO_TRANSLATE_NODE(0x00, 78, 0, 0), - GEO_OPEN_NODE(), - GEO_SCALE(0x00, 16384), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, -300, 0, 0, NULL), - GEO_OPEN_NODE(), + GEO_TRANSLATE_NODE(0x00, 78, 0, 0), + GEO_OPEN_NODE(), + GEO_SCALE(0x00, 16384), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, -300, 0, 0, NULL), GEO_OPEN_NODE(), - GEO_RENDER_RANGE(-2048, 3500), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, door_seg3_dl_03014B30), - GEO_CLOSE_NODE(), - GEO_RENDER_RANGE(3500, 32767), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, door_seg3_dl_03015008), - GEO_CLOSE_NODE(), + GEO_OPEN_NODE(), + GEO_RENDER_RANGE(-2048, 3500), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, door_seg3_dl_03014B30), + GEO_CLOSE_NODE(), + GEO_RENDER_RANGE(3500, 32767), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, door_seg3_dl_03015008), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), -GEO_CLOSE_NODE(), //! more close than open nodes -GEO_END(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), //! more close than open nodes + GEO_END(), }; // 0x160005F8 const GeoLayout metal_door_geo[] = { - GEO_TRANSLATE_NODE(0x00, 78, 0, 0), - GEO_OPEN_NODE(), - GEO_SCALE(0x00, 16384), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, -300, 0, 0, NULL), - GEO_OPEN_NODE(), + GEO_TRANSLATE_NODE(0x00, 78, 0, 0), + GEO_OPEN_NODE(), + GEO_SCALE(0x00, 16384), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, -300, 0, 0, NULL), GEO_OPEN_NODE(), - GEO_RENDER_RANGE(-2048, 3500), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, door_seg3_dl_03014BE0), - GEO_CLOSE_NODE(), - GEO_RENDER_RANGE(3500, 32767), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, door_seg3_dl_03015078), - GEO_CLOSE_NODE(), + GEO_OPEN_NODE(), + GEO_RENDER_RANGE(-2048, 3500), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, door_seg3_dl_03014BE0), + GEO_CLOSE_NODE(), + GEO_RENDER_RANGE(3500, 32767), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, door_seg3_dl_03015078), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), -GEO_CLOSE_NODE(), //! more close than open nodes -GEO_END(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), //! more close than open nodes + GEO_END(), }; // 0x1600068C const GeoLayout hazy_maze_door_geo[] = { - GEO_TRANSLATE_NODE(0x00, 78, 0, 0), - GEO_OPEN_NODE(), - GEO_SCALE(0x00, 16384), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, -300, 0, 0, NULL), - GEO_OPEN_NODE(), + GEO_TRANSLATE_NODE(0x00, 78, 0, 0), + GEO_OPEN_NODE(), + GEO_SCALE(0x00, 16384), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, -300, 0, 0, NULL), GEO_OPEN_NODE(), - GEO_RENDER_RANGE(-2048, 3500), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, door_seg3_dl_03014C90), - GEO_CLOSE_NODE(), - GEO_RENDER_RANGE(3500, 32767), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, door_seg3_dl_030150E8), - GEO_CLOSE_NODE(), + GEO_OPEN_NODE(), + GEO_RENDER_RANGE(-2048, 3500), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, door_seg3_dl_03014C90), + GEO_CLOSE_NODE(), + GEO_RENDER_RANGE(3500, 32767), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, door_seg3_dl_030150E8), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), -GEO_CLOSE_NODE(), //! more close than open nodes -GEO_END(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), //! more close than open nodes + GEO_END(), }; // 0x16000720 const GeoLayout haunted_door_geo[] = { - GEO_TRANSLATE_NODE(0x00, 78, 0, 0), - GEO_OPEN_NODE(), - GEO_SCALE(0x00, 16384), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, -300, 0, 0, NULL), - GEO_OPEN_NODE(), + GEO_TRANSLATE_NODE(0x00, 78, 0, 0), + GEO_OPEN_NODE(), + GEO_SCALE(0x00, 16384), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, -300, 0, 0, NULL), GEO_OPEN_NODE(), - GEO_RENDER_RANGE(-2048, 3500), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, door_seg3_dl_03014D40), - GEO_CLOSE_NODE(), - GEO_RENDER_RANGE(3500, 32767), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, door_seg3_dl_03015158), - GEO_CLOSE_NODE(), + GEO_OPEN_NODE(), + GEO_RENDER_RANGE(-2048, 3500), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, door_seg3_dl_03014D40), + GEO_CLOSE_NODE(), + GEO_RENDER_RANGE(3500, 32767), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, door_seg3_dl_03015158), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), -GEO_CLOSE_NODE(), //! more close than open nodes -GEO_END(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), //! more close than open nodes + GEO_END(), }; // 0x160007B4 const GeoLayout castle_door_0_star_geo[] = { - GEO_TRANSLATE_NODE(0x00, 78, 0, 0), - GEO_OPEN_NODE(), - GEO_SCALE(0x00, 16384), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, -300, 0, 0, NULL), - GEO_OPEN_NODE(), + GEO_TRANSLATE_NODE(0x00, 78, 0, 0), + GEO_OPEN_NODE(), + GEO_SCALE(0x00, 16384), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, -300, 0, 0, NULL), GEO_OPEN_NODE(), - GEO_RENDER_RANGE(-2048, 1000), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, door_seg3_dl_03013E28), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, door_seg3_dl_03014250), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_RENDER_RANGE(1000, 32767), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, door_seg3_dl_03013E28), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT_DECAL, door_seg3_dl_03014280), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), + GEO_OPEN_NODE(), + GEO_RENDER_RANGE(-2048, 1000), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, door_seg3_dl_03013E28), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, door_seg3_dl_03014250), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_RENDER_RANGE(1000, 32767), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, door_seg3_dl_03013E28), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT_DECAL, door_seg3_dl_03014280), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), -GEO_CLOSE_NODE(), //! more close than open nodes -GEO_END(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), //! more close than open nodes + GEO_END(), }; // 0x16000868 const GeoLayout castle_door_1_star_geo[] = { - GEO_TRANSLATE_NODE(0x00, 78, 0, 0), - GEO_OPEN_NODE(), - GEO_SCALE(0x00, 16384), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, -300, 0, 0, NULL), - GEO_OPEN_NODE(), + GEO_TRANSLATE_NODE(0x00, 78, 0, 0), + GEO_OPEN_NODE(), + GEO_SCALE(0x00, 16384), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, -300, 0, 0, NULL), GEO_OPEN_NODE(), - GEO_RENDER_RANGE(-2048, 1000), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, door_seg3_dl_03013E28), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, door_seg3_dl_030142B0), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_RENDER_RANGE(1000, 32767), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, door_seg3_dl_03013E28), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT_DECAL, door_seg3_dl_030142E0), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), + GEO_OPEN_NODE(), + GEO_RENDER_RANGE(-2048, 1000), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, door_seg3_dl_03013E28), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, door_seg3_dl_030142B0), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_RENDER_RANGE(1000, 32767), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, door_seg3_dl_03013E28), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT_DECAL, door_seg3_dl_030142E0), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), -GEO_CLOSE_NODE(), //! more close than open nodes -GEO_END(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), //! more close than open nodes + GEO_END(), }; // 0x1600091C const GeoLayout castle_door_3_stars_geo[] = { - GEO_TRANSLATE_NODE(0x00, 78, 0, 0), - GEO_OPEN_NODE(), - GEO_SCALE(0x00, 16384), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, -300, 0, 0, NULL), - GEO_OPEN_NODE(), + GEO_TRANSLATE_NODE(0x00, 78, 0, 0), + GEO_OPEN_NODE(), + GEO_SCALE(0x00, 16384), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, -300, 0, 0, NULL), GEO_OPEN_NODE(), - GEO_RENDER_RANGE(-2048, 1000), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, door_seg3_dl_03013E28), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, door_seg3_dl_03014310), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_RENDER_RANGE(1000, 32767), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, door_seg3_dl_03013E28), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT_DECAL, door_seg3_dl_03014340), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), + GEO_OPEN_NODE(), + GEO_RENDER_RANGE(-2048, 1000), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, door_seg3_dl_03013E28), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, door_seg3_dl_03014310), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_RENDER_RANGE(1000, 32767), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, door_seg3_dl_03013E28), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT_DECAL, door_seg3_dl_03014340), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), -GEO_CLOSE_NODE(), //! more close than open nodes -GEO_END(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), //! more close than open nodes + GEO_END(), }; // 0x160009D0 const GeoLayout key_door_geo[] = { - GEO_TRANSLATE_NODE(0x00, 78, 0, 0), - GEO_OPEN_NODE(), - GEO_SCALE(0x00, 16384), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, -300, 0, 0, NULL), - GEO_OPEN_NODE(), + GEO_TRANSLATE_NODE(0x00, 78, 0, 0), + GEO_OPEN_NODE(), + GEO_SCALE(0x00, 16384), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, -300, 0, 0, NULL), GEO_OPEN_NODE(), - GEO_RENDER_RANGE(-2048, 1000), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, door_seg3_dl_03013E28), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, door_seg3_dl_03014540), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_RENDER_RANGE(1000, 32767), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, door_seg3_dl_03013E28), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE_DECAL, door_seg3_dl_03014528), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), + GEO_OPEN_NODE(), + GEO_RENDER_RANGE(-2048, 1000), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, door_seg3_dl_03013E28), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, door_seg3_dl_03014540), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_RENDER_RANGE(1000, 32767), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, door_seg3_dl_03013E28), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE_DECAL, door_seg3_dl_03014528), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), -GEO_CLOSE_NODE(), //! more close than open nodes -GEO_END(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), //! more close than open nodes + GEO_END(), }; diff --git a/actors/dorrie/geo.inc.c b/actors/dorrie/geo.inc.c index 23fd462c..73f76e66 100644 --- a/actors/dorrie/geo.inc.c +++ b/actors/dorrie/geo.inc.c @@ -1,54 +1,54 @@ // 0x0D000230 const GeoLayout dorrie_geo[] = { - GEO_CULLING_RADIUS(5000), - GEO_OPEN_NODE(), - GEO_SCALE(0x00, 16384), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, dorrie_seg6_dl_0600CFD0), + GEO_CULLING_RADIUS(5000), + GEO_OPEN_NODE(), + GEO_SCALE(0x00, 16384), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 1295, 0, 0, dorrie_seg6_dl_0600C8B8), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 916, 0, 0, dorrie_seg6_dl_0600C468), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 874, 0, 0, dorrie_seg6_dl_0600BAF8), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, dorrie_seg6_dl_0600DFA8), - GEO_ANIMATED_PART(LAYER_OPAQUE, 30, 444, -6, NULL), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, dorrie_seg6_dl_0600CFD0), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 1295, 0, 0, dorrie_seg6_dl_0600C8B8), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 916, 0, 0, dorrie_seg6_dl_0600C468), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, dorrie_seg6_dl_0600C030), + GEO_ANIMATED_PART(LAYER_OPAQUE, 874, 0, 0, dorrie_seg6_dl_0600BAF8), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, dorrie_seg6_dl_0600DFA8), + GEO_ANIMATED_PART(LAYER_OPAQUE, 30, 444, -6, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, dorrie_seg6_dl_0600C030), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, -893, -490, -6, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, dorrie_seg6_dl_0600D440), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 1300, 0, 0, dorrie_seg6_dl_0600D6D8), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, -1086, 91, -700, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, dorrie_seg6_dl_0600DE38), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 902, 700, -785, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, dorrie_seg6_dl_0600DA88), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, -1086, 91, 698, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, dorrie_seg6_dl_0600DC60), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 902, 700, 783, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, dorrie_seg6_dl_0600D8B0), - GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, -893, -490, -6, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, dorrie_seg6_dl_0600D440), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 1300, 0, 0, dorrie_seg6_dl_0600D6D8), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, -1086, 91, -700, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, dorrie_seg6_dl_0600DE38), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 902, 700, -785, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, dorrie_seg6_dl_0600DA88), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, -1086, 91, 698, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, dorrie_seg6_dl_0600DC60), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 902, 700, 783, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, dorrie_seg6_dl_0600D8B0), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), -GEO_CLOSE_NODE(), //! more close than open nodes -GEO_END(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), //! more close than open nodes + GEO_END(), }; diff --git a/actors/exclamation_box/geo.inc.c b/actors/exclamation_box/geo.inc.c index 3d5845c8..d23f3f4c 100644 --- a/actors/exclamation_box/geo.inc.c +++ b/actors/exclamation_box/geo.inc.c @@ -1,17 +1,17 @@ // 0x0F000694 const GeoLayout exclamation_box_geo[] = { - GEO_CULLING_RADIUS(300), - GEO_OPEN_NODE(), - GEO_SHADOW(SHADOW_SQUARE_PERMANENT, 0xB4, 70), - GEO_OPEN_NODE(), - GEO_SWITCH_CASE(4, geo_switch_anim_state), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, exclamation_box_seg8_dl_08019318), - GEO_DISPLAY_LIST(LAYER_OPAQUE, exclamation_box_seg8_dl_08019378), - GEO_DISPLAY_LIST(LAYER_OPAQUE, exclamation_box_seg8_dl_080193D8), - GEO_DISPLAY_LIST(LAYER_OPAQUE, exclamation_box_seg8_dl_08019438), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(300), + GEO_OPEN_NODE(), + GEO_SHADOW(SHADOW_SQUARE_PERMANENT, 0xB4, 70), + GEO_OPEN_NODE(), + GEO_SWITCH_CASE(4, geo_switch_anim_state), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, exclamation_box_seg8_dl_08019318), + GEO_DISPLAY_LIST(LAYER_OPAQUE, exclamation_box_seg8_dl_08019378), + GEO_DISPLAY_LIST(LAYER_OPAQUE, exclamation_box_seg8_dl_080193D8), + GEO_DISPLAY_LIST(LAYER_OPAQUE, exclamation_box_seg8_dl_08019438), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/actors/exclamation_box_outline/geo.inc.c b/actors/exclamation_box_outline/geo.inc.c index 88e8101b..963876df 100644 --- a/actors/exclamation_box_outline/geo.inc.c +++ b/actors/exclamation_box_outline/geo.inc.c @@ -1,18 +1,18 @@ // 0x0F000A5A const GeoLayout exclamation_box_outline_geo[] = { - GEO_CULLING_RADIUS(300), - GEO_OPEN_NODE(), - GEO_SHADOW(SHADOW_SQUARE_PERMANENT, 0xB4, 70), - GEO_OPEN_NODE(), - GEO_SWITCH_CASE(4, geo_switch_anim_state), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, exclamation_box_outline_seg8_dl_08024F88), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, exclamation_box_outline_seg8_dl_08024FA8), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, exclamation_box_outline_seg8_dl_08024FC8), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, exclamation_box_outline_seg8_dl_08024FE8), - GEO_CLOSE_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, exclamation_box_outline_seg8_dl_080259F8), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(300), + GEO_OPEN_NODE(), + GEO_SHADOW(SHADOW_SQUARE_PERMANENT, 0xB4, 70), + GEO_OPEN_NODE(), + GEO_SWITCH_CASE(4, geo_switch_anim_state), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, exclamation_box_outline_seg8_dl_08024F88), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, exclamation_box_outline_seg8_dl_08024FA8), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, exclamation_box_outline_seg8_dl_08024FC8), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, exclamation_box_outline_seg8_dl_08024FE8), + GEO_CLOSE_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, exclamation_box_outline_seg8_dl_080259F8), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/actors/explosion/geo.inc.c b/actors/explosion/geo.inc.c index 901bae67..0d27a1fb 100644 --- a/actors/explosion/geo.inc.c +++ b/actors/explosion/geo.inc.c @@ -1,19 +1,19 @@ // 0x16000040 const GeoLayout explosion_geo[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_SWITCH_CASE(9, geo_switch_anim_state), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, explosion_seg3_dl_03004298), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, explosion_seg3_dl_03004298), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, explosion_seg3_dl_030042B0), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, explosion_seg3_dl_030042B0), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, explosion_seg3_dl_030042C8), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, explosion_seg3_dl_030042E0), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, explosion_seg3_dl_030042F8), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, explosion_seg3_dl_03004310), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, explosion_seg3_dl_03004328), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_SWITCH_CASE(9, geo_switch_anim_state), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, explosion_seg3_dl_03004298), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, explosion_seg3_dl_03004298), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, explosion_seg3_dl_030042B0), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, explosion_seg3_dl_030042B0), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, explosion_seg3_dl_030042C8), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, explosion_seg3_dl_030042E0), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, explosion_seg3_dl_030042F8), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, explosion_seg3_dl_03004310), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, explosion_seg3_dl_03004328), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/actors/eyerok/geo.inc.c b/actors/eyerok/geo.inc.c index 16113827..5f70b302 100644 --- a/actors/eyerok/geo.inc.c +++ b/actors/eyerok/geo.inc.c @@ -1,131 +1,131 @@ // 0x0C0002AC const GeoLayout eyerok_geo_0002AC[] = { - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 447, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, eyerok_seg5_dl_0500C640), - GEO_ANIMATED_PART(LAYER_OPAQUE, 281, 5, -419, NULL), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 447, 0, 0, NULL), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 400, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 401, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, eyerok_seg5_dl_0500BF00), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, eyerok_seg5_dl_0500C100), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, eyerok_seg5_dl_0500C378), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 281, 5, -218, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 400, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 401, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, eyerok_seg5_dl_0500BF00), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, eyerok_seg5_dl_0500C100), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, eyerok_seg5_dl_0500C378), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 281, 5, -18, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 400, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 401, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, eyerok_seg5_dl_0500BF00), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, eyerok_seg5_dl_0500C100), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, eyerok_seg5_dl_0500C378), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 281, 5, 180, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 400, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 401, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, eyerok_seg5_dl_0500BF00), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, eyerok_seg5_dl_0500C100), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, eyerok_seg5_dl_0500C378), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, eyerok_seg5_dl_0500C908), - GEO_OPEN_NODE(), - GEO_SWITCH_CASE(4, geo_switch_anim_state), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, eyerok_seg5_dl_0500C9B8), - GEO_DISPLAY_LIST(LAYER_ALPHA, eyerok_seg5_dl_0500CA50), - GEO_DISPLAY_LIST(LAYER_ALPHA, eyerok_seg5_dl_0500CAE8), - GEO_DISPLAY_LIST(LAYER_ALPHA, eyerok_seg5_dl_0500CB80), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 181, 89, 80, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 199, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, eyerok_seg5_dl_0500BC88), - GEO_ANIMATED_PART(LAYER_OPAQUE, 200, 199, 199, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 336, 0, 0, NULL), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, eyerok_seg5_dl_0500C640), + GEO_ANIMATED_PART(LAYER_OPAQUE, 281, 5, -419, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 400, 0, 0, NULL), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, eyerok_seg5_dl_0500B748), + GEO_ANIMATED_PART(LAYER_OPAQUE, 401, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, eyerok_seg5_dl_0500BF00), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, eyerok_seg5_dl_0500C100), GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, eyerok_seg5_dl_0500B9C0), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, eyerok_seg5_dl_0500C378), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 281, 5, -218, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 400, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 401, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, eyerok_seg5_dl_0500BF00), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, eyerok_seg5_dl_0500C100), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, eyerok_seg5_dl_0500C378), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 281, 5, -18, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 400, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 401, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, eyerok_seg5_dl_0500BF00), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, eyerok_seg5_dl_0500C100), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, eyerok_seg5_dl_0500C378), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 281, 5, 180, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 400, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 401, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, eyerok_seg5_dl_0500BF00), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, eyerok_seg5_dl_0500C100), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, eyerok_seg5_dl_0500C378), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, eyerok_seg5_dl_0500C908), + GEO_OPEN_NODE(), + GEO_SWITCH_CASE(4, geo_switch_anim_state), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, eyerok_seg5_dl_0500C9B8), + GEO_DISPLAY_LIST(LAYER_ALPHA, eyerok_seg5_dl_0500CA50), + GEO_DISPLAY_LIST(LAYER_ALPHA, eyerok_seg5_dl_0500CAE8), + GEO_DISPLAY_LIST(LAYER_ALPHA, eyerok_seg5_dl_0500CB80), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 181, 89, 80, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 199, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, eyerok_seg5_dl_0500BC88), + GEO_ANIMATED_PART(LAYER_OPAQUE, 200, 199, 199, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 336, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, eyerok_seg5_dl_0500B748), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, eyerok_seg5_dl_0500B9C0), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x0C0005A8 const GeoLayout eyerok_left_hand_geo[] = { - GEO_SHADOW(SHADOW_SQUARE_SCALABLE, 0xB4, 300), - GEO_OPEN_NODE(), - GEO_SCALE(0x00, 16384), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, eyerok_seg5_dl_0500CC18), - GEO_BRANCH(1, eyerok_geo_0002AC), - GEO_DISPLAY_LIST(LAYER_OPAQUE, eyerok_seg5_dl_0500CC30), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_SHADOW(SHADOW_SQUARE_SCALABLE, 0xB4, 300), + GEO_OPEN_NODE(), + GEO_SCALE(0x00, 16384), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, eyerok_seg5_dl_0500CC18), + GEO_BRANCH(1, eyerok_geo_0002AC), + GEO_DISPLAY_LIST(LAYER_OPAQUE, eyerok_seg5_dl_0500CC30), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; // 0x0C0005E4 const GeoLayout eyerok_right_hand_geo[] = { - GEO_SHADOW(SHADOW_SQUARE_SCALABLE, 0xB4, 300), - GEO_OPEN_NODE(), - GEO_SCALE(0x00, 16384), - GEO_OPEN_NODE(), - GEO_BRANCH(1, eyerok_geo_0002AC), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_SHADOW(SHADOW_SQUARE_SCALABLE, 0xB4, 300), + GEO_OPEN_NODE(), + GEO_SCALE(0x00, 16384), + GEO_OPEN_NODE(), + GEO_BRANCH(1, eyerok_geo_0002AC), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/actors/flame/geo.inc.c b/actors/flame/geo.inc.c index a4617ad2..88185272 100644 --- a/actors/flame/geo.inc.c +++ b/actors/flame/geo.inc.c @@ -1,46 +1,46 @@ // 0x16000B10 const GeoLayout red_flame_shadow_geo[] = { - GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0x50, 20), - GEO_OPEN_NODE(), - GEO_BRANCH_AND_LINK(red_flame_geo), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0x50, 20), + GEO_OPEN_NODE(), + GEO_BRANCH_AND_LINK(red_flame_geo), + GEO_CLOSE_NODE(), + GEO_END(), }; // 0x16000B2C const GeoLayout red_flame_geo[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_SWITCH_CASE(8, geo_switch_anim_state), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, flame_seg3_dl_0301B3B0), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, flame_seg3_dl_0301B3C8), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, flame_seg3_dl_0301B3E0), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, flame_seg3_dl_0301B3F8), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, flame_seg3_dl_0301B410), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, flame_seg3_dl_0301B428), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, flame_seg3_dl_0301B440), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, flame_seg3_dl_0301B458), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_SWITCH_CASE(8, geo_switch_anim_state), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, flame_seg3_dl_0301B3B0), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, flame_seg3_dl_0301B3C8), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, flame_seg3_dl_0301B3E0), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, flame_seg3_dl_0301B3F8), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, flame_seg3_dl_0301B410), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, flame_seg3_dl_0301B428), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, flame_seg3_dl_0301B440), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, flame_seg3_dl_0301B458), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; // 0x16000B8C const GeoLayout blue_flame_geo[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_SWITCH_CASE(8, geo_switch_anim_state), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, flame_seg3_dl_0301B500), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, flame_seg3_dl_0301B518), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, flame_seg3_dl_0301B530), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, flame_seg3_dl_0301B548), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, flame_seg3_dl_0301B560), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, flame_seg3_dl_0301B578), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, flame_seg3_dl_0301B590), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, flame_seg3_dl_0301B5A8), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_SWITCH_CASE(8, geo_switch_anim_state), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, flame_seg3_dl_0301B500), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, flame_seg3_dl_0301B518), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, flame_seg3_dl_0301B530), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, flame_seg3_dl_0301B548), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, flame_seg3_dl_0301B560), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, flame_seg3_dl_0301B578), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, flame_seg3_dl_0301B590), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, flame_seg3_dl_0301B5A8), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/actors/flyguy/geo.inc.c b/actors/flyguy/geo.inc.c index 54bf6fd1..30e4ed4c 100644 --- a/actors/flyguy/geo.inc.c +++ b/actors/flyguy/geo.inc.c @@ -1,29 +1,29 @@ // 0x0F000518 const GeoLayout flyguy_geo[] = { - GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0x96, 100), - GEO_OPEN_NODE(), - GEO_SCALE(0x00, 16384), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, flyguy_seg8_dl_08011710), + GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0x96, 100), + GEO_OPEN_NODE(), + GEO_SCALE(0x00, 16384), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, -45, -20, -55, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, flyguy_seg8_dl_08010840), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, -45, -20, 55, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, flyguy_seg8_dl_08010968), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 250, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, flyguy_seg8_dl_08010B80), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, flyguy_seg8_dl_08011710), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, -45, -20, -55, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, flyguy_seg8_dl_08010840), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, -45, -20, 55, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, flyguy_seg8_dl_08010968), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 250, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, flyguy_seg8_dl_08010B80), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/actors/fwoosh/geo.inc.c b/actors/fwoosh/geo.inc.c index 9067675c..0ee64b01 100644 --- a/actors/fwoosh/geo.inc.c +++ b/actors/fwoosh/geo.inc.c @@ -1,8 +1,8 @@ // 0x0C00036C const GeoLayout fwoosh_geo[] = { - GEO_CULLING_RADIUS(200), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, fwoosh_seg5_dl_05016040), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(200), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, fwoosh_seg5_dl_05016040), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/actors/goomba/geo.inc.c b/actors/goomba/geo.inc.c index fb5c8d17..b011b602 100644 --- a/actors/goomba/geo.inc.c +++ b/actors/goomba/geo.inc.c @@ -1,35 +1,35 @@ // 0x0F0006E4 const GeoLayout goomba_geo[] = { - GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0x96, 100), - GEO_OPEN_NODE(), - GEO_SCALE(0x00, 16384), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, goomba_seg8_dl_0801D760), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0x96, 100), + GEO_OPEN_NODE(), + GEO_SCALE(0x00, 16384), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, goomba_seg8_dl_0801D760), GEO_OPEN_NODE(), - GEO_BILLBOARD(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, goomba_seg8_dl_0801B690), - GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_BILLBOARD(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, goomba_seg8_dl_0801B690), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_OPEN_NODE(), + GEO_SWITCH_CASE(2, geo_switch_anim_state), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 48, 0, 0, goomba_seg8_dl_0801B5C8), + GEO_ANIMATED_PART(LAYER_OPAQUE, 48, 0, 0, goomba_seg8_dl_0801B5F0), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, -60, -16, 45, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, goomba_seg8_dl_0801CE20), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, -60, -16, -45, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, goomba_seg8_dl_0801CF78), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_OPEN_NODE(), - GEO_SWITCH_CASE(2, geo_switch_anim_state), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 48, 0, 0, goomba_seg8_dl_0801B5C8), - GEO_ANIMATED_PART(LAYER_OPAQUE, 48, 0, 0, goomba_seg8_dl_0801B5F0), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, -60, -16, 45, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, goomba_seg8_dl_0801CE20), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, -60, -16, -45, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, goomba_seg8_dl_0801CF78), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/actors/haunted_cage/geo.inc.c b/actors/haunted_cage/geo.inc.c index 5bfa6486..864378ba 100644 --- a/actors/haunted_cage/geo.inc.c +++ b/actors/haunted_cage/geo.inc.c @@ -1,13 +1,13 @@ // 0x0C000274 const GeoLayout haunted_cage_geo[] = { - GEO_CULLING_RADIUS(300), - GEO_OPEN_NODE(), - GEO_SHADOW(SHADOW_CIRCLE_9_VERTS, 0x96, 100), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, haunted_cage_seg5_dl_0500F7D8), - GEO_DISPLAY_LIST(LAYER_OPAQUE, haunted_cage_seg5_dl_0500FC28), - GEO_DISPLAY_LIST(LAYER_ALPHA, haunted_cage_seg5_dl_05010100), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(300), + GEO_OPEN_NODE(), + GEO_SHADOW(SHADOW_CIRCLE_9_VERTS, 0x96, 100), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, haunted_cage_seg5_dl_0500F7D8), + GEO_DISPLAY_LIST(LAYER_OPAQUE, haunted_cage_seg5_dl_0500FC28), + GEO_DISPLAY_LIST(LAYER_ALPHA, haunted_cage_seg5_dl_05010100), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/actors/heart/geo.inc.c b/actors/heart/geo.inc.c index 756654ff..a81cb9c3 100644 --- a/actors/heart/geo.inc.c +++ b/actors/heart/geo.inc.c @@ -1,8 +1,8 @@ // 0x0F0004FC const GeoLayout heart_geo[] = { - GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0x64, 100), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, heart_seg8_dl_0800DFE0), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0x64, 100), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, heart_seg8_dl_0800DFE0), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/actors/heave_ho/geo.inc.c b/actors/heave_ho/geo.inc.c index 61866e56..fc7e1385 100644 --- a/actors/heave_ho/geo.inc.c +++ b/actors/heave_ho/geo.inc.c @@ -1,60 +1,60 @@ // 0x0C00028C const GeoLayout heave_ho_geo[] = { - GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0xC8, 100), - GEO_OPEN_NODE(), - GEO_SCALE(0x00, 16384), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, heave_ho_seg5_dl_05014D80), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 140, -11, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, heave_ho_seg5_dl_05011EC0), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 150, 50, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, heave_ho_seg5_dl_05014560), - GEO_ANIMATED_PART(LAYER_ALPHA, 0, 0, 0, heave_ho_seg5_dl_050127F8), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 135, 0, -84, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_BILLBOARD(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, heave_ho_seg5_dl_050126E8), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 168, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_BILLBOARD(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, heave_ho_seg5_dl_050126E8), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 168, 0, 0, NULL), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 149, -28, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, heave_ho_seg5_dl_050125F8), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, heave_ho_seg5_dl_05012148), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, heave_ho_seg5_dl_050123A8), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), + GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0xC8, 100), + GEO_OPEN_NODE(), + GEO_SCALE(0x00, 16384), + GEO_OPEN_NODE(), GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), GEO_OPEN_NODE(), - GEO_BILLBOARD(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, heave_ho_seg5_dl_050126E8), - GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, heave_ho_seg5_dl_05014D80), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 140, -11, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, heave_ho_seg5_dl_05011EC0), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 150, 50, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, heave_ho_seg5_dl_05014560), + GEO_ANIMATED_PART(LAYER_ALPHA, 0, 0, 0, heave_ho_seg5_dl_050127F8), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 135, 0, -84, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_BILLBOARD(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, heave_ho_seg5_dl_050126E8), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 168, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_BILLBOARD(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, heave_ho_seg5_dl_050126E8), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 168, 0, 0, NULL), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 149, -28, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, heave_ho_seg5_dl_050125F8), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, heave_ho_seg5_dl_05012148), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, heave_ho_seg5_dl_050123A8), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_BILLBOARD(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, heave_ho_seg5_dl_050126E8), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/actors/hoot/geo.inc.c b/actors/hoot/geo.inc.c index e415a492..1f7c51d6 100644 --- a/actors/hoot/geo.inc.c +++ b/actors/hoot/geo.inc.c @@ -1,62 +1,62 @@ // 0x0C000018 const GeoLayout hoot_geo[] = { - GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0xFF, 100), - GEO_OPEN_NODE(), - GEO_SCALE(0x00, 16384), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 147, -5, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, hoot_seg5_dl_05004D48), + GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0xFF, 100), + GEO_OPEN_NODE(), + GEO_SCALE(0x00, 16384), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 147, -5, NULL), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 96, 0, 0, hoot_seg5_dl_05001DF0), - GEO_ANIMATED_PART(LAYER_OPAQUE, 34, -35, 31, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_ALPHA, 0, 0, 0, hoot_seg5_dl_05003728), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_ALPHA, 91, 0, 0, hoot_seg5_dl_050034D8), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_ALPHA, 121, 0, 0, hoot_seg5_dl_050033B0), - GEO_ANIMATED_PART(LAYER_OPAQUE, 121, 0, 0, NULL), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 91, 0, 0, NULL), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_ALPHA, 0, 0, 0, hoot_seg5_dl_05003600), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, -31, 5, 37, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, hoot_seg5_dl_05004A98), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 42, 0, 0, hoot_seg5_dl_05004928), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, -31, 5, -37, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, hoot_seg5_dl_05004CA8), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 42, 0, 0, hoot_seg5_dl_05004B38), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 34, -35, -31, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_ALPHA, 0, 0, 0, hoot_seg5_dl_05003288), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_ALPHA, 91, 0, 0, hoot_seg5_dl_05003038), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_ALPHA, 121, 0, 0, hoot_seg5_dl_05002F10), - GEO_ANIMATED_PART(LAYER_OPAQUE, 121, 0, 0, NULL), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 91, 0, 0, NULL), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_ALPHA, 0, 0, 0, hoot_seg5_dl_05003160), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, hoot_seg5_dl_05004D48), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 96, 0, 0, hoot_seg5_dl_05001DF0), + GEO_ANIMATED_PART(LAYER_OPAQUE, 34, -35, 31, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_ALPHA, 0, 0, 0, hoot_seg5_dl_05003728), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_ALPHA, 91, 0, 0, hoot_seg5_dl_050034D8), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_ALPHA, 121, 0, 0, hoot_seg5_dl_050033B0), + GEO_ANIMATED_PART(LAYER_OPAQUE, 121, 0, 0, NULL), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 91, 0, 0, NULL), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_ALPHA, 0, 0, 0, hoot_seg5_dl_05003600), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, -31, 5, 37, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, hoot_seg5_dl_05004A98), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 42, 0, 0, hoot_seg5_dl_05004928), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, -31, 5, -37, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, hoot_seg5_dl_05004CA8), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 42, 0, 0, hoot_seg5_dl_05004B38), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 34, -35, -31, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_ALPHA, 0, 0, 0, hoot_seg5_dl_05003288), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_ALPHA, 91, 0, 0, hoot_seg5_dl_05003038), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_ALPHA, 121, 0, 0, hoot_seg5_dl_05002F10), + GEO_ANIMATED_PART(LAYER_OPAQUE, 121, 0, 0, NULL), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 91, 0, 0, NULL), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_ALPHA, 0, 0, 0, hoot_seg5_dl_05003160), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), -GEO_CLOSE_NODE(), //! more close than open nodes -GEO_END(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), //! more close than open nodes + GEO_END(), }; diff --git a/actors/impact_ring/geo.inc.c b/actors/impact_ring/geo.inc.c index a3a7898f..20b4d119 100644 --- a/actors/impact_ring/geo.inc.c +++ b/actors/impact_ring/geo.inc.c @@ -1,9 +1,9 @@ // 0x0D000090 const GeoLayout invisible_bowser_accessory_geo[] = { - GEO_CULLING_RADIUS(10000), - GEO_OPEN_NODE(), - GEO_ASM(20, geo_update_layer_transparency), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT_DECAL, impact_ring_seg6_dl_0601EAC0), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(10000), + GEO_OPEN_NODE(), + GEO_ASM(20, geo_update_layer_transparency), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT_DECAL, impact_ring_seg6_dl_0601EAC0), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/actors/impact_smoke/geo.inc.c b/actors/impact_smoke/geo.inc.c index d8790212..fa49067a 100644 --- a/actors/impact_smoke/geo.inc.c +++ b/actors/impact_smoke/geo.inc.c @@ -1,16 +1,16 @@ // 0x0D000BB8 / 0BFC const GeoLayout bowser_impact_smoke_geo[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_ASM(0, geo_update_layer_transparency), - GEO_SWITCH_CASE(5, geo_switch_anim_state), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, impact_smoke_seg6_dl_06062B38), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, impact_smoke_seg6_dl_06062BD8), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, impact_smoke_seg6_dl_06062C78), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, impact_smoke_seg6_dl_06062D18), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, impact_smoke_seg6_dl_06062BD8), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_ASM(0, geo_update_layer_transparency), + GEO_SWITCH_CASE(5, geo_switch_anim_state), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, impact_smoke_seg6_dl_06062B38), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, impact_smoke_seg6_dl_06062BD8), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, impact_smoke_seg6_dl_06062C78), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, impact_smoke_seg6_dl_06062D18), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, impact_smoke_seg6_dl_06062BD8), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/actors/king_bobomb/geo.inc.c b/actors/king_bobomb/geo.inc.c index 5b7ced61..a9e6a704 100644 --- a/actors/king_bobomb/geo.inc.c +++ b/actors/king_bobomb/geo.inc.c @@ -1,120 +1,120 @@ // 0x0C000000 const GeoLayout king_bobomb_geo[] = { - GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0x96, 300), - GEO_OPEN_NODE(), - GEO_SCALE(0x00, 16384), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), + GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0x96, 300), + GEO_OPEN_NODE(), + GEO_SCALE(0x00, 16384), + GEO_OPEN_NODE(), GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_BILLBOARD(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, king_bobomb_seg5_dl_0500B188), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, -243, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 488, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 110, 0, 0, NULL), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_BILLBOARD(), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, king_bobomb_seg5_dl_0500AD08), + GEO_DISPLAY_LIST(LAYER_ALPHA, king_bobomb_seg5_dl_0500B188), GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, -243, 0, NULL), + GEO_OPEN_NODE(), GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), GEO_OPEN_NODE(), - GEO_BILLBOARD(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, king_bobomb_seg5_dl_0500A5D8), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_ALPHA, 0, 0, 0, king_bobomb_seg5_dl_0500B2D0), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, king_bobomb_seg5_dl_0500B418), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, king_bobomb_seg5_dl_0500B6C0), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 243, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 488, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 110, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, king_bobomb_seg5_dl_0500B068), + GEO_ANIMATED_PART(LAYER_OPAQUE, 488, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 110, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, king_bobomb_seg5_dl_0500AD08), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_BILLBOARD(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, king_bobomb_seg5_dl_0500A5D8), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_ALPHA, 0, 0, 0, king_bobomb_seg5_dl_0500B2D0), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, king_bobomb_seg5_dl_0500B418), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, king_bobomb_seg5_dl_0500B6C0), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 243, 0, NULL), + GEO_OPEN_NODE(), GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), GEO_OPEN_NODE(), - GEO_BILLBOARD(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, king_bobomb_seg5_dl_0500A890), - GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 488, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 110, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, king_bobomb_seg5_dl_0500B068), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_BILLBOARD(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, king_bobomb_seg5_dl_0500A890), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, -1, 36, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 548, 0, 0, NULL), - GEO_OPEN_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, -1, 36, NULL), + GEO_OPEN_NODE(), GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), GEO_OPEN_NODE(), - GEO_BILLBOARD(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, king_bobomb_seg5_dl_0500A4F0), - GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 548, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_BILLBOARD(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, king_bobomb_seg5_dl_0500A4F0), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 189, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_BILLBOARD(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, king_bobomb_seg5_dl_0500A6C0), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ASM(0, geo_update_held_mario_pos), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 189, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_BILLBOARD(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, king_bobomb_seg5_dl_0500A6C0), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ASM(0, geo_update_held_mario_pos), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 1, 36, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 548, 0, 0, NULL), - GEO_OPEN_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 1, 36, NULL), + GEO_OPEN_NODE(), GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), GEO_OPEN_NODE(), - GEO_BILLBOARD(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, king_bobomb_seg5_dl_0500A7A8), - GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 548, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_BILLBOARD(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, king_bobomb_seg5_dl_0500A7A8), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 189, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_BILLBOARD(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, king_bobomb_seg5_dl_0500A978), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 189, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_BILLBOARD(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, king_bobomb_seg5_dl_0500A978), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), -GEO_CLOSE_NODE(), //! more close than open nodes -GEO_END(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), //! more close than open nodes + GEO_END(), }; diff --git a/actors/klepto/geo.inc.c b/actors/klepto/geo.inc.c index 0d0bbe30..33145a1b 100644 --- a/actors/klepto/geo.inc.c +++ b/actors/klepto/geo.inc.c @@ -1,96 +1,96 @@ // 0x0C000000 const GeoLayout klepto_geo[] = { - GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0x96, 250), - GEO_OPEN_NODE(), - GEO_SCALE(0x00, 65536), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_ALPHA, 0, 0, 0, klepto_seg5_dl_050041E8), + GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0x96, 250), + GEO_OPEN_NODE(), + GEO_SCALE(0x00, 65536), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 62, 0, 0, klepto_seg5_dl_05003F20), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 44, 0, 0, klepto_seg5_dl_05003D80), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 58, 0, 0, klepto_seg5_dl_05003BD0), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, -3, 17, 17, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, klepto_seg5_dl_05004330), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 68, 0, 0, klepto_seg5_dl_050047C8), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_SWITCH_CASE(4, geo_switch_anim_state), + GEO_ANIMATED_PART(LAYER_ALPHA, 0, 0, 0, klepto_seg5_dl_050041E8), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 62, 0, 0, klepto_seg5_dl_05003F20), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 44, 0, 0, klepto_seg5_dl_05003D80), GEO_OPEN_NODE(), - GEO_NODE_START(), - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_SCALE(0x00, 16384), - GEO_OPEN_NODE(), - GEO_ASM(0, geo_offset_klepto_held_object), - GEO_TRANSLATE_ROTATE_WITH_DL(LAYER_OPAQUE, 0, 100, 0, 180, 270, 0, mario_cap_seg3_dl_03022F48), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_SCALE(0x00, 16384), - GEO_OPEN_NODE(), - GEO_ASM(0, geo_offset_klepto_held_object), - GEO_TRANSLATE_ROTATE_WITH_DL(LAYER_OPAQUE, 0, 100, 0, 180, 270, 0, star_seg3_dl_0302B870), - GEO_ASM(0, geo_offset_klepto_held_object), - GEO_TRANSLATE_ROTATE_WITH_DL(LAYER_ALPHA, 0, 100, 0, 180, 270, 0, star_seg3_dl_0302BA18), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_SCALE(0x00, 16384), - GEO_OPEN_NODE(), - GEO_ASM(0, geo_offset_klepto_held_object), - GEO_TRANSLATE_ROTATE_WITH_DL(LAYER_OPAQUE, 0, 100, 0, 180, 270, 0, transparent_star_seg3_dl_0302C620), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 58, 0, 0, klepto_seg5_dl_05003BD0), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, -3, 17, -17, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, klepto_seg5_dl_05004438), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 68, 0, 0, klepto_seg5_dl_05004B58), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 49, -9, -17, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_ALPHA, 0, 0, 0, klepto_seg5_dl_05004D38), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_ALPHA, 34, 0, 0, klepto_seg5_dl_05004F58), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_ALPHA, 79, 0, 0, klepto_seg5_dl_05005178), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 49, -9, 17, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_ALPHA, 0, 0, 0, klepto_seg5_dl_05004C28), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_ALPHA, 34, 0, 0, klepto_seg5_dl_05004E48), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_ALPHA, 79, 0, 0, klepto_seg5_dl_05005068), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, -3, 17, 17, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, klepto_seg5_dl_05004330), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 68, 0, 0, klepto_seg5_dl_050047C8), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_SWITCH_CASE(4, geo_switch_anim_state), + GEO_OPEN_NODE(), + GEO_NODE_START(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_SCALE(0x00, 16384), + GEO_OPEN_NODE(), + GEO_ASM(0, geo_offset_klepto_held_object), + GEO_TRANSLATE_ROTATE_WITH_DL(LAYER_OPAQUE, 0, 100, 0, 180, 270, 0, mario_cap_seg3_dl_03022F48), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_SCALE(0x00, 16384), + GEO_OPEN_NODE(), + GEO_ASM(0, geo_offset_klepto_held_object), + GEO_TRANSLATE_ROTATE_WITH_DL(LAYER_OPAQUE, 0, 100, 0, 180, 270, 0, star_seg3_dl_0302B870), + GEO_ASM(0, geo_offset_klepto_held_object), + GEO_TRANSLATE_ROTATE_WITH_DL(LAYER_ALPHA, 0, 100, 0, 180, 270, 0, star_seg3_dl_0302BA18), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_SCALE(0x00, 16384), + GEO_OPEN_NODE(), + GEO_ASM(0, geo_offset_klepto_held_object), + GEO_TRANSLATE_ROTATE_WITH_DL(LAYER_OPAQUE, 0, 100, 0, 180, 270, 0, transparent_star_seg3_dl_0302C620), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, -3, 17, -17, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, klepto_seg5_dl_05004438), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 68, 0, 0, klepto_seg5_dl_05004B58), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 49, -9, -17, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_ALPHA, 0, 0, 0, klepto_seg5_dl_05004D38), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_ALPHA, 34, 0, 0, klepto_seg5_dl_05004F58), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_ALPHA, 79, 0, 0, klepto_seg5_dl_05005178), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 49, -9, 17, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_ALPHA, 0, 0, 0, klepto_seg5_dl_05004C28), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_ALPHA, 34, 0, 0, klepto_seg5_dl_05004E48), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_ALPHA, 79, 0, 0, klepto_seg5_dl_05005068), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, klepto_seg5_dl_05004118), GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, klepto_seg5_dl_05004118), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/actors/koopa/geo.inc.c b/actors/koopa/geo.inc.c index a6cbe07a..1e83c2b9 100644 --- a/actors/koopa/geo.inc.c +++ b/actors/koopa/geo.inc.c @@ -1,99 +1,99 @@ // 0x0D0000D0 const GeoLayout koopa_without_shell_geo[] = { - GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0x9B, 100), - GEO_OPEN_NODE(), - GEO_SCALE(0x00, 16384), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, koopa_seg6_dl_0600C498), + GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0x9B, 100), + GEO_OPEN_NODE(), + GEO_SCALE(0x00, 16384), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), GEO_OPEN_NODE(), - GEO_SWITCH_CASE(2, geo_switch_anim_state), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 114, 0, 0, koopa_seg6_dl_06007AF8), - GEO_ANIMATED_PART(LAYER_OPAQUE, 114, 0, 0, koopa_seg6_dl_06007B20), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, -29, 39, 60, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, koopa_seg6_dl_0600B838), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, koopa_seg6_dl_060086D0), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, -29, 39, -60, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, koopa_seg6_dl_0600BA10), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, koopa_seg6_dl_06008B50), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 55, 25, -73, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, koopa_seg6_dl_0600BC18), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 54, 0, 0, koopa_seg6_dl_0600BA90), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 55, 25, 74, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, koopa_seg6_dl_0600BE10), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 54, 0, 0, koopa_seg6_dl_0600BC88), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, koopa_seg6_dl_0600C498), + GEO_OPEN_NODE(), + GEO_SWITCH_CASE(2, geo_switch_anim_state), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 114, 0, 0, koopa_seg6_dl_06007AF8), + GEO_ANIMATED_PART(LAYER_OPAQUE, 114, 0, 0, koopa_seg6_dl_06007B20), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, -29, 39, 60, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, koopa_seg6_dl_0600B838), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, koopa_seg6_dl_060086D0), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, -29, 39, -60, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, koopa_seg6_dl_0600BA10), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, koopa_seg6_dl_06008B50), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 55, 25, -73, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, koopa_seg6_dl_0600BC18), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 54, 0, 0, koopa_seg6_dl_0600BA90), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 55, 25, 74, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, koopa_seg6_dl_0600BE10), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 54, 0, 0, koopa_seg6_dl_0600BC88), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; // 0x0D000214 const GeoLayout koopa_with_shell_geo[] = { - GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0x9B, 100), - GEO_OPEN_NODE(), - GEO_SCALE(0x00, 16384), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, koopa_seg6_dl_06008250), + GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0x9B, 100), + GEO_OPEN_NODE(), + GEO_SCALE(0x00, 16384), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), GEO_OPEN_NODE(), - GEO_SWITCH_CASE(2, geo_switch_anim_state), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 114, 0, 0, koopa_seg6_dl_06007AF8), - GEO_ANIMATED_PART(LAYER_OPAQUE, 114, 0, 0, koopa_seg6_dl_06007B20), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, -29, 39, 60, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, koopa_seg6_dl_0600B838), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, koopa_seg6_dl_060086D0), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, -29, 39, -60, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, koopa_seg6_dl_0600BA10), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, koopa_seg6_dl_06008B50), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 55, 25, -73, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, koopa_seg6_dl_0600BC18), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 54, 0, 0, koopa_seg6_dl_0600BA90), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 55, 25, 74, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, koopa_seg6_dl_0600BE10), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 54, 0, 0, koopa_seg6_dl_0600BC88), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, koopa_seg6_dl_06008250), + GEO_OPEN_NODE(), + GEO_SWITCH_CASE(2, geo_switch_anim_state), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 114, 0, 0, koopa_seg6_dl_06007AF8), + GEO_ANIMATED_PART(LAYER_OPAQUE, 114, 0, 0, koopa_seg6_dl_06007B20), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, -29, 39, 60, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, koopa_seg6_dl_0600B838), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, koopa_seg6_dl_060086D0), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, -29, 39, -60, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, koopa_seg6_dl_0600BA10), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, koopa_seg6_dl_06008B50), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 55, 25, -73, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, koopa_seg6_dl_0600BC18), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 54, 0, 0, koopa_seg6_dl_0600BA90), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 55, 25, 74, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, koopa_seg6_dl_0600BE10), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 54, 0, 0, koopa_seg6_dl_0600BC88), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/actors/koopa_flag/geo.inc.c b/actors/koopa_flag/geo.inc.c index b9c8c8dc..b3c45187 100644 --- a/actors/koopa_flag/geo.inc.c +++ b/actors/koopa_flag/geo.inc.c @@ -1,32 +1,32 @@ // 0x0D000000 const GeoLayout koopa_flag_geo[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_SCALE(0x00, 16384), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, koopa_flag_seg6_dl_06000A08), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_SCALE(0x00, 16384), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 2040, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, koopa_flag_seg6_dl_06000B08), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 460, 0, 0, koopa_flag_seg6_dl_06000BF8), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 460, 0, 0, koopa_flag_seg6_dl_06000CE0), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, koopa_flag_seg6_dl_06000A08), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 2040, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, koopa_flag_seg6_dl_06000B08), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 344, 0, 0, koopa_flag_seg6_dl_06000DB0), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 288, 0, 0, koopa_flag_seg6_dl_06000E38), - GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 460, 0, 0, koopa_flag_seg6_dl_06000BF8), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 460, 0, 0, koopa_flag_seg6_dl_06000CE0), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 344, 0, 0, koopa_flag_seg6_dl_06000DB0), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 288, 0, 0, koopa_flag_seg6_dl_06000E38), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/actors/koopa_shell/geo.inc.c b/actors/koopa_shell/geo.inc.c index 424c3291..82f273bb 100644 --- a/actors/koopa_shell/geo.inc.c +++ b/actors/koopa_shell/geo.inc.c @@ -1,35 +1,35 @@ // 0x0F000AB0 const GeoLayout koopa_shell_geo[] = { - GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0xC8, 70), - GEO_OPEN_NODE(), - GEO_SCALE(0x00, 65536), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, koopa_shell_seg8_dl_08028B78), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0xC8, 70), + GEO_OPEN_NODE(), + GEO_SCALE(0x00, 65536), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, koopa_shell_seg8_dl_08028B78), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; // 0x0F000ADC const GeoLayout koopa_shell2_geo[] = { - GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0xC8, 70), - GEO_OPEN_NODE(), - GEO_SCALE(0x00, 16384), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, koopa_shell_seg8_dl_08027420), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0xC8, 70), + GEO_OPEN_NODE(), + GEO_SCALE(0x00, 16384), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, koopa_shell_seg8_dl_08027420), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; // 0x0F000B08 const GeoLayout koopa_shell3_geo[] = { - GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0xC8, 70), - GEO_OPEN_NODE(), - GEO_SCALE(0x00, 16384), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, koopa_shell_seg8_dl_080273C8), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0xC8, 70), + GEO_OPEN_NODE(), + GEO_SCALE(0x00, 16384), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, koopa_shell_seg8_dl_080273C8), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/actors/lakitu_cameraman/geo.inc.c b/actors/lakitu_cameraman/geo.inc.c index 2dd17365..0275019d 100644 --- a/actors/lakitu_cameraman/geo.inc.c +++ b/actors/lakitu_cameraman/geo.inc.c @@ -1,43 +1,43 @@ // 0x0D000000 const GeoLayout lakitu_geo[] = { - GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0x96, 100), - GEO_OPEN_NODE(), - GEO_SCALE(0x00, 16384), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, lakitu_seg6_dl_06003E30), + GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0x96, 100), + GEO_OPEN_NODE(), + GEO_SCALE(0x00, 16384), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 132, 0, 0, lakitu_seg6_dl_06004680), - GEO_OPEN_NODE(), - GEO_SWITCH_CASE(2, geo_switch_anim_state), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, lakitu_seg6_dl_06004C60), - GEO_DISPLAY_LIST(LAYER_ALPHA, lakitu_seg6_dl_06004C88), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 87, 18, 72, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, lakitu_seg6_dl_060047E8), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 87, 18, -72, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, lakitu_seg6_dl_060049E0), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 334, -214, -50, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, lakitu_seg6_dl_06005610), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, lakitu_seg6_dl_06003E30), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 132, 0, 0, lakitu_seg6_dl_06004680), + GEO_OPEN_NODE(), + GEO_SWITCH_CASE(2, geo_switch_anim_state), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 191, 0, 0, lakitu_seg6_dl_06005360), + GEO_DISPLAY_LIST(LAYER_ALPHA, lakitu_seg6_dl_06004C60), + GEO_DISPLAY_LIST(LAYER_ALPHA, lakitu_seg6_dl_06004C88), GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, lakitu_seg6_dl_060055E8), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, lakitu_seg6_dl_06005598), - GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 87, 18, 72, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, lakitu_seg6_dl_060047E8), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 87, 18, -72, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, lakitu_seg6_dl_060049E0), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 334, -214, -50, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, lakitu_seg6_dl_06005610), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 191, 0, 0, lakitu_seg6_dl_06005360), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, lakitu_seg6_dl_060055E8), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, lakitu_seg6_dl_06005598), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/actors/lakitu_enemy/geo.inc.c b/actors/lakitu_enemy/geo.inc.c index 93045f6e..a8173217 100644 --- a/actors/lakitu_enemy/geo.inc.c +++ b/actors/lakitu_enemy/geo.inc.c @@ -1,34 +1,34 @@ // 0x0C0001BC const GeoLayout enemy_lakitu_geo[] = { - GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0x96, 100), - GEO_OPEN_NODE(), - GEO_SCALE(0x00, 16384), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 63, -62, lakitu_enemy_seg5_dl_050138B0), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, lakitu_enemy_seg5_dl_05012910), + GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0x96, 100), + GEO_OPEN_NODE(), + GEO_SCALE(0x00, 16384), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 63, -62, lakitu_enemy_seg5_dl_050138B0), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 132, 0, 0, lakitu_enemy_seg5_dl_05013160), - GEO_OPEN_NODE(), - GEO_SWITCH_CASE(2, geo_switch_anim_state), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, lakitu_enemy_seg5_dl_05013350), - GEO_DISPLAY_LIST(LAYER_ALPHA, lakitu_enemy_seg5_dl_05013378), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 87, 18, 72, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, lakitu_enemy_seg5_dl_050136A0), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 87, 18, -72, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, lakitu_enemy_seg5_dl_050134A8), - GEO_ASM(0, geo_update_projectile_pos_from_parent), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, lakitu_enemy_seg5_dl_05012910), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 132, 0, 0, lakitu_enemy_seg5_dl_05013160), + GEO_OPEN_NODE(), + GEO_SWITCH_CASE(2, geo_switch_anim_state), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, lakitu_enemy_seg5_dl_05013350), + GEO_DISPLAY_LIST(LAYER_ALPHA, lakitu_enemy_seg5_dl_05013378), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 87, 18, 72, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, lakitu_enemy_seg5_dl_050136A0), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 87, 18, -72, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, lakitu_enemy_seg5_dl_050134A8), + GEO_ASM(0, geo_update_projectile_pos_from_parent), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/actors/leaves/geo.inc.c b/actors/leaves/geo.inc.c index c466a517..bc313117 100644 --- a/actors/leaves/geo.inc.c +++ b/actors/leaves/geo.inc.c @@ -1,8 +1,8 @@ // 0x16000C8C const GeoLayout leaves_geo[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, leaves_seg3_dl_0301CDE0), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, leaves_seg3_dl_0301CDE0), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/actors/mad_piano/geo.inc.c b/actors/mad_piano/geo.inc.c index 70dea53e..cc155976 100644 --- a/actors/mad_piano/geo.inc.c +++ b/actors/mad_piano/geo.inc.c @@ -1,21 +1,21 @@ // 0x0C0001B4 const GeoLayout mad_piano_geo[] = { - GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0x96, 100), - GEO_OPEN_NODE(), - GEO_SCALE(0x00, 16384), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, mad_piano_seg5_dl_050098E8), + GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0x96, 100), + GEO_OPEN_NODE(), + GEO_SCALE(0x00, 16384), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, -141, -546, 218, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, mad_piano_seg5_dl_05008CB0), - GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, mad_piano_seg5_dl_050098E8), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, -141, -546, 218, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, mad_piano_seg5_dl_05008CB0), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), -GEO_CLOSE_NODE(), //! more close than open nodes -GEO_END(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), //! more close than open nodes + GEO_END(), }; diff --git a/actors/manta/geo.inc.c b/actors/manta/geo.inc.c index d60ce675..91c524c6 100644 --- a/actors/manta/geo.inc.c +++ b/actors/manta/geo.inc.c @@ -1,60 +1,60 @@ // 0x05008D14 const GeoLayout manta_seg5_geo_05008D14[] = { - GEO_SCALE(0, 16384), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(1, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(1, 0, 0, 0, manta_seg5_dl_05006750), + GEO_SCALE(0, 16384), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(1, 0, 0, 0, NULL), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(1, 440, 220, 6, NULL), + GEO_ANIMATED_PART(1, 0, 0, 0, manta_seg5_dl_05006750), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(1, 0, 0, 0, manta_seg5_dl_05005358), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(1, 220, 0, 0, manta_seg5_dl_050055A8), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(1, 180, 0, 0, manta_seg5_dl_05005768), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(1, 440, -220, 6, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(1, 0, 0, 0, manta_seg5_dl_05005C38), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(1, 220, 0, 0, manta_seg5_dl_05005E88), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(1, 180, 0, 0, manta_seg5_dl_05006048), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(1, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(1, 0, 0, 0, manta_seg5_dl_05006C08), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(1, 168, 0, 0, manta_seg5_dl_05006B70), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(1, 236, 0, 0, manta_seg5_dl_05006B08), - GEO_ANIMATED_PART(1, 236, 0, 0, manta_seg5_dl_05004E90), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(1, 688, 120, -6, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(1, 0, 0, 0, manta_seg5_dl_05005038), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(1, 668, 170, 6, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(1, 0, 0, 0, manta_seg5_dl_05004DB8), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(1, 688, -120, -6, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(1, 0, 0, 0, manta_seg5_dl_05005918), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(1, 668, -170, 6, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(1, 0, 0, 0, manta_seg5_dl_05004A70), + GEO_ANIMATED_PART(1, 440, 220, 6, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(1, 0, 0, 0, manta_seg5_dl_05005358), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(1, 220, 0, 0, manta_seg5_dl_050055A8), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(1, 180, 0, 0, manta_seg5_dl_05005768), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(1, 440, -220, 6, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(1, 0, 0, 0, manta_seg5_dl_05005C38), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(1, 220, 0, 0, manta_seg5_dl_05005E88), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(1, 180, 0, 0, manta_seg5_dl_05006048), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(1, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(1, 0, 0, 0, manta_seg5_dl_05006C08), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(1, 168, 0, 0, manta_seg5_dl_05006B70), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(1, 236, 0, 0, manta_seg5_dl_05006B08), + GEO_ANIMATED_PART(1, 236, 0, 0, manta_seg5_dl_05004E90), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(1, 688, 120, -6, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(1, 0, 0, 0, manta_seg5_dl_05005038), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(1, 668, 170, 6, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(1, 0, 0, 0, manta_seg5_dl_05004DB8), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(1, 688, -120, -6, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(1, 0, 0, 0, manta_seg5_dl_05005918), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(1, 668, -170, 6, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(1, 0, 0, 0, manta_seg5_dl_05004A70), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/actors/mario/geo.inc.c b/actors/mario/geo.inc.c index 736d31f0..feb396bb 100644 --- a/actors/mario/geo.inc.c +++ b/actors/mario/geo.inc.c @@ -2,1824 +2,1824 @@ // 0x170002E0 const GeoLayout mario_geo_face_and_wings[] = { - GEO_ASM(0, geo_mario_head_rotation), - GEO_ROTATION_NODE(0x00, 0, 0, 0), - GEO_OPEN_NODE(), - GEO_SWITCH_CASE(0, geo_switch_mario_cap_on_off), - GEO_OPEN_NODE(), - GEO_SWITCH_CASE(0, geo_switch_mario_eyes), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_cap_on_eyes_front), - GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_cap_on_eyes_half_closed), - GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_cap_on_eyes_closed), - GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_cap_on_eyes_right), // unused - GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_cap_on_eyes_left), // unused - GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_cap_on_eyes_up), // unused - GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_cap_on_eyes_down), // unused - GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_cap_on_eyes_dead), - GEO_CLOSE_NODE(), - GEO_SWITCH_CASE(0, geo_switch_mario_eyes), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_cap_off_eyes_front), - GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_cap_off_eyes_half_closed), - GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_cap_off_eyes_closed), - GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_cap_off_eyes_right), // unused - GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_cap_off_eyes_left), // unused - GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_cap_off_eyes_up), // unused - GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_cap_off_eyes_down), // unused - GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_cap_off_eyes_dead), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_TRANSLATE_ROTATE(0, 142, -51, -126, 22, -40, -135), - GEO_OPEN_NODE(), - GEO_ASM(0, geo_mario_rotate_wing_cap_wings), - GEO_ROTATION_NODE(0x00, 0, 0, 0), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, mario_cap_wings), // left - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_TRANSLATE_ROTATE(0, 142, -51, 126, -22, 40, -135), - GEO_OPEN_NODE(), - GEO_ASM(1, geo_mario_rotate_wing_cap_wings), - GEO_ROTATION_NODE(0x00, 0, 0, 0), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, mario_cap_wings), // right - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_ASM(0, geo_mario_head_rotation), + GEO_ROTATION_NODE(0x00, 0, 0, 0), + GEO_OPEN_NODE(), + GEO_SWITCH_CASE(0, geo_switch_mario_cap_on_off), + GEO_OPEN_NODE(), + GEO_SWITCH_CASE(0, geo_switch_mario_eyes), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_cap_on_eyes_front), + GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_cap_on_eyes_half_closed), + GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_cap_on_eyes_closed), + GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_cap_on_eyes_right), // unused + GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_cap_on_eyes_left), // unused + GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_cap_on_eyes_up), // unused + GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_cap_on_eyes_down), // unused + GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_cap_on_eyes_dead), + GEO_CLOSE_NODE(), + GEO_SWITCH_CASE(0, geo_switch_mario_eyes), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_cap_off_eyes_front), + GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_cap_off_eyes_half_closed), + GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_cap_off_eyes_closed), + GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_cap_off_eyes_right), // unused + GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_cap_off_eyes_left), // unused + GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_cap_off_eyes_up), // unused + GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_cap_off_eyes_down), // unused + GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_cap_off_eyes_dead), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_TRANSLATE_ROTATE(0, 142, -51, -126, 22, -40, -135), + GEO_OPEN_NODE(), + GEO_ASM(0, geo_mario_rotate_wing_cap_wings), + GEO_ROTATION_NODE(0x00, 0, 0, 0), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, mario_cap_wings), // left + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_TRANSLATE_ROTATE(0, 142, -51, 126, -22, 40, -135), + GEO_OPEN_NODE(), + GEO_ASM(1, geo_mario_rotate_wing_cap_wings), + GEO_ROTATION_NODE(0x00, 0, 0, 0), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, mario_cap_wings), // right + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x1700041C const GeoLayout mario_geo_left_hand[] = { - GEO_SWITCH_CASE(1, geo_switch_mario_hand), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ASM(1, geo_mario_hand_foot_scaler), - GEO_SCALE(0x00, 65536), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_left_hand_closed), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, mario_left_hand_open), - GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, mario_left_hand_closed), - GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, mario_left_hand_closed), - GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, mario_left_hand_closed), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_SWITCH_CASE(1, geo_switch_mario_hand), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ASM(1, geo_mario_hand_foot_scaler), + GEO_SCALE(0x00, 65536), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_left_hand_closed), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, mario_left_hand_open), + GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, mario_left_hand_closed), + GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, mario_left_hand_closed), + GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, mario_left_hand_closed), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x17000494 const GeoLayout mario_geo_right_hand[] = { - GEO_SWITCH_CASE(0, geo_switch_mario_hand), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ASM(0, geo_mario_hand_foot_scaler), - GEO_SCALE(0x00, 65536), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_right_hand_closed), - GEO_CLOSE_NODE(), - GEO_HELD_OBJECT(0x00, 0, 0, 0, geo_switch_mario_hand_grab_pos), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, mario_right_hand_open), - GEO_OPEN_NODE(), - GEO_HELD_OBJECT(0x00, 0, 0, 0, geo_switch_mario_hand_grab_pos), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, mario_right_hand_peace), // here we go hand - GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, mario_right_hand_cap), - GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, mario_right_hand_cap), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, mario_right_hand_cap_wings), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_SWITCH_CASE(0, geo_switch_mario_hand), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ASM(0, geo_mario_hand_foot_scaler), + GEO_SCALE(0x00, 65536), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_right_hand_closed), + GEO_CLOSE_NODE(), + GEO_HELD_OBJECT(0x00, 0, 0, 0, geo_switch_mario_hand_grab_pos), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, mario_right_hand_open), + GEO_OPEN_NODE(), + GEO_HELD_OBJECT(0x00, 0, 0, 0, geo_switch_mario_hand_grab_pos), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, mario_right_hand_peace), // here we go hand + GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, mario_right_hand_cap), + GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, mario_right_hand_cap), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, mario_right_hand_cap_wings), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // The body loads all the parts with some shared dls to apply the solid color of the dl that has it, the same rule applies to the medium and low poly geos // 0x1700053C const GeoLayout mario_geo_body[] = { - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, mario_butt), // starts sharing solid color with mario_torso (blue) - GEO_OPEN_NODE(), - GEO_ASM(0, geo_move_mario_part_from_parent), - GEO_ASM(0, geo_mario_tilt_torso), - GEO_ROTATION_NODE(0x00, 0, 0, 0), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 68, 0, 0, mario_torso), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, mario_butt), // starts sharing solid color with mario_torso (blue) + GEO_OPEN_NODE(), + GEO_ASM(0, geo_move_mario_part_from_parent), + GEO_ASM(0, geo_mario_tilt_torso), + GEO_ROTATION_NODE(0x00, 0, 0, 0), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 87, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_BRANCH(1, mario_geo_face_and_wings), // stops sharing because faces has its own dl - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 67, -10, 79, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, mario_left_arm), // starts sharing solid color with mario_left_forearm (red) - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 65, 0, 0, mario_left_forearm_shared_dl), - GEO_OPEN_NODE(), - GEO_BRANCH(1, mario_geo_left_hand), // stops sharing because hand has its solid color (white) - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 68, -10, -79, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, mario_right_arm), // starts sharing solid color of his dl with mario_right_forearm (red) - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 65, 0, 0, mario_right_forearm_shared_dl), - GEO_OPEN_NODE(), - GEO_BRANCH(1, mario_geo_right_hand), // stops sharing because hand has its solid color (white) - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 68, 0, 0, mario_torso), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 87, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_BRANCH(1, mario_geo_face_and_wings), // stops sharing because faces has its own dl + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 67, -10, 79, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, mario_left_arm), // starts sharing solid color with mario_left_forearm (red) + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 65, 0, 0, mario_left_forearm_shared_dl), + GEO_OPEN_NODE(), + GEO_BRANCH(1, mario_geo_left_hand), // stops sharing because hand has its solid color (white) + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 68, -10, -79, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, mario_right_arm), // starts sharing solid color of his dl with mario_right_forearm (red) + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 65, 0, 0, mario_right_forearm_shared_dl), + GEO_OPEN_NODE(), + GEO_BRANCH(1, mario_geo_right_hand), // stops sharing because hand has its solid color (white) + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 13, -8, 42, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, mario_left_thigh), // starts sharing solid color of his dl with mario_left_leg (blue) + GEO_ANIMATED_PART(LAYER_OPAQUE, 13, -8, 42, NULL), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 89, 0, 0, mario_left_leg_shared_dl), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 67, 0, 0, mario_left_foot), // stops sharing because foot has its solid color (brown) - GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, mario_left_thigh), // starts sharing solid color of his dl with mario_left_leg (blue) + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 89, 0, 0, mario_left_leg_shared_dl), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 67, 0, 0, mario_left_foot), // stops sharing because foot has its solid color (brown) + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 13, -8, -42, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, mario_right_thigh), // starts sharing solid color of his dl with mario_left_leg (blue) + GEO_ANIMATED_PART(LAYER_OPAQUE, 13, -8, -42, NULL), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 89, 0, 0, mario_right_leg_shared_dl), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 67, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ASM(2, geo_mario_hand_foot_scaler), - GEO_SCALE(0x00, 65536), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_right_foot), // stops sharing because foot has its solid color (brown) - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, mario_right_thigh), // starts sharing solid color of his dl with mario_left_leg (blue) + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 89, 0, 0, mario_right_leg_shared_dl), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 67, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ASM(2, geo_mario_hand_foot_scaler), + GEO_SCALE(0x00, 65536), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_right_foot), // stops sharing because foot has its solid color (brown) + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x170006F8 const GeoLayout mario_geo_medium_poly_left_hand[] = { - GEO_SWITCH_CASE(1, geo_switch_mario_hand), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ASM(1, geo_mario_hand_foot_scaler), - GEO_SCALE(0x00, 65536), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_medium_poly_left_hand_closed), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, mario_left_hand_open), - GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, mario_medium_poly_left_hand_closed), - GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, mario_medium_poly_left_hand_closed), - GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, mario_medium_poly_left_hand_closed), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_SWITCH_CASE(1, geo_switch_mario_hand), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ASM(1, geo_mario_hand_foot_scaler), + GEO_SCALE(0x00, 65536), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_medium_poly_left_hand_closed), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, mario_left_hand_open), + GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, mario_medium_poly_left_hand_closed), + GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, mario_medium_poly_left_hand_closed), + GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, mario_medium_poly_left_hand_closed), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x17000770 const GeoLayout mario_geo_medium_poly_right_hand[] = { - GEO_SWITCH_CASE(0, geo_switch_mario_hand), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ASM(0, geo_mario_hand_foot_scaler), - GEO_SCALE(0x00, 65536), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_medium_poly_right_hand_closed), - GEO_CLOSE_NODE(), - GEO_HELD_OBJECT(0x00, 0, 0, 0, geo_switch_mario_hand_grab_pos), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, mario_right_hand_open), - GEO_OPEN_NODE(), - GEO_HELD_OBJECT(0x00, 0, 0, 0, geo_switch_mario_hand_grab_pos), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, mario_right_hand_peace), // here we go hand - GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, mario_right_hand_cap), - GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, mario_right_hand_cap), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, mario_right_hand_cap_wings), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_SWITCH_CASE(0, geo_switch_mario_hand), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ASM(0, geo_mario_hand_foot_scaler), + GEO_SCALE(0x00, 65536), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_medium_poly_right_hand_closed), + GEO_CLOSE_NODE(), + GEO_HELD_OBJECT(0x00, 0, 0, 0, geo_switch_mario_hand_grab_pos), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, mario_right_hand_open), + GEO_OPEN_NODE(), + GEO_HELD_OBJECT(0x00, 0, 0, 0, geo_switch_mario_hand_grab_pos), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, mario_right_hand_peace), // here we go hand + GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, mario_right_hand_cap), + GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, mario_right_hand_cap), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, mario_right_hand_cap_wings), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x17000818 const GeoLayout mario_geo_medium_poly_body[] = { - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, mario_medium_poly_butt), // starts sharing solid color with mario_torso (blue) - GEO_OPEN_NODE(), - GEO_ASM(0, geo_move_mario_part_from_parent), - GEO_ASM(0, geo_mario_tilt_torso), - GEO_ROTATION_NODE(0x00, 0, 0, 0), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 68, 0, 0, mario_medium_poly_torso), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, mario_medium_poly_butt), // starts sharing solid color with mario_torso (blue) + GEO_OPEN_NODE(), + GEO_ASM(0, geo_move_mario_part_from_parent), + GEO_ASM(0, geo_mario_tilt_torso), + GEO_ROTATION_NODE(0x00, 0, 0, 0), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 87, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_BRANCH(1, mario_geo_face_and_wings), // stops sharing because faces has its own dl - medium poly mario uses high poly face - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 67, -10, 79, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, mario_medium_poly_left_arm), // starts sharing solid color with mario_left_forearm (red) - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 65, 0, 0, mario_medium_poly_left_forearm_shared_dl), - GEO_OPEN_NODE(), - GEO_BRANCH(1, mario_geo_medium_poly_left_hand), // stops sharing because hand has its solid color (white) - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 68, -10, -79, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, mario_medium_poly_right_arm), // starts sharing solid color of his dl with mario_right_forearm (red) - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 65, 0, 0, mario_medium_poly_right_forearm_shared_dl), - GEO_OPEN_NODE(), - GEO_BRANCH(1, mario_geo_medium_poly_right_hand), // stops sharing because hand has its solid color (white) - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 68, 0, 0, mario_medium_poly_torso), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 87, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_BRANCH(1, mario_geo_face_and_wings), // stops sharing because faces has its own dl - medium poly mario uses high poly face + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 67, -10, 79, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, mario_medium_poly_left_arm), // starts sharing solid color with mario_left_forearm (red) + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 65, 0, 0, mario_medium_poly_left_forearm_shared_dl), + GEO_OPEN_NODE(), + GEO_BRANCH(1, mario_geo_medium_poly_left_hand), // stops sharing because hand has its solid color (white) + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 68, -10, -79, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, mario_medium_poly_right_arm), // starts sharing solid color of his dl with mario_right_forearm (red) + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 65, 0, 0, mario_medium_poly_right_forearm_shared_dl), + GEO_OPEN_NODE(), + GEO_BRANCH(1, mario_geo_medium_poly_right_hand), // stops sharing because hand has its solid color (white) + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 13, -8, 42, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, mario_medium_poly_left_thigh), // starts sharing solid color of his dl with mario_left_leg (blue) + GEO_ANIMATED_PART(LAYER_OPAQUE, 13, -8, 42, NULL), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 89, 0, 0, mario_medium_poly_left_leg_shared_dl), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 67, 0, 0, mario_medium_poly_left_foot), // stops sharing because foot has its solid color (brown) - GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, mario_medium_poly_left_thigh), // starts sharing solid color of his dl with mario_left_leg (blue) + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 89, 0, 0, mario_medium_poly_left_leg_shared_dl), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 67, 0, 0, mario_medium_poly_left_foot), // stops sharing because foot has its solid color (brown) + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 13, -8, -42, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, mario_medium_poly_right_thigh), // starts sharing solid color of his dl with mario_left_leg (blue) + GEO_ANIMATED_PART(LAYER_OPAQUE, 13, -8, -42, NULL), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 89, 0, 0, mario_medium_poly_right_leg_shared_dl), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 67, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ASM(2, geo_mario_hand_foot_scaler), - GEO_SCALE(0x00, 65536), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_medium_poly_right_foot), // stops sharing because foot has its solid color (brown) - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, mario_medium_poly_right_thigh), // starts sharing solid color of his dl with mario_left_leg (blue) + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 89, 0, 0, mario_medium_poly_right_leg_shared_dl), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 67, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ASM(2, geo_mario_hand_foot_scaler), + GEO_SCALE(0x00, 65536), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_medium_poly_right_foot), // stops sharing because foot has its solid color (brown) + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x170009D4 const GeoLayout mario_geo_low_poly_face_and_wings[] = { - GEO_ASM(0, geo_mario_head_rotation), - GEO_ROTATION_NODE(0x00, 0, 0, 0), - GEO_OPEN_NODE(), - GEO_SWITCH_CASE(0, geo_switch_mario_cap_on_off), - GEO_OPEN_NODE(), - GEO_SWITCH_CASE(0, geo_switch_mario_eyes), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_low_poly_cap_on_eyes_front), - GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_low_poly_cap_on_eyes_half_closed), - GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_low_poly_cap_on_eyes_closed), - GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_low_poly_cap_on_eyes_right), // unused - GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_low_poly_cap_on_eyes_left), // unused - GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_low_poly_cap_on_eyes_up), // unused - GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_low_poly_cap_on_eyes_down), // unused - GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_low_poly_cap_on_eyes_dead), - GEO_CLOSE_NODE(), - GEO_SWITCH_CASE(0, geo_switch_mario_eyes), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_low_poly_cap_off_eyes_front), - GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_low_poly_cap_off_eyes_half_closed), - GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_low_poly_cap_off_eyes_closed), - GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_low_poly_cap_off_eyes_right), // unused - GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_low_poly_cap_off_eyes_left), // unused - GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_low_poly_cap_off_eyes_up), // unused - GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_low_poly_cap_off_eyes_down), // unused - GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_low_poly_cap_off_eyes_dead), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_TRANSLATE_ROTATE(0, 142, -51, -126, 22, -40, -135), - GEO_OPEN_NODE(), - GEO_ASM(0, geo_mario_rotate_wing_cap_wings), - GEO_ROTATION_NODE(0x00, 0, 0, 0), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, mario_cap_wings), // left - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_TRANSLATE_ROTATE(0, 142, -51, 126, -22, 40, -135), - GEO_OPEN_NODE(), - GEO_ASM(1, geo_mario_rotate_wing_cap_wings), - GEO_ROTATION_NODE(0x00, 0, 0, 0), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, mario_cap_wings), // right - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_ASM(0, geo_mario_head_rotation), + GEO_ROTATION_NODE(0x00, 0, 0, 0), + GEO_OPEN_NODE(), + GEO_SWITCH_CASE(0, geo_switch_mario_cap_on_off), + GEO_OPEN_NODE(), + GEO_SWITCH_CASE(0, geo_switch_mario_eyes), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_low_poly_cap_on_eyes_front), + GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_low_poly_cap_on_eyes_half_closed), + GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_low_poly_cap_on_eyes_closed), + GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_low_poly_cap_on_eyes_right), // unused + GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_low_poly_cap_on_eyes_left), // unused + GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_low_poly_cap_on_eyes_up), // unused + GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_low_poly_cap_on_eyes_down), // unused + GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_low_poly_cap_on_eyes_dead), + GEO_CLOSE_NODE(), + GEO_SWITCH_CASE(0, geo_switch_mario_eyes), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_low_poly_cap_off_eyes_front), + GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_low_poly_cap_off_eyes_half_closed), + GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_low_poly_cap_off_eyes_closed), + GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_low_poly_cap_off_eyes_right), // unused + GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_low_poly_cap_off_eyes_left), // unused + GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_low_poly_cap_off_eyes_up), // unused + GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_low_poly_cap_off_eyes_down), // unused + GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_low_poly_cap_off_eyes_dead), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_TRANSLATE_ROTATE(0, 142, -51, -126, 22, -40, -135), + GEO_OPEN_NODE(), + GEO_ASM(0, geo_mario_rotate_wing_cap_wings), + GEO_ROTATION_NODE(0x00, 0, 0, 0), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, mario_cap_wings), // left + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_TRANSLATE_ROTATE(0, 142, -51, 126, -22, 40, -135), + GEO_OPEN_NODE(), + GEO_ASM(1, geo_mario_rotate_wing_cap_wings), + GEO_ROTATION_NODE(0x00, 0, 0, 0), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, mario_cap_wings), // right + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x17000B10 const GeoLayout mario_geo_low_poly_left_hand[] = { - GEO_SWITCH_CASE(1, geo_switch_mario_hand), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ASM(1, geo_mario_hand_foot_scaler), - GEO_SCALE(0x00, 65536), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_low_poly_left_hand_closed), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, mario_left_hand_open), - GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, mario_low_poly_left_hand_closed), - GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, mario_low_poly_left_hand_closed), - GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, mario_low_poly_left_hand_closed), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_SWITCH_CASE(1, geo_switch_mario_hand), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ASM(1, geo_mario_hand_foot_scaler), + GEO_SCALE(0x00, 65536), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_low_poly_left_hand_closed), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, mario_left_hand_open), + GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, mario_low_poly_left_hand_closed), + GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, mario_low_poly_left_hand_closed), + GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, mario_low_poly_left_hand_closed), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x17000B88 const GeoLayout mario_geo_low_poly_right_hand[] = { - GEO_SWITCH_CASE(0, geo_switch_mario_hand), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ASM(0, geo_mario_hand_foot_scaler), - GEO_SCALE(0x00, 65536), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_low_poly_right_hand_closed), - GEO_CLOSE_NODE(), - GEO_HELD_OBJECT(0x00, 0, 0, 0, geo_switch_mario_hand_grab_pos), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, mario_right_hand_open), - GEO_OPEN_NODE(), - GEO_HELD_OBJECT(0x00, 0, 0, 0, geo_switch_mario_hand_grab_pos), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, mario_right_hand_peace), // here we go hand - GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, mario_right_hand_cap), - GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, mario_right_hand_cap), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, mario_right_hand_cap_wings), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_SWITCH_CASE(0, geo_switch_mario_hand), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ASM(0, geo_mario_hand_foot_scaler), + GEO_SCALE(0x00, 65536), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_low_poly_right_hand_closed), + GEO_CLOSE_NODE(), + GEO_HELD_OBJECT(0x00, 0, 0, 0, geo_switch_mario_hand_grab_pos), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, mario_right_hand_open), + GEO_OPEN_NODE(), + GEO_HELD_OBJECT(0x00, 0, 0, 0, geo_switch_mario_hand_grab_pos), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, mario_right_hand_peace), // here we go hand + GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, mario_right_hand_cap), + GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, mario_right_hand_cap), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, mario_right_hand_cap_wings), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x17000C30 const GeoLayout mario_geo_low_poly_body[] = { - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, mario_low_poly_butt), // starts sharing solid color with mario_torso (blue) - GEO_OPEN_NODE(), - GEO_ASM(0, geo_move_mario_part_from_parent), - GEO_ASM(0, geo_mario_tilt_torso), - GEO_ROTATION_NODE(0x00, 0, 0, 0), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 68, 0, 0, mario_low_poly_torso), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, mario_low_poly_butt), // starts sharing solid color with mario_torso (blue) + GEO_OPEN_NODE(), + GEO_ASM(0, geo_move_mario_part_from_parent), + GEO_ASM(0, geo_mario_tilt_torso), + GEO_ROTATION_NODE(0x00, 0, 0, 0), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 87, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_BRANCH(1, mario_geo_low_poly_face_and_wings), // stops sharing because faces has its own dl - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 67, -10, 79, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, mario_low_poly_left_arm), // starts sharing solid color with mario_left_forearm (red) - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 65, 0, 0, mario_low_poly_left_forearm_shared_dl), - GEO_OPEN_NODE(), - GEO_BRANCH(1, mario_geo_low_poly_left_hand), // stops sharing because hand has its solid color (white) - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 68, -10, -79, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, mario_low_poly_right_arm), // starts sharing solid color of his dl with mario_right_forearm (red) - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 65, 0, 0, mario_low_poly_right_forearm_shared_dl), - GEO_OPEN_NODE(), - GEO_BRANCH(1, mario_geo_low_poly_right_hand), // stops sharing because hand has its solid color (white) - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 68, 0, 0, mario_low_poly_torso), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 87, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_BRANCH(1, mario_geo_low_poly_face_and_wings), // stops sharing because faces has its own dl + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 67, -10, 79, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, mario_low_poly_left_arm), // starts sharing solid color with mario_left_forearm (red) + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 65, 0, 0, mario_low_poly_left_forearm_shared_dl), + GEO_OPEN_NODE(), + GEO_BRANCH(1, mario_geo_low_poly_left_hand), // stops sharing because hand has its solid color (white) + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 68, -10, -79, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, mario_low_poly_right_arm), // starts sharing solid color of his dl with mario_right_forearm (red) + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 65, 0, 0, mario_low_poly_right_forearm_shared_dl), + GEO_OPEN_NODE(), + GEO_BRANCH(1, mario_geo_low_poly_right_hand), // stops sharing because hand has its solid color (white) + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 13, -8, 42, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, mario_low_poly_left_thigh), // starts sharing solid color of his dl with mario_left_leg (blue) + GEO_ANIMATED_PART(LAYER_OPAQUE, 13, -8, 42, NULL), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 89, 0, 0, mario_low_poly_left_leg_shared_dl), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 67, 0, 0, mario_low_poly_left_foot), // stops sharing because foot has its solid color (brown) - GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, mario_low_poly_left_thigh), // starts sharing solid color of his dl with mario_left_leg (blue) + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 89, 0, 0, mario_low_poly_left_leg_shared_dl), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 67, 0, 0, mario_low_poly_left_foot), // stops sharing because foot has its solid color (brown) + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 13, -8, -42, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, mario_low_poly_right_thigh), // starts sharing solid color of his dl with mario_left_leg (blue) + GEO_ANIMATED_PART(LAYER_OPAQUE, 13, -8, -42, NULL), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 89, 0, 0, mario_low_poly_right_leg_shared_dl), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 67, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ASM(2, geo_mario_hand_foot_scaler), - GEO_SCALE(0x00, 65536), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_low_poly_right_foot), // stops sharing because foot has its solid color (brown) - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, mario_low_poly_right_thigh), // starts sharing solid color of his dl with mario_left_leg (blue) + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 89, 0, 0, mario_low_poly_right_leg_shared_dl), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 67, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ASM(2, geo_mario_hand_foot_scaler), + GEO_SCALE(0x00, 65536), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_low_poly_right_foot), // stops sharing because foot has its solid color (brown) + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // Vanish Mario Geo // 0x17000DEC const GeoLayout mario_vanish_geo_face_and_wings[] = { - GEO_ASM(0, geo_mario_head_rotation), - GEO_ROTATION_NODE(0x00, 0, 0, 0), - GEO_OPEN_NODE(), - GEO_SWITCH_CASE(0, geo_switch_mario_cap_on_off), - GEO_OPEN_NODE(), - GEO_SWITCH_CASE(0, geo_switch_mario_eyes), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_cap_on_eyes_front), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_cap_on_eyes_half_closed), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_cap_on_eyes_closed), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_cap_on_eyes_right), // unused - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_cap_on_eyes_left), // unused - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_cap_on_eyes_up), // unused - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_cap_on_eyes_down), // unused - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_cap_on_eyes_dead), - GEO_CLOSE_NODE(), - GEO_SWITCH_CASE(0, geo_switch_mario_eyes), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_cap_off_eyes_front), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_cap_off_eyes_half_closed), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_cap_off_eyes_closed), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_cap_off_eyes_right), // unused - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_cap_off_eyes_left), // unused - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_cap_off_eyes_up), // unused - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_cap_off_eyes_down), // unused - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_cap_off_eyes_dead), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_TRANSLATE_ROTATE(0, 142, -51, -126, 22, -40, -135), - GEO_OPEN_NODE(), - GEO_ASM(0, geo_mario_rotate_wing_cap_wings), - GEO_ROTATION_NODE(0x00, 0, 0, 0), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_cap_wings_transparent), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_TRANSLATE_ROTATE(0, 142, -51, 126, -22, 40, -135), - GEO_OPEN_NODE(), - GEO_ASM(1, geo_mario_rotate_wing_cap_wings), - GEO_ROTATION_NODE(0x00, 0, 0, 0), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_cap_wings_transparent), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_ASM(0, geo_mario_head_rotation), + GEO_ROTATION_NODE(0x00, 0, 0, 0), + GEO_OPEN_NODE(), + GEO_SWITCH_CASE(0, geo_switch_mario_cap_on_off), + GEO_OPEN_NODE(), + GEO_SWITCH_CASE(0, geo_switch_mario_eyes), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_cap_on_eyes_front), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_cap_on_eyes_half_closed), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_cap_on_eyes_closed), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_cap_on_eyes_right), // unused + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_cap_on_eyes_left), // unused + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_cap_on_eyes_up), // unused + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_cap_on_eyes_down), // unused + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_cap_on_eyes_dead), + GEO_CLOSE_NODE(), + GEO_SWITCH_CASE(0, geo_switch_mario_eyes), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_cap_off_eyes_front), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_cap_off_eyes_half_closed), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_cap_off_eyes_closed), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_cap_off_eyes_right), // unused + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_cap_off_eyes_left), // unused + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_cap_off_eyes_up), // unused + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_cap_off_eyes_down), // unused + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_cap_off_eyes_dead), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_TRANSLATE_ROTATE(0, 142, -51, -126, 22, -40, -135), + GEO_OPEN_NODE(), + GEO_ASM(0, geo_mario_rotate_wing_cap_wings), + GEO_ROTATION_NODE(0x00, 0, 0, 0), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_cap_wings_transparent), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_TRANSLATE_ROTATE(0, 142, -51, 126, -22, 40, -135), + GEO_OPEN_NODE(), + GEO_ASM(1, geo_mario_rotate_wing_cap_wings), + GEO_ROTATION_NODE(0x00, 0, 0, 0), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_cap_wings_transparent), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x17000F28 const GeoLayout mario_vanish_geo_left_hand[] = { - GEO_SWITCH_CASE(1, geo_switch_mario_hand), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ASM(1, geo_mario_hand_foot_scaler), - GEO_SCALE(0x00, 65536), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_left_hand_closed), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, mario_left_hand_open), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, mario_left_hand_closed), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, mario_left_hand_closed), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, mario_left_hand_closed), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_SWITCH_CASE(1, geo_switch_mario_hand), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ASM(1, geo_mario_hand_foot_scaler), + GEO_SCALE(0x00, 65536), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_left_hand_closed), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, mario_left_hand_open), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, mario_left_hand_closed), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, mario_left_hand_closed), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, mario_left_hand_closed), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x17000FA0 const GeoLayout mario_vanish_geo_right_hand[] = { - GEO_SWITCH_CASE(0, geo_switch_mario_hand), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ASM(0, geo_mario_hand_foot_scaler), - GEO_SCALE(0x00, 65536), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_right_hand_closed), - GEO_CLOSE_NODE(), - GEO_HELD_OBJECT(0x00, 0, 0, 0, geo_switch_mario_hand_grab_pos), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, mario_right_hand_open), - GEO_OPEN_NODE(), - GEO_HELD_OBJECT(0x00, 0, 0, 0, geo_switch_mario_hand_grab_pos), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, mario_right_hand_peace), // here we go hand - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, mario_right_hand_cap), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, mario_right_hand_cap), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, mario_right_hand_cap_wings), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_SWITCH_CASE(0, geo_switch_mario_hand), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ASM(0, geo_mario_hand_foot_scaler), + GEO_SCALE(0x00, 65536), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_right_hand_closed), + GEO_CLOSE_NODE(), + GEO_HELD_OBJECT(0x00, 0, 0, 0, geo_switch_mario_hand_grab_pos), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, mario_right_hand_open), + GEO_OPEN_NODE(), + GEO_HELD_OBJECT(0x00, 0, 0, 0, geo_switch_mario_hand_grab_pos), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, mario_right_hand_peace), // here we go hand + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, mario_right_hand_cap), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, mario_right_hand_cap), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, mario_right_hand_cap_wings), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // Same rule body as Normal Mario // 0x17001048 const GeoLayout mario_vanish_geo_body[] = { - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, mario_butt), - GEO_OPEN_NODE(), - GEO_ASM(0, geo_move_mario_part_from_parent), - GEO_ASM(0, geo_mario_tilt_torso), - GEO_ROTATION_NODE(0x00, 0, 0, 0), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 68, 0, 0, mario_torso), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, mario_butt), + GEO_OPEN_NODE(), + GEO_ASM(0, geo_move_mario_part_from_parent), + GEO_ASM(0, geo_mario_tilt_torso), + GEO_ROTATION_NODE(0x00, 0, 0, 0), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 87, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_BRANCH(1, mario_vanish_geo_face_and_wings), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 67, -10, 79, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, mario_left_arm), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 65, 0, 0, mario_left_forearm_shared_dl), - GEO_OPEN_NODE(), - GEO_BRANCH(1, mario_vanish_geo_left_hand), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 68, -10, -79, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, mario_right_arm), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 65, 0, 0, mario_right_forearm_shared_dl), - GEO_OPEN_NODE(), - GEO_BRANCH(1, mario_vanish_geo_right_hand), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 68, 0, 0, mario_torso), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 87, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_BRANCH(1, mario_vanish_geo_face_and_wings), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 67, -10, 79, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, mario_left_arm), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 65, 0, 0, mario_left_forearm_shared_dl), + GEO_OPEN_NODE(), + GEO_BRANCH(1, mario_vanish_geo_left_hand), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 68, -10, -79, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, mario_right_arm), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 65, 0, 0, mario_right_forearm_shared_dl), + GEO_OPEN_NODE(), + GEO_BRANCH(1, mario_vanish_geo_right_hand), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 13, -8, 42, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, mario_left_thigh), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 13, -8, 42, NULL), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 89, 0, 0, mario_left_leg_shared_dl), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 67, 0, 0, mario_left_foot), - GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, mario_left_thigh), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 89, 0, 0, mario_left_leg_shared_dl), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 67, 0, 0, mario_left_foot), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 13, -8, -42, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, mario_right_thigh), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 13, -8, -42, NULL), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 89, 0, 0, mario_right_leg_shared_dl), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 67, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ASM(2, geo_mario_hand_foot_scaler), - GEO_SCALE(0x00, 65536), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_right_foot), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, mario_right_thigh), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 89, 0, 0, mario_right_leg_shared_dl), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 67, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ASM(2, geo_mario_hand_foot_scaler), + GEO_SCALE(0x00, 65536), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_right_foot), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x17001204 const GeoLayout mario_vanish_geo_medium_poly_left_hand[] = { - GEO_SWITCH_CASE(1, geo_switch_mario_hand), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ASM(1, geo_mario_hand_foot_scaler), - GEO_SCALE(0x00, 65536), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_medium_poly_left_hand_closed), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, mario_left_hand_open), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, mario_medium_poly_left_hand_closed), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, mario_medium_poly_left_hand_closed), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, mario_medium_poly_left_hand_closed), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_SWITCH_CASE(1, geo_switch_mario_hand), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ASM(1, geo_mario_hand_foot_scaler), + GEO_SCALE(0x00, 65536), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_medium_poly_left_hand_closed), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, mario_left_hand_open), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, mario_medium_poly_left_hand_closed), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, mario_medium_poly_left_hand_closed), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, mario_medium_poly_left_hand_closed), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x1700127C const GeoLayout mario_vanish_geo_medium_poly_right_hand[] = { - GEO_SWITCH_CASE(0, geo_switch_mario_hand), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ASM(0, geo_mario_hand_foot_scaler), - GEO_SCALE(0x00, 65536), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_medium_poly_right_hand_closed), - GEO_CLOSE_NODE(), - GEO_HELD_OBJECT(0x00, 0, 0, 0, geo_switch_mario_hand_grab_pos), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, mario_right_hand_open), - GEO_OPEN_NODE(), - GEO_HELD_OBJECT(0x00, 0, 0, 0, geo_switch_mario_hand_grab_pos), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, mario_right_hand_peace), // here we go hand - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, mario_right_hand_cap), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, mario_right_hand_cap), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, mario_right_hand_cap_wings), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_SWITCH_CASE(0, geo_switch_mario_hand), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ASM(0, geo_mario_hand_foot_scaler), + GEO_SCALE(0x00, 65536), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_medium_poly_right_hand_closed), + GEO_CLOSE_NODE(), + GEO_HELD_OBJECT(0x00, 0, 0, 0, geo_switch_mario_hand_grab_pos), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, mario_right_hand_open), + GEO_OPEN_NODE(), + GEO_HELD_OBJECT(0x00, 0, 0, 0, geo_switch_mario_hand_grab_pos), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, mario_right_hand_peace), // here we go hand + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, mario_right_hand_cap), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, mario_right_hand_cap), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, mario_right_hand_cap_wings), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x17001324 const GeoLayout mario_vanish_geo_medium_poly_body[] = { - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, mario_medium_poly_butt), - GEO_OPEN_NODE(), - GEO_ASM(0, geo_move_mario_part_from_parent), - GEO_ASM(0, geo_mario_tilt_torso), - GEO_ROTATION_NODE(0x00, 0, 0, 0), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 68, 0, 0, mario_medium_poly_torso), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, mario_medium_poly_butt), + GEO_OPEN_NODE(), + GEO_ASM(0, geo_move_mario_part_from_parent), + GEO_ASM(0, geo_mario_tilt_torso), + GEO_ROTATION_NODE(0x00, 0, 0, 0), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 87, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_BRANCH(1, mario_vanish_geo_face_and_wings), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 67, -10, 79, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, mario_medium_poly_left_arm), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 65, 0, 0, mario_medium_poly_left_forearm_shared_dl), - GEO_OPEN_NODE(), - GEO_BRANCH(1, mario_vanish_geo_medium_poly_left_hand), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 68, -10, -79, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, mario_medium_poly_right_arm), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 65, 0, 0, mario_medium_poly_right_forearm_shared_dl), - GEO_OPEN_NODE(), - GEO_BRANCH(1, mario_vanish_geo_medium_poly_right_hand), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 68, 0, 0, mario_medium_poly_torso), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 87, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_BRANCH(1, mario_vanish_geo_face_and_wings), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 67, -10, 79, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, mario_medium_poly_left_arm), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 65, 0, 0, mario_medium_poly_left_forearm_shared_dl), + GEO_OPEN_NODE(), + GEO_BRANCH(1, mario_vanish_geo_medium_poly_left_hand), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 68, -10, -79, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, mario_medium_poly_right_arm), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 65, 0, 0, mario_medium_poly_right_forearm_shared_dl), + GEO_OPEN_NODE(), + GEO_BRANCH(1, mario_vanish_geo_medium_poly_right_hand), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 13, -8, 42, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, mario_medium_poly_left_thigh), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 13, -8, 42, NULL), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 89, 0, 0, mario_medium_poly_left_leg_shared_dl), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 67, 0, 0, mario_medium_poly_left_foot), - GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, mario_medium_poly_left_thigh), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 89, 0, 0, mario_medium_poly_left_leg_shared_dl), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 67, 0, 0, mario_medium_poly_left_foot), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 13, -8, -42, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, mario_medium_poly_right_thigh), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 13, -8, -42, NULL), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 89, 0, 0, mario_medium_poly_right_leg_shared_dl), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 67, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ASM(2, geo_mario_hand_foot_scaler), - GEO_SCALE(0x00, 65536), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_medium_poly_right_foot), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, mario_medium_poly_right_thigh), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 89, 0, 0, mario_medium_poly_right_leg_shared_dl), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 67, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ASM(2, geo_mario_hand_foot_scaler), + GEO_SCALE(0x00, 65536), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_medium_poly_right_foot), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x170014E0 const GeoLayout mario_vanish_geo_low_poly_face_and_wings[] = { - GEO_ASM(0, geo_mario_head_rotation), - GEO_ROTATION_NODE(0x00, 0, 0, 0), - GEO_OPEN_NODE(), - GEO_SWITCH_CASE(0, geo_switch_mario_cap_on_off), - GEO_OPEN_NODE(), - GEO_SWITCH_CASE(0, geo_switch_mario_eyes), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_low_poly_cap_on_eyes_front), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_low_poly_cap_on_eyes_half_closed), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_low_poly_cap_on_eyes_closed), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_low_poly_cap_on_eyes_right), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_low_poly_cap_on_eyes_left), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_low_poly_cap_on_eyes_up), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_low_poly_cap_on_eyes_down), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_low_poly_cap_on_eyes_dead), - GEO_CLOSE_NODE(), - GEO_SWITCH_CASE(0, geo_switch_mario_eyes), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_low_poly_cap_off_eyes_front), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_low_poly_cap_off_eyes_half_closed), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_low_poly_cap_off_eyes_closed), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_low_poly_cap_off_eyes_right), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_low_poly_cap_off_eyes_left), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_low_poly_cap_off_eyes_up), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_low_poly_cap_off_eyes_down), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_low_poly_cap_off_eyes_dead), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_TRANSLATE_ROTATE(0, 142, -51, -126, 22, -40, -135), - GEO_OPEN_NODE(), - GEO_ASM(0, geo_mario_rotate_wing_cap_wings), - GEO_ROTATION_NODE(0x00, 0, 0, 0), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_cap_wings_transparent), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_TRANSLATE_ROTATE(0, 142, -51, 126, -22, 40, -135), - GEO_OPEN_NODE(), - GEO_ASM(1, geo_mario_rotate_wing_cap_wings), - GEO_ROTATION_NODE(0x00, 0, 0, 0), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_cap_wings_transparent), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_ASM(0, geo_mario_head_rotation), + GEO_ROTATION_NODE(0x00, 0, 0, 0), + GEO_OPEN_NODE(), + GEO_SWITCH_CASE(0, geo_switch_mario_cap_on_off), + GEO_OPEN_NODE(), + GEO_SWITCH_CASE(0, geo_switch_mario_eyes), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_low_poly_cap_on_eyes_front), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_low_poly_cap_on_eyes_half_closed), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_low_poly_cap_on_eyes_closed), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_low_poly_cap_on_eyes_right), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_low_poly_cap_on_eyes_left), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_low_poly_cap_on_eyes_up), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_low_poly_cap_on_eyes_down), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_low_poly_cap_on_eyes_dead), + GEO_CLOSE_NODE(), + GEO_SWITCH_CASE(0, geo_switch_mario_eyes), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_low_poly_cap_off_eyes_front), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_low_poly_cap_off_eyes_half_closed), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_low_poly_cap_off_eyes_closed), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_low_poly_cap_off_eyes_right), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_low_poly_cap_off_eyes_left), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_low_poly_cap_off_eyes_up), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_low_poly_cap_off_eyes_down), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_low_poly_cap_off_eyes_dead), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_TRANSLATE_ROTATE(0, 142, -51, -126, 22, -40, -135), + GEO_OPEN_NODE(), + GEO_ASM(0, geo_mario_rotate_wing_cap_wings), + GEO_ROTATION_NODE(0x00, 0, 0, 0), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_cap_wings_transparent), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_TRANSLATE_ROTATE(0, 142, -51, 126, -22, 40, -135), + GEO_OPEN_NODE(), + GEO_ASM(1, geo_mario_rotate_wing_cap_wings), + GEO_ROTATION_NODE(0x00, 0, 0, 0), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_cap_wings_transparent), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x1700161C const GeoLayout mario_vanish_geo_low_poly_left_hand[] = { - GEO_SWITCH_CASE(1, geo_switch_mario_hand), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ASM(1, geo_mario_hand_foot_scaler), - GEO_SCALE(0x00, 65536), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_low_poly_left_hand_closed), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, mario_left_hand_open), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, mario_low_poly_left_hand_closed), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, mario_low_poly_left_hand_closed), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, mario_low_poly_left_hand_closed), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_SWITCH_CASE(1, geo_switch_mario_hand), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ASM(1, geo_mario_hand_foot_scaler), + GEO_SCALE(0x00, 65536), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_low_poly_left_hand_closed), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, mario_left_hand_open), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, mario_low_poly_left_hand_closed), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, mario_low_poly_left_hand_closed), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, mario_low_poly_left_hand_closed), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x17001694 const GeoLayout mario_vanish_geo_low_poly_right_hand[] = { - GEO_SWITCH_CASE(0, geo_switch_mario_hand), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ASM(0, geo_mario_hand_foot_scaler), - GEO_SCALE(0x00, 65536), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_low_poly_right_hand_closed), - GEO_CLOSE_NODE(), - GEO_HELD_OBJECT(0x00, 0, 0, 0, geo_switch_mario_hand_grab_pos), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, mario_right_hand_open), - GEO_OPEN_NODE(), - GEO_HELD_OBJECT(0x00, 0, 0, 0, geo_switch_mario_hand_grab_pos), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, mario_right_hand_peace), // here we go hand - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, mario_right_hand_cap), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, mario_right_hand_cap), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, mario_right_hand_cap_wings), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_SWITCH_CASE(0, geo_switch_mario_hand), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ASM(0, geo_mario_hand_foot_scaler), + GEO_SCALE(0x00, 65536), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_low_poly_right_hand_closed), + GEO_CLOSE_NODE(), + GEO_HELD_OBJECT(0x00, 0, 0, 0, geo_switch_mario_hand_grab_pos), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, mario_right_hand_open), + GEO_OPEN_NODE(), + GEO_HELD_OBJECT(0x00, 0, 0, 0, geo_switch_mario_hand_grab_pos), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, mario_right_hand_peace), // here we go hand + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, mario_right_hand_cap), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, mario_right_hand_cap), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, mario_right_hand_cap_wings), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x1700173C const GeoLayout mario_vanish_geo_low_poly_body[] = { - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, mario_low_poly_butt), - GEO_OPEN_NODE(), - GEO_ASM(0, geo_move_mario_part_from_parent), - GEO_ASM(0, geo_mario_tilt_torso), - GEO_ROTATION_NODE(0x00, 0, 0, 0), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 68, 0, 0, mario_low_poly_torso), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, mario_low_poly_butt), + GEO_OPEN_NODE(), + GEO_ASM(0, geo_move_mario_part_from_parent), + GEO_ASM(0, geo_mario_tilt_torso), + GEO_ROTATION_NODE(0x00, 0, 0, 0), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 87, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_BRANCH(1, mario_vanish_geo_low_poly_face_and_wings), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 67, -10, 79, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, mario_low_poly_left_arm), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 65, 0, 0, mario_low_poly_left_forearm_shared_dl), - GEO_OPEN_NODE(), - GEO_BRANCH(1, mario_vanish_geo_low_poly_left_hand), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 68, -10, -79, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, mario_low_poly_right_arm), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 65, 0, 0, mario_low_poly_right_forearm_shared_dl), - GEO_OPEN_NODE(), - GEO_BRANCH(1, mario_vanish_geo_low_poly_right_hand), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 68, 0, 0, mario_low_poly_torso), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 87, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_BRANCH(1, mario_vanish_geo_low_poly_face_and_wings), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 67, -10, 79, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, mario_low_poly_left_arm), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 65, 0, 0, mario_low_poly_left_forearm_shared_dl), + GEO_OPEN_NODE(), + GEO_BRANCH(1, mario_vanish_geo_low_poly_left_hand), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 68, -10, -79, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, mario_low_poly_right_arm), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 65, 0, 0, mario_low_poly_right_forearm_shared_dl), + GEO_OPEN_NODE(), + GEO_BRANCH(1, mario_vanish_geo_low_poly_right_hand), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 13, -8, 42, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, mario_low_poly_left_thigh), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 13, -8, 42, NULL), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 89, 0, 0, mario_low_poly_left_leg_shared_dl), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 67, 0, 0, mario_low_poly_left_foot), - GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, mario_low_poly_left_thigh), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 89, 0, 0, mario_low_poly_left_leg_shared_dl), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 67, 0, 0, mario_low_poly_left_foot), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 13, -8, -42, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, mario_low_poly_right_thigh), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 13, -8, -42, NULL), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 89, 0, 0, mario_low_poly_right_leg_shared_dl), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 67, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ASM(2, geo_mario_hand_foot_scaler), - GEO_SCALE(0x00, 65536), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_low_poly_right_foot), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, mario_low_poly_right_thigh), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 89, 0, 0, mario_low_poly_right_leg_shared_dl), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 67, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ASM(2, geo_mario_hand_foot_scaler), + GEO_SCALE(0x00, 65536), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_low_poly_right_foot), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // Metal Mario Geo // 0x170018F8 const GeoLayout mario_metal_geo_face_and_wings[] = { - GEO_ASM(0, geo_mario_head_rotation), - GEO_ROTATION_NODE(0x00, 0, 0, 0), - GEO_OPEN_NODE(), - GEO_SWITCH_CASE(0, geo_switch_mario_cap_on_off), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_metal_cap_on_shared_dl), - GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_metal_cap_off_shared_dl), - GEO_CLOSE_NODE(), - GEO_TRANSLATE_ROTATE(0, 142, -51, -126, 22, -40, -135), - GEO_OPEN_NODE(), - GEO_ASM(0, geo_mario_rotate_wing_cap_wings), - GEO_ROTATION_NODE(0x00, 0, 0, 0), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, mario_metal_cap_wings), // left - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_TRANSLATE_ROTATE(0, 142, -51, 126, -22, 40, -135), - GEO_OPEN_NODE(), - GEO_ASM(1, geo_mario_rotate_wing_cap_wings), - GEO_ROTATION_NODE(0x00, 0, 0, 0), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, mario_metal_cap_wings), // right - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_ASM(0, geo_mario_head_rotation), + GEO_ROTATION_NODE(0x00, 0, 0, 0), + GEO_OPEN_NODE(), + GEO_SWITCH_CASE(0, geo_switch_mario_cap_on_off), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_metal_cap_on_shared_dl), + GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_metal_cap_off_shared_dl), + GEO_CLOSE_NODE(), + GEO_TRANSLATE_ROTATE(0, 142, -51, -126, 22, -40, -135), + GEO_OPEN_NODE(), + GEO_ASM(0, geo_mario_rotate_wing_cap_wings), + GEO_ROTATION_NODE(0x00, 0, 0, 0), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, mario_metal_cap_wings), // left + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_TRANSLATE_ROTATE(0, 142, -51, 126, -22, 40, -135), + GEO_OPEN_NODE(), + GEO_ASM(1, geo_mario_rotate_wing_cap_wings), + GEO_ROTATION_NODE(0x00, 0, 0, 0), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, mario_metal_cap_wings), // right + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x170019A4 const GeoLayout mario_metal_geo_left_hand[] = { - GEO_SWITCH_CASE(1, geo_switch_mario_hand), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ASM(1, geo_mario_hand_foot_scaler), - GEO_SCALE(0x00, 65536), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_left_hand_closed_shared_dl), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, mario_left_hand_open_shared_dl), - GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, mario_left_hand_closed_shared_dl), - GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, mario_left_hand_closed_shared_dl), - GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, mario_left_hand_closed_shared_dl), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_SWITCH_CASE(1, geo_switch_mario_hand), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ASM(1, geo_mario_hand_foot_scaler), + GEO_SCALE(0x00, 65536), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_left_hand_closed_shared_dl), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, mario_left_hand_open_shared_dl), + GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, mario_left_hand_closed_shared_dl), + GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, mario_left_hand_closed_shared_dl), + GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, mario_left_hand_closed_shared_dl), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x17001A1C const GeoLayout mario_metal_geo_right_hand[] = { - GEO_SWITCH_CASE(0, geo_switch_mario_hand), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ASM(0, geo_mario_hand_foot_scaler), - GEO_SCALE(0x00, 65536), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_metal_right_hand_closed), - GEO_CLOSE_NODE(), - GEO_HELD_OBJECT(0x00, 0, 0, 0, geo_switch_mario_hand_grab_pos), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, mario_metal_right_hand_open), - GEO_OPEN_NODE(), - GEO_HELD_OBJECT(0x00, 0, 0, 0, geo_switch_mario_hand_grab_pos), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, mario_right_hand_peace_shared_dl), // here we go hand - GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, mario_metal_right_hand_cap_shared_dl), - GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, mario_metal_right_hand_cap_shared_dl), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, mario_metal_right_hand_cap_shared_dl_wings), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_SWITCH_CASE(0, geo_switch_mario_hand), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ASM(0, geo_mario_hand_foot_scaler), + GEO_SCALE(0x00, 65536), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_metal_right_hand_closed), + GEO_CLOSE_NODE(), + GEO_HELD_OBJECT(0x00, 0, 0, 0, geo_switch_mario_hand_grab_pos), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, mario_metal_right_hand_open), + GEO_OPEN_NODE(), + GEO_HELD_OBJECT(0x00, 0, 0, 0, geo_switch_mario_hand_grab_pos), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, mario_right_hand_peace_shared_dl), // here we go hand + GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, mario_metal_right_hand_cap_shared_dl), + GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, mario_metal_right_hand_cap_shared_dl), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, mario_metal_right_hand_cap_shared_dl_wings), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // A difference from Normal Mario is that the dls after the butt and left thigh shares the metal texture of it, same rule applies to the medium and low poly geos // 0x17001AC4 const GeoLayout mario_metal_geo_body[] = { - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, mario_metal_butt), // starts sharing metal texture with the dls below - GEO_OPEN_NODE(), - GEO_ASM(0, geo_move_mario_part_from_parent), - GEO_ASM(0, geo_mario_tilt_torso), - GEO_ROTATION_NODE(0x00, 0, 0, 0), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 68, 0, 0, mario_metal_torso_shared_dl), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, mario_metal_butt), // starts sharing metal texture with the dls below + GEO_OPEN_NODE(), + GEO_ASM(0, geo_move_mario_part_from_parent), + GEO_ASM(0, geo_mario_tilt_torso), + GEO_ROTATION_NODE(0x00, 0, 0, 0), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 87, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_BRANCH(1, mario_metal_geo_face_and_wings), // unlike normal mario geo, these dls still share the metal texture - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 67, -10, 79, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, mario_left_arm_shared_dl), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 65, 0, 0, mario_left_forearm_shared_dl), - GEO_OPEN_NODE(), - GEO_BRANCH(1, mario_metal_geo_left_hand), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 68, -10, -79, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, mario_right_arm_shared_dl), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 65, 0, 0, mario_right_forearm_shared_dl), - GEO_OPEN_NODE(), - GEO_BRANCH(1, mario_metal_geo_right_hand), // stop sharing because the wing metal cap of it - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 68, 0, 0, mario_metal_torso_shared_dl), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 87, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_BRANCH(1, mario_metal_geo_face_and_wings), // unlike normal mario geo, these dls still share the metal texture + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 67, -10, 79, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, mario_left_arm_shared_dl), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 65, 0, 0, mario_left_forearm_shared_dl), + GEO_OPEN_NODE(), + GEO_BRANCH(1, mario_metal_geo_left_hand), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 68, -10, -79, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, mario_right_arm_shared_dl), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 65, 0, 0, mario_right_forearm_shared_dl), + GEO_OPEN_NODE(), + GEO_BRANCH(1, mario_metal_geo_right_hand), // stop sharing because the wing metal cap of it + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 13, -8, 42, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, mario_metal_left_thigh), // starts sharing metal texture with the dls below + GEO_ANIMATED_PART(LAYER_OPAQUE, 13, -8, 42, NULL), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 89, 0, 0, mario_left_leg_shared_dl), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 67, 0, 0, mario_left_foot_shared_dl), - GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, mario_metal_left_thigh), // starts sharing metal texture with the dls below + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 89, 0, 0, mario_left_leg_shared_dl), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 67, 0, 0, mario_left_foot_shared_dl), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 13, -8, -42, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, mario_right_thigh_shared_dl), + GEO_ANIMATED_PART(LAYER_OPAQUE, 13, -8, -42, NULL), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 89, 0, 0, mario_right_leg_shared_dl), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 67, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ASM(2, geo_mario_hand_foot_scaler), - GEO_SCALE(0x00, 65536), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_metal_right_foot), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, mario_right_thigh_shared_dl), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 89, 0, 0, mario_right_leg_shared_dl), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 67, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ASM(2, geo_mario_hand_foot_scaler), + GEO_SCALE(0x00, 65536), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_metal_right_foot), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x17001C80 const GeoLayout mario_metal_geo_medium_poly_left_hand[] = { - GEO_SWITCH_CASE(1, geo_switch_mario_hand), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ASM(1, geo_mario_hand_foot_scaler), - GEO_SCALE(0x00, 65536), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_medium_poly_left_hand_closed_shared_dl), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, mario_left_hand_open_shared_dl), - GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, mario_medium_poly_left_hand_closed_shared_dl), - GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, mario_medium_poly_left_hand_closed_shared_dl), - GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, mario_medium_poly_left_hand_closed_shared_dl), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_SWITCH_CASE(1, geo_switch_mario_hand), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ASM(1, geo_mario_hand_foot_scaler), + GEO_SCALE(0x00, 65536), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_medium_poly_left_hand_closed_shared_dl), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, mario_left_hand_open_shared_dl), + GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, mario_medium_poly_left_hand_closed_shared_dl), + GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, mario_medium_poly_left_hand_closed_shared_dl), + GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, mario_medium_poly_left_hand_closed_shared_dl), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x17001CF8 const GeoLayout mario_metal_geo_medium_poly_right_hand[] = { - GEO_SWITCH_CASE(0, geo_switch_mario_hand), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ASM(0, geo_mario_hand_foot_scaler), - GEO_SCALE(0x00, 65536), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_metal_medium_poly_right_hand_closed), - GEO_CLOSE_NODE(), - GEO_HELD_OBJECT(0x00, 0, 0, 0, geo_switch_mario_hand_grab_pos), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, mario_metal_right_hand_open), - GEO_OPEN_NODE(), - GEO_HELD_OBJECT(0x00, 0, 0, 0, geo_switch_mario_hand_grab_pos), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, mario_right_hand_peace_shared_dl), // here we go hand - GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, mario_metal_right_hand_cap_shared_dl), - GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, mario_metal_right_hand_cap_shared_dl), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, mario_metal_right_hand_cap_shared_dl_wings), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_SWITCH_CASE(0, geo_switch_mario_hand), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ASM(0, geo_mario_hand_foot_scaler), + GEO_SCALE(0x00, 65536), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_metal_medium_poly_right_hand_closed), + GEO_CLOSE_NODE(), + GEO_HELD_OBJECT(0x00, 0, 0, 0, geo_switch_mario_hand_grab_pos), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, mario_metal_right_hand_open), + GEO_OPEN_NODE(), + GEO_HELD_OBJECT(0x00, 0, 0, 0, geo_switch_mario_hand_grab_pos), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, mario_right_hand_peace_shared_dl), // here we go hand + GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, mario_metal_right_hand_cap_shared_dl), + GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, mario_metal_right_hand_cap_shared_dl), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, mario_metal_right_hand_cap_shared_dl_wings), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x17001DA0 const GeoLayout mario_metal_geo_medium_poly_body[] = { - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, mario_metal_medium_poly_butt), - GEO_OPEN_NODE(), - GEO_ASM(0, geo_move_mario_part_from_parent), - GEO_ASM(0, geo_mario_tilt_torso), - GEO_ROTATION_NODE(0x00, 0, 0, 0), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 68, 0, 0, mario_metal_medium_poly_torso), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, mario_metal_medium_poly_butt), + GEO_OPEN_NODE(), + GEO_ASM(0, geo_move_mario_part_from_parent), + GEO_ASM(0, geo_mario_tilt_torso), + GEO_ROTATION_NODE(0x00, 0, 0, 0), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 87, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_BRANCH(1, mario_metal_geo_face_and_wings), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 67, -10, 79, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, mario_medium_poly_left_arm_shared_dl), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 65, 0, 0, mario_medium_poly_left_forearm_shared_dl), - GEO_OPEN_NODE(), - GEO_BRANCH(1, mario_metal_geo_medium_poly_left_hand), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 68, -10, -79, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, mario_medium_poly_right_arm_shared_dl), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 65, 0, 0, mario_medium_poly_right_forearm_shared_dl), - GEO_OPEN_NODE(), - GEO_BRANCH(1, mario_metal_geo_medium_poly_right_hand), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 68, 0, 0, mario_metal_medium_poly_torso), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 87, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_BRANCH(1, mario_metal_geo_face_and_wings), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 67, -10, 79, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, mario_medium_poly_left_arm_shared_dl), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 65, 0, 0, mario_medium_poly_left_forearm_shared_dl), + GEO_OPEN_NODE(), + GEO_BRANCH(1, mario_metal_geo_medium_poly_left_hand), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 68, -10, -79, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, mario_medium_poly_right_arm_shared_dl), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 65, 0, 0, mario_medium_poly_right_forearm_shared_dl), + GEO_OPEN_NODE(), + GEO_BRANCH(1, mario_metal_geo_medium_poly_right_hand), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 13, -8, 42, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, mario_metal_medium_poly_left_thigh), + GEO_ANIMATED_PART(LAYER_OPAQUE, 13, -8, 42, NULL), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 89, 0, 0, mario_medium_poly_left_leg_shared_dl), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 67, 0, 0, mario_medium_poly_left_foot_shared_dl), - GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, mario_metal_medium_poly_left_thigh), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 89, 0, 0, mario_medium_poly_left_leg_shared_dl), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 67, 0, 0, mario_medium_poly_left_foot_shared_dl), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 13, -8, -42, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, mario_medium_poly_right_thigh_shared_dl), + GEO_ANIMATED_PART(LAYER_OPAQUE, 13, -8, -42, NULL), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 89, 0, 0, mario_medium_poly_right_leg_shared_dl), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 67, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ASM(2, geo_mario_hand_foot_scaler), - GEO_SCALE(0x00, 65536), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_metal_medium_poly_right_foot), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, mario_medium_poly_right_thigh_shared_dl), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 89, 0, 0, mario_medium_poly_right_leg_shared_dl), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 67, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ASM(2, geo_mario_hand_foot_scaler), + GEO_SCALE(0x00, 65536), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_metal_medium_poly_right_foot), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x17001F5C const GeoLayout mario_metal_geo_low_poly_face_and_wings[] = { - GEO_ASM(0, geo_mario_head_rotation), - GEO_ROTATION_NODE(0x00, 0, 0, 0), - GEO_OPEN_NODE(), - GEO_SWITCH_CASE(0, geo_switch_mario_cap_on_off), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_metal_low_poly_cap_on), - GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_metal_low_poly_cap_off), - GEO_CLOSE_NODE(), - GEO_TRANSLATE_ROTATE(0, 142, -51, -126, 22, -40, -135), - GEO_OPEN_NODE(), - GEO_ASM(0, geo_mario_rotate_wing_cap_wings), - GEO_ROTATION_NODE(0x00, 0, 0, 0), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, mario_metal_cap_wings), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_TRANSLATE_ROTATE(0, 142, -51, 126, -22, 40, -135), - GEO_OPEN_NODE(), - GEO_ASM(1, geo_mario_rotate_wing_cap_wings), - GEO_ROTATION_NODE(0x00, 0, 0, 0), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, mario_metal_cap_wings), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_ASM(0, geo_mario_head_rotation), + GEO_ROTATION_NODE(0x00, 0, 0, 0), + GEO_OPEN_NODE(), + GEO_SWITCH_CASE(0, geo_switch_mario_cap_on_off), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_metal_low_poly_cap_on), + GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_metal_low_poly_cap_off), + GEO_CLOSE_NODE(), + GEO_TRANSLATE_ROTATE(0, 142, -51, -126, 22, -40, -135), + GEO_OPEN_NODE(), + GEO_ASM(0, geo_mario_rotate_wing_cap_wings), + GEO_ROTATION_NODE(0x00, 0, 0, 0), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, mario_metal_cap_wings), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_TRANSLATE_ROTATE(0, 142, -51, 126, -22, 40, -135), + GEO_OPEN_NODE(), + GEO_ASM(1, geo_mario_rotate_wing_cap_wings), + GEO_ROTATION_NODE(0x00, 0, 0, 0), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, mario_metal_cap_wings), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x17002008 const GeoLayout mario_metal_geo_low_poly_left_hand[] = { - GEO_SWITCH_CASE(1, geo_switch_mario_hand), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ASM(1, geo_mario_hand_foot_scaler), - GEO_SCALE(0x00, 65536), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_low_poly_left_hand_closed_shared_dl), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, mario_left_hand_open_shared_dl), - GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, mario_low_poly_left_hand_closed_shared_dl), - GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, mario_low_poly_left_hand_closed_shared_dl), - GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, mario_low_poly_left_hand_closed_shared_dl), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_SWITCH_CASE(1, geo_switch_mario_hand), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ASM(1, geo_mario_hand_foot_scaler), + GEO_SCALE(0x00, 65536), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_low_poly_left_hand_closed_shared_dl), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, mario_left_hand_open_shared_dl), + GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, mario_low_poly_left_hand_closed_shared_dl), + GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, mario_low_poly_left_hand_closed_shared_dl), + GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, mario_low_poly_left_hand_closed_shared_dl), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x17002080 const GeoLayout mario_metal_geo_low_poly_right_hand[] = { - GEO_SWITCH_CASE(0, geo_switch_mario_hand), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ASM(0, geo_mario_hand_foot_scaler), - GEO_SCALE(0x00, 65536), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_metal_low_poly_right_hand_closed), - GEO_CLOSE_NODE(), - GEO_HELD_OBJECT(0x00, 0, 0, 0, geo_switch_mario_hand_grab_pos), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, mario_metal_right_hand_open), - GEO_OPEN_NODE(), - GEO_HELD_OBJECT(0x00, 0, 0, 0, geo_switch_mario_hand_grab_pos), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, mario_right_hand_peace_shared_dl), // here we go hand - GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, mario_metal_right_hand_cap_shared_dl), - GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, mario_metal_right_hand_cap_shared_dl), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, mario_metal_right_hand_cap_shared_dl_wings), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_SWITCH_CASE(0, geo_switch_mario_hand), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ASM(0, geo_mario_hand_foot_scaler), + GEO_SCALE(0x00, 65536), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_metal_low_poly_right_hand_closed), + GEO_CLOSE_NODE(), + GEO_HELD_OBJECT(0x00, 0, 0, 0, geo_switch_mario_hand_grab_pos), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, mario_metal_right_hand_open), + GEO_OPEN_NODE(), + GEO_HELD_OBJECT(0x00, 0, 0, 0, geo_switch_mario_hand_grab_pos), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, mario_right_hand_peace_shared_dl), // here we go hand + GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, mario_metal_right_hand_cap_shared_dl), + GEO_ANIMATED_PART(LAYER_OPAQUE, 60, 0, 0, mario_metal_right_hand_cap_shared_dl), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, mario_metal_right_hand_cap_shared_dl_wings), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x17002128 const GeoLayout mario_metal_geo_low_poly_body[] = { - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, mario_metal_low_poly_butt), - GEO_OPEN_NODE(), - GEO_ASM(0, geo_move_mario_part_from_parent), - GEO_ASM(0, geo_mario_tilt_torso), - GEO_ROTATION_NODE(0x00, 0, 0, 0), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 68, 0, 0, mario_metal_low_poly_torso), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, mario_metal_low_poly_butt), + GEO_OPEN_NODE(), + GEO_ASM(0, geo_move_mario_part_from_parent), + GEO_ASM(0, geo_mario_tilt_torso), + GEO_ROTATION_NODE(0x00, 0, 0, 0), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 87, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_BRANCH(1, mario_metal_geo_low_poly_face_and_wings), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 67, -10, 79, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, mario_low_poly_left_arm_shared_dl), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 65, 0, 0, mario_low_poly_left_forearm_shared_dl), - GEO_OPEN_NODE(), - GEO_BRANCH(1, mario_metal_geo_low_poly_left_hand), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 68, -10, -79, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, mario_low_poly_right_arm_shared_dl), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 65, 0, 0, mario_low_poly_right_forearm_shared_dl), - GEO_OPEN_NODE(), - GEO_BRANCH(1, mario_metal_geo_low_poly_right_hand), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 68, 0, 0, mario_metal_low_poly_torso), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 87, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_BRANCH(1, mario_metal_geo_low_poly_face_and_wings), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 67, -10, 79, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, mario_low_poly_left_arm_shared_dl), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 65, 0, 0, mario_low_poly_left_forearm_shared_dl), + GEO_OPEN_NODE(), + GEO_BRANCH(1, mario_metal_geo_low_poly_left_hand), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 68, -10, -79, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, mario_low_poly_right_arm_shared_dl), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 65, 0, 0, mario_low_poly_right_forearm_shared_dl), + GEO_OPEN_NODE(), + GEO_BRANCH(1, mario_metal_geo_low_poly_right_hand), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 13, -8, 42, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, mario_metal_low_poly_left_thigh), + GEO_ANIMATED_PART(LAYER_OPAQUE, 13, -8, 42, NULL), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 89, 0, 0, mario_low_poly_left_leg_shared_dl), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 67, 0, 0, mario_low_poly_left_foot_shared_dl), - GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, mario_metal_low_poly_left_thigh), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 89, 0, 0, mario_low_poly_left_leg_shared_dl), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 67, 0, 0, mario_low_poly_left_foot_shared_dl), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 13, -8, -42, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, mario_low_poly_right_thigh_shared_dl), + GEO_ANIMATED_PART(LAYER_OPAQUE, 13, -8, -42, NULL), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 89, 0, 0, mario_low_poly_right_leg_shared_dl), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 67, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ASM(2, geo_mario_hand_foot_scaler), - GEO_SCALE(0x00, 65536), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_metal_low_poly_right_foot), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, mario_low_poly_right_thigh_shared_dl), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 89, 0, 0, mario_low_poly_right_leg_shared_dl), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 67, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ASM(2, geo_mario_hand_foot_scaler), + GEO_SCALE(0x00, 65536), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_metal_low_poly_right_foot), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // Metal Vanish Mario Geo // 0x170022E4 const GeoLayout mario_metal_vanish_geo_face_and_wings[] = { - GEO_ASM(0, geo_mario_head_rotation), - GEO_ROTATION_NODE(0x00, 0, 0, 0), - GEO_OPEN_NODE(), - GEO_SWITCH_CASE(0, geo_switch_mario_cap_on_off), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_metal_cap_on_shared_dl), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_metal_cap_off_shared_dl), - GEO_CLOSE_NODE(), - GEO_TRANSLATE_ROTATE(0, 142, -51, -126, 22, -40, -135), - GEO_OPEN_NODE(), - GEO_ASM(0, geo_mario_rotate_wing_cap_wings), - GEO_ROTATION_NODE(0x00, 0, 0, 0), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_metal_cap_wings_transparent), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_TRANSLATE_ROTATE(0, 142, -51, 126, -22, 40, -135), - GEO_OPEN_NODE(), - GEO_ASM(1, geo_mario_rotate_wing_cap_wings), - GEO_ROTATION_NODE(0x00, 0, 0, 0), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_metal_cap_wings_transparent), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_ASM(0, geo_mario_head_rotation), + GEO_ROTATION_NODE(0x00, 0, 0, 0), + GEO_OPEN_NODE(), + GEO_SWITCH_CASE(0, geo_switch_mario_cap_on_off), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_metal_cap_on_shared_dl), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_metal_cap_off_shared_dl), + GEO_CLOSE_NODE(), + GEO_TRANSLATE_ROTATE(0, 142, -51, -126, 22, -40, -135), + GEO_OPEN_NODE(), + GEO_ASM(0, geo_mario_rotate_wing_cap_wings), + GEO_ROTATION_NODE(0x00, 0, 0, 0), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_metal_cap_wings_transparent), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_TRANSLATE_ROTATE(0, 142, -51, 126, -22, 40, -135), + GEO_OPEN_NODE(), + GEO_ASM(1, geo_mario_rotate_wing_cap_wings), + GEO_ROTATION_NODE(0x00, 0, 0, 0), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_metal_cap_wings_transparent), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x17002390 const GeoLayout mario_metal_vanish_geo_left_hand[] = { - GEO_SWITCH_CASE(0, geo_switch_mario_hand), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ASM(1, geo_mario_hand_foot_scaler), - GEO_SCALE(0x00, 65536), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_left_hand_closed_shared_dl), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, mario_left_hand_open_shared_dl), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, mario_left_hand_closed_shared_dl), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, mario_left_hand_closed_shared_dl), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, mario_left_hand_closed_shared_dl), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_SWITCH_CASE(0, geo_switch_mario_hand), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ASM(1, geo_mario_hand_foot_scaler), + GEO_SCALE(0x00, 65536), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_left_hand_closed_shared_dl), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, mario_left_hand_open_shared_dl), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, mario_left_hand_closed_shared_dl), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, mario_left_hand_closed_shared_dl), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, mario_left_hand_closed_shared_dl), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x17002408 const GeoLayout mario_metal_vanish_geo_right_hand[] = { - GEO_SWITCH_CASE(0, geo_switch_mario_hand), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ASM(0, geo_mario_hand_foot_scaler), - GEO_SCALE(0x00, 65536), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_metal_right_hand_closed), - GEO_CLOSE_NODE(), - GEO_HELD_OBJECT(0x00, 0, 0, 0, geo_switch_mario_hand_grab_pos), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, mario_metal_right_hand_open), - GEO_OPEN_NODE(), - GEO_HELD_OBJECT(0x00, 0, 0, 0, geo_switch_mario_hand_grab_pos), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, mario_right_hand_peace_shared_dl), // here we go hand - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, mario_metal_right_hand_cap_shared_dl), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, mario_metal_right_hand_cap_shared_dl), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, mario_metal_right_hand_cap_shared_dl_wings), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_SWITCH_CASE(0, geo_switch_mario_hand), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ASM(0, geo_mario_hand_foot_scaler), + GEO_SCALE(0x00, 65536), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_metal_right_hand_closed), + GEO_CLOSE_NODE(), + GEO_HELD_OBJECT(0x00, 0, 0, 0, geo_switch_mario_hand_grab_pos), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, mario_metal_right_hand_open), + GEO_OPEN_NODE(), + GEO_HELD_OBJECT(0x00, 0, 0, 0, geo_switch_mario_hand_grab_pos), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, mario_right_hand_peace_shared_dl), // here we go hand + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, mario_metal_right_hand_cap_shared_dl), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, mario_metal_right_hand_cap_shared_dl), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, mario_metal_right_hand_cap_shared_dl_wings), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // Same rules as Metal Mario // 0x170024B0 const GeoLayout mario_metal_vanish_geo_body[] = { - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, mario_metal_butt), - GEO_OPEN_NODE(), - GEO_ASM(0, geo_move_mario_part_from_parent), - GEO_ASM(0, geo_mario_tilt_torso), - GEO_ROTATION_NODE(0x00, 0, 0, 0), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 68, 0, 0, mario_metal_torso_shared_dl), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, mario_metal_butt), + GEO_OPEN_NODE(), + GEO_ASM(0, geo_move_mario_part_from_parent), + GEO_ASM(0, geo_mario_tilt_torso), + GEO_ROTATION_NODE(0x00, 0, 0, 0), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 87, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_BRANCH(1, mario_metal_vanish_geo_face_and_wings), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 67, -10, 79, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, mario_left_arm_shared_dl), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 65, 0, 0, mario_left_forearm_shared_dl), - GEO_OPEN_NODE(), - GEO_BRANCH(1, mario_metal_vanish_geo_left_hand), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 68, -10, -79, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, mario_right_arm_shared_dl), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 65, 0, 0, mario_right_forearm_shared_dl), - GEO_OPEN_NODE(), - GEO_BRANCH(1, mario_metal_vanish_geo_right_hand), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 68, 0, 0, mario_metal_torso_shared_dl), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 87, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_BRANCH(1, mario_metal_vanish_geo_face_and_wings), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 67, -10, 79, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, mario_left_arm_shared_dl), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 65, 0, 0, mario_left_forearm_shared_dl), + GEO_OPEN_NODE(), + GEO_BRANCH(1, mario_metal_vanish_geo_left_hand), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 68, -10, -79, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, mario_right_arm_shared_dl), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 65, 0, 0, mario_right_forearm_shared_dl), + GEO_OPEN_NODE(), + GEO_BRANCH(1, mario_metal_vanish_geo_right_hand), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 13, -8, 42, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, mario_metal_left_thigh), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 13, -8, 42, NULL), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 89, 0, 0, mario_left_leg_shared_dl), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 67, 0, 0, mario_left_foot_shared_dl), - GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, mario_metal_left_thigh), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 89, 0, 0, mario_left_leg_shared_dl), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 67, 0, 0, mario_left_foot_shared_dl), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 13, -8, -42, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, mario_right_thigh_shared_dl), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 13, -8, -42, NULL), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 89, 0, 0, mario_right_leg_shared_dl), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 67, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ASM(2, geo_mario_hand_foot_scaler), - GEO_SCALE(0x00, 65536), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_metal_right_foot), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, mario_right_thigh_shared_dl), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 89, 0, 0, mario_right_leg_shared_dl), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 67, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ASM(2, geo_mario_hand_foot_scaler), + GEO_SCALE(0x00, 65536), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_metal_right_foot), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x1700266C const GeoLayout mario_metal_vanish_geo_medium_poly_left_hand[] = { - GEO_SWITCH_CASE(0, geo_switch_mario_hand), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ASM(1, geo_mario_hand_foot_scaler), - GEO_SCALE(0x00, 65536), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_medium_poly_left_hand_closed_shared_dl), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, mario_left_hand_open_shared_dl), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, mario_medium_poly_left_hand_closed_shared_dl), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, mario_medium_poly_left_hand_closed_shared_dl), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, mario_medium_poly_left_hand_closed_shared_dl), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_SWITCH_CASE(0, geo_switch_mario_hand), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ASM(1, geo_mario_hand_foot_scaler), + GEO_SCALE(0x00, 65536), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_medium_poly_left_hand_closed_shared_dl), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, mario_left_hand_open_shared_dl), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, mario_medium_poly_left_hand_closed_shared_dl), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, mario_medium_poly_left_hand_closed_shared_dl), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, mario_medium_poly_left_hand_closed_shared_dl), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x170026E4 const GeoLayout mario_metal_vanish_geo_medium_poly_right_hand[] = { - GEO_SWITCH_CASE(0, geo_switch_mario_hand), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ASM(0, geo_mario_hand_foot_scaler), - GEO_SCALE(0x00, 65536), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_metal_medium_poly_right_hand_closed), - GEO_CLOSE_NODE(), - GEO_HELD_OBJECT(0x00, 0, 0, 0, geo_switch_mario_hand_grab_pos), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, mario_metal_right_hand_open), - GEO_OPEN_NODE(), - GEO_HELD_OBJECT(0x00, 0, 0, 0, geo_switch_mario_hand_grab_pos), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, mario_right_hand_peace_shared_dl), // here we go hand - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, mario_metal_right_hand_cap_shared_dl), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, mario_metal_right_hand_cap_shared_dl), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, mario_metal_right_hand_cap_shared_dl_wings), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_SWITCH_CASE(0, geo_switch_mario_hand), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ASM(0, geo_mario_hand_foot_scaler), + GEO_SCALE(0x00, 65536), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_metal_medium_poly_right_hand_closed), + GEO_CLOSE_NODE(), + GEO_HELD_OBJECT(0x00, 0, 0, 0, geo_switch_mario_hand_grab_pos), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, mario_metal_right_hand_open), + GEO_OPEN_NODE(), + GEO_HELD_OBJECT(0x00, 0, 0, 0, geo_switch_mario_hand_grab_pos), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, mario_right_hand_peace_shared_dl), // here we go hand + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, mario_metal_right_hand_cap_shared_dl), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, mario_metal_right_hand_cap_shared_dl), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, mario_metal_right_hand_cap_shared_dl_wings), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x1700278C const GeoLayout mario_metal_vanish_geo_medium_poly_body[] = { - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, mario_metal_medium_poly_butt), - GEO_OPEN_NODE(), - GEO_ASM(0, geo_move_mario_part_from_parent), - GEO_ASM(0, geo_mario_tilt_torso), - GEO_ROTATION_NODE(0x00, 0, 0, 0), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 68, 0, 0, mario_metal_medium_poly_torso), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, mario_metal_medium_poly_butt), + GEO_OPEN_NODE(), + GEO_ASM(0, geo_move_mario_part_from_parent), + GEO_ASM(0, geo_mario_tilt_torso), + GEO_ROTATION_NODE(0x00, 0, 0, 0), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 87, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_BRANCH(1, mario_metal_vanish_geo_face_and_wings), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 67, -10, 79, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, mario_medium_poly_left_arm_shared_dl), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 65, 0, 0, mario_medium_poly_left_forearm_shared_dl), - GEO_OPEN_NODE(), - GEO_BRANCH(1, mario_metal_vanish_geo_medium_poly_left_hand), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 68, -10, -79, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, mario_medium_poly_right_arm_shared_dl), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 65, 0, 0, mario_medium_poly_right_forearm_shared_dl), - GEO_OPEN_NODE(), - GEO_SWITCH_CASE(0, geo_switch_mario_hand), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 68, 0, 0, mario_metal_medium_poly_torso), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 87, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_BRANCH(1, mario_metal_vanish_geo_face_and_wings), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 67, -10, 79, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, mario_medium_poly_left_arm_shared_dl), GEO_OPEN_NODE(), - GEO_BRANCH(1, mario_metal_vanish_geo_medium_poly_right_hand), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 65, 0, 0, mario_medium_poly_left_forearm_shared_dl), + GEO_OPEN_NODE(), + GEO_BRANCH(1, mario_metal_vanish_geo_medium_poly_left_hand), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 68, -10, -79, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, mario_medium_poly_right_arm_shared_dl), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 65, 0, 0, mario_medium_poly_right_forearm_shared_dl), + GEO_OPEN_NODE(), + GEO_SWITCH_CASE(0, geo_switch_mario_hand), + GEO_OPEN_NODE(), + GEO_BRANCH(1, mario_metal_vanish_geo_medium_poly_right_hand), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 13, -8, 42, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, mario_metal_medium_poly_left_thigh), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 13, -8, 42, NULL), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 89, 0, 0, mario_medium_poly_left_leg_shared_dl), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 67, 0, 0, mario_medium_poly_left_foot_shared_dl), - GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, mario_metal_medium_poly_left_thigh), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 89, 0, 0, mario_medium_poly_left_leg_shared_dl), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 67, 0, 0, mario_medium_poly_left_foot_shared_dl), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 13, -8, -42, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, mario_medium_poly_right_thigh_shared_dl), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 13, -8, -42, NULL), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 89, 0, 0, mario_medium_poly_right_leg_shared_dl), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 67, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ASM(2, geo_mario_hand_foot_scaler), - GEO_SCALE(0x00, 65536), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_metal_medium_poly_right_foot), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, mario_medium_poly_right_thigh_shared_dl), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 89, 0, 0, mario_medium_poly_right_leg_shared_dl), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 67, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ASM(2, geo_mario_hand_foot_scaler), + GEO_SCALE(0x00, 65536), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_metal_medium_poly_right_foot), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x17002958 const GeoLayout mario_metal_vanish_geo_low_poly_face_and_wings[] = { - GEO_ASM(0, geo_mario_head_rotation), - GEO_ROTATION_NODE(0x00, 0, 0, 0), - GEO_OPEN_NODE(), - GEO_SWITCH_CASE(0, geo_switch_mario_cap_on_off), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_metal_low_poly_cap_on), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_metal_low_poly_cap_off), - GEO_CLOSE_NODE(), - GEO_TRANSLATE_ROTATE(0, 142, -51, -126, 22, -40, -135), - GEO_OPEN_NODE(), - GEO_ASM(0, geo_mario_rotate_wing_cap_wings), - GEO_ROTATION_NODE(0x00, 0, 0, 0), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_metal_cap_wings_transparent), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_TRANSLATE_ROTATE(0, 142, -51, 126, -22, 40, -135), - GEO_OPEN_NODE(), - GEO_ASM(1, geo_mario_rotate_wing_cap_wings), - GEO_ROTATION_NODE(0x00, 0, 0, 0), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_metal_cap_wings_transparent), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_ASM(0, geo_mario_head_rotation), + GEO_ROTATION_NODE(0x00, 0, 0, 0), + GEO_OPEN_NODE(), + GEO_SWITCH_CASE(0, geo_switch_mario_cap_on_off), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_metal_low_poly_cap_on), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_metal_low_poly_cap_off), + GEO_CLOSE_NODE(), + GEO_TRANSLATE_ROTATE(0, 142, -51, -126, 22, -40, -135), + GEO_OPEN_NODE(), + GEO_ASM(0, geo_mario_rotate_wing_cap_wings), + GEO_ROTATION_NODE(0x00, 0, 0, 0), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_metal_cap_wings_transparent), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_TRANSLATE_ROTATE(0, 142, -51, 126, -22, 40, -135), + GEO_OPEN_NODE(), + GEO_ASM(1, geo_mario_rotate_wing_cap_wings), + GEO_ROTATION_NODE(0x00, 0, 0, 0), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_metal_cap_wings_transparent), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x17002A04 const GeoLayout mario_metal_vanish_geo_low_poly_left_hand[] = { - GEO_SWITCH_CASE(0, geo_switch_mario_hand), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ASM(1, geo_mario_hand_foot_scaler), - GEO_SCALE(0x00, 65536), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_low_poly_left_hand_closed_shared_dl), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, mario_left_hand_open_shared_dl), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, mario_low_poly_left_hand_closed_shared_dl), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, mario_low_poly_left_hand_closed_shared_dl), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, mario_low_poly_left_hand_closed_shared_dl), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_SWITCH_CASE(0, geo_switch_mario_hand), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ASM(1, geo_mario_hand_foot_scaler), + GEO_SCALE(0x00, 65536), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_low_poly_left_hand_closed_shared_dl), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, mario_left_hand_open_shared_dl), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, mario_low_poly_left_hand_closed_shared_dl), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, mario_low_poly_left_hand_closed_shared_dl), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, mario_low_poly_left_hand_closed_shared_dl), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x17002A7C const GeoLayout mario_metal_vanish_geo_low_poly_right_hand[] = { - GEO_SWITCH_CASE(0, geo_switch_mario_hand), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ASM(0, geo_mario_hand_foot_scaler), - GEO_SCALE(0x00, 65536), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_metal_low_poly_right_hand_closed), - GEO_CLOSE_NODE(), - GEO_HELD_OBJECT(0x00, 0, 0, 0, geo_switch_mario_hand_grab_pos), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, mario_metal_right_hand_open), - GEO_OPEN_NODE(), - GEO_HELD_OBJECT(0x00, 0, 0, 0, geo_switch_mario_hand_grab_pos), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, mario_right_hand_peace_shared_dl), // here we go hand - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, mario_metal_right_hand_cap_shared_dl), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, mario_metal_right_hand_cap_shared_dl), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, mario_metal_right_hand_cap_shared_dl_wings), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_SWITCH_CASE(0, geo_switch_mario_hand), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ASM(0, geo_mario_hand_foot_scaler), + GEO_SCALE(0x00, 65536), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_metal_low_poly_right_hand_closed), + GEO_CLOSE_NODE(), + GEO_HELD_OBJECT(0x00, 0, 0, 0, geo_switch_mario_hand_grab_pos), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, mario_metal_right_hand_open), + GEO_OPEN_NODE(), + GEO_HELD_OBJECT(0x00, 0, 0, 0, geo_switch_mario_hand_grab_pos), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, mario_right_hand_peace_shared_dl), // here we go hand + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, mario_metal_right_hand_cap_shared_dl), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 60, 0, 0, mario_metal_right_hand_cap_shared_dl), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, mario_metal_right_hand_cap_shared_dl_wings), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x17002B24 const GeoLayout mario_metal_vanish_geo_low_poly_body[] = { - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, mario_metal_low_poly_butt), - GEO_OPEN_NODE(), - GEO_ASM(0, geo_move_mario_part_from_parent), - GEO_ASM(0, geo_mario_tilt_torso), - GEO_ROTATION_NODE(0x00, 0, 0, 0), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 68, 0, 0, mario_metal_low_poly_torso), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, mario_metal_low_poly_butt), + GEO_OPEN_NODE(), + GEO_ASM(0, geo_move_mario_part_from_parent), + GEO_ASM(0, geo_mario_tilt_torso), + GEO_ROTATION_NODE(0x00, 0, 0, 0), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 87, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_BRANCH(1, mario_metal_vanish_geo_low_poly_face_and_wings), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 67, -10, 79, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, mario_low_poly_left_arm_shared_dl), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 65, 0, 0, mario_low_poly_left_forearm_shared_dl), - GEO_OPEN_NODE(), - GEO_BRANCH(1, mario_metal_vanish_geo_low_poly_left_hand), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 68, -10, -79, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, mario_low_poly_right_arm_shared_dl), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 65, 0, 0, mario_low_poly_right_forearm_shared_dl), - GEO_OPEN_NODE(), - GEO_BRANCH(1, mario_metal_vanish_geo_low_poly_right_hand), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 68, 0, 0, mario_metal_low_poly_torso), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 87, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_BRANCH(1, mario_metal_vanish_geo_low_poly_face_and_wings), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 67, -10, 79, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, mario_low_poly_left_arm_shared_dl), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 65, 0, 0, mario_low_poly_left_forearm_shared_dl), + GEO_OPEN_NODE(), + GEO_BRANCH(1, mario_metal_vanish_geo_low_poly_left_hand), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 68, -10, -79, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, mario_low_poly_right_arm_shared_dl), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 65, 0, 0, mario_low_poly_right_forearm_shared_dl), + GEO_OPEN_NODE(), + GEO_BRANCH(1, mario_metal_vanish_geo_low_poly_right_hand), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 13, -8, 42, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, mario_metal_low_poly_left_thigh), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 13, -8, 42, NULL), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 89, 0, 0, mario_low_poly_left_leg_shared_dl), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 67, 0, 0, mario_low_poly_left_foot_shared_dl), - GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, mario_metal_low_poly_left_thigh), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 89, 0, 0, mario_low_poly_left_leg_shared_dl), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 67, 0, 0, mario_low_poly_left_foot_shared_dl), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 13, -8, -42, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, mario_low_poly_right_thigh_shared_dl), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 13, -8, -42, NULL), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 89, 0, 0, mario_low_poly_right_leg_shared_dl), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 67, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ASM(2, geo_mario_hand_foot_scaler), - GEO_SCALE(0x00, 65536), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_metal_low_poly_right_foot), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, mario_low_poly_right_thigh_shared_dl), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 89, 0, 0, mario_low_poly_right_leg_shared_dl), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 67, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ASM(2, geo_mario_hand_foot_scaler), + GEO_SCALE(0x00, 65536), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_metal_low_poly_right_foot), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // High Poly // 0x17002CE0 const GeoLayout mario_geo_load_body[] = { - GEO_SWITCH_CASE(0, geo_switch_mario_cap_effect), - GEO_OPEN_NODE(), - GEO_BRANCH(1, mario_geo_body), - GEO_BRANCH(1, mario_vanish_geo_body), - GEO_BRANCH(1, mario_metal_geo_body), - GEO_BRANCH(1, mario_metal_vanish_geo_body), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_SWITCH_CASE(0, geo_switch_mario_cap_effect), + GEO_OPEN_NODE(), + GEO_BRANCH(1, mario_geo_body), + GEO_BRANCH(1, mario_vanish_geo_body), + GEO_BRANCH(1, mario_metal_geo_body), + GEO_BRANCH(1, mario_metal_vanish_geo_body), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // Medium Poly // 0x17002D14 const GeoLayout mario_geo_load_medium_poly_body[] = { - GEO_SWITCH_CASE(0, geo_switch_mario_cap_effect), - GEO_OPEN_NODE(), - GEO_BRANCH(1, mario_geo_medium_poly_body), - GEO_BRANCH(1, mario_vanish_geo_medium_poly_body), - GEO_BRANCH(1, mario_metal_geo_medium_poly_body), - GEO_BRANCH(1, mario_metal_vanish_geo_medium_poly_body), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_SWITCH_CASE(0, geo_switch_mario_cap_effect), + GEO_OPEN_NODE(), + GEO_BRANCH(1, mario_geo_medium_poly_body), + GEO_BRANCH(1, mario_vanish_geo_medium_poly_body), + GEO_BRANCH(1, mario_metal_geo_medium_poly_body), + GEO_BRANCH(1, mario_metal_vanish_geo_medium_poly_body), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // Low Poly // 0x17002D48 const GeoLayout mario_geo_load_low_poly_body[] = { - GEO_SWITCH_CASE(0, geo_switch_mario_cap_effect), - GEO_OPEN_NODE(), - GEO_BRANCH(1, mario_geo_low_poly_body), - GEO_BRANCH(1, mario_vanish_geo_low_poly_body), - GEO_BRANCH(1, mario_metal_geo_low_poly_body), - GEO_BRANCH(1, mario_metal_vanish_geo_low_poly_body), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_SWITCH_CASE(0, geo_switch_mario_cap_effect), + GEO_OPEN_NODE(), + GEO_BRANCH(1, mario_geo_low_poly_body), + GEO_BRANCH(1, mario_vanish_geo_low_poly_body), + GEO_BRANCH(1, mario_metal_geo_low_poly_body), + GEO_BRANCH(1, mario_metal_vanish_geo_low_poly_body), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x17002D7C const GeoLayout mario_geo_render_body[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_RENDER_RANGE(-2048, 600), - GEO_OPEN_NODE(), - GEO_BRANCH(1, mario_geo_load_body), - GEO_CLOSE_NODE(), - GEO_RENDER_RANGE(600, 1600), - GEO_OPEN_NODE(), - GEO_BRANCH(1, mario_geo_load_medium_poly_body), - GEO_CLOSE_NODE(), - GEO_RENDER_RANGE(1600, 32767), - GEO_OPEN_NODE(), - GEO_BRANCH(1, mario_geo_load_low_poly_body), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_RENDER_RANGE(-2048, 600), + GEO_OPEN_NODE(), + GEO_BRANCH(1, mario_geo_load_body), + GEO_CLOSE_NODE(), + GEO_RENDER_RANGE(600, 1600), + GEO_OPEN_NODE(), + GEO_BRANCH(1, mario_geo_load_medium_poly_body), + GEO_CLOSE_NODE(), + GEO_RENDER_RANGE(1600, 32767), + GEO_OPEN_NODE(), + GEO_BRANCH(1, mario_geo_load_low_poly_body), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // This last geo is used to load all of Mario Geo in the Level Scripts // 0x17002DD4 const GeoLayout mario_geo[] = { - GEO_SHADOW(SHADOW_CIRCLE_PLAYER, 0xB4, 100), - GEO_OPEN_NODE(), - GEO_SCALE(0x00, 16384), - GEO_OPEN_NODE(), - GEO_ASM(0, geo_mirror_mario_backface_culling), - GEO_ASM(0, geo_mirror_mario_set_alpha), - GEO_SWITCH_CASE(0, geo_switch_mario_stand_run), - GEO_OPEN_NODE(), - GEO_BRANCH(1, mario_geo_load_body), - GEO_BRANCH(1, mario_geo_render_body), - GEO_CLOSE_NODE(), - GEO_ASM(1, geo_mirror_mario_backface_culling), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_SHADOW(SHADOW_CIRCLE_PLAYER, 0xB4, 100), + GEO_OPEN_NODE(), + GEO_SCALE(0x00, 16384), + GEO_OPEN_NODE(), + GEO_ASM(0, geo_mirror_mario_backface_culling), + GEO_ASM(0, geo_mirror_mario_set_alpha), + GEO_SWITCH_CASE(0, geo_switch_mario_stand_run), + GEO_OPEN_NODE(), + GEO_BRANCH(1, mario_geo_load_body), + GEO_BRANCH(1, mario_geo_render_body), + GEO_CLOSE_NODE(), + GEO_ASM(1, geo_mirror_mario_backface_culling), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/actors/mario_cap/geo.inc.c b/actors/mario_cap/geo.inc.c index 5e59c311..94e7fcf5 100644 --- a/actors/mario_cap/geo.inc.c +++ b/actors/mario_cap/geo.inc.c @@ -1,81 +1,81 @@ // 0x16000CA4 const GeoLayout marios_cap_geo[] = { - GEO_SHADOW(SHADOW_CIRCLE_9_VERTS, 0xB4, 75), - GEO_OPEN_NODE(), - GEO_SCALE(0x00, 16384), - GEO_OPEN_NODE(), - GEO_ASM(10, geo_update_layer_transparency), - GEO_SWITCH_CASE(2, geo_switch_anim_state), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_cap_seg3_dl_03022F48), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_cap_seg3_dl_03022F48), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_SHADOW(SHADOW_CIRCLE_9_VERTS, 0xB4, 75), + GEO_OPEN_NODE(), + GEO_SCALE(0x00, 16384), + GEO_OPEN_NODE(), + GEO_ASM(10, geo_update_layer_transparency), + GEO_SWITCH_CASE(2, geo_switch_anim_state), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_cap_seg3_dl_03022F48), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_cap_seg3_dl_03022F48), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; // 0x16000CF0 const GeoLayout marios_metal_cap_geo[] = { - GEO_SHADOW(SHADOW_CIRCLE_9_VERTS, 0xB4, 75), - GEO_OPEN_NODE(), - GEO_SCALE(0x00, 16384), - GEO_OPEN_NODE(), - GEO_ASM(10, geo_update_layer_transparency), - GEO_SWITCH_CASE(2, geo_switch_anim_state), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_cap_seg3_dl_03022FF8), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_cap_seg3_dl_03022FF8), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_SHADOW(SHADOW_CIRCLE_9_VERTS, 0xB4, 75), + GEO_OPEN_NODE(), + GEO_SCALE(0x00, 16384), + GEO_OPEN_NODE(), + GEO_ASM(10, geo_update_layer_transparency), + GEO_SWITCH_CASE(2, geo_switch_anim_state), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_cap_seg3_dl_03022FF8), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_cap_seg3_dl_03022FF8), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; // 0x16000D3C const GeoLayout marios_wing_cap_geo[] = { - GEO_SHADOW(SHADOW_CIRCLE_9_VERTS, 0xB4, 75), - GEO_OPEN_NODE(), - GEO_SCALE(0x00, 16384), - GEO_OPEN_NODE(), - GEO_ASM(10, geo_update_layer_transparency), - GEO_SWITCH_CASE(2, geo_switch_anim_state), - GEO_OPEN_NODE(), - GEO_NODE_START(), + GEO_SHADOW(SHADOW_CIRCLE_9_VERTS, 0xB4, 75), + GEO_OPEN_NODE(), + GEO_SCALE(0x00, 16384), + GEO_OPEN_NODE(), + GEO_ASM(10, geo_update_layer_transparency), + GEO_SWITCH_CASE(2, geo_switch_anim_state), GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_cap_seg3_dl_03022F48), - GEO_DISPLAY_LIST(LAYER_ALPHA, mario_cap_seg3_dl_030230B0), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_cap_seg3_dl_03022F48), + GEO_DISPLAY_LIST(LAYER_ALPHA, mario_cap_seg3_dl_030230B0), + GEO_CLOSE_NODE(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_cap_seg3_dl_03023160), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_cap_seg3_dl_03023160), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; // 0x16000DA8 const GeoLayout marios_winged_metal_cap_geo[] = { - GEO_SHADOW(SHADOW_CIRCLE_9_VERTS, 0xB4, 75), - GEO_OPEN_NODE(), - GEO_SCALE(0x00, 16384), - GEO_OPEN_NODE(), - GEO_ASM(10, geo_update_layer_transparency), - GEO_SWITCH_CASE(2, geo_switch_anim_state), - GEO_OPEN_NODE(), - GEO_NODE_START(), + GEO_SHADOW(SHADOW_CIRCLE_9_VERTS, 0xB4, 75), + GEO_OPEN_NODE(), + GEO_SCALE(0x00, 16384), + GEO_OPEN_NODE(), + GEO_ASM(10, geo_update_layer_transparency), + GEO_SWITCH_CASE(2, geo_switch_anim_state), GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_cap_seg3_dl_03022FF8), - GEO_DISPLAY_LIST(LAYER_ALPHA, mario_cap_seg3_dl_03023108), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_cap_seg3_dl_03022FF8), + GEO_DISPLAY_LIST(LAYER_ALPHA, mario_cap_seg3_dl_03023108), + GEO_CLOSE_NODE(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_cap_seg3_dl_03023298), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mario_cap_seg3_dl_03023298), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/actors/metal_box/geo.inc.c b/actors/metal_box/geo.inc.c index 676bd0ad..08656991 100644 --- a/actors/metal_box/geo.inc.c +++ b/actors/metal_box/geo.inc.c @@ -1,11 +1,11 @@ // 0x0F000A30 const GeoLayout metal_box_geo[] = { - GEO_CULLING_RADIUS(500), - GEO_OPEN_NODE(), - GEO_SHADOW(SHADOW_SQUARE_PERMANENT, 0xB4, 70), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, metal_box_dl), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(500), + GEO_OPEN_NODE(), + GEO_SHADOW(SHADOW_SQUARE_PERMANENT, 0xB4, 70), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, metal_box_dl), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/actors/mips/geo.inc.c b/actors/mips/geo.inc.c index 58948b5b..ffb323a7 100644 --- a/actors/mips/geo.inc.c +++ b/actors/mips/geo.inc.c @@ -1,56 +1,56 @@ // 0x0D000448 const GeoLayout mips_geo[] = { - GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0x96, 100), - GEO_OPEN_NODE(), - GEO_SCALE(0x00, 16384), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, mips_seg6_dl_06010C40), + GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0x96, 100), + GEO_OPEN_NODE(), + GEO_SCALE(0x00, 16384), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 64, 0, 0, mips_seg6_dl_060107B8), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 52, -24, -32, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, mips_seg6_dl_06011DB0), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 79, 0, 0, mips_seg6_dl_06011BB0), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 52, -24, 32, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, mips_seg6_dl_060110B0), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 79, 0, 0, mips_seg6_dl_06010E60), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, -31, 4, -39, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, mips_seg6_dl_06011FC0), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 45, 0, 0, mips_seg6_dl_06011990), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 52, 0, 0, mips_seg6_dl_06011780), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, -31, 4, 40, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, mips_seg6_dl_06011ED8), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 45, 0, 0, mips_seg6_dl_06011520), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 52, 0, 0, mips_seg6_dl_06011310), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, mips_seg6_dl_06010C40), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 64, 0, 0, mips_seg6_dl_060107B8), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 52, -24, -32, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, mips_seg6_dl_06011DB0), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 79, 0, 0, mips_seg6_dl_06011BB0), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 52, -24, 32, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, mips_seg6_dl_060110B0), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 79, 0, 0, mips_seg6_dl_06010E60), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, -31, 4, -39, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, mips_seg6_dl_06011FC0), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 45, 0, 0, mips_seg6_dl_06011990), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 52, 0, 0, mips_seg6_dl_06011780), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, -31, 4, 40, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, mips_seg6_dl_06011ED8), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 45, 0, 0, mips_seg6_dl_06011520), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 52, 0, 0, mips_seg6_dl_06011310), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), -GEO_CLOSE_NODE(), //! more close than open nodes -GEO_END(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), //! more close than open nodes + GEO_END(), }; UNUSED static const u64 mips_unused_1 = 0; diff --git a/actors/mist/geo.inc.c b/actors/mist/geo.inc.c index 93308965..4357b82a 100644 --- a/actors/mist/geo.inc.c +++ b/actors/mist/geo.inc.c @@ -1,19 +1,19 @@ // 0x16000000 const GeoLayout mist_geo[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_ASM(0, geo_update_layer_transparency), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mist_seg3_dl_03000880), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_ASM(0, geo_update_layer_transparency), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mist_seg3_dl_03000880), + GEO_CLOSE_NODE(), + GEO_END(), }; // 0x16000020 const GeoLayout white_puff_geo[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_ASM(0, geo_update_layer_transparency), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mist_seg3_dl_03000920), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_ASM(0, geo_update_layer_transparency), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mist_seg3_dl_03000920), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/actors/moneybag/geo.inc.c b/actors/moneybag/geo.inc.c index 2d1db035..efe8420b 100644 --- a/actors/moneybag/geo.inc.c +++ b/actors/moneybag/geo.inc.c @@ -1,59 +1,59 @@ // 0x0D000000 const GeoLayout moneybag_geo_000000[] = { - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, moneybag_seg6_dl_06005750), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, -120, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, moneybag_seg6_dl_06005980), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 120, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, moneybag_seg6_dl_060059F0), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, moneybag_seg6_dl_06005688), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, moneybag_seg6_dl_06005750), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, -120, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, moneybag_seg6_dl_06005980), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 120, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, moneybag_seg6_dl_060059F0), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, moneybag_seg6_dl_06005688), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x0D000078 const GeoLayout moneybag_geo_000078[] = { - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, moneybag_seg6_dl_06005750), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, -120, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, moneybag_seg6_dl_06005980), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 120, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, moneybag_seg6_dl_060059F0), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, moneybag_seg6_dl_06005688), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, moneybag_seg6_dl_06005750), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, -120, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, moneybag_seg6_dl_06005980), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 120, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, moneybag_seg6_dl_060059F0), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, moneybag_seg6_dl_06005688), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x0D0000F0 const GeoLayout moneybag_geo[] = { - GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0xC8, 100), - GEO_OPEN_NODE(), - GEO_SCALE(0x00, 16384), - GEO_OPEN_NODE(), - GEO_ASM(0, geo_update_layer_transparency), - GEO_SWITCH_CASE(2, geo_switch_anim_state), - GEO_OPEN_NODE(), - GEO_BRANCH(1, moneybag_geo_000000), - GEO_BRANCH(1, moneybag_geo_000078), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), -GEO_CLOSE_NODE(), //! more close than open nodes -GEO_END(), + GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0xC8, 100), + GEO_OPEN_NODE(), + GEO_SCALE(0x00, 16384), + GEO_OPEN_NODE(), + GEO_ASM(0, geo_update_layer_transparency), + GEO_SWITCH_CASE(2, geo_switch_anim_state), + GEO_OPEN_NODE(), + GEO_BRANCH(1, moneybag_geo_000000), + GEO_BRANCH(1, moneybag_geo_000078), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), //! more close than open nodes + GEO_END(), }; UNUSED static const u64 moneybag_unused_1 = 0; diff --git a/actors/monty_mole/geo.inc.c b/actors/monty_mole/geo.inc.c index 5c76e89c..4144c92d 100644 --- a/actors/monty_mole/geo.inc.c +++ b/actors/monty_mole/geo.inc.c @@ -1,41 +1,41 @@ // 0x0C000000 const GeoLayout monty_mole_geo[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_SCALE(0x00, 16384), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, monty_mole_seg5_dl_050044B0), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_SCALE(0x00, 16384), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 116, 0, 0, monty_mole_seg5_dl_05004C00), - GEO_ANIMATED_PART(LAYER_ALPHA, 116, 0, 0, monty_mole_seg5_dl_05004D30), - GEO_ANIMATED_PART(LAYER_OPAQUE, -68, -5, -40, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, monty_mole_seg5_dl_05003C48), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, -68, -5, 40, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, monty_mole_seg5_dl_05003518), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 80, 1, 78, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, monty_mole_seg5_dl_050032A0), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 80, 0, 0, monty_mole_seg5_dl_05003820), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 80, 1, -78, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, monty_mole_seg5_dl_050039D0), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 80, 0, 0, monty_mole_seg5_dl_05003F50), - GEO_ASM(0, geo_update_projectile_pos_from_parent), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, monty_mole_seg5_dl_050044B0), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 116, 0, 0, monty_mole_seg5_dl_05004C00), + GEO_ANIMATED_PART(LAYER_ALPHA, 116, 0, 0, monty_mole_seg5_dl_05004D30), + GEO_ANIMATED_PART(LAYER_OPAQUE, -68, -5, -40, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, monty_mole_seg5_dl_05003C48), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, -68, -5, 40, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, monty_mole_seg5_dl_05003518), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 80, 1, 78, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, monty_mole_seg5_dl_050032A0), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 80, 0, 0, monty_mole_seg5_dl_05003820), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 80, 1, -78, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, monty_mole_seg5_dl_050039D0), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 80, 0, 0, monty_mole_seg5_dl_05003F50), + GEO_ASM(0, geo_update_projectile_pos_from_parent), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/actors/mr_i_eyeball/geo.inc.c b/actors/mr_i_eyeball/geo.inc.c index b1a693b7..dc50a7c0 100644 --- a/actors/mr_i_eyeball/geo.inc.c +++ b/actors/mr_i_eyeball/geo.inc.c @@ -1,8 +1,8 @@ // 0x0D000000 const GeoLayout mr_i_geo[] = { - GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0x9B, 200), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, mr_i_eyeball_seg6_dl_06002080), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0x9B, 200), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, mr_i_eyeball_seg6_dl_06002080), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/actors/mr_i_iris/geo.inc.c b/actors/mr_i_iris/geo.inc.c index 31156664..e12155ff 100644 --- a/actors/mr_i_iris/geo.inc.c +++ b/actors/mr_i_iris/geo.inc.c @@ -1,30 +1,30 @@ // 0x0D00001C const GeoLayout mr_i_iris_geo[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_SWITCH_CASE(20, geo_switch_anim_state), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, mr_i_iris_seg6_dl_060041D8), - GEO_DISPLAY_LIST(LAYER_ALPHA, mr_i_iris_seg6_dl_060041F0), - GEO_DISPLAY_LIST(LAYER_ALPHA, mr_i_iris_seg6_dl_06004208), - GEO_DISPLAY_LIST(LAYER_ALPHA, mr_i_iris_seg6_dl_06004220), - GEO_DISPLAY_LIST(LAYER_ALPHA, mr_i_iris_seg6_dl_06004208), - GEO_DISPLAY_LIST(LAYER_ALPHA, mr_i_iris_seg6_dl_060041F0), - GEO_DISPLAY_LIST(LAYER_ALPHA, mr_i_iris_seg6_dl_060041D8), - GEO_DISPLAY_LIST(LAYER_ALPHA, mr_i_iris_seg6_dl_060041D8), - GEO_DISPLAY_LIST(LAYER_ALPHA, mr_i_iris_seg6_dl_060041D8), - GEO_DISPLAY_LIST(LAYER_ALPHA, mr_i_iris_seg6_dl_060041F0), - GEO_DISPLAY_LIST(LAYER_ALPHA, mr_i_iris_seg6_dl_06004208), - GEO_DISPLAY_LIST(LAYER_ALPHA, mr_i_iris_seg6_dl_06004220), - GEO_DISPLAY_LIST(LAYER_ALPHA, mr_i_iris_seg6_dl_06004208), - GEO_DISPLAY_LIST(LAYER_ALPHA, mr_i_iris_seg6_dl_060041F0), - GEO_DISPLAY_LIST(LAYER_ALPHA, mr_i_iris_seg6_dl_060041D8), - GEO_DISPLAY_LIST(LAYER_ALPHA, mr_i_iris_seg6_dl_060041D8), - GEO_DISPLAY_LIST(LAYER_ALPHA, mr_i_iris_seg6_dl_060041D8), - GEO_DISPLAY_LIST(LAYER_ALPHA, mr_i_iris_seg6_dl_060041D8), - GEO_DISPLAY_LIST(LAYER_ALPHA, mr_i_iris_seg6_dl_060041D8), - GEO_DISPLAY_LIST(LAYER_ALPHA, mr_i_iris_seg6_dl_060041D8), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_SWITCH_CASE(20, geo_switch_anim_state), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, mr_i_iris_seg6_dl_060041D8), + GEO_DISPLAY_LIST(LAYER_ALPHA, mr_i_iris_seg6_dl_060041F0), + GEO_DISPLAY_LIST(LAYER_ALPHA, mr_i_iris_seg6_dl_06004208), + GEO_DISPLAY_LIST(LAYER_ALPHA, mr_i_iris_seg6_dl_06004220), + GEO_DISPLAY_LIST(LAYER_ALPHA, mr_i_iris_seg6_dl_06004208), + GEO_DISPLAY_LIST(LAYER_ALPHA, mr_i_iris_seg6_dl_060041F0), + GEO_DISPLAY_LIST(LAYER_ALPHA, mr_i_iris_seg6_dl_060041D8), + GEO_DISPLAY_LIST(LAYER_ALPHA, mr_i_iris_seg6_dl_060041D8), + GEO_DISPLAY_LIST(LAYER_ALPHA, mr_i_iris_seg6_dl_060041D8), + GEO_DISPLAY_LIST(LAYER_ALPHA, mr_i_iris_seg6_dl_060041F0), + GEO_DISPLAY_LIST(LAYER_ALPHA, mr_i_iris_seg6_dl_06004208), + GEO_DISPLAY_LIST(LAYER_ALPHA, mr_i_iris_seg6_dl_06004220), + GEO_DISPLAY_LIST(LAYER_ALPHA, mr_i_iris_seg6_dl_06004208), + GEO_DISPLAY_LIST(LAYER_ALPHA, mr_i_iris_seg6_dl_060041F0), + GEO_DISPLAY_LIST(LAYER_ALPHA, mr_i_iris_seg6_dl_060041D8), + GEO_DISPLAY_LIST(LAYER_ALPHA, mr_i_iris_seg6_dl_060041D8), + GEO_DISPLAY_LIST(LAYER_ALPHA, mr_i_iris_seg6_dl_060041D8), + GEO_DISPLAY_LIST(LAYER_ALPHA, mr_i_iris_seg6_dl_060041D8), + GEO_DISPLAY_LIST(LAYER_ALPHA, mr_i_iris_seg6_dl_060041D8), + GEO_DISPLAY_LIST(LAYER_ALPHA, mr_i_iris_seg6_dl_060041D8), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/actors/mushroom_1up/geo.inc.c b/actors/mushroom_1up/geo.inc.c index 62c2bc3d..9a402095 100644 --- a/actors/mushroom_1up/geo.inc.c +++ b/actors/mushroom_1up/geo.inc.c @@ -1,8 +1,8 @@ // 0x16000E84 const GeoLayout mushroom_1up_geo[] = { - GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0xB4, 80), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, mushroom_1up_seg3_dl_0302A660), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0xB4, 80), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, mushroom_1up_seg3_dl_0302A660), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/actors/number/geo.inc.c b/actors/number/geo.inc.c index 0cf3845c..3abb7331 100644 --- a/actors/number/geo.inc.c +++ b/actors/number/geo.inc.c @@ -1,20 +1,20 @@ // 0x16000E14 const GeoLayout number_geo[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_SWITCH_CASE(10, geo_switch_anim_state), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, dl_billboard_num_0), - GEO_DISPLAY_LIST(LAYER_ALPHA, dl_billboard_num_1), - GEO_DISPLAY_LIST(LAYER_ALPHA, dl_billboard_num_2), - GEO_DISPLAY_LIST(LAYER_ALPHA, dl_billboard_num_3), - GEO_DISPLAY_LIST(LAYER_ALPHA, dl_billboard_num_4), - GEO_DISPLAY_LIST(LAYER_ALPHA, dl_billboard_num_5), - GEO_DISPLAY_LIST(LAYER_ALPHA, dl_billboard_num_6), - GEO_DISPLAY_LIST(LAYER_ALPHA, dl_billboard_num_7), - GEO_DISPLAY_LIST(LAYER_ALPHA, dl_billboard_num_8), - GEO_DISPLAY_LIST(LAYER_ALPHA, dl_billboard_num_9), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_SWITCH_CASE(10, geo_switch_anim_state), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, dl_billboard_num_0), + GEO_DISPLAY_LIST(LAYER_ALPHA, dl_billboard_num_1), + GEO_DISPLAY_LIST(LAYER_ALPHA, dl_billboard_num_2), + GEO_DISPLAY_LIST(LAYER_ALPHA, dl_billboard_num_3), + GEO_DISPLAY_LIST(LAYER_ALPHA, dl_billboard_num_4), + GEO_DISPLAY_LIST(LAYER_ALPHA, dl_billboard_num_5), + GEO_DISPLAY_LIST(LAYER_ALPHA, dl_billboard_num_6), + GEO_DISPLAY_LIST(LAYER_ALPHA, dl_billboard_num_7), + GEO_DISPLAY_LIST(LAYER_ALPHA, dl_billboard_num_8), + GEO_DISPLAY_LIST(LAYER_ALPHA, dl_billboard_num_9), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/actors/peach/geo.inc.c b/actors/peach/geo.inc.c index 876bfee5..8194b0ed 100644 --- a/actors/peach/geo.inc.c +++ b/actors/peach/geo.inc.c @@ -1,154 +1,154 @@ // 0x0C000098 const GeoLayout peach_geo_000098[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, peach_seg5_dl_05007230), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 78, 0, 0, peach_seg5_dl_05006A18), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, peach_seg5_dl_05007230), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 132, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_SWITCH_CASE(8, geo_switch_peach_eyes), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, peach_seg5_dl_05005CE0), - GEO_DISPLAY_LIST(LAYER_OPAQUE, peach_seg5_dl_05005D38), - GEO_DISPLAY_LIST(LAYER_OPAQUE, peach_seg5_dl_05005D90), - GEO_DISPLAY_LIST(LAYER_OPAQUE, peach_seg5_dl_05005DE8), - GEO_DISPLAY_LIST(LAYER_OPAQUE, peach_seg5_dl_05005E40), - GEO_DISPLAY_LIST(LAYER_OPAQUE, peach_seg5_dl_05005E98), - GEO_DISPLAY_LIST(LAYER_OPAQUE, peach_seg5_dl_05005EF0), - GEO_DISPLAY_LIST(LAYER_OPAQUE, peach_seg5_dl_05005F48), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 38, -78, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, peach_seg5_dl_05007AB8), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 132, 0, 0, peach_seg5_dl_05009148), - GEO_ANIMATED_PART(LAYER_OPAQUE, 132, 0, 0, peach_seg5_dl_05008F20), - GEO_ANIMATED_PART(LAYER_OPAQUE, 63, 0, 84, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, peach_seg5_dl_05007E58), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 104, 0, 0, peach_seg5_dl_050087A8), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 87, 0, 0, peach_seg5_dl_05009500), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, peach_seg5_dl_05008560), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 63, 0, -84, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, peach_seg5_dl_05008228), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 104, 0, 0, peach_seg5_dl_05008CF8), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 87, 0, 0, peach_seg5_dl_05009940), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, peach_seg5_dl_05008AB0), - GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 78, 0, 0, peach_seg5_dl_05006A18), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 132, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_SWITCH_CASE(8, geo_switch_peach_eyes), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, peach_seg5_dl_05005CE0), + GEO_DISPLAY_LIST(LAYER_OPAQUE, peach_seg5_dl_05005D38), + GEO_DISPLAY_LIST(LAYER_OPAQUE, peach_seg5_dl_05005D90), + GEO_DISPLAY_LIST(LAYER_OPAQUE, peach_seg5_dl_05005DE8), + GEO_DISPLAY_LIST(LAYER_OPAQUE, peach_seg5_dl_05005E40), + GEO_DISPLAY_LIST(LAYER_OPAQUE, peach_seg5_dl_05005E98), + GEO_DISPLAY_LIST(LAYER_OPAQUE, peach_seg5_dl_05005EF0), + GEO_DISPLAY_LIST(LAYER_OPAQUE, peach_seg5_dl_05005F48), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 38, -78, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, peach_seg5_dl_05007AB8), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 132, 0, 0, peach_seg5_dl_05009148), + GEO_ANIMATED_PART(LAYER_OPAQUE, 132, 0, 0, peach_seg5_dl_05008F20), + GEO_ANIMATED_PART(LAYER_OPAQUE, 63, 0, 84, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, peach_seg5_dl_05007E58), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 104, 0, 0, peach_seg5_dl_050087A8), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 87, 0, 0, peach_seg5_dl_05009500), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, peach_seg5_dl_05008560), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 63, 0, -84, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, peach_seg5_dl_05008228), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 104, 0, 0, peach_seg5_dl_05008CF8), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 87, 0, 0, peach_seg5_dl_05009940), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, peach_seg5_dl_05008AB0), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 78, 0, 0, peach_seg5_dl_050060E0), + GEO_ANIMATED_PART(LAYER_OPAQUE, -23, -1, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, peach_seg5_dl_0500A0A8), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 78, 0, 0, peach_seg5_dl_050060E0), - GEO_ANIMATED_PART(LAYER_OPAQUE, -23, -1, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, peach_seg5_dl_0500A0A8), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x0C000254 const GeoLayout peach_geo_000254[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, NULL), - GEO_OPEN_NODE(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, NULL), + GEO_OPEN_NODE(), #ifdef VERSION_JP - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, peach_seg5_dl_05007230), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, peach_seg5_dl_05007230), #else - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, peach_seg5_us_dl_05007288), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, peach_seg5_us_dl_05007288), #endif - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 78, 0, 0, peach_seg5_dl_05006A18), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 132, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_SWITCH_CASE(8, geo_switch_peach_eyes), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, peach_seg5_dl_05005CE0), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, peach_seg5_dl_05005D38), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, peach_seg5_dl_05005D90), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, peach_seg5_dl_05005DE8), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, peach_seg5_dl_05005E40), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, peach_seg5_dl_05005E98), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, peach_seg5_dl_05005EF0), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, peach_seg5_dl_05005F48), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 38, -78, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, peach_seg5_dl_05007AB8), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 132, 0, 0, peach_seg5_dl_05009148), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 132, 0, 0, peach_seg5_dl_05008F20), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 63, 0, 84, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, peach_seg5_dl_05007E58), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 104, 0, 0, peach_seg5_dl_050087A8), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 87, 0, 0, peach_seg5_dl_05009500), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, peach_seg5_dl_05008560), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 63, 0, -84, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, peach_seg5_dl_05008228), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 104, 0, 0, peach_seg5_dl_05008CF8), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 87, 0, 0, peach_seg5_dl_05009940), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, peach_seg5_dl_05008AB0), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 78, 0, 0, peach_seg5_dl_050060E0), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, -23, -1, 0, NULL), GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 78, 0, 0, peach_seg5_dl_05006A18), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 132, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_SWITCH_CASE(8, geo_switch_peach_eyes), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, peach_seg5_dl_05005CE0), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, peach_seg5_dl_05005D38), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, peach_seg5_dl_05005D90), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, peach_seg5_dl_05005DE8), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, peach_seg5_dl_05005E40), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, peach_seg5_dl_05005E98), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, peach_seg5_dl_05005EF0), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, peach_seg5_dl_05005F48), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 38, -78, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, peach_seg5_dl_05007AB8), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 132, 0, 0, peach_seg5_dl_05009148), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 132, 0, 0, peach_seg5_dl_05008F20), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 63, 0, 84, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, peach_seg5_dl_05007E58), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 104, 0, 0, peach_seg5_dl_050087A8), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 87, 0, 0, peach_seg5_dl_05009500), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, peach_seg5_dl_05008560), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 63, 0, -84, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, peach_seg5_dl_05008228), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 104, 0, 0, peach_seg5_dl_05008CF8), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 87, 0, 0, peach_seg5_dl_05009940), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, peach_seg5_dl_05008AB0), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 78, 0, 0, peach_seg5_dl_050060E0), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, -23, -1, 0, NULL), + GEO_OPEN_NODE(), #ifdef VERSION_JP - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, peach_seg5_dl_0500A0A8), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, peach_seg5_dl_0500A0A8), #else - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, peach_seg5_us_dl_0500A188), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, peach_seg5_us_dl_0500A188), #endif + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x0C000410 const GeoLayout peach_geo[] = { - GEO_SHADOW(SHADOW_CIRCLE_9_VERTS, 0x96, 100), - GEO_OPEN_NODE(), - GEO_SCALE(0x00, 16384), - GEO_OPEN_NODE(), - GEO_ASM(10, geo_update_layer_transparency), - GEO_SWITCH_CASE(2, geo_switch_anim_state), - GEO_OPEN_NODE(), - GEO_BRANCH(1, peach_geo_000098), - GEO_BRANCH(1, peach_geo_000254), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_SHADOW(SHADOW_CIRCLE_9_VERTS, 0x96, 100), + GEO_OPEN_NODE(), + GEO_SCALE(0x00, 16384), + GEO_OPEN_NODE(), + GEO_ASM(10, geo_update_layer_transparency), + GEO_SWITCH_CASE(2, geo_switch_anim_state), + GEO_OPEN_NODE(), + GEO_BRANCH(1, peach_geo_000098), + GEO_BRANCH(1, peach_geo_000254), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; UNUSED static const u64 peach_unused_1 = 0; diff --git a/actors/penguin/geo.inc.c b/actors/penguin/geo.inc.c index aea40dd9..d67f0844 100644 --- a/actors/penguin/geo.inc.c +++ b/actors/penguin/geo.inc.c @@ -1,44 +1,44 @@ // 0x0C000104 const GeoLayout penguin_geo[] = { -#if defined(VERSION_EU) || defined(VERSION_SH) - GEO_SHADOW(SHADOW_CIRCLE_9_VERTS, 0x96, 60), +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) + GEO_SHADOW(SHADOW_CIRCLE_9_VERTS, 0x96, 60), #else - GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0x96, 100), + GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0x96, 100), #endif - GEO_OPEN_NODE(), - GEO_SCALE(0x00, 16384), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 40, penguin_seg5_dl_05007540), - GEO_OPEN_NODE(), + GEO_OPEN_NODE(), + GEO_SCALE(0x00, 16384), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 40, penguin_seg5_dl_05007540), + GEO_OPEN_NODE(), GEO_ANIMATED_PART(LAYER_OPAQUE, -51, 84, -13, NULL), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, penguin_seg5_dl_05007198), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, penguin_seg5_dl_05007198), GEO_CLOSE_NODE(), GEO_ANIMATED_PART(LAYER_OPAQUE, 51, 84, -13, NULL), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, penguin_seg5_dl_050071E8), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, penguin_seg5_dl_050071E8), GEO_CLOSE_NODE(), GEO_ANIMATED_PART(LAYER_OPAQUE, -38, -54, -13, NULL), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, penguin_seg5_dl_05007238), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, penguin_seg5_dl_05007238), GEO_CLOSE_NODE(), GEO_ANIMATED_PART(LAYER_OPAQUE, 38, -54, -13, NULL), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, penguin_seg5_dl_050072C8), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, penguin_seg5_dl_050072C8), GEO_CLOSE_NODE(), GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 111, -19, NULL), GEO_OPEN_NODE(), - GEO_SWITCH_CASE(5, geo_switch_tuxie_mother_eyes), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, penguin_seg5_dl_05006428), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, penguin_seg5_dl_05006458), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, penguin_seg5_dl_05006488), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, penguin_seg5_dl_050064B8), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, penguin_seg5_dl_050064E8), // unused, seen in Shoshinkai 1995 footage - GEO_CLOSE_NODE(), + GEO_SWITCH_CASE(5, geo_switch_tuxie_mother_eyes), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, penguin_seg5_dl_05006428), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, penguin_seg5_dl_05006458), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, penguin_seg5_dl_05006488), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, penguin_seg5_dl_050064B8), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, penguin_seg5_dl_050064E8), // unused, seen in Shoshinkai 1995 footage + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/actors/piranha_plant/geo.inc.c b/actors/piranha_plant/geo.inc.c index 4b48a6c3..fe6acdb2 100644 --- a/actors/piranha_plant/geo.inc.c +++ b/actors/piranha_plant/geo.inc.c @@ -1,47 +1,47 @@ // 0x0D000358 const GeoLayout piranha_plant_geo[] = { - GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0x9B, 200), - GEO_OPEN_NODE(), - GEO_SCALE(0x00, 16384), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 14, 3, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, piranha_plant_seg6_dl_06015850), + GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0x9B, 200), + GEO_OPEN_NODE(), + GEO_SCALE(0x00, 16384), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 14, 3, NULL), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 46, 0, 0, piranha_plant_seg6_dl_06016F20), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 154, 0, 0, piranha_plant_seg6_dl_06016D98), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 153, 0, 0, piranha_plant_seg6_dl_06016C10), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 236, 42, 0, NULL), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, piranha_plant_seg6_dl_06015850), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 46, 0, 0, piranha_plant_seg6_dl_06016F20), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 154, 0, 0, piranha_plant_seg6_dl_06016D98), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, piranha_plant_seg6_dl_060160B0), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, piranha_plant_seg6_dl_06016120), - GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 153, 0, 0, piranha_plant_seg6_dl_06016C10), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 236, 42, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, piranha_plant_seg6_dl_060160B0), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, piranha_plant_seg6_dl_06016120), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 217, -2, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, piranha_plant_seg6_dl_060169E8), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, piranha_plant_seg6_dl_06016A78), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 217, -2, 0, NULL), + GEO_ANIMATED_PART(LAYER_OPAQUE, 49, 0, -34, NULL), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, piranha_plant_seg6_dl_060169E8), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, piranha_plant_seg6_dl_06016A78), - GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_ALPHA, 0, 0, 0, piranha_plant_seg6_dl_06015480), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 49, 0, -34, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_ALPHA, 0, 0, 0, piranha_plant_seg6_dl_06015480), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 49, 0, 37, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_ALPHA, 0, 0, 0, piranha_plant_seg6_dl_06015578), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 49, 0, 37, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_ALPHA, 0, 0, 0, piranha_plant_seg6_dl_06015578), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/actors/pokey/geo.inc.c b/actors/pokey/geo.inc.c index f4ca96f2..abe9db86 100644 --- a/actors/pokey/geo.inc.c +++ b/actors/pokey/geo.inc.c @@ -1,21 +1,21 @@ // 0x0C000610 const GeoLayout pokey_head_geo[] = { - GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0x96, 50), - GEO_OPEN_NODE(), - GEO_SWITCH_CASE(2, geo_switch_anim_state), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, pokey_seg5_dl_050127D8), - GEO_DISPLAY_LIST(LAYER_ALPHA, pokey_seg5_dl_05012808), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0x96, 50), + GEO_OPEN_NODE(), + GEO_SWITCH_CASE(2, geo_switch_anim_state), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, pokey_seg5_dl_050127D8), + GEO_DISPLAY_LIST(LAYER_ALPHA, pokey_seg5_dl_05012808), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; // 0x0C000644 const GeoLayout pokey_body_part_geo[] = { - GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0x96, 50), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, pokey_seg5_dl_050130B0), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0x96, 50), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, pokey_seg5_dl_050130B0), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/actors/poundable_pole/geo.inc.c b/actors/poundable_pole/geo.inc.c index 719a9b7d..ea1b9dcf 100644 --- a/actors/poundable_pole/geo.inc.c +++ b/actors/poundable_pole/geo.inc.c @@ -1,8 +1,8 @@ // 0x0D0000B8 const GeoLayout wooden_post_geo[] = { - GEO_CULLING_RADIUS(450), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, poundable_pole_seg6_dl_06002410), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(450), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, poundable_pole_seg6_dl_06002410), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/actors/power_meter/model.inc.c b/actors/power_meter/model.inc.c index 1a2c17f6..be095b78 100644 --- a/actors/power_meter/model.inc.c +++ b/actors/power_meter/model.inc.c @@ -2,6 +2,15 @@ UNUSED static const u64 power_meter_unused_1 = 0; +#if defined(VERSION_CN) +ALIGNED8 static const Texture texture_power_meter_left_side[] = { +#include "actors/power_meter/power_meter_left_side_cn.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_power_meter_right_side[] = { +#include "actors/power_meter/power_meter_right_side_cn.rgba16.inc.c" +}; +#else // 0x030233E0 ALIGNED8 static const Texture texture_power_meter_left_side[] = { #include "actors/power_meter/power_meter_left_side.rgba16.inc.c" @@ -11,6 +20,7 @@ ALIGNED8 static const Texture texture_power_meter_left_side[] = { ALIGNED8 static const Texture texture_power_meter_right_side[] = { #include "actors/power_meter/power_meter_right_side.rgba16.inc.c" }; +#endif // 0x030253E0 ALIGNED8 static const Texture texture_power_meter_full[] = { @@ -102,10 +112,17 @@ const Gfx dl_power_meter_base[] = { // 0x03029530 static const Vtx vertex_power_meter_health_segments[] = { +#if defined(VERSION_CN) + {{{ -16, -20, 0}, 0, { 0, 992}, {0xff, 0xff, 0xff, 0xff}}}, + {{{ 15, -20, 0}, 0, { 992, 992}, {0xff, 0xff, 0xff, 0xff}}}, + {{{ 15, 12, 0}, 0, { 992, 0}, {0xff, 0xff, 0xff, 0xff}}}, + {{{ -16, 12, 0}, 0, { 0, 0}, {0xff, 0xff, 0xff, 0xff}}}, +#else {{{ -16, -16, 0}, 0, { 0, 992}, {0xff, 0xff, 0xff, 0xff}}}, {{{ 15, -16, 0}, 0, { 992, 992}, {0xff, 0xff, 0xff, 0xff}}}, {{{ 15, 16, 0}, 0, { 992, 0}, {0xff, 0xff, 0xff, 0xff}}}, {{{ -16, 16, 0}, 0, { 0, 0}, {0xff, 0xff, 0xff, 0xff}}}, +#endif }; // 0x03029570 - 0x030295A0 diff --git a/actors/purple_switch/geo.inc.c b/actors/purple_switch/geo.inc.c index 85567220..40cdd173 100644 --- a/actors/purple_switch/geo.inc.c +++ b/actors/purple_switch/geo.inc.c @@ -1,8 +1,8 @@ // 0x0F0004CC const GeoLayout purple_switch_geo[] = { - GEO_CULLING_RADIUS(300), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, purple_switch_seg8_dl_0800C718), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(300), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, purple_switch_seg8_dl_0800C718), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/actors/scuttlebug/geo.inc.c b/actors/scuttlebug/geo.inc.c index 254ebcdf..8f6ff3e7 100644 --- a/actors/scuttlebug/geo.inc.c +++ b/actors/scuttlebug/geo.inc.c @@ -1,118 +1,118 @@ // 0x0D000394 const GeoLayout scuttlebug_geo[] = { - GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0x96, 100), - GEO_OPEN_NODE(), - GEO_SCALE(0x00, 16384), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, -29, 0, NULL), + GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0x96, 100), + GEO_OPEN_NODE(), + GEO_SCALE(0x00, 16384), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, -1, 113, 112, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 198, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 195, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_ALPHA, 0, 0, 0, scuttlebug_seg6_dl_06014378), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_ALPHA, 0, 0, 0, scuttlebug_seg6_dl_06014270), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_ALPHA, 0, 0, 0, scuttlebug_seg6_dl_06014188), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, -1, 109, -116, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 198, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 195, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_ALPHA, 0, 0, 0, scuttlebug_seg6_dl_06014378), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_ALPHA, 0, 0, 0, scuttlebug_seg6_dl_06014270), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_ALPHA, 0, 0, 0, scuttlebug_seg6_dl_06014188), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_BILLBOARD(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, scuttlebug_seg6_dl_060139F8), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, -29, -57, 28, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 158, 0, 0, NULL), - GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, -29, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, -1, 113, 112, NULL), + GEO_OPEN_NODE(), GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), GEO_OPEN_NODE(), - GEO_BILLBOARD(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, scuttlebug_seg6_dl_06013AE8), - GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 198, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 195, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_ALPHA, 0, 0, 0, scuttlebug_seg6_dl_06014378), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_ALPHA, 0, 0, 0, scuttlebug_seg6_dl_06014270), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_ALPHA, 0, 0, 0, scuttlebug_seg6_dl_06014188), GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_ALPHA, 0, 0, 0, scuttlebug_seg6_dl_06013CB8), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, -29, 55, 28, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 157, 0, 0, NULL), - GEO_OPEN_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, -1, 109, -116, NULL), + GEO_OPEN_NODE(), GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), GEO_OPEN_NODE(), - GEO_BILLBOARD(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, scuttlebug_seg6_dl_06013BD0), - GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 198, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 195, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_ALPHA, 0, 0, 0, scuttlebug_seg6_dl_06014378), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_ALPHA, 0, 0, 0, scuttlebug_seg6_dl_06014270), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_ALPHA, 0, 0, 0, scuttlebug_seg6_dl_06014188), GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_ALPHA, 0, 0, 0, scuttlebug_seg6_dl_06013DA0), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, -1, -116, -111, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 198, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 195, 0, 0, NULL), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_BILLBOARD(), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_ALPHA, 0, 0, 0, scuttlebug_seg6_dl_06014378), + GEO_DISPLAY_LIST(LAYER_ALPHA, scuttlebug_seg6_dl_060139F8), GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_ALPHA, 0, 0, 0, scuttlebug_seg6_dl_06014270), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_ALPHA, 0, 0, 0, scuttlebug_seg6_dl_06014188), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, -1, -116, 112, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 195, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 199, 0, 0, NULL), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, -29, -57, 28, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_ALPHA, 0, 0, 0, scuttlebug_seg6_dl_06014378), + GEO_ANIMATED_PART(LAYER_OPAQUE, 158, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_BILLBOARD(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, scuttlebug_seg6_dl_06013AE8), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_ALPHA, 0, 0, 0, scuttlebug_seg6_dl_06013CB8), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_ALPHA, 0, 0, 0, scuttlebug_seg6_dl_06014270), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_ALPHA, 0, 0, 0, scuttlebug_seg6_dl_06014188), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, scuttlebug_seg6_dl_060140F0), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, -29, 55, 28, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 157, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_BILLBOARD(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, scuttlebug_seg6_dl_06013BD0), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_ALPHA, 0, 0, 0, scuttlebug_seg6_dl_06013DA0), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, -1, -116, -111, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 198, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 195, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_ALPHA, 0, 0, 0, scuttlebug_seg6_dl_06014378), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_ALPHA, 0, 0, 0, scuttlebug_seg6_dl_06014270), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_ALPHA, 0, 0, 0, scuttlebug_seg6_dl_06014188), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, -1, -116, 112, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 195, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 199, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_ALPHA, 0, 0, 0, scuttlebug_seg6_dl_06014378), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_ALPHA, 0, 0, 0, scuttlebug_seg6_dl_06014270), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_ALPHA, 0, 0, 0, scuttlebug_seg6_dl_06014188), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, scuttlebug_seg6_dl_060140F0), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/actors/seaweed/geo.inc.c b/actors/seaweed/geo.inc.c index a085a505..2aed0ebe 100644 --- a/actors/seaweed/geo.inc.c +++ b/actors/seaweed/geo.inc.c @@ -1,20 +1,20 @@ // 0x0D000284 const GeoLayout seaweed_geo[] = { - GEO_SCALE(0x00, 16384), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_ALPHA, 0, 0, 0, seaweed_seg6_dl_0600A180), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_ALPHA, 238, 0, 0, seaweed_seg6_dl_0600A088), + GEO_SCALE(0x00, 16384), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_ALPHA, 0, 0, 0, seaweed_seg6_dl_0600A180), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_ALPHA, 317, 0, 0, seaweed_seg6_dl_06009F90), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_ALPHA, 314, 0, 0, seaweed_seg6_dl_06009E98), - GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_ALPHA, 238, 0, 0, seaweed_seg6_dl_0600A088), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_ALPHA, 317, 0, 0, seaweed_seg6_dl_06009F90), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_ALPHA, 314, 0, 0, seaweed_seg6_dl_06009E98), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/actors/skeeter/geo.inc.c b/actors/skeeter/geo.inc.c index aafd4cd5..a12db4dc 100644 --- a/actors/skeeter/geo.inc.c +++ b/actors/skeeter/geo.inc.c @@ -1,98 +1,98 @@ // 0x0D000000 const GeoLayout skeeter_geo[] = { - GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0x96, 100), - GEO_OPEN_NODE(), - GEO_SCALE(0x00, 16384), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), + GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0x96, 100), + GEO_OPEN_NODE(), + GEO_SCALE(0x00, 16384), + GEO_OPEN_NODE(), GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), GEO_OPEN_NODE(), - GEO_BILLBOARD(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, skeeter_seg6_dl_06000A08), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 100, -75, -105, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, skeeter_seg6_dl_06004070), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 405, 0, 0, skeeter_seg6_dl_06004040), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 540, 0, 0, skeeter_seg6_dl_06000EC0), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, -40, -75, -125, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, skeeter_seg6_dl_06004120), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 405, 0, 0, skeeter_seg6_dl_060040F0), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 540, 0, 0, skeeter_seg6_dl_06000EC0), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, -40, -75, 125, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, skeeter_seg6_dl_060041D0), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 405, 0, 0, skeeter_seg6_dl_060041A0), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 540, 0, 0, skeeter_seg6_dl_06000EC0), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, -150, -87, 111, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_BILLBOARD(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, skeeter_seg6_dl_06000BD8), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_ALPHA, 0, 0, 0, skeeter_seg6_dl_06000CA8), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, -150, -87, -111, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_ALPHA, 0, 0, 0, skeeter_seg6_dl_06000D78), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_BILLBOARD(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, skeeter_seg6_dl_06000BD8), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 100, -75, 95, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, skeeter_seg6_dl_06004648), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 405, 0, 0, skeeter_seg6_dl_06004618), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 540, 0, 0, skeeter_seg6_dl_06000EC0), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 147, 84, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, skeeter_seg6_dl_06005328), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 216, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_BILLBOARD(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_BILLBOARD(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, skeeter_seg6_dl_06000A08), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 100, -75, -105, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, skeeter_seg6_dl_06004070), GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, skeeter_seg6_dl_06000AF0), + GEO_ANIMATED_PART(LAYER_OPAQUE, 405, 0, 0, skeeter_seg6_dl_06004040), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 540, 0, 0, skeeter_seg6_dl_06000EC0), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 216, 0, 0, NULL), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, -40, -75, -125, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, skeeter_seg6_dl_06004120), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 405, 0, 0, skeeter_seg6_dl_060040F0), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 540, 0, 0, skeeter_seg6_dl_06000EC0), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, -40, -75, 125, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, skeeter_seg6_dl_060041D0), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 405, 0, 0, skeeter_seg6_dl_060041A0), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 540, 0, 0, skeeter_seg6_dl_06000EC0), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, -150, -87, 111, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_BILLBOARD(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, skeeter_seg6_dl_06000BD8), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_ALPHA, 0, 0, 0, skeeter_seg6_dl_06000CA8), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, -150, -87, -111, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_ALPHA, 0, 0, 0, skeeter_seg6_dl_06000D78), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_BILLBOARD(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, skeeter_seg6_dl_06000BD8), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 100, -75, 95, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, skeeter_seg6_dl_06004648), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 405, 0, 0, skeeter_seg6_dl_06004618), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 540, 0, 0, skeeter_seg6_dl_06000EC0), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 147, 84, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, skeeter_seg6_dl_06005328), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 216, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_BILLBOARD(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, skeeter_seg6_dl_06000AF0), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 216, 0, 0, NULL), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/actors/small_key/geo.inc.c b/actors/small_key/geo.inc.c index 882ad244..480f599d 100644 --- a/actors/small_key/geo.inc.c +++ b/actors/small_key/geo.inc.c @@ -1,11 +1,11 @@ // 0x0C000188 const GeoLayout small_key_geo[] = { - GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0x96, 80), - GEO_OPEN_NODE(), - GEO_SCALE(0x00, 16384), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, small_key_seg5_dl_05006A68), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0x96, 80), + GEO_OPEN_NODE(), + GEO_SCALE(0x00, 16384), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, small_key_seg5_dl_05006A68), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/actors/snowman/geo.inc.c b/actors/snowman/geo.inc.c index 2dded75e..d079f435 100644 --- a/actors/snowman/geo.inc.c +++ b/actors/snowman/geo.inc.c @@ -1,57 +1,57 @@ // 0x0C00021C const GeoLayout mr_blizzard_hidden_geo[] = { - GEO_SCALE(0x00, 16384), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_BILLBOARD(), + GEO_SCALE(0x00, 16384), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, snowman_seg5_dl_0500C620), + GEO_BILLBOARD(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, snowman_seg5_dl_0500C620), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 356, 0, 0, NULL), GEO_OPEN_NODE(), - GEO_BILLBOARD(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, snowman_seg5_dl_0500CBF8), - GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 356, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_BILLBOARD(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, snowman_seg5_dl_0500CBF8), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_ALPHA, 356, 0, 0, snowman_seg5_dl_0500CCE8), + GEO_ANIMATED_PART(LAYER_ALPHA, 356, 0, 0, snowman_seg5_dl_0500C760), + GEO_SWITCH_CASE(2, geo_switch_anim_state), + GEO_OPEN_NODE(), + GEO_NODE_START(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_SCALE(0x00, 65536), + GEO_OPEN_NODE(), + GEO_TRANSLATE_ROTATE_WITH_DL(LAYER_OPAQUE, 490, 14, 43, 305, 0, 248, mario_cap_seg3_dl_03022F48), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 89, 0, -229, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, snowman_seg5_dl_0500C500), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 68, 0, 0, snowman_seg5_dl_0500CAA8), + GEO_ASM(0, geo_update_projectile_pos_from_parent), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 356, 0, 0, NULL), GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_ALPHA, 356, 0, 0, snowman_seg5_dl_0500CCE8), - GEO_ANIMATED_PART(LAYER_ALPHA, 356, 0, 0, snowman_seg5_dl_0500C760), - GEO_SWITCH_CASE(2, geo_switch_anim_state), - GEO_OPEN_NODE(), - GEO_NODE_START(), - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_SCALE(0x00, 65536), - GEO_OPEN_NODE(), - GEO_TRANSLATE_ROTATE_WITH_DL(LAYER_OPAQUE, 490, 14, 43, 305, 0, 248, mario_cap_seg3_dl_03022F48), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 89, 0, -229, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, snowman_seg5_dl_0500C500), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 68, 0, 0, snowman_seg5_dl_0500CAA8), - GEO_ASM(0, geo_update_projectile_pos_from_parent), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 356, 0, 0, NULL), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; // 0x0C000348 const GeoLayout mr_blizzard_geo[] = { - GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0xB4, 160), - GEO_OPEN_NODE(), - GEO_BRANCH_AND_LINK(mr_blizzard_hidden_geo), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0xB4, 160), + GEO_OPEN_NODE(), + GEO_BRANCH_AND_LINK(mr_blizzard_hidden_geo), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/actors/snufit/geo.inc.c b/actors/snufit/geo.inc.c index a8aabecc..b1ecd32e 100644 --- a/actors/snufit/geo.inc.c +++ b/actors/snufit/geo.inc.c @@ -1,27 +1,27 @@ // 0x0D0001A0 const GeoLayout snufit_geo[] = { - GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0x96, 100), - GEO_OPEN_NODE(), - GEO_SCALE(0x00, 16384), - GEO_OPEN_NODE(), - GEO_ASM(0, geo_snufit_move_mask), - GEO_TRANSLATE_NODE(0x00, 0, 0, 0), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, snufit_seg6_dl_06009748), - GEO_CLOSE_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, snufit_seg6_dl_06009498), - GEO_DISPLAY_LIST(LAYER_OPAQUE, snufit_seg6_dl_06009938), - GEO_DISPLAY_LIST(LAYER_OPAQUE, snufit_seg6_dl_06009B68), - GEO_BILLBOARD(), - GEO_OPEN_NODE(), - GEO_ASM(0, geo_snufit_scale_body), - GEO_SCALE(0x00, 0), + GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0x96, 100), + GEO_OPEN_NODE(), + GEO_SCALE(0x00, 16384), + GEO_OPEN_NODE(), + GEO_ASM(0, geo_snufit_move_mask), + GEO_TRANSLATE_NODE(0x00, 0, 0, 0), GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, snufit_seg6_dl_06009A10), + GEO_DISPLAY_LIST(LAYER_OPAQUE, snufit_seg6_dl_06009748), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), -GEO_CLOSE_NODE(), //! more close than open nodes -GEO_END(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, snufit_seg6_dl_06009498), + GEO_DISPLAY_LIST(LAYER_OPAQUE, snufit_seg6_dl_06009938), + GEO_DISPLAY_LIST(LAYER_OPAQUE, snufit_seg6_dl_06009B68), + GEO_BILLBOARD(), + GEO_OPEN_NODE(), + GEO_ASM(0, geo_snufit_scale_body), + GEO_SCALE(0x00, 0), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, snufit_seg6_dl_06009A10), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), //! more close than open nodes + GEO_END(), }; diff --git a/actors/sparkle/geo.inc.c b/actors/sparkle/geo.inc.c index d96da669..0bdf6181 100644 --- a/actors/sparkle/geo.inc.c +++ b/actors/sparkle/geo.inc.c @@ -1,19 +1,19 @@ // 0x170001BC const GeoLayout sparkles_geo[] = { - GEO_SWITCH_CASE(12, geo_switch_anim_state), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, sparkles_seg4_dl_0402A570), - GEO_DISPLAY_LIST(LAYER_ALPHA, sparkles_seg4_dl_0402A570), - GEO_DISPLAY_LIST(LAYER_ALPHA, sparkles_seg4_dl_0402A558), - GEO_DISPLAY_LIST(LAYER_ALPHA, sparkles_seg4_dl_0402A558), - GEO_DISPLAY_LIST(LAYER_ALPHA, sparkles_seg4_dl_0402A540), - GEO_DISPLAY_LIST(LAYER_ALPHA, sparkles_seg4_dl_0402A540), - GEO_DISPLAY_LIST(LAYER_ALPHA, sparkles_seg4_dl_0402A528), - GEO_DISPLAY_LIST(LAYER_ALPHA, sparkles_seg4_dl_0402A528), - GEO_DISPLAY_LIST(LAYER_ALPHA, sparkles_seg4_dl_0402A510), - GEO_DISPLAY_LIST(LAYER_ALPHA, sparkles_seg4_dl_0402A510), - GEO_DISPLAY_LIST(LAYER_ALPHA, sparkles_seg4_dl_0402A4F8), - GEO_DISPLAY_LIST(LAYER_ALPHA, sparkles_seg4_dl_0402A4F8), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_SWITCH_CASE(12, geo_switch_anim_state), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, sparkles_seg4_dl_0402A570), + GEO_DISPLAY_LIST(LAYER_ALPHA, sparkles_seg4_dl_0402A570), + GEO_DISPLAY_LIST(LAYER_ALPHA, sparkles_seg4_dl_0402A558), + GEO_DISPLAY_LIST(LAYER_ALPHA, sparkles_seg4_dl_0402A558), + GEO_DISPLAY_LIST(LAYER_ALPHA, sparkles_seg4_dl_0402A540), + GEO_DISPLAY_LIST(LAYER_ALPHA, sparkles_seg4_dl_0402A540), + GEO_DISPLAY_LIST(LAYER_ALPHA, sparkles_seg4_dl_0402A528), + GEO_DISPLAY_LIST(LAYER_ALPHA, sparkles_seg4_dl_0402A528), + GEO_DISPLAY_LIST(LAYER_ALPHA, sparkles_seg4_dl_0402A510), + GEO_DISPLAY_LIST(LAYER_ALPHA, sparkles_seg4_dl_0402A510), + GEO_DISPLAY_LIST(LAYER_ALPHA, sparkles_seg4_dl_0402A4F8), + GEO_DISPLAY_LIST(LAYER_ALPHA, sparkles_seg4_dl_0402A4F8), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/actors/sparkle_animation/geo.inc.c b/actors/sparkle_animation/geo.inc.c index b6110b59..b7a48c89 100644 --- a/actors/sparkle_animation/geo.inc.c +++ b/actors/sparkle_animation/geo.inc.c @@ -1,16 +1,16 @@ // 0x17000284 const GeoLayout sparkles_animation_geo[] = { - GEO_SWITCH_CASE(9, geo_switch_anim_state), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, sparkles_animation_seg4_dl_04035300), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, sparkles_animation_seg4_dl_04035318), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, sparkles_animation_seg4_dl_04035330), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, sparkles_animation_seg4_dl_04035348), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, sparkles_animation_seg4_dl_04035360), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, sparkles_animation_seg4_dl_04035348), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, sparkles_animation_seg4_dl_04035330), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, sparkles_animation_seg4_dl_04035318), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, sparkles_animation_seg4_dl_04035300), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_SWITCH_CASE(9, geo_switch_anim_state), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, sparkles_animation_seg4_dl_04035300), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, sparkles_animation_seg4_dl_04035318), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, sparkles_animation_seg4_dl_04035330), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, sparkles_animation_seg4_dl_04035348), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, sparkles_animation_seg4_dl_04035360), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, sparkles_animation_seg4_dl_04035348), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, sparkles_animation_seg4_dl_04035330), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, sparkles_animation_seg4_dl_04035318), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, sparkles_animation_seg4_dl_04035300), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/actors/spindrift/geo.inc.c b/actors/spindrift/geo.inc.c index 3cd1f515..f784bdaa 100644 --- a/actors/spindrift/geo.inc.c +++ b/actors/spindrift/geo.inc.c @@ -1,36 +1,36 @@ // 0x0C000000 const GeoLayout spindrift_geo[] = { - GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0x96, 100), - GEO_OPEN_NODE(), - GEO_SCALE(0x00, 32768), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_ALPHA, 0, 0, 0, spindrift_seg5_dl_05002900), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 100, 0, 0, spindrift_seg5_dl_05000328), - GEO_ANIMATED_PART(LAYER_ALPHA, 100, 0, 0, spindrift_seg5_dl_05002A20), - GEO_ANIMATED_PART(LAYER_ALPHA, 100, 0, 0, spindrift_seg5_dl_05002B30), - GEO_ANIMATED_PART(LAYER_OPAQUE, -88, -32, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, spindrift_seg5_dl_050002A0), - GEO_ANIMATED_PART(LAYER_ALPHA, 0, 0, 0, spindrift_seg5_dl_05002D08), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), + GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0x96, 100), + GEO_OPEN_NODE(), + GEO_SCALE(0x00, 32768), + GEO_OPEN_NODE(), GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), GEO_OPEN_NODE(), - GEO_BILLBOARD(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, spindrift_seg5_dl_05002748), - GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_ALPHA, 0, 0, 0, spindrift_seg5_dl_05002900), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 100, 0, 0, spindrift_seg5_dl_05000328), + GEO_ANIMATED_PART(LAYER_ALPHA, 100, 0, 0, spindrift_seg5_dl_05002A20), + GEO_ANIMATED_PART(LAYER_ALPHA, 100, 0, 0, spindrift_seg5_dl_05002B30), + GEO_ANIMATED_PART(LAYER_OPAQUE, -88, -32, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, spindrift_seg5_dl_050002A0), + GEO_ANIMATED_PART(LAYER_ALPHA, 0, 0, 0, spindrift_seg5_dl_05002D08), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_BILLBOARD(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, spindrift_seg5_dl_05002748), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_ALPHA, 0, 0, 0, spindrift_seg5_dl_05002830), GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_ALPHA, 0, 0, 0, spindrift_seg5_dl_05002830), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/actors/spiny/geo.inc.c b/actors/spiny/geo.inc.c index fa813f84..fd3b8441 100644 --- a/actors/spiny/geo.inc.c +++ b/actors/spiny/geo.inc.c @@ -1,57 +1,57 @@ // 0x0C000328 const GeoLayout spiny_geo[] = { - GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0x96, 100), - GEO_OPEN_NODE(), - GEO_SCALE(0x00, 16384), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 72, -7, spiny_seg5_dl_05016A48), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0x96, 100), + GEO_OPEN_NODE(), + GEO_SCALE(0x00, 16384), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 72, -7, spiny_seg5_dl_05016A48), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, spiny_seg5_dl_05016738), - GEO_ANIMATED_PART(LAYER_OPAQUE, -1, 55, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 77, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, spiny_seg5_dl_05016418), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, -48, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 88, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, spiny_seg5_dl_050164E0), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, -1, 55, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 77, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, spiny_seg5_dl_050165A8), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, -48, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 88, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, spiny_seg5_dl_05016670), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, spiny_seg5_dl_05016738), + GEO_ANIMATED_PART(LAYER_OPAQUE, -1, 55, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 77, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, spiny_seg5_dl_05016418), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, -48, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 88, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, spiny_seg5_dl_050164E0), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, -1, 55, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 77, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, spiny_seg5_dl_050165A8), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, -48, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 88, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, spiny_seg5_dl_05016670), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/actors/spiny_egg/geo.inc.c b/actors/spiny_egg/geo.inc.c index e2a3d4f6..721b487e 100644 --- a/actors/spiny_egg/geo.inc.c +++ b/actors/spiny_egg/geo.inc.c @@ -1,21 +1,21 @@ // 0x0C000290 const GeoLayout spiny_ball_geo[] = { - GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0x96, 100), - GEO_OPEN_NODE(), - GEO_SCALE(0x00, 16384), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, -18, -34, 10, spiny_egg_seg5_dl_05015368), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, spiny_egg_seg5_dl_05015330), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, spiny_egg_seg5_dl_050152F8), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, spiny_egg_seg5_dl_050152C0), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, spiny_egg_seg5_dl_05015288), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, spiny_egg_seg5_dl_05015250), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, spiny_egg_seg5_dl_05015218), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, spiny_egg_seg5_dl_050151E0), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, spiny_egg_seg5_dl_050151A8), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0x96, 100), + GEO_OPEN_NODE(), + GEO_SCALE(0x00, 16384), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, -18, -34, 10, spiny_egg_seg5_dl_05015368), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, spiny_egg_seg5_dl_05015330), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, spiny_egg_seg5_dl_050152F8), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, spiny_egg_seg5_dl_050152C0), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, spiny_egg_seg5_dl_05015288), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, spiny_egg_seg5_dl_05015250), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, spiny_egg_seg5_dl_05015218), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, spiny_egg_seg5_dl_050151E0), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, spiny_egg_seg5_dl_050151A8), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/actors/springboard/geo.inc.c b/actors/springboard/geo.inc.c index ed5a896b..aa8ce677 100644 --- a/actors/springboard/geo.inc.c +++ b/actors/springboard/geo.inc.c @@ -1,29 +1,29 @@ // top of beta trampoline - unused // 0x0C000000 const GeoLayout springboard_top_geo[] = { - GEO_CULLING_RADIUS(500), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, springboard_checkerboard_seg5_dl_050016B8), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(500), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, springboard_checkerboard_seg5_dl_050016B8), + GEO_CLOSE_NODE(), + GEO_END(), }; // middle of beta trampoline - unused // 0x0C000018 const GeoLayout springboard_spring_geo[] = { - GEO_CULLING_RADIUS(500), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, springboard_spring_seg5_dl_05001800), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(500), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, springboard_spring_seg5_dl_05001800), + GEO_CLOSE_NODE(), + GEO_END(), }; // bottom of beta trampoline - unused // 0x0C000030 const GeoLayout springboard_bottom_geo[] = { - GEO_CULLING_RADIUS(500), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, springboard_checkerboard_seg5_dl_05001900), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(500), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, springboard_checkerboard_seg5_dl_05001900), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/actors/star/geo.inc.c b/actors/star/geo.inc.c index 200f64e7..1f2f1afa 100644 --- a/actors/star/geo.inc.c +++ b/actors/star/geo.inc.c @@ -1,12 +1,12 @@ // 0x16000EA0 const GeoLayout star_geo[] = { - GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0x9B, 100), - GEO_OPEN_NODE(), - GEO_SCALE(0x00, 16384), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, star_seg3_dl_0302B870), - GEO_DISPLAY_LIST(LAYER_ALPHA, star_seg3_dl_0302BA18), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0x9B, 100), + GEO_OPEN_NODE(), + GEO_SCALE(0x00, 16384), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, star_seg3_dl_0302B870), + GEO_DISPLAY_LIST(LAYER_ALPHA, star_seg3_dl_0302BA18), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/actors/stomp_smoke/geo.inc.c b/actors/stomp_smoke/geo.inc.c index 1fc0a468..8819b694 100644 --- a/actors/stomp_smoke/geo.inc.c +++ b/actors/stomp_smoke/geo.inc.c @@ -1,28 +1,28 @@ // 0x1700009C const GeoLayout small_water_splash_geo[] = { - GEO_SWITCH_CASE(6, geo_switch_anim_state), - GEO_OPEN_NODE(), - // TODO: Rename these display lists - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, stomp_smoke_seg4_dl_040251F8), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, stomp_smoke_seg4_dl_04025210), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, stomp_smoke_seg4_dl_04025228), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, stomp_smoke_seg4_dl_04025240), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, stomp_smoke_seg4_dl_04025258), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, stomp_smoke_seg4_dl_04025270), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_SWITCH_CASE(6, geo_switch_anim_state), + GEO_OPEN_NODE(), + // TODO: Rename these display lists + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, stomp_smoke_seg4_dl_040251F8), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, stomp_smoke_seg4_dl_04025210), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, stomp_smoke_seg4_dl_04025228), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, stomp_smoke_seg4_dl_04025240), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, stomp_smoke_seg4_dl_04025258), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, stomp_smoke_seg4_dl_04025270), + GEO_CLOSE_NODE(), + GEO_END(), }; // 0x170000E0 const GeoLayout mario_TODO_geo_0000E0[] = { - GEO_SWITCH_CASE(6, geo_switch_anim_state), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, stomp_smoke_seg4_dl_04025288), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, stomp_smoke_seg4_dl_040252A0), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, stomp_smoke_seg4_dl_040252B8), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, stomp_smoke_seg4_dl_040252D0), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, stomp_smoke_seg4_dl_040252E8), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, stomp_smoke_seg4_dl_04025300), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_SWITCH_CASE(6, geo_switch_anim_state), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, stomp_smoke_seg4_dl_04025288), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, stomp_smoke_seg4_dl_040252A0), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, stomp_smoke_seg4_dl_040252B8), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, stomp_smoke_seg4_dl_040252D0), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, stomp_smoke_seg4_dl_040252E8), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, stomp_smoke_seg4_dl_04025300), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/actors/sushi/geo.inc.c b/actors/sushi/geo.inc.c index 4e401699..f507a3d8 100644 --- a/actors/sushi/geo.inc.c +++ b/actors/sushi/geo.inc.c @@ -1,28 +1,28 @@ // 0x0C000068 const GeoLayout sushi_geo[] = { - GEO_CULLING_RADIUS(800), - GEO_OPEN_NODE(), - GEO_SCALE(0x00, 16384), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, sushi_seg5_dl_0500A768), + GEO_CULLING_RADIUS(800), + GEO_OPEN_NODE(), + GEO_SCALE(0x00, 16384), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), GEO_OPEN_NODE(), - GEO_ASM(0, geo_update_body_rot_from_parent), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, sushi_seg5_dl_0500A768), + GEO_OPEN_NODE(), + GEO_ASM(0, geo_update_body_rot_from_parent), + GEO_CLOSE_NODE(), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 201, 0, 0, sushi_seg5_dl_05009DD0), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 415, 0, 0, sushi_seg5_dl_0500A008), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 486, 0, 0, sushi_seg5_dl_0500A160), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_ALPHA, 0, 0, 0, sushi_seg5_dl_0500A990), + GEO_ANIMATED_PART(LAYER_ALPHA, 0, 0, 0, sushi_seg5_dl_0500A8A8), GEO_CLOSE_NODE(), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 201, 0, 0, sushi_seg5_dl_05009DD0), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 415, 0, 0, sushi_seg5_dl_0500A008), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 486, 0, 0, sushi_seg5_dl_0500A160), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_ALPHA, 0, 0, 0, sushi_seg5_dl_0500A990), - GEO_ANIMATED_PART(LAYER_ALPHA, 0, 0, 0, sushi_seg5_dl_0500A8A8), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/actors/swoop/geo.inc.c b/actors/swoop/geo.inc.c index 5cde29ba..c3d40387 100644 --- a/actors/swoop/geo.inc.c +++ b/actors/swoop/geo.inc.c @@ -1,32 +1,32 @@ // 0x0D0000DC const GeoLayout swoop_geo[] = { - GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0x96, 100), - GEO_OPEN_NODE(), - GEO_SCALE(0x00, 16384), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), + GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0x96, 100), + GEO_OPEN_NODE(), + GEO_SCALE(0x00, 16384), + GEO_OPEN_NODE(), GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), GEO_OPEN_NODE(), - GEO_BILLBOARD(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, swoop_seg6_dl_06006880), - GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_BILLBOARD(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, swoop_seg6_dl_06006880), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 54, 0, 0, swoop_seg6_dl_06006758), + GEO_ANIMATED_PART(LAYER_OPAQUE, 54, 0, 0, swoop_seg6_dl_06006A88), + GEO_ANIMATED_PART(LAYER_OPAQUE, 57, -48, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_ALPHA, 0, 0, 0, swoop_seg6_dl_06006BD0), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 57, -48, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_ALPHA, 0, 0, 0, swoop_seg6_dl_06006D00), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 54, 0, 0, swoop_seg6_dl_06006758), - GEO_ANIMATED_PART(LAYER_OPAQUE, 54, 0, 0, swoop_seg6_dl_06006A88), - GEO_ANIMATED_PART(LAYER_OPAQUE, 57, -48, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_ALPHA, 0, 0, 0, swoop_seg6_dl_06006BD0), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 57, -48, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_ALPHA, 0, 0, 0, swoop_seg6_dl_06006D00), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/actors/thwomp/geo.inc.c b/actors/thwomp/geo.inc.c index d096c5ae..a45a1f4f 100644 --- a/actors/thwomp/geo.inc.c +++ b/actors/thwomp/geo.inc.c @@ -1,8 +1,8 @@ // 0x0C000248 const GeoLayout thwomp_geo[] = { - GEO_SHADOW(SHADOW_SQUARE_SCALABLE, 0xB4, 300), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, thwomp_seg5_dl_0500B750), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_SHADOW(SHADOW_SQUARE_SCALABLE, 0xB4, 300), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, thwomp_seg5_dl_0500B750), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/actors/toad/geo.inc.c b/actors/toad/geo.inc.c index fd8af275..bc27ea4d 100644 --- a/actors/toad/geo.inc.c +++ b/actors/toad/geo.inc.c @@ -1,141 +1,141 @@ // 0x0D000114 const GeoLayout toad_geo_000114[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 83, 0, 0, NULL), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 126, -37, 0, toad_seg6_dl_06007710), + GEO_ANIMATED_PART(LAYER_OPAQUE, 83, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 126, -37, 0, toad_seg6_dl_06007710), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 25, 8, 0, toad_seg6_dl_06007A48), + GEO_ANIMATED_PART(LAYER_OPAQUE, 34, 8, 0, toad_seg6_dl_06007EB0), + GEO_ANIMATED_PART(LAYER_OPAQUE, 4, 7, 38, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 37, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 9, -25, 3, toad_seg6_dl_06008890), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 4, 7, -38, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 37, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 9, -25, -3, toad_seg6_dl_06008BD8), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 61, -3, 52, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 17, 0, 4, toad_seg6_dl_060081F8), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 61, -3, -52, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 17, 0, -4, toad_seg6_dl_06008520), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 25, 8, 0, toad_seg6_dl_06007A48), - GEO_ANIMATED_PART(LAYER_OPAQUE, 34, 8, 0, toad_seg6_dl_06007EB0), - GEO_ANIMATED_PART(LAYER_OPAQUE, 4, 7, 38, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 37, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 9, -25, 3, toad_seg6_dl_06008890), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 4, 7, -38, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 37, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 9, -25, -3, toad_seg6_dl_06008BD8), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 61, -3, 52, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 17, 0, 4, toad_seg6_dl_060081F8), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 61, -3, -52, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 17, 0, -4, toad_seg6_dl_06008520), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x0D00027C const GeoLayout toad_geo_00027C[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 83, 0, 0, NULL), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, NULL), GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 83, 0, 0, NULL), + GEO_OPEN_NODE(), #ifdef VERSION_JP - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 126, -37, 0, toad_seg6_dl_06007710), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 126, -37, 0, toad_seg6_dl_06007710), #else - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 126, -37, 0, toad_seg6_us_dl_06007788), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 126, -37, 0, toad_seg6_us_dl_06007788), #endif - GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), #ifdef VERSION_JP - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 25, 8, 0, toad_seg6_dl_06007A48), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 25, 8, 0, toad_seg6_dl_06007A48), #else - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 25, 8, 0, toad_seg6_us_dl_06007B00), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 25, 8, 0, toad_seg6_us_dl_06007B00), #endif - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 34, 8, 0, toad_seg6_dl_06007EB0), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 4, 7, 38, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 37, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 9, -25, 3, toad_seg6_dl_06008890), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 4, 7, -38, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 37, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 9, -25, -3, toad_seg6_dl_06008BD8), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 61, -3, 52, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 17, 0, 4, toad_seg6_dl_060081F8), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 61, -3, -52, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, NULL), - GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 34, 8, 0, toad_seg6_dl_06007EB0), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 4, 7, 38, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 37, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 9, -25, 3, toad_seg6_dl_06008890), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 4, 7, -38, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 37, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 9, -25, -3, toad_seg6_dl_06008BD8), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 61, -3, 52, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 17, 0, 4, toad_seg6_dl_060081F8), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 61, -3, -52, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, NULL), + GEO_OPEN_NODE(), #ifdef VERSION_JP - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 17, 0, -4, toad_seg6_dl_06008520), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 17, 0, -4, toad_seg6_dl_06008520), #else - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 17, 0, -4, toad_seg6_us_dl_06008608), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 17, 0, -4, toad_seg6_us_dl_06008608), #endif - GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x0D0003E4 const GeoLayout toad_geo[] = { - GEO_CULLING_RADIUS(1000), - GEO_OPEN_NODE(), - GEO_SHADOW(SHADOW_CIRCLE_9_VERTS, 0x96, 100), - GEO_OPEN_NODE(), - GEO_SCALE(0x00, 16384), - GEO_OPEN_NODE(), - GEO_ASM(10, geo_update_layer_transparency), - GEO_SWITCH_CASE(2, geo_switch_anim_state), + GEO_CULLING_RADIUS(1000), + GEO_OPEN_NODE(), + GEO_SHADOW(SHADOW_CIRCLE_9_VERTS, 0x96, 100), + GEO_OPEN_NODE(), + GEO_SCALE(0x00, 16384), GEO_OPEN_NODE(), - GEO_BRANCH(1, toad_geo_000114), - GEO_BRANCH(1, toad_geo_00027C), + GEO_ASM(10, geo_update_layer_transparency), + GEO_SWITCH_CASE(2, geo_switch_anim_state), + GEO_OPEN_NODE(), + GEO_BRANCH(1, toad_geo_000114), + GEO_BRANCH(1, toad_geo_00027C), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; UNUSED static const u64 toad_unused_1 = 0; diff --git a/actors/tornado/geo.inc.c b/actors/tornado/geo.inc.c index 26f971cb..533d24b0 100644 --- a/actors/tornado/geo.inc.c +++ b/actors/tornado/geo.inc.c @@ -2,7 +2,7 @@ const GeoLayout tweester_geo[] = { GEO_CULLING_RADIUS(5000), GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, tornado_seg5_dl_050145C0), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, tornado_seg5_dl_050145C0), GEO_CLOSE_NODE(), GEO_END(), }; diff --git a/actors/transparent_star/geo.inc.c b/actors/transparent_star/geo.inc.c index fca28b58..87e06bce 100644 --- a/actors/transparent_star/geo.inc.c +++ b/actors/transparent_star/geo.inc.c @@ -1,11 +1,11 @@ // 0x16000F6C const GeoLayout transparent_star_geo[] = { - GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0x9B, 100), - GEO_OPEN_NODE(), - GEO_SCALE(0x00, 16384), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, transparent_star_seg3_dl_0302C620), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0x9B, 100), + GEO_OPEN_NODE(), + GEO_SCALE(0x00, 16384), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, transparent_star_seg3_dl_0302C620), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/actors/treasure_chest/geo.inc.c b/actors/treasure_chest/geo.inc.c index 4ace3590..29a993ed 100644 --- a/actors/treasure_chest/geo.inc.c +++ b/actors/treasure_chest/geo.inc.c @@ -1,17 +1,17 @@ // 0x0D000450 const GeoLayout treasure_chest_base_geo[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, treasure_chest_seg6_dl_06016F90), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, treasure_chest_seg6_dl_06016F90), + GEO_CLOSE_NODE(), + GEO_END(), }; // 0x0D000468 const GeoLayout treasure_chest_lid_geo[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, treasure_chest_seg6_dl_060178C0), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, treasure_chest_seg6_dl_060178C0), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/actors/tree/geo.inc.c b/actors/tree/geo.inc.c index c58ded64..7377f0ae 100644 --- a/actors/tree/geo.inc.c +++ b/actors/tree/geo.inc.c @@ -1,44 +1,44 @@ // 0x16000FE8 const GeoLayout bubbly_tree_geo[] = { - GEO_CULLING_RADIUS(800), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, tree_seg3_dl_0302FEE8), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(800), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, tree_seg3_dl_0302FEE8), + GEO_CLOSE_NODE(), + GEO_END(), }; // 0x16001000 const GeoLayout spiky_tree_geo[] = { - GEO_CULLING_RADIUS(800), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, tree_seg3_dl_03030FA0), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(800), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, tree_seg3_dl_03030FA0), + GEO_CLOSE_NODE(), + GEO_END(), }; // 0x16001018 const GeoLayout snow_tree_geo[] = { - GEO_CULLING_RADIUS(800), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, tree_seg3_dl_03032088), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(800), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, tree_seg3_dl_03032088), + GEO_CLOSE_NODE(), + GEO_END(), }; // 0x16001030 const GeoLayout spiky_tree1_geo[] = { - GEO_CULLING_RADIUS(800), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, tree_seg3_dl_03032170), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(800), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, tree_seg3_dl_03032170), + GEO_CLOSE_NODE(), + GEO_END(), }; // 0x16001048 const GeoLayout palm_tree_geo[] = { - GEO_CULLING_RADIUS(800), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, tree_seg3_dl_03033258), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(800), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, tree_seg3_dl_03033258), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/actors/ukiki/geo.inc.c b/actors/ukiki/geo.inc.c index 72d864c9..6f2a6c7a 100644 --- a/actors/ukiki/geo.inc.c +++ b/actors/ukiki/geo.inc.c @@ -1,91 +1,91 @@ // 0x0C000110 const GeoLayout ukiki_geo[] = { - GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0x96, 80), - GEO_OPEN_NODE(), - GEO_SCALE(0x00, 16384), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, ukiki_seg5_dl_0500B820), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 99, -11, NULL), + GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0x96, 80), + GEO_OPEN_NODE(), + GEO_SCALE(0x00, 16384), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, ukiki_seg5_dl_0500B820), GEO_OPEN_NODE(), - GEO_SWITCH_CASE(4, geo_switch_anim_state), - GEO_OPEN_NODE(), - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, ukiki_seg5_dl_0500B2E8), - GEO_CLOSE_NODE(), - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, ukiki_seg5_dl_0500B310), - GEO_CLOSE_NODE(), - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, ukiki_seg5_dl_0500B2E8), - GEO_OPEN_NODE(), - GEO_TRANSLATE_ROTATE_WITH_DL(LAYER_OPAQUE, 100, 0, 0, -90, -90, 0, mario_cap_seg3_dl_03022F48), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, ukiki_seg5_dl_0500B310), - GEO_OPEN_NODE(), - GEO_TRANSLATE_ROTATE_WITH_DL(LAYER_OPAQUE, 100, 0, 0, -90, -90, 0, mario_cap_seg3_dl_03022F48), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 99, -11, NULL), + GEO_OPEN_NODE(), + GEO_SWITCH_CASE(4, geo_switch_anim_state), + GEO_OPEN_NODE(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, ukiki_seg5_dl_0500B2E8), + GEO_CLOSE_NODE(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, ukiki_seg5_dl_0500B310), + GEO_CLOSE_NODE(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, ukiki_seg5_dl_0500B2E8), + GEO_OPEN_NODE(), + GEO_TRANSLATE_ROTATE_WITH_DL(LAYER_OPAQUE, 100, 0, 0, -90, -90, 0, mario_cap_seg3_dl_03022F48), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, ukiki_seg5_dl_0500B310), + GEO_OPEN_NODE(), + GEO_TRANSLATE_ROTATE_WITH_DL(LAYER_OPAQUE, 100, 0, 0, -90, -90, 0, mario_cap_seg3_dl_03022F48), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 71, 69, -9, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, ukiki_seg5_dl_0500B988), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 86, 0, 0, ukiki_seg5_dl_0500BB28), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 64, 0, 0, ukiki_seg5_dl_0500CF68), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, -71, 68, -9, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, ukiki_seg5_dl_0500BC78), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 86, 0, 0, ukiki_seg5_dl_0500BE38), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 64, 0, 0, ukiki_seg5_dl_0500CFF0), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 43, -22, -1, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, ukiki_seg5_dl_0500BFF8), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 46, 0, 0, ukiki_seg5_dl_0500C1B8), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 36, 0, 0, ukiki_seg5_dl_0500D078), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, -43, -22, -1, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, ukiki_seg5_dl_0500C368), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 46, 0, 0, ukiki_seg5_dl_0500C528), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 36, 0, 0, ukiki_seg5_dl_0500D108), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, -15, -57, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, ukiki_seg5_dl_0500C6E8), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 45, 0, 0, ukiki_seg5_dl_0500C898), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 46, 0, 0, ukiki_seg5_dl_0500CA48), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 71, 69, -9, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, ukiki_seg5_dl_0500B988), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 86, 0, 0, ukiki_seg5_dl_0500BB28), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 64, 0, 0, ukiki_seg5_dl_0500CF68), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, -71, 68, -9, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, ukiki_seg5_dl_0500BC78), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 86, 0, 0, ukiki_seg5_dl_0500BE38), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 64, 0, 0, ukiki_seg5_dl_0500CFF0), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 43, -22, -1, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, ukiki_seg5_dl_0500BFF8), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 46, 0, 0, ukiki_seg5_dl_0500C1B8), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 36, 0, 0, ukiki_seg5_dl_0500D078), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, -43, -22, -1, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, ukiki_seg5_dl_0500C368), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 46, 0, 0, ukiki_seg5_dl_0500C528), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 36, 0, 0, ukiki_seg5_dl_0500D108), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, -15, -57, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, ukiki_seg5_dl_0500C6E8), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 45, 0, 0, ukiki_seg5_dl_0500C898), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 46, 0, 0, ukiki_seg5_dl_0500CA48), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/actors/unagi/geo.inc.c b/actors/unagi/geo.inc.c index a6f7674c..bac11b65 100644 --- a/actors/unagi/geo.inc.c +++ b/actors/unagi/geo.inc.c @@ -1,55 +1,55 @@ // 0x0C00010C const GeoLayout unagi_geo[] = { - GEO_CULLING_RADIUS(2000), - GEO_OPEN_NODE(), - GEO_SCALE(0x00, 16384), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, unagi_seg5_dl_0500D268), + GEO_CULLING_RADIUS(2000), + GEO_OPEN_NODE(), + GEO_SCALE(0x00, 16384), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 245, 0, 0, unagi_seg5_dl_0500D468), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 494, 0, 0, unagi_seg5_dl_0500D668), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 475, 0, 0, unagi_seg5_dl_0500D828), - GEO_OPEN_NODE(), - GEO_SWITCH_CASE(2, geo_switch_anim_state), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, unagi_seg5_dl_0500D268), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 245, 0, 0, unagi_seg5_dl_0500D468), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 494, 0, 0, unagi_seg5_dl_0500D668), GEO_OPEN_NODE(), - GEO_NODE_START(), - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_SCALE(0x00, 16384), - GEO_OPEN_NODE(), - GEO_TRANSLATE_ROTATE_WITH_DL(LAYER_OPAQUE, 2000, 0, 0, 0, 0, 0, star_seg3_dl_0302B870), - GEO_TRANSLATE_ROTATE_WITH_DL(LAYER_ALPHA, 2000, 0, 0, 0, 0, 0, star_seg3_dl_0302BA18), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 475, 0, 0, unagi_seg5_dl_0500D828), + GEO_OPEN_NODE(), + GEO_SWITCH_CASE(2, geo_switch_anim_state), + GEO_OPEN_NODE(), + GEO_NODE_START(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_SCALE(0x00, 16384), + GEO_OPEN_NODE(), + GEO_TRANSLATE_ROTATE_WITH_DL(LAYER_OPAQUE, 2000, 0, 0, 0, 0, 0, star_seg3_dl_0302B870), + GEO_TRANSLATE_ROTATE_WITH_DL(LAYER_ALPHA, 2000, 0, 0, 0, 0, 0, star_seg3_dl_0302BA18), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, -254, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, unagi_seg5_dl_0500D050), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_ALPHA, 527, 0, 0, unagi_seg5_dl_0500DEB8), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 226, 65, 0, NULL), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, -254, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, unagi_seg5_dl_0500D050), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_ALPHA, 0, 0, 0, unagi_seg5_dl_0500E258), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, unagi_seg5_dl_0500CDD0), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_ANIMATED_PART(LAYER_ALPHA, 527, 0, 0, unagi_seg5_dl_0500DEB8), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 226, 65, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_ALPHA, 0, 0, 0, unagi_seg5_dl_0500E258), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, unagi_seg5_dl_0500CDD0), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_ALPHA, 527, 0, 0, unagi_seg5_dl_0500E088), + GEO_ANIMATED_PART(LAYER_OPAQUE, 527, 0, 0, unagi_seg5_dl_0500DD08), + GEO_ANIMATED_PART(LAYER_OPAQUE, 527, 0, 0, NULL), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_ALPHA, 527, 0, 0, unagi_seg5_dl_0500E088), - GEO_ANIMATED_PART(LAYER_OPAQUE, 527, 0, 0, unagi_seg5_dl_0500DD08), - GEO_ANIMATED_PART(LAYER_OPAQUE, 527, 0, 0, NULL), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/actors/walk_smoke/geo.inc.c b/actors/walk_smoke/geo.inc.c index 8b521062..c9b51b49 100644 --- a/actors/walk_smoke/geo.inc.c +++ b/actors/walk_smoke/geo.inc.c @@ -1,14 +1,14 @@ // 0x17000038 const GeoLayout smoke_geo[] = { - GEO_SWITCH_CASE(7, geo_switch_anim_state), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, smoke_seg4_dl_04021718), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, smoke_seg4_dl_04021730), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, smoke_seg4_dl_04021748), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, smoke_seg4_dl_04021760), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, smoke_seg4_dl_04021778), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, smoke_seg4_dl_04021790), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, smoke_seg4_dl_040217A8), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_SWITCH_CASE(7, geo_switch_anim_state), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, smoke_seg4_dl_04021718), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, smoke_seg4_dl_04021730), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, smoke_seg4_dl_04021748), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, smoke_seg4_dl_04021760), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, smoke_seg4_dl_04021778), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, smoke_seg4_dl_04021790), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, smoke_seg4_dl_040217A8), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/actors/warp_pipe/geo.inc.c b/actors/warp_pipe/geo.inc.c index b537b43f..581b2d50 100644 --- a/actors/warp_pipe/geo.inc.c +++ b/actors/warp_pipe/geo.inc.c @@ -1,9 +1,9 @@ // 0x16000388 const GeoLayout warp_pipe_geo[] = { - GEO_CULLING_RADIUS(350), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, warp_pipe_seg3_dl_03008F98), - GEO_DISPLAY_LIST(LAYER_OPAQUE, warp_pipe_seg3_dl_03009A50), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(350), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, warp_pipe_seg3_dl_03008F98), + GEO_DISPLAY_LIST(LAYER_OPAQUE, warp_pipe_seg3_dl_03009A50), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/actors/water_bubble/geo.inc.c b/actors/water_bubble/geo.inc.c index b429edcd..318a794b 100644 --- a/actors/water_bubble/geo.inc.c +++ b/actors/water_bubble/geo.inc.c @@ -1,19 +1,19 @@ // 0x0C000308 const GeoLayout water_bomb_geo[] = { - GEO_CULLING_RADIUS(150), - GEO_OPEN_NODE(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, water_bubble_seg5_dl_05011000), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(150), + GEO_OPEN_NODE(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, water_bubble_seg5_dl_05011000), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; // 0x0C000328 const GeoLayout water_bomb_shadow_geo[] = { - GEO_CULLING_RADIUS(150), - GEO_OPEN_NODE(), - GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0x64, 160), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(150), + GEO_OPEN_NODE(), + GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0x64, 160), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/actors/water_mine/geo.inc.c b/actors/water_mine/geo.inc.c index 92497e1e..36c64a91 100644 --- a/actors/water_mine/geo.inc.c +++ b/actors/water_mine/geo.inc.c @@ -1,12 +1,12 @@ // 0x0D0002F4 const GeoLayout water_mine_geo[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, water_mine_seg6_dl_0600D3F8), - GEO_BILLBOARD(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, water_mine_seg6_dl_0600D268), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, water_mine_seg6_dl_0600D3F8), + GEO_BILLBOARD(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, water_mine_seg6_dl_0600D268), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/actors/water_ring/geo.inc.c b/actors/water_ring/geo.inc.c index 3d2b546a..e20742f1 100644 --- a/actors/water_ring/geo.inc.c +++ b/actors/water_ring/geo.inc.c @@ -1,12 +1,12 @@ // 0x0D000414 const GeoLayout water_ring_geo[] = { - GEO_SCALE(0x00, 32768), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ASM(0, geo_update_layer_transparency), - GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, water_ring_seg6_dl_06013AC0), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_SCALE(0x00, 32768), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ASM(0, geo_update_layer_transparency), + GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, water_ring_seg6_dl_06013AC0), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/actors/water_splash/geo.inc.c b/actors/water_splash/geo.inc.c index 7075b114..5d7a222a 100644 --- a/actors/water_splash/geo.inc.c +++ b/actors/water_splash/geo.inc.c @@ -1,15 +1,15 @@ // 0x17000230 const GeoLayout water_splash_geo[] = { - GEO_SWITCH_CASE(8, geo_switch_anim_state), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, water_splash_seg4_dl_04032640), - GEO_DISPLAY_LIST(LAYER_ALPHA, water_splash_seg4_dl_04032658), - GEO_DISPLAY_LIST(LAYER_ALPHA, water_splash_seg4_dl_04032670), - GEO_DISPLAY_LIST(LAYER_ALPHA, water_splash_seg4_dl_04032688), - GEO_DISPLAY_LIST(LAYER_ALPHA, water_splash_seg4_dl_040326A0), - GEO_DISPLAY_LIST(LAYER_ALPHA, water_splash_seg4_dl_040326B8), - GEO_DISPLAY_LIST(LAYER_ALPHA, water_splash_seg4_dl_040326D0), - GEO_DISPLAY_LIST(LAYER_ALPHA, water_splash_seg4_dl_040326E8), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_SWITCH_CASE(8, geo_switch_anim_state), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, water_splash_seg4_dl_04032640), + GEO_DISPLAY_LIST(LAYER_ALPHA, water_splash_seg4_dl_04032658), + GEO_DISPLAY_LIST(LAYER_ALPHA, water_splash_seg4_dl_04032670), + GEO_DISPLAY_LIST(LAYER_ALPHA, water_splash_seg4_dl_04032688), + GEO_DISPLAY_LIST(LAYER_ALPHA, water_splash_seg4_dl_040326A0), + GEO_DISPLAY_LIST(LAYER_ALPHA, water_splash_seg4_dl_040326B8), + GEO_DISPLAY_LIST(LAYER_ALPHA, water_splash_seg4_dl_040326D0), + GEO_DISPLAY_LIST(LAYER_ALPHA, water_splash_seg4_dl_040326E8), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/actors/water_wave/geo.inc.c b/actors/water_wave/geo.inc.c index 6abbc0da..75923ab3 100644 --- a/actors/water_wave/geo.inc.c +++ b/actors/water_wave/geo.inc.c @@ -1,29 +1,29 @@ // 0x17000124 const GeoLayout idle_water_wave_geo[] = { - GEO_SWITCH_CASE(6, geo_switch_anim_state), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, water_wave_seg4_dl_040273F0), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, water_wave_seg4_dl_04027408), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, water_wave_seg4_dl_04027420), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, water_wave_seg4_dl_04027438), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, water_wave_seg4_dl_04027420), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, water_wave_seg4_dl_04027408), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_SWITCH_CASE(6, geo_switch_anim_state), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, water_wave_seg4_dl_040273F0), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, water_wave_seg4_dl_04027408), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, water_wave_seg4_dl_04027420), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, water_wave_seg4_dl_04027438), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, water_wave_seg4_dl_04027420), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, water_wave_seg4_dl_04027408), + GEO_CLOSE_NODE(), + GEO_END(), }; // 0x17000168 const GeoLayout wave_trail_geo[] = { - GEO_SWITCH_CASE(8, geo_switch_anim_state), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, water_wave_seg4_dl_040273F0), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, water_wave_seg4_dl_04027408), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, water_wave_seg4_dl_04027420), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, water_wave_seg4_dl_04027438), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, water_wave_seg4_dl_04027438), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, water_wave_seg4_dl_04027438), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, water_wave_seg4_dl_04027438), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, water_wave_seg4_dl_04027438), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_SWITCH_CASE(8, geo_switch_anim_state), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, water_wave_seg4_dl_040273F0), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, water_wave_seg4_dl_04027408), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, water_wave_seg4_dl_04027420), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, water_wave_seg4_dl_04027438), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, water_wave_seg4_dl_04027438), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, water_wave_seg4_dl_04027438), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, water_wave_seg4_dl_04027438), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, water_wave_seg4_dl_04027438), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/actors/white_particle/geo.inc.c b/actors/white_particle/geo.inc.c index 5a161ed5..793393ba 100644 --- a/actors/white_particle/geo.inc.c +++ b/actors/white_particle/geo.inc.c @@ -1,8 +1,8 @@ // 0x16000F98 const GeoLayout white_particle_geo[] = { - GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0xB4, 50), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, white_particle_dl), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0xB4, 50), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, white_particle_dl), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/actors/whomp/geo.inc.c b/actors/whomp/geo.inc.c index c2edb69e..e848f710 100644 --- a/actors/whomp/geo.inc.c +++ b/actors/whomp/geo.inc.c @@ -1,56 +1,56 @@ // 0x0D000480 const GeoLayout whomp_geo[] = { - GEO_CULLING_RADIUS(2000), - GEO_OPEN_NODE(), - GEO_TRANSLATE_NODE(0x00, 0, 0, -50), - GEO_OPEN_NODE(), - GEO_SHADOW(0x01 + SHADOW_RECTANGLE_HARDCODED_OFFSET, 0xB4, 0), - GEO_OPEN_NODE(), - GEO_SCALE(0x00, 16384), + GEO_CULLING_RADIUS(2000), + GEO_OPEN_NODE(), + GEO_TRANSLATE_NODE(0x00, 0, 0, -50), + GEO_OPEN_NODE(), + GEO_SHADOW(0x01 + SHADOW_RECTANGLE_HARDCODED_OFFSET, 0xB4, 0), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, whomp_seg6_dl_0601F5E0), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, -12, 490, -5, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, whomp_seg6_dl_0601FEA8), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, -18, -479, -5, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, whomp_seg6_dl_06020038), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 1075, 570, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, whomp_seg6_dl_0601F880), + GEO_SCALE(0x00, 16384), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, whomp_seg6_dl_0601F5E0), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_ALPHA, 400, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_BILLBOARD(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, whomp_seg6_dl_0601FBC0), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, -12, 490, -5, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, whomp_seg6_dl_0601FEA8), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, -18, -479, -5, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, whomp_seg6_dl_06020038), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 1075, 570, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, whomp_seg6_dl_0601F880), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_ALPHA, 400, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_BILLBOARD(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, whomp_seg6_dl_0601FBC0), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 1068, -574, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, whomp_seg6_dl_0601FAE8), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_ALPHA, 400, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_BILLBOARD(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, whomp_seg6_dl_0601FCA8), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 1068, -574, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, whomp_seg6_dl_0601FAE8), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_ALPHA, 400, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_BILLBOARD(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, whomp_seg6_dl_0601FCA8), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/actors/wiggler_body/geo.inc.c b/actors/wiggler_body/geo.inc.c index a55a1f93..56e55e5c 100644 --- a/actors/wiggler_body/geo.inc.c +++ b/actors/wiggler_body/geo.inc.c @@ -2,41 +2,41 @@ const GeoLayout wiggler_body_geo[] = { GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0x96, 0x64), GEO_OPEN_NODE(), - GEO_SCALE(0, 16384), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(1, 0, 0, 0, NULL), + GEO_SCALE(0, 16384), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(1, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_BILLBOARD(), + GEO_ANIMATED_PART(1, 0, 0, 0, NULL), GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, wiggler_seg5_dl_0500C278), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(1, -31, 0, 51, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(1, 0, 0, 0, wiggler_seg5_dl_0500BE98), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(1, 39, 0, 0, wiggler_seg5_dl_0500BE10), + GEO_ANIMATED_PART(1, 0, 0, 0, NULL), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(1, 41, 0, 0, wiggler_seg5_dl_0500BCB8), + GEO_BILLBOARD(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, wiggler_seg5_dl_0500C278), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(1, -31, 0, -49, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(1, 0, 0, 0, wiggler_seg5_dl_0500C100), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(1, 39, 0, 0, wiggler_seg5_dl_0500C078), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(1, 41, 0, 0, wiggler_seg5_dl_0500BF20), + GEO_ANIMATED_PART(1, -31, 0, 51, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(1, 0, 0, 0, wiggler_seg5_dl_0500BE98), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(1, 39, 0, 0, wiggler_seg5_dl_0500BE10), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(1, 41, 0, 0, wiggler_seg5_dl_0500BCB8), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(1, -31, 0, -49, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(1, 0, 0, 0, wiggler_seg5_dl_0500C100), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(1, 39, 0, 0, wiggler_seg5_dl_0500C078), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(1, 41, 0, 0, wiggler_seg5_dl_0500BF20), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), GEO_END(), }; diff --git a/actors/wiggler_head/geo.inc.c b/actors/wiggler_head/geo.inc.c index 320a824e..5346f5ce 100644 --- a/actors/wiggler_head/geo.inc.c +++ b/actors/wiggler_head/geo.inc.c @@ -1,62 +1,62 @@ // 0x0C000030 const GeoLayout wiggler_head_geo[] = { - GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0x96, 100), - GEO_OPEN_NODE(), - GEO_SCALE(0x00, 16384), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), + GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0x96, 100), + GEO_OPEN_NODE(), + GEO_SCALE(0x00, 16384), + GEO_OPEN_NODE(), GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), GEO_OPEN_NODE(), - GEO_BILLBOARD(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, wiggler_seg5_dl_0500C278), - GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_BILLBOARD(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, wiggler_seg5_dl_0500C278), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 157, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_BILLBOARD(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, wiggler_seg5_dl_0500E678), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 143, 0, 0, NULL), + GEO_OPEN_NODE(), + GEO_BILLBOARD(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, wiggler_seg5_dl_0500E1D8), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 143, 0, 0, NULL), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_ALPHA, 157, 0, 0, wiggler_seg5_dl_0500E518), + GEO_ANIMATED_PART(LAYER_ALPHA, 157, 0, 0, wiggler_seg5_dl_0500E430), + GEO_ANIMATED_PART(LAYER_ALPHA, 157, 0, 0, wiggler_seg5_dl_0500E2F8), + GEO_ANIMATED_PART(LAYER_OPAQUE, -16, 23, 51, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, wiggler_seg5_dl_0500DDF8), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 39, 0, 0, wiggler_seg5_dl_0500DD70), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 41, 0, 0, wiggler_seg5_dl_0500DC18), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, -16, 23, -49, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, wiggler_seg5_dl_0500E060), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 39, 0, 0, wiggler_seg5_dl_0500DFD8), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 41, 0, 0, wiggler_seg5_dl_0500DE80), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 157, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_BILLBOARD(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, wiggler_seg5_dl_0500E678), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 143, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_BILLBOARD(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, wiggler_seg5_dl_0500E1D8), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 143, 0, 0, NULL), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_ALPHA, 157, 0, 0, wiggler_seg5_dl_0500E518), - GEO_ANIMATED_PART(LAYER_ALPHA, 157, 0, 0, wiggler_seg5_dl_0500E430), - GEO_ANIMATED_PART(LAYER_ALPHA, 157, 0, 0, wiggler_seg5_dl_0500E2F8), - GEO_ANIMATED_PART(LAYER_OPAQUE, -16, 23, 51, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, wiggler_seg5_dl_0500DDF8), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 39, 0, 0, wiggler_seg5_dl_0500DD70), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 41, 0, 0, wiggler_seg5_dl_0500DC18), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, -16, 23, -49, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, wiggler_seg5_dl_0500E060), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 39, 0, 0, wiggler_seg5_dl_0500DFD8), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 41, 0, 0, wiggler_seg5_dl_0500DE80), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/actors/wooden_signpost/geo.inc.c b/actors/wooden_signpost/geo.inc.c index 5b4e1b31..08d2886a 100644 --- a/actors/wooden_signpost/geo.inc.c +++ b/actors/wooden_signpost/geo.inc.c @@ -1,12 +1,12 @@ // 0x16000FB4 const GeoLayout wooden_signpost_geo[] = { - GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0xC8, 60), - GEO_OPEN_NODE(), - GEO_SCALE(0x00, 16384), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, wooden_signpost_seg3_dl_0302DA48), - GEO_DISPLAY_LIST(LAYER_OPAQUE, wooden_signpost_seg3_dl_0302DD08), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0xC8, 60), + GEO_OPEN_NODE(), + GEO_SCALE(0x00, 16384), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, wooden_signpost_seg3_dl_0302DA48), + GEO_DISPLAY_LIST(LAYER_OPAQUE, wooden_signpost_seg3_dl_0302DD08), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/actors/yellow_sphere/geo.inc.c b/actors/yellow_sphere/geo.inc.c index 67252e30..057f87bd 100644 --- a/actors/yellow_sphere/geo.inc.c +++ b/actors/yellow_sphere/geo.inc.c @@ -1,11 +1,11 @@ // 0x0D0000B0 const GeoLayout bowser_1_yellow_sphere_geo[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_BILLBOARD(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, yellow_sphere_seg6_dl_0601F3C0), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_BILLBOARD(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, yellow_sphere_seg6_dl_0601F3C0), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/actors/yellow_sphere_small/geo.inc.c b/actors/yellow_sphere_small/geo.inc.c index 01142c04..22e71aca 100644 --- a/actors/yellow_sphere_small/geo.inc.c +++ b/actors/yellow_sphere_small/geo.inc.c @@ -1,8 +1,8 @@ // 0x0C000000 const GeoLayout yellow_sphere_geo[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, yellow_sphere_seg5_dl_050008C8), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, yellow_sphere_seg5_dl_050008C8), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/actors/yoshi/geo.inc.c b/actors/yoshi/geo.inc.c index 86252d55..6b9f6fa2 100644 --- a/actors/yoshi/geo.inc.c +++ b/actors/yoshi/geo.inc.c @@ -1,77 +1,77 @@ // 0x0C000468 const GeoLayout yoshi_geo[] = { - GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0xC8, 100), - GEO_OPEN_NODE(), - GEO_SCALE(0x00, 16384), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, yoshi_seg5_dl_05022608), + GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0xC8, 100), + GEO_OPEN_NODE(), + GEO_SCALE(0x00, 16384), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 100, 0, 0, yoshi_seg5_dl_05022408), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 222, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_SWITCH_CASE(2, geo_switch_anim_state), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, yoshi_seg5_dl_0501D970), - GEO_DISPLAY_LIST(LAYER_OPAQUE, yoshi_seg5_dl_0501D998), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 76, 49, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, yoshi_seg5_dl_050212B0), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 51, 55, 97, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, yoshi_seg5_dl_05021678), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 74, 0, 0, yoshi_seg5_dl_050215D8), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, yoshi_seg5_dl_05022608), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 100, 0, 0, yoshi_seg5_dl_05022408), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 222, 0, 0, NULL), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 69, 0, 0, yoshi_seg5_dl_05021490), + GEO_SWITCH_CASE(2, geo_switch_anim_state), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, yoshi_seg5_dl_0501D970), + GEO_DISPLAY_LIST(LAYER_OPAQUE, yoshi_seg5_dl_0501D998), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 51, 55, -97, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, yoshi_seg5_dl_05021900), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 74, 0, 0, yoshi_seg5_dl_05021860), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 69, 0, 0, yoshi_seg5_dl_05021718), + GEO_ANIMATED_PART(LAYER_OPAQUE, 76, 49, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, yoshi_seg5_dl_050212B0), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, -1, 27, 95, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, yoshi_seg5_dl_05021CD8), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 100, 0, 0, yoshi_seg5_dl_05021B90), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 95, 0, 0, yoshi_seg5_dl_050219A0), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, -89, -62, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, yoshi_seg5_dl_05021E38), - GEO_CLOSE_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, -1, 27, -95, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, yoshi_seg5_dl_050222A8), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 100, 0, 0, yoshi_seg5_dl_05022160), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 95, 0, 0, yoshi_seg5_dl_05021F70), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 51, 55, 97, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, yoshi_seg5_dl_05021678), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 74, 0, 0, yoshi_seg5_dl_050215D8), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 69, 0, 0, yoshi_seg5_dl_05021490), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 51, 55, -97, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, yoshi_seg5_dl_05021900), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 74, 0, 0, yoshi_seg5_dl_05021860), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 69, 0, 0, yoshi_seg5_dl_05021718), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, -1, 27, 95, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, yoshi_seg5_dl_05021CD8), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 100, 0, 0, yoshi_seg5_dl_05021B90), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 95, 0, 0, yoshi_seg5_dl_050219A0), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, -89, -62, 0, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, yoshi_seg5_dl_05021E38), + GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, -1, 27, -95, NULL), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, yoshi_seg5_dl_050222A8), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 100, 0, 0, yoshi_seg5_dl_05022160), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 95, 0, 0, yoshi_seg5_dl_05021F70), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/actors/yoshi_egg/geo.inc.c b/actors/yoshi_egg/geo.inc.c index c1c5bf14..0f2da79f 100644 --- a/actors/yoshi_egg/geo.inc.c +++ b/actors/yoshi_egg/geo.inc.c @@ -1,18 +1,18 @@ // 0x0C0001E4 const GeoLayout yoshi_egg_geo[] = { - GEO_SCALE(0x00, 16384), - GEO_OPEN_NODE(), - GEO_SWITCH_CASE(8, geo_switch_anim_state), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, yoshi_egg_seg5_dl_050098C8), - GEO_DISPLAY_LIST(LAYER_ALPHA, yoshi_egg_seg5_dl_050098B0), - GEO_DISPLAY_LIST(LAYER_ALPHA, yoshi_egg_seg5_dl_05009898), - GEO_DISPLAY_LIST(LAYER_ALPHA, yoshi_egg_seg5_dl_05009880), - GEO_DISPLAY_LIST(LAYER_ALPHA, yoshi_egg_seg5_dl_05009868), - GEO_DISPLAY_LIST(LAYER_ALPHA, yoshi_egg_seg5_dl_05009850), - GEO_DISPLAY_LIST(LAYER_ALPHA, yoshi_egg_seg5_dl_05009838), - GEO_DISPLAY_LIST(LAYER_ALPHA, yoshi_egg_seg5_dl_05009820), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_SCALE(0x00, 16384), + GEO_OPEN_NODE(), + GEO_SWITCH_CASE(8, geo_switch_anim_state), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, yoshi_egg_seg5_dl_050098C8), + GEO_DISPLAY_LIST(LAYER_ALPHA, yoshi_egg_seg5_dl_050098B0), + GEO_DISPLAY_LIST(LAYER_ALPHA, yoshi_egg_seg5_dl_05009898), + GEO_DISPLAY_LIST(LAYER_ALPHA, yoshi_egg_seg5_dl_05009880), + GEO_DISPLAY_LIST(LAYER_ALPHA, yoshi_egg_seg5_dl_05009868), + GEO_DISPLAY_LIST(LAYER_ALPHA, yoshi_egg_seg5_dl_05009850), + GEO_DISPLAY_LIST(LAYER_ALPHA, yoshi_egg_seg5_dl_05009838), + GEO_DISPLAY_LIST(LAYER_ALPHA, yoshi_egg_seg5_dl_05009820), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/asm/boot.s b/asm/boot.s index 17a0ace7..381e19ba 100644 --- a/asm/boot.s +++ b/asm/boot.s @@ -1,10 +1,26 @@ // assembler directives .set noat // allow manual use of $at .set noreorder // don't insert nops after branches -.set gp=64 #include "macros.inc" +.equ EXCEPTION_TLB_MISS, 0x80000000 +.equ SP_DMEM, 0xA4000000 +.equ SP_IMEM, 0xA4001000 +.equ MI_MODE_REG, 0xA4300000 +.equ RI_MODE_REG, 0xA4700000 + +#ifdef VERSION_CN +.macro cn_li a b + li \a, \b +.endm +#else +.macro cn_li a b + lui \a, %hi(\b) + addiu \a, \a, %lo(\b) +.endm +#endif + // 0xA0000000-0xBFFFFFFF: KSEG1 direct map non-cache mirror of 0x00000000 // 0xA4000000-0xA4000FFF: RSP DMEM @@ -19,8 +35,7 @@ glabel ipl3_entry // 0xA4000040 mtc0 $zero, $13 mtc0 $zero, $9 mtc0 $zero, $11 - lui $t0, %hi(RI_MODE_REG) - addiu $t0, %lo(RI_MODE_REG) + cn_li $t0, RI_MODE_REG lw $t1, 0xc($t0) bnez $t1, .LA4000410 nop @@ -30,15 +45,13 @@ glabel ipl3_entry // 0xA4000040 sw $s5, 8($sp) sw $s6, 0xc($sp) sw $s7, 0x10($sp) - lui $t0, %hi(RI_MODE_REG) - addiu $t0, %lo(RI_MODE_REG) + cn_li $t0, RI_MODE_REG lui $t2, (0xa3f80000 >> 16) lui $t3, (0xa3f00000 >> 16) - lui $t4, %hi(MI_MODE_REG) - addiu $t4, %lo(MI_MODE_REG) + cn_li $t4, MI_MODE_REG ori $t1, $zero, 64 sw $t1, 4($t0) - li $s1, 8000 + li $s1, 8000 .LA400009C: nop addi $s1, $s1, -1 @@ -71,20 +84,19 @@ glabel ipl3_entry // 0xA4000040 move $t5, $zero move $t6, $zero lui $t7, (0xA3F00000 >> 16) - move $t8, $zero + move $t8, $zero lui $t9, (0xA3F00000 >> 16) lui $s6, (0xA0000000 >> 16) - move $s7, $zero + move $s7, $zero lui $a2, (0xA3F00000 >> 16) lui $a3, (0xA0000000 >> 16) - move $s2, $zero + move $s2, $zero lui $s4, (0xA0000000 >> 16) addiu $sp, $sp, -0x48 - move $fp, $sp + move $fp, $sp lui $s0, %hi(MI_VERSION_REG) lw $s0, %lo(MI_VERSION_REG)($s0) - lui $s1, (0x01010101 >> 16) - addiu $s1, (0x01010101 & 0xFFFF) + cn_li $s1, 0x01010101 bne $s0, $s1, .LA4000160 nop li $s0, 512 @@ -161,12 +173,16 @@ glabel ipl3_entry // 0xA4000040 bnez $t0, .LA4000168 nop .LA400025C: +#ifdef VERSION_CN + li $t0, 0xc0000000 +#else li $t0, 0xc4000000 +#endif sw $t0, 0xc($t2) li $t0, 0x80000000 sw $t0, 0x4($t2) - move $sp, $fp - move $v1, $zero + move $sp, $fp + move $v1, $zero .LA4000274: lw $t1, 4($sp) lui $t0, 0xb009 @@ -245,7 +261,7 @@ glabel ipl3_entry // 0xA4000040 ori $t1, (0x0FFFFFFF & 0xFFFF) and $s6, $s6, $t1 sw $s6, 0x18($t0) - move $sp, $fp + move $sp, $fp addiu $sp, $sp, 0x48 lw $s3, ($sp) lw $s4, 4($sp) @@ -253,8 +269,7 @@ glabel ipl3_entry // 0xA4000040 lw $s6, 0xc($sp) lw $s7, 0x10($sp) addiu $sp, $sp, 0x18 - lui $t0, %hi(EXCEPTION_TLB_MISS) - addiu $t0, $t0, %lo(EXCEPTION_TLB_MISS) + cn_li $t0, EXCEPTION_TLB_MISS addiu $t1, $t0, 0x4000 addiu $t1, $t1, -0x20 mtc0 $zero, $28 @@ -264,8 +279,7 @@ glabel ipl3_entry // 0xA4000040 sltu $at, $t0, $t1 bnez $at, .LA40003D8 addiu $t0, $t0, 0x20 - lui $t0, %hi(EXCEPTION_TLB_MISS) - addiu $t0, %lo(EXCEPTION_TLB_MISS) + cn_li $t0, EXCEPTION_TLB_MISS addiu $t1, $t0, 0x2000 addiu $t1, $t1, -0x10 .LA40003F8: @@ -276,8 +290,7 @@ glabel ipl3_entry // 0xA4000040 b .LA4000458 nop .LA4000410: - lui $t0, %hi(EXCEPTION_TLB_MISS) - addiu $t0, %lo(EXCEPTION_TLB_MISS) + cn_li $t0, EXCEPTION_TLB_MISS addiu $t1, $t0, 0x4000 addiu $t1, $t1, -0x20 mtc0 $zero, $28 @@ -287,8 +300,7 @@ glabel ipl3_entry // 0xA4000040 sltu $at, $t0, $t1 bnez $at, .LA4000428 addiu $t0, $t0, 0x20 - lui $t0, %hi(EXCEPTION_TLB_MISS) - addiu $t0, %lo(EXCEPTION_TLB_MISS) + cn_li $t0, EXCEPTION_TLB_MISS addiu $t1, $t0, 0x2000 addiu $t1, $t1, -0x10 .LA4000448: @@ -297,8 +309,45 @@ glabel ipl3_entry // 0xA4000040 bnez $at, .LA4000448 addiu $t0, $t0, 0x10 .LA4000458: - lui $t2, %hi(SP_DMEM) - addiu $t2, $t2, %lo(SP_DMEM) +#ifdef VERSION_CN + la $t0, D_CN_0400049C + lui $t1, 0xf + ori $t1, $t1, 0xffff + and $t0, $t0, $t1 + lui $t2, 0xa400 + lui $t3, 0xfff0 + and $t2, $t2, $t3 + or $t0, $t0, $t2 + la $t3, D_CN_0400074C + and $t3, $t3, $t1 + or $t3, $t3, $t2 + lui $t1, 0xa000 +.LA4000474: + lw $t5, ($t0) + sw $t5, ($t1) + addiu $t0, $t0, 4 + addiu $t1, $t1, 4 + sltu $at, $t0, $t3 + bnez $at, .LA4000474 + nop + lui $t4, 0x8000 + jr $t4 + nop + lui $t3, 0xb000 + lui $t2, 0x1fff + ori $t2, $t2, 0xffff + lw $t1, 8($t3) + and $t1, $t1, $t2 + lui $at, 0xa460 + sw $t1, ($at) +.LA40004B8: + lui $t0, 0xa460 + lw $t0, 0x10($t0) + andi $t0, $t0, 2 + bnez $t0, .LA40004B8 + nop +#else + cn_li $t2, SP_DMEM lui $t3, 0xfff0 lui $t1, 0x0010 and $t2, $t2, $t3 @@ -320,8 +369,7 @@ glabel ipl3_entry // 0xA4000040 addiu $t1, $t1, 4 bnez $at, .LA4000498 sw $t5, -4($t1) - lui $t4, %hi(EXCEPTION_TLB_MISS) - addiu $t4, %lo(EXCEPTION_TLB_MISS) + cn_li $t4, EXCEPTION_TLB_MISS jr $t4 nop lui $t3, %hi(D_B0000008) @@ -337,13 +385,13 @@ glabel ipl3_entry // 0xA4000040 andi $t0, $t0, 2 bnezl $t0, .LA40004D0 lui $t0, %hi(PI_STATUS_REG) +#endif li $t0, 0x1000 add $t0, $t0, $t3 and $t0, $t0, $t2 lui $at, %hi(PI_CART_ADDR_REG) sw $t0, %lo(PI_CART_ADDR_REG)($at) - lui $t2, 0x0010 - addiu $t2, 0xFFFF + cn_li $t2, 0x000FFFFF lui $at, %hi(PI_WR_LEN_REG) sw $t2, %lo(PI_WR_LEN_REG)($at) @@ -381,6 +429,104 @@ glabel ipl3_entry // 0xA4000040 andi $t3, $t3, 0x1 bnez $t3, .LA4000514 nop +#ifdef VERSION_CN + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop +#endif +#ifdef VERSION_CN + lui $t1, %hi(SP_PC) + lw $t1, %lo(SP_PC)($t1) + beqz $t1, .LA4000698 + nop + addiu $t2, $zero, 0x41 + lui $at, %hi(SP_STATUS_REG) + sw $t2, %lo(SP_STATUS_REG)($at) + lui $at, %hi(SP_PC) + sw $zero, %lo(SP_PC)($at) +.LA4000698: + li $t3, 0x00AAAAAE + lui $at, %hi(SP_STATUS_REG) + sw $t3, %lo(SP_STATUS_REG)($at) + li $t0, 1365 + lui $at, %hi(MI_INTR_MASK_REG) + sw $t0, %lo(MI_INTR_MASK_REG)($at) + lui $at, %hi(SI_STATUS_REG) + sw $zero, %lo(SI_STATUS_REG)($at) + lui $at, %hi(AI_STATUS_REG) + sw $zero, %lo(AI_STATUS_REG)($at) + li $t1, 2048 + lui $at, %hi(MI_MODE_REG) + sw $t1, %lo(MI_MODE_REG)($at) + li $t1, 2 + lui $at, %hi(PI_STATUS_REG) + sw $t1, %lo(PI_STATUS_REG)($at) + lui $t0, (0xA0000300 >> 16) + ori $t0, (0xA0000300 & 0xFFFF) + sw $s4, ($t0) + sw $s3, 4($t0) +#else lui $t3, %hi(D_B0000008) lw $a0, %lo(D_B0000008)($t3) move $a1, $s6 @@ -463,8 +609,7 @@ func_A4000690: lui $at, %hi(SP_PC) sw $zero, %lo(SP_PC)($at) .LA40006BC: - lui $t3, (0x00AAAAAE >> 16) - ori $t3, (0x00AAAAAE & 0xFFFF) + li $t3, 0x00AAAAAE lui $at, %hi(SP_STATUS_REG) sw $t3, %lo(SP_STATUS_REG)($at) lui $at, %hi(MI_INTR_MASK_REG) @@ -483,32 +628,53 @@ func_A4000690: ori $t0, (0xA0000300 & 0xFFFF) sw $t1, %lo(PI_STATUS_REG)($at) sw $s7, 0x14($t0) +#endif sw $s5, 0xc($t0) +#ifdef VERSION_CN + beqz $s3, .LA4000728 + sw $s7, 0x14($t0) + b .LA4000730 + lui $t1, 0xa600 +#else sw $s3, 0x4($t0) beqz $s3, .LA4000728 sw $s4, ($t0) lui $t1, 0xa600 b .LA4000730 addiu $t1, $t1, 0 +#endif .LA4000728: - lui $t1, 0xb000 - addiu $t1, $t1, 0 + cn_li $t1, 0xb0000000 .LA4000730: sw $t1, 0x8($t0) - lui $t0, %hi(SP_DMEM) - addiu $t0, %lo(SP_DMEM) + cn_li $t0, SP_DMEM addi $t1, $t0, 0x1000 +#ifdef VERSION_CN +.LA4000710: + sw $zero, ($t0) + addiu $t0, $t0, 4 + bne $t0, $t1, .LA4000710 + nop +#else .LA4000740: addiu $t0, $t0, 4 bne $t0, $t1, .LA4000740 sw $zero, -4($t0) - lui $t0, %hi(SP_IMEM) - addiu $t0, %lo(SP_IMEM) +#endif + cn_li $t0, SP_IMEM addi $t1, $t0, 0x1000 +#ifdef VERSION_CN +.LA400072C: + sw $zero, ($t0) + addiu $t0, $t0, 4 + bne $t0, $t1, .LA400072C + nop +#else .LA4000758: addiu $t0, $t0, 4 bne $t0, $t1, .LA4000758 sw $zero, -4($t0) +#endif lui $t3, %hi(D_B0000008) lw $t1, %lo(D_B0000008)($t3) jr $t1 @@ -517,10 +683,12 @@ func_A4000690: func_A4000778: addiu $sp, $sp, -0xa0 +#ifndef VERSION_CN sw $s0, 0x40($sp) sw $s1, 0x44($sp) move $s1, $zero move $s0, $zero +#endif sw $v0, ($sp) sw $v1, 4($sp) sw $a0, 8($sp) @@ -537,6 +705,10 @@ func_A4000778: sw $t7, 0x34($sp) sw $t8, 0x38($sp) sw $t9, 0x3c($sp) +#ifdef VERSION_CN + sw $s0, 0x40($sp) + sw $s1, 0x44($sp) +#endif sw $s2, 0x48($sp) sw $s3, 0x4c($sp) sw $s4, 0x50($sp) @@ -545,19 +717,34 @@ func_A4000778: sw $s7, 0x5c($sp) sw $fp, 0x60($sp) sw $ra, 0x64($sp) +#ifdef VERSION_CN + move $s0, $zero + move $s1, $zero +#endif .LA40007EC: jal func_A4000880 nop addiu $s0, $s0, 1 +#ifdef VERSION_CN + addu $s1, $s1, $v0 +#endif slti $t1, $s0, 4 bnez $t1, .LA40007EC +#ifdef VERSION_CN + nop +#else addu $s1, $s1, $v0 +#endif srl $a0, $s1, 2 jal func_A4000A40 li $a1, 1 +#ifdef VERSION_CN + srl $v0, $s1, 2 +#else lw $ra, 0x64($sp) srl $v0, $s1, 2 lw $s1, 0x44($sp) +#endif lw $v1, 4($sp) lw $a0, 8($sp) lw $a1, 0xc($sp) @@ -574,6 +761,9 @@ func_A4000778: lw $t8, 0x38($sp) lw $t9, 0x3c($sp) lw $s0, 0x40($sp) +#ifdef VERSION_CN + lw $s1, 0x44($sp) +#endif lw $s2, 0x48($sp) lw $s3, 0x4c($sp) lw $s4, 0x50($sp) @@ -581,6 +771,9 @@ func_A4000778: lw $s6, 0x58($sp) lw $s7, 0x5c($sp) lw $fp, 0x60($sp) +#ifdef VERSION_CN + lw $ra, 0x64($sp) +#endif jr $ra addiu $sp, $sp, 0xa0 @@ -592,22 +785,46 @@ func_A4000880: move $t4, $zero .LA4000894: slti $k0, $t4, 0x40 +#ifdef VERSION_CN + beqz $k0, .LA40008D4 + nop +#else beql $k0, $zero, .LA40008FC move $v0, $zero +#endif jal func_A400090C move $a0, $t4 +#ifdef VERSION_CN + blez $v0, .LA40008CC + nop +#else blezl $v0, .LA40008CC slti $k0, $t1, 0x50 +#endif subu $k0, $v0, $t1 multu $k0, $t4 +#ifndef VERSION_CN move $t1, $v0 +#endif mflo $k0 addu $t3, $t3, $k0 +#ifdef VERSION_CN + move $t1, $v0 +#else nop slti $k0, $t1, 0x50 +#endif .LA40008CC: +#ifdef VERSION_CN + addiu $t4, $t4, 1 + slti $k0, $t1, 0x50 +#endif bnez $k0, .LA4000894 +#ifdef VERSION_CN + nop +#else addiu $t4, $t4, 1 +#endif sll $a0, $t3, 2 subu $a0, $a0, $t3 sll $a0, $a0, 2 @@ -615,15 +832,27 @@ func_A4000880: sll $a0, $a0, 1 jal func_A4000980 addiu $a0, $a0, -0x370 +#ifdef VERSION_CN + b .LA40008FC + nop +.LA40008D4: + move $v0, $zero +#else b .LA4000900 lw $ra, 0x1c($sp) move $v0, $zero +#endif .LA40008FC: lw $ra, 0x1c($sp) .LA4000900: +#ifdef VERSION_CN + jr $ra + addiu $sp, $sp, 0x20 +#else addiu $sp, $sp, 0x20 jr $ra nop +#endif func_A400090C: addiu $sp, $sp, -0x28 @@ -632,7 +861,16 @@ func_A400090C: jal func_A4000A40 li $a1, 2 move $fp, $zero +.LA40008FC_cn: li $k0, -1 +#ifdef VERSION_CN + sw $k0, ($s4) + sw $k0, ($s4) + sw $k0, 4($s4) + lw $v1, 4($s4) + srl $v1, $v1, 0x10 + move $gp, $zero +#else .LA4000928: sw $k0, 4($s4) lw $v1, 4($s4) @@ -640,42 +878,82 @@ func_A400090C: sw $k0, ($s4) move $gp, $zero srl $v1, $v1, 0x10 +#endif .LA4000940: andi $k0, $v1, 1 +#ifdef VERSION_CN + beqz $k0, .LA4000928_cn + nop +#else beql $k0, $zero, .LA4000954 addiu $gp, $gp, 1 +#endif addiu $v0, $v0, 1 +#ifdef VERSION_CN +.LA4000928_cn: + srl $v1, $v1, 1 +#endif addiu $gp, $gp, 1 .LA4000954: slti $k0, $gp, 8 bnez $k0, .LA4000940 +#ifdef VERSION_CN + nop +#else srl $v1, $v1, 1 +#endif addiu $fp, $fp, 1 slti $k0, $fp, 0xa +#ifdef VERSION_CN + bnez $k0, .LA40008FC_cn + nop + lw $ra, 0x1c($sp) + jr $ra + addiu $sp, $sp, 0x28 +#else bnezl $k0, .LA4000928 li $k0, -1 lw $ra, 0x1c($sp) addiu $sp, $sp, 0x28 jr $ra nop +#endif func_A4000980: addiu $sp, $sp, -0x28 sw $ra, 0x1c($sp) sw $a0, 0x20($sp) +#ifndef VERSION_CN sb $zero, 0x27($sp) +#endif move $t0, $zero move $t2, $zero li $t5, 51200 +#ifdef VERSION_CN + sb $zero, 0x27($sp) +#endif move $t6, $zero +#ifdef VERSION_CN +.LA4000978: +#endif slti $k0, $t6, 0x40 .LA40009A4: +#ifdef VERSION_CN + bnez $k0, .LA400098C_cn + nop +#else bnezl $k0, .LA40009B8 move $a0, $t6 +#endif b .LA4000A30 - move $v0, $zero - move $a0, $t6 + move $v0, $zero +#ifdef VERSION_CN +.LA400098C_cn: +#endif + move $a0, $t6 +#ifndef VERSION_CN .LA40009B8: +#endif jal func_A4000A40 li $a1, 1 jal func_A4000AD0 @@ -684,6 +962,37 @@ func_A4000980: addiu $a0, $sp, 0x27 lbu $k0, 0x27($sp) li $k1, 800 +#ifdef VERSION_CN + multu $k0, $k1 + mflo $t0 + lw $a0, 0x20($sp) + subu $k0, $t0, $a0 + bgez $k0, .LA40009CC + nop + subu $k0, $a0, $t0 +.LA40009CC: + slt $k1, $k0, $t5 + beqz $k1, .LA40009E0 + nop + move $t5, $k0 + move $t2, $t6 +.LA40009E0: + lw $a0, 0x20($sp) + slt $k1, $t0, $a0 + beqz $k1, .LA4000A00 + nop + addiu $t6, $t6, 1 + slti $k1, $t6, 0x41 + bnez $k1, .LA4000978 + nop +.LA4000A00: + addu $v0, $t2, $t6 + srl $v0, $v0, 1 +.LA4000A30: + lw $ra, 0x1c($sp) + jr $ra + addiu $sp, $sp, 0x28 +#else lw $a0, 0x20($sp) multu $k0, $k1 mflo $t0 @@ -714,15 +1023,26 @@ func_A4000980: addiu $sp, $sp, 0x28 jr $ra nop +#endif func_A4000A40: addiu $sp, $sp, -0x28 +#ifdef VERSION_CN + sw $ra, 0x1c($sp) + lui $t7, 0x4200 + andi $a0, $a0, 0xff + xori $a0, $a0, 0x3f + li $k1, 1 + bne $a1, $k1, .LA4000A64 + nop +#else andi $a0, $a0, 0xff li $k1, 1 xori $a0, $a0, 0x3f sw $ra, 0x1c($sp) bne $a1, $k1, .LA4000A64 lui $t7, 0x4600 +#endif lui $k0, 0x8000 or $t7, $t7, $k0 .LA4000A64: @@ -744,31 +1064,53 @@ func_A4000A40: andi $k0, $a0, 0x20 sll $k0, $k0, 0x12 or $t7, $t7, $k0 +#ifdef VERSION_CN + sw $t7, ($s5) + li $k1, 1 + bne $a1, $k1, .LA4000AC0 + nop +#else li $k1, 1 bne $a1, $k1, .LA4000AC0 sw $t7, ($s5) +#endif lui $k0, %hi(MI_MODE_REG) sw $zero, %lo(MI_MODE_REG)($k0) .LA4000AC0: lw $ra, 0x1c($sp) +#ifdef VERSION_CN + jr $ra + addiu $sp, $sp, 0x28 +#else addiu $sp, $sp, 0x28 jr $ra nop +#endif func_A4000AD0: addiu $sp, $sp, -0x28 sw $ra, 0x1c($sp) +#ifdef VERSION_CN + move $fp, $zero +#endif li $k0, 0x2000 lui $k1, %hi(MI_MODE_REG) sw $k0, %lo(MI_MODE_REG)($k1) +#ifndef VERSION_CN move $fp, $zero +#endif lw $fp, ($s5) li $k0, 0x1000 sw $k0, %lo(MI_MODE_REG)($k1) +#ifdef VERSION_CN + move $k0, $zero +#endif li $k1, 0x40 and $k1, $k1, $fp srl $k1, $k1, 6 +#ifndef VERSION_CN move $k0, $zero +#endif or $k0, $k0, $k1 li $k1, 0x4000 and $k1, $k1, $fp @@ -792,61 +1134,13 @@ func_A4000AD0: or $k0, $k0, $k1 sb $k0, ($a0) lw $ra, 0x1c($sp) +#ifdef VERSION_CN + jr $ra + addiu $sp, $sp, 0x28 +.fill 0x30 +#else addiu $sp, $sp, 0x28 jr $ra nop nop - -// 0xA4000B70-0xA4000FFF: IPL3 Font -glabel ipl3_font -.incbin "textures/ipl3_raw/ipl3_font_00.ia1" -.incbin "textures/ipl3_raw/ipl3_font_01.ia1" -.incbin "textures/ipl3_raw/ipl3_font_02.ia1" -.incbin "textures/ipl3_raw/ipl3_font_03.ia1" -.incbin "textures/ipl3_raw/ipl3_font_04.ia1" -.incbin "textures/ipl3_raw/ipl3_font_05.ia1" -.incbin "textures/ipl3_raw/ipl3_font_06.ia1" -.incbin "textures/ipl3_raw/ipl3_font_07.ia1" -.incbin "textures/ipl3_raw/ipl3_font_08.ia1" -.incbin "textures/ipl3_raw/ipl3_font_09.ia1" -.incbin "textures/ipl3_raw/ipl3_font_10.ia1" -.incbin "textures/ipl3_raw/ipl3_font_11.ia1" -.incbin "textures/ipl3_raw/ipl3_font_12.ia1" -.incbin "textures/ipl3_raw/ipl3_font_13.ia1" -.incbin "textures/ipl3_raw/ipl3_font_14.ia1" -.incbin "textures/ipl3_raw/ipl3_font_15.ia1" -.incbin "textures/ipl3_raw/ipl3_font_16.ia1" -.incbin "textures/ipl3_raw/ipl3_font_17.ia1" -.incbin "textures/ipl3_raw/ipl3_font_18.ia1" -.incbin "textures/ipl3_raw/ipl3_font_19.ia1" -.incbin "textures/ipl3_raw/ipl3_font_20.ia1" -.incbin "textures/ipl3_raw/ipl3_font_21.ia1" -.incbin "textures/ipl3_raw/ipl3_font_22.ia1" -.incbin "textures/ipl3_raw/ipl3_font_23.ia1" -.incbin "textures/ipl3_raw/ipl3_font_24.ia1" -.incbin "textures/ipl3_raw/ipl3_font_25.ia1" -.incbin "textures/ipl3_raw/ipl3_font_26.ia1" -.incbin "textures/ipl3_raw/ipl3_font_27.ia1" -.incbin "textures/ipl3_raw/ipl3_font_28.ia1" -.incbin "textures/ipl3_raw/ipl3_font_29.ia1" -.incbin "textures/ipl3_raw/ipl3_font_30.ia1" -.incbin "textures/ipl3_raw/ipl3_font_31.ia1" -.incbin "textures/ipl3_raw/ipl3_font_32.ia1" -.incbin "textures/ipl3_raw/ipl3_font_33.ia1" -.incbin "textures/ipl3_raw/ipl3_font_34.ia1" -.incbin "textures/ipl3_raw/ipl3_font_35.ia1" -.incbin "textures/ipl3_raw/ipl3_font_36.ia1" -.incbin "textures/ipl3_raw/ipl3_font_37.ia1" -.incbin "textures/ipl3_raw/ipl3_font_38.ia1" -.incbin "textures/ipl3_raw/ipl3_font_39.ia1" -.incbin "textures/ipl3_raw/ipl3_font_40.ia1" -.incbin "textures/ipl3_raw/ipl3_font_41.ia1" -.incbin "textures/ipl3_raw/ipl3_font_42.ia1" -.incbin "textures/ipl3_raw/ipl3_font_43.ia1" -.incbin "textures/ipl3_raw/ipl3_font_44.ia1" -.incbin "textures/ipl3_raw/ipl3_font_45.ia1" -.incbin "textures/ipl3_raw/ipl3_font_46.ia1" -.incbin "textures/ipl3_raw/ipl3_font_47.ia1" -.incbin "textures/ipl3_raw/ipl3_font_48.ia1" -.incbin "textures/ipl3_raw/ipl3_font_49.ia1" -.fill 0x12 +#endif diff --git a/asm/decompress.s b/asm/decompress.s index 4c1733e4..7a90c25b 100644 --- a/asm/decompress.s +++ b/asm/decompress.s @@ -1,7 +1,6 @@ // assembler directives .set noat // allow manual use of $at .set noreorder // don't insert nops after branches -.set gp=64 #include "macros.inc" @@ -11,13 +10,13 @@ // This file is handwritten. glabel decompress -#if defined(VERSION_EU) || defined(VERSION_SH) +#if !defined(VERSION_JP) && !defined(VERSION_US) lw $a3, 8($a0) lw $t9, 0xc($a0) lw $t8, 4($a0) add $a3, $a3, $a0 add $t9, $t9, $a0 - move $a2, $zero + or $a2, $zero, $zero addi $a0, $a0, 0x10 add $t8, $t8, $a1 .L8026ED80: diff --git a/asm/entry.s b/asm/entry.s index fa95d8e1..e0f53fea 100644 --- a/asm/entry.s +++ b/asm/entry.s @@ -1,7 +1,6 @@ // assembler directives .set noat // allow manual use of $at .set noreorder // don't insert nops after branches -.set gp=64 #include "macros.inc" @@ -9,6 +8,25 @@ .section .text, "ax" glabel entry_point +.if VERSION_CN == 1 + lui $t0, %lo(_mainSegmentNoloadStartHi) + ori $t0, %lo(_mainSegmentNoloadStartLo) + lui $t1, %lo(_mainSegmentNoloadSizeHi) + ori $t1, %lo(_mainSegmentNoloadSizeLo) +.L80249010: + sw $zero, ($t0) + sw $zero, 4($t0) + addi $t0, $t0, 8 + addi $t1, $t1, -8 + bnez $t1, .L80249010 + nop + lui $sp, %lo(gIdleThreadStackHi) + ori $sp, %lo(gIdleThreadStackLo) + lui $t2, %lo(main_funcHi) + ori $t2, %lo(main_funcLo) + jr $t2 + nop +.else lui $t0, %hi(_mainSegmentNoloadStart) // $t0, 0x8034 lui $t1, %lo(_mainSegmentNoloadSizeHi) // lui $t1, 2 addiu $t0, %lo(_mainSegmentNoloadStart) // addiu $t0, $t0, -0x6df0 @@ -24,6 +42,7 @@ glabel entry_point addiu $t2, %lo(main_func) // addiu $t2, $t2, 0x6dc4 jr $t2 addiu $sp, %lo(gIdleThreadStack) // addiu $sp, $sp, 0xa00 +.endif nop nop nop diff --git a/asm/ipl3_font.s b/asm/ipl3_font.s new file mode 100644 index 00000000..f002a789 --- /dev/null +++ b/asm/ipl3_font.s @@ -0,0 +1,56 @@ +#include "macros.inc" + +// 0xA4000B70-0xA4000FFF: IPL3 Font +glabel ipl3_font +.incbin "textures/ipl3_raw/ipl3_font_00.ia1" +.incbin "textures/ipl3_raw/ipl3_font_01.ia1" +.incbin "textures/ipl3_raw/ipl3_font_02.ia1" +.incbin "textures/ipl3_raw/ipl3_font_03.ia1" +.incbin "textures/ipl3_raw/ipl3_font_04.ia1" +.incbin "textures/ipl3_raw/ipl3_font_05.ia1" +.incbin "textures/ipl3_raw/ipl3_font_06.ia1" +.incbin "textures/ipl3_raw/ipl3_font_07.ia1" +.incbin "textures/ipl3_raw/ipl3_font_08.ia1" +.incbin "textures/ipl3_raw/ipl3_font_09.ia1" +.incbin "textures/ipl3_raw/ipl3_font_10.ia1" +.incbin "textures/ipl3_raw/ipl3_font_11.ia1" +.incbin "textures/ipl3_raw/ipl3_font_12.ia1" +.incbin "textures/ipl3_raw/ipl3_font_13.ia1" +.incbin "textures/ipl3_raw/ipl3_font_14.ia1" +.incbin "textures/ipl3_raw/ipl3_font_15.ia1" +.incbin "textures/ipl3_raw/ipl3_font_16.ia1" +.incbin "textures/ipl3_raw/ipl3_font_17.ia1" +.incbin "textures/ipl3_raw/ipl3_font_18.ia1" +.incbin "textures/ipl3_raw/ipl3_font_19.ia1" +.incbin "textures/ipl3_raw/ipl3_font_20.ia1" +.incbin "textures/ipl3_raw/ipl3_font_21.ia1" +.incbin "textures/ipl3_raw/ipl3_font_22.ia1" +.incbin "textures/ipl3_raw/ipl3_font_23.ia1" +.incbin "textures/ipl3_raw/ipl3_font_24.ia1" +.incbin "textures/ipl3_raw/ipl3_font_25.ia1" +.incbin "textures/ipl3_raw/ipl3_font_26.ia1" +.incbin "textures/ipl3_raw/ipl3_font_27.ia1" +.incbin "textures/ipl3_raw/ipl3_font_28.ia1" +.incbin "textures/ipl3_raw/ipl3_font_29.ia1" +.incbin "textures/ipl3_raw/ipl3_font_30.ia1" +.incbin "textures/ipl3_raw/ipl3_font_31.ia1" +.incbin "textures/ipl3_raw/ipl3_font_32.ia1" +.incbin "textures/ipl3_raw/ipl3_font_33.ia1" +.incbin "textures/ipl3_raw/ipl3_font_34.ia1" +.incbin "textures/ipl3_raw/ipl3_font_35.ia1" +.incbin "textures/ipl3_raw/ipl3_font_36.ia1" +.incbin "textures/ipl3_raw/ipl3_font_37.ia1" +.incbin "textures/ipl3_raw/ipl3_font_38.ia1" +.incbin "textures/ipl3_raw/ipl3_font_39.ia1" +.incbin "textures/ipl3_raw/ipl3_font_40.ia1" +.incbin "textures/ipl3_raw/ipl3_font_41.ia1" +.incbin "textures/ipl3_raw/ipl3_font_42.ia1" +.incbin "textures/ipl3_raw/ipl3_font_43.ia1" +.incbin "textures/ipl3_raw/ipl3_font_44.ia1" +.incbin "textures/ipl3_raw/ipl3_font_45.ia1" +.incbin "textures/ipl3_raw/ipl3_font_46.ia1" +.incbin "textures/ipl3_raw/ipl3_font_47.ia1" +.incbin "textures/ipl3_raw/ipl3_font_48.ia1" +.incbin "textures/ipl3_raw/ipl3_font_49.ia1" +.fill 0x12 + diff --git a/asm/rom_header.s b/asm/rom_header.s index af8b9afd..0f6cd83c 100644 --- a/asm/rom_header.s +++ b/asm/rom_header.s @@ -10,12 +10,18 @@ /* Revision */ #ifdef VERSION_SH .word 0x00001448 +#elif defined(VERSION_CN) + .word 0x0000144C #elif defined(VERSION_EU) .word 0x00001446 #else /* NTSC-U and NTSC-J 1.0 */ .word 0x00001444 #endif +#ifdef VERSION_CN + .fill 0x30 +#else + .word 0x4EAA3D0E /* Checksum 1 */ .word 0x74757C24 /* Checksum 2 */ .word 0x00000000 /* Unknown */ @@ -44,3 +50,5 @@ #else .byte 0x00 /* Version */ #endif + +#endif diff --git a/assets.json b/assets.json index 691735f2..dd2e5a7d 100644 --- a/assets.json +++ b/assets.json @@ -4,735 +4,740 @@ "@sound ctl eu": [97856,{"eu":[5626032]}], "@sound ctl jp": [94400,{"jp":[5738816]}], "@sound ctl us": [97856,{"us":[5748512]}], -"@sound ctl sh": [89472,{"sh":[5596480]}], +"@sound ctl sh": [89472,{"sh":[5596480],"cn":[5669504]}], "@sound tbl eu": [2216704,{"us":[5846368],"eu":[5723888]}], "@sound tbl jp": [1793408,{"jp":[5833216]}], "@sound tbl us": [2216704,{"us":[5846368],"eu":[5723888]}], -"@sound tbl sh": [2184688,{"sh":[5685952]}], -"@sound ctl header sh": [624,{"sh":[864272]}], -"@sound tbl header sh": [192,{"sh":[865056]}], -"textures/ipl3_raw/ipl3_font_00.ia1.png": [13,14,23,{"jp":[2928],"us":[2928],"eu":[2928],"sh":[2928]}], -"textures/ipl3_raw/ipl3_font_01.ia1.png": [13,14,23,{"jp":[2951],"us":[2951],"eu":[2951],"sh":[2951]}], -"textures/ipl3_raw/ipl3_font_02.ia1.png": [13,14,23,{"jp":[2974],"us":[2974],"eu":[2974],"sh":[2974]}], -"textures/ipl3_raw/ipl3_font_03.ia1.png": [13,14,23,{"jp":[2997],"us":[2997],"eu":[2997],"sh":[2997]}], -"textures/ipl3_raw/ipl3_font_04.ia1.png": [13,14,23,{"jp":[3020],"us":[3020],"eu":[3020],"sh":[3020]}], -"textures/ipl3_raw/ipl3_font_05.ia1.png": [13,14,23,{"jp":[3043],"us":[3043],"eu":[3043],"sh":[3043]}], -"textures/ipl3_raw/ipl3_font_06.ia1.png": [13,14,23,{"jp":[3066],"us":[3066],"eu":[3066],"sh":[3066]}], -"textures/ipl3_raw/ipl3_font_07.ia1.png": [13,14,23,{"jp":[3089],"us":[3089],"eu":[3089],"sh":[3089]}], -"textures/ipl3_raw/ipl3_font_08.ia1.png": [13,14,23,{"jp":[3112],"us":[3112],"eu":[3112],"sh":[3112]}], -"textures/ipl3_raw/ipl3_font_09.ia1.png": [13,14,23,{"jp":[3135],"us":[3135],"eu":[3135],"sh":[3135]}], -"textures/ipl3_raw/ipl3_font_10.ia1.png": [13,14,23,{"jp":[3158],"us":[3158],"eu":[3158],"sh":[3158]}], -"textures/ipl3_raw/ipl3_font_11.ia1.png": [13,14,23,{"jp":[3181],"us":[3181],"eu":[3181],"sh":[3181]}], -"textures/ipl3_raw/ipl3_font_12.ia1.png": [13,14,23,{"jp":[3204],"us":[3204],"eu":[3204],"sh":[3204]}], -"textures/ipl3_raw/ipl3_font_13.ia1.png": [13,14,23,{"jp":[3227],"us":[3227],"eu":[3227],"sh":[3227]}], -"textures/ipl3_raw/ipl3_font_14.ia1.png": [13,14,23,{"jp":[3250],"us":[3250],"eu":[3250],"sh":[3250]}], -"textures/ipl3_raw/ipl3_font_15.ia1.png": [13,14,23,{"jp":[3273],"us":[3273],"eu":[3273],"sh":[3273]}], -"textures/ipl3_raw/ipl3_font_16.ia1.png": [13,14,23,{"jp":[3296],"us":[3296],"eu":[3296],"sh":[3296]}], -"textures/ipl3_raw/ipl3_font_17.ia1.png": [13,14,23,{"jp":[3319],"us":[3319],"eu":[3319],"sh":[3319]}], -"textures/ipl3_raw/ipl3_font_18.ia1.png": [13,14,23,{"jp":[3342],"us":[3342],"eu":[3342],"sh":[3342]}], -"textures/ipl3_raw/ipl3_font_19.ia1.png": [13,14,23,{"jp":[3365],"us":[3365],"eu":[3365],"sh":[3365]}], -"textures/ipl3_raw/ipl3_font_20.ia1.png": [13,14,23,{"jp":[3388],"us":[3388],"eu":[3388],"sh":[3388]}], -"textures/ipl3_raw/ipl3_font_21.ia1.png": [13,14,23,{"jp":[3411],"us":[3411],"eu":[3411],"sh":[3411]}], -"textures/ipl3_raw/ipl3_font_22.ia1.png": [13,14,23,{"jp":[3434],"us":[3434],"eu":[3434],"sh":[3434]}], -"textures/ipl3_raw/ipl3_font_23.ia1.png": [13,14,23,{"jp":[3457],"us":[3457],"eu":[3457],"sh":[3457]}], -"textures/ipl3_raw/ipl3_font_24.ia1.png": [13,14,23,{"jp":[3480],"us":[3480],"eu":[3480],"sh":[3480]}], -"textures/ipl3_raw/ipl3_font_25.ia1.png": [13,14,23,{"jp":[3503],"us":[3503],"eu":[3503],"sh":[3503]}], -"textures/ipl3_raw/ipl3_font_26.ia1.png": [13,14,23,{"jp":[3526],"us":[3526],"eu":[3526],"sh":[3526]}], -"textures/ipl3_raw/ipl3_font_27.ia1.png": [13,14,23,{"jp":[3549],"us":[3549],"eu":[3549],"sh":[3549]}], -"textures/ipl3_raw/ipl3_font_28.ia1.png": [13,14,23,{"jp":[3572],"us":[3572],"eu":[3572],"sh":[3572]}], -"textures/ipl3_raw/ipl3_font_29.ia1.png": [13,14,23,{"jp":[3595],"us":[3595],"eu":[3595],"sh":[3595]}], -"textures/ipl3_raw/ipl3_font_30.ia1.png": [13,14,23,{"jp":[3618],"us":[3618],"eu":[3618],"sh":[3618]}], -"textures/ipl3_raw/ipl3_font_31.ia1.png": [13,14,23,{"jp":[3641],"us":[3641],"eu":[3641],"sh":[3641]}], -"textures/ipl3_raw/ipl3_font_32.ia1.png": [13,14,23,{"jp":[3664],"us":[3664],"eu":[3664],"sh":[3664]}], -"textures/ipl3_raw/ipl3_font_33.ia1.png": [13,14,23,{"jp":[3687],"us":[3687],"eu":[3687],"sh":[3687]}], -"textures/ipl3_raw/ipl3_font_34.ia1.png": [13,14,23,{"jp":[3710],"us":[3710],"eu":[3710],"sh":[3710]}], -"textures/ipl3_raw/ipl3_font_35.ia1.png": [13,14,23,{"jp":[3733],"us":[3733],"eu":[3733],"sh":[3733]}], -"textures/ipl3_raw/ipl3_font_36.ia1.png": [13,14,23,{"jp":[3756],"us":[3756],"eu":[3756],"sh":[3756]}], -"textures/ipl3_raw/ipl3_font_37.ia1.png": [13,14,23,{"jp":[3779],"us":[3779],"eu":[3779],"sh":[3779]}], -"textures/ipl3_raw/ipl3_font_38.ia1.png": [13,14,23,{"jp":[3802],"us":[3802],"eu":[3802],"sh":[3802]}], -"textures/ipl3_raw/ipl3_font_39.ia1.png": [13,14,23,{"jp":[3825],"us":[3825],"eu":[3825],"sh":[3825]}], -"textures/ipl3_raw/ipl3_font_40.ia1.png": [13,14,23,{"jp":[3848],"us":[3848],"eu":[3848],"sh":[3848]}], -"textures/ipl3_raw/ipl3_font_41.ia1.png": [13,14,23,{"jp":[3871],"us":[3871],"eu":[3871],"sh":[3871]}], -"textures/ipl3_raw/ipl3_font_42.ia1.png": [13,14,23,{"jp":[3894],"us":[3894],"eu":[3894],"sh":[3894]}], -"textures/ipl3_raw/ipl3_font_43.ia1.png": [13,14,23,{"jp":[3917],"us":[3917],"eu":[3917],"sh":[3917]}], -"textures/ipl3_raw/ipl3_font_44.ia1.png": [13,14,23,{"jp":[3940],"us":[3940],"eu":[3940],"sh":[3940]}], -"textures/ipl3_raw/ipl3_font_45.ia1.png": [13,14,23,{"jp":[3963],"us":[3963],"eu":[3963],"sh":[3963]}], -"textures/ipl3_raw/ipl3_font_46.ia1.png": [13,14,23,{"jp":[3986],"us":[3986],"eu":[3986],"sh":[3986]}], -"textures/ipl3_raw/ipl3_font_47.ia1.png": [13,14,23,{"jp":[4009],"us":[4009],"eu":[4009],"sh":[4009]}], -"textures/ipl3_raw/ipl3_font_48.ia1.png": [13,14,23,{"jp":[4032],"us":[4032],"eu":[4032],"sh":[4032]}], -"textures/ipl3_raw/ipl3_font_49.ia1.png": [13,14,23,{"jp":[4055],"us":[4055],"eu":[4055],"sh":[4055]}], -"textures/crash_screen/crash_screen_font.ia1.png": [32,63,252,{"eu":[757168],"sh":[805680]}], -"actors/amp/amp_body.rgba16.png": [32,32,2048,{"jp":[2032944,6936],"us":[2040320,6936],"eu":[1912288,6936],"sh":[1888800,6936]}], -"actors/amp/amp_electricity.rgba16.png": [16,32,1024,{"jp":[2032944,3864],"us":[2040320,3864],"eu":[1912288,3864],"sh":[1888800,3864]}], -"actors/amp/amp_eyes.rgba16.png": [32,32,2048,{"jp":[2032944,4888],"us":[2040320,4888],"eu":[1912288,4888],"sh":[1888800,4888]}], -"actors/amp/amp_mouth.rgba16.png": [32,32,2048,{"jp":[2032944,8984],"us":[2040320,8984],"eu":[1912288,8984],"sh":[1888800,8984]}], -"actors/blue_coin_switch/blue_coin_switch_side.rgba16.png": [32,16,1024,{"jp":[2032944,24],"us":[2040320,24],"eu":[1912288,24],"sh":[1888800,24]}], -"actors/blue_coin_switch/blue_coin_switch_top.rgba16.png": [32,32,2048,{"jp":[2032944,1048],"us":[2040320,1048],"eu":[1912288,1048],"sh":[1888800,1048]}], -"actors/blue_fish/blue_fish.rgba16.png": [32,32,2048,{"jp":[2094912,112096],"us":[2102288,112096],"eu":[1974256,112096],"sh":[1950768,112096]}], -"actors/bobomb/bob-omb_buddy_left_side.rgba16.png": [32,64,4096,{"jp":[1257760,120],"us":[1264928,120],"eu":[1136896,120],"sh":[1113408,120]}], -"actors/bobomb/bob-omb_buddy_right_side.rgba16.png": [32,64,4096,{"jp":[1257760,4216],"us":[1264928,4216],"eu":[1136896,4216],"sh":[1113408,4216]}], -"actors/bobomb/bob-omb_eyes.rgba16.png": [32,32,2048,{"jp":[1257760,18552],"us":[1264928,18552],"eu":[1136896,18552],"sh":[1113408,18552]}], -"actors/bobomb/bob-omb_eyes_blink.rgba16.png": [32,32,2048,{"jp":[1257760,20600],"us":[1264928,20600],"eu":[1136896,20600],"sh":[1113408,20600]}], -"actors/bobomb/bob-omb_left_side.rgba16.png": [32,64,4096,{"jp":[2032944,121440],"us":[2040320,121440],"eu":[1912288,121440],"sh":[1888800,121440]}], -"actors/bobomb/bob-omb_right_side.rgba16.png": [32,64,4096,{"jp":[2032944,125536],"us":[2040320,125536],"eu":[1912288,125536],"sh":[1888800,125536]}], -"actors/bomb/bomb_left_side.rgba16.png": [32,64,4096,{"jp":[1599504,359104],"us":[1606720,359440],"eu":[1478688,359440],"sh":[1455200,359440]}], -"actors/bomb/bomb_right_side.rgba16.png": [32,64,4096,{"jp":[1599504,363200],"us":[1606720,363536],"eu":[1478688,363536],"sh":[1455200,363536]}], -"actors/bomb/bomb_spike.rgba16.png": [32,32,2048,{"jp":[1599504,367296],"us":[1606720,367632],"eu":[1478688,367632],"sh":[1455200,367632]}], -"actors/boo/boo_eyes.rgba16.png": [64,32,4096,{"jp":[1462368,39744],"us":[1469536,39744],"eu":[1341504,39744],"sh":[1318016,39744]}], -"actors/boo/boo_mouth.rgba16.png": [32,32,2048,{"jp":[1462368,43840],"us":[1469536,43840],"eu":[1341504,43840],"sh":[1318016,43840]}], -"actors/boo_castle/bbh_boo_eyes.rgba16.png": [64,32,4096,{"jp":[1462368,39744],"us":[1469536,39744],"eu":[1341504,39744],"sh":[1318016,39744]}], -"actors/boo_castle/bbh_boo_mouth.rgba16.png": [32,32,2048,{"jp":[1462368,43840],"us":[1469536,43840],"eu":[1341504,43840],"sh":[1318016,43840]}], -"actors/book/book_cover.rgba16.png": [32,32,2048,{"jp":[1462368,4192],"us":[1469536,4192],"eu":[1341504,4192],"sh":[1318016,4192]}], -"actors/bookend/bookend_cover.rgba16.png": [32,32,2048,{"jp":[1462368,4192],"us":[1469536,4192],"eu":[1341504,4192],"sh":[1318016,4192]}], -"actors/bookend/bookend_mouth.rgba16.png": [16,32,1024,{"jp":[1462368,2144],"us":[1469536,2144],"eu":[1341504,2144],"sh":[1318016,2144]}], -"actors/bookend/bookend_pages.rgba16.png": [16,32,1024,{"jp":[1462368,3168],"us":[1469536,3168],"eu":[1341504,3168],"sh":[1318016,3168]}], -"actors/bookend/bookend_spine.rgba16.png": [16,32,1024,{"jp":[1462368,96],"us":[1469536,96],"eu":[1341504,96],"sh":[1318016,96]}], -"actors/bookend/bookend_tooth.rgba16.png": [16,32,1024,{"jp":[1462368,1120],"us":[1469536,1120],"eu":[1341504,1120],"sh":[1318016,1120]}], -"actors/bowser/bowser_armband.rgba16.png": [32,32,2048,{"jp":[1599504,146488],"us":[1606720,146488],"eu":[1478688,146488],"sh":[1455200,146488]}], -"actors/bowser/bowser_armband_spike.rgba16.png": [64,32,4096,{"jp":[1599504,142392],"us":[1606720,142392],"eu":[1478688,142392],"sh":[1455200,142392]}], -"actors/bowser/bowser_blue_eye_unused.rgba16.png": [64,32,4096,{"jp":[1599504,156728],"us":[1606720,156728],"eu":[1478688,156728],"sh":[1455200,156728]}], -"actors/bowser/bowser_body.rgba16.png": [32,32,2048,{"jp":[1599504,140344],"us":[1606720,140344],"eu":[1478688,140344],"sh":[1455200,140344]}], -"actors/bowser/bowser_chest.rgba16.png": [32,32,2048,{"jp":[1599504,152632],"us":[1606720,152632],"eu":[1478688,152632],"sh":[1455200,152632]}], -"actors/bowser/bowser_claw_edge.rgba16.png": [32,64,4096,{"jp":[1599504,171064],"us":[1606720,171064],"eu":[1478688,171064],"sh":[1455200,171064]}], -"actors/bowser/bowser_claw_horn_angle.rgba16.png": [32,64,4096,{"jp":[1599504,179256],"us":[1606720,179256],"eu":[1478688,179256],"sh":[1455200,179256]}], -"actors/bowser/bowser_claw_horn_tooth.rgba16.png": [32,64,4096,{"jp":[1599504,175160],"us":[1606720,175160],"eu":[1478688,175160],"sh":[1455200,175160]}], -"actors/bowser/bowser_eye_center_0.rgba16.png": [64,32,4096,{"jp":[1599504,195640],"us":[1606720,195640],"eu":[1478688,195640],"sh":[1455200,195640]}], -"actors/bowser/bowser_eye_center_1.rgba16.png": [64,32,4096,{"jp":[1599504,195640],"us":[1606720,195640],"eu":[1478688,195640],"sh":[1455200,195640]}], -"actors/bowser/bowser_eye_closed_0.rgba16.png": [64,32,4096,{"jp":[1599504,191544],"us":[1606720,191544],"eu":[1478688,191544],"sh":[1455200,191544]}], -"actors/bowser/bowser_eye_closed_1.rgba16.png": [64,32,4096,{"jp":[1599504,191544],"us":[1606720,191544],"eu":[1478688,191544],"sh":[1455200,191544]}], -"actors/bowser/bowser_eye_far_left_0.rgba16.png": [64,32,4096,{"jp":[1599504,203832],"us":[1606720,203832],"eu":[1478688,203832],"sh":[1455200,203832]}], -"actors/bowser/bowser_eye_far_left_1.rgba16.png": [64,32,4096,{"jp":[1599504,203832],"us":[1606720,203832],"eu":[1478688,203832],"sh":[1455200,203832]}], -"actors/bowser/bowser_eye_half_closed_0.rgba16.png": [64,32,4096,{"jp":[1599504,187448],"us":[1606720,187448],"eu":[1478688,187448],"sh":[1455200,187448]}], -"actors/bowser/bowser_eye_half_closed_1.rgba16.png": [64,32,4096,{"jp":[1599504,187448],"us":[1606720,187448],"eu":[1478688,187448],"sh":[1455200,187448]}], -"actors/bowser/bowser_eye_left_0.rgba16.png": [64,32,4096,{"jp":[1599504,183352],"us":[1606720,183352],"eu":[1478688,183352],"sh":[1455200,183352]}], -"actors/bowser/bowser_eye_left_1.rgba16.png": [64,32,4096,{"jp":[1599504,183352],"us":[1606720,183352],"eu":[1478688,183352],"sh":[1455200,183352]}], -"actors/bowser/bowser_eye_right_0.rgba16.png": [64,32,4096,{"jp":[1599504,199736],"us":[1606720,199736],"eu":[1478688,199736],"sh":[1455200,199736]}], -"actors/bowser/bowser_eye_right_1.rgba16.png": [64,32,4096,{"jp":[1599504,199736],"us":[1606720,199736],"eu":[1478688,199736],"sh":[1455200,199736]}], -"actors/bowser/bowser_eyebrow.rgba16.png": [64,32,4096,{"jp":[1599504,130104],"us":[1606720,130104],"eu":[1478688,130104],"sh":[1455200,130104]}], -"actors/bowser/bowser_hair.rgba16.png": [32,64,4096,{"jp":[1599504,166968],"us":[1606720,166968],"eu":[1478688,166968],"sh":[1455200,166968]}], -"actors/bowser/bowser_mouth_unused.rgba16.png": [64,32,4096,{"jp":[1599504,160824],"us":[1606720,160824],"eu":[1478688,160824],"sh":[1455200,160824]}], -"actors/bowser/bowser_muzzle.rgba16.png": [32,32,2048,{"jp":[1599504,134200],"us":[1606720,134200],"eu":[1478688,134200],"sh":[1455200,134200]}], -"actors/bowser/bowser_nostrils.rgba16.png": [64,32,4096,{"jp":[1599504,136248],"us":[1606720,136248],"eu":[1478688,136248],"sh":[1455200,136248]}], -"actors/bowser/bowser_shell.rgba16.png": [32,32,2048,{"jp":[1599504,128056],"us":[1606720,128056],"eu":[1478688,128056],"sh":[1455200,128056]}], -"actors/bowser/bowser_shell_edge.rgba16.png": [32,32,2048,{"jp":[1599504,154680],"us":[1606720,154680],"eu":[1478688,154680],"sh":[1455200,154680]}], -"actors/bowser/bowser_tongue.rgba16.png": [32,64,4096,{"jp":[1599504,148536],"us":[1606720,148536],"eu":[1478688,148536],"sh":[1455200,148536]}], -"actors/bowser/bowser_upper_face.rgba16.png": [32,32,2048,{"jp":[1599504,164920],"us":[1606720,164920],"eu":[1478688,164920],"sh":[1455200,164920]}], -"actors/bowser_flame/bowser_flame_0.rgba16.png": [64,64,8192,{"jp":[1599504,0],"us":[1606720,0],"eu":[1478688,0],"sh":[1455200,0]}], -"actors/bowser_flame/bowser_flame_1.rgba16.png": [64,64,8192,{"jp":[1599504,8192],"us":[1606720,8192],"eu":[1478688,8192],"sh":[1455200,8192]}], -"actors/bowser_flame/bowser_flame_10.rgba16.png": [64,64,8192,{"jp":[1599504,81920],"us":[1606720,81920],"eu":[1478688,81920],"sh":[1455200,81920]}], -"actors/bowser_flame/bowser_flame_11.rgba16.png": [64,64,8192,{"jp":[1599504,90112],"us":[1606720,90112],"eu":[1478688,90112],"sh":[1455200,90112]}], -"actors/bowser_flame/bowser_flame_12.rgba16.png": [64,64,8192,{"jp":[1599504,98304],"us":[1606720,98304],"eu":[1478688,98304],"sh":[1455200,98304]}], -"actors/bowser_flame/bowser_flame_13.rgba16.png": [64,64,8192,{"jp":[1599504,106496],"us":[1606720,106496],"eu":[1478688,106496],"sh":[1455200,106496]}], -"actors/bowser_flame/bowser_flame_2.rgba16.png": [64,64,8192,{"jp":[1599504,16384],"us":[1606720,16384],"eu":[1478688,16384],"sh":[1455200,16384]}], -"actors/bowser_flame/bowser_flame_3.rgba16.png": [64,64,8192,{"jp":[1599504,24576],"us":[1606720,24576],"eu":[1478688,24576],"sh":[1455200,24576]}], -"actors/bowser_flame/bowser_flame_4.rgba16.png": [64,64,8192,{"jp":[1599504,32768],"us":[1606720,32768],"eu":[1478688,32768],"sh":[1455200,32768]}], -"actors/bowser_flame/bowser_flame_5.rgba16.png": [64,64,8192,{"jp":[1599504,40960],"us":[1606720,40960],"eu":[1478688,40960],"sh":[1455200,40960]}], -"actors/bowser_flame/bowser_flame_6.rgba16.png": [64,64,8192,{"jp":[1599504,49152],"us":[1606720,49152],"eu":[1478688,49152],"sh":[1455200,49152]}], -"actors/bowser_flame/bowser_flame_7.rgba16.png": [64,64,8192,{"jp":[1599504,57344],"us":[1606720,57344],"eu":[1478688,57344],"sh":[1455200,57344]}], -"actors/bowser_flame/bowser_flame_8.rgba16.png": [64,64,8192,{"jp":[1599504,65536],"us":[1606720,65536],"eu":[1478688,65536],"sh":[1455200,65536]}], -"actors/bowser_flame/bowser_flame_9.rgba16.png": [64,64,8192,{"jp":[1599504,73728],"us":[1606720,73728],"eu":[1478688,73728],"sh":[1455200,73728]}], -"actors/breakable_box/cork_box_surface.rgba16.png": [32,32,2048,{"jp":[2032944,74384],"us":[2040320,74384],"eu":[1912288,74384],"sh":[1888800,74384]}], -"actors/breakable_box/crazy_box_surface.rgba16.png": [32,32,2048,{"jp":[2032944,72336],"us":[2040320,72336],"eu":[1912288,72336],"sh":[1888800,72336]}], -"actors/bub/bub_eye_border.rgba16.png": [32,32,2048,{"jp":[1568640,5128],"us":[1575856,5128],"eu":[1447824,5128],"sh":[1424336,5128]}], -"actors/bub/bub_eyes.rgba16.png": [64,32,4096,{"jp":[1568640,1032],"us":[1575856,1032],"eu":[1447824,1032],"sh":[1424336,1032]}], -"actors/bub/bub_fins.rgba16.png": [32,32,2048,{"jp":[1568640,7176],"us":[1575856,7176],"eu":[1447824,7176],"sh":[1424336,7176]}], -"actors/bub/bub_scales.rgba16.png": [64,32,4096,{"jp":[1568640,9224],"us":[1575856,9224],"eu":[1447824,9224],"sh":[1424336,9224]}], -"actors/bubba/bubba_eye_border.rgba16.png": [32,32,2048,{"jp":[1568640,5128],"us":[1575856,5128],"eu":[1447824,5128],"sh":[1424336,5128]}], -"actors/bubba/bubba_eyes_unused.rgba16.png": [64,32,4096,{"jp":[1568640,1032],"us":[1575856,1032],"eu":[1447824,1032],"sh":[1424336,1032]}], -"actors/bubba/bubba_fins.rgba16.png": [32,32,2048,{"jp":[1568640,7176],"us":[1575856,7176],"eu":[1447824,7176],"sh":[1424336,7176]}], -"actors/bubba/bubba_scales.rgba16.png": [64,64,8192,{"jp":[1568640,9224],"us":[1575856,9224],"eu":[1447824,9224],"sh":[1424336,9224]}], -"actors/bubba/bubba_sunglasses.rgba16.png": [16,32,1024,{"jp":[1568640,8],"us":[1575856,8],"eu":[1447824,8],"sh":[1424336,8]}], -"actors/bubble/bubble.rgba16.png": [32,32,2048,{"jp":[1125200,118112],"us":[1132368,118112],"eu":[1004336,118112],"sh":[980848,118112]}], -"actors/bubble/mr_i_bubble.rgba16.png": [32,32,2048,{"jp":[1125200,120160],"us":[1132368,120160],"eu":[1004336,120160],"sh":[980848,120160]}], -"actors/bullet_bill/bullet_bill_eye.rgba16.png": [64,32,4096,{"jp":[1215456,47784],"us":[1222624,47784],"eu":[1094592,47784],"sh":[1071104,47784]}], -"actors/bullet_bill/bullet_bill_mouth.rgba16.png": [64,32,4096,{"jp":[1215456,51880],"us":[1222624,51880],"eu":[1094592,51880],"sh":[1071104,51880]}], -"actors/bully/bully_eye.rgba16.png": [32,32,2048,{"jp":[1249376,9320],"us":[1256544,9320],"eu":[1128512,9320],"sh":[1105024,9320]}], -"actors/bully/bully_horn.rgba16.png": [16,16,512,{"jp":[1249376,224],"us":[1256544,224],"eu":[1128512,224],"sh":[1105024,224]}], -"actors/bully/bully_left_side.rgba16.png": [32,64,4096,{"jp":[1249376,1128],"us":[1256544,1128],"eu":[1128512,1128],"sh":[1105024,1128]}], -"actors/bully/bully_right_side.rgba16.png": [32,64,4096,{"jp":[1249376,5224],"us":[1256544,5224],"eu":[1128512,5224],"sh":[1105024,5224]}], -"actors/burn_smoke/burn_smoke.ia16.png": [32,32,2048,{"jp":[1125200,137216],"us":[1132368,137216],"eu":[1004336,137216],"sh":[980848,137216]}], -"actors/butterfly/butterfly_wing.rgba16.png": [32,64,4096,{"jp":[2094912,17320],"us":[2102288,17320],"eu":[1974256,17320],"sh":[1950768,17320]}], -"actors/cannon_barrel/cannon_barrel.rgba16.png": [32,32,2048,{"jp":[2032944,22696],"us":[2040320,22696],"eu":[1912288,22696],"sh":[1888800,22696]}], -"actors/cannon_base/cannon_base.rgba16.png": [32,32,2048,{"jp":[2032944,18872],"us":[2040320,18872],"eu":[1912288,18872],"sh":[1888800,18872]}], -"actors/cannon_lid/cannon_lid.rgba16.png": [32,32,2048,{"jp":[2032944,16472],"us":[2040320,16472],"eu":[1912288,16472],"sh":[1888800,16472]}], -"actors/capswitch/cap_switch_base.rgba16.png": [16,4,128,{"jp":[1457744,11336],"us":[1464912,11336],"eu":[1336880,11336],"sh":[1313392,11336]}], -"actors/capswitch/cap_switch_head.ia16.png": [32,64,4096,{"jp":[1457744,7240],"us":[1464912,7240],"eu":[1336880,7240],"sh":[1313392,7240]}], -"actors/chain_ball/chain_ball.rgba16.png": [32,32,2048,{"jp":[1844608,133864],"us":[1851952,133864],"eu":[1723920,133864],"sh":[1700432,133864]}], -"actors/chain_chomp/chain_chomp_bright_shine.rgba16.png": [32,32,2048,{"jp":[1844608,136144],"us":[1851952,136144],"eu":[1723920,136144],"sh":[1700432,136144]}], -"actors/chain_chomp/chain_chomp_dull_shine.rgba16.png": [32,32,2048,{"jp":[1844608,138192],"us":[1851952,138192],"eu":[1723920,138192],"sh":[1700432,138192]}], -"actors/chain_chomp/chain_chomp_eye.rgba16.png": [32,32,2048,{"jp":[1844608,144336],"us":[1851952,144336],"eu":[1723920,144336],"sh":[1700432,144336]}], -"actors/chain_chomp/chain_chomp_tongue.rgba16.png": [32,32,2048,{"jp":[1844608,140240],"us":[1851952,140240],"eu":[1723920,140240],"sh":[1700432,140240]}], -"actors/chain_chomp/chain_chomp_tooth.rgba16.png": [32,32,2048,{"jp":[1462368,27376],"us":[1469536,27376],"eu":[1341504,27376],"sh":[1318016,27376]}], -"actors/chair/chair_bottom.rgba16.png": [32,16,1024,{"jp":[1462368,16480],"us":[1469536,16480],"eu":[1341504,16480],"sh":[1318016,16480]}], -"actors/chair/chair_front.rgba16.png": [32,32,2048,{"jp":[1462368,12384],"us":[1469536,12384],"eu":[1341504,12384],"sh":[1318016,12384]}], -"actors/chair/chair_leg.rgba16.png": [32,32,2048,{"jp":[1462368,14432],"us":[1469536,14432],"eu":[1341504,14432],"sh":[1318016,14432]}], -"actors/chair/chair_surface_unused.rgba16.png": [32,32,2048,{"jp":[1462368,17504],"us":[1469536,17504],"eu":[1341504,17504],"sh":[1318016,17504]}], -"actors/checkerboard_platform/checkerboard_platform.rgba16.png": [32,32,2048,{"jp":[2032944,52288],"us":[2040320,52288],"eu":[1912288,52288],"sh":[1888800,52288]}], -"actors/checkerboard_platform/checkerboard_platform_side.rgba16.png": [32,16,1024,{"jp":[2032944,51264],"us":[2040320,51264],"eu":[1912288,51264],"sh":[1888800,51264]}], -"actors/chillychief/chill_bully_eye.rgba16.png": [32,32,2048,{"jp":[1249376,9320],"us":[1256544,9320],"eu":[1128512,9320],"sh":[1105024,9320]}], -"actors/chillychief/chill_bully_left_side.rgba16.png": [32,64,4096,{"jp":[1979680,96],"us":[1987056,96],"eu":[1859024,96],"sh":[1835536,96]}], -"actors/chillychief/chill_bully_right_side.rgba16.png": [32,64,4096,{"jp":[1979680,4192],"us":[1987056,4192],"eu":[1859024,4192],"sh":[1835536,4192]}], -"actors/chuckya/chuckya_body_arm_left_side.rgba16.png": [32,64,4096,{"jp":[2032944,32632],"us":[2040320,32632],"eu":[1912288,32632],"sh":[1888800,32632]}], -"actors/chuckya/chuckya_body_arm_right_side.rgba16.png": [32,64,4096,{"jp":[2032944,36728],"us":[2040320,36728],"eu":[1912288,36728],"sh":[1888800,36728]}], -"actors/chuckya/chuckya_eyes.rgba16.png": [32,64,4096,{"jp":[2032944,26488],"us":[2040320,26488],"eu":[1912288,26488],"sh":[1888800,26488]}], -"actors/chuckya/chuckya_hand_antenna.rgba16.png": [32,32,2048,{"jp":[2032944,30584],"us":[2040320,30584],"eu":[1912288,30584],"sh":[1888800,30584]}], -"actors/clam_shell/clam_shell.rgba16.png": [32,32,2048,{"jp":[1285392,48],"us":[1292560,48],"eu":[1164528,48],"sh":[1141040,48]}], -"actors/clam_shell/clam_shell_mouth.rgba16.png": [32,32,2048,{"jp":[1285392,2096],"us":[1292560,2096],"eu":[1164528,2096],"sh":[1141040,2096]}], -"actors/coin/coin_front.ia16.png": [32,32,2048,{"jp":[2094912,22400],"us":[2102288,22400],"eu":[1974256,22400],"sh":[1950768,22400]}], -"actors/coin/coin_side.ia16.png": [32,32,2048,{"jp":[2094912,26496],"us":[2102288,26496],"eu":[1974256,26496],"sh":[1950768,26496]}], -"actors/coin/coin_tilt_left.ia16.png": [32,32,2048,{"jp":[2094912,28544],"us":[2102288,28544],"eu":[1974256,28544],"sh":[1950768,28544]}], -"actors/coin/coin_tilt_right.ia16.png": [32,32,2048,{"jp":[2094912,24448],"us":[2102288,24448],"eu":[1974256,24448],"sh":[1950768,24448]}], -"actors/cyan_fish/cyan_fish.rgba16.png": [32,32,2048,{"jp":[1802256,54376],"us":[1809600,54376],"eu":[1681568,54376],"sh":[1658080,54376]}], -"actors/dirt/dirt_particle.rgba16.png": [16,16,512,{"jp":[2094912,179704],"us":[2102288,179704],"eu":[1974256,179704],"sh":[1950768,179704]}], -"actors/door/bbh_door.rgba16.png": [32,64,4096,{"jp":[2094912,66832],"us":[2102288,66832],"eu":[1974256,66832],"sh":[1950768,66832]}], -"actors/door/bbh_door_overlay.rgba16.png": [32,32,2048,{"jp":[2094912,70928],"us":[2102288,70928],"eu":[1974256,70928],"sh":[1950768,70928]}], -"actors/door/door_lock.rgba16.png": [16,32,1024,{"jp":[2094912,79120],"us":[2102288,79120],"eu":[1974256,79120],"sh":[1950768,79120]}], -"actors/door/hmc_mural_door.rgba16.png": [32,64,4096,{"jp":[2094912,60688],"us":[2102288,60688],"eu":[1974256,60688],"sh":[1950768,60688]}], -"actors/door/hmc_mural_door_overlay.rgba16.png": [32,32,2048,{"jp":[2094912,64784],"us":[2102288,64784],"eu":[1974256,64784],"sh":[1950768,64784]}], -"actors/door/metal_door.rgba16.png": [32,64,4096,{"jp":[2094912,54544],"us":[2102288,54544],"eu":[1974256,54544],"sh":[1950768,54544]}], -"actors/door/metal_door_overlay.rgba16.png": [32,32,2048,{"jp":[2094912,58640],"us":[2102288,58640],"eu":[1974256,58640],"sh":[1950768,58640]}], -"actors/door/one_star_door_sign.rgba16.png": [32,32,2048,{"jp":[2094912,75024],"us":[2102288,75024],"eu":[1974256,75024],"sh":[1950768,75024]}], -"actors/door/polished_wooden_door.rgba16.png": [32,64,4096,{"jp":[2094912,40208],"us":[2102288,40208],"eu":[1974256,40208],"sh":[1950768,40208]}], -"actors/door/polished_wooden_door_overlay.rgba16.png": [32,64,4096,{"jp":[2094912,44304],"us":[2102288,44304],"eu":[1974256,44304],"sh":[1950768,44304]}], -"actors/door/rough_wooden_door.rgba16.png": [32,64,4096,{"jp":[2094912,48400],"us":[2102288,48400],"eu":[1974256,48400],"sh":[1950768,48400]}], -"actors/door/rough_wooden_door_overlay.rgba16.png": [32,32,2048,{"jp":[2094912,52496],"us":[2102288,52496],"eu":[1974256,52496],"sh":[1950768,52496]}], -"actors/door/three_star_door_sign.rgba16.png": [32,32,2048,{"jp":[2094912,77072],"us":[2102288,77072],"eu":[1974256,77072],"sh":[1950768,77072]}], -"actors/door/zero_star_door_sign.rgba16.png": [32,32,2048,{"jp":[2094912,72976],"us":[2102288,72976],"eu":[1974256,72976],"sh":[1950768,72976]}], -"actors/dorrie/dorrie_eye.rgba16.png": [16,16,512,{"jp":[1991184,39840],"us":[1998560,39840],"eu":[1870528,39840],"sh":[1847040,39840]}], -"actors/dorrie/dorrie_skin.rgba16.png": [32,64,4096,{"jp":[1991184,40352],"us":[1998560,40352],"eu":[1870528,40352],"sh":[1847040,40352]}], -"actors/dorrie/dorrie_tongue.rgba16.png": [32,32,2048,{"jp":[1844608,140240],"us":[1851952,140240],"eu":[1723920,140240],"sh":[1700432,140240]}], -"actors/exclamation_box/exclamation_box_front.rgba16.png": [32,32,2048,{"jp":[2032944,95784],"us":[2040320,95784],"eu":[1912288,95784],"sh":[1888800,95784]}], -"actors/exclamation_box/exclamation_box_side.rgba16.png": [64,32,4096,{"jp":[2032944,97832],"us":[2040320,97832],"eu":[1912288,97832],"sh":[1888800,97832]}], -"actors/exclamation_box/metal_cap_box_front.rgba16.png": [32,32,2048,{"jp":[2032944,83496],"us":[2040320,83496],"eu":[1912288,83496],"sh":[1888800,83496]}], -"actors/exclamation_box/metal_cap_box_side.rgba16.png": [64,32,4096,{"jp":[2032944,85544],"us":[2040320,85544],"eu":[1912288,85544],"sh":[1888800,85544]}], -"actors/exclamation_box/vanish_cap_box_front.rgba16.png": [32,32,2048,{"jp":[2032944,77352],"us":[2040320,77352],"eu":[1912288,77352],"sh":[1888800,77352]}], -"actors/exclamation_box/vanish_cap_box_side.rgba16.png": [32,64,4096,{"jp":[2032944,79400],"us":[2040320,79400],"eu":[1912288,79400],"sh":[1888800,79400]}], -"actors/exclamation_box/wing_cap_box_front.rgba16.png": [32,32,2048,{"jp":[2032944,89640],"us":[2040320,89640],"eu":[1912288,89640],"sh":[1888800,89640]}], -"actors/exclamation_box/wing_cap_box_side.rgba16.png": [32,64,4096,{"jp":[2032944,91688],"us":[2040320,91688],"eu":[1912288,91688],"sh":[1888800,91688]}], -"actors/exclamation_box_outline/exclamation_box_outline.rgba16.png": [32,32,2048,{"jp":[2032944,151912],"us":[2040320,151912],"eu":[1912288,151912],"sh":[1888800,151912]}], -"actors/exclamation_box_outline/exclamation_point.rgba16.png": [16,32,1024,{"jp":[2032944,154240],"us":[2040320,154240],"eu":[1912288,154240],"sh":[1888800,154240]}], -"actors/explosion/explosion_0.rgba16.png": [32,32,2048,{"jp":[2094912,2568],"us":[2102288,2568],"eu":[1974256,2568],"sh":[1950768,2568]}], -"actors/explosion/explosion_1.rgba16.png": [32,32,2048,{"jp":[2094912,4616],"us":[2102288,4616],"eu":[1974256,4616],"sh":[1950768,4616]}], -"actors/explosion/explosion_2.rgba16.png": [32,32,2048,{"jp":[2094912,6664],"us":[2102288,6664],"eu":[1974256,6664],"sh":[1950768,6664]}], -"actors/explosion/explosion_3.rgba16.png": [32,32,2048,{"jp":[2094912,8712],"us":[2102288,8712],"eu":[1974256,8712],"sh":[1950768,8712]}], -"actors/explosion/explosion_4.rgba16.png": [32,32,2048,{"jp":[2094912,10760],"us":[2102288,10760],"eu":[1974256,10760],"sh":[1950768,10760]}], -"actors/explosion/explosion_5.rgba16.png": [32,32,2048,{"jp":[2094912,12808],"us":[2102288,12808],"eu":[1974256,12808],"sh":[1950768,12808]}], -"actors/explosion/explosion_6.rgba16.png": [32,32,2048,{"jp":[2094912,14856],"us":[2102288,14856],"eu":[1974256,14856],"sh":[1950768,14856]}], -"actors/eyerok/eyerok_bricks.rgba16.png": [32,32,2048,{"jp":[1327760,36160],"us":[1334928,36160],"eu":[1206896,36160],"sh":[1183408,36160]}], -"actors/eyerok/eyerok_eye_closed.rgba16.png": [32,32,2048,{"jp":[1327760,44352],"us":[1334928,44352],"eu":[1206896,44352],"sh":[1183408,44352]}], -"actors/eyerok/eyerok_eye_mostly_closed.rgba16.png": [32,32,2048,{"jp":[1327760,42304],"us":[1334928,42304],"eu":[1206896,42304],"sh":[1183408,42304]}], -"actors/eyerok/eyerok_eye_mostly_open.rgba16.png": [32,32,2048,{"jp":[1327760,40256],"us":[1334928,40256],"eu":[1206896,40256],"sh":[1183408,40256]}], -"actors/eyerok/eyerok_eye_open.rgba16.png": [32,32,2048,{"jp":[1327760,38208],"us":[1334928,38208],"eu":[1206896,38208],"sh":[1183408,38208]}], -"actors/flame/flame_0.ia16.png": [32,32,2048,{"jp":[2094912,95008],"us":[2102288,95008],"eu":[1974256,95008],"sh":[1950768,95008]}], -"actors/flame/flame_1.ia16.png": [32,32,2048,{"jp":[2094912,97056],"us":[2102288,97056],"eu":[1974256,97056],"sh":[1950768,97056]}], -"actors/flame/flame_2.ia16.png": [32,32,2048,{"jp":[2094912,99104],"us":[2102288,99104],"eu":[1974256,99104],"sh":[1950768,99104]}], -"actors/flame/flame_3.ia16.png": [32,32,2048,{"jp":[2094912,101152],"us":[2102288,101152],"eu":[1974256,101152],"sh":[1950768,101152]}], -"actors/flame/flame_4.ia16.png": [32,32,2048,{"jp":[2094912,103200],"us":[2102288,103200],"eu":[1974256,103200],"sh":[1950768,103200]}], -"actors/flame/flame_5.ia16.png": [32,32,2048,{"jp":[2094912,105248],"us":[2102288,105248],"eu":[1974256,105248],"sh":[1950768,105248]}], -"actors/flame/flame_6.ia16.png": [32,32,2048,{"jp":[2094912,107296],"us":[2102288,107296],"eu":[1974256,107296],"sh":[1950768,107296]}], -"actors/flame/flame_7.ia16.png": [32,32,2048,{"jp":[2094912,109344],"us":[2102288,109344],"eu":[1974256,109344],"sh":[1950768,109344]}], -"actors/flyguy/flyguy_cloth_wrinkle.rgba16.png": [64,32,4096,{"jp":[2032944,57480],"us":[2040320,57480],"eu":[1912288,57480],"sh":[1888800,57480]}], -"actors/flyguy/flyguy_face.rgba16.png": [32,32,2048,{"jp":[2032944,61576],"us":[2040320,61576],"eu":[1912288,61576],"sh":[1888800,61576]}], -"actors/flyguy/flyguy_propeller.ia16.png": [32,32,2048,{"jp":[2032944,63624],"us":[2040320,63624],"eu":[1912288,63624],"sh":[1888800,63624]}], -"actors/fwoosh/fwoosh_face.ia16.png": [32,32,2048,{"jp":[1377744,88072],"us":[1384912,88072],"eu":[1256880,88072],"sh":[1233392,88072]}], -"actors/goomba/goomba_body.rgba16.png": [32,32,2048,{"jp":[2032944,103728],"us":[2040320,103728],"eu":[1912288,103728],"sh":[1888800,103728]}], -"actors/goomba/goomba_face.rgba16.png": [32,32,2048,{"jp":[2032944,105776],"us":[2040320,105776],"eu":[1912288,105776],"sh":[1888800,105776]}], -"actors/goomba/goomba_face_blink.rgba16.png": [32,32,2048,{"jp":[2032944,107824],"us":[2040320,107824],"eu":[1912288,107824],"sh":[1888800,107824]}], -"actors/haunted_cage/bbh_cage_bars.rgba16.png": [32,32,2048,{"jp":[1462368,55944],"us":[1469536,55944],"eu":[1341504,55944],"sh":[1318016,55944]}], -"actors/haunted_cage/bbh_cage_double_ornament.rgba16.png": [32,32,2048,{"jp":[1462368,51848],"us":[1469536,51848],"eu":[1341504,51848],"sh":[1318016,51848]}], -"actors/haunted_cage/bbh_cage_floor.rgba16.png": [32,32,2048,{"jp":[1462368,49800],"us":[1469536,49800],"eu":[1341504,49800],"sh":[1318016,49800]}], -"actors/haunted_cage/bbh_cage_garbage.rgba16.png": [32,32,2048,{"jp":[1462368,57992],"us":[1469536,57992],"eu":[1341504,57992],"sh":[1318016,57992]}], -"actors/haunted_cage/bbh_cage_ornament.rgba16.png": [32,16,1024,{"jp":[1462368,53896],"us":[1469536,53896],"eu":[1341504,53896],"sh":[1318016,53896]}], -"actors/haunted_cage/bbh_cage_wooden_base.rgba16.png": [32,16,1024,{"jp":[1462368,54920],"us":[1469536,54920],"eu":[1341504,54920],"sh":[1318016,54920]}], -"actors/heart/spinning_heart.rgba16.png": [32,32,2048,{"jp":[2032944,55264],"us":[2040320,55264],"eu":[1912288,55264],"sh":[1888800,55264]}], -"actors/heave_ho/heave-ho_arm_ornament.rgba16.png": [32,32,2048,{"jp":[1215456,68040],"us":[1222624,68040],"eu":[1094592,68040],"sh":[1071104,68040]}], -"actors/heave_ho/heave-ho_face.rgba16.png": [32,32,2048,{"jp":[1215456,59848],"us":[1222624,59848],"eu":[1094592,59848],"sh":[1071104,59848]}], -"actors/heave_ho/heave-ho_logo.rgba16.png": [64,32,4096,{"jp":[1215456,63944],"us":[1222624,63944],"eu":[1094592,63944],"sh":[1071104,63944]}], -"actors/heave_ho/heave-ho_platform.rgba16.png": [32,32,2048,{"jp":[1215456,61896],"us":[1222624,61896],"eu":[1094592,61896],"sh":[1071104,61896]}], -"actors/heave_ho/heave-ho_roller.rgba16.png": [16,16,512,{"jp":[1215456,70088],"us":[1222624,70088],"eu":[1094592,70088],"sh":[1071104,70088]}], -"actors/heave_ho/heave-ho_turnkey.rgba16.png": [32,32,2048,{"jp":[1215456,70600],"us":[1222624,70600],"eu":[1094592,70600],"sh":[1071104,70600]}], -"actors/hoot/hoot_eyes.rgba16.png": [32,32,2048,{"jp":[1215456,2592],"us":[1222624,2592],"eu":[1094592,2592],"sh":[1071104,2592]}], -"actors/hoot/hoot_wing.rgba16.png": [32,32,2048,{"jp":[1215456,7760],"us":[1222624,7760],"eu":[1094592,7760],"sh":[1071104,7760]}], -"actors/hoot/hoot_wing_tip.rgba16.png": [32,32,2048,{"jp":[1215456,9808],"us":[1222624,9808],"eu":[1094592,9808],"sh":[1071104,9808]}], -"actors/impact_ring/impact_ring_left_side.ia16.png": [32,64,4096,{"jp":[1599504,117328],"us":[1606720,117328],"eu":[1478688,117328],"sh":[1455200,117328]}], -"actors/impact_ring/impact_ring_right_side.ia16.png": [32,64,4096,{"jp":[1599504,121424],"us":[1606720,121424],"eu":[1478688,121424],"sh":[1455200,121424]}], -"actors/impact_smoke/impact_smoke_0.ia16.png": [64,64,8192,{"jp":[1599504,371240],"us":[1606720,371576],"eu":[1478688,371576],"sh":[1455200,371576]}], -"actors/impact_smoke/impact_smoke_1.ia16.png": [64,64,8192,{"jp":[1599504,379432],"us":[1606720,379768],"eu":[1478688,379768],"sh":[1455200,379768]}], -"actors/impact_smoke/impact_smoke_2.ia16.png": [64,64,8192,{"jp":[1599504,387624],"us":[1606720,387960],"eu":[1478688,387960],"sh":[1455200,387960]}], -"actors/impact_smoke/impact_smoke_3.ia16.png": [64,64,8192,{"jp":[1599504,395816],"us":[1606720,396152],"eu":[1478688,396152],"sh":[1455200,396152]}], -"actors/king_bobomb/bob-omb_buddy_body_unused.rgba16.png": [64,64,8192,{"jp":[1257760,25720],"us":[1264928,25720],"eu":[1136896,25720],"sh":[1113408,25720]}], -"actors/king_bobomb/bob-omb_buddy_left_side_unused.rgba16.png": [32,64,4096,{"jp":[1257760,120],"us":[1264928,120],"eu":[1136896,120],"sh":[1113408,120]}], -"actors/king_bobomb/bob-omb_buddy_right_side_unused.rgba16.png": [32,64,4096,{"jp":[1257760,4216],"us":[1264928,4216],"eu":[1136896,4216],"sh":[1113408,4216]}], -"actors/king_bobomb/king_bob-omb_arm.rgba16.png": [32,32,2048,{"jp":[1257760,8312],"us":[1264928,8312],"eu":[1136896,8312],"sh":[1113408,8312]}], -"actors/king_bobomb/king_bob-omb_body_unused.rgba16.png": [64,64,8192,{"jp":[1257760,10360],"us":[1264928,10360],"eu":[1136896,10360],"sh":[1113408,10360]}], -"actors/king_bobomb/king_bob-omb_crown_rim.rgba16.png": [32,16,1024,{"jp":[1257760,24696],"us":[1264928,24696],"eu":[1136896,24696],"sh":[1113408,24696]}], -"actors/king_bobomb/king_bob-omb_eyes.rgba16.png": [32,32,2048,{"jp":[1257760,18552],"us":[1264928,18552],"eu":[1136896,18552],"sh":[1113408,18552]}], -"actors/king_bobomb/king_bob-omb_eyes_blink.rgba16.png": [32,32,2048,{"jp":[1257760,20600],"us":[1264928,20600],"eu":[1136896,20600],"sh":[1113408,20600]}], -"actors/king_bobomb/king_bob-omb_hand.rgba16.png": [32,32,2048,{"jp":[1257760,22648],"us":[1264928,22648],"eu":[1136896,22648],"sh":[1113408,22648]}], -"actors/king_bobomb/king_bob-omb_left_side.rgba16.png": [32,64,4096,{"jp":[1257760,33912],"us":[1264928,33912],"eu":[1136896,33912],"sh":[1113408,33912]}], -"actors/king_bobomb/king_bob-omb_right_side.rgba16.png": [32,64,4096,{"jp":[1257760,38008],"us":[1264928,38008],"eu":[1136896,38008],"sh":[1113408,38008]}], -"actors/klepto/klepto_beak.rgba16.png": [32,64,4096,{"jp":[1327760,4104],"us":[1334928,4104],"eu":[1206896,4104],"sh":[1183408,4104]}], -"actors/klepto/klepto_chest_tuft.rgba16.png": [32,32,2048,{"jp":[1327760,8],"us":[1334928,8],"eu":[1206896,8],"sh":[1183408,8]}], -"actors/klepto/klepto_eye.rgba16.png": [32,32,2048,{"jp":[1327760,2056],"us":[1334928,2056],"eu":[1206896,2056],"sh":[1183408,2056]}], -"actors/klepto/klepto_wing.rgba16.png": [64,32,4096,{"jp":[1327760,8200],"us":[1334928,8200],"eu":[1206896,8200],"sh":[1183408,8200]}], -"actors/klepto/klepto_wing_flap.rgba16.png": [32,32,2048,{"jp":[1327760,12296],"us":[1334928,12296],"eu":[1206896,12296],"sh":[1183408,12296]}], -"actors/koopa/koopa_eye_border.rgba16.png": [32,32,2048,{"jp":[1844608,22088],"us":[1851952,22088],"eu":[1723920,22088],"sh":[1700432,22088]}], -"actors/koopa/koopa_eyes_closed.rgba16.png": [32,32,2048,{"jp":[1844608,20040],"us":[1851952,20040],"eu":[1723920,20040],"sh":[1700432,20040]}], -"actors/koopa/koopa_eyes_open.rgba16.png": [32,32,2048,{"jp":[1844608,17992],"us":[1851952,17992],"eu":[1723920,17992],"sh":[1700432,17992]}], -"actors/koopa/koopa_nostrils.rgba16.png": [64,32,4096,{"jp":[1844608,24136],"us":[1851952,24136],"eu":[1723920,24136],"sh":[1700432,24136]}], -"actors/koopa/koopa_shell_back.rgba16.png": [32,32,2048,{"jp":[1844608,11848],"us":[1851952,11848],"eu":[1723920,11848],"sh":[1700432,11848]}], -"actors/koopa/koopa_shell_front.rgba16.png": [32,32,2048,{"jp":[1844608,9800],"us":[1851952,9800],"eu":[1723920,9800],"sh":[1700432,9800]}], -"actors/koopa/koopa_shell_front_top.rgba16.png": [32,32,2048,{"jp":[1844608,15944],"us":[1851952,15944],"eu":[1723920,15944],"sh":[1700432,15944]}], -"actors/koopa/koopa_shoe.rgba16.png": [32,32,2048,{"jp":[1844608,13896],"us":[1851952,13896],"eu":[1723920,13896],"sh":[1700432,13896]}], -"actors/koopa_flag/koopa_flag_banner.rgba16.png": [32,32,2048,{"jp":[1844608,72],"us":[1851952,72],"eu":[1723920,72],"sh":[1700432,72]}], -"actors/koopa_shell/koopa_shell_back.rgba16.png": [32,32,2048,{"jp":[1844608,11848],"us":[1851952,11848],"eu":[1723920,11848],"sh":[1700432,11848]}], -"actors/koopa_shell/koopa_shell_front.rgba16.png": [32,32,2048,{"jp":[1844608,9800],"us":[1851952,9800],"eu":[1723920,9800],"sh":[1700432,9800]}], -"actors/lakitu_cameraman/lakitu_camera_lens.rgba16.png": [16,16,512,{"jp":[1926752,14336],"us":[1934096,14336],"eu":[1806064,14336],"sh":[1782576,14336]}], -"actors/lakitu_cameraman/lakitu_cameraman_cloud_face_unused.rgba16.png": [32,32,2048,{"jp":[1568640,60640],"us":[1575856,60640],"eu":[1447824,60640],"sh":[1424336,60640]}], -"actors/lakitu_cameraman/lakitu_cameraman_eyes_closed.rgba16.png": [64,32,4096,{"jp":[1568640,66784],"us":[1575856,66784],"eu":[1447824,66784],"sh":[1424336,66784]}], -"actors/lakitu_cameraman/lakitu_cameraman_eyes_open.rgba16.png": [64,32,4096,{"jp":[1568640,62688],"us":[1575856,62688],"eu":[1447824,62688],"sh":[1424336,62688]}], -"actors/lakitu_cameraman/lakitu_cameraman_frown.rgba16.png": [32,32,2048,{"jp":[1568640,72928],"us":[1575856,72928],"eu":[1447824,72928],"sh":[1424336,72928]}], -"actors/lakitu_cameraman/lakitu_cameraman_shell.rgba16.png": [32,32,2048,{"jp":[1568640,70880],"us":[1575856,70880],"eu":[1447824,70880],"sh":[1424336,70880]}], -"actors/lakitu_enemy/lakitu_enemy_cloud_face_unused.rgba16.png": [32,32,2048,{"jp":[1568640,60640],"us":[1575856,60640],"eu":[1447824,60640],"sh":[1424336,60640]}], -"actors/lakitu_enemy/lakitu_enemy_eyes_closed.rgba16.png": [64,32,4096,{"jp":[1568640,66784],"us":[1575856,66784],"eu":[1447824,66784],"sh":[1424336,66784]}], -"actors/lakitu_enemy/lakitu_enemy_eyes_open.rgba16.png": [64,32,4096,{"jp":[1568640,62688],"us":[1575856,62688],"eu":[1447824,62688],"sh":[1424336,62688]}], -"actors/lakitu_enemy/lakitu_enemy_frown.rgba16.png": [32,32,2048,{"jp":[1568640,72928],"us":[1575856,72928],"eu":[1447824,72928],"sh":[1424336,72928]}], -"actors/lakitu_enemy/lakitu_enemy_shell.rgba16.png": [32,32,2048,{"jp":[1568640,70880],"us":[1575856,70880],"eu":[1447824,70880],"sh":[1424336,70880]}], -"actors/leaves/leaf.rgba16.png": [16,16,512,{"jp":[2094912,117728],"us":[2102288,117728],"eu":[1974256,117728],"sh":[1950768,117728]}], -"actors/mad_piano/mad_piano_body.rgba16.png": [16,32,1024,{"jp":[1462368,29424],"us":[1469536,29424],"eu":[1341504,29424],"sh":[1318016,29424]}], -"actors/mad_piano/mad_piano_keys.rgba16.png": [32,16,1024,{"jp":[1462368,32496],"us":[1469536,32496],"eu":[1341504,32496],"sh":[1318016,32496]}], -"actors/mad_piano/mad_piano_keys_corner.rgba16.png": [32,16,1024,{"jp":[1462368,30448],"us":[1469536,30448],"eu":[1341504,30448],"sh":[1318016,30448]}], -"actors/mad_piano/mad_piano_keys_edge.rgba16.png": [32,16,1024,{"jp":[1462368,33520],"us":[1469536,33520],"eu":[1341504,33520],"sh":[1318016,33520]}], -"actors/mad_piano/mad_piano_mouth.rgba16.png": [16,32,1024,{"jp":[1462368,31472],"us":[1469536,31472],"eu":[1341504,31472],"sh":[1318016,31472]}], -"actors/mad_piano/mad_piano_tooth.rgba16.png": [32,32,2048,{"jp":[1462368,27376],"us":[1469536,27376],"eu":[1341504,27376],"sh":[1318016,27376]}], -"actors/manta/manta_eye.rgba16.png": [32,32,2048,{"jp":[1285392,12192],"us":[1292560,12192],"eu":[1164528,12192],"sh":[1141040,12192]}], -"actors/manta/manta_fin_corner.rgba16.png": [32,32,2048,{"jp":[1285392,6048],"us":[1292560,6048],"eu":[1164528,6048],"sh":[1141040,6048]}], -"actors/manta/manta_fin_edge.rgba16.png": [64,32,4096,{"jp":[1285392,14240],"us":[1292560,14240],"eu":[1164528,14240],"sh":[1141040,14240]}], -"actors/manta/manta_gills.rgba16.png": [32,64,4096,{"jp":[1285392,8096],"us":[1292560,8096],"eu":[1164528,8096],"sh":[1141040,8096]}], -"actors/mario/mario_eyes_center.rgba16.png": [32,32,2048,{"jp":[1125200,12432],"us":[1132368,12432],"eu":[1004336,12432],"sh":[980848,12432]}], -"actors/mario/mario_eyes_closed.rgba16.png": [32,32,2048,{"jp":[1125200,16528],"us":[1132368,16528],"eu":[1004336,16528],"sh":[980848,16528]}], -"actors/mario/mario_eyes_closed_unused_0.rgba16.png": [32,32,2048,{"jp":[1125200,16528],"us":[1132368,16528],"eu":[1004336,16528],"sh":[980848,16528]}], -"actors/mario/mario_eyes_closed_unused_1.rgba16.png": [32,32,2048,{"jp":[1125200,16528],"us":[1132368,16528],"eu":[1004336,16528],"sh":[980848,16528]}], -"actors/mario/mario_eyes_dead.rgba16.png": [32,32,2048,{"jp":[1125200,30864],"us":[1132368,30864],"eu":[1004336,30864],"sh":[980848,30864]}], -"actors/mario/mario_eyes_down_unused.rgba16.png": [32,32,2048,{"jp":[1125200,28816],"us":[1132368,28816],"eu":[1004336,28816],"sh":[980848,28816]}], -"actors/mario/mario_eyes_half_closed.rgba16.png": [32,32,2048,{"jp":[1125200,14480],"us":[1132368,14480],"eu":[1004336,14480],"sh":[980848,14480]}], -"actors/mario/mario_eyes_left_unused.rgba16.png": [32,32,2048,{"jp":[1125200,22672],"us":[1132368,22672],"eu":[1004336,22672],"sh":[980848,22672]}], -"actors/mario/mario_eyes_right_unused.rgba16.png": [32,32,2048,{"jp":[1125200,24720],"us":[1132368,24720],"eu":[1004336,24720],"sh":[980848,24720]}], -"actors/mario/mario_eyes_up_unused.rgba16.png": [32,32,2048,{"jp":[1125200,26768],"us":[1132368,26768],"eu":[1004336,26768],"sh":[980848,26768]}], -"actors/mario/mario_logo.rgba16.png": [32,32,2048,{"jp":[1125200,6288],"us":[1132368,6288],"eu":[1004336,6288],"sh":[980848,6288]}], -"actors/mario/mario_metal.rgba16.png": [64,32,4096,{"jp":[1125200,144],"us":[1132368,144],"eu":[1004336,144],"sh":[980848,144]}], -"actors/mario/mario_metal_wing_tip_unused.rgba16.png": [32,64,4096,{"jp":[1125200,45200],"us":[1132368,45200],"eu":[1004336,45200],"sh":[980848,45200]}], -"actors/mario/mario_metal_wing_unused.rgba16.png": [32,64,4096,{"jp":[1125200,41104],"us":[1132368,41104],"eu":[1004336,41104],"sh":[980848,41104]}], -"actors/mario/mario_mustache.rgba16.png": [32,32,2048,{"jp":[1125200,10384],"us":[1132368,10384],"eu":[1004336,10384],"sh":[980848,10384]}], -"actors/mario/mario_overalls_button.rgba16.png": [32,32,2048,{"jp":[1125200,4240],"us":[1132368,4240],"eu":[1004336,4240],"sh":[980848,4240]}], -"actors/mario/mario_sideburn.rgba16.png": [32,32,2048,{"jp":[1125200,8336],"us":[1132368,8336],"eu":[1004336,8336],"sh":[980848,8336]}], -"actors/mario/mario_wing.rgba16.png": [32,64,4096,{"jp":[1125200,32912],"us":[1132368,32912],"eu":[1004336,32912],"sh":[980848,32912]}], -"actors/mario/mario_wing_tip.rgba16.png": [32,64,4096,{"jp":[1125200,37008],"us":[1132368,37008],"eu":[1004336,37008],"sh":[980848,37008]}], -"actors/mario_cap/mario_cap_logo.rgba16.png": [32,32,2048,{"jp":[1125200,6288],"us":[1132368,6288],"eu":[1004336,6288],"sh":[980848,6288]}], -"actors/mario_cap/mario_cap_metal.rgba16.png": [64,32,4096,{"jp":[1125200,144],"us":[1132368,144],"eu":[1004336,144],"sh":[980848,144]}], -"actors/mario_cap/mario_cap_metal_wing_tip_unused.rgba16.png": [32,64,4096,{"jp":[1125200,45200],"us":[1132368,45200],"eu":[1004336,45200],"sh":[980848,45200]}], -"actors/mario_cap/mario_cap_metal_wing_unused.rgba16.png": [32,64,4096,{"jp":[1125200,41104],"us":[1132368,41104],"eu":[1004336,41104],"sh":[980848,41104]}], -"actors/mario_cap/mario_cap_wing.rgba16.png": [32,64,4096,{"jp":[1125200,32912],"us":[1132368,32912],"eu":[1004336,32912],"sh":[980848,32912]}], -"actors/mario_cap/mario_cap_wing_tip.rgba16.png": [32,64,4096,{"jp":[1125200,37008],"us":[1132368,37008],"eu":[1004336,37008],"sh":[980848,37008]}], -"actors/metal_box/metal_box_side.rgba16.png": [32,64,4096,{"jp":[2032944,145816],"us":[2040320,145816],"eu":[1912288,145816],"sh":[1888800,145816]}], -"actors/mips/mips_eyes.rgba16.png": [32,32,2048,{"jp":[1926752,64384],"us":[1934096,64624],"eu":[1806064,64624],"sh":[1782576,64624]}], -"actors/mist/mist.ia16.png": [32,32,2048,{"jp":[2094912,128],"us":[2102288,128],"eu":[1974256,128],"sh":[1950768,128]}], -"actors/moneybag/moneybag_eyes.rgba16.png": [32,32,2048,{"jp":[1979680,18864],"us":[1987056,18864],"eu":[1859024,18864],"sh":[1835536,18864]}], -"actors/moneybag/moneybag_mouth.rgba16.png": [64,32,4096,{"jp":[1979680,14768],"us":[1987056,14768],"eu":[1859024,14768],"sh":[1835536,14768]}], -"actors/monty_mole/monty_mole_cheek.rgba16.png": [32,32,2048,{"jp":[1377744,2416],"us":[1384912,2416],"eu":[1256880,2416],"sh":[1233392,2416]}], -"actors/monty_mole/monty_mole_claw.rgba16.png": [32,32,2048,{"jp":[1377744,10608],"us":[1384912,10608],"eu":[1256880,10608],"sh":[1233392,10608]}], -"actors/monty_mole/monty_mole_eye.rgba16.png": [32,32,2048,{"jp":[1377744,4464],"us":[1384912,4464],"eu":[1256880,4464],"sh":[1233392,4464]}], -"actors/monty_mole/monty_mole_nose.rgba16.png": [32,32,2048,{"jp":[1377744,6512],"us":[1384912,6512],"eu":[1256880,6512],"sh":[1233392,6512]}], -"actors/monty_mole/monty_mole_tooth.rgba16.png": [32,32,2048,{"jp":[1377744,8560],"us":[1384912,8560],"eu":[1256880,8560],"sh":[1233392,8560]}], -"actors/monty_mole_hole/monty_mole_hole.ia16.png": [32,32,2048,{"jp":[1377744,64],"us":[1384912,64],"eu":[1256880,64],"sh":[1233392,64]}], -"actors/mr_i_eyeball/mr_i_eyeball_left_side.rgba16.png": [32,64,4096,{"jp":[1991184,128],"us":[1998560,128],"eu":[1870528,128],"sh":[1847040,128]}], -"actors/mr_i_eyeball/mr_i_eyeball_right_side.rgba16.png": [32,64,4096,{"jp":[1991184,4224],"us":[1998560,4224],"eu":[1870528,4224],"sh":[1847040,4224]}], -"actors/mr_i_iris/mr_i_iris_closed.rgba16.png": [32,32,2048,{"jp":[1991184,14704],"us":[1998560,14704],"eu":[1870528,14704],"sh":[1847040,14704]}], -"actors/mr_i_iris/mr_i_iris_mostly_closed.rgba16.png": [32,32,2048,{"jp":[1991184,12656],"us":[1998560,12656],"eu":[1870528,12656],"sh":[1847040,12656]}], -"actors/mr_i_iris/mr_i_iris_mostly_open.rgba16.png": [32,32,2048,{"jp":[1991184,10608],"us":[1998560,10608],"eu":[1870528,10608],"sh":[1847040,10608]}], -"actors/mr_i_iris/mr_i_iris_open.rgba16.png": [32,32,2048,{"jp":[1991184,8560],"us":[1998560,8560],"eu":[1870528,8560],"sh":[1847040,8560]}], -"actors/mushroom_1up/1-up_mushroom.rgba16.png": [32,64,4096,{"jp":[2094912,169512],"us":[2102288,169512],"eu":[1974256,169512],"sh":[1950768,169512]}], -"actors/peach/peach_chest_jewel.rgba16.png": [16,16,512,{"jp":[1490032,11304],"us":[1497200,11304],"eu":[1369168,11304],"sh":[1345680,11304]}], -"actors/peach/peach_crown_jewel.rgba16.png": [16,16,512,{"jp":[1490032,10792],"us":[1497200,10792],"eu":[1369168,10792],"sh":[1345680,10792]}], -"actors/peach/peach_dress.rgba16.png": [32,32,2048,{"jp":[1490032,16424],"us":[1497200,16424],"eu":[1369168,16424],"sh":[1345680,16424]}], -"actors/peach/peach_eye_closed.rgba16.png": [32,32,2048,{"jp":[1490032,8744],"us":[1497200,8744],"eu":[1369168,8744],"sh":[1345680,8744]}], -"actors/peach/peach_eye_mostly_closed.rgba16.png": [32,32,2048,{"jp":[1490032,6696],"us":[1497200,6696],"eu":[1369168,6696],"sh":[1345680,6696]}], -"actors/peach/peach_eye_mostly_open.rgba16.png": [32,32,2048,{"jp":[1490032,4648],"us":[1497200,4648],"eu":[1369168,4648],"sh":[1345680,4648]}], -"actors/peach/peach_eye_open.rgba16.png": [32,32,2048,{"jp":[1490032,2600],"us":[1497200,2600],"eu":[1369168,2600],"sh":[1345680,2600]}], -"actors/peach/peach_lips.rgba16.png": [32,32,2048,{"jp":[1490032,13864],"us":[1497200,13864],"eu":[1369168,13864],"sh":[1345680,13864]}], -"actors/peach/peach_lips_scrunched.rgba16.png": [32,32,2048,{"jp":[1490032,11816],"us":[1497200,11816],"eu":[1369168,11816],"sh":[1345680,11816]}], -"actors/peach/peach_nostril.rgba16.png": [16,16,512,{"jp":[1490032,15912],"us":[1497200,15912],"eu":[1369168,15912],"sh":[1345680,15912]}], -"actors/pebble/pebble.rgba16.png": [32,32,2048,{"jp":[2094912,115456],"us":[2102288,115456],"eu":[1974256,115456],"sh":[1950768,115456]}], -"actors/penguin/penguin_beak.rgba16.png": [32,32,2048,{"jp":[1436272,21984],"us":[1443440,21984],"eu":[1315408,21984],"sh":[1291920,21984]}], -"actors/penguin/penguin_eye_angry.rgba16.png": [32,32,2048,{"jp":[1436272,17888],"us":[1443440,17888],"eu":[1315408,17888],"sh":[1291920,17888]}], -"actors/penguin/penguin_eye_angry_unused.rgba16.png": [32,32,2048,{"jp":[1436272,19936],"us":[1443440,19936],"eu":[1315408,19936],"sh":[1291920,19936]}], -"actors/penguin/penguin_eye_closed.rgba16.png": [32,32,2048,{"jp":[1436272,15840],"us":[1443440,15840],"eu":[1315408,15840],"sh":[1291920,15840]}], -"actors/penguin/penguin_eye_half_closed.rgba16.png": [32,32,2048,{"jp":[1436272,13792],"us":[1443440,13792],"eu":[1315408,13792],"sh":[1291920,13792]}], -"actors/penguin/penguin_eye_open.rgba16.png": [32,32,2048,{"jp":[1436272,11744],"us":[1443440,11744],"eu":[1315408,11744],"sh":[1291920,11744]}], -"actors/piranha_plant/piranha_plant_bottom_lip.rgba16.png": [32,32,2048,{"jp":[1844608,78840],"us":[1851952,78840],"eu":[1723920,78840],"sh":[1700432,78840]}], -"actors/piranha_plant/piranha_plant_leaf.rgba16.png": [32,64,4096,{"jp":[1844608,82936],"us":[1851952,82936],"eu":[1723920,82936],"sh":[1700432,82936]}], -"actors/piranha_plant/piranha_plant_skin.rgba16.png": [32,32,2048,{"jp":[1844608,74744],"us":[1851952,74744],"eu":[1723920,74744],"sh":[1700432,74744]}], -"actors/piranha_plant/piranha_plant_stem.rgba16.png": [32,32,2048,{"jp":[1844608,76792],"us":[1851952,76792],"eu":[1723920,76792],"sh":[1700432,76792]}], -"actors/piranha_plant/piranha_plant_tongue.rgba16.png": [32,64,4096,{"jp":[1599504,148536],"us":[1606720,148536],"eu":[1478688,148536],"sh":[1455200,148536]}], -"actors/piranha_plant/piranha_plant_tooth.rgba16.png": [32,32,2048,{"jp":[1844608,80888],"us":[1851952,80888],"eu":[1723920,80888],"sh":[1700432,80888]}], -"actors/pokey/pokey_body.rgba16.png": [32,32,2048,{"jp":[1327760,75896],"us":[1334928,75896],"eu":[1206896,75896],"sh":[1183408,75896]}], -"actors/pokey/pokey_face.rgba16.png": [32,32,2048,{"jp":[1327760,71504],"us":[1334928,71504],"eu":[1206896,71504],"sh":[1183408,71504]}], -"actors/pokey/pokey_face_blink.rgba16.png": [32,32,2048,{"jp":[1327760,73552],"us":[1334928,73552],"eu":[1206896,73552],"sh":[1183408,73552]}], -"actors/poundable_pole/poundable_pole_side.rgba16.png": [32,32,2048,{"jp":[1844608,6224],"us":[1851952,6224],"eu":[1723920,6224],"sh":[1700432,6224]}], -"actors/poundable_pole/poundable_pole_top.rgba16.png": [32,32,2048,{"jp":[1844608,4176],"us":[1851952,4176],"eu":[1723920,4176],"sh":[1700432,4176]}], -"actors/power_meter/power_meter_five_segments.rgba16.png": [32,32,2048,{"jp":[2094912,158688],"us":[2102288,158688],"eu":[1974256,158688],"sh":[1950768,158688]}], -"actors/power_meter/power_meter_four_segments.rgba16.png": [32,32,2048,{"jp":[2094912,160736],"us":[2102288,160736],"eu":[1974256,160736],"sh":[1950768,160736]}], -"actors/power_meter/power_meter_full.rgba16.png": [32,32,2048,{"jp":[2094912,152544],"us":[2102288,152544],"eu":[1974256,152544],"sh":[1950768,152544]}], +"@sound tbl sh": [2184688,{"sh":[5685952],"cn":[5758976]}], +"@sound ctl header sh": [624,{"sh":[864272],"cn":[876656]}], +"@sound tbl header sh": [192,{"sh":[865056],"cn":[877440]}], +"textures/ipl3_raw/ipl3_font_00.ia1.png": [13,14,23,{"jp":[2928],"us":[2928],"eu":[2928],"sh":[2928],"cn":[2928]}], +"textures/ipl3_raw/ipl3_font_01.ia1.png": [13,14,23,{"jp":[2951],"us":[2951],"eu":[2951],"sh":[2951],"cn":[2951]}], +"textures/ipl3_raw/ipl3_font_02.ia1.png": [13,14,23,{"jp":[2974],"us":[2974],"eu":[2974],"sh":[2974],"cn":[2974]}], +"textures/ipl3_raw/ipl3_font_03.ia1.png": [13,14,23,{"jp":[2997],"us":[2997],"eu":[2997],"sh":[2997],"cn":[2997]}], +"textures/ipl3_raw/ipl3_font_04.ia1.png": [13,14,23,{"jp":[3020],"us":[3020],"eu":[3020],"sh":[3020],"cn":[3020]}], +"textures/ipl3_raw/ipl3_font_05.ia1.png": [13,14,23,{"jp":[3043],"us":[3043],"eu":[3043],"sh":[3043],"cn":[3043]}], +"textures/ipl3_raw/ipl3_font_06.ia1.png": [13,14,23,{"jp":[3066],"us":[3066],"eu":[3066],"sh":[3066],"cn":[3066]}], +"textures/ipl3_raw/ipl3_font_07.ia1.png": [13,14,23,{"jp":[3089],"us":[3089],"eu":[3089],"sh":[3089],"cn":[3089]}], +"textures/ipl3_raw/ipl3_font_08.ia1.png": [13,14,23,{"jp":[3112],"us":[3112],"eu":[3112],"sh":[3112],"cn":[3112]}], +"textures/ipl3_raw/ipl3_font_09.ia1.png": [13,14,23,{"jp":[3135],"us":[3135],"eu":[3135],"sh":[3135],"cn":[3135]}], +"textures/ipl3_raw/ipl3_font_10.ia1.png": [13,14,23,{"jp":[3158],"us":[3158],"eu":[3158],"sh":[3158],"cn":[3158]}], +"textures/ipl3_raw/ipl3_font_11.ia1.png": [13,14,23,{"jp":[3181],"us":[3181],"eu":[3181],"sh":[3181],"cn":[3181]}], +"textures/ipl3_raw/ipl3_font_12.ia1.png": [13,14,23,{"jp":[3204],"us":[3204],"eu":[3204],"sh":[3204],"cn":[3204]}], +"textures/ipl3_raw/ipl3_font_13.ia1.png": [13,14,23,{"jp":[3227],"us":[3227],"eu":[3227],"sh":[3227],"cn":[3227]}], +"textures/ipl3_raw/ipl3_font_14.ia1.png": [13,14,23,{"jp":[3250],"us":[3250],"eu":[3250],"sh":[3250],"cn":[3250]}], +"textures/ipl3_raw/ipl3_font_15.ia1.png": [13,14,23,{"jp":[3273],"us":[3273],"eu":[3273],"sh":[3273],"cn":[3273]}], +"textures/ipl3_raw/ipl3_font_16.ia1.png": [13,14,23,{"jp":[3296],"us":[3296],"eu":[3296],"sh":[3296],"cn":[3296]}], +"textures/ipl3_raw/ipl3_font_17.ia1.png": [13,14,23,{"jp":[3319],"us":[3319],"eu":[3319],"sh":[3319],"cn":[3319]}], +"textures/ipl3_raw/ipl3_font_18.ia1.png": [13,14,23,{"jp":[3342],"us":[3342],"eu":[3342],"sh":[3342],"cn":[3342]}], +"textures/ipl3_raw/ipl3_font_19.ia1.png": [13,14,23,{"jp":[3365],"us":[3365],"eu":[3365],"sh":[3365],"cn":[3365]}], +"textures/ipl3_raw/ipl3_font_20.ia1.png": [13,14,23,{"jp":[3388],"us":[3388],"eu":[3388],"sh":[3388],"cn":[3388]}], +"textures/ipl3_raw/ipl3_font_21.ia1.png": [13,14,23,{"jp":[3411],"us":[3411],"eu":[3411],"sh":[3411],"cn":[3411]}], +"textures/ipl3_raw/ipl3_font_22.ia1.png": [13,14,23,{"jp":[3434],"us":[3434],"eu":[3434],"sh":[3434],"cn":[3434]}], +"textures/ipl3_raw/ipl3_font_23.ia1.png": [13,14,23,{"jp":[3457],"us":[3457],"eu":[3457],"sh":[3457],"cn":[3457]}], +"textures/ipl3_raw/ipl3_font_24.ia1.png": [13,14,23,{"jp":[3480],"us":[3480],"eu":[3480],"sh":[3480],"cn":[3480]}], +"textures/ipl3_raw/ipl3_font_25.ia1.png": [13,14,23,{"jp":[3503],"us":[3503],"eu":[3503],"sh":[3503],"cn":[3503]}], +"textures/ipl3_raw/ipl3_font_26.ia1.png": [13,14,23,{"jp":[3526],"us":[3526],"eu":[3526],"sh":[3526],"cn":[3526]}], +"textures/ipl3_raw/ipl3_font_27.ia1.png": [13,14,23,{"jp":[3549],"us":[3549],"eu":[3549],"sh":[3549],"cn":[3549]}], +"textures/ipl3_raw/ipl3_font_28.ia1.png": [13,14,23,{"jp":[3572],"us":[3572],"eu":[3572],"sh":[3572],"cn":[3572]}], +"textures/ipl3_raw/ipl3_font_29.ia1.png": [13,14,23,{"jp":[3595],"us":[3595],"eu":[3595],"sh":[3595],"cn":[3595]}], +"textures/ipl3_raw/ipl3_font_30.ia1.png": [13,14,23,{"jp":[3618],"us":[3618],"eu":[3618],"sh":[3618],"cn":[3618]}], +"textures/ipl3_raw/ipl3_font_31.ia1.png": [13,14,23,{"jp":[3641],"us":[3641],"eu":[3641],"sh":[3641],"cn":[3641]}], +"textures/ipl3_raw/ipl3_font_32.ia1.png": [13,14,23,{"jp":[3664],"us":[3664],"eu":[3664],"sh":[3664],"cn":[3664]}], +"textures/ipl3_raw/ipl3_font_33.ia1.png": [13,14,23,{"jp":[3687],"us":[3687],"eu":[3687],"sh":[3687],"cn":[3687]}], +"textures/ipl3_raw/ipl3_font_34.ia1.png": [13,14,23,{"jp":[3710],"us":[3710],"eu":[3710],"sh":[3710],"cn":[3710]}], +"textures/ipl3_raw/ipl3_font_35.ia1.png": [13,14,23,{"jp":[3733],"us":[3733],"eu":[3733],"sh":[3733],"cn":[3733]}], +"textures/ipl3_raw/ipl3_font_36.ia1.png": [13,14,23,{"jp":[3756],"us":[3756],"eu":[3756],"sh":[3756],"cn":[3756]}], +"textures/ipl3_raw/ipl3_font_37.ia1.png": [13,14,23,{"jp":[3779],"us":[3779],"eu":[3779],"sh":[3779],"cn":[3779]}], +"textures/ipl3_raw/ipl3_font_38.ia1.png": [13,14,23,{"jp":[3802],"us":[3802],"eu":[3802],"sh":[3802],"cn":[3802]}], +"textures/ipl3_raw/ipl3_font_39.ia1.png": [13,14,23,{"jp":[3825],"us":[3825],"eu":[3825],"sh":[3825],"cn":[3825]}], +"textures/ipl3_raw/ipl3_font_40.ia1.png": [13,14,23,{"jp":[3848],"us":[3848],"eu":[3848],"sh":[3848],"cn":[3848]}], +"textures/ipl3_raw/ipl3_font_41.ia1.png": [13,14,23,{"jp":[3871],"us":[3871],"eu":[3871],"sh":[3871],"cn":[3871]}], +"textures/ipl3_raw/ipl3_font_42.ia1.png": [13,14,23,{"jp":[3894],"us":[3894],"eu":[3894],"sh":[3894],"cn":[3894]}], +"textures/ipl3_raw/ipl3_font_43.ia1.png": [13,14,23,{"jp":[3917],"us":[3917],"eu":[3917],"sh":[3917],"cn":[3917]}], +"textures/ipl3_raw/ipl3_font_44.ia1.png": [13,14,23,{"jp":[3940],"us":[3940],"eu":[3940],"sh":[3940],"cn":[3940]}], +"textures/ipl3_raw/ipl3_font_45.ia1.png": [13,14,23,{"jp":[3963],"us":[3963],"eu":[3963],"sh":[3963],"cn":[3963]}], +"textures/ipl3_raw/ipl3_font_46.ia1.png": [13,14,23,{"jp":[3986],"us":[3986],"eu":[3986],"sh":[3986],"cn":[3986]}], +"textures/ipl3_raw/ipl3_font_47.ia1.png": [13,14,23,{"jp":[4009],"us":[4009],"eu":[4009],"sh":[4009],"cn":[4009]}], +"textures/ipl3_raw/ipl3_font_48.ia1.png": [13,14,23,{"jp":[4032],"us":[4032],"eu":[4032],"sh":[4032],"cn":[4032]}], +"textures/ipl3_raw/ipl3_font_49.ia1.png": [13,14,23,{"jp":[4055],"us":[4055],"eu":[4055],"sh":[4055],"cn":[4055]}], +"textures/crash_screen/crash_screen_font.ia1.png": [32,63,252,{"eu":[757168],"sh":[805680],"cn":[815248]}], +"actors/amp/amp_body.rgba16.png": [32,32,2048,{"jp":[2032944,6936],"us":[2040320,6936],"eu":[1912288,6936],"sh":[1888800,6936],"cn":[1955632,6936]}], +"actors/amp/amp_electricity.rgba16.png": [16,32,1024,{"jp":[2032944,3864],"us":[2040320,3864],"eu":[1912288,3864],"sh":[1888800,3864],"cn":[1955632,3864]}], +"actors/amp/amp_eyes.rgba16.png": [32,32,2048,{"jp":[2032944,4888],"us":[2040320,4888],"eu":[1912288,4888],"sh":[1888800,4888],"cn":[1955632,4888]}], +"actors/amp/amp_mouth.rgba16.png": [32,32,2048,{"jp":[2032944,8984],"us":[2040320,8984],"eu":[1912288,8984],"sh":[1888800,8984],"cn":[1955632,8984]}], +"actors/blue_coin_switch/blue_coin_switch_side.rgba16.png": [32,16,1024,{"jp":[2032944,24],"us":[2040320,24],"eu":[1912288,24],"sh":[1888800,24],"cn":[1955632,24]}], +"actors/blue_coin_switch/blue_coin_switch_top.rgba16.png": [32,32,2048,{"jp":[2032944,1048],"us":[2040320,1048],"eu":[1912288,1048],"sh":[1888800,1048],"cn":[1955632,1048]}], +"actors/blue_fish/blue_fish.rgba16.png": [32,32,2048,{"jp":[2094912,112096],"us":[2102288,112096],"eu":[1974256,112096],"sh":[1950768,112096],"cn":[2017600,112096]}], +"actors/bobomb/bob-omb_buddy_left_side.rgba16.png": [32,64,4096,{"jp":[1257760,120],"us":[1264928,120],"eu":[1136896,120],"sh":[1113408,120],"cn":[1180240,120]}], +"actors/bobomb/bob-omb_buddy_right_side.rgba16.png": [32,64,4096,{"jp":[1257760,4216],"us":[1264928,4216],"eu":[1136896,4216],"sh":[1113408,4216],"cn":[1180240,4216]}], +"actors/bobomb/bob-omb_eyes.rgba16.png": [32,32,2048,{"jp":[1257760,18552],"us":[1264928,18552],"eu":[1136896,18552],"sh":[1113408,18552],"cn":[1180240,18552]}], +"actors/bobomb/bob-omb_eyes_blink.rgba16.png": [32,32,2048,{"jp":[1257760,20600],"us":[1264928,20600],"eu":[1136896,20600],"sh":[1113408,20600],"cn":[1180240,20600]}], +"actors/bobomb/bob-omb_left_side.rgba16.png": [32,64,4096,{"jp":[2032944,121440],"us":[2040320,121440],"eu":[1912288,121440],"sh":[1888800,121440],"cn":[1955632,121440]}], +"actors/bobomb/bob-omb_right_side.rgba16.png": [32,64,4096,{"jp":[2032944,125536],"us":[2040320,125536],"eu":[1912288,125536],"sh":[1888800,125536],"cn":[1955632,125536]}], +"actors/bomb/bomb_left_side.rgba16.png": [32,64,4096,{"jp":[1599504,359104],"us":[1606720,359440],"eu":[1478688,359440],"sh":[1455200,359440],"cn":[1522032,359440]}], +"actors/bomb/bomb_right_side.rgba16.png": [32,64,4096,{"jp":[1599504,363200],"us":[1606720,363536],"eu":[1478688,363536],"sh":[1455200,363536],"cn":[1522032,363536]}], +"actors/bomb/bomb_spike.rgba16.png": [32,32,2048,{"jp":[1599504,367296],"us":[1606720,367632],"eu":[1478688,367632],"sh":[1455200,367632],"cn":[1522032,367632]}], +"actors/boo/boo_eyes.rgba16.png": [64,32,4096,{"jp":[1462368,39744],"us":[1469536,39744],"eu":[1341504,39744],"sh":[1318016,39744],"cn":[1384848,39744]}], +"actors/boo/boo_mouth.rgba16.png": [32,32,2048,{"jp":[1462368,43840],"us":[1469536,43840],"eu":[1341504,43840],"sh":[1318016,43840],"cn":[1384848,43840]}], +"actors/boo_castle/bbh_boo_eyes.rgba16.png": [64,32,4096,{"jp":[1462368,39744],"us":[1469536,39744],"eu":[1341504,39744],"sh":[1318016,39744],"cn":[1384848,39744]}], +"actors/boo_castle/bbh_boo_mouth.rgba16.png": [32,32,2048,{"jp":[1462368,43840],"us":[1469536,43840],"eu":[1341504,43840],"sh":[1318016,43840],"cn":[1384848,43840]}], +"actors/book/book_cover.rgba16.png": [32,32,2048,{"jp":[1462368,4192],"us":[1469536,4192],"eu":[1341504,4192],"sh":[1318016,4192],"cn":[1384848,4192]}], +"actors/bookend/bookend_cover.rgba16.png": [32,32,2048,{"jp":[1462368,4192],"us":[1469536,4192],"eu":[1341504,4192],"sh":[1318016,4192],"cn":[1384848,4192]}], +"actors/bookend/bookend_mouth.rgba16.png": [16,32,1024,{"jp":[1462368,2144],"us":[1469536,2144],"eu":[1341504,2144],"sh":[1318016,2144],"cn":[1384848,2144]}], +"actors/bookend/bookend_pages.rgba16.png": [16,32,1024,{"jp":[1462368,3168],"us":[1469536,3168],"eu":[1341504,3168],"sh":[1318016,3168],"cn":[1384848,3168]}], +"actors/bookend/bookend_spine.rgba16.png": [16,32,1024,{"jp":[1462368,96],"us":[1469536,96],"eu":[1341504,96],"sh":[1318016,96],"cn":[1384848,96]}], +"actors/bookend/bookend_tooth.rgba16.png": [16,32,1024,{"jp":[1462368,1120],"us":[1469536,1120],"eu":[1341504,1120],"sh":[1318016,1120],"cn":[1384848,1120]}], +"actors/bowser/bowser_armband.rgba16.png": [32,32,2048,{"jp":[1599504,146488],"us":[1606720,146488],"eu":[1478688,146488],"sh":[1455200,146488],"cn":[1522032,146488]}], +"actors/bowser/bowser_armband_spike.rgba16.png": [64,32,4096,{"jp":[1599504,142392],"us":[1606720,142392],"eu":[1478688,142392],"sh":[1455200,142392],"cn":[1522032,142392]}], +"actors/bowser/bowser_blue_eye_unused.rgba16.png": [64,32,4096,{"jp":[1599504,156728],"us":[1606720,156728],"eu":[1478688,156728],"sh":[1455200,156728],"cn":[1522032,156728]}], +"actors/bowser/bowser_body.rgba16.png": [32,32,2048,{"jp":[1599504,140344],"us":[1606720,140344],"eu":[1478688,140344],"sh":[1455200,140344],"cn":[1522032,140344]}], +"actors/bowser/bowser_chest.rgba16.png": [32,32,2048,{"jp":[1599504,152632],"us":[1606720,152632],"eu":[1478688,152632],"sh":[1455200,152632],"cn":[1522032,152632]}], +"actors/bowser/bowser_claw_edge.rgba16.png": [32,64,4096,{"jp":[1599504,171064],"us":[1606720,171064],"eu":[1478688,171064],"sh":[1455200,171064],"cn":[1522032,171064]}], +"actors/bowser/bowser_claw_horn_angle.rgba16.png": [32,64,4096,{"jp":[1599504,179256],"us":[1606720,179256],"eu":[1478688,179256],"sh":[1455200,179256],"cn":[1522032,179256]}], +"actors/bowser/bowser_claw_horn_tooth.rgba16.png": [32,64,4096,{"jp":[1599504,175160],"us":[1606720,175160],"eu":[1478688,175160],"sh":[1455200,175160],"cn":[1522032,175160]}], +"actors/bowser/bowser_eye_center_0.rgba16.png": [64,32,4096,{"jp":[1599504,195640],"us":[1606720,195640],"eu":[1478688,195640],"sh":[1455200,195640],"cn":[1522032,195640]}], +"actors/bowser/bowser_eye_center_1.rgba16.png": [64,32,4096,{"jp":[1599504,195640],"us":[1606720,195640],"eu":[1478688,195640],"sh":[1455200,195640],"cn":[1522032,195640]}], +"actors/bowser/bowser_eye_closed_0.rgba16.png": [64,32,4096,{"jp":[1599504,191544],"us":[1606720,191544],"eu":[1478688,191544],"sh":[1455200,191544],"cn":[1522032,191544]}], +"actors/bowser/bowser_eye_closed_1.rgba16.png": [64,32,4096,{"jp":[1599504,191544],"us":[1606720,191544],"eu":[1478688,191544],"sh":[1455200,191544],"cn":[1522032,191544]}], +"actors/bowser/bowser_eye_far_left_0.rgba16.png": [64,32,4096,{"jp":[1599504,203832],"us":[1606720,203832],"eu":[1478688,203832],"sh":[1455200,203832],"cn":[1522032,203832]}], +"actors/bowser/bowser_eye_far_left_1.rgba16.png": [64,32,4096,{"jp":[1599504,203832],"us":[1606720,203832],"eu":[1478688,203832],"sh":[1455200,203832],"cn":[1522032,203832]}], +"actors/bowser/bowser_eye_half_closed_0.rgba16.png": [64,32,4096,{"jp":[1599504,187448],"us":[1606720,187448],"eu":[1478688,187448],"sh":[1455200,187448],"cn":[1522032,187448]}], +"actors/bowser/bowser_eye_half_closed_1.rgba16.png": [64,32,4096,{"jp":[1599504,187448],"us":[1606720,187448],"eu":[1478688,187448],"sh":[1455200,187448],"cn":[1522032,187448]}], +"actors/bowser/bowser_eye_left_0.rgba16.png": [64,32,4096,{"jp":[1599504,183352],"us":[1606720,183352],"eu":[1478688,183352],"sh":[1455200,183352],"cn":[1522032,183352]}], +"actors/bowser/bowser_eye_left_1.rgba16.png": [64,32,4096,{"jp":[1599504,183352],"us":[1606720,183352],"eu":[1478688,183352],"sh":[1455200,183352],"cn":[1522032,183352]}], +"actors/bowser/bowser_eye_right_0.rgba16.png": [64,32,4096,{"jp":[1599504,199736],"us":[1606720,199736],"eu":[1478688,199736],"sh":[1455200,199736],"cn":[1522032,199736]}], +"actors/bowser/bowser_eye_right_1.rgba16.png": [64,32,4096,{"jp":[1599504,199736],"us":[1606720,199736],"eu":[1478688,199736],"sh":[1455200,199736],"cn":[1522032,199736]}], +"actors/bowser/bowser_eyebrow.rgba16.png": [64,32,4096,{"jp":[1599504,130104],"us":[1606720,130104],"eu":[1478688,130104],"sh":[1455200,130104],"cn":[1522032,130104]}], +"actors/bowser/bowser_hair.rgba16.png": [32,64,4096,{"jp":[1599504,166968],"us":[1606720,166968],"eu":[1478688,166968],"sh":[1455200,166968],"cn":[1522032,166968]}], +"actors/bowser/bowser_mouth_unused.rgba16.png": [64,32,4096,{"jp":[1599504,160824],"us":[1606720,160824],"eu":[1478688,160824],"sh":[1455200,160824],"cn":[1522032,160824]}], +"actors/bowser/bowser_muzzle.rgba16.png": [32,32,2048,{"jp":[1599504,134200],"us":[1606720,134200],"eu":[1478688,134200],"sh":[1455200,134200],"cn":[1522032,134200]}], +"actors/bowser/bowser_nostrils.rgba16.png": [64,32,4096,{"jp":[1599504,136248],"us":[1606720,136248],"eu":[1478688,136248],"sh":[1455200,136248],"cn":[1522032,136248]}], +"actors/bowser/bowser_shell.rgba16.png": [32,32,2048,{"jp":[1599504,128056],"us":[1606720,128056],"eu":[1478688,128056],"sh":[1455200,128056],"cn":[1522032,128056]}], +"actors/bowser/bowser_shell_edge.rgba16.png": [32,32,2048,{"jp":[1599504,154680],"us":[1606720,154680],"eu":[1478688,154680],"sh":[1455200,154680],"cn":[1522032,154680]}], +"actors/bowser/bowser_tongue.rgba16.png": [32,64,4096,{"jp":[1599504,148536],"us":[1606720,148536],"eu":[1478688,148536],"sh":[1455200,148536],"cn":[1522032,148536]}], +"actors/bowser/bowser_upper_face.rgba16.png": [32,32,2048,{"jp":[1599504,164920],"us":[1606720,164920],"eu":[1478688,164920],"sh":[1455200,164920],"cn":[1522032,164920]}], +"actors/bowser_flame/bowser_flame_0.rgba16.png": [64,64,8192,{"jp":[1599504,0],"us":[1606720,0],"eu":[1478688,0],"sh":[1455200,0],"cn":[1522032,0]}], +"actors/bowser_flame/bowser_flame_1.rgba16.png": [64,64,8192,{"jp":[1599504,8192],"us":[1606720,8192],"eu":[1478688,8192],"sh":[1455200,8192],"cn":[1522032,8192]}], +"actors/bowser_flame/bowser_flame_10.rgba16.png": [64,64,8192,{"jp":[1599504,81920],"us":[1606720,81920],"eu":[1478688,81920],"sh":[1455200,81920],"cn":[1522032,81920]}], +"actors/bowser_flame/bowser_flame_11.rgba16.png": [64,64,8192,{"jp":[1599504,90112],"us":[1606720,90112],"eu":[1478688,90112],"sh":[1455200,90112],"cn":[1522032,90112]}], +"actors/bowser_flame/bowser_flame_12.rgba16.png": [64,64,8192,{"jp":[1599504,98304],"us":[1606720,98304],"eu":[1478688,98304],"sh":[1455200,98304],"cn":[1522032,98304]}], +"actors/bowser_flame/bowser_flame_13.rgba16.png": [64,64,8192,{"jp":[1599504,106496],"us":[1606720,106496],"eu":[1478688,106496],"sh":[1455200,106496],"cn":[1522032,106496]}], +"actors/bowser_flame/bowser_flame_2.rgba16.png": [64,64,8192,{"jp":[1599504,16384],"us":[1606720,16384],"eu":[1478688,16384],"sh":[1455200,16384],"cn":[1522032,16384]}], +"actors/bowser_flame/bowser_flame_3.rgba16.png": [64,64,8192,{"jp":[1599504,24576],"us":[1606720,24576],"eu":[1478688,24576],"sh":[1455200,24576],"cn":[1522032,24576]}], +"actors/bowser_flame/bowser_flame_4.rgba16.png": [64,64,8192,{"jp":[1599504,32768],"us":[1606720,32768],"eu":[1478688,32768],"sh":[1455200,32768],"cn":[1522032,32768]}], +"actors/bowser_flame/bowser_flame_5.rgba16.png": [64,64,8192,{"jp":[1599504,40960],"us":[1606720,40960],"eu":[1478688,40960],"sh":[1455200,40960],"cn":[1522032,40960]}], +"actors/bowser_flame/bowser_flame_6.rgba16.png": [64,64,8192,{"jp":[1599504,49152],"us":[1606720,49152],"eu":[1478688,49152],"sh":[1455200,49152],"cn":[1522032,49152]}], +"actors/bowser_flame/bowser_flame_7.rgba16.png": [64,64,8192,{"jp":[1599504,57344],"us":[1606720,57344],"eu":[1478688,57344],"sh":[1455200,57344],"cn":[1522032,57344]}], +"actors/bowser_flame/bowser_flame_8.rgba16.png": [64,64,8192,{"jp":[1599504,65536],"us":[1606720,65536],"eu":[1478688,65536],"sh":[1455200,65536],"cn":[1522032,65536]}], +"actors/bowser_flame/bowser_flame_9.rgba16.png": [64,64,8192,{"jp":[1599504,73728],"us":[1606720,73728],"eu":[1478688,73728],"sh":[1455200,73728],"cn":[1522032,73728]}], +"actors/breakable_box/cork_box_surface.rgba16.png": [32,32,2048,{"jp":[2032944,74384],"us":[2040320,74384],"eu":[1912288,74384],"sh":[1888800,74384],"cn":[1955632,74384]}], +"actors/breakable_box/crazy_box_surface.rgba16.png": [32,32,2048,{"jp":[2032944,72336],"us":[2040320,72336],"eu":[1912288,72336],"sh":[1888800,72336],"cn":[1955632,72336]}], +"actors/bub/bub_eye_border.rgba16.png": [32,32,2048,{"jp":[1568640,5128],"us":[1575856,5128],"eu":[1447824,5128],"sh":[1424336,5128],"cn":[1491168,5128]}], +"actors/bub/bub_eyes.rgba16.png": [64,32,4096,{"jp":[1568640,1032],"us":[1575856,1032],"eu":[1447824,1032],"sh":[1424336,1032],"cn":[1491168,1032]}], +"actors/bub/bub_fins.rgba16.png": [32,32,2048,{"jp":[1568640,7176],"us":[1575856,7176],"eu":[1447824,7176],"sh":[1424336,7176],"cn":[1491168,7176]}], +"actors/bub/bub_scales.rgba16.png": [64,32,4096,{"jp":[1568640,9224],"us":[1575856,9224],"eu":[1447824,9224],"sh":[1424336,9224],"cn":[1491168,9224]}], +"actors/bubba/bubba_eye_border.rgba16.png": [32,32,2048,{"jp":[1568640,5128],"us":[1575856,5128],"eu":[1447824,5128],"sh":[1424336,5128],"cn":[1491168,5128]}], +"actors/bubba/bubba_eyes_unused.rgba16.png": [64,32,4096,{"jp":[1568640,1032],"us":[1575856,1032],"eu":[1447824,1032],"sh":[1424336,1032],"cn":[1491168,1032]}], +"actors/bubba/bubba_fins.rgba16.png": [32,32,2048,{"jp":[1568640,7176],"us":[1575856,7176],"eu":[1447824,7176],"sh":[1424336,7176],"cn":[1491168,7176]}], +"actors/bubba/bubba_scales.rgba16.png": [64,64,8192,{"jp":[1568640,9224],"us":[1575856,9224],"eu":[1447824,9224],"sh":[1424336,9224],"cn":[1491168,9224]}], +"actors/bubba/bubba_sunglasses.rgba16.png": [16,32,1024,{"jp":[1568640,8],"us":[1575856,8],"eu":[1447824,8],"sh":[1424336,8],"cn":[1491168,8]}], +"actors/bubble/bubble.rgba16.png": [32,32,2048,{"jp":[1125200,118112],"us":[1132368,118112],"eu":[1004336,118112],"sh":[980848,118112],"cn":[1047664,118112]}], +"actors/bubble/mr_i_bubble.rgba16.png": [32,32,2048,{"jp":[1125200,120160],"us":[1132368,120160],"eu":[1004336,120160],"sh":[980848,120160],"cn":[1047664,120160]}], +"actors/bullet_bill/bullet_bill_eye.rgba16.png": [64,32,4096,{"jp":[1215456,47784],"us":[1222624,47784],"eu":[1094592,47784],"sh":[1071104,47784],"cn":[1137936,47784]}], +"actors/bullet_bill/bullet_bill_mouth.rgba16.png": [64,32,4096,{"jp":[1215456,51880],"us":[1222624,51880],"eu":[1094592,51880],"sh":[1071104,51880],"cn":[1137936,51880]}], +"actors/bully/bully_eye.rgba16.png": [32,32,2048,{"jp":[1249376,9320],"us":[1256544,9320],"eu":[1128512,9320],"sh":[1105024,9320],"cn":[1171856,9320]}], +"actors/bully/bully_horn.rgba16.png": [16,16,512,{"jp":[1249376,224],"us":[1256544,224],"eu":[1128512,224],"sh":[1105024,224],"cn":[1171856,224]}], +"actors/bully/bully_left_side.rgba16.png": [32,64,4096,{"jp":[1249376,1128],"us":[1256544,1128],"eu":[1128512,1128],"sh":[1105024,1128],"cn":[1171856,1128]}], +"actors/bully/bully_right_side.rgba16.png": [32,64,4096,{"jp":[1249376,5224],"us":[1256544,5224],"eu":[1128512,5224],"sh":[1105024,5224],"cn":[1171856,5224]}], +"actors/burn_smoke/burn_smoke.ia16.png": [32,32,2048,{"jp":[1125200,137216],"us":[1132368,137216],"eu":[1004336,137216],"sh":[980848,137216],"cn":[1047664,137216]}], +"actors/butterfly/butterfly_wing.rgba16.png": [32,64,4096,{"jp":[2094912,17320],"us":[2102288,17320],"eu":[1974256,17320],"sh":[1950768,17320],"cn":[2017600,17320]}], +"actors/cannon_barrel/cannon_barrel.rgba16.png": [32,32,2048,{"jp":[2032944,22696],"us":[2040320,22696],"eu":[1912288,22696],"sh":[1888800,22696],"cn":[1955632,22696]}], +"actors/cannon_base/cannon_base.rgba16.png": [32,32,2048,{"jp":[2032944,18872],"us":[2040320,18872],"eu":[1912288,18872],"sh":[1888800,18872],"cn":[1955632,18872]}], +"actors/cannon_lid/cannon_lid.rgba16.png": [32,32,2048,{"jp":[2032944,16472],"us":[2040320,16472],"eu":[1912288,16472],"sh":[1888800,16472],"cn":[1955632,16472]}], +"actors/capswitch/cap_switch_base.rgba16.png": [16,4,128,{"jp":[1457744,11336],"us":[1464912,11336],"eu":[1336880,11336],"sh":[1313392,11336],"cn":[1380224,11336]}], +"actors/capswitch/cap_switch_head.ia16.png": [32,64,4096,{"jp":[1457744,7240],"us":[1464912,7240],"eu":[1336880,7240],"sh":[1313392,7240],"cn":[1380224,7240]}], +"actors/chain_ball/chain_ball.rgba16.png": [32,32,2048,{"jp":[1844608,133864],"us":[1851952,133864],"eu":[1723920,133864],"sh":[1700432,133864],"cn":[1767264,133864]}], +"actors/chain_chomp/chain_chomp_bright_shine.rgba16.png": [32,32,2048,{"jp":[1844608,136144],"us":[1851952,136144],"eu":[1723920,136144],"sh":[1700432,136144],"cn":[1767264,136144]}], +"actors/chain_chomp/chain_chomp_dull_shine.rgba16.png": [32,32,2048,{"jp":[1844608,138192],"us":[1851952,138192],"eu":[1723920,138192],"sh":[1700432,138192],"cn":[1767264,138192]}], +"actors/chain_chomp/chain_chomp_eye.rgba16.png": [32,32,2048,{"jp":[1844608,144336],"us":[1851952,144336],"eu":[1723920,144336],"sh":[1700432,144336],"cn":[1767264,144336]}], +"actors/chain_chomp/chain_chomp_tongue.rgba16.png": [32,32,2048,{"jp":[1844608,140240],"us":[1851952,140240],"eu":[1723920,140240],"sh":[1700432,140240],"cn":[1767264,140240]}], +"actors/chain_chomp/chain_chomp_tooth.rgba16.png": [32,32,2048,{"jp":[1462368,27376],"us":[1469536,27376],"eu":[1341504,27376],"sh":[1318016,27376],"cn":[1384848,27376]}], +"actors/chair/chair_bottom.rgba16.png": [32,16,1024,{"jp":[1462368,16480],"us":[1469536,16480],"eu":[1341504,16480],"sh":[1318016,16480],"cn":[1384848,16480]}], +"actors/chair/chair_front.rgba16.png": [32,32,2048,{"jp":[1462368,12384],"us":[1469536,12384],"eu":[1341504,12384],"sh":[1318016,12384],"cn":[1384848,12384]}], +"actors/chair/chair_leg.rgba16.png": [32,32,2048,{"jp":[1462368,14432],"us":[1469536,14432],"eu":[1341504,14432],"sh":[1318016,14432],"cn":[1384848,14432]}], +"actors/chair/chair_surface_unused.rgba16.png": [32,32,2048,{"jp":[1462368,17504],"us":[1469536,17504],"eu":[1341504,17504],"sh":[1318016,17504],"cn":[1384848,17504]}], +"actors/checkerboard_platform/checkerboard_platform.rgba16.png": [32,32,2048,{"jp":[2032944,52288],"us":[2040320,52288],"eu":[1912288,52288],"sh":[1888800,52288],"cn":[1955632,52288]}], +"actors/checkerboard_platform/checkerboard_platform_side.rgba16.png": [32,16,1024,{"jp":[2032944,51264],"us":[2040320,51264],"eu":[1912288,51264],"sh":[1888800,51264],"cn":[1955632,51264]}], +"actors/chillychief/chill_bully_eye.rgba16.png": [32,32,2048,{"jp":[1249376,9320],"us":[1256544,9320],"eu":[1128512,9320],"sh":[1105024,9320],"cn":[1171856,9320]}], +"actors/chillychief/chill_bully_left_side.rgba16.png": [32,64,4096,{"jp":[1979680,96],"us":[1987056,96],"eu":[1859024,96],"sh":[1835536,96],"cn":[1902368,96]}], +"actors/chillychief/chill_bully_right_side.rgba16.png": [32,64,4096,{"jp":[1979680,4192],"us":[1987056,4192],"eu":[1859024,4192],"sh":[1835536,4192],"cn":[1902368,4192]}], +"actors/chuckya/chuckya_body_arm_left_side.rgba16.png": [32,64,4096,{"jp":[2032944,32632],"us":[2040320,32632],"eu":[1912288,32632],"sh":[1888800,32632],"cn":[1955632,32632]}], +"actors/chuckya/chuckya_body_arm_right_side.rgba16.png": [32,64,4096,{"jp":[2032944,36728],"us":[2040320,36728],"eu":[1912288,36728],"sh":[1888800,36728],"cn":[1955632,36728]}], +"actors/chuckya/chuckya_eyes.rgba16.png": [32,64,4096,{"jp":[2032944,26488],"us":[2040320,26488],"eu":[1912288,26488],"sh":[1888800,26488],"cn":[1955632,26488]}], +"actors/chuckya/chuckya_hand_antenna.rgba16.png": [32,32,2048,{"jp":[2032944,30584],"us":[2040320,30584],"eu":[1912288,30584],"sh":[1888800,30584],"cn":[1955632,30584]}], +"actors/clam_shell/clam_shell.rgba16.png": [32,32,2048,{"jp":[1285392,48],"us":[1292560,48],"eu":[1164528,48],"sh":[1141040,48],"cn":[1207872,48]}], +"actors/clam_shell/clam_shell_mouth.rgba16.png": [32,32,2048,{"jp":[1285392,2096],"us":[1292560,2096],"eu":[1164528,2096],"sh":[1141040,2096],"cn":[1207872,2096]}], +"actors/coin/coin_front.ia16.png": [32,32,2048,{"jp":[2094912,22400],"us":[2102288,22400],"eu":[1974256,22400],"sh":[1950768,22400],"cn":[2017600,22400]}], +"actors/coin/coin_side.ia16.png": [32,32,2048,{"jp":[2094912,26496],"us":[2102288,26496],"eu":[1974256,26496],"sh":[1950768,26496],"cn":[2017600,26496]}], +"actors/coin/coin_tilt_left.ia16.png": [32,32,2048,{"jp":[2094912,28544],"us":[2102288,28544],"eu":[1974256,28544],"sh":[1950768,28544],"cn":[2017600,28544]}], +"actors/coin/coin_tilt_right.ia16.png": [32,32,2048,{"jp":[2094912,24448],"us":[2102288,24448],"eu":[1974256,24448],"sh":[1950768,24448],"cn":[2017600,24448]}], +"actors/cyan_fish/cyan_fish.rgba16.png": [32,32,2048,{"jp":[1802256,54376],"us":[1809600,54376],"eu":[1681568,54376],"sh":[1658080,54376],"cn":[1724912,54376]}], +"actors/dirt/dirt_particle.rgba16.png": [16,16,512,{"jp":[2094912,179704],"us":[2102288,179704],"eu":[1974256,179704],"sh":[1950768,179704],"cn":[2017600,179704]}], +"actors/door/bbh_door.rgba16.png": [32,64,4096,{"jp":[2094912,66832],"us":[2102288,66832],"eu":[1974256,66832],"sh":[1950768,66832],"cn":[2017600,66832]}], +"actors/door/bbh_door_overlay.rgba16.png": [32,32,2048,{"jp":[2094912,70928],"us":[2102288,70928],"eu":[1974256,70928],"sh":[1950768,70928],"cn":[2017600,70928]}], +"actors/door/door_lock.rgba16.png": [16,32,1024,{"jp":[2094912,79120],"us":[2102288,79120],"eu":[1974256,79120],"sh":[1950768,79120],"cn":[2017600,79120]}], +"actors/door/hmc_mural_door.rgba16.png": [32,64,4096,{"jp":[2094912,60688],"us":[2102288,60688],"eu":[1974256,60688],"sh":[1950768,60688],"cn":[2017600,60688]}], +"actors/door/hmc_mural_door_overlay.rgba16.png": [32,32,2048,{"jp":[2094912,64784],"us":[2102288,64784],"eu":[1974256,64784],"sh":[1950768,64784],"cn":[2017600,64784]}], +"actors/door/metal_door.rgba16.png": [32,64,4096,{"jp":[2094912,54544],"us":[2102288,54544],"eu":[1974256,54544],"sh":[1950768,54544],"cn":[2017600,54544]}], +"actors/door/metal_door_overlay.rgba16.png": [32,32,2048,{"jp":[2094912,58640],"us":[2102288,58640],"eu":[1974256,58640],"sh":[1950768,58640],"cn":[2017600,58640]}], +"actors/door/one_star_door_sign.rgba16.png": [32,32,2048,{"jp":[2094912,75024],"us":[2102288,75024],"eu":[1974256,75024],"sh":[1950768,75024],"cn":[2017600,75024]}], +"actors/door/polished_wooden_door.rgba16.png": [32,64,4096,{"jp":[2094912,40208],"us":[2102288,40208],"eu":[1974256,40208],"sh":[1950768,40208],"cn":[2017600,40208]}], +"actors/door/polished_wooden_door_overlay.rgba16.png": [32,64,4096,{"jp":[2094912,44304],"us":[2102288,44304],"eu":[1974256,44304],"sh":[1950768,44304],"cn":[2017600,44304]}], +"actors/door/rough_wooden_door.rgba16.png": [32,64,4096,{"jp":[2094912,48400],"us":[2102288,48400],"eu":[1974256,48400],"sh":[1950768,48400],"cn":[2017600,48400]}], +"actors/door/rough_wooden_door_overlay.rgba16.png": [32,32,2048,{"jp":[2094912,52496],"us":[2102288,52496],"eu":[1974256,52496],"sh":[1950768,52496],"cn":[2017600,52496]}], +"actors/door/three_star_door_sign.rgba16.png": [32,32,2048,{"jp":[2094912,77072],"us":[2102288,77072],"eu":[1974256,77072],"sh":[1950768,77072],"cn":[2017600,77072]}], +"actors/door/zero_star_door_sign.rgba16.png": [32,32,2048,{"jp":[2094912,72976],"us":[2102288,72976],"eu":[1974256,72976],"sh":[1950768,72976],"cn":[2017600,72976]}], +"actors/dorrie/dorrie_eye.rgba16.png": [16,16,512,{"jp":[1991184,39840],"us":[1998560,39840],"eu":[1870528,39840],"sh":[1847040,39840],"cn":[1913872,39840]}], +"actors/dorrie/dorrie_skin.rgba16.png": [32,64,4096,{"jp":[1991184,40352],"us":[1998560,40352],"eu":[1870528,40352],"sh":[1847040,40352],"cn":[1913872,40352]}], +"actors/dorrie/dorrie_tongue.rgba16.png": [32,32,2048,{"jp":[1844608,140240],"us":[1851952,140240],"eu":[1723920,140240],"sh":[1700432,140240],"cn":[1767264,140240]}], +"actors/exclamation_box/exclamation_box_front.rgba16.png": [32,32,2048,{"jp":[2032944,95784],"us":[2040320,95784],"eu":[1912288,95784],"sh":[1888800,95784],"cn":[1955632,95784]}], +"actors/exclamation_box/exclamation_box_side.rgba16.png": [64,32,4096,{"jp":[2032944,97832],"us":[2040320,97832],"eu":[1912288,97832],"sh":[1888800,97832],"cn":[1955632,97832]}], +"actors/exclamation_box/metal_cap_box_front.rgba16.png": [32,32,2048,{"jp":[2032944,83496],"us":[2040320,83496],"eu":[1912288,83496],"sh":[1888800,83496],"cn":[1955632,83496]}], +"actors/exclamation_box/metal_cap_box_side.rgba16.png": [64,32,4096,{"jp":[2032944,85544],"us":[2040320,85544],"eu":[1912288,85544],"sh":[1888800,85544],"cn":[1955632,85544]}], +"actors/exclamation_box/vanish_cap_box_front.rgba16.png": [32,32,2048,{"jp":[2032944,77352],"us":[2040320,77352],"eu":[1912288,77352],"sh":[1888800,77352],"cn":[1955632,77352]}], +"actors/exclamation_box/vanish_cap_box_side.rgba16.png": [32,64,4096,{"jp":[2032944,79400],"us":[2040320,79400],"eu":[1912288,79400],"sh":[1888800,79400],"cn":[1955632,79400]}], +"actors/exclamation_box/wing_cap_box_front.rgba16.png": [32,32,2048,{"jp":[2032944,89640],"us":[2040320,89640],"eu":[1912288,89640],"sh":[1888800,89640],"cn":[1955632,89640]}], +"actors/exclamation_box/wing_cap_box_side.rgba16.png": [32,64,4096,{"jp":[2032944,91688],"us":[2040320,91688],"eu":[1912288,91688],"sh":[1888800,91688],"cn":[1955632,91688]}], +"actors/exclamation_box_outline/exclamation_box_outline.rgba16.png": [32,32,2048,{"jp":[2032944,151912],"us":[2040320,151912],"eu":[1912288,151912],"sh":[1888800,151912],"cn":[1955632,151912]}], +"actors/exclamation_box_outline/exclamation_point.rgba16.png": [16,32,1024,{"jp":[2032944,154240],"us":[2040320,154240],"eu":[1912288,154240],"sh":[1888800,154240],"cn":[1955632,154240]}], +"actors/explosion/explosion_0.rgba16.png": [32,32,2048,{"jp":[2094912,2568],"us":[2102288,2568],"eu":[1974256,2568],"sh":[1950768,2568],"cn":[2017600,2568]}], +"actors/explosion/explosion_1.rgba16.png": [32,32,2048,{"jp":[2094912,4616],"us":[2102288,4616],"eu":[1974256,4616],"sh":[1950768,4616],"cn":[2017600,4616]}], +"actors/explosion/explosion_2.rgba16.png": [32,32,2048,{"jp":[2094912,6664],"us":[2102288,6664],"eu":[1974256,6664],"sh":[1950768,6664],"cn":[2017600,6664]}], +"actors/explosion/explosion_3.rgba16.png": [32,32,2048,{"jp":[2094912,8712],"us":[2102288,8712],"eu":[1974256,8712],"sh":[1950768,8712],"cn":[2017600,8712]}], +"actors/explosion/explosion_4.rgba16.png": [32,32,2048,{"jp":[2094912,10760],"us":[2102288,10760],"eu":[1974256,10760],"sh":[1950768,10760],"cn":[2017600,10760]}], +"actors/explosion/explosion_5.rgba16.png": [32,32,2048,{"jp":[2094912,12808],"us":[2102288,12808],"eu":[1974256,12808],"sh":[1950768,12808],"cn":[2017600,12808]}], +"actors/explosion/explosion_6.rgba16.png": [32,32,2048,{"jp":[2094912,14856],"us":[2102288,14856],"eu":[1974256,14856],"sh":[1950768,14856],"cn":[2017600,14856]}], +"actors/eyerok/eyerok_bricks.rgba16.png": [32,32,2048,{"jp":[1327760,36160],"us":[1334928,36160],"eu":[1206896,36160],"sh":[1183408,36160],"cn":[1250240,36160]}], +"actors/eyerok/eyerok_eye_closed.rgba16.png": [32,32,2048,{"jp":[1327760,44352],"us":[1334928,44352],"eu":[1206896,44352],"sh":[1183408,44352],"cn":[1250240,44352]}], +"actors/eyerok/eyerok_eye_mostly_closed.rgba16.png": [32,32,2048,{"jp":[1327760,42304],"us":[1334928,42304],"eu":[1206896,42304],"sh":[1183408,42304],"cn":[1250240,42304]}], +"actors/eyerok/eyerok_eye_mostly_open.rgba16.png": [32,32,2048,{"jp":[1327760,40256],"us":[1334928,40256],"eu":[1206896,40256],"sh":[1183408,40256],"cn":[1250240,40256]}], +"actors/eyerok/eyerok_eye_open.rgba16.png": [32,32,2048,{"jp":[1327760,38208],"us":[1334928,38208],"eu":[1206896,38208],"sh":[1183408,38208],"cn":[1250240,38208]}], +"actors/flame/flame_0.ia16.png": [32,32,2048,{"jp":[2094912,95008],"us":[2102288,95008],"eu":[1974256,95008],"sh":[1950768,95008],"cn":[2017600,95008]}], +"actors/flame/flame_1.ia16.png": [32,32,2048,{"jp":[2094912,97056],"us":[2102288,97056],"eu":[1974256,97056],"sh":[1950768,97056],"cn":[2017600,97056]}], +"actors/flame/flame_2.ia16.png": [32,32,2048,{"jp":[2094912,99104],"us":[2102288,99104],"eu":[1974256,99104],"sh":[1950768,99104],"cn":[2017600,99104]}], +"actors/flame/flame_3.ia16.png": [32,32,2048,{"jp":[2094912,101152],"us":[2102288,101152],"eu":[1974256,101152],"sh":[1950768,101152],"cn":[2017600,101152]}], +"actors/flame/flame_4.ia16.png": [32,32,2048,{"jp":[2094912,103200],"us":[2102288,103200],"eu":[1974256,103200],"sh":[1950768,103200],"cn":[2017600,103200]}], +"actors/flame/flame_5.ia16.png": [32,32,2048,{"jp":[2094912,105248],"us":[2102288,105248],"eu":[1974256,105248],"sh":[1950768,105248],"cn":[2017600,105248]}], +"actors/flame/flame_6.ia16.png": [32,32,2048,{"jp":[2094912,107296],"us":[2102288,107296],"eu":[1974256,107296],"sh":[1950768,107296],"cn":[2017600,107296]}], +"actors/flame/flame_7.ia16.png": [32,32,2048,{"jp":[2094912,109344],"us":[2102288,109344],"eu":[1974256,109344],"sh":[1950768,109344],"cn":[2017600,109344]}], +"actors/flyguy/flyguy_cloth_wrinkle.rgba16.png": [64,32,4096,{"jp":[2032944,57480],"us":[2040320,57480],"eu":[1912288,57480],"sh":[1888800,57480],"cn":[1955632,57480]}], +"actors/flyguy/flyguy_face.rgba16.png": [32,32,2048,{"jp":[2032944,61576],"us":[2040320,61576],"eu":[1912288,61576],"sh":[1888800,61576],"cn":[1955632,61576]}], +"actors/flyguy/flyguy_propeller.ia16.png": [32,32,2048,{"jp":[2032944,63624],"us":[2040320,63624],"eu":[1912288,63624],"sh":[1888800,63624],"cn":[1955632,63624]}], +"actors/fwoosh/fwoosh_face.ia16.png": [32,32,2048,{"jp":[1377744,88072],"us":[1384912,88072],"eu":[1256880,88072],"sh":[1233392,88072],"cn":[1300224,88072]}], +"actors/goomba/goomba_body.rgba16.png": [32,32,2048,{"jp":[2032944,103728],"us":[2040320,103728],"eu":[1912288,103728],"sh":[1888800,103728],"cn":[1955632,103728]}], +"actors/goomba/goomba_face.rgba16.png": [32,32,2048,{"jp":[2032944,105776],"us":[2040320,105776],"eu":[1912288,105776],"sh":[1888800,105776],"cn":[1955632,105776]}], +"actors/goomba/goomba_face_blink.rgba16.png": [32,32,2048,{"jp":[2032944,107824],"us":[2040320,107824],"eu":[1912288,107824],"sh":[1888800,107824],"cn":[1955632,107824]}], +"actors/haunted_cage/bbh_cage_bars.rgba16.png": [32,32,2048,{"jp":[1462368,55944],"us":[1469536,55944],"eu":[1341504,55944],"sh":[1318016,55944],"cn":[1384848,55944]}], +"actors/haunted_cage/bbh_cage_double_ornament.rgba16.png": [32,32,2048,{"jp":[1462368,51848],"us":[1469536,51848],"eu":[1341504,51848],"sh":[1318016,51848],"cn":[1384848,51848]}], +"actors/haunted_cage/bbh_cage_floor.rgba16.png": [32,32,2048,{"jp":[1462368,49800],"us":[1469536,49800],"eu":[1341504,49800],"sh":[1318016,49800],"cn":[1384848,49800]}], +"actors/haunted_cage/bbh_cage_garbage.rgba16.png": [32,32,2048,{"jp":[1462368,57992],"us":[1469536,57992],"eu":[1341504,57992],"sh":[1318016,57992],"cn":[1384848,57992]}], +"actors/haunted_cage/bbh_cage_ornament.rgba16.png": [32,16,1024,{"jp":[1462368,53896],"us":[1469536,53896],"eu":[1341504,53896],"sh":[1318016,53896],"cn":[1384848,53896]}], +"actors/haunted_cage/bbh_cage_wooden_base.rgba16.png": [32,16,1024,{"jp":[1462368,54920],"us":[1469536,54920],"eu":[1341504,54920],"sh":[1318016,54920],"cn":[1384848,54920]}], +"actors/heart/spinning_heart.rgba16.png": [32,32,2048,{"jp":[2032944,55264],"us":[2040320,55264],"eu":[1912288,55264],"sh":[1888800,55264],"cn":[1955632,55264]}], +"actors/heave_ho/heave-ho_arm_ornament.rgba16.png": [32,32,2048,{"jp":[1215456,68040],"us":[1222624,68040],"eu":[1094592,68040],"sh":[1071104,68040],"cn":[1137936,68040]}], +"actors/heave_ho/heave-ho_face.rgba16.png": [32,32,2048,{"jp":[1215456,59848],"us":[1222624,59848],"eu":[1094592,59848],"sh":[1071104,59848],"cn":[1137936,59848]}], +"actors/heave_ho/heave-ho_logo.rgba16.png": [64,32,4096,{"jp":[1215456,63944],"us":[1222624,63944],"eu":[1094592,63944],"sh":[1071104,63944],"cn":[1137936,63944]}], +"actors/heave_ho/heave-ho_platform.rgba16.png": [32,32,2048,{"jp":[1215456,61896],"us":[1222624,61896],"eu":[1094592,61896],"sh":[1071104,61896],"cn":[1137936,61896]}], +"actors/heave_ho/heave-ho_roller.rgba16.png": [16,16,512,{"jp":[1215456,70088],"us":[1222624,70088],"eu":[1094592,70088],"sh":[1071104,70088],"cn":[1137936,70088]}], +"actors/heave_ho/heave-ho_turnkey.rgba16.png": [32,32,2048,{"jp":[1215456,70600],"us":[1222624,70600],"eu":[1094592,70600],"sh":[1071104,70600],"cn":[1137936,70600]}], +"actors/hoot/hoot_eyes.rgba16.png": [32,32,2048,{"jp":[1215456,2592],"us":[1222624,2592],"eu":[1094592,2592],"sh":[1071104,2592],"cn":[1137936,2592]}], +"actors/hoot/hoot_wing.rgba16.png": [32,32,2048,{"jp":[1215456,7760],"us":[1222624,7760],"eu":[1094592,7760],"sh":[1071104,7760],"cn":[1137936,7760]}], +"actors/hoot/hoot_wing_tip.rgba16.png": [32,32,2048,{"jp":[1215456,9808],"us":[1222624,9808],"eu":[1094592,9808],"sh":[1071104,9808],"cn":[1137936,9808]}], +"actors/impact_ring/impact_ring_left_side.ia16.png": [32,64,4096,{"jp":[1599504,117328],"us":[1606720,117328],"eu":[1478688,117328],"sh":[1455200,117328],"cn":[1522032,117328]}], +"actors/impact_ring/impact_ring_right_side.ia16.png": [32,64,4096,{"jp":[1599504,121424],"us":[1606720,121424],"eu":[1478688,121424],"sh":[1455200,121424],"cn":[1522032,121424]}], +"actors/impact_smoke/impact_smoke_0.ia16.png": [64,64,8192,{"jp":[1599504,371240],"us":[1606720,371576],"eu":[1478688,371576],"sh":[1455200,371576],"cn":[1522032,371576]}], +"actors/impact_smoke/impact_smoke_1.ia16.png": [64,64,8192,{"jp":[1599504,379432],"us":[1606720,379768],"eu":[1478688,379768],"sh":[1455200,379768],"cn":[1522032,379768]}], +"actors/impact_smoke/impact_smoke_2.ia16.png": [64,64,8192,{"jp":[1599504,387624],"us":[1606720,387960],"eu":[1478688,387960],"sh":[1455200,387960],"cn":[1522032,387960]}], +"actors/impact_smoke/impact_smoke_3.ia16.png": [64,64,8192,{"jp":[1599504,395816],"us":[1606720,396152],"eu":[1478688,396152],"sh":[1455200,396152],"cn":[1522032,396152]}], +"actors/king_bobomb/bob-omb_buddy_body_unused.rgba16.png": [64,64,8192,{"jp":[1257760,25720],"us":[1264928,25720],"eu":[1136896,25720],"sh":[1113408,25720],"cn":[1180240,25720]}], +"actors/king_bobomb/bob-omb_buddy_left_side_unused.rgba16.png": [32,64,4096,{"jp":[1257760,120],"us":[1264928,120],"eu":[1136896,120],"sh":[1113408,120],"cn":[1180240,120]}], +"actors/king_bobomb/bob-omb_buddy_right_side_unused.rgba16.png": [32,64,4096,{"jp":[1257760,4216],"us":[1264928,4216],"eu":[1136896,4216],"sh":[1113408,4216],"cn":[1180240,4216]}], +"actors/king_bobomb/king_bob-omb_arm.rgba16.png": [32,32,2048,{"jp":[1257760,8312],"us":[1264928,8312],"eu":[1136896,8312],"sh":[1113408,8312],"cn":[1180240,8312]}], +"actors/king_bobomb/king_bob-omb_body_unused.rgba16.png": [64,64,8192,{"jp":[1257760,10360],"us":[1264928,10360],"eu":[1136896,10360],"sh":[1113408,10360],"cn":[1180240,10360]}], +"actors/king_bobomb/king_bob-omb_crown_rim.rgba16.png": [32,16,1024,{"jp":[1257760,24696],"us":[1264928,24696],"eu":[1136896,24696],"sh":[1113408,24696],"cn":[1180240,24696]}], +"actors/king_bobomb/king_bob-omb_eyes.rgba16.png": [32,32,2048,{"jp":[1257760,18552],"us":[1264928,18552],"eu":[1136896,18552],"sh":[1113408,18552],"cn":[1180240,18552]}], +"actors/king_bobomb/king_bob-omb_eyes_blink.rgba16.png": [32,32,2048,{"jp":[1257760,20600],"us":[1264928,20600],"eu":[1136896,20600],"sh":[1113408,20600],"cn":[1180240,20600]}], +"actors/king_bobomb/king_bob-omb_hand.rgba16.png": [32,32,2048,{"jp":[1257760,22648],"us":[1264928,22648],"eu":[1136896,22648],"sh":[1113408,22648],"cn":[1180240,22648]}], +"actors/king_bobomb/king_bob-omb_left_side.rgba16.png": [32,64,4096,{"jp":[1257760,33912],"us":[1264928,33912],"eu":[1136896,33912],"sh":[1113408,33912],"cn":[1180240,33912]}], +"actors/king_bobomb/king_bob-omb_right_side.rgba16.png": [32,64,4096,{"jp":[1257760,38008],"us":[1264928,38008],"eu":[1136896,38008],"sh":[1113408,38008],"cn":[1180240,38008]}], +"actors/klepto/klepto_beak.rgba16.png": [32,64,4096,{"jp":[1327760,4104],"us":[1334928,4104],"eu":[1206896,4104],"sh":[1183408,4104],"cn":[1250240,4104]}], +"actors/klepto/klepto_chest_tuft.rgba16.png": [32,32,2048,{"jp":[1327760,8],"us":[1334928,8],"eu":[1206896,8],"sh":[1183408,8],"cn":[1250240,8]}], +"actors/klepto/klepto_eye.rgba16.png": [32,32,2048,{"jp":[1327760,2056],"us":[1334928,2056],"eu":[1206896,2056],"sh":[1183408,2056],"cn":[1250240,2056]}], +"actors/klepto/klepto_wing.rgba16.png": [64,32,4096,{"jp":[1327760,8200],"us":[1334928,8200],"eu":[1206896,8200],"sh":[1183408,8200],"cn":[1250240,8200]}], +"actors/klepto/klepto_wing_flap.rgba16.png": [32,32,2048,{"jp":[1327760,12296],"us":[1334928,12296],"eu":[1206896,12296],"sh":[1183408,12296],"cn":[1250240,12296]}], +"actors/koopa/koopa_eye_border.rgba16.png": [32,32,2048,{"jp":[1844608,22088],"us":[1851952,22088],"eu":[1723920,22088],"sh":[1700432,22088],"cn":[1767264,22088]}], +"actors/koopa/koopa_eyes_closed.rgba16.png": [32,32,2048,{"jp":[1844608,20040],"us":[1851952,20040],"eu":[1723920,20040],"sh":[1700432,20040],"cn":[1767264,20040]}], +"actors/koopa/koopa_eyes_open.rgba16.png": [32,32,2048,{"jp":[1844608,17992],"us":[1851952,17992],"eu":[1723920,17992],"sh":[1700432,17992],"cn":[1767264,17992]}], +"actors/koopa/koopa_nostrils.rgba16.png": [64,32,4096,{"jp":[1844608,24136],"us":[1851952,24136],"eu":[1723920,24136],"sh":[1700432,24136],"cn":[1767264,24136]}], +"actors/koopa/koopa_shell_back.rgba16.png": [32,32,2048,{"jp":[1844608,11848],"us":[1851952,11848],"eu":[1723920,11848],"sh":[1700432,11848],"cn":[1767264,11848]}], +"actors/koopa/koopa_shell_front.rgba16.png": [32,32,2048,{"jp":[1844608,9800],"us":[1851952,9800],"eu":[1723920,9800],"sh":[1700432,9800],"cn":[1767264,9800]}], +"actors/koopa/koopa_shell_front_top.rgba16.png": [32,32,2048,{"jp":[1844608,15944],"us":[1851952,15944],"eu":[1723920,15944],"sh":[1700432,15944],"cn":[1767264,15944]}], +"actors/koopa/koopa_shoe.rgba16.png": [32,32,2048,{"jp":[1844608,13896],"us":[1851952,13896],"eu":[1723920,13896],"sh":[1700432,13896],"cn":[1767264,13896]}], +"actors/koopa_flag/koopa_flag_banner.rgba16.png": [32,32,2048,{"jp":[1844608,72],"us":[1851952,72],"eu":[1723920,72],"sh":[1700432,72],"cn":[1767264,72]}], +"actors/koopa_shell/koopa_shell_back.rgba16.png": [32,32,2048,{"jp":[1844608,11848],"us":[1851952,11848],"eu":[1723920,11848],"sh":[1700432,11848],"cn":[1767264,11848]}], +"actors/koopa_shell/koopa_shell_front.rgba16.png": [32,32,2048,{"jp":[1844608,9800],"us":[1851952,9800],"eu":[1723920,9800],"sh":[1700432,9800],"cn":[1767264,9800]}], +"actors/lakitu_cameraman/lakitu_camera_lens.rgba16.png": [16,16,512,{"jp":[1926752,14336],"us":[1934096,14336],"eu":[1806064,14336],"sh":[1782576,14336],"cn":[1849408,14336]}], +"actors/lakitu_cameraman/lakitu_cameraman_cloud_face_unused.rgba16.png": [32,32,2048,{"jp":[1568640,60640],"us":[1575856,60640],"eu":[1447824,60640],"sh":[1424336,60640],"cn":[1491168,60640]}], +"actors/lakitu_cameraman/lakitu_cameraman_eyes_closed.rgba16.png": [64,32,4096,{"jp":[1568640,66784],"us":[1575856,66784],"eu":[1447824,66784],"sh":[1424336,66784],"cn":[1491168,66784]}], +"actors/lakitu_cameraman/lakitu_cameraman_eyes_open.rgba16.png": [64,32,4096,{"jp":[1568640,62688],"us":[1575856,62688],"eu":[1447824,62688],"sh":[1424336,62688],"cn":[1491168,62688]}], +"actors/lakitu_cameraman/lakitu_cameraman_frown.rgba16.png": [32,32,2048,{"jp":[1568640,72928],"us":[1575856,72928],"eu":[1447824,72928],"sh":[1424336,72928],"cn":[1491168,72928]}], +"actors/lakitu_cameraman/lakitu_cameraman_shell.rgba16.png": [32,32,2048,{"jp":[1568640,70880],"us":[1575856,70880],"eu":[1447824,70880],"sh":[1424336,70880],"cn":[1491168,70880]}], +"actors/lakitu_enemy/lakitu_enemy_cloud_face_unused.rgba16.png": [32,32,2048,{"jp":[1568640,60640],"us":[1575856,60640],"eu":[1447824,60640],"sh":[1424336,60640],"cn":[1491168,60640]}], +"actors/lakitu_enemy/lakitu_enemy_eyes_closed.rgba16.png": [64,32,4096,{"jp":[1568640,66784],"us":[1575856,66784],"eu":[1447824,66784],"sh":[1424336,66784],"cn":[1491168,66784]}], +"actors/lakitu_enemy/lakitu_enemy_eyes_open.rgba16.png": [64,32,4096,{"jp":[1568640,62688],"us":[1575856,62688],"eu":[1447824,62688],"sh":[1424336,62688],"cn":[1491168,62688]}], +"actors/lakitu_enemy/lakitu_enemy_frown.rgba16.png": [32,32,2048,{"jp":[1568640,72928],"us":[1575856,72928],"eu":[1447824,72928],"sh":[1424336,72928],"cn":[1491168,72928]}], +"actors/lakitu_enemy/lakitu_enemy_shell.rgba16.png": [32,32,2048,{"jp":[1568640,70880],"us":[1575856,70880],"eu":[1447824,70880],"sh":[1424336,70880],"cn":[1491168,70880]}], +"actors/leaves/leaf.rgba16.png": [16,16,512,{"jp":[2094912,117728],"us":[2102288,117728],"eu":[1974256,117728],"sh":[1950768,117728],"cn":[2017600,117728]}], +"actors/mad_piano/mad_piano_body.rgba16.png": [16,32,1024,{"jp":[1462368,29424],"us":[1469536,29424],"eu":[1341504,29424],"sh":[1318016,29424],"cn":[1384848,29424]}], +"actors/mad_piano/mad_piano_keys.rgba16.png": [32,16,1024,{"jp":[1462368,32496],"us":[1469536,32496],"eu":[1341504,32496],"sh":[1318016,32496],"cn":[1384848,32496]}], +"actors/mad_piano/mad_piano_keys_corner.rgba16.png": [32,16,1024,{"jp":[1462368,30448],"us":[1469536,30448],"eu":[1341504,30448],"sh":[1318016,30448],"cn":[1384848,30448]}], +"actors/mad_piano/mad_piano_keys_edge.rgba16.png": [32,16,1024,{"jp":[1462368,33520],"us":[1469536,33520],"eu":[1341504,33520],"sh":[1318016,33520],"cn":[1384848,33520]}], +"actors/mad_piano/mad_piano_mouth.rgba16.png": [16,32,1024,{"jp":[1462368,31472],"us":[1469536,31472],"eu":[1341504,31472],"sh":[1318016,31472],"cn":[1384848,31472]}], +"actors/mad_piano/mad_piano_tooth.rgba16.png": [32,32,2048,{"jp":[1462368,27376],"us":[1469536,27376],"eu":[1341504,27376],"sh":[1318016,27376],"cn":[1384848,27376]}], +"actors/manta/manta_eye.rgba16.png": [32,32,2048,{"jp":[1285392,12192],"us":[1292560,12192],"eu":[1164528,12192],"sh":[1141040,12192],"cn":[1207872,12192]}], +"actors/manta/manta_fin_corner.rgba16.png": [32,32,2048,{"jp":[1285392,6048],"us":[1292560,6048],"eu":[1164528,6048],"sh":[1141040,6048],"cn":[1207872,6048]}], +"actors/manta/manta_fin_edge.rgba16.png": [64,32,4096,{"jp":[1285392,14240],"us":[1292560,14240],"eu":[1164528,14240],"sh":[1141040,14240],"cn":[1207872,14240]}], +"actors/manta/manta_gills.rgba16.png": [32,64,4096,{"jp":[1285392,8096],"us":[1292560,8096],"eu":[1164528,8096],"sh":[1141040,8096],"cn":[1207872,8096]}], +"actors/mario/mario_eyes_center.rgba16.png": [32,32,2048,{"jp":[1125200,12432],"us":[1132368,12432],"eu":[1004336,12432],"sh":[980848,12432],"cn":[1047664,12432]}], +"actors/mario/mario_eyes_closed.rgba16.png": [32,32,2048,{"jp":[1125200,16528],"us":[1132368,16528],"eu":[1004336,16528],"sh":[980848,16528],"cn":[1047664,16528]}], +"actors/mario/mario_eyes_closed_unused_0.rgba16.png": [32,32,2048,{"jp":[1125200,16528],"us":[1132368,16528],"eu":[1004336,16528],"sh":[980848,16528],"cn":[1047664,16528]}], +"actors/mario/mario_eyes_closed_unused_1.rgba16.png": [32,32,2048,{"jp":[1125200,16528],"us":[1132368,16528],"eu":[1004336,16528],"sh":[980848,16528],"cn":[1047664,16528]}], +"actors/mario/mario_eyes_dead.rgba16.png": [32,32,2048,{"jp":[1125200,30864],"us":[1132368,30864],"eu":[1004336,30864],"sh":[980848,30864],"cn":[1047664,30864]}], +"actors/mario/mario_eyes_down_unused.rgba16.png": [32,32,2048,{"jp":[1125200,28816],"us":[1132368,28816],"eu":[1004336,28816],"sh":[980848,28816],"cn":[1047664,28816]}], +"actors/mario/mario_eyes_half_closed.rgba16.png": [32,32,2048,{"jp":[1125200,14480],"us":[1132368,14480],"eu":[1004336,14480],"sh":[980848,14480],"cn":[1047664,14480]}], +"actors/mario/mario_eyes_left_unused.rgba16.png": [32,32,2048,{"jp":[1125200,22672],"us":[1132368,22672],"eu":[1004336,22672],"sh":[980848,22672],"cn":[1047664,22672]}], +"actors/mario/mario_eyes_right_unused.rgba16.png": [32,32,2048,{"jp":[1125200,24720],"us":[1132368,24720],"eu":[1004336,24720],"sh":[980848,24720],"cn":[1047664,24720]}], +"actors/mario/mario_eyes_up_unused.rgba16.png": [32,32,2048,{"jp":[1125200,26768],"us":[1132368,26768],"eu":[1004336,26768],"sh":[980848,26768],"cn":[1047664,26768]}], +"actors/mario/mario_logo.rgba16.png": [32,32,2048,{"jp":[1125200,6288],"us":[1132368,6288],"eu":[1004336,6288],"sh":[980848,6288],"cn":[1047664,6288]}], +"actors/mario/mario_metal.rgba16.png": [64,32,4096,{"jp":[1125200,144],"us":[1132368,144],"eu":[1004336,144],"sh":[980848,144],"cn":[1047664,144]}], +"actors/mario/mario_metal_wing_tip_unused.rgba16.png": [32,64,4096,{"jp":[1125200,45200],"us":[1132368,45200],"eu":[1004336,45200],"sh":[980848,45200],"cn":[1047664,45200]}], +"actors/mario/mario_metal_wing_unused.rgba16.png": [32,64,4096,{"jp":[1125200,41104],"us":[1132368,41104],"eu":[1004336,41104],"sh":[980848,41104],"cn":[1047664,41104]}], +"actors/mario/mario_mustache.rgba16.png": [32,32,2048,{"jp":[1125200,10384],"us":[1132368,10384],"eu":[1004336,10384],"sh":[980848,10384],"cn":[1047664,10384]}], +"actors/mario/mario_overalls_button.rgba16.png": [32,32,2048,{"jp":[1125200,4240],"us":[1132368,4240],"eu":[1004336,4240],"sh":[980848,4240],"cn":[1047664,4240]}], +"actors/mario/mario_sideburn.rgba16.png": [32,32,2048,{"jp":[1125200,8336],"us":[1132368,8336],"eu":[1004336,8336],"sh":[980848,8336],"cn":[1047664,8336]}], +"actors/mario/mario_wing.rgba16.png": [32,64,4096,{"jp":[1125200,32912],"us":[1132368,32912],"eu":[1004336,32912],"sh":[980848,32912],"cn":[1047664,32912]}], +"actors/mario/mario_wing_tip.rgba16.png": [32,64,4096,{"jp":[1125200,37008],"us":[1132368,37008],"eu":[1004336,37008],"sh":[980848,37008],"cn":[1047664,37008]}], +"actors/mario_cap/mario_cap_logo.rgba16.png": [32,32,2048,{"jp":[1125200,6288],"us":[1132368,6288],"eu":[1004336,6288],"sh":[980848,6288],"cn":[1047664,6288]}], +"actors/mario_cap/mario_cap_metal.rgba16.png": [64,32,4096,{"jp":[1125200,144],"us":[1132368,144],"eu":[1004336,144],"sh":[980848,144],"cn":[1047664,144]}], +"actors/mario_cap/mario_cap_metal_wing_tip_unused.rgba16.png": [32,64,4096,{"jp":[1125200,45200],"us":[1132368,45200],"eu":[1004336,45200],"sh":[980848,45200],"cn":[1047664,45200]}], +"actors/mario_cap/mario_cap_metal_wing_unused.rgba16.png": [32,64,4096,{"jp":[1125200,41104],"us":[1132368,41104],"eu":[1004336,41104],"sh":[980848,41104],"cn":[1047664,41104]}], +"actors/mario_cap/mario_cap_wing.rgba16.png": [32,64,4096,{"jp":[1125200,32912],"us":[1132368,32912],"eu":[1004336,32912],"sh":[980848,32912],"cn":[1047664,32912]}], +"actors/mario_cap/mario_cap_wing_tip.rgba16.png": [32,64,4096,{"jp":[1125200,37008],"us":[1132368,37008],"eu":[1004336,37008],"sh":[980848,37008],"cn":[1047664,37008]}], +"actors/metal_box/metal_box_side.rgba16.png": [32,64,4096,{"jp":[2032944,145816],"us":[2040320,145816],"eu":[1912288,145816],"sh":[1888800,145816],"cn":[1955632,145816]}], +"actors/mips/mips_eyes.rgba16.png": [32,32,2048,{"jp":[1926752,64384],"us":[1934096,64624],"eu":[1806064,64624],"sh":[1782576,64624],"cn":[1849408,64624]}], +"actors/mist/mist.ia16.png": [32,32,2048,{"jp":[2094912,128],"us":[2102288,128],"eu":[1974256,128],"sh":[1950768,128],"cn":[2017600,128]}], +"actors/moneybag/moneybag_eyes.rgba16.png": [32,32,2048,{"jp":[1979680,18864],"us":[1987056,18864],"eu":[1859024,18864],"sh":[1835536,18864],"cn":[1902368,18864]}], +"actors/moneybag/moneybag_mouth.rgba16.png": [64,32,4096,{"jp":[1979680,14768],"us":[1987056,14768],"eu":[1859024,14768],"sh":[1835536,14768],"cn":[1902368,14768]}], +"actors/monty_mole/monty_mole_cheek.rgba16.png": [32,32,2048,{"jp":[1377744,2416],"us":[1384912,2416],"eu":[1256880,2416],"sh":[1233392,2416],"cn":[1300224,2416]}], +"actors/monty_mole/monty_mole_claw.rgba16.png": [32,32,2048,{"jp":[1377744,10608],"us":[1384912,10608],"eu":[1256880,10608],"sh":[1233392,10608],"cn":[1300224,10608]}], +"actors/monty_mole/monty_mole_eye.rgba16.png": [32,32,2048,{"jp":[1377744,4464],"us":[1384912,4464],"eu":[1256880,4464],"sh":[1233392,4464],"cn":[1300224,4464]}], +"actors/monty_mole/monty_mole_nose.rgba16.png": [32,32,2048,{"jp":[1377744,6512],"us":[1384912,6512],"eu":[1256880,6512],"sh":[1233392,6512],"cn":[1300224,6512]}], +"actors/monty_mole/monty_mole_tooth.rgba16.png": [32,32,2048,{"jp":[1377744,8560],"us":[1384912,8560],"eu":[1256880,8560],"sh":[1233392,8560],"cn":[1300224,8560]}], +"actors/monty_mole_hole/monty_mole_hole.ia16.png": [32,32,2048,{"jp":[1377744,64],"us":[1384912,64],"eu":[1256880,64],"sh":[1233392,64],"cn":[1300224,64]}], +"actors/mr_i_eyeball/mr_i_eyeball_left_side.rgba16.png": [32,64,4096,{"jp":[1991184,128],"us":[1998560,128],"eu":[1870528,128],"sh":[1847040,128],"cn":[1913872,128]}], +"actors/mr_i_eyeball/mr_i_eyeball_right_side.rgba16.png": [32,64,4096,{"jp":[1991184,4224],"us":[1998560,4224],"eu":[1870528,4224],"sh":[1847040,4224],"cn":[1913872,4224]}], +"actors/mr_i_iris/mr_i_iris_closed.rgba16.png": [32,32,2048,{"jp":[1991184,14704],"us":[1998560,14704],"eu":[1870528,14704],"sh":[1847040,14704],"cn":[1913872,14704]}], +"actors/mr_i_iris/mr_i_iris_mostly_closed.rgba16.png": [32,32,2048,{"jp":[1991184,12656],"us":[1998560,12656],"eu":[1870528,12656],"sh":[1847040,12656],"cn":[1913872,12656]}], +"actors/mr_i_iris/mr_i_iris_mostly_open.rgba16.png": [32,32,2048,{"jp":[1991184,10608],"us":[1998560,10608],"eu":[1870528,10608],"sh":[1847040,10608],"cn":[1913872,10608]}], +"actors/mr_i_iris/mr_i_iris_open.rgba16.png": [32,32,2048,{"jp":[1991184,8560],"us":[1998560,8560],"eu":[1870528,8560],"sh":[1847040,8560],"cn":[1913872,8560]}], +"actors/mushroom_1up/1-up_mushroom.rgba16.png": [32,64,4096,{"jp":[2094912,169512],"us":[2102288,169512],"eu":[1974256,169512],"sh":[1950768,169512],"cn":[2017600,169512]}], +"actors/peach/peach_chest_jewel.rgba16.png": [16,16,512,{"jp":[1490032,11304],"us":[1497200,11304],"eu":[1369168,11304],"sh":[1345680,11304],"cn":[1412512,11304]}], +"actors/peach/peach_crown_jewel.rgba16.png": [16,16,512,{"jp":[1490032,10792],"us":[1497200,10792],"eu":[1369168,10792],"sh":[1345680,10792],"cn":[1412512,10792]}], +"actors/peach/peach_dress.rgba16.png": [32,32,2048,{"jp":[1490032,16424],"us":[1497200,16424],"eu":[1369168,16424],"sh":[1345680,16424],"cn":[1412512,16424]}], +"actors/peach/peach_eye_closed.rgba16.png": [32,32,2048,{"jp":[1490032,8744],"us":[1497200,8744],"eu":[1369168,8744],"sh":[1345680,8744],"cn":[1412512,8744]}], +"actors/peach/peach_eye_mostly_closed.rgba16.png": [32,32,2048,{"jp":[1490032,6696],"us":[1497200,6696],"eu":[1369168,6696],"sh":[1345680,6696],"cn":[1412512,6696]}], +"actors/peach/peach_eye_mostly_open.rgba16.png": [32,32,2048,{"jp":[1490032,4648],"us":[1497200,4648],"eu":[1369168,4648],"sh":[1345680,4648],"cn":[1412512,4648]}], +"actors/peach/peach_eye_open.rgba16.png": [32,32,2048,{"jp":[1490032,2600],"us":[1497200,2600],"eu":[1369168,2600],"sh":[1345680,2600],"cn":[1412512,2600]}], +"actors/peach/peach_lips.rgba16.png": [32,32,2048,{"jp":[1490032,13864],"us":[1497200,13864],"eu":[1369168,13864],"sh":[1345680,13864],"cn":[1412512,13864]}], +"actors/peach/peach_lips_scrunched.rgba16.png": [32,32,2048,{"jp":[1490032,11816],"us":[1497200,11816],"eu":[1369168,11816],"sh":[1345680,11816],"cn":[1412512,11816]}], +"actors/peach/peach_nostril.rgba16.png": [16,16,512,{"jp":[1490032,15912],"us":[1497200,15912],"eu":[1369168,15912],"sh":[1345680,15912],"cn":[1412512,15912]}], +"actors/pebble/pebble.rgba16.png": [32,32,2048,{"jp":[2094912,115456],"us":[2102288,115456],"eu":[1974256,115456],"sh":[1950768,115456],"cn":[2017600,115456]}], +"actors/penguin/penguin_beak.rgba16.png": [32,32,2048,{"jp":[1436272,21984],"us":[1443440,21984],"eu":[1315408,21984],"sh":[1291920,21984],"cn":[1358752,21984]}], +"actors/penguin/penguin_eye_angry.rgba16.png": [32,32,2048,{"jp":[1436272,17888],"us":[1443440,17888],"eu":[1315408,17888],"sh":[1291920,17888],"cn":[1358752,17888]}], +"actors/penguin/penguin_eye_angry_unused.rgba16.png": [32,32,2048,{"jp":[1436272,19936],"us":[1443440,19936],"eu":[1315408,19936],"sh":[1291920,19936],"cn":[1358752,19936]}], +"actors/penguin/penguin_eye_closed.rgba16.png": [32,32,2048,{"jp":[1436272,15840],"us":[1443440,15840],"eu":[1315408,15840],"sh":[1291920,15840],"cn":[1358752,15840]}], +"actors/penguin/penguin_eye_half_closed.rgba16.png": [32,32,2048,{"jp":[1436272,13792],"us":[1443440,13792],"eu":[1315408,13792],"sh":[1291920,13792],"cn":[1358752,13792]}], +"actors/penguin/penguin_eye_open.rgba16.png": [32,32,2048,{"jp":[1436272,11744],"us":[1443440,11744],"eu":[1315408,11744],"sh":[1291920,11744],"cn":[1358752,11744]}], +"actors/piranha_plant/piranha_plant_bottom_lip.rgba16.png": [32,32,2048,{"jp":[1844608,78840],"us":[1851952,78840],"eu":[1723920,78840],"sh":[1700432,78840],"cn":[1767264,78840]}], +"actors/piranha_plant/piranha_plant_leaf.rgba16.png": [32,64,4096,{"jp":[1844608,82936],"us":[1851952,82936],"eu":[1723920,82936],"sh":[1700432,82936],"cn":[1767264,82936]}], +"actors/piranha_plant/piranha_plant_skin.rgba16.png": [32,32,2048,{"jp":[1844608,74744],"us":[1851952,74744],"eu":[1723920,74744],"sh":[1700432,74744],"cn":[1767264,74744]}], +"actors/piranha_plant/piranha_plant_stem.rgba16.png": [32,32,2048,{"jp":[1844608,76792],"us":[1851952,76792],"eu":[1723920,76792],"sh":[1700432,76792],"cn":[1767264,76792]}], +"actors/piranha_plant/piranha_plant_tongue.rgba16.png": [32,64,4096,{"jp":[1599504,148536],"us":[1606720,148536],"eu":[1478688,148536],"sh":[1455200,148536],"cn":[1522032,148536]}], +"actors/piranha_plant/piranha_plant_tooth.rgba16.png": [32,32,2048,{"jp":[1844608,80888],"us":[1851952,80888],"eu":[1723920,80888],"sh":[1700432,80888],"cn":[1767264,80888]}], +"actors/pokey/pokey_body.rgba16.png": [32,32,2048,{"jp":[1327760,75896],"us":[1334928,75896],"eu":[1206896,75896],"sh":[1183408,75896],"cn":[1250240,75896]}], +"actors/pokey/pokey_face.rgba16.png": [32,32,2048,{"jp":[1327760,71504],"us":[1334928,71504],"eu":[1206896,71504],"sh":[1183408,71504],"cn":[1250240,71504]}], +"actors/pokey/pokey_face_blink.rgba16.png": [32,32,2048,{"jp":[1327760,73552],"us":[1334928,73552],"eu":[1206896,73552],"sh":[1183408,73552],"cn":[1250240,73552]}], +"actors/poundable_pole/poundable_pole_side.rgba16.png": [32,32,2048,{"jp":[1844608,6224],"us":[1851952,6224],"eu":[1723920,6224],"sh":[1700432,6224],"cn":[1767264,6224]}], +"actors/poundable_pole/poundable_pole_top.rgba16.png": [32,32,2048,{"jp":[1844608,4176],"us":[1851952,4176],"eu":[1723920,4176],"sh":[1700432,4176],"cn":[1767264,4176]}], +"actors/power_meter/power_meter_five_segments.rgba16.png": [32,32,2048,{"jp":[2094912,158688],"us":[2102288,158688],"eu":[1974256,158688],"sh":[1950768,158688],"cn":[2017600,158688]}], +"actors/power_meter/power_meter_four_segments.rgba16.png": [32,32,2048,{"jp":[2094912,160736],"us":[2102288,160736],"eu":[1974256,160736],"sh":[1950768,160736],"cn":[2017600,160736]}], +"actors/power_meter/power_meter_full.rgba16.png": [32,32,2048,{"jp":[2094912,152544],"us":[2102288,152544],"eu":[1974256,152544],"sh":[1950768,152544],"cn":[2017600,152544]}], "actors/power_meter/power_meter_left_side.rgba16.png": [32,64,4096,{"jp":[2094912,144352],"us":[2102288,144352],"eu":[1974256,144352],"sh":[1950768,144352]}], -"actors/power_meter/power_meter_one_segment.rgba16.png": [32,32,2048,{"jp":[2094912,166880],"us":[2102288,166880],"eu":[1974256,166880],"sh":[1950768,166880]}], +"actors/power_meter/power_meter_left_side_cn.rgba16.png": [32,64,4096,{"cn":[2017600,144352]}], +"actors/power_meter/power_meter_one_segment.rgba16.png": [32,32,2048,{"jp":[2094912,166880],"us":[2102288,166880],"eu":[1974256,166880],"sh":[1950768,166880],"cn":[2017600,166880]}], "actors/power_meter/power_meter_right_side.rgba16.png": [32,64,4096,{"jp":[2094912,148448],"us":[2102288,148448],"eu":[1974256,148448],"sh":[1950768,148448]}], -"actors/power_meter/power_meter_seven_segments.rgba16.png": [32,32,2048,{"jp":[2094912,154592],"us":[2102288,154592],"eu":[1974256,154592],"sh":[1950768,154592]}], -"actors/power_meter/power_meter_six_segments.rgba16.png": [32,32,2048,{"jp":[2094912,156640],"us":[2102288,156640],"eu":[1974256,156640],"sh":[1950768,156640]}], -"actors/power_meter/power_meter_three_segments.rgba16.png": [32,32,2048,{"jp":[2094912,162784],"us":[2102288,162784],"eu":[1974256,162784],"sh":[1950768,162784]}], -"actors/power_meter/power_meter_two_segments.rgba16.png": [32,32,2048,{"jp":[2094912,164832],"us":[2102288,164832],"eu":[1974256,164832],"sh":[1950768,164832]}], -"actors/purple_switch/purple_switch_base.rgba16.png": [16,4,128,{"jp":[2032944,49320],"us":[2040320,49320],"eu":[1912288,49320],"sh":[1888800,49320]}], -"actors/purple_switch/purple_switch_exclamation_point.rgba16.png": [16,32,1024,{"jp":[2032944,49448],"us":[2040320,49448],"eu":[1912288,49448],"sh":[1888800,49448]}], -"actors/sand/sand_particle.rgba16.png": [16,16,512,{"jp":[2094912,178896],"us":[2102288,178896],"eu":[1974256,178896],"sh":[1950768,178896]}], -"actors/scuttlebug/scuttlebug_eye.rgba16.png": [32,32,2048,{"jp":[1991184,65800],"us":[1998560,65800],"eu":[1870528,65800],"sh":[1847040,65800]}], -"actors/scuttlebug/scuttlebug_iris.rgba16.png": [32,32,2048,{"jp":[1991184,76040],"us":[1998560,76040],"eu":[1870528,76040],"sh":[1847040,76040]}], -"actors/scuttlebug/scuttlebug_left_side.rgba16.png": [32,64,4096,{"jp":[1991184,67848],"us":[1998560,67848],"eu":[1870528,67848],"sh":[1847040,67848]}], -"actors/scuttlebug/scuttlebug_leg.rgba16.png": [32,32,2048,{"jp":[1991184,78088],"us":[1998560,78088],"eu":[1870528,78088],"sh":[1847040,78088]}], -"actors/scuttlebug/scuttlebug_right_side.rgba16.png": [32,64,4096,{"jp":[1991184,71944],"us":[1998560,71944],"eu":[1870528,71944],"sh":[1847040,71944]}], -"actors/seaweed/seaweed_base.rgba16.png": [32,32,2048,{"jp":[1802256,38416],"us":[1809600,38416],"eu":[1681568,38416],"sh":[1658080,38416]}], -"actors/seaweed/seaweed_lower_center.rgba16.png": [32,32,2048,{"jp":[1802256,36368],"us":[1809600,36368],"eu":[1681568,36368],"sh":[1658080,36368]}], -"actors/seaweed/seaweed_tip.rgba16.png": [32,32,2048,{"jp":[1802256,32272],"us":[1809600,32272],"eu":[1681568,32272],"sh":[1658080,32272]}], -"actors/seaweed/seaweed_upper_center.rgba16.png": [32,32,2048,{"jp":[1802256,34320],"us":[1809600,34320],"eu":[1681568,34320],"sh":[1658080,34320]}], -"actors/skeeter/skeeter_eye.rgba16.png": [32,32,2048,{"jp":[1802256,144],"us":[1809600,144],"eu":[1681568,144],"sh":[1658080,144]}], -"actors/skeeter/skeeter_iris.rgba16.png": [16,8,256,{"jp":[1802256,2192],"us":[1809600,2192],"eu":[1681568,2192],"sh":[1658080,2192]}], -"actors/smoke/smoke.ia16.png": [32,32,2048,{"jp":[1377744,29376],"us":[1384912,29376],"eu":[1256880,29376],"sh":[1233392,29376]}], -"actors/snowman/mr_blizzard_eye.rgba16.png": [32,32,2048,{"jp":[1436272,46192],"us":[1443440,46192],"eu":[1315408,46192],"sh":[1291920,46192]}], -"actors/snowman/mr_blizzard_left_side.rgba16.png": [32,64,4096,{"jp":[1436272,38000],"us":[1443440,38000],"eu":[1315408,38000],"sh":[1291920,38000]}], -"actors/snowman/mr_blizzard_mitten.rgba16.png": [32,32,2048,{"jp":[1436272,35952],"us":[1443440,35952],"eu":[1315408,35952],"sh":[1291920,35952]}], -"actors/snowman/mr_blizzard_mouth.rgba16.png": [32,32,2048,{"jp":[1436272,48240],"us":[1443440,48240],"eu":[1315408,48240],"sh":[1291920,48240]}], -"actors/snowman/mr_blizzard_right_side.rgba16.png": [32,64,4096,{"jp":[1436272,42096],"us":[1443440,42096],"eu":[1315408,42096],"sh":[1291920,42096]}], -"actors/snufit/snufit_body.rgba16.png": [32,32,2048,{"jp":[1991184,28896],"us":[1998560,28896],"eu":[1870528,28896],"sh":[1847040,28896]}], -"actors/snufit/snufit_eye.rgba16.png": [32,32,2048,{"jp":[1991184,30944],"us":[1998560,30944],"eu":[1870528,30944],"sh":[1847040,30944]}], -"actors/snufit/snufit_mask_strap.rgba16.png": [16,32,1024,{"jp":[1991184,32992],"us":[1998560,32992],"eu":[1870528,32992],"sh":[1847040,32992]}], -"actors/snufit/snufit_mouth.rgba16.png": [32,32,2048,{"jp":[1991184,34016],"us":[1998560,34016],"eu":[1870528,34016],"sh":[1847040,34016]}], -"actors/sparkle/sparkle_0.rgba16.png": [32,32,2048,{"jp":[1125200,160912],"us":[1132368,160912],"eu":[1004336,160912],"sh":[980848,160912]}], -"actors/sparkle/sparkle_1.rgba16.png": [32,32,2048,{"jp":[1125200,162960],"us":[1132368,162960],"eu":[1004336,162960],"sh":[980848,162960]}], -"actors/sparkle/sparkle_2.rgba16.png": [32,32,2048,{"jp":[1125200,165008],"us":[1132368,165008],"eu":[1004336,165008],"sh":[980848,165008]}], -"actors/sparkle/sparkle_3.rgba16.png": [32,32,2048,{"jp":[1125200,167056],"us":[1132368,167056],"eu":[1004336,167056],"sh":[980848,167056]}], -"actors/sparkle/sparkle_4.rgba16.png": [32,32,2048,{"jp":[1125200,169104],"us":[1132368,169104],"eu":[1004336,169104],"sh":[980848,169104]}], -"actors/sparkle/sparkle_5.rgba16.png": [32,32,2048,{"jp":[1125200,171152],"us":[1132368,171152],"eu":[1004336,171152],"sh":[980848,171152]}], -"actors/sparkle_animation/sparkle_animation_0.ia16.png": [32,32,2048,{"jp":[1125200,207496],"us":[1132368,207496],"eu":[1004336,207496],"sh":[980848,207496]}], -"actors/sparkle_animation/sparkle_animation_1.ia16.png": [32,32,2048,{"jp":[1125200,209544],"us":[1132368,209544],"eu":[1004336,209544],"sh":[980848,209544]}], -"actors/sparkle_animation/sparkle_animation_2.ia16.png": [32,32,2048,{"jp":[1125200,211592],"us":[1132368,211592],"eu":[1004336,211592],"sh":[980848,211592]}], -"actors/sparkle_animation/sparkle_animation_3.ia16.png": [32,32,2048,{"jp":[1125200,213640],"us":[1132368,213640],"eu":[1004336,213640],"sh":[980848,213640]}], -"actors/sparkle_animation/sparkle_animation_4.ia16.png": [32,32,2048,{"jp":[1125200,215688],"us":[1132368,215688],"eu":[1004336,215688],"sh":[980848,215688]}], -"actors/spindrift/spindrift_face.rgba16.png": [32,32,2048,{"jp":[1436272,1744],"us":[1443440,1744],"eu":[1315408,1744],"sh":[1291920,1744]}], -"actors/spindrift/spindrift_head.rgba16.png": [32,32,2048,{"jp":[1436272,7888],"us":[1443440,7888],"eu":[1315408,7888],"sh":[1291920,7888]}], -"actors/spindrift/spindrift_leaf.rgba16.png": [32,32,2048,{"jp":[1436272,5840],"us":[1443440,5840],"eu":[1315408,5840],"sh":[1291920,5840]}], -"actors/spindrift/spindrift_petal.rgba16.png": [32,32,2048,{"jp":[1436272,3792],"us":[1443440,3792],"eu":[1315408,3792],"sh":[1291920,3792]}], -"actors/springboard/springboard_base_unused.rgba16.png": [32,32,2048,{"jp":[1457744,2072],"us":[1464912,2072],"eu":[1336880,2072],"sh":[1313392,2072]}], -"actors/springboard/springboard_top_unused.rgba16.png": [32,32,2048,{"jp":[1457744,24],"us":[1464912,24],"eu":[1336880,24],"sh":[1313392,24]}], -"actors/star/star_eye.rgba16.png": [32,32,2048,{"jp":[1568640,31280],"us":[1575856,31280],"eu":[1447824,31280],"sh":[1424336,31280]}], -"actors/star/star_surface.rgba16.png": [32,32,2048,{"jp":[2094912,173808],"us":[2102288,173808],"eu":[1974256,173808],"sh":[1950768,173808]}], -"actors/stomp_smoke/stomp_smoke_0.ia16.png": [32,32,2048,{"jp":[1125200,139592],"us":[1132368,139592],"eu":[1004336,139592],"sh":[980848,139592]}], -"actors/stomp_smoke/stomp_smoke_1.ia16.png": [32,32,2048,{"jp":[1125200,141640],"us":[1132368,141640],"eu":[1004336,141640],"sh":[980848,141640]}], -"actors/stomp_smoke/stomp_smoke_2.ia16.png": [32,32,2048,{"jp":[1125200,143688],"us":[1132368,143688],"eu":[1004336,143688],"sh":[980848,143688]}], -"actors/stomp_smoke/stomp_smoke_3.ia16.png": [32,32,2048,{"jp":[1125200,145736],"us":[1132368,145736],"eu":[1004336,145736],"sh":[980848,145736]}], -"actors/stomp_smoke/stomp_smoke_4.ia16.png": [32,32,2048,{"jp":[1125200,147784],"us":[1132368,147784],"eu":[1004336,147784],"sh":[980848,147784]}], -"actors/stomp_smoke/stomp_smoke_5.ia16.png": [32,32,2048,{"jp":[1125200,149832],"us":[1132368,149832],"eu":[1004336,149832],"sh":[980848,149832]}], -"actors/sushi/sushi_eye.rgba16.png": [32,16,1024,{"jp":[1285392,38608],"us":[1292560,38608],"eu":[1164528,38608],"sh":[1141040,38608]}], -"actors/sushi/sushi_snout.rgba16.png": [32,32,2048,{"jp":[1285392,36560],"us":[1292560,36560],"eu":[1164528,36560],"sh":[1141040,36560]}], -"actors/sushi/sushi_tooth.rgba16.png": [8,8,128,{"jp":[1285392,39632],"us":[1292560,39632],"eu":[1164528,39632],"sh":[1141040,39632]}], -"actors/swoop/swoop_body.rgba16.png": [32,32,2048,{"jp":[1991184,17008],"us":[1998560,17008],"eu":[1870528,17008],"sh":[1847040,17008]}], -"actors/swoop/swoop_eye.rgba16.png": [32,32,2048,{"jp":[1991184,19056],"us":[1998560,19056],"eu":[1870528,19056],"sh":[1847040,19056]}], -"actors/swoop/swoop_nose.rgba16.png": [32,32,2048,{"jp":[1991184,21104],"us":[1998560,21104],"eu":[1870528,21104],"sh":[1847040,21104]}], -"actors/swoop/swoop_wing.rgba16.png": [32,32,2048,{"jp":[1991184,23152],"us":[1998560,23152],"eu":[1870528,23152],"sh":[1847040,23152]}], -"actors/thwomp/thwomp_face.rgba16.png": [32,64,4096,{"jp":[1215456,39168],"us":[1222624,39168],"eu":[1094592,39168],"sh":[1071104,39168]}], -"actors/thwomp/thwomp_surface.rgba16.png": [32,32,2048,{"jp":[1215456,43264],"us":[1222624,43264],"eu":[1094592,43264],"sh":[1071104,43264]}], -"actors/toad/toad_face.rgba16.png": [32,32,2048,{"jp":[1926752,22816],"us":[1934096,22816],"eu":[1806064,22816],"sh":[1782576,22816]}], -"actors/toad/toad_head.rgba16.png": [32,32,2048,{"jp":[1926752,24864],"us":[1934096,24864],"eu":[1806064,24864],"sh":[1782576,24864]}], -"actors/tornado/tornado.ia16.png": [32,64,4096,{"jp":[1285392,75848],"us":[1292560,75848],"eu":[1164528,75848],"sh":[1141040,75848]}], -"actors/treasure_chest/treasure_chest_front.rgba16.png": [64,32,4096,{"jp":[1802256,87976],"us":[1809600,87976],"eu":[1681568,87976],"sh":[1658080,87976]}], -"actors/treasure_chest/treasure_chest_lock.rgba16.png": [32,32,2048,{"jp":[1802256,81832],"us":[1809600,81832],"eu":[1681568,81832],"sh":[1658080,81832]}], -"actors/treasure_chest/treasure_chest_lock_top.rgba16.png": [32,32,2048,{"jp":[1802256,85928],"us":[1809600,85928],"eu":[1681568,85928],"sh":[1658080,85928]}], -"actors/treasure_chest/treasure_chest_side.rgba16.png": [32,32,2048,{"jp":[1802256,83880],"us":[1809600,83880],"eu":[1681568,83880],"sh":[1658080,83880]}], -"actors/tree/palm_tree.rgba16.png": [32,64,4096,{"jp":[2094912,205336],"us":[2102288,205336],"eu":[1974256,205336],"sh":[1950768,205336]}], -"actors/tree/pine_tree.rgba16.png": [32,64,4096,{"jp":[2094912,196448],"us":[2102288,196448],"eu":[1974256,196448],"sh":[1950768,196448]}], -"actors/tree/snowy_pine_tree.rgba16.png": [32,64,4096,{"jp":[2094912,200776],"us":[2102288,200776],"eu":[1974256,200776],"sh":[1950768,200776]}], -"actors/tree/tree_left_side.rgba16.png": [32,64,4096,{"jp":[2094912,187944],"us":[2102288,187944],"eu":[1974256,187944],"sh":[1950768,187944]}], -"actors/tree/tree_right_side.rgba16.png": [32,64,4096,{"jp":[2094912,192040],"us":[2102288,192040],"eu":[1974256,192040],"sh":[1950768,192040]}], -"actors/ukiki/ukiki_butt.rgba16.png": [32,32,2048,{"jp":[1377744,39872],"us":[1384912,39872],"eu":[1256880,39872],"sh":[1233392,39872]}], -"actors/ukiki/ukiki_face.rgba16.png": [64,32,4096,{"jp":[1377744,31680],"us":[1384912,31680],"eu":[1256880,31680],"sh":[1233392,31680]}], -"actors/ukiki/ukiki_face_blink.rgba16.png": [64,32,4096,{"jp":[1377744,35776],"us":[1384912,35776],"eu":[1256880,35776],"sh":[1233392,35776]}], -"actors/ukiki/ukiki_fur.rgba16.png": [32,32,2048,{"jp":[1377744,41920],"us":[1384912,41920],"eu":[1256880,41920],"sh":[1233392,41920]}], -"actors/unagi/unagi_body.rgba16.png": [32,32,2048,{"jp":[1285392,44832],"us":[1292560,44832],"eu":[1164528,44832],"sh":[1141040,44832]}], -"actors/unagi/unagi_eye.rgba16.png": [16,16,512,{"jp":[1285392,46880],"us":[1292560,46880],"eu":[1164528,46880],"sh":[1141040,46880]}], -"actors/unagi/unagi_head_base.rgba16.png": [32,32,2048,{"jp":[1285392,47392],"us":[1292560,47392],"eu":[1164528,47392],"sh":[1141040,47392]}], -"actors/unagi/unagi_mouth.rgba16.png": [8,8,128,{"jp":[1285392,49952],"us":[1292560,49952],"eu":[1164528,49952],"sh":[1141040,49952]}], -"actors/unagi/unagi_tail.rgba16.png": [32,32,2048,{"jp":[1285392,50080],"us":[1292560,50080],"eu":[1164528,50080],"sh":[1141040,50080]}], -"actors/unagi/unagi_tooth.rgba16.png": [16,16,512,{"jp":[1285392,49440],"us":[1292560,49440],"eu":[1164528,49440],"sh":[1141040,49440]}], -"actors/walk_smoke/walk_smoke_0.ia16.png": [32,32,2048,{"jp":[1125200,122528],"us":[1132368,122528],"eu":[1004336,122528],"sh":[980848,122528]}], -"actors/walk_smoke/walk_smoke_1.ia16.png": [32,32,2048,{"jp":[1125200,124576],"us":[1132368,124576],"eu":[1004336,124576],"sh":[980848,124576]}], -"actors/walk_smoke/walk_smoke_2.ia16.png": [32,32,2048,{"jp":[1125200,126624],"us":[1132368,126624],"eu":[1004336,126624],"sh":[980848,126624]}], -"actors/walk_smoke/walk_smoke_3.ia16.png": [32,32,2048,{"jp":[1125200,128672],"us":[1132368,128672],"eu":[1004336,128672],"sh":[980848,128672]}], -"actors/walk_smoke/walk_smoke_4.ia16.png": [32,32,2048,{"jp":[1125200,130720],"us":[1132368,130720],"eu":[1004336,130720],"sh":[980848,130720]}], -"actors/walk_smoke/walk_smoke_5.ia16.png": [32,32,2048,{"jp":[1125200,132768],"us":[1132368,132768],"eu":[1004336,132768],"sh":[980848,132768]}], -"actors/walk_smoke/walk_smoke_6.ia16.png": [32,32,2048,{"jp":[1125200,134816],"us":[1132368,134816],"eu":[1004336,134816],"sh":[980848,134816]}], -"actors/warp_pipe/warp_pipe_side.rgba16.png": [32,64,4096,{"jp":[2094912,32320],"us":[2102288,32320],"eu":[1974256,32320],"sh":[1950768,32320]}], -"actors/warp_pipe/warp_pipe_top.rgba16.png": [32,32,2048,{"jp":[2094912,37224],"us":[2102288,37224],"eu":[1974256,37224],"sh":[1950768,37224]}], -"actors/water_bubble/water_bubble.rgba16.png": [32,32,2048,{"jp":[1257760,65152],"us":[1264928,65152],"eu":[1136896,65152],"sh":[1113408,65152]}], -"actors/water_mine/water_mine_left_side_unused.rgba16.png": [32,64,4096,{"jp":[1599504,359104],"us":[1606720,359440],"eu":[1478688,359440],"sh":[1455200,359440]}], -"actors/water_mine/water_mine_right_side_unused.rgba16.png": [32,64,4096,{"jp":[1599504,363200],"us":[1606720,363536],"eu":[1478688,363536],"sh":[1455200,363536]}], -"actors/water_mine/water_mine_spike_unused.rgba16.png": [32,32,2048,{"jp":[1599504,367296],"us":[1606720,367632],"eu":[1478688,367632],"sh":[1455200,367632]}], -"actors/water_ring/water_ring.rgba16.png": [64,32,4096,{"jp":[1802256,74624],"us":[1809600,74624],"eu":[1681568,74624],"sh":[1658080,74624]}], -"actors/water_splash/water_splash_0.rgba16.png": [32,64,4096,{"jp":[1125200,173512],"us":[1132368,173512],"eu":[1004336,173512],"sh":[980848,173512]}], -"actors/water_splash/water_splash_1.rgba16.png": [32,64,4096,{"jp":[1125200,177608],"us":[1132368,177608],"eu":[1004336,177608],"sh":[980848,177608]}], -"actors/water_splash/water_splash_2.rgba16.png": [32,64,4096,{"jp":[1125200,181704],"us":[1132368,181704],"eu":[1004336,181704],"sh":[980848,181704]}], -"actors/water_splash/water_splash_3.rgba16.png": [32,64,4096,{"jp":[1125200,185800],"us":[1132368,185800],"eu":[1004336,185800],"sh":[980848,185800]}], -"actors/water_splash/water_splash_4.rgba16.png": [32,64,4096,{"jp":[1125200,189896],"us":[1132368,189896],"eu":[1004336,189896],"sh":[980848,189896]}], -"actors/water_splash/water_splash_5.rgba16.png": [32,64,4096,{"jp":[1125200,193992],"us":[1132368,193992],"eu":[1004336,193992],"sh":[980848,193992]}], -"actors/water_splash/water_splash_6.rgba16.png": [32,64,4096,{"jp":[1125200,198088],"us":[1132368,198088],"eu":[1004336,198088],"sh":[980848,198088]}], -"actors/water_splash/water_splash_7.rgba16.png": [32,64,4096,{"jp":[1125200,202184],"us":[1132368,202184],"eu":[1004336,202184],"sh":[980848,202184]}], -"actors/water_wave/water_wave_0.ia16.png": [32,32,2048,{"jp":[1125200,152408],"us":[1132368,152408],"eu":[1004336,152408],"sh":[980848,152408]}], -"actors/water_wave/water_wave_1.ia16.png": [32,32,2048,{"jp":[1125200,154456],"us":[1132368,154456],"eu":[1004336,154456],"sh":[980848,154456]}], -"actors/water_wave/water_wave_2.ia16.png": [32,32,2048,{"jp":[1125200,156504],"us":[1132368,156504],"eu":[1004336,156504],"sh":[980848,156504]}], -"actors/water_wave/water_wave_3.ia16.png": [32,32,2048,{"jp":[1125200,158552],"us":[1132368,158552],"eu":[1004336,158552],"sh":[980848,158552]}], -"actors/whirlpool/whirlpool.ia16.png": [32,64,4096,{"jp":[1285392,75848],"us":[1292560,75848],"eu":[1164528,75848],"sh":[1141040,75848]}], -"actors/white_particle/snow_particle.rgba16.png": [16,16,512,{"jp":[2094912,181920],"us":[2102288,181920],"eu":[1974256,181920],"sh":[1950768,181920]}], -"actors/white_particle_small/small_snow_particle.rgba16.png": [16,16,512,{"jp":[1125200,206720],"us":[1132368,206720],"eu":[1004336,206720],"sh":[980848,206720]}], -"actors/whomp/whomp_back.rgba16.png": [32,64,4096,{"jp":[1844608,115552],"us":[1851952,115552],"eu":[1723920,115552],"sh":[1700432,115552]}], -"actors/whomp/whomp_face.rgba16.png": [32,64,4096,{"jp":[1844608,119648],"us":[1851952,119648],"eu":[1723920,119648],"sh":[1700432,119648]}], -"actors/whomp/whomp_hand.rgba16.png": [32,32,2048,{"jp":[1844608,123744],"us":[1851952,123744],"eu":[1723920,123744],"sh":[1700432,123744]}], -"actors/whomp/whomp_surface.rgba16.png": [32,32,2048,{"jp":[1844608,125792],"us":[1851952,125792],"eu":[1723920,125792],"sh":[1700432,125792]}], -"actors/wiggler/wiggler_eye.rgba16.png": [32,32,2048,{"jp":[1568640,31280],"us":[1575856,31280],"eu":[1447824,31280],"sh":[1424336,31280]}], -"actors/wiggler/wiggler_flower.rgba16.png": [32,32,2048,{"jp":[1568640,33328],"us":[1575856,33328],"eu":[1447824,33328],"sh":[1424336,33328]}], -"actors/wiggler/wiggler_frown.rgba16.png": [32,32,2048,{"jp":[1568640,35376],"us":[1575856,35376],"eu":[1447824,35376],"sh":[1424336,35376]}], -"actors/wiggler/wiggler_nose_left_side.rgba16.png": [32,64,4096,{"jp":[1568640,37424],"us":[1575856,37424],"eu":[1447824,37424],"sh":[1424336,37424]}], -"actors/wiggler/wiggler_nose_right_side.rgba16.png": [32,64,4096,{"jp":[1568640,41520],"us":[1575856,41520],"eu":[1447824,41520],"sh":[1424336,41520]}], -"actors/wiggler/wiggler_segment_left_side.rgba16.png": [32,64,4096,{"jp":[1568640,23088],"us":[1575856,23088],"eu":[1447824,23088],"sh":[1424336,23088]}], -"actors/wiggler/wiggler_segment_right_side.rgba16.png": [32,64,4096,{"jp":[1568640,27184],"us":[1575856,27184],"eu":[1447824,27184],"sh":[1424336,27184]}], -"actors/wooden_signpost/wooden_signpost_back.rgba16.png": [32,32,2048,{"jp":[2094912,182728],"us":[2102288,182728],"eu":[1974256,182728],"sh":[1950768,182728]}], -"actors/wooden_signpost/wooden_signpost_front.rgba16.png": [32,32,2048,{"jp":[2094912,184776],"us":[2102288,184776],"eu":[1974256,184776],"sh":[1950768,184776]}], -"actors/yellow_sphere/yellow_sphere.rgba16.png": [32,32,2048,{"jp":[1215456,64],"us":[1222624,64],"eu":[1094592,64],"sh":[1071104,64]}], -"actors/yellow_sphere_small/small_yellow_sphere.rgba16.png": [32,32,2048,{"jp":[1215456,64],"us":[1222624,64],"eu":[1094592,64],"sh":[1071104,64]}], -"actors/yoshi/yoshi_eye.rgba16.png": [16,16,512,{"jp":[1490032,115872],"us":[1497200,116104],"eu":[1369168,116104],"sh":[1345680,116104]}], -"actors/yoshi/yoshi_eye_blink.rgba16.png": [16,16,512,{"jp":[1490032,116384],"us":[1497200,116616],"eu":[1369168,116616],"sh":[1345680,116616]}], -"actors/yoshi/yoshi_nostril.rgba16.png": [16,16,512,{"jp":[1490032,116896],"us":[1497200,117128],"eu":[1369168,117128],"sh":[1345680,117128]}], -"actors/yoshi_egg/yoshi_egg_0_unused.rgba16.png": [32,32,2048,{"jp":[1215456,22456],"us":[1222624,22456],"eu":[1094592,22456],"sh":[1071104,22456]}], -"actors/yoshi_egg/yoshi_egg_1_unused.rgba16.png": [32,32,2048,{"jp":[1215456,24504],"us":[1222624,24504],"eu":[1094592,24504],"sh":[1071104,24504]}], -"actors/yoshi_egg/yoshi_egg_2_unused.rgba16.png": [32,32,2048,{"jp":[1215456,26552],"us":[1222624,26552],"eu":[1094592,26552],"sh":[1071104,26552]}], -"actors/yoshi_egg/yoshi_egg_3_unused.rgba16.png": [32,32,2048,{"jp":[1215456,28600],"us":[1222624,28600],"eu":[1094592,28600],"sh":[1071104,28600]}], -"actors/yoshi_egg/yoshi_egg_4_unused.rgba16.png": [32,32,2048,{"jp":[1215456,30648],"us":[1222624,30648],"eu":[1094592,30648],"sh":[1071104,30648]}], -"actors/yoshi_egg/yoshi_egg_5_unused.rgba16.png": [32,32,2048,{"jp":[1215456,32696],"us":[1222624,32696],"eu":[1094592,32696],"sh":[1071104,32696]}], -"actors/yoshi_egg/yoshi_egg_6_unused.rgba16.png": [32,32,2048,{"jp":[1215456,34744],"us":[1222624,34744],"eu":[1094592,34744],"sh":[1071104,34744]}], -"actors/yoshi_egg/yoshi_egg_7_unused.rgba16.png": [32,32,2048,{"jp":[1215456,36792],"us":[1222624,36792],"eu":[1094592,36792],"sh":[1071104,36792]}], -"assets/demos/bbh.bin": [988,{"jp":[5733368],"us":[5741664],"eu":[5620584],"sh":[5589632]}], -"assets/demos/bitdw.bin": [1412,{"us":[5747100],"sh":[5595068]}], -"assets/demos/ccm.bin": [1320,{"jp":[5734356],"us":[5742652],"eu":[5621572],"sh":[5590620]}], -"assets/demos/hmc.bin": [980,{"jp":[5735676],"us":[5743972],"eu":[5622892],"sh":[5591940]}], -"assets/demos/jrb.bin": [620,{"jp":[5736656],"us":[5744952],"eu":[5623872],"sh":[5592920]}], -"assets/demos/pss.bin": [748,{"jp":[5737948],"us":[5746244],"eu":[5625164],"sh":[5594212]}], -"assets/demos/unused.bin": [108,{"jp":[5738696],"us":[5746992],"eu":[5625912],"sh":[5594960]}], -"assets/demos/wf.bin": [672,{"jp":[5737276],"us":[5745572],"eu":[5624492],"sh":[5593540]}], -"levels/bbh/0.rgba16.png": [32,64,4096,{"jp":[3604960,0],"us":[3611712,0],"eu":[3485312,0],"sh":[3459680,0]}], -"levels/bbh/1.rgba16.png": [32,32,2048,{"jp":[3604960,4096],"us":[3611712,4096],"eu":[3485312,4096],"sh":[3459680,4096]}], -"levels/bbh/2.rgba16.png": [32,32,2048,{"jp":[3604960,6144],"us":[3611712,6144],"eu":[3485312,6144],"sh":[3459680,6144]}], -"levels/bbh/3.rgba16.png": [32,64,4096,{"jp":[3604960,8192],"us":[3611712,8192],"eu":[3485312,8192],"sh":[3459680,8192]}], -"levels/bbh/4.rgba16.png": [16,32,1024,{"jp":[3604960,12288],"us":[3611712,12288],"eu":[3485312,12288],"sh":[3459680,12288]}], -"levels/bbh/5.rgba16.png": [32,64,4096,{"jp":[3604960,13312],"us":[3611712,13312],"eu":[3485312,13312],"sh":[3459680,13312]}], -"levels/bbh/6.rgba16.png": [16,32,1024,{"jp":[3604960,17408],"us":[3611712,17408],"eu":[3485312,17408],"sh":[3459680,17408]}], -"levels/bitdw/0.rgba16.png": [32,32,2048,{"jp":[4533568,0],"us":[4541952,0],"eu":[4415552,0],"sh":[4389920,0]}], -"levels/bitdw/1.rgba16.png": [32,32,2048,{"jp":[4533568,2048],"us":[4541952,2048],"eu":[4415552,2048],"sh":[4389920,2048]}], -"levels/bitdw/2.rgba16.png": [32,32,2048,{"jp":[4533568,4096],"us":[4541952,4096],"eu":[4415552,4096],"sh":[4389920,4096]}], -"levels/bitdw/3.rgba16.png": [32,32,2048,{"jp":[4533568,6144],"us":[4541952,6144],"eu":[4415552,6144],"sh":[4389920,6144]}], -"levels/bitfs/0.rgba16.png": [32,64,4096,{"jp":[4584464,0],"us":[4592848,0],"eu":[4466448,0],"sh":[4440816,0]}], -"levels/bitfs/1.rgba16.png": [32,32,2048,{"jp":[4584464,4096],"us":[4592848,4096],"eu":[4466448,4096],"sh":[4440816,4096]}], -"levels/bitfs/2.rgba16.png": [32,32,2048,{"jp":[4584464,6144],"us":[4592848,6144],"eu":[4466448,6144],"sh":[4440816,6144]}], -"levels/bits/0.rgba16.png": [32,64,4096,{"jp":[4629216,0],"us":[4637600,0],"eu":[4511200,0],"sh":[4485568,0]}], -"levels/bits/1.rgba16.png": [64,32,4096,{"jp":[4629216,4096],"us":[4637600,4096],"eu":[4511200,4096],"sh":[4485568,4096]}], -"levels/bits/2.rgba16.png": [32,32,2048,{"jp":[4629216,8192],"us":[4637600,8192],"eu":[4511200,8192],"sh":[4485568,8192]}], -"levels/bob/0.rgba16.png": [32,32,2048,{"jp":[4170512,0],"us":[4178608,0],"eu":[4052208,0],"sh":[4026576,0]}], -"levels/bob/1.rgba16.png": [32,32,2048,{"jp":[4170512,2048],"us":[4178608,2048],"eu":[4052208,2048],"sh":[4026576,2048]}], -"levels/bob/2.rgba16.png": [32,32,2048,{"jp":[4170512,4096],"us":[4178608,4096],"eu":[4052208,4096],"sh":[4026576,4096]}], -"levels/bob/3.rgba16.png": [32,32,2048,{"jp":[4170512,6144],"us":[4178608,6144],"eu":[4052208,6144],"sh":[4026576,6144]}], -"levels/bob/4.rgba16.png": [32,32,2048,{"jp":[4170512,8192],"us":[4178608,8192],"eu":[4052208,8192],"sh":[4026576,8192]}], -"levels/bowser_1/0.rgba16.png": [32,64,4096,{"jp":[4982976,0],"us":[4991264,0],"eu":[4870192,0],"sh":[4839232,0]}], -"levels/bowser_1/1.rgba16.png": [32,32,2048,{"jp":[4982976,4096],"us":[4991264,4096],"eu":[4870192,4096],"sh":[4839232,4096]}], -"levels/bowser_1/2.rgba16.png": [32,32,2048,{"jp":[4982976,6144],"us":[4991264,6144],"eu":[4870192,6144],"sh":[4839232,6144]}], -"levels/bowser_2/0.rgba16.png": [32,32,2048,{"jp":[5028720,0],"us":[5037008,0],"eu":[4915936,0],"sh":[4884976,0]}], -"levels/bowser_3/0.rgba16.png": [32,32,2048,{"jp":[5032864,0],"us":[5041152,0],"eu":[4920080,0],"sh":[4889120,0]}], -"levels/bowser_3/1.rgba16.png": [32,32,2048,{"jp":[5032864,2048],"us":[5041152,2048],"eu":[4920080,2048],"sh":[4889120,2048]}], -"levels/bowser_3/2.rgba16.png": [32,64,4096,{"jp":[5032864,4096],"us":[5041152,4096],"eu":[4920080,4096],"sh":[4889120,4096]}], -"levels/castle_grounds/0.rgba16.png": [32,64,4096,{"jp":[4492416,0],"us":[4500416,0],"eu":[4374016,0],"sh":[4348384,0]}], -"levels/castle_grounds/1.rgba16.png": [64,32,4096,{"jp":[4492416,4096],"us":[4500416,4096],"eu":[4374016,4096],"sh":[4348384,4096]}], -"levels/castle_grounds/2.rgba16.png": [64,32,4096,{"jp":[4492416,8192],"us":[4500416,8192],"eu":[4374016,8192],"sh":[4348384,8192]}], -"levels/castle_grounds/3.rgba16.png": [32,64,4096,{"jp":[4492416,51688],"us":[4500416,51688],"eu":[4374016,51688],"sh":[4348384,51688]}], -"levels/castle_grounds/4.rgba16.png": [32,64,4096,{"jp":[4492416,55784],"us":[4500416,55784],"eu":[4374016,55784],"sh":[4348384,55784]}], -"levels/castle_grounds/5.ia8.png": [64,32,2048,{"us":[4500416,60136],"eu":[4374016,60136],"sh":[4348384,60136]}], -"levels/castle_inside/1.rgba16.png": [32,32,2048,{"jp":[3754192,2048],"us":[3760960,2048],"eu":[3634560,2048],"sh":[3608928,2048]}], -"levels/castle_inside/10.rgba16.png": [32,32,2048,{"jp":[3754192,28672],"us":[3760960,28672],"eu":[3634560,28672],"sh":[3608928,28672]}], -"levels/castle_inside/11.rgba16.png": [32,32,2048,{"jp":[3754192,30720],"us":[3760960,30720],"eu":[3634560,30720],"sh":[3608928,30720]}], -"levels/castle_inside/12.rgba16.png": [32,32,2048,{"jp":[3754192,32768],"us":[3760960,32768],"eu":[3634560,32768],"sh":[3608928,32768]}], -"levels/castle_inside/13.rgba16.png": [32,32,2048,{"jp":[3754192,34816],"us":[3760960,34816],"eu":[3634560,34816],"sh":[3608928,34816]}], -"levels/castle_inside/14.rgba16.png": [32,32,2048,{"jp":[3754192,36864],"us":[3760960,36864],"eu":[3634560,36864],"sh":[3608928,36864]}], -"levels/castle_inside/15.rgba16.png": [32,32,2048,{"jp":[3754192,38912],"us":[3760960,38912],"eu":[3634560,38912],"sh":[3608928,38912]}], -"levels/castle_inside/16.ia16.png": [32,32,2048,{"jp":[3754192,40960],"us":[3760960,40960],"eu":[3634560,40960],"sh":[3608928,40960]}], -"levels/castle_inside/17.rgba16.png": [64,32,4096,{"jp":[3754192,43008],"us":[3760960,43008],"eu":[3634560,43008],"sh":[3608928,43008]}], -"levels/castle_inside/18.rgba16.png": [64,32,4096,{"jp":[3754192,47104],"us":[3760960,47104],"eu":[3634560,47104],"sh":[3608928,47104]}], -"levels/castle_inside/19.rgba16.png": [64,32,4096,{"jp":[3754192,51200],"us":[3760960,51200],"eu":[3634560,51200],"sh":[3608928,51200]}], -"levels/castle_inside/2.ia16.png": [32,64,4096,{"jp":[3298272,47104],"us":[3305024,47104],"eu":[3178624,47104],"sh":[3152992,47104]}], -"levels/castle_inside/20.rgba16.png": [64,32,4096,{"jp":[3754192,55296],"us":[3760960,55296],"eu":[3634560,55296],"sh":[3608928,55296]}], -"levels/castle_inside/21.rgba16.png": [64,32,4096,{"jp":[3754192,59392],"us":[3760960,59392],"eu":[3634560,59392],"sh":[3608928,59392]}], -"levels/castle_inside/22.rgba16.png": [64,32,4096,{"jp":[3754192,63488],"us":[3760960,63488],"eu":[3634560,63488],"sh":[3608928,63488]}], +"actors/power_meter/power_meter_right_side_cn.rgba16.png": [32,64,4096,{"cn":[2017600,148448]}], +"actors/power_meter/power_meter_seven_segments.rgba16.png": [32,32,2048,{"jp":[2094912,154592],"us":[2102288,154592],"eu":[1974256,154592],"sh":[1950768,154592],"cn":[2017600,154592]}], +"actors/power_meter/power_meter_six_segments.rgba16.png": [32,32,2048,{"jp":[2094912,156640],"us":[2102288,156640],"eu":[1974256,156640],"sh":[1950768,156640],"cn":[2017600,156640]}], +"actors/power_meter/power_meter_three_segments.rgba16.png": [32,32,2048,{"jp":[2094912,162784],"us":[2102288,162784],"eu":[1974256,162784],"sh":[1950768,162784],"cn":[2017600,162784]}], +"actors/power_meter/power_meter_two_segments.rgba16.png": [32,32,2048,{"jp":[2094912,164832],"us":[2102288,164832],"eu":[1974256,164832],"sh":[1950768,164832],"cn":[2017600,164832]}], +"actors/purple_switch/purple_switch_base.rgba16.png": [16,4,128,{"jp":[2032944,49320],"us":[2040320,49320],"eu":[1912288,49320],"sh":[1888800,49320],"cn":[1955632,49320]}], +"actors/purple_switch/purple_switch_exclamation_point.rgba16.png": [16,32,1024,{"jp":[2032944,49448],"us":[2040320,49448],"eu":[1912288,49448],"sh":[1888800,49448],"cn":[1955632,49448]}], +"actors/sand/sand_particle.rgba16.png": [16,16,512,{"jp":[2094912,178896],"us":[2102288,178896],"eu":[1974256,178896],"sh":[1950768,178896],"cn":[2017600,178896]}], +"actors/scuttlebug/scuttlebug_eye.rgba16.png": [32,32,2048,{"jp":[1991184,65800],"us":[1998560,65800],"eu":[1870528,65800],"sh":[1847040,65800],"cn":[1913872,65800]}], +"actors/scuttlebug/scuttlebug_iris.rgba16.png": [32,32,2048,{"jp":[1991184,76040],"us":[1998560,76040],"eu":[1870528,76040],"sh":[1847040,76040],"cn":[1913872,76040]}], +"actors/scuttlebug/scuttlebug_left_side.rgba16.png": [32,64,4096,{"jp":[1991184,67848],"us":[1998560,67848],"eu":[1870528,67848],"sh":[1847040,67848],"cn":[1913872,67848]}], +"actors/scuttlebug/scuttlebug_leg.rgba16.png": [32,32,2048,{"jp":[1991184,78088],"us":[1998560,78088],"eu":[1870528,78088],"sh":[1847040,78088],"cn":[1913872,78088]}], +"actors/scuttlebug/scuttlebug_right_side.rgba16.png": [32,64,4096,{"jp":[1991184,71944],"us":[1998560,71944],"eu":[1870528,71944],"sh":[1847040,71944],"cn":[1913872,71944]}], +"actors/seaweed/seaweed_base.rgba16.png": [32,32,2048,{"jp":[1802256,38416],"us":[1809600,38416],"eu":[1681568,38416],"sh":[1658080,38416],"cn":[1724912,38416]}], +"actors/seaweed/seaweed_lower_center.rgba16.png": [32,32,2048,{"jp":[1802256,36368],"us":[1809600,36368],"eu":[1681568,36368],"sh":[1658080,36368],"cn":[1724912,36368]}], +"actors/seaweed/seaweed_tip.rgba16.png": [32,32,2048,{"jp":[1802256,32272],"us":[1809600,32272],"eu":[1681568,32272],"sh":[1658080,32272],"cn":[1724912,32272]}], +"actors/seaweed/seaweed_upper_center.rgba16.png": [32,32,2048,{"jp":[1802256,34320],"us":[1809600,34320],"eu":[1681568,34320],"sh":[1658080,34320],"cn":[1724912,34320]}], +"actors/skeeter/skeeter_eye.rgba16.png": [32,32,2048,{"jp":[1802256,144],"us":[1809600,144],"eu":[1681568,144],"sh":[1658080,144],"cn":[1724912,144]}], +"actors/skeeter/skeeter_iris.rgba16.png": [16,8,256,{"jp":[1802256,2192],"us":[1809600,2192],"eu":[1681568,2192],"sh":[1658080,2192],"cn":[1724912,2192]}], +"actors/smoke/smoke.ia16.png": [32,32,2048,{"jp":[1377744,29376],"us":[1384912,29376],"eu":[1256880,29376],"sh":[1233392,29376],"cn":[1300224,29376]}], +"actors/snowman/mr_blizzard_eye.rgba16.png": [32,32,2048,{"jp":[1436272,46192],"us":[1443440,46192],"eu":[1315408,46192],"sh":[1291920,46192],"cn":[1358752,46192]}], +"actors/snowman/mr_blizzard_left_side.rgba16.png": [32,64,4096,{"jp":[1436272,38000],"us":[1443440,38000],"eu":[1315408,38000],"sh":[1291920,38000],"cn":[1358752,38000]}], +"actors/snowman/mr_blizzard_mitten.rgba16.png": [32,32,2048,{"jp":[1436272,35952],"us":[1443440,35952],"eu":[1315408,35952],"sh":[1291920,35952],"cn":[1358752,35952]}], +"actors/snowman/mr_blizzard_mouth.rgba16.png": [32,32,2048,{"jp":[1436272,48240],"us":[1443440,48240],"eu":[1315408,48240],"sh":[1291920,48240],"cn":[1358752,48240]}], +"actors/snowman/mr_blizzard_right_side.rgba16.png": [32,64,4096,{"jp":[1436272,42096],"us":[1443440,42096],"eu":[1315408,42096],"sh":[1291920,42096],"cn":[1358752,42096]}], +"actors/snufit/snufit_body.rgba16.png": [32,32,2048,{"jp":[1991184,28896],"us":[1998560,28896],"eu":[1870528,28896],"sh":[1847040,28896],"cn":[1913872,28896]}], +"actors/snufit/snufit_eye.rgba16.png": [32,32,2048,{"jp":[1991184,30944],"us":[1998560,30944],"eu":[1870528,30944],"sh":[1847040,30944],"cn":[1913872,30944]}], +"actors/snufit/snufit_mask_strap.rgba16.png": [16,32,1024,{"jp":[1991184,32992],"us":[1998560,32992],"eu":[1870528,32992],"sh":[1847040,32992],"cn":[1913872,32992]}], +"actors/snufit/snufit_mouth.rgba16.png": [32,32,2048,{"jp":[1991184,34016],"us":[1998560,34016],"eu":[1870528,34016],"sh":[1847040,34016],"cn":[1913872,34016]}], +"actors/sparkle/sparkle_0.rgba16.png": [32,32,2048,{"jp":[1125200,160912],"us":[1132368,160912],"eu":[1004336,160912],"sh":[980848,160912],"cn":[1047664,160912]}], +"actors/sparkle/sparkle_1.rgba16.png": [32,32,2048,{"jp":[1125200,162960],"us":[1132368,162960],"eu":[1004336,162960],"sh":[980848,162960],"cn":[1047664,162960]}], +"actors/sparkle/sparkle_2.rgba16.png": [32,32,2048,{"jp":[1125200,165008],"us":[1132368,165008],"eu":[1004336,165008],"sh":[980848,165008],"cn":[1047664,165008]}], +"actors/sparkle/sparkle_3.rgba16.png": [32,32,2048,{"jp":[1125200,167056],"us":[1132368,167056],"eu":[1004336,167056],"sh":[980848,167056],"cn":[1047664,167056]}], +"actors/sparkle/sparkle_4.rgba16.png": [32,32,2048,{"jp":[1125200,169104],"us":[1132368,169104],"eu":[1004336,169104],"sh":[980848,169104],"cn":[1047664,169104]}], +"actors/sparkle/sparkle_5.rgba16.png": [32,32,2048,{"jp":[1125200,171152],"us":[1132368,171152],"eu":[1004336,171152],"sh":[980848,171152],"cn":[1047664,171152]}], +"actors/sparkle_animation/sparkle_animation_0.ia16.png": [32,32,2048,{"jp":[1125200,207496],"us":[1132368,207496],"eu":[1004336,207496],"sh":[980848,207496],"cn":[1047664,207496]}], +"actors/sparkle_animation/sparkle_animation_1.ia16.png": [32,32,2048,{"jp":[1125200,209544],"us":[1132368,209544],"eu":[1004336,209544],"sh":[980848,209544],"cn":[1047664,209544]}], +"actors/sparkle_animation/sparkle_animation_2.ia16.png": [32,32,2048,{"jp":[1125200,211592],"us":[1132368,211592],"eu":[1004336,211592],"sh":[980848,211592],"cn":[1047664,211592]}], +"actors/sparkle_animation/sparkle_animation_3.ia16.png": [32,32,2048,{"jp":[1125200,213640],"us":[1132368,213640],"eu":[1004336,213640],"sh":[980848,213640],"cn":[1047664,213640]}], +"actors/sparkle_animation/sparkle_animation_4.ia16.png": [32,32,2048,{"jp":[1125200,215688],"us":[1132368,215688],"eu":[1004336,215688],"sh":[980848,215688],"cn":[1047664,215688]}], +"actors/spindrift/spindrift_face.rgba16.png": [32,32,2048,{"jp":[1436272,1744],"us":[1443440,1744],"eu":[1315408,1744],"sh":[1291920,1744],"cn":[1358752,1744]}], +"actors/spindrift/spindrift_head.rgba16.png": [32,32,2048,{"jp":[1436272,7888],"us":[1443440,7888],"eu":[1315408,7888],"sh":[1291920,7888],"cn":[1358752,7888]}], +"actors/spindrift/spindrift_leaf.rgba16.png": [32,32,2048,{"jp":[1436272,5840],"us":[1443440,5840],"eu":[1315408,5840],"sh":[1291920,5840],"cn":[1358752,5840]}], +"actors/spindrift/spindrift_petal.rgba16.png": [32,32,2048,{"jp":[1436272,3792],"us":[1443440,3792],"eu":[1315408,3792],"sh":[1291920,3792],"cn":[1358752,3792]}], +"actors/springboard/springboard_base_unused.rgba16.png": [32,32,2048,{"jp":[1457744,2072],"us":[1464912,2072],"eu":[1336880,2072],"sh":[1313392,2072],"cn":[1380224,2072]}], +"actors/springboard/springboard_top_unused.rgba16.png": [32,32,2048,{"jp":[1457744,24],"us":[1464912,24],"eu":[1336880,24],"sh":[1313392,24],"cn":[1380224,24]}], +"actors/star/star_eye.rgba16.png": [32,32,2048,{"jp":[1568640,31280],"us":[1575856,31280],"eu":[1447824,31280],"sh":[1424336,31280],"cn":[1491168,31280]}], +"actors/star/star_surface.rgba16.png": [32,32,2048,{"jp":[2094912,173808],"us":[2102288,173808],"eu":[1974256,173808],"sh":[1950768,173808],"cn":[2017600,173808]}], +"actors/stomp_smoke/stomp_smoke_0.ia16.png": [32,32,2048,{"jp":[1125200,139592],"us":[1132368,139592],"eu":[1004336,139592],"sh":[980848,139592],"cn":[1047664,139592]}], +"actors/stomp_smoke/stomp_smoke_1.ia16.png": [32,32,2048,{"jp":[1125200,141640],"us":[1132368,141640],"eu":[1004336,141640],"sh":[980848,141640],"cn":[1047664,141640]}], +"actors/stomp_smoke/stomp_smoke_2.ia16.png": [32,32,2048,{"jp":[1125200,143688],"us":[1132368,143688],"eu":[1004336,143688],"sh":[980848,143688],"cn":[1047664,143688]}], +"actors/stomp_smoke/stomp_smoke_3.ia16.png": [32,32,2048,{"jp":[1125200,145736],"us":[1132368,145736],"eu":[1004336,145736],"sh":[980848,145736],"cn":[1047664,145736]}], +"actors/stomp_smoke/stomp_smoke_4.ia16.png": [32,32,2048,{"jp":[1125200,147784],"us":[1132368,147784],"eu":[1004336,147784],"sh":[980848,147784],"cn":[1047664,147784]}], +"actors/stomp_smoke/stomp_smoke_5.ia16.png": [32,32,2048,{"jp":[1125200,149832],"us":[1132368,149832],"eu":[1004336,149832],"sh":[980848,149832],"cn":[1047664,149832]}], +"actors/sushi/sushi_eye.rgba16.png": [32,16,1024,{"jp":[1285392,38608],"us":[1292560,38608],"eu":[1164528,38608],"sh":[1141040,38608],"cn":[1207872,38608]}], +"actors/sushi/sushi_snout.rgba16.png": [32,32,2048,{"jp":[1285392,36560],"us":[1292560,36560],"eu":[1164528,36560],"sh":[1141040,36560],"cn":[1207872,36560]}], +"actors/sushi/sushi_tooth.rgba16.png": [8,8,128,{"jp":[1285392,39632],"us":[1292560,39632],"eu":[1164528,39632],"sh":[1141040,39632],"cn":[1207872,39632]}], +"actors/swoop/swoop_body.rgba16.png": [32,32,2048,{"jp":[1991184,17008],"us":[1998560,17008],"eu":[1870528,17008],"sh":[1847040,17008],"cn":[1913872,17008]}], +"actors/swoop/swoop_eye.rgba16.png": [32,32,2048,{"jp":[1991184,19056],"us":[1998560,19056],"eu":[1870528,19056],"sh":[1847040,19056],"cn":[1913872,19056]}], +"actors/swoop/swoop_nose.rgba16.png": [32,32,2048,{"jp":[1991184,21104],"us":[1998560,21104],"eu":[1870528,21104],"sh":[1847040,21104],"cn":[1913872,21104]}], +"actors/swoop/swoop_wing.rgba16.png": [32,32,2048,{"jp":[1991184,23152],"us":[1998560,23152],"eu":[1870528,23152],"sh":[1847040,23152],"cn":[1913872,23152]}], +"actors/thwomp/thwomp_face.rgba16.png": [32,64,4096,{"jp":[1215456,39168],"us":[1222624,39168],"eu":[1094592,39168],"sh":[1071104,39168],"cn":[1137936,39168]}], +"actors/thwomp/thwomp_surface.rgba16.png": [32,32,2048,{"jp":[1215456,43264],"us":[1222624,43264],"eu":[1094592,43264],"sh":[1071104,43264],"cn":[1137936,43264]}], +"actors/toad/toad_face.rgba16.png": [32,32,2048,{"jp":[1926752,22816],"us":[1934096,22816],"eu":[1806064,22816],"sh":[1782576,22816],"cn":[1849408,22816]}], +"actors/toad/toad_head.rgba16.png": [32,32,2048,{"jp":[1926752,24864],"us":[1934096,24864],"eu":[1806064,24864],"sh":[1782576,24864],"cn":[1849408,24864]}], +"actors/tornado/tornado.ia16.png": [32,64,4096,{"jp":[1285392,75848],"us":[1292560,75848],"eu":[1164528,75848],"sh":[1141040,75848],"cn":[1207872,75848]}], +"actors/treasure_chest/treasure_chest_front.rgba16.png": [64,32,4096,{"jp":[1802256,87976],"us":[1809600,87976],"eu":[1681568,87976],"sh":[1658080,87976],"cn":[1724912,87976]}], +"actors/treasure_chest/treasure_chest_lock.rgba16.png": [32,32,2048,{"jp":[1802256,81832],"us":[1809600,81832],"eu":[1681568,81832],"sh":[1658080,81832],"cn":[1724912,81832]}], +"actors/treasure_chest/treasure_chest_lock_top.rgba16.png": [32,32,2048,{"jp":[1802256,85928],"us":[1809600,85928],"eu":[1681568,85928],"sh":[1658080,85928],"cn":[1724912,85928]}], +"actors/treasure_chest/treasure_chest_side.rgba16.png": [32,32,2048,{"jp":[1802256,83880],"us":[1809600,83880],"eu":[1681568,83880],"sh":[1658080,83880],"cn":[1724912,83880]}], +"actors/tree/palm_tree.rgba16.png": [32,64,4096,{"jp":[2094912,205336],"us":[2102288,205336],"eu":[1974256,205336],"sh":[1950768,205336],"cn":[2017600,205336]}], +"actors/tree/pine_tree.rgba16.png": [32,64,4096,{"jp":[2094912,196448],"us":[2102288,196448],"eu":[1974256,196448],"sh":[1950768,196448],"cn":[2017600,196448]}], +"actors/tree/snowy_pine_tree.rgba16.png": [32,64,4096,{"jp":[2094912,200776],"us":[2102288,200776],"eu":[1974256,200776],"sh":[1950768,200776],"cn":[2017600,200776]}], +"actors/tree/tree_left_side.rgba16.png": [32,64,4096,{"jp":[2094912,187944],"us":[2102288,187944],"eu":[1974256,187944],"sh":[1950768,187944],"cn":[2017600,187944]}], +"actors/tree/tree_right_side.rgba16.png": [32,64,4096,{"jp":[2094912,192040],"us":[2102288,192040],"eu":[1974256,192040],"sh":[1950768,192040],"cn":[2017600,192040]}], +"actors/ukiki/ukiki_butt.rgba16.png": [32,32,2048,{"jp":[1377744,39872],"us":[1384912,39872],"eu":[1256880,39872],"sh":[1233392,39872],"cn":[1300224,39872]}], +"actors/ukiki/ukiki_face.rgba16.png": [64,32,4096,{"jp":[1377744,31680],"us":[1384912,31680],"eu":[1256880,31680],"sh":[1233392,31680],"cn":[1300224,31680]}], +"actors/ukiki/ukiki_face_blink.rgba16.png": [64,32,4096,{"jp":[1377744,35776],"us":[1384912,35776],"eu":[1256880,35776],"sh":[1233392,35776],"cn":[1300224,35776]}], +"actors/ukiki/ukiki_fur.rgba16.png": [32,32,2048,{"jp":[1377744,41920],"us":[1384912,41920],"eu":[1256880,41920],"sh":[1233392,41920],"cn":[1300224,41920]}], +"actors/unagi/unagi_body.rgba16.png": [32,32,2048,{"jp":[1285392,44832],"us":[1292560,44832],"eu":[1164528,44832],"sh":[1141040,44832],"cn":[1207872,44832]}], +"actors/unagi/unagi_eye.rgba16.png": [16,16,512,{"jp":[1285392,46880],"us":[1292560,46880],"eu":[1164528,46880],"sh":[1141040,46880],"cn":[1207872,46880]}], +"actors/unagi/unagi_head_base.rgba16.png": [32,32,2048,{"jp":[1285392,47392],"us":[1292560,47392],"eu":[1164528,47392],"sh":[1141040,47392],"cn":[1207872,47392]}], +"actors/unagi/unagi_mouth.rgba16.png": [8,8,128,{"jp":[1285392,49952],"us":[1292560,49952],"eu":[1164528,49952],"sh":[1141040,49952],"cn":[1207872,49952]}], +"actors/unagi/unagi_tail.rgba16.png": [32,32,2048,{"jp":[1285392,50080],"us":[1292560,50080],"eu":[1164528,50080],"sh":[1141040,50080],"cn":[1207872,50080]}], +"actors/unagi/unagi_tooth.rgba16.png": [16,16,512,{"jp":[1285392,49440],"us":[1292560,49440],"eu":[1164528,49440],"sh":[1141040,49440],"cn":[1207872,49440]}], +"actors/walk_smoke/walk_smoke_0.ia16.png": [32,32,2048,{"jp":[1125200,122528],"us":[1132368,122528],"eu":[1004336,122528],"sh":[980848,122528],"cn":[1047664,122528]}], +"actors/walk_smoke/walk_smoke_1.ia16.png": [32,32,2048,{"jp":[1125200,124576],"us":[1132368,124576],"eu":[1004336,124576],"sh":[980848,124576],"cn":[1047664,124576]}], +"actors/walk_smoke/walk_smoke_2.ia16.png": [32,32,2048,{"jp":[1125200,126624],"us":[1132368,126624],"eu":[1004336,126624],"sh":[980848,126624],"cn":[1047664,126624]}], +"actors/walk_smoke/walk_smoke_3.ia16.png": [32,32,2048,{"jp":[1125200,128672],"us":[1132368,128672],"eu":[1004336,128672],"sh":[980848,128672],"cn":[1047664,128672]}], +"actors/walk_smoke/walk_smoke_4.ia16.png": [32,32,2048,{"jp":[1125200,130720],"us":[1132368,130720],"eu":[1004336,130720],"sh":[980848,130720],"cn":[1047664,130720]}], +"actors/walk_smoke/walk_smoke_5.ia16.png": [32,32,2048,{"jp":[1125200,132768],"us":[1132368,132768],"eu":[1004336,132768],"sh":[980848,132768],"cn":[1047664,132768]}], +"actors/walk_smoke/walk_smoke_6.ia16.png": [32,32,2048,{"jp":[1125200,134816],"us":[1132368,134816],"eu":[1004336,134816],"sh":[980848,134816],"cn":[1047664,134816]}], +"actors/warp_pipe/warp_pipe_side.rgba16.png": [32,64,4096,{"jp":[2094912,32320],"us":[2102288,32320],"eu":[1974256,32320],"sh":[1950768,32320],"cn":[2017600,32320]}], +"actors/warp_pipe/warp_pipe_top.rgba16.png": [32,32,2048,{"jp":[2094912,37224],"us":[2102288,37224],"eu":[1974256,37224],"sh":[1950768,37224],"cn":[2017600,37224]}], +"actors/water_bubble/water_bubble.rgba16.png": [32,32,2048,{"jp":[1257760,65152],"us":[1264928,65152],"eu":[1136896,65152],"sh":[1113408,65152],"cn":[1180240,65152]}], +"actors/water_mine/water_mine_left_side_unused.rgba16.png": [32,64,4096,{"jp":[1599504,359104],"us":[1606720,359440],"eu":[1478688,359440],"sh":[1455200,359440],"cn":[1522032,359440]}], +"actors/water_mine/water_mine_right_side_unused.rgba16.png": [32,64,4096,{"jp":[1599504,363200],"us":[1606720,363536],"eu":[1478688,363536],"sh":[1455200,363536],"cn":[1522032,363536]}], +"actors/water_mine/water_mine_spike_unused.rgba16.png": [32,32,2048,{"jp":[1599504,367296],"us":[1606720,367632],"eu":[1478688,367632],"sh":[1455200,367632],"cn":[1522032,367632]}], +"actors/water_ring/water_ring.rgba16.png": [64,32,4096,{"jp":[1802256,74624],"us":[1809600,74624],"eu":[1681568,74624],"sh":[1658080,74624],"cn":[1724912,74624]}], +"actors/water_splash/water_splash_0.rgba16.png": [32,64,4096,{"jp":[1125200,173512],"us":[1132368,173512],"eu":[1004336,173512],"sh":[980848,173512],"cn":[1047664,173512]}], +"actors/water_splash/water_splash_1.rgba16.png": [32,64,4096,{"jp":[1125200,177608],"us":[1132368,177608],"eu":[1004336,177608],"sh":[980848,177608],"cn":[1047664,177608]}], +"actors/water_splash/water_splash_2.rgba16.png": [32,64,4096,{"jp":[1125200,181704],"us":[1132368,181704],"eu":[1004336,181704],"sh":[980848,181704],"cn":[1047664,181704]}], +"actors/water_splash/water_splash_3.rgba16.png": [32,64,4096,{"jp":[1125200,185800],"us":[1132368,185800],"eu":[1004336,185800],"sh":[980848,185800],"cn":[1047664,185800]}], +"actors/water_splash/water_splash_4.rgba16.png": [32,64,4096,{"jp":[1125200,189896],"us":[1132368,189896],"eu":[1004336,189896],"sh":[980848,189896],"cn":[1047664,189896]}], +"actors/water_splash/water_splash_5.rgba16.png": [32,64,4096,{"jp":[1125200,193992],"us":[1132368,193992],"eu":[1004336,193992],"sh":[980848,193992],"cn":[1047664,193992]}], +"actors/water_splash/water_splash_6.rgba16.png": [32,64,4096,{"jp":[1125200,198088],"us":[1132368,198088],"eu":[1004336,198088],"sh":[980848,198088],"cn":[1047664,198088]}], +"actors/water_splash/water_splash_7.rgba16.png": [32,64,4096,{"jp":[1125200,202184],"us":[1132368,202184],"eu":[1004336,202184],"sh":[980848,202184],"cn":[1047664,202184]}], +"actors/water_wave/water_wave_0.ia16.png": [32,32,2048,{"jp":[1125200,152408],"us":[1132368,152408],"eu":[1004336,152408],"sh":[980848,152408],"cn":[1047664,152408]}], +"actors/water_wave/water_wave_1.ia16.png": [32,32,2048,{"jp":[1125200,154456],"us":[1132368,154456],"eu":[1004336,154456],"sh":[980848,154456],"cn":[1047664,154456]}], +"actors/water_wave/water_wave_2.ia16.png": [32,32,2048,{"jp":[1125200,156504],"us":[1132368,156504],"eu":[1004336,156504],"sh":[980848,156504],"cn":[1047664,156504]}], +"actors/water_wave/water_wave_3.ia16.png": [32,32,2048,{"jp":[1125200,158552],"us":[1132368,158552],"eu":[1004336,158552],"sh":[980848,158552],"cn":[1047664,158552]}], +"actors/whirlpool/whirlpool.ia16.png": [32,64,4096,{"jp":[1285392,75848],"us":[1292560,75848],"eu":[1164528,75848],"sh":[1141040,75848],"cn":[1207872,75848]}], +"actors/white_particle/snow_particle.rgba16.png": [16,16,512,{"jp":[2094912,181920],"us":[2102288,181920],"eu":[1974256,181920],"sh":[1950768,181920],"cn":[2017600,181920]}], +"actors/white_particle_small/small_snow_particle.rgba16.png": [16,16,512,{"jp":[1125200,206720],"us":[1132368,206720],"eu":[1004336,206720],"sh":[980848,206720],"cn":[1047664,206720]}], +"actors/whomp/whomp_back.rgba16.png": [32,64,4096,{"jp":[1844608,115552],"us":[1851952,115552],"eu":[1723920,115552],"sh":[1700432,115552],"cn":[1767264,115552]}], +"actors/whomp/whomp_face.rgba16.png": [32,64,4096,{"jp":[1844608,119648],"us":[1851952,119648],"eu":[1723920,119648],"sh":[1700432,119648],"cn":[1767264,119648]}], +"actors/whomp/whomp_hand.rgba16.png": [32,32,2048,{"jp":[1844608,123744],"us":[1851952,123744],"eu":[1723920,123744],"sh":[1700432,123744],"cn":[1767264,123744]}], +"actors/whomp/whomp_surface.rgba16.png": [32,32,2048,{"jp":[1844608,125792],"us":[1851952,125792],"eu":[1723920,125792],"sh":[1700432,125792],"cn":[1767264,125792]}], +"actors/wiggler/wiggler_eye.rgba16.png": [32,32,2048,{"jp":[1568640,31280],"us":[1575856,31280],"eu":[1447824,31280],"sh":[1424336,31280],"cn":[1491168,31280]}], +"actors/wiggler/wiggler_flower.rgba16.png": [32,32,2048,{"jp":[1568640,33328],"us":[1575856,33328],"eu":[1447824,33328],"sh":[1424336,33328],"cn":[1491168,33328]}], +"actors/wiggler/wiggler_frown.rgba16.png": [32,32,2048,{"jp":[1568640,35376],"us":[1575856,35376],"eu":[1447824,35376],"sh":[1424336,35376],"cn":[1491168,35376]}], +"actors/wiggler/wiggler_nose_left_side.rgba16.png": [32,64,4096,{"jp":[1568640,37424],"us":[1575856,37424],"eu":[1447824,37424],"sh":[1424336,37424],"cn":[1491168,37424]}], +"actors/wiggler/wiggler_nose_right_side.rgba16.png": [32,64,4096,{"jp":[1568640,41520],"us":[1575856,41520],"eu":[1447824,41520],"sh":[1424336,41520],"cn":[1491168,41520]}], +"actors/wiggler/wiggler_segment_left_side.rgba16.png": [32,64,4096,{"jp":[1568640,23088],"us":[1575856,23088],"eu":[1447824,23088],"sh":[1424336,23088],"cn":[1491168,23088]}], +"actors/wiggler/wiggler_segment_right_side.rgba16.png": [32,64,4096,{"jp":[1568640,27184],"us":[1575856,27184],"eu":[1447824,27184],"sh":[1424336,27184],"cn":[1491168,27184]}], +"actors/wooden_signpost/wooden_signpost_back.rgba16.png": [32,32,2048,{"jp":[2094912,182728],"us":[2102288,182728],"eu":[1974256,182728],"sh":[1950768,182728],"cn":[2017600,182728]}], +"actors/wooden_signpost/wooden_signpost_front.rgba16.png": [32,32,2048,{"jp":[2094912,184776],"us":[2102288,184776],"eu":[1974256,184776],"sh":[1950768,184776],"cn":[2017600,184776]}], +"actors/yellow_sphere/yellow_sphere.rgba16.png": [32,32,2048,{"jp":[1215456,64],"us":[1222624,64],"eu":[1094592,64],"sh":[1071104,64],"cn":[1137936,64]}], +"actors/yellow_sphere_small/small_yellow_sphere.rgba16.png": [32,32,2048,{"jp":[1215456,64],"us":[1222624,64],"eu":[1094592,64],"sh":[1071104,64],"cn":[1137936,64]}], +"actors/yoshi/yoshi_eye.rgba16.png": [16,16,512,{"jp":[1490032,115872],"us":[1497200,116104],"eu":[1369168,116104],"sh":[1345680,116104],"cn":[1412512,116104]}], +"actors/yoshi/yoshi_eye_blink.rgba16.png": [16,16,512,{"jp":[1490032,116384],"us":[1497200,116616],"eu":[1369168,116616],"sh":[1345680,116616],"cn":[1412512,116616]}], +"actors/yoshi/yoshi_nostril.rgba16.png": [16,16,512,{"jp":[1490032,116896],"us":[1497200,117128],"eu":[1369168,117128],"sh":[1345680,117128],"cn":[1412512,117128]}], +"actors/yoshi_egg/yoshi_egg_0_unused.rgba16.png": [32,32,2048,{"jp":[1215456,22456],"us":[1222624,22456],"eu":[1094592,22456],"sh":[1071104,22456],"cn":[1137936,22456]}], +"actors/yoshi_egg/yoshi_egg_1_unused.rgba16.png": [32,32,2048,{"jp":[1215456,24504],"us":[1222624,24504],"eu":[1094592,24504],"sh":[1071104,24504],"cn":[1137936,24504]}], +"actors/yoshi_egg/yoshi_egg_2_unused.rgba16.png": [32,32,2048,{"jp":[1215456,26552],"us":[1222624,26552],"eu":[1094592,26552],"sh":[1071104,26552],"cn":[1137936,26552]}], +"actors/yoshi_egg/yoshi_egg_3_unused.rgba16.png": [32,32,2048,{"jp":[1215456,28600],"us":[1222624,28600],"eu":[1094592,28600],"sh":[1071104,28600],"cn":[1137936,28600]}], +"actors/yoshi_egg/yoshi_egg_4_unused.rgba16.png": [32,32,2048,{"jp":[1215456,30648],"us":[1222624,30648],"eu":[1094592,30648],"sh":[1071104,30648],"cn":[1137936,30648]}], +"actors/yoshi_egg/yoshi_egg_5_unused.rgba16.png": [32,32,2048,{"jp":[1215456,32696],"us":[1222624,32696],"eu":[1094592,32696],"sh":[1071104,32696],"cn":[1137936,32696]}], +"actors/yoshi_egg/yoshi_egg_6_unused.rgba16.png": [32,32,2048,{"jp":[1215456,34744],"us":[1222624,34744],"eu":[1094592,34744],"sh":[1071104,34744],"cn":[1137936,34744]}], +"actors/yoshi_egg/yoshi_egg_7_unused.rgba16.png": [32,32,2048,{"jp":[1215456,36792],"us":[1222624,36792],"eu":[1094592,36792],"sh":[1071104,36792],"cn":[1137936,36792]}], +"assets/demos/bbh.bin": [988,{"jp":[5733368],"us":[5741664],"eu":[5620584],"sh":[5589632],"cn":[5662656]}], +"assets/demos/bitdw.bin": [1412,{"us":[5747100],"sh":[5595068],"cn":[5668092]}], +"assets/demos/ccm.bin": [1320,{"jp":[5734356],"us":[5742652],"eu":[5621572],"sh":[5590620],"cn":[5663644]}], +"assets/demos/hmc.bin": [980,{"jp":[5735676],"us":[5743972],"eu":[5622892],"sh":[5591940],"cn":[5664964]}], +"assets/demos/jrb.bin": [620,{"jp":[5736656],"us":[5744952],"eu":[5623872],"sh":[5592920],"cn":[5665944]}], +"assets/demos/pss.bin": [748,{"jp":[5737948],"us":[5746244],"eu":[5625164],"sh":[5594212],"cn":[5667236]}], +"assets/demos/unused.bin": [108,{"jp":[5738696],"us":[5746992],"eu":[5625912],"sh":[5594960],"cn":[5667984]}], +"assets/demos/wf.bin": [672,{"jp":[5737276],"us":[5745572],"eu":[5624492],"sh":[5593540],"cn":[5666564]}], +"levels/bbh/0.rgba16.png": [32,64,4096,{"jp":[3604960,0],"us":[3611712,0],"eu":[3485312,0],"sh":[3459680,0],"cn":[3533440,0]}], +"levels/bbh/1.rgba16.png": [32,32,2048,{"jp":[3604960,4096],"us":[3611712,4096],"eu":[3485312,4096],"sh":[3459680,4096],"cn":[3533440,4096]}], +"levels/bbh/2.rgba16.png": [32,32,2048,{"jp":[3604960,6144],"us":[3611712,6144],"eu":[3485312,6144],"sh":[3459680,6144],"cn":[3533440,6144]}], +"levels/bbh/3.rgba16.png": [32,64,4096,{"jp":[3604960,8192],"us":[3611712,8192],"eu":[3485312,8192],"sh":[3459680,8192],"cn":[3533440,8192]}], +"levels/bbh/4.rgba16.png": [16,32,1024,{"jp":[3604960,12288],"us":[3611712,12288],"eu":[3485312,12288],"sh":[3459680,12288],"cn":[3533440,12288]}], +"levels/bbh/5.rgba16.png": [32,64,4096,{"jp":[3604960,13312],"us":[3611712,13312],"eu":[3485312,13312],"sh":[3459680,13312],"cn":[3533440,13312]}], +"levels/bbh/6.rgba16.png": [16,32,1024,{"jp":[3604960,17408],"us":[3611712,17408],"eu":[3485312,17408],"sh":[3459680,17408],"cn":[3533440,17408]}], +"levels/bitdw/0.rgba16.png": [32,32,2048,{"jp":[4533568,0],"us":[4541952,0],"eu":[4415552,0],"sh":[4389920,0],"cn":[4463696,0]}], +"levels/bitdw/1.rgba16.png": [32,32,2048,{"jp":[4533568,2048],"us":[4541952,2048],"eu":[4415552,2048],"sh":[4389920,2048],"cn":[4463696,2048]}], +"levels/bitdw/2.rgba16.png": [32,32,2048,{"jp":[4533568,4096],"us":[4541952,4096],"eu":[4415552,4096],"sh":[4389920,4096],"cn":[4463696,4096]}], +"levels/bitdw/3.rgba16.png": [32,32,2048,{"jp":[4533568,6144],"us":[4541952,6144],"eu":[4415552,6144],"sh":[4389920,6144],"cn":[4463696,6144]}], +"levels/bitfs/0.rgba16.png": [32,64,4096,{"jp":[4584464,0],"us":[4592848,0],"eu":[4466448,0],"sh":[4440816,0],"cn":[4514592,0]}], +"levels/bitfs/1.rgba16.png": [32,32,2048,{"jp":[4584464,4096],"us":[4592848,4096],"eu":[4466448,4096],"sh":[4440816,4096],"cn":[4514592,4096]}], +"levels/bitfs/2.rgba16.png": [32,32,2048,{"jp":[4584464,6144],"us":[4592848,6144],"eu":[4466448,6144],"sh":[4440816,6144],"cn":[4514592,6144]}], +"levels/bits/0.rgba16.png": [32,64,4096,{"jp":[4629216,0],"us":[4637600,0],"eu":[4511200,0],"sh":[4485568,0],"cn":[4559344,0]}], +"levels/bits/1.rgba16.png": [64,32,4096,{"jp":[4629216,4096],"us":[4637600,4096],"eu":[4511200,4096],"sh":[4485568,4096],"cn":[4559344,4096]}], +"levels/bits/2.rgba16.png": [32,32,2048,{"jp":[4629216,8192],"us":[4637600,8192],"eu":[4511200,8192],"sh":[4485568,8192],"cn":[4559344,8192]}], +"levels/bob/0.rgba16.png": [32,32,2048,{"jp":[4170512,0],"us":[4178608,0],"eu":[4052208,0],"sh":[4026576,0],"cn":[4100352,0]}], +"levels/bob/1.rgba16.png": [32,32,2048,{"jp":[4170512,2048],"us":[4178608,2048],"eu":[4052208,2048],"sh":[4026576,2048],"cn":[4100352,2048]}], +"levels/bob/2.rgba16.png": [32,32,2048,{"jp":[4170512,4096],"us":[4178608,4096],"eu":[4052208,4096],"sh":[4026576,4096],"cn":[4100352,4096]}], +"levels/bob/3.rgba16.png": [32,32,2048,{"jp":[4170512,6144],"us":[4178608,6144],"eu":[4052208,6144],"sh":[4026576,6144],"cn":[4100352,6144]}], +"levels/bob/4.rgba16.png": [32,32,2048,{"jp":[4170512,8192],"us":[4178608,8192],"eu":[4052208,8192],"sh":[4026576,8192],"cn":[4100352,8192]}], +"levels/bowser_1/0.rgba16.png": [32,64,4096,{"jp":[4982976,0],"us":[4991264,0],"eu":[4870192,0],"sh":[4839232,0],"cn":[4912256,0]}], +"levels/bowser_1/1.rgba16.png": [32,32,2048,{"jp":[4982976,4096],"us":[4991264,4096],"eu":[4870192,4096],"sh":[4839232,4096],"cn":[4912256,4096]}], +"levels/bowser_1/2.rgba16.png": [32,32,2048,{"jp":[4982976,6144],"us":[4991264,6144],"eu":[4870192,6144],"sh":[4839232,6144],"cn":[4912256,6144]}], +"levels/bowser_2/0.rgba16.png": [32,32,2048,{"jp":[5028720,0],"us":[5037008,0],"eu":[4915936,0],"sh":[4884976,0],"cn":[4958000,0]}], +"levels/bowser_3/0.rgba16.png": [32,32,2048,{"jp":[5032864,0],"us":[5041152,0],"eu":[4920080,0],"sh":[4889120,0],"cn":[4962144,0]}], +"levels/bowser_3/1.rgba16.png": [32,32,2048,{"jp":[5032864,2048],"us":[5041152,2048],"eu":[4920080,2048],"sh":[4889120,2048],"cn":[4962144,2048]}], +"levels/bowser_3/2.rgba16.png": [32,64,4096,{"jp":[5032864,4096],"us":[5041152,4096],"eu":[4920080,4096],"sh":[4889120,4096],"cn":[4962144,4096]}], +"levels/castle_grounds/0.rgba16.png": [32,64,4096,{"jp":[4492416,0],"us":[4500416,0],"eu":[4374016,0],"sh":[4348384,0],"cn":[4422160,0]}], +"levels/castle_grounds/1.rgba16.png": [64,32,4096,{"jp":[4492416,4096],"us":[4500416,4096],"eu":[4374016,4096],"sh":[4348384,4096],"cn":[4422160,4096]}], +"levels/castle_grounds/2.rgba16.png": [64,32,4096,{"jp":[4492416,8192],"us":[4500416,8192],"eu":[4374016,8192],"sh":[4348384,8192],"cn":[4422160,8192]}], +"levels/castle_grounds/3.rgba16.png": [32,64,4096,{"jp":[4492416,51688],"us":[4500416,51688],"eu":[4374016,51688],"sh":[4348384,51688],"cn":[4422160,51688]}], +"levels/castle_grounds/4.rgba16.png": [32,64,4096,{"jp":[4492416,55784],"us":[4500416,55784],"eu":[4374016,55784],"sh":[4348384,55784],"cn":[4422160,55784]}], +"levels/castle_grounds/5.ia8.png": [64,32,2048,{"us":[4500416,60136],"eu":[4374016,60136],"sh":[4348384,60136],"cn":[4422160,60136]}], +"levels/castle_inside/1.rgba16.png": [32,32,2048,{"jp":[3754192,2048],"us":[3760960,2048],"eu":[3634560,2048],"sh":[3608928,2048],"cn":[3682704,2048]}], +"levels/castle_inside/10.rgba16.png": [32,32,2048,{"jp":[3754192,28672],"us":[3760960,28672],"eu":[3634560,28672],"sh":[3608928,28672],"cn":[3682704,28672]}], +"levels/castle_inside/11.rgba16.png": [32,32,2048,{"jp":[3754192,30720],"us":[3760960,30720],"eu":[3634560,30720],"sh":[3608928,30720],"cn":[3682704,30720]}], +"levels/castle_inside/12.rgba16.png": [32,32,2048,{"jp":[3754192,32768],"us":[3760960,32768],"eu":[3634560,32768],"sh":[3608928,32768],"cn":[3682704,32768]}], +"levels/castle_inside/13.rgba16.png": [32,32,2048,{"jp":[3754192,34816],"us":[3760960,34816],"eu":[3634560,34816],"sh":[3608928,34816],"cn":[3682704,34816]}], +"levels/castle_inside/14.rgba16.png": [32,32,2048,{"jp":[3754192,36864],"us":[3760960,36864],"eu":[3634560,36864],"sh":[3608928,36864],"cn":[3682704,36864]}], +"levels/castle_inside/15.rgba16.png": [32,32,2048,{"jp":[3754192,38912],"us":[3760960,38912],"eu":[3634560,38912],"sh":[3608928,38912],"cn":[3682704,38912]}], +"levels/castle_inside/16.ia16.png": [32,32,2048,{"jp":[3754192,40960],"us":[3760960,40960],"eu":[3634560,40960],"sh":[3608928,40960],"cn":[3682704,40960]}], +"levels/castle_inside/17.rgba16.png": [64,32,4096,{"jp":[3754192,43008],"us":[3760960,43008],"eu":[3634560,43008],"sh":[3608928,43008],"cn":[3682704,43008]}], +"levels/castle_inside/18.rgba16.png": [64,32,4096,{"jp":[3754192,47104],"us":[3760960,47104],"eu":[3634560,47104],"sh":[3608928,47104],"cn":[3682704,47104]}], +"levels/castle_inside/19.rgba16.png": [64,32,4096,{"jp":[3754192,51200],"us":[3760960,51200],"eu":[3634560,51200],"sh":[3608928,51200],"cn":[3682704,51200]}], +"levels/castle_inside/2.ia16.png": [32,64,4096,{"jp":[3298272,47104],"us":[3305024,47104],"eu":[3178624,47104],"sh":[3152992,47104],"cn":[3226752,47104]}], +"levels/castle_inside/20.rgba16.png": [64,32,4096,{"jp":[3754192,55296],"us":[3760960,55296],"eu":[3634560,55296],"sh":[3608928,55296],"cn":[3682704,55296]}], +"levels/castle_inside/21.rgba16.png": [64,32,4096,{"jp":[3754192,59392],"us":[3760960,59392],"eu":[3634560,59392],"sh":[3608928,59392],"cn":[3682704,59392]}], +"levels/castle_inside/22.rgba16.png": [64,32,4096,{"jp":[3754192,63488],"us":[3760960,63488],"eu":[3634560,63488],"sh":[3608928,63488],"cn":[3682704,63488]}], "levels/castle_inside/23.rgba16.png": [64,32,4096,{"jp":[3754192,67584]}], -"levels/castle_inside/23_us.rgba16.png": [64,32,4096,{"us":[3760960,67584],"eu":[3634560,67584],"sh":[3608928,67584]}], +"levels/castle_inside/23_us.rgba16.png": [64,32,4096,{"us":[3760960,67584],"eu":[3634560,67584],"sh":[3608928,67584],"cn":[3682704,67584]}], "levels/castle_inside/24.rgba16.png": [64,32,4096,{"jp":[3754192,71680]}], -"levels/castle_inside/24_us.rgba16.png": [64,32,4096,{"us":[3760960,71680],"eu":[3634560,71680],"sh":[3608928,71680]}], -"levels/castle_inside/25.rgba16.png": [64,32,4096,{"jp":[3754192,75776],"us":[3760960,75776],"eu":[3634560,75776],"sh":[3608928,75776]}], -"levels/castle_inside/26.rgba16.png": [64,32,4096,{"jp":[3754192,79872],"us":[3760960,79872],"eu":[3634560,79872],"sh":[3608928,79872]}], -"levels/castle_inside/27.rgba16.png": [64,32,4096,{"jp":[3754192,83968],"us":[3760960,83968],"eu":[3634560,83968],"sh":[3608928,83968]}], -"levels/castle_inside/28.rgba16.png": [64,32,4096,{"jp":[3754192,88064],"us":[3760960,88064],"eu":[3634560,88064],"sh":[3608928,88064]}], -"levels/castle_inside/29.rgba16.png": [32,32,2048,{"jp":[3754192,92160],"us":[3760960,92160],"eu":[3634560,92160],"sh":[3608928,92160]}], -"levels/castle_inside/3.rgba16.png": [32,64,4096,{"jp":[3754192,8192],"us":[3760960,8192],"eu":[3634560,8192],"sh":[3608928,8192]}], -"levels/castle_inside/30.rgba16.png": [32,32,2048,{"jp":[3754192,94208],"us":[3760960,94208],"eu":[3634560,94208],"sh":[3608928,94208]}], -"levels/castle_inside/31.rgba16.png": [64,32,4096,{"jp":[3754192,96256],"us":[3760960,96256],"eu":[3634560,96256],"sh":[3608928,96256]}], -"levels/castle_inside/32.rgba16.png": [64,32,4096,{"jp":[3754192,100352],"us":[3760960,100352],"eu":[3634560,100352],"sh":[3608928,100352]}], -"levels/castle_inside/33.rgba16.png": [64,32,4096,{"jp":[3754192,104448],"us":[3760960,104448],"eu":[3634560,104448],"sh":[3608928,104448]}], -"levels/castle_inside/34.rgba16.png": [64,32,4096,{"jp":[3754192,108544],"us":[3760960,108544],"eu":[3634560,108544],"sh":[3608928,108544]}], -"levels/castle_inside/35.rgba16.png": [64,32,4096,{"jp":[3754192,112640],"us":[3760960,112640],"eu":[3634560,112640],"sh":[3608928,112640]}], -"levels/castle_inside/36.rgba16.png": [64,32,4096,{"jp":[3754192,116736],"us":[3760960,116736],"eu":[3634560,116736],"sh":[3608928,116736]}], -"levels/castle_inside/37.rgba16.png": [64,32,4096,{"jp":[3754192,120832],"us":[3760960,120832],"eu":[3634560,120832],"sh":[3608928,120832]}], -"levels/castle_inside/38.rgba16.png": [64,32,4096,{"jp":[3754192,124928],"us":[3760960,124928],"eu":[3634560,124928],"sh":[3608928,124928]}], -"levels/castle_inside/39.rgba16.png": [64,32,4096,{"jp":[3754192,129024],"us":[3760960,129024],"eu":[3634560,129024],"sh":[3608928,129024]}], -"levels/castle_inside/4.rgba16.png": [32,32,2048,{"jp":[3754192,12288],"us":[3760960,12288],"eu":[3634560,12288],"sh":[3608928,12288]}], -"levels/castle_inside/40.rgba16.png": [64,32,4096,{"jp":[3754192,133120],"us":[3760960,133120],"eu":[3634560,133120],"sh":[3608928,133120]}], -"levels/castle_inside/5.rgba16.png": [32,64,4096,{"jp":[3754192,14336],"us":[3760960,14336],"eu":[3634560,14336],"sh":[3608928,14336]}], -"levels/castle_inside/6.rgba16.png": [32,64,4096,{"jp":[3754192,18432],"us":[3760960,18432],"eu":[3634560,18432],"sh":[3608928,18432]}], -"levels/castle_inside/7.rgba16.png": [32,32,2048,{"jp":[3754192,22528],"us":[3760960,22528],"eu":[3634560,22528],"sh":[3608928,22528]}], -"levels/castle_inside/8.rgba16.png": [32,32,2048,{"jp":[3754192,24576],"us":[3760960,24576],"eu":[3634560,24576],"sh":[3608928,24576]}], -"levels/castle_inside/9.rgba16.png": [32,32,2048,{"jp":[3754192,26624],"us":[3760960,26624],"eu":[3634560,26624],"sh":[3608928,26624]}], -"levels/castle_inside/castle_light.ia16.png": [32,32,2048,{"jp":[3432432,47104],"us":[3439184,47104],"eu":[3312784,47104],"sh":[3287152,47104]}], -"levels/ccm/0.rgba16.png": [32,32,2048,{"jp":[3677936,0],"us":[3684688,0],"eu":[3558288,0],"sh":[3532656,0]}], -"levels/ccm/1.rgba16.png": [32,4,256,{"jp":[3677936,2048],"us":[3684688,2048],"eu":[3558288,2048],"sh":[3532656,2048]}], -"levels/ccm/10.rgba16.png": [32,32,2048,{"jp":[3677936,17152],"us":[3684688,17152],"eu":[3558288,17152],"sh":[3532656,17152]}], -"levels/ccm/11.rgba16.png": [32,32,2048,{"jp":[3677936,19200],"us":[3684688,19200],"eu":[3558288,19200],"sh":[3532656,19200]}], -"levels/ccm/12.rgba16.png": [32,32,2048,{"jp":[3677936,72024],"us":[3684688,72024],"eu":[3558288,72024],"sh":[3532656,72024]}], -"levels/ccm/2.rgba16.png": [32,32,2048,{"jp":[3677936,2304],"us":[3684688,2304],"eu":[3558288,2304],"sh":[3532656,2304]}], -"levels/ccm/3.rgba16.png": [32,32,2048,{"jp":[3677936,4352],"us":[3684688,4352],"eu":[3558288,4352],"sh":[3532656,4352]}], -"levels/ccm/4.rgba16.png": [32,32,2048,{"jp":[3677936,6400],"us":[3684688,6400],"eu":[3558288,6400],"sh":[3532656,6400]}], -"levels/ccm/5.rgba16.png": [32,32,2048,{"jp":[1436272,48240],"us":[1443440,48240],"eu":[1315408,48240],"sh":[1291920,48240]}], -"levels/ccm/6.rgba16.png": [32,32,2048,{"jp":[1436272,46192],"us":[1443440,46192],"eu":[1315408,46192],"sh":[1291920,46192]}], -"levels/ccm/7.rgba16.png": [32,32,2048,{"jp":[3677936,12544],"us":[3684688,12544],"eu":[3558288,12544],"sh":[3532656,12544]}], -"levels/ccm/8.ia16.png": [16,16,512,{"jp":[3677936,14592],"us":[3684688,14592],"eu":[3558288,14592],"sh":[3532656,14592]}], -"levels/ccm/9.ia16.png": [32,32,2048,{"jp":[3677936,15104],"us":[3684688,15104],"eu":[3558288,15104],"sh":[3532656,15104]}], -"levels/cotmc/0.rgba16.png": [64,32,4096,{"jp":[4939888,0],"us":[4948176,0],"eu":[4827104,0],"sh":[4796144,0]}], -"levels/cotmc/1.rgba16.png": [32,32,2048,{"jp":[4939888,4096],"us":[4948176,4096],"eu":[4827104,4096],"sh":[4796144,4096]}], -"levels/cotmc/2.rgba16.png": [32,32,2048,{"jp":[4939888,6144],"us":[4948176,6144],"eu":[4827104,6144],"sh":[4796144,6144]}], -"levels/cotmc/3.rgba16.png": [32,32,2048,{"jp":[4939888,8192],"us":[4948176,8192],"eu":[4827104,8192],"sh":[4796144,8192]}], -"levels/cotmc/4.rgba16.png": [64,16,2048,{"jp":[4939888,10240],"us":[4948176,10240],"eu":[4827104,10240],"sh":[4796144,10240]}], -"levels/ddd/0.rgba16.png": [32,64,4096,{"jp":[4765904,0],"us":[4774192,0],"eu":[4647792,0],"sh":[4622160,0]}], -"levels/ddd/1.rgba16.png": [32,32,2048,{"jp":[3432432,4096],"us":[3439184,4096],"eu":[3312784,4096],"sh":[3287152,4096]}], -"levels/ddd/2.rgba16.png": [32,32,2048,{"jp":[4765904,6144],"us":[4774192,6144],"eu":[4647792,6144],"sh":[4622160,6144]}], -"levels/ddd/3.rgba16.png": [64,32,4096,{"jp":[4765904,8192],"us":[4774192,8192],"eu":[4647792,8192],"sh":[4622160,8192]}], -"levels/ddd/4.rgba16.png": [32,32,2048,{"jp":[4765904,12288],"us":[4774192,12288],"eu":[4647792,12288],"sh":[4622160,12288]}], +"levels/castle_inside/24_us.rgba16.png": [64,32,4096,{"us":[3760960,71680],"eu":[3634560,71680],"sh":[3608928,71680],"cn":[3682704,71680]}], +"levels/castle_inside/25.rgba16.png": [64,32,4096,{"jp":[3754192,75776],"us":[3760960,75776],"eu":[3634560,75776],"sh":[3608928,75776],"cn":[3682704,75776]}], +"levels/castle_inside/26.rgba16.png": [64,32,4096,{"jp":[3754192,79872],"us":[3760960,79872],"eu":[3634560,79872],"sh":[3608928,79872],"cn":[3682704,79872]}], +"levels/castle_inside/27.rgba16.png": [64,32,4096,{"jp":[3754192,83968],"us":[3760960,83968],"eu":[3634560,83968],"sh":[3608928,83968],"cn":[3682704,83968]}], +"levels/castle_inside/28.rgba16.png": [64,32,4096,{"jp":[3754192,88064],"us":[3760960,88064],"eu":[3634560,88064],"sh":[3608928,88064],"cn":[3682704,88064]}], +"levels/castle_inside/29.rgba16.png": [32,32,2048,{"jp":[3754192,92160],"us":[3760960,92160],"eu":[3634560,92160],"sh":[3608928,92160],"cn":[3682704,92160]}], +"levels/castle_inside/3.rgba16.png": [32,64,4096,{"jp":[3754192,8192],"us":[3760960,8192],"eu":[3634560,8192],"sh":[3608928,8192],"cn":[3682704,8192]}], +"levels/castle_inside/30.rgba16.png": [32,32,2048,{"jp":[3754192,94208],"us":[3760960,94208],"eu":[3634560,94208],"sh":[3608928,94208],"cn":[3682704,94208]}], +"levels/castle_inside/31.rgba16.png": [64,32,4096,{"jp":[3754192,96256],"us":[3760960,96256],"eu":[3634560,96256],"sh":[3608928,96256],"cn":[3682704,96256]}], +"levels/castle_inside/32.rgba16.png": [64,32,4096,{"jp":[3754192,100352],"us":[3760960,100352],"eu":[3634560,100352],"sh":[3608928,100352],"cn":[3682704,100352]}], +"levels/castle_inside/33.rgba16.png": [64,32,4096,{"jp":[3754192,104448],"us":[3760960,104448],"eu":[3634560,104448],"sh":[3608928,104448],"cn":[3682704,104448]}], +"levels/castle_inside/34.rgba16.png": [64,32,4096,{"jp":[3754192,108544],"us":[3760960,108544],"eu":[3634560,108544],"sh":[3608928,108544],"cn":[3682704,108544]}], +"levels/castle_inside/35.rgba16.png": [64,32,4096,{"jp":[3754192,112640],"us":[3760960,112640],"eu":[3634560,112640],"sh":[3608928,112640],"cn":[3682704,112640]}], +"levels/castle_inside/36.rgba16.png": [64,32,4096,{"jp":[3754192,116736],"us":[3760960,116736],"eu":[3634560,116736],"sh":[3608928,116736],"cn":[3682704,116736]}], +"levels/castle_inside/37.rgba16.png": [64,32,4096,{"jp":[3754192,120832],"us":[3760960,120832],"eu":[3634560,120832],"sh":[3608928,120832],"cn":[3682704,120832]}], +"levels/castle_inside/38.rgba16.png": [64,32,4096,{"jp":[3754192,124928],"us":[3760960,124928],"eu":[3634560,124928],"sh":[3608928,124928],"cn":[3682704,124928]}], +"levels/castle_inside/39.rgba16.png": [64,32,4096,{"jp":[3754192,129024],"us":[3760960,129024],"eu":[3634560,129024],"sh":[3608928,129024],"cn":[3682704,129024]}], +"levels/castle_inside/4.rgba16.png": [32,32,2048,{"jp":[3754192,12288],"us":[3760960,12288],"eu":[3634560,12288],"sh":[3608928,12288],"cn":[3682704,12288]}], +"levels/castle_inside/40.rgba16.png": [64,32,4096,{"jp":[3754192,133120],"us":[3760960,133120],"eu":[3634560,133120],"sh":[3608928,133120],"cn":[3682704,133120]}], +"levels/castle_inside/5.rgba16.png": [32,64,4096,{"jp":[3754192,14336],"us":[3760960,14336],"eu":[3634560,14336],"sh":[3608928,14336],"cn":[3682704,14336]}], +"levels/castle_inside/6.rgba16.png": [32,64,4096,{"jp":[3754192,18432],"us":[3760960,18432],"eu":[3634560,18432],"sh":[3608928,18432],"cn":[3682704,18432]}], +"levels/castle_inside/7.rgba16.png": [32,32,2048,{"jp":[3754192,22528],"us":[3760960,22528],"eu":[3634560,22528],"sh":[3608928,22528],"cn":[3682704,22528]}], +"levels/castle_inside/8.rgba16.png": [32,32,2048,{"jp":[3754192,24576],"us":[3760960,24576],"eu":[3634560,24576],"sh":[3608928,24576],"cn":[3682704,24576]}], +"levels/castle_inside/9.rgba16.png": [32,32,2048,{"jp":[3754192,26624],"us":[3760960,26624],"eu":[3634560,26624],"sh":[3608928,26624],"cn":[3682704,26624]}], +"levels/castle_inside/castle_light.ia16.png": [32,32,2048,{"jp":[3432432,47104],"us":[3439184,47104],"eu":[3312784,47104],"sh":[3287152,47104],"cn":[3360912,47104]}], +"levels/ccm/0.rgba16.png": [32,32,2048,{"jp":[3677936,0],"us":[3684688,0],"eu":[3558288,0],"sh":[3532656,0],"cn":[3606416,0]}], +"levels/ccm/1.rgba16.png": [32,4,256,{"jp":[3677936,2048],"us":[3684688,2048],"eu":[3558288,2048],"sh":[3532656,2048],"cn":[3606416,2048]}], +"levels/ccm/10.rgba16.png": [32,32,2048,{"jp":[3677936,17152],"us":[3684688,17152],"eu":[3558288,17152],"sh":[3532656,17152],"cn":[3606416,17152]}], +"levels/ccm/11.rgba16.png": [32,32,2048,{"jp":[3677936,19200],"us":[3684688,19200],"eu":[3558288,19200],"sh":[3532656,19200],"cn":[3606416,19200]}], +"levels/ccm/12.rgba16.png": [32,32,2048,{"jp":[3677936,72024],"us":[3684688,72024],"eu":[3558288,72024],"sh":[3532656,72024],"cn":[3606416,72024]}], +"levels/ccm/2.rgba16.png": [32,32,2048,{"jp":[3677936,2304],"us":[3684688,2304],"eu":[3558288,2304],"sh":[3532656,2304],"cn":[3606416,2304]}], +"levels/ccm/3.rgba16.png": [32,32,2048,{"jp":[3677936,4352],"us":[3684688,4352],"eu":[3558288,4352],"sh":[3532656,4352],"cn":[3606416,4352]}], +"levels/ccm/4.rgba16.png": [32,32,2048,{"jp":[3677936,6400],"us":[3684688,6400],"eu":[3558288,6400],"sh":[3532656,6400],"cn":[3606416,6400]}], +"levels/ccm/5.rgba16.png": [32,32,2048,{"jp":[1436272,48240],"us":[1443440,48240],"eu":[1315408,48240],"sh":[1291920,48240],"cn":[1358752,48240]}], +"levels/ccm/6.rgba16.png": [32,32,2048,{"jp":[1436272,46192],"us":[1443440,46192],"eu":[1315408,46192],"sh":[1291920,46192],"cn":[1358752,46192]}], +"levels/ccm/7.rgba16.png": [32,32,2048,{"jp":[3677936,12544],"us":[3684688,12544],"eu":[3558288,12544],"sh":[3532656,12544],"cn":[3606416,12544]}], +"levels/ccm/8.ia16.png": [16,16,512,{"jp":[3677936,14592],"us":[3684688,14592],"eu":[3558288,14592],"sh":[3532656,14592],"cn":[3606416,14592]}], +"levels/ccm/9.ia16.png": [32,32,2048,{"jp":[3677936,15104],"us":[3684688,15104],"eu":[3558288,15104],"sh":[3532656,15104],"cn":[3606416,15104]}], +"levels/cotmc/0.rgba16.png": [64,32,4096,{"jp":[4939888,0],"us":[4948176,0],"eu":[4827104,0],"sh":[4796144,0],"cn":[4869152,0]}], +"levels/cotmc/1.rgba16.png": [32,32,2048,{"jp":[4939888,4096],"us":[4948176,4096],"eu":[4827104,4096],"sh":[4796144,4096],"cn":[4869152,4096]}], +"levels/cotmc/2.rgba16.png": [32,32,2048,{"jp":[4939888,6144],"us":[4948176,6144],"eu":[4827104,6144],"sh":[4796144,6144],"cn":[4869152,6144]}], +"levels/cotmc/3.rgba16.png": [32,32,2048,{"jp":[4939888,8192],"us":[4948176,8192],"eu":[4827104,8192],"sh":[4796144,8192],"cn":[4869152,8192]}], +"levels/cotmc/4.rgba16.png": [64,16,2048,{"jp":[4939888,10240],"us":[4948176,10240],"eu":[4827104,10240],"sh":[4796144,10240],"cn":[4869152,10240]}], +"levels/ddd/0.rgba16.png": [32,64,4096,{"jp":[4765904,0],"us":[4774192,0],"eu":[4647792,0],"sh":[4622160,0],"cn":[4695936,0]}], +"levels/ddd/1.rgba16.png": [32,32,2048,{"jp":[3432432,4096],"us":[3439184,4096],"eu":[3312784,4096],"sh":[3287152,4096],"cn":[3360912,4096]}], +"levels/ddd/2.rgba16.png": [32,32,2048,{"jp":[4765904,6144],"us":[4774192,6144],"eu":[4647792,6144],"sh":[4622160,6144],"cn":[4695936,6144]}], +"levels/ddd/3.rgba16.png": [64,32,4096,{"jp":[4765904,8192],"us":[4774192,8192],"eu":[4647792,8192],"sh":[4622160,8192],"cn":[4695936,8192]}], +"levels/ddd/4.rgba16.png": [32,32,2048,{"jp":[4765904,12288],"us":[4774192,12288],"eu":[4647792,12288],"sh":[4622160,12288],"cn":[4695936,12288]}], "levels/ending/cake.png": [153600,{"jp":[4834992,0],"us":[4843280,0],"sh":[4691248,0]}], "levels/ending/cake_eu.png": [143360,{"eu":[4716880,0]}], +"levels/ending/cake_cn.png": [153600,{"cn":[4765024,0]}], "levels/ending/eu_023000.rgba16.png": [64,32,4096,{"eu":[4716880,143360]}], "levels/ending/eu_024000.rgba16.png": [64,32,4096,{"eu":[4716880,147456]}], "levels/ending/eu_025000.rgba16.png": [64,32,4096,{"eu":[4716880,151552]}], "levels/ending/eu_026000.rgba16.png": [64,32,4096,{"eu":[4716880,155648]}], "levels/ending/eu_027000.rgba16.png": [64,32,4096,{"eu":[4716880,159744]}], "levels/ending/eu_028000.rgba16.png": [64,32,4096,{"eu":[4716880,163840]}], -"levels/hmc/0.rgba16.png": [32,64,4096,{"jp":[3993136,0],"us":[4001216,0],"eu":[3874816,0],"sh":[3849184,0]}], -"levels/hmc/1.rgba16.png": [32,64,4096,{"jp":[3993136,4096],"us":[4001216,4096],"eu":[3874816,4096],"sh":[3849184,4096]}], -"levels/hmc/2.rgba16.png": [32,64,4096,{"jp":[3993136,8192],"us":[4001216,8192],"eu":[3874816,8192],"sh":[3849184,8192]}], -"levels/hmc/3.rgba16.png": [32,32,2048,{"jp":[3993136,12288],"us":[4001216,12288],"eu":[3874816,12288],"sh":[3849184,12288]}], -"levels/hmc/4.rgba16.png": [32,32,2048,{"jp":[3993136,14336],"us":[4001216,14336],"eu":[3874816,14336],"sh":[3849184,14336]}], -"levels/hmc/5.rgba16.png": [32,32,2048,{"jp":[3993136,16384],"us":[4001216,16384],"eu":[3874816,16384],"sh":[3849184,16384]}], -"levels/hmc/6.rgba16.png": [32,64,4096,{"jp":[3993136,18432],"us":[4001216,18432],"eu":[3874816,18432],"sh":[3849184,18432]}], -"levels/hmc/7.rgba16.png": [32,32,2048,{"jp":[3754192,92160],"us":[3760960,92160],"eu":[3634560,92160],"sh":[3608928,92160]}], -"levels/intro/0.rgba16.png": [32,32,2048,{"jp":[2524448,32416],"us":[2532256,32416],"eu":[2401056,32416],"sh":[2377888,32416]}], -"levels/intro/1.rgba16.png": [32,32,2048,{"jp":[2524448,34464],"us":[2532256,34464],"eu":[2401056,34464],"sh":[2377888,34464]}], +"levels/hmc/0.rgba16.png": [32,64,4096,{"jp":[3993136,0],"us":[4001216,0],"eu":[3874816,0],"sh":[3849184,0],"cn":[3922960,0]}], +"levels/hmc/1.rgba16.png": [32,64,4096,{"jp":[3993136,4096],"us":[4001216,4096],"eu":[3874816,4096],"sh":[3849184,4096],"cn":[3922960,4096]}], +"levels/hmc/2.rgba16.png": [32,64,4096,{"jp":[3993136,8192],"us":[4001216,8192],"eu":[3874816,8192],"sh":[3849184,8192],"cn":[3922960,8192]}], +"levels/hmc/3.rgba16.png": [32,32,2048,{"jp":[3993136,12288],"us":[4001216,12288],"eu":[3874816,12288],"sh":[3849184,12288],"cn":[3922960,12288]}], +"levels/hmc/4.rgba16.png": [32,32,2048,{"jp":[3993136,14336],"us":[4001216,14336],"eu":[3874816,14336],"sh":[3849184,14336],"cn":[3922960,14336]}], +"levels/hmc/5.rgba16.png": [32,32,2048,{"jp":[3993136,16384],"us":[4001216,16384],"eu":[3874816,16384],"sh":[3849184,16384],"cn":[3922960,16384]}], +"levels/hmc/6.rgba16.png": [32,64,4096,{"jp":[3993136,18432],"us":[4001216,18432],"eu":[3874816,18432],"sh":[3849184,18432],"cn":[3922960,18432]}], +"levels/hmc/7.rgba16.png": [32,32,2048,{"jp":[3754192,92160],"us":[3760960,92160],"eu":[3634560,92160],"sh":[3608928,92160],"cn":[3682704,92160]}], +"levels/intro/0.rgba16.png": [32,32,2048,{"jp":[2524448,32416],"us":[2532256,32416],"eu":[2401056,32416],"sh":[2377888,32416],"cn":[2448576,31392]}], +"levels/intro/1.rgba16.png": [32,32,2048,{"jp":[2524448,34464],"us":[2532256,34464],"eu":[2401056,34464],"sh":[2377888,34464],"cn":[2448576,33440]}], "levels/intro/2_copyright.rgba16.png": [128,16,4096,{"jp":[2524448,46240],"us":[2532256,46240]}], +"levels/intro/2_cn_copyright.rgba16.png": [128,16,4096,{"cn":[2448576,47392]}], +"levels/intro/2_cn_copyright_ique.rgba16.png": [128,16,4096,{"cn":[2448576,51488]}], "levels/intro/2_eu_copyright.rgba16.png": [128,16,4096,{"eu":[2401056,46240],"sh":[2377888,46240]}], "levels/intro/3_eu_tm.rgba16.png": [16,16,512,{"eu":[2401056,50336]}], "levels/intro/3_tm.rgba16.png": [16,16,512,{"jp":[2524448,50336],"us":[2532256,50336]}], -"levels/intro/3_sh_tm.rgba16.png": [16,16,512,{"sh":[2377888,50336]}], -"levels/jrb/0.rgba16.png": [32,32,2048,{"jp":[3432432,4096],"us":[3439184,4096],"eu":[3312784,4096],"sh":[3287152,4096]}], -"levels/jrb/1.rgba16.png": [64,32,4096,{"jp":[4294592,2048],"us":[4302688,2048],"eu":[4176288,2048],"sh":[4150656,2048]}], -"levels/jrb/2.rgba16.png": [32,32,2048,{"jp":[4294592,6144],"us":[4302688,6144],"eu":[4176288,6144],"sh":[4150656,6144]}], -"levels/jrb/3.rgba16.png": [32,32,2048,{"jp":[4294592,8192],"us":[4302688,8192],"eu":[4176288,8192],"sh":[4150656,8192]}], -"levels/lll/0.rgba16.png": [32,32,2048,{"jp":[4678592,0],"us":[4687008,0],"eu":[4560608,0],"sh":[4534976,0]}], -"levels/lll/1.rgba16.png": [32,32,2048,{"jp":[4678592,2048],"us":[4687008,2048],"eu":[4560608,2048],"sh":[4534976,2048]}], -"levels/lll/10.rgba16.png": [32,32,2048,{"jp":[4678592,20480],"us":[4687008,20480],"eu":[4560608,20480],"sh":[4534976,20480]}], -"levels/lll/11.rgba16.png": [32,32,2048,{"jp":[4678592,22528],"us":[4687008,22528],"eu":[4560608,22528],"sh":[4534976,22528]}], -"levels/lll/12.rgba16.png": [32,32,2048,{"jp":[4678592,24576],"us":[4687008,24576],"eu":[4560608,24576],"sh":[4534976,24576]}], -"levels/lll/13.rgba16.png": [32,32,2048,{"jp":[4678592,26624],"us":[4687008,26624],"eu":[4560608,26624],"sh":[4534976,26624]}], -"levels/lll/14.rgba16.png": [32,32,2048,{"jp":[4678592,28672],"us":[4687008,28672],"eu":[4560608,28672],"sh":[4534976,28672]}], -"levels/lll/15.rgba16.png": [32,32,2048,{"jp":[4678592,30720],"us":[4687008,30720],"eu":[4560608,30720],"sh":[4534976,30720]}], -"levels/lll/16.rgba16.png": [32,32,2048,{"jp":[4678592,32768],"us":[4687008,32768],"eu":[4560608,32768],"sh":[4534976,32768]}], -"levels/lll/17.rgba16.png": [32,32,2048,{"jp":[4678592,34816],"us":[4687008,34816],"eu":[4560608,34816],"sh":[4534976,34816]}], -"levels/lll/18.rgba16.png": [32,32,2048,{"jp":[4678592,36864],"us":[4687008,36864],"eu":[4560608,36864],"sh":[4534976,36864]}], -"levels/lll/19.rgba16.png": [32,32,2048,{"jp":[4678592,38912],"us":[4687008,38912],"eu":[4560608,38912],"sh":[4534976,38912]}], -"levels/lll/2.rgba16.png": [32,32,2048,{"jp":[4678592,4096],"us":[4687008,4096],"eu":[4560608,4096],"sh":[4534976,4096]}], -"levels/lll/20.rgba16.png": [32,32,2048,{"jp":[4678592,40960],"us":[4687008,40960],"eu":[4560608,40960],"sh":[4534976,40960]}], -"levels/lll/21.rgba16.png": [32,32,2048,{"jp":[4678592,43008],"us":[4687008,43008],"eu":[4560608,43008],"sh":[4534976,43008]}], -"levels/lll/22.rgba16.png": [32,32,2048,{"jp":[4678592,45056],"us":[4687008,45056],"eu":[4560608,45056],"sh":[4534976,45056]}], -"levels/lll/23.rgba16.png": [32,32,2048,{"jp":[4678592,47104],"us":[4687008,47104],"eu":[4560608,47104],"sh":[4534976,47104]}], -"levels/lll/24.rgba16.png": [32,32,2048,{"jp":[4678592,49152],"us":[4687008,49152],"eu":[4560608,49152],"sh":[4534976,49152]}], -"levels/lll/25.rgba16.png": [32,32,2048,{"jp":[4678592,51200],"us":[4687008,51200],"eu":[4560608,51200],"sh":[4534976,51200]}], -"levels/lll/26.rgba16.png": [16,16,512,{"jp":[4678592,53248],"us":[4687008,53248],"eu":[4560608,53248],"sh":[4534976,53248]}], -"levels/lll/27.ia16.png": [16,16,512,{"jp":[3677936,14592],"us":[3684688,14592],"eu":[3558288,14592],"sh":[3532656,14592]}], -"levels/lll/28.rgba16.png": [32,32,2048,{"jp":[4678592,54272],"us":[4687008,54272],"eu":[4560608,54272],"sh":[4534976,54272]}], -"levels/lll/29.rgba16.png": [32,32,2048,{"jp":[4678592,56320],"us":[4687008,56320],"eu":[4560608,56320],"sh":[4534976,56320]}], -"levels/lll/3.rgba16.png": [32,32,2048,{"jp":[4678592,6144],"us":[4687008,6144],"eu":[4560608,6144],"sh":[4534976,6144]}], -"levels/lll/30.rgba16.png": [32,32,2048,{"jp":[4678592,58368],"us":[4687008,58368],"eu":[4560608,58368],"sh":[4534976,58368]}], -"levels/lll/31.rgba16.png": [32,32,2048,{"jp":[4678592,60416],"us":[4687008,60416],"eu":[4560608,60416],"sh":[4534976,60416]}], -"levels/lll/32.rgba16.png": [64,16,2048,{"jp":[4678592,62464],"us":[4687008,62464],"eu":[4560608,62464],"sh":[4534976,62464]}], -"levels/lll/4.rgba16.png": [32,32,2048,{"jp":[4678592,8192],"us":[4687008,8192],"eu":[4560608,8192],"sh":[4534976,8192]}], -"levels/lll/5.rgba16.png": [32,32,2048,{"jp":[4678592,10240],"us":[4687008,10240],"eu":[4560608,10240],"sh":[4534976,10240]}], -"levels/lll/6.rgba16.png": [32,32,2048,{"jp":[4678592,12288],"us":[4687008,12288],"eu":[4560608,12288],"sh":[4534976,12288]}], -"levels/lll/7.rgba16.png": [32,32,2048,{"jp":[3262320,6144],"us":[3269072,6144],"eu":[3142672,6144],"sh":[3117040,6144]}], -"levels/lll/8.rgba16.png": [32,32,2048,{"jp":[4678592,16384],"us":[4687008,16384],"eu":[4560608,16384],"sh":[4534976,16384]}], -"levels/lll/9.rgba16.png": [32,32,2048,{"jp":[4678592,18432],"us":[4687008,18432],"eu":[4560608,18432],"sh":[4534976,18432]}], -"levels/menu/main_menu_seg7.00018.rgba16.png": [32,32,2048,{"jp":[2770736,24],"us":[2778544,24],"eu":[2647072,24],"sh":[2625456,24]}], -"levels/menu/main_menu_seg7.00818.rgba16.png": [32,32,2048,{"jp":[2770736,2072],"us":[2778544,2072],"eu":[2647072,2072],"sh":[2625456,2072]}], -"levels/menu/main_menu_seg7.01018.rgba16.png": [64,32,4096,{"jp":[2770736,4120],"us":[2778544,4120],"eu":[2647072,4120],"sh":[2625456,4120]}], -"levels/menu/main_menu_seg7.02018.rgba16.png": [64,32,4096,{"jp":[2770736,8216],"us":[2778544,8216],"eu":[2647072,8216],"sh":[2625456,8216]}], -"levels/menu/main_menu_seg7.03468.rgba16.png": [32,32,2048,{"jp":[2770736,13416],"us":[2778544,13416],"eu":[2647072,13416],"sh":[2625456,13416]}], -"levels/menu/main_menu_seg7.03C68.rgba16.png": [32,32,2048,{"jp":[2770736,15464],"us":[2778544,15464],"eu":[2647072,15464],"sh":[2625456,15464]}], -"levels/menu/main_menu_seg7.04468.rgba16.png": [32,32,2048,{"jp":[2770736,17512],"us":[2778544,17512],"eu":[2647072,17512],"sh":[2625456,17512]}], -"levels/menu/main_menu_seg7.04C68.rgba16.png": [32,32,2048,{"jp":[2770736,19560],"us":[2778544,19560],"eu":[2647072,19560],"sh":[2625456,19560]}], -"levels/menu/main_menu_seg7.05468.rgba16.png": [32,32,2048,{"jp":[2770736,21608],"us":[2778544,21608],"eu":[2647072,21608],"sh":[2625456,21608]}], -"levels/menu/main_menu_seg7.06328.rgba16.png": [32,32,2048,{"jp":[2770736,25384],"us":[2778544,25384],"eu":[2647072,25384],"sh":[2625456,25384]}], -"levels/menu/main_menu_seg7.06B28.rgba16.png": [32,32,2048,{"jp":[2770736,27432],"us":[2778544,27432],"eu":[2647072,27432],"sh":[2625456,27432]}], -"levels/menu/main_menu_seg7.073D0.rgba16.png": [16,16,512,{"jp":[2770736,29648],"us":[2778544,29648],"eu":[2647072,29648],"sh":[2625456,29648]}], -"levels/menu/main_menu_seg7.075D0.rgba16.png": [16,16,512,{"jp":[2770736,30160],"us":[2778544,30160],"eu":[2647072,30160],"sh":[2625456,30160]}], -"levels/menu/main_menu_seg7.077D0.rgba16.png": [16,16,512,{"jp":[2770736,30672],"us":[2778544,30672],"eu":[2647072,30672],"sh":[2625456,30672]}], -"levels/menu/main_menu_seg7.079D0.rgba16.png": [16,16,512,{"jp":[2770736,31184],"us":[2778544,31184],"eu":[2647072,31184],"sh":[2625456,31184]}], -"levels/menu/main_menu_seg7.07BD0.rgba16.png": [16,16,512,{"jp":[2770736,31696],"us":[2778544,31696],"eu":[2647072,31696],"sh":[2625456,31696]}], -"levels/menu/main_menu_seg7.07DD0.rgba16.png": [16,16,512,{"jp":[2770736,32208],"us":[2778544,32208],"eu":[2647072,32208],"sh":[2625456,32208]}], -"levels/menu/main_menu_seg7.07FD0.rgba16.png": [16,16,512,{"jp":[2770736,32720],"us":[2778544,32720],"eu":[2647072,32720],"sh":[2625456,32720]}], -"levels/menu/main_menu_seg7.081D0.rgba16.png": [16,16,512,{"jp":[2770736,33232],"us":[2778544,33232],"eu":[2647072,33232],"sh":[2625456,33232]}], -"levels/menu/main_menu_seg7.083D0.rgba16.png": [16,16,512,{"jp":[2770736,33744],"us":[2778544,33744],"eu":[2647072,33744],"sh":[2625456,33744]}], -"levels/menu/main_menu_seg7.085D0.rgba16.png": [16,16,512,{"jp":[2770736,34256],"us":[2778544,34256],"eu":[2647072,34256],"sh":[2625456,34256]}], -"levels/menu/main_menu_seg7.087D0.rgba16.png": [16,16,512,{"jp":[2770736,34768],"us":[2778544,34768],"eu":[2647072,34768],"sh":[2625456,34768]}], -"levels/menu/main_menu_seg7.089D0.rgba16.png": [16,16,512,{"jp":[2770736,35280],"us":[2778544,35280],"eu":[2647072,35280],"sh":[2625456,35280]}], -"levels/menu/main_menu_seg7.08BD0.rgba16.png": [16,16,512,{"jp":[2770736,35792],"us":[2778544,35792],"eu":[2647072,35792],"sh":[2625456,35792]}], -"levels/menu/main_menu_seg7.08DD0.rgba16.png": [16,16,512,{"jp":[2770736,36304],"us":[2778544,36304],"eu":[2647072,36304],"sh":[2625456,36304]}], -"levels/menu/main_menu_seg7.08FD0.rgba16.png": [16,16,512,{"jp":[2770736,36816],"us":[2778544,36816],"eu":[2647072,36816],"sh":[2625456,36816]}], -"levels/menu/main_menu_seg7.091D0.rgba16.png": [16,16,512,{"jp":[2770736,37328],"us":[2778544,37328],"eu":[2647072,37328],"sh":[2625456,37328]}], -"levels/menu/main_menu_seg7.093D0.rgba16.png": [16,16,512,{"jp":[2770736,37840],"us":[2778544,37840],"eu":[2647072,37840],"sh":[2625456,37840]}], -"levels/menu/main_menu_seg7.095D0.rgba16.png": [16,16,512,{"jp":[2770736,38352],"us":[2778544,38352],"eu":[2647072,38352],"sh":[2625456,38352]}], -"levels/menu/main_menu_seg7.097D0.rgba16.png": [16,16,512,{"jp":[2770736,38864],"us":[2778544,38864],"eu":[2647072,38864],"sh":[2625456,38864]}], -"levels/menu/main_menu_seg7.099D0.rgba16.png": [16,16,512,{"jp":[2770736,39376],"us":[2778544,39376],"eu":[2647072,39376],"sh":[2625456,39376]}], -"levels/menu/main_menu_seg7.09BD0.rgba16.png": [16,16,512,{"jp":[2770736,39888],"us":[2778544,39888],"eu":[2647072,39888],"sh":[2625456,39888]}], -"levels/menu/main_menu_seg7.09DD0.rgba16.png": [16,16,512,{"jp":[2770736,40400],"us":[2778544,40400],"eu":[2647072,40400],"sh":[2625456,40400]}], -"levels/menu/main_menu_seg7.09FD0.rgba16.png": [16,16,512,{"jp":[2770736,40912],"us":[2778544,40912],"eu":[2647072,40912],"sh":[2625456,40912]}], -"levels/menu/main_menu_seg7.0A1D0.rgba16.png": [16,16,512,{"jp":[1078992,20480],"us":[2778544,41424],"eu":[2647072,41424],"sh":[934640,20480]}], -"levels/menu/main_menu_seg7.0A3D0.rgba16.png": [16,16,512,{"jp":[2770736,41936],"us":[2778544,41936],"eu":[2647072,41936],"sh":[2625456,41936]}], -"levels/menu/main_menu_seg7.0A5D0.rgba16.png": [16,16,512,{"jp":[2770736,42448],"us":[2778544,42448],"eu":[2647072,42448],"sh":[2625456,42448]}], -"levels/menu/main_menu_seg7.0A7D0.rgba16.png": [16,16,512,{"jp":[2770736,42960],"us":[2778544,42960],"eu":[2647072,42960],"sh":[2625456,42960]}], -"levels/menu/main_menu_seg7.0A9D0.rgba16.png": [16,16,512,{"jp":[2770736,43472],"us":[2778544,43472],"eu":[2647072,43472],"sh":[2625456,43472]}], +"levels/intro/3_sh_tm.rgba16.png": [16,16,512,{"sh":[2377888,50336],"cn":[2448576,55584]}], +"levels/jrb/0.rgba16.png": [32,32,2048,{"jp":[3432432,4096],"us":[3439184,4096],"eu":[3312784,4096],"sh":[3287152,4096],"cn":[3360912,4096]}], +"levels/jrb/1.rgba16.png": [64,32,4096,{"jp":[4294592,2048],"us":[4302688,2048],"eu":[4176288,2048],"sh":[4150656,2048],"cn":[4224432,2048]}], +"levels/jrb/2.rgba16.png": [32,32,2048,{"jp":[4294592,6144],"us":[4302688,6144],"eu":[4176288,6144],"sh":[4150656,6144],"cn":[4224432,6144]}], +"levels/jrb/3.rgba16.png": [32,32,2048,{"jp":[4294592,8192],"us":[4302688,8192],"eu":[4176288,8192],"sh":[4150656,8192],"cn":[4224432,8192]}], +"levels/lll/0.rgba16.png": [32,32,2048,{"jp":[4678592,0],"us":[4687008,0],"eu":[4560608,0],"sh":[4534976,0],"cn":[4608752,0]}], +"levels/lll/1.rgba16.png": [32,32,2048,{"jp":[4678592,2048],"us":[4687008,2048],"eu":[4560608,2048],"sh":[4534976,2048],"cn":[4608752,2048]}], +"levels/lll/10.rgba16.png": [32,32,2048,{"jp":[4678592,20480],"us":[4687008,20480],"eu":[4560608,20480],"sh":[4534976,20480],"cn":[4608752,20480]}], +"levels/lll/11.rgba16.png": [32,32,2048,{"jp":[4678592,22528],"us":[4687008,22528],"eu":[4560608,22528],"sh":[4534976,22528],"cn":[4608752,22528]}], +"levels/lll/12.rgba16.png": [32,32,2048,{"jp":[4678592,24576],"us":[4687008,24576],"eu":[4560608,24576],"sh":[4534976,24576],"cn":[4608752,24576]}], +"levels/lll/13.rgba16.png": [32,32,2048,{"jp":[4678592,26624],"us":[4687008,26624],"eu":[4560608,26624],"sh":[4534976,26624],"cn":[4608752,26624]}], +"levels/lll/14.rgba16.png": [32,32,2048,{"jp":[4678592,28672],"us":[4687008,28672],"eu":[4560608,28672],"sh":[4534976,28672],"cn":[4608752,28672]}], +"levels/lll/15.rgba16.png": [32,32,2048,{"jp":[4678592,30720],"us":[4687008,30720],"eu":[4560608,30720],"sh":[4534976,30720],"cn":[4608752,30720]}], +"levels/lll/16.rgba16.png": [32,32,2048,{"jp":[4678592,32768],"us":[4687008,32768],"eu":[4560608,32768],"sh":[4534976,32768],"cn":[4608752,32768]}], +"levels/lll/17.rgba16.png": [32,32,2048,{"jp":[4678592,34816],"us":[4687008,34816],"eu":[4560608,34816],"sh":[4534976,34816],"cn":[4608752,34816]}], +"levels/lll/18.rgba16.png": [32,32,2048,{"jp":[4678592,36864],"us":[4687008,36864],"eu":[4560608,36864],"sh":[4534976,36864],"cn":[4608752,36864]}], +"levels/lll/19.rgba16.png": [32,32,2048,{"jp":[4678592,38912],"us":[4687008,38912],"eu":[4560608,38912],"sh":[4534976,38912],"cn":[4608752,38912]}], +"levels/lll/2.rgba16.png": [32,32,2048,{"jp":[4678592,4096],"us":[4687008,4096],"eu":[4560608,4096],"sh":[4534976,4096],"cn":[4608752,4096]}], +"levels/lll/20.rgba16.png": [32,32,2048,{"jp":[4678592,40960],"us":[4687008,40960],"eu":[4560608,40960],"sh":[4534976,40960],"cn":[4608752,40960]}], +"levels/lll/21.rgba16.png": [32,32,2048,{"jp":[4678592,43008],"us":[4687008,43008],"eu":[4560608,43008],"sh":[4534976,43008],"cn":[4608752,43008]}], +"levels/lll/22.rgba16.png": [32,32,2048,{"jp":[4678592,45056],"us":[4687008,45056],"eu":[4560608,45056],"sh":[4534976,45056],"cn":[4608752,45056]}], +"levels/lll/23.rgba16.png": [32,32,2048,{"jp":[4678592,47104],"us":[4687008,47104],"eu":[4560608,47104],"sh":[4534976,47104],"cn":[4608752,47104]}], +"levels/lll/24.rgba16.png": [32,32,2048,{"jp":[4678592,49152],"us":[4687008,49152],"eu":[4560608,49152],"sh":[4534976,49152],"cn":[4608752,49152]}], +"levels/lll/25.rgba16.png": [32,32,2048,{"jp":[4678592,51200],"us":[4687008,51200],"eu":[4560608,51200],"sh":[4534976,51200],"cn":[4608752,51200]}], +"levels/lll/26.rgba16.png": [16,16,512,{"jp":[4678592,53248],"us":[4687008,53248],"eu":[4560608,53248],"sh":[4534976,53248],"cn":[4608752,53248]}], +"levels/lll/27.ia16.png": [16,16,512,{"jp":[3677936,14592],"us":[3684688,14592],"eu":[3558288,14592],"sh":[3532656,14592],"cn":[3606416,14592]}], +"levels/lll/28.rgba16.png": [32,32,2048,{"jp":[4678592,54272],"us":[4687008,54272],"eu":[4560608,54272],"sh":[4534976,54272],"cn":[4608752,54272]}], +"levels/lll/29.rgba16.png": [32,32,2048,{"jp":[4678592,56320],"us":[4687008,56320],"eu":[4560608,56320],"sh":[4534976,56320],"cn":[4608752,56320]}], +"levels/lll/3.rgba16.png": [32,32,2048,{"jp":[4678592,6144],"us":[4687008,6144],"eu":[4560608,6144],"sh":[4534976,6144],"cn":[4608752,6144]}], +"levels/lll/30.rgba16.png": [32,32,2048,{"jp":[4678592,58368],"us":[4687008,58368],"eu":[4560608,58368],"sh":[4534976,58368],"cn":[4608752,58368]}], +"levels/lll/31.rgba16.png": [32,32,2048,{"jp":[4678592,60416],"us":[4687008,60416],"eu":[4560608,60416],"sh":[4534976,60416],"cn":[4608752,60416]}], +"levels/lll/32.rgba16.png": [64,16,2048,{"jp":[4678592,62464],"us":[4687008,62464],"eu":[4560608,62464],"sh":[4534976,62464],"cn":[4608752,62464]}], +"levels/lll/4.rgba16.png": [32,32,2048,{"jp":[4678592,8192],"us":[4687008,8192],"eu":[4560608,8192],"sh":[4534976,8192],"cn":[4608752,8192]}], +"levels/lll/5.rgba16.png": [32,32,2048,{"jp":[4678592,10240],"us":[4687008,10240],"eu":[4560608,10240],"sh":[4534976,10240],"cn":[4608752,10240]}], +"levels/lll/6.rgba16.png": [32,32,2048,{"jp":[4678592,12288],"us":[4687008,12288],"eu":[4560608,12288],"sh":[4534976,12288],"cn":[4608752,12288]}], +"levels/lll/7.rgba16.png": [32,32,2048,{"jp":[3262320,6144],"us":[3269072,6144],"eu":[3142672,6144],"sh":[3117040,6144],"cn":[3190800,6144]}], +"levels/lll/8.rgba16.png": [32,32,2048,{"jp":[4678592,16384],"us":[4687008,16384],"eu":[4560608,16384],"sh":[4534976,16384],"cn":[4608752,16384]}], +"levels/lll/9.rgba16.png": [32,32,2048,{"jp":[4678592,18432],"us":[4687008,18432],"eu":[4560608,18432],"sh":[4534976,18432],"cn":[4608752,18432]}], +"levels/menu/main_menu_seg7.00018.rgba16.png": [32,32,2048,{"jp":[2770736,24],"us":[2778544,24],"eu":[2647072,24],"sh":[2625456,24],"cn":[2700128,24]}], +"levels/menu/main_menu_seg7.00818.rgba16.png": [32,32,2048,{"jp":[2770736,2072],"us":[2778544,2072],"eu":[2647072,2072],"sh":[2625456,2072],"cn":[2700128,2072]}], +"levels/menu/main_menu_seg7.01018.rgba16.png": [64,32,4096,{"jp":[2770736,4120],"us":[2778544,4120],"eu":[2647072,4120],"sh":[2625456,4120],"cn":[2700128,4120]}], +"levels/menu/main_menu_seg7.02018.rgba16.png": [64,32,4096,{"jp":[2770736,8216],"us":[2778544,8216],"eu":[2647072,8216],"sh":[2625456,8216],"cn":[2700128,8216]}], +"levels/menu/main_menu_seg7.03468.rgba16.png": [32,32,2048,{"jp":[2770736,13416],"us":[2778544,13416],"eu":[2647072,13416],"sh":[2625456,13416],"cn":[2700128,13416]}], +"levels/menu/main_menu_seg7.03C68.rgba16.png": [32,32,2048,{"jp":[2770736,15464],"us":[2778544,15464],"eu":[2647072,15464],"sh":[2625456,15464],"cn":[2700128,15464]}], +"levels/menu/main_menu_seg7.04468.rgba16.png": [32,32,2048,{"jp":[2770736,17512],"us":[2778544,17512],"eu":[2647072,17512],"sh":[2625456,17512],"cn":[2700128,17512]}], +"levels/menu/main_menu_seg7.04C68.rgba16.png": [32,32,2048,{"jp":[2770736,19560],"us":[2778544,19560],"eu":[2647072,19560],"sh":[2625456,19560],"cn":[2700128,19560]}], +"levels/menu/main_menu_seg7.05468.rgba16.png": [32,32,2048,{"jp":[2770736,21608],"us":[2778544,21608],"eu":[2647072,21608],"sh":[2625456,21608],"cn":[2700128,21608]}], +"levels/menu/main_menu_seg7.06328.rgba16.png": [32,32,2048,{"jp":[2770736,25384],"us":[2778544,25384],"eu":[2647072,25384],"sh":[2625456,25384],"cn":[2700128,25384]}], +"levels/menu/main_menu_seg7.06B28.rgba16.png": [32,32,2048,{"jp":[2770736,27432],"us":[2778544,27432],"eu":[2647072,27432],"sh":[2625456,27432],"cn":[2700128,27432]}], +"levels/menu/main_menu_seg7.073D0.rgba16.png": [16,16,512,{"jp":[2770736,29648],"us":[2778544,29648],"eu":[2647072,29648],"sh":[2625456,29648],"cn":[2700128,29648]}], +"levels/menu/main_menu_seg7.075D0.rgba16.png": [16,16,512,{"jp":[2770736,30160],"us":[2778544,30160],"eu":[2647072,30160],"sh":[2625456,30160],"cn":[2700128,30160]}], +"levels/menu/main_menu_seg7.077D0.rgba16.png": [16,16,512,{"jp":[2770736,30672],"us":[2778544,30672],"eu":[2647072,30672],"sh":[2625456,30672],"cn":[2700128,30672]}], +"levels/menu/main_menu_seg7.079D0.rgba16.png": [16,16,512,{"jp":[2770736,31184],"us":[2778544,31184],"eu":[2647072,31184],"sh":[2625456,31184],"cn":[2700128,31184]}], +"levels/menu/main_menu_seg7.07BD0.rgba16.png": [16,16,512,{"jp":[2770736,31696],"us":[2778544,31696],"eu":[2647072,31696],"sh":[2625456,31696],"cn":[2700128,31696]}], +"levels/menu/main_menu_seg7.07DD0.rgba16.png": [16,16,512,{"jp":[2770736,32208],"us":[2778544,32208],"eu":[2647072,32208],"sh":[2625456,32208],"cn":[2700128,32208]}], +"levels/menu/main_menu_seg7.07FD0.rgba16.png": [16,16,512,{"jp":[2770736,32720],"us":[2778544,32720],"eu":[2647072,32720],"sh":[2625456,32720],"cn":[2700128,32720]}], +"levels/menu/main_menu_seg7.081D0.rgba16.png": [16,16,512,{"jp":[2770736,33232],"us":[2778544,33232],"eu":[2647072,33232],"sh":[2625456,33232],"cn":[2700128,33232]}], +"levels/menu/main_menu_seg7.083D0.rgba16.png": [16,16,512,{"jp":[2770736,33744],"us":[2778544,33744],"eu":[2647072,33744],"sh":[2625456,33744],"cn":[2700128,33744]}], +"levels/menu/main_menu_seg7.085D0.rgba16.png": [16,16,512,{"jp":[2770736,34256],"us":[2778544,34256],"eu":[2647072,34256],"sh":[2625456,34256],"cn":[2700128,34256]}], +"levels/menu/main_menu_seg7.087D0.rgba16.png": [16,16,512,{"jp":[2770736,34768],"us":[2778544,34768],"eu":[2647072,34768],"sh":[2625456,34768],"cn":[2700128,34768]}], +"levels/menu/main_menu_seg7.089D0.rgba16.png": [16,16,512,{"jp":[2770736,35280],"us":[2778544,35280],"eu":[2647072,35280],"sh":[2625456,35280],"cn":[2700128,35280]}], +"levels/menu/main_menu_seg7.08BD0.rgba16.png": [16,16,512,{"jp":[2770736,35792],"us":[2778544,35792],"eu":[2647072,35792],"sh":[2625456,35792],"cn":[2700128,35792]}], +"levels/menu/main_menu_seg7.08DD0.rgba16.png": [16,16,512,{"jp":[2770736,36304],"us":[2778544,36304],"eu":[2647072,36304],"sh":[2625456,36304],"cn":[2700128,36304]}], +"levels/menu/main_menu_seg7.08FD0.rgba16.png": [16,16,512,{"jp":[2770736,36816],"us":[2778544,36816],"eu":[2647072,36816],"sh":[2625456,36816],"cn":[2700128,36816]}], +"levels/menu/main_menu_seg7.091D0.rgba16.png": [16,16,512,{"jp":[2770736,37328],"us":[2778544,37328],"eu":[2647072,37328],"sh":[2625456,37328],"cn":[2700128,37328]}], +"levels/menu/main_menu_seg7.093D0.rgba16.png": [16,16,512,{"jp":[2770736,37840],"us":[2778544,37840],"eu":[2647072,37840],"sh":[2625456,37840],"cn":[2700128,37840]}], +"levels/menu/main_menu_seg7.095D0.rgba16.png": [16,16,512,{"jp":[2770736,38352],"us":[2778544,38352],"eu":[2647072,38352],"sh":[2625456,38352],"cn":[2700128,38352]}], +"levels/menu/main_menu_seg7.097D0.rgba16.png": [16,16,512,{"jp":[2770736,38864],"us":[2778544,38864],"eu":[2647072,38864],"sh":[2625456,38864],"cn":[2700128,38864]}], +"levels/menu/main_menu_seg7.099D0.rgba16.png": [16,16,512,{"jp":[2770736,39376],"us":[2778544,39376],"eu":[2647072,39376],"sh":[2625456,39376],"cn":[2700128,39376]}], +"levels/menu/main_menu_seg7.09BD0.rgba16.png": [16,16,512,{"jp":[2770736,39888],"us":[2778544,39888],"eu":[2647072,39888],"sh":[2625456,39888],"cn":[2700128,39888]}], +"levels/menu/main_menu_seg7.09DD0.rgba16.png": [16,16,512,{"jp":[2770736,40400],"us":[2778544,40400],"eu":[2647072,40400],"sh":[2625456,40400],"cn":[2700128,40400]}], +"levels/menu/main_menu_seg7.09FD0.rgba16.png": [16,16,512,{"jp":[2770736,40912],"us":[2778544,40912],"eu":[2647072,40912],"sh":[2625456,40912],"cn":[2700128,40912]}], +"levels/menu/main_menu_seg7.0A1D0.rgba16.png": [16,16,512,{"jp":[1078992,20480],"us":[2778544,41424],"eu":[2647072,41424],"sh":[934640,20480],"cn":[2700128,41424]}], +"levels/menu/main_menu_seg7.0A3D0.rgba16.png": [16,16,512,{"jp":[2770736,41936],"us":[2778544,41936],"eu":[2647072,41936],"sh":[2625456,41936],"cn":[2700128,41936]}], +"levels/menu/main_menu_seg7.0A5D0.rgba16.png": [16,16,512,{"jp":[2770736,42448],"us":[2778544,42448],"eu":[2647072,42448],"sh":[2625456,42448],"cn":[2700128,42448]}], +"levels/menu/main_menu_seg7.0A7D0.rgba16.png": [16,16,512,{"jp":[2770736,42960],"us":[2778544,42960],"eu":[2647072,42960],"sh":[2625456,42960],"cn":[2700128,42960]}], +"levels/menu/main_menu_seg7.0A9D0.rgba16.png": [16,16,512,{"jp":[2770736,43472],"us":[2778544,43472],"eu":[2647072,43472],"sh":[2625456,43472],"cn":[2700128,43472]}], "levels/menu/main_menu_seg7.0AC48.ia8.png": [8,8,64,{"jp":[2770736,44104],"sh":[2625456,44104]}], "levels/menu/main_menu_seg7.0AC88.ia8.png": [8,8,64,{"jp":[2770736,44168],"sh":[2625456,44168]}], "levels/menu/main_menu_seg7.0ACC8.ia8.png": [8,8,64,{"jp":[2770736,44232],"sh":[2625456,44232]}], @@ -866,6 +871,8 @@ "levels/menu/main_menu_seg7.0CCC8.ia8.png": [8,8,64,{"jp":[2770736,52424],"sh":[2625456,52424]}], "levels/menu/main_menu_seg7.0D1A8.rgba16.png": [64,32,4096,{"jp":[2770736,53672],"us":[2778544,48352],"sh":[2625456,53672]}], "levels/menu/main_menu_seg7.0E1A8.rgba16.png": [64,32,4096,{"jp":[2770736,57768],"us":[2778544,52448],"sh":[2625456,57768]}], +"levels/menu/main_menu_seg7_cn.0BCE0.rgba16.png": [64,32,4096,{"cn":[2700128,48352]}], +"levels/menu/main_menu_seg7_cn.0CCE0.rgba16.png": [64,32,4096,{"cn":[2700128,52448]}], "levels/menu/main_menu_seg7_eu.0AF80.ia8.png": [8,8,64,{"eu":[2647072,44928]}], "levels/menu/main_menu_seg7_eu.0B640.ia8.png": [8,8,64,{"eu":[2647072,46656]}], "levels/menu/main_menu_seg7_eu.0B680.ia8.png": [8,8,64,{"eu":[2647072,46720]}], @@ -876,115 +883,115 @@ "levels/menu/main_menu_seg7_eu.0CDA0.rgba16.png": [64,32,4096,{"eu":[2647072,52640]}], "levels/menu/main_menu_seg7_eu.0DDA0.rgba16.png": [64,32,4096,{"eu":[2647072,56736]}], "levels/menu/main_menu_seg7_eu.0EDA0.rgba16.png": [64,32,4096,{"eu":[2647072,60832]}], -"levels/menu/main_menu_seg7_us.0AC40.ia8.png": [8,8,64,{"us":[2778544,44096],"eu":[2647072,44096]}], -"levels/menu/main_menu_seg7_us.0AC80.ia8.png": [8,8,64,{"us":[2778544,44160],"eu":[2647072,44160]}], -"levels/menu/main_menu_seg7_us.0ACC0.ia8.png": [8,8,64,{"us":[2778544,44224],"eu":[2647072,44224]}], -"levels/menu/main_menu_seg7_us.0AD00.ia8.png": [8,8,64,{"us":[2778544,44288],"eu":[2647072,44288]}], -"levels/menu/main_menu_seg7_us.0AD40.ia8.png": [8,8,64,{"us":[2778544,44352],"eu":[2647072,44352]}], -"levels/menu/main_menu_seg7_us.0AD80.ia8.png": [8,8,64,{"us":[2778544,44416],"eu":[2647072,44416]}], -"levels/menu/main_menu_seg7_us.0ADC0.ia8.png": [8,8,64,{"us":[2778544,44480],"eu":[2647072,44480]}], -"levels/menu/main_menu_seg7_us.0AE00.ia8.png": [8,8,64,{"us":[2778544,44544],"eu":[2647072,44544]}], -"levels/menu/main_menu_seg7_us.0AE40.ia8.png": [8,8,64,{"us":[2778544,44608],"eu":[2647072,44608]}], -"levels/menu/main_menu_seg7_us.0AE80.ia8.png": [8,8,64,{"us":[2778544,44672],"eu":[2647072,44672]}], -"levels/menu/main_menu_seg7_us.0AEC0.ia8.png": [8,8,64,{"us":[2778544,44736],"eu":[2647072,44736]}], -"levels/menu/main_menu_seg7_us.0AF00.ia8.png": [8,8,64,{"us":[2778544,44800],"eu":[2647072,44800]}], -"levels/menu/main_menu_seg7_us.0AF40.ia8.png": [8,8,64,{"us":[2778544,44864],"eu":[2647072,44864]}], -"levels/menu/main_menu_seg7_us.0AF80.ia8.png": [8,8,64,{"us":[2778544,44928]}], -"levels/menu/main_menu_seg7_us.0AFC0.ia8.png": [8,8,64,{"us":[2778544,44992],"eu":[2647072,44992]}], -"levels/menu/main_menu_seg7_us.0B000.ia8.png": [8,8,64,{"us":[2778544,45056],"eu":[2647072,45056]}], -"levels/menu/main_menu_seg7_us.0B040.ia8.png": [8,8,64,{"us":[2778544,45120],"eu":[2647072,45120]}], -"levels/menu/main_menu_seg7_us.0B080.ia8.png": [8,8,64,{"us":[2778544,45184],"eu":[2647072,45184]}], -"levels/menu/main_menu_seg7_us.0B0C0.ia8.png": [8,8,64,{"us":[2778544,45248],"eu":[2647072,45248]}], -"levels/menu/main_menu_seg7_us.0B100.ia8.png": [8,8,64,{"us":[2778544,45312],"eu":[2647072,45312]}], -"levels/menu/main_menu_seg7_us.0B140.ia8.png": [8,8,64,{"us":[2778544,45376],"eu":[2647072,45376]}], -"levels/menu/main_menu_seg7_us.0B180.ia8.png": [8,8,64,{"us":[2778544,45440],"eu":[2647072,45440]}], -"levels/menu/main_menu_seg7_us.0B1C0.ia8.png": [8,8,64,{"us":[2778544,45504],"eu":[2647072,45504]}], -"levels/menu/main_menu_seg7_us.0B200.ia8.png": [8,8,64,{"us":[2778544,45568],"eu":[2647072,45568]}], -"levels/menu/main_menu_seg7_us.0B240.ia8.png": [8,8,64,{"us":[2778544,45632],"eu":[2647072,45632]}], -"levels/menu/main_menu_seg7_us.0B280.ia8.png": [8,8,64,{"us":[2778544,45696],"eu":[2647072,45696]}], -"levels/menu/main_menu_seg7_us.0B2C0.ia8.png": [8,8,64,{"us":[2778544,45760],"eu":[2647072,45760]}], -"levels/menu/main_menu_seg7_us.0B300.ia8.png": [8,8,64,{"us":[2778544,45824],"eu":[2647072,45824]}], -"levels/menu/main_menu_seg7_us.0B340.ia8.png": [8,8,64,{"us":[2778544,45888],"eu":[2647072,45888]}], -"levels/menu/main_menu_seg7_us.0B380.ia8.png": [8,8,64,{"us":[2778544,45952],"eu":[2647072,45952]}], -"levels/menu/main_menu_seg7_us.0B3C0.ia8.png": [8,8,64,{"us":[2778544,46016],"eu":[2647072,46016]}], -"levels/menu/main_menu_seg7_us.0B400.ia8.png": [8,8,64,{"us":[2778544,46080],"eu":[2647072,46080]}], -"levels/menu/main_menu_seg7_us.0B440.ia8.png": [8,8,64,{"us":[2778544,46144],"eu":[2647072,46144]}], -"levels/menu/main_menu_seg7_us.0B480.ia8.png": [8,8,64,{"us":[2778544,46208],"eu":[2647072,46208]}], -"levels/menu/main_menu_seg7_us.0B4C0.ia8.png": [8,8,64,{"us":[2778544,46272],"eu":[2647072,46272]}], -"levels/menu/main_menu_seg7_us.0B500.ia8.png": [8,8,64,{"us":[2778544,46336],"eu":[2647072,46336]}], -"levels/menu/main_menu_seg7_us.0B540.ia8.png": [8,8,64,{"us":[2778544,46400],"eu":[2647072,46400]}], -"levels/menu/main_menu_seg7_us.0B580.ia8.png": [8,8,64,{"us":[2778544,46464],"eu":[2647072,46464]}], -"levels/menu/main_menu_seg7_us.0B5C0.ia8.png": [8,8,64,{"us":[2778544,46528],"eu":[2647072,46528]}], -"levels/menu/main_menu_seg7_us.0B600.ia8.png": [8,8,64,{"us":[2778544,46592],"eu":[2647072,46592]}], -"levels/menu/main_menu_seg7_us.0B640.ia8.png": [8,8,64,{"us":[2778544,46656]}], -"levels/menu/main_menu_seg7_us.0B680.ia8.png": [8,8,64,{"us":[2778544,46720]}], -"levels/menu/main_menu_seg7_us.0B6C0.ia8.png": [8,8,64,{"us":[2778544,46784],"eu":[2647072,46784]}], -"levels/menu/main_menu_seg7_us.0B700.ia8.png": [8,8,64,{"us":[2778544,46848],"eu":[2647072,46848]}], -"levels/menu/main_menu_seg7_us.0B740.ia8.png": [8,8,64,{"us":[2778544,46912],"eu":[2647072,46912]}], -"levels/menu/main_menu_seg7_us.0B780.ia8.png": [8,8,64,{"us":[2778544,46976],"eu":[2647072,46976]}], -"levels/menu/main_menu_seg7_us.0B7C0.ia8.png": [8,8,64,{"us":[2778544,46648],"eu":[2647072,47040]}], -"levels/menu/main_menu_seg7_us.0B800.ia8.png": [8,8,64,{"us":[2778544,47104],"eu":[2647072,47104]}], -"levels/pss/0.rgba16.png": [32,32,2048,{"jp":[4905168,0],"us":[4913456,0],"eu":[4792384,0],"sh":[4761424,0]}], -"levels/pss/1.ia16.png": [32,32,2048,{"jp":[4905168,2048],"us":[4913456,2048],"eu":[4792384,2048],"sh":[4761424,2048]}], -"levels/pss/2.rgba16.png": [32,32,2048,{"jp":[4905168,4096],"us":[4913456,4096],"eu":[4792384,4096],"sh":[4761424,4096]}], -"levels/rr/1.rgba16.png": [64,32,4096,{"jp":[4413648,2048],"us":[4421744,2048],"eu":[4295344,2048],"sh":[4269712,2048]}], -"levels/rr/2.rgba16.png": [32,32,2048,{"jp":[4413648,6144],"us":[4421744,6144],"eu":[4295344,6144],"sh":[4269712,6144]}], -"levels/rr/quarter_flying_carpet.rgba16.png": [32,32,2048,{"jp":[4413648,0],"us":[4421744,0],"eu":[4295344,0],"sh":[4269712,0]}], -"levels/sl/0.rgba16.png": [32,32,2048,{"jp":[4210704,0],"us":[4218800,0],"eu":[4092400,0],"sh":[4066768,0]}], -"levels/sl/1.rgba16.png": [32,32,2048,{"jp":[4210704,2048],"us":[4218800,2048],"eu":[4092400,2048],"sh":[4066768,2048]}], -"levels/sl/2.rgba16.png": [32,32,2048,{"jp":[4210704,4096],"us":[4218800,4096],"eu":[4092400,4096],"sh":[4066768,4096]}], -"levels/sl/3.rgba16.png": [32,32,2048,{"jp":[4210704,6144],"us":[4218800,6144],"eu":[4092400,6144],"sh":[4066768,6144]}], -"levels/sl/4.rgba16.png": [32,32,2048,{"jp":[4210704,8192],"us":[4218800,8192],"eu":[4092400,8192],"sh":[4066768,8192]}], -"levels/ssl/0.rgba16.png": [32,32,2048,{"jp":[4085520,0],"us":[4093616,0],"eu":[3967216,0],"sh":[3941584,0]}], -"levels/ssl/1.ia16.png": [32,32,2048,{"jp":[4085520,2048],"us":[4093616,2048],"eu":[3967216,2048],"sh":[3941584,2048]}], -"levels/ssl/10.rgba16.png": [32,64,4096,{"jp":[4085520,55208],"us":[4093616,55208],"eu":[3967216,55208],"sh":[3941584,55208]}], -"levels/ssl/11.rgba16.png": [32,64,4096,{"jp":[4085520,59304],"us":[4093616,59304],"eu":[3967216,59304],"sh":[3941584,59304]}], -"levels/ssl/2.rgba16.png": [32,32,2048,{"jp":[4085520,4096],"us":[4093616,4096],"eu":[3967216,4096],"sh":[3941584,4096]}], -"levels/ssl/3.rgba16.png": [32,32,2048,{"jp":[4085520,6144],"us":[4093616,6144],"eu":[3967216,6144],"sh":[3941584,6144]}], -"levels/ssl/4.rgba16.png": [32,32,2048,{"jp":[4085520,8192],"us":[4093616,8192],"eu":[3967216,8192],"sh":[3941584,8192]}], -"levels/ssl/5.rgba16.png": [32,64,4096,{"jp":[4085520,10240],"us":[4093616,10240],"eu":[3967216,10240],"sh":[3941584,10240]}], -"levels/ssl/6.rgba16.png": [32,32,2048,{"jp":[4085520,14336],"us":[4093616,14336],"eu":[3967216,14336],"sh":[3941584,14336]}], -"levels/ssl/7.rgba16.png": [32,32,2048,{"jp":[3323408,32768],"us":[3330160,32768],"eu":[3203760,32768],"sh":[3178128,32768]}], -"levels/ssl/8.rgba16.png": [32,32,2048,{"jp":[4085520,49064],"us":[4093616,49064],"eu":[3967216,49064],"sh":[3941584,49064]}], -"levels/ssl/9.rgba16.png": [32,64,4096,{"jp":[4085520,51112],"us":[4093616,51112],"eu":[3967216,51112],"sh":[3941584,51112]}], -"levels/thi/0.rgba16.png": [32,32,2048,{"jp":[4335408,0],"us":[4343504,0],"eu":[4217104,0],"sh":[4191472,0]}], -"levels/thi/1.rgba16.png": [32,32,2048,{"jp":[4335408,2048],"us":[4343504,2048],"eu":[4217104,2048],"sh":[4191472,2048]}], -"levels/totwc/0.rgba16.png": [32,64,4096,{"jp":[4967376,0],"us":[4975664,0],"eu":[4854592,0],"sh":[4823632,0]}], -"levels/totwc/1.rgba16.png": [32,32,2048,{"jp":[4967376,4096],"us":[4975664,4096],"eu":[4854592,4096],"sh":[4823632,4096]}], -"levels/totwc/2.rgba16.png": [32,32,2048,{"jp":[4967376,6144],"us":[4975664,6144],"eu":[4854592,6144],"sh":[4823632,6144]}], -"levels/totwc/3.ia16.png": [32,32,2048,{"jp":[4967376,8192],"us":[4975664,8192],"eu":[4854592,8192],"sh":[4823632,8192]}], -"levels/ttc/0.rgba16.png": [32,32,2048,{"jp":[4370304,0],"us":[4378400,0],"eu":[4252000,0],"sh":[4226368,0]}], -"levels/ttc/1.rgba16.png": [16,64,2048,{"jp":[4370304,2048],"us":[4378400,2048],"eu":[4252000,2048],"sh":[4226368,2048]}], -"levels/ttc/2.rgba16.png": [32,32,2048,{"jp":[4370304,90000],"us":[4378400,90000],"eu":[4252000,90000],"sh":[4226368,90000]}], -"levels/ttm/0.ia16.png": [32,32,2048,{"jp":[5044400,0],"us":[5052688,0],"eu":[4931616,0],"sh":[4900656,0]}], -"levels/ttm/1.rgba16.png": [32,32,2048,{"jp":[5044400,2048],"us":[5052688,2048],"eu":[4931616,2048],"sh":[4900656,2048]}], -"levels/ttm/2.rgba16.png": [32,32,2048,{"jp":[5044400,4096],"us":[5052688,4096],"eu":[4931616,4096],"sh":[4900656,4096]}], -"levels/ttm/3.rgba16.png": [32,32,2048,{"jp":[5044400,6144],"us":[5052688,6144],"eu":[4931616,6144],"sh":[4900656,6144]}], -"levels/ttm/4.rgba16.png": [32,32,2048,{"jp":[5044400,8192],"us":[5052688,8192],"eu":[4931616,8192],"sh":[4900656,8192]}], -"levels/ttm/5.rgba16.png": [32,32,2048,{"jp":[5044400,10240],"us":[5052688,10240],"eu":[4931616,10240],"sh":[4900656,10240]}], -"levels/ttm/6.rgba16.png": [64,32,4096,{"jp":[5044400,12288],"us":[5052688,12288],"eu":[4931616,12288],"sh":[4900656,12288]}], -"levels/ttm/7.rgba16.png": [64,32,4096,{"jp":[5044400,16384],"us":[5052688,16384],"eu":[4931616,16384],"sh":[4900656,16384]}], -"levels/ttm/8.rgba16.png": [32,32,2048,{"jp":[3473152,43008],"us":[3479904,43008],"eu":[3353504,43008],"sh":[3327872,43008]}], -"levels/vcutm/0.rgba16.png": [32,32,2048,{"jp":[4564288,0],"us":[4572672,0],"eu":[4446272,0],"sh":[4420640,0]}], -"levels/vcutm/1.rgba16.png": [64,32,4096,{"jp":[4564288,2048],"us":[4572672,2048],"eu":[4446272,2048],"sh":[4420640,2048]}], -"levels/vcutm/2.rgba16.png": [32,64,4096,{"jp":[4564288,6144],"us":[4572672,6144],"eu":[4446272,6144],"sh":[4420640,6144]}], -"levels/vcutm/3.rgba16.png": [32,32,2048,{"jp":[4564288,10240],"us":[4572672,10240],"eu":[4446272,10240],"sh":[4420640,10240]}], -"levels/wdw/0.rgba16.png": [32,32,2048,{"jp":[4246992,0],"us":[4255088,0],"eu":[4128688,0],"sh":[4103056,0]}], -"levels/wdw/1.rgba16.png": [32,32,2048,{"jp":[4246992,2048],"us":[4255088,2048],"eu":[4128688,2048],"sh":[4103056,2048]}], -"levels/wdw/2.rgba16.png": [32,32,2048,{"jp":[4246992,4096],"us":[4255088,4096],"eu":[4128688,4096],"sh":[4103056,4096]}], -"levels/wdw/3.rgba16.png": [32,32,2048,{"jp":[4246992,6144],"us":[4255088,6144],"eu":[4128688,6144],"sh":[4103056,6144]}], -"levels/wdw/4.rgba16.png": [32,32,2048,{"jp":[4246992,8192],"us":[4255088,8192],"eu":[4128688,8192],"sh":[4103056,8192]}], -"levels/wf/0.rgba16.png": [32,32,2048,{"jp":[4800560,0],"us":[4808848,0],"eu":[4682448,0],"sh":[4656816,0]}], -"levels/wf/1.rgba16.png": [32,32,2048,{"jp":[4800560,2048],"us":[4808848,2048],"eu":[4682448,2048],"sh":[4656816,2048]}], -"levels/wf/2.rgba16.png": [32,32,2048,{"jp":[4800560,4096],"us":[4808848,4096],"eu":[4682448,4096],"sh":[4656816,4096]}], -"levels/wf/3.rgba16.png": [32,32,2048,{"jp":[4800560,6144],"us":[4808848,6144],"eu":[4682448,6144],"sh":[4656816,6144]}], -"levels/wf/4.rgba16.png": [32,32,2048,{"jp":[4800560,8192],"us":[4808848,8192],"eu":[4682448,8192],"sh":[4656816,8192]}], -"levels/wf/5.ia8.png": [16,16,256,{"jp":[1078992,62296],"us":[1083968,74168],"eu":[909712,30840],"sh":[934640,62296]}], -"levels/wmotr/0.rgba16.png": [32,32,2048,{"jp":[4989632,0],"us":[4997920,0],"eu":[4876848,0],"sh":[4845888,0]}], -"levels/wmotr/1.rgba16.png": [32,16,1024,{"jp":[4989632,2048],"us":[4997920,2048],"eu":[4876848,2048],"sh":[4845888,2048]}], -"levels/wmotr/2.rgba16.png": [32,32,2048,{"jp":[4989632,3072],"us":[4997920,3072],"eu":[4876848,3072],"sh":[4845888,3072]}], -"levels/wmotr/3.rgba16.png": [32,8,512,{"jp":[4989632,5120],"us":[4997920,5120],"eu":[4876848,5120],"sh":[4845888,5120]}], -"levels/wmotr/4.rgba16.png": [8,32,512,{"jp":[4989632,5632],"us":[4997920,5632],"eu":[4876848,5632],"sh":[4845888,5632]}], +"levels/menu/main_menu_seg7_us.0AC40.ia8.png": [8,8,64,{"us":[2778544,44096],"eu":[2647072,44096],"cn":[2700128,44096]}], +"levels/menu/main_menu_seg7_us.0AC80.ia8.png": [8,8,64,{"us":[2778544,44160],"eu":[2647072,44160],"cn":[2700128,44160]}], +"levels/menu/main_menu_seg7_us.0ACC0.ia8.png": [8,8,64,{"us":[2778544,44224],"eu":[2647072,44224],"cn":[2700128,44224]}], +"levels/menu/main_menu_seg7_us.0AD00.ia8.png": [8,8,64,{"us":[2778544,44288],"eu":[2647072,44288],"cn":[2700128,44288]}], +"levels/menu/main_menu_seg7_us.0AD40.ia8.png": [8,8,64,{"us":[2778544,44352],"eu":[2647072,44352],"cn":[2700128,44352]}], +"levels/menu/main_menu_seg7_us.0AD80.ia8.png": [8,8,64,{"us":[2778544,44416],"eu":[2647072,44416],"cn":[2700128,44416]}], +"levels/menu/main_menu_seg7_us.0ADC0.ia8.png": [8,8,64,{"us":[2778544,44480],"eu":[2647072,44480],"cn":[2700128,44480]}], +"levels/menu/main_menu_seg7_us.0AE00.ia8.png": [8,8,64,{"us":[2778544,44544],"eu":[2647072,44544],"cn":[2700128,44544]}], +"levels/menu/main_menu_seg7_us.0AE40.ia8.png": [8,8,64,{"us":[2778544,44608],"eu":[2647072,44608],"cn":[2700128,44608]}], +"levels/menu/main_menu_seg7_us.0AE80.ia8.png": [8,8,64,{"us":[2778544,44672],"eu":[2647072,44672],"cn":[2700128,44672]}], +"levels/menu/main_menu_seg7_us.0AEC0.ia8.png": [8,8,64,{"us":[2778544,44736],"eu":[2647072,44736],"cn":[2700128,44736]}], +"levels/menu/main_menu_seg7_us.0AF00.ia8.png": [8,8,64,{"us":[2778544,44800],"eu":[2647072,44800],"cn":[2700128,44800]}], +"levels/menu/main_menu_seg7_us.0AF40.ia8.png": [8,8,64,{"us":[2778544,44864],"eu":[2647072,44864],"cn":[2700128,44864]}], +"levels/menu/main_menu_seg7_us.0AF80.ia8.png": [8,8,64,{"us":[2778544,44928],"cn":[2700128,44928]}], +"levels/menu/main_menu_seg7_us.0AFC0.ia8.png": [8,8,64,{"us":[2778544,44992],"eu":[2647072,44992],"cn":[2700128,44992]}], +"levels/menu/main_menu_seg7_us.0B000.ia8.png": [8,8,64,{"us":[2778544,45056],"eu":[2647072,45056],"cn":[2700128,45056]}], +"levels/menu/main_menu_seg7_us.0B040.ia8.png": [8,8,64,{"us":[2778544,45120],"eu":[2647072,45120],"cn":[2700128,45120]}], +"levels/menu/main_menu_seg7_us.0B080.ia8.png": [8,8,64,{"us":[2778544,45184],"eu":[2647072,45184],"cn":[2700128,45184]}], +"levels/menu/main_menu_seg7_us.0B0C0.ia8.png": [8,8,64,{"us":[2778544,45248],"eu":[2647072,45248],"cn":[2700128,45248]}], +"levels/menu/main_menu_seg7_us.0B100.ia8.png": [8,8,64,{"us":[2778544,45312],"eu":[2647072,45312],"cn":[2700128,45312]}], +"levels/menu/main_menu_seg7_us.0B140.ia8.png": [8,8,64,{"us":[2778544,45376],"eu":[2647072,45376],"cn":[2700128,45376]}], +"levels/menu/main_menu_seg7_us.0B180.ia8.png": [8,8,64,{"us":[2778544,45440],"eu":[2647072,45440],"cn":[2700128,45440]}], +"levels/menu/main_menu_seg7_us.0B1C0.ia8.png": [8,8,64,{"us":[2778544,45504],"eu":[2647072,45504],"cn":[2700128,45504]}], +"levels/menu/main_menu_seg7_us.0B200.ia8.png": [8,8,64,{"us":[2778544,45568],"eu":[2647072,45568],"cn":[2700128,45568]}], +"levels/menu/main_menu_seg7_us.0B240.ia8.png": [8,8,64,{"us":[2778544,45632],"eu":[2647072,45632],"cn":[2700128,45632]}], +"levels/menu/main_menu_seg7_us.0B280.ia8.png": [8,8,64,{"us":[2778544,45696],"eu":[2647072,45696],"cn":[2700128,45696]}], +"levels/menu/main_menu_seg7_us.0B2C0.ia8.png": [8,8,64,{"us":[2778544,45760],"eu":[2647072,45760],"cn":[2700128,45760]}], +"levels/menu/main_menu_seg7_us.0B300.ia8.png": [8,8,64,{"us":[2778544,45824],"eu":[2647072,45824],"cn":[2700128,45824]}], +"levels/menu/main_menu_seg7_us.0B340.ia8.png": [8,8,64,{"us":[2778544,45888],"eu":[2647072,45888],"cn":[2700128,45888]}], +"levels/menu/main_menu_seg7_us.0B380.ia8.png": [8,8,64,{"us":[2778544,45952],"eu":[2647072,45952],"cn":[2700128,45952]}], +"levels/menu/main_menu_seg7_us.0B3C0.ia8.png": [8,8,64,{"us":[2778544,46016],"eu":[2647072,46016],"cn":[2700128,46016]}], +"levels/menu/main_menu_seg7_us.0B400.ia8.png": [8,8,64,{"us":[2778544,46080],"eu":[2647072,46080],"cn":[2700128,46080]}], +"levels/menu/main_menu_seg7_us.0B440.ia8.png": [8,8,64,{"us":[2778544,46144],"eu":[2647072,46144],"cn":[2700128,46144]}], +"levels/menu/main_menu_seg7_us.0B480.ia8.png": [8,8,64,{"us":[2778544,46208],"eu":[2647072,46208],"cn":[2700128,46208]}], +"levels/menu/main_menu_seg7_us.0B4C0.ia8.png": [8,8,64,{"us":[2778544,46272],"eu":[2647072,46272],"cn":[2700128,46272]}], +"levels/menu/main_menu_seg7_us.0B500.ia8.png": [8,8,64,{"us":[2778544,46336],"eu":[2647072,46336],"cn":[2700128,46336]}], +"levels/menu/main_menu_seg7_us.0B540.ia8.png": [8,8,64,{"us":[2778544,46400],"eu":[2647072,46400],"cn":[2700128,46400]}], +"levels/menu/main_menu_seg7_us.0B580.ia8.png": [8,8,64,{"us":[2778544,46464],"eu":[2647072,46464],"cn":[2700128,46464]}], +"levels/menu/main_menu_seg7_us.0B5C0.ia8.png": [8,8,64,{"us":[2778544,46528],"eu":[2647072,46528],"cn":[2700128,46528]}], +"levels/menu/main_menu_seg7_us.0B600.ia8.png": [8,8,64,{"us":[2778544,46592],"eu":[2647072,46592],"cn":[2700128,46592]}], +"levels/menu/main_menu_seg7_us.0B640.ia8.png": [8,8,64,{"us":[2778544,46656],"cn":[2700128,46656]}], +"levels/menu/main_menu_seg7_us.0B680.ia8.png": [8,8,64,{"us":[2778544,46720],"cn":[2700128,46720]}], +"levels/menu/main_menu_seg7_us.0B6C0.ia8.png": [8,8,64,{"us":[2778544,46784],"eu":[2647072,46784],"cn":[2700128,46784]}], +"levels/menu/main_menu_seg7_us.0B700.ia8.png": [8,8,64,{"us":[2778544,46848],"eu":[2647072,46848],"cn":[2700128,46848]}], +"levels/menu/main_menu_seg7_us.0B740.ia8.png": [8,8,64,{"us":[2778544,46912],"eu":[2647072,46912],"cn":[2700128,46912]}], +"levels/menu/main_menu_seg7_us.0B780.ia8.png": [8,8,64,{"us":[2778544,46976],"eu":[2647072,46976],"cn":[2700128,46976]}], +"levels/menu/main_menu_seg7_us.0B7C0.ia8.png": [8,8,64,{"us":[2778544,46648],"eu":[2647072,47040],"cn":[2700128,46648]}], +"levels/menu/main_menu_seg7_us.0B800.ia8.png": [8,8,64,{"us":[2778544,47104],"eu":[2647072,47104],"cn":[2700128,47104]}], +"levels/pss/0.rgba16.png": [32,32,2048,{"jp":[4905168,0],"us":[4913456,0],"eu":[4792384,0],"sh":[4761424,0],"cn":[4834432,0]}], +"levels/pss/1.ia16.png": [32,32,2048,{"jp":[4905168,2048],"us":[4913456,2048],"eu":[4792384,2048],"sh":[4761424,2048],"cn":[4834432,2048]}], +"levels/pss/2.rgba16.png": [32,32,2048,{"jp":[4905168,4096],"us":[4913456,4096],"eu":[4792384,4096],"sh":[4761424,4096],"cn":[4834432,4096]}], +"levels/rr/1.rgba16.png": [64,32,4096,{"jp":[4413648,2048],"us":[4421744,2048],"eu":[4295344,2048],"sh":[4269712,2048],"cn":[4343488,2048]}], +"levels/rr/2.rgba16.png": [32,32,2048,{"jp":[4413648,6144],"us":[4421744,6144],"eu":[4295344,6144],"sh":[4269712,6144],"cn":[4343488,6144]}], +"levels/rr/quarter_flying_carpet.rgba16.png": [32,32,2048,{"jp":[4413648,0],"us":[4421744,0],"eu":[4295344,0],"sh":[4269712,0],"cn":[4343488,0]}], +"levels/sl/0.rgba16.png": [32,32,2048,{"jp":[4210704,0],"us":[4218800,0],"eu":[4092400,0],"sh":[4066768,0],"cn":[4140544,0]}], +"levels/sl/1.rgba16.png": [32,32,2048,{"jp":[4210704,2048],"us":[4218800,2048],"eu":[4092400,2048],"sh":[4066768,2048],"cn":[4140544,2048]}], +"levels/sl/2.rgba16.png": [32,32,2048,{"jp":[4210704,4096],"us":[4218800,4096],"eu":[4092400,4096],"sh":[4066768,4096],"cn":[4140544,4096]}], +"levels/sl/3.rgba16.png": [32,32,2048,{"jp":[4210704,6144],"us":[4218800,6144],"eu":[4092400,6144],"sh":[4066768,6144],"cn":[4140544,6144]}], +"levels/sl/4.rgba16.png": [32,32,2048,{"jp":[4210704,8192],"us":[4218800,8192],"eu":[4092400,8192],"sh":[4066768,8192],"cn":[4140544,8192]}], +"levels/ssl/0.rgba16.png": [32,32,2048,{"jp":[4085520,0],"us":[4093616,0],"eu":[3967216,0],"sh":[3941584,0],"cn":[4015360,0]}], +"levels/ssl/1.ia16.png": [32,32,2048,{"jp":[4085520,2048],"us":[4093616,2048],"eu":[3967216,2048],"sh":[3941584,2048],"cn":[4015360,2048]}], +"levels/ssl/10.rgba16.png": [32,64,4096,{"jp":[4085520,55208],"us":[4093616,55208],"eu":[3967216,55208],"sh":[3941584,55208],"cn":[4015360,55208]}], +"levels/ssl/11.rgba16.png": [32,64,4096,{"jp":[4085520,59304],"us":[4093616,59304],"eu":[3967216,59304],"sh":[3941584,59304],"cn":[4015360,59304]}], +"levels/ssl/2.rgba16.png": [32,32,2048,{"jp":[4085520,4096],"us":[4093616,4096],"eu":[3967216,4096],"sh":[3941584,4096],"cn":[4015360,4096]}], +"levels/ssl/3.rgba16.png": [32,32,2048,{"jp":[4085520,6144],"us":[4093616,6144],"eu":[3967216,6144],"sh":[3941584,6144],"cn":[4015360,6144]}], +"levels/ssl/4.rgba16.png": [32,32,2048,{"jp":[4085520,8192],"us":[4093616,8192],"eu":[3967216,8192],"sh":[3941584,8192],"cn":[4015360,8192]}], +"levels/ssl/5.rgba16.png": [32,64,4096,{"jp":[4085520,10240],"us":[4093616,10240],"eu":[3967216,10240],"sh":[3941584,10240],"cn":[4015360,10240]}], +"levels/ssl/6.rgba16.png": [32,32,2048,{"jp":[4085520,14336],"us":[4093616,14336],"eu":[3967216,14336],"sh":[3941584,14336],"cn":[4015360,14336]}], +"levels/ssl/7.rgba16.png": [32,32,2048,{"jp":[3323408,32768],"us":[3330160,32768],"eu":[3203760,32768],"sh":[3178128,32768],"cn":[3251888,32768]}], +"levels/ssl/8.rgba16.png": [32,32,2048,{"jp":[4085520,49064],"us":[4093616,49064],"eu":[3967216,49064],"sh":[3941584,49064],"cn":[4015360,49064]}], +"levels/ssl/9.rgba16.png": [32,64,4096,{"jp":[4085520,51112],"us":[4093616,51112],"eu":[3967216,51112],"sh":[3941584,51112],"cn":[4015360,51112]}], +"levels/thi/0.rgba16.png": [32,32,2048,{"jp":[4335408,0],"us":[4343504,0],"eu":[4217104,0],"sh":[4191472,0],"cn":[4265248,0]}], +"levels/thi/1.rgba16.png": [32,32,2048,{"jp":[4335408,2048],"us":[4343504,2048],"eu":[4217104,2048],"sh":[4191472,2048],"cn":[4265248,2048]}], +"levels/totwc/0.rgba16.png": [32,64,4096,{"jp":[4967376,0],"us":[4975664,0],"eu":[4854592,0],"sh":[4823632,0],"cn":[4896640,0]}], +"levels/totwc/1.rgba16.png": [32,32,2048,{"jp":[4967376,4096],"us":[4975664,4096],"eu":[4854592,4096],"sh":[4823632,4096],"cn":[4896640,4096]}], +"levels/totwc/2.rgba16.png": [32,32,2048,{"jp":[4967376,6144],"us":[4975664,6144],"eu":[4854592,6144],"sh":[4823632,6144],"cn":[4896640,6144]}], +"levels/totwc/3.ia16.png": [32,32,2048,{"jp":[4967376,8192],"us":[4975664,8192],"eu":[4854592,8192],"sh":[4823632,8192],"cn":[4896640,8192]}], +"levels/ttc/0.rgba16.png": [32,32,2048,{"jp":[4370304,0],"us":[4378400,0],"eu":[4252000,0],"sh":[4226368,0],"cn":[4300144,0]}], +"levels/ttc/1.rgba16.png": [16,64,2048,{"jp":[4370304,2048],"us":[4378400,2048],"eu":[4252000,2048],"sh":[4226368,2048],"cn":[4300144,2048]}], +"levels/ttc/2.rgba16.png": [32,32,2048,{"jp":[4370304,90000],"us":[4378400,90000],"eu":[4252000,90000],"sh":[4226368,90000],"cn":[4300144,90000]}], +"levels/ttm/0.ia16.png": [32,32,2048,{"jp":[5044400,0],"us":[5052688,0],"eu":[4931616,0],"sh":[4900656,0],"cn":[4973680,0]}], +"levels/ttm/1.rgba16.png": [32,32,2048,{"jp":[5044400,2048],"us":[5052688,2048],"eu":[4931616,2048],"sh":[4900656,2048],"cn":[4973680,2048]}], +"levels/ttm/2.rgba16.png": [32,32,2048,{"jp":[5044400,4096],"us":[5052688,4096],"eu":[4931616,4096],"sh":[4900656,4096],"cn":[4973680,4096]}], +"levels/ttm/3.rgba16.png": [32,32,2048,{"jp":[5044400,6144],"us":[5052688,6144],"eu":[4931616,6144],"sh":[4900656,6144],"cn":[4973680,6144]}], +"levels/ttm/4.rgba16.png": [32,32,2048,{"jp":[5044400,8192],"us":[5052688,8192],"eu":[4931616,8192],"sh":[4900656,8192],"cn":[4973680,8192]}], +"levels/ttm/5.rgba16.png": [32,32,2048,{"jp":[5044400,10240],"us":[5052688,10240],"eu":[4931616,10240],"sh":[4900656,10240],"cn":[4973680,10240]}], +"levels/ttm/6.rgba16.png": [64,32,4096,{"jp":[5044400,12288],"us":[5052688,12288],"eu":[4931616,12288],"sh":[4900656,12288],"cn":[4973680,12288]}], +"levels/ttm/7.rgba16.png": [64,32,4096,{"jp":[5044400,16384],"us":[5052688,16384],"eu":[4931616,16384],"sh":[4900656,16384],"cn":[4973680,16384]}], +"levels/ttm/8.rgba16.png": [32,32,2048,{"jp":[3473152,43008],"us":[3479904,43008],"eu":[3353504,43008],"sh":[3327872,43008],"cn":[3401632,43008]}], +"levels/vcutm/0.rgba16.png": [32,32,2048,{"jp":[4564288,0],"us":[4572672,0],"eu":[4446272,0],"sh":[4420640,0],"cn":[4494416,0]}], +"levels/vcutm/1.rgba16.png": [64,32,4096,{"jp":[4564288,2048],"us":[4572672,2048],"eu":[4446272,2048],"sh":[4420640,2048],"cn":[4494416,2048]}], +"levels/vcutm/2.rgba16.png": [32,64,4096,{"jp":[4564288,6144],"us":[4572672,6144],"eu":[4446272,6144],"sh":[4420640,6144],"cn":[4494416,6144]}], +"levels/vcutm/3.rgba16.png": [32,32,2048,{"jp":[4564288,10240],"us":[4572672,10240],"eu":[4446272,10240],"sh":[4420640,10240],"cn":[4494416,10240]}], +"levels/wdw/0.rgba16.png": [32,32,2048,{"jp":[4246992,0],"us":[4255088,0],"eu":[4128688,0],"sh":[4103056,0],"cn":[4176832,0]}], +"levels/wdw/1.rgba16.png": [32,32,2048,{"jp":[4246992,2048],"us":[4255088,2048],"eu":[4128688,2048],"sh":[4103056,2048],"cn":[4176832,2048]}], +"levels/wdw/2.rgba16.png": [32,32,2048,{"jp":[4246992,4096],"us":[4255088,4096],"eu":[4128688,4096],"sh":[4103056,4096],"cn":[4176832,4096]}], +"levels/wdw/3.rgba16.png": [32,32,2048,{"jp":[4246992,6144],"us":[4255088,6144],"eu":[4128688,6144],"sh":[4103056,6144],"cn":[4176832,6144]}], +"levels/wdw/4.rgba16.png": [32,32,2048,{"jp":[4246992,8192],"us":[4255088,8192],"eu":[4128688,8192],"sh":[4103056,8192],"cn":[4176832,8192]}], +"levels/wf/0.rgba16.png": [32,32,2048,{"jp":[4800560,0],"us":[4808848,0],"eu":[4682448,0],"sh":[4656816,0],"cn":[4730592,0]}], +"levels/wf/1.rgba16.png": [32,32,2048,{"jp":[4800560,2048],"us":[4808848,2048],"eu":[4682448,2048],"sh":[4656816,2048],"cn":[4730592,2048]}], +"levels/wf/2.rgba16.png": [32,32,2048,{"jp":[4800560,4096],"us":[4808848,4096],"eu":[4682448,4096],"sh":[4656816,4096],"cn":[4730592,4096]}], +"levels/wf/3.rgba16.png": [32,32,2048,{"jp":[4800560,6144],"us":[4808848,6144],"eu":[4682448,6144],"sh":[4656816,6144],"cn":[4730592,6144]}], +"levels/wf/4.rgba16.png": [32,32,2048,{"jp":[4800560,8192],"us":[4808848,8192],"eu":[4682448,8192],"sh":[4656816,8192],"cn":[4730592,8192]}], +"levels/wf/5.ia8.png": [16,16,256,{"jp":[1078992,62296],"us":[1083968,74168],"eu":[909712,30840],"sh":[934640,62296],"cn":[947456,174632]}], +"levels/wmotr/0.rgba16.png": [32,32,2048,{"jp":[4989632,0],"us":[4997920,0],"eu":[4876848,0],"sh":[4845888,0],"cn":[4918912,0]}], +"levels/wmotr/1.rgba16.png": [32,16,1024,{"jp":[4989632,2048],"us":[4997920,2048],"eu":[4876848,2048],"sh":[4845888,2048],"cn":[4918912,2048]}], +"levels/wmotr/2.rgba16.png": [32,32,2048,{"jp":[4989632,3072],"us":[4997920,3072],"eu":[4876848,3072],"sh":[4845888,3072],"cn":[4918912,3072]}], +"levels/wmotr/3.rgba16.png": [32,8,512,{"jp":[4989632,5120],"us":[4997920,5120],"eu":[4876848,5120],"sh":[4845888,5120],"cn":[4918912,5120]}], +"levels/wmotr/4.rgba16.png": [8,32,512,{"jp":[4989632,5632],"us":[4997920,5632],"eu":[4876848,5632],"sh":[4845888,5632],"cn":[4918912,5632]}], "sound/sequences/eu/01_cutscene_collect_star.m64": [626,{"eu":[7954384]}], "sound/sequences/eu/02_menu_title_screen.m64": [8282,{"eu":[7955024]}], "sound/sequences/eu/03_level_grass.m64": [5131,{"eu":[7963312]}], @@ -1052,40 +1059,40 @@ "sound/sequences/jp/1F_cutscene_victory.m64": [2074,{"jp":[7735392]}], "sound/sequences/jp/20_cutscene_ending.m64": [1892,{"jp":[7737472]}], "sound/sequences/jp/21_menu_file_select.m64": [789,{"jp":[7739376]}], -"sound/sequences/sh/01_cutscene_collect_star.m64": [626,{"sh":[7884144]}], -"sound/sequences/sh/02_menu_title_screen.m64": [8282,{"sh":[7884784]}], -"sound/sequences/sh/03_level_grass.m64": [5129,{"sh":[7893072]}], -"sound/sequences/sh/04_level_inside_castle.m64": [2503,{"sh":[7898208]}], -"sound/sequences/sh/05_level_water.m64": [4788,{"sh":[7900720]}], -"sound/sequences/sh/06_level_hot.m64": [2455,{"sh":[7905520]}], -"sound/sequences/sh/07_level_boss_koopa.m64": [3424,{"sh":[7907984]}], -"sound/sequences/sh/08_level_snow.m64": [8150,{"sh":[7911408]}], -"sound/sequences/sh/09_level_slide.m64": [7443,{"sh":[7919568]}], -"sound/sequences/sh/0A_level_spooky.m64": [5681,{"sh":[7927024]}], -"sound/sequences/sh/0B_event_piranha_plant.m64": [1400,{"sh":[7932720]}], -"sound/sequences/sh/0C_level_underground.m64": [4899,{"sh":[7934128]}], -"sound/sequences/sh/0D_menu_star_select.m64": [136,{"sh":[7939040]}], -"sound/sequences/sh/0E_event_powerup.m64": [3137,{"sh":[7939184]}], -"sound/sequences/sh/0F_event_metal_cap.m64": [2779,{"sh":[7942336]}], -"sound/sequences/sh/10_event_koopa_message.m64": [558,{"sh":[7945120]}], -"sound/sequences/sh/11_level_koopa_road.m64": [4753,{"sh":[7945680]}], -"sound/sequences/sh/12_event_high_score.m64": [275,{"sh":[7950448]}], -"sound/sequences/sh/13_event_merry_go_round.m64": [1660,{"sh":[7950736]}], -"sound/sequences/sh/14_event_race.m64": [200,{"sh":[7952400]}], -"sound/sequences/sh/15_cutscene_star_spawn.m64": [649,{"sh":[7952608]}], -"sound/sequences/sh/16_event_boss.m64": [3444,{"sh":[7953264]}], -"sound/sequences/sh/17_cutscene_collect_key.m64": [677,{"sh":[7956720]}], -"sound/sequences/sh/18_event_endless_stairs.m64": [1783,{"sh":[7957408]}], -"sound/sequences/sh/19_level_boss_koopa_final.m64": [3521,{"sh":[7959200]}], -"sound/sequences/sh/1A_cutscene_credits.m64": [14328,{"sh":[7962736]}], -"sound/sequences/sh/1B_event_solve_puzzle.m64": [219,{"sh":[7977072]}], -"sound/sequences/sh/1C_event_toad_message.m64": [211,{"sh":[7977296]}], -"sound/sequences/sh/1D_event_peach_message.m64": [436,{"sh":[7977520]}], -"sound/sequences/sh/1E_cutscene_intro.m64": [1770,{"sh":[7977968]}], -"sound/sequences/sh/1F_cutscene_victory.m64": [2066,{"sh":[7979744]}], -"sound/sequences/sh/20_cutscene_ending.m64": [1887,{"sh":[7981824]}], -"sound/sequences/sh/21_menu_file_select.m64": [786,{"sh":[7983712]}], -"sound/sequences/sh/22_cutscene_lakitu.m64": [317,{"sh":[7984512]}], +"sound/sequences/sh/01_cutscene_collect_star.m64": [626,{"sh":[7884144],"cn":[7957168]}], +"sound/sequences/sh/02_menu_title_screen.m64": [8282,{"sh":[7884784],"cn":[7957808]}], +"sound/sequences/sh/03_level_grass.m64": [5129,{"sh":[7893072],"cn":[7966096]}], +"sound/sequences/sh/04_level_inside_castle.m64": [2503,{"sh":[7898208],"cn":[7971232]}], +"sound/sequences/sh/05_level_water.m64": [4788,{"sh":[7900720],"cn":[7973744]}], +"sound/sequences/sh/06_level_hot.m64": [2455,{"sh":[7905520],"cn":[7978544]}], +"sound/sequences/sh/07_level_boss_koopa.m64": [3424,{"sh":[7907984],"cn":[7981008]}], +"sound/sequences/sh/08_level_snow.m64": [8150,{"sh":[7911408],"cn":[7984432]}], +"sound/sequences/sh/09_level_slide.m64": [7443,{"sh":[7919568],"cn":[7992592]}], +"sound/sequences/sh/0A_level_spooky.m64": [5681,{"sh":[7927024],"cn":[8000048]}], +"sound/sequences/sh/0B_event_piranha_plant.m64": [1400,{"sh":[7932720],"cn":[8005744]}], +"sound/sequences/sh/0C_level_underground.m64": [4899,{"sh":[7934128],"cn":[8007152]}], +"sound/sequences/sh/0D_menu_star_select.m64": [136,{"sh":[7939040],"cn":[8012064]}], +"sound/sequences/sh/0E_event_powerup.m64": [3137,{"sh":[7939184],"cn":[8012208]}], +"sound/sequences/sh/0F_event_metal_cap.m64": [2779,{"sh":[7942336],"cn":[8015360]}], +"sound/sequences/sh/10_event_koopa_message.m64": [558,{"sh":[7945120],"cn":[8018144]}], +"sound/sequences/sh/11_level_koopa_road.m64": [4753,{"sh":[7945680],"cn":[8018704]}], +"sound/sequences/sh/12_event_high_score.m64": [275,{"sh":[7950448],"cn":[8023472]}], +"sound/sequences/sh/13_event_merry_go_round.m64": [1660,{"sh":[7950736],"cn":[8023760]}], +"sound/sequences/sh/14_event_race.m64": [200,{"sh":[7952400],"cn":[8025424]}], +"sound/sequences/sh/15_cutscene_star_spawn.m64": [649,{"sh":[7952608],"cn":[8025632]}], +"sound/sequences/sh/16_event_boss.m64": [3444,{"sh":[7953264],"cn":[8026288]}], +"sound/sequences/sh/17_cutscene_collect_key.m64": [677,{"sh":[7956720],"cn":[8029744]}], +"sound/sequences/sh/18_event_endless_stairs.m64": [1783,{"sh":[7957408],"cn":[8030432]}], +"sound/sequences/sh/19_level_boss_koopa_final.m64": [3521,{"sh":[7959200],"cn":[8032224]}], +"sound/sequences/sh/1A_cutscene_credits.m64": [14328,{"sh":[7962736],"cn":[8035760]}], +"sound/sequences/sh/1B_event_solve_puzzle.m64": [219,{"sh":[7977072],"cn":[8050096]}], +"sound/sequences/sh/1C_event_toad_message.m64": [211,{"sh":[7977296],"cn":[8050320]}], +"sound/sequences/sh/1D_event_peach_message.m64": [436,{"sh":[7977520],"cn":[8050544]}], +"sound/sequences/sh/1E_cutscene_intro.m64": [1770,{"sh":[7977968],"cn":[8050992]}], +"sound/sequences/sh/1F_cutscene_victory.m64": [2066,{"sh":[7979744],"cn":[8052768]}], +"sound/sequences/sh/20_cutscene_ending.m64": [1887,{"sh":[7981824],"cn":[8054848]}], +"sound/sequences/sh/21_menu_file_select.m64": [786,{"sh":[7983712],"cn":[8056736]}], +"sound/sequences/sh/22_cutscene_lakitu.m64": [317,{"sh":[7984512],"cn":[8057536]}], "sound/sequences/us/01_cutscene_collect_star.m64": [619,{"us":[8076816]}], "sound/sequences/us/02_menu_title_screen.m64": [8254,{"us":[8077440]}], "sound/sequences/us/03_level_grass.m64": [5122,{"us":[8085696]}], @@ -1120,490 +1127,490 @@ "sound/sequences/us/20_cutscene_ending.m64": [1882,{"us":[8174192]}], "sound/sequences/us/21_menu_file_select.m64": [781,{"us":[8176080]}], "sound/sequences/us/22_cutscene_lakitu.m64": [313,{"us":[8176864]}], -"textures/cave/hmc_textures.00000.rgba16.png": [32,64,4096,{"jp":[3432432,0],"us":[3439184,0],"eu":[3312784,0],"sh":[3287152,0]}], -"textures/cave/hmc_textures.01000.rgba16.png": [32,32,2048,{"jp":[3432432,4096],"us":[3439184,4096],"eu":[3312784,4096],"sh":[3287152,4096]}], -"textures/cave/hmc_textures.01800.rgba16.png": [32,64,4096,{"jp":[3432432,6144],"us":[3439184,6144],"eu":[3312784,6144],"sh":[3287152,6144]}], -"textures/cave/hmc_textures.02800.rgba16.png": [32,32,2048,{"jp":[3432432,10240],"us":[3439184,10240],"eu":[3312784,10240],"sh":[3287152,10240]}], -"textures/cave/hmc_textures.03000.rgba16.png": [32,32,2048,{"jp":[3432432,12288],"us":[3439184,12288],"eu":[3312784,12288],"sh":[3287152,12288]}], -"textures/cave/hmc_textures.03800.rgba16.png": [32,64,4096,{"jp":[3432432,14336],"us":[3439184,14336],"eu":[3312784,14336],"sh":[3287152,14336]}], -"textures/cave/hmc_textures.04800.rgba16.png": [64,32,4096,{"jp":[3432432,18432],"us":[3439184,18432],"eu":[3312784,18432],"sh":[3287152,18432]}], -"textures/cave/hmc_textures.05800.rgba16.png": [32,64,4096,{"jp":[3432432,22528],"us":[3439184,22528],"eu":[3312784,22528],"sh":[3287152,22528]}], -"textures/cave/hmc_textures.06800.rgba16.png": [32,32,2048,{"jp":[3432432,26624],"us":[3439184,26624],"eu":[3312784,26624],"sh":[3287152,26624]}], -"textures/cave/hmc_textures.07000.rgba16.png": [32,32,2048,{"jp":[3432432,28672],"us":[3439184,28672],"eu":[3312784,28672],"sh":[3287152,28672]}], -"textures/cave/hmc_textures.07800.rgba16.png": [32,64,4096,{"jp":[3432432,30720],"us":[3439184,30720],"eu":[3312784,30720],"sh":[3287152,30720]}], -"textures/cave/hmc_textures.08800.rgba16.png": [32,64,4096,{"jp":[3432432,34816],"us":[3439184,34816],"eu":[3312784,34816],"sh":[3287152,34816]}], -"textures/cave/hmc_textures.09800.rgba16.png": [32,32,2048,{"jp":[3432432,38912],"us":[3439184,38912],"eu":[3312784,38912],"sh":[3287152,38912]}], -"textures/cave/hmc_textures.0A000.rgba16.png": [32,32,2048,{"jp":[3432432,40960],"us":[3439184,40960],"eu":[3312784,40960],"sh":[3287152,40960]}], -"textures/cave/hmc_textures.0A800.rgba16.png": [32,64,4096,{"jp":[3432432,43008],"us":[3439184,43008],"eu":[3312784,43008],"sh":[3287152,43008]}], -"textures/cave/hmc_textures.0B800.ia16.png": [32,32,2048,{"jp":[3432432,47104],"us":[3439184,47104],"eu":[3312784,47104],"sh":[3287152,47104]}], -"textures/cave/hmc_textures.0C000.ia16.png": [32,32,2048,{"jp":[3298272,43008],"us":[3305024,43008],"eu":[3178624,43008],"sh":[3152992,43008]}], -"textures/skyboxes/bbh.png": [84288,{"jp":[3118928,0],"us":[3125680,0],"eu":[2999280,0],"sh":[2973648,0]}], -"textures/skyboxes/bidw.png": [131392,{"jp":[3146352,0],"us":[3153104,0],"eu":[3026704,0],"sh":[3001072,0]}], -"textures/skyboxes/bitfs.png": [102720,{"jp":[2942432,0],"us":[2949184,0],"eu":[2822784,0],"sh":[2797152,0]}], -"textures/skyboxes/bits.png": [131392,{"jp":[3191904,0],"us":[3198656,0],"eu":[3072256,0],"sh":[3046624,0]}], -"textures/skyboxes/ccm.png": [131392,{"jp":[2847920,0],"us":[2854672,0],"eu":[2728272,0],"sh":[2702640,0]}], -"textures/skyboxes/cloud_floor.png": [131392,{"jp":[3038752,0],"us":[3045504,0],"eu":[2919104,0],"sh":[2893472,0]}], -"textures/skyboxes/clouds.png": [84288,{"jp":[2906480,0],"us":[2913232,0],"eu":[2786832,0],"sh":[2761200,0]}], -"textures/skyboxes/ssl.png": [131392,{"jp":[3078784,0],"us":[3085536,0],"eu":[2959136,0],"sh":[2933504,0]}], -"textures/skyboxes/water.png": [131392,{"jp":[2796624,0],"us":[2803376,0],"eu":[2676976,0],"sh":[2651344,0]}], -"textures/skyboxes/wdw.png": [131392,{"jp":[2968208,0],"us":[2974960,0],"eu":[2848560,0],"sh":[2822928,0]}], -"textures/effect/bubble.06048.rgba16.png": [32,32,2048,{"jp":[3594960,24648],"us":[3601712,24648],"eu":[3475312,24648],"sh":[3449680,24648]}], -"textures/effect/flower.00008.rgba16.png": [32,32,2048,{"jp":[3594960,8],"us":[3601712,8],"eu":[3475312,8],"sh":[3449680,8]}], -"textures/effect/flower.00808.rgba16.png": [32,32,2048,{"jp":[3594960,2056],"us":[3601712,2056],"eu":[3475312,2056],"sh":[3449680,2056]}], -"textures/effect/flower.01008.rgba16.png": [32,32,2048,{"jp":[3594960,4104],"us":[3601712,4104],"eu":[3475312,4104],"sh":[3449680,4104]}], -"textures/effect/flower.01808.rgba16.png": [32,32,2048,{"jp":[3594960,6152],"us":[3601712,6152],"eu":[3475312,6152],"sh":[3449680,6152]}], -"textures/effect/lava_bubble.02020.rgba16.png": [32,32,2048,{"jp":[3594960,8224],"us":[3601712,8224],"eu":[3475312,8224],"sh":[3449680,8224]}], -"textures/effect/lava_bubble.02820.rgba16.png": [32,32,2048,{"jp":[3594960,10272],"us":[3601712,10272],"eu":[3475312,10272],"sh":[3449680,10272]}], -"textures/effect/lava_bubble.03020.rgba16.png": [32,32,2048,{"jp":[3594960,12320],"us":[3601712,12320],"eu":[3475312,12320],"sh":[3449680,12320]}], -"textures/effect/lava_bubble.03820.rgba16.png": [32,32,2048,{"jp":[3594960,14368],"us":[3601712,14368],"eu":[3475312,14368],"sh":[3449680,14368]}], -"textures/effect/lava_bubble.04020.rgba16.png": [32,32,2048,{"jp":[3594960,16416],"us":[3601712,16416],"eu":[3475312,16416],"sh":[3449680,16416]}], -"textures/effect/lava_bubble.04820.rgba16.png": [32,32,2048,{"jp":[3594960,18464],"us":[3601712,18464],"eu":[3475312,18464],"sh":[3449680,18464]}], -"textures/effect/lava_bubble.05020.rgba16.png": [32,32,2048,{"jp":[3594960,20512],"us":[3601712,20512],"eu":[3475312,20512],"sh":[3449680,20512]}], -"textures/effect/lava_bubble.05820.rgba16.png": [32,32,2048,{"jp":[3594960,22560],"us":[3601712,22560],"eu":[3475312,22560],"sh":[3449680,22560]}], -"textures/effect/tiny_bubble.0684C.rgba16.png": [16,16,512,{"jp":[3594960,26700],"us":[3601712,26700],"eu":[3475312,26700],"sh":[3449680,26700]}], -"textures/effect/tiny_bubble.06AD8.rgba16.png": [16,16,512,{"jp":[3594960,27352],"us":[3601712,27352],"eu":[3475312,27352],"sh":[3449680,27352]}], -"textures/fire/lll_textures.00000.rgba16.png": [32,32,2048,{"jp":[3262320,0],"us":[3269072,0],"eu":[3142672,0],"sh":[3117040,0]}], -"textures/fire/lll_textures.00800.rgba16.png": [32,32,2048,{"jp":[3262320,2048],"us":[3269072,2048],"eu":[3142672,2048],"sh":[3117040,2048]}], -"textures/fire/lll_textures.01000.rgba16.png": [32,32,2048,{"jp":[3262320,4096],"us":[3269072,4096],"eu":[3142672,4096],"sh":[3117040,4096]}], -"textures/fire/lll_textures.01800.rgba16.png": [32,32,2048,{"jp":[3262320,6144],"us":[3269072,6144],"eu":[3142672,6144],"sh":[3117040,6144]}], -"textures/fire/lll_textures.02000.rgba16.png": [32,32,2048,{"jp":[3262320,8192],"us":[3269072,8192],"eu":[3142672,8192],"sh":[3117040,8192]}], -"textures/fire/lll_textures.02800.rgba16.png": [32,32,2048,{"jp":[3262320,10240],"us":[3269072,10240],"eu":[3142672,10240],"sh":[3117040,10240]}], -"textures/fire/lll_textures.03000.rgba16.png": [32,32,2048,{"jp":[3262320,12288],"us":[3269072,12288],"eu":[3142672,12288],"sh":[3117040,12288]}], -"textures/fire/lll_textures.03800.rgba16.png": [32,32,2048,{"jp":[3262320,14336],"us":[3269072,14336],"eu":[3142672,14336],"sh":[3117040,14336]}], -"textures/fire/lll_textures.04000.rgba16.png": [32,32,2048,{"jp":[3262320,16384],"us":[3269072,16384],"eu":[3142672,16384],"sh":[3117040,16384]}], -"textures/fire/lll_textures.04800.rgba16.png": [32,32,2048,{"jp":[3262320,18432],"us":[3269072,18432],"eu":[3142672,18432],"sh":[3117040,18432]}], -"textures/fire/lll_textures.05000.rgba16.png": [32,32,2048,{"jp":[3262320,20480],"us":[3269072,20480],"eu":[3142672,20480],"sh":[3117040,20480]}], -"textures/fire/lll_textures.05800.rgba16.png": [32,32,2048,{"jp":[3262320,22528],"us":[3269072,22528],"eu":[3142672,22528],"sh":[3117040,22528]}], -"textures/fire/lll_textures.06000.rgba16.png": [32,32,2048,{"jp":[3262320,24576],"us":[3269072,24576],"eu":[3142672,24576],"sh":[3117040,24576]}], -"textures/fire/lll_textures.06800.rgba16.png": [32,32,2048,{"jp":[3262320,26624],"us":[3269072,26624],"eu":[3142672,26624],"sh":[3117040,26624]}], -"textures/fire/lll_textures.07000.rgba16.png": [32,32,2048,{"jp":[3262320,28672],"us":[3269072,28672],"eu":[3142672,28672],"sh":[3117040,28672]}], -"textures/fire/lll_textures.07800.rgba16.png": [32,32,2048,{"jp":[3262320,30720],"us":[3269072,30720],"eu":[3142672,30720],"sh":[3117040,30720]}], -"textures/fire/lll_textures.08000.rgba16.png": [32,32,2048,{"jp":[3262320,32768],"us":[3269072,32768],"eu":[3142672,32768],"sh":[3117040,32768]}], -"textures/fire/lll_textures.08800.rgba16.png": [32,32,2048,{"jp":[3262320,34816],"us":[3269072,34816],"eu":[3142672,34816],"sh":[3117040,34816]}], -"textures/fire/lll_textures.09000.rgba16.png": [32,32,2048,{"jp":[1078992,80984],"us":[1083968,92856],"eu":[909712,49528],"sh":[934640,80984]}], -"textures/fire/lll_textures.09800.rgba16.png": [32,32,2048,{"jp":[3262320,38912],"us":[3269072,38912],"eu":[3142672,38912],"sh":[3117040,38912]}], -"textures/fire/lll_textures.0A000.rgba16.png": [32,32,2048,{"jp":[3262320,40960],"us":[3269072,40960],"eu":[3142672,40960],"sh":[3117040,40960]}], -"textures/fire/lll_textures.0A800.rgba16.png": [32,32,2048,{"jp":[3262320,43008],"us":[3269072,43008],"eu":[3142672,43008],"sh":[3117040,43008]}], -"textures/fire/lll_textures.0B000.rgba16.png": [32,32,2048,{"jp":[3262320,45056],"us":[3269072,45056],"eu":[3142672,45056],"sh":[3117040,45056]}], -"textures/fire/lll_textures.0B800.rgba16.png": [32,32,2048,{"jp":[3262320,47104],"us":[3269072,47104],"eu":[3142672,47104],"sh":[3117040,47104]}], -"textures/generic/bob_textures.00000.rgba16.png": [32,32,2048,{"jp":[3323408,0],"us":[3330160,0],"eu":[3203760,0],"sh":[3178128,0]}], -"textures/generic/bob_textures.00800.rgba16.png": [32,32,2048,{"jp":[1327760,36160],"us":[1334928,36160],"eu":[1206896,36160],"sh":[1183408,36160]}], -"textures/generic/bob_textures.01000.rgba16.png": [32,32,2048,{"jp":[3323408,4096],"us":[3330160,4096],"eu":[3203760,4096],"sh":[3178128,4096]}], -"textures/generic/bob_textures.01800.rgba16.png": [32,32,2048,{"jp":[3323408,6144],"us":[3330160,6144],"eu":[3203760,6144],"sh":[3178128,6144]}], -"textures/generic/bob_textures.02000.rgba16.png": [32,32,2048,{"jp":[3323408,8192],"us":[3330160,8192],"eu":[3203760,8192],"sh":[3178128,8192]}], -"textures/generic/bob_textures.02800.rgba16.png": [32,32,2048,{"jp":[3323408,10240],"us":[3330160,10240],"eu":[3203760,10240],"sh":[3178128,10240]}], -"textures/generic/bob_textures.03000.rgba16.png": [32,32,2048,{"jp":[3323408,12288],"us":[3330160,12288],"eu":[3203760,12288],"sh":[3178128,12288]}], -"textures/generic/bob_textures.03800.rgba16.png": [32,32,2048,{"jp":[3323408,14336],"us":[3330160,14336],"eu":[3203760,14336],"sh":[3178128,14336]}], -"textures/generic/bob_textures.04000.rgba16.png": [32,32,2048,{"jp":[3323408,16384],"us":[3330160,16384],"eu":[3203760,16384],"sh":[3178128,16384]}], -"textures/generic/bob_textures.04800.rgba16.png": [32,32,2048,{"jp":[3323408,18432],"us":[3330160,18432],"eu":[3203760,18432],"sh":[3178128,18432]}], -"textures/generic/bob_textures.05000.rgba16.png": [32,32,2048,{"jp":[3323408,20480],"us":[3330160,20480],"eu":[3203760,20480],"sh":[3178128,20480]}], -"textures/generic/bob_textures.05800.rgba16.png": [32,32,2048,{"jp":[3323408,22528],"us":[3330160,22528],"eu":[3203760,22528],"sh":[3178128,22528]}], -"textures/generic/bob_textures.06000.rgba16.png": [32,64,4096,{"jp":[3323408,24576],"us":[3330160,24576],"eu":[3203760,24576],"sh":[3178128,24576]}], -"textures/generic/bob_textures.07000.rgba16.png": [32,32,2048,{"jp":[3323408,28672],"us":[3330160,28672],"eu":[3203760,28672],"sh":[3178128,28672]}], -"textures/generic/bob_textures.07800.rgba16.png": [32,32,2048,{"jp":[3323408,30720],"us":[3330160,30720],"eu":[3203760,30720],"sh":[3178128,30720]}], -"textures/generic/bob_textures.08000.rgba16.png": [32,32,2048,{"jp":[3323408,32768],"us":[3330160,32768],"eu":[3203760,32768],"sh":[3178128,32768]}], -"textures/generic/bob_textures.08800.rgba16.png": [32,32,2048,{"jp":[3323408,34816],"us":[3330160,34816],"eu":[3203760,34816],"sh":[3178128,34816]}], -"textures/generic/bob_textures.09000.rgba16.png": [32,32,2048,{"jp":[3323408,36864],"us":[3330160,36864],"eu":[3203760,36864],"sh":[3178128,36864]}], -"textures/generic/bob_textures.09800.rgba16.png": [32,32,2048,{"jp":[3323408,38912],"us":[3330160,38912],"eu":[3203760,38912],"sh":[3178128,38912]}], -"textures/generic/bob_textures.0A000.rgba16.png": [32,32,2048,{"jp":[3323408,40960],"us":[3330160,40960],"eu":[3203760,40960],"sh":[3178128,40960]}], -"textures/generic/bob_textures.0A800.rgba16.png": [32,32,2048,{"jp":[3323408,43008],"us":[3330160,43008],"eu":[3203760,43008],"sh":[3178128,43008]}], -"textures/generic/bob_textures.0B000.ia16.png": [32,32,2048,{"jp":[3323408,45056],"us":[3330160,45056],"eu":[3203760,45056],"sh":[3178128,45056]}], -"textures/grass/wf_textures.00000.rgba16.png": [32,32,2048,{"jp":[3496176,0],"us":[3502928,0],"eu":[3376528,0],"sh":[3350896,0]}], -"textures/grass/wf_textures.00800.rgba16.png": [32,32,2048,{"jp":[3496176,2048],"us":[3502928,2048],"eu":[3376528,2048],"sh":[3350896,2048]}], -"textures/grass/wf_textures.01000.rgba16.png": [32,32,2048,{"jp":[3496176,4096],"us":[3502928,4096],"eu":[3376528,4096],"sh":[3350896,4096]}], -"textures/grass/wf_textures.01800.rgba16.png": [32,32,2048,{"jp":[3496176,6144],"us":[3502928,6144],"eu":[3376528,6144],"sh":[3350896,6144]}], -"textures/grass/wf_textures.02000.rgba16.png": [32,32,2048,{"jp":[3496176,8192],"us":[3502928,8192],"eu":[3376528,8192],"sh":[3350896,8192]}], -"textures/grass/wf_textures.02800.rgba16.png": [32,32,2048,{"jp":[3496176,10240],"us":[3502928,10240],"eu":[3376528,10240],"sh":[3350896,10240]}], -"textures/grass/wf_textures.03000.rgba16.png": [32,32,2048,{"jp":[3496176,12288],"us":[3502928,12288],"eu":[3376528,12288],"sh":[3350896,12288]}], -"textures/grass/wf_textures.03800.rgba16.png": [32,32,2048,{"jp":[3496176,14336],"us":[3502928,14336],"eu":[3376528,14336],"sh":[3350896,14336]}], -"textures/grass/wf_textures.04000.rgba16.png": [32,32,2048,{"jp":[3496176,16384],"us":[3502928,16384],"eu":[3376528,16384],"sh":[3350896,16384]}], -"textures/grass/wf_textures.04800.rgba16.png": [32,32,2048,{"jp":[3496176,18432],"us":[3502928,18432],"eu":[3376528,18432],"sh":[3350896,18432]}], -"textures/grass/wf_textures.05000.rgba16.png": [32,32,2048,{"jp":[3496176,20480],"us":[3502928,20480],"eu":[3376528,20480],"sh":[3350896,20480]}], -"textures/grass/wf_textures.05800.rgba16.png": [32,32,2048,{"jp":[3496176,22528],"us":[3502928,22528],"eu":[3376528,22528],"sh":[3350896,22528]}], -"textures/grass/wf_textures.06000.rgba16.png": [32,32,2048,{"jp":[3390640,20480],"us":[3397392,20480],"eu":[3270992,20480],"sh":[3245360,20480]}], -"textures/grass/wf_textures.06800.rgba16.png": [32,32,2048,{"jp":[3496176,26624],"us":[3502928,26624],"eu":[3376528,26624],"sh":[3350896,26624]}], -"textures/grass/wf_textures.07000.rgba16.png": [32,32,2048,{"jp":[3496176,28672],"us":[3502928,28672],"eu":[3376528,28672],"sh":[3350896,28672]}], -"textures/grass/wf_textures.07800.rgba16.png": [32,32,2048,{"jp":[3496176,30720],"us":[3502928,30720],"eu":[3376528,30720],"sh":[3350896,30720]}], -"textures/grass/wf_textures.08000.rgba16.png": [32,32,2048,{"jp":[3496176,32768],"us":[3502928,32768],"eu":[3376528,32768],"sh":[3350896,32768]}], -"textures/grass/wf_textures.08800.rgba16.png": [32,32,2048,{"jp":[3496176,34816],"us":[3502928,34816],"eu":[3376528,34816],"sh":[3350896,34816]}], -"textures/grass/wf_textures.09000.rgba16.png": [32,32,2048,{"jp":[3496176,36864],"us":[3502928,36864],"eu":[3376528,36864],"sh":[3350896,36864]}], -"textures/grass/wf_textures.09800.rgba16.png": [32,32,2048,{"jp":[3496176,38912],"us":[3502928,38912],"eu":[3376528,38912],"sh":[3350896,38912]}], -"textures/grass/wf_textures.0A000.rgba16.png": [32,32,2048,{"jp":[3496176,40960],"us":[3502928,40960],"eu":[3376528,40960],"sh":[3350896,40960]}], -"textures/grass/wf_textures.0A800.rgba16.png": [32,32,2048,{"jp":[3496176,43008],"us":[3502928,43008],"eu":[3376528,43008],"sh":[3350896,43008]}], -"textures/grass/wf_textures.0B000.ia16.png": [32,32,2048,{"jp":[3323408,45056],"us":[3330160,45056],"eu":[3203760,45056],"sh":[3178128,45056]}], -"textures/grass/wf_textures.0B800.ia16.png": [32,32,2048,{"jp":[3496176,47104],"us":[3502928,47104],"eu":[3376528,47104],"sh":[3350896,47104]}], -"textures/inside/inside_castle_textures.00000.rgba16.png": [64,32,4096,{"jp":[3555104,0],"us":[3561856,0],"eu":[3435456,0],"sh":[3409824,0]}], -"textures/inside/inside_castle_textures.01000.rgba16.png": [64,32,4096,{"jp":[3555104,4096],"us":[3561856,4096],"eu":[3435456,4096],"sh":[3409824,4096]}], -"textures/inside/inside_castle_textures.02000.rgba16.png": [32,64,4096,{"jp":[3555104,8192],"us":[3561856,8192],"eu":[3435456,8192],"sh":[3409824,8192]}], -"textures/inside/inside_castle_textures.03000.rgba16.png": [32,32,2048,{"jp":[3555104,12288],"us":[3561856,12288],"eu":[3435456,12288],"sh":[3409824,12288]}], -"textures/inside/inside_castle_textures.03800.rgba16.png": [32,32,2048,{"jp":[3555104,14336],"us":[3561856,14336],"eu":[3435456,14336],"sh":[3409824,14336]}], -"textures/inside/inside_castle_textures.04000.rgba16.png": [32,32,2048,{"jp":[3555104,16384],"us":[3561856,16384],"eu":[3435456,16384],"sh":[3409824,16384]}], -"textures/inside/inside_castle_textures.04800.rgba16.png": [32,32,2048,{"jp":[3460352,2048],"us":[3467104,2048],"eu":[3340704,2048],"sh":[3315072,2048]}], -"textures/inside/inside_castle_textures.05000.rgba16.png": [32,32,2048,{"jp":[3555104,20480],"us":[3561856,20480],"eu":[3435456,20480],"sh":[3409824,20480]}], -"textures/inside/inside_castle_textures.05800.rgba16.png": [32,32,2048,{"jp":[3555104,22528],"us":[3561856,22528],"eu":[3435456,22528],"sh":[3409824,22528]}], -"textures/inside/inside_castle_textures.06000.rgba16.png": [32,64,4096,{"jp":[3555104,24576],"us":[3561856,24576],"eu":[3435456,24576],"sh":[3409824,24576]}], -"textures/inside/inside_castle_textures.07000.rgba16.png": [32,64,4096,{"jp":[3555104,28672],"us":[3561856,28672],"eu":[3435456,28672],"sh":[3409824,28672]}], -"textures/inside/inside_castle_textures.08000.rgba16.png": [32,32,2048,{"jp":[3555104,32768],"us":[3561856,32768],"eu":[3435456,32768],"sh":[3409824,32768]}], -"textures/inside/inside_castle_textures.08800.rgba16.png": [32,32,2048,{"jp":[3555104,34816],"us":[3561856,34816],"eu":[3435456,34816],"sh":[3409824,34816]}], -"textures/inside/inside_castle_textures.09000.rgba16.png": [32,64,4096,{"jp":[3555104,36864],"us":[3561856,36864],"eu":[3435456,36864],"sh":[3409824,36864]}], -"textures/inside/inside_castle_textures.0A000.rgba16.png": [32,64,4096,{"jp":[3555104,40960],"us":[3561856,40960],"eu":[3435456,40960],"sh":[3409824,40960]}], -"textures/inside/inside_castle_textures.0B000.rgba16.png": [32,32,2048,{"jp":[3555104,45056],"us":[3561856,45056],"eu":[3435456,45056],"sh":[3409824,45056]}], -"textures/inside/inside_castle_textures.0B800.rgba16.png": [64,32,4096,{"jp":[3555104,47104],"us":[3561856,47104],"eu":[3435456,47104],"sh":[3409824,47104]}], -"textures/intro_raw/hand_closed.rgba16.png": [32,32,2048,{"jp":[2455304],"us":[2463112],"eu":[2331912],"sh":[2308680]}], -"textures/intro_raw/hand_open.rgba16.png": [32,32,2048,{"jp":[2453248],"us":[2461056],"eu":[2329856],"sh":[2306624]}], -"textures/intro_raw/mario_face_shine.ia8.png": [32,32,1024,{"jp":[2503888],"us":[2511696],"eu":[2380496],"sh":[2357264]}], -"textures/intro_raw/red_star_0.rgba16.png": [32,32,2048,{"jp":[2457352],"us":[2465160],"eu":[2333960],"sh":[2310728]}], -"textures/intro_raw/red_star_1.rgba16.png": [32,32,2048,{"jp":[2459400],"us":[2467208],"eu":[2336008],"sh":[2312776]}], -"textures/intro_raw/red_star_2.rgba16.png": [32,32,2048,{"jp":[2461448],"us":[2469256],"eu":[2338056],"sh":[2314824]}], -"textures/intro_raw/red_star_3.rgba16.png": [32,32,2048,{"jp":[2463496],"us":[2471304],"eu":[2340104],"sh":[2316872]}], -"textures/intro_raw/red_star_4.rgba16.png": [32,32,2048,{"jp":[2465544],"us":[2473352],"eu":[2342152],"sh":[2318920]}], -"textures/intro_raw/red_star_5.rgba16.png": [32,32,2048,{"jp":[2467592],"us":[2475400],"eu":[2344200],"sh":[2320968]}], -"textures/intro_raw/red_star_6.rgba16.png": [32,32,2048,{"jp":[2469640],"us":[2477448],"eu":[2346248],"sh":[2323016]}], -"textures/intro_raw/red_star_7.rgba16.png": [32,32,2048,{"jp":[2471688],"us":[2479496],"eu":[2348296],"sh":[2325064]}], -"textures/intro_raw/sparkle_0.rgba16.png": [32,32,2048,{"jp":[2490888],"us":[2498696],"eu":[2367496],"sh":[2344264]}], -"textures/intro_raw/sparkle_1.rgba16.png": [32,32,2048,{"jp":[2492936],"us":[2500744],"eu":[2369544],"sh":[2346312]}], -"textures/intro_raw/sparkle_2.rgba16.png": [32,32,2048,{"jp":[2494984],"us":[2502792],"eu":[2371592],"sh":[2348360]}], -"textures/intro_raw/sparkle_3.rgba16.png": [32,32,2048,{"jp":[2497032],"us":[2504840],"eu":[2373640],"sh":[2350408]}], -"textures/intro_raw/sparkle_4.rgba16.png": [32,32,2048,{"jp":[2499080],"us":[2506888],"eu":[2375688],"sh":[2352456]}], -"textures/intro_raw/sparkle_5.rgba16.png": [32,32,2048,{"jp":[2501128],"us":[2508936],"eu":[2377736],"sh":[2354504]}], -"textures/intro_raw/white_star_0.rgba16.png": [32,32,2048,{"jp":[2473736],"us":[2481544],"eu":[2350344],"sh":[2327112]}], -"textures/intro_raw/white_star_1.rgba16.png": [32,32,2048,{"jp":[2475784],"us":[2483592],"eu":[2352392],"sh":[2329160]}], -"textures/intro_raw/white_star_2.rgba16.png": [32,32,2048,{"jp":[2477832],"us":[2485640],"eu":[2354440],"sh":[2331208]}], -"textures/intro_raw/white_star_3.rgba16.png": [32,32,2048,{"jp":[2479880],"us":[2487688],"eu":[2356488],"sh":[2333256]}], -"textures/intro_raw/white_star_4.rgba16.png": [32,32,2048,{"jp":[2481928],"us":[2489736],"eu":[2358536],"sh":[2335304]}], -"textures/intro_raw/white_star_5.rgba16.png": [32,32,2048,{"jp":[2483976],"us":[2491784],"eu":[2360584],"sh":[2337352]}], -"textures/intro_raw/white_star_6.rgba16.png": [32,32,2048,{"jp":[2486024],"us":[2493832],"eu":[2362632],"sh":[2339400]}], -"textures/intro_raw/white_star_7.rgba16.png": [32,32,2048,{"jp":[2488072],"us":[2495880],"eu":[2364680],"sh":[2341448]}], -"textures/machine/ttc_textures.00000.rgba16.png": [32,32,2048,{"jp":[3460352,0],"us":[3467104,0],"eu":[3340704,0],"sh":[3315072,0]}], -"textures/machine/ttc_textures.00800.rgba16.png": [32,32,2048,{"jp":[3460352,2048],"us":[3467104,2048],"eu":[3340704,2048],"sh":[3315072,2048]}], -"textures/machine/ttc_textures.01000.rgba16.png": [32,32,2048,{"jp":[3460352,4096],"us":[3467104,4096],"eu":[3340704,4096],"sh":[3315072,4096]}], -"textures/machine/ttc_textures.01800.rgba16.png": [32,32,2048,{"jp":[3460352,6144],"us":[3467104,6144],"eu":[3340704,6144],"sh":[3315072,6144]}], -"textures/machine/ttc_textures.02000.rgba16.png": [32,32,2048,{"jp":[3460352,8192],"us":[3467104,8192],"eu":[3340704,8192],"sh":[3315072,8192]}], -"textures/machine/ttc_textures.02800.rgba16.png": [32,32,2048,{"jp":[3460352,10240],"us":[3467104,10240],"eu":[3340704,10240],"sh":[3315072,10240]}], -"textures/machine/ttc_textures.03000.rgba16.png": [32,32,2048,{"jp":[3460352,12288],"us":[3467104,12288],"eu":[3340704,12288],"sh":[3315072,12288]}], -"textures/machine/ttc_textures.03800.rgba16.png": [32,32,2048,{"jp":[3460352,14336],"us":[3467104,14336],"eu":[3340704,14336],"sh":[3315072,14336]}], -"textures/machine/ttc_textures.04000.rgba16.png": [32,64,4096,{"jp":[3460352,16384],"us":[3467104,16384],"eu":[3340704,16384],"sh":[3315072,16384]}], -"textures/machine/ttc_textures.05000.rgba16.png": [32,32,2048,{"jp":[3460352,20480],"us":[3467104,20480],"eu":[3340704,20480],"sh":[3315072,20480]}], -"textures/machine/ttc_textures.05800.rgba16.png": [32,32,2048,{"jp":[3460352,22528],"us":[3467104,22528],"eu":[3340704,22528],"sh":[3315072,22528]}], -"textures/machine/ttc_textures.06000.rgba16.png": [32,32,2048,{"jp":[3460352,24576],"us":[3467104,24576],"eu":[3340704,24576],"sh":[3315072,24576]}], -"textures/machine/ttc_textures.06800.rgba16.png": [32,32,2048,{"jp":[3460352,26624],"us":[3467104,26624],"eu":[3340704,26624],"sh":[3315072,26624]}], -"textures/machine/ttc_textures.07000.rgba16.png": [32,32,2048,{"jp":[3460352,28672],"us":[3467104,28672],"eu":[3340704,28672],"sh":[3315072,28672]}], -"textures/machine/ttc_textures.07800.rgba16.png": [16,64,2048,{"jp":[3460352,30720],"us":[3467104,30720],"eu":[3340704,30720],"sh":[3315072,30720]}], -"textures/machine/ttc_textures.08000.rgba16.png": [64,8,1024,{"jp":[3460352,32768],"us":[3467104,32768],"eu":[3340704,32768],"sh":[3315072,32768]}], -"textures/machine/ttc_textures.08400.rgba16.png": [32,32,2048,{"jp":[3460352,33792],"us":[3467104,33792],"eu":[3340704,33792],"sh":[3315072,33792]}], -"textures/mountain/ttm_textures.00000.rgba16.png": [32,32,2048,{"jp":[3473152,0],"us":[3479904,0],"eu":[3353504,0],"sh":[3327872,0]}], -"textures/mountain/ttm_textures.00800.rgba16.png": [64,32,4096,{"jp":[3473152,2048],"us":[3479904,2048],"eu":[3353504,2048],"sh":[3327872,2048]}], -"textures/mountain/ttm_textures.01800.rgba16.png": [32,64,4096,{"jp":[3473152,6144],"us":[3479904,6144],"eu":[3353504,6144],"sh":[3327872,6144]}], -"textures/mountain/ttm_textures.02800.rgba16.png": [32,32,2048,{"jp":[3473152,10240],"us":[3479904,10240],"eu":[3353504,10240],"sh":[3327872,10240]}], -"textures/mountain/ttm_textures.03000.rgba16.png": [32,32,2048,{"jp":[3473152,12288],"us":[3479904,12288],"eu":[3353504,12288],"sh":[3327872,12288]}], -"textures/mountain/ttm_textures.03800.rgba16.png": [32,32,2048,{"jp":[3473152,14336],"us":[3479904,14336],"eu":[3353504,14336],"sh":[3327872,14336]}], -"textures/mountain/ttm_textures.04000.rgba16.png": [32,32,2048,{"jp":[3473152,16384],"us":[3479904,16384],"eu":[3353504,16384],"sh":[3327872,16384]}], -"textures/mountain/ttm_textures.04800.rgba16.png": [32,32,2048,{"jp":[3473152,18432],"us":[3479904,18432],"eu":[3353504,18432],"sh":[3327872,18432]}], -"textures/mountain/ttm_textures.05000.rgba16.png": [32,32,2048,{"jp":[3473152,20480],"us":[3479904,20480],"eu":[3353504,20480],"sh":[3327872,20480]}], -"textures/mountain/ttm_textures.05800.rgba16.png": [32,64,4096,{"jp":[3473152,22528],"us":[3479904,22528],"eu":[3353504,22528],"sh":[3327872,22528]}], -"textures/mountain/ttm_textures.06800.rgba16.png": [32,32,2048,{"jp":[3473152,26624],"us":[3479904,26624],"eu":[3353504,26624],"sh":[3327872,26624]}], -"textures/mountain/ttm_textures.07000.rgba16.png": [32,32,2048,{"jp":[3473152,28672],"us":[3479904,28672],"eu":[3353504,28672],"sh":[3327872,28672]}], -"textures/mountain/ttm_textures.07800.rgba16.png": [32,32,2048,{"jp":[3473152,30720],"us":[3479904,30720],"eu":[3353504,30720],"sh":[3327872,30720]}], -"textures/mountain/ttm_textures.08000.rgba16.png": [32,32,2048,{"jp":[3473152,32768],"us":[3479904,32768],"eu":[3353504,32768],"sh":[3327872,32768]}], -"textures/mountain/ttm_textures.08800.rgba16.png": [64,32,4096,{"jp":[3473152,34816],"us":[3479904,34816],"eu":[3353504,34816],"sh":[3327872,34816]}], -"textures/mountain/ttm_textures.09800.rgba16.png": [32,32,2048,{"jp":[3473152,38912],"us":[3479904,38912],"eu":[3353504,38912],"sh":[3327872,38912]}], -"textures/mountain/ttm_textures.0A000.rgba16.png": [32,32,2048,{"jp":[3390640,24576],"us":[3397392,24576],"eu":[3270992,24576],"sh":[3245360,24576]}], -"textures/mountain/ttm_textures.0A800.rgba16.png": [32,32,2048,{"jp":[3473152,43008],"us":[3479904,43008],"eu":[3353504,43008],"sh":[3327872,43008]}], -"textures/mountain/ttm_textures.0B000.rgba16.png": [32,32,2048,{"jp":[3473152,45056],"us":[3479904,45056],"eu":[3353504,45056],"sh":[3327872,45056]}], -"textures/mountain/ttm_textures.0B800.rgba16.png": [32,32,2048,{"jp":[3473152,47104],"us":[3479904,47104],"eu":[3353504,47104],"sh":[3327872,47104]}], -"textures/mountain/ttm_textures.0C000.rgba16.png": [32,32,2048,{"jp":[3473152,49152],"us":[3479904,49152],"eu":[3353504,49152],"sh":[3327872,49152]}], -"textures/outside/castle_grounds_textures.00000.rgba16.png": [32,32,2048,{"jp":[3527344,0],"us":[3534096,0],"eu":[3407696,0],"sh":[3382064,0]}], -"textures/outside/castle_grounds_textures.00800.rgba16.png": [32,32,2048,{"jp":[3527344,2048],"us":[3534096,2048],"eu":[3407696,2048],"sh":[3382064,2048]}], -"textures/outside/castle_grounds_textures.01000.rgba16.png": [64,32,4096,{"jp":[3527344,4096],"us":[3534096,4096],"eu":[3407696,4096],"sh":[3382064,4096]}], -"textures/outside/castle_grounds_textures.02000.rgba16.png": [32,64,4096,{"jp":[3527344,8192],"us":[3534096,8192],"eu":[3407696,8192],"sh":[3382064,8192]}], -"textures/outside/castle_grounds_textures.03000.rgba16.png": [32,32,2048,{"jp":[3527344,12288],"us":[3534096,12288],"eu":[3407696,12288],"sh":[3382064,12288]}], -"textures/outside/castle_grounds_textures.03800.rgba16.png": [32,32,2048,{"jp":[3527344,14336],"us":[3534096,14336],"eu":[3407696,14336],"sh":[3382064,14336]}], -"textures/outside/castle_grounds_textures.04000.rgba16.png": [32,32,2048,{"jp":[3527344,16384],"us":[3534096,16384],"eu":[3407696,16384],"sh":[3382064,16384]}], -"textures/outside/castle_grounds_textures.04800.rgba16.png": [32,64,4096,{"jp":[3527344,18432],"us":[3534096,18432],"eu":[3407696,18432],"sh":[3382064,18432]}], -"textures/outside/castle_grounds_textures.05800.rgba16.png": [32,32,2048,{"jp":[3527344,22528],"us":[3534096,22528],"eu":[3407696,22528],"sh":[3382064,22528]}], -"textures/outside/castle_grounds_textures.06000.rgba16.png": [32,32,2048,{"jp":[3527344,24576],"us":[3534096,24576],"eu":[3407696,24576],"sh":[3382064,24576]}], -"textures/outside/castle_grounds_textures.06800.rgba16.png": [64,32,4096,{"jp":[3527344,26624],"us":[3534096,26624],"eu":[3407696,26624],"sh":[3382064,26624]}], -"textures/outside/castle_grounds_textures.07800.rgba16.png": [32,32,2048,{"jp":[3527344,30720],"us":[3534096,30720],"eu":[3407696,30720],"sh":[3382064,30720]}], -"textures/outside/castle_grounds_textures.08000.rgba16.png": [32,32,2048,{"jp":[3527344,32768],"us":[3534096,32768],"eu":[3407696,32768],"sh":[3382064,32768]}], -"textures/outside/castle_grounds_textures.08800.rgba16.png": [32,32,2048,{"jp":[3527344,34816],"us":[3534096,34816],"eu":[3407696,34816],"sh":[3382064,34816]}], -"textures/outside/castle_grounds_textures.09000.rgba16.png": [32,32,2048,{"jp":[3527344,36864],"us":[3534096,36864],"eu":[3407696,36864],"sh":[3382064,36864]}], -"textures/outside/castle_grounds_textures.09800.rgba16.png": [32,32,2048,{"jp":[3527344,38912],"us":[3534096,38912],"eu":[3407696,38912],"sh":[3382064,38912]}], -"textures/outside/castle_grounds_textures.0A000.rgba16.png": [32,32,2048,{"jp":[3527344,40960],"us":[3534096,40960],"eu":[3407696,40960],"sh":[3382064,40960]}], -"textures/outside/castle_grounds_textures.0A800.rgba16.png": [32,32,2048,{"jp":[3527344,43008],"us":[3534096,43008],"eu":[3407696,43008],"sh":[3382064,43008]}], -"textures/outside/castle_grounds_textures.0B000.rgba16.png": [16,32,1024,{"jp":[3527344,45056],"us":[3534096,45056],"eu":[3407696,45056],"sh":[3382064,45056]}], -"textures/outside/castle_grounds_textures.0B400.rgba16.png": [32,32,2048,{"jp":[3527344,46080],"us":[3534096,46080],"eu":[3407696,46080],"sh":[3382064,46080]}], -"textures/outside/castle_grounds_textures.0BC00.ia16.png": [32,32,2048,{"jp":[3323408,45056],"us":[3330160,45056],"eu":[3203760,45056],"sh":[3178128,45056]}], -"textures/segment2/font_graphics.05900.ia4.png": [16,8,64,{"us":[1083968,22784]}], -"textures/segment2/font_graphics.05940.ia4.png": [16,8,64,{"us":[1083968,22848]}], -"textures/segment2/font_graphics.05980.ia4.png": [16,8,64,{"us":[1083968,22912]}], -"textures/segment2/font_graphics.059C0.ia4.png": [16,8,64,{"us":[1083968,22976]}], -"textures/segment2/font_graphics.05A00.ia4.png": [16,8,64,{"us":[1083968,23040]}], -"textures/segment2/font_graphics.05A40.ia4.png": [16,8,64,{"us":[1083968,23104]}], -"textures/segment2/font_graphics.05A80.ia4.png": [16,8,64,{"us":[1083968,23168]}], -"textures/segment2/font_graphics.05AC0.ia4.png": [16,8,64,{"us":[1083968,23232]}], -"textures/segment2/font_graphics.05B00.ia4.png": [16,8,64,{"us":[1083968,23296]}], -"textures/segment2/font_graphics.05B40.ia4.png": [16,8,64,{"us":[1083968,23360]}], -"textures/segment2/font_graphics.05B80.ia4.png": [16,8,64,{"us":[1083968,23424]}], -"textures/segment2/font_graphics.05BC0.ia4.png": [16,8,64,{"us":[1083968,23488]}], -"textures/segment2/font_graphics.05C00.ia4.png": [16,8,64,{"us":[1083968,23552]}], -"textures/segment2/font_graphics.05C40.ia4.png": [16,8,64,{"us":[1083968,23616]}], -"textures/segment2/font_graphics.05C80.ia4.png": [16,8,64,{"us":[1083968,23680]}], -"textures/segment2/font_graphics.05CC0.ia4.png": [16,8,64,{"us":[1083968,23744]}], -"textures/segment2/font_graphics.05D00.ia4.png": [16,8,64,{"us":[1083968,23808]}], -"textures/segment2/font_graphics.05D40.ia4.png": [16,8,64,{"us":[1083968,23872]}], -"textures/segment2/font_graphics.05D80.ia4.png": [16,8,64,{"us":[1083968,23936]}], -"textures/segment2/font_graphics.05DC0.ia4.png": [16,8,64,{"us":[1083968,24000]}], -"textures/segment2/font_graphics.05E00.ia4.png": [16,8,64,{"us":[1083968,24064]}], -"textures/segment2/font_graphics.05E40.ia4.png": [16,8,64,{"us":[1083968,24128]}], -"textures/segment2/font_graphics.05E80.ia4.png": [16,8,64,{"us":[1083968,24192]}], -"textures/segment2/font_graphics.05EC0.ia4.png": [16,8,64,{"us":[1083968,24256]}], +"textures/cave/hmc_textures.00000.rgba16.png": [32,64,4096,{"jp":[3432432,0],"us":[3439184,0],"eu":[3312784,0],"sh":[3287152,0],"cn":[3360912,0]}], +"textures/cave/hmc_textures.01000.rgba16.png": [32,32,2048,{"jp":[3432432,4096],"us":[3439184,4096],"eu":[3312784,4096],"sh":[3287152,4096],"cn":[3360912,4096]}], +"textures/cave/hmc_textures.01800.rgba16.png": [32,64,4096,{"jp":[3432432,6144],"us":[3439184,6144],"eu":[3312784,6144],"sh":[3287152,6144],"cn":[3360912,6144]}], +"textures/cave/hmc_textures.02800.rgba16.png": [32,32,2048,{"jp":[3432432,10240],"us":[3439184,10240],"eu":[3312784,10240],"sh":[3287152,10240],"cn":[3360912,10240]}], +"textures/cave/hmc_textures.03000.rgba16.png": [32,32,2048,{"jp":[3432432,12288],"us":[3439184,12288],"eu":[3312784,12288],"sh":[3287152,12288],"cn":[3360912,12288]}], +"textures/cave/hmc_textures.03800.rgba16.png": [32,64,4096,{"jp":[3432432,14336],"us":[3439184,14336],"eu":[3312784,14336],"sh":[3287152,14336],"cn":[3360912,14336]}], +"textures/cave/hmc_textures.04800.rgba16.png": [64,32,4096,{"jp":[3432432,18432],"us":[3439184,18432],"eu":[3312784,18432],"sh":[3287152,18432],"cn":[3360912,18432]}], +"textures/cave/hmc_textures.05800.rgba16.png": [32,64,4096,{"jp":[3432432,22528],"us":[3439184,22528],"eu":[3312784,22528],"sh":[3287152,22528],"cn":[3360912,22528]}], +"textures/cave/hmc_textures.06800.rgba16.png": [32,32,2048,{"jp":[3432432,26624],"us":[3439184,26624],"eu":[3312784,26624],"sh":[3287152,26624],"cn":[3360912,26624]}], +"textures/cave/hmc_textures.07000.rgba16.png": [32,32,2048,{"jp":[3432432,28672],"us":[3439184,28672],"eu":[3312784,28672],"sh":[3287152,28672],"cn":[3360912,28672]}], +"textures/cave/hmc_textures.07800.rgba16.png": [32,64,4096,{"jp":[3432432,30720],"us":[3439184,30720],"eu":[3312784,30720],"sh":[3287152,30720],"cn":[3360912,30720]}], +"textures/cave/hmc_textures.08800.rgba16.png": [32,64,4096,{"jp":[3432432,34816],"us":[3439184,34816],"eu":[3312784,34816],"sh":[3287152,34816],"cn":[3360912,34816]}], +"textures/cave/hmc_textures.09800.rgba16.png": [32,32,2048,{"jp":[3432432,38912],"us":[3439184,38912],"eu":[3312784,38912],"sh":[3287152,38912],"cn":[3360912,38912]}], +"textures/cave/hmc_textures.0A000.rgba16.png": [32,32,2048,{"jp":[3432432,40960],"us":[3439184,40960],"eu":[3312784,40960],"sh":[3287152,40960],"cn":[3360912,40960]}], +"textures/cave/hmc_textures.0A800.rgba16.png": [32,64,4096,{"jp":[3432432,43008],"us":[3439184,43008],"eu":[3312784,43008],"sh":[3287152,43008],"cn":[3360912,43008]}], +"textures/cave/hmc_textures.0B800.ia16.png": [32,32,2048,{"jp":[3432432,47104],"us":[3439184,47104],"eu":[3312784,47104],"sh":[3287152,47104],"cn":[3360912,47104]}], +"textures/cave/hmc_textures.0C000.ia16.png": [32,32,2048,{"jp":[3298272,43008],"us":[3305024,43008],"eu":[3178624,43008],"sh":[3152992,43008],"cn":[3226752,43008]}], +"textures/skyboxes/bbh.png": [84288,{"jp":[3118928,0],"us":[3125680,0],"eu":[2999280,0],"sh":[2973648,0],"cn":[3047408,0]}], +"textures/skyboxes/bidw.png": [131392,{"jp":[3146352,0],"us":[3153104,0],"eu":[3026704,0],"sh":[3001072,0],"cn":[3074832,0]}], +"textures/skyboxes/bitfs.png": [102720,{"jp":[2942432,0],"us":[2949184,0],"eu":[2822784,0],"sh":[2797152,0],"cn":[2870912,0]}], +"textures/skyboxes/bits.png": [131392,{"jp":[3191904,0],"us":[3198656,0],"eu":[3072256,0],"sh":[3046624,0],"cn":[3120384,0]}], +"textures/skyboxes/ccm.png": [131392,{"jp":[2847920,0],"us":[2854672,0],"eu":[2728272,0],"sh":[2702640,0],"cn":[2776400,0]}], +"textures/skyboxes/cloud_floor.png": [131392,{"jp":[3038752,0],"us":[3045504,0],"eu":[2919104,0],"sh":[2893472,0],"cn":[2967232,0]}], +"textures/skyboxes/clouds.png": [84288,{"jp":[2906480,0],"us":[2913232,0],"eu":[2786832,0],"sh":[2761200,0],"cn":[2834960,0]}], +"textures/skyboxes/ssl.png": [131392,{"jp":[3078784,0],"us":[3085536,0],"eu":[2959136,0],"sh":[2933504,0],"cn":[3007264,0]}], +"textures/skyboxes/water.png": [131392,{"jp":[2796624,0],"us":[2803376,0],"eu":[2676976,0],"sh":[2651344,0],"cn":[2725104,0]}], +"textures/skyboxes/wdw.png": [131392,{"jp":[2968208,0],"us":[2974960,0],"eu":[2848560,0],"sh":[2822928,0],"cn":[2896688,0]}], +"textures/effect/bubble.06048.rgba16.png": [32,32,2048,{"jp":[3594960,24648],"us":[3601712,24648],"eu":[3475312,24648],"sh":[3449680,24648],"cn":[3523440,24648]}], +"textures/effect/flower.00008.rgba16.png": [32,32,2048,{"jp":[3594960,8],"us":[3601712,8],"eu":[3475312,8],"sh":[3449680,8],"cn":[3523440,8]}], +"textures/effect/flower.00808.rgba16.png": [32,32,2048,{"jp":[3594960,2056],"us":[3601712,2056],"eu":[3475312,2056],"sh":[3449680,2056],"cn":[3523440,2056]}], +"textures/effect/flower.01008.rgba16.png": [32,32,2048,{"jp":[3594960,4104],"us":[3601712,4104],"eu":[3475312,4104],"sh":[3449680,4104],"cn":[3523440,4104]}], +"textures/effect/flower.01808.rgba16.png": [32,32,2048,{"jp":[3594960,6152],"us":[3601712,6152],"eu":[3475312,6152],"sh":[3449680,6152],"cn":[3523440,6152]}], +"textures/effect/lava_bubble.02020.rgba16.png": [32,32,2048,{"jp":[3594960,8224],"us":[3601712,8224],"eu":[3475312,8224],"sh":[3449680,8224],"cn":[3523440,8224]}], +"textures/effect/lava_bubble.02820.rgba16.png": [32,32,2048,{"jp":[3594960,10272],"us":[3601712,10272],"eu":[3475312,10272],"sh":[3449680,10272],"cn":[3523440,10272]}], +"textures/effect/lava_bubble.03020.rgba16.png": [32,32,2048,{"jp":[3594960,12320],"us":[3601712,12320],"eu":[3475312,12320],"sh":[3449680,12320],"cn":[3523440,12320]}], +"textures/effect/lava_bubble.03820.rgba16.png": [32,32,2048,{"jp":[3594960,14368],"us":[3601712,14368],"eu":[3475312,14368],"sh":[3449680,14368],"cn":[3523440,14368]}], +"textures/effect/lava_bubble.04020.rgba16.png": [32,32,2048,{"jp":[3594960,16416],"us":[3601712,16416],"eu":[3475312,16416],"sh":[3449680,16416],"cn":[3523440,16416]}], +"textures/effect/lava_bubble.04820.rgba16.png": [32,32,2048,{"jp":[3594960,18464],"us":[3601712,18464],"eu":[3475312,18464],"sh":[3449680,18464],"cn":[3523440,18464]}], +"textures/effect/lava_bubble.05020.rgba16.png": [32,32,2048,{"jp":[3594960,20512],"us":[3601712,20512],"eu":[3475312,20512],"sh":[3449680,20512],"cn":[3523440,20512]}], +"textures/effect/lava_bubble.05820.rgba16.png": [32,32,2048,{"jp":[3594960,22560],"us":[3601712,22560],"eu":[3475312,22560],"sh":[3449680,22560],"cn":[3523440,22560]}], +"textures/effect/tiny_bubble.0684C.rgba16.png": [16,16,512,{"jp":[3594960,26700],"us":[3601712,26700],"eu":[3475312,26700],"sh":[3449680,26700],"cn":[3523440,26700]}], +"textures/effect/tiny_bubble.06AD8.rgba16.png": [16,16,512,{"jp":[3594960,27352],"us":[3601712,27352],"eu":[3475312,27352],"sh":[3449680,27352],"cn":[3523440,27352]}], +"textures/fire/lll_textures.00000.rgba16.png": [32,32,2048,{"jp":[3262320,0],"us":[3269072,0],"eu":[3142672,0],"sh":[3117040,0],"cn":[3190800,0]}], +"textures/fire/lll_textures.00800.rgba16.png": [32,32,2048,{"jp":[3262320,2048],"us":[3269072,2048],"eu":[3142672,2048],"sh":[3117040,2048],"cn":[3190800,2048]}], +"textures/fire/lll_textures.01000.rgba16.png": [32,32,2048,{"jp":[3262320,4096],"us":[3269072,4096],"eu":[3142672,4096],"sh":[3117040,4096],"cn":[3190800,4096]}], +"textures/fire/lll_textures.01800.rgba16.png": [32,32,2048,{"jp":[3262320,6144],"us":[3269072,6144],"eu":[3142672,6144],"sh":[3117040,6144],"cn":[3190800,6144]}], +"textures/fire/lll_textures.02000.rgba16.png": [32,32,2048,{"jp":[3262320,8192],"us":[3269072,8192],"eu":[3142672,8192],"sh":[3117040,8192],"cn":[3190800,8192]}], +"textures/fire/lll_textures.02800.rgba16.png": [32,32,2048,{"jp":[3262320,10240],"us":[3269072,10240],"eu":[3142672,10240],"sh":[3117040,10240],"cn":[3190800,10240]}], +"textures/fire/lll_textures.03000.rgba16.png": [32,32,2048,{"jp":[3262320,12288],"us":[3269072,12288],"eu":[3142672,12288],"sh":[3117040,12288],"cn":[3190800,12288]}], +"textures/fire/lll_textures.03800.rgba16.png": [32,32,2048,{"jp":[3262320,14336],"us":[3269072,14336],"eu":[3142672,14336],"sh":[3117040,14336],"cn":[3190800,14336]}], +"textures/fire/lll_textures.04000.rgba16.png": [32,32,2048,{"jp":[3262320,16384],"us":[3269072,16384],"eu":[3142672,16384],"sh":[3117040,16384],"cn":[3190800,16384]}], +"textures/fire/lll_textures.04800.rgba16.png": [32,32,2048,{"jp":[3262320,18432],"us":[3269072,18432],"eu":[3142672,18432],"sh":[3117040,18432],"cn":[3190800,18432]}], +"textures/fire/lll_textures.05000.rgba16.png": [32,32,2048,{"jp":[3262320,20480],"us":[3269072,20480],"eu":[3142672,20480],"sh":[3117040,20480],"cn":[3190800,20480]}], +"textures/fire/lll_textures.05800.rgba16.png": [32,32,2048,{"jp":[3262320,22528],"us":[3269072,22528],"eu":[3142672,22528],"sh":[3117040,22528],"cn":[3190800,22528]}], +"textures/fire/lll_textures.06000.rgba16.png": [32,32,2048,{"jp":[3262320,24576],"us":[3269072,24576],"eu":[3142672,24576],"sh":[3117040,24576],"cn":[3190800,24576]}], +"textures/fire/lll_textures.06800.rgba16.png": [32,32,2048,{"jp":[3262320,26624],"us":[3269072,26624],"eu":[3142672,26624],"sh":[3117040,26624],"cn":[3190800,26624]}], +"textures/fire/lll_textures.07000.rgba16.png": [32,32,2048,{"jp":[3262320,28672],"us":[3269072,28672],"eu":[3142672,28672],"sh":[3117040,28672],"cn":[3190800,28672]}], +"textures/fire/lll_textures.07800.rgba16.png": [32,32,2048,{"jp":[3262320,30720],"us":[3269072,30720],"eu":[3142672,30720],"sh":[3117040,30720],"cn":[3190800,30720]}], +"textures/fire/lll_textures.08000.rgba16.png": [32,32,2048,{"jp":[3262320,32768],"us":[3269072,32768],"eu":[3142672,32768],"sh":[3117040,32768],"cn":[3190800,32768]}], +"textures/fire/lll_textures.08800.rgba16.png": [32,32,2048,{"jp":[3262320,34816],"us":[3269072,34816],"eu":[3142672,34816],"sh":[3117040,34816],"cn":[3190800,34816]}], +"textures/fire/lll_textures.09000.rgba16.png": [32,32,2048,{"jp":[1078992,80984],"us":[1083968,92856],"eu":[909712,49528],"sh":[934640,80984],"cn":[947456,193320]}], +"textures/fire/lll_textures.09800.rgba16.png": [32,32,2048,{"jp":[3262320,38912],"us":[3269072,38912],"eu":[3142672,38912],"sh":[3117040,38912],"cn":[3190800,38912]}], +"textures/fire/lll_textures.0A000.rgba16.png": [32,32,2048,{"jp":[3262320,40960],"us":[3269072,40960],"eu":[3142672,40960],"sh":[3117040,40960],"cn":[3190800,40960]}], +"textures/fire/lll_textures.0A800.rgba16.png": [32,32,2048,{"jp":[3262320,43008],"us":[3269072,43008],"eu":[3142672,43008],"sh":[3117040,43008],"cn":[3190800,43008]}], +"textures/fire/lll_textures.0B000.rgba16.png": [32,32,2048,{"jp":[3262320,45056],"us":[3269072,45056],"eu":[3142672,45056],"sh":[3117040,45056],"cn":[3190800,45056]}], +"textures/fire/lll_textures.0B800.rgba16.png": [32,32,2048,{"jp":[3262320,47104],"us":[3269072,47104],"eu":[3142672,47104],"sh":[3117040,47104],"cn":[3190800,47104]}], +"textures/generic/bob_textures.00000.rgba16.png": [32,32,2048,{"jp":[3323408,0],"us":[3330160,0],"eu":[3203760,0],"sh":[3178128,0],"cn":[3251888,0]}], +"textures/generic/bob_textures.00800.rgba16.png": [32,32,2048,{"jp":[1327760,36160],"us":[1334928,36160],"eu":[1206896,36160],"sh":[1183408,36160],"cn":[1250240,36160]}], +"textures/generic/bob_textures.01000.rgba16.png": [32,32,2048,{"jp":[3323408,4096],"us":[3330160,4096],"eu":[3203760,4096],"sh":[3178128,4096],"cn":[3251888,4096]}], +"textures/generic/bob_textures.01800.rgba16.png": [32,32,2048,{"jp":[3323408,6144],"us":[3330160,6144],"eu":[3203760,6144],"sh":[3178128,6144],"cn":[3251888,6144]}], +"textures/generic/bob_textures.02000.rgba16.png": [32,32,2048,{"jp":[3323408,8192],"us":[3330160,8192],"eu":[3203760,8192],"sh":[3178128,8192],"cn":[3251888,8192]}], +"textures/generic/bob_textures.02800.rgba16.png": [32,32,2048,{"jp":[3323408,10240],"us":[3330160,10240],"eu":[3203760,10240],"sh":[3178128,10240],"cn":[3251888,10240]}], +"textures/generic/bob_textures.03000.rgba16.png": [32,32,2048,{"jp":[3323408,12288],"us":[3330160,12288],"eu":[3203760,12288],"sh":[3178128,12288],"cn":[3251888,12288]}], +"textures/generic/bob_textures.03800.rgba16.png": [32,32,2048,{"jp":[3323408,14336],"us":[3330160,14336],"eu":[3203760,14336],"sh":[3178128,14336],"cn":[3251888,14336]}], +"textures/generic/bob_textures.04000.rgba16.png": [32,32,2048,{"jp":[3323408,16384],"us":[3330160,16384],"eu":[3203760,16384],"sh":[3178128,16384],"cn":[3251888,16384]}], +"textures/generic/bob_textures.04800.rgba16.png": [32,32,2048,{"jp":[3323408,18432],"us":[3330160,18432],"eu":[3203760,18432],"sh":[3178128,18432],"cn":[3251888,18432]}], +"textures/generic/bob_textures.05000.rgba16.png": [32,32,2048,{"jp":[3323408,20480],"us":[3330160,20480],"eu":[3203760,20480],"sh":[3178128,20480],"cn":[3251888,20480]}], +"textures/generic/bob_textures.05800.rgba16.png": [32,32,2048,{"jp":[3323408,22528],"us":[3330160,22528],"eu":[3203760,22528],"sh":[3178128,22528],"cn":[3251888,22528]}], +"textures/generic/bob_textures.06000.rgba16.png": [32,64,4096,{"jp":[3323408,24576],"us":[3330160,24576],"eu":[3203760,24576],"sh":[3178128,24576],"cn":[3251888,24576]}], +"textures/generic/bob_textures.07000.rgba16.png": [32,32,2048,{"jp":[3323408,28672],"us":[3330160,28672],"eu":[3203760,28672],"sh":[3178128,28672],"cn":[3251888,28672]}], +"textures/generic/bob_textures.07800.rgba16.png": [32,32,2048,{"jp":[3323408,30720],"us":[3330160,30720],"eu":[3203760,30720],"sh":[3178128,30720],"cn":[3251888,30720]}], +"textures/generic/bob_textures.08000.rgba16.png": [32,32,2048,{"jp":[3323408,32768],"us":[3330160,32768],"eu":[3203760,32768],"sh":[3178128,32768],"cn":[3251888,32768]}], +"textures/generic/bob_textures.08800.rgba16.png": [32,32,2048,{"jp":[3323408,34816],"us":[3330160,34816],"eu":[3203760,34816],"sh":[3178128,34816],"cn":[3251888,34816]}], +"textures/generic/bob_textures.09000.rgba16.png": [32,32,2048,{"jp":[3323408,36864],"us":[3330160,36864],"eu":[3203760,36864],"sh":[3178128,36864],"cn":[3251888,36864]}], +"textures/generic/bob_textures.09800.rgba16.png": [32,32,2048,{"jp":[3323408,38912],"us":[3330160,38912],"eu":[3203760,38912],"sh":[3178128,38912],"cn":[3251888,38912]}], +"textures/generic/bob_textures.0A000.rgba16.png": [32,32,2048,{"jp":[3323408,40960],"us":[3330160,40960],"eu":[3203760,40960],"sh":[3178128,40960],"cn":[3251888,40960]}], +"textures/generic/bob_textures.0A800.rgba16.png": [32,32,2048,{"jp":[3323408,43008],"us":[3330160,43008],"eu":[3203760,43008],"sh":[3178128,43008],"cn":[3251888,43008]}], +"textures/generic/bob_textures.0B000.ia16.png": [32,32,2048,{"jp":[3323408,45056],"us":[3330160,45056],"eu":[3203760,45056],"sh":[3178128,45056],"cn":[3251888,45056]}], +"textures/grass/wf_textures.00000.rgba16.png": [32,32,2048,{"jp":[3496176,0],"us":[3502928,0],"eu":[3376528,0],"sh":[3350896,0],"cn":[3424656,0]}], +"textures/grass/wf_textures.00800.rgba16.png": [32,32,2048,{"jp":[3496176,2048],"us":[3502928,2048],"eu":[3376528,2048],"sh":[3350896,2048],"cn":[3424656,2048]}], +"textures/grass/wf_textures.01000.rgba16.png": [32,32,2048,{"jp":[3496176,4096],"us":[3502928,4096],"eu":[3376528,4096],"sh":[3350896,4096],"cn":[3424656,4096]}], +"textures/grass/wf_textures.01800.rgba16.png": [32,32,2048,{"jp":[3496176,6144],"us":[3502928,6144],"eu":[3376528,6144],"sh":[3350896,6144],"cn":[3424656,6144]}], +"textures/grass/wf_textures.02000.rgba16.png": [32,32,2048,{"jp":[3496176,8192],"us":[3502928,8192],"eu":[3376528,8192],"sh":[3350896,8192],"cn":[3424656,8192]}], +"textures/grass/wf_textures.02800.rgba16.png": [32,32,2048,{"jp":[3496176,10240],"us":[3502928,10240],"eu":[3376528,10240],"sh":[3350896,10240],"cn":[3424656,10240]}], +"textures/grass/wf_textures.03000.rgba16.png": [32,32,2048,{"jp":[3496176,12288],"us":[3502928,12288],"eu":[3376528,12288],"sh":[3350896,12288],"cn":[3424656,12288]}], +"textures/grass/wf_textures.03800.rgba16.png": [32,32,2048,{"jp":[3496176,14336],"us":[3502928,14336],"eu":[3376528,14336],"sh":[3350896,14336],"cn":[3424656,14336]}], +"textures/grass/wf_textures.04000.rgba16.png": [32,32,2048,{"jp":[3496176,16384],"us":[3502928,16384],"eu":[3376528,16384],"sh":[3350896,16384],"cn":[3424656,16384]}], +"textures/grass/wf_textures.04800.rgba16.png": [32,32,2048,{"jp":[3496176,18432],"us":[3502928,18432],"eu":[3376528,18432],"sh":[3350896,18432],"cn":[3424656,18432]}], +"textures/grass/wf_textures.05000.rgba16.png": [32,32,2048,{"jp":[3496176,20480],"us":[3502928,20480],"eu":[3376528,20480],"sh":[3350896,20480],"cn":[3424656,20480]}], +"textures/grass/wf_textures.05800.rgba16.png": [32,32,2048,{"jp":[3496176,22528],"us":[3502928,22528],"eu":[3376528,22528],"sh":[3350896,22528],"cn":[3424656,22528]}], +"textures/grass/wf_textures.06000.rgba16.png": [32,32,2048,{"jp":[3390640,20480],"us":[3397392,20480],"eu":[3270992,20480],"sh":[3245360,20480],"cn":[3319120,20480]}], +"textures/grass/wf_textures.06800.rgba16.png": [32,32,2048,{"jp":[3496176,26624],"us":[3502928,26624],"eu":[3376528,26624],"sh":[3350896,26624],"cn":[3424656,26624]}], +"textures/grass/wf_textures.07000.rgba16.png": [32,32,2048,{"jp":[3496176,28672],"us":[3502928,28672],"eu":[3376528,28672],"sh":[3350896,28672],"cn":[3424656,28672]}], +"textures/grass/wf_textures.07800.rgba16.png": [32,32,2048,{"jp":[3496176,30720],"us":[3502928,30720],"eu":[3376528,30720],"sh":[3350896,30720],"cn":[3424656,30720]}], +"textures/grass/wf_textures.08000.rgba16.png": [32,32,2048,{"jp":[3496176,32768],"us":[3502928,32768],"eu":[3376528,32768],"sh":[3350896,32768],"cn":[3424656,32768]}], +"textures/grass/wf_textures.08800.rgba16.png": [32,32,2048,{"jp":[3496176,34816],"us":[3502928,34816],"eu":[3376528,34816],"sh":[3350896,34816],"cn":[3424656,34816]}], +"textures/grass/wf_textures.09000.rgba16.png": [32,32,2048,{"jp":[3496176,36864],"us":[3502928,36864],"eu":[3376528,36864],"sh":[3350896,36864],"cn":[3424656,36864]}], +"textures/grass/wf_textures.09800.rgba16.png": [32,32,2048,{"jp":[3496176,38912],"us":[3502928,38912],"eu":[3376528,38912],"sh":[3350896,38912],"cn":[3424656,38912]}], +"textures/grass/wf_textures.0A000.rgba16.png": [32,32,2048,{"jp":[3496176,40960],"us":[3502928,40960],"eu":[3376528,40960],"sh":[3350896,40960],"cn":[3424656,40960]}], +"textures/grass/wf_textures.0A800.rgba16.png": [32,32,2048,{"jp":[3496176,43008],"us":[3502928,43008],"eu":[3376528,43008],"sh":[3350896,43008],"cn":[3424656,43008]}], +"textures/grass/wf_textures.0B000.ia16.png": [32,32,2048,{"jp":[3323408,45056],"us":[3330160,45056],"eu":[3203760,45056],"sh":[3178128,45056],"cn":[3251888,45056]}], +"textures/grass/wf_textures.0B800.ia16.png": [32,32,2048,{"jp":[3496176,47104],"us":[3502928,47104],"eu":[3376528,47104],"sh":[3350896,47104],"cn":[3424656,47104]}], +"textures/inside/inside_castle_textures.00000.rgba16.png": [64,32,4096,{"jp":[3555104,0],"us":[3561856,0],"eu":[3435456,0],"sh":[3409824,0],"cn":[3483584,0]}], +"textures/inside/inside_castle_textures.01000.rgba16.png": [64,32,4096,{"jp":[3555104,4096],"us":[3561856,4096],"eu":[3435456,4096],"sh":[3409824,4096],"cn":[3483584,4096]}], +"textures/inside/inside_castle_textures.02000.rgba16.png": [32,64,4096,{"jp":[3555104,8192],"us":[3561856,8192],"eu":[3435456,8192],"sh":[3409824,8192],"cn":[3483584,8192]}], +"textures/inside/inside_castle_textures.03000.rgba16.png": [32,32,2048,{"jp":[3555104,12288],"us":[3561856,12288],"eu":[3435456,12288],"sh":[3409824,12288],"cn":[3483584,12288]}], +"textures/inside/inside_castle_textures.03800.rgba16.png": [32,32,2048,{"jp":[3555104,14336],"us":[3561856,14336],"eu":[3435456,14336],"sh":[3409824,14336],"cn":[3483584,14336]}], +"textures/inside/inside_castle_textures.04000.rgba16.png": [32,32,2048,{"jp":[3555104,16384],"us":[3561856,16384],"eu":[3435456,16384],"sh":[3409824,16384],"cn":[3483584,16384]}], +"textures/inside/inside_castle_textures.04800.rgba16.png": [32,32,2048,{"jp":[3460352,2048],"us":[3467104,2048],"eu":[3340704,2048],"sh":[3315072,2048],"cn":[3388832,2048]}], +"textures/inside/inside_castle_textures.05000.rgba16.png": [32,32,2048,{"jp":[3555104,20480],"us":[3561856,20480],"eu":[3435456,20480],"sh":[3409824,20480],"cn":[3483584,20480]}], +"textures/inside/inside_castle_textures.05800.rgba16.png": [32,32,2048,{"jp":[3555104,22528],"us":[3561856,22528],"eu":[3435456,22528],"sh":[3409824,22528],"cn":[3483584,22528]}], +"textures/inside/inside_castle_textures.06000.rgba16.png": [32,64,4096,{"jp":[3555104,24576],"us":[3561856,24576],"eu":[3435456,24576],"sh":[3409824,24576],"cn":[3483584,24576]}], +"textures/inside/inside_castle_textures.07000.rgba16.png": [32,64,4096,{"jp":[3555104,28672],"us":[3561856,28672],"eu":[3435456,28672],"sh":[3409824,28672],"cn":[3483584,28672]}], +"textures/inside/inside_castle_textures.08000.rgba16.png": [32,32,2048,{"jp":[3555104,32768],"us":[3561856,32768],"eu":[3435456,32768],"sh":[3409824,32768],"cn":[3483584,32768]}], +"textures/inside/inside_castle_textures.08800.rgba16.png": [32,32,2048,{"jp":[3555104,34816],"us":[3561856,34816],"eu":[3435456,34816],"sh":[3409824,34816],"cn":[3483584,34816]}], +"textures/inside/inside_castle_textures.09000.rgba16.png": [32,64,4096,{"jp":[3555104,36864],"us":[3561856,36864],"eu":[3435456,36864],"sh":[3409824,36864],"cn":[3483584,36864]}], +"textures/inside/inside_castle_textures.0A000.rgba16.png": [32,64,4096,{"jp":[3555104,40960],"us":[3561856,40960],"eu":[3435456,40960],"sh":[3409824,40960],"cn":[3483584,40960]}], +"textures/inside/inside_castle_textures.0B000.rgba16.png": [32,32,2048,{"jp":[3555104,45056],"us":[3561856,45056],"eu":[3435456,45056],"sh":[3409824,45056],"cn":[3483584,45056]}], +"textures/inside/inside_castle_textures.0B800.rgba16.png": [64,32,4096,{"jp":[3555104,47104],"us":[3561856,47104],"eu":[3435456,47104],"sh":[3409824,47104],"cn":[3483584,47104]}], +"textures/intro_raw/hand_closed.rgba16.png": [32,32,2048,{"jp":[2455304],"us":[2463112],"eu":[2331912],"sh":[2308680],"cn":[2379416]}], +"textures/intro_raw/hand_open.rgba16.png": [32,32,2048,{"jp":[2453248],"us":[2461056],"eu":[2329856],"sh":[2306624],"cn":[2377360]}], +"textures/intro_raw/mario_face_shine.ia8.png": [32,32,1024,{"jp":[2503888],"us":[2511696],"eu":[2380496],"sh":[2357264],"cn":[2428000]}], +"textures/intro_raw/red_star_0.rgba16.png": [32,32,2048,{"jp":[2457352],"us":[2465160],"eu":[2333960],"sh":[2310728],"cn":[2381464]}], +"textures/intro_raw/red_star_1.rgba16.png": [32,32,2048,{"jp":[2459400],"us":[2467208],"eu":[2336008],"sh":[2312776],"cn":[2383512]}], +"textures/intro_raw/red_star_2.rgba16.png": [32,32,2048,{"jp":[2461448],"us":[2469256],"eu":[2338056],"sh":[2314824],"cn":[2385560]}], +"textures/intro_raw/red_star_3.rgba16.png": [32,32,2048,{"jp":[2463496],"us":[2471304],"eu":[2340104],"sh":[2316872],"cn":[2387608]}], +"textures/intro_raw/red_star_4.rgba16.png": [32,32,2048,{"jp":[2465544],"us":[2473352],"eu":[2342152],"sh":[2318920],"cn":[2389656]}], +"textures/intro_raw/red_star_5.rgba16.png": [32,32,2048,{"jp":[2467592],"us":[2475400],"eu":[2344200],"sh":[2320968],"cn":[2391704]}], +"textures/intro_raw/red_star_6.rgba16.png": [32,32,2048,{"jp":[2469640],"us":[2477448],"eu":[2346248],"sh":[2323016],"cn":[2393752]}], +"textures/intro_raw/red_star_7.rgba16.png": [32,32,2048,{"jp":[2471688],"us":[2479496],"eu":[2348296],"sh":[2325064],"cn":[2395800]}], +"textures/intro_raw/sparkle_0.rgba16.png": [32,32,2048,{"jp":[2490888],"us":[2498696],"eu":[2367496],"sh":[2344264],"cn":[2415000]}], +"textures/intro_raw/sparkle_1.rgba16.png": [32,32,2048,{"jp":[2492936],"us":[2500744],"eu":[2369544],"sh":[2346312],"cn":[2417048]}], +"textures/intro_raw/sparkle_2.rgba16.png": [32,32,2048,{"jp":[2494984],"us":[2502792],"eu":[2371592],"sh":[2348360],"cn":[2419096]}], +"textures/intro_raw/sparkle_3.rgba16.png": [32,32,2048,{"jp":[2497032],"us":[2504840],"eu":[2373640],"sh":[2350408],"cn":[2421144]}], +"textures/intro_raw/sparkle_4.rgba16.png": [32,32,2048,{"jp":[2499080],"us":[2506888],"eu":[2375688],"sh":[2352456],"cn":[2423192]}], +"textures/intro_raw/sparkle_5.rgba16.png": [32,32,2048,{"jp":[2501128],"us":[2508936],"eu":[2377736],"sh":[2354504],"cn":[2425240]}], +"textures/intro_raw/white_star_0.rgba16.png": [32,32,2048,{"jp":[2473736],"us":[2481544],"eu":[2350344],"sh":[2327112],"cn":[2397848]}], +"textures/intro_raw/white_star_1.rgba16.png": [32,32,2048,{"jp":[2475784],"us":[2483592],"eu":[2352392],"sh":[2329160],"cn":[2399896]}], +"textures/intro_raw/white_star_2.rgba16.png": [32,32,2048,{"jp":[2477832],"us":[2485640],"eu":[2354440],"sh":[2331208],"cn":[2401944]}], +"textures/intro_raw/white_star_3.rgba16.png": [32,32,2048,{"jp":[2479880],"us":[2487688],"eu":[2356488],"sh":[2333256],"cn":[2403992]}], +"textures/intro_raw/white_star_4.rgba16.png": [32,32,2048,{"jp":[2481928],"us":[2489736],"eu":[2358536],"sh":[2335304],"cn":[2406040]}], +"textures/intro_raw/white_star_5.rgba16.png": [32,32,2048,{"jp":[2483976],"us":[2491784],"eu":[2360584],"sh":[2337352],"cn":[2408088]}], +"textures/intro_raw/white_star_6.rgba16.png": [32,32,2048,{"jp":[2486024],"us":[2493832],"eu":[2362632],"sh":[2339400],"cn":[2410136]}], +"textures/intro_raw/white_star_7.rgba16.png": [32,32,2048,{"jp":[2488072],"us":[2495880],"eu":[2364680],"sh":[2341448],"cn":[2412184]}], +"textures/machine/ttc_textures.00000.rgba16.png": [32,32,2048,{"jp":[3460352,0],"us":[3467104,0],"eu":[3340704,0],"sh":[3315072,0],"cn":[3388832,0]}], +"textures/machine/ttc_textures.00800.rgba16.png": [32,32,2048,{"jp":[3460352,2048],"us":[3467104,2048],"eu":[3340704,2048],"sh":[3315072,2048],"cn":[3388832,2048]}], +"textures/machine/ttc_textures.01000.rgba16.png": [32,32,2048,{"jp":[3460352,4096],"us":[3467104,4096],"eu":[3340704,4096],"sh":[3315072,4096],"cn":[3388832,4096]}], +"textures/machine/ttc_textures.01800.rgba16.png": [32,32,2048,{"jp":[3460352,6144],"us":[3467104,6144],"eu":[3340704,6144],"sh":[3315072,6144],"cn":[3388832,6144]}], +"textures/machine/ttc_textures.02000.rgba16.png": [32,32,2048,{"jp":[3460352,8192],"us":[3467104,8192],"eu":[3340704,8192],"sh":[3315072,8192],"cn":[3388832,8192]}], +"textures/machine/ttc_textures.02800.rgba16.png": [32,32,2048,{"jp":[3460352,10240],"us":[3467104,10240],"eu":[3340704,10240],"sh":[3315072,10240],"cn":[3388832,10240]}], +"textures/machine/ttc_textures.03000.rgba16.png": [32,32,2048,{"jp":[3460352,12288],"us":[3467104,12288],"eu":[3340704,12288],"sh":[3315072,12288],"cn":[3388832,12288]}], +"textures/machine/ttc_textures.03800.rgba16.png": [32,32,2048,{"jp":[3460352,14336],"us":[3467104,14336],"eu":[3340704,14336],"sh":[3315072,14336],"cn":[3388832,14336]}], +"textures/machine/ttc_textures.04000.rgba16.png": [32,64,4096,{"jp":[3460352,16384],"us":[3467104,16384],"eu":[3340704,16384],"sh":[3315072,16384],"cn":[3388832,16384]}], +"textures/machine/ttc_textures.05000.rgba16.png": [32,32,2048,{"jp":[3460352,20480],"us":[3467104,20480],"eu":[3340704,20480],"sh":[3315072,20480],"cn":[3388832,20480]}], +"textures/machine/ttc_textures.05800.rgba16.png": [32,32,2048,{"jp":[3460352,22528],"us":[3467104,22528],"eu":[3340704,22528],"sh":[3315072,22528],"cn":[3388832,22528]}], +"textures/machine/ttc_textures.06000.rgba16.png": [32,32,2048,{"jp":[3460352,24576],"us":[3467104,24576],"eu":[3340704,24576],"sh":[3315072,24576],"cn":[3388832,24576]}], +"textures/machine/ttc_textures.06800.rgba16.png": [32,32,2048,{"jp":[3460352,26624],"us":[3467104,26624],"eu":[3340704,26624],"sh":[3315072,26624],"cn":[3388832,26624]}], +"textures/machine/ttc_textures.07000.rgba16.png": [32,32,2048,{"jp":[3460352,28672],"us":[3467104,28672],"eu":[3340704,28672],"sh":[3315072,28672],"cn":[3388832,28672]}], +"textures/machine/ttc_textures.07800.rgba16.png": [16,64,2048,{"jp":[3460352,30720],"us":[3467104,30720],"eu":[3340704,30720],"sh":[3315072,30720],"cn":[3388832,30720]}], +"textures/machine/ttc_textures.08000.rgba16.png": [64,8,1024,{"jp":[3460352,32768],"us":[3467104,32768],"eu":[3340704,32768],"sh":[3315072,32768],"cn":[3388832,32768]}], +"textures/machine/ttc_textures.08400.rgba16.png": [32,32,2048,{"jp":[3460352,33792],"us":[3467104,33792],"eu":[3340704,33792],"sh":[3315072,33792],"cn":[3388832,33792]}], +"textures/mountain/ttm_textures.00000.rgba16.png": [32,32,2048,{"jp":[3473152,0],"us":[3479904,0],"eu":[3353504,0],"sh":[3327872,0],"cn":[3401632,0]}], +"textures/mountain/ttm_textures.00800.rgba16.png": [64,32,4096,{"jp":[3473152,2048],"us":[3479904,2048],"eu":[3353504,2048],"sh":[3327872,2048],"cn":[3401632,2048]}], +"textures/mountain/ttm_textures.01800.rgba16.png": [32,64,4096,{"jp":[3473152,6144],"us":[3479904,6144],"eu":[3353504,6144],"sh":[3327872,6144],"cn":[3401632,6144]}], +"textures/mountain/ttm_textures.02800.rgba16.png": [32,32,2048,{"jp":[3473152,10240],"us":[3479904,10240],"eu":[3353504,10240],"sh":[3327872,10240],"cn":[3401632,10240]}], +"textures/mountain/ttm_textures.03000.rgba16.png": [32,32,2048,{"jp":[3473152,12288],"us":[3479904,12288],"eu":[3353504,12288],"sh":[3327872,12288],"cn":[3401632,12288]}], +"textures/mountain/ttm_textures.03800.rgba16.png": [32,32,2048,{"jp":[3473152,14336],"us":[3479904,14336],"eu":[3353504,14336],"sh":[3327872,14336],"cn":[3401632,14336]}], +"textures/mountain/ttm_textures.04000.rgba16.png": [32,32,2048,{"jp":[3473152,16384],"us":[3479904,16384],"eu":[3353504,16384],"sh":[3327872,16384],"cn":[3401632,16384]}], +"textures/mountain/ttm_textures.04800.rgba16.png": [32,32,2048,{"jp":[3473152,18432],"us":[3479904,18432],"eu":[3353504,18432],"sh":[3327872,18432],"cn":[3401632,18432]}], +"textures/mountain/ttm_textures.05000.rgba16.png": [32,32,2048,{"jp":[3473152,20480],"us":[3479904,20480],"eu":[3353504,20480],"sh":[3327872,20480],"cn":[3401632,20480]}], +"textures/mountain/ttm_textures.05800.rgba16.png": [32,64,4096,{"jp":[3473152,22528],"us":[3479904,22528],"eu":[3353504,22528],"sh":[3327872,22528],"cn":[3401632,22528]}], +"textures/mountain/ttm_textures.06800.rgba16.png": [32,32,2048,{"jp":[3473152,26624],"us":[3479904,26624],"eu":[3353504,26624],"sh":[3327872,26624],"cn":[3401632,26624]}], +"textures/mountain/ttm_textures.07000.rgba16.png": [32,32,2048,{"jp":[3473152,28672],"us":[3479904,28672],"eu":[3353504,28672],"sh":[3327872,28672],"cn":[3401632,28672]}], +"textures/mountain/ttm_textures.07800.rgba16.png": [32,32,2048,{"jp":[3473152,30720],"us":[3479904,30720],"eu":[3353504,30720],"sh":[3327872,30720],"cn":[3401632,30720]}], +"textures/mountain/ttm_textures.08000.rgba16.png": [32,32,2048,{"jp":[3473152,32768],"us":[3479904,32768],"eu":[3353504,32768],"sh":[3327872,32768],"cn":[3401632,32768]}], +"textures/mountain/ttm_textures.08800.rgba16.png": [64,32,4096,{"jp":[3473152,34816],"us":[3479904,34816],"eu":[3353504,34816],"sh":[3327872,34816],"cn":[3401632,34816]}], +"textures/mountain/ttm_textures.09800.rgba16.png": [32,32,2048,{"jp":[3473152,38912],"us":[3479904,38912],"eu":[3353504,38912],"sh":[3327872,38912],"cn":[3401632,38912]}], +"textures/mountain/ttm_textures.0A000.rgba16.png": [32,32,2048,{"jp":[3390640,24576],"us":[3397392,24576],"eu":[3270992,24576],"sh":[3245360,24576],"cn":[3319120,24576]}], +"textures/mountain/ttm_textures.0A800.rgba16.png": [32,32,2048,{"jp":[3473152,43008],"us":[3479904,43008],"eu":[3353504,43008],"sh":[3327872,43008],"cn":[3401632,43008]}], +"textures/mountain/ttm_textures.0B000.rgba16.png": [32,32,2048,{"jp":[3473152,45056],"us":[3479904,45056],"eu":[3353504,45056],"sh":[3327872,45056],"cn":[3401632,45056]}], +"textures/mountain/ttm_textures.0B800.rgba16.png": [32,32,2048,{"jp":[3473152,47104],"us":[3479904,47104],"eu":[3353504,47104],"sh":[3327872,47104],"cn":[3401632,47104]}], +"textures/mountain/ttm_textures.0C000.rgba16.png": [32,32,2048,{"jp":[3473152,49152],"us":[3479904,49152],"eu":[3353504,49152],"sh":[3327872,49152],"cn":[3401632,49152]}], +"textures/outside/castle_grounds_textures.00000.rgba16.png": [32,32,2048,{"jp":[3527344,0],"us":[3534096,0],"eu":[3407696,0],"sh":[3382064,0],"cn":[3455824,0]}], +"textures/outside/castle_grounds_textures.00800.rgba16.png": [32,32,2048,{"jp":[3527344,2048],"us":[3534096,2048],"eu":[3407696,2048],"sh":[3382064,2048],"cn":[3455824,2048]}], +"textures/outside/castle_grounds_textures.01000.rgba16.png": [64,32,4096,{"jp":[3527344,4096],"us":[3534096,4096],"eu":[3407696,4096],"sh":[3382064,4096],"cn":[3455824,4096]}], +"textures/outside/castle_grounds_textures.02000.rgba16.png": [32,64,4096,{"jp":[3527344,8192],"us":[3534096,8192],"eu":[3407696,8192],"sh":[3382064,8192],"cn":[3455824,8192]}], +"textures/outside/castle_grounds_textures.03000.rgba16.png": [32,32,2048,{"jp":[3527344,12288],"us":[3534096,12288],"eu":[3407696,12288],"sh":[3382064,12288],"cn":[3455824,12288]}], +"textures/outside/castle_grounds_textures.03800.rgba16.png": [32,32,2048,{"jp":[3527344,14336],"us":[3534096,14336],"eu":[3407696,14336],"sh":[3382064,14336],"cn":[3455824,14336]}], +"textures/outside/castle_grounds_textures.04000.rgba16.png": [32,32,2048,{"jp":[3527344,16384],"us":[3534096,16384],"eu":[3407696,16384],"sh":[3382064,16384],"cn":[3455824,16384]}], +"textures/outside/castle_grounds_textures.04800.rgba16.png": [32,64,4096,{"jp":[3527344,18432],"us":[3534096,18432],"eu":[3407696,18432],"sh":[3382064,18432],"cn":[3455824,18432]}], +"textures/outside/castle_grounds_textures.05800.rgba16.png": [32,32,2048,{"jp":[3527344,22528],"us":[3534096,22528],"eu":[3407696,22528],"sh":[3382064,22528],"cn":[3455824,22528]}], +"textures/outside/castle_grounds_textures.06000.rgba16.png": [32,32,2048,{"jp":[3527344,24576],"us":[3534096,24576],"eu":[3407696,24576],"sh":[3382064,24576],"cn":[3455824,24576]}], +"textures/outside/castle_grounds_textures.06800.rgba16.png": [64,32,4096,{"jp":[3527344,26624],"us":[3534096,26624],"eu":[3407696,26624],"sh":[3382064,26624],"cn":[3455824,26624]}], +"textures/outside/castle_grounds_textures.07800.rgba16.png": [32,32,2048,{"jp":[3527344,30720],"us":[3534096,30720],"eu":[3407696,30720],"sh":[3382064,30720],"cn":[3455824,30720]}], +"textures/outside/castle_grounds_textures.08000.rgba16.png": [32,32,2048,{"jp":[3527344,32768],"us":[3534096,32768],"eu":[3407696,32768],"sh":[3382064,32768],"cn":[3455824,32768]}], +"textures/outside/castle_grounds_textures.08800.rgba16.png": [32,32,2048,{"jp":[3527344,34816],"us":[3534096,34816],"eu":[3407696,34816],"sh":[3382064,34816],"cn":[3455824,34816]}], +"textures/outside/castle_grounds_textures.09000.rgba16.png": [32,32,2048,{"jp":[3527344,36864],"us":[3534096,36864],"eu":[3407696,36864],"sh":[3382064,36864],"cn":[3455824,36864]}], +"textures/outside/castle_grounds_textures.09800.rgba16.png": [32,32,2048,{"jp":[3527344,38912],"us":[3534096,38912],"eu":[3407696,38912],"sh":[3382064,38912],"cn":[3455824,38912]}], +"textures/outside/castle_grounds_textures.0A000.rgba16.png": [32,32,2048,{"jp":[3527344,40960],"us":[3534096,40960],"eu":[3407696,40960],"sh":[3382064,40960],"cn":[3455824,40960]}], +"textures/outside/castle_grounds_textures.0A800.rgba16.png": [32,32,2048,{"jp":[3527344,43008],"us":[3534096,43008],"eu":[3407696,43008],"sh":[3382064,43008],"cn":[3455824,43008]}], +"textures/outside/castle_grounds_textures.0B000.rgba16.png": [16,32,1024,{"jp":[3527344,45056],"us":[3534096,45056],"eu":[3407696,45056],"sh":[3382064,45056],"cn":[3455824,45056]}], +"textures/outside/castle_grounds_textures.0B400.rgba16.png": [32,32,2048,{"jp":[3527344,46080],"us":[3534096,46080],"eu":[3407696,46080],"sh":[3382064,46080],"cn":[3455824,46080]}], +"textures/outside/castle_grounds_textures.0BC00.ia16.png": [32,32,2048,{"jp":[3323408,45056],"us":[3330160,45056],"eu":[3203760,45056],"sh":[3178128,45056],"cn":[3251888,45056]}], +"textures/segment2/font_graphics.05900.ia4.png": [16,8,64,{"us":[1083968,22784],"cn":[947456,86272]}], +"textures/segment2/font_graphics.05940.ia4.png": [16,8,64,{"us":[1083968,22848],"cn":[947456,86336]}], +"textures/segment2/font_graphics.05980.ia4.png": [16,8,64,{"us":[1083968,22912],"cn":[947456,86400]}], +"textures/segment2/font_graphics.059C0.ia4.png": [16,8,64,{"us":[1083968,22976],"cn":[947456,86464]}], +"textures/segment2/font_graphics.05A00.ia4.png": [16,8,64,{"us":[1083968,23040],"cn":[947456,86528]}], +"textures/segment2/font_graphics.05A40.ia4.png": [16,8,64,{"us":[1083968,23104],"cn":[947456,86592]}], +"textures/segment2/font_graphics.05A80.ia4.png": [16,8,64,{"us":[1083968,23168],"cn":[947456,86656]}], +"textures/segment2/font_graphics.05AC0.ia4.png": [16,8,64,{"us":[1083968,23232],"cn":[947456,86720]}], +"textures/segment2/font_graphics.05B00.ia4.png": [16,8,64,{"us":[1083968,23296],"cn":[947456,86784]}], +"textures/segment2/font_graphics.05B40.ia4.png": [16,8,64,{"us":[1083968,23360],"cn":[947456,86848]}], +"textures/segment2/font_graphics.05B80.ia4.png": [16,8,64,{"us":[1083968,23424],"cn":[947456,86912]}], +"textures/segment2/font_graphics.05BC0.ia4.png": [16,8,64,{"us":[1083968,23488],"cn":[947456,86976]}], +"textures/segment2/font_graphics.05C00.ia4.png": [16,8,64,{"us":[1083968,23552],"cn":[947456,87040]}], +"textures/segment2/font_graphics.05C40.ia4.png": [16,8,64,{"us":[1083968,23616],"cn":[947456,87104]}], +"textures/segment2/font_graphics.05C80.ia4.png": [16,8,64,{"us":[1083968,23680],"cn":[947456,87168]}], +"textures/segment2/font_graphics.05CC0.ia4.png": [16,8,64,{"us":[1083968,23744],"cn":[947456,87232]}], +"textures/segment2/font_graphics.05D00.ia4.png": [16,8,64,{"us":[1083968,23808],"cn":[947456,87296]}], +"textures/segment2/font_graphics.05D40.ia4.png": [16,8,64,{"us":[1083968,23872],"cn":[947456,87360]}], +"textures/segment2/font_graphics.05D80.ia4.png": [16,8,64,{"us":[1083968,23936],"cn":[947456,87424]}], +"textures/segment2/font_graphics.05DC0.ia4.png": [16,8,64,{"us":[1083968,24000],"cn":[947456,87488]}], +"textures/segment2/font_graphics.05E00.ia4.png": [16,8,64,{"us":[1083968,24064],"cn":[947456,87552]}], +"textures/segment2/font_graphics.05E40.ia4.png": [16,8,64,{"us":[1083968,24128],"cn":[947456,87616]}], +"textures/segment2/font_graphics.05E80.ia4.png": [16,8,64,{"us":[1083968,24192],"cn":[947456,87680]}], +"textures/segment2/font_graphics.05EC0.ia4.png": [16,8,64,{"us":[1083968,24256],"cn":[947456,87744]}], "textures/segment2/font_graphics.05F00.ia1.png": [16,8,16,{"eu":[909712,24320]}], -"textures/segment2/font_graphics.05F00.ia4.png": [16,8,64,{"us":[1083968,24320]}], +"textures/segment2/font_graphics.05F00.ia4.png": [16,8,64,{"us":[1083968,24320],"cn":[947456,87808]}], "textures/segment2/font_graphics.05F10.ia1.png": [16,8,16,{"eu":[909712,24336]}], "textures/segment2/font_graphics.05F20.ia1.png": [16,8,16,{"eu":[909712,24352]}], "textures/segment2/font_graphics.05F30.ia1.png": [16,8,16,{"eu":[909712,24368]}], "textures/segment2/font_graphics.05F40.ia1.png": [16,8,16,{"eu":[909712,24384]}], -"textures/segment2/font_graphics.05F40.ia4.png": [16,8,64,{"us":[1083968,24384]}], +"textures/segment2/font_graphics.05F40.ia4.png": [16,8,64,{"us":[1083968,24384],"cn":[947456,87872]}], "textures/segment2/font_graphics.05F50.ia1.png": [16,8,16,{"eu":[909712,24400]}], "textures/segment2/font_graphics.05F60.ia1.png": [16,8,16,{"eu":[909712,24416]}], "textures/segment2/font_graphics.05F70.ia1.png": [16,8,16,{"eu":[909712,24432]}], "textures/segment2/font_graphics.05F80.ia1.png": [16,8,16,{"eu":[909712,24448]}], -"textures/segment2/font_graphics.05F80.ia4.png": [16,8,64,{"us":[1083968,24448]}], +"textures/segment2/font_graphics.05F80.ia4.png": [16,8,64,{"us":[1083968,24448],"cn":[947456,87936]}], "textures/segment2/font_graphics.05F90.ia1.png": [16,8,16,{"eu":[909712,24464]}], "textures/segment2/font_graphics.05FA0.ia1.png": [16,8,16,{"eu":[909712,24480]}], "textures/segment2/font_graphics.05FB0.ia1.png": [16,8,16,{"eu":[909712,24496]}], "textures/segment2/font_graphics.05FC0.ia1.png": [16,8,16,{"eu":[909712,24512]}], -"textures/segment2/font_graphics.05FC0.ia4.png": [16,8,64,{"us":[1083968,24512]}], +"textures/segment2/font_graphics.05FC0.ia4.png": [16,8,64,{"us":[1083968,24512],"cn":[947456,88000]}], "textures/segment2/font_graphics.05FD0.ia1.png": [16,8,16,{"eu":[909712,24528]}], "textures/segment2/font_graphics.05FE0.ia1.png": [16,8,16,{"eu":[909712,24544]}], "textures/segment2/font_graphics.05FF0.ia1.png": [16,8,16,{"eu":[909712,24560]}], "textures/segment2/font_graphics.06000.ia1.png": [16,8,16,{"eu":[909712,24576]}], -"textures/segment2/font_graphics.06000.ia4.png": [16,8,64,{"us":[1083968,24576]}], +"textures/segment2/font_graphics.06000.ia4.png": [16,8,64,{"us":[1083968,24576],"cn":[947456,88064]}], "textures/segment2/font_graphics.06010.ia1.png": [16,8,16,{"eu":[909712,24592]}], "textures/segment2/font_graphics.06020.ia1.png": [16,8,16,{"eu":[909712,24608]}], "textures/segment2/font_graphics.06030.ia1.png": [16,8,16,{"eu":[909712,24624]}], "textures/segment2/font_graphics.06040.ia1.png": [16,8,16,{"eu":[909712,24640]}], -"textures/segment2/font_graphics.06040.ia4.png": [16,8,64,{"us":[1083968,24640]}], +"textures/segment2/font_graphics.06040.ia4.png": [16,8,64,{"us":[1083968,24640],"cn":[947456,88128]}], "textures/segment2/font_graphics.06050.ia1.png": [16,8,16,{"eu":[909712,24656]}], "textures/segment2/font_graphics.06060.ia1.png": [16,8,16,{"eu":[909712,24672]}], "textures/segment2/font_graphics.06070.ia1.png": [16,8,16,{"eu":[909712,24688]}], "textures/segment2/font_graphics.06080.ia1.png": [16,8,16,{"eu":[909712,24704]}], -"textures/segment2/font_graphics.06080.ia4.png": [16,8,64,{"us":[1083968,24704]}], +"textures/segment2/font_graphics.06080.ia4.png": [16,8,64,{"us":[1083968,24704],"cn":[947456,88192]}], "textures/segment2/font_graphics.06090.ia1.png": [16,8,16,{"eu":[909712,24720]}], "textures/segment2/font_graphics.060A0.ia1.png": [16,8,16,{"eu":[909712,24736]}], "textures/segment2/font_graphics.060B0.ia1.png": [16,8,16,{"eu":[909712,24752]}], "textures/segment2/font_graphics.060C0.ia1.png": [16,8,16,{"eu":[909712,24768]}], -"textures/segment2/font_graphics.060C0.ia4.png": [16,8,64,{"us":[1083968,24768]}], +"textures/segment2/font_graphics.060C0.ia4.png": [16,8,64,{"us":[1083968,24768],"cn":[947456,88256]}], "textures/segment2/font_graphics.060D0.ia1.png": [16,8,16,{"eu":[909712,24784]}], "textures/segment2/font_graphics.060E0.ia1.png": [16,8,16,{"eu":[909712,24800]}], "textures/segment2/font_graphics.060F0.ia1.png": [16,8,16,{"eu":[909712,24816]}], "textures/segment2/font_graphics.06100.ia1.png": [16,8,16,{"eu":[909712,24832]}], -"textures/segment2/font_graphics.06100.ia4.png": [16,8,64,{"us":[1083968,24832]}], +"textures/segment2/font_graphics.06100.ia4.png": [16,8,64,{"us":[1083968,24832],"cn":[947456,88320]}], "textures/segment2/font_graphics.06110.ia1.png": [16,8,16,{"eu":[909712,24848]}], "textures/segment2/font_graphics.06120.ia1.png": [16,8,16,{"eu":[909712,24864]}], "textures/segment2/font_graphics.06130.ia1.png": [16,8,16,{"eu":[909712,24880]}], "textures/segment2/font_graphics.06140.ia1.png": [16,8,16,{"eu":[909712,24896]}], -"textures/segment2/font_graphics.06140.ia4.png": [16,8,64,{"us":[1083968,24896]}], +"textures/segment2/font_graphics.06140.ia4.png": [16,8,64,{"us":[1083968,24896],"cn":[947456,88384]}], "textures/segment2/font_graphics.06150.ia1.png": [16,8,16,{"eu":[909712,24912]}], "textures/segment2/font_graphics.06160.ia1.png": [16,8,16,{"eu":[909712,24928]}], "textures/segment2/font_graphics.06170.ia1.png": [16,8,16,{"eu":[909712,24944]}], "textures/segment2/font_graphics.06180.ia1.png": [16,8,16,{"eu":[909712,24960]}], -"textures/segment2/font_graphics.06180.ia4.png": [16,8,64,{"us":[1083968,24960]}], +"textures/segment2/font_graphics.06180.ia4.png": [16,8,64,{"us":[1083968,24960],"cn":[947456,88448]}], "textures/segment2/font_graphics.06190.ia1.png": [16,8,16,{"eu":[909712,24976]}], "textures/segment2/font_graphics.061A0.ia1.png": [16,8,16,{"eu":[909712,24992]}], "textures/segment2/font_graphics.061B0.ia1.png": [16,8,16,{"eu":[909712,25008]}], "textures/segment2/font_graphics.061C0.ia1.png": [16,8,16,{"eu":[909712,25024]}], -"textures/segment2/font_graphics.061C0.ia4.png": [16,8,64,{"us":[1083968,25024]}], +"textures/segment2/font_graphics.061C0.ia4.png": [16,8,64,{"us":[1083968,25024],"cn":[947456,88512]}], "textures/segment2/font_graphics.061D0.ia1.png": [16,8,16,{"eu":[909712,25040]}], "textures/segment2/font_graphics.061E0.ia1.png": [16,8,16,{"eu":[909712,25056]}], "textures/segment2/font_graphics.061F0.ia1.png": [16,8,16,{"eu":[909712,25072]}], "textures/segment2/font_graphics.06200.ia1.png": [16,8,16,{"eu":[909712,25088]}], -"textures/segment2/font_graphics.06200.ia4.png": [16,8,64,{"us":[1083968,25088]}], +"textures/segment2/font_graphics.06200.ia4.png": [16,8,64,{"us":[1083968,25088],"cn":[947456,88576]}], "textures/segment2/font_graphics.06210.ia1.png": [16,8,16,{"eu":[909712,25104]}], "textures/segment2/font_graphics.06220.ia1.png": [16,8,16,{"eu":[909712,25120]}], "textures/segment2/font_graphics.06230.ia1.png": [16,8,16,{"eu":[909712,25136]}], "textures/segment2/font_graphics.06240.ia1.png": [16,8,16,{"eu":[909712,25152]}], -"textures/segment2/font_graphics.06240.ia4.png": [16,8,64,{"us":[1083968,25152]}], +"textures/segment2/font_graphics.06240.ia4.png": [16,8,64,{"us":[1083968,25152],"cn":[947456,88640]}], "textures/segment2/font_graphics.06250.ia1.png": [16,8,16,{"eu":[909712,25168]}], "textures/segment2/font_graphics.06260.ia1.png": [16,8,16,{"eu":[909712,25184]}], "textures/segment2/font_graphics.06270.ia1.png": [16,8,16,{"eu":[909712,25200]}], "textures/segment2/font_graphics.06280.ia1.png": [16,8,16,{"eu":[909712,25216]}], -"textures/segment2/font_graphics.06280.ia4.png": [16,8,64,{"us":[1083968,25216]}], +"textures/segment2/font_graphics.06280.ia4.png": [16,8,64,{"us":[1083968,25216],"cn":[947456,88704]}], "textures/segment2/font_graphics.06290.ia1.png": [16,8,16,{"eu":[909712,25232]}], "textures/segment2/font_graphics.062A0.ia1.png": [16,8,16,{"eu":[909712,25248]}], "textures/segment2/font_graphics.062B0.ia1.png": [16,8,16,{"eu":[909712,25264]}], "textures/segment2/font_graphics.062C0.ia1.png": [16,8,16,{"eu":[909712,25280]}], -"textures/segment2/font_graphics.062C0.ia4.png": [16,8,64,{"us":[1083968,25280]}], +"textures/segment2/font_graphics.062C0.ia4.png": [16,8,64,{"us":[1083968,25280],"cn":[947456,88768]}], "textures/segment2/font_graphics.062D0.ia1.png": [16,8,16,{"eu":[909712,25296]}], "textures/segment2/font_graphics.062E0.ia1.png": [16,8,16,{"eu":[909712,25312]}], "textures/segment2/font_graphics.062F0.ia1.png": [16,8,16,{"eu":[909712,25328]}], "textures/segment2/font_graphics.06300.ia1.png": [16,8,16,{"eu":[909712,25344]}], -"textures/segment2/font_graphics.06300.ia4.png": [16,8,64,{"us":[1083968,25344]}], +"textures/segment2/font_graphics.06300.ia4.png": [16,8,64,{"us":[1083968,25344],"cn":[947456,88832]}], "textures/segment2/font_graphics.06310.ia1.png": [16,8,16,{"eu":[909712,25360]}], "textures/segment2/font_graphics.06320.ia1.png": [16,8,16,{"eu":[909712,25376]}], "textures/segment2/font_graphics.06330.ia1.png": [16,8,16,{"eu":[909712,25392]}], "textures/segment2/font_graphics.06340.ia1.png": [16,8,16,{"eu":[909712,25408]}], -"textures/segment2/font_graphics.06340.ia4.png": [16,8,64,{"us":[1083968,25408]}], +"textures/segment2/font_graphics.06340.ia4.png": [16,8,64,{"us":[1083968,25408],"cn":[947456,88896]}], "textures/segment2/font_graphics.06350.ia1.png": [16,8,16,{"eu":[909712,25424]}], "textures/segment2/font_graphics.06360.ia1.png": [16,8,16,{"eu":[909712,25440]}], "textures/segment2/font_graphics.06370.ia1.png": [16,8,16,{"eu":[909712,25456]}], "textures/segment2/font_graphics.06380.ia1.png": [16,8,16,{"eu":[909712,25472]}], -"textures/segment2/font_graphics.06380.ia4.png": [16,8,64,{"us":[1083968,25472]}], +"textures/segment2/font_graphics.06380.ia4.png": [16,8,64,{"us":[1083968,25472],"cn":[947456,88960]}], "textures/segment2/font_graphics.06390.ia1.png": [16,8,16,{"eu":[909712,25488]}], "textures/segment2/font_graphics.063A0.ia1.png": [16,8,16,{"eu":[909712,25504]}], "textures/segment2/font_graphics.063B0.ia1.png": [16,8,16,{"eu":[909712,25520]}], "textures/segment2/font_graphics.063C0.ia1.png": [16,8,16,{"eu":[909712,25536]}], -"textures/segment2/font_graphics.063C0.ia4.png": [16,8,64,{"us":[1083968,25536]}], +"textures/segment2/font_graphics.063C0.ia4.png": [16,8,64,{"us":[1083968,25536],"cn":[947456,89024]}], "textures/segment2/font_graphics.063D0.ia1.png": [16,8,16,{"eu":[909712,25552]}], "textures/segment2/font_graphics.063E0.ia1.png": [16,8,16,{"eu":[909712,25568]}], "textures/segment2/font_graphics.063F0.ia1.png": [16,8,16,{"eu":[909712,25584]}], "textures/segment2/font_graphics.06400.ia1.png": [16,8,16,{"eu":[909712,25600]}], -"textures/segment2/font_graphics.06400.ia4.png": [16,8,64,{"us":[1083968,25600]}], -"textures/segment2/font_graphics.06410.ia1.png": [16,8,16,{"jp":[1599504,83574],"us":[1606720,83574],"eu":[909712,25616],"sh":[1455200,83574]}], -"textures/segment2/font_graphics.06420.ia1.png": [16,8,16,{"jp":[1844608,133979],"us":[1851952,133979],"eu":[909712,25632],"sh":[1700432,133979]}], +"textures/segment2/font_graphics.06400.ia4.png": [16,8,64,{"us":[1083968,25600],"cn":[947456,89088]}], +"textures/segment2/font_graphics.06410.ia1.png": [16,8,16,{"jp":[1599504,83574],"us":[1606720,83574],"eu":[909712,25616],"sh":[1455200,83574],"cn":[1522032,83574]}], +"textures/segment2/font_graphics.06420.ia1.png": [16,8,16,{"jp":[1844608,133979],"us":[1851952,133979],"eu":[909712,25632],"sh":[1700432,133979],"cn":[1767264,133979]}], "textures/segment2/font_graphics.06430.ia1.png": [16,8,16,{"eu":[909712,25648]}], "textures/segment2/font_graphics.06440.ia1.png": [16,8,16,{"eu":[909712,25664]}], -"textures/segment2/font_graphics.06440.ia4.png": [16,8,64,{"us":[1083968,25664]}], +"textures/segment2/font_graphics.06440.ia4.png": [16,8,64,{"us":[1083968,25664],"cn":[947456,89152]}], "textures/segment2/font_graphics.06450.ia1.png": [16,8,16,{"eu":[909712,25680]}], "textures/segment2/font_graphics.06460.ia1.png": [16,8,16,{"eu":[909712,25696]}], "textures/segment2/font_graphics.06470.ia1.png": [16,8,16,{"eu":[909712,25712]}], "textures/segment2/font_graphics.06480.ia1.png": [16,8,16,{"eu":[909712,25728]}], -"textures/segment2/font_graphics.06480.ia4.png": [16,8,64,{"us":[1083968,25728]}], +"textures/segment2/font_graphics.06480.ia4.png": [16,8,64,{"us":[1083968,25728],"cn":[947456,89216]}], "textures/segment2/font_graphics.06490.ia1.png": [16,8,16,{"eu":[909712,25744]}], "textures/segment2/font_graphics.064A0.ia1.png": [16,8,16,{"eu":[909712,25760]}], "textures/segment2/font_graphics.064B0.ia1.png": [16,8,16,{"eu":[909712,25776]}], "textures/segment2/font_graphics.064C0.ia1.png": [16,8,16,{"eu":[909712,25792]}], -"textures/segment2/font_graphics.064C0.ia4.png": [16,8,64,{"us":[1083968,25792]}], +"textures/segment2/font_graphics.064C0.ia4.png": [16,8,64,{"us":[1083968,25792],"cn":[947456,89280]}], "textures/segment2/font_graphics.064D0.ia1.png": [16,8,16,{"eu":[909712,25808]}], "textures/segment2/font_graphics.064E0.ia1.png": [16,8,16,{"eu":[909712,25824]}], "textures/segment2/font_graphics.064F0.ia1.png": [16,8,16,{"eu":[909712,25840]}], "textures/segment2/font_graphics.06500.ia1.png": [16,8,16,{"eu":[909712,25856]}], -"textures/segment2/font_graphics.06500.ia4.png": [16,8,64,{"us":[1083968,25856]}], +"textures/segment2/font_graphics.06500.ia4.png": [16,8,64,{"us":[1083968,25856],"cn":[947456,89344]}], "textures/segment2/font_graphics.06510.ia1.png": [16,8,16,{"eu":[909712,25872]}], "textures/segment2/font_graphics.06520.ia1.png": [16,8,16,{"eu":[909712,25888]}], "textures/segment2/font_graphics.06530.ia1.png": [16,8,16,{"eu":[909712,25904]}], -"textures/segment2/font_graphics.06540.ia4.png": [16,8,64,{"us":[1083968,25920]}], -"textures/segment2/font_graphics.06580.ia4.png": [16,8,64,{"us":[1083968,25984]}], -"textures/segment2/font_graphics.065C0.ia4.png": [16,8,64,{"us":[1083968,26048]}], -"textures/segment2/font_graphics.06600.ia4.png": [16,8,64,{"us":[1083968,26112]}], -"textures/segment2/font_graphics.06640.ia4.png": [16,8,64,{"us":[1083968,26176]}], -"textures/segment2/font_graphics.06680.ia4.png": [16,8,64,{"us":[1083968,26240]}], -"textures/segment2/font_graphics.066C0.ia4.png": [16,8,64,{"us":[1083968,26304]}], -"textures/segment2/font_graphics.06700.ia4.png": [16,8,64,{"us":[1083968,26368]}], -"textures/segment2/font_graphics.06740.ia4.png": [16,8,64,{"us":[1083968,26432]}], -"textures/segment2/font_graphics.06780.ia4.png": [16,8,64,{"us":[1083968,26496]}], -"textures/segment2/font_graphics.067C0.ia4.png": [16,8,64,{"us":[1083968,26560]}], -"textures/segment2/font_graphics.06800.ia4.png": [16,8,64,{"us":[1083968,26624]}], -"textures/segment2/font_graphics.06840.ia4.png": [16,8,64,{"us":[1083968,26688]}], -"textures/segment2/font_graphics.06880.ia4.png": [16,8,64,{"us":[1083968,26752]}], -"textures/segment2/font_graphics.068C0.ia4.png": [16,8,64,{"us":[1083968,26816]}], -"textures/segment2/font_graphics.06900.ia4.png": [16,8,64,{"us":[1083968,26880]}], -"textures/segment2/font_graphics.06940.ia4.png": [16,8,64,{"us":[1083968,26944]}], -"textures/segment2/font_graphics.06980.ia4.png": [16,8,64,{"us":[1083968,27008]}], -"textures/segment2/font_graphics.069C0.ia4.png": [16,8,64,{"us":[1083968,27072]}], -"textures/segment2/font_graphics.06A00.ia4.png": [16,8,64,{"us":[1083968,27136]}], -"textures/segment2/font_graphics.06A40.ia4.png": [16,8,64,{"us":[1083968,27200]}], -"textures/segment2/font_graphics.06A80.ia4.png": [16,8,64,{"us":[1083968,27264]}], -"textures/segment2/font_graphics.06AC0.ia4.png": [16,8,64,{"us":[1083968,27328]}], -"textures/segment2/font_graphics.06B00.ia4.png": [16,8,64,{"us":[1083968,27392]}], -"textures/segment2/font_graphics.06B40.ia4.png": [16,8,64,{"us":[1083968,27456]}], -"textures/segment2/font_graphics.06B80.ia4.png": [16,8,64,{"us":[1083968,27520]}], -"textures/segment2/font_graphics.06BC0.ia4.png": [16,8,64,{"us":[1083968,27584]}], -"textures/segment2/font_graphics.06C00.ia4.png": [16,8,64,{"us":[1083968,27648]}], -"textures/segment2/font_graphics.06C40.ia4.png": [16,8,64,{"us":[1083968,27712]}], -"textures/segment2/font_graphics.06C80.ia4.png": [16,8,64,{"us":[1083968,27776]}], -"textures/segment2/font_graphics.06CC0.ia4.png": [16,8,64,{"us":[1083968,27840]}], -"textures/segment2/font_graphics.06D00.ia4.png": [16,8,64,{"us":[1083968,27904]}], -"textures/segment2/font_graphics.06D40.ia4.png": [16,8,64,{"us":[1083968,27968]}], -"textures/segment2/font_graphics.06D80.ia4.png": [16,8,64,{"us":[1083968,28032]}], -"textures/segment2/font_graphics.06DC0.ia4.png": [16,8,64,{"us":[1083968,28096]}], -"textures/segment2/font_graphics.06E00.ia4.png": [16,8,64,{"us":[1083968,28160]}], -"textures/segment2/font_graphics.06E40.ia4.png": [16,8,64,{"us":[1083968,28224]}], -"textures/segment2/font_graphics.06E80.ia4.png": [16,8,64,{"us":[1083968,28288]}], -"textures/segment2/font_graphics.06EC0.ia4.png": [16,8,64,{"us":[1083968,28352]}], -"textures/segment2/font_graphics.06F00.ia4.png": [16,8,64,{"us":[1083968,28416]}], -"textures/segment2/font_graphics.06F40.ia4.png": [16,8,64,{"us":[1083968,28480]}], -"textures/segment2/font_graphics.06F80.ia4.png": [16,8,64,{"us":[1083968,28544]}], -"textures/segment2/font_graphics.06FC0.ia4.png": [16,8,64,{"us":[1083968,28608]}], -"textures/segment2/segment2.00000.rgba16.png": [16,16,512,{"jp":[1078992,0],"us":[1083968,0],"eu":[909712,0],"sh":[934640,0]}], -"textures/segment2/segment2.00200.rgba16.png": [16,16,512,{"jp":[1078992,512],"us":[1083968,512],"eu":[909712,512],"sh":[934640,512]}], -"textures/segment2/segment2.00400.rgba16.png": [16,16,512,{"jp":[1078992,1024],"us":[1083968,1024],"eu":[909712,1024],"sh":[934640,1024]}], -"textures/segment2/segment2.00600.rgba16.png": [16,16,512,{"jp":[1078992,1536],"us":[1083968,1536],"eu":[909712,1536],"sh":[934640,1536]}], -"textures/segment2/segment2.00800.rgba16.png": [16,16,512,{"jp":[1078992,2048],"us":[1083968,2048],"eu":[909712,2048],"sh":[934640,2048]}], -"textures/segment2/segment2.00A00.rgba16.png": [16,16,512,{"jp":[1078992,2560],"us":[1083968,2560],"eu":[909712,2560],"sh":[934640,2560]}], -"textures/segment2/segment2.00C00.rgba16.png": [16,16,512,{"jp":[1078992,3072],"us":[1083968,3072],"eu":[909712,3072],"sh":[934640,3072]}], -"textures/segment2/segment2.00E00.rgba16.png": [16,16,512,{"jp":[1078992,3584],"us":[1083968,3584],"eu":[909712,3584],"sh":[934640,3584]}], -"textures/segment2/segment2.01000.rgba16.png": [16,16,512,{"jp":[1078992,4096],"us":[1083968,4096],"eu":[909712,4096],"sh":[934640,4096]}], -"textures/segment2/segment2.01200.rgba16.png": [16,16,512,{"jp":[1078992,4608],"us":[1083968,4608],"eu":[909712,4608],"sh":[934640,4608]}], -"textures/segment2/segment2.01400.rgba16.png": [16,16,512,{"jp":[1078992,5120],"us":[1083968,5120],"eu":[909712,5120],"sh":[934640,5120]}], -"textures/segment2/segment2.01600.rgba16.png": [16,16,512,{"jp":[1078992,5632],"us":[1083968,5632],"eu":[909712,5632],"sh":[934640,5632]}], -"textures/segment2/segment2.01800.rgba16.png": [16,16,512,{"jp":[1078992,6144],"us":[1083968,6144],"eu":[909712,6144],"sh":[934640,6144]}], -"textures/segment2/segment2.01A00.rgba16.png": [16,16,512,{"jp":[1078992,6656],"us":[1083968,6656],"eu":[909712,6656],"sh":[934640,6656]}], -"textures/segment2/segment2.01C00.rgba16.png": [16,16,512,{"jp":[1078992,7168],"us":[1083968,7168],"eu":[909712,7168],"sh":[934640,7168]}], -"textures/segment2/segment2.01E00.rgba16.png": [16,16,512,{"jp":[1078992,7680],"us":[1083968,7680],"eu":[909712,7680],"sh":[934640,7680]}], -"textures/segment2/segment2.02000.rgba16.png": [16,16,512,{"jp":[1078992,8192],"us":[1083968,8192],"eu":[909712,8192],"sh":[934640,8192]}], -"textures/segment2/segment2.02200.rgba16.png": [16,16,512,{"jp":[1078992,8704],"us":[1083968,8704],"eu":[909712,8704],"sh":[934640,8704]}], -"textures/segment2/segment2.02400.rgba16.png": [16,16,512,{"jp":[1078992,9216],"us":[1083968,9216],"eu":[909712,9216],"sh":[934640,9216]}], +"textures/segment2/font_graphics.06540.ia4.png": [16,8,64,{"us":[1083968,25920],"cn":[947456,89408]}], +"textures/segment2/font_graphics.06580.ia4.png": [16,8,64,{"us":[1083968,25984],"cn":[947456,89472]}], +"textures/segment2/font_graphics.065C0.ia4.png": [16,8,64,{"us":[1083968,26048],"cn":[947456,89536]}], +"textures/segment2/font_graphics.06600.ia4.png": [16,8,64,{"us":[1083968,26112],"cn":[947456,89600]}], +"textures/segment2/font_graphics.06640.ia4.png": [16,8,64,{"us":[1083968,26176],"cn":[947456,89664]}], +"textures/segment2/font_graphics.06680.ia4.png": [16,8,64,{"us":[1083968,26240],"cn":[947456,89728]}], +"textures/segment2/font_graphics.066C0.ia4.png": [16,8,64,{"us":[1083968,26304],"cn":[947456,89792]}], +"textures/segment2/font_graphics.06700.ia4.png": [16,8,64,{"us":[1083968,26368],"cn":[947456,89856]}], +"textures/segment2/font_graphics.06740.ia4.png": [16,8,64,{"us":[1083968,26432],"cn":[947456,89920]}], +"textures/segment2/font_graphics.06780.ia4.png": [16,8,64,{"us":[1083968,26496],"cn":[947456,89984]}], +"textures/segment2/font_graphics.067C0.ia4.png": [16,8,64,{"us":[1083968,26560],"cn":[947456,90048]}], +"textures/segment2/font_graphics.06800.ia4.png": [16,8,64,{"us":[1083968,26624],"cn":[947456,90112]}], +"textures/segment2/font_graphics.06840.ia4.png": [16,8,64,{"us":[1083968,26688],"cn":[947456,90176]}], +"textures/segment2/font_graphics.06880.ia4.png": [16,8,64,{"us":[1083968,26752],"cn":[947456,90240]}], +"textures/segment2/font_graphics.068C0.ia4.png": [16,8,64,{"us":[1083968,26816],"cn":[947456,90304]}], +"textures/segment2/font_graphics.06900.ia4.png": [16,8,64,{"us":[1083968,26880],"cn":[947456,90368]}], +"textures/segment2/font_graphics.06940.ia4.png": [16,8,64,{"us":[1083968,26944],"cn":[947456,90432]}], +"textures/segment2/font_graphics.06980.ia4.png": [16,8,64,{"us":[1083968,27008],"cn":[947456,90496]}], +"textures/segment2/font_graphics.069C0.ia4.png": [16,8,64,{"us":[1083968,27072],"cn":[947456,90560]}], +"textures/segment2/font_graphics.06A00.ia4.png": [16,8,64,{"us":[1083968,27136],"cn":[947456,90624]}], +"textures/segment2/font_graphics.06A40.ia4.png": [16,8,64,{"us":[1083968,27200],"cn":[947456,90688]}], +"textures/segment2/font_graphics.06A80.ia4.png": [16,8,64,{"us":[1083968,27264],"cn":[947456,90752]}], +"textures/segment2/font_graphics.06AC0.ia4.png": [16,8,64,{"us":[1083968,27328],"cn":[947456,90816]}], +"textures/segment2/font_graphics.06B00.ia4.png": [16,8,64,{"us":[1083968,27392],"cn":[947456,90880]}], +"textures/segment2/font_graphics.06B40.ia4.png": [16,8,64,{"us":[1083968,27456],"cn":[947456,90944]}], +"textures/segment2/font_graphics.06B80.ia4.png": [16,8,64,{"us":[1083968,27520],"cn":[947456,91008]}], +"textures/segment2/font_graphics.06BC0.ia4.png": [16,8,64,{"us":[1083968,27584],"cn":[947456,91072]}], +"textures/segment2/font_graphics.06C00.ia4.png": [16,8,64,{"us":[1083968,27648],"cn":[947456,91136]}], +"textures/segment2/font_graphics.06C40.ia4.png": [16,8,64,{"us":[1083968,27712],"cn":[947456,91200]}], +"textures/segment2/font_graphics.06C80.ia4.png": [16,8,64,{"us":[1083968,27776],"cn":[947456,91264]}], +"textures/segment2/font_graphics.06CC0.ia4.png": [16,8,64,{"us":[1083968,27840],"cn":[947456,91328]}], +"textures/segment2/font_graphics.06D00.ia4.png": [16,8,64,{"us":[1083968,27904],"cn":[947456,91392]}], +"textures/segment2/font_graphics.06D40.ia4.png": [16,8,64,{"us":[1083968,27968],"cn":[947456,91456]}], +"textures/segment2/font_graphics.06D80.ia4.png": [16,8,64,{"us":[1083968,28032],"cn":[947456,91520]}], +"textures/segment2/font_graphics.06DC0.ia4.png": [16,8,64,{"us":[1083968,28096],"cn":[947456,91584]}], +"textures/segment2/font_graphics.06E00.ia4.png": [16,8,64,{"us":[1083968,28160],"cn":[947456,91648]}], +"textures/segment2/font_graphics.06E40.ia4.png": [16,8,64,{"us":[1083968,28224],"cn":[947456,91712]}], +"textures/segment2/font_graphics.06E80.ia4.png": [16,8,64,{"us":[1083968,28288],"cn":[947456,91776]}], +"textures/segment2/font_graphics.06EC0.ia4.png": [16,8,64,{"us":[1083968,28352],"cn":[947456,91840]}], +"textures/segment2/font_graphics.06F00.ia4.png": [16,8,64,{"us":[1083968,28416],"cn":[947456,91904]}], +"textures/segment2/font_graphics.06F40.ia4.png": [16,8,64,{"us":[1083968,28480],"cn":[947456,91968]}], +"textures/segment2/font_graphics.06F80.ia4.png": [16,8,64,{"us":[1083968,28544],"cn":[947456,92032]}], +"textures/segment2/font_graphics.06FC0.ia4.png": [16,8,64,{"us":[1083968,28608],"cn":[947456,92096]}], +"textures/segment2/segment2.00000.rgba16.png": [16,16,512,{"jp":[1078992,0],"us":[1083968,0],"eu":[909712,0],"sh":[934640,0],"cn":[947456,0]}], +"textures/segment2/segment2.00200.rgba16.png": [16,16,512,{"jp":[1078992,512],"us":[1083968,512],"eu":[909712,512],"sh":[934640,512],"cn":[947456,512]}], +"textures/segment2/segment2.00400.rgba16.png": [16,16,512,{"jp":[1078992,1024],"us":[1083968,1024],"eu":[909712,1024],"sh":[934640,1024],"cn":[947456,1024]}], +"textures/segment2/segment2.00600.rgba16.png": [16,16,512,{"jp":[1078992,1536],"us":[1083968,1536],"eu":[909712,1536],"sh":[934640,1536],"cn":[947456,1536]}], +"textures/segment2/segment2.00800.rgba16.png": [16,16,512,{"jp":[1078992,2048],"us":[1083968,2048],"eu":[909712,2048],"sh":[934640,2048],"cn":[947456,2048]}], +"textures/segment2/segment2.00A00.rgba16.png": [16,16,512,{"jp":[1078992,2560],"us":[1083968,2560],"eu":[909712,2560],"sh":[934640,2560],"cn":[947456,2560]}], +"textures/segment2/segment2.00C00.rgba16.png": [16,16,512,{"jp":[1078992,3072],"us":[1083968,3072],"eu":[909712,3072],"sh":[934640,3072],"cn":[947456,3072]}], +"textures/segment2/segment2.00E00.rgba16.png": [16,16,512,{"jp":[1078992,3584],"us":[1083968,3584],"eu":[909712,3584],"sh":[934640,3584],"cn":[947456,3584]}], +"textures/segment2/segment2.01000.rgba16.png": [16,16,512,{"jp":[1078992,4096],"us":[1083968,4096],"eu":[909712,4096],"sh":[934640,4096],"cn":[947456,4096]}], +"textures/segment2/segment2.01200.rgba16.png": [16,16,512,{"jp":[1078992,4608],"us":[1083968,4608],"eu":[909712,4608],"sh":[934640,4608],"cn":[947456,4608]}], +"textures/segment2/segment2.01400.rgba16.png": [16,16,512,{"jp":[1078992,5120],"us":[1083968,5120],"eu":[909712,5120],"sh":[934640,5120],"cn":[947456,5120]}], +"textures/segment2/segment2.01600.rgba16.png": [16,16,512,{"jp":[1078992,5632],"us":[1083968,5632],"eu":[909712,5632],"sh":[934640,5632],"cn":[947456,5632]}], +"textures/segment2/segment2.01800.rgba16.png": [16,16,512,{"jp":[1078992,6144],"us":[1083968,6144],"eu":[909712,6144],"sh":[934640,6144],"cn":[947456,6144]}], +"textures/segment2/segment2.01A00.rgba16.png": [16,16,512,{"jp":[1078992,6656],"us":[1083968,6656],"eu":[909712,6656],"sh":[934640,6656],"cn":[947456,6656]}], +"textures/segment2/segment2.01C00.rgba16.png": [16,16,512,{"jp":[1078992,7168],"us":[1083968,7168],"eu":[909712,7168],"sh":[934640,7168],"cn":[947456,7168]}], +"textures/segment2/segment2.01E00.rgba16.png": [16,16,512,{"jp":[1078992,7680],"us":[1083968,7680],"eu":[909712,7680],"sh":[934640,7680],"cn":[947456,7680]}], +"textures/segment2/segment2.02000.rgba16.png": [16,16,512,{"jp":[1078992,8192],"us":[1083968,8192],"eu":[909712,8192],"sh":[934640,8192],"cn":[947456,8192]}], +"textures/segment2/segment2.02200.rgba16.png": [16,16,512,{"jp":[1078992,8704],"us":[1083968,8704],"eu":[909712,8704],"sh":[934640,8704],"cn":[947456,8704]}], +"textures/segment2/segment2.02400.rgba16.png": [16,16,512,{"jp":[1078992,9216],"us":[1083968,9216],"eu":[909712,9216],"sh":[934640,9216],"cn":[947456,9216]}], "textures/segment2/segment2.02600.rgba16.png": [16,16,512,{"jp":[1078992,9728],"sh":[934640,9728]}], -"textures/segment2/segment2.02800.rgba16.png": [16,16,512,{"jp":[1078992,10240],"us":[1083968,9728],"eu":[909712,9728],"sh":[934640,10240]}], -"textures/segment2/segment2.02A00.rgba16.png": [16,16,512,{"jp":[1078992,10752],"us":[1083968,10240],"eu":[909712,10240],"sh":[934640,10752]}], -"textures/segment2/segment2.02C00.rgba16.png": [16,16,512,{"jp":[1078992,11264],"us":[1083968,10752],"eu":[909712,10752],"sh":[934640,11264]}], -"textures/segment2/segment2.02E00.rgba16.png": [16,16,512,{"jp":[1078992,11776],"us":[1083968,11264],"eu":[909712,11264],"sh":[934640,11776]}], -"textures/segment2/segment2.03000.rgba16.png": [16,16,512,{"jp":[1078992,12288],"us":[1083968,11776],"eu":[909712,11776],"sh":[934640,12288]}], -"textures/segment2/segment2.03200.rgba16.png": [16,16,512,{"jp":[1078992,12800],"us":[1083968,12288],"eu":[909712,12288],"sh":[934640,12800]}], +"textures/segment2/segment2.02800.rgba16.png": [16,16,512,{"jp":[1078992,10240],"us":[1083968,9728],"eu":[909712,9728],"sh":[934640,10240],"cn":[947456,9728]}], +"textures/segment2/segment2.02A00.rgba16.png": [16,16,512,{"jp":[1078992,10752],"us":[1083968,10240],"eu":[909712,10240],"sh":[934640,10752],"cn":[947456,10240]}], +"textures/segment2/segment2.02C00.rgba16.png": [16,16,512,{"jp":[1078992,11264],"us":[1083968,10752],"eu":[909712,10752],"sh":[934640,11264],"cn":[947456,10752]}], +"textures/segment2/segment2.02E00.rgba16.png": [16,16,512,{"jp":[1078992,11776],"us":[1083968,11264],"eu":[909712,11264],"sh":[934640,11776],"cn":[947456,11264]}], +"textures/segment2/segment2.03000.rgba16.png": [16,16,512,{"jp":[1078992,12288],"us":[1083968,11776],"eu":[909712,11776],"sh":[934640,12288],"cn":[947456,11776]}], +"textures/segment2/segment2.03200.rgba16.png": [16,16,512,{"jp":[1078992,12800],"us":[1083968,12288],"eu":[909712,12288],"sh":[934640,12800],"cn":[947456,12288]}], "textures/segment2/segment2.03400.rgba16.png": [16,16,512,{"jp":[1078992,13312],"sh":[934640,13312]}], -"textures/segment2/segment2.03600.rgba16.png": [16,16,512,{"jp":[1078992,13824],"us":[1083968,12800],"eu":[909712,12800],"sh":[934640,13824]}], -"textures/segment2/segment2.03800.rgba16.png": [16,16,512,{"jp":[1078992,14336],"us":[1083968,13312],"eu":[909712,13312],"sh":[934640,14336]}], -"textures/segment2/segment2.03A00.rgba16.png": [16,16,512,{"jp":[1078992,14848],"us":[1083968,13824],"eu":[909712,13824],"sh":[934640,14848]}], -"textures/segment2/segment2.03C00.rgba16.png": [16,16,512,{"jp":[1078992,15360],"us":[1083968,14336],"eu":[909712,14336],"sh":[934640,15360]}], +"textures/segment2/segment2.03600.rgba16.png": [16,16,512,{"jp":[1078992,13824],"us":[1083968,12800],"eu":[909712,12800],"sh":[934640,13824],"cn":[947456,12800]}], +"textures/segment2/segment2.03800.rgba16.png": [16,16,512,{"jp":[1078992,14336],"us":[1083968,13312],"eu":[909712,13312],"sh":[934640,14336],"cn":[947456,13312]}], +"textures/segment2/segment2.03A00.rgba16.png": [16,16,512,{"jp":[1078992,14848],"us":[1083968,13824],"eu":[909712,13824],"sh":[934640,14848],"cn":[947456,13824]}], +"textures/segment2/segment2.03C00.rgba16.png": [16,16,512,{"jp":[1078992,15360],"us":[1083968,14336],"eu":[909712,14336],"sh":[934640,15360],"cn":[947456,14336]}], "textures/segment2/segment2.03E00.rgba16.png": [16,16,512,{"jp":[1078992,15872],"eu":[909712,14848],"sh":[934640,15872]}], -"textures/segment2/segment2.04000.rgba16.png": [16,16,512,{"jp":[1078992,16384],"us":[1083968,14848],"eu":[909712,15360],"sh":[934640,16384]}], +"textures/segment2/segment2.04000.rgba16.png": [16,16,512,{"jp":[1078992,16384],"us":[1083968,14848],"eu":[909712,15360],"sh":[934640,16384],"cn":[947456,14848]}], "textures/segment2/segment2.04200.rgba16.png": [16,16,512,{"jp":[1078992,16896],"sh":[934640,16896]}], -"textures/segment2/segment2.04400.rgba16.png": [16,16,512,{"jp":[1078992,17408],"us":[1083968,15360],"eu":[909712,15872],"sh":[934640,17408]}], +"textures/segment2/segment2.04400.rgba16.png": [16,16,512,{"jp":[1078992,17408],"us":[1083968,15360],"eu":[909712,15872],"sh":[934640,17408],"cn":[947456,15360]}], "textures/segment2/segment2.04600.rgba16.png": [16,16,512,{"jp":[1078992,17920],"eu":[909712,16384],"sh":[934640,17920]}], -"textures/segment2/segment2.04800.rgba16.png": [16,16,512,{"jp":[1078992,18432],"us":[1083968,15872],"eu":[909712,16896],"sh":[934640,18432]}], -"textures/segment2/segment2.04A00.rgba16.png": [16,16,512,{"jp":[1078992,18944],"us":[1083968,16384],"eu":[909712,17408],"sh":[934640,18944]}], +"textures/segment2/segment2.04800.rgba16.png": [16,16,512,{"jp":[1078992,18432],"us":[1083968,15872],"eu":[909712,16896],"sh":[934640,18432],"cn":[947456,15872]}], +"textures/segment2/segment2.04A00.rgba16.png": [16,16,512,{"jp":[1078992,18944],"us":[1083968,16384],"eu":[909712,17408],"sh":[934640,18944],"cn":[947456,16384]}], "textures/segment2/segment2.04C00.rgba16.png": [16,16,512,{"jp":[1078992,19456],"sh":[934640,19456]}], "textures/segment2/segment2.04E00.rgba16.png": [16,16,512,{"jp":[1078992,19968],"sh":[934640,19968]}], -"textures/segment2/segment2.05000.rgba16.png": [16,16,512,{"jp":[1078992,20480],"us":[2778544,41424],"eu":[2647072,41424],"sh":[934640,20480]}], +"textures/segment2/segment2.05000.rgba16.png": [16,16,512,{"jp":[1078992,20480],"us":[2778544,41424],"eu":[2647072,41424],"sh":[934640,20480],"cn":[2700128,41424]}], "textures/segment2/segment2.05200.rgba16.png": [16,16,512,{"jp":[1078992,20992],"sh":[934640,20992]}], "textures/segment2/segment2.05400.rgba16.png": [16,16,512,{"jp":[1078992,21504],"sh":[934640,21504]}], -"textures/segment2/segment2.05600.rgba16.png": [16,16,512,{"jp":[1078992,22016],"us":[1083968,16896],"eu":[909712,18432],"sh":[934640,22016]}], -"textures/segment2/segment2.05800.rgba16.png": [16,16,512,{"jp":[1078992,22528],"us":[1083968,17408],"eu":[909712,18944],"sh":[934640,22528]}], -"textures/segment2/segment2.05A00.rgba16.png": [16,16,512,{"jp":[1078992,23040],"us":[1083968,17920],"eu":[909712,19456],"sh":[934640,23040]}], -"textures/segment2/segment2.05C00.rgba16.png": [16,16,512,{"jp":[1078992,23552],"us":[1083968,18432],"eu":[909712,19968],"sh":[934640,23552]}], +"textures/segment2/segment2.05600.rgba16.png": [16,16,512,{"jp":[1078992,22016],"us":[1083968,16896],"eu":[909712,18432],"sh":[934640,22016],"cn":[947456,16896]}], +"textures/segment2/segment2.05800.rgba16.png": [16,16,512,{"jp":[1078992,22528],"us":[1083968,17408],"eu":[909712,18944],"sh":[934640,22528],"cn":[947456,17408]}], +"textures/segment2/segment2.05A00.rgba16.png": [16,16,512,{"jp":[1078992,23040],"us":[1083968,17920],"eu":[909712,19456],"sh":[934640,23040],"cn":[947456,17920]}], +"textures/segment2/segment2.05C00.rgba16.png": [16,16,512,{"jp":[1078992,23552],"us":[1083968,18432],"eu":[909712,19968],"sh":[934640,23552],"cn":[947456,18432]}], "textures/segment2/segment2.05E00.rgba16.png": [16,16,512,{"jp":[1078992,24064],"sh":[934640,24064]}], "textures/segment2/segment2.06000.rgba16.png": [16,16,512,{"jp":[1078992,24576],"sh":[934640,24576]}], -"textures/segment2/segment2.06200.rgba16.png": [8,8,128,{"jp":[1078992,25088],"us":[1083968,18944],"eu":[909712,20480],"sh":[934640,25088]}], -"textures/segment2/segment2.06280.rgba16.png": [8,8,128,{"jp":[1078992,25216],"us":[1083968,19072],"eu":[909712,20608],"sh":[934640,25216]}], -"textures/segment2/segment2.06300.rgba16.png": [8,8,128,{"jp":[1078992,25344],"us":[1083968,19200],"eu":[909712,20736],"sh":[934640,25344]}], -"textures/segment2/segment2.06380.rgba16.png": [8,8,128,{"jp":[1078992,25472],"us":[1083968,19328],"eu":[909712,20864],"sh":[934640,25472]}], -"textures/segment2/segment2.06400.rgba16.png": [8,8,128,{"jp":[1078992,25600],"us":[1083968,19456],"eu":[909712,20992],"sh":[934640,25600]}], -"textures/segment2/segment2.06480.rgba16.png": [8,8,128,{"jp":[1078992,25728],"us":[1083968,19584],"eu":[909712,21120],"sh":[934640,25728]}], -"textures/segment2/segment2.06500.rgba16.png": [8,8,128,{"jp":[1078992,25856],"us":[1083968,19712],"eu":[909712,21248],"sh":[934640,25856]}], -"textures/segment2/segment2.06580.rgba16.png": [8,8,128,{"jp":[1078992,25984],"us":[1083968,19840],"eu":[909712,21376],"sh":[934640,25984]}], -"textures/segment2/segment2.06600.rgba16.png": [8,8,128,{"jp":[1078992,26112],"us":[1083968,19968],"eu":[909712,21504],"sh":[934640,26112]}], -"textures/segment2/segment2.06680.rgba16.png": [8,8,128,{"jp":[1078992,26240],"us":[1083968,20096],"eu":[909712,21632],"sh":[934640,26240]}], -"textures/segment2/segment2.06700.rgba16.png": [8,8,128,{"jp":[1078992,26368],"us":[1083968,20224],"eu":[909712,21760],"sh":[934640,26368]}], -"textures/segment2/segment2.06780.rgba16.png": [8,8,128,{"jp":[1078992,26496],"us":[1083968,20352],"eu":[909712,21888],"sh":[934640,26496]}], -"textures/segment2/segment2.06800.rgba16.png": [8,8,128,{"jp":[1078992,26624],"us":[1083968,20480],"eu":[909712,22016],"sh":[934640,26624]}], -"textures/segment2/segment2.06880.rgba16.png": [8,8,128,{"jp":[1078992,26752],"us":[1083968,20608],"eu":[909712,22144],"sh":[934640,26752]}], -"textures/segment2/segment2.06900.rgba16.png": [8,8,128,{"jp":[1078992,26880],"us":[1083968,20736],"eu":[909712,22272],"sh":[934640,26880]}], -"textures/segment2/segment2.06980.rgba16.png": [8,8,128,{"jp":[1078992,27008],"us":[1083968,20864],"eu":[909712,22400],"sh":[934640,27008]}], -"textures/segment2/segment2.06A00.rgba16.png": [8,8,128,{"jp":[1078992,27136],"us":[1083968,20992],"eu":[909712,22528],"sh":[934640,27136]}], -"textures/segment2/segment2.06A80.rgba16.png": [8,8,128,{"jp":[1078992,27264],"us":[1083968,21120],"eu":[909712,22656],"sh":[934640,27264]}], -"textures/segment2/segment2.06B00.rgba16.png": [8,8,128,{"jp":[1078992,27392],"us":[1083968,21248],"eu":[909712,22784],"sh":[934640,27392]}], -"textures/segment2/segment2.06B80.rgba16.png": [8,8,128,{"jp":[1078992,27520],"us":[1083968,21376],"eu":[909712,22912],"sh":[934640,27520]}], -"textures/segment2/segment2.06C00.rgba16.png": [8,8,128,{"jp":[1078992,27648],"us":[1083968,21504],"eu":[909712,23040],"sh":[934640,27648]}], -"textures/segment2/segment2.06C80.rgba16.png": [8,8,128,{"jp":[1078992,27776],"us":[1083968,21632],"eu":[909712,23168],"sh":[934640,27776]}], -"textures/segment2/segment2.06D00.rgba16.png": [8,8,128,{"jp":[1078992,27904],"us":[1083968,21760],"eu":[909712,23296],"sh":[934640,27904]}], -"textures/segment2/segment2.06D80.rgba16.png": [8,8,128,{"jp":[1078992,28032],"us":[1083968,21888],"eu":[909712,23424],"sh":[934640,28032]}], -"textures/segment2/segment2.06E00.rgba16.png": [8,8,128,{"jp":[1078992,28160],"us":[1083968,22016],"eu":[909712,23552],"sh":[934640,28160]}], -"textures/segment2/segment2.06E80.rgba16.png": [8,8,128,{"jp":[1078992,28288],"us":[1083968,22144],"eu":[909712,23680],"sh":[934640,28288]}], -"textures/segment2/segment2.06F00.rgba16.png": [8,8,128,{"jp":[1078992,28416],"us":[1083968,22272],"eu":[909712,23808],"sh":[934640,28416]}], -"textures/segment2/segment2.06F80.rgba16.png": [8,8,128,{"jp":[1078992,28544],"us":[1083968,22400],"eu":[909712,23936],"sh":[934640,28544]}], -"textures/segment2/segment2.07000.rgba16.png": [8,8,128,{"jp":[1078992,28672],"us":[1083968,22528],"eu":[909712,24064],"sh":[934640,28672]}], -"textures/segment2/segment2.07080.rgba16.png": [8,8,128,{"jp":[1078992,28800],"us":[1083968,22656],"eu":[909712,24192],"sh":[934640,28800]}], +"textures/segment2/segment2.06200.rgba16.png": [8,8,128,{"jp":[1078992,25088],"us":[1083968,18944],"eu":[909712,20480],"sh":[934640,25088],"cn":[947456,82432]}], +"textures/segment2/segment2.06280.rgba16.png": [8,8,128,{"jp":[1078992,25216],"us":[1083968,19072],"eu":[909712,20608],"sh":[934640,25216],"cn":[947456,82560]}], +"textures/segment2/segment2.06300.rgba16.png": [8,8,128,{"jp":[1078992,25344],"us":[1083968,19200],"eu":[909712,20736],"sh":[934640,25344],"cn":[947456,82688]}], +"textures/segment2/segment2.06380.rgba16.png": [8,8,128,{"jp":[1078992,25472],"us":[1083968,19328],"eu":[909712,20864],"sh":[934640,25472],"cn":[947456,82816]}], +"textures/segment2/segment2.06400.rgba16.png": [8,8,128,{"jp":[1078992,25600],"us":[1083968,19456],"eu":[909712,20992],"sh":[934640,25600],"cn":[947456,82944]}], +"textures/segment2/segment2.06480.rgba16.png": [8,8,128,{"jp":[1078992,25728],"us":[1083968,19584],"eu":[909712,21120],"sh":[934640,25728],"cn":[947456,83072]}], +"textures/segment2/segment2.06500.rgba16.png": [8,8,128,{"jp":[1078992,25856],"us":[1083968,19712],"eu":[909712,21248],"sh":[934640,25856],"cn":[947456,83200]}], +"textures/segment2/segment2.06580.rgba16.png": [8,8,128,{"jp":[1078992,25984],"us":[1083968,19840],"eu":[909712,21376],"sh":[934640,25984],"cn":[947456,83328]}], +"textures/segment2/segment2.06600.rgba16.png": [8,8,128,{"jp":[1078992,26112],"us":[1083968,19968],"eu":[909712,21504],"sh":[934640,26112],"cn":[947456,83456]}], +"textures/segment2/segment2.06680.rgba16.png": [8,8,128,{"jp":[1078992,26240],"us":[1083968,20096],"eu":[909712,21632],"sh":[934640,26240],"cn":[947456,83584]}], +"textures/segment2/segment2.06700.rgba16.png": [8,8,128,{"jp":[1078992,26368],"us":[1083968,20224],"eu":[909712,21760],"sh":[934640,26368],"cn":[947456,83712]}], +"textures/segment2/segment2.06780.rgba16.png": [8,8,128,{"jp":[1078992,26496],"us":[1083968,20352],"eu":[909712,21888],"sh":[934640,26496],"cn":[947456,83840]}], +"textures/segment2/segment2.06800.rgba16.png": [8,8,128,{"jp":[1078992,26624],"us":[1083968,20480],"eu":[909712,22016],"sh":[934640,26624],"cn":[947456,83968]}], +"textures/segment2/segment2.06880.rgba16.png": [8,8,128,{"jp":[1078992,26752],"us":[1083968,20608],"eu":[909712,22144],"sh":[934640,26752],"cn":[947456,84096]}], +"textures/segment2/segment2.06900.rgba16.png": [8,8,128,{"jp":[1078992,26880],"us":[1083968,20736],"eu":[909712,22272],"sh":[934640,26880],"cn":[947456,84224]}], +"textures/segment2/segment2.06980.rgba16.png": [8,8,128,{"jp":[1078992,27008],"us":[1083968,20864],"eu":[909712,22400],"sh":[934640,27008],"cn":[947456,84352]}], +"textures/segment2/segment2.06A00.rgba16.png": [8,8,128,{"jp":[1078992,27136],"us":[1083968,20992],"eu":[909712,22528],"sh":[934640,27136],"cn":[947456,84480]}], +"textures/segment2/segment2.06A80.rgba16.png": [8,8,128,{"jp":[1078992,27264],"us":[1083968,21120],"eu":[909712,22656],"sh":[934640,27264],"cn":[947456,84608]}], +"textures/segment2/segment2.06B00.rgba16.png": [8,8,128,{"jp":[1078992,27392],"us":[1083968,21248],"eu":[909712,22784],"sh":[934640,27392],"cn":[947456,84736]}], +"textures/segment2/segment2.06B80.rgba16.png": [8,8,128,{"jp":[1078992,27520],"us":[1083968,21376],"eu":[909712,22912],"sh":[934640,27520],"cn":[947456,84864]}], +"textures/segment2/segment2.06C00.rgba16.png": [8,8,128,{"jp":[1078992,27648],"us":[1083968,21504],"eu":[909712,23040],"sh":[934640,27648],"cn":[947456,84992]}], +"textures/segment2/segment2.06C80.rgba16.png": [8,8,128,{"jp":[1078992,27776],"us":[1083968,21632],"eu":[909712,23168],"sh":[934640,27776],"cn":[947456,85120]}], +"textures/segment2/segment2.06D00.rgba16.png": [8,8,128,{"jp":[1078992,27904],"us":[1083968,21760],"eu":[909712,23296],"sh":[934640,27904],"cn":[947456,85248]}], +"textures/segment2/segment2.06D80.rgba16.png": [8,8,128,{"jp":[1078992,28032],"us":[1083968,21888],"eu":[909712,23424],"sh":[934640,28032],"cn":[947456,85376]}], +"textures/segment2/segment2.06E00.rgba16.png": [8,8,128,{"jp":[1078992,28160],"us":[1083968,22016],"eu":[909712,23552],"sh":[934640,28160],"cn":[947456,85504]}], +"textures/segment2/segment2.06E80.rgba16.png": [8,8,128,{"jp":[1078992,28288],"us":[1083968,22144],"eu":[909712,23680],"sh":[934640,28288],"cn":[947456,85632]}], +"textures/segment2/segment2.06F00.rgba16.png": [8,8,128,{"jp":[1078992,28416],"us":[1083968,22272],"eu":[909712,23808],"sh":[934640,28416],"cn":[947456,85760]}], +"textures/segment2/segment2.06F80.rgba16.png": [8,8,128,{"jp":[1078992,28544],"us":[1083968,22400],"eu":[909712,23936],"sh":[934640,28544],"cn":[947456,85888]}], +"textures/segment2/segment2.07000.rgba16.png": [8,8,128,{"jp":[1078992,28672],"us":[1083968,22528],"eu":[909712,24064],"sh":[934640,28672],"cn":[947456,86016]}], +"textures/segment2/segment2.07080.rgba16.png": [8,8,128,{"jp":[1078992,28800],"us":[1083968,22656],"eu":[909712,24192],"sh":[934640,28800],"cn":[947456,86144]}], "textures/segment2/segment2.07100.ia1.png": [8,16,16,{"jp":[1078992,28928],"sh":[934640,28928]}], "textures/segment2/segment2.07110.ia1.png": [8,16,16,{"jp":[1078992,28944],"sh":[934640,28944]}], "textures/segment2/segment2.07120.ia1.png": [8,16,16,{"jp":[1078992,28960],"sh":[934640,28960]}], @@ -1640,7 +1647,7 @@ "textures/segment2/segment2.07310.ia1.png": [8,16,16,{"jp":[1078992,29456],"sh":[934640,29456]}], "textures/segment2/segment2.07320.ia1.png": [8,16,16,{"jp":[1078992,29472],"sh":[934640,29472]}], "textures/segment2/segment2.07330.ia1.png": [8,16,16,{"jp":[1078992,29488],"sh":[934640,29488]}], -"textures/segment2/segment2.07340.ia1.png": [8,16,16,{"jp":[1078992,29504],"us":[1083968,24050],"eu":[2647072,44317],"sh":[934640,29504]}], +"textures/segment2/segment2.07340.ia1.png": [8,16,16,{"jp":[1078992,29504],"us":[1083968,24050],"eu":[2647072,44317],"sh":[934640,29504],"cn":[947456,87538]}], "textures/segment2/segment2.07350.ia1.png": [8,16,16,{"jp":[1078992,29520],"sh":[934640,29520]}], "textures/segment2/segment2.07360.ia1.png": [8,16,16,{"jp":[1078992,29536],"sh":[934640,29536]}], "textures/segment2/segment2.07370.ia1.png": [8,16,16,{"jp":[1078992,29552],"sh":[934640,29552]}], @@ -1769,74 +1776,2350 @@ "textures/segment2/segment2.07B20.ia1.png": [8,16,16,{"jp":[1078992,31520],"sh":[934640,31520]}], "textures/segment2/segment2.07B30.ia1.png": [8,16,16,{"jp":[1078992,31536],"sh":[934640,31536]}], "textures/segment2/segment2.07B40.ia1.png": [8,16,16,{"jp":[1078992,31552],"sh":[934640,31552]}], -"textures/segment2/segment2.07B50.rgba16.png": [16,16,512,{"jp":[1078992,31568],"us":[1083968,28672],"eu":[909712,25920],"sh":[934640,31568]}], -"textures/segment2/segment2.07D50.rgba16.png": [16,16,512,{"jp":[1078992,32080],"us":[1083968,29184],"eu":[909712,26432],"sh":[934640,32080]}], -"textures/segment2/segment2.07F50.rgba16.png": [16,16,512,{"jp":[1078992,32592],"us":[1083968,29696],"eu":[909712,26944],"sh":[934640,32592]}], -"textures/segment2/segment2.08150.rgba16.png": [8,8,128,{"jp":[1078992,33104],"us":[1083968,30208],"eu":[909712,27456],"sh":[934640,33104]}], -"textures/segment2/segment2.081D0.rgba16.png": [8,8,128,{"jp":[1078992,33232],"us":[1083968,30336],"eu":[909712,27584],"sh":[934640,33232]}], -"textures/segment2/segment2.0F458.ia8.png": [32,64,2048,{"jp":[1078992,62552],"us":[1083968,74424],"eu":[909712,31096],"sh":[934640,62552]}], -"textures/segment2/segment2.0FC58.ia8.png": [32,64,2048,{"jp":[1078992,64600],"us":[1083968,76472],"eu":[909712,33144],"sh":[934640,64600]}], -"textures/segment2/segment2.10458.ia8.png": [64,64,4096,{"jp":[1078992,66648],"us":[1083968,78520],"eu":[909712,35192],"sh":[934640,66648]}], -"textures/segment2/segment2.11458.ia8.png": [32,64,2048,{"jp":[1078992,70744],"us":[1083968,82616],"eu":[909712,39288],"sh":[934640,70744]}], -"textures/segment2/segment2.11C58.rgba16.png": [32,32,2048,{"jp":[1078992,72792],"us":[1083968,84664],"eu":[909712,41336],"sh":[934640,72792]}], -"textures/segment2/segment2.12458.rgba16.png": [32,32,2048,{"jp":[1078992,74840],"us":[1083968,86712],"eu":[909712,43384],"sh":[934640,74840]}], -"textures/segment2/segment2.12C58.rgba16.png": [32,32,2048,{"jp":[1078992,76888],"us":[1083968,88760],"eu":[909712,45432],"sh":[934640,76888]}], -"textures/segment2/segment2.13458.ia16.png": [32,32,2048,{"jp":[1078992,78936],"us":[1083968,90808],"eu":[909712,47480],"sh":[934640,78936]}], -"textures/segment2/segment2.13C58.rgba16.png": [32,32,2048,{"jp":[1078992,80984],"us":[1083968,92856],"eu":[909712,49528],"sh":[934640,80984]}], -"textures/segment2/segment2.14838.ia8.png": [8,8,64,{"jp":[1078992,84024],"us":[1083968,95896],"eu":[909712,52568],"sh":[934640,84024]}], +"textures/segment2/segment2.07B50.rgba16.png": [16,16,512,{"jp":[1078992,31568],"us":[1083968,28672],"eu":[909712,25920],"sh":[934640,31568],"cn":[947456,126592]}], +"textures/segment2/segment2.07D50.rgba16.png": [16,16,512,{"jp":[1078992,32080],"us":[1083968,29184],"eu":[909712,26432],"sh":[934640,32080],"cn":[947456,127104]}], +"textures/segment2/segment2.07F50.rgba16.png": [16,16,512,{"jp":[1078992,32592],"us":[1083968,29696],"eu":[909712,26944],"sh":[934640,32592],"cn":[947456,127616]}], +"textures/segment2/segment2.08150.rgba16.png": [8,8,128,{"jp":[1078992,33104],"us":[1083968,30208],"eu":[909712,27456],"sh":[934640,33104],"cn":[947456,128128]}], +"textures/segment2/segment2.081D0.rgba16.png": [8,8,128,{"jp":[1078992,33232],"us":[1083968,30336],"eu":[909712,27584],"sh":[934640,33232],"cn":[947456,128256]}], +"textures/segment2/segment2.0F458.ia8.png": [32,64,2048,{"jp":[1078992,62552],"us":[1083968,74424],"eu":[909712,31096],"sh":[934640,62552],"cn":[947456,174888]}], +"textures/segment2/segment2.0FC58.ia8.png": [32,64,2048,{"jp":[1078992,64600],"us":[1083968,76472],"eu":[909712,33144],"sh":[934640,64600],"cn":[947456,176936]}], +"textures/segment2/segment2.10458.ia8.png": [64,64,4096,{"jp":[1078992,66648],"us":[1083968,78520],"eu":[909712,35192],"sh":[934640,66648],"cn":[947456,178984]}], +"textures/segment2/segment2.11458.ia8.png": [32,64,2048,{"jp":[1078992,70744],"us":[1083968,82616],"eu":[909712,39288],"sh":[934640,70744],"cn":[947456,183080]}], +"textures/segment2/segment2.11C58.rgba16.png": [32,32,2048,{"jp":[1078992,72792],"us":[1083968,84664],"eu":[909712,41336],"sh":[934640,72792],"cn":[947456,185128]}], +"textures/segment2/segment2.12458.rgba16.png": [32,32,2048,{"jp":[1078992,74840],"us":[1083968,86712],"eu":[909712,43384],"sh":[934640,74840],"cn":[947456,187176]}], +"textures/segment2/segment2.12C58.rgba16.png": [32,32,2048,{"jp":[1078992,76888],"us":[1083968,88760],"eu":[909712,45432],"sh":[934640,76888],"cn":[947456,189224]}], +"textures/segment2/segment2.13458.ia16.png": [32,32,2048,{"jp":[1078992,78936],"us":[1083968,90808],"eu":[909712,47480],"sh":[934640,78936],"cn":[947456,191272]}], +"textures/segment2/segment2.13C58.rgba16.png": [32,32,2048,{"jp":[1078992,80984],"us":[1083968,92856],"eu":[909712,49528],"sh":[934640,80984],"cn":[947456,193320]}], +"textures/segment2/segment2.14838.ia8.png": [8,8,64,{"jp":[1078992,84024],"us":[1083968,95896],"eu":[909712,52568],"sh":[934640,84024],"cn":[947456,196360]}], "textures/segment2/segment2.umlaut.rgba16.png": [16,16,512,{"eu":[909712,17920]}], -"textures/segment2/shadow_quarter_circle.ia8.png": [16,16,256,{"jp":[1078992,62040],"us":[1083968,73912],"eu":[909712,30584],"sh":[934640,62040]}], -"textures/segment2/shadow_quarter_square.ia8.png": [16,16,256,{"jp":[1078992,62296],"us":[1083968,74168],"eu":[909712,30840],"sh":[934640,62296]}], -"textures/sky/metal_hole.rgba16.png": [32,32,2048,{"jp":[3390640,26624],"us":[3397392,26624],"eu":[3270992,26624],"sh":[3245360,26624]}], -"textures/sky/rr_textures.00000.rgba16.png": [32,32,2048,{"jp":[3390640,0],"us":[3397392,0],"eu":[3270992,0],"sh":[3245360,0]}], -"textures/sky/rr_textures.00800.rgba16.png": [32,32,2048,{"jp":[3390640,2048],"us":[3397392,2048],"eu":[3270992,2048],"sh":[3245360,2048]}], -"textures/sky/rr_textures.01000.rgba16.png": [32,32,2048,{"jp":[3390640,4096],"us":[3397392,4096],"eu":[3270992,4096],"sh":[3245360,4096]}], -"textures/sky/rr_textures.01800.rgba16.png": [32,32,2048,{"jp":[3390640,6144],"us":[3397392,6144],"eu":[3270992,6144],"sh":[3245360,6144]}], -"textures/sky/rr_textures.02000.rgba16.png": [32,64,4096,{"jp":[3390640,8192],"us":[3397392,8192],"eu":[3270992,8192],"sh":[3245360,8192]}], -"textures/sky/rr_textures.03000.rgba16.png": [32,32,2048,{"jp":[3390640,12288],"us":[3397392,12288],"eu":[3270992,12288],"sh":[3245360,12288]}], -"textures/sky/rr_textures.03800.rgba16.png": [64,32,4096,{"jp":[3390640,14336],"us":[3397392,14336],"eu":[3270992,14336],"sh":[3245360,14336]}], -"textures/sky/rr_textures.04800.rgba16.png": [32,32,2048,{"jp":[3390640,18432],"us":[3397392,18432],"eu":[3270992,18432],"sh":[3245360,18432]}], -"textures/sky/rr_textures.05000.rgba16.png": [32,32,2048,{"jp":[3390640,20480],"us":[3397392,20480],"eu":[3270992,20480],"sh":[3245360,20480]}], -"textures/sky/rr_textures.05800.rgba16.png": [32,32,2048,{"jp":[3390640,22528],"us":[3397392,22528],"eu":[3270992,22528],"sh":[3245360,22528]}], -"textures/sky/rr_textures.06000.rgba16.png": [32,32,2048,{"jp":[3390640,24576],"us":[3397392,24576],"eu":[3270992,24576],"sh":[3245360,24576]}], -"textures/sky/rr_textures.07000.rgba16.png": [32,32,2048,{"jp":[3390640,28672],"us":[3397392,28672],"eu":[3270992,28672],"sh":[3245360,28672]}], -"textures/sky/rr_textures.07800.rgba16.png": [32,32,2048,{"jp":[3390640,30720],"us":[3397392,30720],"eu":[3270992,30720],"sh":[3245360,30720]}], -"textures/sky/rr_textures.08000.rgba16.png": [32,32,2048,{"jp":[3390640,32768],"us":[3397392,32768],"eu":[3270992,32768],"sh":[3245360,32768]}], -"textures/snow/ccm_textures.00000.rgba16.png": [32,32,2048,{"jp":[3405536,0],"us":[3412288,0],"eu":[3285888,0],"sh":[3260256,0]}], -"textures/snow/ccm_textures.00800.rgba16.png": [32,32,2048,{"jp":[3405536,2048],"us":[3412288,2048],"eu":[3285888,2048],"sh":[3260256,2048]}], -"textures/snow/ccm_textures.01000.rgba16.png": [32,64,4096,{"jp":[3405536,4096],"us":[3412288,4096],"eu":[3285888,4096],"sh":[3260256,4096]}], -"textures/snow/ccm_textures.02000.rgba16.png": [32,32,2048,{"jp":[3405536,8192],"us":[3412288,8192],"eu":[3285888,8192],"sh":[3260256,8192]}], -"textures/snow/ccm_textures.02800.rgba16.png": [32,32,2048,{"jp":[3405536,10240],"us":[3412288,10240],"eu":[3285888,10240],"sh":[3260256,10240]}], -"textures/snow/ccm_textures.03000.rgba16.png": [32,32,2048,{"jp":[3405536,12288],"us":[3412288,12288],"eu":[3285888,12288],"sh":[3260256,12288]}], -"textures/snow/ccm_textures.03800.rgba16.png": [32,32,2048,{"jp":[3405536,14336],"us":[3412288,14336],"eu":[3285888,14336],"sh":[3260256,14336]}], -"textures/snow/ccm_textures.04000.rgba16.png": [32,32,2048,{"jp":[3405536,16384],"us":[3412288,16384],"eu":[3285888,16384],"sh":[3260256,16384]}], -"textures/snow/ccm_textures.04800.rgba16.png": [32,32,2048,{"jp":[3405536,18432],"us":[3412288,18432],"eu":[3285888,18432],"sh":[3260256,18432]}], -"textures/snow/ccm_textures.05000.rgba16.png": [32,32,2048,{"jp":[3405536,20480],"us":[3412288,20480],"eu":[3285888,20480],"sh":[3260256,20480]}], -"textures/snow/ccm_textures.05800.rgba16.png": [32,32,2048,{"jp":[3405536,22528],"us":[3412288,22528],"eu":[3285888,22528],"sh":[3260256,22528]}], -"textures/snow/ccm_textures.06000.rgba16.png": [32,32,2048,{"jp":[3405536,24576],"us":[3412288,24576],"eu":[3285888,24576],"sh":[3260256,24576]}], -"textures/snow/ccm_textures.06800.rgba16.png": [32,32,2048,{"jp":[3405536,26624],"us":[3412288,26624],"eu":[3285888,26624],"sh":[3260256,26624]}], -"textures/snow/ccm_textures.07000.rgba16.png": [64,32,4096,{"jp":[3405536,28672],"us":[3412288,28672],"eu":[3285888,28672],"sh":[3260256,28672]}], -"textures/snow/ccm_textures.08000.rgba16.png": [32,32,2048,{"jp":[3405536,32768],"us":[3412288,32768],"eu":[3285888,32768],"sh":[3260256,32768]}], -"textures/snow/ccm_textures.08800.rgba16.png": [32,32,2048,{"jp":[3405536,34816],"us":[3412288,34816],"eu":[3285888,34816],"sh":[3260256,34816]}], -"textures/snow/ccm_textures.09000.ia16.png": [32,32,2048,{"jp":[3405536,36864],"us":[3412288,36864],"eu":[3285888,36864],"sh":[3260256,36864]}], -"textures/snow/ccm_textures.09800.ia16.png": [32,32,2048,{"jp":[3405536,38912],"us":[3412288,38912],"eu":[3285888,38912],"sh":[3260256,38912]}], -"textures/spooky/bbh_textures.00000.rgba16.png": [32,32,2048,{"jp":[3298272,0],"us":[3305024,0],"eu":[3178624,0],"sh":[3152992,0]}], -"textures/spooky/bbh_textures.00800.rgba16.png": [32,64,4096,{"jp":[3298272,2048],"us":[3305024,2048],"eu":[3178624,2048],"sh":[3152992,2048]}], -"textures/spooky/bbh_textures.01800.rgba16.png": [32,64,4096,{"jp":[3298272,6144],"us":[3305024,6144],"eu":[3178624,6144],"sh":[3152992,6144]}], -"textures/spooky/bbh_textures.02800.rgba16.png": [32,64,4096,{"jp":[3298272,10240],"us":[3305024,10240],"eu":[3178624,10240],"sh":[3152992,10240]}], -"textures/spooky/bbh_textures.03800.rgba16.png": [32,64,4096,{"jp":[3298272,14336],"us":[3305024,14336],"eu":[3178624,14336],"sh":[3152992,14336]}], -"textures/spooky/bbh_textures.04800.rgba16.png": [32,32,2048,{"jp":[3298272,18432],"us":[3305024,18432],"eu":[3178624,18432],"sh":[3152992,18432]}], -"textures/spooky/bbh_textures.05000.rgba16.png": [32,64,4096,{"jp":[3298272,20480],"us":[3305024,20480],"eu":[3178624,20480],"sh":[3152992,20480]}], -"textures/spooky/bbh_textures.06000.rgba16.png": [32,32,2048,{"jp":[3298272,24576],"us":[3305024,24576],"eu":[3178624,24576],"sh":[3152992,24576]}], -"textures/spooky/bbh_textures.06800.rgba16.png": [32,32,2048,{"jp":[3298272,26624],"us":[3305024,26624],"eu":[3178624,26624],"sh":[3152992,26624]}], -"textures/spooky/bbh_textures.07000.rgba16.png": [64,32,4096,{"jp":[3298272,28672],"us":[3305024,28672],"eu":[3178624,28672],"sh":[3152992,28672]}], -"textures/spooky/bbh_textures.08000.rgba16.png": [32,32,2048,{"jp":[3298272,32768],"us":[3305024,32768],"eu":[3178624,32768],"sh":[3152992,32768]}], -"textures/spooky/bbh_textures.08800.rgba16.png": [32,32,2048,{"jp":[3298272,34816],"us":[3305024,34816],"eu":[3178624,34816],"sh":[3152992,34816]}], -"textures/spooky/bbh_textures.09000.rgba16.png": [64,32,4096,{"jp":[3298272,36864],"us":[3305024,36864],"eu":[3178624,36864],"sh":[3152992,36864]}], -"textures/spooky/bbh_textures.0A000.rgba16.png": [32,32,2048,{"jp":[1462368,49800],"us":[1469536,49800],"eu":[1341504,49800],"sh":[1318016,49800]}], -"textures/spooky/bbh_textures.0A800.ia16.png": [32,32,2048,{"jp":[3298272,43008],"us":[3305024,43008],"eu":[3178624,43008],"sh":[3152992,43008]}], -"textures/spooky/bbh_textures.0B000.ia16.png": [32,32,2048,{"jp":[3298272,45056],"us":[3305024,45056],"eu":[3178624,45056],"sh":[3152992,45056]}], -"textures/spooky/bbh_textures.0B800.ia16.png": [32,64,4096,{"jp":[3298272,47104],"us":[3305024,47104],"eu":[3178624,47104],"sh":[3152992,47104]}], +"textures/segment2/segment2_cn.04A00.rgba16.png": [16,16,512,{"cn":[947456,18944]}], +"textures/segment2/segment2_cn.04C00.rgba16.png": [16,16,512,{"cn":[947456,19456]}], +"textures/segment2/segment2_cn.04E00.rgba16.png": [16,16,512,{"cn":[947456,19968]}], +"textures/segment2/segment2_cn.05000.rgba16.png": [16,16,512,{"cn":[947456,20480]}], +"textures/segment2/segment2_cn.05200.rgba16.png": [16,16,512,{"cn":[947456,20992]}], +"textures/segment2/segment2_cn.05400.rgba16.png": [16,16,512,{"cn":[947456,21504]}], +"textures/segment2/segment2_cn.05600.rgba16.png": [16,16,512,{"cn":[947456,22016]}], +"textures/segment2/segment2_cn.05800.rgba16.png": [16,16,512,{"cn":[947456,22528]}], +"textures/segment2/segment2_cn.05A00.rgba16.png": [16,16,512,{"cn":[947456,23040]}], +"textures/segment2/segment2_cn.05C00.rgba16.png": [16,16,512,{"cn":[947456,23552]}], +"textures/segment2/segment2_cn.05E00.rgba16.png": [16,16,512,{"cn":[947456,24064]}], +"textures/segment2/segment2_cn.06000.rgba16.png": [16,16,512,{"cn":[947456,24576]}], +"textures/segment2/segment2_cn.06200.rgba16.png": [16,16,512,{"cn":[947456,25088]}], +"textures/segment2/segment2_cn.06400.rgba16.png": [16,16,512,{"cn":[947456,25600]}], +"textures/segment2/segment2_cn.06600.rgba16.png": [16,16,512,{"cn":[947456,26112]}], +"textures/segment2/segment2_cn.06800.rgba16.png": [16,16,512,{"cn":[947456,26624]}], +"textures/segment2/segment2_cn.06A00.rgba16.png": [16,16,512,{"cn":[947456,27136]}], +"textures/segment2/segment2_cn.06C00.rgba16.png": [16,16,512,{"cn":[947456,27648]}], +"textures/segment2/segment2_cn.06E00.rgba16.png": [16,16,512,{"cn":[947456,28160]}], +"textures/segment2/segment2_cn.07000.rgba16.png": [16,16,512,{"cn":[947456,28672]}], +"textures/segment2/segment2_cn.07200.rgba16.png": [16,16,512,{"cn":[947456,29184]}], +"textures/segment2/segment2_cn.07400.rgba16.png": [16,16,512,{"cn":[947456,29696]}], +"textures/segment2/segment2_cn.07600.rgba16.png": [16,16,512,{"cn":[947456,30208]}], +"textures/segment2/segment2_cn.07800.rgba16.png": [16,16,512,{"cn":[947456,30720]}], +"textures/segment2/segment2_cn.07A00.rgba16.png": [16,16,512,{"cn":[947456,31232]}], +"textures/segment2/segment2_cn.07C00.rgba16.png": [16,16,512,{"cn":[947456,31744]}], +"textures/segment2/segment2_cn.07E00.rgba16.png": [16,16,512,{"cn":[947456,32256]}], +"textures/segment2/segment2_cn.08000.rgba16.png": [16,16,512,{"cn":[947456,32768]}], +"textures/segment2/segment2_cn.08200.rgba16.png": [16,16,512,{"cn":[947456,33280]}], +"textures/segment2/segment2_cn.08400.rgba16.png": [16,16,512,{"cn":[947456,33792]}], +"textures/segment2/segment2_cn.08600.rgba16.png": [16,16,512,{"cn":[947456,34304]}], +"textures/segment2/segment2_cn.08800.rgba16.png": [16,16,512,{"cn":[947456,34816]}], +"textures/segment2/segment2_cn.08A00.rgba16.png": [16,16,512,{"cn":[947456,35328]}], +"textures/segment2/segment2_cn.08C00.rgba16.png": [16,16,512,{"cn":[947456,35840]}], +"textures/segment2/segment2_cn.08E00.rgba16.png": [16,16,512,{"cn":[947456,36352]}], +"textures/segment2/segment2_cn.09000.rgba16.png": [16,16,512,{"cn":[947456,36864]}], +"textures/segment2/segment2_cn.09200.rgba16.png": [16,16,512,{"cn":[947456,37376]}], +"textures/segment2/segment2_cn.09400.rgba16.png": [16,16,512,{"cn":[947456,37888]}], +"textures/segment2/segment2_cn.09600.rgba16.png": [16,16,512,{"cn":[947456,38400]}], +"textures/segment2/segment2_cn.09800.rgba16.png": [16,16,512,{"cn":[947456,38912]}], +"textures/segment2/segment2_cn.09A00.rgba16.png": [16,16,512,{"cn":[947456,39424]}], +"textures/segment2/segment2_cn.09C00.rgba16.png": [16,16,512,{"cn":[947456,39936]}], +"textures/segment2/segment2_cn.09E00.rgba16.png": [16,16,512,{"cn":[947456,40448]}], +"textures/segment2/segment2_cn.0A000.rgba16.png": [16,16,512,{"cn":[947456,40960]}], +"textures/segment2/segment2_cn.0A200.rgba16.png": [16,16,512,{"cn":[947456,41472]}], +"textures/segment2/segment2_cn.0A400.rgba16.png": [16,16,512,{"cn":[947456,41984]}], +"textures/segment2/segment2_cn.0A600.rgba16.png": [16,16,512,{"cn":[947456,42496]}], +"textures/segment2/segment2_cn.0A800.rgba16.png": [16,16,512,{"cn":[947456,43008]}], +"textures/segment2/segment2_cn.0AA00.rgba16.png": [16,16,512,{"cn":[947456,43520]}], +"textures/segment2/segment2_cn.0AC00.rgba16.png": [16,16,512,{"cn":[947456,44032]}], +"textures/segment2/segment2_cn.0AE00.rgba16.png": [16,16,512,{"cn":[947456,44544]}], +"textures/segment2/segment2_cn.0B000.rgba16.png": [16,16,512,{"cn":[947456,45056]}], +"textures/segment2/segment2_cn.0B200.rgba16.png": [16,16,512,{"cn":[947456,45568]}], +"textures/segment2/segment2_cn.0B400.rgba16.png": [16,16,512,{"cn":[947456,46080]}], +"textures/segment2/segment2_cn.0B600.rgba16.png": [16,16,512,{"cn":[947456,46592]}], +"textures/segment2/segment2_cn.0B800.rgba16.png": [16,16,512,{"cn":[947456,47104]}], +"textures/segment2/segment2_cn.0BA00.rgba16.png": [16,16,512,{"cn":[947456,47616]}], +"textures/segment2/segment2_cn.0BC00.rgba16.png": [16,16,512,{"cn":[947456,48128]}], +"textures/segment2/segment2_cn.0BE00.rgba16.png": [16,16,512,{"cn":[947456,48640]}], +"textures/segment2/segment2_cn.0C000.rgba16.png": [16,16,512,{"cn":[947456,49152]}], +"textures/segment2/segment2_cn.0C200.rgba16.png": [16,16,512,{"cn":[947456,49664]}], +"textures/segment2/segment2_cn.0C400.rgba16.png": [16,16,512,{"cn":[947456,50176]}], +"textures/segment2/segment2_cn.0C600.rgba16.png": [16,16,512,{"cn":[947456,50688]}], +"textures/segment2/segment2_cn.0C800.rgba16.png": [16,16,512,{"cn":[947456,51200]}], +"textures/segment2/segment2_cn.0CA00.rgba16.png": [16,16,512,{"cn":[947456,51712]}], +"textures/segment2/segment2_cn.0CC00.rgba16.png": [16,16,512,{"cn":[947456,52224]}], +"textures/segment2/segment2_cn.0CE00.rgba16.png": [16,16,512,{"cn":[947456,52736]}], +"textures/segment2/segment2_cn.0D000.rgba16.png": [16,16,512,{"cn":[947456,53248]}], +"textures/segment2/segment2_cn.0D200.rgba16.png": [16,16,512,{"cn":[947456,53760]}], +"textures/segment2/segment2_cn.0D400.rgba16.png": [16,16,512,{"cn":[947456,54272]}], +"textures/segment2/segment2_cn.0D600.rgba16.png": [16,16,512,{"cn":[947456,54784]}], +"textures/segment2/segment2_cn.0D800.rgba16.png": [16,16,512,{"cn":[947456,55296]}], +"textures/segment2/segment2_cn.0DA00.rgba16.png": [16,16,512,{"cn":[947456,55808]}], +"textures/segment2/segment2_cn.0DC00.rgba16.png": [16,16,512,{"cn":[947456,56320]}], +"textures/segment2/segment2_cn.0DE00.rgba16.png": [16,16,512,{"cn":[947456,56832]}], +"textures/segment2/segment2_cn.0E000.rgba16.png": [16,16,512,{"cn":[947456,57344]}], +"textures/segment2/segment2_cn.0E200.rgba16.png": [16,16,512,{"cn":[947456,57856]}], +"textures/segment2/segment2_cn.0E400.rgba16.png": [16,16,512,{"cn":[947456,58368]}], +"textures/segment2/segment2_cn.0E600.rgba16.png": [16,16,512,{"cn":[947456,58880]}], +"textures/segment2/segment2_cn.0E800.rgba16.png": [16,16,512,{"cn":[947456,59392]}], +"textures/segment2/segment2_cn.0EA00.rgba16.png": [16,16,512,{"cn":[947456,59904]}], +"textures/segment2/segment2_cn.0EC00.rgba16.png": [16,16,512,{"cn":[947456,60416]}], +"textures/segment2/segment2_cn.0EE00.rgba16.png": [16,16,512,{"cn":[947456,60928]}], +"textures/segment2/segment2_cn.0F000.rgba16.png": [16,16,512,{"cn":[947456,61440]}], +"textures/segment2/segment2_cn.0F200.rgba16.png": [16,16,512,{"cn":[947456,61952]}], +"textures/segment2/segment2_cn.0F400.rgba16.png": [16,16,512,{"cn":[947456,62464]}], +"textures/segment2/segment2_cn.0F600.rgba16.png": [16,16,512,{"cn":[947456,62976]}], +"textures/segment2/segment2_cn.0F800.rgba16.png": [16,16,512,{"cn":[947456,63488]}], +"textures/segment2/segment2_cn.0FA00.rgba16.png": [16,16,512,{"cn":[947456,64000]}], +"textures/segment2/segment2_cn.0FC00.rgba16.png": [16,16,512,{"cn":[947456,64512]}], +"textures/segment2/segment2_cn.0FE00.rgba16.png": [16,16,512,{"cn":[947456,65024]}], +"textures/segment2/segment2_cn.10000.rgba16.png": [16,16,512,{"cn":[947456,65536]}], +"textures/segment2/segment2_cn.10200.rgba16.png": [16,16,512,{"cn":[947456,66048]}], +"textures/segment2/segment2_cn.10400.rgba16.png": [16,16,512,{"cn":[947456,66560]}], +"textures/segment2/segment2_cn.10600.rgba16.png": [16,16,512,{"cn":[947456,67072]}], +"textures/segment2/segment2_cn.10800.rgba16.png": [16,16,512,{"cn":[947456,67584]}], +"textures/segment2/segment2_cn.10A00.rgba16.png": [16,16,512,{"cn":[947456,68096]}], +"textures/segment2/segment2_cn.10C00.rgba16.png": [16,16,512,{"cn":[947456,68608]}], +"textures/segment2/segment2_cn.10E00.rgba16.png": [16,16,512,{"cn":[947456,69120]}], +"textures/segment2/segment2_cn.11000.rgba16.png": [16,16,512,{"cn":[947456,69632]}], +"textures/segment2/segment2_cn.11200.rgba16.png": [16,16,512,{"cn":[947456,70144]}], +"textures/segment2/segment2_cn.11400.rgba16.png": [16,16,512,{"cn":[947456,70656]}], +"textures/segment2/segment2_cn.11600.rgba16.png": [16,16,512,{"cn":[947456,71168]}], +"textures/segment2/segment2_cn.11800.rgba16.png": [16,16,512,{"cn":[947456,71680]}], +"textures/segment2/segment2_cn.11A00.rgba16.png": [16,16,512,{"cn":[947456,72192]}], +"textures/segment2/segment2_cn.11C00.rgba16.png": [16,16,512,{"cn":[947456,72704]}], +"textures/segment2/segment2_cn.11E00.rgba16.png": [16,16,512,{"cn":[947456,73216]}], +"textures/segment2/segment2_cn.12000.rgba16.png": [16,16,512,{"cn":[947456,73728]}], +"textures/segment2/segment2_cn.12200.rgba16.png": [16,16,512,{"cn":[947456,74240]}], +"textures/segment2/segment2_cn.12400.rgba16.png": [16,16,512,{"cn":[947456,74752]}], +"textures/segment2/segment2_cn.12600.rgba16.png": [16,16,512,{"cn":[947456,75264]}], +"textures/segment2/segment2_cn.12800.rgba16.png": [16,16,512,{"cn":[947456,75776]}], +"textures/segment2/segment2_cn.12A00.rgba16.png": [16,16,512,{"cn":[947456,76288]}], +"textures/segment2/segment2_cn.12C00.rgba16.png": [16,16,512,{"cn":[947456,76800]}], +"textures/segment2/segment2_cn.12E00.rgba16.png": [16,16,512,{"cn":[947456,77312]}], +"textures/segment2/segment2_cn.13000.rgba16.png": [16,16,512,{"cn":[947456,77824]}], +"textures/segment2/segment2_cn.13200.rgba16.png": [16,16,512,{"cn":[947456,78336]}], +"textures/segment2/segment2_cn.13400.rgba16.png": [16,16,512,{"cn":[947456,78848]}], +"textures/segment2/segment2_cn.13600.rgba16.png": [16,16,512,{"cn":[947456,79360]}], +"textures/segment2/segment2_cn.13800.rgba16.png": [16,16,512,{"cn":[947456,79872]}], +"textures/segment2/segment2_cn.13A00.rgba16.png": [16,16,512,{"cn":[947456,80384]}], +"textures/segment2/segment2_cn.13C00.rgba16.png": [16,16,512,{"cn":[947456,80896]}], +"textures/segment2/segment2_cn.13E00.rgba16.png": [16,16,512,{"cn":[947456,81408]}], +"textures/segment2/segment2_cn.14000.rgba16.png": [16,16,512,{"cn":[947456,81920]}], +"textures/segment2/segment2_cn.16800.ia1.png": [16,8,16,{"cn":[947456,92160]}], +"textures/segment2/segment2_cn.16810.ia1.png": [16,8,16,{"cn":[947456,92176]}], +"textures/segment2/segment2_cn.16820.ia1.png": [16,8,16,{"cn":[947456,92192]}], +"textures/segment2/segment2_cn.16830.ia1.png": [16,8,16,{"cn":[947456,92208]}], +"textures/segment2/segment2_cn.16840.ia1.png": [16,8,16,{"cn":[947456,92224]}], +"textures/segment2/segment2_cn.16850.ia1.png": [16,8,16,{"cn":[947456,92240]}], +"textures/segment2/segment2_cn.16860.ia1.png": [16,8,16,{"cn":[947456,92256]}], +"textures/segment2/segment2_cn.16870.ia1.png": [16,8,16,{"cn":[947456,92272]}], +"textures/segment2/segment2_cn.16880.ia1.png": [16,8,16,{"cn":[947456,92288]}], +"textures/segment2/segment2_cn.16890.ia1.png": [16,8,16,{"cn":[947456,92304]}], +"textures/segment2/segment2_cn.168A0.ia1.png": [16,8,16,{"cn":[947456,92320]}], +"textures/segment2/segment2_cn.168B0.ia1.png": [16,8,16,{"cn":[947456,92336]}], +"textures/segment2/segment2_cn.168C0.ia1.png": [16,8,16,{"cn":[947456,92352]}], +"textures/segment2/segment2_cn.168D0.ia1.png": [16,8,16,{"cn":[947456,92368]}], +"textures/segment2/segment2_cn.168E0.ia1.png": [16,8,16,{"cn":[947456,92384]}], +"textures/segment2/segment2_cn.168F0.ia1.png": [16,8,16,{"cn":[947456,92400]}], +"textures/segment2/segment2_cn.16900.ia1.png": [16,8,16,{"cn":[947456,92416]}], +"textures/segment2/segment2_cn.16910.ia1.png": [16,8,16,{"cn":[947456,92432]}], +"textures/segment2/segment2_cn.16920.ia1.png": [16,8,16,{"cn":[947456,92448]}], +"textures/segment2/segment2_cn.16930.ia1.png": [16,8,16,{"cn":[947456,92464]}], +"textures/segment2/segment2_cn.16940.ia1.png": [16,8,16,{"cn":[947456,92480]}], +"textures/segment2/segment2_cn.16950.ia1.png": [16,8,16,{"cn":[947456,92496]}], +"textures/segment2/segment2_cn.16960.ia1.png": [16,8,16,{"cn":[947456,92512]}], +"textures/segment2/segment2_cn.16970.ia1.png": [16,8,16,{"cn":[947456,92528]}], +"textures/segment2/segment2_cn.16980.ia1.png": [16,8,16,{"cn":[947456,92544]}], +"textures/segment2/segment2_cn.16990.ia1.png": [16,8,16,{"cn":[947456,92560]}], +"textures/segment2/segment2_cn.169A0.ia1.png": [16,8,16,{"cn":[947456,92576]}], +"textures/segment2/segment2_cn.169B0.ia1.png": [16,8,16,{"cn":[947456,92592]}], +"textures/segment2/segment2_cn.169C0.ia1.png": [16,8,16,{"cn":[947456,92608]}], +"textures/segment2/segment2_cn.169D0.ia1.png": [16,8,16,{"cn":[947456,92624]}], +"textures/segment2/segment2_cn.169E0.ia1.png": [16,8,16,{"cn":[947456,92640]}], +"textures/segment2/segment2_cn.169F0.ia1.png": [16,8,16,{"cn":[947456,92656]}], +"textures/segment2/segment2_cn.16A00.ia1.png": [16,8,16,{"cn":[947456,92672]}], +"textures/segment2/segment2_cn.16A10.ia1.png": [16,8,16,{"cn":[947456,92688]}], +"textures/segment2/segment2_cn.16A20.ia1.png": [16,8,16,{"cn":[947456,92704]}], +"textures/segment2/segment2_cn.16A30.ia1.png": [16,8,16,{"cn":[947456,92720]}], +"textures/segment2/segment2_cn.16A40.ia1.png": [16,8,16,{"cn":[947456,92736]}], +"textures/segment2/segment2_cn.16A50.ia1.png": [16,8,16,{"cn":[947456,92752]}], +"textures/segment2/segment2_cn.16A60.ia1.png": [16,8,16,{"cn":[947456,92768]}], +"textures/segment2/segment2_cn.16A70.ia1.png": [16,8,16,{"cn":[947456,92784]}], +"textures/segment2/segment2_cn.16A80.ia1.png": [16,8,16,{"cn":[947456,92800]}], +"textures/segment2/segment2_cn.16A90.ia1.png": [16,8,16,{"cn":[947456,92816]}], +"textures/segment2/segment2_cn.16AA0.ia1.png": [16,8,16,{"cn":[947456,92832]}], +"textures/segment2/segment2_cn.16AB0.ia1.png": [16,8,16,{"cn":[947456,92848]}], +"textures/segment2/segment2_cn.16AC0.ia1.png": [16,8,16,{"cn":[947456,92864]}], +"textures/segment2/segment2_cn.16AD0.ia1.png": [16,8,16,{"cn":[947456,92880]}], +"textures/segment2/segment2_cn.16AE0.ia1.png": [16,8,16,{"cn":[947456,92896]}], +"textures/segment2/segment2_cn.16AF0.ia1.png": [16,8,16,{"cn":[947456,92912]}], +"textures/segment2/segment2_cn.16B00.ia1.png": [16,8,16,{"cn":[947456,92928]}], +"textures/segment2/segment2_cn.16B10.ia1.png": [16,8,16,{"cn":[947456,92944]}], +"textures/segment2/segment2_cn.16B20.ia1.png": [16,8,16,{"cn":[947456,92960]}], +"textures/segment2/segment2_cn.16B30.ia1.png": [16,8,16,{"cn":[947456,92976]}], +"textures/segment2/segment2_cn.16B40.ia1.png": [16,8,16,{"cn":[947456,92992]}], +"textures/segment2/segment2_cn.16B50.ia1.png": [16,8,16,{"cn":[947456,93008]}], +"textures/segment2/segment2_cn.16B60.ia1.png": [16,8,16,{"cn":[947456,93024]}], +"textures/segment2/segment2_cn.16B70.ia1.png": [16,8,16,{"cn":[947456,93040]}], +"textures/segment2/segment2_cn.16B80.ia1.png": [16,8,16,{"cn":[947456,93056]}], +"textures/segment2/segment2_cn.16B90.ia1.png": [16,8,16,{"cn":[947456,93072]}], +"textures/segment2/segment2_cn.16BA0.ia1.png": [16,8,16,{"cn":[947456,93088]}], +"textures/segment2/segment2_cn.16BB0.ia1.png": [16,8,16,{"cn":[947456,93104]}], +"textures/segment2/segment2_cn.16BC0.ia1.png": [16,8,16,{"cn":[947456,93120]}], +"textures/segment2/segment2_cn.16BD0.ia1.png": [16,8,16,{"cn":[947456,93136]}], +"textures/segment2/segment2_cn.16BE0.ia1.png": [16,8,16,{"cn":[947456,93152]}], +"textures/segment2/segment2_cn.16BF0.ia1.png": [16,8,16,{"cn":[947456,93168]}], +"textures/segment2/segment2_cn.16C00.ia1.png": [16,8,16,{"cn":[947456,93184]}], +"textures/segment2/segment2_cn.16C10.ia1.png": [16,8,16,{"cn":[947456,93200]}], +"textures/segment2/segment2_cn.16C20.ia1.png": [16,8,16,{"cn":[947456,93216]}], +"textures/segment2/segment2_cn.16C30.ia1.png": [16,8,16,{"cn":[947456,93232]}], +"textures/segment2/segment2_cn.16C40.ia1.png": [16,8,16,{"cn":[947456,93248]}], +"textures/segment2/segment2_cn.16C50.ia1.png": [16,8,16,{"cn":[947456,93264]}], +"textures/segment2/segment2_cn.16C60.ia1.png": [16,8,16,{"cn":[947456,93280]}], +"textures/segment2/segment2_cn.16C70.ia1.png": [16,8,16,{"cn":[947456,93296]}], +"textures/segment2/segment2_cn.16C80.ia1.png": [16,8,16,{"cn":[947456,93312]}], +"textures/segment2/segment2_cn.16C90.ia1.png": [16,8,16,{"cn":[947456,93328]}], +"textures/segment2/segment2_cn.16CA0.ia1.png": [16,8,16,{"cn":[947456,93344]}], +"textures/segment2/segment2_cn.16CB0.ia1.png": [16,8,16,{"cn":[947456,93360]}], +"textures/segment2/segment2_cn.16CC0.ia1.png": [16,8,16,{"cn":[947456,93376]}], +"textures/segment2/segment2_cn.16CD0.ia1.png": [16,8,16,{"cn":[947456,93392]}], +"textures/segment2/segment2_cn.16CE0.ia1.png": [16,8,16,{"cn":[947456,93408]}], +"textures/segment2/segment2_cn.16CF0.ia1.png": [16,8,16,{"cn":[947456,93424]}], +"textures/segment2/segment2_cn.16D00.ia1.png": [16,8,16,{"cn":[947456,93440]}], +"textures/segment2/segment2_cn.16D10.ia1.png": [16,8,16,{"cn":[947456,93456]}], +"textures/segment2/segment2_cn.16D20.ia1.png": [16,8,16,{"cn":[947456,93472]}], +"textures/segment2/segment2_cn.16D30.ia1.png": [16,8,16,{"cn":[947456,93488]}], +"textures/segment2/segment2_cn.16D40.ia1.png": [16,8,16,{"cn":[947456,93504]}], +"textures/segment2/segment2_cn.16D50.ia1.png": [16,8,16,{"cn":[947456,93520]}], +"textures/segment2/segment2_cn.16D60.ia1.png": [16,8,16,{"cn":[947456,93536]}], +"textures/segment2/segment2_cn.16D70.ia1.png": [16,8,16,{"cn":[947456,93552]}], +"textures/segment2/segment2_cn.16D80.ia1.png": [16,8,16,{"cn":[947456,93568]}], +"textures/segment2/segment2_cn.16D90.ia1.png": [16,8,16,{"cn":[947456,93584]}], +"textures/segment2/segment2_cn.16DA0.ia1.png": [16,8,16,{"cn":[947456,93600]}], +"textures/segment2/segment2_cn.16DB0.ia1.png": [16,8,16,{"cn":[947456,93616]}], +"textures/segment2/segment2_cn.16DC0.ia1.png": [16,8,16,{"cn":[947456,93632]}], +"textures/segment2/segment2_cn.16DD0.ia1.png": [16,8,16,{"cn":[947456,93648]}], +"textures/segment2/segment2_cn.16DE0.ia1.png": [16,8,16,{"cn":[947456,93664]}], +"textures/segment2/segment2_cn.16DF0.ia1.png": [16,8,16,{"cn":[947456,93680]}], +"textures/segment2/segment2_cn.16E00.ia1.png": [16,8,16,{"cn":[947456,93696]}], +"textures/segment2/segment2_cn.16E10.ia1.png": [16,8,16,{"cn":[947456,93712]}], +"textures/segment2/segment2_cn.16E20.ia1.png": [16,8,16,{"cn":[947456,93728]}], +"textures/segment2/segment2_cn.16E30.ia1.png": [16,8,16,{"cn":[947456,93744]}], +"textures/segment2/segment2_cn.16E40.ia1.png": [16,8,16,{"cn":[947456,93760]}], +"textures/segment2/segment2_cn.16E50.ia1.png": [16,8,16,{"cn":[947456,93776]}], +"textures/segment2/segment2_cn.16E60.ia1.png": [16,8,16,{"cn":[947456,93792]}], +"textures/segment2/segment2_cn.16E70.ia1.png": [16,8,16,{"cn":[947456,93808]}], +"textures/segment2/segment2_cn.16E80.ia1.png": [16,8,16,{"cn":[947456,93824]}], +"textures/segment2/segment2_cn.16E90.ia1.png": [16,8,16,{"cn":[947456,93840]}], +"textures/segment2/segment2_cn.16EA0.ia1.png": [16,8,16,{"cn":[947456,93856]}], +"textures/segment2/segment2_cn.16EB0.ia1.png": [16,8,16,{"cn":[947456,93872]}], +"textures/segment2/segment2_cn.16EC0.ia1.png": [16,8,16,{"cn":[947456,93888]}], +"textures/segment2/segment2_cn.16ED0.ia1.png": [16,8,16,{"cn":[947456,93904]}], +"textures/segment2/segment2_cn.16EE0.ia1.png": [16,8,16,{"cn":[947456,93920]}], +"textures/segment2/segment2_cn.16EF0.ia1.png": [16,8,16,{"cn":[947456,93936]}], +"textures/segment2/segment2_cn.16F00.ia1.png": [16,8,16,{"cn":[947456,93952]}], +"textures/segment2/segment2_cn.16F10.ia1.png": [16,8,16,{"cn":[947456,93968]}], +"textures/segment2/segment2_cn.16F20.ia1.png": [16,8,16,{"cn":[947456,93984]}], +"textures/segment2/segment2_cn.16F30.ia1.png": [16,8,16,{"cn":[947456,94000]}], +"textures/segment2/segment2_cn.16F40.ia1.png": [16,8,16,{"cn":[947456,94016]}], +"textures/segment2/segment2_cn.16F50.ia1.png": [16,8,16,{"cn":[947456,94032]}], +"textures/segment2/segment2_cn.16F60.ia1.png": [16,8,16,{"cn":[947456,94048]}], +"textures/segment2/segment2_cn.16F70.ia1.png": [16,8,16,{"cn":[947456,94064]}], +"textures/segment2/segment2_cn.16F80.ia1.png": [16,8,16,{"cn":[947456,94080]}], +"textures/segment2/segment2_cn.16F90.ia1.png": [16,8,16,{"cn":[947456,94096]}], +"textures/segment2/segment2_cn.16FA0.ia1.png": [16,8,16,{"cn":[947456,94112]}], +"textures/segment2/segment2_cn.16FB0.ia1.png": [16,8,16,{"cn":[947456,94128]}], +"textures/segment2/segment2_cn.16FC0.ia1.png": [16,8,16,{"cn":[947456,94144]}], +"textures/segment2/segment2_cn.16FD0.ia1.png": [16,8,16,{"cn":[947456,94160]}], +"textures/segment2/segment2_cn.16FE0.ia1.png": [16,8,16,{"cn":[947456,94176]}], +"textures/segment2/segment2_cn.16FF0.ia1.png": [16,8,16,{"cn":[947456,94192]}], +"textures/segment2/segment2_cn.17000.ia1.png": [16,8,16,{"cn":[947456,94208]}], +"textures/segment2/segment2_cn.17010.ia1.png": [16,8,16,{"cn":[947456,94224]}], +"textures/segment2/segment2_cn.17020.ia1.png": [16,8,16,{"cn":[947456,94240]}], +"textures/segment2/segment2_cn.17030.ia1.png": [16,8,16,{"cn":[947456,94256]}], +"textures/segment2/segment2_cn.17040.ia1.png": [16,8,16,{"cn":[947456,94272]}], +"textures/segment2/segment2_cn.17050.ia1.png": [16,8,16,{"cn":[947456,94288]}], +"textures/segment2/segment2_cn.17060.ia1.png": [16,8,16,{"cn":[947456,94304]}], +"textures/segment2/segment2_cn.17070.ia1.png": [16,8,16,{"cn":[947456,94320]}], +"textures/segment2/segment2_cn.17080.ia1.png": [16,8,16,{"cn":[947456,94336]}], +"textures/segment2/segment2_cn.17090.ia1.png": [16,8,16,{"cn":[947456,94352]}], +"textures/segment2/segment2_cn.170A0.ia1.png": [16,8,16,{"cn":[947456,94368]}], +"textures/segment2/segment2_cn.170B0.ia1.png": [16,8,16,{"cn":[947456,94384]}], +"textures/segment2/segment2_cn.170C0.ia1.png": [16,8,16,{"cn":[947456,94400]}], +"textures/segment2/segment2_cn.170D0.ia1.png": [16,8,16,{"cn":[947456,94416]}], +"textures/segment2/segment2_cn.170E0.ia1.png": [16,8,16,{"cn":[947456,94432]}], +"textures/segment2/segment2_cn.170F0.ia1.png": [16,8,16,{"cn":[947456,94448]}], +"textures/segment2/segment2_cn.17100.ia1.png": [16,8,16,{"cn":[947456,94464]}], +"textures/segment2/segment2_cn.17110.ia1.png": [16,8,16,{"cn":[947456,94480]}], +"textures/segment2/segment2_cn.17120.ia1.png": [16,8,16,{"cn":[947456,94496]}], +"textures/segment2/segment2_cn.17130.ia1.png": [16,8,16,{"cn":[947456,94512]}], +"textures/segment2/segment2_cn.17140.ia1.png": [16,8,16,{"cn":[947456,94528]}], +"textures/segment2/segment2_cn.17150.ia1.png": [16,8,16,{"cn":[947456,94544]}], +"textures/segment2/segment2_cn.17160.ia1.png": [16,8,16,{"cn":[947456,94560]}], +"textures/segment2/segment2_cn.17170.ia1.png": [16,8,16,{"cn":[947456,94576]}], +"textures/segment2/segment2_cn.17180.ia1.png": [16,8,16,{"cn":[947456,94592]}], +"textures/segment2/segment2_cn.17190.ia1.png": [16,8,16,{"cn":[947456,94608]}], +"textures/segment2/segment2_cn.171A0.ia1.png": [16,8,16,{"cn":[947456,94624]}], +"textures/segment2/segment2_cn.171B0.ia1.png": [16,8,16,{"cn":[947456,94640]}], +"textures/segment2/segment2_cn.171C0.ia1.png": [16,8,16,{"cn":[947456,94656]}], +"textures/segment2/segment2_cn.171D0.ia1.png": [16,8,16,{"cn":[947456,94672]}], +"textures/segment2/segment2_cn.171E0.ia1.png": [16,8,16,{"cn":[947456,94688]}], +"textures/segment2/segment2_cn.171F0.ia1.png": [16,8,16,{"cn":[947456,94704]}], +"textures/segment2/segment2_cn.17200.ia1.png": [16,8,16,{"cn":[947456,94720]}], +"textures/segment2/segment2_cn.17210.ia1.png": [16,8,16,{"cn":[947456,94736]}], +"textures/segment2/segment2_cn.17220.ia1.png": [16,8,16,{"cn":[947456,94752]}], +"textures/segment2/segment2_cn.17230.ia1.png": [16,8,16,{"cn":[947456,94768]}], +"textures/segment2/segment2_cn.17240.ia1.png": [16,8,16,{"cn":[947456,94784]}], +"textures/segment2/segment2_cn.17250.ia1.png": [16,8,16,{"cn":[947456,94800]}], +"textures/segment2/segment2_cn.17260.ia1.png": [16,8,16,{"cn":[947456,94816]}], +"textures/segment2/segment2_cn.17270.ia1.png": [16,8,16,{"cn":[947456,94832]}], +"textures/segment2/segment2_cn.17280.ia1.png": [16,8,16,{"cn":[947456,94848]}], +"textures/segment2/segment2_cn.17290.ia1.png": [16,8,16,{"cn":[947456,94864]}], +"textures/segment2/segment2_cn.172A0.ia1.png": [16,8,16,{"cn":[947456,94880]}], +"textures/segment2/segment2_cn.172B0.ia1.png": [16,8,16,{"cn":[947456,94896]}], +"textures/segment2/segment2_cn.172C0.ia1.png": [16,8,16,{"cn":[947456,94912]}], +"textures/segment2/segment2_cn.172D0.ia1.png": [16,8,16,{"cn":[947456,94928]}], +"textures/segment2/segment2_cn.172E0.ia1.png": [16,8,16,{"cn":[947456,94944]}], +"textures/segment2/segment2_cn.172F0.ia1.png": [16,8,16,{"cn":[947456,94960]}], +"textures/segment2/segment2_cn.17300.ia1.png": [16,8,16,{"cn":[947456,94976]}], +"textures/segment2/segment2_cn.17310.ia1.png": [16,8,16,{"cn":[947456,94992]}], +"textures/segment2/segment2_cn.17320.ia1.png": [16,8,16,{"cn":[947456,95008]}], +"textures/segment2/segment2_cn.17330.ia1.png": [16,8,16,{"cn":[947456,95024]}], +"textures/segment2/segment2_cn.17340.ia1.png": [16,8,16,{"cn":[947456,95040]}], +"textures/segment2/segment2_cn.17350.ia1.png": [16,8,16,{"cn":[947456,95056]}], +"textures/segment2/segment2_cn.17360.ia1.png": [16,8,16,{"cn":[947456,95072]}], +"textures/segment2/segment2_cn.17370.ia1.png": [16,8,16,{"cn":[947456,95088]}], +"textures/segment2/segment2_cn.17380.ia1.png": [16,8,16,{"cn":[947456,95104]}], +"textures/segment2/segment2_cn.17390.ia1.png": [16,8,16,{"cn":[947456,95120]}], +"textures/segment2/segment2_cn.173A0.ia1.png": [16,8,16,{"cn":[947456,95136]}], +"textures/segment2/segment2_cn.173B0.ia1.png": [16,8,16,{"cn":[947456,95152]}], +"textures/segment2/segment2_cn.173C0.ia1.png": [16,8,16,{"cn":[947456,95168]}], +"textures/segment2/segment2_cn.173D0.ia1.png": [16,8,16,{"cn":[947456,95184]}], +"textures/segment2/segment2_cn.173E0.ia1.png": [16,8,16,{"cn":[947456,95200]}], +"textures/segment2/segment2_cn.173F0.ia1.png": [16,8,16,{"cn":[947456,95216]}], +"textures/segment2/segment2_cn.17400.ia1.png": [16,8,16,{"cn":[947456,95232]}], +"textures/segment2/segment2_cn.17410.ia1.png": [16,8,16,{"cn":[947456,95248]}], +"textures/segment2/segment2_cn.17420.ia1.png": [16,8,16,{"cn":[947456,95264]}], +"textures/segment2/segment2_cn.17430.ia1.png": [16,8,16,{"cn":[947456,95280]}], +"textures/segment2/segment2_cn.17440.ia1.png": [16,8,16,{"cn":[947456,95296]}], +"textures/segment2/segment2_cn.17450.ia1.png": [16,8,16,{"cn":[947456,95312]}], +"textures/segment2/segment2_cn.17460.ia1.png": [16,8,16,{"cn":[947456,95328]}], +"textures/segment2/segment2_cn.17470.ia1.png": [16,8,16,{"cn":[947456,95344]}], +"textures/segment2/segment2_cn.17480.ia1.png": [16,8,16,{"cn":[947456,95360]}], +"textures/segment2/segment2_cn.17490.ia1.png": [16,8,16,{"cn":[947456,95376]}], +"textures/segment2/segment2_cn.174A0.ia1.png": [16,8,16,{"cn":[947456,95392]}], +"textures/segment2/segment2_cn.174B0.ia1.png": [16,8,16,{"cn":[947456,95408]}], +"textures/segment2/segment2_cn.174C0.ia1.png": [16,8,16,{"cn":[947456,95424]}], +"textures/segment2/segment2_cn.174D0.ia1.png": [16,8,16,{"cn":[947456,95440]}], +"textures/segment2/segment2_cn.174E0.ia1.png": [16,8,16,{"cn":[947456,95456]}], +"textures/segment2/segment2_cn.174F0.ia1.png": [16,8,16,{"cn":[947456,95472]}], +"textures/segment2/segment2_cn.17500.ia1.png": [16,8,16,{"cn":[947456,95488]}], +"textures/segment2/segment2_cn.17510.ia1.png": [16,8,16,{"cn":[947456,95504]}], +"textures/segment2/segment2_cn.17520.ia1.png": [16,8,16,{"cn":[947456,95520]}], +"textures/segment2/segment2_cn.17530.ia1.png": [16,8,16,{"cn":[947456,95536]}], +"textures/segment2/segment2_cn.17540.ia1.png": [16,8,16,{"cn":[947456,95552]}], +"textures/segment2/segment2_cn.17550.ia1.png": [16,8,16,{"cn":[947456,95568]}], +"textures/segment2/segment2_cn.17560.ia1.png": [16,8,16,{"cn":[947456,95584]}], +"textures/segment2/segment2_cn.17570.ia1.png": [16,8,16,{"cn":[947456,95600]}], +"textures/segment2/segment2_cn.17580.ia1.png": [16,8,16,{"cn":[947456,95616]}], +"textures/segment2/segment2_cn.17590.ia1.png": [16,8,16,{"cn":[947456,95632]}], +"textures/segment2/segment2_cn.175A0.ia1.png": [16,8,16,{"cn":[947456,95648]}], +"textures/segment2/segment2_cn.175B0.ia1.png": [16,8,16,{"cn":[947456,95664]}], +"textures/segment2/segment2_cn.175C0.ia1.png": [16,8,16,{"cn":[947456,95680]}], +"textures/segment2/segment2_cn.175D0.ia1.png": [16,8,16,{"cn":[947456,95696]}], +"textures/segment2/segment2_cn.175E0.ia1.png": [16,8,16,{"cn":[947456,95712]}], +"textures/segment2/segment2_cn.175F0.ia1.png": [16,8,16,{"cn":[947456,95728]}], +"textures/segment2/segment2_cn.17600.ia1.png": [16,8,16,{"cn":[947456,95744]}], +"textures/segment2/segment2_cn.17610.ia1.png": [16,8,16,{"cn":[947456,95760]}], +"textures/segment2/segment2_cn.17620.ia1.png": [16,8,16,{"cn":[947456,95776]}], +"textures/segment2/segment2_cn.17630.ia1.png": [16,8,16,{"cn":[947456,95792]}], +"textures/segment2/segment2_cn.17640.ia1.png": [16,8,16,{"cn":[947456,95808]}], +"textures/segment2/segment2_cn.17650.ia1.png": [16,8,16,{"cn":[947456,95824]}], +"textures/segment2/segment2_cn.17660.ia1.png": [16,8,16,{"cn":[947456,95840]}], +"textures/segment2/segment2_cn.17670.ia1.png": [16,8,16,{"cn":[947456,95856]}], +"textures/segment2/segment2_cn.17680.ia1.png": [16,8,16,{"cn":[947456,95872]}], +"textures/segment2/segment2_cn.17690.ia1.png": [16,8,16,{"cn":[947456,95888]}], +"textures/segment2/segment2_cn.176A0.ia1.png": [16,8,16,{"cn":[947456,95904]}], +"textures/segment2/segment2_cn.176B0.ia1.png": [16,8,16,{"cn":[947456,95920]}], +"textures/segment2/segment2_cn.176C0.ia1.png": [16,8,16,{"cn":[947456,95936]}], +"textures/segment2/segment2_cn.176D0.ia1.png": [16,8,16,{"cn":[947456,95952]}], +"textures/segment2/segment2_cn.176E0.ia1.png": [16,8,16,{"cn":[947456,95968]}], +"textures/segment2/segment2_cn.176F0.ia1.png": [16,8,16,{"cn":[947456,95984]}], +"textures/segment2/segment2_cn.17700.ia1.png": [16,8,16,{"cn":[947456,96000]}], +"textures/segment2/segment2_cn.17710.ia1.png": [16,8,16,{"cn":[947456,96016]}], +"textures/segment2/segment2_cn.17720.ia1.png": [16,8,16,{"cn":[947456,96032]}], +"textures/segment2/segment2_cn.17730.ia1.png": [16,8,16,{"cn":[947456,96048]}], +"textures/segment2/segment2_cn.17740.ia1.png": [16,8,16,{"cn":[947456,96064]}], +"textures/segment2/segment2_cn.17750.ia1.png": [16,8,16,{"cn":[947456,96080]}], +"textures/segment2/segment2_cn.17760.ia1.png": [16,8,16,{"cn":[947456,96096]}], +"textures/segment2/segment2_cn.17770.ia1.png": [16,8,16,{"cn":[947456,96112]}], +"textures/segment2/segment2_cn.17780.ia1.png": [16,8,16,{"cn":[947456,96128]}], +"textures/segment2/segment2_cn.17790.ia1.png": [16,8,16,{"cn":[947456,96144]}], +"textures/segment2/segment2_cn.177A0.ia1.png": [16,8,16,{"cn":[947456,96160]}], +"textures/segment2/segment2_cn.177B0.ia1.png": [16,8,16,{"cn":[947456,96176]}], +"textures/segment2/segment2_cn.177C0.ia1.png": [16,8,16,{"cn":[947456,96192]}], +"textures/segment2/segment2_cn.177D0.ia1.png": [16,8,16,{"cn":[947456,96208]}], +"textures/segment2/segment2_cn.177E0.ia1.png": [16,8,16,{"cn":[947456,96224]}], +"textures/segment2/segment2_cn.177F0.ia1.png": [16,8,16,{"cn":[947456,96240]}], +"textures/segment2/segment2_cn.17800.ia1.png": [16,8,16,{"cn":[947456,96256]}], +"textures/segment2/segment2_cn.17810.ia1.png": [16,8,16,{"cn":[947456,96272]}], +"textures/segment2/segment2_cn.17820.ia1.png": [16,8,16,{"cn":[947456,96288]}], +"textures/segment2/segment2_cn.17830.ia1.png": [16,8,16,{"cn":[947456,96304]}], +"textures/segment2/segment2_cn.17840.ia1.png": [16,8,16,{"cn":[947456,96320]}], +"textures/segment2/segment2_cn.17850.ia1.png": [16,8,16,{"cn":[947456,96336]}], +"textures/segment2/segment2_cn.17860.ia1.png": [16,8,16,{"cn":[947456,96352]}], +"textures/segment2/segment2_cn.17870.ia1.png": [16,8,16,{"cn":[947456,96368]}], +"textures/segment2/segment2_cn.17880.ia1.png": [16,8,16,{"cn":[947456,96384]}], +"textures/segment2/segment2_cn.17890.ia1.png": [16,8,16,{"cn":[947456,96400]}], +"textures/segment2/segment2_cn.178A0.ia1.png": [16,8,16,{"cn":[947456,96416]}], +"textures/segment2/segment2_cn.178B0.ia1.png": [16,8,16,{"cn":[947456,96432]}], +"textures/segment2/segment2_cn.178C0.ia1.png": [16,8,16,{"cn":[947456,96448]}], +"textures/segment2/segment2_cn.178D0.ia1.png": [16,8,16,{"cn":[947456,96464]}], +"textures/segment2/segment2_cn.178E0.ia1.png": [16,8,16,{"cn":[947456,96480]}], +"textures/segment2/segment2_cn.178F0.ia1.png": [16,8,16,{"cn":[947456,96496]}], +"textures/segment2/segment2_cn.17900.ia1.png": [16,8,16,{"cn":[947456,96512]}], +"textures/segment2/segment2_cn.17910.ia1.png": [16,8,16,{"cn":[947456,96528]}], +"textures/segment2/segment2_cn.17920.ia1.png": [16,8,16,{"cn":[947456,96544]}], +"textures/segment2/segment2_cn.17930.ia1.png": [16,8,16,{"cn":[947456,96560]}], +"textures/segment2/segment2_cn.17940.ia1.png": [16,8,16,{"cn":[947456,96576]}], +"textures/segment2/segment2_cn.17950.ia1.png": [16,8,16,{"cn":[947456,96592]}], +"textures/segment2/segment2_cn.17960.ia1.png": [16,8,16,{"cn":[947456,96608]}], +"textures/segment2/segment2_cn.17970.ia1.png": [16,8,16,{"cn":[947456,96624]}], +"textures/segment2/segment2_cn.17980.ia1.png": [16,8,16,{"cn":[947456,96640]}], +"textures/segment2/segment2_cn.17990.ia1.png": [16,8,16,{"cn":[947456,96656]}], +"textures/segment2/segment2_cn.179A0.ia1.png": [16,8,16,{"cn":[947456,96672]}], +"textures/segment2/segment2_cn.179B0.ia1.png": [16,8,16,{"cn":[947456,96688]}], +"textures/segment2/segment2_cn.179C0.ia1.png": [16,8,16,{"cn":[947456,96704]}], +"textures/segment2/segment2_cn.179D0.ia1.png": [16,8,16,{"cn":[947456,96720]}], +"textures/segment2/segment2_cn.179E0.ia1.png": [16,8,16,{"cn":[947456,96736]}], +"textures/segment2/segment2_cn.179F0.ia1.png": [16,8,16,{"cn":[947456,96752]}], +"textures/segment2/segment2_cn.17A00.ia1.png": [16,8,16,{"cn":[947456,96768]}], +"textures/segment2/segment2_cn.17A10.ia1.png": [16,8,16,{"cn":[947456,96784]}], +"textures/segment2/segment2_cn.17A20.ia1.png": [16,8,16,{"cn":[947456,96800]}], +"textures/segment2/segment2_cn.17A30.ia1.png": [16,8,16,{"cn":[947456,96816]}], +"textures/segment2/segment2_cn.17A40.ia1.png": [16,8,16,{"cn":[947456,96832]}], +"textures/segment2/segment2_cn.17A50.ia1.png": [16,8,16,{"cn":[947456,96848]}], +"textures/segment2/segment2_cn.17A60.ia1.png": [16,8,16,{"cn":[947456,96864]}], +"textures/segment2/segment2_cn.17A70.ia1.png": [16,8,16,{"cn":[947456,96880]}], +"textures/segment2/segment2_cn.17A80.ia1.png": [16,8,16,{"cn":[947456,96896]}], +"textures/segment2/segment2_cn.17A90.ia1.png": [16,8,16,{"cn":[947456,96912]}], +"textures/segment2/segment2_cn.17AA0.ia1.png": [16,8,16,{"cn":[947456,96928]}], +"textures/segment2/segment2_cn.17AB0.ia1.png": [16,8,16,{"cn":[947456,96944]}], +"textures/segment2/segment2_cn.17AC0.ia1.png": [16,8,16,{"cn":[947456,96960]}], +"textures/segment2/segment2_cn.17AD0.ia1.png": [16,8,16,{"cn":[947456,96976]}], +"textures/segment2/segment2_cn.17AE0.ia1.png": [16,8,16,{"cn":[947456,96992]}], +"textures/segment2/segment2_cn.17AF0.ia1.png": [16,8,16,{"cn":[947456,97008]}], +"textures/segment2/segment2_cn.17B00.ia1.png": [16,8,16,{"cn":[947456,97024]}], +"textures/segment2/segment2_cn.17B10.ia1.png": [16,8,16,{"cn":[947456,97040]}], +"textures/segment2/segment2_cn.17B20.ia1.png": [16,8,16,{"cn":[947456,97056]}], +"textures/segment2/segment2_cn.17B30.ia1.png": [16,8,16,{"cn":[947456,97072]}], +"textures/segment2/segment2_cn.17B40.ia1.png": [16,8,16,{"cn":[947456,97088]}], +"textures/segment2/segment2_cn.17B50.ia1.png": [16,8,16,{"cn":[947456,97104]}], +"textures/segment2/segment2_cn.17B60.ia1.png": [16,8,16,{"cn":[947456,97120]}], +"textures/segment2/segment2_cn.17B70.ia1.png": [16,8,16,{"cn":[947456,97136]}], +"textures/segment2/segment2_cn.17B80.ia1.png": [16,8,16,{"cn":[947456,97152]}], +"textures/segment2/segment2_cn.17B90.ia1.png": [16,8,16,{"cn":[947456,97168]}], +"textures/segment2/segment2_cn.17BA0.ia1.png": [16,8,16,{"cn":[947456,97184]}], +"textures/segment2/segment2_cn.17BB0.ia1.png": [16,8,16,{"cn":[947456,97200]}], +"textures/segment2/segment2_cn.17BC0.ia1.png": [16,8,16,{"cn":[947456,97216]}], +"textures/segment2/segment2_cn.17BD0.ia1.png": [16,8,16,{"cn":[947456,97232]}], +"textures/segment2/segment2_cn.17BE0.ia1.png": [16,8,16,{"cn":[947456,97248]}], +"textures/segment2/segment2_cn.17BF0.ia1.png": [16,8,16,{"cn":[947456,97264]}], +"textures/segment2/segment2_cn.17C00.ia1.png": [16,8,16,{"cn":[947456,97280]}], +"textures/segment2/segment2_cn.17C10.ia1.png": [16,8,16,{"cn":[947456,97296]}], +"textures/segment2/segment2_cn.17C20.ia1.png": [16,8,16,{"cn":[947456,97312]}], +"textures/segment2/segment2_cn.17C30.ia1.png": [16,8,16,{"cn":[947456,97328]}], +"textures/segment2/segment2_cn.17C40.ia1.png": [16,8,16,{"cn":[947456,97344]}], +"textures/segment2/segment2_cn.17C50.ia1.png": [16,8,16,{"cn":[947456,97360]}], +"textures/segment2/segment2_cn.17C60.ia1.png": [16,8,16,{"cn":[947456,97376]}], +"textures/segment2/segment2_cn.17C70.ia1.png": [16,8,16,{"cn":[947456,97392]}], +"textures/segment2/segment2_cn.17C80.ia1.png": [16,8,16,{"cn":[947456,97408]}], +"textures/segment2/segment2_cn.17C90.ia1.png": [16,8,16,{"cn":[947456,97424]}], +"textures/segment2/segment2_cn.17CA0.ia1.png": [16,8,16,{"cn":[947456,97440]}], +"textures/segment2/segment2_cn.17CB0.ia1.png": [16,8,16,{"cn":[947456,97456]}], +"textures/segment2/segment2_cn.17CC0.ia1.png": [16,8,16,{"cn":[947456,97472]}], +"textures/segment2/segment2_cn.17CD0.ia1.png": [16,8,16,{"cn":[947456,97488]}], +"textures/segment2/segment2_cn.17CE0.ia1.png": [16,8,16,{"cn":[947456,97504]}], +"textures/segment2/segment2_cn.17CF0.ia1.png": [16,8,16,{"cn":[947456,97520]}], +"textures/segment2/segment2_cn.17D00.ia1.png": [16,8,16,{"cn":[947456,97536]}], +"textures/segment2/segment2_cn.17D10.ia1.png": [16,8,16,{"cn":[947456,97552]}], +"textures/segment2/segment2_cn.17D20.ia1.png": [16,8,16,{"cn":[947456,97568]}], +"textures/segment2/segment2_cn.17D30.ia1.png": [16,8,16,{"cn":[947456,97584]}], +"textures/segment2/segment2_cn.17D40.ia1.png": [16,8,16,{"cn":[947456,97600]}], +"textures/segment2/segment2_cn.17D50.ia1.png": [16,8,16,{"cn":[947456,97616]}], +"textures/segment2/segment2_cn.17D60.ia1.png": [16,8,16,{"cn":[947456,97632]}], +"textures/segment2/segment2_cn.17D70.ia1.png": [16,8,16,{"cn":[947456,97648]}], +"textures/segment2/segment2_cn.17D80.ia1.png": [16,8,16,{"cn":[947456,97664]}], +"textures/segment2/segment2_cn.17D90.ia1.png": [16,8,16,{"cn":[947456,97680]}], +"textures/segment2/segment2_cn.17DA0.ia1.png": [16,8,16,{"cn":[947456,97696]}], +"textures/segment2/segment2_cn.17DB0.ia1.png": [16,8,16,{"cn":[947456,97712]}], +"textures/segment2/segment2_cn.17DC0.ia1.png": [16,8,16,{"cn":[947456,97728]}], +"textures/segment2/segment2_cn.17DD0.ia1.png": [16,8,16,{"cn":[947456,97744]}], +"textures/segment2/segment2_cn.17DE0.ia1.png": [16,8,16,{"cn":[947456,97760]}], +"textures/segment2/segment2_cn.17DF0.ia1.png": [16,8,16,{"cn":[947456,97776]}], +"textures/segment2/segment2_cn.17E00.ia1.png": [16,8,16,{"cn":[947456,97792]}], +"textures/segment2/segment2_cn.17E10.ia1.png": [16,8,16,{"cn":[947456,97808]}], +"textures/segment2/segment2_cn.17E20.ia1.png": [16,8,16,{"cn":[947456,97824]}], +"textures/segment2/segment2_cn.17E30.ia1.png": [16,8,16,{"cn":[947456,97840]}], +"textures/segment2/segment2_cn.17E40.ia1.png": [16,8,16,{"cn":[947456,97856]}], +"textures/segment2/segment2_cn.17E50.ia1.png": [16,8,16,{"cn":[947456,97872]}], +"textures/segment2/segment2_cn.17E60.ia1.png": [16,8,16,{"cn":[947456,97888]}], +"textures/segment2/segment2_cn.17E70.ia1.png": [16,8,16,{"cn":[947456,97904]}], +"textures/segment2/segment2_cn.17E80.ia1.png": [16,8,16,{"cn":[947456,97920]}], +"textures/segment2/segment2_cn.17E90.ia1.png": [16,8,16,{"cn":[947456,97936]}], +"textures/segment2/segment2_cn.17EA0.ia1.png": [16,8,16,{"cn":[947456,97952]}], +"textures/segment2/segment2_cn.17EB0.ia1.png": [16,8,16,{"cn":[947456,97968]}], +"textures/segment2/segment2_cn.17EC0.ia1.png": [16,8,16,{"cn":[947456,97984]}], +"textures/segment2/segment2_cn.17ED0.ia1.png": [16,8,16,{"cn":[947456,98000]}], +"textures/segment2/segment2_cn.17EE0.ia1.png": [16,8,16,{"cn":[947456,98016]}], +"textures/segment2/segment2_cn.17EF0.ia1.png": [16,8,16,{"cn":[947456,98032]}], +"textures/segment2/segment2_cn.17F00.ia1.png": [16,8,16,{"cn":[947456,98048]}], +"textures/segment2/segment2_cn.17F10.ia1.png": [16,8,16,{"cn":[947456,98064]}], +"textures/segment2/segment2_cn.17F20.ia1.png": [16,8,16,{"cn":[947456,98080]}], +"textures/segment2/segment2_cn.17F30.ia1.png": [16,8,16,{"cn":[947456,98096]}], +"textures/segment2/segment2_cn.17F40.ia1.png": [16,8,16,{"cn":[947456,98112]}], +"textures/segment2/segment2_cn.17F50.ia1.png": [16,8,16,{"cn":[947456,98128]}], +"textures/segment2/segment2_cn.17F60.ia1.png": [16,8,16,{"cn":[947456,98144]}], +"textures/segment2/segment2_cn.17F70.ia1.png": [16,8,16,{"cn":[947456,98160]}], +"textures/segment2/segment2_cn.17F80.ia1.png": [16,8,16,{"cn":[947456,98176]}], +"textures/segment2/segment2_cn.17F90.ia1.png": [16,8,16,{"cn":[947456,98192]}], +"textures/segment2/segment2_cn.17FA0.ia1.png": [16,8,16,{"cn":[947456,98208]}], +"textures/segment2/segment2_cn.17FB0.ia1.png": [16,8,16,{"cn":[947456,98224]}], +"textures/segment2/segment2_cn.17FC0.ia1.png": [16,8,16,{"cn":[947456,98240]}], +"textures/segment2/segment2_cn.17FD0.ia1.png": [16,8,16,{"cn":[947456,98256]}], +"textures/segment2/segment2_cn.17FE0.ia1.png": [16,8,16,{"cn":[947456,98272]}], +"textures/segment2/segment2_cn.17FF0.ia1.png": [16,8,16,{"cn":[947456,98288]}], +"textures/segment2/segment2_cn.18000.ia1.png": [16,8,16,{"cn":[947456,98304]}], +"textures/segment2/segment2_cn.18010.ia1.png": [16,8,16,{"cn":[947456,98320]}], +"textures/segment2/segment2_cn.18020.ia1.png": [16,8,16,{"cn":[947456,98336]}], +"textures/segment2/segment2_cn.18030.ia1.png": [16,8,16,{"cn":[947456,98352]}], +"textures/segment2/segment2_cn.18040.ia1.png": [16,8,16,{"cn":[947456,98368]}], +"textures/segment2/segment2_cn.18050.ia1.png": [16,8,16,{"cn":[947456,98384]}], +"textures/segment2/segment2_cn.18060.ia1.png": [16,8,16,{"cn":[947456,98400]}], +"textures/segment2/segment2_cn.18070.ia1.png": [16,8,16,{"cn":[947456,98416]}], +"textures/segment2/segment2_cn.18080.ia1.png": [16,8,16,{"cn":[947456,98432]}], +"textures/segment2/segment2_cn.18090.ia1.png": [16,8,16,{"cn":[947456,98448]}], +"textures/segment2/segment2_cn.180A0.ia1.png": [16,8,16,{"cn":[947456,98464]}], +"textures/segment2/segment2_cn.180B0.ia1.png": [16,8,16,{"cn":[947456,98480]}], +"textures/segment2/segment2_cn.180C0.ia1.png": [16,8,16,{"cn":[947456,98496]}], +"textures/segment2/segment2_cn.180D0.ia1.png": [16,8,16,{"cn":[947456,98512]}], +"textures/segment2/segment2_cn.180E0.ia1.png": [16,8,16,{"cn":[947456,98528]}], +"textures/segment2/segment2_cn.180F0.ia1.png": [16,8,16,{"cn":[947456,98544]}], +"textures/segment2/segment2_cn.18100.ia1.png": [16,8,16,{"cn":[947456,98560]}], +"textures/segment2/segment2_cn.18110.ia1.png": [16,8,16,{"cn":[947456,98576]}], +"textures/segment2/segment2_cn.18120.ia1.png": [16,8,16,{"cn":[947456,98592]}], +"textures/segment2/segment2_cn.18130.ia1.png": [16,8,16,{"cn":[947456,98608]}], +"textures/segment2/segment2_cn.18140.ia1.png": [16,8,16,{"cn":[947456,98624]}], +"textures/segment2/segment2_cn.18150.ia1.png": [16,8,16,{"cn":[947456,98640]}], +"textures/segment2/segment2_cn.18160.ia1.png": [16,8,16,{"cn":[947456,98656]}], +"textures/segment2/segment2_cn.18170.ia1.png": [16,8,16,{"cn":[947456,98672]}], +"textures/segment2/segment2_cn.18180.ia1.png": [16,8,16,{"cn":[947456,98688]}], +"textures/segment2/segment2_cn.18190.ia1.png": [16,8,16,{"cn":[947456,98704]}], +"textures/segment2/segment2_cn.181A0.ia1.png": [16,8,16,{"cn":[947456,98720]}], +"textures/segment2/segment2_cn.181B0.ia1.png": [16,8,16,{"cn":[947456,98736]}], +"textures/segment2/segment2_cn.181C0.ia1.png": [16,8,16,{"cn":[947456,98752]}], +"textures/segment2/segment2_cn.181D0.ia1.png": [16,8,16,{"cn":[947456,98768]}], +"textures/segment2/segment2_cn.181E0.ia1.png": [16,8,16,{"cn":[947456,98784]}], +"textures/segment2/segment2_cn.181F0.ia1.png": [16,8,16,{"cn":[947456,98800]}], +"textures/segment2/segment2_cn.18200.ia1.png": [16,8,16,{"cn":[947456,98816]}], +"textures/segment2/segment2_cn.18210.ia1.png": [16,8,16,{"cn":[947456,98832]}], +"textures/segment2/segment2_cn.18220.ia1.png": [16,8,16,{"cn":[947456,98848]}], +"textures/segment2/segment2_cn.18230.ia1.png": [16,8,16,{"cn":[947456,98864]}], +"textures/segment2/segment2_cn.18240.ia1.png": [16,8,16,{"cn":[947456,98880]}], +"textures/segment2/segment2_cn.18250.ia1.png": [16,8,16,{"cn":[947456,98896]}], +"textures/segment2/segment2_cn.18260.ia1.png": [16,8,16,{"cn":[947456,98912]}], +"textures/segment2/segment2_cn.18270.ia1.png": [16,8,16,{"cn":[947456,98928]}], +"textures/segment2/segment2_cn.18280.ia1.png": [16,8,16,{"cn":[947456,98944]}], +"textures/segment2/segment2_cn.18290.ia1.png": [16,8,16,{"cn":[947456,98960]}], +"textures/segment2/segment2_cn.182A0.ia1.png": [16,8,16,{"cn":[947456,98976]}], +"textures/segment2/segment2_cn.182B0.ia1.png": [16,8,16,{"cn":[947456,98992]}], +"textures/segment2/segment2_cn.182C0.ia1.png": [16,8,16,{"cn":[947456,99008]}], +"textures/segment2/segment2_cn.182D0.ia1.png": [16,8,16,{"cn":[947456,99024]}], +"textures/segment2/segment2_cn.182E0.ia1.png": [16,8,16,{"cn":[947456,99040]}], +"textures/segment2/segment2_cn.182F0.ia1.png": [16,8,16,{"cn":[947456,99056]}], +"textures/segment2/segment2_cn.18300.ia1.png": [16,8,16,{"cn":[947456,99072]}], +"textures/segment2/segment2_cn.18310.ia1.png": [16,8,16,{"cn":[947456,99088]}], +"textures/segment2/segment2_cn.18320.ia1.png": [16,8,16,{"cn":[947456,99104]}], +"textures/segment2/segment2_cn.18330.ia1.png": [16,8,16,{"cn":[947456,99120]}], +"textures/segment2/segment2_cn.18340.ia1.png": [16,8,16,{"cn":[947456,99136]}], +"textures/segment2/segment2_cn.18350.ia1.png": [16,8,16,{"cn":[947456,99152]}], +"textures/segment2/segment2_cn.18360.ia1.png": [16,8,16,{"cn":[947456,99168]}], +"textures/segment2/segment2_cn.18370.ia1.png": [16,8,16,{"cn":[947456,99184]}], +"textures/segment2/segment2_cn.18380.ia1.png": [16,8,16,{"cn":[947456,99200]}], +"textures/segment2/segment2_cn.18390.ia1.png": [16,8,16,{"cn":[947456,99216]}], +"textures/segment2/segment2_cn.183A0.ia1.png": [16,8,16,{"cn":[947456,99232]}], +"textures/segment2/segment2_cn.183B0.ia1.png": [16,8,16,{"cn":[947456,99248]}], +"textures/segment2/segment2_cn.183C0.ia1.png": [16,8,16,{"cn":[947456,99264]}], +"textures/segment2/segment2_cn.183D0.ia1.png": [16,8,16,{"cn":[947456,99280]}], +"textures/segment2/segment2_cn.183E0.ia1.png": [16,8,16,{"cn":[947456,99296]}], +"textures/segment2/segment2_cn.183F0.ia1.png": [16,8,16,{"cn":[947456,99312]}], +"textures/segment2/segment2_cn.18400.ia1.png": [16,8,16,{"cn":[947456,99328]}], +"textures/segment2/segment2_cn.18410.ia1.png": [16,8,16,{"cn":[947456,99344]}], +"textures/segment2/segment2_cn.18420.ia1.png": [16,8,16,{"cn":[947456,99360]}], +"textures/segment2/segment2_cn.18430.ia1.png": [16,8,16,{"cn":[947456,99376]}], +"textures/segment2/segment2_cn.18440.ia1.png": [16,8,16,{"cn":[947456,99392]}], +"textures/segment2/segment2_cn.18450.ia1.png": [16,8,16,{"cn":[947456,99408]}], +"textures/segment2/segment2_cn.18460.ia1.png": [16,8,16,{"cn":[947456,99424]}], +"textures/segment2/segment2_cn.18470.ia1.png": [16,8,16,{"cn":[947456,99440]}], +"textures/segment2/segment2_cn.18480.ia1.png": [16,8,16,{"cn":[947456,99456]}], +"textures/segment2/segment2_cn.18490.ia1.png": [16,8,16,{"cn":[947456,99472]}], +"textures/segment2/segment2_cn.184A0.ia1.png": [16,8,16,{"cn":[947456,99488]}], +"textures/segment2/segment2_cn.184B0.ia1.png": [16,8,16,{"cn":[947456,99504]}], +"textures/segment2/segment2_cn.184C0.ia1.png": [16,8,16,{"cn":[947456,99520]}], +"textures/segment2/segment2_cn.184D0.ia1.png": [16,8,16,{"cn":[947456,99536]}], +"textures/segment2/segment2_cn.184E0.ia1.png": [16,8,16,{"cn":[947456,99552]}], +"textures/segment2/segment2_cn.184F0.ia1.png": [16,8,16,{"cn":[947456,99568]}], +"textures/segment2/segment2_cn.18500.ia1.png": [16,8,16,{"cn":[947456,99584]}], +"textures/segment2/segment2_cn.18510.ia1.png": [16,8,16,{"cn":[947456,99600]}], +"textures/segment2/segment2_cn.18520.ia1.png": [16,8,16,{"cn":[947456,99616]}], +"textures/segment2/segment2_cn.18530.ia1.png": [16,8,16,{"cn":[947456,99632]}], +"textures/segment2/segment2_cn.18540.ia1.png": [16,8,16,{"cn":[947456,99648]}], +"textures/segment2/segment2_cn.18550.ia1.png": [16,8,16,{"cn":[947456,99664]}], +"textures/segment2/segment2_cn.18560.ia1.png": [16,8,16,{"cn":[947456,99680]}], +"textures/segment2/segment2_cn.18570.ia1.png": [16,8,16,{"cn":[947456,99696]}], +"textures/segment2/segment2_cn.18580.ia1.png": [16,8,16,{"cn":[947456,99712]}], +"textures/segment2/segment2_cn.18590.ia1.png": [16,8,16,{"cn":[947456,99728]}], +"textures/segment2/segment2_cn.185A0.ia1.png": [16,8,16,{"cn":[947456,99744]}], +"textures/segment2/segment2_cn.185B0.ia1.png": [16,8,16,{"cn":[947456,99760]}], +"textures/segment2/segment2_cn.185C0.ia1.png": [16,8,16,{"cn":[947456,99776]}], +"textures/segment2/segment2_cn.185D0.ia1.png": [16,8,16,{"cn":[947456,99792]}], +"textures/segment2/segment2_cn.185E0.ia1.png": [16,8,16,{"cn":[947456,99808]}], +"textures/segment2/segment2_cn.185F0.ia1.png": [16,8,16,{"cn":[947456,99824]}], +"textures/segment2/segment2_cn.18600.ia1.png": [16,8,16,{"cn":[947456,99840]}], +"textures/segment2/segment2_cn.18610.ia1.png": [16,8,16,{"cn":[947456,99856]}], +"textures/segment2/segment2_cn.18620.ia1.png": [16,8,16,{"cn":[947456,99872]}], +"textures/segment2/segment2_cn.18630.ia1.png": [16,8,16,{"cn":[947456,99888]}], +"textures/segment2/segment2_cn.18640.ia1.png": [16,8,16,{"cn":[947456,99904]}], +"textures/segment2/segment2_cn.18650.ia1.png": [16,8,16,{"cn":[947456,99920]}], +"textures/segment2/segment2_cn.18660.ia1.png": [16,8,16,{"cn":[947456,99936]}], +"textures/segment2/segment2_cn.18670.ia1.png": [16,8,16,{"cn":[947456,99952]}], +"textures/segment2/segment2_cn.18680.ia1.png": [16,8,16,{"cn":[947456,99968]}], +"textures/segment2/segment2_cn.18690.ia1.png": [16,8,16,{"cn":[947456,99984]}], +"textures/segment2/segment2_cn.186A0.ia1.png": [16,8,16,{"cn":[947456,100000]}], +"textures/segment2/segment2_cn.186B0.ia1.png": [16,8,16,{"cn":[947456,100016]}], +"textures/segment2/segment2_cn.186C0.ia1.png": [16,8,16,{"cn":[947456,100032]}], +"textures/segment2/segment2_cn.186D0.ia1.png": [16,8,16,{"cn":[947456,100048]}], +"textures/segment2/segment2_cn.186E0.ia1.png": [16,8,16,{"cn":[947456,100064]}], +"textures/segment2/segment2_cn.186F0.ia1.png": [16,8,16,{"cn":[947456,100080]}], +"textures/segment2/segment2_cn.18700.ia1.png": [16,8,16,{"cn":[947456,100096]}], +"textures/segment2/segment2_cn.18710.ia1.png": [16,8,16,{"cn":[947456,100112]}], +"textures/segment2/segment2_cn.18720.ia1.png": [16,8,16,{"cn":[947456,100128]}], +"textures/segment2/segment2_cn.18730.ia1.png": [16,8,16,{"cn":[947456,100144]}], +"textures/segment2/segment2_cn.18740.ia1.png": [16,8,16,{"cn":[947456,100160]}], +"textures/segment2/segment2_cn.18750.ia1.png": [16,8,16,{"cn":[947456,100176]}], +"textures/segment2/segment2_cn.18760.ia1.png": [16,8,16,{"cn":[947456,100192]}], +"textures/segment2/segment2_cn.18770.ia1.png": [16,8,16,{"cn":[947456,100208]}], +"textures/segment2/segment2_cn.18780.ia1.png": [16,8,16,{"cn":[947456,100224]}], +"textures/segment2/segment2_cn.18790.ia1.png": [16,8,16,{"cn":[947456,100240]}], +"textures/segment2/segment2_cn.187A0.ia1.png": [16,8,16,{"cn":[947456,100256]}], +"textures/segment2/segment2_cn.187B0.ia1.png": [16,8,16,{"cn":[947456,100272]}], +"textures/segment2/segment2_cn.187C0.ia1.png": [16,8,16,{"cn":[947456,100288]}], +"textures/segment2/segment2_cn.187D0.ia1.png": [16,8,16,{"cn":[947456,100304]}], +"textures/segment2/segment2_cn.187E0.ia1.png": [16,8,16,{"cn":[947456,100320]}], +"textures/segment2/segment2_cn.187F0.ia1.png": [16,8,16,{"cn":[947456,100336]}], +"textures/segment2/segment2_cn.18800.ia1.png": [16,8,16,{"cn":[947456,100352]}], +"textures/segment2/segment2_cn.18810.ia1.png": [16,8,16,{"cn":[947456,100368]}], +"textures/segment2/segment2_cn.18820.ia1.png": [16,8,16,{"cn":[947456,100384]}], +"textures/segment2/segment2_cn.18830.ia1.png": [16,8,16,{"cn":[947456,100400]}], +"textures/segment2/segment2_cn.18840.ia1.png": [16,8,16,{"cn":[947456,100416]}], +"textures/segment2/segment2_cn.18850.ia1.png": [16,8,16,{"cn":[947456,100432]}], +"textures/segment2/segment2_cn.18860.ia1.png": [16,8,16,{"cn":[947456,100448]}], +"textures/segment2/segment2_cn.18870.ia1.png": [16,8,16,{"cn":[947456,100464]}], +"textures/segment2/segment2_cn.18880.ia1.png": [16,8,16,{"cn":[947456,100480]}], +"textures/segment2/segment2_cn.18890.ia1.png": [16,8,16,{"cn":[947456,100496]}], +"textures/segment2/segment2_cn.188A0.ia1.png": [16,8,16,{"cn":[947456,100512]}], +"textures/segment2/segment2_cn.188B0.ia1.png": [16,8,16,{"cn":[947456,100528]}], +"textures/segment2/segment2_cn.188C0.ia1.png": [16,8,16,{"cn":[947456,100544]}], +"textures/segment2/segment2_cn.188D0.ia1.png": [16,8,16,{"cn":[947456,100560]}], +"textures/segment2/segment2_cn.188E0.ia1.png": [16,8,16,{"cn":[947456,100576]}], +"textures/segment2/segment2_cn.188F0.ia1.png": [16,8,16,{"cn":[947456,100592]}], +"textures/segment2/segment2_cn.18900.ia1.png": [16,8,16,{"cn":[947456,100608]}], +"textures/segment2/segment2_cn.18910.ia1.png": [16,8,16,{"cn":[947456,100624]}], +"textures/segment2/segment2_cn.18920.ia1.png": [16,8,16,{"cn":[947456,100640]}], +"textures/segment2/segment2_cn.18930.ia1.png": [16,8,16,{"cn":[947456,100656]}], +"textures/segment2/segment2_cn.18940.ia1.png": [16,8,16,{"cn":[947456,100672]}], +"textures/segment2/segment2_cn.18950.ia1.png": [16,8,16,{"cn":[947456,100688]}], +"textures/segment2/segment2_cn.18960.ia1.png": [16,8,16,{"cn":[947456,100704]}], +"textures/segment2/segment2_cn.18970.ia1.png": [16,8,16,{"cn":[947456,100720]}], +"textures/segment2/segment2_cn.18980.ia1.png": [16,8,16,{"cn":[947456,100736]}], +"textures/segment2/segment2_cn.18990.ia1.png": [16,8,16,{"cn":[947456,100752]}], +"textures/segment2/segment2_cn.189A0.ia1.png": [16,8,16,{"cn":[947456,100768]}], +"textures/segment2/segment2_cn.189B0.ia1.png": [16,8,16,{"cn":[947456,100784]}], +"textures/segment2/segment2_cn.189C0.ia1.png": [16,8,16,{"cn":[947456,100800]}], +"textures/segment2/segment2_cn.189D0.ia1.png": [16,8,16,{"cn":[947456,100816]}], +"textures/segment2/segment2_cn.189E0.ia1.png": [16,8,16,{"cn":[947456,100832]}], +"textures/segment2/segment2_cn.189F0.ia1.png": [16,8,16,{"cn":[947456,100848]}], +"textures/segment2/segment2_cn.18A00.ia1.png": [16,8,16,{"cn":[947456,100864]}], +"textures/segment2/segment2_cn.18A10.ia1.png": [16,8,16,{"cn":[947456,100880]}], +"textures/segment2/segment2_cn.18A20.ia1.png": [16,8,16,{"cn":[947456,100896]}], +"textures/segment2/segment2_cn.18A30.ia1.png": [16,8,16,{"cn":[947456,100912]}], +"textures/segment2/segment2_cn.18A40.ia1.png": [16,8,16,{"cn":[947456,100928]}], +"textures/segment2/segment2_cn.18A50.ia1.png": [16,8,16,{"cn":[947456,100944]}], +"textures/segment2/segment2_cn.18A60.ia1.png": [16,8,16,{"cn":[947456,100960]}], +"textures/segment2/segment2_cn.18A70.ia1.png": [16,8,16,{"cn":[947456,100976]}], +"textures/segment2/segment2_cn.18A80.ia1.png": [16,8,16,{"cn":[947456,100992]}], +"textures/segment2/segment2_cn.18A90.ia1.png": [16,8,16,{"cn":[947456,101008]}], +"textures/segment2/segment2_cn.18AA0.ia1.png": [16,8,16,{"cn":[947456,101024]}], +"textures/segment2/segment2_cn.18AB0.ia1.png": [16,8,16,{"cn":[947456,101040]}], +"textures/segment2/segment2_cn.18AC0.ia1.png": [16,8,16,{"cn":[947456,101056]}], +"textures/segment2/segment2_cn.18AD0.ia1.png": [16,8,16,{"cn":[947456,101072]}], +"textures/segment2/segment2_cn.18AE0.ia1.png": [16,8,16,{"cn":[947456,101088]}], +"textures/segment2/segment2_cn.18AF0.ia1.png": [16,8,16,{"cn":[947456,101104]}], +"textures/segment2/segment2_cn.18B00.ia1.png": [16,8,16,{"cn":[947456,101120]}], +"textures/segment2/segment2_cn.18B10.ia1.png": [16,8,16,{"cn":[947456,101136]}], +"textures/segment2/segment2_cn.18B20.ia1.png": [16,8,16,{"cn":[947456,101152]}], +"textures/segment2/segment2_cn.18B30.ia1.png": [16,8,16,{"cn":[947456,101168]}], +"textures/segment2/segment2_cn.18B40.ia1.png": [16,8,16,{"cn":[947456,101184]}], +"textures/segment2/segment2_cn.18B50.ia1.png": [16,8,16,{"cn":[947456,101200]}], +"textures/segment2/segment2_cn.18B60.ia1.png": [16,8,16,{"cn":[947456,101216]}], +"textures/segment2/segment2_cn.18B70.ia1.png": [16,8,16,{"cn":[947456,101232]}], +"textures/segment2/segment2_cn.18B80.ia1.png": [16,8,16,{"cn":[947456,101248]}], +"textures/segment2/segment2_cn.18B90.ia1.png": [16,8,16,{"cn":[947456,101264]}], +"textures/segment2/segment2_cn.18BA0.ia1.png": [16,8,16,{"cn":[947456,101280]}], +"textures/segment2/segment2_cn.18BB0.ia1.png": [16,8,16,{"cn":[947456,101296]}], +"textures/segment2/segment2_cn.18BC0.ia1.png": [16,8,16,{"cn":[947456,101312]}], +"textures/segment2/segment2_cn.18BD0.ia1.png": [16,8,16,{"cn":[947456,101328]}], +"textures/segment2/segment2_cn.18BE0.ia1.png": [16,8,16,{"cn":[947456,101344]}], +"textures/segment2/segment2_cn.18BF0.ia1.png": [16,8,16,{"cn":[947456,101360]}], +"textures/segment2/segment2_cn.18C00.ia1.png": [16,8,16,{"cn":[947456,101376]}], +"textures/segment2/segment2_cn.18C10.ia1.png": [16,8,16,{"cn":[947456,101392]}], +"textures/segment2/segment2_cn.18C20.ia1.png": [16,8,16,{"cn":[947456,101408]}], +"textures/segment2/segment2_cn.18C30.ia1.png": [16,8,16,{"cn":[947456,101424]}], +"textures/segment2/segment2_cn.18C40.ia1.png": [16,8,16,{"cn":[947456,101440]}], +"textures/segment2/segment2_cn.18C50.ia1.png": [16,8,16,{"cn":[947456,101456]}], +"textures/segment2/segment2_cn.18C60.ia1.png": [16,8,16,{"cn":[947456,101472]}], +"textures/segment2/segment2_cn.18C70.ia1.png": [16,8,16,{"cn":[947456,101488]}], +"textures/segment2/segment2_cn.18C80.ia1.png": [16,8,16,{"cn":[947456,101504]}], +"textures/segment2/segment2_cn.18C90.ia1.png": [16,8,16,{"cn":[947456,101520]}], +"textures/segment2/segment2_cn.18CA0.ia1.png": [16,8,16,{"cn":[947456,101536]}], +"textures/segment2/segment2_cn.18CB0.ia1.png": [16,8,16,{"cn":[947456,101552]}], +"textures/segment2/segment2_cn.18CC0.ia1.png": [16,8,16,{"cn":[947456,101568]}], +"textures/segment2/segment2_cn.18CD0.ia1.png": [16,8,16,{"cn":[947456,101584]}], +"textures/segment2/segment2_cn.18CE0.ia1.png": [16,8,16,{"cn":[947456,101600]}], +"textures/segment2/segment2_cn.18CF0.ia1.png": [16,8,16,{"cn":[947456,101616]}], +"textures/segment2/segment2_cn.18D00.ia1.png": [16,8,16,{"cn":[947456,101632]}], +"textures/segment2/segment2_cn.18D10.ia1.png": [16,8,16,{"cn":[947456,101648]}], +"textures/segment2/segment2_cn.18D20.ia1.png": [16,8,16,{"cn":[947456,101664]}], +"textures/segment2/segment2_cn.18D30.ia1.png": [16,8,16,{"cn":[947456,101680]}], +"textures/segment2/segment2_cn.18D40.ia1.png": [16,8,16,{"cn":[947456,101696]}], +"textures/segment2/segment2_cn.18D50.ia1.png": [16,8,16,{"cn":[947456,101712]}], +"textures/segment2/segment2_cn.18D60.ia1.png": [16,8,16,{"cn":[947456,101728]}], +"textures/segment2/segment2_cn.18D70.ia1.png": [16,8,16,{"cn":[947456,101744]}], +"textures/segment2/segment2_cn.18D80.ia1.png": [16,8,16,{"cn":[947456,101760]}], +"textures/segment2/segment2_cn.18D90.ia1.png": [16,8,16,{"cn":[947456,101776]}], +"textures/segment2/segment2_cn.18DA0.ia1.png": [16,8,16,{"cn":[947456,101792]}], +"textures/segment2/segment2_cn.18DB0.ia1.png": [16,8,16,{"cn":[947456,101808]}], +"textures/segment2/segment2_cn.18DC0.ia1.png": [16,8,16,{"cn":[947456,101824]}], +"textures/segment2/segment2_cn.18DD0.ia1.png": [16,8,16,{"cn":[947456,101840]}], +"textures/segment2/segment2_cn.18DE0.ia1.png": [16,8,16,{"cn":[947456,101856]}], +"textures/segment2/segment2_cn.18DF0.ia1.png": [16,8,16,{"cn":[947456,101872]}], +"textures/segment2/segment2_cn.18E00.ia1.png": [16,8,16,{"cn":[947456,101888]}], +"textures/segment2/segment2_cn.18E10.ia1.png": [16,8,16,{"cn":[947456,101904]}], +"textures/segment2/segment2_cn.18E20.ia1.png": [16,8,16,{"cn":[947456,101920]}], +"textures/segment2/segment2_cn.18E30.ia1.png": [16,8,16,{"cn":[947456,101936]}], +"textures/segment2/segment2_cn.18E40.ia1.png": [16,8,16,{"cn":[947456,101952]}], +"textures/segment2/segment2_cn.18E50.ia1.png": [16,8,16,{"cn":[947456,101968]}], +"textures/segment2/segment2_cn.18E60.ia1.png": [16,8,16,{"cn":[947456,101984]}], +"textures/segment2/segment2_cn.18E70.ia1.png": [16,8,16,{"cn":[947456,102000]}], +"textures/segment2/segment2_cn.18E80.ia1.png": [16,8,16,{"cn":[947456,102016]}], +"textures/segment2/segment2_cn.18E90.ia1.png": [16,8,16,{"cn":[947456,102032]}], +"textures/segment2/segment2_cn.18EA0.ia1.png": [16,8,16,{"cn":[947456,102048]}], +"textures/segment2/segment2_cn.18EB0.ia1.png": [16,8,16,{"cn":[947456,102064]}], +"textures/segment2/segment2_cn.18EC0.ia1.png": [16,8,16,{"cn":[947456,102080]}], +"textures/segment2/segment2_cn.18ED0.ia1.png": [16,8,16,{"cn":[947456,102096]}], +"textures/segment2/segment2_cn.18EE0.ia1.png": [16,8,16,{"cn":[947456,102112]}], +"textures/segment2/segment2_cn.18EF0.ia1.png": [16,8,16,{"cn":[947456,102128]}], +"textures/segment2/segment2_cn.18F00.ia1.png": [16,8,16,{"cn":[947456,102144]}], +"textures/segment2/segment2_cn.18F10.ia1.png": [16,8,16,{"cn":[947456,102160]}], +"textures/segment2/segment2_cn.18F20.ia1.png": [16,8,16,{"cn":[947456,102176]}], +"textures/segment2/segment2_cn.18F30.ia1.png": [16,8,16,{"cn":[947456,102192]}], +"textures/segment2/segment2_cn.18F40.ia1.png": [16,8,16,{"cn":[947456,102208]}], +"textures/segment2/segment2_cn.18F50.ia1.png": [16,8,16,{"cn":[947456,102224]}], +"textures/segment2/segment2_cn.18F60.ia1.png": [16,8,16,{"cn":[947456,102240]}], +"textures/segment2/segment2_cn.18F70.ia1.png": [16,8,16,{"cn":[947456,102256]}], +"textures/segment2/segment2_cn.18F80.ia1.png": [16,8,16,{"cn":[947456,102272]}], +"textures/segment2/segment2_cn.18F90.ia1.png": [16,8,16,{"cn":[947456,102288]}], +"textures/segment2/segment2_cn.18FA0.ia1.png": [16,8,16,{"cn":[947456,102304]}], +"textures/segment2/segment2_cn.18FB0.ia1.png": [16,8,16,{"cn":[947456,102320]}], +"textures/segment2/segment2_cn.18FC0.ia1.png": [16,8,16,{"cn":[947456,102336]}], +"textures/segment2/segment2_cn.18FD0.ia1.png": [16,8,16,{"cn":[947456,102352]}], +"textures/segment2/segment2_cn.18FE0.ia1.png": [16,8,16,{"cn":[947456,102368]}], +"textures/segment2/segment2_cn.18FF0.ia1.png": [16,8,16,{"cn":[947456,102384]}], +"textures/segment2/segment2_cn.19000.ia1.png": [16,8,16,{"cn":[947456,102400]}], +"textures/segment2/segment2_cn.19010.ia1.png": [16,8,16,{"cn":[947456,102416]}], +"textures/segment2/segment2_cn.19020.ia1.png": [16,8,16,{"cn":[947456,102432]}], +"textures/segment2/segment2_cn.19030.ia1.png": [16,8,16,{"cn":[947456,102448]}], +"textures/segment2/segment2_cn.19040.ia1.png": [16,8,16,{"cn":[947456,102464]}], +"textures/segment2/segment2_cn.19050.ia1.png": [16,8,16,{"cn":[947456,102480]}], +"textures/segment2/segment2_cn.19060.ia1.png": [16,8,16,{"cn":[947456,102496]}], +"textures/segment2/segment2_cn.19070.ia1.png": [16,8,16,{"cn":[947456,102512]}], +"textures/segment2/segment2_cn.19080.ia1.png": [16,8,16,{"cn":[947456,102528]}], +"textures/segment2/segment2_cn.19090.ia1.png": [16,8,16,{"cn":[947456,102544]}], +"textures/segment2/segment2_cn.190A0.ia1.png": [16,8,16,{"cn":[947456,102560]}], +"textures/segment2/segment2_cn.190B0.ia1.png": [16,8,16,{"cn":[947456,102576]}], +"textures/segment2/segment2_cn.190C0.ia1.png": [16,8,16,{"cn":[947456,102592]}], +"textures/segment2/segment2_cn.190D0.ia1.png": [16,8,16,{"cn":[947456,102608]}], +"textures/segment2/segment2_cn.190E0.ia1.png": [16,8,16,{"cn":[947456,102624]}], +"textures/segment2/segment2_cn.190F0.ia1.png": [16,8,16,{"cn":[947456,102640]}], +"textures/segment2/segment2_cn.19100.ia1.png": [16,8,16,{"cn":[947456,102656]}], +"textures/segment2/segment2_cn.19110.ia1.png": [16,8,16,{"cn":[947456,102672]}], +"textures/segment2/segment2_cn.19120.ia1.png": [16,8,16,{"cn":[947456,102688]}], +"textures/segment2/segment2_cn.19130.ia1.png": [16,8,16,{"cn":[947456,102704]}], +"textures/segment2/segment2_cn.19140.ia1.png": [16,8,16,{"cn":[947456,102720]}], +"textures/segment2/segment2_cn.19150.ia1.png": [16,8,16,{"cn":[947456,102736]}], +"textures/segment2/segment2_cn.19160.ia1.png": [16,8,16,{"cn":[947456,102752]}], +"textures/segment2/segment2_cn.19170.ia1.png": [16,8,16,{"cn":[947456,102768]}], +"textures/segment2/segment2_cn.19180.ia1.png": [16,8,16,{"cn":[947456,102784]}], +"textures/segment2/segment2_cn.19190.ia1.png": [16,8,16,{"cn":[947456,102800]}], +"textures/segment2/segment2_cn.191A0.ia1.png": [16,8,16,{"cn":[947456,102816]}], +"textures/segment2/segment2_cn.191B0.ia1.png": [16,8,16,{"cn":[947456,102832]}], +"textures/segment2/segment2_cn.191C0.ia1.png": [16,8,16,{"cn":[947456,102848]}], +"textures/segment2/segment2_cn.191D0.ia1.png": [16,8,16,{"cn":[947456,102864]}], +"textures/segment2/segment2_cn.191E0.ia1.png": [16,8,16,{"cn":[947456,102880]}], +"textures/segment2/segment2_cn.191F0.ia1.png": [16,8,16,{"cn":[947456,102896]}], +"textures/segment2/segment2_cn.19200.ia1.png": [16,8,16,{"cn":[947456,102912]}], +"textures/segment2/segment2_cn.19210.ia1.png": [16,8,16,{"cn":[947456,102928]}], +"textures/segment2/segment2_cn.19220.ia1.png": [16,8,16,{"cn":[947456,102944]}], +"textures/segment2/segment2_cn.19230.ia1.png": [16,8,16,{"cn":[947456,102960]}], +"textures/segment2/segment2_cn.19240.ia1.png": [16,8,16,{"cn":[947456,102976]}], +"textures/segment2/segment2_cn.19250.ia1.png": [16,8,16,{"cn":[947456,102992]}], +"textures/segment2/segment2_cn.19260.ia1.png": [16,8,16,{"cn":[947456,103008]}], +"textures/segment2/segment2_cn.19270.ia1.png": [16,8,16,{"cn":[947456,103024]}], +"textures/segment2/segment2_cn.19280.ia1.png": [16,8,16,{"cn":[947456,103040]}], +"textures/segment2/segment2_cn.19290.ia1.png": [16,8,16,{"cn":[947456,103056]}], +"textures/segment2/segment2_cn.192A0.ia1.png": [16,8,16,{"cn":[947456,103072]}], +"textures/segment2/segment2_cn.192B0.ia1.png": [16,8,16,{"cn":[947456,103088]}], +"textures/segment2/segment2_cn.192C0.ia1.png": [16,8,16,{"cn":[947456,103104]}], +"textures/segment2/segment2_cn.192D0.ia1.png": [16,8,16,{"cn":[947456,103120]}], +"textures/segment2/segment2_cn.192E0.ia1.png": [16,8,16,{"cn":[947456,103136]}], +"textures/segment2/segment2_cn.192F0.ia1.png": [16,8,16,{"cn":[947456,103152]}], +"textures/segment2/segment2_cn.19300.ia1.png": [16,8,16,{"cn":[947456,103168]}], +"textures/segment2/segment2_cn.19310.ia1.png": [16,8,16,{"cn":[947456,103184]}], +"textures/segment2/segment2_cn.19320.ia1.png": [16,8,16,{"cn":[947456,103200]}], +"textures/segment2/segment2_cn.19330.ia1.png": [16,8,16,{"cn":[947456,103216]}], +"textures/segment2/segment2_cn.19340.ia1.png": [16,8,16,{"cn":[947456,103232]}], +"textures/segment2/segment2_cn.19350.ia1.png": [16,8,16,{"cn":[947456,103248]}], +"textures/segment2/segment2_cn.19360.ia1.png": [16,8,16,{"cn":[947456,103264]}], +"textures/segment2/segment2_cn.19370.ia1.png": [16,8,16,{"cn":[947456,103280]}], +"textures/segment2/segment2_cn.19380.ia1.png": [16,8,16,{"cn":[947456,103296]}], +"textures/segment2/segment2_cn.19390.ia1.png": [16,8,16,{"cn":[947456,103312]}], +"textures/segment2/segment2_cn.193A0.ia1.png": [16,8,16,{"cn":[947456,103328]}], +"textures/segment2/segment2_cn.193B0.ia1.png": [16,8,16,{"cn":[947456,103344]}], +"textures/segment2/segment2_cn.193C0.ia1.png": [16,8,16,{"cn":[947456,103360]}], +"textures/segment2/segment2_cn.193D0.ia1.png": [16,8,16,{"cn":[947456,103376]}], +"textures/segment2/segment2_cn.193E0.ia1.png": [16,8,16,{"cn":[947456,103392]}], +"textures/segment2/segment2_cn.193F0.ia1.png": [16,8,16,{"cn":[947456,103408]}], +"textures/segment2/segment2_cn.19400.ia1.png": [16,8,16,{"cn":[947456,103424]}], +"textures/segment2/segment2_cn.19410.ia1.png": [16,8,16,{"cn":[947456,103440]}], +"textures/segment2/segment2_cn.19420.ia1.png": [16,8,16,{"cn":[947456,103456]}], +"textures/segment2/segment2_cn.19430.ia1.png": [16,8,16,{"cn":[947456,103472]}], +"textures/segment2/segment2_cn.19440.ia1.png": [16,8,16,{"cn":[947456,103488]}], +"textures/segment2/segment2_cn.19450.ia1.png": [16,8,16,{"cn":[947456,103504]}], +"textures/segment2/segment2_cn.19460.ia1.png": [16,8,16,{"cn":[947456,103520]}], +"textures/segment2/segment2_cn.19470.ia1.png": [16,8,16,{"cn":[947456,103536]}], +"textures/segment2/segment2_cn.19480.ia1.png": [16,8,16,{"cn":[947456,103552]}], +"textures/segment2/segment2_cn.19490.ia1.png": [16,8,16,{"cn":[947456,103568]}], +"textures/segment2/segment2_cn.194A0.ia1.png": [16,8,16,{"cn":[947456,103584]}], +"textures/segment2/segment2_cn.194B0.ia1.png": [16,8,16,{"cn":[947456,103600]}], +"textures/segment2/segment2_cn.194C0.ia1.png": [16,8,16,{"cn":[947456,103616]}], +"textures/segment2/segment2_cn.194D0.ia1.png": [16,8,16,{"cn":[947456,103632]}], +"textures/segment2/segment2_cn.194E0.ia1.png": [16,8,16,{"cn":[947456,103648]}], +"textures/segment2/segment2_cn.194F0.ia1.png": [16,8,16,{"cn":[947456,103664]}], +"textures/segment2/segment2_cn.19500.ia1.png": [16,8,16,{"cn":[947456,103680]}], +"textures/segment2/segment2_cn.19510.ia1.png": [16,8,16,{"cn":[947456,103696]}], +"textures/segment2/segment2_cn.19520.ia1.png": [16,8,16,{"cn":[947456,103712]}], +"textures/segment2/segment2_cn.19530.ia1.png": [16,8,16,{"cn":[947456,103728]}], +"textures/segment2/segment2_cn.19540.ia1.png": [16,8,16,{"cn":[947456,103744]}], +"textures/segment2/segment2_cn.19550.ia1.png": [16,8,16,{"cn":[947456,103760]}], +"textures/segment2/segment2_cn.19560.ia1.png": [16,8,16,{"cn":[947456,103776]}], +"textures/segment2/segment2_cn.19570.ia1.png": [16,8,16,{"cn":[947456,103792]}], +"textures/segment2/segment2_cn.19580.ia1.png": [16,8,16,{"cn":[947456,103808]}], +"textures/segment2/segment2_cn.19590.ia1.png": [16,8,16,{"cn":[947456,103824]}], +"textures/segment2/segment2_cn.195A0.ia1.png": [16,8,16,{"cn":[947456,103840]}], +"textures/segment2/segment2_cn.195B0.ia1.png": [16,8,16,{"cn":[947456,103856]}], +"textures/segment2/segment2_cn.195C0.ia1.png": [16,8,16,{"cn":[947456,103872]}], +"textures/segment2/segment2_cn.195D0.ia1.png": [16,8,16,{"cn":[947456,103888]}], +"textures/segment2/segment2_cn.195E0.ia1.png": [16,8,16,{"cn":[947456,103904]}], +"textures/segment2/segment2_cn.195F0.ia1.png": [16,8,16,{"cn":[947456,103920]}], +"textures/segment2/segment2_cn.19600.ia1.png": [16,8,16,{"cn":[947456,103936]}], +"textures/segment2/segment2_cn.19610.ia1.png": [16,8,16,{"cn":[947456,103952]}], +"textures/segment2/segment2_cn.19620.ia1.png": [16,8,16,{"cn":[947456,103968]}], +"textures/segment2/segment2_cn.19630.ia1.png": [16,8,16,{"cn":[947456,103984]}], +"textures/segment2/segment2_cn.19640.ia1.png": [16,8,16,{"cn":[947456,104000]}], +"textures/segment2/segment2_cn.19650.ia1.png": [16,8,16,{"cn":[947456,104016]}], +"textures/segment2/segment2_cn.19660.ia1.png": [16,8,16,{"cn":[947456,104032]}], +"textures/segment2/segment2_cn.19670.ia1.png": [16,8,16,{"cn":[947456,104048]}], +"textures/segment2/segment2_cn.19680.ia1.png": [16,8,16,{"cn":[947456,104064]}], +"textures/segment2/segment2_cn.19690.ia1.png": [16,8,16,{"cn":[947456,104080]}], +"textures/segment2/segment2_cn.196A0.ia1.png": [16,8,16,{"cn":[947456,104096]}], +"textures/segment2/segment2_cn.196B0.ia1.png": [16,8,16,{"cn":[947456,104112]}], +"textures/segment2/segment2_cn.196C0.ia1.png": [16,8,16,{"cn":[947456,104128]}], +"textures/segment2/segment2_cn.196D0.ia1.png": [16,8,16,{"cn":[947456,104144]}], +"textures/segment2/segment2_cn.196E0.ia1.png": [16,8,16,{"cn":[947456,104160]}], +"textures/segment2/segment2_cn.196F0.ia1.png": [16,8,16,{"cn":[947456,104176]}], +"textures/segment2/segment2_cn.19700.ia1.png": [16,8,16,{"cn":[947456,104192]}], +"textures/segment2/segment2_cn.19710.ia1.png": [16,8,16,{"cn":[947456,104208]}], +"textures/segment2/segment2_cn.19720.ia1.png": [16,8,16,{"cn":[947456,104224]}], +"textures/segment2/segment2_cn.19730.ia1.png": [16,8,16,{"cn":[947456,104240]}], +"textures/segment2/segment2_cn.19740.ia1.png": [16,8,16,{"cn":[947456,104256]}], +"textures/segment2/segment2_cn.19750.ia1.png": [16,8,16,{"cn":[947456,104272]}], +"textures/segment2/segment2_cn.19760.ia1.png": [16,8,16,{"cn":[947456,104288]}], +"textures/segment2/segment2_cn.19770.ia1.png": [16,8,16,{"cn":[947456,104304]}], +"textures/segment2/segment2_cn.19780.ia1.png": [16,8,16,{"cn":[947456,104320]}], +"textures/segment2/segment2_cn.19790.ia1.png": [16,8,16,{"cn":[947456,104336]}], +"textures/segment2/segment2_cn.197A0.ia1.png": [16,8,16,{"cn":[947456,104352]}], +"textures/segment2/segment2_cn.197B0.ia1.png": [16,8,16,{"cn":[947456,104368]}], +"textures/segment2/segment2_cn.197C0.ia1.png": [16,8,16,{"cn":[947456,104384]}], +"textures/segment2/segment2_cn.197D0.ia1.png": [16,8,16,{"cn":[947456,104400]}], +"textures/segment2/segment2_cn.197E0.ia1.png": [16,8,16,{"cn":[947456,104416]}], +"textures/segment2/segment2_cn.197F0.ia1.png": [16,8,16,{"cn":[947456,104432]}], +"textures/segment2/segment2_cn.19800.ia1.png": [16,8,16,{"cn":[947456,104448]}], +"textures/segment2/segment2_cn.19810.ia1.png": [16,8,16,{"cn":[947456,104464]}], +"textures/segment2/segment2_cn.19820.ia1.png": [16,8,16,{"cn":[947456,104480]}], +"textures/segment2/segment2_cn.19830.ia1.png": [16,8,16,{"cn":[947456,104496]}], +"textures/segment2/segment2_cn.19840.ia1.png": [16,8,16,{"cn":[947456,104512]}], +"textures/segment2/segment2_cn.19850.ia1.png": [16,8,16,{"cn":[947456,104528]}], +"textures/segment2/segment2_cn.19860.ia1.png": [16,8,16,{"cn":[947456,104544]}], +"textures/segment2/segment2_cn.19870.ia1.png": [16,8,16,{"cn":[947456,104560]}], +"textures/segment2/segment2_cn.19880.ia1.png": [16,8,16,{"cn":[947456,104576]}], +"textures/segment2/segment2_cn.19890.ia1.png": [16,8,16,{"cn":[947456,104592]}], +"textures/segment2/segment2_cn.198A0.ia1.png": [16,8,16,{"cn":[947456,104608]}], +"textures/segment2/segment2_cn.198B0.ia1.png": [16,8,16,{"cn":[947456,104624]}], +"textures/segment2/segment2_cn.198C0.ia1.png": [16,8,16,{"cn":[947456,104640]}], +"textures/segment2/segment2_cn.198D0.ia1.png": [16,8,16,{"cn":[947456,104656]}], +"textures/segment2/segment2_cn.198E0.ia1.png": [16,8,16,{"cn":[947456,104672]}], +"textures/segment2/segment2_cn.198F0.ia1.png": [16,8,16,{"cn":[947456,104688]}], +"textures/segment2/segment2_cn.19900.ia1.png": [16,8,16,{"cn":[947456,104704]}], +"textures/segment2/segment2_cn.19910.ia1.png": [16,8,16,{"cn":[947456,104720]}], +"textures/segment2/segment2_cn.19920.ia1.png": [16,8,16,{"cn":[947456,104736]}], +"textures/segment2/segment2_cn.19930.ia1.png": [16,8,16,{"cn":[947456,104752]}], +"textures/segment2/segment2_cn.19940.ia1.png": [16,8,16,{"cn":[947456,104768]}], +"textures/segment2/segment2_cn.19950.ia1.png": [16,8,16,{"cn":[947456,104784]}], +"textures/segment2/segment2_cn.19960.ia1.png": [16,8,16,{"cn":[947456,104800]}], +"textures/segment2/segment2_cn.19970.ia1.png": [16,8,16,{"cn":[947456,104816]}], +"textures/segment2/segment2_cn.19980.ia1.png": [16,8,16,{"cn":[947456,104832]}], +"textures/segment2/segment2_cn.19990.ia1.png": [16,8,16,{"cn":[947456,104848]}], +"textures/segment2/segment2_cn.199A0.ia1.png": [16,8,16,{"cn":[947456,104864]}], +"textures/segment2/segment2_cn.199B0.ia1.png": [16,8,16,{"cn":[947456,104880]}], +"textures/segment2/segment2_cn.199C0.ia1.png": [16,8,16,{"cn":[947456,104896]}], +"textures/segment2/segment2_cn.199D0.ia1.png": [16,8,16,{"cn":[947456,104912]}], +"textures/segment2/segment2_cn.199E0.ia1.png": [16,8,16,{"cn":[947456,104928]}], +"textures/segment2/segment2_cn.199F0.ia1.png": [16,8,16,{"cn":[947456,104944]}], +"textures/segment2/segment2_cn.19A00.ia1.png": [16,8,16,{"cn":[947456,104960]}], +"textures/segment2/segment2_cn.19A10.ia1.png": [16,8,16,{"cn":[947456,104976]}], +"textures/segment2/segment2_cn.19A20.ia1.png": [16,8,16,{"cn":[947456,104992]}], +"textures/segment2/segment2_cn.19A30.ia1.png": [16,8,16,{"cn":[947456,105008]}], +"textures/segment2/segment2_cn.19A40.ia1.png": [16,8,16,{"cn":[947456,105024]}], +"textures/segment2/segment2_cn.19A50.ia1.png": [16,8,16,{"cn":[947456,105040]}], +"textures/segment2/segment2_cn.19A60.ia1.png": [16,8,16,{"cn":[947456,105056]}], +"textures/segment2/segment2_cn.19A70.ia1.png": [16,8,16,{"cn":[947456,105072]}], +"textures/segment2/segment2_cn.19A80.ia1.png": [16,8,16,{"cn":[947456,105088]}], +"textures/segment2/segment2_cn.19A90.ia1.png": [16,8,16,{"cn":[947456,105104]}], +"textures/segment2/segment2_cn.19AA0.ia1.png": [16,8,16,{"cn":[947456,105120]}], +"textures/segment2/segment2_cn.19AB0.ia1.png": [16,8,16,{"cn":[947456,105136]}], +"textures/segment2/segment2_cn.19AC0.ia1.png": [16,8,16,{"cn":[947456,105152]}], +"textures/segment2/segment2_cn.19AD0.ia1.png": [16,8,16,{"cn":[947456,105168]}], +"textures/segment2/segment2_cn.19AE0.ia1.png": [16,8,16,{"cn":[947456,105184]}], +"textures/segment2/segment2_cn.19AF0.ia1.png": [16,8,16,{"cn":[947456,105200]}], +"textures/segment2/segment2_cn.19B00.ia1.png": [16,8,16,{"cn":[947456,105216]}], +"textures/segment2/segment2_cn.19B10.ia1.png": [16,8,16,{"cn":[947456,105232]}], +"textures/segment2/segment2_cn.19B20.ia1.png": [16,8,16,{"cn":[947456,105248]}], +"textures/segment2/segment2_cn.19B30.ia1.png": [16,8,16,{"cn":[947456,105264]}], +"textures/segment2/segment2_cn.19B40.ia1.png": [16,8,16,{"cn":[947456,105280]}], +"textures/segment2/segment2_cn.19B50.ia1.png": [16,8,16,{"cn":[947456,105296]}], +"textures/segment2/segment2_cn.19B60.ia1.png": [16,8,16,{"cn":[947456,105312]}], +"textures/segment2/segment2_cn.19B70.ia1.png": [16,8,16,{"cn":[947456,105328]}], +"textures/segment2/segment2_cn.19B80.ia1.png": [16,8,16,{"cn":[947456,105344]}], +"textures/segment2/segment2_cn.19B90.ia1.png": [16,8,16,{"cn":[947456,105360]}], +"textures/segment2/segment2_cn.19BA0.ia1.png": [16,8,16,{"cn":[947456,105376]}], +"textures/segment2/segment2_cn.19BB0.ia1.png": [16,8,16,{"cn":[947456,105392]}], +"textures/segment2/segment2_cn.19BC0.ia1.png": [16,8,16,{"cn":[947456,105408]}], +"textures/segment2/segment2_cn.19BD0.ia1.png": [16,8,16,{"cn":[947456,105424]}], +"textures/segment2/segment2_cn.19BE0.ia1.png": [16,8,16,{"cn":[947456,105440]}], +"textures/segment2/segment2_cn.19BF0.ia1.png": [16,8,16,{"cn":[947456,105456]}], +"textures/segment2/segment2_cn.19C00.ia1.png": [16,8,16,{"cn":[947456,105472]}], +"textures/segment2/segment2_cn.19C10.ia1.png": [16,8,16,{"cn":[947456,105488]}], +"textures/segment2/segment2_cn.19C20.ia1.png": [16,8,16,{"cn":[947456,105504]}], +"textures/segment2/segment2_cn.19C30.ia1.png": [16,8,16,{"cn":[947456,105520]}], +"textures/segment2/segment2_cn.19C40.ia1.png": [16,8,16,{"cn":[947456,105536]}], +"textures/segment2/segment2_cn.19C50.ia1.png": [16,8,16,{"cn":[947456,105552]}], +"textures/segment2/segment2_cn.19C60.ia1.png": [16,8,16,{"cn":[947456,105568]}], +"textures/segment2/segment2_cn.19C70.ia1.png": [16,8,16,{"cn":[947456,105584]}], +"textures/segment2/segment2_cn.19C80.ia1.png": [16,8,16,{"cn":[947456,105600]}], +"textures/segment2/segment2_cn.19C90.ia1.png": [16,8,16,{"cn":[947456,105616]}], +"textures/segment2/segment2_cn.19CA0.ia1.png": [16,8,16,{"cn":[947456,105632]}], +"textures/segment2/segment2_cn.19CB0.ia1.png": [16,8,16,{"cn":[947456,105648]}], +"textures/segment2/segment2_cn.19CC0.ia1.png": [16,8,16,{"cn":[947456,105664]}], +"textures/segment2/segment2_cn.19CD0.ia1.png": [16,8,16,{"cn":[947456,105680]}], +"textures/segment2/segment2_cn.19CE0.ia1.png": [16,8,16,{"cn":[947456,105696]}], +"textures/segment2/segment2_cn.19CF0.ia1.png": [16,8,16,{"cn":[947456,105712]}], +"textures/segment2/segment2_cn.19D00.ia1.png": [16,8,16,{"cn":[947456,105728]}], +"textures/segment2/segment2_cn.19D10.ia1.png": [16,8,16,{"cn":[947456,105744]}], +"textures/segment2/segment2_cn.19D20.ia1.png": [16,8,16,{"cn":[947456,105760]}], +"textures/segment2/segment2_cn.19D30.ia1.png": [16,8,16,{"cn":[947456,105776]}], +"textures/segment2/segment2_cn.19D40.ia1.png": [16,8,16,{"cn":[947456,105792]}], +"textures/segment2/segment2_cn.19D50.ia1.png": [16,8,16,{"cn":[947456,105808]}], +"textures/segment2/segment2_cn.19D60.ia1.png": [16,8,16,{"cn":[947456,105824]}], +"textures/segment2/segment2_cn.19D70.ia1.png": [16,8,16,{"cn":[947456,105840]}], +"textures/segment2/segment2_cn.19D80.ia1.png": [16,8,16,{"cn":[947456,105856]}], +"textures/segment2/segment2_cn.19D90.ia1.png": [16,8,16,{"cn":[947456,105872]}], +"textures/segment2/segment2_cn.19DA0.ia1.png": [16,8,16,{"cn":[947456,105888]}], +"textures/segment2/segment2_cn.19DB0.ia1.png": [16,8,16,{"cn":[947456,105904]}], +"textures/segment2/segment2_cn.19DC0.ia1.png": [16,8,16,{"cn":[947456,105920]}], +"textures/segment2/segment2_cn.19DD0.ia1.png": [16,8,16,{"cn":[947456,105936]}], +"textures/segment2/segment2_cn.19DE0.ia1.png": [16,8,16,{"cn":[947456,105952]}], +"textures/segment2/segment2_cn.19DF0.ia1.png": [16,8,16,{"cn":[947456,105968]}], +"textures/segment2/segment2_cn.19E00.ia1.png": [16,8,16,{"cn":[947456,105984]}], +"textures/segment2/segment2_cn.19E10.ia1.png": [16,8,16,{"cn":[947456,106000]}], +"textures/segment2/segment2_cn.19E20.ia1.png": [16,8,16,{"cn":[947456,106016]}], +"textures/segment2/segment2_cn.19E30.ia1.png": [16,8,16,{"cn":[947456,106032]}], +"textures/segment2/segment2_cn.19E40.ia1.png": [16,8,16,{"cn":[947456,106048]}], +"textures/segment2/segment2_cn.19E50.ia1.png": [16,8,16,{"cn":[947456,106064]}], +"textures/segment2/segment2_cn.19E60.ia1.png": [16,8,16,{"cn":[947456,106080]}], +"textures/segment2/segment2_cn.19E70.ia1.png": [16,8,16,{"cn":[947456,106096]}], +"textures/segment2/segment2_cn.19E80.ia1.png": [16,8,16,{"cn":[947456,106112]}], +"textures/segment2/segment2_cn.19E90.ia1.png": [16,8,16,{"cn":[947456,106128]}], +"textures/segment2/segment2_cn.19EA0.ia1.png": [16,8,16,{"cn":[947456,106144]}], +"textures/segment2/segment2_cn.19EB0.ia1.png": [16,8,16,{"cn":[947456,106160]}], +"textures/segment2/segment2_cn.19EC0.ia1.png": [16,8,16,{"cn":[947456,106176]}], +"textures/segment2/segment2_cn.19ED0.ia1.png": [16,8,16,{"cn":[947456,106192]}], +"textures/segment2/segment2_cn.19EE0.ia1.png": [16,8,16,{"cn":[947456,106208]}], +"textures/segment2/segment2_cn.19EF0.ia1.png": [16,8,16,{"cn":[947456,106224]}], +"textures/segment2/segment2_cn.19F00.ia1.png": [16,8,16,{"cn":[947456,106240]}], +"textures/segment2/segment2_cn.19F10.ia1.png": [16,8,16,{"cn":[947456,106256]}], +"textures/segment2/segment2_cn.19F20.ia1.png": [16,8,16,{"cn":[947456,106272]}], +"textures/segment2/segment2_cn.19F30.ia1.png": [16,8,16,{"cn":[947456,106288]}], +"textures/segment2/segment2_cn.19F40.ia1.png": [16,8,16,{"cn":[947456,106304]}], +"textures/segment2/segment2_cn.19F50.ia1.png": [16,8,16,{"cn":[947456,106320]}], +"textures/segment2/segment2_cn.19F60.ia1.png": [16,8,16,{"cn":[947456,106336]}], +"textures/segment2/segment2_cn.19F70.ia1.png": [16,8,16,{"cn":[947456,106352]}], +"textures/segment2/segment2_cn.19F80.ia1.png": [16,8,16,{"cn":[947456,106368]}], +"textures/segment2/segment2_cn.19F90.ia1.png": [16,8,16,{"cn":[947456,106384]}], +"textures/segment2/segment2_cn.19FA0.ia1.png": [16,8,16,{"cn":[947456,106400]}], +"textures/segment2/segment2_cn.19FB0.ia1.png": [16,8,16,{"cn":[947456,106416]}], +"textures/segment2/segment2_cn.19FC0.ia1.png": [16,8,16,{"cn":[947456,106432]}], +"textures/segment2/segment2_cn.19FD0.ia1.png": [16,8,16,{"cn":[947456,106448]}], +"textures/segment2/segment2_cn.19FE0.ia1.png": [16,8,16,{"cn":[947456,106464]}], +"textures/segment2/segment2_cn.19FF0.ia1.png": [16,8,16,{"cn":[947456,106480]}], +"textures/segment2/segment2_cn.1A000.ia1.png": [16,8,16,{"cn":[947456,106496]}], +"textures/segment2/segment2_cn.1A010.ia1.png": [16,8,16,{"cn":[947456,106512]}], +"textures/segment2/segment2_cn.1A020.ia1.png": [16,8,16,{"cn":[947456,106528]}], +"textures/segment2/segment2_cn.1A030.ia1.png": [16,8,16,{"cn":[947456,106544]}], +"textures/segment2/segment2_cn.1A040.ia1.png": [16,8,16,{"cn":[947456,106560]}], +"textures/segment2/segment2_cn.1A050.ia1.png": [16,8,16,{"cn":[947456,106576]}], +"textures/segment2/segment2_cn.1A060.ia1.png": [16,8,16,{"cn":[947456,106592]}], +"textures/segment2/segment2_cn.1A070.ia1.png": [16,8,16,{"cn":[947456,106608]}], +"textures/segment2/segment2_cn.1A080.ia1.png": [16,8,16,{"cn":[947456,106624]}], +"textures/segment2/segment2_cn.1A090.ia1.png": [16,8,16,{"cn":[947456,106640]}], +"textures/segment2/segment2_cn.1A0A0.ia1.png": [16,8,16,{"cn":[947456,106656]}], +"textures/segment2/segment2_cn.1A0B0.ia1.png": [16,8,16,{"cn":[947456,106672]}], +"textures/segment2/segment2_cn.1A0C0.ia1.png": [16,8,16,{"cn":[947456,106688]}], +"textures/segment2/segment2_cn.1A0D0.ia1.png": [16,8,16,{"cn":[947456,106704]}], +"textures/segment2/segment2_cn.1A0E0.ia1.png": [16,8,16,{"cn":[947456,106720]}], +"textures/segment2/segment2_cn.1A0F0.ia1.png": [16,8,16,{"cn":[947456,106736]}], +"textures/segment2/segment2_cn.1A100.ia1.png": [16,8,16,{"cn":[947456,106752]}], +"textures/segment2/segment2_cn.1A110.ia1.png": [16,8,16,{"cn":[947456,106768]}], +"textures/segment2/segment2_cn.1A120.ia1.png": [16,8,16,{"cn":[947456,106784]}], +"textures/segment2/segment2_cn.1A130.ia1.png": [16,8,16,{"cn":[947456,106800]}], +"textures/segment2/segment2_cn.1A140.ia1.png": [16,8,16,{"cn":[947456,106816]}], +"textures/segment2/segment2_cn.1A150.ia1.png": [16,8,16,{"cn":[947456,106832]}], +"textures/segment2/segment2_cn.1A160.ia1.png": [16,8,16,{"cn":[947456,106848]}], +"textures/segment2/segment2_cn.1A170.ia1.png": [16,8,16,{"cn":[947456,106864]}], +"textures/segment2/segment2_cn.1A180.ia1.png": [16,8,16,{"cn":[947456,106880]}], +"textures/segment2/segment2_cn.1A190.ia1.png": [16,8,16,{"cn":[947456,106896]}], +"textures/segment2/segment2_cn.1A1A0.ia1.png": [16,8,16,{"cn":[947456,106912]}], +"textures/segment2/segment2_cn.1A1B0.ia1.png": [16,8,16,{"cn":[947456,106928]}], +"textures/segment2/segment2_cn.1A1C0.ia1.png": [16,8,16,{"cn":[947456,106944]}], +"textures/segment2/segment2_cn.1A1D0.ia1.png": [16,8,16,{"cn":[947456,106960]}], +"textures/segment2/segment2_cn.1A1E0.ia1.png": [16,8,16,{"cn":[947456,106976]}], +"textures/segment2/segment2_cn.1A1F0.ia1.png": [16,8,16,{"cn":[947456,106992]}], +"textures/segment2/segment2_cn.1A200.ia1.png": [16,8,16,{"cn":[947456,107008]}], +"textures/segment2/segment2_cn.1A210.ia1.png": [16,8,16,{"cn":[947456,107024]}], +"textures/segment2/segment2_cn.1A220.ia1.png": [16,8,16,{"cn":[947456,107040]}], +"textures/segment2/segment2_cn.1A230.ia1.png": [16,8,16,{"cn":[947456,107056]}], +"textures/segment2/segment2_cn.1A240.ia1.png": [16,8,16,{"cn":[947456,107072]}], +"textures/segment2/segment2_cn.1A250.ia1.png": [16,8,16,{"cn":[947456,107088]}], +"textures/segment2/segment2_cn.1A260.ia1.png": [16,8,16,{"cn":[947456,107104]}], +"textures/segment2/segment2_cn.1A270.ia1.png": [16,8,16,{"cn":[947456,107120]}], +"textures/segment2/segment2_cn.1A280.ia1.png": [16,8,16,{"cn":[947456,107136]}], +"textures/segment2/segment2_cn.1A290.ia1.png": [16,8,16,{"cn":[947456,107152]}], +"textures/segment2/segment2_cn.1A2A0.ia1.png": [16,8,16,{"cn":[947456,107168]}], +"textures/segment2/segment2_cn.1A2B0.ia1.png": [16,8,16,{"cn":[947456,107184]}], +"textures/segment2/segment2_cn.1A2C0.ia1.png": [16,8,16,{"cn":[947456,107200]}], +"textures/segment2/segment2_cn.1A2D0.ia1.png": [16,8,16,{"cn":[947456,107216]}], +"textures/segment2/segment2_cn.1A2E0.ia1.png": [16,8,16,{"cn":[947456,107232]}], +"textures/segment2/segment2_cn.1A2F0.ia1.png": [16,8,16,{"cn":[947456,107248]}], +"textures/segment2/segment2_cn.1A300.ia1.png": [16,8,16,{"cn":[947456,107264]}], +"textures/segment2/segment2_cn.1A310.ia1.png": [16,8,16,{"cn":[947456,107280]}], +"textures/segment2/segment2_cn.1A320.ia1.png": [16,8,16,{"cn":[947456,107296]}], +"textures/segment2/segment2_cn.1A330.ia1.png": [16,8,16,{"cn":[947456,107312]}], +"textures/segment2/segment2_cn.1A340.ia1.png": [16,8,16,{"cn":[947456,107328]}], +"textures/segment2/segment2_cn.1A350.ia1.png": [16,8,16,{"cn":[947456,107344]}], +"textures/segment2/segment2_cn.1A360.ia1.png": [16,8,16,{"cn":[947456,107360]}], +"textures/segment2/segment2_cn.1A370.ia1.png": [16,8,16,{"cn":[947456,107376]}], +"textures/segment2/segment2_cn.1A380.ia1.png": [16,8,16,{"cn":[947456,107392]}], +"textures/segment2/segment2_cn.1A390.ia1.png": [16,8,16,{"cn":[947456,107408]}], +"textures/segment2/segment2_cn.1A3A0.ia1.png": [16,8,16,{"cn":[947456,107424]}], +"textures/segment2/segment2_cn.1A3B0.ia1.png": [16,8,16,{"cn":[947456,107440]}], +"textures/segment2/segment2_cn.1A3C0.ia1.png": [16,8,16,{"cn":[947456,107456]}], +"textures/segment2/segment2_cn.1A3D0.ia1.png": [16,8,16,{"cn":[947456,107472]}], +"textures/segment2/segment2_cn.1A3E0.ia1.png": [16,8,16,{"cn":[947456,107488]}], +"textures/segment2/segment2_cn.1A3F0.ia1.png": [16,8,16,{"cn":[947456,107504]}], +"textures/segment2/segment2_cn.1A400.ia1.png": [16,8,16,{"cn":[947456,107520]}], +"textures/segment2/segment2_cn.1A410.ia1.png": [16,8,16,{"cn":[947456,107536]}], +"textures/segment2/segment2_cn.1A420.ia1.png": [16,8,16,{"cn":[947456,107552]}], +"textures/segment2/segment2_cn.1A430.ia1.png": [16,8,16,{"cn":[947456,107568]}], +"textures/segment2/segment2_cn.1A440.ia1.png": [16,8,16,{"cn":[947456,107584]}], +"textures/segment2/segment2_cn.1A450.ia1.png": [16,8,16,{"cn":[947456,107600]}], +"textures/segment2/segment2_cn.1A460.ia1.png": [16,8,16,{"cn":[947456,107616]}], +"textures/segment2/segment2_cn.1A470.ia1.png": [16,8,16,{"cn":[947456,107632]}], +"textures/segment2/segment2_cn.1A480.ia1.png": [16,8,16,{"cn":[947456,107648]}], +"textures/segment2/segment2_cn.1A490.ia1.png": [16,8,16,{"cn":[947456,107664]}], +"textures/segment2/segment2_cn.1A4A0.ia1.png": [16,8,16,{"cn":[947456,107680]}], +"textures/segment2/segment2_cn.1A4B0.ia1.png": [16,8,16,{"cn":[947456,107696]}], +"textures/segment2/segment2_cn.1A4C0.ia1.png": [16,8,16,{"cn":[947456,107712]}], +"textures/segment2/segment2_cn.1A4D0.ia1.png": [16,8,16,{"cn":[947456,107728]}], +"textures/segment2/segment2_cn.1A4E0.ia1.png": [16,8,16,{"cn":[947456,107744]}], +"textures/segment2/segment2_cn.1A4F0.ia1.png": [16,8,16,{"cn":[947456,107760]}], +"textures/segment2/segment2_cn.1A500.ia1.png": [16,8,16,{"cn":[947456,107776]}], +"textures/segment2/segment2_cn.1A510.ia1.png": [16,8,16,{"cn":[947456,107792]}], +"textures/segment2/segment2_cn.1A520.ia1.png": [16,8,16,{"cn":[947456,107808]}], +"textures/segment2/segment2_cn.1A530.ia1.png": [16,8,16,{"cn":[947456,107824]}], +"textures/segment2/segment2_cn.1A540.ia1.png": [16,8,16,{"cn":[947456,107840]}], +"textures/segment2/segment2_cn.1A550.ia1.png": [16,8,16,{"cn":[947456,107856]}], +"textures/segment2/segment2_cn.1A560.ia1.png": [16,8,16,{"cn":[947456,107872]}], +"textures/segment2/segment2_cn.1A570.ia1.png": [16,8,16,{"cn":[947456,107888]}], +"textures/segment2/segment2_cn.1A580.ia1.png": [16,8,16,{"cn":[947456,107904]}], +"textures/segment2/segment2_cn.1A590.ia1.png": [16,8,16,{"cn":[947456,107920]}], +"textures/segment2/segment2_cn.1A5A0.ia1.png": [16,8,16,{"cn":[947456,107936]}], +"textures/segment2/segment2_cn.1A5B0.ia1.png": [16,8,16,{"cn":[947456,107952]}], +"textures/segment2/segment2_cn.1A5C0.ia1.png": [16,8,16,{"cn":[947456,107968]}], +"textures/segment2/segment2_cn.1A5D0.ia1.png": [16,8,16,{"cn":[947456,107984]}], +"textures/segment2/segment2_cn.1A5E0.ia1.png": [16,8,16,{"cn":[947456,108000]}], +"textures/segment2/segment2_cn.1A5F0.ia1.png": [16,8,16,{"cn":[947456,108016]}], +"textures/segment2/segment2_cn.1A600.ia1.png": [16,8,16,{"cn":[947456,108032]}], +"textures/segment2/segment2_cn.1A610.ia1.png": [16,8,16,{"cn":[947456,108048]}], +"textures/segment2/segment2_cn.1A620.ia1.png": [16,8,16,{"cn":[947456,108064]}], +"textures/segment2/segment2_cn.1A630.ia1.png": [16,8,16,{"cn":[947456,108080]}], +"textures/segment2/segment2_cn.1A640.ia1.png": [16,8,16,{"cn":[947456,108096]}], +"textures/segment2/segment2_cn.1A650.ia1.png": [16,8,16,{"cn":[947456,108112]}], +"textures/segment2/segment2_cn.1A660.ia1.png": [16,8,16,{"cn":[947456,108128]}], +"textures/segment2/segment2_cn.1A670.ia1.png": [16,8,16,{"cn":[947456,108144]}], +"textures/segment2/segment2_cn.1A680.ia1.png": [16,8,16,{"cn":[947456,108160]}], +"textures/segment2/segment2_cn.1A690.ia1.png": [16,8,16,{"cn":[947456,108176]}], +"textures/segment2/segment2_cn.1A6A0.ia1.png": [16,8,16,{"cn":[947456,108192]}], +"textures/segment2/segment2_cn.1A6B0.ia1.png": [16,8,16,{"cn":[947456,108208]}], +"textures/segment2/segment2_cn.1A6C0.ia1.png": [16,8,16,{"cn":[947456,108224]}], +"textures/segment2/segment2_cn.1A6D0.ia1.png": [16,8,16,{"cn":[947456,108240]}], +"textures/segment2/segment2_cn.1A6E0.ia1.png": [16,8,16,{"cn":[947456,108256]}], +"textures/segment2/segment2_cn.1A6F0.ia1.png": [16,8,16,{"cn":[947456,108272]}], +"textures/segment2/segment2_cn.1A700.ia1.png": [16,8,16,{"cn":[947456,108288]}], +"textures/segment2/segment2_cn.1A710.ia1.png": [16,8,16,{"cn":[947456,108304]}], +"textures/segment2/segment2_cn.1A720.ia1.png": [16,8,16,{"cn":[947456,108320]}], +"textures/segment2/segment2_cn.1A730.ia1.png": [16,8,16,{"cn":[947456,108336]}], +"textures/segment2/segment2_cn.1A740.ia1.png": [16,8,16,{"cn":[947456,108352]}], +"textures/segment2/segment2_cn.1A750.ia1.png": [16,8,16,{"cn":[947456,108368]}], +"textures/segment2/segment2_cn.1A760.ia1.png": [16,8,16,{"cn":[947456,108384]}], +"textures/segment2/segment2_cn.1A770.ia1.png": [16,8,16,{"cn":[947456,108400]}], +"textures/segment2/segment2_cn.1A780.ia1.png": [16,8,16,{"cn":[947456,108416]}], +"textures/segment2/segment2_cn.1A790.ia1.png": [16,8,16,{"cn":[947456,108432]}], +"textures/segment2/segment2_cn.1A7A0.ia1.png": [16,8,16,{"cn":[947456,108448]}], +"textures/segment2/segment2_cn.1A7B0.ia1.png": [16,8,16,{"cn":[947456,108464]}], +"textures/segment2/segment2_cn.1A7C0.ia1.png": [16,8,16,{"cn":[947456,108480]}], +"textures/segment2/segment2_cn.1A7D0.ia1.png": [16,8,16,{"cn":[947456,108496]}], +"textures/segment2/segment2_cn.1A7E0.ia1.png": [16,8,16,{"cn":[947456,108512]}], +"textures/segment2/segment2_cn.1A7F0.ia1.png": [16,8,16,{"cn":[947456,108528]}], +"textures/segment2/segment2_cn.1A800.ia1.png": [16,8,16,{"cn":[947456,108544]}], +"textures/segment2/segment2_cn.1A810.ia1.png": [16,8,16,{"cn":[947456,108560]}], +"textures/segment2/segment2_cn.1A820.ia1.png": [16,8,16,{"cn":[947456,108576]}], +"textures/segment2/segment2_cn.1A830.ia1.png": [16,8,16,{"cn":[947456,108592]}], +"textures/segment2/segment2_cn.1A840.ia1.png": [16,8,16,{"cn":[947456,108608]}], +"textures/segment2/segment2_cn.1A850.ia1.png": [16,8,16,{"cn":[947456,108624]}], +"textures/segment2/segment2_cn.1A860.ia1.png": [16,8,16,{"cn":[947456,108640]}], +"textures/segment2/segment2_cn.1A870.ia1.png": [16,8,16,{"cn":[947456,108656]}], +"textures/segment2/segment2_cn.1A880.ia1.png": [16,8,16,{"cn":[947456,108672]}], +"textures/segment2/segment2_cn.1A890.ia1.png": [16,8,16,{"cn":[947456,108688]}], +"textures/segment2/segment2_cn.1A8A0.ia1.png": [16,8,16,{"cn":[947456,108704]}], +"textures/segment2/segment2_cn.1A8B0.ia1.png": [16,8,16,{"cn":[947456,108720]}], +"textures/segment2/segment2_cn.1A8C0.ia1.png": [16,8,16,{"cn":[947456,108736]}], +"textures/segment2/segment2_cn.1A8D0.ia1.png": [16,8,16,{"cn":[947456,108752]}], +"textures/segment2/segment2_cn.1A8E0.ia1.png": [16,8,16,{"cn":[947456,108768]}], +"textures/segment2/segment2_cn.1A8F0.ia1.png": [16,8,16,{"cn":[947456,108784]}], +"textures/segment2/segment2_cn.1A900.ia1.png": [16,8,16,{"cn":[947456,108800]}], +"textures/segment2/segment2_cn.1A910.ia1.png": [16,8,16,{"cn":[947456,108816]}], +"textures/segment2/segment2_cn.1A920.ia1.png": [16,8,16,{"cn":[947456,108832]}], +"textures/segment2/segment2_cn.1A930.ia1.png": [16,8,16,{"cn":[947456,108848]}], +"textures/segment2/segment2_cn.1A940.ia1.png": [16,8,16,{"cn":[947456,108864]}], +"textures/segment2/segment2_cn.1A950.ia1.png": [16,8,16,{"cn":[947456,108880]}], +"textures/segment2/segment2_cn.1A960.ia1.png": [16,8,16,{"cn":[947456,108896]}], +"textures/segment2/segment2_cn.1A970.ia1.png": [16,8,16,{"cn":[947456,108912]}], +"textures/segment2/segment2_cn.1A980.ia1.png": [16,8,16,{"cn":[947456,108928]}], +"textures/segment2/segment2_cn.1A990.ia1.png": [16,8,16,{"cn":[947456,108944]}], +"textures/segment2/segment2_cn.1A9A0.ia1.png": [16,8,16,{"cn":[947456,108960]}], +"textures/segment2/segment2_cn.1A9B0.ia1.png": [16,8,16,{"cn":[947456,108976]}], +"textures/segment2/segment2_cn.1A9C0.ia1.png": [16,8,16,{"cn":[947456,108992]}], +"textures/segment2/segment2_cn.1A9D0.ia1.png": [16,8,16,{"cn":[947456,109008]}], +"textures/segment2/segment2_cn.1A9E0.ia1.png": [16,8,16,{"cn":[947456,109024]}], +"textures/segment2/segment2_cn.1A9F0.ia1.png": [16,8,16,{"cn":[947456,109040]}], +"textures/segment2/segment2_cn.1AA00.ia1.png": [16,8,16,{"cn":[947456,109056]}], +"textures/segment2/segment2_cn.1AA10.ia1.png": [16,8,16,{"cn":[947456,109072]}], +"textures/segment2/segment2_cn.1AA20.ia1.png": [16,8,16,{"cn":[947456,109088]}], +"textures/segment2/segment2_cn.1AA30.ia1.png": [16,8,16,{"cn":[947456,109104]}], +"textures/segment2/segment2_cn.1AA40.ia1.png": [16,8,16,{"cn":[947456,109120]}], +"textures/segment2/segment2_cn.1AA50.ia1.png": [16,8,16,{"cn":[947456,109136]}], +"textures/segment2/segment2_cn.1AA60.ia1.png": [16,8,16,{"cn":[947456,109152]}], +"textures/segment2/segment2_cn.1AA70.ia1.png": [16,8,16,{"cn":[947456,109168]}], +"textures/segment2/segment2_cn.1AA80.ia1.png": [16,8,16,{"cn":[947456,109184]}], +"textures/segment2/segment2_cn.1AA90.ia1.png": [16,8,16,{"cn":[947456,109200]}], +"textures/segment2/segment2_cn.1AAA0.ia1.png": [16,8,16,{"cn":[947456,109216]}], +"textures/segment2/segment2_cn.1AAB0.ia1.png": [16,8,16,{"cn":[947456,109232]}], +"textures/segment2/segment2_cn.1AAC0.ia1.png": [16,8,16,{"cn":[947456,109248]}], +"textures/segment2/segment2_cn.1AAD0.ia1.png": [16,8,16,{"cn":[947456,109264]}], +"textures/segment2/segment2_cn.1AAE0.ia1.png": [16,8,16,{"cn":[947456,109280]}], +"textures/segment2/segment2_cn.1AAF0.ia1.png": [16,8,16,{"cn":[947456,109296]}], +"textures/segment2/segment2_cn.1AB00.ia1.png": [16,8,16,{"cn":[947456,109312]}], +"textures/segment2/segment2_cn.1AB10.ia1.png": [16,8,16,{"cn":[947456,109328]}], +"textures/segment2/segment2_cn.1AB20.ia1.png": [16,8,16,{"cn":[947456,109344]}], +"textures/segment2/segment2_cn.1AB30.ia1.png": [16,8,16,{"cn":[947456,109360]}], +"textures/segment2/segment2_cn.1AB40.ia1.png": [16,8,16,{"cn":[947456,109376]}], +"textures/segment2/segment2_cn.1AB50.ia1.png": [16,8,16,{"cn":[947456,109392]}], +"textures/segment2/segment2_cn.1AB60.ia1.png": [16,8,16,{"cn":[947456,109408]}], +"textures/segment2/segment2_cn.1AB70.ia1.png": [16,8,16,{"cn":[947456,109424]}], +"textures/segment2/segment2_cn.1AB80.ia1.png": [16,8,16,{"cn":[947456,109440]}], +"textures/segment2/segment2_cn.1AB90.ia1.png": [16,8,16,{"cn":[947456,109456]}], +"textures/segment2/segment2_cn.1ABA0.ia1.png": [16,8,16,{"cn":[947456,109472]}], +"textures/segment2/segment2_cn.1ABB0.ia1.png": [16,8,16,{"cn":[947456,109488]}], +"textures/segment2/segment2_cn.1ABC0.ia1.png": [16,8,16,{"cn":[947456,109504]}], +"textures/segment2/segment2_cn.1ABD0.ia1.png": [16,8,16,{"cn":[947456,109520]}], +"textures/segment2/segment2_cn.1ABE0.ia1.png": [16,8,16,{"cn":[947456,109536]}], +"textures/segment2/segment2_cn.1ABF0.ia1.png": [16,8,16,{"cn":[947456,109552]}], +"textures/segment2/segment2_cn.1AC00.ia1.png": [16,8,16,{"cn":[947456,109568]}], +"textures/segment2/segment2_cn.1AC10.ia1.png": [16,8,16,{"cn":[947456,109584]}], +"textures/segment2/segment2_cn.1AC20.ia1.png": [16,8,16,{"cn":[947456,109600]}], +"textures/segment2/segment2_cn.1AC30.ia1.png": [16,8,16,{"cn":[947456,109616]}], +"textures/segment2/segment2_cn.1AC40.ia1.png": [16,8,16,{"cn":[947456,109632]}], +"textures/segment2/segment2_cn.1AC50.ia1.png": [16,8,16,{"cn":[947456,109648]}], +"textures/segment2/segment2_cn.1AC60.ia1.png": [16,8,16,{"cn":[947456,109664]}], +"textures/segment2/segment2_cn.1AC70.ia1.png": [16,8,16,{"cn":[947456,109680]}], +"textures/segment2/segment2_cn.1AC80.ia1.png": [16,8,16,{"cn":[947456,109696]}], +"textures/segment2/segment2_cn.1AC90.ia1.png": [16,8,16,{"cn":[947456,109712]}], +"textures/segment2/segment2_cn.1ACA0.ia1.png": [16,8,16,{"cn":[947456,109728]}], +"textures/segment2/segment2_cn.1ACB0.ia1.png": [16,8,16,{"cn":[947456,109744]}], +"textures/segment2/segment2_cn.1ACC0.ia1.png": [16,8,16,{"cn":[947456,109760]}], +"textures/segment2/segment2_cn.1ACD0.ia1.png": [16,8,16,{"cn":[947456,109776]}], +"textures/segment2/segment2_cn.1ACE0.ia1.png": [16,8,16,{"cn":[947456,109792]}], +"textures/segment2/segment2_cn.1ACF0.ia1.png": [16,8,16,{"cn":[947456,109808]}], +"textures/segment2/segment2_cn.1AD00.ia1.png": [16,8,16,{"cn":[947456,109824]}], +"textures/segment2/segment2_cn.1AD10.ia1.png": [16,8,16,{"cn":[947456,109840]}], +"textures/segment2/segment2_cn.1AD20.ia1.png": [16,8,16,{"cn":[947456,109856]}], +"textures/segment2/segment2_cn.1AD30.ia1.png": [16,8,16,{"cn":[947456,109872]}], +"textures/segment2/segment2_cn.1AD40.ia1.png": [16,8,16,{"cn":[947456,109888]}], +"textures/segment2/segment2_cn.1AD50.ia1.png": [16,8,16,{"cn":[947456,109904]}], +"textures/segment2/segment2_cn.1AD60.ia1.png": [16,8,16,{"cn":[947456,109920]}], +"textures/segment2/segment2_cn.1AD70.ia1.png": [16,8,16,{"cn":[947456,109936]}], +"textures/segment2/segment2_cn.1AD80.ia1.png": [16,8,16,{"cn":[947456,109952]}], +"textures/segment2/segment2_cn.1AD90.ia1.png": [16,8,16,{"cn":[947456,109968]}], +"textures/segment2/segment2_cn.1ADA0.ia1.png": [16,8,16,{"cn":[947456,109984]}], +"textures/segment2/segment2_cn.1ADB0.ia1.png": [16,8,16,{"cn":[947456,110000]}], +"textures/segment2/segment2_cn.1ADC0.ia1.png": [16,8,16,{"cn":[947456,110016]}], +"textures/segment2/segment2_cn.1ADD0.ia1.png": [16,8,16,{"cn":[947456,110032]}], +"textures/segment2/segment2_cn.1ADE0.ia1.png": [16,8,16,{"cn":[947456,110048]}], +"textures/segment2/segment2_cn.1ADF0.ia1.png": [16,8,16,{"cn":[947456,110064]}], +"textures/segment2/segment2_cn.1AE00.ia1.png": [16,8,16,{"cn":[947456,110080]}], +"textures/segment2/segment2_cn.1AE10.ia1.png": [16,8,16,{"cn":[947456,110096]}], +"textures/segment2/segment2_cn.1AE20.ia1.png": [16,8,16,{"cn":[947456,110112]}], +"textures/segment2/segment2_cn.1AE30.ia1.png": [16,8,16,{"cn":[947456,110128]}], +"textures/segment2/segment2_cn.1AE40.ia1.png": [16,8,16,{"cn":[947456,110144]}], +"textures/segment2/segment2_cn.1AE50.ia1.png": [16,8,16,{"cn":[947456,110160]}], +"textures/segment2/segment2_cn.1AE60.ia1.png": [16,8,16,{"cn":[947456,110176]}], +"textures/segment2/segment2_cn.1AE70.ia1.png": [16,8,16,{"cn":[947456,110192]}], +"textures/segment2/segment2_cn.1AE80.ia1.png": [16,8,16,{"cn":[947456,110208]}], +"textures/segment2/segment2_cn.1AE90.ia1.png": [16,8,16,{"cn":[947456,110224]}], +"textures/segment2/segment2_cn.1AEA0.ia1.png": [16,8,16,{"cn":[947456,110240]}], +"textures/segment2/segment2_cn.1AEB0.ia1.png": [16,8,16,{"cn":[947456,110256]}], +"textures/segment2/segment2_cn.1AEC0.ia1.png": [16,8,16,{"cn":[947456,110272]}], +"textures/segment2/segment2_cn.1AED0.ia1.png": [16,8,16,{"cn":[947456,110288]}], +"textures/segment2/segment2_cn.1AEE0.ia1.png": [16,8,16,{"cn":[947456,110304]}], +"textures/segment2/segment2_cn.1AEF0.ia1.png": [16,8,16,{"cn":[947456,110320]}], +"textures/segment2/segment2_cn.1AF00.ia1.png": [16,8,16,{"cn":[947456,110336]}], +"textures/segment2/segment2_cn.1AF10.ia1.png": [16,8,16,{"cn":[947456,110352]}], +"textures/segment2/segment2_cn.1AF20.ia1.png": [16,8,16,{"cn":[947456,110368]}], +"textures/segment2/segment2_cn.1AF30.ia1.png": [16,8,16,{"cn":[947456,110384]}], +"textures/segment2/segment2_cn.1AF40.ia1.png": [16,8,16,{"cn":[947456,110400]}], +"textures/segment2/segment2_cn.1AF50.ia1.png": [16,8,16,{"cn":[947456,110416]}], +"textures/segment2/segment2_cn.1AF60.ia1.png": [16,8,16,{"cn":[947456,110432]}], +"textures/segment2/segment2_cn.1AF70.ia1.png": [16,8,16,{"cn":[947456,110448]}], +"textures/segment2/segment2_cn.1AF80.ia1.png": [16,8,16,{"cn":[947456,110464]}], +"textures/segment2/segment2_cn.1AF90.ia1.png": [16,8,16,{"cn":[947456,110480]}], +"textures/segment2/segment2_cn.1AFA0.ia1.png": [16,8,16,{"cn":[947456,110496]}], +"textures/segment2/segment2_cn.1AFB0.ia1.png": [16,8,16,{"cn":[947456,110512]}], +"textures/segment2/segment2_cn.1AFC0.ia1.png": [16,8,16,{"cn":[947456,110528]}], +"textures/segment2/segment2_cn.1AFD0.ia1.png": [16,8,16,{"cn":[947456,110544]}], +"textures/segment2/segment2_cn.1AFE0.ia1.png": [16,8,16,{"cn":[947456,110560]}], +"textures/segment2/segment2_cn.1AFF0.ia1.png": [16,8,16,{"cn":[947456,110576]}], +"textures/segment2/segment2_cn.1B000.ia1.png": [16,8,16,{"cn":[947456,110592]}], +"textures/segment2/segment2_cn.1B010.ia1.png": [16,8,16,{"cn":[947456,110608]}], +"textures/segment2/segment2_cn.1B020.ia1.png": [16,8,16,{"cn":[947456,110624]}], +"textures/segment2/segment2_cn.1B030.ia1.png": [16,8,16,{"cn":[947456,110640]}], +"textures/segment2/segment2_cn.1B040.ia1.png": [16,8,16,{"cn":[947456,110656]}], +"textures/segment2/segment2_cn.1B050.ia1.png": [16,8,16,{"cn":[947456,110672]}], +"textures/segment2/segment2_cn.1B060.ia1.png": [16,8,16,{"cn":[947456,110688]}], +"textures/segment2/segment2_cn.1B070.ia1.png": [16,8,16,{"cn":[947456,110704]}], +"textures/segment2/segment2_cn.1B080.ia1.png": [16,8,16,{"cn":[947456,110720]}], +"textures/segment2/segment2_cn.1B090.ia1.png": [16,8,16,{"cn":[947456,110736]}], +"textures/segment2/segment2_cn.1B0A0.ia1.png": [16,8,16,{"cn":[947456,110752]}], +"textures/segment2/segment2_cn.1B0B0.ia1.png": [16,8,16,{"cn":[947456,110768]}], +"textures/segment2/segment2_cn.1B0C0.ia1.png": [16,8,16,{"cn":[947456,110784]}], +"textures/segment2/segment2_cn.1B0D0.ia1.png": [16,8,16,{"cn":[947456,110800]}], +"textures/segment2/segment2_cn.1B0E0.ia1.png": [16,8,16,{"cn":[947456,110816]}], +"textures/segment2/segment2_cn.1B0F0.ia1.png": [16,8,16,{"cn":[947456,110832]}], +"textures/segment2/segment2_cn.1B100.ia1.png": [16,8,16,{"cn":[947456,110848]}], +"textures/segment2/segment2_cn.1B110.ia1.png": [16,8,16,{"cn":[947456,110864]}], +"textures/segment2/segment2_cn.1B120.ia1.png": [16,8,16,{"cn":[947456,110880]}], +"textures/segment2/segment2_cn.1B130.ia1.png": [16,8,16,{"cn":[947456,110896]}], +"textures/segment2/segment2_cn.1B140.ia1.png": [16,8,16,{"cn":[947456,110912]}], +"textures/segment2/segment2_cn.1B150.ia1.png": [16,8,16,{"cn":[947456,110928]}], +"textures/segment2/segment2_cn.1B160.ia1.png": [16,8,16,{"cn":[947456,110944]}], +"textures/segment2/segment2_cn.1B170.ia1.png": [16,8,16,{"cn":[947456,110960]}], +"textures/segment2/segment2_cn.1B180.ia1.png": [16,8,16,{"cn":[947456,110976]}], +"textures/segment2/segment2_cn.1B190.ia1.png": [16,8,16,{"cn":[947456,110992]}], +"textures/segment2/segment2_cn.1B1A0.ia1.png": [16,8,16,{"cn":[947456,111008]}], +"textures/segment2/segment2_cn.1B1B0.ia1.png": [16,8,16,{"cn":[947456,111024]}], +"textures/segment2/segment2_cn.1B1C0.ia1.png": [16,8,16,{"cn":[947456,111040]}], +"textures/segment2/segment2_cn.1B1D0.ia1.png": [16,8,16,{"cn":[947456,111056]}], +"textures/segment2/segment2_cn.1B1E0.ia1.png": [16,8,16,{"cn":[947456,111072]}], +"textures/segment2/segment2_cn.1B1F0.ia1.png": [16,8,16,{"cn":[947456,111088]}], +"textures/segment2/segment2_cn.1B200.ia1.png": [16,8,16,{"cn":[947456,111104]}], +"textures/segment2/segment2_cn.1B210.ia1.png": [16,8,16,{"cn":[947456,111120]}], +"textures/segment2/segment2_cn.1B220.ia1.png": [16,8,16,{"cn":[947456,111136]}], +"textures/segment2/segment2_cn.1B230.ia1.png": [16,8,16,{"cn":[947456,111152]}], +"textures/segment2/segment2_cn.1B240.ia1.png": [16,8,16,{"cn":[947456,111168]}], +"textures/segment2/segment2_cn.1B250.ia1.png": [16,8,16,{"cn":[947456,111184]}], +"textures/segment2/segment2_cn.1B260.ia1.png": [16,8,16,{"cn":[947456,111200]}], +"textures/segment2/segment2_cn.1B270.ia1.png": [16,8,16,{"cn":[947456,111216]}], +"textures/segment2/segment2_cn.1B280.ia1.png": [16,8,16,{"cn":[947456,111232]}], +"textures/segment2/segment2_cn.1B290.ia1.png": [16,8,16,{"cn":[947456,111248]}], +"textures/segment2/segment2_cn.1B2A0.ia1.png": [16,8,16,{"cn":[947456,111264]}], +"textures/segment2/segment2_cn.1B2B0.ia1.png": [16,8,16,{"cn":[947456,111280]}], +"textures/segment2/segment2_cn.1B2C0.ia1.png": [16,8,16,{"cn":[947456,111296]}], +"textures/segment2/segment2_cn.1B2D0.ia1.png": [16,8,16,{"cn":[947456,111312]}], +"textures/segment2/segment2_cn.1B2E0.ia1.png": [16,8,16,{"cn":[947456,111328]}], +"textures/segment2/segment2_cn.1B2F0.ia1.png": [16,8,16,{"cn":[947456,111344]}], +"textures/segment2/segment2_cn.1B300.ia1.png": [16,8,16,{"cn":[947456,111360]}], +"textures/segment2/segment2_cn.1B310.ia1.png": [16,8,16,{"cn":[947456,111376]}], +"textures/segment2/segment2_cn.1B320.ia1.png": [16,8,16,{"cn":[947456,111392]}], +"textures/segment2/segment2_cn.1B330.ia1.png": [16,8,16,{"cn":[947456,111408]}], +"textures/segment2/segment2_cn.1B340.ia1.png": [16,8,16,{"cn":[947456,111424]}], +"textures/segment2/segment2_cn.1B350.ia1.png": [16,8,16,{"cn":[947456,111440]}], +"textures/segment2/segment2_cn.1B360.ia1.png": [16,8,16,{"cn":[947456,111456]}], +"textures/segment2/segment2_cn.1B370.ia1.png": [16,8,16,{"cn":[947456,111472]}], +"textures/segment2/segment2_cn.1B380.ia1.png": [16,8,16,{"cn":[947456,111488]}], +"textures/segment2/segment2_cn.1B390.ia1.png": [16,8,16,{"cn":[947456,111504]}], +"textures/segment2/segment2_cn.1B3A0.ia1.png": [16,8,16,{"cn":[947456,111520]}], +"textures/segment2/segment2_cn.1B3B0.ia1.png": [16,8,16,{"cn":[947456,111536]}], +"textures/segment2/segment2_cn.1B3C0.ia1.png": [16,8,16,{"cn":[947456,111552]}], +"textures/segment2/segment2_cn.1B3D0.ia1.png": [16,8,16,{"cn":[947456,111568]}], +"textures/segment2/segment2_cn.1B3E0.ia1.png": [16,8,16,{"cn":[947456,111584]}], +"textures/segment2/segment2_cn.1B3F0.ia1.png": [16,8,16,{"cn":[947456,111600]}], +"textures/segment2/segment2_cn.1B400.ia1.png": [16,8,16,{"cn":[947456,111616]}], +"textures/segment2/segment2_cn.1B410.ia1.png": [16,8,16,{"cn":[947456,111632]}], +"textures/segment2/segment2_cn.1B420.ia1.png": [16,8,16,{"cn":[947456,111648]}], +"textures/segment2/segment2_cn.1B430.ia1.png": [16,8,16,{"cn":[947456,111664]}], +"textures/segment2/segment2_cn.1B440.ia1.png": [16,8,16,{"cn":[947456,111680]}], +"textures/segment2/segment2_cn.1B450.ia1.png": [16,8,16,{"cn":[947456,111696]}], +"textures/segment2/segment2_cn.1B460.ia1.png": [16,8,16,{"cn":[947456,111712]}], +"textures/segment2/segment2_cn.1B470.ia1.png": [16,8,16,{"cn":[947456,111728]}], +"textures/segment2/segment2_cn.1B480.ia1.png": [16,8,16,{"cn":[947456,111744]}], +"textures/segment2/segment2_cn.1B490.ia1.png": [16,8,16,{"cn":[947456,111760]}], +"textures/segment2/segment2_cn.1B4A0.ia1.png": [16,8,16,{"cn":[947456,111776]}], +"textures/segment2/segment2_cn.1B4B0.ia1.png": [16,8,16,{"cn":[947456,111792]}], +"textures/segment2/segment2_cn.1B4C0.ia1.png": [16,8,16,{"cn":[947456,111808]}], +"textures/segment2/segment2_cn.1B4D0.ia1.png": [16,8,16,{"cn":[947456,111824]}], +"textures/segment2/segment2_cn.1B4E0.ia1.png": [16,8,16,{"cn":[947456,111840]}], +"textures/segment2/segment2_cn.1B4F0.ia1.png": [16,8,16,{"cn":[947456,111856]}], +"textures/segment2/segment2_cn.1B500.ia1.png": [16,8,16,{"cn":[947456,111872]}], +"textures/segment2/segment2_cn.1B510.ia1.png": [16,8,16,{"cn":[947456,111888]}], +"textures/segment2/segment2_cn.1B520.ia1.png": [16,8,16,{"cn":[947456,111904]}], +"textures/segment2/segment2_cn.1B530.ia1.png": [16,8,16,{"cn":[947456,111920]}], +"textures/segment2/segment2_cn.1B540.ia1.png": [16,8,16,{"cn":[947456,111936]}], +"textures/segment2/segment2_cn.1B550.ia1.png": [16,8,16,{"cn":[947456,111952]}], +"textures/segment2/segment2_cn.1B560.ia1.png": [16,8,16,{"cn":[947456,111968]}], +"textures/segment2/segment2_cn.1B570.ia1.png": [16,8,16,{"cn":[947456,111984]}], +"textures/segment2/segment2_cn.1B580.ia1.png": [16,8,16,{"cn":[947456,112000]}], +"textures/segment2/segment2_cn.1B590.ia1.png": [16,8,16,{"cn":[947456,112016]}], +"textures/segment2/segment2_cn.1B5A0.ia1.png": [16,8,16,{"cn":[947456,112032]}], +"textures/segment2/segment2_cn.1B5B0.ia1.png": [16,8,16,{"cn":[947456,112048]}], +"textures/segment2/segment2_cn.1B5C0.ia1.png": [16,8,16,{"cn":[947456,112064]}], +"textures/segment2/segment2_cn.1B5D0.ia1.png": [16,8,16,{"cn":[947456,112080]}], +"textures/segment2/segment2_cn.1B5E0.ia1.png": [16,8,16,{"cn":[947456,112096]}], +"textures/segment2/segment2_cn.1B5F0.ia1.png": [16,8,16,{"cn":[947456,112112]}], +"textures/segment2/segment2_cn.1B600.ia1.png": [16,8,16,{"cn":[947456,112128]}], +"textures/segment2/segment2_cn.1B610.ia1.png": [16,8,16,{"cn":[947456,112144]}], +"textures/segment2/segment2_cn.1B620.ia1.png": [16,8,16,{"cn":[947456,112160]}], +"textures/segment2/segment2_cn.1B630.ia1.png": [16,8,16,{"cn":[947456,112176]}], +"textures/segment2/segment2_cn.1B640.ia1.png": [16,8,16,{"cn":[947456,112192]}], +"textures/segment2/segment2_cn.1B650.ia1.png": [16,8,16,{"cn":[947456,112208]}], +"textures/segment2/segment2_cn.1B660.ia1.png": [16,8,16,{"cn":[947456,112224]}], +"textures/segment2/segment2_cn.1B670.ia1.png": [16,8,16,{"cn":[947456,112240]}], +"textures/segment2/segment2_cn.1B680.ia1.png": [16,8,16,{"cn":[947456,112256]}], +"textures/segment2/segment2_cn.1B690.ia1.png": [16,8,16,{"cn":[947456,112272]}], +"textures/segment2/segment2_cn.1B6A0.ia1.png": [16,8,16,{"cn":[947456,112288]}], +"textures/segment2/segment2_cn.1B6B0.ia1.png": [16,8,16,{"cn":[947456,112304]}], +"textures/segment2/segment2_cn.1B6C0.ia1.png": [16,8,16,{"cn":[947456,112320]}], +"textures/segment2/segment2_cn.1B6D0.ia1.png": [16,8,16,{"cn":[947456,112336]}], +"textures/segment2/segment2_cn.1B6E0.ia1.png": [16,8,16,{"cn":[947456,112352]}], +"textures/segment2/segment2_cn.1B6F0.ia1.png": [16,8,16,{"cn":[947456,112368]}], +"textures/segment2/segment2_cn.1B700.ia1.png": [16,8,16,{"cn":[947456,112384]}], +"textures/segment2/segment2_cn.1B710.ia1.png": [16,8,16,{"cn":[947456,112400]}], +"textures/segment2/segment2_cn.1B720.ia1.png": [16,8,16,{"cn":[947456,112416]}], +"textures/segment2/segment2_cn.1B730.ia1.png": [16,8,16,{"cn":[947456,112432]}], +"textures/segment2/segment2_cn.1B740.ia1.png": [16,8,16,{"cn":[947456,112448]}], +"textures/segment2/segment2_cn.1B750.ia1.png": [16,8,16,{"cn":[947456,112464]}], +"textures/segment2/segment2_cn.1B760.ia1.png": [16,8,16,{"cn":[947456,112480]}], +"textures/segment2/segment2_cn.1B770.ia1.png": [16,8,16,{"cn":[947456,112496]}], +"textures/segment2/segment2_cn.1B780.ia1.png": [16,8,16,{"cn":[947456,112512]}], +"textures/segment2/segment2_cn.1B790.ia1.png": [16,8,16,{"cn":[947456,112528]}], +"textures/segment2/segment2_cn.1B7A0.ia1.png": [16,8,16,{"cn":[947456,112544]}], +"textures/segment2/segment2_cn.1B7B0.ia1.png": [16,8,16,{"cn":[947456,112560]}], +"textures/segment2/segment2_cn.1B7C0.ia1.png": [16,8,16,{"cn":[947456,112576]}], +"textures/segment2/segment2_cn.1B7D0.ia1.png": [16,8,16,{"cn":[947456,112592]}], +"textures/segment2/segment2_cn.1B7E0.ia1.png": [16,8,16,{"cn":[947456,112608]}], +"textures/segment2/segment2_cn.1B7F0.ia1.png": [16,8,16,{"cn":[947456,112624]}], +"textures/segment2/segment2_cn.1B800.ia1.png": [16,8,16,{"cn":[947456,112640]}], +"textures/segment2/segment2_cn.1B810.ia1.png": [16,8,16,{"cn":[947456,112656]}], +"textures/segment2/segment2_cn.1B820.ia1.png": [16,8,16,{"cn":[947456,112672]}], +"textures/segment2/segment2_cn.1B830.ia1.png": [16,8,16,{"cn":[947456,112688]}], +"textures/segment2/segment2_cn.1B840.ia1.png": [16,8,16,{"cn":[947456,112704]}], +"textures/segment2/segment2_cn.1B850.ia1.png": [16,8,16,{"cn":[947456,112720]}], +"textures/segment2/segment2_cn.1B860.ia1.png": [16,8,16,{"cn":[947456,112736]}], +"textures/segment2/segment2_cn.1B870.ia1.png": [16,8,16,{"cn":[947456,112752]}], +"textures/segment2/segment2_cn.1B880.ia1.png": [16,8,16,{"cn":[947456,112768]}], +"textures/segment2/segment2_cn.1B890.ia1.png": [16,8,16,{"cn":[947456,112784]}], +"textures/segment2/segment2_cn.1B8A0.ia1.png": [16,8,16,{"cn":[947456,112800]}], +"textures/segment2/segment2_cn.1B8B0.ia1.png": [16,8,16,{"cn":[947456,112816]}], +"textures/segment2/segment2_cn.1B8C0.ia1.png": [16,8,16,{"cn":[947456,112832]}], +"textures/segment2/segment2_cn.1B8D0.ia1.png": [16,8,16,{"cn":[947456,112848]}], +"textures/segment2/segment2_cn.1B8E0.ia1.png": [16,8,16,{"cn":[947456,112864]}], +"textures/segment2/segment2_cn.1B8F0.ia1.png": [16,8,16,{"cn":[947456,112880]}], +"textures/segment2/segment2_cn.1B900.ia1.png": [16,8,16,{"cn":[947456,112896]}], +"textures/segment2/segment2_cn.1B910.ia1.png": [16,8,16,{"cn":[947456,112912]}], +"textures/segment2/segment2_cn.1B920.ia1.png": [16,8,16,{"cn":[947456,112928]}], +"textures/segment2/segment2_cn.1B930.ia1.png": [16,8,16,{"cn":[947456,112944]}], +"textures/segment2/segment2_cn.1B940.ia1.png": [16,8,16,{"cn":[947456,112960]}], +"textures/segment2/segment2_cn.1B950.ia1.png": [16,8,16,{"cn":[947456,112976]}], +"textures/segment2/segment2_cn.1B960.ia1.png": [16,8,16,{"cn":[947456,112992]}], +"textures/segment2/segment2_cn.1B970.ia1.png": [16,8,16,{"cn":[947456,113008]}], +"textures/segment2/segment2_cn.1B980.ia1.png": [16,8,16,{"cn":[947456,113024]}], +"textures/segment2/segment2_cn.1B990.ia1.png": [16,8,16,{"cn":[947456,113040]}], +"textures/segment2/segment2_cn.1B9A0.ia1.png": [16,8,16,{"cn":[947456,113056]}], +"textures/segment2/segment2_cn.1B9B0.ia1.png": [16,8,16,{"cn":[947456,113072]}], +"textures/segment2/segment2_cn.1B9C0.ia1.png": [16,8,16,{"cn":[947456,113088]}], +"textures/segment2/segment2_cn.1B9D0.ia1.png": [16,8,16,{"cn":[947456,113104]}], +"textures/segment2/segment2_cn.1B9E0.ia1.png": [16,8,16,{"cn":[947456,113120]}], +"textures/segment2/segment2_cn.1B9F0.ia1.png": [16,8,16,{"cn":[947456,113136]}], +"textures/segment2/segment2_cn.1BA00.ia1.png": [16,8,16,{"cn":[947456,113152]}], +"textures/segment2/segment2_cn.1BA10.ia1.png": [16,8,16,{"cn":[947456,113168]}], +"textures/segment2/segment2_cn.1BA20.ia1.png": [16,8,16,{"cn":[947456,113184]}], +"textures/segment2/segment2_cn.1BA30.ia1.png": [16,8,16,{"cn":[947456,113200]}], +"textures/segment2/segment2_cn.1BA40.ia1.png": [16,8,16,{"cn":[947456,113216]}], +"textures/segment2/segment2_cn.1BA50.ia1.png": [16,8,16,{"cn":[947456,113232]}], +"textures/segment2/segment2_cn.1BA60.ia1.png": [16,8,16,{"cn":[947456,113248]}], +"textures/segment2/segment2_cn.1BA70.ia1.png": [16,8,16,{"cn":[947456,113264]}], +"textures/segment2/segment2_cn.1BA80.ia1.png": [16,8,16,{"cn":[947456,113280]}], +"textures/segment2/segment2_cn.1BA90.ia1.png": [16,8,16,{"cn":[947456,113296]}], +"textures/segment2/segment2_cn.1BAA0.ia1.png": [16,8,16,{"cn":[947456,113312]}], +"textures/segment2/segment2_cn.1BAB0.ia1.png": [16,8,16,{"cn":[947456,113328]}], +"textures/segment2/segment2_cn.1BAC0.ia1.png": [16,8,16,{"cn":[947456,113344]}], +"textures/segment2/segment2_cn.1BAD0.ia1.png": [16,8,16,{"cn":[947456,113360]}], +"textures/segment2/segment2_cn.1BAE0.ia1.png": [16,8,16,{"cn":[947456,113376]}], +"textures/segment2/segment2_cn.1BAF0.ia1.png": [16,8,16,{"cn":[947456,113392]}], +"textures/segment2/segment2_cn.1BB00.ia1.png": [16,8,16,{"cn":[947456,113408]}], +"textures/segment2/segment2_cn.1BB10.ia1.png": [16,8,16,{"cn":[947456,113424]}], +"textures/segment2/segment2_cn.1BB20.ia1.png": [16,8,16,{"cn":[947456,113440]}], +"textures/segment2/segment2_cn.1BB30.ia1.png": [16,8,16,{"cn":[947456,113456]}], +"textures/segment2/segment2_cn.1BB40.ia1.png": [16,8,16,{"cn":[947456,113472]}], +"textures/segment2/segment2_cn.1BB50.ia1.png": [16,8,16,{"cn":[947456,113488]}], +"textures/segment2/segment2_cn.1BB60.ia1.png": [16,8,16,{"cn":[947456,113504]}], +"textures/segment2/segment2_cn.1BB70.ia1.png": [16,8,16,{"cn":[947456,113520]}], +"textures/segment2/segment2_cn.1BB80.ia1.png": [16,8,16,{"cn":[947456,113536]}], +"textures/segment2/segment2_cn.1BB90.ia1.png": [16,8,16,{"cn":[947456,113552]}], +"textures/segment2/segment2_cn.1BBA0.ia1.png": [16,8,16,{"cn":[947456,113568]}], +"textures/segment2/segment2_cn.1BBB0.ia1.png": [16,8,16,{"cn":[947456,113584]}], +"textures/segment2/segment2_cn.1BBC0.ia1.png": [16,8,16,{"cn":[947456,113600]}], +"textures/segment2/segment2_cn.1BBD0.ia1.png": [16,8,16,{"cn":[947456,113616]}], +"textures/segment2/segment2_cn.1BBE0.ia1.png": [16,8,16,{"cn":[947456,113632]}], +"textures/segment2/segment2_cn.1BBF0.ia1.png": [16,8,16,{"cn":[947456,113648]}], +"textures/segment2/segment2_cn.1BC00.ia1.png": [16,8,16,{"cn":[947456,113664]}], +"textures/segment2/segment2_cn.1BC10.ia1.png": [16,8,16,{"cn":[947456,113680]}], +"textures/segment2/segment2_cn.1BC20.ia1.png": [16,8,16,{"cn":[947456,113696]}], +"textures/segment2/segment2_cn.1BC30.ia1.png": [16,8,16,{"cn":[947456,113712]}], +"textures/segment2/segment2_cn.1BC40.ia1.png": [16,8,16,{"cn":[947456,113728]}], +"textures/segment2/segment2_cn.1BC50.ia1.png": [16,8,16,{"cn":[947456,113744]}], +"textures/segment2/segment2_cn.1BC60.ia1.png": [16,8,16,{"cn":[947456,113760]}], +"textures/segment2/segment2_cn.1BC70.ia1.png": [16,8,16,{"cn":[947456,113776]}], +"textures/segment2/segment2_cn.1BC80.ia1.png": [16,8,16,{"cn":[947456,113792]}], +"textures/segment2/segment2_cn.1BC90.ia1.png": [16,8,16,{"cn":[947456,113808]}], +"textures/segment2/segment2_cn.1BCA0.ia1.png": [16,8,16,{"cn":[947456,113824]}], +"textures/segment2/segment2_cn.1BCB0.ia1.png": [16,8,16,{"cn":[947456,113840]}], +"textures/segment2/segment2_cn.1BCC0.ia1.png": [16,8,16,{"cn":[947456,113856]}], +"textures/segment2/segment2_cn.1BCD0.ia1.png": [16,8,16,{"cn":[947456,113872]}], +"textures/segment2/segment2_cn.1BCE0.ia1.png": [16,8,16,{"cn":[947456,113888]}], +"textures/segment2/segment2_cn.1BCF0.ia1.png": [16,8,16,{"cn":[947456,113904]}], +"textures/segment2/segment2_cn.1BD00.ia1.png": [16,8,16,{"cn":[947456,113920]}], +"textures/segment2/segment2_cn.1BD10.ia1.png": [16,8,16,{"cn":[947456,113936]}], +"textures/segment2/segment2_cn.1BD20.ia1.png": [16,8,16,{"cn":[947456,113952]}], +"textures/segment2/segment2_cn.1BD30.ia1.png": [16,8,16,{"cn":[947456,113968]}], +"textures/segment2/segment2_cn.1BD40.ia1.png": [16,8,16,{"cn":[947456,113984]}], +"textures/segment2/segment2_cn.1BD50.ia1.png": [16,8,16,{"cn":[947456,114000]}], +"textures/segment2/segment2_cn.1BD60.ia1.png": [16,8,16,{"cn":[947456,114016]}], +"textures/segment2/segment2_cn.1BD70.ia1.png": [16,8,16,{"cn":[947456,114032]}], +"textures/segment2/segment2_cn.1BD80.ia1.png": [16,8,16,{"cn":[947456,114048]}], +"textures/segment2/segment2_cn.1BD90.ia1.png": [16,8,16,{"cn":[947456,114064]}], +"textures/segment2/segment2_cn.1BDA0.ia1.png": [16,8,16,{"cn":[947456,114080]}], +"textures/segment2/segment2_cn.1BDB0.ia1.png": [16,8,16,{"cn":[947456,114096]}], +"textures/segment2/segment2_cn.1BDC0.ia1.png": [16,8,16,{"cn":[947456,114112]}], +"textures/segment2/segment2_cn.1BDD0.ia1.png": [16,8,16,{"cn":[947456,114128]}], +"textures/segment2/segment2_cn.1BDE0.ia1.png": [16,8,16,{"cn":[947456,114144]}], +"textures/segment2/segment2_cn.1BDF0.ia1.png": [16,8,16,{"cn":[947456,114160]}], +"textures/segment2/segment2_cn.1BE00.ia1.png": [16,8,16,{"cn":[947456,114176]}], +"textures/segment2/segment2_cn.1BE10.ia1.png": [16,8,16,{"cn":[947456,114192]}], +"textures/segment2/segment2_cn.1BE20.ia1.png": [16,8,16,{"cn":[947456,114208]}], +"textures/segment2/segment2_cn.1BE30.ia1.png": [16,8,16,{"cn":[947456,114224]}], +"textures/segment2/segment2_cn.1BE40.ia1.png": [16,8,16,{"cn":[947456,114240]}], +"textures/segment2/segment2_cn.1BE50.ia1.png": [16,8,16,{"cn":[947456,114256]}], +"textures/segment2/segment2_cn.1BE60.ia1.png": [16,8,16,{"cn":[947456,114272]}], +"textures/segment2/segment2_cn.1BE70.ia1.png": [16,8,16,{"cn":[947456,114288]}], +"textures/segment2/segment2_cn.1BE80.ia1.png": [16,8,16,{"cn":[947456,114304]}], +"textures/segment2/segment2_cn.1BE90.ia1.png": [16,8,16,{"cn":[947456,114320]}], +"textures/segment2/segment2_cn.1BEA0.ia1.png": [16,8,16,{"cn":[947456,114336]}], +"textures/segment2/segment2_cn.1BEB0.ia1.png": [16,8,16,{"cn":[947456,114352]}], +"textures/segment2/segment2_cn.1BEC0.ia1.png": [16,8,16,{"cn":[947456,114368]}], +"textures/segment2/segment2_cn.1BED0.ia1.png": [16,8,16,{"cn":[947456,114384]}], +"textures/segment2/segment2_cn.1BEE0.ia1.png": [16,8,16,{"cn":[947456,114400]}], +"textures/segment2/segment2_cn.1BEF0.ia1.png": [16,8,16,{"cn":[947456,114416]}], +"textures/segment2/segment2_cn.1BF00.ia1.png": [16,8,16,{"cn":[947456,114432]}], +"textures/segment2/segment2_cn.1BF10.ia1.png": [16,8,16,{"cn":[947456,114448]}], +"textures/segment2/segment2_cn.1BF20.ia1.png": [16,8,16,{"cn":[947456,114464]}], +"textures/segment2/segment2_cn.1BF30.ia1.png": [16,8,16,{"cn":[947456,114480]}], +"textures/segment2/segment2_cn.1BF40.ia1.png": [16,8,16,{"cn":[947456,114496]}], +"textures/segment2/segment2_cn.1BF50.ia1.png": [16,8,16,{"cn":[947456,114512]}], +"textures/segment2/segment2_cn.1BF60.ia1.png": [16,8,16,{"cn":[947456,114528]}], +"textures/segment2/segment2_cn.1BF70.ia1.png": [16,8,16,{"cn":[947456,114544]}], +"textures/segment2/segment2_cn.1BF80.ia1.png": [16,8,16,{"cn":[947456,114560]}], +"textures/segment2/segment2_cn.1BF90.ia1.png": [16,8,16,{"cn":[947456,114576]}], +"textures/segment2/segment2_cn.1BFA0.ia1.png": [16,8,16,{"cn":[947456,114592]}], +"textures/segment2/segment2_cn.1BFB0.ia1.png": [16,8,16,{"cn":[947456,114608]}], +"textures/segment2/segment2_cn.1BFC0.ia1.png": [16,8,16,{"cn":[947456,114624]}], +"textures/segment2/segment2_cn.1BFD0.ia1.png": [16,8,16,{"cn":[947456,114640]}], +"textures/segment2/segment2_cn.1BFE0.ia1.png": [16,8,16,{"cn":[947456,114656]}], +"textures/segment2/segment2_cn.1BFF0.ia1.png": [16,8,16,{"cn":[947456,114672]}], +"textures/segment2/segment2_cn.1C000.ia1.png": [16,8,16,{"cn":[947456,114688]}], +"textures/segment2/segment2_cn.1C010.ia1.png": [16,8,16,{"cn":[947456,114704]}], +"textures/segment2/segment2_cn.1C020.ia1.png": [16,8,16,{"cn":[947456,114720]}], +"textures/segment2/segment2_cn.1C030.ia1.png": [16,8,16,{"cn":[947456,114736]}], +"textures/segment2/segment2_cn.1C040.ia1.png": [16,8,16,{"cn":[947456,114752]}], +"textures/segment2/segment2_cn.1C050.ia1.png": [16,8,16,{"cn":[947456,114768]}], +"textures/segment2/segment2_cn.1C060.ia1.png": [16,8,16,{"cn":[947456,114784]}], +"textures/segment2/segment2_cn.1C070.ia1.png": [16,8,16,{"cn":[947456,114800]}], +"textures/segment2/segment2_cn.1C080.ia1.png": [16,8,16,{"cn":[947456,114816]}], +"textures/segment2/segment2_cn.1C090.ia1.png": [16,8,16,{"cn":[947456,114832]}], +"textures/segment2/segment2_cn.1C0A0.ia1.png": [16,8,16,{"cn":[947456,114848]}], +"textures/segment2/segment2_cn.1C0B0.ia1.png": [16,8,16,{"cn":[947456,114864]}], +"textures/segment2/segment2_cn.1C0C0.ia1.png": [16,8,16,{"cn":[947456,114880]}], +"textures/segment2/segment2_cn.1C0D0.ia1.png": [16,8,16,{"cn":[947456,114896]}], +"textures/segment2/segment2_cn.1C0E0.ia1.png": [16,8,16,{"cn":[947456,114912]}], +"textures/segment2/segment2_cn.1C0F0.ia1.png": [16,8,16,{"cn":[947456,114928]}], +"textures/segment2/segment2_cn.1C100.ia1.png": [16,8,16,{"cn":[947456,114944]}], +"textures/segment2/segment2_cn.1C110.ia1.png": [16,8,16,{"cn":[947456,114960]}], +"textures/segment2/segment2_cn.1C120.ia1.png": [16,8,16,{"cn":[947456,114976]}], +"textures/segment2/segment2_cn.1C130.ia1.png": [16,8,16,{"cn":[947456,114992]}], +"textures/segment2/segment2_cn.1C140.ia1.png": [16,8,16,{"cn":[947456,115008]}], +"textures/segment2/segment2_cn.1C150.ia1.png": [16,8,16,{"cn":[947456,115024]}], +"textures/segment2/segment2_cn.1C160.ia1.png": [16,8,16,{"cn":[947456,115040]}], +"textures/segment2/segment2_cn.1C170.ia1.png": [16,8,16,{"cn":[947456,115056]}], +"textures/segment2/segment2_cn.1C180.ia1.png": [16,8,16,{"cn":[947456,115072]}], +"textures/segment2/segment2_cn.1C190.ia1.png": [16,8,16,{"cn":[947456,115088]}], +"textures/segment2/segment2_cn.1C1A0.ia1.png": [16,8,16,{"cn":[947456,115104]}], +"textures/segment2/segment2_cn.1C1B0.ia1.png": [16,8,16,{"cn":[947456,115120]}], +"textures/segment2/segment2_cn.1C1C0.ia1.png": [16,8,16,{"cn":[947456,115136]}], +"textures/segment2/segment2_cn.1C1D0.ia1.png": [16,8,16,{"cn":[947456,115152]}], +"textures/segment2/segment2_cn.1C1E0.ia1.png": [16,8,16,{"cn":[947456,115168]}], +"textures/segment2/segment2_cn.1C1F0.ia1.png": [16,8,16,{"cn":[947456,115184]}], +"textures/segment2/segment2_cn.1C200.ia1.png": [16,8,16,{"cn":[947456,115200]}], +"textures/segment2/segment2_cn.1C210.ia1.png": [16,8,16,{"cn":[947456,115216]}], +"textures/segment2/segment2_cn.1C220.ia1.png": [16,8,16,{"cn":[947456,115232]}], +"textures/segment2/segment2_cn.1C230.ia1.png": [16,8,16,{"cn":[947456,115248]}], +"textures/segment2/segment2_cn.1C240.ia1.png": [16,8,16,{"cn":[947456,115264]}], +"textures/segment2/segment2_cn.1C250.ia1.png": [16,8,16,{"cn":[947456,115280]}], +"textures/segment2/segment2_cn.1C260.ia1.png": [16,8,16,{"cn":[947456,115296]}], +"textures/segment2/segment2_cn.1C270.ia1.png": [16,8,16,{"cn":[947456,115312]}], +"textures/segment2/segment2_cn.1C280.ia1.png": [16,8,16,{"cn":[947456,115328]}], +"textures/segment2/segment2_cn.1C290.ia1.png": [16,8,16,{"cn":[947456,115344]}], +"textures/segment2/segment2_cn.1C2A0.ia1.png": [16,8,16,{"cn":[947456,115360]}], +"textures/segment2/segment2_cn.1C2B0.ia1.png": [16,8,16,{"cn":[947456,115376]}], +"textures/segment2/segment2_cn.1C2C0.ia1.png": [16,8,16,{"cn":[947456,115392]}], +"textures/segment2/segment2_cn.1C2D0.ia1.png": [16,8,16,{"cn":[947456,115408]}], +"textures/segment2/segment2_cn.1C2E0.ia1.png": [16,8,16,{"cn":[947456,115424]}], +"textures/segment2/segment2_cn.1C2F0.ia1.png": [16,8,16,{"cn":[947456,115440]}], +"textures/segment2/segment2_cn.1C300.ia1.png": [16,8,16,{"cn":[947456,115456]}], +"textures/segment2/segment2_cn.1C310.ia1.png": [16,8,16,{"cn":[947456,115472]}], +"textures/segment2/segment2_cn.1C320.ia1.png": [16,8,16,{"cn":[947456,115488]}], +"textures/segment2/segment2_cn.1C330.ia1.png": [16,8,16,{"cn":[947456,115504]}], +"textures/segment2/segment2_cn.1C340.ia1.png": [16,8,16,{"cn":[947456,115520]}], +"textures/segment2/segment2_cn.1C350.ia1.png": [16,8,16,{"cn":[947456,115536]}], +"textures/segment2/segment2_cn.1C360.ia1.png": [16,8,16,{"cn":[947456,115552]}], +"textures/segment2/segment2_cn.1C370.ia1.png": [16,8,16,{"cn":[947456,115568]}], +"textures/segment2/segment2_cn.1C380.ia1.png": [16,8,16,{"cn":[947456,115584]}], +"textures/segment2/segment2_cn.1C390.ia1.png": [16,8,16,{"cn":[947456,115600]}], +"textures/segment2/segment2_cn.1C3A0.ia1.png": [16,8,16,{"cn":[947456,115616]}], +"textures/segment2/segment2_cn.1C3B0.ia1.png": [16,8,16,{"cn":[947456,115632]}], +"textures/segment2/segment2_cn.1C3C0.ia1.png": [16,8,16,{"cn":[947456,115648]}], +"textures/segment2/segment2_cn.1C3D0.ia1.png": [16,8,16,{"cn":[947456,115664]}], +"textures/segment2/segment2_cn.1C3E0.ia1.png": [16,8,16,{"cn":[947456,115680]}], +"textures/segment2/segment2_cn.1C3F0.ia1.png": [16,8,16,{"cn":[947456,115696]}], +"textures/segment2/segment2_cn.1C400.ia1.png": [16,8,16,{"cn":[947456,115712]}], +"textures/segment2/segment2_cn.1C410.ia1.png": [16,8,16,{"cn":[947456,115728]}], +"textures/segment2/segment2_cn.1C420.ia1.png": [16,8,16,{"cn":[947456,115744]}], +"textures/segment2/segment2_cn.1C430.ia1.png": [16,8,16,{"cn":[947456,115760]}], +"textures/segment2/segment2_cn.1C440.ia1.png": [16,8,16,{"cn":[947456,115776]}], +"textures/segment2/segment2_cn.1C450.ia1.png": [16,8,16,{"cn":[947456,115792]}], +"textures/segment2/segment2_cn.1C460.ia1.png": [16,8,16,{"cn":[947456,115808]}], +"textures/segment2/segment2_cn.1C470.ia1.png": [16,8,16,{"cn":[947456,115824]}], +"textures/segment2/segment2_cn.1C480.ia1.png": [16,8,16,{"cn":[947456,115840]}], +"textures/segment2/segment2_cn.1C490.ia1.png": [16,8,16,{"cn":[947456,115856]}], +"textures/segment2/segment2_cn.1C4A0.ia1.png": [16,8,16,{"cn":[947456,115872]}], +"textures/segment2/segment2_cn.1C4B0.ia1.png": [16,8,16,{"cn":[947456,115888]}], +"textures/segment2/segment2_cn.1C4C0.ia1.png": [16,8,16,{"cn":[947456,115904]}], +"textures/segment2/segment2_cn.1C4D0.ia1.png": [16,8,16,{"cn":[947456,115920]}], +"textures/segment2/segment2_cn.1C4E0.ia1.png": [16,8,16,{"cn":[947456,115936]}], +"textures/segment2/segment2_cn.1C4F0.ia1.png": [16,8,16,{"cn":[947456,115952]}], +"textures/segment2/segment2_cn.1C500.ia1.png": [16,8,16,{"cn":[947456,115968]}], +"textures/segment2/segment2_cn.1C510.ia1.png": [16,8,16,{"cn":[947456,115984]}], +"textures/segment2/segment2_cn.1C520.ia1.png": [16,8,16,{"cn":[947456,116000]}], +"textures/segment2/segment2_cn.1C530.ia1.png": [16,8,16,{"cn":[947456,116016]}], +"textures/segment2/segment2_cn.1C540.ia1.png": [16,8,16,{"cn":[947456,116032]}], +"textures/segment2/segment2_cn.1C550.ia1.png": [16,8,16,{"cn":[947456,116048]}], +"textures/segment2/segment2_cn.1C560.ia1.png": [16,8,16,{"cn":[947456,116064]}], +"textures/segment2/segment2_cn.1C570.ia1.png": [16,8,16,{"cn":[947456,116080]}], +"textures/segment2/segment2_cn.1C580.ia1.png": [16,8,16,{"cn":[947456,116096]}], +"textures/segment2/segment2_cn.1C590.ia1.png": [16,8,16,{"cn":[947456,116112]}], +"textures/segment2/segment2_cn.1C5A0.ia1.png": [16,8,16,{"cn":[947456,116128]}], +"textures/segment2/segment2_cn.1C5B0.ia1.png": [16,8,16,{"cn":[947456,116144]}], +"textures/segment2/segment2_cn.1C5C0.ia1.png": [16,8,16,{"cn":[947456,116160]}], +"textures/segment2/segment2_cn.1C5D0.ia1.png": [16,8,16,{"cn":[947456,116176]}], +"textures/segment2/segment2_cn.1C5E0.ia1.png": [16,8,16,{"cn":[947456,116192]}], +"textures/segment2/segment2_cn.1C5F0.ia1.png": [16,8,16,{"cn":[947456,116208]}], +"textures/segment2/segment2_cn.1C600.ia1.png": [16,8,16,{"cn":[947456,116224]}], +"textures/segment2/segment2_cn.1C610.ia1.png": [16,8,16,{"cn":[947456,116240]}], +"textures/segment2/segment2_cn.1C620.ia1.png": [16,8,16,{"cn":[947456,116256]}], +"textures/segment2/segment2_cn.1C630.ia1.png": [16,8,16,{"cn":[947456,116272]}], +"textures/segment2/segment2_cn.1C640.ia1.png": [16,8,16,{"cn":[947456,116288]}], +"textures/segment2/segment2_cn.1C650.ia1.png": [16,8,16,{"cn":[947456,116304]}], +"textures/segment2/segment2_cn.1C660.ia1.png": [16,8,16,{"cn":[947456,116320]}], +"textures/segment2/segment2_cn.1C670.ia1.png": [16,8,16,{"cn":[947456,116336]}], +"textures/segment2/segment2_cn.1C680.ia1.png": [16,8,16,{"cn":[947456,116352]}], +"textures/segment2/segment2_cn.1C690.ia1.png": [16,8,16,{"cn":[947456,116368]}], +"textures/segment2/segment2_cn.1C6A0.ia1.png": [16,8,16,{"cn":[947456,116384]}], +"textures/segment2/segment2_cn.1C6B0.ia1.png": [16,8,16,{"cn":[947456,116400]}], +"textures/segment2/segment2_cn.1C6C0.ia1.png": [16,8,16,{"cn":[947456,116416]}], +"textures/segment2/segment2_cn.1C6D0.ia1.png": [16,8,16,{"cn":[947456,116432]}], +"textures/segment2/segment2_cn.1C6E0.ia1.png": [16,8,16,{"cn":[947456,116448]}], +"textures/segment2/segment2_cn.1C6F0.ia1.png": [16,8,16,{"cn":[947456,116464]}], +"textures/segment2/segment2_cn.1C700.ia1.png": [16,8,16,{"cn":[947456,116480]}], +"textures/segment2/segment2_cn.1C710.ia1.png": [16,8,16,{"cn":[947456,116496]}], +"textures/segment2/segment2_cn.1C720.ia1.png": [16,8,16,{"cn":[947456,116512]}], +"textures/segment2/segment2_cn.1C730.ia1.png": [16,8,16,{"cn":[947456,116528]}], +"textures/segment2/segment2_cn.1C740.ia1.png": [16,8,16,{"cn":[947456,116544]}], +"textures/segment2/segment2_cn.1C750.ia1.png": [16,8,16,{"cn":[947456,116560]}], +"textures/segment2/segment2_cn.1C760.ia1.png": [16,8,16,{"cn":[947456,116576]}], +"textures/segment2/segment2_cn.1C770.ia1.png": [16,8,16,{"cn":[947456,116592]}], +"textures/segment2/segment2_cn.1C780.ia1.png": [16,8,16,{"cn":[947456,116608]}], +"textures/segment2/segment2_cn.1C790.ia1.png": [16,8,16,{"cn":[947456,116624]}], +"textures/segment2/segment2_cn.1C7A0.ia1.png": [16,8,16,{"cn":[947456,116640]}], +"textures/segment2/segment2_cn.1C7B0.ia1.png": [16,8,16,{"cn":[947456,116656]}], +"textures/segment2/segment2_cn.1C7C0.ia1.png": [16,8,16,{"cn":[947456,116672]}], +"textures/segment2/segment2_cn.1C7D0.ia1.png": [16,8,16,{"cn":[947456,116688]}], +"textures/segment2/segment2_cn.1C7E0.ia1.png": [16,8,16,{"cn":[947456,116704]}], +"textures/segment2/segment2_cn.1C7F0.ia1.png": [16,8,16,{"cn":[947456,116720]}], +"textures/segment2/segment2_cn.1C800.ia1.png": [16,8,16,{"cn":[947456,116736]}], +"textures/segment2/segment2_cn.1C810.ia1.png": [16,8,16,{"cn":[947456,116752]}], +"textures/segment2/segment2_cn.1C820.ia1.png": [16,8,16,{"cn":[947456,116768]}], +"textures/segment2/segment2_cn.1C830.ia1.png": [16,8,16,{"cn":[947456,116784]}], +"textures/segment2/segment2_cn.1C840.ia1.png": [16,8,16,{"cn":[947456,116800]}], +"textures/segment2/segment2_cn.1C850.ia1.png": [16,8,16,{"cn":[947456,116816]}], +"textures/segment2/segment2_cn.1C860.ia1.png": [16,8,16,{"cn":[947456,116832]}], +"textures/segment2/segment2_cn.1C870.ia1.png": [16,8,16,{"cn":[947456,116848]}], +"textures/segment2/segment2_cn.1C880.ia1.png": [16,8,16,{"cn":[947456,116864]}], +"textures/segment2/segment2_cn.1C890.ia1.png": [16,8,16,{"cn":[947456,116880]}], +"textures/segment2/segment2_cn.1C8A0.ia1.png": [16,8,16,{"cn":[947456,116896]}], +"textures/segment2/segment2_cn.1C8B0.ia1.png": [16,8,16,{"cn":[947456,116912]}], +"textures/segment2/segment2_cn.1C8C0.ia1.png": [16,8,16,{"cn":[947456,116928]}], +"textures/segment2/segment2_cn.1C8D0.ia1.png": [16,8,16,{"cn":[947456,116944]}], +"textures/segment2/segment2_cn.1C8E0.ia1.png": [16,8,16,{"cn":[947456,116960]}], +"textures/segment2/segment2_cn.1C8F0.ia1.png": [16,8,16,{"cn":[947456,116976]}], +"textures/segment2/segment2_cn.1C900.ia1.png": [16,8,16,{"cn":[947456,116992]}], +"textures/segment2/segment2_cn.1C910.ia1.png": [16,8,16,{"cn":[947456,117008]}], +"textures/segment2/segment2_cn.1C920.ia1.png": [16,8,16,{"cn":[947456,117024]}], +"textures/segment2/segment2_cn.1C930.ia1.png": [16,8,16,{"cn":[947456,117040]}], +"textures/segment2/segment2_cn.1C940.ia1.png": [16,8,16,{"cn":[947456,117056]}], +"textures/segment2/segment2_cn.1C950.ia1.png": [16,8,16,{"cn":[947456,117072]}], +"textures/segment2/segment2_cn.1C960.ia1.png": [16,8,16,{"cn":[947456,117088]}], +"textures/segment2/segment2_cn.1C970.ia1.png": [16,8,16,{"cn":[947456,117104]}], +"textures/segment2/segment2_cn.1C980.ia1.png": [16,8,16,{"cn":[947456,117120]}], +"textures/segment2/segment2_cn.1C990.ia1.png": [16,8,16,{"cn":[947456,117136]}], +"textures/segment2/segment2_cn.1C9A0.ia1.png": [16,8,16,{"cn":[947456,117152]}], +"textures/segment2/segment2_cn.1C9B0.ia1.png": [16,8,16,{"cn":[947456,117168]}], +"textures/segment2/segment2_cn.1C9C0.ia1.png": [16,8,16,{"cn":[947456,117184]}], +"textures/segment2/segment2_cn.1C9D0.ia1.png": [16,8,16,{"cn":[947456,117200]}], +"textures/segment2/segment2_cn.1C9E0.ia1.png": [16,8,16,{"cn":[947456,117216]}], +"textures/segment2/segment2_cn.1C9F0.ia1.png": [16,8,16,{"cn":[947456,117232]}], +"textures/segment2/segment2_cn.1CA00.ia1.png": [16,8,16,{"cn":[947456,117248]}], +"textures/segment2/segment2_cn.1CA10.ia1.png": [16,8,16,{"cn":[947456,117264]}], +"textures/segment2/segment2_cn.1CA20.ia1.png": [16,8,16,{"cn":[947456,117280]}], +"textures/segment2/segment2_cn.1CA30.ia1.png": [16,8,16,{"cn":[947456,117296]}], +"textures/segment2/segment2_cn.1CA40.ia1.png": [16,8,16,{"cn":[947456,117312]}], +"textures/segment2/segment2_cn.1CA50.ia1.png": [16,8,16,{"cn":[947456,117328]}], +"textures/segment2/segment2_cn.1CA60.ia1.png": [16,8,16,{"cn":[947456,117344]}], +"textures/segment2/segment2_cn.1CA70.ia1.png": [16,8,16,{"cn":[947456,117360]}], +"textures/segment2/segment2_cn.1CA80.ia1.png": [16,8,16,{"cn":[947456,117376]}], +"textures/segment2/segment2_cn.1CA90.ia1.png": [16,8,16,{"cn":[947456,117392]}], +"textures/segment2/segment2_cn.1CAA0.ia1.png": [16,8,16,{"cn":[947456,117408]}], +"textures/segment2/segment2_cn.1CAB0.ia1.png": [16,8,16,{"cn":[947456,117424]}], +"textures/segment2/segment2_cn.1CAC0.ia1.png": [16,8,16,{"cn":[947456,117440]}], +"textures/segment2/segment2_cn.1CAD0.ia1.png": [16,8,16,{"cn":[947456,117456]}], +"textures/segment2/segment2_cn.1CAE0.ia1.png": [16,8,16,{"cn":[947456,117472]}], +"textures/segment2/segment2_cn.1CAF0.ia1.png": [16,8,16,{"cn":[947456,117488]}], +"textures/segment2/segment2_cn.1CB00.ia1.png": [16,8,16,{"cn":[947456,117504]}], +"textures/segment2/segment2_cn.1CB10.ia1.png": [16,8,16,{"cn":[947456,117520]}], +"textures/segment2/segment2_cn.1CB20.ia1.png": [16,8,16,{"cn":[947456,117536]}], +"textures/segment2/segment2_cn.1CB30.ia1.png": [16,8,16,{"cn":[947456,117552]}], +"textures/segment2/segment2_cn.1CB40.ia1.png": [16,8,16,{"cn":[947456,117568]}], +"textures/segment2/segment2_cn.1CB50.ia1.png": [16,8,16,{"cn":[947456,117584]}], +"textures/segment2/segment2_cn.1CB60.ia1.png": [16,8,16,{"cn":[947456,117600]}], +"textures/segment2/segment2_cn.1CB70.ia1.png": [16,8,16,{"cn":[947456,117616]}], +"textures/segment2/segment2_cn.1CB80.ia1.png": [16,8,16,{"cn":[947456,117632]}], +"textures/segment2/segment2_cn.1CB90.ia1.png": [16,8,16,{"cn":[947456,117648]}], +"textures/segment2/segment2_cn.1CBA0.ia1.png": [16,8,16,{"cn":[947456,117664]}], +"textures/segment2/segment2_cn.1CBB0.ia1.png": [16,8,16,{"cn":[947456,117680]}], +"textures/segment2/segment2_cn.1CBC0.ia1.png": [16,8,16,{"cn":[947456,117696]}], +"textures/segment2/segment2_cn.1CBD0.ia1.png": [16,8,16,{"cn":[947456,117712]}], +"textures/segment2/segment2_cn.1CBE0.ia1.png": [16,8,16,{"cn":[947456,117728]}], +"textures/segment2/segment2_cn.1CBF0.ia1.png": [16,8,16,{"cn":[947456,117744]}], +"textures/segment2/segment2_cn.1CC00.ia1.png": [16,8,16,{"cn":[947456,117760]}], +"textures/segment2/segment2_cn.1CC10.ia1.png": [16,8,16,{"cn":[947456,117776]}], +"textures/segment2/segment2_cn.1CC20.ia1.png": [16,8,16,{"cn":[947456,117792]}], +"textures/segment2/segment2_cn.1CC30.ia1.png": [16,8,16,{"cn":[947456,117808]}], +"textures/segment2/segment2_cn.1CC40.ia1.png": [16,8,16,{"cn":[947456,117824]}], +"textures/segment2/segment2_cn.1CC50.ia1.png": [16,8,16,{"cn":[947456,117840]}], +"textures/segment2/segment2_cn.1CC60.ia1.png": [16,8,16,{"cn":[947456,117856]}], +"textures/segment2/segment2_cn.1CC70.ia1.png": [16,8,16,{"cn":[947456,117872]}], +"textures/segment2/segment2_cn.1CC80.ia1.png": [16,8,16,{"cn":[947456,117888]}], +"textures/segment2/segment2_cn.1CC90.ia1.png": [16,8,16,{"cn":[947456,117904]}], +"textures/segment2/segment2_cn.1CCA0.ia1.png": [16,8,16,{"cn":[947456,117920]}], +"textures/segment2/segment2_cn.1CCB0.ia1.png": [16,8,16,{"cn":[947456,117936]}], +"textures/segment2/segment2_cn.1CCC0.ia1.png": [16,8,16,{"cn":[947456,117952]}], +"textures/segment2/segment2_cn.1CCD0.ia1.png": [16,8,16,{"cn":[947456,117968]}], +"textures/segment2/segment2_cn.1CCE0.ia1.png": [16,8,16,{"cn":[947456,117984]}], +"textures/segment2/segment2_cn.1CCF0.ia1.png": [16,8,16,{"cn":[947456,118000]}], +"textures/segment2/segment2_cn.1CD00.ia1.png": [16,8,16,{"cn":[947456,118016]}], +"textures/segment2/segment2_cn.1CD10.ia1.png": [16,8,16,{"cn":[947456,118032]}], +"textures/segment2/segment2_cn.1CD20.ia1.png": [16,8,16,{"cn":[947456,118048]}], +"textures/segment2/segment2_cn.1CD30.ia1.png": [16,8,16,{"cn":[947456,118064]}], +"textures/segment2/segment2_cn.1CD40.ia1.png": [16,8,16,{"cn":[947456,118080]}], +"textures/segment2/segment2_cn.1CD50.ia1.png": [16,8,16,{"cn":[947456,118096]}], +"textures/segment2/segment2_cn.1CD60.ia1.png": [16,8,16,{"cn":[947456,118112]}], +"textures/segment2/segment2_cn.1CD70.ia1.png": [16,8,16,{"cn":[947456,118128]}], +"textures/segment2/segment2_cn.1CD80.ia1.png": [16,8,16,{"cn":[947456,118144]}], +"textures/segment2/segment2_cn.1CD90.ia1.png": [16,8,16,{"cn":[947456,118160]}], +"textures/segment2/segment2_cn.1CDA0.ia1.png": [16,8,16,{"cn":[947456,118176]}], +"textures/segment2/segment2_cn.1CDB0.ia1.png": [16,8,16,{"cn":[947456,118192]}], +"textures/segment2/segment2_cn.1CDC0.ia1.png": [16,8,16,{"cn":[947456,118208]}], +"textures/segment2/segment2_cn.1CDD0.ia1.png": [16,8,16,{"cn":[947456,118224]}], +"textures/segment2/segment2_cn.1CDE0.ia1.png": [16,8,16,{"cn":[947456,118240]}], +"textures/segment2/segment2_cn.1CDF0.ia1.png": [16,8,16,{"cn":[947456,118256]}], +"textures/segment2/segment2_cn.1CE00.ia1.png": [16,8,16,{"cn":[947456,118272]}], +"textures/segment2/segment2_cn.1CE10.ia1.png": [16,8,16,{"cn":[947456,118288]}], +"textures/segment2/segment2_cn.1CE20.ia1.png": [16,8,16,{"cn":[947456,118304]}], +"textures/segment2/segment2_cn.1CE30.ia1.png": [16,8,16,{"cn":[947456,118320]}], +"textures/segment2/segment2_cn.1CE40.ia1.png": [16,8,16,{"cn":[947456,118336]}], +"textures/segment2/segment2_cn.1CE50.ia1.png": [16,8,16,{"cn":[947456,118352]}], +"textures/segment2/segment2_cn.1CE60.ia1.png": [16,8,16,{"cn":[947456,118368]}], +"textures/segment2/segment2_cn.1CE70.ia1.png": [16,8,16,{"cn":[947456,118384]}], +"textures/segment2/segment2_cn.1CE80.ia1.png": [16,8,16,{"cn":[947456,118400]}], +"textures/segment2/segment2_cn.1CE90.ia1.png": [16,8,16,{"cn":[947456,118416]}], +"textures/segment2/segment2_cn.1CEA0.ia1.png": [16,8,16,{"cn":[947456,118432]}], +"textures/segment2/segment2_cn.1CEB0.ia1.png": [16,8,16,{"cn":[947456,118448]}], +"textures/segment2/segment2_cn.1CEC0.ia1.png": [16,8,16,{"cn":[947456,118464]}], +"textures/segment2/segment2_cn.1CED0.ia1.png": [16,8,16,{"cn":[947456,118480]}], +"textures/segment2/segment2_cn.1CEE0.ia1.png": [16,8,16,{"cn":[947456,118496]}], +"textures/segment2/segment2_cn.1CEF0.ia1.png": [16,8,16,{"cn":[947456,118512]}], +"textures/segment2/segment2_cn.1CF00.ia1.png": [16,8,16,{"cn":[947456,118528]}], +"textures/segment2/segment2_cn.1CF10.ia1.png": [16,8,16,{"cn":[947456,118544]}], +"textures/segment2/segment2_cn.1CF20.ia1.png": [16,8,16,{"cn":[947456,118560]}], +"textures/segment2/segment2_cn.1CF30.ia1.png": [16,8,16,{"cn":[947456,118576]}], +"textures/segment2/segment2_cn.1CF40.ia1.png": [16,8,16,{"cn":[947456,118592]}], +"textures/segment2/segment2_cn.1CF50.ia1.png": [16,8,16,{"cn":[947456,118608]}], +"textures/segment2/segment2_cn.1CF60.ia1.png": [16,8,16,{"cn":[947456,118624]}], +"textures/segment2/segment2_cn.1CF70.ia1.png": [16,8,16,{"cn":[947456,118640]}], +"textures/segment2/segment2_cn.1CF80.ia1.png": [16,8,16,{"cn":[947456,118656]}], +"textures/segment2/segment2_cn.1CF90.ia1.png": [16,8,16,{"cn":[947456,118672]}], +"textures/segment2/segment2_cn.1CFA0.ia1.png": [16,8,16,{"cn":[947456,118688]}], +"textures/segment2/segment2_cn.1CFB0.ia1.png": [16,8,16,{"cn":[947456,118704]}], +"textures/segment2/segment2_cn.1CFC0.ia1.png": [16,8,16,{"cn":[947456,118720]}], +"textures/segment2/segment2_cn.1CFD0.ia1.png": [16,8,16,{"cn":[947456,118736]}], +"textures/segment2/segment2_cn.1CFE0.ia1.png": [16,8,16,{"cn":[947456,118752]}], +"textures/segment2/segment2_cn.1CFF0.ia1.png": [16,8,16,{"cn":[947456,118768]}], +"textures/segment2/segment2_cn.1D000.ia1.png": [16,8,16,{"cn":[947456,118784]}], +"textures/segment2/segment2_cn.1D010.ia1.png": [16,8,16,{"cn":[947456,118800]}], +"textures/segment2/segment2_cn.1D020.ia1.png": [16,8,16,{"cn":[947456,118816]}], +"textures/segment2/segment2_cn.1D030.ia1.png": [16,8,16,{"cn":[947456,118832]}], +"textures/segment2/segment2_cn.1D040.ia1.png": [16,8,16,{"cn":[947456,118848]}], +"textures/segment2/segment2_cn.1D050.ia1.png": [16,8,16,{"cn":[947456,118864]}], +"textures/segment2/segment2_cn.1D060.ia1.png": [16,8,16,{"cn":[947456,118880]}], +"textures/segment2/segment2_cn.1D070.ia1.png": [16,8,16,{"cn":[947456,118896]}], +"textures/segment2/segment2_cn.1D080.ia1.png": [16,8,16,{"cn":[947456,118912]}], +"textures/segment2/segment2_cn.1D090.ia1.png": [16,8,16,{"cn":[947456,118928]}], +"textures/segment2/segment2_cn.1D0A0.ia1.png": [16,8,16,{"cn":[947456,118944]}], +"textures/segment2/segment2_cn.1D0B0.ia1.png": [16,8,16,{"cn":[947456,118960]}], +"textures/segment2/segment2_cn.1D0C0.ia1.png": [16,8,16,{"cn":[947456,118976]}], +"textures/segment2/segment2_cn.1D0D0.ia1.png": [16,8,16,{"cn":[947456,118992]}], +"textures/segment2/segment2_cn.1D0E0.ia1.png": [16,8,16,{"cn":[947456,119008]}], +"textures/segment2/segment2_cn.1D0F0.ia1.png": [16,8,16,{"cn":[947456,119024]}], +"textures/segment2/segment2_cn.1D100.ia1.png": [16,8,16,{"cn":[947456,119040]}], +"textures/segment2/segment2_cn.1D110.ia1.png": [16,8,16,{"cn":[947456,119056]}], +"textures/segment2/segment2_cn.1D120.ia1.png": [16,8,16,{"cn":[947456,119072]}], +"textures/segment2/segment2_cn.1D130.ia1.png": [16,8,16,{"cn":[947456,119088]}], +"textures/segment2/segment2_cn.1D140.ia1.png": [16,8,16,{"cn":[947456,119104]}], +"textures/segment2/segment2_cn.1D150.ia1.png": [16,8,16,{"cn":[947456,119120]}], +"textures/segment2/segment2_cn.1D160.ia1.png": [16,8,16,{"cn":[947456,119136]}], +"textures/segment2/segment2_cn.1D170.ia1.png": [16,8,16,{"cn":[947456,119152]}], +"textures/segment2/segment2_cn.1D180.ia1.png": [16,8,16,{"cn":[947456,119168]}], +"textures/segment2/segment2_cn.1D190.ia1.png": [16,8,16,{"cn":[947456,119184]}], +"textures/segment2/segment2_cn.1D1A0.ia1.png": [16,8,16,{"cn":[947456,119200]}], +"textures/segment2/segment2_cn.1D1B0.ia1.png": [16,8,16,{"cn":[947456,119216]}], +"textures/segment2/segment2_cn.1D1C0.ia1.png": [16,8,16,{"cn":[947456,119232]}], +"textures/segment2/segment2_cn.1D1D0.ia1.png": [16,8,16,{"cn":[947456,119248]}], +"textures/segment2/segment2_cn.1D1E0.ia1.png": [16,8,16,{"cn":[947456,119264]}], +"textures/segment2/segment2_cn.1D1F0.ia1.png": [16,8,16,{"cn":[947456,119280]}], +"textures/segment2/segment2_cn.1D200.ia1.png": [16,8,16,{"cn":[947456,119296]}], +"textures/segment2/segment2_cn.1D210.ia1.png": [16,8,16,{"cn":[947456,119312]}], +"textures/segment2/segment2_cn.1D220.ia1.png": [16,8,16,{"cn":[947456,119328]}], +"textures/segment2/segment2_cn.1D230.ia1.png": [16,8,16,{"cn":[947456,119344]}], +"textures/segment2/segment2_cn.1D240.ia1.png": [16,8,16,{"cn":[947456,119360]}], +"textures/segment2/segment2_cn.1D250.ia1.png": [16,8,16,{"cn":[947456,119376]}], +"textures/segment2/segment2_cn.1D260.ia1.png": [16,8,16,{"cn":[947456,119392]}], +"textures/segment2/segment2_cn.1D270.ia1.png": [16,8,16,{"cn":[947456,119408]}], +"textures/segment2/segment2_cn.1D280.ia1.png": [16,8,16,{"cn":[947456,119424]}], +"textures/segment2/segment2_cn.1D290.ia1.png": [16,8,16,{"cn":[947456,119440]}], +"textures/segment2/segment2_cn.1D2A0.ia1.png": [16,8,16,{"cn":[947456,119456]}], +"textures/segment2/segment2_cn.1D2B0.ia1.png": [16,8,16,{"cn":[947456,119472]}], +"textures/segment2/segment2_cn.1D2C0.ia1.png": [16,8,16,{"cn":[947456,119488]}], +"textures/segment2/segment2_cn.1D2D0.ia1.png": [16,8,16,{"cn":[947456,119504]}], +"textures/segment2/segment2_cn.1D2E0.ia1.png": [16,8,16,{"cn":[947456,119520]}], +"textures/segment2/segment2_cn.1D2F0.ia1.png": [16,8,16,{"cn":[947456,119536]}], +"textures/segment2/segment2_cn.1D300.ia1.png": [16,8,16,{"cn":[947456,119552]}], +"textures/segment2/segment2_cn.1D310.ia1.png": [16,8,16,{"cn":[947456,119568]}], +"textures/segment2/segment2_cn.1D320.ia1.png": [16,8,16,{"cn":[947456,119584]}], +"textures/segment2/segment2_cn.1D330.ia1.png": [16,8,16,{"cn":[947456,119600]}], +"textures/segment2/segment2_cn.1D340.ia1.png": [16,8,16,{"cn":[947456,119616]}], +"textures/segment2/segment2_cn.1D350.ia1.png": [16,8,16,{"cn":[947456,119632]}], +"textures/segment2/segment2_cn.1D360.ia1.png": [16,8,16,{"cn":[947456,119648]}], +"textures/segment2/segment2_cn.1D370.ia1.png": [16,8,16,{"cn":[947456,119664]}], +"textures/segment2/segment2_cn.1D380.ia1.png": [16,8,16,{"cn":[947456,119680]}], +"textures/segment2/segment2_cn.1D390.ia1.png": [16,8,16,{"cn":[947456,119696]}], +"textures/segment2/segment2_cn.1D3A0.ia1.png": [16,8,16,{"cn":[947456,119712]}], +"textures/segment2/segment2_cn.1D3B0.ia1.png": [16,8,16,{"cn":[947456,119728]}], +"textures/segment2/segment2_cn.1D3C0.ia1.png": [16,8,16,{"cn":[947456,119744]}], +"textures/segment2/segment2_cn.1D3D0.ia1.png": [16,8,16,{"cn":[947456,119760]}], +"textures/segment2/segment2_cn.1D3E0.ia1.png": [16,8,16,{"cn":[947456,119776]}], +"textures/segment2/segment2_cn.1D3F0.ia1.png": [16,8,16,{"cn":[947456,119792]}], +"textures/segment2/segment2_cn.1D400.ia1.png": [16,8,16,{"cn":[947456,119808]}], +"textures/segment2/segment2_cn.1D410.ia1.png": [16,8,16,{"cn":[947456,119824]}], +"textures/segment2/segment2_cn.1D420.ia1.png": [16,8,16,{"cn":[947456,119840]}], +"textures/segment2/segment2_cn.1D430.ia1.png": [16,8,16,{"cn":[947456,119856]}], +"textures/segment2/segment2_cn.1D440.ia1.png": [16,8,16,{"cn":[947456,119872]}], +"textures/segment2/segment2_cn.1D450.ia1.png": [16,8,16,{"cn":[947456,119888]}], +"textures/segment2/segment2_cn.1D460.ia1.png": [16,8,16,{"cn":[947456,119904]}], +"textures/segment2/segment2_cn.1D470.ia1.png": [16,8,16,{"cn":[947456,119920]}], +"textures/segment2/segment2_cn.1D480.ia1.png": [16,8,16,{"cn":[947456,119936]}], +"textures/segment2/segment2_cn.1D490.ia1.png": [16,8,16,{"cn":[947456,119952]}], +"textures/segment2/segment2_cn.1D4A0.ia1.png": [16,8,16,{"cn":[947456,119968]}], +"textures/segment2/segment2_cn.1D4B0.ia1.png": [16,8,16,{"cn":[947456,119984]}], +"textures/segment2/segment2_cn.1D4C0.ia1.png": [16,8,16,{"cn":[947456,120000]}], +"textures/segment2/segment2_cn.1D4D0.ia1.png": [16,8,16,{"cn":[947456,120016]}], +"textures/segment2/segment2_cn.1D4E0.ia1.png": [16,8,16,{"cn":[947456,120032]}], +"textures/segment2/segment2_cn.1D4F0.ia1.png": [16,8,16,{"cn":[947456,120048]}], +"textures/segment2/segment2_cn.1D500.ia1.png": [16,8,16,{"cn":[947456,120064]}], +"textures/segment2/segment2_cn.1D510.ia1.png": [16,8,16,{"cn":[947456,120080]}], +"textures/segment2/segment2_cn.1D520.ia1.png": [16,8,16,{"cn":[947456,120096]}], +"textures/segment2/segment2_cn.1D530.ia1.png": [16,8,16,{"cn":[947456,120112]}], +"textures/segment2/segment2_cn.1D540.ia1.png": [16,8,16,{"cn":[947456,120128]}], +"textures/segment2/segment2_cn.1D550.ia1.png": [16,8,16,{"cn":[947456,120144]}], +"textures/segment2/segment2_cn.1D560.ia1.png": [16,8,16,{"cn":[947456,120160]}], +"textures/segment2/segment2_cn.1D570.ia1.png": [16,8,16,{"cn":[947456,120176]}], +"textures/segment2/segment2_cn.1D580.ia1.png": [16,8,16,{"cn":[947456,120192]}], +"textures/segment2/segment2_cn.1D590.ia1.png": [16,8,16,{"cn":[947456,120208]}], +"textures/segment2/segment2_cn.1D5A0.ia1.png": [16,8,16,{"cn":[947456,120224]}], +"textures/segment2/segment2_cn.1D5B0.ia1.png": [16,8,16,{"cn":[947456,120240]}], +"textures/segment2/segment2_cn.1D5C0.ia1.png": [16,8,16,{"cn":[947456,120256]}], +"textures/segment2/segment2_cn.1D5D0.ia1.png": [16,8,16,{"cn":[947456,120272]}], +"textures/segment2/segment2_cn.1D5E0.ia1.png": [16,8,16,{"cn":[947456,120288]}], +"textures/segment2/segment2_cn.1D5F0.ia1.png": [16,8,16,{"cn":[947456,120304]}], +"textures/segment2/segment2_cn.1D600.ia1.png": [16,8,16,{"cn":[947456,120320]}], +"textures/segment2/segment2_cn.1D610.ia1.png": [16,8,16,{"cn":[947456,120336]}], +"textures/segment2/segment2_cn.1D620.ia1.png": [16,8,16,{"cn":[947456,120352]}], +"textures/segment2/segment2_cn.1D630.ia1.png": [16,8,16,{"cn":[947456,120368]}], +"textures/segment2/segment2_cn.1D640.ia1.png": [16,8,16,{"cn":[947456,120384]}], +"textures/segment2/segment2_cn.1D650.ia1.png": [16,8,16,{"cn":[947456,120400]}], +"textures/segment2/segment2_cn.1D660.ia1.png": [16,8,16,{"cn":[947456,120416]}], +"textures/segment2/segment2_cn.1D670.ia1.png": [16,8,16,{"cn":[947456,120432]}], +"textures/segment2/segment2_cn.1D680.ia1.png": [16,8,16,{"cn":[947456,120448]}], +"textures/segment2/segment2_cn.1D690.ia1.png": [16,8,16,{"cn":[947456,120464]}], +"textures/segment2/segment2_cn.1D6A0.ia1.png": [16,8,16,{"cn":[947456,120480]}], +"textures/segment2/segment2_cn.1D6B0.ia1.png": [16,8,16,{"cn":[947456,120496]}], +"textures/segment2/segment2_cn.1D6C0.ia1.png": [16,8,16,{"cn":[947456,120512]}], +"textures/segment2/segment2_cn.1D6D0.ia1.png": [16,8,16,{"cn":[947456,120528]}], +"textures/segment2/segment2_cn.1D6E0.ia1.png": [16,8,16,{"cn":[947456,120544]}], +"textures/segment2/segment2_cn.1D6F0.ia1.png": [16,8,16,{"cn":[947456,120560]}], +"textures/segment2/segment2_cn.1D700.ia1.png": [16,8,16,{"cn":[947456,120576]}], +"textures/segment2/segment2_cn.1D710.ia1.png": [16,8,16,{"cn":[947456,120592]}], +"textures/segment2/segment2_cn.1D720.ia1.png": [16,8,16,{"cn":[947456,120608]}], +"textures/segment2/segment2_cn.1D730.ia1.png": [16,8,16,{"cn":[947456,120624]}], +"textures/segment2/segment2_cn.1D740.ia1.png": [16,8,16,{"cn":[947456,120640]}], +"textures/segment2/segment2_cn.1D750.ia1.png": [16,8,16,{"cn":[947456,120656]}], +"textures/segment2/segment2_cn.1D760.ia1.png": [16,8,16,{"cn":[947456,120672]}], +"textures/segment2/segment2_cn.1D770.ia1.png": [16,8,16,{"cn":[947456,120688]}], +"textures/segment2/segment2_cn.1D780.ia1.png": [16,8,16,{"cn":[947456,120704]}], +"textures/segment2/segment2_cn.1D790.ia1.png": [16,8,16,{"cn":[947456,120720]}], +"textures/segment2/segment2_cn.1D7A0.ia1.png": [16,8,16,{"cn":[947456,120736]}], +"textures/segment2/segment2_cn.1D7B0.ia1.png": [16,8,16,{"cn":[947456,120752]}], +"textures/segment2/segment2_cn.1D7C0.ia1.png": [16,8,16,{"cn":[947456,120768]}], +"textures/segment2/segment2_cn.1D7D0.ia1.png": [16,8,16,{"cn":[947456,120784]}], +"textures/segment2/segment2_cn.1D7E0.ia1.png": [16,8,16,{"cn":[947456,120800]}], +"textures/segment2/segment2_cn.1D7F0.ia1.png": [16,8,16,{"cn":[947456,120816]}], +"textures/segment2/segment2_cn.1D800.ia1.png": [16,8,16,{"cn":[947456,120832]}], +"textures/segment2/segment2_cn.1D810.ia1.png": [16,8,16,{"cn":[947456,120848]}], +"textures/segment2/segment2_cn.1D820.ia1.png": [16,8,16,{"cn":[947456,120864]}], +"textures/segment2/segment2_cn.1D830.ia1.png": [16,8,16,{"cn":[947456,120880]}], +"textures/segment2/segment2_cn.1D840.ia1.png": [16,8,16,{"cn":[947456,120896]}], +"textures/segment2/segment2_cn.1D850.ia1.png": [16,8,16,{"cn":[947456,120912]}], +"textures/segment2/segment2_cn.1D860.ia1.png": [16,8,16,{"cn":[947456,120928]}], +"textures/segment2/segment2_cn.1D870.ia1.png": [16,8,16,{"cn":[947456,120944]}], +"textures/segment2/segment2_cn.1D880.ia1.png": [16,8,16,{"cn":[947456,120960]}], +"textures/segment2/segment2_cn.1D890.ia1.png": [16,8,16,{"cn":[947456,120976]}], +"textures/segment2/segment2_cn.1D8A0.ia1.png": [16,8,16,{"cn":[947456,120992]}], +"textures/segment2/segment2_cn.1D8B0.ia1.png": [16,8,16,{"cn":[947456,121008]}], +"textures/segment2/segment2_cn.1D8C0.ia1.png": [16,8,16,{"cn":[947456,121024]}], +"textures/segment2/segment2_cn.1D8D0.ia1.png": [16,8,16,{"cn":[947456,121040]}], +"textures/segment2/segment2_cn.1D8E0.ia1.png": [16,8,16,{"cn":[947456,121056]}], +"textures/segment2/segment2_cn.1D8F0.ia1.png": [16,8,16,{"cn":[947456,121072]}], +"textures/segment2/segment2_cn.1D900.ia1.png": [16,8,16,{"cn":[947456,121088]}], +"textures/segment2/segment2_cn.1D910.ia1.png": [16,8,16,{"cn":[947456,121104]}], +"textures/segment2/segment2_cn.1D920.ia1.png": [16,8,16,{"cn":[947456,121120]}], +"textures/segment2/segment2_cn.1D930.ia1.png": [16,8,16,{"cn":[947456,121136]}], +"textures/segment2/segment2_cn.1D940.ia1.png": [16,8,16,{"cn":[947456,121152]}], +"textures/segment2/segment2_cn.1D950.ia1.png": [16,8,16,{"cn":[947456,121168]}], +"textures/segment2/segment2_cn.1D960.ia1.png": [16,8,16,{"cn":[947456,121184]}], +"textures/segment2/segment2_cn.1D970.ia1.png": [16,8,16,{"cn":[947456,121200]}], +"textures/segment2/segment2_cn.1D980.ia1.png": [16,8,16,{"cn":[947456,121216]}], +"textures/segment2/segment2_cn.1D990.ia1.png": [16,8,16,{"cn":[947456,121232]}], +"textures/segment2/segment2_cn.1D9A0.ia1.png": [16,8,16,{"cn":[947456,121248]}], +"textures/segment2/segment2_cn.1D9B0.ia1.png": [16,8,16,{"cn":[947456,121264]}], +"textures/segment2/segment2_cn.1D9C0.ia1.png": [16,8,16,{"cn":[947456,121280]}], +"textures/segment2/segment2_cn.1D9D0.ia1.png": [16,8,16,{"cn":[947456,121296]}], +"textures/segment2/segment2_cn.1D9E0.ia1.png": [16,8,16,{"cn":[947456,121312]}], +"textures/segment2/segment2_cn.1D9F0.ia1.png": [16,8,16,{"cn":[947456,121328]}], +"textures/segment2/segment2_cn.1DA00.ia1.png": [16,8,16,{"cn":[947456,121344]}], +"textures/segment2/segment2_cn.1DA10.ia1.png": [16,8,16,{"cn":[947456,121360]}], +"textures/segment2/segment2_cn.1DA20.ia1.png": [16,8,16,{"cn":[947456,121376]}], +"textures/segment2/segment2_cn.1DA30.ia1.png": [16,8,16,{"cn":[947456,121392]}], +"textures/segment2/segment2_cn.1DA40.ia1.png": [16,8,16,{"cn":[947456,121408]}], +"textures/segment2/segment2_cn.1DA50.ia1.png": [16,8,16,{"cn":[947456,121424]}], +"textures/segment2/segment2_cn.1DA60.ia1.png": [16,8,16,{"cn":[947456,121440]}], +"textures/segment2/segment2_cn.1DA70.ia1.png": [16,8,16,{"cn":[947456,121456]}], +"textures/segment2/segment2_cn.1DA80.ia1.png": [16,8,16,{"cn":[947456,121472]}], +"textures/segment2/segment2_cn.1DA90.ia1.png": [16,8,16,{"cn":[947456,121488]}], +"textures/segment2/segment2_cn.1DAA0.ia1.png": [16,8,16,{"cn":[947456,121504]}], +"textures/segment2/segment2_cn.1DAB0.ia1.png": [16,8,16,{"cn":[947456,121520]}], +"textures/segment2/segment2_cn.1DAC0.ia1.png": [16,8,16,{"cn":[947456,121536]}], +"textures/segment2/segment2_cn.1DAD0.ia1.png": [16,8,16,{"cn":[947456,121552]}], +"textures/segment2/segment2_cn.1DAE0.ia1.png": [16,8,16,{"cn":[947456,121568]}], +"textures/segment2/segment2_cn.1DAF0.ia1.png": [16,8,16,{"cn":[947456,121584]}], +"textures/segment2/segment2_cn.1DB00.ia1.png": [16,8,16,{"cn":[947456,121600]}], +"textures/segment2/segment2_cn.1DB10.ia1.png": [16,8,16,{"cn":[947456,121616]}], +"textures/segment2/segment2_cn.1DB20.ia1.png": [16,8,16,{"cn":[947456,121632]}], +"textures/segment2/segment2_cn.1DB30.ia1.png": [16,8,16,{"cn":[947456,121648]}], +"textures/segment2/segment2_cn.1DB40.ia1.png": [16,8,16,{"cn":[947456,121664]}], +"textures/segment2/segment2_cn.1DB50.ia1.png": [16,8,16,{"cn":[947456,121680]}], +"textures/segment2/segment2_cn.1DB60.ia1.png": [16,8,16,{"cn":[947456,121696]}], +"textures/segment2/segment2_cn.1DB70.ia1.png": [16,8,16,{"cn":[947456,121712]}], +"textures/segment2/segment2_cn.1DB80.ia1.png": [16,8,16,{"cn":[947456,121728]}], +"textures/segment2/segment2_cn.1DB90.ia1.png": [16,8,16,{"cn":[947456,121744]}], +"textures/segment2/segment2_cn.1DBA0.ia1.png": [16,8,16,{"cn":[947456,121760]}], +"textures/segment2/segment2_cn.1DBB0.ia1.png": [16,8,16,{"cn":[947456,121776]}], +"textures/segment2/segment2_cn.1DBC0.ia1.png": [16,8,16,{"cn":[947456,121792]}], +"textures/segment2/segment2_cn.1DBD0.ia1.png": [16,8,16,{"cn":[947456,121808]}], +"textures/segment2/segment2_cn.1DBE0.ia1.png": [16,8,16,{"cn":[947456,121824]}], +"textures/segment2/segment2_cn.1DBF0.ia1.png": [16,8,16,{"cn":[947456,121840]}], +"textures/segment2/segment2_cn.1DC00.ia1.png": [16,8,16,{"cn":[947456,121856]}], +"textures/segment2/segment2_cn.1DC10.ia1.png": [16,8,16,{"cn":[947456,121872]}], +"textures/segment2/segment2_cn.1DC20.ia1.png": [16,8,16,{"cn":[947456,121888]}], +"textures/segment2/segment2_cn.1DC30.ia1.png": [16,8,16,{"cn":[947456,121904]}], +"textures/segment2/segment2_cn.1DC40.ia1.png": [16,8,16,{"cn":[947456,121920]}], +"textures/segment2/segment2_cn.1DC50.ia1.png": [16,8,16,{"cn":[947456,121936]}], +"textures/segment2/segment2_cn.1DC60.ia1.png": [16,8,16,{"cn":[947456,121952]}], +"textures/segment2/segment2_cn.1DC70.ia1.png": [16,8,16,{"cn":[947456,121968]}], +"textures/segment2/segment2_cn.1DC80.ia1.png": [16,8,16,{"cn":[947456,121984]}], +"textures/segment2/segment2_cn.1DC90.ia1.png": [16,8,16,{"cn":[947456,122000]}], +"textures/segment2/segment2_cn.1DCA0.ia1.png": [16,8,16,{"cn":[947456,122016]}], +"textures/segment2/segment2_cn.1DCB0.ia1.png": [16,8,16,{"cn":[947456,122032]}], +"textures/segment2/segment2_cn.1DCC0.ia1.png": [16,8,16,{"cn":[947456,122048]}], +"textures/segment2/segment2_cn.1DCD0.ia1.png": [16,8,16,{"cn":[947456,122064]}], +"textures/segment2/segment2_cn.1DCE0.ia1.png": [16,8,16,{"cn":[947456,122080]}], +"textures/segment2/segment2_cn.1DCF0.ia1.png": [16,8,16,{"cn":[947456,122096]}], +"textures/segment2/segment2_cn.1DD00.ia1.png": [16,8,16,{"cn":[947456,122112]}], +"textures/segment2/segment2_cn.1DD10.ia1.png": [16,8,16,{"cn":[947456,122128]}], +"textures/segment2/segment2_cn.1DD20.ia1.png": [16,8,16,{"cn":[947456,122144]}], +"textures/segment2/segment2_cn.1DD30.ia1.png": [16,8,16,{"cn":[947456,122160]}], +"textures/segment2/segment2_cn.1DD40.ia1.png": [16,8,16,{"cn":[947456,122176]}], +"textures/segment2/segment2_cn.1DD50.ia1.png": [16,8,16,{"cn":[947456,122192]}], +"textures/segment2/segment2_cn.1DD60.ia1.png": [16,8,16,{"cn":[947456,122208]}], +"textures/segment2/segment2_cn.1DD70.ia1.png": [16,8,16,{"cn":[947456,122224]}], +"textures/segment2/segment2_cn.1DD80.ia1.png": [16,8,16,{"cn":[947456,122240]}], +"textures/segment2/segment2_cn.1DD90.ia1.png": [16,8,16,{"cn":[947456,122256]}], +"textures/segment2/segment2_cn.1DDA0.ia1.png": [16,8,16,{"cn":[947456,122272]}], +"textures/segment2/segment2_cn.1DDB0.ia1.png": [16,8,16,{"cn":[947456,122288]}], +"textures/segment2/segment2_cn.1DDC0.ia1.png": [16,8,16,{"cn":[947456,122304]}], +"textures/segment2/segment2_cn.1DDD0.ia1.png": [16,8,16,{"cn":[947456,122320]}], +"textures/segment2/segment2_cn.1DDE0.ia1.png": [16,8,16,{"cn":[947456,122336]}], +"textures/segment2/segment2_cn.1DDF0.ia1.png": [16,8,16,{"cn":[947456,122352]}], +"textures/segment2/segment2_cn.1DE00.ia1.png": [16,8,16,{"cn":[947456,122368]}], +"textures/segment2/segment2_cn.1DE10.ia1.png": [16,8,16,{"cn":[947456,122384]}], +"textures/segment2/segment2_cn.1DE20.ia1.png": [16,8,16,{"cn":[947456,122400]}], +"textures/segment2/segment2_cn.1DE30.ia1.png": [16,8,16,{"cn":[947456,122416]}], +"textures/segment2/segment2_cn.1DE40.ia1.png": [16,8,16,{"cn":[947456,122432]}], +"textures/segment2/segment2_cn.1DE50.ia1.png": [16,8,16,{"cn":[947456,122448]}], +"textures/segment2/segment2_cn.1DE60.ia1.png": [16,8,16,{"cn":[947456,122464]}], +"textures/segment2/segment2_cn.1DE70.ia1.png": [16,8,16,{"cn":[947456,122480]}], +"textures/segment2/segment2_cn.1DE80.ia1.png": [16,8,16,{"cn":[947456,122496]}], +"textures/segment2/segment2_cn.1DE90.ia1.png": [16,8,16,{"cn":[947456,122512]}], +"textures/segment2/segment2_cn.1DEA0.ia1.png": [16,8,16,{"cn":[947456,122528]}], +"textures/segment2/segment2_cn.1DEB0.ia1.png": [16,8,16,{"cn":[947456,122544]}], +"textures/segment2/segment2_cn.1DEC0.ia1.png": [16,8,16,{"cn":[947456,122560]}], +"textures/segment2/segment2_cn.1DED0.ia1.png": [16,8,16,{"cn":[947456,122576]}], +"textures/segment2/segment2_cn.1DEE0.ia1.png": [16,8,16,{"cn":[947456,122592]}], +"textures/segment2/segment2_cn.1DEF0.ia1.png": [16,8,16,{"cn":[947456,122608]}], +"textures/segment2/segment2_cn.1DF00.ia1.png": [16,8,16,{"cn":[947456,122624]}], +"textures/segment2/segment2_cn.1DF10.ia1.png": [16,8,16,{"cn":[947456,122640]}], +"textures/segment2/segment2_cn.1DF20.ia1.png": [16,8,16,{"cn":[947456,122656]}], +"textures/segment2/segment2_cn.1DF30.ia1.png": [16,8,16,{"cn":[947456,122672]}], +"textures/segment2/segment2_cn.1DF40.ia1.png": [16,8,16,{"cn":[947456,122688]}], +"textures/segment2/segment2_cn.1DF50.ia1.png": [16,8,16,{"cn":[947456,122704]}], +"textures/segment2/segment2_cn.1DF60.ia1.png": [16,8,16,{"cn":[947456,122720]}], +"textures/segment2/segment2_cn.1DF70.ia1.png": [16,8,16,{"cn":[947456,122736]}], +"textures/segment2/segment2_cn.1DF80.ia1.png": [16,8,16,{"cn":[947456,122752]}], +"textures/segment2/segment2_cn.1DF90.ia1.png": [16,8,16,{"cn":[947456,122768]}], +"textures/segment2/segment2_cn.1DFA0.ia1.png": [16,8,16,{"cn":[947456,122784]}], +"textures/segment2/segment2_cn.1DFB0.ia1.png": [16,8,16,{"cn":[947456,122800]}], +"textures/segment2/segment2_cn.1DFC0.ia1.png": [16,8,16,{"cn":[947456,122816]}], +"textures/segment2/segment2_cn.1DFD0.ia1.png": [16,8,16,{"cn":[947456,122832]}], +"textures/segment2/segment2_cn.1DFE0.ia1.png": [16,8,16,{"cn":[947456,122848]}], +"textures/segment2/segment2_cn.1DFF0.ia1.png": [16,8,16,{"cn":[947456,122864]}], +"textures/segment2/segment2_cn.1E000.ia1.png": [16,8,16,{"cn":[947456,122880]}], +"textures/segment2/segment2_cn.1E010.ia1.png": [16,8,16,{"cn":[947456,122896]}], +"textures/segment2/segment2_cn.1E020.ia1.png": [16,8,16,{"cn":[947456,122912]}], +"textures/segment2/segment2_cn.1E030.ia1.png": [16,8,16,{"cn":[947456,122928]}], +"textures/segment2/segment2_cn.1E040.ia1.png": [16,8,16,{"cn":[947456,122944]}], +"textures/segment2/segment2_cn.1E050.ia1.png": [16,8,16,{"cn":[947456,122960]}], +"textures/segment2/segment2_cn.1E060.ia1.png": [16,8,16,{"cn":[947456,122976]}], +"textures/segment2/segment2_cn.1E070.ia1.png": [16,8,16,{"cn":[947456,122992]}], +"textures/segment2/segment2_cn.1E080.ia1.png": [16,8,16,{"cn":[947456,123008]}], +"textures/segment2/segment2_cn.1E090.ia1.png": [16,8,16,{"cn":[947456,123024]}], +"textures/segment2/segment2_cn.1E0A0.ia1.png": [16,8,16,{"cn":[947456,123040]}], +"textures/segment2/segment2_cn.1E0B0.ia1.png": [16,8,16,{"cn":[947456,123056]}], +"textures/segment2/segment2_cn.1E0C0.ia1.png": [16,8,16,{"cn":[947456,123072]}], +"textures/segment2/segment2_cn.1E0D0.ia1.png": [16,8,16,{"cn":[947456,123088]}], +"textures/segment2/segment2_cn.1E0E0.ia1.png": [16,8,16,{"cn":[947456,123104]}], +"textures/segment2/segment2_cn.1E0F0.ia1.png": [16,8,16,{"cn":[947456,123120]}], +"textures/segment2/segment2_cn.1E100.ia1.png": [16,8,16,{"cn":[947456,123136]}], +"textures/segment2/segment2_cn.1E110.ia1.png": [16,8,16,{"cn":[947456,123152]}], +"textures/segment2/segment2_cn.1E120.ia1.png": [16,8,16,{"cn":[947456,123168]}], +"textures/segment2/segment2_cn.1E130.ia1.png": [16,8,16,{"cn":[947456,123184]}], +"textures/segment2/segment2_cn.1E140.ia1.png": [16,8,16,{"cn":[947456,123200]}], +"textures/segment2/segment2_cn.1E150.ia1.png": [16,8,16,{"cn":[947456,123216]}], +"textures/segment2/segment2_cn.1E160.ia1.png": [16,8,16,{"cn":[947456,123232]}], +"textures/segment2/segment2_cn.1E170.ia1.png": [16,8,16,{"cn":[947456,123248]}], +"textures/segment2/segment2_cn.1E180.ia1.png": [16,8,16,{"cn":[947456,123264]}], +"textures/segment2/segment2_cn.1E190.ia1.png": [16,8,16,{"cn":[947456,123280]}], +"textures/segment2/segment2_cn.1E1A0.ia1.png": [16,8,16,{"cn":[947456,123296]}], +"textures/segment2/segment2_cn.1E1B0.ia1.png": [16,8,16,{"cn":[947456,123312]}], +"textures/segment2/segment2_cn.1E1C0.ia1.png": [16,8,16,{"cn":[947456,123328]}], +"textures/segment2/segment2_cn.1E1D0.ia1.png": [16,8,16,{"cn":[947456,123344]}], +"textures/segment2/segment2_cn.1E1E0.ia1.png": [16,8,16,{"cn":[947456,123360]}], +"textures/segment2/segment2_cn.1E1F0.ia1.png": [16,8,16,{"cn":[947456,123376]}], +"textures/segment2/segment2_cn.1E200.ia1.png": [16,8,16,{"cn":[947456,123392]}], +"textures/segment2/segment2_cn.1E210.ia1.png": [16,8,16,{"cn":[947456,123408]}], +"textures/segment2/segment2_cn.1E220.ia1.png": [16,8,16,{"cn":[947456,123424]}], +"textures/segment2/segment2_cn.1E230.ia1.png": [16,8,16,{"cn":[947456,123440]}], +"textures/segment2/segment2_cn.1E240.ia1.png": [16,8,16,{"cn":[947456,123456]}], +"textures/segment2/segment2_cn.1E250.ia1.png": [16,8,16,{"cn":[947456,123472]}], +"textures/segment2/segment2_cn.1E260.ia1.png": [16,8,16,{"cn":[947456,123488]}], +"textures/segment2/segment2_cn.1E270.ia1.png": [16,8,16,{"cn":[947456,123504]}], +"textures/segment2/segment2_cn.1E280.ia1.png": [16,8,16,{"cn":[947456,123520]}], +"textures/segment2/segment2_cn.1E290.ia1.png": [16,8,16,{"cn":[947456,123536]}], +"textures/segment2/segment2_cn.1E2A0.ia1.png": [16,8,16,{"cn":[947456,123552]}], +"textures/segment2/segment2_cn.1E2B0.ia1.png": [16,8,16,{"cn":[947456,123568]}], +"textures/segment2/segment2_cn.1E2C0.ia1.png": [16,8,16,{"cn":[947456,123584]}], +"textures/segment2/segment2_cn.1E2D0.ia1.png": [16,8,16,{"cn":[947456,123600]}], +"textures/segment2/segment2_cn.1E2E0.ia1.png": [16,8,16,{"cn":[947456,123616]}], +"textures/segment2/segment2_cn.1E2F0.ia1.png": [16,8,16,{"cn":[947456,123632]}], +"textures/segment2/segment2_cn.1E300.ia1.png": [16,8,16,{"cn":[947456,123648]}], +"textures/segment2/segment2_cn.1E310.ia1.png": [16,8,16,{"cn":[947456,123664]}], +"textures/segment2/segment2_cn.1E320.ia1.png": [16,8,16,{"cn":[947456,123680]}], +"textures/segment2/segment2_cn.1E330.ia1.png": [16,8,16,{"cn":[947456,123696]}], +"textures/segment2/segment2_cn.1E340.ia1.png": [16,8,16,{"cn":[947456,123712]}], +"textures/segment2/segment2_cn.1E350.ia1.png": [16,8,16,{"cn":[947456,123728]}], +"textures/segment2/segment2_cn.1E360.ia1.png": [16,8,16,{"cn":[947456,123744]}], +"textures/segment2/segment2_cn.1E370.ia1.png": [16,8,16,{"cn":[947456,123760]}], +"textures/segment2/segment2_cn.1E380.ia1.png": [16,8,16,{"cn":[947456,123776]}], +"textures/segment2/segment2_cn.1E390.ia1.png": [16,8,16,{"cn":[947456,123792]}], +"textures/segment2/segment2_cn.1E3A0.ia1.png": [16,8,16,{"cn":[947456,123808]}], +"textures/segment2/segment2_cn.1E3B0.ia1.png": [16,8,16,{"cn":[947456,123824]}], +"textures/segment2/segment2_cn.1E3C0.ia1.png": [16,8,16,{"cn":[947456,123840]}], +"textures/segment2/segment2_cn.1E3D0.ia1.png": [16,8,16,{"cn":[947456,123856]}], +"textures/segment2/segment2_cn.1E3E0.ia1.png": [16,8,16,{"cn":[947456,123872]}], +"textures/segment2/segment2_cn.1E3F0.ia1.png": [16,8,16,{"cn":[947456,123888]}], +"textures/segment2/segment2_cn.1E400.ia1.png": [16,8,16,{"cn":[947456,123904]}], +"textures/segment2/segment2_cn.1E410.ia1.png": [16,8,16,{"cn":[947456,123920]}], +"textures/segment2/segment2_cn.1E420.ia1.png": [16,8,16,{"cn":[947456,123936]}], +"textures/segment2/segment2_cn.1E430.ia1.png": [16,8,16,{"cn":[947456,123952]}], +"textures/segment2/segment2_cn.1E440.ia1.png": [16,8,16,{"cn":[947456,123968]}], +"textures/segment2/segment2_cn.1E450.ia1.png": [16,8,16,{"cn":[947456,123984]}], +"textures/segment2/segment2_cn.1E460.ia1.png": [16,8,16,{"cn":[947456,124000]}], +"textures/segment2/segment2_cn.1E470.ia1.png": [16,8,16,{"cn":[947456,124016]}], +"textures/segment2/segment2_cn.1E480.ia1.png": [16,8,16,{"cn":[947456,124032]}], +"textures/segment2/segment2_cn.1E490.ia1.png": [16,8,16,{"cn":[947456,124048]}], +"textures/segment2/segment2_cn.1E4A0.ia1.png": [16,8,16,{"cn":[947456,124064]}], +"textures/segment2/segment2_cn.1E4B0.ia1.png": [16,8,16,{"cn":[947456,124080]}], +"textures/segment2/segment2_cn.1E4C0.ia1.png": [16,8,16,{"cn":[947456,124096]}], +"textures/segment2/segment2_cn.1E4D0.ia1.png": [16,8,16,{"cn":[947456,124112]}], +"textures/segment2/segment2_cn.1E4E0.ia1.png": [16,8,16,{"cn":[947456,124128]}], +"textures/segment2/segment2_cn.1E4F0.ia1.png": [16,8,16,{"cn":[947456,124144]}], +"textures/segment2/segment2_cn.1E500.ia1.png": [16,8,16,{"cn":[947456,124160]}], +"textures/segment2/segment2_cn.1E510.ia1.png": [16,8,16,{"cn":[947456,124176]}], +"textures/segment2/segment2_cn.1E520.ia1.png": [16,8,16,{"cn":[947456,124192]}], +"textures/segment2/segment2_cn.1E530.ia1.png": [16,8,16,{"cn":[947456,124208]}], +"textures/segment2/segment2_cn.1E540.ia1.png": [16,8,16,{"cn":[947456,124224]}], +"textures/segment2/segment2_cn.1E550.ia1.png": [16,8,16,{"cn":[947456,124240]}], +"textures/segment2/segment2_cn.1E560.ia1.png": [16,8,16,{"cn":[947456,124256]}], +"textures/segment2/segment2_cn.1E570.ia1.png": [16,8,16,{"cn":[947456,124272]}], +"textures/segment2/segment2_cn.1E580.ia1.png": [16,8,16,{"cn":[947456,124288]}], +"textures/segment2/segment2_cn.1E590.ia1.png": [16,8,16,{"cn":[947456,124304]}], +"textures/segment2/segment2_cn.1E5A0.ia1.png": [16,8,16,{"cn":[947456,124320]}], +"textures/segment2/segment2_cn.1E5B0.ia1.png": [16,8,16,{"cn":[947456,124336]}], +"textures/segment2/segment2_cn.1E5C0.ia1.png": [16,8,16,{"cn":[947456,124352]}], +"textures/segment2/segment2_cn.1E5D0.ia1.png": [16,8,16,{"cn":[947456,124368]}], +"textures/segment2/segment2_cn.1E5E0.ia1.png": [16,8,16,{"cn":[947456,124384]}], +"textures/segment2/segment2_cn.1E5F0.ia1.png": [16,8,16,{"cn":[947456,124400]}], +"textures/segment2/segment2_cn.1E600.ia1.png": [16,8,16,{"cn":[947456,124416]}], +"textures/segment2/segment2_cn.1E610.ia1.png": [16,8,16,{"cn":[947456,124432]}], +"textures/segment2/segment2_cn.1E620.ia1.png": [16,8,16,{"cn":[947456,124448]}], +"textures/segment2/segment2_cn.1E630.ia1.png": [16,8,16,{"cn":[947456,124464]}], +"textures/segment2/segment2_cn.1E640.ia1.png": [16,8,16,{"cn":[947456,124480]}], +"textures/segment2/segment2_cn.1E650.ia1.png": [16,8,16,{"cn":[947456,124496]}], +"textures/segment2/segment2_cn.1E660.ia1.png": [16,8,16,{"cn":[947456,124512]}], +"textures/segment2/segment2_cn.1E670.ia1.png": [16,8,16,{"cn":[947456,124528]}], +"textures/segment2/segment2_cn.1E680.ia1.png": [16,8,16,{"cn":[947456,124544]}], +"textures/segment2/segment2_cn.1E690.ia1.png": [16,8,16,{"cn":[947456,124560]}], +"textures/segment2/segment2_cn.1E6A0.ia1.png": [16,8,16,{"cn":[947456,124576]}], +"textures/segment2/segment2_cn.1E6B0.ia1.png": [16,8,16,{"cn":[947456,124592]}], +"textures/segment2/segment2_cn.1E6C0.ia1.png": [16,8,16,{"cn":[947456,124608]}], +"textures/segment2/segment2_cn.1E6D0.ia1.png": [16,8,16,{"cn":[947456,124624]}], +"textures/segment2/segment2_cn.1E6E0.ia1.png": [16,8,16,{"cn":[947456,124640]}], +"textures/segment2/segment2_cn.1E6F0.ia1.png": [16,8,16,{"cn":[947456,124656]}], +"textures/segment2/segment2_cn.1E700.ia1.png": [16,8,16,{"cn":[947456,124672]}], +"textures/segment2/segment2_cn.1E710.ia1.png": [16,8,16,{"cn":[947456,124688]}], +"textures/segment2/segment2_cn.1E720.ia1.png": [16,8,16,{"cn":[947456,124704]}], +"textures/segment2/segment2_cn.1E730.ia1.png": [16,8,16,{"cn":[947456,124720]}], +"textures/segment2/segment2_cn.1E740.ia1.png": [16,8,16,{"cn":[947456,124736]}], +"textures/segment2/segment2_cn.1E750.ia1.png": [16,8,16,{"cn":[947456,124752]}], +"textures/segment2/segment2_cn.1E760.ia1.png": [16,8,16,{"cn":[947456,124768]}], +"textures/segment2/segment2_cn.1E770.ia1.png": [16,8,16,{"cn":[947456,124784]}], +"textures/segment2/segment2_cn.1E780.ia1.png": [16,8,16,{"cn":[947456,124800]}], +"textures/segment2/segment2_cn.1E790.ia1.png": [16,8,16,{"cn":[947456,124816]}], +"textures/segment2/segment2_cn.1E7A0.ia1.png": [16,8,16,{"cn":[947456,124832]}], +"textures/segment2/segment2_cn.1E7B0.ia1.png": [16,8,16,{"cn":[947456,124848]}], +"textures/segment2/segment2_cn.1E7C0.ia1.png": [16,8,16,{"cn":[947456,124864]}], +"textures/segment2/segment2_cn.1E7D0.ia1.png": [16,8,16,{"cn":[947456,124880]}], +"textures/segment2/segment2_cn.1E7E0.ia1.png": [16,8,16,{"cn":[947456,124896]}], +"textures/segment2/segment2_cn.1E7F0.ia1.png": [16,8,16,{"cn":[947456,124912]}], +"textures/segment2/segment2_cn.1E800.ia1.png": [16,8,16,{"cn":[947456,124928]}], +"textures/segment2/segment2_cn.1E810.ia1.png": [16,8,16,{"cn":[947456,124944]}], +"textures/segment2/segment2_cn.1E820.ia1.png": [16,8,16,{"cn":[947456,124960]}], +"textures/segment2/segment2_cn.1E830.ia1.png": [16,8,16,{"cn":[947456,124976]}], +"textures/segment2/segment2_cn.1E840.ia1.png": [16,8,16,{"cn":[947456,124992]}], +"textures/segment2/segment2_cn.1E850.ia1.png": [16,8,16,{"cn":[947456,125008]}], +"textures/segment2/segment2_cn.1E860.ia1.png": [16,8,16,{"cn":[947456,125024]}], +"textures/segment2/segment2_cn.1E870.ia1.png": [16,8,16,{"cn":[947456,125040]}], +"textures/segment2/segment2_cn.1E880.ia1.png": [16,8,16,{"cn":[947456,125056]}], +"textures/segment2/segment2_cn.1E890.ia1.png": [16,8,16,{"cn":[947456,125072]}], +"textures/segment2/segment2_cn.1E8A0.ia1.png": [16,8,16,{"cn":[947456,125088]}], +"textures/segment2/segment2_cn.1E8B0.ia1.png": [16,8,16,{"cn":[947456,125104]}], +"textures/segment2/segment2_cn.1E8C0.ia1.png": [16,8,16,{"cn":[947456,125120]}], +"textures/segment2/segment2_cn.1E8D0.ia1.png": [16,8,16,{"cn":[947456,125136]}], +"textures/segment2/segment2_cn.1E8E0.ia1.png": [16,8,16,{"cn":[947456,125152]}], +"textures/segment2/segment2_cn.1E8F0.ia1.png": [16,8,16,{"cn":[947456,125168]}], +"textures/segment2/segment2_cn.1E900.ia1.png": [16,8,16,{"cn":[947456,125184]}], +"textures/segment2/segment2_cn.1E910.ia1.png": [16,8,16,{"cn":[947456,125200]}], +"textures/segment2/segment2_cn.1E920.ia1.png": [16,8,16,{"cn":[947456,125216]}], +"textures/segment2/segment2_cn.1E930.ia1.png": [16,8,16,{"cn":[947456,125232]}], +"textures/segment2/segment2_cn.1E940.ia1.png": [16,8,16,{"cn":[947456,125248]}], +"textures/segment2/segment2_cn.1E950.ia1.png": [16,8,16,{"cn":[947456,125264]}], +"textures/segment2/segment2_cn.1E960.ia1.png": [16,8,16,{"cn":[947456,125280]}], +"textures/segment2/segment2_cn.1E970.ia1.png": [16,8,16,{"cn":[947456,125296]}], +"textures/segment2/segment2_cn.1E980.ia1.png": [16,8,16,{"cn":[947456,125312]}], +"textures/segment2/segment2_cn.1E990.ia1.png": [16,8,16,{"cn":[947456,125328]}], +"textures/segment2/segment2_cn.1E9A0.ia1.png": [16,8,16,{"cn":[947456,125344]}], +"textures/segment2/segment2_cn.1E9B0.ia1.png": [16,8,16,{"cn":[947456,125360]}], +"textures/segment2/segment2_cn.1E9C0.ia1.png": [16,8,16,{"cn":[947456,125376]}], +"textures/segment2/segment2_cn.1E9D0.ia1.png": [16,8,16,{"cn":[947456,125392]}], +"textures/segment2/segment2_cn.1E9E0.ia1.png": [16,8,16,{"cn":[947456,125408]}], +"textures/segment2/segment2_cn.1E9F0.ia1.png": [16,8,16,{"cn":[947456,125424]}], +"textures/segment2/segment2_cn.1EA00.ia1.png": [16,8,16,{"cn":[947456,125440]}], +"textures/segment2/segment2_cn.1EA10.ia1.png": [16,8,16,{"cn":[947456,125456]}], +"textures/segment2/segment2_cn.1EA20.ia1.png": [16,8,16,{"cn":[947456,125472]}], +"textures/segment2/segment2_cn.1EA30.ia1.png": [16,8,16,{"cn":[947456,125488]}], +"textures/segment2/segment2_cn.1EA40.ia1.png": [16,8,16,{"cn":[947456,125504]}], +"textures/segment2/segment2_cn.1EA50.ia1.png": [16,8,16,{"cn":[947456,125520]}], +"textures/segment2/segment2_cn.1EA60.ia1.png": [16,8,16,{"cn":[947456,125536]}], +"textures/segment2/segment2_cn.1EA70.ia1.png": [16,8,16,{"cn":[947456,125552]}], +"textures/segment2/segment2_cn.1EA80.ia1.png": [16,8,16,{"cn":[947456,125568]}], +"textures/segment2/segment2_cn.1EA90.ia1.png": [16,8,16,{"cn":[947456,125584]}], +"textures/segment2/segment2_cn.1EAA0.ia1.png": [16,8,16,{"cn":[947456,125600]}], +"textures/segment2/segment2_cn.1EAB0.ia1.png": [16,8,16,{"cn":[947456,125616]}], +"textures/segment2/segment2_cn.1EAC0.ia1.png": [16,8,16,{"cn":[947456,125632]}], +"textures/segment2/segment2_cn.1EAD0.ia1.png": [16,8,16,{"cn":[947456,125648]}], +"textures/segment2/segment2_cn.1EAE0.ia1.png": [16,8,16,{"cn":[947456,125664]}], +"textures/segment2/segment2_cn.1EAF0.ia1.png": [16,8,16,{"cn":[947456,125680]}], +"textures/segment2/segment2_cn.1EB00.ia1.png": [16,8,16,{"cn":[947456,125696]}], +"textures/segment2/segment2_cn.1EB10.ia1.png": [16,8,16,{"cn":[947456,125712]}], +"textures/segment2/segment2_cn.1EB20.ia1.png": [16,8,16,{"cn":[947456,125728]}], +"textures/segment2/segment2_cn.1EB30.ia1.png": [16,8,16,{"cn":[947456,125744]}], +"textures/segment2/segment2_cn.1EB40.ia1.png": [16,8,16,{"cn":[947456,125760]}], +"textures/segment2/segment2_cn.1EB50.ia1.png": [16,8,16,{"cn":[947456,125776]}], +"textures/segment2/segment2_cn.1EB60.ia1.png": [16,8,16,{"cn":[947456,125792]}], +"textures/segment2/segment2_cn.1EB70.ia1.png": [16,8,16,{"cn":[947456,125808]}], +"textures/segment2/segment2_cn.1EB80.ia1.png": [16,8,16,{"cn":[947456,125824]}], +"textures/segment2/segment2_cn.1EB90.ia1.png": [16,8,16,{"cn":[947456,125840]}], +"textures/segment2/segment2_cn.1EBA0.ia1.png": [16,8,16,{"cn":[947456,125856]}], +"textures/segment2/segment2_cn.1EBB0.ia1.png": [16,8,16,{"cn":[947456,125872]}], +"textures/segment2/segment2_cn.1EBC0.ia1.png": [16,8,16,{"cn":[947456,125888]}], +"textures/segment2/segment2_cn.1EBD0.ia1.png": [16,8,16,{"cn":[947456,125904]}], +"textures/segment2/segment2_cn.1EBE0.ia1.png": [16,8,16,{"cn":[947456,125920]}], +"textures/segment2/segment2_cn.1EBF0.ia1.png": [16,8,16,{"cn":[947456,125936]}], +"textures/segment2/segment2_cn.1EC00.ia1.png": [16,8,16,{"cn":[947456,125952]}], +"textures/segment2/segment2_cn.1EC10.ia1.png": [16,8,16,{"cn":[947456,125968]}], +"textures/segment2/segment2_cn.1EC20.ia1.png": [16,8,16,{"cn":[947456,125984]}], +"textures/segment2/segment2_cn.1EC30.ia1.png": [16,8,16,{"cn":[947456,126000]}], +"textures/segment2/segment2_cn.1EC40.ia1.png": [16,8,16,{"cn":[947456,126016]}], +"textures/segment2/segment2_cn.1EC50.ia1.png": [16,8,16,{"cn":[947456,126032]}], +"textures/segment2/segment2_cn.1EC60.ia1.png": [16,8,16,{"cn":[947456,126048]}], +"textures/segment2/segment2_cn.1EC70.ia1.png": [16,8,16,{"cn":[947456,126064]}], +"textures/segment2/segment2_cn.1EC80.ia1.png": [16,8,16,{"cn":[947456,126080]}], +"textures/segment2/segment2_cn.1EC90.ia1.png": [16,8,16,{"cn":[947456,126096]}], +"textures/segment2/segment2_cn.1ECA0.ia1.png": [16,8,16,{"cn":[947456,126112]}], +"textures/segment2/segment2_cn.1ECB0.ia1.png": [16,8,16,{"cn":[947456,126128]}], +"textures/segment2/segment2_cn.1ECC0.ia1.png": [16,8,16,{"cn":[947456,126144]}], +"textures/segment2/segment2_cn.1ECD0.ia1.png": [16,8,16,{"cn":[947456,126160]}], +"textures/segment2/segment2_cn.1ECE0.ia1.png": [16,8,16,{"cn":[947456,126176]}], +"textures/segment2/segment2_cn.1ECF0.ia1.png": [16,8,16,{"cn":[947456,126192]}], +"textures/segment2/segment2_cn.1ED00.ia1.png": [16,8,16,{"cn":[947456,126208]}], +"textures/segment2/segment2_cn.1ED10.ia1.png": [16,8,16,{"cn":[947456,126224]}], +"textures/segment2/segment2_cn.1ED20.ia1.png": [16,8,16,{"cn":[947456,126240]}], +"textures/segment2/segment2_cn.1ED30.ia1.png": [16,8,16,{"cn":[947456,126256]}], +"textures/segment2/segment2_cn.1ED40.ia1.png": [16,8,16,{"cn":[947456,126272]}], +"textures/segment2/segment2_cn.1ED50.ia1.png": [16,8,16,{"cn":[947456,126288]}], +"textures/segment2/segment2_cn.1ED60.ia1.png": [16,8,16,{"cn":[947456,126304]}], +"textures/segment2/segment2_cn.1ED70.ia1.png": [16,8,16,{"cn":[947456,126320]}], +"textures/segment2/segment2_cn.1ED80.ia1.png": [16,8,16,{"cn":[947456,126336]}], +"textures/segment2/segment2_cn.1ED90.ia1.png": [16,8,16,{"cn":[947456,126352]}], +"textures/segment2/segment2_cn.1EDA0.ia1.png": [16,8,16,{"cn":[947456,126368]}], +"textures/segment2/segment2_cn.1EDB0.ia1.png": [16,8,16,{"cn":[947456,126384]}], +"textures/segment2/segment2_cn.1EDC0.ia1.png": [16,8,16,{"cn":[947456,126400]}], +"textures/segment2/segment2_cn.1EDD0.ia1.png": [16,8,16,{"cn":[947456,126416]}], +"textures/segment2/segment2_cn.1EDE0.ia1.png": [16,8,16,{"cn":[947456,126432]}], +"textures/segment2/segment2_cn.1EDF0.ia1.png": [16,8,16,{"cn":[947456,126448]}], +"textures/segment2/segment2_cn.1EE00.ia1.png": [16,8,16,{"cn":[947456,126464]}], +"textures/segment2/segment2_cn.1EE10.ia1.png": [16,8,16,{"cn":[947456,126480]}], +"textures/segment2/segment2_cn.1EE20.ia1.png": [16,8,16,{"cn":[947456,126496]}], +"textures/segment2/segment2_cn.1EE30.ia1.png": [16,8,16,{"cn":[947456,126512]}], +"textures/segment2/segment2_cn.1EE40.ia1.png": [16,8,16,{"cn":[947456,126528]}], +"textures/segment2/segment2_cn.1EE50.ia1.png": [16,8,16,{"cn":[947456,126544]}], +"textures/segment2/segment2_cn.1EE60.ia1.png": [16,8,16,{"cn":[947456,126560]}], +"textures/segment2/segment2_cn.1EE70.ia1.png": [16,8,16,{"cn":[947456,126576]}], +"textures/segment2/shadow_quarter_circle.ia8.png": [16,16,256,{"jp":[1078992,62040],"us":[1083968,73912],"eu":[909712,30584],"sh":[934640,62040],"cn":[947456,174376]}], +"textures/segment2/shadow_quarter_square.ia8.png": [16,16,256,{"jp":[1078992,62296],"us":[1083968,74168],"eu":[909712,30840],"sh":[934640,62296],"cn":[947456,174632]}], +"textures/sky/metal_hole.rgba16.png": [32,32,2048,{"jp":[3390640,26624],"us":[3397392,26624],"eu":[3270992,26624],"sh":[3245360,26624],"cn":[3319120,26624]}], +"textures/sky/rr_textures.00000.rgba16.png": [32,32,2048,{"jp":[3390640,0],"us":[3397392,0],"eu":[3270992,0],"sh":[3245360,0],"cn":[3319120,0]}], +"textures/sky/rr_textures.00800.rgba16.png": [32,32,2048,{"jp":[3390640,2048],"us":[3397392,2048],"eu":[3270992,2048],"sh":[3245360,2048],"cn":[3319120,2048]}], +"textures/sky/rr_textures.01000.rgba16.png": [32,32,2048,{"jp":[3390640,4096],"us":[3397392,4096],"eu":[3270992,4096],"sh":[3245360,4096],"cn":[3319120,4096]}], +"textures/sky/rr_textures.01800.rgba16.png": [32,32,2048,{"jp":[3390640,6144],"us":[3397392,6144],"eu":[3270992,6144],"sh":[3245360,6144],"cn":[3319120,6144]}], +"textures/sky/rr_textures.02000.rgba16.png": [32,64,4096,{"jp":[3390640,8192],"us":[3397392,8192],"eu":[3270992,8192],"sh":[3245360,8192],"cn":[3319120,8192]}], +"textures/sky/rr_textures.03000.rgba16.png": [32,32,2048,{"jp":[3390640,12288],"us":[3397392,12288],"eu":[3270992,12288],"sh":[3245360,12288],"cn":[3319120,12288]}], +"textures/sky/rr_textures.03800.rgba16.png": [64,32,4096,{"jp":[3390640,14336],"us":[3397392,14336],"eu":[3270992,14336],"sh":[3245360,14336],"cn":[3319120,14336]}], +"textures/sky/rr_textures.04800.rgba16.png": [32,32,2048,{"jp":[3390640,18432],"us":[3397392,18432],"eu":[3270992,18432],"sh":[3245360,18432],"cn":[3319120,18432]}], +"textures/sky/rr_textures.05000.rgba16.png": [32,32,2048,{"jp":[3390640,20480],"us":[3397392,20480],"eu":[3270992,20480],"sh":[3245360,20480],"cn":[3319120,20480]}], +"textures/sky/rr_textures.05800.rgba16.png": [32,32,2048,{"jp":[3390640,22528],"us":[3397392,22528],"eu":[3270992,22528],"sh":[3245360,22528],"cn":[3319120,22528]}], +"textures/sky/rr_textures.06000.rgba16.png": [32,32,2048,{"jp":[3390640,24576],"us":[3397392,24576],"eu":[3270992,24576],"sh":[3245360,24576],"cn":[3319120,24576]}], +"textures/sky/rr_textures.07000.rgba16.png": [32,32,2048,{"jp":[3390640,28672],"us":[3397392,28672],"eu":[3270992,28672],"sh":[3245360,28672],"cn":[3319120,28672]}], +"textures/sky/rr_textures.07800.rgba16.png": [32,32,2048,{"jp":[3390640,30720],"us":[3397392,30720],"eu":[3270992,30720],"sh":[3245360,30720],"cn":[3319120,30720]}], +"textures/sky/rr_textures.08000.rgba16.png": [32,32,2048,{"jp":[3390640,32768],"us":[3397392,32768],"eu":[3270992,32768],"sh":[3245360,32768],"cn":[3319120,32768]}], +"textures/snow/ccm_textures.00000.rgba16.png": [32,32,2048,{"jp":[3405536,0],"us":[3412288,0],"eu":[3285888,0],"sh":[3260256,0],"cn":[3334016,0]}], +"textures/snow/ccm_textures.00800.rgba16.png": [32,32,2048,{"jp":[3405536,2048],"us":[3412288,2048],"eu":[3285888,2048],"sh":[3260256,2048],"cn":[3334016,2048]}], +"textures/snow/ccm_textures.01000.rgba16.png": [32,64,4096,{"jp":[3405536,4096],"us":[3412288,4096],"eu":[3285888,4096],"sh":[3260256,4096],"cn":[3334016,4096]}], +"textures/snow/ccm_textures.02000.rgba16.png": [32,32,2048,{"jp":[3405536,8192],"us":[3412288,8192],"eu":[3285888,8192],"sh":[3260256,8192],"cn":[3334016,8192]}], +"textures/snow/ccm_textures.02800.rgba16.png": [32,32,2048,{"jp":[3405536,10240],"us":[3412288,10240],"eu":[3285888,10240],"sh":[3260256,10240],"cn":[3334016,10240]}], +"textures/snow/ccm_textures.03000.rgba16.png": [32,32,2048,{"jp":[3405536,12288],"us":[3412288,12288],"eu":[3285888,12288],"sh":[3260256,12288],"cn":[3334016,12288]}], +"textures/snow/ccm_textures.03800.rgba16.png": [32,32,2048,{"jp":[3405536,14336],"us":[3412288,14336],"eu":[3285888,14336],"sh":[3260256,14336],"cn":[3334016,14336]}], +"textures/snow/ccm_textures.04000.rgba16.png": [32,32,2048,{"jp":[3405536,16384],"us":[3412288,16384],"eu":[3285888,16384],"sh":[3260256,16384],"cn":[3334016,16384]}], +"textures/snow/ccm_textures.04800.rgba16.png": [32,32,2048,{"jp":[3405536,18432],"us":[3412288,18432],"eu":[3285888,18432],"sh":[3260256,18432],"cn":[3334016,18432]}], +"textures/snow/ccm_textures.05000.rgba16.png": [32,32,2048,{"jp":[3405536,20480],"us":[3412288,20480],"eu":[3285888,20480],"sh":[3260256,20480],"cn":[3334016,20480]}], +"textures/snow/ccm_textures.05800.rgba16.png": [32,32,2048,{"jp":[3405536,22528],"us":[3412288,22528],"eu":[3285888,22528],"sh":[3260256,22528],"cn":[3334016,22528]}], +"textures/snow/ccm_textures.06000.rgba16.png": [32,32,2048,{"jp":[3405536,24576],"us":[3412288,24576],"eu":[3285888,24576],"sh":[3260256,24576],"cn":[3334016,24576]}], +"textures/snow/ccm_textures.06800.rgba16.png": [32,32,2048,{"jp":[3405536,26624],"us":[3412288,26624],"eu":[3285888,26624],"sh":[3260256,26624],"cn":[3334016,26624]}], +"textures/snow/ccm_textures.07000.rgba16.png": [64,32,4096,{"jp":[3405536,28672],"us":[3412288,28672],"eu":[3285888,28672],"sh":[3260256,28672],"cn":[3334016,28672]}], +"textures/snow/ccm_textures.08000.rgba16.png": [32,32,2048,{"jp":[3405536,32768],"us":[3412288,32768],"eu":[3285888,32768],"sh":[3260256,32768],"cn":[3334016,32768]}], +"textures/snow/ccm_textures.08800.rgba16.png": [32,32,2048,{"jp":[3405536,34816],"us":[3412288,34816],"eu":[3285888,34816],"sh":[3260256,34816],"cn":[3334016,34816]}], +"textures/snow/ccm_textures.09000.ia16.png": [32,32,2048,{"jp":[3405536,36864],"us":[3412288,36864],"eu":[3285888,36864],"sh":[3260256,36864],"cn":[3334016,36864]}], +"textures/snow/ccm_textures.09800.ia16.png": [32,32,2048,{"jp":[3405536,38912],"us":[3412288,38912],"eu":[3285888,38912],"sh":[3260256,38912],"cn":[3334016,38912]}], +"textures/spooky/bbh_textures.00000.rgba16.png": [32,32,2048,{"jp":[3298272,0],"us":[3305024,0],"eu":[3178624,0],"sh":[3152992,0],"cn":[3226752,0]}], +"textures/spooky/bbh_textures.00800.rgba16.png": [32,64,4096,{"jp":[3298272,2048],"us":[3305024,2048],"eu":[3178624,2048],"sh":[3152992,2048],"cn":[3226752,2048]}], +"textures/spooky/bbh_textures.01800.rgba16.png": [32,64,4096,{"jp":[3298272,6144],"us":[3305024,6144],"eu":[3178624,6144],"sh":[3152992,6144],"cn":[3226752,6144]}], +"textures/spooky/bbh_textures.02800.rgba16.png": [32,64,4096,{"jp":[3298272,10240],"us":[3305024,10240],"eu":[3178624,10240],"sh":[3152992,10240],"cn":[3226752,10240]}], +"textures/spooky/bbh_textures.03800.rgba16.png": [32,64,4096,{"jp":[3298272,14336],"us":[3305024,14336],"eu":[3178624,14336],"sh":[3152992,14336],"cn":[3226752,14336]}], +"textures/spooky/bbh_textures.04800.rgba16.png": [32,32,2048,{"jp":[3298272,18432],"us":[3305024,18432],"eu":[3178624,18432],"sh":[3152992,18432],"cn":[3226752,18432]}], +"textures/spooky/bbh_textures.05000.rgba16.png": [32,64,4096,{"jp":[3298272,20480],"us":[3305024,20480],"eu":[3178624,20480],"sh":[3152992,20480],"cn":[3226752,20480]}], +"textures/spooky/bbh_textures.06000.rgba16.png": [32,32,2048,{"jp":[3298272,24576],"us":[3305024,24576],"eu":[3178624,24576],"sh":[3152992,24576],"cn":[3226752,24576]}], +"textures/spooky/bbh_textures.06800.rgba16.png": [32,32,2048,{"jp":[3298272,26624],"us":[3305024,26624],"eu":[3178624,26624],"sh":[3152992,26624],"cn":[3226752,26624]}], +"textures/spooky/bbh_textures.07000.rgba16.png": [64,32,4096,{"jp":[3298272,28672],"us":[3305024,28672],"eu":[3178624,28672],"sh":[3152992,28672],"cn":[3226752,28672]}], +"textures/spooky/bbh_textures.08000.rgba16.png": [32,32,2048,{"jp":[3298272,32768],"us":[3305024,32768],"eu":[3178624,32768],"sh":[3152992,32768],"cn":[3226752,32768]}], +"textures/spooky/bbh_textures.08800.rgba16.png": [32,32,2048,{"jp":[3298272,34816],"us":[3305024,34816],"eu":[3178624,34816],"sh":[3152992,34816],"cn":[3226752,34816]}], +"textures/spooky/bbh_textures.09000.rgba16.png": [64,32,4096,{"jp":[3298272,36864],"us":[3305024,36864],"eu":[3178624,36864],"sh":[3152992,36864],"cn":[3226752,36864]}], +"textures/spooky/bbh_textures.0A000.rgba16.png": [32,32,2048,{"jp":[1462368,49800],"us":[1469536,49800],"eu":[1341504,49800],"sh":[1318016,49800],"cn":[1384848,49800]}], +"textures/spooky/bbh_textures.0A800.ia16.png": [32,32,2048,{"jp":[3298272,43008],"us":[3305024,43008],"eu":[3178624,43008],"sh":[3152992,43008],"cn":[3226752,43008]}], +"textures/spooky/bbh_textures.0B000.ia16.png": [32,32,2048,{"jp":[3298272,45056],"us":[3305024,45056],"eu":[3178624,45056],"sh":[3152992,45056],"cn":[3226752,45056]}], +"textures/spooky/bbh_textures.0B800.ia16.png": [32,64,4096,{"jp":[3298272,47104],"us":[3305024,47104],"eu":[3178624,47104],"sh":[3152992,47104],"cn":[3226752,47104]}], "textures/title_screen_bg/title_screen_bg.001C0.rgba16.png": [80,20,3200,{"jp":[2550336,448],"us":[2558144,448],"eu":[2426672,448],"sh":[2403488,448]}], "textures/title_screen_bg/title_screen_bg.00E40.rgba16.png": [80,20,3200,{"jp":[2550336,3648],"us":[2558144,3648],"eu":[2426672,3648],"sh":[2403488,3648]}], "textures/title_screen_bg/title_screen_bg.01AC0.rgba16.png": [80,20,3200,{"jp":[2550336,6848],"us":[2558144,6848],"eu":[2426672,6848],"sh":[2403488,6848]}], @@ -1845,243 +4128,251 @@ "textures/title_screen_bg/title_screen_bg.04040.rgba16.png": [80,20,3200,{"jp":[2550336,16448],"us":[2558144,16448],"eu":[2426672,16448],"sh":[2403488,16448]}], "textures/title_screen_bg/title_screen_bg.04CC0.rgba16.png": [80,20,3200,{"jp":[2550336,19648],"us":[2558144,19648],"eu":[2426672,19648],"sh":[2403488,19648]}], "textures/title_screen_bg/title_screen_bg.05940.rgba16.png": [80,20,3200,{"jp":[2550336,22848],"us":[2558144,22848],"eu":[2426672,22848],"sh":[2403488,22848]}], -"textures/title_screen_bg/title_screen_bg.06648.rgba16.png": [80,24,3840,{"sh":[2403488,26184]}], -"textures/water/jrb_textures.00000.rgba16.png": [32,32,2048,{"jp":[3354832,0],"us":[3361584,0],"eu":[3235184,0],"sh":[3209552,0]}], -"textures/water/jrb_textures.00800.rgba16.png": [64,32,4096,{"jp":[3354832,2048],"us":[3361584,2048],"eu":[3235184,2048],"sh":[3209552,2048]}], -"textures/water/jrb_textures.01800.rgba16.png": [64,32,4096,{"jp":[3354832,6144],"us":[3361584,6144],"eu":[3235184,6144],"sh":[3209552,6144]}], -"textures/water/jrb_textures.02800.rgba16.png": [64,32,4096,{"jp":[3354832,10240],"us":[3361584,10240],"eu":[3235184,10240],"sh":[3209552,10240]}], -"textures/water/jrb_textures.03800.rgba16.png": [64,32,4096,{"jp":[3354832,14336],"us":[3361584,14336],"eu":[3235184,14336],"sh":[3209552,14336]}], -"textures/water/jrb_textures.04800.rgba16.png": [64,32,4096,{"jp":[3354832,18432],"us":[3361584,18432],"eu":[3235184,18432],"sh":[3209552,18432]}], -"textures/water/jrb_textures.05800.rgba16.png": [32,32,2048,{"jp":[3354832,22528],"us":[3361584,22528],"eu":[3235184,22528],"sh":[3209552,22528]}], -"textures/water/jrb_textures.06000.rgba16.png": [32,32,2048,{"jp":[3354832,24576],"us":[3361584,24576],"eu":[3235184,24576],"sh":[3209552,24576]}], -"textures/water/jrb_textures.06800.rgba16.png": [64,32,4096,{"jp":[3354832,26624],"us":[3361584,26624],"eu":[3235184,26624],"sh":[3209552,26624]}], -"textures/water/jrb_textures.07800.rgba16.png": [64,32,4096,{"jp":[3354832,30720],"us":[3361584,30720],"eu":[3235184,30720],"sh":[3209552,30720]}], -"textures/water/jrb_textures.08800.rgba16.png": [32,32,2048,{"jp":[3354832,34816],"us":[3361584,34816],"eu":[3235184,34816],"sh":[3209552,34816]}], -"textures/water/jrb_textures.09000.rgba16.png": [64,32,4096,{"jp":[3354832,36864],"us":[3361584,36864],"eu":[3235184,36864],"sh":[3209552,36864]}], -"textures/water/jrb_textures.0A000.rgba16.png": [32,32,2048,{"jp":[3354832,40960],"us":[3361584,40960],"eu":[3235184,40960],"sh":[3209552,40960]}], -"textures/water/jrb_textures.0A800.rgba16.png": [64,32,4096,{"jp":[3354832,43008],"us":[3361584,43008],"eu":[3235184,43008],"sh":[3209552,43008]}], -"textures/water/jrb_textures.0B800.rgba16.png": [64,32,4096,{"jp":[3354832,47104],"us":[3361584,47104],"eu":[3235184,47104],"sh":[3209552,47104]}], -"sound/samples/bowser_organ/00_organ_1.aiff": [0,{"jp":["@sound",195],"us":["@sound",216],"eu":["@sound",216]}], -"sound/samples/bowser_organ/01_organ_1_lq.aiff": [0,{"jp":["@sound",196],"us":["@sound",217],"eu":["@sound",217]}], -"sound/samples/bowser_organ/02_boys_choir.aiff": [0,{"jp":["@sound",197],"us":["@sound",218],"eu":["@sound",218]}], -"sound/samples/course_start/00_la.aiff": [0,{"jp":["@sound",194],"us":["@sound",215],"eu":["@sound",215]}], -"sound/samples/instruments/00.aiff": [0,{"jp":["@sound",120],"us":["@sound",141],"eu":["@sound",141],"sh":["@sound",141]}], -"sound/samples/instruments/01_banjo_1.aiff": [0,{"jp":["@sound",121],"us":["@sound",142],"eu":["@sound",142],"sh":["@sound",142]}], -"sound/samples/instruments/02.aiff": [0,{"jp":["@sound",122],"us":["@sound",143],"eu":["@sound",143],"sh":["@sound",143]}], -"sound/samples/instruments/03_human_whistle.aiff": [0,{"jp":["@sound",123],"us":["@sound",144],"eu":["@sound",144],"sh":["@sound",144]}], -"sound/samples/instruments/04_bright_piano.aiff": [0,{"jp":["@sound",124],"us":["@sound",145],"eu":["@sound",145],"sh":["@sound",145]}], -"sound/samples/instruments/05_acoustic_bass.aiff": [0,{"jp":["@sound",125],"us":["@sound",146],"eu":["@sound",146],"sh":["@sound",146]}], -"sound/samples/instruments/06_kick_drum_1.aiff": [0,{"jp":["@sound",126],"us":["@sound",147],"eu":["@sound",147],"sh":["@sound",147]}], -"sound/samples/instruments/07_rimshot.aiff": [0,{"jp":["@sound",127],"us":["@sound",148],"eu":["@sound",148],"sh":["@sound",148]}], -"sound/samples/instruments/08.aiff": [0,{"jp":["@sound",128],"us":["@sound",149],"eu":["@sound",149],"sh":["@sound",149]}], -"sound/samples/instruments/09.aiff": [0,{"jp":["@sound",129],"us":["@sound",150],"eu":["@sound",150],"sh":["@sound",150]}], -"sound/samples/instruments/0A_tambourine.aiff": [0,{"jp":["@sound",130],"us":["@sound",151],"eu":["@sound",151],"sh":["@sound",151]}], -"sound/samples/instruments/0B.aiff": [0,{"jp":["@sound",131],"us":["@sound",152],"eu":["@sound",152],"sh":["@sound",152]}], -"sound/samples/instruments/0C_conga_stick.aiff": [0,{"jp":["@sound",132],"us":["@sound",153],"eu":["@sound",153],"sh":["@sound",153]}], -"sound/samples/instruments/0D_clave.aiff": [0,{"jp":["@sound",133],"us":["@sound",154],"eu":["@sound",154],"sh":["@sound",154]}], -"sound/samples/instruments/0E_hihat_closed.aiff": [0,{"jp":["@sound",134],"us":["@sound",155],"eu":["@sound",155],"sh":["@sound",155]}], -"sound/samples/instruments/0F_hihat_open.aiff": [0,{"jp":["@sound",135],"us":["@sound",156],"eu":["@sound",156],"sh":["@sound",156]}], -"sound/samples/instruments/10_cymbal_bell.aiff": [0,{"jp":["@sound",136],"us":["@sound",157],"eu":["@sound",157],"sh":["@sound",157]}], -"sound/samples/instruments/11_splash_cymbal.aiff": [0,{"jp":["@sound",137],"us":["@sound",158],"eu":["@sound",158],"sh":["@sound",158]}], -"sound/samples/instruments/12_snare_drum_1.aiff": [0,{"jp":["@sound",138],"us":["@sound",159],"eu":["@sound",159],"sh":["@sound",159]}], -"sound/samples/instruments/13_snare_drum_2.aiff": [0,{"jp":["@sound",139],"us":["@sound",160],"eu":["@sound",160],"sh":["@sound",160]}], -"sound/samples/instruments/14_strings_5.aiff": [0,{"jp":["@sound",140],"us":["@sound",161],"eu":["@sound",161],"sh":["@sound",161]}], -"sound/samples/instruments/15_strings_4.aiff": [0,{"jp":["@sound",141],"us":["@sound",162],"eu":["@sound",162],"sh":["@sound",162]}], -"sound/samples/instruments/16_french_horns.aiff": [0,{"jp":["@sound",142],"us":["@sound",163],"eu":["@sound",163],"sh":["@sound",163]}], -"sound/samples/instruments/17_trumpet.aiff": [0,{"jp":["@sound",143],"us":["@sound",164],"eu":["@sound",164],"sh":["@sound",164]}], -"sound/samples/instruments/18_timpani.aiff": [0,{"jp":["@sound",144],"us":["@sound",165],"eu":["@sound",165],"sh":["@sound",165]}], -"sound/samples/instruments/19_brass.aiff": [0,{"jp":["@sound",145],"us":["@sound",166],"eu":["@sound",166],"sh":["@sound",166]}], -"sound/samples/instruments/1A_slap_bass.aiff": [0,{"jp":["@sound",146],"us":["@sound",167],"eu":["@sound",167],"sh":["@sound",167]}], -"sound/samples/instruments/1B_organ_2.aiff": [0,{"jp":["@sound",147],"us":["@sound",168],"eu":["@sound",168],"sh":["@sound",168]}], -"sound/samples/instruments/1C.aiff": [0,{"jp":["@sound",148],"us":["@sound",169],"eu":["@sound",169],"sh":["@sound",169]}], -"sound/samples/instruments/1D.aiff": [0,{"jp":["@sound",149],"us":["@sound",170],"eu":["@sound",170],"sh":["@sound",170]}], -"sound/samples/instruments/1E_closed_triangle.aiff": [0,{"jp":["@sound",150],"us":["@sound",171],"eu":["@sound",171],"sh":["@sound",171]}], -"sound/samples/instruments/1F_open_triangle.aiff": [0,{"jp":["@sound",151],"us":["@sound",172],"eu":["@sound",172],"sh":["@sound",172]}], -"sound/samples/instruments/20_cabasa.aiff": [0,{"jp":["@sound",152],"us":["@sound",173],"eu":["@sound",173],"sh":["@sound",173]}], -"sound/samples/instruments/21_sine_bass.aiff": [0,{"jp":["@sound",153],"us":["@sound",174],"eu":["@sound",174],"sh":["@sound",174]}], -"sound/samples/instruments/22_boys_choir.aiff": [0,{"jp":["@sound",154],"us":["@sound",175],"eu":["@sound",175],"sh":["@sound",175]}], -"sound/samples/instruments/23_strings_1.aiff": [0,{"jp":["@sound",155],"us":["@sound",176],"eu":["@sound",176],"sh":["@sound",176]}], -"sound/samples/instruments/24_strings_2.aiff": [0,{"jp":["@sound",156],"us":["@sound",177],"eu":["@sound",177],"sh":["@sound",177]}], -"sound/samples/instruments/25_strings_3.aiff": [0,{"jp":["@sound",157],"us":["@sound",178],"eu":["@sound",178],"sh":["@sound",178]}], -"sound/samples/instruments/26_crystal_rhodes.aiff": [0,{"jp":["@sound",158],"us":["@sound",179],"eu":["@sound",179],"sh":["@sound",179]}], -"sound/samples/instruments/27_harpsichord.aiff": [0,{"jp":["@sound",159],"us":["@sound",180],"eu":["@sound",180],"sh":["@sound",180]}], -"sound/samples/instruments/28_sitar_1.aiff": [0,{"jp":["@sound",160],"us":["@sound",181],"eu":["@sound",181],"sh":["@sound",181]}], -"sound/samples/instruments/29_orchestra_hit.aiff": [0,{"jp":["@sound",161],"us":["@sound",182],"eu":["@sound",182],"sh":["@sound",182]}], -"sound/samples/instruments/2A.aiff": [0,{"jp":["@sound",162],"us":["@sound",183],"eu":["@sound",183],"sh":["@sound",183]}], -"sound/samples/instruments/2B.aiff": [0,{"jp":["@sound",163],"us":["@sound",184],"eu":["@sound",184],"sh":["@sound",184]}], -"sound/samples/instruments/2C.aiff": [0,{"jp":["@sound",164],"us":["@sound",185],"eu":["@sound",185],"sh":["@sound",185]}], -"sound/samples/instruments/2D_trombone.aiff": [0,{"jp":["@sound",165],"us":["@sound",186],"eu":["@sound",186],"sh":["@sound",186]}], -"sound/samples/instruments/2E_accordion.aiff": [0,{"jp":["@sound",166],"us":["@sound",187],"eu":["@sound",187],"sh":["@sound",187]}], -"sound/samples/instruments/2F_sleigh_bells.aiff": [0,{"jp":["@sound",167],"us":["@sound",188],"eu":["@sound",188],"sh":["@sound",188]}], -"sound/samples/instruments/30_rarefaction-lahna.aiff": [0,{"jp":["@sound",168],"us":["@sound",189],"eu":["@sound",189],"sh":["@sound",189]}], -"sound/samples/instruments/31_rarefaction-convolution.aiff": [0,{"jp":["@sound",169],"us":["@sound",190],"eu":["@sound",190],"sh":["@sound",190]}], -"sound/samples/instruments/32_metal_rimshot.aiff": [0,{"jp":["@sound",170],"us":["@sound",191],"eu":["@sound",191],"sh":["@sound",191]}], -"sound/samples/instruments/33_kick_drum_2.aiff": [0,{"jp":["@sound",171],"us":["@sound",192],"eu":["@sound",192],"sh":["@sound",192]}], -"sound/samples/instruments/34_alto_flute.aiff": [0,{"jp":["@sound",172],"us":["@sound",193],"eu":["@sound",193],"sh":["@sound",193]}], -"sound/samples/instruments/34b_organ.aiff": [0,{"sh":["@sound",194]}], -"sound/samples/instruments/34c_organ_lq.aiff": [0,{"sh":["@sound",195]}], -"sound/samples/instruments/35_gospel_organ.aiff": [0,{"jp":["@sound",173],"us":["@sound",194],"eu":["@sound",194],"sh":["@sound",196]}], -"sound/samples/instruments/36_sawtooth_synth.aiff": [0,{"jp":["@sound",174],"us":["@sound",195],"eu":["@sound",195],"sh":["@sound",197]}], -"sound/samples/instruments/37_square_synth.aiff": [0,{"jp":["@sound",175],"us":["@sound",196],"eu":["@sound",196],"sh":["@sound",198]}], -"sound/samples/instruments/38_electric_kick_drum.aiff": [0,{"jp":["@sound",176],"us":["@sound",197],"eu":["@sound",197],"sh":["@sound",199]}], -"sound/samples/instruments/39_sitar_2.aiff": [0,{"jp":["@sound",177],"us":["@sound",198],"eu":["@sound",198],"sh":["@sound",200]}], -"sound/samples/instruments/3A_music_box.aiff": [0,{"jp":["@sound",178],"us":["@sound",199],"eu":["@sound",199],"sh":["@sound",201]}], -"sound/samples/instruments/3B_banjo_2.aiff": [0,{"jp":["@sound",179],"us":["@sound",200],"eu":["@sound",200],"sh":["@sound",202]}], -"sound/samples/instruments/3C_acoustic_guitar.aiff": [0,{"jp":["@sound",180],"us":["@sound",201],"eu":["@sound",201],"sh":["@sound",203]}], -"sound/samples/instruments/3D.aiff": [0,{"jp":["@sound",181],"us":["@sound",202],"eu":["@sound",202],"sh":["@sound",204]}], -"sound/samples/instruments/3E_monk_choir.aiff": [0,{"jp":["@sound",182],"us":["@sound",203],"eu":["@sound",203],"sh":["@sound",205]}], -"sound/samples/instruments/3F.aiff": [0,{"jp":["@sound",183],"us":["@sound",204],"eu":["@sound",204],"sh":["@sound",206]}], -"sound/samples/instruments/40_bell.aiff": [0,{"jp":["@sound",184],"us":["@sound",205],"eu":["@sound",205],"sh":["@sound",207]}], -"sound/samples/instruments/41_pan_flute.aiff": [0,{"jp":["@sound",185],"us":["@sound",206],"eu":["@sound",206],"sh":["@sound",208]}], -"sound/samples/instruments/42_vibraphone.aiff": [0,{"jp":["@sound",186],"us":["@sound",207],"eu":["@sound",207],"sh":["@sound",209]}], -"sound/samples/instruments/43_harmonica.aiff": [0,{"jp":["@sound",187],"us":["@sound",208],"eu":["@sound",208],"sh":["@sound",210]}], -"sound/samples/instruments/44_grand_piano.aiff": [0,{"jp":["@sound",188],"us":["@sound",209],"eu":["@sound",209],"sh":["@sound",211]}], -"sound/samples/instruments/45_french_horns_lq.aiff": [0,{"jp":["@sound",189],"us":["@sound",210],"eu":["@sound",210],"sh":["@sound",212]}], -"sound/samples/instruments/45b_la.aiff": [0,{"sh":["@sound",213]}], -"sound/samples/instruments/46_pizzicato_strings_1.aiff": [0,{"jp":["@sound",190],"us":["@sound",211],"eu":["@sound",211],"sh":["@sound",214]}], -"sound/samples/instruments/47_pizzicato_strings_2.aiff": [0,{"jp":["@sound",191],"us":["@sound",212],"eu":["@sound",212],"sh":["@sound",215]}], -"sound/samples/instruments/48_steel_drum.aiff": [0,{"jp":["@sound",192],"us":["@sound",213],"eu":["@sound",213],"sh":["@sound",216]}], -"sound/samples/piranha_music_box/00_music_box.aiff": [0,{"jp":["@sound",193],"us":["@sound",214],"eu":["@sound",214]}], -"sound/samples/sfx_1/00_twirl.aiff": [0,{"jp":["@sound",0],"us":["@sound",0],"eu":["@sound",0],"sh":["@sound",0]}], -"sound/samples/sfx_1/01_brushing.aiff": [0,{"jp":["@sound",1],"us":["@sound",1],"eu":["@sound",1],"sh":["@sound",1]}], -"sound/samples/sfx_1/02_hand_touch.aiff": [0,{"jp":["@sound",2],"us":["@sound",2],"eu":["@sound",2],"sh":["@sound",2]}], -"sound/samples/sfx_1/03_yoshi.aiff": [0,{"jp":["@sound",3],"us":["@sound",3],"eu":["@sound",3],"sh":["@sound",3]}], -"sound/samples/sfx_1/04_plop.aiff": [0,{"jp":["@sound",4],"us":["@sound",4],"eu":["@sound",4],"sh":["@sound",4]}], -"sound/samples/sfx_1/05_heavy_landing.aiff": [0,{"jp":["@sound",5],"us":["@sound",5],"eu":["@sound",5],"sh":["@sound",5]}], -"sound/samples/sfx_4/00.aiff": [0,{"jp":["@sound",17],"us":["@sound",17],"eu":["@sound",17],"sh":["@sound",17]}], -"sound/samples/sfx_4/01.aiff": [0,{"jp":["@sound",18],"us":["@sound",18],"eu":["@sound",18],"sh":["@sound",18]}], -"sound/samples/sfx_4/02.aiff": [0,{"jp":["@sound",19],"us":["@sound",19],"eu":["@sound",19],"sh":["@sound",19]}], -"sound/samples/sfx_4/03.aiff": [0,{"jp":["@sound",20],"us":["@sound",20],"eu":["@sound",20],"sh":["@sound",20]}], -"sound/samples/sfx_4/04.aiff": [0,{"jp":["@sound",21],"us":["@sound",21],"eu":["@sound",21],"sh":["@sound",21]}], -"sound/samples/sfx_4/05.aiff": [0,{"jp":["@sound",22],"us":["@sound",22],"eu":["@sound",22],"sh":["@sound",22]}], -"sound/samples/sfx_4/06.aiff": [0,{"jp":["@sound",23],"us":["@sound",23],"eu":["@sound",23],"sh":["@sound",23]}], -"sound/samples/sfx_4/07.aiff": [0,{"jp":["@sound",24],"us":["@sound",24],"eu":["@sound",24],"sh":["@sound",24]}], -"sound/samples/sfx_4/08.aiff": [0,{"jp":["@sound",25],"us":["@sound",25],"eu":["@sound",25],"sh":["@sound",25]}], -"sound/samples/sfx_4/09.aiff": [0,{"jp":["@sound",26],"us":["@sound",26],"eu":["@sound",26],"sh":["@sound",26]}], -"sound/samples/sfx_5/00.aiff": [0,{"jp":["@sound",27],"us":["@sound",27],"eu":["@sound",27],"sh":["@sound",27]}], -"sound/samples/sfx_5/01.aiff": [0,{"jp":["@sound",28],"us":["@sound",28],"eu":["@sound",28],"sh":["@sound",28]}], -"sound/samples/sfx_5/02.aiff": [0,{"jp":["@sound",29],"us":["@sound",29],"eu":["@sound",29],"sh":["@sound",29]}], -"sound/samples/sfx_5/03.aiff": [0,{"jp":["@sound",30],"us":["@sound",30],"eu":["@sound",30],"sh":["@sound",30]}], -"sound/samples/sfx_5/04.aiff": [0,{"jp":["@sound",31],"us":["@sound",31],"eu":["@sound",31],"sh":["@sound",31]}], -"sound/samples/sfx_5/05.aiff": [0,{"jp":["@sound",32],"us":["@sound",32],"eu":["@sound",32],"sh":["@sound",32]}], -"sound/samples/sfx_5/06.aiff": [0,{"jp":["@sound",33],"us":["@sound",33],"eu":["@sound",33],"sh":["@sound",33]}], -"sound/samples/sfx_5/07.aiff": [0,{"jp":["@sound",34],"us":["@sound",34],"eu":["@sound",34],"sh":["@sound",34]}], -"sound/samples/sfx_5/08.aiff": [0,{"jp":["@sound",35],"us":["@sound",35],"eu":["@sound",35],"sh":["@sound",35]}], -"sound/samples/sfx_5/09.aiff": [0,{"jp":["@sound",36],"us":["@sound",36],"eu":["@sound",36],"sh":["@sound",36]}], -"sound/samples/sfx_5/0A.aiff": [0,{"jp":["@sound",37],"us":["@sound",37],"eu":["@sound",37],"sh":["@sound",37]}], -"sound/samples/sfx_5/0B.aiff": [0,{"jp":["@sound",38],"us":["@sound",38],"eu":["@sound",38],"sh":["@sound",38]}], -"sound/samples/sfx_5/0C.aiff": [0,{"jp":["@sound",39],"us":["@sound",39],"eu":["@sound",39],"sh":["@sound",39]}], -"sound/samples/sfx_5/0D.aiff": [0,{"jp":["@sound",40],"us":["@sound",40],"eu":["@sound",40],"sh":["@sound",40]}], -"sound/samples/sfx_5/0E.aiff": [0,{"jp":["@sound",41],"us":["@sound",41],"eu":["@sound",41],"sh":["@sound",41]}], -"sound/samples/sfx_5/0F.aiff": [0,{"jp":["@sound",42],"us":["@sound",42],"eu":["@sound",42],"sh":["@sound",42]}], -"sound/samples/sfx_5/10.aiff": [0,{"jp":["@sound",43],"us":["@sound",43],"eu":["@sound",43],"sh":["@sound",43]}], -"sound/samples/sfx_5/11.aiff": [0,{"jp":["@sound",44],"us":["@sound",44],"eu":["@sound",44],"sh":["@sound",44]}], -"sound/samples/sfx_5/12.aiff": [0,{"jp":["@sound",45],"us":["@sound",45],"eu":["@sound",45],"sh":["@sound",45]}], -"sound/samples/sfx_5/13.aiff": [0,{"jp":["@sound",46],"us":["@sound",46],"eu":["@sound",46],"sh":["@sound",46]}], -"sound/samples/sfx_5/14.aiff": [0,{"jp":["@sound",47],"us":["@sound",47],"eu":["@sound",47],"sh":["@sound",47]}], -"sound/samples/sfx_5/15.aiff": [0,{"jp":["@sound",48],"us":["@sound",48],"eu":["@sound",48],"sh":["@sound",48]}], -"sound/samples/sfx_5/16.aiff": [0,{"jp":["@sound",49],"us":["@sound",49],"eu":["@sound",49],"sh":["@sound",49]}], -"sound/samples/sfx_5/17.aiff": [0,{"jp":["@sound",50],"us":["@sound",50],"eu":["@sound",50],"sh":["@sound",50]}], -"sound/samples/sfx_5/18.aiff": [0,{"jp":["@sound",51],"us":["@sound",51],"eu":["@sound",51],"sh":["@sound",51]}], -"sound/samples/sfx_5/19.aiff": [0,{"jp":["@sound",52],"us":["@sound",52],"eu":["@sound",52],"sh":["@sound",52]}], -"sound/samples/sfx_5/1A.aiff": [0,{"jp":["@sound",53],"us":["@sound",53],"eu":["@sound",53],"sh":["@sound",53]}], -"sound/samples/sfx_5/1B.aiff": [0,{"jp":["@sound",54],"us":["@sound",54],"eu":["@sound",54],"sh":["@sound",54]}], -"sound/samples/sfx_5/1C.aiff": [0,{"jp":["@sound",55],"us":["@sound",55],"eu":["@sound",55],"sh":["@sound",55]}], -"sound/samples/sfx_6/00.aiff": [0,{"jp":["@sound",56],"us":["@sound",56],"eu":["@sound",56],"sh":["@sound",56]}], -"sound/samples/sfx_6/01.aiff": [0,{"jp":["@sound",57],"us":["@sound",57],"eu":["@sound",57],"sh":["@sound",57]}], -"sound/samples/sfx_6/02.aiff": [0,{"jp":["@sound",58],"us":["@sound",58],"eu":["@sound",58],"sh":["@sound",58]}], -"sound/samples/sfx_6/03.aiff": [0,{"jp":["@sound",59],"us":["@sound",59],"eu":["@sound",59],"sh":["@sound",59]}], -"sound/samples/sfx_6/04.aiff": [0,{"jp":["@sound",60],"us":["@sound",60],"eu":["@sound",60],"sh":["@sound",60]}], -"sound/samples/sfx_6/05.aiff": [0,{"jp":["@sound",61],"us":["@sound",61],"eu":["@sound",61],"sh":["@sound",61]}], -"sound/samples/sfx_6/06.aiff": [0,{"jp":["@sound",62],"us":["@sound",62],"eu":["@sound",62],"sh":["@sound",62]}], -"sound/samples/sfx_6/07.aiff": [0,{"jp":["@sound",63],"us":["@sound",63],"eu":["@sound",63],"sh":["@sound",63]}], -"sound/samples/sfx_6/08.aiff": [0,{"jp":["@sound",64],"us":["@sound",64],"eu":["@sound",64],"sh":["@sound",64]}], -"sound/samples/sfx_6/09.aiff": [0,{"jp":["@sound",65],"us":["@sound",65],"eu":["@sound",65],"sh":["@sound",65]}], -"sound/samples/sfx_6/0A.aiff": [0,{"jp":["@sound",66],"us":["@sound",66],"eu":["@sound",66],"sh":["@sound",66]}], -"sound/samples/sfx_6/0B.aiff": [0,{"jp":["@sound",67],"us":["@sound",67],"eu":["@sound",67],"sh":["@sound",67]}], -"sound/samples/sfx_6/0C.aiff": [0,{"jp":["@sound",68],"us":["@sound",68],"eu":["@sound",68],"sh":["@sound",68]}], -"sound/samples/sfx_6/0D.aiff": [0,{"jp":["@sound",69],"us":["@sound",69],"eu":["@sound",69],"sh":["@sound",69]}], -"sound/samples/sfx_7/00.aiff": [0,{"jp":["@sound",70],"us":["@sound",70],"eu":["@sound",70],"sh":["@sound",70]}], -"sound/samples/sfx_7/01.aiff": [0,{"jp":["@sound",71],"us":["@sound",71],"eu":["@sound",71],"sh":["@sound",71]}], -"sound/samples/sfx_7/02.aiff": [0,{"jp":["@sound",72],"us":["@sound",72],"eu":["@sound",72],"sh":["@sound",72]}], -"sound/samples/sfx_7/03.aiff": [0,{"jp":["@sound",73],"us":["@sound",73],"eu":["@sound",73],"sh":["@sound",73]}], -"sound/samples/sfx_7/04.aiff": [0,{"jp":["@sound",74],"us":["@sound",74],"eu":["@sound",74],"sh":["@sound",74]}], -"sound/samples/sfx_7/05.aiff": [0,{"jp":["@sound",75],"us":["@sound",75],"eu":["@sound",75],"sh":["@sound",75]}], -"sound/samples/sfx_7/06.aiff": [0,{"jp":["@sound",76],"us":["@sound",76],"eu":["@sound",76],"sh":["@sound",76]}], -"sound/samples/sfx_7/07.aiff": [0,{"jp":["@sound",77],"us":["@sound",77],"eu":["@sound",77],"sh":["@sound",77]}], -"sound/samples/sfx_7/08.aiff": [0,{"jp":["@sound",78],"us":["@sound",78],"eu":["@sound",78],"sh":["@sound",78]}], -"sound/samples/sfx_7/09.aiff": [0,{"jp":["@sound",79],"us":["@sound",79],"eu":["@sound",79],"sh":["@sound",79]}], -"sound/samples/sfx_7/0A.aiff": [0,{"jp":["@sound",80],"us":["@sound",80],"eu":["@sound",80],"sh":["@sound",80]}], -"sound/samples/sfx_7/0B.aiff": [0,{"jp":["@sound",81],"us":["@sound",81],"eu":["@sound",81],"sh":["@sound",81]}], -"sound/samples/sfx_7/0C.aiff": [0,{"jp":["@sound",82],"us":["@sound",82],"eu":["@sound",82],"sh":["@sound",82]}], -"sound/samples/sfx_7/0D_chain_chomp_bark.aiff": [0,{"us":["@sound",83],"eu":["@sound",83],"sh":["@sound",83]}], -"sound/samples/sfx_9/00.aiff": [0,{"jp":["@sound",99],"us":["@sound",111],"eu":["@sound",111],"sh":["@sound",111]}], -"sound/samples/sfx_9/01.aiff": [0,{"jp":["@sound",100],"us":["@sound",112],"eu":["@sound",112],"sh":["@sound",112]}], -"sound/samples/sfx_9/02.aiff": [0,{"jp":["@sound",101],"us":["@sound",113],"eu":["@sound",113],"sh":["@sound",113]}], -"sound/samples/sfx_9/03.aiff": [0,{"jp":["@sound",102],"us":["@sound",114],"eu":["@sound",114],"sh":["@sound",114]}], -"sound/samples/sfx_9/04_camera_buzz.aiff": [0,{"jp":["@sound",103],"us":["@sound",115],"eu":["@sound",115],"sh":["@sound",115]}], -"sound/samples/sfx_9/05_camera_shutter.aiff": [0,{"jp":["@sound",104],"us":["@sound",116],"eu":["@sound",116],"sh":["@sound",116]}], -"sound/samples/sfx_9/06.aiff": [0,{"jp":["@sound",105],"us":["@sound",117],"eu":["@sound",117],"sh":["@sound",117]}], -"sound/samples/sfx_mario/00_mario_jump_hoo.aiff": [0,{"jp":["@sound",83],"us":["@sound",84],"eu":["@sound",84],"sh":["@sound",84]}], -"sound/samples/sfx_mario/01_mario_jump_wah.aiff": [0,{"jp":["@sound",84],"us":["@sound",85],"eu":["@sound",85],"sh":["@sound",85]}], -"sound/samples/sfx_mario/02_mario_yah.aiff": [0,{"jp":["@sound",85],"us":["@sound",86],"eu":["@sound",86],"sh":["@sound",86]}], -"sound/samples/sfx_mario/03_mario_haha.aiff": [0,{"jp":["@sound",86],"us":["@sound",87],"eu":["@sound",87],"sh":["@sound",87]}], -"sound/samples/sfx_mario/04_mario_yahoo.aiff": [0,{"jp":["@sound",87],"us":["@sound",88],"eu":["@sound",88],"sh":["@sound",88]}], -"sound/samples/sfx_mario/05_mario_uh.aiff": [0,{"jp":["@sound",88],"us":["@sound",89],"eu":["@sound",89],"sh":["@sound",89]}], -"sound/samples/sfx_mario/06_mario_hrmm.aiff": [0,{"jp":["@sound",89],"us":["@sound",90],"eu":["@sound",90],"sh":["@sound",90]}], -"sound/samples/sfx_mario/07_mario_wah2.aiff": [0,{"jp":["@sound",90],"us":["@sound",91],"eu":["@sound",91],"sh":["@sound",91]}], -"sound/samples/sfx_mario/08_mario_whoa.aiff": [0,{"jp":["@sound",91],"us":["@sound",92],"eu":["@sound",92],"sh":["@sound",92]}], -"sound/samples/sfx_mario/09_mario_eeuh.aiff": [0,{"jp":["@sound",92],"us":["@sound",93],"eu":["@sound",93],"sh":["@sound",93]}], -"sound/samples/sfx_mario/0A_mario_attacked.aiff": [0,{"jp":["@sound",93],"us":["@sound",94],"eu":["@sound",94],"sh":["@sound",94]}], -"sound/samples/sfx_mario/0B_mario_ooof.aiff": [0,{"jp":["@sound",94],"us":["@sound",95],"eu":["@sound",95],"sh":["@sound",95]}], -"sound/samples/sfx_mario/0C_mario_here_we_go.aiff": [0,{"jp":["@sound",95],"us":["@sound",96],"eu":["@sound",96],"sh":["@sound",96]}], -"sound/samples/sfx_mario/0D_mario_yawning.aiff": [0,{"jp":["@sound",96],"us":["@sound",97],"eu":["@sound",97],"sh":["@sound",97]}], -"sound/samples/sfx_mario/0E_mario_snoring1.aiff": [0,{"jp":["@sound",97],"us":["@sound",98],"eu":["@sound",98],"sh":["@sound",98]}], -"sound/samples/sfx_mario/0F_mario_snoring2.aiff": [0,{"jp":["@sound",98],"us":["@sound",99],"eu":["@sound",99],"sh":["@sound",99]}], -"sound/samples/sfx_mario/10_mario_doh.aiff": [0,{"us":["@sound",100],"eu":["@sound",100],"sh":["@sound",100]}], -"sound/samples/sfx_mario/11_mario_game_over.aiff": [0,{"us":["@sound",101],"eu":["@sound",101],"sh":["@sound",101]}], -"sound/samples/sfx_mario/12_mario_hello.aiff": [0,{"us":["@sound",102],"eu":["@sound",102],"sh":["@sound",102]}], -"sound/samples/sfx_mario/13_mario_press_start_to_play.aiff": [0,{"us":["@sound",103],"eu":["@sound",103],"sh":["@sound",103]}], -"sound/samples/sfx_mario/14_mario_twirl_bounce.aiff": [0,{"us":["@sound",104],"eu":["@sound",104],"sh":["@sound",104]}], -"sound/samples/sfx_mario/15_mario_snoring3.aiff": [0,{"us":["@sound",105],"eu":["@sound",105],"sh":["@sound",105]}], +"textures/title_screen_bg/title_screen_bg.06648.rgba16.png": [80,24,3840,{"sh":[2403488,26184],"cn":[2474624,26184]}], +"textures/title_screen_bg/title_screen_bg_ique.001C0.rgba16.png": [80,20,3200,{"cn":[2474624,448]}], +"textures/title_screen_bg/title_screen_bg_ique.00E40.rgba16.png": [80,20,3200,{"cn":[2474624,3648]}], +"textures/title_screen_bg/title_screen_bg_ique.01AC0.rgba16.png": [80,20,3200,{"cn":[2474624,6848]}], +"textures/title_screen_bg/title_screen_bg_ique.02740.rgba16.png": [80,20,3200,{"cn":[2474624,10048]}], +"textures/title_screen_bg/title_screen_bg_ique.033C0.rgba16.png": [80,20,3200,{"cn":[2474624,13248]}], +"textures/title_screen_bg/title_screen_bg_ique.04040.rgba16.png": [80,20,3200,{"cn":[2474624,16448]}], +"textures/title_screen_bg/title_screen_bg_ique.04CC0.rgba16.png": [80,20,3200,{"cn":[2474624,19648]}], +"textures/title_screen_bg/title_screen_bg_ique.05940.rgba16.png": [80,20,3200,{"cn":[2474624,22848]}], +"textures/water/jrb_textures.00000.rgba16.png": [32,32,2048,{"jp":[3354832,0],"us":[3361584,0],"eu":[3235184,0],"sh":[3209552,0],"cn":[3283312,0]}], +"textures/water/jrb_textures.00800.rgba16.png": [64,32,4096,{"jp":[3354832,2048],"us":[3361584,2048],"eu":[3235184,2048],"sh":[3209552,2048],"cn":[3283312,2048]}], +"textures/water/jrb_textures.01800.rgba16.png": [64,32,4096,{"jp":[3354832,6144],"us":[3361584,6144],"eu":[3235184,6144],"sh":[3209552,6144],"cn":[3283312,6144]}], +"textures/water/jrb_textures.02800.rgba16.png": [64,32,4096,{"jp":[3354832,10240],"us":[3361584,10240],"eu":[3235184,10240],"sh":[3209552,10240],"cn":[3283312,10240]}], +"textures/water/jrb_textures.03800.rgba16.png": [64,32,4096,{"jp":[3354832,14336],"us":[3361584,14336],"eu":[3235184,14336],"sh":[3209552,14336],"cn":[3283312,14336]}], +"textures/water/jrb_textures.04800.rgba16.png": [64,32,4096,{"jp":[3354832,18432],"us":[3361584,18432],"eu":[3235184,18432],"sh":[3209552,18432],"cn":[3283312,18432]}], +"textures/water/jrb_textures.05800.rgba16.png": [32,32,2048,{"jp":[3354832,22528],"us":[3361584,22528],"eu":[3235184,22528],"sh":[3209552,22528],"cn":[3283312,22528]}], +"textures/water/jrb_textures.06000.rgba16.png": [32,32,2048,{"jp":[3354832,24576],"us":[3361584,24576],"eu":[3235184,24576],"sh":[3209552,24576],"cn":[3283312,24576]}], +"textures/water/jrb_textures.06800.rgba16.png": [64,32,4096,{"jp":[3354832,26624],"us":[3361584,26624],"eu":[3235184,26624],"sh":[3209552,26624],"cn":[3283312,26624]}], +"textures/water/jrb_textures.07800.rgba16.png": [64,32,4096,{"jp":[3354832,30720],"us":[3361584,30720],"eu":[3235184,30720],"sh":[3209552,30720],"cn":[3283312,30720]}], +"textures/water/jrb_textures.08800.rgba16.png": [32,32,2048,{"jp":[3354832,34816],"us":[3361584,34816],"eu":[3235184,34816],"sh":[3209552,34816],"cn":[3283312,34816]}], +"textures/water/jrb_textures.09000.rgba16.png": [64,32,4096,{"jp":[3354832,36864],"us":[3361584,36864],"eu":[3235184,36864],"sh":[3209552,36864],"cn":[3283312,36864]}], +"textures/water/jrb_textures.0A000.rgba16.png": [32,32,2048,{"jp":[3354832,40960],"us":[3361584,40960],"eu":[3235184,40960],"sh":[3209552,40960],"cn":[3283312,40960]}], +"textures/water/jrb_textures.0A800.rgba16.png": [64,32,4096,{"jp":[3354832,43008],"us":[3361584,43008],"eu":[3235184,43008],"sh":[3209552,43008],"cn":[3283312,43008]}], +"textures/water/jrb_textures.0B800.rgba16.png": [64,32,4096,{"jp":[3354832,47104],"us":[3361584,47104],"eu":[3235184,47104],"sh":[3209552,47104],"cn":[3283312,47104]}], +"sound/samples/bowser_organ/00_organ_C3.aiff": [0,{"jp":["@sound",195],"us":["@sound",216],"eu":["@sound",216]}], +"sound/samples/bowser_organ/01_organ_C4.aiff": [0,{"jp":["@sound",196],"us":["@sound",217],"eu":["@sound",217]}], +"sound/samples/bowser_organ/02_boys_choir_Bb4.aiff": [0,{"jp":["@sound",197],"us":["@sound",218],"eu":["@sound",218]}], +"sound/samples/course_start/00_la_E3.aiff": [0,{"jp":["@sound",194],"us":["@sound",215],"eu":["@sound",215]}], +"sound/samples/instruments/00_banjo_D2.aiff": [0,{"jp":["@sound",120],"us":["@sound",141],"eu":["@sound",141],"sh":["@sound",141],"cn":["@sound",141]}], +"sound/samples/instruments/01_banjo_A2.aiff": [0,{"jp":["@sound",121],"us":["@sound",142],"eu":["@sound",142],"sh":["@sound",142],"cn":["@sound",142]}], +"sound/samples/instruments/02_violin_B2.aiff": [0,{"jp":["@sound",122],"us":["@sound",143],"eu":["@sound",143],"sh":["@sound",143],"cn":["@sound",143]}], +"sound/samples/instruments/03_human_whistle_C3.aiff": [0,{"jp":["@sound",123],"us":["@sound",144],"eu":["@sound",144],"sh":["@sound",144],"cn":["@sound",144]}], +"sound/samples/instruments/04_bright_piano_G#3.aiff": [0,{"jp":["@sound",124],"us":["@sound",145],"eu":["@sound",145],"sh":["@sound",145],"cn":["@sound",145]}], +"sound/samples/instruments/05_acoustic_bass_A1.aiff": [0,{"jp":["@sound",125],"us":["@sound",146],"eu":["@sound",146],"sh":["@sound",146],"cn":["@sound",146]}], +"sound/samples/instruments/06_kick_drum_1.aiff": [0,{"jp":["@sound",126],"us":["@sound",147],"eu":["@sound",147],"sh":["@sound",147],"cn":["@sound",147]}], +"sound/samples/instruments/07_rimshot.aiff": [0,{"jp":["@sound",127],"us":["@sound",148],"eu":["@sound",148],"sh":["@sound",148],"cn":["@sound",148]}], +"sound/samples/instruments/08.aiff": [0,{"jp":["@sound",128],"us":["@sound",149],"eu":["@sound",149],"sh":["@sound",149],"cn":["@sound",149]}], +"sound/samples/instruments/09.aiff": [0,{"jp":["@sound",129],"us":["@sound",150],"eu":["@sound",150],"sh":["@sound",150],"cn":["@sound",150]}], +"sound/samples/instruments/0A_tambourine.aiff": [0,{"jp":["@sound",130],"us":["@sound",151],"eu":["@sound",151],"sh":["@sound",151],"cn":["@sound",151]}], +"sound/samples/instruments/0B.aiff": [0,{"jp":["@sound",131],"us":["@sound",152],"eu":["@sound",152],"sh":["@sound",152],"cn":["@sound",152]}], +"sound/samples/instruments/0C_conga_stick.aiff": [0,{"jp":["@sound",132],"us":["@sound",153],"eu":["@sound",153],"sh":["@sound",153],"cn":["@sound",153]}], +"sound/samples/instruments/0D_clave.aiff": [0,{"jp":["@sound",133],"us":["@sound",154],"eu":["@sound",154],"sh":["@sound",154],"cn":["@sound",154]}], +"sound/samples/instruments/0E_hihat_closed.aiff": [0,{"jp":["@sound",134],"us":["@sound",155],"eu":["@sound",155],"sh":["@sound",155],"cn":["@sound",155]}], +"sound/samples/instruments/0F_hihat_open.aiff": [0,{"jp":["@sound",135],"us":["@sound",156],"eu":["@sound",156],"sh":["@sound",156],"cn":["@sound",156]}], +"sound/samples/instruments/10_cymbal_bell.aiff": [0,{"jp":["@sound",136],"us":["@sound",157],"eu":["@sound",157],"sh":["@sound",157],"cn":["@sound",157]}], +"sound/samples/instruments/11_splash_cymbal.aiff": [0,{"jp":["@sound",137],"us":["@sound",158],"eu":["@sound",158],"sh":["@sound",158],"cn":["@sound",158]}], +"sound/samples/instruments/12_snare_drum_1.aiff": [0,{"jp":["@sound",138],"us":["@sound",159],"eu":["@sound",159],"sh":["@sound",159],"cn":["@sound",159]}], +"sound/samples/instruments/13_snare_drum_2.aiff": [0,{"jp":["@sound",139],"us":["@sound",160],"eu":["@sound",160],"sh":["@sound",160],"cn":["@sound",160]}], +"sound/samples/instruments/14_strings_Eb2.aiff": [0,{"jp":["@sound",140],"us":["@sound",161],"eu":["@sound",161],"sh":["@sound",161],"cn":["@sound",161]}], +"sound/samples/instruments/15_strings_B3.aiff": [0,{"jp":["@sound",141],"us":["@sound",162],"eu":["@sound",162],"sh":["@sound",162],"cn":["@sound",162]}], +"sound/samples/instruments/16_french_horns_C3.aiff": [0,{"jp":["@sound",142],"us":["@sound",163],"eu":["@sound",163],"sh":["@sound",163],"cn":["@sound",163]}], +"sound/samples/instruments/17_trumpet_C#3.aiff": [0,{"jp":["@sound",143],"us":["@sound",164],"eu":["@sound",164],"sh":["@sound",164],"cn":["@sound",164]}], +"sound/samples/instruments/18_timpani.aiff": [0,{"jp":["@sound",144],"us":["@sound",165],"eu":["@sound",165],"sh":["@sound",165],"cn":["@sound",165]}], +"sound/samples/instruments/19_brass_Eb3.aiff": [0,{"jp":["@sound",145],"us":["@sound",166],"eu":["@sound",166],"sh":["@sound",166],"cn":["@sound",166]}], +"sound/samples/instruments/1A_slap_bass_G#2.aiff": [0,{"jp":["@sound",146],"us":["@sound",167],"eu":["@sound",167],"sh":["@sound",167],"cn":["@sound",167]}], +"sound/samples/instruments/1B_percussive_synth_Eb3.aiff": [0,{"jp":["@sound",147],"us":["@sound",168],"eu":["@sound",168],"sh":["@sound",168],"cn":["@sound",168]}], +"sound/samples/instruments/1C_les_paul_guitar_E2.aiff": [0,{"jp":["@sound",148],"us":["@sound",169],"eu":["@sound",169],"sh":["@sound",169],"cn":["@sound",169]}], +"sound/samples/instruments/1D.aiff": [0,{"jp":["@sound",149],"us":["@sound",170],"eu":["@sound",170],"sh":["@sound",170],"cn":["@sound",170]}], +"sound/samples/instruments/1E_closed_triangle.aiff": [0,{"jp":["@sound",150],"us":["@sound",171],"eu":["@sound",171],"sh":["@sound",171],"cn":["@sound",171]}], +"sound/samples/instruments/1F_open_triangle.aiff": [0,{"jp":["@sound",151],"us":["@sound",172],"eu":["@sound",172],"sh":["@sound",172],"cn":["@sound",172]}], +"sound/samples/instruments/20_cabasa.aiff": [0,{"jp":["@sound",152],"us":["@sound",173],"eu":["@sound",173],"sh":["@sound",173],"cn":["@sound",173]}], +"sound/samples/instruments/21_sine_bass_Bb2.aiff": [0,{"jp":["@sound",153],"us":["@sound",174],"eu":["@sound",174],"sh":["@sound",174],"cn":["@sound",174]}], +"sound/samples/instruments/22_boys_choir_Bb4.aiff": [0,{"jp":["@sound",154],"us":["@sound",175],"eu":["@sound",175],"sh":["@sound",175],"cn":["@sound",175]}], +"sound/samples/instruments/23_strings_Eb2.aiff": [0,{"jp":["@sound",155],"us":["@sound",176],"eu":["@sound",176],"sh":["@sound",176],"cn":["@sound",176]}], +"sound/samples/instruments/24_strings_G#2.aiff": [0,{"jp":["@sound",156],"us":["@sound",177],"eu":["@sound",177],"sh":["@sound",177],"cn":["@sound",177]}], +"sound/samples/instruments/25_strings_F#3.aiff": [0,{"jp":["@sound",157],"us":["@sound",178],"eu":["@sound",178],"sh":["@sound",178],"cn":["@sound",178]}], +"sound/samples/instruments/26_crystal_rhodes_C4.aiff": [0,{"jp":["@sound",158],"us":["@sound",179],"eu":["@sound",179],"sh":["@sound",179],"cn":["@sound",179]}], +"sound/samples/instruments/27_harpsichord_F3.aiff": [0,{"jp":["@sound",159],"us":["@sound",180],"eu":["@sound",180],"sh":["@sound",180],"cn":["@sound",180]}], +"sound/samples/instruments/28_sitar_1_A2.aiff": [0,{"jp":["@sound",160],"us":["@sound",181],"eu":["@sound",181],"sh":["@sound",181],"cn":["@sound",181]}], +"sound/samples/instruments/29_orchestra_hit_C3.aiff": [0,{"jp":["@sound",161],"us":["@sound",182],"eu":["@sound",182],"sh":["@sound",182],"cn":["@sound",182]}], +"sound/samples/instruments/2A_tabla_riff_1.aiff": [0,{"jp":["@sound",162],"us":["@sound",183],"eu":["@sound",183],"sh":["@sound",183],"cn":["@sound",183]}], +"sound/samples/instruments/2B_tabla_riff_2.aiff": [0,{"jp":["@sound",163],"us":["@sound",184],"eu":["@sound",184],"sh":["@sound",184],"cn":["@sound",184]}], +"sound/samples/instruments/2C_tabla_riff_3.aiff": [0,{"jp":["@sound",164],"us":["@sound",185],"eu":["@sound",185],"sh":["@sound",185],"cn":["@sound",185]}], +"sound/samples/instruments/2D_trombone_Bb2.aiff": [0,{"jp":["@sound",165],"us":["@sound",186],"eu":["@sound",186],"sh":["@sound",186],"cn":["@sound",186]}], +"sound/samples/instruments/2E_accordion_C4.aiff": [0,{"jp":["@sound",166],"us":["@sound",187],"eu":["@sound",187],"sh":["@sound",187],"cn":["@sound",187]}], +"sound/samples/instruments/2F_sleigh_bells.aiff": [0,{"jp":["@sound",167],"us":["@sound",188],"eu":["@sound",188],"sh":["@sound",188],"cn":["@sound",188]}], +"sound/samples/instruments/30_rarefaction-lahna_E4.aiff": [0,{"jp":["@sound",168],"us":["@sound",189],"eu":["@sound",189],"sh":["@sound",189],"cn":["@sound",189]}], +"sound/samples/instruments/31_rarefaction-convolution_Eb2.aiff": [0,{"jp":["@sound",169],"us":["@sound",190],"eu":["@sound",190],"sh":["@sound",190],"cn":["@sound",190]}], +"sound/samples/instruments/32_metal_rimshot.aiff": [0,{"jp":["@sound",170],"us":["@sound",191],"eu":["@sound",191],"sh":["@sound",191],"cn":["@sound",191]}], +"sound/samples/instruments/33_kick_drum_2.aiff": [0,{"jp":["@sound",171],"us":["@sound",192],"eu":["@sound",192],"sh":["@sound",192],"cn":["@sound",192]}], +"sound/samples/instruments/34_alto_flute_A4.aiff": [0,{"jp":["@sound",172],"us":["@sound",193],"eu":["@sound",193],"sh":["@sound",193],"cn":["@sound",193]}], +"sound/samples/instruments/34b_organ_C3.aiff": [0,{"sh":["@sound",194],"cn":["@sound",194]}], +"sound/samples/instruments/34c_organ_C4.aiff": [0,{"sh":["@sound",195],"cn":["@sound",195]}], +"sound/samples/instruments/35_gospel_organ_F4.aiff": [0,{"jp":["@sound",173],"us":["@sound",194],"eu":["@sound",194],"sh":["@sound",196],"cn":["@sound",196]}], +"sound/samples/instruments/36_sawtooth_synth_Eb1.aiff": [0,{"jp":["@sound",174],"us":["@sound",195],"eu":["@sound",195],"sh":["@sound",197],"cn":["@sound",197]}], +"sound/samples/instruments/37_square_synth_C5.aiff": [0,{"jp":["@sound",175],"us":["@sound",196],"eu":["@sound",196],"sh":["@sound",198],"cn":["@sound",198]}], +"sound/samples/instruments/38_electric_kick_drum.aiff": [0,{"jp":["@sound",176],"us":["@sound",197],"eu":["@sound",197],"sh":["@sound",199],"cn":["@sound",199]}], +"sound/samples/instruments/39_sitar_2_C#3.aiff": [0,{"jp":["@sound",177],"us":["@sound",198],"eu":["@sound",198],"sh":["@sound",200],"cn":["@sound",200]}], +"sound/samples/instruments/3A_music_box_C5.aiff": [0,{"jp":["@sound",178],"us":["@sound",199],"eu":["@sound",199],"sh":["@sound",201],"cn":["@sound",201]}], +"sound/samples/instruments/3B_acoustic_guitar_A1.aiff": [0,{"jp":["@sound",179],"us":["@sound",200],"eu":["@sound",200],"sh":["@sound",202],"cn":["@sound",202]}], +"sound/samples/instruments/3C_acoustic_guitar_E3.aiff": [0,{"jp":["@sound",180],"us":["@sound",201],"eu":["@sound",201],"sh":["@sound",203],"cn":["@sound",203]}], +"sound/samples/instruments/3D_acoustic_guitar_B6.aiff": [0,{"jp":["@sound",181],"us":["@sound",202],"eu":["@sound",202],"sh":["@sound",204],"cn":["@sound",204]}], +"sound/samples/instruments/3E_monk_choir_B2.aiff": [0,{"jp":["@sound",182],"us":["@sound",203],"eu":["@sound",203],"sh":["@sound",205],"cn":["@sound",205]}], +"sound/samples/instruments/3F_small_gamelan.aiff": [0,{"jp":["@sound",183],"us":["@sound",204],"eu":["@sound",204],"sh":["@sound",206],"cn":["@sound",206]}], +"sound/samples/instruments/40_fu_yin_gong_C4.aiff": [0,{"jp":["@sound",184],"us":["@sound",205],"eu":["@sound",205],"sh":["@sound",207],"cn":["@sound",207]}], +"sound/samples/instruments/41_pan_flute_C3.aiff": [0,{"jp":["@sound",185],"us":["@sound",206],"eu":["@sound",206],"sh":["@sound",208],"cn":["@sound",208]}], +"sound/samples/instruments/42_vibraphone_F#4.aiff": [0,{"jp":["@sound",186],"us":["@sound",207],"eu":["@sound",207],"sh":["@sound",209],"cn":["@sound",209]}], +"sound/samples/instruments/43_harmonica_C4.aiff": [0,{"jp":["@sound",187],"us":["@sound",208],"eu":["@sound",208],"sh":["@sound",210],"cn":["@sound",210]}], +"sound/samples/instruments/44_grand_piano_F#5.aiff": [0,{"jp":["@sound",188],"us":["@sound",209],"eu":["@sound",209],"sh":["@sound",211],"cn":["@sound",211]}], +"sound/samples/instruments/45_french_horns_C4.aiff": [0,{"jp":["@sound",189],"us":["@sound",210],"eu":["@sound",210],"sh":["@sound",212],"cn":["@sound",212]}], +"sound/samples/instruments/45b_la_E3.aiff": [0,{"sh":["@sound",213],"cn":["@sound",213]}], +"sound/samples/instruments/46_pizzicato_strings_Bb2.aiff": [0,{"jp":["@sound",190],"us":["@sound",211],"eu":["@sound",211],"sh":["@sound",214],"cn":["@sound",214]}], +"sound/samples/instruments/47_pizzicato_strings_Bb3.aiff": [0,{"jp":["@sound",191],"us":["@sound",212],"eu":["@sound",212],"sh":["@sound",215],"cn":["@sound",215]}], +"sound/samples/instruments/48_steel_drum_C#3.aiff": [0,{"jp":["@sound",192],"us":["@sound",213],"eu":["@sound",213],"sh":["@sound",216],"cn":["@sound",216]}], +"sound/samples/piranha_music_box/00_music_box_C5.aiff": [0,{"jp":["@sound",193],"us":["@sound",214],"eu":["@sound",214]}], +"sound/samples/sfx_1/00_twirl.aiff": [0,{"jp":["@sound",0],"us":["@sound",0],"eu":["@sound",0],"sh":["@sound",0],"cn":["@sound",0]}], +"sound/samples/sfx_1/01_brushing.aiff": [0,{"jp":["@sound",1],"us":["@sound",1],"eu":["@sound",1],"sh":["@sound",1],"cn":["@sound",1]}], +"sound/samples/sfx_1/02_hand_touch.aiff": [0,{"jp":["@sound",2],"us":["@sound",2],"eu":["@sound",2],"sh":["@sound",2],"cn":["@sound",2]}], +"sound/samples/sfx_1/03_yoshi.aiff": [0,{"jp":["@sound",3],"us":["@sound",3],"eu":["@sound",3],"sh":["@sound",3],"cn":["@sound",3]}], +"sound/samples/sfx_1/04_plop.aiff": [0,{"jp":["@sound",4],"us":["@sound",4],"eu":["@sound",4],"sh":["@sound",4],"cn":["@sound",4]}], +"sound/samples/sfx_1/05_heavy_landing.aiff": [0,{"jp":["@sound",5],"us":["@sound",5],"eu":["@sound",5],"sh":["@sound",5],"cn":["@sound",5]}], +"sound/samples/sfx_4/00.aiff": [0,{"jp":["@sound",17],"us":["@sound",17],"eu":["@sound",17],"sh":["@sound",17],"cn":["@sound",17]}], +"sound/samples/sfx_4/01.aiff": [0,{"jp":["@sound",18],"us":["@sound",18],"eu":["@sound",18],"sh":["@sound",18],"cn":["@sound",18]}], +"sound/samples/sfx_4/02.aiff": [0,{"jp":["@sound",19],"us":["@sound",19],"eu":["@sound",19],"sh":["@sound",19],"cn":["@sound",19]}], +"sound/samples/sfx_4/03.aiff": [0,{"jp":["@sound",20],"us":["@sound",20],"eu":["@sound",20],"sh":["@sound",20],"cn":["@sound",20]}], +"sound/samples/sfx_4/04.aiff": [0,{"jp":["@sound",21],"us":["@sound",21],"eu":["@sound",21],"sh":["@sound",21],"cn":["@sound",21]}], +"sound/samples/sfx_4/05.aiff": [0,{"jp":["@sound",22],"us":["@sound",22],"eu":["@sound",22],"sh":["@sound",22],"cn":["@sound",22]}], +"sound/samples/sfx_4/06.aiff": [0,{"jp":["@sound",23],"us":["@sound",23],"eu":["@sound",23],"sh":["@sound",23],"cn":["@sound",23]}], +"sound/samples/sfx_4/07.aiff": [0,{"jp":["@sound",24],"us":["@sound",24],"eu":["@sound",24],"sh":["@sound",24],"cn":["@sound",24]}], +"sound/samples/sfx_4/08.aiff": [0,{"jp":["@sound",25],"us":["@sound",25],"eu":["@sound",25],"sh":["@sound",25],"cn":["@sound",25]}], +"sound/samples/sfx_4/09.aiff": [0,{"jp":["@sound",26],"us":["@sound",26],"eu":["@sound",26],"sh":["@sound",26],"cn":["@sound",26]}], +"sound/samples/sfx_5/00.aiff": [0,{"jp":["@sound",27],"us":["@sound",27],"eu":["@sound",27],"sh":["@sound",27],"cn":["@sound",27]}], +"sound/samples/sfx_5/01.aiff": [0,{"jp":["@sound",28],"us":["@sound",28],"eu":["@sound",28],"sh":["@sound",28],"cn":["@sound",28]}], +"sound/samples/sfx_5/02.aiff": [0,{"jp":["@sound",29],"us":["@sound",29],"eu":["@sound",29],"sh":["@sound",29],"cn":["@sound",29]}], +"sound/samples/sfx_5/03.aiff": [0,{"jp":["@sound",30],"us":["@sound",30],"eu":["@sound",30],"sh":["@sound",30],"cn":["@sound",30]}], +"sound/samples/sfx_5/04.aiff": [0,{"jp":["@sound",31],"us":["@sound",31],"eu":["@sound",31],"sh":["@sound",31],"cn":["@sound",31]}], +"sound/samples/sfx_5/05.aiff": [0,{"jp":["@sound",32],"us":["@sound",32],"eu":["@sound",32],"sh":["@sound",32],"cn":["@sound",32]}], +"sound/samples/sfx_5/06.aiff": [0,{"jp":["@sound",33],"us":["@sound",33],"eu":["@sound",33],"sh":["@sound",33],"cn":["@sound",33]}], +"sound/samples/sfx_5/07.aiff": [0,{"jp":["@sound",34],"us":["@sound",34],"eu":["@sound",34],"sh":["@sound",34],"cn":["@sound",34]}], +"sound/samples/sfx_5/08.aiff": [0,{"jp":["@sound",35],"us":["@sound",35],"eu":["@sound",35],"sh":["@sound",35],"cn":["@sound",35]}], +"sound/samples/sfx_5/09.aiff": [0,{"jp":["@sound",36],"us":["@sound",36],"eu":["@sound",36],"sh":["@sound",36],"cn":["@sound",36]}], +"sound/samples/sfx_5/0A.aiff": [0,{"jp":["@sound",37],"us":["@sound",37],"eu":["@sound",37],"sh":["@sound",37],"cn":["@sound",37]}], +"sound/samples/sfx_5/0B.aiff": [0,{"jp":["@sound",38],"us":["@sound",38],"eu":["@sound",38],"sh":["@sound",38],"cn":["@sound",38]}], +"sound/samples/sfx_5/0C.aiff": [0,{"jp":["@sound",39],"us":["@sound",39],"eu":["@sound",39],"sh":["@sound",39],"cn":["@sound",39]}], +"sound/samples/sfx_5/0D.aiff": [0,{"jp":["@sound",40],"us":["@sound",40],"eu":["@sound",40],"sh":["@sound",40],"cn":["@sound",40]}], +"sound/samples/sfx_5/0E.aiff": [0,{"jp":["@sound",41],"us":["@sound",41],"eu":["@sound",41],"sh":["@sound",41],"cn":["@sound",41]}], +"sound/samples/sfx_5/0F.aiff": [0,{"jp":["@sound",42],"us":["@sound",42],"eu":["@sound",42],"sh":["@sound",42],"cn":["@sound",42]}], +"sound/samples/sfx_5/10.aiff": [0,{"jp":["@sound",43],"us":["@sound",43],"eu":["@sound",43],"sh":["@sound",43],"cn":["@sound",43]}], +"sound/samples/sfx_5/11.aiff": [0,{"jp":["@sound",44],"us":["@sound",44],"eu":["@sound",44],"sh":["@sound",44],"cn":["@sound",44]}], +"sound/samples/sfx_5/12.aiff": [0,{"jp":["@sound",45],"us":["@sound",45],"eu":["@sound",45],"sh":["@sound",45],"cn":["@sound",45]}], +"sound/samples/sfx_5/13.aiff": [0,{"jp":["@sound",46],"us":["@sound",46],"eu":["@sound",46],"sh":["@sound",46],"cn":["@sound",46]}], +"sound/samples/sfx_5/14.aiff": [0,{"jp":["@sound",47],"us":["@sound",47],"eu":["@sound",47],"sh":["@sound",47],"cn":["@sound",47]}], +"sound/samples/sfx_5/15.aiff": [0,{"jp":["@sound",48],"us":["@sound",48],"eu":["@sound",48],"sh":["@sound",48],"cn":["@sound",48]}], +"sound/samples/sfx_5/16.aiff": [0,{"jp":["@sound",49],"us":["@sound",49],"eu":["@sound",49],"sh":["@sound",49],"cn":["@sound",49]}], +"sound/samples/sfx_5/17.aiff": [0,{"jp":["@sound",50],"us":["@sound",50],"eu":["@sound",50],"sh":["@sound",50],"cn":["@sound",50]}], +"sound/samples/sfx_5/18.aiff": [0,{"jp":["@sound",51],"us":["@sound",51],"eu":["@sound",51],"sh":["@sound",51],"cn":["@sound",51]}], +"sound/samples/sfx_5/19.aiff": [0,{"jp":["@sound",52],"us":["@sound",52],"eu":["@sound",52],"sh":["@sound",52],"cn":["@sound",52]}], +"sound/samples/sfx_5/1A.aiff": [0,{"jp":["@sound",53],"us":["@sound",53],"eu":["@sound",53],"sh":["@sound",53],"cn":["@sound",53]}], +"sound/samples/sfx_5/1B.aiff": [0,{"jp":["@sound",54],"us":["@sound",54],"eu":["@sound",54],"sh":["@sound",54],"cn":["@sound",54]}], +"sound/samples/sfx_5/1C.aiff": [0,{"jp":["@sound",55],"us":["@sound",55],"eu":["@sound",55],"sh":["@sound",55],"cn":["@sound",55]}], +"sound/samples/sfx_6/00.aiff": [0,{"jp":["@sound",56],"us":["@sound",56],"eu":["@sound",56],"sh":["@sound",56],"cn":["@sound",56]}], +"sound/samples/sfx_6/01.aiff": [0,{"jp":["@sound",57],"us":["@sound",57],"eu":["@sound",57],"sh":["@sound",57],"cn":["@sound",57]}], +"sound/samples/sfx_6/02.aiff": [0,{"jp":["@sound",58],"us":["@sound",58],"eu":["@sound",58],"sh":["@sound",58],"cn":["@sound",58]}], +"sound/samples/sfx_6/03.aiff": [0,{"jp":["@sound",59],"us":["@sound",59],"eu":["@sound",59],"sh":["@sound",59],"cn":["@sound",59]}], +"sound/samples/sfx_6/04.aiff": [0,{"jp":["@sound",60],"us":["@sound",60],"eu":["@sound",60],"sh":["@sound",60],"cn":["@sound",60]}], +"sound/samples/sfx_6/05.aiff": [0,{"jp":["@sound",61],"us":["@sound",61],"eu":["@sound",61],"sh":["@sound",61],"cn":["@sound",61]}], +"sound/samples/sfx_6/06.aiff": [0,{"jp":["@sound",62],"us":["@sound",62],"eu":["@sound",62],"sh":["@sound",62],"cn":["@sound",62]}], +"sound/samples/sfx_6/07.aiff": [0,{"jp":["@sound",63],"us":["@sound",63],"eu":["@sound",63],"sh":["@sound",63],"cn":["@sound",63]}], +"sound/samples/sfx_6/08.aiff": [0,{"jp":["@sound",64],"us":["@sound",64],"eu":["@sound",64],"sh":["@sound",64],"cn":["@sound",64]}], +"sound/samples/sfx_6/09.aiff": [0,{"jp":["@sound",65],"us":["@sound",65],"eu":["@sound",65],"sh":["@sound",65],"cn":["@sound",65]}], +"sound/samples/sfx_6/0A.aiff": [0,{"jp":["@sound",66],"us":["@sound",66],"eu":["@sound",66],"sh":["@sound",66],"cn":["@sound",66]}], +"sound/samples/sfx_6/0B.aiff": [0,{"jp":["@sound",67],"us":["@sound",67],"eu":["@sound",67],"sh":["@sound",67],"cn":["@sound",67]}], +"sound/samples/sfx_6/0C.aiff": [0,{"jp":["@sound",68],"us":["@sound",68],"eu":["@sound",68],"sh":["@sound",68],"cn":["@sound",68]}], +"sound/samples/sfx_6/0D.aiff": [0,{"jp":["@sound",69],"us":["@sound",69],"eu":["@sound",69],"sh":["@sound",69],"cn":["@sound",69]}], +"sound/samples/sfx_7/00.aiff": [0,{"jp":["@sound",70],"us":["@sound",70],"eu":["@sound",70],"sh":["@sound",70],"cn":["@sound",70]}], +"sound/samples/sfx_7/01.aiff": [0,{"jp":["@sound",71],"us":["@sound",71],"eu":["@sound",71],"sh":["@sound",71],"cn":["@sound",71]}], +"sound/samples/sfx_7/02.aiff": [0,{"jp":["@sound",72],"us":["@sound",72],"eu":["@sound",72],"sh":["@sound",72],"cn":["@sound",72]}], +"sound/samples/sfx_7/03.aiff": [0,{"jp":["@sound",73],"us":["@sound",73],"eu":["@sound",73],"sh":["@sound",73],"cn":["@sound",73]}], +"sound/samples/sfx_7/04.aiff": [0,{"jp":["@sound",74],"us":["@sound",74],"eu":["@sound",74],"sh":["@sound",74],"cn":["@sound",74]}], +"sound/samples/sfx_7/05.aiff": [0,{"jp":["@sound",75],"us":["@sound",75],"eu":["@sound",75],"sh":["@sound",75],"cn":["@sound",75]}], +"sound/samples/sfx_7/06.aiff": [0,{"jp":["@sound",76],"us":["@sound",76],"eu":["@sound",76],"sh":["@sound",76],"cn":["@sound",76]}], +"sound/samples/sfx_7/07.aiff": [0,{"jp":["@sound",77],"us":["@sound",77],"eu":["@sound",77],"sh":["@sound",77],"cn":["@sound",77]}], +"sound/samples/sfx_7/08.aiff": [0,{"jp":["@sound",78],"us":["@sound",78],"eu":["@sound",78],"sh":["@sound",78],"cn":["@sound",78]}], +"sound/samples/sfx_7/09.aiff": [0,{"jp":["@sound",79],"us":["@sound",79],"eu":["@sound",79],"sh":["@sound",79],"cn":["@sound",79]}], +"sound/samples/sfx_7/0A.aiff": [0,{"jp":["@sound",80],"us":["@sound",80],"eu":["@sound",80],"sh":["@sound",80],"cn":["@sound",80]}], +"sound/samples/sfx_7/0B.aiff": [0,{"jp":["@sound",81],"us":["@sound",81],"eu":["@sound",81],"sh":["@sound",81],"cn":["@sound",81]}], +"sound/samples/sfx_7/0C.aiff": [0,{"jp":["@sound",82],"us":["@sound",82],"eu":["@sound",82],"sh":["@sound",82],"cn":["@sound",82]}], +"sound/samples/sfx_7/0D_chain_chomp_bark.aiff": [0,{"us":["@sound",83],"eu":["@sound",83],"sh":["@sound",83],"cn":["@sound",83]}], +"sound/samples/sfx_9/00.aiff": [0,{"jp":["@sound",99],"us":["@sound",111],"eu":["@sound",111],"sh":["@sound",111],"cn":["@sound",111]}], +"sound/samples/sfx_9/01.aiff": [0,{"jp":["@sound",100],"us":["@sound",112],"eu":["@sound",112],"sh":["@sound",112],"cn":["@sound",112]}], +"sound/samples/sfx_9/02.aiff": [0,{"jp":["@sound",101],"us":["@sound",113],"eu":["@sound",113],"sh":["@sound",113],"cn":["@sound",113]}], +"sound/samples/sfx_9/03.aiff": [0,{"jp":["@sound",102],"us":["@sound",114],"eu":["@sound",114],"sh":["@sound",114],"cn":["@sound",114]}], +"sound/samples/sfx_9/04_camera_buzz.aiff": [0,{"jp":["@sound",103],"us":["@sound",115],"eu":["@sound",115],"sh":["@sound",115],"cn":["@sound",115]}], +"sound/samples/sfx_9/05_camera_shutter.aiff": [0,{"jp":["@sound",104],"us":["@sound",116],"eu":["@sound",116],"sh":["@sound",116],"cn":["@sound",116]}], +"sound/samples/sfx_9/06.aiff": [0,{"jp":["@sound",105],"us":["@sound",117],"eu":["@sound",117],"sh":["@sound",117],"cn":["@sound",117]}], +"sound/samples/sfx_mario/00_mario_jump_hoo.aiff": [0,{"jp":["@sound",83],"us":["@sound",84],"eu":["@sound",84],"sh":["@sound",84],"cn":["@sound",84]}], +"sound/samples/sfx_mario/01_mario_jump_wah.aiff": [0,{"jp":["@sound",84],"us":["@sound",85],"eu":["@sound",85],"sh":["@sound",85],"cn":["@sound",85]}], +"sound/samples/sfx_mario/02_mario_yah.aiff": [0,{"jp":["@sound",85],"us":["@sound",86],"eu":["@sound",86],"sh":["@sound",86],"cn":["@sound",86]}], +"sound/samples/sfx_mario/03_mario_haha.aiff": [0,{"jp":["@sound",86],"us":["@sound",87],"eu":["@sound",87],"sh":["@sound",87],"cn":["@sound",87]}], +"sound/samples/sfx_mario/04_mario_yahoo.aiff": [0,{"jp":["@sound",87],"us":["@sound",88],"eu":["@sound",88],"sh":["@sound",88],"cn":["@sound",88]}], +"sound/samples/sfx_mario/05_mario_uh.aiff": [0,{"jp":["@sound",88],"us":["@sound",89],"eu":["@sound",89],"sh":["@sound",89],"cn":["@sound",89]}], +"sound/samples/sfx_mario/06_mario_hrmm.aiff": [0,{"jp":["@sound",89],"us":["@sound",90],"eu":["@sound",90],"sh":["@sound",90],"cn":["@sound",90]}], +"sound/samples/sfx_mario/07_mario_wah2.aiff": [0,{"jp":["@sound",90],"us":["@sound",91],"eu":["@sound",91],"sh":["@sound",91],"cn":["@sound",91]}], +"sound/samples/sfx_mario/08_mario_whoa.aiff": [0,{"jp":["@sound",91],"us":["@sound",92],"eu":["@sound",92],"sh":["@sound",92],"cn":["@sound",92]}], +"sound/samples/sfx_mario/09_mario_eeuh.aiff": [0,{"jp":["@sound",92],"us":["@sound",93],"eu":["@sound",93],"sh":["@sound",93],"cn":["@sound",93]}], +"sound/samples/sfx_mario/0A_mario_attacked.aiff": [0,{"jp":["@sound",93],"us":["@sound",94],"eu":["@sound",94],"sh":["@sound",94],"cn":["@sound",94]}], +"sound/samples/sfx_mario/0B_mario_ooof.aiff": [0,{"jp":["@sound",94],"us":["@sound",95],"eu":["@sound",95],"sh":["@sound",95],"cn":["@sound",95]}], +"sound/samples/sfx_mario/0C_mario_here_we_go.aiff": [0,{"jp":["@sound",95],"us":["@sound",96],"eu":["@sound",96],"sh":["@sound",96],"cn":["@sound",96]}], +"sound/samples/sfx_mario/0D_mario_yawning.aiff": [0,{"jp":["@sound",96],"us":["@sound",97],"eu":["@sound",97],"sh":["@sound",97],"cn":["@sound",97]}], +"sound/samples/sfx_mario/0E_mario_snoring1.aiff": [0,{"jp":["@sound",97],"us":["@sound",98],"eu":["@sound",98],"sh":["@sound",98],"cn":["@sound",98]}], +"sound/samples/sfx_mario/0F_mario_snoring2.aiff": [0,{"jp":["@sound",98],"us":["@sound",99],"eu":["@sound",99],"sh":["@sound",99],"cn":["@sound",99]}], +"sound/samples/sfx_mario/10_mario_doh.aiff": [0,{"us":["@sound",100],"eu":["@sound",100],"sh":["@sound",100],"cn":["@sound",100]}], +"sound/samples/sfx_mario/11_mario_game_over.aiff": [0,{"us":["@sound",101],"eu":["@sound",101],"sh":["@sound",101],"cn":["@sound",101]}], +"sound/samples/sfx_mario/12_mario_hello.aiff": [0,{"us":["@sound",102],"eu":["@sound",102],"sh":["@sound",102],"cn":["@sound",102]}], +"sound/samples/sfx_mario/13_mario_press_start_to_play.aiff": [0,{"us":["@sound",103],"eu":["@sound",103],"sh":["@sound",103],"cn":["@sound",103]}], +"sound/samples/sfx_mario/14_mario_twirl_bounce.aiff": [0,{"us":["@sound",104],"eu":["@sound",104],"sh":["@sound",104],"cn":["@sound",104]}], +"sound/samples/sfx_mario/15_mario_snoring3.aiff": [0,{"us":["@sound",105],"eu":["@sound",105],"sh":["@sound",105],"cn":["@sound",105]}], "sound/samples/sfx_mario/16_mario_so_longa_bowser.aiff": [0,{"us":["@sound",106],"eu":["@sound",106]}], -"sound/samples/sfx_mario/16_mario_bye_bye.aiff": [0,{"sh":["@sound",106]}], -"sound/samples/sfx_mario/17_mario_ima_tired.aiff": [0,{"us":["@sound",107],"eu":["@sound",107],"sh":["@sound",107]}], -"sound/samples/sfx_mario/18_mario_waha.aiff": [0,{"us":["@sound",108],"eu":["@sound",108],"sh":["@sound",108]}], -"sound/samples/sfx_mario/19_mario_yippee.aiff": [0,{"us":["@sound",109],"eu":["@sound",109],"sh":["@sound",109]}], -"sound/samples/sfx_mario/1A_mario_lets_a_go.aiff": [0,{"us":["@sound",110],"eu":["@sound",110],"sh":["@sound",110]}], -"sound/samples/sfx_mario_peach/00_mario_waaaooow.aiff": [0,{"jp":["@sound",106],"us":["@sound",118],"eu":["@sound",118],"sh":["@sound",118]}], -"sound/samples/sfx_mario_peach/01_mario_hoohoo.aiff": [0,{"jp":["@sound",107],"us":["@sound",119],"eu":["@sound",119],"sh":["@sound",119]}], -"sound/samples/sfx_mario_peach/02_mario_panting.aiff": [0,{"jp":["@sound",108],"us":["@sound",120],"eu":["@sound",120],"sh":["@sound",120]}], -"sound/samples/sfx_mario_peach/03_mario_dying.aiff": [0,{"jp":["@sound",109],"us":["@sound",121],"eu":["@sound",121],"sh":["@sound",121]}], -"sound/samples/sfx_mario_peach/04_mario_on_fire.aiff": [0,{"jp":["@sound",110],"us":["@sound",122],"eu":["@sound",122],"sh":["@sound",122]}], -"sound/samples/sfx_mario_peach/05_mario_uh2.aiff": [0,{"jp":["@sound",111],"us":["@sound",123],"eu":["@sound",123],"sh":["@sound",123]}], -"sound/samples/sfx_mario_peach/06_mario_coughing.aiff": [0,{"jp":["@sound",112],"us":["@sound",124],"eu":["@sound",124],"sh":["@sound",124]}], -"sound/samples/sfx_mario_peach/07_mario_its_a_me_mario.aiff": [0,{"jp":["@sound",113],"us":["@sound",125],"eu":["@sound",125],"sh":["@sound",125]}], -"sound/samples/sfx_mario_peach/08_mario_punch_yah.aiff": [0,{"jp":["@sound",114],"us":["@sound",126],"eu":["@sound",126],"sh":["@sound",126]}], -"sound/samples/sfx_mario_peach/09_mario_punch_hoo.aiff": [0,{"jp":["@sound",115],"us":["@sound",127],"eu":["@sound",127],"sh":["@sound",127]}], -"sound/samples/sfx_mario_peach/0A_mario_mama_mia.aiff": [0,{"jp":["@sound",116],"us":["@sound",128],"eu":["@sound",128],"sh":["@sound",128]}], -"sound/samples/sfx_mario_peach/0B_mario_okey_dokey.aiff": [0,{"jp":["@sound",117],"us":["@sound",129],"eu":["@sound",129],"sh":["@sound",129]}], -"sound/samples/sfx_mario_peach/0C_mario_drowning.aiff": [0,{"jp":["@sound",118],"us":["@sound",130],"eu":["@sound",130],"sh":["@sound",130]}], -"sound/samples/sfx_mario_peach/0D_mario_thank_you_playing_my_game.aiff": [0,{"jp":["@sound",119],"us":["@sound",131],"eu":["@sound",131],"sh":["@sound",131]}], -"sound/samples/sfx_mario_peach/0E_peach_dear_mario.aiff": [0,{"us":["@sound",132],"eu":["@sound",132],"sh":["@sound",132]}], -"sound/samples/sfx_mario_peach/0F_peach_mario.aiff": [0,{"us":["@sound",133],"eu":["@sound",133],"sh":["@sound",133]}], -"sound/samples/sfx_mario_peach/10_peach_power_of_the_stars.aiff": [0,{"us":["@sound",134],"eu":["@sound",134],"sh":["@sound",134]}], -"sound/samples/sfx_mario_peach/11_peach_thanks_to_you.aiff": [0,{"us":["@sound",135],"eu":["@sound",135],"sh":["@sound",135]}], -"sound/samples/sfx_mario_peach/12_peach_thank_you_mario.aiff": [0,{"us":["@sound",136],"eu":["@sound",136],"sh":["@sound",136]}], -"sound/samples/sfx_mario_peach/13_peach_something_special.aiff": [0,{"us":["@sound",137],"eu":["@sound",137],"sh":["@sound",137]}], -"sound/samples/sfx_mario_peach/14_peach_bake_a_cake.aiff": [0,{"us":["@sound",138],"eu":["@sound",138],"sh":["@sound",138]}], -"sound/samples/sfx_mario_peach/15_peach_for_mario.aiff": [0,{"us":["@sound",139],"eu":["@sound",139],"sh":["@sound",139]}], -"sound/samples/sfx_mario_peach/16_peach_mario2.aiff": [0,{"us":["@sound",140],"eu":["@sound",140],"sh":["@sound",140]}], -"sound/samples/sfx_terrain/00_step_default.aiff": [0,{"jp":["@sound",6],"us":["@sound",6],"eu":["@sound",6],"sh":["@sound",6]}], -"sound/samples/sfx_terrain/01_step_grass.aiff": [0,{"jp":["@sound",7],"us":["@sound",7],"eu":["@sound",7],"sh":["@sound",7]}], -"sound/samples/sfx_terrain/02_step_stone.aiff": [0,{"jp":["@sound",8],"us":["@sound",8],"eu":["@sound",8],"sh":["@sound",8]}], -"sound/samples/sfx_terrain/03_step_spooky.aiff": [0,{"jp":["@sound",9],"us":["@sound",9],"eu":["@sound",9],"sh":["@sound",9]}], -"sound/samples/sfx_terrain/04_step_snow.aiff": [0,{"jp":["@sound",10],"us":["@sound",10],"eu":["@sound",10],"sh":["@sound",10]}], -"sound/samples/sfx_terrain/05_step_ice.aiff": [0,{"jp":["@sound",11],"us":["@sound",11],"eu":["@sound",11],"sh":["@sound",11]}], -"sound/samples/sfx_terrain/06_step_metal.aiff": [0,{"jp":["@sound",12],"us":["@sound",12],"eu":["@sound",12],"sh":["@sound",12]}], -"sound/samples/sfx_terrain/07_step_sand.aiff": [0,{"jp":["@sound",13],"us":["@sound",13],"eu":["@sound",13],"sh":["@sound",13]}], -"sound/samples/sfx_water/00_plunge.aiff": [0,{"jp":["@sound",14],"us":["@sound",14],"eu":["@sound",14],"sh":["@sound",14]}], -"sound/samples/sfx_water/01_splash.aiff": [0,{"jp":["@sound",15],"us":["@sound",15],"eu":["@sound",15],"sh":["@sound",15]}], -"sound/samples/sfx_water/02_swim.aiff": [0,{"jp":["@sound",16],"us":["@sound",16],"eu":["@sound",16],"sh":["@sound",16]}] +"sound/samples/sfx_mario/16_mario_bye_bye.aiff": [0,{"sh":["@sound",106],"cn":["@sound",106]}], +"sound/samples/sfx_mario/17_mario_ima_tired.aiff": [0,{"us":["@sound",107],"eu":["@sound",107],"sh":["@sound",107],"cn":["@sound",107]}], +"sound/samples/sfx_mario/18_mario_waha.aiff": [0,{"us":["@sound",108],"eu":["@sound",108],"sh":["@sound",108],"cn":["@sound",108]}], +"sound/samples/sfx_mario/19_mario_yippee.aiff": [0,{"us":["@sound",109],"eu":["@sound",109],"sh":["@sound",109],"cn":["@sound",109]}], +"sound/samples/sfx_mario/1A_mario_lets_a_go.aiff": [0,{"us":["@sound",110],"eu":["@sound",110],"sh":["@sound",110],"cn":["@sound",110]}], +"sound/samples/sfx_mario_peach/00_mario_waaaooow.aiff": [0,{"jp":["@sound",106],"us":["@sound",118],"eu":["@sound",118],"sh":["@sound",118],"cn":["@sound",118]}], +"sound/samples/sfx_mario_peach/01_mario_hoohoo.aiff": [0,{"jp":["@sound",107],"us":["@sound",119],"eu":["@sound",119],"sh":["@sound",119],"cn":["@sound",119]}], +"sound/samples/sfx_mario_peach/02_mario_panting.aiff": [0,{"jp":["@sound",108],"us":["@sound",120],"eu":["@sound",120],"sh":["@sound",120],"cn":["@sound",120]}], +"sound/samples/sfx_mario_peach/03_mario_dying.aiff": [0,{"jp":["@sound",109],"us":["@sound",121],"eu":["@sound",121],"sh":["@sound",121],"cn":["@sound",121]}], +"sound/samples/sfx_mario_peach/04_mario_on_fire.aiff": [0,{"jp":["@sound",110],"us":["@sound",122],"eu":["@sound",122],"sh":["@sound",122],"cn":["@sound",122]}], +"sound/samples/sfx_mario_peach/05_mario_uh2.aiff": [0,{"jp":["@sound",111],"us":["@sound",123],"eu":["@sound",123],"sh":["@sound",123],"cn":["@sound",123]}], +"sound/samples/sfx_mario_peach/06_mario_coughing.aiff": [0,{"jp":["@sound",112],"us":["@sound",124],"eu":["@sound",124],"sh":["@sound",124],"cn":["@sound",124]}], +"sound/samples/sfx_mario_peach/07_mario_its_a_me_mario.aiff": [0,{"jp":["@sound",113],"us":["@sound",125],"eu":["@sound",125],"sh":["@sound",125],"cn":["@sound",125]}], +"sound/samples/sfx_mario_peach/08_mario_punch_yah.aiff": [0,{"jp":["@sound",114],"us":["@sound",126],"eu":["@sound",126],"sh":["@sound",126],"cn":["@sound",126]}], +"sound/samples/sfx_mario_peach/09_mario_punch_hoo.aiff": [0,{"jp":["@sound",115],"us":["@sound",127],"eu":["@sound",127],"sh":["@sound",127],"cn":["@sound",127]}], +"sound/samples/sfx_mario_peach/0A_mario_mama_mia.aiff": [0,{"jp":["@sound",116],"us":["@sound",128],"eu":["@sound",128],"sh":["@sound",128],"cn":["@sound",128]}], +"sound/samples/sfx_mario_peach/0B_mario_okey_dokey.aiff": [0,{"jp":["@sound",117],"us":["@sound",129],"eu":["@sound",129],"sh":["@sound",129],"cn":["@sound",129]}], +"sound/samples/sfx_mario_peach/0C_mario_drowning.aiff": [0,{"jp":["@sound",118],"us":["@sound",130],"eu":["@sound",130],"sh":["@sound",130],"cn":["@sound",130]}], +"sound/samples/sfx_mario_peach/0D_mario_thank_you_playing_my_game.aiff": [0,{"jp":["@sound",119],"us":["@sound",131],"eu":["@sound",131],"sh":["@sound",131],"cn":["@sound",131]}], +"sound/samples/sfx_mario_peach/0E_peach_dear_mario.aiff": [0,{"us":["@sound",132],"eu":["@sound",132],"sh":["@sound",132],"cn":["@sound",132]}], +"sound/samples/sfx_mario_peach/0F_peach_mario.aiff": [0,{"us":["@sound",133],"eu":["@sound",133],"sh":["@sound",133],"cn":["@sound",133]}], +"sound/samples/sfx_mario_peach/10_peach_power_of_the_stars.aiff": [0,{"us":["@sound",134],"eu":["@sound",134],"sh":["@sound",134],"cn":["@sound",134]}], +"sound/samples/sfx_mario_peach/11_peach_thanks_to_you.aiff": [0,{"us":["@sound",135],"eu":["@sound",135],"sh":["@sound",135],"cn":["@sound",135]}], +"sound/samples/sfx_mario_peach/12_peach_thank_you_mario.aiff": [0,{"us":["@sound",136],"eu":["@sound",136],"sh":["@sound",136],"cn":["@sound",136]}], +"sound/samples/sfx_mario_peach/13_peach_something_special.aiff": [0,{"us":["@sound",137],"eu":["@sound",137],"sh":["@sound",137],"cn":["@sound",137]}], +"sound/samples/sfx_mario_peach/14_peach_bake_a_cake.aiff": [0,{"us":["@sound",138],"eu":["@sound",138],"sh":["@sound",138],"cn":["@sound",138]}], +"sound/samples/sfx_mario_peach/15_peach_for_mario.aiff": [0,{"us":["@sound",139],"eu":["@sound",139],"sh":["@sound",139],"cn":["@sound",139]}], +"sound/samples/sfx_mario_peach/16_peach_mario2.aiff": [0,{"us":["@sound",140],"eu":["@sound",140],"sh":["@sound",140],"cn":["@sound",140]}], +"sound/samples/sfx_terrain/00_step_default.aiff": [0,{"jp":["@sound",6],"us":["@sound",6],"eu":["@sound",6],"sh":["@sound",6],"cn":["@sound",6]}], +"sound/samples/sfx_terrain/01_step_grass.aiff": [0,{"jp":["@sound",7],"us":["@sound",7],"eu":["@sound",7],"sh":["@sound",7],"cn":["@sound",7]}], +"sound/samples/sfx_terrain/02_step_stone.aiff": [0,{"jp":["@sound",8],"us":["@sound",8],"eu":["@sound",8],"sh":["@sound",8],"cn":["@sound",8]}], +"sound/samples/sfx_terrain/03_step_spooky.aiff": [0,{"jp":["@sound",9],"us":["@sound",9],"eu":["@sound",9],"sh":["@sound",9],"cn":["@sound",9]}], +"sound/samples/sfx_terrain/04_step_snow.aiff": [0,{"jp":["@sound",10],"us":["@sound",10],"eu":["@sound",10],"sh":["@sound",10],"cn":["@sound",10]}], +"sound/samples/sfx_terrain/05_step_ice.aiff": [0,{"jp":["@sound",11],"us":["@sound",11],"eu":["@sound",11],"sh":["@sound",11],"cn":["@sound",11]}], +"sound/samples/sfx_terrain/06_step_metal.aiff": [0,{"jp":["@sound",12],"us":["@sound",12],"eu":["@sound",12],"sh":["@sound",12],"cn":["@sound",12]}], +"sound/samples/sfx_terrain/07_step_sand.aiff": [0,{"jp":["@sound",13],"us":["@sound",13],"eu":["@sound",13],"sh":["@sound",13],"cn":["@sound",13]}], +"sound/samples/sfx_water/00_plunge.aiff": [0,{"jp":["@sound",14],"us":["@sound",14],"eu":["@sound",14],"sh":["@sound",14],"cn":["@sound",14]}], +"sound/samples/sfx_water/01_splash.aiff": [0,{"jp":["@sound",15],"us":["@sound",15],"eu":["@sound",15],"sh":["@sound",15],"cn":["@sound",15]}], +"sound/samples/sfx_water/02_swim.aiff": [0,{"jp":["@sound",16],"us":["@sound",16],"eu":["@sound",16],"sh":["@sound",16],"cn":["@sound",16]}] } diff --git a/assets/demo_data.json b/assets/demo_data.json index 3652b490..e723caf8 100644 --- a/assets/demo_data.json +++ b/assets/demo_data.json @@ -19,7 +19,7 @@ { "table": [ - {"demofile":"bitdw", "ifdef":["VERSION_US", "VERSION_SH"]}, + {"demofile":"bitdw", "ifdef":["VERSION_US", "VERSION_SH", "VERSION_CN"]}, /* Whomp's Fortress has the wrong size. The original entries probably manually input the sizes. */ @@ -44,6 +44,6 @@ Mario runs into the sign and aligns himself as if it were a mistake. */ {"name":"unused"}, - {"name":"bitdw", "ifdef":["VERSION_US", "VERSION_SH"]} + {"name":"bitdw", "ifdef":["VERSION_US", "VERSION_SH", "VERSION_CN"]} ] } diff --git a/bin/segment2.c b/bin/segment2.c index ea305277..7f69dc33 100644 --- a/bin/segment2.c +++ b/bin/segment2.c @@ -138,7 +138,7 @@ ALIGNED8 static const Texture texture_hud_char_U[] = { #include "textures/segment2/segment2.03C00.rgba16.inc.c" }; -#if defined(VERSION_JP) || defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_JP) || defined(VERSION_SH) ALIGNED8 static const Texture texture_hud_char_V[] = { #include "textures/segment2/segment2.03E00.rgba16.inc.c" }; @@ -158,7 +158,7 @@ ALIGNED8 static const Texture texture_hud_char_Y[] = { #include "textures/segment2/segment2.04400.rgba16.inc.c" }; -#if defined(VERSION_JP) || defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_JP) || defined(VERSION_SH) ALIGNED8 static const Texture texture_hud_char_Z[] = { #include "textures/segment2/segment2.04600.rgba16.inc.c" }; @@ -228,6 +228,504 @@ ALIGNED8 static const Texture texture_hud_char_beta_key[] = { }; #endif +#if defined(VERSION_CN) +ALIGNED8 static const Texture texture_hud_char_cn_04A00[] = { +#include "textures/segment2/segment2_cn.04A00.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_04C00[] = { +#include "textures/segment2/segment2_cn.04C00.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_04E00[] = { +#include "textures/segment2/segment2_cn.04E00.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_05000[] = { +#include "textures/segment2/segment2_cn.05000.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_05200[] = { +#include "textures/segment2/segment2_cn.05200.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_05400[] = { +#include "textures/segment2/segment2_cn.05400.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_05600[] = { +#include "textures/segment2/segment2_cn.05600.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_05800[] = { +#include "textures/segment2/segment2_cn.05800.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_05A00[] = { +#include "textures/segment2/segment2_cn.05A00.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_05C00[] = { +#include "textures/segment2/segment2_cn.05C00.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_05E00[] = { +#include "textures/segment2/segment2_cn.05E00.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_06000[] = { +#include "textures/segment2/segment2_cn.06000.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_06200[] = { +#include "textures/segment2/segment2_cn.06200.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_06400[] = { +#include "textures/segment2/segment2_cn.06400.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_06600[] = { +#include "textures/segment2/segment2_cn.06600.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_06800[] = { +#include "textures/segment2/segment2_cn.06800.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_06A00[] = { +#include "textures/segment2/segment2_cn.06A00.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_06C00[] = { +#include "textures/segment2/segment2_cn.06C00.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_06E00[] = { +#include "textures/segment2/segment2_cn.06E00.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_07000[] = { +#include "textures/segment2/segment2_cn.07000.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_07200[] = { +#include "textures/segment2/segment2_cn.07200.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_07400[] = { +#include "textures/segment2/segment2_cn.07400.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_07600[] = { +#include "textures/segment2/segment2_cn.07600.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_07800[] = { +#include "textures/segment2/segment2_cn.07800.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_07A00[] = { +#include "textures/segment2/segment2_cn.07A00.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_07C00[] = { +#include "textures/segment2/segment2_cn.07C00.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_07E00[] = { +#include "textures/segment2/segment2_cn.07E00.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_08000[] = { +#include "textures/segment2/segment2_cn.08000.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_08200[] = { +#include "textures/segment2/segment2_cn.08200.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_08400[] = { +#include "textures/segment2/segment2_cn.08400.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_08600[] = { +#include "textures/segment2/segment2_cn.08600.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_08800[] = { +#include "textures/segment2/segment2_cn.08800.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_08A00[] = { +#include "textures/segment2/segment2_cn.08A00.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_08C00[] = { +#include "textures/segment2/segment2_cn.08C00.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_08E00[] = { +#include "textures/segment2/segment2_cn.08E00.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_09000[] = { +#include "textures/segment2/segment2_cn.09000.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_09200[] = { +#include "textures/segment2/segment2_cn.09200.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_09400[] = { +#include "textures/segment2/segment2_cn.09400.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_09600[] = { +#include "textures/segment2/segment2_cn.09600.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_09800[] = { +#include "textures/segment2/segment2_cn.09800.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_09A00[] = { +#include "textures/segment2/segment2_cn.09A00.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_09C00[] = { +#include "textures/segment2/segment2_cn.09C00.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_09E00[] = { +#include "textures/segment2/segment2_cn.09E00.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_0A000[] = { +#include "textures/segment2/segment2_cn.0A000.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_0A200[] = { +#include "textures/segment2/segment2_cn.0A200.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_0A400[] = { +#include "textures/segment2/segment2_cn.0A400.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_0A600[] = { +#include "textures/segment2/segment2_cn.0A600.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_0A800[] = { +#include "textures/segment2/segment2_cn.0A800.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_0AA00[] = { +#include "textures/segment2/segment2_cn.0AA00.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_0AC00[] = { +#include "textures/segment2/segment2_cn.0AC00.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_0AE00[] = { +#include "textures/segment2/segment2_cn.0AE00.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_0B000[] = { +#include "textures/segment2/segment2_cn.0B000.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_0B200[] = { +#include "textures/segment2/segment2_cn.0B200.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_0B400[] = { +#include "textures/segment2/segment2_cn.0B400.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_0B600[] = { +#include "textures/segment2/segment2_cn.0B600.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_0B800[] = { +#include "textures/segment2/segment2_cn.0B800.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_0BA00[] = { +#include "textures/segment2/segment2_cn.0BA00.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_0BC00[] = { +#include "textures/segment2/segment2_cn.0BC00.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_0BE00[] = { +#include "textures/segment2/segment2_cn.0BE00.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_0C000[] = { +#include "textures/segment2/segment2_cn.0C000.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_0C200[] = { +#include "textures/segment2/segment2_cn.0C200.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_0C400[] = { +#include "textures/segment2/segment2_cn.0C400.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_0C600[] = { +#include "textures/segment2/segment2_cn.0C600.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_0C800[] = { +#include "textures/segment2/segment2_cn.0C800.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_0CA00[] = { +#include "textures/segment2/segment2_cn.0CA00.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_0CC00[] = { +#include "textures/segment2/segment2_cn.0CC00.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_0CE00[] = { +#include "textures/segment2/segment2_cn.0CE00.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_0D000[] = { +#include "textures/segment2/segment2_cn.0D000.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_0D200[] = { +#include "textures/segment2/segment2_cn.0D200.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_0D400[] = { +#include "textures/segment2/segment2_cn.0D400.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_0D600[] = { +#include "textures/segment2/segment2_cn.0D600.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_0D800[] = { +#include "textures/segment2/segment2_cn.0D800.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_0DA00[] = { +#include "textures/segment2/segment2_cn.0DA00.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_0DC00[] = { +#include "textures/segment2/segment2_cn.0DC00.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_0DE00[] = { +#include "textures/segment2/segment2_cn.0DE00.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_0E000[] = { +#include "textures/segment2/segment2_cn.0E000.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_0E200[] = { +#include "textures/segment2/segment2_cn.0E200.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_0E400[] = { +#include "textures/segment2/segment2_cn.0E400.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_0E600[] = { +#include "textures/segment2/segment2_cn.0E600.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_0E800[] = { +#include "textures/segment2/segment2_cn.0E800.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_0EA00[] = { +#include "textures/segment2/segment2_cn.0EA00.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_0EC00[] = { +#include "textures/segment2/segment2_cn.0EC00.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_0EE00[] = { +#include "textures/segment2/segment2_cn.0EE00.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_0F000[] = { +#include "textures/segment2/segment2_cn.0F000.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_0F200[] = { +#include "textures/segment2/segment2_cn.0F200.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_0F400[] = { +#include "textures/segment2/segment2_cn.0F400.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_0F600[] = { +#include "textures/segment2/segment2_cn.0F600.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_0F800[] = { +#include "textures/segment2/segment2_cn.0F800.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_0FA00[] = { +#include "textures/segment2/segment2_cn.0FA00.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_0FC00[] = { +#include "textures/segment2/segment2_cn.0FC00.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_0FE00[] = { +#include "textures/segment2/segment2_cn.0FE00.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_10000[] = { +#include "textures/segment2/segment2_cn.10000.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_10200[] = { +#include "textures/segment2/segment2_cn.10200.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_10400[] = { +#include "textures/segment2/segment2_cn.10400.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_10600[] = { +#include "textures/segment2/segment2_cn.10600.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_10800[] = { +#include "textures/segment2/segment2_cn.10800.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_10A00[] = { +#include "textures/segment2/segment2_cn.10A00.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_10C00[] = { +#include "textures/segment2/segment2_cn.10C00.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_10E00[] = { +#include "textures/segment2/segment2_cn.10E00.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_11000[] = { +#include "textures/segment2/segment2_cn.11000.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_11200[] = { +#include "textures/segment2/segment2_cn.11200.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_11400[] = { +#include "textures/segment2/segment2_cn.11400.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_11600[] = { +#include "textures/segment2/segment2_cn.11600.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_11800[] = { +#include "textures/segment2/segment2_cn.11800.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_11A00[] = { +#include "textures/segment2/segment2_cn.11A00.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_11C00[] = { +#include "textures/segment2/segment2_cn.11C00.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_11E00[] = { +#include "textures/segment2/segment2_cn.11E00.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_12000[] = { +#include "textures/segment2/segment2_cn.12000.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_12200[] = { +#include "textures/segment2/segment2_cn.12200.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_12400[] = { +#include "textures/segment2/segment2_cn.12400.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_12600[] = { +#include "textures/segment2/segment2_cn.12600.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_12800[] = { +#include "textures/segment2/segment2_cn.12800.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_12A00[] = { +#include "textures/segment2/segment2_cn.12A00.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_12C00[] = { +#include "textures/segment2/segment2_cn.12C00.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_12E00[] = { +#include "textures/segment2/segment2_cn.12E00.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_13000[] = { +#include "textures/segment2/segment2_cn.13000.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_13200[] = { +#include "textures/segment2/segment2_cn.13200.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_13400[] = { +#include "textures/segment2/segment2_cn.13400.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_13600[] = { +#include "textures/segment2/segment2_cn.13600.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_13800[] = { +#include "textures/segment2/segment2_cn.13800.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_13A00[] = { +#include "textures/segment2/segment2_cn.13A00.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_13C00[] = { +#include "textures/segment2/segment2_cn.13C00.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_13E00[] = { +#include "textures/segment2/segment2_cn.13E00.rgba16.inc.c" +}; + +ALIGNED8 static const Texture texture_hud_char_cn_14000[] = { +#include "textures/segment2/segment2_cn.14000.rgba16.inc.c" +}; +#endif // VERSION_CN + ALIGNED8 static const Texture texture_credits_char_3[] = { #include "textures/segment2/segment2.06200.rgba16.inc.c" }; @@ -1784,6 +2282,8616 @@ ALIGNED8 static const Texture texture_font_char_us_button_C_right[] = { }; #endif +#if defined(VERSION_CN) +ALIGNED8 static const Texture texture_font_char_cn_16800[] = { +#include "textures/segment2/segment2_cn.16800.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16810[] = { +#include "textures/segment2/segment2_cn.16810.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16820[] = { +#include "textures/segment2/segment2_cn.16820.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16830[] = { +#include "textures/segment2/segment2_cn.16830.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16840[] = { +#include "textures/segment2/segment2_cn.16840.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16850[] = { +#include "textures/segment2/segment2_cn.16850.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16860[] = { +#include "textures/segment2/segment2_cn.16860.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16870[] = { +#include "textures/segment2/segment2_cn.16870.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16880[] = { +#include "textures/segment2/segment2_cn.16880.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16890[] = { +#include "textures/segment2/segment2_cn.16890.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_168A0[] = { +#include "textures/segment2/segment2_cn.168A0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_168B0[] = { +#include "textures/segment2/segment2_cn.168B0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_168C0[] = { +#include "textures/segment2/segment2_cn.168C0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_168D0[] = { +#include "textures/segment2/segment2_cn.168D0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_168E0[] = { +#include "textures/segment2/segment2_cn.168E0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_168F0[] = { +#include "textures/segment2/segment2_cn.168F0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16900[] = { +#include "textures/segment2/segment2_cn.16900.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16910[] = { +#include "textures/segment2/segment2_cn.16910.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16920[] = { +#include "textures/segment2/segment2_cn.16920.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16930[] = { +#include "textures/segment2/segment2_cn.16930.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16940[] = { +#include "textures/segment2/segment2_cn.16940.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16950[] = { +#include "textures/segment2/segment2_cn.16950.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16960[] = { +#include "textures/segment2/segment2_cn.16960.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16970[] = { +#include "textures/segment2/segment2_cn.16970.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16980[] = { +#include "textures/segment2/segment2_cn.16980.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16990[] = { +#include "textures/segment2/segment2_cn.16990.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_169A0[] = { +#include "textures/segment2/segment2_cn.169A0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_169B0[] = { +#include "textures/segment2/segment2_cn.169B0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_169C0[] = { +#include "textures/segment2/segment2_cn.169C0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_169D0[] = { +#include "textures/segment2/segment2_cn.169D0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_169E0[] = { +#include "textures/segment2/segment2_cn.169E0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_169F0[] = { +#include "textures/segment2/segment2_cn.169F0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16A00[] = { +#include "textures/segment2/segment2_cn.16A00.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16A10[] = { +#include "textures/segment2/segment2_cn.16A10.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16A20[] = { +#include "textures/segment2/segment2_cn.16A20.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16A30[] = { +#include "textures/segment2/segment2_cn.16A30.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16A40[] = { +#include "textures/segment2/segment2_cn.16A40.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16A50[] = { +#include "textures/segment2/segment2_cn.16A50.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16A60[] = { +#include "textures/segment2/segment2_cn.16A60.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16A70[] = { +#include "textures/segment2/segment2_cn.16A70.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16A80[] = { +#include "textures/segment2/segment2_cn.16A80.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16A90[] = { +#include "textures/segment2/segment2_cn.16A90.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16AA0[] = { +#include "textures/segment2/segment2_cn.16AA0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16AB0[] = { +#include "textures/segment2/segment2_cn.16AB0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16AC0[] = { +#include "textures/segment2/segment2_cn.16AC0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16AD0[] = { +#include "textures/segment2/segment2_cn.16AD0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16AE0[] = { +#include "textures/segment2/segment2_cn.16AE0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16AF0[] = { +#include "textures/segment2/segment2_cn.16AF0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16B00[] = { +#include "textures/segment2/segment2_cn.16B00.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16B10[] = { +#include "textures/segment2/segment2_cn.16B10.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16B20[] = { +#include "textures/segment2/segment2_cn.16B20.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16B30[] = { +#include "textures/segment2/segment2_cn.16B30.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16B40[] = { +#include "textures/segment2/segment2_cn.16B40.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16B50[] = { +#include "textures/segment2/segment2_cn.16B50.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16B60[] = { +#include "textures/segment2/segment2_cn.16B60.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16B70[] = { +#include "textures/segment2/segment2_cn.16B70.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16B80[] = { +#include "textures/segment2/segment2_cn.16B80.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16B90[] = { +#include "textures/segment2/segment2_cn.16B90.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16BA0[] = { +#include "textures/segment2/segment2_cn.16BA0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16BB0[] = { +#include "textures/segment2/segment2_cn.16BB0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16BC0[] = { +#include "textures/segment2/segment2_cn.16BC0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16BD0[] = { +#include "textures/segment2/segment2_cn.16BD0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16BE0[] = { +#include "textures/segment2/segment2_cn.16BE0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16BF0[] = { +#include "textures/segment2/segment2_cn.16BF0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16C00[] = { +#include "textures/segment2/segment2_cn.16C00.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16C10[] = { +#include "textures/segment2/segment2_cn.16C10.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16C20[] = { +#include "textures/segment2/segment2_cn.16C20.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16C30[] = { +#include "textures/segment2/segment2_cn.16C30.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16C40[] = { +#include "textures/segment2/segment2_cn.16C40.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16C50[] = { +#include "textures/segment2/segment2_cn.16C50.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16C60[] = { +#include "textures/segment2/segment2_cn.16C60.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16C70[] = { +#include "textures/segment2/segment2_cn.16C70.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16C80[] = { +#include "textures/segment2/segment2_cn.16C80.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16C90[] = { +#include "textures/segment2/segment2_cn.16C90.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16CA0[] = { +#include "textures/segment2/segment2_cn.16CA0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16CB0[] = { +#include "textures/segment2/segment2_cn.16CB0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16CC0[] = { +#include "textures/segment2/segment2_cn.16CC0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16CD0[] = { +#include "textures/segment2/segment2_cn.16CD0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16CE0[] = { +#include "textures/segment2/segment2_cn.16CE0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16CF0[] = { +#include "textures/segment2/segment2_cn.16CF0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16D00[] = { +#include "textures/segment2/segment2_cn.16D00.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16D10[] = { +#include "textures/segment2/segment2_cn.16D10.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16D20[] = { +#include "textures/segment2/segment2_cn.16D20.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16D30[] = { +#include "textures/segment2/segment2_cn.16D30.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16D40[] = { +#include "textures/segment2/segment2_cn.16D40.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16D50[] = { +#include "textures/segment2/segment2_cn.16D50.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16D60[] = { +#include "textures/segment2/segment2_cn.16D60.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16D70[] = { +#include "textures/segment2/segment2_cn.16D70.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16D80[] = { +#include "textures/segment2/segment2_cn.16D80.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16D90[] = { +#include "textures/segment2/segment2_cn.16D90.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16DA0[] = { +#include "textures/segment2/segment2_cn.16DA0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16DB0[] = { +#include "textures/segment2/segment2_cn.16DB0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16DC0[] = { +#include "textures/segment2/segment2_cn.16DC0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16DD0[] = { +#include "textures/segment2/segment2_cn.16DD0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16DE0[] = { +#include "textures/segment2/segment2_cn.16DE0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16DF0[] = { +#include "textures/segment2/segment2_cn.16DF0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16E00[] = { +#include "textures/segment2/segment2_cn.16E00.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16E10[] = { +#include "textures/segment2/segment2_cn.16E10.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16E20[] = { +#include "textures/segment2/segment2_cn.16E20.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16E30[] = { +#include "textures/segment2/segment2_cn.16E30.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16E40[] = { +#include "textures/segment2/segment2_cn.16E40.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16E50[] = { +#include "textures/segment2/segment2_cn.16E50.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16E60[] = { +#include "textures/segment2/segment2_cn.16E60.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16E70[] = { +#include "textures/segment2/segment2_cn.16E70.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16E80[] = { +#include "textures/segment2/segment2_cn.16E80.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16E90[] = { +#include "textures/segment2/segment2_cn.16E90.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16EA0[] = { +#include "textures/segment2/segment2_cn.16EA0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16EB0[] = { +#include "textures/segment2/segment2_cn.16EB0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16EC0[] = { +#include "textures/segment2/segment2_cn.16EC0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16ED0[] = { +#include "textures/segment2/segment2_cn.16ED0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16EE0[] = { +#include "textures/segment2/segment2_cn.16EE0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16EF0[] = { +#include "textures/segment2/segment2_cn.16EF0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16F00[] = { +#include "textures/segment2/segment2_cn.16F00.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16F10[] = { +#include "textures/segment2/segment2_cn.16F10.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16F20[] = { +#include "textures/segment2/segment2_cn.16F20.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16F30[] = { +#include "textures/segment2/segment2_cn.16F30.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16F40[] = { +#include "textures/segment2/segment2_cn.16F40.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16F50[] = { +#include "textures/segment2/segment2_cn.16F50.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16F60[] = { +#include "textures/segment2/segment2_cn.16F60.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16F70[] = { +#include "textures/segment2/segment2_cn.16F70.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16F80[] = { +#include "textures/segment2/segment2_cn.16F80.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16F90[] = { +#include "textures/segment2/segment2_cn.16F90.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16FA0[] = { +#include "textures/segment2/segment2_cn.16FA0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16FB0[] = { +#include "textures/segment2/segment2_cn.16FB0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16FC0[] = { +#include "textures/segment2/segment2_cn.16FC0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16FD0[] = { +#include "textures/segment2/segment2_cn.16FD0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16FE0[] = { +#include "textures/segment2/segment2_cn.16FE0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_16FF0[] = { +#include "textures/segment2/segment2_cn.16FF0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17000[] = { +#include "textures/segment2/segment2_cn.17000.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17010[] = { +#include "textures/segment2/segment2_cn.17010.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17020[] = { +#include "textures/segment2/segment2_cn.17020.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17030[] = { +#include "textures/segment2/segment2_cn.17030.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17040[] = { +#include "textures/segment2/segment2_cn.17040.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17050[] = { +#include "textures/segment2/segment2_cn.17050.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17060[] = { +#include "textures/segment2/segment2_cn.17060.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17070[] = { +#include "textures/segment2/segment2_cn.17070.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17080[] = { +#include "textures/segment2/segment2_cn.17080.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17090[] = { +#include "textures/segment2/segment2_cn.17090.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_170A0[] = { +#include "textures/segment2/segment2_cn.170A0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_170B0[] = { +#include "textures/segment2/segment2_cn.170B0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_170C0[] = { +#include "textures/segment2/segment2_cn.170C0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_170D0[] = { +#include "textures/segment2/segment2_cn.170D0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_170E0[] = { +#include "textures/segment2/segment2_cn.170E0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_170F0[] = { +#include "textures/segment2/segment2_cn.170F0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17100[] = { +#include "textures/segment2/segment2_cn.17100.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17110[] = { +#include "textures/segment2/segment2_cn.17110.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17120[] = { +#include "textures/segment2/segment2_cn.17120.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17130[] = { +#include "textures/segment2/segment2_cn.17130.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17140[] = { +#include "textures/segment2/segment2_cn.17140.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17150[] = { +#include "textures/segment2/segment2_cn.17150.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17160[] = { +#include "textures/segment2/segment2_cn.17160.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17170[] = { +#include "textures/segment2/segment2_cn.17170.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17180[] = { +#include "textures/segment2/segment2_cn.17180.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17190[] = { +#include "textures/segment2/segment2_cn.17190.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_171A0[] = { +#include "textures/segment2/segment2_cn.171A0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_171B0[] = { +#include "textures/segment2/segment2_cn.171B0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_171C0[] = { +#include "textures/segment2/segment2_cn.171C0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_171D0[] = { +#include "textures/segment2/segment2_cn.171D0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_171E0[] = { +#include "textures/segment2/segment2_cn.171E0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_171F0[] = { +#include "textures/segment2/segment2_cn.171F0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17200[] = { +#include "textures/segment2/segment2_cn.17200.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17210[] = { +#include "textures/segment2/segment2_cn.17210.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17220[] = { +#include "textures/segment2/segment2_cn.17220.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17230[] = { +#include "textures/segment2/segment2_cn.17230.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17240[] = { +#include "textures/segment2/segment2_cn.17240.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17250[] = { +#include "textures/segment2/segment2_cn.17250.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17260[] = { +#include "textures/segment2/segment2_cn.17260.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17270[] = { +#include "textures/segment2/segment2_cn.17270.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17280[] = { +#include "textures/segment2/segment2_cn.17280.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17290[] = { +#include "textures/segment2/segment2_cn.17290.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_172A0[] = { +#include "textures/segment2/segment2_cn.172A0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_172B0[] = { +#include "textures/segment2/segment2_cn.172B0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_172C0[] = { +#include "textures/segment2/segment2_cn.172C0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_172D0[] = { +#include "textures/segment2/segment2_cn.172D0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_172E0[] = { +#include "textures/segment2/segment2_cn.172E0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_172F0[] = { +#include "textures/segment2/segment2_cn.172F0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17300[] = { +#include "textures/segment2/segment2_cn.17300.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17310[] = { +#include "textures/segment2/segment2_cn.17310.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17320[] = { +#include "textures/segment2/segment2_cn.17320.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17330[] = { +#include "textures/segment2/segment2_cn.17330.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17340[] = { +#include "textures/segment2/segment2_cn.17340.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17350[] = { +#include "textures/segment2/segment2_cn.17350.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17360[] = { +#include "textures/segment2/segment2_cn.17360.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17370[] = { +#include "textures/segment2/segment2_cn.17370.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17380[] = { +#include "textures/segment2/segment2_cn.17380.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17390[] = { +#include "textures/segment2/segment2_cn.17390.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_173A0[] = { +#include "textures/segment2/segment2_cn.173A0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_173B0[] = { +#include "textures/segment2/segment2_cn.173B0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_173C0[] = { +#include "textures/segment2/segment2_cn.173C0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_173D0[] = { +#include "textures/segment2/segment2_cn.173D0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_173E0[] = { +#include "textures/segment2/segment2_cn.173E0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_173F0[] = { +#include "textures/segment2/segment2_cn.173F0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17400[] = { +#include "textures/segment2/segment2_cn.17400.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17410[] = { +#include "textures/segment2/segment2_cn.17410.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17420[] = { +#include "textures/segment2/segment2_cn.17420.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17430[] = { +#include "textures/segment2/segment2_cn.17430.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17440[] = { +#include "textures/segment2/segment2_cn.17440.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17450[] = { +#include "textures/segment2/segment2_cn.17450.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17460[] = { +#include "textures/segment2/segment2_cn.17460.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17470[] = { +#include "textures/segment2/segment2_cn.17470.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17480[] = { +#include "textures/segment2/segment2_cn.17480.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17490[] = { +#include "textures/segment2/segment2_cn.17490.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_174A0[] = { +#include "textures/segment2/segment2_cn.174A0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_174B0[] = { +#include "textures/segment2/segment2_cn.174B0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_174C0[] = { +#include "textures/segment2/segment2_cn.174C0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_174D0[] = { +#include "textures/segment2/segment2_cn.174D0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_174E0[] = { +#include "textures/segment2/segment2_cn.174E0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_174F0[] = { +#include "textures/segment2/segment2_cn.174F0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17500[] = { +#include "textures/segment2/segment2_cn.17500.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17510[] = { +#include "textures/segment2/segment2_cn.17510.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17520[] = { +#include "textures/segment2/segment2_cn.17520.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17530[] = { +#include "textures/segment2/segment2_cn.17530.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17540[] = { +#include "textures/segment2/segment2_cn.17540.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17550[] = { +#include "textures/segment2/segment2_cn.17550.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17560[] = { +#include "textures/segment2/segment2_cn.17560.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17570[] = { +#include "textures/segment2/segment2_cn.17570.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17580[] = { +#include "textures/segment2/segment2_cn.17580.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17590[] = { +#include "textures/segment2/segment2_cn.17590.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_175A0[] = { +#include "textures/segment2/segment2_cn.175A0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_175B0[] = { +#include "textures/segment2/segment2_cn.175B0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_175C0[] = { +#include "textures/segment2/segment2_cn.175C0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_175D0[] = { +#include "textures/segment2/segment2_cn.175D0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_175E0[] = { +#include "textures/segment2/segment2_cn.175E0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_175F0[] = { +#include "textures/segment2/segment2_cn.175F0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17600[] = { +#include "textures/segment2/segment2_cn.17600.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17610[] = { +#include "textures/segment2/segment2_cn.17610.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17620[] = { +#include "textures/segment2/segment2_cn.17620.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17630[] = { +#include "textures/segment2/segment2_cn.17630.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17640[] = { +#include "textures/segment2/segment2_cn.17640.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17650[] = { +#include "textures/segment2/segment2_cn.17650.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17660[] = { +#include "textures/segment2/segment2_cn.17660.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17670[] = { +#include "textures/segment2/segment2_cn.17670.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17680[] = { +#include "textures/segment2/segment2_cn.17680.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17690[] = { +#include "textures/segment2/segment2_cn.17690.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_176A0[] = { +#include "textures/segment2/segment2_cn.176A0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_176B0[] = { +#include "textures/segment2/segment2_cn.176B0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_176C0[] = { +#include "textures/segment2/segment2_cn.176C0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_176D0[] = { +#include "textures/segment2/segment2_cn.176D0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_176E0[] = { +#include "textures/segment2/segment2_cn.176E0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_176F0[] = { +#include "textures/segment2/segment2_cn.176F0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17700[] = { +#include "textures/segment2/segment2_cn.17700.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17710[] = { +#include "textures/segment2/segment2_cn.17710.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17720[] = { +#include "textures/segment2/segment2_cn.17720.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17730[] = { +#include "textures/segment2/segment2_cn.17730.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17740[] = { +#include "textures/segment2/segment2_cn.17740.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17750[] = { +#include "textures/segment2/segment2_cn.17750.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17760[] = { +#include "textures/segment2/segment2_cn.17760.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17770[] = { +#include "textures/segment2/segment2_cn.17770.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17780[] = { +#include "textures/segment2/segment2_cn.17780.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17790[] = { +#include "textures/segment2/segment2_cn.17790.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_177A0[] = { +#include "textures/segment2/segment2_cn.177A0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_177B0[] = { +#include "textures/segment2/segment2_cn.177B0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_177C0[] = { +#include "textures/segment2/segment2_cn.177C0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_177D0[] = { +#include "textures/segment2/segment2_cn.177D0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_177E0[] = { +#include "textures/segment2/segment2_cn.177E0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_177F0[] = { +#include "textures/segment2/segment2_cn.177F0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17800[] = { +#include "textures/segment2/segment2_cn.17800.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17810[] = { +#include "textures/segment2/segment2_cn.17810.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17820[] = { +#include "textures/segment2/segment2_cn.17820.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17830[] = { +#include "textures/segment2/segment2_cn.17830.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17840[] = { +#include "textures/segment2/segment2_cn.17840.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17850[] = { +#include "textures/segment2/segment2_cn.17850.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17860[] = { +#include "textures/segment2/segment2_cn.17860.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17870[] = { +#include "textures/segment2/segment2_cn.17870.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17880[] = { +#include "textures/segment2/segment2_cn.17880.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17890[] = { +#include "textures/segment2/segment2_cn.17890.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_178A0[] = { +#include "textures/segment2/segment2_cn.178A0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_178B0[] = { +#include "textures/segment2/segment2_cn.178B0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_178C0[] = { +#include "textures/segment2/segment2_cn.178C0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_178D0[] = { +#include "textures/segment2/segment2_cn.178D0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_178E0[] = { +#include "textures/segment2/segment2_cn.178E0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_178F0[] = { +#include "textures/segment2/segment2_cn.178F0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17900[] = { +#include "textures/segment2/segment2_cn.17900.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17910[] = { +#include "textures/segment2/segment2_cn.17910.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17920[] = { +#include "textures/segment2/segment2_cn.17920.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17930[] = { +#include "textures/segment2/segment2_cn.17930.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17940[] = { +#include "textures/segment2/segment2_cn.17940.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17950[] = { +#include "textures/segment2/segment2_cn.17950.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17960[] = { +#include "textures/segment2/segment2_cn.17960.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17970[] = { +#include "textures/segment2/segment2_cn.17970.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17980[] = { +#include "textures/segment2/segment2_cn.17980.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17990[] = { +#include "textures/segment2/segment2_cn.17990.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_179A0[] = { +#include "textures/segment2/segment2_cn.179A0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_179B0[] = { +#include "textures/segment2/segment2_cn.179B0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_179C0[] = { +#include "textures/segment2/segment2_cn.179C0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_179D0[] = { +#include "textures/segment2/segment2_cn.179D0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_179E0[] = { +#include "textures/segment2/segment2_cn.179E0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_179F0[] = { +#include "textures/segment2/segment2_cn.179F0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17A00[] = { +#include "textures/segment2/segment2_cn.17A00.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17A10[] = { +#include "textures/segment2/segment2_cn.17A10.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17A20[] = { +#include "textures/segment2/segment2_cn.17A20.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17A30[] = { +#include "textures/segment2/segment2_cn.17A30.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17A40[] = { +#include "textures/segment2/segment2_cn.17A40.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17A50[] = { +#include "textures/segment2/segment2_cn.17A50.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17A60[] = { +#include "textures/segment2/segment2_cn.17A60.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17A70[] = { +#include "textures/segment2/segment2_cn.17A70.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17A80[] = { +#include "textures/segment2/segment2_cn.17A80.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17A90[] = { +#include "textures/segment2/segment2_cn.17A90.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17AA0[] = { +#include "textures/segment2/segment2_cn.17AA0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17AB0[] = { +#include "textures/segment2/segment2_cn.17AB0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17AC0[] = { +#include "textures/segment2/segment2_cn.17AC0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17AD0[] = { +#include "textures/segment2/segment2_cn.17AD0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17AE0[] = { +#include "textures/segment2/segment2_cn.17AE0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17AF0[] = { +#include "textures/segment2/segment2_cn.17AF0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17B00[] = { +#include "textures/segment2/segment2_cn.17B00.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17B10[] = { +#include "textures/segment2/segment2_cn.17B10.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17B20[] = { +#include "textures/segment2/segment2_cn.17B20.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17B30[] = { +#include "textures/segment2/segment2_cn.17B30.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17B40[] = { +#include "textures/segment2/segment2_cn.17B40.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17B50[] = { +#include "textures/segment2/segment2_cn.17B50.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17B60[] = { +#include "textures/segment2/segment2_cn.17B60.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17B70[] = { +#include "textures/segment2/segment2_cn.17B70.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17B80[] = { +#include "textures/segment2/segment2_cn.17B80.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17B90[] = { +#include "textures/segment2/segment2_cn.17B90.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17BA0[] = { +#include "textures/segment2/segment2_cn.17BA0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17BB0[] = { +#include "textures/segment2/segment2_cn.17BB0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17BC0[] = { +#include "textures/segment2/segment2_cn.17BC0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17BD0[] = { +#include "textures/segment2/segment2_cn.17BD0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17BE0[] = { +#include "textures/segment2/segment2_cn.17BE0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17BF0[] = { +#include "textures/segment2/segment2_cn.17BF0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17C00[] = { +#include "textures/segment2/segment2_cn.17C00.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17C10[] = { +#include "textures/segment2/segment2_cn.17C10.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17C20[] = { +#include "textures/segment2/segment2_cn.17C20.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17C30[] = { +#include "textures/segment2/segment2_cn.17C30.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17C40[] = { +#include "textures/segment2/segment2_cn.17C40.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17C50[] = { +#include "textures/segment2/segment2_cn.17C50.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17C60[] = { +#include "textures/segment2/segment2_cn.17C60.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17C70[] = { +#include "textures/segment2/segment2_cn.17C70.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17C80[] = { +#include "textures/segment2/segment2_cn.17C80.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17C90[] = { +#include "textures/segment2/segment2_cn.17C90.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17CA0[] = { +#include "textures/segment2/segment2_cn.17CA0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17CB0[] = { +#include "textures/segment2/segment2_cn.17CB0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17CC0[] = { +#include "textures/segment2/segment2_cn.17CC0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17CD0[] = { +#include "textures/segment2/segment2_cn.17CD0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17CE0[] = { +#include "textures/segment2/segment2_cn.17CE0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17CF0[] = { +#include "textures/segment2/segment2_cn.17CF0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17D00[] = { +#include "textures/segment2/segment2_cn.17D00.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17D10[] = { +#include "textures/segment2/segment2_cn.17D10.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17D20[] = { +#include "textures/segment2/segment2_cn.17D20.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17D30[] = { +#include "textures/segment2/segment2_cn.17D30.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17D40[] = { +#include "textures/segment2/segment2_cn.17D40.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17D50[] = { +#include "textures/segment2/segment2_cn.17D50.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17D60[] = { +#include "textures/segment2/segment2_cn.17D60.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17D70[] = { +#include "textures/segment2/segment2_cn.17D70.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17D80[] = { +#include "textures/segment2/segment2_cn.17D80.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17D90[] = { +#include "textures/segment2/segment2_cn.17D90.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17DA0[] = { +#include "textures/segment2/segment2_cn.17DA0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17DB0[] = { +#include "textures/segment2/segment2_cn.17DB0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17DC0[] = { +#include "textures/segment2/segment2_cn.17DC0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17DD0[] = { +#include "textures/segment2/segment2_cn.17DD0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17DE0[] = { +#include "textures/segment2/segment2_cn.17DE0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17DF0[] = { +#include "textures/segment2/segment2_cn.17DF0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17E00[] = { +#include "textures/segment2/segment2_cn.17E00.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17E10[] = { +#include "textures/segment2/segment2_cn.17E10.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17E20[] = { +#include "textures/segment2/segment2_cn.17E20.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17E30[] = { +#include "textures/segment2/segment2_cn.17E30.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17E40[] = { +#include "textures/segment2/segment2_cn.17E40.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17E50[] = { +#include "textures/segment2/segment2_cn.17E50.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17E60[] = { +#include "textures/segment2/segment2_cn.17E60.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17E70[] = { +#include "textures/segment2/segment2_cn.17E70.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17E80[] = { +#include "textures/segment2/segment2_cn.17E80.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17E90[] = { +#include "textures/segment2/segment2_cn.17E90.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17EA0[] = { +#include "textures/segment2/segment2_cn.17EA0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17EB0[] = { +#include "textures/segment2/segment2_cn.17EB0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17EC0[] = { +#include "textures/segment2/segment2_cn.17EC0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17ED0[] = { +#include "textures/segment2/segment2_cn.17ED0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17EE0[] = { +#include "textures/segment2/segment2_cn.17EE0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17EF0[] = { +#include "textures/segment2/segment2_cn.17EF0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17F00[] = { +#include "textures/segment2/segment2_cn.17F00.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17F10[] = { +#include "textures/segment2/segment2_cn.17F10.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17F20[] = { +#include "textures/segment2/segment2_cn.17F20.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17F30[] = { +#include "textures/segment2/segment2_cn.17F30.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17F40[] = { +#include "textures/segment2/segment2_cn.17F40.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17F50[] = { +#include "textures/segment2/segment2_cn.17F50.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17F60[] = { +#include "textures/segment2/segment2_cn.17F60.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17F70[] = { +#include "textures/segment2/segment2_cn.17F70.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17F80[] = { +#include "textures/segment2/segment2_cn.17F80.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17F90[] = { +#include "textures/segment2/segment2_cn.17F90.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17FA0[] = { +#include "textures/segment2/segment2_cn.17FA0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17FB0[] = { +#include "textures/segment2/segment2_cn.17FB0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17FC0[] = { +#include "textures/segment2/segment2_cn.17FC0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17FD0[] = { +#include "textures/segment2/segment2_cn.17FD0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17FE0[] = { +#include "textures/segment2/segment2_cn.17FE0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_17FF0[] = { +#include "textures/segment2/segment2_cn.17FF0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18000[] = { +#include "textures/segment2/segment2_cn.18000.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18010[] = { +#include "textures/segment2/segment2_cn.18010.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18020[] = { +#include "textures/segment2/segment2_cn.18020.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18030[] = { +#include "textures/segment2/segment2_cn.18030.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18040[] = { +#include "textures/segment2/segment2_cn.18040.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18050[] = { +#include "textures/segment2/segment2_cn.18050.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18060[] = { +#include "textures/segment2/segment2_cn.18060.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18070[] = { +#include "textures/segment2/segment2_cn.18070.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18080[] = { +#include "textures/segment2/segment2_cn.18080.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18090[] = { +#include "textures/segment2/segment2_cn.18090.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_180A0[] = { +#include "textures/segment2/segment2_cn.180A0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_180B0[] = { +#include "textures/segment2/segment2_cn.180B0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_180C0[] = { +#include "textures/segment2/segment2_cn.180C0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_180D0[] = { +#include "textures/segment2/segment2_cn.180D0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_180E0[] = { +#include "textures/segment2/segment2_cn.180E0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_180F0[] = { +#include "textures/segment2/segment2_cn.180F0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18100[] = { +#include "textures/segment2/segment2_cn.18100.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18110[] = { +#include "textures/segment2/segment2_cn.18110.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18120[] = { +#include "textures/segment2/segment2_cn.18120.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18130[] = { +#include "textures/segment2/segment2_cn.18130.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18140[] = { +#include "textures/segment2/segment2_cn.18140.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18150[] = { +#include "textures/segment2/segment2_cn.18150.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18160[] = { +#include "textures/segment2/segment2_cn.18160.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18170[] = { +#include "textures/segment2/segment2_cn.18170.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18180[] = { +#include "textures/segment2/segment2_cn.18180.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18190[] = { +#include "textures/segment2/segment2_cn.18190.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_181A0[] = { +#include "textures/segment2/segment2_cn.181A0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_181B0[] = { +#include "textures/segment2/segment2_cn.181B0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_181C0[] = { +#include "textures/segment2/segment2_cn.181C0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_181D0[] = { +#include "textures/segment2/segment2_cn.181D0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_181E0[] = { +#include "textures/segment2/segment2_cn.181E0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_181F0[] = { +#include "textures/segment2/segment2_cn.181F0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18200[] = { +#include "textures/segment2/segment2_cn.18200.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18210[] = { +#include "textures/segment2/segment2_cn.18210.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18220[] = { +#include "textures/segment2/segment2_cn.18220.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18230[] = { +#include "textures/segment2/segment2_cn.18230.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18240[] = { +#include "textures/segment2/segment2_cn.18240.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18250[] = { +#include "textures/segment2/segment2_cn.18250.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18260[] = { +#include "textures/segment2/segment2_cn.18260.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18270[] = { +#include "textures/segment2/segment2_cn.18270.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18280[] = { +#include "textures/segment2/segment2_cn.18280.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18290[] = { +#include "textures/segment2/segment2_cn.18290.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_182A0[] = { +#include "textures/segment2/segment2_cn.182A0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_182B0[] = { +#include "textures/segment2/segment2_cn.182B0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_182C0[] = { +#include "textures/segment2/segment2_cn.182C0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_182D0[] = { +#include "textures/segment2/segment2_cn.182D0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_182E0[] = { +#include "textures/segment2/segment2_cn.182E0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_182F0[] = { +#include "textures/segment2/segment2_cn.182F0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18300[] = { +#include "textures/segment2/segment2_cn.18300.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18310[] = { +#include "textures/segment2/segment2_cn.18310.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18320[] = { +#include "textures/segment2/segment2_cn.18320.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18330[] = { +#include "textures/segment2/segment2_cn.18330.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18340[] = { +#include "textures/segment2/segment2_cn.18340.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18350[] = { +#include "textures/segment2/segment2_cn.18350.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18360[] = { +#include "textures/segment2/segment2_cn.18360.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18370[] = { +#include "textures/segment2/segment2_cn.18370.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18380[] = { +#include "textures/segment2/segment2_cn.18380.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18390[] = { +#include "textures/segment2/segment2_cn.18390.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_183A0[] = { +#include "textures/segment2/segment2_cn.183A0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_183B0[] = { +#include "textures/segment2/segment2_cn.183B0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_183C0[] = { +#include "textures/segment2/segment2_cn.183C0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_183D0[] = { +#include "textures/segment2/segment2_cn.183D0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_183E0[] = { +#include "textures/segment2/segment2_cn.183E0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_183F0[] = { +#include "textures/segment2/segment2_cn.183F0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18400[] = { +#include "textures/segment2/segment2_cn.18400.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18410[] = { +#include "textures/segment2/segment2_cn.18410.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18420[] = { +#include "textures/segment2/segment2_cn.18420.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18430[] = { +#include "textures/segment2/segment2_cn.18430.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18440[] = { +#include "textures/segment2/segment2_cn.18440.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18450[] = { +#include "textures/segment2/segment2_cn.18450.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18460[] = { +#include "textures/segment2/segment2_cn.18460.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18470[] = { +#include "textures/segment2/segment2_cn.18470.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18480[] = { +#include "textures/segment2/segment2_cn.18480.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18490[] = { +#include "textures/segment2/segment2_cn.18490.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_184A0[] = { +#include "textures/segment2/segment2_cn.184A0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_184B0[] = { +#include "textures/segment2/segment2_cn.184B0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_184C0[] = { +#include "textures/segment2/segment2_cn.184C0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_184D0[] = { +#include "textures/segment2/segment2_cn.184D0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_184E0[] = { +#include "textures/segment2/segment2_cn.184E0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_184F0[] = { +#include "textures/segment2/segment2_cn.184F0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18500[] = { +#include "textures/segment2/segment2_cn.18500.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18510[] = { +#include "textures/segment2/segment2_cn.18510.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18520[] = { +#include "textures/segment2/segment2_cn.18520.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18530[] = { +#include "textures/segment2/segment2_cn.18530.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18540[] = { +#include "textures/segment2/segment2_cn.18540.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18550[] = { +#include "textures/segment2/segment2_cn.18550.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18560[] = { +#include "textures/segment2/segment2_cn.18560.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18570[] = { +#include "textures/segment2/segment2_cn.18570.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18580[] = { +#include "textures/segment2/segment2_cn.18580.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18590[] = { +#include "textures/segment2/segment2_cn.18590.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_185A0[] = { +#include "textures/segment2/segment2_cn.185A0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_185B0[] = { +#include "textures/segment2/segment2_cn.185B0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_185C0[] = { +#include "textures/segment2/segment2_cn.185C0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_185D0[] = { +#include "textures/segment2/segment2_cn.185D0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_185E0[] = { +#include "textures/segment2/segment2_cn.185E0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_185F0[] = { +#include "textures/segment2/segment2_cn.185F0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18600[] = { +#include "textures/segment2/segment2_cn.18600.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18610[] = { +#include "textures/segment2/segment2_cn.18610.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18620[] = { +#include "textures/segment2/segment2_cn.18620.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18630[] = { +#include "textures/segment2/segment2_cn.18630.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18640[] = { +#include "textures/segment2/segment2_cn.18640.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18650[] = { +#include "textures/segment2/segment2_cn.18650.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18660[] = { +#include "textures/segment2/segment2_cn.18660.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18670[] = { +#include "textures/segment2/segment2_cn.18670.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18680[] = { +#include "textures/segment2/segment2_cn.18680.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18690[] = { +#include "textures/segment2/segment2_cn.18690.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_186A0[] = { +#include "textures/segment2/segment2_cn.186A0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_186B0[] = { +#include "textures/segment2/segment2_cn.186B0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_186C0[] = { +#include "textures/segment2/segment2_cn.186C0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_186D0[] = { +#include "textures/segment2/segment2_cn.186D0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_186E0[] = { +#include "textures/segment2/segment2_cn.186E0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_186F0[] = { +#include "textures/segment2/segment2_cn.186F0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18700[] = { +#include "textures/segment2/segment2_cn.18700.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18710[] = { +#include "textures/segment2/segment2_cn.18710.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18720[] = { +#include "textures/segment2/segment2_cn.18720.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18730[] = { +#include "textures/segment2/segment2_cn.18730.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18740[] = { +#include "textures/segment2/segment2_cn.18740.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18750[] = { +#include "textures/segment2/segment2_cn.18750.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18760[] = { +#include "textures/segment2/segment2_cn.18760.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18770[] = { +#include "textures/segment2/segment2_cn.18770.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18780[] = { +#include "textures/segment2/segment2_cn.18780.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18790[] = { +#include "textures/segment2/segment2_cn.18790.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_187A0[] = { +#include "textures/segment2/segment2_cn.187A0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_187B0[] = { +#include "textures/segment2/segment2_cn.187B0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_187C0[] = { +#include "textures/segment2/segment2_cn.187C0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_187D0[] = { +#include "textures/segment2/segment2_cn.187D0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_187E0[] = { +#include "textures/segment2/segment2_cn.187E0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_187F0[] = { +#include "textures/segment2/segment2_cn.187F0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18800[] = { +#include "textures/segment2/segment2_cn.18800.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18810[] = { +#include "textures/segment2/segment2_cn.18810.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18820[] = { +#include "textures/segment2/segment2_cn.18820.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18830[] = { +#include "textures/segment2/segment2_cn.18830.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18840[] = { +#include "textures/segment2/segment2_cn.18840.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18850[] = { +#include "textures/segment2/segment2_cn.18850.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18860[] = { +#include "textures/segment2/segment2_cn.18860.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18870[] = { +#include "textures/segment2/segment2_cn.18870.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18880[] = { +#include "textures/segment2/segment2_cn.18880.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18890[] = { +#include "textures/segment2/segment2_cn.18890.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_188A0[] = { +#include "textures/segment2/segment2_cn.188A0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_188B0[] = { +#include "textures/segment2/segment2_cn.188B0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_188C0[] = { +#include "textures/segment2/segment2_cn.188C0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_188D0[] = { +#include "textures/segment2/segment2_cn.188D0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_188E0[] = { +#include "textures/segment2/segment2_cn.188E0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_188F0[] = { +#include "textures/segment2/segment2_cn.188F0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18900[] = { +#include "textures/segment2/segment2_cn.18900.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18910[] = { +#include "textures/segment2/segment2_cn.18910.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18920[] = { +#include "textures/segment2/segment2_cn.18920.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18930[] = { +#include "textures/segment2/segment2_cn.18930.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18940[] = { +#include "textures/segment2/segment2_cn.18940.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18950[] = { +#include "textures/segment2/segment2_cn.18950.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18960[] = { +#include "textures/segment2/segment2_cn.18960.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18970[] = { +#include "textures/segment2/segment2_cn.18970.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18980[] = { +#include "textures/segment2/segment2_cn.18980.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18990[] = { +#include "textures/segment2/segment2_cn.18990.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_189A0[] = { +#include "textures/segment2/segment2_cn.189A0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_189B0[] = { +#include "textures/segment2/segment2_cn.189B0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_189C0[] = { +#include "textures/segment2/segment2_cn.189C0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_189D0[] = { +#include "textures/segment2/segment2_cn.189D0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_189E0[] = { +#include "textures/segment2/segment2_cn.189E0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_189F0[] = { +#include "textures/segment2/segment2_cn.189F0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18A00[] = { +#include "textures/segment2/segment2_cn.18A00.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18A10[] = { +#include "textures/segment2/segment2_cn.18A10.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18A20[] = { +#include "textures/segment2/segment2_cn.18A20.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18A30[] = { +#include "textures/segment2/segment2_cn.18A30.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18A40[] = { +#include "textures/segment2/segment2_cn.18A40.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18A50[] = { +#include "textures/segment2/segment2_cn.18A50.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18A60[] = { +#include "textures/segment2/segment2_cn.18A60.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18A70[] = { +#include "textures/segment2/segment2_cn.18A70.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18A80[] = { +#include "textures/segment2/segment2_cn.18A80.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18A90[] = { +#include "textures/segment2/segment2_cn.18A90.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18AA0[] = { +#include "textures/segment2/segment2_cn.18AA0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18AB0[] = { +#include "textures/segment2/segment2_cn.18AB0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18AC0[] = { +#include "textures/segment2/segment2_cn.18AC0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18AD0[] = { +#include "textures/segment2/segment2_cn.18AD0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18AE0[] = { +#include "textures/segment2/segment2_cn.18AE0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18AF0[] = { +#include "textures/segment2/segment2_cn.18AF0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18B00[] = { +#include "textures/segment2/segment2_cn.18B00.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18B10[] = { +#include "textures/segment2/segment2_cn.18B10.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18B20[] = { +#include "textures/segment2/segment2_cn.18B20.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18B30[] = { +#include "textures/segment2/segment2_cn.18B30.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18B40[] = { +#include "textures/segment2/segment2_cn.18B40.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18B50[] = { +#include "textures/segment2/segment2_cn.18B50.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18B60[] = { +#include "textures/segment2/segment2_cn.18B60.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18B70[] = { +#include "textures/segment2/segment2_cn.18B70.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18B80[] = { +#include "textures/segment2/segment2_cn.18B80.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18B90[] = { +#include "textures/segment2/segment2_cn.18B90.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18BA0[] = { +#include "textures/segment2/segment2_cn.18BA0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18BB0[] = { +#include "textures/segment2/segment2_cn.18BB0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18BC0[] = { +#include "textures/segment2/segment2_cn.18BC0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18BD0[] = { +#include "textures/segment2/segment2_cn.18BD0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18BE0[] = { +#include "textures/segment2/segment2_cn.18BE0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18BF0[] = { +#include "textures/segment2/segment2_cn.18BF0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18C00[] = { +#include "textures/segment2/segment2_cn.18C00.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18C10[] = { +#include "textures/segment2/segment2_cn.18C10.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18C20[] = { +#include "textures/segment2/segment2_cn.18C20.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18C30[] = { +#include "textures/segment2/segment2_cn.18C30.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18C40[] = { +#include "textures/segment2/segment2_cn.18C40.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18C50[] = { +#include "textures/segment2/segment2_cn.18C50.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18C60[] = { +#include "textures/segment2/segment2_cn.18C60.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18C70[] = { +#include "textures/segment2/segment2_cn.18C70.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18C80[] = { +#include "textures/segment2/segment2_cn.18C80.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18C90[] = { +#include "textures/segment2/segment2_cn.18C90.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18CA0[] = { +#include "textures/segment2/segment2_cn.18CA0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18CB0[] = { +#include "textures/segment2/segment2_cn.18CB0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18CC0[] = { +#include "textures/segment2/segment2_cn.18CC0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18CD0[] = { +#include "textures/segment2/segment2_cn.18CD0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18CE0[] = { +#include "textures/segment2/segment2_cn.18CE0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18CF0[] = { +#include "textures/segment2/segment2_cn.18CF0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18D00[] = { +#include "textures/segment2/segment2_cn.18D00.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18D10[] = { +#include "textures/segment2/segment2_cn.18D10.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18D20[] = { +#include "textures/segment2/segment2_cn.18D20.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18D30[] = { +#include "textures/segment2/segment2_cn.18D30.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18D40[] = { +#include "textures/segment2/segment2_cn.18D40.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18D50[] = { +#include "textures/segment2/segment2_cn.18D50.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18D60[] = { +#include "textures/segment2/segment2_cn.18D60.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18D70[] = { +#include "textures/segment2/segment2_cn.18D70.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18D80[] = { +#include "textures/segment2/segment2_cn.18D80.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18D90[] = { +#include "textures/segment2/segment2_cn.18D90.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18DA0[] = { +#include "textures/segment2/segment2_cn.18DA0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18DB0[] = { +#include "textures/segment2/segment2_cn.18DB0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18DC0[] = { +#include "textures/segment2/segment2_cn.18DC0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18DD0[] = { +#include "textures/segment2/segment2_cn.18DD0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18DE0[] = { +#include "textures/segment2/segment2_cn.18DE0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18DF0[] = { +#include "textures/segment2/segment2_cn.18DF0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18E00[] = { +#include "textures/segment2/segment2_cn.18E00.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18E10[] = { +#include "textures/segment2/segment2_cn.18E10.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18E20[] = { +#include "textures/segment2/segment2_cn.18E20.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18E30[] = { +#include "textures/segment2/segment2_cn.18E30.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18E40[] = { +#include "textures/segment2/segment2_cn.18E40.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18E50[] = { +#include "textures/segment2/segment2_cn.18E50.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18E60[] = { +#include "textures/segment2/segment2_cn.18E60.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18E70[] = { +#include "textures/segment2/segment2_cn.18E70.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18E80[] = { +#include "textures/segment2/segment2_cn.18E80.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18E90[] = { +#include "textures/segment2/segment2_cn.18E90.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18EA0[] = { +#include "textures/segment2/segment2_cn.18EA0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18EB0[] = { +#include "textures/segment2/segment2_cn.18EB0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18EC0[] = { +#include "textures/segment2/segment2_cn.18EC0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18ED0[] = { +#include "textures/segment2/segment2_cn.18ED0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18EE0[] = { +#include "textures/segment2/segment2_cn.18EE0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18EF0[] = { +#include "textures/segment2/segment2_cn.18EF0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18F00[] = { +#include "textures/segment2/segment2_cn.18F00.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18F10[] = { +#include "textures/segment2/segment2_cn.18F10.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18F20[] = { +#include "textures/segment2/segment2_cn.18F20.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18F30[] = { +#include "textures/segment2/segment2_cn.18F30.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18F40[] = { +#include "textures/segment2/segment2_cn.18F40.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18F50[] = { +#include "textures/segment2/segment2_cn.18F50.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18F60[] = { +#include "textures/segment2/segment2_cn.18F60.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18F70[] = { +#include "textures/segment2/segment2_cn.18F70.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18F80[] = { +#include "textures/segment2/segment2_cn.18F80.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18F90[] = { +#include "textures/segment2/segment2_cn.18F90.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18FA0[] = { +#include "textures/segment2/segment2_cn.18FA0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18FB0[] = { +#include "textures/segment2/segment2_cn.18FB0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18FC0[] = { +#include "textures/segment2/segment2_cn.18FC0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18FD0[] = { +#include "textures/segment2/segment2_cn.18FD0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18FE0[] = { +#include "textures/segment2/segment2_cn.18FE0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_18FF0[] = { +#include "textures/segment2/segment2_cn.18FF0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19000[] = { +#include "textures/segment2/segment2_cn.19000.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19010[] = { +#include "textures/segment2/segment2_cn.19010.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19020[] = { +#include "textures/segment2/segment2_cn.19020.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19030[] = { +#include "textures/segment2/segment2_cn.19030.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19040[] = { +#include "textures/segment2/segment2_cn.19040.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19050[] = { +#include "textures/segment2/segment2_cn.19050.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19060[] = { +#include "textures/segment2/segment2_cn.19060.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19070[] = { +#include "textures/segment2/segment2_cn.19070.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19080[] = { +#include "textures/segment2/segment2_cn.19080.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19090[] = { +#include "textures/segment2/segment2_cn.19090.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_190A0[] = { +#include "textures/segment2/segment2_cn.190A0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_190B0[] = { +#include "textures/segment2/segment2_cn.190B0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_190C0[] = { +#include "textures/segment2/segment2_cn.190C0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_190D0[] = { +#include "textures/segment2/segment2_cn.190D0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_190E0[] = { +#include "textures/segment2/segment2_cn.190E0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_190F0[] = { +#include "textures/segment2/segment2_cn.190F0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19100[] = { +#include "textures/segment2/segment2_cn.19100.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19110[] = { +#include "textures/segment2/segment2_cn.19110.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19120[] = { +#include "textures/segment2/segment2_cn.19120.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19130[] = { +#include "textures/segment2/segment2_cn.19130.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19140[] = { +#include "textures/segment2/segment2_cn.19140.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19150[] = { +#include "textures/segment2/segment2_cn.19150.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19160[] = { +#include "textures/segment2/segment2_cn.19160.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19170[] = { +#include "textures/segment2/segment2_cn.19170.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19180[] = { +#include "textures/segment2/segment2_cn.19180.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19190[] = { +#include "textures/segment2/segment2_cn.19190.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_191A0[] = { +#include "textures/segment2/segment2_cn.191A0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_191B0[] = { +#include "textures/segment2/segment2_cn.191B0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_191C0[] = { +#include "textures/segment2/segment2_cn.191C0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_191D0[] = { +#include "textures/segment2/segment2_cn.191D0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_191E0[] = { +#include "textures/segment2/segment2_cn.191E0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_191F0[] = { +#include "textures/segment2/segment2_cn.191F0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19200[] = { +#include "textures/segment2/segment2_cn.19200.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19210[] = { +#include "textures/segment2/segment2_cn.19210.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19220[] = { +#include "textures/segment2/segment2_cn.19220.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19230[] = { +#include "textures/segment2/segment2_cn.19230.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19240[] = { +#include "textures/segment2/segment2_cn.19240.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19250[] = { +#include "textures/segment2/segment2_cn.19250.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19260[] = { +#include "textures/segment2/segment2_cn.19260.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19270[] = { +#include "textures/segment2/segment2_cn.19270.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19280[] = { +#include "textures/segment2/segment2_cn.19280.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19290[] = { +#include "textures/segment2/segment2_cn.19290.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_192A0[] = { +#include "textures/segment2/segment2_cn.192A0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_192B0[] = { +#include "textures/segment2/segment2_cn.192B0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_192C0[] = { +#include "textures/segment2/segment2_cn.192C0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_192D0[] = { +#include "textures/segment2/segment2_cn.192D0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_192E0[] = { +#include "textures/segment2/segment2_cn.192E0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_192F0[] = { +#include "textures/segment2/segment2_cn.192F0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19300[] = { +#include "textures/segment2/segment2_cn.19300.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19310[] = { +#include "textures/segment2/segment2_cn.19310.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19320[] = { +#include "textures/segment2/segment2_cn.19320.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19330[] = { +#include "textures/segment2/segment2_cn.19330.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19340[] = { +#include "textures/segment2/segment2_cn.19340.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19350[] = { +#include "textures/segment2/segment2_cn.19350.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19360[] = { +#include "textures/segment2/segment2_cn.19360.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19370[] = { +#include "textures/segment2/segment2_cn.19370.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19380[] = { +#include "textures/segment2/segment2_cn.19380.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19390[] = { +#include "textures/segment2/segment2_cn.19390.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_193A0[] = { +#include "textures/segment2/segment2_cn.193A0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_193B0[] = { +#include "textures/segment2/segment2_cn.193B0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_193C0[] = { +#include "textures/segment2/segment2_cn.193C0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_193D0[] = { +#include "textures/segment2/segment2_cn.193D0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_193E0[] = { +#include "textures/segment2/segment2_cn.193E0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_193F0[] = { +#include "textures/segment2/segment2_cn.193F0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19400[] = { +#include "textures/segment2/segment2_cn.19400.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19410[] = { +#include "textures/segment2/segment2_cn.19410.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19420[] = { +#include "textures/segment2/segment2_cn.19420.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19430[] = { +#include "textures/segment2/segment2_cn.19430.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19440[] = { +#include "textures/segment2/segment2_cn.19440.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19450[] = { +#include "textures/segment2/segment2_cn.19450.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19460[] = { +#include "textures/segment2/segment2_cn.19460.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19470[] = { +#include "textures/segment2/segment2_cn.19470.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19480[] = { +#include "textures/segment2/segment2_cn.19480.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19490[] = { +#include "textures/segment2/segment2_cn.19490.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_194A0[] = { +#include "textures/segment2/segment2_cn.194A0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_194B0[] = { +#include "textures/segment2/segment2_cn.194B0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_194C0[] = { +#include "textures/segment2/segment2_cn.194C0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_194D0[] = { +#include "textures/segment2/segment2_cn.194D0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_194E0[] = { +#include "textures/segment2/segment2_cn.194E0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_194F0[] = { +#include "textures/segment2/segment2_cn.194F0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19500[] = { +#include "textures/segment2/segment2_cn.19500.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19510[] = { +#include "textures/segment2/segment2_cn.19510.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19520[] = { +#include "textures/segment2/segment2_cn.19520.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19530[] = { +#include "textures/segment2/segment2_cn.19530.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19540[] = { +#include "textures/segment2/segment2_cn.19540.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19550[] = { +#include "textures/segment2/segment2_cn.19550.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19560[] = { +#include "textures/segment2/segment2_cn.19560.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19570[] = { +#include "textures/segment2/segment2_cn.19570.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19580[] = { +#include "textures/segment2/segment2_cn.19580.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19590[] = { +#include "textures/segment2/segment2_cn.19590.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_195A0[] = { +#include "textures/segment2/segment2_cn.195A0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_195B0[] = { +#include "textures/segment2/segment2_cn.195B0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_195C0[] = { +#include "textures/segment2/segment2_cn.195C0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_195D0[] = { +#include "textures/segment2/segment2_cn.195D0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_195E0[] = { +#include "textures/segment2/segment2_cn.195E0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_195F0[] = { +#include "textures/segment2/segment2_cn.195F0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19600[] = { +#include "textures/segment2/segment2_cn.19600.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19610[] = { +#include "textures/segment2/segment2_cn.19610.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19620[] = { +#include "textures/segment2/segment2_cn.19620.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19630[] = { +#include "textures/segment2/segment2_cn.19630.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19640[] = { +#include "textures/segment2/segment2_cn.19640.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19650[] = { +#include "textures/segment2/segment2_cn.19650.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19660[] = { +#include "textures/segment2/segment2_cn.19660.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19670[] = { +#include "textures/segment2/segment2_cn.19670.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19680[] = { +#include "textures/segment2/segment2_cn.19680.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19690[] = { +#include "textures/segment2/segment2_cn.19690.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_196A0[] = { +#include "textures/segment2/segment2_cn.196A0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_196B0[] = { +#include "textures/segment2/segment2_cn.196B0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_196C0[] = { +#include "textures/segment2/segment2_cn.196C0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_196D0[] = { +#include "textures/segment2/segment2_cn.196D0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_196E0[] = { +#include "textures/segment2/segment2_cn.196E0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_196F0[] = { +#include "textures/segment2/segment2_cn.196F0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19700[] = { +#include "textures/segment2/segment2_cn.19700.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19710[] = { +#include "textures/segment2/segment2_cn.19710.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19720[] = { +#include "textures/segment2/segment2_cn.19720.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19730[] = { +#include "textures/segment2/segment2_cn.19730.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19740[] = { +#include "textures/segment2/segment2_cn.19740.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19750[] = { +#include "textures/segment2/segment2_cn.19750.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19760[] = { +#include "textures/segment2/segment2_cn.19760.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19770[] = { +#include "textures/segment2/segment2_cn.19770.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19780[] = { +#include "textures/segment2/segment2_cn.19780.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19790[] = { +#include "textures/segment2/segment2_cn.19790.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_197A0[] = { +#include "textures/segment2/segment2_cn.197A0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_197B0[] = { +#include "textures/segment2/segment2_cn.197B0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_197C0[] = { +#include "textures/segment2/segment2_cn.197C0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_197D0[] = { +#include "textures/segment2/segment2_cn.197D0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_197E0[] = { +#include "textures/segment2/segment2_cn.197E0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_197F0[] = { +#include "textures/segment2/segment2_cn.197F0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19800[] = { +#include "textures/segment2/segment2_cn.19800.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19810[] = { +#include "textures/segment2/segment2_cn.19810.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19820[] = { +#include "textures/segment2/segment2_cn.19820.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19830[] = { +#include "textures/segment2/segment2_cn.19830.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19840[] = { +#include "textures/segment2/segment2_cn.19840.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19850[] = { +#include "textures/segment2/segment2_cn.19850.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19860[] = { +#include "textures/segment2/segment2_cn.19860.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19870[] = { +#include "textures/segment2/segment2_cn.19870.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19880[] = { +#include "textures/segment2/segment2_cn.19880.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19890[] = { +#include "textures/segment2/segment2_cn.19890.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_198A0[] = { +#include "textures/segment2/segment2_cn.198A0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_198B0[] = { +#include "textures/segment2/segment2_cn.198B0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_198C0[] = { +#include "textures/segment2/segment2_cn.198C0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_198D0[] = { +#include "textures/segment2/segment2_cn.198D0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_198E0[] = { +#include "textures/segment2/segment2_cn.198E0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_198F0[] = { +#include "textures/segment2/segment2_cn.198F0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19900[] = { +#include "textures/segment2/segment2_cn.19900.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19910[] = { +#include "textures/segment2/segment2_cn.19910.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19920[] = { +#include "textures/segment2/segment2_cn.19920.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19930[] = { +#include "textures/segment2/segment2_cn.19930.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19940[] = { +#include "textures/segment2/segment2_cn.19940.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19950[] = { +#include "textures/segment2/segment2_cn.19950.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19960[] = { +#include "textures/segment2/segment2_cn.19960.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19970[] = { +#include "textures/segment2/segment2_cn.19970.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19980[] = { +#include "textures/segment2/segment2_cn.19980.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19990[] = { +#include "textures/segment2/segment2_cn.19990.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_199A0[] = { +#include "textures/segment2/segment2_cn.199A0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_199B0[] = { +#include "textures/segment2/segment2_cn.199B0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_199C0[] = { +#include "textures/segment2/segment2_cn.199C0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_199D0[] = { +#include "textures/segment2/segment2_cn.199D0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_199E0[] = { +#include "textures/segment2/segment2_cn.199E0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_199F0[] = { +#include "textures/segment2/segment2_cn.199F0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19A00[] = { +#include "textures/segment2/segment2_cn.19A00.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19A10[] = { +#include "textures/segment2/segment2_cn.19A10.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19A20[] = { +#include "textures/segment2/segment2_cn.19A20.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19A30[] = { +#include "textures/segment2/segment2_cn.19A30.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19A40[] = { +#include "textures/segment2/segment2_cn.19A40.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19A50[] = { +#include "textures/segment2/segment2_cn.19A50.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19A60[] = { +#include "textures/segment2/segment2_cn.19A60.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19A70[] = { +#include "textures/segment2/segment2_cn.19A70.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19A80[] = { +#include "textures/segment2/segment2_cn.19A80.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19A90[] = { +#include "textures/segment2/segment2_cn.19A90.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19AA0[] = { +#include "textures/segment2/segment2_cn.19AA0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19AB0[] = { +#include "textures/segment2/segment2_cn.19AB0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19AC0[] = { +#include "textures/segment2/segment2_cn.19AC0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19AD0[] = { +#include "textures/segment2/segment2_cn.19AD0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19AE0[] = { +#include "textures/segment2/segment2_cn.19AE0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19AF0[] = { +#include "textures/segment2/segment2_cn.19AF0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19B00[] = { +#include "textures/segment2/segment2_cn.19B00.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19B10[] = { +#include "textures/segment2/segment2_cn.19B10.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19B20[] = { +#include "textures/segment2/segment2_cn.19B20.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19B30[] = { +#include "textures/segment2/segment2_cn.19B30.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19B40[] = { +#include "textures/segment2/segment2_cn.19B40.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19B50[] = { +#include "textures/segment2/segment2_cn.19B50.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19B60[] = { +#include "textures/segment2/segment2_cn.19B60.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19B70[] = { +#include "textures/segment2/segment2_cn.19B70.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19B80[] = { +#include "textures/segment2/segment2_cn.19B80.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19B90[] = { +#include "textures/segment2/segment2_cn.19B90.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19BA0[] = { +#include "textures/segment2/segment2_cn.19BA0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19BB0[] = { +#include "textures/segment2/segment2_cn.19BB0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19BC0[] = { +#include "textures/segment2/segment2_cn.19BC0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19BD0[] = { +#include "textures/segment2/segment2_cn.19BD0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19BE0[] = { +#include "textures/segment2/segment2_cn.19BE0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19BF0[] = { +#include "textures/segment2/segment2_cn.19BF0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19C00[] = { +#include "textures/segment2/segment2_cn.19C00.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19C10[] = { +#include "textures/segment2/segment2_cn.19C10.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19C20[] = { +#include "textures/segment2/segment2_cn.19C20.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19C30[] = { +#include "textures/segment2/segment2_cn.19C30.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19C40[] = { +#include "textures/segment2/segment2_cn.19C40.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19C50[] = { +#include "textures/segment2/segment2_cn.19C50.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19C60[] = { +#include "textures/segment2/segment2_cn.19C60.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19C70[] = { +#include "textures/segment2/segment2_cn.19C70.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19C80[] = { +#include "textures/segment2/segment2_cn.19C80.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19C90[] = { +#include "textures/segment2/segment2_cn.19C90.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19CA0[] = { +#include "textures/segment2/segment2_cn.19CA0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19CB0[] = { +#include "textures/segment2/segment2_cn.19CB0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19CC0[] = { +#include "textures/segment2/segment2_cn.19CC0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19CD0[] = { +#include "textures/segment2/segment2_cn.19CD0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19CE0[] = { +#include "textures/segment2/segment2_cn.19CE0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19CF0[] = { +#include "textures/segment2/segment2_cn.19CF0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19D00[] = { +#include "textures/segment2/segment2_cn.19D00.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19D10[] = { +#include "textures/segment2/segment2_cn.19D10.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19D20[] = { +#include "textures/segment2/segment2_cn.19D20.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19D30[] = { +#include "textures/segment2/segment2_cn.19D30.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19D40[] = { +#include "textures/segment2/segment2_cn.19D40.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19D50[] = { +#include "textures/segment2/segment2_cn.19D50.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19D60[] = { +#include "textures/segment2/segment2_cn.19D60.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19D70[] = { +#include "textures/segment2/segment2_cn.19D70.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19D80[] = { +#include "textures/segment2/segment2_cn.19D80.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19D90[] = { +#include "textures/segment2/segment2_cn.19D90.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19DA0[] = { +#include "textures/segment2/segment2_cn.19DA0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19DB0[] = { +#include "textures/segment2/segment2_cn.19DB0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19DC0[] = { +#include "textures/segment2/segment2_cn.19DC0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19DD0[] = { +#include "textures/segment2/segment2_cn.19DD0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19DE0[] = { +#include "textures/segment2/segment2_cn.19DE0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19DF0[] = { +#include "textures/segment2/segment2_cn.19DF0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19E00[] = { +#include "textures/segment2/segment2_cn.19E00.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19E10[] = { +#include "textures/segment2/segment2_cn.19E10.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19E20[] = { +#include "textures/segment2/segment2_cn.19E20.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19E30[] = { +#include "textures/segment2/segment2_cn.19E30.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19E40[] = { +#include "textures/segment2/segment2_cn.19E40.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19E50[] = { +#include "textures/segment2/segment2_cn.19E50.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19E60[] = { +#include "textures/segment2/segment2_cn.19E60.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19E70[] = { +#include "textures/segment2/segment2_cn.19E70.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19E80[] = { +#include "textures/segment2/segment2_cn.19E80.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19E90[] = { +#include "textures/segment2/segment2_cn.19E90.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19EA0[] = { +#include "textures/segment2/segment2_cn.19EA0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19EB0[] = { +#include "textures/segment2/segment2_cn.19EB0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19EC0[] = { +#include "textures/segment2/segment2_cn.19EC0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19ED0[] = { +#include "textures/segment2/segment2_cn.19ED0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19EE0[] = { +#include "textures/segment2/segment2_cn.19EE0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19EF0[] = { +#include "textures/segment2/segment2_cn.19EF0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19F00[] = { +#include "textures/segment2/segment2_cn.19F00.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19F10[] = { +#include "textures/segment2/segment2_cn.19F10.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19F20[] = { +#include "textures/segment2/segment2_cn.19F20.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19F30[] = { +#include "textures/segment2/segment2_cn.19F30.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19F40[] = { +#include "textures/segment2/segment2_cn.19F40.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19F50[] = { +#include "textures/segment2/segment2_cn.19F50.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19F60[] = { +#include "textures/segment2/segment2_cn.19F60.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19F70[] = { +#include "textures/segment2/segment2_cn.19F70.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19F80[] = { +#include "textures/segment2/segment2_cn.19F80.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19F90[] = { +#include "textures/segment2/segment2_cn.19F90.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19FA0[] = { +#include "textures/segment2/segment2_cn.19FA0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19FB0[] = { +#include "textures/segment2/segment2_cn.19FB0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19FC0[] = { +#include "textures/segment2/segment2_cn.19FC0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19FD0[] = { +#include "textures/segment2/segment2_cn.19FD0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19FE0[] = { +#include "textures/segment2/segment2_cn.19FE0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_19FF0[] = { +#include "textures/segment2/segment2_cn.19FF0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A000[] = { +#include "textures/segment2/segment2_cn.1A000.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A010[] = { +#include "textures/segment2/segment2_cn.1A010.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A020[] = { +#include "textures/segment2/segment2_cn.1A020.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A030[] = { +#include "textures/segment2/segment2_cn.1A030.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A040[] = { +#include "textures/segment2/segment2_cn.1A040.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A050[] = { +#include "textures/segment2/segment2_cn.1A050.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A060[] = { +#include "textures/segment2/segment2_cn.1A060.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A070[] = { +#include "textures/segment2/segment2_cn.1A070.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A080[] = { +#include "textures/segment2/segment2_cn.1A080.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A090[] = { +#include "textures/segment2/segment2_cn.1A090.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A0A0[] = { +#include "textures/segment2/segment2_cn.1A0A0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A0B0[] = { +#include "textures/segment2/segment2_cn.1A0B0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A0C0[] = { +#include "textures/segment2/segment2_cn.1A0C0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A0D0[] = { +#include "textures/segment2/segment2_cn.1A0D0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A0E0[] = { +#include "textures/segment2/segment2_cn.1A0E0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A0F0[] = { +#include "textures/segment2/segment2_cn.1A0F0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A100[] = { +#include "textures/segment2/segment2_cn.1A100.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A110[] = { +#include "textures/segment2/segment2_cn.1A110.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A120[] = { +#include "textures/segment2/segment2_cn.1A120.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A130[] = { +#include "textures/segment2/segment2_cn.1A130.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A140[] = { +#include "textures/segment2/segment2_cn.1A140.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A150[] = { +#include "textures/segment2/segment2_cn.1A150.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A160[] = { +#include "textures/segment2/segment2_cn.1A160.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A170[] = { +#include "textures/segment2/segment2_cn.1A170.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A180[] = { +#include "textures/segment2/segment2_cn.1A180.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A190[] = { +#include "textures/segment2/segment2_cn.1A190.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A1A0[] = { +#include "textures/segment2/segment2_cn.1A1A0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A1B0[] = { +#include "textures/segment2/segment2_cn.1A1B0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A1C0[] = { +#include "textures/segment2/segment2_cn.1A1C0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A1D0[] = { +#include "textures/segment2/segment2_cn.1A1D0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A1E0[] = { +#include "textures/segment2/segment2_cn.1A1E0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A1F0[] = { +#include "textures/segment2/segment2_cn.1A1F0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A200[] = { +#include "textures/segment2/segment2_cn.1A200.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A210[] = { +#include "textures/segment2/segment2_cn.1A210.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A220[] = { +#include "textures/segment2/segment2_cn.1A220.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A230[] = { +#include "textures/segment2/segment2_cn.1A230.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A240[] = { +#include "textures/segment2/segment2_cn.1A240.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A250[] = { +#include "textures/segment2/segment2_cn.1A250.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A260[] = { +#include "textures/segment2/segment2_cn.1A260.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A270[] = { +#include "textures/segment2/segment2_cn.1A270.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A280[] = { +#include "textures/segment2/segment2_cn.1A280.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A290[] = { +#include "textures/segment2/segment2_cn.1A290.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A2A0[] = { +#include "textures/segment2/segment2_cn.1A2A0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A2B0[] = { +#include "textures/segment2/segment2_cn.1A2B0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A2C0[] = { +#include "textures/segment2/segment2_cn.1A2C0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A2D0[] = { +#include "textures/segment2/segment2_cn.1A2D0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A2E0[] = { +#include "textures/segment2/segment2_cn.1A2E0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A2F0[] = { +#include "textures/segment2/segment2_cn.1A2F0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A300[] = { +#include "textures/segment2/segment2_cn.1A300.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A310[] = { +#include "textures/segment2/segment2_cn.1A310.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A320[] = { +#include "textures/segment2/segment2_cn.1A320.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A330[] = { +#include "textures/segment2/segment2_cn.1A330.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A340[] = { +#include "textures/segment2/segment2_cn.1A340.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A350[] = { +#include "textures/segment2/segment2_cn.1A350.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A360[] = { +#include "textures/segment2/segment2_cn.1A360.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A370[] = { +#include "textures/segment2/segment2_cn.1A370.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A380[] = { +#include "textures/segment2/segment2_cn.1A380.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A390[] = { +#include "textures/segment2/segment2_cn.1A390.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A3A0[] = { +#include "textures/segment2/segment2_cn.1A3A0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A3B0[] = { +#include "textures/segment2/segment2_cn.1A3B0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A3C0[] = { +#include "textures/segment2/segment2_cn.1A3C0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A3D0[] = { +#include "textures/segment2/segment2_cn.1A3D0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A3E0[] = { +#include "textures/segment2/segment2_cn.1A3E0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A3F0[] = { +#include "textures/segment2/segment2_cn.1A3F0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A400[] = { +#include "textures/segment2/segment2_cn.1A400.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A410[] = { +#include "textures/segment2/segment2_cn.1A410.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A420[] = { +#include "textures/segment2/segment2_cn.1A420.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A430[] = { +#include "textures/segment2/segment2_cn.1A430.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A440[] = { +#include "textures/segment2/segment2_cn.1A440.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A450[] = { +#include "textures/segment2/segment2_cn.1A450.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A460[] = { +#include "textures/segment2/segment2_cn.1A460.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A470[] = { +#include "textures/segment2/segment2_cn.1A470.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A480[] = { +#include "textures/segment2/segment2_cn.1A480.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A490[] = { +#include "textures/segment2/segment2_cn.1A490.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A4A0[] = { +#include "textures/segment2/segment2_cn.1A4A0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A4B0[] = { +#include "textures/segment2/segment2_cn.1A4B0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A4C0[] = { +#include "textures/segment2/segment2_cn.1A4C0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A4D0[] = { +#include "textures/segment2/segment2_cn.1A4D0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A4E0[] = { +#include "textures/segment2/segment2_cn.1A4E0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A4F0[] = { +#include "textures/segment2/segment2_cn.1A4F0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A500[] = { +#include "textures/segment2/segment2_cn.1A500.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A510[] = { +#include "textures/segment2/segment2_cn.1A510.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A520[] = { +#include "textures/segment2/segment2_cn.1A520.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A530[] = { +#include "textures/segment2/segment2_cn.1A530.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A540[] = { +#include "textures/segment2/segment2_cn.1A540.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A550[] = { +#include "textures/segment2/segment2_cn.1A550.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A560[] = { +#include "textures/segment2/segment2_cn.1A560.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A570[] = { +#include "textures/segment2/segment2_cn.1A570.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A580[] = { +#include "textures/segment2/segment2_cn.1A580.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A590[] = { +#include "textures/segment2/segment2_cn.1A590.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A5A0[] = { +#include "textures/segment2/segment2_cn.1A5A0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A5B0[] = { +#include "textures/segment2/segment2_cn.1A5B0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A5C0[] = { +#include "textures/segment2/segment2_cn.1A5C0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A5D0[] = { +#include "textures/segment2/segment2_cn.1A5D0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A5E0[] = { +#include "textures/segment2/segment2_cn.1A5E0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A5F0[] = { +#include "textures/segment2/segment2_cn.1A5F0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A600[] = { +#include "textures/segment2/segment2_cn.1A600.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A610[] = { +#include "textures/segment2/segment2_cn.1A610.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A620[] = { +#include "textures/segment2/segment2_cn.1A620.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A630[] = { +#include "textures/segment2/segment2_cn.1A630.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A640[] = { +#include "textures/segment2/segment2_cn.1A640.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A650[] = { +#include "textures/segment2/segment2_cn.1A650.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A660[] = { +#include "textures/segment2/segment2_cn.1A660.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A670[] = { +#include "textures/segment2/segment2_cn.1A670.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A680[] = { +#include "textures/segment2/segment2_cn.1A680.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A690[] = { +#include "textures/segment2/segment2_cn.1A690.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A6A0[] = { +#include "textures/segment2/segment2_cn.1A6A0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A6B0[] = { +#include "textures/segment2/segment2_cn.1A6B0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A6C0[] = { +#include "textures/segment2/segment2_cn.1A6C0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A6D0[] = { +#include "textures/segment2/segment2_cn.1A6D0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A6E0[] = { +#include "textures/segment2/segment2_cn.1A6E0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A6F0[] = { +#include "textures/segment2/segment2_cn.1A6F0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A700[] = { +#include "textures/segment2/segment2_cn.1A700.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A710[] = { +#include "textures/segment2/segment2_cn.1A710.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A720[] = { +#include "textures/segment2/segment2_cn.1A720.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A730[] = { +#include "textures/segment2/segment2_cn.1A730.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A740[] = { +#include "textures/segment2/segment2_cn.1A740.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A750[] = { +#include "textures/segment2/segment2_cn.1A750.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A760[] = { +#include "textures/segment2/segment2_cn.1A760.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A770[] = { +#include "textures/segment2/segment2_cn.1A770.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A780[] = { +#include "textures/segment2/segment2_cn.1A780.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A790[] = { +#include "textures/segment2/segment2_cn.1A790.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A7A0[] = { +#include "textures/segment2/segment2_cn.1A7A0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A7B0[] = { +#include "textures/segment2/segment2_cn.1A7B0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A7C0[] = { +#include "textures/segment2/segment2_cn.1A7C0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A7D0[] = { +#include "textures/segment2/segment2_cn.1A7D0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A7E0[] = { +#include "textures/segment2/segment2_cn.1A7E0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A7F0[] = { +#include "textures/segment2/segment2_cn.1A7F0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A800[] = { +#include "textures/segment2/segment2_cn.1A800.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A810[] = { +#include "textures/segment2/segment2_cn.1A810.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A820[] = { +#include "textures/segment2/segment2_cn.1A820.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A830[] = { +#include "textures/segment2/segment2_cn.1A830.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A840[] = { +#include "textures/segment2/segment2_cn.1A840.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A850[] = { +#include "textures/segment2/segment2_cn.1A850.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A860[] = { +#include "textures/segment2/segment2_cn.1A860.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A870[] = { +#include "textures/segment2/segment2_cn.1A870.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A880[] = { +#include "textures/segment2/segment2_cn.1A880.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A890[] = { +#include "textures/segment2/segment2_cn.1A890.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A8A0[] = { +#include "textures/segment2/segment2_cn.1A8A0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A8B0[] = { +#include "textures/segment2/segment2_cn.1A8B0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A8C0[] = { +#include "textures/segment2/segment2_cn.1A8C0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A8D0[] = { +#include "textures/segment2/segment2_cn.1A8D0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A8E0[] = { +#include "textures/segment2/segment2_cn.1A8E0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A8F0[] = { +#include "textures/segment2/segment2_cn.1A8F0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A900[] = { +#include "textures/segment2/segment2_cn.1A900.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A910[] = { +#include "textures/segment2/segment2_cn.1A910.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A920[] = { +#include "textures/segment2/segment2_cn.1A920.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A930[] = { +#include "textures/segment2/segment2_cn.1A930.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A940[] = { +#include "textures/segment2/segment2_cn.1A940.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A950[] = { +#include "textures/segment2/segment2_cn.1A950.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A960[] = { +#include "textures/segment2/segment2_cn.1A960.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A970[] = { +#include "textures/segment2/segment2_cn.1A970.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A980[] = { +#include "textures/segment2/segment2_cn.1A980.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A990[] = { +#include "textures/segment2/segment2_cn.1A990.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A9A0[] = { +#include "textures/segment2/segment2_cn.1A9A0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A9B0[] = { +#include "textures/segment2/segment2_cn.1A9B0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A9C0[] = { +#include "textures/segment2/segment2_cn.1A9C0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A9D0[] = { +#include "textures/segment2/segment2_cn.1A9D0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A9E0[] = { +#include "textures/segment2/segment2_cn.1A9E0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1A9F0[] = { +#include "textures/segment2/segment2_cn.1A9F0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1AA00[] = { +#include "textures/segment2/segment2_cn.1AA00.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1AA10[] = { +#include "textures/segment2/segment2_cn.1AA10.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1AA20[] = { +#include "textures/segment2/segment2_cn.1AA20.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1AA30[] = { +#include "textures/segment2/segment2_cn.1AA30.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1AA40[] = { +#include "textures/segment2/segment2_cn.1AA40.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1AA50[] = { +#include "textures/segment2/segment2_cn.1AA50.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1AA60[] = { +#include "textures/segment2/segment2_cn.1AA60.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1AA70[] = { +#include "textures/segment2/segment2_cn.1AA70.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1AA80[] = { +#include "textures/segment2/segment2_cn.1AA80.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1AA90[] = { +#include "textures/segment2/segment2_cn.1AA90.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1AAA0[] = { +#include "textures/segment2/segment2_cn.1AAA0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1AAB0[] = { +#include "textures/segment2/segment2_cn.1AAB0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1AAC0[] = { +#include "textures/segment2/segment2_cn.1AAC0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1AAD0[] = { +#include "textures/segment2/segment2_cn.1AAD0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1AAE0[] = { +#include "textures/segment2/segment2_cn.1AAE0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1AAF0[] = { +#include "textures/segment2/segment2_cn.1AAF0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1AB00[] = { +#include "textures/segment2/segment2_cn.1AB00.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1AB10[] = { +#include "textures/segment2/segment2_cn.1AB10.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1AB20[] = { +#include "textures/segment2/segment2_cn.1AB20.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1AB30[] = { +#include "textures/segment2/segment2_cn.1AB30.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1AB40[] = { +#include "textures/segment2/segment2_cn.1AB40.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1AB50[] = { +#include "textures/segment2/segment2_cn.1AB50.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1AB60[] = { +#include "textures/segment2/segment2_cn.1AB60.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1AB70[] = { +#include "textures/segment2/segment2_cn.1AB70.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1AB80[] = { +#include "textures/segment2/segment2_cn.1AB80.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1AB90[] = { +#include "textures/segment2/segment2_cn.1AB90.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1ABA0[] = { +#include "textures/segment2/segment2_cn.1ABA0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1ABB0[] = { +#include "textures/segment2/segment2_cn.1ABB0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1ABC0[] = { +#include "textures/segment2/segment2_cn.1ABC0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1ABD0[] = { +#include "textures/segment2/segment2_cn.1ABD0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1ABE0[] = { +#include "textures/segment2/segment2_cn.1ABE0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1ABF0[] = { +#include "textures/segment2/segment2_cn.1ABF0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1AC00[] = { +#include "textures/segment2/segment2_cn.1AC00.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1AC10[] = { +#include "textures/segment2/segment2_cn.1AC10.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1AC20[] = { +#include "textures/segment2/segment2_cn.1AC20.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1AC30[] = { +#include "textures/segment2/segment2_cn.1AC30.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1AC40[] = { +#include "textures/segment2/segment2_cn.1AC40.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1AC50[] = { +#include "textures/segment2/segment2_cn.1AC50.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1AC60[] = { +#include "textures/segment2/segment2_cn.1AC60.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1AC70[] = { +#include "textures/segment2/segment2_cn.1AC70.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1AC80[] = { +#include "textures/segment2/segment2_cn.1AC80.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1AC90[] = { +#include "textures/segment2/segment2_cn.1AC90.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1ACA0[] = { +#include "textures/segment2/segment2_cn.1ACA0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1ACB0[] = { +#include "textures/segment2/segment2_cn.1ACB0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1ACC0[] = { +#include "textures/segment2/segment2_cn.1ACC0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1ACD0[] = { +#include "textures/segment2/segment2_cn.1ACD0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1ACE0[] = { +#include "textures/segment2/segment2_cn.1ACE0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1ACF0[] = { +#include "textures/segment2/segment2_cn.1ACF0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1AD00[] = { +#include "textures/segment2/segment2_cn.1AD00.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1AD10[] = { +#include "textures/segment2/segment2_cn.1AD10.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1AD20[] = { +#include "textures/segment2/segment2_cn.1AD20.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1AD30[] = { +#include "textures/segment2/segment2_cn.1AD30.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1AD40[] = { +#include "textures/segment2/segment2_cn.1AD40.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1AD50[] = { +#include "textures/segment2/segment2_cn.1AD50.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1AD60[] = { +#include "textures/segment2/segment2_cn.1AD60.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1AD70[] = { +#include "textures/segment2/segment2_cn.1AD70.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1AD80[] = { +#include "textures/segment2/segment2_cn.1AD80.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1AD90[] = { +#include "textures/segment2/segment2_cn.1AD90.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1ADA0[] = { +#include "textures/segment2/segment2_cn.1ADA0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1ADB0[] = { +#include "textures/segment2/segment2_cn.1ADB0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1ADC0[] = { +#include "textures/segment2/segment2_cn.1ADC0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1ADD0[] = { +#include "textures/segment2/segment2_cn.1ADD0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1ADE0[] = { +#include "textures/segment2/segment2_cn.1ADE0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1ADF0[] = { +#include "textures/segment2/segment2_cn.1ADF0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1AE00[] = { +#include "textures/segment2/segment2_cn.1AE00.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1AE10[] = { +#include "textures/segment2/segment2_cn.1AE10.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1AE20[] = { +#include "textures/segment2/segment2_cn.1AE20.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1AE30[] = { +#include "textures/segment2/segment2_cn.1AE30.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1AE40[] = { +#include "textures/segment2/segment2_cn.1AE40.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1AE50[] = { +#include "textures/segment2/segment2_cn.1AE50.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1AE60[] = { +#include "textures/segment2/segment2_cn.1AE60.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1AE70[] = { +#include "textures/segment2/segment2_cn.1AE70.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1AE80[] = { +#include "textures/segment2/segment2_cn.1AE80.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1AE90[] = { +#include "textures/segment2/segment2_cn.1AE90.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1AEA0[] = { +#include "textures/segment2/segment2_cn.1AEA0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1AEB0[] = { +#include "textures/segment2/segment2_cn.1AEB0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1AEC0[] = { +#include "textures/segment2/segment2_cn.1AEC0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1AED0[] = { +#include "textures/segment2/segment2_cn.1AED0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1AEE0[] = { +#include "textures/segment2/segment2_cn.1AEE0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1AEF0[] = { +#include "textures/segment2/segment2_cn.1AEF0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1AF00[] = { +#include "textures/segment2/segment2_cn.1AF00.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1AF10[] = { +#include "textures/segment2/segment2_cn.1AF10.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1AF20[] = { +#include "textures/segment2/segment2_cn.1AF20.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1AF30[] = { +#include "textures/segment2/segment2_cn.1AF30.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1AF40[] = { +#include "textures/segment2/segment2_cn.1AF40.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1AF50[] = { +#include "textures/segment2/segment2_cn.1AF50.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1AF60[] = { +#include "textures/segment2/segment2_cn.1AF60.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1AF70[] = { +#include "textures/segment2/segment2_cn.1AF70.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1AF80[] = { +#include "textures/segment2/segment2_cn.1AF80.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1AF90[] = { +#include "textures/segment2/segment2_cn.1AF90.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1AFA0[] = { +#include "textures/segment2/segment2_cn.1AFA0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1AFB0[] = { +#include "textures/segment2/segment2_cn.1AFB0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1AFC0[] = { +#include "textures/segment2/segment2_cn.1AFC0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1AFD0[] = { +#include "textures/segment2/segment2_cn.1AFD0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1AFE0[] = { +#include "textures/segment2/segment2_cn.1AFE0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1AFF0[] = { +#include "textures/segment2/segment2_cn.1AFF0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B000[] = { +#include "textures/segment2/segment2_cn.1B000.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B010[] = { +#include "textures/segment2/segment2_cn.1B010.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B020[] = { +#include "textures/segment2/segment2_cn.1B020.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B030[] = { +#include "textures/segment2/segment2_cn.1B030.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B040[] = { +#include "textures/segment2/segment2_cn.1B040.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B050[] = { +#include "textures/segment2/segment2_cn.1B050.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B060[] = { +#include "textures/segment2/segment2_cn.1B060.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B070[] = { +#include "textures/segment2/segment2_cn.1B070.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B080[] = { +#include "textures/segment2/segment2_cn.1B080.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B090[] = { +#include "textures/segment2/segment2_cn.1B090.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B0A0[] = { +#include "textures/segment2/segment2_cn.1B0A0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B0B0[] = { +#include "textures/segment2/segment2_cn.1B0B0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B0C0[] = { +#include "textures/segment2/segment2_cn.1B0C0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B0D0[] = { +#include "textures/segment2/segment2_cn.1B0D0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B0E0[] = { +#include "textures/segment2/segment2_cn.1B0E0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B0F0[] = { +#include "textures/segment2/segment2_cn.1B0F0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B100[] = { +#include "textures/segment2/segment2_cn.1B100.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B110[] = { +#include "textures/segment2/segment2_cn.1B110.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B120[] = { +#include "textures/segment2/segment2_cn.1B120.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B130[] = { +#include "textures/segment2/segment2_cn.1B130.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B140[] = { +#include "textures/segment2/segment2_cn.1B140.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B150[] = { +#include "textures/segment2/segment2_cn.1B150.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B160[] = { +#include "textures/segment2/segment2_cn.1B160.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B170[] = { +#include "textures/segment2/segment2_cn.1B170.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B180[] = { +#include "textures/segment2/segment2_cn.1B180.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B190[] = { +#include "textures/segment2/segment2_cn.1B190.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B1A0[] = { +#include "textures/segment2/segment2_cn.1B1A0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B1B0[] = { +#include "textures/segment2/segment2_cn.1B1B0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B1C0[] = { +#include "textures/segment2/segment2_cn.1B1C0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B1D0[] = { +#include "textures/segment2/segment2_cn.1B1D0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B1E0[] = { +#include "textures/segment2/segment2_cn.1B1E0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B1F0[] = { +#include "textures/segment2/segment2_cn.1B1F0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B200[] = { +#include "textures/segment2/segment2_cn.1B200.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B210[] = { +#include "textures/segment2/segment2_cn.1B210.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B220[] = { +#include "textures/segment2/segment2_cn.1B220.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B230[] = { +#include "textures/segment2/segment2_cn.1B230.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B240[] = { +#include "textures/segment2/segment2_cn.1B240.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B250[] = { +#include "textures/segment2/segment2_cn.1B250.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B260[] = { +#include "textures/segment2/segment2_cn.1B260.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B270[] = { +#include "textures/segment2/segment2_cn.1B270.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B280[] = { +#include "textures/segment2/segment2_cn.1B280.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B290[] = { +#include "textures/segment2/segment2_cn.1B290.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B2A0[] = { +#include "textures/segment2/segment2_cn.1B2A0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B2B0[] = { +#include "textures/segment2/segment2_cn.1B2B0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B2C0[] = { +#include "textures/segment2/segment2_cn.1B2C0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B2D0[] = { +#include "textures/segment2/segment2_cn.1B2D0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B2E0[] = { +#include "textures/segment2/segment2_cn.1B2E0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B2F0[] = { +#include "textures/segment2/segment2_cn.1B2F0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B300[] = { +#include "textures/segment2/segment2_cn.1B300.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B310[] = { +#include "textures/segment2/segment2_cn.1B310.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B320[] = { +#include "textures/segment2/segment2_cn.1B320.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B330[] = { +#include "textures/segment2/segment2_cn.1B330.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B340[] = { +#include "textures/segment2/segment2_cn.1B340.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B350[] = { +#include "textures/segment2/segment2_cn.1B350.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B360[] = { +#include "textures/segment2/segment2_cn.1B360.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B370[] = { +#include "textures/segment2/segment2_cn.1B370.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B380[] = { +#include "textures/segment2/segment2_cn.1B380.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B390[] = { +#include "textures/segment2/segment2_cn.1B390.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B3A0[] = { +#include "textures/segment2/segment2_cn.1B3A0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B3B0[] = { +#include "textures/segment2/segment2_cn.1B3B0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B3C0[] = { +#include "textures/segment2/segment2_cn.1B3C0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B3D0[] = { +#include "textures/segment2/segment2_cn.1B3D0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B3E0[] = { +#include "textures/segment2/segment2_cn.1B3E0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B3F0[] = { +#include "textures/segment2/segment2_cn.1B3F0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B400[] = { +#include "textures/segment2/segment2_cn.1B400.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B410[] = { +#include "textures/segment2/segment2_cn.1B410.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B420[] = { +#include "textures/segment2/segment2_cn.1B420.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B430[] = { +#include "textures/segment2/segment2_cn.1B430.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B440[] = { +#include "textures/segment2/segment2_cn.1B440.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B450[] = { +#include "textures/segment2/segment2_cn.1B450.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B460[] = { +#include "textures/segment2/segment2_cn.1B460.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B470[] = { +#include "textures/segment2/segment2_cn.1B470.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B480[] = { +#include "textures/segment2/segment2_cn.1B480.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B490[] = { +#include "textures/segment2/segment2_cn.1B490.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B4A0[] = { +#include "textures/segment2/segment2_cn.1B4A0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B4B0[] = { +#include "textures/segment2/segment2_cn.1B4B0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B4C0[] = { +#include "textures/segment2/segment2_cn.1B4C0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B4D0[] = { +#include "textures/segment2/segment2_cn.1B4D0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B4E0[] = { +#include "textures/segment2/segment2_cn.1B4E0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B4F0[] = { +#include "textures/segment2/segment2_cn.1B4F0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B500[] = { +#include "textures/segment2/segment2_cn.1B500.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B510[] = { +#include "textures/segment2/segment2_cn.1B510.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B520[] = { +#include "textures/segment2/segment2_cn.1B520.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B530[] = { +#include "textures/segment2/segment2_cn.1B530.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B540[] = { +#include "textures/segment2/segment2_cn.1B540.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B550[] = { +#include "textures/segment2/segment2_cn.1B550.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B560[] = { +#include "textures/segment2/segment2_cn.1B560.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B570[] = { +#include "textures/segment2/segment2_cn.1B570.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B580[] = { +#include "textures/segment2/segment2_cn.1B580.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B590[] = { +#include "textures/segment2/segment2_cn.1B590.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B5A0[] = { +#include "textures/segment2/segment2_cn.1B5A0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B5B0[] = { +#include "textures/segment2/segment2_cn.1B5B0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B5C0[] = { +#include "textures/segment2/segment2_cn.1B5C0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B5D0[] = { +#include "textures/segment2/segment2_cn.1B5D0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B5E0[] = { +#include "textures/segment2/segment2_cn.1B5E0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B5F0[] = { +#include "textures/segment2/segment2_cn.1B5F0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B600[] = { +#include "textures/segment2/segment2_cn.1B600.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B610[] = { +#include "textures/segment2/segment2_cn.1B610.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B620[] = { +#include "textures/segment2/segment2_cn.1B620.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B630[] = { +#include "textures/segment2/segment2_cn.1B630.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B640[] = { +#include "textures/segment2/segment2_cn.1B640.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B650[] = { +#include "textures/segment2/segment2_cn.1B650.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B660[] = { +#include "textures/segment2/segment2_cn.1B660.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B670[] = { +#include "textures/segment2/segment2_cn.1B670.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B680[] = { +#include "textures/segment2/segment2_cn.1B680.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B690[] = { +#include "textures/segment2/segment2_cn.1B690.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B6A0[] = { +#include "textures/segment2/segment2_cn.1B6A0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B6B0[] = { +#include "textures/segment2/segment2_cn.1B6B0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B6C0[] = { +#include "textures/segment2/segment2_cn.1B6C0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B6D0[] = { +#include "textures/segment2/segment2_cn.1B6D0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B6E0[] = { +#include "textures/segment2/segment2_cn.1B6E0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B6F0[] = { +#include "textures/segment2/segment2_cn.1B6F0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B700[] = { +#include "textures/segment2/segment2_cn.1B700.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B710[] = { +#include "textures/segment2/segment2_cn.1B710.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B720[] = { +#include "textures/segment2/segment2_cn.1B720.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B730[] = { +#include "textures/segment2/segment2_cn.1B730.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B740[] = { +#include "textures/segment2/segment2_cn.1B740.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B750[] = { +#include "textures/segment2/segment2_cn.1B750.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B760[] = { +#include "textures/segment2/segment2_cn.1B760.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B770[] = { +#include "textures/segment2/segment2_cn.1B770.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B780[] = { +#include "textures/segment2/segment2_cn.1B780.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B790[] = { +#include "textures/segment2/segment2_cn.1B790.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B7A0[] = { +#include "textures/segment2/segment2_cn.1B7A0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B7B0[] = { +#include "textures/segment2/segment2_cn.1B7B0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B7C0[] = { +#include "textures/segment2/segment2_cn.1B7C0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B7D0[] = { +#include "textures/segment2/segment2_cn.1B7D0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B7E0[] = { +#include "textures/segment2/segment2_cn.1B7E0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B7F0[] = { +#include "textures/segment2/segment2_cn.1B7F0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B800[] = { +#include "textures/segment2/segment2_cn.1B800.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B810[] = { +#include "textures/segment2/segment2_cn.1B810.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B820[] = { +#include "textures/segment2/segment2_cn.1B820.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B830[] = { +#include "textures/segment2/segment2_cn.1B830.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B840[] = { +#include "textures/segment2/segment2_cn.1B840.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B850[] = { +#include "textures/segment2/segment2_cn.1B850.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B860[] = { +#include "textures/segment2/segment2_cn.1B860.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B870[] = { +#include "textures/segment2/segment2_cn.1B870.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B880[] = { +#include "textures/segment2/segment2_cn.1B880.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B890[] = { +#include "textures/segment2/segment2_cn.1B890.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B8A0[] = { +#include "textures/segment2/segment2_cn.1B8A0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B8B0[] = { +#include "textures/segment2/segment2_cn.1B8B0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B8C0[] = { +#include "textures/segment2/segment2_cn.1B8C0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B8D0[] = { +#include "textures/segment2/segment2_cn.1B8D0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B8E0[] = { +#include "textures/segment2/segment2_cn.1B8E0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B8F0[] = { +#include "textures/segment2/segment2_cn.1B8F0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B900[] = { +#include "textures/segment2/segment2_cn.1B900.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B910[] = { +#include "textures/segment2/segment2_cn.1B910.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B920[] = { +#include "textures/segment2/segment2_cn.1B920.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B930[] = { +#include "textures/segment2/segment2_cn.1B930.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B940[] = { +#include "textures/segment2/segment2_cn.1B940.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B950[] = { +#include "textures/segment2/segment2_cn.1B950.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B960[] = { +#include "textures/segment2/segment2_cn.1B960.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B970[] = { +#include "textures/segment2/segment2_cn.1B970.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B980[] = { +#include "textures/segment2/segment2_cn.1B980.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B990[] = { +#include "textures/segment2/segment2_cn.1B990.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B9A0[] = { +#include "textures/segment2/segment2_cn.1B9A0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B9B0[] = { +#include "textures/segment2/segment2_cn.1B9B0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B9C0[] = { +#include "textures/segment2/segment2_cn.1B9C0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B9D0[] = { +#include "textures/segment2/segment2_cn.1B9D0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B9E0[] = { +#include "textures/segment2/segment2_cn.1B9E0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1B9F0[] = { +#include "textures/segment2/segment2_cn.1B9F0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1BA00[] = { +#include "textures/segment2/segment2_cn.1BA00.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1BA10[] = { +#include "textures/segment2/segment2_cn.1BA10.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1BA20[] = { +#include "textures/segment2/segment2_cn.1BA20.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1BA30[] = { +#include "textures/segment2/segment2_cn.1BA30.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1BA40[] = { +#include "textures/segment2/segment2_cn.1BA40.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1BA50[] = { +#include "textures/segment2/segment2_cn.1BA50.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1BA60[] = { +#include "textures/segment2/segment2_cn.1BA60.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1BA70[] = { +#include "textures/segment2/segment2_cn.1BA70.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1BA80[] = { +#include "textures/segment2/segment2_cn.1BA80.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1BA90[] = { +#include "textures/segment2/segment2_cn.1BA90.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1BAA0[] = { +#include "textures/segment2/segment2_cn.1BAA0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1BAB0[] = { +#include "textures/segment2/segment2_cn.1BAB0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1BAC0[] = { +#include "textures/segment2/segment2_cn.1BAC0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1BAD0[] = { +#include "textures/segment2/segment2_cn.1BAD0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1BAE0[] = { +#include "textures/segment2/segment2_cn.1BAE0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1BAF0[] = { +#include "textures/segment2/segment2_cn.1BAF0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1BB00[] = { +#include "textures/segment2/segment2_cn.1BB00.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1BB10[] = { +#include "textures/segment2/segment2_cn.1BB10.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1BB20[] = { +#include "textures/segment2/segment2_cn.1BB20.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1BB30[] = { +#include "textures/segment2/segment2_cn.1BB30.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1BB40[] = { +#include "textures/segment2/segment2_cn.1BB40.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1BB50[] = { +#include "textures/segment2/segment2_cn.1BB50.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1BB60[] = { +#include "textures/segment2/segment2_cn.1BB60.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1BB70[] = { +#include "textures/segment2/segment2_cn.1BB70.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1BB80[] = { +#include "textures/segment2/segment2_cn.1BB80.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1BB90[] = { +#include "textures/segment2/segment2_cn.1BB90.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1BBA0[] = { +#include "textures/segment2/segment2_cn.1BBA0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1BBB0[] = { +#include "textures/segment2/segment2_cn.1BBB0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1BBC0[] = { +#include "textures/segment2/segment2_cn.1BBC0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1BBD0[] = { +#include "textures/segment2/segment2_cn.1BBD0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1BBE0[] = { +#include "textures/segment2/segment2_cn.1BBE0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1BBF0[] = { +#include "textures/segment2/segment2_cn.1BBF0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1BC00[] = { +#include "textures/segment2/segment2_cn.1BC00.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1BC10[] = { +#include "textures/segment2/segment2_cn.1BC10.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1BC20[] = { +#include "textures/segment2/segment2_cn.1BC20.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1BC30[] = { +#include "textures/segment2/segment2_cn.1BC30.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1BC40[] = { +#include "textures/segment2/segment2_cn.1BC40.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1BC50[] = { +#include "textures/segment2/segment2_cn.1BC50.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1BC60[] = { +#include "textures/segment2/segment2_cn.1BC60.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1BC70[] = { +#include "textures/segment2/segment2_cn.1BC70.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1BC80[] = { +#include "textures/segment2/segment2_cn.1BC80.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1BC90[] = { +#include "textures/segment2/segment2_cn.1BC90.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1BCA0[] = { +#include "textures/segment2/segment2_cn.1BCA0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1BCB0[] = { +#include "textures/segment2/segment2_cn.1BCB0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1BCC0[] = { +#include "textures/segment2/segment2_cn.1BCC0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1BCD0[] = { +#include "textures/segment2/segment2_cn.1BCD0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1BCE0[] = { +#include "textures/segment2/segment2_cn.1BCE0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1BCF0[] = { +#include "textures/segment2/segment2_cn.1BCF0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1BD00[] = { +#include "textures/segment2/segment2_cn.1BD00.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1BD10[] = { +#include "textures/segment2/segment2_cn.1BD10.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1BD20[] = { +#include "textures/segment2/segment2_cn.1BD20.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1BD30[] = { +#include "textures/segment2/segment2_cn.1BD30.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1BD40[] = { +#include "textures/segment2/segment2_cn.1BD40.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1BD50[] = { +#include "textures/segment2/segment2_cn.1BD50.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1BD60[] = { +#include "textures/segment2/segment2_cn.1BD60.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1BD70[] = { +#include "textures/segment2/segment2_cn.1BD70.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1BD80[] = { +#include "textures/segment2/segment2_cn.1BD80.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1BD90[] = { +#include "textures/segment2/segment2_cn.1BD90.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1BDA0[] = { +#include "textures/segment2/segment2_cn.1BDA0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1BDB0[] = { +#include "textures/segment2/segment2_cn.1BDB0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1BDC0[] = { +#include "textures/segment2/segment2_cn.1BDC0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1BDD0[] = { +#include "textures/segment2/segment2_cn.1BDD0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1BDE0[] = { +#include "textures/segment2/segment2_cn.1BDE0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1BDF0[] = { +#include "textures/segment2/segment2_cn.1BDF0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1BE00[] = { +#include "textures/segment2/segment2_cn.1BE00.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1BE10[] = { +#include "textures/segment2/segment2_cn.1BE10.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1BE20[] = { +#include "textures/segment2/segment2_cn.1BE20.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1BE30[] = { +#include "textures/segment2/segment2_cn.1BE30.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1BE40[] = { +#include "textures/segment2/segment2_cn.1BE40.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1BE50[] = { +#include "textures/segment2/segment2_cn.1BE50.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1BE60[] = { +#include "textures/segment2/segment2_cn.1BE60.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1BE70[] = { +#include "textures/segment2/segment2_cn.1BE70.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1BE80[] = { +#include "textures/segment2/segment2_cn.1BE80.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1BE90[] = { +#include "textures/segment2/segment2_cn.1BE90.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1BEA0[] = { +#include "textures/segment2/segment2_cn.1BEA0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1BEB0[] = { +#include "textures/segment2/segment2_cn.1BEB0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1BEC0[] = { +#include "textures/segment2/segment2_cn.1BEC0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1BED0[] = { +#include "textures/segment2/segment2_cn.1BED0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1BEE0[] = { +#include "textures/segment2/segment2_cn.1BEE0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1BEF0[] = { +#include "textures/segment2/segment2_cn.1BEF0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1BF00[] = { +#include "textures/segment2/segment2_cn.1BF00.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1BF10[] = { +#include "textures/segment2/segment2_cn.1BF10.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1BF20[] = { +#include "textures/segment2/segment2_cn.1BF20.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1BF30[] = { +#include "textures/segment2/segment2_cn.1BF30.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1BF40[] = { +#include "textures/segment2/segment2_cn.1BF40.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1BF50[] = { +#include "textures/segment2/segment2_cn.1BF50.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1BF60[] = { +#include "textures/segment2/segment2_cn.1BF60.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1BF70[] = { +#include "textures/segment2/segment2_cn.1BF70.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1BF80[] = { +#include "textures/segment2/segment2_cn.1BF80.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1BF90[] = { +#include "textures/segment2/segment2_cn.1BF90.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1BFA0[] = { +#include "textures/segment2/segment2_cn.1BFA0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1BFB0[] = { +#include "textures/segment2/segment2_cn.1BFB0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1BFC0[] = { +#include "textures/segment2/segment2_cn.1BFC0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1BFD0[] = { +#include "textures/segment2/segment2_cn.1BFD0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1BFE0[] = { +#include "textures/segment2/segment2_cn.1BFE0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1BFF0[] = { +#include "textures/segment2/segment2_cn.1BFF0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C000[] = { +#include "textures/segment2/segment2_cn.1C000.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C010[] = { +#include "textures/segment2/segment2_cn.1C010.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C020[] = { +#include "textures/segment2/segment2_cn.1C020.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C030[] = { +#include "textures/segment2/segment2_cn.1C030.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C040[] = { +#include "textures/segment2/segment2_cn.1C040.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C050[] = { +#include "textures/segment2/segment2_cn.1C050.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C060[] = { +#include "textures/segment2/segment2_cn.1C060.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C070[] = { +#include "textures/segment2/segment2_cn.1C070.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C080[] = { +#include "textures/segment2/segment2_cn.1C080.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C090[] = { +#include "textures/segment2/segment2_cn.1C090.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C0A0[] = { +#include "textures/segment2/segment2_cn.1C0A0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C0B0[] = { +#include "textures/segment2/segment2_cn.1C0B0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C0C0[] = { +#include "textures/segment2/segment2_cn.1C0C0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C0D0[] = { +#include "textures/segment2/segment2_cn.1C0D0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C0E0[] = { +#include "textures/segment2/segment2_cn.1C0E0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C0F0[] = { +#include "textures/segment2/segment2_cn.1C0F0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C100[] = { +#include "textures/segment2/segment2_cn.1C100.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C110[] = { +#include "textures/segment2/segment2_cn.1C110.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C120[] = { +#include "textures/segment2/segment2_cn.1C120.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C130[] = { +#include "textures/segment2/segment2_cn.1C130.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C140[] = { +#include "textures/segment2/segment2_cn.1C140.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C150[] = { +#include "textures/segment2/segment2_cn.1C150.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C160[] = { +#include "textures/segment2/segment2_cn.1C160.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C170[] = { +#include "textures/segment2/segment2_cn.1C170.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C180[] = { +#include "textures/segment2/segment2_cn.1C180.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C190[] = { +#include "textures/segment2/segment2_cn.1C190.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C1A0[] = { +#include "textures/segment2/segment2_cn.1C1A0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C1B0[] = { +#include "textures/segment2/segment2_cn.1C1B0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C1C0[] = { +#include "textures/segment2/segment2_cn.1C1C0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C1D0[] = { +#include "textures/segment2/segment2_cn.1C1D0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C1E0[] = { +#include "textures/segment2/segment2_cn.1C1E0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C1F0[] = { +#include "textures/segment2/segment2_cn.1C1F0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C200[] = { +#include "textures/segment2/segment2_cn.1C200.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C210[] = { +#include "textures/segment2/segment2_cn.1C210.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C220[] = { +#include "textures/segment2/segment2_cn.1C220.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C230[] = { +#include "textures/segment2/segment2_cn.1C230.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C240[] = { +#include "textures/segment2/segment2_cn.1C240.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C250[] = { +#include "textures/segment2/segment2_cn.1C250.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C260[] = { +#include "textures/segment2/segment2_cn.1C260.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C270[] = { +#include "textures/segment2/segment2_cn.1C270.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C280[] = { +#include "textures/segment2/segment2_cn.1C280.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C290[] = { +#include "textures/segment2/segment2_cn.1C290.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C2A0[] = { +#include "textures/segment2/segment2_cn.1C2A0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C2B0[] = { +#include "textures/segment2/segment2_cn.1C2B0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C2C0[] = { +#include "textures/segment2/segment2_cn.1C2C0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C2D0[] = { +#include "textures/segment2/segment2_cn.1C2D0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C2E0[] = { +#include "textures/segment2/segment2_cn.1C2E0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C2F0[] = { +#include "textures/segment2/segment2_cn.1C2F0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C300[] = { +#include "textures/segment2/segment2_cn.1C300.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C310[] = { +#include "textures/segment2/segment2_cn.1C310.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C320[] = { +#include "textures/segment2/segment2_cn.1C320.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C330[] = { +#include "textures/segment2/segment2_cn.1C330.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C340[] = { +#include "textures/segment2/segment2_cn.1C340.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C350[] = { +#include "textures/segment2/segment2_cn.1C350.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C360[] = { +#include "textures/segment2/segment2_cn.1C360.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C370[] = { +#include "textures/segment2/segment2_cn.1C370.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C380[] = { +#include "textures/segment2/segment2_cn.1C380.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C390[] = { +#include "textures/segment2/segment2_cn.1C390.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C3A0[] = { +#include "textures/segment2/segment2_cn.1C3A0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C3B0[] = { +#include "textures/segment2/segment2_cn.1C3B0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C3C0[] = { +#include "textures/segment2/segment2_cn.1C3C0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C3D0[] = { +#include "textures/segment2/segment2_cn.1C3D0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C3E0[] = { +#include "textures/segment2/segment2_cn.1C3E0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C3F0[] = { +#include "textures/segment2/segment2_cn.1C3F0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C400[] = { +#include "textures/segment2/segment2_cn.1C400.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C410[] = { +#include "textures/segment2/segment2_cn.1C410.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C420[] = { +#include "textures/segment2/segment2_cn.1C420.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C430[] = { +#include "textures/segment2/segment2_cn.1C430.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C440[] = { +#include "textures/segment2/segment2_cn.1C440.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C450[] = { +#include "textures/segment2/segment2_cn.1C450.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C460[] = { +#include "textures/segment2/segment2_cn.1C460.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C470[] = { +#include "textures/segment2/segment2_cn.1C470.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C480[] = { +#include "textures/segment2/segment2_cn.1C480.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C490[] = { +#include "textures/segment2/segment2_cn.1C490.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C4A0[] = { +#include "textures/segment2/segment2_cn.1C4A0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C4B0[] = { +#include "textures/segment2/segment2_cn.1C4B0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C4C0[] = { +#include "textures/segment2/segment2_cn.1C4C0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C4D0[] = { +#include "textures/segment2/segment2_cn.1C4D0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C4E0[] = { +#include "textures/segment2/segment2_cn.1C4E0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C4F0[] = { +#include "textures/segment2/segment2_cn.1C4F0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C500[] = { +#include "textures/segment2/segment2_cn.1C500.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C510[] = { +#include "textures/segment2/segment2_cn.1C510.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C520[] = { +#include "textures/segment2/segment2_cn.1C520.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C530[] = { +#include "textures/segment2/segment2_cn.1C530.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C540[] = { +#include "textures/segment2/segment2_cn.1C540.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C550[] = { +#include "textures/segment2/segment2_cn.1C550.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C560[] = { +#include "textures/segment2/segment2_cn.1C560.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C570[] = { +#include "textures/segment2/segment2_cn.1C570.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C580[] = { +#include "textures/segment2/segment2_cn.1C580.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C590[] = { +#include "textures/segment2/segment2_cn.1C590.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C5A0[] = { +#include "textures/segment2/segment2_cn.1C5A0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C5B0[] = { +#include "textures/segment2/segment2_cn.1C5B0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C5C0[] = { +#include "textures/segment2/segment2_cn.1C5C0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C5D0[] = { +#include "textures/segment2/segment2_cn.1C5D0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C5E0[] = { +#include "textures/segment2/segment2_cn.1C5E0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C5F0[] = { +#include "textures/segment2/segment2_cn.1C5F0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C600[] = { +#include "textures/segment2/segment2_cn.1C600.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C610[] = { +#include "textures/segment2/segment2_cn.1C610.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C620[] = { +#include "textures/segment2/segment2_cn.1C620.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C630[] = { +#include "textures/segment2/segment2_cn.1C630.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C640[] = { +#include "textures/segment2/segment2_cn.1C640.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C650[] = { +#include "textures/segment2/segment2_cn.1C650.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C660[] = { +#include "textures/segment2/segment2_cn.1C660.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C670[] = { +#include "textures/segment2/segment2_cn.1C670.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C680[] = { +#include "textures/segment2/segment2_cn.1C680.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C690[] = { +#include "textures/segment2/segment2_cn.1C690.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C6A0[] = { +#include "textures/segment2/segment2_cn.1C6A0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C6B0[] = { +#include "textures/segment2/segment2_cn.1C6B0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C6C0[] = { +#include "textures/segment2/segment2_cn.1C6C0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C6D0[] = { +#include "textures/segment2/segment2_cn.1C6D0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C6E0[] = { +#include "textures/segment2/segment2_cn.1C6E0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C6F0[] = { +#include "textures/segment2/segment2_cn.1C6F0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C700[] = { +#include "textures/segment2/segment2_cn.1C700.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C710[] = { +#include "textures/segment2/segment2_cn.1C710.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C720[] = { +#include "textures/segment2/segment2_cn.1C720.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C730[] = { +#include "textures/segment2/segment2_cn.1C730.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C740[] = { +#include "textures/segment2/segment2_cn.1C740.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C750[] = { +#include "textures/segment2/segment2_cn.1C750.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C760[] = { +#include "textures/segment2/segment2_cn.1C760.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C770[] = { +#include "textures/segment2/segment2_cn.1C770.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C780[] = { +#include "textures/segment2/segment2_cn.1C780.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C790[] = { +#include "textures/segment2/segment2_cn.1C790.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C7A0[] = { +#include "textures/segment2/segment2_cn.1C7A0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C7B0[] = { +#include "textures/segment2/segment2_cn.1C7B0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C7C0[] = { +#include "textures/segment2/segment2_cn.1C7C0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C7D0[] = { +#include "textures/segment2/segment2_cn.1C7D0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C7E0[] = { +#include "textures/segment2/segment2_cn.1C7E0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C7F0[] = { +#include "textures/segment2/segment2_cn.1C7F0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C800[] = { +#include "textures/segment2/segment2_cn.1C800.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C810[] = { +#include "textures/segment2/segment2_cn.1C810.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C820[] = { +#include "textures/segment2/segment2_cn.1C820.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C830[] = { +#include "textures/segment2/segment2_cn.1C830.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C840[] = { +#include "textures/segment2/segment2_cn.1C840.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C850[] = { +#include "textures/segment2/segment2_cn.1C850.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C860[] = { +#include "textures/segment2/segment2_cn.1C860.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C870[] = { +#include "textures/segment2/segment2_cn.1C870.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C880[] = { +#include "textures/segment2/segment2_cn.1C880.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C890[] = { +#include "textures/segment2/segment2_cn.1C890.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C8A0[] = { +#include "textures/segment2/segment2_cn.1C8A0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C8B0[] = { +#include "textures/segment2/segment2_cn.1C8B0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C8C0[] = { +#include "textures/segment2/segment2_cn.1C8C0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C8D0[] = { +#include "textures/segment2/segment2_cn.1C8D0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C8E0[] = { +#include "textures/segment2/segment2_cn.1C8E0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C8F0[] = { +#include "textures/segment2/segment2_cn.1C8F0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C900[] = { +#include "textures/segment2/segment2_cn.1C900.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C910[] = { +#include "textures/segment2/segment2_cn.1C910.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C920[] = { +#include "textures/segment2/segment2_cn.1C920.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C930[] = { +#include "textures/segment2/segment2_cn.1C930.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C940[] = { +#include "textures/segment2/segment2_cn.1C940.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C950[] = { +#include "textures/segment2/segment2_cn.1C950.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C960[] = { +#include "textures/segment2/segment2_cn.1C960.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C970[] = { +#include "textures/segment2/segment2_cn.1C970.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C980[] = { +#include "textures/segment2/segment2_cn.1C980.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C990[] = { +#include "textures/segment2/segment2_cn.1C990.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C9A0[] = { +#include "textures/segment2/segment2_cn.1C9A0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C9B0[] = { +#include "textures/segment2/segment2_cn.1C9B0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C9C0[] = { +#include "textures/segment2/segment2_cn.1C9C0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C9D0[] = { +#include "textures/segment2/segment2_cn.1C9D0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C9E0[] = { +#include "textures/segment2/segment2_cn.1C9E0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1C9F0[] = { +#include "textures/segment2/segment2_cn.1C9F0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1CA00[] = { +#include "textures/segment2/segment2_cn.1CA00.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1CA10[] = { +#include "textures/segment2/segment2_cn.1CA10.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1CA20[] = { +#include "textures/segment2/segment2_cn.1CA20.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1CA30[] = { +#include "textures/segment2/segment2_cn.1CA30.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1CA40[] = { +#include "textures/segment2/segment2_cn.1CA40.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1CA50[] = { +#include "textures/segment2/segment2_cn.1CA50.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1CA60[] = { +#include "textures/segment2/segment2_cn.1CA60.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1CA70[] = { +#include "textures/segment2/segment2_cn.1CA70.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1CA80[] = { +#include "textures/segment2/segment2_cn.1CA80.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1CA90[] = { +#include "textures/segment2/segment2_cn.1CA90.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1CAA0[] = { +#include "textures/segment2/segment2_cn.1CAA0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1CAB0[] = { +#include "textures/segment2/segment2_cn.1CAB0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1CAC0[] = { +#include "textures/segment2/segment2_cn.1CAC0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1CAD0[] = { +#include "textures/segment2/segment2_cn.1CAD0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1CAE0[] = { +#include "textures/segment2/segment2_cn.1CAE0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1CAF0[] = { +#include "textures/segment2/segment2_cn.1CAF0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1CB00[] = { +#include "textures/segment2/segment2_cn.1CB00.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1CB10[] = { +#include "textures/segment2/segment2_cn.1CB10.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1CB20[] = { +#include "textures/segment2/segment2_cn.1CB20.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1CB30[] = { +#include "textures/segment2/segment2_cn.1CB30.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1CB40[] = { +#include "textures/segment2/segment2_cn.1CB40.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1CB50[] = { +#include "textures/segment2/segment2_cn.1CB50.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1CB60[] = { +#include "textures/segment2/segment2_cn.1CB60.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1CB70[] = { +#include "textures/segment2/segment2_cn.1CB70.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1CB80[] = { +#include "textures/segment2/segment2_cn.1CB80.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1CB90[] = { +#include "textures/segment2/segment2_cn.1CB90.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1CBA0[] = { +#include "textures/segment2/segment2_cn.1CBA0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1CBB0[] = { +#include "textures/segment2/segment2_cn.1CBB0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1CBC0[] = { +#include "textures/segment2/segment2_cn.1CBC0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1CBD0[] = { +#include "textures/segment2/segment2_cn.1CBD0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1CBE0[] = { +#include "textures/segment2/segment2_cn.1CBE0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1CBF0[] = { +#include "textures/segment2/segment2_cn.1CBF0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1CC00[] = { +#include "textures/segment2/segment2_cn.1CC00.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1CC10[] = { +#include "textures/segment2/segment2_cn.1CC10.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1CC20[] = { +#include "textures/segment2/segment2_cn.1CC20.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1CC30[] = { +#include "textures/segment2/segment2_cn.1CC30.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1CC40[] = { +#include "textures/segment2/segment2_cn.1CC40.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1CC50[] = { +#include "textures/segment2/segment2_cn.1CC50.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1CC60[] = { +#include "textures/segment2/segment2_cn.1CC60.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1CC70[] = { +#include "textures/segment2/segment2_cn.1CC70.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1CC80[] = { +#include "textures/segment2/segment2_cn.1CC80.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1CC90[] = { +#include "textures/segment2/segment2_cn.1CC90.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1CCA0[] = { +#include "textures/segment2/segment2_cn.1CCA0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1CCB0[] = { +#include "textures/segment2/segment2_cn.1CCB0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1CCC0[] = { +#include "textures/segment2/segment2_cn.1CCC0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1CCD0[] = { +#include "textures/segment2/segment2_cn.1CCD0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1CCE0[] = { +#include "textures/segment2/segment2_cn.1CCE0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1CCF0[] = { +#include "textures/segment2/segment2_cn.1CCF0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1CD00[] = { +#include "textures/segment2/segment2_cn.1CD00.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1CD10[] = { +#include "textures/segment2/segment2_cn.1CD10.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1CD20[] = { +#include "textures/segment2/segment2_cn.1CD20.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1CD30[] = { +#include "textures/segment2/segment2_cn.1CD30.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1CD40[] = { +#include "textures/segment2/segment2_cn.1CD40.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1CD50[] = { +#include "textures/segment2/segment2_cn.1CD50.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1CD60[] = { +#include "textures/segment2/segment2_cn.1CD60.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1CD70[] = { +#include "textures/segment2/segment2_cn.1CD70.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1CD80[] = { +#include "textures/segment2/segment2_cn.1CD80.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1CD90[] = { +#include "textures/segment2/segment2_cn.1CD90.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1CDA0[] = { +#include "textures/segment2/segment2_cn.1CDA0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1CDB0[] = { +#include "textures/segment2/segment2_cn.1CDB0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1CDC0[] = { +#include "textures/segment2/segment2_cn.1CDC0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1CDD0[] = { +#include "textures/segment2/segment2_cn.1CDD0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1CDE0[] = { +#include "textures/segment2/segment2_cn.1CDE0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1CDF0[] = { +#include "textures/segment2/segment2_cn.1CDF0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1CE00[] = { +#include "textures/segment2/segment2_cn.1CE00.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1CE10[] = { +#include "textures/segment2/segment2_cn.1CE10.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1CE20[] = { +#include "textures/segment2/segment2_cn.1CE20.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1CE30[] = { +#include "textures/segment2/segment2_cn.1CE30.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1CE40[] = { +#include "textures/segment2/segment2_cn.1CE40.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1CE50[] = { +#include "textures/segment2/segment2_cn.1CE50.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1CE60[] = { +#include "textures/segment2/segment2_cn.1CE60.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1CE70[] = { +#include "textures/segment2/segment2_cn.1CE70.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1CE80[] = { +#include "textures/segment2/segment2_cn.1CE80.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1CE90[] = { +#include "textures/segment2/segment2_cn.1CE90.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1CEA0[] = { +#include "textures/segment2/segment2_cn.1CEA0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1CEB0[] = { +#include "textures/segment2/segment2_cn.1CEB0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1CEC0[] = { +#include "textures/segment2/segment2_cn.1CEC0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1CED0[] = { +#include "textures/segment2/segment2_cn.1CED0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1CEE0[] = { +#include "textures/segment2/segment2_cn.1CEE0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1CEF0[] = { +#include "textures/segment2/segment2_cn.1CEF0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1CF00[] = { +#include "textures/segment2/segment2_cn.1CF00.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1CF10[] = { +#include "textures/segment2/segment2_cn.1CF10.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1CF20[] = { +#include "textures/segment2/segment2_cn.1CF20.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1CF30[] = { +#include "textures/segment2/segment2_cn.1CF30.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1CF40[] = { +#include "textures/segment2/segment2_cn.1CF40.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1CF50[] = { +#include "textures/segment2/segment2_cn.1CF50.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1CF60[] = { +#include "textures/segment2/segment2_cn.1CF60.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1CF70[] = { +#include "textures/segment2/segment2_cn.1CF70.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1CF80[] = { +#include "textures/segment2/segment2_cn.1CF80.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1CF90[] = { +#include "textures/segment2/segment2_cn.1CF90.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1CFA0[] = { +#include "textures/segment2/segment2_cn.1CFA0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1CFB0[] = { +#include "textures/segment2/segment2_cn.1CFB0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1CFC0[] = { +#include "textures/segment2/segment2_cn.1CFC0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1CFD0[] = { +#include "textures/segment2/segment2_cn.1CFD0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1CFE0[] = { +#include "textures/segment2/segment2_cn.1CFE0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1CFF0[] = { +#include "textures/segment2/segment2_cn.1CFF0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D000[] = { +#include "textures/segment2/segment2_cn.1D000.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D010[] = { +#include "textures/segment2/segment2_cn.1D010.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D020[] = { +#include "textures/segment2/segment2_cn.1D020.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D030[] = { +#include "textures/segment2/segment2_cn.1D030.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D040[] = { +#include "textures/segment2/segment2_cn.1D040.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D050[] = { +#include "textures/segment2/segment2_cn.1D050.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D060[] = { +#include "textures/segment2/segment2_cn.1D060.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D070[] = { +#include "textures/segment2/segment2_cn.1D070.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D080[] = { +#include "textures/segment2/segment2_cn.1D080.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D090[] = { +#include "textures/segment2/segment2_cn.1D090.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D0A0[] = { +#include "textures/segment2/segment2_cn.1D0A0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D0B0[] = { +#include "textures/segment2/segment2_cn.1D0B0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D0C0[] = { +#include "textures/segment2/segment2_cn.1D0C0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D0D0[] = { +#include "textures/segment2/segment2_cn.1D0D0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D0E0[] = { +#include "textures/segment2/segment2_cn.1D0E0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D0F0[] = { +#include "textures/segment2/segment2_cn.1D0F0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D100[] = { +#include "textures/segment2/segment2_cn.1D100.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D110[] = { +#include "textures/segment2/segment2_cn.1D110.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D120[] = { +#include "textures/segment2/segment2_cn.1D120.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D130[] = { +#include "textures/segment2/segment2_cn.1D130.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D140[] = { +#include "textures/segment2/segment2_cn.1D140.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D150[] = { +#include "textures/segment2/segment2_cn.1D150.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D160[] = { +#include "textures/segment2/segment2_cn.1D160.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D170[] = { +#include "textures/segment2/segment2_cn.1D170.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D180[] = { +#include "textures/segment2/segment2_cn.1D180.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D190[] = { +#include "textures/segment2/segment2_cn.1D190.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D1A0[] = { +#include "textures/segment2/segment2_cn.1D1A0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D1B0[] = { +#include "textures/segment2/segment2_cn.1D1B0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D1C0[] = { +#include "textures/segment2/segment2_cn.1D1C0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D1D0[] = { +#include "textures/segment2/segment2_cn.1D1D0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D1E0[] = { +#include "textures/segment2/segment2_cn.1D1E0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D1F0[] = { +#include "textures/segment2/segment2_cn.1D1F0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D200[] = { +#include "textures/segment2/segment2_cn.1D200.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D210[] = { +#include "textures/segment2/segment2_cn.1D210.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D220[] = { +#include "textures/segment2/segment2_cn.1D220.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D230[] = { +#include "textures/segment2/segment2_cn.1D230.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D240[] = { +#include "textures/segment2/segment2_cn.1D240.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D250[] = { +#include "textures/segment2/segment2_cn.1D250.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D260[] = { +#include "textures/segment2/segment2_cn.1D260.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D270[] = { +#include "textures/segment2/segment2_cn.1D270.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D280[] = { +#include "textures/segment2/segment2_cn.1D280.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D290[] = { +#include "textures/segment2/segment2_cn.1D290.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D2A0[] = { +#include "textures/segment2/segment2_cn.1D2A0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D2B0[] = { +#include "textures/segment2/segment2_cn.1D2B0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D2C0[] = { +#include "textures/segment2/segment2_cn.1D2C0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D2D0[] = { +#include "textures/segment2/segment2_cn.1D2D0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D2E0[] = { +#include "textures/segment2/segment2_cn.1D2E0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D2F0[] = { +#include "textures/segment2/segment2_cn.1D2F0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D300[] = { +#include "textures/segment2/segment2_cn.1D300.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D310[] = { +#include "textures/segment2/segment2_cn.1D310.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D320[] = { +#include "textures/segment2/segment2_cn.1D320.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D330[] = { +#include "textures/segment2/segment2_cn.1D330.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D340[] = { +#include "textures/segment2/segment2_cn.1D340.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D350[] = { +#include "textures/segment2/segment2_cn.1D350.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D360[] = { +#include "textures/segment2/segment2_cn.1D360.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D370[] = { +#include "textures/segment2/segment2_cn.1D370.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D380[] = { +#include "textures/segment2/segment2_cn.1D380.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D390[] = { +#include "textures/segment2/segment2_cn.1D390.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D3A0[] = { +#include "textures/segment2/segment2_cn.1D3A0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D3B0[] = { +#include "textures/segment2/segment2_cn.1D3B0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D3C0[] = { +#include "textures/segment2/segment2_cn.1D3C0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D3D0[] = { +#include "textures/segment2/segment2_cn.1D3D0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D3E0[] = { +#include "textures/segment2/segment2_cn.1D3E0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D3F0[] = { +#include "textures/segment2/segment2_cn.1D3F0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D400[] = { +#include "textures/segment2/segment2_cn.1D400.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D410[] = { +#include "textures/segment2/segment2_cn.1D410.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D420[] = { +#include "textures/segment2/segment2_cn.1D420.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D430[] = { +#include "textures/segment2/segment2_cn.1D430.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D440[] = { +#include "textures/segment2/segment2_cn.1D440.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D450[] = { +#include "textures/segment2/segment2_cn.1D450.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D460[] = { +#include "textures/segment2/segment2_cn.1D460.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D470[] = { +#include "textures/segment2/segment2_cn.1D470.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D480[] = { +#include "textures/segment2/segment2_cn.1D480.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D490[] = { +#include "textures/segment2/segment2_cn.1D490.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D4A0[] = { +#include "textures/segment2/segment2_cn.1D4A0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D4B0[] = { +#include "textures/segment2/segment2_cn.1D4B0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D4C0[] = { +#include "textures/segment2/segment2_cn.1D4C0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D4D0[] = { +#include "textures/segment2/segment2_cn.1D4D0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D4E0[] = { +#include "textures/segment2/segment2_cn.1D4E0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D4F0[] = { +#include "textures/segment2/segment2_cn.1D4F0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D500[] = { +#include "textures/segment2/segment2_cn.1D500.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D510[] = { +#include "textures/segment2/segment2_cn.1D510.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D520[] = { +#include "textures/segment2/segment2_cn.1D520.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D530[] = { +#include "textures/segment2/segment2_cn.1D530.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D540[] = { +#include "textures/segment2/segment2_cn.1D540.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D550[] = { +#include "textures/segment2/segment2_cn.1D550.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D560[] = { +#include "textures/segment2/segment2_cn.1D560.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D570[] = { +#include "textures/segment2/segment2_cn.1D570.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D580[] = { +#include "textures/segment2/segment2_cn.1D580.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D590[] = { +#include "textures/segment2/segment2_cn.1D590.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D5A0[] = { +#include "textures/segment2/segment2_cn.1D5A0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D5B0[] = { +#include "textures/segment2/segment2_cn.1D5B0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D5C0[] = { +#include "textures/segment2/segment2_cn.1D5C0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D5D0[] = { +#include "textures/segment2/segment2_cn.1D5D0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D5E0[] = { +#include "textures/segment2/segment2_cn.1D5E0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D5F0[] = { +#include "textures/segment2/segment2_cn.1D5F0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D600[] = { +#include "textures/segment2/segment2_cn.1D600.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D610[] = { +#include "textures/segment2/segment2_cn.1D610.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D620[] = { +#include "textures/segment2/segment2_cn.1D620.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D630[] = { +#include "textures/segment2/segment2_cn.1D630.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D640[] = { +#include "textures/segment2/segment2_cn.1D640.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D650[] = { +#include "textures/segment2/segment2_cn.1D650.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D660[] = { +#include "textures/segment2/segment2_cn.1D660.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D670[] = { +#include "textures/segment2/segment2_cn.1D670.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D680[] = { +#include "textures/segment2/segment2_cn.1D680.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D690[] = { +#include "textures/segment2/segment2_cn.1D690.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D6A0[] = { +#include "textures/segment2/segment2_cn.1D6A0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D6B0[] = { +#include "textures/segment2/segment2_cn.1D6B0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D6C0[] = { +#include "textures/segment2/segment2_cn.1D6C0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D6D0[] = { +#include "textures/segment2/segment2_cn.1D6D0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D6E0[] = { +#include "textures/segment2/segment2_cn.1D6E0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D6F0[] = { +#include "textures/segment2/segment2_cn.1D6F0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D700[] = { +#include "textures/segment2/segment2_cn.1D700.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D710[] = { +#include "textures/segment2/segment2_cn.1D710.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D720[] = { +#include "textures/segment2/segment2_cn.1D720.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D730[] = { +#include "textures/segment2/segment2_cn.1D730.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D740[] = { +#include "textures/segment2/segment2_cn.1D740.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D750[] = { +#include "textures/segment2/segment2_cn.1D750.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D760[] = { +#include "textures/segment2/segment2_cn.1D760.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D770[] = { +#include "textures/segment2/segment2_cn.1D770.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D780[] = { +#include "textures/segment2/segment2_cn.1D780.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D790[] = { +#include "textures/segment2/segment2_cn.1D790.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D7A0[] = { +#include "textures/segment2/segment2_cn.1D7A0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D7B0[] = { +#include "textures/segment2/segment2_cn.1D7B0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D7C0[] = { +#include "textures/segment2/segment2_cn.1D7C0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D7D0[] = { +#include "textures/segment2/segment2_cn.1D7D0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D7E0[] = { +#include "textures/segment2/segment2_cn.1D7E0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D7F0[] = { +#include "textures/segment2/segment2_cn.1D7F0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D800[] = { +#include "textures/segment2/segment2_cn.1D800.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D810[] = { +#include "textures/segment2/segment2_cn.1D810.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D820[] = { +#include "textures/segment2/segment2_cn.1D820.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D830[] = { +#include "textures/segment2/segment2_cn.1D830.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D840[] = { +#include "textures/segment2/segment2_cn.1D840.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D850[] = { +#include "textures/segment2/segment2_cn.1D850.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D860[] = { +#include "textures/segment2/segment2_cn.1D860.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D870[] = { +#include "textures/segment2/segment2_cn.1D870.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D880[] = { +#include "textures/segment2/segment2_cn.1D880.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D890[] = { +#include "textures/segment2/segment2_cn.1D890.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D8A0[] = { +#include "textures/segment2/segment2_cn.1D8A0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D8B0[] = { +#include "textures/segment2/segment2_cn.1D8B0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D8C0[] = { +#include "textures/segment2/segment2_cn.1D8C0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D8D0[] = { +#include "textures/segment2/segment2_cn.1D8D0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D8E0[] = { +#include "textures/segment2/segment2_cn.1D8E0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D8F0[] = { +#include "textures/segment2/segment2_cn.1D8F0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D900[] = { +#include "textures/segment2/segment2_cn.1D900.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D910[] = { +#include "textures/segment2/segment2_cn.1D910.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D920[] = { +#include "textures/segment2/segment2_cn.1D920.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D930[] = { +#include "textures/segment2/segment2_cn.1D930.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D940[] = { +#include "textures/segment2/segment2_cn.1D940.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D950[] = { +#include "textures/segment2/segment2_cn.1D950.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D960[] = { +#include "textures/segment2/segment2_cn.1D960.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D970[] = { +#include "textures/segment2/segment2_cn.1D970.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D980[] = { +#include "textures/segment2/segment2_cn.1D980.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D990[] = { +#include "textures/segment2/segment2_cn.1D990.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D9A0[] = { +#include "textures/segment2/segment2_cn.1D9A0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D9B0[] = { +#include "textures/segment2/segment2_cn.1D9B0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D9C0[] = { +#include "textures/segment2/segment2_cn.1D9C0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D9D0[] = { +#include "textures/segment2/segment2_cn.1D9D0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D9E0[] = { +#include "textures/segment2/segment2_cn.1D9E0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1D9F0[] = { +#include "textures/segment2/segment2_cn.1D9F0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1DA00[] = { +#include "textures/segment2/segment2_cn.1DA00.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1DA10[] = { +#include "textures/segment2/segment2_cn.1DA10.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1DA20[] = { +#include "textures/segment2/segment2_cn.1DA20.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1DA30[] = { +#include "textures/segment2/segment2_cn.1DA30.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1DA40[] = { +#include "textures/segment2/segment2_cn.1DA40.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1DA50[] = { +#include "textures/segment2/segment2_cn.1DA50.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1DA60[] = { +#include "textures/segment2/segment2_cn.1DA60.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1DA70[] = { +#include "textures/segment2/segment2_cn.1DA70.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1DA80[] = { +#include "textures/segment2/segment2_cn.1DA80.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1DA90[] = { +#include "textures/segment2/segment2_cn.1DA90.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1DAA0[] = { +#include "textures/segment2/segment2_cn.1DAA0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1DAB0[] = { +#include "textures/segment2/segment2_cn.1DAB0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1DAC0[] = { +#include "textures/segment2/segment2_cn.1DAC0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1DAD0[] = { +#include "textures/segment2/segment2_cn.1DAD0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1DAE0[] = { +#include "textures/segment2/segment2_cn.1DAE0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1DAF0[] = { +#include "textures/segment2/segment2_cn.1DAF0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1DB00[] = { +#include "textures/segment2/segment2_cn.1DB00.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1DB10[] = { +#include "textures/segment2/segment2_cn.1DB10.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1DB20[] = { +#include "textures/segment2/segment2_cn.1DB20.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1DB30[] = { +#include "textures/segment2/segment2_cn.1DB30.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1DB40[] = { +#include "textures/segment2/segment2_cn.1DB40.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1DB50[] = { +#include "textures/segment2/segment2_cn.1DB50.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1DB60[] = { +#include "textures/segment2/segment2_cn.1DB60.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1DB70[] = { +#include "textures/segment2/segment2_cn.1DB70.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1DB80[] = { +#include "textures/segment2/segment2_cn.1DB80.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1DB90[] = { +#include "textures/segment2/segment2_cn.1DB90.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1DBA0[] = { +#include "textures/segment2/segment2_cn.1DBA0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1DBB0[] = { +#include "textures/segment2/segment2_cn.1DBB0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1DBC0[] = { +#include "textures/segment2/segment2_cn.1DBC0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1DBD0[] = { +#include "textures/segment2/segment2_cn.1DBD0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1DBE0[] = { +#include "textures/segment2/segment2_cn.1DBE0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1DBF0[] = { +#include "textures/segment2/segment2_cn.1DBF0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1DC00[] = { +#include "textures/segment2/segment2_cn.1DC00.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1DC10[] = { +#include "textures/segment2/segment2_cn.1DC10.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1DC20[] = { +#include "textures/segment2/segment2_cn.1DC20.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1DC30[] = { +#include "textures/segment2/segment2_cn.1DC30.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1DC40[] = { +#include "textures/segment2/segment2_cn.1DC40.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1DC50[] = { +#include "textures/segment2/segment2_cn.1DC50.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1DC60[] = { +#include "textures/segment2/segment2_cn.1DC60.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1DC70[] = { +#include "textures/segment2/segment2_cn.1DC70.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1DC80[] = { +#include "textures/segment2/segment2_cn.1DC80.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1DC90[] = { +#include "textures/segment2/segment2_cn.1DC90.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1DCA0[] = { +#include "textures/segment2/segment2_cn.1DCA0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1DCB0[] = { +#include "textures/segment2/segment2_cn.1DCB0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1DCC0[] = { +#include "textures/segment2/segment2_cn.1DCC0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1DCD0[] = { +#include "textures/segment2/segment2_cn.1DCD0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1DCE0[] = { +#include "textures/segment2/segment2_cn.1DCE0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1DCF0[] = { +#include "textures/segment2/segment2_cn.1DCF0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1DD00[] = { +#include "textures/segment2/segment2_cn.1DD00.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1DD10[] = { +#include "textures/segment2/segment2_cn.1DD10.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1DD20[] = { +#include "textures/segment2/segment2_cn.1DD20.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1DD30[] = { +#include "textures/segment2/segment2_cn.1DD30.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1DD40[] = { +#include "textures/segment2/segment2_cn.1DD40.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1DD50[] = { +#include "textures/segment2/segment2_cn.1DD50.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1DD60[] = { +#include "textures/segment2/segment2_cn.1DD60.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1DD70[] = { +#include "textures/segment2/segment2_cn.1DD70.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1DD80[] = { +#include "textures/segment2/segment2_cn.1DD80.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1DD90[] = { +#include "textures/segment2/segment2_cn.1DD90.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1DDA0[] = { +#include "textures/segment2/segment2_cn.1DDA0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1DDB0[] = { +#include "textures/segment2/segment2_cn.1DDB0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1DDC0[] = { +#include "textures/segment2/segment2_cn.1DDC0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1DDD0[] = { +#include "textures/segment2/segment2_cn.1DDD0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1DDE0[] = { +#include "textures/segment2/segment2_cn.1DDE0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1DDF0[] = { +#include "textures/segment2/segment2_cn.1DDF0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1DE00[] = { +#include "textures/segment2/segment2_cn.1DE00.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1DE10[] = { +#include "textures/segment2/segment2_cn.1DE10.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1DE20[] = { +#include "textures/segment2/segment2_cn.1DE20.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1DE30[] = { +#include "textures/segment2/segment2_cn.1DE30.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1DE40[] = { +#include "textures/segment2/segment2_cn.1DE40.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1DE50[] = { +#include "textures/segment2/segment2_cn.1DE50.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1DE60[] = { +#include "textures/segment2/segment2_cn.1DE60.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1DE70[] = { +#include "textures/segment2/segment2_cn.1DE70.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1DE80[] = { +#include "textures/segment2/segment2_cn.1DE80.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1DE90[] = { +#include "textures/segment2/segment2_cn.1DE90.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1DEA0[] = { +#include "textures/segment2/segment2_cn.1DEA0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1DEB0[] = { +#include "textures/segment2/segment2_cn.1DEB0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1DEC0[] = { +#include "textures/segment2/segment2_cn.1DEC0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1DED0[] = { +#include "textures/segment2/segment2_cn.1DED0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1DEE0[] = { +#include "textures/segment2/segment2_cn.1DEE0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1DEF0[] = { +#include "textures/segment2/segment2_cn.1DEF0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1DF00[] = { +#include "textures/segment2/segment2_cn.1DF00.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1DF10[] = { +#include "textures/segment2/segment2_cn.1DF10.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1DF20[] = { +#include "textures/segment2/segment2_cn.1DF20.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1DF30[] = { +#include "textures/segment2/segment2_cn.1DF30.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1DF40[] = { +#include "textures/segment2/segment2_cn.1DF40.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1DF50[] = { +#include "textures/segment2/segment2_cn.1DF50.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1DF60[] = { +#include "textures/segment2/segment2_cn.1DF60.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1DF70[] = { +#include "textures/segment2/segment2_cn.1DF70.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1DF80[] = { +#include "textures/segment2/segment2_cn.1DF80.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1DF90[] = { +#include "textures/segment2/segment2_cn.1DF90.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1DFA0[] = { +#include "textures/segment2/segment2_cn.1DFA0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1DFB0[] = { +#include "textures/segment2/segment2_cn.1DFB0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1DFC0[] = { +#include "textures/segment2/segment2_cn.1DFC0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1DFD0[] = { +#include "textures/segment2/segment2_cn.1DFD0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1DFE0[] = { +#include "textures/segment2/segment2_cn.1DFE0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1DFF0[] = { +#include "textures/segment2/segment2_cn.1DFF0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E000[] = { +#include "textures/segment2/segment2_cn.1E000.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E010[] = { +#include "textures/segment2/segment2_cn.1E010.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E020[] = { +#include "textures/segment2/segment2_cn.1E020.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E030[] = { +#include "textures/segment2/segment2_cn.1E030.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E040[] = { +#include "textures/segment2/segment2_cn.1E040.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E050[] = { +#include "textures/segment2/segment2_cn.1E050.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E060[] = { +#include "textures/segment2/segment2_cn.1E060.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E070[] = { +#include "textures/segment2/segment2_cn.1E070.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E080[] = { +#include "textures/segment2/segment2_cn.1E080.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E090[] = { +#include "textures/segment2/segment2_cn.1E090.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E0A0[] = { +#include "textures/segment2/segment2_cn.1E0A0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E0B0[] = { +#include "textures/segment2/segment2_cn.1E0B0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E0C0[] = { +#include "textures/segment2/segment2_cn.1E0C0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E0D0[] = { +#include "textures/segment2/segment2_cn.1E0D0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E0E0[] = { +#include "textures/segment2/segment2_cn.1E0E0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E0F0[] = { +#include "textures/segment2/segment2_cn.1E0F0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E100[] = { +#include "textures/segment2/segment2_cn.1E100.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E110[] = { +#include "textures/segment2/segment2_cn.1E110.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E120[] = { +#include "textures/segment2/segment2_cn.1E120.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E130[] = { +#include "textures/segment2/segment2_cn.1E130.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E140[] = { +#include "textures/segment2/segment2_cn.1E140.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E150[] = { +#include "textures/segment2/segment2_cn.1E150.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E160[] = { +#include "textures/segment2/segment2_cn.1E160.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E170[] = { +#include "textures/segment2/segment2_cn.1E170.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E180[] = { +#include "textures/segment2/segment2_cn.1E180.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E190[] = { +#include "textures/segment2/segment2_cn.1E190.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E1A0[] = { +#include "textures/segment2/segment2_cn.1E1A0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E1B0[] = { +#include "textures/segment2/segment2_cn.1E1B0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E1C0[] = { +#include "textures/segment2/segment2_cn.1E1C0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E1D0[] = { +#include "textures/segment2/segment2_cn.1E1D0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E1E0[] = { +#include "textures/segment2/segment2_cn.1E1E0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E1F0[] = { +#include "textures/segment2/segment2_cn.1E1F0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E200[] = { +#include "textures/segment2/segment2_cn.1E200.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E210[] = { +#include "textures/segment2/segment2_cn.1E210.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E220[] = { +#include "textures/segment2/segment2_cn.1E220.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E230[] = { +#include "textures/segment2/segment2_cn.1E230.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E240[] = { +#include "textures/segment2/segment2_cn.1E240.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E250[] = { +#include "textures/segment2/segment2_cn.1E250.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E260[] = { +#include "textures/segment2/segment2_cn.1E260.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E270[] = { +#include "textures/segment2/segment2_cn.1E270.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E280[] = { +#include "textures/segment2/segment2_cn.1E280.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E290[] = { +#include "textures/segment2/segment2_cn.1E290.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E2A0[] = { +#include "textures/segment2/segment2_cn.1E2A0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E2B0[] = { +#include "textures/segment2/segment2_cn.1E2B0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E2C0[] = { +#include "textures/segment2/segment2_cn.1E2C0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E2D0[] = { +#include "textures/segment2/segment2_cn.1E2D0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E2E0[] = { +#include "textures/segment2/segment2_cn.1E2E0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E2F0[] = { +#include "textures/segment2/segment2_cn.1E2F0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E300[] = { +#include "textures/segment2/segment2_cn.1E300.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E310[] = { +#include "textures/segment2/segment2_cn.1E310.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E320[] = { +#include "textures/segment2/segment2_cn.1E320.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E330[] = { +#include "textures/segment2/segment2_cn.1E330.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E340[] = { +#include "textures/segment2/segment2_cn.1E340.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E350[] = { +#include "textures/segment2/segment2_cn.1E350.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E360[] = { +#include "textures/segment2/segment2_cn.1E360.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E370[] = { +#include "textures/segment2/segment2_cn.1E370.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E380[] = { +#include "textures/segment2/segment2_cn.1E380.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E390[] = { +#include "textures/segment2/segment2_cn.1E390.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E3A0[] = { +#include "textures/segment2/segment2_cn.1E3A0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E3B0[] = { +#include "textures/segment2/segment2_cn.1E3B0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E3C0[] = { +#include "textures/segment2/segment2_cn.1E3C0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E3D0[] = { +#include "textures/segment2/segment2_cn.1E3D0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E3E0[] = { +#include "textures/segment2/segment2_cn.1E3E0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E3F0[] = { +#include "textures/segment2/segment2_cn.1E3F0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E400[] = { +#include "textures/segment2/segment2_cn.1E400.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E410[] = { +#include "textures/segment2/segment2_cn.1E410.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E420[] = { +#include "textures/segment2/segment2_cn.1E420.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E430[] = { +#include "textures/segment2/segment2_cn.1E430.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E440[] = { +#include "textures/segment2/segment2_cn.1E440.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E450[] = { +#include "textures/segment2/segment2_cn.1E450.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E460[] = { +#include "textures/segment2/segment2_cn.1E460.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E470[] = { +#include "textures/segment2/segment2_cn.1E470.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E480[] = { +#include "textures/segment2/segment2_cn.1E480.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E490[] = { +#include "textures/segment2/segment2_cn.1E490.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E4A0[] = { +#include "textures/segment2/segment2_cn.1E4A0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E4B0[] = { +#include "textures/segment2/segment2_cn.1E4B0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E4C0[] = { +#include "textures/segment2/segment2_cn.1E4C0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E4D0[] = { +#include "textures/segment2/segment2_cn.1E4D0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E4E0[] = { +#include "textures/segment2/segment2_cn.1E4E0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E4F0[] = { +#include "textures/segment2/segment2_cn.1E4F0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E500[] = { +#include "textures/segment2/segment2_cn.1E500.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E510[] = { +#include "textures/segment2/segment2_cn.1E510.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E520[] = { +#include "textures/segment2/segment2_cn.1E520.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E530[] = { +#include "textures/segment2/segment2_cn.1E530.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E540[] = { +#include "textures/segment2/segment2_cn.1E540.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E550[] = { +#include "textures/segment2/segment2_cn.1E550.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E560[] = { +#include "textures/segment2/segment2_cn.1E560.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E570[] = { +#include "textures/segment2/segment2_cn.1E570.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E580[] = { +#include "textures/segment2/segment2_cn.1E580.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E590[] = { +#include "textures/segment2/segment2_cn.1E590.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E5A0[] = { +#include "textures/segment2/segment2_cn.1E5A0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E5B0[] = { +#include "textures/segment2/segment2_cn.1E5B0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E5C0[] = { +#include "textures/segment2/segment2_cn.1E5C0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E5D0[] = { +#include "textures/segment2/segment2_cn.1E5D0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E5E0[] = { +#include "textures/segment2/segment2_cn.1E5E0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E5F0[] = { +#include "textures/segment2/segment2_cn.1E5F0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E600[] = { +#include "textures/segment2/segment2_cn.1E600.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E610[] = { +#include "textures/segment2/segment2_cn.1E610.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E620[] = { +#include "textures/segment2/segment2_cn.1E620.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E630[] = { +#include "textures/segment2/segment2_cn.1E630.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E640[] = { +#include "textures/segment2/segment2_cn.1E640.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E650[] = { +#include "textures/segment2/segment2_cn.1E650.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E660[] = { +#include "textures/segment2/segment2_cn.1E660.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E670[] = { +#include "textures/segment2/segment2_cn.1E670.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E680[] = { +#include "textures/segment2/segment2_cn.1E680.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E690[] = { +#include "textures/segment2/segment2_cn.1E690.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E6A0[] = { +#include "textures/segment2/segment2_cn.1E6A0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E6B0[] = { +#include "textures/segment2/segment2_cn.1E6B0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E6C0[] = { +#include "textures/segment2/segment2_cn.1E6C0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E6D0[] = { +#include "textures/segment2/segment2_cn.1E6D0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E6E0[] = { +#include "textures/segment2/segment2_cn.1E6E0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E6F0[] = { +#include "textures/segment2/segment2_cn.1E6F0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E700[] = { +#include "textures/segment2/segment2_cn.1E700.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E710[] = { +#include "textures/segment2/segment2_cn.1E710.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E720[] = { +#include "textures/segment2/segment2_cn.1E720.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E730[] = { +#include "textures/segment2/segment2_cn.1E730.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E740[] = { +#include "textures/segment2/segment2_cn.1E740.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E750[] = { +#include "textures/segment2/segment2_cn.1E750.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E760[] = { +#include "textures/segment2/segment2_cn.1E760.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E770[] = { +#include "textures/segment2/segment2_cn.1E770.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E780[] = { +#include "textures/segment2/segment2_cn.1E780.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E790[] = { +#include "textures/segment2/segment2_cn.1E790.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E7A0[] = { +#include "textures/segment2/segment2_cn.1E7A0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E7B0[] = { +#include "textures/segment2/segment2_cn.1E7B0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E7C0[] = { +#include "textures/segment2/segment2_cn.1E7C0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E7D0[] = { +#include "textures/segment2/segment2_cn.1E7D0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E7E0[] = { +#include "textures/segment2/segment2_cn.1E7E0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E7F0[] = { +#include "textures/segment2/segment2_cn.1E7F0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E800[] = { +#include "textures/segment2/segment2_cn.1E800.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E810[] = { +#include "textures/segment2/segment2_cn.1E810.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E820[] = { +#include "textures/segment2/segment2_cn.1E820.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E830[] = { +#include "textures/segment2/segment2_cn.1E830.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E840[] = { +#include "textures/segment2/segment2_cn.1E840.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E850[] = { +#include "textures/segment2/segment2_cn.1E850.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E860[] = { +#include "textures/segment2/segment2_cn.1E860.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E870[] = { +#include "textures/segment2/segment2_cn.1E870.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E880[] = { +#include "textures/segment2/segment2_cn.1E880.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E890[] = { +#include "textures/segment2/segment2_cn.1E890.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E8A0[] = { +#include "textures/segment2/segment2_cn.1E8A0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E8B0[] = { +#include "textures/segment2/segment2_cn.1E8B0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E8C0[] = { +#include "textures/segment2/segment2_cn.1E8C0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E8D0[] = { +#include "textures/segment2/segment2_cn.1E8D0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E8E0[] = { +#include "textures/segment2/segment2_cn.1E8E0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E8F0[] = { +#include "textures/segment2/segment2_cn.1E8F0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E900[] = { +#include "textures/segment2/segment2_cn.1E900.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E910[] = { +#include "textures/segment2/segment2_cn.1E910.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E920[] = { +#include "textures/segment2/segment2_cn.1E920.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E930[] = { +#include "textures/segment2/segment2_cn.1E930.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E940[] = { +#include "textures/segment2/segment2_cn.1E940.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E950[] = { +#include "textures/segment2/segment2_cn.1E950.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E960[] = { +#include "textures/segment2/segment2_cn.1E960.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E970[] = { +#include "textures/segment2/segment2_cn.1E970.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E980[] = { +#include "textures/segment2/segment2_cn.1E980.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E990[] = { +#include "textures/segment2/segment2_cn.1E990.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E9A0[] = { +#include "textures/segment2/segment2_cn.1E9A0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E9B0[] = { +#include "textures/segment2/segment2_cn.1E9B0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E9C0[] = { +#include "textures/segment2/segment2_cn.1E9C0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E9D0[] = { +#include "textures/segment2/segment2_cn.1E9D0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E9E0[] = { +#include "textures/segment2/segment2_cn.1E9E0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1E9F0[] = { +#include "textures/segment2/segment2_cn.1E9F0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1EA00[] = { +#include "textures/segment2/segment2_cn.1EA00.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1EA10[] = { +#include "textures/segment2/segment2_cn.1EA10.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1EA20[] = { +#include "textures/segment2/segment2_cn.1EA20.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1EA30[] = { +#include "textures/segment2/segment2_cn.1EA30.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1EA40[] = { +#include "textures/segment2/segment2_cn.1EA40.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1EA50[] = { +#include "textures/segment2/segment2_cn.1EA50.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1EA60[] = { +#include "textures/segment2/segment2_cn.1EA60.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1EA70[] = { +#include "textures/segment2/segment2_cn.1EA70.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1EA80[] = { +#include "textures/segment2/segment2_cn.1EA80.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1EA90[] = { +#include "textures/segment2/segment2_cn.1EA90.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1EAA0[] = { +#include "textures/segment2/segment2_cn.1EAA0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1EAB0[] = { +#include "textures/segment2/segment2_cn.1EAB0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1EAC0[] = { +#include "textures/segment2/segment2_cn.1EAC0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1EAD0[] = { +#include "textures/segment2/segment2_cn.1EAD0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1EAE0[] = { +#include "textures/segment2/segment2_cn.1EAE0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1EAF0[] = { +#include "textures/segment2/segment2_cn.1EAF0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1EB00[] = { +#include "textures/segment2/segment2_cn.1EB00.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1EB10[] = { +#include "textures/segment2/segment2_cn.1EB10.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1EB20[] = { +#include "textures/segment2/segment2_cn.1EB20.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1EB30[] = { +#include "textures/segment2/segment2_cn.1EB30.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1EB40[] = { +#include "textures/segment2/segment2_cn.1EB40.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1EB50[] = { +#include "textures/segment2/segment2_cn.1EB50.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1EB60[] = { +#include "textures/segment2/segment2_cn.1EB60.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1EB70[] = { +#include "textures/segment2/segment2_cn.1EB70.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1EB80[] = { +#include "textures/segment2/segment2_cn.1EB80.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1EB90[] = { +#include "textures/segment2/segment2_cn.1EB90.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1EBA0[] = { +#include "textures/segment2/segment2_cn.1EBA0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1EBB0[] = { +#include "textures/segment2/segment2_cn.1EBB0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1EBC0[] = { +#include "textures/segment2/segment2_cn.1EBC0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1EBD0[] = { +#include "textures/segment2/segment2_cn.1EBD0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1EBE0[] = { +#include "textures/segment2/segment2_cn.1EBE0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1EBF0[] = { +#include "textures/segment2/segment2_cn.1EBF0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1EC00[] = { +#include "textures/segment2/segment2_cn.1EC00.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1EC10[] = { +#include "textures/segment2/segment2_cn.1EC10.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1EC20[] = { +#include "textures/segment2/segment2_cn.1EC20.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1EC30[] = { +#include "textures/segment2/segment2_cn.1EC30.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1EC40[] = { +#include "textures/segment2/segment2_cn.1EC40.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1EC50[] = { +#include "textures/segment2/segment2_cn.1EC50.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1EC60[] = { +#include "textures/segment2/segment2_cn.1EC60.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1EC70[] = { +#include "textures/segment2/segment2_cn.1EC70.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1EC80[] = { +#include "textures/segment2/segment2_cn.1EC80.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1EC90[] = { +#include "textures/segment2/segment2_cn.1EC90.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1ECA0[] = { +#include "textures/segment2/segment2_cn.1ECA0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1ECB0[] = { +#include "textures/segment2/segment2_cn.1ECB0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1ECC0[] = { +#include "textures/segment2/segment2_cn.1ECC0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1ECD0[] = { +#include "textures/segment2/segment2_cn.1ECD0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1ECE0[] = { +#include "textures/segment2/segment2_cn.1ECE0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1ECF0[] = { +#include "textures/segment2/segment2_cn.1ECF0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1ED00[] = { +#include "textures/segment2/segment2_cn.1ED00.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1ED10[] = { +#include "textures/segment2/segment2_cn.1ED10.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1ED20[] = { +#include "textures/segment2/segment2_cn.1ED20.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1ED30[] = { +#include "textures/segment2/segment2_cn.1ED30.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1ED40[] = { +#include "textures/segment2/segment2_cn.1ED40.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1ED50[] = { +#include "textures/segment2/segment2_cn.1ED50.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1ED60[] = { +#include "textures/segment2/segment2_cn.1ED60.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1ED70[] = { +#include "textures/segment2/segment2_cn.1ED70.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1ED80[] = { +#include "textures/segment2/segment2_cn.1ED80.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1ED90[] = { +#include "textures/segment2/segment2_cn.1ED90.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1EDA0[] = { +#include "textures/segment2/segment2_cn.1EDA0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1EDB0[] = { +#include "textures/segment2/segment2_cn.1EDB0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1EDC0[] = { +#include "textures/segment2/segment2_cn.1EDC0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1EDD0[] = { +#include "textures/segment2/segment2_cn.1EDD0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1EDE0[] = { +#include "textures/segment2/segment2_cn.1EDE0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1EDF0[] = { +#include "textures/segment2/segment2_cn.1EDF0.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1EE00[] = { +#include "textures/segment2/segment2_cn.1EE00.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1EE10[] = { +#include "textures/segment2/segment2_cn.1EE10.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1EE20[] = { +#include "textures/segment2/segment2_cn.1EE20.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1EE30[] = { +#include "textures/segment2/segment2_cn.1EE30.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1EE40[] = { +#include "textures/segment2/segment2_cn.1EE40.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1EE50[] = { +#include "textures/segment2/segment2_cn.1EE50.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1EE60[] = { +#include "textures/segment2/segment2_cn.1EE60.ia1.inc.c" +}; + +ALIGNED8 static const Texture texture_font_char_cn_1EE70[] = { +#include "textures/segment2/segment2_cn.1EE70.ia1.inc.c" +}; +#endif // VERSION_CN + ALIGNED8 static const Texture texture_hud_char_camera[] = { #include "textures/segment2/segment2.07B50.rgba16.inc.c" }; @@ -1806,43 +10914,68 @@ ALIGNED8 static const Texture texture_hud_char_arrow_down[] = { // Main HUD print table 0x02008250-0x02008337 const Texture *const main_hud_lut[] = { -#ifdef VERSION_EU texture_hud_char_0, texture_hud_char_1, texture_hud_char_2, texture_hud_char_3, texture_hud_char_4, texture_hud_char_5, texture_hud_char_6, texture_hud_char_7, texture_hud_char_8, texture_hud_char_9, texture_hud_char_A, texture_hud_char_B, texture_hud_char_C, texture_hud_char_D, texture_hud_char_E, texture_hud_char_F, - texture_hud_char_G, texture_hud_char_H, texture_hud_char_I, 0x0, +#if defined(VERSION_EU) + texture_hud_char_G, texture_hud_char_H, texture_hud_char_I, 0x0, texture_hud_char_K, texture_hud_char_L, texture_hud_char_M, texture_hud_char_N, - texture_hud_char_O, texture_hud_char_P, 0x0, texture_hud_char_R, + texture_hud_char_O, texture_hud_char_P, 0x0, texture_hud_char_R, texture_hud_char_S, texture_hud_char_T, texture_hud_char_U, texture_hud_char_V, - texture_hud_char_W, 0x0, texture_hud_char_Y, texture_hud_char_Z, - 0x0, 0x0, 0x0, 0x0, - 0x0, 0x0, 0x0, 0x0, - 0x0, 0x0, 0x0, 0x0, - 0x0, 0x0, texture_hud_char_multiply, texture_hud_char_coin, - texture_hud_char_mario_head, texture_hud_char_star, 0x0, 0x0, + texture_hud_char_W, 0x0, texture_hud_char_Y, texture_hud_char_Z, + 0x0, 0x0, 0x0, 0x0, + 0x0, 0x0, 0x0, 0x0, + 0x0, 0x0, 0x0, 0x0, + 0x0, 0x0, texture_hud_char_multiply, texture_hud_char_coin, + texture_hud_char_mario_head, texture_hud_char_star, 0x0, 0x0, texture_hud_char_apostrophe, texture_hud_char_double_quote, texture_hud_char_umlaut, -#elif defined(VERSION_US) - texture_hud_char_0, texture_hud_char_1, texture_hud_char_2, texture_hud_char_3, - texture_hud_char_4, texture_hud_char_5, texture_hud_char_6, texture_hud_char_7, - texture_hud_char_8, texture_hud_char_9, texture_hud_char_A, texture_hud_char_B, - texture_hud_char_C, texture_hud_char_D, texture_hud_char_E, texture_hud_char_F, - texture_hud_char_G, texture_hud_char_H, texture_hud_char_I, 0x0, +#elif defined(VERSION_CN) || defined(VERSION_US) + texture_hud_char_G, texture_hud_char_H, texture_hud_char_I, 0x0, texture_hud_char_K, texture_hud_char_L, texture_hud_char_M, texture_hud_char_N, - texture_hud_char_O, texture_hud_char_P, 0x0, texture_hud_char_R, - texture_hud_char_S, texture_hud_char_T, texture_hud_char_U, 0x0, - texture_hud_char_W, 0x0, texture_hud_char_Y, 0x0, - 0x0, 0x0, 0x0, 0x0, - 0x0, 0x0, 0x0, 0x0, - 0x0, 0x0, 0x0, 0x0, - 0x0, 0x0, texture_hud_char_multiply, texture_hud_char_coin, + texture_hud_char_O, texture_hud_char_P, 0x0, texture_hud_char_R, + texture_hud_char_S, texture_hud_char_T, texture_hud_char_U, 0x0, + texture_hud_char_W, 0x0, texture_hud_char_Y, 0x0, + 0x0, 0x0, 0x0, 0x0, + 0x0, 0x0, 0x0, 0x0, + 0x0, 0x0, 0x0, 0x0, + 0x0, 0x0, texture_hud_char_multiply, texture_hud_char_coin, texture_hud_char_mario_head, texture_hud_char_star, 0x0, 0x0, texture_hud_char_apostrophe, texture_hud_char_double_quote, +#if defined(VERSION_CN) + texture_hud_char_cn_04A00, texture_hud_char_cn_04C00, texture_hud_char_cn_04E00, texture_hud_char_cn_05000, + texture_hud_char_cn_05200, texture_hud_char_cn_05400, texture_hud_char_cn_05600, texture_hud_char_cn_05800, + texture_hud_char_cn_05A00, texture_hud_char_cn_05C00, texture_hud_char_cn_05E00, texture_hud_char_cn_06000, + texture_hud_char_cn_06200, texture_hud_char_cn_06400, texture_hud_char_cn_06600, texture_hud_char_cn_06800, + texture_hud_char_cn_06A00, texture_hud_char_cn_06C00, texture_hud_char_cn_06E00, texture_hud_char_cn_07000, + texture_hud_char_cn_07200, texture_hud_char_cn_07400, texture_hud_char_cn_07600, texture_hud_char_cn_07800, + texture_hud_char_cn_07A00, texture_hud_char_cn_07C00, texture_hud_char_cn_07E00, texture_hud_char_cn_08000, + texture_hud_char_cn_08200, texture_hud_char_cn_08400, texture_hud_char_cn_08600, texture_hud_char_cn_08800, + texture_hud_char_cn_08A00, texture_hud_char_cn_08C00, texture_hud_char_cn_08E00, texture_hud_char_cn_09000, + texture_hud_char_cn_09200, texture_hud_char_cn_09400, texture_hud_char_cn_09600, texture_hud_char_cn_09800, + texture_hud_char_cn_09A00, texture_hud_char_cn_09C00, texture_hud_char_cn_09E00, texture_hud_char_cn_0A000, + texture_hud_char_cn_0A200, texture_hud_char_cn_0A400, texture_hud_char_cn_0A600, texture_hud_char_cn_0A800, + texture_hud_char_cn_0AA00, texture_hud_char_cn_0AC00, texture_hud_char_cn_0AE00, texture_hud_char_cn_0B000, + texture_hud_char_cn_0B200, texture_hud_char_cn_0B400, texture_hud_char_cn_0B600, texture_hud_char_cn_0B800, + texture_hud_char_cn_0BA00, texture_hud_char_cn_0BC00, texture_hud_char_cn_0BE00, texture_hud_char_cn_0C000, + texture_hud_char_cn_0C200, texture_hud_char_cn_0C400, texture_hud_char_cn_0C600, texture_hud_char_cn_0C800, + texture_hud_char_cn_0CA00, texture_hud_char_cn_0CC00, texture_hud_char_cn_0CE00, texture_hud_char_cn_0D000, + texture_hud_char_cn_0D200, texture_hud_char_cn_0D400, texture_hud_char_cn_0D600, texture_hud_char_cn_0D800, + texture_hud_char_cn_0DA00, texture_hud_char_cn_0DC00, texture_hud_char_cn_0DE00, texture_hud_char_cn_0E000, + texture_hud_char_cn_0E200, texture_hud_char_cn_0E400, texture_hud_char_cn_0E600, texture_hud_char_cn_0E800, + texture_hud_char_cn_0EA00, texture_hud_char_cn_0EC00, texture_hud_char_cn_0EE00, texture_hud_char_cn_0F000, + texture_hud_char_cn_0F200, texture_hud_char_cn_0F400, texture_hud_char_cn_0F600, texture_hud_char_cn_0F800, + texture_hud_char_cn_0FA00, texture_hud_char_cn_0FC00, texture_hud_char_cn_0FE00, texture_hud_char_cn_10000, + texture_hud_char_cn_10200, texture_hud_char_cn_10400, texture_hud_char_cn_10600, texture_hud_char_cn_10800, + texture_hud_char_cn_10A00, texture_hud_char_cn_10C00, texture_hud_char_cn_10E00, texture_hud_char_cn_11000, + texture_hud_char_cn_11200, texture_hud_char_cn_11400, texture_hud_char_cn_11600, texture_hud_char_cn_11800, + texture_hud_char_cn_11A00, texture_hud_char_cn_11C00, texture_hud_char_cn_11E00, texture_hud_char_cn_12000, + texture_hud_char_cn_12200, texture_hud_char_cn_12400, texture_hud_char_cn_12600, texture_hud_char_cn_12800, + texture_hud_char_cn_12A00, texture_hud_char_cn_12C00, texture_hud_char_cn_12E00, texture_hud_char_cn_13000, + texture_hud_char_cn_13200, texture_hud_char_cn_13400, texture_hud_char_cn_13600, texture_hud_char_cn_13800, + texture_hud_char_cn_13A00, texture_hud_char_cn_13C00, texture_hud_char_cn_13E00, texture_hud_char_cn_14000, +#endif // VERSION_CN #else - texture_hud_char_0, texture_hud_char_1, texture_hud_char_2, texture_hud_char_3, - texture_hud_char_4, texture_hud_char_5, texture_hud_char_6, texture_hud_char_7, - texture_hud_char_8, texture_hud_char_9, texture_hud_char_A, texture_hud_char_B, - texture_hud_char_C, texture_hud_char_D, texture_hud_char_E, texture_hud_char_F, texture_hud_char_G, texture_hud_char_H, texture_hud_char_I, texture_hud_char_J, texture_hud_char_K, texture_hud_char_L, texture_hud_char_M, texture_hud_char_N, texture_hud_char_O, texture_hud_char_P, texture_hud_char_Q, texture_hud_char_R, @@ -1926,7 +11059,7 @@ const Texture *const main_font_lut[] = { texture_font_char_eu_interpunct, texture_font_char_eu_star_hollow, 0x0, 0x0, -#elif defined(VERSION_US) // US Font Table +#elif defined(VERSION_US) || defined(VERSION_CN) // US Font Table texture_font_char_us_0, texture_font_char_us_1, texture_font_char_us_2, texture_font_char_us_3, texture_font_char_us_4, texture_font_char_us_5, texture_font_char_us_6, texture_font_char_us_7, texture_font_char_us_8, texture_font_char_us_9, texture_font_char_us_A, texture_font_char_us_B, @@ -1943,7 +11076,11 @@ const Texture *const main_font_lut[] = { texture_font_char_us_q, texture_font_char_us_r, texture_font_char_us_s, texture_font_char_us_t, texture_font_char_us_u, texture_font_char_us_v, texture_font_char_us_w, texture_font_char_us_x, texture_font_char_us_y, texture_font_char_us_z, texture_font_char_us_apostrophe, texture_font_char_us_period, +#if defined(VERSION_CN) + texture_font_char_cn_16800, texture_font_char_cn_16840, 0x0, 0x0, +#else 0x0, 0x0, 0x0, 0x0, +#endif 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, @@ -1991,6 +11128,544 @@ const Texture *const main_font_lut[] = { texture_font_char_us_question, texture_font_char_us_double_quote_open, texture_font_char_us_double_quote_close, texture_font_char_us_tilde, 0x0, texture_font_char_us_coin, texture_font_char_us_star_filled, texture_font_char_us_multiply, texture_font_char_us_interpunct, texture_font_char_us_star_hollow, 0x0, 0x0, +#if defined(VERSION_CN) + texture_font_char_cn_16880, texture_font_char_cn_16890, texture_font_char_cn_168A0, texture_font_char_cn_168B0, + texture_font_char_cn_168C0, texture_font_char_cn_168D0, texture_font_char_cn_168E0, texture_font_char_cn_168F0, + texture_font_char_cn_16900, texture_font_char_cn_16910, texture_font_char_cn_16920, texture_font_char_cn_16930, + texture_font_char_cn_16940, texture_font_char_cn_16950, texture_font_char_cn_16960, texture_font_char_cn_16970, + texture_font_char_cn_16980, texture_font_char_cn_16990, texture_font_char_cn_169A0, texture_font_char_cn_169B0, + texture_font_char_cn_169C0, texture_font_char_cn_169D0, texture_font_char_cn_169E0, texture_font_char_cn_169F0, + texture_font_char_cn_16A00, texture_font_char_cn_16A10, texture_font_char_cn_16A20, texture_font_char_cn_16A30, + texture_font_char_cn_16A40, texture_font_char_cn_16A50, texture_font_char_cn_16A60, texture_font_char_cn_16A70, + texture_font_char_cn_16A80, texture_font_char_cn_16A90, texture_font_char_cn_16AA0, texture_font_char_cn_16AB0, + texture_font_char_cn_16AC0, texture_font_char_cn_16AD0, texture_font_char_cn_16AE0, texture_font_char_cn_16AF0, + texture_font_char_cn_16B00, texture_font_char_cn_16B10, texture_font_char_cn_16B20, texture_font_char_cn_16B30, + texture_font_char_cn_16B40, texture_font_char_cn_16B50, texture_font_char_cn_16B60, texture_font_char_cn_16B70, + texture_font_char_cn_16B80, texture_font_char_cn_16B90, texture_font_char_cn_16BA0, texture_font_char_cn_16BB0, + texture_font_char_cn_16BC0, texture_font_char_cn_16BD0, texture_font_char_cn_16BE0, texture_font_char_cn_16BF0, + texture_font_char_cn_16C00, texture_font_char_cn_16C10, texture_font_char_cn_16C20, texture_font_char_cn_16C30, + texture_font_char_cn_16C40, texture_font_char_cn_16C50, texture_font_char_cn_16C60, texture_font_char_cn_16C70, + texture_font_char_cn_16C80, texture_font_char_cn_16C90, texture_font_char_cn_16CA0, texture_font_char_cn_16CB0, + texture_font_char_cn_16CC0, texture_font_char_cn_16CD0, texture_font_char_cn_16CE0, texture_font_char_cn_16CF0, + texture_font_char_cn_16D00, texture_font_char_cn_16D10, texture_font_char_cn_16D20, texture_font_char_cn_16D30, + texture_font_char_cn_16D40, texture_font_char_cn_16D50, texture_font_char_cn_16D60, texture_font_char_cn_16D70, + texture_font_char_cn_16D80, texture_font_char_cn_16D90, texture_font_char_cn_16DA0, texture_font_char_cn_16DB0, + texture_font_char_cn_16DC0, texture_font_char_cn_16DD0, texture_font_char_cn_16DE0, texture_font_char_cn_16DF0, + texture_font_char_cn_16E00, texture_font_char_cn_16E10, texture_font_char_cn_16E20, texture_font_char_cn_16E30, + texture_font_char_cn_16E40, texture_font_char_cn_16E50, texture_font_char_cn_16E60, texture_font_char_cn_16E70, + texture_font_char_cn_16E80, texture_font_char_cn_16E90, texture_font_char_cn_16EA0, texture_font_char_cn_16EB0, + texture_font_char_cn_16EC0, texture_font_char_cn_16ED0, texture_font_char_cn_16EE0, texture_font_char_cn_16EF0, + texture_font_char_cn_16F00, texture_font_char_cn_16F10, texture_font_char_cn_16F20, texture_font_char_cn_16F30, + texture_font_char_cn_16F40, texture_font_char_cn_16F50, texture_font_char_cn_16F60, texture_font_char_cn_16F70, + texture_font_char_cn_16F80, texture_font_char_cn_16F90, texture_font_char_cn_16FA0, texture_font_char_cn_16FB0, + texture_font_char_cn_16FC0, texture_font_char_cn_16FD0, texture_font_char_cn_16FE0, texture_font_char_cn_16FF0, + texture_font_char_cn_17000, texture_font_char_cn_17010, texture_font_char_cn_17020, texture_font_char_cn_17030, + texture_font_char_cn_17040, texture_font_char_cn_17050, texture_font_char_cn_17060, texture_font_char_cn_17070, + texture_font_char_cn_17080, texture_font_char_cn_17090, texture_font_char_cn_170A0, texture_font_char_cn_170B0, + texture_font_char_cn_170C0, texture_font_char_cn_170D0, texture_font_char_cn_170E0, texture_font_char_cn_170F0, + texture_font_char_cn_17100, texture_font_char_cn_17110, texture_font_char_cn_17120, texture_font_char_cn_17130, + texture_font_char_cn_17140, texture_font_char_cn_17150, texture_font_char_cn_17160, texture_font_char_cn_17170, + texture_font_char_cn_17180, texture_font_char_cn_17190, texture_font_char_cn_171A0, texture_font_char_cn_171B0, + texture_font_char_cn_171C0, texture_font_char_cn_171D0, texture_font_char_cn_171E0, texture_font_char_cn_171F0, + texture_font_char_cn_17200, texture_font_char_cn_17210, texture_font_char_cn_17220, texture_font_char_cn_17230, + texture_font_char_cn_17240, texture_font_char_cn_17250, texture_font_char_cn_17260, texture_font_char_cn_17270, + texture_font_char_cn_17280, texture_font_char_cn_17290, texture_font_char_cn_172A0, texture_font_char_cn_172B0, + texture_font_char_cn_172C0, texture_font_char_cn_172D0, texture_font_char_cn_172E0, texture_font_char_cn_172F0, + texture_font_char_cn_17300, texture_font_char_cn_17310, texture_font_char_cn_17320, texture_font_char_cn_17330, + texture_font_char_cn_17340, texture_font_char_cn_17350, texture_font_char_cn_17360, texture_font_char_cn_17370, + texture_font_char_cn_17380, texture_font_char_cn_17390, texture_font_char_cn_173A0, texture_font_char_cn_173B0, + texture_font_char_cn_173C0, texture_font_char_cn_173D0, texture_font_char_cn_173E0, texture_font_char_cn_173F0, + texture_font_char_cn_17400, texture_font_char_cn_17410, texture_font_char_cn_17420, texture_font_char_cn_17430, + texture_font_char_cn_17440, texture_font_char_cn_17450, texture_font_char_cn_17460, texture_font_char_cn_17470, + texture_font_char_cn_17480, texture_font_char_cn_17490, texture_font_char_cn_174A0, texture_font_char_cn_174B0, + texture_font_char_cn_174C0, texture_font_char_cn_174D0, texture_font_char_cn_174E0, texture_font_char_cn_174F0, + texture_font_char_cn_17500, texture_font_char_cn_17510, texture_font_char_cn_17520, texture_font_char_cn_17530, + texture_font_char_cn_17540, texture_font_char_cn_17550, texture_font_char_cn_17560, texture_font_char_cn_17570, + texture_font_char_cn_17580, texture_font_char_cn_17590, texture_font_char_cn_175A0, texture_font_char_cn_175B0, + texture_font_char_cn_175C0, texture_font_char_cn_175D0, texture_font_char_cn_175E0, texture_font_char_cn_175F0, + texture_font_char_cn_17600, texture_font_char_cn_17610, texture_font_char_cn_17620, texture_font_char_cn_17630, + texture_font_char_cn_17640, texture_font_char_cn_17650, texture_font_char_cn_17660, texture_font_char_cn_17670, + texture_font_char_cn_17680, texture_font_char_cn_17690, texture_font_char_cn_176A0, texture_font_char_cn_176B0, + texture_font_char_cn_176C0, texture_font_char_cn_176D0, texture_font_char_cn_176E0, texture_font_char_cn_176F0, + texture_font_char_cn_17700, texture_font_char_cn_17710, texture_font_char_cn_17720, texture_font_char_cn_17730, + texture_font_char_cn_17740, texture_font_char_cn_17750, texture_font_char_cn_17760, texture_font_char_cn_17770, + texture_font_char_cn_17780, texture_font_char_cn_17790, texture_font_char_cn_177A0, texture_font_char_cn_177B0, + texture_font_char_cn_177C0, texture_font_char_cn_177D0, texture_font_char_cn_177E0, texture_font_char_cn_177F0, + texture_font_char_cn_17800, texture_font_char_cn_17810, texture_font_char_cn_17820, texture_font_char_cn_17830, + texture_font_char_cn_17840, texture_font_char_cn_17850, texture_font_char_cn_17860, texture_font_char_cn_17870, + texture_font_char_cn_17880, texture_font_char_cn_17890, texture_font_char_cn_178A0, texture_font_char_cn_178B0, + texture_font_char_cn_178C0, texture_font_char_cn_178D0, texture_font_char_cn_178E0, texture_font_char_cn_178F0, + texture_font_char_cn_17900, texture_font_char_cn_17910, texture_font_char_cn_17920, texture_font_char_cn_17930, + texture_font_char_cn_17940, texture_font_char_cn_17950, texture_font_char_cn_17960, texture_font_char_cn_17970, + texture_font_char_cn_17980, texture_font_char_cn_17990, texture_font_char_cn_179A0, texture_font_char_cn_179B0, + texture_font_char_cn_179C0, texture_font_char_cn_179D0, texture_font_char_cn_179E0, texture_font_char_cn_179F0, + texture_font_char_cn_17A00, texture_font_char_cn_17A10, texture_font_char_cn_17A20, texture_font_char_cn_17A30, + texture_font_char_cn_17A40, texture_font_char_cn_17A50, texture_font_char_cn_17A60, texture_font_char_cn_17A70, + texture_font_char_cn_17A80, texture_font_char_cn_17A90, texture_font_char_cn_17AA0, texture_font_char_cn_17AB0, + texture_font_char_cn_17AC0, texture_font_char_cn_17AD0, texture_font_char_cn_17AE0, texture_font_char_cn_17AF0, + texture_font_char_cn_17B00, texture_font_char_cn_17B10, texture_font_char_cn_17B20, texture_font_char_cn_17B30, + texture_font_char_cn_17B40, texture_font_char_cn_17B50, texture_font_char_cn_17B60, texture_font_char_cn_17B70, + texture_font_char_cn_17B80, texture_font_char_cn_17B90, texture_font_char_cn_17BA0, texture_font_char_cn_17BB0, + texture_font_char_cn_17BC0, texture_font_char_cn_17BD0, texture_font_char_cn_17BE0, texture_font_char_cn_17BF0, + texture_font_char_cn_17C00, texture_font_char_cn_17C10, texture_font_char_cn_17C20, texture_font_char_cn_17C30, + texture_font_char_cn_17C40, texture_font_char_cn_17C50, texture_font_char_cn_17C60, texture_font_char_cn_17C70, + texture_font_char_cn_17C80, texture_font_char_cn_17C90, texture_font_char_cn_17CA0, texture_font_char_cn_17CB0, + texture_font_char_cn_17CC0, texture_font_char_cn_17CD0, texture_font_char_cn_17CE0, texture_font_char_cn_17CF0, + texture_font_char_cn_17D00, texture_font_char_cn_17D10, texture_font_char_cn_17D20, texture_font_char_cn_17D30, + texture_font_char_cn_17D40, texture_font_char_cn_17D50, texture_font_char_cn_17D60, texture_font_char_cn_17D70, + texture_font_char_cn_17D80, texture_font_char_cn_17D90, texture_font_char_cn_17DA0, texture_font_char_cn_17DB0, + texture_font_char_cn_17DC0, texture_font_char_cn_17DD0, texture_font_char_cn_17DE0, texture_font_char_cn_17DF0, + texture_font_char_cn_17E00, texture_font_char_cn_17E10, texture_font_char_cn_17E20, texture_font_char_cn_17E30, + texture_font_char_cn_17E40, texture_font_char_cn_17E50, texture_font_char_cn_17E60, texture_font_char_cn_17E70, + texture_font_char_cn_17E80, texture_font_char_cn_17E90, texture_font_char_cn_17EA0, texture_font_char_cn_17EB0, + texture_font_char_cn_17EC0, texture_font_char_cn_17ED0, texture_font_char_cn_17EE0, texture_font_char_cn_17EF0, + texture_font_char_cn_17F00, texture_font_char_cn_17F10, texture_font_char_cn_17F20, texture_font_char_cn_17F30, + texture_font_char_cn_17F40, texture_font_char_cn_17F50, texture_font_char_cn_17F60, texture_font_char_cn_17F70, + texture_font_char_cn_17F80, texture_font_char_cn_17F90, texture_font_char_cn_17FA0, texture_font_char_cn_17FB0, + texture_font_char_cn_17FC0, texture_font_char_cn_17FD0, texture_font_char_cn_17FE0, texture_font_char_cn_17FF0, + texture_font_char_cn_18000, texture_font_char_cn_18010, texture_font_char_cn_18020, texture_font_char_cn_18030, + texture_font_char_cn_18040, texture_font_char_cn_18050, texture_font_char_cn_18060, texture_font_char_cn_18070, + texture_font_char_cn_18080, texture_font_char_cn_18090, texture_font_char_cn_180A0, texture_font_char_cn_180B0, + texture_font_char_cn_180C0, texture_font_char_cn_180D0, texture_font_char_cn_180E0, texture_font_char_cn_180F0, + texture_font_char_cn_18100, texture_font_char_cn_18110, texture_font_char_cn_18120, texture_font_char_cn_18130, + texture_font_char_cn_18140, texture_font_char_cn_18150, texture_font_char_cn_18160, texture_font_char_cn_18170, + texture_font_char_cn_18180, texture_font_char_cn_18190, texture_font_char_cn_181A0, texture_font_char_cn_181B0, + texture_font_char_cn_181C0, texture_font_char_cn_181D0, texture_font_char_cn_181E0, texture_font_char_cn_181F0, + texture_font_char_cn_18200, texture_font_char_cn_18210, texture_font_char_cn_18220, texture_font_char_cn_18230, + texture_font_char_cn_18240, texture_font_char_cn_18250, texture_font_char_cn_18260, texture_font_char_cn_18270, + texture_font_char_cn_18280, texture_font_char_cn_18290, texture_font_char_cn_182A0, texture_font_char_cn_182B0, + texture_font_char_cn_182C0, texture_font_char_cn_182D0, texture_font_char_cn_182E0, texture_font_char_cn_182F0, + texture_font_char_cn_18300, texture_font_char_cn_18310, texture_font_char_cn_18320, texture_font_char_cn_18330, + texture_font_char_cn_18340, texture_font_char_cn_18350, texture_font_char_cn_18360, texture_font_char_cn_18370, + texture_font_char_cn_18380, texture_font_char_cn_18390, texture_font_char_cn_183A0, texture_font_char_cn_183B0, + texture_font_char_cn_183C0, texture_font_char_cn_183D0, texture_font_char_cn_183E0, texture_font_char_cn_183F0, + texture_font_char_cn_18400, texture_font_char_cn_18410, texture_font_char_cn_18420, texture_font_char_cn_18430, + texture_font_char_cn_18440, texture_font_char_cn_18450, texture_font_char_cn_18460, texture_font_char_cn_18470, + texture_font_char_cn_18480, texture_font_char_cn_18490, texture_font_char_cn_184A0, texture_font_char_cn_184B0, + texture_font_char_cn_184C0, texture_font_char_cn_184D0, texture_font_char_cn_184E0, texture_font_char_cn_184F0, + texture_font_char_cn_18500, texture_font_char_cn_18510, texture_font_char_cn_18520, texture_font_char_cn_18530, + texture_font_char_cn_18540, texture_font_char_cn_18550, texture_font_char_cn_18560, texture_font_char_cn_18570, + texture_font_char_cn_18580, texture_font_char_cn_18590, texture_font_char_cn_185A0, texture_font_char_cn_185B0, + texture_font_char_cn_185C0, texture_font_char_cn_185D0, texture_font_char_cn_185E0, texture_font_char_cn_185F0, + texture_font_char_cn_18600, texture_font_char_cn_18610, texture_font_char_cn_18620, texture_font_char_cn_18630, + texture_font_char_cn_18640, texture_font_char_cn_18650, texture_font_char_cn_18660, texture_font_char_cn_18670, + texture_font_char_cn_18680, texture_font_char_cn_18690, texture_font_char_cn_186A0, texture_font_char_cn_186B0, + texture_font_char_cn_186C0, texture_font_char_cn_186D0, texture_font_char_cn_186E0, texture_font_char_cn_186F0, + texture_font_char_cn_18700, texture_font_char_cn_18710, texture_font_char_cn_18720, texture_font_char_cn_18730, + texture_font_char_cn_18740, texture_font_char_cn_18750, texture_font_char_cn_18760, texture_font_char_cn_18770, + texture_font_char_cn_18780, texture_font_char_cn_18790, texture_font_char_cn_187A0, texture_font_char_cn_187B0, + texture_font_char_cn_187C0, texture_font_char_cn_187D0, texture_font_char_cn_187E0, texture_font_char_cn_187F0, + texture_font_char_cn_18800, texture_font_char_cn_18810, texture_font_char_cn_18820, texture_font_char_cn_18830, + texture_font_char_cn_18840, texture_font_char_cn_18850, texture_font_char_cn_18860, texture_font_char_cn_18870, + texture_font_char_cn_18880, texture_font_char_cn_18890, texture_font_char_cn_188A0, texture_font_char_cn_188B0, + texture_font_char_cn_188C0, texture_font_char_cn_188D0, texture_font_char_cn_188E0, texture_font_char_cn_188F0, + texture_font_char_cn_18900, texture_font_char_cn_18910, texture_font_char_cn_18920, texture_font_char_cn_18930, + texture_font_char_cn_18940, texture_font_char_cn_18950, texture_font_char_cn_18960, texture_font_char_cn_18970, + texture_font_char_cn_18980, texture_font_char_cn_18990, texture_font_char_cn_189A0, texture_font_char_cn_189B0, + texture_font_char_cn_189C0, texture_font_char_cn_189D0, texture_font_char_cn_189E0, texture_font_char_cn_189F0, + texture_font_char_cn_18A00, texture_font_char_cn_18A10, texture_font_char_cn_18A20, texture_font_char_cn_18A30, + texture_font_char_cn_18A40, texture_font_char_cn_18A50, texture_font_char_cn_18A60, texture_font_char_cn_18A70, + texture_font_char_cn_18A80, texture_font_char_cn_18A90, texture_font_char_cn_18AA0, texture_font_char_cn_18AB0, + texture_font_char_cn_18AC0, texture_font_char_cn_18AD0, texture_font_char_cn_18AE0, texture_font_char_cn_18AF0, + texture_font_char_cn_18B00, texture_font_char_cn_18B10, texture_font_char_cn_18B20, texture_font_char_cn_18B30, + texture_font_char_cn_18B40, texture_font_char_cn_18B50, texture_font_char_cn_18B60, texture_font_char_cn_18B70, + texture_font_char_cn_18B80, texture_font_char_cn_18B90, texture_font_char_cn_18BA0, texture_font_char_cn_18BB0, + texture_font_char_cn_18BC0, texture_font_char_cn_18BD0, texture_font_char_cn_18BE0, texture_font_char_cn_18BF0, + texture_font_char_cn_18C00, texture_font_char_cn_18C10, texture_font_char_cn_18C20, texture_font_char_cn_18C30, + texture_font_char_cn_18C40, texture_font_char_cn_18C50, texture_font_char_cn_18C60, texture_font_char_cn_18C70, + texture_font_char_cn_18C80, texture_font_char_cn_18C90, texture_font_char_cn_18CA0, texture_font_char_cn_18CB0, + texture_font_char_cn_18CC0, texture_font_char_cn_18CD0, texture_font_char_cn_18CE0, texture_font_char_cn_18CF0, + texture_font_char_cn_18D00, texture_font_char_cn_18D10, texture_font_char_cn_18D20, texture_font_char_cn_18D30, + texture_font_char_cn_18D40, texture_font_char_cn_18D50, texture_font_char_cn_18D60, texture_font_char_cn_18D70, + texture_font_char_cn_18D80, texture_font_char_cn_18D90, texture_font_char_cn_18DA0, texture_font_char_cn_18DB0, + texture_font_char_cn_18DC0, texture_font_char_cn_18DD0, texture_font_char_cn_18DE0, texture_font_char_cn_18DF0, + texture_font_char_cn_18E00, texture_font_char_cn_18E10, texture_font_char_cn_18E20, texture_font_char_cn_18E30, + texture_font_char_cn_18E40, texture_font_char_cn_18E50, texture_font_char_cn_18E60, texture_font_char_cn_18E70, + texture_font_char_cn_18E80, texture_font_char_cn_18E90, texture_font_char_cn_18EA0, texture_font_char_cn_18EB0, + texture_font_char_cn_18EC0, texture_font_char_cn_18ED0, texture_font_char_cn_18EE0, texture_font_char_cn_18EF0, + texture_font_char_cn_18F00, texture_font_char_cn_18F10, texture_font_char_cn_18F20, texture_font_char_cn_18F30, + texture_font_char_cn_18F40, texture_font_char_cn_18F50, texture_font_char_cn_18F60, texture_font_char_cn_18F70, + texture_font_char_cn_18F80, texture_font_char_cn_18F90, texture_font_char_cn_18FA0, texture_font_char_cn_18FB0, + texture_font_char_cn_18FC0, texture_font_char_cn_18FD0, texture_font_char_cn_18FE0, texture_font_char_cn_18FF0, + texture_font_char_cn_19000, texture_font_char_cn_19010, texture_font_char_cn_19020, texture_font_char_cn_19030, + texture_font_char_cn_19040, texture_font_char_cn_19050, texture_font_char_cn_19060, texture_font_char_cn_19070, + texture_font_char_cn_19080, texture_font_char_cn_19090, texture_font_char_cn_190A0, texture_font_char_cn_190B0, + texture_font_char_cn_190C0, texture_font_char_cn_190D0, texture_font_char_cn_190E0, texture_font_char_cn_190F0, + texture_font_char_cn_19100, texture_font_char_cn_19110, texture_font_char_cn_19120, texture_font_char_cn_19130, + texture_font_char_cn_19140, texture_font_char_cn_19150, texture_font_char_cn_19160, texture_font_char_cn_19170, + texture_font_char_cn_19180, texture_font_char_cn_19190, texture_font_char_cn_191A0, texture_font_char_cn_191B0, + texture_font_char_cn_191C0, texture_font_char_cn_191D0, texture_font_char_cn_191E0, texture_font_char_cn_191F0, + texture_font_char_cn_19200, texture_font_char_cn_19210, texture_font_char_cn_19220, texture_font_char_cn_19230, + texture_font_char_cn_19240, texture_font_char_cn_19250, texture_font_char_cn_19260, texture_font_char_cn_19270, + texture_font_char_cn_19280, texture_font_char_cn_19290, texture_font_char_cn_192A0, texture_font_char_cn_192B0, + texture_font_char_cn_192C0, texture_font_char_cn_192D0, texture_font_char_cn_192E0, texture_font_char_cn_192F0, + texture_font_char_cn_19300, texture_font_char_cn_19310, texture_font_char_cn_19320, texture_font_char_cn_19330, + texture_font_char_cn_19340, texture_font_char_cn_19350, texture_font_char_cn_19360, texture_font_char_cn_19370, + texture_font_char_cn_19380, texture_font_char_cn_19390, texture_font_char_cn_193A0, texture_font_char_cn_193B0, + texture_font_char_cn_193C0, texture_font_char_cn_193D0, texture_font_char_cn_193E0, texture_font_char_cn_193F0, + texture_font_char_cn_19400, texture_font_char_cn_19410, texture_font_char_cn_19420, texture_font_char_cn_19430, + texture_font_char_cn_19440, texture_font_char_cn_19450, texture_font_char_cn_19460, texture_font_char_cn_19470, + texture_font_char_cn_19480, texture_font_char_cn_19490, texture_font_char_cn_194A0, texture_font_char_cn_194B0, + texture_font_char_cn_194C0, texture_font_char_cn_194D0, texture_font_char_cn_194E0, texture_font_char_cn_194F0, + texture_font_char_cn_19500, texture_font_char_cn_19510, texture_font_char_cn_19520, texture_font_char_cn_19530, + texture_font_char_cn_19540, texture_font_char_cn_19550, texture_font_char_cn_19560, texture_font_char_cn_19570, + texture_font_char_cn_19580, texture_font_char_cn_19590, texture_font_char_cn_195A0, texture_font_char_cn_195B0, + texture_font_char_cn_195C0, texture_font_char_cn_195D0, texture_font_char_cn_195E0, texture_font_char_cn_195F0, + texture_font_char_cn_19600, texture_font_char_cn_19610, texture_font_char_cn_19620, texture_font_char_cn_19630, + texture_font_char_cn_19640, texture_font_char_cn_19650, texture_font_char_cn_19660, texture_font_char_cn_19670, + texture_font_char_cn_19680, texture_font_char_cn_19690, texture_font_char_cn_196A0, texture_font_char_cn_196B0, + texture_font_char_cn_196C0, texture_font_char_cn_196D0, texture_font_char_cn_196E0, texture_font_char_cn_196F0, + texture_font_char_cn_19700, texture_font_char_cn_19710, texture_font_char_cn_19720, texture_font_char_cn_19730, + texture_font_char_cn_19740, texture_font_char_cn_19750, texture_font_char_cn_19760, texture_font_char_cn_19770, + texture_font_char_cn_19780, texture_font_char_cn_19790, texture_font_char_cn_197A0, texture_font_char_cn_197B0, + texture_font_char_cn_197C0, texture_font_char_cn_197D0, texture_font_char_cn_197E0, texture_font_char_cn_197F0, + texture_font_char_cn_19800, texture_font_char_cn_19810, texture_font_char_cn_19820, texture_font_char_cn_19830, + texture_font_char_cn_19840, texture_font_char_cn_19850, texture_font_char_cn_19860, texture_font_char_cn_19870, + texture_font_char_cn_19880, texture_font_char_cn_19890, texture_font_char_cn_198A0, texture_font_char_cn_198B0, + texture_font_char_cn_198C0, texture_font_char_cn_198D0, texture_font_char_cn_198E0, texture_font_char_cn_198F0, + texture_font_char_cn_19900, texture_font_char_cn_19910, texture_font_char_cn_19920, texture_font_char_cn_19930, + texture_font_char_cn_19940, texture_font_char_cn_19950, texture_font_char_cn_19960, texture_font_char_cn_19970, + texture_font_char_cn_19980, texture_font_char_cn_19990, texture_font_char_cn_199A0, texture_font_char_cn_199B0, + texture_font_char_cn_199C0, texture_font_char_cn_199D0, texture_font_char_cn_199E0, texture_font_char_cn_199F0, + texture_font_char_cn_19A00, texture_font_char_cn_19A10, texture_font_char_cn_19A20, texture_font_char_cn_19A30, + texture_font_char_cn_19A40, texture_font_char_cn_19A50, texture_font_char_cn_19A60, texture_font_char_cn_19A70, + texture_font_char_cn_19A80, texture_font_char_cn_19A90, texture_font_char_cn_19AA0, texture_font_char_cn_19AB0, + texture_font_char_cn_19AC0, texture_font_char_cn_19AD0, texture_font_char_cn_19AE0, texture_font_char_cn_19AF0, + texture_font_char_cn_19B00, texture_font_char_cn_19B10, texture_font_char_cn_19B20, texture_font_char_cn_19B30, + texture_font_char_cn_19B40, texture_font_char_cn_19B50, texture_font_char_cn_19B60, texture_font_char_cn_19B70, + texture_font_char_cn_19B80, texture_font_char_cn_19B90, texture_font_char_cn_19BA0, texture_font_char_cn_19BB0, + texture_font_char_cn_19BC0, texture_font_char_cn_19BD0, texture_font_char_cn_19BE0, texture_font_char_cn_19BF0, + texture_font_char_cn_19C00, texture_font_char_cn_19C10, texture_font_char_cn_19C20, texture_font_char_cn_19C30, + texture_font_char_cn_19C40, texture_font_char_cn_19C50, texture_font_char_cn_19C60, texture_font_char_cn_19C70, + texture_font_char_cn_19C80, texture_font_char_cn_19C90, texture_font_char_cn_19CA0, texture_font_char_cn_19CB0, + texture_font_char_cn_19CC0, texture_font_char_cn_19CD0, texture_font_char_cn_19CE0, texture_font_char_cn_19CF0, + texture_font_char_cn_19D00, texture_font_char_cn_19D10, texture_font_char_cn_19D20, texture_font_char_cn_19D30, + texture_font_char_cn_19D40, texture_font_char_cn_19D50, texture_font_char_cn_19D60, texture_font_char_cn_19D70, + texture_font_char_cn_19D80, texture_font_char_cn_19D90, texture_font_char_cn_19DA0, texture_font_char_cn_19DB0, + texture_font_char_cn_19DC0, texture_font_char_cn_19DD0, texture_font_char_cn_19DE0, texture_font_char_cn_19DF0, + texture_font_char_cn_19E00, texture_font_char_cn_19E10, texture_font_char_cn_19E20, texture_font_char_cn_19E30, + texture_font_char_cn_19E40, texture_font_char_cn_19E50, texture_font_char_cn_19E60, texture_font_char_cn_19E70, + texture_font_char_cn_19E80, texture_font_char_cn_19E90, texture_font_char_cn_19EA0, texture_font_char_cn_19EB0, + texture_font_char_cn_19EC0, texture_font_char_cn_19ED0, texture_font_char_cn_19EE0, texture_font_char_cn_19EF0, + texture_font_char_cn_19F00, texture_font_char_cn_19F10, texture_font_char_cn_19F20, texture_font_char_cn_19F30, + texture_font_char_cn_19F40, texture_font_char_cn_19F50, texture_font_char_cn_19F60, texture_font_char_cn_19F70, + texture_font_char_cn_19F80, texture_font_char_cn_19F90, texture_font_char_cn_19FA0, texture_font_char_cn_19FB0, + texture_font_char_cn_19FC0, texture_font_char_cn_19FD0, texture_font_char_cn_19FE0, texture_font_char_cn_19FF0, + texture_font_char_cn_1A000, texture_font_char_cn_1A010, texture_font_char_cn_1A020, texture_font_char_cn_1A030, + texture_font_char_cn_1A040, texture_font_char_cn_1A050, texture_font_char_cn_1A060, texture_font_char_cn_1A070, + texture_font_char_cn_1A080, texture_font_char_cn_1A090, texture_font_char_cn_1A0A0, texture_font_char_cn_1A0B0, + texture_font_char_cn_1A0C0, texture_font_char_cn_1A0D0, texture_font_char_cn_1A0E0, texture_font_char_cn_1A0F0, + texture_font_char_cn_1A100, texture_font_char_cn_1A110, texture_font_char_cn_1A120, texture_font_char_cn_1A130, + texture_font_char_cn_1A140, texture_font_char_cn_1A150, texture_font_char_cn_1A160, texture_font_char_cn_1A170, + texture_font_char_cn_1A180, texture_font_char_cn_1A190, texture_font_char_cn_1A1A0, texture_font_char_cn_1A1B0, + texture_font_char_cn_1A1C0, texture_font_char_cn_1A1D0, texture_font_char_cn_1A1E0, texture_font_char_cn_1A1F0, + texture_font_char_cn_1A200, texture_font_char_cn_1A210, texture_font_char_cn_1A220, texture_font_char_cn_1A230, + texture_font_char_cn_1A240, texture_font_char_cn_1A250, texture_font_char_cn_1A260, texture_font_char_cn_1A270, + texture_font_char_cn_1A280, texture_font_char_cn_1A290, texture_font_char_cn_1A2A0, texture_font_char_cn_1A2B0, + texture_font_char_cn_1A2C0, texture_font_char_cn_1A2D0, texture_font_char_cn_1A2E0, texture_font_char_cn_1A2F0, + texture_font_char_cn_1A300, texture_font_char_cn_1A310, texture_font_char_cn_1A320, texture_font_char_cn_1A330, + texture_font_char_cn_1A340, texture_font_char_cn_1A350, texture_font_char_cn_1A360, texture_font_char_cn_1A370, + texture_font_char_cn_1A380, texture_font_char_cn_1A390, texture_font_char_cn_1A3A0, texture_font_char_cn_1A3B0, + texture_font_char_cn_1A3C0, texture_font_char_cn_1A3D0, texture_font_char_cn_1A3E0, texture_font_char_cn_1A3F0, + texture_font_char_cn_1A400, texture_font_char_cn_1A410, texture_font_char_cn_1A420, texture_font_char_cn_1A430, + texture_font_char_cn_1A440, texture_font_char_cn_1A450, texture_font_char_cn_1A460, texture_font_char_cn_1A470, + texture_font_char_cn_1A480, texture_font_char_cn_1A490, texture_font_char_cn_1A4A0, texture_font_char_cn_1A4B0, + texture_font_char_cn_1A4C0, texture_font_char_cn_1A4D0, texture_font_char_cn_1A4E0, texture_font_char_cn_1A4F0, + texture_font_char_cn_1A500, texture_font_char_cn_1A510, texture_font_char_cn_1A520, texture_font_char_cn_1A530, + texture_font_char_cn_1A540, texture_font_char_cn_1A550, texture_font_char_cn_1A560, texture_font_char_cn_1A570, + texture_font_char_cn_1A580, texture_font_char_cn_1A590, texture_font_char_cn_1A5A0, texture_font_char_cn_1A5B0, + texture_font_char_cn_1A5C0, texture_font_char_cn_1A5D0, texture_font_char_cn_1A5E0, texture_font_char_cn_1A5F0, + texture_font_char_cn_1A600, texture_font_char_cn_1A610, texture_font_char_cn_1A620, texture_font_char_cn_1A630, + texture_font_char_cn_1A640, texture_font_char_cn_1A650, texture_font_char_cn_1A660, texture_font_char_cn_1A670, + texture_font_char_cn_1A680, texture_font_char_cn_1A690, texture_font_char_cn_1A6A0, texture_font_char_cn_1A6B0, + texture_font_char_cn_1A6C0, texture_font_char_cn_1A6D0, texture_font_char_cn_1A6E0, texture_font_char_cn_1A6F0, + texture_font_char_cn_1A700, texture_font_char_cn_1A710, texture_font_char_cn_1A720, texture_font_char_cn_1A730, + texture_font_char_cn_1A740, texture_font_char_cn_1A750, texture_font_char_cn_1A760, texture_font_char_cn_1A770, + texture_font_char_cn_1A780, texture_font_char_cn_1A790, texture_font_char_cn_1A7A0, texture_font_char_cn_1A7B0, + texture_font_char_cn_1A7C0, texture_font_char_cn_1A7D0, texture_font_char_cn_1A7E0, texture_font_char_cn_1A7F0, + texture_font_char_cn_1A800, texture_font_char_cn_1A810, texture_font_char_cn_1A820, texture_font_char_cn_1A830, + texture_font_char_cn_1A840, texture_font_char_cn_1A850, texture_font_char_cn_1A860, texture_font_char_cn_1A870, + texture_font_char_cn_1A880, texture_font_char_cn_1A890, texture_font_char_cn_1A8A0, texture_font_char_cn_1A8B0, + texture_font_char_cn_1A8C0, texture_font_char_cn_1A8D0, texture_font_char_cn_1A8E0, texture_font_char_cn_1A8F0, + texture_font_char_cn_1A900, texture_font_char_cn_1A910, texture_font_char_cn_1A920, texture_font_char_cn_1A930, + texture_font_char_cn_1A940, texture_font_char_cn_1A950, texture_font_char_cn_1A960, texture_font_char_cn_1A970, + texture_font_char_cn_1A980, texture_font_char_cn_1A990, texture_font_char_cn_1A9A0, texture_font_char_cn_1A9B0, + texture_font_char_cn_1A9C0, texture_font_char_cn_1A9D0, texture_font_char_cn_1A9E0, texture_font_char_cn_1A9F0, + texture_font_char_cn_1AA00, texture_font_char_cn_1AA10, texture_font_char_cn_1AA20, texture_font_char_cn_1AA30, + texture_font_char_cn_1AA40, texture_font_char_cn_1AA50, texture_font_char_cn_1AA60, texture_font_char_cn_1AA70, + texture_font_char_cn_1AA80, texture_font_char_cn_1AA90, texture_font_char_cn_1AAA0, texture_font_char_cn_1AAB0, + texture_font_char_cn_1AAC0, texture_font_char_cn_1AAD0, texture_font_char_cn_1AAE0, texture_font_char_cn_1AAF0, + texture_font_char_cn_1AB00, texture_font_char_cn_1AB10, texture_font_char_cn_1AB20, texture_font_char_cn_1AB30, + texture_font_char_cn_1AB40, texture_font_char_cn_1AB50, texture_font_char_cn_1AB60, texture_font_char_cn_1AB70, + texture_font_char_cn_1AB80, texture_font_char_cn_1AB90, texture_font_char_cn_1ABA0, texture_font_char_cn_1ABB0, + texture_font_char_cn_1ABC0, texture_font_char_cn_1ABD0, texture_font_char_cn_1ABE0, texture_font_char_cn_1ABF0, + texture_font_char_cn_1AC00, texture_font_char_cn_1AC10, texture_font_char_cn_1AC20, texture_font_char_cn_1AC30, + texture_font_char_cn_1AC40, texture_font_char_cn_1AC50, texture_font_char_cn_1AC60, texture_font_char_cn_1AC70, + texture_font_char_cn_1AC80, texture_font_char_cn_1AC90, texture_font_char_cn_1ACA0, texture_font_char_cn_1ACB0, + texture_font_char_cn_1ACC0, texture_font_char_cn_1ACD0, texture_font_char_cn_1ACE0, texture_font_char_cn_1ACF0, + texture_font_char_cn_1AD00, texture_font_char_cn_1AD10, texture_font_char_cn_1AD20, texture_font_char_cn_1AD30, + texture_font_char_cn_1AD40, texture_font_char_cn_1AD50, texture_font_char_cn_1AD60, texture_font_char_cn_1AD70, + texture_font_char_cn_1AD80, texture_font_char_cn_1AD90, texture_font_char_cn_1ADA0, texture_font_char_cn_1ADB0, + texture_font_char_cn_1ADC0, texture_font_char_cn_1ADD0, texture_font_char_cn_1ADE0, texture_font_char_cn_1ADF0, + texture_font_char_cn_1AE00, texture_font_char_cn_1AE10, texture_font_char_cn_1AE20, texture_font_char_cn_1AE30, + texture_font_char_cn_1AE40, texture_font_char_cn_1AE50, texture_font_char_cn_1AE60, texture_font_char_cn_1AE70, + texture_font_char_cn_1AE80, texture_font_char_cn_1AE90, texture_font_char_cn_1AEA0, texture_font_char_cn_1AEB0, + texture_font_char_cn_1AEC0, texture_font_char_cn_1AED0, texture_font_char_cn_1AEE0, texture_font_char_cn_1AEF0, + texture_font_char_cn_1AF00, texture_font_char_cn_1AF10, texture_font_char_cn_1AF20, texture_font_char_cn_1AF30, + texture_font_char_cn_1AF40, texture_font_char_cn_1AF50, texture_font_char_cn_1AF60, texture_font_char_cn_1AF70, + texture_font_char_cn_1AF80, texture_font_char_cn_1AF90, texture_font_char_cn_1AFA0, texture_font_char_cn_1AFB0, + texture_font_char_cn_1AFC0, texture_font_char_cn_1AFD0, texture_font_char_cn_1AFE0, texture_font_char_cn_1AFF0, + texture_font_char_cn_1B000, texture_font_char_cn_1B010, texture_font_char_cn_1B020, texture_font_char_cn_1B030, + texture_font_char_cn_1B040, texture_font_char_cn_1B050, texture_font_char_cn_1B060, texture_font_char_cn_1B070, + texture_font_char_cn_1B080, texture_font_char_cn_1B090, texture_font_char_cn_1B0A0, texture_font_char_cn_1B0B0, + texture_font_char_cn_1B0C0, texture_font_char_cn_1B0D0, texture_font_char_cn_1B0E0, texture_font_char_cn_1B0F0, + texture_font_char_cn_1B100, texture_font_char_cn_1B110, texture_font_char_cn_1B120, texture_font_char_cn_1B130, + texture_font_char_cn_1B140, texture_font_char_cn_1B150, texture_font_char_cn_1B160, texture_font_char_cn_1B170, + texture_font_char_cn_1B180, texture_font_char_cn_1B190, texture_font_char_cn_1B1A0, texture_font_char_cn_1B1B0, + texture_font_char_cn_1B1C0, texture_font_char_cn_1B1D0, texture_font_char_cn_1B1E0, texture_font_char_cn_1B1F0, + texture_font_char_cn_1B200, texture_font_char_cn_1B210, texture_font_char_cn_1B220, texture_font_char_cn_1B230, + texture_font_char_cn_1B240, texture_font_char_cn_1B250, texture_font_char_cn_1B260, texture_font_char_cn_1B270, + texture_font_char_cn_1B280, texture_font_char_cn_1B290, texture_font_char_cn_1B2A0, texture_font_char_cn_1B2B0, + texture_font_char_cn_1B2C0, texture_font_char_cn_1B2D0, texture_font_char_cn_1B2E0, texture_font_char_cn_1B2F0, + texture_font_char_cn_1B300, texture_font_char_cn_1B310, texture_font_char_cn_1B320, texture_font_char_cn_1B330, + texture_font_char_cn_1B340, texture_font_char_cn_1B350, texture_font_char_cn_1B360, texture_font_char_cn_1B370, + texture_font_char_cn_1B380, texture_font_char_cn_1B390, texture_font_char_cn_1B3A0, texture_font_char_cn_1B3B0, + texture_font_char_cn_1B3C0, texture_font_char_cn_1B3D0, texture_font_char_cn_1B3E0, texture_font_char_cn_1B3F0, + texture_font_char_cn_1B400, texture_font_char_cn_1B410, texture_font_char_cn_1B420, texture_font_char_cn_1B430, + texture_font_char_cn_1B440, texture_font_char_cn_1B450, texture_font_char_cn_1B460, texture_font_char_cn_1B470, + texture_font_char_cn_1B480, texture_font_char_cn_1B490, texture_font_char_cn_1B4A0, texture_font_char_cn_1B4B0, + texture_font_char_cn_1B4C0, texture_font_char_cn_1B4D0, texture_font_char_cn_1B4E0, texture_font_char_cn_1B4F0, + texture_font_char_cn_1B500, texture_font_char_cn_1B510, texture_font_char_cn_1B520, texture_font_char_cn_1B530, + texture_font_char_cn_1B540, texture_font_char_cn_1B550, texture_font_char_cn_1B560, texture_font_char_cn_1B570, + texture_font_char_cn_1B580, texture_font_char_cn_1B590, texture_font_char_cn_1B5A0, texture_font_char_cn_1B5B0, + texture_font_char_cn_1B5C0, texture_font_char_cn_1B5D0, texture_font_char_cn_1B5E0, texture_font_char_cn_1B5F0, + texture_font_char_cn_1B600, texture_font_char_cn_1B610, texture_font_char_cn_1B620, texture_font_char_cn_1B630, + texture_font_char_cn_1B640, texture_font_char_cn_1B650, texture_font_char_cn_1B660, texture_font_char_cn_1B670, + texture_font_char_cn_1B680, texture_font_char_cn_1B690, texture_font_char_cn_1B6A0, texture_font_char_cn_1B6B0, + texture_font_char_cn_1B6C0, texture_font_char_cn_1B6D0, texture_font_char_cn_1B6E0, texture_font_char_cn_1B6F0, + texture_font_char_cn_1B700, texture_font_char_cn_1B710, texture_font_char_cn_1B720, texture_font_char_cn_1B730, + texture_font_char_cn_1B740, texture_font_char_cn_1B750, texture_font_char_cn_1B760, texture_font_char_cn_1B770, + texture_font_char_cn_1B780, texture_font_char_cn_1B790, texture_font_char_cn_1B7A0, texture_font_char_cn_1B7B0, + texture_font_char_cn_1B7C0, texture_font_char_cn_1B7D0, texture_font_char_cn_1B7E0, texture_font_char_cn_1B7F0, + texture_font_char_cn_1B800, texture_font_char_cn_1B810, texture_font_char_cn_1B820, texture_font_char_cn_1B830, + texture_font_char_cn_1B840, texture_font_char_cn_1B850, texture_font_char_cn_1B860, texture_font_char_cn_1B870, + texture_font_char_cn_1B880, texture_font_char_cn_1B890, texture_font_char_cn_1B8A0, texture_font_char_cn_1B8B0, + texture_font_char_cn_1B8C0, texture_font_char_cn_1B8D0, texture_font_char_cn_1B8E0, texture_font_char_cn_1B8F0, + texture_font_char_cn_1B900, texture_font_char_cn_1B910, texture_font_char_cn_1B920, texture_font_char_cn_1B930, + texture_font_char_cn_1B940, texture_font_char_cn_1B950, texture_font_char_cn_1B960, texture_font_char_cn_1B970, + texture_font_char_cn_1B980, texture_font_char_cn_1B990, texture_font_char_cn_1B9A0, texture_font_char_cn_1B9B0, + texture_font_char_cn_1B9C0, texture_font_char_cn_1B9D0, texture_font_char_cn_1B9E0, texture_font_char_cn_1B9F0, + texture_font_char_cn_1BA00, texture_font_char_cn_1BA10, texture_font_char_cn_1BA20, texture_font_char_cn_1BA30, + texture_font_char_cn_1BA40, texture_font_char_cn_1BA50, texture_font_char_cn_1BA60, texture_font_char_cn_1BA70, + texture_font_char_cn_1BA80, texture_font_char_cn_1BA90, texture_font_char_cn_1BAA0, texture_font_char_cn_1BAB0, + texture_font_char_cn_1BAC0, texture_font_char_cn_1BAD0, texture_font_char_cn_1BAE0, texture_font_char_cn_1BAF0, + texture_font_char_cn_1BB00, texture_font_char_cn_1BB10, texture_font_char_cn_1BB20, texture_font_char_cn_1BB30, + texture_font_char_cn_1BB40, texture_font_char_cn_1BB50, texture_font_char_cn_1BB60, texture_font_char_cn_1BB70, + texture_font_char_cn_1BB80, texture_font_char_cn_1BB90, texture_font_char_cn_1BBA0, texture_font_char_cn_1BBB0, + texture_font_char_cn_1BBC0, texture_font_char_cn_1BBD0, texture_font_char_cn_1BBE0, texture_font_char_cn_1BBF0, + texture_font_char_cn_1BC00, texture_font_char_cn_1BC10, texture_font_char_cn_1BC20, texture_font_char_cn_1BC30, + texture_font_char_cn_1BC40, texture_font_char_cn_1BC50, texture_font_char_cn_1BC60, texture_font_char_cn_1BC70, + texture_font_char_cn_1BC80, texture_font_char_cn_1BC90, texture_font_char_cn_1BCA0, texture_font_char_cn_1BCB0, + texture_font_char_cn_1BCC0, texture_font_char_cn_1BCD0, texture_font_char_cn_1BCE0, texture_font_char_cn_1BCF0, + texture_font_char_cn_1BD00, texture_font_char_cn_1BD10, texture_font_char_cn_1BD20, texture_font_char_cn_1BD30, + texture_font_char_cn_1BD40, texture_font_char_cn_1BD50, texture_font_char_cn_1BD60, texture_font_char_cn_1BD70, + texture_font_char_cn_1BD80, texture_font_char_cn_1BD90, texture_font_char_cn_1BDA0, texture_font_char_cn_1BDB0, + texture_font_char_cn_1BDC0, texture_font_char_cn_1BDD0, texture_font_char_cn_1BDE0, texture_font_char_cn_1BDF0, + texture_font_char_cn_1BE00, texture_font_char_cn_1BE10, texture_font_char_cn_1BE20, texture_font_char_cn_1BE30, + texture_font_char_cn_1BE40, texture_font_char_cn_1BE50, texture_font_char_cn_1BE60, texture_font_char_cn_1BE70, + texture_font_char_cn_1BE80, texture_font_char_cn_1BE90, texture_font_char_cn_1BEA0, texture_font_char_cn_1BEB0, + texture_font_char_cn_1BEC0, texture_font_char_cn_1BED0, texture_font_char_cn_1BEE0, texture_font_char_cn_1BEF0, + texture_font_char_cn_1BF00, texture_font_char_cn_1BF10, texture_font_char_cn_1BF20, texture_font_char_cn_1BF30, + texture_font_char_cn_1BF40, texture_font_char_cn_1BF50, texture_font_char_cn_1BF60, texture_font_char_cn_1BF70, + texture_font_char_cn_1BF80, texture_font_char_cn_1BF90, texture_font_char_cn_1BFA0, texture_font_char_cn_1BFB0, + texture_font_char_cn_1BFC0, texture_font_char_cn_1BFD0, texture_font_char_cn_1BFE0, texture_font_char_cn_1BFF0, + texture_font_char_cn_1C000, texture_font_char_cn_1C010, texture_font_char_cn_1C020, texture_font_char_cn_1C030, + texture_font_char_cn_1C040, texture_font_char_cn_1C050, texture_font_char_cn_1C060, texture_font_char_cn_1C070, + texture_font_char_cn_1C080, texture_font_char_cn_1C090, texture_font_char_cn_1C0A0, texture_font_char_cn_1C0B0, + texture_font_char_cn_1C0C0, texture_font_char_cn_1C0D0, texture_font_char_cn_1C0E0, texture_font_char_cn_1C0F0, + texture_font_char_cn_1C100, texture_font_char_cn_1C110, texture_font_char_cn_1C120, texture_font_char_cn_1C130, + texture_font_char_cn_1C140, texture_font_char_cn_1C150, texture_font_char_cn_1C160, texture_font_char_cn_1C170, + texture_font_char_cn_1C180, texture_font_char_cn_1C190, texture_font_char_cn_1C1A0, texture_font_char_cn_1C1B0, + texture_font_char_cn_1C1C0, texture_font_char_cn_1C1D0, texture_font_char_cn_1C1E0, texture_font_char_cn_1C1F0, + texture_font_char_cn_1C200, texture_font_char_cn_1C210, texture_font_char_cn_1C220, texture_font_char_cn_1C230, + texture_font_char_cn_1C240, texture_font_char_cn_1C250, texture_font_char_cn_1C260, texture_font_char_cn_1C270, + texture_font_char_cn_1C280, texture_font_char_cn_1C290, texture_font_char_cn_1C2A0, texture_font_char_cn_1C2B0, + texture_font_char_cn_1C2C0, texture_font_char_cn_1C2D0, texture_font_char_cn_1C2E0, texture_font_char_cn_1C2F0, + texture_font_char_cn_1C300, texture_font_char_cn_1C310, texture_font_char_cn_1C320, texture_font_char_cn_1C330, + texture_font_char_cn_1C340, texture_font_char_cn_1C350, texture_font_char_cn_1C360, texture_font_char_cn_1C370, + texture_font_char_cn_1C380, texture_font_char_cn_1C390, texture_font_char_cn_1C3A0, texture_font_char_cn_1C3B0, + texture_font_char_cn_1C3C0, texture_font_char_cn_1C3D0, texture_font_char_cn_1C3E0, texture_font_char_cn_1C3F0, + texture_font_char_cn_1C400, texture_font_char_cn_1C410, texture_font_char_cn_1C420, texture_font_char_cn_1C430, + texture_font_char_cn_1C440, texture_font_char_cn_1C450, texture_font_char_cn_1C460, texture_font_char_cn_1C470, + texture_font_char_cn_1C480, texture_font_char_cn_1C490, texture_font_char_cn_1C4A0, texture_font_char_cn_1C4B0, + texture_font_char_cn_1C4C0, texture_font_char_cn_1C4D0, texture_font_char_cn_1C4E0, texture_font_char_cn_1C4F0, + texture_font_char_cn_1C500, texture_font_char_cn_1C510, texture_font_char_cn_1C520, texture_font_char_cn_1C530, + texture_font_char_cn_1C540, texture_font_char_cn_1C550, texture_font_char_cn_1C560, texture_font_char_cn_1C570, + texture_font_char_cn_1C580, texture_font_char_cn_1C590, texture_font_char_cn_1C5A0, texture_font_char_cn_1C5B0, + texture_font_char_cn_1C5C0, texture_font_char_cn_1C5D0, texture_font_char_cn_1C5E0, texture_font_char_cn_1C5F0, + texture_font_char_cn_1C600, texture_font_char_cn_1C610, texture_font_char_cn_1C620, texture_font_char_cn_1C630, + texture_font_char_cn_1C640, texture_font_char_cn_1C650, texture_font_char_cn_1C660, texture_font_char_cn_1C670, + texture_font_char_cn_1C680, texture_font_char_cn_1C690, texture_font_char_cn_1C6A0, texture_font_char_cn_1C6B0, + texture_font_char_cn_1C6C0, texture_font_char_cn_1C6D0, texture_font_char_cn_1C6E0, texture_font_char_cn_1C6F0, + texture_font_char_cn_1C700, texture_font_char_cn_1C710, texture_font_char_cn_1C720, texture_font_char_cn_1C730, + texture_font_char_cn_1C740, texture_font_char_cn_1C750, texture_font_char_cn_1C760, texture_font_char_cn_1C770, + texture_font_char_cn_1C780, texture_font_char_cn_1C790, texture_font_char_cn_1C7A0, texture_font_char_cn_1C7B0, + texture_font_char_cn_1C7C0, texture_font_char_cn_1C7D0, texture_font_char_cn_1C7E0, texture_font_char_cn_1C7F0, + texture_font_char_cn_1C800, texture_font_char_cn_1C810, texture_font_char_cn_1C820, texture_font_char_cn_1C830, + texture_font_char_cn_1C840, texture_font_char_cn_1C850, texture_font_char_cn_1C860, texture_font_char_cn_1C870, + texture_font_char_cn_1C880, texture_font_char_cn_1C890, texture_font_char_cn_1C8A0, texture_font_char_cn_1C8B0, + texture_font_char_cn_1C8C0, texture_font_char_cn_1C8D0, texture_font_char_cn_1C8E0, texture_font_char_cn_1C8F0, + texture_font_char_cn_1C900, texture_font_char_cn_1C910, texture_font_char_cn_1C920, texture_font_char_cn_1C930, + texture_font_char_cn_1C940, texture_font_char_cn_1C950, texture_font_char_cn_1C960, texture_font_char_cn_1C970, + texture_font_char_cn_1C980, texture_font_char_cn_1C990, texture_font_char_cn_1C9A0, texture_font_char_cn_1C9B0, + texture_font_char_cn_1C9C0, texture_font_char_cn_1C9D0, texture_font_char_cn_1C9E0, texture_font_char_cn_1C9F0, + texture_font_char_cn_1CA00, texture_font_char_cn_1CA10, texture_font_char_cn_1CA20, texture_font_char_cn_1CA30, + texture_font_char_cn_1CA40, texture_font_char_cn_1CA50, texture_font_char_cn_1CA60, texture_font_char_cn_1CA70, + texture_font_char_cn_1CA80, texture_font_char_cn_1CA90, texture_font_char_cn_1CAA0, texture_font_char_cn_1CAB0, + texture_font_char_cn_1CAC0, texture_font_char_cn_1CAD0, texture_font_char_cn_1CAE0, texture_font_char_cn_1CAF0, + texture_font_char_cn_1CB00, texture_font_char_cn_1CB10, texture_font_char_cn_1CB20, texture_font_char_cn_1CB30, + texture_font_char_cn_1CB40, texture_font_char_cn_1CB50, texture_font_char_cn_1CB60, texture_font_char_cn_1CB70, + texture_font_char_cn_1CB80, texture_font_char_cn_1CB90, texture_font_char_cn_1CBA0, texture_font_char_cn_1CBB0, + texture_font_char_cn_1CBC0, texture_font_char_cn_1CBD0, texture_font_char_cn_1CBE0, texture_font_char_cn_1CBF0, + texture_font_char_cn_1CC00, texture_font_char_cn_1CC10, texture_font_char_cn_1CC20, texture_font_char_cn_1CC30, + texture_font_char_cn_1CC40, texture_font_char_cn_1CC50, texture_font_char_cn_1CC60, texture_font_char_cn_1CC70, + texture_font_char_cn_1CC80, texture_font_char_cn_1CC90, texture_font_char_cn_1CCA0, texture_font_char_cn_1CCB0, + texture_font_char_cn_1CCC0, texture_font_char_cn_1CCD0, texture_font_char_cn_1CCE0, texture_font_char_cn_1CCF0, + texture_font_char_cn_1CD00, texture_font_char_cn_1CD10, texture_font_char_cn_1CD20, texture_font_char_cn_1CD30, + texture_font_char_cn_1CD40, texture_font_char_cn_1CD50, texture_font_char_cn_1CD60, texture_font_char_cn_1CD70, + texture_font_char_cn_1CD80, texture_font_char_cn_1CD90, texture_font_char_cn_1CDA0, texture_font_char_cn_1CDB0, + texture_font_char_cn_1CDC0, texture_font_char_cn_1CDD0, texture_font_char_cn_1CDE0, texture_font_char_cn_1CDF0, + texture_font_char_cn_1CE00, texture_font_char_cn_1CE10, texture_font_char_cn_1CE20, texture_font_char_cn_1CE30, + texture_font_char_cn_1CE40, texture_font_char_cn_1CE50, texture_font_char_cn_1CE60, texture_font_char_cn_1CE70, + texture_font_char_cn_1CE80, texture_font_char_cn_1CE90, texture_font_char_cn_1CEA0, texture_font_char_cn_1CEB0, + texture_font_char_cn_1CEC0, texture_font_char_cn_1CED0, texture_font_char_cn_1CEE0, texture_font_char_cn_1CEF0, + texture_font_char_cn_1CF00, texture_font_char_cn_1CF10, texture_font_char_cn_1CF20, texture_font_char_cn_1CF30, + texture_font_char_cn_1CF40, texture_font_char_cn_1CF50, texture_font_char_cn_1CF60, texture_font_char_cn_1CF70, + texture_font_char_cn_1CF80, texture_font_char_cn_1CF90, texture_font_char_cn_1CFA0, texture_font_char_cn_1CFB0, + texture_font_char_cn_1CFC0, texture_font_char_cn_1CFD0, texture_font_char_cn_1CFE0, texture_font_char_cn_1CFF0, + texture_font_char_cn_1D000, texture_font_char_cn_1D010, texture_font_char_cn_1D020, texture_font_char_cn_1D030, + texture_font_char_cn_1D040, texture_font_char_cn_1D050, texture_font_char_cn_1D060, texture_font_char_cn_1D070, + texture_font_char_cn_1D080, texture_font_char_cn_1D090, texture_font_char_cn_1D0A0, texture_font_char_cn_1D0B0, + texture_font_char_cn_1D0C0, texture_font_char_cn_1D0D0, texture_font_char_cn_1D0E0, texture_font_char_cn_1D0F0, + texture_font_char_cn_1D100, texture_font_char_cn_1D110, texture_font_char_cn_1D120, texture_font_char_cn_1D130, + texture_font_char_cn_1D140, texture_font_char_cn_1D150, texture_font_char_cn_1D160, texture_font_char_cn_1D170, + texture_font_char_cn_1D180, texture_font_char_cn_1D190, texture_font_char_cn_1D1A0, texture_font_char_cn_1D1B0, + texture_font_char_cn_1D1C0, texture_font_char_cn_1D1D0, texture_font_char_cn_1D1E0, texture_font_char_cn_1D1F0, + texture_font_char_cn_1D200, texture_font_char_cn_1D210, texture_font_char_cn_1D220, texture_font_char_cn_1D230, + texture_font_char_cn_1D240, texture_font_char_cn_1D250, texture_font_char_cn_1D260, texture_font_char_cn_1D270, + texture_font_char_cn_1D280, texture_font_char_cn_1D290, texture_font_char_cn_1D2A0, texture_font_char_cn_1D2B0, + texture_font_char_cn_1D2C0, texture_font_char_cn_1D2D0, texture_font_char_cn_1D2E0, texture_font_char_cn_1D2F0, + texture_font_char_cn_1D300, texture_font_char_cn_1D310, texture_font_char_cn_1D320, texture_font_char_cn_1D330, + texture_font_char_cn_1D340, texture_font_char_cn_1D350, texture_font_char_cn_1D360, texture_font_char_cn_1D370, + texture_font_char_cn_1D380, texture_font_char_cn_1D390, texture_font_char_cn_1D3A0, texture_font_char_cn_1D3B0, + texture_font_char_cn_1D3C0, texture_font_char_cn_1D3D0, texture_font_char_cn_1D3E0, texture_font_char_cn_1D3F0, + texture_font_char_cn_1D400, texture_font_char_cn_1D410, texture_font_char_cn_1D420, texture_font_char_cn_1D430, + texture_font_char_cn_1D440, texture_font_char_cn_1D450, texture_font_char_cn_1D460, texture_font_char_cn_1D470, + texture_font_char_cn_1D480, texture_font_char_cn_1D490, texture_font_char_cn_1D4A0, texture_font_char_cn_1D4B0, + texture_font_char_cn_1D4C0, texture_font_char_cn_1D4D0, texture_font_char_cn_1D4E0, texture_font_char_cn_1D4F0, + texture_font_char_cn_1D500, texture_font_char_cn_1D510, texture_font_char_cn_1D520, texture_font_char_cn_1D530, + texture_font_char_cn_1D540, texture_font_char_cn_1D550, texture_font_char_cn_1D560, texture_font_char_cn_1D570, + texture_font_char_cn_1D580, texture_font_char_cn_1D590, texture_font_char_cn_1D5A0, texture_font_char_cn_1D5B0, + texture_font_char_cn_1D5C0, texture_font_char_cn_1D5D0, texture_font_char_cn_1D5E0, texture_font_char_cn_1D5F0, + texture_font_char_cn_1D600, texture_font_char_cn_1D610, texture_font_char_cn_1D620, texture_font_char_cn_1D630, + texture_font_char_cn_1D640, texture_font_char_cn_1D650, texture_font_char_cn_1D660, texture_font_char_cn_1D670, + texture_font_char_cn_1D680, texture_font_char_cn_1D690, texture_font_char_cn_1D6A0, texture_font_char_cn_1D6B0, + texture_font_char_cn_1D6C0, texture_font_char_cn_1D6D0, texture_font_char_cn_1D6E0, texture_font_char_cn_1D6F0, + texture_font_char_cn_1D700, texture_font_char_cn_1D710, texture_font_char_cn_1D720, texture_font_char_cn_1D730, + texture_font_char_cn_1D740, texture_font_char_cn_1D750, texture_font_char_cn_1D760, texture_font_char_cn_1D770, + texture_font_char_cn_1D780, texture_font_char_cn_1D790, texture_font_char_cn_1D7A0, texture_font_char_cn_1D7B0, + texture_font_char_cn_1D7C0, texture_font_char_cn_1D7D0, texture_font_char_cn_1D7E0, texture_font_char_cn_1D7F0, + texture_font_char_cn_1D800, texture_font_char_cn_1D810, texture_font_char_cn_1D820, texture_font_char_cn_1D830, + texture_font_char_cn_1D840, texture_font_char_cn_1D850, texture_font_char_cn_1D860, texture_font_char_cn_1D870, + texture_font_char_cn_1D880, texture_font_char_cn_1D890, texture_font_char_cn_1D8A0, texture_font_char_cn_1D8B0, + texture_font_char_cn_1D8C0, texture_font_char_cn_1D8D0, texture_font_char_cn_1D8E0, texture_font_char_cn_1D8F0, + texture_font_char_cn_1D900, texture_font_char_cn_1D910, texture_font_char_cn_1D920, texture_font_char_cn_1D930, + texture_font_char_cn_1D940, texture_font_char_cn_1D950, texture_font_char_cn_1D960, texture_font_char_cn_1D970, + texture_font_char_cn_1D980, texture_font_char_cn_1D990, texture_font_char_cn_1D9A0, texture_font_char_cn_1D9B0, + texture_font_char_cn_1D9C0, texture_font_char_cn_1D9D0, texture_font_char_cn_1D9E0, texture_font_char_cn_1D9F0, + texture_font_char_cn_1DA00, texture_font_char_cn_1DA10, texture_font_char_cn_1DA20, texture_font_char_cn_1DA30, + texture_font_char_cn_1DA40, texture_font_char_cn_1DA50, texture_font_char_cn_1DA60, texture_font_char_cn_1DA70, + texture_font_char_cn_1DA80, texture_font_char_cn_1DA90, texture_font_char_cn_1DAA0, texture_font_char_cn_1DAB0, + texture_font_char_cn_1DAC0, texture_font_char_cn_1DAD0, texture_font_char_cn_1DAE0, texture_font_char_cn_1DAF0, + texture_font_char_cn_1DB00, texture_font_char_cn_1DB10, texture_font_char_cn_1DB20, texture_font_char_cn_1DB30, + texture_font_char_cn_1DB40, texture_font_char_cn_1DB50, texture_font_char_cn_1DB60, texture_font_char_cn_1DB70, + texture_font_char_cn_1DB80, texture_font_char_cn_1DB90, texture_font_char_cn_1DBA0, texture_font_char_cn_1DBB0, + texture_font_char_cn_1DBC0, texture_font_char_cn_1DBD0, texture_font_char_cn_1DBE0, texture_font_char_cn_1DBF0, + texture_font_char_cn_1DC00, texture_font_char_cn_1DC10, texture_font_char_cn_1DC20, texture_font_char_cn_1DC30, + texture_font_char_cn_1DC40, texture_font_char_cn_1DC50, texture_font_char_cn_1DC60, texture_font_char_cn_1DC70, + texture_font_char_cn_1DC80, texture_font_char_cn_1DC90, texture_font_char_cn_1DCA0, texture_font_char_cn_1DCB0, + texture_font_char_cn_1DCC0, texture_font_char_cn_1DCD0, texture_font_char_cn_1DCE0, texture_font_char_cn_1DCF0, + texture_font_char_cn_1DD00, texture_font_char_cn_1DD10, texture_font_char_cn_1DD20, texture_font_char_cn_1DD30, + texture_font_char_cn_1DD40, texture_font_char_cn_1DD50, texture_font_char_cn_1DD60, texture_font_char_cn_1DD70, + texture_font_char_cn_1DD80, texture_font_char_cn_1DD90, texture_font_char_cn_1DDA0, texture_font_char_cn_1DDB0, + texture_font_char_cn_1DDC0, texture_font_char_cn_1DDD0, texture_font_char_cn_1DDE0, texture_font_char_cn_1DDF0, + texture_font_char_cn_1DE00, texture_font_char_cn_1DE10, texture_font_char_cn_1DE20, texture_font_char_cn_1DE30, + texture_font_char_cn_1DE40, texture_font_char_cn_1DE50, texture_font_char_cn_1DE60, texture_font_char_cn_1DE70, + texture_font_char_cn_1DE80, texture_font_char_cn_1DE90, texture_font_char_cn_1DEA0, texture_font_char_cn_1DEB0, + texture_font_char_cn_1DEC0, texture_font_char_cn_1DED0, texture_font_char_cn_1DEE0, texture_font_char_cn_1DEF0, + texture_font_char_cn_1DF00, texture_font_char_cn_1DF10, texture_font_char_cn_1DF20, texture_font_char_cn_1DF30, + texture_font_char_cn_1DF40, texture_font_char_cn_1DF50, texture_font_char_cn_1DF60, texture_font_char_cn_1DF70, + texture_font_char_cn_1DF80, texture_font_char_cn_1DF90, texture_font_char_cn_1DFA0, texture_font_char_cn_1DFB0, + texture_font_char_cn_1DFC0, texture_font_char_cn_1DFD0, texture_font_char_cn_1DFE0, texture_font_char_cn_1DFF0, + texture_font_char_cn_1E000, texture_font_char_cn_1E010, texture_font_char_cn_1E020, texture_font_char_cn_1E030, + texture_font_char_cn_1E040, texture_font_char_cn_1E050, texture_font_char_cn_1E060, texture_font_char_cn_1E070, + texture_font_char_cn_1E080, texture_font_char_cn_1E090, texture_font_char_cn_1E0A0, texture_font_char_cn_1E0B0, + texture_font_char_cn_1E0C0, texture_font_char_cn_1E0D0, texture_font_char_cn_1E0E0, texture_font_char_cn_1E0F0, + texture_font_char_cn_1E100, texture_font_char_cn_1E110, texture_font_char_cn_1E120, texture_font_char_cn_1E130, + texture_font_char_cn_1E140, texture_font_char_cn_1E150, texture_font_char_cn_1E160, texture_font_char_cn_1E170, + texture_font_char_cn_1E180, texture_font_char_cn_1E190, texture_font_char_cn_1E1A0, texture_font_char_cn_1E1B0, + texture_font_char_cn_1E1C0, texture_font_char_cn_1E1D0, texture_font_char_cn_1E1E0, texture_font_char_cn_1E1F0, + texture_font_char_cn_1E200, texture_font_char_cn_1E210, texture_font_char_cn_1E220, texture_font_char_cn_1E230, + texture_font_char_cn_1E240, texture_font_char_cn_1E250, texture_font_char_cn_1E260, texture_font_char_cn_1E270, + texture_font_char_cn_1E280, texture_font_char_cn_1E290, texture_font_char_cn_1E2A0, texture_font_char_cn_1E2B0, + texture_font_char_cn_1E2C0, texture_font_char_cn_1E2D0, texture_font_char_cn_1E2E0, texture_font_char_cn_1E2F0, + texture_font_char_cn_1E300, texture_font_char_cn_1E310, texture_font_char_cn_1E320, texture_font_char_cn_1E330, + texture_font_char_cn_1E340, texture_font_char_cn_1E350, texture_font_char_cn_1E360, texture_font_char_cn_1E370, + texture_font_char_cn_1E380, texture_font_char_cn_1E390, texture_font_char_cn_1E3A0, texture_font_char_cn_1E3B0, + texture_font_char_cn_1E3C0, texture_font_char_cn_1E3D0, texture_font_char_cn_1E3E0, texture_font_char_cn_1E3F0, + texture_font_char_cn_1E400, texture_font_char_cn_1E410, texture_font_char_cn_1E420, texture_font_char_cn_1E430, + texture_font_char_cn_1E440, texture_font_char_cn_1E450, texture_font_char_cn_1E460, texture_font_char_cn_1E470, + texture_font_char_cn_1E480, texture_font_char_cn_1E490, texture_font_char_cn_1E4A0, texture_font_char_cn_1E4B0, + texture_font_char_cn_1E4C0, texture_font_char_cn_1E4D0, texture_font_char_cn_1E4E0, texture_font_char_cn_1E4F0, + texture_font_char_cn_1E500, texture_font_char_cn_1E510, texture_font_char_cn_1E520, texture_font_char_cn_1E530, + texture_font_char_cn_1E540, texture_font_char_cn_1E550, texture_font_char_cn_1E560, texture_font_char_cn_1E570, + texture_font_char_cn_1E580, texture_font_char_cn_1E590, texture_font_char_cn_1E5A0, texture_font_char_cn_1E5B0, + texture_font_char_cn_1E5C0, texture_font_char_cn_1E5D0, texture_font_char_cn_1E5E0, texture_font_char_cn_1E5F0, + texture_font_char_cn_1E600, texture_font_char_cn_1E610, texture_font_char_cn_1E620, texture_font_char_cn_1E630, + texture_font_char_cn_1E640, texture_font_char_cn_1E650, texture_font_char_cn_1E660, texture_font_char_cn_1E670, + texture_font_char_cn_1E680, texture_font_char_cn_1E690, texture_font_char_cn_1E6A0, texture_font_char_cn_1E6B0, + texture_font_char_cn_1E6C0, texture_font_char_cn_1E6D0, texture_font_char_cn_1E6E0, texture_font_char_cn_1E6F0, + texture_font_char_cn_1E700, texture_font_char_cn_1E710, texture_font_char_cn_1E720, texture_font_char_cn_1E730, + texture_font_char_cn_1E740, texture_font_char_cn_1E750, texture_font_char_cn_1E760, texture_font_char_cn_1E770, + texture_font_char_cn_1E780, texture_font_char_cn_1E790, texture_font_char_cn_1E7A0, texture_font_char_cn_1E7B0, + texture_font_char_cn_1E7C0, texture_font_char_cn_1E7D0, texture_font_char_cn_1E7E0, texture_font_char_cn_1E7F0, + texture_font_char_cn_1E800, texture_font_char_cn_1E810, texture_font_char_cn_1E820, texture_font_char_cn_1E830, + texture_font_char_cn_1E840, texture_font_char_cn_1E850, texture_font_char_cn_1E860, texture_font_char_cn_1E870, + texture_font_char_cn_1E880, texture_font_char_cn_1E890, texture_font_char_cn_1E8A0, texture_font_char_cn_1E8B0, + texture_font_char_cn_1E8C0, texture_font_char_cn_1E8D0, texture_font_char_cn_1E8E0, texture_font_char_cn_1E8F0, + texture_font_char_cn_1E900, texture_font_char_cn_1E910, texture_font_char_cn_1E920, texture_font_char_cn_1E930, + texture_font_char_cn_1E940, texture_font_char_cn_1E950, texture_font_char_cn_1E960, texture_font_char_cn_1E970, + texture_font_char_cn_1E980, texture_font_char_cn_1E990, texture_font_char_cn_1E9A0, texture_font_char_cn_1E9B0, + texture_font_char_cn_1E9C0, texture_font_char_cn_1E9D0, texture_font_char_cn_1E9E0, texture_font_char_cn_1E9F0, + texture_font_char_cn_1EA00, texture_font_char_cn_1EA10, texture_font_char_cn_1EA20, texture_font_char_cn_1EA30, + texture_font_char_cn_1EA40, texture_font_char_cn_1EA50, texture_font_char_cn_1EA60, texture_font_char_cn_1EA70, + texture_font_char_cn_1EA80, texture_font_char_cn_1EA90, texture_font_char_cn_1EAA0, texture_font_char_cn_1EAB0, + texture_font_char_cn_1EAC0, texture_font_char_cn_1EAD0, texture_font_char_cn_1EAE0, texture_font_char_cn_1EAF0, + texture_font_char_cn_1EB00, texture_font_char_cn_1EB10, texture_font_char_cn_1EB20, texture_font_char_cn_1EB30, + texture_font_char_cn_1EB40, texture_font_char_cn_1EB50, texture_font_char_cn_1EB60, texture_font_char_cn_1EB70, + texture_font_char_cn_1EB80, texture_font_char_cn_1EB90, texture_font_char_cn_1EBA0, texture_font_char_cn_1EBB0, + texture_font_char_cn_1EBC0, texture_font_char_cn_1EBD0, texture_font_char_cn_1EBE0, texture_font_char_cn_1EBF0, + texture_font_char_cn_1EC00, texture_font_char_cn_1EC10, texture_font_char_cn_1EC20, texture_font_char_cn_1EC30, + texture_font_char_cn_1EC40, texture_font_char_cn_1EC50, texture_font_char_cn_1EC60, texture_font_char_cn_1EC70, + texture_font_char_cn_1EC80, texture_font_char_cn_1EC90, texture_font_char_cn_1ECA0, texture_font_char_cn_1ECB0, + texture_font_char_cn_1ECC0, texture_font_char_cn_1ECD0, texture_font_char_cn_1ECE0, texture_font_char_cn_1ECF0, + texture_font_char_cn_1ED00, texture_font_char_cn_1ED10, texture_font_char_cn_1ED20, texture_font_char_cn_1ED30, + texture_font_char_cn_1ED40, texture_font_char_cn_1ED50, texture_font_char_cn_1ED60, texture_font_char_cn_1ED70, + texture_font_char_cn_1ED80, texture_font_char_cn_1ED90, texture_font_char_cn_1EDA0, texture_font_char_cn_1EDB0, + texture_font_char_cn_1EDC0, texture_font_char_cn_1EDD0, texture_font_char_cn_1EDE0, texture_font_char_cn_1EDF0, + texture_font_char_cn_1EE00, texture_font_char_cn_1EE10, texture_font_char_cn_1EE20, texture_font_char_cn_1EE30, + texture_font_char_cn_1EE40, texture_font_char_cn_1EE50, texture_font_char_cn_1EE60, texture_font_char_cn_1EE70, +#endif // VERSION_CN #elif defined(VERSION_JP) || defined(VERSION_SH) texture_font_char_jp_0, texture_font_char_jp_1, texture_font_char_jp_2, texture_font_char_jp_3, texture_font_char_jp_4, texture_font_char_jp_5, texture_font_char_jp_6, texture_font_char_jp_7, @@ -2079,6 +11754,8 @@ const Texture *const main_hud_camera_lut[] = { texture_hud_char_arrow_up, texture_hud_char_arrow_down, }; +#include "text/debug_text.raw.inc.c" + // If you change the language here, the following Makefile rule also needs to // change, to generate the right version of define_text.inc.c: // $(BUILD_DIR)/bin/segment2.o: $(BUILD_DIR)/text/$(VERSION)/define_text.inc.c @@ -2086,6 +11763,8 @@ const Texture *const main_hud_camera_lut[] = { #include "text/jp/define_text.inc.c" #elif defined(VERSION_US) #include "text/us/define_text.inc.c" +#elif defined(VERSION_CN) +#include "text/cn/define_text.inc.c" #endif UNUSED static const u64 segment2_unused_0 = 0; @@ -2194,6 +11873,11 @@ static const Vtx vertex_ia8_char[] = { {{{ 8, 0, 0}, 0, { 512, 1024}, {0xff, 0xff, 0xff, 0xff}}}, {{{ 8, 16, 0}, 0, { 512, 0}, {0xff, 0xff, 0xff, 0xff}}}, {{{ 0, 16, 0}, 0, { 0, 0}, {0xff, 0xff, 0xff, 0xff}}}, +#elif defined(VERSION_CN) + {{{ 0, 0, 0}, 0, { 0, 256}, {0xff, 0xff, 0xff, 0xff}}}, + {{{ 8, 0, 0}, 0, { 0, 0}, {0xff, 0xff, 0xff, 0xff}}}, + {{{ 8, 16, 0}, 0, { 512, 0}, {0xff, 0xff, 0xff, 0xff}}}, + {{{ 0, 16, 0}, 0, { 512, 256}, {0xff, 0xff, 0xff, 0xff}}}, #else {{{ 0, 0, 0}, 0, { 0, 256}, {0xff, 0xff, 0xff, 0xff}}}, {{{ 8, 0, 0}, 0, { 0, 0}, {0xff, 0xff, 0xff, 0xff}}}, @@ -2237,7 +11921,7 @@ const Gfx dl_ia_text_end[] = { gsSPEndDisplayList(), }; -#elif defined(VERSION_US) +#elif defined(VERSION_US) || defined(VERSION_CN) const Gfx dl_ia_text_begin[] = { gsDPPipeSync(), gsSPClearGeometryMode(G_LIGHTING), diff --git a/bin/title_screen_bg.c b/bin/title_screen_bg.c index d6deb092..1aba517d 100644 --- a/bin/title_screen_bg.c +++ b/bin/title_screen_bg.c @@ -71,6 +71,50 @@ const Gfx title_screen_bg_dl_0A000190[] = { gsSPEndDisplayList(), }; +#if defined(VERSION_CN) + +// 0x0A0001C0 +ALIGNED8 static const Texture title_texture_0A0001C0[] = { +#include "textures/title_screen_bg/title_screen_bg_ique.001C0.rgba16.inc.c" +}; + +// 0x0A000E40 +ALIGNED8 static const Texture title_texture_0A000E40[] = { +#include "textures/title_screen_bg/title_screen_bg_ique.00E40.rgba16.inc.c" +}; + +// 0x0A001AC0 +ALIGNED8 static const Texture title_texture_0A001AC0[] = { +#include "textures/title_screen_bg/title_screen_bg_ique.01AC0.rgba16.inc.c" +}; + +// 0x0A002740 +ALIGNED8 static const Texture title_texture_0A002740[] = { +#include "textures/title_screen_bg/title_screen_bg_ique.02740.rgba16.inc.c" +}; + +// 0x0A0033C0 +ALIGNED8 static const Texture title_texture_0A0033C0[] = { +#include "textures/title_screen_bg/title_screen_bg_ique.033C0.rgba16.inc.c" +}; + +// 0x0A004040 +ALIGNED8 static const Texture title_texture_0A004040[] = { +#include "textures/title_screen_bg/title_screen_bg_ique.04040.rgba16.inc.c" +}; + +// 0x0A004CC0 +ALIGNED8 static const Texture title_texture_0A004CC0[] = { +#include "textures/title_screen_bg/title_screen_bg_ique.04CC0.rgba16.inc.c" +}; + +// 0x0A005940 +ALIGNED8 static const Texture title_texture_0A005940[] = { +#include "textures/title_screen_bg/title_screen_bg_ique.05940.rgba16.inc.c" +}; + +#else + // 0x0A0001C0 ALIGNED8 static const Texture title_texture_0A0001C0[] = { #include "textures/title_screen_bg/title_screen_bg.001C0.rgba16.inc.c" @@ -111,6 +155,8 @@ ALIGNED8 static const Texture title_texture_0A005940[] = { #include "textures/title_screen_bg/title_screen_bg.05940.rgba16.inc.c" }; +#endif + // 0x0A0065C0 const Texture *const mario_title_texture_table[] = { title_texture_0A0001C0, title_texture_0A000E40, title_texture_0A001AC0, title_texture_0A002740, @@ -123,7 +169,7 @@ const Texture *const game_over_texture_table[] = { UNUSED static const u64 title_screen_bg_unused_0 = 0; -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) const Gfx title_screen_bg_dl_0A0065E8[] = { gsDPPipeSync(), gsDPSetCycleType(G_CYC_COPY), diff --git a/charmap.txt b/charmap.txt index 49aaee55..57d9f741 100644 --- a/charmap.txt +++ b/charmap.txt @@ -1,257 +1,269 @@ -'0' = 0x00 -'0' = 0x00 -'1' = 0x01 -'1' = 0x01 -'2' = 0x02 -'2' = 0x02 -'3' = 0x03 -'3' = 0x03 -'4' = 0x04 -'4' = 0x04 -'5' = 0x05 -'5' = 0x05 -'6' = 0x06 -'6' = 0x06 -'7' = 0x07 -'7' = 0x07 -'8' = 0x08 -'8' = 0x08 -'9' = 0x09 -'9' = 0x09 -'A' = 0x0A -'A' = 0x0A -'B' = 0x0B -'B' = 0x0B -'C' = 0x0C -'C' = 0x0C -'D' = 0x0D -'D' = 0x0D -'E' = 0x0E -'E' = 0x0E -'F' = 0x0F -'F' = 0x0F -'G' = 0x10 -'G' = 0x10 -'H' = 0x11 -'H' = 0x11 -'I' = 0x12 -'I' = 0x12 -'J' = 0x13 -'J' = 0x13 -'K' = 0x14 -'K' = 0x14 -'L' = 0x15 -'L' = 0x15 -'M' = 0x16 -'M' = 0x16 -'N' = 0x17 -'N' = 0x17 -'O' = 0x18 -'O' = 0x18 -'P' = 0x19 -'P' = 0x19 -'Q' = 0x1A -'Q' = 0x1A -'R' = 0x1B -'R' = 0x1B -'S' = 0x1C -'S' = 0x1C -'T' = 0x1D -'T' = 0x1D -'U' = 0x1E -'U' = 0x1E -'V' = 0x1F -'V' = 0x1F -'W' = 0x20 -'W' = 0x20 -'X' = 0x21 -'X' = 0x21 -'Y' = 0x22 -'Y' = 0x22 -'Z' = 0x23 -'Z' = 0x23 -'a' = 0x24 -'b' = 0x25 -'c' = 0x26 -'d' = 0x27 -'e' = 0x28 -'f' = 0x29 -'g' = 0x2A -'h' = 0x2B -'i' = 0x2C -'j' = 0x2D -'k' = 0x2E -'l' = 0x2F -'m' = 0x30 -'n' = 0x31 -'o' = 0x32 -'p' = 0x33 -'q' = 0x34 -'r' = 0x35 -'s' = 0x36 -'t' = 0x37 -'u' = 0x38 -'v' = 0x39 -'w' = 0x3A -'x' = 0x3B -'y' = 0x3C -'z' = 0x3D -'\'' = 0x3E -'.' = 0x3F +#if defined(VERSION_CN) && !defined(CHARMAP_DEBUG) +#define CN_ZERO 0x00, +#define CN_FF 0xFF, +#define CN_DIFF(a, b) REMOVE_PARENS b +#define REMOVE_PARENS(a, b) a, b +#else +#define CN_ZERO +#define CN_FF +#define CN_DIFF(a, b) a +#endif -# Mario face US/EU menu string (Note: NOT multi-text, each char has a part of the face) -'☺' = 0x40, 0x41 +'0' = CN_ZERO 0x00 +'0' = CN_ZERO 0x00 +'1' = CN_ZERO 0x01 +'1' = CN_ZERO 0x01 +'2' = CN_ZERO 0x02 +'2' = CN_ZERO 0x02 +'3' = CN_ZERO 0x03 +'3' = CN_ZERO 0x03 +'4' = CN_ZERO 0x04 +'4' = CN_ZERO 0x04 +'5' = CN_ZERO 0x05 +'5' = CN_ZERO 0x05 +'6' = CN_ZERO 0x06 +'6' = CN_ZERO 0x06 +'7' = CN_ZERO 0x07 +'7' = CN_ZERO 0x07 +'8' = CN_ZERO 0x08 +'8' = CN_ZERO 0x08 +'9' = CN_ZERO 0x09 +'9' = CN_ZERO 0x09 +'A' = CN_ZERO 0x0A +'A' = CN_DIFF(0x0A, (0x04, 0x52)) +'B' = CN_ZERO 0x0B +'B' = CN_ZERO 0x0B +'C' = CN_ZERO 0x0C +'C' = CN_ZERO 0x0C +'D' = CN_ZERO 0x0D +'D' = CN_ZERO 0x0D +'E' = CN_ZERO 0x0E +'E' = CN_ZERO 0x0E +'F' = CN_ZERO 0x0F +'F' = CN_ZERO 0x0F +'G' = CN_ZERO 0x10 +'G' = CN_ZERO 0x10 +'H' = CN_ZERO 0x11 +'H' = CN_ZERO 0x11 +'I' = CN_ZERO 0x12 +'I' = CN_ZERO 0x12 +'J' = CN_ZERO 0x13 +'J' = CN_ZERO 0x13 +'K' = CN_ZERO 0x14 +'K' = CN_ZERO 0x14 +'L' = CN_ZERO 0x15 +'L' = CN_ZERO 0x15 +'M' = CN_ZERO 0x16 +'M' = CN_ZERO 0x16 +'N' = CN_ZERO 0x17 +'N' = CN_ZERO 0x17 +'O' = CN_ZERO 0x18 +'O' = CN_ZERO 0x18 +'P' = CN_ZERO 0x19 +'P' = CN_ZERO 0x19 +'Q' = CN_ZERO 0x1A +'Q' = CN_ZERO 0x1A +'R' = CN_ZERO 0x1B +'R' = CN_DIFF(0x1B, (0x04, 0x53)) +'S' = CN_ZERO 0x1C +'S' = CN_DIFF(0x1C, (0x04, 0x50)) +'T' = CN_ZERO 0x1D +'T' = CN_DIFF(0x1D, (0x04, 0x51)) +'U' = CN_ZERO 0x1E +'U' = CN_ZERO 0x1E +'V' = CN_ZERO 0x1F +'V' = CN_ZERO 0x1F +'W' = CN_ZERO 0x20 +'W' = CN_ZERO 0x20 +'X' = CN_ZERO 0x21 +'X' = CN_ZERO 0x21 +'Y' = CN_ZERO 0x22 +'Y' = CN_ZERO 0x22 +'Z' = CN_ZERO 0x23 +'Z' = CN_ZERO 0x23 +'a' = CN_ZERO 0x24 +'b' = CN_ZERO 0x25 +'c' = CN_ZERO 0x26 +'d' = CN_ZERO 0x27 +'e' = CN_ZERO 0x28 +'f' = CN_ZERO 0x29 +'g' = CN_ZERO 0x2A +'h' = CN_ZERO 0x2B +'i' = CN_ZERO 0x2C +'j' = CN_ZERO 0x2D +'k' = CN_ZERO 0x2E +'l' = CN_ZERO 0x2F +'m' = CN_ZERO 0x30 +'n' = CN_ZERO 0x31 +'o' = CN_ZERO 0x32 +'p' = CN_ZERO 0x33 +'q' = CN_ZERO 0x34 +'r' = CN_ZERO 0x35 +'s' = CN_ZERO 0x36 +'t' = CN_ZERO 0x37 +'u' = CN_ZERO 0x38 +'v' = CN_ZERO 0x39 +'w' = CN_ZERO 0x3A +'x' = CN_ZERO 0x3B +'y' = CN_ZERO 0x3C +'z' = CN_ZERO 0x3D +'\'' = CN_ZERO 0x3E +'.' = CN_ZERO 0x3F -'あ' = 0x40 -'い' = 0x41 -'う' = 0x42 -'え' = 0x43 -'お' = 0x44 -'か' = 0x45 -'き' = 0x46 -'く' = 0x47 -'け' = 0x48 -'こ' = 0x49 -'さ' = 0x4A -'し' = 0x4B -'す' = 0x4C -'せ' = 0x4D -'そ' = 0x4E -'た' = 0x4F -'ち' = 0x50 -'つ' = 0x51 -'て' = 0x52 -'と' = 0x53 -'な' = 0x54 -'に' = 0x55 -'ぬ' = 0x56 -'ね' = 0x57 -'の' = 0x58 -'は' = 0x59 -'ひ' = 0x5A -'ふ' = 0x5B -'へ' = 0x5C -'ほ' = 0x5D -'ま' = 0x5E -'み' = 0x5F -'む' = 0x60 -'め' = 0x61 -'も' = 0x62 -'や' = 0x63 -'ゆ' = 0x64 -'よ' = 0x65 -'ら' = 0x66 -'り' = 0x67 -'る' = 0x68 -'れ' = 0x69 -'ろ' = 0x6A -'わ' = 0x6B -'を' = 0x6C -'ん' = 0x6D -'。' = 0x6E -',' = 0x6F -'、' = 0x6F -'ア' = 0x70 -'イ' = 0x71 -'ウ' = 0x72 -'エ' = 0x73 -'オ' = 0x74 -'カ' = 0x75 -'キ' = 0x76 -'ク' = 0x77 -'ケ' = 0x78 -'コ' = 0x79 -'サ' = 0x7A -'シ' = 0x7B -'ス' = 0x7C -'セ' = 0x7D -'ソ' = 0x7E -'タ' = 0x7F -'チ' = 0x80 -'ツ' = 0x81 -'テ' = 0x82 -'ト' = 0x83 -'ナ' = 0x84 -'ニ' = 0x85 -'ヌ' = 0x86 -'ネ' = 0x87 -'ノ' = 0x88 -'ハ' = 0x89 -'ヒ' = 0x8A -'フ' = 0x8B -'ヘ' = 0x8C -'ホ' = 0x8D -'マ' = 0x8E -'ミ' = 0x8F -'ム' = 0x90 -'メ' = 0x91 -'モ' = 0x92 -'ヤ' = 0x93 -'ユ' = 0x94 -'ヨ' = 0x95 -'ラ' = 0x96 -'リ' = 0x97 -'ル' = 0x98 -'レ' = 0x99 -'ロ' = 0x9A -'ワ' = 0x9B -# 0x9C is unused, only defined in jp menu char lut -'ヲ' = 0x9C -'ン' = 0x9D -' ' = 0x9E -' ' = 0x9E -'-' = 0x9F -'ー' = 0x9F -'ぇ' = 0xA0 -'っ' = 0xA1 -'ゃ' = 0xA2 -'ゅ' = 0xA3 -'ょ' = 0xA4 -'ぁ' = 0xA5 -'ぃ' = 0xA6 -'ぅ' = 0xA7 -'ぉ' = 0xA8 -'ェ' = 0xD0 -'ッ' = 0xD1 -'ャ' = 0xD2 -'ュ' = 0xD3 -'ョ' = 0xD4 -'ァ' = 0xD5 -'ィ' = 0xD6 -'ゥ' = 0xD7 -'ォ' = 0xD8 -'[%]' = 0xE0 -'(' = 0xE1 -'(' = 0xE1 -')(' = 0xE2 -')(' = 0xE2 -')' = 0xE3 -')' = 0xE3 -'+' = 0xE4 -'↔' = 0xE4 -'&' = 0xE5 -':' = 0xE6 -'゛' = 0xF0 -'゜' = 0xF1 -'!' = 0xF2 -'!' = 0xF2 -'%' = 0xF3 -'%' = 0xF3 -'?' = 0xF4 -'?' = 0xF4 -'『' = 0xF5 -'』' = 0xF6 -'~' = 0xF7 -'~' = 0xF7 -'…' = 0xF8 -'$' = 0xF9 -'★' = 0xFA -'×' = 0xFB -'・' = 0xFC -'☆' = 0xFD -'\n' = 0xFE +// Mario face US/EU menu string (Note: NOT multi-text, each char has a part of the face) +'☺' = CN_ZERO 0x40, CN_ZERO 0x41 -# hiragana or katakana with dakuten +'あ' = CN_ZERO 0x40 +'い' = CN_ZERO 0x41 +'う' = CN_ZERO 0x42 +'え' = CN_ZERO 0x43 +'お' = CN_ZERO 0x44 +'か' = CN_ZERO 0x45 +'き' = CN_ZERO 0x46 +'く' = CN_ZERO 0x47 +'け' = CN_ZERO 0x48 +'こ' = CN_ZERO 0x49 +'さ' = CN_ZERO 0x4A +'し' = CN_ZERO 0x4B +'す' = CN_ZERO 0x4C +'せ' = CN_ZERO 0x4D +'そ' = CN_ZERO 0x4E +'た' = CN_ZERO 0x4F +'ち' = CN_ZERO 0x50 +'つ' = CN_ZERO 0x51 +'て' = CN_ZERO 0x52 +'と' = CN_ZERO 0x53 +'な' = CN_ZERO 0x54 +'に' = CN_ZERO 0x55 +'ぬ' = CN_ZERO 0x56 +'ね' = CN_ZERO 0x57 +'の' = CN_ZERO 0x58 +'は' = CN_ZERO 0x59 +'ひ' = CN_ZERO 0x5A +'ふ' = CN_ZERO 0x5B +'へ' = CN_ZERO 0x5C +'ほ' = CN_ZERO 0x5D +'ま' = CN_ZERO 0x5E +'み' = CN_ZERO 0x5F +'む' = CN_ZERO 0x60 +'め' = CN_ZERO 0x61 +'も' = CN_ZERO 0x62 +'や' = CN_ZERO 0x63 +'ゆ' = CN_ZERO 0x64 +'よ' = CN_ZERO 0x65 +'ら' = CN_ZERO 0x66 +'り' = CN_ZERO 0x67 +'る' = CN_ZERO 0x68 +'れ' = CN_ZERO 0x69 +'ろ' = CN_ZERO 0x6A +'わ' = CN_ZERO 0x6B +'を' = CN_ZERO 0x6C +'ん' = CN_ZERO 0x6D +'。' = CN_DIFF(0x6E, (0x02, 0x6C)) +',' = CN_ZERO 0x6F +'、' = CN_DIFF(0x6F, (0x03, 0xE6)) +'ア' = CN_ZERO 0x70 +'イ' = CN_ZERO 0x71 +'ウ' = CN_ZERO 0x72 +'エ' = CN_ZERO 0x73 +'オ' = CN_ZERO 0x74 +'カ' = CN_ZERO 0x75 +'キ' = CN_ZERO 0x76 +'ク' = CN_ZERO 0x77 +'ケ' = CN_ZERO 0x78 +'コ' = CN_ZERO 0x79 +'サ' = CN_ZERO 0x7A +'シ' = CN_ZERO 0x7B +'ス' = CN_ZERO 0x7C +'セ' = CN_ZERO 0x7D +'ソ' = CN_ZERO 0x7E +'タ' = CN_ZERO 0x7F +'チ' = CN_ZERO 0x80 +'ツ' = CN_ZERO 0x81 +'テ' = CN_ZERO 0x82 +'ト' = CN_ZERO 0x83 +'ナ' = CN_ZERO 0x84 +'ニ' = CN_ZERO 0x85 +'ヌ' = CN_ZERO 0x86 +'ネ' = CN_ZERO 0x87 +'ノ' = CN_ZERO 0x88 +'ハ' = CN_ZERO 0x89 +'ヒ' = CN_ZERO 0x8A +'フ' = CN_ZERO 0x8B +'ヘ' = CN_ZERO 0x8C +'ホ' = CN_ZERO 0x8D +'マ' = CN_ZERO 0x8E +'ミ' = CN_ZERO 0x8F +'ム' = CN_ZERO 0x90 +'メ' = CN_ZERO 0x91 +'モ' = CN_ZERO 0x92 +'ヤ' = CN_ZERO 0x93 +'ユ' = CN_ZERO 0x94 +'ヨ' = CN_ZERO 0x95 +'ラ' = CN_ZERO 0x96 +'リ' = CN_ZERO 0x97 +'ル' = CN_ZERO 0x98 +'レ' = CN_ZERO 0x99 +'ロ' = CN_ZERO 0x9A +'ワ' = CN_ZERO 0x9B +// 0x9C is unused, only defined in jp menu char lut +'ヲ' = CN_ZERO 0x9C +'ン' = CN_ZERO 0x9D +' ' = CN_FF 0x9E +' ' = CN_FF 0x9E +'-' = CN_ZERO 0x9F +'ー' = CN_ZERO 0x9F +'ぇ' = CN_ZERO 0xA0 +'っ' = CN_ZERO 0xA1 +'ゃ' = CN_ZERO 0xA2 +'ゅ' = CN_ZERO 0xA3 +'ょ' = CN_ZERO 0xA4 +'ぁ' = CN_ZERO 0xA5 +'ぃ' = CN_ZERO 0xA6 +'ぅ' = CN_ZERO 0xA7 +'ぉ' = CN_ZERO 0xA8 +'ェ' = CN_ZERO 0xD0 +'ッ' = CN_ZERO 0xD1 +'ャ' = CN_ZERO 0xD2 +'ュ' = CN_ZERO 0xD3 +'ョ' = CN_ZERO 0xD4 +'ァ' = CN_ZERO 0xD5 +'ィ' = CN_ZERO 0xD6 +'ゥ' = CN_ZERO 0xD7 +'ォ' = CN_ZERO 0xD8 +'[%]' = CN_FF 0xE0 +'(' = CN_ZERO 0xE1 +'(' = CN_DIFF(0xE1, (0x02, 0x78)) +')(' = CN_ZERO 0xE2 +')(' = CN_ZERO 0xE2 +')' = CN_ZERO 0xE3 +')' = CN_DIFF(0xE3, (0x02, 0x7E)) +'+' = CN_ZERO 0xE4 +'↔' = CN_ZERO 0xE4 +'&' = CN_ZERO 0xE5 +':' = CN_ZERO 0xE6 +'゛' = CN_ZERO 0xF0 +'゜' = CN_ZERO 0xF1 +'!' = CN_ZERO 0xF2 +'!' = CN_DIFF(0xF2, (0x02, 0x65)) +'%' = CN_ZERO 0xF3 +'%' = CN_ZERO 0xF3 +'?' = CN_ZERO 0xF4 +'?' = CN_DIFF(0xF4, (0x01, 0x3A)) +'『' = CN_ZERO 0xF5 +'』' = CN_ZERO 0xF6 +'~' = CN_ZERO 0xF7 +'~' = CN_ZERO 0xF7 +'…' = CN_DIFF(0xF8, (0x02, 0xE6)) +'$' = CN_ZERO 0xF9 +'★' = CN_ZERO 0xFA +'×' = CN_ZERO 0xFB +'・' = CN_ZERO 0xFC +'☆' = CN_ZERO 0xFD +'\n' = CN_FF 0xFE +'\0' = CN_FF 0xFF + +// hiragana or katakana with dakuten 'が' = 0xF0, 0x45 'ぎ' = 0xF0, 0x46 'ぐ' = 0xF0, 0x47 @@ -293,7 +305,7 @@ 'ベ' = 0xF0, 0x8C 'ボ' = 0xF0, 0x8D -# hiragana or katakana with handakuten +// hiragana or katakana with handakuten 'ぱ' = 0xF1, 0x59 'ぴ' = 0xF1, 0x5A 'ぷ' = 0xF1, 0x5B @@ -305,52 +317,1115 @@ 'ペ' = 0xF1, 0x8C 'ポ' = 0xF1, 0x8D -# overwritten US symbols -# these symbols overwrite -# a previous symbol. -'^' = 0x50 -'|' = 0x51 -'<' = 0x52 -'>' = 0x53 -'[A]' = 0x54 -'[B]' = 0x55 -'[C]' = 0x56 -'[Z]' = 0x57 -'[R]' = 0x58 -'/' = 0xD0 +// overwritten symbols +// these symbols overwrite +// a previous symbol. +'▲' = CN_ZERO 0x50 +'▼' = CN_ZERO 0x51 +'◀' = CN_ZERO 0x52 +'▶' = CN_ZERO 0x53 +'[A]' = CN_ZERO 0x54 +'[B]' = CN_ZERO 0x55 +'[C]' = CN_ZERO 0x56 +'[Z]' = CN_ZERO 0x57 +'[R]' = CN_ZERO 0x58 +'/' = CN_ZERO 0xD0 -# multi-text US symbols -'the' = 0xD1 -'you' = 0xD2 +// multi-text US symbols +'the' = CN_ZERO 0xD1 +'you' = CN_ZERO 0xD2 -# EU ROM symbols -'à' = 0x60 -'â' = 0x61 -'ä' = 0x62 -'À' = 0x64 -'Â' = 0x65 -'Ä' = 0x66 -'è' = 0x70 -'ê' = 0x71 -'ë' = 0x72 -'é' = 0x73 -'È' = 0x74 -'Ê' = 0x75 -'Ë' = 0x76 -'É' = 0x77 -'ù' = 0x80 -'û' = 0x81 -'ü' = 0x82 -'Ù' = 0x84 -'Û' = 0x85 -'Ü' = 0x86 -'ô' = 0x91 -'ö' = 0x92 -'Ô' = 0x95 -'Ö' = 0x96 -'î' = 0xA1 -'ï' = 0xA2 -'ß' = 0xEC -'Ç' = 0xED -'ç' = 0xEE -'„' = 0xF0 +// EU ROM symbols +'à' = CN_ZERO 0x60 +'â' = CN_ZERO 0x61 +'ä' = CN_ZERO 0x62 +'À' = CN_ZERO 0x64 +'Â' = CN_ZERO 0x65 +'Ä' = CN_ZERO 0x66 +'è' = CN_ZERO 0x70 +'ê' = CN_ZERO 0x71 +'ë' = CN_ZERO 0x72 +'é' = CN_ZERO 0x73 +'È' = CN_ZERO 0x74 +'Ê' = CN_ZERO 0x75 +'Ë' = CN_ZERO 0x76 +'É' = CN_ZERO 0x77 +'ù' = CN_ZERO 0x80 +'û' = CN_ZERO 0x81 +'ü' = CN_ZERO 0x82 +'Ù' = CN_ZERO 0x84 +'Û' = CN_ZERO 0x85 +'Ü' = CN_ZERO 0x86 +'ô' = CN_ZERO 0x91 +'ö' = CN_ZERO 0x92 +'Ô' = CN_ZERO 0x95 +'Ö' = CN_ZERO 0x96 +'î' = CN_ZERO 0xA1 +'ï' = CN_ZERO 0xA2 +'ß' = CN_ZERO 0xEC +'Ç' = CN_ZERO 0xED +'ç' = CN_ZERO 0xEE +'„' = CN_ZERO 0xF0 + +// CN chars +'我' = 0x01, 0x00 +'的' = 0x01, 0x01 +'积' = 0x01, 0x02 +'分' = 0x01, 0x03 +'关' = 0x01, 0x04 +'卡' = 0x01, 0x05 +'退' = 0x01, 0x06 +'出' = 0x01, 0x07 +'继' = 0x01, 0x08 +'续' = 0x01, 0x09 +'使' = 0x01, 0x0A +'用' = 0x01, 0x0B +'键' = 0x01, 0x0C +'设' = 0x01, 0x0D +'定' = 0x01, 0x0E +'视' = 0x01, 0x0F +'角' = 0x01, 0x10 +'特' = 0x01, 0x11 +'写' = 0x01, 0x12 +'镜' = 0x01, 0x13 +'头' = 0x01, 0x14 +'固' = 0x01, 0x15 +'返' = 0x01, 0x16 +'回' = 0x01, 0x17 +'查' = 0x01, 0x18 +'看' = 0x01, 0x19 +'复' = 0x01, 0x1A +'制' = 0x01, 0x1B +'文' = 0x01, 0x1C +'件' = 0x01, 0x1D +'删' = 0x01, 0x1E +'除' = 0x01, 0x1F +'立' = 0x01, 0x20 +'体' = 0x01, 0x21 +'声' = 0x01, 0x22 +'单' = 0x01, 0x23 +'道' = 0x01, 0x24 +'耳' = 0x01, 0x25 +'机' = 0x01, 0x26 +'选' = 0x01, 0x27 +'择' = 0x01, 0x28 +'没' = 0x01, 0x29 +'有' = 0x01, 0x2A +'保' = 0x01, 0x2B +'存' = 0x01, 0x2C +'数' = 0x01, 0x2D +'据' = 0x01, 0x2E +'到' = 0x01, 0x2F +'何' = 0x01, 0x30 +'处' = 0x01, 0x31 +'完' = 0x01, 0x32 +'毕' = 0x01, 0x33 +'空' = 0x01, 0x34 +'储' = 0x01, 0x35 +'是' = 0x01, 0x36 +'否' = 0x01, 0x37 +'确' = 0x01, 0x38 +'吗' = 0x01, 0x39 +'已' = 0x01, 0x3B +'音' = 0x01, 0x3C +'马' = 0x01, 0x3D +'力' = 0x01, 0x3E +'欧' = 0x01, 0x3F +'最' = 0x01, 0x40 +'高' = 0x01, 0x41 +'并' = 0x01, 0x42 +'不' = 0x01, 0x43 +'必' = 0x01, 0x44 +'接' = 0x01, 0x45 +'住' = 0x01, 0x46 +'清' = 0x01, 0x47 +'炸' = 0x01, 0x48 +'弹' = 0x01, 0x49 +'王' = 0x01, 0x4A +'国' = 0x01, 0x4B +'嘭' = 0x01, 0x4C +'要' = 0x01, 0x4D +'塞' = 0x01, 0x4E +'海' = 0x01, 0x4F +'盗' = 0x01, 0x50 +'湾' = 0x01, 0x51 +'酷' = 0x01, 0x52 +'冰' = 0x01, 0x53 +'雪' = 0x01, 0x54 +'山' = 0x01, 0x55 +'大' = 0x01, 0x56 +'嘘' = 0x01, 0x57 +'鬼' = 0x01, 0x58 +'城' = 0x01, 0x59 +'堡' = 0x01, 0x5A +'迷' = 0x01, 0x5B +'失' = 0x01, 0x5C +'洞' = 0x01, 0x5D +'窟' = 0x01, 0x5E +'岩' = 0x01, 0x5F +'浆' = 0x01, 0x60 +'地' = 0x01, 0x61 +'狱' = 0x01, 0x62 +'热' = 0x01, 0x63 +'沙' = 0x01, 0x64 +'漠' = 0x01, 0x65 +'恐' = 0x01, 0x66 +'怖' = 0x01, 0x67 +'船' = 0x01, 0x68 +'坞' = 0x01, 0x69 +'人' = 0x01, 0x6A +'水' = 0x01, 0x6B +'下' = 0x01, 0x6C +'遗' = 0x01, 0x6D +'迹' = 0x01, 0x6E +'脉' = 0x01, 0x6F +'小' = 0x01, 0x70 +'摇' = 0x01, 0x71 +'摆' = 0x01, 0x72 +'古' = 0x01, 0x73 +'钟' = 0x01, 0x74 +'彩' = 0x01, 0x75 +'虹' = 0x01, 0x76 +'之' = 0x01, 0x77 +'旅' = 0x01, 0x78 +'黑' = 0x01, 0x79 +'暗' = 0x01, 0x7A +'世' = 0x01, 0x7B +'界' = 0x01, 0x7C +'霸' = 0x01, 0x7D +'火' = 0x01, 0x7E +'中' = 0x01, 0x7F +'天' = 0x01, 0x80 +'公' = 0x01, 0x81 +'主' = 0x01, 0x82 +'秘' = 0x01, 0x83 +'密' = 0x01, 0x84 +'滑' = 0x01, 0x85 +'梯' = 0x01, 0x86 +'金' = 0x01, 0x87 +'属' = 0x01, 0x88 +'帽' = 0x01, 0x89 +'瀑' = 0x01, 0x8A +'布' = 0x01, 0x8B +'石' = 0x01, 0x8C +'飞' = 0x01, 0x8D +'行' = 0x01, 0x8E +'塔' = 0x01, 0x8F +'护' = 0x01, 0x90 +'河' = 0x01, 0x91 +'里' = 0x01, 0x92 +'隐' = 0x01, 0x93 +'身' = 0x01, 0x94 +'越' = 0x01, 0x95 +'族' = 0x01, 0x96 +'馆' = 0x01, 0x97 +'藏' = 0x01, 0x98 +'星' = 0x01, 0x99 +'顶' = 0x01, 0x9A +'上' = 0x01, 0x9B +'喏' = 0x01, 0x9C +'库' = 0x01, 0x9D +'诺' = 0x01, 0x9E +'田' = 0x01, 0x9F +'径' = 0x01, 0xA0 +'锦' = 0x01, 0xA1 +'标' = 0x01, 0xA2 +'赛' = 0x01, 0xA3 +'岛' = 0x01, 0xA4 +'屿' = 0x01, 0xA5 +'枚' = 0x01, 0xA6 +'红' = 0x01, 0xA7 +'色' = 0x01, 0xA8 +'硬' = 0x01, 0xA9 +'币' = 0x01, 0xAA +'长' = 0x01, 0xAB +'翅' = 0x01, 0xAC +'膀' = 0x01, 0xAD +'汪' = 0x01, 0xAE +'守' = 0x01, 0xAF +'铁' = 0x01, 0xB0 +'门' = 0x01, 0xB1 +'疯' = 0x01, 0xB2 +'狂' = 0x01, 0xB3 +'巅' = 0x01, 0xB4 +'射' = 0x01, 0xB5 +'向' = 0x01, 0xB6 +'蓝' = 0x01, 0xB7 +'浮' = 0x01, 0xB8 +'降' = 0x01, 0xB9 +'篮' = 0x01, 0xBA +'破' = 0x01, 0xBB +'壁' = 0x01, 0xBC +'摘' = 0x01, 0xBD +'沉' = 0x01, 0xBE +'宝' = 0x01, 0xBF +'来' = 0x01, 0xC0 +'玩' = 0x01, 0xC1 +'吧' = 0x01, 0xC2 +'鳗' = 0x01, 0xC3 +'底' = 0x01, 0xC4 +'财' = 0x01, 0xC5 +'发' = 0x01, 0xC6 +'柱' = 0x01, 0xC7 +'平' = 0x01, 0xC8 +'台' = 0x01, 0xC9 +'穿' = 0x01, 0xCA +'急' = 0x01, 0xCB +'流' = 0x01, 0xCC +'企' = 0x01, 0xCD +'鹅' = 0x01, 0xCE +'该' = 0x01, 0xCF +'家' = 0x01, 0xD0 +'了' = 0x01, 0xD1 +'比' = 0x01, 0xD2 +'帮' = 0x01, 0xD3 +'助' = 0x01, 0xD4 +'寻' = 0x01, 0xD5 +'找' = 0x01, 0xD6 +'脑' = 0x01, 0xD7 +'袋' = 0x01, 0xD8 +'踢' = 0x01, 0xD9 +'墙' = 0x01, 0xDA +'跳' = 0x01, 0xDB +'猎' = 0x01, 0xDC +'记' = 0x01, 0xDD +'旋' = 0x01, 0xDE +'转' = 0x01, 0xDF +'木' = 0x01, 0xE0 +'书' = 0x01, 0xE1 +'房' = 0x01, 0xE2 +'室' = 0x01, 0xE3 +'阳' = 0x01, 0xE4 +'眼' = 0x01, 0xE5 +'睛' = 0x01, 0xE6 +'穴' = 0x01, 0xE7 +'怪' = 0x01, 0xE8 +'移' = 0x01, 0xE9 +'动' = 0x01, 0xEA +'通' = 0x01, 0xEB +'过' = 0x01, 0xEC +'毒' = 0x01, 0xED +'气' = 0x01, 0xEE +'宫' = 0x01, 0xEF +'紧' = 0x01, 0xF0 +'口' = 0x01, 0xF1 +'心' = 0x01, 0xF2 +'落' = 0x01, 0xF3 +'巨' = 0x01, 0xF4 +'融' = 0x01, 0xF5 +'化' = 0x01, 0xF6 +'斗' = 0x01, 0xF7 +'打' = 0x01, 0xF8 +'败' = 0x01, 0xF9 +'块' = 0x01, 0xFA +'拼' = 0x01, 0xFB +'图' = 0x01, 0xFC +'灼' = 0x01, 0xFD +'滚' = 0x01, 0xFE +'陷' = 0x01, 0xFF +'阱' = 0x02, 0x00 +'进' = 0x02, 0x01 +'电' = 0x02, 0x02 +'还' = 0x02, 0x03 +'给' = 0x02, 0x04 +'秃' = 0x02, 0x05 +'鹫' = 0x02, 0x06 +'字' = 0x02, 0x07 +'闪' = 0x02, 0x08 +'光' = 0x02, 0x09 +'法' = 0x02, 0x0A +'老' = 0x02, 0x0B +'珍' = 0x02, 0x0C +'于' = 0x02, 0x0D +'四' = 0x02, 0x0E +'颠' = 0x02, 0x0F +'为' = 0x02, 0x10 +'自' = 0x02, 0x11 +'由' = 0x02, 0x12 +'翔' = 0x02, 0x13 +'谜' = 0x02, 0x14 +'潜' = 0x02, 0x15 +'艇' = 0x02, 0x16 +'湍' = 0x02, 0x17 +'箱' = 0x02, 0x18 +'才' = 0x02, 0x19 +'杂' = 0x02, 0x1A +'技' = 0x02, 0x1B +'演' = 0x02, 0x1C +'员' = 0x02, 0x1D +'勇' = 0x02, 0x1E +'鳐' = 0x02, 0x1F +'鱼' = 0x02, 0x20 +'奖' = 0x02, 0x21 +'励' = 0x02, 0x22 +'子' = 0x02, 0x23 +'收' = 0x02, 0x24 +'寒' = 0x02, 0x25 +'冷' = 0x02, 0x26 +'雕' = 0x02, 0x27 +'冻' = 0x02, 0x28 +'池' = 0x02, 0x29 +'塘' = 0x02, 0x2A +'圆' = 0x02, 0x2B +'舞' = 0x02, 0x2C +'曲' = 0x02, 0x2D +'板' = 0x02, 0x2E +'与' = 0x02, 0x2F +'爱' = 0x02, 0x30 +'斯' = 0x02, 0x31 +'基' = 0x02, 0x32 +'摩' = 0x02, 0x33 +'屋' = 0x02, 0x34 +'箭' = 0x02, 0x35 +'和' = 0x02, 0x36 +'快' = 0x02, 0x37 +'速' = 0x02, 0x38 +'—' = 0x02, 0x39 +'抓' = 0x02, 0x3A +'时' = 0x02, 0x3B +'间' = 0x02, 0x3C +'镇' = 0x02, 0x3D +'攀' = 0x02, 0x3E +'登' = 0x02, 0x3F +'神' = 0x02, 0x40 +'猴' = 0x02, 0x41 +'呦' = 0x02, 0x42 +'奇' = 0x02, 0x43 +'笼' = 0x02, 0x44 +'蘑' = 0x02, 0x45 +'菇' = 0x02, 0x46 +'惊' = 0x02, 0x47 +'险' = 0x02, 0x48 +'帘' = 0x02, 0x49 +'孤' = 0x02, 0x4A +'独' = 0x02, 0x4B +'食' = 0x02, 0x4C +'花' = 0x02, 0x4D +'又' = 0x02, 0x4E +'五' = 0x02, 0x4F +'个' = 0x02, 0x50 +'蠕' = 0x02, 0x51 +'指' = 0x02, 0x52 +'针' = 0x02, 0x53 +'楼' = 0x02, 0x54 +'恰' = 0x02, 0x55 +'好' = 0x02, 0x56 +'踏' = 0x02, 0x57 +'在' = 0x02, 0x58 +'正' = 0x02, 0x59 +'点' = 0x02, 0x5A +'梭' = 0x02, 0x5B +'云' = 0x02, 0x5C +'集' = 0x02, 0x5D +'风' = 0x02, 0x5E +'荡' = 0x02, 0x5F +'狡' = 0x02, 0x60 +'猾' = 0x02, 0x61 +'三' = 0x02, 0x62 +'某' = 0x02, 0x63 +'哇' = 0x02, 0x64 +'你' = 0x02, 0x66 +'闯' = 0x02, 0x67 +'入' = 0x02, 0x68 +'战' = 0x02, 0x69 +'场' = 0x02, 0x6A +'啦' = 0x02, 0x6B +'可' = 0x02, 0x6D +'以' = 0x02, 0x6E +'这' = 0x02, 0x6F +'画' = 0x02, 0x70 +'偷' = 0x02, 0x71 +'走' = 0x02, 0x72 +'量' = 0x02, 0x73 +'先' = 0x02, 0x74 +'去' = 0x02, 0x75 +'问' = 0x02, 0x76 +'兵' = 0x02, 0x77 +'按' = 0x02, 0x79 +'开' = 0x02, 0x7A +'始' = 0x02, 0x7B +'对' = 0x02, 0x7C +'话' = 0x02, 0x7D +',' = 0x02, 0x7F +'从' = 0x02, 0x80 +'他' = 0x02, 0x81 +'伙' = 0x02, 0x82 +'伴' = 0x02, 0x83 +'那' = 0x02, 0x84 +'得' = 0x02, 0x85 +'如' = 0x02, 0x86 +'果' = 0x02, 0x87 +'需' = 0x02, 0x88 +'察' = 0x02, 0x89 +'路' = 0x02, 0x8A +'面' = 0x02, 0x8B +'它' = 0x02, 0x8C +'或' = 0x02, 0x8D +'翻' = 0x02, 0x8E +'页' = 0x02, 0x8F +'站' = 0x02, 0x90 +'其' = 0x02, 0x91 +'前' = 0x02, 0x92 +'们' = 0x02, 0x93 +'当' = 0x02, 0x94 +'瞎' = 0x02, 0x95 +'逛' = 0x02, 0x96 +'随' = 0x02, 0x97 +'能' = 0x02, 0x98 +'被' = 0x02, 0x99 +'珠' = 0x02, 0x9A +'伤' = 0x02, 0x9B +'些' = 0x02, 0x9C +'敌' = 0x02, 0x9D +'非' = 0x02, 0x9E +'常' = 0x02, 0x9F +'总' = 0x02, 0xA0 +'想' = 0x02, 0xA1 +'方' = 0x02, 0xA2 +'攻' = 0x02, 0xA3 +'击' = 0x02, 0xA4 +'片' = 0x02, 0xA5 +'草' = 0x02, 0xA6 +'原' = 0x02, 0xA7 +'就' = 0x02, 0xA8 +'变' = 0x02, 0xA9 +'纷' = 0x02, 0xAA +'座' = 0x02, 0xAB +'桥' = 0x02, 0xAC +'沿' = 0x02, 0xAD +'着' = 0x02, 0xAE +'左' = 0x02, 0xAF +'夺' = 0x02, 0xB0 +'一' = 0x02, 0xB1 +'啊' = 0x02, 0xB2 +'嘿' = 0x02, 0xB3 +'听' = 0x02, 0xB4 +'很' = 0x02, 0xB5 +'危' = 0x02, 0xB6 +'噢' = 0x02, 0xB7 +'忠' = 0x02, 0xB8 +'告' = 0x02, 0xB9 +'两' = 0x02, 0xBA +'后' = 0x02, 0xBB +'坠' = 0x02, 0xBC +'会' = 0x02, 0xBD +'强' = 0x02, 0xBE +'千' = 0x02, 0xBF +'万' = 0x02, 0xC0 +'让' = 0x02, 0xC1 +'边' = 0x02, 0xC2 +'都' = 0x02, 0xC3 +'忙' = 0x02, 0xC4 +'谢' = 0x02, 0xC5 +'现' = 0x02, 0xC6 +'只' = 0x02, 0xC7 +'哑' = 0x02, 0xC8 +'哈' = 0x02, 0xC9 +'但' = 0x02, 0xCA +'真' = 0x02, 0xCB +'刚' = 0x02, 0xCC +'余' = 0x02, 0xCD +'拿' = 0x02, 0xCE +'更' = 0x02, 0xCF +'多' = 0x02, 0xD0 +'往' = 0x02, 0xD1 +'新' = 0x02, 0xD2 +'等' = 0x02, 0xD3 +'别' = 0x02, 0xD4 +'忘' = 0x02, 0xD5 +'准' = 0x02, 0xD6 +'备' = 0x02, 0xD7 +'炮' = 0x02, 0xD8 +'所' = 0x02, 0xD9 +'介' = 0x02, 0xDA +'意' = 0x02, 0xDB +'顺' = 0x02, 0xDC +'厉' = 0x02, 0xDD +'害' = 0x02, 0xDE +'而' = 0x02, 0xDF +'且' = 0x02, 0xE0 +'迅' = 0x02, 0xE1 +'呢' = 0x02, 0xE2 +'追' = 0x02, 0xE3 +'名' = 0x02, 0xE4 +'鼎' = 0x02, 0xE5 +'赢' = 0x02, 0xE7 +'试' = 0x02, 0xE8 +'赌' = 0x02, 0xE9 +'次' = 0x02, 0xEA +'跑' = 0x02, 0xEB +'终' = 0x02, 0xEC +'怎' = 0x02, 0xED +'么' = 0x02, 0xEE +'样' = 0x02, 0xEF +'说' = 0x02, 0xF0 +'“' = 0x02, 0xF1 +'”' = 0x02, 0xF2 +'预' = 0x02, 0xF3 +'傻' = 0x02, 0xF4 +'瓜' = 0x02, 0xF5 +'全' = 0x02, 0xF6 +'程' = 0x02, 0xF7 +'候' = 0x02, 0xF8 +'再' = 0x02, 0xF9 +'呼' = 0x02, 0xFA +'愿' = 0x02, 0xFB +'服' = 0x02, 0xFC +'输' = 0x02, 0xFD +'满' = 0x02, 0xFE +'嘴' = 0x02, 0xFF +'牙' = 0x03, 0x00 +'带' = 0x03, 0x01 +'锁' = 0x03, 0x02 +'链' = 0x03, 0x03 +'靠' = 0x03, 0x04 +'近' = 0x03, 0x05 +'仔' = 0x03, 0x06 +'细' = 0x03, 0x07 +'吓' = 0x03, 0x08 +'坏' = 0x03, 0x09 +'桩' = 0x03, 0x0A +'八' = 0x03, 0x0B +'颗' = 0x03, 0x0C +'久' = 0x03, 0x0D +'见' = 0x03, 0x0E +'加' = 0x03, 0x0F +'甘' = 0x03, 0x10 +'峡' = 0x03, 0x11 +'谷' = 0x03, 0x12 +'踩' = 0x03, 0x13 +'戴' = 0x03, 0x14 +'砖' = 0x03, 0x15 +'游' = 0x03, 0x16 +'戏' = 0x03, 0x17 +'无' = 0x03, 0x18 +'绿' = 0x03, 0x19 +'透' = 0x03, 0x1A +'明' = 0x03, 0x1B +'将' = 0x03, 0x1C +'经' = 0x03, 0x1D +'错' = 0x03, 0x1E +'拳' = 0x03, 0x1F +'跃' = 0x03, 0x20 +'脚' = 0x03, 0x21 +'把' = 0x03, 0x22 +'什' = 0x03, 0x23 +'东' = 0x03, 0x24 +'西' = 0x03, 0x25 +'举' = 0x03, 0x26 +'起' = 0x03, 0x27 +'也' = 0x03, 0x28 +'扔' = 0x03, 0x29 +'龟' = 0x03, 0x2A +'壳' = 0x03, 0x2B +'乘' = 0x03, 0x2C +'任' = 0x03, 0x2D +'压' = 0x03, 0x2E +'碎' = 0x03, 0x2F +'统' = 0x03, 0x30 +'治' = 0x03, 0x31 +'者' = 0x03, 0x32 +'敢' = 0x03, 0x33 +'爬' = 0x03, 0x34 +'凭' = 0x03, 0x35 +'虽' = 0x03, 0x36 +'然' = 0x03, 0x37 +'侥' = 0x03, 0x38 +'幸' = 0x03, 0x39 +'躲' = 0x03, 0x3A +'卫' = 0x03, 0x3B +'永' = 0x03, 0x3C +'远' = 0x03, 0x3D +'逃' = 0x03, 0x3E +'手' = 0x03, 0x3F +'掌' = 0x03, 0x40 +'决' = 0x03, 0x41 +'须' = 0x03, 0x42 +'证' = 0x03, 0x43 +'己' = 0x03, 0x44 +'抱' = 0x03, 0x45 +'摔' = 0x03, 0x46 +'皇' = 0x03, 0x47 +'办' = 0x03, 0x48 +'困' = 0x03, 0x49 +'阿' = 0x03, 0x4A +'睡' = 0x03, 0x4B +'希' = 0x03, 0x4C +'望' = 0x03, 0x4D +'扰' = 0x03, 0x4E +'请' = 0x03, 0x4F +'轻' = 0x03, 0x50 +'廊' = 0x03, 0x51 +'放' = 0x03, 0x52 +'步' = 0x03, 0x53 +'亲' = 0x03, 0x54 +':' = 0x03, 0x55 +'烤' = 0x03, 0x56 +'蛋' = 0x03, 0x57 +'糕' = 0x03, 0x58 +'桃' = 0x03, 0x59 +'欢' = 0x03, 0x5A +'迎' = 0x03, 0x5B +'钥' = 0x03, 0x5C +'匙' = 0x03, 0x5D +'扇' = 0x03, 0x5E +'许' = 0x03, 0x5F +'幅' = 0x03, 0x60 +'缺' = 0x03, 0x61 +'少' = 0x03, 0x62 +'尽' = 0x03, 0x63 +'嗨' = 0x03, 0x64 +'朱' = 0x03, 0x65 +'盖' = 0x03, 0x66 +'兄' = 0x03, 0x67 +'弟' = 0x03, 0x68 +'插' = 0x03, 0x69 +'播' = 0x03, 0x6A +'报' = 0x03, 0x6B +'展' = 0x03, 0x6C +'学' = 0x03, 0x6D +'悄' = 0x03, 0x6E +'巧' = 0x03, 0x6F +'缓' = 0x03, 0x70 +'慢' = 0x03, 0x71 +'重' = 0x03, 0x72 +'摄' = 0x03, 0x73 +'像' = 0x03, 0x74 +'同' = 0x03, 0x75 +'度' = 0x03, 0x76 +'观' = 0x03, 0x77 +'影' = 0x03, 0x78 +'嘟' = 0x03, 0x79 +'警' = 0x03, 0x7A +'蓄' = 0x03, 0x7B +'买' = 0x03, 0x7C +'双' = 0x03, 0x7D +'号' = 0x03, 0x7E +'鞋' = 0x03, 0x7F +'应' = 0x03, 0x80 +'交' = 0x03, 0x81 +'胜' = 0x03, 0x82 +'利' = 0x03, 0x83 +'恭' = 0x03, 0x84 +'喜' = 0x03, 0x85 +'级' = 0x03, 0x86 +'条' = 0x03, 0x87 +'直' = 0x03, 0x88 +'线' = 0x03, 0x89 +'连' = 0x03, 0x8A +'右' = 0x03, 0x8B +'环' = 0x03, 0x8C +'传' = 0x03, 0x8D +'送' = 0x03, 0x8E +'管' = 0x03, 0x8F +'柄' = 0x03, 0x90 +'简' = 0x03, 0x91 +'读' = 0x03, 0x92 +'牌' = 0x03, 0x93 +'杆' = 0x03, 0x94 +'控' = 0x03, 0x95 +'午' = 0x03, 0x96 +'外' = 0x03, 0x97 +'您' = 0x03, 0x98 +'达' = 0x03, 0x99 +'实' = 0x03, 0x9A +'况' = 0x03, 0x9B +'丢' = 0x03, 0x9C +'作' = 0x03, 0x9D +'专' = 0x03, 0x9E +'佳' = 0x03, 0x9F +'拍' = 0x03, 0xA0 +'停' = 0x03, 0xA1 +'周' = 0x03, 0xA2 +'围' = 0x03, 0xA3 +'情' = 0x03, 0xA4 +'切' = 0x03, 0xA5 +'换' = 0x03, 0xA6 +'习' = 0x03, 0xA7 +'操' = 0x03, 0xA8 +'导' = 0x03, 0xA9 +'共' = 0x03, 0xAA +'般' = 0x03, 0xAB +'推' = 0x03, 0xAC +'荐' = 0x03, 0xAD +'改' = 0x03, 0xAE +'跟' = 0x03, 0xAF +'漏' = 0x03, 0xB0 +'哦' = 0x03, 0xB1 +'暂' = 0x03, 0xB2 +'模' = 0x03, 0xB3 +'式' = 0x03, 0xB4 +'运' = 0x03, 0xB5 +'旨' = 0x03, 0xB6 +'此' = 0x03, 0xB7 +'禁' = 0x03, 0xB8 +'止' = 0x03, 0xB9 +'参' = 0x03, 0xBA +'绝' = 0x03, 0xBB +'弃' = 0x03, 0xBC +'芒' = 0x03, 0xBD +'赏' = 0x03, 0xBE +'赐' = 0x03, 0xBF +'物' = 0x03, 0xC0 +'土' = 0x03, 0xC1 +'露' = 0x03, 0xC2 +'位' = 0x03, 0xC3 +'置' = 0x03, 0xC4 +'提' = 0x03, 0xC5 +'示' = 0x03, 0xC6 +'每' = 0x03, 0xC7 +'注' = 0x03, 0xC8 +'川' = 0x03, 0xC9 +'裂' = 0x03, 0xCA +'缝' = 0x03, 0xCB +'结' = 0x03, 0xCC +'祝' = 0x03, 0xCD +'峭' = 0x03, 0xCE +'缘' = 0x03, 0xCF +'悬' = 0x03, 0xD0 +'挂' = 0x03, 0xD1 +';' = 0x03, 0xD2 +'崖' = 0x03, 0xD3 +'拉' = 0x03, 0xD4 +'则' = 0x03, 0xD5 +'鸟' = 0x03, 0xD6 +'谁' = 0x03, 0xD7 +'吵' = 0x03, 0xD8 +'醒' = 0x03, 0xD9 +'白' = 0x03, 0xDA +'觉' = 0x03, 0xDB +'喂' = 0x03, 0xDC +'既' = 0x03, 0xDD +'短' = 0x03, 0xDE +'途' = 0x03, 0xDF +'松' = 0x03, 0xE0 +'牢' = 0x03, 0xE1 +'陆' = 0x03, 0xE2 +'握' = 0x03, 0xE3 +'种' = 0x03, 0xE4 +'首' = 0x03, 0xE5 +'二' = 0x03, 0xE7 +'蹲' = 0x03, 0xE8 +'做' = 0x03, 0xE9 +'碰' = 0x03, 0xEA +'练' = 0x03, 0xEB +'另' = 0x03, 0xEC +'获' = 0x03, 0xED +'熟' = 0x03, 0xEE +'生' = 0x03, 0xEF +'斜' = 0x03, 0xF0 +'屁' = 0x03, 0xF1 +'股' = 0x03, 0xF2 +'担' = 0x03, 0xF3 +'容' = 0x03, 0xF4 +'易' = 0x03, 0xF5 +'树' = 0x03, 0xF6 +'旗' = 0x03, 0xF7 +'拔' = 0x03, 0xF8 +'绕' = 0x03, 0xF9 +'倒' = 0x03, 0xFA +'姿' = 0x03, 0xFB +'势' = 0x03, 0xFC +'漂' = 0x03, 0xFD +'亮' = 0x03, 0xFE +'侧' = 0x03, 0xFF +'弯' = 0x04, 0x00 +'论' = 0x04, 0x01 +'滞' = 0x04, 0x02 +'触' = 0x04, 0x03 +'减' = 0x04, 0x04 +'知' = 0x04, 0x05 +'挺' = 0x04, 0x06 +'冠' = 0x04, 0x07 +'军' = 0x04, 0x08 +'纪' = 0x04, 0x09 +'录' = 0x04, 0x0A +'太' = 0x04, 0x0B +'难' = 0x04, 0x0C +'信' = 0x04, 0x0D +'棒' = 0x04, 0x0E +'孩' = 0x04, 0x0F +'她' = 0x04, 0x10 +'究' = 0x04, 0x11 +'竟' = 0x04, 0x12 +'哪' = 0x04, 0x13 +'感' = 0x04, 0x14 +'受' = 0x04, 0x15 +'激' = 0x04, 0x16 +'根' = 0x04, 0x17 +'本' = 0x04, 0x18 +'父' = 0x04, 0x19 +'母' = 0x04, 0x1A +'肯' = 0x04, 0x1B +'死' = 0x04, 0x1C +'氧' = 0x04, 0x1D +'泡' = 0x04, 0x1E +'吸' = 0x04, 0x1F +'泳' = 0x04, 0x20 +'稳' = 0x04, 0x21 +'节' = 0x04, 0x22 +'奏' = 0x04, 0x23 +'笑' = 0x04, 0x24 +'怕' = 0x04, 0x25 +'烧' = 0x04, 0x26 +'甚' = 0x04, 0x27 +'至' = 0x04, 0x28 +'唯' = 0x04, 0x29 +'惑' = 0x04, 0x2A +'因' = 0x04, 0x2B +'骗' = 0x04, 0x2C +'升' = 0x04, 0x2D +'课' = 0x04, 0x2E +'蛙' = 0x04, 0x2F +'频' = 0x04, 0x30 +'率' = 0x04, 0x31 +'合' = 0x04, 0x32 +'适' = 0x04, 0x33 +'表' = 0x04, 0x34 +'值' = 0x04, 0x35 +'低' = 0x04, 0x36 +'喘' = 0x04, 0x37 +'事' = 0x04, 0x38 +'够' = 0x04, 0x39 +'残' = 0x04, 0x3A +'忍' = 0x04, 0x3B +'喷' = 0x04, 0x3C +'焰' = 0x04, 0x3D +'成' = 0x04, 0x3E +'焦' = 0x04, 0x3F +'炭' = 0x04, 0x40 +'尾' = 0x04, 0x41 +'巴' = 0x04, 0x42 +'瞄' = 0x04, 0x43 +'命' = 0x04, 0x44 +'象' = 0x04, 0x45 +'懦' = 0x04, 0x46 +'夫' = 0x04, 0x47 +'掉' = 0x04, 0x48 +'烫' = 0x04, 0x49 +'乱' = 0x04, 0x4A +'仍' = 0x04, 0x4B +'持' = 0x04, 0x4C +'静' = 0x04, 0x4D +'撞' = 0x04, 0x4E +'反' = 0x04, 0x4F +'较' = 0x04, 0x54 +'显' = 0x04, 0x55 +'烟' = 0x04, 0x56 +'眩' = 0x04, 0x57 +'晕' = 0x04, 0x58 +'鲜' = 0x04, 0x59 +'圈' = 0x04, 0x5A +'避' = 0x04, 0x5B +'免' = 0x04, 0x5C +'吹' = 0x04, 0x5D +'朋' = 0x04, 0x5E +'友' = 0x04, 0x5F +'照' = 0x04, 0x60 +'序' = 0x04, 0x61 +'建' = 0x04, 0x62 +'筑' = 0x04, 0x63 +'背' = 0x04, 0x64 +'干' = 0x04, 0x65 +'解' = 0x04, 0x66 +'救' = 0x04, 0x67 +'封' = 0x04, 0x68 +'监' = 0x04, 0x69 +'恢' = 0x04, 0x6A +'诉' = 0x04, 0x6B +'超' = 0x04, 0x6C +'猜' = 0x04, 0x6D +'令' = 0x04, 0x6E +'相' = 0x04, 0x6F +'黄' = 0x04, 0x70 +'消' = 0x04, 0x71 +'惜' = 0x04, 0x72 +'嘻' = 0x04, 0x73 +'幽' = 0x04, 0x74 +'默' = 0x04, 0x75 +'咿' = 0x04, 0x76 +'答' = 0x04, 0x77 +'案' = 0x04, 0x78 +'市' = 0x04, 0x79 +'深' = 0x04, 0x7A +'访' = 0x04, 0x7B +'队' = 0x04, 0x7C +'早' = 0x04, 0x7D +'瞧' = 0x04, 0x7E +'迟' = 0x04, 0x7F +'晚' = 0x04, 0x80 +'赶' = 0x04, 0x81 +'及' = 0x04, 0x82 +'礼' = 0x04, 0x83 +'约' = 0x04, 0x84 +'墓' = 0x04, 0x85 +'章' = 0x04, 0x86 +'缭' = 0x04, 0x87 +'圣' = 0x04, 0x88 +'诞' = 0x04, 0x89 +'钻' = 0x04, 0x8A +'囱' = 0x04, 0x8B +'工' = 0x04, 0x8C +'充' = 0x04, 0x8D +'啧' = 0x04, 0x8E +'浓' = 0x04, 0x8F +'雾' = 0x04, 0x90 +'湖' = 0x04, 0x91 +'烦' = 0x04, 0x92 +'儿' = 0x04, 0x93 +'吐' = 0x04, 0x94 +'坡' = 0x04, 0x95 +'内' = 0x04, 0x96 +'讲' = 0x04, 0x97 +'窄' = 0x04, 0x98 +'胆' = 0x04, 0x99 +'呵' = 0x04, 0x9A +'哼' = 0x04, 0x9B +'安' = 0x04, 0x9C +'恙' = 0x04, 0x9D +'拦' = 0x04, 0x9E +'欠' = 0x04, 0x9F +'咳' = 0x04, 0xA0 +'苦' = 0x04, 0xA1 +'羞' = 0x04, 0xA2 +'端' = 0x04, 0xA3 +'灯' = 0x04, 0xA4 +'烁' = 0x04, 0xA5 +'敏' = 0x04, 0xA6 +'捷' = 0x04, 0xA7 +'便' = 0x04, 0xA8 +'活' = 0x04, 0xA9 +'离' = 0x04, 0xAA +'轰' = 0x04, 0xAB +'恶' = 0x04, 0xAC +'剧' = 0x04, 0xAD +'丧' = 0x04, 0xAE +'历' = 0x04, 0xAF +'拖' = 0x04, 0xB0 +'脸' = 0x04, 0xB1 +'肩' = 0x04, 0xB2 +'架' = 0x04, 0xB3 +'壮' = 0x04, 0xB4 +'美' = 0x04, 0xB5 +'温' = 0x04, 0xB6 +'暖' = 0x04, 0xB7 +'补' = 0x04, 0xB8 +'检' = 0x04, 0xB9 +'摸' = 0x04, 0xBA +'殊' = 0x04, 0xBB +'愤' = 0x04, 0xBC +'造' = 0x04, 0xBD +'铺' = 0x04, 0xBE +'却' = 0x04, 0xBF +'散' = 0x04, 0xC0 +'臭' = 0x04, 0xC1 +'垫' = 0x04, 0xC2 +'砾' = 0x04, 0xC3 +'嗯' = 0x04, 0xC4 +'投' = 0x04, 0xC5 +'教' = 0x04, 0xC6 +'训' = 0x04, 0xC7 +'遵' = 0x04, 0xC8 +'言' = 0x04, 0xC9 +'菜' = 0x04, 0xCA +'印' = 0x04, 0xCB +'侵' = 0x04, 0xCC +'卵' = 0x04, 0xCD +'今' = 0x04, 0xCE +'粗' = 0x04, 0xCF +'乎' = 0x04, 0xD0 +'料' = 0x04, 0xD1 +'拥' = 0x04, 0xD2 +'付' = 0x04, 0xD3 +'代' = 0x04, 0xD4 +'价' = 0x04, 0xD5 +'状' = 0x04, 0xD6 +'态' = 0x04, 0xD7 +'层' = 0x04, 0xD8 +'束' = 0x04, 0xD9 +'局' = 0x04, 0xDA +'阅' = 0x04, 0xDB +'朝' = 0x04, 0xDC +'驶' = 0x04, 0xDD +'闭' = 0x04, 0xDE +'泊' = 0x04, 0xDF +'废' = 0x04, 0xE0 +'矿' = 0x04, 0xE1 +'龙' = 0x04, 0xE2 +'敲' = 0x04, 0xE3 +'餐' = 0x04, 0xE4 +'尊' = 0x04, 0xE5 +'敬' = 0x04, 0xE6 +'违' = 0x04, 0xE7 +'规' = 0x04, 0xE8 +'障' = 0x04, 0xE9 +'碍' = 0x04, 0xEA +'旦' = 0x04, 0xEB +'漫' = 0x04, 0xEC +'驾' = 0x04, 0xED +'遥' = 0x04, 0xEE +'耍' = 0x04, 0xEF +'赖' = 0x04, 0xF0 +'抄' = 0x04, 0xF1 +'懂' = 0x04, 0xF2 +'理' = 0x04, 0xF3 +'取' = 0x04, 0xF4 +'资' = 0x04, 0xF5 +'格' = 0x04, 0xF6 +'竞' = 0x04, 0xF7 +'争' = 0x04, 0xF8 +'兴' = 0x04, 0xF9 +'创' = 0x04, 0xFA +'借' = 0x04, 0xFB +'第' = 0x04, 0xFC +'称' = 0x04, 0xFD +'品' = 0x04, 0xFE +'尝' = 0x04, 0xFF +'六' = 0x05, 0x00 +'几' = 0x05, 0x01 +'部' = 0x05, 0x02 +'油' = 0x05, 0x03 +'启' = 0x05, 0x04 +'区' = 0x05, 0x05 +'域' = 0x05, 0x06 +'断' = 0x05, 0x07 +'乐' = 0x05, 0x08 +'缠' = 0x05, 0x09 +'哥' = 0x05, 0x0A +'揭' = 0x05, 0x0B +'亏' = 0x05, 0x0C +'挑' = 0x05, 0x0D +'形' = 0x05, 0x0E +'-' = 0x05, 0x0F +'淹' = 0x05, 0x10 +'糟' = 0x05, 0x11 +'蹋' = 0x05, 0x12 +'呜' = 0x05, 0x13 +'晶' = 0x05, 0x14 +'湿' = 0x05, 0x15 +'叔' = 0x05, 0x16 +'蚂' = 0x05, 0x17 +'蚁' = 0x05, 0x18 +'蚤' = 0x05, 0x19 +'惹' = 0x05, 0x1A +'吞' = 0x05, 0x1B +'闷' = 0x05, 0x1C +'渊' = 0x05, 0x1D +'冒' = 0x05, 0x1E +'息' = 0x05, 0x1F +'十' = 0x05, 0x20 +'组' = 0x05, 0x21 +'群' = 0x05, 0x22 +'思' = 0x05, 0x23 +'议' = 0x05, 0x24 +'归' = 0x05, 0x25 +'恨' = 0x05, 0x26 +'期' = 0x05, 0x27 +'待' = 0x05, 0x28 +'精' = 0x05, 0x29 +'昏' = 0x05, 0x2A +'承' = 0x05, 0x2B +'责' = 0x05, 0x2C +'私' = 0x05, 0x2D +'遇' = 0x05, 0x2E +'灾' = 0x05, 0x2F diff --git a/charmap_menu.txt b/charmap_menu.txt index 7642e737..71c1a684 100644 --- a/charmap_menu.txt +++ b/charmap_menu.txt @@ -1,5 +1,5 @@ -# Menu HUD chars, only used in JP -# Char values used by text_menu_strings.h.in +// Menu HUD chars, only used in JP +// Char values used by text_menu_strings.h.in 'フ' = 0x00 'ァ' = 0x01 'イ' = 0x02 diff --git a/data/behavior_data.c b/data/behavior_data.c index e9234e53..04f95a1c 100644 --- a/data/behavior_data.c +++ b/data/behavior_data.c @@ -114,7 +114,7 @@ // Often used to end behavior scripts that do not contain an infinite loop. #define BREAK() \ BC_B(0x0A) - + // Exits the behavior script, unused. #define BREAK_UNUSED() \ BC_B(0x0B) @@ -175,15 +175,15 @@ #define ADD_INT_RAND_RSHIFT(field, min, rshift) \ BC_BBH(0x17, field, min), \ BC_H(rshift) - + // No operation. Unused. #define CMD_NOP_1(field) \ BC_BB(0x18, field) - + // No operation. Unused. #define CMD_NOP_2(field) \ BC_BB(0x19, field) - + // No operation. Unused. #define CMD_NOP_3(field) \ BC_BB(0x1A, field) @@ -418,7 +418,7 @@ const BehaviorScript bhvPoleGrabbing[] = { END_LOOP(), }; -const BehaviorScript bhvThiHugeIslandTop[] = { +const BehaviorScript bhvTHIHugeIslandTop[] = { BEGIN(OBJ_LIST_SURFACE), OR_INT(oFlags, OBJ_FLAG_UPDATE_GFX_POS_AND_ANGLE), LOAD_COLLISION_DATA(thi_seg7_collision_top_trap), @@ -427,7 +427,7 @@ const BehaviorScript bhvThiHugeIslandTop[] = { END_LOOP(), }; -const BehaviorScript bhvThiTinyIslandTop[] = { +const BehaviorScript bhvTHITinyIslandTop[] = { BEGIN(OBJ_LIST_DEFAULT), OR_INT(oFlags, (OBJ_FLAG_COMPUTE_DIST_TO_MARIO | OBJ_FLAG_UPDATE_GFX_POS_AND_ANGLE)), BEGIN_LOOP(), @@ -724,13 +724,13 @@ const BehaviorScript bhvBulletBillCannon[] = { END_LOOP(), }; -const BehaviorScript bhvWfBreakableWallRight[] = { +const BehaviorScript bhvWFBreakableWallRight[] = { BEGIN(OBJ_LIST_SURFACE), LOAD_COLLISION_DATA(wf_seg7_collision_breakable_wall), - GOTO(bhvWfBreakableWallLeft + 1 + 2), + GOTO(bhvWFBreakableWallLeft + 1 + 2), }; -const BehaviorScript bhvWfBreakableWallLeft[] = { +const BehaviorScript bhvWFBreakableWallLeft[] = { BEGIN(OBJ_LIST_SURFACE), LOAD_COLLISION_DATA(wf_seg7_collision_breakable_wall_2), // WF breakable walls - common: @@ -773,7 +773,7 @@ const BehaviorScript bhvRotatingCounterClockwise[] = { BREAK(), }; -const BehaviorScript bhvWfRotatingWoodenPlatform[] = { +const BehaviorScript bhvWFRotatingWoodenPlatform[] = { BEGIN(OBJ_LIST_SURFACE), OR_INT(oFlags, OBJ_FLAG_UPDATE_GFX_POS_AND_ANGLE), LOAD_COLLISION_DATA(wf_seg7_collision_clocklike_rotation), @@ -853,7 +853,7 @@ const BehaviorScript bhvWhitePuffExplosion[] = { const BehaviorScript bhvSpawnedStar[] = { BEGIN(OBJ_LIST_LEVEL), OR_INT(oFlags, OBJ_FLAG_UPDATE_GFX_POS_AND_ANGLE), - SET_INT(oBehParams2ndByte, 1), + SET_INT(oBhvParams2ndByte, 1), GOTO(bhvSpawnedStarNoLevelExit + 1 + 1), }; @@ -868,20 +868,20 @@ const BehaviorScript bhvSpawnedStarNoLevelExit[] = { END_LOOP(), }; -const BehaviorScript bhvMrIBlueCoin[] = { +const BehaviorScript bhvSpawnedBlueCoin[] = { BEGIN(OBJ_LIST_LEVEL), SET_INT(oInteractType, INTERACT_COIN), OR_INT(oFlags, OBJ_FLAG_UPDATE_GFX_POS_AND_ANGLE), BILLBOARD(), SET_INT(oIntangibleTimer, 0), - SET_FLOAT(oCoinUnk110, 20), + SET_FLOAT(oCoinBaseVelY, 20), SET_INT(oAnimState, -1), SET_OBJ_PHYSICS(/*Wall hitbox radius*/ 30, /*Gravity*/ -400, /*Bounciness*/ -70, /*Drag strength*/ 1000, /*Friction*/ 1000, /*Buoyancy*/ 200, /*Unused*/ 0, 0), - CALL_NATIVE(bhv_coin_init), + CALL_NATIVE(bhv_spawned_coin_init), SET_INT(oDamageOrCoinValue, 5), SET_HITBOX(/*Radius*/ 120, /*Height*/ 64), BEGIN_LOOP(), - CALL_NATIVE(bhv_coin_loop), + CALL_NATIVE(bhv_spawned_coin_loop), ADD_INT(oAnimState, 1), END_LOOP(), }; @@ -920,7 +920,7 @@ const BehaviorScript bhvCoinFormation[] = { const BehaviorScript bhvOneCoin[] = { BEGIN(OBJ_LIST_LEVEL), - SET_INT(oBehParams2ndByte, 1), + SET_INT(oBhvParams2ndByte, 1), GOTO(bhvYellowCoin + 1), }; @@ -967,10 +967,10 @@ const BehaviorScript bhvSingleCoinGetsSpawned[] = { BEGIN(OBJ_LIST_LEVEL), OR_INT(oFlags, OBJ_FLAG_UPDATE_GFX_POS_AND_ANGLE), BILLBOARD(), - CALL_NATIVE(bhv_coin_init), + CALL_NATIVE(bhv_spawned_coin_init), SET_OBJ_PHYSICS(/*Wall hitbox radius*/ 30, /*Gravity*/ -400, /*Bounciness*/ -70, /*Drag strength*/ 1000, /*Friction*/ 1000, /*Buoyancy*/ 200, /*Unused*/ 0, 0), BEGIN_LOOP(), - CALL_NATIVE(bhv_coin_loop), + CALL_NATIVE(bhv_spawned_coin_loop), ADD_INT(oAnimState, 1), END_LOOP(), }; @@ -1096,7 +1096,7 @@ const BehaviorScript bhvGrindel[] = { END_LOOP(), }; -const BehaviorScript bhvThwomp2[] = { +const BehaviorScript bhvThwomp[] = { BEGIN(OBJ_LIST_SURFACE), LOAD_COLLISION_DATA(thwomp_seg5_collision_0500B92C), OR_INT(oFlags, (OBJ_FLAG_COMPUTE_DIST_TO_MARIO | OBJ_FLAG_SET_FACE_YAW_TO_MOVE_YAW | OBJ_FLAG_UPDATE_GFX_POS_AND_ANGLE)), @@ -1111,7 +1111,7 @@ const BehaviorScript bhvThwomp2[] = { END_LOOP(), }; -const BehaviorScript bhvThwomp[] = { +const BehaviorScript bhvThwomp2[] = { BEGIN(OBJ_LIST_SURFACE), LOAD_COLLISION_DATA(thwomp_seg5_collision_0500B7D0), OR_INT(oFlags, (OBJ_FLAG_COMPUTE_DIST_TO_MARIO | OBJ_FLAG_SET_FACE_YAW_TO_MOVE_YAW | OBJ_FLAG_UPDATE_GFX_POS_AND_ANGLE)), @@ -1136,7 +1136,7 @@ const BehaviorScript bhvTumblingBridgePlatform[] = { END_LOOP(), }; -const BehaviorScript bhvWfTumblingBridge[] = { +const BehaviorScript bhvTumblingBridge[] = { BEGIN(OBJ_LIST_SPAWNER), OR_INT(oFlags, (OBJ_FLAG_ACTIVE_FROM_AFAR | OBJ_FLAG_COMPUTE_DIST_TO_MARIO | OBJ_FLAG_UPDATE_GFX_POS_AND_ANGLE)), SET_HOME(), @@ -1145,21 +1145,21 @@ const BehaviorScript bhvWfTumblingBridge[] = { END_LOOP(), }; -const BehaviorScript bhvBbhTumblingBridge[] = { +const BehaviorScript bhvBBHTumblingBridge[] = { BEGIN(OBJ_LIST_SPAWNER), OR_INT(oFlags, (OBJ_FLAG_ACTIVE_FROM_AFAR | OBJ_FLAG_COMPUTE_DIST_TO_MARIO | OBJ_FLAG_UPDATE_GFX_POS_AND_ANGLE)), SET_HOME(), - SET_INT(oBehParams2ndByte, 1), + SET_INT(oBhvParams2ndByte, TUMBLING_BRIDGE_BP_BBH), BEGIN_LOOP(), CALL_NATIVE(bhv_tumbling_bridge_loop), END_LOOP(), }; -const BehaviorScript bhvLllTumblingBridge[] = { +const BehaviorScript bhvLLLTumblingBridge[] = { BEGIN(OBJ_LIST_SPAWNER), OR_INT(oFlags, (OBJ_FLAG_ACTIVE_FROM_AFAR | OBJ_FLAG_COMPUTE_DIST_TO_MARIO | OBJ_FLAG_UPDATE_GFX_POS_AND_ANGLE)), SET_HOME(), - SET_INT(oBehParams2ndByte, 2), + SET_INT(oBhvParams2ndByte, TUMBLING_BRIDGE_BP_LLL), BEGIN_LOOP(), CALL_NATIVE(bhv_tumbling_bridge_loop), END_LOOP(), @@ -1193,7 +1193,7 @@ const BehaviorScript bhvAnotherElavator[] = { END_LOOP(), }; -const BehaviorScript bhvRrElevatorPlatform[] = { +const BehaviorScript bhvRRElevatorPlatform[] = { BEGIN(OBJ_LIST_SURFACE), OR_INT(oFlags, (OBJ_FLAG_COMPUTE_DIST_TO_MARIO | OBJ_FLAG_UPDATE_GFX_POS_AND_ANGLE)), LOAD_COLLISION_DATA(rr_seg7_collision_elevator_platform), @@ -1205,7 +1205,7 @@ const BehaviorScript bhvRrElevatorPlatform[] = { END_LOOP(), }; -const BehaviorScript bhvHmcElevatorPlatform[] = { +const BehaviorScript bhvHMCElevatorPlatform[] = { BEGIN(OBJ_LIST_SURFACE), OR_INT(oFlags, (OBJ_FLAG_COMPUTE_DIST_TO_MARIO | OBJ_FLAG_UPDATE_GFX_POS_AND_ANGLE)), LOAD_COLLISION_DATA(hmc_seg7_collision_elevator), @@ -1375,7 +1375,7 @@ const BehaviorScript bhvUkikiCage[] = { END_LOOP(), }; -const BehaviorScript bhvBitfsSinkingPlatforms[] = { +const BehaviorScript bhvBitFSSinkingPlatforms[] = { BEGIN(OBJ_LIST_SURFACE), OR_INT(oFlags, OBJ_FLAG_UPDATE_GFX_POS_AND_ANGLE), LOAD_COLLISION_DATA(bitfs_seg7_collision_sinking_platform), @@ -1386,19 +1386,19 @@ const BehaviorScript bhvBitfsSinkingPlatforms[] = { END_LOOP(), }; -const BehaviorScript bhvBitfsSinkingCagePlatform[] = { +const BehaviorScript bhvBitFSSinkingCagePlatform[] = { BEGIN(OBJ_LIST_SURFACE), OR_INT(oFlags, OBJ_FLAG_UPDATE_GFX_POS_AND_ANGLE), LOAD_COLLISION_DATA(bitfs_seg7_collision_sinking_cage_platform), SET_HOME(), - SPAWN_CHILD(/*Model*/ MODEL_BITFS_BLUE_POLE, /*Behavior*/ bhvDddMovingPole), + SPAWN_CHILD(/*Model*/ MODEL_BITFS_BLUE_POLE, /*Behavior*/ bhvDDDMovingPole), BEGIN_LOOP(), CALL_NATIVE(bhv_bitfs_sinking_cage_platform_loop), CALL_NATIVE(load_object_collision_model), END_LOOP(), }; -const BehaviorScript bhvDddMovingPole[] = { +const BehaviorScript bhvDDDMovingPole[] = { BEGIN(OBJ_LIST_POLELIKE), OR_INT(oFlags, OBJ_FLAG_UPDATE_GFX_POS_AND_ANGLE), SET_INT(oInteractType, INTERACT_POLE), @@ -1410,7 +1410,7 @@ const BehaviorScript bhvDddMovingPole[] = { END_LOOP(), }; -const BehaviorScript bhvBitfsTiltingInvertedPyramid[] = { +const BehaviorScript bhvBitFSTiltingInvertedPyramid[] = { BEGIN(OBJ_LIST_SURFACE), OR_INT(oFlags, (OBJ_FLAG_COMPUTE_DIST_TO_MARIO | OBJ_FLAG_SET_FACE_YAW_TO_MOVE_YAW | OBJ_FLAG_UPDATE_GFX_POS_AND_ANGLE)), LOAD_COLLISION_DATA(bitfs_seg7_collision_inverted_pyramid), @@ -1457,7 +1457,7 @@ const BehaviorScript bhvBetaMovingFlames[] = { END_LOOP(), }; -const BehaviorScript bhvRrRotatingBridgePlatform[] = { +const BehaviorScript bhvRRRotatingBridgePlatform[] = { BEGIN(OBJ_LIST_SURFACE), OR_INT(oFlags, (OBJ_FLAG_COMPUTE_DIST_TO_MARIO | OBJ_FLAG_SET_FACE_YAW_TO_MOVE_YAW | OBJ_FLAG_UPDATE_GFX_POS_AND_ANGLE)), LOAD_COLLISION_DATA(rr_seg7_collision_rotating_platform_with_fire), @@ -1607,7 +1607,7 @@ const BehaviorScript bhvTowerPlatformGroup[] = { END_LOOP(), }; -const BehaviorScript bhvWfSlidingTowerPlatform[] = { +const BehaviorScript bhvWFSlidingTowerPlatform[] = { BEGIN(OBJ_LIST_SURFACE), OR_INT(oFlags, (OBJ_FLAG_SET_FACE_YAW_TO_MOVE_YAW | OBJ_FLAG_UPDATE_GFX_POS_AND_ANGLE)), LOAD_COLLISION_DATA(wf_seg7_collision_platform), @@ -1617,7 +1617,7 @@ const BehaviorScript bhvWfSlidingTowerPlatform[] = { END_LOOP(), }; -const BehaviorScript bhvWfElevatorTowerPlatform[] = { +const BehaviorScript bhvWFElevatorTowerPlatform[] = { BEGIN(OBJ_LIST_SURFACE), OR_INT(oFlags, (OBJ_FLAG_SET_FACE_YAW_TO_MOVE_YAW | OBJ_FLAG_UPDATE_GFX_POS_AND_ANGLE)), LOAD_COLLISION_DATA(wf_seg7_collision_platform), @@ -1627,7 +1627,7 @@ const BehaviorScript bhvWfElevatorTowerPlatform[] = { END_LOOP(), }; -const BehaviorScript bhvWfSolidTowerPlatform[] = { +const BehaviorScript bhvWFSolidTowerPlatform[] = { BEGIN(OBJ_LIST_SURFACE), OR_INT(oFlags, (OBJ_FLAG_SET_FACE_YAW_TO_MOVE_YAW | OBJ_FLAG_UPDATE_GFX_POS_AND_ANGLE)), LOAD_COLLISION_DATA(wf_seg7_collision_platform), @@ -1704,7 +1704,7 @@ const BehaviorScript bhvPiranhaPlantWakingBubbles[] = { const BehaviorScript bhvFloorSwitchAnimatesObject[] = { BEGIN(OBJ_LIST_SURFACE), - SET_INT(oBehParams2ndByte, 1), + SET_INT(oBhvParams2ndByte, 1), GOTO(bhvFloorSwitchHardcodedModel + 1), }; @@ -1726,7 +1726,7 @@ const BehaviorScript bhvFloorSwitchHardcodedModel[] = { const BehaviorScript bhvFloorSwitchHiddenObjects[] = { BEGIN(OBJ_LIST_SURFACE), - SET_INT(oBehParams2ndByte, 2), + SET_INT(oBhvParams2ndByte, 2), GOTO(bhvFloorSwitchHardcodedModel + 1), }; @@ -1791,7 +1791,7 @@ const BehaviorScript bhvHeaveHoThrowMario[] = { END_LOOP(), }; -const BehaviorScript bhvCcmTouchedStarSpawn[] = { +const BehaviorScript bhvCCMTouchedStarSpawn[] = { BEGIN(OBJ_LIST_LEVEL), OR_INT(oFlags, (OBJ_FLAG_PERSISTENT_RESPAWN | OBJ_FLAG_UPDATE_GFX_POS_AND_ANGLE)), SET_HITBOX(/*Radius*/ 500, /*Height*/ 500), @@ -2185,7 +2185,7 @@ const BehaviorScript bhvWaterLevelPillar[] = { END_LOOP(), }; -const BehaviorScript bhvDddWarp[] = { +const BehaviorScript bhvDDDWarp[] = { BEGIN(OBJ_LIST_SURFACE), OR_INT(oFlags, OBJ_FLAG_UPDATE_GFX_POS_AND_ANGLE), SET_FLOAT(oCollisionDistance, 30000), @@ -2246,7 +2246,7 @@ const BehaviorScript bhvStub1D0C[] = { DEACTIVATE(), }; -const BehaviorScript bhvLllRotatingHexagonalPlatform[] = { +const BehaviorScript bhvLLLRotatingHexagonalPlatform[] = { BEGIN(OBJ_LIST_SURFACE), OR_INT(oFlags, (OBJ_FLAG_SET_FACE_YAW_TO_MOVE_YAW | OBJ_FLAG_UPDATE_GFX_POS_AND_ANGLE)), LOAD_COLLISION_DATA(lll_seg7_collision_hexagonal_platform), @@ -2258,7 +2258,7 @@ const BehaviorScript bhvLllRotatingHexagonalPlatform[] = { END_LOOP(), }; -const BehaviorScript bhvLllSinkingRockBlock[] = { +const BehaviorScript bhvLLLSinkingRockBlock[] = { BEGIN(OBJ_LIST_SURFACE), OR_INT(oFlags, (OBJ_FLAG_SET_FACE_YAW_TO_MOVE_YAW | OBJ_FLAG_UPDATE_GFX_POS_AND_ANGLE)), LOAD_COLLISION_DATA(lll_seg7_collision_floating_block), @@ -2275,7 +2275,7 @@ const BehaviorScript bhvStub1D70[] = { BREAK(), }; -const BehaviorScript bhvLllMovingOctagonalMeshPlatform[] = { +const BehaviorScript bhvLLLMovingOctagonalMeshPlatform[] = { BEGIN(OBJ_LIST_SURFACE), OR_INT(oFlags, (OBJ_FLAG_COMPUTE_DIST_TO_MARIO | OBJ_FLAG_UPDATE_GFX_POS_AND_ANGLE)), ADD_FLOAT(oPosY, -50), @@ -2290,7 +2290,7 @@ const BehaviorScript bhvSnowBall[] = { BREAK(), }; -const BehaviorScript bhvLllRotatingBlockWithFireBars[] = { +const BehaviorScript bhvLLLRotatingBlockWithFireBars[] = { BEGIN(OBJ_LIST_SURFACE), OR_INT(oFlags, (OBJ_FLAG_COMPUTE_DIST_TO_MARIO | OBJ_FLAG_SET_FACE_YAW_TO_MOVE_YAW | OBJ_FLAG_UPDATE_GFX_POS_AND_ANGLE)), LOAD_COLLISION_DATA(lll_seg7_collision_rotating_fire_bars), @@ -2300,7 +2300,7 @@ const BehaviorScript bhvLllRotatingBlockWithFireBars[] = { END_LOOP(), }; -const BehaviorScript bhvLllRotatingHexFlame[] = { +const BehaviorScript bhvLLLRotatingHexFlame[] = { BEGIN(OBJ_LIST_LEVEL), OR_INT(oFlags, (OBJ_FLAG_COMPUTE_DIST_TO_MARIO | OBJ_FLAG_SET_FACE_YAW_TO_MOVE_YAW | OBJ_FLAG_UPDATE_GFX_POS_AND_ANGLE)), SET_INTERACT_TYPE(INTERACT_FLAME), @@ -2313,7 +2313,7 @@ const BehaviorScript bhvLllRotatingHexFlame[] = { END_LOOP(), }; -const BehaviorScript bhvLllWoodPiece[] = { +const BehaviorScript bhvLLLWoodPiece[] = { BEGIN(OBJ_LIST_SURFACE), OR_INT(oFlags, (OBJ_FLAG_COMPUTE_DIST_TO_MARIO | OBJ_FLAG_SET_FACE_YAW_TO_MOVE_YAW | OBJ_FLAG_UPDATE_GFX_POS_AND_ANGLE)), LOAD_COLLISION_DATA(lll_seg7_collision_wood_piece), @@ -2324,7 +2324,7 @@ const BehaviorScript bhvLllWoodPiece[] = { END_LOOP(), }; -const BehaviorScript bhvLllFloatingWoodBridge[] = { +const BehaviorScript bhvLLLFloatingWoodBridge[] = { BEGIN(OBJ_LIST_DEFAULT), OR_INT(oFlags, (OBJ_FLAG_COMPUTE_DIST_TO_MARIO | OBJ_FLAG_SET_FACE_YAW_TO_MOVE_YAW | OBJ_FLAG_UPDATE_GFX_POS_AND_ANGLE)), SET_MODEL(MODEL_NONE), @@ -2343,7 +2343,7 @@ const BehaviorScript bhvVolcanoFlames[] = { END_LOOP(), }; -const BehaviorScript bhvLllRotatingHexagonalRing[] = { +const BehaviorScript bhvLLLRotatingHexagonalRing[] = { BEGIN(OBJ_LIST_SURFACE), OR_INT(oFlags, (OBJ_FLAG_COMPUTE_DIST_TO_MARIO | OBJ_FLAG_SET_FACE_YAW_TO_MOVE_YAW | OBJ_FLAG_UPDATE_GFX_POS_AND_ANGLE)), LOAD_COLLISION_DATA(lll_seg7_collision_rotating_platform), @@ -2353,7 +2353,7 @@ const BehaviorScript bhvLllRotatingHexagonalRing[] = { END_LOOP(), }; -const BehaviorScript bhvLllSinkingRectangularPlatform[] = { +const BehaviorScript bhvLLLSinkingRectangularPlatform[] = { BEGIN(OBJ_LIST_SURFACE), OR_INT(oFlags, (OBJ_FLAG_COMPUTE_DIST_TO_MARIO | OBJ_FLAG_SET_FACE_YAW_TO_MOVE_YAW | OBJ_FLAG_UPDATE_GFX_POS_AND_ANGLE)), LOAD_COLLISION_DATA(lll_seg7_collision_slow_tilting_platform), @@ -2365,7 +2365,7 @@ const BehaviorScript bhvLllSinkingRectangularPlatform[] = { END_LOOP(), }; -const BehaviorScript bhvLllSinkingSquarePlatforms[] = { +const BehaviorScript bhvLLLSinkingSquarePlatforms[] = { BEGIN(OBJ_LIST_SURFACE), OR_INT(oFlags, (OBJ_FLAG_COMPUTE_DIST_TO_MARIO | OBJ_FLAG_SET_FACE_YAW_TO_MOVE_YAW | OBJ_FLAG_UPDATE_GFX_POS_AND_ANGLE)), LOAD_COLLISION_DATA(lll_seg7_collision_sinking_pyramids), @@ -2378,7 +2378,7 @@ const BehaviorScript bhvLllSinkingSquarePlatforms[] = { END_LOOP(), }; -const BehaviorScript bhvLllTiltingInvertedPyramid[] = { +const BehaviorScript bhvLLLTiltingInvertedPyramid[] = { BEGIN(OBJ_LIST_SURFACE), OR_INT(oFlags, (OBJ_FLAG_COMPUTE_DIST_TO_MARIO | OBJ_FLAG_SET_FACE_YAW_TO_MOVE_YAW | OBJ_FLAG_UPDATE_GFX_POS_AND_ANGLE)), LOAD_COLLISION_DATA(lll_seg7_collision_inverted_pyramid), @@ -2448,7 +2448,7 @@ const BehaviorScript bhvPiranhaPlant[] = { END_LOOP(), }; -const BehaviorScript bhvLllHexagonalMesh[] = { +const BehaviorScript bhvLLLHexagonalMesh[] = { BEGIN(OBJ_LIST_SURFACE), OR_INT(oFlags, OBJ_FLAG_UPDATE_GFX_POS_AND_ANGLE), LOAD_COLLISION_DATA(lll_hexagonal_mesh_seg3_collision_0301CECC), @@ -2457,7 +2457,7 @@ const BehaviorScript bhvLllHexagonalMesh[] = { END_LOOP(), }; -const BehaviorScript bhvLllBowserPuzzlePiece[] = { +const BehaviorScript bhvLLLBowserPuzzlePiece[] = { BEGIN(OBJ_LIST_SURFACE), OR_INT(oFlags, (OBJ_FLAG_COMPUTE_DIST_TO_MARIO | OBJ_FLAG_UPDATE_GFX_POS_AND_ANGLE)), LOAD_COLLISION_DATA(lll_seg7_collision_puzzle_piece), @@ -2469,7 +2469,7 @@ const BehaviorScript bhvLllBowserPuzzlePiece[] = { END_LOOP(), }; -const BehaviorScript bhvLllBowserPuzzle[] = { +const BehaviorScript bhvLLLBowserPuzzle[] = { BEGIN(OBJ_LIST_SPAWNER), DISABLE_RENDERING(), OR_INT(oFlags, (OBJ_FLAG_COMPUTE_DIST_TO_MARIO | OBJ_FLAG_UPDATE_GFX_POS_AND_ANGLE)), @@ -2523,13 +2523,13 @@ const BehaviorScript bhvSmallPenguin[] = { const BehaviorScript bhvManyBlueFishSpawner[] = { BEGIN(OBJ_LIST_DEFAULT), - SET_INT(oBehParams2ndByte, 0), + SET_INT(oBhvParams2ndByte, FISH_SPAWNER_BP_MANY_BLUE), GOTO(bhvFishSpawner + 1), }; const BehaviorScript bhvFewBlueFishSpawner[] = { BEGIN(OBJ_LIST_DEFAULT), - SET_INT(oBehParams2ndByte, 1), + SET_INT(oBhvParams2ndByte, FISH_SPAWNER_BP_FEW_BLUE), GOTO(bhvFishSpawner + 1), }; @@ -2552,7 +2552,7 @@ const BehaviorScript bhvFish[] = { END_LOOP(), }; -const BehaviorScript bhvWdwExpressElevator[] = { +const BehaviorScript bhvWDWExpressElevator[] = { BEGIN(OBJ_LIST_SURFACE), OR_INT(oFlags, (OBJ_FLAG_COMPUTE_DIST_TO_MARIO | OBJ_FLAG_UPDATE_GFX_POS_AND_ANGLE)), LOAD_COLLISION_DATA(wdw_seg7_collision_express_elevator_platform), @@ -2563,7 +2563,7 @@ const BehaviorScript bhvWdwExpressElevator[] = { END_LOOP(), }; -const BehaviorScript bhvWdwExpressElevatorPlatform[] = { +const BehaviorScript bhvWDWExpressElevatorPlatform[] = { BEGIN(OBJ_LIST_SURFACE), OR_INT(oFlags, (OBJ_FLAG_COMPUTE_DIST_TO_MARIO | OBJ_FLAG_UPDATE_GFX_POS_AND_ANGLE)), LOAD_COLLISION_DATA(wdw_seg7_collision_express_elevator_platform), @@ -2691,7 +2691,7 @@ const BehaviorScript bhvSushiSharkCollisionChild[] = { END_LOOP(), }; -const BehaviorScript bhvJrbSlidingBox[] = { +const BehaviorScript bhvJRBSlidingBox[] = { BEGIN(OBJ_LIST_SURFACE), OR_INT(oFlags, OBJ_FLAG_UPDATE_GFX_POS_AND_ANGLE), LOAD_COLLISION_DATA(jrb_seg7_collision_floating_box), @@ -2815,7 +2815,7 @@ const BehaviorScript bhvWhitePuffSmoke2[] = { const BehaviorScript bhvPurpleSwitchHiddenBoxes[] = { BEGIN(OBJ_LIST_SURFACE), - SET_INT(oBehParams2ndByte, 2), + SET_INT(oBhvParams2ndByte, 2), GOTO(bhvFloorSwitchHardcodedModel + 1), }; @@ -2948,14 +2948,14 @@ const BehaviorScript bhvBooWithCage[] = { const BehaviorScript bhvBalconyBigBoo[] = { BEGIN(OBJ_LIST_GENACTOR), - SET_INT(oBehParams2ndByte, 2), + SET_INT(oBhvParams2ndByte, BIG_BOO_BP_BALCONY), SET_INT(oBigBooNumMinionBoosKilled, 10), GOTO(bhvGhostHuntBigBoo + 1), }; const BehaviorScript bhvMerryGoRoundBigBoo[] = { BEGIN(OBJ_LIST_GENACTOR), - SET_INT(oBehParams2ndByte, 1), + SET_INT(oBhvParams2ndByte, BIG_BOO_BP_MERRY_GO_ROUND), // Set number of minion boos killed to 10, which is greater than 5 so that the boo always loads without needing to kill any boos. SET_INT(oBigBooNumMinionBoosKilled, 10), GOTO(bhvGhostHuntBigBoo + 1), @@ -2983,13 +2983,13 @@ const BehaviorScript bhvCourtyardBooTriplet[] = { const BehaviorScript bhvBoo[] = { BEGIN(OBJ_LIST_GENACTOR), - SET_INT(oBehParams2ndByte, 1), + SET_INT(oBhvParams2ndByte, BOO_BP_GENERIC), GOTO(bhvGhostHuntBoo + 1), }; const BehaviorScript bhvMerryGoRoundBoo[] = { BEGIN(OBJ_LIST_GENACTOR), - SET_INT(oBehParams2ndByte, 2), + SET_INT(oBhvParams2ndByte, BOO_BP_MERRY_GO_ROUND), GOTO(bhvGhostHuntBoo + 1), }; @@ -3037,7 +3037,7 @@ const BehaviorScript bhvBooStaircase[] = { END_LOOP(), }; -const BehaviorScript bhvBbhTiltingTrapPlatform[] = { +const BehaviorScript bhvBBHTiltingTrapPlatform[] = { BEGIN(OBJ_LIST_SURFACE), OR_INT(oFlags, (OBJ_FLAG_COMPUTE_ANGLE_TO_MARIO | OBJ_FLAG_COMPUTE_DIST_TO_MARIO | OBJ_FLAG_UPDATE_GFX_POS_AND_ANGLE)), LOAD_COLLISION_DATA(bbh_seg7_collision_tilt_floor_platform), @@ -3067,7 +3067,7 @@ const BehaviorScript bhvMeshElevator[] = { LOAD_COLLISION_DATA(bbh_seg7_collision_mesh_elevator), SET_HOME(), SET_INT(oRoom, 12), - SET_INT(oBehParams2ndByte, 4), + SET_INT(oBhvParams2ndByte, 4), CALL_NATIVE(bhv_elevator_init), BEGIN_LOOP(), CALL_NATIVE(bhv_elevator_loop), @@ -3253,7 +3253,7 @@ const BehaviorScript bhvScuttlebugSpawn[] = { const BehaviorScript bhvWhompKingBoss[] = { BEGIN(OBJ_LIST_SURFACE), - SET_INT(oBehParams2ndByte, 1), + SET_INT(oBhvParams2ndByte, WHOMP_BP_KING), SET_INT(oHealth, 3), GOTO(bhvSmallWhomp + 1 + 1), }; @@ -3764,7 +3764,7 @@ const BehaviorScript bhvBobombBuddy[] = { DROP_TO_FLOOR(), SET_HITBOX(/*Radius*/ 100, /*Height*/ 60), ANIMATE(0), - SET_INT(oBobombBuddyRole, 0), + SET_INT(oBobombBuddyRole, BOBOMB_BUDDY_ROLE_ADVICE), SET_HOME(), CALL_NATIVE(bhv_bobomb_buddy_init), BEGIN_LOOP(), @@ -3782,7 +3782,7 @@ const BehaviorScript bhvBobombBuddyOpensCannon[] = { DROP_TO_FLOOR(), SET_HITBOX(/*Radius*/ 100, /*Height*/ 60), ANIMATE(0), - SET_INT(oBobombBuddyRole, 1), + SET_INT(oBobombBuddyRole, BOBOMB_BUDDY_ROLE_CANNON), SET_HOME(), CALL_NATIVE(bhv_bobomb_buddy_init), BEGIN_LOOP(), @@ -4091,7 +4091,7 @@ const BehaviorScript bhvSmallChillBully[] = { LOAD_ANIMATIONS(oAnimations, chilly_chief_seg6_anims_06003994), DROP_TO_FLOOR(), SET_HOME(), - SET_INT(oBullySubtype, 0x0010), + SET_INT(oBullySubtype, BULLY_STYPE_CHILL), CALL_NATIVE(bhv_small_bully_init), BEGIN_LOOP(), SET_INT(oIntangibleTimer, 0), @@ -4105,7 +4105,7 @@ const BehaviorScript bhvBigChillBully[] = { LOAD_ANIMATIONS(oAnimations, chilly_chief_seg6_anims_06003994), DROP_TO_FLOOR(), SET_HOME(), - SET_INT(oBullySubtype, 0x0010), + SET_INT(oBullySubtype, BULLY_STYPE_CHILL), CALL_NATIVE(bhv_big_bully_init), BEGIN_LOOP(), SET_INT(oIntangibleTimer, 0), @@ -4223,7 +4223,7 @@ const BehaviorScript bhvStarKeyCollectionPuffSpawner[] = { END_LOOP(), }; -const BehaviorScript bhvLllDrawbridgeSpawner[] = { +const BehaviorScript bhvLLLDrawbridgeSpawner[] = { BEGIN(OBJ_LIST_DEFAULT), HIDE(), BEGIN_LOOP(), @@ -4231,7 +4231,7 @@ const BehaviorScript bhvLllDrawbridgeSpawner[] = { END_LOOP(), }; -const BehaviorScript bhvLllDrawbridge[] = { +const BehaviorScript bhvLLLDrawbridge[] = { BEGIN(OBJ_LIST_SURFACE), OR_INT(oFlags, (OBJ_FLAG_SET_FACE_YAW_TO_MOVE_YAW | OBJ_FLAG_UPDATE_GFX_POS_AND_ANGLE)), LOAD_COLLISION_DATA(lll_seg7_collision_drawbridge), @@ -4263,7 +4263,7 @@ const BehaviorScript bhvLargeBomp[] = { END_LOOP(), }; -const BehaviorScript bhvWfSlidingPlatform[] = { +const BehaviorScript bhvWFSlidingPlatform[] = { BEGIN(OBJ_LIST_SURFACE), OR_INT(oFlags, (OBJ_FLAG_MOVE_XZ_USING_FVEL | OBJ_FLAG_UPDATE_GFX_POS_AND_ANGLE)), LOAD_COLLISION_DATA(wf_seg7_collision_sliding_brick_platform), @@ -4334,7 +4334,7 @@ const BehaviorScript bhvBowlingBall[] = { END_LOOP(), }; -const BehaviorScript bhvTtmBowlingBallSpawner[] = { +const BehaviorScript bhvTTMBowlingBallSpawner[] = { BEGIN(OBJ_LIST_GENACTOR), OR_INT(oFlags, OBJ_FLAG_UPDATE_GFX_POS_AND_ANGLE), SET_INT(oBBallSpawnerPeriodMinus1, 63), @@ -4344,7 +4344,7 @@ const BehaviorScript bhvTtmBowlingBallSpawner[] = { END_LOOP(), }; -const BehaviorScript bhvBobBowlingBallSpawner[] = { +const BehaviorScript bhvBoBBowlingBallSpawner[] = { BEGIN(OBJ_LIST_GENACTOR), OR_INT(oFlags, OBJ_FLAG_UPDATE_GFX_POS_AND_ANGLE), SET_INT(oBBallSpawnerPeriodMinus1, 127), @@ -4354,7 +4354,7 @@ const BehaviorScript bhvBobBowlingBallSpawner[] = { END_LOOP(), }; -const BehaviorScript bhvThiBowlingBallSpawner[] = { +const BehaviorScript bhvTHIBowlingBallSpawner[] = { BEGIN(OBJ_LIST_GENACTOR), OR_INT(oFlags, OBJ_FLAG_UPDATE_GFX_POS_AND_ANGLE), BEGIN_LOOP(), @@ -4362,7 +4362,7 @@ const BehaviorScript bhvThiBowlingBallSpawner[] = { END_LOOP(), }; -const BehaviorScript bhvRrCruiserWing[] = { +const BehaviorScript bhvRRCruiserWing[] = { BEGIN(OBJ_LIST_DEFAULT), OR_INT(oFlags, OBJ_FLAG_UPDATE_GFX_POS_AND_ANGLE), CALL_NATIVE(bhv_rr_cruiser_wing_init), @@ -4382,7 +4382,7 @@ const BehaviorScript bhvSpindel[] = { END_LOOP(), }; -const BehaviorScript bhvSslMovingPyramidWall[] = { +const BehaviorScript bhvSSLMovingPyramidWall[] = { BEGIN(OBJ_LIST_SURFACE), OR_INT(oFlags, (OBJ_FLAG_SET_FACE_ANGLE_TO_MOVE_ANGLE | OBJ_FLAG_UPDATE_GFX_POS_AND_ANGLE)), LOAD_COLLISION_DATA(ssl_seg7_collision_0702808C), @@ -4671,7 +4671,7 @@ const BehaviorScript bhvHiddenStarTrigger[] = { END_LOOP(), }; -const BehaviorScript bhvTtmRollingLog[] = { +const BehaviorScript bhvTTMRollingLog[] = { BEGIN(OBJ_LIST_SURFACE), OR_INT(oFlags, OBJ_FLAG_UPDATE_GFX_POS_AND_ANGLE), LOAD_COLLISION_DATA(ttm_seg7_collision_pitoune_2), @@ -4684,7 +4684,7 @@ const BehaviorScript bhvTtmRollingLog[] = { END_LOOP(), }; -const BehaviorScript bhvLllVolcanoFallingTrap[] = { +const BehaviorScript bhvLLLVolcanoFallingTrap[] = { BEGIN(OBJ_LIST_SURFACE), OR_INT(oFlags, OBJ_FLAG_UPDATE_GFX_POS_AND_ANGLE), LOAD_COLLISION_DATA(lll_seg7_collision_falling_wall), @@ -4695,7 +4695,7 @@ const BehaviorScript bhvLllVolcanoFallingTrap[] = { END_LOOP(), }; -const BehaviorScript bhvLllRollingLog[] = { +const BehaviorScript bhvLLLRollingLog[] = { BEGIN(OBJ_LIST_SURFACE), OR_INT(oFlags, OBJ_FLAG_UPDATE_GFX_POS_AND_ANGLE), LOAD_COLLISION_DATA(lll_seg7_collision_pitoune), @@ -4708,7 +4708,7 @@ const BehaviorScript bhvLllRollingLog[] = { END_LOOP(), }; -const BehaviorScript bhv1upWalking[] = { +const BehaviorScript bhv1UpWalking[] = { BEGIN(OBJ_LIST_LEVEL), OR_INT(oFlags, (OBJ_FLAG_COMPUTE_ANGLE_TO_MARIO | OBJ_FLAG_UPDATE_GFX_POS_AND_ANGLE)), BILLBOARD(), @@ -4720,7 +4720,7 @@ const BehaviorScript bhv1upWalking[] = { END_LOOP(), }; -const BehaviorScript bhv1upRunningAway[] = { +const BehaviorScript bhv1UpRunningAway[] = { BEGIN(OBJ_LIST_LEVEL), OR_INT(oFlags, (OBJ_FLAG_COMPUTE_ANGLE_TO_MARIO | OBJ_FLAG_UPDATE_GFX_POS_AND_ANGLE)), BILLBOARD(), @@ -4732,7 +4732,7 @@ const BehaviorScript bhv1upRunningAway[] = { END_LOOP(), }; -const BehaviorScript bhv1upSliding[] = { +const BehaviorScript bhv1UpSliding[] = { BEGIN(OBJ_LIST_LEVEL), OR_INT(oFlags, OBJ_FLAG_UPDATE_GFX_POS_AND_ANGLE), BILLBOARD(), @@ -4758,7 +4758,7 @@ const BehaviorScript bhv1Up[] = { END_LOOP(), }; -const BehaviorScript bhv1upJumpOnApproach[] = { +const BehaviorScript bhv1UpJumpOnApproach[] = { BEGIN(OBJ_LIST_LEVEL), OR_INT(oFlags, (OBJ_FLAG_COMPUTE_ANGLE_TO_MARIO | OBJ_FLAG_UPDATE_GFX_POS_AND_ANGLE)), BILLBOARD(), @@ -4771,7 +4771,7 @@ const BehaviorScript bhv1upJumpOnApproach[] = { END_LOOP(), }; -const BehaviorScript bhvHidden1up[] = { +const BehaviorScript bhvHidden1Up[] = { BEGIN(OBJ_LIST_LEVEL), OR_INT(oFlags, (OBJ_FLAG_COMPUTE_ANGLE_TO_MARIO | OBJ_FLAG_UPDATE_GFX_POS_AND_ANGLE)), BILLBOARD(), @@ -4784,7 +4784,7 @@ const BehaviorScript bhvHidden1up[] = { END_LOOP(), }; -const BehaviorScript bhvHidden1upTrigger[] = { +const BehaviorScript bhvHidden1UpTrigger[] = { BEGIN(OBJ_LIST_LEVEL), OR_INT(oFlags, OBJ_FLAG_UPDATE_GFX_POS_AND_ANGLE), SET_HITBOX(/*Radius*/ 100, /*Height*/ 100), @@ -4794,7 +4794,7 @@ const BehaviorScript bhvHidden1upTrigger[] = { END_LOOP(), }; -const BehaviorScript bhvHidden1upInPole[] = { +const BehaviorScript bhvHidden1UpInPole[] = { BEGIN(OBJ_LIST_LEVEL), OR_INT(oFlags, (OBJ_FLAG_COMPUTE_ANGLE_TO_MARIO | OBJ_FLAG_UPDATE_GFX_POS_AND_ANGLE)), BILLBOARD(), @@ -4807,7 +4807,7 @@ const BehaviorScript bhvHidden1upInPole[] = { END_LOOP(), }; -const BehaviorScript bhvHidden1upInPoleTrigger[] = { +const BehaviorScript bhvHidden1UpInPoleTrigger[] = { BEGIN(OBJ_LIST_LEVEL), OR_INT(oFlags, OBJ_FLAG_UPDATE_GFX_POS_AND_ANGLE), SET_HITBOX(/*Radius*/ 100, /*Height*/ 100), @@ -4817,7 +4817,7 @@ const BehaviorScript bhvHidden1upInPoleTrigger[] = { END_LOOP(), }; -const BehaviorScript bhvHidden1upInPoleSpawner[] = { +const BehaviorScript bhvHidden1UpInPoleSpawner[] = { BEGIN(OBJ_LIST_LEVEL), OR_INT(oFlags, OBJ_FLAG_UPDATE_GFX_POS_AND_ANGLE), BEGIN_LOOP(), @@ -4877,7 +4877,7 @@ const BehaviorScript bhvSnowMoundSpawn[] = { END_LOOP(), }; -const BehaviorScript bhvWdwSquareFloatingPlatform[] = { +const BehaviorScript bhvWDWSquareFloatingPlatform[] = { BEGIN(OBJ_LIST_SURFACE), OR_INT(oFlags, (OBJ_FLAG_SET_FACE_YAW_TO_MOVE_YAW | OBJ_FLAG_UPDATE_GFX_POS_AND_ANGLE)), LOAD_COLLISION_DATA(wdw_seg7_collision_square_floating_platform), @@ -4889,7 +4889,7 @@ const BehaviorScript bhvWdwSquareFloatingPlatform[] = { END_LOOP(), }; -const BehaviorScript bhvWdwRectangularFloatingPlatform[] = { +const BehaviorScript bhvWDWRectangularFloatingPlatform[] = { BEGIN(OBJ_LIST_SURFACE), OR_INT(oFlags, (OBJ_FLAG_SET_FACE_YAW_TO_MOVE_YAW | OBJ_FLAG_UPDATE_GFX_POS_AND_ANGLE)), LOAD_COLLISION_DATA(wdw_seg7_collision_rect_floating_platform), @@ -4901,7 +4901,7 @@ const BehaviorScript bhvWdwRectangularFloatingPlatform[] = { END_LOOP(), }; -const BehaviorScript bhvJrbFloatingPlatform[] = { +const BehaviorScript bhvJRBFloatingPlatform[] = { BEGIN(OBJ_LIST_SURFACE), OR_INT(oFlags, (OBJ_FLAG_SET_FACE_YAW_TO_MOVE_YAW | OBJ_FLAG_UPDATE_GFX_POS_AND_ANGLE)), LOAD_COLLISION_DATA(jrb_seg7_collision_floating_platform), @@ -4976,7 +4976,7 @@ const BehaviorScript bhvPillarBase[] = { END_LOOP(), }; -const BehaviorScript bhvJrbFloatingBox[] = { +const BehaviorScript bhvJRBFloatingBox[] = { BEGIN(OBJ_LIST_SURFACE), OR_INT(oFlags, OBJ_FLAG_UPDATE_GFX_POS_AND_ANGLE), LOAD_COLLISION_DATA(jrb_seg7_collision_floating_box), @@ -5006,7 +5006,7 @@ const BehaviorScript bhvTreasureChestsShip[] = { END_LOOP(), }; -const BehaviorScript bhvTreasureChestsJrb[] = { +const BehaviorScript bhvTreasureChestsJRB[] = { BEGIN(OBJ_LIST_DEFAULT), OR_INT(oFlags, OBJ_FLAG_UPDATE_GFX_POS_AND_ANGLE), DROP_TO_FLOOR(), @@ -5016,13 +5016,13 @@ const BehaviorScript bhvTreasureChestsJrb[] = { END_LOOP(), }; -const BehaviorScript bhvTreasureChests[] = { +const BehaviorScript bhvTreasureChestsDDD[] = { BEGIN(OBJ_LIST_DEFAULT), OR_INT(oFlags, OBJ_FLAG_UPDATE_GFX_POS_AND_ANGLE), DROP_TO_FLOOR(), - CALL_NATIVE(bhv_treasure_chest_init), + CALL_NATIVE(bhv_treasure_chest_ddd_init), BEGIN_LOOP(), - CALL_NATIVE(bhv_treasure_chest_loop), + CALL_NATIVE(bhv_treasure_chest_ddd_loop), END_LOOP(), }; diff --git a/diff_settings.py b/diff_settings.py index 933ccb37..dd8b5108 100644 --- a/diff_settings.py +++ b/diff_settings.py @@ -10,6 +10,8 @@ def add_custom_arguments(parser): help="Set version to EU.") group.add_argument('-s', dest='lang', action='store_const', const='sh', help="Set version to SH.") + group.add_argument('-c', dest='lang', action='store_const', const='cn', + help="Set version to CN.") def apply(config, args): lang = args.lang or 'us' diff --git a/enhancements/README.md b/enhancements/README.md index 241d82f3..50405715 100644 --- a/enhancements/README.md +++ b/enhancements/README.md @@ -8,10 +8,10 @@ To apply a patch, run `tools/apply_patch.sh [patch]` where `[patch]` is the name to the source code. Likewise, to undo the changes from a patch you applied, run -`tools/revert_patch.sh` with the name of the .patch file you wish to undo. +`tools/revert_patch.sh` with the name of the .patch file you wish to undo. To create your own enhancement patch, switch to the `master` Git -branch, make your changes to the code (but do not commit), then run `tools/create_patch.sh`. Your changes will be stored in the .patch file you specify. +branch, make your changes to the code (but do not commit), then run `tools/create_patch.sh`. Your changes will be stored in the .patch file you specify. The following enhancements are included in this directory: diff --git a/enhancements/crash.patch b/enhancements/crash.patch index 87c5c8f9..671bbb2e 100644 --- a/enhancements/crash.patch +++ b/enhancements/crash.patch @@ -158,7 +158,7 @@ index 00000000..033bf952 + jr $k0 // run the original handler + nop diff --git a/lib/asm/__osExceptionPreamble.s b/lib/asm/__osExceptionPreamble.s -index c3b97993..c552a485 100644 +index 4e841ea0..ab0c7d13 100644 --- a/lib/asm/__osExceptionPreamble.s +++ b/lib/asm/__osExceptionPreamble.s @@ -11,8 +11,8 @@ @@ -173,17 +173,17 @@ index c3b97993..c552a485 100644 nop diff --git a/sm64.ld b/sm64.ld -index 7d9b5b4a..c7bb81b9 100755 +index da9bc4dd..25ac57e8 100755 --- a/sm64.ld +++ b/sm64.ld @@ -117,6 +117,7 @@ SECTIONS - BUILD_DIR/src/game/rendering_graph_node.o(.text); - BUILD_DIR/src/game/profiler.o(.text); - BUILD_DIR/asm/decompress.o(.text); -+ BUILD_DIR/asm/crash.o(.text); - BUILD_DIR/src/game/camera.o(.text); - BUILD_DIR/src/game/debug_course.o(.text); - BUILD_DIR/src/game/object_list_processor.o(.text); + BUILD_DIR/src/game/rendering_graph_node.o(.text); + BUILD_DIR/src/game/profiler.o(.text); + BUILD_DIR/asm/decompress.o(.text); ++ BUILD_DIR/asm/crash.o(.text); + BUILD_DIR/src/game/camera.o(.text); + BUILD_DIR/src/game/debug_course.o(.text); + BUILD_DIR/src/game/object_list_processor.o(.text); diff --git a/src/game/crash.c b/src/game/crash.c new file mode 100644 index 00000000..716adfbd diff --git a/enhancements/ique_support.patch b/enhancements/ique_support.patch deleted file mode 100644 index 8487c48e..00000000 --- a/enhancements/ique_support.patch +++ /dev/null @@ -1,312 +0,0 @@ -diff --git a/include/PR/console_type.h b/include/PR/console_type.h -new file mode 100644 -index 00000000..e60550ab ---- /dev/null -+++ b/include/PR/console_type.h -@@ -0,0 +1,7 @@ -+enum ConsoleType { -+ CONSOLE_N64, -+ CONSOLE_IQUE -+}; -+ -+extern enum ConsoleType gConsoleType; -+extern enum ConsoleType get_console_type(void); -diff --git a/lib/asm/skGetId.s b/lib/asm/skGetId.s -new file mode 100644 -index 00000000..58e7d4f9 ---- /dev/null -+++ b/lib/asm/skGetId.s -@@ -0,0 +1,18 @@ -+// Code by stuckpixel -+ -+.set noreorder -+.set gp=64 -+ -+#include "macros.inc" -+ -+glabel skGetId -+ li $v0, 0 -+ li $t0, 0xA4300014 -+ lw $t1, 0x00($t0) -+ nop -+ jr $ra -+ nop -+ nop -+ nop -+ nop -+ nop -diff --git a/lib/src/__osViSwapContext.c b/lib/src/__osViSwapContext.c -index 990cb11f..22756e91 100644 ---- a/lib/src/__osViSwapContext.c -+++ b/lib/src/__osViSwapContext.c -@@ -54,7 +54,9 @@ void __osViSwapContext() { - HW_REG(VI_INTR_REG, u32) = s0->fldRegs[field].vIntr; - HW_REG(VI_X_SCALE_REG, u32) = s1->unk20; - HW_REG(VI_Y_SCALE_REG, u32) = s1->unk2c; -- HW_REG(VI_CONTROL_REG, u32) = s1->features; -+ /* Make sure bit 13 is cleared. Otherwise, graphics will be corrupted on -+ * iQue Player. This has no effect on N64. */ -+ HW_REG(VI_CONTROL_REG, u32) = s1->features & ~(1 << 13); - __osViNext = __osViCurr; - __osViCurr = s1; - *__osViNext = *__osViCurr; -diff --git a/lib/src/consoleType.c b/lib/src/consoleType.c -new file mode 100644 -index 00000000..ef08d1ef ---- /dev/null -+++ b/lib/src/consoleType.c -@@ -0,0 +1,12 @@ -+#include "libultra_internal.h" -+#include -+ -+enum ConsoleType gConsoleType; -+ -+void skGetId(u32 *out); -+ -+enum ConsoleType get_console_type(void) { -+ u32 id = 0; -+ skGetId(&id); -+ return (id == 0) ? CONSOLE_N64 : CONSOLE_IQUE; -+} -diff --git a/lib/src/osEepromProbe.c b/lib/src/osEepromProbe.c -index d550b846..bbaf2bcc 100644 ---- a/lib/src/osEepromProbe.c -+++ b/lib/src/osEepromProbe.c -@@ -1,4 +1,5 @@ - #include "libultra_internal.h" -+#include - - // TODO: merge with osEepromWrite - typedef struct { -@@ -13,11 +14,23 @@ s32 osEepromProbe(OSMesgQueue *mq) { - unkStruct sp18; - - __osSiGetAccess(); -- status = __osEepStatus(mq, &sp18); -- if (status == 0 && (sp18.unk00 & 0x8000) != 0) { -- status = 1; -- } else { -- status = 0; -+ if (gConsoleType == CONSOLE_N64) { -+ status = __osEepStatus(mq, &sp18); -+ if (status == 0 && (sp18.unk00 & 0x8000) != 0) { -+ status = 1; -+ } else { -+ status = 0; -+ } -+ } else if (gConsoleType == CONSOLE_IQUE) { -+ s32 __osBbEepromSize = * (s32*) 0x80000360; -+ -+ if (__osBbEepromSize == 0x200) { -+ status = 1; -+ } -+ -+ if (__osBbEepromSize == 0x800) { -+ status = 2; -+ } - } - __osSiRelAccess(); - return status; -diff --git a/lib/src/osEepromRead.c b/lib/src/osEepromRead.c -index ea784b2c..116dae2d 100644 ---- a/lib/src/osEepromRead.c -+++ b/lib/src/osEepromRead.c -@@ -1,4 +1,5 @@ - #include "libultra_internal.h" -+#include - - extern u8 _osLastSentSiCmd; - -@@ -42,33 +43,44 @@ s32 osEepromRead(OSMesgQueue *mq, u8 address, u8 *buffer) { - return -1; - } - __osSiGetAccess(); -- sp34 = __osEepStatus(mq, &sp28); -- if (sp34 != 0 || sp28.unk00 != 0x8000) { -+ if (gConsoleType == CONSOLE_N64) { -+ sp34 = __osEepStatus(mq, &sp28); -+ if (sp34 != 0 || sp28.unk00 != 0x8000) { - -- return 8; -- } -- while (sp28.unk02 & 0x80) { -- __osEepStatus(mq, &sp28); -- } -- __osPackEepReadData(address); -- sp34 = __osSiRawStartDma(OS_WRITE, &D_80365E00); -- osRecvMesg(mq, NULL, OS_MESG_BLOCK); -- for (sp30 = 0; sp30 < 0x10; sp30++) { -- (D_80365E00)[sp30] = 255; -- } -- D_80365E3C = 0; -- sp34 = __osSiRawStartDma(OS_READ, D_80365E00); -- _osLastSentSiCmd = 4; -- osRecvMesg(mq, NULL, OS_MESG_BLOCK); -- for (sp30 = 0; sp30 < 4; sp30++) { -- sp2c++; -- } -- sp20 = *(unkStruct2 *) sp2c; -- sp34 = (sp20.unk01 & 0xc0) >> 4; -- if (sp34 == 0) { -- for (sp30 = 0; sp30 < 8; sp30++) { -- *buffer++ = ((u8 *) &sp20.unk04)[sp30]; -+ return 8; -+ } -+ while (sp28.unk02 & 0x80) { -+ __osEepStatus(mq, &sp28); -+ } -+ __osPackEepReadData(address); -+ sp34 = __osSiRawStartDma(OS_WRITE, &D_80365E00); -+ osRecvMesg(mq, NULL, OS_MESG_BLOCK); -+ for (sp30 = 0; sp30 < 0x10; sp30++) { -+ (D_80365E00)[sp30] = 255; - } -+ D_80365E3C = 0; -+ sp34 = __osSiRawStartDma(OS_READ, D_80365E00); -+ _osLastSentSiCmd = 4; -+ osRecvMesg(mq, NULL, OS_MESG_BLOCK); -+ for (sp30 = 0; sp30 < 4; sp30++) { -+ sp2c++; -+ } -+ sp20 = *(unkStruct2 *) sp2c; -+ sp34 = (sp20.unk01 & 0xc0) >> 4; -+ if (sp34 == 0) { -+ for (sp30 = 0; sp30 < 8; sp30++) { -+ *buffer++ = ((u8 *) &sp20.unk04)[sp30]; -+ } -+ } -+ } else if (gConsoleType == CONSOLE_IQUE) { -+ u8 *__osBbEepromAddress = * (u8**) 0x8000035C; -+ s32 i; -+ -+ for (i = 0; i < 8; i++) { -+ buffer[i] = __osBbEepromAddress[(address << 3) + i]; -+ } -+ -+ sp34 = 0; - } - __osSiRelAccess(); - return sp34; -diff --git a/lib/src/osEepromWrite.c b/lib/src/osEepromWrite.c -index 1a86477b..a94f8721 100644 ---- a/lib/src/osEepromWrite.c -+++ b/lib/src/osEepromWrite.c -@@ -1,5 +1,6 @@ - #include "libultra_internal.h" - #include "osContInternal.h" -+#include - - #ifndef AVOID_UB - ALIGNED8 u32 D_80365E00[15]; -@@ -52,36 +53,47 @@ s32 osEepromWrite(OSMesgQueue *mq, u8 address, u8 *buffer) { - } - - __osSiGetAccess(); -- sp34 = __osEepStatus(mq, &sp1c); -+ if (gConsoleType == CONSOLE_N64) { -+ sp34 = __osEepStatus(mq, &sp1c); - -- if (sp34 != 0 || sp1c.unk00 != 0x8000) { -- return 8; -- } -+ if (sp34 != 0 || sp1c.unk00 != 0x8000) { -+ return 8; -+ } - -- while (sp1c.unk02 & 0x80) { -- __osEepStatus(mq, &sp1c); -- } -+ while (sp1c.unk02 & 0x80) { -+ __osEepStatus(mq, &sp1c); -+ } - -- __osPackEepWriteData(address, buffer); -+ __osPackEepWriteData(address, buffer); - -- sp34 = __osSiRawStartDma(OS_WRITE, &D_80365E00); -- osRecvMesg(mq, NULL, OS_MESG_BLOCK); -+ sp34 = __osSiRawStartDma(OS_WRITE, &D_80365E00); -+ osRecvMesg(mq, NULL, OS_MESG_BLOCK); - -- for (sp30 = 0; sp30 < 0x10; sp30++) { -- (D_80365E00)[sp30] = 255; -- } -+ for (sp30 = 0; sp30 < 0x10; sp30++) { -+ (D_80365E00)[sp30] = 255; -+ } - -- D_80365E3C = 0; -- sp34 = __osSiRawStartDma(OS_READ, D_80365E00); -- _osLastSentSiCmd = 5; -- osRecvMesg(mq, NULL, OS_MESG_BLOCK); -+ D_80365E3C = 0; -+ sp34 = __osSiRawStartDma(OS_READ, D_80365E00); -+ _osLastSentSiCmd = 5; -+ osRecvMesg(mq, NULL, OS_MESG_BLOCK); - -- for (sp30 = 0; sp30 < 4; sp30++) { -- sp2c++; -- } -+ for (sp30 = 0; sp30 < 4; sp30++) { -+ sp2c++; -+ } -+ -+ sp20 = *(unkStruct2 *) sp2c; -+ sp34 = (sp20.unk01 & 0xc0) >> 4; -+ } else if (gConsoleType == CONSOLE_IQUE) { -+ u8 *__osBbEepromAddress = * (u8**) 0x8000035C; -+ s32 i; - -- sp20 = *(unkStruct2 *) sp2c; -- sp34 = (sp20.unk01 & 0xc0) >> 4; -+ for (i = 0; i < 8; i++) { -+ __osBbEepromAddress[(address << 3) + i] = buffer[i]; -+ } -+ -+ sp34 = 0; -+ } - __osSiRelAccess(); - return sp34; - } -diff --git a/lib/src/osInitialize.c b/lib/src/osInitialize.c -index ba73024b..6deaf407 100644 ---- a/lib/src/osInitialize.c -+++ b/lib/src/osInitialize.c -@@ -1,6 +1,7 @@ - #include "libultra_internal.h" - #include "hardware.h" - #include -+#include - - #define PIF_ADDR_START (void *) 0x1FC007FC - -@@ -51,6 +52,7 @@ void osInitialize(void) { - UNUSED u32 eu_sp30; - #endif - UNUSED u32 sp2c; -+ gConsoleType = get_console_type(); - D_80365CD0 = TRUE; - __osSetSR(__osGetSR() | 0x20000000); - __osSetFpcCsr(0x01000800); -diff --git a/sm64.ld b/sm64.ld -index 7d9b5b4a..be853a3b 100755 ---- a/sm64.ld -+++ b/sm64.ld -@@ -306,6 +306,8 @@ SECTIONS - #if ENABLE_RUMBLE - BUILD_DIR/libultra.a:unk_shindou_file_3.o(.text); - #endif -+ BUILD_DIR/libultra.a:consoleType.o(.text) -+ BUILD_DIR/libultra.a:skGetId.o(.text) - BUILD_DIR/lib/rsp.o(.text); - #else - BUILD_DIR/src/game*.o(.text); -@@ -428,6 +430,8 @@ SECTIONS - #if ENABLE_RUMBLE - BUILD_DIR/libultra.a:unk_shindou_file_3.o(.text); - #endif -+ BUILD_DIR/libultra.a:consoleType.o(.text) -+ BUILD_DIR/libultra.a:skGetId.o(.text) - BUILD_DIR/lib/rsp.o(.text); - #endif - diff --git a/enhancements/mem_error_screen.patch b/enhancements/mem_error_screen.patch index 3941e328..9fbbc8a9 100644 --- a/enhancements/mem_error_screen.patch +++ b/enhancements/mem_error_screen.patch @@ -37,7 +37,7 @@ index 749179b1..2f6f7a3c 100644 +#define TEXT_PJ64 _("If you are using PJ64 1.6, go to:\nOptions > Settings > Rom Settings Tab > Memory Size\nthen select 8 MB from the drop-down box.") +#define TEXT_PJ64_2 _("If you are using PJ64 2.X, go to:\nOptions > Settings > Config: > Memory Size, select 8 MB") + - #if defined(VERSION_JP) || defined(VERSION_SH) + #if defined(VERSION_JP) || defined(VERSION_SH) || defined(VERSION_CN) /** diff --git a/levels/entry.c b/levels/entry.c @@ -66,26 +66,26 @@ index 30a87806..6bf7b79a 100644 #include "levels/intro/header.h" +const GeoLayout intro_geo_error_screen[] = { -+ GEO_NODE_SCREEN_AREA(0, SCREEN_WIDTH/2, SCREEN_HEIGHT/2, SCREEN_WIDTH/2, SCREEN_HEIGHT/2), -+ GEO_OPEN_NODE(), -+ GEO_ZBUFFER(0), -+ GEO_OPEN_NODE(), -+ GEO_NODE_ORTHO(100), -+ GEO_OPEN_NODE(), -+ GEO_BACKGROUND_COLOR(0x0001), -+ GEO_CLOSE_NODE(), -+ GEO_CLOSE_NODE(), -+ GEO_ZBUFFER(0), -+ GEO_OPEN_NODE(), -+ GEO_ASM(0, geo18_display_error_message), -+ GEO_CLOSE_NODE(), -+ GEO_CLOSE_NODE(), -+ GEO_END(), ++ GEO_NODE_SCREEN_AREA(0, SCREEN_WIDTH/2, SCREEN_HEIGHT/2, SCREEN_WIDTH/2, SCREEN_HEIGHT/2), ++ GEO_OPEN_NODE(), ++ GEO_ZBUFFER(0), ++ GEO_OPEN_NODE(), ++ GEO_NODE_ORTHO(100), ++ GEO_OPEN_NODE(), ++ GEO_BACKGROUND_COLOR(0x0001), ++ GEO_CLOSE_NODE(), ++ GEO_CLOSE_NODE(), ++ GEO_ZBUFFER(0), ++ GEO_OPEN_NODE(), ++ GEO_ASM(0, geo18_display_error_message), ++ GEO_CLOSE_NODE(), ++ GEO_CLOSE_NODE(), ++ GEO_END(), +}; + // 0x0E0002D0 const GeoLayout intro_geo_0002D0[] = { - GEO_NODE_SCREEN_AREA(0, SCREEN_WIDTH/2, SCREEN_HEIGHT/2, SCREEN_WIDTH/2, SCREEN_HEIGHT/2), + GEO_NODE_SCREEN_AREA(0, SCREEN_WIDTH/2, SCREEN_HEIGHT/2, SCREEN_WIDTH/2, SCREEN_HEIGHT/2), diff --git a/levels/intro/header.h b/levels/intro/header.h index 99277e86..04797cd7 100644 --- a/levels/intro/header.h diff --git a/extract_assets.py b/extract_assets.py index bde5ef21..b09d26c9 100755 --- a/extract_assets.py +++ b/extract_assets.py @@ -76,7 +76,7 @@ def main(): clean_assets(local_asset_file) sys.exit(0) - all_langs = ["jp", "us", "eu", "sh"] + all_langs = ["jp", "us", "eu", "sh", "cn"] if not langs or not all(a in all_langs for a in langs): langs_str = " ".join("[" + lang + "]" for lang in all_langs) print("Usage: " + sys.argv[0] + " " + langs_str) @@ -156,7 +156,11 @@ def main(): # Make sure tools exist subprocess.check_call( - ["make", "-s", "-C", "tools/", "n64graphics", "skyconv", "mio0", "aifc_decode"] + ["make", "-s", "-C", "tools/sm64tools/", "n64graphics", "mio0"] + ) + + subprocess.check_call( + ["make", "-s", "-C", "tools/", "skyconv", "aifc_decode"] ) # Go through the assets in roughly alphabetical order (but assets in the same @@ -175,13 +179,14 @@ def main(): "baserom." + lang + ".z64", ] def append_args(key): - size, locs = asset_map["@sound " + key + " " + lang] + sound_ver = "sh" if lang == "cn" else lang + size, locs = asset_map["@sound " + key + " " + sound_ver] offset = locs[lang][0] args.append(str(offset)) args.append(str(size)) append_args("ctl") append_args("tbl") - if lang == "sh": + if lang in ("sh", "cn"): args.append("--shindou-headers") append_args("ctl header") append_args("tbl header") @@ -195,7 +200,7 @@ def main(): if mio0 is not None: image = subprocess.run( [ - "./tools/mio0", + "./tools/sm64tools/mio0", "-d", "-o", str(mio0), @@ -222,7 +227,8 @@ def main(): if asset.startswith("textures/skyboxes/"): imagetype = "sky" else: - imagetype = "cake" + ("-eu" if "eu" in asset else "") + imagetype = "cake" + ("-cn" if "cn" in asset else "-eu" if "eu" in asset else "") + print(imagetype, png_file.name, asset) subprocess.run( [ "./tools/skyconv", @@ -239,7 +245,7 @@ def main(): fmt = asset.split(".")[-2] subprocess.run( [ - "./tools/n64graphics", + "./tools/sm64tools/n64graphics", "-e", png_file.name, "-g", diff --git a/first-diff.py b/first-diff.py index c4483b53..9d8a65e8 100755 --- a/first-diff.py +++ b/first-diff.py @@ -41,11 +41,18 @@ versionGroup.add_argument( const="sh", dest="version", ) +versionGroup.add_argument( + "-c", + "--cn", + help="use iQue (Chinese) version", + action="store_const", + const="cn", + dest="version", +) parser.add_argument( "-m", "--make", help="run make before finding difference(s)", action="store_true" ) parser.add_argument( - "-c", "--count", type=int, default=1, diff --git a/include/PR/abi.h b/include/PR/abi.h index b73cb726..0f689956 100644 --- a/include/PR/abi.h +++ b/include/PR/abi.h @@ -42,7 +42,7 @@ #define A_INTERLEAVE 13 #define A_SETLOOP 15 -#ifndef VERSION_SH +#if !defined(VERSION_SH) && !defined(VERSION_CN) #define A_ENVMIXER 3 #define A_LOADBUFF 4 @@ -642,7 +642,7 @@ typedef short ENVMIX_STATE[40]; _a->words.w1 = (uintptr_t)(tr); \ } -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) #undef aLoadBuffer #undef aSaveBuffer #undef aMix diff --git a/include/PR/ique.h b/include/PR/ique.h new file mode 100644 index 00000000..b6a3ef6e --- /dev/null +++ b/include/PR/ique.h @@ -0,0 +1,37 @@ +#ifndef IQUE_H +#define IQUE_H + +#include "rcp.h" + +#define MI_SK_EXCEPTION_REG (MI_BASE_REG+0x14) +#define MI_SK_WATCHDOG_TIMER (MI_BASE_REG+0x18) + +// Hardware interrupts +// 0x40 = NAND DMA, 0x80 = MD, 0x100 = RDB, 0x200 = AES, +// 0x400 = PI_ERR, 0x800 = USB0, 0x1000 = USB1, 0x2000 = NAND +#define MI_HW_INTR_REG (MI_BASE_REG+0x38) +#define MI_HW_INTR_MASK_REG (MI_BASE_REG+0x3C) + +#define PI_CARD_ADDR_REG (PI_BASE_REG+0x48) +#define PI_EX_RD_LEN_REG (PI_BASE_REG+0x58) +#define PI_EX_WR_LEN_REG (PI_BASE_REG+0x5C) +#define PI_MISC_REG (PI_BASE_REG+0x60) + +#if defined(_LANGUAGE_C) || defined(_LANGUAGE_C_PLUS_PLUS) + +extern u8 *__osBbEepromAddress; +extern u32 __osBbEepromSize; +extern u32 __osBbFlashAddress; +extern u32 __osBbFlashSize; +extern u32 __osBbSramAddress; +extern u32 __osBbSramSize; +extern u32 *__osBbPakAddress[]; +extern u32 __osBbPakSize; +extern u32 __osBbIsBb; +extern u32 __osBbHackFlags; + +void skKeepAlive(void); + +#endif + +#endif diff --git a/include/PR/libaudio.h b/include/PR/libaudio.h index cb7a5b19..0a8797d7 100644 --- a/include/PR/libaudio.h +++ b/include/PR/libaudio.h @@ -7,7 +7,7 @@ typedef struct { u8 *offset; s32 len; -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) s8 medium; s8 magic; // tbl: 0x04, otherwise: 0x03 @@ -32,11 +32,11 @@ typedef struct typedef struct { -#ifndef VERSION_SH +#if !defined(VERSION_SH) && !defined(VERSION_CN) s16 revision; #endif s16 seqCount; -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) s16 unk2; u8 *data; #if !IS_64_BIT diff --git a/include/PR/os.h b/include/PR/os.h index 3126f481..d10160cb 100644 --- a/include/PR/os.h +++ b/include/PR/os.h @@ -59,37 +59,6 @@ typedef struct { s32 (*dma)(s32, u32, void *, u32); s32 (*edma)(OSPiHandle *, s32, u32, void *, u32); } OSDevMgr; - -/* - * Structure for file system - */ - - - -typedef struct { - int status; - OSMesgQueue *queue; - int channel; - u8 id[32]; - u8 label[32]; - int version; - int dir_size; - int inode_table; /* block location */ - int minode_table; /* mirrioring inode_table */ - int dir_table; /* block location */ - int inode_start_page; /* page # */ - u8 banks; - u8 activebank; -} OSPfs; - - -typedef struct { - u32 file_size; /* bytes */ - u32 game_code; - u16 company_code; - char ext_name[4]; - char game_name[16]; -} OSPfsState; /* * Structure for Profiler @@ -116,39 +85,6 @@ typedef struct { #define OS_STATE_RUNNING 4 #define OS_STATE_WAITING 8 -/* Events */ -#ifdef _FINALROM -#define OS_NUM_EVENTS 15 -#else -#define OS_NUM_EVENTS 23 -#endif - -#define OS_EVENT_SW1 0 /* CPU SW1 interrupt */ -#define OS_EVENT_SW2 1 /* CPU SW2 interrupt */ -#define OS_EVENT_CART 2 /* Cartridge interrupt: used by rmon */ -#define OS_EVENT_COUNTER 3 /* Counter int: used by VI/Timer Mgr */ -#define OS_EVENT_SP 4 /* SP task done interrupt */ -#define OS_EVENT_SI 5 /* SI (controller) interrupt */ -#define OS_EVENT_AI 6 /* AI interrupt */ -#define OS_EVENT_VI 7 /* VI interrupt: used by VI/Timer Mgr */ -#define OS_EVENT_PI 8 /* PI interrupt: used by PI Manager */ -#define OS_EVENT_DP 9 /* DP full sync interrupt */ -#define OS_EVENT_CPU_BREAK 10 /* CPU breakpoint: used by rmon */ -#define OS_EVENT_SP_BREAK 11 /* SP breakpoint: used by rmon */ -#define OS_EVENT_FAULT 12 /* CPU fault event: used by rmon */ -#define OS_EVENT_THREADSTATUS 13 /* CPU thread status: used by rmon */ -#define OS_EVENT_PRENMI 14 /* Pre NMI interrupt */ -#ifndef _FINALROM -#define OS_EVENT_RDB_READ_DONE 15 /* RDB read ok event: used by rmon */ -#define OS_EVENT_RDB_LOG_DONE 16 /* read of log data complete */ -#define OS_EVENT_RDB_DATA_DONE 17 /* read of hostio data complete */ -#define OS_EVENT_RDB_REQ_RAMROM 18 /* host needs ramrom access */ -#define OS_EVENT_RDB_FREE_RAMROM 19 /* host is done with ramrom access */ -#define OS_EVENT_RDB_DBG_DONE 20 -#define OS_EVENT_RDB_FLUSH_PROF 21 -#define OS_EVENT_RDB_ACK_PROF 22 -#endif - /* Flags for debugging purpose */ #define OS_FLAG_CPU_BREAK 1 /* Break exception has occurred */ @@ -186,12 +122,6 @@ typedef struct { #define OS_PRIORITY_APPMAX 127 #define OS_PRIORITY_IDLE 0 /* Must be 0 */ - -/* Flags to turn blocking on/off when sending/receiving message */ - -#define OS_MESG_NOBLOCK 0 -#define OS_MESG_BLOCK 1 - /* Flags to indicate direction of data transfer */ #define OS_READ 0 /* device -> RDRAM */ @@ -406,42 +336,6 @@ typedef struct { #define R_CBUTTONS CONT_F #define D_CBUTTONS CONT_D -/* File System size */ -#define OS_PFS_VERSION 0x0200 -#define OS_PFS_VERSION_HI (OS_PFS_VERSION >> 8) -#define OS_PFS_VERSION_LO (OS_PFS_VERSION & 255) - -#define PFS_FILE_NAME_LEN 16 -#define PFS_FILE_EXT_LEN 4 -#define BLOCKSIZE 32 /* bytes */ -#define PFS_ONE_PAGE 8 /* blocks */ -#define PFS_MAX_BANKS 62 - -/* File System flag */ - -#define PFS_READ 0 -#define PFS_WRITE 1 -#define PFS_CREATE 2 - -/* File System status */ -#define PFS_INITIALIZED 0x1 -#define PFS_CORRUPTED 0x2 /* File system was corrupted */ - -/* File System error number */ - -#define PFS_ERR_NOPACK 1 /* no memory card is plugged or */ -#define PFS_ERR_NEW_PACK 2 /* ram pack has been changed to a */ - /* different one */ -#define PFS_ERR_INCONSISTENT 3 /* need to run Pfschecker */ -#define PFS_ERR_CONTRFAIL CONT_OVERRUN_ERROR -#define PFS_ERR_INVALID 5 /* invalid parameter or file not exist*/ -#define PFS_ERR_BAD_DATA 6 /* the data read from pack are bad*/ -#define PFS_DATA_FULL 7 /* no free pages on ram pack */ -#define PFS_DIR_FULL 8 /* no free directories on ram pack*/ -#define PFS_ERR_EXIST 9 /* file exists */ -#define PFS_ERR_ID_FATAL 10 /* dead ram pack */ -#define PFS_ERR_DEVICE 11 /* wrong device type*/ - /* definition for EEPROM */ #define EEPROM_MAXBLOCKS 64 @@ -739,6 +633,12 @@ extern s32 osMotorInit(OSMesgQueue *, OSPfs *, int); extern s32 osMotorStop(OSPfs *); extern s32 osMotorStart(OSPfs *); +#ifdef VERSION_CN +#define MOTOR_START 1 +#define MOTOR_STOP 0 +extern s32 __osMotorAccess(OSPfs *, s32); +#endif + /* Enhanced PI interface */ extern OSPiHandle *osCartRomInit(void); diff --git a/include/PR/os_cont.h b/include/PR/os_cont.h index 15ee60f3..3b51e3ec 100644 --- a/include/PR/os_cont.h +++ b/include/PR/os_cont.h @@ -53,22 +53,22 @@ extern "C" { typedef struct { u16 type; /* Controller Type */ u8 status; /* Controller status */ - u8 errnum; + u8 errnum; }OSContStatus; typedef struct { u16 button; s8 stick_x; /* -80 <= stick_x <= 80 */ s8 stick_y; /* -80 <= stick_y <= 80 */ - u8 errnum; + u8 errnum; } OSContPad; typedef struct { void *address; /* Ram pad Address: 11 bits */ u8 databuffer[32]; /* address of the data buffer */ - u8 addressCrc; /* CRC code for address */ + u8 addressCrc; /* CRC code for address */ u8 dataCrc; /* CRC code for data */ - u8 errnum; + u8 errnum; } OSContRamIo; diff --git a/include/PR/os_libc.h b/include/PR/os_libc.h index 94111c0b..7dec0e45 100644 --- a/include/PR/os_libc.h +++ b/include/PR/os_libc.h @@ -7,4 +7,12 @@ extern void bcopy(const void *, void *, size_t); extern void bzero(void *, size_t); +/* Printf */ + +extern int sprintf(char *s, const char *fmt, ...); +extern void osSyncPrintf(const char *fmt, ...); +extern void osAsyncPrintf(const char *fmt, ...); +extern int osSyncGetChars(char *buf); +extern int osAsyncGetChars(char *buf); + #endif /* !_OS_LIBC_H_ */ diff --git a/include/PR/os_message.h b/include/PR/os_message.h index 71e76986..458d06c1 100644 --- a/include/PR/os_message.h +++ b/include/PR/os_message.h @@ -76,7 +76,10 @@ typedef struct OSMesgQueue_s { */ /* Events */ -#ifdef _FINALROM + +#ifdef BBPLAYER +#define OS_NUM_EVENTS 31 +#elif defined(_FINALROM) #define OS_NUM_EVENTS 15 #else #define OS_NUM_EVENTS 23 @@ -107,6 +110,16 @@ typedef struct OSMesgQueue_s { #define OS_EVENT_RDB_FLUSH_PROF 21 #define OS_EVENT_RDB_ACK_PROF 22 #endif +#ifdef BBPLAYER +#define OS_EVENT_FLASH 23 /* NAND flash operation complete */ +#define OS_EVENT_AES 24 /* AES */ +#define OS_EVENT_IDE 25 /* IDE? */ +#define OS_EVENT_PI_ERR 26 /* PI Error? */ +#define OS_EVENT_USB0 27 /* USB Controller 0 */ +#define OS_EVENT_USB1 28 /* USB Controller 1 */ +#define OS_EVENT_UNK_29 29 /* TODO does this exist at all */ +#define OS_EVENT_MD 30 /* Related to card */ +#endif /* Flags to turn blocking on/off when sending/receiving message */ diff --git a/include/PR/os_motor.h b/include/PR/os_motor.h new file mode 100644 index 00000000..eb8c7d6c --- /dev/null +++ b/include/PR/os_motor.h @@ -0,0 +1,75 @@ + +/*---------------------------------------------------------------------* + Copyright (C) 1998 Nintendo. + + $RCSfile: os_motor.h,v $ + $Revision: 1.1 $ + $Date: 1998/10/09 08:01:15 $ + *---------------------------------------------------------------------*/ + +#ifndef _OS_MOTOR_H_ +#define _OS_MOTOR_H_ + +#ifdef _LANGUAGE_C_PLUS_PLUS +extern "C" { +#endif + +#include +#include "os_message.h" +#include "os_pfs.h" + + +#if defined(_LANGUAGE_C) || defined(_LANGUAGE_C_PLUS_PLUS) + +/************************************************************************** + * + * Type definitions + * + */ + + +#endif /* defined(_LANGUAGE_C) || defined(_LANGUAGE_C_PLUS_PLUS) */ + +/************************************************************************** + * + * Global definitions + * + */ + + +#if defined(_LANGUAGE_C) || defined(_LANGUAGE_C_PLUS_PLUS) + +/************************************************************************** + * + * Macro definitions + * + */ + + +/************************************************************************** + * + * Extern variables + * + */ + + +/************************************************************************** + * + * Function prototypes + * + */ + +/* Rumble PAK interface */ + +extern s32 osMotorInit(OSMesgQueue *, OSPfs *, int); +extern s32 osMotorStop(OSPfs *); +extern s32 osMotorStart(OSPfs *); + + +#endif /* defined(_LANGUAGE_C) || defined(_LANGUAGE_C_PLUS_PLUS) */ + +#ifdef _LANGUAGE_C_PLUS_PLUS +} +#endif + +#endif /* !_OS_MOTOR_H_ */ diff --git a/include/PR/os_pfs.h b/include/PR/os_pfs.h new file mode 100644 index 00000000..43a39db1 --- /dev/null +++ b/include/PR/os_pfs.h @@ -0,0 +1,123 @@ +/*==================================================================== + * os_pfs.h + * + * Copyright 1995, Silicon Graphics, Inc. + * All Rights Reserved. + * + * This is UNPUBLISHED PROPRIETARY SOURCE CODE of Silicon Graphics, + * Inc.; the contents of this file may not be disclosed to third + * parties, copied or duplicated in any form, in whole or in part, + * without the prior written permission of Silicon Graphics, Inc. + * + * RESTRICTED RIGHTS LEGEND: + * Use, duplication or disclosure by the Government is subject to + * restrictions as set forth in subdivision (c)(1)(ii) of the Rights + * in Technical Data and Computer Software clause at DFARS + * 252.227-7013, and/or in similar or successor clauses in the FAR, + * DOD or NASA FAR Supplement. Unpublished - rights reserved under the + * Copyright Laws of the United States. + *====================================================================*/ + +/*---------------------------------------------------------------------* + Copyright (C) 1998 Nintendo. (Originated by SGI) + + $RCSfile: os_pfs.h,v $ + $Revision: 1.1 $ + $Date: 1998/10/09 08:01:16 $ + *---------------------------------------------------------------------*/ + +#ifndef _OS_PFS_H_ +#define _OS_PFS_H_ + +#ifdef _LANGUAGE_C_PLUS_PLUS +extern "C" { +#endif + +#include +#include "os_message.h" + +#if defined(_LANGUAGE_C) || defined(_LANGUAGE_C_PLUS_PLUS) + +/************************************************************************** + * + * Type definitions + * + */ + +/* + * Structure for file system + */ + +typedef struct { + int status; + OSMesgQueue *queue; + int channel; + u8 id[32]; + u8 label[32]; + int version; + int dir_size; + int inode_table; /* block location */ + int minode_table; /* mirrioring inode_table */ + int dir_table; /* block location */ + int inode_start_page; /* page # */ + u8 banks; + u8 activebank; +} OSPfs; + + +typedef struct { + u32 file_size; /* bytes */ + u32 game_code; + u16 company_code; + char ext_name[4]; + char game_name[16]; +} OSPfsState; + +#endif /* defined(_LANGUAGE_C) || defined(_LANGUAGE_C_PLUS_PLUS) */ + +/************************************************************************** + * + * Global definitions + * + */ + +/* File System size */ +#define OS_PFS_VERSION 0x0200 +#define OS_PFS_VERSION_HI (OS_PFS_VERSION >> 8) +#define OS_PFS_VERSION_LO (OS_PFS_VERSION & 255) + +#define PFS_FILE_NAME_LEN 16 +#define PFS_FILE_EXT_LEN 4 +#define BLOCKSIZE 32 /* bytes */ +#define PFS_ONE_PAGE 8 /* blocks */ +#define PFS_MAX_BANKS 62 + +/* File System flag */ + +#define PFS_READ 0 +#define PFS_WRITE 1 +#define PFS_CREATE 2 + +/* File System status */ +#define PFS_INITIALIZED 0x1 +#define PFS_CORRUPTED 0x2 /* File system was corrupted */ + +/* File System error number */ + +#define PFS_ERR_NOPACK 1 /* no memory card is plugged or */ +#define PFS_ERR_NEW_PACK 2 /* ram pack has been changed to a */ +#define PFS_ERR_INCONSISTENT 3 /* need to run Pfschecker */ +#define PFS_ERR_CONTRFAIL CONT_OVERRUN_ERROR +#define PFS_ERR_INVALID 5 /* invalid parameter or file not exist*/ +#define PFS_ERR_BAD_DATA 6 /* the data read from pack are bad*/ +#define PFS_DATA_FULL 7 /* no free pages on ram pack */ +#define PFS_DIR_FULL 8 /* no free directories on ram pack*/ +#define PFS_ERR_EXIST 9 /* file exists*/ +#define PFS_ERR_ID_FATAL 10 /* dead ram pack */ +#define PFS_ERR_DEVICE 11 /* wrong device type*/ + +#ifdef _LANGUAGE_C_PLUS_PLUS +} +#endif + +#endif diff --git a/include/PR/os_pi.h b/include/PR/os_pi.h index 8da37e25..86b961e2 100644 --- a/include/PR/os_pi.h +++ b/include/PR/os_pi.h @@ -61,7 +61,7 @@ typedef struct { /*0x08*/ void *dramAddr; /*0x0C*/ uintptr_t devAddr; /*0x10*/ size_t size; -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) OSPiHandle *piHandle; // from the official definition #endif } OSIoMesg; diff --git a/include/PR/os_thread.h b/include/PR/os_thread.h index 76e528b5..c07a5745 100644 --- a/include/PR/os_thread.h +++ b/include/PR/os_thread.h @@ -16,6 +16,8 @@ #define OS_STATE_RUNNING 4 #define OS_STATE_WAITING 8 +#if defined(_LANGUAGE_C) || defined(_LANGUAGE_C_PLUS_PLUS) + /* Types */ typedef s32 OSPri; @@ -73,3 +75,5 @@ void osStartThread(OSThread *thread); void osStopThread(OSThread *thread); #endif + +#endif diff --git a/include/PR/os_time.h b/include/PR/os_time.h index ecb05d62..878d13fd 100644 --- a/include/PR/os_time.h +++ b/include/PR/os_time.h @@ -13,7 +13,7 @@ typedef struct OSTimer_str u64 interval; u64 remaining; OSMesgQueue *mq; - OSMesg *msg; + OSMesg msg; } OSTimer; typedef u64 OSTime; diff --git a/include/PR/os_vi.h b/include/PR/os_vi.h index 98fb4ed3..d27c5c55 100644 --- a/include/PR/os_vi.h +++ b/include/PR/os_vi.h @@ -4,6 +4,16 @@ #include #include +//TODO: figure out what this is +#define VI_STATE_01 0x01 +#define VI_STATE_XSCALE_UPDATED 0x02 +#define VI_STATE_YSCALE_UPDATED 0x04 +#define VI_STATE_08 0x08 //related to control regs changing +#define VI_STATE_10 0x10 //swap buffer +#define VI_STATE_BLACK 0x20 //probably related to a black screen +#define VI_STATE_REPEATLINE 0x40 //repeat line? +#define VI_STATE_FADE 0x80 //fade + /* Ultra64 Video Interface */ @@ -27,8 +37,7 @@ /* Types */ -typedef struct -{ +typedef struct { u32 ctrl; u32 width; u32 burst; @@ -40,8 +49,7 @@ typedef struct u32 vCurrent; } OSViCommonRegs; -typedef struct -{ +typedef struct { u32 origin; u32 yScale; u32 vStart; @@ -49,15 +57,13 @@ typedef struct u32 vIntr; } OSViFieldRegs; -typedef struct -{ +typedef struct { u8 type; OSViCommonRegs comRegs; OSViFieldRegs fldRegs[2]; } OSViMode; -typedef struct -{ +typedef struct { /* 0x00 */ u16 unk00; //some kind of flags. swap buffer sets to 0x10 /* 0x02 */ u16 retraceCount; /* 0x04 */ void* buffer; diff --git a/include/PR/rcp.h b/include/PR/rcp.h index 68ce9682..022943e3 100644 --- a/include/PR/rcp.h +++ b/include/PR/rcp.h @@ -161,6 +161,7 @@ The Indy development board use cartridge domain 1: #define DEVICE_TYPE_BULK 1 /* ROM bulk */ #define DEVICE_TYPE_64DD 2 /* 64 Disk Drive */ #define DEVICE_TYPE_SRAM 3 /* SRAM */ +#define DEVICE_TYPE_INIT 7 /* initial value */ /************************************************************************* * SP Memory diff --git a/include/PR/rdb.h b/include/PR/rdb.h new file mode 100644 index 00000000..ea8c1006 --- /dev/null +++ b/include/PR/rdb.h @@ -0,0 +1,94 @@ + +/************************************************************************** + * + * $Revision: 1.6 $ + * $Date: 1997/02/11 08:29:31 $ + * $Source: /disk6/Master/cvsmdev2/PR/include/rdb.h,v $ + * + **************************************************************************/ + +#ifndef _RDB_H +#define _RDB_H + +/* U64 side address */ +#define RDB_BASE_REG 0xc0000000 +#define RDB_WRITE_INTR_REG (RDB_BASE_REG + 0x8) +#define RDB_READ_INTR_REG (RDB_BASE_REG + 0xc) +#define RDB_BASE_VIRTUAL_ADDR 0x80000000 + +/* packet type Have six bits, so can have up to 63 types */ +#define RDB_TYPE_INVALID 0 +#define RDB_TYPE_GtoH_PRINT 1 +#define RDB_TYPE_GtoH_FAULT 2 +#define RDB_TYPE_GtoH_LOG_CT 3 +#define RDB_TYPE_GtoH_LOG 4 +#define RDB_TYPE_GtoH_READY_FOR_DATA 5 +#define RDB_TYPE_GtoH_DATA_CT 6 +#define RDB_TYPE_GtoH_DATA 7 +#define RDB_TYPE_GtoH_DEBUG 8 +#define RDB_TYPE_GtoH_RAMROM 9 +#define RDB_TYPE_GtoH_DEBUG_DONE 10 +#define RDB_TYPE_GtoH_DEBUG_READY 11 +#define RDB_TYPE_GtoH_KDEBUG 12 +#define RDB_TYPE_GtoH_PROF_DATA 22 + + +#define RDB_TYPE_HtoG_LOG_DONE 13 +#define RDB_TYPE_HtoG_DEBUG 14 +#define RDB_TYPE_HtoG_DEBUG_CT 15 +#define RDB_TYPE_HtoG_DATA 16 +#define RDB_TYPE_HtoG_DATA_DONE 17 +#define RDB_TYPE_HtoG_REQ_RAMROM 18 +#define RDB_TYPE_HtoG_FREE_RAMROM 19 +#define RDB_TYPE_HtoG_KDEBUG 20 +#define RDB_TYPE_HtoG_PROF_SIGNAL 21 + + +#define RDB_PROF_ACK_SIG 1 +#define RDB_PROF_FLUSH_SIG 2 +#define PROF_BLOCK_SIZE 2048 + +#define RDB_LOG_MAX_BLOCK_SIZE 0x8000 +#define RDB_DATA_MAX_BLOCK_SIZE 0x8000 + + +/* GIO side address */ +#define GIO_RDB_BASE_REG 0xbf480000 +#define GIO_RDB_WRITE_INTR_REG (GIO_RDB_BASE_REG + 0x8) +#define GIO_RDB_READ_INTR_REG (GIO_RDB_BASE_REG + 0xc) + +/* minor device number */ +#define GIO_RDB_PRINT_MINOR 1 +#define GIO_RDB_DEBUG_MINOR 2 + +/* interrupt bit */ +#define GIO_RDB_WRITE_INTR_BIT 0x80000000 +#define GIO_RDB_READ_INTR_BIT 0x40000000 + +/* debug command */ +#define DEBUG_COMMAND_NULL 0 +#define DEBUG_COMMAND_MEMORY 1 +#define DEBUG_COMMAND_REGISTER 2 +#define DEBUG_COMMAND_INVALID 255 + +/* debug state */ +#define DEBUG_STATE_NULL 0 +#define DEBUG_STATE_RECEIVE 1 +#define DEBUG_STATE_INVALID 255 + +#if defined(_LANGUAGE_C) || defined(_LANGUAGE_C_PLUS_PLUS) + +/* Structure for debug port */ +typedef struct { + unsigned type : 2; /* 0: invalid, 1: print, 2: debug */ + unsigned pad : 4; // CHANGED FROM THE ORIGINAL LIBULTRA HEADER + unsigned length : 2; /* 1, 2, or 3 */ + unsigned char buf[3]; /* character buffer */ +} rdbPacket; + +extern unsigned int __osRdbWriteOK; +extern unsigned int __osRdbSendMessage; + +#endif /* _LANGUAGE_C */ + +#endif /* !_RDB_H */ diff --git a/include/PR/sptask.h b/include/PR/sptask.h index ec443ef4..46dd0e2c 100644 --- a/include/PR/sptask.h +++ b/include/PR/sptask.h @@ -18,7 +18,7 @@ /* Flags */ #define M_TASK_FLAG0 1 #define M_TASK_FLAG1 2 -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) #define M_TASK_FLAG2 4 #endif diff --git a/include/PR/ultratypes.h b/include/PR/ultratypes.h index 8a00490a..425b7a9e 100644 --- a/include/PR/ultratypes.h +++ b/include/PR/ultratypes.h @@ -1,6 +1,8 @@ #ifndef _ULTRA64_TYPES_H_ #define _ULTRA64_TYPES_H_ +#if defined(_LANGUAGE_C) || defined(_LANGUAGE_C_PLUS_PLUS) + #ifndef NULL #define NULL (void *)0 #endif @@ -42,3 +44,5 @@ typedef ptrdiff_t ssize_t; #endif #endif + +#endif diff --git a/include/behavior_data.h b/include/behavior_data.h index 66c410b7..538ec93b 100644 --- a/include/behavior_data.h +++ b/include/behavior_data.h @@ -3,6 +3,11 @@ #include "types.h" +#define BPARAM1(param) (((param) & 0xFF) << 24) +#define BPARAM2(param) (((param) & 0xFF) << 16) +#define BPARAM3(param) (((param) & 0xFF) << 8) +#define BPARAM4(param) (((param) & 0xFF) << 0) + extern const BehaviorScript bhvStarDoor[]; extern const BehaviorScript bhvMrI[]; extern const BehaviorScript bhvMrIBody[]; @@ -10,8 +15,8 @@ extern const BehaviorScript bhvMrIParticle[]; extern const BehaviorScript bhvPurpleParticle[]; extern const BehaviorScript bhvGiantPole[]; extern const BehaviorScript bhvPoleGrabbing[]; -extern const BehaviorScript bhvThiHugeIslandTop[]; -extern const BehaviorScript bhvThiTinyIslandTop[]; +extern const BehaviorScript bhvTHIHugeIslandTop[]; +extern const BehaviorScript bhvTHITinyIslandTop[]; extern const BehaviorScript bhvCapSwitchBase[]; extern const BehaviorScript bhvCapSwitch[]; extern const BehaviorScript bhvKingBobomb[]; @@ -37,12 +42,12 @@ extern const BehaviorScript bhvUnused05A8[]; extern const BehaviorScript bhvRotatingPlatform[]; extern const BehaviorScript bhvTower[]; extern const BehaviorScript bhvBulletBillCannon[]; -extern const BehaviorScript bhvWfBreakableWallRight[]; -extern const BehaviorScript bhvWfBreakableWallLeft[]; +extern const BehaviorScript bhvWFBreakableWallRight[]; +extern const BehaviorScript bhvWFBreakableWallLeft[]; extern const BehaviorScript bhvKickableBoard[]; extern const BehaviorScript bhvTowerDoor[]; extern const BehaviorScript bhvRotatingCounterClockwise[]; -extern const BehaviorScript bhvWfRotatingWoodenPlatform[]; +extern const BehaviorScript bhvWFRotatingWoodenPlatform[]; extern const BehaviorScript bhvKoopaShellUnderwater[]; extern const BehaviorScript bhvExitPodiumWarp[]; extern const BehaviorScript bhvFadingWarp[]; @@ -51,7 +56,7 @@ extern const BehaviorScript bhvWarpPipe[]; extern const BehaviorScript bhvWhitePuffExplosion[]; extern const BehaviorScript bhvSpawnedStar[]; extern const BehaviorScript bhvSpawnedStarNoLevelExit[]; -extern const BehaviorScript bhvMrIBlueCoin[]; +extern const BehaviorScript bhvSpawnedBlueCoin[]; extern const BehaviorScript bhvCoinInsideBoo[]; extern const BehaviorScript bhvCoinFormationSpawn[]; extern const BehaviorScript bhvCoinFormation[]; @@ -72,16 +77,16 @@ extern const BehaviorScript bhvTriangleParticleSpawner[]; extern const BehaviorScript bhvDoorWarp[]; extern const BehaviorScript bhvDoor[]; extern const BehaviorScript bhvGrindel[]; -extern const BehaviorScript bhvThwomp2[]; extern const BehaviorScript bhvThwomp[]; +extern const BehaviorScript bhvThwomp2[]; extern const BehaviorScript bhvTumblingBridgePlatform[]; -extern const BehaviorScript bhvWfTumblingBridge[]; -extern const BehaviorScript bhvBbhTumblingBridge[]; -extern const BehaviorScript bhvLllTumblingBridge[]; +extern const BehaviorScript bhvTumblingBridge[]; +extern const BehaviorScript bhvBBHTumblingBridge[]; +extern const BehaviorScript bhvLLLTumblingBridge[]; extern const BehaviorScript bhvFlame[]; extern const BehaviorScript bhvAnotherElavator[]; -extern const BehaviorScript bhvRrElevatorPlatform[]; -extern const BehaviorScript bhvHmcElevatorPlatform[]; +extern const BehaviorScript bhvRRElevatorPlatform[]; +extern const BehaviorScript bhvHMCElevatorPlatform[]; extern const BehaviorScript bhvWaterMist[]; extern const BehaviorScript bhvBreathParticleSpawner[]; extern const BehaviorScript bhvBreakBoxTriangle[]; @@ -99,15 +104,15 @@ extern const BehaviorScript bhvUkiki[]; extern const BehaviorScript bhvUkikiCageChild[]; extern const BehaviorScript bhvUkikiCageStar[]; extern const BehaviorScript bhvUkikiCage[]; -extern const BehaviorScript bhvBitfsSinkingPlatforms[]; -extern const BehaviorScript bhvBitfsSinkingCagePlatform[]; -extern const BehaviorScript bhvDddMovingPole[]; -extern const BehaviorScript bhvBitfsTiltingInvertedPyramid[]; +extern const BehaviorScript bhvBitFSSinkingPlatforms[]; +extern const BehaviorScript bhvBitFSSinkingCagePlatform[]; +extern const BehaviorScript bhvDDDMovingPole[]; +extern const BehaviorScript bhvBitFSTiltingInvertedPyramid[]; extern const BehaviorScript bhvSquishablePlatform[]; extern const BehaviorScript bhvCutOutObject[]; extern const BehaviorScript bhvBetaMovingFlamesSpawn[]; extern const BehaviorScript bhvBetaMovingFlames[]; -extern const BehaviorScript bhvRrRotatingBridgePlatform[]; +extern const BehaviorScript bhvRRRotatingBridgePlatform[]; extern const BehaviorScript bhvFlamethrower[]; extern const BehaviorScript bhvFlamethrowerFlame[]; extern const BehaviorScript bhvBouncingFireball[]; @@ -120,9 +125,9 @@ extern const BehaviorScript bhvBlackSmokeUpward[]; extern const BehaviorScript bhvBetaFishSplashSpawner[]; extern const BehaviorScript bhvSpindrift[]; extern const BehaviorScript bhvTowerPlatformGroup[]; -extern const BehaviorScript bhvWfSlidingTowerPlatform[]; -extern const BehaviorScript bhvWfElevatorTowerPlatform[]; -extern const BehaviorScript bhvWfSolidTowerPlatform[]; +extern const BehaviorScript bhvWFSlidingTowerPlatform[]; +extern const BehaviorScript bhvWFElevatorTowerPlatform[]; +extern const BehaviorScript bhvWFSolidTowerPlatform[]; extern const BehaviorScript bhvLeafParticleSpawner[]; extern const BehaviorScript bhvTreeSnow[]; extern const BehaviorScript bhvTreeLeaf[]; @@ -139,7 +144,7 @@ extern const BehaviorScript bhvBreakableBox[]; extern const BehaviorScript bhvPushableMetalBox[]; extern const BehaviorScript bhvHeaveHo[]; extern const BehaviorScript bhvHeaveHoThrowMario[]; -extern const BehaviorScript bhvCcmTouchedStarSpawn[]; +extern const BehaviorScript bhvCCMTouchedStarSpawn[]; extern const BehaviorScript bhvUnusedPoundablePlatform[]; extern const BehaviorScript bhvBetaTrampolineTop[]; extern const BehaviorScript bhvBetaTrampolineSpring[]; @@ -175,34 +180,34 @@ extern const BehaviorScript bhvBowserKeyUnlockDoor[]; extern const BehaviorScript bhvBowserKeyCourseExit[]; extern const BehaviorScript bhvInvisibleObjectsUnderBridge[]; extern const BehaviorScript bhvWaterLevelPillar[]; -extern const BehaviorScript bhvDddWarp[]; +extern const BehaviorScript bhvDDDWarp[]; extern const BehaviorScript bhvMoatGrills[]; extern const BehaviorScript bhvClockMinuteHand[]; extern const BehaviorScript bhvClockHourHand[]; extern const BehaviorScript bhvMacroUkiki[]; extern const BehaviorScript bhvStub1D0C[]; -extern const BehaviorScript bhvLllRotatingHexagonalPlatform[]; -extern const BehaviorScript bhvLllSinkingRockBlock[]; +extern const BehaviorScript bhvLLLRotatingHexagonalPlatform[]; +extern const BehaviorScript bhvLLLSinkingRockBlock[]; extern const BehaviorScript bhvStub1D70[]; -extern const BehaviorScript bhvLllMovingOctagonalMeshPlatform[]; +extern const BehaviorScript bhvLLLMovingOctagonalMeshPlatform[]; extern const BehaviorScript bhvSnowBall[]; -extern const BehaviorScript bhvLllRotatingBlockWithFireBars[]; -extern const BehaviorScript bhvLllRotatingHexFlame[]; -extern const BehaviorScript bhvLllWoodPiece[]; -extern const BehaviorScript bhvLllFloatingWoodBridge[]; +extern const BehaviorScript bhvLLLRotatingBlockWithFireBars[]; +extern const BehaviorScript bhvLLLRotatingHexFlame[]; +extern const BehaviorScript bhvLLLWoodPiece[]; +extern const BehaviorScript bhvLLLFloatingWoodBridge[]; extern const BehaviorScript bhvVolcanoFlames[]; -extern const BehaviorScript bhvLllRotatingHexagonalRing[]; -extern const BehaviorScript bhvLllSinkingRectangularPlatform[]; -extern const BehaviorScript bhvLllSinkingSquarePlatforms[]; -extern const BehaviorScript bhvLllTiltingInvertedPyramid[]; +extern const BehaviorScript bhvLLLRotatingHexagonalRing[]; +extern const BehaviorScript bhvLLLSinkingRectangularPlatform[]; +extern const BehaviorScript bhvLLLSinkingSquarePlatforms[]; +extern const BehaviorScript bhvLLLTiltingInvertedPyramid[]; extern const BehaviorScript bhvUnused1F30[]; extern const BehaviorScript bhvKoopaShell[]; extern const BehaviorScript bhvKoopaShellFlame[]; extern const BehaviorScript bhvToxBox[]; extern const BehaviorScript bhvPiranhaPlant[]; -extern const BehaviorScript bhvLllHexagonalMesh[]; -extern const BehaviorScript bhvLllBowserPuzzlePiece[]; -extern const BehaviorScript bhvLllBowserPuzzle[]; +extern const BehaviorScript bhvLLLHexagonalMesh[]; +extern const BehaviorScript bhvLLLBowserPuzzlePiece[]; +extern const BehaviorScript bhvLLLBowserPuzzle[]; extern const BehaviorScript bhvTuxiesMother[]; extern const BehaviorScript bhvPenguinBaby[]; extern const BehaviorScript bhvUnused20E0[]; @@ -212,8 +217,8 @@ extern const BehaviorScript bhvFewBlueFishSpawner[]; extern const BehaviorScript bhvFishSpawner[]; extern const BehaviorScript bhvFishCommon[]; extern const BehaviorScript bhvFish[]; -extern const BehaviorScript bhvWdwExpressElevator[]; -extern const BehaviorScript bhvWdwExpressElevatorPlatform[]; +extern const BehaviorScript bhvWDWExpressElevator[]; +extern const BehaviorScript bhvWDWExpressElevatorPlatform[]; extern const BehaviorScript bhvChirpChirp[]; extern const BehaviorScript bhvChirpChirpUnused[]; extern const BehaviorScript bhvBub[]; @@ -227,7 +232,7 @@ extern const BehaviorScript bhvBowserSubDoor[]; extern const BehaviorScript bhvBowsersSub[]; extern const BehaviorScript bhvSushiShark[]; extern const BehaviorScript bhvSushiSharkCollisionChild[]; -extern const BehaviorScript bhvJrbSlidingBox[]; +extern const BehaviorScript bhvJRBSlidingBox[]; extern const BehaviorScript bhvShipPart3[]; extern const BehaviorScript bhvInSunkenShip3[]; extern const BehaviorScript bhvSunkenShipPart[]; @@ -262,7 +267,7 @@ extern const BehaviorScript bhvMerryGoRoundBoo[]; extern const BehaviorScript bhvGhostHuntBoo[]; extern const BehaviorScript bhvHiddenStaircaseStep[]; extern const BehaviorScript bhvBooStaircase[]; -extern const BehaviorScript bhvBbhTiltingTrapPlatform[]; +extern const BehaviorScript bhvBBHTiltingTrapPlatform[]; extern const BehaviorScript bhvHauntedBookshelf[]; extern const BehaviorScript bhvMeshElevator[]; extern const BehaviorScript bhvMerryGoRound[]; @@ -371,22 +376,22 @@ extern const BehaviorScript bhvBowserBombSmoke[]; extern const BehaviorScript bhvCelebrationStar[]; extern const BehaviorScript bhvCelebrationStarSparkle[]; extern const BehaviorScript bhvStarKeyCollectionPuffSpawner[]; -extern const BehaviorScript bhvLllDrawbridgeSpawner[]; -extern const BehaviorScript bhvLllDrawbridge[]; +extern const BehaviorScript bhvLLLDrawbridgeSpawner[]; +extern const BehaviorScript bhvLLLDrawbridge[]; extern const BehaviorScript bhvSmallBomp[]; extern const BehaviorScript bhvLargeBomp[]; -extern const BehaviorScript bhvWfSlidingPlatform[]; +extern const BehaviorScript bhvWFSlidingPlatform[]; extern const BehaviorScript bhvMoneybag[]; extern const BehaviorScript bhvMoneybagHidden[]; extern const BehaviorScript bhvPitBowlingBall[]; extern const BehaviorScript bhvFreeBowlingBall[]; extern const BehaviorScript bhvBowlingBall[]; -extern const BehaviorScript bhvTtmBowlingBallSpawner[]; -extern const BehaviorScript bhvBobBowlingBallSpawner[]; -extern const BehaviorScript bhvThiBowlingBallSpawner[]; -extern const BehaviorScript bhvRrCruiserWing[]; +extern const BehaviorScript bhvTTMBowlingBallSpawner[]; +extern const BehaviorScript bhvBoBBowlingBallSpawner[]; +extern const BehaviorScript bhvTHIBowlingBallSpawner[]; +extern const BehaviorScript bhvRRCruiserWing[]; extern const BehaviorScript bhvSpindel[]; -extern const BehaviorScript bhvSslMovingPyramidWall[]; +extern const BehaviorScript bhvSSLMovingPyramidWall[]; extern const BehaviorScript bhvPyramidElevator[]; extern const BehaviorScript bhvPyramidElevatorTrajectoryMarkerBall[]; extern const BehaviorScript bhvPyramidTop[]; @@ -416,38 +421,38 @@ extern const BehaviorScript bhvRedCoin[]; extern const BehaviorScript bhvBowserCourseRedCoinStar[]; extern const BehaviorScript bhvHiddenStar[]; extern const BehaviorScript bhvHiddenStarTrigger[]; -extern const BehaviorScript bhvTtmRollingLog[]; -extern const BehaviorScript bhvLllVolcanoFallingTrap[]; -extern const BehaviorScript bhvLllRollingLog[]; -extern const BehaviorScript bhv1upWalking[]; -extern const BehaviorScript bhv1upRunningAway[]; -extern const BehaviorScript bhv1upSliding[]; +extern const BehaviorScript bhvTTMRollingLog[]; +extern const BehaviorScript bhvLLLVolcanoFallingTrap[]; +extern const BehaviorScript bhvLLLRollingLog[]; +extern const BehaviorScript bhv1UpWalking[]; +extern const BehaviorScript bhv1UpRunningAway[]; +extern const BehaviorScript bhv1UpSliding[]; extern const BehaviorScript bhv1Up[]; -extern const BehaviorScript bhv1upJumpOnApproach[]; -extern const BehaviorScript bhvHidden1up[]; -extern const BehaviorScript bhvHidden1upTrigger[]; -extern const BehaviorScript bhvHidden1upInPole[]; -extern const BehaviorScript bhvHidden1upInPoleTrigger[]; -extern const BehaviorScript bhvHidden1upInPoleSpawner[]; +extern const BehaviorScript bhv1UpJumpOnApproach[]; +extern const BehaviorScript bhvHidden1Up[]; +extern const BehaviorScript bhvHidden1UpTrigger[]; +extern const BehaviorScript bhvHidden1UpInPole[]; +extern const BehaviorScript bhvHidden1UpInPoleTrigger[]; +extern const BehaviorScript bhvHidden1UpInPoleSpawner[]; extern const BehaviorScript bhvControllablePlatform[]; extern const BehaviorScript bhvControllablePlatformSub[]; extern const BehaviorScript bhvBreakableBoxSmall[]; extern const BehaviorScript bhvSlidingSnowMound[]; extern const BehaviorScript bhvSnowMoundSpawn[]; -extern const BehaviorScript bhvWdwSquareFloatingPlatform[]; -extern const BehaviorScript bhvWdwRectangularFloatingPlatform[]; -extern const BehaviorScript bhvJrbFloatingPlatform[]; +extern const BehaviorScript bhvWDWSquareFloatingPlatform[]; +extern const BehaviorScript bhvWDWRectangularFloatingPlatform[]; +extern const BehaviorScript bhvJRBFloatingPlatform[]; extern const BehaviorScript bhvArrowLift[]; extern const BehaviorScript bhvOrangeNumber[]; extern const BehaviorScript bhvMantaRay[]; extern const BehaviorScript bhvFallingPillar[]; extern const BehaviorScript bhvFallingPillarHitbox[]; extern const BehaviorScript bhvPillarBase[]; -extern const BehaviorScript bhvJrbFloatingBox[]; +extern const BehaviorScript bhvJRBFloatingBox[]; extern const BehaviorScript bhvDecorativePendulum[]; extern const BehaviorScript bhvTreasureChestsShip[]; -extern const BehaviorScript bhvTreasureChestsJrb[]; -extern const BehaviorScript bhvTreasureChests[]; +extern const BehaviorScript bhvTreasureChestsJRB[]; +extern const BehaviorScript bhvTreasureChestsDDD[]; extern const BehaviorScript bhvTreasureChestBottom[]; extern const BehaviorScript bhvTreasureChestTop[]; extern const BehaviorScript bhvMips[]; diff --git a/include/config.h b/include/config.h index 044b0694..053b737a 100644 --- a/include/config.h +++ b/include/config.h @@ -10,34 +10,39 @@ // Bug Fixes // --| Post-JP Version Nintendo Bug Fixes /// Fixes bug where obtaining over 999 coins sets the number of lives to 999 (or -25) -#define BUGFIX_MAX_LIVES (0 || VERSION_US || VERSION_EU || VERSION_SH) +#define BUGFIX_MAX_LIVES (0 || VERSION_US || VERSION_EU || VERSION_SH || VERSION_CN) /// Fixes bug where the Boss music won't fade out after defeating King Bob-omb -#define BUGFIX_KING_BOB_OMB_FADE_MUSIC (0 || VERSION_US || VERSION_EU || VERSION_SH) -/// Fixes bug in Bob-Omb Battlefield where entering a warp stops the Koopa race music -#define BUGFIX_KOOPA_RACE_MUSIC (0 || VERSION_US || VERSION_EU || VERSION_SH) +#define BUGFIX_KING_BOB_OMB_FADE_MUSIC (0 || VERSION_US || VERSION_EU || VERSION_SH || VERSION_CN) +/// Fixes bug in Bob-omb Battlefield where entering a warp stops the Koopa race music +#define BUGFIX_KOOPA_RACE_MUSIC (0 || VERSION_US || VERSION_EU || VERSION_SH || VERSION_CN) /// Fixes bug where Piranha Plants do not reset their action state when the /// player exits their activation radius. -#define BUGFIX_PIRANHA_PLANT_STATE_RESET (0 || VERSION_US || VERSION_EU || VERSION_SH) +#define BUGFIX_PIRANHA_PLANT_STATE_RESET (0 || VERSION_US || VERSION_EU || VERSION_SH || VERSION_CN) /// Fixes bug where sleeping Piranha Plants damage players that bump into them -#define BUGFIX_PIRANHA_PLANT_SLEEP_DAMAGE (0 || VERSION_US || VERSION_SH) +#define BUGFIX_PIRANHA_PLANT_SLEEP_DAMAGE (0 || VERSION_US || VERSION_SH || VERSION_CN) /// Fixes bug where it shows a star when you grab a key in bowser battle stages -#define BUGFIX_STAR_BOWSER_KEY (0 || VERSION_US || VERSION_EU || VERSION_SH) +#define BUGFIX_STAR_BOWSER_KEY (0 || VERSION_US || VERSION_EU || VERSION_SH || VERSION_CN) /// Fixes bug that enables Mario in time stop even if is not ready to speak -#define BUGFIX_DIALOG_TIME_STOP (0 || VERSION_US || VERSION_EU || VERSION_SH) +#define BUGFIX_DIALOG_TIME_STOP (0 || VERSION_US || VERSION_EU || VERSION_SH || VERSION_CN) /// Fixes bug that causes Mario to still collide with Bowser in BitS after his defeat -#define BUGFIX_BOWSER_COLLIDE_BITS_DEAD (0 || VERSION_US || VERSION_EU || VERSION_SH) +#define BUGFIX_BOWSER_COLLIDE_BITS_DEAD (0 || VERSION_US || VERSION_EU || VERSION_SH || VERSION_CN) /// Fixes bug where Bowser wouldn't reset his speed when fallen off (and adds missing checks) -#define BUGFIX_BOWSER_FALLEN_OFF_STAGE (0 || VERSION_US || VERSION_EU || VERSION_SH) +#define BUGFIX_BOWSER_FALLEN_OFF_STAGE (0 || VERSION_US || VERSION_EU || VERSION_SH || VERSION_CN) /// Fixes bug where Bowser would look weird while fading out -#define BUGFIX_BOWSER_FADING_OUT (0 || VERSION_US || VERSION_EU || VERSION_SH) +#define BUGFIX_BOWSER_FADING_OUT (0 || VERSION_US || VERSION_EU || VERSION_SH || VERSION_CN) // Support Rumble Pak -#define ENABLE_RUMBLE (0 || VERSION_SH) +#define ENABLE_RUMBLE (0 || VERSION_SH || VERSION_CN) // Screen Size Defines #define SCREEN_WIDTH 320 #define SCREEN_HEIGHT 240 +// Stack Size Defines +#define IDLE_STACKSIZE 0x800 +#define STACKSIZE 0x2000 +#define UNUSED_STACKSIZE 0x1400 + // Border Height Define for NTSC Versions #ifdef TARGET_N64 #ifndef VERSION_EU diff --git a/include/dialog_ids.h b/include/dialog_ids.h index 2d9a2410..10e087ba 100644 --- a/include/dialog_ids.h +++ b/include/dialog_ids.h @@ -1,7 +1,7 @@ #ifndef DIALOG_IDS_H #define DIALOG_IDS_H -enum DialogId { +enum DialogID { DIALOG_NONE = -1, DIALOG_000, DIALOG_001, diff --git a/include/geo_commands.h b/include/geo_commands.h index 432ec1fd..c611619b 100644 --- a/include/geo_commands.h +++ b/include/geo_commands.h @@ -308,7 +308,7 @@ CMD_HH(ty, tz), \ CMD_PTR(displayList) #define GEO_BILLBOARD() \ - GEO_BILLBOARD_WITH_PARAMS(0, 0, 0, 0) + GEO_BILLBOARD_WITH_PARAMS(0, 0, 0, 0) /** * 0x15: Create plain display list scene graph node @@ -357,7 +357,7 @@ CMD_BBH(0x19, 0x00, background), \ CMD_PTR(function) #define GEO_BACKGROUND_COLOR(background) \ - GEO_BACKGROUND(background, NULL) + GEO_BACKGROUND(background, NULL) /** * 0x1A: No operation diff --git a/include/level_commands.h b/include/level_commands.h index f2490fe1..24ab99b4 100644 --- a/include/level_commands.h +++ b/include/level_commands.h @@ -214,19 +214,19 @@ CMD_PTR(unk4), \ CMD_W(unk8) -#define OBJECT_WITH_ACTS(model, posX, posY, posZ, angleX, angleY, angleZ, behParam, beh, acts) \ +#define OBJECT_WITH_ACTS(model, posX, posY, posZ, angleX, angleY, angleZ, bhvParam, bhv, acts) \ CMD_BBBB(0x24, 0x18, acts, model), \ CMD_HHHHHH(posX, posY, posZ, angleX, angleY, angleZ), \ - CMD_W(behParam), \ - CMD_PTR(beh) + CMD_W(bhvParam), \ + CMD_PTR(bhv) -#define OBJECT(model, posX, posY, posZ, angleX, angleY, angleZ, behParam, beh) \ - OBJECT_WITH_ACTS(model, posX, posY, posZ, angleX, angleY, angleZ, behParam, beh, 0x1F) +#define OBJECT(model, posX, posY, posZ, angleX, angleY, angleZ, bhvParam, bhv) \ + OBJECT_WITH_ACTS(model, posX, posY, posZ, angleX, angleY, angleZ, bhvParam, bhv, 0x1F) -#define MARIO(unk3, behArg, beh) \ - CMD_BBBB(0x25, 0x0C, 0x00, unk3), \ - CMD_W(behArg), \ - CMD_PTR(beh) +#define MARIO(model, bhvArg, bhv) \ + CMD_BBBB(0x25, 0x0C, 0x00, model), \ + CMD_W(bhvArg), \ + CMD_PTR(bhv) #define WARP_NODE(id, destLevel, destArea, destNode, flags) \ CMD_BBBB(0x26, 0x08, id, destLevel), \ @@ -268,8 +268,8 @@ CMD_BBH(0x2F, 0x08, 0x0000), \ CMD_PTR(surfaceRooms) -#define SHOW_DIALOG(index, dialogId) \ - CMD_BBBB(0x30, 0x04, index, dialogId) +#define SHOW_DIALOG(index, dialogID) \ + CMD_BBBB(0x30, 0x04, index, dialogID) #define TERRAIN_TYPE(terrainType) \ CMD_BBH(0x31, 0x04, terrainType) diff --git a/include/level_misc_macros.h b/include/level_misc_macros.h index 91ccd784..70b8cb68 100644 --- a/include/level_misc_macros.h +++ b/include/level_misc_macros.h @@ -1,11 +1,11 @@ #ifndef LEVEL_MISC_MACROS_H #define LEVEL_MISC_MACROS_H -#define MACRO_OBJECT_WITH_BEH_PARAM(preset, yaw, posX, posY, posZ, behParam) \ - ((s16)((yaw * 0x10 / 45) << 9) | (preset + 0x1F)), posX, posY, posZ, behParam +#define MACRO_OBJECT_WITH_BHV_PARAM(preset, yaw, posX, posY, posZ, bhvParam) \ + ((s16)((yaw * 0x10 / 45) << 9) | (preset + 0x1F)), posX, posY, posZ, bhvParam #define MACRO_OBJECT(preset, yaw, posX, posY, posZ) \ - MACRO_OBJECT_WITH_BEH_PARAM(preset, yaw, posX, posY, posZ, 0) + MACRO_OBJECT_WITH_BHV_PARAM(preset, yaw, posX, posY, posZ, 0) #define MACRO_OBJECT_END() \ 0x001E diff --git a/include/libc/stdarg.h b/include/libc/stdarg.h index aa7e3393..26906110 100644 --- a/include/libc/stdarg.h +++ b/include/libc/stdarg.h @@ -2,11 +2,256 @@ #define STDARG_H // When not building with IDO, use the builtin vaarg macros for portability. -#ifndef __sgi +#if !defined(__sgi) && (__GNUC__ > 2) #define va_list __builtin_va_list #define va_start __builtin_va_start #define va_arg __builtin_va_arg #define va_end __builtin_va_end + +#elif (__GNUC__ == 2) + +typedef void *__gnuc_va_list; +typedef __gnuc_va_list va_list; + +#ifndef _VA_MIPS_H_ENUM +#define _VA_MIPS_H_ENUM +enum { + __no_type_class = -1, + __void_type_class, + __integer_type_class, + __char_type_class, + __enumeral_type_class, + __boolean_type_class, + __pointer_type_class, + __reference_type_class, + __offset_type_class, + __real_type_class, + __complex_type_class, + __function_type_class, + __method_type_class, + __record_type_class, + __union_type_class, + __array_type_class, + __string_type_class, + __set_type_class, + __file_type_class, + __lang_type_class +}; +#endif + +/* In GCC version 2, we want an ellipsis at the end of the declaration + of the argument list. GCC version 1 can't parse it. */ + +#if __GNUC__ > 1 +#define __va_ellipsis ... +#else +#define __va_ellipsis +#endif + +#ifdef __mips64 +#define __va_rounded_size(__TYPE) \ + (((sizeof (__TYPE) + 8 - 1) / 8) * 8) +#else +#define __va_rounded_size(__TYPE) \ + (((sizeof (__TYPE) + sizeof (int) - 1) / sizeof (int)) * sizeof (int)) +#endif + +#ifdef __mips64 +#define __va_reg_size 8 +#else +#define __va_reg_size 4 +#endif + +/* Get definitions for _MIPS_SIM_ABI64 etc. */ +#ifdef _MIPS_SIM +//#include +#endif + +#ifdef STDARG_H +#if defined (__mips_eabi) +#if ! defined (__mips_soft_float) && ! defined (__mips_single_float) +#ifdef __mips64 +#define va_start(__AP, __LASTARG) \ + (__AP.__gp_regs = ((char *) __builtin_next_arg (__LASTARG) \ + - (__builtin_args_info (2) < 8 \ + ? (8 - __builtin_args_info (2)) * __va_reg_size \ + : 0)), \ + __AP.__fp_left = 8 - __builtin_args_info (3), \ + __AP.__fp_regs = __AP.__gp_regs - __AP.__fp_left * __va_reg_size) +#else /* ! defined (__mips64) */ +#define va_start(__AP, __LASTARG) \ + (__AP.__gp_regs = ((char *) __builtin_next_arg (__LASTARG) \ + - (__builtin_args_info (2) < 8 \ + ? (8 - __builtin_args_info (2)) * __va_reg_size \ + : 0)), \ + __AP.__fp_left = (8 - __builtin_args_info (3)) / 2, \ + __AP.__fp_regs = __AP.__gp_regs - __AP.__fp_left * 8, \ + __AP.__fp_regs = (char *) ((int) __AP.__fp_regs & -8)) +#endif /* ! defined (__mips64) */ +#else /* ! (! defined (__mips_soft_float) && ! defined (__mips_single_float) ) */ +#define va_start(__AP, __LASTARG) \ + (__AP = ((__gnuc_va_list) __builtin_next_arg (__LASTARG) \ + - (__builtin_args_info (2) >= 8 ? 0 \ + : (8 - __builtin_args_info (2)) * __va_reg_size))) +#endif /* ! (! defined (__mips_soft_float) && ! defined (__mips_single_float) ) */ +#else /* ! defined (__mips_eabi) */ +#define va_start(__AP, __LASTARG) \ + (__AP = (__gnuc_va_list) __builtin_next_arg (__LASTARG)) +#endif /* ! (defined (__mips_eabi) && ! defined (__mips_soft_float) && ! defined (__mips_single_float)) */ +#else /* ! _STDARG_H */ +#define va_alist __builtin_va_alist +#ifdef __mips64 +/* This assumes that `long long int' is always a 64 bit type. */ +#define va_dcl long long int __builtin_va_alist; __va_ellipsis +#else +#define va_dcl int __builtin_va_alist; __va_ellipsis +#endif +#if defined (__mips_eabi) +#if ! defined (__mips_soft_float) && ! defined (__mips_single_float) +#ifdef __mips64 +#define va_start(__AP) \ + (__AP.__gp_regs = ((char *) __builtin_next_arg () \ + - (__builtin_args_info (2) < 8 \ + ? (8 - __builtin_args_info (2)) * __va_reg_size \ + : __va_reg_size)), \ + __AP.__fp_left = 8 - __builtin_args_info (3), \ + __AP.__fp_regs = __AP.__gp_regs - __AP.__fp_left * __va_reg_size) +#else /* ! defined (__mips64) */ +#define va_start(__AP) \ + (__AP.__gp_regs = ((char *) __builtin_next_arg () \ + - (__builtin_args_info (2) < 8 \ + ? (8 - __builtin_args_info (2)) * __va_reg_size \ + : __va_reg_size)), \ + __AP.__fp_left = (8 - __builtin_args_info (3)) / 2, \ + __AP.__fp_regs = __AP.__gp_regs - __AP.__fp_left * 8, \ + __AP.__fp_regs = (char *) ((int) __AP.__fp_regs & -8)) +#endif /* ! defined (__mips64) */ +#else /* ! (! defined (__mips_soft_float) && ! defined (__mips_single_float)) */ +#define va_start(__AP) \ + (__AP = ((__gnuc_va_list) __builtin_next_arg () \ + - (__builtin_args_info (2) >= 8 ? __va_reg_size \ + : (8 - __builtin_args_info (2)) * __va_reg_size))) +#endif /* ! (! defined (__mips_soft_float) && ! defined (__mips_single_float)) */ +/* Need alternate code for _MIPS_SIM_ABI64. */ +#elif defined(_MIPS_SIM) && (_MIPS_SIM == _MIPS_SIM_ABI64 || _MIPS_SIM == _MIPS_SIM_NABI32) +#define va_start(__AP) \ + (__AP = (__gnuc_va_list) __builtin_next_arg () \ + + (__builtin_args_info (2) >= 8 ? -8 : 0)) +#else +#define va_start(__AP) __AP = (char *) &__builtin_va_alist +#endif +#endif /* ! _STDARG_H */ + +#ifndef va_end +void va_end (__gnuc_va_list); /* Defined in libgcc.a */ +#endif +#define va_end(__AP) ((void)0) + +#if defined (__mips_eabi) + +#if ! defined (__mips_soft_float) && ! defined (__mips_single_float) +#ifdef __mips64 +#define __va_next_addr(__AP, __type) \ + ((__builtin_classify_type (*(__type *) 0) == __real_type_class \ + && __AP.__fp_left > 0) \ + ? (--__AP.__fp_left, (__AP.__fp_regs += 8) - 8) \ + : (__AP.__gp_regs += __va_reg_size) - __va_reg_size) +#else +#define __va_next_addr(__AP, __type) \ + ((__builtin_classify_type (*(__type *) 0) == __real_type_class \ + && __AP.__fp_left > 0) \ + ? (--__AP.__fp_left, (__AP.__fp_regs += 8) - 8) \ + : (((__builtin_classify_type (* (__type *) 0) < __record_type_class \ + && __alignof__ (__type) > 4) \ + ? __AP.__gp_regs = (char *) (((int) __AP.__gp_regs + 8 - 1) & -8) \ + : (char *) 0), \ + (__builtin_classify_type (* (__type *) 0) >= __record_type_class \ + ? (__AP.__gp_regs += __va_reg_size) - __va_reg_size \ + : ((__AP.__gp_regs += __va_rounded_size (__type)) \ + - __va_rounded_size (__type))))) +#endif +#else /* ! (! defined (__mips_soft_float) && ! defined (__mips_single_float)) */ +#ifdef __mips64 +#define __va_next_addr(__AP, __type) \ + ((__AP += __va_reg_size) - __va_reg_size) +#else +#define __va_next_addr(__AP, __type) \ + (((__builtin_classify_type (* (__type *) 0) < __record_type_class \ + && __alignof__ (__type) > 4) \ + ? __AP = (char *) (((__PTRDIFF_TYPE__) __AP + 8 - 1) & -8) \ + : (char *) 0), \ + (__builtin_classify_type (* (__type *) 0) >= __record_type_class \ + ? (__AP += __va_reg_size) - __va_reg_size \ + : ((__AP += __va_rounded_size (__type)) \ + - __va_rounded_size (__type)))) +#endif +#endif /* ! (! defined (__mips_soft_float) && ! defined (__mips_single_float)) */ + +#ifdef __MIPSEB__ +#define va_arg(__AP, __type) \ + ((__va_rounded_size (__type) <= __va_reg_size) \ + ? *(__type *) (void *) (__va_next_addr (__AP, __type) \ + + __va_reg_size \ + - sizeof (__type)) \ + : (__builtin_classify_type (*(__type *) 0) >= __record_type_class \ + ? **(__type **) (void *) (__va_next_addr (__AP, __type) \ + + __va_reg_size \ + - sizeof (char *)) \ + : *(__type *) (void *) __va_next_addr (__AP, __type))) +#else +#define va_arg(__AP, __type) \ + ((__va_rounded_size (__type) <= __va_reg_size) \ + ? *(__type *) (void *) __va_next_addr (__AP, __type) \ + : (__builtin_classify_type (* (__type *) 0) >= __record_type_class \ + ? **(__type **) (void *) __va_next_addr (__AP, __type) \ + : *(__type *) (void *) __va_next_addr (__AP, __type))) +#endif + +#else /* ! defined (__mips_eabi) */ + +/* We cast to void * and then to TYPE * because this avoids + a warning about increasing the alignment requirement. */ +/* The __mips64 cases are reversed from the 32 bit cases, because the standard + 32 bit calling convention left-aligns all parameters smaller than a word, + whereas the __mips64 calling convention does not (and hence they are + right aligned). */ +#ifdef __mips64 +#ifdef __MIPSEB__ +#define va_arg(__AP, __type) \ + ((__type *) (void *) (__AP = (char *) \ + ((((__PTRDIFF_TYPE__)__AP + 8 - 1) & -8) \ + + __va_rounded_size (__type))))[-1] +#else +#define va_arg(__AP, __type) \ + ((__AP = (char *) ((((__PTRDIFF_TYPE__)__AP + 8 - 1) & -8) \ + + __va_rounded_size (__type))), \ + *(__type *) (void *) (__AP - __va_rounded_size (__type))) +#endif + +#else /* not __mips64 */ + +#ifdef __MIPSEB__ +/* For big-endian machines. */ +#define va_arg(__AP, __type) \ + ((__AP = (char *) ((__alignof__ (__type) > 4 \ + ? ((__PTRDIFF_TYPE__)__AP + 8 - 1) & -8 \ + : ((__PTRDIFF_TYPE__)__AP + 4 - 1) & -4) \ + + __va_rounded_size (__type))), \ + *(__type *) (void *) (__AP - __va_rounded_size (__type))) +#else +/* For little-endian machines. */ +#define va_arg(__AP, __type) \ + ((__type *) (void *) (__AP = (char *) ((__alignof__(__type) > 4 \ + ? ((__PTRDIFF_TYPE__)__AP + 8 - 1) & -8 \ + : ((__PTRDIFF_TYPE__)__AP + 4 - 1) & -4) \ + + __va_rounded_size(__type))))[-1] +#endif +#endif +#endif /* ! defined (__mips_eabi) */ + +/* Copy __gnuc_va_list into another variable of this type. */ +#define __va_copy(dest, src) (dest) = (src) + #else typedef char *va_list; diff --git a/include/macro_preset_names.h b/include/macro_preset_names.h deleted file mode 100644 index 2700a8e8..00000000 --- a/include/macro_preset_names.h +++ /dev/null @@ -1,373 +0,0 @@ -#ifndef MACRO_PRESET_NAMES_H -#define MACRO_PRESET_NAMES_H - -enum MacroPresets { - macro_yellow_coin, - macro_yellow_coin_2, - macro_moving_blue_coin, - macro_sliding_blue_coin, - macro_red_coin, - macro_empty_5, - macro_coin_line_horizontal, - macro_coin_ring_horizontal, - macro_coin_arrow, - macro_coin_line_horizontal_flying, - macro_coin_line_vertical, - macro_coin_ring_horizontal_flying, - macro_coin_ring_vertical, - macro_coin_arrow_flying, - macro_hidden_star_trigger, - macro_empty_15, - macro_empty_16, - macro_empty_17, - macro_empty_18, - macro_empty_19, - macro_fake_star, - macro_wooden_signpost, - macro_cannon_closed, - macro_bobomb_buddy_opens_cannon, - macro_butterfly, - macro_bouncing_fireball_copy, - macro_fish_group_3, - macro_fish_group, - macro_unknown_28, - macro_hidden_1up_in_pole, - macro_huge_goomba, - macro_tiny_goomba, - macro_goomba_triplet_spawner, - macro_goomba_quintuplet_spawner, - macro_sign_on_wall, - macro_chuckya, - macro_cannon_open, - macro_goomba, - macro_homing_amp, - macro_circling_amp, - macro_unknown_40, - macro_unknown_41, - macro_free_bowling_ball, - macro_snufit, - macro_recovery_heart, - macro_1up_sliding, - macro_1up, - macro_1up_jump_on_approach, - macro_hidden_1up, - macro_hidden_1up_trigger, - macro_1up_2, - macro_1up_3, - macro_empty_52, - macro_blue_coin_switch, - macro_hidden_blue_coin, - macro_wing_cap_switch, - macro_metal_cap_switch, - macro_vanish_cap_switch, - macro_yellow_cap_switch, - macro_unknown_59, - macro_box_wing_cap, - macro_box_metal_cap, - macro_box_vanish_cap, - macro_box_koopa_shell, - macro_box_one_coin, - macro_box_three_coins, - macro_box_ten_coins, - macro_box_1up, - macro_box_star_1, - macro_breakable_box_no_coins, - macro_breakable_box_three_coins, - macro_pushable_metal_box, - macro_breakable_box_small, - macro_floor_switch_hidden_objects, - macro_hidden_box, - macro_hidden_object_2, - macro_hidden_object_3, - macro_breakable_box_giant, - macro_koopa_shell_underwater, - macro_box_1up_running_away, - macro_empty_80, - macro_bullet_bill_cannon, - macro_heave_ho, - macro_empty_83, - macro_thwomp, - macro_fire_spitter, - macro_fire_fly_guy, - macro_jumping_box, - macro_butterfly_triplet, - macro_butterfly_triplet_2, - macro_empty_90, - macro_empty_91, - macro_empty_92, - macro_bully, - macro_bully_2, - macro_empty_95, - macro_unknown_96, - macro_bouncing_fireball, - macro_flamethrower, - macro_empty_99, - macro_empty_100, - macro_empty_101, - macro_empty_102, - macro_empty_103, - macro_empty_104, - macro_empty_105, - macro_wooden_post, - macro_water_bomb_spawner, - macro_enemy_lakitu, - macro_bob_koopa_the_quick, - macro_koopa_race_endpoint, - macro_bobomb, - macro_water_bomb_cannon_copy, - macro_bobomb_buddy_opens_cannon_copy, - macro_water_bomb_cannon, - macro_bobomb_still, - macro_empty_116, - macro_empty_117, - macro_empty_118, - macro_empty_119, - macro_empty_120, - macro_empty_121, - macro_empty_122, - macro_unknown_123, - macro_empty_124, - macro_unagi, - macro_sushi, - macro_empty_127, - macro_empty_128, - macro_empty_129, - macro_empty_130, - macro_empty_131, - macro_empty_132, - macro_empty_133, - macro_empty_134, - macro_empty_135, - macro_empty_136, - macro_unknown_137, - macro_tornado, - macro_pokey, - macro_pokey_copy, - macro_tox_box, - macro_empty_142, - macro_empty_143, - macro_empty_144, - macro_empty_145, - macro_empty_146, - macro_empty_147, - macro_empty_148, - macro_empty_149, - macro_empty_150, - macro_monty_mole_2, - macro_monty_mole, - macro_monty_mole_hole, - macro_fly_guy, - macro_empty_155, - macro_wiggler, - macro_empty_157, - macro_empty_158, - macro_empty_159, - macro_empty_160, - macro_empty_161, - macro_empty_162, - macro_empty_163, - macro_empty_164, - macro_spindrift, - macro_mr_blizzard, - macro_mr_blizzard_copy, - macro_empty_168, - macro_small_penguin, - macro_tuxies_mother, - macro_tuxies_mother_copy, - macro_mr_blizzard_2, - macro_empty_173, - macro_empty_174, - macro_empty_175, - macro_empty_176, - macro_empty_177, - macro_empty_178, - macro_empty_179, - macro_empty_180, - macro_empty_181, - macro_empty_182, - macro_empty_183, - macro_empty_184, - macro_empty_185, - macro_empty_186, - macro_empty_187, - macro_empty_188, - macro_haunted_chair_copy, - macro_haunted_chair, - macro_haunted_chair_copy2, - macro_boo, - macro_boo_copy, - macro_boo_group, - macro_boo_with_cage, - macro_beta_key, - macro_empty_197, - macro_empty_198, - macro_empty_199, - macro_empty_200, - macro_empty_201, - macro_empty_202, - macro_empty_203, - macro_empty_204, - macro_empty_205, - macro_empty_206, - macro_empty_207, - macro_empty_208, - macro_empty_209, - macro_empty_210, - macro_empty_211, - macro_empty_212, - macro_empty_213, - macro_empty_214, - macro_empty_215, - macro_empty_216, - macro_empty_217, - macro_empty_218, - macro_empty_219, - macro_empty_220, - macro_empty_221, - macro_empty_222, - macro_empty_223, - macro_empty_224, - macro_empty_225, - macro_empty_226, - macro_empty_227, - macro_empty_228, - macro_empty_229, - macro_empty_230, - macro_empty_231, - macro_empty_232, - macro_empty_233, - macro_chirp_chirp, - macro_seaweed_bundle, - macro_beta_chest, - macro_water_mine, - macro_fish_group_4, - macro_fish_group_2, - macro_jet_stream_ring_spawner, - macro_jet_stream_ring_spawner_copy, - macro_skeeter, - macro_clam_shell, - macro_empty_244, - macro_empty_245, - macro_empty_246, - macro_empty_247, - macro_empty_248, - macro_empty_249, - macro_empty_250, - macro_ukiki, - macro_ukiki_2, - macro_piranha_plant, - macro_empty_254, - macro_whomp, - macro_chain_chomp, - macro_empty_257, - macro_koopa, - macro_koopa_shellless, - macro_wooden_post_copy, - macro_fire_piranha_plant, - macro_fire_piranha_plant_2, - macro_thi_koopa_the_quick, - macro_empty_264, - macro_empty_265, - macro_empty_266, - macro_empty_267, - macro_empty_268, - macro_empty_269, - macro_empty_270, - macro_empty_271, - macro_empty_272, - macro_empty_273, - macro_empty_274, - macro_empty_275, - macro_empty_276, - macro_empty_277, - macro_empty_278, - macro_empty_279, - macro_empty_280, - macro_moneybag, - macro_empty_282, - macro_empty_283, - macro_empty_284, - macro_empty_285, - macro_empty_286, - macro_empty_287, - macro_empty_288, - macro_swoop, - macro_swoop_2, - macro_mr_i, - macro_scuttlebug_spawner, - macro_scuttlebug, - macro_empty_294, - macro_empty_295, - macro_empty_296, - macro_empty_297, - macro_empty_298, - macro_empty_299, - macro_empty_300, - macro_empty_301, - macro_empty_302, - macro_unknown_303, - macro_empty_304, - macro_empty_305, - macro_empty_306, - macro_empty_307, - macro_empty_308, - macro_empty_309, - macro_empty_310, - macro_empty_311, - macro_empty_312, - macro_ttc_rotating_cube, - macro_ttc_rotating_prism, - macro_ttc_pendulum, - macro_ttc_large_treadmill, - macro_ttc_small_treadmill, - macro_ttc_push_block, - macro_ttc_rotating_hexagon, - macro_ttc_rotating_triangle, - macro_ttc_pit_block, - macro_ttc_pit_block_2, - macro_ttc_elevator_platform, - macro_ttc_clock_hand, - macro_ttc_spinner, - macro_ttc_small_gear, - macro_ttc_large_gear, - macro_ttc_large_treadmill_2, - macro_ttc_small_treadmill_2, - macro_empty_330, - macro_empty_331, - macro_empty_332, - macro_empty_333, - macro_empty_334, - macro_empty_335, - macro_empty_336, - macro_empty_337, - macro_empty_338, - macro_box_star_2, - macro_box_star_3, - macro_box_star_4, - macro_box_star_5, - macro_box_star_6, - macro_empty_344, - macro_empty_345, - macro_empty_346, - macro_empty_347, - macro_empty_348, - macro_empty_349, - macro_bits_sliding_platform, - macro_bits_twin_sliding_platforms, - macro_bits_unknown_352, - macro_bits_octagonal_platform, - macro_bits_staircase, - macro_empty_355, - macro_empty_356, - macro_bits_ferris_wheel_axle, - macro_bits_arrow_platform, - macro_bits_seesaw_platform, - macro_bits_tilting_w_platform, - macro_empty_361, - macro_empty_362, - macro_empty_363, - macro_empty_364, - macro_empty_365 -}; - -#endif // MACRO_PRESET_NAMES_H diff --git a/include/macro_presets.h b/include/macro_presets.h index 38b1eb69..c5f6639e 100644 --- a/include/macro_presets.h +++ b/include/macro_presets.h @@ -1,383 +1,375 @@ #ifndef MACRO_PRESETS_H #define MACRO_PRESETS_H -#include "macro_preset_names.h" -#include "behavior_data.h" -#include "model_ids.h" +enum MacroPresets { + macro_yellow_coin_1, + macro_yellow_coin_2, + macro_moving_blue_coin, + macro_sliding_blue_coin, + macro_red_coin, + macro_empty_5, + macro_coin_line_horizontal, + macro_coin_ring_horizontal, + macro_coin_arrow, + macro_coin_line_horizontal_flying, + macro_coin_line_vertical_flying, + macro_coin_ring_horizontal_flying, + macro_coin_ring_vertical_flying, + macro_coin_arrow_flying, + macro_hidden_star_trigger, + macro_empty_15, + macro_empty_16, + macro_empty_17, + macro_empty_18, + macro_empty_19, + macro_fake_star, + macro_wooden_signpost, + macro_cannon_closed, + macro_bobomb_buddy_opens_cannon_1, + macro_butterfly, + macro_bouncing_fireball_1, + macro_fish_spawner_many_blue, + macro_fish_spawner_few_blue, + macro_unknown_28, + macro_hidden_1up_in_pole, + macro_huge_goomba, + macro_tiny_goomba, + macro_goomba_triplet_spawner, + macro_goomba_quintuplet_spawner, + macro_sign_on_wall, + macro_chuckya, + macro_cannon_open, + macro_goomba, + macro_homing_amp, + macro_circling_amp, + macro_unknown_40, + macro_unknown_41, + macro_free_bowling_ball, + macro_snufit, + macro_recovery_heart, + macro_1up_sliding, + macro_1up, + macro_1up_jump_on_approach, + macro_hidden_1up, + macro_hidden_1up_trigger, + macro_1up_beat_bitdw_bowser, + macro_1up_beat_bitfs_bowser, + macro_empty_52, + macro_blue_coin_switch, + macro_hidden_blue_coin, + macro_wing_cap_switch, + macro_metal_cap_switch, + macro_vanish_cap_switch, + macro_yellow_cap_switch, + macro_unknown_59, + macro_box_wing_cap, + macro_box_metal_cap, + macro_box_vanish_cap, + macro_box_koopa_shell, + macro_box_one_coin, + macro_box_three_coins, + macro_box_ten_coins, + macro_box_1up, + macro_box_star_act_1, + macro_breakable_box_no_coins, + macro_breakable_box_three_coins, + macro_pushable_metal_box, + macro_breakable_box_small, + macro_floor_switch_hidden_objects, + macro_hidden_breakable_box, + macro_hidden_unbreakable_box_1, + macro_hidden_unbreakable_box_2, + macro_breakable_box_giant, + macro_koopa_shell_underwater, + macro_box_1up_running_away, + macro_empty_80, + macro_bullet_bill_cannon, + macro_heave_ho, + macro_empty_83, + macro_thwomp, + macro_fire_spitter, + macro_fire_fly_guy, + macro_jumping_box, + macro_butterfly_triplet, + macro_butterfly_triplet_no_bombs, + macro_empty_90, + macro_empty_91, + macro_empty_92, + macro_small_bully, + macro_big_bully, + macro_empty_95, + macro_unknown_96, + macro_bouncing_fireball_2, + macro_flamethrower, + macro_empty_99, + macro_empty_100, + macro_empty_101, + macro_empty_102, + macro_empty_103, + macro_empty_104, + macro_empty_105, + macro_wooden_post_1, + macro_water_bomb_spawner, + macro_enemy_lakitu, + macro_bob_koopa_the_quick, + macro_koopa_race_endpoint, + macro_bobomb, + macro_water_bomb_cannon_1, + macro_bobomb_buddy_opens_cannon_2, + macro_water_bomb_cannon_2, + macro_bobomb_stationary, + macro_empty_116, + macro_empty_117, + macro_empty_118, + macro_empty_119, + macro_empty_120, + macro_empty_121, + macro_empty_122, + macro_unknown_123, + macro_empty_124, + macro_unagi, + macro_sushi, + macro_empty_127, + macro_empty_128, + macro_empty_129, + macro_empty_130, + macro_empty_131, + macro_empty_132, + macro_empty_133, + macro_empty_134, + macro_empty_135, + macro_empty_136, + macro_unknown_137, + macro_tornado, + macro_pokey_1, + macro_pokey_2, + macro_tox_box, + macro_empty_142, + macro_empty_143, + macro_empty_144, + macro_empty_145, + macro_empty_146, + macro_empty_147, + macro_empty_148, + macro_empty_149, + macro_empty_150, + macro_monty_mole_no_rock, + macro_monty_mole, + macro_monty_mole_hole, + macro_fly_guy, + macro_empty_155, + macro_wiggler, + macro_empty_157, + macro_empty_158, + macro_empty_159, + macro_empty_160, + macro_empty_161, + macro_empty_162, + macro_empty_163, + macro_empty_164, + macro_spindrift, + macro_mr_blizzard_1, + macro_mr_blizzard_2, + macro_empty_168, + macro_small_penguin, + macro_tuxies_mother_1, + macro_tuxies_mother_2, + macro_mr_blizzard_jumping, + macro_empty_173, + macro_empty_174, + macro_empty_175, + macro_empty_176, + macro_empty_177, + macro_empty_178, + macro_empty_179, + macro_empty_180, + macro_empty_181, + macro_empty_182, + macro_empty_183, + macro_empty_184, + macro_empty_185, + macro_empty_186, + macro_empty_187, + macro_empty_188, + macro_haunted_chair_1, + macro_haunted_chair_2, + macro_haunted_chair_3, + macro_boo_1, + macro_boo_2, + macro_boo_group, + macro_boo_with_cage, + macro_beta_key, + macro_empty_197, + macro_empty_198, + macro_empty_199, + macro_empty_200, + macro_empty_201, + macro_empty_202, + macro_empty_203, + macro_empty_204, + macro_empty_205, + macro_empty_206, + macro_empty_207, + macro_empty_208, + macro_empty_209, + macro_empty_210, + macro_empty_211, + macro_empty_212, + macro_empty_213, + macro_empty_214, + macro_empty_215, + macro_empty_216, + macro_empty_217, + macro_empty_218, + macro_empty_219, + macro_empty_220, + macro_empty_221, + macro_empty_222, + macro_empty_223, + macro_empty_224, + macro_empty_225, + macro_empty_226, + macro_empty_227, + macro_empty_228, + macro_empty_229, + macro_empty_230, + macro_empty_231, + macro_empty_232, + macro_empty_233, + macro_chirp_chirp, + macro_seaweed_bundle, + macro_beta_chest, + macro_water_mine, + macro_fish_spawner_many_cyan, + macro_fish_spawner_few_cyan, + macro_jet_stream_ring_spawner_1, + macro_jet_stream_ring_spawner_2, + macro_skeeter, + macro_clam_shell, + macro_empty_244, + macro_empty_245, + macro_empty_246, + macro_empty_247, + macro_empty_248, + macro_empty_249, + macro_empty_250, + macro_cage_ukiki, + macro_cap_ukiki, + macro_piranha_plant, + macro_empty_254, + macro_whomp, + macro_chain_chomp, + macro_empty_257, + macro_koopa, + macro_koopa_shellless, + macro_wooden_post_2, + macro_fire_piranha_plant_1, + macro_fire_piranha_plant_2, + macro_koopa_tiny, + macro_empty_264, + macro_empty_265, + macro_empty_266, + macro_empty_267, + macro_empty_268, + macro_empty_269, + macro_empty_270, + macro_empty_271, + macro_empty_272, + macro_empty_273, + macro_empty_274, + macro_empty_275, + macro_empty_276, + macro_empty_277, + macro_empty_278, + macro_empty_279, + macro_empty_280, + macro_moneybag, + macro_empty_282, + macro_empty_283, + macro_empty_284, + macro_empty_285, + macro_empty_286, + macro_empty_287, + macro_empty_288, + macro_swoop_1, + macro_swoop_2, + macro_mr_i, + macro_scuttlebug_spawner, + macro_scuttlebug, + macro_empty_294, + macro_empty_295, + macro_empty_296, + macro_empty_297, + macro_empty_298, + macro_empty_299, + macro_empty_300, + macro_empty_301, + macro_empty_302, + macro_unknown_303, + macro_empty_304, + macro_empty_305, + macro_empty_306, + macro_empty_307, + macro_empty_308, + macro_empty_309, + macro_empty_310, + macro_empty_311, + macro_empty_312, + macro_ttc_rotating_cube, + macro_ttc_rotating_prism, + macro_ttc_pendulum, + macro_ttc_large_treadmill_1, + macro_ttc_small_treadmill_1, + macro_ttc_push_block, + macro_ttc_rotating_hexagon, + macro_ttc_rotating_triangle, + macro_ttc_pit_block_1, + macro_ttc_pit_block_2, + macro_ttc_elevator_platform, + macro_ttc_clock_hand, + macro_ttc_spinner, + macro_ttc_small_gear, + macro_ttc_large_gear, + macro_ttc_large_treadmill_2, + macro_ttc_small_treadmill_2, + macro_empty_330, + macro_empty_331, + macro_empty_332, + macro_empty_333, + macro_empty_334, + macro_empty_335, + macro_empty_336, + macro_empty_337, + macro_empty_338, + macro_box_star_act_2, + macro_box_star_act_3, + macro_box_star_act_4, + macro_box_star_act_5, + macro_box_star_act_6, + macro_empty_344, + macro_empty_345, + macro_empty_346, + macro_empty_347, + macro_empty_348, + macro_empty_349, + macro_bits_sliding_platform, + macro_bits_twin_sliding_platforms, + macro_bits_unknown_352, + macro_bits_octagonal_platform, + macro_bits_staircase, + macro_empty_355, + macro_empty_356, + macro_bits_ferris_wheel_axle, + macro_bits_arrow_platform, + macro_bits_seesaw_platform, + macro_bits_tilting_w_platform, + macro_empty_361, + macro_empty_362, + macro_empty_363, + macro_empty_364, + macro_empty_365, -struct MacroPreset { - /*0x00*/ const BehaviorScript *behavior; - /*0x04*/ s16 model; - /*0x06*/ s16 param; -}; - -struct MacroPreset MacroObjectPresets[] = { - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvOneCoin, MODEL_YELLOW_COIN, 0}, - {bhvMovingBlueCoin, MODEL_BLUE_COIN, 0}, - {bhvBlueCoinSliding, MODEL_BLUE_COIN, 0}, // unused - {bhvRedCoin, MODEL_RED_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvCoinFormation, MODEL_NONE, 0}, - {bhvCoinFormation, MODEL_NONE, COIN_FORMATION_FLAG_RING}, - {bhvCoinFormation, MODEL_NONE, COIN_FORMATION_FLAG_ARROW}, - {bhvCoinFormation, MODEL_NONE, COIN_FORMATION_FLAG_FLYING}, - {bhvCoinFormation, MODEL_NONE, COIN_FORMATION_FLAG_FLYING | COIN_FORMATION_FLAG_VERTICAL}, - {bhvCoinFormation, MODEL_NONE, COIN_FORMATION_FLAG_FLYING | COIN_FORMATION_FLAG_RING}, - {bhvCoinFormation, MODEL_NONE, COIN_FORMATION_FLAG_FLYING | COIN_FORMATION_FLAG_RING | COIN_FORMATION_FLAG_VERTICAL}, - {bhvCoinFormation, MODEL_NONE, COIN_FORMATION_FLAG_FLYING | COIN_FORMATION_FLAG_ARROW}, // unused - {bhvHiddenStarTrigger, MODEL_NONE, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvUnusedFakeStar, MODEL_STAR, 0}, // unused - {bhvMessagePanel, MODEL_WOODEN_SIGNPOST, 0}, - {bhvCannonClosed, MODEL_DL_CANNON_LID, 0}, - {bhvBobombBuddyOpensCannon, MODEL_BOBOMB_BUDDY, 0}, - {bhvButterfly, MODEL_BUTTERFLY, 0}, // unused - {bhvBouncingFireball, MODEL_NONE, 0}, // unused - {bhvFishSpawner, MODEL_NONE, 0}, // unused - {bhvFishSpawner, MODEL_NONE, 1}, - {bhvBetaFishSplashSpawner, MODEL_NONE, 0}, - {bhvHidden1upInPoleSpawner, MODEL_NONE, 0}, - {bhvGoomba, MODEL_GOOMBA, 1}, - {bhvGoomba, MODEL_GOOMBA, 2}, - {bhvGoombaTripletSpawner, MODEL_NONE, 0}, - {bhvGoombaTripletSpawner, MODEL_NONE, 8}, // unused - {bhvSignOnWall, MODEL_NONE, 0}, - {bhvChuckya, MODEL_CHUCKYA, 0}, - {bhvCannon, MODEL_CANNON_BASE, 0}, - {bhvGoomba, MODEL_GOOMBA, 0}, - {bhvHomingAmp, MODEL_AMP, 0}, - {bhvCirclingAmp, MODEL_AMP, 0}, - {bhvCarrySomething1, MODEL_UNKNOWN_7D, 0}, // unused - {bhvBetaTrampolineTop, MODEL_TRAMPOLINE, 0}, // unused - {bhvFreeBowlingBall, MODEL_BOWLING_BALL, 0}, // unused - {bhvSnufit, MODEL_SNUFIT, 0}, - {bhvRecoveryHeart, MODEL_HEART, 0}, - {bhv1upSliding, MODEL_1UP, 0}, - {bhv1Up, MODEL_1UP, 0}, - {bhv1upJumpOnApproach, MODEL_1UP, 0}, // unused - {bhvHidden1up, MODEL_1UP, 0}, - {bhvHidden1upTrigger, MODEL_NONE, 0}, - {bhv1Up, MODEL_1UP, 1}, - {bhv1Up, MODEL_1UP, 2}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvBlueCoinSwitch, MODEL_BLUE_COIN_SWITCH, 0}, - {bhvHiddenBlueCoin, MODEL_BLUE_COIN, 0}, - {bhvCapSwitch, MODEL_CAP_SWITCH, 0}, // unused - {bhvCapSwitch, MODEL_CAP_SWITCH, 1}, // unused - {bhvCapSwitch, MODEL_CAP_SWITCH, 2}, // unused - {bhvCapSwitch, MODEL_CAP_SWITCH, 3}, // unused - {bhvWaterLevelDiamond, MODEL_BREAKABLE_BOX, 0}, // unused - {bhvExclamationBox, MODEL_EXCLAMATION_BOX, 0}, - {bhvExclamationBox, MODEL_EXCLAMATION_BOX, 1}, - {bhvExclamationBox, MODEL_EXCLAMATION_BOX, 2}, - {bhvExclamationBox, MODEL_EXCLAMATION_BOX, 3}, - {bhvExclamationBox, MODEL_EXCLAMATION_BOX, 4}, // unused - {bhvExclamationBox, MODEL_EXCLAMATION_BOX, 5}, - {bhvExclamationBox, MODEL_EXCLAMATION_BOX, 6}, - {bhvExclamationBox, MODEL_EXCLAMATION_BOX, 7}, - {bhvExclamationBox, MODEL_EXCLAMATION_BOX, 8}, - {bhvBreakableBox, MODEL_BREAKABLE_BOX, 0}, - {bhvBreakableBox, MODEL_BREAKABLE_BOX, 1}, - {bhvPushableMetalBox, MODEL_METAL_BOX, 0}, - {bhvBreakableBoxSmall, MODEL_BREAKABLE_BOX_SMALL, 0}, - {bhvFloorSwitchHiddenObjects, MODEL_PURPLE_SWITCH, 0}, - {bhvHiddenObject, MODEL_BREAKABLE_BOX, 0}, - {bhvHiddenObject, MODEL_BREAKABLE_BOX, 1}, // unused - {bhvHiddenObject, MODEL_BREAKABLE_BOX, 2}, // unused - {bhvBreakableBox, MODEL_BREAKABLE_BOX, 3}, - {bhvKoopaShellUnderwater, MODEL_KOOPA_SHELL, 0}, - {bhvExclamationBox, MODEL_EXCLAMATION_BOX, 9}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvBulletBill, MODEL_BULLET_BILL, 0}, // unused - {bhvHeaveHo, MODEL_HEAVE_HO, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvThwomp2, MODEL_THWOMP, 0}, // unused - {bhvFireSpitter, MODEL_BOWLING_BALL, 0}, - {bhvFlyGuy, MODEL_FLYGUY, 1}, - {bhvJumpingBox, MODEL_BREAKABLE_BOX, 0}, - {bhvTripletButterfly, MODEL_BUTTERFLY, 0}, - {bhvTripletButterfly, MODEL_BUTTERFLY, 4}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvSmallBully, MODEL_BULLY, 0}, - {bhvSmallBully, MODEL_BULLY_BOSS, 0}, // unused - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvStub1D0C, MODEL_UNKNOWN_58, 0}, // unused - {bhvBouncingFireball, MODEL_NONE, 0}, - {bhvFlamethrower, MODEL_NONE, 4}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvWoodenPost, MODEL_WOODEN_POST, 0}, - {bhvWaterBombSpawner, MODEL_NONE, 0}, - {bhvEnemyLakitu, MODEL_ENEMY_LAKITU, 0}, - {bhvKoopa, MODEL_KOOPA_WITH_SHELL, 2}, // unused - {bhvKoopaRaceEndpoint, MODEL_NONE, 0}, // unused - {bhvBobomb, MODEL_BLACK_BOBOMB, 0}, - {bhvWaterBombCannon, MODEL_CANNON_BASE, 0}, // unused - {bhvBobombBuddyOpensCannon, MODEL_BOBOMB_BUDDY, 0}, // unused - {bhvWaterBombCannon, MODEL_CANNON_BASE, 0}, - {bhvBobomb, MODEL_BLACK_BOBOMB, 1}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvUnusedFakeStar, MODEL_UNKNOWN_54, 0}, // unused - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvUnagi, MODEL_UNAGI, 0}, // unused - {bhvSushiShark, MODEL_SUSHI, 0}, // unused - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvStaticObject, MODEL_KLEPTO, 0}, // unused - {bhvTweester, MODEL_TWEESTER, 0}, // unused - {bhvPokey, MODEL_NONE, 0}, - {bhvPokey, MODEL_NONE, 0}, // unused - {bhvToxBox, MODEL_SSL_TOX_BOX, 0}, // unused - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvMontyMole, MODEL_MONTY_MOLE, 0}, // unused - {bhvMontyMole, MODEL_MONTY_MOLE, 1}, - {bhvMontyMoleHole, MODEL_DL_MONTY_MOLE_HOLE, 0}, - {bhvFlyGuy, MODEL_FLYGUY, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvWigglerHead, MODEL_WIGGLER_HEAD, 0}, // unused - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvSpindrift, MODEL_SPINDRIFT, 0}, - {bhvMrBlizzard, MODEL_MR_BLIZZARD_HIDDEN, 0}, - {bhvMrBlizzard, MODEL_MR_BLIZZARD_HIDDEN, 0}, // unused - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvSmallPenguin, MODEL_PENGUIN, 0}, // unused - {bhvTuxiesMother, MODEL_PENGUIN, 0}, // unused - {bhvTuxiesMother, MODEL_PENGUIN, 0}, // unused - {bhvMrBlizzard, MODEL_MR_BLIZZARD_HIDDEN, 1}, // unused - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvHauntedChair, MODEL_HAUNTED_CHAIR, 0}, // unused - {bhvHauntedChair, MODEL_HAUNTED_CHAIR, 0}, - {bhvHauntedChair, MODEL_HAUNTED_CHAIR, 0}, // unused - {bhvGhostHuntBoo, MODEL_BOO, 0}, // unused - {bhvGhostHuntBoo, MODEL_BOO, 0}, // unused - {bhvCourtyardBooTriplet, MODEL_BOO, 0}, // unused - {bhvBooWithCage, MODEL_BOO, 0}, // unused - {bhvAlphaBooKey, MODEL_BETA_BOO_KEY, 0}, // unused - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvChirpChirp, MODEL_NONE, 0}, - {bhvSeaweedBundle, MODEL_NONE, 0}, - {bhvBetaChestBottom, MODEL_TREASURE_CHEST_BASE, 0}, // unused - {bhvBowserBomb, MODEL_WATER_MINE, 0}, // unused - {bhvFishSpawner, MODEL_NONE, 2}, // unused - {bhvFishSpawner, MODEL_NONE, 3}, - {bhvJetStreamRingSpawner, MODEL_WATER_RING, 0}, // unused - {bhvJetStreamRingSpawner, MODEL_WATER_RING, 0}, // unused - {bhvSkeeter, MODEL_SKEETER, 0}, - {bhvClamShell, MODEL_CLAM_SHELL, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvMacroUkiki, MODEL_UKIKI, 0}, // unused - {bhvMacroUkiki, MODEL_UKIKI, 1}, // unused - {bhvPiranhaPlant, MODEL_PIRANHA_PLANT, 0}, // unused - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvSmallWhomp, MODEL_WHOMP, 0}, - {bhvChainChomp, MODEL_CHAIN_CHOMP, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvKoopa, MODEL_KOOPA_WITH_SHELL, 1}, - {bhvKoopa, MODEL_KOOPA_WITHOUT_SHELL, 0}, // unused - {bhvWoodenPost, MODEL_WOODEN_POST, 0}, // unused - {bhvFirePiranhaPlant, MODEL_PIRANHA_PLANT, 0}, - {bhvFirePiranhaPlant, MODEL_PIRANHA_PLANT, 1}, // unused - {bhvKoopa, MODEL_KOOPA_WITH_SHELL, 4}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvMoneybagHidden, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvSwoop, MODEL_SWOOP, 0}, - {bhvSwoop, MODEL_SWOOP, 1}, - {bhvMrI, MODEL_NONE, 0}, - {bhvScuttlebugSpawn, MODEL_NONE, 0}, - {bhvScuttlebug, MODEL_SCUTTLEBUG, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_UNKNOWN_54, 0}, // unused - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvTTCRotatingSolid, MODEL_TTC_ROTATING_CUBE, 0}, - {bhvTTCRotatingSolid, MODEL_TTC_ROTATING_PRISM, 1}, - {bhvTTCPendulum, MODEL_TTC_PENDULUM, 0}, - {bhvTTCTreadmill, MODEL_TTC_LARGE_TREADMILL, 0}, - {bhvTTCTreadmill, MODEL_TTC_SMALL_TREADMILL, 1}, - {bhvTTCMovingBar, MODEL_TTC_PUSH_BLOCK, 0}, - {bhvTTCCog, MODEL_TTC_ROTATING_HEXAGON, 0}, - {bhvTTCCog, MODEL_TTC_ROTATING_TRIANGLE, 2}, - {bhvTTCPitBlock, MODEL_TTC_PIT_BLOCK, 0}, - {bhvTTCPitBlock, MODEL_TTC_PIT_BLOCK_UNUSED, 1}, // unused - {bhvTTCElevator, MODEL_TTC_ELEVATOR_PLATFORM, 0}, - {bhvTTC2DRotator, MODEL_TTC_CLOCK_HAND, 0}, - {bhvTTCSpinner, MODEL_TTC_SPINNER, 0}, - {bhvTTC2DRotator, MODEL_TTC_SMALL_GEAR, 1}, - {bhvTTC2DRotator, MODEL_TTC_LARGE_GEAR, 1}, - {bhvTTCTreadmill, MODEL_TTC_LARGE_TREADMILL, 2}, - {bhvTTCTreadmill, MODEL_TTC_SMALL_TREADMILL, 3}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvExclamationBox, MODEL_EXCLAMATION_BOX, 10}, - {bhvExclamationBox, MODEL_EXCLAMATION_BOX, 11}, - {bhvExclamationBox, MODEL_EXCLAMATION_BOX, 12}, - {bhvExclamationBox, MODEL_EXCLAMATION_BOX, 13}, // unused - {bhvExclamationBox, MODEL_EXCLAMATION_BOX, 14}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvSlidingPlatform2, MODEL_BITS_SLIDING_PLATFORM, 0}, // unused - {bhvSlidingPlatform2, MODEL_BITS_TWIN_SLIDING_PLATFORMS, 0}, // unused - {bhvAnotherTiltingPlatform, MODEL_BITDW_SLIDING_PLATFORM, 0}, // unused - {bhvOctagonalPlatformRotating, MODEL_BITS_OCTAGONAL_PLATFORM, 0}, // unused - {bhvAnimatesOnFloorSwitchPress, MODEL_BITS_STAIRCASE, 0}, // unused - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvFerrisWheelAxle, MODEL_BITS_FERRIS_WHEEL_AXLE, 0}, // unused - {bhvActivatedBackAndForthPlatform, MODEL_BITS_ARROW_PLATFORM, 0}, // unused - {bhvSeesawPlatform, MODEL_BITS_SEESAW_PLATFORM, 0}, // unused - {bhvSeesawPlatform, MODEL_BITS_TILTING_W_PLATFORM, 0}, // unused - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0}, - {bhvYellowCoin, MODEL_YELLOW_COIN, 0} + macro_count }; #endif // MACRO_PRESETS_H diff --git a/include/macro_presets.inc.c b/include/macro_presets.inc.c new file mode 100644 index 00000000..53c31b57 --- /dev/null +++ b/include/macro_presets.inc.c @@ -0,0 +1,379 @@ +#include "macro_presets.h" + +struct MacroPreset { + /* 0x00 */ const BehaviorScript *behavior; + /* 0x04 */ s16 model; + /* 0x06 */ s16 param; +}; + +static struct MacroPreset sMacroObjectPresets[] = { + /* macro_yellow_coin_1 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_yellow_coin_2 */ { bhvOneCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_moving_blue_coin */ { bhvMovingBlueCoin, MODEL_BLUE_COIN, 0 }, + /* macro_sliding_blue_coin */ { bhvBlueCoinSliding, MODEL_BLUE_COIN, 0 }, // unused + /* macro_red_coin */ { bhvRedCoin, MODEL_RED_COIN, 0 }, + /* macro_empty_5 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_coin_line_horizontal */ { bhvCoinFormation, MODEL_NONE, COIN_FORMATION_BP_LINE_HORIZONTAL }, + /* macro_coin_ring_horizontal */ { bhvCoinFormation, MODEL_NONE, COIN_FORMATION_BP_RING_HORIZONTAL }, + /* macro_coin_arrow */ { bhvCoinFormation, MODEL_NONE, COIN_FORMATION_BP_ARROW }, + /* macro_coin_line_horizontal_flying */ { bhvCoinFormation, MODEL_NONE, COIN_FORMATION_BP_LINE_HORIZONTAL | COIN_FORMATION_BP_FLAG_FLYING }, + /* macro_coin_line_vertical_flying */ { bhvCoinFormation, MODEL_NONE, COIN_FORMATION_BP_LINE_VERTICAL | COIN_FORMATION_BP_FLAG_FLYING }, + /* macro_coin_ring_horizontal_flying */ { bhvCoinFormation, MODEL_NONE, COIN_FORMATION_BP_RING_HORIZONTAL | COIN_FORMATION_BP_FLAG_FLYING }, + /* macro_coin_ring_vertical_flying */ { bhvCoinFormation, MODEL_NONE, COIN_FORMATION_BP_RING_VERTICAL | COIN_FORMATION_BP_FLAG_FLYING }, + /* macro_coin_arrow_flying */ { bhvCoinFormation, MODEL_NONE, COIN_FORMATION_BP_ARROW | COIN_FORMATION_BP_FLAG_FLYING }, // unused + /* macro_hidden_star_trigger */ { bhvHiddenStarTrigger, MODEL_NONE, 0 }, + /* macro_empty_15 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_16 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_17 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_18 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_19 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_fake_star */ { bhvUnusedFakeStar, MODEL_STAR, 0 }, // unused + /* macro_wooden_signpost */ { bhvMessagePanel, MODEL_WOODEN_SIGNPOST, 0 }, + /* macro_cannon_closed */ { bhvCannonClosed, MODEL_DL_CANNON_LID, 0 }, + /* macro_bobomb_buddy_opens_cannon_1 */ { bhvBobombBuddyOpensCannon, MODEL_BOBOMB_BUDDY, 0 }, + /* macro_butterfly */ { bhvButterfly, MODEL_BUTTERFLY, 0 }, // unused + /* macro_bouncing_fireball_1 */ { bhvBouncingFireball, MODEL_NONE, 0 }, // unused + /* macro_fish_spawner_many_blue */ { bhvFishSpawner, MODEL_NONE, FISH_SPAWNER_BP_MANY_BLUE }, // unused + /* macro_fish_spawner_few_blue */ { bhvFishSpawner, MODEL_NONE, FISH_SPAWNER_BP_FEW_BLUE }, + /* macro_unknown_28 */ { bhvBetaFishSplashSpawner, MODEL_NONE, 0 }, + /* macro_hidden_1up_in_pole */ { bhvHidden1UpInPoleSpawner, MODEL_NONE, 0 }, + /* macro_huge_goomba */ { bhvGoomba, MODEL_GOOMBA, GOOMBA_SIZE_HUGE }, + /* macro_tiny_goomba */ { bhvGoomba, MODEL_GOOMBA, GOOMBA_SIZE_TINY }, + /* macro_goomba_triplet_spawner */ { bhvGoombaTripletSpawner, MODEL_NONE, GOOMBA_TRIPLET_SPAWNER_BP_EXTRA_GOOMBAS(0) | GOOMBA_SIZE_REGULAR }, + /* macro_goomba_quintuplet_spawner */ { bhvGoombaTripletSpawner, MODEL_NONE, GOOMBA_TRIPLET_SPAWNER_BP_EXTRA_GOOMBAS(2) | GOOMBA_SIZE_REGULAR }, // unused + /* macro_sign_on_wall */ { bhvSignOnWall, MODEL_NONE, 0 }, + /* macro_chuckya */ { bhvChuckya, MODEL_CHUCKYA, 0 }, + /* macro_cannon_open */ { bhvCannon, MODEL_CANNON_BASE, 0 }, + /* macro_goomba */ { bhvGoomba, MODEL_GOOMBA, 0 }, + /* macro_homing_amp */ { bhvHomingAmp, MODEL_AMP, 0 }, + /* macro_circling_amp */ { bhvCirclingAmp, MODEL_AMP, AMP_BP_ROT_RADIUS_200 }, + /* macro_unknown_40 */ { bhvCarrySomething1, MODEL_UNKNOWN_7D, 0 }, // unused + /* macro_unknown_41 */ { bhvBetaTrampolineTop, MODEL_TRAMPOLINE, 0 }, // unused + /* macro_free_bowling_ball */ { bhvFreeBowlingBall, MODEL_BOWLING_BALL, 0 }, // unused + /* macro_snufit */ { bhvSnufit, MODEL_SNUFIT, 0 }, + /* macro_recovery_heart */ { bhvRecoveryHeart, MODEL_HEART, 0 }, + /* macro_1up_sliding */ { bhv1UpSliding, MODEL_1UP, 0 }, + /* macro_1up */ { bhv1Up, MODEL_1UP, 0 }, + /* macro_1up_jump_on_approach */ { bhv1UpJumpOnApproach, MODEL_1UP, 0 }, // unused + /* macro_hidden_1up */ { bhvHidden1Up, MODEL_1UP, 0 }, + /* macro_hidden_1up_trigger */ { bhvHidden1UpTrigger, MODEL_NONE, 0 }, + /* macro_1up_beat_bitdw_bowser */ { bhv1Up, MODEL_1UP, ONE_UP_BP_BEAT_BITDW_BOWSER }, + /* macro_1up_beat_bitfs_bowser */ { bhv1Up, MODEL_1UP, ONE_UP_BP_BEAT_BITFS_BOWSER }, + /* macro_empty_52 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_blue_coin_switch */ { bhvBlueCoinSwitch, MODEL_BLUE_COIN_SWITCH, 0 }, + /* macro_hidden_blue_coin */ { bhvHiddenBlueCoin, MODEL_BLUE_COIN, 0 }, + /* macro_wing_cap_switch */ { bhvCapSwitch, MODEL_CAP_SWITCH, CAP_SWITCH_BP_RED }, // unused + /* macro_metal_cap_switch */ { bhvCapSwitch, MODEL_CAP_SWITCH, CAP_SWITCH_BP_GREEN }, // unused + /* macro_vanish_cap_switch */ { bhvCapSwitch, MODEL_CAP_SWITCH, CAP_SWITCH_BP_BLUE }, // unused + /* macro_yellow_cap_switch */ { bhvCapSwitch, MODEL_CAP_SWITCH, CAP_SWITCH_BP_YELLOW }, // unused + /* macro_unknown_59 */ { bhvWaterLevelDiamond, MODEL_BREAKABLE_BOX, 0 }, // unused + /* macro_box_wing_cap */ { bhvExclamationBox, MODEL_EXCLAMATION_BOX, EXCLAMATION_BOX_BP_WING_CAP }, + /* macro_box_metal_cap */ { bhvExclamationBox, MODEL_EXCLAMATION_BOX, EXCLAMATION_BOX_BP_METAL_CAP }, + /* macro_box_vanish_cap */ { bhvExclamationBox, MODEL_EXCLAMATION_BOX, EXCLAMATION_BOX_BP_VANISH_CAP }, + /* macro_box_koopa_shell */ { bhvExclamationBox, MODEL_EXCLAMATION_BOX, EXCLAMATION_BOX_BP_KOOPA_SHELL }, + /* macro_box_one_coin */ { bhvExclamationBox, MODEL_EXCLAMATION_BOX, EXCLAMATION_BOX_BP_ONE_COIN }, // unused + /* macro_box_three_coins */ { bhvExclamationBox, MODEL_EXCLAMATION_BOX, EXCLAMATION_BOX_BP_THREE_COINS }, + /* macro_box_ten_coins */ { bhvExclamationBox, MODEL_EXCLAMATION_BOX, EXCLAMATION_BOX_BP_TEN_COINS }, + /* macro_box_1up */ { bhvExclamationBox, MODEL_EXCLAMATION_BOX, EXCLAMATION_BOX_BP_1UP_WALKING }, + /* macro_box_star_act_1 */ { bhvExclamationBox, MODEL_EXCLAMATION_BOX, EXCLAMATION_BOX_BP_STAR_ACT_1 }, + /* macro_breakable_box_no_coins */ { bhvBreakableBox, MODEL_BREAKABLE_BOX, BREAKABLE_BOX_BP_NO_COINS }, + /* macro_breakable_box_three_coins */ { bhvBreakableBox, MODEL_BREAKABLE_BOX, BREAKABLE_BOX_BP_3_COINS }, + /* macro_pushable_metal_box */ { bhvPushableMetalBox, MODEL_METAL_BOX, 0 }, + /* macro_breakable_box_small */ { bhvBreakableBoxSmall, MODEL_BREAKABLE_BOX_SMALL, 0 }, + /* macro_floor_switch_hidden_objects */ { bhvFloorSwitchHiddenObjects, MODEL_PURPLE_SWITCH, 0 }, + /* macro_hidden_breakable_box */ { bhvHiddenObject, MODEL_BREAKABLE_BOX, HIDDEN_OBJECT_BP_BREAKABLE_BOX }, + /* macro_hidden_unbreakable_box_1 */ { bhvHiddenObject, MODEL_BREAKABLE_BOX, HIDDEN_OBJECT_BP_UNBREAKABLE_BOX_UNUSED_1 }, // unused + /* macro_hidden_unbreakable_box_2 */ { bhvHiddenObject, MODEL_BREAKABLE_BOX, HIDDEN_OBJECT_BP_UNBREAKABLE_BOX_UNUSED_2 }, // unused + /* macro_breakable_box_giant */ { bhvBreakableBox, MODEL_BREAKABLE_BOX, BREAKABLE_BOX_BP_GIANT }, + /* macro_koopa_shell_underwater */ { bhvKoopaShellUnderwater, MODEL_KOOPA_SHELL, 0 }, + /* macro_box_1up_running_away */ { bhvExclamationBox, MODEL_EXCLAMATION_BOX, EXCLAMATION_BOX_BP_1UP_RUNNING_AWAY }, + /* macro_empty_80 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_bullet_bill_cannon */ { bhvBulletBill, MODEL_BULLET_BILL, 0 }, // unused + /* macro_heave_ho */ { bhvHeaveHo, MODEL_HEAVE_HO, 0 }, + /* macro_empty_83 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_thwomp */ { bhvThwomp, MODEL_THWOMP, 0 }, // unused + /* macro_fire_spitter */ { bhvFireSpitter, MODEL_BOWLING_BALL, 0 }, + /* macro_fire_fly_guy */ { bhvFlyGuy, MODEL_FLYGUY, FLY_GUY_BP_FIRE }, + /* macro_jumping_box */ { bhvJumpingBox, MODEL_BREAKABLE_BOX, 0 }, + /* macro_butterfly_triplet */ { bhvTripletButterfly, MODEL_BUTTERFLY, 0 }, + /* macro_butterfly_triplet_no_bombs */ { bhvTripletButterfly, MODEL_BUTTERFLY, TRIPLET_BUTTERFLY_BP_NO_BOMBS }, + /* macro_empty_90 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_91 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_92 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_small_bully */ { bhvSmallBully, MODEL_BULLY, 0 }, + /* macro_big_bully */ { bhvSmallBully, MODEL_BULLY_BOSS, 0 }, // unused + /* macro_empty_95 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_unknown_96 */ { bhvStub1D0C, MODEL_UNKNOWN_58, 0 }, // unused + /* macro_bouncing_fireball_2 */ { bhvBouncingFireball, MODEL_NONE, 0 }, + /* macro_flamethrower */ { bhvFlamethrower, MODEL_NONE, 4 }, + /* macro_empty_99 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_100 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_101 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_102 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_103 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_104 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_105 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_wooden_post_1 */ { bhvWoodenPost, MODEL_WOODEN_POST, 0 }, + /* macro_water_bomb_spawner */ { bhvWaterBombSpawner, MODEL_NONE, 0 }, + /* macro_enemy_lakitu */ { bhvEnemyLakitu, MODEL_ENEMY_LAKITU, 0 }, + /* macro_bob_koopa_the_quick */ { bhvKoopa, MODEL_KOOPA_WITH_SHELL, KOOPA_BP_KOOPA_THE_QUICK_BOB }, // unused + /* macro_koopa_race_endpoint */ { bhvKoopaRaceEndpoint, MODEL_NONE, 0 }, // unused + /* macro_bobomb */ { bhvBobomb, MODEL_BLACK_BOBOMB, BOBOMB_BP_STYPE_GENERIC }, + /* macro_water_bomb_cannon_1 */ { bhvWaterBombCannon, MODEL_CANNON_BASE, 0 }, // unused + /* macro_bobomb_buddy_opens_cannon_2 */ { bhvBobombBuddyOpensCannon, MODEL_BOBOMB_BUDDY, 0 }, // unused + /* macro_water_bomb_cannon_2 */ { bhvWaterBombCannon, MODEL_CANNON_BASE, 0 }, + /* macro_bobomb_stationary */ { bhvBobomb, MODEL_BLACK_BOBOMB, BOBOMB_BP_STYPE_STATIONARY }, + /* macro_empty_116 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_117 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_118 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_119 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_120 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_121 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_122 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_unknown_123 */ { bhvUnusedFakeStar, MODEL_UNKNOWN_54, 0 }, // unused + /* macro_empty_124 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_unagi */ { bhvUnagi, MODEL_UNAGI, 0 }, // unused + /* macro_sushi */ { bhvSushiShark, MODEL_SUSHI, 0 }, // unused + /* macro_empty_127 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_128 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_129 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_130 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_131 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_132 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_133 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_134 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_135 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_136 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_unknown_137 */ { bhvStaticObject, MODEL_KLEPTO, 0 }, // unused + /* macro_tornado */ { bhvTweester, MODEL_TWEESTER, 0 }, // unused + /* macro_pokey_1 */ { bhvPokey, MODEL_NONE, 0 }, + /* macro_pokey_2 */ { bhvPokey, MODEL_NONE, 0 }, // unused + /* macro_tox_box */ { bhvToxBox, MODEL_SSL_TOX_BOX, TOX_BOX_BP_MOVEMENT_PATTERN_1 }, // unused + /* macro_empty_142 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_143 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_144 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_145 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_146 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_147 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_148 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_149 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_150 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_monty_mole_no_rock */ { bhvMontyMole, MODEL_MONTY_MOLE, MONTY_MOLE_BP_NO_ROCK }, // unused + /* macro_monty_mole */ { bhvMontyMole, MODEL_MONTY_MOLE, MONTY_MOLE_BP_GENERIC }, + /* macro_monty_mole_hole */ { bhvMontyMoleHole, MODEL_DL_MONTY_MOLE_HOLE, 0 }, + /* macro_fly_guy */ { bhvFlyGuy, MODEL_FLYGUY, FLY_GUY_BP_GENERIC }, + /* macro_empty_155 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_wiggler */ { bhvWigglerHead, MODEL_WIGGLER_HEAD, 0 }, // unused + /* macro_empty_157 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_158 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_159 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_160 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_161 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_162 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_163 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_164 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_spindrift */ { bhvSpindrift, MODEL_SPINDRIFT, 0 }, + /* macro_mr_blizzard_1 */ { bhvMrBlizzard, MODEL_MR_BLIZZARD_HIDDEN, MR_BLIZZARD_STYPE_GENERIC }, + /* macro_mr_blizzard_2 */ { bhvMrBlizzard, MODEL_MR_BLIZZARD_HIDDEN, MR_BLIZZARD_STYPE_GENERIC }, // unused + /* macro_empty_168 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_small_penguin */ { bhvSmallPenguin, MODEL_PENGUIN, 0 }, // unused + /* macro_tuxies_mother_1 */ { bhvTuxiesMother, MODEL_PENGUIN, 0 }, // unused + /* macro_tuxies_mother_2 */ { bhvTuxiesMother, MODEL_PENGUIN, 0 }, // unused + /* macro_mr_blizzard_jumping */ { bhvMrBlizzard, MODEL_MR_BLIZZARD_HIDDEN, MR_BLIZZARD_STYPE_JUMPING }, // unused + /* macro_empty_173 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_174 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_175 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_176 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_177 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_178 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_179 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_180 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_181 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_182 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_183 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_184 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_185 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_186 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_187 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_188 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_haunted_chair_1 */ { bhvHauntedChair, MODEL_HAUNTED_CHAIR, 0 }, // unused + /* macro_haunted_chair_2 */ { bhvHauntedChair, MODEL_HAUNTED_CHAIR, 0 }, + /* macro_haunted_chair_3 */ { bhvHauntedChair, MODEL_HAUNTED_CHAIR, 0 }, // unused + /* macro_boo_1 */ { bhvGhostHuntBoo, MODEL_BOO, BOO_BP_GHOST_HUNT }, // unused + /* macro_boo_2 */ { bhvGhostHuntBoo, MODEL_BOO, BOO_BP_GHOST_HUNT }, // unused + /* macro_boo_group */ { bhvCourtyardBooTriplet, MODEL_BOO, 0 }, // unused + /* macro_boo_with_cage */ { bhvBooWithCage, MODEL_BOO, 0 }, // unused + /* macro_beta_key */ { bhvAlphaBooKey, MODEL_BETA_BOO_KEY, 0 }, // unused + /* macro_empty_197 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_198 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_199 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_200 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_201 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_202 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_203 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_204 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_205 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_206 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_207 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_208 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_209 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_210 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_211 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_212 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_213 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_214 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_215 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_216 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_217 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_218 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_219 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_220 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_221 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_222 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_223 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_224 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_225 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_226 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_227 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_228 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_229 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_230 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_231 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_232 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_233 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_chirp_chirp */ { bhvChirpChirp, MODEL_NONE, 0 }, + /* macro_seaweed_bundle */ { bhvSeaweedBundle, MODEL_NONE, 0 }, + /* macro_beta_chest */ { bhvBetaChestBottom, MODEL_TREASURE_CHEST_BASE, 0 }, // unused + /* macro_water_mine */ { bhvBowserBomb, MODEL_WATER_MINE, 0 }, // unused + /* macro_fish_spawner_many_cyan */ { bhvFishSpawner, MODEL_NONE, FISH_SPAWNER_BP_MANY_CYAN }, // unused + /* macro_fish_spawner_few_cyan */ { bhvFishSpawner, MODEL_NONE, FISH_SPAWNER_BP_FEW_CYAN }, + /* macro_jet_stream_ring_spawner_1 */ { bhvJetStreamRingSpawner, MODEL_WATER_RING, 0 }, // unused + /* macro_jet_stream_ring_spawner_2 */ { bhvJetStreamRingSpawner, MODEL_WATER_RING, 0 }, // unused + /* macro_skeeter */ { bhvSkeeter, MODEL_SKEETER, 0 }, + /* macro_clam_shell */ { bhvClamShell, MODEL_CLAM_SHELL, 0 }, + /* macro_empty_244 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_245 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_246 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_247 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_248 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_249 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_250 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_cage_ukiki */ { bhvMacroUkiki, MODEL_UKIKI, UKIKI_BP_CAGE }, // unused + /* macro_cap_ukiki */ { bhvMacroUkiki, MODEL_UKIKI, UKIKI_BP_CAP }, // unused + /* macro_piranha_plant */ { bhvPiranhaPlant, MODEL_PIRANHA_PLANT, 0 }, // unused + /* macro_empty_254 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_whomp */ { bhvSmallWhomp, MODEL_WHOMP, 0 }, + /* macro_chain_chomp */ { bhvChainChomp, MODEL_CHAIN_CHOMP, 0 }, + /* macro_empty_257 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_koopa */ { bhvKoopa, MODEL_KOOPA_WITH_SHELL, KOOPA_BP_NORMAL }, + /* macro_koopa_shellless */ { bhvKoopa, MODEL_KOOPA_WITHOUT_SHELL, KOOPA_BP_UNSHELLED }, // unused + /* macro_wooden_post_2 */ { bhvWoodenPost, MODEL_WOODEN_POST, 0 }, // unused + /* macro_fire_piranha_plant_1 */ { bhvFirePiranhaPlant, MODEL_PIRANHA_PLANT, 0 }, + /* macro_fire_piranha_plant_2 */ { bhvFirePiranhaPlant, MODEL_PIRANHA_PLANT, 1 }, // unused + /* macro_koopa_tiny */ { bhvKoopa, MODEL_KOOPA_WITH_SHELL, KOOPA_BP_TINY }, + /* macro_empty_264 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_265 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_266 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_267 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_268 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_269 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_270 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_271 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_272 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_273 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_274 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_275 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_276 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_277 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_278 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_279 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_280 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_moneybag */ { bhvMoneybagHidden, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_282 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_283 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_284 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_285 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_286 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_287 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_288 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_swoop_1 */ { bhvSwoop, MODEL_SWOOP, 0 }, + /* macro_swoop_2 */ { bhvSwoop, MODEL_SWOOP, 1 }, + /* macro_mr_i */ { bhvMrI, MODEL_NONE, 0 }, + /* macro_scuttlebug_spawner */ { bhvScuttlebugSpawn, MODEL_NONE, 0 }, + /* macro_scuttlebug */ { bhvScuttlebug, MODEL_SCUTTLEBUG, 0 }, + /* macro_empty_294 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_295 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_296 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_297 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_298 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_299 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_300 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_301 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_302 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_unknown_303 */ { bhvYellowCoin, MODEL_UNKNOWN_54, 0 }, // unused + /* macro_empty_304 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_305 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_306 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_307 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_308 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_309 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_310 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_311 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_312 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_ttc_rotating_cube */ { bhvTTCRotatingSolid, MODEL_TTC_ROTATING_CUBE, TTC_ROTATING_SOLID_BP_CUBE }, + /* macro_ttc_rotating_prism */ { bhvTTCRotatingSolid, MODEL_TTC_ROTATING_PRISM, TTC_ROTATING_SOLID_BP_TRIANGULAR_PRISM }, + /* macro_ttc_pendulum */ { bhvTTCPendulum, MODEL_TTC_PENDULUM, 0 }, + /* macro_ttc_large_treadmill_1 */ { bhvTTCTreadmill, MODEL_TTC_LARGE_TREADMILL, TTC_TREADMILL_BP_LARGE_1 }, + /* macro_ttc_small_treadmill_1 */ { bhvTTCTreadmill, MODEL_TTC_SMALL_TREADMILL, TTC_TREADMILL_BP_SMALL_1 }, + /* macro_ttc_push_block */ { bhvTTCMovingBar, MODEL_TTC_PUSH_BLOCK, 0 }, + /* macro_ttc_rotating_hexagon */ { bhvTTCCog, MODEL_TTC_ROTATING_HEXAGON, TTC_COG_BP_SHAPE_HEXAGON | TTC_COG_BP_DIR_CCW }, + /* macro_ttc_rotating_triangle */ { bhvTTCCog, MODEL_TTC_ROTATING_TRIANGLE, TTC_COG_BP_SHAPE_TRIANGLE | TTC_COG_BP_DIR_CCW }, + /* macro_ttc_pit_block_1 */ { bhvTTCPitBlock, MODEL_TTC_PIT_BLOCK, 0 }, + /* macro_ttc_pit_block_2 */ { bhvTTCPitBlock, MODEL_TTC_PIT_BLOCK_UNUSED, 1 }, // unused + /* macro_ttc_elevator_platform */ { bhvTTCElevator, MODEL_TTC_ELEVATOR_PLATFORM, 0 }, + /* macro_ttc_clock_hand */ { bhvTTC2DRotator, MODEL_TTC_CLOCK_HAND, 0 }, + /* macro_ttc_spinner */ { bhvTTCSpinner, MODEL_TTC_SPINNER, 0 }, + /* macro_ttc_small_gear */ { bhvTTC2DRotator, MODEL_TTC_SMALL_GEAR, 1 }, + /* macro_ttc_large_gear */ { bhvTTC2DRotator, MODEL_TTC_LARGE_GEAR, 1 }, + /* macro_ttc_large_treadmill_2 */ { bhvTTCTreadmill, MODEL_TTC_LARGE_TREADMILL, TTC_TREADMILL_BP_LARGE_2 }, + /* macro_ttc_small_treadmill_2 */ { bhvTTCTreadmill, MODEL_TTC_SMALL_TREADMILL, TTC_TREADMILL_BP_SMALL_2 }, + /* macro_empty_330 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_331 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_332 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_333 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_334 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_335 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_336 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_337 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_338 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_box_star_act_2 */ { bhvExclamationBox, MODEL_EXCLAMATION_BOX, EXCLAMATION_BOX_BP_STAR_ACT_2 }, + /* macro_box_star_act_3 */ { bhvExclamationBox, MODEL_EXCLAMATION_BOX, EXCLAMATION_BOX_BP_STAR_ACT_3 }, + /* macro_box_star_act_4 */ { bhvExclamationBox, MODEL_EXCLAMATION_BOX, EXCLAMATION_BOX_BP_STAR_ACT_4 }, + /* macro_box_star_act_5 */ { bhvExclamationBox, MODEL_EXCLAMATION_BOX, EXCLAMATION_BOX_BP_STAR_ACT_5 }, // unused + /* macro_box_star_act_6 */ { bhvExclamationBox, MODEL_EXCLAMATION_BOX, EXCLAMATION_BOX_BP_STAR_ACT_6 }, + /* macro_empty_344 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_345 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_346 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_347 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_348 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_349 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_bits_sliding_platform */ { bhvSlidingPlatform2, MODEL_BITS_SLIDING_PLATFORM, 0 }, // unused + /* macro_bits_twin_sliding_platforms */ { bhvSlidingPlatform2, MODEL_BITS_TWIN_SLIDING_PLATFORMS, 0 }, // unused + /* macro_bits_unknown_352 */ { bhvAnotherTiltingPlatform, MODEL_BITDW_SLIDING_PLATFORM, 0 }, // unused + /* macro_bits_octagonal_platform */ { bhvOctagonalPlatformRotating, MODEL_BITS_OCTAGONAL_PLATFORM, 0 }, // unused + /* macro_bits_staircase */ { bhvAnimatesOnFloorSwitchPress, MODEL_BITS_STAIRCASE, 0 }, // unused + /* macro_empty_355 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_356 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_bits_ferris_wheel_axle */ { bhvFerrisWheelAxle, MODEL_BITS_FERRIS_WHEEL_AXLE, 0 }, // unused + /* macro_bits_arrow_platform */ { bhvActivatedBackAndForthPlatform, MODEL_BITS_ARROW_PLATFORM, 0 }, // unused + /* macro_bits_seesaw_platform */ { bhvSeesawPlatform, MODEL_BITS_SEESAW_PLATFORM, 0 }, // unused + /* macro_bits_tilting_w_platform */ { bhvSeesawPlatform, MODEL_BITS_TILTING_W_PLATFORM, 0 }, // unused + /* macro_empty_361 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_362 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_363 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_364 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, + /* macro_empty_365 */ { bhvYellowCoin, MODEL_YELLOW_COIN, 0 }, +}; + +STATIC_ASSERT(ARRAY_COUNT(sMacroObjectPresets) == macro_count, + "change this array if you are adding macro objects"); diff --git a/include/macros.h b/include/macros.h index 3c171faf..57d59218 100644 --- a/include/macros.h +++ b/include/macros.h @@ -25,6 +25,12 @@ #define UNUSED #endif +#ifdef VERSION_CN +#define UNUSED_CN UNUSED +#else +#define UNUSED_CN +#endif + // Avoid undefined behaviour for non-returning functions #ifdef __GNUC__ #define NORETURN __attribute__((noreturn)) @@ -69,4 +75,17 @@ #define VIRTUAL_TO_PHYSICAL2(addr) ((void *)(addr)) #endif +// Stubbed CN debug prints +#ifdef VERSION_CN +#define CN_DEBUG_PRINTF(args) osSyncPrintf args +#else +#define CN_DEBUG_PRINTF(args) +#endif + +#ifdef VERSION_CN +#define FORCE_BSS __attribute__((nocommon)) __attribute__((section (".bss_cn"))) +#else +#define FORCE_BSS +#endif + #endif // MACROS_H diff --git a/include/macros.inc b/include/macros.inc index 3cb002a3..bcbe5f17 100644 --- a/include/macros.inc +++ b/include/macros.inc @@ -1,8 +1,10 @@ -// Assembly Macros +#ifndef VERSION_CN +.set gp=64 +#endif -.set K0BASE, 0x80000000 -.set K1BASE, 0xA0000000 -.set K2BASE, 0xC0000000 +.equ K0BASE, 0x80000000 +.equ K1BASE, 0xA0000000 +.equ K2BASE, 0xC0000000 .macro glabel label .global \label diff --git a/include/model_ids.h b/include/model_ids.h index c51b0b23..aebf9ab2 100644 --- a/include/model_ids.h +++ b/include/model_ids.h @@ -14,11 +14,6 @@ #define ALL_ACTS_MACRO ACT_1 | ACT_2 | ACT_3 | ACT_4 | ACT_5 #define ALL_ACTS ACT_1 | ACT_2 | ACT_3 | ACT_4 | ACT_5 | ACT_6 -#define COIN_FORMATION_FLAG_VERTICAL (1 << 0) -#define COIN_FORMATION_FLAG_RING (1 << 1) -#define COIN_FORMATION_FLAG_ARROW (1 << 2) -#define COIN_FORMATION_FLAG_FLYING (1 << 4) - #define MODEL_NONE 0x00 /* Global models that are loaded for every level */ diff --git a/include/object_constants.h b/include/object_constants.h index 16dfe90c..2ed0eb69 100644 --- a/include/object_constants.h +++ b/include/object_constants.h @@ -18,7 +18,6 @@ #define ACTIVE_FLAG_UNK9 (1 << 9) // 0x0200 #define ACTIVE_FLAG_UNK10 (1 << 10) // 0x0400 - /* respawnInfoType */ #define RESPAWN_INFO_TYPE_NULL 0 #define RESPAWN_INFO_TYPE_32 1 @@ -86,10 +85,10 @@ #endif #define OBJ_MOVE_MASK_ON_GROUND (OBJ_MOVE_LANDED | OBJ_MOVE_ON_GROUND) -#define OBJ_MOVE_MASK_IN_WATER (\ - OBJ_MOVE_ENTERED_WATER |\ - OBJ_MOVE_AT_WATER_SURFACE |\ - OBJ_MOVE_UNDERWATER_OFF_GROUND |\ +#define OBJ_MOVE_MASK_IN_WATER ( \ + OBJ_MOVE_ENTERED_WATER | \ + OBJ_MOVE_AT_WATER_SURFACE | \ + OBJ_MOVE_UNDERWATER_OFF_GROUND | \ OBJ_MOVE_UNDERWATER_ON_GROUND) /* oActiveParticleFlags */ @@ -122,6 +121,15 @@ #define OBJ_ACT_VERTICAL_KNOCKBACK 101 #define OBJ_ACT_SQUISHED 102 +/* Star Index */ +#define STAR_INDEX_ACT_1 0 +#define STAR_INDEX_ACT_2 1 +#define STAR_INDEX_ACT_3 2 +#define STAR_INDEX_ACT_4 3 +#define STAR_INDEX_ACT_5 4 +#define STAR_INDEX_ACT_6 5 +#define STAR_INDEX_100_COINS 6 + /* gTTCSpeedSetting */ #define TTC_SPEED_SLOW 0 #define TTC_SPEED_FAST 1 @@ -129,18 +137,41 @@ #define TTC_SPEED_STOPPED 3 /* Bob-omb */ - /* oBehParams2ndByte */ + /* oBhvParams2ndByte */ #define BOBOMB_BP_STYPE_GENERIC 0 #define BOBOMB_BP_STYPE_STATIONARY 1 /* oAction */ - #define BOBOMB_ACT_PATROL 0 - #define BOBOMB_ACT_LAUNCHED 1 - #define BOBOMB_ACT_CHASE_MARIO 2 - #define BOBOMB_ACT_EXPLODE 3 + #define BOBOMB_ACT_PATROL 0 + #define BOBOMB_ACT_LAUNCHED 1 + #define BOBOMB_ACT_CHASE_MARIO 2 + #define BOBOMB_ACT_EXPLODE 3 #define BOBOMB_ACT_LAVA_DEATH 100 #define BOBOMB_ACT_DEATH_PLANE_DEATH 101 +/* Coin Formation */ + /* oAction */ + #define COIN_FORMATION_ACT_SPAWN_COINS 0 + #define COIN_FORMATION_ACT_IDLE 1 + #define COIN_FORMATION_ACT_RESPAWN_COINS 2 + + /* oBhvParams2ndByte */ + #define COIN_FORMATION_BP_FLAG_HORIZONTAL (0 << 0) + #define COIN_FORMATION_BP_FLAG_VERTICAL (1 << 0) + #define COIN_FORMATION_BP_FLAG_RING (1 << 1) + #define COIN_FORMATION_BP_FLAG_ARROW (1 << 2) + #define COIN_FORMATION_BP_FLAG_FLYING (1 << 4) + #define COIN_FORMATION_BP_FLAG_MASK (COIN_FORMATION_BP_FLAG_HORIZONTAL | \ + COIN_FORMATION_BP_FLAG_VERTICAL | \ + COIN_FORMATION_BP_FLAG_RING | \ + COIN_FORMATION_BP_FLAG_ARROW) + + #define COIN_FORMATION_BP_LINE_HORIZONTAL (COIN_FORMATION_BP_FLAG_HORIZONTAL) + #define COIN_FORMATION_BP_LINE_VERTICAL (COIN_FORMATION_BP_FLAG_VERTICAL) + #define COIN_FORMATION_BP_RING_HORIZONTAL (COIN_FORMATION_BP_FLAG_HORIZONTAL | COIN_FORMATION_BP_FLAG_RING) + #define COIN_FORMATION_BP_RING_VERTICAL (COIN_FORMATION_BP_FLAG_VERTICAL | COIN_FORMATION_BP_FLAG_RING) + #define COIN_FORMATION_BP_ARROW (COIN_FORMATION_BP_FLAG_ARROW) + /* Hidden Blue Coin */ /* oAction */ #define HIDDEN_BLUE_COIN_ACT_INACTIVE 0 @@ -160,13 +191,13 @@ /* Moving Yellow Coin */ /* oAction */ - #define MOV_YCOIN_ACT_IDLE 0 - #define MOV_YCOIN_ACT_BLINKING 1 + #define MOV_YCOIN_ACT_IDLE 0 + #define MOV_YCOIN_ACT_BLINKING 1 #define MOV_YCOIN_ACT_LAVA_DEATH 100 #define MOV_YCOIN_ACT_DEATH_PLANE_DEATH 101 /* Bob-omb Buddy */ - /* oBehParams2ndByte */ + /* oBhvParams2ndByte */ #define BOBOMB_BUDDY_BP_STYPE_GENERIC 0 #define BOBOMB_BUDDY_BP_STYPE_BOB_GRASS_KBB 1 #define BOBOMB_BUDDY_BP_STYPE_BOB_CANNON_KBB 2 @@ -248,7 +279,7 @@ #define BOWSER_ANIM_FLIP 25 #define BOWSER_ANIM_STAND_UP_FROM_FLIP 26 - /* oBehParams2ndByte */ + /* oBhvParams2ndByte */ #define BOWSER_BP_BITDW 0 #define BOWSER_BP_BITFS 1 #define BOWSER_BP_BITS 2 @@ -292,13 +323,13 @@ #define BOWSER_SUB_ACT_HIT_MINE_START 0 #define BOWSER_SUB_ACT_HIT_MINE_FALL 1 #define BOWSER_SUB_ACT_HIT_MINE_STOP 2 - + #define BOWSER_SUB_ACT_JUMP_ON_STAGE_IDLE 0 #define BOWSER_SUB_ACT_JUMP_ON_STAGE_START 1 #define BOWSER_SUB_ACT_JUMP_ON_STAGE_LAND 2 #define BOWSER_SUB_ACT_JUMP_ON_STAGE_STOP 3 -/* Bowser Bits Platform*/ +/* Bowser BitS Platform */ /* oAction */ #define BOWSER_BITS_PLAT_ACT_START 0 #define BOWSER_BITS_PLAT_ACT_CHECK 1 @@ -308,9 +339,9 @@ /* oAction */ #define FISH_SPAWNER_ACT_SPAWN 0 #define FISH_SPAWNER_ACT_IDLE 1 - #define FISH_SPAWNER_ACT_RESPAWN 2 + #define FISH_SPAWNER_ACT_RESPAWN 2 - /* oBehParams2ndByte */ + /* oBhvParams2ndByte */ #define FISH_SPAWNER_BP_MANY_BLUE 0 #define FISH_SPAWNER_BP_FEW_BLUE 1 #define FISH_SPAWNER_BP_MANY_CYAN 2 @@ -322,7 +353,7 @@ #define FISH_ACT_ROAM 1 #define FISH_ACT_FLEE 2 -/* Blue_Fish */ +/* Blue Fish */ /* oAction */ #define BLUE_FISH_ACT_DIVE 0 #define BLUE_FISH_ACT_TURN 1 @@ -350,7 +381,7 @@ #define HOMING_AMP_ACT_ATTACK_COOLDOWN 4 /* Amp */ - /* oBehParams2ndByte */ + /* oBhvParams2ndByte */ #define AMP_BP_ROT_RADIUS_200 0 #define AMP_BP_ROT_RADIUS_300 1 #define AMP_BP_ROT_RADIUS_400 2 @@ -377,27 +408,27 @@ #define HOOT_ACT_CARRY 1 #define HOOT_ACT_TIRED 2 -/* Bully (all variants) */ - /* oBehParams2ndByte */ +/* Bully (All variants) */ + /* oBhvParams2ndByte */ #define BULLY_BP_SIZE_SMALL 0 #define BULLY_BP_SIZE_BIG 1 /* oAction */ - #define BULLY_ACT_PATROL 0 - #define BULLY_ACT_CHASE_MARIO 1 - #define BULLY_ACT_KNOCKBACK 2 - #define BULLY_ACT_BACK_UP 3 - #define BULLY_ACT_INACTIVE 4 - #define BULLY_ACT_ACTIVATE_AND_FALL 5 + #define BULLY_ACT_PATROL 0 + #define BULLY_ACT_CHASE_MARIO 1 + #define BULLY_ACT_KNOCKBACK 2 + #define BULLY_ACT_BACK_UP 3 + #define BULLY_ACT_INACTIVE 4 + #define BULLY_ACT_ACTIVATE_AND_FALL 5 #define BULLY_ACT_LAVA_DEATH 100 #define BULLY_ACT_DEATH_PLANE_DEATH 101 /* oBullySubtype */ - #define BULLY_STYPE_GENERIC 0 - #define BULLY_STYPE_MINION 1 + #define BULLY_STYPE_GENERIC 0 + #define BULLY_STYPE_MINION 1 #define BULLY_STYPE_CHILL 16 -/* Water Ring (all variants) */ +/* Water Ring (All variants) */ /* oAction */ #define WATER_RING_ACT_NOT_COLLECTED 0 #define WATER_RING_ACT_COLLECTED 1 @@ -417,7 +448,7 @@ #define LLL_DRAWBRIDGE_ACT_LOWER 0 #define LLL_DRAWBRIDGE_ACT_RAISE 1 -/* Bomp (both variants) */ +/* Bomp (Both variants) */ /* oAction */ #define BOMP_ACT_WAIT 0 #define BOMP_ACT_POKE_OUT 1 @@ -425,7 +456,7 @@ #define BOMP_ACT_RETRACT 3 /* WF Sliding Brick Platform */ - /* oBehParams2ndByte */ + /* oBhvParams2ndByte */ #define WF_SLID_BRICK_PTFM_BP_MOV_VEL_10 1 #define WF_SLID_BRICK_PTFM_BP_MOV_VEL_15 2 #define WF_SLID_BRICK_PTFM_BP_MOV_VEL_20 3 @@ -462,8 +493,8 @@ #define BBALL_ACT_INITIALIZE 0 #define BBALL_ACT_ROLL 1 -/* Bowling Ball + Bowling Ball Spawner (all variants) */ - /* oBehParams2ndByte */ +/* Bowling Ball + Bowling Ball Spawner (All variants) */ + /* oBhvParams2ndByte */ #define BBALL_BP_STYPE_BOB_UPPER 0 #define BBALL_BP_STYPE_TTM 1 #define BBALL_BP_STYPE_BOB_LOWER 2 @@ -495,10 +526,21 @@ #define BOO_DEATH_STATUS_DEAD 2 /* attackStatus */ - #define BOO_NOT_ATTACKED 0 - #define BOO_ATTACKED 1 + #define BOO_NOT_ATTACKED 0 + #define BOO_ATTACKED 1 #define BOO_BOUNCED_ON -1 + /* oBhvParams2ndByte */ + #define BOO_BP_GHOST_HUNT 0 + #define BOO_BP_GENERIC 1 + #define BOO_BP_MERRY_GO_ROUND 2 + +/* Big Boo */ + /* oBhvParams2ndByte */ + #define BIG_BOO_BP_GHOST_HUNT 0 + #define BIG_BOO_BP_MERRY_GO_ROUND 1 + #define BIG_BOO_BP_BALCONY 2 + /* Beta Boo Key */ /* oAction */ #define BETA_BOO_KEY_ACT_IN_BOO 0 @@ -521,7 +563,7 @@ /* BBH Merry-Go-Round */ /* gMarioCurrentRoom */ #define BBH_NEAR_MERRY_GO_ROUND_ROOM 10 - #define BBH_DYNAMIC_SURFACE_ROOM 0 + #define BBH_DYNAMIC_SURFACE_ROOM 0 #define BBH_OUTSIDE_ROOM 13 /* Coffin Spawner */ @@ -533,7 +575,7 @@ #define COFFIN_ACT_IDLE 0 #define COFFIN_ACT_STAND_UP 1 - /* oBehParams2ndByte */ + /* oBhvParams2ndByte */ #define COFFIN_BP_STATIC 0 /* WDW Arrow Lift */ @@ -548,12 +590,12 @@ /* Yoshi */ /* oAction */ - #define YOSHI_ACT_IDLE 0 - #define YOSHI_ACT_WALK 1 - #define YOSHI_ACT_TALK 2 - #define YOSHI_ACT_WALK_JUMP_OFF_ROOF 3 - #define YOSHI_ACT_FINISH_JUMPING_AND_DESPAWN 4 - #define YOSHI_ACT_GIVE_PRESENT 5 + #define YOSHI_ACT_IDLE 0 + #define YOSHI_ACT_WALK 1 + #define YOSHI_ACT_TALK 2 + #define YOSHI_ACT_WALK_JUMP_OFF_ROOF 3 + #define YOSHI_ACT_FINISH_JUMPING_AND_DESPAWN 4 + #define YOSHI_ACT_GIVE_PRESENT 5 #define YOSHI_ACT_CREDITS 10 /* Koopa */ @@ -590,7 +632,7 @@ #define KOOPA_THE_QUICK_BOB_INDEX 0 #define KOOPA_THE_QUICK_THI_INDEX 1 - /* oBehParams2ndByte */ + /* oBhvParams2ndByte */ #define KOOPA_BP_UNSHELLED 0 #define KOOPA_BP_NORMAL 1 #define KOOPA_BP_KOOPA_THE_QUICK_BASE 2 @@ -609,35 +651,40 @@ #define SWOOP_ACT_IDLE 0 #define SWOOP_ACT_MOVE 1 -/* Fly guy */ +/* Fly Guy */ /* oAction */ #define FLY_GUY_ACT_IDLE 0 #define FLY_GUY_ACT_APPROACH_MARIO 1 #define FLY_GUY_ACT_LUNGE 2 #define FLY_GUY_ACT_SHOOT_FIRE 3 -/* Goomba triplet spawner */ - /* oBehParams2ndByte */ - #define GOOMBA_TRIPLET_SPAWNER_BP_SIZE_MASK 0x00000003 - #define GOOMBA_TRIPLET_SPAWNER_BP_EXTRA_GOOMBAS_MASK 0x000000FC - - /* oAction */ - #define GOOMBA_TRIPLET_SPAWNER_ACT_UNLOADED 0 - #define GOOMBA_TRIPLET_SPAWNER_ACT_LOADED 1 + /* oBhvParams2ndByte */ + #define FLY_GUY_BP_GENERIC 0 + #define FLY_GUY_BP_FIRE 1 /* Goomba */ - /* oBehParams2ndByte */ - #define GOOMBA_BP_SIZE_MASK 0x00000003 - #define GOOMBA_SIZE_REGULAR 0 - #define GOOMBA_SIZE_HUGE 1 - #define GOOMBA_SIZE_TINY 2 - #define GOOMBA_BP_TRIPLET_FLAG_MASK 0x000000FC /* oAction */ #define GOOMBA_ACT_WALK 0 #define GOOMBA_ACT_ATTACKED_MARIO 1 #define GOOMBA_ACT_JUMP 2 -/* Chain chomp */ + /* oBhvParams2ndByte */ + #define GOOMBA_SIZE_REGULAR 0 + #define GOOMBA_SIZE_HUGE 1 + #define GOOMBA_SIZE_TINY 2 + #define GOOMBA_BP_SIZE_MASK (GOOMBA_SIZE_REGULAR | GOOMBA_SIZE_HUGE | GOOMBA_SIZE_TINY) + #define GOOMBA_BP_TRIPLET_RESPAWN_FLAG_MASK (0x000000FF & ~GOOMBA_BP_SIZE_MASK) + +/* Goomba Triplet Spawner */ + /* oAction */ + #define GOOMBA_TRIPLET_SPAWNER_ACT_UNLOADED 0 + #define GOOMBA_TRIPLET_SPAWNER_ACT_LOADED 1 + + /* oBhvParams2ndByte */ + #define GOOMBA_TRIPLET_SPAWNER_BP_EXTRA_GOOMBAS_MASK (0x000000FF & ~GOOMBA_BP_SIZE_MASK) + #define GOOMBA_TRIPLET_SPAWNER_BP_EXTRA_GOOMBAS(num) ((num) << 2) + +/* Chain Chomp */ /* oAction */ #define CHAIN_CHOMP_ACT_UNINITIALIZED 0 #define CHAIN_CHOMP_ACT_MOVE 1 @@ -655,12 +702,12 @@ #define CHAIN_CHOMP_RELEASED_JUMP_AWAY 4 #define CHAIN_CHOMP_RELEASED_END_CUTSCENE 5 -/* Chain chomp chain part */ - /* oBehParams2ndByte */ +/* Chain Chomp Chain Part */ + /* oBhvParams2ndByte */ #define CHAIN_CHOMP_CHAIN_PART_BP_PIVOT 0 -/* Wooden post */ - /* oBehParams */ +/* Wooden Post */ + /* oBhvParams */ #define WOODEN_POST_BP_NO_COINS_MASK 0x0000FF00 /* Wiggler */ @@ -684,7 +731,7 @@ #define SPINY_ACT_THROWN_BY_LAKITU 2 #define SPINY_ACT_ATTACKED_MARIO 3 -/* Evil lakitu */ +/* Evil Lakitu */ /* oAction */ #define ENEMY_LAKITU_ACT_UNINITIALIZED 0 #define ENEMY_LAKITU_ACT_MAIN 1 @@ -701,17 +748,17 @@ #define CLOUD_ACT_UNLOAD 2 #define CLOUD_ACT_FWOOSH_HIDDEN 3 - /* oBehParams2ndByte */ + /* oBhvParams2ndByte */ #define CLOUD_BP_FWOOSH 0 #define CLOUD_BP_LAKITU_CLOUD 1 -/* Camera lakitu */ +/* Camera Lakitu */ /* oAction */ #define CAMERA_LAKITU_INTRO_ACT_TRIGGER_CUTSCENE 0 #define CAMERA_LAKITU_INTRO_ACT_SPAWN_CLOUD 1 #define CAMERA_LAKITU_INTRO_ACT_UNK2 2 - /* oBehParams2ndByte */ + /* oBhvParams2ndByte */ #define CAMERA_LAKITU_BP_FOLLOW_CAMERA 0 #define CAMERA_LAKITU_BP_INTRO 1 @@ -720,7 +767,7 @@ #define MANTA_ACT_SPAWN_RINGS 0 #define MANTA_ACT_NO_RINGS 1 -/* Monty mole */ +/* Monty Mole */ /* oAction */ #define MONTY_MOLE_ACT_SELECT_HOLE 0 #define MONTY_MOLE_ACT_RISE_FROM_HOLE 1 @@ -731,10 +778,11 @@ #define MONTY_MOLE_ACT_HIDE 6 #define MONTY_MOLE_ACT_JUMP_OUT_OF_HOLE 7 - /* oBehParams2ndByte */ + /* oBhvParams2ndByte */ #define MONTY_MOLE_BP_NO_ROCK 0 + #define MONTY_MOLE_BP_GENERIC 1 -/* Monty mole rock */ +/* Monty Mole Rock */ /* oAction */ #define MONTY_MOLE_ROCK_ACT_HELD 0 #define MONTY_MOLE_ROCK_ACT_MOVE 1 @@ -776,21 +824,21 @@ #define UKIKI_TEXT_DO_NOT_LET_GO 6 #define UKIKI_TEXT_STEAL_CAP 7 - /* oBehParams2ndByte */ - #define UKIKI_CAGE 0 - #define UKIKI_CAP 1 + /* oBhvParams2ndByte */ + #define UKIKI_BP_CAGE 0 + #define UKIKI_BP_CAP 1 /* Animations */ - #define UKIKI_ANIM_RUN 0 - #define UKIKI_ANIM_UNUSED_WALK 1 - #define UKIKI_ANIM_UNUSED_APOSE 2 - #define UKIKI_ANIM_UNUSED_DEATH 3 - #define UKIKI_ANIM_SCREECH 4 - #define UKIKI_ANIM_JUMP_CLAP 5 - #define UKIKI_ANIM_UNUSED_HOP 6 - #define UKIKI_ANIM_LAND 7 - #define UKIKI_ANIM_JUMP 8 - #define UKIKI_ANIM_ITCH 9 + #define UKIKI_ANIM_RUN 0 + #define UKIKI_ANIM_UNUSED_WALK 1 + #define UKIKI_ANIM_UNUSED_APOSE 2 + #define UKIKI_ANIM_UNUSED_DEATH 3 + #define UKIKI_ANIM_SCREECH 4 + #define UKIKI_ANIM_JUMP_CLAP 5 + #define UKIKI_ANIM_UNUSED_HOP 6 + #define UKIKI_ANIM_LAND 7 + #define UKIKI_ANIM_JUMP 8 + #define UKIKI_ANIM_ITCH 9 #define UKIKI_ANIM_HANDSTAND 10 #define UKIKI_ANIM_TURN 11 #define UKIKI_ANIM_HELD 12 @@ -830,12 +878,13 @@ /* oPiranhaPlantSleepMusicState */ #define PIRANHA_PLANT_SLEEP_MUSIC_PLAYING 0 -/* Piranha Plant bubble */ +/* Piranha Plant Bubble */ + /* oAction */ #define PIRANHA_PLANT_BUBBLE_ACT_IDLE 0 #define PIRANHA_PLANT_BUBBLE_ACT_GROW_SHRINK_LOOP 1 #define PIRANHA_PLANT_BUBBLE_ACT_BURST 2 -/* Platform on track */ +/* Platform on Track */ /* oAction */ #define PLATFORM_ON_TRACK_ACT_INIT 0 #define PLATFORM_ON_TRACK_ACT_WAIT_FOR_MARIO 1 @@ -843,11 +892,11 @@ #define PLATFORM_ON_TRACK_ACT_PAUSE_BRIEFLY 3 #define PLATFORM_ON_TRACK_ACT_FALL 4 - /* oBehParams >> 16 */ - #define PLATFORM_ON_TRACK_BP_MASK_PATH 0xF - #define PLATFORM_ON_TRACK_BP_MASK_TYPE (0x7 << 4) - #define PLATFORM_ON_TRACK_BP_RETURN_TO_START (1 << 8) - #define PLATFORM_ON_TRACK_BP_DONT_DISAPPEAR (1 << 9) + /* oBhvParams >> 16 */ + #define PLATFORM_ON_TRACK_BP_MASK_PATH 0x000F + #define PLATFORM_ON_TRACK_BP_MASK_TYPE 0x0070 + #define PLATFORM_ON_TRACK_BP_RETURN_TO_START (1 << 8) + #define PLATFORM_ON_TRACK_BP_DONT_DISAPPEAR (1 << 9) #define PLATFORM_ON_TRACK_BP_DONT_TURN_YAW (1 << 10) #define PLATFORM_ON_TRACK_BP_DONT_TURN_ROLL (1 << 11) @@ -856,35 +905,38 @@ #define PLATFORM_ON_TRACK_TYPE_CHECKERED 2 #define PLATFORM_ON_TRACK_TYPE_GRATE 3 -/* Purple switch */ - #define PURPLE_SWITCH_IDLE 0 - #define PURPLE_SWITCH_PRESSED 1 - #define PURPLE_SWITCH_TICKING 2 - #define PURPLE_SWITCH_UNPRESSED 3 - #define PURPLE_SWITCH_WAIT_FOR_MARIO_TO_GET_OFF 4 +/* Purple Switch */ + /* oAction */ + #define PURPLE_SWITCH_ACT_IDLE 0 + #define PURPLE_SWITCH_ACT_PRESSED 1 + #define PURPLE_SWITCH_ACT_TICKING 2 + #define PURPLE_SWITCH_ACT_UNPRESSED 3 + #define PURPLE_SWITCH_ACT_WAIT_FOR_MARIO_TO_GET_OFF 4 -/* Pyramid elevator */ - #define PYRAMID_ELEVATOR_IDLE 0 - #define PYRAMID_ELEVATOR_START_MOVING 1 - #define PYRAMID_ELEVATOR_CONSTANT_VELOCITY 2 - #define PYRAMID_ELEVATOR_AT_BOTTOM 3 +/* Pyramid Elevator */ + /* oAction */ + #define PYRAMID_ELEVATOR_ACT_IDLE 0 + #define PYRAMID_ELEVATOR_ACT_START_MOVING 1 + #define PYRAMID_ELEVATOR_ACT_CONSTANT_VELOCITY 2 + #define PYRAMID_ELEVATOR_ACT_AT_BOTTOM 3 -/* Pyramid top */ +/* Pyramid Top */ + /* oAction */ #define PYRAMID_TOP_ACT_CHECK_IF_SOLVED 0 #define PYRAMID_TOP_ACT_SPINNING 1 #define PYRAMID_TOP_ACT_EXPLODE 2 -/* Pyramid wall */ +/* Pyramid Wall */ /* oAction */ #define PYRAMID_WALL_ACT_MOVING_DOWN 0 #define PYRAMID_WALL_ACT_MOVING_UP 1 - /* oBehParams2ndByte */ + /* oBhvParams2ndByte */ #define PYRAMID_WALL_BP_POSITION_HIGH 0 #define PYRAMID_WALL_BP_POSITION_MIDDLE 1 #define PYRAMID_WALL_BP_POSITION_LOW 2 -/* Penguins (general) */ +/* Penguins (General) */ /* Walking sounds */ #define PENGUIN_WALK_BABY 0 #define PENGUIN_WALK_BIG 1 @@ -893,7 +945,7 @@ #define PENGUIN_ANIM_WALK 0 #define PENGUIN_ANIM_IDLE 3 -/* Racing penguin */ +/* Racing Penguin */ /* oAction */ #define RACING_PENGUIN_ACT_WAIT_FOR_MARIO 0 #define RACING_PENGUIN_ACT_SHOW_INIT_TEXT 1 @@ -902,80 +954,98 @@ #define RACING_PENGUIN_ACT_FINISH_RACE 4 #define RACING_PENGUIN_ACT_SHOW_FINAL_TEXT 5 -/* SL walking penguin */ + /* oBhvParams2ndByte */ + #define RACING_PENGUIN_BP_THIN 0 + #define RACING_PENGUIN_BP_FAT 1 + +/* SL Walking Penguin */ /* oAction */ #define SL_WALKING_PENGUIN_ACT_MOVING_FORWARDS 0 #define SL_WALKING_PENGUIN_ACT_TURNING_BACK 1 #define SL_WALKING_PENGUIN_ACT_RETURNING 2 #define SL_WALKING_PENGUIN_ACT_TURNING_FORWARDS 3 -/* Snowman wind */ +/* Snowman Wind */ /* oSubAction */ #define SL_SNOWMAN_WIND_ACT_IDLE 0 #define SL_SNOWMAN_WIND_ACT_TALKING 1 #define SL_SNOWMAN_WIND_ACT_BLOWING 2 -/* Water bomb */ +/* Water Bomb */ /* oAction */ #define WATER_BOMB_ACT_SHOT_FROM_CANNON 0 #define WATER_BOMB_ACT_INIT 1 #define WATER_BOMB_ACT_DROP 2 #define WATER_BOMB_ACT_EXPLODE 3 -/* TTC rotating solid */ - /* oBehParams2ndByte */ +/* TTC Rotating Solid */ + /* oBhvParams2ndByte */ #define TTC_ROTATING_SOLID_BP_CUBE 0 #define TTC_ROTATING_SOLID_BP_TRIANGULAR_PRISM 1 -/* TTC moving bar */ +/* TTC Treadmill */ + /* oBhvParams2ndByte */ + #define TTC_TREADMILL_BP_FLAG_LARGE (0 << 0) + #define TTC_TREADMILL_BP_FLAG_SMALL (1 << 0) + #define TTC_TREADMILL_BP_FLAG_MASK (TTC_TREADMILL_BP_FLAG_LARGE | TTC_TREADMILL_BP_FLAG_SMALL) + #define TTC_TREADMILL_BP_LARGE_1 ((0 << 1) | TTC_TREADMILL_BP_FLAG_LARGE) + #define TTC_TREADMILL_BP_SMALL_1 ((0 << 1) | TTC_TREADMILL_BP_FLAG_SMALL) + #define TTC_TREADMILL_BP_LARGE_2 ((1 << 1) | TTC_TREADMILL_BP_FLAG_LARGE) + #define TTC_TREADMILL_BP_SMALL_2 ((1 << 1) | TTC_TREADMILL_BP_FLAG_SMALL) + +/* TTC Moving Bar */ /* oAction */ #define TTC_MOVING_BAR_ACT_WAIT 0 #define TTC_MOVING_BAR_ACT_PULL_BACK 1 #define TTC_MOVING_BAR_ACT_EXTEND 2 #define TTC_MOVING_BAR_ACT_RETRACT 3 -/* TTC cog */ - /* oBehParams2ndByte */ - #define TTC_COG_BP_SHAPE_MASK 0x00000002 +/* TTC Cog */ + /* oBhvParams2ndByte */ #define TTC_COG_BP_SHAPE_HEXAGON (0 << 1) #define TTC_COG_BP_SHAPE_TRIANGLE (1 << 1) - #define TTC_COG_BP_DIR_MASK 0x00000001 + #define TTC_COG_BP_SHAPE_MASK (TTC_COG_BP_SHAPE_HEXAGON | TTC_COG_BP_SHAPE_TRIANGLE) #define TTC_COG_BP_DIR_CCW (0 << 0) // TODO: Check these #define TTC_COG_BP_DIR_CW (1 << 0) + #define TTC_COG_BP_DIR_MASK (TTC_COG_BP_DIR_CCW | TTC_COG_BP_DIR_CW) /* TTC 2D Rotator */ - /* oBehParams2ndByte */ + /* oBhvParams2ndByte */ #define TTC_2D_ROTATOR_BP_HAND 0 #define TTC_2D_ROTATOR_BP_2D_COG 1 /* Activated Back-and-Forth Platform */ - /* ((u16)(o->oBehParams >> 16) & 0x0300) >> 8 aka platform type */ #define ACTIVATED_BF_PLAT_TYPE_BITS_ARROW_PLAT 0 #define ACTIVATED_BF_PLAT_TYPE_BITFS_MESH_PLAT 1 #define ACTIVATED_BF_PLAT_TYPE_BITFS_ELEVATOR 2 + /* oBhvParams >> 16 */ + #define ACTIVATED_BF_PLAT_BP_MASK_TYPE ((ACTIVATED_BF_PLAT_TYPE_BITS_ARROW_PLAT | \ + ACTIVATED_BF_PLAT_TYPE_BITFS_MESH_PLAT | \ + ACTIVATED_BF_PLAT_TYPE_BITFS_ELEVATOR) << 8) + /* Dorrie */ /* oAction */ #define DORRIE_ACT_MOVE 0 #define DORRIE_ACT_LOWER_HEAD 1 #define DORRIE_ACT_RAISE_HEAD 2 -/* Mad piano */ +/* Mad Piano */ /* oAction */ #define MAD_PIANO_ACT_WAIT 0 #define MAD_PIANO_ACT_ATTACK 1 -/* Fire piranha plant */ +/* Fire Piranha Plant */ /* oAction */ #define FIRE_PIRANHA_PLANT_ACT_HIDE 0 #define FIRE_PIRANHA_PLANT_ACT_GROW 1 -/* Fire spitter */ +/* Fire Spitter */ /* oAction */ #define FIRE_SPITTER_ACT_IDLE 0 #define FIRE_SPITTER_ACT_SPIT_FIRE 1 -/* Eyerok boss */ +/* Eyerok Boss */ /* oAction */ #define EYEROK_BOSS_ACT_SLEEP 0 #define EYEROK_BOSS_ACT_WAKE_UP 1 @@ -983,18 +1053,18 @@ #define EYEROK_BOSS_ACT_FIGHT 3 #define EYEROK_BOSS_ACT_DIE 4 -/* Eyerok hand */ +/* Eyerok Hand */ /* oAction */ - #define EYEROK_HAND_ACT_SLEEP 0 - #define EYEROK_HAND_ACT_IDLE 1 - #define EYEROK_HAND_ACT_OPEN 2 - #define EYEROK_HAND_ACT_SHOW_EYE 3 - #define EYEROK_HAND_ACT_CLOSE 4 - #define EYEROK_HAND_ACT_RETREAT 5 - #define EYEROK_HAND_ACT_TARGET_MARIO 6 - #define EYEROK_HAND_ACT_SMASH 7 - #define EYEROK_HAND_ACT_FIST_PUSH 8 - #define EYEROK_HAND_ACT_FIST_SWEEP 9 + #define EYEROK_HAND_ACT_SLEEP 0 + #define EYEROK_HAND_ACT_IDLE 1 + #define EYEROK_HAND_ACT_OPEN 2 + #define EYEROK_HAND_ACT_SHOW_EYE 3 + #define EYEROK_HAND_ACT_CLOSE 4 + #define EYEROK_HAND_ACT_RETREAT 5 + #define EYEROK_HAND_ACT_TARGET_MARIO 6 + #define EYEROK_HAND_ACT_SMASH 7 + #define EYEROK_HAND_ACT_FIST_PUSH 8 + #define EYEROK_HAND_ACT_FIST_SWEEP 9 #define EYEROK_HAND_ACT_BEGIN_DOUBLE_POUND 10 // raising for double smash #define EYEROK_HAND_ACT_DOUBLE_POUND 11 // double smashing #define EYEROK_HAND_ACT_ATTACKED 12 @@ -1023,7 +1093,7 @@ #define BIRD_ACT_INACTIVE 0 #define BIRD_ACT_FLY 1 - /* oBehParams2ndByte */ + /* oBhvParams2ndByte */ #define BIRD_BP_SPAWNED 0 #define BIRD_BP_SPAWNER 1 @@ -1049,23 +1119,28 @@ #define TWEESTER_SUB_ACT_CHASE 0 -/* Triplet butterfly */ +/* Triplet Butterfly */ /* oAction */ #define TRIPLET_BUTTERFLY_ACT_INIT 0 #define TRIPLET_BUTTERFLY_ACT_WANDER 1 #define TRIPLET_BUTTERFLY_ACT_ACTIVATE 2 #define TRIPLET_BUTTERFLY_ACT_EXPLODE 3 - /* oBehParams2ndByte */ - #define TRIPLET_BUTTERFLY_BP_BUTTERFLY_NUM 0x00000003 - #define TRIPLET_BUTTERFLY_BP_NO_BOMBS 0x00000004 + /* oBhvParams2ndByte */ + #define TRIPLET_BUTTERFLY_BP_SPAWN_TYPE_SPAWNER (0 << 0) + #define TRIPLET_BUTTERFLY_BP_SPAWN_TYPE_SPAWNED_1 (1 << 0) + #define TRIPLET_BUTTERFLY_BP_SPAWN_TYPE_SPAWNED_2 (1 << 1) + #define TRIPLET_BUTTERFLY_BP_SPAWN_TYPE_MASK (TRIPLET_BUTTERFLY_BP_SPAWN_TYPE_SPAWNER | \ + TRIPLET_BUTTERFLY_BP_SPAWN_TYPE_SPAWNED_1 | \ + TRIPLET_BUTTERFLY_BP_SPAWN_TYPE_SPAWNED_2) + #define TRIPLET_BUTTERFLY_BP_NO_BOMBS (1 << 2) /* oTripletButterflyType */ #define TRIPLET_BUTTERFLY_TYPE_NORMAL -1 - #define TRIPLET_BUTTERFLY_TYPE_EXPLODES 0 - #define TRIPLET_BUTTERFLY_TYPE_SPAWN_1UP 1 + #define TRIPLET_BUTTERFLY_TYPE_EXPLODES 0 + #define TRIPLET_BUTTERFLY_TYPE_SPAWN_1UP 1 -/* Water level diamond */ +/* Water Level Diamond */ /* oAction */ // Loading #define WATER_LEVEL_DIAMOND_ACT_INIT 0 @@ -1089,6 +1164,10 @@ #define MIPS_STAR_STATUS_SHOULD_SPAWN_STAR 1 #define MIPS_STAR_STATUS_ALREADY_SPAWNED_STAR 2 + /* oBhvParams2ndByte */ + #define MIPS_BP_15_STARS 0 + #define MIPS_BP_50_STARS 1 + /* Falling Pillar */ /* oAction */ #define FALLING_PILLAR_ACT_IDLE 0 @@ -1112,8 +1191,119 @@ #define MR_BLIZZARD_ACT_DEATH 6 #define MR_BLIZZARD_ACT_JUMP 7 - /* oBehParams2ndByte */ - #define MR_BLIZZARD_STYPE_NO_CAP 0 + /* oBhvParams2ndByte */ + #define MR_BLIZZARD_STYPE_GENERIC 0 #define MR_BLIZZARD_STYPE_JUMPING 1 + #define MR_BLIZZARD_STYPE_CAP 2 + +/* Whomp */ + /* oBhvParams2ndByte */ + #define WHOMP_BP_SMALL 0 + #define WHOMP_BP_KING 1 + +/* 1-Up Mushroom */ + /* oBhvParams2ndByte */ + #define ONE_UP_BP_GENERIC 0 + #define ONE_UP_BP_BEAT_BITDW_BOWSER 1 + #define ONE_UP_BP_BEAT_BITFS_BOWSER 2 + +/* Breakable Box */ + /* oBhvParams2ndByte */ + #define BREAKABLE_BOX_BP_NO_COINS 0 + #define BREAKABLE_BOX_BP_3_COINS 1 + #define BREAKABLE_BOX_BP_5_COINS 2 + #define BREAKABLE_BOX_BP_GIANT 3 + +/* Hidden Object */ + /* oAction */ + #define HIDDEN_OBJECT_ACT_INACTIVE 0 + #define HIDDEN_OBJECT_ACT_ACTIVE 1 + #define HIDDEN_OBJECT_ACT_BROKEN 2 + + /* oBhvParams2ndByte */ + #define HIDDEN_OBJECT_BP_BREAKABLE_BOX 0 + #define HIDDEN_OBJECT_BP_WDW_PLATFORM 1 + #define HIDDEN_OBJECT_BP_UNBREAKABLE_BOX_UNUSED_1 1 + #define HIDDEN_OBJECT_BP_UNBREAKABLE_BOX_UNUSED_2 2 + +/* Exclamation Box */ + /* oAnimState */ + #define EXCLAMATION_BOX_ANIM_STATE_WING_CAP 0 + #define EXCLAMATION_BOX_ANIM_STATE_METAL_CAP 1 + #define EXCLAMATION_BOX_ANIM_STATE_VANISH_CAP 2 + #define EXCLAMATION_BOX_ANIM_STATE_DEFAULT 3 + + /* oBhvParams2ndByte */ + #define EXCLAMATION_BOX_BP_WING_CAP 0 + #define EXCLAMATION_BOX_BP_METAL_CAP 1 + #define EXCLAMATION_BOX_BP_VANISH_CAP 2 + #define EXCLAMATION_BOX_BP_SPECIAL_CAP_END 2 + #define EXCLAMATION_BOX_BP_KOOPA_SHELL 3 + #define EXCLAMATION_BOX_BP_ONE_COIN 4 + #define EXCLAMATION_BOX_BP_THREE_COINS 5 + #define EXCLAMATION_BOX_BP_TEN_COINS 6 + #define EXCLAMATION_BOX_BP_1UP_WALKING 7 + #define EXCLAMATION_BOX_BP_STAR_ACT_1 8 + #define EXCLAMATION_BOX_BP_1UP_RUNNING_AWAY 9 + #define EXCLAMATION_BOX_BP_STAR_ACT_2 10 + #define EXCLAMATION_BOX_BP_STAR_ACT_3 11 + #define EXCLAMATION_BOX_BP_STAR_ACT_4 12 + #define EXCLAMATION_BOX_BP_STAR_ACT_5 13 + #define EXCLAMATION_BOX_BP_STAR_ACT_6 14 + #define EXCLAMATION_BOX_BP_END 99 + +/* Cap Switch */ + /* oBhvParams2ndByte */ + #define CAP_SWITCH_BP_RED 0 + #define CAP_SWITCH_BP_GREEN 1 + #define CAP_SWITCH_BP_BLUE 2 + #define CAP_SWITCH_BP_YELLOW 3 + +/* Openable Grill */ + /* oBhvParams2ndByte */ + #define OPENABLE_GRILL_BP_BOB 0 + #define OPENABLE_GRILL_BP_HMC 1 + +/* WF Rotating Wooden Platform */ + /* oAction */ + #define WF_ROTATING_WOODEN_PLATFORM_ACT_IDLE 0 + #define WF_ROTATING_WOODEN_PLATFORM_ACT_ROTATING 1 + +/* Rotating Platform */ + /* oBhvParams2ndByte */ + #define ROTATING_PLATFORM_BP_WF 0 + #define ROTATING_PLATFORM_BP_WDW 1 + +/* Tumbling Bridge */ + /* oBhvParams2ndByte */ + #define TUMBLING_BRIDGE_BP_WF 0 + #define TUMBLING_BRIDGE_BP_BBH 1 + #define TUMBLING_BRIDGE_BP_LLL 2 + #define TUMBLING_BRIDGE_BP_BITFS 3 + +/* Grindel or Thwomp */ + /* oAction */ + #define GRINDEL_THWOMP_ACT_RAISE 0 + #define GRINDEL_THWOMP_ACT_IDLE_AT_TOP 1 + #define GRINDEL_THWOMP_ACT_LOWER 2 + #define GRINDEL_THWOMP_ACT_LAND 3 + #define GRINDEL_THWOMP_ACT_IDLE_AT_BOTTOM 4 + +/* Tox Box */ + /* oAction */ + #define TOX_BOX_ACT_INIT 0 + #define TOX_BOX_ACT_ROLL_LAND 1 + #define TOX_BOX_ACT_IDLE 2 + #define TOX_BOX_ACT_UNUSED_IDLE 3 + #define TOX_BOX_ACT_ROLL_FORWARD 4 + #define TOX_BOX_ACT_ROLL_BACKWARD 5 + #define TOX_BOX_ACT_ROLL_RIGHT 6 + #define TOX_BOX_ACT_ROLL_LEFT 7 + #define TOX_BOX_ACT_TABLE_END -1 + + /* oBhvParams2ndByte */ + #define TOX_BOX_BP_MOVEMENT_PATTERN_1 0 + #define TOX_BOX_BP_MOVEMENT_PATTERN_2 1 + #define TOX_BOX_BP_MOVEMENT_PATTERN_3 2 #endif // OBJECT_CONSTANTS_H diff --git a/include/object_fields.h b/include/object_fields.h index 8159f4aa..3eba0042 100644 --- a/include/object_fields.h +++ b/include/object_fields.h @@ -101,7 +101,7 @@ #define /*0x138*/ oParentRelativePosX OBJECT_FIELD_F32(O_PARENT_RELATIVE_POS_INDEX + 0) #define /*0x13C*/ oParentRelativePosY OBJECT_FIELD_F32(O_PARENT_RELATIVE_POS_INDEX + 1) #define /*0x140*/ oParentRelativePosZ OBJECT_FIELD_F32(O_PARENT_RELATIVE_POS_INDEX + 2) -#define /*0x144*/ oBehParams2ndByte OBJECT_FIELD_S32(0x2F) +#define /*0x144*/ oBhvParams2ndByte OBJECT_FIELD_S32(0x2F) // 0x148 unused, possibly a third param byte. #define /*0x14C*/ oAction OBJECT_FIELD_S32(0x31) #define /*0x150*/ oSubAction OBJECT_FIELD_S32(0x32) @@ -118,7 +118,7 @@ #define /*0x17C*/ oOpacity OBJECT_FIELD_S32(0x3D) #define /*0x180*/ oDamageOrCoinValue OBJECT_FIELD_S32(0x3E) #define /*0x184*/ oHealth OBJECT_FIELD_S32(0x3F) -#define /*0x188*/ oBehParams OBJECT_FIELD_S32(0x40) +#define /*0x188*/ oBhvParams OBJECT_FIELD_S32(0x40) #define /*0x18C*/ oPrevAction OBJECT_FIELD_S32(0x41) #define /*0x190*/ oInteractionSubtype OBJECT_FIELD_U32(0x42) #define /*0x194*/ oCollisionDistance OBJECT_FIELD_F32(0x43) @@ -126,7 +126,7 @@ #define /*0x19C*/ oDrawingDistance OBJECT_FIELD_F32(0x45) #define /*0x1A0*/ oRoom OBJECT_FIELD_S32(0x46) // 0x1A4 is unused, possibly related to 0x1A8 in removed macro purposes. -#define /*0x1A8*/ oUnk1A8 OBJECT_FIELD_U32(0x48) +#define /*0x1A8*/ oUnusedBhvParams OBJECT_FIELD_U32(0x48) // 0x1AC-0x1B2 (0x48-0x4A) are object specific and defined below the common fields. #define /*0x1B4*/ oWallAngle OBJECT_FIELD_S32(0x4B) #define /*0x1B8*/ oFloorType OBJECT_FIELD_S16(0x4C, 0) @@ -165,8 +165,8 @@ #define /*0x110*/ oMarioSteepJumpYaw OBJECT_FIELD_S32(0x22) #define /*0x110*/ oMarioWalkingPitch OBJECT_FIELD_S32(0x22) -/* 1-Up Hidden */ -#define /*0x0F4*/ o1UpHiddenUnkF4 OBJECT_FIELD_S32(0x1B) +/* Hidden 1-Up */ +#define /*0x0F4*/ oHidden1UpNumTouchedTriggers OBJECT_FIELD_S32(0x1B) /* Activated Back and Forth Platform */ #define /*0x0F4*/ oActivatedBackAndForthPlatformMaxOffset OBJECT_FIELD_F32(0x1B) @@ -278,7 +278,7 @@ #define /*0x0F4*/ oBowserStatus OBJECT_FIELD_S32(0x1B) #define /*0x0F8*/ oBowserTimer OBJECT_FIELD_S32(0x1C) #define /*0x0FC*/ oBowserDistToCenter OBJECT_FIELD_F32(0x1D) -#define /*0x106*/ oBowserBitsJustJump OBJECT_FIELD_S16(0x1F, 1) +#define /*0x106*/ oBowserBitSJustJump OBJECT_FIELD_S16(0x1F, 1) #define /*0x108*/ oBowserRandSplitFloor OBJECT_FIELD_S16(0x20, 0) #define /*0x10A*/ oBowserHeldAnglePitch OBJECT_FIELD_S16(0x20, 1) #define /*0x10D*/ oBowserHeldAngleVelYaw OBJECT_FIELD_S16(0x21, 0) @@ -398,11 +398,11 @@ #define /*0x1AC*/ oCloudFwooshMovementRadius OBJECT_FIELD_S16(0x49, 0) /* Coin */ -#define /*0x0F4*/ oCoinUnkF4 OBJECT_FIELD_S32(0x1B) -#define /*0x0F8*/ oCoinUnkF8 OBJECT_FIELD_S32(0x1C) -#define /*0x110*/ oCoinUnk110 OBJECT_FIELD_F32(0x22) +#define /*0x0F4*/ oCoinCollectedFlags OBJECT_FIELD_S32(0x1B) +#define /*0x0F8*/ oCoinOnGround OBJECT_FIELD_S32(0x1C) +#define /*0x110*/ oCoinBaseVelY OBJECT_FIELD_F32(0x22) #ifndef VERSION_JP -#define /*0x1B0*/ oCoinUnk1B0 OBJECT_FIELD_S32(0x4A) +#define /*0x1B0*/ oCoinNumBounceSoundPlayed OBJECT_FIELD_S32(0x4A) #endif /* Collision Particle */ @@ -569,7 +569,7 @@ #define /*0x0F4*/ oHeaveHoUnkF4 OBJECT_FIELD_F32(0x1B) /* Hidden Object */ -#define /*0x0F4*/ oHiddenObjectUnkF4 OBJECT_FIELD_OBJ(0x1B) +#define /*0x0F4*/ oHiddenObjectPurpleSwitch OBJECT_FIELD_OBJ(0x1B) /* Hoot */ #define /*0x0F4*/ oHootAvailability OBJECT_FIELD_S32(0x1B) @@ -724,8 +724,8 @@ #define /*0x0FC*/ oRespawnerBehaviorToRespawn OBJECT_FIELD_CVPTR(0x1D) /* Openable Grill */ -#define /*0x088*/ oOpenableGrillUnk88 OBJECT_FIELD_S32(0x00) -#define /*0x0F4*/ oOpenableGrillUnkF4 OBJECT_FIELD_OBJ(0x1B) +#define /*0x088*/ oOpenableGrillUnk88 OBJECT_FIELD_S32(0x00) +#define /*0x0F4*/ oOpenableGrillPurpleSwitch OBJECT_FIELD_OBJ(0x1B) /* Intro Cutscene Peach */ #define /*0x108*/ oIntroPeachYawFromFocus OBJECT_FIELD_F32(0x20) @@ -770,12 +770,12 @@ #define /*0x0F8*/ oPitouneUnkF8 OBJECT_FIELD_F32(0x1C) #define /*0x0FC*/ oPitouneUnkFC OBJECT_FIELD_F32(0x1D) -/* Falling Rising Bitfs Platform */ -#define /*0x0F4*/ oBitfsPlatformTimer OBJECT_FIELD_S32(0x1B) +/* Falling Rising BitFS Platform */ +#define /*0x0F4*/ oBitFSPlatformTimer OBJECT_FIELD_S32(0x1B) -/* Falling Bowser Bits Platform */ -#define /*0x0F8*/ oBitsPlatformBowser OBJECT_FIELD_OBJ(0x1C) -#define /*0x0FC*/ oBitsPlatformTimer OBJECT_FIELD_S32(0x1D) +/* Falling Bowser BitS Platform */ +#define /*0x0F8*/ oBitSPlatformBowser OBJECT_FIELD_OBJ(0x1C) +#define /*0x0FC*/ oBitSPlatformTimer OBJECT_FIELD_S32(0x1D) /* WF Platform */ #define /*0x10C*/ oPlatformUnk10C OBJECT_FIELD_F32(0x21) @@ -831,10 +831,10 @@ /* Rolling Log */ #define /*0x0F4*/ oRollingLogUnkF4 OBJECT_FIELD_F32(0x1B) -/* Lll Rotating Hex Flame */ -#define /*0x0F4*/ oLllRotatingHexFlameUnkF4 OBJECT_FIELD_F32(0x1B) -#define /*0x0F8*/ oLllRotatingHexFlameUnkF8 OBJECT_FIELD_F32(0x1C) -#define /*0x0FC*/ oLllRotatingHexFlameUnkFC OBJECT_FIELD_F32(0x1D) +/* LLL Rotating Hex Flame */ +#define /*0x0F4*/ oLLLRotatingHexFlameUnkF4 OBJECT_FIELD_F32(0x1B) +#define /*0x0F8*/ oLLLRotatingHexFlameUnkF8 OBJECT_FIELD_F32(0x1C) +#define /*0x0FC*/ oLLLRotatingHexFlameUnkFC OBJECT_FIELD_F32(0x1D) /* Scuttlebug */ #define /*0x0F4*/ oScuttlebugUnkF4 OBJECT_FIELD_S32(0x1B) @@ -863,10 +863,10 @@ #define /*0x100*/ oSkeeterWaitTime OBJECT_FIELD_S32(0x1E) #define /*0x1AC*/ oSkeeterUnk1AC OBJECT_FIELD_S16(0x49, 0) -/* Jrb Sliding Box */ -#define /*0x0F4*/ oJrbSlidingBoxUnkF4 OBJECT_FIELD_OBJ(0x1B) -#define /*0x0F8*/ oJrbSlidingBoxUnkF8 OBJECT_FIELD_S32(0x1C) -#define /*0x0FC*/ oJrbSlidingBoxUnkFC OBJECT_FIELD_F32(0x1D) +/* JRB Sliding Box */ +#define /*0x0F4*/ oJRBSlidingBoxUnkF4 OBJECT_FIELD_OBJ(0x1B) +#define /*0x0F8*/ oJRBSlidingBoxUnkF8 OBJECT_FIELD_S32(0x1C) +#define /*0x0FC*/ oJRBSlidingBoxUnkFC OBJECT_FIELD_F32(0x1D) /* WF Sliding Brick Platform */ #define /*0x0F4*/ oWFSlidBrickPtfmMovVel OBJECT_FIELD_F32(0x1B) @@ -952,8 +952,8 @@ #define /*0x0F8*/ oSwoopTargetPitch OBJECT_FIELD_S32(0x1C) #define /*0x0FC*/ oSwoopTargetYaw OBJECT_FIELD_S32(0x1D) -/* Thwomp */ -#define /*0x0F4*/ oThwompRandomTimer OBJECT_FIELD_S32(0x1B) +/* Grindel or Thwomp */ +#define /*0x0F4*/ oGrindelThwompRandomTimer OBJECT_FIELD_S32(0x1B) /* Tilting Platform */ #define /*0x0F4*/ oTiltingPyramidNormalX OBJECT_FIELD_F32(0x1B) @@ -962,13 +962,13 @@ #define /*0x10C*/ oTiltingPyramidMarioOnPlatform OBJECT_FIELD_S32(0x21) /* Toad Message */ -#define /*0x108*/ oToadMessageDialogId OBJECT_FIELD_U32(0x20) +#define /*0x108*/ oToadMessageDialogID OBJECT_FIELD_U32(0x20) #define /*0x10C*/ oToadMessageRecentlyTalked OBJECT_FIELD_S32(0x21) #define /*0x110*/ oToadMessageState OBJECT_FIELD_S32(0x22) /* Tox Box */ -#define /*0x1AC*/ oToxBoxMovementPattern OBJECT_FIELD_VPTR(0x49) -#define /*0x1B0*/ oToxBoxMovementStep OBJECT_FIELD_S32(0x4A) +#define /*0x1AC*/ oToxBoxActionTable OBJECT_FIELD_VPTR(0x49) +#define /*0x1B0*/ oToxBoxActionStep OBJECT_FIELD_S32(0x4A) /* TTC Rotating Solid */ #define /*0x0F4*/ oTTCRotatingSolidNumTurns OBJECT_FIELD_S32(0x1B) @@ -1033,7 +1033,7 @@ #define /*0x0F8*/ oTreasureChestUnkF8 OBJECT_FIELD_S32(0x1C) #define /*0x0FC*/ oTreasureChestUnkFC OBJECT_FIELD_S32(0x1D) -/* Tree Snow Or Leaf */ +/* Tree Snow or Leaf */ #define /*0x0F4*/ oTreeSnowOrLeafUnkF4 OBJECT_FIELD_S32(0x1B) #define /*0x0F8*/ oTreeSnowOrLeafUnkF8 OBJECT_FIELD_S32(0x1C) #define /*0x0FC*/ oTreeSnowOrLeafUnkFC OBJECT_FIELD_S32(0x1D) @@ -1146,8 +1146,8 @@ #define /*0x1AC*/ oWigglerUnused OBJECT_FIELD_S16(0x49, 0) #define /*0x1AE*/ oWigglerTextStatus OBJECT_FIELD_S16(0x49, 1) -/* Lll Wood Piece */ -#define /*0x0F4*/ oLllWoodPieceOscillationTimer OBJECT_FIELD_S32(0x1B) +/* LLL Wood Piece */ +#define /*0x0F4*/ oLLLWoodPieceOscillationTimer OBJECT_FIELD_S32(0x1B) /* Wooden Post */ #define /*0x0F4*/ oWoodenPostTotalMarioAngle OBJECT_FIELD_S32(0x1B) diff --git a/include/segment_symbols.h b/include/segment_symbols.h index 22b37131..73cdd7e1 100644 --- a/include/segment_symbols.h +++ b/include/segment_symbols.h @@ -40,8 +40,15 @@ DECLARE_SEGMENT(engine) DECLARE_SEGMENT(behavior) DECLARE_SEGMENT(scripts) DECLARE_SEGMENT(goddard) + extern u8 _goddardSegmentStart[]; +#ifdef USE_EXT_RAM +extern u8 _engineSegmentStart[]; +extern u8 _framebuffersSegmentNoloadStart[]; +extern u8 _framebuffersSegmentNoloadEnd[]; +#endif + DECLARE_LEVEL_SEGMENT(menu) DECLARE_LEVEL_SEGMENT(intro) DECLARE_LEVEL_SEGMENT(ending) diff --git a/include/segments.h b/include/segments.h index a97d6ee8..65f1fc46 100644 --- a/include/segments.h +++ b/include/segments.h @@ -13,30 +13,29 @@ * linker script syntax. */ +#define SEG_START 0x8005C000 + +#define SEG_FRAMEBUFFERS_SIZE (2 * SCREEN_WIDTH * SCREEN_HEIGHT * 3) +#define SEG_GODDARD_POOL_OFFSET 0x52000 // Offset from right side of pool +#define SEG_GODDARD (SEG_POOL_END - SEG_GODDARD_POOL_OFFSET) + #ifndef USE_EXT_RAM /* Default: Runs out of memory quickly when importing custom assets. */ -#define SEG_POOL_START 0x8005C000 -#define SEG_POOL_END SEG_BUFFERS +#define RDRAM_END 0x80400000 -#define SEG_GODDARD 0x8016F000 +#define SEG_POOL_START SEG_START +#define SEG_POOL_SIZE 0x165000 +#define SEG_POOL_END (SEG_POOL_START + SEG_POOL_SIZE) -#define SEG_BUFFERS 0x801C1000 - -#if defined(VERSION_SH) || ENABLE_RUMBLE -#define SEG_MAIN 0x80249000 -#elif defined(VERSION_EU) -#define SEG_MAIN 0x80241800 // TODO: Investigate why it's different? -#else -#define SEG_MAIN 0x80246000 -#endif +#define SEG_BUFFERS SEG_POOL_END #ifdef VERSION_EU -#define SEG_ENGINE 0x8036FF00 +#define SEG_ENGINE 0x8036FF00 #else -#define SEG_ENGINE 0x80378800 +#define SEG_ENGINE 0x80378800 #endif -#define SEG_FRAMEBUFFERS 0x8038F800 +#define SEG_FRAMEBUFFERS (RDRAM_END - SEG_FRAMEBUFFERS_SIZE) #else /* Use Expansion Pak space for pool. */ @@ -45,14 +44,19 @@ * importing large custom content. */ -#define SEG_BUFFERS 0x8005C000 // 0x0085000 in size -#define SEG_MAIN 0x800E1000 // 0x0132800 in size -#define SEG_ENGINE 0x80213800 // 0x0017000 in size -#define SEG_FRAMEBUFFERS 0x8022A800 // 0x0070800 in size -#define SEG_POOL_START 0x8029B000 // 0x0165000 in size -#define SEG_POOL_END 0x80800000 -#define SEG_POOL_END_4MB 0x80400000 // For the error message screen enhancement. -#define SEG_GODDARD SEG_POOL_START + 0x113000 +#ifdef VERSION_CN +#define RDRAM_END 0x807C0000 // iQue has stuff like EEPROM mapped at 807C0000 onwards. TODO: Code this using osMemSize +#else +#define RDRAM_END 0x80800000 +#endif + +#define SEG_BUFFERS SEG_START +#define SEG_ENGINE ((u32) &_engineSegmentStart) +#define SEG_FRAMEBUFFERS ((u32) &_framebuffersSegmentNoloadStart) +#define SEG_POOL_START ((u32) &_framebuffersSegmentNoloadEnd) +#define SEG_POOL_END RDRAM_END +#define SEG_POOL_END_4MB 0x80400000 // For the error message screen enhancement. + #endif #endif // SEGMENTS_H diff --git a/include/seq_macros.inc b/include/seq_macros.inc index d73d9923..84bde56b 100644 --- a/include/seq_macros.inc +++ b/include/seq_macros.inc @@ -155,7 +155,7 @@ .byte 0xff .endm -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) .macro seq_unreservenotes .byte 0xf0 @@ -462,7 +462,7 @@ var_long \a .endm -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) .macro chan_setnotepriority a .byte 0xe9 diff --git a/include/sounds.h b/include/sounds.h index 71709c90..dd199980 100644 --- a/include/sounds.h +++ b/include/sounds.h @@ -98,7 +98,7 @@ /** * The table below defines all sounds that exist in the game, and which flags * they are used with. If a sound is used with multiple sets of flags (e.g. - * different priorities), they are gives distinguishing suffixes. + * different priorities), they are given distinguishing suffixes. * A _2 suffix means the sound is the same despite a different sound ID. */ diff --git a/include/special_preset_names.h b/include/special_preset_names.h deleted file mode 100644 index 229d2878..00000000 --- a/include/special_preset_names.h +++ /dev/null @@ -1,93 +0,0 @@ -#ifndef SPECIAL_PRESET_NAMES_H -#define SPECIAL_PRESET_NAMES_H - -enum SpecialPresets { - special_null_start, - special_yellow_coin, - special_yellow_coin_2, - special_unknown_3, - special_boo, - special_unknown_5, - special_lll_moving_octagonal_mesh_platform, - special_snow_ball, - special_lll_drawbridge_spawner, - special_empty_9, - special_lll_rotating_block_with_fire_bars, - special_lll_floating_wood_bridge, - special_tumbling_platform, - special_lll_rotating_hexagonal_ring, - special_lll_sinking_rectangular_platform, - special_lll_sinking_square_platforms, - special_lll_tilting_square_platform, - special_lll_bowser_puzzle, - special_mr_i, - special_small_bully, - special_big_bully, - special_empty_21, - special_empty_22, - special_empty_23, - special_empty_24, - special_empty_25, - special_moving_blue_coin, - special_jrb_chest, - special_water_ring, - special_mine, - special_empty_30, - special_empty_31, - special_butterfly, - special_bowser, - special_wf_rotating_wooden_platform, - special_small_bomp, - special_wf_sliding_platform, - special_tower_platform_group, - special_rotating_counter_clockwise, - special_wf_tumbling_bridge, - special_large_bomp, - - special_level_geo_03 = 0x65, - special_level_geo_04, - special_level_geo_05, - special_level_geo_06, - special_level_geo_07, - special_level_geo_08, - special_level_geo_09, - special_level_geo_0A, - special_level_geo_0B, - special_level_geo_0C, - special_level_geo_0D, - special_level_geo_0E, - special_level_geo_0F, - special_level_geo_10, - special_level_geo_11, - special_level_geo_12, - special_level_geo_13, - special_level_geo_14, - special_level_geo_15, - special_level_geo_16, - special_bubble_tree, - special_spiky_tree, - special_snow_tree, - special_unknown_tree, - special_palm_tree, - special_wooden_door, - special_haunted_door = special_wooden_door, - special_unknown_door, - special_metal_door, - special_hmc_door, - special_unknown2_door, - special_wooden_door_warp, - special_unknown1_door_warp, - special_metal_door_warp, - special_unknown2_door_warp, - special_unknown3_door_warp, - special_castle_door_warp, - special_castle_door, - special_0stars_door, - special_1star_door, - special_3star_door, - special_key_door, - - special_null_end = 0xFF -}; - -#endif // SPECIAL_PRESET_NAMES_H diff --git a/include/special_presets.h b/include/special_presets.h index 9e2e1853..bbf7551c 100644 --- a/include/special_presets.h +++ b/include/special_presets.h @@ -1,111 +1,93 @@ #ifndef SPECIAL_PRESETS_H #define SPECIAL_PRESETS_H -#include "special_preset_names.h" -#include "behavior_data.h" -#include "model_ids.h" +enum SpecialPresets { + special_null_start, + special_yellow_coin, + special_yellow_coin_2, + special_unknown_3, + special_boo, + special_unknown_5, + special_lll_moving_octagonal_mesh_platform, + special_snow_ball, + special_lll_drawbridge_spawner, + special_empty_9, + special_lll_rotating_block_with_fire_bars, + special_lll_floating_wood_bridge, + special_tumbling_platform, + special_lll_rotating_hexagonal_ring, + special_lll_sinking_rectangular_platform, + special_lll_sinking_square_platforms, + special_lll_tilting_square_platform, + special_lll_bowser_puzzle, + special_mr_i, + special_small_bully, + special_big_bully, + special_empty_21, + special_empty_22, + special_empty_23, + special_empty_24, + special_empty_25, + special_moving_blue_coin, + special_jrb_chest, + special_water_ring, + special_mine, + special_empty_30, + special_empty_31, + special_butterfly, + special_bowser, + special_wf_rotating_wooden_platform, + special_small_bomp, + special_wf_sliding_platform, + special_tower_platform_group, + special_rotating_counter_clockwise, + special_wf_tumbling_bridge, + special_large_bomp, -// Special Preset types -#define SPTYPE_NO_YROT_OR_PARAMS 0 // object is 8-bytes long, no y-rotation or any behavior params -#define SPTYPE_YROT_NO_PARAMS 1 // object is 10-bytes long, has y-rotation but no params -#define SPTYPE_PARAMS_AND_YROT 2 // object is 12-bytes long, has y-rotation and params -#define SPTYPE_UNKNOWN 3 // object is 14-bytes long, has 3 extra shorts that get converted to floats. -#define SPTYPE_DEF_PARAM_AND_YROT 4 // object is 10-bytes long, has y-rotation and uses the default param + special_level_geo_03 = 0x65, + special_level_geo_04, + special_level_geo_05, + special_level_geo_06, + special_level_geo_07, + special_level_geo_08, + special_level_geo_09, + special_level_geo_0A, + special_level_geo_0B, + special_level_geo_0C, + special_level_geo_0D, + special_level_geo_0E, + special_level_geo_0F, + special_level_geo_10, + special_level_geo_11, + special_level_geo_12, + special_level_geo_13, + special_level_geo_14, + special_level_geo_15, + special_level_geo_16, + special_bubble_tree, + special_spiky_tree, + special_snow_tree, + special_unknown_tree, + special_palm_tree, + special_wooden_door, + special_haunted_door = special_wooden_door, + special_unknown_door, + special_metal_door, + special_hmc_door, + special_unknown2_door, + special_wooden_door_warp, + special_unknown1_door_warp, + special_metal_door_warp, + special_unknown2_door_warp, + special_unknown3_door_warp, + special_castle_door_warp, + special_castle_door, + special_0stars_door, + special_1star_door, + special_3star_door, + special_key_door, -struct SpecialPreset { - /*00*/ u8 preset_id; - /*01*/ u8 type; // Determines whether object is 8, 10, 12 or 14 bytes long. - /*02*/ u8 defParam; // Default parameter, only used when type is SPTYPE_DEF_PARAM_AND_YROT - /*03*/ u8 model; - /*04*/ const BehaviorScript *behavior; -}; - -// Some Models ID's are missing their names because they are probably unused - -static struct SpecialPreset SpecialObjectPresets[] = { - {0x00, SPTYPE_YROT_NO_PARAMS , 0x00, MODEL_NONE, NULL}, - {0x01, SPTYPE_NO_YROT_OR_PARAMS , 0x00, MODEL_YELLOW_COIN, bhvYellowCoin}, - {0x02, SPTYPE_NO_YROT_OR_PARAMS , 0x00, MODEL_YELLOW_COIN, bhvYellowCoin}, - {0x03, SPTYPE_NO_YROT_OR_PARAMS , 0x00, MODEL_UNKNOWN_B8, bhvStaticObject}, - {0x04, SPTYPE_NO_YROT_OR_PARAMS , 0x00, MODEL_BOO, bhvCourtyardBooTriplet}, - {0x05, SPTYPE_NO_YROT_OR_PARAMS , 0x00, MODEL_UNKNOWN_AC, bhvCastleFloorTrap}, - {0x06, SPTYPE_NO_YROT_OR_PARAMS , 0x00, MODEL_LLL_MOVING_OCTAGONAL_MESH_PLATFORM, bhvLllMovingOctagonalMeshPlatform}, - {0x07, SPTYPE_NO_YROT_OR_PARAMS , 0x00, MODEL_CCM_SNOWMAN_HEAD, bhvSnowBall}, - {0x08, SPTYPE_YROT_NO_PARAMS , 0x00, MODEL_LLL_DRAWBRIDGE_PART, bhvLllDrawbridgeSpawner}, - {0x09, SPTYPE_NO_YROT_OR_PARAMS , 0x00, MODEL_NONE, bhvStaticObject}, - {0x0A, SPTYPE_NO_YROT_OR_PARAMS , 0x00, MODEL_LLL_ROTATING_BLOCK_FIRE_BARS, bhvLllRotatingBlockWithFireBars}, - {0x0B, SPTYPE_NO_YROT_OR_PARAMS , 0x00, MODEL_NONE, bhvLllFloatingWoodBridge}, - {0x0C, SPTYPE_NO_YROT_OR_PARAMS , 0x00, MODEL_NONE, bhvLllTumblingBridge}, - {0x0D, SPTYPE_NO_YROT_OR_PARAMS , 0x00, MODEL_LLL_ROTATING_HEXAGONAL_RING , bhvLllRotatingHexagonalRing}, - {0x0E, SPTYPE_YROT_NO_PARAMS , 0x00, MODEL_LLL_SINKING_RECTANGULAR_PLATFORM, bhvLllSinkingRectangularPlatform}, - {0x0F, SPTYPE_NO_YROT_OR_PARAMS , 0x00, MODEL_LLL_SINKING_SQUARE_PLATFORMS, bhvLllSinkingSquarePlatforms}, - {0x10, SPTYPE_NO_YROT_OR_PARAMS , 0x00, MODEL_LLL_TILTING_SQUARE_PLATFORM, bhvLllTiltingInvertedPyramid}, - {0x11, SPTYPE_NO_YROT_OR_PARAMS , 0x00, MODEL_NONE, bhvLllBowserPuzzle}, - {0x12, SPTYPE_NO_YROT_OR_PARAMS , 0x00, MODEL_NONE, bhvMrI}, - {0x13, SPTYPE_NO_YROT_OR_PARAMS , 0x00, MODEL_BULLY, bhvSmallBully}, - {0x14, SPTYPE_NO_YROT_OR_PARAMS , 0x00, MODEL_BULLY_BOSS, bhvBigBully}, - {0x15, SPTYPE_NO_YROT_OR_PARAMS , 0x00, MODEL_NONE, bhvStaticObject}, - {0x16, SPTYPE_NO_YROT_OR_PARAMS , 0x00, MODEL_NONE, bhvStaticObject}, - {0x17, SPTYPE_NO_YROT_OR_PARAMS , 0x00, MODEL_NONE, bhvStaticObject}, - {0x18, SPTYPE_NO_YROT_OR_PARAMS , 0x00, MODEL_NONE, bhvStaticObject}, - {0x19, SPTYPE_NO_YROT_OR_PARAMS , 0x00, MODEL_NONE, bhvStaticObject}, - {0x1A, SPTYPE_NO_YROT_OR_PARAMS , 0x00, MODEL_YELLOW_COIN, bhvMovingBlueCoin}, - {0x1B, SPTYPE_NO_YROT_OR_PARAMS , 0x00, MODEL_TREASURE_CHEST_BASE, bhvBetaChestBottom}, - {0x1C, SPTYPE_NO_YROT_OR_PARAMS , 0x00, MODEL_WATER_RING, bhvJetStreamRingSpawner}, - {0x1D, SPTYPE_NO_YROT_OR_PARAMS , 0x00, MODEL_WATER_MINE, bhvBowserBomb}, - {0x1E, SPTYPE_UNKNOWN , 0x00, MODEL_NONE, bhvStaticObject}, - {0x1F, SPTYPE_NO_YROT_OR_PARAMS , 0x00, MODEL_NONE, bhvStaticObject}, - {0x20, SPTYPE_NO_YROT_OR_PARAMS , 0x00, MODEL_BUTTERFLY, bhvButterfly}, - {0x21, SPTYPE_NO_YROT_OR_PARAMS , 0x00, MODEL_BOWSER, bhvBowser}, - {0x22, SPTYPE_NO_YROT_OR_PARAMS , 0x00, MODEL_WF_ROTATING_WOODEN_PLATFORM, bhvWfRotatingWoodenPlatform}, - {0x23, SPTYPE_YROT_NO_PARAMS , 0x00, MODEL_WF_SMALL_BOMP, bhvSmallBomp}, - {0x24, SPTYPE_YROT_NO_PARAMS , 0x00, MODEL_WF_SLIDING_PLATFORM, bhvWfSlidingPlatform}, - {0x25, SPTYPE_NO_YROT_OR_PARAMS , 0x00, MODEL_NONE, bhvTowerPlatformGroup}, - {0x26, SPTYPE_NO_YROT_OR_PARAMS , 0x00, MODEL_NONE, bhvRotatingCounterClockwise}, - {0x27, SPTYPE_NO_YROT_OR_PARAMS , 0x00, MODEL_WF_TUMBLING_BRIDGE, bhvWfTumblingBridge}, - {0x28, SPTYPE_NO_YROT_OR_PARAMS , 0x00, MODEL_WF_LARGE_BOMP, bhvLargeBomp}, - {0x65, SPTYPE_YROT_NO_PARAMS , 0x00, MODEL_LEVEL_GEOMETRY_03, bhvStaticObject}, - {0x66, SPTYPE_YROT_NO_PARAMS , 0x00, MODEL_LEVEL_GEOMETRY_04, bhvStaticObject}, - {0x67, SPTYPE_YROT_NO_PARAMS , 0x00, MODEL_LEVEL_GEOMETRY_05, bhvStaticObject}, - {0x68, SPTYPE_YROT_NO_PARAMS , 0x00, MODEL_LEVEL_GEOMETRY_06, bhvStaticObject}, - {0x69, SPTYPE_YROT_NO_PARAMS , 0x00, MODEL_LEVEL_GEOMETRY_07, bhvStaticObject}, - {0x6A, SPTYPE_YROT_NO_PARAMS , 0x00, MODEL_LEVEL_GEOMETRY_08, bhvStaticObject}, - {0x6B, SPTYPE_YROT_NO_PARAMS , 0x00, MODEL_LEVEL_GEOMETRY_09, bhvStaticObject}, - {0x6C, SPTYPE_YROT_NO_PARAMS , 0x00, MODEL_LEVEL_GEOMETRY_0A, bhvStaticObject}, - {0x6D, SPTYPE_YROT_NO_PARAMS , 0x00, MODEL_LEVEL_GEOMETRY_0B, bhvStaticObject}, - {0x6E, SPTYPE_YROT_NO_PARAMS , 0x00, MODEL_LEVEL_GEOMETRY_0C, bhvStaticObject}, - {0x6F, SPTYPE_YROT_NO_PARAMS , 0x00, MODEL_LEVEL_GEOMETRY_0D, bhvStaticObject}, - {0x70, SPTYPE_YROT_NO_PARAMS , 0x00, MODEL_LEVEL_GEOMETRY_0E, bhvStaticObject}, - {0x71, SPTYPE_YROT_NO_PARAMS , 0x00, MODEL_LEVEL_GEOMETRY_0F, bhvStaticObject}, - {0x72, SPTYPE_YROT_NO_PARAMS , 0x00, MODEL_LEVEL_GEOMETRY_10, bhvStaticObject}, - {0x73, SPTYPE_YROT_NO_PARAMS , 0x00, MODEL_LEVEL_GEOMETRY_11, bhvStaticObject}, - {0x74, SPTYPE_YROT_NO_PARAMS , 0x00, MODEL_LEVEL_GEOMETRY_12, bhvStaticObject}, - {0x75, SPTYPE_YROT_NO_PARAMS , 0x00, MODEL_LEVEL_GEOMETRY_13, bhvStaticObject}, - {0x76, SPTYPE_YROT_NO_PARAMS , 0x00, MODEL_LEVEL_GEOMETRY_14, bhvStaticObject}, - {0x77, SPTYPE_YROT_NO_PARAMS , 0x00, MODEL_LEVEL_GEOMETRY_15, bhvStaticObject}, - {0x78, SPTYPE_YROT_NO_PARAMS , 0x00, MODEL_LEVEL_GEOMETRY_16, bhvStaticObject}, - {0x79, SPTYPE_NO_YROT_OR_PARAMS , 0x00, MODEL_BOB_BUBBLY_TREE, bhvTree}, - {0x7A, SPTYPE_NO_YROT_OR_PARAMS , 0x00, MODEL_COURTYARD_SPIKY_TREE, bhvTree}, - {0x7B, SPTYPE_NO_YROT_OR_PARAMS , 0x00, MODEL_CCM_SNOW_TREE, bhvTree}, - {0x7C, SPTYPE_NO_YROT_OR_PARAMS , 0x00, MODEL_UNKNOWN_TREE_1A, bhvTree}, - {0x7D, SPTYPE_NO_YROT_OR_PARAMS , 0x00, MODEL_SSL_PALM_TREE, bhvTree}, - {0x89, SPTYPE_YROT_NO_PARAMS , 0x00, MODEL_CASTLE_CASTLE_DOOR_UNUSED, bhvDoor}, - {0x7E, SPTYPE_YROT_NO_PARAMS , 0x00, MODEL_CASTLE_WOODEN_DOOR_UNUSED, bhvDoor}, - {0x7F, SPTYPE_YROT_NO_PARAMS , 0x00, MODEL_UNKNOWN_DOOR_1E, bhvDoor}, - {0x80, SPTYPE_YROT_NO_PARAMS , 0x00, MODEL_HMC_METAL_DOOR, bhvDoor}, - {0x81, SPTYPE_YROT_NO_PARAMS , 0x00, MODEL_HMC_HAZY_MAZE_DOOR, bhvDoor}, - {0x82, SPTYPE_YROT_NO_PARAMS , 0x00, MODEL_UNKNOWN_DOOR_21, bhvDoor}, - {0x8A, SPTYPE_DEF_PARAM_AND_YROT, 0x00, MODEL_CASTLE_DOOR_0_STARS, bhvDoor}, - {0x8B, SPTYPE_DEF_PARAM_AND_YROT, 0x01, MODEL_CASTLE_DOOR_1_STAR, bhvDoor}, - {0x8C, SPTYPE_DEF_PARAM_AND_YROT, 0x03, MODEL_CASTLE_DOOR_3_STARS, bhvDoor}, - {0x8D, SPTYPE_DEF_PARAM_AND_YROT, 0x00, MODEL_CASTLE_KEY_DOOR, bhvDoor}, - {0x88, SPTYPE_PARAMS_AND_YROT , 0x00, MODEL_CASTLE_CASTLE_DOOR, bhvDoorWarp}, - {0x83, SPTYPE_PARAMS_AND_YROT , 0x00, MODEL_CASTLE_WOODEN_DOOR, bhvDoorWarp}, - {0x84, SPTYPE_PARAMS_AND_YROT , 0x00, MODEL_UNKNOWN_DOOR_28, bhvDoorWarp}, - {0x85, SPTYPE_PARAMS_AND_YROT , 0x00, MODEL_CASTLE_METAL_DOOR, bhvDoorWarp}, - {0x86, SPTYPE_PARAMS_AND_YROT , 0x00, MODEL_UNKNOWN_DOOR_2A, bhvDoorWarp}, - {0x87, SPTYPE_PARAMS_AND_YROT , 0x00, MODEL_UNKNOWN_DOOR_2B, bhvDoorWarp}, - {0xFF, SPTYPE_NO_YROT_OR_PARAMS , 0x00, MODEL_NONE, NULL} + special_null_end = 0xFF }; #endif // SPECIAL_PRESETS_H diff --git a/include/special_presets.inc.c b/include/special_presets.inc.c new file mode 100644 index 00000000..b9a0220d --- /dev/null +++ b/include/special_presets.inc.c @@ -0,0 +1,104 @@ +#include "special_presets.h" + +// Special Preset types +#define SPTYPE_NO_YROT_OR_PARAMS 0 // object is 8-bytes long, no y-rotation or any behavior params +#define SPTYPE_YROT_NO_PARAMS 1 // object is 10-bytes long, has y-rotation but no params +#define SPTYPE_PARAMS_AND_YROT 2 // object is 12-bytes long, has y-rotation and params +#define SPTYPE_UNKNOWN 3 // object is 14-bytes long, has 3 extra shorts that get converted to floats. +#define SPTYPE_DEF_PARAM_AND_YROT 4 // object is 10-bytes long, has y-rotation and uses the default param + +struct SpecialPreset { + /* 0x00 */ u8 presetID; + /* 0x01 */ u8 type; // Determines whether object is 8, 10, 12 or 14 bytes long. + /* 0x02 */ u8 defParam; // Default parameter, only used when type is SPTYPE_DEF_PARAM_AND_YROT + /* 0x03 */ u8 model; + /* 0x04 */ const BehaviorScript *behavior; +}; + +// Some Models ID's are missing their names because they are probably unused + +static struct SpecialPreset sSpecialObjectPresets[] = { + { special_null_start, SPTYPE_YROT_NO_PARAMS, 0x00, MODEL_NONE, NULL }, + { special_yellow_coin, SPTYPE_NO_YROT_OR_PARAMS, 0x00, MODEL_YELLOW_COIN, bhvYellowCoin }, + { special_yellow_coin_2, SPTYPE_NO_YROT_OR_PARAMS, 0x00, MODEL_YELLOW_COIN, bhvYellowCoin }, + { special_unknown_3, SPTYPE_NO_YROT_OR_PARAMS, 0x00, MODEL_UNKNOWN_B8, bhvStaticObject }, + { special_boo, SPTYPE_NO_YROT_OR_PARAMS, 0x00, MODEL_BOO, bhvCourtyardBooTriplet }, + { special_unknown_5, SPTYPE_NO_YROT_OR_PARAMS, 0x00, MODEL_UNKNOWN_AC, bhvCastleFloorTrap }, + { special_lll_moving_octagonal_mesh_platform, SPTYPE_NO_YROT_OR_PARAMS, 0x00, MODEL_LLL_MOVING_OCTAGONAL_MESH_PLATFORM, bhvLLLMovingOctagonalMeshPlatform }, + { special_snow_ball, SPTYPE_NO_YROT_OR_PARAMS, 0x00, MODEL_CCM_SNOWMAN_HEAD, bhvSnowBall }, + { special_lll_drawbridge_spawner, SPTYPE_YROT_NO_PARAMS, 0x00, MODEL_LLL_DRAWBRIDGE_PART, bhvLLLDrawbridgeSpawner }, + { special_empty_9, SPTYPE_NO_YROT_OR_PARAMS, 0x00, MODEL_NONE, bhvStaticObject }, + { special_lll_rotating_block_with_fire_bars, SPTYPE_NO_YROT_OR_PARAMS, 0x00, MODEL_LLL_ROTATING_BLOCK_FIRE_BARS, bhvLLLRotatingBlockWithFireBars }, + { special_lll_floating_wood_bridge, SPTYPE_NO_YROT_OR_PARAMS, 0x00, MODEL_NONE, bhvLLLFloatingWoodBridge }, + { special_tumbling_platform, SPTYPE_NO_YROT_OR_PARAMS, 0x00, MODEL_NONE, bhvLLLTumblingBridge }, + { special_lll_rotating_hexagonal_ring, SPTYPE_NO_YROT_OR_PARAMS, 0x00, MODEL_LLL_ROTATING_HEXAGONAL_RING , bhvLLLRotatingHexagonalRing }, + { special_lll_sinking_rectangular_platform, SPTYPE_YROT_NO_PARAMS, 0x00, MODEL_LLL_SINKING_RECTANGULAR_PLATFORM, bhvLLLSinkingRectangularPlatform }, + { special_lll_sinking_square_platforms, SPTYPE_NO_YROT_OR_PARAMS, 0x00, MODEL_LLL_SINKING_SQUARE_PLATFORMS, bhvLLLSinkingSquarePlatforms }, + { special_lll_tilting_square_platform, SPTYPE_NO_YROT_OR_PARAMS, 0x00, MODEL_LLL_TILTING_SQUARE_PLATFORM, bhvLLLTiltingInvertedPyramid }, + { special_lll_bowser_puzzle, SPTYPE_NO_YROT_OR_PARAMS, 0x00, MODEL_NONE, bhvLLLBowserPuzzle }, + { special_mr_i, SPTYPE_NO_YROT_OR_PARAMS, 0x00, MODEL_NONE, bhvMrI }, + { special_small_bully, SPTYPE_NO_YROT_OR_PARAMS, 0x00, MODEL_BULLY, bhvSmallBully }, + { special_big_bully, SPTYPE_NO_YROT_OR_PARAMS, 0x00, MODEL_BULLY_BOSS, bhvBigBully }, + { special_empty_21, SPTYPE_NO_YROT_OR_PARAMS, 0x00, MODEL_NONE, bhvStaticObject }, + { special_empty_22, SPTYPE_NO_YROT_OR_PARAMS, 0x00, MODEL_NONE, bhvStaticObject }, + { special_empty_23, SPTYPE_NO_YROT_OR_PARAMS, 0x00, MODEL_NONE, bhvStaticObject }, + { special_empty_24, SPTYPE_NO_YROT_OR_PARAMS, 0x00, MODEL_NONE, bhvStaticObject }, + { special_empty_25, SPTYPE_NO_YROT_OR_PARAMS, 0x00, MODEL_NONE, bhvStaticObject }, + { special_moving_blue_coin, SPTYPE_NO_YROT_OR_PARAMS, 0x00, MODEL_YELLOW_COIN, bhvMovingBlueCoin }, + { special_jrb_chest, SPTYPE_NO_YROT_OR_PARAMS, 0x00, MODEL_TREASURE_CHEST_BASE, bhvBetaChestBottom }, + { special_water_ring, SPTYPE_NO_YROT_OR_PARAMS, 0x00, MODEL_WATER_RING, bhvJetStreamRingSpawner }, + { special_mine, SPTYPE_NO_YROT_OR_PARAMS, 0x00, MODEL_WATER_MINE, bhvBowserBomb }, + { special_empty_30, SPTYPE_UNKNOWN, 0x00, MODEL_NONE, bhvStaticObject }, + { special_empty_31, SPTYPE_NO_YROT_OR_PARAMS, 0x00, MODEL_NONE, bhvStaticObject }, + { special_butterfly, SPTYPE_NO_YROT_OR_PARAMS, 0x00, MODEL_BUTTERFLY, bhvButterfly }, + { special_bowser, SPTYPE_NO_YROT_OR_PARAMS, 0x00, MODEL_BOWSER, bhvBowser }, + { special_wf_rotating_wooden_platform, SPTYPE_NO_YROT_OR_PARAMS, 0x00, MODEL_WF_ROTATING_WOODEN_PLATFORM, bhvWFRotatingWoodenPlatform }, + { special_small_bomp, SPTYPE_YROT_NO_PARAMS, 0x00, MODEL_WF_SMALL_BOMP, bhvSmallBomp }, + { special_wf_sliding_platform, SPTYPE_YROT_NO_PARAMS, 0x00, MODEL_WF_SLIDING_PLATFORM, bhvWFSlidingPlatform }, + { special_tower_platform_group, SPTYPE_NO_YROT_OR_PARAMS, 0x00, MODEL_NONE, bhvTowerPlatformGroup }, + { special_rotating_counter_clockwise, SPTYPE_NO_YROT_OR_PARAMS, 0x00, MODEL_NONE, bhvRotatingCounterClockwise }, + { special_wf_tumbling_bridge, SPTYPE_NO_YROT_OR_PARAMS, 0x00, MODEL_WF_TUMBLING_BRIDGE, bhvTumblingBridge }, + { special_large_bomp, SPTYPE_NO_YROT_OR_PARAMS, 0x00, MODEL_WF_LARGE_BOMP, bhvLargeBomp }, + { special_level_geo_03, SPTYPE_YROT_NO_PARAMS, 0x00, MODEL_LEVEL_GEOMETRY_03, bhvStaticObject }, + { special_level_geo_04, SPTYPE_YROT_NO_PARAMS, 0x00, MODEL_LEVEL_GEOMETRY_04, bhvStaticObject }, + { special_level_geo_05, SPTYPE_YROT_NO_PARAMS, 0x00, MODEL_LEVEL_GEOMETRY_05, bhvStaticObject }, + { special_level_geo_06, SPTYPE_YROT_NO_PARAMS, 0x00, MODEL_LEVEL_GEOMETRY_06, bhvStaticObject }, + { special_level_geo_07, SPTYPE_YROT_NO_PARAMS, 0x00, MODEL_LEVEL_GEOMETRY_07, bhvStaticObject }, + { special_level_geo_08, SPTYPE_YROT_NO_PARAMS, 0x00, MODEL_LEVEL_GEOMETRY_08, bhvStaticObject }, + { special_level_geo_09, SPTYPE_YROT_NO_PARAMS, 0x00, MODEL_LEVEL_GEOMETRY_09, bhvStaticObject }, + { special_level_geo_0A, SPTYPE_YROT_NO_PARAMS, 0x00, MODEL_LEVEL_GEOMETRY_0A, bhvStaticObject }, + { special_level_geo_0B, SPTYPE_YROT_NO_PARAMS, 0x00, MODEL_LEVEL_GEOMETRY_0B, bhvStaticObject }, + { special_level_geo_0C, SPTYPE_YROT_NO_PARAMS, 0x00, MODEL_LEVEL_GEOMETRY_0C, bhvStaticObject }, + { special_level_geo_0D, SPTYPE_YROT_NO_PARAMS, 0x00, MODEL_LEVEL_GEOMETRY_0D, bhvStaticObject }, + { special_level_geo_0E, SPTYPE_YROT_NO_PARAMS, 0x00, MODEL_LEVEL_GEOMETRY_0E, bhvStaticObject }, + { special_level_geo_0F, SPTYPE_YROT_NO_PARAMS, 0x00, MODEL_LEVEL_GEOMETRY_0F, bhvStaticObject }, + { special_level_geo_10, SPTYPE_YROT_NO_PARAMS, 0x00, MODEL_LEVEL_GEOMETRY_10, bhvStaticObject }, + { special_level_geo_11, SPTYPE_YROT_NO_PARAMS, 0x00, MODEL_LEVEL_GEOMETRY_11, bhvStaticObject }, + { special_level_geo_12, SPTYPE_YROT_NO_PARAMS, 0x00, MODEL_LEVEL_GEOMETRY_12, bhvStaticObject }, + { special_level_geo_13, SPTYPE_YROT_NO_PARAMS, 0x00, MODEL_LEVEL_GEOMETRY_13, bhvStaticObject }, + { special_level_geo_14, SPTYPE_YROT_NO_PARAMS, 0x00, MODEL_LEVEL_GEOMETRY_14, bhvStaticObject }, + { special_level_geo_15, SPTYPE_YROT_NO_PARAMS, 0x00, MODEL_LEVEL_GEOMETRY_15, bhvStaticObject }, + { special_level_geo_16, SPTYPE_YROT_NO_PARAMS, 0x00, MODEL_LEVEL_GEOMETRY_16, bhvStaticObject }, + { special_bubble_tree, SPTYPE_NO_YROT_OR_PARAMS, 0x00, MODEL_BOB_BUBBLY_TREE, bhvTree }, + { special_spiky_tree, SPTYPE_NO_YROT_OR_PARAMS, 0x00, MODEL_COURTYARD_SPIKY_TREE, bhvTree }, + { special_snow_tree, SPTYPE_NO_YROT_OR_PARAMS, 0x00, MODEL_CCM_SNOW_TREE, bhvTree }, + { special_unknown_tree, SPTYPE_NO_YROT_OR_PARAMS, 0x00, MODEL_UNKNOWN_TREE_1A, bhvTree }, + { special_palm_tree, SPTYPE_NO_YROT_OR_PARAMS, 0x00, MODEL_SSL_PALM_TREE, bhvTree }, + { special_castle_door, SPTYPE_YROT_NO_PARAMS, 0x00, MODEL_CASTLE_CASTLE_DOOR_UNUSED, bhvDoor }, + { special_wooden_door, SPTYPE_YROT_NO_PARAMS, 0x00, MODEL_CASTLE_WOODEN_DOOR_UNUSED, bhvDoor }, + { special_unknown_door, SPTYPE_YROT_NO_PARAMS, 0x00, MODEL_UNKNOWN_DOOR_1E, bhvDoor }, + { special_metal_door, SPTYPE_YROT_NO_PARAMS, 0x00, MODEL_HMC_METAL_DOOR, bhvDoor }, + { special_hmc_door, SPTYPE_YROT_NO_PARAMS, 0x00, MODEL_HMC_HAZY_MAZE_DOOR, bhvDoor }, + { special_unknown2_door, SPTYPE_YROT_NO_PARAMS, 0x00, MODEL_UNKNOWN_DOOR_21, bhvDoor }, + { special_0stars_door, SPTYPE_DEF_PARAM_AND_YROT, 0x00, MODEL_CASTLE_DOOR_0_STARS, bhvDoor }, + { special_1star_door, SPTYPE_DEF_PARAM_AND_YROT, 0x01, MODEL_CASTLE_DOOR_1_STAR, bhvDoor }, + { special_3star_door, SPTYPE_DEF_PARAM_AND_YROT, 0x03, MODEL_CASTLE_DOOR_3_STARS, bhvDoor }, + { special_key_door, SPTYPE_DEF_PARAM_AND_YROT, 0x00, MODEL_CASTLE_KEY_DOOR, bhvDoor }, + { special_castle_door_warp, SPTYPE_PARAMS_AND_YROT, 0x00, MODEL_CASTLE_CASTLE_DOOR, bhvDoorWarp }, + { special_wooden_door_warp, SPTYPE_PARAMS_AND_YROT, 0x00, MODEL_CASTLE_WOODEN_DOOR, bhvDoorWarp }, + { special_unknown1_door_warp, SPTYPE_PARAMS_AND_YROT, 0x00, MODEL_UNKNOWN_DOOR_28, bhvDoorWarp }, + { special_metal_door_warp, SPTYPE_PARAMS_AND_YROT, 0x00, MODEL_CASTLE_METAL_DOOR, bhvDoorWarp }, + { special_unknown2_door_warp, SPTYPE_PARAMS_AND_YROT, 0x00, MODEL_UNKNOWN_DOOR_2A, bhvDoorWarp }, + { special_unknown3_door_warp, SPTYPE_PARAMS_AND_YROT, 0x00, MODEL_UNKNOWN_DOOR_2B, bhvDoorWarp }, + { special_null_end, SPTYPE_NO_YROT_OR_PARAMS, 0x00, MODEL_NONE, NULL }, +}; diff --git a/include/surface_terrains.h b/include/surface_terrains.h index f555d5b1..8f1e1f41 100644 --- a/include/surface_terrains.h +++ b/include/surface_terrains.h @@ -102,9 +102,9 @@ #define SURFACE_PAINTING_WOBBLE_CD 0x00CD // Painting wobble (THI Huge - Left) #define SURFACE_PAINTING_WOBBLE_CE 0x00CE // Painting wobble (THI Huge - Middle) #define SURFACE_PAINTING_WOBBLE_CF 0x00CF // Painting wobble (THI Huge - Right) -#define SURFACE_PAINTING_WOBBLE_D0 0x00D0 // Painting wobble (HMC & COTMC - Left), makes the painting wobble if touched -#define SURFACE_PAINTING_WOBBLE_D1 0x00D1 // Painting wobble (Unused, HMC & COTMC - Middle) -#define SURFACE_PAINTING_WOBBLE_D2 0x00D2 // Painting wobble (Unused, HMC & COTMC - Right) +#define SURFACE_PAINTING_WOBBLE_D0 0x00D0 // Painting wobble (HMC & CotMC - Left), makes the painting wobble if touched +#define SURFACE_PAINTING_WOBBLE_D1 0x00D1 // Painting wobble (Unused, HMC & CotMC - Middle) +#define SURFACE_PAINTING_WOBBLE_D2 0x00D2 // Painting wobble (Unused, HMC & CotMC - Right) #define SURFACE_PAINTING_WARP_D3 0x00D3 // Painting warp (BoB Left) #define SURFACE_PAINTING_WARP_D4 0x00D4 // Painting warp (BoB Middle) #define SURFACE_PAINTING_WARP_D5 0x00D5 // Painting warp (BoB Right) diff --git a/include/text_menu_strings.h.in b/include/text_menu_strings.h.in index c9f93af3..f564e7b2 100644 --- a/include/text_menu_strings.h.in +++ b/include/text_menu_strings.h.in @@ -2,17 +2,19 @@ #define TEXT_MENU_STRINGS_H // These strings use a different table defined in menu_hud_lut -// Unlike text_strings.h.in, the charmap is different and +// Unlike text_strings.h.in, the charmap is different and // uses char values from charmap_menu.txt /** * File Select JP HUD Text */ +#if defined(VERSION_JP) || defined(VERSION_SH) #define TEXT_JPHUD_MARIO _("マリオ") #define TEXT_JPHUD_SELECT_FILE _("ファイルセレクト") #define TEXT_JPHUD_CHECK_FILE _("どのスコアをみる?") #define TEXT_JPHUD_COPY_FILE _("ファイルコピーする") #define TEXT_JPHUD_ERASE_FILE _("ファイルけす") #define TEXT_JPHUD_SOUND_SELECT _("サウンドセレクト") +#endif #endif // TEXT_MENU_STRINGS_H diff --git a/include/text_strings.h.in b/include/text_strings.h.in index 749179b1..a1f1ae3e 100644 --- a/include/text_strings.h.in +++ b/include/text_strings.h.in @@ -6,30 +6,48 @@ /** * Global Symbols */ -#define TEXT_ZERO _("0") +#define TEXT_EMPTY_STRING _("") +#define TEXT_ZERO _%("0") #define TEXT_COIN _("$") #define TEXT_STAR _("★") #define TEXT_COIN_X _("$×") #define TEXT_STAR_X _("★×") #define TEXT_VARIABLE_X _("×") + +#ifdef VERSION_CN +#define TEXT_STAR_DIFF _("★ ") +#define TEXT_UNFILLED_STAR _("☆ ") +#else +#define TEXT_STAR_DIFF TEXT_STAR #define TEXT_UNFILLED_STAR _("☆") +#endif /** * Global Text */ // File Select -#define TEXT_NEW _("NEW") // New File Text #define TEXT_4DASHES _("----") // Used in Score File Menu +#ifdef VERSION_CN +#define TEXT_NEW 0x7E, 0x7F, 0x82, 0x83, 0xFE, 0x80, 0x81, 0x84, 0x85, 0xFF +#else +#define TEXT_NEW _("NEW") // New File Text +#endif // Ingame Menu +#ifdef VERSION_CN +#define TEXT_PAUSE 0x86, 0x87, 0x8A, 0x8B, 0x8E, 0x8F, 0xFE, 0x88, 0x89, 0x8C, 0x8D, 0x90, 0x91, 0xFF +#define TEXT_HUD_CONGRATULATIONS 0x3A, 0x3B, 0x3E, 0x3F, 0x42, 0x43, 0xFE, 0x3C, 0x3D, 0x40, 0x41, 0x44, 0x45, 0xFF +#else #define TEXT_PAUSE _("PAUSE") // Pause text, Castle Courses #define TEXT_HUD_CONGRATULATIONS _("CONGRATULATIONS") // Course Complete Text, Bowser Courses +#endif #if defined(VERSION_JP) || defined(VERSION_SH) /** * File Select Text */ + // Main Screens // JPHUD menu strings are defined in "text_menu_strings.h.in" #define TEXT_MARIO TEXT_JPHUD_MARIO // View Score Menu @@ -129,6 +147,7 @@ /** * File Select Text */ + // Main Screens #define TEXT_MARIO _("MARIO") // View Score Menu #define TEXT_SELECT_FILE _("SELECT FILE") @@ -136,6 +155,7 @@ #define TEXT_COPY_FILE _("COPY FILE") #define TEXT_ERASE_FILE _("ERASE FILE") #define TEXT_SOUND_SELECT _("SOUND SELECT") + #define TEXT_FILE_MARIO_A _("MARIO A") #define TEXT_FILE_MARIO_B _("MARIO B") #define TEXT_FILE_MARIO_C _("MARIO C") @@ -472,4 +492,97 @@ #define TEXT_MENU_STARS_DE _(" GEHEIME STERNE") #endif // VERSION_EU +#ifdef VERSION_CN + +/** + * File Select Text + */ + +// Main Screens +// JPHUD menu strings are defined in "text_menu_strings.h.in" +#define TEXT_MARIO 0x76, 0x77, 0x7A, 0x7B, 0xFE, 0x78, 0x79, 0x7C, 0x7D, 0xFF +#define TEXT_SELECT_FILE 0x96, 0x97, 0x9A, 0x9B, 0x9E, 0x9F, 0xFE, 0x98, 0x99, 0x9C, 0x9D, 0xA0, 0xA1, 0xFF +#define TEXT_CHECK_FILE 0x46, 0x47, 0x4A, 0x4B, 0x4E, 0x4F, 0xFE, 0x48, 0x49, 0x4C, 0x4D, 0x50, 0x51, 0xFF +#define TEXT_COPY_FILE 0x52, 0x53, 0x56, 0x57, 0x5A, 0x5B, 0xFE, 0x54, 0x55, 0x58, 0x59, 0x5C, 0x5D, 0xFF +#define TEXT_ERASE_FILE 0x5E, 0x5F, 0x62, 0x63, 0x66, 0x67, 0xFE, 0x60, 0x61, 0x64, 0x65, 0x68, 0x69, 0xFF +#define TEXT_SOUND_SELECT 0xA2, 0xA3, 0xA6, 0xA7, 0xAA, 0xAB, 0xFE, 0xA4, 0xA5, 0xA8, 0xA9, 0xAC, 0xAD, 0xFF + +#define TEXT_FILE_MARIO_A _("马力欧 A") +#define TEXT_FILE_MARIO_B _("马力欧 B") +#define TEXT_FILE_MARIO_C _("马力欧 C") +#define TEXT_FILE_MARIO_D _("马力欧 D") + +// Menu Options +#define TEXT_SCORE _("积分") +#define TEXT_COPY _("复制") +#define TEXT_ERASE _("删除") + +// Sound Options +#define TEXT_STEREO _("立体声") +#define TEXT_MONO _("单声道") +#define TEXT_HEADSET _("耳机") + +// Misc Menu Text +#define TEXT_SAVED_DATA_EXISTS _("有保存的数据") +#define TEXT_NO_SAVED_DATA_EXISTS _("没有保存的数据") + +// Inside a Menu +#define TEXT_RETURN _("返回") +#define TEXT_CHECK_SCORE _("查看积分") +#define TEXT_COPY_FILE_BUTTON _("复制文件") +#define TEXT_ERASE_FILE_BUTTON _("删除文件") + +// Score Menu +#define TEXT_HI_SCORE _("最高积分") +#define TEXT_MY_SCORE _("我的积分") +#define TEXT_SCORE_MARIO_A _("☺A") +#define TEXT_SCORE_MARIO_B _("☺B") +#define TEXT_SCORE_MARIO_C _("☺C") +#define TEXT_SCORE_MARIO_D _("☺D") + +// Copy Menu +#define TEXT_COPY_IT_TO_WHERE _("复制到何处") +#define TEXT_COPYING_COMPLETED _("复制完毕") +#define TEXT_NO_FILE_TO_COPY_FROM _("没有空文件") + +// Erase Menu +#define TEXT_SURE _("确定吗?") +#define TEXT_YES _("是") +#define TEXT_NO _("否") +#define TEXT_FILE_MARIO_A_JUST_ERASED _("文件已删除") + +/** + * Menus Text (Pause, Course Completed) + */ +// Main Courses +#define TEXT_COURSE _("关卡") +#define TEXT_MYSCORE TEXT_MY_SCORE +#define TEXT_CONTINUE _("继续") +#define TEXT_EXIT_COURSE _("退出") +#define TEXT_CAMERA_ANGLE_R _("使用[R]键设定视角") + +// Camera Options +#define TEXT_LAKITU_MARIO TEXT_EMPTY_STRING +#define TEXT_LAKITU_STOP TEXT_EMPTY_STRING +#define TEXT_NORMAL_UPCLOSE _("特写镜头") +#define TEXT_NORMAL_FIXED _("固定镜头") + +// Course Completed Misc Text +#define TEXT_CATCH _("接住") +#define TEXT_CLEAR _("清除") +#define TEXT_HUD_HI_SCORE 0x6A, 0x6B, 0x6E, 0x6F, 0x72, 0x73, 0xFE, 0x6C, 0x6D, 0x70, 0x71, 0x74, 0x75, 0xFF + +// Save Options +#define TEXT_SAVE_AND_CONTINUE _("保存并继续") +#define TEXT_SAVE_AND_QUIT _("保存并退出") +#define TEXT_CONTINUE_WITHOUT_SAVING _("不必保存") + +// File Score Menu Icons +#define TEXT_ARROW_L _("◀ L") +#define TEXT_R_ARROW _("R ▶") + +#endif // VERSION_CN + #endif // TEXT_STRINGS_H + + diff --git a/include/types.h b/include/types.h index 150de575..e53fb7dd 100644 --- a/include/types.h +++ b/include/types.h @@ -48,11 +48,14 @@ typedef uintptr_t GeoLayout; typedef uintptr_t LevelScript; typedef s16 Movtex; typedef s16 MacroObject; -typedef s16 Collision; +typedef s16 Collision; // Collision data is limited to -32768 to 32767. Change this if you want to increase it. typedef s16 Trajectory; typedef s16 PaintingData; typedef uintptr_t BehaviorScript; typedef u8 Texture; +typedef s8 RoomData; // Rooms are limited to -128 to 127. Change the type if you wish to have more rooms. +typedef Collision TerrainData; +typedef TerrainData Vec3Terrain[3]; enum SpTaskState { SPTASK_STATE_NOT_STARTED, @@ -75,7 +78,7 @@ struct VblankHandler { }; #define ANIM_FLAG_NOLOOP (1 << 0) // 0x01 -#define ANIM_FLAG_FORWARD (1 << 1) // 0x02 +#define ANIM_FLAG_BACKWARD (1 << 1) // 0x02 #define ANIM_FLAG_2 (1 << 2) // 0x04 #define ANIM_FLAG_HOR_TRANS (1 << 3) // 0x08 #define ANIM_FLAG_VERT_TRANS (1 << 4) // 0x10 @@ -216,15 +219,15 @@ struct Waypoint { }; struct Surface { - /*0x00*/ s16 type; - /*0x02*/ s16 force; + /*0x00*/ TerrainData type; + /*0x02*/ TerrainData force; /*0x04*/ s8 flags; - /*0x05*/ s8 room; - /*0x06*/ s16 lowerY; - /*0x08*/ s16 upperY; - /*0x0A*/ Vec3s vertex1; - /*0x10*/ Vec3s vertex2; - /*0x16*/ Vec3s vertex3; + /*0x05*/ RoomData room; + /*0x06*/ TerrainData lowerY; + /*0x08*/ TerrainData upperY; + /*0x0A*/ Vec3Terrain vertex1; + /*0x10*/ Vec3Terrain vertex2; + /*0x16*/ Vec3Terrain vertex3; /*0x1C*/ struct { f32 x; f32 y; @@ -309,7 +312,7 @@ struct MarioState { /*0xB8*/ s16 prevNumStarsForDialog; /*0xBC*/ f32 peakHeight; /*0xC0*/ f32 quicksandDepth; - /*0xC4*/ f32 unkC4; + /*0xC4*/ f32 gettingBlownGravity; }; #endif // TYPES_H diff --git a/include/ultra64.h b/include/ultra64.h index 409a3cf7..36516203 100644 --- a/include/ultra64.h +++ b/include/ultra64.h @@ -14,6 +14,7 @@ #include #include #include +#include #include #include #include @@ -27,6 +28,7 @@ #include #include #include +#include #include #include diff --git a/levels/bbh/areas/1/geo.inc.c b/levels/bbh/areas/1/geo.inc.c index 6a7deebb..965ee409 100644 --- a/levels/bbh/areas/1/geo.inc.c +++ b/levels/bbh/areas/1/geo.inc.c @@ -1,526 +1,526 @@ // 0x0E000670 const GeoLayout geo_bbh_000670[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_070075A8), - GEO_DISPLAY_LIST(LAYER_ALPHA, bbh_seg7_dl_07007940), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_07007B90), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, bbh_seg7_dl_07007FD0), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_07008B58), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, bbh_seg7_dl_07008EA8), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_070075A8), + GEO_DISPLAY_LIST(LAYER_ALPHA, bbh_seg7_dl_07007940), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_07007B90), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, bbh_seg7_dl_07007FD0), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_07008B58), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, bbh_seg7_dl_07008EA8), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x0E0006B0 const GeoLayout geo_bbh_0006B0[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0700AFF0), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0700B1C8), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, bbh_seg7_dl_0700B418), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0700B9E0), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, bbh_seg7_dl_0700BBF8), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0700AFF0), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0700B1C8), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, bbh_seg7_dl_0700B418), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0700B9E0), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, bbh_seg7_dl_0700BBF8), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x0E0006E8 const GeoLayout geo_bbh_0006E8[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0700D080), - GEO_DISPLAY_LIST(LAYER_ALPHA, bbh_seg7_dl_0700D2E0), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0700D490), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, bbh_seg7_dl_0700D7E0), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_07012220), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_07012510), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, bbh_seg7_dl_070126E8), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0700D080), + GEO_DISPLAY_LIST(LAYER_ALPHA, bbh_seg7_dl_0700D2E0), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0700D490), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, bbh_seg7_dl_0700D7E0), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_07012220), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_07012510), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, bbh_seg7_dl_070126E8), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x0E000730 const GeoLayout geo_bbh_000730[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0700F510), - GEO_DISPLAY_LIST(LAYER_ALPHA, bbh_seg7_dl_0700F848), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0700F510), + GEO_DISPLAY_LIST(LAYER_ALPHA, bbh_seg7_dl_0700F848), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x0E000750 const GeoLayout geo_bbh_000750[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_07011120), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_07011120), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x0E000768 const GeoLayout geo_bbh_000768[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0700D080), - GEO_DISPLAY_LIST(LAYER_ALPHA, bbh_seg7_dl_0700D2E0), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0700D490), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, bbh_seg7_dl_0700D7E0), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_07012220), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_07012510), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, bbh_seg7_dl_070126E8), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0700D080), + GEO_DISPLAY_LIST(LAYER_ALPHA, bbh_seg7_dl_0700D2E0), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0700D490), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, bbh_seg7_dl_0700D7E0), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_07012220), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_07012510), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, bbh_seg7_dl_070126E8), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x0E0007B0 const GeoLayout geo_bbh_0007B0[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_070139A8), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, bbh_seg7_dl_07013BE8), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_070139A8), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, bbh_seg7_dl_07013BE8), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x0E0007D0 const GeoLayout geo_bbh_0007D0[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_07014FD8), - GEO_DISPLAY_LIST(LAYER_ALPHA, bbh_seg7_dl_07015398), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, bbh_seg7_dl_070156E0), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_07015A20), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_07014FD8), + GEO_DISPLAY_LIST(LAYER_ALPHA, bbh_seg7_dl_07015398), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, bbh_seg7_dl_070156E0), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_07015A20), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x0E000800 const GeoLayout geo_bbh_000800[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_07017378), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_07017570), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, bbh_seg7_dl_07017788), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_07017378), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_07017570), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, bbh_seg7_dl_07017788), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x0E000828 const GeoLayout geo_bbh_000828[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_07019EF8), - GEO_DISPLAY_LIST(LAYER_ALPHA, bbh_seg7_dl_0701A080), - GEO_ASM( 0, geo_movtex_pause_control), - GEO_ASM(0x0400, geo_movtex_draw_water_regions), - GEO_ASM(0x0401, geo_movtex_draw_water_regions), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_07019EF8), + GEO_DISPLAY_LIST(LAYER_ALPHA, bbh_seg7_dl_0701A080), + GEO_ASM( 0, geo_movtex_pause_control), + GEO_ASM(0x0400, geo_movtex_draw_water_regions), + GEO_ASM(0x0401, geo_movtex_draw_water_regions), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x0E000860 const GeoLayout geo_bbh_000860[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0701A850), - GEO_ASM( 0, geo_movtex_pause_control), - GEO_ASM(0x0400, geo_movtex_draw_water_regions), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0701A850), + GEO_ASM( 0, geo_movtex_pause_control), + GEO_ASM(0x0400, geo_movtex_draw_water_regions), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x0E000888 const GeoLayout geo_bbh_000888[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0701B6D0), - GEO_ASM( 0, geo_movtex_pause_control), - GEO_ASM(0x0400, geo_movtex_draw_water_regions), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0701B6D0), + GEO_ASM( 0, geo_movtex_pause_control), + GEO_ASM(0x0400, geo_movtex_draw_water_regions), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x0E0008B0 const GeoLayout geo_bbh_0008B0[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0701E4E0), - GEO_DISPLAY_LIST(LAYER_ALPHA, bbh_seg7_dl_0701E8D8), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0701ED18), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, bbh_seg7_dl_0701EEC8), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0701F070), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0701E4E0), + GEO_DISPLAY_LIST(LAYER_ALPHA, bbh_seg7_dl_0701E8D8), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0701ED18), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, bbh_seg7_dl_0701EEC8), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0701F070), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x0E0008E8 const GeoLayout geo_bbh_0008E8[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_070075A8), - GEO_DISPLAY_LIST(LAYER_ALPHA, bbh_seg7_dl_07007940), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_07007B90), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, bbh_seg7_dl_07007FD0), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_07008B58), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, bbh_seg7_dl_07008EA8), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0700AFF0), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0700B1C8), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, bbh_seg7_dl_0700B418), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0700B9E0), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, bbh_seg7_dl_0700BBF8), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_070075A8), + GEO_DISPLAY_LIST(LAYER_ALPHA, bbh_seg7_dl_07007940), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_07007B90), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, bbh_seg7_dl_07007FD0), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_07008B58), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, bbh_seg7_dl_07008EA8), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0700AFF0), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0700B1C8), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, bbh_seg7_dl_0700B418), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0700B9E0), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, bbh_seg7_dl_0700BBF8), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x0E000950 const GeoLayout geo_bbh_000950[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_070075A8), - GEO_DISPLAY_LIST(LAYER_ALPHA, bbh_seg7_dl_07007940), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_07007B90), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, bbh_seg7_dl_07007FD0), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_07008B58), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, bbh_seg7_dl_07008EA8), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0700D080), - GEO_DISPLAY_LIST(LAYER_ALPHA, bbh_seg7_dl_0700D2E0), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0700D490), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, bbh_seg7_dl_0700D7E0), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_07012220), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_07012510), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, bbh_seg7_dl_070126E8), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_070075A8), + GEO_DISPLAY_LIST(LAYER_ALPHA, bbh_seg7_dl_07007940), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_07007B90), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, bbh_seg7_dl_07007FD0), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_07008B58), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, bbh_seg7_dl_07008EA8), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0700D080), + GEO_DISPLAY_LIST(LAYER_ALPHA, bbh_seg7_dl_0700D2E0), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0700D490), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, bbh_seg7_dl_0700D7E0), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_07012220), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_07012510), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, bbh_seg7_dl_070126E8), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x0E0009C8 const GeoLayout geo_bbh_0009C8[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_070075A8), - GEO_DISPLAY_LIST(LAYER_ALPHA, bbh_seg7_dl_07007940), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_07007B90), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, bbh_seg7_dl_07007FD0), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_07008B58), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, bbh_seg7_dl_07008EA8), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0700F510), - GEO_DISPLAY_LIST(LAYER_ALPHA, bbh_seg7_dl_0700F848), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_070075A8), + GEO_DISPLAY_LIST(LAYER_ALPHA, bbh_seg7_dl_07007940), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_07007B90), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, bbh_seg7_dl_07007FD0), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_07008B58), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, bbh_seg7_dl_07008EA8), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0700F510), + GEO_DISPLAY_LIST(LAYER_ALPHA, bbh_seg7_dl_0700F848), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x0E000A18 const GeoLayout geo_bbh_000A18[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_070075A8), - GEO_DISPLAY_LIST(LAYER_ALPHA, bbh_seg7_dl_07007940), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_07007B90), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, bbh_seg7_dl_07007FD0), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_07008B58), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, bbh_seg7_dl_07008EA8), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_07011120), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_070075A8), + GEO_DISPLAY_LIST(LAYER_ALPHA, bbh_seg7_dl_07007940), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_07007B90), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, bbh_seg7_dl_07007FD0), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_07008B58), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, bbh_seg7_dl_07008EA8), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_07011120), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x0E000A60 const GeoLayout geo_bbh_000A60[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_070075A8), - GEO_DISPLAY_LIST(LAYER_ALPHA, bbh_seg7_dl_07007940), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_07007B90), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, bbh_seg7_dl_07007FD0), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_07008B58), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, bbh_seg7_dl_07008EA8), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0700D080), - GEO_DISPLAY_LIST(LAYER_ALPHA, bbh_seg7_dl_0700D2E0), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0700D490), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, bbh_seg7_dl_0700D7E0), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_07012220), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_07012510), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, bbh_seg7_dl_070126E8), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_070075A8), + GEO_DISPLAY_LIST(LAYER_ALPHA, bbh_seg7_dl_07007940), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_07007B90), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, bbh_seg7_dl_07007FD0), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_07008B58), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, bbh_seg7_dl_07008EA8), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0700D080), + GEO_DISPLAY_LIST(LAYER_ALPHA, bbh_seg7_dl_0700D2E0), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0700D490), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, bbh_seg7_dl_0700D7E0), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_07012220), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_07012510), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, bbh_seg7_dl_070126E8), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x0E000AD8 const GeoLayout geo_bbh_000AD8[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_070075A8), - GEO_DISPLAY_LIST(LAYER_ALPHA, bbh_seg7_dl_07007940), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_07007B90), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, bbh_seg7_dl_07007FD0), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_07008B58), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, bbh_seg7_dl_07008EA8), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_070139A8), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, bbh_seg7_dl_07013BE8), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_070075A8), + GEO_DISPLAY_LIST(LAYER_ALPHA, bbh_seg7_dl_07007940), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_07007B90), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, bbh_seg7_dl_07007FD0), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_07008B58), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, bbh_seg7_dl_07008EA8), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_070139A8), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, bbh_seg7_dl_07013BE8), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x0E000B28 const GeoLayout geo_bbh_000B28[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_070075A8), - GEO_DISPLAY_LIST(LAYER_ALPHA, bbh_seg7_dl_07007940), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_07007B90), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, bbh_seg7_dl_07007FD0), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_07008B58), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, bbh_seg7_dl_07008EA8), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_07014FD8), - GEO_DISPLAY_LIST(LAYER_ALPHA, bbh_seg7_dl_07015398), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, bbh_seg7_dl_070156E0), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_07015A20), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_070075A8), + GEO_DISPLAY_LIST(LAYER_ALPHA, bbh_seg7_dl_07007940), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_07007B90), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, bbh_seg7_dl_07007FD0), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_07008B58), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, bbh_seg7_dl_07008EA8), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_07014FD8), + GEO_DISPLAY_LIST(LAYER_ALPHA, bbh_seg7_dl_07015398), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, bbh_seg7_dl_070156E0), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_07015A20), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x0E000B88 const GeoLayout geo_bbh_000B88[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_070075A8), - GEO_DISPLAY_LIST(LAYER_ALPHA, bbh_seg7_dl_07007940), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_07007B90), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, bbh_seg7_dl_07007FD0), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_07008B58), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, bbh_seg7_dl_07008EA8), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0701E4E0), - GEO_DISPLAY_LIST(LAYER_ALPHA, bbh_seg7_dl_0701E8D8), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0701ED18), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, bbh_seg7_dl_0701EEC8), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0701F070), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_070075A8), + GEO_DISPLAY_LIST(LAYER_ALPHA, bbh_seg7_dl_07007940), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_07007B90), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, bbh_seg7_dl_07007FD0), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_07008B58), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, bbh_seg7_dl_07008EA8), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0701E4E0), + GEO_DISPLAY_LIST(LAYER_ALPHA, bbh_seg7_dl_0701E8D8), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0701ED18), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, bbh_seg7_dl_0701EEC8), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0701F070), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x0E000BF0 const GeoLayout geo_bbh_000BF0[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0700AFF0), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0700B1C8), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, bbh_seg7_dl_0700B418), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0700B9E0), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, bbh_seg7_dl_0700BBF8), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0700F510), - GEO_DISPLAY_LIST(LAYER_ALPHA, bbh_seg7_dl_0700F848), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0700AFF0), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0700B1C8), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, bbh_seg7_dl_0700B418), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0700B9E0), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, bbh_seg7_dl_0700BBF8), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0700F510), + GEO_DISPLAY_LIST(LAYER_ALPHA, bbh_seg7_dl_0700F848), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x0E000C38 const GeoLayout geo_bbh_000C38[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0700AFF0), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0700B1C8), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, bbh_seg7_dl_0700B418), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0700B9E0), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, bbh_seg7_dl_0700BBF8), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_07017378), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_07017570), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, bbh_seg7_dl_07017788), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0700AFF0), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0700B1C8), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, bbh_seg7_dl_0700B418), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0700B9E0), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, bbh_seg7_dl_0700BBF8), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_07017378), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_07017570), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, bbh_seg7_dl_07017788), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x0E000C88 const GeoLayout geo_bbh_000C88[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0700AFF0), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0700B1C8), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, bbh_seg7_dl_0700B418), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0700B9E0), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, bbh_seg7_dl_0700BBF8), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_07019EF8), - GEO_DISPLAY_LIST(LAYER_ALPHA, bbh_seg7_dl_0701A080), - GEO_ASM( 0, geo_movtex_pause_control), - GEO_ASM(0x0400, geo_movtex_draw_water_regions), - GEO_ASM(0x0401, geo_movtex_draw_water_regions), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0700AFF0), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0700B1C8), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, bbh_seg7_dl_0700B418), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0700B9E0), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, bbh_seg7_dl_0700BBF8), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_07019EF8), + GEO_DISPLAY_LIST(LAYER_ALPHA, bbh_seg7_dl_0701A080), + GEO_ASM( 0, geo_movtex_pause_control), + GEO_ASM(0x0400, geo_movtex_draw_water_regions), + GEO_ASM(0x0401, geo_movtex_draw_water_regions), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x0E000CE8 const GeoLayout geo_bbh_000CE8[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0700D080), - GEO_DISPLAY_LIST(LAYER_ALPHA, bbh_seg7_dl_0700D2E0), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0700D490), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, bbh_seg7_dl_0700D7E0), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_07011120), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0700D080), + GEO_DISPLAY_LIST(LAYER_ALPHA, bbh_seg7_dl_0700D2E0), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0700D490), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, bbh_seg7_dl_0700D7E0), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_07011120), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x0E000D20 const GeoLayout geo_bbh_000D20[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0700D080), - GEO_DISPLAY_LIST(LAYER_ALPHA, bbh_seg7_dl_0700D2E0), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0700D490), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, bbh_seg7_dl_0700D7E0), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_07012220), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_07012510), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, bbh_seg7_dl_070126E8), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0700D080), + GEO_DISPLAY_LIST(LAYER_ALPHA, bbh_seg7_dl_0700D2E0), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0700D490), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, bbh_seg7_dl_0700D7E0), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_07012220), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_07012510), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, bbh_seg7_dl_070126E8), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x0E000D68 const GeoLayout geo_bbh_000D68[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0700F510), - GEO_DISPLAY_LIST(LAYER_ALPHA, bbh_seg7_dl_0700F848), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_07019EF8), - GEO_DISPLAY_LIST(LAYER_ALPHA, bbh_seg7_dl_0701A080), - GEO_ASM( 0, geo_movtex_pause_control), - GEO_ASM(0x0400, geo_movtex_draw_water_regions), - GEO_ASM(0x0401, geo_movtex_draw_water_regions), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0700F510), + GEO_DISPLAY_LIST(LAYER_ALPHA, bbh_seg7_dl_0700F848), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_07019EF8), + GEO_DISPLAY_LIST(LAYER_ALPHA, bbh_seg7_dl_0701A080), + GEO_ASM( 0, geo_movtex_pause_control), + GEO_ASM(0x0400, geo_movtex_draw_water_regions), + GEO_ASM(0x0401, geo_movtex_draw_water_regions), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x0E000DB0 const GeoLayout geo_bbh_000DB0[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_07011120), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0701E4E0), - GEO_DISPLAY_LIST(LAYER_ALPHA, bbh_seg7_dl_0701E8D8), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0701ED18), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, bbh_seg7_dl_0701EEC8), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0701F070), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_07011120), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0701E4E0), + GEO_DISPLAY_LIST(LAYER_ALPHA, bbh_seg7_dl_0701E8D8), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0701ED18), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, bbh_seg7_dl_0701EEC8), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0701F070), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x0E000DF0 const GeoLayout geo_bbh_000DF0[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_07017378), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_07017570), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, bbh_seg7_dl_07017788), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0701E4E0), - GEO_DISPLAY_LIST(LAYER_ALPHA, bbh_seg7_dl_0701E8D8), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0701ED18), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, bbh_seg7_dl_0701EEC8), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0701F070), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_07017378), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_07017570), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, bbh_seg7_dl_07017788), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0701E4E0), + GEO_DISPLAY_LIST(LAYER_ALPHA, bbh_seg7_dl_0701E8D8), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0701ED18), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, bbh_seg7_dl_0701EEC8), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0701F070), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x0E000E40 const GeoLayout geo_bbh_000E40[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_07019EF8), - GEO_DISPLAY_LIST(LAYER_ALPHA, bbh_seg7_dl_0701A080), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0701A850), - GEO_ASM( 0, geo_movtex_pause_control), - GEO_ASM(0x0400, geo_movtex_draw_water_regions), - GEO_ASM(0x0401, geo_movtex_draw_water_regions), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_07019EF8), + GEO_DISPLAY_LIST(LAYER_ALPHA, bbh_seg7_dl_0701A080), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0701A850), + GEO_ASM( 0, geo_movtex_pause_control), + GEO_ASM(0x0400, geo_movtex_draw_water_regions), + GEO_ASM(0x0401, geo_movtex_draw_water_regions), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x0E000E80 const GeoLayout geo_bbh_000E80[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0701A850), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0701B6D0), - GEO_ASM( 0, geo_movtex_pause_control), - GEO_ASM(0x0400, geo_movtex_draw_water_regions), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0701A850), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0701B6D0), + GEO_ASM( 0, geo_movtex_pause_control), + GEO_ASM(0x0400, geo_movtex_draw_water_regions), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x0E000EB0 const GeoLayout geo_bbh_000EB0[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0701B6D0), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0701E4E0), - GEO_DISPLAY_LIST(LAYER_ALPHA, bbh_seg7_dl_0701E8D8), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0701ED18), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, bbh_seg7_dl_0701EEC8), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0701F070), - GEO_ASM( 0, geo_movtex_pause_control), - GEO_ASM(0x0400, geo_movtex_draw_water_regions), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0701B6D0), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0701E4E0), + GEO_DISPLAY_LIST(LAYER_ALPHA, bbh_seg7_dl_0701E8D8), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0701ED18), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, bbh_seg7_dl_0701EEC8), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0701F070), + GEO_ASM( 0, geo_movtex_pause_control), + GEO_ASM(0x0400, geo_movtex_draw_water_regions), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x0E000F00 const GeoLayout geo_bbh_000F00[] = { - GEO_NODE_SCREEN_AREA(10, SCREEN_WIDTH/2, SCREEN_HEIGHT/2, SCREEN_WIDTH/2, SCREEN_HEIGHT/2), - GEO_OPEN_NODE(), - GEO_ZBUFFER(0), - GEO_OPEN_NODE(), - GEO_NODE_ORTHO(100), - GEO_OPEN_NODE(), - GEO_BACKGROUND(BACKGROUND_HAUNTED, geo_skybox_main), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ZBUFFER(1), - GEO_OPEN_NODE(), - GEO_CAMERA_FRUSTUM_WITH_FUNC(45, 50, 10000, geo_camera_fov), - GEO_OPEN_NODE(), - GEO_CAMERA(4, 0, 2000, 6000, 0, 0, 0, geo_camera_main), + GEO_NODE_SCREEN_AREA(10, SCREEN_WIDTH/2, SCREEN_HEIGHT/2, SCREEN_WIDTH/2, SCREEN_HEIGHT/2), + GEO_OPEN_NODE(), + GEO_ZBUFFER(0), + GEO_OPEN_NODE(), + GEO_NODE_ORTHO(100), GEO_OPEN_NODE(), - GEO_SWITCH_CASE(32, geo_switch_area), - GEO_OPEN_NODE(), - GEO_BRANCH(1, geo_bbh_000670), // 0x0E000670 - GEO_BRANCH(1, geo_bbh_0006B0), // 0x0E0006B0 - GEO_BRANCH(1, geo_bbh_0006E8), // 0x0E0006E8 - GEO_BRANCH(1, geo_bbh_000730), // 0x0E000730 - GEO_BRANCH(1, geo_bbh_000750), // 0x0E000750 - GEO_BRANCH(1, geo_bbh_000768), // 0x0E000768 - GEO_BRANCH(1, geo_bbh_0007B0), // 0x0E0007B0 - GEO_BRANCH(1, geo_bbh_0007D0), // 0x0E0007D0 - GEO_BRANCH(1, geo_bbh_000800), // 0x0E000800 - GEO_BRANCH(1, geo_bbh_000828), // 0x0E000828 - GEO_BRANCH(1, geo_bbh_000860), // 0x0E000860 - GEO_BRANCH(1, geo_bbh_000888), // 0x0E000888 - GEO_BRANCH(1, geo_bbh_0008B0), // 0x0E0008B0 - GEO_BRANCH(1, geo_bbh_0008E8), // 0x0E0008E8 - GEO_BRANCH(1, geo_bbh_000950), // 0x0E000950 - GEO_BRANCH(1, geo_bbh_0009C8), // 0x0E0009C8 - GEO_BRANCH(1, geo_bbh_000A18), // 0x0E000A18 - GEO_BRANCH(1, geo_bbh_000A60), // 0x0E000A60 - GEO_BRANCH(1, geo_bbh_000AD8), // 0x0E000AD8 - GEO_BRANCH(1, geo_bbh_000B28), // 0x0E000B28 - GEO_BRANCH(1, geo_bbh_000B88), // 0x0E000B88 - GEO_BRANCH(1, geo_bbh_000BF0), // 0x0E000BF0 - GEO_BRANCH(1, geo_bbh_000C38), // 0x0E000C38 - GEO_BRANCH(1, geo_bbh_000C88), // 0x0E000C88 - GEO_BRANCH(1, geo_bbh_000CE8), // 0x0E000CE8 - GEO_BRANCH(1, geo_bbh_000D20), // 0x0E000D20 - GEO_BRANCH(1, geo_bbh_000D68), // 0x0E000D68 - GEO_BRANCH(1, geo_bbh_000DB0), // 0x0E000DB0 - GEO_BRANCH(1, geo_bbh_000DF0), // 0x0E000DF0 - GEO_BRANCH(1, geo_bbh_000E40), // 0x0E000E40 - GEO_BRANCH(1, geo_bbh_000E80), // 0x0E000E80 - GEO_BRANCH(1, geo_bbh_000EB0), // 0x0E000EB0 - GEO_CLOSE_NODE(), - GEO_RENDER_OBJ(), - GEO_ASM(0, geo_envfx_main), + GEO_BACKGROUND(BACKGROUND_HAUNTED, geo_skybox_main), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CLOSE_NODE(), + GEO_ZBUFFER(1), + GEO_OPEN_NODE(), + GEO_CAMERA_FRUSTUM_WITH_FUNC(45, 50, 10000, geo_camera_fov), + GEO_OPEN_NODE(), + GEO_CAMERA(4, 0, 2000, 6000, 0, 0, 0, geo_camera_main), + GEO_OPEN_NODE(), + GEO_SWITCH_CASE(32, geo_switch_area), + GEO_OPEN_NODE(), + GEO_BRANCH(1, geo_bbh_000670), // 0x0E000670 + GEO_BRANCH(1, geo_bbh_0006B0), // 0x0E0006B0 + GEO_BRANCH(1, geo_bbh_0006E8), // 0x0E0006E8 + GEO_BRANCH(1, geo_bbh_000730), // 0x0E000730 + GEO_BRANCH(1, geo_bbh_000750), // 0x0E000750 + GEO_BRANCH(1, geo_bbh_000768), // 0x0E000768 + GEO_BRANCH(1, geo_bbh_0007B0), // 0x0E0007B0 + GEO_BRANCH(1, geo_bbh_0007D0), // 0x0E0007D0 + GEO_BRANCH(1, geo_bbh_000800), // 0x0E000800 + GEO_BRANCH(1, geo_bbh_000828), // 0x0E000828 + GEO_BRANCH(1, geo_bbh_000860), // 0x0E000860 + GEO_BRANCH(1, geo_bbh_000888), // 0x0E000888 + GEO_BRANCH(1, geo_bbh_0008B0), // 0x0E0008B0 + GEO_BRANCH(1, geo_bbh_0008E8), // 0x0E0008E8 + GEO_BRANCH(1, geo_bbh_000950), // 0x0E000950 + GEO_BRANCH(1, geo_bbh_0009C8), // 0x0E0009C8 + GEO_BRANCH(1, geo_bbh_000A18), // 0x0E000A18 + GEO_BRANCH(1, geo_bbh_000A60), // 0x0E000A60 + GEO_BRANCH(1, geo_bbh_000AD8), // 0x0E000AD8 + GEO_BRANCH(1, geo_bbh_000B28), // 0x0E000B28 + GEO_BRANCH(1, geo_bbh_000B88), // 0x0E000B88 + GEO_BRANCH(1, geo_bbh_000BF0), // 0x0E000BF0 + GEO_BRANCH(1, geo_bbh_000C38), // 0x0E000C38 + GEO_BRANCH(1, geo_bbh_000C88), // 0x0E000C88 + GEO_BRANCH(1, geo_bbh_000CE8), // 0x0E000CE8 + GEO_BRANCH(1, geo_bbh_000D20), // 0x0E000D20 + GEO_BRANCH(1, geo_bbh_000D68), // 0x0E000D68 + GEO_BRANCH(1, geo_bbh_000DB0), // 0x0E000DB0 + GEO_BRANCH(1, geo_bbh_000DF0), // 0x0E000DF0 + GEO_BRANCH(1, geo_bbh_000E40), // 0x0E000E40 + GEO_BRANCH(1, geo_bbh_000E80), // 0x0E000E80 + GEO_BRANCH(1, geo_bbh_000EB0), // 0x0E000EB0 + GEO_CLOSE_NODE(), + GEO_RENDER_OBJ(), + GEO_ASM(0, geo_envfx_main), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bbh/areas/1/macro.inc.c b/levels/bbh/areas/1/macro.inc.c index acc59b67..581afa0d 100644 --- a/levels/bbh/areas/1/macro.inc.c +++ b/levels/bbh/areas/1/macro.inc.c @@ -1,38 +1,38 @@ // 0x070268C4 - 0x07026A1A const MacroObject bbh_seg7_macro_objs[] = { - MACRO_OBJECT(/*preset*/ macro_haunted_chair, /*yaw*/ 90, /*pos*/ -1960, -20, 340), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 0, /*pos*/ -800, -204, 2915, /*behParam*/ DIALOG_063), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 0, /*pos*/ 400, -204, 3057, /*behParam*/ DIALOG_085), - MACRO_OBJECT(/*preset*/ macro_haunted_chair, /*yaw*/ 270, /*pos*/ -1080, 20, 160), - MACRO_OBJECT(/*preset*/ macro_box_vanish_cap, /*yaw*/ 0, /*pos*/ 1268, 1050, 1860), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -1164, 0, 2325), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 2540, 820, 2174), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 2600, 815, -380), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 2950, 815, -1250), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -1500, 550, 960), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -420, 550, 60), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 2856, 50, 2144), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 50, 900, -1400), - MACRO_OBJECT(/*preset*/ macro_box_1up, /*yaw*/ 0, /*pos*/ 660, 3200, 1160), - MACRO_OBJECT(/*preset*/ macro_blue_coin_switch, /*yaw*/ 0, /*pos*/ 640, 1741, 760), - MACRO_OBJECT(/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ 1400, 1840, 1100), - MACRO_OBJECT(/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ 1700, 1840, 1100), - MACRO_OBJECT(/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ 0, 1840, 1100), - MACRO_OBJECT(/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ -400, 1840, 1100), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 0, /*pos*/ 2026, -204, 2966, /*behParam*/ DIALOG_102), - MACRO_OBJECT(/*preset*/ macro_mr_i, /*yaw*/ 0, /*pos*/ 480, 10, -653), - MACRO_OBJECT(/*preset*/ macro_scuttlebug, /*yaw*/ 0, /*pos*/ -346, -204, -2813), - MACRO_OBJECT(/*preset*/ macro_scuttlebug, /*yaw*/ 0, /*pos*/ 1146, -203, -2280), - MACRO_OBJECT(/*preset*/ macro_mr_i, /*yaw*/ 0, /*pos*/ -2369, -204, 5184), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 135, /*pos*/ -1546, -204, 4813, /*behParam*/ DIALOG_086), - MACRO_OBJECT(/*preset*/ macro_scuttlebug, /*yaw*/ 0, /*pos*/ 3466, -204, 5106), - MACRO_OBJECT(/*preset*/ macro_mr_i, /*yaw*/ 0, /*pos*/ 1640, 840, -733), - MACRO_OBJECT(/*preset*/ macro_box_vanish_cap, /*yaw*/ 0, /*pos*/ -1960, 300, -120), - MACRO_OBJECT(/*preset*/ macro_box_vanish_cap, /*yaw*/ 0, /*pos*/ 460, 2140, -560), - MACRO_OBJECT(/*preset*/ macro_box_ten_coins, /*yaw*/ 0, /*pos*/ 700, 80, -2800), - MACRO_OBJECT(/*preset*/ macro_breakable_box_three_coins, /*yaw*/ 45, /*pos*/ -3800, -204, 4600), - MACRO_OBJECT(/*preset*/ macro_breakable_box_three_coins, /*yaw*/ 45, /*pos*/ -3659, -204, 4459), - MACRO_OBJECT(/*preset*/ macro_jumping_box, /*yaw*/ 0, /*pos*/ -220, -220, 6140), - MACRO_OBJECT(/*preset*/ macro_1up, /*yaw*/ 0, /*pos*/ -3040, 1120, 5460), + MACRO_OBJECT (/*preset*/ macro_haunted_chair_2, /*yaw*/ 90, /*pos*/ -1960, -20, 340), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 0, /*pos*/ -800, -204, 2915, /*bhvParam*/ DIALOG_063), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 0, /*pos*/ 400, -204, 3057, /*bhvParam*/ DIALOG_085), + MACRO_OBJECT (/*preset*/ macro_haunted_chair_2, /*yaw*/ 270, /*pos*/ -1080, 20, 160), + MACRO_OBJECT (/*preset*/ macro_box_vanish_cap, /*yaw*/ 0, /*pos*/ 1268, 1050, 1860), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -1164, 0, 2325), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 2540, 820, 2174), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 2600, 815, -380), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 2950, 815, -1250), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -1500, 550, 960), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -420, 550, 60), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 2856, 50, 2144), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 50, 900, -1400), + MACRO_OBJECT (/*preset*/ macro_box_1up, /*yaw*/ 0, /*pos*/ 660, 3200, 1160), + MACRO_OBJECT (/*preset*/ macro_blue_coin_switch, /*yaw*/ 0, /*pos*/ 640, 1741, 760), + MACRO_OBJECT (/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ 1400, 1840, 1100), + MACRO_OBJECT (/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ 1700, 1840, 1100), + MACRO_OBJECT (/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ 0, 1840, 1100), + MACRO_OBJECT (/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ -400, 1840, 1100), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 0, /*pos*/ 2026, -204, 2966, /*bhvParam*/ DIALOG_102), + MACRO_OBJECT (/*preset*/ macro_mr_i, /*yaw*/ 0, /*pos*/ 480, 10, -653), + MACRO_OBJECT (/*preset*/ macro_scuttlebug, /*yaw*/ 0, /*pos*/ -346, -204, -2813), + MACRO_OBJECT (/*preset*/ macro_scuttlebug, /*yaw*/ 0, /*pos*/ 1146, -203, -2280), + MACRO_OBJECT (/*preset*/ macro_mr_i, /*yaw*/ 0, /*pos*/ -2369, -204, 5184), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 135, /*pos*/ -1546, -204, 4813, /*bhvParam*/ DIALOG_086), + MACRO_OBJECT (/*preset*/ macro_scuttlebug, /*yaw*/ 0, /*pos*/ 3466, -204, 5106), + MACRO_OBJECT (/*preset*/ macro_mr_i, /*yaw*/ 0, /*pos*/ 1640, 840, -733), + MACRO_OBJECT (/*preset*/ macro_box_vanish_cap, /*yaw*/ 0, /*pos*/ -1960, 300, -120), + MACRO_OBJECT (/*preset*/ macro_box_vanish_cap, /*yaw*/ 0, /*pos*/ 460, 2140, -560), + MACRO_OBJECT (/*preset*/ macro_box_ten_coins, /*yaw*/ 0, /*pos*/ 700, 80, -2800), + MACRO_OBJECT (/*preset*/ macro_breakable_box_three_coins, /*yaw*/ 45, /*pos*/ -3800, -204, 4600), + MACRO_OBJECT (/*preset*/ macro_breakable_box_three_coins, /*yaw*/ 45, /*pos*/ -3659, -204, 4459), + MACRO_OBJECT (/*preset*/ macro_jumping_box, /*yaw*/ 0, /*pos*/ -220, -220, 6140), + MACRO_OBJECT (/*preset*/ macro_1up, /*yaw*/ 0, /*pos*/ -3040, 1120, 5460), MACRO_OBJECT_END(), }; diff --git a/levels/bbh/areas/1/room.inc.c b/levels/bbh/areas/1/room.inc.c index 29bba9cd..7412fdfe 100644 --- a/levels/bbh/areas/1/room.inc.c +++ b/levels/bbh/areas/1/room.inc.c @@ -1,5 +1,5 @@ // 0x0702605C - 0x070268C2 -const u8 bbh_seg7_rooms[] = { +const RoomData bbh_seg7_rooms[] = { 13, 13, 13, 13, 13, 13, 13, 13, // 0-7 13, 13, 13, 13, 13, 13, 13, 13, // 8-15 13, 13, 29, 29, 13, 13, 13, 13, // 16-23 diff --git a/levels/bbh/coffin/geo.inc.c b/levels/bbh/coffin/geo.inc.c index baa97eba..361e6832 100644 --- a/levels/bbh/coffin/geo.inc.c +++ b/levels/bbh/coffin/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000658 const GeoLayout geo_bbh_000658[] = { - GEO_CULLING_RADIUS(800), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_070206F0), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(800), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_070206F0), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bbh/header.h b/levels/bbh/header.h index 74f49d83..de769e94 100644 --- a/levels/bbh/header.h +++ b/levels/bbh/header.h @@ -96,7 +96,7 @@ extern const Gfx bbh_seg7_dl_0701FFE8[]; extern const Gfx bbh_seg7_dl_070202F0[]; extern const Gfx bbh_seg7_dl_070206F0[]; extern const Collision bbh_seg7_collision_level[]; -extern const u8 bbh_seg7_rooms[]; +extern const RoomData bbh_seg7_rooms[]; extern const MacroObject bbh_seg7_macro_objs[]; extern const Collision bbh_seg7_collision_staircase_step[]; extern const Collision bbh_seg7_collision_tilt_floor_platform[]; diff --git a/levels/bbh/leveldata.c b/levels/bbh/leveldata.c index 74440b9b..cf30b06e 100644 --- a/levels/bbh/leveldata.c +++ b/levels/bbh/leveldata.c @@ -3,8 +3,8 @@ #include "surface_terrains.h" #include "moving_texture_macros.h" #include "level_misc_macros.h" -#include "macro_preset_names.h" -#include "special_preset_names.h" +#include "macro_presets.h" +#include "special_presets.h" #include "textures.h" #include "dialog_ids.h" diff --git a/levels/bbh/merry_go_round/geo.inc.c b/levels/bbh/merry_go_round/geo.inc.c index 4b75cdcd..fc5ce0c2 100644 --- a/levels/bbh/merry_go_round/geo.inc.c +++ b/levels/bbh/merry_go_round/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000640 const GeoLayout geo_bbh_000640[] = { - GEO_CULLING_RADIUS(2300), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_070202F0), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(2300), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_070202F0), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bbh/mesh_elevator/geo.inc.c b/levels/bbh/mesh_elevator/geo.inc.c index 80ef700a..2e75363f 100644 --- a/levels/bbh/mesh_elevator/geo.inc.c +++ b/levels/bbh/mesh_elevator/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000628 const GeoLayout geo_bbh_000628[] = { - GEO_CULLING_RADIUS(600), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, bbh_seg7_dl_0701FFE8), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(600), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, bbh_seg7_dl_0701FFE8), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bbh/moving_bookshelf/geo.inc.c b/levels/bbh/moving_bookshelf/geo.inc.c index 7e00a5d4..4757f1d5 100644 --- a/levels/bbh/moving_bookshelf/geo.inc.c +++ b/levels/bbh/moving_bookshelf/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000610 const GeoLayout geo_bbh_000610[] = { - GEO_CULLING_RADIUS(1000), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0701FD28), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(1000), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0701FD28), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bbh/script.c b/levels/bbh/script.c index bfa04334..aa8301ed 100644 --- a/levels/bbh/script.c +++ b/levels/bbh/script.c @@ -18,77 +18,77 @@ static const LevelScript script_func_local_1[] = { - OBJECT(/*model*/ MODEL_RED_FLAME, /*pos*/ 2089, 1331, -1125, /*angle*/ 0, 270, 0, /*behParam*/ 0x00000000, /*beh*/ bhvFlame), - OBJECT(/*model*/ MODEL_RED_FLAME, /*pos*/ 1331, 1075, -1330, /*angle*/ 0, 90, 0, /*behParam*/ 0x00000000, /*beh*/ bhvFlame), - OBJECT(/*model*/ MODEL_RED_FLAME, /*pos*/ 2089, 1331, -511, /*angle*/ 0, 270, 0, /*behParam*/ 0x00000000, /*beh*/ bhvFlame), - OBJECT(/*model*/ MODEL_RED_FLAME, /*pos*/ -511, 358, -1330, /*angle*/ 0, 90, 0, /*behParam*/ 0x00000000, /*beh*/ bhvFlame), - OBJECT(/*model*/ MODEL_RED_FLAME, /*pos*/ 1126, 358, 2212, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvFlame), - OBJECT(/*model*/ MODEL_RED_FLAME, /*pos*/ 205, 358, 2212, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvFlame), + OBJECT(/*model*/ MODEL_RED_FLAME, /*pos*/ 2089, 1331, -1125, /*angle*/ 0, 270, 0, /*bhvParam*/ 0, /*bhv*/ bhvFlame), + OBJECT(/*model*/ MODEL_RED_FLAME, /*pos*/ 1331, 1075, -1330, /*angle*/ 0, 90, 0, /*bhvParam*/ 0, /*bhv*/ bhvFlame), + OBJECT(/*model*/ MODEL_RED_FLAME, /*pos*/ 2089, 1331, -511, /*angle*/ 0, 270, 0, /*bhvParam*/ 0, /*bhv*/ bhvFlame), + OBJECT(/*model*/ MODEL_RED_FLAME, /*pos*/ -511, 358, -1330, /*angle*/ 0, 90, 0, /*bhvParam*/ 0, /*bhv*/ bhvFlame), + OBJECT(/*model*/ MODEL_RED_FLAME, /*pos*/ 1126, 358, 2212, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvFlame), + OBJECT(/*model*/ MODEL_RED_FLAME, /*pos*/ 205, 358, 2212, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvFlame), RETURN(), }; static const LevelScript script_func_local_2[] = { - OBJECT(/*model*/ MODEL_BBH_TILTING_FLOOR_PLATFORM, /*pos*/ 2866, 820, 1897, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvBbhTiltingTrapPlatform), - OBJECT(/*model*/ MODEL_BBH_TUMBLING_PLATFORM, /*pos*/ 2961, 0, -768, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvBbhTumblingBridge), - OBJECT(/*model*/ MODEL_BBH_MOVING_BOOKSHELF, /*pos*/ -1994, 819, 213, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvHauntedBookshelf), - OBJECT(/*model*/ MODEL_BBH_MESH_ELEVATOR, /*pos*/ -2985, -205, 5400, /*angle*/ 0, -45, 0, /*behParam*/ 0x00000000, /*beh*/ bhvMeshElevator), - OBJECT(/*model*/ MODEL_BBH_MERRY_GO_ROUND, /*pos*/ -205, -2560, 205, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvMerryGoRound), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 2200, 819, -800, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvCoffinSpawner), + OBJECT(/*model*/ MODEL_BBH_TILTING_FLOOR_PLATFORM, /*pos*/ 2866, 820, 1897, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvBBHTiltingTrapPlatform), + OBJECT(/*model*/ MODEL_BBH_TUMBLING_PLATFORM, /*pos*/ 2961, 0, -768, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvBBHTumblingBridge), + OBJECT(/*model*/ MODEL_BBH_MOVING_BOOKSHELF, /*pos*/ -1994, 819, 213, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvHauntedBookshelf), + OBJECT(/*model*/ MODEL_BBH_MESH_ELEVATOR, /*pos*/ -2985, -205, 5400, /*angle*/ 0, -45, 0, /*bhvParam*/ 0, /*bhv*/ bhvMeshElevator), + OBJECT(/*model*/ MODEL_BBH_MERRY_GO_ROUND, /*pos*/ -205, -2560, 205, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvMerryGoRound), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 2200, 819, -800, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvCoffinSpawner), RETURN(), }; static const LevelScript script_func_local_3[] = { - OBJECT_WITH_ACTS(/*model*/ MODEL_BOO, /*pos*/ 1000, 50, 1000, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvGhostHuntBigBoo, /*acts*/ ACT_1), - OBJECT_WITH_ACTS(/*model*/ MODEL_BOO, /*pos*/ 20, 100, -908, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvGhostHuntBoo, /*acts*/ ACT_1), - OBJECT_WITH_ACTS(/*model*/ MODEL_BOO, /*pos*/ 3150, 100, 398, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvGhostHuntBoo, /*acts*/ ACT_1), - OBJECT_WITH_ACTS(/*model*/ MODEL_BOO, /*pos*/ -2000, 150, -800, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvGhostHuntBoo, /*acts*/ ACT_1), - OBJECT_WITH_ACTS(/*model*/ MODEL_BOO, /*pos*/ 2851, 100, 2289, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvGhostHuntBoo, /*acts*/ ACT_1), - OBJECT_WITH_ACTS(/*model*/ MODEL_BOO, /*pos*/ -1551, 100, -1018, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvGhostHuntBoo, /*acts*/ ACT_1), - OBJECT_WITH_ACTS(/*model*/ MODEL_BBH_STAIRCASE_STEP, /*pos*/ 973, 0, 517, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvHiddenStaircaseStep, /*acts*/ ACT_2 | ACT_3 | ACT_4 | ACT_5 | ACT_6), - OBJECT_WITH_ACTS(/*model*/ MODEL_BBH_STAIRCASE_STEP, /*pos*/ 973, -206, 717, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvHiddenStaircaseStep, /*acts*/ ACT_2 | ACT_3 | ACT_4 | ACT_5 | ACT_6), - OBJECT_WITH_ACTS(/*model*/ MODEL_BBH_STAIRCASE_STEP, /*pos*/ 973, -412, 917, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvHiddenStaircaseStep, /*acts*/ ACT_2 | ACT_3 | ACT_4 | ACT_5 | ACT_6), - OBJECT_WITH_ACTS(/*model*/ MODEL_BOO, /*pos*/ 20, 100, -908, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvBoo, /*acts*/ ACT_2 | ACT_3 | ACT_4 | ACT_5 | ACT_6), - OBJECT_WITH_ACTS(/*model*/ MODEL_BOO, /*pos*/ 3150, 100, 398, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvBoo, /*acts*/ ACT_2 | ACT_3 | ACT_4 | ACT_5 | ACT_6), - OBJECT_WITH_ACTS(/*model*/ MODEL_BOO, /*pos*/ -2000, 150, -800, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvBoo, /*acts*/ ACT_2 | ACT_3 | ACT_4 | ACT_5 | ACT_6), - OBJECT_WITH_ACTS(/*model*/ MODEL_BOO, /*pos*/ 2851, 100, 2289, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvBoo, /*acts*/ ACT_2 | ACT_3 | ACT_4 | ACT_5 | ACT_6), - OBJECT_WITH_ACTS(/*model*/ MODEL_BOO, /*pos*/ -1551, 100, -1018, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvBoo, /*acts*/ ACT_2 | ACT_3 | ACT_4 | ACT_5 | ACT_6), - OBJECT_WITH_ACTS(/*model*/ MODEL_NONE, /*pos*/ 990, -2146, -908, /*angle*/ 0, -45, 0, /*behParam*/ 0x00030000, /*beh*/ bhvFlamethrower, /*acts*/ ACT_2 | ACT_3 | ACT_4 | ACT_5 | ACT_6), - OBJECT_WITH_ACTS(/*model*/ MODEL_NONE, /*pos*/ -1100, -2372, 1100, /*angle*/ 0, 135, 0, /*behParam*/ 0x01000000, /*beh*/ bhvMerryGoRoundBooManager, /*acts*/ ACT_2 | ACT_3 | ACT_4 | ACT_5 | ACT_6), - OBJECT_WITH_ACTS(/*model*/ MODEL_BOO, /*pos*/ 1030, 1922, 2546, /*angle*/ 0, -90, 0, /*behParam*/ 0x04000000, /*beh*/ bhvBalconyBigBoo, /*acts*/ ALL_ACTS), - OBJECT_WITH_ACTS(/*model*/ MODEL_BOO, /*pos*/ 581, 1850, -206, /*angle*/ 0, -90, 0, /*behParam*/ 0x00000000, /*beh*/ bhvBoo, /*acts*/ ALL_ACTS), - OBJECT(/*model*/ MODEL_MAD_PIANO, /*pos*/ -1300, 0, 2310, /*angle*/ 0, 243, 0, /*behParam*/ 0x00000000, /*beh*/ bhvMadPiano), - OBJECT(/*model*/ MODEL_HAUNTED_CHAIR, /*pos*/ -1530, 0, 2200, /*angle*/ 0, 66, 0, /*behParam*/ 0x00000000, /*beh*/ bhvHauntedChair), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -1330, 890, 200, /*angle*/ 0, 90, 0, /*behParam*/ 0x00000000, /*beh*/ bhvBookendSpawn), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -818, 890, -200, /*angle*/ 0, 270, 0, /*behParam*/ 0x00000000, /*beh*/ bhvBookendSpawn), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -1330, 890, -622, /*angle*/ 0, 90, 0, /*behParam*/ 0x00000000, /*beh*/ bhvBookendSpawn), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -818, 890, -686, /*angle*/ 0, 270, 0, /*behParam*/ 0x00000000, /*beh*/ bhvBookendSpawn), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -1950, 880, 8, /*angle*/ 0, 180, 0, /*behParam*/ 0x00000000, /*beh*/ bhvHauntedBookshelfManager), - OBJECT(/*model*/ MODEL_BOOKEND, /*pos*/ 2680, 1045, 876, /*angle*/ 0, 166, 0, /*behParam*/ 0x00000000, /*beh*/ bhvFlyingBookend), - OBJECT(/*model*/ MODEL_BOOKEND, /*pos*/ 3075, 1045, 995, /*angle*/ 0, 166, 0, /*behParam*/ 0x00000000, /*beh*/ bhvFlyingBookend), - OBJECT(/*model*/ MODEL_BOOKEND, /*pos*/ -1411, 218, 922, /*angle*/ 0, 180, 0, /*behParam*/ 0x00000000, /*beh*/ bhvFlyingBookend), + OBJECT_WITH_ACTS(/*model*/ MODEL_BOO, /*pos*/ 1000, 50, 1000, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(STAR_INDEX_ACT_1) | BPARAM2(BIG_BOO_BP_GHOST_HUNT), /*bhv*/ bhvGhostHuntBigBoo, /*acts*/ ACT_1), + OBJECT_WITH_ACTS(/*model*/ MODEL_BOO, /*pos*/ 20, 100, -908, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(BOO_BP_GHOST_HUNT), /*bhv*/ bhvGhostHuntBoo, /*acts*/ ACT_1), + OBJECT_WITH_ACTS(/*model*/ MODEL_BOO, /*pos*/ 3150, 100, 398, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(BOO_BP_GHOST_HUNT), /*bhv*/ bhvGhostHuntBoo, /*acts*/ ACT_1), + OBJECT_WITH_ACTS(/*model*/ MODEL_BOO, /*pos*/ -2000, 150, -800, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(BOO_BP_GHOST_HUNT), /*bhv*/ bhvGhostHuntBoo, /*acts*/ ACT_1), + OBJECT_WITH_ACTS(/*model*/ MODEL_BOO, /*pos*/ 2851, 100, 2289, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(BOO_BP_GHOST_HUNT), /*bhv*/ bhvGhostHuntBoo, /*acts*/ ACT_1), + OBJECT_WITH_ACTS(/*model*/ MODEL_BOO, /*pos*/ -1551, 100, -1018, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(BOO_BP_GHOST_HUNT), /*bhv*/ bhvGhostHuntBoo, /*acts*/ ACT_1), + OBJECT_WITH_ACTS(/*model*/ MODEL_BBH_STAIRCASE_STEP, /*pos*/ 973, 0, 517, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvHiddenStaircaseStep, /*acts*/ ACT_2 | ACT_3 | ACT_4 | ACT_5 | ACT_6), + OBJECT_WITH_ACTS(/*model*/ MODEL_BBH_STAIRCASE_STEP, /*pos*/ 973, -206, 717, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvHiddenStaircaseStep, /*acts*/ ACT_2 | ACT_3 | ACT_4 | ACT_5 | ACT_6), + OBJECT_WITH_ACTS(/*model*/ MODEL_BBH_STAIRCASE_STEP, /*pos*/ 973, -412, 917, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvHiddenStaircaseStep, /*acts*/ ACT_2 | ACT_3 | ACT_4 | ACT_5 | ACT_6), + OBJECT_WITH_ACTS(/*model*/ MODEL_BOO, /*pos*/ 20, 100, -908, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvBoo, /*acts*/ ACT_2 | ACT_3 | ACT_4 | ACT_5 | ACT_6), + OBJECT_WITH_ACTS(/*model*/ MODEL_BOO, /*pos*/ 3150, 100, 398, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvBoo, /*acts*/ ACT_2 | ACT_3 | ACT_4 | ACT_5 | ACT_6), + OBJECT_WITH_ACTS(/*model*/ MODEL_BOO, /*pos*/ -2000, 150, -800, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvBoo, /*acts*/ ACT_2 | ACT_3 | ACT_4 | ACT_5 | ACT_6), + OBJECT_WITH_ACTS(/*model*/ MODEL_BOO, /*pos*/ 2851, 100, 2289, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvBoo, /*acts*/ ACT_2 | ACT_3 | ACT_4 | ACT_5 | ACT_6), + OBJECT_WITH_ACTS(/*model*/ MODEL_BOO, /*pos*/ -1551, 100, -1018, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvBoo, /*acts*/ ACT_2 | ACT_3 | ACT_4 | ACT_5 | ACT_6), + OBJECT_WITH_ACTS(/*model*/ MODEL_NONE, /*pos*/ 990, -2146, -908, /*angle*/ 0, -45, 0, /*bhvParam*/ BPARAM2(0x03), /*bhv*/ bhvFlamethrower, /*acts*/ ACT_2 | ACT_3 | ACT_4 | ACT_5 | ACT_6), + OBJECT_WITH_ACTS(/*model*/ MODEL_NONE, /*pos*/ -1100, -2372, 1100, /*angle*/ 0, 135, 0, /*bhvParam*/ BPARAM1(STAR_INDEX_ACT_2), /*bhv*/ bhvMerryGoRoundBooManager, /*acts*/ ACT_2 | ACT_3 | ACT_4 | ACT_5 | ACT_6), + OBJECT_WITH_ACTS(/*model*/ MODEL_BOO, /*pos*/ 1030, 1922, 2546, /*angle*/ 0, -90, 0, /*bhvParam*/ BPARAM1(STAR_INDEX_ACT_5), /*bhv*/ bhvBalconyBigBoo, /*acts*/ ALL_ACTS), + OBJECT_WITH_ACTS(/*model*/ MODEL_BOO, /*pos*/ 581, 1850, -206, /*angle*/ 0, -90, 0, /*bhvParam*/ 0, /*bhv*/ bhvBoo, /*acts*/ ALL_ACTS), + OBJECT (/*model*/ MODEL_MAD_PIANO, /*pos*/ -1300, 0, 2310, /*angle*/ 0, 243, 0, /*bhvParam*/ 0, /*bhv*/ bhvMadPiano), + OBJECT (/*model*/ MODEL_HAUNTED_CHAIR, /*pos*/ -1530, 0, 2200, /*angle*/ 0, 66, 0, /*bhvParam*/ 0, /*bhv*/ bhvHauntedChair), + OBJECT (/*model*/ MODEL_NONE, /*pos*/ -1330, 890, 200, /*angle*/ 0, 90, 0, /*bhvParam*/ 0, /*bhv*/ bhvBookendSpawn), + OBJECT (/*model*/ MODEL_NONE, /*pos*/ -818, 890, -200, /*angle*/ 0, 270, 0, /*bhvParam*/ 0, /*bhv*/ bhvBookendSpawn), + OBJECT (/*model*/ MODEL_NONE, /*pos*/ -1330, 890, -622, /*angle*/ 0, 90, 0, /*bhvParam*/ 0, /*bhv*/ bhvBookendSpawn), + OBJECT (/*model*/ MODEL_NONE, /*pos*/ -818, 890, -686, /*angle*/ 0, 270, 0, /*bhvParam*/ 0, /*bhv*/ bhvBookendSpawn), + OBJECT (/*model*/ MODEL_NONE, /*pos*/ -1950, 880, 8, /*angle*/ 0, 180, 0, /*bhvParam*/ 0, /*bhv*/ bhvHauntedBookshelfManager), + OBJECT (/*model*/ MODEL_BOOKEND, /*pos*/ 2680, 1045, 876, /*angle*/ 0, 166, 0, /*bhvParam*/ 0, /*bhv*/ bhvFlyingBookend), + OBJECT (/*model*/ MODEL_BOOKEND, /*pos*/ 3075, 1045, 995, /*angle*/ 0, 166, 0, /*bhvParam*/ 0, /*bhv*/ bhvFlyingBookend), + OBJECT (/*model*/ MODEL_BOOKEND, /*pos*/ -1411, 218, 922, /*angle*/ 0, 180, 0, /*bhvParam*/ 0, /*bhv*/ bhvFlyingBookend), RETURN(), }; static const LevelScript script_func_local_4[] = { - OBJECT_WITH_ACTS(/*model*/ MODEL_STAR, /*pos*/ -2030, 1350, 1940, /*angle*/ 0, 0, 0, /*behParam*/ 0x02000000, /*beh*/ bhvStar, /*acts*/ ALL_ACTS), - OBJECT_WITH_ACTS(/*model*/ MODEL_NONE, /*pos*/ -204, 1100, 1576, /*angle*/ 0, 0, 0, /*behParam*/ 0x03000000, /*beh*/ bhvHiddenRedCoinStar, /*acts*/ ALL_ACTS), - OBJECT_WITH_ACTS(/*model*/ MODEL_NONE, /*pos*/ 923, 1741, -332, /*angle*/ 0, 18, 0, /*behParam*/ 0x05010000, /*beh*/ bhvMrI, /*acts*/ ALL_ACTS), + OBJECT_WITH_ACTS(/*model*/ MODEL_STAR, /*pos*/ -2030, 1350, 1940, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(STAR_INDEX_ACT_3), /*bhv*/ bhvStar, /*acts*/ ALL_ACTS), + OBJECT_WITH_ACTS(/*model*/ MODEL_NONE, /*pos*/ -204, 1100, 1576, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(STAR_INDEX_ACT_4), /*bhv*/ bhvHiddenRedCoinStar, /*acts*/ ALL_ACTS), + OBJECT_WITH_ACTS(/*model*/ MODEL_NONE, /*pos*/ 923, 1741, -332, /*angle*/ 0, 18, 0, /*bhvParam*/ BPARAM1(STAR_INDEX_ACT_6) | BPARAM2(0x01), /*bhv*/ bhvMrI, /*acts*/ ALL_ACTS), RETURN(), }; const LevelScript level_bbh_entry[] = { INIT_LEVEL(), - LOAD_MIO0( /*seg*/ 0x07, _bbh_segment_7SegmentRomStart, _bbh_segment_7SegmentRomEnd), - LOAD_MIO0( /*seg*/ 0x0A, _bbh_skybox_mio0SegmentRomStart, _bbh_skybox_mio0SegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x07, _bbh_segment_7SegmentRomStart, _bbh_segment_7SegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x0A, _bbh_skybox_mio0SegmentRomStart, _bbh_skybox_mio0SegmentRomEnd), LOAD_MIO0_TEXTURE(/*seg*/ 0x09, _spooky_mio0SegmentRomStart, _spooky_mio0SegmentRomEnd), - LOAD_MIO0( /*seg*/ 0x05, _group9_mio0SegmentRomStart, _group9_mio0SegmentRomEnd), - LOAD_RAW( /*seg*/ 0x0C, _group9_geoSegmentRomStart, _group9_geoSegmentRomEnd), - LOAD_MIO0( /*seg*/ 0x06, _group17_mio0SegmentRomStart, _group17_mio0SegmentRomEnd), - LOAD_RAW( /*seg*/ 0x0D, _group17_geoSegmentRomStart, _group17_geoSegmentRomEnd), - LOAD_MIO0( /*seg*/ 0x08, _common0_mio0SegmentRomStart, _common0_mio0SegmentRomEnd), - LOAD_RAW( /*seg*/ 0x0F, _common0_geoSegmentRomStart, _common0_geoSegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x05, _group9_mio0SegmentRomStart, _group9_mio0SegmentRomEnd), + LOAD_RAW (/*seg*/ 0x0C, _group9_geoSegmentRomStart, _group9_geoSegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x06, _group17_mio0SegmentRomStart, _group17_mio0SegmentRomEnd), + LOAD_RAW (/*seg*/ 0x0D, _group17_geoSegmentRomStart, _group17_geoSegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x08, _common0_mio0SegmentRomStart, _common0_mio0SegmentRomEnd), + LOAD_RAW (/*seg*/ 0x0F, _common0_geoSegmentRomStart, _common0_geoSegmentRomEnd), ALLOC_LEVEL_POOL(), - MARIO(/*model*/ MODEL_MARIO, /*behParam*/ 0x00000001, /*beh*/ bhvMario), + MARIO(/*model*/ MODEL_MARIO, /*bhvParam*/ BPARAM4(0x01), /*bhv*/ bhvMario), JUMP_LINK(script_func_global_1), JUMP_LINK(script_func_global_10), JUMP_LINK(script_func_global_18), @@ -107,10 +107,10 @@ const LevelScript level_bbh_entry[] = { JUMP_LINK(script_func_local_2), JUMP_LINK(script_func_local_3), JUMP_LINK(script_func_local_4), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 666, 796, 5350, /*angle*/ 0, 180, 0, /*behParam*/ 0x000A0000, /*beh*/ bhvSpinAirborneWarp), - WARP_NODE(/*id*/ 0x0A, /*destLevel*/ LEVEL_BBH, /*destArea*/ 0x01, /*destNode*/ 0x0A, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0xF0, /*destLevel*/ LEVEL_CASTLE_COURTYARD, /*destArea*/ 0x01, /*destNode*/ 0x0A, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0xF1, /*destLevel*/ LEVEL_CASTLE_COURTYARD, /*destArea*/ 0x01, /*destNode*/ 0x0B, /*flags*/ WARP_NO_CHECKPOINT), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 666, 796, 5350, /*angle*/ 0, 180, 0, /*bhvParam*/ BPARAM2(WARP_NODE_0A), /*bhv*/ bhvSpinAirborneWarp), + WARP_NODE(/*id*/ WARP_NODE_0A, /*destLevel*/ LEVEL_BBH, /*destArea*/ 1, /*destNode*/ WARP_NODE_0A, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_SUCCESS, /*destLevel*/ LEVEL_CASTLE_COURTYARD, /*destArea*/ 1, /*destNode*/ WARP_NODE_0A, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_DEATH, /*destLevel*/ LEVEL_CASTLE_COURTYARD, /*destArea*/ 1, /*destNode*/ WARP_NODE_0B, /*flags*/ WARP_NO_CHECKPOINT), TERRAIN(/*terrainData*/ bbh_seg7_collision_level), MACRO_OBJECTS(/*objList*/ bbh_seg7_macro_objs), ROOMS(/*surfaceRooms*/ bbh_seg7_rooms), diff --git a/levels/bbh/staircase_step/geo.inc.c b/levels/bbh/staircase_step/geo.inc.c index 7592fe2c..acc31f78 100644 --- a/levels/bbh/staircase_step/geo.inc.c +++ b/levels/bbh/staircase_step/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E0005B0 const GeoLayout geo_bbh_0005B0[] = { - GEO_CULLING_RADIUS(700), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0701F2E8), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(700), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0701F2E8), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bbh/tilting_trap_platform/geo.inc.c b/levels/bbh/tilting_trap_platform/geo.inc.c index 81844d68..9c1f42d5 100644 --- a/levels/bbh/tilting_trap_platform/geo.inc.c +++ b/levels/bbh/tilting_trap_platform/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E0005C8 const GeoLayout geo_bbh_0005C8[] = { - GEO_CULLING_RADIUS(600), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0701F5F8), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(600), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0701F5F8), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bbh/tumbling_platform_far/geo.inc.c b/levels/bbh/tumbling_platform_far/geo.inc.c index ca2ae057..b10d459d 100644 --- a/levels/bbh/tumbling_platform_far/geo.inc.c +++ b/levels/bbh/tumbling_platform_far/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E0005E0 const GeoLayout geo_bbh_0005E0[] = { - GEO_CULLING_RADIUS(650), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0701F7E8), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(650), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0701F7E8), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bbh/tumbling_platform_near/geo.inc.c b/levels/bbh/tumbling_platform_near/geo.inc.c index bfa6c6bc..447ee85a 100644 --- a/levels/bbh/tumbling_platform_near/geo.inc.c +++ b/levels/bbh/tumbling_platform_near/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E0005F8 const GeoLayout geo_bbh_0005F8[] = { - GEO_CULLING_RADIUS(300), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0701FAB0), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(300), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bbh_seg7_dl_0701FAB0), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bitdw/areas/1/geo.inc.c b/levels/bitdw/areas/1/geo.inc.c index 39f6143e..949abbe5 100644 --- a/levels/bitdw/areas/1/geo.inc.c +++ b/levels/bitdw/areas/1/geo.inc.c @@ -1,26 +1,26 @@ // 0x0E000618 const GeoLayout geo_bitdw_000618[] = { - GEO_NODE_SCREEN_AREA(10, SCREEN_WIDTH/2, SCREEN_HEIGHT/2, SCREEN_WIDTH/2, SCREEN_HEIGHT/2), - GEO_OPEN_NODE(), - GEO_ZBUFFER(0), - GEO_OPEN_NODE(), - GEO_NODE_ORTHO(100), - GEO_OPEN_NODE(), - GEO_BACKGROUND(BACKGROUND_GREEN_SKY, geo_skybox_main), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ZBUFFER(1), - GEO_OPEN_NODE(), - GEO_CAMERA_FRUSTUM_WITH_FUNC(45, 100, 20000, geo_camera_fov), - GEO_OPEN_NODE(), - GEO_CAMERA(14, 0, 2000, 6000, 0, 0, 0, geo_camera_main), + GEO_NODE_SCREEN_AREA(10, SCREEN_WIDTH/2, SCREEN_HEIGHT/2, SCREEN_WIDTH/2, SCREEN_HEIGHT/2), + GEO_OPEN_NODE(), + GEO_ZBUFFER(0), + GEO_OPEN_NODE(), + GEO_NODE_ORTHO(100), GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, bitdw_seg7_dl_070020C8), - GEO_RENDER_OBJ(), - GEO_ASM(0, geo_envfx_main), + GEO_BACKGROUND(BACKGROUND_GREEN_SKY, geo_skybox_main), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CLOSE_NODE(), + GEO_ZBUFFER(1), + GEO_OPEN_NODE(), + GEO_CAMERA_FRUSTUM_WITH_FUNC(45, 100, 20000, geo_camera_fov), + GEO_OPEN_NODE(), + GEO_CAMERA(14, 0, 2000, 6000, 0, 0, 0, geo_camera_main), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, bitdw_seg7_dl_070020C8), + GEO_RENDER_OBJ(), + GEO_ASM(0, geo_envfx_main), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bitdw/areas/1/large_platform/geo.inc.c b/levels/bitdw/areas/1/large_platform/geo.inc.c index d4b11233..fb9fa108 100644 --- a/levels/bitdw/areas/1/large_platform/geo.inc.c +++ b/levels/bitdw/areas/1/large_platform/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E0003D8 const GeoLayout geo_bitdw_0003D8[] = { - GEO_CULLING_RADIUS(2300), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bitdw_seg7_dl_070032F8), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(2300), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bitdw_seg7_dl_070032F8), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bitdw/areas/1/macro.inc.c b/levels/bitdw/areas/1/macro.inc.c index cf1783a1..e593eff8 100644 --- a/levels/bitdw/areas/1/macro.inc.c +++ b/levels/bitdw/areas/1/macro.inc.c @@ -1,63 +1,63 @@ // 0x0700F438 - 0x0700F688 const MacroObject bitdw_seg7_macro_objs[] = { - MACRO_OBJECT(/*preset*/ macro_box_metal_cap, /*yaw*/ 0, /*pos*/ -6420, -2900, 3880), - MACRO_OBJECT(/*preset*/ macro_coin_ring_horizontal_flying, /*yaw*/ 0, /*pos*/ -1660, -3000, 3900), - MACRO_OBJECT(/*preset*/ macro_coin_line_horizontal, /*yaw*/ 0, /*pos*/ -2400, -800, 1900), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_circling_amp, /*yaw*/ 0, /*pos*/ -5300, 20, 1000, /*behParam*/ 0), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_circling_amp, /*yaw*/ 0, /*pos*/ -7140, 500, 380, /*behParam*/ 1), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_circling_amp, /*yaw*/ 0, /*pos*/ -7120, 1050, -2080, /*behParam*/ 1), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_circling_amp, /*yaw*/ 0, /*pos*/ -6480, 240, 1000, /*behParam*/ 0), - MACRO_OBJECT(/*preset*/ macro_coin_ring_horizontal_flying, /*yaw*/ 0, /*pos*/ -2060, 1200, -940), - MACRO_OBJECT(/*preset*/ macro_yellow_coin, /*yaw*/ 0, /*pos*/ -170, 1070, 300), - MACRO_OBJECT(/*preset*/ macro_yellow_coin, /*yaw*/ 0, /*pos*/ -170, 1070, 700), - MACRO_OBJECT(/*preset*/ macro_yellow_coin, /*yaw*/ 0, /*pos*/ 1450, 1400, 300), - MACRO_OBJECT(/*preset*/ macro_yellow_coin, /*yaw*/ 0, /*pos*/ 1450, 1400, 700), - MACRO_OBJECT(/*preset*/ macro_coin_line_horizontal, /*yaw*/ 90, /*pos*/ 1660, -1980, 3660), - MACRO_OBJECT(/*preset*/ macro_goomba, /*yaw*/ 0, /*pos*/ 3180, 1020, 240), - MACRO_OBJECT(/*preset*/ macro_goomba, /*yaw*/ 0, /*pos*/ 2860, 1020, 580), - MACRO_OBJECT(/*preset*/ macro_yellow_coin, /*yaw*/ 0, /*pos*/ 4640, 2360, 0), - MACRO_OBJECT(/*preset*/ macro_yellow_coin, /*yaw*/ 0, /*pos*/ 4900, 2600, 0), - MACRO_OBJECT(/*preset*/ macro_yellow_coin, /*yaw*/ 0, /*pos*/ 5180, 2820, 0), - MACRO_OBJECT(/*preset*/ macro_yellow_coin, /*yaw*/ 0, /*pos*/ 2760, 1940, 500), - MACRO_OBJECT(/*preset*/ macro_yellow_coin, /*yaw*/ 0, /*pos*/ 2760, 1940, 180), - MACRO_OBJECT(/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ -2460, 812, 800), - MACRO_OBJECT(/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ -3080, 813, 840), - MACRO_OBJECT(/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ -3660, 873, 620), - MACRO_OBJECT(/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ -4060, 1011, 240), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_circling_amp, /*yaw*/ 0, /*pos*/ -4620, 1220, -300, /*behParam*/ 2), - MACRO_OBJECT(/*preset*/ macro_coin_ring_horizontal, /*yaw*/ 0, /*pos*/ -4620, 1220, -300), - MACRO_OBJECT(/*preset*/ macro_box_1up, /*yaw*/ 0, /*pos*/ -4860, 1380, -300), - MACRO_OBJECT(/*preset*/ macro_yellow_coin, /*yaw*/ 0, /*pos*/ -150, -1200, 3660), - MACRO_OBJECT(/*preset*/ macro_box_three_coins, /*yaw*/ 0, /*pos*/ -5120, 1460, -2140), - MACRO_OBJECT(/*preset*/ macro_yellow_coin, /*yaw*/ 0, /*pos*/ 4380, 2120, 0), - MACRO_OBJECT(/*preset*/ macro_yellow_coin, /*yaw*/ 0, /*pos*/ 5420, 3000, 0), - MACRO_OBJECT(/*preset*/ macro_yellow_coin, /*yaw*/ 0, /*pos*/ -2357, 1200, -2454), - MACRO_OBJECT(/*preset*/ macro_yellow_coin, /*yaw*/ 0, /*pos*/ -2357, 1300, -2454), - MACRO_OBJECT(/*preset*/ macro_goomba, /*yaw*/ 0, /*pos*/ -2560, -1433, 3280), - MACRO_OBJECT(/*preset*/ macro_goomba, /*yaw*/ 0, /*pos*/ -2060, -1433, 3540), - MACRO_OBJECT(/*preset*/ macro_goomba, /*yaw*/ 0, /*pos*/ -2720, -1433, 3860), - MACRO_OBJECT(/*preset*/ macro_goomba, /*yaw*/ 0, /*pos*/ -1680, 1024, 580), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -3100, -2900, 4520), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -4740, 1050, -2130), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -3120, 1160, -2570), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -4613, 1220, -427), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -1000, 1933, 466), - MACRO_OBJECT(/*preset*/ macro_1up_2, /*yaw*/ 0, /*pos*/ 33, 1900, 333), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -6475, 125, 890), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -7810, -3100, 4900), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 1500, 1066, -166), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 0, /*pos*/ 5940, 2765, -280, /*behParam*/ DIALOG_066), - MACRO_OBJECT(/*preset*/ macro_yellow_coin, /*yaw*/ 0, /*pos*/ -2357, 1400, -2454), - MACRO_OBJECT(/*preset*/ macro_yellow_coin, /*yaw*/ 0, /*pos*/ -170, 1070, 500), - MACRO_OBJECT(/*preset*/ macro_yellow_coin, /*yaw*/ 0, /*pos*/ 1450, 1400, 500), - MACRO_OBJECT(/*preset*/ macro_1up, /*yaw*/ 0, /*pos*/ 610, 1045, -167), - MACRO_OBJECT(/*preset*/ macro_1up_2, /*yaw*/ 0, /*pos*/ -485, 1054, -167), - MACRO_OBJECT(/*preset*/ macro_1up_3, /*yaw*/ 0, /*pos*/ 1100, 2080, 363), - MACRO_OBJECT(/*preset*/ macro_floor_switch_hidden_objects, /*yaw*/ 0, /*pos*/ -3100, -2946, 3530), - MACRO_OBJECT(/*preset*/ macro_hidden_box, /*yaw*/ 0, /*pos*/ -7810, -3360, 4500), - MACRO_OBJECT(/*preset*/ macro_hidden_box, /*yaw*/ 0, /*pos*/ -7810, -3360, 4700), - MACRO_OBJECT(/*preset*/ macro_hidden_box, /*yaw*/ 0, /*pos*/ -7810, -3360, 4900), - MACRO_OBJECT(/*preset*/ macro_hidden_box, /*yaw*/ 0, /*pos*/ -3100, -3145, 4518), - MACRO_OBJECT(/*preset*/ macro_box_1up_running_away, /*yaw*/ 0, /*pos*/ -2420, -1140, 3700), + MACRO_OBJECT (/*preset*/ macro_box_metal_cap, /*yaw*/ 0, /*pos*/ -6420, -2900, 3880), + MACRO_OBJECT (/*preset*/ macro_coin_ring_horizontal_flying, /*yaw*/ 0, /*pos*/ -1660, -3000, 3900), + MACRO_OBJECT (/*preset*/ macro_coin_line_horizontal, /*yaw*/ 0, /*pos*/ -2400, -800, 1900), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_circling_amp, /*yaw*/ 0, /*pos*/ -5300, 20, 1000, /*bhvParam*/ AMP_BP_ROT_RADIUS_200), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_circling_amp, /*yaw*/ 0, /*pos*/ -7140, 500, 380, /*bhvParam*/ AMP_BP_ROT_RADIUS_300), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_circling_amp, /*yaw*/ 0, /*pos*/ -7120, 1050, -2080, /*bhvParam*/ AMP_BP_ROT_RADIUS_300), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_circling_amp, /*yaw*/ 0, /*pos*/ -6480, 240, 1000, /*bhvParam*/ AMP_BP_ROT_RADIUS_200), + MACRO_OBJECT (/*preset*/ macro_coin_ring_horizontal_flying, /*yaw*/ 0, /*pos*/ -2060, 1200, -940), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_1, /*yaw*/ 0, /*pos*/ -170, 1070, 300), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_1, /*yaw*/ 0, /*pos*/ -170, 1070, 700), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_1, /*yaw*/ 0, /*pos*/ 1450, 1400, 300), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_1, /*yaw*/ 0, /*pos*/ 1450, 1400, 700), + MACRO_OBJECT (/*preset*/ macro_coin_line_horizontal, /*yaw*/ 90, /*pos*/ 1660, -1980, 3660), + MACRO_OBJECT (/*preset*/ macro_goomba, /*yaw*/ 0, /*pos*/ 3180, 1020, 240), + MACRO_OBJECT (/*preset*/ macro_goomba, /*yaw*/ 0, /*pos*/ 2860, 1020, 580), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_1, /*yaw*/ 0, /*pos*/ 4640, 2360, 0), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_1, /*yaw*/ 0, /*pos*/ 4900, 2600, 0), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_1, /*yaw*/ 0, /*pos*/ 5180, 2820, 0), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_1, /*yaw*/ 0, /*pos*/ 2760, 1940, 500), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_1, /*yaw*/ 0, /*pos*/ 2760, 1940, 180), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ -2460, 812, 800), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ -3080, 813, 840), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ -3660, 873, 620), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ -4060, 1011, 240), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_circling_amp, /*yaw*/ 0, /*pos*/ -4620, 1220, -300, /*bhvParam*/ AMP_BP_ROT_RADIUS_400), + MACRO_OBJECT (/*preset*/ macro_coin_ring_horizontal, /*yaw*/ 0, /*pos*/ -4620, 1220, -300), + MACRO_OBJECT (/*preset*/ macro_box_1up, /*yaw*/ 0, /*pos*/ -4860, 1380, -300), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_1, /*yaw*/ 0, /*pos*/ -150, -1200, 3660), + MACRO_OBJECT (/*preset*/ macro_box_three_coins, /*yaw*/ 0, /*pos*/ -5120, 1460, -2140), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_1, /*yaw*/ 0, /*pos*/ 4380, 2120, 0), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_1, /*yaw*/ 0, /*pos*/ 5420, 3000, 0), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_1, /*yaw*/ 0, /*pos*/ -2357, 1200, -2454), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_1, /*yaw*/ 0, /*pos*/ -2357, 1300, -2454), + MACRO_OBJECT (/*preset*/ macro_goomba, /*yaw*/ 0, /*pos*/ -2560, -1433, 3280), + MACRO_OBJECT (/*preset*/ macro_goomba, /*yaw*/ 0, /*pos*/ -2060, -1433, 3540), + MACRO_OBJECT (/*preset*/ macro_goomba, /*yaw*/ 0, /*pos*/ -2720, -1433, 3860), + MACRO_OBJECT (/*preset*/ macro_goomba, /*yaw*/ 0, /*pos*/ -1680, 1024, 580), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -3100, -2900, 4520), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -4740, 1050, -2130), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -3120, 1160, -2570), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -4613, 1220, -427), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -1000, 1933, 466), + MACRO_OBJECT (/*preset*/ macro_1up_beat_bitdw_bowser, /*yaw*/ 0, /*pos*/ 33, 1900, 333), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -6475, 125, 890), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -7810, -3100, 4900), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 1500, 1066, -166), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 0, /*pos*/ 5940, 2765, -280, /*bhvParam*/ DIALOG_066), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_1, /*yaw*/ 0, /*pos*/ -2357, 1400, -2454), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_1, /*yaw*/ 0, /*pos*/ -170, 1070, 500), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_1, /*yaw*/ 0, /*pos*/ 1450, 1400, 500), + MACRO_OBJECT (/*preset*/ macro_1up, /*yaw*/ 0, /*pos*/ 610, 1045, -167), + MACRO_OBJECT (/*preset*/ macro_1up_beat_bitdw_bowser, /*yaw*/ 0, /*pos*/ -485, 1054, -167), + MACRO_OBJECT (/*preset*/ macro_1up_beat_bitfs_bowser, /*yaw*/ 0, /*pos*/ 1100, 2080, 363), + MACRO_OBJECT (/*preset*/ macro_floor_switch_hidden_objects, /*yaw*/ 0, /*pos*/ -3100, -2946, 3530), + MACRO_OBJECT (/*preset*/ macro_hidden_breakable_box, /*yaw*/ 0, /*pos*/ -7810, -3360, 4500), + MACRO_OBJECT (/*preset*/ macro_hidden_breakable_box, /*yaw*/ 0, /*pos*/ -7810, -3360, 4700), + MACRO_OBJECT (/*preset*/ macro_hidden_breakable_box, /*yaw*/ 0, /*pos*/ -7810, -3360, 4900), + MACRO_OBJECT (/*preset*/ macro_hidden_breakable_box, /*yaw*/ 0, /*pos*/ -3100, -3145, 4518), + MACRO_OBJECT (/*preset*/ macro_box_1up_running_away, /*yaw*/ 0, /*pos*/ -2420, -1140, 3700), MACRO_OBJECT_END(), }; diff --git a/levels/bitdw/areas/1/narrow_path_platform/geo.inc.c b/levels/bitdw/areas/1/narrow_path_platform/geo.inc.c index 0855e361..205ce46b 100644 --- a/levels/bitdw/areas/1/narrow_path_platform/geo.inc.c +++ b/levels/bitdw/areas/1/narrow_path_platform/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000510 const GeoLayout geo_bitdw_000510[] = { - GEO_CULLING_RADIUS(1400), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bitdw_seg7_dl_0700AD10), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(1400), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bitdw_seg7_dl_0700AD10), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bitdw/areas/1/octogonal_platform/geo.inc.c b/levels/bitdw/areas/1/octogonal_platform/geo.inc.c index 2f05fa7d..835854c3 100644 --- a/levels/bitdw/areas/1/octogonal_platform/geo.inc.c +++ b/levels/bitdw/areas/1/octogonal_platform/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000450 const GeoLayout geo_bitdw_000450[] = { - GEO_CULLING_RADIUS(1300), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bitdw_seg7_dl_07005078), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(1300), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bitdw_seg7_dl_07005078), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bitdw/areas/1/platform_with_hill/geo.inc.c b/levels/bitdw/areas/1/platform_with_hill/geo.inc.c index bd5a2d8a..5609bf22 100644 --- a/levels/bitdw/areas/1/platform_with_hill/geo.inc.c +++ b/levels/bitdw/areas/1/platform_with_hill/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000468 const GeoLayout geo_bitdw_000468[] = { - GEO_CULLING_RADIUS(2900), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bitdw_seg7_dl_07005BC0), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(2900), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bitdw_seg7_dl_07005BC0), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bitdw/areas/1/platforms_and_tilting/geo.inc.c b/levels/bitdw/areas/1/platforms_and_tilting/geo.inc.c index ec785c46..1ceb6c50 100644 --- a/levels/bitdw/areas/1/platforms_and_tilting/geo.inc.c +++ b/levels/bitdw/areas/1/platforms_and_tilting/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000498 const GeoLayout geo_bitdw_000498[] = { - GEO_CULLING_RADIUS(2400), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bitdw_seg7_dl_07007AA8), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(2400), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bitdw_seg7_dl_07007AA8), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bitdw/areas/1/platforms_and_tilting_2/geo.inc.c b/levels/bitdw/areas/1/platforms_and_tilting_2/geo.inc.c index e9244276..f6ec2904 100644 --- a/levels/bitdw/areas/1/platforms_and_tilting_2/geo.inc.c +++ b/levels/bitdw/areas/1/platforms_and_tilting_2/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E0004B0 const GeoLayout geo_bitdw_0004B0[] = { - GEO_CULLING_RADIUS(2400), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bitdw_seg7_dl_07008FF0), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(2400), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bitdw_seg7_dl_07008FF0), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bitdw/areas/1/quartz_crystal/geo.inc.c b/levels/bitdw/areas/1/quartz_crystal/geo.inc.c index a93affbd..73d7321b 100644 --- a/levels/bitdw/areas/1/quartz_crystal/geo.inc.c +++ b/levels/bitdw/areas/1/quartz_crystal/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E0004C8 const GeoLayout geo_bitdw_0004C8[] = { - GEO_CULLING_RADIUS(300), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, bitdw_seg7_dl_070093B0), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(300), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, bitdw_seg7_dl_070093B0), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bitdw/areas/1/quartzy_path_1/geo.inc.c b/levels/bitdw/areas/1/quartzy_path_1/geo.inc.c index c4d02183..3745c00c 100644 --- a/levels/bitdw/areas/1/quartzy_path_1/geo.inc.c +++ b/levels/bitdw/areas/1/quartzy_path_1/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000408 const GeoLayout geo_bitdw_000408[] = { - GEO_CULLING_RADIUS(4000), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bitdw_seg7_dl_07003BF0), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(4000), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bitdw_seg7_dl_07003BF0), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bitdw/areas/1/quartzy_path_2/geo.inc.c b/levels/bitdw/areas/1/quartzy_path_2/geo.inc.c index 8b1b15d6..378af27e 100644 --- a/levels/bitdw/areas/1/quartzy_path_2/geo.inc.c +++ b/levels/bitdw/areas/1/quartzy_path_2/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000420 const GeoLayout geo_bitdw_000420[] = { - GEO_CULLING_RADIUS(3500), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bitdw_seg7_dl_07004318), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(3500), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bitdw_seg7_dl_07004318), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bitdw/areas/1/quartzy_path_fences/geo.inc.c b/levels/bitdw/areas/1/quartzy_path_fences/geo.inc.c index cd97916f..478ced7e 100644 --- a/levels/bitdw/areas/1/quartzy_path_fences/geo.inc.c +++ b/levels/bitdw/areas/1/quartzy_path_fences/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000438 const GeoLayout geo_bitdw_000438[] = { - GEO_CULLING_RADIUS(2500), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, bitdw_seg7_dl_070045C0), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(2500), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, bitdw_seg7_dl_070045C0), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bitdw/areas/1/staircase_slope_and_platform/geo.inc.c b/levels/bitdw/areas/1/staircase_slope_and_platform/geo.inc.c index f7315cce..7e9c73fc 100644 --- a/levels/bitdw/areas/1/staircase_slope_and_platform/geo.inc.c +++ b/levels/bitdw/areas/1/staircase_slope_and_platform/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E0004E0 const GeoLayout geo_bitdw_0004E0[] = { - GEO_CULLING_RADIUS(2400), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bitdw_seg7_dl_0700A368), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(2400), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bitdw_seg7_dl_0700A368), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bitdw/areas/1/starting_platform/geo.inc.c b/levels/bitdw/areas/1/starting_platform/geo.inc.c index b5f98fb5..c548184e 100644 --- a/levels/bitdw/areas/1/starting_platform/geo.inc.c +++ b/levels/bitdw/areas/1/starting_platform/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E0003C0 const GeoLayout geo_bitdw_0003C0[] = { - GEO_CULLING_RADIUS(2000), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bitdw_seg7_dl_070028A0), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(2000), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bitdw_seg7_dl_070028A0), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bitdw/areas/1/track_for_pyramid_platforms/geo.inc.c b/levels/bitdw/areas/1/track_for_pyramid_platforms/geo.inc.c index 80f64d7e..cb7cd943 100644 --- a/levels/bitdw/areas/1/track_for_pyramid_platforms/geo.inc.c +++ b/levels/bitdw/areas/1/track_for_pyramid_platforms/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E0004F8 const GeoLayout geo_bitdw_0004F8[] = { - GEO_CULLING_RADIUS(1100), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, bitdw_seg7_dl_0700A6A8), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(1100), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, bitdw_seg7_dl_0700A6A8), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bitdw/areas/1/wooden_bridge_and_fences/geo.inc.c b/levels/bitdw/areas/1/wooden_bridge_and_fences/geo.inc.c index d38fb3e3..6939eca8 100644 --- a/levels/bitdw/areas/1/wooden_bridge_and_fences/geo.inc.c +++ b/levels/bitdw/areas/1/wooden_bridge_and_fences/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E0003F0 const GeoLayout geo_bitdw_0003F0[] = { - GEO_CULLING_RADIUS(2000), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, bitdw_seg7_dl_07003608), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(2000), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, bitdw_seg7_dl_07003608), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bitdw/areas/1/wooden_platform/geo.inc.c b/levels/bitdw/areas/1/wooden_platform/geo.inc.c index d71272a8..1faa2b45 100644 --- a/levels/bitdw/areas/1/wooden_platform/geo.inc.c +++ b/levels/bitdw/areas/1/wooden_platform/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000480 const GeoLayout geo_bitdw_000480[] = { - GEO_CULLING_RADIUS(1500), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bitdw_seg7_dl_070065F0), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(1500), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bitdw_seg7_dl_070065F0), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bitdw/collapsing_stairs_1/geo.inc.c b/levels/bitdw/collapsing_stairs_1/geo.inc.c index 95e3b09e..c13e3f55 100644 --- a/levels/bitdw/collapsing_stairs_1/geo.inc.c +++ b/levels/bitdw/collapsing_stairs_1/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E0005A0 const GeoLayout geo_bitdw_0005A0[] = { - GEO_CULLING_RADIUS(2000), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bitdw_seg7_dl_0700C0E0), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(2000), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bitdw_seg7_dl_0700C0E0), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bitdw/collapsing_stairs_2/geo.inc.c b/levels/bitdw/collapsing_stairs_2/geo.inc.c index 264fb6ac..d977bcfc 100644 --- a/levels/bitdw/collapsing_stairs_2/geo.inc.c +++ b/levels/bitdw/collapsing_stairs_2/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E0005B8 const GeoLayout geo_bitdw_0005B8[] = { - GEO_CULLING_RADIUS(2000), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bitdw_seg7_dl_0700C670), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(2000), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bitdw_seg7_dl_0700C670), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bitdw/collapsing_stairs_3/geo.inc.c b/levels/bitdw/collapsing_stairs_3/geo.inc.c index ea51337d..7ac9acb7 100644 --- a/levels/bitdw/collapsing_stairs_3/geo.inc.c +++ b/levels/bitdw/collapsing_stairs_3/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E0005D0 const GeoLayout geo_bitdw_0005D0[] = { - GEO_CULLING_RADIUS(2000), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bitdw_seg7_dl_0700CC00), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(2000), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bitdw_seg7_dl_0700CC00), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bitdw/collapsing_stairs_4/geo.inc.c b/levels/bitdw/collapsing_stairs_4/geo.inc.c index fc1468ae..05325002 100644 --- a/levels/bitdw/collapsing_stairs_4/geo.inc.c +++ b/levels/bitdw/collapsing_stairs_4/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E0005E8 const GeoLayout geo_bitdw_0005E8[] = { - GEO_CULLING_RADIUS(2000), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bitdw_seg7_dl_0700D190), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(2000), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bitdw_seg7_dl_0700D190), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bitdw/collapsing_stairs_5/geo.inc.c b/levels/bitdw/collapsing_stairs_5/geo.inc.c index b25afb38..d01f7284 100644 --- a/levels/bitdw/collapsing_stairs_5/geo.inc.c +++ b/levels/bitdw/collapsing_stairs_5/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000600 const GeoLayout geo_bitdw_000600[] = { - GEO_CULLING_RADIUS(2000), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bitdw_seg7_dl_0700D3E8), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(2000), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bitdw_seg7_dl_0700D3E8), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bitdw/ferris_platform/geo.inc.c b/levels/bitdw/ferris_platform/geo.inc.c index dea71c17..b019850c 100644 --- a/levels/bitdw/ferris_platform/geo.inc.c +++ b/levels/bitdw/ferris_platform/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000588 const GeoLayout geo_bitdw_000588[] = { - GEO_CULLING_RADIUS(600), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bitdw_seg7_dl_0700BB58), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(600), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bitdw_seg7_dl_0700BB58), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bitdw/ferris_wheel_axle/geo.inc.c b/levels/bitdw/ferris_wheel_axle/geo.inc.c index c7317a0a..f8ebdba5 100644 --- a/levels/bitdw/ferris_wheel_axle/geo.inc.c +++ b/levels/bitdw/ferris_wheel_axle/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000570 const GeoLayout geo_bitdw_000570[] = { - GEO_CULLING_RADIUS(600), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bitdw_seg7_dl_0700B8D8), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(600), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bitdw_seg7_dl_0700B8D8), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bitdw/leveldata.c b/levels/bitdw/leveldata.c index de889e20..97f9b807 100644 --- a/levels/bitdw/leveldata.c +++ b/levels/bitdw/leveldata.c @@ -3,8 +3,8 @@ #include "surface_terrains.h" #include "moving_texture_macros.h" #include "level_misc_macros.h" -#include "macro_preset_names.h" -#include "special_preset_names.h" +#include "macro_presets.h" +#include "special_presets.h" #include "textures.h" #include "dialog_ids.h" diff --git a/levels/bitdw/script.c b/levels/bitdw/script.c index 5e14a7ee..3a09ec9f 100644 --- a/levels/bitdw/script.c +++ b/levels/bitdw/script.c @@ -17,45 +17,45 @@ #include "levels/bitdw/header.h" static const LevelScript script_func_local_1[] = { - OBJECT(/*model*/ MODEL_BITDW_SQUARE_PLATFORM, /*pos*/ -1966, -3154, 3586, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvSquarishPathMoving), - OBJECT(/*model*/ MODEL_BITDW_SQUARE_PLATFORM, /*pos*/ -1352, -3154, 4200, /*angle*/ 0, 0, 0, /*behParam*/ 0x00020000, /*beh*/ bhvSquarishPathMoving), - OBJECT(/*model*/ MODEL_BITDW_SQUARE_PLATFORM, /*pos*/ -2963, 1017, -2464, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvSquarishPathMoving), - OBJECT(/*model*/ MODEL_BITDW_SQUARE_PLATFORM, /*pos*/ -2349, 1017, -1849, /*angle*/ 0, 0, 0, /*behParam*/ 0x00020000, /*beh*/ bhvSquarishPathMoving), - OBJECT(/*model*/ MODEL_BITDW_SQUARE_PLATFORM, /*pos*/ -2349, 1017, -1235, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvSquarishPathMoving), - OBJECT(/*model*/ MODEL_BITDW_SQUARE_PLATFORM, /*pos*/ -1735, 1017, -621, /*angle*/ 0, 0, 0, /*behParam*/ 0x00020000, /*beh*/ bhvSquarishPathMoving), - OBJECT(/*model*/ MODEL_BITDW_SEESAW_PLATFORM, /*pos*/ 1491, 1273, 512, /*angle*/ 0, 90, 0, /*behParam*/ 0x00000000, /*beh*/ bhvSeesawPlatform), - OBJECT(/*model*/ MODEL_BITDW_SEESAW_PLATFORM, /*pos*/ -147, 894, 512, /*angle*/ 0, 90, 0, /*behParam*/ 0x00000000, /*beh*/ bhvSeesawPlatform), - OBJECT(/*model*/ MODEL_BITDW_SLIDING_PLATFORM, /*pos*/ -5728, 819, -2151, /*angle*/ 0, 0, 0, /*behParam*/ 0x03CE0000, /*beh*/ bhvSlidingPlatform2), - OBJECT(/*model*/ MODEL_BITDW_FERRIS_WHEEL_AXLE, /*pos*/ -204, -1924, 3381, /*angle*/ 0, 0, 0, /*behParam*/ 0x00010000, /*beh*/ bhvFerrisWheelAxle), - OBJECT(/*model*/ MODEL_BITDW_STAIRCASE, /*pos*/ 5279, 1740, -6, /*angle*/ 0, 0, 0, /*behParam*/ 0x00010000, /*beh*/ bhvAnimatesOnFloorSwitchPress), - OBJECT(/*model*/ MODEL_PURPLE_SWITCH, /*pos*/ 3922, 1740, -7, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvFloorSwitchAnimatesObject), + OBJECT(/*model*/ MODEL_BITDW_SQUARE_PLATFORM, /*pos*/ -1966, -3154, 3586, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(0x00), /*bhv*/ bhvSquarishPathMoving), + OBJECT(/*model*/ MODEL_BITDW_SQUARE_PLATFORM, /*pos*/ -1352, -3154, 4200, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(0x02), /*bhv*/ bhvSquarishPathMoving), + OBJECT(/*model*/ MODEL_BITDW_SQUARE_PLATFORM, /*pos*/ -2963, 1017, -2464, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(0x00), /*bhv*/ bhvSquarishPathMoving), + OBJECT(/*model*/ MODEL_BITDW_SQUARE_PLATFORM, /*pos*/ -2349, 1017, -1849, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(0x02), /*bhv*/ bhvSquarishPathMoving), + OBJECT(/*model*/ MODEL_BITDW_SQUARE_PLATFORM, /*pos*/ -2349, 1017, -1235, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(0x00), /*bhv*/ bhvSquarishPathMoving), + OBJECT(/*model*/ MODEL_BITDW_SQUARE_PLATFORM, /*pos*/ -1735, 1017, -621, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(0x02), /*bhv*/ bhvSquarishPathMoving), + OBJECT(/*model*/ MODEL_BITDW_SEESAW_PLATFORM, /*pos*/ 1491, 1273, 512, /*angle*/ 0, 90, 0, /*bhvParam*/ 0, /*bhv*/ bhvSeesawPlatform), + OBJECT(/*model*/ MODEL_BITDW_SEESAW_PLATFORM, /*pos*/ -147, 894, 512, /*angle*/ 0, 90, 0, /*bhvParam*/ 0, /*bhv*/ bhvSeesawPlatform), + OBJECT(/*model*/ MODEL_BITDW_SLIDING_PLATFORM, /*pos*/ -5728, 819, -2151, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(0x03) | BPARAM2(0xCE), /*bhv*/ bhvSlidingPlatform2), + OBJECT(/*model*/ MODEL_BITDW_FERRIS_WHEEL_AXLE, /*pos*/ -204, -1924, 3381, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(0x01), /*bhv*/ bhvFerrisWheelAxle), + OBJECT(/*model*/ MODEL_BITDW_STAIRCASE, /*pos*/ 5279, 1740, -6, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(0x01), /*bhv*/ bhvAnimatesOnFloorSwitchPress), + OBJECT(/*model*/ MODEL_PURPLE_SWITCH, /*pos*/ 3922, 1740, -7, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvFloorSwitchAnimatesObject), RETURN(), }; static const LevelScript script_func_local_2[] = { - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -3092, -2795, 2842, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvFlamethrower), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 2463, -2386, 2844, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvFlamethrower), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ -3092, -2795, 2842, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvFlamethrower), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 2463, -2386, 2844, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvFlamethrower), RETURN(), }; static const LevelScript script_func_local_3[] = { - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 7180, 3000, 0, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvBowserCourseRedCoinStar), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 7180, 3000, 0, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(STAR_INDEX_ACT_1), /*bhv*/ bhvBowserCourseRedCoinStar), RETURN(), }; const LevelScript level_bitdw_entry[] = { INIT_LEVEL(), - LOAD_MIO0( /*seg*/ 0x07, _bitdw_segment_7SegmentRomStart, _bitdw_segment_7SegmentRomEnd), - LOAD_MIO0( /*seg*/ 0x0A, _bidw_skybox_mio0SegmentRomStart, _bidw_skybox_mio0SegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x07, _bitdw_segment_7SegmentRomStart, _bitdw_segment_7SegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x0A, _bidw_skybox_mio0SegmentRomStart, _bidw_skybox_mio0SegmentRomEnd), LOAD_MIO0_TEXTURE(/*seg*/ 0x09, _sky_mio0SegmentRomStart, _sky_mio0SegmentRomEnd), - LOAD_MIO0( /*seg*/ 0x05, _group11_mio0SegmentRomStart, _group11_mio0SegmentRomEnd), - LOAD_RAW( /*seg*/ 0x0C, _group11_geoSegmentRomStart, _group11_geoSegmentRomEnd), - LOAD_MIO0( /*seg*/ 0x06, _group17_mio0SegmentRomStart, _group17_mio0SegmentRomEnd), - LOAD_RAW( /*seg*/ 0x0D, _group17_geoSegmentRomStart, _group17_geoSegmentRomEnd), - LOAD_MIO0( /*seg*/ 0x08, _common0_mio0SegmentRomStart, _common0_mio0SegmentRomEnd), - LOAD_RAW( /*seg*/ 0x0F, _common0_geoSegmentRomStart, _common0_geoSegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x05, _group11_mio0SegmentRomStart, _group11_mio0SegmentRomEnd), + LOAD_RAW (/*seg*/ 0x0C, _group11_geoSegmentRomStart, _group11_geoSegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x06, _group17_mio0SegmentRomStart, _group17_mio0SegmentRomEnd), + LOAD_RAW (/*seg*/ 0x0D, _group17_geoSegmentRomStart, _group17_geoSegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x08, _common0_mio0SegmentRomStart, _common0_mio0SegmentRomEnd), + LOAD_RAW (/*seg*/ 0x0F, _common0_geoSegmentRomStart, _common0_geoSegmentRomEnd), ALLOC_LEVEL_POOL(), - MARIO(/*model*/ MODEL_MARIO, /*behParam*/ 0x00000001, /*beh*/ bhvMario), + MARIO(/*model*/ MODEL_MARIO, /*bhvParam*/ BPARAM4(0x01), /*bhv*/ bhvMario), JUMP_LINK(script_func_global_12), JUMP_LINK(script_func_global_18), JUMP_LINK(script_func_global_1), @@ -87,13 +87,13 @@ const LevelScript level_bitdw_entry[] = { LOAD_MODEL_FROM_GEO(MODEL_BITDW_STAIRCASE, geo_bitdw_000600), AREA(/*index*/ 1, geo_bitdw_000618), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -7443, -2153, 3886, /*angle*/ 0, 90, 0, /*behParam*/ 0x000A0000, /*beh*/ bhvAirborneWarp), - OBJECT(/*model*/ MODEL_BITDW_WARP_PIPE, /*pos*/ 6816, 2860, -7, /*angle*/ 0, 0, 0, /*behParam*/ 0x000B0000, /*beh*/ bhvWarpPipe), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 5910, 3500, -7, /*angle*/ 0, 90, 0, /*behParam*/ 0x000C0000, /*beh*/ bhvDeathWarp), - WARP_NODE(/*id*/ 0x0A, /*destLevel*/ LEVEL_BITDW, /*destArea*/ 0x01, /*destNode*/ 0x0A, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0x0B, /*destLevel*/ LEVEL_BOWSER_1, /*destArea*/ 0x01, /*destNode*/ 0x0A, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0x0C, /*destLevel*/ LEVEL_BITDW, /*destArea*/ 0x01, /*destNode*/ 0x0C, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0xF1, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x01, /*destNode*/ 0x25, /*flags*/ WARP_NO_CHECKPOINT), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ -7443, -2153, 3886, /*angle*/ 0, 90, 0, /*bhvParam*/ BPARAM2(WARP_NODE_0A), /*bhv*/ bhvAirborneWarp), + OBJECT(/*model*/ MODEL_BITDW_WARP_PIPE, /*pos*/ 6816, 2860, -7, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(WARP_NODE_0B), /*bhv*/ bhvWarpPipe), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 5910, 3500, -7, /*angle*/ 0, 90, 0, /*bhvParam*/ BPARAM2(WARP_NODE_0C), /*bhv*/ bhvDeathWarp), + WARP_NODE(/*id*/ WARP_NODE_0A, /*destLevel*/ LEVEL_BITDW, /*destArea*/ 1, /*destNode*/ WARP_NODE_0A, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_0B, /*destLevel*/ LEVEL_BOWSER_1, /*destArea*/ 1, /*destNode*/ WARP_NODE_0A, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_0C, /*destLevel*/ LEVEL_BITDW, /*destArea*/ 1, /*destNode*/ WARP_NODE_0C, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_DEATH, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 1, /*destNode*/ WARP_NODE_25, /*flags*/ WARP_NO_CHECKPOINT), JUMP_LINK(script_func_local_1), JUMP_LINK(script_func_local_2), JUMP_LINK(script_func_local_3), diff --git a/levels/bitdw/seesaw_platform/geo.inc.c b/levels/bitdw/seesaw_platform/geo.inc.c index 54673de6..68fdd24d 100644 --- a/levels/bitdw/seesaw_platform/geo.inc.c +++ b/levels/bitdw/seesaw_platform/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000540 const GeoLayout geo_bitdw_000540[] = { - GEO_CULLING_RADIUS(1100), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bitdw_seg7_dl_0700B220), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(1100), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bitdw_seg7_dl_0700B220), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bitdw/sliding_platform/geo.inc.c b/levels/bitdw/sliding_platform/geo.inc.c index a27bbe88..cd64ca34 100644 --- a/levels/bitdw/sliding_platform/geo.inc.c +++ b/levels/bitdw/sliding_platform/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000528 const GeoLayout geo_bitdw_000528[] = { - GEO_CULLING_RADIUS(1500), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bitdw_seg7_dl_0700AFA0), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(1500), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bitdw_seg7_dl_0700AFA0), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bitdw/square_platform/geo.inc.c b/levels/bitdw/square_platform/geo.inc.c index 25813740..1cf15e20 100644 --- a/levels/bitdw/square_platform/geo.inc.c +++ b/levels/bitdw/square_platform/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000558 const GeoLayout geo_bitdw_000558[] = { - GEO_CULLING_RADIUS(600), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bitdw_seg7_dl_0700B480), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(600), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bitdw_seg7_dl_0700B480), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bitfs/areas/1/10/geo.inc.c b/levels/bitfs/areas/1/10/geo.inc.c index d028d579..71353dda 100644 --- a/levels/bitfs/areas/1/10/geo.inc.c +++ b/levels/bitfs/areas/1/10/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000570 const GeoLayout bitfs_geo_000570[] = { - GEO_CULLING_RADIUS(500), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bitfs_seg7_dl_07007958), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(500), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bitfs_seg7_dl_07007958), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bitfs/areas/1/11/geo.inc.c b/levels/bitfs/areas/1/11/geo.inc.c index a834d09f..d800f308 100644 --- a/levels/bitfs/areas/1/11/geo.inc.c +++ b/levels/bitfs/areas/1/11/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000588 const GeoLayout bitfs_geo_000588[] = { - GEO_CULLING_RADIUS(2200), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bitfs_seg7_dl_07008F48), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(2200), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bitfs_seg7_dl_07008F48), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bitfs/areas/1/12/geo.inc.c b/levels/bitfs/areas/1/12/geo.inc.c index cc386401..5fe31894 100644 --- a/levels/bitfs/areas/1/12/geo.inc.c +++ b/levels/bitfs/areas/1/12/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E0005A0 const GeoLayout bitfs_geo_0005A0[] = { - GEO_CULLING_RADIUS(2100), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, bitfs_seg7_dl_070091E0), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(2100), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, bitfs_seg7_dl_070091E0), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bitfs/areas/1/13/geo.inc.c b/levels/bitfs/areas/1/13/geo.inc.c index e017bb37..fa371f89 100644 --- a/levels/bitfs/areas/1/13/geo.inc.c +++ b/levels/bitfs/areas/1/13/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E0005B8 const GeoLayout bitfs_geo_0005B8[] = { - GEO_CULLING_RADIUS(1300), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bitfs_seg7_dl_070095E0), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(1300), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bitfs_seg7_dl_070095E0), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bitfs/areas/1/14/geo.inc.c b/levels/bitfs/areas/1/14/geo.inc.c index 74a102d7..e4a44251 100644 --- a/levels/bitfs/areas/1/14/geo.inc.c +++ b/levels/bitfs/areas/1/14/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E0005D0 const GeoLayout bitfs_geo_0005D0[] = { - GEO_CULLING_RADIUS(1900), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bitfs_seg7_dl_0700AA00), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(1900), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bitfs_seg7_dl_0700AA00), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bitfs/areas/1/15/geo.inc.c b/levels/bitfs/areas/1/15/geo.inc.c index 2e2cb309..9c8facab 100644 --- a/levels/bitfs/areas/1/15/geo.inc.c +++ b/levels/bitfs/areas/1/15/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E0005E8 const GeoLayout bitfs_geo_0005E8[] = { - GEO_CULLING_RADIUS(900), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, bitfs_seg7_dl_0700AB90), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(900), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, bitfs_seg7_dl_0700AB90), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bitfs/areas/1/16/geo.inc.c b/levels/bitfs/areas/1/16/geo.inc.c index 4e9a32be..72a5d45b 100644 --- a/levels/bitfs/areas/1/16/geo.inc.c +++ b/levels/bitfs/areas/1/16/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000600 const GeoLayout bitfs_geo_000600[] = { - GEO_CULLING_RADIUS(2800), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bitfs_seg7_dl_0700BED8), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(2800), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bitfs_seg7_dl_0700BED8), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bitfs/areas/1/17/geo.inc.c b/levels/bitfs/areas/1/17/geo.inc.c index 13756b4d..ee93b2b2 100644 --- a/levels/bitfs/areas/1/17/geo.inc.c +++ b/levels/bitfs/areas/1/17/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000618 const GeoLayout bitfs_geo_000618[] = { - GEO_CULLING_RADIUS(2500), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, bitfs_seg7_dl_0700C3C0), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(2500), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, bitfs_seg7_dl_0700C3C0), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bitfs/areas/1/18/geo.inc.c b/levels/bitfs/areas/1/18/geo.inc.c index 8cfac073..ed2aed3e 100644 --- a/levels/bitfs/areas/1/18/geo.inc.c +++ b/levels/bitfs/areas/1/18/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000630 const GeoLayout bitfs_geo_000630[] = { - GEO_CULLING_RADIUS(1600), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bitfs_seg7_dl_0700EC78), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(1600), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bitfs_seg7_dl_0700EC78), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bitfs/areas/1/19/geo.inc.c b/levels/bitfs/areas/1/19/geo.inc.c index e4a0c273..a5650def 100644 --- a/levels/bitfs/areas/1/19/geo.inc.c +++ b/levels/bitfs/areas/1/19/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000648 const GeoLayout bitfs_geo_000648[] = { - GEO_CULLING_RADIUS(600), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, bitfs_seg7_dl_0700ED90), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(600), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, bitfs_seg7_dl_0700ED90), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bitfs/areas/1/2/geo.inc.c b/levels/bitfs/areas/1/2/geo.inc.c index 3f291498..39298568 100644 --- a/levels/bitfs/areas/1/2/geo.inc.c +++ b/levels/bitfs/areas/1/2/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E0004B0 const GeoLayout bitfs_geo_0004B0[] = { - GEO_CULLING_RADIUS(2700), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bitfs_seg7_dl_07002A78), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(2700), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bitfs_seg7_dl_07002A78), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bitfs/areas/1/20/geo.inc.c b/levels/bitfs/areas/1/20/geo.inc.c index 126c08ea..4f9feecf 100644 --- a/levels/bitfs/areas/1/20/geo.inc.c +++ b/levels/bitfs/areas/1/20/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000660 const GeoLayout bitfs_geo_000660[] = { - GEO_CULLING_RADIUS(4100), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bitfs_seg7_dl_0700F1C8), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(4100), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bitfs_seg7_dl_0700F1C8), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bitfs/areas/1/3/geo.inc.c b/levels/bitfs/areas/1/3/geo.inc.c index 09ac4105..081c5e7f 100644 --- a/levels/bitfs/areas/1/3/geo.inc.c +++ b/levels/bitfs/areas/1/3/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E0004C8 const GeoLayout bitfs_geo_0004C8[] = { - GEO_CULLING_RADIUS(2100), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bitfs_seg7_dl_07003670), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(2100), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bitfs_seg7_dl_07003670), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bitfs/areas/1/4/geo.inc.c b/levels/bitfs/areas/1/4/geo.inc.c index 5b32eed3..d7f5c09b 100644 --- a/levels/bitfs/areas/1/4/geo.inc.c +++ b/levels/bitfs/areas/1/4/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E0004E0 const GeoLayout bitfs_geo_0004E0[] = { - GEO_CULLING_RADIUS(2500), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bitfs_seg7_dl_07003C60), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(2500), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bitfs_seg7_dl_07003C60), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bitfs/areas/1/5/geo.inc.c b/levels/bitfs/areas/1/5/geo.inc.c index d30d19e5..5d54b044 100644 --- a/levels/bitfs/areas/1/5/geo.inc.c +++ b/levels/bitfs/areas/1/5/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E0004F8 const GeoLayout bitfs_geo_0004F8[] = { - GEO_CULLING_RADIUS(3200), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bitfs_seg7_dl_070040B0), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(3200), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bitfs_seg7_dl_070040B0), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bitfs/areas/1/6/geo.inc.c b/levels/bitfs/areas/1/6/geo.inc.c index 699b1fea..470d236b 100644 --- a/levels/bitfs/areas/1/6/geo.inc.c +++ b/levels/bitfs/areas/1/6/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000510 const GeoLayout bitfs_geo_000510[] = { - GEO_CULLING_RADIUS(2600), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, bitfs_seg7_dl_07004630), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(2600), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, bitfs_seg7_dl_07004630), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bitfs/areas/1/7/geo.inc.c b/levels/bitfs/areas/1/7/geo.inc.c index f2109770..0532d4dc 100644 --- a/levels/bitfs/areas/1/7/geo.inc.c +++ b/levels/bitfs/areas/1/7/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000528 const GeoLayout bitfs_geo_000528[] = { - GEO_CULLING_RADIUS(3500), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bitfs_seg7_dl_07006B90), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(3500), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bitfs_seg7_dl_07006B90), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bitfs/areas/1/8/geo.inc.c b/levels/bitfs/areas/1/8/geo.inc.c index c46b9625..33734eaf 100644 --- a/levels/bitfs/areas/1/8/geo.inc.c +++ b/levels/bitfs/areas/1/8/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000540 const GeoLayout bitfs_geo_000540[] = { - GEO_CULLING_RADIUS(1900), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, bitfs_seg7_dl_07007070), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(1900), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, bitfs_seg7_dl_07007070), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bitfs/areas/1/9/geo.inc.c b/levels/bitfs/areas/1/9/geo.inc.c index a21c634a..fd97ad33 100644 --- a/levels/bitfs/areas/1/9/geo.inc.c +++ b/levels/bitfs/areas/1/9/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000558 const GeoLayout bitfs_geo_000558[] = { - GEO_CULLING_RADIUS(4600), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bitfs_seg7_dl_07007720), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(4600), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bitfs_seg7_dl_07007720), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bitfs/areas/1/geo.inc.c b/levels/bitfs/areas/1/geo.inc.c index 847c6ca7..6dce74b0 100644 --- a/levels/bitfs/areas/1/geo.inc.c +++ b/levels/bitfs/areas/1/geo.inc.c @@ -1,30 +1,30 @@ // 0x0E0007A0 const GeoLayout bitfs_geo_0007A0[] = { - GEO_NODE_SCREEN_AREA(10, SCREEN_WIDTH/2, SCREEN_HEIGHT/2, SCREEN_WIDTH/2, SCREEN_HEIGHT/2), - GEO_OPEN_NODE(), - GEO_ZBUFFER(0), - GEO_OPEN_NODE(), - GEO_NODE_ORTHO(100), - GEO_OPEN_NODE(), - GEO_BACKGROUND(BACKGROUND_FLAMING_SKY, geo_skybox_main), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ZBUFFER(1), - GEO_OPEN_NODE(), - GEO_CAMERA_FRUSTUM_WITH_FUNC(45, 100, 20000, geo_camera_fov), - GEO_OPEN_NODE(), - GEO_CAMERA(14, 0, 2000, 6000, 0, -4500, -8000, geo_camera_main), + GEO_NODE_SCREEN_AREA(10, SCREEN_WIDTH/2, SCREEN_HEIGHT/2, SCREEN_WIDTH/2, SCREEN_HEIGHT/2), + GEO_OPEN_NODE(), + GEO_ZBUFFER(0), + GEO_OPEN_NODE(), + GEO_NODE_ORTHO(100), GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, bitfs_seg7_dl_07002118), - GEO_ASM( 0, geo_movtex_pause_control), - GEO_ASM(0x1901, geo_movtex_draw_nocolor), - GEO_ASM(0x1902, geo_movtex_draw_nocolor), - GEO_ASM(0x1903, geo_movtex_draw_nocolor), - GEO_RENDER_OBJ(), - GEO_ASM( 12, geo_envfx_main), + GEO_BACKGROUND(BACKGROUND_FLAMING_SKY, geo_skybox_main), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CLOSE_NODE(), + GEO_ZBUFFER(1), + GEO_OPEN_NODE(), + GEO_CAMERA_FRUSTUM_WITH_FUNC(45, 100, 20000, geo_camera_fov), + GEO_OPEN_NODE(), + GEO_CAMERA(14, 0, 2000, 6000, 0, -4500, -8000, geo_camera_main), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, bitfs_seg7_dl_07002118), + GEO_ASM( 0, geo_movtex_pause_control), + GEO_ASM(0x1901, geo_movtex_draw_nocolor), + GEO_ASM(0x1902, geo_movtex_draw_nocolor), + GEO_ASM(0x1903, geo_movtex_draw_nocolor), + GEO_RENDER_OBJ(), + GEO_ASM( 12, geo_envfx_main), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bitfs/areas/1/macro.inc.c b/levels/bitfs/areas/1/macro.inc.c index 3e7a7bb2..fee87864 100644 --- a/levels/bitfs/areas/1/macro.inc.c +++ b/levels/bitfs/areas/1/macro.inc.c @@ -1,44 +1,44 @@ // 0x07014F90 - 0x07015122 const MacroObject bitfs_seg7_macro_objs[] = { - MACRO_OBJECT(/*preset*/ macro_yellow_coin, /*yaw*/ 0, /*pos*/ -1990, -2780, -590), - MACRO_OBJECT(/*preset*/ macro_yellow_coin, /*yaw*/ 0, /*pos*/ -2860, -2780, -580), - MACRO_OBJECT(/*preset*/ macro_coin_line_horizontal_flying, /*yaw*/ 0, /*pos*/ 1130, -3000, 400), - MACRO_OBJECT(/*preset*/ macro_1up, /*yaw*/ 0, /*pos*/ -4320, -2640, -500), - MACRO_OBJECT(/*preset*/ macro_bully, /*yaw*/ 0, /*pos*/ 2340, -2764, 580), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_circling_amp, /*yaw*/ 0, /*pos*/ 6600, -2770, 280, /*behParam*/ 0), - MACRO_OBJECT(/*preset*/ macro_recovery_heart, /*yaw*/ 0, /*pos*/ 3660, -2700, 280), - MACRO_OBJECT(/*preset*/ macro_hidden_1up_in_pole, /*yaw*/ 0, /*pos*/ 3880, -1140, 260), - MACRO_OBJECT(/*preset*/ macro_coin_ring_horizontal_flying, /*yaw*/ 0, /*pos*/ -1900, 652, 320), - MACRO_OBJECT(/*preset*/ macro_bully, /*yaw*/ 0, /*pos*/ -1720, 1320, -340), - MACRO_OBJECT(/*preset*/ macro_coin_line_horizontal, /*yaw*/ 0, /*pos*/ -640, 800, 180), - MACRO_OBJECT(/*preset*/ macro_bully, /*yaw*/ 0, /*pos*/ -5340, 410, 20), - MACRO_OBJECT(/*preset*/ macro_bully, /*yaw*/ 0, /*pos*/ -5200, 410, 700), - MACRO_OBJECT(/*preset*/ macro_box_1up, /*yaw*/ 0, /*pos*/ -7400, 1500, 0), - MACRO_OBJECT(/*preset*/ macro_hidden_1up_trigger, /*yaw*/ 0, /*pos*/ -6150, 1480, 500), - MACRO_OBJECT(/*preset*/ macro_hidden_1up_trigger, /*yaw*/ 0, /*pos*/ -6150, 2600, 500), - MACRO_OBJECT(/*preset*/ macro_hidden_1up_trigger, /*yaw*/ 0, /*pos*/ -6150, 3080, 500), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_hidden_1up, /*yaw*/ 0, /*pos*/ -6460, 2760, 320, /*behParam*/ 3), - MACRO_OBJECT(/*preset*/ macro_coin_line_horizontal, /*yaw*/ 90, /*pos*/ -6360, 3760, -840), - MACRO_OBJECT(/*preset*/ macro_recovery_heart, /*yaw*/ 0, /*pos*/ -20, 3850, 160), - MACRO_OBJECT(/*preset*/ macro_box_1up, /*yaw*/ 0, /*pos*/ 2440, 5520, 140), - MACRO_OBJECT(/*preset*/ macro_1up_3, /*yaw*/ 0, /*pos*/ 1198, 5478, 103), - MACRO_OBJECT(/*preset*/ macro_coin_line_horizontal_flying, /*yaw*/ 0, /*pos*/ -2610, 3600, 0), - MACRO_OBJECT(/*preset*/ macro_coin_ring_horizontal, /*yaw*/ 0, /*pos*/ 1231, -2168, -1747), - MACRO_OBJECT(/*preset*/ macro_coin_line_vertical, /*yaw*/ 0, /*pos*/ -5705, 800, 0), - MACRO_OBJECT(/*preset*/ macro_goomba_triplet_spawner, /*yaw*/ 0, /*pos*/ 3660, -2764, 300), - MACRO_OBJECT(/*preset*/ macro_1up_3, /*yaw*/ 0, /*pos*/ -174, -2840, -138), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 2888, -1375, 310), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 1230, -1900, -1747), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 5800, -2000, 0), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -1846, 1600, -476), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -4210, 2615, 280), - MACRO_OBJECT(/*preset*/ macro_bobomb, /*yaw*/ 0, /*pos*/ -5361, 3686, 315), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -1390, 3575, -420), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 3065, 4610, 92), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 4330, -790, -50), - MACRO_OBJECT(/*preset*/ macro_box_three_coins, /*yaw*/ 0, /*pos*/ 7220, -1800, 260), - MACRO_OBJECT(/*preset*/ macro_fire_spitter, /*yaw*/ 0, /*pos*/ -7280, 3100, -925), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_circling_amp, /*yaw*/ 0, /*pos*/ -2325, 3625, 0, /*behParam*/ 2), - MACRO_OBJECT(/*preset*/ macro_box_ten_coins, /*yaw*/ 0, /*pos*/ -5340, 4000, 100), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_1, /*yaw*/ 0, /*pos*/ -1990, -2780, -590), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_1, /*yaw*/ 0, /*pos*/ -2860, -2780, -580), + MACRO_OBJECT (/*preset*/ macro_coin_line_horizontal_flying, /*yaw*/ 0, /*pos*/ 1130, -3000, 400), + MACRO_OBJECT (/*preset*/ macro_1up, /*yaw*/ 0, /*pos*/ -4320, -2640, -500), + MACRO_OBJECT (/*preset*/ macro_small_bully, /*yaw*/ 0, /*pos*/ 2340, -2764, 580), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_circling_amp, /*yaw*/ 0, /*pos*/ 6600, -2770, 280, /*bhvParam*/ AMP_BP_ROT_RADIUS_200), + MACRO_OBJECT (/*preset*/ macro_recovery_heart, /*yaw*/ 0, /*pos*/ 3660, -2700, 280), + MACRO_OBJECT (/*preset*/ macro_hidden_1up_in_pole, /*yaw*/ 0, /*pos*/ 3880, -1140, 260), + MACRO_OBJECT (/*preset*/ macro_coin_ring_horizontal_flying, /*yaw*/ 0, /*pos*/ -1900, 652, 320), + MACRO_OBJECT (/*preset*/ macro_small_bully, /*yaw*/ 0, /*pos*/ -1720, 1320, -340), + MACRO_OBJECT (/*preset*/ macro_coin_line_horizontal, /*yaw*/ 0, /*pos*/ -640, 800, 180), + MACRO_OBJECT (/*preset*/ macro_small_bully, /*yaw*/ 0, /*pos*/ -5340, 410, 20), + MACRO_OBJECT (/*preset*/ macro_small_bully, /*yaw*/ 0, /*pos*/ -5200, 410, 700), + MACRO_OBJECT (/*preset*/ macro_box_1up, /*yaw*/ 0, /*pos*/ -7400, 1500, 0), + MACRO_OBJECT (/*preset*/ macro_hidden_1up_trigger, /*yaw*/ 0, /*pos*/ -6150, 1480, 500), + MACRO_OBJECT (/*preset*/ macro_hidden_1up_trigger, /*yaw*/ 0, /*pos*/ -6150, 2600, 500), + MACRO_OBJECT (/*preset*/ macro_hidden_1up_trigger, /*yaw*/ 0, /*pos*/ -6150, 3080, 500), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_hidden_1up, /*yaw*/ 0, /*pos*/ -6460, 2760, 320, /*bhvParam*/ 3), + MACRO_OBJECT (/*preset*/ macro_coin_line_horizontal, /*yaw*/ 90, /*pos*/ -6360, 3760, -840), + MACRO_OBJECT (/*preset*/ macro_recovery_heart, /*yaw*/ 0, /*pos*/ -20, 3850, 160), + MACRO_OBJECT (/*preset*/ macro_box_1up, /*yaw*/ 0, /*pos*/ 2440, 5520, 140), + MACRO_OBJECT (/*preset*/ macro_1up_beat_bitfs_bowser, /*yaw*/ 0, /*pos*/ 1198, 5478, 103), + MACRO_OBJECT (/*preset*/ macro_coin_line_horizontal_flying, /*yaw*/ 0, /*pos*/ -2610, 3600, 0), + MACRO_OBJECT (/*preset*/ macro_coin_ring_horizontal, /*yaw*/ 0, /*pos*/ 1231, -2168, -1747), + MACRO_OBJECT (/*preset*/ macro_coin_line_vertical_flying, /*yaw*/ 0, /*pos*/ -5705, 800, 0), + MACRO_OBJECT (/*preset*/ macro_goomba_triplet_spawner, /*yaw*/ 0, /*pos*/ 3660, -2764, 300), + MACRO_OBJECT (/*preset*/ macro_1up_beat_bitfs_bowser, /*yaw*/ 0, /*pos*/ -174, -2840, -138), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 2888, -1375, 310), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 1230, -1900, -1747), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 5800, -2000, 0), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -1846, 1600, -476), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -4210, 2615, 280), + MACRO_OBJECT (/*preset*/ macro_bobomb, /*yaw*/ 0, /*pos*/ -5361, 3686, 315), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -1390, 3575, -420), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 3065, 4610, 92), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 4330, -790, -50), + MACRO_OBJECT (/*preset*/ macro_box_three_coins, /*yaw*/ 0, /*pos*/ 7220, -1800, 260), + MACRO_OBJECT (/*preset*/ macro_fire_spitter, /*yaw*/ 0, /*pos*/ -7280, 3100, -925), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_circling_amp, /*yaw*/ 0, /*pos*/ -2325, 3625, 0, /*bhvParam*/ AMP_BP_ROT_RADIUS_400), + MACRO_OBJECT (/*preset*/ macro_box_ten_coins, /*yaw*/ 0, /*pos*/ -5340, 4000, 100), MACRO_OBJECT_END(), }; diff --git a/levels/bitfs/elevator/geo.inc.c b/levels/bitfs/elevator/geo.inc.c index 2354c8ba..6b376c71 100644 --- a/levels/bitfs/elevator/geo.inc.c +++ b/levels/bitfs/elevator/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000678 const GeoLayout bitfs_geo_000678[] = { - GEO_CULLING_RADIUS(400), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bitfs_seg7_dl_0700F508), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(400), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bitfs_seg7_dl_0700F508), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bitfs/leveldata.c b/levels/bitfs/leveldata.c index 1d22a4f8..12297047 100644 --- a/levels/bitfs/leveldata.c +++ b/levels/bitfs/leveldata.c @@ -3,8 +3,8 @@ #include "surface_terrains.h" #include "moving_texture_macros.h" #include "level_misc_macros.h" -#include "macro_preset_names.h" -#include "special_preset_names.h" +#include "macro_presets.h" +#include "special_presets.h" #include "textures.h" #include "make_const_nonconst.h" diff --git a/levels/bitfs/moving_square_platform/geo.inc.c b/levels/bitfs/moving_square_platform/geo.inc.c index 5252ad07..c9a5f139 100644 --- a/levels/bitfs/moving_square_platform/geo.inc.c +++ b/levels/bitfs/moving_square_platform/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000728 const GeoLayout bitfs_geo_000728[] = { - GEO_CULLING_RADIUS(650), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bitfs_seg7_dl_07011318), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(650), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bitfs_seg7_dl_07011318), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bitfs/platform_on_track/geo.inc.c b/levels/bitfs/platform_on_track/geo.inc.c index f4348621..ec83a7a2 100644 --- a/levels/bitfs/platform_on_track/geo.inc.c +++ b/levels/bitfs/platform_on_track/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000758 const GeoLayout bitfs_geo_000758[] = { - GEO_CULLING_RADIUS(600), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, bitfs_seg7_dl_07011798), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(600), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, bitfs_seg7_dl_07011798), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bitfs/script.c b/levels/bitfs/script.c index 56b108dc..585a6e08 100644 --- a/levels/bitfs/script.c +++ b/levels/bitfs/script.c @@ -16,54 +16,54 @@ #include "levels/bitfs/header.h" static const LevelScript script_func_local_1[] = { - OBJECT(/*model*/ MODEL_BITFS_PLATFORM_ON_TRACK, /*pos*/ -5733, -3071, 0, /*angle*/ 0, 0, 0, /*behParam*/ 0x07330000, /*beh*/ bhvPlatformOnTrack), - OBJECT(/*model*/ MODEL_BITFS_TILTING_SQUARE_PLATFORM, /*pos*/ -1945, -3225, -715, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvBitfsTiltingInvertedPyramid), - OBJECT(/*model*/ MODEL_BITFS_TILTING_SQUARE_PLATFORM, /*pos*/ -2866, -3225, -715, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvBitfsTiltingInvertedPyramid), - OBJECT(/*model*/ MODEL_BITFS_SINKING_PLATFORMS, /*pos*/ -1381, 3487, 96, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvBitfsSinkingPlatforms), - OBJECT(/*model*/ MODEL_BITFS_SINKING_PLATFORMS, /*pos*/ 1126, -3065, 307, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvBitfsSinkingPlatforms), - OBJECT(/*model*/ MODEL_BITFS_SINKING_PLATFORMS, /*pos*/ -3225, 3487, 96, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvBitfsSinkingPlatforms), - OBJECT(/*model*/ MODEL_BITFS_SINKING_CAGE_PLATFORM, /*pos*/ 6605, -3071, 266, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvBitfsSinkingCagePlatform), - OBJECT(/*model*/ MODEL_BITFS_SINKING_CAGE_PLATFORM, /*pos*/ 1843, 3584, 96, /*angle*/ 0, 0, 0, /*behParam*/ 0x00010000, /*beh*/ bhvBitfsSinkingCagePlatform), - OBJECT(/*model*/ MODEL_BITFS_SINKING_CAGE_PLATFORM, /*pos*/ 614, 3584, 96, /*angle*/ 0, 0, 0, /*behParam*/ 0x00010000, /*beh*/ bhvBitfsSinkingCagePlatform), - OBJECT(/*model*/ MODEL_BITFS_SINKING_CAGE_PLATFORM, /*pos*/ 3072, 3584, 96, /*angle*/ 0, 0, 0, /*behParam*/ 0x00010000, /*beh*/ bhvBitfsSinkingCagePlatform), - OBJECT(/*model*/ MODEL_BITFS_ELEVATOR, /*pos*/ 2867, -1279, 307, /*angle*/ 0, 0, 0, /*behParam*/ 0x029F0000, /*beh*/ bhvActivatedBackAndForthPlatform), - OBJECT(/*model*/ MODEL_BITFS_STRETCHING_PLATFORMS, /*pos*/ -5836, 410, 300, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvSquishablePlatform), - OBJECT(/*model*/ MODEL_BITFS_SEESAW_PLATFORM, /*pos*/ 4454, -2226, 266, /*angle*/ 0, 0, 0, /*behParam*/ 0x00040000, /*beh*/ bhvSeesawPlatform), - OBJECT(/*model*/ MODEL_BITFS_SEESAW_PLATFORM, /*pos*/ 5786, -2380, 266, /*angle*/ 0, 0, 0, /*behParam*/ 0x00040000, /*beh*/ bhvSeesawPlatform), - OBJECT(/*model*/ MODEL_BITFS_MOVING_SQUARE_PLATFORM, /*pos*/ -3890, 102, 617, /*angle*/ 0, 90, 0, /*behParam*/ 0x010C0000, /*beh*/ bhvSlidingPlatform2), - OBJECT(/*model*/ MODEL_BITFS_MOVING_SQUARE_PLATFORM, /*pos*/ -3276, 102, 2, /*angle*/ 0, 270, 0, /*behParam*/ 0x010C0000, /*beh*/ bhvSlidingPlatform2), - OBJECT(/*model*/ MODEL_BITFS_SLIDING_PLATFORM, /*pos*/ 2103, 198, 312, /*angle*/ 0, 0, 0, /*behParam*/ 0x019F0000, /*beh*/ bhvSlidingPlatform2), - OBJECT(/*model*/ MODEL_BITFS_TUMBLING_PLATFORM, /*pos*/ 4979, 4250, 96, /*angle*/ 0, 0, 0, /*behParam*/ 0x00030000, /*beh*/ bhvWfTumblingBridge), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 3890, -2043, 266, /*angle*/ 0, 0, 0, /*behParam*/ 0x00520000, /*beh*/ bhvPoleGrabbing), + OBJECT(/*model*/ MODEL_BITFS_PLATFORM_ON_TRACK, /*pos*/ -5733, -3071, 0, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(0x07) | BPARAM2(0x33), /*bhv*/ bhvPlatformOnTrack), + OBJECT(/*model*/ MODEL_BITFS_TILTING_SQUARE_PLATFORM, /*pos*/ -1945, -3225, -715, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvBitFSTiltingInvertedPyramid), + OBJECT(/*model*/ MODEL_BITFS_TILTING_SQUARE_PLATFORM, /*pos*/ -2866, -3225, -715, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvBitFSTiltingInvertedPyramid), + OBJECT(/*model*/ MODEL_BITFS_SINKING_PLATFORMS, /*pos*/ -1381, 3487, 96, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvBitFSSinkingPlatforms), + OBJECT(/*model*/ MODEL_BITFS_SINKING_PLATFORMS, /*pos*/ 1126, -3065, 307, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvBitFSSinkingPlatforms), + OBJECT(/*model*/ MODEL_BITFS_SINKING_PLATFORMS, /*pos*/ -3225, 3487, 96, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvBitFSSinkingPlatforms), + OBJECT(/*model*/ MODEL_BITFS_SINKING_CAGE_PLATFORM, /*pos*/ 6605, -3071, 266, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(0x00), /*bhv*/ bhvBitFSSinkingCagePlatform), + OBJECT(/*model*/ MODEL_BITFS_SINKING_CAGE_PLATFORM, /*pos*/ 1843, 3584, 96, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(0x01), /*bhv*/ bhvBitFSSinkingCagePlatform), + OBJECT(/*model*/ MODEL_BITFS_SINKING_CAGE_PLATFORM, /*pos*/ 614, 3584, 96, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(0x01), /*bhv*/ bhvBitFSSinkingCagePlatform), + OBJECT(/*model*/ MODEL_BITFS_SINKING_CAGE_PLATFORM, /*pos*/ 3072, 3584, 96, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(0x01), /*bhv*/ bhvBitFSSinkingCagePlatform), + OBJECT(/*model*/ MODEL_BITFS_ELEVATOR, /*pos*/ 2867, -1279, 307, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(ACTIVATED_BF_PLAT_TYPE_BITFS_ELEVATOR) | BPARAM2(159), /*bhv*/ bhvActivatedBackAndForthPlatform), + OBJECT(/*model*/ MODEL_BITFS_STRETCHING_PLATFORMS, /*pos*/ -5836, 410, 300, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvSquishablePlatform), + OBJECT(/*model*/ MODEL_BITFS_SEESAW_PLATFORM, /*pos*/ 4454, -2226, 266, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(0x04), /*bhv*/ bhvSeesawPlatform), + OBJECT(/*model*/ MODEL_BITFS_SEESAW_PLATFORM, /*pos*/ 5786, -2380, 266, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(0x04), /*bhv*/ bhvSeesawPlatform), + OBJECT(/*model*/ MODEL_BITFS_MOVING_SQUARE_PLATFORM, /*pos*/ -3890, 102, 617, /*angle*/ 0, 90, 0, /*bhvParam*/ BPARAM1(0x01) | BPARAM2(0x0C), /*bhv*/ bhvSlidingPlatform2), + OBJECT(/*model*/ MODEL_BITFS_MOVING_SQUARE_PLATFORM, /*pos*/ -3276, 102, 2, /*angle*/ 0, 270, 0, /*bhvParam*/ BPARAM1(0x01) | BPARAM2(0x0C), /*bhv*/ bhvSlidingPlatform2), + OBJECT(/*model*/ MODEL_BITFS_SLIDING_PLATFORM, /*pos*/ 2103, 198, 312, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(0x01) | BPARAM2(0x9F), /*bhv*/ bhvSlidingPlatform2), + OBJECT(/*model*/ MODEL_BITFS_TUMBLING_PLATFORM, /*pos*/ 4979, 4250, 96, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(TUMBLING_BRIDGE_BP_BITFS), /*bhv*/ bhvTumblingBridge), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 3890, -2043, 266, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(82), /*bhv*/ bhvPoleGrabbing), RETURN(), }; static const LevelScript script_func_local_2[] = { - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -3226, 3584, -822, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvFlamethrower), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -1382, 3584, -822, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvFlamethrower), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 1229, 307, -412, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvFlamethrower), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ -3226, 3584, -822, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvFlamethrower), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ -1382, 3584, -822, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvFlamethrower), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 1229, 307, -412, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvFlamethrower), RETURN(), }; static const LevelScript script_func_local_3[] = { - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 1200, 5700, 160, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvBowserCourseRedCoinStar), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 1200, 5700, 160, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(STAR_INDEX_ACT_1), /*bhv*/ bhvBowserCourseRedCoinStar), RETURN(), }; const LevelScript level_bitfs_entry[] = { INIT_LEVEL(), - LOAD_MIO0( /*seg*/ 0x07, _bitfs_segment_7SegmentRomStart, _bitfs_segment_7SegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x07, _bitfs_segment_7SegmentRomStart, _bitfs_segment_7SegmentRomEnd), LOAD_MIO0_TEXTURE(/*seg*/ 0x09, _sky_mio0SegmentRomStart, _sky_mio0SegmentRomEnd), - LOAD_MIO0( /*seg*/ 0x0A, _bitfs_skybox_mio0SegmentRomStart, _bitfs_skybox_mio0SegmentRomEnd), - LOAD_MIO0( /*seg*/ 0x0B, _effect_mio0SegmentRomStart, _effect_mio0SegmentRomEnd), - LOAD_MIO0( /*seg*/ 0x05, _group2_mio0SegmentRomStart, _group2_mio0SegmentRomEnd), - LOAD_RAW( /*seg*/ 0x0C, _group2_geoSegmentRomStart, _group2_geoSegmentRomEnd), - LOAD_MIO0( /*seg*/ 0x06, _group17_mio0SegmentRomStart, _group17_mio0SegmentRomEnd), - LOAD_RAW( /*seg*/ 0x0D, _group17_geoSegmentRomStart, _group17_geoSegmentRomEnd), - LOAD_MIO0( /*seg*/ 0x08, _common0_mio0SegmentRomStart, _common0_mio0SegmentRomEnd), - LOAD_RAW( /*seg*/ 0x0F, _common0_geoSegmentRomStart, _common0_geoSegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x0A, _bitfs_skybox_mio0SegmentRomStart, _bitfs_skybox_mio0SegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x0B, _effect_mio0SegmentRomStart, _effect_mio0SegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x05, _group2_mio0SegmentRomStart, _group2_mio0SegmentRomEnd), + LOAD_RAW (/*seg*/ 0x0C, _group2_geoSegmentRomStart, _group2_geoSegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x06, _group17_mio0SegmentRomStart, _group17_mio0SegmentRomEnd), + LOAD_RAW (/*seg*/ 0x0D, _group17_geoSegmentRomStart, _group17_geoSegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x08, _common0_mio0SegmentRomStart, _common0_mio0SegmentRomEnd), + LOAD_RAW (/*seg*/ 0x0F, _common0_geoSegmentRomStart, _common0_geoSegmentRomEnd), ALLOC_LEVEL_POOL(), - MARIO(/*model*/ MODEL_MARIO, /*behParam*/ 0x00000001, /*beh*/ bhvMario), + MARIO(/*model*/ MODEL_MARIO, /*bhvParam*/ BPARAM4(0x01), /*bhv*/ bhvMario), JUMP_LINK(script_func_global_3), JUMP_LINK(script_func_global_18), JUMP_LINK(script_func_global_1), @@ -100,13 +100,13 @@ const LevelScript level_bitfs_entry[] = { LOAD_MODEL_FROM_GEO(MODEL_BITFS_TUMBLING_PLATFORM, bitfs_geo_0006F0), AREA(/*index*/ 1, bitfs_geo_0007A0), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -7577, -1764, 0, /*angle*/ 0, 90, 0, /*behParam*/ 0x000A0000, /*beh*/ bhvAirborneWarp), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 6735, 3681, 99, /*angle*/ 0, 0, 0, /*behParam*/ 0x140B0000, /*beh*/ bhvWarp), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 5886, 5000, 99, /*angle*/ 0, 90, 0, /*behParam*/ 0x000C0000, /*beh*/ bhvDeathWarp), - WARP_NODE(/*id*/ 0x0A, /*destLevel*/ LEVEL_BITFS, /*destArea*/ 0x01, /*destNode*/ 0x0A, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0x0B, /*destLevel*/ LEVEL_BOWSER_2, /*destArea*/ 0x01, /*destNode*/ 0x0A, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0x0C, /*destLevel*/ LEVEL_BITFS, /*destArea*/ 0x01, /*destNode*/ 0x0C, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0xF1, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x03, /*destNode*/ 0x68, /*flags*/ WARP_NO_CHECKPOINT), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ -7577, -1764, 0, /*angle*/ 0, 90, 0, /*bhvParam*/ BPARAM2(WARP_NODE_0A), /*bhv*/ bhvAirborneWarp), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 6735, 3681, 99, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(20) | BPARAM2(WARP_NODE_0B), /*bhv*/ bhvWarp), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 5886, 5000, 99, /*angle*/ 0, 90, 0, /*bhvParam*/ BPARAM2(WARP_NODE_0C), /*bhv*/ bhvDeathWarp), + WARP_NODE(/*id*/ WARP_NODE_0A, /*destLevel*/ LEVEL_BITFS, /*destArea*/ 1, /*destNode*/ WARP_NODE_0A, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_0B, /*destLevel*/ LEVEL_BOWSER_2, /*destArea*/ 1, /*destNode*/ WARP_NODE_0A, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_0C, /*destLevel*/ LEVEL_BITFS, /*destArea*/ 1, /*destNode*/ WARP_NODE_0C, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_DEATH, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 3, /*destNode*/ WARP_NODE_68, /*flags*/ WARP_NO_CHECKPOINT), JUMP_LINK(script_func_local_1), JUMP_LINK(script_func_local_2), JUMP_LINK(script_func_local_3), diff --git a/levels/bitfs/seesaw_platform/geo.inc.c b/levels/bitfs/seesaw_platform/geo.inc.c index 2efcfcf0..1e660131 100644 --- a/levels/bitfs/seesaw_platform/geo.inc.c +++ b/levels/bitfs/seesaw_platform/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000788 const GeoLayout bitfs_geo_000788[] = { - GEO_CULLING_RADIUS(800), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bitfs_seg7_dl_07011E28), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(800), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bitfs_seg7_dl_07011E28), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bitfs/sinking_cage_platform/geo.inc.c b/levels/bitfs/sinking_cage_platform/geo.inc.c index a1a4790c..0f771969 100644 --- a/levels/bitfs/sinking_cage_platform/geo.inc.c +++ b/levels/bitfs/sinking_cage_platform/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000690 const GeoLayout bitfs_geo_000690[] = { - GEO_CULLING_RADIUS(550), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, bitfs_seg7_dl_0700F6A8), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(550), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, bitfs_seg7_dl_0700F6A8), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bitfs/sinking_cage_pole/geo.inc.c b/levels/bitfs/sinking_cage_pole/geo.inc.c index e310384d..152ad1c7 100644 --- a/levels/bitfs/sinking_cage_pole/geo.inc.c +++ b/levels/bitfs/sinking_cage_pole/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E0006A8 const GeoLayout bitfs_geo_0006A8[] = { - GEO_CULLING_RADIUS(900), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bitfs_seg7_dl_0700FB38), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(900), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bitfs_seg7_dl_0700FB38), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bitfs/sinking_platforms/geo.inc.c b/levels/bitfs/sinking_platforms/geo.inc.c index e88e9035..1e4cc3ef 100644 --- a/levels/bitfs/sinking_platforms/geo.inc.c +++ b/levels/bitfs/sinking_platforms/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000770 const GeoLayout bitfs_geo_000770[] = { - GEO_CULLING_RADIUS(1300), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bitfs_seg7_dl_07011BA0), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(1300), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bitfs_seg7_dl_07011BA0), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bitfs/sliding_platform/geo.inc.c b/levels/bitfs/sliding_platform/geo.inc.c index 59ee8c55..ff3ae317 100644 --- a/levels/bitfs/sliding_platform/geo.inc.c +++ b/levels/bitfs/sliding_platform/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000740 const GeoLayout bitfs_geo_000740[] = { - GEO_CULLING_RADIUS(550), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bitfs_seg7_dl_07011568), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(550), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bitfs_seg7_dl_07011568), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bitfs/stretching_platform/geo.inc.c b/levels/bitfs/stretching_platform/geo.inc.c index b30b987e..d0f239a9 100644 --- a/levels/bitfs/stretching_platform/geo.inc.c +++ b/levels/bitfs/stretching_platform/geo.inc.c @@ -1,9 +1,9 @@ // 0x0E000708 const GeoLayout bitfs_geo_000708[] = { - GEO_CULLING_RADIUS(3000), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, bitfs_seg7_dl_07010340), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bitfs_seg7_dl_07011138), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(3000), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, bitfs_seg7_dl_07010340), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bitfs_seg7_dl_07011138), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bitfs/tilting_square_platform/geo.inc.c b/levels/bitfs/tilting_square_platform/geo.inc.c index c8aa53dc..41293686 100644 --- a/levels/bitfs/tilting_square_platform/geo.inc.c +++ b/levels/bitfs/tilting_square_platform/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E0006C0 const GeoLayout bitfs_geo_0006C0[] = { - GEO_CULLING_RADIUS(700), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bitfs_seg7_dl_0700FD08), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(700), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bitfs_seg7_dl_0700FD08), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bitfs/tumbling_platform_far/geo.inc.c b/levels/bitfs/tumbling_platform_far/geo.inc.c index cfd6927b..2f2f0f0b 100644 --- a/levels/bitfs/tumbling_platform_far/geo.inc.c +++ b/levels/bitfs/tumbling_platform_far/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E0006F0 const GeoLayout bitfs_geo_0006F0[] = { - GEO_CULLING_RADIUS(800), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bitfs_seg7_dl_07010168), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(800), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bitfs_seg7_dl_07010168), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bitfs/tumbling_platform_near/geo.inc.c b/levels/bitfs/tumbling_platform_near/geo.inc.c index 44f2edcc..f843af16 100644 --- a/levels/bitfs/tumbling_platform_near/geo.inc.c +++ b/levels/bitfs/tumbling_platform_near/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E0006D8 const GeoLayout bitfs_geo_0006D8[] = { - GEO_CULLING_RADIUS(400), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bitfs_seg7_dl_0700FF90), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(400), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bitfs_seg7_dl_0700FF90), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bits/areas/1/10/geo.inc.c b/levels/bits/areas/1/10/geo.inc.c index c8b35d42..b57d44f3 100644 --- a/levels/bits/areas/1/10/geo.inc.c +++ b/levels/bits/areas/1/10/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E0004F0 const GeoLayout bits_geo_0004F0[] = { - GEO_CULLING_RADIUS(1800), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bits_seg7_dl_07009690), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(1800), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bits_seg7_dl_07009690), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bits/areas/1/11/geo.inc.c b/levels/bits/areas/1/11/geo.inc.c index 79a10c9c..2fbbf056 100644 --- a/levels/bits/areas/1/11/geo.inc.c +++ b/levels/bits/areas/1/11/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000508 const GeoLayout bits_geo_000508[] = { - GEO_CULLING_RADIUS(3200), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bits_seg7_dl_0700B4A0), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(3200), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bits_seg7_dl_0700B4A0), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bits/areas/1/12/geo.inc.c b/levels/bits/areas/1/12/geo.inc.c index d8fd4453..99693983 100644 --- a/levels/bits/areas/1/12/geo.inc.c +++ b/levels/bits/areas/1/12/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000520 const GeoLayout bits_geo_000520[] = { - GEO_CULLING_RADIUS(1100), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bits_seg7_dl_0700B820), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(1100), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bits_seg7_dl_0700B820), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bits/areas/1/13/geo.inc.c b/levels/bits/areas/1/13/geo.inc.c index 13cde878..c11aea60 100644 --- a/levels/bits/areas/1/13/geo.inc.c +++ b/levels/bits/areas/1/13/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000538 const GeoLayout bits_geo_000538[] = { - GEO_CULLING_RADIUS(800), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, bits_seg7_dl_0700BA18), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(800), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, bits_seg7_dl_0700BA18), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bits/areas/1/14/geo.inc.c b/levels/bits/areas/1/14/geo.inc.c index 991fbc60..94eed8a6 100644 --- a/levels/bits/areas/1/14/geo.inc.c +++ b/levels/bits/areas/1/14/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000550 const GeoLayout bits_geo_000550[] = { - GEO_CULLING_RADIUS(2900), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bits_seg7_dl_0700CDC0), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(2900), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bits_seg7_dl_0700CDC0), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bits/areas/1/15/geo.inc.c b/levels/bits/areas/1/15/geo.inc.c index 3fa1f25e..e335455f 100644 --- a/levels/bits/areas/1/15/geo.inc.c +++ b/levels/bits/areas/1/15/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000568 const GeoLayout bits_geo_000568[] = { - GEO_CULLING_RADIUS(2400), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bits_seg7_dl_0700D278), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(2400), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bits_seg7_dl_0700D278), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bits/areas/1/16/geo.inc.c b/levels/bits/areas/1/16/geo.inc.c index 72c05ef9..0463273f 100644 --- a/levels/bits/areas/1/16/geo.inc.c +++ b/levels/bits/areas/1/16/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000580 const GeoLayout bits_geo_000580[] = { - GEO_CULLING_RADIUS(3500), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, bits_seg7_dl_0700D5A0), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(3500), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, bits_seg7_dl_0700D5A0), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bits/areas/1/17/geo.inc.c b/levels/bits/areas/1/17/geo.inc.c index f3e40957..f38c6676 100644 --- a/levels/bits/areas/1/17/geo.inc.c +++ b/levels/bits/areas/1/17/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000598 const GeoLayout bits_geo_000598[] = { - GEO_CULLING_RADIUS(2200), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bits_seg7_dl_0700DD00), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(2200), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bits_seg7_dl_0700DD00), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bits/areas/1/18/geo.inc.c b/levels/bits/areas/1/18/geo.inc.c index 965542d1..b1f37593 100644 --- a/levels/bits/areas/1/18/geo.inc.c +++ b/levels/bits/areas/1/18/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E0005B0 const GeoLayout bits_geo_0005B0[] = { - GEO_CULLING_RADIUS(2700), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bits_seg7_dl_0700FC70), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(2700), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bits_seg7_dl_0700FC70), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bits/areas/1/19/geo.inc.c b/levels/bits/areas/1/19/geo.inc.c index 8ea28d01..75ac51b4 100644 --- a/levels/bits/areas/1/19/geo.inc.c +++ b/levels/bits/areas/1/19/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E0005C8 const GeoLayout bits_geo_0005C8[] = { - GEO_CULLING_RADIUS(3300), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bits_seg7_dl_070128F0), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(3300), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bits_seg7_dl_070128F0), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bits/areas/1/2/geo.inc.c b/levels/bits/areas/1/2/geo.inc.c index 35495bbf..ab8878d8 100644 --- a/levels/bits/areas/1/2/geo.inc.c +++ b/levels/bits/areas/1/2/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000430 const GeoLayout bits_geo_000430[] = { - GEO_CULLING_RADIUS(3200), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bits_seg7_dl_07003670), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(3200), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bits_seg7_dl_07003670), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bits/areas/1/20/geo.inc.c b/levels/bits/areas/1/20/geo.inc.c index a56e5ab0..799a612b 100644 --- a/levels/bits/areas/1/20/geo.inc.c +++ b/levels/bits/areas/1/20/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E0005E0 const GeoLayout bits_geo_0005E0[] = { - GEO_CULLING_RADIUS(1100), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bits_seg7_dl_07012B10), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(1100), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bits_seg7_dl_07012B10), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bits/areas/1/21/geo.inc.c b/levels/bits/areas/1/21/geo.inc.c index 7fc69385..204f06b7 100644 --- a/levels/bits/areas/1/21/geo.inc.c +++ b/levels/bits/areas/1/21/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E0005F8 const GeoLayout bits_geo_0005F8[] = { - GEO_CULLING_RADIUS(700), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bits_seg7_dl_07012D40), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(700), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bits_seg7_dl_07012D40), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bits/areas/1/22/geo.inc.c b/levels/bits/areas/1/22/geo.inc.c index edbe4217..0883f998 100644 --- a/levels/bits/areas/1/22/geo.inc.c +++ b/levels/bits/areas/1/22/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000610 const GeoLayout bits_geo_000610[] = { - GEO_CULLING_RADIUS(1300), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bits_seg7_dl_070135A0), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(1300), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bits_seg7_dl_070135A0), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bits/areas/1/23/geo.inc.c b/levels/bits/areas/1/23/geo.inc.c index 61984039..677af799 100644 --- a/levels/bits/areas/1/23/geo.inc.c +++ b/levels/bits/areas/1/23/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000628 const GeoLayout bits_geo_000628[] = { - GEO_CULLING_RADIUS(600), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bits_seg7_dl_07013820), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(600), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bits_seg7_dl_07013820), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bits/areas/1/24/geo.inc.c b/levels/bits/areas/1/24/geo.inc.c index 6a66c119..1ec05d69 100644 --- a/levels/bits/areas/1/24/geo.inc.c +++ b/levels/bits/areas/1/24/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000640 const GeoLayout bits_geo_000640[] = { - GEO_CULLING_RADIUS(600), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bits_seg7_dl_07013C78), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(600), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bits_seg7_dl_07013C78), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bits/areas/1/25/geo.inc.c b/levels/bits/areas/1/25/geo.inc.c index 245f8716..46d40db2 100644 --- a/levels/bits/areas/1/25/geo.inc.c +++ b/levels/bits/areas/1/25/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000658 const GeoLayout bits_geo_000658[] = { - GEO_CULLING_RADIUS(700), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bits_seg7_dl_07013EF8), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(700), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bits_seg7_dl_07013EF8), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bits/areas/1/26/geo.inc.c b/levels/bits/areas/1/26/geo.inc.c index 752cb935..e78751d9 100644 --- a/levels/bits/areas/1/26/geo.inc.c +++ b/levels/bits/areas/1/26/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000670 const GeoLayout bits_geo_000670[] = { - GEO_CULLING_RADIUS(1100), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bits_seg7_dl_07014178), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(1100), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bits_seg7_dl_07014178), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bits/areas/1/27/geo.inc.c b/levels/bits/areas/1/27/geo.inc.c index 360c7188..b0fbf54f 100644 --- a/levels/bits/areas/1/27/geo.inc.c +++ b/levels/bits/areas/1/27/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000688 const GeoLayout bits_geo_000688[] = { - GEO_CULLING_RADIUS(1900), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bits_seg7_dl_07014C28), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(1900), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bits_seg7_dl_07014C28), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bits/areas/1/28/geo.inc.c b/levels/bits/areas/1/28/geo.inc.c index 947cd093..ae27d6ab 100644 --- a/levels/bits/areas/1/28/geo.inc.c +++ b/levels/bits/areas/1/28/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E0006A0 const GeoLayout bits_geo_0006A0[] = { - GEO_CULLING_RADIUS(2100), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bits_seg7_dl_070153C0), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(2100), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bits_seg7_dl_070153C0), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bits/areas/1/29/geo.inc.c b/levels/bits/areas/1/29/geo.inc.c index 3a160451..fe724619 100644 --- a/levels/bits/areas/1/29/geo.inc.c +++ b/levels/bits/areas/1/29/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E0006B8 const GeoLayout bits_geo_0006B8[] = { - GEO_CULLING_RADIUS(2100), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bits_seg7_dl_07015B60), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(2100), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bits_seg7_dl_07015B60), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bits/areas/1/3/geo.inc.c b/levels/bits/areas/1/3/geo.inc.c index 4f30e267..8eca6e59 100644 --- a/levels/bits/areas/1/3/geo.inc.c +++ b/levels/bits/areas/1/3/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000448 const GeoLayout bits_geo_000448[] = { - GEO_CULLING_RADIUS(3200), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bits_seg7_dl_070047F0), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(3200), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bits_seg7_dl_070047F0), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bits/areas/1/30/geo.inc.c b/levels/bits/areas/1/30/geo.inc.c index a00b0133..9300693d 100644 --- a/levels/bits/areas/1/30/geo.inc.c +++ b/levels/bits/areas/1/30/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E0006D0 const GeoLayout bits_geo_0006D0[] = { - GEO_CULLING_RADIUS(2100), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bits_seg7_dl_07016300), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(2100), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bits_seg7_dl_07016300), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bits/areas/1/31/geo.inc.c b/levels/bits/areas/1/31/geo.inc.c index 64590cb7..daa151ab 100644 --- a/levels/bits/areas/1/31/geo.inc.c +++ b/levels/bits/areas/1/31/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E0006E8 const GeoLayout bits_geo_0006E8[] = { - GEO_CULLING_RADIUS(2100), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bits_seg7_dl_07016AA0), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(2100), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bits_seg7_dl_07016AA0), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bits/areas/1/32/geo.inc.c b/levels/bits/areas/1/32/geo.inc.c index 49547961..afbd2771 100644 --- a/levels/bits/areas/1/32/geo.inc.c +++ b/levels/bits/areas/1/32/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000700 const GeoLayout bits_geo_000700[] = { - GEO_CULLING_RADIUS(2100), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bits_seg7_dl_07016DA0), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(2100), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bits_seg7_dl_07016DA0), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bits/areas/1/4/geo.inc.c b/levels/bits/areas/1/4/geo.inc.c index 7e63710d..f15f79de 100644 --- a/levels/bits/areas/1/4/geo.inc.c +++ b/levels/bits/areas/1/4/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000460 const GeoLayout bits_geo_000460[] = { - GEO_CULLING_RADIUS(3900), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bits_seg7_dl_07005DB8), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(3900), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bits_seg7_dl_07005DB8), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bits/areas/1/5/geo.inc.c b/levels/bits/areas/1/5/geo.inc.c index 7d10d034..9433b149 100644 --- a/levels/bits/areas/1/5/geo.inc.c +++ b/levels/bits/areas/1/5/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000478 const GeoLayout bits_geo_000478[] = { - GEO_CULLING_RADIUS(2500), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bits_seg7_dl_07007AF0), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(2500), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bits_seg7_dl_07007AF0), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bits/areas/1/6/geo.inc.c b/levels/bits/areas/1/6/geo.inc.c index 31a7dbdc..f78f2bed 100644 --- a/levels/bits/areas/1/6/geo.inc.c +++ b/levels/bits/areas/1/6/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000490 const GeoLayout bits_geo_000490[] = { - GEO_CULLING_RADIUS(1000), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, bits_seg7_dl_07007C28), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(1000), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, bits_seg7_dl_07007C28), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bits/areas/1/7/geo.inc.c b/levels/bits/areas/1/7/geo.inc.c index c46efb4f..d8300a84 100644 --- a/levels/bits/areas/1/7/geo.inc.c +++ b/levels/bits/areas/1/7/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E0004A8 const GeoLayout bits_geo_0004A8[] = { - GEO_CULLING_RADIUS(1000), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bits_seg7_dl_07007EC8), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(1000), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bits_seg7_dl_07007EC8), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bits/areas/1/8/geo.inc.c b/levels/bits/areas/1/8/geo.inc.c index 998ce57f..d5393a08 100644 --- a/levels/bits/areas/1/8/geo.inc.c +++ b/levels/bits/areas/1/8/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E0004C0 const GeoLayout bits_geo_0004C0[] = { - GEO_CULLING_RADIUS(2700), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bits_seg7_dl_07008D18), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(2700), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bits_seg7_dl_07008D18), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bits/areas/1/9/geo.inc.c b/levels/bits/areas/1/9/geo.inc.c index 2ffb84ae..3548cce9 100644 --- a/levels/bits/areas/1/9/geo.inc.c +++ b/levels/bits/areas/1/9/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E0004D8 const GeoLayout bits_geo_0004D8[] = { - GEO_CULLING_RADIUS(1600), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, bits_seg7_dl_07008FE8), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(1600), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, bits_seg7_dl_07008FE8), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bits/areas/1/geo.inc.c b/levels/bits/areas/1/geo.inc.c index 50e96cc3..831ee315 100644 --- a/levels/bits/areas/1/geo.inc.c +++ b/levels/bits/areas/1/geo.inc.c @@ -1,26 +1,26 @@ // 0x0E000718 const GeoLayout bits_geo_000718[] = { - GEO_NODE_SCREEN_AREA(10, SCREEN_WIDTH/2, SCREEN_HEIGHT/2, SCREEN_WIDTH/2, SCREEN_HEIGHT/2), - GEO_OPEN_NODE(), - GEO_ZBUFFER(0), - GEO_OPEN_NODE(), - GEO_NODE_ORTHO(100), - GEO_OPEN_NODE(), - GEO_BACKGROUND(BACKGROUND_PURPLE_SKY, geo_skybox_main), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ZBUFFER(1), - GEO_OPEN_NODE(), - GEO_CAMERA_FRUSTUM_WITH_FUNC(45, 100, 20000, geo_camera_fov), - GEO_OPEN_NODE(), - GEO_CAMERA(14, 0, 2000, 6000, 0, -4500, -8000, geo_camera_main), + GEO_NODE_SCREEN_AREA(10, SCREEN_WIDTH/2, SCREEN_HEIGHT/2, SCREEN_WIDTH/2, SCREEN_HEIGHT/2), + GEO_OPEN_NODE(), + GEO_ZBUFFER(0), + GEO_OPEN_NODE(), + GEO_NODE_ORTHO(100), GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, bits_seg7_dl_07002918), - GEO_RENDER_OBJ(), - GEO_ASM(0, geo_envfx_main), + GEO_BACKGROUND(BACKGROUND_PURPLE_SKY, geo_skybox_main), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CLOSE_NODE(), + GEO_ZBUFFER(1), + GEO_OPEN_NODE(), + GEO_CAMERA_FRUSTUM_WITH_FUNC(45, 100, 20000, geo_camera_fov), + GEO_OPEN_NODE(), + GEO_CAMERA(14, 0, 2000, 6000, 0, -4500, -8000, geo_camera_main), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, bits_seg7_dl_07002918), + GEO_RENDER_OBJ(), + GEO_ASM(0, geo_envfx_main), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bits/areas/1/macro.inc.c b/levels/bits/areas/1/macro.inc.c index 663871c0..4f4af5c4 100644 --- a/levels/bits/areas/1/macro.inc.c +++ b/levels/bits/areas/1/macro.inc.c @@ -1,60 +1,60 @@ // 0x0701A76C - 0x0701A99E const MacroObject bits_seg7_macro_objs[] = { - MACRO_OBJECT(/*preset*/ macro_yellow_coin, /*yaw*/ 0, /*pos*/ -1400, -4000, 0), - MACRO_OBJECT(/*preset*/ macro_yellow_coin, /*yaw*/ 0, /*pos*/ -272, -4000, 0), - MACRO_OBJECT(/*preset*/ macro_yellow_coin, /*yaw*/ 0, /*pos*/ 840, -4000, 0), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_circling_amp, /*yaw*/ 0, /*pos*/ 4100, -1320, -1800, /*behParam*/ 1), - MACRO_OBJECT(/*preset*/ macro_goomba, /*yaw*/ 0, /*pos*/ 6180, -1791, 0), - MACRO_OBJECT(/*preset*/ macro_goomba, /*yaw*/ 0, /*pos*/ 6260, -1453, -1800), - MACRO_OBJECT(/*preset*/ macro_fire_piranha_plant, /*yaw*/ 0, /*pos*/ 1920, -1187, -1840), - MACRO_OBJECT(/*preset*/ macro_coin_line_horizontal, /*yaw*/ 0, /*pos*/ -5080, -2457, -800), - MACRO_OBJECT(/*preset*/ macro_1up, /*yaw*/ 0, /*pos*/ 1380, -1740, -660), - MACRO_OBJECT(/*preset*/ macro_whomp, /*yaw*/ 90, /*pos*/ -4180, -1330, -800), - MACRO_OBJECT(/*preset*/ macro_chuckya, /*yaw*/ 90, /*pos*/ -3909, -409, -1199), - MACRO_OBJECT(/*preset*/ macro_yellow_coin, /*yaw*/ 0, /*pos*/ 600, -200, -900), - MACRO_OBJECT(/*preset*/ macro_yellow_coin, /*yaw*/ 0, /*pos*/ 900, 60, -900), - MACRO_OBJECT(/*preset*/ macro_yellow_coin, /*yaw*/ 0, /*pos*/ 1200, 310, -900), - MACRO_OBJECT(/*preset*/ macro_yellow_coin, /*yaw*/ 0, /*pos*/ 1500, 560, -900), - MACRO_OBJECT(/*preset*/ macro_yellow_coin, /*yaw*/ 0, /*pos*/ 1800, 810, -900), - MACRO_OBJECT(/*preset*/ macro_yellow_coin, /*yaw*/ 0, /*pos*/ 2100, 1060, -900), - MACRO_OBJECT(/*preset*/ macro_recovery_heart, /*yaw*/ 0, /*pos*/ 1279, 2639, -959), - MACRO_OBJECT(/*preset*/ macro_1up, /*yaw*/ 0, /*pos*/ -1399, 2750, -1159), - MACRO_OBJECT(/*preset*/ macro_bobomb, /*yaw*/ 0, /*pos*/ -2839, 2059, -959), - MACRO_OBJECT(/*preset*/ macro_bobomb, /*yaw*/ 0, /*pos*/ -3479, 2059, -799), - MACRO_OBJECT(/*preset*/ macro_yellow_coin, /*yaw*/ 0, /*pos*/ -7200, 2080, -890), - MACRO_OBJECT(/*preset*/ macro_yellow_coin, /*yaw*/ 0, /*pos*/ -6600, 2080, -180), - MACRO_OBJECT(/*preset*/ macro_yellow_coin, /*yaw*/ 0, /*pos*/ -6600, 2080, -1550), - MACRO_OBJECT(/*preset*/ macro_hidden_1up_trigger, /*yaw*/ 0, /*pos*/ -6600, 2080, -180), - MACRO_OBJECT(/*preset*/ macro_hidden_1up_trigger, /*yaw*/ 0, /*pos*/ -7200, 2080, -890), - MACRO_OBJECT(/*preset*/ macro_hidden_1up_trigger, /*yaw*/ 0, /*pos*/ -6600, 2080, -1550), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_hidden_1up, /*yaw*/ 0, /*pos*/ -6640, 2280, -890, /*behParam*/ 3), - MACRO_OBJECT(/*preset*/ macro_goomba_triplet_spawner, /*yaw*/ 0, /*pos*/ -5239, 3839, -999), - MACRO_OBJECT(/*preset*/ macro_bobomb, /*yaw*/ 0, /*pos*/ -1559, 3800, -1079), - MACRO_OBJECT(/*preset*/ macro_bobomb, /*yaw*/ 0, /*pos*/ -1079, 3800, -1039), - MACRO_OBJECT(/*preset*/ macro_coin_line_horizontal, /*yaw*/ 0, /*pos*/ 1879, 4639, -1559), - MACRO_OBJECT(/*preset*/ macro_1up, /*yaw*/ 0, /*pos*/ -259, 6059, -3759), - MACRO_OBJECT(/*preset*/ macro_recovery_heart, /*yaw*/ 0, /*pos*/ 359, 6099, -3219), - MACRO_OBJECT(/*preset*/ macro_fire_piranha_plant, /*yaw*/ 0, /*pos*/ 3680, 2428, -1840), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_circling_amp, /*yaw*/ 0, /*pos*/ -6460, 2080, -900, /*behParam*/ 2), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_circling_amp, /*yaw*/ 0, /*pos*/ -6460, 2280, -900, /*behParam*/ 0), - MACRO_OBJECT(/*preset*/ macro_goomba_triplet_spawner, /*yaw*/ 0, /*pos*/ 360, 6040, -2880), - MACRO_OBJECT(/*preset*/ macro_coin_line_horizontal, /*yaw*/ 0, /*pos*/ -302, -2457, -800), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 1590, -1120, -2055), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -2960, -3360, 0), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -298, -2600, -1600), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 7618, 4850, -1909), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -136, 3109, -909), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -3330, 4050, -900), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -4830, 2103, -1030), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 348, 5921, -4585), - MACRO_OBJECT(/*preset*/ macro_pushable_metal_box, /*yaw*/ 0, /*pos*/ -2300, -4100, 0), - MACRO_OBJECT(/*preset*/ macro_fire_spitter, /*yaw*/ 0, /*pos*/ -4769, 2344, -904), - MACRO_OBJECT(/*preset*/ macro_fire_spitter, /*yaw*/ 0, /*pos*/ 377, 4140, -2042), - MACRO_OBJECT(/*preset*/ macro_1up, /*yaw*/ 0, /*pos*/ -1751, -1246, -805), - MACRO_OBJECT(/*preset*/ macro_fire_spitter, /*yaw*/ 0, /*pos*/ -6712, -899, -796), - MACRO_OBJECT(/*preset*/ macro_coin_line_horizontal, /*yaw*/ 0, /*pos*/ 7322, 4566, -1922), - MACRO_OBJECT(/*preset*/ macro_fire_spitter, /*yaw*/ 0, /*pos*/ -3600, -2433, -800), - MACRO_OBJECT(/*preset*/ macro_fire_spitter, /*yaw*/ 0, /*pos*/ -2656, -2442, -800), - MACRO_OBJECT(/*preset*/ macro_box_1up_running_away, /*yaw*/ 0, /*pos*/ 4100, -1050, -1800), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_1, /*yaw*/ 0, /*pos*/ -1400, -4000, 0), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_1, /*yaw*/ 0, /*pos*/ -272, -4000, 0), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_1, /*yaw*/ 0, /*pos*/ 840, -4000, 0), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_circling_amp, /*yaw*/ 0, /*pos*/ 4100, -1320, -1800, /*bhvParam*/ AMP_BP_ROT_RADIUS_300), + MACRO_OBJECT (/*preset*/ macro_goomba, /*yaw*/ 0, /*pos*/ 6180, -1791, 0), + MACRO_OBJECT (/*preset*/ macro_goomba, /*yaw*/ 0, /*pos*/ 6260, -1453, -1800), + MACRO_OBJECT (/*preset*/ macro_fire_piranha_plant_1, /*yaw*/ 0, /*pos*/ 1920, -1187, -1840), + MACRO_OBJECT (/*preset*/ macro_coin_line_horizontal, /*yaw*/ 0, /*pos*/ -5080, -2457, -800), + MACRO_OBJECT (/*preset*/ macro_1up, /*yaw*/ 0, /*pos*/ 1380, -1740, -660), + MACRO_OBJECT (/*preset*/ macro_whomp, /*yaw*/ 90, /*pos*/ -4180, -1330, -800), + MACRO_OBJECT (/*preset*/ macro_chuckya, /*yaw*/ 90, /*pos*/ -3909, -409, -1199), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_1, /*yaw*/ 0, /*pos*/ 600, -200, -900), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_1, /*yaw*/ 0, /*pos*/ 900, 60, -900), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_1, /*yaw*/ 0, /*pos*/ 1200, 310, -900), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_1, /*yaw*/ 0, /*pos*/ 1500, 560, -900), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_1, /*yaw*/ 0, /*pos*/ 1800, 810, -900), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_1, /*yaw*/ 0, /*pos*/ 2100, 1060, -900), + MACRO_OBJECT (/*preset*/ macro_recovery_heart, /*yaw*/ 0, /*pos*/ 1279, 2639, -959), + MACRO_OBJECT (/*preset*/ macro_1up, /*yaw*/ 0, /*pos*/ -1399, 2750, -1159), + MACRO_OBJECT (/*preset*/ macro_bobomb, /*yaw*/ 0, /*pos*/ -2839, 2059, -959), + MACRO_OBJECT (/*preset*/ macro_bobomb, /*yaw*/ 0, /*pos*/ -3479, 2059, -799), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_1, /*yaw*/ 0, /*pos*/ -7200, 2080, -890), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_1, /*yaw*/ 0, /*pos*/ -6600, 2080, -180), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_1, /*yaw*/ 0, /*pos*/ -6600, 2080, -1550), + MACRO_OBJECT (/*preset*/ macro_hidden_1up_trigger, /*yaw*/ 0, /*pos*/ -6600, 2080, -180), + MACRO_OBJECT (/*preset*/ macro_hidden_1up_trigger, /*yaw*/ 0, /*pos*/ -7200, 2080, -890), + MACRO_OBJECT (/*preset*/ macro_hidden_1up_trigger, /*yaw*/ 0, /*pos*/ -6600, 2080, -1550), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_hidden_1up, /*yaw*/ 0, /*pos*/ -6640, 2280, -890, /*bhvParam*/ 3), + MACRO_OBJECT (/*preset*/ macro_goomba_triplet_spawner, /*yaw*/ 0, /*pos*/ -5239, 3839, -999), + MACRO_OBJECT (/*preset*/ macro_bobomb, /*yaw*/ 0, /*pos*/ -1559, 3800, -1079), + MACRO_OBJECT (/*preset*/ macro_bobomb, /*yaw*/ 0, /*pos*/ -1079, 3800, -1039), + MACRO_OBJECT (/*preset*/ macro_coin_line_horizontal, /*yaw*/ 0, /*pos*/ 1879, 4639, -1559), + MACRO_OBJECT (/*preset*/ macro_1up, /*yaw*/ 0, /*pos*/ -259, 6059, -3759), + MACRO_OBJECT (/*preset*/ macro_recovery_heart, /*yaw*/ 0, /*pos*/ 359, 6099, -3219), + MACRO_OBJECT (/*preset*/ macro_fire_piranha_plant_1, /*yaw*/ 0, /*pos*/ 3680, 2428, -1840), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_circling_amp, /*yaw*/ 0, /*pos*/ -6460, 2080, -900, /*bhvParam*/ AMP_BP_ROT_RADIUS_400), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_circling_amp, /*yaw*/ 0, /*pos*/ -6460, 2280, -900, /*bhvParam*/ AMP_BP_ROT_RADIUS_200), + MACRO_OBJECT (/*preset*/ macro_goomba_triplet_spawner, /*yaw*/ 0, /*pos*/ 360, 6040, -2880), + MACRO_OBJECT (/*preset*/ macro_coin_line_horizontal, /*yaw*/ 0, /*pos*/ -302, -2457, -800), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 1590, -1120, -2055), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -2960, -3360, 0), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -298, -2600, -1600), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 7618, 4850, -1909), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -136, 3109, -909), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -3330, 4050, -900), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -4830, 2103, -1030), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 348, 5921, -4585), + MACRO_OBJECT (/*preset*/ macro_pushable_metal_box, /*yaw*/ 0, /*pos*/ -2300, -4100, 0), + MACRO_OBJECT (/*preset*/ macro_fire_spitter, /*yaw*/ 0, /*pos*/ -4769, 2344, -904), + MACRO_OBJECT (/*preset*/ macro_fire_spitter, /*yaw*/ 0, /*pos*/ 377, 4140, -2042), + MACRO_OBJECT (/*preset*/ macro_1up, /*yaw*/ 0, /*pos*/ -1751, -1246, -805), + MACRO_OBJECT (/*preset*/ macro_fire_spitter, /*yaw*/ 0, /*pos*/ -6712, -899, -796), + MACRO_OBJECT (/*preset*/ macro_coin_line_horizontal, /*yaw*/ 0, /*pos*/ 7322, 4566, -1922), + MACRO_OBJECT (/*preset*/ macro_fire_spitter, /*yaw*/ 0, /*pos*/ -3600, -2433, -800), + MACRO_OBJECT (/*preset*/ macro_fire_spitter, /*yaw*/ 0, /*pos*/ -2656, -2442, -800), + MACRO_OBJECT (/*preset*/ macro_box_1up_running_away, /*yaw*/ 0, /*pos*/ 4100, -1050, -1800), MACRO_OBJECT_END(), }; diff --git a/levels/bits/leveldata.c b/levels/bits/leveldata.c index 50b749ab..4134039d 100644 --- a/levels/bits/leveldata.c +++ b/levels/bits/leveldata.c @@ -3,8 +3,8 @@ #include "surface_terrains.h" #include "moving_texture_macros.h" #include "level_misc_macros.h" -#include "macro_preset_names.h" -#include "special_preset_names.h" +#include "macro_presets.h" +#include "special_presets.h" #include "textures.h" #include "make_const_nonconst.h" diff --git a/levels/bits/script.c b/levels/bits/script.c index 2d1bd872..2b18239d 100644 --- a/levels/bits/script.c +++ b/levels/bits/script.c @@ -16,44 +16,44 @@ #include "levels/bits/header.h" static const LevelScript script_func_local_1[] = { - OBJECT(/*model*/ MODEL_BITS_SLIDING_PLATFORM, /*pos*/ -2370, -4525, 0, /*angle*/ 0, 0, 0, /*behParam*/ 0x00100000, /*beh*/ bhvSlidingPlatform2), - OBJECT(/*model*/ MODEL_BITS_TWIN_SLIDING_PLATFORMS, /*pos*/ -2611, 3544, -904, /*angle*/ 0, 0, 0, /*behParam*/ 0x00CF0000, /*beh*/ bhvSlidingPlatform2), - OBJECT(/*model*/ MODEL_BITS_TWIN_SLIDING_PLATFORMS, /*pos*/ -4700, 3544, -904, /*angle*/ 0, 180, 0, /*behParam*/ 0x008F0000, /*beh*/ bhvSlidingPlatform2), - OBJECT(/*model*/ MODEL_BITS_OCTAGONAL_PLATFORM, /*pos*/ 4139, -1740, -1831, /*angle*/ 0, 0, 0, /*behParam*/ 0x02000000, /*beh*/ bhvOctagonalPlatformRotating), - OBJECT(/*model*/ MODEL_BITS_OCTAGONAL_PLATFORM, /*pos*/ -6459, 1732, -904, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvOctagonalPlatformRotating), - OBJECT(/*model*/ MODEL_BITS_OCTAGONAL_PLATFORM, /*pos*/ -4770, 1732, -904, /*angle*/ 0, 0, 0, /*behParam*/ 0x02000000, /*beh*/ bhvOctagonalPlatformRotating), - OBJECT(/*model*/ MODEL_BITS_FERRIS_WHEEL_AXLE, /*pos*/ -1748, -1330, -1094, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvFerrisWheelAxle), - OBJECT(/*model*/ MODEL_BITS_FERRIS_WHEEL_AXLE, /*pos*/ 2275, 5628, -1315, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvFerrisWheelAxle), - OBJECT(/*model*/ MODEL_BITS_FERRIS_WHEEL_AXLE, /*pos*/ 3114, 4701, -1320, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvFerrisWheelAxle), - OBJECT(/*model*/ MODEL_BITS_ARROW_PLATFORM, /*pos*/ 2793, 2325, -904, /*angle*/ 0, 0, 0, /*behParam*/ 0x00610000, /*beh*/ bhvActivatedBackAndForthPlatform), - OBJECT(/*model*/ MODEL_BITS_SEESAW_PLATFORM, /*pos*/ 27, -1555, -713, /*angle*/ 0, 90, 0, /*behParam*/ 0x00010000, /*beh*/ bhvSeesawPlatform), - OBJECT(/*model*/ MODEL_BITS_TILTING_W_PLATFORM, /*pos*/ -306, -4300, 0, /*angle*/ 0, 0, 0, /*behParam*/ 0x00020000, /*beh*/ bhvSeesawPlatform), - OBJECT(/*model*/ MODEL_BITS_STAIRCASE, /*pos*/ 1769, -234, -899, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvAnimatesOnFloorSwitchPress), - OBJECT(/*model*/ MODEL_PURPLE_SWITCH, /*pos*/ -279, -234, -900, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvFloorSwitchAnimatesObject), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -6460, 2039, -905, /*angle*/ 0, 0, 0, /*behParam*/ 0x00CF0000, /*beh*/ bhvPoleGrabbing), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -3326, 3227, -905, /*angle*/ 0, 0, 0, /*behParam*/ 0x004D0000, /*beh*/ bhvPoleGrabbing), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 5518, 3184, -4019, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvFlamethrower), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 6465, 3731, -1915, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvFlamethrower), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 5915, 3718, -4019, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvFlamethrower), + OBJECT(/*model*/ MODEL_BITS_SLIDING_PLATFORM, /*pos*/ -2370, -4525, 0, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(0x10), /*bhv*/ bhvSlidingPlatform2), + OBJECT(/*model*/ MODEL_BITS_TWIN_SLIDING_PLATFORMS, /*pos*/ -2611, 3544, -904, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(0xCF), /*bhv*/ bhvSlidingPlatform2), + OBJECT(/*model*/ MODEL_BITS_TWIN_SLIDING_PLATFORMS, /*pos*/ -4700, 3544, -904, /*angle*/ 0, 180, 0, /*bhvParam*/ BPARAM2(0x8F), /*bhv*/ bhvSlidingPlatform2), + OBJECT(/*model*/ MODEL_BITS_OCTAGONAL_PLATFORM, /*pos*/ 4139, -1740, -1831, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(0x02), /*bhv*/ bhvOctagonalPlatformRotating), + OBJECT(/*model*/ MODEL_BITS_OCTAGONAL_PLATFORM, /*pos*/ -6459, 1732, -904, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvOctagonalPlatformRotating), + OBJECT(/*model*/ MODEL_BITS_OCTAGONAL_PLATFORM, /*pos*/ -4770, 1732, -904, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(0x02), /*bhv*/ bhvOctagonalPlatformRotating), + OBJECT(/*model*/ MODEL_BITS_FERRIS_WHEEL_AXLE, /*pos*/ -1748, -1330, -1094, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvFerrisWheelAxle), + OBJECT(/*model*/ MODEL_BITS_FERRIS_WHEEL_AXLE, /*pos*/ 2275, 5628, -1315, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvFerrisWheelAxle), + OBJECT(/*model*/ MODEL_BITS_FERRIS_WHEEL_AXLE, /*pos*/ 3114, 4701, -1320, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvFerrisWheelAxle), + OBJECT(/*model*/ MODEL_BITS_ARROW_PLATFORM, /*pos*/ 2793, 2325, -904, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(ACTIVATED_BF_PLAT_TYPE_BITS_ARROW_PLAT) | BPARAM2(97), /*bhv*/ bhvActivatedBackAndForthPlatform), + OBJECT(/*model*/ MODEL_BITS_SEESAW_PLATFORM, /*pos*/ 27, -1555, -713, /*angle*/ 0, 90, 0, /*bhvParam*/ BPARAM2(0x01), /*bhv*/ bhvSeesawPlatform), + OBJECT(/*model*/ MODEL_BITS_TILTING_W_PLATFORM, /*pos*/ -306, -4300, 0, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(0x02), /*bhv*/ bhvSeesawPlatform), + OBJECT(/*model*/ MODEL_BITS_STAIRCASE, /*pos*/ 1769, -234, -899, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvAnimatesOnFloorSwitchPress), + OBJECT(/*model*/ MODEL_PURPLE_SWITCH, /*pos*/ -279, -234, -900, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvFloorSwitchAnimatesObject), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ -6460, 2039, -905, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(207), /*bhv*/ bhvPoleGrabbing), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ -3326, 3227, -905, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(77), /*bhv*/ bhvPoleGrabbing), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 5518, 3184, -4019, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvFlamethrower), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 6465, 3731, -1915, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvFlamethrower), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 5915, 3718, -4019, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvFlamethrower), RETURN(), }; static const LevelScript script_func_local_2[] = { - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 350, 6800, -6800, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvBowserCourseRedCoinStar), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 350, 6800, -6800, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(STAR_INDEX_ACT_1), /*bhv*/ bhvBowserCourseRedCoinStar), RETURN(), }; const LevelScript level_bits_entry[] = { INIT_LEVEL(), - LOAD_MIO0( /*seg*/ 0x07, _bits_segment_7SegmentRomStart, _bits_segment_7SegmentRomEnd), - LOAD_MIO0( /*seg*/ 0x0A, _bits_skybox_mio0SegmentRomStart, _bits_skybox_mio0SegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x07, _bits_segment_7SegmentRomStart, _bits_segment_7SegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x0A, _bits_skybox_mio0SegmentRomStart, _bits_skybox_mio0SegmentRomEnd), LOAD_MIO0_TEXTURE(/*seg*/ 0x09, _sky_mio0SegmentRomStart, _sky_mio0SegmentRomEnd), - LOAD_MIO0( /*seg*/ 0x06, _group14_mio0SegmentRomStart, _group14_mio0SegmentRomEnd), - LOAD_RAW( /*seg*/ 0x0D, _group14_geoSegmentRomStart, _group14_geoSegmentRomEnd), - LOAD_MIO0( /*seg*/ 0x08, _common0_mio0SegmentRomStart, _common0_mio0SegmentRomEnd), - LOAD_RAW( /*seg*/ 0x0F, _common0_geoSegmentRomStart, _common0_geoSegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x06, _group14_mio0SegmentRomStart, _group14_mio0SegmentRomEnd), + LOAD_RAW (/*seg*/ 0x0D, _group14_geoSegmentRomStart, _group14_geoSegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x08, _common0_mio0SegmentRomStart, _common0_mio0SegmentRomEnd), + LOAD_RAW (/*seg*/ 0x0F, _common0_geoSegmentRomStart, _common0_geoSegmentRomEnd), ALLOC_LEVEL_POOL(), - MARIO(/*model*/ MODEL_MARIO, /*behParam*/ 0x00000001, /*beh*/ bhvMario), + MARIO(/*model*/ MODEL_MARIO, /*bhvParam*/ BPARAM4(0x01), /*bhv*/ bhvMario), JUMP_LINK(script_func_global_15), JUMP_LINK(script_func_global_1), LOAD_MODEL_FROM_GEO(MODEL_LEVEL_GEOMETRY_03, bits_geo_000430), @@ -90,13 +90,13 @@ const LevelScript level_bits_entry[] = { LOAD_MODEL_FROM_GEO(MODEL_BITS_WARP_PIPE, warp_pipe_geo), AREA(/*index*/ 1, bits_geo_000718), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -7039, -3812, 4, /*angle*/ 0, 90, 0, /*behParam*/ 0x000A0000, /*beh*/ bhvAirborneWarp), - OBJECT(/*model*/ MODEL_BITS_WARP_PIPE, /*pos*/ 351, 6652, -6030, /*angle*/ 0, 0, 0, /*behParam*/ 0x000B0000, /*beh*/ bhvWarpPipe), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 351, 6800, -3900, /*angle*/ 0, 180, 0, /*behParam*/ 0x000C0000, /*beh*/ bhvDeathWarp), - WARP_NODE(/*id*/ 0x0A, /*destLevel*/ LEVEL_BITS, /*destArea*/ 0x01, /*destNode*/ 0x0A, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0x0B, /*destLevel*/ LEVEL_BOWSER_3, /*destArea*/ 0x01, /*destNode*/ 0x0A, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0x0C, /*destLevel*/ LEVEL_BITS, /*destArea*/ 0x01, /*destNode*/ 0x0C, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0xF1, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x02, /*destNode*/ 0x6B, /*flags*/ WARP_NO_CHECKPOINT), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ -7039, -3812, 4, /*angle*/ 0, 90, 0, /*bhvParam*/ BPARAM2(WARP_NODE_0A), /*bhv*/ bhvAirborneWarp), + OBJECT(/*model*/ MODEL_BITS_WARP_PIPE, /*pos*/ 351, 6652, -6030, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(WARP_NODE_0B), /*bhv*/ bhvWarpPipe), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 351, 6800, -3900, /*angle*/ 0, 180, 0, /*bhvParam*/ BPARAM2(WARP_NODE_0C), /*bhv*/ bhvDeathWarp), + WARP_NODE(/*id*/ WARP_NODE_0A, /*destLevel*/ LEVEL_BITS, /*destArea*/ 1, /*destNode*/ WARP_NODE_0A, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_0B, /*destLevel*/ LEVEL_BOWSER_3, /*destArea*/ 1, /*destNode*/ WARP_NODE_0A, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_0C, /*destLevel*/ LEVEL_BITS, /*destArea*/ 1, /*destNode*/ WARP_NODE_0C, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_DEATH, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 2, /*destNode*/ WARP_NODE_6B, /*flags*/ WARP_NO_CHECKPOINT), JUMP_LINK(script_func_local_1), JUMP_LINK(script_func_local_2), TERRAIN(/*terrainData*/ bits_seg7_collision_level), diff --git a/levels/bob/areas/1/geo.inc.c b/levels/bob/areas/1/geo.inc.c index c7c6fc20..a6d1f8dc 100644 --- a/levels/bob/areas/1/geo.inc.c +++ b/levels/bob/areas/1/geo.inc.c @@ -1,35 +1,35 @@ // 0x0E000488 const GeoLayout bob_geo_000488[] = { - GEO_NODE_SCREEN_AREA(10, SCREEN_WIDTH/2, SCREEN_HEIGHT/2, SCREEN_WIDTH/2, SCREEN_HEIGHT/2), - GEO_OPEN_NODE(), - GEO_ZBUFFER(0), - GEO_OPEN_NODE(), - GEO_NODE_ORTHO(100), - GEO_OPEN_NODE(), - GEO_BACKGROUND(BACKGROUND_OCEAN_SKY, geo_skybox_main), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ZBUFFER(1), - GEO_OPEN_NODE(), - GEO_CAMERA_FRUSTUM_WITH_FUNC(45, 100, 30000, geo_camera_fov), - GEO_OPEN_NODE(), - GEO_CAMERA(1, 0, 2000, 6000, 3072, 0, -4608, geo_camera_main), + GEO_NODE_SCREEN_AREA(10, SCREEN_WIDTH/2, SCREEN_HEIGHT/2, SCREEN_WIDTH/2, SCREEN_HEIGHT/2), + GEO_OPEN_NODE(), + GEO_ZBUFFER(0), + GEO_OPEN_NODE(), + GEO_NODE_ORTHO(100), GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bob_seg7_dl_07004390), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bob_seg7_dl_07009D80), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT_DECAL, bob_seg7_dl_0700A470), - GEO_DISPLAY_LIST(LAYER_ALPHA, bob_seg7_dl_0700A920), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bob_seg7_dl_0700DD18), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bob_seg7_dl_0700E338), - GEO_RENDER_OBJ(), - GEO_ASM(0, geo_envfx_main), + GEO_BACKGROUND(BACKGROUND_OCEAN_SKY, geo_skybox_main), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ZBUFFER(0), - GEO_OPEN_NODE(), - GEO_ASM(0, geo_cannon_circle_base), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CLOSE_NODE(), + GEO_ZBUFFER(1), + GEO_OPEN_NODE(), + GEO_CAMERA_FRUSTUM_WITH_FUNC(45, 100, 30000, geo_camera_fov), + GEO_OPEN_NODE(), + GEO_CAMERA(1, 0, 2000, 6000, 3072, 0, -4608, geo_camera_main), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bob_seg7_dl_07004390), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bob_seg7_dl_07009D80), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT_DECAL, bob_seg7_dl_0700A470), + GEO_DISPLAY_LIST(LAYER_ALPHA, bob_seg7_dl_0700A920), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bob_seg7_dl_0700DD18), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bob_seg7_dl_0700E338), + GEO_RENDER_OBJ(), + GEO_ASM(0, geo_envfx_main), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ZBUFFER(0), + GEO_OPEN_NODE(), + GEO_ASM(0, geo_cannon_circle_base), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bob/areas/1/macro.inc.c b/levels/bob/areas/1/macro.inc.c index e7127c57..c0a0d0d5 100644 --- a/levels/bob/areas/1/macro.inc.c +++ b/levels/bob/areas/1/macro.inc.c @@ -1,92 +1,92 @@ // 0x0701104C - 0x070113BE const MacroObject bob_seg7_macro_objs[] = { - MACRO_OBJECT(/*preset*/ macro_chain_chomp, /*yaw*/ 0, /*pos*/ 260, 735, 1920), - MACRO_OBJECT(/*preset*/ macro_breakable_box_no_coins, /*yaw*/ 0, /*pos*/ -3979, 0, 6827), - MACRO_OBJECT(/*preset*/ macro_goomba, /*yaw*/ 0, /*pos*/ -2713, 152, 5778), - MACRO_OBJECT(/*preset*/ macro_goomba, /*yaw*/ 0, /*pos*/ -342, 400, 5433), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_water_bomb_spawner, /*yaw*/ 0, /*pos*/ 3620, 4000, 4800, /*behParam*/ 15), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_water_bomb_spawner, /*yaw*/ 0, /*pos*/ -5141, 3764, -743, /*behParam*/ 25), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_water_bomb_spawner, /*yaw*/ 0, /*pos*/ -4208, 3769, -2036, /*behParam*/ 10), - MACRO_OBJECT(/*preset*/ macro_water_bomb_cannon, /*yaw*/ 315, /*pos*/ 1388, 2918, -2383), - MACRO_OBJECT(/*preset*/ macro_wooden_post, /*yaw*/ 0, /*pos*/ -6500, 768, 1800), - MACRO_OBJECT(/*preset*/ macro_wooden_post, /*yaw*/ 0, /*pos*/ -5500, 768, 1800), - MACRO_OBJECT(/*preset*/ macro_wooden_post, /*yaw*/ 0, /*pos*/ -6500, 768, 3000), - MACRO_OBJECT(/*preset*/ macro_wooden_post, /*yaw*/ 0, /*pos*/ -5500, 768, 3000), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 270, /*pos*/ -4000, 0, 6050, /*behParam*/ DIALOG_015), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 0, /*pos*/ 1230, 768, 3258, /*behParam*/ DIALOG_008), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_cannon_closed, /*yaw*/ 0, /*pos*/ -5018, 1332, -3533, /*behParam*/ 0x00), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_cannon_closed, /*yaw*/ 0, /*pos*/ 6349, 2080, -7066, /*behParam*/ 0xC0), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_cannon_closed, /*yaw*/ 0, /*pos*/ 4243, 3071, -2451, /*behParam*/ 0xC0), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_cannon_closed, /*yaw*/ 0, /*pos*/ 4352, 3072, 1229, /*behParam*/ 0x80), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_cannon_closed, /*yaw*/ 0, /*pos*/ 5376, 1537, 4610, /*behParam*/ 0x40), - MACRO_OBJECT(/*preset*/ macro_bobomb, /*yaw*/ 0, /*pos*/ -3080, 0, -5200), - MACRO_OBJECT(/*preset*/ macro_bobomb, /*yaw*/ 0, /*pos*/ -3688, 885, -3813), - MACRO_OBJECT(/*preset*/ macro_bobomb, /*yaw*/ 0, /*pos*/ -4629, 1024, -1772), - MACRO_OBJECT(/*preset*/ macro_bobomb, /*yaw*/ 0, /*pos*/ -3480, 891, -2120), - MACRO_OBJECT(/*preset*/ macro_bobomb, /*yaw*/ 0, /*pos*/ -3800, 1024, -460), - MACRO_OBJECT(/*preset*/ macro_bobomb, /*yaw*/ 0, /*pos*/ 6888, 2002, -5608), - MACRO_OBJECT(/*preset*/ macro_recovery_heart, /*yaw*/ 0, /*pos*/ 3603, 3659, -7070), - MACRO_OBJECT(/*preset*/ macro_coin_ring_horizontal, /*yaw*/ 0, /*pos*/ -6060, 1060, -5340), - MACRO_OBJECT(/*preset*/ macro_coin_line_horizontal, /*yaw*/ 90, /*pos*/ -129, 0, 5668), - MACRO_OBJECT(/*preset*/ macro_coin_line_horizontal, /*yaw*/ 75, /*pos*/ 1851, 2917, -2234), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -5500, 768, 2400), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -6500, 768, 2400), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 1135, 1920, -7161), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 250, 1000, 1920), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 1600, 980, 4440), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -2755, 0, -4083), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 4934, 1352, 861), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 4100, 3672, 1629), - MACRO_OBJECT(/*preset*/ macro_box_wing_cap, /*yaw*/ 0, /*pos*/ -6710, 1300, -2170), - MACRO_OBJECT(/*preset*/ macro_breakable_box_small, /*yaw*/ 0, /*pos*/ -3740, 0, 6180), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 270, /*pos*/ -4000, 0, 6300, /*behParam*/ DIALOG_095), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_hidden_1up, /*yaw*/ 0, /*pos*/ -6060, 1060, -5340, /*behParam*/ 4), - MACRO_OBJECT(/*preset*/ macro_hidden_1up_trigger, /*yaw*/ 0, /*pos*/ -5760, 1060, -5340), - MACRO_OBJECT(/*preset*/ macro_hidden_1up_trigger, /*yaw*/ 0, /*pos*/ -6360, 1060, -5340), - MACRO_OBJECT(/*preset*/ macro_hidden_1up_trigger, /*yaw*/ 0, /*pos*/ -6060, 1060, -5640), - MACRO_OBJECT(/*preset*/ macro_hidden_1up_trigger, /*yaw*/ 0, /*pos*/ -6060, 1040, -5040), - MACRO_OBJECT(/*preset*/ macro_box_wing_cap, /*yaw*/ 0, /*pos*/ 3789, 3340, 1818), - MACRO_OBJECT(/*preset*/ macro_bobomb, /*yaw*/ 0, /*pos*/ 2350, 757, 3700), - MACRO_OBJECT(/*preset*/ macro_bobomb, /*yaw*/ 0, /*pos*/ -1750, 0, -2800), - MACRO_OBJECT(/*preset*/ macro_bobomb, /*yaw*/ 0, /*pos*/ -1400, 0, -950), - MACRO_OBJECT(/*preset*/ macro_bobomb, /*yaw*/ 0, /*pos*/ -2650, 0, 1750), - MACRO_OBJECT(/*preset*/ macro_bobomb, /*yaw*/ 0, /*pos*/ -1900, 0, 3450), - MACRO_OBJECT(/*preset*/ macro_1up, /*yaw*/ 0, /*pos*/ -2531, 0, -4201), - MACRO_OBJECT(/*preset*/ macro_hidden_1up_in_pole, /*yaw*/ 0, /*pos*/ 5444, 1400, 6016), - MACRO_OBJECT(/*preset*/ macro_goomba_triplet_spawner, /*yaw*/ 0, /*pos*/ 3640, 768, 6280), - MACRO_OBJECT(/*preset*/ macro_goomba_triplet_spawner, /*yaw*/ 0, /*pos*/ 6060, 877, 2000), - MACRO_OBJECT(/*preset*/ macro_goomba_triplet_spawner, /*yaw*/ 0, /*pos*/ -6050, 768, 1250), - MACRO_OBJECT(/*preset*/ macro_box_wing_cap, /*yaw*/ 0, /*pos*/ 400, 350, 6500), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 270, /*pos*/ 66, 0, 6977, /*behParam*/ DIALOG_113), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 0, /*pos*/ 3394, 3072, 1846, /*behParam*/ DIALOG_064), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 270, /*pos*/ -3110, 104, 5064, /*behParam*/ DIALOG_035), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 0, /*pos*/ 6860, 2041, -6640, /*behParam*/ DIALOG_074), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 0, /*pos*/ -6020, 768, 2957, /*behParam*/ DIALOG_104), - MACRO_OBJECT(/*preset*/ macro_coin_ring_vertical, /*yaw*/ 90, /*pos*/ -1506, 5317, 1250), - MACRO_OBJECT(/*preset*/ macro_hidden_star_trigger, /*yaw*/ 0, /*pos*/ -1506, 5517, 1250), - MACRO_OBJECT(/*preset*/ macro_breakable_box_no_coins, /*yaw*/ 0, /*pos*/ 7157, 2027, -6714), - MACRO_OBJECT(/*preset*/ macro_coin_ring_vertical, /*yaw*/ 90, /*pos*/ 1000, 3400, 1250), - MACRO_OBJECT(/*preset*/ macro_coin_ring_vertical, /*yaw*/ 90, /*pos*/ 2000, 3400, 1250), - MACRO_OBJECT(/*preset*/ macro_coin_ring_vertical, /*yaw*/ 90, /*pos*/ 3000, 3400, 1250), - MACRO_OBJECT(/*preset*/ macro_hidden_star_trigger, /*yaw*/ 0, /*pos*/ 1000, 3600, 1250), - MACRO_OBJECT(/*preset*/ macro_hidden_star_trigger, /*yaw*/ 0, /*pos*/ 2000, 3600, 1250), - MACRO_OBJECT(/*preset*/ macro_hidden_star_trigger, /*yaw*/ 0, /*pos*/ 3000, 3600, 1250), - MACRO_OBJECT(/*preset*/ macro_bobomb_still, /*yaw*/ 0, /*pos*/ 1127, 2897, -2495), - MACRO_OBJECT(/*preset*/ macro_coin_line_horizontal, /*yaw*/ 120, /*pos*/ 4836, 3079, -2707), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 45, /*pos*/ -3530, 1415, 430, /*behParam*/ DIALOG_050), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 0, /*pos*/ 5053, 3073, 2180, /*behParam*/ DIALOG_053), - MACRO_OBJECT(/*preset*/ macro_yellow_coin, /*yaw*/ 0, /*pos*/ -1506, 5517, 1250), - MACRO_OBJECT(/*preset*/ macro_yellow_coin, /*yaw*/ 0, /*pos*/ 1000, 3600, 1250), - MACRO_OBJECT(/*preset*/ macro_yellow_coin, /*yaw*/ 0, /*pos*/ 2000, 3600, 1250), - MACRO_OBJECT(/*preset*/ macro_yellow_coin, /*yaw*/ 0, /*pos*/ 3000, 3600, 1250), - MACRO_OBJECT(/*preset*/ macro_hidden_star_trigger, /*yaw*/ 0, /*pos*/ -300, 4200, 1250), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 270, /*pos*/ -2224, 990, -4359, /*behParam*/ DIALOG_039), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 60, /*pos*/ 3911, 3529, -7081, /*behParam*/ DIALOG_112), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 0, /*pos*/ -7000, 1024, -2099, /*behParam*/ DIALOG_032), - MACRO_OBJECT(/*preset*/ macro_breakable_box_three_coins, /*yaw*/ 0, /*pos*/ -3979, 0, 6627), - MACRO_OBJECT(/*preset*/ macro_box_star_3, /*yaw*/ 0, /*pos*/ 5540, 3350, 1200), - MACRO_OBJECT(/*preset*/ macro_coin_ring_vertical, /*yaw*/ 90, /*pos*/ -300, 4000, 1250), - MACRO_OBJECT(/*preset*/ macro_yellow_coin, /*yaw*/ 0, /*pos*/ -300, 4200, 1250), - MACRO_OBJECT(/*preset*/ macro_breakable_box_small, /*yaw*/ 0, /*pos*/ -6800, 1024, 40), + MACRO_OBJECT (/*preset*/ macro_chain_chomp, /*yaw*/ 0, /*pos*/ 260, 735, 1920), + MACRO_OBJECT (/*preset*/ macro_breakable_box_no_coins, /*yaw*/ 0, /*pos*/ -3979, 0, 6827), + MACRO_OBJECT (/*preset*/ macro_goomba, /*yaw*/ 0, /*pos*/ -2713, 152, 5778), + MACRO_OBJECT (/*preset*/ macro_goomba, /*yaw*/ 0, /*pos*/ -342, 400, 5433), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_water_bomb_spawner, /*yaw*/ 0, /*pos*/ 3620, 4000, 4800, /*bhvParam*/ 15), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_water_bomb_spawner, /*yaw*/ 0, /*pos*/ -5141, 3764, -743, /*bhvParam*/ 25), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_water_bomb_spawner, /*yaw*/ 0, /*pos*/ -4208, 3769, -2036, /*bhvParam*/ 10), + MACRO_OBJECT (/*preset*/ macro_water_bomb_cannon_2, /*yaw*/ 315, /*pos*/ 1388, 2918, -2383), + MACRO_OBJECT (/*preset*/ macro_wooden_post_1, /*yaw*/ 0, /*pos*/ -6500, 768, 1800), + MACRO_OBJECT (/*preset*/ macro_wooden_post_1, /*yaw*/ 0, /*pos*/ -5500, 768, 1800), + MACRO_OBJECT (/*preset*/ macro_wooden_post_1, /*yaw*/ 0, /*pos*/ -6500, 768, 3000), + MACRO_OBJECT (/*preset*/ macro_wooden_post_1, /*yaw*/ 0, /*pos*/ -5500, 768, 3000), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 270, /*pos*/ -4000, 0, 6050, /*bhvParam*/ DIALOG_015), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 0, /*pos*/ 1230, 768, 3258, /*bhvParam*/ DIALOG_008), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_cannon_closed, /*yaw*/ 0, /*pos*/ -5018, 1332, -3533, /*bhvParam*/ 0x00), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_cannon_closed, /*yaw*/ 0, /*pos*/ 6349, 2080, -7066, /*bhvParam*/ 0xC0), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_cannon_closed, /*yaw*/ 0, /*pos*/ 4243, 3071, -2451, /*bhvParam*/ 0xC0), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_cannon_closed, /*yaw*/ 0, /*pos*/ 4352, 3072, 1229, /*bhvParam*/ 0x80), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_cannon_closed, /*yaw*/ 0, /*pos*/ 5376, 1537, 4610, /*bhvParam*/ 0x40), + MACRO_OBJECT (/*preset*/ macro_bobomb, /*yaw*/ 0, /*pos*/ -3080, 0, -5200), + MACRO_OBJECT (/*preset*/ macro_bobomb, /*yaw*/ 0, /*pos*/ -3688, 885, -3813), + MACRO_OBJECT (/*preset*/ macro_bobomb, /*yaw*/ 0, /*pos*/ -4629, 1024, -1772), + MACRO_OBJECT (/*preset*/ macro_bobomb, /*yaw*/ 0, /*pos*/ -3480, 891, -2120), + MACRO_OBJECT (/*preset*/ macro_bobomb, /*yaw*/ 0, /*pos*/ -3800, 1024, -460), + MACRO_OBJECT (/*preset*/ macro_bobomb, /*yaw*/ 0, /*pos*/ 6888, 2002, -5608), + MACRO_OBJECT (/*preset*/ macro_recovery_heart, /*yaw*/ 0, /*pos*/ 3603, 3659, -7070), + MACRO_OBJECT (/*preset*/ macro_coin_ring_horizontal, /*yaw*/ 0, /*pos*/ -6060, 1060, -5340), + MACRO_OBJECT (/*preset*/ macro_coin_line_horizontal, /*yaw*/ 90, /*pos*/ -129, 0, 5668), + MACRO_OBJECT (/*preset*/ macro_coin_line_horizontal, /*yaw*/ 75, /*pos*/ 1851, 2917, -2234), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -5500, 768, 2400), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -6500, 768, 2400), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 1135, 1920, -7161), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 250, 1000, 1920), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 1600, 980, 4440), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -2755, 0, -4083), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 4934, 1352, 861), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 4100, 3672, 1629), + MACRO_OBJECT (/*preset*/ macro_box_wing_cap, /*yaw*/ 0, /*pos*/ -6710, 1300, -2170), + MACRO_OBJECT (/*preset*/ macro_breakable_box_small, /*yaw*/ 0, /*pos*/ -3740, 0, 6180), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 270, /*pos*/ -4000, 0, 6300, /*bhvParam*/ DIALOG_095), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_hidden_1up, /*yaw*/ 0, /*pos*/ -6060, 1060, -5340, /*bhvParam*/ 4), + MACRO_OBJECT (/*preset*/ macro_hidden_1up_trigger, /*yaw*/ 0, /*pos*/ -5760, 1060, -5340), + MACRO_OBJECT (/*preset*/ macro_hidden_1up_trigger, /*yaw*/ 0, /*pos*/ -6360, 1060, -5340), + MACRO_OBJECT (/*preset*/ macro_hidden_1up_trigger, /*yaw*/ 0, /*pos*/ -6060, 1060, -5640), + MACRO_OBJECT (/*preset*/ macro_hidden_1up_trigger, /*yaw*/ 0, /*pos*/ -6060, 1040, -5040), + MACRO_OBJECT (/*preset*/ macro_box_wing_cap, /*yaw*/ 0, /*pos*/ 3789, 3340, 1818), + MACRO_OBJECT (/*preset*/ macro_bobomb, /*yaw*/ 0, /*pos*/ 2350, 757, 3700), + MACRO_OBJECT (/*preset*/ macro_bobomb, /*yaw*/ 0, /*pos*/ -1750, 0, -2800), + MACRO_OBJECT (/*preset*/ macro_bobomb, /*yaw*/ 0, /*pos*/ -1400, 0, -950), + MACRO_OBJECT (/*preset*/ macro_bobomb, /*yaw*/ 0, /*pos*/ -2650, 0, 1750), + MACRO_OBJECT (/*preset*/ macro_bobomb, /*yaw*/ 0, /*pos*/ -1900, 0, 3450), + MACRO_OBJECT (/*preset*/ macro_1up, /*yaw*/ 0, /*pos*/ -2531, 0, -4201), + MACRO_OBJECT (/*preset*/ macro_hidden_1up_in_pole, /*yaw*/ 0, /*pos*/ 5444, 1400, 6016), + MACRO_OBJECT (/*preset*/ macro_goomba_triplet_spawner, /*yaw*/ 0, /*pos*/ 3640, 768, 6280), + MACRO_OBJECT (/*preset*/ macro_goomba_triplet_spawner, /*yaw*/ 0, /*pos*/ 6060, 877, 2000), + MACRO_OBJECT (/*preset*/ macro_goomba_triplet_spawner, /*yaw*/ 0, /*pos*/ -6050, 768, 1250), + MACRO_OBJECT (/*preset*/ macro_box_wing_cap, /*yaw*/ 0, /*pos*/ 400, 350, 6500), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 270, /*pos*/ 66, 0, 6977, /*bhvParam*/ DIALOG_113), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 0, /*pos*/ 3394, 3072, 1846, /*bhvParam*/ DIALOG_064), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 270, /*pos*/ -3110, 104, 5064, /*bhvParam*/ DIALOG_035), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 0, /*pos*/ 6860, 2041, -6640, /*bhvParam*/ DIALOG_074), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 0, /*pos*/ -6020, 768, 2957, /*bhvParam*/ DIALOG_104), + MACRO_OBJECT (/*preset*/ macro_coin_ring_vertical_flying, /*yaw*/ 90, /*pos*/ -1506, 5317, 1250), + MACRO_OBJECT (/*preset*/ macro_hidden_star_trigger, /*yaw*/ 0, /*pos*/ -1506, 5517, 1250), + MACRO_OBJECT (/*preset*/ macro_breakable_box_no_coins, /*yaw*/ 0, /*pos*/ 7157, 2027, -6714), + MACRO_OBJECT (/*preset*/ macro_coin_ring_vertical_flying, /*yaw*/ 90, /*pos*/ 1000, 3400, 1250), + MACRO_OBJECT (/*preset*/ macro_coin_ring_vertical_flying, /*yaw*/ 90, /*pos*/ 2000, 3400, 1250), + MACRO_OBJECT (/*preset*/ macro_coin_ring_vertical_flying, /*yaw*/ 90, /*pos*/ 3000, 3400, 1250), + MACRO_OBJECT (/*preset*/ macro_hidden_star_trigger, /*yaw*/ 0, /*pos*/ 1000, 3600, 1250), + MACRO_OBJECT (/*preset*/ macro_hidden_star_trigger, /*yaw*/ 0, /*pos*/ 2000, 3600, 1250), + MACRO_OBJECT (/*preset*/ macro_hidden_star_trigger, /*yaw*/ 0, /*pos*/ 3000, 3600, 1250), + MACRO_OBJECT (/*preset*/ macro_bobomb_stationary, /*yaw*/ 0, /*pos*/ 1127, 2897, -2495), + MACRO_OBJECT (/*preset*/ macro_coin_line_horizontal, /*yaw*/ 120, /*pos*/ 4836, 3079, -2707), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 45, /*pos*/ -3530, 1415, 430, /*bhvParam*/ DIALOG_050), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 0, /*pos*/ 5053, 3073, 2180, /*bhvParam*/ DIALOG_053), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_1, /*yaw*/ 0, /*pos*/ -1506, 5517, 1250), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_1, /*yaw*/ 0, /*pos*/ 1000, 3600, 1250), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_1, /*yaw*/ 0, /*pos*/ 2000, 3600, 1250), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_1, /*yaw*/ 0, /*pos*/ 3000, 3600, 1250), + MACRO_OBJECT (/*preset*/ macro_hidden_star_trigger, /*yaw*/ 0, /*pos*/ -300, 4200, 1250), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 270, /*pos*/ -2224, 990, -4359, /*bhvParam*/ DIALOG_039), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 60, /*pos*/ 3911, 3529, -7081, /*bhvParam*/ DIALOG_112), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 0, /*pos*/ -7000, 1024, -2099, /*bhvParam*/ DIALOG_032), + MACRO_OBJECT (/*preset*/ macro_breakable_box_three_coins, /*yaw*/ 0, /*pos*/ -3979, 0, 6627), + MACRO_OBJECT (/*preset*/ macro_box_star_act_3, /*yaw*/ 0, /*pos*/ 5540, 3350, 1200), + MACRO_OBJECT (/*preset*/ macro_coin_ring_vertical_flying, /*yaw*/ 90, /*pos*/ -300, 4000, 1250), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_1, /*yaw*/ 0, /*pos*/ -300, 4200, 1250), + MACRO_OBJECT (/*preset*/ macro_breakable_box_small, /*yaw*/ 0, /*pos*/ -6800, 1024, 40), MACRO_OBJECT_END(), }; diff --git a/levels/bob/chain_chomp_gate/geo.inc.c b/levels/bob/chain_chomp_gate/geo.inc.c index e6864f09..c786d0ad 100644 --- a/levels/bob/chain_chomp_gate/geo.inc.c +++ b/levels/bob/chain_chomp_gate/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000440 const GeoLayout bob_geo_000440[] = { - GEO_CULLING_RADIUS(1000), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, bob_seg7_dl_0700E458), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(1000), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, bob_seg7_dl_0700E458), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bob/grate_door/geo.inc.c b/levels/bob/grate_door/geo.inc.c index 447fbce8..42dfbf41 100644 --- a/levels/bob/grate_door/geo.inc.c +++ b/levels/bob/grate_door/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000470 const GeoLayout bob_geo_000470[] = { - GEO_CULLING_RADIUS(800), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, bob_seg7_dl_0700E8A0), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(800), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, bob_seg7_dl_0700E8A0), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bob/level.yaml b/levels/bob/level.yaml index 38a01def..fb26f569 100644 --- a/levels/bob/level.yaml +++ b/levels/bob/level.yaml @@ -1,6 +1,6 @@ -# Bob-Omb Battlefield +# Bob-omb Battlefield short-name: bob -full-name: Bob-Omb Battlefield +full-name: Bob-omb Battlefield texture-file: ["/texture.inc.c"] area-count: 1 objects: [chain_chomp_gate, grate_door, seesaw_platform] diff --git a/levels/bob/leveldata.c b/levels/bob/leveldata.c index 3c0befd1..9cec6310 100644 --- a/levels/bob/leveldata.c +++ b/levels/bob/leveldata.c @@ -3,8 +3,8 @@ #include "surface_terrains.h" #include "moving_texture_macros.h" #include "level_misc_macros.h" -#include "macro_preset_names.h" -#include "special_preset_names.h" +#include "macro_presets.h" +#include "special_presets.h" #include "textures.h" #include "dialog_ids.h" diff --git a/levels/bob/script.c b/levels/bob/script.c index ce7bf54c..2575812a 100644 --- a/levels/bob/script.c +++ b/levels/bob/script.c @@ -17,55 +17,55 @@ #include "levels/bob/header.h" static const LevelScript script_func_local_1[] = { - OBJECT(/*model*/ MODEL_BOB_CHAIN_CHOMP_GATE, /*pos*/ 1456, 768, 446, /*angle*/ 0, 326, 0, /*behParam*/ 0x00000000, /*beh*/ bhvChainChompGate), - OBJECT(/*model*/ MODEL_BOB_SEESAW_PLATFORM, /*pos*/ -2303, 717, 1024, /*angle*/ 0, 45, 0, /*behParam*/ 0x00030000, /*beh*/ bhvSeesawPlatform), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -2050, 0, -3069, /*angle*/ 0, 25, 0, /*behParam*/ 0x00000000, /*beh*/ bhvOpenableGrill), - OBJECT(/*model*/ MODEL_PURPLE_SWITCH, /*pos*/ -2283, 0, -3682, /*angle*/ 0, 27, 0, /*behParam*/ 0x00000000, /*beh*/ bhvFloorSwitchGrills), - OBJECT(/*model*/ MODEL_CHECKERBOARD_PLATFORM, /*pos*/ 1612, 300, 4611, /*angle*/ 0, 0, 0, /*behParam*/ 0x00280000, /*beh*/ bhvCheckerboardElevatorGroup), + OBJECT(/*model*/ MODEL_BOB_CHAIN_CHOMP_GATE, /*pos*/ 1456, 768, 446, /*angle*/ 0, 326, 0, /*bhvParam*/ 0, /*bhv*/ bhvChainChompGate), + OBJECT(/*model*/ MODEL_BOB_SEESAW_PLATFORM, /*pos*/ -2303, 717, 1024, /*angle*/ 0, 45, 0, /*bhvParam*/ BPARAM2(0x03), /*bhv*/ bhvSeesawPlatform), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ -2050, 0, -3069, /*angle*/ 0, 25, 0, /*bhvParam*/ BPARAM2(OPENABLE_GRILL_BP_BOB), /*bhv*/ bhvOpenableGrill), + OBJECT(/*model*/ MODEL_PURPLE_SWITCH, /*pos*/ -2283, 0, -3682, /*angle*/ 0, 27, 0, /*bhvParam*/ 0, /*bhv*/ bhvFloorSwitchGrills), + OBJECT(/*model*/ MODEL_CHECKERBOARD_PLATFORM, /*pos*/ 1612, 300, 4611, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(0) | BPARAM2(40), /*bhv*/ bhvCheckerboardElevatorGroup), RETURN(), }; static const LevelScript script_func_local_2[] = { - OBJECT_WITH_ACTS(/*model*/ MODEL_NONE, /*pos*/ 1535, 3840, -5561, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvBobBowlingBallSpawner, /*acts*/ ACT_1 | ACT_2), - OBJECT_WITH_ACTS(/*model*/ MODEL_NONE, /*pos*/ 1535, 3840, -5561, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvTtmBowlingBallSpawner, /*acts*/ ACT_3 | ACT_4 | ACT_5 | ACT_6), - OBJECT_WITH_ACTS(/*model*/ MODEL_NONE, /*pos*/ 524, 2825, -5400, /*angle*/ 0, 0, 0, /*behParam*/ 0x00020000, /*beh*/ bhvBobBowlingBallSpawner, /*acts*/ ACT_1 | ACT_2), - OBJECT_WITH_ACTS(/*model*/ MODEL_NONE, /*pos*/ 524, 2825, -5400, /*angle*/ 0, 0, 0, /*behParam*/ 0x00020000, /*beh*/ bhvTtmBowlingBallSpawner, /*acts*/ ACT_3 | ACT_4 | ACT_5 | ACT_6), - OBJECT (/*model*/ MODEL_BOWLING_BALL, /*pos*/ -993, 886, -3565, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvPitBowlingBall), - OBJECT (/*model*/ MODEL_BOWLING_BALL, /*pos*/ -785, 886, -4301, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvPitBowlingBall), - OBJECT_WITH_ACTS(/*model*/ MODEL_BOWLING_BALL, /*pos*/ -93, 886, -3414, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvPitBowlingBall, /*acts*/ ACT_2 | ACT_3 | ACT_4 | ACT_5 | ACT_6), - OBJECT_WITH_ACTS(/*model*/ MODEL_BOBOMB_BUDDY, /*pos*/ -5723, 140, 6017, /*angle*/ 0, 0, 0, /*behParam*/ DIALOG_002 << 16, /*beh*/ bhvBobombBuddy, /*acts*/ ACT_1), - OBJECT_WITH_ACTS(/*model*/ MODEL_BOBOMB_BUDDY, /*pos*/ -6250, 0, 6680, /*angle*/ 0, 0, 0, /*behParam*/ DIALOG_001 << 16, /*beh*/ bhvBobombBuddy, /*acts*/ ACT_1), - OBJECT_WITH_ACTS(/*model*/ MODEL_BOBOMB_BUDDY, /*pos*/ -5723, 140, 6017, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvBobombBuddyOpensCannon, /*acts*/ ACT_2 | ACT_3 | ACT_4 | ACT_5 | ACT_6), - OBJECT_WITH_ACTS(/*model*/ MODEL_BOBOMB_BUDDY, /*pos*/ -6250, 0, 6680, /*angle*/ 0, 0, 0, /*behParam*/ DIALOG_003 << 16, /*beh*/ bhvBobombBuddy, /*acts*/ ACT_2 | ACT_3 | ACT_4 | ACT_5 | ACT_6), - OBJECT_WITH_ACTS(/*model*/ MODEL_CANNON_BASE, /*pos*/ -5694, 128, 5600, /*angle*/ 0, 135, 0, /*behParam*/ 0x00010000, /*beh*/ bhvWaterBombCannon, /*acts*/ ACT_1), - OBJECT_WITH_ACTS(/*model*/ MODEL_DL_CANNON_LID, /*pos*/ -5694, 128, 5600, /*angle*/ 0, 180, 0, /*behParam*/ 0x00000000, /*beh*/ bhvCannonClosed, /*acts*/ ACT_2 | ACT_3 | ACT_4 | ACT_5 | ACT_6), - OBJECT_WITH_ACTS(/*model*/ MODEL_NONE, /*pos*/ 3304, 4242, -4603, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvKoopaRaceEndpoint, /*acts*/ ACT_2), - OBJECT_WITH_ACTS(/*model*/ MODEL_KOOPA_WITH_SHELL, /*pos*/ 3400, 770, 6500, /*angle*/ 0, 0, 0, /*behParam*/ 0x00010000, /*beh*/ bhvKoopa, /*acts*/ ACT_3 | ACT_4 | ACT_5 | ACT_6), + OBJECT_WITH_ACTS(/*model*/ MODEL_NONE, /*pos*/ 1535, 3840, -5561, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(BBALL_BP_STYPE_BOB_UPPER), /*bhv*/ bhvBoBBowlingBallSpawner, /*acts*/ ACT_1 | ACT_2), + OBJECT_WITH_ACTS(/*model*/ MODEL_NONE, /*pos*/ 1535, 3840, -5561, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(BBALL_BP_STYPE_BOB_UPPER), /*bhv*/ bhvTTMBowlingBallSpawner, /*acts*/ ACT_3 | ACT_4 | ACT_5 | ACT_6), + OBJECT_WITH_ACTS(/*model*/ MODEL_NONE, /*pos*/ 524, 2825, -5400, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(BBALL_BP_STYPE_BOB_LOWER), /*bhv*/ bhvBoBBowlingBallSpawner, /*acts*/ ACT_1 | ACT_2), + OBJECT_WITH_ACTS(/*model*/ MODEL_NONE, /*pos*/ 524, 2825, -5400, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(BBALL_BP_STYPE_BOB_LOWER), /*bhv*/ bhvTTMBowlingBallSpawner, /*acts*/ ACT_3 | ACT_4 | ACT_5 | ACT_6), + OBJECT (/*model*/ MODEL_BOWLING_BALL, /*pos*/ -993, 886, -3565, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvPitBowlingBall), + OBJECT (/*model*/ MODEL_BOWLING_BALL, /*pos*/ -785, 886, -4301, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvPitBowlingBall), + OBJECT_WITH_ACTS(/*model*/ MODEL_BOWLING_BALL, /*pos*/ -93, 886, -3414, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvPitBowlingBall, /*acts*/ ACT_2 | ACT_3 | ACT_4 | ACT_5 | ACT_6), + OBJECT_WITH_ACTS(/*model*/ MODEL_BOBOMB_BUDDY, /*pos*/ -5723, 140, 6017, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(DIALOG_002), /*bhv*/ bhvBobombBuddy, /*acts*/ ACT_1), + OBJECT_WITH_ACTS(/*model*/ MODEL_BOBOMB_BUDDY, /*pos*/ -6250, 0, 6680, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(DIALOG_001), /*bhv*/ bhvBobombBuddy, /*acts*/ ACT_1), + OBJECT_WITH_ACTS(/*model*/ MODEL_BOBOMB_BUDDY, /*pos*/ -5723, 140, 6017, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvBobombBuddyOpensCannon, /*acts*/ ACT_2 | ACT_3 | ACT_4 | ACT_5 | ACT_6), + OBJECT_WITH_ACTS(/*model*/ MODEL_BOBOMB_BUDDY, /*pos*/ -6250, 0, 6680, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(DIALOG_003), /*bhv*/ bhvBobombBuddy, /*acts*/ ACT_2 | ACT_3 | ACT_4 | ACT_5 | ACT_6), + OBJECT_WITH_ACTS(/*model*/ MODEL_CANNON_BASE, /*pos*/ -5694, 128, 5600, /*angle*/ 0, 135, 0, /*bhvParam*/ BPARAM2(0x01), /*bhv*/ bhvWaterBombCannon, /*acts*/ ACT_1), + OBJECT_WITH_ACTS(/*model*/ MODEL_DL_CANNON_LID, /*pos*/ -5694, 128, 5600, /*angle*/ 0, 180, 0, /*bhvParam*/ BPARAM2(0x00), /*bhv*/ bhvCannonClosed, /*acts*/ ACT_2 | ACT_3 | ACT_4 | ACT_5 | ACT_6), + OBJECT_WITH_ACTS(/*model*/ MODEL_NONE, /*pos*/ 3304, 4242, -4603, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvKoopaRaceEndpoint, /*acts*/ ACT_2), + OBJECT_WITH_ACTS(/*model*/ MODEL_KOOPA_WITH_SHELL, /*pos*/ 3400, 770, 6500, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(KOOPA_BP_NORMAL), /*bhv*/ bhvKoopa, /*acts*/ ACT_3 | ACT_4 | ACT_5 | ACT_6), RETURN(), }; static const LevelScript script_func_local_3[] = { - OBJECT_WITH_ACTS(/*model*/ MODEL_KING_BOBOMB, /*pos*/ 1636, 4242, -5567, /*angle*/ 0, -147, 0, /*behParam*/ 0x00000000, /*beh*/ bhvKingBobomb, /*acts*/ ACT_1), - OBJECT_WITH_ACTS(/*model*/ MODEL_KOOPA_WITH_SHELL, /*pos*/ -4004, 0, 5221, /*angle*/ 0, 0, 0, /*behParam*/ 0x01020000, /*beh*/ bhvKoopa, /*acts*/ ACT_2), - OBJECT_WITH_ACTS(/*model*/ MODEL_NONE, /*pos*/ -6000, 1000, 2400, /*angle*/ 0, 0, 0, /*behParam*/ 0x03000000, /*beh*/ bhvHiddenRedCoinStar, /*acts*/ ALL_ACTS), - OBJECT_WITH_ACTS(/*model*/ MODEL_NONE, /*pos*/ -6600, 1000, 1250, /*angle*/ 0, 0, 0, /*behParam*/ 0x04040000, /*beh*/ bhvHiddenStar, /*acts*/ ALL_ACTS), - OBJECT_WITH_ACTS(/*model*/ MODEL_STAR, /*pos*/ 1550, 1200, 300, /*angle*/ 0, 0, 0, /*behParam*/ 0x05000000, /*beh*/ bhvStar, /*acts*/ ALL_ACTS), + OBJECT_WITH_ACTS(/*model*/ MODEL_KING_BOBOMB, /*pos*/ 1636, 4242, -5567, /*angle*/ 0, -147, 0, /*bhvParam*/ BPARAM1(STAR_INDEX_ACT_1), /*bhv*/ bhvKingBobomb, /*acts*/ ACT_1), + OBJECT_WITH_ACTS(/*model*/ MODEL_KOOPA_WITH_SHELL, /*pos*/ -4004, 0, 5221, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(STAR_INDEX_ACT_2) | BPARAM2(KOOPA_BP_KOOPA_THE_QUICK_BOB), /*bhv*/ bhvKoopa, /*acts*/ ACT_2), + OBJECT_WITH_ACTS(/*model*/ MODEL_NONE, /*pos*/ -6000, 1000, 2400, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(STAR_INDEX_ACT_4), /*bhv*/ bhvHiddenRedCoinStar, /*acts*/ ALL_ACTS), + OBJECT_WITH_ACTS(/*model*/ MODEL_NONE, /*pos*/ -6600, 1000, 1250, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(STAR_INDEX_ACT_5) | BPARAM2(0x04), /*bhv*/ bhvHiddenStar, /*acts*/ ALL_ACTS), + OBJECT_WITH_ACTS(/*model*/ MODEL_STAR, /*pos*/ 1550, 1200, 300, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(STAR_INDEX_ACT_6), /*bhv*/ bhvStar, /*acts*/ ALL_ACTS), RETURN(), }; const LevelScript level_bob_entry[] = { INIT_LEVEL(), - LOAD_MIO0( /*seg*/ 0x07, _bob_segment_7SegmentRomStart, _bob_segment_7SegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x07, _bob_segment_7SegmentRomStart, _bob_segment_7SegmentRomEnd), LOAD_MIO0_TEXTURE(/*seg*/ 0x09, _generic_mio0SegmentRomStart, _generic_mio0SegmentRomEnd), - LOAD_MIO0( /*seg*/ 0x0A, _water_skybox_mio0SegmentRomStart, _water_skybox_mio0SegmentRomEnd), - LOAD_MIO0( /*seg*/ 0x05, _group3_mio0SegmentRomStart, _group3_mio0SegmentRomEnd), - LOAD_RAW( /*seg*/ 0x0C, _group3_geoSegmentRomStart, _group3_geoSegmentRomEnd), - LOAD_MIO0( /*seg*/ 0x06, _group14_mio0SegmentRomStart, _group14_mio0SegmentRomEnd), - LOAD_RAW( /*seg*/ 0x0D, _group14_geoSegmentRomStart, _group14_geoSegmentRomEnd), - LOAD_MIO0( /*seg*/ 0x08, _common0_mio0SegmentRomStart, _common0_mio0SegmentRomEnd), - LOAD_RAW( /*seg*/ 0x0F, _common0_geoSegmentRomStart, _common0_geoSegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x0A, _water_skybox_mio0SegmentRomStart, _water_skybox_mio0SegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x05, _group3_mio0SegmentRomStart, _group3_mio0SegmentRomEnd), + LOAD_RAW (/*seg*/ 0x0C, _group3_geoSegmentRomStart, _group3_geoSegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x06, _group14_mio0SegmentRomStart, _group14_mio0SegmentRomEnd), + LOAD_RAW (/*seg*/ 0x0D, _group14_geoSegmentRomStart, _group14_geoSegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x08, _common0_mio0SegmentRomStart, _common0_mio0SegmentRomEnd), + LOAD_RAW (/*seg*/ 0x0F, _common0_geoSegmentRomStart, _common0_geoSegmentRomEnd), ALLOC_LEVEL_POOL(), - MARIO(/*model*/ MODEL_MARIO, /*behParam*/ 0x00000001, /*beh*/ bhvMario), + MARIO(/*model*/ MODEL_MARIO, /*bhvParam*/ BPARAM4(0x01), /*bhv*/ bhvMario), JUMP_LINK(script_func_global_1), JUMP_LINK(script_func_global_4), JUMP_LINK(script_func_global_15), @@ -78,18 +78,18 @@ const LevelScript level_bob_entry[] = { JUMP_LINK(script_func_local_1), JUMP_LINK(script_func_local_2), JUMP_LINK(script_func_local_3), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -6558, 1000, 6464, /*angle*/ 0, 135, 0, /*behParam*/ 0x000A0000, /*beh*/ bhvSpinAirborneWarp), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 583, 2683, -5387, /*angle*/ 0, -154, 0, /*behParam*/ 0x000B0000, /*beh*/ bhvFadingWarp), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 1680, 3835, -5523, /*angle*/ 0, -153, 0, /*behParam*/ 0x000C0000, /*beh*/ bhvFadingWarp), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -6612, 1024, -3351, /*angle*/ 0, 107, 0, /*behParam*/ 0x000D0000, /*beh*/ bhvFadingWarp), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 1980, 768, 6618, /*angle*/ 0, -151, 0, /*behParam*/ 0x000E0000, /*beh*/ bhvFadingWarp), - WARP_NODE(/*id*/ 0x0A, /*destLevel*/ LEVEL_BOB, /*destArea*/ 0x01, /*destNode*/ 0x0A, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0x0B, /*destLevel*/ LEVEL_BOB, /*destArea*/ 0x01, /*destNode*/ 0x0C, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0x0C, /*destLevel*/ LEVEL_BOB, /*destArea*/ 0x01, /*destNode*/ 0x0B, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0x0D, /*destLevel*/ LEVEL_BOB, /*destArea*/ 0x01, /*destNode*/ 0x0E, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0x0E, /*destLevel*/ LEVEL_BOB, /*destArea*/ 0x01, /*destNode*/ 0x0D, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0xF0, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x01, /*destNode*/ 0x32, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0xF1, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x01, /*destNode*/ 0x64, /*flags*/ WARP_NO_CHECKPOINT), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ -6558, 1000, 6464, /*angle*/ 0, 135, 0, /*bhvParam*/ BPARAM2(WARP_NODE_0A), /*bhv*/ bhvSpinAirborneWarp), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 583, 2683, -5387, /*angle*/ 0, -154, 0, /*bhvParam*/ BPARAM2(WARP_NODE_0B), /*bhv*/ bhvFadingWarp), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 1680, 3835, -5523, /*angle*/ 0, -153, 0, /*bhvParam*/ BPARAM2(WARP_NODE_0C), /*bhv*/ bhvFadingWarp), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ -6612, 1024, -3351, /*angle*/ 0, 107, 0, /*bhvParam*/ BPARAM2(WARP_NODE_0D), /*bhv*/ bhvFadingWarp), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 1980, 768, 6618, /*angle*/ 0, -151, 0, /*bhvParam*/ BPARAM2(WARP_NODE_0E), /*bhv*/ bhvFadingWarp), + WARP_NODE(/*id*/ WARP_NODE_0A, /*destLevel*/ LEVEL_BOB, /*destArea*/ 1, /*destNode*/ WARP_NODE_0A, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_0B, /*destLevel*/ LEVEL_BOB, /*destArea*/ 1, /*destNode*/ WARP_NODE_0C, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_0C, /*destLevel*/ LEVEL_BOB, /*destArea*/ 1, /*destNode*/ WARP_NODE_0B, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_0D, /*destLevel*/ LEVEL_BOB, /*destArea*/ 1, /*destNode*/ WARP_NODE_0E, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_0E, /*destLevel*/ LEVEL_BOB, /*destArea*/ 1, /*destNode*/ WARP_NODE_0D, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_SUCCESS, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 1, /*destNode*/ WARP_NODE_32, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_DEATH, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 1, /*destNode*/ WARP_NODE_64, /*flags*/ WARP_NO_CHECKPOINT), TERRAIN(/*terrainData*/ bob_seg7_collision_level), MACRO_OBJECTS(/*objList*/ bob_seg7_macro_objs), SHOW_DIALOG(/*index*/ 0x00, DIALOG_000), diff --git a/levels/bob/seesaw_platform/geo.inc.c b/levels/bob/seesaw_platform/geo.inc.c index dd59ee12..7d738a36 100644 --- a/levels/bob/seesaw_platform/geo.inc.c +++ b/levels/bob/seesaw_platform/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000458 const GeoLayout bob_geo_000458[] = { - GEO_CULLING_RADIUS(1200), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bob_seg7_dl_0700E768), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(1200), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bob_seg7_dl_0700E768), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bowser_1/areas/1/geo.inc.c b/levels/bowser_1/areas/1/geo.inc.c index f6acd67f..ea430079 100644 --- a/levels/bowser_1/areas/1/geo.inc.c +++ b/levels/bowser_1/areas/1/geo.inc.c @@ -1,26 +1,26 @@ // 0x0E0000D0 const GeoLayout bowser_1_geo_0000D0[] = { - GEO_NODE_SCREEN_AREA(10, SCREEN_WIDTH/2, SCREEN_HEIGHT/2, SCREEN_WIDTH/2, SCREEN_HEIGHT/2), - GEO_OPEN_NODE(), - GEO_ZBUFFER(0), - GEO_OPEN_NODE(), - GEO_NODE_ORTHO(100), - GEO_OPEN_NODE(), - GEO_BACKGROUND(BACKGROUND_GREEN_SKY, geo_skybox_main), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ZBUFFER(1), - GEO_OPEN_NODE(), - GEO_CAMERA_FRUSTUM_WITH_FUNC(45, 100, 12800, geo_camera_fov), - GEO_OPEN_NODE(), - GEO_CAMERA(11, 0, 2000, 6000, 0, 0, 0, geo_camera_main), + GEO_NODE_SCREEN_AREA(10, SCREEN_WIDTH/2, SCREEN_HEIGHT/2, SCREEN_WIDTH/2, SCREEN_HEIGHT/2), + GEO_OPEN_NODE(), + GEO_ZBUFFER(0), + GEO_OPEN_NODE(), + GEO_NODE_ORTHO(100), GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bowser_1_seg7_dl_07002768), - GEO_RENDER_OBJ(), - GEO_ASM(0, geo_envfx_main), + GEO_BACKGROUND(BACKGROUND_GREEN_SKY, geo_skybox_main), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CLOSE_NODE(), + GEO_ZBUFFER(1), + GEO_OPEN_NODE(), + GEO_CAMERA_FRUSTUM_WITH_FUNC(45, 100, 12800, geo_camera_fov), + GEO_OPEN_NODE(), + GEO_CAMERA(11, 0, 2000, 6000, 0, 0, 0, geo_camera_main), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bowser_1_seg7_dl_07002768), + GEO_RENDER_OBJ(), + GEO_ASM(0, geo_envfx_main), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bowser_1/leveldata.c b/levels/bowser_1/leveldata.c index d198f19a..b703740e 100644 --- a/levels/bowser_1/leveldata.c +++ b/levels/bowser_1/leveldata.c @@ -3,8 +3,8 @@ #include "surface_terrains.h" #include "moving_texture_macros.h" #include "level_misc_macros.h" -#include "macro_preset_names.h" -#include "special_preset_names.h" +#include "macro_presets.h" +#include "special_presets.h" #include "textures.h" #include "make_const_nonconst.h" diff --git a/levels/bowser_1/script.c b/levels/bowser_1/script.c index e70de999..db4261d4 100644 --- a/levels/bowser_1/script.c +++ b/levels/bowser_1/script.c @@ -21,17 +21,17 @@ const LevelScript level_bowser_1_entry[] = { LOAD_MIO0(/*seg*/ 0x07, _bowser_1_segment_7SegmentRomStart, _bowser_1_segment_7SegmentRomEnd), LOAD_MIO0(/*seg*/ 0x0A, _bidw_skybox_mio0SegmentRomStart, _bidw_skybox_mio0SegmentRomEnd), LOAD_MIO0(/*seg*/ 0x06, _group12_mio0SegmentRomStart, _group12_mio0SegmentRomEnd), - LOAD_RAW( /*seg*/ 0x0D, _group12_geoSegmentRomStart, _group12_geoSegmentRomEnd), + LOAD_RAW (/*seg*/ 0x0D, _group12_geoSegmentRomStart, _group12_geoSegmentRomEnd), ALLOC_LEVEL_POOL(), - MARIO(/*model*/ MODEL_MARIO, /*behParam*/ 0x00000001, /*beh*/ bhvMario), + MARIO(/*model*/ MODEL_MARIO, /*bhvParam*/ BPARAM4(0x01), /*bhv*/ bhvMario), JUMP_LINK(script_func_global_13), LOAD_MODEL_FROM_GEO(MODEL_LEVEL_GEOMETRY_03, bowser_1_yellow_sphere_geo), AREA(/*index*/ 1, bowser_1_geo_0000D0), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 0, 1307, 0, /*angle*/ 0, 180, 0, /*behParam*/ 0x000A0000, /*beh*/ bhvSpinAirborneCircleWarp), - WARP_NODE(/*id*/ 0x0A, /*destLevel*/ LEVEL_BOWSER_1, /*destArea*/ 0x01, /*destNode*/ 0x0A, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0xF0, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x01, /*destNode*/ 0x24, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0xF1, /*destLevel*/ LEVEL_BITDW, /*destArea*/ 0x01, /*destNode*/ 0x0C, /*flags*/ WARP_NO_CHECKPOINT), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 0, 1307, 0, /*angle*/ 0, 180, 0, /*bhvParam*/ BPARAM2(WARP_NODE_0A), /*bhv*/ bhvSpinAirborneCircleWarp), + WARP_NODE(/*id*/ WARP_NODE_0A, /*destLevel*/ LEVEL_BOWSER_1, /*destArea*/ 1, /*destNode*/ WARP_NODE_0A, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_SUCCESS, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 1, /*destNode*/ WARP_NODE_24, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_DEATH, /*destLevel*/ LEVEL_BITDW, /*destArea*/ 1, /*destNode*/ WARP_NODE_0C, /*flags*/ WARP_NO_CHECKPOINT), TERRAIN(/*terrainData*/ bowser_1_seg7_collision_level), SET_BACKGROUND_MUSIC(/*settingsPreset*/ 0x0002, /*seq*/ SEQ_LEVEL_BOSS_KOOPA), TERRAIN_TYPE(/*terrainType*/ TERRAIN_STONE), diff --git a/levels/bowser_2/areas/1/geo.inc.c b/levels/bowser_2/areas/1/geo.inc.c index 2b0d120e..141816ff 100644 --- a/levels/bowser_2/areas/1/geo.inc.c +++ b/levels/bowser_2/areas/1/geo.inc.c @@ -1,26 +1,26 @@ // 0x0E000188 const GeoLayout bowser_2_geo_000188[] = { - GEO_NODE_SCREEN_AREA(10, SCREEN_WIDTH/2, SCREEN_HEIGHT/2, SCREEN_WIDTH/2, SCREEN_HEIGHT/2), - GEO_OPEN_NODE(), - GEO_ZBUFFER(0), - GEO_OPEN_NODE(), - GEO_NODE_ORTHO(100), - GEO_OPEN_NODE(), - GEO_BACKGROUND(BACKGROUND_FLAMING_SKY, geo_skybox_main), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ZBUFFER(1), - GEO_OPEN_NODE(), - GEO_CAMERA_FRUSTUM_WITH_FUNC(45, 100, 20000, geo_camera_fov), - GEO_OPEN_NODE(), - GEO_CAMERA(11, 0, 2000, 6000, 0, 0, 0, geo_camera_main), + GEO_NODE_SCREEN_AREA(10, SCREEN_WIDTH/2, SCREEN_HEIGHT/2, SCREEN_WIDTH/2, SCREEN_HEIGHT/2), + GEO_OPEN_NODE(), + GEO_ZBUFFER(0), + GEO_OPEN_NODE(), + GEO_NODE_ORTHO(100), GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bowser_2_seg7_dl_07001930), - GEO_RENDER_OBJ(), - GEO_ASM(12, geo_envfx_main), + GEO_BACKGROUND(BACKGROUND_FLAMING_SKY, geo_skybox_main), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CLOSE_NODE(), + GEO_ZBUFFER(1), + GEO_OPEN_NODE(), + GEO_CAMERA_FRUSTUM_WITH_FUNC(45, 100, 20000, geo_camera_fov), + GEO_OPEN_NODE(), + GEO_CAMERA(11, 0, 2000, 6000, 0, 0, 0, geo_camera_main), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bowser_2_seg7_dl_07001930), + GEO_RENDER_OBJ(), + GEO_ASM(12, geo_envfx_main), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bowser_2/leveldata.c b/levels/bowser_2/leveldata.c index 7c9e48bf..e4699d3e 100644 --- a/levels/bowser_2/leveldata.c +++ b/levels/bowser_2/leveldata.c @@ -3,8 +3,8 @@ #include "surface_terrains.h" #include "moving_texture_macros.h" #include "level_misc_macros.h" -#include "macro_preset_names.h" -#include "special_preset_names.h" +#include "macro_presets.h" +#include "special_presets.h" #include "textures.h" #include "make_const_nonconst.h" diff --git a/levels/bowser_2/script.c b/levels/bowser_2/script.c index b848c00c..4f1bda10 100644 --- a/levels/bowser_2/script.c +++ b/levels/bowser_2/script.c @@ -16,32 +16,32 @@ #include "levels/bowser_2/header.h" static const LevelScript script_func_local_1[] = { - OBJECT(/*model*/ MODEL_BOWSER_2_TILTING_ARENA, /*pos*/ 0, 0, 0, /*angle*/ 0, 90, 0, /*behParam*/ 0x00000000, /*beh*/ bhvTiltingBowserLavaPlatform), - OBJECT(/*model*/ MODEL_BOWSER_BOMB, /*pos*/ 4, 1329, 3598, /*angle*/ 0, 90, 0, /*behParam*/ 0x00000000, /*beh*/ bhvBowserBomb), - OBJECT(/*model*/ MODEL_BOWSER_BOMB, /*pos*/ 3584, 1329, 0, /*angle*/ 0, 90, 0, /*behParam*/ 0x00000000, /*beh*/ bhvBowserBomb), - OBJECT(/*model*/ MODEL_BOWSER_BOMB, /*pos*/ 0, 1329, -3583, /*angle*/ 0, 90, 0, /*behParam*/ 0x00000000, /*beh*/ bhvBowserBomb), - OBJECT(/*model*/ MODEL_BOWSER_BOMB, /*pos*/ -3583, 1329, 0, /*angle*/ 0, 90, 0, /*behParam*/ 0x00000000, /*beh*/ bhvBowserBomb), + OBJECT(/*model*/ MODEL_BOWSER_2_TILTING_ARENA, /*pos*/ 0, 0, 0, /*angle*/ 0, 90, 0, /*bhvParam*/ 0, /*bhv*/ bhvTiltingBowserLavaPlatform), + OBJECT(/*model*/ MODEL_BOWSER_BOMB, /*pos*/ 4, 1329, 3598, /*angle*/ 0, 90, 0, /*bhvParam*/ 0, /*bhv*/ bhvBowserBomb), + OBJECT(/*model*/ MODEL_BOWSER_BOMB, /*pos*/ 3584, 1329, 0, /*angle*/ 0, 90, 0, /*bhvParam*/ 0, /*bhv*/ bhvBowserBomb), + OBJECT(/*model*/ MODEL_BOWSER_BOMB, /*pos*/ 0, 1329, -3583, /*angle*/ 0, 90, 0, /*bhvParam*/ 0, /*bhv*/ bhvBowserBomb), + OBJECT(/*model*/ MODEL_BOWSER_BOMB, /*pos*/ -3583, 1329, 0, /*angle*/ 0, 90, 0, /*bhvParam*/ 0, /*bhv*/ bhvBowserBomb), RETURN(), }; const LevelScript level_bowser_2_entry[] = { INIT_LEVEL(), - LOAD_MIO0( /*seg*/ 0x0A, _bitfs_skybox_mio0SegmentRomStart, _bitfs_skybox_mio0SegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x0A, _bitfs_skybox_mio0SegmentRomStart, _bitfs_skybox_mio0SegmentRomEnd), LOAD_MIO0_TEXTURE(/*seg*/ 0x09, _fire_mio0SegmentRomStart, _fire_mio0SegmentRomEnd), - LOAD_MIO0( /*seg*/ 0x0B, _effect_mio0SegmentRomStart, _effect_mio0SegmentRomEnd), - LOAD_MIO0( /*seg*/ 0x07, _bowser_2_segment_7SegmentRomStart, _bowser_2_segment_7SegmentRomEnd), - LOAD_MIO0( /*seg*/ 0x06, _group12_mio0SegmentRomStart, _group12_mio0SegmentRomEnd), - LOAD_RAW( /*seg*/ 0x0D, _group12_geoSegmentRomStart, _group12_geoSegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x0B, _effect_mio0SegmentRomStart, _effect_mio0SegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x07, _bowser_2_segment_7SegmentRomStart, _bowser_2_segment_7SegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x06, _group12_mio0SegmentRomStart, _group12_mio0SegmentRomEnd), + LOAD_RAW (/*seg*/ 0x0D, _group12_geoSegmentRomStart, _group12_geoSegmentRomEnd), ALLOC_LEVEL_POOL(), - MARIO(/*model*/ MODEL_MARIO, /*behParam*/ 0x00000001, /*beh*/ bhvMario), + MARIO(/*model*/ MODEL_MARIO, /*bhvParam*/ BPARAM4(0x01), /*bhv*/ bhvMario), JUMP_LINK(script_func_global_13), LOAD_MODEL_FROM_GEO(MODEL_BOWSER_2_TILTING_ARENA, bowser_2_geo_000170), AREA(/*index*/ 1, bowser_2_geo_000188), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 0, 2229, 0, /*angle*/ 0, 180, 0, /*behParam*/ 0x000A0000, /*beh*/ bhvSpinAirborneCircleWarp), - WARP_NODE(/*id*/ 0x0A, /*destLevel*/ LEVEL_BOWSER_2, /*destArea*/ 0x01, /*destNode*/ 0x0A, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0xF0, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x03, /*destNode*/ 0x36, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0xF1, /*destLevel*/ LEVEL_BITFS, /*destArea*/ 0x01, /*destNode*/ 0x0C, /*flags*/ WARP_NO_CHECKPOINT), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 0, 2229, 0, /*angle*/ 0, 180, 0, /*bhvParam*/ BPARAM2(WARP_NODE_0A), /*bhv*/ bhvSpinAirborneCircleWarp), + WARP_NODE(/*id*/ WARP_NODE_0A, /*destLevel*/ LEVEL_BOWSER_2, /*destArea*/ 1, /*destNode*/ WARP_NODE_0A, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_SUCCESS, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 3, /*destNode*/ WARP_NODE_36, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_DEATH, /*destLevel*/ LEVEL_BITFS, /*destArea*/ 1, /*destNode*/ WARP_NODE_0C, /*flags*/ WARP_NO_CHECKPOINT), JUMP_LINK(script_func_local_1), TERRAIN(/*terrainData*/ bowser_2_seg7_collision_lava), SET_BACKGROUND_MUSIC(/*settingsPreset*/ 0x0002, /*seq*/ SEQ_LEVEL_BOSS_KOOPA), diff --git a/levels/bowser_2/tilting_platform/geo.inc.c b/levels/bowser_2/tilting_platform/geo.inc.c index 6283a1e6..a11f2edb 100644 --- a/levels/bowser_2/tilting_platform/geo.inc.c +++ b/levels/bowser_2/tilting_platform/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000170 const GeoLayout bowser_2_geo_000170[] = { - GEO_CULLING_RADIUS(5000), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bowser_2_seg7_dl_07000FE0), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(5000), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bowser_2_seg7_dl_07000FE0), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bowser_3/areas/1/bomb_stand/geo.inc.c b/levels/bowser_3/areas/1/bomb_stand/geo.inc.c index 3fe21e10..34fd2cfd 100644 --- a/levels/bowser_3/areas/1/bomb_stand/geo.inc.c +++ b/levels/bowser_3/areas/1/bomb_stand/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000380 const GeoLayout bowser_3_geo_000380[] = { - GEO_CULLING_RADIUS(700), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bowser_3_seg7_dl_07004958), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(700), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bowser_3_seg7_dl_07004958), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bowser_3/areas/1/geo.inc.c b/levels/bowser_3/areas/1/geo.inc.c index 9c6e02db..7c48328c 100644 --- a/levels/bowser_3/areas/1/geo.inc.c +++ b/levels/bowser_3/areas/1/geo.inc.c @@ -1,26 +1,26 @@ // 0x0E000398 const GeoLayout bowser_3_geo_000398[] = { - GEO_NODE_SCREEN_AREA(10, SCREEN_WIDTH/2, SCREEN_HEIGHT/2, SCREEN_WIDTH/2, SCREEN_HEIGHT/2), - GEO_OPEN_NODE(), - GEO_ZBUFFER(0), - GEO_OPEN_NODE(), - GEO_NODE_ORTHO(100), - GEO_OPEN_NODE(), - GEO_BACKGROUND(BACKGROUND_PURPLE_SKY, geo_skybox_main), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ZBUFFER(1), - GEO_OPEN_NODE(), - GEO_CAMERA_FRUSTUM_WITH_FUNC(45, 100, 12800, geo_camera_fov), - GEO_OPEN_NODE(), - GEO_CAMERA(11, 0, 2000, 6000, 0, 0, 0, geo_camera_main), + GEO_NODE_SCREEN_AREA(10, SCREEN_WIDTH/2, SCREEN_HEIGHT/2, SCREEN_WIDTH/2, SCREEN_HEIGHT/2), + GEO_OPEN_NODE(), + GEO_ZBUFFER(0), + GEO_OPEN_NODE(), + GEO_NODE_ORTHO(100), GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bowser_3_seg7_dl_070046B0), - GEO_RENDER_OBJ(), - GEO_ASM(0, geo_envfx_main), + GEO_BACKGROUND(BACKGROUND_PURPLE_SKY, geo_skybox_main), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CLOSE_NODE(), + GEO_ZBUFFER(1), + GEO_OPEN_NODE(), + GEO_CAMERA_FRUSTUM_WITH_FUNC(45, 100, 12800, geo_camera_fov), + GEO_OPEN_NODE(), + GEO_CAMERA(11, 0, 2000, 6000, 0, 0, 0, geo_camera_main), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bowser_3_seg7_dl_070046B0), + GEO_RENDER_OBJ(), + GEO_ASM(0, geo_envfx_main), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bowser_3/falling_platform_1/geo.inc.c b/levels/bowser_3/falling_platform_1/geo.inc.c index f46e4cb6..1f0c118c 100644 --- a/levels/bowser_3/falling_platform_1/geo.inc.c +++ b/levels/bowser_3/falling_platform_1/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000290 const GeoLayout bowser_3_geo_000290[] = { - GEO_CULLING_RADIUS(5000), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bowser_3_seg7_dl_070022A8), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(5000), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bowser_3_seg7_dl_070022A8), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bowser_3/falling_platform_10/geo.inc.c b/levels/bowser_3/falling_platform_10/geo.inc.c index 21fded64..15041f22 100644 --- a/levels/bowser_3/falling_platform_10/geo.inc.c +++ b/levels/bowser_3/falling_platform_10/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000368 const GeoLayout bowser_3_geo_000368[] = { - GEO_CULLING_RADIUS(5000), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bowser_3_seg7_dl_07003FA0), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(5000), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bowser_3_seg7_dl_07003FA0), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bowser_3/falling_platform_2/geo.inc.c b/levels/bowser_3/falling_platform_2/geo.inc.c index fb3a5cd1..8b173745 100644 --- a/levels/bowser_3/falling_platform_2/geo.inc.c +++ b/levels/bowser_3/falling_platform_2/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E0002A8 const GeoLayout bowser_3_geo_0002A8[] = { - GEO_CULLING_RADIUS(5000), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bowser_3_seg7_dl_070025E0), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(5000), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bowser_3_seg7_dl_070025E0), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bowser_3/falling_platform_3/geo.inc.c b/levels/bowser_3/falling_platform_3/geo.inc.c index e6e0e5be..586638b7 100644 --- a/levels/bowser_3/falling_platform_3/geo.inc.c +++ b/levels/bowser_3/falling_platform_3/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E0002C0 const GeoLayout bowser_3_geo_0002C0[] = { - GEO_CULLING_RADIUS(5000), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bowser_3_seg7_dl_07002918), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(5000), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bowser_3_seg7_dl_07002918), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bowser_3/falling_platform_4/geo.inc.c b/levels/bowser_3/falling_platform_4/geo.inc.c index d64b8dc8..92fb2277 100644 --- a/levels/bowser_3/falling_platform_4/geo.inc.c +++ b/levels/bowser_3/falling_platform_4/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E0002D8 const GeoLayout bowser_3_geo_0002D8[] = { - GEO_CULLING_RADIUS(5000), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bowser_3_seg7_dl_07002C50), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(5000), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bowser_3_seg7_dl_07002C50), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bowser_3/falling_platform_5/geo.inc.c b/levels/bowser_3/falling_platform_5/geo.inc.c index 2b8500d2..52939954 100644 --- a/levels/bowser_3/falling_platform_5/geo.inc.c +++ b/levels/bowser_3/falling_platform_5/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E0002F0 const GeoLayout bowser_3_geo_0002F0[] = { - GEO_CULLING_RADIUS(5000), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bowser_3_seg7_dl_07002F88), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(5000), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bowser_3_seg7_dl_07002F88), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bowser_3/falling_platform_6/geo.inc.c b/levels/bowser_3/falling_platform_6/geo.inc.c index 2fbe759e..b1ed8ccf 100644 --- a/levels/bowser_3/falling_platform_6/geo.inc.c +++ b/levels/bowser_3/falling_platform_6/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000308 const GeoLayout bowser_3_geo_000308[] = { - GEO_CULLING_RADIUS(5000), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bowser_3_seg7_dl_070032C0), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(5000), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bowser_3_seg7_dl_070032C0), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bowser_3/falling_platform_7/geo.inc.c b/levels/bowser_3/falling_platform_7/geo.inc.c index 4465bc7f..45016d71 100644 --- a/levels/bowser_3/falling_platform_7/geo.inc.c +++ b/levels/bowser_3/falling_platform_7/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000320 const GeoLayout bowser_3_geo_000320[] = { - GEO_CULLING_RADIUS(5000), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bowser_3_seg7_dl_070035F8), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(5000), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bowser_3_seg7_dl_070035F8), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bowser_3/falling_platform_8/geo.inc.c b/levels/bowser_3/falling_platform_8/geo.inc.c index 88529b73..556ba020 100644 --- a/levels/bowser_3/falling_platform_8/geo.inc.c +++ b/levels/bowser_3/falling_platform_8/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000338 const GeoLayout bowser_3_geo_000338[] = { - GEO_CULLING_RADIUS(5000), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bowser_3_seg7_dl_07003930), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(5000), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bowser_3_seg7_dl_07003930), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bowser_3/falling_platform_9/geo.inc.c b/levels/bowser_3/falling_platform_9/geo.inc.c index b9b80d50..9673c66b 100644 --- a/levels/bowser_3/falling_platform_9/geo.inc.c +++ b/levels/bowser_3/falling_platform_9/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000350 const GeoLayout bowser_3_geo_000350[] = { - GEO_CULLING_RADIUS(5000), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, bowser_3_seg7_dl_07003C68), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(5000), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, bowser_3_seg7_dl_07003C68), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/bowser_3/leveldata.c b/levels/bowser_3/leveldata.c index 3505aed3..d98fe545 100644 --- a/levels/bowser_3/leveldata.c +++ b/levels/bowser_3/leveldata.c @@ -3,8 +3,8 @@ #include "surface_terrains.h" #include "moving_texture_macros.h" #include "level_misc_macros.h" -#include "macro_preset_names.h" -#include "special_preset_names.h" +#include "macro_presets.h" +#include "special_presets.h" #include "textures.h" #include "make_const_nonconst.h" diff --git a/levels/bowser_3/script.c b/levels/bowser_3/script.c index 756ef81b..0ce454c3 100644 --- a/levels/bowser_3/script.c +++ b/levels/bowser_3/script.c @@ -16,21 +16,21 @@ #include "levels/bowser_3/header.h" static const LevelScript script_func_local_1[] = { - OBJECT(/*model*/ MODEL_BOWSER_3_FALLING_PLATFORM_1, /*pos*/ 0, 0, 0, /*angle*/ 0, 0, 0, /*behParam*/ 0x00010000, /*beh*/ bhvFallingBowserPlatform), - OBJECT(/*model*/ MODEL_BOWSER_3_FALLING_PLATFORM_2, /*pos*/ 0, 0, 0, /*angle*/ 0, 0, 0, /*behParam*/ 0x00020000, /*beh*/ bhvFallingBowserPlatform), - OBJECT(/*model*/ MODEL_BOWSER_3_FALLING_PLATFORM_3, /*pos*/ 0, 0, 0, /*angle*/ 0, 0, 0, /*behParam*/ 0x00030000, /*beh*/ bhvFallingBowserPlatform), - OBJECT(/*model*/ MODEL_BOWSER_3_FALLING_PLATFORM_4, /*pos*/ 0, 0, 0, /*angle*/ 0, 0, 0, /*behParam*/ 0x00040000, /*beh*/ bhvFallingBowserPlatform), - OBJECT(/*model*/ MODEL_BOWSER_3_FALLING_PLATFORM_5, /*pos*/ 0, 0, 0, /*angle*/ 0, 0, 0, /*behParam*/ 0x00050000, /*beh*/ bhvFallingBowserPlatform), - OBJECT(/*model*/ MODEL_BOWSER_3_FALLING_PLATFORM_6, /*pos*/ 0, 0, 0, /*angle*/ 0, 0, 0, /*behParam*/ 0x00060000, /*beh*/ bhvFallingBowserPlatform), - OBJECT(/*model*/ MODEL_BOWSER_3_FALLING_PLATFORM_7, /*pos*/ 0, 0, 0, /*angle*/ 0, 0, 0, /*behParam*/ 0x00070000, /*beh*/ bhvFallingBowserPlatform), - OBJECT(/*model*/ MODEL_BOWSER_3_FALLING_PLATFORM_8, /*pos*/ 0, 0, 0, /*angle*/ 0, 0, 0, /*behParam*/ 0x00080000, /*beh*/ bhvFallingBowserPlatform), - OBJECT(/*model*/ MODEL_BOWSER_3_FALLING_PLATFORM_9, /*pos*/ 0, 0, 0, /*angle*/ 0, 0, 0, /*behParam*/ 0x00090000, /*beh*/ bhvFallingBowserPlatform), - OBJECT(/*model*/ MODEL_BOWSER_3_FALLING_PLATFORM_10, /*pos*/ 0, 0, 0, /*angle*/ 0, 0, 0, /*behParam*/ 0x000A0000, /*beh*/ bhvFallingBowserPlatform), - OBJECT(/*model*/ MODEL_BOWSER_BOMB, /*pos*/ -2122, 512, -2912, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvBowserBomb), - OBJECT(/*model*/ MODEL_BOWSER_BOMB, /*pos*/ -3362, 512, 1121, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvBowserBomb), - OBJECT(/*model*/ MODEL_BOWSER_BOMB, /*pos*/ 0, 512, 3584, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvBowserBomb), - OBJECT(/*model*/ MODEL_BOWSER_BOMB, /*pos*/ 3363, 512, 1121, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvBowserBomb), - OBJECT(/*model*/ MODEL_BOWSER_BOMB, /*pos*/ 2123, 512, -2912, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvBowserBomb), + OBJECT(/*model*/ MODEL_BOWSER_3_FALLING_PLATFORM_1, /*pos*/ 0, 0, 0, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(1), /*bhv*/ bhvFallingBowserPlatform), + OBJECT(/*model*/ MODEL_BOWSER_3_FALLING_PLATFORM_2, /*pos*/ 0, 0, 0, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(2), /*bhv*/ bhvFallingBowserPlatform), + OBJECT(/*model*/ MODEL_BOWSER_3_FALLING_PLATFORM_3, /*pos*/ 0, 0, 0, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(3), /*bhv*/ bhvFallingBowserPlatform), + OBJECT(/*model*/ MODEL_BOWSER_3_FALLING_PLATFORM_4, /*pos*/ 0, 0, 0, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(4), /*bhv*/ bhvFallingBowserPlatform), + OBJECT(/*model*/ MODEL_BOWSER_3_FALLING_PLATFORM_5, /*pos*/ 0, 0, 0, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(5), /*bhv*/ bhvFallingBowserPlatform), + OBJECT(/*model*/ MODEL_BOWSER_3_FALLING_PLATFORM_6, /*pos*/ 0, 0, 0, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(6), /*bhv*/ bhvFallingBowserPlatform), + OBJECT(/*model*/ MODEL_BOWSER_3_FALLING_PLATFORM_7, /*pos*/ 0, 0, 0, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(7), /*bhv*/ bhvFallingBowserPlatform), + OBJECT(/*model*/ MODEL_BOWSER_3_FALLING_PLATFORM_8, /*pos*/ 0, 0, 0, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(8), /*bhv*/ bhvFallingBowserPlatform), + OBJECT(/*model*/ MODEL_BOWSER_3_FALLING_PLATFORM_9, /*pos*/ 0, 0, 0, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(9), /*bhv*/ bhvFallingBowserPlatform), + OBJECT(/*model*/ MODEL_BOWSER_3_FALLING_PLATFORM_10, /*pos*/ 0, 0, 0, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(10), /*bhv*/ bhvFallingBowserPlatform), + OBJECT(/*model*/ MODEL_BOWSER_BOMB, /*pos*/ -2122, 512, -2912, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvBowserBomb), + OBJECT(/*model*/ MODEL_BOWSER_BOMB, /*pos*/ -3362, 512, 1121, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvBowserBomb), + OBJECT(/*model*/ MODEL_BOWSER_BOMB, /*pos*/ 0, 512, 3584, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvBowserBomb), + OBJECT(/*model*/ MODEL_BOWSER_BOMB, /*pos*/ 3363, 512, 1121, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvBowserBomb), + OBJECT(/*model*/ MODEL_BOWSER_BOMB, /*pos*/ 2123, 512, -2912, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvBowserBomb), RETURN(), }; @@ -38,10 +38,10 @@ const LevelScript level_bowser_3_entry[] = { INIT_LEVEL(), LOAD_MIO0(/*seg*/ 0x07, _bowser_3_segment_7SegmentRomStart, _bowser_3_segment_7SegmentRomEnd), LOAD_MIO0(/*seg*/ 0x06, _group12_mio0SegmentRomStart, _group12_mio0SegmentRomEnd), - LOAD_RAW( /*seg*/ 0x0D, _group12_geoSegmentRomStart, _group12_geoSegmentRomEnd), + LOAD_RAW (/*seg*/ 0x0D, _group12_geoSegmentRomStart, _group12_geoSegmentRomEnd), LOAD_MIO0(/*seg*/ 0x0A, _bits_skybox_mio0SegmentRomStart, _bits_skybox_mio0SegmentRomEnd), ALLOC_LEVEL_POOL(), - MARIO(/*model*/ MODEL_MARIO, /*behParam*/ 0x00000001, /*beh*/ bhvMario), + MARIO(/*model*/ MODEL_MARIO, /*bhvParam*/ BPARAM4(0x01), /*bhv*/ bhvMario), JUMP_LINK(script_func_global_13), LOAD_MODEL_FROM_GEO(MODEL_BOWSER_3_FALLING_PLATFORM_1, bowser_3_geo_000290), LOAD_MODEL_FROM_GEO(MODEL_BOWSER_3_FALLING_PLATFORM_2, bowser_3_geo_0002A8), @@ -56,10 +56,10 @@ const LevelScript level_bowser_3_entry[] = { LOAD_MODEL_FROM_GEO(MODEL_LEVEL_GEOMETRY_03, bowser_3_geo_000380), AREA(/*index*/ 1, bowser_3_geo_000398), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 0, 1307, 0, /*angle*/ 0, 183, 0, /*behParam*/ 0x000A0000, /*beh*/ bhvSpinAirborneCircleWarp), - WARP_NODE(/*id*/ 0x0A, /*destLevel*/ LEVEL_BOWSER_3, /*destArea*/ 0x01, /*destNode*/ 0x0A, /*flags*/ WARP_NO_CHECKPOINT), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 0, 1307, 0, /*angle*/ 0, 183, 0, /*bhvParam*/ BPARAM2(WARP_NODE_0A), /*bhv*/ bhvSpinAirborneCircleWarp), + WARP_NODE(/*id*/ WARP_NODE_0A, /*destLevel*/ LEVEL_BOWSER_3, /*destArea*/ 1, /*destNode*/ WARP_NODE_0A, /*flags*/ WARP_NO_CHECKPOINT), JUMP_LINK(script_func_local_1), - WARP_NODE(/*id*/ 0xF1, /*destLevel*/ LEVEL_BITS, /*destArea*/ 0x01, /*destNode*/ 0x0C, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_DEATH, /*destLevel*/ LEVEL_BITS, /*destArea*/ 1, /*destNode*/ WARP_NODE_0C, /*flags*/ WARP_NO_CHECKPOINT), TERRAIN(/*terrainData*/ bowser_3_seg7_collision_level), SET_BACKGROUND_MUSIC(/*settingsPreset*/ 0x0002, /*seq*/ SEQ_LEVEL_BOSS_KOOPA_FINAL), TERRAIN_TYPE(/*terrainType*/ TERRAIN_STONE), diff --git a/levels/castle_courtyard/areas/1/collision.inc.c b/levels/castle_courtyard/areas/1/collision.inc.c index 8d1f2bd3..b18e82c7 100644 --- a/levels/castle_courtyard/areas/1/collision.inc.c +++ b/levels/castle_courtyard/areas/1/collision.inc.c @@ -865,7 +865,7 @@ const Collision castle_courtyard_seg7_collision[] = { SPECIAL_OBJECT(/*preset*/ special_spiky_tree, /*pos*/ -2446, -214, -1786), SPECIAL_OBJECT(/*preset*/ special_spiky_tree, /*pos*/ -2820, -214, -1317), SPECIAL_OBJECT(/*preset*/ special_spiky_tree, /*pos*/ -1868, -214, -45), - SPECIAL_OBJECT_WITH_YAW_AND_PARAM(/*preset*/ special_wooden_door_warp, /*pos*/ 0, 0, 461, /*yaw*/ 0, /*behParam2*/ 1), + SPECIAL_OBJECT_WITH_YAW_AND_PARAM(/*preset*/ special_wooden_door_warp, /*pos*/ 0, 0, 461, /*yaw*/ 0, /*bhvParam2*/ 1), COL_WATER_BOX_INIT(1), COL_WATER_BOX(0, -656, -2405, 674, -1074, 51), COL_END(), diff --git a/levels/castle_courtyard/areas/1/geo.inc.c b/levels/castle_courtyard/areas/1/geo.inc.c index 1d1d1dec..ca842b4b 100644 --- a/levels/castle_courtyard/areas/1/geo.inc.c +++ b/levels/castle_courtyard/areas/1/geo.inc.c @@ -1,30 +1,30 @@ // 0x0E000218 const GeoLayout castle_courtyard_geo_000218[] = { - GEO_NODE_SCREEN_AREA(10, SCREEN_WIDTH/2, SCREEN_HEIGHT/2, SCREEN_WIDTH/2, SCREEN_HEIGHT/2), - GEO_OPEN_NODE(), - GEO_ZBUFFER(0), - GEO_OPEN_NODE(), - GEO_NODE_ORTHO(100), - GEO_OPEN_NODE(), - GEO_BACKGROUND(BACKGROUND_OCEAN_SKY, geo_skybox_main), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ZBUFFER(1), - GEO_OPEN_NODE(), - GEO_CAMERA_FRUSTUM_WITH_FUNC(45, 100, 12800, geo_camera_fov), - GEO_OPEN_NODE(), - GEO_CAMERA(16, 0, 2000, 6000, 0, 0, 0, geo_camera_main), + GEO_NODE_SCREEN_AREA(10, SCREEN_WIDTH/2, SCREEN_HEIGHT/2, SCREEN_WIDTH/2, SCREEN_HEIGHT/2), + GEO_OPEN_NODE(), + GEO_ZBUFFER(0), + GEO_OPEN_NODE(), + GEO_NODE_ORTHO(100), GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, castle_courtyard_seg7_dl_070048B8), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT_DECAL, castle_courtyard_seg7_dl_07005698), - GEO_DISPLAY_LIST(LAYER_ALPHA, castle_courtyard_seg7_dl_07005938), - GEO_ASM( 0, geo_movtex_pause_control), - GEO_ASM(0x2601, geo_movtex_draw_water_regions), - GEO_RENDER_OBJ(), - GEO_ASM(0, geo_envfx_main), + GEO_BACKGROUND(BACKGROUND_OCEAN_SKY, geo_skybox_main), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CLOSE_NODE(), + GEO_ZBUFFER(1), + GEO_OPEN_NODE(), + GEO_CAMERA_FRUSTUM_WITH_FUNC(45, 100, 12800, geo_camera_fov), + GEO_OPEN_NODE(), + GEO_CAMERA(16, 0, 2000, 6000, 0, 0, 0, geo_camera_main), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, castle_courtyard_seg7_dl_070048B8), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT_DECAL, castle_courtyard_seg7_dl_07005698), + GEO_DISPLAY_LIST(LAYER_ALPHA, castle_courtyard_seg7_dl_07005938), + GEO_ASM( 0, geo_movtex_pause_control), + GEO_ASM(0x2601, geo_movtex_draw_water_regions), + GEO_RENDER_OBJ(), + GEO_ASM(0, geo_envfx_main), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/castle_courtyard/areas/1/macro.inc.c b/levels/castle_courtyard/areas/1/macro.inc.c index 0f88dfd2..5014065d 100644 --- a/levels/castle_courtyard/areas/1/macro.inc.c +++ b/levels/castle_courtyard/areas/1/macro.inc.c @@ -1,8 +1,8 @@ // 0x07006E20 - 0x07006E4A const MacroObject castle_courtyard_seg7_macro_objs[] = { - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 225, /*pos*/ 3180, 20, 330, /*behParam*/ DIALOG_158), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 135, /*pos*/ -3180, 20, 330, /*behParam*/ DIALOG_159), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 0, /*pos*/ 300, 0, -3600, /*behParam*/ DIALOG_102), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 0, /*pos*/ -300, 0, -3600, /*behParam*/ DIALOG_160), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 225, /*pos*/ 3180, 20, 330, /*bhvParam*/ DIALOG_158), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 135, /*pos*/ -3180, 20, 330, /*bhvParam*/ DIALOG_159), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 0, /*pos*/ 300, 0, -3600, /*bhvParam*/ DIALOG_102), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 0, /*pos*/ -300, 0, -3600, /*bhvParam*/ DIALOG_160), MACRO_OBJECT_END(), }; diff --git a/levels/castle_courtyard/areas/1/spire/geo.inc.c b/levels/castle_courtyard/areas/1/spire/geo.inc.c index 1f24eaea..81e9c5db 100644 --- a/levels/castle_courtyard/areas/1/spire/geo.inc.c +++ b/levels/castle_courtyard/areas/1/spire/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000200 const GeoLayout castle_courtyard_geo_000200[] = { - GEO_CULLING_RADIUS(2600), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, castle_courtyard_seg7_dl_07005078), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(2600), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, castle_courtyard_seg7_dl_07005078), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/castle_courtyard/leveldata.c b/levels/castle_courtyard/leveldata.c index 6d14ac59..cd6ed84f 100644 --- a/levels/castle_courtyard/leveldata.c +++ b/levels/castle_courtyard/leveldata.c @@ -3,8 +3,8 @@ #include "surface_terrains.h" #include "moving_texture_macros.h" #include "level_misc_macros.h" -#include "macro_preset_names.h" -#include "special_preset_names.h" +#include "macro_presets.h" +#include "special_presets.h" #include "textures.h" #include "dialog_ids.h" diff --git a/levels/castle_courtyard/script.c b/levels/castle_courtyard/script.c index c17cc21a..bffa0a62 100644 --- a/levels/castle_courtyard/script.c +++ b/levels/castle_courtyard/script.c @@ -16,30 +16,30 @@ #include "levels/castle_courtyard/header.h" static const LevelScript script_func_local_1[] = { - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 0, 200, -1652, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvAmbientSounds), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -2700, 0, -1652, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvBirdsSoundLoop), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 2700, 0, -1652, /*angle*/ 0, 0, 0, /*behParam*/ 0x00010000, /*beh*/ bhvBirdsSoundLoop), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 0, 200, -1652, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvAmbientSounds), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ -2700, 0, -1652, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(0x00), /*bhv*/ bhvBirdsSoundLoop), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 2700, 0, -1652, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(0x01), /*bhv*/ bhvBirdsSoundLoop), RETURN(), }; static const LevelScript script_func_local_2[] = { - OBJECT(/*model*/ MODEL_BOO, /*pos*/ -3217, 100, -101, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvCourtyardBooTriplet), - OBJECT(/*model*/ MODEL_BOO, /*pos*/ 3317, 100, -1701, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvCourtyardBooTriplet), - OBJECT(/*model*/ MODEL_BOO, /*pos*/ -71, 1, -1387, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvCourtyardBooTriplet), + OBJECT(/*model*/ MODEL_BOO, /*pos*/ -3217, 100, -101, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvCourtyardBooTriplet), + OBJECT(/*model*/ MODEL_BOO, /*pos*/ 3317, 100, -1701, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvCourtyardBooTriplet), + OBJECT(/*model*/ MODEL_BOO, /*pos*/ -71, 1, -1387, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvCourtyardBooTriplet), RETURN(), }; const LevelScript level_castle_courtyard_entry[] = { INIT_LEVEL(), - LOAD_MIO0( /*seg*/ 0x07, _castle_courtyard_segment_7SegmentRomStart, _castle_courtyard_segment_7SegmentRomEnd), - LOAD_MIO0( /*seg*/ 0x0A, _water_skybox_mio0SegmentRomStart, _water_skybox_mio0SegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x07, _castle_courtyard_segment_7SegmentRomStart, _castle_courtyard_segment_7SegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x0A, _water_skybox_mio0SegmentRomStart, _water_skybox_mio0SegmentRomEnd), LOAD_MIO0_TEXTURE(/*seg*/ 0x09, _outside_mio0SegmentRomStart, _outside_mio0SegmentRomEnd), - LOAD_MIO0( /*seg*/ 0x05, _group9_mio0SegmentRomStart, _group9_mio0SegmentRomEnd), - LOAD_RAW( /*seg*/ 0x0C, _group9_geoSegmentRomStart, _group9_geoSegmentRomEnd), - LOAD_MIO0( /*seg*/ 0x08, _common0_mio0SegmentRomStart, _common0_mio0SegmentRomEnd), - LOAD_RAW( /*seg*/ 0x0F, _common0_geoSegmentRomStart, _common0_geoSegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x05, _group9_mio0SegmentRomStart, _group9_mio0SegmentRomEnd), + LOAD_RAW (/*seg*/ 0x0C, _group9_geoSegmentRomStart, _group9_geoSegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x08, _common0_mio0SegmentRomStart, _common0_mio0SegmentRomEnd), + LOAD_RAW (/*seg*/ 0x0F, _common0_geoSegmentRomStart, _common0_geoSegmentRomEnd), ALLOC_LEVEL_POOL(), - MARIO(/*model*/ MODEL_MARIO, /*behParam*/ 0x00000001, /*beh*/ bhvMario), + MARIO(/*model*/ MODEL_MARIO, /*bhvParam*/ BPARAM4(0x01), /*bhv*/ bhvMario), JUMP_LINK(script_func_global_1), JUMP_LINK(script_func_global_10), LOAD_MODEL_FROM_GEO(MODEL_COURTYARD_SPIKY_TREE, spiky_tree_geo), @@ -47,14 +47,14 @@ const LevelScript level_castle_courtyard_entry[] = { LOAD_MODEL_FROM_GEO(MODEL_LEVEL_GEOMETRY_03, castle_courtyard_geo_000200), AREA(/*index*/ 1, castle_courtyard_geo_000218), - OBJECT(/*model*/ MODEL_BOO, /*pos*/ -2360, -100, -2712, /*angle*/ 0, 0, 0, /*behParam*/ 0x01050000, /*beh*/ bhvBooWithCage), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 0, 51, -1000, /*angle*/ 0, 180, 0, /*behParam*/ 0x000A0000, /*beh*/ bhvLaunchStarCollectWarp), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 0, 51, -1000, /*angle*/ 0, 180, 0, /*behParam*/ 0x000B0000, /*beh*/ bhvLaunchDeathWarp), - WARP_NODE(/*id*/ 0x05, /*destLevel*/ LEVEL_BBH, /*destArea*/ 0x01, /*destNode*/ 0x0A, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0x0A, /*destLevel*/ LEVEL_CASTLE_COURTYARD, /*destArea*/ 0x01, /*destNode*/ 0x0A, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0x0B, /*destLevel*/ LEVEL_CASTLE_COURTYARD, /*destArea*/ 0x01, /*destNode*/ 0x0B, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0x01, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x01, /*destNode*/ 0x02, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0xF1, /*destLevel*/ LEVEL_CASTLE_GROUNDS, /*destArea*/ 0x01, /*destNode*/ 0x03, /*flags*/ WARP_NO_CHECKPOINT), + OBJECT(/*model*/ MODEL_BOO, /*pos*/ -2360, -100, -2712, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(1) | BPARAM2(WARP_NODE_05), /*bhv*/ bhvBooWithCage), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 0, 51, -1000, /*angle*/ 0, 180, 0, /*bhvParam*/ BPARAM2(WARP_NODE_0A), /*bhv*/ bhvLaunchStarCollectWarp), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 0, 51, -1000, /*angle*/ 0, 180, 0, /*bhvParam*/ BPARAM2(WARP_NODE_0B), /*bhv*/ bhvLaunchDeathWarp), + WARP_NODE(/*id*/ WARP_NODE_05, /*destLevel*/ LEVEL_BBH, /*destArea*/ 1, /*destNode*/ WARP_NODE_0A, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_0A, /*destLevel*/ LEVEL_CASTLE_COURTYARD, /*destArea*/ 1, /*destNode*/ WARP_NODE_0A, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_0B, /*destLevel*/ LEVEL_CASTLE_COURTYARD, /*destArea*/ 1, /*destNode*/ WARP_NODE_0B, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_01, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 1, /*destNode*/ WARP_NODE_02, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_DEATH, /*destLevel*/ LEVEL_CASTLE_GROUNDS, /*destArea*/ 1, /*destNode*/ WARP_NODE_03, /*flags*/ WARP_NO_CHECKPOINT), JUMP_LINK(script_func_local_1), JUMP_LINK(script_func_local_2), TERRAIN(/*terrainData*/ castle_courtyard_seg7_collision), diff --git a/levels/castle_grounds/areas/1/11/geo.inc.c b/levels/castle_grounds/areas/1/11/geo.inc.c index e5127f1d..3b85c389 100644 --- a/levels/castle_grounds/areas/1/11/geo.inc.c +++ b/levels/castle_grounds/areas/1/11/geo.inc.c @@ -1,27 +1,27 @@ // 0x0E000660 const GeoLayout castle_grounds_geo_000660[] = { - GEO_CULLING_RADIUS(1000), - GEO_OPEN_NODE(), - GEO_SCALE(0x00, 24576), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, castle_grounds_seg7_dl_0700C768), + GEO_CULLING_RADIUS(1000), + GEO_OPEN_NODE(), + GEO_SCALE(0x00, 24576), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL), GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 459, 0, 0, castle_grounds_seg7_dl_0700C728), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 460, 0, 0, castle_grounds_seg7_dl_0700C6E8), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 345, 0, 0, castle_grounds_seg7_dl_0700C6A8), - GEO_OPEN_NODE(), - GEO_ANIMATED_PART(LAYER_OPAQUE, 287, 0, 0, castle_grounds_seg7_dl_0700C670), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, castle_grounds_seg7_dl_0700C768), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 459, 0, 0, castle_grounds_seg7_dl_0700C728), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 460, 0, 0, castle_grounds_seg7_dl_0700C6E8), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 345, 0, 0, castle_grounds_seg7_dl_0700C6A8), + GEO_OPEN_NODE(), + GEO_ANIMATED_PART(LAYER_OPAQUE, 287, 0, 0, castle_grounds_seg7_dl_0700C670), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), -GEO_CLOSE_NODE(), //! more close than open nodes -GEO_END(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), //! more close than open nodes + GEO_END(), }; diff --git a/levels/castle_grounds/areas/1/3/geo.inc.c b/levels/castle_grounds/areas/1/3/geo.inc.c index f76d37d2..a6fd4dd7 100644 --- a/levels/castle_grounds/areas/1/3/geo.inc.c +++ b/levels/castle_grounds/areas/1/3/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E0006F4 const GeoLayout castle_grounds_geo_0006F4[] = { - GEO_CULLING_RADIUS(2100), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, castle_grounds_seg7_dl_0700A290), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(2100), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, castle_grounds_seg7_dl_0700A290), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/castle_grounds/areas/1/7/geo.inc.c b/levels/castle_grounds/areas/1/7/geo.inc.c index 26bae9a8..26702b34 100644 --- a/levels/castle_grounds/areas/1/7/geo.inc.c +++ b/levels/castle_grounds/areas/1/7/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E00070C const GeoLayout castle_grounds_geo_00070C[] = { - GEO_CULLING_RADIUS(15000), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, castle_grounds_seg7_dl_0700BB80), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(15000), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, castle_grounds_seg7_dl_0700BB80), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/castle_grounds/areas/1/8/geo.inc.c b/levels/castle_grounds/areas/1/8/geo.inc.c index 1a5ae855..6bb3a8a4 100644 --- a/levels/castle_grounds/areas/1/8/geo.inc.c +++ b/levels/castle_grounds/areas/1/8/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000724 const GeoLayout castle_grounds_geo_000724[] = { - GEO_CULLING_RADIUS(15000), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, castle_grounds_seg7_dl_0700BC68), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(15000), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, castle_grounds_seg7_dl_0700BC68), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/castle_grounds/areas/1/collision.inc.c b/levels/castle_grounds/areas/1/collision.inc.c index 64a1fa82..04cc038c 100644 --- a/levels/castle_grounds/areas/1/collision.inc.c +++ b/levels/castle_grounds/areas/1/collision.inc.c @@ -1410,9 +1410,9 @@ const Collision castle_grounds_seg7_collision_level[] = { SPECIAL_OBJECT(/*preset*/ special_bubble_tree, /*pos*/ 5774, 413, -1114), SPECIAL_OBJECT(/*preset*/ special_bubble_tree, /*pos*/ 5954, 526, -2846), SPECIAL_OBJECT(/*preset*/ special_bubble_tree, /*pos*/ -5204, 296, 811), - SPECIAL_OBJECT_WITH_YAW_AND_PARAM(/*preset*/ special_metal_door_warp, /*pos*/ 3292, -511, -2931, /*yaw*/ 160, /*behParam2*/ 2), - SPECIAL_OBJECT_WITH_YAW_AND_PARAM(/*preset*/ special_castle_door_warp, /*pos*/ -76, 803, -3155, /*yaw*/ 0, /*behParam2*/ 0), - SPECIAL_OBJECT_WITH_YAW_AND_PARAM(/*preset*/ special_castle_door_warp, /*pos*/ 77, 803, -3155, /*yaw*/ 128, /*behParam2*/ 1), + SPECIAL_OBJECT_WITH_YAW_AND_PARAM(/*preset*/ special_metal_door_warp, /*pos*/ 3292, -511, -2931, /*yaw*/ 160, /*bhvParam2*/ 2), + SPECIAL_OBJECT_WITH_YAW_AND_PARAM(/*preset*/ special_castle_door_warp, /*pos*/ -76, 803, -3155, /*yaw*/ 0, /*bhvParam2*/ 0), + SPECIAL_OBJECT_WITH_YAW_AND_PARAM(/*preset*/ special_castle_door_warp, /*pos*/ 77, 803, -3155, /*yaw*/ 128, /*bhvParam2*/ 1), COL_WATER_BOX_INIT(2), COL_WATER_BOX(0, -7129, -7222, 8253, -58, -81), COL_WATER_BOX(1, 1024, -58, 8230, 8137, -81), diff --git a/levels/castle_grounds/areas/1/geo.inc.c b/levels/castle_grounds/areas/1/geo.inc.c index 96233941..59b155c3 100644 --- a/levels/castle_grounds/areas/1/geo.inc.c +++ b/levels/castle_grounds/areas/1/geo.inc.c @@ -1,39 +1,39 @@ // 0x0E00073C const GeoLayout castle_grounds_geo_00073C[] = { - GEO_NODE_SCREEN_AREA(10, SCREEN_WIDTH/2, SCREEN_HEIGHT/2, SCREEN_WIDTH/2, SCREEN_HEIGHT/2), - GEO_OPEN_NODE(), - GEO_ZBUFFER(0), - GEO_OPEN_NODE(), - GEO_NODE_ORTHO(100), - GEO_OPEN_NODE(), - GEO_BACKGROUND(BACKGROUND_OCEAN_SKY, geo_skybox_main), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ZBUFFER(1), - GEO_OPEN_NODE(), - GEO_CAMERA_FRUSTUM_WITH_FUNC(45, 100, 20000, geo_camera_fov), - GEO_OPEN_NODE(), - GEO_CAMERA(16, 0, 1500, 2500, 0, 1500, -12000, geo_camera_main), + GEO_NODE_SCREEN_AREA(10, SCREEN_WIDTH/2, SCREEN_HEIGHT/2, SCREEN_WIDTH/2, SCREEN_HEIGHT/2), + GEO_OPEN_NODE(), + GEO_ZBUFFER(0), + GEO_OPEN_NODE(), + GEO_NODE_ORTHO(100), GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, castle_grounds_seg7_dl_07006D70), - GEO_DISPLAY_LIST(LAYER_OPAQUE, castle_grounds_seg7_dl_070095F0), - GEO_DISPLAY_LIST(LAYER_ALPHA, castle_grounds_seg7_dl_0700A860), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT_DECAL, castle_grounds_seg7_dl_0700B1D0), - GEO_DISPLAY_LIST(LAYER_ALPHA, castle_grounds_seg7_dl_0700BA20), - GEO_DISPLAY_LIST(LAYER_OPAQUE_DECAL, castle_grounds_seg7_dl_0700C430), - GEO_DISPLAY_LIST(LAYER_OPAQUE, castle_grounds_seg7_dl_0700C210), - GEO_ASM( 0, geo_movtex_pause_control), - GEO_ASM(0x1601, geo_movtex_draw_nocolor), - GEO_ASM(0x1601, geo_movtex_draw_water_regions), - GEO_RENDER_OBJ(), - GEO_ASM(0, geo_envfx_main), + GEO_BACKGROUND(BACKGROUND_OCEAN_SKY, geo_skybox_main), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ZBUFFER(0), - GEO_OPEN_NODE(), - GEO_ASM(0, geo_cannon_circle_base), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CLOSE_NODE(), + GEO_ZBUFFER(1), + GEO_OPEN_NODE(), + GEO_CAMERA_FRUSTUM_WITH_FUNC(45, 100, 20000, geo_camera_fov), + GEO_OPEN_NODE(), + GEO_CAMERA(16, 0, 1500, 2500, 0, 1500, -12000, geo_camera_main), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, castle_grounds_seg7_dl_07006D70), + GEO_DISPLAY_LIST(LAYER_OPAQUE, castle_grounds_seg7_dl_070095F0), + GEO_DISPLAY_LIST(LAYER_ALPHA, castle_grounds_seg7_dl_0700A860), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT_DECAL, castle_grounds_seg7_dl_0700B1D0), + GEO_DISPLAY_LIST(LAYER_ALPHA, castle_grounds_seg7_dl_0700BA20), + GEO_DISPLAY_LIST(LAYER_OPAQUE_DECAL, castle_grounds_seg7_dl_0700C430), + GEO_DISPLAY_LIST(LAYER_OPAQUE, castle_grounds_seg7_dl_0700C210), + GEO_ASM( 0, geo_movtex_pause_control), + GEO_ASM(0x1601, geo_movtex_draw_nocolor), + GEO_ASM(0x1601, geo_movtex_draw_water_regions), + GEO_RENDER_OBJ(), + GEO_ASM(0, geo_envfx_main), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ZBUFFER(0), + GEO_OPEN_NODE(), + GEO_ASM(0, geo_cannon_circle_base), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/castle_grounds/areas/1/macro.inc.c b/levels/castle_grounds/areas/1/macro.inc.c index 94ea2330..d418394f 100644 --- a/levels/castle_grounds/areas/1/macro.inc.c +++ b/levels/castle_grounds/areas/1/macro.inc.c @@ -1,21 +1,21 @@ // 0x07010D08 - 0x07010DB4 const MacroObject castle_grounds_seg7_macro_objs[] = { - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 262, /*pos*/ 5288, 722, -800, /*behParam*/ DIALOG_050), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 90, /*pos*/ 1740, 35, 2500, /*behParam*/ DIALOG_065), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 0, /*pos*/ -1566, 260, 3503, /*behParam*/ DIALOG_167), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 82, /*pos*/ -4666, 260, 922, /*behParam*/ DIALOG_051), - MACRO_OBJECT(/*preset*/ macro_hidden_1up_in_pole, /*yaw*/ 0, /*pos*/ -6270, 975, -2145), - MACRO_OBJECT(/*preset*/ macro_1up, /*yaw*/ 0, /*pos*/ -440, 3180, -5000), - MACRO_OBJECT(/*preset*/ macro_1up, /*yaw*/ 0, /*pos*/ 0, 3180, -5200), - MACRO_OBJECT(/*preset*/ macro_1up, /*yaw*/ 0, /*pos*/ 440, 3180, -5000), - MACRO_OBJECT(/*preset*/ macro_box_wing_cap, /*yaw*/ 0, /*pos*/ 13, 3476, -5646), - MACRO_OBJECT(/*preset*/ macro_hidden_1up_trigger, /*yaw*/ 0, /*pos*/ 0, 535, -500), - MACRO_OBJECT(/*preset*/ macro_hidden_1up_trigger, /*yaw*/ 0, /*pos*/ 0, 535, -1774), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_hidden_1up, /*yaw*/ 0, /*pos*/ 0, 510, -1170, /*behParam*/ 2), - MACRO_OBJECT(/*preset*/ macro_yellow_coin, /*yaw*/ 0, /*pos*/ 0, 540, -1774), - MACRO_OBJECT(/*preset*/ macro_yellow_coin, /*yaw*/ 0, /*pos*/ 0, 540, -500), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_cannon_open, /*yaw*/ 0, /*pos*/ 2384, 70, 1961, /*behParam*/ 0x40), - MACRO_OBJECT(/*preset*/ macro_butterfly_triplet_2, /*yaw*/ 0, /*pos*/ -6240, 295, 320), - MACRO_OBJECT(/*preset*/ macro_butterfly_triplet_2, /*yaw*/ 0, /*pos*/ 6330, 710, -3760), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 262, /*pos*/ 5288, 722, -800, /*bhvParam*/ DIALOG_050), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 90, /*pos*/ 1740, 35, 2500, /*bhvParam*/ DIALOG_065), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 0, /*pos*/ -1566, 260, 3503, /*bhvParam*/ DIALOG_167), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 82, /*pos*/ -4666, 260, 922, /*bhvParam*/ DIALOG_051), + MACRO_OBJECT (/*preset*/ macro_hidden_1up_in_pole, /*yaw*/ 0, /*pos*/ -6270, 975, -2145), + MACRO_OBJECT (/*preset*/ macro_1up, /*yaw*/ 0, /*pos*/ -440, 3180, -5000), + MACRO_OBJECT (/*preset*/ macro_1up, /*yaw*/ 0, /*pos*/ 0, 3180, -5200), + MACRO_OBJECT (/*preset*/ macro_1up, /*yaw*/ 0, /*pos*/ 440, 3180, -5000), + MACRO_OBJECT (/*preset*/ macro_box_wing_cap, /*yaw*/ 0, /*pos*/ 13, 3476, -5646), + MACRO_OBJECT (/*preset*/ macro_hidden_1up_trigger, /*yaw*/ 0, /*pos*/ 0, 535, -500), + MACRO_OBJECT (/*preset*/ macro_hidden_1up_trigger, /*yaw*/ 0, /*pos*/ 0, 535, -1774), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_hidden_1up, /*yaw*/ 0, /*pos*/ 0, 510, -1170, /*bhvParam*/ 2), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_1, /*yaw*/ 0, /*pos*/ 0, 540, -1774), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_1, /*yaw*/ 0, /*pos*/ 0, 540, -500), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_cannon_open, /*yaw*/ 0, /*pos*/ 2384, 70, 1961, /*bhvParam*/ 0x40), + MACRO_OBJECT (/*preset*/ macro_butterfly_triplet_no_bombs, /*yaw*/ 0, /*pos*/ -6240, 295, 320), + MACRO_OBJECT (/*preset*/ macro_butterfly_triplet_no_bombs, /*yaw*/ 0, /*pos*/ 6330, 710, -3760), MACRO_OBJECT_END(), }; diff --git a/levels/castle_grounds/leveldata.c b/levels/castle_grounds/leveldata.c index 1263f062..a2f7eb7f 100644 --- a/levels/castle_grounds/leveldata.c +++ b/levels/castle_grounds/leveldata.c @@ -3,8 +3,8 @@ #include "surface_terrains.h" #include "moving_texture_macros.h" #include "level_misc_macros.h" -#include "macro_preset_names.h" -#include "special_preset_names.h" +#include "macro_presets.h" +#include "special_presets.h" #include "textures.h" #include "dialog_ids.h" diff --git a/levels/castle_grounds/script.c b/levels/castle_grounds/script.c index 626bece4..a1c899c2 100644 --- a/levels/castle_grounds/script.c +++ b/levels/castle_grounds/script.c @@ -16,95 +16,95 @@ #include "levels/castle_grounds/header.h" static const LevelScript script_func_local_1[] = { - WARP_NODE(/*id*/ 0x00, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x01, /*destNode*/ 0x00, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0x01, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x01, /*destNode*/ 0x01, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0x02, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x03, /*destNode*/ 0x02, /*flags*/ WARP_NO_CHECKPOINT), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 0, 900, -1710, /*angle*/ 0, 180, 0, /*behParam*/ 0x00030000, /*beh*/ bhvDeathWarp), - WARP_NODE(/*id*/ 0x03, /*destLevel*/ LEVEL_CASTLE_GROUNDS, /*destArea*/ 0x01, /*destNode*/ 0x03, /*flags*/ WARP_NO_CHECKPOINT), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -1328, 260, 4664, /*angle*/ 0, 180, 0, /*behParam*/ 0x00040000, /*beh*/ bhvSpinAirborneCircleWarp), - WARP_NODE(/*id*/ 0x04, /*destLevel*/ LEVEL_CASTLE_GROUNDS, /*destArea*/ 0x01, /*destNode*/ 0x04, /*flags*/ WARP_NO_CHECKPOINT), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -3379, -815, -2025, /*angle*/ 0, 0, 0, /*behParam*/ 0x3C050000, /*beh*/ bhvWarp), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -3379, -500, -2025, /*angle*/ 0, 180, 0, /*behParam*/ 0x00060000, /*beh*/ bhvLaunchDeathWarp), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -3799, -1199, -5816, /*angle*/ 0, 0, 0, /*behParam*/ 0x00070000, /*beh*/ bhvSwimmingWarp), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -3379, -500, -2025, /*angle*/ 0, 180, 0, /*behParam*/ 0x00080000, /*beh*/ bhvLaunchStarCollectWarp), - WARP_NODE(/*id*/ 0x05, /*destLevel*/ LEVEL_VCUTM, /*destArea*/ 0x01, /*destNode*/ 0x0A, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0x06, /*destLevel*/ LEVEL_CASTLE_GROUNDS, /*destArea*/ 0x01, /*destNode*/ 0x06, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0x07, /*destLevel*/ LEVEL_CASTLE_GROUNDS, /*destArea*/ 0x01, /*destNode*/ 0x07, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0x08, /*destLevel*/ LEVEL_CASTLE_GROUNDS, /*destArea*/ 0x01, /*destNode*/ 0x08, /*flags*/ WARP_NO_CHECKPOINT), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 5408, 4500, 3637, /*angle*/ 0, 225, 0, /*behParam*/ 0x000A0000, /*beh*/ bhvAirborneWarp), - WARP_NODE(/*id*/ 0x0A, /*destLevel*/ LEVEL_CASTLE_GROUNDS, /*destArea*/ 0x01, /*destNode*/ 0x0A, /*flags*/ WARP_NO_CHECKPOINT), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -6901, 2376, -6509, /*angle*/ 0, 230, 0, /*behParam*/ 0x00140000, /*beh*/ bhvAirborneWarp), - WARP_NODE(/*id*/ 0x14, /*destLevel*/ LEVEL_CASTLE_GROUNDS, /*destArea*/ 0x01, /*destNode*/ 0x14, /*flags*/ WARP_NO_CHECKPOINT), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 4997, -1250, 2258, /*angle*/ 0, 210, 0, /*behParam*/ 0x001E0000, /*beh*/ bhvSwimmingWarp), - WARP_NODE(/*id*/ 0x1E, /*destLevel*/ LEVEL_CASTLE_GROUNDS, /*destArea*/ 0x01, /*destNode*/ 0x1E, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_00, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 1, /*destNode*/ WARP_NODE_00, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_01, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 1, /*destNode*/ WARP_NODE_01, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_02, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 3, /*destNode*/ WARP_NODE_02, /*flags*/ WARP_NO_CHECKPOINT), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 0, 900, -1710, /*angle*/ 0, 180, 0, /*bhvParam*/ BPARAM2(WARP_NODE_03), /*bhv*/ bhvDeathWarp), + WARP_NODE(/*id*/ WARP_NODE_03, /*destLevel*/ LEVEL_CASTLE_GROUNDS, /*destArea*/ 1, /*destNode*/ WARP_NODE_03, /*flags*/ WARP_NO_CHECKPOINT), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ -1328, 260, 4664, /*angle*/ 0, 180, 0, /*bhvParam*/ BPARAM2(WARP_NODE_04), /*bhv*/ bhvSpinAirborneCircleWarp), + WARP_NODE(/*id*/ WARP_NODE_04, /*destLevel*/ LEVEL_CASTLE_GROUNDS, /*destArea*/ 1, /*destNode*/ WARP_NODE_04, /*flags*/ WARP_NO_CHECKPOINT), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ -3379, -815, -2025, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(60) | BPARAM2(WARP_NODE_05), /*bhv*/ bhvWarp), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ -3379, -500, -2025, /*angle*/ 0, 180, 0, /*bhvParam*/ BPARAM2(WARP_NODE_06), /*bhv*/ bhvLaunchDeathWarp), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ -3799, -1199, -5816, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(WARP_NODE_07), /*bhv*/ bhvSwimmingWarp), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ -3379, -500, -2025, /*angle*/ 0, 180, 0, /*bhvParam*/ BPARAM2(WARP_NODE_08), /*bhv*/ bhvLaunchStarCollectWarp), + WARP_NODE(/*id*/ WARP_NODE_05, /*destLevel*/ LEVEL_VCUTM, /*destArea*/ 1, /*destNode*/ WARP_NODE_0A, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_06, /*destLevel*/ LEVEL_CASTLE_GROUNDS, /*destArea*/ 1, /*destNode*/ WARP_NODE_06, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_07, /*destLevel*/ LEVEL_CASTLE_GROUNDS, /*destArea*/ 1, /*destNode*/ WARP_NODE_07, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_08, /*destLevel*/ LEVEL_CASTLE_GROUNDS, /*destArea*/ 1, /*destNode*/ WARP_NODE_08, /*flags*/ WARP_NO_CHECKPOINT), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 5408, 4500, 3637, /*angle*/ 0, 225, 0, /*bhvParam*/ BPARAM2(WARP_NODE_0A), /*bhv*/ bhvAirborneWarp), + WARP_NODE(/*id*/ WARP_NODE_0A, /*destLevel*/ LEVEL_CASTLE_GROUNDS, /*destArea*/ 1, /*destNode*/ WARP_NODE_0A, /*flags*/ WARP_NO_CHECKPOINT), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ -6901, 2376, -6509, /*angle*/ 0, 230, 0, /*bhvParam*/ BPARAM2(WARP_NODE_14), /*bhv*/ bhvAirborneWarp), + WARP_NODE(/*id*/ WARP_NODE_14, /*destLevel*/ LEVEL_CASTLE_GROUNDS, /*destArea*/ 1, /*destNode*/ WARP_NODE_14, /*flags*/ WARP_NO_CHECKPOINT), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 4997, -1250, 2258, /*angle*/ 0, 210, 0, /*bhvParam*/ BPARAM2(WARP_NODE_1E), /*bhv*/ bhvSwimmingWarp), + WARP_NODE(/*id*/ WARP_NODE_1E, /*destLevel*/ LEVEL_CASTLE_GROUNDS, /*destArea*/ 1, /*destNode*/ WARP_NODE_1E, /*flags*/ WARP_NO_CHECKPOINT), RETURN(), }; static const LevelScript script_func_local_2[] = { - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -5812, 100, -5937, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvWaterfallSoundLoop), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -7430, 1500, 873, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvBirdsSoundLoop), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -80, 1500, 5004, /*angle*/ 0, 0, 0, /*behParam*/ 0x00010000, /*beh*/ bhvBirdsSoundLoop), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 7131, 1500, -2989, /*angle*/ 0, 0, 0, /*behParam*/ 0x00020000, /*beh*/ bhvBirdsSoundLoop), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -7430, 1500, -5937, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvAmbientSounds), - OBJECT(/*model*/ MODEL_CASTLE_GROUNDS_VCUTM_GRILL, /*pos*/ 0, 0, 0, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvMoatGrills), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 0, 0, 0, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvInvisibleObjectsUnderBridge), - OBJECT(/*model*/ MODEL_MIST, /*pos*/ -4878, -787, -5690, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvWaterMist2), - OBJECT(/*model*/ MODEL_MIST, /*pos*/ -4996, -787, -5548, /*angle*/ 0, 0, 0, /*behParam*/ 0x00010000, /*beh*/ bhvWaterMist2), - OBJECT(/*model*/ MODEL_MIST, /*pos*/ -5114, -787, -5406, /*angle*/ 0, 0, 0, /*behParam*/ 0x00020000, /*beh*/ bhvWaterMist2), - OBJECT(/*model*/ MODEL_MIST, /*pos*/ -5212, -787, -5219, /*angle*/ 0, 0, 0, /*behParam*/ 0x00030000, /*beh*/ bhvWaterMist2), - OBJECT(/*model*/ MODEL_MIST, /*pos*/ -5311, -787, -5033, /*angle*/ 0, 0, 0, /*behParam*/ 0x00040000, /*beh*/ bhvWaterMist2), - OBJECT(/*model*/ MODEL_MIST, /*pos*/ -5419, -787, -4895, /*angle*/ 0, 0, 0, /*behParam*/ 0x00050000, /*beh*/ bhvWaterMist2), - OBJECT(/*model*/ MODEL_MIST, /*pos*/ -5527, -787, -4757, /*angle*/ 0, 0, 0, /*behParam*/ 0x00060000, /*beh*/ bhvWaterMist2), - OBJECT(/*model*/ MODEL_MIST, /*pos*/ -5686, -787, -4733, /*angle*/ 0, 0, 0, /*behParam*/ 0x00070000, /*beh*/ bhvWaterMist2), - OBJECT(/*model*/ MODEL_MIST, /*pos*/ -5845, -787, -4710, /*angle*/ 0, 0, 0, /*behParam*/ 0x00080000, /*beh*/ bhvWaterMist2), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 5223, -975, 1667, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvManyBlueFishSpawner), - OBJECT(/*model*/ MODEL_BIRDS, /*pos*/ -5069, 850, 3221, /*angle*/ 0, 0, 0, /*behParam*/ 0x00010000, /*beh*/ bhvBird), - OBJECT(/*model*/ MODEL_BIRDS, /*pos*/ -4711, 742, 433, /*angle*/ 0, 0, 0, /*behParam*/ 0x00010000, /*beh*/ bhvBird), - OBJECT(/*model*/ MODEL_BIRDS, /*pos*/ 5774, 913, -1114, /*angle*/ 0, 0, 0, /*behParam*/ 0x00010000, /*beh*/ bhvBird), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -1328, 260, 4664, /*angle*/ 0, 180, 0, /*behParam*/ 0x00280000, /*beh*/ bhvIntroScene), - OBJECT(/*model*/ MODEL_CASTLE_GROUNDS_CANNON_GRILL, /*pos*/ 0, 0, 0, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvHiddenAt120Stars), - OBJECT(/*model*/ MODEL_LAKITU, /*pos*/ 11, 803, -3015, /*angle*/ 0, 0, 0, /*behParam*/ 0x00010000, /*beh*/ bhvCameraLakitu), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ -5812, 100, -5937, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvWaterfallSoundLoop), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ -7430, 1500, 873, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(0x00), /*bhv*/ bhvBirdsSoundLoop), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ -80, 1500, 5004, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(0x01), /*bhv*/ bhvBirdsSoundLoop), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 7131, 1500, -2989, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(0x02), /*bhv*/ bhvBirdsSoundLoop), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ -7430, 1500, -5937, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvAmbientSounds), + OBJECT(/*model*/ MODEL_CASTLE_GROUNDS_VCUTM_GRILL, /*pos*/ 0, 0, 0, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvMoatGrills), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 0, 0, 0, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvInvisibleObjectsUnderBridge), + OBJECT(/*model*/ MODEL_MIST, /*pos*/ -4878, -787, -5690, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvWaterMist2), + OBJECT(/*model*/ MODEL_MIST, /*pos*/ -4996, -787, -5548, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(0x01), /*bhv*/ bhvWaterMist2), + OBJECT(/*model*/ MODEL_MIST, /*pos*/ -5114, -787, -5406, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(0x02), /*bhv*/ bhvWaterMist2), + OBJECT(/*model*/ MODEL_MIST, /*pos*/ -5212, -787, -5219, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(0x03), /*bhv*/ bhvWaterMist2), + OBJECT(/*model*/ MODEL_MIST, /*pos*/ -5311, -787, -5033, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(0x04), /*bhv*/ bhvWaterMist2), + OBJECT(/*model*/ MODEL_MIST, /*pos*/ -5419, -787, -4895, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(0x05), /*bhv*/ bhvWaterMist2), + OBJECT(/*model*/ MODEL_MIST, /*pos*/ -5527, -787, -4757, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(0x06), /*bhv*/ bhvWaterMist2), + OBJECT(/*model*/ MODEL_MIST, /*pos*/ -5686, -787, -4733, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(0x07), /*bhv*/ bhvWaterMist2), + OBJECT(/*model*/ MODEL_MIST, /*pos*/ -5845, -787, -4710, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(0x08), /*bhv*/ bhvWaterMist2), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 5223, -975, 1667, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvManyBlueFishSpawner), + OBJECT(/*model*/ MODEL_BIRDS, /*pos*/ -5069, 850, 3221, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(BIRD_BP_SPAWNER), /*bhv*/ bhvBird), + OBJECT(/*model*/ MODEL_BIRDS, /*pos*/ -4711, 742, 433, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(BIRD_BP_SPAWNER), /*bhv*/ bhvBird), + OBJECT(/*model*/ MODEL_BIRDS, /*pos*/ 5774, 913, -1114, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(BIRD_BP_SPAWNER), /*bhv*/ bhvBird), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ -1328, 260, 4664, /*angle*/ 0, 180, 0, /*bhvParam*/ BPARAM2(0x28), /*bhv*/ bhvIntroScene), + OBJECT(/*model*/ MODEL_CASTLE_GROUNDS_CANNON_GRILL, /*pos*/ 0, 0, 0, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvHiddenAt120Stars), + OBJECT(/*model*/ MODEL_LAKITU, /*pos*/ 11, 803, -3015, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(CAMERA_LAKITU_BP_INTRO), /*bhv*/ bhvCameraLakitu), RETURN(), }; static const LevelScript script_func_local_3[] = { - OBJECT(/*model*/ MODEL_CASTLE_GROUNDS_FLAG, /*pos*/ -3213, 3348, -3011, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvCastleFlagWaving), - OBJECT(/*model*/ MODEL_CASTLE_GROUNDS_FLAG, /*pos*/ 3213, 3348, -3011, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvCastleFlagWaving), - OBJECT(/*model*/ MODEL_CASTLE_GROUNDS_FLAG, /*pos*/ -3835, 3348, -6647, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvCastleFlagWaving), - OBJECT(/*model*/ MODEL_CASTLE_GROUNDS_FLAG, /*pos*/ 3835, 3348, -6647, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvCastleFlagWaving), + OBJECT(/*model*/ MODEL_CASTLE_GROUNDS_FLAG, /*pos*/ -3213, 3348, -3011, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvCastleFlagWaving), + OBJECT(/*model*/ MODEL_CASTLE_GROUNDS_FLAG, /*pos*/ 3213, 3348, -3011, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvCastleFlagWaving), + OBJECT(/*model*/ MODEL_CASTLE_GROUNDS_FLAG, /*pos*/ -3835, 3348, -6647, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvCastleFlagWaving), + OBJECT(/*model*/ MODEL_CASTLE_GROUNDS_FLAG, /*pos*/ 3835, 3348, -6647, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvCastleFlagWaving), RETURN(), }; static const LevelScript script_func_local_4[] = { - OBJECT(/*model*/ MODEL_BUTTERFLY, /*pos*/ -4508, 406, 4400, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvButterfly), - OBJECT(/*model*/ MODEL_BUTTERFLY, /*pos*/ -4408, 406, 4500, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvButterfly), - OBJECT(/*model*/ MODEL_BUTTERFLY, /*pos*/ -4708, 406, 4100, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvButterfly), - OBJECT(/*model*/ MODEL_BUTTERFLY, /*pos*/ -6003, 473, -2621, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvButterfly), - OBJECT(/*model*/ MODEL_BUTTERFLY, /*pos*/ -6003, 473, -2321, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvButterfly), - OBJECT(/*model*/ MODEL_BUTTERFLY, /*pos*/ 6543, 461, -617, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvButterfly), - OBJECT(/*model*/ MODEL_BUTTERFLY, /*pos*/ 6143, 461, -617, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvButterfly), - OBJECT(/*model*/ MODEL_BUTTERFLY, /*pos*/ 5773, 775, -5722, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvButterfly), - OBJECT(/*model*/ MODEL_BUTTERFLY, /*pos*/ 5873, 775, -5622, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvButterfly), - OBJECT(/*model*/ MODEL_BUTTERFLY, /*pos*/ 5473, 775, -5322, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvButterfly), - OBJECT(/*model*/ MODEL_BUTTERFLY, /*pos*/ -1504, 326, 3196, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvButterfly), - OBJECT(/*model*/ MODEL_BUTTERFLY, /*pos*/ -1204, 326, 3296, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvButterfly), - OBJECT(/*model*/ MODEL_YOSHI, /*pos*/ 0, 3174, -5625, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvYoshi), + OBJECT(/*model*/ MODEL_BUTTERFLY, /*pos*/ -4508, 406, 4400, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvButterfly), + OBJECT(/*model*/ MODEL_BUTTERFLY, /*pos*/ -4408, 406, 4500, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvButterfly), + OBJECT(/*model*/ MODEL_BUTTERFLY, /*pos*/ -4708, 406, 4100, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvButterfly), + OBJECT(/*model*/ MODEL_BUTTERFLY, /*pos*/ -6003, 473, -2621, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvButterfly), + OBJECT(/*model*/ MODEL_BUTTERFLY, /*pos*/ -6003, 473, -2321, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvButterfly), + OBJECT(/*model*/ MODEL_BUTTERFLY, /*pos*/ 6543, 461, -617, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvButterfly), + OBJECT(/*model*/ MODEL_BUTTERFLY, /*pos*/ 6143, 461, -617, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvButterfly), + OBJECT(/*model*/ MODEL_BUTTERFLY, /*pos*/ 5773, 775, -5722, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvButterfly), + OBJECT(/*model*/ MODEL_BUTTERFLY, /*pos*/ 5873, 775, -5622, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvButterfly), + OBJECT(/*model*/ MODEL_BUTTERFLY, /*pos*/ 5473, 775, -5322, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvButterfly), + OBJECT(/*model*/ MODEL_BUTTERFLY, /*pos*/ -1504, 326, 3196, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvButterfly), + OBJECT(/*model*/ MODEL_BUTTERFLY, /*pos*/ -1204, 326, 3296, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvButterfly), + OBJECT(/*model*/ MODEL_YOSHI, /*pos*/ 0, 3174, -5625, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvYoshi), RETURN(), }; const LevelScript level_castle_grounds_entry[] = { INIT_LEVEL(), - LOAD_MIO0( /*seg*/ 0x07, _castle_grounds_segment_7SegmentRomStart, _castle_grounds_segment_7SegmentRomEnd), - LOAD_MIO0( /*seg*/ 0x0A, _water_skybox_mio0SegmentRomStart, _water_skybox_mio0SegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x07, _castle_grounds_segment_7SegmentRomStart, _castle_grounds_segment_7SegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x0A, _water_skybox_mio0SegmentRomStart, _water_skybox_mio0SegmentRomEnd), LOAD_MIO0_TEXTURE(/*seg*/ 0x09, _outside_mio0SegmentRomStart, _outside_mio0SegmentRomEnd), - LOAD_MIO0( /*seg*/ 0x05, _group10_mio0SegmentRomStart, _group10_mio0SegmentRomEnd), - LOAD_RAW( /*seg*/ 0x0C, _group10_geoSegmentRomStart, _group10_geoSegmentRomEnd), - LOAD_MIO0( /*seg*/ 0x06, _group15_mio0SegmentRomStart, _group15_mio0SegmentRomEnd), - LOAD_RAW( /*seg*/ 0x0D, _group15_geoSegmentRomStart, _group15_geoSegmentRomEnd), - LOAD_MIO0( /*seg*/ 0x08, _common0_mio0SegmentRomStart, _common0_mio0SegmentRomEnd), - LOAD_RAW( /*seg*/ 0x0F, _common0_geoSegmentRomStart, _common0_geoSegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x05, _group10_mio0SegmentRomStart, _group10_mio0SegmentRomEnd), + LOAD_RAW (/*seg*/ 0x0C, _group10_geoSegmentRomStart, _group10_geoSegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x06, _group15_mio0SegmentRomStart, _group15_mio0SegmentRomEnd), + LOAD_RAW (/*seg*/ 0x0D, _group15_geoSegmentRomStart, _group15_geoSegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x08, _common0_mio0SegmentRomStart, _common0_mio0SegmentRomEnd), + LOAD_RAW (/*seg*/ 0x0F, _common0_geoSegmentRomStart, _common0_geoSegmentRomEnd), ALLOC_LEVEL_POOL(), - MARIO(/*model*/ MODEL_MARIO, /*behParam*/ 0x00000001, /*beh*/ bhvMario), + MARIO(/*model*/ MODEL_MARIO, /*bhvParam*/ BPARAM4(0x01), /*bhv*/ bhvMario), JUMP_LINK(script_func_global_1), JUMP_LINK(script_func_global_11), JUMP_LINK(script_func_global_16), @@ -118,7 +118,7 @@ const LevelScript level_castle_grounds_entry[] = { LOAD_MODEL_FROM_GEO(MODEL_CASTLE_GROUNDS_CANNON_GRILL, castle_grounds_geo_000724), AREA(/*index*/ 1, castle_grounds_geo_00073C), - WARP_NODE(/*id*/ 0xF1, /*destLevel*/ LEVEL_CASTLE_GROUNDS, /*destArea*/ 0x01, /*destNode*/ 0x03, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_DEATH, /*destLevel*/ LEVEL_CASTLE_GROUNDS, /*destArea*/ 1, /*destNode*/ WARP_NODE_03, /*flags*/ WARP_NO_CHECKPOINT), JUMP_LINK(script_func_local_1), JUMP_LINK(script_func_local_2), JUMP_LINK(script_func_local_3), diff --git a/levels/castle_inside/areas/1/collision.inc.c b/levels/castle_inside/areas/1/collision.inc.c index a081bccf..45bacdfb 100644 --- a/levels/castle_inside/areas/1/collision.inc.c +++ b/levels/castle_inside/areas/1/collision.inc.c @@ -3744,9 +3744,9 @@ const Collision inside_castle_seg7_area_1_collision[] = { SPECIAL_OBJECT_WITH_YAW(/*preset*/ special_null_start, /*pos*/ -1023, 0, 1152, /*yaw*/ 128), // unused, probably an early way to set initial position SPECIAL_OBJECT_WITH_YAW(/*preset*/ special_wooden_door, /*pos*/ -271, 0, -824, /*yaw*/ 32), SPECIAL_OBJECT_WITH_YAW(/*preset*/ special_wooden_door, /*pos*/ -1775, 0, -824, /*yaw*/ 224), - SPECIAL_OBJECT_WITH_YAW_AND_PARAM(/*preset*/ special_castle_door_warp, /*pos*/ -1100, 0, 2202, /*yaw*/ 0, /*behParam2*/ 0), - SPECIAL_OBJECT_WITH_YAW_AND_PARAM(/*preset*/ special_castle_door_warp, /*pos*/ -946, 0, 2202, /*yaw*/ 128, /*behParam2*/ 1), - SPECIAL_OBJECT_WITH_YAW_AND_PARAM(/*preset*/ special_wooden_door_warp, /*pos*/ -1023, -101, -5170, /*yaw*/ 0, /*behParam2*/ 2), + SPECIAL_OBJECT_WITH_YAW_AND_PARAM(/*preset*/ special_castle_door_warp, /*pos*/ -1100, 0, 2202, /*yaw*/ 0, /*bhvParam2*/ 0), + SPECIAL_OBJECT_WITH_YAW_AND_PARAM(/*preset*/ special_castle_door_warp, /*pos*/ -946, 0, 2202, /*yaw*/ 128, /*bhvParam2*/ 1), + SPECIAL_OBJECT_WITH_YAW_AND_PARAM(/*preset*/ special_wooden_door_warp, /*pos*/ -1023, -101, -5170, /*yaw*/ 0, /*bhvParam2*/ 2), SPECIAL_OBJECT_WITH_YAW(/*preset*/ special_0stars_door, /*pos*/ -3122, 205, -793, /*yaw*/ 64), SPECIAL_OBJECT_WITH_YAW(/*preset*/ special_1star_door, /*pos*/ 256, 0, -1074, /*yaw*/ 0), SPECIAL_OBJECT_WITH_YAW(/*preset*/ special_1star_door, /*pos*/ 644, 614, -1476, /*yaw*/ 224), diff --git a/levels/castle_inside/areas/1/geo.inc.c b/levels/castle_inside/areas/1/geo.inc.c index 78d3e442..1b15c86c 100644 --- a/levels/castle_inside/areas/1/geo.inc.c +++ b/levels/castle_inside/areas/1/geo.inc.c @@ -1,301 +1,301 @@ // 0x0E000F30 const GeoLayout castle_geo_000F30[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_07028FD0), - GEO_DISPLAY_LIST(LAYER_ALPHA, inside_castle_seg7_dl_07029578), - GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_0702A650), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT_DECAL, inside_castle_seg7_dl_0702AA10), - GEO_DISPLAY_LIST(LAYER_ALPHA, inside_castle_seg7_dl_0702AB20), - GEO_ASM(0, geo_exec_inside_castle_light), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_07028FD0), + GEO_DISPLAY_LIST(LAYER_ALPHA, inside_castle_seg7_dl_07029578), + GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_0702A650), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT_DECAL, inside_castle_seg7_dl_0702AA10), + GEO_DISPLAY_LIST(LAYER_ALPHA, inside_castle_seg7_dl_0702AB20), + GEO_ASM(0, geo_exec_inside_castle_light), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x0E000F70 const GeoLayout castle_geo_000F70[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_0702E408), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_0702E408), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x0E000F88 const GeoLayout castle_geo_000F88[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_0702FD30), - GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_07023DB0), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_0702FD30), + GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_07023DB0), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x0E000FA8 const GeoLayout castle_geo_000FA8[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_07031588), - GEO_DISPLAY_LIST(LAYER_ALPHA, inside_castle_seg7_dl_07031720), - GEO_DISPLAY_LIST(LAYER_ALPHA, inside_castle_seg7_dl_07031830), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_07031588), + GEO_DISPLAY_LIST(LAYER_ALPHA, inside_castle_seg7_dl_07031720), + GEO_DISPLAY_LIST(LAYER_ALPHA, inside_castle_seg7_dl_07031830), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x0E000FD0 const GeoLayout castle_geo_000FD0[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_07032FC0), - GEO_DISPLAY_LIST(LAYER_ALPHA, inside_castle_seg7_dl_07033158), - GEO_ASM( 0, geo_painting_update), - GEO_ASM(PAINTING_ID(0, 1), geo_painting_draw), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_07032FC0), + GEO_DISPLAY_LIST(LAYER_ALPHA, inside_castle_seg7_dl_07033158), + GEO_ASM( 0, geo_painting_update), + GEO_ASM(PAINTING_ID(0, 1), geo_painting_draw), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x0E001000 const GeoLayout castle_geo_001000[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_07034D88), - GEO_DISPLAY_LIST(LAYER_ALPHA, inside_castle_seg7_dl_07035178), - GEO_DISPLAY_LIST(LAYER_ALPHA, inside_castle_seg7_dl_07035288), - GEO_ASM( 0, geo_painting_update), - GEO_ASM(PAINTING_ID(2, 1), geo_painting_draw), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_07034D88), + GEO_DISPLAY_LIST(LAYER_ALPHA, inside_castle_seg7_dl_07035178), + GEO_DISPLAY_LIST(LAYER_ALPHA, inside_castle_seg7_dl_07035288), + GEO_ASM( 0, geo_painting_update), + GEO_ASM(PAINTING_ID(2, 1), geo_painting_draw), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x0E001038 const GeoLayout castle_geo_001038[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_07036D88), - GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_07037988), - GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_07037BF8), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, inside_castle_seg7_dl_07037DE8), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, dl_castle_aquarium_light), - GEO_DISPLAY_LIST(LAYER_ALPHA, inside_castle_seg7_dl_07038350), - GEO_ASM( 0, geo_painting_update), - GEO_ASM(PAINTING_ID(3, 1), geo_painting_draw), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_07036D88), + GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_07037988), + GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_07037BF8), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, inside_castle_seg7_dl_07037DE8), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, dl_castle_aquarium_light), + GEO_DISPLAY_LIST(LAYER_ALPHA, inside_castle_seg7_dl_07038350), + GEO_ASM( 0, geo_painting_update), + GEO_ASM(PAINTING_ID(3, 1), geo_painting_draw), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x0E001088 const GeoLayout castle_geo_001088[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_0703A6C8), - GEO_DISPLAY_LIST(LAYER_ALPHA, inside_castle_seg7_dl_0703A808), - GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_070234C0), - GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_07023520), - GEO_ASM( 0, geo_painting_update), - GEO_ASM(PAINTING_ID(1, 1), geo_painting_draw), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_0703A6C8), + GEO_DISPLAY_LIST(LAYER_ALPHA, inside_castle_seg7_dl_0703A808), + GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_070234C0), + GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_07023520), + GEO_ASM( 0, geo_painting_update), + GEO_ASM(PAINTING_ID(1, 1), geo_painting_draw), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x0E0010C8 const GeoLayout castle_geo_0010C8[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_07028FD0), - GEO_DISPLAY_LIST(LAYER_ALPHA, inside_castle_seg7_dl_07029578), - GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_0702A650), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT_DECAL, inside_castle_seg7_dl_0702AA10), - GEO_DISPLAY_LIST(LAYER_ALPHA, inside_castle_seg7_dl_0702AB20), - GEO_ASM(0, geo_exec_inside_castle_light), - GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_0703BA08), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_07028FD0), + GEO_DISPLAY_LIST(LAYER_ALPHA, inside_castle_seg7_dl_07029578), + GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_0702A650), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT_DECAL, inside_castle_seg7_dl_0702AA10), + GEO_DISPLAY_LIST(LAYER_ALPHA, inside_castle_seg7_dl_0702AB20), + GEO_ASM(0, geo_exec_inside_castle_light), + GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_0703BA08), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x0E001110 const GeoLayout castle_geo_001110[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_07028FD0), - GEO_DISPLAY_LIST(LAYER_ALPHA, inside_castle_seg7_dl_07029578), - GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_0702A650), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT_DECAL, inside_castle_seg7_dl_0702AA10), - GEO_DISPLAY_LIST(LAYER_ALPHA, inside_castle_seg7_dl_0702AB20), - GEO_ASM(0, geo_exec_inside_castle_light), - GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_0702E408), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_07028FD0), + GEO_DISPLAY_LIST(LAYER_ALPHA, inside_castle_seg7_dl_07029578), + GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_0702A650), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT_DECAL, inside_castle_seg7_dl_0702AA10), + GEO_DISPLAY_LIST(LAYER_ALPHA, inside_castle_seg7_dl_0702AB20), + GEO_ASM(0, geo_exec_inside_castle_light), + GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_0702E408), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x0E001158 const GeoLayout castle_geo_001158[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_07028FD0), - GEO_DISPLAY_LIST(LAYER_ALPHA, inside_castle_seg7_dl_07029578), - GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_0702A650), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT_DECAL, inside_castle_seg7_dl_0702AA10), - GEO_DISPLAY_LIST(LAYER_ALPHA, inside_castle_seg7_dl_0702AB20), - GEO_ASM(0, geo_exec_inside_castle_light), - GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_0702FD30), - GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_07023DB0), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_07028FD0), + GEO_DISPLAY_LIST(LAYER_ALPHA, inside_castle_seg7_dl_07029578), + GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_0702A650), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT_DECAL, inside_castle_seg7_dl_0702AA10), + GEO_DISPLAY_LIST(LAYER_ALPHA, inside_castle_seg7_dl_0702AB20), + GEO_ASM(0, geo_exec_inside_castle_light), + GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_0702FD30), + GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_07023DB0), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x0E0011A8 const GeoLayout castle_geo_0011A8[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_07028FD0), - GEO_DISPLAY_LIST(LAYER_ALPHA, inside_castle_seg7_dl_07029578), - GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_0702A650), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT_DECAL, inside_castle_seg7_dl_0702AA10), - GEO_DISPLAY_LIST(LAYER_ALPHA, inside_castle_seg7_dl_0702AB20), - GEO_ASM(0, geo_exec_inside_castle_light), - GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_07031588), - GEO_DISPLAY_LIST(LAYER_ALPHA, inside_castle_seg7_dl_07031720), - GEO_DISPLAY_LIST(LAYER_ALPHA, inside_castle_seg7_dl_07031830), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_07028FD0), + GEO_DISPLAY_LIST(LAYER_ALPHA, inside_castle_seg7_dl_07029578), + GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_0702A650), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT_DECAL, inside_castle_seg7_dl_0702AA10), + GEO_DISPLAY_LIST(LAYER_ALPHA, inside_castle_seg7_dl_0702AB20), + GEO_ASM(0, geo_exec_inside_castle_light), + GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_07031588), + GEO_DISPLAY_LIST(LAYER_ALPHA, inside_castle_seg7_dl_07031720), + GEO_DISPLAY_LIST(LAYER_ALPHA, inside_castle_seg7_dl_07031830), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x0E001200 const GeoLayout castle_geo_001200[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_07028FD0), - GEO_DISPLAY_LIST(LAYER_ALPHA, inside_castle_seg7_dl_07029578), - GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_0702A650), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT_DECAL, inside_castle_seg7_dl_0702AA10), - GEO_DISPLAY_LIST(LAYER_ALPHA, inside_castle_seg7_dl_0702AB20), - GEO_ASM( 0, geo_exec_inside_castle_light), - GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_07032FC0), - GEO_DISPLAY_LIST(LAYER_ALPHA, inside_castle_seg7_dl_07033158), - GEO_ASM( 0, geo_painting_update), - GEO_ASM(256, geo_painting_draw), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_07028FD0), + GEO_DISPLAY_LIST(LAYER_ALPHA, inside_castle_seg7_dl_07029578), + GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_0702A650), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT_DECAL, inside_castle_seg7_dl_0702AA10), + GEO_DISPLAY_LIST(LAYER_ALPHA, inside_castle_seg7_dl_0702AB20), + GEO_ASM( 0, geo_exec_inside_castle_light), + GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_07032FC0), + GEO_DISPLAY_LIST(LAYER_ALPHA, inside_castle_seg7_dl_07033158), + GEO_ASM( 0, geo_painting_update), + GEO_ASM(256, geo_painting_draw), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x0E001260 const GeoLayout castle_geo_001260[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_07028FD0), - GEO_DISPLAY_LIST(LAYER_ALPHA, inside_castle_seg7_dl_07029578), - GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_0702A650), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT_DECAL, inside_castle_seg7_dl_0702AA10), - GEO_DISPLAY_LIST(LAYER_ALPHA, inside_castle_seg7_dl_0702AB20), - GEO_ASM( 0, geo_exec_inside_castle_light), - GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_07034D88), - GEO_DISPLAY_LIST(LAYER_ALPHA, inside_castle_seg7_dl_07035178), - GEO_DISPLAY_LIST(LAYER_ALPHA, inside_castle_seg7_dl_07035288), - GEO_ASM( 0, geo_painting_update), - GEO_ASM(258, geo_painting_draw), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_07028FD0), + GEO_DISPLAY_LIST(LAYER_ALPHA, inside_castle_seg7_dl_07029578), + GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_0702A650), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT_DECAL, inside_castle_seg7_dl_0702AA10), + GEO_DISPLAY_LIST(LAYER_ALPHA, inside_castle_seg7_dl_0702AB20), + GEO_ASM( 0, geo_exec_inside_castle_light), + GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_07034D88), + GEO_DISPLAY_LIST(LAYER_ALPHA, inside_castle_seg7_dl_07035178), + GEO_DISPLAY_LIST(LAYER_ALPHA, inside_castle_seg7_dl_07035288), + GEO_ASM( 0, geo_painting_update), + GEO_ASM(258, geo_painting_draw), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x0E0012C8 const GeoLayout castle_geo_0012C8[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_07028FD0), - GEO_DISPLAY_LIST(LAYER_ALPHA, inside_castle_seg7_dl_07029578), - GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_0702A650), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT_DECAL, inside_castle_seg7_dl_0702AA10), - GEO_DISPLAY_LIST(LAYER_ALPHA, inside_castle_seg7_dl_0702AB20), - GEO_ASM( 0, geo_exec_inside_castle_light), - GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_07036D88), - GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_07037988), - GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_07037BF8), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, inside_castle_seg7_dl_07037DE8), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, dl_castle_aquarium_light), - GEO_DISPLAY_LIST(LAYER_ALPHA, inside_castle_seg7_dl_07038350), - GEO_ASM( 0, geo_painting_update), - GEO_ASM(PAINTING_ID(3, 1), geo_painting_draw), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_07028FD0), + GEO_DISPLAY_LIST(LAYER_ALPHA, inside_castle_seg7_dl_07029578), + GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_0702A650), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT_DECAL, inside_castle_seg7_dl_0702AA10), + GEO_DISPLAY_LIST(LAYER_ALPHA, inside_castle_seg7_dl_0702AB20), + GEO_ASM( 0, geo_exec_inside_castle_light), + GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_07036D88), + GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_07037988), + GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_07037BF8), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, inside_castle_seg7_dl_07037DE8), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, dl_castle_aquarium_light), + GEO_DISPLAY_LIST(LAYER_ALPHA, inside_castle_seg7_dl_07038350), + GEO_ASM( 0, geo_painting_update), + GEO_ASM(PAINTING_ID(3, 1), geo_painting_draw), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x0E001348 const GeoLayout castle_geo_001348[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_07028FD0), - GEO_DISPLAY_LIST(LAYER_ALPHA, inside_castle_seg7_dl_07029578), - GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_0702A650), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT_DECAL, inside_castle_seg7_dl_0702AA10), - GEO_DISPLAY_LIST(LAYER_ALPHA, inside_castle_seg7_dl_0702AB20), - GEO_ASM( 0, geo_exec_inside_castle_light), - GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_0703A6C8), - GEO_DISPLAY_LIST(LAYER_ALPHA, inside_castle_seg7_dl_0703A808), - GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_070234C0), - GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_07023520), - GEO_ASM( 0, geo_painting_update), - GEO_ASM(PAINTING_ID(1, 1), geo_painting_draw), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_07028FD0), + GEO_DISPLAY_LIST(LAYER_ALPHA, inside_castle_seg7_dl_07029578), + GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_0702A650), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT_DECAL, inside_castle_seg7_dl_0702AA10), + GEO_DISPLAY_LIST(LAYER_ALPHA, inside_castle_seg7_dl_0702AB20), + GEO_ASM( 0, geo_exec_inside_castle_light), + GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_0703A6C8), + GEO_DISPLAY_LIST(LAYER_ALPHA, inside_castle_seg7_dl_0703A808), + GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_070234C0), + GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_07023520), + GEO_ASM( 0, geo_painting_update), + GEO_ASM(PAINTING_ID(1, 1), geo_painting_draw), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x0E0013B8 const GeoLayout castle_geo_0013B8[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_07028FD0), - GEO_DISPLAY_LIST(LAYER_ALPHA, inside_castle_seg7_dl_07029578), - GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_0702A650), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT_DECAL, inside_castle_seg7_dl_0702AA10), - GEO_DISPLAY_LIST(LAYER_ALPHA, inside_castle_seg7_dl_0702AB20), - GEO_ASM(0, geo_exec_inside_castle_light), - GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_0703BA08), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_07028FD0), + GEO_DISPLAY_LIST(LAYER_ALPHA, inside_castle_seg7_dl_07029578), + GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_0702A650), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT_DECAL, inside_castle_seg7_dl_0702AA10), + GEO_DISPLAY_LIST(LAYER_ALPHA, inside_castle_seg7_dl_0702AB20), + GEO_ASM(0, geo_exec_inside_castle_light), + GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_0703BA08), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x0E001400 const GeoLayout castle_geo_001400[] = { - GEO_NODE_SCREEN_AREA(10, SCREEN_WIDTH/2, SCREEN_HEIGHT/2, SCREEN_WIDTH/2, SCREEN_HEIGHT/2), - GEO_OPEN_NODE(), - GEO_ZBUFFER(0), - GEO_OPEN_NODE(), - GEO_NODE_ORTHO(100), - GEO_OPEN_NODE(), - GEO_BACKGROUND_COLOR(0x0001), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ZBUFFER(1), - GEO_OPEN_NODE(), - GEO_CAMERA_FRUSTUM_WITH_FUNC(64, 50, 7000, geo_camera_fov), - GEO_OPEN_NODE(), - GEO_CAMERA(13, 0, 2000, 6000, 0, 0, 0, geo_camera_main), + GEO_NODE_SCREEN_AREA(10, SCREEN_WIDTH/2, SCREEN_HEIGHT/2, SCREEN_WIDTH/2, SCREEN_HEIGHT/2), + GEO_OPEN_NODE(), + GEO_ZBUFFER(0), + GEO_OPEN_NODE(), + GEO_NODE_ORTHO(100), GEO_OPEN_NODE(), - GEO_SWITCH_CASE(17, geo_switch_area), - GEO_OPEN_NODE(), - GEO_BRANCH(1, castle_geo_000F30), // 0x0E000F30 - GEO_BRANCH(1, castle_geo_000F70), // 0x0E000F70 - GEO_BRANCH(1, castle_geo_000F88), // 0x0E000F88 - GEO_BRANCH(1, castle_geo_000FA8), // 0x0E000FA8 - GEO_BRANCH(1, castle_geo_000FD0), // 0x0E000FD0 - GEO_BRANCH(1, castle_geo_001000), // 0x0E001000 - GEO_BRANCH(1, castle_geo_001038), // 0x0E001038 - GEO_BRANCH(1, castle_geo_001088), // 0x0E001088 - GEO_BRANCH(1, castle_geo_0010C8), // 0x0E0010C8 - GEO_BRANCH(1, castle_geo_001110), // 0x0E001110 - GEO_BRANCH(1, castle_geo_001158), // 0x0E001158 - GEO_BRANCH(1, castle_geo_0011A8), // 0x0E0011A8 - GEO_BRANCH(1, castle_geo_001200), // 0x0E001200 - GEO_BRANCH(1, castle_geo_001260), // 0x0E001260 - GEO_BRANCH(1, castle_geo_0012C8), // 0x0E0012C8 - GEO_BRANCH(1, castle_geo_001348), // 0x0E001348 - GEO_BRANCH(1, castle_geo_0013B8), // 0x0E0013B8 - GEO_CLOSE_NODE(), - GEO_RENDER_OBJ(), - GEO_ASM(0, geo_envfx_main), + GEO_BACKGROUND_COLOR(0x0001), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CLOSE_NODE(), + GEO_ZBUFFER(1), + GEO_OPEN_NODE(), + GEO_CAMERA_FRUSTUM_WITH_FUNC(64, 50, 7000, geo_camera_fov), + GEO_OPEN_NODE(), + GEO_CAMERA(13, 0, 2000, 6000, 0, 0, 0, geo_camera_main), + GEO_OPEN_NODE(), + GEO_SWITCH_CASE(17, geo_switch_area), + GEO_OPEN_NODE(), + GEO_BRANCH(1, castle_geo_000F30), // 0x0E000F30 + GEO_BRANCH(1, castle_geo_000F70), // 0x0E000F70 + GEO_BRANCH(1, castle_geo_000F88), // 0x0E000F88 + GEO_BRANCH(1, castle_geo_000FA8), // 0x0E000FA8 + GEO_BRANCH(1, castle_geo_000FD0), // 0x0E000FD0 + GEO_BRANCH(1, castle_geo_001000), // 0x0E001000 + GEO_BRANCH(1, castle_geo_001038), // 0x0E001038 + GEO_BRANCH(1, castle_geo_001088), // 0x0E001088 + GEO_BRANCH(1, castle_geo_0010C8), // 0x0E0010C8 + GEO_BRANCH(1, castle_geo_001110), // 0x0E001110 + GEO_BRANCH(1, castle_geo_001158), // 0x0E001158 + GEO_BRANCH(1, castle_geo_0011A8), // 0x0E0011A8 + GEO_BRANCH(1, castle_geo_001200), // 0x0E001200 + GEO_BRANCH(1, castle_geo_001260), // 0x0E001260 + GEO_BRANCH(1, castle_geo_0012C8), // 0x0E0012C8 + GEO_BRANCH(1, castle_geo_001348), // 0x0E001348 + GEO_BRANCH(1, castle_geo_0013B8), // 0x0E0013B8 + GEO_CLOSE_NODE(), + GEO_RENDER_OBJ(), + GEO_ASM(0, geo_envfx_main), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/castle_inside/areas/1/macro.inc.c b/levels/castle_inside/areas/1/macro.inc.c index cf28d237..fed0a607 100644 --- a/levels/castle_inside/areas/1/macro.inc.c +++ b/levels/castle_inside/areas/1/macro.inc.c @@ -1,16 +1,16 @@ // 0x07077764 - 0x070777DE const MacroObject inside_castle_seg7_area_1_macro_objs[] = { - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_sign_on_wall, /*yaw*/ 90, /*pos*/ 1178, 614, -2434, /*behParam*/ DIALOG_075), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_sign_on_wall, /*yaw*/ 270, /*pos*/ -3185, 205, -410, /*behParam*/ DIALOG_046), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_sign_on_wall, /*yaw*/ 270, /*pos*/ -3185, 205, -51, /*behParam*/ DIALOG_070), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_sign_on_wall, /*yaw*/ 180, /*pos*/ 435, 0, -1137, /*behParam*/ DIALOG_069), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_sign_on_wall, /*yaw*/ 45, /*pos*/ 1670, 307, -1144, /*behParam*/ DIALOG_147), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_sign_on_wall, /*yaw*/ 180, /*pos*/ -2278, -410, -3002, /*behParam*/ DIALOG_052), - MACRO_OBJECT(/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ -618, 388, -324), - MACRO_OBJECT(/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ -1430, 388, -324), - MACRO_OBJECT(/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ -724, 388, -324), - MACRO_OBJECT(/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ -1324, 388, -324), - MACRO_OBJECT(/*preset*/ macro_hidden_1up_trigger, /*yaw*/ 0, /*pos*/ 2005, 800, -1694), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_hidden_1up, /*yaw*/ 0, /*pos*/ 2036, 800, -1673, /*behParam*/ 1), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_sign_on_wall, /*yaw*/ 90, /*pos*/ 1178, 614, -2434, /*bhvParam*/ DIALOG_075), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_sign_on_wall, /*yaw*/ 270, /*pos*/ -3185, 205, -410, /*bhvParam*/ DIALOG_046), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_sign_on_wall, /*yaw*/ 270, /*pos*/ -3185, 205, -51, /*bhvParam*/ DIALOG_070), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_sign_on_wall, /*yaw*/ 180, /*pos*/ 435, 0, -1137, /*bhvParam*/ DIALOG_069), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_sign_on_wall, /*yaw*/ 45, /*pos*/ 1670, 307, -1144, /*bhvParam*/ DIALOG_147), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_sign_on_wall, /*yaw*/ 180, /*pos*/ -2278, -410, -3002, /*bhvParam*/ DIALOG_052), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ -618, 388, -324), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ -1430, 388, -324), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ -724, 388, -324), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ -1324, 388, -324), + MACRO_OBJECT (/*preset*/ macro_hidden_1up_trigger, /*yaw*/ 0, /*pos*/ 2005, 800, -1694), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_hidden_1up, /*yaw*/ 0, /*pos*/ 2036, 800, -1673, /*bhvParam*/ 1), MACRO_OBJECT_END(), }; diff --git a/levels/castle_inside/areas/1/room.inc.c b/levels/castle_inside/areas/1/room.inc.c index 055c00c2..fb101699 100644 --- a/levels/castle_inside/areas/1/room.inc.c +++ b/levels/castle_inside/areas/1/room.inc.c @@ -1,5 +1,5 @@ // 0x0707782C - 0x0707808C -const u8 inside_castle_seg7_area_1_rooms[] = { +const RoomData inside_castle_seg7_area_1_rooms[] = { 1, 9, 9, 1, 9, 9, 9, 9, // 0-7 9, 9, 1, 1, 1, 9, 9, 17, // 8-15 1, 9, 9, 9, 9, 9, 17, 9, // 16-23 diff --git a/levels/castle_inside/areas/2/geo.inc.c b/levels/castle_inside/areas/2/geo.inc.c index 29748a6e..5433d088 100644 --- a/levels/castle_inside/areas/2/geo.inc.c +++ b/levels/castle_inside/areas/2/geo.inc.c @@ -1,200 +1,200 @@ // 0x0E001560 const GeoLayout castle_geo_001560[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_0703E6F0), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_0703E6F0), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x0E001578 const GeoLayout castle_geo_001578[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_07043028), - GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_07043B48), - GEO_DISPLAY_LIST(LAYER_ALPHA, inside_castle_seg7_dl_07043CD8), - GEO_ASM( 0, geo_painting_update), - GEO_ASM(PAINTING_ID(8, 1), geo_painting_draw), - GEO_ASM(PAINTING_ID(10, 1), geo_painting_draw), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_07043028), + GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_07043B48), + GEO_DISPLAY_LIST(LAYER_ALPHA, inside_castle_seg7_dl_07043CD8), + GEO_ASM( 0, geo_painting_update), + GEO_ASM(PAINTING_ID(8, 1), geo_painting_draw), + GEO_ASM(PAINTING_ID(10, 1), geo_painting_draw), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x0E0015B8 const GeoLayout castle_geo_0015B8[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_0704A0E8), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, inside_castle_seg7_dl_0704A2E0), - GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_0704AA98), - GEO_ASM( 0, geo_painting_update), - GEO_ASM(PAINTING_ID(12, 1), geo_painting_draw), - GEO_ASM( 0, geo_render_mirror_mario), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_0704A0E8), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, inside_castle_seg7_dl_0704A2E0), + GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_0704AA98), + GEO_ASM( 0, geo_painting_update), + GEO_ASM(PAINTING_ID(12, 1), geo_painting_draw), + GEO_ASM( 0, geo_render_mirror_mario), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x0E0015F8 const GeoLayout castle_geo_0015F8[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_0704C7D8), - GEO_ASM( 0, geo_painting_update), - GEO_ASM(PAINTING_ID(9, 1), geo_painting_draw), - GEO_ASM(PAINTING_ID(13, 1), geo_painting_draw), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_0704C7D8), + GEO_ASM( 0, geo_painting_update), + GEO_ASM(PAINTING_ID(9, 1), geo_painting_draw), + GEO_ASM(PAINTING_ID(13, 1), geo_painting_draw), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x0E001628 const GeoLayout castle_geo_001628[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_07050938), - GEO_DISPLAY_LIST(LAYER_ALPHA, inside_castle_seg7_dl_07051678), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, inside_castle_seg7_dl_070519C8), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, inside_castle_seg7_dl_07051B60), - GEO_ASM( 0, geo_painting_update), - GEO_ASM(PAINTING_ID(11, 1), geo_painting_draw), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_07050938), + GEO_DISPLAY_LIST(LAYER_ALPHA, inside_castle_seg7_dl_07051678), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, inside_castle_seg7_dl_070519C8), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, inside_castle_seg7_dl_07051B60), + GEO_ASM( 0, geo_painting_update), + GEO_ASM(PAINTING_ID(11, 1), geo_painting_draw), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x0E001668 const GeoLayout castle_geo_001668[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_070558D0), - GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_070572A0), - GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_07057F00), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_070558D0), + GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_070572A0), + GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_07057F00), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x0E001690 const GeoLayout castle_geo_001690[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_0703E6F0), - GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_07043028), - GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_07043B48), - GEO_DISPLAY_LIST(LAYER_ALPHA, inside_castle_seg7_dl_07043CD8), - GEO_ASM( 0, geo_painting_update), - GEO_ASM(PAINTING_ID(8, 1), geo_painting_draw), - GEO_ASM(PAINTING_ID(10, 1), geo_painting_draw), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_0703E6F0), + GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_07043028), + GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_07043B48), + GEO_DISPLAY_LIST(LAYER_ALPHA, inside_castle_seg7_dl_07043CD8), + GEO_ASM( 0, geo_painting_update), + GEO_ASM(PAINTING_ID(8, 1), geo_painting_draw), + GEO_ASM(PAINTING_ID(10, 1), geo_painting_draw), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x0E0016D8 const GeoLayout castle_geo_0016D8[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_07043028), - GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_07043B48), - GEO_DISPLAY_LIST(LAYER_ALPHA, inside_castle_seg7_dl_07043CD8), - GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_0704A0E8), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, inside_castle_seg7_dl_0704A2E0), - GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_0704AA98), - GEO_ASM( 0, geo_painting_update), - GEO_ASM(PAINTING_ID(8, 1), geo_painting_draw), - GEO_ASM(PAINTING_ID(10, 1), geo_painting_draw), - GEO_ASM(PAINTING_ID(12, 1), geo_painting_draw), - GEO_ASM( 0, geo_render_mirror_mario), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_07043028), + GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_07043B48), + GEO_DISPLAY_LIST(LAYER_ALPHA, inside_castle_seg7_dl_07043CD8), + GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_0704A0E8), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, inside_castle_seg7_dl_0704A2E0), + GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_0704AA98), + GEO_ASM( 0, geo_painting_update), + GEO_ASM(PAINTING_ID(8, 1), geo_painting_draw), + GEO_ASM(PAINTING_ID(10, 1), geo_painting_draw), + GEO_ASM(PAINTING_ID(12, 1), geo_painting_draw), + GEO_ASM( 0, geo_render_mirror_mario), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x0E001740 const GeoLayout castle_geo_001740[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_07043028), - GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_07043B48), - GEO_DISPLAY_LIST(LAYER_ALPHA, inside_castle_seg7_dl_07043CD8), - GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_0704C7D8), - GEO_ASM( 0, geo_painting_update), - GEO_ASM(PAINTING_ID(8, 1), geo_painting_draw), - GEO_ASM(PAINTING_ID(9, 1), geo_painting_draw), - GEO_ASM(PAINTING_ID(10, 1), geo_painting_draw), - GEO_ASM(PAINTING_ID(13, 1), geo_painting_draw), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_07043028), + GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_07043B48), + GEO_DISPLAY_LIST(LAYER_ALPHA, inside_castle_seg7_dl_07043CD8), + GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_0704C7D8), + GEO_ASM( 0, geo_painting_update), + GEO_ASM(PAINTING_ID(8, 1), geo_painting_draw), + GEO_ASM(PAINTING_ID(9, 1), geo_painting_draw), + GEO_ASM(PAINTING_ID(10, 1), geo_painting_draw), + GEO_ASM(PAINTING_ID(13, 1), geo_painting_draw), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x0E001798 const GeoLayout castle_geo_001798[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_07043028), - GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_07043B48), - GEO_DISPLAY_LIST(LAYER_ALPHA, inside_castle_seg7_dl_07043CD8), - GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_07050938), - GEO_DISPLAY_LIST(LAYER_ALPHA, inside_castle_seg7_dl_07051678), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, inside_castle_seg7_dl_070519C8), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, inside_castle_seg7_dl_07051B60), - GEO_ASM( 0, geo_painting_update), - GEO_ASM(PAINTING_ID(8, 1), geo_painting_draw), - GEO_ASM(PAINTING_ID(10, 1), geo_painting_draw), - GEO_ASM(PAINTING_ID(11, 1), geo_painting_draw), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_07043028), + GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_07043B48), + GEO_DISPLAY_LIST(LAYER_ALPHA, inside_castle_seg7_dl_07043CD8), + GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_07050938), + GEO_DISPLAY_LIST(LAYER_ALPHA, inside_castle_seg7_dl_07051678), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, inside_castle_seg7_dl_070519C8), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, inside_castle_seg7_dl_07051B60), + GEO_ASM( 0, geo_painting_update), + GEO_ASM(PAINTING_ID(8, 1), geo_painting_draw), + GEO_ASM(PAINTING_ID(10, 1), geo_painting_draw), + GEO_ASM(PAINTING_ID(11, 1), geo_painting_draw), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x0E001800 const GeoLayout castle_geo_001800[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_07050938), - GEO_DISPLAY_LIST(LAYER_ALPHA, inside_castle_seg7_dl_07051678), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, inside_castle_seg7_dl_070519C8), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, inside_castle_seg7_dl_07051B60), - GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_070558D0), - GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_070572A0), - GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_07057F00), - GEO_ASM( 0, geo_painting_update), - GEO_ASM(PAINTING_ID(11, 1), geo_painting_draw), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_07050938), + GEO_DISPLAY_LIST(LAYER_ALPHA, inside_castle_seg7_dl_07051678), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, inside_castle_seg7_dl_070519C8), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, inside_castle_seg7_dl_07051B60), + GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_070558D0), + GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_070572A0), + GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_07057F00), + GEO_ASM( 0, geo_painting_update), + GEO_ASM(PAINTING_ID(11, 1), geo_painting_draw), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x0E001858 const GeoLayout castle_geo_001858[] = { - GEO_NODE_SCREEN_AREA(10, SCREEN_WIDTH/2, SCREEN_HEIGHT/2, SCREEN_WIDTH/2, SCREEN_HEIGHT/2), - GEO_OPEN_NODE(), - GEO_ZBUFFER(0), - GEO_OPEN_NODE(), - GEO_NODE_ORTHO(100), - GEO_OPEN_NODE(), - GEO_BACKGROUND_COLOR(0x0001), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ZBUFFER(1), - GEO_OPEN_NODE(), - GEO_CAMERA_FRUSTUM_WITH_FUNC(64, 50, 8000, geo_camera_fov), - GEO_OPEN_NODE(), - GEO_CAMERA(4, 0, 2000, 6000, 0, 0, 0, geo_camera_main), + GEO_NODE_SCREEN_AREA(10, SCREEN_WIDTH/2, SCREEN_HEIGHT/2, SCREEN_WIDTH/2, SCREEN_HEIGHT/2), + GEO_OPEN_NODE(), + GEO_ZBUFFER(0), + GEO_OPEN_NODE(), + GEO_NODE_ORTHO(100), GEO_OPEN_NODE(), - GEO_SWITCH_CASE(11, geo_switch_area), - GEO_OPEN_NODE(), - GEO_BRANCH(1, castle_geo_001560), // 0x0E001560 - GEO_BRANCH(1, castle_geo_001578), // 0x0E001578 - GEO_BRANCH(1, castle_geo_0015B8), // 0x0E0015B8 - GEO_BRANCH(1, castle_geo_0015F8), // 0x0E0015F8 - GEO_BRANCH(1, castle_geo_001628), // 0x0E001628 - GEO_BRANCH(1, castle_geo_001668), // 0x0E001668 - GEO_BRANCH(1, castle_geo_001690), // 0x0E001690 - GEO_BRANCH(1, castle_geo_0016D8), // 0x0E0016D8 - GEO_BRANCH(1, castle_geo_001740), // 0x0E001740 - GEO_BRANCH(1, castle_geo_001798), // 0x0E001798 - GEO_BRANCH(1, castle_geo_001800), // 0x0E001800 - GEO_CLOSE_NODE(), - GEO_RENDER_OBJ(), - GEO_ASM(0, geo_envfx_main), + GEO_BACKGROUND_COLOR(0x0001), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CLOSE_NODE(), + GEO_ZBUFFER(1), + GEO_OPEN_NODE(), + GEO_CAMERA_FRUSTUM_WITH_FUNC(64, 50, 8000, geo_camera_fov), + GEO_OPEN_NODE(), + GEO_CAMERA(4, 0, 2000, 6000, 0, 0, 0, geo_camera_main), + GEO_OPEN_NODE(), + GEO_SWITCH_CASE(11, geo_switch_area), + GEO_OPEN_NODE(), + GEO_BRANCH(1, castle_geo_001560), // 0x0E001560 + GEO_BRANCH(1, castle_geo_001578), // 0x0E001578 + GEO_BRANCH(1, castle_geo_0015B8), // 0x0E0015B8 + GEO_BRANCH(1, castle_geo_0015F8), // 0x0E0015F8 + GEO_BRANCH(1, castle_geo_001628), // 0x0E001628 + GEO_BRANCH(1, castle_geo_001668), // 0x0E001668 + GEO_BRANCH(1, castle_geo_001690), // 0x0E001690 + GEO_BRANCH(1, castle_geo_0016D8), // 0x0E0016D8 + GEO_BRANCH(1, castle_geo_001740), // 0x0E001740 + GEO_BRANCH(1, castle_geo_001798), // 0x0E001798 + GEO_BRANCH(1, castle_geo_001800), // 0x0E001800 + GEO_CLOSE_NODE(), + GEO_RENDER_OBJ(), + GEO_ASM(0, geo_envfx_main), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/castle_inside/areas/2/macro.inc.c b/levels/castle_inside/areas/2/macro.inc.c index 5ae3bd18..12ed72b0 100644 --- a/levels/castle_inside/areas/2/macro.inc.c +++ b/levels/castle_inside/areas/2/macro.inc.c @@ -1,5 +1,5 @@ // 0x070777E0 - 0x070777EC const MacroObject inside_castle_seg7_area_2_macro_objs[] = { - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_sign_on_wall, /*yaw*/ 90, /*pos*/ 164, 1203, 2278, /*behParam*/ DIALOG_019), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_sign_on_wall, /*yaw*/ 90, /*pos*/ 164, 1203, 2278, /*bhvParam*/ DIALOG_019), MACRO_OBJECT_END(), }; diff --git a/levels/castle_inside/areas/2/pendulum/geo.inc.c b/levels/castle_inside/areas/2/pendulum/geo.inc.c index 19e4a400..d13fb854 100644 --- a/levels/castle_inside/areas/2/pendulum/geo.inc.c +++ b/levels/castle_inside/areas/2/pendulum/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E001518 const GeoLayout castle_geo_001518[] = { - GEO_CULLING_RADIUS(600), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_070512F8), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(600), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_070512F8), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/castle_inside/areas/2/room.inc.c b/levels/castle_inside/areas/2/room.inc.c index 4a8af19a..a2b40730 100644 --- a/levels/castle_inside/areas/2/room.inc.c +++ b/levels/castle_inside/areas/2/room.inc.c @@ -1,5 +1,5 @@ // 0x0707808C -const u8 inside_castle_seg7_area_2_rooms[] = { +const RoomData inside_castle_seg7_area_2_rooms[] = { 6, 6, 6, 6, 6, 6, 6, 6, // 2144-2151 6, 6, 6, 6, 6, 6, 6, 6, // 2152-2159 6, 6, 6, 6, 6, 6, 6, 6, // 2160-2167 diff --git a/levels/castle_inside/areas/3/collision.inc.c b/levels/castle_inside/areas/3/collision.inc.c index a74959bc..c74cfacb 100644 --- a/levels/castle_inside/areas/3/collision.inc.c +++ b/levels/castle_inside/areas/3/collision.inc.c @@ -2516,7 +2516,7 @@ const Collision inside_castle_seg7_area_3_collision[] = { SPECIAL_OBJECT_WITH_YAW(/*preset*/ special_wooden_door, /*pos*/ -332, -767, 205, /*yaw*/ 0), SPECIAL_OBJECT_WITH_YAW(/*preset*/ special_wooden_door, /*pos*/ 717, -1177, -869, /*yaw*/ 192), SPECIAL_OBJECT_WITH_YAW(/*preset*/ special_0stars_door, /*pos*/ 1126, -1074, -2661, /*yaw*/ 192), - SPECIAL_OBJECT_WITH_YAW_AND_PARAM(/*preset*/ special_metal_door_warp, /*pos*/ 7885, -1586, -511, /*yaw*/ 192, /*behParam2*/ 2), + SPECIAL_OBJECT_WITH_YAW_AND_PARAM(/*preset*/ special_metal_door_warp, /*pos*/ 7885, -1586, -511, /*yaw*/ 192, /*bhvParam2*/ 2), COL_WATER_BOX_INIT(3), COL_WATER_BOX(1, 973, -1279, 5786, 256, -1228), COL_WATER_BOX(0, -3225, -4146, 870, -255, -1228), diff --git a/levels/castle_inside/areas/3/geo.inc.c b/levels/castle_inside/areas/3/geo.inc.c index 70b295fe..56ffe57e 100644 --- a/levels/castle_inside/areas/3/geo.inc.c +++ b/levels/castle_inside/areas/3/geo.inc.c @@ -1,185 +1,185 @@ // 0x0E001958 const GeoLayout castle_geo_001958[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_0705E088), - GEO_DISPLAY_LIST(LAYER_ALPHA, inside_castle_seg7_dl_0705E2A0), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, inside_castle_seg7_dl_0705E450), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_0705E088), + GEO_DISPLAY_LIST(LAYER_ALPHA, inside_castle_seg7_dl_0705E2A0), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, inside_castle_seg7_dl_0705E450), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x0E001980 const GeoLayout castle_geo_001980[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_070616E8), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, inside_castle_seg7_dl_07061C20), - GEO_ASM( 0, geo_painting_update), - GEO_ASM( PAINTING_ID(4, 1), geo_painting_draw), - GEO_ASM( PAINTING_ID(5, 1), geo_painting_draw), - GEO_ASM( 0, geo_movtex_pause_control), - GEO_ASM(0x0600, geo_movtex_draw_water_regions), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_070616E8), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, inside_castle_seg7_dl_07061C20), + GEO_ASM( 0, geo_painting_update), + GEO_ASM( PAINTING_ID(4, 1), geo_painting_draw), + GEO_ASM( PAINTING_ID(5, 1), geo_painting_draw), + GEO_ASM( 0, geo_movtex_pause_control), + GEO_ASM(0x0600, geo_movtex_draw_water_regions), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x0E0019C8 const GeoLayout castle_geo_0019C8[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_07064B78), - GEO_DISPLAY_LIST(LAYER_ALPHA, inside_castle_seg7_dl_07064D58), - GEO_ASM(0, geo_painting_update), - GEO_ASM(PAINTING_ID(6, 1), geo_painting_draw), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_07064B78), + GEO_DISPLAY_LIST(LAYER_ALPHA, inside_castle_seg7_dl_07064D58), + GEO_ASM(0, geo_painting_update), + GEO_ASM(PAINTING_ID(6, 1), geo_painting_draw), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x0E0019F8 const GeoLayout castle_geo_0019F8[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_07066CE0), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, inside_castle_seg7_dl_07066E90), - GEO_DISPLAY_LIST(LAYER_ALPHA, inside_castle_seg7_dl_07066FA0), - GEO_ASM( 0, geo_movtex_pause_control), - GEO_ASM(0x0612, geo_movtex_draw_water_regions), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_07066CE0), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, inside_castle_seg7_dl_07066E90), + GEO_DISPLAY_LIST(LAYER_ALPHA, inside_castle_seg7_dl_07066FA0), + GEO_ASM( 0, geo_movtex_pause_control), + GEO_ASM(0x0612, geo_movtex_draw_water_regions), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x0E001A30 const GeoLayout castle_geo_001A30[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_07068850), - GEO_ASM( 0, geo_painting_update), - GEO_ASM(PAINTING_ID(7, 1), geo_painting_draw), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_07068850), + GEO_ASM( 0, geo_painting_update), + GEO_ASM(PAINTING_ID(7, 1), geo_painting_draw), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x0E001A58 const GeoLayout castle_geo_001A58[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_0705E088), - GEO_DISPLAY_LIST(LAYER_ALPHA, inside_castle_seg7_dl_0705E2A0), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, inside_castle_seg7_dl_0705E450), - GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_070616E8), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, inside_castle_seg7_dl_07061C20), - GEO_ASM( 0, geo_painting_update), - GEO_ASM( PAINTING_ID(4, 1), geo_painting_draw), - GEO_ASM( PAINTING_ID(5, 1), geo_painting_draw), - GEO_ASM( 0, geo_movtex_pause_control), - GEO_ASM(0x0600, geo_movtex_draw_water_regions), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_0705E088), + GEO_DISPLAY_LIST(LAYER_ALPHA, inside_castle_seg7_dl_0705E2A0), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, inside_castle_seg7_dl_0705E450), + GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_070616E8), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, inside_castle_seg7_dl_07061C20), + GEO_ASM( 0, geo_painting_update), + GEO_ASM( PAINTING_ID(4, 1), geo_painting_draw), + GEO_ASM( PAINTING_ID(5, 1), geo_painting_draw), + GEO_ASM( 0, geo_movtex_pause_control), + GEO_ASM(0x0600, geo_movtex_draw_water_regions), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x0E001AB8 const GeoLayout castle_geo_001AB8[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_0705E088), - GEO_DISPLAY_LIST(LAYER_ALPHA, inside_castle_seg7_dl_0705E2A0), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, inside_castle_seg7_dl_0705E450), - GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_07068850), - GEO_ASM( 0, geo_painting_update), - GEO_ASM(PAINTING_ID(7, 1), geo_painting_draw), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_0705E088), + GEO_DISPLAY_LIST(LAYER_ALPHA, inside_castle_seg7_dl_0705E2A0), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, inside_castle_seg7_dl_0705E450), + GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_07068850), + GEO_ASM( 0, geo_painting_update), + GEO_ASM(PAINTING_ID(7, 1), geo_painting_draw), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x0E001AF8 const GeoLayout castle_geo_001AF8[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_0705E088), - GEO_DISPLAY_LIST(LAYER_ALPHA, inside_castle_seg7_dl_0705E2A0), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, inside_castle_seg7_dl_0705E450), - GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_07066CE0), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, inside_castle_seg7_dl_07066E90), - GEO_DISPLAY_LIST(LAYER_ALPHA, inside_castle_seg7_dl_07066FA0), - GEO_ASM( 0, geo_movtex_pause_control), - GEO_ASM(0x0612, geo_movtex_draw_water_regions), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_0705E088), + GEO_DISPLAY_LIST(LAYER_ALPHA, inside_castle_seg7_dl_0705E2A0), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, inside_castle_seg7_dl_0705E450), + GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_07066CE0), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, inside_castle_seg7_dl_07066E90), + GEO_DISPLAY_LIST(LAYER_ALPHA, inside_castle_seg7_dl_07066FA0), + GEO_ASM( 0, geo_movtex_pause_control), + GEO_ASM(0x0612, geo_movtex_draw_water_regions), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x0E001B48 const GeoLayout castle_geo_001B48[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_070616E8), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, inside_castle_seg7_dl_07061C20), - GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_07066CE0), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, inside_castle_seg7_dl_07066E90), - GEO_DISPLAY_LIST(LAYER_ALPHA, inside_castle_seg7_dl_07066FA0), - GEO_ASM( 0, geo_painting_update), - GEO_ASM( PAINTING_ID(4, 1), geo_painting_draw), - GEO_ASM( PAINTING_ID(5, 1), geo_painting_draw), - GEO_ASM( 0, geo_movtex_pause_control), - GEO_ASM(0x0600, geo_movtex_draw_water_regions), - GEO_ASM(0x0612, geo_movtex_draw_water_regions), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_070616E8), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, inside_castle_seg7_dl_07061C20), + GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_07066CE0), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, inside_castle_seg7_dl_07066E90), + GEO_DISPLAY_LIST(LAYER_ALPHA, inside_castle_seg7_dl_07066FA0), + GEO_ASM( 0, geo_painting_update), + GEO_ASM( PAINTING_ID(4, 1), geo_painting_draw), + GEO_ASM( PAINTING_ID(5, 1), geo_painting_draw), + GEO_ASM( 0, geo_movtex_pause_control), + GEO_ASM(0x0600, geo_movtex_draw_water_regions), + GEO_ASM(0x0612, geo_movtex_draw_water_regions), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x0E001BB0 const GeoLayout castle_geo_001BB0[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_070616E8), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, inside_castle_seg7_dl_07061C20), - GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_07064B78), - GEO_DISPLAY_LIST(LAYER_ALPHA, inside_castle_seg7_dl_07064D58), - GEO_ASM( 0, geo_painting_update), - GEO_ASM( PAINTING_ID(4, 1), geo_painting_draw), - GEO_ASM( PAINTING_ID(5, 1), geo_painting_draw), - GEO_ASM( PAINTING_ID(6, 1), geo_painting_draw), - GEO_ASM( 0, geo_movtex_pause_control), - GEO_ASM(0x0600, geo_movtex_draw_water_regions), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_070616E8), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, inside_castle_seg7_dl_07061C20), + GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_07064B78), + GEO_DISPLAY_LIST(LAYER_ALPHA, inside_castle_seg7_dl_07064D58), + GEO_ASM( 0, geo_painting_update), + GEO_ASM( PAINTING_ID(4, 1), geo_painting_draw), + GEO_ASM( PAINTING_ID(5, 1), geo_painting_draw), + GEO_ASM( PAINTING_ID(6, 1), geo_painting_draw), + GEO_ASM( 0, geo_movtex_pause_control), + GEO_ASM(0x0600, geo_movtex_draw_water_regions), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x0E001C10 const GeoLayout castle_geo_001C10[] = { - GEO_NODE_SCREEN_AREA(10, SCREEN_WIDTH/2, SCREEN_HEIGHT/2, SCREEN_WIDTH/2, SCREEN_HEIGHT/2), - GEO_OPEN_NODE(), - GEO_ZBUFFER(0), - GEO_OPEN_NODE(), - GEO_NODE_ORTHO(100), - GEO_OPEN_NODE(), - GEO_BACKGROUND_COLOR(0x0001), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ZBUFFER(1), - GEO_OPEN_NODE(), - GEO_CAMERA_FRUSTUM_WITH_FUNC(64, 50, 6400, geo_camera_fov), - GEO_OPEN_NODE(), - GEO_CAMERA(4, 0, 2000, 6000, 0, 0, 0, geo_camera_main), + GEO_NODE_SCREEN_AREA(10, SCREEN_WIDTH/2, SCREEN_HEIGHT/2, SCREEN_WIDTH/2, SCREEN_HEIGHT/2), + GEO_OPEN_NODE(), + GEO_ZBUFFER(0), + GEO_OPEN_NODE(), + GEO_NODE_ORTHO(100), GEO_OPEN_NODE(), - GEO_SWITCH_CASE(10, geo_switch_area), - GEO_OPEN_NODE(), - GEO_BRANCH(1, castle_geo_001958), // 0x0E001958 - GEO_BRANCH(1, castle_geo_001980), // 0x0E001980 - GEO_BRANCH(1, castle_geo_0019C8), // 0x0E0019C8 - GEO_BRANCH(1, castle_geo_0019F8), // 0x0E0019F8 - GEO_BRANCH(1, castle_geo_001A30), // 0x0E001A30 - GEO_BRANCH(1, castle_geo_001A58), // 0x0E001A58 - GEO_BRANCH(1, castle_geo_001AB8), // 0x0E001AB8 - GEO_BRANCH(1, castle_geo_001AF8), // 0x0E001AF8 - GEO_BRANCH(1, castle_geo_001B48), // 0x0E001B48 - GEO_BRANCH(1, castle_geo_001BB0), // 0x0E001BB0 - GEO_CLOSE_NODE(), - GEO_RENDER_OBJ(), - GEO_ASM(0, geo_envfx_main), + GEO_BACKGROUND_COLOR(0x0001), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CLOSE_NODE(), + GEO_ZBUFFER(1), + GEO_OPEN_NODE(), + GEO_CAMERA_FRUSTUM_WITH_FUNC(64, 50, 6400, geo_camera_fov), + GEO_OPEN_NODE(), + GEO_CAMERA(4, 0, 2000, 6000, 0, 0, 0, geo_camera_main), + GEO_OPEN_NODE(), + GEO_SWITCH_CASE(10, geo_switch_area), + GEO_OPEN_NODE(), + GEO_BRANCH(1, castle_geo_001958), // 0x0E001958 + GEO_BRANCH(1, castle_geo_001980), // 0x0E001980 + GEO_BRANCH(1, castle_geo_0019C8), // 0x0E0019C8 + GEO_BRANCH(1, castle_geo_0019F8), // 0x0E0019F8 + GEO_BRANCH(1, castle_geo_001A30), // 0x0E001A30 + GEO_BRANCH(1, castle_geo_001A58), // 0x0E001A58 + GEO_BRANCH(1, castle_geo_001AB8), // 0x0E001AB8 + GEO_BRANCH(1, castle_geo_001AF8), // 0x0E001AF8 + GEO_BRANCH(1, castle_geo_001B48), // 0x0E001B48 + GEO_BRANCH(1, castle_geo_001BB0), // 0x0E001BB0 + GEO_CLOSE_NODE(), + GEO_RENDER_OBJ(), + GEO_ASM(0, geo_envfx_main), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/castle_inside/areas/3/macro.inc.c b/levels/castle_inside/areas/3/macro.inc.c index ab8212f7..c5fd9690 100644 --- a/levels/castle_inside/areas/3/macro.inc.c +++ b/levels/castle_inside/areas/3/macro.inc.c @@ -1,10 +1,10 @@ // 0x070777EC - 0x0707782A const MacroObject inside_castle_seg7_area_3_macro_objs[] = { - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_sign_on_wall, /*yaw*/ 0, /*pos*/ 6400, -1178, -1270, /*behParam*/ DIALOG_077), - MACRO_OBJECT(/*preset*/ macro_hidden_1up_trigger, /*yaw*/ 0, /*pos*/ 2130, -2508, -946), - MACRO_OBJECT(/*preset*/ macro_hidden_1up_trigger, /*yaw*/ 0, /*pos*/ 2130, -2508, -92), - MACRO_OBJECT(/*preset*/ macro_hidden_1up_trigger, /*yaw*/ 0, /*pos*/ 3515, -2508, -946), - MACRO_OBJECT(/*preset*/ macro_hidden_1up_trigger, /*yaw*/ 0, /*pos*/ 3515, -2508, -92), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_hidden_1up, /*yaw*/ 0, /*pos*/ 2861, -2508, -515, /*behParam*/ 4), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_sign_on_wall, /*yaw*/ 0, /*pos*/ 6400, -1178, -1270, /*bhvParam*/ DIALOG_077), + MACRO_OBJECT (/*preset*/ macro_hidden_1up_trigger, /*yaw*/ 0, /*pos*/ 2130, -2508, -946), + MACRO_OBJECT (/*preset*/ macro_hidden_1up_trigger, /*yaw*/ 0, /*pos*/ 2130, -2508, -92), + MACRO_OBJECT (/*preset*/ macro_hidden_1up_trigger, /*yaw*/ 0, /*pos*/ 3515, -2508, -946), + MACRO_OBJECT (/*preset*/ macro_hidden_1up_trigger, /*yaw*/ 0, /*pos*/ 3515, -2508, -92), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_hidden_1up, /*yaw*/ 0, /*pos*/ 2861, -2508, -515, /*bhvParam*/ 4), MACRO_OBJECT_END(), }; diff --git a/levels/castle_inside/areas/3/room.inc.c b/levels/castle_inside/areas/3/room.inc.c index 8802cd46..cecf412f 100644 --- a/levels/castle_inside/areas/3/room.inc.c +++ b/levels/castle_inside/areas/3/room.inc.c @@ -1,5 +1,5 @@ // 0x07078870 - 0x07078DE3 -const u8 inside_castle_seg7_area_3_rooms[] = { +const RoomData inside_castle_seg7_area_3_rooms[] = { 5, 5, 5, 5, 5, 5, 5, 5, // 0-7 5, 5, 5, 5, 5, 5, 5, 5, // 8-15 5, 5, 5, 5, 5, 5, 5, 5, // 16-23 diff --git a/levels/castle_inside/clock_hour_hand/geo.inc.c b/levels/castle_inside/clock_hour_hand/geo.inc.c index aa80186f..9b8de712 100644 --- a/levels/castle_inside/clock_hour_hand/geo.inc.c +++ b/levels/castle_inside/clock_hour_hand/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E001548 const GeoLayout castle_geo_001548[] = { - GEO_CULLING_RADIUS(300), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_07059190), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(300), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_07059190), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/castle_inside/clock_minute_hand/geo.inc.c b/levels/castle_inside/clock_minute_hand/geo.inc.c index 3f8baee6..f08aa526 100644 --- a/levels/castle_inside/clock_minute_hand/geo.inc.c +++ b/levels/castle_inside/clock_minute_hand/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E001530 const GeoLayout castle_geo_001530[] = { - GEO_CULLING_RADIUS(300), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_07058950), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(300), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_07058950), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/castle_inside/header.h b/levels/castle_inside/header.h index dfd63923..043e3383 100644 --- a/levels/castle_inside/header.h +++ b/levels/castle_inside/header.h @@ -141,9 +141,9 @@ extern const Collision inside_castle_seg7_collision_ddd_warp_2[]; extern const MacroObject inside_castle_seg7_area_1_macro_objs[]; extern const MacroObject inside_castle_seg7_area_2_macro_objs[]; extern const MacroObject inside_castle_seg7_area_3_macro_objs[]; -extern const u8 inside_castle_seg7_area_1_rooms[]; -extern const u8 inside_castle_seg7_area_2_rooms[]; -extern const u8 inside_castle_seg7_area_3_rooms[]; +extern const RoomData inside_castle_seg7_area_1_rooms[]; +extern const RoomData inside_castle_seg7_area_2_rooms[]; +extern const RoomData inside_castle_seg7_area_3_rooms[]; extern const Collision inside_castle_seg7_collision_floor_trap[]; extern const Collision inside_castle_seg7_collision_star_door[]; extern const Collision inside_castle_seg7_collision_water_level_pillar[]; diff --git a/levels/castle_inside/leveldata.c b/levels/castle_inside/leveldata.c index 7052031c..3f64fc2f 100644 --- a/levels/castle_inside/leveldata.c +++ b/levels/castle_inside/leveldata.c @@ -3,8 +3,8 @@ #include "surface_terrains.h" #include "moving_texture_macros.h" #include "level_misc_macros.h" -#include "macro_preset_names.h" -#include "special_preset_names.h" +#include "macro_presets.h" +#include "special_presets.h" #include "textures.h" #include "dialog_ids.h" diff --git a/levels/castle_inside/painting.inc.c b/levels/castle_inside/painting.inc.c index d668820f..096d2ebd 100644 --- a/levels/castle_inside/painting.inc.c +++ b/levels/castle_inside/painting.inc.c @@ -574,7 +574,7 @@ static const Lights1 inside_castle_seg7_lights_07022528 = gdSPDefLights1( // No gdSPDefLights1 macro defined because of odd different light value (0xff and 0xfa) static const Lights1 inside_castle_seg7_lights_07022540 = { {{ {0x40, 0x40, 0x80}, 0, {0x40, 0x40, 0x80}, 0} }, - {{{ {0x64, 0x64, 0xff}, 0, {0x64, 0x64, 0xfa}, 0, {0x28, 0x28, 0x28},0} }} + {{{ {0x64, 0x64, 0xff}, 0, {0x64, 0x64, 0xfa}, 0, {0x28, 0x28, 0x28},0} }} }; // 0x07022558 - 0x07022598 diff --git a/levels/castle_inside/script.c b/levels/castle_inside/script.c index 5d9ae4fb..d6d9eb3a 100644 --- a/levels/castle_inside/script.c +++ b/levels/castle_inside/script.c @@ -17,216 +17,216 @@ #include "levels/castle_inside/header.h" static const LevelScript script_func_local_1[] = { - WARP_NODE(/*id*/ 0x00, /*destLevel*/ LEVEL_CASTLE_GROUNDS, /*destArea*/ 0x01, /*destNode*/ 0x00, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0x01, /*destLevel*/ LEVEL_CASTLE_GROUNDS, /*destArea*/ 0x01, /*destNode*/ 0x01, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0x02, /*destLevel*/ LEVEL_CASTLE_COURTYARD, /*destArea*/ 0x01, /*destNode*/ 0x01, /*flags*/ WARP_NO_CHECKPOINT), - OBJECT(/*model*/ MODEL_CASTLE_STAR_DOOR_8_STARS, /*pos*/ -2706, 512, -1409, /*angle*/ 0, 45, 0, /*behParam*/ 0x08000000, /*beh*/ bhvStarDoor), - OBJECT(/*model*/ MODEL_CASTLE_STAR_DOOR_8_STARS, /*pos*/ -2598, 512, -1517, /*angle*/ 0, 225, 0, /*behParam*/ 0x08000000, /*beh*/ bhvStarDoor), - OBJECT(/*model*/ MODEL_CASTLE_KEY_DOOR, /*pos*/ -1100, 512, -1074, /*angle*/ 0, 0, 0, /*behParam*/ 0x01030000, /*beh*/ bhvDoorWarp), - OBJECT(/*model*/ MODEL_CASTLE_KEY_DOOR, /*pos*/ -946, 512, -1074, /*angle*/ 0, 180, 0, /*behParam*/ 0x01040000, /*beh*/ bhvDoorWarp), - OBJECT(/*model*/ MODEL_CASTLE_KEY_DOOR, /*pos*/ -1100, -1074, 922, /*angle*/ 0, 0, 0, /*behParam*/ 0x02050000, /*beh*/ bhvDoorWarp), - OBJECT(/*model*/ MODEL_CASTLE_KEY_DOOR, /*pos*/ -946, -1074, 922, /*angle*/ 0, 180, 0, /*behParam*/ 0x02060000, /*beh*/ bhvDoorWarp), - WARP_NODE(/*id*/ 0x03, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x02, /*destNode*/ 0x00, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0x04, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x02, /*destNode*/ 0x01, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0x05, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x03, /*destNode*/ 0x00, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0x06, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x03, /*destNode*/ 0x01, /*flags*/ WARP_NO_CHECKPOINT), - PAINTING_WARP_NODE(/*id*/ 0x00, /*destLevel*/ LEVEL_BOB, /*destArea*/ 0x01, /*destNode*/ 0x0A, /*flags*/ WARP_NO_CHECKPOINT), - PAINTING_WARP_NODE(/*id*/ 0x01, /*destLevel*/ LEVEL_BOB, /*destArea*/ 0x01, /*destNode*/ 0x0A, /*flags*/ WARP_NO_CHECKPOINT), - PAINTING_WARP_NODE(/*id*/ 0x02, /*destLevel*/ LEVEL_BOB, /*destArea*/ 0x01, /*destNode*/ 0x0A, /*flags*/ WARP_NO_CHECKPOINT), - PAINTING_WARP_NODE(/*id*/ 0x03, /*destLevel*/ LEVEL_CCM, /*destArea*/ 0x01, /*destNode*/ 0x0A, /*flags*/ WARP_NO_CHECKPOINT), - PAINTING_WARP_NODE(/*id*/ 0x04, /*destLevel*/ LEVEL_CCM, /*destArea*/ 0x01, /*destNode*/ 0x0A, /*flags*/ WARP_NO_CHECKPOINT), - PAINTING_WARP_NODE(/*id*/ 0x05, /*destLevel*/ LEVEL_CCM, /*destArea*/ 0x01, /*destNode*/ 0x0A, /*flags*/ WARP_NO_CHECKPOINT), - PAINTING_WARP_NODE(/*id*/ 0x06, /*destLevel*/ LEVEL_WF, /*destArea*/ 0x01, /*destNode*/ 0x0A, /*flags*/ WARP_NO_CHECKPOINT), - PAINTING_WARP_NODE(/*id*/ 0x07, /*destLevel*/ LEVEL_WF, /*destArea*/ 0x01, /*destNode*/ 0x0A, /*flags*/ WARP_NO_CHECKPOINT), - PAINTING_WARP_NODE(/*id*/ 0x08, /*destLevel*/ LEVEL_WF, /*destArea*/ 0x01, /*destNode*/ 0x0A, /*flags*/ WARP_NO_CHECKPOINT), - PAINTING_WARP_NODE(/*id*/ 0x09, /*destLevel*/ LEVEL_JRB, /*destArea*/ 0x01, /*destNode*/ 0x0A, /*flags*/ WARP_NO_CHECKPOINT), - PAINTING_WARP_NODE(/*id*/ 0x0A, /*destLevel*/ LEVEL_JRB, /*destArea*/ 0x01, /*destNode*/ 0x0A, /*flags*/ WARP_NO_CHECKPOINT), - PAINTING_WARP_NODE(/*id*/ 0x0B, /*destLevel*/ LEVEL_JRB, /*destArea*/ 0x01, /*destNode*/ 0x0A, /*flags*/ WARP_NO_CHECKPOINT), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 2013, 768, -2014, /*angle*/ 0, 0, 0, /*behParam*/ 0x000A0000, /*beh*/ bhvWarp), - WARP_NODE(/*id*/ 0x0A, /*destLevel*/ LEVEL_PSS, /*destArea*/ 0x01, /*destNode*/ 0x0A, /*flags*/ WARP_NO_CHECKPOINT), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -5513, 512, -4324, /*angle*/ 0, 0, 0, /*behParam*/ 0x300B0000, /*beh*/ bhvWarp), - WARP_NODE(/*id*/ 0x0B, /*destLevel*/ LEVEL_BITDW, /*destArea*/ 0x01, /*destNode*/ 0x0A, /*flags*/ WARP_NO_CHECKPOINT), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 1963, 819, 1280, /*angle*/ 0, 0, 0, /*behParam*/ 0x050C0000, /*beh*/ bhvWarp), - WARP_NODE(/*id*/ 0x0C, /*destLevel*/ LEVEL_SA, /*destArea*/ 0x01, /*destNode*/ 0x0A, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0xF2, /*destLevel*/ LEVEL_TOTWC, /*destArea*/ 0x01, /*destNode*/ 0x0A, /*flags*/ WARP_NO_CHECKPOINT), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -1024, 512, -650, /*angle*/ 0, 0, 0, /*behParam*/ 0x001E0000, /*beh*/ bhvInstantActiveWarp), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -1024, -50, 717, /*angle*/ 0, 180, 0, /*behParam*/ 0x001F0000, /*beh*/ bhvInstantActiveWarp), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -1024, 900, 717, /*angle*/ 0, 180, 0, /*behParam*/ 0x00200000, /*beh*/ bhvAirborneWarp), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -1024, 900, 717, /*angle*/ 0, 180, 0, /*behParam*/ 0x00210000, /*beh*/ bhvAirborneDeathWarp), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -1024, 900, 717, /*angle*/ 0, 180, 0, /*behParam*/ 0x00220000, /*beh*/ bhvHardAirKnockBackWarp), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -1024, 900, 717, /*angle*/ 0, 180, 0, /*behParam*/ 0x00230000, /*beh*/ bhvDeathWarp), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -5513, 512, -4324, /*angle*/ 0, -135, 0, /*behParam*/ 0x00240000, /*beh*/ bhvLaunchStarCollectWarp), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -5513, 512, -4324, /*angle*/ 0, -135, 0, /*behParam*/ 0x00250000, /*beh*/ bhvLaunchDeathWarp), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -1024, 900, 717, /*angle*/ 0, 0, 0, /*behParam*/ 0x00260000, /*beh*/ bhvAirborneStarCollectWarp), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 2816, 1200, -256, /*angle*/ 0, 90, 0, /*behParam*/ 0x00270000, /*beh*/ bhvAirborneStarCollectWarp), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 2816, 1200, -256, /*angle*/ 0, 270, 0, /*behParam*/ 0x00280000, /*beh*/ bhvDeathWarp), - WARP_NODE(/*id*/ 0x1E, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x01, /*destNode*/ 0x1E, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0x1F, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x01, /*destNode*/ 0x1F, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0x20, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x01, /*destNode*/ 0x20, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0x21, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x01, /*destNode*/ 0x21, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0x22, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x01, /*destNode*/ 0x22, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0x23, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x01, /*destNode*/ 0x23, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0x24, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x01, /*destNode*/ 0x24, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0x25, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x01, /*destNode*/ 0x25, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0x26, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x01, /*destNode*/ 0x26, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0x27, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x01, /*destNode*/ 0x27, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0x28, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x01, /*destNode*/ 0x28, /*flags*/ WARP_NO_CHECKPOINT), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -5422, 717, -461, /*angle*/ 0, 270, 0, /*behParam*/ 0x00320000, /*beh*/ bhvPaintingStarCollectWarp), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -2304, 0, -4552, /*angle*/ 0, 180, 0, /*behParam*/ 0x00330000, /*beh*/ bhvPaintingStarCollectWarp), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 256, 102, -4706, /*angle*/ 0, 180, 0, /*behParam*/ 0x00340000, /*beh*/ bhvPaintingStarCollectWarp), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 4501, 717, -230, /*angle*/ 0, 90, 0, /*behParam*/ 0x00350000, /*beh*/ bhvPaintingStarCollectWarp), - WARP_NODE(/*id*/ 0x32, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x01, /*destNode*/ 0x32, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0x33, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x01, /*destNode*/ 0x33, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0x34, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x01, /*destNode*/ 0x34, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0x35, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x01, /*destNode*/ 0x35, /*flags*/ WARP_NO_CHECKPOINT), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -5422, 717, -461, /*angle*/ 0, 270, 0, /*behParam*/ 0x00640000, /*beh*/ bhvPaintingDeathWarp), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -2304, 0, -4552, /*angle*/ 0, 180, 0, /*behParam*/ 0x00650000, /*beh*/ bhvPaintingDeathWarp), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 256, 102, -4706, /*angle*/ 0, 180, 0, /*behParam*/ 0x00660000, /*beh*/ bhvPaintingDeathWarp), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 4501, 717, -230, /*angle*/ 0, 90, 0, /*behParam*/ 0x00670000, /*beh*/ bhvPaintingDeathWarp), - WARP_NODE(/*id*/ 0x64, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x01, /*destNode*/ 0x64, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0x65, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x01, /*destNode*/ 0x65, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0x66, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x01, /*destNode*/ 0x66, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0x67, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x01, /*destNode*/ 0x67, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_00, /*destLevel*/ LEVEL_CASTLE_GROUNDS, /*destArea*/ 1, /*destNode*/ WARP_NODE_00, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_01, /*destLevel*/ LEVEL_CASTLE_GROUNDS, /*destArea*/ 1, /*destNode*/ WARP_NODE_01, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_02, /*destLevel*/ LEVEL_CASTLE_COURTYARD, /*destArea*/ 1, /*destNode*/ WARP_NODE_01, /*flags*/ WARP_NO_CHECKPOINT), + OBJECT(/*model*/ MODEL_CASTLE_STAR_DOOR_8_STARS, /*pos*/ -2706, 512, -1409, /*angle*/ 0, 45, 0, /*bhvParam*/ BPARAM1(8), /*bhv*/ bhvStarDoor), + OBJECT(/*model*/ MODEL_CASTLE_STAR_DOOR_8_STARS, /*pos*/ -2598, 512, -1517, /*angle*/ 0, 225, 0, /*bhvParam*/ BPARAM1(8), /*bhv*/ bhvStarDoor), + OBJECT(/*model*/ MODEL_CASTLE_KEY_DOOR, /*pos*/ -1100, 512, -1074, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(0x01) | BPARAM2(WARP_NODE_03), /*bhv*/ bhvDoorWarp), + OBJECT(/*model*/ MODEL_CASTLE_KEY_DOOR, /*pos*/ -946, 512, -1074, /*angle*/ 0, 180, 0, /*bhvParam*/ BPARAM1(0x01) | BPARAM2(WARP_NODE_04), /*bhv*/ bhvDoorWarp), + OBJECT(/*model*/ MODEL_CASTLE_KEY_DOOR, /*pos*/ -1100, -1074, 922, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(0x02) | BPARAM2(WARP_NODE_05), /*bhv*/ bhvDoorWarp), + OBJECT(/*model*/ MODEL_CASTLE_KEY_DOOR, /*pos*/ -946, -1074, 922, /*angle*/ 0, 180, 0, /*bhvParam*/ BPARAM1(0x02) | BPARAM2(WARP_NODE_06), /*bhv*/ bhvDoorWarp), + WARP_NODE(/*id*/ WARP_NODE_03, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 2, /*destNode*/ WARP_NODE_00, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_04, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 2, /*destNode*/ WARP_NODE_01, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_05, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 3, /*destNode*/ WARP_NODE_00, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_06, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 3, /*destNode*/ WARP_NODE_01, /*flags*/ WARP_NO_CHECKPOINT), + PAINTING_WARP_NODE(/*id*/ WARP_NODE_00, /*destLevel*/ LEVEL_BOB, /*destArea*/ 1, /*destNode*/ WARP_NODE_0A, /*flags*/ WARP_NO_CHECKPOINT), + PAINTING_WARP_NODE(/*id*/ WARP_NODE_01, /*destLevel*/ LEVEL_BOB, /*destArea*/ 1, /*destNode*/ WARP_NODE_0A, /*flags*/ WARP_NO_CHECKPOINT), + PAINTING_WARP_NODE(/*id*/ WARP_NODE_02, /*destLevel*/ LEVEL_BOB, /*destArea*/ 1, /*destNode*/ WARP_NODE_0A, /*flags*/ WARP_NO_CHECKPOINT), + PAINTING_WARP_NODE(/*id*/ WARP_NODE_03, /*destLevel*/ LEVEL_CCM, /*destArea*/ 1, /*destNode*/ WARP_NODE_0A, /*flags*/ WARP_NO_CHECKPOINT), + PAINTING_WARP_NODE(/*id*/ WARP_NODE_04, /*destLevel*/ LEVEL_CCM, /*destArea*/ 1, /*destNode*/ WARP_NODE_0A, /*flags*/ WARP_NO_CHECKPOINT), + PAINTING_WARP_NODE(/*id*/ WARP_NODE_05, /*destLevel*/ LEVEL_CCM, /*destArea*/ 1, /*destNode*/ WARP_NODE_0A, /*flags*/ WARP_NO_CHECKPOINT), + PAINTING_WARP_NODE(/*id*/ WARP_NODE_06, /*destLevel*/ LEVEL_WF, /*destArea*/ 1, /*destNode*/ WARP_NODE_0A, /*flags*/ WARP_NO_CHECKPOINT), + PAINTING_WARP_NODE(/*id*/ WARP_NODE_07, /*destLevel*/ LEVEL_WF, /*destArea*/ 1, /*destNode*/ WARP_NODE_0A, /*flags*/ WARP_NO_CHECKPOINT), + PAINTING_WARP_NODE(/*id*/ WARP_NODE_08, /*destLevel*/ LEVEL_WF, /*destArea*/ 1, /*destNode*/ WARP_NODE_0A, /*flags*/ WARP_NO_CHECKPOINT), + PAINTING_WARP_NODE(/*id*/ WARP_NODE_09, /*destLevel*/ LEVEL_JRB, /*destArea*/ 1, /*destNode*/ WARP_NODE_0A, /*flags*/ WARP_NO_CHECKPOINT), + PAINTING_WARP_NODE(/*id*/ WARP_NODE_0A, /*destLevel*/ LEVEL_JRB, /*destArea*/ 1, /*destNode*/ WARP_NODE_0A, /*flags*/ WARP_NO_CHECKPOINT), + PAINTING_WARP_NODE(/*id*/ WARP_NODE_0B, /*destLevel*/ LEVEL_JRB, /*destArea*/ 1, /*destNode*/ WARP_NODE_0A, /*flags*/ WARP_NO_CHECKPOINT), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 2013, 768, -2014, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(WARP_NODE_0A), /*bhv*/ bhvWarp), + WARP_NODE(/*id*/ WARP_NODE_0A, /*destLevel*/ LEVEL_PSS, /*destArea*/ 1, /*destNode*/ WARP_NODE_0A, /*flags*/ WARP_NO_CHECKPOINT), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ -5513, 512, -4324, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(0x30) | BPARAM2(WARP_NODE_0B), /*bhv*/ bhvWarp), + WARP_NODE(/*id*/ WARP_NODE_0B, /*destLevel*/ LEVEL_BITDW, /*destArea*/ 1, /*destNode*/ WARP_NODE_0A, /*flags*/ WARP_NO_CHECKPOINT), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 1963, 819, 1280, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(0x05) | BPARAM2(WARP_NODE_0C), /*bhv*/ bhvWarp), + WARP_NODE(/*id*/ WARP_NODE_0C, /*destLevel*/ LEVEL_SA, /*destArea*/ 1, /*destNode*/ WARP_NODE_0A, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_TOTWC, /*destLevel*/ LEVEL_TOTWC, /*destArea*/ 1, /*destNode*/ WARP_NODE_0A, /*flags*/ WARP_NO_CHECKPOINT), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ -1024, 512, -650, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(WARP_NODE_1E), /*bhv*/ bhvInstantActiveWarp), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ -1024, -50, 717, /*angle*/ 0, 180, 0, /*bhvParam*/ BPARAM2(WARP_NODE_1F), /*bhv*/ bhvInstantActiveWarp), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ -1024, 900, 717, /*angle*/ 0, 180, 0, /*bhvParam*/ BPARAM2(WARP_NODE_20), /*bhv*/ bhvAirborneWarp), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ -1024, 900, 717, /*angle*/ 0, 180, 0, /*bhvParam*/ BPARAM2(WARP_NODE_21), /*bhv*/ bhvAirborneDeathWarp), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ -1024, 900, 717, /*angle*/ 0, 180, 0, /*bhvParam*/ BPARAM2(WARP_NODE_22), /*bhv*/ bhvHardAirKnockBackWarp), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ -1024, 900, 717, /*angle*/ 0, 180, 0, /*bhvParam*/ BPARAM2(WARP_NODE_23), /*bhv*/ bhvDeathWarp), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ -5513, 512, -4324, /*angle*/ 0, -135, 0, /*bhvParam*/ BPARAM2(WARP_NODE_24), /*bhv*/ bhvLaunchStarCollectWarp), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ -5513, 512, -4324, /*angle*/ 0, -135, 0, /*bhvParam*/ BPARAM2(WARP_NODE_25), /*bhv*/ bhvLaunchDeathWarp), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ -1024, 900, 717, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(WARP_NODE_26), /*bhv*/ bhvAirborneStarCollectWarp), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 2816, 1200, -256, /*angle*/ 0, 90, 0, /*bhvParam*/ BPARAM2(WARP_NODE_27), /*bhv*/ bhvAirborneStarCollectWarp), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 2816, 1200, -256, /*angle*/ 0, 270, 0, /*bhvParam*/ BPARAM2(WARP_NODE_28), /*bhv*/ bhvDeathWarp), + WARP_NODE(/*id*/ WARP_NODE_1E, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 1, /*destNode*/ WARP_NODE_1E, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_1F, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 1, /*destNode*/ WARP_NODE_1F, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_20, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 1, /*destNode*/ WARP_NODE_20, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_21, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 1, /*destNode*/ WARP_NODE_21, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_22, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 1, /*destNode*/ WARP_NODE_22, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_23, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 1, /*destNode*/ WARP_NODE_23, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_24, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 1, /*destNode*/ WARP_NODE_24, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_25, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 1, /*destNode*/ WARP_NODE_25, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_26, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 1, /*destNode*/ WARP_NODE_26, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_27, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 1, /*destNode*/ WARP_NODE_27, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_28, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 1, /*destNode*/ WARP_NODE_28, /*flags*/ WARP_NO_CHECKPOINT), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ -5422, 717, -461, /*angle*/ 0, 270, 0, /*bhvParam*/ BPARAM2(WARP_NODE_32), /*bhv*/ bhvPaintingStarCollectWarp), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ -2304, 0, -4552, /*angle*/ 0, 180, 0, /*bhvParam*/ BPARAM2(WARP_NODE_33), /*bhv*/ bhvPaintingStarCollectWarp), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 256, 102, -4706, /*angle*/ 0, 180, 0, /*bhvParam*/ BPARAM2(WARP_NODE_34), /*bhv*/ bhvPaintingStarCollectWarp), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 4501, 717, -230, /*angle*/ 0, 90, 0, /*bhvParam*/ BPARAM2(WARP_NODE_35), /*bhv*/ bhvPaintingStarCollectWarp), + WARP_NODE(/*id*/ WARP_NODE_32, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 1, /*destNode*/ WARP_NODE_32, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_33, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 1, /*destNode*/ WARP_NODE_33, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_34, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 1, /*destNode*/ WARP_NODE_34, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_35, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 1, /*destNode*/ WARP_NODE_35, /*flags*/ WARP_NO_CHECKPOINT), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ -5422, 717, -461, /*angle*/ 0, 270, 0, /*bhvParam*/ BPARAM2(WARP_NODE_64), /*bhv*/ bhvPaintingDeathWarp), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ -2304, 0, -4552, /*angle*/ 0, 180, 0, /*bhvParam*/ BPARAM2(WARP_NODE_65), /*bhv*/ bhvPaintingDeathWarp), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 256, 102, -4706, /*angle*/ 0, 180, 0, /*bhvParam*/ BPARAM2(WARP_NODE_66), /*bhv*/ bhvPaintingDeathWarp), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 4501, 717, -230, /*angle*/ 0, 90, 0, /*bhvParam*/ BPARAM2(WARP_NODE_67), /*bhv*/ bhvPaintingDeathWarp), + WARP_NODE(/*id*/ WARP_NODE_64, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 1, /*destNode*/ WARP_NODE_64, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_65, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 1, /*destNode*/ WARP_NODE_65, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_66, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 1, /*destNode*/ WARP_NODE_66, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_67, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 1, /*destNode*/ WARP_NODE_67, /*flags*/ WARP_NO_CHECKPOINT), RETURN(), }; static const LevelScript script_func_local_2[] = { - OBJECT(/*model*/ MODEL_CASTLE_KEY_DOOR, /*pos*/ -1100, 512, 3021, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvDoorWarp), - OBJECT(/*model*/ MODEL_CASTLE_KEY_DOOR, /*pos*/ -946, 512, 3021, /*angle*/ 0, 180, 0, /*behParam*/ 0x00010000, /*beh*/ bhvDoorWarp), - WARP_NODE(/*id*/ 0x00, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x01, /*destNode*/ 0x03, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0x01, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x01, /*destNode*/ 0x04, /*flags*/ WARP_NO_CHECKPOINT), - OBJECT(/*model*/ MODEL_CASTLE_STAR_DOOR_50_STARS, /*pos*/ -281, 2253, 4762, /*angle*/ 0, 0, 0, /*behParam*/ 0x32000000, /*beh*/ bhvStarDoor), - OBJECT(/*model*/ MODEL_CASTLE_STAR_DOOR_50_STARS, /*pos*/ -127, 2253, 4762, /*angle*/ 0, 180, 0, /*behParam*/ 0x32000000, /*beh*/ bhvStarDoor), - OBJECT(/*model*/ MODEL_CASTLE_STAR_DOOR_70_STARS, /*pos*/ -281, 3174, 3772, /*angle*/ 0, 0, 0, /*behParam*/ 0x46000000, /*beh*/ bhvStarDoor), - OBJECT(/*model*/ MODEL_CASTLE_STAR_DOOR_70_STARS, /*pos*/ -127, 3174, 3772, /*angle*/ 0, 180, 0, /*behParam*/ 0x46000000, /*beh*/ bhvStarDoor), - PAINTING_WARP_NODE(/*id*/ 0x18, /*destLevel*/ LEVEL_WDW, /*destArea*/ 0x01, /*destNode*/ 0x0A, /*flags*/ WARP_NO_CHECKPOINT), - PAINTING_WARP_NODE(/*id*/ 0x19, /*destLevel*/ LEVEL_WDW, /*destArea*/ 0x01, /*destNode*/ 0x0A, /*flags*/ WARP_NO_CHECKPOINT), - PAINTING_WARP_NODE(/*id*/ 0x1A, /*destLevel*/ LEVEL_WDW, /*destArea*/ 0x01, /*destNode*/ 0x0A, /*flags*/ WARP_NO_CHECKPOINT), - PAINTING_WARP_NODE(/*id*/ 0x1B, /*destLevel*/ LEVEL_THI, /*destArea*/ 0x02, /*destNode*/ 0x0A, /*flags*/ WARP_NO_CHECKPOINT), - PAINTING_WARP_NODE(/*id*/ 0x1C, /*destLevel*/ LEVEL_THI, /*destArea*/ 0x02, /*destNode*/ 0x0A, /*flags*/ WARP_NO_CHECKPOINT), - PAINTING_WARP_NODE(/*id*/ 0x1D, /*destLevel*/ LEVEL_THI, /*destArea*/ 0x02, /*destNode*/ 0x0A, /*flags*/ WARP_NO_CHECKPOINT), - PAINTING_WARP_NODE(/*id*/ 0x1E, /*destLevel*/ LEVEL_TTM, /*destArea*/ 0x01, /*destNode*/ 0x0A, /*flags*/ WARP_NO_CHECKPOINT), - PAINTING_WARP_NODE(/*id*/ 0x1F, /*destLevel*/ LEVEL_TTM, /*destArea*/ 0x01, /*destNode*/ 0x0A, /*flags*/ WARP_NO_CHECKPOINT), - PAINTING_WARP_NODE(/*id*/ 0x20, /*destLevel*/ LEVEL_TTM, /*destArea*/ 0x01, /*destNode*/ 0x0A, /*flags*/ WARP_NO_CHECKPOINT), - PAINTING_WARP_NODE(/*id*/ 0x21, /*destLevel*/ LEVEL_TTC, /*destArea*/ 0x01, /*destNode*/ 0x0A, /*flags*/ WARP_NO_CHECKPOINT), - PAINTING_WARP_NODE(/*id*/ 0x22, /*destLevel*/ LEVEL_TTC, /*destArea*/ 0x01, /*destNode*/ 0x0A, /*flags*/ WARP_NO_CHECKPOINT), - PAINTING_WARP_NODE(/*id*/ 0x23, /*destLevel*/ LEVEL_TTC, /*destArea*/ 0x01, /*destNode*/ 0x0A, /*flags*/ WARP_NO_CHECKPOINT), - PAINTING_WARP_NODE(/*id*/ 0x24, /*destLevel*/ LEVEL_SL, /*destArea*/ 0x01, /*destNode*/ 0x0A, /*flags*/ WARP_NO_CHECKPOINT), - PAINTING_WARP_NODE(/*id*/ 0x25, /*destLevel*/ LEVEL_SL, /*destArea*/ 0x01, /*destNode*/ 0x0A, /*flags*/ WARP_NO_CHECKPOINT), - PAINTING_WARP_NODE(/*id*/ 0x26, /*destLevel*/ LEVEL_SL, /*destArea*/ 0x01, /*destNode*/ 0x0A, /*flags*/ WARP_NO_CHECKPOINT), - PAINTING_WARP_NODE(/*id*/ 0x27, /*destLevel*/ LEVEL_THI, /*destArea*/ 0x01, /*destNode*/ 0x0A, /*flags*/ WARP_NO_CHECKPOINT), - PAINTING_WARP_NODE(/*id*/ 0x28, /*destLevel*/ LEVEL_THI, /*destArea*/ 0x01, /*destNode*/ 0x0A, /*flags*/ WARP_NO_CHECKPOINT), - PAINTING_WARP_NODE(/*id*/ 0x29, /*destLevel*/ LEVEL_THI, /*destArea*/ 0x01, /*destNode*/ 0x0A, /*flags*/ WARP_NO_CHECKPOINT), - PAINTING_WARP_NODE(/*id*/ 0x2A, /*destLevel*/ LEVEL_RR, /*destArea*/ 0x01, /*destNode*/ 0x0A, /*flags*/ WARP_NO_CHECKPOINT), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 3002, 2816, 5886, /*angle*/ 0, 0, 0, /*behParam*/ 0x0F0A0000, /*beh*/ bhvWarp), - WARP_NODE(/*id*/ 0x0A, /*destLevel*/ LEVEL_WMOTR, /*destArea*/ 0x01, /*destNode*/ 0x0A, /*flags*/ WARP_NO_CHECKPOINT), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -230, 4813, -3352, /*angle*/ 0, 0, 0, /*behParam*/ 0x0F0B0000, /*beh*/ bhvWarp), - WARP_NODE(/*id*/ 0x0B, /*destLevel*/ LEVEL_BITS, /*destArea*/ 0x01, /*destNode*/ 0x0A, /*flags*/ WARP_NO_CHECKPOINT), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -659, 1613, -350, /*angle*/ 0, 180, 0, /*behParam*/ 0x00320000, /*beh*/ bhvPaintingStarCollectWarp), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -4693, 2157, 1828, /*angle*/ 0, 270, 0, /*behParam*/ 0x00330000, /*beh*/ bhvAirborneStarCollectWarp), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -675, 1400, 3870, /*angle*/ 0, 0, 0, /*behParam*/ 0x00340000, /*beh*/ bhvPaintingStarCollectWarp), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -205, 2918, 7300, /*angle*/ 0, 0, 0, /*behParam*/ 0x00350000, /*beh*/ bhvPaintingStarCollectWarp), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 3538, 1766, -400, /*angle*/ 0, 180, 0, /*behParam*/ 0x00360000, /*beh*/ bhvPaintingStarCollectWarp), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -4693, 2157, 1828, /*angle*/ 0, 270, 0, /*behParam*/ 0x00370000, /*beh*/ bhvAirborneStarCollectWarp), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 3002, 2816, 5886, /*angle*/ 0, 90, 0, /*behParam*/ 0x00380000, /*beh*/ bhvLaunchStarCollectWarp), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -3412, 2816, 5886, /*angle*/ 0, 270, 0, /*behParam*/ 0x003A0000, /*beh*/ bhvLaunchStarCollectWarp), - WARP_NODE(/*id*/ 0x32, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x02, /*destNode*/ 0x32, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0x33, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x02, /*destNode*/ 0x33, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0x34, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x02, /*destNode*/ 0x34, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0x35, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x02, /*destNode*/ 0x35, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0x36, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x02, /*destNode*/ 0x36, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0x37, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x02, /*destNode*/ 0x37, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0x38, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x02, /*destNode*/ 0x38, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0x3A, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x02, /*destNode*/ 0x3A, /*flags*/ WARP_NO_CHECKPOINT), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -659, 1613, -350, /*angle*/ 0, 180, 0, /*behParam*/ 0x00640000, /*beh*/ bhvPaintingDeathWarp), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -4693, 2157, 1828, /*angle*/ 0, 270, 0, /*behParam*/ 0x00650000, /*beh*/ bhvDeathWarp), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -675, 1400, 3870, /*angle*/ 0, 0, 0, /*behParam*/ 0x00660000, /*beh*/ bhvPaintingDeathWarp), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -205, 2918, 7300, /*angle*/ 0, 0, 0, /*behParam*/ 0x00670000, /*beh*/ bhvPaintingDeathWarp), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 3538, 1766, -400, /*angle*/ 0, 180, 0, /*behParam*/ 0x00680000, /*beh*/ bhvPaintingDeathWarp), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -4693, 2157, 1828, /*angle*/ 0, 270, 0, /*behParam*/ 0x00690000, /*beh*/ bhvDeathWarp), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -230, 4813, -3352, /*angle*/ 0, 180, 0, /*behParam*/ 0x006B0000, /*beh*/ bhvLaunchDeathWarp), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -3412, 2816, 5886, /*angle*/ 0, 270, 0, /*behParam*/ 0x006C0000, /*beh*/ bhvLaunchDeathWarp), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 3002, 2816, 5886, /*angle*/ 0, 90, 0, /*behParam*/ 0x006D0000, /*beh*/ bhvLaunchDeathWarp), - WARP_NODE(/*id*/ 0x64, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x02, /*destNode*/ 0x64, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0x65, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x02, /*destNode*/ 0x65, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0x66, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x02, /*destNode*/ 0x66, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0x67, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x02, /*destNode*/ 0x67, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0x68, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x02, /*destNode*/ 0x68, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0x69, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x02, /*destNode*/ 0x69, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0x6B, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x02, /*destNode*/ 0x6B, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0x6C, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x02, /*destNode*/ 0x6C, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0x6D, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x02, /*destNode*/ 0x6D, /*flags*/ WARP_NO_CHECKPOINT), + OBJECT(/*model*/ MODEL_CASTLE_KEY_DOOR, /*pos*/ -1100, 512, 3021, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(WARP_NODE_00), /*bhv*/ bhvDoorWarp), + OBJECT(/*model*/ MODEL_CASTLE_KEY_DOOR, /*pos*/ -946, 512, 3021, /*angle*/ 0, 180, 0, /*bhvParam*/ BPARAM2(WARP_NODE_01), /*bhv*/ bhvDoorWarp), + WARP_NODE(/*id*/ WARP_NODE_00, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 1, /*destNode*/ WARP_NODE_03, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_01, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 1, /*destNode*/ WARP_NODE_04, /*flags*/ WARP_NO_CHECKPOINT), + OBJECT(/*model*/ MODEL_CASTLE_STAR_DOOR_50_STARS, /*pos*/ -281, 2253, 4762, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(50), /*bhv*/ bhvStarDoor), + OBJECT(/*model*/ MODEL_CASTLE_STAR_DOOR_50_STARS, /*pos*/ -127, 2253, 4762, /*angle*/ 0, 180, 0, /*bhvParam*/ BPARAM1(50), /*bhv*/ bhvStarDoor), + OBJECT(/*model*/ MODEL_CASTLE_STAR_DOOR_70_STARS, /*pos*/ -281, 3174, 3772, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(70), /*bhv*/ bhvStarDoor), + OBJECT(/*model*/ MODEL_CASTLE_STAR_DOOR_70_STARS, /*pos*/ -127, 3174, 3772, /*angle*/ 0, 180, 0, /*bhvParam*/ BPARAM1(70), /*bhv*/ bhvStarDoor), + PAINTING_WARP_NODE(/*id*/ WARP_NODE_18, /*destLevel*/ LEVEL_WDW, /*destArea*/ 1, /*destNode*/ WARP_NODE_0A, /*flags*/ WARP_NO_CHECKPOINT), + PAINTING_WARP_NODE(/*id*/ WARP_NODE_19, /*destLevel*/ LEVEL_WDW, /*destArea*/ 1, /*destNode*/ WARP_NODE_0A, /*flags*/ WARP_NO_CHECKPOINT), + PAINTING_WARP_NODE(/*id*/ WARP_NODE_1A, /*destLevel*/ LEVEL_WDW, /*destArea*/ 1, /*destNode*/ WARP_NODE_0A, /*flags*/ WARP_NO_CHECKPOINT), + PAINTING_WARP_NODE(/*id*/ WARP_NODE_1B, /*destLevel*/ LEVEL_THI, /*destArea*/ 2, /*destNode*/ WARP_NODE_0A, /*flags*/ WARP_NO_CHECKPOINT), + PAINTING_WARP_NODE(/*id*/ WARP_NODE_1C, /*destLevel*/ LEVEL_THI, /*destArea*/ 2, /*destNode*/ WARP_NODE_0A, /*flags*/ WARP_NO_CHECKPOINT), + PAINTING_WARP_NODE(/*id*/ WARP_NODE_1D, /*destLevel*/ LEVEL_THI, /*destArea*/ 2, /*destNode*/ WARP_NODE_0A, /*flags*/ WARP_NO_CHECKPOINT), + PAINTING_WARP_NODE(/*id*/ WARP_NODE_1E, /*destLevel*/ LEVEL_TTM, /*destArea*/ 1, /*destNode*/ WARP_NODE_0A, /*flags*/ WARP_NO_CHECKPOINT), + PAINTING_WARP_NODE(/*id*/ WARP_NODE_1F, /*destLevel*/ LEVEL_TTM, /*destArea*/ 1, /*destNode*/ WARP_NODE_0A, /*flags*/ WARP_NO_CHECKPOINT), + PAINTING_WARP_NODE(/*id*/ WARP_NODE_20, /*destLevel*/ LEVEL_TTM, /*destArea*/ 1, /*destNode*/ WARP_NODE_0A, /*flags*/ WARP_NO_CHECKPOINT), + PAINTING_WARP_NODE(/*id*/ WARP_NODE_21, /*destLevel*/ LEVEL_TTC, /*destArea*/ 1, /*destNode*/ WARP_NODE_0A, /*flags*/ WARP_NO_CHECKPOINT), + PAINTING_WARP_NODE(/*id*/ WARP_NODE_22, /*destLevel*/ LEVEL_TTC, /*destArea*/ 1, /*destNode*/ WARP_NODE_0A, /*flags*/ WARP_NO_CHECKPOINT), + PAINTING_WARP_NODE(/*id*/ WARP_NODE_23, /*destLevel*/ LEVEL_TTC, /*destArea*/ 1, /*destNode*/ WARP_NODE_0A, /*flags*/ WARP_NO_CHECKPOINT), + PAINTING_WARP_NODE(/*id*/ WARP_NODE_24, /*destLevel*/ LEVEL_SL, /*destArea*/ 1, /*destNode*/ WARP_NODE_0A, /*flags*/ WARP_NO_CHECKPOINT), + PAINTING_WARP_NODE(/*id*/ WARP_NODE_25, /*destLevel*/ LEVEL_SL, /*destArea*/ 1, /*destNode*/ WARP_NODE_0A, /*flags*/ WARP_NO_CHECKPOINT), + PAINTING_WARP_NODE(/*id*/ WARP_NODE_26, /*destLevel*/ LEVEL_SL, /*destArea*/ 1, /*destNode*/ WARP_NODE_0A, /*flags*/ WARP_NO_CHECKPOINT), + PAINTING_WARP_NODE(/*id*/ WARP_NODE_27, /*destLevel*/ LEVEL_THI, /*destArea*/ 1, /*destNode*/ WARP_NODE_0A, /*flags*/ WARP_NO_CHECKPOINT), + PAINTING_WARP_NODE(/*id*/ WARP_NODE_28, /*destLevel*/ LEVEL_THI, /*destArea*/ 1, /*destNode*/ WARP_NODE_0A, /*flags*/ WARP_NO_CHECKPOINT), + PAINTING_WARP_NODE(/*id*/ WARP_NODE_29, /*destLevel*/ LEVEL_THI, /*destArea*/ 1, /*destNode*/ WARP_NODE_0A, /*flags*/ WARP_NO_CHECKPOINT), + PAINTING_WARP_NODE(/*id*/ WARP_NODE_2A, /*destLevel*/ LEVEL_RR, /*destArea*/ 1, /*destNode*/ WARP_NODE_0A, /*flags*/ WARP_NO_CHECKPOINT), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 3002, 2816, 5886, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(15) | BPARAM2(WARP_NODE_0A), /*bhv*/ bhvWarp), + WARP_NODE(/*id*/ WARP_NODE_0A, /*destLevel*/ LEVEL_WMOTR, /*destArea*/ 1, /*destNode*/ WARP_NODE_0A, /*flags*/ WARP_NO_CHECKPOINT), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ -230, 4813, -3352, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(15) | BPARAM2(WARP_NODE_0B), /*bhv*/ bhvWarp), + WARP_NODE(/*id*/ WARP_NODE_0B, /*destLevel*/ LEVEL_BITS, /*destArea*/ 1, /*destNode*/ WARP_NODE_0A, /*flags*/ WARP_NO_CHECKPOINT), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ -659, 1613, -350, /*angle*/ 0, 180, 0, /*bhvParam*/ BPARAM2(WARP_NODE_32), /*bhv*/ bhvPaintingStarCollectWarp), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ -4693, 2157, 1828, /*angle*/ 0, 270, 0, /*bhvParam*/ BPARAM2(WARP_NODE_33), /*bhv*/ bhvAirborneStarCollectWarp), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ -675, 1400, 3870, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(WARP_NODE_34), /*bhv*/ bhvPaintingStarCollectWarp), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ -205, 2918, 7300, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(WARP_NODE_35), /*bhv*/ bhvPaintingStarCollectWarp), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 3538, 1766, -400, /*angle*/ 0, 180, 0, /*bhvParam*/ BPARAM2(WARP_NODE_36), /*bhv*/ bhvPaintingStarCollectWarp), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ -4693, 2157, 1828, /*angle*/ 0, 270, 0, /*bhvParam*/ BPARAM2(WARP_NODE_37), /*bhv*/ bhvAirborneStarCollectWarp), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 3002, 2816, 5886, /*angle*/ 0, 90, 0, /*bhvParam*/ BPARAM2(WARP_NODE_38), /*bhv*/ bhvLaunchStarCollectWarp), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ -3412, 2816, 5886, /*angle*/ 0, 270, 0, /*bhvParam*/ BPARAM2(WARP_NODE_3A), /*bhv*/ bhvLaunchStarCollectWarp), + WARP_NODE(/*id*/ WARP_NODE_32, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 2, /*destNode*/ WARP_NODE_32, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_33, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 2, /*destNode*/ WARP_NODE_33, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_34, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 2, /*destNode*/ WARP_NODE_34, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_35, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 2, /*destNode*/ WARP_NODE_35, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_36, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 2, /*destNode*/ WARP_NODE_36, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_37, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 2, /*destNode*/ WARP_NODE_37, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_38, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 2, /*destNode*/ WARP_NODE_38, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(WARP_NODE_3A, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 2, /*destNode*/ WARP_NODE_3A, /*flags*/ WARP_NO_CHECKPOINT), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ -659, 1613, -350, /*angle*/ 0, 180, 0, /*bhvParam*/ BPARAM2(WARP_NODE_64), /*bhv*/ bhvPaintingDeathWarp), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ -4693, 2157, 1828, /*angle*/ 0, 270, 0, /*bhvParam*/ BPARAM2(WARP_NODE_65), /*bhv*/ bhvDeathWarp), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ -675, 1400, 3870, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(WARP_NODE_66), /*bhv*/ bhvPaintingDeathWarp), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ -205, 2918, 7300, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(WARP_NODE_67), /*bhv*/ bhvPaintingDeathWarp), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 3538, 1766, -400, /*angle*/ 0, 180, 0, /*bhvParam*/ BPARAM2(WARP_NODE_68), /*bhv*/ bhvPaintingDeathWarp), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ -4693, 2157, 1828, /*angle*/ 0, 270, 0, /*bhvParam*/ BPARAM2(WARP_NODE_69), /*bhv*/ bhvDeathWarp), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ -230, 4813, -3352, /*angle*/ 0, 180, 0, /*bhvParam*/ BPARAM2(WARP_NODE_6B), /*bhv*/ bhvLaunchDeathWarp), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ -3412, 2816, 5886, /*angle*/ 0, 270, 0, /*bhvParam*/ BPARAM2(WARP_NODE_6C), /*bhv*/ bhvLaunchDeathWarp), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 3002, 2816, 5886, /*angle*/ 0, 90, 0, /*bhvParam*/ BPARAM2(WARP_NODE_6D), /*bhv*/ bhvLaunchDeathWarp), + WARP_NODE(/*id*/ WARP_NODE_64, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 2, /*destNode*/ WARP_NODE_64, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_65, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 2, /*destNode*/ WARP_NODE_65, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_66, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 2, /*destNode*/ WARP_NODE_66, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_67, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 2, /*destNode*/ WARP_NODE_67, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_68, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 2, /*destNode*/ WARP_NODE_68, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_69, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 2, /*destNode*/ WARP_NODE_69, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_6B, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 2, /*destNode*/ WARP_NODE_6B, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_6C, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 2, /*destNode*/ WARP_NODE_6C, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_6D, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 2, /*destNode*/ WARP_NODE_6D, /*flags*/ WARP_NO_CHECKPOINT), RETURN(), }; static const LevelScript script_func_local_3[] = { - OBJECT(/*model*/ MODEL_CASTLE_KEY_DOOR, /*pos*/ -1100, -1074, 922, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvDoorWarp), - OBJECT(/*model*/ MODEL_CASTLE_KEY_DOOR, /*pos*/ -946, -1074, 922, /*angle*/ 0, 180, 0, /*behParam*/ 0x00010000, /*beh*/ bhvDoorWarp), - WARP_NODE(/*id*/ 0x00, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x01, /*destNode*/ 0x05, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0x01, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x01, /*destNode*/ 0x06, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0x02, /*destLevel*/ LEVEL_CASTLE_GROUNDS, /*destArea*/ 0x01, /*destNode*/ 0x02, /*flags*/ WARP_NO_CHECKPOINT), - OBJECT(/*model*/ MODEL_CASTLE_STAR_DOOR_30_STARS, /*pos*/ 307, -1074, 2074, /*angle*/ 0, 90, 0, /*behParam*/ 0x1E000000, /*beh*/ bhvStarDoor), - OBJECT(/*model*/ MODEL_CASTLE_STAR_DOOR_30_STARS, /*pos*/ 307, -1074, 1920, /*angle*/ 0, 270, 0, /*behParam*/ 0x1E000000, /*beh*/ bhvStarDoor), - PAINTING_WARP_NODE(/*id*/ 0x0C, /*destLevel*/ LEVEL_LLL, /*destArea*/ 0x01, /*destNode*/ 0x0A, /*flags*/ WARP_NO_CHECKPOINT), - PAINTING_WARP_NODE(/*id*/ 0x0D, /*destLevel*/ LEVEL_LLL, /*destArea*/ 0x01, /*destNode*/ 0x0A, /*flags*/ WARP_NO_CHECKPOINT), - PAINTING_WARP_NODE(/*id*/ 0x0E, /*destLevel*/ LEVEL_LLL, /*destArea*/ 0x01, /*destNode*/ 0x0A, /*flags*/ WARP_NO_CHECKPOINT), - PAINTING_WARP_NODE(/*id*/ 0x0F, /*destLevel*/ LEVEL_SSL, /*destArea*/ 0x01, /*destNode*/ 0x0A, /*flags*/ WARP_NO_CHECKPOINT), - PAINTING_WARP_NODE(/*id*/ 0x10, /*destLevel*/ LEVEL_SSL, /*destArea*/ 0x01, /*destNode*/ 0x0A, /*flags*/ WARP_NO_CHECKPOINT), - PAINTING_WARP_NODE(/*id*/ 0x11, /*destLevel*/ LEVEL_SSL, /*destArea*/ 0x01, /*destNode*/ 0x0A, /*flags*/ WARP_NO_CHECKPOINT), - PAINTING_WARP_NODE(/*id*/ 0x2A, /*destLevel*/ LEVEL_HMC, /*destArea*/ 0x01, /*destNode*/ 0x0A, /*flags*/ WARP_NO_CHECKPOINT), - PAINTING_WARP_NODE(/*id*/ 0x15, /*destLevel*/ LEVEL_DDD, /*destArea*/ 0x01, /*destNode*/ 0x0A, /*flags*/ WARP_NO_CHECKPOINT), - PAINTING_WARP_NODE(/*id*/ 0x16, /*destLevel*/ LEVEL_DDD, /*destArea*/ 0x01, /*destNode*/ 0x0A, /*flags*/ WARP_NO_CHECKPOINT), - PAINTING_WARP_NODE(/*id*/ 0x17, /*destLevel*/ LEVEL_DDD, /*destArea*/ 0x01, /*destNode*/ 0x0A, /*flags*/ WARP_NO_CHECKPOINT), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 4147, -1280, 1997, /*angle*/ 0, 0, 0, /*behParam*/ 0x0F180000, /*beh*/ bhvWarp), - WARP_NODE(/*id*/ 0x18, /*destLevel*/ LEVEL_BITFS, /*destArea*/ 0x01, /*destNode*/ 0x0A, /*flags*/ WARP_NO_CHECKPOINT), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -1382, -819, -4150, /*angle*/ 0, 180, 0, /*behParam*/ 0x00320000, /*beh*/ bhvPaintingStarCollectWarp), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -2918, -870, -875, /*angle*/ 0, 0, 0, /*behParam*/ 0x00330000, /*beh*/ bhvPaintingStarCollectWarp), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 2483, -1688, -2662, /*angle*/ 0, 270, 0, /*behParam*/ 0x00340000, /*beh*/ bhvLaunchStarCollectWarp), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 2381, -500, 2011, /*angle*/ 0, 90, 0, /*behParam*/ 0x00350000, /*beh*/ bhvAirborneStarCollectWarp), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 4147, -1100, 1997, /*angle*/ 0, 90, 0, /*behParam*/ 0x00360000, /*beh*/ bhvLaunchStarCollectWarp), - WARP_NODE(/*id*/ 0x32, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x03, /*destNode*/ 0x32, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0x33, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x03, /*destNode*/ 0x33, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0x34, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x03, /*destNode*/ 0x34, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0x35, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x03, /*destNode*/ 0x35, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0x36, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x03, /*destNode*/ 0x36, /*flags*/ WARP_NO_CHECKPOINT), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -1382, -819, -4150, /*angle*/ 0, 180, 0, /*behParam*/ 0x00640000, /*beh*/ bhvPaintingDeathWarp), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -2918, -870, -875, /*angle*/ 0, 0, 0, /*behParam*/ 0x00650000, /*beh*/ bhvPaintingDeathWarp), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 2483, -1688, -2662, /*angle*/ 0, 270, 0, /*behParam*/ 0x00660000, /*beh*/ bhvLaunchDeathWarp), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 2381, -500, 2011, /*angle*/ 0, 90, 0, /*behParam*/ 0x00670000, /*beh*/ bhvDeathWarp), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 4147, -1100, 1997, /*angle*/ 0, 90, 0, /*behParam*/ 0x00680000, /*beh*/ bhvLaunchDeathWarp), - WARP_NODE(/*id*/ 0x64, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x03, /*destNode*/ 0x64, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0x65, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x03, /*destNode*/ 0x65, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0x66, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x03, /*destNode*/ 0x66, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0x67, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x03, /*destNode*/ 0x67, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0x68, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x03, /*destNode*/ 0x68, /*flags*/ WARP_NO_CHECKPOINT), + OBJECT(/*model*/ MODEL_CASTLE_KEY_DOOR, /*pos*/ -1100, -1074, 922, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(WARP_NODE_00), /*bhv*/ bhvDoorWarp), + OBJECT(/*model*/ MODEL_CASTLE_KEY_DOOR, /*pos*/ -946, -1074, 922, /*angle*/ 0, 180, 0, /*bhvParam*/ BPARAM2(WARP_NODE_01), /*bhv*/ bhvDoorWarp), + WARP_NODE(/*id*/ WARP_NODE_00, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 1, /*destNode*/ WARP_NODE_05, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_01, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 1, /*destNode*/ WARP_NODE_06, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_02, /*destLevel*/ LEVEL_CASTLE_GROUNDS, /*destArea*/ 1, /*destNode*/ WARP_NODE_02, /*flags*/ WARP_NO_CHECKPOINT), + OBJECT(/*model*/ MODEL_CASTLE_STAR_DOOR_30_STARS, /*pos*/ 307, -1074, 2074, /*angle*/ 0, 90, 0, /*bhvParam*/ BPARAM1(30), /*bhv*/ bhvStarDoor), + OBJECT(/*model*/ MODEL_CASTLE_STAR_DOOR_30_STARS, /*pos*/ 307, -1074, 1920, /*angle*/ 0, 270, 0, /*bhvParam*/ BPARAM1(30), /*bhv*/ bhvStarDoor), + PAINTING_WARP_NODE(/*id*/ WARP_NODE_0C, /*destLevel*/ LEVEL_LLL, /*destArea*/ 1, /*destNode*/ WARP_NODE_0A, /*flags*/ WARP_NO_CHECKPOINT), + PAINTING_WARP_NODE(/*id*/ WARP_NODE_0D, /*destLevel*/ LEVEL_LLL, /*destArea*/ 1, /*destNode*/ WARP_NODE_0A, /*flags*/ WARP_NO_CHECKPOINT), + PAINTING_WARP_NODE(/*id*/ WARP_NODE_0E, /*destLevel*/ LEVEL_LLL, /*destArea*/ 1, /*destNode*/ WARP_NODE_0A, /*flags*/ WARP_NO_CHECKPOINT), + PAINTING_WARP_NODE(/*id*/ WARP_NODE_0F, /*destLevel*/ LEVEL_SSL, /*destArea*/ 1, /*destNode*/ WARP_NODE_0A, /*flags*/ WARP_NO_CHECKPOINT), + PAINTING_WARP_NODE(/*id*/ WARP_NODE_10, /*destLevel*/ LEVEL_SSL, /*destArea*/ 1, /*destNode*/ WARP_NODE_0A, /*flags*/ WARP_NO_CHECKPOINT), + PAINTING_WARP_NODE(/*id*/ WARP_NODE_11, /*destLevel*/ LEVEL_SSL, /*destArea*/ 1, /*destNode*/ WARP_NODE_0A, /*flags*/ WARP_NO_CHECKPOINT), + PAINTING_WARP_NODE(/*id*/ WARP_NODE_2A, /*destLevel*/ LEVEL_HMC, /*destArea*/ 1, /*destNode*/ WARP_NODE_0A, /*flags*/ WARP_NO_CHECKPOINT), + PAINTING_WARP_NODE(/*id*/ WARP_NODE_15, /*destLevel*/ LEVEL_DDD, /*destArea*/ 1, /*destNode*/ WARP_NODE_0A, /*flags*/ WARP_NO_CHECKPOINT), + PAINTING_WARP_NODE(/*id*/ WARP_NODE_16, /*destLevel*/ LEVEL_DDD, /*destArea*/ 1, /*destNode*/ WARP_NODE_0A, /*flags*/ WARP_NO_CHECKPOINT), + PAINTING_WARP_NODE(/*id*/ WARP_NODE_17, /*destLevel*/ LEVEL_DDD, /*destArea*/ 1, /*destNode*/ WARP_NODE_0A, /*flags*/ WARP_NO_CHECKPOINT), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 4147, -1280, 1997, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(15) | BPARAM2(WARP_NODE_18), /*bhv*/ bhvWarp), + WARP_NODE(/*id*/ WARP_NODE_18, /*destLevel*/ LEVEL_BITFS, /*destArea*/ 1, /*destNode*/ WARP_NODE_0A, /*flags*/ WARP_NO_CHECKPOINT), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ -1382, -819, -4150, /*angle*/ 0, 180, 0, /*bhvParam*/ BPARAM2(WARP_NODE_32), /*bhv*/ bhvPaintingStarCollectWarp), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ -2918, -870, -875, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(WARP_NODE_33), /*bhv*/ bhvPaintingStarCollectWarp), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 2483, -1688, -2662, /*angle*/ 0, 270, 0, /*bhvParam*/ BPARAM2(WARP_NODE_34), /*bhv*/ bhvLaunchStarCollectWarp), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 2381, -500, 2011, /*angle*/ 0, 90, 0, /*bhvParam*/ BPARAM2(WARP_NODE_35), /*bhv*/ bhvAirborneStarCollectWarp), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 4147, -1100, 1997, /*angle*/ 0, 90, 0, /*bhvParam*/ BPARAM2(WARP_NODE_36), /*bhv*/ bhvLaunchStarCollectWarp), + WARP_NODE(/*id*/ WARP_NODE_32, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 3, /*destNode*/ WARP_NODE_32, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_33, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 3, /*destNode*/ WARP_NODE_33, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_34, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 3, /*destNode*/ WARP_NODE_34, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_35, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 3, /*destNode*/ WARP_NODE_35, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_36, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 3, /*destNode*/ WARP_NODE_36, /*flags*/ WARP_NO_CHECKPOINT), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ -1382, -819, -4150, /*angle*/ 0, 180, 0, /*bhvParam*/ BPARAM2(WARP_NODE_64), /*bhv*/ bhvPaintingDeathWarp), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ -2918, -870, -875, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(WARP_NODE_65), /*bhv*/ bhvPaintingDeathWarp), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 2483, -1688, -2662, /*angle*/ 0, 270, 0, /*bhvParam*/ BPARAM2(WARP_NODE_66), /*bhv*/ bhvLaunchDeathWarp), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 2381, -500, 2011, /*angle*/ 0, 90, 0, /*bhvParam*/ BPARAM2(WARP_NODE_67), /*bhv*/ bhvDeathWarp), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 4147, -1100, 1997, /*angle*/ 0, 90, 0, /*bhvParam*/ BPARAM2(WARP_NODE_68), /*bhv*/ bhvLaunchDeathWarp), + WARP_NODE(/*id*/ WARP_NODE_64, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 3, /*destNode*/ WARP_NODE_64, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_65, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 3, /*destNode*/ WARP_NODE_65, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_66, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 3, /*destNode*/ WARP_NODE_66, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_67, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 3, /*destNode*/ WARP_NODE_67, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_68, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 3, /*destNode*/ WARP_NODE_68, /*flags*/ WARP_NO_CHECKPOINT), RETURN(), }; static const LevelScript script_func_local_4[] = { - OBJECT(/*model*/ MODEL_RED_FLAME, /*pos*/ -2037, -818, -716, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvFlame), - OBJECT(/*model*/ MODEL_RED_FLAME, /*pos*/ -1648, -818, -716, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvFlame), - OBJECT(/*model*/ MODEL_RED_FLAME, /*pos*/ -1648, -818, -101, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvFlame), - OBJECT(/*model*/ MODEL_RED_FLAME, /*pos*/ -1648, -818, 512, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvFlame), - OBJECT(/*model*/ MODEL_RED_FLAME, /*pos*/ -2037, -818, -101, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvFlame), - OBJECT(/*model*/ MODEL_RED_FLAME, /*pos*/ -2969, -921, 420, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvFlame), - OBJECT(/*model*/ MODEL_RED_FLAME, /*pos*/ -2037, -818, -1330, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvFlame), - OBJECT(/*model*/ MODEL_RED_FLAME, /*pos*/ -3839, -1023, -1422, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvFlame), - OBJECT(/*model*/ MODEL_RED_FLAME, /*pos*/ -1929, -818, -3615, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvFlame), - OBJECT(/*model*/ MODEL_RED_FLAME, /*pos*/ -834, -818, -3615, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvFlame), - OBJECT(/*model*/ MODEL_BLUE_FLAME, /*pos*/ -3317, -921, 1229, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvFlame), - OBJECT(/*model*/ MODEL_BLUE_FLAME, /*pos*/ -204, -921, -624, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvFlame), - OBJECT(/*model*/ MODEL_BLUE_FLAME, /*pos*/ -2876, -921, 1229, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvFlame), + OBJECT(/*model*/ MODEL_RED_FLAME, /*pos*/ -2037, -818, -716, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvFlame), + OBJECT(/*model*/ MODEL_RED_FLAME, /*pos*/ -1648, -818, -716, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvFlame), + OBJECT(/*model*/ MODEL_RED_FLAME, /*pos*/ -1648, -818, -101, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvFlame), + OBJECT(/*model*/ MODEL_RED_FLAME, /*pos*/ -1648, -818, 512, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvFlame), + OBJECT(/*model*/ MODEL_RED_FLAME, /*pos*/ -2037, -818, -101, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvFlame), + OBJECT(/*model*/ MODEL_RED_FLAME, /*pos*/ -2969, -921, 420, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvFlame), + OBJECT(/*model*/ MODEL_RED_FLAME, /*pos*/ -2037, -818, -1330, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvFlame), + OBJECT(/*model*/ MODEL_RED_FLAME, /*pos*/ -3839, -1023, -1422, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvFlame), + OBJECT(/*model*/ MODEL_RED_FLAME, /*pos*/ -1929, -818, -3615, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvFlame), + OBJECT(/*model*/ MODEL_RED_FLAME, /*pos*/ -834, -818, -3615, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvFlame), + OBJECT(/*model*/ MODEL_BLUE_FLAME, /*pos*/ -3317, -921, 1229, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvFlame), + OBJECT(/*model*/ MODEL_BLUE_FLAME, /*pos*/ -204, -921, -624, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvFlame), + OBJECT(/*model*/ MODEL_BLUE_FLAME, /*pos*/ -2876, -921, 1229, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvFlame), RETURN(), }; const LevelScript level_castle_inside_entry[] = { INIT_LEVEL(), - LOAD_MIO0( /*seg*/ 0x07, _castle_inside_segment_7SegmentRomStart, _castle_inside_segment_7SegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x07, _castle_inside_segment_7SegmentRomStart, _castle_inside_segment_7SegmentRomEnd), LOAD_MIO0_TEXTURE(/*seg*/ 0x09, _inside_mio0SegmentRomStart, _inside_mio0SegmentRomEnd), - LOAD_MIO0( /*seg*/ 0x06, _group15_mio0SegmentRomStart, _group15_mio0SegmentRomEnd), - LOAD_RAW( /*seg*/ 0x0D, _group15_geoSegmentRomStart, _group15_geoSegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x06, _group15_mio0SegmentRomStart, _group15_mio0SegmentRomEnd), + LOAD_RAW (/*seg*/ 0x0D, _group15_geoSegmentRomStart, _group15_geoSegmentRomEnd), ALLOC_LEVEL_POOL(), - MARIO(/*model*/ MODEL_MARIO, /*behParam*/ 0x00000001, /*beh*/ bhvMario), + MARIO(/*model*/ MODEL_MARIO, /*bhvParam*/ BPARAM4(0x01), /*bhv*/ bhvMario), JUMP_LINK(script_func_global_16), LOAD_MODEL_FROM_GEO(MODEL_CASTLE_BOWSER_TRAP, castle_geo_000F18), LOAD_MODEL_FROM_GEO(MODEL_CASTLE_WATER_LEVEL_PILLAR, castle_geo_001940), @@ -250,18 +250,18 @@ const LevelScript level_castle_inside_entry[] = { LOAD_MODEL_FROM_GEO(MODEL_CASTLE_STAR_DOOR_70_STARS, castle_geo_000F00), AREA(/*index*/ 1, castle_geo_001400), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -5513, 717, -4324, /*angle*/ 0, 45, 0, /*behParam*/ 0x00140000, /*beh*/ bhvCastleFloorTrap), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 2477, 307, -2000, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvFishGroup), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 2774, 507, -1716, /*angle*/ 0, 90, 0, /*behParam*/ 0x00000000, /*beh*/ bhvTankFishGroup), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 3672, 507, -1307, /*angle*/ 0, 45, 0, /*behParam*/ 0x00000000, /*beh*/ bhvTankFishGroup), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 3748, 507, 773, /*angle*/ 0, -45, 0, /*behParam*/ 0x00000000, /*beh*/ bhvTankFishGroup), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 2778, 507, 1255, /*angle*/ 0, -90, 0, /*behParam*/ 0x00000000, /*beh*/ bhvTankFishGroup), - OBJECT(/*model*/ MODEL_BOO_CASTLE, /*pos*/ -1000, 50, -3500, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvBooInCastle), - OBJECT(/*model*/ MODEL_TOAD, /*pos*/ -1671, 0, 1313, /*angle*/ 0, 83, 0, /*behParam*/ DIALOG_133 << 24, /*beh*/ bhvToadMessage), - OBJECT(/*model*/ MODEL_TOAD, /*pos*/ 1524, 307, 458, /*angle*/ 0, 110, 0, /*behParam*/ DIALOG_134 << 24, /*beh*/ bhvToadMessage), - OBJECT(/*model*/ MODEL_TOAD, /*pos*/ 596, -306, -2637, /*angle*/ 0, 152, 0, /*behParam*/ DIALOG_135 << 24, /*beh*/ bhvToadMessage), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ -5513, 717, -4324, /*angle*/ 0, 45, 0, /*bhvParam*/ BPARAM2(0x14), /*bhv*/ bhvCastleFloorTrap), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 2477, 307, -2000, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvFishGroup), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 2774, 507, -1716, /*angle*/ 0, 90, 0, /*bhvParam*/ 0, /*bhv*/ bhvTankFishGroup), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 3672, 507, -1307, /*angle*/ 0, 45, 0, /*bhvParam*/ 0, /*bhv*/ bhvTankFishGroup), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 3748, 507, 773, /*angle*/ 0, -45, 0, /*bhvParam*/ 0, /*bhv*/ bhvTankFishGroup), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 2778, 507, 1255, /*angle*/ 0, -90, 0, /*bhvParam*/ 0, /*bhv*/ bhvTankFishGroup), + OBJECT(/*model*/ MODEL_BOO_CASTLE, /*pos*/ -1000, 50, -3500, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvBooInCastle), + OBJECT(/*model*/ MODEL_TOAD, /*pos*/ -1671, 0, 1313, /*angle*/ 0, 83, 0, /*bhvParam*/ BPARAM1(DIALOG_133), /*bhv*/ bhvToadMessage), + OBJECT(/*model*/ MODEL_TOAD, /*pos*/ 1524, 307, 458, /*angle*/ 0, 110, 0, /*bhvParam*/ BPARAM1(DIALOG_134), /*bhv*/ bhvToadMessage), + OBJECT(/*model*/ MODEL_TOAD, /*pos*/ 596, -306, -2637, /*angle*/ 0, 152, 0, /*bhvParam*/ BPARAM1(DIALOG_135), /*bhv*/ bhvToadMessage), JUMP_LINK(script_func_local_1), - WARP_NODE(/*id*/ 0xF1, /*destLevel*/ LEVEL_CASTLE_GROUNDS, /*destArea*/ 0x01, /*destNode*/ 0x03, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_DEATH, /*destLevel*/ LEVEL_CASTLE_GROUNDS, /*destArea*/ 1, /*destNode*/ WARP_NODE_03, /*flags*/ WARP_NO_CHECKPOINT), TERRAIN(/*terrainData*/ inside_castle_seg7_area_1_collision), ROOMS(/*surfaceRooms*/ inside_castle_seg7_area_1_rooms), MACRO_OBJECTS(/*objList*/ inside_castle_seg7_area_1_macro_objs), @@ -270,15 +270,15 @@ const LevelScript level_castle_inside_entry[] = { END_AREA(), AREA(/*index*/ 2, castle_geo_001858), - OBJECT(/*model*/ MODEL_CASTLE_CLOCK_MINUTE_HAND, /*pos*/ -205, 2918, 7222, /*angle*/ 0, 180, 0, /*behParam*/ 0x00000000, /*beh*/ bhvClockMinuteHand), - OBJECT(/*model*/ MODEL_CASTLE_CLOCK_HOUR_HAND, /*pos*/ -205, 2918, 7222, /*angle*/ 0, 180, 0, /*behParam*/ 0x00000000, /*beh*/ bhvClockHourHand), - OBJECT(/*model*/ MODEL_CASTLE_CLOCK_PENDULUM, /*pos*/ -205, 2611, 7140, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvDecorativePendulum), - OBJECT(/*model*/ MODEL_LAKITU, /*pos*/ 4231, 1408, 1601, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvCameraLakitu), - OBJECT(/*model*/ MODEL_TOAD, /*pos*/ -977, 1203, 2569, /*angle*/ 0, 0, 0, /*behParam*/ DIALOG_076 << 24, /*beh*/ bhvToadMessage), - OBJECT(/*model*/ MODEL_TOAD, /*pos*/ -1584, 2253, 7157, /*angle*/ 0, 136, 0, /*behParam*/ DIALOG_083 << 24, /*beh*/ bhvToadMessage), - OBJECT(/*model*/ MODEL_TOAD, /*pos*/ 837, 1203, 3020, /*angle*/ 0, 180, 0, /*behParam*/ DIALOG_137 << 24, /*beh*/ bhvToadMessage), + OBJECT(/*model*/ MODEL_CASTLE_CLOCK_MINUTE_HAND, /*pos*/ -205, 2918, 7222, /*angle*/ 0, 180, 0, /*bhvParam*/ 0, /*bhv*/ bhvClockMinuteHand), + OBJECT(/*model*/ MODEL_CASTLE_CLOCK_HOUR_HAND, /*pos*/ -205, 2918, 7222, /*angle*/ 0, 180, 0, /*bhvParam*/ 0, /*bhv*/ bhvClockHourHand), + OBJECT(/*model*/ MODEL_CASTLE_CLOCK_PENDULUM, /*pos*/ -205, 2611, 7140, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvDecorativePendulum), + OBJECT(/*model*/ MODEL_LAKITU, /*pos*/ 4231, 1408, 1601, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(CAMERA_LAKITU_BP_FOLLOW_CAMERA), /*bhv*/ bhvCameraLakitu), + OBJECT(/*model*/ MODEL_TOAD, /*pos*/ -977, 1203, 2569, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(DIALOG_076), /*bhv*/ bhvToadMessage), + OBJECT(/*model*/ MODEL_TOAD, /*pos*/ -1584, 2253, 7157, /*angle*/ 0, 136, 0, /*bhvParam*/ BPARAM1(DIALOG_083), /*bhv*/ bhvToadMessage), + OBJECT(/*model*/ MODEL_TOAD, /*pos*/ 837, 1203, 3020, /*angle*/ 0, 180, 0, /*bhvParam*/ BPARAM1(DIALOG_137), /*bhv*/ bhvToadMessage), JUMP_LINK(script_func_local_2), - WARP_NODE(/*id*/ 0xF1, /*destLevel*/ LEVEL_CASTLE_GROUNDS, /*destArea*/ 0x01, /*destNode*/ 0x03, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_DEATH, /*destLevel*/ LEVEL_CASTLE_GROUNDS, /*destArea*/ 1, /*destNode*/ WARP_NODE_03, /*flags*/ WARP_NO_CHECKPOINT), TERRAIN(/*terrainData*/ inside_castle_seg7_area_2_collision), ROOMS(/*surfaceRooms*/ inside_castle_seg7_area_2_rooms), MACRO_OBJECTS(/*objList*/ inside_castle_seg7_area_2_macro_objs), @@ -288,15 +288,15 @@ const LevelScript level_castle_inside_entry[] = { END_AREA(), AREA(/*index*/ 3, castle_geo_001C10), - OBJECT(/*model*/ MODEL_CASTLE_WATER_LEVEL_PILLAR, /*pos*/ 7066, -1178, -819, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvWaterLevelPillar), - OBJECT(/*model*/ MODEL_CASTLE_WATER_LEVEL_PILLAR, /*pos*/ 7066, -1178, -205, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvWaterLevelPillar), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 0, 0, 0, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvDddWarp), - OBJECT(/*model*/ MODEL_MIPS, /*pos*/ -1509, -1177, -1564, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvMips), - OBJECT(/*model*/ MODEL_TOAD, /*pos*/ 1787, -1381, -1957, /*angle*/ 0, 126, 0, /*behParam*/ DIALOG_082 << 24, /*beh*/ bhvToadMessage), - OBJECT(/*model*/ MODEL_TOAD, /*pos*/ -4048, -1381, -1334, /*angle*/ 0, 30, 0, /*behParam*/ DIALOG_136 << 24, /*beh*/ bhvToadMessage), + OBJECT(/*model*/ MODEL_CASTLE_WATER_LEVEL_PILLAR, /*pos*/ 7066, -1178, -819, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvWaterLevelPillar), + OBJECT(/*model*/ MODEL_CASTLE_WATER_LEVEL_PILLAR, /*pos*/ 7066, -1178, -205, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvWaterLevelPillar), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 0, 0, 0, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvDDDWarp), + OBJECT(/*model*/ MODEL_MIPS, /*pos*/ -1509, -1177, -1564, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(MIPS_BP_15_STARS), /*bhv*/ bhvMips), + OBJECT(/*model*/ MODEL_TOAD, /*pos*/ 1787, -1381, -1957, /*angle*/ 0, 126, 0, /*bhvParam*/ BPARAM1(DIALOG_082), /*bhv*/ bhvToadMessage), + OBJECT(/*model*/ MODEL_TOAD, /*pos*/ -4048, -1381, -1334, /*angle*/ 0, 30, 0, /*bhvParam*/ BPARAM1(DIALOG_136), /*bhv*/ bhvToadMessage), JUMP_LINK(script_func_local_3), JUMP_LINK(script_func_local_4), - WARP_NODE(/*id*/ 0xF1, /*destLevel*/ LEVEL_CASTLE_GROUNDS, /*destArea*/ 0x01, /*destNode*/ 0x03, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_DEATH, /*destLevel*/ LEVEL_CASTLE_GROUNDS, /*destArea*/ 1, /*destNode*/ WARP_NODE_03, /*flags*/ WARP_NO_CHECKPOINT), TERRAIN(/*terrainData*/ inside_castle_seg7_area_3_collision), ROOMS(/*surfaceRooms*/ inside_castle_seg7_area_3_rooms), MACRO_OBJECTS(/*objList*/ inside_castle_seg7_area_3_macro_objs), diff --git a/levels/castle_inside/star_door/geo.inc.c b/levels/castle_inside/star_door/geo.inc.c index a70dbaf4..a7e91046 100644 --- a/levels/castle_inside/star_door/geo.inc.c +++ b/levels/castle_inside/star_door/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000F00 const GeoLayout castle_geo_000F00[] = { - GEO_CULLING_RADIUS(400), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_0703BFA8), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(400), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_0703BFA8), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/castle_inside/trap_door/geo.inc.c b/levels/castle_inside/trap_door/geo.inc.c index 4587fb54..4ca4f80e 100644 --- a/levels/castle_inside/trap_door/geo.inc.c +++ b/levels/castle_inside/trap_door/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000F18 const GeoLayout castle_geo_000F18[] = { - GEO_CULLING_RADIUS(600), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_0703BCB8), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(600), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_0703BCB8), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/castle_inside/water_level_pillar/geo.inc.c b/levels/castle_inside/water_level_pillar/geo.inc.c index 44765314..b57fc53c 100644 --- a/levels/castle_inside/water_level_pillar/geo.inc.c +++ b/levels/castle_inside/water_level_pillar/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E001940 const GeoLayout castle_geo_001940[] = { - GEO_CULLING_RADIUS(550), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_07068B10), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(550), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, inside_castle_seg7_dl_07068B10), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/ccm/areas/1/10/geo.inc.c b/levels/ccm/areas/1/10/geo.inc.c index e29900af..2dcbeb63 100644 --- a/levels/ccm/areas/1/10/geo.inc.c +++ b/levels/ccm/areas/1/10/geo.inc.c @@ -1,13 +1,13 @@ // 0x0E0004E4 const GeoLayout ccm_geo_0004E4[] = { - GEO_CULLING_RADIUS(3500), - GEO_OPEN_NODE(), - GEO_RENDER_RANGE(-3000, 6000), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, ccm_seg7_dl_07010660), - GEO_DISPLAY_LIST(LAYER_ALPHA, ccm_seg7_dl_070109D0), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, ccm_seg7_dl_07010B50), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(3500), + GEO_OPEN_NODE(), + GEO_RENDER_RANGE(-3000, 6000), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, ccm_seg7_dl_07010660), + GEO_DISPLAY_LIST(LAYER_ALPHA, ccm_seg7_dl_070109D0), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, ccm_seg7_dl_07010B50), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/ccm/areas/1/6/geo.inc.c b/levels/ccm/areas/1/6/geo.inc.c index 8b3a8d5b..197e5e38 100644 --- a/levels/ccm/areas/1/6/geo.inc.c +++ b/levels/ccm/areas/1/6/geo.inc.c @@ -1,12 +1,12 @@ // 0x0E00042C const GeoLayout ccm_geo_00042C[] = { - GEO_CULLING_RADIUS(800), - GEO_OPEN_NODE(), - GEO_RENDER_RANGE(-1000, 4000), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, ccm_seg7_dl_0700E708), - GEO_DISPLAY_LIST(LAYER_ALPHA, ccm_seg7_dl_0700E970), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(800), + GEO_OPEN_NODE(), + GEO_RENDER_RANGE(-1000, 4000), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, ccm_seg7_dl_0700E708), + GEO_DISPLAY_LIST(LAYER_ALPHA, ccm_seg7_dl_0700E970), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/ccm/areas/1/7/geo.inc.c b/levels/ccm/areas/1/7/geo.inc.c index aa86bb9f..3f010512 100644 --- a/levels/ccm/areas/1/7/geo.inc.c +++ b/levels/ccm/areas/1/7/geo.inc.c @@ -1,13 +1,13 @@ // 0x0E00045C const GeoLayout ccm_geo_00045C[] = { - GEO_CULLING_RADIUS(900), - GEO_OPEN_NODE(), - GEO_RENDER_RANGE(-1000, 7000), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, ccm_seg7_dl_0700F440), - GEO_DISPLAY_LIST(LAYER_ALPHA, ccm_seg7_dl_0700F650), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, ccm_seg7_dl_0700F780), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(900), + GEO_OPEN_NODE(), + GEO_RENDER_RANGE(-1000, 7000), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, ccm_seg7_dl_0700F440), + GEO_DISPLAY_LIST(LAYER_ALPHA, ccm_seg7_dl_0700F650), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, ccm_seg7_dl_0700F780), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/ccm/areas/1/8/geo.inc.c b/levels/ccm/areas/1/8/geo.inc.c index bd7b9bcc..8f446506 100644 --- a/levels/ccm/areas/1/8/geo.inc.c +++ b/levels/ccm/areas/1/8/geo.inc.c @@ -1,11 +1,11 @@ // 0x0E000494 const GeoLayout ccm_geo_000494[] = { - GEO_CULLING_RADIUS(400), - GEO_OPEN_NODE(), - GEO_RENDER_RANGE(-500, 7000), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, ccm_seg7_dl_0700FB00), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(400), + GEO_OPEN_NODE(), + GEO_RENDER_RANGE(-500, 7000), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, ccm_seg7_dl_0700FB00), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/ccm/areas/1/9/geo.inc.c b/levels/ccm/areas/1/9/geo.inc.c index 408aec6b..8cc713db 100644 --- a/levels/ccm/areas/1/9/geo.inc.c +++ b/levels/ccm/areas/1/9/geo.inc.c @@ -1,11 +1,11 @@ // 0x0E0004BC const GeoLayout ccm_geo_0004BC[] = { - GEO_CULLING_RADIUS(800), - GEO_OPEN_NODE(), - GEO_RENDER_RANGE(-1000, 7000), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, ccm_seg7_dl_0700FD08), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(800), + GEO_OPEN_NODE(), + GEO_RENDER_RANGE(-1000, 7000), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, ccm_seg7_dl_0700FD08), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/ccm/areas/1/collision.inc.c b/levels/ccm/areas/1/collision.inc.c index 45068372..b78170bc 100644 --- a/levels/ccm/areas/1/collision.inc.c +++ b/levels/ccm/areas/1/collision.inc.c @@ -1767,7 +1767,7 @@ const Collision ccm_seg7_area_1_collision[] = { SPECIAL_OBJECT(/*preset*/ special_snow_tree, /*pos*/ -1146, -3583, 5919), SPECIAL_OBJECT(/*preset*/ special_snow_tree, /*pos*/ -1768, 2560, -1793), SPECIAL_OBJECT(/*preset*/ special_snow_tree, /*pos*/ -3443, 807, -2713), - SPECIAL_OBJECT_WITH_YAW_AND_PARAM(/*preset*/ special_wooden_door_warp, /*pos*/ 2464, -4607, 4302, /*yaw*/ 158, /*behParam2*/ 20), + SPECIAL_OBJECT_WITH_YAW_AND_PARAM(/*preset*/ special_wooden_door_warp, /*pos*/ 2464, -4607, 4302, /*yaw*/ 158, /*bhvParam2*/ 20), COL_WATER_BOX_INIT(1), COL_WATER_BOX(0, 3137, 4228, 3925, 4945, -4638), COL_END(), diff --git a/levels/ccm/areas/1/geo.inc.c b/levels/ccm/areas/1/geo.inc.c index 2a0dfe34..58b0528f 100644 --- a/levels/ccm/areas/1/geo.inc.c +++ b/levels/ccm/areas/1/geo.inc.c @@ -1,36 +1,36 @@ // 0x0E00051C const GeoLayout ccm_geo_00051C[] = { - GEO_NODE_SCREEN_AREA(10, SCREEN_WIDTH/2, SCREEN_HEIGHT/2, SCREEN_WIDTH/2, SCREEN_HEIGHT/2), - GEO_OPEN_NODE(), - GEO_ZBUFFER(0), - GEO_OPEN_NODE(), - GEO_NODE_ORTHO(100), - GEO_OPEN_NODE(), - GEO_BACKGROUND(BACKGROUND_SNOW_MOUNTAINS, geo_skybox_main), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ZBUFFER(1), - GEO_OPEN_NODE(), - GEO_CAMERA_FRUSTUM_WITH_FUNC(45, 100, 12800, geo_camera_fov), - GEO_OPEN_NODE(), - GEO_CAMERA(1, 0, 2000, 6000, 0, 0, 0, geo_camera_main), + GEO_NODE_SCREEN_AREA(10, SCREEN_WIDTH/2, SCREEN_HEIGHT/2, SCREEN_WIDTH/2, SCREEN_HEIGHT/2), + GEO_OPEN_NODE(), + GEO_ZBUFFER(0), + GEO_OPEN_NODE(), + GEO_NODE_ORTHO(100), GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, ccm_seg7_dl_0700B090), - GEO_DISPLAY_LIST(LAYER_OPAQUE, ccm_seg7_dl_0700B1D8), - GEO_DISPLAY_LIST(LAYER_OPAQUE, ccm_seg7_dl_0700C380), - GEO_DISPLAY_LIST(LAYER_ALPHA, ccm_seg7_dl_0700D578), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT_DECAL, ccm_seg7_dl_0700DDF0), - GEO_ASM( 0, geo_movtex_pause_control), - GEO_ASM(0x0501, geo_movtex_draw_water_regions), - GEO_RENDER_OBJ(), - GEO_ASM( 1, geo_envfx_main), + GEO_BACKGROUND(BACKGROUND_SNOW_MOUNTAINS, geo_skybox_main), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ZBUFFER(0), - GEO_OPEN_NODE(), - GEO_ASM(0, geo_cannon_circle_base), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CLOSE_NODE(), + GEO_ZBUFFER(1), + GEO_OPEN_NODE(), + GEO_CAMERA_FRUSTUM_WITH_FUNC(45, 100, 12800, geo_camera_fov), + GEO_OPEN_NODE(), + GEO_CAMERA(1, 0, 2000, 6000, 0, 0, 0, geo_camera_main), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, ccm_seg7_dl_0700B090), + GEO_DISPLAY_LIST(LAYER_OPAQUE, ccm_seg7_dl_0700B1D8), + GEO_DISPLAY_LIST(LAYER_OPAQUE, ccm_seg7_dl_0700C380), + GEO_DISPLAY_LIST(LAYER_ALPHA, ccm_seg7_dl_0700D578), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT_DECAL, ccm_seg7_dl_0700DDF0), + GEO_ASM( 0, geo_movtex_pause_control), + GEO_ASM(0x0501, geo_movtex_draw_water_regions), + GEO_RENDER_OBJ(), + GEO_ASM( 1, geo_envfx_main), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ZBUFFER(0), + GEO_OPEN_NODE(), + GEO_ASM(0, geo_cannon_circle_base), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/ccm/areas/1/macro.inc.c b/levels/ccm/areas/1/macro.inc.c index a49d9c81..f612adf0 100644 --- a/levels/ccm/areas/1/macro.inc.c +++ b/levels/ccm/areas/1/macro.inc.c @@ -1,41 +1,41 @@ // 0x07016284 - 0x070163F8 const MacroObject ccm_seg7_area_1_macro_objs[] = { - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 180, /*pos*/ -2412, 2912, -878, /*behParam*/ DIALOG_040), - MACRO_OBJECT(/*preset*/ macro_mr_blizzard, /*yaw*/ 0, /*pos*/ 3054, -2674, 2072), - MACRO_OBJECT(/*preset*/ macro_spindrift, /*yaw*/ 0, /*pos*/ 2542, 2622, -1714), - MACRO_OBJECT(/*preset*/ macro_spindrift, /*yaw*/ 0, /*pos*/ -6090, -1740, 1936), - MACRO_OBJECT(/*preset*/ macro_spindrift, /*yaw*/ 0, /*pos*/ 4346, -3068, 400), - MACRO_OBJECT(/*preset*/ macro_spindrift, /*yaw*/ 0, /*pos*/ -5054, -4659, -1054), - MACRO_OBJECT(/*preset*/ macro_spindrift, /*yaw*/ 0, /*pos*/ -5033, -4740, -2666), - MACRO_OBJECT(/*preset*/ macro_bobomb_buddy_opens_cannon, /*yaw*/ 0, /*pos*/ -1220, -3583, 5969), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_cannon_closed, /*yaw*/ 0, /*pos*/ -3615, -4607, 4790, /*behParam*/ 0x00), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_cannon_closed, /*yaw*/ 0, /*pos*/ -5045, -1740, 4615, /*behParam*/ 0x00), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_cannon_closed, /*yaw*/ 0, /*pos*/ 1090, -4607, 5729, /*behParam*/ 0x80), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 270, /*pos*/ -1060, 2560, -1840, /*behParam*/ DIALOG_087), - MACRO_OBJECT(/*preset*/ macro_coin_line_vertical, /*yaw*/ 0, /*pos*/ -180, 3100, -1480), - MACRO_OBJECT(/*preset*/ macro_coin_line_horizontal, /*yaw*/ 0, /*pos*/ 3560, 2100, -280), - MACRO_OBJECT(/*preset*/ macro_coin_line_horizontal, /*yaw*/ 77, /*pos*/ -1942, 1334, 1678), - MACRO_OBJECT(/*preset*/ macro_coin_line_horizontal, /*yaw*/ 90, /*pos*/ -1020, 646, -2706), - MACRO_OBJECT(/*preset*/ macro_coin_line_horizontal, /*yaw*/ 93, /*pos*/ -1460, -888, -3933), - MACRO_OBJECT(/*preset*/ macro_coin_arrow, /*yaw*/ 75, /*pos*/ -2586, -4889, -4093), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 270, /*pos*/ -4350, -4864, -4813, /*behParam*/ DIALOG_094), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 0, /*pos*/ -1037, -3583, 5872, /*behParam*/ DIALOG_091), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 180, /*pos*/ -309, -4889, -3690, /*behParam*/ DIALOG_049), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 0, /*pos*/ 1900, -1535, 3500, /*behParam*/ DIALOG_040), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -488, 3100, -2305), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -3120, -1200, -2080), - MACRO_OBJECT(/*preset*/ macro_hidden_1up_in_pole, /*yaw*/ 0, /*pos*/ -5200, -1345, 2995), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 2940, -1400, 2630), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -600, -505, 1940), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -3814, -2112, 6427), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 2700, -4600, 1230), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 1990, -4040, 4950), - MACRO_OBJECT(/*preset*/ macro_blue_coin_switch, /*yaw*/ 0, /*pos*/ 3400, -820, 0), - MACRO_OBJECT(/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ 3400, -640, -740), - MACRO_OBJECT(/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ 3400, -320, -1740), - MACRO_OBJECT(/*preset*/ macro_recovery_heart, /*yaw*/ 0, /*pos*/ -270, -4650, -3100), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 4408, -4550, -1534), - MACRO_OBJECT(/*preset*/ macro_box_1up_running_away, /*yaw*/ 0, /*pos*/ -4887, -1300, -4003), - MACRO_OBJECT(/*preset*/ macro_box_1up_running_away, /*yaw*/ 0, /*pos*/ -1557, -205, 1794), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 180, /*pos*/ -2412, 2912, -878, /*bhvParam*/ DIALOG_040), + MACRO_OBJECT (/*preset*/ macro_mr_blizzard_1, /*yaw*/ 0, /*pos*/ 3054, -2674, 2072), + MACRO_OBJECT (/*preset*/ macro_spindrift, /*yaw*/ 0, /*pos*/ 2542, 2622, -1714), + MACRO_OBJECT (/*preset*/ macro_spindrift, /*yaw*/ 0, /*pos*/ -6090, -1740, 1936), + MACRO_OBJECT (/*preset*/ macro_spindrift, /*yaw*/ 0, /*pos*/ 4346, -3068, 400), + MACRO_OBJECT (/*preset*/ macro_spindrift, /*yaw*/ 0, /*pos*/ -5054, -4659, -1054), + MACRO_OBJECT (/*preset*/ macro_spindrift, /*yaw*/ 0, /*pos*/ -5033, -4740, -2666), + MACRO_OBJECT (/*preset*/ macro_bobomb_buddy_opens_cannon_1, /*yaw*/ 0, /*pos*/ -1220, -3583, 5969), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_cannon_closed, /*yaw*/ 0, /*pos*/ -3615, -4607, 4790, /*bhvParam*/ 0x00), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_cannon_closed, /*yaw*/ 0, /*pos*/ -5045, -1740, 4615, /*bhvParam*/ 0x00), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_cannon_closed, /*yaw*/ 0, /*pos*/ 1090, -4607, 5729, /*bhvParam*/ 0x80), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 270, /*pos*/ -1060, 2560, -1840, /*bhvParam*/ DIALOG_087), + MACRO_OBJECT (/*preset*/ macro_coin_line_vertical_flying, /*yaw*/ 0, /*pos*/ -180, 3100, -1480), + MACRO_OBJECT (/*preset*/ macro_coin_line_horizontal, /*yaw*/ 0, /*pos*/ 3560, 2100, -280), + MACRO_OBJECT (/*preset*/ macro_coin_line_horizontal, /*yaw*/ 77, /*pos*/ -1942, 1334, 1678), + MACRO_OBJECT (/*preset*/ macro_coin_line_horizontal, /*yaw*/ 90, /*pos*/ -1020, 646, -2706), + MACRO_OBJECT (/*preset*/ macro_coin_line_horizontal, /*yaw*/ 93, /*pos*/ -1460, -888, -3933), + MACRO_OBJECT (/*preset*/ macro_coin_arrow, /*yaw*/ 75, /*pos*/ -2586, -4889, -4093), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 270, /*pos*/ -4350, -4864, -4813, /*bhvParam*/ DIALOG_094), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 0, /*pos*/ -1037, -3583, 5872, /*bhvParam*/ DIALOG_091), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 180, /*pos*/ -309, -4889, -3690, /*bhvParam*/ DIALOG_049), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 0, /*pos*/ 1900, -1535, 3500, /*bhvParam*/ DIALOG_040), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -488, 3100, -2305), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -3120, -1200, -2080), + MACRO_OBJECT (/*preset*/ macro_hidden_1up_in_pole, /*yaw*/ 0, /*pos*/ -5200, -1345, 2995), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 2940, -1400, 2630), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -600, -505, 1940), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -3814, -2112, 6427), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 2700, -4600, 1230), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 1990, -4040, 4950), + MACRO_OBJECT (/*preset*/ macro_blue_coin_switch, /*yaw*/ 0, /*pos*/ 3400, -820, 0), + MACRO_OBJECT (/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ 3400, -640, -740), + MACRO_OBJECT (/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ 3400, -320, -1740), + MACRO_OBJECT (/*preset*/ macro_recovery_heart, /*yaw*/ 0, /*pos*/ -270, -4650, -3100), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 4408, -4550, -1534), + MACRO_OBJECT (/*preset*/ macro_box_1up_running_away, /*yaw*/ 0, /*pos*/ -4887, -1300, -4003), + MACRO_OBJECT (/*preset*/ macro_box_1up_running_away, /*yaw*/ 0, /*pos*/ -1557, -205, 1794), MACRO_OBJECT_END(), }; diff --git a/levels/ccm/areas/2/collision.inc.c b/levels/ccm/areas/2/collision.inc.c index d75bdf58..839eb273 100644 --- a/levels/ccm/areas/2/collision.inc.c +++ b/levels/ccm/areas/2/collision.inc.c @@ -1874,6 +1874,6 @@ const Collision ccm_seg7_area_2_collision[] = { COL_TRI_STOP(), COL_SPECIAL_INIT(2), SPECIAL_OBJECT_WITH_YAW(/*preset*/ special_null_start, /*pos*/ -5836, 7465, -6143, /*yaw*/ 64), // unused, probably an early way to set initial position - SPECIAL_OBJECT_WITH_YAW_AND_PARAM(/*preset*/ special_wooden_door_warp, /*pos*/ -7628, -5836, -6988, /*yaw*/ 64, /*behParam2*/ 20), + SPECIAL_OBJECT_WITH_YAW_AND_PARAM(/*preset*/ special_wooden_door_warp, /*pos*/ -7628, -5836, -6988, /*yaw*/ 64, /*bhvParam2*/ 20), COL_END(), }; diff --git a/levels/ccm/areas/2/geo.inc.c b/levels/ccm/areas/2/geo.inc.c index 11f40583..ac1eb305 100644 --- a/levels/ccm/areas/2/geo.inc.c +++ b/levels/ccm/areas/2/geo.inc.c @@ -1,32 +1,32 @@ // 0x0E0005E8 const GeoLayout ccm_geo_0005E8[] = { - GEO_NODE_SCREEN_AREA(10, SCREEN_WIDTH/2, SCREEN_HEIGHT/2, SCREEN_WIDTH/2, SCREEN_HEIGHT/2), - GEO_OPEN_NODE(), - GEO_ZBUFFER(0), - GEO_OPEN_NODE(), - GEO_NODE_ORTHO(100), - GEO_OPEN_NODE(), - GEO_BACKGROUND_COLOR(0x0001), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ZBUFFER(1), - GEO_OPEN_NODE(), - GEO_CAMERA_FRUSTUM_WITH_FUNC(45, 100, 12800, geo_camera_fov), - GEO_OPEN_NODE(), - GEO_CAMERA(9, 0, 2000, 6000, 0, 0, 0, geo_camera_main), + GEO_NODE_SCREEN_AREA(10, SCREEN_WIDTH/2, SCREEN_HEIGHT/2, SCREEN_WIDTH/2, SCREEN_HEIGHT/2), + GEO_OPEN_NODE(), + GEO_ZBUFFER(0), + GEO_OPEN_NODE(), + GEO_NODE_ORTHO(100), GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, ccm_seg7_dl_0701CE30), - GEO_DISPLAY_LIST(LAYER_OPAQUE, ccm_seg7_dl_0701E558), - GEO_DISPLAY_LIST(LAYER_OPAQUE_DECAL, ccm_seg7_dl_0701E6B0), - GEO_DISPLAY_LIST(LAYER_ALPHA, ccm_seg7_dl_0701FC78), - GEO_DISPLAY_LIST(LAYER_ALPHA, ccm_seg7_dl_0701FD78), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, ccm_seg7_dl_0701FE60), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, ccm_seg7_dl_070207F0), - GEO_RENDER_OBJ(), - GEO_ASM(0, geo_envfx_main), + GEO_BACKGROUND_COLOR(0x0001), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CLOSE_NODE(), + GEO_ZBUFFER(1), + GEO_OPEN_NODE(), + GEO_CAMERA_FRUSTUM_WITH_FUNC(45, 100, 12800, geo_camera_fov), + GEO_OPEN_NODE(), + GEO_CAMERA(9, 0, 2000, 6000, 0, 0, 0, geo_camera_main), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, ccm_seg7_dl_0701CE30), + GEO_DISPLAY_LIST(LAYER_OPAQUE, ccm_seg7_dl_0701E558), + GEO_DISPLAY_LIST(LAYER_OPAQUE_DECAL, ccm_seg7_dl_0701E6B0), + GEO_DISPLAY_LIST(LAYER_ALPHA, ccm_seg7_dl_0701FC78), + GEO_DISPLAY_LIST(LAYER_ALPHA, ccm_seg7_dl_0701FD78), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, ccm_seg7_dl_0701FE60), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, ccm_seg7_dl_070207F0), + GEO_RENDER_OBJ(), + GEO_ASM(0, geo_envfx_main), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/ccm/areas/2/macro.inc.c b/levels/ccm/areas/2/macro.inc.c index e4e91f29..8026dd1a 100644 --- a/levels/ccm/areas/2/macro.inc.c +++ b/levels/ccm/areas/2/macro.inc.c @@ -1,45 +1,45 @@ // 0x07023468 - 0x07023604 const MacroObject ccm_seg7_area_2_macro_objs[] = { - MACRO_OBJECT(/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ 2255, 4091, -536), - MACRO_OBJECT(/*preset*/ macro_yellow_coin, /*yaw*/ 0, /*pos*/ 2055, 4352, -497), - MACRO_OBJECT(/*preset*/ macro_yellow_coin, /*yaw*/ 0, /*pos*/ 1843, 4486, -433), - MACRO_OBJECT(/*preset*/ macro_yellow_coin, /*yaw*/ 0, /*pos*/ 1603, 4567, -347), - MACRO_OBJECT(/*preset*/ macro_yellow_coin, /*yaw*/ 0, /*pos*/ 1397, 4530, -287), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 0, /*pos*/ -5320, 6656, -6540, /*behParam*/ DIALOG_054), - MACRO_OBJECT(/*preset*/ macro_coin_line_horizontal, /*yaw*/ 0, /*pos*/ -4980, 2180, -1980), - MACRO_OBJECT(/*preset*/ macro_coin_line_horizontal, /*yaw*/ 0, /*pos*/ 6640, -60, -800), - MACRO_OBJECT(/*preset*/ macro_coin_line_horizontal, /*yaw*/ 0, /*pos*/ 6640, -1020, 440), - MACRO_OBJECT(/*preset*/ macro_coin_line_horizontal, /*yaw*/ 0, /*pos*/ 6640, -1820, 1760), - MACRO_OBJECT(/*preset*/ macro_coin_line_horizontal, /*yaw*/ 0, /*pos*/ 6640, -2260, 2620), - MACRO_OBJECT(/*preset*/ macro_coin_line_horizontal, /*yaw*/ 0, /*pos*/ -6460, -5000, -3200), - MACRO_OBJECT(/*preset*/ macro_coin_line_horizontal, /*yaw*/ 0, /*pos*/ -6460, -5540, -4100), - MACRO_OBJECT(/*preset*/ macro_coin_line_horizontal, /*yaw*/ 0, /*pos*/ -6460, -5200, -5000), - MACRO_OBJECT(/*preset*/ macro_box_1up, /*yaw*/ 0, /*pos*/ -5600, -4500, -6644), - MACRO_OBJECT(/*preset*/ macro_moving_blue_coin, /*yaw*/ 0, /*pos*/ -3160, 6267, -6120), - MACRO_OBJECT(/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ -700, 5923, -6240), - MACRO_OBJECT(/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ 2260, 5342, -6440), - MACRO_OBJECT(/*preset*/ macro_coin_line_horizontal, /*yaw*/ 120, /*pos*/ 2960, 4280, -880), - MACRO_OBJECT(/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ 1900, 659, -2340), - MACRO_OBJECT(/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ 1720, 690, -2220), - MACRO_OBJECT(/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ 3400, 302, -5240), - MACRO_OBJECT(/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ 3600, 297, -5420), - MACRO_OBJECT(/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ 6120, 4435, -5020), - MACRO_OBJECT(/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ 6140, -152, -5540), - MACRO_OBJECT(/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ 6320, -200, -5320), - MACRO_OBJECT(/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ 3960, -3297, 6440), - MACRO_OBJECT(/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ 1400, -3560, 5840), - MACRO_OBJECT(/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ -220, -3780, 4960), - MACRO_OBJECT(/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ -520, -3890, 4360), - MACRO_OBJECT(/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ -740, -4008, 3540), - MACRO_OBJECT(/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ -920, -4094, 2760), - MACRO_OBJECT(/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ -960, -4101, 2080), - MACRO_OBJECT(/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ -860, 3391, -760), - MACRO_OBJECT(/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ -1120, 3293, -1140), - MACRO_OBJECT(/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ -1560, 2989, -3280), - MACRO_OBJECT(/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ -1740, 2926, -3780), - MACRO_OBJECT(/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ -2849, 2677, -4608), - MACRO_OBJECT(/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ -4620, 2353, -4120), - MACRO_OBJECT(/*preset*/ macro_1up_sliding, /*yaw*/ 0, /*pos*/ -4890, 1452, 552), - MACRO_OBJECT(/*preset*/ macro_1up_sliding, /*yaw*/ 0, /*pos*/ -6369, -1538, 3726), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ 2255, 4091, -536), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_1, /*yaw*/ 0, /*pos*/ 2055, 4352, -497), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_1, /*yaw*/ 0, /*pos*/ 1843, 4486, -433), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_1, /*yaw*/ 0, /*pos*/ 1603, 4567, -347), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_1, /*yaw*/ 0, /*pos*/ 1397, 4530, -287), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 0, /*pos*/ -5320, 6656, -6540, /*bhvParam*/ DIALOG_054), + MACRO_OBJECT (/*preset*/ macro_coin_line_horizontal, /*yaw*/ 0, /*pos*/ -4980, 2180, -1980), + MACRO_OBJECT (/*preset*/ macro_coin_line_horizontal, /*yaw*/ 0, /*pos*/ 6640, -60, -800), + MACRO_OBJECT (/*preset*/ macro_coin_line_horizontal, /*yaw*/ 0, /*pos*/ 6640, -1020, 440), + MACRO_OBJECT (/*preset*/ macro_coin_line_horizontal, /*yaw*/ 0, /*pos*/ 6640, -1820, 1760), + MACRO_OBJECT (/*preset*/ macro_coin_line_horizontal, /*yaw*/ 0, /*pos*/ 6640, -2260, 2620), + MACRO_OBJECT (/*preset*/ macro_coin_line_horizontal, /*yaw*/ 0, /*pos*/ -6460, -5000, -3200), + MACRO_OBJECT (/*preset*/ macro_coin_line_horizontal, /*yaw*/ 0, /*pos*/ -6460, -5540, -4100), + MACRO_OBJECT (/*preset*/ macro_coin_line_horizontal, /*yaw*/ 0, /*pos*/ -6460, -5200, -5000), + MACRO_OBJECT (/*preset*/ macro_box_1up, /*yaw*/ 0, /*pos*/ -5600, -4500, -6644), + MACRO_OBJECT (/*preset*/ macro_moving_blue_coin, /*yaw*/ 0, /*pos*/ -3160, 6267, -6120), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ -700, 5923, -6240), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ 2260, 5342, -6440), + MACRO_OBJECT (/*preset*/ macro_coin_line_horizontal, /*yaw*/ 120, /*pos*/ 2960, 4280, -880), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ 1900, 659, -2340), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ 1720, 690, -2220), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ 3400, 302, -5240), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ 3600, 297, -5420), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ 6120, 4435, -5020), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ 6140, -152, -5540), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ 6320, -200, -5320), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ 3960, -3297, 6440), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ 1400, -3560, 5840), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ -220, -3780, 4960), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ -520, -3890, 4360), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ -740, -4008, 3540), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ -920, -4094, 2760), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ -960, -4101, 2080), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ -860, 3391, -760), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ -1120, 3293, -1140), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ -1560, 2989, -3280), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ -1740, 2926, -3780), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ -2849, 2677, -4608), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ -4620, 2353, -4120), + MACRO_OBJECT (/*preset*/ macro_1up_sliding, /*yaw*/ 0, /*pos*/ -4890, 1452, 552), + MACRO_OBJECT (/*preset*/ macro_1up_sliding, /*yaw*/ 0, /*pos*/ -6369, -1538, 3726), MACRO_OBJECT_END(), }; diff --git a/levels/ccm/level.yaml b/levels/ccm/level.yaml index 687296e3..15d39bac 100644 --- a/levels/ccm/level.yaml +++ b/levels/ccm/level.yaml @@ -1,6 +1,6 @@ -# Cool Cool Mountain +# Cool, Cool Mountain short-name: ccm -full-name: Cool Cool Mountain +full-name: Cool, Cool Mountain texture-file: ["/texture.inc.c"] area-count: 2 objects: [ropeway_lift, snowman_base, snowman_head] diff --git a/levels/ccm/leveldata.c b/levels/ccm/leveldata.c index fef53ddd..6ab07858 100644 --- a/levels/ccm/leveldata.c +++ b/levels/ccm/leveldata.c @@ -3,8 +3,8 @@ #include "surface_terrains.h" #include "moving_texture_macros.h" #include "level_misc_macros.h" -#include "macro_preset_names.h" -#include "special_preset_names.h" +#include "macro_presets.h" +#include "special_presets.h" #include "textures.h" #include "dialog_ids.h" diff --git a/levels/ccm/ropeway_lift/geo.inc.c b/levels/ccm/ropeway_lift/geo.inc.c index 67e33f52..aff4ae45 100644 --- a/levels/ccm/ropeway_lift/geo.inc.c +++ b/levels/ccm/ropeway_lift/geo.inc.c @@ -1,9 +1,9 @@ // 0x0E0003D0 const GeoLayout ccm_geo_0003D0[] = { - GEO_CULLING_RADIUS(500), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, ccm_seg7_dl_07010F28), - GEO_DISPLAY_LIST(LAYER_OPAQUE, ccm_seg7_dl_070118B0), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(500), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, ccm_seg7_dl_07010F28), + GEO_DISPLAY_LIST(LAYER_OPAQUE, ccm_seg7_dl_070118B0), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/ccm/script.c b/levels/ccm/script.c index c43f7891..38fda8c7 100644 --- a/levels/ccm/script.c +++ b/levels/ccm/script.c @@ -17,52 +17,52 @@ #include "levels/ccm/header.h" static const LevelScript script_func_local_1[] = { - OBJECT(/*model*/ MODEL_CCM_ROPEWAY_LIFT, /*pos*/ 531, -4430, 6426, /*angle*/ 0, 0, 0, /*behParam*/ 0x07120000, /*beh*/ bhvPlatformOnTrack), + OBJECT(/*model*/ MODEL_CCM_ROPEWAY_LIFT, /*pos*/ 531, -4430, 6426, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(0x07) | BPARAM2(0x12), /*bhv*/ bhvPlatformOnTrack), RETURN(), }; static const LevelScript script_func_local_2[] = { - OBJECT(/*model*/ MODEL_PENGUIN, /*pos*/ 2650, -3735, 3970, /*angle*/ 0, 0, 0, /*behParam*/ 0x00010000, /*beh*/ bhvSmallPenguin), - OBJECT(/*model*/ MODEL_PENGUIN, /*pos*/ -555, 3470, -1000, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvSmallPenguin), - OBJECT(/*model*/ MODEL_MR_BLIZZARD, /*pos*/ -2376, -1589, 4256, /*angle*/ 0, 252, 0, /*behParam*/ 0x00010000, /*beh*/ bhvMrBlizzard), - OBJECT(/*model*/ MODEL_MR_BLIZZARD, /*pos*/ -394, -1589, 4878, /*angle*/ 0, 74, 0, /*behParam*/ 0x00010000, /*beh*/ bhvMrBlizzard), - OBJECT_WITH_ACTS(/*model*/ MODEL_CCM_SNOWMAN_BASE, /*pos*/ 2560, 2662, -1122, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvSnowmansBottom, /*acts*/ ACT_5), + OBJECT (/*model*/ MODEL_PENGUIN, /*pos*/ 2650, -3735, 3970, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(0x01), /*bhv*/ bhvSmallPenguin), + OBJECT (/*model*/ MODEL_PENGUIN, /*pos*/ -555, 3470, -1000, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(0x00), /*bhv*/ bhvSmallPenguin), + OBJECT (/*model*/ MODEL_MR_BLIZZARD, /*pos*/ -2376, -1589, 4256, /*angle*/ 0, 252, 0, /*bhvParam*/ BPARAM2(MR_BLIZZARD_STYPE_JUMPING), /*bhv*/ bhvMrBlizzard), + OBJECT (/*model*/ MODEL_MR_BLIZZARD, /*pos*/ -394, -1589, 4878, /*angle*/ 0, 74, 0, /*bhvParam*/ BPARAM2(MR_BLIZZARD_STYPE_JUMPING), /*bhv*/ bhvMrBlizzard), + OBJECT_WITH_ACTS(/*model*/ MODEL_CCM_SNOWMAN_BASE, /*pos*/ 2560, 2662, -1122, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvSnowmansBottom, /*acts*/ ACT_5), RETURN(), }; static const LevelScript script_func_local_3[] = { - OBJECT_WITH_ACTS(/*model*/ MODEL_NONE, /*pos*/ 2665, -4607, 4525, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvCcmTouchedStarSpawn, /*acts*/ ALL_ACTS), - OBJECT_WITH_ACTS(/*model*/ MODEL_PENGUIN, /*pos*/ 3450, -4700, 4550, /*angle*/ 0, 0, 0, /*behParam*/ 0x01000000, /*beh*/ bhvTuxiesMother, /*acts*/ ALL_ACTS), - OBJECT_WITH_ACTS(/*model*/ MODEL_NONE, /*pos*/ 4200, -927, 400, /*angle*/ 0, 0, 0, /*behParam*/ 0x03000000, /*beh*/ bhvHiddenRedCoinStar, /*acts*/ ALL_ACTS), - OBJECT_WITH_ACTS(/*model*/ MODEL_CCM_SNOWMAN_HEAD, /*pos*/ -4230, -1169, 1813, /*angle*/ 0, 270, 0, /*behParam*/ 0x04000000, /*beh*/ bhvSnowmansHead, /*acts*/ ALL_ACTS), - OBJECT_WITH_ACTS(/*model*/ MODEL_STAR, /*pos*/ -2000, -2200, -3000, /*angle*/ 0, 0, 0, /*behParam*/ 0x05000000, /*beh*/ bhvStar, /*acts*/ ALL_ACTS), + OBJECT_WITH_ACTS(/*model*/ MODEL_NONE, /*pos*/ 2665, -4607, 4525, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(STAR_INDEX_ACT_1), /*bhv*/ bhvCCMTouchedStarSpawn, /*acts*/ ALL_ACTS), + OBJECT_WITH_ACTS(/*model*/ MODEL_PENGUIN, /*pos*/ 3450, -4700, 4550, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(STAR_INDEX_ACT_2), /*bhv*/ bhvTuxiesMother, /*acts*/ ALL_ACTS), + OBJECT_WITH_ACTS(/*model*/ MODEL_NONE, /*pos*/ 4200, -927, 400, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(STAR_INDEX_ACT_4), /*bhv*/ bhvHiddenRedCoinStar, /*acts*/ ALL_ACTS), + OBJECT_WITH_ACTS(/*model*/ MODEL_CCM_SNOWMAN_HEAD, /*pos*/ -4230, -1169, 1813, /*angle*/ 0, 270, 0, /*bhvParam*/ BPARAM1(STAR_INDEX_ACT_5), /*bhv*/ bhvSnowmansHead, /*acts*/ ALL_ACTS), + OBJECT_WITH_ACTS(/*model*/ MODEL_STAR, /*pos*/ -2000, -2200, -3000, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(STAR_INDEX_ACT_6), /*bhv*/ bhvStar, /*acts*/ ALL_ACTS), RETURN(), }; static const LevelScript script_func_local_4[] = { - OBJECT_WITH_ACTS(/*model*/ MODEL_PENGUIN, /*pos*/ -4952, 6656, -6075, /*angle*/ 0, 270, 0, /*behParam*/ 0x02000000, /*beh*/ bhvRacingPenguin, /*acts*/ ACT_2 | ACT_3 | ACT_4 | ACT_5 | ACT_6), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -6500, -5836, -6400, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvPenguinRaceFinishLine), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -6393, -716, 7503, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvPenguinRaceShortcutCheck), + OBJECT_WITH_ACTS(/*model*/ MODEL_PENGUIN, /*pos*/ -4952, 6656, -6075, /*angle*/ 0, 270, 0, /*bhvParam*/ BPARAM1(STAR_INDEX_ACT_3) | BPARAM2(RACING_PENGUIN_BP_THIN), /*bhv*/ bhvRacingPenguin, /*acts*/ ACT_2 | ACT_3 | ACT_4 | ACT_5 | ACT_6), + OBJECT (/*model*/ MODEL_NONE, /*pos*/ -6500, -5836, -6400, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvPenguinRaceFinishLine), + OBJECT (/*model*/ MODEL_NONE, /*pos*/ -6393, -716, 7503, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvPenguinRaceShortcutCheck), #ifndef VERSION_JP - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -4943, 1321, 667, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvPlaysMusicTrackWhenTouched), + OBJECT (/*model*/ MODEL_NONE, /*pos*/ -4943, 1321, 667, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvPlaysMusicTrackWhenTouched), #endif RETURN(), }; const LevelScript level_ccm_entry[] = { INIT_LEVEL(), - LOAD_MIO0( /*seg*/ 0x07, _ccm_segment_7SegmentRomStart, _ccm_segment_7SegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x07, _ccm_segment_7SegmentRomStart, _ccm_segment_7SegmentRomEnd), LOAD_MIO0_TEXTURE(/*seg*/ 0x09, _snow_mio0SegmentRomStart, _snow_mio0SegmentRomEnd), - LOAD_MIO0( /*seg*/ 0x0B, _effect_mio0SegmentRomStart, _effect_mio0SegmentRomEnd), - LOAD_MIO0( /*seg*/ 0x0A, _ccm_skybox_mio0SegmentRomStart, _ccm_skybox_mio0SegmentRomEnd), - LOAD_MIO0( /*seg*/ 0x05, _group7_mio0SegmentRomStart, _group7_mio0SegmentRomEnd), - LOAD_RAW( /*seg*/ 0x0C, _group7_geoSegmentRomStart, _group7_geoSegmentRomEnd), - LOAD_MIO0( /*seg*/ 0x06, _group16_mio0SegmentRomStart, _group16_mio0SegmentRomEnd), - LOAD_RAW( /*seg*/ 0x0D, _group16_geoSegmentRomStart, _group16_geoSegmentRomEnd), - LOAD_MIO0( /*seg*/ 0x08, _common0_mio0SegmentRomStart, _common0_mio0SegmentRomEnd), - LOAD_RAW( /*seg*/ 0x0F, _common0_geoSegmentRomStart, _common0_geoSegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x0B, _effect_mio0SegmentRomStart, _effect_mio0SegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x0A, _ccm_skybox_mio0SegmentRomStart, _ccm_skybox_mio0SegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x05, _group7_mio0SegmentRomStart, _group7_mio0SegmentRomEnd), + LOAD_RAW (/*seg*/ 0x0C, _group7_geoSegmentRomStart, _group7_geoSegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x06, _group16_mio0SegmentRomStart, _group16_mio0SegmentRomEnd), + LOAD_RAW (/*seg*/ 0x0D, _group16_geoSegmentRomStart, _group16_geoSegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x08, _common0_mio0SegmentRomStart, _common0_mio0SegmentRomEnd), + LOAD_RAW (/*seg*/ 0x0F, _common0_geoSegmentRomStart, _common0_geoSegmentRomEnd), ALLOC_LEVEL_POOL(), - MARIO(/*model*/ MODEL_MARIO, /*behParam*/ 0x00000001, /*beh*/ bhvMario), + MARIO(/*model*/ MODEL_MARIO, /*bhvParam*/ BPARAM4(0x01), /*bhv*/ bhvMario), JUMP_LINK(script_func_global_1), JUMP_LINK(script_func_global_8), JUMP_LINK(script_func_global_17), @@ -78,17 +78,17 @@ const LevelScript level_ccm_entry[] = { LOAD_MODEL_FROM_GEO(MODEL_CCM_SNOWMAN_HEAD, ccm_geo_00040C), AREA(/*index*/ 1, ccm_geo_00051C), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -1512, 3560, -2305, /*angle*/ 0, 140, 0, /*behParam*/ 0x000A0000, /*beh*/ bhvSpinAirborneWarp), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -181, 2918, -1486, /*angle*/ 0, 0, 0, /*behParam*/ 0x0F1E0000, /*beh*/ bhvWarp), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -1847, 2815, -321, /*angle*/ 0, -158, 0, /*behParam*/ 0x001F0000, /*beh*/ bhvFadingWarp), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 3349, -4694, -183, /*angle*/ 0, -34, 0, /*behParam*/ 0x00200000, /*beh*/ bhvFadingWarp), - WARP_NODE(/*id*/ 0x0A, /*destLevel*/ LEVEL_CCM, /*destArea*/ 0x01, /*destNode*/ 0x0A, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0x14, /*destLevel*/ LEVEL_CCM, /*destArea*/ 0x02, /*destNode*/ 0x14, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0x1E, /*destLevel*/ LEVEL_CCM, /*destArea*/ 0x02, /*destNode*/ 0x0A, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0x1F, /*destLevel*/ LEVEL_CCM, /*destArea*/ 0x01, /*destNode*/ 0x20, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0x20, /*destLevel*/ LEVEL_CCM, /*destArea*/ 0x01, /*destNode*/ 0x1F, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0xF0, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x01, /*destNode*/ 0x33, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0xF1, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x01, /*destNode*/ 0x65, /*flags*/ WARP_NO_CHECKPOINT), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ -1512, 3560, -2305, /*angle*/ 0, 140, 0, /*bhvParam*/ BPARAM2(WARP_NODE_0A), /*bhv*/ bhvSpinAirborneWarp), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ -181, 2918, -1486, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(15) | BPARAM2(WARP_NODE_1E), /*bhv*/ bhvWarp), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ -1847, 2815, -321, /*angle*/ 0, -158, 0, /*bhvParam*/ BPARAM2(WARP_NODE_1F), /*bhv*/ bhvFadingWarp), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 3349, -4694, -183, /*angle*/ 0, -34, 0, /*bhvParam*/ BPARAM2(WARP_NODE_20), /*bhv*/ bhvFadingWarp), + WARP_NODE(/*id*/ WARP_NODE_0A, /*destLevel*/ LEVEL_CCM, /*destArea*/ 1, /*destNode*/ WARP_NODE_0A, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_14, /*destLevel*/ LEVEL_CCM, /*destArea*/ 2, /*destNode*/ WARP_NODE_14, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_1E, /*destLevel*/ LEVEL_CCM, /*destArea*/ 2, /*destNode*/ WARP_NODE_0A, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_1F, /*destLevel*/ LEVEL_CCM, /*destArea*/ 1, /*destNode*/ WARP_NODE_20, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_20, /*destLevel*/ LEVEL_CCM, /*destArea*/ 1, /*destNode*/ WARP_NODE_1F, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_SUCCESS, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 1, /*destNode*/ WARP_NODE_33, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_DEATH, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 1, /*destNode*/ WARP_NODE_65, /*flags*/ WARP_NO_CHECKPOINT), JUMP_LINK(script_func_local_1), JUMP_LINK(script_func_local_2), JUMP_LINK(script_func_local_3), @@ -100,11 +100,11 @@ const LevelScript level_ccm_entry[] = { END_AREA(), AREA(/*index*/ 2, ccm_geo_0005E8), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -5836, 7465, -6143, /*angle*/ 0, 90, 0, /*behParam*/ 0x000A0000, /*beh*/ bhvAirborneWarp), - WARP_NODE(/*id*/ 0x14, /*destLevel*/ LEVEL_CCM, /*destArea*/ 0x01, /*destNode*/ 0x14, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0x0A, /*destLevel*/ LEVEL_CCM, /*destArea*/ 0x02, /*destNode*/ 0x0A, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0xF0, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x01, /*destNode*/ 0x33, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0xF1, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x01, /*destNode*/ 0x65, /*flags*/ WARP_NO_CHECKPOINT), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ -5836, 7465, -6143, /*angle*/ 0, 90, 0, /*bhvParam*/ BPARAM2(WARP_NODE_0A), /*bhv*/ bhvAirborneWarp), + WARP_NODE(/*id*/ WARP_NODE_14, /*destLevel*/ LEVEL_CCM, /*destArea*/ 1, /*destNode*/ WARP_NODE_14, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_0A, /*destLevel*/ LEVEL_CCM, /*destArea*/ 2, /*destNode*/ WARP_NODE_0A, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_SUCCESS, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 1, /*destNode*/ WARP_NODE_33, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_DEATH, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 1, /*destNode*/ WARP_NODE_65, /*flags*/ WARP_NO_CHECKPOINT), JUMP_LINK(script_func_local_4), TERRAIN(/*terrainData*/ ccm_seg7_area_2_collision), MACRO_OBJECTS(/*objList*/ ccm_seg7_area_2_macro_objs), diff --git a/levels/ccm/snowman_base/geo.inc.c b/levels/ccm/snowman_base/geo.inc.c index 57f2a3fc..6038acb1 100644 --- a/levels/ccm/snowman_base/geo.inc.c +++ b/levels/ccm/snowman_base/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E0003F0 const GeoLayout ccm_geo_0003F0[] = { - GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0xC8, 400), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, ccm_seg7_dl_07012BD8), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_SHADOW(SHADOW_CIRCLE_4_VERTS, 0xC8, 400), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, ccm_seg7_dl_07012BD8), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/ccm/snowman_head/geo.inc.c b/levels/ccm/snowman_head/geo.inc.c index 96142663..ee1b2cb2 100644 --- a/levels/ccm/snowman_head/geo.inc.c +++ b/levels/ccm/snowman_head/geo.inc.c @@ -1,9 +1,9 @@ // 0x0E00040C const GeoLayout ccm_geo_00040C[] = { - GEO_CULLING_RADIUS(300), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, ccm_seg7_dl_070136D0), - GEO_DISPLAY_LIST(LAYER_ALPHA, ccm_seg7_dl_07013870), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(300), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, ccm_seg7_dl_070136D0), + GEO_DISPLAY_LIST(LAYER_ALPHA, ccm_seg7_dl_07013870), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/cotmc/areas/1/geo.inc.c b/levels/cotmc/areas/1/geo.inc.c index 26fc0a4c..686f456c 100644 --- a/levels/cotmc/areas/1/geo.inc.c +++ b/levels/cotmc/areas/1/geo.inc.c @@ -1,30 +1,30 @@ // 0x0E0001A0 const GeoLayout cotmc_geo_0001A0[] = { - GEO_NODE_SCREEN_AREA(10, SCREEN_WIDTH/2, SCREEN_HEIGHT/2, SCREEN_WIDTH/2, SCREEN_HEIGHT/2), - GEO_OPEN_NODE(), - GEO_ZBUFFER(0), - GEO_OPEN_NODE(), - GEO_NODE_ORTHO(100), - GEO_OPEN_NODE(), - GEO_BACKGROUND_COLOR(0x0001), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ZBUFFER(1), - GEO_OPEN_NODE(), - GEO_CAMERA_FRUSTUM_WITH_FUNC(45, 100, 12800, geo_camera_fov), - GEO_OPEN_NODE(), - GEO_CAMERA(16, 0, 2000, 6000, 0, 0, 0, geo_camera_main), + GEO_NODE_SCREEN_AREA(10, SCREEN_WIDTH/2, SCREEN_HEIGHT/2, SCREEN_WIDTH/2, SCREEN_HEIGHT/2), + GEO_OPEN_NODE(), + GEO_ZBUFFER(0), + GEO_OPEN_NODE(), + GEO_NODE_ORTHO(100), GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, cotmc_seg7_dl_07007D48), - GEO_DISPLAY_LIST(LAYER_OPAQUE, cotmc_seg7_dl_0700A160), - GEO_ASM( 0, geo_movtex_pause_control), - GEO_ASM(0x2801, geo_movtex_draw_nocolor), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, cotmc_seg7_dl_0700A4B8), - GEO_RENDER_OBJ(), - GEO_ASM(0, geo_envfx_main), + GEO_BACKGROUND_COLOR(0x0001), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CLOSE_NODE(), + GEO_ZBUFFER(1), + GEO_OPEN_NODE(), + GEO_CAMERA_FRUSTUM_WITH_FUNC(45, 100, 12800, geo_camera_fov), + GEO_OPEN_NODE(), + GEO_CAMERA(16, 0, 2000, 6000, 0, 0, 0, geo_camera_main), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, cotmc_seg7_dl_07007D48), + GEO_DISPLAY_LIST(LAYER_OPAQUE, cotmc_seg7_dl_0700A160), + GEO_ASM( 0, geo_movtex_pause_control), + GEO_ASM(0x2801, geo_movtex_draw_nocolor), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, cotmc_seg7_dl_0700A4B8), + GEO_RENDER_OBJ(), + GEO_ASM(0, geo_envfx_main), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/cotmc/areas/1/macro.inc.c b/levels/cotmc/areas/1/macro.inc.c index 0792e633..78d8a374 100644 --- a/levels/cotmc/areas/1/macro.inc.c +++ b/levels/cotmc/areas/1/macro.inc.c @@ -1,25 +1,25 @@ // 0x0700BD38 - 0x0700BE0C const MacroObject cotmc_seg7_macro_objs[] = { - MACRO_OBJECT(/*preset*/ macro_snufit, /*yaw*/ 0, /*pos*/ -2920, 220, -20), - MACRO_OBJECT(/*preset*/ macro_snufit, /*yaw*/ 0, /*pos*/ -1380, 240, 740), - MACRO_OBJECT(/*preset*/ macro_box_metal_cap, /*yaw*/ 0, /*pos*/ -360, 300, -200), - MACRO_OBJECT(/*preset*/ macro_snufit, /*yaw*/ 0, /*pos*/ 360, 200, -1120), - MACRO_OBJECT(/*preset*/ macro_coin_line_horizontal, /*yaw*/ 0, /*pos*/ 400, 256, -4300), - MACRO_OBJECT(/*preset*/ macro_box_metal_cap, /*yaw*/ 0, /*pos*/ 300, 620, -5280), - MACRO_OBJECT(/*preset*/ macro_snufit, /*yaw*/ 0, /*pos*/ -340, 260, -2620), - MACRO_OBJECT(/*preset*/ macro_coin_ring_horizontal, /*yaw*/ 0, /*pos*/ 0, -450, -7000), - MACRO_OBJECT(/*preset*/ macro_1up, /*yaw*/ 0, /*pos*/ 900, 260, -3620), - MACRO_OBJECT(/*preset*/ macro_coin_line_horizontal, /*yaw*/ 0, /*pos*/ 0, -170, -1660), - MACRO_OBJECT(/*preset*/ macro_coin_line_horizontal, /*yaw*/ 0, /*pos*/ -20, -211, -3940), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 270, /*pos*/ -71, 20, 720, /*behParam*/ DIALOG_123), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 200, -291, -5600), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 980, 260, -3430), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -540, -352, -5940), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -300, 450, -6240), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -200, -400, -6680), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 250, 450, -6400), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 540, -361, -6340), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 980, 260, -3810), - MACRO_OBJECT(/*preset*/ macro_box_1up_running_away, /*yaw*/ 0, /*pos*/ -20, 180, 2060), + MACRO_OBJECT (/*preset*/ macro_snufit, /*yaw*/ 0, /*pos*/ -2920, 220, -20), + MACRO_OBJECT (/*preset*/ macro_snufit, /*yaw*/ 0, /*pos*/ -1380, 240, 740), + MACRO_OBJECT (/*preset*/ macro_box_metal_cap, /*yaw*/ 0, /*pos*/ -360, 300, -200), + MACRO_OBJECT (/*preset*/ macro_snufit, /*yaw*/ 0, /*pos*/ 360, 200, -1120), + MACRO_OBJECT (/*preset*/ macro_coin_line_horizontal, /*yaw*/ 0, /*pos*/ 400, 256, -4300), + MACRO_OBJECT (/*preset*/ macro_box_metal_cap, /*yaw*/ 0, /*pos*/ 300, 620, -5280), + MACRO_OBJECT (/*preset*/ macro_snufit, /*yaw*/ 0, /*pos*/ -340, 260, -2620), + MACRO_OBJECT (/*preset*/ macro_coin_ring_horizontal, /*yaw*/ 0, /*pos*/ 0, -450, -7000), + MACRO_OBJECT (/*preset*/ macro_1up, /*yaw*/ 0, /*pos*/ 900, 260, -3620), + MACRO_OBJECT (/*preset*/ macro_coin_line_horizontal, /*yaw*/ 0, /*pos*/ 0, -170, -1660), + MACRO_OBJECT (/*preset*/ macro_coin_line_horizontal, /*yaw*/ 0, /*pos*/ -20, -211, -3940), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 270, /*pos*/ -71, 20, 720, /*bhvParam*/ DIALOG_123), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 200, -291, -5600), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 980, 260, -3430), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -540, -352, -5940), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -300, 450, -6240), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -200, -400, -6680), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 250, 450, -6400), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 540, -361, -6340), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 980, 260, -3810), + MACRO_OBJECT (/*preset*/ macro_box_1up_running_away, /*yaw*/ 0, /*pos*/ -20, 180, 2060), MACRO_OBJECT_END(), }; diff --git a/levels/cotmc/leveldata.c b/levels/cotmc/leveldata.c index ae5abbea..1711438c 100644 --- a/levels/cotmc/leveldata.c +++ b/levels/cotmc/leveldata.c @@ -3,8 +3,8 @@ #include "surface_terrains.h" #include "moving_texture_macros.h" #include "level_misc_macros.h" -#include "macro_preset_names.h" -#include "special_preset_names.h" +#include "macro_presets.h" +#include "special_presets.h" #include "textures.h" #include "dialog_ids.h" diff --git a/levels/cotmc/script.c b/levels/cotmc/script.c index 118136ce..9800c0f4 100644 --- a/levels/cotmc/script.c +++ b/levels/cotmc/script.c @@ -17,39 +17,39 @@ #include "levels/cotmc/header.h" static const LevelScript script_func_local_1[] = { - OBJECT(/*model*/ MODEL_CAP_SWITCH, /*pos*/ 0, 363, -6144, /*angle*/ 0, 0, 0, /*behParam*/ 0x00010000, /*beh*/ bhvCapSwitch), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 0, 500, -7373, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvWaterfallSoundLoop), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 0, 500, 3584, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvWaterfallSoundLoop), + OBJECT(/*model*/ MODEL_CAP_SWITCH, /*pos*/ 0, 363, -6144, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(0x01), /*bhv*/ bhvCapSwitch), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 0, 500, -7373, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvWaterfallSoundLoop), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 0, 500, 3584, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvWaterfallSoundLoop), RETURN(), }; static const LevelScript script_func_local_2[] = { - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 0, -200, -7000, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvHiddenRedCoinStar), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 0, -200, -7000, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(STAR_INDEX_ACT_1), /*bhv*/ bhvHiddenRedCoinStar), RETURN(), }; const LevelScript level_cotmc_entry[] = { INIT_LEVEL(), - LOAD_MIO0( /*seg*/ 0x07, _cotmc_segment_7SegmentRomStart, _cotmc_segment_7SegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x07, _cotmc_segment_7SegmentRomStart, _cotmc_segment_7SegmentRomEnd), LOAD_MIO0_TEXTURE(/*seg*/ 0x09, _cave_mio0SegmentRomStart, _cave_mio0SegmentRomEnd), - LOAD_MIO0( /*seg*/ 0x05, _group8_mio0SegmentRomStart, _group8_mio0SegmentRomEnd), - LOAD_RAW( /*seg*/ 0x0C, _group8_geoSegmentRomStart, _group8_geoSegmentRomEnd), - LOAD_MIO0( /*seg*/ 0x06, _group17_mio0SegmentRomStart, _group17_mio0SegmentRomEnd), - LOAD_RAW( /*seg*/ 0x0D, _group17_geoSegmentRomStart, _group17_geoSegmentRomEnd), - LOAD_MIO0( /*seg*/ 0x08, _common0_mio0SegmentRomStart, _common0_mio0SegmentRomEnd), - LOAD_RAW( /*seg*/ 0x0F, _common0_geoSegmentRomStart, _common0_geoSegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x05, _group8_mio0SegmentRomStart, _group8_mio0SegmentRomEnd), + LOAD_RAW (/*seg*/ 0x0C, _group8_geoSegmentRomStart, _group8_geoSegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x06, _group17_mio0SegmentRomStart, _group17_mio0SegmentRomEnd), + LOAD_RAW (/*seg*/ 0x0D, _group17_geoSegmentRomStart, _group17_geoSegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x08, _common0_mio0SegmentRomStart, _common0_mio0SegmentRomEnd), + LOAD_RAW (/*seg*/ 0x0F, _common0_geoSegmentRomStart, _common0_geoSegmentRomEnd), ALLOC_LEVEL_POOL(), - MARIO(/*model*/ MODEL_MARIO, /*behParam*/ 0x00000001, /*beh*/ bhvMario), + MARIO(/*model*/ MODEL_MARIO, /*bhvParam*/ BPARAM4(0x01), /*bhv*/ bhvMario), JUMP_LINK(script_func_global_9), JUMP_LINK(script_func_global_18), JUMP_LINK(script_func_global_1), AREA(/*index*/ 1, cotmc_geo_0001A0), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -4185, 1020, -47, /*angle*/ 0, 90, 0, /*behParam*/ 0x000A0000, /*beh*/ bhvAirborneWarp), - WARP_NODE(/*id*/ 0x0A, /*destLevel*/ LEVEL_COTMC, /*destArea*/ 0x01, /*destNode*/ 0x0A, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0xF0, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x03, /*destNode*/ 0x34, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0xF1, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x03, /*destNode*/ 0x66, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0xF3, /*destLevel*/ LEVEL_CASTLE_GROUNDS, /*destArea*/ 0x01, /*destNode*/ 0x14, /*flags*/ WARP_NO_CHECKPOINT), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ -4185, 1020, -47, /*angle*/ 0, 90, 0, /*bhvParam*/ BPARAM2(WARP_NODE_0A), /*bhv*/ bhvAirborneWarp), + WARP_NODE(/*id*/ WARP_NODE_0A, /*destLevel*/ LEVEL_COTMC, /*destArea*/ 1, /*destNode*/ WARP_NODE_0A, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_SUCCESS, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 3, /*destNode*/ WARP_NODE_34, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_DEATH, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 3, /*destNode*/ WARP_NODE_66, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_WARP_FLOOR, /*destLevel*/ LEVEL_CASTLE_GROUNDS, /*destArea*/ 1, /*destNode*/ WARP_NODE_14, /*flags*/ WARP_NO_CHECKPOINT), JUMP_LINK(script_func_local_2), JUMP_LINK(script_func_local_1), TERRAIN(/*terrainData*/ cotmc_seg7_collision_level), diff --git a/levels/course_defines.h b/levels/course_defines.h index 600cead4..f028b78e 100644 --- a/levels/course_defines.h +++ b/levels/course_defines.h @@ -11,18 +11,18 @@ * 4: Default, used for 100 coin stars, 8 red coin stars in bowser levels, and secret stars */ DEFINE_COURSE(COURSE_NONE, 0x44444440) // (0) Course Hub (Castle Grounds) -DEFINE_COURSE(COURSE_BOB, 0x00022240) // (1) Bob Omb Battlefield +DEFINE_COURSE(COURSE_BOB, 0x00022240) // (1) Bob-omb Battlefield DEFINE_COURSE(COURSE_WF, 0x00002040) // (2) Whomp's Fortress -DEFINE_COURSE(COURSE_JRB, 0x22222240) // (3) Jolly Rodger's Bay -DEFINE_COURSE(COURSE_CCM, 0x00220040) // (4) Cool Cool Mountain +DEFINE_COURSE(COURSE_JRB, 0x22222240) // (3) Jolly Roger Bay +DEFINE_COURSE(COURSE_CCM, 0x00220040) // (4) Cool, Cool Mountain DEFINE_COURSE(COURSE_BBH, 0x22222240) // (5) Big Boo's Haunt DEFINE_COURSE(COURSE_HMC, 0x22222240) // (6) Hazy Maze Cave DEFINE_COURSE(COURSE_LLL, 0x21212140) // (7) Lethal Lava Land DEFINE_COURSE(COURSE_SSL, 0x20222240) // (8) Shifting Sand Land DEFINE_COURSE(COURSE_DDD, 0x22222240) // (9) Dire Dire Docks DEFINE_COURSE(COURSE_SL, 0x02020240) // (10) Snowman's Land -DEFINE_COURSE(COURSE_WDW, 0x22102240) // (11) Wet Dry World -DEFINE_COURSE(COURSE_TTM, 0x00000040) // (12) Tall Tall Mountain +DEFINE_COURSE(COURSE_WDW, 0x22102240) // (11) Wet-Dry World +DEFINE_COURSE(COURSE_TTM, 0x00000040) // (12) Tall, Tall Mountain DEFINE_COURSE(COURSE_THI, 0x11112140) // (13) Tiny Huge Island DEFINE_COURSE(COURSE_TTC, 0x22222240) // (14) Tick Tock Clock DEFINE_COURSE(COURSE_RR, 0x00000040) // (15) Rainbow Ride @@ -30,10 +30,10 @@ DEFINE_COURSES_END() DEFINE_BONUS_COURSE(COURSE_BITDW, 0x34444440) // (16) Bowser in the Dark World DEFINE_BONUS_COURSE(COURSE_BITFS, 0x34444440) // (17) Bowser in the Fire Sea DEFINE_BONUS_COURSE(COURSE_BITS, 0x34444440) // (18) Bowser in the Sky -DEFINE_BONUS_COURSE(COURSE_PSS, 0x24444440) // (19) Princess's Secret Slide +DEFINE_BONUS_COURSE(COURSE_PSS, 0x24444440) // (19) The Princess's Secret Slide DEFINE_BONUS_COURSE(COURSE_COTMC, 0x44444440) // (20) Cavern of the Metal Cap DEFINE_BONUS_COURSE(COURSE_TOTWC, 0x04444440) // (21) Tower of the Wing Cap -DEFINE_BONUS_COURSE(COURSE_VCUTM, 0x24444440) // (22) Vanish Cap Under the Moat -DEFINE_BONUS_COURSE(COURSE_WMOTR, 0x04444440) // (23) Winged Mario over the Rainbow +DEFINE_BONUS_COURSE(COURSE_VCUTM, 0x24444440) // (22) Vanish Cap under the Moat +DEFINE_BONUS_COURSE(COURSE_WMOTR, 0x04444440) // (23) Wing Mario over the Rainbow DEFINE_BONUS_COURSE(COURSE_SA, 0x24444440) // (24) Secret Aquarium DEFINE_BONUS_COURSE(COURSE_CAKE_END, 0x44444440) // (25) The End (Cake Scene) diff --git a/levels/ddd/areas/1/geo.inc.c b/levels/ddd/areas/1/geo.inc.c index e58d7e1e..91318cd0 100644 --- a/levels/ddd/areas/1/geo.inc.c +++ b/levels/ddd/areas/1/geo.inc.c @@ -1,31 +1,31 @@ // 0x0E0004C0 const GeoLayout ddd_geo_0004C0[] = { - GEO_NODE_SCREEN_AREA(10, SCREEN_WIDTH/2, SCREEN_HEIGHT/2, SCREEN_WIDTH/2, SCREEN_HEIGHT/2), - GEO_OPEN_NODE(), - GEO_ZBUFFER(0), - GEO_OPEN_NODE(), - GEO_NODE_ORTHO(100), - GEO_OPEN_NODE(), - GEO_BACKGROUND(BACKGROUND_OCEAN_SKY, geo_skybox_main), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ZBUFFER(1), - GEO_OPEN_NODE(), - GEO_CAMERA_FRUSTUM_WITH_FUNC(45, 100, 12800, geo_camera_fov), - GEO_OPEN_NODE(), - GEO_CAMERA(2, 0, 2000, 6000, 2560, 0, 512, geo_camera_main), + GEO_NODE_SCREEN_AREA(10, SCREEN_WIDTH/2, SCREEN_HEIGHT/2, SCREEN_WIDTH/2, SCREEN_HEIGHT/2), + GEO_OPEN_NODE(), + GEO_ZBUFFER(0), + GEO_OPEN_NODE(), + GEO_NODE_ORTHO(100), GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, ddd_seg7_dl_07004D48), - GEO_DISPLAY_LIST(LAYER_OPAQUE, ddd_seg7_dl_070057E8), - GEO_DISPLAY_LIST(LAYER_ALPHA, ddd_seg7_dl_07005C40), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, ddd_seg7_dl_07005F78), - GEO_ASM( 0, geo_movtex_pause_control), - GEO_ASM(0x2301, geo_movtex_draw_water_regions), - GEO_RENDER_OBJ(), - GEO_ASM( 13, geo_envfx_main), + GEO_BACKGROUND(BACKGROUND_OCEAN_SKY, geo_skybox_main), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CLOSE_NODE(), + GEO_ZBUFFER(1), + GEO_OPEN_NODE(), + GEO_CAMERA_FRUSTUM_WITH_FUNC(45, 100, 12800, geo_camera_fov), + GEO_OPEN_NODE(), + GEO_CAMERA(2, 0, 2000, 6000, 2560, 0, 512, geo_camera_main), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, ddd_seg7_dl_07004D48), + GEO_DISPLAY_LIST(LAYER_OPAQUE, ddd_seg7_dl_070057E8), + GEO_DISPLAY_LIST(LAYER_ALPHA, ddd_seg7_dl_07005C40), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, ddd_seg7_dl_07005F78), + GEO_ASM( 0, geo_movtex_pause_control), + GEO_ASM(0x2301, geo_movtex_draw_water_regions), + GEO_RENDER_OBJ(), + GEO_ASM( 13, geo_envfx_main), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/ddd/areas/1/macro.inc.c b/levels/ddd/areas/1/macro.inc.c index 6544cfdb..0b094aeb 100644 --- a/levels/ddd/areas/1/macro.inc.c +++ b/levels/ddd/areas/1/macro.inc.c @@ -1,22 +1,22 @@ // 0x0700EEF4 - 0x0700EFAA const MacroObject ddd_seg7_area_1_macro_objs[] = { - MACRO_OBJECT(/*preset*/ macro_seaweed_bundle, /*yaw*/ 0, /*pos*/ -2880, -5120, -1850), - MACRO_OBJECT(/*preset*/ macro_clam_shell, /*yaw*/ 90, /*pos*/ -4760, -5120, 580), - MACRO_OBJECT(/*preset*/ macro_seaweed_bundle, /*yaw*/ 0, /*pos*/ -3510, -5120, 1950), - MACRO_OBJECT(/*preset*/ macro_hidden_1up_trigger, /*yaw*/ 0, /*pos*/ -4760, -5100, 580), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_hidden_1up, /*yaw*/ 0, /*pos*/ -4760, -5080, 580, /*behParam*/ 1), - MACRO_OBJECT(/*preset*/ macro_coin_ring_vertical, /*yaw*/ 90, /*pos*/ -1000, -4250, 0), - MACRO_OBJECT(/*preset*/ macro_fish_group, /*yaw*/ 0, /*pos*/ -4646, -4615, -800), - MACRO_OBJECT(/*preset*/ macro_fish_group_2, /*yaw*/ 0, /*pos*/ -1804, -2560, 1292), - MACRO_OBJECT(/*preset*/ macro_coin_line_vertical, /*yaw*/ 0, /*pos*/ -3760, -4560, 660), - MACRO_OBJECT(/*preset*/ macro_coin_line_vertical, /*yaw*/ 0, /*pos*/ -4240, -4786, 1180), - MACRO_OBJECT(/*preset*/ macro_coin_line_horizontal, /*yaw*/ 315, /*pos*/ -4840, -1137, 1860), - MACRO_OBJECT(/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ -2180, -5119, 1720), - MACRO_OBJECT(/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ -1460, -5119, 1300), - MACRO_OBJECT(/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ -1320, -5119, 840), - MACRO_OBJECT(/*preset*/ macro_fish_group, /*yaw*/ 0, /*pos*/ -3580, -2280, -1120), - MACRO_OBJECT(/*preset*/ macro_fish_group, /*yaw*/ 0, /*pos*/ -2020, -3460, -120), - MACRO_OBJECT(/*preset*/ macro_coin_ring_vertical, /*yaw*/ 90, /*pos*/ 0, -4250, 0), - MACRO_OBJECT(/*preset*/ macro_coin_ring_vertical, /*yaw*/ 90, /*pos*/ -2000, -4250, 0), + MACRO_OBJECT (/*preset*/ macro_seaweed_bundle, /*yaw*/ 0, /*pos*/ -2880, -5120, -1850), + MACRO_OBJECT (/*preset*/ macro_clam_shell, /*yaw*/ 90, /*pos*/ -4760, -5120, 580), + MACRO_OBJECT (/*preset*/ macro_seaweed_bundle, /*yaw*/ 0, /*pos*/ -3510, -5120, 1950), + MACRO_OBJECT (/*preset*/ macro_hidden_1up_trigger, /*yaw*/ 0, /*pos*/ -4760, -5100, 580), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_hidden_1up, /*yaw*/ 0, /*pos*/ -4760, -5080, 580, /*bhvParam*/ 1), + MACRO_OBJECT (/*preset*/ macro_coin_ring_vertical_flying, /*yaw*/ 90, /*pos*/ -1000, -4250, 0), + MACRO_OBJECT (/*preset*/ macro_fish_spawner_few_blue, /*yaw*/ 0, /*pos*/ -4646, -4615, -800), + MACRO_OBJECT (/*preset*/ macro_fish_spawner_few_cyan, /*yaw*/ 0, /*pos*/ -1804, -2560, 1292), + MACRO_OBJECT (/*preset*/ macro_coin_line_vertical_flying, /*yaw*/ 0, /*pos*/ -3760, -4560, 660), + MACRO_OBJECT (/*preset*/ macro_coin_line_vertical_flying, /*yaw*/ 0, /*pos*/ -4240, -4786, 1180), + MACRO_OBJECT (/*preset*/ macro_coin_line_horizontal, /*yaw*/ 315, /*pos*/ -4840, -1137, 1860), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ -2180, -5119, 1720), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ -1460, -5119, 1300), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ -1320, -5119, 840), + MACRO_OBJECT (/*preset*/ macro_fish_spawner_few_blue, /*yaw*/ 0, /*pos*/ -3580, -2280, -1120), + MACRO_OBJECT (/*preset*/ macro_fish_spawner_few_blue, /*yaw*/ 0, /*pos*/ -2020, -3460, -120), + MACRO_OBJECT (/*preset*/ macro_coin_ring_vertical_flying, /*yaw*/ 90, /*pos*/ 0, -4250, 0), + MACRO_OBJECT (/*preset*/ macro_coin_ring_vertical_flying, /*yaw*/ 90, /*pos*/ -2000, -4250, 0), MACRO_OBJECT_END(), }; diff --git a/levels/ddd/areas/2/geo.inc.c b/levels/ddd/areas/2/geo.inc.c index 68201f70..8c5c537b 100644 --- a/levels/ddd/areas/2/geo.inc.c +++ b/levels/ddd/areas/2/geo.inc.c @@ -1,33 +1,33 @@ // 0x0E000570 const GeoLayout ddd_geo_000570[] = { - GEO_NODE_SCREEN_AREA(10, SCREEN_WIDTH/2, SCREEN_HEIGHT/2, SCREEN_WIDTH/2, SCREEN_HEIGHT/2), - GEO_OPEN_NODE(), - GEO_ZBUFFER(0), - GEO_OPEN_NODE(), - GEO_NODE_ORTHO(100), - GEO_OPEN_NODE(), - GEO_BACKGROUND_COLOR(0x0001), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ZBUFFER(1), - GEO_OPEN_NODE(), - GEO_CAMERA_FRUSTUM_WITH_FUNC(45, 100, 12800, geo_camera_fov), - GEO_OPEN_NODE(), - GEO_CAMERA(4, 0, 2000, 6000, 2560, 0, 512, geo_camera_main), + GEO_NODE_SCREEN_AREA(10, SCREEN_WIDTH/2, SCREEN_HEIGHT/2, SCREEN_WIDTH/2, SCREEN_HEIGHT/2), + GEO_OPEN_NODE(), + GEO_ZBUFFER(0), + GEO_OPEN_NODE(), + GEO_NODE_ORTHO(100), GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, ddd_seg7_dl_07007408), - GEO_DISPLAY_LIST(LAYER_OPAQUE, ddd_seg7_dl_07007CB8), - GEO_DISPLAY_LIST(LAYER_ALPHA, ddd_seg7_dl_07008C48), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, ddd_seg7_dl_07008F80), - GEO_DISPLAY_LIST(LAYER_ALPHA, ddd_seg7_dl_0700BAE0), - GEO_DISPLAY_LIST(LAYER_OPAQUE, ddd_seg7_dl_0700CE48), - GEO_ASM( 0, geo_movtex_pause_control), - GEO_ASM(0x2302, geo_movtex_draw_water_regions), - GEO_RENDER_OBJ(), - GEO_ASM( 14, geo_envfx_main), + GEO_BACKGROUND_COLOR(0x0001), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CLOSE_NODE(), + GEO_ZBUFFER(1), + GEO_OPEN_NODE(), + GEO_CAMERA_FRUSTUM_WITH_FUNC(45, 100, 12800, geo_camera_fov), + GEO_OPEN_NODE(), + GEO_CAMERA(4, 0, 2000, 6000, 2560, 0, 512, geo_camera_main), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, ddd_seg7_dl_07007408), + GEO_DISPLAY_LIST(LAYER_OPAQUE, ddd_seg7_dl_07007CB8), + GEO_DISPLAY_LIST(LAYER_ALPHA, ddd_seg7_dl_07008C48), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, ddd_seg7_dl_07008F80), + GEO_DISPLAY_LIST(LAYER_ALPHA, ddd_seg7_dl_0700BAE0), + GEO_DISPLAY_LIST(LAYER_OPAQUE, ddd_seg7_dl_0700CE48), + GEO_ASM( 0, geo_movtex_pause_control), + GEO_ASM(0x2302, geo_movtex_draw_water_regions), + GEO_RENDER_OBJ(), + GEO_ASM( 14, geo_envfx_main), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/ddd/areas/2/macro.inc.c b/levels/ddd/areas/2/macro.inc.c index f442f350..8278e5d4 100644 --- a/levels/ddd/areas/2/macro.inc.c +++ b/levels/ddd/areas/2/macro.inc.c @@ -1,50 +1,50 @@ // 0x0700EFAC - 0x0700F17A const MacroObject ddd_seg7_area_2_macro_objs[] = { - MACRO_OBJECT(/*preset*/ macro_box_metal_cap, /*yaw*/ 0, /*pos*/ 6800, 500, -850), - MACRO_OBJECT(/*preset*/ macro_box_vanish_cap, /*yaw*/ 0, /*pos*/ 6800, 500, -150), - MACRO_OBJECT(/*preset*/ macro_floor_switch_hidden_objects, /*yaw*/ 0, /*pos*/ 6800, 110, 2000), - MACRO_OBJECT(/*preset*/ macro_hidden_box, /*yaw*/ 0, /*pos*/ 6075, -100, 2000), - MACRO_OBJECT(/*preset*/ macro_hidden_box, /*yaw*/ 0, /*pos*/ 5875, 100, 2000), - MACRO_OBJECT(/*preset*/ macro_hidden_box, /*yaw*/ 0, /*pos*/ 5675, 100, 2000), - MACRO_OBJECT(/*preset*/ macro_hidden_box, /*yaw*/ 0, /*pos*/ 5475, 300, 2000), - MACRO_OBJECT(/*preset*/ macro_hidden_box, /*yaw*/ 0, /*pos*/ 5275, 300, 2000), - MACRO_OBJECT(/*preset*/ macro_hidden_box, /*yaw*/ 0, /*pos*/ 5075, 500, 2000), - MACRO_OBJECT(/*preset*/ macro_hidden_box, /*yaw*/ 0, /*pos*/ 4875, 500, 2000), - MACRO_OBJECT(/*preset*/ macro_hidden_box, /*yaw*/ 0, /*pos*/ 6275, -100, 2000), - MACRO_OBJECT(/*preset*/ macro_hidden_box, /*yaw*/ 0, /*pos*/ 6475, -100, 2000), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 4680, 1155, -2200), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 3525, 1155, -2250), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 3850, 1111, 3550), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 4400, 1288, 3595), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 2974, 1015, 3584), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 5550, 1015, 3575), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 3300, 1111, -1900), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 2100, 1025, -1600), - MACRO_OBJECT(/*preset*/ macro_fish_group, /*yaw*/ 0, /*pos*/ 2061, -3323, 2246), - MACRO_OBJECT(/*preset*/ macro_fish_group_2, /*yaw*/ 0, /*pos*/ 5661, -2923, -1415), - MACRO_OBJECT(/*preset*/ macro_clam_shell, /*yaw*/ 90, /*pos*/ 1273, -4106, 2320), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 180, /*pos*/ 3086, 110, 6120, /*behParam*/ DIALOG_053), - MACRO_OBJECT(/*preset*/ macro_seaweed_bundle, /*yaw*/ 0, /*pos*/ 6420, -4106, -2026), - MACRO_OBJECT(/*preset*/ macro_seaweed_bundle, /*yaw*/ 0, /*pos*/ 6340, -4106, -1413), - MACRO_OBJECT(/*preset*/ macro_clam_shell, /*yaw*/ 135, /*pos*/ 1966, -4106, 3226), - MACRO_OBJECT(/*preset*/ macro_clam_shell, /*yaw*/ 180, /*pos*/ 3886, -4006, 5130), - MACRO_OBJECT(/*preset*/ macro_hidden_box, /*yaw*/ 0, /*pos*/ 5740, 710, 3900), - MACRO_OBJECT(/*preset*/ macro_hidden_box, /*yaw*/ 0, /*pos*/ 5740, 510, 4100), - MACRO_OBJECT(/*preset*/ macro_hidden_box, /*yaw*/ 0, /*pos*/ 5740, 310, 4300), - MACRO_OBJECT(/*preset*/ macro_hidden_box, /*yaw*/ 0, /*pos*/ 5740, 110, 4500), - MACRO_OBJECT(/*preset*/ macro_seaweed_bundle, /*yaw*/ 0, /*pos*/ 2999, -4092, 4430), - MACRO_OBJECT(/*preset*/ macro_coin_ring_horizontal, /*yaw*/ 0, /*pos*/ 4876, -4087, 4430), - MACRO_OBJECT(/*preset*/ macro_coin_line_vertical, /*yaw*/ 0, /*pos*/ 3892, -4030, -3830), - MACRO_OBJECT(/*preset*/ macro_coin_line_horizontal, /*yaw*/ 90, /*pos*/ 3923, 110, 5953), - MACRO_OBJECT(/*preset*/ macro_fire_spitter, /*yaw*/ 0, /*pos*/ 938, 153, 4107), - MACRO_OBJECT(/*preset*/ macro_hidden_box, /*yaw*/ 0, /*pos*/ 5940, 110, 4500), - MACRO_OBJECT(/*preset*/ macro_blue_coin_switch, /*yaw*/ 0, /*pos*/ 1614, 928, 922), - MACRO_OBJECT(/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ 1414, 1020, 622), - MACRO_OBJECT(/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ 1814, 1020, 622), - MACRO_OBJECT(/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ 1814, 1020, 1222), - MACRO_OBJECT(/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ 1414, 1020, 1222), - MACRO_OBJECT(/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ 1414, 1020, 922), - MACRO_OBJECT(/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ 1814, 1020, 922), - MACRO_OBJECT(/*preset*/ macro_koopa_shell_underwater, /*yaw*/ 0, /*pos*/ 3886, -4050, 5100), + MACRO_OBJECT (/*preset*/ macro_box_metal_cap, /*yaw*/ 0, /*pos*/ 6800, 500, -850), + MACRO_OBJECT (/*preset*/ macro_box_vanish_cap, /*yaw*/ 0, /*pos*/ 6800, 500, -150), + MACRO_OBJECT (/*preset*/ macro_floor_switch_hidden_objects, /*yaw*/ 0, /*pos*/ 6800, 110, 2000), + MACRO_OBJECT (/*preset*/ macro_hidden_breakable_box, /*yaw*/ 0, /*pos*/ 6075, -100, 2000), + MACRO_OBJECT (/*preset*/ macro_hidden_breakable_box, /*yaw*/ 0, /*pos*/ 5875, 100, 2000), + MACRO_OBJECT (/*preset*/ macro_hidden_breakable_box, /*yaw*/ 0, /*pos*/ 5675, 100, 2000), + MACRO_OBJECT (/*preset*/ macro_hidden_breakable_box, /*yaw*/ 0, /*pos*/ 5475, 300, 2000), + MACRO_OBJECT (/*preset*/ macro_hidden_breakable_box, /*yaw*/ 0, /*pos*/ 5275, 300, 2000), + MACRO_OBJECT (/*preset*/ macro_hidden_breakable_box, /*yaw*/ 0, /*pos*/ 5075, 500, 2000), + MACRO_OBJECT (/*preset*/ macro_hidden_breakable_box, /*yaw*/ 0, /*pos*/ 4875, 500, 2000), + MACRO_OBJECT (/*preset*/ macro_hidden_breakable_box, /*yaw*/ 0, /*pos*/ 6275, -100, 2000), + MACRO_OBJECT (/*preset*/ macro_hidden_breakable_box, /*yaw*/ 0, /*pos*/ 6475, -100, 2000), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 4680, 1155, -2200), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 3525, 1155, -2250), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 3850, 1111, 3550), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 4400, 1288, 3595), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 2974, 1015, 3584), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 5550, 1015, 3575), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 3300, 1111, -1900), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 2100, 1025, -1600), + MACRO_OBJECT (/*preset*/ macro_fish_spawner_few_blue, /*yaw*/ 0, /*pos*/ 2061, -3323, 2246), + MACRO_OBJECT (/*preset*/ macro_fish_spawner_few_cyan, /*yaw*/ 0, /*pos*/ 5661, -2923, -1415), + MACRO_OBJECT (/*preset*/ macro_clam_shell, /*yaw*/ 90, /*pos*/ 1273, -4106, 2320), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 180, /*pos*/ 3086, 110, 6120, /*bhvParam*/ DIALOG_053), + MACRO_OBJECT (/*preset*/ macro_seaweed_bundle, /*yaw*/ 0, /*pos*/ 6420, -4106, -2026), + MACRO_OBJECT (/*preset*/ macro_seaweed_bundle, /*yaw*/ 0, /*pos*/ 6340, -4106, -1413), + MACRO_OBJECT (/*preset*/ macro_clam_shell, /*yaw*/ 135, /*pos*/ 1966, -4106, 3226), + MACRO_OBJECT (/*preset*/ macro_clam_shell, /*yaw*/ 180, /*pos*/ 3886, -4006, 5130), + MACRO_OBJECT (/*preset*/ macro_hidden_breakable_box, /*yaw*/ 0, /*pos*/ 5740, 710, 3900), + MACRO_OBJECT (/*preset*/ macro_hidden_breakable_box, /*yaw*/ 0, /*pos*/ 5740, 510, 4100), + MACRO_OBJECT (/*preset*/ macro_hidden_breakable_box, /*yaw*/ 0, /*pos*/ 5740, 310, 4300), + MACRO_OBJECT (/*preset*/ macro_hidden_breakable_box, /*yaw*/ 0, /*pos*/ 5740, 110, 4500), + MACRO_OBJECT (/*preset*/ macro_seaweed_bundle, /*yaw*/ 0, /*pos*/ 2999, -4092, 4430), + MACRO_OBJECT (/*preset*/ macro_coin_ring_horizontal, /*yaw*/ 0, /*pos*/ 4876, -4087, 4430), + MACRO_OBJECT (/*preset*/ macro_coin_line_vertical_flying, /*yaw*/ 0, /*pos*/ 3892, -4030, -3830), + MACRO_OBJECT (/*preset*/ macro_coin_line_horizontal, /*yaw*/ 90, /*pos*/ 3923, 110, 5953), + MACRO_OBJECT (/*preset*/ macro_fire_spitter, /*yaw*/ 0, /*pos*/ 938, 153, 4107), + MACRO_OBJECT (/*preset*/ macro_hidden_breakable_box, /*yaw*/ 0, /*pos*/ 5940, 110, 4500), + MACRO_OBJECT (/*preset*/ macro_blue_coin_switch, /*yaw*/ 0, /*pos*/ 1614, 928, 922), + MACRO_OBJECT (/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ 1414, 1020, 622), + MACRO_OBJECT (/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ 1814, 1020, 622), + MACRO_OBJECT (/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ 1814, 1020, 1222), + MACRO_OBJECT (/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ 1414, 1020, 1222), + MACRO_OBJECT (/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ 1414, 1020, 922), + MACRO_OBJECT (/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ 1814, 1020, 922), + MACRO_OBJECT (/*preset*/ macro_koopa_shell_underwater, /*yaw*/ 0, /*pos*/ 3886, -4050, 5100), MACRO_OBJECT_END(), }; diff --git a/levels/ddd/leveldata.c b/levels/ddd/leveldata.c index 4b0434c5..582565b7 100644 --- a/levels/ddd/leveldata.c +++ b/levels/ddd/leveldata.c @@ -3,8 +3,8 @@ #include "surface_terrains.h" #include "moving_texture_macros.h" #include "level_misc_macros.h" -#include "macro_preset_names.h" -#include "special_preset_names.h" +#include "macro_presets.h" +#include "special_presets.h" #include "textures.h" #include "dialog_ids.h" diff --git a/levels/ddd/pole/geo.inc.c b/levels/ddd/pole/geo.inc.c index 49a90d0e..fb121655 100644 --- a/levels/ddd/pole/geo.inc.c +++ b/levels/ddd/pole/geo.inc.c @@ -1,11 +1,11 @@ // 0x0E000450 const GeoLayout ddd_geo_000450[] = { - GEO_CULLING_RADIUS(700), - GEO_OPEN_NODE(), - GEO_SHADOW(SHADOW_SQUARE_PERMANENT, 0xB4, 120), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, ddd_seg7_dl_0700D2A0), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(700), + GEO_OPEN_NODE(), + GEO_SHADOW(SHADOW_SQUARE_PERMANENT, 0xB4, 120), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, ddd_seg7_dl_0700D2A0), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/ddd/script.c b/levels/ddd/script.c index 759a2627..a2f81f50 100644 --- a/levels/ddd/script.c +++ b/levels/ddd/script.c @@ -16,64 +16,64 @@ #include "levels/ddd/header.h" static const LevelScript script_func_local_1[] = { - OBJECT(/*model*/ MODEL_SUSHI, /*pos*/ -3071, -270, 0, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvSushiShark), - OBJECT(/*model*/ MODEL_SUSHI, /*pos*/ -3071, -4270, 0, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvSushiShark), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -3071, -130, 0, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvFewBlueFishSpawner), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -3071, -4270, 0, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvManyBlueFishSpawner), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -3071, -2000, 0, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvChirpChirp), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -3071, -3000, 0, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvChirpChirp), - OBJECT(/*model*/ MODEL_DL_WHIRLPOOL, /*pos*/ -3174, -4915, 102, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvWhirlpool), + OBJECT(/*model*/ MODEL_SUSHI, /*pos*/ -3071, -270, 0, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvSushiShark), + OBJECT(/*model*/ MODEL_SUSHI, /*pos*/ -3071, -4270, 0, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvSushiShark), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ -3071, -130, 0, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvFewBlueFishSpawner), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ -3071, -4270, 0, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvManyBlueFishSpawner), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ -3071, -2000, 0, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvChirpChirp), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ -3071, -3000, 0, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvChirpChirp), + OBJECT(/*model*/ MODEL_DL_WHIRLPOOL, /*pos*/ -3174, -4915, 102, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvWhirlpool), RETURN(), }; static const LevelScript script_func_local_2[] = { - OBJECT_WITH_ACTS(/*model*/ MODEL_NONE, /*pos*/ -2400, -4607, 125, /*angle*/ 0, 0, 0, /*behParam*/ 0x01000000, /*beh*/ bhvTreasureChests, /*acts*/ ALL_ACTS), - OBJECT_WITH_ACTS(/*model*/ MODEL_MANTA_RAY, /*pos*/ -4640, -1380, 40, /*angle*/ 0, 0, 0, /*behParam*/ 0x04000000, /*beh*/ bhvMantaRay, /*acts*/ ACT_2 | ACT_3 | ACT_4 | ACT_5 | ACT_6), + OBJECT_WITH_ACTS(/*model*/ MODEL_NONE, /*pos*/ -2400, -4607, 125, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(STAR_INDEX_ACT_2), /*bhv*/ bhvTreasureChestsDDD, /*acts*/ ALL_ACTS), + OBJECT_WITH_ACTS(/*model*/ MODEL_MANTA_RAY, /*pos*/ -4640, -1380, 40, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(STAR_INDEX_ACT_5), /*bhv*/ bhvMantaRay, /*acts*/ ACT_2 | ACT_3 | ACT_4 | ACT_5 | ACT_6), RETURN(), }; static const LevelScript script_func_local_3[] = { - OBJECT(/*model*/ MODEL_DDD_BOWSER_SUB_DOOR, /*pos*/ 0, 0, 0, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvBowserSubDoor), - OBJECT(/*model*/ MODEL_DDD_BOWSER_SUB, /*pos*/ 0, 0, 0, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvBowsersSub), - OBJECT(/*model*/ MODEL_DDD_POLE, /*pos*/ 5120, 1005, 3584, /*angle*/ 0, 180, 0, /*behParam*/ 0x001E0000, /*beh*/ bhvDDDPole), - OBJECT(/*model*/ MODEL_DDD_POLE, /*pos*/ 5605, 1005, 3380, /*angle*/ 0, 270, 0, /*behParam*/ 0x00150000, /*beh*/ bhvDDDPole), - OBJECT(/*model*/ MODEL_DDD_POLE, /*pos*/ 1800, 1005, 1275, /*angle*/ 0, 0, 0, /*behParam*/ 0x000B0000, /*beh*/ bhvDDDPole), - OBJECT(/*model*/ MODEL_DDD_POLE, /*pos*/ 4000, 1005, 1075, /*angle*/ 0, 180, 0, /*behParam*/ 0x000B0000, /*beh*/ bhvDDDPole), - OBJECT(/*model*/ MODEL_DDD_POLE, /*pos*/ 1830, 1005, 520, /*angle*/ 0, 270, 0, /*behParam*/ 0x00140000, /*beh*/ bhvDDDPole), - OBJECT(/*model*/ MODEL_DDD_POLE, /*pos*/ 4000, 1005, 1275, /*angle*/ 0, 0, 0, /*behParam*/ 0x000B0000, /*beh*/ bhvDDDPole), - OBJECT(/*model*/ MODEL_DDD_POLE, /*pos*/ 5760, 1005, 360, /*angle*/ 0, 270, 0, /*behParam*/ 0x00170000, /*beh*/ bhvDDDPole), - OBJECT(/*model*/ MODEL_DDD_POLE, /*pos*/ 3310, 1005, -1945, /*angle*/ 0, 0, 0, /*behParam*/ 0x00170000, /*beh*/ bhvDDDPole), - OBJECT(/*model*/ MODEL_DDD_POLE, /*pos*/ 3550, 1005, -2250, /*angle*/ 0, 0, 0, /*behParam*/ 0x000D0000, /*beh*/ bhvDDDPole), + OBJECT(/*model*/ MODEL_DDD_BOWSER_SUB_DOOR, /*pos*/ 0, 0, 0, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvBowserSubDoor), + OBJECT(/*model*/ MODEL_DDD_BOWSER_SUB, /*pos*/ 0, 0, 0, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvBowsersSub), + OBJECT(/*model*/ MODEL_DDD_POLE, /*pos*/ 5120, 1005, 3584, /*angle*/ 0, 180, 0, /*bhvParam*/ BPARAM2(0x1E), /*bhv*/ bhvDDDPole), + OBJECT(/*model*/ MODEL_DDD_POLE, /*pos*/ 5605, 1005, 3380, /*angle*/ 0, 270, 0, /*bhvParam*/ BPARAM2(0x15), /*bhv*/ bhvDDDPole), + OBJECT(/*model*/ MODEL_DDD_POLE, /*pos*/ 1800, 1005, 1275, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(0x0B), /*bhv*/ bhvDDDPole), + OBJECT(/*model*/ MODEL_DDD_POLE, /*pos*/ 4000, 1005, 1075, /*angle*/ 0, 180, 0, /*bhvParam*/ BPARAM2(0x0B), /*bhv*/ bhvDDDPole), + OBJECT(/*model*/ MODEL_DDD_POLE, /*pos*/ 1830, 1005, 520, /*angle*/ 0, 270, 0, /*bhvParam*/ BPARAM2(0x14), /*bhv*/ bhvDDDPole), + OBJECT(/*model*/ MODEL_DDD_POLE, /*pos*/ 4000, 1005, 1275, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(0x0B), /*bhv*/ bhvDDDPole), + OBJECT(/*model*/ MODEL_DDD_POLE, /*pos*/ 5760, 1005, 360, /*angle*/ 0, 270, 0, /*bhvParam*/ BPARAM2(0x17), /*bhv*/ bhvDDDPole), + OBJECT(/*model*/ MODEL_DDD_POLE, /*pos*/ 3310, 1005, -1945, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(0x17), /*bhv*/ bhvDDDPole), + OBJECT(/*model*/ MODEL_DDD_POLE, /*pos*/ 3550, 1005, -2250, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(0x0D), /*bhv*/ bhvDDDPole), RETURN(), }; static const LevelScript script_func_local_4[] = { - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 3404, -3319, -489, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvJetStream), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 3404, -3319, -489, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvJetStream), RETURN(), }; static const LevelScript script_func_local_5[] = { - OBJECT_WITH_ACTS(/*model*/ MODEL_STAR, /*pos*/ 3900, 850, -600, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvStar, /*acts*/ ALL_ACTS), - OBJECT_WITH_ACTS(/*model*/ MODEL_NONE, /*pos*/ 5513, 1200, 900, /*angle*/ 0, 0, 0, /*behParam*/ 0x02000000, /*beh*/ bhvHiddenRedCoinStar, /*acts*/ ALL_ACTS), - OBJECT_WITH_ACTS(/*model*/ MODEL_NONE, /*pos*/ 3404, -3319, -489, /*angle*/ 0, 0, 0, /*behParam*/ 0x03000000, /*beh*/ bhvJetStreamRingSpawner, /*acts*/ ALL_ACTS), - OBJECT_WITH_ACTS(/*model*/ MODEL_STAR, /*pos*/ 2030, -3700, -2780, /*angle*/ 0, 0, 0, /*behParam*/ 0x05000000, /*beh*/ bhvStar, /*acts*/ ALL_ACTS), + OBJECT_WITH_ACTS(/*model*/ MODEL_STAR, /*pos*/ 3900, 850, -600, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(STAR_INDEX_ACT_1), /*bhv*/ bhvStar, /*acts*/ ALL_ACTS), + OBJECT_WITH_ACTS(/*model*/ MODEL_NONE, /*pos*/ 5513, 1200, 900, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(STAR_INDEX_ACT_3), /*bhv*/ bhvHiddenRedCoinStar, /*acts*/ ALL_ACTS), + OBJECT_WITH_ACTS(/*model*/ MODEL_NONE, /*pos*/ 3404, -3319, -489, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(STAR_INDEX_ACT_4), /*bhv*/ bhvJetStreamRingSpawner, /*acts*/ ALL_ACTS), + OBJECT_WITH_ACTS(/*model*/ MODEL_STAR, /*pos*/ 2030, -3700, -2780, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(STAR_INDEX_ACT_6), /*bhv*/ bhvStar, /*acts*/ ALL_ACTS), RETURN(), }; const LevelScript level_ddd_entry[] = { INIT_LEVEL(), - LOAD_MIO0( /*seg*/ 0x07, _ddd_segment_7SegmentRomStart, _ddd_segment_7SegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x07, _ddd_segment_7SegmentRomStart, _ddd_segment_7SegmentRomEnd), LOAD_MIO0_TEXTURE(/*seg*/ 0x09, _water_mio0SegmentRomStart, _water_mio0SegmentRomEnd), - LOAD_MIO0( /*seg*/ 0x0B, _effect_mio0SegmentRomStart, _effect_mio0SegmentRomEnd), - LOAD_MIO0( /*seg*/ 0x0A, _water_skybox_mio0SegmentRomStart, _water_skybox_mio0SegmentRomEnd), - LOAD_MIO0( /*seg*/ 0x05, _group4_mio0SegmentRomStart, _group4_mio0SegmentRomEnd), - LOAD_RAW( /*seg*/ 0x0C, _group4_geoSegmentRomStart, _group4_geoSegmentRomEnd), - LOAD_MIO0( /*seg*/ 0x06, _group13_mio0SegmentRomStart, _group13_mio0SegmentRomEnd), - LOAD_RAW( /*seg*/ 0x0D, _group13_geoSegmentRomStart, _group13_geoSegmentRomEnd), - LOAD_MIO0( /*seg*/ 0x08, _common0_mio0SegmentRomStart, _common0_mio0SegmentRomEnd), - LOAD_RAW( /*seg*/ 0x0F, _common0_geoSegmentRomStart, _common0_geoSegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x0B, _effect_mio0SegmentRomStart, _effect_mio0SegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x0A, _water_skybox_mio0SegmentRomStart, _water_skybox_mio0SegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x05, _group4_mio0SegmentRomStart, _group4_mio0SegmentRomEnd), + LOAD_RAW (/*seg*/ 0x0C, _group4_geoSegmentRomStart, _group4_geoSegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x06, _group13_mio0SegmentRomStart, _group13_mio0SegmentRomEnd), + LOAD_RAW (/*seg*/ 0x0D, _group13_geoSegmentRomStart, _group13_geoSegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x08, _common0_mio0SegmentRomStart, _common0_mio0SegmentRomEnd), + LOAD_RAW (/*seg*/ 0x0F, _common0_geoSegmentRomStart, _common0_geoSegmentRomEnd), ALLOC_LEVEL_POOL(), - MARIO(/*model*/ MODEL_MARIO, /*behParam*/ 0x00000001, /*beh*/ bhvMario), + MARIO(/*model*/ MODEL_MARIO, /*bhvParam*/ BPARAM4(0x01), /*bhv*/ bhvMario), JUMP_LINK(script_func_global_1), JUMP_LINK(script_func_global_5), JUMP_LINK(script_func_global_14), @@ -82,10 +82,10 @@ const LevelScript level_ddd_entry[] = { LOAD_MODEL_FROM_GEO(MODEL_DDD_POLE, ddd_geo_000450), AREA(/*index*/ 1, ddd_geo_0004C0), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -3071, 3000, 0, /*angle*/ 0, 7, 0, /*behParam*/ 0x000A0000, /*beh*/ bhvSpinAirborneWarp), - WARP_NODE(/*id*/ 0x0A, /*destLevel*/ LEVEL_DDD, /*destArea*/ 0x01, /*destNode*/ 0x0A, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0xF0, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x03, /*destNode*/ 0x35, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0xF1, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x03, /*destNode*/ 0x67, /*flags*/ WARP_NO_CHECKPOINT), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ -3071, 3000, 0, /*angle*/ 0, 7, 0, /*bhvParam*/ BPARAM2(WARP_NODE_0A), /*bhv*/ bhvSpinAirborneWarp), + WARP_NODE(/*id*/ WARP_NODE_0A, /*destLevel*/ LEVEL_DDD, /*destArea*/ 1, /*destNode*/ WARP_NODE_0A, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_SUCCESS, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 3, /*destNode*/ WARP_NODE_35, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_DEATH, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 3, /*destNode*/ WARP_NODE_67, /*flags*/ WARP_NO_CHECKPOINT), WHIRLPOOL(/*unk2*/ 0, /*unk3*/ 0, /*pos*/ -3174, -4915, 102, /*strength*/ 20), JUMP_LINK(script_func_local_1), JUMP_LINK(script_func_local_2), @@ -99,9 +99,9 @@ const LevelScript level_ddd_entry[] = { AREA(/*index*/ 2, ddd_geo_000570), WHIRLPOOL(/*unk2*/ 0, /*unk3*/ 0, /*pos*/ 3355, -3575, -515, /*strength*/ -30), WHIRLPOOL(/*unk2*/ 1, /*unk3*/ 2, /*pos*/ 3917, -2040, -6041, /*strength*/ 50), - WARP_NODE(/*id*/ 0xF0, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x03, /*destNode*/ 0x35, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0xF1, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x03, /*destNode*/ 0x67, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0xF3, /*destLevel*/ LEVEL_CASTLE_GROUNDS, /*destArea*/ 0x01, /*destNode*/ 0x1E, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_SUCCESS, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 3, /*destNode*/ WARP_NODE_35, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_DEATH, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 3, /*destNode*/ WARP_NODE_67, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_WARP_FLOOR, /*destLevel*/ LEVEL_CASTLE_GROUNDS, /*destArea*/ 1, /*destNode*/ WARP_NODE_1E, /*flags*/ WARP_NO_CHECKPOINT), JUMP_LINK(script_func_local_3), JUMP_LINK(script_func_local_4), JUMP_LINK(script_func_local_5), diff --git a/levels/ddd/sub_door/geo.inc.c b/levels/ddd/sub_door/geo.inc.c index 271857fd..dfffe9e2 100644 --- a/levels/ddd/sub_door/geo.inc.c +++ b/levels/ddd/sub_door/geo.inc.c @@ -1,10 +1,10 @@ // 0x0E000478 const GeoLayout ddd_geo_000478[] = { - GEO_CULLING_RADIUS(10000), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, ddd_seg7_dl_07009030), - GEO_DISPLAY_LIST(LAYER_OPAQUE, ddd_seg7_dl_07009120), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, ddd_seg7_dl_07009208), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(10000), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, ddd_seg7_dl_07009030), + GEO_DISPLAY_LIST(LAYER_OPAQUE, ddd_seg7_dl_07009120), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, ddd_seg7_dl_07009208), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/ddd/submarine/geo.inc.c b/levels/ddd/submarine/geo.inc.c index 62d318e3..bad9f9af 100644 --- a/levels/ddd/submarine/geo.inc.c +++ b/levels/ddd/submarine/geo.inc.c @@ -1,9 +1,9 @@ // 0x0E0004A0 const GeoLayout ddd_geo_0004A0[] = { - GEO_CULLING_RADIUS(10000), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, ddd_seg7_dl_0700AF10), - GEO_DISPLAY_LIST(LAYER_ALPHA, ddd_seg7_dl_0700B068), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(10000), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, ddd_seg7_dl_0700AF10), + GEO_DISPLAY_LIST(LAYER_ALPHA, ddd_seg7_dl_0700B068), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/ending/geo.c b/levels/ending/geo.c index 867bebb5..1e973423 100644 --- a/levels/ending/geo.c +++ b/levels/ending/geo.c @@ -15,26 +15,26 @@ // 0x0E000050 const GeoLayout ending_geo_000050[] = { - GEO_NODE_SCREEN_AREA(10, SCREEN_WIDTH/2, SCREEN_HEIGHT/2, SCREEN_WIDTH/2, SCREEN_HEIGHT/2), - GEO_OPEN_NODE(), - GEO_ZBUFFER(0), - GEO_OPEN_NODE(), - GEO_NODE_ORTHO(100), - GEO_OPEN_NODE(), + GEO_NODE_SCREEN_AREA(10, SCREEN_WIDTH/2, SCREEN_HEIGHT/2, SCREEN_WIDTH/2, SCREEN_HEIGHT/2), + GEO_OPEN_NODE(), + GEO_ZBUFFER(0), + GEO_OPEN_NODE(), + GEO_NODE_ORTHO(100), + GEO_OPEN_NODE(), #ifdef VERSION_EU - GEO_BACKGROUND_COLOR(0x0001), + GEO_BACKGROUND_COLOR(0x0001), #endif - GEO_ASM(0, geo_exec_cake_end_screen), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ZBUFFER(1), - GEO_OPEN_NODE(), - GEO_CAMERA_FRUSTUM_WITH_FUNC(45, 100, 12800, geo_camera_fov), - GEO_OPEN_NODE(), - GEO_CAMERA(1, 0, 2000, 6000, 0, 0, 0, geo_camera_main), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_ASM(0, geo_exec_cake_end_screen), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ZBUFFER(1), + GEO_OPEN_NODE(), + GEO_CAMERA_FRUSTUM_WITH_FUNC(45, 100, 12800, geo_camera_fov), + GEO_OPEN_NODE(), + GEO_CAMERA(1, 0, 2000, 6000, 0, 0, 0, geo_camera_main), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/ending/leveldata.c b/levels/ending/leveldata.c index 94b93872..5dcb7ed2 100644 --- a/levels/ending/leveldata.c +++ b/levels/ending/leveldata.c @@ -245,7 +245,11 @@ const Gfx dl_cake_end_screen_eu_070297D8[] = { // VERSION_EU #else +#ifdef VERSION_CN +#include "levels/ending/cake_cn.inc.c" +#else #include "levels/ending/cake.inc.c" +#endif // 0x07025800 - 0x07025840 static const Vtx cake_end_vertex_07025800[] = { diff --git a/levels/hmc/areas/1/geo.inc.c b/levels/hmc/areas/1/geo.inc.c index 5a2baac0..88686626 100644 --- a/levels/hmc/areas/1/geo.inc.c +++ b/levels/hmc/areas/1/geo.inc.c @@ -1,335 +1,335 @@ // 0x0E0005E8 const GeoLayout hmc_geo_0005E8[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_070078B0), - GEO_DISPLAY_LIST(LAYER_ALPHA, hmc_seg7_dl_07007B50), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, hmc_seg7_dl_070080E8), - GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_070093F0), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_070078B0), + GEO_DISPLAY_LIST(LAYER_ALPHA, hmc_seg7_dl_07007B50), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, hmc_seg7_dl_070080E8), + GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_070093F0), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x0E000618 const GeoLayout hmc_geo_000618[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_0700E448), - GEO_DISPLAY_LIST(LAYER_ALPHA, hmc_seg7_dl_0700EF00), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, hmc_seg7_dl_0700F3E8), - GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_0700FA40), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, hmc_seg7_dl_0700FEF0), - GEO_DISPLAY_LIST(LAYER_OPAQUE_DECAL, hmc_seg7_dl_07010070), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_0700E448), + GEO_DISPLAY_LIST(LAYER_ALPHA, hmc_seg7_dl_0700EF00), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, hmc_seg7_dl_0700F3E8), + GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_0700FA40), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, hmc_seg7_dl_0700FEF0), + GEO_DISPLAY_LIST(LAYER_OPAQUE_DECAL, hmc_seg7_dl_07010070), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x0E000658 const GeoLayout hmc_geo_000658[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_07013CA8), - GEO_DISPLAY_LIST(LAYER_ALPHA, hmc_seg7_dl_07013E80), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, hmc_seg7_dl_07014300), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, hmc_seg7_dl_07014B08), - GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_07014C00), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, hmc_seg7_dl_07014E48), - GEO_ASM( 0, geo_movtex_pause_control), - GEO_ASM(0x0702, geo_movtex_draw_water_regions), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_07013CA8), + GEO_DISPLAY_LIST(LAYER_ALPHA, hmc_seg7_dl_07013E80), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, hmc_seg7_dl_07014300), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, hmc_seg7_dl_07014B08), + GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_07014C00), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, hmc_seg7_dl_07014E48), + GEO_ASM( 0, geo_movtex_pause_control), + GEO_ASM(0x0702, geo_movtex_draw_water_regions), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x0E0006A8 const GeoLayout hmc_geo_0006A8[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_070173A8), - GEO_DISPLAY_LIST(LAYER_ALPHA, hmc_seg7_dl_07017C98), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, hmc_seg7_dl_07018200), - GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_07019248), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, hmc_seg7_dl_07019368), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_070173A8), + GEO_DISPLAY_LIST(LAYER_ALPHA, hmc_seg7_dl_07017C98), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, hmc_seg7_dl_07018200), + GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_07019248), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, hmc_seg7_dl_07019368), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x0E0006E0 const GeoLayout hmc_geo_0006E0[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_0701A080), - GEO_DISPLAY_LIST(LAYER_ALPHA, hmc_seg7_dl_0701A400), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_0701A080), + GEO_DISPLAY_LIST(LAYER_ALPHA, hmc_seg7_dl_0701A400), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x0E000700 const GeoLayout hmc_geo_000700[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_0701E820), - GEO_DISPLAY_LIST(LAYER_ALPHA, hmc_seg7_dl_0701F1B0), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, hmc_seg7_dl_0701F690), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, hmc_seg7_dl_0701F818), - GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_0701FD58), - GEO_ASM(0, geo_movtex_pause_control), - GEO_ASM(0x0701, geo_movtex_draw_water_regions), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_0701E820), + GEO_DISPLAY_LIST(LAYER_ALPHA, hmc_seg7_dl_0701F1B0), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, hmc_seg7_dl_0701F690), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, hmc_seg7_dl_0701F818), + GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_0701FD58), + GEO_ASM(0, geo_movtex_pause_control), + GEO_ASM(0x0701, geo_movtex_draw_water_regions), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x0E000748 const GeoLayout hmc_geo_000748[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_07020FD0), - GEO_ASM(0, geo_painting_update), - GEO_ASM(PAINTING_ID(0, 0), geo_painting_draw), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_07020FD0), + GEO_ASM(0, geo_painting_update), + GEO_ASM(PAINTING_ID(0, 0), geo_painting_draw), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x0E000770 const GeoLayout hmc_geo_000770[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_07021760), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, hmc_seg7_dl_07021BA0), - GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_070228A0), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_07021760), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, hmc_seg7_dl_07021BA0), + GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_070228A0), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x0E000798 const GeoLayout hmc_geo_000798[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_070078B0), - GEO_DISPLAY_LIST(LAYER_ALPHA, hmc_seg7_dl_07007B50), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, hmc_seg7_dl_070080E8), - GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_070093F0), - GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_0700E448), - GEO_DISPLAY_LIST(LAYER_ALPHA, hmc_seg7_dl_0700EF00), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, hmc_seg7_dl_0700F3E8), - GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_0700FA40), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, hmc_seg7_dl_0700FEF0), - GEO_DISPLAY_LIST(LAYER_OPAQUE_DECAL, hmc_seg7_dl_07010070), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_070078B0), + GEO_DISPLAY_LIST(LAYER_ALPHA, hmc_seg7_dl_07007B50), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, hmc_seg7_dl_070080E8), + GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_070093F0), + GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_0700E448), + GEO_DISPLAY_LIST(LAYER_ALPHA, hmc_seg7_dl_0700EF00), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, hmc_seg7_dl_0700F3E8), + GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_0700FA40), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, hmc_seg7_dl_0700FEF0), + GEO_DISPLAY_LIST(LAYER_OPAQUE_DECAL, hmc_seg7_dl_07010070), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x0E0007F8 const GeoLayout hmc_geo_0007F8[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_070078B0), - GEO_DISPLAY_LIST(LAYER_ALPHA, hmc_seg7_dl_07007B50), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, hmc_seg7_dl_070080E8), - GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_070093F0), - GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_070173A8), - GEO_DISPLAY_LIST(LAYER_ALPHA, hmc_seg7_dl_07017C98), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, hmc_seg7_dl_07018200), - GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_07019248), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, hmc_seg7_dl_07019368), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_070078B0), + GEO_DISPLAY_LIST(LAYER_ALPHA, hmc_seg7_dl_07007B50), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, hmc_seg7_dl_070080E8), + GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_070093F0), + GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_070173A8), + GEO_DISPLAY_LIST(LAYER_ALPHA, hmc_seg7_dl_07017C98), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, hmc_seg7_dl_07018200), + GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_07019248), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, hmc_seg7_dl_07019368), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x0E000850 const GeoLayout hmc_geo_000850[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_0700E448), - GEO_DISPLAY_LIST(LAYER_ALPHA, hmc_seg7_dl_0700EF00), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, hmc_seg7_dl_0700F3E8), - GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_0700FA40), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, hmc_seg7_dl_0700FEF0), - GEO_DISPLAY_LIST(LAYER_OPAQUE_DECAL, hmc_seg7_dl_07010070), - GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_07013CA8), - GEO_DISPLAY_LIST(LAYER_ALPHA, hmc_seg7_dl_07013E80), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, hmc_seg7_dl_07014300), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, hmc_seg7_dl_07014B08), - GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_07014C00), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, hmc_seg7_dl_07014E48), - GEO_ASM( 0, geo_movtex_pause_control), - GEO_ASM(0x0702, geo_movtex_draw_water_regions), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_0700E448), + GEO_DISPLAY_LIST(LAYER_ALPHA, hmc_seg7_dl_0700EF00), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, hmc_seg7_dl_0700F3E8), + GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_0700FA40), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, hmc_seg7_dl_0700FEF0), + GEO_DISPLAY_LIST(LAYER_OPAQUE_DECAL, hmc_seg7_dl_07010070), + GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_07013CA8), + GEO_DISPLAY_LIST(LAYER_ALPHA, hmc_seg7_dl_07013E80), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, hmc_seg7_dl_07014300), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, hmc_seg7_dl_07014B08), + GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_07014C00), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, hmc_seg7_dl_07014E48), + GEO_ASM( 0, geo_movtex_pause_control), + GEO_ASM(0x0702, geo_movtex_draw_water_regions), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x0E0008D0 const GeoLayout hmc_geo_0008D0[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_0700E448), - GEO_DISPLAY_LIST(LAYER_ALPHA, hmc_seg7_dl_0700EF00), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, hmc_seg7_dl_0700F3E8), - GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_0700FA40), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, hmc_seg7_dl_0700FEF0), - GEO_DISPLAY_LIST(LAYER_OPAQUE_DECAL, hmc_seg7_dl_07010070), - GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_070173A8), - GEO_DISPLAY_LIST(LAYER_ALPHA, hmc_seg7_dl_07017C98), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, hmc_seg7_dl_07018200), - GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_07019248), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, hmc_seg7_dl_07019368), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_0700E448), + GEO_DISPLAY_LIST(LAYER_ALPHA, hmc_seg7_dl_0700EF00), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, hmc_seg7_dl_0700F3E8), + GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_0700FA40), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, hmc_seg7_dl_0700FEF0), + GEO_DISPLAY_LIST(LAYER_OPAQUE_DECAL, hmc_seg7_dl_07010070), + GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_070173A8), + GEO_DISPLAY_LIST(LAYER_ALPHA, hmc_seg7_dl_07017C98), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, hmc_seg7_dl_07018200), + GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_07019248), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, hmc_seg7_dl_07019368), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x0E000938 const GeoLayout hmc_geo_000938[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_07013CA8), - GEO_DISPLAY_LIST(LAYER_ALPHA, hmc_seg7_dl_07013E80), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, hmc_seg7_dl_07014300), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, hmc_seg7_dl_07014B08), - GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_07014C00), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, hmc_seg7_dl_07014E48), - GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_0701A080), - GEO_DISPLAY_LIST(LAYER_ALPHA, hmc_seg7_dl_0701A400), - GEO_ASM( 0, geo_movtex_pause_control), - GEO_ASM(0x0702, geo_movtex_draw_water_regions), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_07013CA8), + GEO_DISPLAY_LIST(LAYER_ALPHA, hmc_seg7_dl_07013E80), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, hmc_seg7_dl_07014300), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, hmc_seg7_dl_07014B08), + GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_07014C00), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, hmc_seg7_dl_07014E48), + GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_0701A080), + GEO_DISPLAY_LIST(LAYER_ALPHA, hmc_seg7_dl_0701A400), + GEO_ASM( 0, geo_movtex_pause_control), + GEO_ASM(0x0702, geo_movtex_draw_water_regions), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x0E000998 const GeoLayout hmc_geo_000998[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_07013CA8), - GEO_DISPLAY_LIST(LAYER_ALPHA, hmc_seg7_dl_07013E80), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, hmc_seg7_dl_07014300), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, hmc_seg7_dl_07014B08), - GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_07014C00), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, hmc_seg7_dl_07014E48), - GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_0701E820), - GEO_DISPLAY_LIST(LAYER_ALPHA, hmc_seg7_dl_0701F1B0), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, hmc_seg7_dl_0701F690), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, hmc_seg7_dl_0701F818), - GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_0701FD58), - GEO_ASM( 0, geo_movtex_pause_control), - GEO_ASM(0x0701, geo_movtex_draw_water_regions), - GEO_ASM(0x0702, geo_movtex_draw_water_regions), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_07013CA8), + GEO_DISPLAY_LIST(LAYER_ALPHA, hmc_seg7_dl_07013E80), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, hmc_seg7_dl_07014300), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, hmc_seg7_dl_07014B08), + GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_07014C00), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, hmc_seg7_dl_07014E48), + GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_0701E820), + GEO_DISPLAY_LIST(LAYER_ALPHA, hmc_seg7_dl_0701F1B0), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, hmc_seg7_dl_0701F690), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, hmc_seg7_dl_0701F818), + GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_0701FD58), + GEO_ASM( 0, geo_movtex_pause_control), + GEO_ASM(0x0701, geo_movtex_draw_water_regions), + GEO_ASM(0x0702, geo_movtex_draw_water_regions), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x0E000A18 const GeoLayout hmc_geo_000A18[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_070173A8), - GEO_DISPLAY_LIST(LAYER_ALPHA, hmc_seg7_dl_07017C98), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, hmc_seg7_dl_07018200), - GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_07019248), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, hmc_seg7_dl_07019368), - GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_0701E820), - GEO_DISPLAY_LIST(LAYER_ALPHA, hmc_seg7_dl_0701F1B0), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, hmc_seg7_dl_0701F690), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, hmc_seg7_dl_0701F818), - GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_0701FD58), - GEO_ASM( 0, geo_movtex_pause_control), - GEO_ASM(0x0701, geo_movtex_draw_water_regions), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_070173A8), + GEO_DISPLAY_LIST(LAYER_ALPHA, hmc_seg7_dl_07017C98), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, hmc_seg7_dl_07018200), + GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_07019248), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, hmc_seg7_dl_07019368), + GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_0701E820), + GEO_DISPLAY_LIST(LAYER_ALPHA, hmc_seg7_dl_0701F1B0), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, hmc_seg7_dl_0701F690), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, hmc_seg7_dl_0701F818), + GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_0701FD58), + GEO_ASM( 0, geo_movtex_pause_control), + GEO_ASM(0x0701, geo_movtex_draw_water_regions), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x0E000A88 const GeoLayout hmc_geo_000A88[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_0701E820), - GEO_DISPLAY_LIST(LAYER_ALPHA, hmc_seg7_dl_0701F1B0), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, hmc_seg7_dl_0701F690), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, hmc_seg7_dl_0701F818), - GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_0701FD58), - GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_07020FD0), - GEO_ASM( 0, geo_painting_update), - GEO_ASM( PAINTING_ID(0, 0), geo_painting_draw), - GEO_ASM( 0, geo_movtex_pause_control), - GEO_ASM(0x0701, geo_movtex_draw_water_regions), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_0701E820), + GEO_DISPLAY_LIST(LAYER_ALPHA, hmc_seg7_dl_0701F1B0), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, hmc_seg7_dl_0701F690), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, hmc_seg7_dl_0701F818), + GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_0701FD58), + GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_07020FD0), + GEO_ASM( 0, geo_painting_update), + GEO_ASM( PAINTING_ID(0, 0), geo_painting_draw), + GEO_ASM( 0, geo_movtex_pause_control), + GEO_ASM(0x0701, geo_movtex_draw_water_regions), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x0E000AE8 const GeoLayout hmc_geo_000AE8[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_0701E820), - GEO_DISPLAY_LIST(LAYER_ALPHA, hmc_seg7_dl_0701F1B0), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, hmc_seg7_dl_0701F690), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, hmc_seg7_dl_0701F818), - GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_0701FD58), - GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_07021760), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, hmc_seg7_dl_07021BA0), - GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_070228A0), - GEO_ASM( 0, geo_movtex_pause_control), - GEO_ASM(0x0701, geo_movtex_draw_water_regions), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_0701E820), + GEO_DISPLAY_LIST(LAYER_ALPHA, hmc_seg7_dl_0701F1B0), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, hmc_seg7_dl_0701F690), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, hmc_seg7_dl_0701F818), + GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_0701FD58), + GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_07021760), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, hmc_seg7_dl_07021BA0), + GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_070228A0), + GEO_ASM( 0, geo_movtex_pause_control), + GEO_ASM(0x0701, geo_movtex_draw_water_regions), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x0E000B48 const GeoLayout hmc_geo_000B48[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_070173A8), - GEO_DISPLAY_LIST(LAYER_ALPHA, hmc_seg7_dl_07017C98), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, hmc_seg7_dl_07018200), - GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_07019248), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, hmc_seg7_dl_07019368), - GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_0701A080), - GEO_DISPLAY_LIST(LAYER_ALPHA, hmc_seg7_dl_0701A400), - GEO_CLOSE_NODE(), - GEO_RETURN(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_070173A8), + GEO_DISPLAY_LIST(LAYER_ALPHA, hmc_seg7_dl_07017C98), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, hmc_seg7_dl_07018200), + GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_07019248), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, hmc_seg7_dl_07019368), + GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_0701A080), + GEO_DISPLAY_LIST(LAYER_ALPHA, hmc_seg7_dl_0701A400), + GEO_CLOSE_NODE(), + GEO_RETURN(), }; // 0x0E000B90 const GeoLayout hmc_geo_000B90[] = { - GEO_NODE_SCREEN_AREA(10, SCREEN_WIDTH/2, SCREEN_HEIGHT/2, SCREEN_WIDTH/2, SCREEN_HEIGHT/2), - GEO_OPEN_NODE(), - GEO_ZBUFFER(0), - GEO_OPEN_NODE(), - GEO_NODE_ORTHO(100), - GEO_OPEN_NODE(), - GEO_BACKGROUND_COLOR(0x0001), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ZBUFFER(1), - GEO_OPEN_NODE(), - GEO_CAMERA_FRUSTUM_WITH_FUNC(45, 100, 12800, geo_camera_fov), - GEO_OPEN_NODE(), - GEO_CAMERA(16, 0, 2000, 6000, 0, 0, 0, geo_camera_main), + GEO_NODE_SCREEN_AREA(10, SCREEN_WIDTH/2, SCREEN_HEIGHT/2, SCREEN_WIDTH/2, SCREEN_HEIGHT/2), + GEO_OPEN_NODE(), + GEO_ZBUFFER(0), + GEO_OPEN_NODE(), + GEO_NODE_ORTHO(100), GEO_OPEN_NODE(), - GEO_SWITCH_CASE(18, geo_switch_area), - GEO_OPEN_NODE(), - GEO_BRANCH(1, hmc_geo_0005E8), // 0x0E0005E8 - GEO_BRANCH(1, hmc_geo_000618), // 0x0E000618 - GEO_BRANCH(1, hmc_geo_000658), // 0x0E000658 - GEO_BRANCH(1, hmc_geo_0006A8), // 0x0E0006A8 - GEO_BRANCH(1, hmc_geo_0006E0), // 0x0E0006E0 - GEO_BRANCH(1, hmc_geo_000700), // 0x0E000700 - GEO_BRANCH(1, hmc_geo_000748), // 0x0E000748 - GEO_BRANCH(1, hmc_geo_000770), // 0x0E000770 - GEO_BRANCH(1, hmc_geo_000798), // 0x0E000798 - GEO_BRANCH(1, hmc_geo_0007F8), // 0x0E0007F8 - GEO_BRANCH(1, hmc_geo_000850), // 0x0E000850 - GEO_BRANCH(1, hmc_geo_0008D0), // 0x0E0008D0 - GEO_BRANCH(1, hmc_geo_000938), // 0x0E000938 - GEO_BRANCH(1, hmc_geo_000998), // 0x0E000998 - GEO_BRANCH(1, hmc_geo_000A18), // 0x0E000A18 - GEO_BRANCH(1, hmc_geo_000A88), // 0x0E000A88 - GEO_BRANCH(1, hmc_geo_000AE8), // 0x0E000AE8 - GEO_BRANCH(1, hmc_geo_000B48), // 0x0E000B48 - GEO_CLOSE_NODE(), - GEO_RENDER_OBJ(), - GEO_ASM(0, geo_envfx_main), + GEO_BACKGROUND_COLOR(0x0001), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CLOSE_NODE(), + GEO_ZBUFFER(1), + GEO_OPEN_NODE(), + GEO_CAMERA_FRUSTUM_WITH_FUNC(45, 100, 12800, geo_camera_fov), + GEO_OPEN_NODE(), + GEO_CAMERA(16, 0, 2000, 6000, 0, 0, 0, geo_camera_main), + GEO_OPEN_NODE(), + GEO_SWITCH_CASE(18, geo_switch_area), + GEO_OPEN_NODE(), + GEO_BRANCH(1, hmc_geo_0005E8), // 0x0E0005E8 + GEO_BRANCH(1, hmc_geo_000618), // 0x0E000618 + GEO_BRANCH(1, hmc_geo_000658), // 0x0E000658 + GEO_BRANCH(1, hmc_geo_0006A8), // 0x0E0006A8 + GEO_BRANCH(1, hmc_geo_0006E0), // 0x0E0006E0 + GEO_BRANCH(1, hmc_geo_000700), // 0x0E000700 + GEO_BRANCH(1, hmc_geo_000748), // 0x0E000748 + GEO_BRANCH(1, hmc_geo_000770), // 0x0E000770 + GEO_BRANCH(1, hmc_geo_000798), // 0x0E000798 + GEO_BRANCH(1, hmc_geo_0007F8), // 0x0E0007F8 + GEO_BRANCH(1, hmc_geo_000850), // 0x0E000850 + GEO_BRANCH(1, hmc_geo_0008D0), // 0x0E0008D0 + GEO_BRANCH(1, hmc_geo_000938), // 0x0E000938 + GEO_BRANCH(1, hmc_geo_000998), // 0x0E000998 + GEO_BRANCH(1, hmc_geo_000A18), // 0x0E000A18 + GEO_BRANCH(1, hmc_geo_000A88), // 0x0E000A88 + GEO_BRANCH(1, hmc_geo_000AE8), // 0x0E000AE8 + GEO_BRANCH(1, hmc_geo_000B48), // 0x0E000B48 + GEO_CLOSE_NODE(), + GEO_RENDER_OBJ(), + GEO_ASM(0, geo_envfx_main), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/hmc/areas/1/grill_door/geo.inc.c b/levels/hmc/areas/1/grill_door/geo.inc.c index e4e123f2..b8fdcf8b 100644 --- a/levels/hmc/areas/1/grill_door/geo.inc.c +++ b/levels/hmc/areas/1/grill_door/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000530 const GeoLayout hmc_geo_000530[] = { - GEO_CULLING_RADIUS(1000), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, hmc_seg7_dl_0701FFF8), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(1000), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, hmc_seg7_dl_0701FFF8), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/hmc/areas/1/macro.inc.c b/levels/hmc/areas/1/macro.inc.c index 96a75fbb..f7582f40 100644 --- a/levels/hmc/areas/1/macro.inc.c +++ b/levels/hmc/areas/1/macro.inc.c @@ -1,88 +1,88 @@ // 0x0702AA78 - 0x0702ADC2 const MacroObject hmc_seg7_macro_objs[] = { - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 315, /*pos*/ -6060, 2048, 5960, /*behParam*/ DIALOG_089), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 0, /*pos*/ -6770, 1845, 4577, /*behParam*/ DIALOG_050), - MACRO_OBJECT(/*preset*/ macro_swoop_2, /*yaw*/ 0, /*pos*/ -439, 220, -2540), - MACRO_OBJECT(/*preset*/ macro_swoop, /*yaw*/ 0, /*pos*/ 80, 140, -4660), - MACRO_OBJECT(/*preset*/ macro_swoop, /*yaw*/ 0, /*pos*/ 800, 60, -7500), - MACRO_OBJECT(/*preset*/ macro_swoop_2, /*yaw*/ 0, /*pos*/ 1880, 100, -7620), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 0, /*pos*/ 2500, 217, 50, /*behParam*/ DIALOG_071), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 0, /*pos*/ 2900, 217, 50, /*behParam*/ DIALOG_062), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 270, /*pos*/ 838, 2052, 3580, /*behParam*/ DIALOG_088), - MACRO_OBJECT(/*preset*/ macro_scuttlebug, /*yaw*/ 0, /*pos*/ -6320, 2048, 6740), - MACRO_OBJECT(/*preset*/ macro_scuttlebug, /*yaw*/ 0, /*pos*/ -5455, 1536, 521), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 2140, 2048, 6540), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 2900, 2048, 6500), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 6400, 2090, 5320), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 6820, 1024, 3300), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 6260, 1124, 4960), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 4080, 1124, 5760), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 4640, 2250, 3980), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 2960, 1124, 5140), - MACRO_OBJECT(/*preset*/ macro_box_metal_cap, /*yaw*/ 45, /*pos*/ -6924, 2440, 7364), - MACRO_OBJECT(/*preset*/ macro_scuttlebug, /*yaw*/ 0, /*pos*/ 4160, 28, 6308), - MACRO_OBJECT(/*preset*/ macro_scuttlebug, /*yaw*/ 0, /*pos*/ 5392, 28, 3587), - MACRO_OBJECT(/*preset*/ macro_snufit, /*yaw*/ 0, /*pos*/ 2260, -627, -1660), - MACRO_OBJECT(/*preset*/ macro_snufit, /*yaw*/ 0, /*pos*/ 5760, -623, -1600), - MACRO_OBJECT(/*preset*/ macro_snufit, /*yaw*/ 0, /*pos*/ 4560, -620, -1499), - MACRO_OBJECT(/*preset*/ macro_box_metal_cap, /*yaw*/ 0, /*pos*/ 5860, -550, -739), - MACRO_OBJECT(/*preset*/ macro_box_metal_cap, /*yaw*/ 0, /*pos*/ 1939, -600, -2920), - MACRO_OBJECT(/*preset*/ macro_box_metal_cap, /*yaw*/ 0, /*pos*/ 5100, -600, -4500), - MACRO_OBJECT(/*preset*/ macro_coin_line_horizontal, /*yaw*/ 0, /*pos*/ -6580, 1680, -5780), - MACRO_OBJECT(/*preset*/ macro_breakable_box_no_coins, /*yaw*/ 0, /*pos*/ 1022, 1848, 5120), - MACRO_OBJECT(/*preset*/ macro_breakable_box_no_coins, /*yaw*/ 0, /*pos*/ 3500, 2150, 3000), - MACRO_OBJECT(/*preset*/ macro_scuttlebug_spawner, /*yaw*/ 270, /*pos*/ 3240, -4720, 2360), - MACRO_OBJECT(/*preset*/ macro_coin_ring_horizontal, /*yaw*/ 0, /*pos*/ -3600, -4240, 3600), - MACRO_OBJECT(/*preset*/ macro_box_metal_cap, /*yaw*/ 0, /*pos*/ -3000, -2250, -6400), - MACRO_OBJECT(/*preset*/ macro_scuttlebug_spawner, /*yaw*/ 270, /*pos*/ -3420, 1800, 5960), - MACRO_OBJECT(/*preset*/ macro_swoop, /*yaw*/ 0, /*pos*/ 6080, 3060, 4660), - MACRO_OBJECT(/*preset*/ macro_swoop, /*yaw*/ 0, /*pos*/ 5480, 3000, 7120), - MACRO_OBJECT(/*preset*/ macro_coin_ring_horizontal, /*yaw*/ 0, /*pos*/ -2700, 2060, -6400), - MACRO_OBJECT(/*preset*/ macro_swoop_2, /*yaw*/ 0, /*pos*/ -5440, 1720, -320), - MACRO_OBJECT(/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ -2220, 2048, 4440), - MACRO_OBJECT(/*preset*/ macro_recovery_heart, /*yaw*/ 0, /*pos*/ -7511, 1420, -666), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 270, /*pos*/ -3359, 1536, 298, /*behParam*/ DIALOG_122), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 0, /*pos*/ -3092, 2033, -7685, /*behParam*/ DIALOG_138), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 0, /*pos*/ 5439, 0, 2785, /*behParam*/ DIALOG_125), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 0, /*pos*/ -3184, 0, 699, /*behParam*/ DIALOG_126), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 270, /*pos*/ 500, -4300, 3644, /*behParam*/ DIALOG_127), - MACRO_OBJECT(/*preset*/ macro_box_1up, /*yaw*/ 0, /*pos*/ -4960, 2700, 80), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 180, /*pos*/ 2006, 0, 6713, /*behParam*/ DIALOG_124), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 0, /*pos*/ 2510, 0, 2800, /*behParam*/ DIALOG_140), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 90, /*pos*/ 510, 0, 5380, /*behParam*/ DIALOG_139), - MACRO_OBJECT(/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ -2340, 2040, 4560), - MACRO_OBJECT(/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ -2460, 2040, 4660), - MACRO_OBJECT(/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ -2060, 2040, 4380), - MACRO_OBJECT(/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ -1920, 2040, 4320), - MACRO_OBJECT(/*preset*/ macro_blue_coin_switch, /*yaw*/ 0, /*pos*/ 5145, -767, -2954), - MACRO_OBJECT(/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ 3945, -1023, -2918), - MACRO_OBJECT(/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ 3800, -1023, -4009), - MACRO_OBJECT(/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ 3036, -858, -4118), - MACRO_OBJECT(/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ 2018, -921, -4154), - MACRO_OBJECT(/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ 1836, -921, -4700), - MACRO_OBJECT(/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ 1836, -721, -4700), - MACRO_OBJECT(/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ 1836, -521, -4700), - MACRO_OBJECT(/*preset*/ macro_coin_line_horizontal, /*yaw*/ 90, /*pos*/ 2800, 205, 463), - MACRO_OBJECT(/*preset*/ macro_coin_line_horizontal, /*yaw*/ 90, /*pos*/ 1800, -409, -7390), - MACRO_OBJECT(/*preset*/ macro_coin_line_horizontal_flying, /*yaw*/ 144, /*pos*/ -5342, 2809, -1790), - MACRO_OBJECT(/*preset*/ macro_swoop_2, /*yaw*/ 0, /*pos*/ 5632, -563, -4454), - MACRO_OBJECT(/*preset*/ macro_swoop_2, /*yaw*/ 0, /*pos*/ 4915, -665, -5274), - MACRO_OBJECT(/*preset*/ macro_swoop, /*yaw*/ 0, /*pos*/ 5120, -665, -4660), - MACRO_OBJECT(/*preset*/ macro_swoop, /*yaw*/ 0, /*pos*/ 5427, -665, -5070), - MACRO_OBJECT(/*preset*/ macro_snufit, /*yaw*/ 0, /*pos*/ 2439, -722, -5499), - MACRO_OBJECT(/*preset*/ macro_monty_mole_hole, /*yaw*/ 0, /*pos*/ 2714, -768, -4096), - MACRO_OBJECT(/*preset*/ macro_monty_mole_hole, /*yaw*/ 0, /*pos*/ 3011, -768, -1272), - MACRO_OBJECT(/*preset*/ macro_monty_mole_hole, /*yaw*/ 0, /*pos*/ 3324, -768, -1475), - MACRO_OBJECT(/*preset*/ macro_monty_mole, /*yaw*/ 0, /*pos*/ 3940, -768, -2880), - MACRO_OBJECT(/*preset*/ macro_mr_i, /*yaw*/ 0, /*pos*/ 4740, 1060, 4680), - MACRO_OBJECT(/*preset*/ macro_mr_i, /*yaw*/ 0, /*pos*/ 6700, 1020, 6820), - MACRO_OBJECT(/*preset*/ macro_breakable_box_no_coins, /*yaw*/ 0, /*pos*/ 2960, 1024, 5140), - MACRO_OBJECT(/*preset*/ macro_breakable_box_no_coins, /*yaw*/ 0, /*pos*/ 4080, 1024, 5760), - MACRO_OBJECT(/*preset*/ macro_breakable_box_no_coins, /*yaw*/ 0, /*pos*/ 6260, 1024, 4960), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 135, /*pos*/ -4370, 2860, -2243, /*behParam*/ DIALOG_043), - MACRO_OBJECT(/*preset*/ macro_flamethrower, /*yaw*/ 0, /*pos*/ -2900, 1620, 4640), - MACRO_OBJECT(/*preset*/ macro_fire_spitter, /*yaw*/ 0, /*pos*/ 1420, -380, -7040), - MACRO_OBJECT(/*preset*/ macro_fire_spitter, /*yaw*/ 0, /*pos*/ 2500, -380, -7740), - MACRO_OBJECT(/*preset*/ macro_box_1up_running_away, /*yaw*/ 0, /*pos*/ -2700, 2100, -6400), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 315, /*pos*/ -6060, 2048, 5960, /*bhvParam*/ DIALOG_089), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 0, /*pos*/ -6770, 1845, 4577, /*bhvParam*/ DIALOG_050), + MACRO_OBJECT (/*preset*/ macro_swoop_2, /*yaw*/ 0, /*pos*/ -439, 220, -2540), + MACRO_OBJECT (/*preset*/ macro_swoop_1, /*yaw*/ 0, /*pos*/ 80, 140, -4660), + MACRO_OBJECT (/*preset*/ macro_swoop_1, /*yaw*/ 0, /*pos*/ 800, 60, -7500), + MACRO_OBJECT (/*preset*/ macro_swoop_2, /*yaw*/ 0, /*pos*/ 1880, 100, -7620), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 0, /*pos*/ 2500, 217, 50, /*bhvParam*/ DIALOG_071), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 0, /*pos*/ 2900, 217, 50, /*bhvParam*/ DIALOG_062), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 270, /*pos*/ 838, 2052, 3580, /*bhvParam*/ DIALOG_088), + MACRO_OBJECT (/*preset*/ macro_scuttlebug, /*yaw*/ 0, /*pos*/ -6320, 2048, 6740), + MACRO_OBJECT (/*preset*/ macro_scuttlebug, /*yaw*/ 0, /*pos*/ -5455, 1536, 521), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 2140, 2048, 6540), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 2900, 2048, 6500), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 6400, 2090, 5320), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 6820, 1024, 3300), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 6260, 1124, 4960), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 4080, 1124, 5760), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 4640, 2250, 3980), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 2960, 1124, 5140), + MACRO_OBJECT (/*preset*/ macro_box_metal_cap, /*yaw*/ 45, /*pos*/ -6924, 2440, 7364), + MACRO_OBJECT (/*preset*/ macro_scuttlebug, /*yaw*/ 0, /*pos*/ 4160, 28, 6308), + MACRO_OBJECT (/*preset*/ macro_scuttlebug, /*yaw*/ 0, /*pos*/ 5392, 28, 3587), + MACRO_OBJECT (/*preset*/ macro_snufit, /*yaw*/ 0, /*pos*/ 2260, -627, -1660), + MACRO_OBJECT (/*preset*/ macro_snufit, /*yaw*/ 0, /*pos*/ 5760, -623, -1600), + MACRO_OBJECT (/*preset*/ macro_snufit, /*yaw*/ 0, /*pos*/ 4560, -620, -1499), + MACRO_OBJECT (/*preset*/ macro_box_metal_cap, /*yaw*/ 0, /*pos*/ 5860, -550, -739), + MACRO_OBJECT (/*preset*/ macro_box_metal_cap, /*yaw*/ 0, /*pos*/ 1939, -600, -2920), + MACRO_OBJECT (/*preset*/ macro_box_metal_cap, /*yaw*/ 0, /*pos*/ 5100, -600, -4500), + MACRO_OBJECT (/*preset*/ macro_coin_line_horizontal, /*yaw*/ 0, /*pos*/ -6580, 1680, -5780), + MACRO_OBJECT (/*preset*/ macro_breakable_box_no_coins, /*yaw*/ 0, /*pos*/ 1022, 1848, 5120), + MACRO_OBJECT (/*preset*/ macro_breakable_box_no_coins, /*yaw*/ 0, /*pos*/ 3500, 2150, 3000), + MACRO_OBJECT (/*preset*/ macro_scuttlebug_spawner, /*yaw*/ 270, /*pos*/ 3240, -4720, 2360), + MACRO_OBJECT (/*preset*/ macro_coin_ring_horizontal, /*yaw*/ 0, /*pos*/ -3600, -4240, 3600), + MACRO_OBJECT (/*preset*/ macro_box_metal_cap, /*yaw*/ 0, /*pos*/ -3000, -2250, -6400), + MACRO_OBJECT (/*preset*/ macro_scuttlebug_spawner, /*yaw*/ 270, /*pos*/ -3420, 1800, 5960), + MACRO_OBJECT (/*preset*/ macro_swoop_1, /*yaw*/ 0, /*pos*/ 6080, 3060, 4660), + MACRO_OBJECT (/*preset*/ macro_swoop_1, /*yaw*/ 0, /*pos*/ 5480, 3000, 7120), + MACRO_OBJECT (/*preset*/ macro_coin_ring_horizontal, /*yaw*/ 0, /*pos*/ -2700, 2060, -6400), + MACRO_OBJECT (/*preset*/ macro_swoop_2, /*yaw*/ 0, /*pos*/ -5440, 1720, -320), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ -2220, 2048, 4440), + MACRO_OBJECT (/*preset*/ macro_recovery_heart, /*yaw*/ 0, /*pos*/ -7511, 1420, -666), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 270, /*pos*/ -3359, 1536, 298, /*bhvParam*/ DIALOG_122), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 0, /*pos*/ -3092, 2033, -7685, /*bhvParam*/ DIALOG_138), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 0, /*pos*/ 5439, 0, 2785, /*bhvParam*/ DIALOG_125), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 0, /*pos*/ -3184, 0, 699, /*bhvParam*/ DIALOG_126), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 270, /*pos*/ 500, -4300, 3644, /*bhvParam*/ DIALOG_127), + MACRO_OBJECT (/*preset*/ macro_box_1up, /*yaw*/ 0, /*pos*/ -4960, 2700, 80), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 180, /*pos*/ 2006, 0, 6713, /*bhvParam*/ DIALOG_124), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 0, /*pos*/ 2510, 0, 2800, /*bhvParam*/ DIALOG_140), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 90, /*pos*/ 510, 0, 5380, /*bhvParam*/ DIALOG_139), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ -2340, 2040, 4560), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ -2460, 2040, 4660), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ -2060, 2040, 4380), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ -1920, 2040, 4320), + MACRO_OBJECT (/*preset*/ macro_blue_coin_switch, /*yaw*/ 0, /*pos*/ 5145, -767, -2954), + MACRO_OBJECT (/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ 3945, -1023, -2918), + MACRO_OBJECT (/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ 3800, -1023, -4009), + MACRO_OBJECT (/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ 3036, -858, -4118), + MACRO_OBJECT (/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ 2018, -921, -4154), + MACRO_OBJECT (/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ 1836, -921, -4700), + MACRO_OBJECT (/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ 1836, -721, -4700), + MACRO_OBJECT (/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ 1836, -521, -4700), + MACRO_OBJECT (/*preset*/ macro_coin_line_horizontal, /*yaw*/ 90, /*pos*/ 2800, 205, 463), + MACRO_OBJECT (/*preset*/ macro_coin_line_horizontal, /*yaw*/ 90, /*pos*/ 1800, -409, -7390), + MACRO_OBJECT (/*preset*/ macro_coin_line_horizontal_flying, /*yaw*/ 144, /*pos*/ -5342, 2809, -1790), + MACRO_OBJECT (/*preset*/ macro_swoop_2, /*yaw*/ 0, /*pos*/ 5632, -563, -4454), + MACRO_OBJECT (/*preset*/ macro_swoop_2, /*yaw*/ 0, /*pos*/ 4915, -665, -5274), + MACRO_OBJECT (/*preset*/ macro_swoop_1, /*yaw*/ 0, /*pos*/ 5120, -665, -4660), + MACRO_OBJECT (/*preset*/ macro_swoop_1, /*yaw*/ 0, /*pos*/ 5427, -665, -5070), + MACRO_OBJECT (/*preset*/ macro_snufit, /*yaw*/ 0, /*pos*/ 2439, -722, -5499), + MACRO_OBJECT (/*preset*/ macro_monty_mole_hole, /*yaw*/ 0, /*pos*/ 2714, -768, -4096), + MACRO_OBJECT (/*preset*/ macro_monty_mole_hole, /*yaw*/ 0, /*pos*/ 3011, -768, -1272), + MACRO_OBJECT (/*preset*/ macro_monty_mole_hole, /*yaw*/ 0, /*pos*/ 3324, -768, -1475), + MACRO_OBJECT (/*preset*/ macro_monty_mole, /*yaw*/ 0, /*pos*/ 3940, -768, -2880), + MACRO_OBJECT (/*preset*/ macro_mr_i, /*yaw*/ 0, /*pos*/ 4740, 1060, 4680), + MACRO_OBJECT (/*preset*/ macro_mr_i, /*yaw*/ 0, /*pos*/ 6700, 1020, 6820), + MACRO_OBJECT (/*preset*/ macro_breakable_box_no_coins, /*yaw*/ 0, /*pos*/ 2960, 1024, 5140), + MACRO_OBJECT (/*preset*/ macro_breakable_box_no_coins, /*yaw*/ 0, /*pos*/ 4080, 1024, 5760), + MACRO_OBJECT (/*preset*/ macro_breakable_box_no_coins, /*yaw*/ 0, /*pos*/ 6260, 1024, 4960), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 135, /*pos*/ -4370, 2860, -2243, /*bhvParam*/ DIALOG_043), + MACRO_OBJECT (/*preset*/ macro_flamethrower, /*yaw*/ 0, /*pos*/ -2900, 1620, 4640), + MACRO_OBJECT (/*preset*/ macro_fire_spitter, /*yaw*/ 0, /*pos*/ 1420, -380, -7040), + MACRO_OBJECT (/*preset*/ macro_fire_spitter, /*yaw*/ 0, /*pos*/ 2500, -380, -7740), + MACRO_OBJECT (/*preset*/ macro_box_1up_running_away, /*yaw*/ 0, /*pos*/ -2700, 2100, -6400), MACRO_OBJECT_END(), }; diff --git a/levels/hmc/areas/1/painting.inc.c b/levels/hmc/areas/1/painting.inc.c index 86e688a1..a0c55961 100644 --- a/levels/hmc/areas/1/painting.inc.c +++ b/levels/hmc/areas/1/painting.inc.c @@ -10,7 +10,7 @@ static const Lights1 hmc_seg7_lights_070241B8 = gdSPDefLights1( // No gdSPDefLights1 macro defined because of odd different light value (0xff and 0xfa) static const Lights1 hmc_seg7_lights_070241D0 = { {{ {0x40, 0x40, 0x80}, 0, {0x40, 0x40, 0x80}, 0} }, - {{{ {0x64, 0x64, 0xff}, 0, {0x64, 0x64, 0xfa}, 0, {0x28, 0x28, 0x28},0} }} + {{{ {0x64, 0x64, 0xff}, 0, {0x64, 0x64, 0xfa}, 0, {0x28, 0x28, 0x28},0} }} }; // Appears to lock 4 of the sides when shimmering and in use. Unused. diff --git a/levels/hmc/areas/1/room.inc.c b/levels/hmc/areas/1/room.inc.c index 3342df39..a3f23161 100644 --- a/levels/hmc/areas/1/room.inc.c +++ b/levels/hmc/areas/1/room.inc.c @@ -1,5 +1,5 @@ // 0x0702ADC4 - 0x0702B5E4 -const u8 hmc_seg7_rooms[] = { +const RoomData hmc_seg7_rooms[] = { 17, 8, 8, 8, 8, 8, 8, 17, // 0-7 17, 8, 8, 8, 17, 8, 8, 8, // 8-15 8, 8, 8, 8, 8, 8, 8, 8, // 16-23 diff --git a/levels/hmc/arrow_platform/geo.inc.c b/levels/hmc/arrow_platform/geo.inc.c index 71f0be75..2541ad56 100644 --- a/levels/hmc/arrow_platform/geo.inc.c +++ b/levels/hmc/arrow_platform/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E0005A0 const GeoLayout hmc_geo_0005A0[] = { - GEO_CULLING_RADIUS(550), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_07022DA0), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(550), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_07022DA0), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/hmc/arrow_platform_button/geo.inc.c b/levels/hmc/arrow_platform_button/geo.inc.c index 09af5b26..1cc1d5a9 100644 --- a/levels/hmc/arrow_platform_button/geo.inc.c +++ b/levels/hmc/arrow_platform_button/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E0005B8 const GeoLayout hmc_geo_0005B8[] = { - GEO_CULLING_RADIUS(200), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_07023090), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(200), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_07023090), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/hmc/elevator_platform/geo.inc.c b/levels/hmc/elevator_platform/geo.inc.c index 2265af03..1094904e 100644 --- a/levels/hmc/elevator_platform/geo.inc.c +++ b/levels/hmc/elevator_platform/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E0005D0 const GeoLayout hmc_geo_0005D0[] = { - GEO_CULLING_RADIUS(500), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_07022AA0), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(500), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_07022AA0), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/hmc/header.h b/levels/hmc/header.h index 6cf715a6..6c2cca11 100644 --- a/levels/hmc/header.h +++ b/levels/hmc/header.h @@ -78,7 +78,7 @@ extern const u8 *const hmc_seg7_painting_textures_07025518[]; extern struct Painting cotmc_painting; extern const Collision hmc_seg7_collision_level[]; extern const MacroObject hmc_seg7_macro_objs[]; -extern const u8 hmc_seg7_rooms[]; +extern const RoomData hmc_seg7_rooms[]; extern const Collision hmc_seg7_collision_elevator[]; extern const Collision hmc_seg7_collision_0702B65C[]; extern const Collision hmc_seg7_collision_controllable_platform[]; diff --git a/levels/hmc/leveldata.c b/levels/hmc/leveldata.c index ec169436..50d38854 100644 --- a/levels/hmc/leveldata.c +++ b/levels/hmc/leveldata.c @@ -3,8 +3,8 @@ #include "surface_terrains.h" #include "moving_texture_macros.h" #include "level_misc_macros.h" -#include "macro_preset_names.h" -#include "special_preset_names.h" +#include "macro_presets.h" +#include "special_presets.h" #include "textures.h" #include "dialog_ids.h" diff --git a/levels/hmc/rolling_rock/geo.inc.c b/levels/hmc/rolling_rock/geo.inc.c index 3822ed9b..678021f7 100644 --- a/levels/hmc/rolling_rock/geo.inc.c +++ b/levels/hmc/rolling_rock/geo.inc.c @@ -1,11 +1,11 @@ // 0x0E000548 const GeoLayout hmc_geo_000548[] = { - GEO_CULLING_RADIUS(300), - GEO_OPEN_NODE(), - GEO_SHADOW(SHADOW_CIRCLE_9_VERTS, 0xB4, 400), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_07023BC8), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(300), + GEO_OPEN_NODE(), + GEO_SHADOW(SHADOW_CIRCLE_9_VERTS, 0xB4, 400), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_07023BC8), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/hmc/rolling_rock_fragment_1/geo.inc.c b/levels/hmc/rolling_rock_fragment_1/geo.inc.c index a40bae62..fd854425 100644 --- a/levels/hmc/rolling_rock_fragment_1/geo.inc.c +++ b/levels/hmc/rolling_rock_fragment_1/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000570 const GeoLayout hmc_geo_000570[] = { - GEO_CULLING_RADIUS(150), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_07023E10), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(150), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_07023E10), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/hmc/rolling_rock_fragment_2/geo.inc.c b/levels/hmc/rolling_rock_fragment_2/geo.inc.c index fe5072ce..91c50821 100644 --- a/levels/hmc/rolling_rock_fragment_2/geo.inc.c +++ b/levels/hmc/rolling_rock_fragment_2/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000588 const GeoLayout hmc_geo_000588[] = { - GEO_CULLING_RADIUS(100), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_07024110), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(100), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, hmc_seg7_dl_07024110), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/hmc/script.c b/levels/hmc/script.c index 06198229..f41e3928 100644 --- a/levels/hmc/script.c +++ b/levels/hmc/script.c @@ -16,70 +16,70 @@ #include "levels/hmc/header.h" static const LevelScript script_func_local_1[] = { - OBJECT(/*model*/ MODEL_RED_FLAME, /*pos*/ 4936, -357, -4146, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvFlame), - OBJECT(/*model*/ MODEL_RED_FLAME, /*pos*/ 5018, -460, -5559, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvFlame), - OBJECT(/*model*/ MODEL_RED_FLAME, /*pos*/ 1997, 666, -235, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvFlame), - OBJECT(/*model*/ MODEL_RED_FLAME, /*pos*/ 1762, -460, -2610, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvFlame), - OBJECT(/*model*/ MODEL_RED_FLAME, /*pos*/ 4178, -255, -3737, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvFlame), - OBJECT(/*model*/ MODEL_RED_FLAME, /*pos*/ 2233, -460, 256, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvFlame), - OBJECT(/*model*/ MODEL_RED_FLAME, /*pos*/ 5510, -255, -3429, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvFlame), - OBJECT(/*model*/ MODEL_RED_FLAME, /*pos*/ 4690, -357, -767, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvFlame), - OBJECT(/*model*/ MODEL_RED_FLAME, /*pos*/ 3462, -255, -1125, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvFlame), - OBJECT(/*model*/ MODEL_RED_FLAME, /*pos*/ 1762, 666, 0, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvFlame), - OBJECT(/*model*/ MODEL_RED_FLAME, /*pos*/ 1762, -460, 256, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvFlame), - OBJECT(/*model*/ MODEL_RED_FLAME, /*pos*/ 6482, 461, 3226, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvFlame), - OBJECT(/*model*/ MODEL_RED_FLAME, /*pos*/ 1075, 461, 6543, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvFlame), - OBJECT(/*model*/ MODEL_RED_FLAME, /*pos*/ 6912, 461, 6543, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvFlame), - OBJECT(/*model*/ MODEL_RED_FLAME, /*pos*/ 6912, 461, 3697, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvFlame), - OBJECT(/*model*/ MODEL_RED_FLAME, /*pos*/ 6482, 461, 7014, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvFlame), - OBJECT(/*model*/ MODEL_RED_FLAME, /*pos*/ 3817, 717, 1034, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvFlame), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 799, 1024, 4434, /*angle*/ 0, 0, 0, /*behParam*/ 0x00B80000, /*beh*/ bhvPoleGrabbing), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 889, 1024, 3277, /*angle*/ 0, 0, 0, /*behParam*/ 0x00B80000, /*beh*/ bhvPoleGrabbing), + OBJECT(/*model*/ MODEL_RED_FLAME, /*pos*/ 4936, -357, -4146, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvFlame), + OBJECT(/*model*/ MODEL_RED_FLAME, /*pos*/ 5018, -460, -5559, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvFlame), + OBJECT(/*model*/ MODEL_RED_FLAME, /*pos*/ 1997, 666, -235, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvFlame), + OBJECT(/*model*/ MODEL_RED_FLAME, /*pos*/ 1762, -460, -2610, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvFlame), + OBJECT(/*model*/ MODEL_RED_FLAME, /*pos*/ 4178, -255, -3737, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvFlame), + OBJECT(/*model*/ MODEL_RED_FLAME, /*pos*/ 2233, -460, 256, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvFlame), + OBJECT(/*model*/ MODEL_RED_FLAME, /*pos*/ 5510, -255, -3429, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvFlame), + OBJECT(/*model*/ MODEL_RED_FLAME, /*pos*/ 4690, -357, -767, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvFlame), + OBJECT(/*model*/ MODEL_RED_FLAME, /*pos*/ 3462, -255, -1125, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvFlame), + OBJECT(/*model*/ MODEL_RED_FLAME, /*pos*/ 1762, 666, 0, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvFlame), + OBJECT(/*model*/ MODEL_RED_FLAME, /*pos*/ 1762, -460, 256, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvFlame), + OBJECT(/*model*/ MODEL_RED_FLAME, /*pos*/ 6482, 461, 3226, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvFlame), + OBJECT(/*model*/ MODEL_RED_FLAME, /*pos*/ 1075, 461, 6543, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvFlame), + OBJECT(/*model*/ MODEL_RED_FLAME, /*pos*/ 6912, 461, 6543, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvFlame), + OBJECT(/*model*/ MODEL_RED_FLAME, /*pos*/ 6912, 461, 3697, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvFlame), + OBJECT(/*model*/ MODEL_RED_FLAME, /*pos*/ 6482, 461, 7014, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvFlame), + OBJECT(/*model*/ MODEL_RED_FLAME, /*pos*/ 3817, 717, 1034, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvFlame), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 799, 1024, 4434, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(184), /*bhv*/ bhvPoleGrabbing), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 889, 1024, 3277, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(184), /*bhv*/ bhvPoleGrabbing), RETURN(), }; static const LevelScript script_func_local_2[] = { - OBJECT(/*model*/ MODEL_HMC_METAL_PLATFORM, /*pos*/ 1100, 950, 6350, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvControllablePlatform), - OBJECT(/*model*/ MODEL_HMC_ELEVATOR_PLATFORM, /*pos*/ -3243, 1434, 1392, /*angle*/ 0, 27, 0, /*behParam*/ 0x00000000, /*beh*/ bhvHmcElevatorPlatform), - OBJECT(/*model*/ MODEL_HMC_ELEVATOR_PLATFORM, /*pos*/ -2816, 2253, -2509, /*angle*/ 0, 0, 0, /*behParam*/ 0x00010000, /*beh*/ bhvHmcElevatorPlatform), - OBJECT(/*model*/ MODEL_HMC_ELEVATOR_PLATFORM, /*pos*/ -973, 1741, -7347, /*angle*/ 0, 0, 0, /*behParam*/ 0x00020000, /*beh*/ bhvHmcElevatorPlatform), - OBJECT(/*model*/ MODEL_HMC_ELEVATOR_PLATFORM, /*pos*/ -3533, 1741, -7040, /*angle*/ 0, 0, 0, /*behParam*/ 0x00030000, /*beh*/ bhvHmcElevatorPlatform), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 614, -4690, 2330, /*angle*/ 0, 270, 0, /*behParam*/ 0x00010000, /*beh*/ bhvOpenableGrill), - OBJECT(/*model*/ MODEL_PURPLE_SWITCH, /*pos*/ -307, -4997, 2483, /*angle*/ 0, 270, 0, /*behParam*/ 0x00000000, /*beh*/ bhvFloorSwitchGrills), - OBJECT(/*model*/ MODEL_CHECKERBOARD_PLATFORM, /*pos*/ 1270, 2000, 4000, /*angle*/ 0, 270, 0, /*behParam*/ 0x09A40000, /*beh*/ bhvPlatformOnTrack), + OBJECT(/*model*/ MODEL_HMC_METAL_PLATFORM, /*pos*/ 1100, 950, 6350, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvControllablePlatform), + OBJECT(/*model*/ MODEL_HMC_ELEVATOR_PLATFORM, /*pos*/ -3243, 1434, 1392, /*angle*/ 0, 27, 0, /*bhvParam*/ 0, /*bhv*/ bhvHMCElevatorPlatform), + OBJECT(/*model*/ MODEL_HMC_ELEVATOR_PLATFORM, /*pos*/ -2816, 2253, -2509, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(0x01), /*bhv*/ bhvHMCElevatorPlatform), + OBJECT(/*model*/ MODEL_HMC_ELEVATOR_PLATFORM, /*pos*/ -973, 1741, -7347, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(0x02), /*bhv*/ bhvHMCElevatorPlatform), + OBJECT(/*model*/ MODEL_HMC_ELEVATOR_PLATFORM, /*pos*/ -3533, 1741, -7040, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(0x03), /*bhv*/ bhvHMCElevatorPlatform), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 614, -4690, 2330, /*angle*/ 0, 270, 0, /*bhvParam*/ BPARAM2(OPENABLE_GRILL_BP_HMC), /*bhv*/ bhvOpenableGrill), + OBJECT(/*model*/ MODEL_PURPLE_SWITCH, /*pos*/ -307, -4997, 2483, /*angle*/ 0, 270, 0, /*bhvParam*/ 0, /*bhv*/ bhvFloorSwitchGrills), + OBJECT(/*model*/ MODEL_CHECKERBOARD_PLATFORM, /*pos*/ 1270, 2000, 4000, /*angle*/ 0, 270, 0, /*bhvParam*/ BPARAM1(0x09) | BPARAM2(0xA4), /*bhv*/ bhvPlatformOnTrack), RETURN(), }; static const LevelScript script_func_local_3[] = { - OBJECT(/*model*/ MODEL_DORRIE, /*pos*/ -3533, -4969, 3558, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvDorrie), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -6093, 3075, -7807, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvBigBoulderGenerator), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -500, 1600, 3500, /*angle*/ 0, 0, 0, /*behParam*/ 0x00040000, /*beh*/ bhvFlamethrower), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -500, 1600, 3800, /*angle*/ 0, 0, 0, /*behParam*/ 0x00040000, /*beh*/ bhvFlamethrower), + OBJECT(/*model*/ MODEL_DORRIE, /*pos*/ -3533, -4969, 3558, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvDorrie), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ -6093, 3075, -7807, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvBigBoulderGenerator), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ -500, 1600, 3500, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(0x04), /*bhv*/ bhvFlamethrower), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ -500, 1600, 3800, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(0x04), /*bhv*/ bhvFlamethrower), RETURN(), }; static const LevelScript script_func_local_4[] = { - OBJECT_WITH_ACTS(/*model*/ MODEL_STAR, /*pos*/ -3600, -4000, 3600, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvStar, /*acts*/ ALL_ACTS), - OBJECT_WITH_ACTS(/*model*/ MODEL_NONE, /*pos*/ 4000, 300, 5000, /*angle*/ 0, 0, 0, /*behParam*/ 0x01000000, /*beh*/ bhvHiddenRedCoinStar, /*acts*/ ALL_ACTS), - OBJECT_WITH_ACTS(/*model*/ MODEL_STAR, /*pos*/ 6200, -4400, 2300, /*angle*/ 0, 0, 0, /*behParam*/ 0x02000000, /*beh*/ bhvStar, /*acts*/ ALL_ACTS), - OBJECT_WITH_ACTS(/*model*/ MODEL_STAR, /*pos*/ -2100, 2100, -7550, /*angle*/ 0, 0, 0, /*behParam*/ 0x03000000, /*beh*/ bhvStar, /*acts*/ ALL_ACTS), - OBJECT_WITH_ACTS(/*model*/ MODEL_STAR, /*pos*/ -6500, 2700, -1600, /*angle*/ 0, 0, 0, /*behParam*/ 0x04000000, /*beh*/ bhvStar, /*acts*/ ALL_ACTS), - OBJECT_WITH_ACTS(/*model*/ MODEL_STAR, /*pos*/ -5000, 3050, -6700, /*angle*/ 0, 0, 0, /*behParam*/ 0x05000000, /*beh*/ bhvStar, /*acts*/ ALL_ACTS), + OBJECT_WITH_ACTS(/*model*/ MODEL_STAR, /*pos*/ -3600, -4000, 3600, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(STAR_INDEX_ACT_1), /*bhv*/ bhvStar, /*acts*/ ALL_ACTS), + OBJECT_WITH_ACTS(/*model*/ MODEL_NONE, /*pos*/ 4000, 300, 5000, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(STAR_INDEX_ACT_2), /*bhv*/ bhvHiddenRedCoinStar, /*acts*/ ALL_ACTS), + OBJECT_WITH_ACTS(/*model*/ MODEL_STAR, /*pos*/ 6200, -4400, 2300, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(STAR_INDEX_ACT_3), /*bhv*/ bhvStar, /*acts*/ ALL_ACTS), + OBJECT_WITH_ACTS(/*model*/ MODEL_STAR, /*pos*/ -2100, 2100, -7550, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(STAR_INDEX_ACT_4), /*bhv*/ bhvStar, /*acts*/ ALL_ACTS), + OBJECT_WITH_ACTS(/*model*/ MODEL_STAR, /*pos*/ -6500, 2700, -1600, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(STAR_INDEX_ACT_5), /*bhv*/ bhvStar, /*acts*/ ALL_ACTS), + OBJECT_WITH_ACTS(/*model*/ MODEL_STAR, /*pos*/ -5000, 3050, -6700, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(STAR_INDEX_ACT_6), /*bhv*/ bhvStar, /*acts*/ ALL_ACTS), RETURN(), }; const LevelScript level_hmc_entry[] = { INIT_LEVEL(), - LOAD_MIO0( /*seg*/ 0x07, _hmc_segment_7SegmentRomStart, _hmc_segment_7SegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x07, _hmc_segment_7SegmentRomStart, _hmc_segment_7SegmentRomEnd), LOAD_MIO0_TEXTURE(/*seg*/ 0x09, _cave_mio0SegmentRomStart, _cave_mio0SegmentRomEnd), - LOAD_MIO0( /*seg*/ 0x05, _group6_mio0SegmentRomStart, _group6_mio0SegmentRomEnd), - LOAD_RAW( /*seg*/ 0x0C, _group6_geoSegmentRomStart, _group6_geoSegmentRomEnd), - LOAD_MIO0( /*seg*/ 0x06, _group17_mio0SegmentRomStart, _group17_mio0SegmentRomEnd), - LOAD_RAW( /*seg*/ 0x0D, _group17_geoSegmentRomStart, _group17_geoSegmentRomEnd), - LOAD_MIO0( /*seg*/ 0x08, _common0_mio0SegmentRomStart, _common0_mio0SegmentRomEnd), - LOAD_RAW( /*seg*/ 0x0F, _common0_geoSegmentRomStart, _common0_geoSegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x05, _group6_mio0SegmentRomStart, _group6_mio0SegmentRomEnd), + LOAD_RAW (/*seg*/ 0x0C, _group6_geoSegmentRomStart, _group6_geoSegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x06, _group17_mio0SegmentRomStart, _group17_mio0SegmentRomEnd), + LOAD_RAW (/*seg*/ 0x0D, _group17_geoSegmentRomStart, _group17_geoSegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x08, _common0_mio0SegmentRomStart, _common0_mio0SegmentRomEnd), + LOAD_RAW (/*seg*/ 0x0F, _common0_geoSegmentRomStart, _common0_geoSegmentRomEnd), ALLOC_LEVEL_POOL(), - MARIO(/*model*/ MODEL_MARIO, /*behParam*/ 0x00000001, /*beh*/ bhvMario), + MARIO(/*model*/ MODEL_MARIO, /*bhvParam*/ BPARAM4(0x01), /*bhv*/ bhvMario), JUMP_LINK(script_func_global_1), JUMP_LINK(script_func_global_7), JUMP_LINK(script_func_global_18), @@ -95,12 +95,12 @@ const LevelScript level_hmc_entry[] = { LOAD_MODEL_FROM_GEO(MODEL_HMC_RED_GRILLS, hmc_geo_000530), AREA(/*index*/ 1, hmc_geo_000B90), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -7152, 3161, 7181, /*angle*/ 0, 135, 0, /*behParam*/ 0x000A0000, /*beh*/ bhvSpinAirborneWarp), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 3351, -4690, 4773, /*angle*/ 0, 0, 0, /*behParam*/ 0x340B0000, /*beh*/ bhvWarp), - WARP_NODE(/*id*/ 0x0A, /*destLevel*/ LEVEL_HMC, /*destArea*/ 0x01, /*destNode*/ 0x0A, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0x0B, /*destLevel*/ LEVEL_COTMC, /*destArea*/ 0x01, /*destNode*/ 0x0A, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0xF0, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x03, /*destNode*/ 0x34, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0xF1, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x03, /*destNode*/ 0x66, /*flags*/ WARP_NO_CHECKPOINT), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ -7152, 3161, 7181, /*angle*/ 0, 135, 0, /*bhvParam*/ BPARAM2(WARP_NODE_0A), /*bhv*/ bhvSpinAirborneWarp), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 3351, -4690, 4773, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(52) | BPARAM2(WARP_NODE_0B), /*bhv*/ bhvWarp), + WARP_NODE(/*id*/ WARP_NODE_0A, /*destLevel*/ LEVEL_HMC, /*destArea*/ 1, /*destNode*/ WARP_NODE_0A, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_0B, /*destLevel*/ LEVEL_COTMC, /*destArea*/ 1, /*destNode*/ WARP_NODE_0A, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_SUCCESS, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 3, /*destNode*/ WARP_NODE_34, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_DEATH, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 3, /*destNode*/ WARP_NODE_66, /*flags*/ WARP_NO_CHECKPOINT), JUMP_LINK(script_func_local_1), JUMP_LINK(script_func_local_2), JUMP_LINK(script_func_local_3), diff --git a/levels/intro/geo.c b/levels/intro/geo.c index 30a87806..3048638b 100644 --- a/levels/intro/geo.c +++ b/levels/intro/geo.c @@ -17,126 +17,126 @@ // 0x0E0002D0 const GeoLayout intro_geo_0002D0[] = { - GEO_NODE_SCREEN_AREA(0, SCREEN_WIDTH/2, SCREEN_HEIGHT/2, SCREEN_WIDTH/2, SCREEN_HEIGHT/2), - GEO_OPEN_NODE(), - GEO_ZBUFFER(0), - GEO_OPEN_NODE(), - GEO_NODE_ORTHO(100), - GEO_OPEN_NODE(), - GEO_BACKGROUND_COLOR(0x0001), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ZBUFFER(1), - GEO_OPEN_NODE(), - GEO_CAMERA_FRUSTUM(45, 128, 16384), - GEO_OPEN_NODE(), - GEO_CAMERA(0, 0, 0, 3200, 0, 0, 0, 0x00000000), + GEO_NODE_SCREEN_AREA(0, SCREEN_WIDTH/2, SCREEN_HEIGHT/2, SCREEN_WIDTH/2, SCREEN_HEIGHT/2), + GEO_OPEN_NODE(), + GEO_ZBUFFER(0), + GEO_OPEN_NODE(), + GEO_NODE_ORTHO(100), GEO_OPEN_NODE(), - GEO_ASM(0, geo_intro_super_mario_64_logo), + GEO_BACKGROUND_COLOR(0x0001), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ZBUFFER(0), - GEO_OPEN_NODE(), - GEO_ASM(0, geo_intro_tm_copyright), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CLOSE_NODE(), + GEO_ZBUFFER(1), + GEO_OPEN_NODE(), + GEO_CAMERA_FRUSTUM(45, 128, 16384), + GEO_OPEN_NODE(), + GEO_CAMERA(0, 0, 0, 3200, 0, 0, 0, 0x00000000), + GEO_OPEN_NODE(), + GEO_ASM(0, geo_intro_super_mario_64_logo), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ZBUFFER(0), + GEO_OPEN_NODE(), + GEO_ASM(0, geo_intro_tm_copyright), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; // 0x0E00035C const GeoLayout intro_geo_mario_head_regular[] = { - GEO_NODE_SCREEN_AREA(0, SCREEN_WIDTH/2, SCREEN_HEIGHT/2, SCREEN_WIDTH/2, SCREEN_HEIGHT/2), - GEO_OPEN_NODE(), - GEO_ZBUFFER(0), - GEO_OPEN_NODE(), - GEO_NODE_ORTHO(100), - GEO_OPEN_NODE(), - GEO_ASM(0, geo_intro_regular_backdrop), -#ifdef VERSION_SH - GEO_ASM(0, geo_intro_face_easter_egg), + GEO_NODE_SCREEN_AREA(0, SCREEN_WIDTH/2, SCREEN_HEIGHT/2, SCREEN_WIDTH/2, SCREEN_HEIGHT/2), + GEO_OPEN_NODE(), + GEO_ZBUFFER(0), + GEO_OPEN_NODE(), + GEO_NODE_ORTHO(100), + GEO_OPEN_NODE(), + GEO_ASM(0, geo_intro_regular_backdrop), +#if defined(VERSION_SH) || defined(VERSION_CN) + GEO_ASM(0, geo_intro_face_easter_egg), #endif - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ZBUFFER(1), - GEO_OPEN_NODE(), - GEO_CAMERA_FRUSTUM(45, 128, 16384), - GEO_OPEN_NODE(), - GEO_ASM(2, geo_draw_mario_head_goddard), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ZBUFFER(1), + GEO_OPEN_NODE(), + GEO_CAMERA_FRUSTUM(45, 128, 16384), + GEO_OPEN_NODE(), + GEO_ASM(2, geo_draw_mario_head_goddard), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), #ifdef VERSION_SH - GEO_ZBUFFER(0), - GEO_OPEN_NODE(), - GEO_ASM(0, geo_intro_rumble_pak_graphic), - GEO_CLOSE_NODE(), + GEO_ZBUFFER(0), + GEO_OPEN_NODE(), + GEO_ASM(0, geo_intro_rumble_pak_graphic), + GEO_CLOSE_NODE(), #endif - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CLOSE_NODE(), + GEO_END(), }; // 0x0E0003B8 const GeoLayout intro_geo_mario_head_dizzy[] = { - GEO_NODE_SCREEN_AREA(0, SCREEN_WIDTH/2, SCREEN_HEIGHT/2, SCREEN_WIDTH/2, SCREEN_HEIGHT/2), - GEO_OPEN_NODE(), - GEO_ZBUFFER(0), - GEO_OPEN_NODE(), - GEO_NODE_ORTHO(100), - GEO_OPEN_NODE(), - GEO_ASM(0, geo_intro_gameover_backdrop), -#ifdef VERSION_SH - GEO_ASM(0, geo_intro_face_easter_egg), + GEO_NODE_SCREEN_AREA(0, SCREEN_WIDTH/2, SCREEN_HEIGHT/2, SCREEN_WIDTH/2, SCREEN_HEIGHT/2), + GEO_OPEN_NODE(), + GEO_ZBUFFER(0), + GEO_OPEN_NODE(), + GEO_NODE_ORTHO(100), + GEO_OPEN_NODE(), + GEO_ASM(0, geo_intro_gameover_backdrop), +#if defined(VERSION_SH) || defined(VERSION_CN) + GEO_ASM(0, geo_intro_face_easter_egg), #endif - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ZBUFFER(1), - GEO_OPEN_NODE(), - GEO_CAMERA_FRUSTUM(45, 128, 16384), - GEO_OPEN_NODE(), - GEO_ASM(3, geo_draw_mario_head_goddard), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ZBUFFER(1), + GEO_OPEN_NODE(), + GEO_CAMERA_FRUSTUM(45, 128, 16384), + GEO_OPEN_NODE(), + GEO_ASM(3, geo_draw_mario_head_goddard), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), #ifdef VERSION_SH - GEO_ZBUFFER(0), - GEO_OPEN_NODE(), - GEO_ASM(1, geo_intro_rumble_pak_graphic), - GEO_CLOSE_NODE(), + GEO_ZBUFFER(0), + GEO_OPEN_NODE(), + GEO_ASM(1, geo_intro_rumble_pak_graphic), + GEO_CLOSE_NODE(), #endif - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CLOSE_NODE(), + GEO_END(), }; // 0x0E000414 const GeoLayout intro_geo_000414[] = { - GEO_NODE_SCREEN_AREA(0, SCREEN_WIDTH/2, SCREEN_HEIGHT/2, SCREEN_WIDTH/2, SCREEN_HEIGHT/2), - GEO_OPEN_NODE(), - GEO_ZBUFFER(0), - GEO_OPEN_NODE(), - GEO_NODE_ORTHO(100), - GEO_OPEN_NODE(), - GEO_ASM(0, geo_intro_regular_backdrop), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ZBUFFER(1), - GEO_OPEN_NODE(), - GEO_CAMERA_FRUSTUM(45, 128, 16384), - GEO_OPEN_NODE(), - GEO_CAMERA(0, 0, 0, 1200, 0, 0, 0, 0x00000000), + GEO_NODE_SCREEN_AREA(0, SCREEN_WIDTH/2, SCREEN_HEIGHT/2, SCREEN_WIDTH/2, SCREEN_HEIGHT/2), + GEO_OPEN_NODE(), + GEO_ZBUFFER(0), + GEO_OPEN_NODE(), + GEO_NODE_ORTHO(100), GEO_OPEN_NODE(), - GEO_TRANSLATE_NODE_WITH_DL(LAYER_OPAQUE, -230, 300, 0, debug_level_select_dl_07000858), - GEO_TRANSLATE_NODE_WITH_DL(LAYER_OPAQUE, -120, 300, 0, debug_level_select_dl_07001100), - GEO_TRANSLATE_NODE_WITH_DL(LAYER_OPAQUE, -20, 300, 0, debug_level_select_dl_07001BA0), - GEO_TRANSLATE_NODE_WITH_DL(LAYER_OPAQUE, 100, 300, 0, debug_level_select_dl_070025F0), - GEO_TRANSLATE_NODE_WITH_DL(LAYER_OPAQUE, 250, 300, 0, debug_level_select_dl_07003258), - GEO_TRANSLATE_NODE_WITH_DL(LAYER_OPAQUE, -310, 100, 0, debug_level_select_dl_07003DB8), - GEO_TRANSLATE_NODE_WITH_DL(LAYER_OPAQUE, -90, 100, 0, debug_level_select_dl_070048C8), - GEO_TRANSLATE_NODE_WITH_DL(LAYER_OPAQUE, 60, 100, 0, debug_level_select_dl_07005558), - GEO_TRANSLATE_NODE_WITH_DL(LAYER_OPAQUE, 180, 100, 0, debug_level_select_dl_070059F8), - GEO_TRANSLATE_NODE_WITH_DL(LAYER_OPAQUE, 300, 100, 0, debug_level_select_dl_070063B0), + GEO_ASM(0, geo_intro_regular_backdrop), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CLOSE_NODE(), + GEO_ZBUFFER(1), + GEO_OPEN_NODE(), + GEO_CAMERA_FRUSTUM(45, 128, 16384), + GEO_OPEN_NODE(), + GEO_CAMERA(0, 0, 0, 1200, 0, 0, 0, 0x00000000), + GEO_OPEN_NODE(), + GEO_TRANSLATE_NODE_WITH_DL(LAYER_OPAQUE, -230, 300, 0, debug_level_select_dl_07000858), + GEO_TRANSLATE_NODE_WITH_DL(LAYER_OPAQUE, -120, 300, 0, debug_level_select_dl_07001100), + GEO_TRANSLATE_NODE_WITH_DL(LAYER_OPAQUE, -20, 300, 0, debug_level_select_dl_07001BA0), + GEO_TRANSLATE_NODE_WITH_DL(LAYER_OPAQUE, 100, 300, 0, debug_level_select_dl_070025F0), + GEO_TRANSLATE_NODE_WITH_DL(LAYER_OPAQUE, 250, 300, 0, debug_level_select_dl_07003258), + GEO_TRANSLATE_NODE_WITH_DL(LAYER_OPAQUE, -310, 100, 0, debug_level_select_dl_07003DB8), + GEO_TRANSLATE_NODE_WITH_DL(LAYER_OPAQUE, -90, 100, 0, debug_level_select_dl_070048C8), + GEO_TRANSLATE_NODE_WITH_DL(LAYER_OPAQUE, 60, 100, 0, debug_level_select_dl_07005558), + GEO_TRANSLATE_NODE_WITH_DL(LAYER_OPAQUE, 180, 100, 0, debug_level_select_dl_070059F8), + GEO_TRANSLATE_NODE_WITH_DL(LAYER_OPAQUE, 300, 100, 0, debug_level_select_dl_070063B0), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/intro/leveldata.c b/levels/intro/leveldata.c index 7a4474d2..cb683344 100644 --- a/levels/intro/leveldata.c +++ b/levels/intro/leveldata.c @@ -6,6 +6,3835 @@ #include "make_const_nonconst.h" +#if defined(VERSION_CN) +// 0x07000000 - 0x07000030 +static const Vtx intro_seg7_vertex_07000000[] = { + {{{ 416, 749, -312}, 0, { 96, 96}, {0x16, 0x27, 0x9e, 0xff}}}, + {{{ 452, 751, -313}, 0, { 96, 96}, {0x16, 0x27, 0x9e, 0xff}}}, + {{{ 431, 777, -344}, 0, { 96, 96}, {0x16, 0x27, 0x9e, 0xff}}}, +}; + +// 0x07000030 - 0x07000060 +static const Vtx intro_seg7_vertex_07000030[] = { + {{{ 427, 812, -365}, 0, { 64, 96}, {0x12, 0x20, 0x81, 0xff}}}, + {{{ 431, 777, -344}, 0, { 96, 96}, {0x12, 0x20, 0x81, 0xff}}}, + {{{ 451, 805, -346}, 0, { 64, 96}, {0x12, 0x20, 0x81, 0xff}}}, +}; + +// 0x07000060 - 0x07000090 +static const Vtx intro_seg7_vertex_07000060[] = { + {{{ 431, 777, -344}, 0, { 96, 96}, {0x12, 0x20, 0x81, 0xff}}}, + {{{ 452, 751, -313}, 0, { 96, 96}, {0x12, 0x20, 0x81, 0xff}}}, + {{{ 451, 805, -346}, 0, { 64, 96}, {0x12, 0x20, 0x81, 0xff}}}, +}; + +// 0x07000090 - 0x070000C0 +static const Vtx intro_seg7_vertex_07000090[] = { + {{{ 427, 812, -365}, 0, { 64, 96}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ 406, 804, -345}, 0, { 64, 96}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ 431, 777, -344}, 0, { 96, 96}, {0x20, 0x39, 0xe5, 0xff}}}, +}; + +// 0x070000C0 - 0x070000F0 +static const Vtx intro_seg7_vertex_070000C0[] = { + {{{ 431, 777, -344}, 0, { 96, 96}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ 406, 804, -345}, 0, { 64, 96}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ 416, 749, -312}, 0, { 96, 96}, {0x20, 0x39, 0xe5, 0xff}}}, +}; + +// 0x070000F0 - 0x07000140 +static const Vtx intro_seg7_vertex_070000F0[] = { + {{{ 571, 814, -363}, 0, { 64, 64}, {0x16, 0x27, 0x9e, 0xff}}}, + {{{ 427, 812, -365}, 0, { 64, 96}, {0x16, 0x27, 0x9e, 0xff}}}, + {{{ 553, 804, -345}, 0, { 96, 64}, {0x16, 0x27, 0x9e, 0xff}}}, + {{{ 427, 812, -365}, 0, { 64, 96}, {0x16, 0x27, 0x9e, 0xff}}}, + {{{ 451, 805, -346}, 0, { 64, 96}, {0x16, 0x27, 0x9e, 0xff}}}, +}; + +// 0x07000140 - 0x07000190 +static const Vtx intro_seg7_vertex_07000140[] = { + {{{ 427, 812, -365}, 0, { 64, 96}, {0x14, 0x23, 0x90, 0xff}}}, + {{{ 302, 780, -330}, 0, { 96, 128}, {0x14, 0x23, 0x90, 0xff}}}, + {{{ 406, 804, -345}, 0, { 64, 96}, {0x14, 0x23, 0x90, 0xff}}}, + {{{ 276, 781, -348}, 0, { 64, 128}, {0x14, 0x23, 0x90, 0xff}}}, + {{{ 427, 812, -365}, 0, { 64, 96}, {0x14, 0x23, 0x90, 0xff}}}, +}; + +// 0x07000190 - 0x070001D0 +static const Vtx intro_seg7_vertex_07000190[] = { + {{{ 557, 762, -320}, 0, { 96, 64}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ 573, 772, -341}, 0, { 96, 64}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ 553, 804, -345}, 0, { 96, 64}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ 571, 814, -363}, 0, { 64, 64}, {0x20, 0x39, 0xe5, 0xff}}}, +}; + +// 0x070001D0 - 0x07000210 +static const Vtx intro_seg7_vertex_070001D0[] = { + {{{ 653, 778, -348}, 0, { 96, 32}, {0x14, 0x23, 0x90, 0xff}}}, + {{{ 573, 772, -341}, 0, { 96, 64}, {0x14, 0x23, 0x90, 0xff}}}, + {{{ 639, 768, -323}, 0, { 96, 32}, {0x14, 0x23, 0x90, 0xff}}}, + {{{ 557, 762, -320}, 0, { 96, 64}, {0x14, 0x23, 0x90, 0xff}}}, +}; + +// 0x07000210 - 0x07000250 +static const Vtx intro_seg7_vertex_07000210[] = { + {{{ 653, 778, -348}, 0, { 96, 32}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ 639, 768, -323}, 0, { 96, 32}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ 647, 662, -276}, 0, { 128, 32}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ 632, 689, -276}, 0, { 128, 32}, {0x20, 0x39, 0xe5, 0xff}}}, +}; + +// 0x07000250 - 0x07000280 +static const Vtx intro_seg7_vertex_07000250[] = { + {{{ 647, 662, -276}, 0, { 128, 32}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ 632, 689, -276}, 0, { 128, 32}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ 637, 664, -277}, 0, { 128, 32}, {0x20, 0x39, 0xe5, 0xff}}}, +}; + +// 0x07000280 - 0x070002B0 +static const Vtx intro_seg7_vertex_07000280[] = { + {{{ 637, 664, -277}, 0, { 128, 32}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ 632, 689, -276}, 0, { 128, 32}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ 621, 687, -275}, 0, { 128, 32}, {0x20, 0x39, 0xe5, 0xff}}}, +}; + +// 0x070002B0 - 0x070002E0 +static const Vtx intro_seg7_vertex_070002B0[] = { + {{{ 632, 689, -276}, 0, { 128, 32}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ 506, 692, -278}, 0, { 128, 64}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ 621, 687, -275}, 0, { 128, 32}, {0x20, 0x39, 0xe5, 0xff}}}, +}; + +// 0x070002E0 - 0x07000310 +static const Vtx intro_seg7_vertex_070002E0[] = { + {{{ 545, 679, -286}, 0, { 128, 64}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ 621, 687, -275}, 0, { 128, 32}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ 506, 692, -278}, 0, { 128, 64}, {0x20, 0x39, 0xe5, 0xff}}}, +}; + +// 0x07000310 - 0x07000340 +static const Vtx intro_seg7_vertex_07000310[] = { + {{{ 545, 679, -286}, 0, { 128, 64}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ 506, 692, -278}, 0, { 128, 64}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ 503, 682, -272}, 0, { 128, 64}, {0x20, 0x39, 0xe5, 0xff}}}, +}; + +// 0x07000340 - 0x07000370 +static const Vtx intro_seg7_vertex_07000340[] = { + {{{ 621, 687, -275}, 0, { 128, 32}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ 614, 680, -271}, 0, { 128, 64}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ 637, 664, -277}, 0, { 128, 32}, {0x20, 0x39, 0xe5, 0xff}}}, +}; + +// 0x07000370 - 0x070003A0 +static const Vtx intro_seg7_vertex_07000370[] = { + {{{ 621, 687, -275}, 0, { 128, 32}, {0x14, 0x23, 0x90, 0xff}}}, + {{{ 545, 679, -286}, 0, { 128, 64}, {0x14, 0x23, 0x90, 0xff}}}, + {{{ 614, 680, -271}, 0, { 128, 64}, {0x14, 0x23, 0x90, 0xff}}}, +}; + +// 0x070003A0 - 0x070003D0 +static const Vtx intro_seg7_vertex_070003A0[] = { + {{{ 545, 679, -286}, 0, { 128, 64}, {0x14, 0x27, 0x9e, 0xff}}}, + {{{ 503, 682, -272}, 0, { 128, 64}, {0x14, 0x27, 0x9e, 0xff}}}, + {{{ 614, 680, -271}, 0, { 128, 64}, {0x14, 0x27, 0x9e, 0xff}}}, +}; + +// 0x070003D0 - 0x07000410 +static const Vtx intro_seg7_vertex_070003D0[] = { + {{{ 618, 578, -227}, 0, { 160, 32}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ 629, 625, -238}, 0, { 160, 32}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ 587, 571, -206}, 0, { 160, 64}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ 646, 614, -248}, 0, { 160, 32}, {0x20, 0x39, 0xe5, 0xff}}}, +}; + +// 0x07000410 - 0x07000450 +static const Vtx intro_seg7_vertex_07000410[] = { + {{{ 652, 577, -226}, 0, { 160, 32}, {0x12, 0x20, 0x81, 0xff}}}, + {{{ 618, 578, -227}, 0, { 160, 32}, {0x12, 0x20, 0x81, 0xff}}}, + {{{ 638, 572, -206}, 0, { 160, 32}, {0x12, 0x20, 0x81, 0xff}}}, + {{{ 587, 571, -206}, 0, { 160, 64}, {0x12, 0x20, 0x81, 0xff}}}, +}; + +// 0x07000450 - 0x07000490 +static const Vtx intro_seg7_vertex_07000450[] = { + {{{ 646, 614, -248}, 0, { 160, 32}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ 637, 664, -277}, 0, { 128, 32}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ 629, 625, -238}, 0, { 160, 32}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ 614, 680, -271}, 0, { 128, 64}, {0x20, 0x39, 0xe5, 0xff}}}, +}; + +// 0x07000490 - 0x070004D0 +static const Vtx intro_seg7_vertex_07000490[] = { + {{{ 658, 486, -172}, 0, { 192, 32}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ 652, 577, -226}, 0, { 160, 32}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ 642, 504, -165}, 0, { 192, 32}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ 638, 572, -206}, 0, { 160, 32}, {0x20, 0x39, 0xe5, 0xff}}}, +}; + +// 0x070004D0 - 0x07000510 +static const Vtx intro_seg7_vertex_070004D0[] = { + {{{ 611, 499, -162}, 0, { 192, 64}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ 627, 482, -170}, 0, { 192, 32}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ 642, 504, -165}, 0, { 192, 32}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ 658, 486, -172}, 0, { 192, 32}, {0x20, 0x39, 0xe5, 0xff}}}, +}; + +// 0x07000510 - 0x07000550 +static const Vtx intro_seg7_vertex_07000510[] = { + {{{ 642, 392, -117}, 0, { 224, 32}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ 627, 482, -170}, 0, { 192, 32}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ 626, 410, -109}, 0, { 224, 64}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ 611, 499, -162}, 0, { 192, 64}, {0x20, 0x39, 0xe5, 0xff}}}, +}; + +// 0x07000550 - 0x07000590 +static const Vtx intro_seg7_vertex_07000550[] = { + {{{ 642, 392, -117}, 0, { 224, 32}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ 626, 410, -109}, 0, { 224, 64}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ 463, 390, -115}, 0, { 224, 96}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ 482, 408, -108}, 0, { 224, 96}, {0x20, 0x39, 0xe5, 0xff}}}, +}; + +// 0x07000590 - 0x070005C0 +static const Vtx intro_seg7_vertex_07000590[] = { + {{{ 463, 390, -115}, 0, { 224, 96}, {0x12, 0x20, 0x81, 0xff}}}, + {{{ 482, 408, -108}, 0, { 224, 96}, {0x12, 0x20, 0x81, 0xff}}}, + {{{ 461, 469, -162}, 0, { 192, 96}, {0x12, 0x20, 0x81, 0xff}}}, +}; + +// 0x070005C0 - 0x070005F0 +static const Vtx intro_seg7_vertex_070005C0[] = { + {{{ 461, 469, -162}, 0, { 192, 96}, {0xff, 0xff, 0xff, 0x01}}}, + {{{ 482, 408, -108}, 0, { 224, 96}, {0xff, 0xff, 0xff, 0x01}}}, + {{{ 466, 457, -137}, 0, { 192, 96}, {0xff, 0xff, 0xff, 0x01}}}, +}; + +// 0x070005F0 - 0x07000620 +static const Vtx intro_seg7_vertex_070005F0[] = { + {{{ 461, 469, -162}, 0, { 192, 96}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ 466, 457, -137}, 0, { 192, 96}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ 505, 481, -151}, 0, { 192, 96}, {0x20, 0x39, 0xe5, 0xff}}}, +}; + +// 0x07000620 - 0x07000650 +static const Vtx intro_seg7_vertex_07000620[] = { + {{{ 461, 469, -162}, 0, { 192, 96}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ 505, 481, -151}, 0, { 192, 96}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ 499, 498, -162}, 0, { 192, 96}, {0x20, 0x39, 0xe5, 0xff}}}, +}; + +// 0x07000650 - 0x07000680 +static const Vtx intro_seg7_vertex_07000650[] = { + {{{ 461, 469, -162}, 0, { 192, 96}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ 499, 498, -162}, 0, { 192, 96}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ 442, 496, -161}, 0, { 192, 96}, {0x20, 0x39, 0xe5, 0xff}}}, +}; + +// 0x07000680 - 0x070006B0 +static const Vtx intro_seg7_vertex_07000680[] = { + {{{ 463, 390, -115}, 0, { 224, 96}, {0x20, 0x39, 0x81, 0xff}}}, + {{{ 461, 469, -162}, 0, { 192, 96}, {0x20, 0x39, 0x81, 0xff}}}, + {{{ 445, 408, -108}, 0, { 224, 96}, {0x20, 0x39, 0x81, 0xff}}}, +}; + +// 0x070006B0 - 0x070006E0 +static const Vtx intro_seg7_vertex_070006B0[] = { + {{{ 461, 469, -162}, 0, { 192, 96}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ 442, 496, -161}, 0, { 192, 96}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ 445, 408, -108}, 0, { 224, 96}, {0x20, 0x39, 0xe5, 0xff}}}, +}; + +// 0x070006E0 - 0x07000720 +static const Vtx intro_seg7_vertex_070006E0[] = { + {{{ 463, 390, -115}, 0, { 224, 96}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ 445, 408, -108}, 0, { 224, 96}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ 347, 390, -115}, 0, { 224, 128}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ 351, 408, -108}, 0, { 224, 128}, {0x20, 0x39, 0xe5, 0xff}}}, +}; + +// 0x07000720 - 0x07000750 +static const Vtx intro_seg7_vertex_07000720[] = { + {{{ 347, 390, -115}, 0, { 224, 128}, {0x12, 0x20, 0x81, 0xff}}}, + {{{ 351, 408, -108}, 0, { 224, 128}, {0x12, 0x20, 0x81, 0xff}}}, + {{{ 341, 430, -139}, 0, { 224, 128}, {0x12, 0x20, 0x81, 0xff}}}, +}; + +// 0x07000750 - 0x07000780 +static const Vtx intro_seg7_vertex_07000750[] = { + {{{ 341, 430, -139}, 0, { 224, 128}, {0x12, 0x20, 0x81, 0xff}}}, + {{{ 351, 408, -108}, 0, { 224, 128}, {0x12, 0x20, 0x81, 0xff}}}, + {{{ 343, 447, -131}, 0, { 192, 128}, {0x12, 0x20, 0x81, 0xff}}}, +}; + +// 0x07000780 - 0x070007B0 +static const Vtx intro_seg7_vertex_07000780[] = { + {{{ 355, 490, -175}, 0, { 192, 128}, {0x12, 0x20, 0x81, 0xff}}}, + {{{ 341, 430, -139}, 0, { 224, 128}, {0x12, 0x20, 0x81, 0xff}}}, + {{{ 363, 472, -146}, 0, { 192, 128}, {0x12, 0x20, 0x81, 0xff}}}, +}; + +// 0x070007B0 - 0x070007E0 +static const Vtx intro_seg7_vertex_070007B0[] = { + {{{ 341, 430, -139}, 0, { 224, 128}, {0x12, 0x20, 0x81, 0xff}}}, + {{{ 343, 447, -131}, 0, { 192, 128}, {0x12, 0x20, 0x81, 0xff}}}, + {{{ 363, 472, -146}, 0, { 192, 128}, {0x12, 0x20, 0x81, 0xff}}}, +}; + +// 0x070007E0 - 0x07000810 +static const Vtx intro_seg7_vertex_070007E0[] = { + {{{ 355, 490, -175}, 0, { 192, 128}, {0x12, 0x20, 0x81, 0xff}}}, + {{{ 363, 472, -146}, 0, { 192, 128}, {0x12, 0x20, 0x81, 0xff}}}, + {{{ 359, 588, -216}, 0, { 160, 128}, {0x12, 0x20, 0x81, 0xff}}}, +}; + +// 0x07000810 - 0x07000840 +static const Vtx intro_seg7_vertex_07000810[] = { + {{{ 355, 490, -175}, 0, { 192, 128}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ 359, 588, -216}, 0, { 160, 128}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ 352, 506, -167}, 0, { 192, 128}, {0x20, 0x39, 0xe5, 0xff}}}, +}; + +// 0x07000840 - 0x07000870 +static const Vtx intro_seg7_vertex_07000840[] = { + {{{ 338, 374, -106}, 0, { 256, 128}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ 347, 390, -115}, 0, { 224, 128}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ 324, 401, -104}, 0, { 224, 128}, {0x20, 0x39, 0xe5, 0xff}}}, +}; + +// 0x07000870 - 0x070008A0 +static const Vtx intro_seg7_vertex_07000870[] = { + {{{ 352, 506, -167}, 0, { 192, 128}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ 324, 401, -104}, 0, { 224, 128}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ 355, 490, -175}, 0, { 192, 128}, {0x20, 0x39, 0xe5, 0xff}}}, +}; + +// 0x070008A0 - 0x070008D0 +static const Vtx intro_seg7_vertex_070008A0[] = { + {{{ 355, 490, -175}, 0, { 192, 128}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ 324, 401, -104}, 0, { 224, 128}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ 341, 430, -139}, 0, { 224, 128}, {0x20, 0x39, 0xe5, 0xff}}}, +}; + +// 0x070008D0 - 0x07000900 +static const Vtx intro_seg7_vertex_070008D0[] = { + {{{ 347, 390, -115}, 0, { 224, 128}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ 341, 430, -139}, 0, { 224, 128}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ 324, 401, -104}, 0, { 224, 128}, {0x20, 0x39, 0xe5, 0xff}}}, +}; + +// 0x07000900 - 0x07000940 +static const Vtx intro_seg7_vertex_07000900[] = { + {{{ 141, 425, -137}, 0, { 224, 192}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ 338, 374, -106}, 0, { 256, 128}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ 173, 443, -129}, 0, { 192, 160}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ 324, 401, -104}, 0, { 224, 128}, {0x20, 0x39, 0xe5, 0xff}}}, +}; + +// 0x07000940 - 0x07000980 +static const Vtx intro_seg7_vertex_07000940[] = { + {{{ 141, 425, -137}, 0, { 224, 192}, {0x10, 0x1c, 0x73, 0xff}}}, + {{{ 173, 443, -129}, 0, { 192, 160}, {0x10, 0x1c, 0x73, 0xff}}}, + {{{ 278, 596, -220}, 0, { 160, 128}, {0x10, 0x1c, 0x73, 0xff}}}, + {{{ 261, 594, -236}, 0, { 160, 128}, {0x10, 0x1c, 0x73, 0xff}}}, +}; + +// 0x07000980 - 0x070009C0 +static const Vtx intro_seg7_vertex_07000980[] = { + {{{ 291, 666, -262}, 0, { 128, 128}, {0x12, 0x20, 0x81, 0xff}}}, + {{{ 274, 649, -268}, 0, { 128, 128}, {0x12, 0x20, 0x81, 0xff}}}, + {{{ 278, 596, -220}, 0, { 160, 128}, {0x12, 0x20, 0x81, 0xff}}}, + {{{ 261, 594, -236}, 0, { 160, 128}, {0x12, 0x20, 0x81, 0xff}}}, +}; + +// 0x070009C0 - 0x07000A00 +static const Vtx intro_seg7_vertex_070009C0[] = { + {{{ 291, 666, -262}, 0, { 128, 128}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ 263, 669, -264}, 0, { 128, 128}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ 274, 649, -268}, 0, { 128, 128}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ 248, 650, -269}, 0, { 128, 160}, {0x20, 0x39, 0xe5, 0xff}}}, +}; + +// 0x07000A00 - 0x07000A40 +static const Vtx intro_seg7_vertex_07000A00[] = { + {{{ 248, 650, -269}, 0, { 128, 160}, {0x12, 0x20, 0x81, 0xff}}}, + {{{ 263, 669, -264}, 0, { 128, 128}, {0x12, 0x20, 0x81, 0xff}}}, + {{{ 247, 742, -321}, 0, { 96, 128}, {0x12, 0x20, 0x81, 0xff}}}, + {{{ 266, 735, -303}, 0, { 96, 128}, {0x12, 0x20, 0x81, 0xff}}}, +}; + +// 0x07000A40 - 0x07000A80 +static const Vtx intro_seg7_vertex_07000A40[] = { + {{{ 324, 740, -307}, 0, { 96, 128}, {0x16, 0x27, 0x9e, 0xff}}}, + {{{ 302, 744, -325}, 0, { 96, 128}, {0x16, 0x27, 0x9e, 0xff}}}, + {{{ 266, 735, -303}, 0, { 96, 128}, {0x16, 0x27, 0x9e, 0xff}}}, + {{{ 247, 742, -321}, 0, { 96, 128}, {0x16, 0x27, 0x9e, 0xff}}}, +}; + +// 0x07000A80 - 0x07000AC0 +static const Vtx intro_seg7_vertex_07000A80[] = { + {{{ 324, 740, -307}, 0, { 96, 128}, {0x12, 0x20, 0x81, 0xff}}}, + {{{ 302, 780, -330}, 0, { 96, 128}, {0x12, 0x20, 0x81, 0xff}}}, + {{{ 302, 744, -325}, 0, { 96, 128}, {0x12, 0x20, 0x81, 0xff}}}, + {{{ 276, 781, -348}, 0, { 64, 128}, {0x12, 0x20, 0x81, 0xff}}}, +}; + +// 0x07000AC0 - 0x07000AF0 +static const Vtx intro_seg7_vertex_07000AC0[] = { + {{{ 428, 674, -267}, 0, { 128, 96}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ 362, 671, -266}, 0, { 128, 96}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ 380, 649, -269}, 0, { 128, 96}, {0x20, 0x39, 0xe5, 0xff}}}, +}; + +// 0x07000AF0 - 0x07000B20 +static const Vtx intro_seg7_vertex_07000AF0[] = { + {{{ 380, 649, -269}, 0, { 128, 96}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ 362, 671, -266}, 0, { 128, 96}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ 363, 640, -247}, 0, { 128, 96}, {0x20, 0x39, 0xe5, 0xff}}}, +}; + +// 0x07000B20 - 0x07000B50 +static const Vtx intro_seg7_vertex_07000B20[] = { + {{{ 380, 649, -269}, 0, { 128, 96}, {0x16, 0x27, 0x9e, 0xff}}}, + {{{ 363, 640, -247}, 0, { 128, 96}, {0x16, 0x27, 0x9e, 0xff}}}, + {{{ 410, 640, -247}, 0, { 128, 96}, {0x16, 0x27, 0x9e, 0xff}}}, +}; + +// 0x07000B50 - 0x07000B80 +static const Vtx intro_seg7_vertex_07000B50[] = { + {{{ 380, 649, -269}, 0, { 128, 96}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ 410, 640, -247}, 0, { 128, 96}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ 428, 674, -267}, 0, { 128, 96}, {0x20, 0x39, 0xe5, 0xff}}}, +}; + +// 0x07000B80 - 0x07000BB0 +static const Vtx intro_seg7_vertex_07000B80[] = { + {{{ 504, 622, -236}, 0, { 160, 64}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ 473, 619, -234}, 0, { 160, 96}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ 469, 578, -227}, 0, { 160, 96}, {0x20, 0x39, 0xe5, 0xff}}}, +}; + +// 0x07000BB0 - 0x07000BE0 +static const Vtx intro_seg7_vertex_07000BB0[] = { + {{{ 469, 578, -227}, 0, { 160, 96}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ 473, 619, -234}, 0, { 160, 96}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ 457, 596, -220}, 0, { 160, 96}, {0x20, 0x39, 0xe5, 0xff}}}, +}; + +// 0x07000BE0 - 0x07000C10 +static const Vtx intro_seg7_vertex_07000BE0[] = { + {{{ 469, 578, -227}, 0, { 160, 96}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ 457, 596, -220}, 0, { 160, 96}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ 436, 608, -228}, 0, { 160, 96}, {0x20, 0x39, 0xe5, 0xff}}}, +}; + +// 0x07000C10 - 0x07000C40 +static const Vtx intro_seg7_vertex_07000C10[] = { + {{{ 469, 578, -227}, 0, { 160, 96}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ 436, 608, -228}, 0, { 160, 96}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ 439, 567, -203}, 0, { 160, 96}, {0x20, 0x39, 0xe5, 0xff}}}, +}; + +// 0x07000C40 - 0x07000C70 +static const Vtx intro_seg7_vertex_07000C40[] = { + {{{ 469, 578, -227}, 0, { 160, 96}, {0x16, 0x27, 0x9e, 0xff}}}, + {{{ 439, 567, -203}, 0, { 160, 96}, {0x16, 0x27, 0x9e, 0xff}}}, + {{{ 482, 570, -205}, 0, { 160, 96}, {0x16, 0x27, 0x9e, 0xff}}}, +}; + +// 0x07000C70 - 0x07000CA0 +static const Vtx intro_seg7_vertex_07000C70[] = { + {{{ 469, 578, -227}, 0, { 160, 96}, {0x12, 0x20, 0x81, 0xff}}}, + {{{ 482, 570, -205}, 0, { 160, 96}, {0x12, 0x20, 0x81, 0xff}}}, + {{{ 475, 585, -214}, 0, { 160, 96}, {0x12, 0x20, 0x81, 0xff}}}, +}; + +// 0x07000CA0 - 0x07000CD0 +static const Vtx intro_seg7_vertex_07000CA0[] = { + {{{ 469, 578, -227}, 0, { 160, 96}, {0x12, 0x20, 0x7f, 0xff}}}, + {{{ 475, 585, -214}, 0, { 160, 96}, {0x12, 0x20, 0x7f, 0xff}}}, + {{{ 504, 622, -236}, 0, { 160, 64}, {0x12, 0x20, 0x7f, 0xff}}}, +}; + +// 0x07000CD0 - 0x07000D00 +static const Vtx intro_seg7_vertex_07000CD0[] = { + {{{ 515, 621, -236}, 0, { 160, 64}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ 542, 602, -224}, 0, { 160, 64}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ 544, 600, -240}, 0, { 160, 64}, {0x20, 0x39, 0xe5, 0xff}}}, +}; + +// 0x07000D00 - 0x07000D30 +static const Vtx intro_seg7_vertex_07000D00[] = { + {{{ 544, 600, -240}, 0, { 160, 64}, {0x12, 0x20, 0x7f, 0xff}}}, + {{{ 542, 602, -224}, 0, { 160, 64}, {0x12, 0x20, 0x7f, 0xff}}}, + {{{ 564, 621, -235}, 0, { 160, 64}, {0x12, 0x20, 0x7f, 0xff}}}, +}; + +// 0x07000D30 - 0x07000D60 +static const Vtx intro_seg7_vertex_07000D30[] = { + {{{ 544, 600, -240}, 0, { 160, 64}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ 564, 621, -235}, 0, { 160, 64}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ 515, 621, -236}, 0, { 160, 64}, {0x20, 0x39, 0xe5, 0xff}}}, +}; + +// 0x07000D60 - 0x07000E60 +static const Vtx intro_seg7_vertex_07000D60[] = { + {{{ 173, 443, -129}, 0, { 192, 160}, {0x65, 0x7f, 0xff, 0xff}}}, + {{{ 324, 401, -104}, 0, { 224, 128}, {0x65, 0x7f, 0xff, 0xff}}}, + {{{ 278, 596, -220}, 0, { 160, 128}, {0x65, 0x7f, 0xff, 0xff}}}, + {{{ 352, 506, -167}, 0, { 192, 128}, {0x65, 0x7f, 0xff, 0xff}}}, + {{{ 359, 588, -216}, 0, { 160, 128}, {0x65, 0x7f, 0xff, 0xff}}}, + {{{ 291, 666, -262}, 0, { 128, 128}, {0x65, 0x7f, 0xff, 0xff}}}, + {{{ 363, 472, -146}, 0, { 192, 128}, {0x65, 0x7f, 0xff, 0xff}}}, + {{{ 442, 496, -161}, 0, { 192, 96}, {0x65, 0x7f, 0xff, 0xff}}}, + {{{ 439, 567, -203}, 0, { 160, 96}, {0x65, 0x7f, 0xff, 0xff}}}, + {{{ 436, 608, -228}, 0, { 160, 96}, {0x65, 0x7f, 0xff, 0xff}}}, + {{{ 302, 780, -330}, 0, { 96, 128}, {0x65, 0x7f, 0xff, 0xff}}}, + {{{ 324, 740, -307}, 0, { 96, 128}, {0x65, 0x7f, 0xff, 0xff}}}, + {{{ 406, 804, -345}, 0, { 64, 96}, {0x65, 0x7f, 0xff, 0xff}}}, + {{{ 416, 749, -312}, 0, { 96, 96}, {0x65, 0x7f, 0xff, 0xff}}}, + {{{ 266, 735, -303}, 0, { 96, 128}, {0x65, 0x7f, 0xff, 0xff}}}, + {{{ 362, 671, -266}, 0, { 128, 96}, {0x65, 0x7f, 0xff, 0xff}}}, +}; + +// 0x07000E60 - 0x07000F50 +static const Vtx intro_seg7_vertex_07000E60[] = { + {{{ 362, 671, -266}, 0, { 128, 96}, {0x65, 0x7f, 0xff, 0xff}}}, + {{{ 428, 674, -267}, 0, { 128, 96}, {0x65, 0x7f, 0xff, 0xff}}}, + {{{ 416, 749, -312}, 0, { 96, 96}, {0x65, 0x7f, 0xff, 0xff}}}, + {{{ 452, 751, -313}, 0, { 96, 96}, {0x65, 0x7f, 0xff, 0xff}}}, + {{{ 626, 410, -109}, 0, { 224, 64}, {0x65, 0x7f, 0xff, 0xff}}}, + {{{ 611, 499, -162}, 0, { 192, 64}, {0x65, 0x7f, 0xff, 0xff}}}, + {{{ 482, 408, -108}, 0, { 224, 96}, {0x65, 0x7f, 0xff, 0xff}}}, + {{{ 466, 457, -137}, 0, { 192, 96}, {0x65, 0x7f, 0xff, 0xff}}}, + {{{ 505, 481, -151}, 0, { 192, 96}, {0x65, 0x7f, 0xff, 0xff}}}, + {{{ 642, 504, -165}, 0, { 192, 32}, {0x65, 0x7f, 0xff, 0xff}}}, + {{{ 587, 571, -206}, 0, { 160, 64}, {0x65, 0x7f, 0xff, 0xff}}}, + {{{ 499, 498, -162}, 0, { 192, 96}, {0x65, 0x7f, 0xff, 0xff}}}, + {{{ 639, 768, -323}, 0, { 96, 32}, {0x65, 0x7f, 0xff, 0xff}}}, + {{{ 557, 762, -320}, 0, { 96, 64}, {0x65, 0x7f, 0xff, 0xff}}}, + {{{ 632, 689, -276}, 0, { 128, 32}, {0x65, 0x7f, 0xff, 0xff}}}, +}; + +// 0x07000F50 - 0x07001050 +static const Vtx intro_seg7_vertex_07000F50[] = { + {{{ 632, 689, -276}, 0, { 128, 32}, {0x65, 0x7f, 0xff, 0xff}}}, + {{{ 557, 762, -320}, 0, { 96, 64}, {0x65, 0x7f, 0xff, 0xff}}}, + {{{ 506, 692, -278}, 0, { 128, 64}, {0x65, 0x7f, 0xff, 0xff}}}, + {{{ 553, 804, -345}, 0, { 96, 64}, {0x65, 0x7f, 0xff, 0xff}}}, + {{{ 452, 751, -313}, 0, { 96, 96}, {0x65, 0x7f, 0xff, 0xff}}}, + {{{ 428, 674, -267}, 0, { 128, 96}, {0x65, 0x7f, 0xff, 0xff}}}, + {{{ 503, 682, -272}, 0, { 128, 64}, {0x65, 0x7f, 0xff, 0xff}}}, + {{{ 263, 669, -264}, 0, { 128, 128}, {0x65, 0x7f, 0xff, 0xff}}}, + {{{ 291, 666, -262}, 0, { 128, 128}, {0x65, 0x7f, 0xff, 0xff}}}, + {{{ 266, 735, -303}, 0, { 96, 128}, {0x65, 0x7f, 0xff, 0xff}}}, + {{{ 436, 608, -228}, 0, { 160, 96}, {0x65, 0x7f, 0xff, 0xff}}}, + {{{ 363, 640, -247}, 0, { 128, 96}, {0x65, 0x7f, 0xff, 0xff}}}, + {{{ 362, 671, -266}, 0, { 128, 96}, {0x65, 0x7f, 0xff, 0xff}}}, + {{{ 445, 408, -108}, 0, { 224, 96}, {0x65, 0x7f, 0xff, 0xff}}}, + {{{ 442, 496, -161}, 0, { 192, 96}, {0x65, 0x7f, 0xff, 0xff}}}, + {{{ 351, 408, -108}, 0, { 224, 128}, {0x65, 0x7f, 0xff, 0xff}}}, +}; + +// 0x07001050 - 0x07001130 +static const Vtx intro_seg7_vertex_07001050[] = { + {{{ 351, 408, -108}, 0, { 224, 128}, {0x65, 0x7f, 0xff, 0xff}}}, + {{{ 442, 496, -161}, 0, { 192, 96}, {0x65, 0x7f, 0xff, 0xff}}}, + {{{ 343, 447, -131}, 0, { 192, 128}, {0x65, 0x7f, 0xff, 0xff}}}, + {{{ 363, 472, -146}, 0, { 192, 128}, {0x65, 0x7f, 0xff, 0xff}}}, + {{{ 499, 498, -162}, 0, { 192, 96}, {0x65, 0x7f, 0xff, 0xff}}}, + {{{ 542, 602, -224}, 0, { 160, 64}, {0x65, 0x7f, 0xff, 0xff}}}, + {{{ 482, 570, -205}, 0, { 160, 96}, {0x65, 0x7f, 0xff, 0xff}}}, + {{{ 439, 567, -203}, 0, { 160, 96}, {0x65, 0x7f, 0xff, 0xff}}}, + {{{ 451, 805, -346}, 0, { 64, 96}, {0x65, 0x7f, 0xff, 0xff}}}, + {{{ 452, 751, -313}, 0, { 96, 96}, {0x65, 0x7f, 0xff, 0xff}}}, + {{{ 553, 804, -345}, 0, { 96, 64}, {0x65, 0x7f, 0xff, 0xff}}}, + {{{ 638, 572, -206}, 0, { 160, 32}, {0x65, 0x7f, 0xff, 0xff}}}, + {{{ 587, 571, -206}, 0, { 160, 64}, {0x65, 0x7f, 0xff, 0xff}}}, + {{{ 642, 504, -165}, 0, { 192, 32}, {0x65, 0x7f, 0xff, 0xff}}}, +}; + +// 0x07001130 - 0x07001220 +static const Vtx intro_seg7_vertex_07001130[] = { + {{{ 629, 625, -238}, 0, { 160, 32}, {0x65, 0x7f, 0xff, 0xff}}}, + {{{ 564, 621, -235}, 0, { 160, 64}, {0x65, 0x7f, 0xff, 0xff}}}, + {{{ 587, 571, -206}, 0, { 160, 64}, {0x65, 0x7f, 0xff, 0xff}}}, + {{{ 542, 602, -224}, 0, { 160, 64}, {0x65, 0x7f, 0xff, 0xff}}}, + {{{ 499, 498, -162}, 0, { 192, 96}, {0x65, 0x7f, 0xff, 0xff}}}, + {{{ 614, 680, -271}, 0, { 128, 64}, {0x65, 0x7f, 0xff, 0xff}}}, + {{{ 503, 682, -272}, 0, { 128, 64}, {0x65, 0x7f, 0xff, 0xff}}}, + {{{ 515, 621, -236}, 0, { 160, 64}, {0x65, 0x7f, 0xff, 0xff}}}, + {{{ 504, 622, -236}, 0, { 160, 64}, {0x65, 0x7f, 0xff, 0xff}}}, + {{{ 473, 619, -234}, 0, { 160, 96}, {0x65, 0x7f, 0xff, 0xff}}}, + {{{ 428, 674, -267}, 0, { 128, 96}, {0x65, 0x7f, 0xff, 0xff}}}, + {{{ 482, 570, -205}, 0, { 160, 96}, {0x65, 0x7f, 0xff, 0xff}}}, + {{{ 475, 585, -214}, 0, { 160, 96}, {0x65, 0x7f, 0xff, 0xff}}}, + {{{ 457, 596, -220}, 0, { 160, 96}, {0x65, 0x7f, 0xff, 0xff}}}, + {{{ 436, 608, -228}, 0, { 160, 96}, {0x65, 0x7f, 0xff, 0xff}}}, +}; + +// 0x07001220 - 0x07001270 +static const Vtx intro_seg7_vertex_07001220[] = { + {{{ 363, 640, -247}, 0, { 128, 96}, {0x65, 0x7f, 0xff, 0xff}}}, + {{{ 436, 608, -228}, 0, { 160, 96}, {0x65, 0x7f, 0xff, 0xff}}}, + {{{ 410, 640, -247}, 0, { 128, 96}, {0x65, 0x7f, 0xff, 0xff}}}, + {{{ 473, 619, -234}, 0, { 160, 96}, {0x65, 0x7f, 0xff, 0xff}}}, + {{{ 428, 674, -267}, 0, { 128, 96}, {0x65, 0x7f, 0xff, 0xff}}}, +}; + +// 0x07001270 - 0x070012B0 +static const Vtx intro_seg7_vertex_07001270[] = { + {{{ 213, 700, -299}, 0, { 128, 160}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ 278, 778, -345}, 0, { 96, 128}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ 208, 731, -301}, 0, { 96, 160}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ 255, 785, -333}, 0, { 96, 128}, {0x20, 0x39, 0xe5, 0xff}}}, +}; + +// 0x070012B0 - 0x070012F0 +static const Vtx intro_seg7_vertex_070012B0[] = { + {{{ 94, 750, -328}, 0, { 96, 192}, {0x18, 0x2b, 0xad, 0xff}}}, + {{{ 208, 731, -301}, 0, { 96, 160}, {0x18, 0x2b, 0xad, 0xff}}}, + {{{ 122, 764, -321}, 0, { 96, 160}, {0x18, 0x2b, 0xad, 0xff}}}, + {{{ 213, 700, -299}, 0, { 128, 160}, {0x18, 0x2b, 0xad, 0xff}}}, +}; + +// 0x070012F0 - 0x07001330 +static const Vtx intro_seg7_vertex_070012F0[] = { + {{{ 180, 850, -387}, 0, { 32, 160}, {0x10, 0x1c, 0x73, 0xff}}}, + {{{ 94, 750, -328}, 0, { 96, 192}, {0x10, 0x1c, 0x73, 0xff}}}, + {{{ 185, 837, -365}, 0, { 64, 160}, {0x10, 0x1c, 0x73, 0xff}}}, + {{{ 122, 764, -321}, 0, { 96, 160}, {0x10, 0x1c, 0x73, 0xff}}}, +}; + +// 0x07001330 - 0x07001370 +static const Vtx intro_seg7_vertex_07001330[] = { + {{{ 278, 778, -345}, 0, { 96, 128}, {0x1a, 0x2e, 0xbb, 0xff}}}, + {{{ 180, 850, -387}, 0, { 32, 160}, {0x1a, 0x2e, 0xbb, 0xff}}}, + {{{ 255, 785, -333}, 0, { 96, 128}, {0x1a, 0x2e, 0xbb, 0xff}}}, + {{{ 185, 837, -365}, 0, { 64, 160}, {0x1a, 0x2e, 0xbb, 0xff}}}, +}; + +// 0x07001370 - 0x070013B0 +static const Vtx intro_seg7_vertex_07001370[] = { + {{{ 122, 764, -321}, 0, { 96, 160}, {0x65, 0x7f, 0xff, 0xff}}}, + {{{ 208, 731, -301}, 0, { 96, 160}, {0x65, 0x7f, 0xff, 0xff}}}, + {{{ 185, 837, -365}, 0, { 64, 160}, {0x65, 0x7f, 0xff, 0xff}}}, + {{{ 255, 785, -333}, 0, { 96, 128}, {0x65, 0x7f, 0xff, 0xff}}}, +}; + +// 0x070013B0 - 0x070013F0 +static const Vtx intro_seg7_vertex_070013B0[] = { + {{{ 214, 657, -257}, 0, { 128, 160}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ 162, 600, -223}, 0, { 160, 160}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ 245, 652, -270}, 0, { 128, 128}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ 170, 568, -221}, 0, { 160, 160}, {0x20, 0x39, 0xe5, 0xff}}}, +}; + +// 0x070013F0 - 0x07001430 +static const Vtx intro_seg7_vertex_070013F0[] = { + {{{ 61, 631, -258}, 0, { 128, 192}, {0x18, 0x2b, 0xad, 0xff}}}, + {{{ 170, 568, -221}, 0, { 160, 160}, {0x18, 0x2b, 0xad, 0xff}}}, + {{{ 84, 642, -248}, 0, { 128, 192}, {0x18, 0x2b, 0xad, 0xff}}}, + {{{ 162, 600, -223}, 0, { 160, 160}, {0x18, 0x2b, 0xad, 0xff}}}, +}; + +// 0x07001430 - 0x07001470 +static const Vtx intro_seg7_vertex_07001430[] = { + {{{ 61, 631, -258}, 0, { 128, 192}, {0x10, 0x1c, 0x73, 0xff}}}, + {{{ 84, 642, -248}, 0, { 128, 192}, {0x10, 0x1c, 0x73, 0xff}}}, + {{{ 134, 738, -321}, 0, { 96, 160}, {0x10, 0x1c, 0x73, 0xff}}}, + {{{ 140, 725, -298}, 0, { 96, 160}, {0x10, 0x1c, 0x73, 0xff}}}, +}; + +// 0x07001470 - 0x070014B0 +static const Vtx intro_seg7_vertex_07001470[] = { + {{{ 245, 652, -270}, 0, { 128, 128}, {0x1a, 0x2e, 0xbb, 0xff}}}, + {{{ 134, 738, -321}, 0, { 96, 160}, {0x1a, 0x2e, 0xbb, 0xff}}}, + {{{ 214, 657, -257}, 0, { 128, 160}, {0x1a, 0x2e, 0xbb, 0xff}}}, + {{{ 140, 725, -298}, 0, { 96, 160}, {0x1a, 0x2e, 0xbb, 0xff}}}, +}; + +// 0x070014B0 - 0x070014F0 +static const Vtx intro_seg7_vertex_070014B0[] = { + {{{ 140, 725, -298}, 0, { 96, 160}, {0x65, 0x7f, 0xff, 0xff}}}, + {{{ 84, 642, -248}, 0, { 128, 192}, {0x65, 0x7f, 0xff, 0xff}}}, + {{{ 214, 657, -257}, 0, { 128, 160}, {0x65, 0x7f, 0xff, 0xff}}}, + {{{ 162, 600, -223}, 0, { 160, 160}, {0x65, 0x7f, 0xff, 0xff}}}, +}; + +// 0x070014F0 - 0x07001530 +static const Vtx intro_seg7_vertex_070014F0[] = { + {{{ 224, 552, -211}, 0, { 160, 128}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ 201, 550, -193}, 0, { 160, 160}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ 126, 383, -111}, 0, { 224, 160}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ 120, 413, -111}, 0, { 224, 192}, {0x20, 0x39, 0xe5, 0xff}}}, +}; + +// 0x07001530 - 0x07001570 +static const Vtx intro_seg7_vertex_07001530[] = { + {{{ -28, 486, -172}, 0, { 192, 224}, {0x18, 0x2b, 0xad, 0xff}}}, + {{{ 126, 383, -111}, 0, { 224, 160}, {0x18, 0x2b, 0xad, 0xff}}}, + {{{ 0, 495, -160}, 0, { 192, 192}, {0x18, 0x2b, 0xad, 0xff}}}, + {{{ 120, 413, -111}, 0, { 224, 192}, {0x18, 0x2b, 0xad, 0xff}}}, +}; + +// 0x07001570 - 0x070015B0 +static const Vtx intro_seg7_vertex_07001570[] = { + {{{ -28, 486, -172}, 0, { 192, 224}, {0x10, 0x1c, 0x73, 0xff}}}, + {{{ 0, 495, -160}, 0, { 192, 192}, {0x10, 0x1c, 0x73, 0xff}}}, + {{{ 97, 580, -211}, 0, { 160, 192}, {0x10, 0x1c, 0x73, 0xff}}}, + {{{ 89, 593, -236}, 0, { 128, 192}, {0x10, 0x1c, 0x73, 0xff}}}, +}; + +// 0x070015B0 - 0x070015F0 +static const Vtx intro_seg7_vertex_070015B0[] = { + {{{ 89, 593, -236}, 0, { 128, 192}, {0x1a, 0x2e, 0xbb, 0xff}}}, + {{{ 97, 580, -211}, 0, { 160, 192}, {0x1a, 0x2e, 0xbb, 0xff}}}, + {{{ 224, 552, -211}, 0, { 160, 128}, {0x1a, 0x2e, 0xbb, 0xff}}}, + {{{ 201, 550, -193}, 0, { 160, 160}, {0x1a, 0x2e, 0xbb, 0xff}}}, +}; + +// 0x070015F0 - 0x07001630 +static const Vtx intro_seg7_vertex_070015F0[] = { + {{{ 120, 413, -111}, 0, { 224, 192}, {0x65, 0x7f, 0xff, 0xff}}}, + {{{ 201, 550, -193}, 0, { 160, 160}, {0x65, 0x7f, 0xff, 0xff}}}, + {{{ 0, 495, -160}, 0, { 192, 192}, {0x65, 0x7f, 0xff, 0xff}}}, + {{{ 97, 580, -211}, 0, { 160, 192}, {0x65, 0x7f, 0xff, 0xff}}}, +}; + +// 0x07001630 - 0x07001670 +static const Vtx intro_seg7_vertex_07001630[] = { + {{{ -385, 770, -324}, 0, { 64, 288}, {0x80, 0x00, 0x00, 0xff}}}, + {{{ -352, 768, -323}, 0, { 64, 288}, {0x80, 0x00, 0x00, 0xff}}}, + {{{ -371, 778, -345}, 0, { 64, 288}, {0x80, 0x00, 0x00, 0xff}}}, + {{{ -340, 779, -346}, 0, { 64, 288}, {0x80, 0x00, 0x00, 0xff}}}, +}; + +// 0x07001670 - 0x070016A0 +static const Vtx intro_seg7_vertex_07001670[] = { + {{{ -340, 779, -346}, 0, { 64, 288}, {0xd7, 0x00, 0x00, 0xff}}}, + {{{ -352, 768, -323}, 0, { 64, 288}, {0xd7, 0x00, 0x00, 0xff}}}, + {{{ -350, 688, -292}, 0, { 96, 288}, {0xd7, 0x00, 0x00, 0xff}}}, +}; + +// 0x070016A0 - 0x070016D0 +static const Vtx intro_seg7_vertex_070016A0[] = { + {{{ -350, 688, -292}, 0, { 96, 288}, {0xd7, 0x00, 0x00, 0xff}}}, + {{{ -352, 768, -323}, 0, { 64, 288}, {0xd7, 0x00, 0x00, 0xff}}}, + {{{ -357, 701, -283}, 0, { 96, 288}, {0xd7, 0x00, 0x00, 0xff}}}, +}; + +// 0x070016D0 - 0x07001700 +static const Vtx intro_seg7_vertex_070016D0[] = { + {{{ -350, 688, -292}, 0, { 96, 288}, {0xd7, 0x00, 0x00, 0xff}}}, + {{{ -357, 701, -283}, 0, { 96, 288}, {0xd7, 0x00, 0x00, 0xff}}}, + {{{ -381, 648, -252}, 0, { 128, 288}, {0xd7, 0x00, 0x00, 0xff}}}, +}; + +// 0x07001700 - 0x07001730 +static const Vtx intro_seg7_vertex_07001700[] = { + {{{ -350, 688, -292}, 0, { 96, 288}, {0x99, 0x00, 0x00, 0xff}}}, + {{{ -381, 648, -252}, 0, { 128, 288}, {0x99, 0x00, 0x00, 0xff}}}, + {{{ -346, 623, -236}, 0, { 128, 288}, {0x99, 0x00, 0x00, 0xff}}}, +}; + +// 0x07001730 - 0x07001760 +static const Vtx intro_seg7_vertex_07001730[] = { + {{{ -346, 623, -236}, 0, { 128, 288}, {0x62, 0x00, 0x00, 0xff}}}, + {{{ -336, 775, -327}, 0, { 64, 288}, {0x62, 0x00, 0x00, 0xff}}}, + {{{ -350, 688, -292}, 0, { 96, 288}, {0x62, 0x00, 0x00, 0xff}}}, +}; + +// 0x07001760 - 0x07001790 +static const Vtx intro_seg7_vertex_07001760[] = { + {{{ -340, 779, -346}, 0, { 64, 288}, {0x62, 0x00, 0x00, 0xff}}}, + {{{ -350, 688, -292}, 0, { 96, 288}, {0x62, 0x00, 0x00, 0xff}}}, + {{{ -336, 775, -327}, 0, { 64, 288}, {0x62, 0x00, 0x00, 0xff}}}, +}; + +// 0x07001790 - 0x070017D0 +static const Vtx intro_seg7_vertex_07001790[] = { + {{{ -405, 831, -361}, 0, { 64, 288}, {0xd7, 0x00, 0x00, 0xff}}}, + {{{ -385, 770, -324}, 0, { 64, 288}, {0xd7, 0x00, 0x00, 0xff}}}, + {{{ -387, 844, -382}, 0, { 32, 288}, {0xd7, 0x00, 0x00, 0xff}}}, + {{{ -371, 778, -345}, 0, { 64, 288}, {0xd7, 0x00, 0x00, 0xff}}}, +}; + +// 0x070017D0 - 0x07001810 +static const Vtx intro_seg7_vertex_070017D0[] = { + {{{ -244, 775, -327}, 0, { 64, 256}, {0x80, 0x00, 0x00, 0xff}}}, + {{{ -261, 785, -349}, 0, { 64, 256}, {0x80, 0x00, 0x00, 0xff}}}, + {{{ -336, 775, -327}, 0, { 64, 288}, {0x80, 0x00, 0x00, 0xff}}}, + {{{ -340, 779, -346}, 0, { 64, 288}, {0x80, 0x00, 0x00, 0xff}}}, +}; + +// 0x07001810 - 0x07001850 +static const Vtx intro_seg7_vertex_07001810[] = { + {{{ -257, 840, -381}, 0, { 32, 256}, {0x62, 0x00, 0x00, 0xff}}}, + {{{ -261, 785, -349}, 0, { 64, 256}, {0x62, 0x00, 0x00, 0xff}}}, + {{{ -236, 830, -360}, 0, { 64, 256}, {0x62, 0x00, 0x00, 0xff}}}, + {{{ -244, 775, -327}, 0, { 64, 256}, {0x62, 0x00, 0x00, 0xff}}}, +}; + +// 0x07001850 - 0x07001890 +static const Vtx intro_seg7_vertex_07001850[] = { + {{{ -257, 840, -381}, 0, { 32, 256}, {0x80, 0x00, 0x00, 0xff}}}, + {{{ -236, 830, -360}, 0, { 64, 256}, {0x80, 0x00, 0x00, 0xff}}}, + {{{ -115, 837, -380}, 0, { 64, 224}, {0x80, 0x00, 0x00, 0xff}}}, + {{{ -130, 832, -361}, 0, { 64, 224}, {0x80, 0x00, 0x00, 0xff}}}, +}; + +// 0x07001890 - 0x070018D0 +static const Vtx intro_seg7_vertex_07001890[] = { + {{{ -132, 769, -324}, 0, { 96, 224}, {0xd7, 0x00, 0x00, 0xff}}}, + {{{ -116, 775, -343}, 0, { 64, 224}, {0xd7, 0x00, 0x00, 0xff}}}, + {{{ -130, 832, -361}, 0, { 64, 224}, {0xd7, 0x00, 0x00, 0xff}}}, + {{{ -115, 837, -380}, 0, { 64, 224}, {0xd7, 0x00, 0x00, 0xff}}}, +}; + +// 0x070018D0 - 0x07001910 +static const Vtx intro_seg7_vertex_070018D0[] = { + {{{ -17, 773, -339}, 0, { 64, 192}, {0x80, 0x00, 0x00, 0xff}}}, + {{{ -116, 775, -343}, 0, { 64, 224}, {0x80, 0x00, 0x00, 0xff}}}, + {{{ -34, 766, -322}, 0, { 96, 192}, {0x80, 0x00, 0x00, 0xff}}}, + {{{ -132, 769, -324}, 0, { 96, 224}, {0x80, 0x00, 0x00, 0xff}}}, +}; + +// 0x07001910 - 0x07001950 +static const Vtx intro_seg7_vertex_07001910[] = { + {{{ -9, 498, -179}, 0, { 192, 192}, {0xd7, 0x00, 0x00, 0xff}}}, + {{{ -34, 766, -322}, 0, { 96, 192}, {0xd7, 0x00, 0x00, 0xff}}}, + {{{ -26, 518, -174}, 0, { 160, 224}, {0xd7, 0x00, 0x00, 0xff}}}, + {{{ -17, 773, -339}, 0, { 64, 192}, {0xd7, 0x00, 0x00, 0xff}}}, +}; + +// 0x07001950 - 0x07001990 +static const Vtx intro_seg7_vertex_07001950[] = { + {{{ -9, 498, -179}, 0, { 192, 192}, {0xc5, 0x00, 0x00, 0xff}}}, + {{{ -26, 518, -174}, 0, { 160, 224}, {0xc5, 0x00, 0x00, 0xff}}}, + {{{ -108, 493, -177}, 0, { 192, 224}, {0xc5, 0x00, 0x00, 0xff}}}, + {{{ -121, 515, -172}, 0, { 160, 224}, {0xc5, 0x00, 0x00, 0xff}}}, +}; + +// 0x07001990 - 0x070019D0 +static const Vtx intro_seg7_vertex_07001990[] = { + {{{ -106, 391, -116}, 0, { 224, 224}, {0xd7, 0x00, 0x00, 0xff}}}, + {{{ -108, 493, -177}, 0, { 192, 224}, {0xd7, 0x00, 0x00, 0xff}}}, + {{{ -122, 413, -111}, 0, { 224, 224}, {0xd7, 0x00, 0x00, 0xff}}}, + {{{ -121, 515, -172}, 0, { 160, 224}, {0xd7, 0x00, 0x00, 0xff}}}, +}; + +// 0x070019D0 - 0x07001A10 +static const Vtx intro_seg7_vertex_070019D0[] = { + {{{ -272, 396, -118}, 0, { 224, 288}, {0xc5, 0x00, 0x00, 0xff}}}, + {{{ -106, 391, -116}, 0, { 224, 224}, {0xc5, 0x00, 0x00, 0xff}}}, + {{{ -255, 416, -113}, 0, { 224, 256}, {0xc5, 0x00, 0x00, 0xff}}}, + {{{ -122, 413, -111}, 0, { 224, 224}, {0xc5, 0x00, 0x00, 0xff}}}, +}; + +// 0x07001A10 - 0x07001A50 +static const Vtx intro_seg7_vertex_07001A10[] = { + {{{ -268, 502, -182}, 0, { 192, 288}, {0x62, 0x00, 0x00, 0xff}}}, + {{{ -255, 416, -113}, 0, { 224, 256}, {0x62, 0x00, 0x00, 0xff}}}, + {{{ -252, 521, -176}, 0, { 160, 256}, {0x62, 0x00, 0x00, 0xff}}}, + {{{ -272, 396, -118}, 0, { 224, 288}, {0x62, 0x00, 0x00, 0xff}}}, +}; + +// 0x07001A50 - 0x07001A90 +static const Vtx intro_seg7_vertex_07001A50[] = { + {{{ -252, 521, -176}, 0, { 160, 256}, {0xc5, 0x00, 0x00, 0xff}}}, + {{{ -351, 524, -177}, 0, { 160, 288}, {0xc5, 0x00, 0x00, 0xff}}}, + {{{ -268, 502, -182}, 0, { 192, 288}, {0xc5, 0x00, 0x00, 0xff}}}, + {{{ -380, 504, -183}, 0, { 192, 288}, {0xc5, 0x00, 0x00, 0xff}}}, +}; + +// 0x07001A90 - 0x07001AC0 +static const Vtx intro_seg7_vertex_07001A90[] = { + {{{ -380, 504, -183}, 0, { 192, 288}, {0x62, 0x00, 0x00, 0xff}}}, + {{{ -351, 524, -177}, 0, { 160, 288}, {0x62, 0x00, 0x00, 0xff}}}, + {{{ -348, 585, -214}, 0, { 160, 288}, {0x62, 0x00, 0x00, 0xff}}}, +}; + +// 0x07001AC0 - 0x07001AF0 +static const Vtx intro_seg7_vertex_07001AC0[] = { + {{{ -380, 504, -183}, 0, { 192, 288}, {0x99, 0x00, 0x00, 0xff}}}, + {{{ -348, 585, -214}, 0, { 160, 288}, {0x99, 0x00, 0x00, 0xff}}}, + {{{ -378, 557, -197}, 0, { 160, 288}, {0x99, 0x00, 0x00, 0xff}}}, +}; + +// 0x07001AF0 - 0x07001B20 +static const Vtx intro_seg7_vertex_07001AF0[] = { + {{{ -380, 504, -183}, 0, { 192, 288}, {0xa1, 0x00, 0x00, 0xff}}}, + {{{ -378, 557, -197}, 0, { 160, 288}, {0xa1, 0x00, 0x00, 0xff}}}, + {{{ -400, 564, -201}, 0, { 160, 288}, {0xa1, 0x00, 0x00, 0xff}}}, +}; + +// 0x07001B20 - 0x07001B60 +static const Vtx intro_seg7_vertex_07001B20[] = { + {{{ -400, 564, -201}, 0, { 160, 288}, {0xd7, 0x00, 0x00, 0xff}}}, + {{{ -398, 425, -118}, 0, { 192, 288}, {0xd7, 0x00, 0x00, 0xff}}}, + {{{ -380, 504, -183}, 0, { 192, 288}, {0xd7, 0x00, 0x00, 0xff}}}, + {{{ -379, 401, -121}, 0, { 224, 288}, {0xd7, 0x00, 0x00, 0xff}}}, +}; + +// 0x07001B60 - 0x07001BA0 +static const Vtx intro_seg7_vertex_07001B60[] = { + {{{ -379, 401, -121}, 0, { 224, 288}, {0xc5, 0x00, 0x00, 0xff}}}, + {{{ -398, 425, -118}, 0, { 192, 288}, {0xc5, 0x00, 0x00, 0xff}}}, + {{{ -566, 406, -122}, 0, { 224, 352}, {0xc5, 0x00, 0x00, 0xff}}}, + {{{ -547, 428, -120}, 0, { 192, 352}, {0xc5, 0x00, 0x00, 0xff}}}, +}; + +// 0x07001BA0 - 0x07001BE0 +static const Vtx intro_seg7_vertex_07001BA0[] = { + {{{ -524, 562, -200}, 0, { 160, 320}, {0x62, 0x00, 0x00, 0xff}}}, + {{{ -540, 534, -201}, 0, { 192, 352}, {0x62, 0x00, 0x00, 0xff}}}, + {{{ -547, 428, -120}, 0, { 192, 352}, {0x62, 0x00, 0x00, 0xff}}}, + {{{ -566, 406, -122}, 0, { 224, 352}, {0x62, 0x00, 0x00, 0xff}}}, +}; + +// 0x07001BE0 - 0x07001C10 +static const Vtx intro_seg7_vertex_07001BE0[] = { + {{{ -568, 515, -189}, 0, { 192, 352}, {0xd7, 0x00, 0x00, 0xff}}}, + {{{ -540, 534, -201}, 0, { 192, 352}, {0xd7, 0x00, 0x00, 0xff}}}, + {{{ -558, 542, -188}, 0, { 160, 352}, {0xd7, 0x00, 0x00, 0xff}}}, +}; + +// 0x07001C10 - 0x07001C40 +static const Vtx intro_seg7_vertex_07001C10[] = { + {{{ -540, 534, -201}, 0, { 192, 352}, {0xd7, 0x00, 0x00, 0xff}}}, + {{{ -524, 562, -200}, 0, { 160, 320}, {0xd7, 0x00, 0x00, 0xff}}}, + {{{ -558, 542, -188}, 0, { 160, 352}, {0xd7, 0x00, 0x00, 0xff}}}, +}; + +// 0x07001C40 - 0x07001C90 +static const Vtx intro_seg7_vertex_07001C40[] = { + {{{ -610, 638, -260}, 0, { 128, 352}, {0x93, 0x00, 0x00, 0xff}}}, + {{{ -568, 515, -189}, 0, { 192, 352}, {0x93, 0x00, 0x00, 0xff}}}, + {{{ -594, 639, -246}, 0, { 128, 352}, {0x93, 0x00, 0x00, 0xff}}}, + {{{ -558, 542, -188}, 0, { 160, 352}, {0x93, 0x00, 0x00, 0xff}}}, + {{{ -594, 639, -246}, 0, { 128, 352}, {0x93, 0x00, 0x00, 0xff}}}, +}; + +// 0x07001C90 - 0x07001CC0 +static const Vtx intro_seg7_vertex_07001C90[] = { + {{{ -500, 682, -272}, 0, { 96, 320}, {0x6b, 0x00, 0x00, 0xff}}}, + {{{ -537, 670, -281}, 0, { 96, 352}, {0x6b, 0x00, 0x00, 0xff}}}, + {{{ -594, 639, -246}, 0, { 128, 352}, {0x6b, 0x00, 0x00, 0xff}}}, +}; + +// 0x07001CC0 - 0x07001CF0 +static const Vtx intro_seg7_vertex_07001CC0[] = { + {{{ -537, 670, -281}, 0, { 96, 352}, {0xa1, 0x00, 0x00, 0xff}}}, + {{{ -500, 682, -272}, 0, { 96, 320}, {0xa1, 0x00, 0x00, 0xff}}}, + {{{ -565, 698, -282}, 0, { 96, 352}, {0xa1, 0x00, 0x00, 0xff}}}, +}; + +// 0x07001CF0 - 0x07001D20 +static const Vtx intro_seg7_vertex_07001CF0[] = { + {{{ -582, 680, -287}, 0, { 96, 352}, {0x93, 0x00, 0x00, 0xff}}}, + {{{ -537, 670, -281}, 0, { 96, 352}, {0x93, 0x00, 0x00, 0xff}}}, + {{{ -565, 698, -282}, 0, { 96, 352}, {0x93, 0x00, 0x00, 0xff}}}, +}; + +// 0x07001D20 - 0x07001D60 +static const Vtx intro_seg7_vertex_07001D20[] = { + {{{ -556, 784, -347}, 0, { 64, 352}, {0x5e, 0x00, 0x00, 0xff}}}, + {{{ -565, 698, -282}, 0, { 96, 352}, {0x5e, 0x00, 0x00, 0xff}}}, + {{{ -543, 776, -328}, 0, { 64, 320}, {0x5e, 0x00, 0x00, 0xff}}}, + {{{ -582, 680, -287}, 0, { 96, 352}, {0x5e, 0x00, 0x00, 0xff}}}, +}; + +// 0x07001D60 - 0x07001D90 +static const Vtx intro_seg7_vertex_07001D60[] = { + {{{ -537, 670, -281}, 0, { 96, 352}, {0x6b, 0x00, 0x00, 0xff}}}, + {{{ -610, 638, -260}, 0, { 128, 352}, {0x6b, 0x00, 0x00, 0xff}}}, + {{{ -594, 639, -246}, 0, { 128, 352}, {0x6b, 0x00, 0x00, 0xff}}}, +}; + +// 0x07001D90 - 0x07001DD0 +static const Vtx intro_seg7_vertex_07001D90[] = { + {{{ -488, 772, -326}, 0, { 64, 320}, {0x80, 0x00, 0x00, 0xff}}}, + {{{ -504, 781, -347}, 0, { 64, 320}, {0x80, 0x00, 0x00, 0xff}}}, + {{{ -543, 776, -328}, 0, { 64, 320}, {0x80, 0x00, 0x00, 0xff}}}, + {{{ -556, 784, -347}, 0, { 64, 352}, {0x80, 0x00, 0x00, 0xff}}}, +}; + +// 0x07001DD0 - 0x07001E10 +static const Vtx intro_seg7_vertex_07001DD0[] = { + {{{ -488, 772, -326}, 0, { 64, 320}, {0x93, 0x00, 0x00, 0xff}}}, + {{{ -499, 805, -345}, 0, { 64, 320}, {0x93, 0x00, 0x00, 0xff}}}, + {{{ -504, 781, -347}, 0, { 64, 320}, {0x93, 0x00, 0x00, 0xff}}}, + {{{ -515, 811, -362}, 0, { 64, 320}, {0x93, 0x00, 0x00, 0xff}}}, +}; + +// 0x07001E10 - 0x07001E50 +static const Vtx intro_seg7_vertex_07001E10[] = { + {{{ -387, 844, -382}, 0, { 32, 288}, {0x80, 0x00, 0x00, 0xff}}}, + {{{ -515, 811, -362}, 0, { 64, 320}, {0x80, 0x00, 0x00, 0xff}}}, + {{{ -405, 831, -361}, 0, { 64, 288}, {0x80, 0x00, 0x00, 0xff}}}, + {{{ -499, 805, -345}, 0, { 64, 320}, {0x80, 0x00, 0x00, 0xff}}}, +}; + +// 0x07001E50 - 0x07001E80 +static const Vtx intro_seg7_vertex_07001E50[] = { + {{{ -244, 715, -292}, 0, { 96, 256}, {0xa1, 0x00, 0x00, 0xff}}}, + {{{ -277, 713, -291}, 0, { 96, 256}, {0xa1, 0x00, 0x00, 0xff}}}, + {{{ -265, 690, -293}, 0, { 96, 256}, {0xa1, 0x00, 0x00, 0xff}}}, +}; + +// 0x07001E80 - 0x07001EB0 +static const Vtx intro_seg7_vertex_07001E80[] = { + {{{ -265, 690, -293}, 0, { 96, 256}, {0xd7, 0x00, 0x00, 0xff}}}, + {{{ -277, 713, -291}, 0, { 96, 256}, {0xd7, 0x00, 0x00, 0xff}}}, + {{{ -278, 677, -269}, 0, { 128, 256}, {0xd7, 0x00, 0x00, 0xff}}}, +}; + +// 0x07001EB0 - 0x07001EE0 +static const Vtx intro_seg7_vertex_07001EB0[] = { + {{{ -265, 690, -293}, 0, { 96, 256}, {0x99, 0x00, 0x00, 0xff}}}, + {{{ -278, 677, -269}, 0, { 128, 256}, {0x99, 0x00, 0x00, 0xff}}}, + {{{ -249, 681, -271}, 0, { 128, 256}, {0x99, 0x00, 0x00, 0xff}}}, +}; + +// 0x07001EE0 - 0x07001F10 +static const Vtx intro_seg7_vertex_07001EE0[] = { + {{{ -265, 690, -293}, 0, { 96, 256}, {0x5e, 0x00, 0x00, 0xff}}}, + {{{ -249, 681, -271}, 0, { 128, 256}, {0x5e, 0x00, 0x00, 0xff}}}, + {{{ -244, 715, -292}, 0, { 96, 256}, {0x5e, 0x00, 0x00, 0xff}}}, +}; + +// 0x07001F10 - 0x07001F40 +static const Vtx intro_seg7_vertex_07001F10[] = { + {{{ -97, 717, -293}, 0, { 96, 224}, {0xa1, 0x00, 0x00, 0xff}}}, + {{{ -138, 714, -291}, 0, { 96, 224}, {0xa1, 0x00, 0x00, 0xff}}}, + {{{ -116, 688, -292}, 0, { 96, 224}, {0xa1, 0x00, 0x00, 0xff}}}, +}; + +// 0x07001F40 - 0x07001F70 +static const Vtx intro_seg7_vertex_07001F40[] = { + {{{ -116, 688, -292}, 0, { 96, 224}, {0xd7, 0x00, 0x00, 0xff}}}, + {{{ -138, 714, -291}, 0, { 96, 224}, {0xd7, 0x00, 0x00, 0xff}}}, + {{{ -139, 675, -268}, 0, { 128, 224}, {0xd7, 0x00, 0x00, 0xff}}}, +}; + +// 0x07001F70 - 0x07001FA0 +static const Vtx intro_seg7_vertex_07001F70[] = { + {{{ -116, 688, -292}, 0, { 96, 224}, {0x99, 0x00, 0x00, 0xff}}}, + {{{ -139, 675, -268}, 0, { 128, 224}, {0x99, 0x00, 0x00, 0xff}}}, + {{{ -90, 677, -269}, 0, { 128, 224}, {0x99, 0x00, 0x00, 0xff}}}, +}; + +// 0x07001FA0 - 0x07001FD0 +static const Vtx intro_seg7_vertex_07001FA0[] = { + {{{ -116, 688, -292}, 0, { 96, 224}, {0x5e, 0x00, 0x00, 0xff}}}, + {{{ -90, 677, -269}, 0, { 128, 224}, {0x5e, 0x00, 0x00, 0xff}}}, + {{{ -97, 717, -293}, 0, { 96, 224}, {0x5e, 0x00, 0x00, 0xff}}}, +}; + +// 0x07001FD0 - 0x07002000 +static const Vtx intro_seg7_vertex_07001FD0[] = { + {{{ -244, 617, -233}, 0, { 128, 256}, {0xa1, 0x00, 0x00, 0xff}}}, + {{{ -279, 621, -235}, 0, { 128, 256}, {0xa1, 0x00, 0x00, 0xff}}}, + {{{ -259, 598, -239}, 0, { 128, 256}, {0xa1, 0x00, 0x00, 0xff}}}, +}; + +// 0x07002000 - 0x07002030 +static const Vtx intro_seg7_vertex_07002000[] = { + {{{ -259, 598, -239}, 0, { 128, 256}, {0xd7, 0x00, 0x00, 0xff}}}, + {{{ -279, 621, -235}, 0, { 128, 256}, {0xd7, 0x00, 0x00, 0xff}}}, + {{{ -285, 581, -211}, 0, { 160, 256}, {0xd7, 0x00, 0x00, 0xff}}}, +}; + +// 0x07002030 - 0x07002060 +static const Vtx intro_seg7_vertex_07002030[] = { + {{{ -259, 598, -239}, 0, { 128, 256}, {0x99, 0x00, 0x00, 0xff}}}, + {{{ -285, 581, -211}, 0, { 160, 256}, {0x99, 0x00, 0x00, 0xff}}}, + {{{ -246, 581, -211}, 0, { 160, 256}, {0x99, 0x00, 0x00, 0xff}}}, +}; + +// 0x07002060 - 0x07002090 +static const Vtx intro_seg7_vertex_07002060[] = { + {{{ -259, 598, -239}, 0, { 128, 256}, {0x5e, 0x00, 0x00, 0xff}}}, + {{{ -246, 581, -211}, 0, { 160, 256}, {0x5e, 0x00, 0x00, 0xff}}}, + {{{ -244, 617, -233}, 0, { 128, 256}, {0x5e, 0x00, 0x00, 0xff}}}, +}; + +// 0x07002090 - 0x070020C0 +static const Vtx intro_seg7_vertex_07002090[] = { + {{{ -89, 627, -239}, 0, { 128, 224}, {0xa1, 0x00, 0x00, 0xff}}}, + {{{ -133, 623, -237}, 0, { 128, 224}, {0xa1, 0x00, 0x00, 0xff}}}, + {{{ -113, 595, -237}, 0, { 160, 224}, {0xa1, 0x00, 0x00, 0xff}}}, +}; + +// 0x070020C0 - 0x070020F0 +static const Vtx intro_seg7_vertex_070020C0[] = { + {{{ -113, 595, -237}, 0, { 160, 224}, {0xd7, 0x00, 0x00, 0xff}}}, + {{{ -133, 623, -237}, 0, { 128, 224}, {0xd7, 0x00, 0x00, 0xff}}}, + {{{ -136, 581, -212}, 0, { 160, 224}, {0xd7, 0x00, 0x00, 0xff}}}, +}; + +// 0x070020F0 - 0x07002120 +static const Vtx intro_seg7_vertex_070020F0[] = { + {{{ -113, 595, -237}, 0, { 160, 224}, {0x99, 0x00, 0x00, 0xff}}}, + {{{ -136, 581, -212}, 0, { 160, 224}, {0x99, 0x00, 0x00, 0xff}}}, + {{{ -93, 581, -212}, 0, { 160, 224}, {0x99, 0x00, 0x00, 0xff}}}, +}; + +// 0x07002120 - 0x07002150 +static const Vtx intro_seg7_vertex_07002120[] = { + {{{ -113, 595, -237}, 0, { 160, 224}, {0x5e, 0x00, 0x00, 0xff}}}, + {{{ -93, 581, -212}, 0, { 160, 224}, {0x5e, 0x00, 0x00, 0xff}}}, + {{{ -89, 627, -239}, 0, { 128, 224}, {0x5e, 0x00, 0x00, 0xff}}}, +}; + +// 0x07002150 - 0x07002240 +static const Vtx intro_seg7_vertex_07002150[] = { + {{{ -558, 542, -188}, 0, { 160, 352}, {0xff, 0x2f, 0x2f, 0xff}}}, + {{{ -524, 562, -200}, 0, { 160, 320}, {0xff, 0x2f, 0x2f, 0xff}}}, + {{{ -594, 639, -246}, 0, { 128, 352}, {0xff, 0x2f, 0x2f, 0xff}}}, + {{{ -500, 682, -272}, 0, { 96, 320}, {0xff, 0x2f, 0x2f, 0xff}}}, + {{{ -547, 428, -120}, 0, { 192, 352}, {0xff, 0x2f, 0x2f, 0xff}}}, + {{{ -398, 425, -118}, 0, { 192, 288}, {0xff, 0x2f, 0x2f, 0xff}}}, + {{{ -400, 564, -201}, 0, { 160, 288}, {0xff, 0x2f, 0x2f, 0xff}}}, + {{{ -565, 698, -282}, 0, { 96, 352}, {0xff, 0x2f, 0x2f, 0xff}}}, + {{{ -543, 776, -328}, 0, { 64, 320}, {0xff, 0x2f, 0x2f, 0xff}}}, + {{{ -488, 772, -326}, 0, { 64, 320}, {0xff, 0x2f, 0x2f, 0xff}}}, + {{{ -385, 770, -324}, 0, { 64, 288}, {0xff, 0x2f, 0x2f, 0xff}}}, + {{{ -357, 701, -283}, 0, { 96, 288}, {0xff, 0x2f, 0x2f, 0xff}}}, + {{{ -381, 648, -252}, 0, { 128, 288}, {0xff, 0x2f, 0x2f, 0xff}}}, + {{{ -346, 623, -236}, 0, { 128, 288}, {0xff, 0x2f, 0x2f, 0xff}}}, + {{{ -378, 557, -197}, 0, { 160, 288}, {0xff, 0x2f, 0x2f, 0xff}}}, +}; + +// 0x07002240 - 0x07002340 +static const Vtx intro_seg7_vertex_07002240[] = { + {{{ -405, 831, -361}, 0, { 64, 288}, {0xff, 0x2f, 0x2f, 0xff}}}, + {{{ -499, 805, -345}, 0, { 64, 320}, {0xff, 0x2f, 0x2f, 0xff}}}, + {{{ -385, 770, -324}, 0, { 64, 288}, {0xff, 0x2f, 0x2f, 0xff}}}, + {{{ -488, 772, -326}, 0, { 64, 320}, {0xff, 0x2f, 0x2f, 0xff}}}, + {{{ -352, 768, -323}, 0, { 64, 288}, {0xff, 0x2f, 0x2f, 0xff}}}, + {{{ -357, 701, -283}, 0, { 96, 288}, {0xff, 0x2f, 0x2f, 0xff}}}, + {{{ -130, 832, -361}, 0, { 64, 224}, {0xff, 0x2f, 0x2f, 0xff}}}, + {{{ -236, 830, -360}, 0, { 64, 256}, {0xff, 0x2f, 0x2f, 0xff}}}, + {{{ -132, 769, -324}, 0, { 96, 224}, {0xff, 0x2f, 0x2f, 0xff}}}, + {{{ -244, 775, -327}, 0, { 64, 256}, {0xff, 0x2f, 0x2f, 0xff}}}, + {{{ -34, 766, -322}, 0, { 96, 192}, {0xff, 0x2f, 0x2f, 0xff}}}, + {{{ -97, 717, -293}, 0, { 96, 224}, {0xff, 0x2f, 0x2f, 0xff}}}, + {{{ -138, 714, -291}, 0, { 96, 224}, {0xff, 0x2f, 0x2f, 0xff}}}, + {{{ -336, 775, -327}, 0, { 64, 288}, {0xff, 0x2f, 0x2f, 0xff}}}, + {{{ -346, 623, -236}, 0, { 128, 288}, {0xff, 0x2f, 0x2f, 0xff}}}, + {{{ -277, 713, -291}, 0, { 96, 256}, {0xff, 0x2f, 0x2f, 0xff}}}, +}; + +// 0x07002340 - 0x07002420 +static const Vtx intro_seg7_vertex_07002340[] = { + {{{ -277, 713, -291}, 0, { 96, 256}, {0xff, 0x2f, 0x2f, 0xff}}}, + {{{ -244, 715, -292}, 0, { 96, 256}, {0xff, 0x2f, 0x2f, 0xff}}}, + {{{ -244, 775, -327}, 0, { 64, 256}, {0xff, 0x2f, 0x2f, 0xff}}}, + {{{ -138, 714, -291}, 0, { 96, 224}, {0xff, 0x2f, 0x2f, 0xff}}}, + {{{ -351, 524, -177}, 0, { 160, 288}, {0xff, 0x2f, 0x2f, 0xff}}}, + {{{ -252, 521, -176}, 0, { 160, 256}, {0xff, 0x2f, 0x2f, 0xff}}}, + {{{ -348, 585, -214}, 0, { 160, 288}, {0xff, 0x2f, 0x2f, 0xff}}}, + {{{ -255, 416, -113}, 0, { 224, 256}, {0xff, 0x2f, 0x2f, 0xff}}}, + {{{ -121, 515, -172}, 0, { 160, 224}, {0xff, 0x2f, 0x2f, 0xff}}}, + {{{ -136, 581, -212}, 0, { 160, 224}, {0xff, 0x2f, 0x2f, 0xff}}}, + {{{ -285, 581, -211}, 0, { 160, 256}, {0xff, 0x2f, 0x2f, 0xff}}}, + {{{ -246, 581, -211}, 0, { 160, 256}, {0xff, 0x2f, 0x2f, 0xff}}}, + {{{ -378, 557, -197}, 0, { 160, 288}, {0xff, 0x2f, 0x2f, 0xff}}}, + {{{ -346, 623, -236}, 0, { 128, 288}, {0xff, 0x2f, 0x2f, 0xff}}}, +}; + +// 0x07002420 - 0x07002520 +static const Vtx intro_seg7_vertex_07002420[] = { + {{{ -122, 413, -111}, 0, { 224, 224}, {0xff, 0x2f, 0x2f, 0xff}}}, + {{{ -121, 515, -172}, 0, { 160, 224}, {0xff, 0x2f, 0x2f, 0xff}}}, + {{{ -255, 416, -113}, 0, { 224, 256}, {0xff, 0x2f, 0x2f, 0xff}}}, + {{{ -26, 518, -174}, 0, { 160, 224}, {0xff, 0x2f, 0x2f, 0xff}}}, + {{{ -93, 581, -212}, 0, { 160, 224}, {0xff, 0x2f, 0x2f, 0xff}}}, + {{{ -136, 581, -212}, 0, { 160, 224}, {0xff, 0x2f, 0x2f, 0xff}}}, + {{{ -34, 766, -322}, 0, { 96, 192}, {0xff, 0x2f, 0x2f, 0xff}}}, + {{{ -89, 627, -239}, 0, { 128, 224}, {0xff, 0x2f, 0x2f, 0xff}}}, + {{{ -90, 677, -269}, 0, { 128, 224}, {0xff, 0x2f, 0x2f, 0xff}}}, + {{{ -97, 717, -293}, 0, { 96, 224}, {0xff, 0x2f, 0x2f, 0xff}}}, + {{{ -133, 623, -237}, 0, { 128, 224}, {0xff, 0x2f, 0x2f, 0xff}}}, + {{{ -246, 581, -211}, 0, { 160, 256}, {0xff, 0x2f, 0x2f, 0xff}}}, + {{{ -244, 617, -233}, 0, { 128, 256}, {0xff, 0x2f, 0x2f, 0xff}}}, + {{{ -138, 714, -291}, 0, { 96, 224}, {0xff, 0x2f, 0x2f, 0xff}}}, + {{{ -244, 715, -292}, 0, { 96, 256}, {0xff, 0x2f, 0x2f, 0xff}}}, + {{{ -139, 675, -268}, 0, { 128, 224}, {0xff, 0x2f, 0x2f, 0xff}}}, +}; + +// 0x07002520 - 0x070025D0 +static const Vtx intro_seg7_vertex_07002520[] = { + {{{ -277, 713, -291}, 0, { 96, 256}, {0xff, 0x2f, 0x2f, 0xff}}}, + {{{ -346, 623, -236}, 0, { 128, 288}, {0xff, 0x2f, 0x2f, 0xff}}}, + {{{ -278, 677, -269}, 0, { 128, 256}, {0xff, 0x2f, 0x2f, 0xff}}}, + {{{ -285, 581, -211}, 0, { 160, 256}, {0xff, 0x2f, 0x2f, 0xff}}}, + {{{ -279, 621, -235}, 0, { 128, 256}, {0xff, 0x2f, 0x2f, 0xff}}}, + {{{ -244, 617, -233}, 0, { 128, 256}, {0xff, 0x2f, 0x2f, 0xff}}}, + {{{ -249, 681, -271}, 0, { 128, 256}, {0xff, 0x2f, 0x2f, 0xff}}}, + {{{ -244, 715, -292}, 0, { 96, 256}, {0xff, 0x2f, 0x2f, 0xff}}}, + {{{ -139, 675, -268}, 0, { 128, 224}, {0xff, 0x2f, 0x2f, 0xff}}}, + {{{ -133, 623, -237}, 0, { 128, 224}, {0xff, 0x2f, 0x2f, 0xff}}}, + {{{ -90, 677, -269}, 0, { 128, 224}, {0xff, 0x2f, 0x2f, 0xff}}}, +}; + +// 0x070025D0 - 0x07002610 +static const Vtx intro_seg7_vertex_070025D0[] = { + {{{ 658, 317, -73}, 0, { 256, 64}, {0x6a, 0x6a, 0x00, 0xff}}}, + {{{ 669, 311, -50}, 0, { 256, 32}, {0x6a, 0x6a, 0x00, 0xff}}}, + {{{ 806, 317, -73}, 0, { 256, 0}, {0x6a, 0x6a, 0x00, 0xff}}}, + {{{ 777, 309, -49}, 0, { 256, 32}, {0x6a, 0x6a, 0x00, 0xff}}}, +}; + +// 0x07002610 - 0x07002650 +static const Vtx intro_seg7_vertex_07002610[] = { + {{{ 760, 257, -17}, 0, { 288, 32}, {0xb1, 0xb1, 0x00, 0xff}}}, + {{{ 790, 270, -45}, 0, { 256, 0}, {0xb1, 0xb1, 0x00, 0xff}}}, + {{{ 777, 309, -49}, 0, { 256, 32}, {0xb1, 0xb1, 0x00, 0xff}}}, + {{{ 806, 317, -73}, 0, { 256, 0}, {0xb1, 0xb1, 0x00, 0xff}}}, +}; + +// 0x07002650 - 0x07002690 +static const Vtx intro_seg7_vertex_07002650[] = { + {{{ 760, 257, -17}, 0, { 288, 32}, {0x6a, 0x6a, 0x00, 0xff}}}, + {{{ 901, 264, -22}, 0, { 288, 0}, {0x6a, 0x6a, 0x00, 0xff}}}, + {{{ 790, 270, -45}, 0, { 256, 0}, {0x6a, 0x6a, 0x00, 0xff}}}, + {{{ 930, 277, -49}, 0, { 256, 0}, {0x6a, 0x6a, 0x00, 0xff}}}, +}; + +// 0x07002690 - 0x070026D0 +static const Vtx intro_seg7_vertex_07002690[] = { + {{{ 887, 92, 62}, 0, { 352, 0}, {0xb1, 0xb1, 0x00, 0xff}}}, + {{{ 930, 277, -49}, 0, { 256, 0}, {0xb1, 0xb1, 0x00, 0xff}}}, + {{{ 871, 123, 62}, 0, { 320, 0}, {0xb1, 0xb1, 0x00, 0xff}}}, + {{{ 901, 264, -22}, 0, { 288, 0}, {0xb1, 0xb1, 0x00, 0xff}}}, +}; + +// 0x070026D0 - 0x07002710 +static const Vtx intro_seg7_vertex_070026D0[] = { + {{{ 887, 92, 62}, 0, { 352, 0}, {0xa1, 0xa1, 0x00, 0xff}}}, + {{{ 871, 123, 62}, 0, { 320, 0}, {0xa1, 0xa1, 0x00, 0xff}}}, + {{{ 786, 118, 44}, 0, { 352, 0}, {0xa1, 0xa1, 0x00, 0xff}}}, + {{{ 779, 149, 46}, 0, { 320, 32}, {0xa1, 0xa1, 0x00, 0xff}}}, +}; + +// 0x07002710 - 0x07002740 +static const Vtx intro_seg7_vertex_07002710[] = { + {{{ 769, 144, 49}, 0, { 320, 32}, {0xa1, 0xa1, 0x00, 0xff}}}, + {{{ 786, 118, 44}, 0, { 352, 0}, {0xa1, 0xa1, 0x00, 0xff}}}, + {{{ 779, 149, 46}, 0, { 320, 32}, {0xa1, 0xa1, 0x00, 0xff}}}, +}; + +// 0x07002740 - 0x07002770 +static const Vtx intro_seg7_vertex_07002740[] = { + {{{ 769, 144, 49}, 0, { 320, 32}, {0xb1, 0xb1, 0x00, 0xff}}}, + {{{ 779, 149, 46}, 0, { 320, 32}, {0xb1, 0xb1, 0x00, 0xff}}}, + {{{ 774, 159, 40}, 0, { 320, 32}, {0xb1, 0xb1, 0x00, 0xff}}}, +}; + +// 0x07002770 - 0x070027A0 +static const Vtx intro_seg7_vertex_07002770[] = { + {{{ 761, 188, 23}, 0, { 320, 32}, {0xa1, 0xa1, 0x00, 0xff}}}, + {{{ 698, 171, 33}, 0, { 320, 32}, {0xa1, 0xa1, 0x00, 0xff}}}, + {{{ 750, 162, 24}, 0, { 320, 32}, {0xa1, 0xa1, 0x00, 0xff}}}, +}; + +// 0x070027A0 - 0x070027D0 +static const Vtx intro_seg7_vertex_070027A0[] = { + {{{ 709, 150, 31}, 0, { 320, 32}, {0xa1, 0xa1, 0x00, 0xff}}}, + {{{ 750, 162, 24}, 0, { 320, 32}, {0xa1, 0xa1, 0x00, 0xff}}}, + {{{ 698, 171, 33}, 0, { 320, 32}, {0xa1, 0xa1, 0x00, 0xff}}}, +}; + +// 0x070027D0 - 0x07002800 +static const Vtx intro_seg7_vertex_070027D0[] = { + {{{ 709, 150, 31}, 0, { 320, 32}, {0xb1, 0xb1, 0x00, 0xff}}}, + {{{ 698, 171, 33}, 0, { 320, 32}, {0xb1, 0xb1, 0x00, 0xff}}}, + {{{ 649, 126, 60}, 0, { 320, 64}, {0xb1, 0xb1, 0x00, 0xff}}}, +}; + +// 0x07002800 - 0x07002830 +static const Vtx intro_seg7_vertex_07002800[] = { + {{{ 750, 162, 24}, 0, { 320, 32}, {0xa1, 0xa1, 0x00, 0xff}}}, + {{{ 774, 159, 40}, 0, { 320, 32}, {0xa1, 0xa1, 0x00, 0xff}}}, + {{{ 761, 188, 23}, 0, { 320, 32}, {0xa1, 0xa1, 0x00, 0xff}}}, +}; + +// 0x07002830 - 0x07002860 +static const Vtx intro_seg7_vertex_07002830[] = { + {{{ 649, 126, 60}, 0, { 320, 64}, {0x6a, 0x6a, 0x00, 0xff}}}, + {{{ 658, 122, 62}, 0, { 320, 64}, {0x6a, 0x6a, 0x00, 0xff}}}, + {{{ 709, 150, 31}, 0, { 320, 32}, {0x6a, 0x6a, 0x00, 0xff}}}, +}; + +// 0x07002860 - 0x07002890 +static const Vtx intro_seg7_vertex_07002860[] = { + {{{ 658, 122, 62}, 0, { 320, 64}, {0x6a, 0x6a, 0x00, 0xff}}}, + {{{ 769, 156, 42}, 0, { 320, 32}, {0x6a, 0x6a, 0x00, 0xff}}}, + {{{ 709, 150, 31}, 0, { 320, 32}, {0x6a, 0x6a, 0x00, 0xff}}}, +}; + +// 0x07002890 - 0x070028C0 +static const Vtx intro_seg7_vertex_07002890[] = { + {{{ 709, 150, 31}, 0, { 320, 32}, {0x6a, 0x6a, 0x00, 0xff}}}, + {{{ 769, 156, 42}, 0, { 320, 32}, {0x6a, 0x6a, 0x00, 0xff}}}, + {{{ 750, 162, 24}, 0, { 320, 32}, {0x6a, 0x6a, 0x00, 0xff}}}, +}; + +// 0x070028C0 - 0x070028F0 +static const Vtx intro_seg7_vertex_070028C0[] = { + {{{ 750, 162, 24}, 0, { 320, 32}, {0x6a, 0x6a, 0x00, 0xff}}}, + {{{ 769, 156, 42}, 0, { 320, 32}, {0x6a, 0x6a, 0x00, 0xff}}}, + {{{ 774, 159, 40}, 0, { 320, 32}, {0x6a, 0x6a, 0x00, 0xff}}}, +}; + +// 0x070028F0 - 0x07002920 +static const Vtx intro_seg7_vertex_070028F0[] = { + {{{ 774, 159, 40}, 0, { 320, 32}, {0xb1, 0xb1, 0x00, 0xff}}}, + {{{ 769, 156, 42}, 0, { 320, 32}, {0xb1, 0xb1, 0x00, 0xff}}}, + {{{ 769, 144, 49}, 0, { 320, 32}, {0xb1, 0xb1, 0x00, 0xff}}}, +}; + +// 0x07002920 - 0x07002950 +static const Vtx intro_seg7_vertex_07002920[] = { + {{{ 769, 156, 42}, 0, { 320, 32}, {0x6a, 0x6a, 0x00, 0xff}}}, + {{{ 658, 122, 62}, 0, { 320, 64}, {0x6a, 0x6a, 0x00, 0xff}}}, + {{{ 769, 144, 49}, 0, { 320, 32}, {0x6a, 0x6a, 0x00, 0xff}}}, +}; + +// 0x07002950 - 0x07002980 +static const Vtx intro_seg7_vertex_07002950[] = { + {{{ 629, 69, 80}, 0, { 352, 64}, {0x43, 0x43, 0x00, 0xff}}}, + {{{ 621, 100, 75}, 0, { 352, 64}, {0x43, 0x43, 0x00, 0xff}}}, + {{{ 611, 67, 74}, 0, { 352, 64}, {0x43, 0x43, 0x00, 0xff}}}, +}; + +// 0x07002980 - 0x070029B0 +static const Vtx intro_seg7_vertex_07002980[] = { + {{{ 629, 69, 80}, 0, { 352, 64}, {0xb1, 0xb1, 0x00, 0xff}}}, + {{{ 649, 126, 60}, 0, { 320, 64}, {0xb1, 0xb1, 0x00, 0xff}}}, + {{{ 621, 100, 75}, 0, { 352, 64}, {0xb1, 0xb1, 0x00, 0xff}}}, +}; + +// 0x070029B0 - 0x070029E0 +static const Vtx intro_seg7_vertex_070029B0[] = { + {{{ 625, 27, 119}, 0, { 352, 64}, {0x43, 0x43, 0x00, 0xff}}}, + {{{ 629, 69, 80}, 0, { 352, 64}, {0x43, 0x43, 0x00, 0xff}}}, + {{{ 610, 30, 96}, 0, { 352, 64}, {0x43, 0x43, 0x00, 0xff}}}, +}; + +// 0x070029E0 - 0x07002A10 +static const Vtx intro_seg7_vertex_070029E0[] = { + {{{ 610, 30, 96}, 0, { 352, 64}, {0x43, 0x43, 0x00, 0xff}}}, + {{{ 629, 69, 80}, 0, { 352, 64}, {0x43, 0x43, 0x00, 0xff}}}, + {{{ 611, 67, 74}, 0, { 352, 64}, {0x43, 0x43, 0x00, 0xff}}}, +}; + +// 0x07002A10 - 0x07002A40 +static const Vtx intro_seg7_vertex_07002A10[] = { + {{{ 649, 126, 60}, 0, { 320, 64}, {0xb1, 0xb1, 0x00, 0xff}}}, + {{{ 629, 69, 80}, 0, { 352, 64}, {0xb1, 0xb1, 0x00, 0xff}}}, + {{{ 658, 122, 62}, 0, { 320, 64}, {0xb1, 0xb1, 0x00, 0xff}}}, +}; + +// 0x07002A40 - 0x07002A70 +static const Vtx intro_seg7_vertex_07002A40[] = { + {{{ 629, 69, 80}, 0, { 352, 64}, {0xba, 0xba, 0x00, 0xff}}}, + {{{ 625, 27, 119}, 0, { 352, 64}, {0xba, 0xba, 0x00, 0xff}}}, + {{{ 658, 122, 62}, 0, { 320, 64}, {0xba, 0xba, 0x00, 0xff}}}, +}; + +// 0x07002A70 - 0x07002AB0 +static const Vtx intro_seg7_vertex_07002A70[] = { + {{{ 482, -98, 173}, 0, { 416, 96}, {0x43, 0x43, 0x00, 0xff}}}, + {{{ 515, -83, 185}, 0, { 416, 96}, {0x43, 0x43, 0x00, 0xff}}}, + {{{ 610, 30, 96}, 0, { 352, 64}, {0x43, 0x43, 0x00, 0xff}}}, + {{{ 625, 27, 119}, 0, { 352, 64}, {0x43, 0x43, 0x00, 0xff}}}, +}; + +// 0x07002AB0 - 0x07002AF0 +static const Vtx intro_seg7_vertex_07002AB0[] = { + {{{ 541, 186, 5}, 0, { 288, 96}, {0x78, 0x78, 0x00, 0xff}}}, + {{{ 611, 67, 74}, 0, { 352, 64}, {0x78, 0x78, 0x00, 0xff}}}, + {{{ 566, 193, 20}, 0, { 288, 64}, {0x78, 0x78, 0x00, 0xff}}}, + {{{ 621, 100, 75}, 0, { 352, 64}, {0x78, 0x78, 0x00, 0xff}}}, +}; + +// 0x07002AF0 - 0x07002B30 +static const Vtx intro_seg7_vertex_07002AF0[] = { + {{{ 541, 186, 5}, 0, { 288, 96}, {0x43, 0x43, 0x00, 0xff}}}, + {{{ 566, 193, 20}, 0, { 288, 64}, {0x43, 0x43, 0x00, 0xff}}}, + {{{ 628, 246, -11}, 0, { 288, 64}, {0x43, 0x43, 0x00, 0xff}}}, + {{{ 619, 247, -31}, 0, { 288, 64}, {0x43, 0x43, 0x00, 0xff}}}, +}; + +// 0x07002B30 - 0x07002B70 +static const Vtx intro_seg7_vertex_07002B30[] = { + {{{ 619, 247, -31}, 0, { 288, 64}, {0x43, 0x43, 0x00, 0xff}}}, + {{{ 628, 246, -11}, 0, { 288, 64}, {0x43, 0x43, 0x00, 0xff}}}, + {{{ 658, 317, -73}, 0, { 256, 64}, {0x43, 0x43, 0x00, 0xff}}}, + {{{ 669, 311, -50}, 0, { 256, 32}, {0x43, 0x43, 0x00, 0xff}}}, +}; + +// 0x07002B70 - 0x07002BB0 +static const Vtx intro_seg7_vertex_07002B70[] = { + {{{ 482, -98, 173}, 0, { 416, 96}, {0x6b, 0x6b, 0x00, 0xff}}}, + {{{ 619, -170, 215}, 0, { 448, 64}, {0x6b, 0x6b, 0x00, 0xff}}}, + {{{ 515, -83, 185}, 0, { 416, 96}, {0x6b, 0x6b, 0x00, 0xff}}}, + {{{ 615, -133, 215}, 0, { 416, 64}, {0x6b, 0x6b, 0x00, 0xff}}}, +}; + +// 0x07002BB0 - 0x07002BF0 +static const Vtx intro_seg7_vertex_07002BB0[] = { + {{{ 668, -97, 172}, 0, { 416, 64}, {0xba, 0xba, 0x00, 0xff}}}, + {{{ 615, -133, 215}, 0, { 416, 64}, {0xba, 0xba, 0x00, 0xff}}}, + {{{ 619, -170, 215}, 0, { 448, 64}, {0xba, 0xba, 0x00, 0xff}}}, + {{{ 667, -61, 172}, 0, { 384, 64}, {0xba, 0xba, 0x00, 0xff}}}, +}; + +// 0x07002BF0 - 0x07002C30 +static const Vtx intro_seg7_vertex_07002BF0[] = { + {{{ 667, -61, 172}, 0, { 384, 64}, {0x6b, 0x6b, 0x00, 0xff}}}, + {{{ 668, -97, 172}, 0, { 416, 64}, {0x6b, 0x6b, 0x00, 0xff}}}, + {{{ 812, -164, 234}, 0, { 448, 32}, {0x6b, 0x6b, 0x00, 0xff}}}, + {{{ 810, -196, 234}, 0, { 448, 32}, {0x6b, 0x6b, 0x00, 0xff}}}, +}; + +// 0x07002C30 - 0x07002C70 +static const Vtx intro_seg7_vertex_07002C30[] = { + {{{ 994, -64, 156}, 0, { 416, 0}, {0xba, 0xba, 0x00, 0xff}}}, + {{{ 954, -62, 173}, 0, { 416, 0}, {0xba, 0xba, 0x00, 0xff}}}, + {{{ 810, -196, 234}, 0, { 448, 32}, {0xba, 0xba, 0x00, 0xff}}}, + {{{ 812, -164, 234}, 0, { 448, 32}, {0xba, 0xba, 0x00, 0xff}}}, +}; + +// 0x07002C70 - 0x07002CB0 +static const Vtx intro_seg7_vertex_07002C70[] = { + {{{ 994, -64, 156}, 0, { 416, 0}, {0x81, 0x81, 0x00, 0xff}}}, + {{{ 789, 26, 98}, 0, { 352, 32}, {0x81, 0x81, 0x00, 0xff}}}, + {{{ 954, -62, 173}, 0, { 416, 0}, {0x81, 0x81, 0x00, 0xff}}}, + {{{ 768, 21, 123}, 0, { 384, 32}, {0x81, 0x81, 0x00, 0xff}}}, +}; + +// 0x07002CB0 - 0x07002CF0 +static const Vtx intro_seg7_vertex_07002CB0[] = { + {{{ 769, 144, 49}, 0, { 320, 32}, {0xb1, 0xb1, 0x00, 0xff}}}, + {{{ 768, 21, 123}, 0, { 384, 32}, {0xb1, 0xb1, 0x00, 0xff}}}, + {{{ 786, 118, 44}, 0, { 352, 0}, {0xb1, 0xb1, 0x00, 0xff}}}, + {{{ 789, 26, 98}, 0, { 352, 32}, {0xb1, 0xb1, 0x00, 0xff}}}, +}; + +// 0x07002CF0 - 0x07002DC0 +static const Vtx intro_seg7_vertex_07002CF0[] = { + {{{ 621, 100, 75}, 0, { 352, 64}, {0xff, 0xff, 0x39, 0xff}}}, + {{{ 649, 126, 60}, 0, { 320, 64}, {0xff, 0xff, 0x39, 0xff}}}, + {{{ 566, 193, 20}, 0, { 288, 64}, {0xff, 0xff, 0x39, 0xff}}}, + {{{ 698, 171, 33}, 0, { 320, 32}, {0xff, 0xff, 0x39, 0xff}}}, + {{{ 628, 246, -11}, 0, { 288, 64}, {0xff, 0xff, 0x39, 0xff}}}, + {{{ 777, 309, -49}, 0, { 256, 32}, {0xff, 0xff, 0x39, 0xff}}}, + {{{ 669, 311, -50}, 0, { 256, 32}, {0xff, 0xff, 0x39, 0xff}}}, + {{{ 760, 257, -17}, 0, { 288, 32}, {0xff, 0xff, 0x39, 0xff}}}, + {{{ 901, 264, -22}, 0, { 288, 0}, {0xff, 0xff, 0x39, 0xff}}}, + {{{ 871, 123, 62}, 0, { 320, 0}, {0xff, 0xff, 0x39, 0xff}}}, + {{{ 779, 149, 46}, 0, { 320, 32}, {0xff, 0xff, 0x39, 0xff}}}, + {{{ 774, 159, 40}, 0, { 320, 32}, {0xff, 0xff, 0x39, 0xff}}}, + {{{ 761, 188, 23}, 0, { 320, 32}, {0xff, 0xff, 0x39, 0xff}}}, +}; + +// 0x07002DC0 - 0x07002E50 +static const Vtx intro_seg7_vertex_07002DC0[] = { + {{{ 954, -62, 173}, 0, { 416, 0}, {0xff, 0xff, 0x39, 0xff}}}, + {{{ 768, 21, 123}, 0, { 384, 32}, {0xff, 0xff, 0x39, 0xff}}}, + {{{ 812, -164, 234}, 0, { 448, 32}, {0xff, 0xff, 0x39, 0xff}}}, + {{{ 667, -61, 172}, 0, { 384, 64}, {0xff, 0xff, 0x39, 0xff}}}, + {{{ 769, 144, 49}, 0, { 320, 32}, {0xff, 0xff, 0x39, 0xff}}}, + {{{ 658, 122, 62}, 0, { 320, 64}, {0xff, 0xff, 0x39, 0xff}}}, + {{{ 625, 27, 119}, 0, { 352, 64}, {0xff, 0xff, 0x39, 0xff}}}, + {{{ 515, -83, 185}, 0, { 416, 96}, {0xff, 0xff, 0x39, 0xff}}}, + {{{ 615, -133, 215}, 0, { 416, 64}, {0xff, 0xff, 0x39, 0xff}}}, +}; + +// 0x07002E50 - 0x07002E90 +static const Vtx intro_seg7_vertex_07002E50[] = { + {{{ 494, 73, 70}, 0, { 352, 96}, {0xba, 0xba, 0x00, 0xff}}}, + {{{ 552, 151, 28}, 0, { 320, 64}, {0xba, 0xba, 0x00, 0xff}}}, + {{{ 480, 81, 86}, 0, { 352, 96}, {0xba, 0xba, 0x00, 0xff}}}, + {{{ 525, 152, 44}, 0, { 320, 96}, {0xba, 0xba, 0x00, 0xff}}}, +}; + +// 0x07002E90 - 0x07002ED0 +static const Vtx intro_seg7_vertex_07002E90[] = { + {{{ 494, 73, 70}, 0, { 352, 96}, {0xb1, 0xb1, 0x00, 0xff}}}, + {{{ 480, 81, 86}, 0, { 352, 96}, {0xb1, 0xb1, 0x00, 0xff}}}, + {{{ 545, -8, 124}, 0, { 384, 64}, {0xb1, 0xb1, 0x00, 0xff}}}, + {{{ 520, 7, 131}, 0, { 384, 96}, {0xb1, 0xb1, 0x00, 0xff}}}, +}; + +// 0x07002ED0 - 0x07002F00 +static const Vtx intro_seg7_vertex_07002ED0[] = { + {{{ 449, 179, 28}, 0, { 320, 96}, {0x8b, 0x8b, 0x00, 0xff}}}, + {{{ 525, 152, 44}, 0, { 320, 96}, {0x8b, 0x8b, 0x00, 0xff}}}, + {{{ 522, 162, 18}, 0, { 320, 64}, {0x8b, 0x8b, 0x00, 0xff}}}, +}; + +// 0x07002F00 - 0x07002F30 +static const Vtx intro_seg7_vertex_07002F00[] = { + {{{ 552, 151, 28}, 0, { 320, 64}, {0x8b, 0x8b, 0x00, 0xff}}}, + {{{ 551, 176, 13}, 0, { 320, 64}, {0x8b, 0x8b, 0x00, 0xff}}}, + {{{ 525, 152, 44}, 0, { 320, 96}, {0x8b, 0x8b, 0x00, 0xff}}}, +}; + +// 0x07002F30 - 0x07002F60 +static const Vtx intro_seg7_vertex_07002F30[] = { + {{{ 530, 186, 24}, 0, { 320, 96}, {0xba, 0xba, 0x00, 0xff}}}, + {{{ 522, 162, 18}, 0, { 320, 64}, {0xba, 0xba, 0x00, 0xff}}}, + {{{ 551, 176, 13}, 0, { 320, 64}, {0xba, 0xba, 0x00, 0xff}}}, +}; + +// 0x07002F60 - 0x07002F90 +static const Vtx intro_seg7_vertex_07002F60[] = { + {{{ 551, 176, 13}, 0, { 320, 64}, {0x6a, 0x6a, 0x00, 0xff}}}, + {{{ 522, 162, 18}, 0, { 320, 64}, {0x6a, 0x6a, 0x00, 0xff}}}, + {{{ 525, 152, 44}, 0, { 320, 96}, {0x6a, 0x6a, 0x00, 0xff}}}, +}; + +// 0x07002F90 - 0x07002FC0 +static const Vtx intro_seg7_vertex_07002F90[] = { + {{{ 522, 162, 18}, 0, { 320, 64}, {0xba, 0xba, 0x00, 0xff}}}, + {{{ 530, 186, 24}, 0, { 320, 96}, {0xba, 0xba, 0x00, 0xff}}}, + {{{ 449, 179, 28}, 0, { 320, 96}, {0xba, 0xba, 0x00, 0xff}}}, +}; + +// 0x07002FC0 - 0x07003000 +static const Vtx intro_seg7_vertex_07002FC0[] = { + {{{ 545, -8, 124}, 0, { 384, 64}, {0xba, 0xba, 0x00, 0xff}}}, + {{{ 520, 7, 131}, 0, { 384, 96}, {0xba, 0xba, 0x00, 0xff}}}, + {{{ 480, -27, 130}, 0, { 384, 96}, {0xba, 0xba, 0x00, 0xff}}}, + {{{ 461, -7, 140}, 0, { 384, 96}, {0xba, 0xba, 0x00, 0xff}}}, +}; + +// 0x07003000 - 0x07003040 +static const Vtx intro_seg7_vertex_07003000[] = { + {{{ 191, -117, 186}, 0, { 416, 192}, {0x51, 0x51, 0x00, 0xff}}}, + {{{ 211, -92, 191}, 0, { 416, 160}, {0x51, 0x51, 0x00, 0xff}}}, + {{{ 175, 281, -51}, 0, { 256, 160}, {0x51, 0x51, 0x00, 0xff}}}, + {{{ 195, 272, -26}, 0, { 256, 160}, {0x51, 0x51, 0x00, 0xff}}}, +}; + +// 0x07003040 - 0x07003080 +static const Vtx intro_seg7_vertex_07003040[] = { + {{{ 578, 342, -86}, 0, { 224, 64}, {0x6a, 0x6a, 0x00, 0xff}}}, + {{{ 175, 281, -51}, 0, { 256, 160}, {0x6a, 0x6a, 0x00, 0xff}}}, + {{{ 554, 328, -60}, 0, { 256, 64}, {0x6a, 0x6a, 0x00, 0xff}}}, + {{{ 195, 272, -26}, 0, { 256, 160}, {0x6a, 0x6a, 0x00, 0xff}}}, +}; + +// 0x07003080 - 0x070030C0 +static const Vtx intro_seg7_vertex_07003080[] = { + {{{ 578, 342, -86}, 0, { 224, 64}, {0xb1, 0xb1, 0x00, 0xff}}}, + {{{ 554, 328, -60}, 0, { 256, 64}, {0xb1, 0xb1, 0x00, 0xff}}}, + {{{ 551, 176, 13}, 0, { 320, 64}, {0xb1, 0xb1, 0x00, 0xff}}}, + {{{ 530, 186, 24}, 0, { 320, 96}, {0xb1, 0xb1, 0x00, 0xff}}}, +}; + +// 0x070030C0 - 0x07003100 +static const Vtx intro_seg7_vertex_070030C0[] = { + {{{ 480, -27, 130}, 0, { 384, 96}, {0xb1, 0xb1, 0x00, 0xff}}}, + {{{ 461, -7, 140}, 0, { 384, 96}, {0xb1, 0xb1, 0x00, 0xff}}}, + {{{ 480, -103, 197}, 0, { 416, 96}, {0xb1, 0xb1, 0x00, 0xff}}}, + {{{ 499, -126, 196}, 0, { 416, 96}, {0xb1, 0xb1, 0x00, 0xff}}}, +}; + +// 0x07003100 - 0x07003140 +static const Vtx intro_seg7_vertex_07003100[] = { + {{{ 499, -126, 196}, 0, { 416, 96}, {0xa4, 0xa4, 0x00, 0xff}}}, + {{{ 480, -103, 197}, 0, { 416, 96}, {0xa4, 0xa4, 0x00, 0xff}}}, + {{{ 191, -117, 186}, 0, { 416, 192}, {0xa4, 0xa4, 0x00, 0xff}}}, + {{{ 211, -92, 191}, 0, { 416, 160}, {0xa4, 0xa4, 0x00, 0xff}}}, +}; + +// 0x07003140 - 0x07003240 +static const Vtx intro_seg7_vertex_07003140[] = { + {{{ 449, 179, 28}, 0, { 320, 96}, {0xff, 0xff, 0x39, 0xff}}}, + {{{ 438, 183, 26}, 0, { 320, 96}, {0xff, 0xff, 0x39, 0xff}}}, + {{{ 435, 180, 28}, 0, { 320, 96}, {0xff, 0xff, 0x39, 0xff}}}, + {{{ 369, 174, 31}, 0, { 320, 128}, {0xff, 0xff, 0x39, 0xff}}}, + {{{ 530, 186, 24}, 0, { 320, 96}, {0xff, 0xff, 0x39, 0xff}}}, + {{{ 195, 272, -26}, 0, { 256, 160}, {0xff, 0xff, 0x39, 0xff}}}, + {{{ 348, 188, 23}, 0, { 288, 128}, {0xff, 0xff, 0x39, 0xff}}}, + {{{ 427, 8, 130}, 0, { 384, 96}, {0xff, 0xff, 0x39, 0xff}}}, + {{{ 449, -10, 142}, 0, { 384, 96}, {0xff, 0xff, 0x39, 0xff}}}, + {{{ 456, 10, 130}, 0, { 384, 96}, {0xff, 0xff, 0x39, 0xff}}}, + {{{ 461, -7, 140}, 0, { 384, 96}, {0xff, 0xff, 0x39, 0xff}}}, + {{{ 211, -92, 191}, 0, { 416, 160}, {0xff, 0xff, 0x39, 0xff}}}, + {{{ 328, 172, 32}, 0, { 320, 128}, {0xff, 0xff, 0x39, 0xff}}}, + {{{ 306, 154, 43}, 0, { 320, 128}, {0xff, 0xff, 0x39, 0xff}}}, + {{{ 411, 147, 47}, 0, { 320, 96}, {0xff, 0xff, 0x39, 0xff}}}, + {{{ 313, 165, 36}, 0, { 320, 128}, {0xff, 0xff, 0x39, 0xff}}}, +}; + +// 0x07003240 - 0x07003330 +static const Vtx intro_seg7_vertex_07003240[] = { + {{{ 328, 172, 32}, 0, { 320, 128}, {0xff, 0xff, 0x39, 0xff}}}, + {{{ 307, 170, 34}, 0, { 320, 128}, {0xff, 0xff, 0x39, 0xff}}}, + {{{ 313, 165, 36}, 0, { 320, 128}, {0xff, 0xff, 0x39, 0xff}}}, + {{{ 195, 272, -26}, 0, { 256, 160}, {0xff, 0xff, 0x39, 0xff}}}, + {{{ 461, -7, 140}, 0, { 384, 96}, {0xff, 0xff, 0x39, 0xff}}}, + {{{ 480, 81, 86}, 0, { 352, 96}, {0xff, 0xff, 0x39, 0xff}}}, + {{{ 456, 10, 130}, 0, { 384, 96}, {0xff, 0xff, 0x39, 0xff}}}, + {{{ 427, 8, 130}, 0, { 384, 96}, {0xff, 0xff, 0x39, 0xff}}}, + {{{ 306, 154, 43}, 0, { 320, 128}, {0xff, 0xff, 0x39, 0xff}}}, + {{{ 520, 7, 131}, 0, { 384, 96}, {0xff, 0xff, 0x39, 0xff}}}, + {{{ 525, 152, 44}, 0, { 320, 96}, {0xff, 0xff, 0x39, 0xff}}}, + {{{ 449, 179, 28}, 0, { 320, 96}, {0xff, 0xff, 0x39, 0xff}}}, + {{{ 435, 180, 28}, 0, { 320, 96}, {0xff, 0xff, 0x39, 0xff}}}, + {{{ 411, 147, 47}, 0, { 320, 96}, {0xff, 0xff, 0x39, 0xff}}}, + {{{ 398, 34, 115}, 0, { 352, 128}, {0xff, 0xff, 0x39, 0xff}}}, +}; + +// 0x07003330 - 0x07003410 +static const Vtx intro_seg7_vertex_07003330[] = { + {{{ 480, -103, 197}, 0, { 416, 96}, {0xff, 0xff, 0x39, 0xff}}}, + {{{ 461, -7, 140}, 0, { 384, 96}, {0xff, 0xff, 0x39, 0xff}}}, + {{{ 211, -92, 191}, 0, { 416, 160}, {0xff, 0xff, 0x39, 0xff}}}, + {{{ 301, 36, 114}, 0, { 352, 128}, {0xff, 0xff, 0x39, 0xff}}}, + {{{ 343, 5, 132}, 0, { 384, 128}, {0xff, 0xff, 0x39, 0xff}}}, + {{{ 330, 88, 82}, 0, { 352, 128}, {0xff, 0xff, 0x39, 0xff}}}, + {{{ 299, 2, 134}, 0, { 384, 128}, {0xff, 0xff, 0x39, 0xff}}}, + {{{ 195, 272, -26}, 0, { 256, 160}, {0xff, 0xff, 0x39, 0xff}}}, + {{{ 306, 154, 43}, 0, { 320, 128}, {0xff, 0xff, 0x39, 0xff}}}, + {{{ 398, 34, 115}, 0, { 352, 128}, {0xff, 0xff, 0x39, 0xff}}}, + {{{ 427, 8, 130}, 0, { 384, 96}, {0xff, 0xff, 0x39, 0xff}}}, + {{{ 411, 147, 47}, 0, { 320, 96}, {0xff, 0xff, 0x39, 0xff}}}, + {{{ 554, 328, -60}, 0, { 256, 64}, {0xff, 0xff, 0x39, 0xff}}}, + {{{ 530, 186, 24}, 0, { 320, 96}, {0xff, 0xff, 0x39, 0xff}}}, +}; + +// 0x07003410 - 0x07003440 +static const Vtx intro_seg7_vertex_07003410[] = { + {{{ 211, -92, 191}, 0, { 416, 160}, {0xff, 0xff, 0x39, 0xff}}}, + {{{ 299, 2, 134}, 0, { 384, 128}, {0xff, 0xff, 0x39, 0xff}}}, + {{{ 195, 272, -26}, 0, { 256, 160}, {0xff, 0xff, 0x39, 0xff}}}, +}; + +// 0x07003440 - 0x07003470 +static const Vtx intro_seg7_vertex_07003440[] = { + {{{ 411, 147, 47}, 0, { 320, 96}, {0x43, 0x43, 0x00, 0xff}}}, + {{{ 435, 180, 28}, 0, { 320, 96}, {0x43, 0x43, 0x00, 0xff}}}, + {{{ 407, 159, 26}, 0, { 320, 128}, {0x43, 0x43, 0x00, 0xff}}}, +}; + +// 0x07003470 - 0x070034A0 +static const Vtx intro_seg7_vertex_07003470[] = { + {{{ 368, 174, 31}, 0, { 320, 128}, {0xba, 0xba, 0x00, 0xff}}}, + {{{ 410, 147, 47}, 0, { 320, 96}, {0xba, 0xba, 0x00, 0xff}}}, + {{{ 406, 159, 26}, 0, { 320, 128}, {0xba, 0xba, 0x00, 0xff}}}, +}; + +// 0x070034A0 - 0x070034D0 +static const Vtx intro_seg7_vertex_070034A0[] = { + {{{ 435, 180, 28}, 0, { 320, 96}, {0xba, 0xba, 0x00, 0xff}}}, + {{{ 369, 174, 31}, 0, { 320, 128}, {0xba, 0xba, 0x00, 0xff}}}, + {{{ 407, 159, 26}, 0, { 320, 128}, {0xba, 0xba, 0x00, 0xff}}}, +}; + +// 0x070034D0 - 0x070035C0 +static const Vtx intro_seg7_vertex_070034D0[] = { + {{{ 396, 12, 114}, 0, { 352, 128}, {0xba, 0xba, 0x00, 0xff}}}, + {{{ 398, 34, 115}, 0, { 352, 128}, {0xba, 0xba, 0x00, 0xff}}}, + {{{ 343, 5, 132}, 0, { 384, 128}, {0xba, 0xba, 0x00, 0xff}}}, + {{{ 316, 83, 71}, 0, { 352, 128}, {0x78, 0x78, 0x00, 0xff}}}, + {{{ 330, 88, 82}, 0, { 352, 128}, {0x78, 0x78, 0x00, 0xff}}}, + {{{ 306, 154, 43}, 0, { 320, 128}, {0x78, 0x78, 0x00, 0xff}}}, + {{{ 312, 7, 117}, 0, { 352, 128}, {0x62, 0x62, 0x00, 0xff}}}, + {{{ 299, 2, 134}, 0, { 384, 128}, {0x62, 0x62, 0x00, 0xff}}}, + {{{ 343, 5, 132}, 0, { 384, 128}, {0x62, 0x62, 0x00, 0xff}}}, + {{{ 301, 36, 114}, 0, { 352, 128}, {0x43, 0x43, 0x00, 0xff}}}, + {{{ 330, 88, 82}, 0, { 352, 128}, {0x43, 0x43, 0x00, 0xff}}}, + {{{ 316, 83, 71}, 0, { 352, 128}, {0x43, 0x43, 0x00, 0xff}}}, + {{{ 427, 8, 130}, 0, { 384, 96}, {0x78, 0x78, 0x00, 0xff}}}, + {{{ 398, 34, 115}, 0, { 352, 128}, {0x78, 0x78, 0x00, 0xff}}}, + {{{ 396, 12, 114}, 0, { 352, 128}, {0x78, 0x78, 0x00, 0xff}}}, +}; + +// 0x070035C0 - 0x07003680 +static const Vtx intro_seg7_vertex_070035C0[] = { + {{{ 343, 5, 132}, 0, { 384, 128}, {0xba, 0xba, 0x00, 0xff}}}, + {{{ 427, 8, 130}, 0, { 384, 96}, {0xba, 0xba, 0x00, 0xff}}}, + {{{ 396, 12, 114}, 0, { 352, 128}, {0xba, 0xba, 0x00, 0xff}}}, + {{{ 301, 36, 114}, 0, { 352, 128}, {0x78, 0x78, 0x00, 0xff}}}, + {{{ 299, 2, 134}, 0, { 384, 128}, {0x78, 0x78, 0x00, 0xff}}}, + {{{ 312, 7, 117}, 0, { 352, 128}, {0x78, 0x78, 0x00, 0xff}}}, + {{{ 306, 154, 43}, 0, { 320, 128}, {0x62, 0x62, 0x00, 0xff}}}, + {{{ 301, 36, 114}, 0, { 352, 128}, {0x62, 0x62, 0x00, 0xff}}}, + {{{ 316, 83, 71}, 0, { 352, 128}, {0x62, 0x62, 0x00, 0xff}}}, + {{{ 312, 7, 117}, 0, { 352, 128}, {0x43, 0x43, 0x00, 0xff}}}, + {{{ 343, 5, 132}, 0, { 384, 128}, {0x43, 0x43, 0x00, 0xff}}}, + {{{ 301, 36, 114}, 0, { 352, 128}, {0x43, 0x43, 0x00, 0xff}}}, +}; + +// 0x07003680 - 0x070036C0 +static const Vtx intro_seg7_vertex_07003680[] = { + {{{ -85, 319, -74}, 0, { 224, 224}, {0x00, 0x75, 0x00, 0xff}}}, + {{{ -72, 307, -47}, 0, { 256, 224}, {0x00, 0x75, 0x00, 0xff}}}, + {{{ 98, 302, -60}, 0, { 256, 160}, {0x00, 0x75, 0x00, 0xff}}}, + {{{ 69, 291, -38}, 0, { 256, 192}, {0x00, 0x75, 0x00, 0xff}}}, +}; + +// 0x070036C0 - 0x07003700 +static const Vtx intro_seg7_vertex_070036C0[] = { + {{{ 59, 241, -21}, 0, { 288, 192}, {0x00, 0xa6, 0x00, 0xff}}}, + {{{ 69, 291, -38}, 0, { 256, 192}, {0x00, 0xa6, 0x00, 0xff}}}, + {{{ 32, 233, -3}, 0, { 288, 192}, {0x00, 0xa6, 0x00, 0xff}}}, + {{{ 98, 302, -60}, 0, { 256, 160}, {0x00, 0xa6, 0x00, 0xff}}}, +}; + +// 0x07003700 - 0x07003740 +static const Vtx intro_seg7_vertex_07003700[] = { + {{{ 32, 233, -3}, 0, { 288, 192}, {0x00, 0x75, 0x00, 0xff}}}, + {{{ 116, 212, 8}, 0, { 288, 192}, {0x00, 0x75, 0x00, 0xff}}}, + {{{ 59, 241, -21}, 0, { 288, 192}, {0x00, 0x75, 0x00, 0xff}}}, + {{{ 144, 218, -12}, 0, { 288, 160}, {0x00, 0x75, 0x00, 0xff}}}, +}; + +// 0x07003740 - 0x07003780 +static const Vtx intro_seg7_vertex_07003740[] = { + {{{ -93, 259, -19}, 0, { 256, 224}, {0x00, 0x4b, 0x00, 0xff}}}, + {{{ -72, 307, -47}, 0, { 256, 224}, {0x00, 0x4b, 0x00, 0xff}}}, + {{{ -110, 272, -42}, 0, { 256, 224}, {0x00, 0x4b, 0x00, 0xff}}}, + {{{ -85, 319, -74}, 0, { 224, 224}, {0x00, 0x4b, 0x00, 0xff}}}, +}; + +// 0x07003780 - 0x070037C0 +static const Vtx intro_seg7_vertex_07003780[] = { + {{{ -93, 259, -19}, 0, { 256, 224}, {0x00, 0x75, 0x00, 0xff}}}, + {{{ -110, 272, -42}, 0, { 256, 224}, {0x00, 0x75, 0x00, 0xff}}}, + {{{ -202, 276, -29}, 0, { 256, 256}, {0x00, 0x75, 0x00, 0xff}}}, + {{{ -213, 286, -51}, 0, { 256, 256}, {0x00, 0x75, 0x00, 0xff}}}, +}; + +// 0x070037C0 - 0x070037F0 +static const Vtx intro_seg7_vertex_070037C0[] = { + {{{ -190, 150, 28}, 0, { 320, 256}, {0x00, 0x5a, 0x00, 0xff}}}, + {{{ -195, 134, 55}, 0, { 320, 256}, {0x00, 0x5a, 0x00, 0xff}}}, + {{{ -165, 171, 33}, 0, { 288, 256}, {0x00, 0x5a, 0x00, 0xff}}}, +}; + +// 0x070037F0 - 0x07003830 +static const Vtx intro_seg7_vertex_070037F0[] = { + {{{ -165, 171, 33}, 0, { 288, 256}, {0x00, 0xbb, 0x00, 0xff}}}, + {{{ -257, 180, 27}, 0, { 288, 288}, {0x00, 0xbb, 0x00, 0xff}}}, + {{{ -190, 150, 28}, 0, { 320, 256}, {0x00, 0xbb, 0x00, 0xff}}}, + {{{ -290, 156, 24}, 0, { 320, 288}, {0x00, 0xbb, 0x00, 0xff}}}, +}; + +// 0x07003830 - 0x07003870 +static const Vtx intro_seg7_vertex_07003830[] = { + {{{ -213, 286, -51}, 0, { 256, 256}, {0x00, 0x4b, 0x00, 0xff}}}, + {{{ -290, 156, 24}, 0, { 320, 288}, {0x00, 0x4b, 0x00, 0xff}}}, + {{{ -202, 276, -29}, 0, { 256, 256}, {0x00, 0x4b, 0x00, 0xff}}}, + {{{ -257, 180, 27}, 0, { 288, 288}, {0x00, 0x4b, 0x00, 0xff}}}, +}; + +// 0x07003870 - 0x070038B0 +static const Vtx intro_seg7_vertex_07003870[] = { + {{{ -366, 60, 81}, 0, { 320, 320}, {0x00, 0x54, 0x00, 0xff}}}, + {{{ -341, 60, 99}, 0, { 352, 288}, {0x00, 0x54, 0x00, 0xff}}}, + {{{ -190, 150, 28}, 0, { 320, 256}, {0x00, 0x54, 0x00, 0xff}}}, + {{{ -195, 134, 55}, 0, { 320, 256}, {0x00, 0x54, 0x00, 0xff}}}, +}; + +// 0x070038B0 - 0x07003910 +static const Vtx intro_seg7_vertex_070038B0[] = { + {{{ 82, -110, 183}, 0, { 416, 192}, {0x00, 0xa6, 0x00, 0xff}}}, + {{{ 144, 218, -12}, 0, { 288, 160}, {0x00, 0xa6, 0x00, 0xff}}}, + {{{ 64, -85, 187}, 0, { 384, 192}, {0x00, 0xa6, 0x00, 0xff}}}, + {{{ 144, 218, -12}, 0, { 288, 160}, {0x00, 0xa6, 0x00, 0xff}}}, + {{{ 116, 212, 8}, 0, { 288, 192}, {0x00, 0xa6, 0x00, 0xff}}}, + {{{ 64, -85, 187}, 0, { 384, 192}, {0x00, 0xa6, 0x00, 0xff}}}, +}; + +// 0x07003910 - 0x07003950 +static const Vtx intro_seg7_vertex_07003910[] = { + {{{ 82, -110, 183}, 0, { 416, 192}, {0x00, 0xa4, 0x00, 0xff}}}, + {{{ 64, -85, 187}, 0, { 384, 192}, {0x00, 0xa4, 0x00, 0xff}}}, + {{{ -153, -107, 181}, 0, { 416, 256}, {0x00, 0xa4, 0x00, 0xff}}}, + {{{ -128, -83, 186}, 0, { 384, 256}, {0x00, 0xa4, 0x00, 0xff}}}, +}; + +// 0x07003950 - 0x07003980 +static const Vtx intro_seg7_vertex_07003950[] = { + {{{ -133, -29, 132}, 0, { 384, 256}, {0x00, 0x4b, 0x00, 0xff}}}, + {{{ -153, -107, 181}, 0, { 416, 256}, {0x00, 0x4b, 0x00, 0xff}}}, + {{{ -128, -83, 186}, 0, { 384, 256}, {0x00, 0x4b, 0x00, 0xff}}}, +}; + +// 0x07003980 - 0x070039B0 +static const Vtx intro_seg7_vertex_07003980[] = { + {{{ -47, 92, 60}, 0, { 320, 224}, {0x00, 0x79, 0x00, 0xff}}}, + {{{ -93, 41, 111}, 0, { 352, 224}, {0x00, 0x79, 0x00, 0xff}}}, + {{{ -41, 34, 115}, 0, { 352, 224}, {0x00, 0x79, 0x00, 0xff}}}, +}; + +// 0x070039B0 - 0x070039E0 +static const Vtx intro_seg7_vertex_070039B0[] = { + {{{ -47, 92, 60}, 0, { 320, 224}, {0x00, 0x5a, 0x00, 0xff}}}, + {{{ -41, 34, 115}, 0, { 352, 224}, {0x00, 0x5a, 0x00, 0xff}}}, + {{{ -11, 126, 60}, 0, { 320, 224}, {0x00, 0x5a, 0x00, 0xff}}}, +}; + +// 0x070039E0 - 0x07003A10 +static const Vtx intro_seg7_vertex_070039E0[] = { + {{{ -47, 92, 60}, 0, { 320, 224}, {0x00, 0xa9, 0x00, 0xff}}}, + {{{ -11, 126, 60}, 0, { 320, 224}, {0x00, 0xa9, 0x00, 0xff}}}, + {{{ -52, 135, 54}, 0, { 320, 224}, {0x00, 0xa9, 0x00, 0xff}}}, +}; + +// 0x07003A10 - 0x07003A40 +static const Vtx intro_seg7_vertex_07003A10[] = { + {{{ -133, -29, 132}, 0, { 384, 256}, {0x00, 0xa6, 0x00, 0xff}}}, + {{{ -47, 92, 60}, 0, { 320, 224}, {0x00, 0xa6, 0x00, 0xff}}}, + {{{ -133, -6, 139}, 0, { 352, 256}, {0x00, 0xa6, 0x00, 0xff}}}, +}; + +// 0x07003A40 - 0x07003A70 +static const Vtx intro_seg7_vertex_07003A40[] = { + {{{ -47, 92, 60}, 0, { 320, 224}, {0x00, 0xa6, 0x00, 0xff}}}, + {{{ -52, 135, 54}, 0, { 320, 224}, {0x00, 0xa6, 0x00, 0xff}}}, + {{{ -133, -6, 139}, 0, { 352, 256}, {0x00, 0xa6, 0x00, 0xff}}}, +}; + +// 0x07003A70 - 0x07003AA0 +static const Vtx intro_seg7_vertex_07003A70[] = { + {{{ -47, 92, 60}, 0, { 320, 224}, {0x00, 0xa6, 0x00, 0xff}}}, + {{{ -132, -31, 133}, 0, { 384, 256}, {0x00, 0xa6, 0x00, 0xff}}}, + {{{ -93, 41, 111}, 0, { 352, 224}, {0x00, 0xa6, 0x00, 0xff}}}, +}; + +// 0x07003AA0 - 0x07003AD0 +static const Vtx intro_seg7_vertex_07003AA0[] = { + {{{ -133, -29, 132}, 0, { 384, 256}, {0x00, 0x4b, 0x00, 0xff}}}, + {{{ -128, -83, 186}, 0, { 384, 256}, {0x00, 0x4b, 0x00, 0xff}}}, + {{{ -93, 41, 111}, 0, { 352, 224}, {0x00, 0x4b, 0x00, 0xff}}}, +}; + +// 0x07003AD0 - 0x07003B10 +static const Vtx intro_seg7_vertex_07003AD0[] = { + {{{ -269, -128, 192}, 0, { 416, 288}, {0x00, 0xbb, 0x00, 0xff}}}, + {{{ -133, -29, 132}, 0, { 384, 256}, {0x00, 0xbb, 0x00, 0xff}}}, + {{{ -260, -92, 191}, 0, { 384, 288}, {0x00, 0xbb, 0x00, 0xff}}}, + {{{ -133, -6, 139}, 0, { 352, 256}, {0x00, 0xbb, 0x00, 0xff}}}, +}; + +// 0x07003B10 - 0x07003B50 +static const Vtx intro_seg7_vertex_07003B10[] = { + {{{ -366, 60, 81}, 0, { 320, 320}, {0x00, 0x5a, 0x00, 0xff}}}, + {{{ -269, -128, 192}, 0, { 416, 288}, {0x00, 0x5a, 0x00, 0xff}}}, + {{{ -341, 60, 99}, 0, { 352, 288}, {0x00, 0x5a, 0x00, 0xff}}}, + {{{ -260, -92, 191}, 0, { 384, 288}, {0x00, 0x5a, 0x00, 0xff}}}, +}; + +// 0x07003B50 - 0x07003C30 +static const Vtx intro_seg7_vertex_07003B50[] = { + {{{ 69, 291, -38}, 0, { 256, 192}, {0x00, 0xf1, 0x00, 0xff}}}, + {{{ -72, 307, -47}, 0, { 256, 224}, {0x00, 0xf1, 0x00, 0xff}}}, + {{{ 32, 233, -3}, 0, { 288, 192}, {0x00, 0xf1, 0x00, 0xff}}}, + {{{ -93, 259, -19}, 0, { 256, 224}, {0x00, 0xf1, 0x00, 0xff}}}, + {{{ -52, 135, 54}, 0, { 320, 224}, {0x00, 0xf1, 0x00, 0xff}}}, + {{{ -11, 126, 60}, 0, { 320, 224}, {0x00, 0xf1, 0x00, 0xff}}}, + {{{ 116, 212, 8}, 0, { 288, 192}, {0x00, 0xf1, 0x00, 0xff}}}, + {{{ -257, 180, 27}, 0, { 288, 288}, {0x00, 0xf1, 0x00, 0xff}}}, + {{{ -165, 171, 33}, 0, { 288, 256}, {0x00, 0xf1, 0x00, 0xff}}}, + {{{ -202, 276, -29}, 0, { 256, 256}, {0x00, 0xf1, 0x00, 0xff}}}, + {{{ -195, 134, 55}, 0, { 320, 256}, {0x00, 0xf1, 0x00, 0xff}}}, + {{{ -260, -92, 191}, 0, { 384, 288}, {0x00, 0xf1, 0x00, 0xff}}}, + {{{ -133, -6, 139}, 0, { 352, 256}, {0x00, 0xf1, 0x00, 0xff}}}, + {{{ -341, 60, 99}, 0, { 352, 288}, {0x00, 0xf1, 0x00, 0xff}}}, +}; + +// 0x07003C30 - 0x07003CD0 +static const Vtx intro_seg7_vertex_07003C30[] = { + {{{ -341, 60, 99}, 0, { 352, 288}, {0x00, 0xf1, 0x00, 0xff}}}, + {{{ -133, -6, 139}, 0, { 352, 256}, {0x00, 0xf1, 0x00, 0xff}}}, + {{{ -195, 134, 55}, 0, { 320, 256}, {0x00, 0xf1, 0x00, 0xff}}}, + {{{ -52, 135, 54}, 0, { 320, 224}, {0x00, 0xf1, 0x00, 0xff}}}, + {{{ -41, 34, 115}, 0, { 352, 224}, {0x00, 0xf1, 0x00, 0xff}}}, + {{{ 116, 212, 8}, 0, { 288, 192}, {0x00, 0xf1, 0x00, 0xff}}}, + {{{ -11, 126, 60}, 0, { 320, 224}, {0x00, 0xf1, 0x00, 0xff}}}, + {{{ -128, -83, 186}, 0, { 384, 256}, {0x00, 0xf1, 0x00, 0xff}}}, + {{{ 64, -85, 187}, 0, { 384, 192}, {0x00, 0xf1, 0x00, 0xff}}}, + {{{ -93, 41, 111}, 0, { 352, 224}, {0x00, 0xf1, 0x00, 0xff}}}, +}; + +// 0x07003CD0 - 0x07003D10 +static const Vtx intro_seg7_vertex_07003CD0[] = { + {{{ -743, 372, -86}, 0, { 224, 384}, {0x16, 0x27, 0x9e, 0xff}}}, + {{{ -366, 340, -67}, 0, { 224, 288}, {0x16, 0x27, 0x9e, 0xff}}}, + {{{ -762, 384, -108}, 0, { 192, 384}, {0x16, 0x27, 0x9e, 0xff}}}, + {{{ -340, 348, -86}, 0, { 224, 288}, {0x16, 0x27, 0x9e, 0xff}}}, +}; + +// 0x07003D10 - 0x07003D50 +static const Vtx intro_seg7_vertex_07003D10[] = { + {{{ -340, 348, -86}, 0, { 224, 288}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ -366, 340, -67}, 0, { 224, 288}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ -392, 177, 14}, 0, { 288, 288}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ -416, 170, 33}, 0, { 288, 320}, {0x20, 0x39, 0xe5, 0xff}}}, +}; + +// 0x07003D50 - 0x07003D90 +static const Vtx intro_seg7_vertex_07003D50[] = { + {{{ -416, 170, 33}, 0, { 288, 320}, {0x16, 0x27, 0x9e, 0xff}}}, + {{{ -352, 159, 40}, 0, { 288, 288}, {0x16, 0x27, 0x9e, 0xff}}}, + {{{ -392, 177, 14}, 0, { 288, 288}, {0x16, 0x27, 0x9e, 0xff}}}, + {{{ -330, 165, 21}, 0, { 288, 288}, {0x16, 0x27, 0x9e, 0xff}}}, +}; + +// 0x07003D90 - 0x07003DD0 +static const Vtx intro_seg7_vertex_07003D90[] = { + {{{ -388, -113, 185}, 0, { 416, 320}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ -330, 165, 21}, 0, { 288, 288}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ -405, -91, 190}, 0, { 384, 320}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ -352, 159, 40}, 0, { 288, 288}, {0x20, 0x39, 0xe5, 0xff}}}, +}; + +// 0x07003DD0 - 0x07003E10 +static const Vtx intro_seg7_vertex_07003DD0[] = { + {{{ -594, -160, 213}, 0, { 416, 384}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ -388, -113, 185}, 0, { 416, 320}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ -583, -130, 213}, 0, { 416, 352}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ -405, -91, 190}, 0, { 384, 320}, {0x20, 0x39, 0xe5, 0xff}}}, +}; + +// 0x07003E10 - 0x07003E40 +static const Vtx intro_seg7_vertex_07003E10[] = { + {{{ -748, 54, 94}, 0, { 320, 384}, {0x13, 0x50, 0x8c, 0xff}}}, + {{{ -735, 79, 88}, 0, { 320, 384}, {0x13, 0x50, 0x8c, 0xff}}}, + {{{ -762, 61, 82}, 0, { 320, 416}, {0x13, 0x50, 0x8c, 0xff}}}, +}; + +// 0x07003E40 - 0x07003E80 +static const Vtx intro_seg7_vertex_07003E40[] = { + {{{ -514, 102, 74}, 0, { 320, 352}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ -735, 79, 88}, 0, { 320, 384}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ -544, 74, 81}, 0, { 320, 352}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ -748, 54, 94}, 0, { 320, 384}, {0x20, 0x39, 0xe5, 0xff}}}, +}; + +// 0x07003E80 - 0x07003EB0 +static const Vtx intro_seg7_vertex_07003E80[] = { + {{{ -514, 102, 74}, 0, { 320, 352}, {0x12, 0x20, 0x81, 0xff}}}, + {{{ -544, 74, 81}, 0, { 320, 352}, {0x12, 0x20, 0x81, 0xff}}}, + {{{ -510, 5, 132}, 0, { 352, 352}, {0x12, 0x20, 0x81, 0xff}}}, +}; + +// 0x07003EB0 - 0x07003EE0 +static const Vtx intro_seg7_vertex_07003EB0[] = { + {{{ -551, 5, 115}, 0, { 352, 352}, {0x12, 0x20, 0x81, 0xff}}}, + {{{ -510, 5, 132}, 0, { 352, 352}, {0x12, 0x20, 0x81, 0xff}}}, + {{{ -544, 74, 81}, 0, { 320, 352}, {0x12, 0x20, 0x81, 0xff}}}, +}; + +// 0x07003EE0 - 0x07003F10 +static const Vtx intro_seg7_vertex_07003EE0[] = { + {{{ -510, 5, 132}, 0, { 352, 352}, {0x12, 0x20, 0x81, 0xff}}}, + {{{ -551, 5, 115}, 0, { 352, 352}, {0x12, 0x20, 0x81, 0xff}}}, + {{{ -574, -5, 139}, 0, { 352, 352}, {0x12, 0x20, 0x81, 0xff}}}, +}; + +// 0x07003F10 - 0x07003F40 +static const Vtx intro_seg7_vertex_07003F10[] = { + {{{ -574, -5, 139}, 0, { 352, 352}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ -551, 5, 115}, 0, { 352, 352}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ -575, 61, 98}, 0, { 320, 352}, {0x20, 0x39, 0xe5, 0xff}}}, +}; + +// 0x07003F40 - 0x07003F70 +static const Vtx intro_seg7_vertex_07003F40[] = { + {{{ -575, 61, 98}, 0, { 320, 352}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ -551, 5, 115}, 0, { 352, 352}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ -544, 74, 81}, 0, { 320, 352}, {0x20, 0x39, 0xe5, 0xff}}}, +}; + +// 0x07003F70 - 0x07003FC0 +static const Vtx intro_seg7_vertex_07003F70[] = { + {{{ -868, -118, 188}, 0, { 416, 448}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ -664, -64, 156}, 0, { 384, 384}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ -850, -86, 187}, 0, { 384, 416}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ -574, -5, 139}, 0, { 352, 352}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ -663, -45, 157}, 0, { 384, 384}, {0x20, 0x39, 0xe5, 0xff}}}, +}; + +// 0x07003FC0 - 0x07004010 +static const Vtx intro_seg7_vertex_07003FC0[] = { + {{{ -583, -130, 213}, 0, { 416, 352}, {0x13, 0x50, 0x8c, 0xff}}}, + {{{ -637, -46, 163}, 0, { 384, 384}, {0x13, 0x50, 0x8c, 0xff}}}, + {{{ -663, -45, 157}, 0, { 384, 384}, {0x13, 0x50, 0x8c, 0xff}}}, + {{{ -594, -160, 213}, 0, { 416, 384}, {0x13, 0x50, 0x8c, 0xff}}}, + {{{ -664, -64, 156}, 0, { 384, 384}, {0x13, 0x50, 0x8c, 0xff}}}, +}; + +// 0x07004010 - 0x07004050 +static const Vtx intro_seg7_vertex_07004010[] = { + {{{ -637, -46, 163}, 0, { 384, 384}, {0x12, 0x20, 0x81, 0xff}}}, + {{{ -510, 5, 132}, 0, { 352, 352}, {0x12, 0x20, 0x81, 0xff}}}, + {{{ -574, -5, 139}, 0, { 352, 352}, {0x12, 0x20, 0x81, 0xff}}}, + {{{ -663, -45, 157}, 0, { 384, 384}, {0x12, 0x20, 0x81, 0xff}}}, +}; + +// 0x07004050 - 0x07004090 +static const Vtx intro_seg7_vertex_07004050[] = { + {{{ -864, 48, 90}, 0, { 320, 416}, {0x16, 0x27, 0x9e, 0xff}}}, + {{{ -844, 36, 114}, 0, { 352, 416}, {0x16, 0x27, 0x9e, 0xff}}}, + {{{ -762, 61, 82}, 0, { 320, 416}, {0x16, 0x27, 0x9e, 0xff}}}, + {{{ -748, 54, 94}, 0, { 320, 384}, {0x16, 0x27, 0x9e, 0xff}}}, +}; + +// 0x07004090 - 0x070040D0 +static const Vtx intro_seg7_vertex_07004090[] = { + {{{ -844, 36, 114}, 0, { 352, 416}, {0x16, 0x27, 0x9e, 0xff}}}, + {{{ -575, 61, 98}, 0, { 320, 352}, {0x16, 0x27, 0x9e, 0xff}}}, + {{{ -748, 54, 94}, 0, { 320, 384}, {0x16, 0x27, 0x9e, 0xff}}}, + {{{ -544, 74, 81}, 0, { 320, 352}, {0x16, 0x27, 0x9e, 0xff}}}, +}; + +// 0x070040D0 - 0x07004110 +static const Vtx intro_seg7_vertex_070040D0[] = { + {{{ -733, 215, -8}, 0, { 288, 384}, {0x16, 0x27, 0x9e, 0xff}}}, + {{{ -716, 209, 10}, 0, { 288, 384}, {0x16, 0x27, 0x9e, 0xff}}}, + {{{ -623, 210, -5}, 0, { 288, 352}, {0x16, 0x27, 0x9e, 0xff}}}, + {{{ -642, 211, 9}, 0, { 288, 352}, {0x16, 0x27, 0x9e, 0xff}}}, +}; + +// 0x07004110 - 0x07004150 +static const Vtx intro_seg7_vertex_07004110[] = { + {{{ -619, 175, 31}, 0, { 288, 352}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ -613, 195, 3}, 0, { 288, 352}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ -642, 211, 9}, 0, { 288, 352}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ -623, 210, -5}, 0, { 288, 352}, {0x20, 0x39, 0xe5, 0xff}}}, +}; + +// 0x07004150 - 0x07004190 +static const Vtx intro_seg7_vertex_07004150[] = { + {{{ -619, 175, 31}, 0, { 288, 352}, {0x16, 0x27, 0x9e, 0xff}}}, + {{{ -521, 175, 31}, 0, { 288, 352}, {0x16, 0x27, 0x9e, 0xff}}}, + {{{ -613, 195, 3}, 0, { 288, 352}, {0x16, 0x27, 0x9e, 0xff}}}, + {{{ -557, 199, 1}, 0, { 288, 352}, {0x16, 0x27, 0x9e, 0xff}}}, +}; + +// 0x07004190 - 0x070041C0 +static const Vtx intro_seg7_vertex_07004190[] = { + {{{ -557, 199, 1}, 0, { 288, 352}, {0x12, 0x20, 0x81, 0xff}}}, + {{{ -521, 175, 31}, 0, { 288, 352}, {0x12, 0x20, 0x81, 0xff}}}, + {{{ -505, 240, -8}, 0, { 256, 320}, {0x12, 0x20, 0x81, 0xff}}}, +}; + +// 0x070041C0 - 0x070041F0 +static const Vtx intro_seg7_vertex_070041C0[] = { + {{{ -623, 210, -5}, 0, { 288, 352}, {0x16, 0x27, 0x9e, 0xff}}}, + {{{ -613, 195, 3}, 0, { 288, 352}, {0x16, 0x27, 0x9e, 0xff}}}, + {{{ -557, 199, 1}, 0, { 288, 352}, {0x16, 0x27, 0x9e, 0xff}}}, +}; + +// 0x070041F0 - 0x07004250 +static const Vtx intro_seg7_vertex_070041F0[] = { + {{{ -772, 213, -9}, 0, { 288, 416}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ -733, 215, -8}, 0, { 288, 384}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ -745, 243, -9}, 0, { 256, 384}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ -623, 210, -5}, 0, { 288, 352}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ -505, 240, -8}, 0, { 256, 320}, {0x20, 0x39, 0xe5, 0xff}}}, + {{{ -557, 199, 1}, 0, { 288, 352}, {0x20, 0x39, 0xe5, 0xff}}}, +}; + +// 0x07004250 - 0x07004290 +static const Vtx intro_seg7_vertex_07004250[] = { + {{{ -762, 384, -108}, 0, { 192, 384}, {0x10, 0x1c, 0x73, 0xff}}}, + {{{ -772, 213, -9}, 0, { 288, 416}, {0x10, 0x1c, 0x73, 0xff}}}, + {{{ -743, 372, -86}, 0, { 224, 384}, {0x10, 0x1c, 0x73, 0xff}}}, + {{{ -745, 243, -9}, 0, { 256, 384}, {0x10, 0x1c, 0x73, 0xff}}}, +}; + +// 0x07004290 - 0x070042D0 +static const Vtx intro_seg7_vertex_07004290[] = { + {{{ -733, 215, -8}, 0, { 288, 384}, {0x10, 0x73, 0x73, 0xff}}}, + {{{ -762, 61, 82}, 0, { 320, 416}, {0x10, 0x73, 0x73, 0xff}}}, + {{{ -716, 209, 10}, 0, { 288, 384}, {0x10, 0x73, 0x73, 0xff}}}, + {{{ -735, 79, 88}, 0, { 320, 384}, {0x10, 0x73, 0x73, 0xff}}}, +}; + +// 0x070042D0 - 0x07004310 +static const Vtx intro_seg7_vertex_070042D0[] = { + {{{ -868, -118, 188}, 0, { 416, 448}, {0x10, 0x73, 0x73, 0xff}}}, + {{{ -850, -86, 187}, 0, { 384, 416}, {0x10, 0x73, 0x73, 0xff}}}, + {{{ -864, 48, 90}, 0, { 320, 416}, {0x10, 0x73, 0x73, 0xff}}}, + {{{ -844, 36, 114}, 0, { 352, 416}, {0x10, 0x73, 0x73, 0xff}}}, +}; + +// 0x07004310 - 0x070043F0 +static const Vtx intro_seg7_vertex_07004310[] = { + {{{ -735, 79, 88}, 0, { 320, 384}, {0x65, 0x7f, 0xff, 0xff}}}, + {{{ -514, 102, 74}, 0, { 320, 352}, {0x65, 0x7f, 0xff, 0xff}}}, + {{{ -716, 209, 10}, 0, { 288, 384}, {0x65, 0x7f, 0xff, 0xff}}}, + {{{ -510, 5, 132}, 0, { 352, 352}, {0x65, 0x7f, 0xff, 0xff}}}, + {{{ -352, 159, 40}, 0, { 288, 288}, {0x65, 0x7f, 0xff, 0xff}}}, + {{{ -416, 170, 33}, 0, { 288, 320}, {0x65, 0x7f, 0xff, 0xff}}}, + {{{ -521, 175, 31}, 0, { 288, 352}, {0x65, 0x7f, 0xff, 0xff}}}, + {{{ -619, 175, 31}, 0, { 288, 352}, {0x65, 0x7f, 0xff, 0xff}}}, + {{{ -642, 211, 9}, 0, { 288, 352}, {0x65, 0x7f, 0xff, 0xff}}}, + {{{ -637, -46, 163}, 0, { 384, 384}, {0x65, 0x7f, 0xff, 0xff}}}, + {{{ -583, -130, 213}, 0, { 416, 352}, {0x65, 0x7f, 0xff, 0xff}}}, + {{{ -405, -91, 190}, 0, { 384, 320}, {0x65, 0x7f, 0xff, 0xff}}}, + {{{ -366, 340, -67}, 0, { 224, 288}, {0x65, 0x7f, 0xff, 0xff}}}, + {{{ -505, 240, -8}, 0, { 256, 320}, {0x65, 0x7f, 0xff, 0xff}}}, +}; + +// 0x070043F0 - 0x07004430 +static const Vtx intro_seg7_vertex_070043F0[] = { + {{{ -743, 372, -86}, 0, { 224, 384}, {0x65, 0x7f, 0xff, 0xff}}}, + {{{ -745, 243, -9}, 0, { 256, 384}, {0x65, 0x7f, 0xff, 0xff}}}, + {{{ -366, 340, -67}, 0, { 224, 288}, {0x65, 0x7f, 0xff, 0xff}}}, + {{{ -505, 240, -8}, 0, { 256, 320}, {0x65, 0x7f, 0xff, 0xff}}}, +}; + +// 0x07004430 - 0x07004470 +static const Vtx intro_seg7_vertex_07004430[] = { + {{{ -850, -86, 187}, 0, { 384, 416}, {0x65, 0x7f, 0xff, 0xff}}}, + {{{ -574, -5, 139}, 0, { 352, 352}, {0x65, 0x7f, 0xff, 0xff}}}, + {{{ -844, 36, 114}, 0, { 352, 416}, {0x65, 0x7f, 0xff, 0xff}}}, + {{{ -575, 61, 98}, 0, { 320, 352}, {0x65, 0x7f, 0xff, 0xff}}}, +}; + +// 0x07004470 - 0x070044B0 +static const Vtx intro_seg7_vertex_07004470[] = { + {{{ 589, 669, -648}, 0, { -1408, -640}, {0xc0, 0xc0, 0xc0, 0xff}}}, + {{{ 589, 815, -404}, 0, { -1408, -640}, {0xc0, 0xc0, 0xc0, 0xff}}}, + {{{ 593, 630, -624}, 0, { -1344, -608}, {0xc0, 0xc0, 0xc0, 0xff}}}, + {{{ 593, 775, -380}, 0, { -1344, -608}, {0xc0, 0xc0, 0xc0, 0xff}}}, +}; + +// 0x070044B0 - 0x070044F0 +static const Vtx intro_seg7_vertex_070044B0[] = { + {{{ 425, 820, -407}, 0, { -1536, -416}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 589, 815, -404}, 0, { -1408, -640}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 425, 674, -651}, 0, { -1536, -416}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 589, 669, -648}, 0, { -1408, -640}, {0x4a, 0x4a, 0x4a, 0xff}}}, +}; + +// 0x070044F0 - 0x07004530 +static const Vtx intro_seg7_vertex_070044F0[] = { + {{{ 681, 636, -628}, 0, { -1280, -768}, {0xc0, 0xc0, 0xc0, 0xff}}}, + {{{ 681, 781, -384}, 0, { -1280, -768}, {0xc0, 0xc0, 0xc0, 0xff}}}, + {{{ 669, 486, -538}, 0, { -1024, -608}, {0xc0, 0xc0, 0xc0, 0xff}}}, + {{{ 669, 631, -295}, 0, { -1024, -608}, {0xc0, 0xc0, 0xc0, 0xff}}}, +}; + +// 0x07004530 - 0x07004570 +static const Vtx intro_seg7_vertex_07004530[] = { + {{{ 593, 630, -624}, 0, { -1344, -608}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 593, 775, -380}, 0, { -1344, -608}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 681, 636, -628}, 0, { -1280, -768}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 681, 781, -384}, 0, { -1280, -768}, {0x4a, 0x4a, 0x4a, 0xff}}}, +}; + +// 0x07004570 - 0x070045B0 +static const Vtx intro_seg7_vertex_07004570[] = { + {{{ 669, 631, -295}, 0, { -1024, -608}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 661, 633, -296}, 0, { -1024, -608}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 669, 486, -538}, 0, { -1024, -608}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 660, 488, -540}, 0, { -1024, -608}, {0x4a, 0x4a, 0x4a, 0xff}}}, +}; + +// 0x070045B0 - 0x070045F0 +static const Vtx intro_seg7_vertex_070045B0[] = { + {{{ 676, 438, -510}, 0, { -928, -576}, {0xc0, 0xc0, 0xc0, 0xff}}}, + {{{ 676, 583, -267}, 0, { -928, -576}, {0xc0, 0xc0, 0xc0, 0xff}}}, + {{{ 682, 308, -432}, 0, { -704, -480}, {0xc0, 0xc0, 0xc0, 0xff}}}, + {{{ 682, 453, -190}, 0, { -704, -480}, {0xc0, 0xc0, 0xc0, 0xff}}}, +}; + +// 0x070045F0 - 0x07004630 +static const Vtx intro_seg7_vertex_070045F0[] = { + {{{ 671, 450, -517}, 0, { -960, -576}, {0xc0, 0xc0, 0xc0, 0xff}}}, + {{{ 671, 595, -274}, 0, { -960, -576}, {0xc0, 0xc0, 0xc0, 0xff}}}, + {{{ 661, 438, -510}, 0, { -960, -544}, {0xc0, 0xc0, 0xc0, 0xff}}}, + {{{ 661, 583, -267}, 0, { -960, -544}, {0xc0, 0xc0, 0xc0, 0xff}}}, +}; + +// 0x07004630 - 0x07004670 +static const Vtx intro_seg7_vertex_07004630[] = { + {{{ 661, 583, -267}, 0, { -960, -544}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 676, 583, -267}, 0, { -928, -576}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 661, 438, -510}, 0, { -960, -544}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 676, 438, -510}, 0, { -928, -576}, {0x4a, 0x4a, 0x4a, 0xff}}}, +}; + +// 0x07004670 - 0x070046B0 +static const Vtx intro_seg7_vertex_07004670[] = { + {{{ 660, 488, -540}, 0, { -1024, -608}, {0xc0, 0xc0, 0xc0, 0xff}}}, + {{{ 661, 633, -296}, 0, { -1024, -608}, {0xc0, 0xc0, 0xc0, 0xff}}}, + {{{ 671, 450, -517}, 0, { -960, -576}, {0xc0, 0xc0, 0xc0, 0xff}}}, + {{{ 671, 595, -274}, 0, { -960, -576}, {0xc0, 0xc0, 0xc0, 0xff}}}, +}; + +// 0x070046B0 - 0x070046F0 +static const Vtx intro_seg7_vertex_070046B0[] = { + {{{ 655, 304, -429}, 0, { -736, -416}, {0xc0, 0xc0, 0xc0, 0xff}}}, + {{{ 655, 448, -187}, 0, { -736, -416}, {0xc0, 0xc0, 0xc0, 0xff}}}, + {{{ 672, 208, -372}, 0, { -544, -352}, {0xc0, 0xc0, 0xc0, 0xff}}}, + {{{ 672, 352, -130}, 0, { -544, -352}, {0xc0, 0xc0, 0xc0, 0xff}}}, +}; + +// 0x070046F0 - 0x07004730 +static const Vtx intro_seg7_vertex_070046F0[] = { + {{{ 682, 308, -432}, 0, { -704, -480}, {0x95, 0x95, 0x95, 0xff}}}, + {{{ 682, 453, -190}, 0, { -704, -480}, {0x95, 0x95, 0x95, 0xff}}}, + {{{ 655, 304, -429}, 0, { -736, -416}, {0x95, 0x95, 0x95, 0xff}}}, + {{{ 655, 448, -187}, 0, { -736, -416}, {0x95, 0x95, 0x95, 0xff}}}, +}; + +// 0x07004730 - 0x07004770 +static const Vtx intro_seg7_vertex_07004730[] = { + {{{ 672, 208, -372}, 0, { -544, -352}, {0x95, 0x95, 0x95, 0xff}}}, + {{{ 672, 352, -130}, 0, { -544, -352}, {0x95, 0x95, 0x95, 0xff}}}, + {{{ 469, 206, -371}, 0, { -704, -64}, {0x95, 0x95, 0x95, 0xff}}}, + {{{ 469, 350, -129}, 0, { -704, -64}, {0x95, 0x95, 0x95, 0xff}}}, +}; + +// 0x07004770 - 0x070047B0 +static const Vtx intro_seg7_vertex_07004770[] = { + {{{ 469, 206, -371}, 0, { -704, -64}, {0x95, 0x95, 0x95, 0xff}}}, + {{{ 469, 350, -129}, 0, { -704, -64}, {0x95, 0x95, 0x95, 0xff}}}, + {{{ 357, 206, -371}, 0, { -800, 64}, {0x95, 0x95, 0x95, 0xff}}}, + {{{ 356, 350, -129}, 0, { -800, 64}, {0x95, 0x95, 0x95, 0xff}}}, +}; + +// 0x070047B0 - 0x070047F0 +static const Vtx intro_seg7_vertex_070047B0[] = { + {{{ 357, 206, -371}, 0, { -800, 64}, {0xc0, 0xc0, 0xc0, 0xff}}}, + {{{ 356, 350, -129}, 0, { -800, 64}, {0xc0, 0xc0, 0xc0, 0xff}}}, + {{{ 353, 189, -361}, 0, { -768, 96}, {0xc0, 0xc0, 0xc0, 0xff}}}, + {{{ 353, 333, -119}, 0, { -768, 96}, {0xc0, 0xc0, 0xc0, 0xff}}}, +}; + +// 0x070047F0 - 0x07004830 +static const Vtx intro_seg7_vertex_070047F0[] = { + {{{ 246, 468, -528}, 0, { -1312, 0}, {0x95, 0x95, 0x95, 0xff}}}, + {{{ 222, 615, -286}, 0, { -1344, 32}, {0x95, 0x95, 0x95, 0xff}}}, + {{{ 222, 471, -529}, 0, { -1344, 32}, {0x95, 0x95, 0x95, 0xff}}}, + {{{ 246, 613, -285}, 0, { -1344, 0}, {0x95, 0x95, 0x95, 0xff}}}, +}; + +// 0x07004830 - 0x07004870 +static const Vtx intro_seg7_vertex_07004830[] = { + {{{ 222, 471, -529}, 0, { -1344, 32}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 222, 615, -286}, 0, { -1344, 32}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 228, 597, -604}, 0, { -1568, -64}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 228, 742, -361}, 0, { -1568, -64}, {0x4a, 0x4a, 0x4a, 0xff}}}, +}; + +// 0x07004870 - 0x070048B0 +static const Vtx intro_seg7_vertex_07004870[] = { + {{{ 353, 333, -119}, 0, { -768, 96}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 114, 399, -158}, 0, { -1056, 384}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 353, 189, -361}, 0, { -768, 96}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 114, 255, -400}, 0, { -1056, 384}, {0x4a, 0x4a, 0x4a, 0xff}}}, +}; + +// 0x070048B0 - 0x070048F0 +static const Vtx intro_seg7_vertex_070048B0[] = { + {{{ 114, 399, -158}, 0, { -1056, 384}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 240, 583, -267}, 0, { -1280, 32}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 114, 255, -400}, 0, { -1056, 384}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 240, 439, -510}, 0, { -1280, 32}, {0x4a, 0x4a, 0x4a, 0xff}}}, +}; + +// 0x070048F0 - 0x07004930 +static const Vtx intro_seg7_vertex_070048F0[] = { + {{{ 240, 439, -510}, 0, { -1280, 32}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 240, 583, -267}, 0, { -1280, 32}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 246, 468, -528}, 0, { -1312, 0}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 246, 613, -285}, 0, { -1344, 0}, {0x4a, 0x4a, 0x4a, 0xff}}}, +}; + +// 0x07004930 - 0x07004970 +static const Vtx intro_seg7_vertex_07004930[] = { + {{{ 228, 597, -604}, 0, { -1568, -64}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 228, 742, -361}, 0, { -1568, -64}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 265, 600, -606}, 0, { -1536, -96}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 265, 745, -363}, 0, { -1536, -96}, {0x4a, 0x4a, 0x4a, 0xff}}}, +}; + +// 0x07004970 - 0x070049B0 +static const Vtx intro_seg7_vertex_07004970[] = { + {{{ 265, 745, -363}, 0, { -1536, -96}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 246, 778, -382}, 0, { -1600, -96}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 265, 600, -606}, 0, { -1536, -96}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 246, 633, -626}, 0, { -1600, -96}, {0x4a, 0x4a, 0x4a, 0xff}}}, +}; + +// 0x070049B0 - 0x070049F0 +static const Vtx intro_seg7_vertex_070049B0[] = { + {{{ 246, 633, -626}, 0, { -1600, -96}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 246, 778, -382}, 0, { -1600, -96}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 425, 674, -651}, 0, { -1536, -416}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 425, 820, -407}, 0, { -1536, -416}, {0x4a, 0x4a, 0x4a, 0xff}}}, +}; + +// 0x070049F0 - 0x07004A30 +static const Vtx intro_seg7_vertex_070049F0[] = { + {{{ 178, 718, -677}, 0, { -1792, -96}, {0x60, 0x60, 0x60, 0xff}}}, + {{{ 178, 864, -433}, 0, { -1792, -96}, {0x60, 0x60, 0x60, 0xff}}}, + {{{ 308, 621, -619}, 0, { -1536, -192}, {0x60, 0x60, 0x60, 0xff}}}, + {{{ 308, 766, -375}, 0, { -1536, -192}, {0x60, 0x60, 0x60, 0xff}}}, +}; + +// 0x07004A30 - 0x07004A70 +static const Vtx intro_seg7_vertex_07004A30[] = { + {{{ 220, 521, -559}, 0, { -1440, 0}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 220, 666, -316}, 0, { -1440, 0}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 61, 582, -596}, 0, { -1664, 192}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 61, 727, -352}, 0, { -1664, 192}, {0x4a, 0x4a, 0x4a, 0xff}}}, +}; + +// 0x07004A70 - 0x07004AB0 +static const Vtx intro_seg7_vertex_07004A70[] = { + {{{ 308, 766, -375}, 0, { -1536, -192}, {0xd1, 0xd1, 0xd1, 0xff}}}, + {{{ 220, 666, -316}, 0, { -1440, 0}, {0xd1, 0xd1, 0xd1, 0xff}}}, + {{{ 308, 621, -619}, 0, { -1536, -192}, {0xd1, 0xd1, 0xd1, 0xff}}}, + {{{ 220, 521, -559}, 0, { -1440, 0}, {0xd1, 0xd1, 0xd1, 0xff}}}, +}; + +// 0x07004AB0 - 0x07004AF0 +static const Vtx intro_seg7_vertex_07004AB0[] = { + {{{ 61, 582, -596}, 0, { -1664, 192}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 61, 727, -352}, 0, { -1664, 192}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 178, 718, -677}, 0, { -1792, -96}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 178, 864, -433}, 0, { -1792, -96}, {0x4a, 0x4a, 0x4a, 0xff}}}, +}; + +// 0x07004AF0 - 0x07004B30 +static const Vtx intro_seg7_vertex_07004AF0[] = { + {{{ 132, 613, -614}, 0, { -1664, 32}, {0x60, 0x60, 0x60, 0xff}}}, + {{{ 132, 758, -370}, 0, { -1664, 32}, {0x60, 0x60, 0x60, 0xff}}}, + {{{ 266, 491, -541}, 0, { -1344, 0}, {0x60, 0x60, 0x60, 0xff}}}, + {{{ 266, 636, -298}, 0, { -1344, 0}, {0x60, 0x60, 0x60, 0xff}}}, +}; + +// 0x07004B30 - 0x07004B70 +static const Vtx intro_seg7_vertex_07004B30[] = { + {{{ 171, 386, -479}, 0, { -1248, 192}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 171, 531, -236}, 0, { -1248, 192}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 32, 463, -524}, 0, { -1472, 320}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 32, 607, -281}, 0, { -1472, 320}, {0x4a, 0x4a, 0x4a, 0xff}}}, +}; + +// 0x07004B70 - 0x07004BB0 +static const Vtx intro_seg7_vertex_07004B70[] = { + {{{ 266, 636, -298}, 0, { -1344, 0}, {0xd1, 0xd1, 0xd1, 0xff}}}, + {{{ 171, 531, -236}, 0, { -1248, 192}, {0xd1, 0xd1, 0xd1, 0xff}}}, + {{{ 266, 491, -541}, 0, { -1344, 0}, {0xd1, 0xd1, 0xd1, 0xff}}}, + {{{ 171, 386, -479}, 0, { -1248, 192}, {0xd1, 0xd1, 0xd1, 0xff}}}, +}; + +// 0x07004BB0 - 0x07004BF0 +static const Vtx intro_seg7_vertex_07004BB0[] = { + {{{ 32, 463, -524}, 0, { -1472, 320}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 32, 607, -281}, 0, { -1472, 320}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 132, 613, -614}, 0, { -1664, 32}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 132, 758, -370}, 0, { -1664, 32}, {0x4a, 0x4a, 0x4a, 0xff}}}, +}; + +// 0x07004BF0 - 0x07004C30 +static const Vtx intro_seg7_vertex_07004BF0[] = { + {{{ 83, 451, -517}, 0, { -1440, 256}, {0x60, 0x60, 0x60, 0xff}}}, + {{{ 83, 596, -274}, 0, { -1440, 256}, {0x60, 0x60, 0x60, 0xff}}}, + {{{ 256, 401, -487}, 0, { -1216, 64}, {0x60, 0x60, 0x60, 0xff}}}, + {{{ 256, 545, -245}, 0, { -1216, 64}, {0x60, 0x60, 0x60, 0xff}}}, +}; + +// 0x07004C30 - 0x07004C70 +static const Vtx intro_seg7_vertex_07004C30[] = { + {{{ 134, 192, -362}, 0, { -960, 416}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 134, 336, -121}, 0, { -960, 416}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -55, 321, -439}, 0, { -1312, 576}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -55, 465, -197}, 0, { -1312, 576}, {0x4a, 0x4a, 0x4a, 0xff}}}, +}; + +// 0x07004C70 - 0x07004CB0 +static const Vtx intro_seg7_vertex_07004C70[] = { + {{{ 256, 545, -245}, 0, { -1216, 64}, {0xd1, 0xd1, 0xd1, 0xff}}}, + {{{ 134, 336, -121}, 0, { -960, 416}, {0xd1, 0xd1, 0xd1, 0xff}}}, + {{{ 256, 401, -487}, 0, { -1216, 64}, {0xd1, 0xd1, 0xd1, 0xff}}}, + {{{ 134, 192, -362}, 0, { -960, 416}, {0xd1, 0xd1, 0xd1, 0xff}}}, +}; + +// 0x07004CB0 - 0x07004CF0 +static const Vtx intro_seg7_vertex_07004CB0[] = { + {{{ -55, 321, -439}, 0, { -1312, 576}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -55, 465, -197}, 0, { -1312, 576}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 83, 451, -517}, 0, { -1440, 256}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 83, 596, -274}, 0, { -1440, 256}, {0x4a, 0x4a, 0x4a, 0xff}}}, +}; + +// 0x07004CF0 - 0x07004D30 +static const Vtx intro_seg7_vertex_07004CF0[] = { + {{{ -362, 706, -670}, 0, { -2208, 704}, {0xc0, 0xc0, 0xc0, 0xff}}}, + {{{ -354, 779, -382}, 0, { -2080, 736}, {0xc0, 0xc0, 0xc0, 0xff}}}, + {{{ -355, 633, -626}, 0, { -2080, 736}, {0xc0, 0xc0, 0xc0, 0xff}}}, + {{{ -361, 851, -425}, 0, { -2208, 704}, {0xc0, 0xc0, 0xc0, 0xff}}}, +}; + +// 0x07004D30 - 0x07004D70 +static const Vtx intro_seg7_vertex_07004D30[] = { + {{{ -296, 215, -376}, 0, { -1312, 1024}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -292, 464, -197}, 0, { -1504, 928}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -293, 320, -439}, 0, { -1504, 928}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -295, 359, -134}, 0, { -1312, 1024}, {0x4a, 0x4a, 0x4a, 0xff}}}, +}; + +// 0x07004D70 - 0x07004DB0 +static const Vtx intro_seg7_vertex_07004D70[] = { + {{{ -279, 640, -631}, 0, { -2016, 640}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -279, 785, -386}, 0, { -2016, 640}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -271, 695, -663}, 0, { -2112, 576}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -270, 840, -419}, 0, { -2112, 576}, {0x4a, 0x4a, 0x4a, 0xff}}}, +}; + +// 0x07004DB0 - 0x07004E10 +static const Vtx intro_seg7_vertex_07004DB0[] = { + {{{ -326, 636, -628}, 0, { -2048, 704}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -355, 633, -626}, 0, { -2080, 736}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -336, 780, -383}, 0, { -2080, 704}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -279, 785, -386}, 0, { -2016, 640}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -279, 640, -631}, 0, { -2016, 640}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -354, 779, -382}, 0, { -2080, 736}, {0x4a, 0x4a, 0x4a, 0xff}}}, +}; + +// 0x07004E10 - 0x07004E50 +static const Vtx intro_seg7_vertex_07004E10[] = { + {{{ 2, 630, -624}, 0, { -1792, 224}, {0xc0, 0xc0, 0xc0, 0xff}}}, + {{{ 3, 775, -380}, 0, { -1792, 224}, {0xc0, 0xc0, 0xc0, 0xff}}}, + {{{ 12, 317, -437}, 0, { -1248, 480}, {0xc0, 0xc0, 0xc0, 0xff}}}, + {{{ 13, 461, -195}, 0, { -1248, 480}, {0xc0, 0xc0, 0xc0, 0xff}}}, +}; + +// 0x07004E50 - 0x07004E90 +static const Vtx intro_seg7_vertex_07004E50[] = { + {{{ -97, 694, -662}, 0, { -1984, 320}, {0xc0, 0xc0, 0xc0, 0xff}}}, + {{{ -97, 839, -418}, 0, { -1984, 320}, {0xc0, 0xc0, 0xc0, 0xff}}}, + {{{ -100, 633, -626}, 0, { -1888, 384}, {0xc0, 0xc0, 0xc0, 0xff}}}, + {{{ -99, 778, -382}, 0, { -1888, 384}, {0xc0, 0xc0, 0xc0, 0xff}}}, +}; + +// 0x07004E90 - 0x07004ED0 +static const Vtx intro_seg7_vertex_07004E90[] = { + {{{ -271, 695, -663}, 0, { -2112, 576}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -270, 840, -419}, 0, { -2112, 576}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -97, 694, -662}, 0, { -1984, 320}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -97, 839, -418}, 0, { -1984, 320}, {0x4a, 0x4a, 0x4a, 0xff}}}, +}; + +// 0x07004ED0 - 0x07004F10 +static const Vtx intro_seg7_vertex_07004ED0[] = { + {{{ -100, 633, -626}, 0, { -1888, 384}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -99, 778, -382}, 0, { -1888, 384}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 2, 630, -624}, 0, { -1792, 224}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 3, 775, -380}, 0, { -1792, 224}, {0x4a, 0x4a, 0x4a, 0xff}}}, +}; + +// 0x07004F10 - 0x07004F50 +static const Vtx intro_seg7_vertex_07004F10[] = { + {{{ -83, 314, -436}, 0, { -1312, 640}, {0xc0, 0xc0, 0xc0, 0xff}}}, + {{{ -82, 459, -193}, 0, { -1312, 640}, {0xc0, 0xc0, 0xc0, 0xff}}}, + {{{ -84, 210, -373}, 0, { -1152, 736}, {0xc0, 0xc0, 0xc0, 0xff}}}, + {{{ -83, 354, -131}, 0, { -1152, 736}, {0xc0, 0xc0, 0xc0, 0xff}}}, +}; + +// 0x07004F50 - 0x07004F90 +static const Vtx intro_seg7_vertex_07004F50[] = { + {{{ 13, 461, -195}, 0, { -1248, 480}, {0x95, 0x95, 0x95, 0xff}}}, + {{{ -82, 459, -193}, 0, { -1312, 640}, {0x95, 0x95, 0x95, 0xff}}}, + {{{ 12, 317, -437}, 0, { -1248, 480}, {0x95, 0x95, 0x95, 0xff}}}, + {{{ -83, 314, -436}, 0, { -1312, 640}, {0x95, 0x95, 0x95, 0xff}}}, +}; + +// 0x07004F90 - 0x07004FD0 +static const Vtx intro_seg7_vertex_07004F90[] = { + {{{ -83, 354, -131}, 0, { -1152, 736}, {0x95, 0x95, 0x95, 0xff}}}, + {{{ -295, 359, -134}, 0, { -1312, 1024}, {0x95, 0x95, 0x95, 0xff}}}, + {{{ -84, 210, -373}, 0, { -1152, 736}, {0x95, 0x95, 0x95, 0xff}}}, + {{{ -296, 215, -376}, 0, { -1312, 1024}, {0x95, 0x95, 0x95, 0xff}}}, +}; + +// 0x07004FD0 - 0x07005010 +static const Vtx intro_seg7_vertex_07004FD0[] = { + {{{ -576, 324, -441}, 0, { -1728, 1344}, {0x95, 0x95, 0x95, 0xff}}}, + {{{ -580, 466, -197}, 0, { -1728, 1376}, {0x95, 0x95, 0x95, 0xff}}}, + {{{ -581, 321, -440}, 0, { -1728, 1376}, {0x95, 0x95, 0x95, 0xff}}}, + {{{ -576, 468, -199}, 0, { -1728, 1344}, {0x95, 0x95, 0x95, 0xff}}}, +}; + +// 0x07005010 - 0x07005050 +static const Vtx intro_seg7_vertex_07005010[] = { + {{{ -593, 222, -380}, 0, { -1568, 1472}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -592, 366, -139}, 0, { -1568, 1472}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -576, 324, -441}, 0, { -1728, 1344}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -576, 468, -199}, 0, { -1728, 1344}, {0x4a, 0x4a, 0x4a, 0xff}}}, +}; + +// 0x07005050 - 0x07005090 +static const Vtx intro_seg7_vertex_07005050[] = { + {{{ -292, 464, -197}, 0, { -1504, 928}, {0x95, 0x95, 0x95, 0xff}}}, + {{{ -361, 478, -205}, 0, { -1568, 1024}, {0x95, 0x95, 0x95, 0xff}}}, + {{{ -293, 320, -439}, 0, { -1504, 928}, {0x95, 0x95, 0x95, 0xff}}}, + {{{ -364, 334, -447}, 0, { -1568, 1024}, {0x95, 0x95, 0x95, 0xff}}}, +}; + +// 0x07005090 - 0x070050D0 +static const Vtx intro_seg7_vertex_07005090[] = { + {{{ -357, 362, -136}, 0, { -1376, 1120}, {0x95, 0x95, 0x95, 0xff}}}, + {{{ -592, 366, -139}, 0, { -1568, 1472}, {0x95, 0x95, 0x95, 0xff}}}, + {{{ -357, 218, -378}, 0, { -1376, 1120}, {0x95, 0x95, 0x95, 0xff}}}, + {{{ -593, 222, -380}, 0, { -1568, 1472}, {0x95, 0x95, 0x95, 0xff}}}, +}; + +// 0x070050D0 - 0x07005110 +static const Vtx intro_seg7_vertex_070050D0[] = { + {{{ -361, 478, -205}, 0, { -1568, 1024}, {0xc0, 0xc0, 0xc0, 0xff}}}, + {{{ -357, 362, -136}, 0, { -1376, 1120}, {0xc0, 0xc0, 0xc0, 0xff}}}, + {{{ -364, 334, -447}, 0, { -1568, 1024}, {0xc0, 0xc0, 0xc0, 0xff}}}, + {{{ -357, 218, -378}, 0, { -1376, 1120}, {0xc0, 0xc0, 0xc0, 0xff}}}, +}; + +// 0x07005110 - 0x07005150 +static const Vtx intro_seg7_vertex_07005110[] = { + {{{ -612, 506, -551}, 0, { -2048, 1248}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -612, 651, -307}, 0, { -2048, 1248}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -575, 643, -632}, 0, { -2272, 1056}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -574, 788, -388}, 0, { -2272, 1056}, {0x4a, 0x4a, 0x4a, 0xff}}}, +}; + +// 0x07005150 - 0x07005190 +static const Vtx intro_seg7_vertex_07005150[] = { + {{{ -642, 487, -539}, 0, { -2048, 1312}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -641, 632, -296}, 0, { -2048, 1312}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -604, 504, -549}, 0, { -2048, 1248}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -603, 649, -306}, 0, { -2048, 1216}, {0x4a, 0x4a, 0x4a, 0xff}}}, +}; + +// 0x07005190 - 0x070051D0 +static const Vtx intro_seg7_vertex_07005190[] = { + {{{ -580, 466, -197}, 0, { -1728, 1376}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -641, 632, -296}, 0, { -2048, 1312}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -581, 321, -440}, 0, { -1728, 1376}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -642, 487, -539}, 0, { -2048, 1312}, {0x4a, 0x4a, 0x4a, 0xff}}}, +}; + +// 0x070051D0 - 0x07005210 +static const Vtx intro_seg7_vertex_070051D0[] = { + {{{ -603, 649, -306}, 0, { -2048, 1216}, {0x95, 0x95, 0x95, 0xff}}}, + {{{ -612, 651, -307}, 0, { -2048, 1248}, {0x95, 0x95, 0x95, 0xff}}}, + {{{ -604, 504, -549}, 0, { -2048, 1248}, {0x95, 0x95, 0x95, 0xff}}}, + {{{ -612, 506, -551}, 0, { -2048, 1248}, {0x95, 0x95, 0x95, 0xff}}}, +}; + +// 0x07005210 - 0x07005250 +static const Vtx intro_seg7_vertex_07005210[] = { + {{{ -542, 641, -631}, 0, { -2240, 1024}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -547, 803, -397}, 0, { -2272, 1024}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -548, 658, -641}, 0, { -2272, 1024}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -541, 786, -387}, 0, { -2240, 1024}, {0x4a, 0x4a, 0x4a, 0xff}}}, +}; + +// 0x07005250 - 0x07005290 +static const Vtx intro_seg7_vertex_07005250[] = { + {{{ -575, 643, -632}, 0, { -2272, 1056}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -574, 788, -388}, 0, { -2272, 1056}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -542, 641, -631}, 0, { -2240, 1024}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -541, 786, -387}, 0, { -2240, 1024}, {0x4a, 0x4a, 0x4a, 0xff}}}, +}; + +// 0x07005290 - 0x070052D0 +static const Vtx intro_seg7_vertex_07005290[] = { + {{{ -547, 803, -397}, 0, { -2272, 1024}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -361, 851, -425}, 0, { -2208, 704}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -548, 658, -641}, 0, { -2272, 1024}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -362, 706, -670}, 0, { -2208, 704}, {0x4a, 0x4a, 0x4a, 0xff}}}, +}; + +// 0x070052D0 - 0x07005310 +static const Vtx intro_seg7_vertex_070052D0[] = { + {{{ 593, 100, -307}, 0, { -448, -160}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 593, 243, -67}, 0, { -448, -160}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 644, 179, -355}, 0, { -512, -288}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 644, 322, -115}, 0, { -544, -288}, {0x4a, 0x4a, 0x4a, 0xff}}}, +}; + +// 0x07005310 - 0x07005350 +static const Vtx intro_seg7_vertex_07005310[] = { + {{{ 904, -92, -192}, 0, { 96, -448}, {0x95, 0x95, 0x95, 0xff}}}, + {{{ 812, 77, 31}, 0, { 0, -320}, {0x95, 0x95, 0x95, 0xff}}}, + {{{ 811, -65, -208}, 0, { 0, -320}, {0x95, 0x95, 0x95, 0xff}}}, + {{{ 904, 50, 47}, 0, { 96, -448}, {0x95, 0x95, 0x95, 0xff}}}, +}; + +// 0x07005350 - 0x07005390 +static const Vtx intro_seg7_vertex_07005350[] = { + {{{ 833, 176, -353}, 0, { -384, -576}, {0xc0, 0xc0, 0xc0, 0xff}}}, + {{{ 833, 319, -113}, 0, { -384, -576}, {0xc0, 0xc0, 0xc0, 0xff}}}, + {{{ 817, 128, -324}, 0, { -320, -512}, {0xc0, 0xc0, 0xc0, 0xff}}}, + {{{ 817, 271, -84}, 0, { -320, -512}, {0xc0, 0xc0, 0xc0, 0xff}}}, +}; + +// 0x07005390 - 0x070053D0 +static const Vtx intro_seg7_vertex_07005390[] = { + {{{ 644, 322, -115}, 0, { -544, -288}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 833, 176, -353}, 0, { -384, -576}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 644, 179, -355}, 0, { -512, -288}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 833, 319, -113}, 0, { -384, -576}, {0x4a, 0x4a, 0x4a, 0xff}}}, +}; + +// 0x070053D0 - 0x07005410 +static const Vtx intro_seg7_vertex_070053D0[] = { + {{{ 817, 271, -84}, 0, { -320, -512}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 952, 278, -88}, 0, { -224, -704}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 817, 128, -324}, 0, { -320, -512}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 952, 135, -328}, 0, { -224, -704}, {0x4a, 0x4a, 0x4a, 0xff}}}, +}; + +// 0x07005410 - 0x07005450 +static const Vtx intro_seg7_vertex_07005410[] = { + {{{ 952, 135, -328}, 0, { -224, -704}, {0xc0, 0xc0, 0xc0, 0xff}}}, + {{{ 952, 278, -88}, 0, { -224, -704}, {0xc0, 0xc0, 0xc0, 0xff}}}, + {{{ 904, -92, -192}, 0, { 96, -448}, {0xc0, 0xc0, 0xc0, 0xff}}}, + {{{ 904, 50, 47}, 0, { 96, -448}, {0xc0, 0xc0, 0xc0, 0xff}}}, +}; + +// 0x07005450 - 0x07005490 +static const Vtx intro_seg7_vertex_07005450[] = { + {{{ 514, 174, -26}, 0, { -384, 0}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 593, 243, -67}, 0, { -448, -160}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 514, 31, -266}, 0, { -384, 0}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 593, 100, -307}, 0, { -448, -160}, {0x4a, 0x4a, 0x4a, 0xff}}}, +}; + +// 0x07005490 - 0x070054D0 +static const Vtx intro_seg7_vertex_07005490[] = { + {{{ 514, 174, -26}, 0, { -384, 0}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 514, 31, -266}, 0, { -384, 0}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 593, 42, 52}, 0, { -96, 0}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 593, -100, -187}, 0, { -96, 0}, {0x4a, 0x4a, 0x4a, 0xff}}}, +}; + +// 0x070054D0 - 0x07005510 +static const Vtx intro_seg7_vertex_070054D0[] = { + {{{ 593, -100, -187}, 0, { -96, 0}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 585, -125, -172}, 0, { -64, 32}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 593, 42, 52}, 0, { -96, 0}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 585, 17, 67}, 0, { -64, 32}, {0x4a, 0x4a, 0x4a, 0xff}}}, +}; + +// 0x07005510 - 0x07005550 +static const Vtx intro_seg7_vertex_07005510[] = { + {{{ 585, -125, -172}, 0, { -64, 32}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 444, -262, -90}, 0, { 32, 352}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 585, 17, 67}, 0, { -64, 32}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 444, -120, 149}, 0, { 32, 352}, {0x4a, 0x4a, 0x4a, 0x00}}}, +}; + +// 0x07005550 - 0x07005590 +static const Vtx intro_seg7_vertex_07005550[] = { + {{{ 444, -262, -90}, 0, { 32, 352}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 628, -353, -35}, 0, { 320, 192}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 444, -120, 149}, 0, { 32, 352}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 626, -211, 204}, 0, { 320, 192}, {0x4a, 0x4a, 0x4a, 0xff}}}, +}; + +// 0x07005590 - 0x070055D0 +static const Vtx intro_seg7_vertex_07005590[] = { + {{{ 678, -286, -75}, 0, { 256, 32}, {0xd1, 0xd1, 0xd1, 0xff}}}, + {{{ 678, -144, 164}, 0, { 256, 32}, {0xd1, 0xd1, 0xd1, 0xff}}}, + {{{ 628, -353, -35}, 0, { 320, 192}, {0xd1, 0xd1, 0xd1, 0xff}}}, + {{{ 626, -211, 204}, 0, { 320, 192}, {0xd1, 0xd1, 0xd1, 0xff}}}, +}; + +// 0x070055D0 - 0x07005610 +static const Vtx intro_seg7_vertex_070055D0[] = { + {{{ 678, -286, -75}, 0, { 256, 32}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 811, -381, -19}, 0, { 512, -32}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 678, -144, 164}, 0, { 256, 32}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 812, -238, 220}, 0, { 512, -32}, {0x4a, 0x4a, 0x4a, 0xff}}}, +}; + +// 0x07005610 - 0x07005650 +static const Vtx intro_seg7_vertex_07005610[] = { + {{{ 1041, -223, -114}, 0, { 448, -512}, {0xd1, 0xd1, 0xd1, 0xff}}}, + {{{ 1041, -80, 125}, 0, { 416, -512}, {0xd1, 0xd1, 0xd1, 0xff}}}, + {{{ 811, -381, -19}, 0, { 512, -32}, {0xd1, 0xd1, 0xd1, 0xff}}}, + {{{ 812, -238, 220}, 0, { 512, -32}, {0xd1, 0xd1, 0xd1, 0xff}}}, +}; + +// 0x07005650 - 0x07005690 +static const Vtx intro_seg7_vertex_07005650[] = { + {{{ 811, -123, -173}, 0, { 96, -256}, {0x5e, 0x5e, 0x5e, 0xff}}}, + {{{ 811, 18, 66}, 0, { 96, -256}, {0x5e, 0x5e, 0x5e, 0xff}}}, + {{{ 1041, -223, -114}, 0, { 448, -512}, {0x5e, 0x5e, 0x5e, 0xff}}}, + {{{ 1041, -80, 125}, 0, { 416, -512}, {0x5e, 0x5e, 0x5e, 0xff}}}, +}; + +// 0x07005690 - 0x070056D0 +static const Vtx intro_seg7_vertex_07005690[] = { + {{{ 812, 77, 31}, 0, { 0, -320}, {0xc0, 0xc0, 0xc0, 0xff}}}, + {{{ 811, 18, 66}, 0, { 96, -256}, {0xc0, 0xc0, 0xc0, 0xff}}}, + {{{ 811, -65, -208}, 0, { 0, -320}, {0xc0, 0xc0, 0xc0, 0xff}}}, + {{{ 811, -123, -173}, 0, { 96, -256}, {0xc0, 0xc0, 0xc0, 0xff}}}, +}; + +// 0x070056D0 - 0x07005710 +static const Vtx intro_seg7_vertex_070056D0[] = { + {{{ 585, 1, -248}, 0, { -256, -32}, {0xc0, 0xc0, 0xc0, 0xff}}}, + {{{ 528, 54, 44}, 0, { -160, 96}, {0xc0, 0xc0, 0xc0, 0xff}}}, + {{{ 528, -88, -194}, 0, { -160, 96}, {0xc0, 0xc0, 0xc0, 0xff}}}, + {{{ 585, 144, -8}, 0, { -288, -32}, {0xc0, 0xc0, 0xc0, 0xff}}}, +}; + +// 0x07005710 - 0x07005750 +static const Vtx intro_seg7_vertex_07005710[] = { + {{{ 528, -88, -194}, 0, { -160, 96}, {0xc0, 0xc0, 0xc0, 0xff}}}, + {{{ 528, 54, 44}, 0, { -160, 96}, {0xc0, 0xc0, 0xc0, 0xff}}}, + {{{ 579, -184, -137}, 0, { 0, 96}, {0xc0, 0xc0, 0xc0, 0xff}}}, + {{{ 579, -41, 102}, 0, { 0, 96}, {0xc0, 0xc0, 0xc0, 0xff}}}, +}; + +// 0x07005750 - 0x07005790 +static const Vtx intro_seg7_vertex_07005750[] = { + {{{ 571, 149, -11}, 0, { -288, -32}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 585, 144, -8}, 0, { -288, -32}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 572, 7, -251}, 0, { -288, -32}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 585, 1, -248}, 0, { -256, -32}, {0x4a, 0x4a, 0x4a, 0xff}}}, +}; + +// 0x07005790 - 0x070057D0 +static const Vtx intro_seg7_vertex_07005790[] = { + {{{ 579, -41, 102}, 0, { 0, 96}, {0x9a, 0x9a, 0x9a, 0xff}}}, + {{{ 507, -59, 113}, 0, { 0, 224}, {0x9a, 0x9a, 0x9a, 0xff}}}, + {{{ 579, -184, -137}, 0, { 0, 96}, {0x9a, 0x9a, 0x9a, 0xff}}}, + {{{ 512, -201, -127}, 0, { 0, 224}, {0x9a, 0x9a, 0x9a, 0xff}}}, +}; + +// 0x070057D0 - 0x07005810 +static const Vtx intro_seg7_vertex_070057D0[] = { + {{{ 512, -201, -127}, 0, { 0, 224}, {0xc0, 0xc0, 0xc0, 0xff}}}, + {{{ 507, -59, 113}, 0, { 0, 224}, {0xc0, 0xc0, 0xc0, 0xff}}}, + {{{ 531, -310, -61}, 0, { 192, 288}, {0xc0, 0xc0, 0xc0, 0xff}}}, + {{{ 531, -167, 178}, 0, { 192, 288}, {0xc0, 0xc0, 0xc0, 0xff}}}, +}; + +// 0x07005810 - 0x07005850 +static const Vtx intro_seg7_vertex_07005810[] = { + {{{ 531, -167, 178}, 0, { 192, 288}, {0x9a, 0x9a, 0x9a, 0xff}}}, + {{{ 170, -153, 169}, 0, { -96, 800}, {0x9a, 0x9a, 0x9a, 0xff}}}, + {{{ 531, -310, -61}, 0, { 192, 288}, {0x9a, 0x9a, 0x9a, 0xff}}}, + {{{ 170, -296, -70}, 0, { -96, 800}, {0x9a, 0x9a, 0x9a, 0xff}}}, +}; + +// 0x07005850 - 0x07005890 +static const Vtx intro_seg7_vertex_07005850[] = { + {{{ 170, -153, 169}, 0, { -96, 800}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 151, 276, -87}, 0, { -832, 448}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 170, -296, -70}, 0, { -96, 800}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 151, 133, -327}, 0, { -832, 448}, {0x4a, 0x4a, 0x4a, 0xff}}}, +}; + +// 0x07005890 - 0x070058D0 +static const Vtx intro_seg7_vertex_07005890[] = { + {{{ 151, 276, -87}, 0, { -832, 448}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 605, 348, -130}, 0, { -608, -256}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 151, 133, -327}, 0, { -832, 448}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 605, 205, -370}, 0, { -608, -256}, {0x4a, 0x4a, 0x4a, 0xff}}}, +}; + +// 0x070058D0 - 0x07005910 +static const Vtx intro_seg7_vertex_070058D0[] = { + {{{ 571, 149, -11}, 0, { -288, -32}, {0xc0, 0xc0, 0xc0, 0xff}}}, + {{{ 572, 7, -251}, 0, { -288, -32}, {0xc0, 0xc0, 0xc0, 0xff}}}, + {{{ 605, 205, -370}, 0, { -608, -256}, {0xc0, 0xc0, 0xc0, 0xff}}}, + {{{ 605, 348, -130}, 0, { -608, -256}, {0xc0, 0xc0, 0xc0, 0xff}}}, +}; + +// 0x07005910 - 0x07005970 +static const Vtx intro_seg7_vertex_07005910[] = { + {{{ -789, 181, -29}, 0, { -1408, 1920}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -782, 384, -149}, 0, { -1760, 1728}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -789, 39, -268}, 0, { -1408, 1920}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -789, 39, -268}, 0, { -1408, 1920}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -782, 384, -149}, 0, { -1760, 1728}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -782, 242, -390}, 0, { -1760, 1728}, {0x4a, 0x4a, 0x4a, 0xff}}}, +}; + +// 0x07005970 - 0x070059B0 +static const Vtx intro_seg7_vertex_07005970[] = { + {{{ -303, 20, -257}, 0, { -992, 1216}, {0xc0, 0xc0, 0xc0, 0xff}}}, + {{{ -368, -147, 164}, 0, { -512, 1600}, {0xc0, 0xc0, 0xc0, 0xff}}}, + {{{ -368, -288, -72}, 0, { -512, 1600}, {0xc0, 0xc0, 0xc0, 0xff}}}, + {{{ -303, 162, -18}, 0, { -992, 1216}, {0xc0, 0xc0, 0xc0, 0xff}}}, +}; + +// 0x070059B0 - 0x070059F0 +static const Vtx intro_seg7_vertex_070059B0[] = { + {{{ -312, 205, -368}, 0, { -1312, 1056}, {0xc0, 0xc0, 0xc0, 0xff}}}, + {{{ -363, 173, -25}, 0, { -1056, 1312}, {0xc0, 0xc0, 0xc0, 0xff}}}, + {{{ -363, 31, -263}, 0, { -1056, 1312}, {0xc0, 0xc0, 0xc0, 0xff}}}, + {{{ -312, 348, -128}, 0, { -1312, 1056}, {0xc0, 0xc0, 0xc0, 0xff}}}, +}; + +// 0x070059F0 - 0x07005A30 +static const Vtx intro_seg7_vertex_070059F0[] = { + {{{ -363, 173, -25}, 0, { -1056, 1312}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -303, 162, -18}, 0, { -992, 1216}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -363, 31, -263}, 0, { -1056, 1312}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -303, 20, -257}, 0, { -992, 1216}, {0x4a, 0x4a, 0x4a, 0xff}}}, +}; + +// 0x07005A30 - 0x07005A60 +static const Vtx intro_seg7_vertex_07005A30[] = { + {{{ -782, 384, -149}, 0, { -1760, 1728}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -312, 348, -128}, 0, { -1312, 1056}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -782, 242, -390}, 0, { -1760, 1728}, {0x4a, 0x4a, 0x4a, 0xff}}}, +}; + +// 0x07005A60 - 0x07005A90 +static const Vtx intro_seg7_vertex_07005A60[] = { + {{{ -312, 348, -128}, 0, { -1312, 1056}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -312, 205, -368}, 0, { -1312, 1056}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -782, 242, -390}, 0, { -1760, 1728}, {0x4a, 0x4a, 0x4a, 0xff}}}, +}; + +// 0x07005A90 - 0x07005AF0 +static const Vtx intro_seg7_vertex_07005A90[] = { + {{{ -746, 185, -32}, 0, { -1376, 1856}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -756, 42, -270}, 0, { -1376, 1888}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -775, 51, 46}, 0, { -1184, 2016}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -777, -89, -192}, 0, { -1184, 2016}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -775, 51, 46}, 0, { -1184, 2016}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -756, 42, -270}, 0, { -1376, 1888}, {0x4a, 0x4a, 0x4a, 0xff}}}, +}; + +// 0x07005AF0 - 0x07005B50 +static const Vtx intro_seg7_vertex_07005AF0[] = { + {{{ -746, 185, -32}, 0, { -1376, 1856}, {0x95, 0x95, 0x95, 0xff}}}, + {{{ -789, 181, -29}, 0, { -1408, 1920}, {0x95, 0x95, 0x95, 0xff}}}, + {{{ -756, 42, -270}, 0, { -1376, 1888}, {0x95, 0x95, 0x95, 0xff}}}, + {{{ -789, 39, -268}, 0, { -1408, 1920}, {0x95, 0x95, 0x95, 0xff}}}, + {{{ -756, 42, -270}, 0, { -1376, 1888}, {0x95, 0x95, 0x95, 0xff}}}, + {{{ -789, 181, -29}, 0, { -1408, 1920}, {0x95, 0x95, 0x95, 0xff}}}, +}; + +// 0x07005B50 - 0x07005B90 +static const Vtx intro_seg7_vertex_07005B50[] = { + {{{ -775, 51, 46}, 0, { -1184, 2016}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -777, -89, -192}, 0, { -1184, 2016}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -888, 45, 50}, 0, { -1248, 2176}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -890, -95, -188}, 0, { -1248, 2208}, {0x4a, 0x4a, 0x4a, 0xff}}}, +}; + +// 0x07005B90 - 0x07005BD0 +static const Vtx intro_seg7_vertex_07005B90[] = { + {{{ -888, 45, 50}, 0, { -1248, 2176}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -890, -95, -188}, 0, { -1248, 2208}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -900, -313, -57}, 0, { -896, 2400}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -898, -173, 180}, 0, { -896, 2400}, {0x4a, 0x4a, 0x4a, 0xff}}}, +}; + +// 0x07005BD0 - 0x07005C10 +static const Vtx intro_seg7_vertex_07005BD0[] = { + {{{ -604, -199, 194}, 0, { -608, 1984}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -667, -97, 135}, 0, { -832, 1984}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -604, -340, -41}, 0, { -608, 1984}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -668, -238, -102}, 0, { -832, 1984}, {0x4a, 0x4a, 0x4a, 0xff}}}, +}; + +// 0x07005C10 - 0x07005C50 +static const Vtx intro_seg7_vertex_07005C10[] = { + {{{ -667, -97, 135}, 0, { -832, 1984}, {0x95, 0x95, 0x95, 0xff}}}, + {{{ -898, -173, 180}, 0, { -896, 2400}, {0x95, 0x95, 0x95, 0xff}}}, + {{{ -668, -238, -102}, 0, { -832, 1984}, {0x95, 0x95, 0x95, 0xff}}}, + {{{ -900, -313, -57}, 0, { -896, 2400}, {0x95, 0x95, 0x95, 0xff}}}, +}; + +// 0x07005C50 - 0x07005C90 +static const Vtx intro_seg7_vertex_07005C50[] = { + {{{ -368, -288, -72}, 0, { -512, 1600}, {0xc0, 0xc0, 0xc0, 0xff}}}, + {{{ -368, -147, 164}, 0, { -512, 1600}, {0xc0, 0xc0, 0xc0, 0xff}}}, + {{{ -604, -340, -41}, 0, { -608, 1984}, {0xc0, 0xc0, 0xc0, 0xff}}}, + {{{ -604, -199, 194}, 0, { -608, 1984}, {0xc0, 0xc0, 0xc0, 0xff}}}, +}; + +// 0x07005C90 - 0x07005CD0 +static const Vtx intro_seg7_vertex_07005C90[] = { + {{{ 101, -291, -73}, 0, { -160, 896}, {0x95, 0x95, 0x95, 0xff}}}, + {{{ 101, -148, 166}, 0, { -160, 896}, {0x95, 0x95, 0x95, 0xff}}}, + {{{ -182, -288, -75}, 0, { -384, 1312}, {0x95, 0x95, 0x95, 0xff}}}, + {{{ -182, -145, 164}, 0, { -384, 1312}, {0x95, 0x95, 0x95, 0xff}}}, +}; + +// 0x07005CD0 - 0x07005D10 +static const Vtx intro_seg7_vertex_07005CD0[] = { + {{{ -154, -231, -109}, 0, { -448, 1216}, {0xd1, 0xd1, 0xd1, 0xff}}}, + {{{ -276, -175, 182}, 0, { -416, 1472}, {0xd1, 0xd1, 0xd1, 0xff}}}, + {{{ -276, -318, -57}, 0, { -416, 1472}, {0xd1, 0xd1, 0xd1, 0xff}}}, + {{{ -151, -80, 125}, 0, { -480, 1216}, {0xd1, 0xd1, 0xd1, 0xff}}}, +}; + +// 0x07005D10 - 0x07005D50 +static const Vtx intro_seg7_vertex_07005D10[] = { + {{{ 164, 69, -289}, 0, { -704, 480}, {0xc0, 0xc0, 0xc0, 0xff}}}, + {{{ 164, 212, -49}, 0, { -704, 480}, {0xc0, 0xc0, 0xc0, 0xff}}}, + {{{ 101, -291, -73}, 0, { -160, 896}, {0xc0, 0xc0, 0xc0, 0xff}}}, + {{{ 101, -148, 166}, 0, { -160, 896}, {0xc0, 0xc0, 0xc0, 0xff}}}, +}; + +// 0x07005D50 - 0x07005D90 +static const Vtx intro_seg7_vertex_07005D50[] = { + {{{ 95, 87, -299}, 0, { -800, 576}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 164, 212, -49}, 0, { -704, 480}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 164, 69, -289}, 0, { -704, 480}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 95, 230, -60}, 0, { -800, 576}, {0x4a, 0x4a, 0x4a, 0xff}}}, +}; + +// 0x07005D90 - 0x07005DD0 +static const Vtx intro_seg7_vertex_07005D90[] = { + {{{ 137, 295, -99}, 0, { -864, 448}, {0xc0, 0xc0, 0xc0, 0xff}}}, + {{{ 95, 230, -60}, 0, { -800, 576}, {0xc0, 0xc0, 0xc0, 0xff}}}, + {{{ 137, 153, -339}, 0, { -864, 448}, {0xc0, 0xc0, 0xc0, 0xff}}}, + {{{ 95, 87, -299}, 0, { -800, 576}, {0xc0, 0xc0, 0xc0, 0xff}}}, +}; + +// 0x07005DD0 - 0x07005E10 +static const Vtx intro_seg7_vertex_07005DD0[] = { + {{{ 137, 295, -99}, 0, { -864, 448}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 137, 153, -339}, 0, { -864, 448}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -100, 178, -354}, 0, { -1120, 768}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -100, 321, -114}, 0, { -1120, 768}, {0x4a, 0x4a, 0x4a, 0xff}}}, +}; + +// 0x07005E10 - 0x07005E50 +static const Vtx intro_seg7_vertex_07005E10[] = { + {{{ -121, 275, -87}, 0, { -1056, 864}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -100, 321, -114}, 0, { -1120, 768}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -100, 178, -354}, 0, { -1120, 768}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -121, 132, -326}, 0, { -1056, 864}, {0x4a, 0x4a, 0x4a, 0xff}}}, +}; + +// 0x07005E50 - 0x07005E90 +static const Vtx intro_seg7_vertex_07005E50[] = { + {{{ -226, 291, -96}, 0, { -1152, 992}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -121, 275, -87}, 0, { -1056, 864}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -121, 132, -326}, 0, { -1056, 864}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -226, 148, -336}, 0, { -1152, 992}, {0x4a, 0x4a, 0x4a, 0xff}}}, +}; + +// 0x07005E90 - 0x07005ED0 +static const Vtx intro_seg7_vertex_07005E90[] = { + {{{ -322, 124, 3}, 0, { -960, 1280}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -226, 291, -96}, 0, { -1152, 992}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -226, 148, -336}, 0, { -1152, 992}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -322, -18, -236}, 0, { -960, 1280}, {0x4a, 0x4a, 0x4a, 0xff}}}, +}; + +// 0x07005ED0 - 0x07005F10 +static const Vtx intro_seg7_vertex_07005ED0[] = { + {{{ -238, 118, 6}, 0, { -864, 1152}, {0xd1, 0xd1, 0xd1, 0xff}}}, + {{{ -322, 124, 3}, 0, { -960, 1280}, {0xd1, 0xd1, 0xd1, 0xff}}}, + {{{ -233, -16, -237}, 0, { -896, 1152}, {0xd1, 0xd1, 0xd1, 0xff}}}, + {{{ -322, -18, -236}, 0, { -960, 1280}, {0xd1, 0xd1, 0xd1, 0xff}}}, +}; + +// 0x07005F10 - 0x07005F50 +static const Vtx intro_seg7_vertex_07005F10[] = { + {{{ -396, 49, 48}, 0, { -864, 1472}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -238, 118, 6}, 0, { -864, 1152}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -233, -16, -237}, 0, { -896, 1152}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -396, -93, -191}, 0, { -864, 1472}, {0x4a, 0x4a, 0x4a, 0xff}}}, +}; + +// 0x07005F50 - 0x07005F90 +static const Vtx intro_seg7_vertex_07005F50[] = { + {{{ -276, -175, 182}, 0, { -416, 1472}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -396, 49, 48}, 0, { -864, 1472}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -396, -93, -191}, 0, { -864, 1472}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -276, -318, -57}, 0, { -416, 1472}, {0x4a, 0x4a, 0x4a, 0xff}}}, +}; + +// 0x07005F90 - 0x07005FD0 +static const Vtx intro_seg7_vertex_07005F90[] = { + {{{ -151, -80, 125}, 0, { -480, 1216}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -154, -231, -109}, 0, { -448, 1216}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -182, -145, 164}, 0, { -384, 1312}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -182, -288, -75}, 0, { -384, 1312}, {0x4a, 0x4a, 0x4a, 0xff}}}, +}; + +// 0x07005FD0 - 0x07006010 +static const Vtx intro_seg7_vertex_07005FD0[] = { + {{{ -312, 348, -128}, 0, { -1312, 1056}, {0x73, 0x73, 0x73, 0xff}}}, + {{{ -782, 384, -149}, 0, { -1760, 1728}, {0x73, 0x73, 0x73, 0xff}}}, + {{{ -340, 348, -86}, 0, { -1312, 1120}, {0x73, 0x73, 0x73, 0xff}}}, + {{{ -762, 384, -108}, 0, { -1696, 1728}, {0x73, 0x73, 0x73, 0xff}}}, +}; + +// 0x07006010 - 0x07006050 +static const Vtx intro_seg7_vertex_07006010[] = { + {{{ -782, 384, -149}, 0, { -1760, 1728}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -789, 181, -29}, 0, { -1408, 1920}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -762, 384, -108}, 0, { -1696, 1728}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -772, 213, -9}, 0, { -1408, 1888}, {0x4a, 0x4a, 0x4a, 0xff}}}, +}; + +// 0x07006050 - 0x07006090 +static const Vtx intro_seg7_vertex_07006050[] = { + {{{ -789, 181, -29}, 0, { -1408, 1920}, {0xf0, 0xf0, 0xf0, 0xff}}}, + {{{ -746, 185, -32}, 0, { -1376, 1856}, {0xf0, 0xf0, 0xf0, 0xff}}}, + {{{ -772, 213, -9}, 0, { -1408, 1888}, {0xf0, 0xf0, 0xf0, 0xff}}}, + {{{ -733, 215, -8}, 0, { -1408, 1824}, {0xf0, 0xf0, 0xf0, 0xff}}}, +}; + +// 0x07006090 - 0x070060D0 +static const Vtx intro_seg7_vertex_07006090[] = { + {{{ -733, 215, -8}, 0, { -1408, 1824}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -746, 185, -32}, 0, { -1376, 1856}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -762, 61, 82}, 0, { -1152, 2016}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -775, 51, 46}, 0, { -1184, 2016}, {0x4a, 0x4a, 0x4a, 0xff}}}, +}; + +// 0x070060D0 - 0x07006120 +static const Vtx intro_seg7_vertex_070060D0[] = { + {{{ -762, 61, 82}, 0, { -1152, 2016}, {0xff, 0xff, 0xff, 0x01}}}, + {{{ -775, 51, 46}, 0, { -1184, 2016}, {0x73, 0x73, 0x73, 0xff}}}, + {{{ -762, 61, 82}, 0, { -1152, 2016}, {0x73, 0x73, 0x73, 0xff}}}, + {{{ -864, 48, 90}, 0, { -1216, 2176}, {0x73, 0x73, 0x73, 0xff}}}, + {{{ -888, 45, 50}, 0, { -1248, 2176}, {0x73, 0x73, 0x73, 0xff}}}, +}; + +// 0x07006120 - 0x07006160 +static const Vtx intro_seg7_vertex_07006120[] = { + {{{ -898, -173, 180}, 0, { -896, 2400}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -868, -118, 188}, 0, { -928, 2336}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -888, 45, 50}, 0, { -1248, 2176}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -864, 48, 90}, 0, { -1216, 2176}, {0x4a, 0x4a, 0x4a, 0xff}}}, +}; + +// 0x07006160 - 0x070061A0 +static const Vtx intro_seg7_vertex_07006160[] = { + {{{ -604, -199, 194}, 0, { -608, 1984}, {0xff, 0xff, 0xfe, 0xff}}}, + {{{ -368, -147, 164}, 0, { -512, 1600}, {0xff, 0xff, 0xfe, 0xff}}}, + {{{ -594, -160, 213}, 0, { -640, 1952}, {0xff, 0xff, 0xfe, 0xff}}}, + {{{ -388, -113, 185}, 0, { -576, 1600}, {0xff, 0xff, 0xfe, 0xff}}}, +}; + +// 0x070061A0 - 0x070061E0 +static const Vtx intro_seg7_vertex_070061A0[] = { + {{{ -303, 162, -18}, 0, { -992, 1216}, {0xff, 0xff, 0xfe, 0xff}}}, + {{{ -330, 165, 21}, 0, { -992, 1280}, {0xff, 0xff, 0xfe, 0xff}}}, + {{{ -368, -147, 164}, 0, { -512, 1600}, {0xff, 0xff, 0xfe, 0xff}}}, + {{{ -388, -113, 185}, 0, { -576, 1600}, {0xff, 0xff, 0xfe, 0xff}}}, +}; + +// 0x070061E0 - 0x07006220 +static const Vtx intro_seg7_vertex_070061E0[] = { + {{{ -392, 177, 14}, 0, { -1056, 1344}, {0x73, 0x73, 0x73, 0xff}}}, + {{{ -330, 165, 21}, 0, { -992, 1280}, {0x73, 0x73, 0x73, 0xff}}}, + {{{ -363, 173, -25}, 0, { -1056, 1312}, {0x73, 0x73, 0x73, 0xff}}}, + {{{ -303, 162, -18}, 0, { -992, 1216}, {0x73, 0x73, 0x73, 0xff}}}, +}; + +// 0x07006220 - 0x07006260 +static const Vtx intro_seg7_vertex_07006220[] = { + {{{ -312, 348, -128}, 0, { -1312, 1056}, {0xff, 0xff, 0xfe, 0xff}}}, + {{{ -340, 348, -86}, 0, { -1312, 1120}, {0xff, 0xff, 0xfe, 0xff}}}, + {{{ -363, 173, -25}, 0, { -1056, 1312}, {0xff, 0xff, 0xfe, 0xff}}}, + {{{ -392, 177, 14}, 0, { -1056, 1344}, {0xff, 0xff, 0xfe, 0xff}}}, +}; + +// 0x07006260 - 0x070062A0 +static const Vtx intro_seg7_vertex_07006260[] = { + {{{ -898, -173, 180}, 0, { -896, 2400}, {0xf0, 0xf0, 0xf0, 0xff}}}, + {{{ -667, -97, 135}, 0, { -832, 1984}, {0xf0, 0xf0, 0xf0, 0xff}}}, + {{{ -868, -118, 188}, 0, { -928, 2336}, {0xf0, 0xf0, 0xf0, 0xff}}}, + {{{ -664, -64, 156}, 0, { -864, 1984}, {0xf0, 0xf0, 0xf0, 0xff}}}, +}; + +// 0x070062A0 - 0x070062E0 +static const Vtx intro_seg7_vertex_070062A0[] = { + {{{ -664, -64, 156}, 0, { -864, 1984}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -667, -97, 135}, 0, { -832, 1984}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -594, -160, 213}, 0, { -640, 1952}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -604, -199, 194}, 0, { -608, 1984}, {0x4a, 0x4a, 0x4a, 0xff}}}, +}; + +// 0x070062E0 - 0x07006320 +static const Vtx intro_seg7_vertex_070062E0[] = { + {{{ 137, 295, -99}, 0, { -864, 448}, {0x73, 0x73, 0x73, 0xff}}}, + {{{ -100, 321, -114}, 0, { -1120, 768}, {0x73, 0x73, 0x73, 0xff}}}, + {{{ 98, 302, -60}, 0, { -896, 512}, {0x73, 0x73, 0x73, 0xff}}}, + {{{ -85, 319, -74}, 0, { -1056, 768}, {0x73, 0x73, 0x73, 0xff}}}, +}; + +// 0x07006320 - 0x07006360 +static const Vtx intro_seg7_vertex_07006320[] = { + {{{ -100, 321, -114}, 0, { -1120, 768}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -121, 275, -87}, 0, { -1056, 864}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -85, 319, -74}, 0, { -1056, 768}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -110, 272, -42}, 0, { -992, 864}, {0x4a, 0x4a, 0x4a, 0xff}}}, +}; + +// 0x07006360 - 0x070063A0 +static const Vtx intro_seg7_vertex_07006360[] = { + {{{ 137, 295, -99}, 0, { -864, 448}, {0xff, 0xff, 0xfe, 0xff}}}, + {{{ 98, 302, -60}, 0, { -896, 512}, {0xff, 0xff, 0xfe, 0xff}}}, + {{{ 95, 230, -60}, 0, { -800, 576}, {0xff, 0xff, 0xfe, 0xff}}}, + {{{ 59, 241, -21}, 0, { -800, 640}, {0xff, 0xff, 0xfe, 0xff}}}, +}; + +// 0x070063A0 - 0x070063E0 +static const Vtx intro_seg7_vertex_070063A0[] = { + {{{ 59, 241, -21}, 0, { -800, 640}, {0x73, 0x73, 0x73, 0xff}}}, + {{{ 144, 218, -12}, 0, { -704, 512}, {0x73, 0x73, 0x73, 0xff}}}, + {{{ 95, 230, -60}, 0, { -800, 576}, {0x73, 0x73, 0x73, 0xff}}}, + {{{ 164, 212, -49}, 0, { -704, 480}, {0x73, 0x73, 0x73, 0xff}}}, +}; + +// 0x070063E0 - 0x07006420 +static const Vtx intro_seg7_vertex_070063E0[] = { + {{{ 101, -148, 166}, 0, { -160, 896}, {0xff, 0xff, 0xfe, 0xff}}}, + {{{ 164, 212, -49}, 0, { -704, 480}, {0xff, 0xff, 0xfe, 0xff}}}, + {{{ 82, -110, 183}, 0, { -192, 896}, {0xff, 0xff, 0xfe, 0xff}}}, + {{{ 144, 218, -12}, 0, { -704, 512}, {0xff, 0xff, 0xfe, 0xff}}}, +}; + +// 0x07006420 - 0x07006460 +static const Vtx intro_seg7_vertex_07006420[] = { + {{{ -182, -145, 164}, 0, { -384, 1312}, {0xf0, 0xf0, 0xf0, 0xff}}}, + {{{ 101, -148, 166}, 0, { -160, 896}, {0xf0, 0xf0, 0xf0, 0xff}}}, + {{{ -153, -107, 181}, 0, { -384, 1248}, {0xf0, 0xf0, 0xf0, 0xff}}}, + {{{ 82, -110, 183}, 0, { -192, 896}, {0xf0, 0xf0, 0xf0, 0xff}}}, +}; + +// 0x07006460 - 0x070064A0 +static const Vtx intro_seg7_vertex_07006460[] = { + {{{ -133, -29, 132}, 0, { -512, 1152}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -151, -80, 125}, 0, { -480, 1216}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -153, -107, 181}, 0, { -384, 1248}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -182, -145, 164}, 0, { -384, 1312}, {0x4a, 0x4a, 0x4a, 0xff}}}, +}; + +// 0x070064A0 - 0x070064E0 +static const Vtx intro_seg7_vertex_070064A0[] = { + {{{ -133, -29, 132}, 0, { -512, 1152}, {0xff, 0xff, 0xfe, 0xff}}}, + {{{ -269, -128, 192}, 0, { -448, 1440}, {0xff, 0xff, 0xfe, 0xff}}}, + {{{ -151, -80, 125}, 0, { -480, 1216}, {0xff, 0xff, 0xfe, 0xff}}}, + {{{ -276, -175, 182}, 0, { -416, 1472}, {0xff, 0xff, 0xfe, 0xff}}}, +}; + +// 0x070064E0 - 0x07006520 +static const Vtx intro_seg7_vertex_070064E0[] = { + {{{ -366, 60, 81}, 0, { -832, 1408}, {0x7d, 0x7d, 0x7d, 0xff}}}, + {{{ -396, 49, 48}, 0, { -864, 1472}, {0x7d, 0x7d, 0x7d, 0xff}}}, + {{{ -269, -128, 192}, 0, { -448, 1440}, {0x7d, 0x7d, 0x7d, 0xff}}}, + {{{ -276, -175, 182}, 0, { -416, 1472}, {0x7d, 0x7d, 0x7d, 0xff}}}, +}; + +// 0x07006520 - 0x07006560 +static const Vtx intro_seg7_vertex_07006520[] = { + {{{ -190, 150, 28}, 0, { -864, 1088}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -238, 118, 6}, 0, { -864, 1152}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -366, 60, 81}, 0, { -832, 1408}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -396, 49, 48}, 0, { -864, 1472}, {0x4a, 0x4a, 0x4a, 0xff}}}, +}; + +// 0x07006560 - 0x070065A0 +static const Vtx intro_seg7_vertex_07006560[] = { + {{{ -190, 150, 28}, 0, { -864, 1088}, {0xf0, 0xf0, 0xf0, 0xff}}}, + {{{ -290, 156, 24}, 0, { -960, 1216}, {0xf0, 0xf0, 0xf0, 0xff}}}, + {{{ -238, 118, 6}, 0, { -864, 1152}, {0xf0, 0xf0, 0xf0, 0xff}}}, + {{{ -322, 124, 3}, 0, { -960, 1280}, {0xf0, 0xf0, 0xf0, 0xff}}}, +}; + +// 0x070065A0 - 0x070065E0 +static const Vtx intro_seg7_vertex_070065A0[] = { + {{{ -213, 286, -51}, 0, { -1120, 992}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -226, 291, -96}, 0, { -1152, 992}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -290, 156, 24}, 0, { -960, 1216}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -322, 124, 3}, 0, { -960, 1280}, {0x4a, 0x4a, 0x4a, 0xff}}}, +}; + +// 0x070065E0 - 0x07006620 +static const Vtx intro_seg7_vertex_070065E0[] = { + {{{ -110, 272, -42}, 0, { -992, 864}, {0x73, 0x73, 0x73, 0xff}}}, + {{{ -121, 275, -87}, 0, { -1056, 864}, {0x73, 0x73, 0x73, 0xff}}}, + {{{ -213, 286, -51}, 0, { -1120, 992}, {0x73, 0x73, 0x73, 0xff}}}, + {{{ -226, 291, -96}, 0, { -1152, 992}, {0x73, 0x73, 0x73, 0xff}}}, +}; + +// 0x07006620 - 0x07006660 +static const Vtx intro_seg7_vertex_07006620[] = { + {{{ 605, 348, -130}, 0, { -608, -256}, {0x73, 0x73, 0x73, 0xff}}}, + {{{ 151, 276, -87}, 0, { -832, 448}, {0x73, 0x73, 0x73, 0xff}}}, + {{{ 578, 342, -86}, 0, { -576, -192}, {0x73, 0x73, 0x73, 0xff}}}, + {{{ 175, 281, -51}, 0, { -800, 416}, {0x73, 0x73, 0x73, 0xff}}}, +}; + +// 0x07006660 - 0x070066A0 +static const Vtx intro_seg7_vertex_07006660[] = { + {{{ 175, 281, -51}, 0, { -800, 416}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 151, 276, -87}, 0, { -832, 448}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 191, -117, 186}, 0, { -96, 768}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 170, -153, 169}, 0, { -96, 800}, {0x4a, 0x4a, 0x4a, 0xff}}}, +}; + +// 0x070066A0 - 0x070066E0 +static const Vtx intro_seg7_vertex_070066A0[] = { + {{{ 531, -167, 178}, 0, { 192, 288}, {0xf0, 0xf0, 0xf0, 0xff}}}, + {{{ 499, -126, 196}, 0, { 128, 320}, {0xf0, 0xf0, 0xf0, 0xff}}}, + {{{ 170, -153, 169}, 0, { -96, 800}, {0xf0, 0xf0, 0xf0, 0xff}}}, + {{{ 191, -117, 186}, 0, { -96, 768}, {0xf0, 0xf0, 0xf0, 0xff}}}, +}; + +// 0x070066E0 - 0x07006720 +static const Vtx intro_seg7_vertex_070066E0[] = { + {{{ 480, -27, 130}, 0, { -32, 256}, {0xff, 0xff, 0xfe, 0xff}}}, + {{{ 507, -59, 113}, 0, { 0, 224}, {0xff, 0xff, 0xfe, 0xff}}}, + {{{ 499, -126, 196}, 0, { 128, 320}, {0xff, 0xff, 0xfe, 0xff}}}, + {{{ 531, -167, 178}, 0, { 192, 288}, {0xff, 0xff, 0xfe, 0xff}}}, +}; + +// 0x07006720 - 0x07006760 +static const Vtx intro_seg7_vertex_07006720[] = { + {{{ 579, -41, 102}, 0, { 0, 96}, {0xff, 0xff, 0xfe, 0xff}}}, + {{{ 507, -59, 113}, 0, { 0, 224}, {0xff, 0xff, 0xfe, 0xff}}}, + {{{ 545, -8, 124}, 0, { 0, 128}, {0xff, 0xff, 0xfe, 0xff}}}, + {{{ 480, -27, 130}, 0, { -32, 256}, {0xff, 0xff, 0xfe, 0xff}}}, +}; + +// 0x07006760 - 0x070067A0 +static const Vtx intro_seg7_vertex_07006760[] = { + {{{ 579, -41, 102}, 0, { 0, 96}, {0xff, 0xff, 0xfe, 0xff}}}, + {{{ 528, 54, 44}, 0, { -160, 96}, {0xff, 0xff, 0xfe, 0xff}}}, + {{{ 545, -8, 124}, 0, { 0, 128}, {0xff, 0xff, 0xfe, 0xff}}}, + {{{ 494, 73, 70}, 0, { -192, 128}, {0xff, 0xff, 0xfe, 0xff}}}, +}; + +// 0x070067A0 - 0x070067E0 +static const Vtx intro_seg7_vertex_070067A0[] = { + {{{ 585, 144, -8}, 0, { -288, -32}, {0xff, 0xff, 0xfe, 0xff}}}, + {{{ 552, 151, 28}, 0, { -288, 0}, {0xff, 0xff, 0xfe, 0xff}}}, + {{{ 528, 54, 44}, 0, { -160, 96}, {0xff, 0xff, 0xfe, 0xff}}}, + {{{ 494, 73, 70}, 0, { -192, 128}, {0xff, 0xff, 0xfe, 0xff}}}, +}; + +// 0x070067E0 - 0x07006820 +static const Vtx intro_seg7_vertex_070067E0[] = { + {{{ 585, 144, -8}, 0, { -288, -32}, {0xff, 0xff, 0xfe, 0xff}}}, + {{{ 552, 151, 28}, 0, { -288, 0}, {0xff, 0xff, 0xfe, 0xff}}}, + {{{ 571, 149, -11}, 0, { -288, -32}, {0xff, 0xff, 0xfe, 0xff}}}, + {{{ 551, 176, 13}, 0, { -320, 0}, {0xff, 0xff, 0xfe, 0xff}}}, +}; + +// 0x07006820 - 0x07006860 +static const Vtx intro_seg7_vertex_07006820[] = { + {{{ 605, 348, -130}, 0, { -608, -256}, {0xff, 0xff, 0xfe, 0xff}}}, + {{{ 578, 342, -86}, 0, { -576, -192}, {0xff, 0xff, 0xfe, 0xff}}}, + {{{ 571, 149, -11}, 0, { -288, -32}, {0xff, 0xff, 0xfe, 0xff}}}, + {{{ 551, 176, 13}, 0, { -320, 0}, {0xff, 0xff, 0xfe, 0xff}}}, +}; + +// 0x07006860 - 0x070068A0 +static const Vtx intro_seg7_vertex_07006860[] = { + {{{ 952, 278, -88}, 0, { -224, -704}, {0x73, 0x73, 0x73, 0xff}}}, + {{{ 817, 271, -84}, 0, { -320, -512}, {0x73, 0x73, 0x73, 0xff}}}, + {{{ 930, 277, -49}, 0, { -192, -672}, {0x73, 0x73, 0x73, 0xff}}}, + {{{ 790, 270, -45}, 0, { -288, -448}, {0x73, 0x73, 0x73, 0xff}}}, +}; + +// 0x070068A0 - 0x070068E0 +static const Vtx intro_seg7_vertex_070068A0[] = { + {{{ 833, 319, -113}, 0, { -384, -576}, {0xff, 0xff, 0xfe, 0xff}}}, + {{{ 806, 317, -73}, 0, { -352, -512}, {0xff, 0xff, 0xfe, 0xff}}}, + {{{ 817, 271, -84}, 0, { -320, -512}, {0xff, 0xff, 0xfe, 0xff}}}, + {{{ 790, 270, -45}, 0, { -288, -448}, {0xff, 0xff, 0xfe, 0xff}}}, +}; + +// 0x070068E0 - 0x07006920 +static const Vtx intro_seg7_vertex_070068E0[] = { + {{{ 833, 319, -113}, 0, { -384, -576}, {0x73, 0x73, 0x73, 0xff}}}, + {{{ 644, 322, -115}, 0, { -544, -288}, {0x73, 0x73, 0x73, 0xff}}}, + {{{ 806, 317, -73}, 0, { -352, -512}, {0x73, 0x73, 0x73, 0xff}}}, + {{{ 658, 317, -73}, 0, { -480, -288}, {0x73, 0x73, 0x73, 0xff}}}, +}; + +// 0x07006920 - 0x07006960 +static const Vtx intro_seg7_vertex_07006920[] = { + {{{ 644, 322, -115}, 0, { -544, -288}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 593, 243, -67}, 0, { -448, -160}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 658, 317, -73}, 0, { -480, -288}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 619, 247, -31}, 0, { -384, -160}, {0x4a, 0x4a, 0x4a, 0xff}}}, +}; + +// 0x07006960 - 0x070069A0 +static const Vtx intro_seg7_vertex_07006960[] = { + {{{ 514, 174, -26}, 0, { -384, 0}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 541, 186, 5}, 0, { -352, 0}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 593, 243, -67}, 0, { -448, -160}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 619, 247, -31}, 0, { -384, -160}, {0x4a, 0x4a, 0x4a, 0xff}}}, +}; + +// 0x070069A0 - 0x070069E0 +static const Vtx intro_seg7_vertex_070069A0[] = { + {{{ 514, 174, -26}, 0, { -384, 0}, {0x80, 0x80, 0x80, 0xff}}}, + {{{ 593, 42, 52}, 0, { -96, 0}, {0x80, 0x80, 0x80, 0xff}}}, + {{{ 541, 186, 5}, 0, { -352, 0}, {0x80, 0x80, 0x80, 0xff}}}, + {{{ 611, 67, 74}, 0, { -96, 0}, {0x80, 0x80, 0x80, 0xff}}}, +}; + +// 0x070069E0 - 0x07006A20 +static const Vtx intro_seg7_vertex_070069E0[] = { + {{{ 611, 67, 74}, 0, { -96, 0}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 593, 42, 52}, 0, { -96, 0}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 610, 30, 96}, 0, { -32, 0}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 585, 17, 67}, 0, { -64, 32}, {0x4a, 0x4a, 0x4a, 0xff}}}, +}; + +// 0x07006A20 - 0x07006A60 +static const Vtx intro_seg7_vertex_07006A20[] = { + {{{ 610, 30, 96}, 0, { -32, 0}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 585, 17, 67}, 0, { -64, 32}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 482, -98, 173}, 0, { 64, 320}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 444, -120, 149}, 0, { 32, 352}, {0x4a, 0x4a, 0x4a, 0xff}}}, +}; + +// 0x07006A60 - 0x07006AA0 +static const Vtx intro_seg7_vertex_07006A60[] = { + {{{ 444, -120, 149}, 0, { 32, 352}, {0x73, 0x73, 0x73, 0xff}}}, + {{{ 626, -211, 204}, 0, { 320, 192}, {0x73, 0x73, 0x73, 0xff}}}, + {{{ 482, -98, 173}, 0, { 64, 320}, {0x73, 0x73, 0x73, 0xff}}}, + {{{ 619, -170, 215}, 0, { 288, 160}, {0x73, 0x73, 0x73, 0xff}}}, +}; + +// 0x07006AA0 - 0x07006AE0 +static const Vtx intro_seg7_vertex_07006AA0[] = { + {{{ 668, -97, 172}, 0, { 192, 32}, {0xff, 0xff, 0xfe, 0xff}}}, + {{{ 619, -170, 215}, 0, { 288, 160}, {0xff, 0xff, 0xfe, 0xff}}}, + {{{ 678, -144, 164}, 0, { 256, 32}, {0xff, 0xff, 0xfe, 0xff}}}, + {{{ 626, -211, 204}, 0, { 320, 192}, {0xff, 0xff, 0xfe, 0xff}}}, +}; + +// 0x07006AE0 - 0x07006B20 +static const Vtx intro_seg7_vertex_07006AE0[] = { + {{{ 668, -97, 172}, 0, { 192, 32}, {0x73, 0x73, 0x73, 0xff}}}, + {{{ 678, -144, 164}, 0, { 256, 32}, {0x73, 0x73, 0x73, 0xff}}}, + {{{ 810, -196, 234}, 0, { 480, -64}, {0x73, 0x73, 0x73, 0xff}}}, + {{{ 812, -238, 220}, 0, { 512, -32}, {0x73, 0x73, 0x73, 0xff}}}, +}; + +// 0x07006B20 - 0x07006B60 +static const Vtx intro_seg7_vertex_07006B20[] = { + {{{ 1041, -80, 125}, 0, { 416, -512}, {0xff, 0xff, 0xfe, 0xff}}}, + {{{ 994, -64, 156}, 0, { 384, -448}, {0xff, 0xff, 0xfe, 0xff}}}, + {{{ 812, -238, 220}, 0, { 512, -32}, {0xff, 0xff, 0xfe, 0xff}}}, + {{{ 810, -196, 234}, 0, { 480, -64}, {0xff, 0xff, 0xfe, 0xff}}}, +}; + +// 0x07006B60 - 0x07006BA0 +static const Vtx intro_seg7_vertex_07006B60[] = { + {{{ 1041, -80, 125}, 0, { 416, -512}, {0xbb, 0xbb, 0xbb, 0xff}}}, + {{{ 811, 18, 66}, 0, { 96, -256}, {0xbb, 0xbb, 0xbb, 0xff}}}, + {{{ 994, -64, 156}, 0, { 384, -448}, {0xbb, 0xbb, 0xbb, 0xff}}}, + {{{ 789, 26, 98}, 0, { 96, -224}, {0xbb, 0xbb, 0xbb, 0xff}}}, +}; + +// 0x07006BA0 - 0x07006BE0 +static const Vtx intro_seg7_vertex_07006BA0[] = { + {{{ 786, 118, 44}, 0, { -32, -320}, {0xff, 0xff, 0xfe, 0xff}}}, + {{{ 789, 26, 98}, 0, { 96, -224}, {0xff, 0xff, 0xfe, 0xff}}}, + {{{ 812, 77, 31}, 0, { 0, -320}, {0xff, 0xff, 0xfe, 0xff}}}, + {{{ 811, 18, 66}, 0, { 96, -256}, {0xff, 0xff, 0xfe, 0xff}}}, +}; + +// 0x07006BE0 - 0x07006C20 +static const Vtx intro_seg7_vertex_07006BE0[] = { + {{{ 786, 118, 44}, 0, { -32, -320}, {0xf0, 0xf0, 0xf0, 0xff}}}, + {{{ 812, 77, 31}, 0, { 0, -320}, {0xf0, 0xf0, 0xf0, 0xff}}}, + {{{ 887, 92, 62}, 0, { 64, -416}, {0xf0, 0xf0, 0xf0, 0xff}}}, + {{{ 904, 50, 47}, 0, { 96, -448}, {0xf0, 0xf0, 0xf0, 0xff}}}, +}; + +// 0x07006C20 - 0x07006C60 +static const Vtx intro_seg7_vertex_07006C20[] = { + {{{ 952, 278, -88}, 0, { -224, -704}, {0xff, 0xff, 0xfe, 0xff}}}, + {{{ 930, 277, -49}, 0, { -192, -672}, {0xff, 0xff, 0xfe, 0xff}}}, + {{{ 904, 50, 47}, 0, { 96, -448}, {0xff, 0xff, 0xfe, 0xff}}}, + {{{ 887, 92, 62}, 0, { 64, -416}, {0xff, 0xff, 0xfe, 0xff}}}, +}; + +// 0x07006C60 - 0x07006CA0 +static const Vtx intro_seg7_vertex_07006C60[] = { + {{{ -97, 839, -418}, 0, { -1984, 320}, {0x73, 0x73, 0x73, 0xff}}}, + {{{ -270, 840, -419}, 0, { -2112, 576}, {0x73, 0x73, 0x73, 0xff}}}, + {{{ -115, 837, -380}, 0, { -1952, 352}, {0x73, 0x73, 0x73, 0xff}}}, + {{{ -257, 840, -381}, 0, { -2080, 576}, {0x73, 0x73, 0x73, 0xff}}}, +}; + +// 0x07006CA0 - 0x07006CE0 +static const Vtx intro_seg7_vertex_07006CA0[] = { + {{{ -270, 840, -419}, 0, { -2112, 576}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -279, 785, -386}, 0, { -2016, 640}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -257, 840, -381}, 0, { -2080, 576}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -261, 785, -349}, 0, { -1984, 608}, {0x4a, 0x4a, 0x4a, 0xff}}}, +}; + +// 0x07006CE0 - 0x07006D20 +static const Vtx intro_seg7_vertex_07006CE0[] = { + {{{ -261, 785, -349}, 0, { -1984, 608}, {0x73, 0x73, 0x73, 0xff}}}, + {{{ -279, 785, -386}, 0, { -2016, 640}, {0x73, 0x73, 0x73, 0xff}}}, + {{{ -340, 779, -346}, 0, { -2048, 736}, {0x73, 0x73, 0x73, 0xff}}}, + {{{ -336, 780, -383}, 0, { -2080, 704}, {0x73, 0x73, 0x73, 0xff}}}, +}; + +// 0x07006D20 - 0x07006D60 +static const Vtx intro_seg7_vertex_07006D20[] = { + {{{ -371, 778, -345}, 0, { -2048, 800}, {0x73, 0x73, 0x73, 0xff}}}, + {{{ -340, 779, -346}, 0, { -2048, 736}, {0x73, 0x73, 0x73, 0xff}}}, + {{{ -354, 779, -382}, 0, { -2080, 736}, {0x73, 0x73, 0x73, 0xff}}}, + {{{ -336, 780, -383}, 0, { -2080, 704}, {0x73, 0x73, 0x73, 0xff}}}, +}; + +// 0x07006D60 - 0x07006DA0 +static const Vtx intro_seg7_vertex_07006D60[] = { + {{{ -361, 851, -425}, 0, { -2208, 704}, {0xff, 0xff, 0xfe, 0xff}}}, + {{{ -387, 844, -382}, 0, { -2176, 768}, {0xff, 0xff, 0xfe, 0xff}}}, + {{{ -354, 779, -382}, 0, { -2080, 736}, {0xff, 0xff, 0xfe, 0xff}}}, + {{{ -371, 778, -345}, 0, { -2048, 800}, {0xff, 0xff, 0xfe, 0xff}}}, +}; + +// 0x07006DA0 - 0x07006DE0 +static const Vtx intro_seg7_vertex_07006DA0[] = { + {{{ -361, 851, -425}, 0, { -2208, 704}, {0x73, 0x73, 0x73, 0xff}}}, + {{{ -547, 803, -397}, 0, { -2272, 1024}, {0x73, 0x73, 0x73, 0xff}}}, + {{{ -387, 844, -382}, 0, { -2176, 768}, {0x73, 0x73, 0x73, 0xff}}}, + {{{ -515, 811, -362}, 0, { -2240, 960}, {0x73, 0x73, 0x73, 0xff}}}, +}; + +// 0x07006DE0 - 0x07006E20 +static const Vtx intro_seg7_vertex_07006DE0[] = { + {{{ -547, 803, -397}, 0, { -2272, 1024}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -541, 786, -387}, 0, { -2240, 1024}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -515, 811, -362}, 0, { -2240, 960}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -504, 781, -347}, 0, { -2176, 992}, {0x4a, 0x4a, 0x4a, 0xff}}}, +}; + +// 0x07006E20 - 0x07006E60 +static const Vtx intro_seg7_vertex_07006E20[] = { + {{{ -504, 781, -347}, 0, { -2176, 992}, {0x73, 0x73, 0x73, 0xff}}}, + {{{ -541, 786, -387}, 0, { -2240, 1024}, {0x73, 0x73, 0x73, 0xff}}}, + {{{ -556, 784, -347}, 0, { -2208, 1056}, {0x73, 0x73, 0x73, 0xff}}}, + {{{ -574, 788, -388}, 0, { -2272, 1056}, {0x73, 0x73, 0x73, 0xff}}}, +}; + +// 0x07006E60 - 0x07006EA0 +static const Vtx intro_seg7_vertex_07006E60[] = { + {{{ -612, 651, -307}, 0, { -2048, 1248}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -582, 680, -287}, 0, { -2048, 1184}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -574, 788, -388}, 0, { -2272, 1056}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -556, 784, -347}, 0, { -2208, 1056}, {0x4a, 0x4a, 0x4a, 0xff}}}, +}; + +// 0x07006EA0 - 0x07006EE0 +static const Vtx intro_seg7_vertex_07006EA0[] = { + {{{ -612, 651, -307}, 0, { -2048, 1248}, {0xdd, 0xdd, 0xdd, 0xff}}}, + {{{ -603, 649, -306}, 0, { -2048, 1216}, {0xdd, 0xdd, 0xdd, 0xff}}}, + {{{ -582, 680, -287}, 0, { -2048, 1184}, {0xdd, 0xdd, 0xdd, 0xff}}}, + {{{ -537, 670, -281}, 0, { -2016, 1120}, {0xdd, 0xdd, 0xdd, 0xff}}}, +}; + +// 0x07006EE0 - 0x07006F20 +static const Vtx intro_seg7_vertex_07006EE0[] = { + {{{ -537, 670, -281}, 0, { -2016, 1120}, {0x73, 0x73, 0x73, 0xff}}}, + {{{ -603, 649, -306}, 0, { -2048, 1216}, {0x73, 0x73, 0x73, 0xff}}}, + {{{ -610, 638, -260}, 0, { -2016, 1280}, {0x73, 0x73, 0x73, 0xff}}}, + {{{ -641, 632, -296}, 0, { -2048, 1312}, {0x73, 0x73, 0x73, 0xff}}}, +}; + +// 0x07006F20 - 0x07006F60 +static const Vtx intro_seg7_vertex_07006F20[] = { + {{{ -580, 466, -197}, 0, { -1728, 1376}, {0x7d, 0x7d, 0x7d, 0xff}}}, + {{{ -568, 515, -189}, 0, { -1760, 1312}, {0x7d, 0x7d, 0x7d, 0xff}}}, + {{{ -641, 632, -296}, 0, { -2048, 1312}, {0x7d, 0x7d, 0x7d, 0xff}}}, + {{{ -610, 638, -260}, 0, { -2016, 1280}, {0x7d, 0x7d, 0x7d, 0xff}}}, +}; + +// 0x07006F60 - 0x07006FA0 +static const Vtx intro_seg7_vertex_07006F60[] = { + {{{ -580, 466, -197}, 0, { -1728, 1376}, {0xdd, 0xdd, 0xdd, 0xff}}}, + {{{ -576, 468, -199}, 0, { -1728, 1344}, {0xdd, 0xdd, 0xdd, 0xff}}}, + {{{ -568, 515, -189}, 0, { -1760, 1312}, {0xdd, 0xdd, 0xdd, 0xff}}}, + {{{ -540, 534, -201}, 0, { -1792, 1248}, {0xdd, 0xdd, 0xdd, 0xff}}}, +}; + +// 0x07006FA0 - 0x07006FE0 +static const Vtx intro_seg7_vertex_07006FA0[] = { + {{{ -540, 534, -201}, 0, { -1792, 1248}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -576, 468, -199}, 0, { -1728, 1344}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -566, 406, -122}, 0, { -1600, 1408}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -592, 366, -139}, 0, { -1568, 1472}, {0x4a, 0x4a, 0x4a, 0xff}}}, +}; + +// 0x07006FE0 - 0x07007020 +static const Vtx intro_seg7_vertex_07006FE0[] = { + {{{ -592, 366, -139}, 0, { -1568, 1472}, {0xf0, 0xf0, 0xf0, 0xff}}}, + {{{ -357, 362, -136}, 0, { -1376, 1120}, {0xf0, 0xf0, 0xf0, 0xff}}}, + {{{ -566, 406, -122}, 0, { -1600, 1408}, {0xf0, 0xf0, 0xf0, 0xff}}}, + {{{ -379, 401, -121}, 0, { -1440, 1152}, {0xf0, 0xf0, 0xf0, 0xff}}}, +}; + +// 0x07007020 - 0x07007060 +static const Vtx intro_seg7_vertex_07007020[] = { + {{{ -380, 504, -183}, 0, { -1600, 1056}, {0xff, 0xff, 0xfe, 0x00}}}, + {{{ -379, 401, -121}, 0, { -1440, 1152}, {0xff, 0xff, 0xfe, 0xff}}}, + {{{ -361, 478, -205}, 0, { -1568, 1024}, {0xff, 0xff, 0xfe, 0xff}}}, + {{{ -357, 362, -136}, 0, { -1376, 1120}, {0xff, 0xff, 0xfe, 0xff}}}, +}; + +// 0x07007060 - 0x070070A0 +static const Vtx intro_seg7_vertex_07007060[] = { + {{{ -380, 504, -183}, 0, { -1600, 1056}, {0xf0, 0xf0, 0xf0, 0xff}}}, + {{{ -361, 478, -205}, 0, { -1568, 1024}, {0xf0, 0xf0, 0xf0, 0xff}}}, + {{{ -268, 502, -182}, 0, { -1504, 896}, {0xf0, 0xf0, 0xf0, 0xff}}}, + {{{ -292, 464, -197}, 0, { -1504, 928}, {0xf0, 0xf0, 0xf0, 0xff}}}, +}; + +// 0x070070A0 - 0x070070E0 +static const Vtx intro_seg7_vertex_070070A0[] = { + {{{ -268, 502, -182}, 0, { -1504, 896}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -292, 464, -197}, 0, { -1504, 928}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -272, 396, -118}, 0, { -1344, 992}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -295, 359, -134}, 0, { -1312, 1024}, {0x4a, 0x4a, 0x4a, 0xff}}}, +}; + +// 0x070070E0 - 0x07007120 +static const Vtx intro_seg7_vertex_070070E0[] = { + {{{ -272, 396, -118}, 0, { -1344, 992}, {0xf0, 0xf0, 0xf0, 0xff}}}, + {{{ -295, 359, -134}, 0, { -1312, 1024}, {0xf0, 0xf0, 0xf0, 0xff}}}, + {{{ -106, 391, -116}, 0, { -1216, 736}, {0xf0, 0xf0, 0xf0, 0xff}}}, + {{{ -83, 354, -131}, 0, { -1152, 736}, {0xf0, 0xf0, 0xf0, 0xff}}}, +}; + +// 0x07007120 - 0x07007160 +static const Vtx intro_seg7_vertex_07007120[] = { + {{{ -108, 493, -177}, 0, { -1376, 640}, {0xff, 0xff, 0xfe, 0xff}}}, + {{{ -106, 391, -116}, 0, { -1216, 736}, {0xff, 0xff, 0xfe, 0xff}}}, + {{{ -82, 459, -193}, 0, { -1312, 640}, {0xff, 0xff, 0xfe, 0xff}}}, + {{{ -83, 354, -131}, 0, { -1152, 736}, {0xff, 0xff, 0xfe, 0xff}}}, +}; + +// 0x07007160 - 0x070071A0 +static const Vtx intro_seg7_vertex_07007160[] = { + {{{ -108, 493, -177}, 0, { -1376, 640}, {0xf0, 0xf0, 0xf0, 0xff}}}, + {{{ -82, 459, -193}, 0, { -1312, 640}, {0xf0, 0xf0, 0xf0, 0xff}}}, + {{{ -9, 498, -179}, 0, { -1312, 512}, {0xf0, 0xf0, 0xf0, 0xff}}}, + {{{ 13, 461, -195}, 0, { -1248, 480}, {0xf0, 0xf0, 0xf0, 0xff}}}, +}; + +// 0x070071A0 - 0x070071E0 +static const Vtx intro_seg7_vertex_070071A0[] = { + {{{ -17, 773, -339}, 0, { -1760, 256}, {0xff, 0xff, 0xfe, 0xff}}}, + {{{ -9, 498, -179}, 0, { -1312, 512}, {0xff, 0xff, 0xfe, 0xff}}}, + {{{ 3, 775, -380}, 0, { -1792, 224}, {0xff, 0xff, 0xfe, 0xff}}}, + {{{ 13, 461, -195}, 0, { -1248, 480}, {0xff, 0xff, 0xfe, 0xff}}}, +}; + +// 0x070071E0 - 0x07007220 +static const Vtx intro_seg7_vertex_070071E0[] = { + {{{ -116, 775, -343}, 0, { -1856, 416}, {0x73, 0x73, 0x73, 0xff}}}, + {{{ -17, 773, -339}, 0, { -1760, 256}, {0x73, 0x73, 0x73, 0xff}}}, + {{{ -99, 778, -382}, 0, { -1888, 384}, {0x73, 0x73, 0x73, 0xff}}}, + {{{ 3, 775, -380}, 0, { -1792, 224}, {0x73, 0x73, 0x73, 0xff}}}, +}; + +// 0x07007220 - 0x07007260 +static const Vtx intro_seg7_vertex_07007220[] = { + {{{ -116, 775, -343}, 0, { -1856, 416}, {0xff, 0xff, 0xfe, 0xff}}}, + {{{ -99, 778, -382}, 0, { -1888, 384}, {0xff, 0xff, 0xfe, 0xff}}}, + {{{ -115, 837, -380}, 0, { -1952, 352}, {0xff, 0xff, 0xfe, 0xff}}}, + {{{ -97, 839, -418}, 0, { -1984, 320}, {0xff, 0xff, 0xfe, 0xff}}}, +}; + +// 0x07007260 - 0x070072A0 +static const Vtx intro_seg7_vertex_07007260[] = { + {{{ 589, 815, -404}, 0, { -1408, -640}, {0x73, 0x73, 0x73, 0xff}}}, + {{{ 425, 820, -407}, 0, { -1536, -416}, {0x73, 0x73, 0x73, 0xff}}}, + {{{ 571, 814, -363}, 0, { -1376, -608}, {0x73, 0x73, 0x73, 0xff}}}, + {{{ 427, 812, -365}, 0, { -1504, -384}, {0x73, 0x73, 0x73, 0xff}}}, +}; + +// 0x070072A0 - 0x070072E0 +static const Vtx intro_seg7_vertex_070072A0[] = { + {{{ 246, 778, -382}, 0, { -1600, -96}, {0x73, 0x73, 0x73, 0xff}}}, + {{{ 276, 781, -348}, 0, { -1568, -128}, {0x73, 0x73, 0x73, 0xff}}}, + {{{ 425, 820, -407}, 0, { -1536, -416}, {0x73, 0x73, 0x73, 0xff}}}, + {{{ 427, 812, -365}, 0, { -1504, -384}, {0x73, 0x73, 0x73, 0xff}}}, +}; + +// 0x070072E0 - 0x07007320 +static const Vtx intro_seg7_vertex_070072E0[] = { + {{{ 246, 778, -382}, 0, { -1600, -96}, {0xaa, 0xaa, 0xaa, 0xff}}}, + {{{ 265, 745, -363}, 0, { -1536, -96}, {0xaa, 0xaa, 0xaa, 0xff}}}, + {{{ 276, 781, -348}, 0, { -1568, -128}, {0xaa, 0xaa, 0xaa, 0xff}}}, + {{{ 302, 744, -325}, 0, { -1472, -160}, {0xaa, 0xaa, 0xaa, 0xff}}}, +}; + +// 0x07007320 - 0x07007360 +static const Vtx intro_seg7_vertex_07007320[] = { + {{{ 302, 744, -325}, 0, { -1472, -160}, {0x73, 0x73, 0x73, 0xff}}}, + {{{ 265, 745, -363}, 0, { -1536, -96}, {0x73, 0x73, 0x73, 0xff}}}, + {{{ 247, 742, -321}, 0, { -1504, -64}, {0x73, 0x73, 0x73, 0xff}}}, + {{{ 228, 742, -361}, 0, { -1568, -64}, {0x73, 0x73, 0x73, 0xff}}}, +}; + +// 0x07007360 - 0x070073A0 +static const Vtx intro_seg7_vertex_07007360[] = { + {{{ 222, 615, -286}, 0, { -1344, 32}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 248, 650, -269}, 0, { -1376, 0}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 228, 742, -361}, 0, { -1568, -64}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 247, 742, -321}, 0, { -1504, -64}, {0x4a, 0x4a, 0x4a, 0xff}}}, +}; + +// 0x070073A0 - 0x070073E0 +static const Vtx intro_seg7_vertex_070073A0[] = { + {{{ 274, 649, -268}, 0, { -1344, -32}, {0xf0, 0xf0, 0xf0, 0xff}}}, + {{{ 248, 650, -269}, 0, { -1376, 0}, {0xf0, 0xf0, 0xf0, 0xff}}}, + {{{ 246, 613, -285}, 0, { -1344, 0}, {0xf0, 0xf0, 0xf0, 0xff}}}, + {{{ 222, 615, -286}, 0, { -1344, 32}, {0xf0, 0xf0, 0xf0, 0xff}}}, +}; + +// 0x070073E0 - 0x07007420 +static const Vtx intro_seg7_vertex_070073E0[] = { + {{{ 274, 649, -268}, 0, { -1344, -32}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 246, 613, -285}, 0, { -1344, 0}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 261, 594, -236}, 0, { -1248, 0}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 240, 583, -267}, 0, { -1280, 32}, {0x4a, 0x4a, 0x4a, 0xff}}}, +}; + +// 0x07007420 - 0x07007460 +static const Vtx intro_seg7_vertex_07007420[] = { + {{{ 114, 399, -158}, 0, { -1056, 384}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 141, 425, -137}, 0, { -1056, 352}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 240, 583, -267}, 0, { -1280, 32}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 261, 594, -236}, 0, { -1248, 0}, {0x4a, 0x4a, 0x4a, 0xff}}}, +}; + +// 0x07007460 - 0x070074A0 +static const Vtx intro_seg7_vertex_07007460[] = { + {{{ 114, 399, -158}, 0, { -1056, 384}, {0xcc, 0xcc, 0xcc, 0xff}}}, + {{{ 353, 333, -119}, 0, { -768, 96}, {0xcc, 0xcc, 0xcc, 0xff}}}, + {{{ 141, 425, -137}, 0, { -1056, 352}, {0xcc, 0xcc, 0xcc, 0xff}}}, + {{{ 338, 374, -106}, 0, { -832, 96}, {0xcc, 0xcc, 0xcc, 0xff}}}, +}; + +// 0x070074A0 - 0x070074E0 +static const Vtx intro_seg7_vertex_070074A0[] = { + {{{ 353, 333, -119}, 0, { -768, 96}, {0xff, 0xff, 0xfe, 0xff}}}, + {{{ 356, 350, -129}, 0, { -800, 64}, {0xff, 0xff, 0xfe, 0xff}}}, + {{{ 338, 374, -106}, 0, { -832, 96}, {0xff, 0xff, 0xfe, 0xff}}}, + {{{ 347, 390, -115}, 0, { -832, 64}, {0xff, 0xff, 0xfe, 0xff}}}, +}; + +// 0x070074E0 - 0x07007520 +static const Vtx intro_seg7_vertex_070074E0[] = { + {{{ 347, 390, -115}, 0, { -832, 64}, {0xf0, 0xf0, 0xf0, 0xff}}}, + {{{ 356, 350, -129}, 0, { -800, 64}, {0xf0, 0xf0, 0xf0, 0xff}}}, + {{{ 642, 392, -117}, 0, { -608, -352}, {0xf0, 0xf0, 0xf0, 0xff}}}, + {{{ 672, 352, -130}, 0, { -544, -352}, {0xf0, 0xf0, 0xf0, 0xff}}}, +}; + +// 0x07007520 - 0x07007560 +static const Vtx intro_seg7_vertex_07007520[] = { + {{{ 627, 482, -170}, 0, { -768, -384}, {0xff, 0xff, 0xfe, 0xff}}}, + {{{ 642, 392, -117}, 0, { -608, -352}, {0xff, 0xff, 0xfe, 0xff}}}, + {{{ 655, 448, -187}, 0, { -736, -416}, {0xff, 0xff, 0xfe, 0xff}}}, + {{{ 672, 352, -130}, 0, { -544, -352}, {0xff, 0xff, 0xfe, 0xff}}}, +}; + +// 0x07007560 - 0x070075A0 +static const Vtx intro_seg7_vertex_07007560[] = { + {{{ 676, 583, -267}, 0, { -928, -576}, {0xff, 0xff, 0xfe, 0xff}}}, + {{{ 652, 577, -226}, 0, { -928, -512}, {0xff, 0xff, 0xfe, 0xff}}}, + {{{ 682, 453, -190}, 0, { -704, -480}, {0xff, 0xff, 0xfe, 0xff}}}, + {{{ 658, 486, -172}, 0, { -768, -448}, {0xff, 0xff, 0xfe, 0xff}}}, +}; + +// 0x070075A0 - 0x070075E0 +static const Vtx intro_seg7_vertex_070075A0[] = { + {{{ 627, 482, -170}, 0, { -768, -384}, {0xf0, 0xf0, 0xf0, 0xff}}}, + {{{ 655, 448, -187}, 0, { -736, -416}, {0xf0, 0xf0, 0xf0, 0xff}}}, + {{{ 658, 486, -172}, 0, { -768, -448}, {0xf0, 0xf0, 0xf0, 0xff}}}, + {{{ 682, 453, -190}, 0, { -704, -480}, {0xf0, 0xf0, 0xf0, 0xff}}}, +}; + +// 0x070075E0 - 0x07007620 +static const Vtx intro_seg7_vertex_070075E0[] = { + {{{ 618, 578, -227}, 0, { -960, -480}, {0x73, 0x73, 0x73, 0xff}}}, + {{{ 652, 577, -226}, 0, { -928, -512}, {0x73, 0x73, 0x73, 0xff}}}, + {{{ 661, 583, -267}, 0, { -960, -544}, {0x73, 0x73, 0x73, 0xff}}}, + {{{ 676, 583, -267}, 0, { -928, -576}, {0x73, 0x73, 0x73, 0xff}}}, +}; + +// 0x07007620 - 0x07007660 +static const Vtx intro_seg7_vertex_07007620[] = { + {{{ 671, 595, -274}, 0, { -960, -576}, {0xff, 0xff, 0xfe, 0xff}}}, + {{{ 646, 614, -248}, 0, { -992, -544}, {0xff, 0xff, 0xfe, 0xff}}}, + {{{ 661, 583, -267}, 0, { -960, -544}, {0xff, 0xff, 0xfe, 0xff}}}, + {{{ 618, 578, -227}, 0, { -960, -480}, {0xff, 0xff, 0xfe, 0xff}}}, +}; + +// 0x07007660 - 0x070076A0 +static const Vtx intro_seg7_vertex_07007660[] = { + {{{ 637, 664, -277}, 0, { -1088, -576}, {0xff, 0xff, 0xfe, 0xff}}}, + {{{ 646, 614, -248}, 0, { -992, -544}, {0xff, 0xff, 0xfe, 0xff}}}, + {{{ 661, 633, -296}, 0, { -1024, -608}, {0xff, 0xff, 0xfe, 0xff}}}, + {{{ 671, 595, -274}, 0, { -960, -576}, {0xff, 0xff, 0xfe, 0xff}}}, +}; + +// 0x070076A0 - 0x070076E0 +static const Vtx intro_seg7_vertex_070076A0[] = { + {{{ 669, 631, -295}, 0, { -1024, -608}, {0xf0, 0xf0, 0xf0, 0xff}}}, + {{{ 647, 662, -276}, 0, { -1056, -576}, {0xf0, 0xf0, 0xf0, 0xff}}}, + {{{ 661, 633, -296}, 0, { -1024, -608}, {0xf0, 0xf0, 0xf0, 0xff}}}, + {{{ 637, 664, -277}, 0, { -1088, -576}, {0xf0, 0xf0, 0xf0, 0xff}}}, +}; + +// 0x070076E0 - 0x07007720 +static const Vtx intro_seg7_vertex_070076E0[] = { + {{{ 681, 781, -384}, 0, { -1280, -768}, {0xff, 0xff, 0xfe, 0xff}}}, + {{{ 653, 778, -348}, 0, { -1248, -704}, {0xff, 0xff, 0xfe, 0xff}}}, + {{{ 669, 631, -295}, 0, { -1024, -608}, {0xff, 0xff, 0xfe, 0xff}}}, + {{{ 647, 662, -276}, 0, { -1056, -576}, {0xff, 0xff, 0xfe, 0xff}}}, +}; + +// 0x07007720 - 0x07007760 +static const Vtx intro_seg7_vertex_07007720[] = { + {{{ 573, 772, -341}, 0, { -1312, -576}, {0x73, 0x73, 0x73, 0xff}}}, + {{{ 653, 778, -348}, 0, { -1248, -704}, {0x73, 0x73, 0x73, 0xff}}}, + {{{ 593, 775, -380}, 0, { -1344, -608}, {0x73, 0x73, 0x73, 0xff}}}, + {{{ 681, 781, -384}, 0, { -1280, -768}, {0x73, 0x73, 0x73, 0xff}}}, +}; + +// 0x07007760 - 0x070077A0 +static const Vtx intro_seg7_vertex_07007760[] = { + {{{ 589, 815, -404}, 0, { -1408, -640}, {0xff, 0xff, 0xfe, 0xff}}}, + {{{ 571, 814, -363}, 0, { -1376, -608}, {0xff, 0xff, 0xfe, 0xff}}}, + {{{ 593, 775, -380}, 0, { -1344, -608}, {0xff, 0xff, 0xfe, 0xff}}}, + {{{ 573, 772, -341}, 0, { -1312, -576}, {0xff, 0xff, 0xfe, 0xff}}}, +}; + +// 0x070077A0 - 0x070077E0 +static const Vtx intro_seg7_vertex_070077A0[] = { + {{{ 178, 864, -433}, 0, { -1792, -96}, {0xaa, 0xaa, 0xaa, 0xff}}}, + {{{ 180, 850, -387}, 0, { -1760, -64}, {0xaa, 0xaa, 0xaa, 0xff}}}, + {{{ 308, 766, -375}, 0, { -1536, -192}, {0xaa, 0xaa, 0xaa, 0xff}}}, + {{{ 278, 778, -345}, 0, { -1568, -128}, {0xaa, 0xaa, 0xaa, 0xff}}}, +}; + +// 0x070077E0 - 0x07007820 +static const Vtx intro_seg7_vertex_070077E0[] = { + {{{ 308, 766, -375}, 0, { -1536, -192}, {0xff, 0xff, 0xfe, 0xff}}}, + {{{ 278, 778, -345}, 0, { -1568, -128}, {0xff, 0xff, 0xfe, 0xff}}}, + {{{ 220, 666, -316}, 0, { -1440, 0}, {0xff, 0xff, 0xfe, 0xff}}}, + {{{ 213, 700, -299}, 0, { -1472, 0}, {0xff, 0xff, 0xfe, 0xff}}}, +}; + +// 0x07007820 - 0x07007860 +static const Vtx intro_seg7_vertex_07007820[] = { + {{{ 213, 700, -299}, 0, { -1472, 0}, {0xa7, 0x91, 0x7b, 0xff}}}, + {{{ 94, 750, -328}, 0, { -1664, 128}, {0xa7, 0x91, 0x7b, 0xff}}}, + {{{ 220, 666, -316}, 0, { -1440, 0}, {0xa7, 0x91, 0x7b, 0xff}}}, + {{{ 61, 727, -352}, 0, { -1664, 192}, {0xa7, 0x91, 0x7b, 0xff}}}, +}; + +// 0x07007860 - 0x070078A0 +static const Vtx intro_seg7_vertex_07007860[] = { + {{{ 94, 750, -328}, 0, { -1664, 128}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 180, 850, -387}, 0, { -1760, -64}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 61, 727, -352}, 0, { -1664, 192}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 178, 864, -433}, 0, { -1792, -96}, {0x4a, 0x4a, 0x4a, 0xff}}}, +}; + +// 0x070078A0 - 0x070078E0 +static const Vtx intro_seg7_vertex_070078A0[] = { + {{{ 132, 758, -370}, 0, { -1664, 32}, {0xaa, 0xaa, 0xaa, 0xff}}}, + {{{ 134, 738, -321}, 0, { -1600, 64}, {0xaa, 0xaa, 0xaa, 0xff}}}, + {{{ 266, 636, -298}, 0, { -1344, 0}, {0xaa, 0xaa, 0xaa, 0xff}}}, + {{{ 245, 652, -270}, 0, { -1376, 0}, {0xaa, 0xaa, 0xaa, 0xff}}}, +}; + +// 0x070078E0 - 0x07007920 +static const Vtx intro_seg7_vertex_070078E0[] = { + {{{ 171, 531, -236}, 0, { -1248, 192}, {0xff, 0xff, 0xfe, 0xff}}}, + {{{ 266, 636, -298}, 0, { -1344, 0}, {0xff, 0xff, 0xfe, 0xff}}}, + {{{ 170, 568, -221}, 0, { -1280, 160}, {0xff, 0xff, 0xfe, 0xff}}}, + {{{ 245, 652, -270}, 0, { -1376, 0}, {0xff, 0xff, 0xfe, 0xff}}}, +}; + +// 0x07007920 - 0x07007960 +static const Vtx intro_seg7_vertex_07007920[] = { + {{{ 170, 568, -221}, 0, { -1280, 160}, {0xa7, 0x91, 0x7b, 0xff}}}, + {{{ 61, 631, -258}, 0, { -1472, 288}, {0xa7, 0x91, 0x7b, 0xff}}}, + {{{ 171, 531, -236}, 0, { -1248, 192}, {0xa7, 0x91, 0x7b, 0xff}}}, + {{{ 32, 607, -281}, 0, { -1472, 320}, {0xa7, 0x91, 0x7b, 0xff}}}, +}; + +// 0x07007960 - 0x070079A0 +static const Vtx intro_seg7_vertex_07007960[] = { + {{{ 61, 631, -258}, 0, { -1472, 288}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 134, 738, -321}, 0, { -1600, 64}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 32, 607, -281}, 0, { -1472, 320}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 132, 758, -370}, 0, { -1664, 32}, {0x4a, 0x4a, 0x4a, 0xff}}}, +}; + +// 0x070079A0 - 0x070079E0 +static const Vtx intro_seg7_vertex_070079A0[] = { + {{{ 256, 545, -245}, 0, { -1216, 64}, {0xaa, 0xaa, 0xaa, 0xff}}}, + {{{ 83, 596, -274}, 0, { -1440, 256}, {0xaa, 0xaa, 0xaa, 0xff}}}, + {{{ 224, 552, -211}, 0, { -1216, 96}, {0xaa, 0xaa, 0xaa, 0xff}}}, + {{{ 89, 593, -236}, 0, { -1376, 256}, {0xaa, 0xaa, 0xaa, 0xff}}}, +}; + +// 0x070079E0 - 0x07007A20 +static const Vtx intro_seg7_vertex_070079E0[] = { + {{{ 134, 336, -121}, 0, { -960, 416}, {0xff, 0xff, 0xfe, 0xff}}}, + {{{ 256, 545, -245}, 0, { -1216, 64}, {0xff, 0xff, 0xfe, 0xff}}}, + {{{ 126, 383, -111}, 0, { -992, 416}, {0xff, 0xff, 0xfe, 0xff}}}, + {{{ 224, 552, -211}, 0, { -1216, 96}, {0xff, 0xff, 0xfe, 0xff}}}, +}; + +// 0x07007A20 - 0x07007A60 +static const Vtx intro_seg7_vertex_07007A20[] = { + {{{ 134, 336, -121}, 0, { -960, 416}, {0xa7, 0x91, 0x7b, 0xff}}}, + {{{ 126, 383, -111}, 0, { -992, 416}, {0xa7, 0x91, 0x7b, 0xff}}}, + {{{ -55, 465, -197}, 0, { -1312, 576}, {0xa7, 0x91, 0x7b, 0xff}}}, + {{{ -28, 486, -172}, 0, { -1312, 544}, {0xa7, 0x91, 0x7b, 0xff}}}, +}; + +// 0x07007A60 - 0x07007AA0 +static const Vtx intro_seg7_vertex_07007A60[] = { + {{{ -55, 465, -197}, 0, { -1312, 576}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ -28, 486, -172}, 0, { -1312, 544}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 83, 596, -274}, 0, { -1440, 256}, {0x4a, 0x4a, 0x4a, 0xff}}}, + {{{ 89, 593, -236}, 0, { -1376, 256}, {0x4a, 0x4a, 0x4a, 0xff}}}, +}; + +#else + // 0x07000000 - 0x07000100 static const Vtx intro_seg7_vertex_07000000[] = { {{{ 498, -74, 90}, 0, { 760, 796}, {0x00, 0xf1, 0x00, 0xff}}}, @@ -2575,20 +6404,1500 @@ static const Vtx intro_seg7_vertex_07007DF0[] = { {{{ 733, 462, -217}, 0, { 0, 0}, {0xa8, 0x95, 0x37, 0xff}}}, {{{ 733, 512, -246}, 0, { 0, 0}, {0xa8, 0x95, 0x37, 0xff}}}, }; +#endif // 0x07007EA0 - 0x07007EA2 -ALIGNED8 static const Texture intro_seg7_texture_07007EA0[] = { +ALIGNED8 static const Texture intro_seg7_texture_0[] = { #include "levels/intro/0.rgba16.inc.c" }; // 0x070086A0 - 0x070086A2 -ALIGNED8 static const Texture intro_seg7_texture_070086A0[] = { +ALIGNED8 static const Texture intro_seg7_texture_1[] = { #include "levels/intro/1.rgba16.inc.c" }; +#if defined(VERSION_CN) +// 0x07008AA0 - 0x0700A398 +static const Gfx intro_seg7_dl_07008AA0[] = { + gsDPSetTextureImage(G_IM_FMT_RGBA, G_IM_SIZ_16b, 1, intro_seg7_texture_1), + gsDPLoadSync(), + gsDPLoadBlock(G_TX_LOADTILE, 0, 0, 32 * 32 - 1, CALC_DXT(32, G_IM_SIZ_16b_BYTES)), + gsSPVertex(intro_seg7_vertex_07000000, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_07000030, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_07000060, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_07000090, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_070000C0, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_070000F0, 5, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(3, 4, 2, 0), + gsSPVertex(intro_seg7_vertex_07000140, 5, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(3, 1, 4, 0), + gsSPVertex(intro_seg7_vertex_07000190, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_070001D0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_07000210, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(2, 1, 3, 0), + gsSPVertex(intro_seg7_vertex_07000250, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_07000280, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_070002B0, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_070002E0, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_07000310, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_07000340, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_07000370, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_070003A0, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_070003D0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(3, 1, 0, 0), + gsSPVertex(intro_seg7_vertex_07000410, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_07000450, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_07000490, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_070004D0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_07000510, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_07000550, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(2, 1, 3, 0), + gsSPVertex(intro_seg7_vertex_07000590, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_070005C0, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_070005F0, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_07000620, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_07000650, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_07000680, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_070006B0, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_070006E0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(2, 1, 3, 0), + gsSPVertex(intro_seg7_vertex_07000720, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_07000750, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_07000780, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_070007B0, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_070007E0, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_07000810, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_07000840, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_07000870, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_070008A0, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_070008D0, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_07000900, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_07000940, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(3, 0, 2, 0), + gsSPVertex(intro_seg7_vertex_07000980, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_070009C0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(3, 2, 1, 0), + gsSPVertex(intro_seg7_vertex_07000A00, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(2, 1, 3, 0), + gsSPVertex(intro_seg7_vertex_07000A40, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_07000A80, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(3, 2, 1, 0), + gsSPVertex(intro_seg7_vertex_07000AC0, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_07000AF0, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_07000B20, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_07000B50, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_07000B80, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_07000BB0, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_07000BE0, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_07000C10, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_07000C40, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_07000C70, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_07000CA0, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_07000CD0, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_07000D00, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_07000D30, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_07000D60, 16, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSP1Triangle(3, 4, 2, 0), + gsSP1Triangle(2, 4, 5, 0), + gsSP1Triangle(6, 7, 4, 0), + gsSP1Triangle(7, 8, 4, 0), + gsSP1Triangle(8, 9, 4, 0), + gsSP1Triangle(4, 9, 5, 0), + gsSP1Triangle(10, 11, 12, 0), + gsSP1Triangle(12, 11, 13, 0), + gsSP1Triangle(14, 5, 11, 0), + gsSP1Triangle(5, 15, 11, 0), + gsSP1Triangle(11, 15, 13, 0), + gsSPVertex(intro_seg7_vertex_07000E60, 15, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(2, 1, 3, 0), + gsSP1Triangle(4, 5, 6, 0), + gsSP1Triangle(6, 5, 7, 0), + gsSP1Triangle(7, 5, 8, 0), + gsSP1Triangle(9, 10, 5, 0), + gsSP1Triangle(5, 10, 8, 0), + gsSP1Triangle(8, 10, 11, 0), + gsSP1Triangle(12, 13, 14, 0), + gsSPVertex(intro_seg7_vertex_07000F50, 16, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(3, 4, 1, 0), + gsSP1Triangle(1, 4, 2, 0), + gsSP1Triangle(4, 5, 2, 0), + gsSP1Triangle(2, 5, 6, 0), + gsSP1Triangle(7, 8, 9, 0), + gsSP1Triangle(8, 10, 11, 0), + gsSP1Triangle(11, 12, 8, 0), + gsSP1Triangle(13, 14, 15, 0), + gsSPVertex(intro_seg7_vertex_07001050, 14, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(2, 1, 3, 0), + gsSP1Triangle(4, 5, 1, 0), + gsSP1Triangle(1, 5, 6, 0), + gsSP1Triangle(6, 7, 1, 0), + gsSP1Triangle(8, 9, 10, 0), + gsSP1Triangle(11, 12, 13, 0), + gsSPVertex(intro_seg7_vertex_07001130, 15, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSP1Triangle(2, 3, 4, 0), + gsSP1Triangle(5, 6, 0, 0), + gsSP1Triangle(0, 6, 1, 0), + gsSP1Triangle(1, 6, 7, 0), + gsSP1Triangle(7, 6, 8, 0), + gsSP1Triangle(8, 6, 9, 0), + gsSP1Triangle(6, 10, 9, 0), + gsSP1Triangle(3, 7, 11, 0), + gsSP1Triangle(11, 7, 12, 0), + gsSP1Triangle(12, 7, 8, 0), + gsSP1Triangle(13, 9, 14, 0), + gsSPVertex(intro_seg7_vertex_07001220, 5, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(2, 1, 3, 0), + gsSP1Triangle(4, 2, 3, 0), + gsSPVertex(intro_seg7_vertex_07001270, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(3, 2, 1, 0), + gsSPVertex(intro_seg7_vertex_070012B0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(3, 1, 0, 0), + gsSPVertex(intro_seg7_vertex_070012F0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_07001330, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_07001370, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(2, 1, 3, 0), + gsSPVertex(intro_seg7_vertex_070013B0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(3, 2, 1, 0), + gsSPVertex(intro_seg7_vertex_070013F0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_07001430, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(2, 1, 3, 0), + gsSPVertex(intro_seg7_vertex_07001470, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_070014B0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_070014F0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_07001530, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_07001570, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(3, 0, 2, 0), + gsSPVertex(intro_seg7_vertex_070015B0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(2, 1, 3, 0), + gsSPVertex(intro_seg7_vertex_070015F0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(3, 2, 1, 0), + gsSPVertex(intro_seg7_vertex_07001630, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_07001670, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_070016A0, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_070016D0, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_07001700, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_07001730, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_07001760, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_07001790, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(3, 2, 1, 0), + gsSPVertex(intro_seg7_vertex_070017D0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_07001810, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_07001850, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(2, 1, 3, 0), + gsSPVertex(intro_seg7_vertex_07001890, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_070018D0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_07001910, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(3, 1, 0, 0), + gsSPVertex(intro_seg7_vertex_07001950, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(2, 1, 3, 0), + gsSPVertex(intro_seg7_vertex_07001990, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_070019D0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_07001A10, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(3, 1, 0, 0), + gsSPVertex(intro_seg7_vertex_07001A50, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(3, 2, 1, 0), + gsSPVertex(intro_seg7_vertex_07001A90, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_07001AC0, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_07001AF0, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_07001B20, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(3, 2, 1, 0), + gsSPVertex(intro_seg7_vertex_07001B60, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(2, 1, 3, 0), + gsSPVertex(intro_seg7_vertex_07001BA0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_07001BE0, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_07001C10, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_07001C40, 5, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 4, 0), + gsSPVertex(intro_seg7_vertex_07001C90, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_07001CC0, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_07001CF0, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_07001D20, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(3, 1, 0, 0), + gsSPVertex(intro_seg7_vertex_07001D60, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_07001D90, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_07001DD0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(3, 2, 1, 0), + gsSPVertex(intro_seg7_vertex_07001E10, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_07001E50, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_07001E80, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_07001EB0, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_07001EE0, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_07001F10, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_07001F40, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_07001F70, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_07001FA0, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_07001FD0, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_07002000, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_07002030, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_07002060, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_07002090, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_070020C0, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_070020F0, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_07002120, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_07002150, 15, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(2, 1, 3, 0), + gsSP1Triangle(4, 5, 1, 0), + gsSP1Triangle(5, 6, 1, 0), + gsSP1Triangle(1, 6, 3, 0), + gsSP1Triangle(7, 3, 8, 0), + gsSP1Triangle(8, 3, 9, 0), + gsSP1Triangle(9, 3, 10, 0), + gsSP1Triangle(10, 3, 11, 0), + gsSP1Triangle(11, 3, 12, 0), + gsSP1Triangle(3, 6, 12, 0), + gsSP1Triangle(12, 6, 13, 0), + gsSP1Triangle(6, 14, 13, 0), + gsSPVertex(intro_seg7_vertex_07002240, 16, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSP1Triangle(4, 2, 5, 0), + gsSP1Triangle(6, 7, 8, 0), + gsSP1Triangle(7, 9, 8, 0), + gsSP1Triangle(10, 8, 11, 0), + gsSP1Triangle(11, 8, 12, 0), + gsSP1Triangle(8, 9, 12, 0), + gsSP1Triangle(13, 14, 9, 0), + gsSP1Triangle(9, 14, 15, 0), + gsSPVertex(intro_seg7_vertex_07002340, 14, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(2, 1, 3, 0), + gsSP1Triangle(4, 5, 6, 0), + gsSP1Triangle(7, 8, 5, 0), + gsSP1Triangle(8, 9, 5, 0), + gsSP1Triangle(5, 10, 6, 0), + gsSP1Triangle(10, 5, 11, 0), + gsSP1Triangle(5, 9, 11, 0), + gsSP1Triangle(12, 6, 13, 0), + gsSP1Triangle(6, 10, 13, 0), + gsSPVertex(intro_seg7_vertex_07002420, 16, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(3, 4, 1, 0), + gsSP1Triangle(4, 5, 1, 0), + gsSP1Triangle(3, 6, 4, 0), + gsSP1Triangle(4, 6, 7, 0), + gsSP1Triangle(7, 6, 8, 0), + gsSP1Triangle(6, 9, 8, 0), + gsSP1Triangle(10, 7, 8, 0), + gsSP1Triangle(11, 5, 12, 0), + gsSP1Triangle(5, 10, 12, 0), + gsSP1Triangle(13, 14, 15, 0), + gsSPVertex(intro_seg7_vertex_07002520, 11, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(3, 4, 1, 0), + gsSP1Triangle(1, 4, 2, 0), + gsSP1Triangle(4, 5, 2, 0), + gsSP1Triangle(2, 5, 6, 0), + gsSP1Triangle(7, 6, 8, 0), + gsSP1Triangle(6, 5, 8, 0), + gsSP1Triangle(5, 9, 8, 0), + gsSP1Triangle(8, 9, 10, 0), + gsSPVertex(intro_seg7_vertex_070025D0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_07002610, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_07002650, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(3, 2, 1, 0), + gsSPVertex(intro_seg7_vertex_07002690, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_070026D0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(2, 1, 3, 0), + gsSPVertex(intro_seg7_vertex_07002710, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_07002740, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_07002770, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_070027A0, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_070027D0, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_07002800, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_07002830, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_07002860, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_07002890, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_070028C0, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_070028F0, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_07002920, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_07002950, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_07002980, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_070029B0, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_070029E0, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_07002A10, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_07002A40, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_07002A70, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_07002AB0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_07002AF0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(3, 0, 2, 0), + gsSPVertex(intro_seg7_vertex_07002B30, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(2, 1, 3, 0), + gsSPVertex(intro_seg7_vertex_07002B70, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_07002BB0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(3, 1, 0, 0), + gsSPVertex(intro_seg7_vertex_07002BF0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(3, 2, 1, 0), + gsSPVertex(intro_seg7_vertex_07002C30, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_07002C70, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_07002CB0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(2, 1, 3, 0), + gsSPVertex(intro_seg7_vertex_07002CF0, 13, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(2, 1, 3, 0), + gsSP1Triangle(4, 2, 3, 0), + gsSP1Triangle(5, 6, 7, 0), + gsSP1Triangle(6, 4, 7, 0), + gsSP1Triangle(8, 7, 9, 0), + gsSP1Triangle(9, 7, 10, 0), + gsSP1Triangle(10, 7, 11, 0), + gsSP1Triangle(11, 7, 12, 0), + gsSP1Triangle(7, 4, 12, 0), + gsSP1Triangle(12, 4, 3, 0), + gsSPVertex(intro_seg7_vertex_07002DC0, 9, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(2, 1, 3, 0), + gsSP1Triangle(4, 5, 1, 0), + gsSP1Triangle(5, 6, 1, 0), + gsSP1Triangle(1, 6, 3, 0), + gsSP1Triangle(6, 7, 3, 0), + gsSP1Triangle(7, 8, 3, 0), + gsSPVertex(intro_seg7_vertex_07002E50, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_07002E90, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(2, 1, 3, 0), + gsSPVertex(intro_seg7_vertex_07002ED0, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_07002F00, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_07002F30, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_07002F60, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_07002F90, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_07002FC0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(2, 1, 3, 0), + gsSPVertex(intro_seg7_vertex_07003000, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_07003040, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_07003080, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_070030C0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(3, 0, 2, 0), + gsSPVertex(intro_seg7_vertex_07003100, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_07003140, 16, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(2, 1, 3, 0), + gsSP1Triangle(0, 4, 1, 0), + gsSP1Triangle(4, 5, 1, 0), + gsSP1Triangle(5, 6, 1, 0), + gsSP1Triangle(6, 3, 1, 0), + gsSP1Triangle(7, 8, 9, 0), + gsSP1Triangle(8, 10, 9, 0), + gsSP1Triangle(10, 8, 11, 0), + gsSP1Triangle(8, 7, 11, 0), + gsSP1Triangle(6, 12, 3, 0), + gsSP1Triangle(12, 6, 5, 0), + gsSP1Triangle(13, 14, 12, 0), + gsSP1Triangle(12, 14, 3, 0), + gsSP1Triangle(12, 15, 13, 0), + gsSPVertex(intro_seg7_vertex_07003240, 15, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 0, 3, 0), + gsSP1Triangle(4, 5, 6, 0), + gsSP1Triangle(6, 5, 7, 0), + gsSP1Triangle(2, 1, 8, 0), + gsSP1Triangle(8, 1, 3, 0), + gsSP1Triangle(9, 5, 4, 0), + gsSP1Triangle(10, 11, 5, 0), + gsSP1Triangle(11, 12, 5, 0), + gsSP1Triangle(12, 13, 5, 0), + gsSP1Triangle(7, 5, 14, 0), + gsSP1Triangle(5, 13, 14, 0), + gsSPVertex(intro_seg7_vertex_07003330, 14, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(3, 4, 5, 0), + gsSP1Triangle(6, 3, 7, 0), + gsSP1Triangle(3, 8, 7, 0), + gsSP1Triangle(4, 9, 5, 0), + gsSP1Triangle(10, 4, 2, 0), + gsSP1Triangle(4, 6, 2, 0), + gsSP1Triangle(9, 11, 5, 0), + gsSP1Triangle(5, 11, 8, 0), + gsSP1Triangle(12, 7, 13, 0), + gsSPVertex(intro_seg7_vertex_07003410, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_07003440, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_07003470, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_070034A0, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_070034D0, 15, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(3, 4, 5, 0), + gsSP1Triangle(6, 7, 8, 0), + gsSP1Triangle(9, 10, 11, 0), + gsSP1Triangle(12, 13, 14, 0), + gsSPVertex(intro_seg7_vertex_070035C0, 12, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(3, 4, 5, 0), + gsSP1Triangle(6, 7, 8, 0), + gsSP1Triangle(9, 10, 11, 0), + gsSPVertex(intro_seg7_vertex_07003680, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_070036C0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(3, 1, 0, 0), + gsSPVertex(intro_seg7_vertex_07003700, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(3, 2, 1, 0), + gsSPVertex(intro_seg7_vertex_07003740, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(3, 2, 1, 0), + gsSPVertex(intro_seg7_vertex_07003780, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_070037C0, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_070037F0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(3, 2, 1, 0), + gsSPVertex(intro_seg7_vertex_07003830, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_07003870, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(2, 1, 3, 0), + gsSPVertex(intro_seg7_vertex_070038B0, 6, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(3, 4, 5, 0), + gsSPVertex(intro_seg7_vertex_07003910, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(2, 1, 3, 0), + gsSPVertex(intro_seg7_vertex_07003950, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_07003980, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_070039B0, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_070039E0, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_07003A10, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_07003A40, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_07003A70, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_07003AA0, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_07003AD0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_07003B10, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_07003B50, 14, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSP1Triangle(3, 4, 2, 0), + gsSP1Triangle(4, 5, 2, 0), + gsSP1Triangle(5, 6, 2, 0), + gsSP1Triangle(7, 8, 9, 0), + gsSP1Triangle(9, 8, 3, 0), + gsSP1Triangle(10, 4, 8, 0), + gsSP1Triangle(8, 4, 3, 0), + gsSP1Triangle(11, 12, 13, 0), + gsSPVertex(intro_seg7_vertex_07003C30, 10, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSP1Triangle(4, 5, 6, 0), + gsSP1Triangle(7, 8, 9, 0), + gsSP1Triangle(9, 8, 4, 0), + gsSP1Triangle(8, 5, 4, 0), + gsSPVertex(intro_seg7_vertex_07003CD0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(3, 2, 1, 0), + gsSPVertex(intro_seg7_vertex_07003D10, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(2, 1, 3, 0), + gsSPVertex(intro_seg7_vertex_07003D50, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(3, 2, 1, 0), + gsSPVertex(intro_seg7_vertex_07003D90, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_07003DD0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_07003E10, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_07003E40, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(2, 1, 3, 0), + gsSPVertex(intro_seg7_vertex_07003E80, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_07003EB0, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_07003EE0, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_07003F10, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_07003F40, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_07003F70, 5, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(3, 2, 4, 0), + gsSP1Triangle(4, 2, 1, 0), + gsSPVertex(intro_seg7_vertex_07003FC0, 5, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(3, 0, 4, 0), + gsSP1Triangle(4, 0, 2, 0), + gsSPVertex(intro_seg7_vertex_07004010, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(3, 0, 2, 0), + gsSPVertex(intro_seg7_vertex_07004050, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(2, 1, 3, 0), + gsSPVertex(intro_seg7_vertex_07004090, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(2, 1, 3, 0), + gsSPVertex(intro_seg7_vertex_070040D0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(2, 1, 3, 0), + gsSPVertex(intro_seg7_vertex_07004110, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_07004150, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(3, 2, 1, 0), + gsSPVertex(intro_seg7_vertex_07004190, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_070041C0, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_070041F0, 6, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSP1Triangle(4, 2, 5, 0), + gsSP1Triangle(2, 3, 5, 0), + gsSPVertex(intro_seg7_vertex_07004250, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_07004290, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_070042D0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(2, 1, 3, 0), + gsSPVertex(intro_seg7_vertex_07004310, 14, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(3, 4, 1, 0), + gsSP1Triangle(4, 5, 1, 0), + gsSP1Triangle(5, 6, 1, 0), + gsSP1Triangle(6, 7, 1, 0), + gsSP1Triangle(1, 7, 2, 0), + gsSP1Triangle(7, 8, 2, 0), + gsSP1Triangle(9, 10, 3, 0), + gsSP1Triangle(10, 11, 3, 0), + gsSP1Triangle(11, 4, 3, 0), + gsSP1Triangle(12, 13, 5, 0), + gsSP1Triangle(13, 6, 5, 0), + gsSPVertex(intro_seg7_vertex_070043F0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_07004430, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(2, 1, 3, 0), + gsSPEndDisplayList(), +}; + +// 0x0700A398 - 0x0700B7E8 +static const Gfx intro_seg7_dl_0700A398[] = { + gsDPSetTextureImage(G_IM_FMT_RGBA, G_IM_SIZ_16b, 1, intro_seg7_texture_0), + gsDPLoadSync(), + gsDPLoadBlock(G_TX_LOADTILE, 0, 0, 32 * 32 - 1, CALC_DXT(32, G_IM_SIZ_16b_BYTES)), + gsSPVertex(intro_seg7_vertex_07004470, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_070044B0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(2, 1, 3, 0), + gsSPVertex(intro_seg7_vertex_070044F0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_07004530, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_07004570, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(2, 1, 3, 0), + gsSPVertex(intro_seg7_vertex_070045B0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_070045F0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_07004630, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(2, 1, 3, 0), + gsSPVertex(intro_seg7_vertex_07004670, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_070046B0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_070046F0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_07004730, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_07004770, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_070047B0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_070047F0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(3, 1, 0, 0), + gsSPVertex(intro_seg7_vertex_07004830, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_07004870, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(2, 1, 3, 0), + gsSPVertex(intro_seg7_vertex_070048B0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(2, 1, 3, 0), + gsSPVertex(intro_seg7_vertex_070048F0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_07004930, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_07004970, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(2, 1, 3, 0), + gsSPVertex(intro_seg7_vertex_070049B0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_070049F0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_07004A30, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_07004A70, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_07004AB0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_07004AF0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_07004B30, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_07004B70, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_07004BB0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_07004BF0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_07004C30, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_07004C70, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_07004CB0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_07004CF0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(3, 1, 0, 0), + gsSPVertex(intro_seg7_vertex_07004D30, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(3, 1, 0, 0), + gsSPVertex(intro_seg7_vertex_07004D70, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_07004DB0, 6, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(2, 3, 0, 0), + gsSP1Triangle(0, 3, 4, 0), + gsSP1Triangle(5, 2, 1, 0), + gsSPVertex(intro_seg7_vertex_07004E10, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_07004E50, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_07004E90, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_07004ED0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_07004F10, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_07004F50, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(2, 1, 3, 0), + gsSPVertex(intro_seg7_vertex_07004F90, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(2, 1, 3, 0), + gsSPVertex(intro_seg7_vertex_07004FD0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(3, 1, 0, 0), + gsSPVertex(intro_seg7_vertex_07005010, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_07005050, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(2, 1, 3, 0), + gsSPVertex(intro_seg7_vertex_07005090, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(2, 1, 3, 0), + gsSPVertex(intro_seg7_vertex_070050D0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(2, 1, 3, 0), + gsSPVertex(intro_seg7_vertex_07005110, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_07005150, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_07005190, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(2, 1, 3, 0), + gsSPVertex(intro_seg7_vertex_070051D0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(2, 1, 3, 0), + gsSPVertex(intro_seg7_vertex_07005210, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(3, 1, 0, 0), + gsSPVertex(intro_seg7_vertex_07005250, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_07005290, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(2, 1, 3, 0), + gsSPVertex(intro_seg7_vertex_070052D0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_07005310, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(3, 1, 0, 0), + gsSPVertex(intro_seg7_vertex_07005350, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_07005390, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(3, 1, 0, 0), + gsSPVertex(intro_seg7_vertex_070053D0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(2, 1, 3, 0), + gsSPVertex(intro_seg7_vertex_07005410, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_07005450, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(2, 1, 3, 0), + gsSPVertex(intro_seg7_vertex_07005490, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(3, 2, 1, 0), + gsSPVertex(intro_seg7_vertex_070054D0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_07005510, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_07005550, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_07005590, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(2, 1, 3, 0), + gsSPVertex(intro_seg7_vertex_070055D0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_07005610, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(2, 1, 3, 0), + gsSPVertex(intro_seg7_vertex_07005650, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(2, 1, 3, 0), + gsSPVertex(intro_seg7_vertex_07005690, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(3, 2, 1, 0), + gsSPVertex(intro_seg7_vertex_070056D0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(3, 1, 0, 0), + gsSPVertex(intro_seg7_vertex_07005710, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_07005750, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(2, 1, 3, 0), + gsSPVertex(intro_seg7_vertex_07005790, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(2, 1, 3, 0), + gsSPVertex(intro_seg7_vertex_070057D0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_07005810, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_07005850, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_07005890, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_070058D0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(3, 0, 2, 0), + gsSPVertex(intro_seg7_vertex_07005910, 6, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(3, 4, 5, 0), + gsSPVertex(intro_seg7_vertex_07005970, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(3, 1, 0, 0), + gsSPVertex(intro_seg7_vertex_070059B0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(3, 1, 0, 0), + gsSPVertex(intro_seg7_vertex_070059F0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(2, 1, 3, 0), + gsSPVertex(intro_seg7_vertex_07005A30, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_07005A60, 3, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSPVertex(intro_seg7_vertex_07005A90, 6, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(3, 4, 5, 0), + gsSPVertex(intro_seg7_vertex_07005AF0, 6, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(3, 4, 5, 0), + gsSPVertex(intro_seg7_vertex_07005B50, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(2, 1, 3, 0), + gsSPVertex(intro_seg7_vertex_07005B90, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(3, 0, 2, 0), + gsSPVertex(intro_seg7_vertex_07005BD0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(2, 1, 3, 0), + gsSPVertex(intro_seg7_vertex_07005C10, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_07005C50, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_07005C90, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_07005CD0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(3, 1, 0, 0), + gsSPVertex(intro_seg7_vertex_07005D10, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_07005D50, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(3, 1, 0, 0), + gsSPVertex(intro_seg7_vertex_07005D90, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(2, 1, 3, 0), + gsSPVertex(intro_seg7_vertex_07005DD0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(3, 0, 2, 0), + gsSPVertex(intro_seg7_vertex_07005E10, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(3, 0, 2, 0), + gsSPVertex(intro_seg7_vertex_07005E50, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(3, 0, 2, 0), + gsSPVertex(intro_seg7_vertex_07005E90, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(3, 0, 2, 0), + gsSPVertex(intro_seg7_vertex_07005ED0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(2, 1, 3, 0), + gsSPVertex(intro_seg7_vertex_07005F10, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(3, 0, 2, 0), + gsSPVertex(intro_seg7_vertex_07005F50, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(3, 0, 2, 0), + gsSPVertex(intro_seg7_vertex_07005F90, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(3, 2, 1, 0), + gsSPVertex(intro_seg7_vertex_07005FD0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_07006010, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_07006050, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_07006090, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_070060D0, 5, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(2, 1, 3, 0), + gsSP1Triangle(4, 3, 1, 0), + gsSPVertex(intro_seg7_vertex_07006120, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(2, 1, 3, 0), + gsSPVertex(intro_seg7_vertex_07006160, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(2, 1, 3, 0), + gsSPVertex(intro_seg7_vertex_070061A0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_070061E0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_07006220, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_07006260, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(2, 1, 3, 0), + gsSPVertex(intro_seg7_vertex_070062A0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(3, 2, 1, 0), + gsSPVertex(intro_seg7_vertex_070062E0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_07006320, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(3, 2, 1, 0), + gsSPVertex(intro_seg7_vertex_07006360, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(2, 1, 3, 0), + gsSPVertex(intro_seg7_vertex_070063A0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(2, 1, 3, 0), + gsSPVertex(intro_seg7_vertex_070063E0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_07006420, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_07006460, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(2, 1, 3, 0), + gsSPVertex(intro_seg7_vertex_070064A0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_070064E0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(3, 2, 1, 0), + gsSPVertex(intro_seg7_vertex_07006520, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(2, 1, 3, 0), + gsSPVertex(intro_seg7_vertex_07006560, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_070065A0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(3, 2, 1, 0), + gsSPVertex(intro_seg7_vertex_070065E0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(3, 2, 1, 0), + gsSPVertex(intro_seg7_vertex_07006620, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(2, 1, 3, 0), + gsSPVertex(intro_seg7_vertex_07006660, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(3, 2, 1, 0), + gsSPVertex(intro_seg7_vertex_070066A0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_070066E0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(3, 2, 1, 0), + gsSPVertex(intro_seg7_vertex_07006720, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(2, 1, 3, 0), + gsSPVertex(intro_seg7_vertex_07006760, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_070067A0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(2, 1, 3, 0), + gsSPVertex(intro_seg7_vertex_070067E0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(2, 1, 3, 0), + gsSPVertex(intro_seg7_vertex_07006820, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(2, 1, 3, 0), + gsSPVertex(intro_seg7_vertex_07006860, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(3, 2, 1, 0), + gsSPVertex(intro_seg7_vertex_070068A0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(2, 1, 3, 0), + gsSPVertex(intro_seg7_vertex_070068E0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(2, 1, 3, 0), + gsSPVertex(intro_seg7_vertex_07006920, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(2, 1, 3, 0), + gsSPVertex(intro_seg7_vertex_07006960, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(2, 1, 3, 0), + gsSPVertex(intro_seg7_vertex_070069A0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(2, 1, 3, 0), + gsSPVertex(intro_seg7_vertex_070069E0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(2, 1, 3, 0), + gsSPVertex(intro_seg7_vertex_07006A20, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(3, 2, 1, 0), + gsSPVertex(intro_seg7_vertex_07006A60, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(2, 1, 3, 0), + gsSPVertex(intro_seg7_vertex_07006AA0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(2, 1, 3, 0), + gsSPVertex(intro_seg7_vertex_07006AE0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(2, 1, 3, 0), + gsSPVertex(intro_seg7_vertex_07006B20, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_07006B60, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_07006BA0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(2, 1, 3, 0), + gsSPVertex(intro_seg7_vertex_07006BE0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(2, 1, 3, 0), + gsSPVertex(intro_seg7_vertex_07006C20, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(2, 1, 3, 0), + gsSPVertex(intro_seg7_vertex_07006C60, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(2, 1, 3, 0), + gsSPVertex(intro_seg7_vertex_07006CA0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(3, 2, 1, 0), + gsSPVertex(intro_seg7_vertex_07006CE0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_07006D20, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(2, 1, 3, 0), + gsSPVertex(intro_seg7_vertex_07006D60, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(2, 1, 3, 0), + gsSPVertex(intro_seg7_vertex_07006DA0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(2, 1, 3, 0), + gsSPVertex(intro_seg7_vertex_07006DE0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(3, 2, 1, 0), + gsSPVertex(intro_seg7_vertex_07006E20, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_07006E60, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(2, 1, 3, 0), + gsSPVertex(intro_seg7_vertex_07006EA0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(2, 1, 3, 0), + gsSPVertex(intro_seg7_vertex_07006EE0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_07006F20, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(2, 1, 3, 0), + gsSPVertex(intro_seg7_vertex_07006F60, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(2, 1, 3, 0), + gsSPVertex(intro_seg7_vertex_07006FA0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_07006FE0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(2, 1, 3, 0), + gsSPVertex(intro_seg7_vertex_07007020, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(3, 2, 1, 0), + gsSPVertex(intro_seg7_vertex_07007060, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(2, 1, 3, 0), + gsSPVertex(intro_seg7_vertex_070070A0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(2, 1, 3, 0), + gsSPVertex(intro_seg7_vertex_070070E0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(3, 2, 1, 0), + gsSPVertex(intro_seg7_vertex_07007120, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(3, 2, 1, 0), + gsSPVertex(intro_seg7_vertex_07007160, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(2, 1, 3, 0), + gsSPVertex(intro_seg7_vertex_070071A0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(3, 2, 1, 0), + gsSPVertex(intro_seg7_vertex_070071E0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(3, 2, 1, 0), + gsSPVertex(intro_seg7_vertex_07007220, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(2, 1, 3, 0), + gsSPVertex(intro_seg7_vertex_07007260, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(2, 1, 3, 0), + gsSPVertex(intro_seg7_vertex_070072A0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(2, 1, 3, 0), + gsSPVertex(intro_seg7_vertex_070072E0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(3, 2, 1, 0), + gsSPVertex(intro_seg7_vertex_07007320, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_07007360, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(2, 1, 3, 0), + gsSPVertex(intro_seg7_vertex_070073A0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_070073E0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_07007420, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(2, 1, 3, 0), + gsSPVertex(intro_seg7_vertex_07007460, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(2, 1, 3, 0), + gsSPVertex(intro_seg7_vertex_070074A0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(2, 1, 3, 0), + gsSPVertex(intro_seg7_vertex_070074E0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(3, 2, 1, 0), + gsSPVertex(intro_seg7_vertex_07007520, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(3, 2, 1, 0), + gsSPVertex(intro_seg7_vertex_07007560, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_070075A0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(2, 1, 3, 0), + gsSPVertex(intro_seg7_vertex_070075E0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(2, 1, 3, 0), + gsSPVertex(intro_seg7_vertex_07007620, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_07007660, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(2, 1, 3, 0), + gsSPVertex(intro_seg7_vertex_070076A0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_070076E0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_07007720, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(3, 2, 1, 0), + gsSPVertex(intro_seg7_vertex_07007760, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_070077A0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(2, 1, 3, 0), + gsSPVertex(intro_seg7_vertex_070077E0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(2, 1, 3, 0), + gsSPVertex(intro_seg7_vertex_07007820, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(3, 2, 1, 0), + gsSPVertex(intro_seg7_vertex_07007860, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(3, 2, 1, 0), + gsSPVertex(intro_seg7_vertex_070078A0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(2, 1, 3, 0), + gsSPVertex(intro_seg7_vertex_070078E0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_07007920, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(3, 2, 1, 0), + gsSPVertex(intro_seg7_vertex_07007960, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(3, 2, 1, 0), + gsSPVertex(intro_seg7_vertex_070079A0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_070079E0, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_07007A20, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPVertex(intro_seg7_vertex_07007A60, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(1, 3, 2, 0), + gsSPEndDisplayList(), +}; + +// 0x0700B7E8 - 0x0700B860 +const Gfx intro_seg7_dl_logo[] = { + gsDPPipeSync(), + gsDPSetCombineMode(G_CC_MODULATEI, G_CC_MODULATEI), + gsSPClearGeometryMode(G_LIGHTING), + gsDPSetTile(G_IM_FMT_RGBA, G_IM_SIZ_16b, 0, 0x0000, G_TX_LOADTILE, 0, G_TX_NOMIRROR | G_TX_WRAP, G_TX_NOMASK, G_TX_NOLOD, G_TX_NOMIRROR | G_TX_WRAP, G_TX_NOMASK, G_TX_NOLOD), + gsSPTexture(0xFFFF, 0xFFFF, 0, G_TX_RENDERTILE, G_ON), + gsDPTileSync(), + gsDPSetTile(G_IM_FMT_RGBA, G_IM_SIZ_16b, 8, 0x0000, G_TX_RENDERTILE, 0, G_TX_NOMIRROR | G_TX_WRAP, 5, G_TX_NOLOD, G_TX_NOMIRROR | G_TX_WRAP, 5, G_TX_NOLOD), + gsDPSetTileSize(G_TX_RENDERTILE, 0, 0, (32 - 1) << G_TEXTURE_IMAGE_FRAC, (32 - 1) << G_TEXTURE_IMAGE_FRAC), + gsSPDisplayList(intro_seg7_dl_07008AA0), + gsSPDisplayList(intro_seg7_dl_0700A398), + gsSPTexture(0xFFFF, 0xFFFF, 0, G_TX_RENDERTILE, G_OFF), + gsDPPipeSync(), + gsDPSetCombineMode(G_CC_SHADE, G_CC_SHADE), + gsSPSetGeometryMode(G_LIGHTING), + gsSPEndDisplayList(), +}; + +#else + // 0x07008EA0 - 0x07009E38 static const Gfx intro_seg7_dl_07008EA0[] = { - gsDPSetTextureImage(G_IM_FMT_RGBA, G_IM_SIZ_16b, 1, intro_seg7_texture_070086A0), + gsDPSetTextureImage(G_IM_FMT_RGBA, G_IM_SIZ_16b, 1, intro_seg7_texture_1), gsDPLoadSync(), gsDPLoadBlock(G_TX_LOADTILE, 0, 0, 32 * 32 - 1, CALC_DXT(32, G_IM_SIZ_16b_BYTES)), gsSPVertex(intro_seg7_vertex_07000000, 16, 0), @@ -2885,7 +8194,7 @@ static const Gfx intro_seg7_dl_07008EA0[] = { // 0x07009E38 - 0x0700ADC0 static const Gfx intro_seg7_dl_07009E38[] = { - gsDPSetTextureImage(G_IM_FMT_RGBA, G_IM_SIZ_16b, 1, intro_seg7_texture_07007EA0), + gsDPSetTextureImage(G_IM_FMT_RGBA, G_IM_SIZ_16b, 1, intro_seg7_texture_0), gsDPLoadSync(), gsDPLoadBlock(G_TX_LOADTILE, 0, 0, 32 * 32 - 1, CALC_DXT(32, G_IM_SIZ_16b_BYTES)), gsSPVertex(intro_seg7_vertex_07003500, 15, 0), @@ -3298,7 +8607,7 @@ static const Gfx intro_seg7_dl_0700ADC0[] = { }; // 0x0700B3A0 - 0x0700B420 -const Gfx intro_seg7_dl_0700B3A0[] = { +const Gfx intro_seg7_dl_logo[] = { gsDPPipeSync(), gsDPSetCombineMode(G_CC_MODULATERGB, G_CC_MODULATERGB), gsSPClearGeometryMode(G_LIGHTING), @@ -3317,16 +8626,38 @@ const Gfx intro_seg7_dl_0700B3A0[] = { gsSPEndDisplayList(), }; -// 0x0700B420 - 0x0700B460 -static const Vtx intro_seg7_vertex_0700B420[] = { +#endif + +#if defined(VERSION_CN) +// 0x0700B860 - 0x0700B8A0 +static const Vtx intro_seg7_vertex_copyright_ique[] = { {{{ 96, 42, -1}, 0, { 0, 512}, {0xff, 0xff, 0xff, 0xff}}}, {{{ 224, 42, -1}, 0, { 4096, 512}, {0xff, 0xff, 0xff, 0xff}}}, {{{ 224, 58, -1}, 0, { 4096, 0}, {0xff, 0xff, 0xff, 0xff}}}, {{{ 96, 58, -1}, 0, { 0, 0}, {0xff, 0xff, 0xff, 0xff}}}, }; +// 0x0700B8A0 - 0x0700B8E0 +static const Vtx intro_seg7_vertex_copyright[] = { + {{{ 96, 58, -1}, 0, { 0, 512}, {0xff, 0xff, 0xff, 0xff}}}, + {{{ 224, 58, -1}, 0, { 4096, 512}, {0xff, 0xff, 0xff, 0xff}}}, + {{{ 224, 75, -1}, 0, { 4096, 0}, {0xff, 0xff, 0xff, 0xff}}}, + {{{ 96, 75, -1}, 0, { 0, 0}, {0xff, 0xff, 0xff, 0xff}}}, +}; + +#else + +// 0x0700B420 - 0x0700B460 +static const Vtx intro_seg7_vertex_copyright[] = { + {{{ 96, 42, -1}, 0, { 0, 512}, {0xff, 0xff, 0xff, 0xff}}}, + {{{ 224, 42, -1}, 0, { 4096, 512}, {0xff, 0xff, 0xff, 0xff}}}, + {{{ 224, 58, -1}, 0, { 4096, 0}, {0xff, 0xff, 0xff, 0xff}}}, + {{{ 96, 58, -1}, 0, { 0, 0}, {0xff, 0xff, 0xff, 0xff}}}, +}; +#endif + // 0x0700B460 - 0x0700B4A0 -static const Vtx intro_seg7_vertex_0700B460[] = { +static const Vtx intro_seg7_vertex_tm[] = { {{{ 268, 180, -1}, 0, { 0, 512}, {0xff, 0xff, 0xff, 0xff}}}, {{{ 284, 180, -1}, 0, { 544, 512}, {0xff, 0xff, 0xff, 0xff}}}, {{{ 284, 196, -1}, 0, { 544, 0}, {0xff, 0xff, 0xff, 0xff}}}, @@ -3335,45 +8666,63 @@ static const Vtx intro_seg7_vertex_0700B460[] = { #if defined(VERSION_EU) || defined(VERSION_SH) // 0x0700B4A0 - 0x0700B4A2 -ALIGNED8 static const Texture intro_seg7_texture_0700B4A0[] = { +ALIGNED8 static const Texture intro_seg7_texture_copyright[] = { #include "levels/intro/2_eu_copyright.rgba16.inc.c" }; +#elif defined(VERSION_CN) +// 0x0700B920 - 0x0700C920 +ALIGNED8 static const Texture intro_seg7_texture_copyright[] = { +#include "levels/intro/2_cn_copyright.rgba16.inc.c" +}; + +// 0x0700C920 - 0x0700D920 +ALIGNED8 static const Texture intro_seg7_texture_copyright_ique[] = { +#include "levels/intro/2_cn_copyright_ique.rgba16.inc.c" +}; + #else // 0x0700B4A0 - 0x0700B4A2 -ALIGNED8 static const Texture intro_seg7_texture_0700B4A0[] = { +ALIGNED8 static const Texture intro_seg7_texture_copyright[] = { #include "levels/intro/2_copyright.rgba16.inc.c" }; #endif #if defined(VERSION_EU) // 0x0700C4A0 - 0x0700D4A0 -ALIGNED8 static const u8 intro_seg7_texture_0700C4A0[] = { +ALIGNED8 static const u8 intro_seg7_texture_tm[] = { #include "levels/intro/3_eu_tm.rgba16.inc.c" }; -#elif defined(VERSION_SH) -ALIGNED8 static const u8 intro_seg7_texture_0700C4A0[] = { + +#elif defined(VERSION_SH) || defined(VERSION_CN) +ALIGNED8 static const u8 intro_seg7_texture_tm[] = { #include "levels/intro/3_sh_tm.rgba16.inc.c" }; + #else // 0x0700C4A0 - 0x0700D4A0 -ALIGNED8 static const Texture intro_seg7_texture_0700C4A0[] = { +ALIGNED8 static const Texture intro_seg7_texture_tm[] = { #include "levels/intro/3_tm.rgba16.inc.c" }; #endif // 0x0700C6A0 - 0x0700C790 -const Gfx intro_seg7_dl_0700C6A0[] = { +const Gfx intro_seg7_dl_copyright[] = { gsDPPipeSync(), gsDPSetCombineMode(G_CC_DECALFADE, G_CC_DECALFADE), gsSPTexture(0xFFFF, 0xFFFF, 0, G_TX_RENDERTILE, G_ON), - - gsDPLoadTextureBlock(intro_seg7_texture_0700B4A0, G_IM_FMT_RGBA, G_IM_SIZ_16b, 128, 16, 0, G_TX_CLAMP, G_TX_CLAMP, 7, 4, G_TX_NOLOD, G_TX_NOLOD), - gsSPVertex(intro_seg7_vertex_0700B420, 4, 0), +#if defined(VERSION_CN) + gsDPLoadTextureBlock(intro_seg7_texture_copyright_ique, G_IM_FMT_RGBA, G_IM_SIZ_16b, 128, 16, 0, G_TX_NOMIRROR | G_TX_CLAMP, G_TX_NOMIRROR | G_TX_CLAMP, 7, 4, G_TX_NOLOD, G_TX_NOLOD), + gsSPVertex(intro_seg7_vertex_copyright_ique, 4, 0), + gsSP1Triangle(0, 1, 2, 0), + gsSP1Triangle(0, 2, 3, 0), +#endif + gsDPLoadTextureBlock(intro_seg7_texture_copyright, G_IM_FMT_RGBA, G_IM_SIZ_16b, 128, 16, 0, G_TX_CLAMP, G_TX_CLAMP, 7, 4, G_TX_NOLOD, G_TX_NOLOD), + gsSPVertex(intro_seg7_vertex_copyright, 4, 0), gsSP2Triangles( 0, 1, 2, 0x0, 0, 2, 3, 0x0), - gsDPLoadTextureBlock(intro_seg7_texture_0700C4A0, G_IM_FMT_RGBA, G_IM_SIZ_16b, 16, 16, 0, G_TX_CLAMP, G_TX_CLAMP, 4, 4, G_TX_NOLOD, G_TX_NOLOD), - gsSPVertex(intro_seg7_vertex_0700B460, 4, 0), + gsDPLoadTextureBlock(intro_seg7_texture_tm, G_IM_FMT_RGBA, G_IM_SIZ_16b, 16, 16, 0, G_TX_CLAMP, G_TX_CLAMP, 4, 4, G_TX_NOLOD, G_TX_NOLOD), + gsSPVertex(intro_seg7_vertex_tm, 4, 0), gsSP2Triangles( 0, 1, 2, 0x0, 0, 2, 3, 0x0), gsSPTexture(0xFFFF, 0xFFFF, 0, G_TX_RENDERTILE, G_OFF), diff --git a/levels/intro/script.c b/levels/intro/script.c index 04b8fc4c..60fe93f3 100644 --- a/levels/intro/script.c +++ b/levels/intro/script.c @@ -21,7 +21,7 @@ const LevelScript level_intro_splash_screen[] = { INIT_LEVEL(), FIXED_LOAD(/*loadAddr*/ _goddardSegmentStart, /*romStart*/ _goddardSegmentRomStart, /*romEnd*/ _goddardSegmentRomEnd), - LOAD_RAW(/*seg*/ 0x13, _behaviorSegmentRomStart, _behaviorSegmentRomEnd), + LOAD_RAW (/*seg*/ 0x13, _behaviorSegmentRomStart, _behaviorSegmentRomEnd), LOAD_MIO0(/*seg*/ 0x07, _intro_segment_7SegmentRomStart, _intro_segment_7SegmentRomEnd), // Load "Super Mario 64" logo @@ -48,7 +48,7 @@ const LevelScript level_intro_mario_head_regular[] = { BLACKOUT(/*active*/ TRUE), FIXED_LOAD(/*loadAddr*/ _goddardSegmentStart, /*romStart*/ _goddardSegmentRomStart, /*romEnd*/ _goddardSegmentRomEnd), LOAD_MARIO_HEAD(/*loadHeadID*/ REGULAR_FACE), - LOAD_RAW(/*seg*/ 0x13, _behaviorSegmentRomStart, _behaviorSegmentRomEnd), + LOAD_RAW (/*seg*/ 0x13, _behaviorSegmentRomStart, _behaviorSegmentRomEnd), LOAD_MIO0_TEXTURE(/*seg*/ 0x0A, _title_screen_bg_mio0SegmentRomStart, _title_screen_bg_mio0SegmentRomEnd), ALLOC_LEVEL_POOL(), @@ -73,7 +73,7 @@ const LevelScript level_intro_mario_head_dizzy[] = { BLACKOUT(/*active*/ TRUE), FIXED_LOAD(/*loadAddr*/ _goddardSegmentStart, /*romStart*/ _goddardSegmentRomStart, /*romEnd*/ _goddardSegmentRomEnd), LOAD_MARIO_HEAD(/*loadHeadID*/ DIZZY_FACE), - LOAD_RAW(/*seg*/ 0x13, _behaviorSegmentRomStart, _behaviorSegmentRomEnd), + LOAD_RAW (/*seg*/ 0x13, _behaviorSegmentRomStart, _behaviorSegmentRomEnd), LOAD_MIO0_TEXTURE(/*seg*/ 0x0A, _title_screen_bg_mio0SegmentRomStart, _title_screen_bg_mio0SegmentRomEnd), ALLOC_LEVEL_POOL(), @@ -95,9 +95,9 @@ const LevelScript level_intro_mario_head_dizzy[] = { const LevelScript level_intro_entry_4[] = { INIT_LEVEL(), - LOAD_RAW(/*seg*/ 0x13, _behaviorSegmentRomStart, _behaviorSegmentRomEnd), + LOAD_RAW (/*seg*/ 0x13, _behaviorSegmentRomStart, _behaviorSegmentRomEnd), LOAD_MIO0_TEXTURE(/*seg*/ 0x0A, _title_screen_bg_mio0SegmentRomStart, _title_screen_bg_mio0SegmentRomEnd), - LOAD_MIO0(/*seg*/ 0x07, _debug_level_select_mio0SegmentRomStart, _debug_level_select_mio0SegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x07, _debug_level_select_mio0SegmentRomStart, _debug_level_select_mio0SegmentRomEnd), FIXED_LOAD(/*loadAddr*/ _goddardSegmentStart, /*romStart*/ _goddardSegmentRomStart, /*romEnd*/ _goddardSegmentRomEnd), ALLOC_LEVEL_POOL(), diff --git a/levels/jrb/areas/1/geo.inc.c b/levels/jrb/areas/1/geo.inc.c index 2a38df57..de74d6cf 100644 --- a/levels/jrb/areas/1/geo.inc.c +++ b/levels/jrb/areas/1/geo.inc.c @@ -1,39 +1,39 @@ // 0x0E000A18 const GeoLayout jrb_geo_000A18[] = { - GEO_NODE_SCREEN_AREA(10, SCREEN_WIDTH/2, SCREEN_HEIGHT/2, SCREEN_WIDTH/2, SCREEN_HEIGHT/2), - GEO_OPEN_NODE(), - GEO_ZBUFFER(0), - GEO_OPEN_NODE(), - GEO_NODE_ORTHO(100), - GEO_OPEN_NODE(), - GEO_BACKGROUND(BACKGROUND_ABOVE_CLOUDS, geo_skybox_main), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ZBUFFER(1), - GEO_OPEN_NODE(), - GEO_CAMERA_FRUSTUM_WITH_FUNC(45, 100, 25000, geo_camera_fov), - GEO_OPEN_NODE(), - GEO_CAMERA(16, 0, 2000, 6000, 0, 0, 0, geo_camera_main), + GEO_NODE_SCREEN_AREA(10, SCREEN_WIDTH/2, SCREEN_HEIGHT/2, SCREEN_WIDTH/2, SCREEN_HEIGHT/2), + GEO_OPEN_NODE(), + GEO_ZBUFFER(0), + GEO_OPEN_NODE(), + GEO_NODE_ORTHO(100), GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, jrb_seg7_dl_07002FD0), - GEO_DISPLAY_LIST(LAYER_OPAQUE, jrb_seg7_dl_07004940), - GEO_DISPLAY_LIST(LAYER_OPAQUE, jrb_seg7_dl_07004C78), - GEO_DISPLAY_LIST(LAYER_OPAQUE, jrb_seg7_dl_070058C8), - GEO_DISPLAY_LIST(LAYER_OPAQUE, jrb_seg7_dl_070069B0), - GEO_DISPLAY_LIST(LAYER_OPAQUE, jrb_seg7_dl_07007570), - GEO_DISPLAY_LIST(LAYER_ALPHA, jrb_seg7_dl_07007718), - GEO_ASM( 0, geo_movtex_pause_control), - GEO_ASM(0x1201, geo_movtex_draw_water_regions), - GEO_ASM(0x1205, geo_movtex_draw_water_regions), - GEO_RENDER_OBJ(), - GEO_ASM( 14, geo_envfx_main), + GEO_BACKGROUND(BACKGROUND_ABOVE_CLOUDS, geo_skybox_main), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ZBUFFER(0), - GEO_OPEN_NODE(), - GEO_ASM(0, geo_cannon_circle_base), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CLOSE_NODE(), + GEO_ZBUFFER(1), + GEO_OPEN_NODE(), + GEO_CAMERA_FRUSTUM_WITH_FUNC(45, 100, 25000, geo_camera_fov), + GEO_OPEN_NODE(), + GEO_CAMERA(16, 0, 2000, 6000, 0, 0, 0, geo_camera_main), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, jrb_seg7_dl_07002FD0), + GEO_DISPLAY_LIST(LAYER_OPAQUE, jrb_seg7_dl_07004940), + GEO_DISPLAY_LIST(LAYER_OPAQUE, jrb_seg7_dl_07004C78), + GEO_DISPLAY_LIST(LAYER_OPAQUE, jrb_seg7_dl_070058C8), + GEO_DISPLAY_LIST(LAYER_OPAQUE, jrb_seg7_dl_070069B0), + GEO_DISPLAY_LIST(LAYER_OPAQUE, jrb_seg7_dl_07007570), + GEO_DISPLAY_LIST(LAYER_ALPHA, jrb_seg7_dl_07007718), + GEO_ASM( 0, geo_movtex_pause_control), + GEO_ASM(0x1201, geo_movtex_draw_water_regions), + GEO_ASM(0x1205, geo_movtex_draw_water_regions), + GEO_RENDER_OBJ(), + GEO_ASM( 14, geo_envfx_main), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ZBUFFER(0), + GEO_OPEN_NODE(), + GEO_ASM(0, geo_cannon_circle_base), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/jrb/areas/1/macro.inc.c b/levels/jrb/areas/1/macro.inc.c index f183a655..a9e9055d 100644 --- a/levels/jrb/areas/1/macro.inc.c +++ b/levels/jrb/areas/1/macro.inc.c @@ -1,66 +1,66 @@ // 0x0700C4E8 - 0x0700C756 const MacroObject jrb_seg7_area_1_macro_objs[] = { - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 250, /*pos*/ -6325, 1126, 1730, /*behParam*/ DIALOG_060), - MACRO_OBJECT(/*preset*/ macro_coin_ring_vertical, /*yaw*/ 0, /*pos*/ 5060, -4420, 720), - MACRO_OBJECT(/*preset*/ macro_box_metal_cap, /*yaw*/ 0, /*pos*/ 2077, 1832, 7465), - MACRO_OBJECT(/*preset*/ macro_coin_ring_horizontal_flying, /*yaw*/ 0, /*pos*/ -1780, -650, 4200), - MACRO_OBJECT(/*preset*/ macro_floor_switch_hidden_objects, /*yaw*/ 45, /*pos*/ 2260, 1536, 6854), - MACRO_OBJECT(/*preset*/ macro_hidden_box, /*yaw*/ 45, /*pos*/ 4269, 1336, 4866), - MACRO_OBJECT(/*preset*/ macro_hidden_box, /*yaw*/ 45, /*pos*/ 4128, 1336, 5007), - MACRO_OBJECT(/*preset*/ macro_hidden_box, /*yaw*/ 45, /*pos*/ 3400, 1336, 5155), - MACRO_OBJECT(/*preset*/ macro_hidden_box, /*yaw*/ 45, /*pos*/ 3261, 1336, 5294), - MACRO_OBJECT(/*preset*/ macro_hidden_box, /*yaw*/ 45, /*pos*/ 3120, 1336, 5435), - MACRO_OBJECT(/*preset*/ macro_seaweed_bundle, /*yaw*/ 0, /*pos*/ 3551, -5120, 2744), - MACRO_OBJECT(/*preset*/ macro_seaweed_bundle, /*yaw*/ 0, /*pos*/ 4201, -5120, 3863), - MACRO_OBJECT(/*preset*/ macro_coin_ring_horizontal, /*yaw*/ 0, /*pos*/ -2440, -2980, -4120), - MACRO_OBJECT(/*preset*/ macro_box_metal_cap, /*yaw*/ 0, /*pos*/ 279, -2600, -7340), - MACRO_OBJECT(/*preset*/ macro_seaweed_bundle, /*yaw*/ 0, /*pos*/ 4846, -5119, 1213), - MACRO_OBJECT(/*preset*/ macro_seaweed_bundle, /*yaw*/ 0, /*pos*/ -800, -1023, 4040), - MACRO_OBJECT(/*preset*/ macro_hidden_box, /*yaw*/ 45, /*pos*/ 3621, 1336, 6529), - MACRO_OBJECT(/*preset*/ macro_hidden_box, /*yaw*/ 45, /*pos*/ 3485, 1336, 6665), - MACRO_OBJECT(/*preset*/ macro_hidden_box, /*yaw*/ 45, /*pos*/ 2671, 1336, 6459), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 4900, 1800, 4700), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -2535, 2110, 6113), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -1845, -1003, 3518), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -546, 530, 5930), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 648, -490, 4256), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 3642, -5103, 3175), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 4400, 2200, 1300), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 5400, 2200, 1300), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 180, /*pos*/ -900, -2966, -2200, /*behParam*/ DIALOG_073), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 80, /*pos*/ -2552, 1331, 6573, /*behParam*/ DIALOG_051), - MACRO_OBJECT(/*preset*/ macro_clam_shell, /*yaw*/ 315, /*pos*/ -1800, -1023, 3500), - MACRO_OBJECT(/*preset*/ macro_clam_shell, /*yaw*/ 225, /*pos*/ -480, 512, 5980), - MACRO_OBJECT(/*preset*/ macro_clam_shell, /*yaw*/ 270, /*pos*/ 700, -511, 4250), - MACRO_OBJECT(/*preset*/ macro_clam_shell, /*yaw*/ 90, /*pos*/ 3600, -5119, 3200), - MACRO_OBJECT(/*preset*/ macro_fish_group, /*yaw*/ 0, /*pos*/ -2523, -246, 4676), - MACRO_OBJECT(/*preset*/ macro_fish_group, /*yaw*/ 0, /*pos*/ 5876, -4738, 3476), - MACRO_OBJECT(/*preset*/ macro_blue_coin_switch, /*yaw*/ 0, /*pos*/ 6011, -2966, -5511), - MACRO_OBJECT(/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ 5900, -2966, -7347), - MACRO_OBJECT(/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ 5300, -2966, -7347), - MACRO_OBJECT(/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ 4700, -2966, -7347), - MACRO_OBJECT(/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ 4100, -2966, -7347), - MACRO_OBJECT(/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ 3500, -2966, -7347), - MACRO_OBJECT(/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ 2900, -2966, -7347), - MACRO_OBJECT(/*preset*/ macro_goomba_triplet_spawner, /*yaw*/ 0, /*pos*/ 3305, -2966, -6147), - MACRO_OBJECT(/*preset*/ macro_coin_line_vertical, /*yaw*/ 0, /*pos*/ 255, 1160, 7633), - MACRO_OBJECT(/*preset*/ macro_coin_ring_horizontal_flying, /*yaw*/ 0, /*pos*/ 51, 960, 2744), - MACRO_OBJECT(/*preset*/ macro_hidden_1up_trigger, /*yaw*/ 0, /*pos*/ 5060, -4220, 720), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_hidden_1up, /*yaw*/ 0, /*pos*/ 5140, -4380, 0, /*behParam*/ 1), - MACRO_OBJECT(/*preset*/ macro_fish_group_2, /*yaw*/ 0, /*pos*/ 4072, -4463, 2027), - MACRO_OBJECT(/*preset*/ macro_fish_group_2, /*yaw*/ 0, /*pos*/ -290, 190, 4645), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_cannon_closed, /*yaw*/ 0, /*pos*/ -4235, 1247, 2137, /*behParam*/ 0x00), - MACRO_OBJECT(/*preset*/ macro_hidden_box, /*yaw*/ 45, /*pos*/ 2536, 1336, 6594), - MACRO_OBJECT(/*preset*/ macro_coin_line_horizontal, /*yaw*/ 45, /*pos*/ 4220, 1536, 5700), - MACRO_OBJECT(/*preset*/ macro_hidden_box, /*yaw*/ 45, /*pos*/ 3987, 1336, 5148), - MACRO_OBJECT(/*preset*/ macro_coin_line_horizontal, /*yaw*/ 45, /*pos*/ 3280, 1536, 5940), - MACRO_OBJECT(/*preset*/ macro_coin_line_horizontal, /*yaw*/ 45, /*pos*/ 3200, 1536, 6720), - MACRO_OBJECT(/*preset*/ macro_box_metal_cap, /*yaw*/ 0, /*pos*/ -7160, 1340, 2580), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 180, /*pos*/ -6910, 1120, 2380, /*behParam*/ DIALOG_113), - MACRO_OBJECT(/*preset*/ macro_box_three_coins, /*yaw*/ 0, /*pos*/ -5800, 1340, -750), - MACRO_OBJECT(/*preset*/ macro_1up, /*yaw*/ 0, /*pos*/ 670, 3000, 3315), - MACRO_OBJECT(/*preset*/ macro_koopa_shell_underwater, /*yaw*/ 0, /*pos*/ -1480, -1000, 4820), - MACRO_OBJECT(/*preset*/ macro_clam_shell, /*yaw*/ 180, /*pos*/ -1480, -1040, 4820), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 0, /*pos*/ 5290, -2966, -4740, /*behParam*/ DIALOG_169), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 250, /*pos*/ -6325, 1126, 1730, /*bhvParam*/ DIALOG_060), + MACRO_OBJECT (/*preset*/ macro_coin_ring_vertical_flying, /*yaw*/ 0, /*pos*/ 5060, -4420, 720), + MACRO_OBJECT (/*preset*/ macro_box_metal_cap, /*yaw*/ 0, /*pos*/ 2077, 1832, 7465), + MACRO_OBJECT (/*preset*/ macro_coin_ring_horizontal_flying, /*yaw*/ 0, /*pos*/ -1780, -650, 4200), + MACRO_OBJECT (/*preset*/ macro_floor_switch_hidden_objects, /*yaw*/ 45, /*pos*/ 2260, 1536, 6854), + MACRO_OBJECT (/*preset*/ macro_hidden_breakable_box, /*yaw*/ 45, /*pos*/ 4269, 1336, 4866), + MACRO_OBJECT (/*preset*/ macro_hidden_breakable_box, /*yaw*/ 45, /*pos*/ 4128, 1336, 5007), + MACRO_OBJECT (/*preset*/ macro_hidden_breakable_box, /*yaw*/ 45, /*pos*/ 3400, 1336, 5155), + MACRO_OBJECT (/*preset*/ macro_hidden_breakable_box, /*yaw*/ 45, /*pos*/ 3261, 1336, 5294), + MACRO_OBJECT (/*preset*/ macro_hidden_breakable_box, /*yaw*/ 45, /*pos*/ 3120, 1336, 5435), + MACRO_OBJECT (/*preset*/ macro_seaweed_bundle, /*yaw*/ 0, /*pos*/ 3551, -5120, 2744), + MACRO_OBJECT (/*preset*/ macro_seaweed_bundle, /*yaw*/ 0, /*pos*/ 4201, -5120, 3863), + MACRO_OBJECT (/*preset*/ macro_coin_ring_horizontal, /*yaw*/ 0, /*pos*/ -2440, -2980, -4120), + MACRO_OBJECT (/*preset*/ macro_box_metal_cap, /*yaw*/ 0, /*pos*/ 279, -2600, -7340), + MACRO_OBJECT (/*preset*/ macro_seaweed_bundle, /*yaw*/ 0, /*pos*/ 4846, -5119, 1213), + MACRO_OBJECT (/*preset*/ macro_seaweed_bundle, /*yaw*/ 0, /*pos*/ -800, -1023, 4040), + MACRO_OBJECT (/*preset*/ macro_hidden_breakable_box, /*yaw*/ 45, /*pos*/ 3621, 1336, 6529), + MACRO_OBJECT (/*preset*/ macro_hidden_breakable_box, /*yaw*/ 45, /*pos*/ 3485, 1336, 6665), + MACRO_OBJECT (/*preset*/ macro_hidden_breakable_box, /*yaw*/ 45, /*pos*/ 2671, 1336, 6459), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 4900, 1800, 4700), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -2535, 2110, 6113), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -1845, -1003, 3518), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -546, 530, 5930), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 648, -490, 4256), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 3642, -5103, 3175), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 4400, 2200, 1300), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 5400, 2200, 1300), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 180, /*pos*/ -900, -2966, -2200, /*bhvParam*/ DIALOG_073), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 80, /*pos*/ -2552, 1331, 6573, /*bhvParam*/ DIALOG_051), + MACRO_OBJECT (/*preset*/ macro_clam_shell, /*yaw*/ 315, /*pos*/ -1800, -1023, 3500), + MACRO_OBJECT (/*preset*/ macro_clam_shell, /*yaw*/ 225, /*pos*/ -480, 512, 5980), + MACRO_OBJECT (/*preset*/ macro_clam_shell, /*yaw*/ 270, /*pos*/ 700, -511, 4250), + MACRO_OBJECT (/*preset*/ macro_clam_shell, /*yaw*/ 90, /*pos*/ 3600, -5119, 3200), + MACRO_OBJECT (/*preset*/ macro_fish_spawner_few_blue, /*yaw*/ 0, /*pos*/ -2523, -246, 4676), + MACRO_OBJECT (/*preset*/ macro_fish_spawner_few_blue, /*yaw*/ 0, /*pos*/ 5876, -4738, 3476), + MACRO_OBJECT (/*preset*/ macro_blue_coin_switch, /*yaw*/ 0, /*pos*/ 6011, -2966, -5511), + MACRO_OBJECT (/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ 5900, -2966, -7347), + MACRO_OBJECT (/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ 5300, -2966, -7347), + MACRO_OBJECT (/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ 4700, -2966, -7347), + MACRO_OBJECT (/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ 4100, -2966, -7347), + MACRO_OBJECT (/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ 3500, -2966, -7347), + MACRO_OBJECT (/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ 2900, -2966, -7347), + MACRO_OBJECT (/*preset*/ macro_goomba_triplet_spawner, /*yaw*/ 0, /*pos*/ 3305, -2966, -6147), + MACRO_OBJECT (/*preset*/ macro_coin_line_vertical_flying, /*yaw*/ 0, /*pos*/ 255, 1160, 7633), + MACRO_OBJECT (/*preset*/ macro_coin_ring_horizontal_flying, /*yaw*/ 0, /*pos*/ 51, 960, 2744), + MACRO_OBJECT (/*preset*/ macro_hidden_1up_trigger, /*yaw*/ 0, /*pos*/ 5060, -4220, 720), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_hidden_1up, /*yaw*/ 0, /*pos*/ 5140, -4380, 0, /*bhvParam*/ 1), + MACRO_OBJECT (/*preset*/ macro_fish_spawner_few_cyan, /*yaw*/ 0, /*pos*/ 4072, -4463, 2027), + MACRO_OBJECT (/*preset*/ macro_fish_spawner_few_cyan, /*yaw*/ 0, /*pos*/ -290, 190, 4645), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_cannon_closed, /*yaw*/ 0, /*pos*/ -4235, 1247, 2137, /*bhvParam*/ 0x00), + MACRO_OBJECT (/*preset*/ macro_hidden_breakable_box, /*yaw*/ 45, /*pos*/ 2536, 1336, 6594), + MACRO_OBJECT (/*preset*/ macro_coin_line_horizontal, /*yaw*/ 45, /*pos*/ 4220, 1536, 5700), + MACRO_OBJECT (/*preset*/ macro_hidden_breakable_box, /*yaw*/ 45, /*pos*/ 3987, 1336, 5148), + MACRO_OBJECT (/*preset*/ macro_coin_line_horizontal, /*yaw*/ 45, /*pos*/ 3280, 1536, 5940), + MACRO_OBJECT (/*preset*/ macro_coin_line_horizontal, /*yaw*/ 45, /*pos*/ 3200, 1536, 6720), + MACRO_OBJECT (/*preset*/ macro_box_metal_cap, /*yaw*/ 0, /*pos*/ -7160, 1340, 2580), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 180, /*pos*/ -6910, 1120, 2380, /*bhvParam*/ DIALOG_113), + MACRO_OBJECT (/*preset*/ macro_box_three_coins, /*yaw*/ 0, /*pos*/ -5800, 1340, -750), + MACRO_OBJECT (/*preset*/ macro_1up, /*yaw*/ 0, /*pos*/ 670, 3000, 3315), + MACRO_OBJECT (/*preset*/ macro_koopa_shell_underwater, /*yaw*/ 0, /*pos*/ -1480, -1000, 4820), + MACRO_OBJECT (/*preset*/ macro_clam_shell, /*yaw*/ 180, /*pos*/ -1480, -1040, 4820), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 0, /*pos*/ 5290, -2966, -4740, /*bhvParam*/ DIALOG_169), MACRO_OBJECT_END(), }; diff --git a/levels/jrb/areas/2/geo.inc.c b/levels/jrb/areas/2/geo.inc.c index c9a15fb9..5a01901b 100644 --- a/levels/jrb/areas/2/geo.inc.c +++ b/levels/jrb/areas/2/geo.inc.c @@ -1,30 +1,30 @@ // 0x0E000AFC const GeoLayout jrb_geo_000AFC[] = { - GEO_NODE_SCREEN_AREA(10, SCREEN_WIDTH/2, SCREEN_HEIGHT/2, SCREEN_WIDTH/2, SCREEN_HEIGHT/2), - GEO_OPEN_NODE(), - GEO_ZBUFFER(0), - GEO_OPEN_NODE(), - GEO_NODE_ORTHO(100), - GEO_OPEN_NODE(), - GEO_BACKGROUND_COLOR(0x0001), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ZBUFFER(1), - GEO_OPEN_NODE(), - GEO_CAMERA_FRUSTUM_WITH_FUNC(45, 100, 10000, geo_camera_fov), - GEO_OPEN_NODE(), - GEO_CAMERA(16, 0, 2000, 6000, 0, 0, 0, geo_camera_main), + GEO_NODE_SCREEN_AREA(10, SCREEN_WIDTH/2, SCREEN_HEIGHT/2, SCREEN_WIDTH/2, SCREEN_HEIGHT/2), + GEO_OPEN_NODE(), + GEO_ZBUFFER(0), + GEO_OPEN_NODE(), + GEO_NODE_ORTHO(100), GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, jrb_seg7_dl_0700EF00), - GEO_DISPLAY_LIST(LAYER_ALPHA, jrb_seg7_dl_0700FE48), - GEO_DISPLAY_LIST(LAYER_OPAQUE, jrb_seg7_dl_07010548), - GEO_ASM( 0, geo_movtex_pause_control), - GEO_ASM(0x1202, geo_movtex_draw_water_regions), - GEO_RENDER_OBJ(), - GEO_ASM( 2, geo_envfx_main), + GEO_BACKGROUND_COLOR(0x0001), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CLOSE_NODE(), + GEO_ZBUFFER(1), + GEO_OPEN_NODE(), + GEO_CAMERA_FRUSTUM_WITH_FUNC(45, 100, 10000, geo_camera_fov), + GEO_OPEN_NODE(), + GEO_CAMERA(16, 0, 2000, 6000, 0, 0, 0, geo_camera_main), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, jrb_seg7_dl_0700EF00), + GEO_DISPLAY_LIST(LAYER_ALPHA, jrb_seg7_dl_0700FE48), + GEO_DISPLAY_LIST(LAYER_OPAQUE, jrb_seg7_dl_07010548), + GEO_ASM( 0, geo_movtex_pause_control), + GEO_ASM(0x1202, geo_movtex_draw_water_regions), + GEO_RENDER_OBJ(), + GEO_ASM( 2, geo_envfx_main), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/jrb/areas/2/macro.inc.c b/levels/jrb/areas/2/macro.inc.c index 54c9469e..b97ac5a6 100644 --- a/levels/jrb/areas/2/macro.inc.c +++ b/levels/jrb/areas/2/macro.inc.c @@ -1,5 +1,5 @@ // 0x07011370 - 0x0701137C const MacroObject jrb_seg7_area_2_macro_objs[] = { - MACRO_OBJECT(/*preset*/ macro_box_star_1, /*yaw*/ 0, /*pos*/ 0, 1600, 3000), + MACRO_OBJECT(/*preset*/ macro_box_star_act_1, /*yaw*/ 0, /*pos*/ 0, 1600, 3000), MACRO_OBJECT_END(), }; diff --git a/levels/jrb/falling_pillar/geo.inc.c b/levels/jrb/falling_pillar/geo.inc.c index c3cf3b40..c5a0c67e 100644 --- a/levels/jrb/falling_pillar/geo.inc.c +++ b/levels/jrb/falling_pillar/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000900 const GeoLayout jrb_geo_000900[] = { - GEO_CULLING_RADIUS(1600), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, jrb_seg7_dl_0700AE48), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(1600), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, jrb_seg7_dl_0700AE48), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/jrb/falling_pillar_base/geo.inc.c b/levels/jrb/falling_pillar_base/geo.inc.c index e8d430ba..637556f7 100644 --- a/levels/jrb/falling_pillar_base/geo.inc.c +++ b/levels/jrb/falling_pillar_base/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000918 const GeoLayout jrb_geo_000918[] = { - GEO_CULLING_RADIUS(300), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, jrb_seg7_dl_0700AFB0), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(300), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, jrb_seg7_dl_0700AFB0), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/jrb/floating_platform/geo.inc.c b/levels/jrb/floating_platform/geo.inc.c index e297895e..2d42c7bf 100644 --- a/levels/jrb/floating_platform/geo.inc.c +++ b/levels/jrb/floating_platform/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000948 const GeoLayout jrb_geo_000948[] = { - GEO_CULLING_RADIUS(900), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, jrb_seg7_dl_07007DC8), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(900), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, jrb_seg7_dl_07007DC8), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/jrb/leveldata.c b/levels/jrb/leveldata.c index 12cc6b72..1b70f0ac 100644 --- a/levels/jrb/leveldata.c +++ b/levels/jrb/leveldata.c @@ -3,8 +3,8 @@ #include "surface_terrains.h" #include "moving_texture_macros.h" #include "level_misc_macros.h" -#include "macro_preset_names.h" -#include "special_preset_names.h" +#include "macro_presets.h" +#include "special_presets.h" #include "textures.h" #include "dialog_ids.h" diff --git a/levels/jrb/rock/geo.inc.c b/levels/jrb/rock/geo.inc.c index c406320d..1a500ba6 100644 --- a/levels/jrb/rock/geo.inc.c +++ b/levels/jrb/rock/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000930 const GeoLayout jrb_geo_000930[] = { - GEO_CULLING_RADIUS(1100), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, jrb_seg7_dl_07007AC8), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(1100), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, jrb_seg7_dl_07007AC8), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/jrb/script.c b/levels/jrb/script.c index 75402867..c7769fe9 100644 --- a/levels/jrb/script.c +++ b/levels/jrb/script.c @@ -16,95 +16,95 @@ #include "levels/jrb/header.h" static const LevelScript script_func_local_1[] = { - OBJECT_WITH_ACTS(/*model*/ MODEL_JRB_SUNKEN_SHIP, /*pos*/ 2385, 3589, 3727, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvSunkenShipPart, /*acts*/ ACT_1), - OBJECT_WITH_ACTS(/*model*/ MODEL_JRB_SUNKEN_SHIP_BACK, /*pos*/ 2385, 3589, 3727, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvSunkenShipPart, /*acts*/ ACT_1), - OBJECT_WITH_ACTS(/*model*/ MODEL_JRB_SHIP_LEFT_HALF_PART, /*pos*/ 5385, -5520, 2428, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvSunkenShipPart2, /*acts*/ ACT_1), - OBJECT_WITH_ACTS(/*model*/ MODEL_JRB_SHIP_RIGHT_HALF_PART, /*pos*/ 5385, -5520, 2428, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvSunkenShipPart2, /*acts*/ ACT_1), - OBJECT_WITH_ACTS(/*model*/ MODEL_NONE, /*pos*/ 5385, -5520, 2428, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvInSunkenShip, /*acts*/ ACT_1), - OBJECT_WITH_ACTS(/*model*/ MODEL_NONE, /*pos*/ 5385, -5520, 2428, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvInSunkenShip2, /*acts*/ ACT_1), - OBJECT_WITH_ACTS(/*model*/ MODEL_JRB_SHIP_LEFT_HALF_PART, /*pos*/ 4880, 820, 2375, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvShipPart3, /*acts*/ ACT_2 | ACT_3 | ACT_4 | ACT_5 | ACT_6), - OBJECT_WITH_ACTS(/*model*/ MODEL_JRB_SHIP_BACK_LEFT_PART, /*pos*/ 4880, 820, 2375, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvShipPart3, /*acts*/ ACT_2 | ACT_3 | ACT_4 | ACT_5 | ACT_6), - OBJECT_WITH_ACTS(/*model*/ MODEL_JRB_SHIP_RIGHT_HALF_PART, /*pos*/ 4880, 820, 2375, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvShipPart3, /*acts*/ ACT_2 | ACT_3 | ACT_4 | ACT_5 | ACT_6), - OBJECT_WITH_ACTS(/*model*/ MODEL_JRB_SHIP_BACK_RIGHT_PART, /*pos*/ 4880, 820, 2375, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvShipPart3, /*acts*/ ACT_2 | ACT_3 | ACT_4 | ACT_5 | ACT_6), - OBJECT_WITH_ACTS(/*model*/ MODEL_NONE, /*pos*/ 4880, 820, 2375, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvInSunkenShip3, /*acts*/ ACT_2 | ACT_3 | ACT_4 | ACT_5 | ACT_6), - OBJECT_WITH_ACTS(/*model*/ MODEL_JRB_SLIDING_BOX, /*pos*/ 4668, 1434, 2916, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvJrbSlidingBox, /*acts*/ ACT_2 | ACT_3 | ACT_4 | ACT_5 | ACT_6), - OBJECT_WITH_ACTS(/*model*/ MODEL_UNAGI, /*pos*/ 6048, -5381, 1154, /*angle*/ 0, 340, 0, /*behParam*/ 0x00000000, /*beh*/ bhvUnagi, /*acts*/ ACT_1), - OBJECT_WITH_ACTS(/*model*/ MODEL_UNAGI, /*pos*/ 8270, -3130, 1846, /*angle*/ 0, 285, 0, /*behParam*/ 0x01010000, /*beh*/ bhvUnagi, /*acts*/ ACT_2), - OBJECT_WITH_ACTS(/*model*/ MODEL_UNAGI, /*pos*/ 6048, -5381, 1154, /*angle*/ 0, 340, 0, /*behParam*/ 0x02020000, /*beh*/ bhvUnagi, /*acts*/ ACT_3 | ACT_4 | ACT_5 | ACT_6), - OBJECT_WITH_ACTS(/*model*/ MODEL_NONE, /*pos*/ 4988, -5221, 2473, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvJetStream, /*acts*/ ACT_2 | ACT_3 | ACT_4 | ACT_5 | ACT_6), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -1800, -2812, -2100, /*angle*/ 0, 0, 0, /*behParam*/ 0x02000000, /*beh*/ bhvTreasureChestsJrb), - OBJECT_WITH_ACTS(/*model*/ MODEL_BOBOMB_BUDDY, /*pos*/ -1956, 1331, 6500, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvBobombBuddyOpensCannon, /*acts*/ ACT_2 | ACT_3 | ACT_4 | ACT_5 | ACT_6), + OBJECT_WITH_ACTS(/*model*/ MODEL_JRB_SUNKEN_SHIP, /*pos*/ 2385, 3589, 3727, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvSunkenShipPart, /*acts*/ ACT_1), + OBJECT_WITH_ACTS(/*model*/ MODEL_JRB_SUNKEN_SHIP_BACK, /*pos*/ 2385, 3589, 3727, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvSunkenShipPart, /*acts*/ ACT_1), + OBJECT_WITH_ACTS(/*model*/ MODEL_JRB_SHIP_LEFT_HALF_PART, /*pos*/ 5385, -5520, 2428, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvSunkenShipPart2, /*acts*/ ACT_1), + OBJECT_WITH_ACTS(/*model*/ MODEL_JRB_SHIP_RIGHT_HALF_PART, /*pos*/ 5385, -5520, 2428, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvSunkenShipPart2, /*acts*/ ACT_1), + OBJECT_WITH_ACTS(/*model*/ MODEL_NONE, /*pos*/ 5385, -5520, 2428, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvInSunkenShip, /*acts*/ ACT_1), + OBJECT_WITH_ACTS(/*model*/ MODEL_NONE, /*pos*/ 5385, -5520, 2428, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvInSunkenShip2, /*acts*/ ACT_1), + OBJECT_WITH_ACTS(/*model*/ MODEL_JRB_SHIP_LEFT_HALF_PART, /*pos*/ 4880, 820, 2375, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvShipPart3, /*acts*/ ACT_2 | ACT_3 | ACT_4 | ACT_5 | ACT_6), + OBJECT_WITH_ACTS(/*model*/ MODEL_JRB_SHIP_BACK_LEFT_PART, /*pos*/ 4880, 820, 2375, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvShipPart3, /*acts*/ ACT_2 | ACT_3 | ACT_4 | ACT_5 | ACT_6), + OBJECT_WITH_ACTS(/*model*/ MODEL_JRB_SHIP_RIGHT_HALF_PART, /*pos*/ 4880, 820, 2375, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvShipPart3, /*acts*/ ACT_2 | ACT_3 | ACT_4 | ACT_5 | ACT_6), + OBJECT_WITH_ACTS(/*model*/ MODEL_JRB_SHIP_BACK_RIGHT_PART, /*pos*/ 4880, 820, 2375, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvShipPart3, /*acts*/ ACT_2 | ACT_3 | ACT_4 | ACT_5 | ACT_6), + OBJECT_WITH_ACTS(/*model*/ MODEL_NONE, /*pos*/ 4880, 820, 2375, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvInSunkenShip3, /*acts*/ ACT_2 | ACT_3 | ACT_4 | ACT_5 | ACT_6), + OBJECT_WITH_ACTS(/*model*/ MODEL_JRB_SLIDING_BOX, /*pos*/ 4668, 1434, 2916, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvJRBSlidingBox, /*acts*/ ACT_2 | ACT_3 | ACT_4 | ACT_5 | ACT_6), + OBJECT_WITH_ACTS(/*model*/ MODEL_UNAGI, /*pos*/ 6048, -5381, 1154, /*angle*/ 0, 340, 0, /*bhvParam*/ 0, /*bhv*/ bhvUnagi, /*acts*/ ACT_1), + OBJECT_WITH_ACTS(/*model*/ MODEL_UNAGI, /*pos*/ 8270, -3130, 1846, /*angle*/ 0, 285, 0, /*bhvParam*/ BPARAM1(STAR_INDEX_ACT_2) | BPARAM2(0x01), /*bhv*/ bhvUnagi, /*acts*/ ACT_2), + OBJECT_WITH_ACTS(/*model*/ MODEL_UNAGI, /*pos*/ 6048, -5381, 1154, /*angle*/ 0, 340, 0, /*bhvParam*/ BPARAM1(0x02) | BPARAM2(0x02), /*bhv*/ bhvUnagi, /*acts*/ ACT_3 | ACT_4 | ACT_5 | ACT_6), + OBJECT_WITH_ACTS(/*model*/ MODEL_NONE, /*pos*/ 4988, -5221, 2473, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvJetStream, /*acts*/ ACT_2 | ACT_3 | ACT_4 | ACT_5 | ACT_6), + OBJECT (/*model*/ MODEL_NONE, /*pos*/ -1800, -2812, -2100, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(STAR_INDEX_ACT_3), /*bhv*/ bhvTreasureChestsJRB), + OBJECT_WITH_ACTS(/*model*/ MODEL_BOBOMB_BUDDY, /*pos*/ -1956, 1331, 6500, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvBobombBuddyOpensCannon, /*acts*/ ACT_2 | ACT_3 | ACT_4 | ACT_5 | ACT_6), RETURN(), }; static const LevelScript script_func_local_2[] = { - OBJECT(/*model*/ MODEL_JRB_ROCK, /*pos*/ 1834, -2556, -7090, /*angle*/ 0, 194, 0, /*behParam*/ 0x00000000, /*beh*/ bhvRockSolid), - OBJECT(/*model*/ MODEL_JRB_ROCK, /*pos*/ -2005, -2556, -3506, /*angle*/ 0, 135, 0, /*behParam*/ 0x00000000, /*beh*/ bhvRockSolid), - OBJECT(/*model*/ MODEL_JRB_ROCK, /*pos*/ 1578, -2556, -5554, /*angle*/ 0, 90, 0, /*behParam*/ 0x00000000, /*beh*/ bhvRockSolid), - OBJECT(/*model*/ MODEL_JRB_ROCK, /*pos*/ 42, -2556, -6578, /*angle*/ 0, 135, 0, /*behParam*/ 0x00000000, /*beh*/ bhvRockSolid), - OBJECT(/*model*/ MODEL_JRB_ROCK, /*pos*/ -981, -2556, -5298, /*angle*/ 0, 255, 0, /*behParam*/ 0x00000000, /*beh*/ bhvRockSolid), - OBJECT(/*model*/ MODEL_JRB_ROCK, /*pos*/ -6549, 1536, 4343, /*angle*/ 0, 90, 0, /*behParam*/ 0x00000000, /*beh*/ bhvRockSolid), - OBJECT(/*model*/ MODEL_JRB_ROCK, /*pos*/ 1322, -2556, -3506, /*angle*/ 0, 165, 0, /*behParam*/ 0x00000000, /*beh*/ bhvRockSolid), - OBJECT(/*model*/ MODEL_JRB_ROCK, /*pos*/ 6442, -2556, -6322, /*angle*/ 0, 135, 0, /*behParam*/ 0x00000000, /*beh*/ bhvRockSolid), - OBJECT(/*model*/ MODEL_JRB_ROCK, /*pos*/ 3882, -2556, -5042, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvRockSolid), - OBJECT(/*model*/ MODEL_JRB_ROCK, /*pos*/ 1497, 1741, 7810, /*angle*/ 0, 14, 0, /*behParam*/ 0x00000000, /*beh*/ bhvRockSolid), - OBJECT(/*model*/ MODEL_JRB_ROCK, /*pos*/ -3978, 1536, -85, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvRockSolid), - OBJECT(/*model*/ MODEL_JRB_ROCK, /*pos*/ -5228, 1230, 2106, /*angle*/ 0, 323, 0, /*behParam*/ 0x00000000, /*beh*/ bhvRockSolid), - OBJECT(/*model*/ MODEL_JRB_ROCK, /*pos*/ -7481, 1536, 185, /*angle*/ 0, 149, 0, /*behParam*/ 0x00000000, /*beh*/ bhvRockSolid), - OBJECT(/*model*/ MODEL_JRB_ROCK, /*pos*/ -5749, 1536, -1113, /*angle*/ 0, 255, 0, /*behParam*/ 0x00000000, /*beh*/ bhvRockSolid), - OBJECT(/*model*/ MODEL_JRB_ROCK, /*pos*/ -5332, 1434, 1023, /*angle*/ 0, 315, 0, /*behParam*/ 0x00000000, /*beh*/ bhvRockSolid), - OBJECT(/*model*/ MODEL_JRB_ROCK, /*pos*/ -815, -613, 3556, /*angle*/ 0, 315, 0, /*behParam*/ 0x00000000, /*beh*/ bhvRockSolid), - OBJECT(/*model*/ MODEL_JRB_ROCK, /*pos*/ -3429, 819, 4948, /*angle*/ 0, 284, 0, /*behParam*/ 0x00000000, /*beh*/ bhvRockSolid), - OBJECT(/*model*/ MODEL_JRB_ROCK, /*pos*/ -1940, 410, 2377, /*angle*/ 0, 194, 0, /*behParam*/ 0x00000000, /*beh*/ bhvRockSolid), - OBJECT(/*model*/ MODEL_JRB_ROCK, /*pos*/ -1798, -716, 4330, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvRockSolid), - OBJECT(/*model*/ MODEL_JRB_ROCK, /*pos*/ -845, 922, 7668, /*angle*/ 0, 315, 0, /*behParam*/ 0x00000000, /*beh*/ bhvRockSolid), - OBJECT(/*model*/ MODEL_JRB_ROCK, /*pos*/ 6741, -2886, 3556, /*angle*/ 0, 135, 0, /*behParam*/ 0x00000000, /*beh*/ bhvRockSolid), - OBJECT(/*model*/ MODEL_JRB_ROCK, /*pos*/ 255, -101, 4719, /*angle*/ 0, 45, 0, /*behParam*/ 0x00000000, /*beh*/ bhvRockSolid), - OBJECT(/*model*/ MODEL_JRB_ROCK, /*pos*/ 1787, -306, 5133, /*angle*/ 0, 315, 0, /*behParam*/ 0x00000000, /*beh*/ bhvRockSolid), - OBJECT(/*model*/ MODEL_JRB_ROCK, /*pos*/ 1079, -613, 2299, /*angle*/ 0, 75, 0, /*behParam*/ 0x00000000, /*beh*/ bhvRockSolid), - OBJECT(/*model*/ MODEL_JRB_ROCK, /*pos*/ 2931, -1697, 980, /*angle*/ 0, 315, 0, /*behParam*/ 0x00000000, /*beh*/ bhvRockSolid), - OBJECT(/*model*/ MODEL_JRB_ROCK, /*pos*/ 3036, -4709, 4027, /*angle*/ 0, 315, 0, /*behParam*/ 0x00000000, /*beh*/ bhvRockSolid), - OBJECT(/*model*/ MODEL_JRB_ROCK, /*pos*/ 4222, -1125, 7083, /*angle*/ 0, 104, 0, /*behParam*/ 0x00000000, /*beh*/ bhvRockSolid), - OBJECT(/*model*/ MODEL_JRB_ROCK, /*pos*/ 6650, -613, 4941, /*angle*/ 0, 315, 0, /*behParam*/ 0x00000000, /*beh*/ bhvRockSolid), - OBJECT(/*model*/ MODEL_JRB_ROCK, /*pos*/ 5764, -4709, 4427, /*angle*/ 0, 315, 0, /*behParam*/ 0x00000000, /*beh*/ bhvRockSolid), - OBJECT(/*model*/ MODEL_JRB_ROCK, /*pos*/ 3693, -4709, 856, /*angle*/ 0, 135, 0, /*behParam*/ 0x00000000, /*beh*/ bhvRockSolid), - OBJECT(/*model*/ MODEL_JRB_ROCK, /*pos*/ 7981, 410, 2704, /*angle*/ 0, 165, 0, /*behParam*/ 0x00000000, /*beh*/ bhvRockSolid), - OBJECT(/*model*/ MODEL_JRB_ROCK, /*pos*/ 2917, -3046, 4818, /*angle*/ 0, 241, 0, /*behParam*/ 0x00000000, /*beh*/ bhvRockSolid), - OBJECT(/*model*/ MODEL_JRB_ROCK, /*pos*/ 5896, -393, -123, /*angle*/ 0, 315, 0, /*behParam*/ 0x00000000, /*beh*/ bhvRockSolid), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 53, 2355, 2724, /*angle*/ 0, 0, 0, /*behParam*/ 0x00290000, /*beh*/ bhvPoleGrabbing), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 659, 2560, 3314, /*angle*/ 0, 0, 0, /*behParam*/ 0x00290000, /*beh*/ bhvPoleGrabbing), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 1087, 2150, 3798, /*angle*/ 0, 0, 0, /*behParam*/ 0x00290000, /*beh*/ bhvPoleGrabbing), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -2535, 1075, 6113, /*angle*/ 0, 0, 0, /*behParam*/ 0x00610000, /*beh*/ bhvPoleGrabbing), - OBJECT(/*model*/ MODEL_JRB_FALLING_PILLAR, /*pos*/ 2078, -2863, -4696, /*angle*/ 0, 90, 0, /*behParam*/ 0x00000000, /*beh*/ bhvFallingPillar), - OBJECT(/*model*/ MODEL_JRB_FALLING_PILLAR, /*pos*/ -1403, -2863, -4696, /*angle*/ 0, 90, 0, /*behParam*/ 0x00000000, /*beh*/ bhvFallingPillar), - OBJECT(/*model*/ MODEL_JRB_FALLING_PILLAR, /*pos*/ -1096, -2863, -3262, /*angle*/ 0, 90, 0, /*behParam*/ 0x00000000, /*beh*/ bhvFallingPillar), - OBJECT(/*model*/ MODEL_JRB_FALLING_PILLAR, /*pos*/ 337, -2863, -5106, /*angle*/ 0, 90, 0, /*behParam*/ 0x00000000, /*beh*/ bhvFallingPillar), - OBJECT(/*model*/ MODEL_JRB_FALLING_PILLAR, /*pos*/ 2078, -2863, -6232, /*angle*/ 0, 90, 0, /*behParam*/ 0x00000000, /*beh*/ bhvFallingPillar), - OBJECT(/*model*/ MODEL_JRB_FALLING_PILLAR, /*pos*/ 4330, -2863, -5618, /*angle*/ 0, 90, 0, /*behParam*/ 0x00000000, /*beh*/ bhvFallingPillar), - OBJECT(/*model*/ MODEL_JRB_FALLING_PILLAR_BASE, /*pos*/ 2078, -2966, -4696, /*angle*/ 0, 90, 0, /*behParam*/ 0x00000000, /*beh*/ bhvPillarBase), - OBJECT(/*model*/ MODEL_JRB_FALLING_PILLAR_BASE, /*pos*/ -1403, -2966, -4696, /*angle*/ 0, 90, 0, /*behParam*/ 0x00000000, /*beh*/ bhvPillarBase), - OBJECT(/*model*/ MODEL_JRB_FALLING_PILLAR_BASE, /*pos*/ -1096, -2966, -3262, /*angle*/ 0, 90, 0, /*behParam*/ 0x00000000, /*beh*/ bhvPillarBase), - OBJECT(/*model*/ MODEL_JRB_FALLING_PILLAR_BASE, /*pos*/ 337, -2966, -5106, /*angle*/ 0, 90, 0, /*behParam*/ 0x00000000, /*beh*/ bhvPillarBase), - OBJECT(/*model*/ MODEL_JRB_FALLING_PILLAR_BASE, /*pos*/ 2078, -2966, -6232, /*angle*/ 0, 90, 0, /*behParam*/ 0x00000000, /*beh*/ bhvPillarBase), - OBJECT(/*model*/ MODEL_JRB_FALLING_PILLAR_BASE, /*pos*/ 4330, -2966, -5618, /*angle*/ 0, 90, 0, /*behParam*/ 0x00000000, /*beh*/ bhvPillarBase), - OBJECT(/*model*/ MODEL_JRB_FLOATING_PLATFORM, /*pos*/ -1059, 1025, 7072, /*angle*/ 0, 247, 0, /*behParam*/ 0x00000000, /*beh*/ bhvJrbFloatingPlatform), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -4236, 1044, 2136, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvInsideCannon), + OBJECT(/*model*/ MODEL_JRB_ROCK, /*pos*/ 1834, -2556, -7090, /*angle*/ 0, 194, 0, /*bhvParam*/ 0, /*bhv*/ bhvRockSolid), + OBJECT(/*model*/ MODEL_JRB_ROCK, /*pos*/ -2005, -2556, -3506, /*angle*/ 0, 135, 0, /*bhvParam*/ 0, /*bhv*/ bhvRockSolid), + OBJECT(/*model*/ MODEL_JRB_ROCK, /*pos*/ 1578, -2556, -5554, /*angle*/ 0, 90, 0, /*bhvParam*/ 0, /*bhv*/ bhvRockSolid), + OBJECT(/*model*/ MODEL_JRB_ROCK, /*pos*/ 42, -2556, -6578, /*angle*/ 0, 135, 0, /*bhvParam*/ 0, /*bhv*/ bhvRockSolid), + OBJECT(/*model*/ MODEL_JRB_ROCK, /*pos*/ -981, -2556, -5298, /*angle*/ 0, 255, 0, /*bhvParam*/ 0, /*bhv*/ bhvRockSolid), + OBJECT(/*model*/ MODEL_JRB_ROCK, /*pos*/ -6549, 1536, 4343, /*angle*/ 0, 90, 0, /*bhvParam*/ 0, /*bhv*/ bhvRockSolid), + OBJECT(/*model*/ MODEL_JRB_ROCK, /*pos*/ 1322, -2556, -3506, /*angle*/ 0, 165, 0, /*bhvParam*/ 0, /*bhv*/ bhvRockSolid), + OBJECT(/*model*/ MODEL_JRB_ROCK, /*pos*/ 6442, -2556, -6322, /*angle*/ 0, 135, 0, /*bhvParam*/ 0, /*bhv*/ bhvRockSolid), + OBJECT(/*model*/ MODEL_JRB_ROCK, /*pos*/ 3882, -2556, -5042, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvRockSolid), + OBJECT(/*model*/ MODEL_JRB_ROCK, /*pos*/ 1497, 1741, 7810, /*angle*/ 0, 14, 0, /*bhvParam*/ 0, /*bhv*/ bhvRockSolid), + OBJECT(/*model*/ MODEL_JRB_ROCK, /*pos*/ -3978, 1536, -85, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvRockSolid), + OBJECT(/*model*/ MODEL_JRB_ROCK, /*pos*/ -5228, 1230, 2106, /*angle*/ 0, 323, 0, /*bhvParam*/ 0, /*bhv*/ bhvRockSolid), + OBJECT(/*model*/ MODEL_JRB_ROCK, /*pos*/ -7481, 1536, 185, /*angle*/ 0, 149, 0, /*bhvParam*/ 0, /*bhv*/ bhvRockSolid), + OBJECT(/*model*/ MODEL_JRB_ROCK, /*pos*/ -5749, 1536, -1113, /*angle*/ 0, 255, 0, /*bhvParam*/ 0, /*bhv*/ bhvRockSolid), + OBJECT(/*model*/ MODEL_JRB_ROCK, /*pos*/ -5332, 1434, 1023, /*angle*/ 0, 315, 0, /*bhvParam*/ 0, /*bhv*/ bhvRockSolid), + OBJECT(/*model*/ MODEL_JRB_ROCK, /*pos*/ -815, -613, 3556, /*angle*/ 0, 315, 0, /*bhvParam*/ 0, /*bhv*/ bhvRockSolid), + OBJECT(/*model*/ MODEL_JRB_ROCK, /*pos*/ -3429, 819, 4948, /*angle*/ 0, 284, 0, /*bhvParam*/ 0, /*bhv*/ bhvRockSolid), + OBJECT(/*model*/ MODEL_JRB_ROCK, /*pos*/ -1940, 410, 2377, /*angle*/ 0, 194, 0, /*bhvParam*/ 0, /*bhv*/ bhvRockSolid), + OBJECT(/*model*/ MODEL_JRB_ROCK, /*pos*/ -1798, -716, 4330, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvRockSolid), + OBJECT(/*model*/ MODEL_JRB_ROCK, /*pos*/ -845, 922, 7668, /*angle*/ 0, 315, 0, /*bhvParam*/ 0, /*bhv*/ bhvRockSolid), + OBJECT(/*model*/ MODEL_JRB_ROCK, /*pos*/ 6741, -2886, 3556, /*angle*/ 0, 135, 0, /*bhvParam*/ 0, /*bhv*/ bhvRockSolid), + OBJECT(/*model*/ MODEL_JRB_ROCK, /*pos*/ 255, -101, 4719, /*angle*/ 0, 45, 0, /*bhvParam*/ 0, /*bhv*/ bhvRockSolid), + OBJECT(/*model*/ MODEL_JRB_ROCK, /*pos*/ 1787, -306, 5133, /*angle*/ 0, 315, 0, /*bhvParam*/ 0, /*bhv*/ bhvRockSolid), + OBJECT(/*model*/ MODEL_JRB_ROCK, /*pos*/ 1079, -613, 2299, /*angle*/ 0, 75, 0, /*bhvParam*/ 0, /*bhv*/ bhvRockSolid), + OBJECT(/*model*/ MODEL_JRB_ROCK, /*pos*/ 2931, -1697, 980, /*angle*/ 0, 315, 0, /*bhvParam*/ 0, /*bhv*/ bhvRockSolid), + OBJECT(/*model*/ MODEL_JRB_ROCK, /*pos*/ 3036, -4709, 4027, /*angle*/ 0, 315, 0, /*bhvParam*/ 0, /*bhv*/ bhvRockSolid), + OBJECT(/*model*/ MODEL_JRB_ROCK, /*pos*/ 4222, -1125, 7083, /*angle*/ 0, 104, 0, /*bhvParam*/ 0, /*bhv*/ bhvRockSolid), + OBJECT(/*model*/ MODEL_JRB_ROCK, /*pos*/ 6650, -613, 4941, /*angle*/ 0, 315, 0, /*bhvParam*/ 0, /*bhv*/ bhvRockSolid), + OBJECT(/*model*/ MODEL_JRB_ROCK, /*pos*/ 5764, -4709, 4427, /*angle*/ 0, 315, 0, /*bhvParam*/ 0, /*bhv*/ bhvRockSolid), + OBJECT(/*model*/ MODEL_JRB_ROCK, /*pos*/ 3693, -4709, 856, /*angle*/ 0, 135, 0, /*bhvParam*/ 0, /*bhv*/ bhvRockSolid), + OBJECT(/*model*/ MODEL_JRB_ROCK, /*pos*/ 7981, 410, 2704, /*angle*/ 0, 165, 0, /*bhvParam*/ 0, /*bhv*/ bhvRockSolid), + OBJECT(/*model*/ MODEL_JRB_ROCK, /*pos*/ 2917, -3046, 4818, /*angle*/ 0, 241, 0, /*bhvParam*/ 0, /*bhv*/ bhvRockSolid), + OBJECT(/*model*/ MODEL_JRB_ROCK, /*pos*/ 5896, -393, -123, /*angle*/ 0, 315, 0, /*bhvParam*/ 0, /*bhv*/ bhvRockSolid), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 53, 2355, 2724, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(41), /*bhv*/ bhvPoleGrabbing), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 659, 2560, 3314, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(41), /*bhv*/ bhvPoleGrabbing), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 1087, 2150, 3798, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(41), /*bhv*/ bhvPoleGrabbing), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ -2535, 1075, 6113, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(97), /*bhv*/ bhvPoleGrabbing), + OBJECT(/*model*/ MODEL_JRB_FALLING_PILLAR, /*pos*/ 2078, -2863, -4696, /*angle*/ 0, 90, 0, /*bhvParam*/ 0, /*bhv*/ bhvFallingPillar), + OBJECT(/*model*/ MODEL_JRB_FALLING_PILLAR, /*pos*/ -1403, -2863, -4696, /*angle*/ 0, 90, 0, /*bhvParam*/ 0, /*bhv*/ bhvFallingPillar), + OBJECT(/*model*/ MODEL_JRB_FALLING_PILLAR, /*pos*/ -1096, -2863, -3262, /*angle*/ 0, 90, 0, /*bhvParam*/ 0, /*bhv*/ bhvFallingPillar), + OBJECT(/*model*/ MODEL_JRB_FALLING_PILLAR, /*pos*/ 337, -2863, -5106, /*angle*/ 0, 90, 0, /*bhvParam*/ 0, /*bhv*/ bhvFallingPillar), + OBJECT(/*model*/ MODEL_JRB_FALLING_PILLAR, /*pos*/ 2078, -2863, -6232, /*angle*/ 0, 90, 0, /*bhvParam*/ 0, /*bhv*/ bhvFallingPillar), + OBJECT(/*model*/ MODEL_JRB_FALLING_PILLAR, /*pos*/ 4330, -2863, -5618, /*angle*/ 0, 90, 0, /*bhvParam*/ 0, /*bhv*/ bhvFallingPillar), + OBJECT(/*model*/ MODEL_JRB_FALLING_PILLAR_BASE, /*pos*/ 2078, -2966, -4696, /*angle*/ 0, 90, 0, /*bhvParam*/ 0, /*bhv*/ bhvPillarBase), + OBJECT(/*model*/ MODEL_JRB_FALLING_PILLAR_BASE, /*pos*/ -1403, -2966, -4696, /*angle*/ 0, 90, 0, /*bhvParam*/ 0, /*bhv*/ bhvPillarBase), + OBJECT(/*model*/ MODEL_JRB_FALLING_PILLAR_BASE, /*pos*/ -1096, -2966, -3262, /*angle*/ 0, 90, 0, /*bhvParam*/ 0, /*bhv*/ bhvPillarBase), + OBJECT(/*model*/ MODEL_JRB_FALLING_PILLAR_BASE, /*pos*/ 337, -2966, -5106, /*angle*/ 0, 90, 0, /*bhvParam*/ 0, /*bhv*/ bhvPillarBase), + OBJECT(/*model*/ MODEL_JRB_FALLING_PILLAR_BASE, /*pos*/ 2078, -2966, -6232, /*angle*/ 0, 90, 0, /*bhvParam*/ 0, /*bhv*/ bhvPillarBase), + OBJECT(/*model*/ MODEL_JRB_FALLING_PILLAR_BASE, /*pos*/ 4330, -2966, -5618, /*angle*/ 0, 90, 0, /*bhvParam*/ 0, /*bhv*/ bhvPillarBase), + OBJECT(/*model*/ MODEL_JRB_FLOATING_PLATFORM, /*pos*/ -1059, 1025, 7072, /*angle*/ 0, 247, 0, /*bhvParam*/ 0, /*bhv*/ bhvJRBFloatingPlatform), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ -4236, 1044, 2136, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvInsideCannon), RETURN(), }; static const LevelScript script_func_local_3[] = { - OBJECT_WITH_ACTS(/*model*/ MODEL_NONE, /*pos*/ 4900, 2400, 800, /*angle*/ 0, 0, 0, /*behParam*/ 0x03000000, /*beh*/ bhvHiddenRedCoinStar, /*acts*/ ALL_ACTS), + OBJECT_WITH_ACTS(/*model*/ MODEL_NONE, /*pos*/ 4900, 2400, 800, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(STAR_INDEX_ACT_4), /*bhv*/ bhvHiddenRedCoinStar, /*acts*/ ALL_ACTS), #if defined(VERSION_JP) || defined(VERSION_SH) - OBJECT_WITH_ACTS(/*model*/ MODEL_STAR, /*pos*/ 1540, 2160, 2130, /*angle*/ 0, 0, 0, /*behParam*/ 0x04000000, /*beh*/ bhvStar, /*acts*/ ALL_ACTS), + OBJECT_WITH_ACTS(/*model*/ MODEL_STAR, /*pos*/ 1540, 2160, 2130, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(STAR_INDEX_ACT_5), /*bhv*/ bhvStar, /*acts*/ ALL_ACTS), #else - OBJECT_WITH_ACTS(/*model*/ MODEL_EXCLAMATION_BOX, /*pos*/ 1540, 2160, 2130, /*angle*/ 0, 0, 0, /*behParam*/ 0x04080000, /*beh*/ bhvExclamationBox, /*acts*/ ALL_ACTS), + OBJECT_WITH_ACTS(/*model*/ MODEL_EXCLAMATION_BOX, /*pos*/ 1540, 2160, 2130, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(STAR_INDEX_ACT_5) | BPARAM2(EXCLAMATION_BOX_BP_STAR_ACT_1), /*bhv*/ bhvExclamationBox, /*acts*/ ALL_ACTS), #endif - OBJECT_WITH_ACTS(/*model*/ MODEL_STAR, /*pos*/ 5000, -4800, 2500, /*angle*/ 0, 0, 0, /*behParam*/ 0x05000000, /*beh*/ bhvStar, /*acts*/ ACT_2 | ACT_3 | ACT_4 | ACT_5 | ACT_6), + OBJECT_WITH_ACTS(/*model*/ MODEL_STAR, /*pos*/ 5000, -4800, 2500, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(STAR_INDEX_ACT_6), /*bhv*/ bhvStar, /*acts*/ ACT_2 | ACT_3 | ACT_4 | ACT_5 | ACT_6), RETURN(), }; static const LevelScript script_func_local_4[] = { - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 400, -350, -2700, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvTreasureChestsShip), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 400, -350, -2700, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvTreasureChestsShip), RETURN(), }; @@ -114,18 +114,18 @@ static const LevelScript script_func_local_5[] = { const LevelScript level_jrb_entry[] = { INIT_LEVEL(), - LOAD_MIO0( /*seg*/ 0x07, _jrb_segment_7SegmentRomStart, _jrb_segment_7SegmentRomEnd), - LOAD_MIO0( /*seg*/ 0x0B, _effect_mio0SegmentRomStart, _effect_mio0SegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x07, _jrb_segment_7SegmentRomStart, _jrb_segment_7SegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x0B, _effect_mio0SegmentRomStart, _effect_mio0SegmentRomEnd), LOAD_MIO0_TEXTURE(/*seg*/ 0x09, _water_mio0SegmentRomStart, _water_mio0SegmentRomEnd), - LOAD_MIO0( /*seg*/ 0x0A, _clouds_skybox_mio0SegmentRomStart, _clouds_skybox_mio0SegmentRomEnd), - LOAD_MIO0( /*seg*/ 0x05, _group4_mio0SegmentRomStart, _group4_mio0SegmentRomEnd), - LOAD_RAW( /*seg*/ 0x0C, _group4_geoSegmentRomStart, _group4_geoSegmentRomEnd), - LOAD_MIO0( /*seg*/ 0x06, _group13_mio0SegmentRomStart, _group13_mio0SegmentRomEnd), - LOAD_RAW( /*seg*/ 0x0D, _group13_geoSegmentRomStart, _group13_geoSegmentRomEnd), - LOAD_MIO0( /*seg*/ 0x08, _common0_mio0SegmentRomStart, _common0_mio0SegmentRomEnd), - LOAD_RAW( /*seg*/ 0x0F, _common0_geoSegmentRomStart, _common0_geoSegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x0A, _clouds_skybox_mio0SegmentRomStart, _clouds_skybox_mio0SegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x05, _group4_mio0SegmentRomStart, _group4_mio0SegmentRomEnd), + LOAD_RAW (/*seg*/ 0x0C, _group4_geoSegmentRomStart, _group4_geoSegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x06, _group13_mio0SegmentRomStart, _group13_mio0SegmentRomEnd), + LOAD_RAW (/*seg*/ 0x0D, _group13_geoSegmentRomStart, _group13_geoSegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x08, _common0_mio0SegmentRomStart, _common0_mio0SegmentRomEnd), + LOAD_RAW (/*seg*/ 0x0F, _common0_geoSegmentRomStart, _common0_geoSegmentRomEnd), ALLOC_LEVEL_POOL(), - MARIO(/*model*/ MODEL_MARIO, /*behParam*/ 0x00000001, /*beh*/ bhvMario), + MARIO(/*model*/ MODEL_MARIO, /*bhvParam*/ BPARAM4(0x01), /*bhv*/ bhvMario), JUMP_LINK(script_func_global_1), JUMP_LINK(script_func_global_5), JUMP_LINK(script_func_global_14), @@ -142,11 +142,11 @@ const LevelScript level_jrb_entry[] = { LOAD_MODEL_FROM_GEO(MODEL_JRB_FLOATING_PLATFORM, jrb_geo_000948), AREA(/*index*/ 1, jrb_geo_000A18), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -6750, 2126, 1482, /*angle*/ 0, 90, 0, /*behParam*/ 0x000A0000, /*beh*/ bhvSpinAirborneWarp), - WARP_NODE(/*id*/ 0x0A, /*destLevel*/ LEVEL_JRB, /*destArea*/ 0x01, /*destNode*/ 0x0A, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0xF3, /*destLevel*/ LEVEL_JRB, /*destArea*/ 0x02, /*destNode*/ 0x0A, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0xF0, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x01, /*destNode*/ 0x35, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0xF1, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x01, /*destNode*/ 0x67, /*flags*/ WARP_NO_CHECKPOINT), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ -6750, 2126, 1482, /*angle*/ 0, 90, 0, /*bhvParam*/ BPARAM2(WARP_NODE_0A), /*bhv*/ bhvSpinAirborneWarp), + WARP_NODE(/*id*/ WARP_NODE_0A, /*destLevel*/ LEVEL_JRB, /*destArea*/ 1, /*destNode*/ WARP_NODE_0A, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_WARP_FLOOR, /*destLevel*/ LEVEL_JRB, /*destArea*/ 2, /*destNode*/ WARP_NODE_0A, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_SUCCESS, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 1, /*destNode*/ WARP_NODE_35, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_DEATH, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 1, /*destNode*/ WARP_NODE_67, /*flags*/ WARP_NO_CHECKPOINT), WHIRLPOOL(/*unk2*/ 0, /*unk3*/ 3, /*pos*/ 4979, -5222, 2482, /*strength*/ -30), JUMP_LINK(script_func_local_1), JUMP_LINK(script_func_local_2), @@ -158,10 +158,10 @@ const LevelScript level_jrb_entry[] = { END_AREA(), AREA(/*index*/ 2, jrb_geo_000AFC), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 928, 1050, -1248, /*angle*/ 0, 180, 0, /*behParam*/ 0x000A0000, /*beh*/ bhvSwimmingWarp), - WARP_NODE(/*id*/ 0x0A, /*destLevel*/ LEVEL_JRB, /*destArea*/ 0x02, /*destNode*/ 0x0A, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0xF0, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x01, /*destNode*/ 0x35, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0xF1, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x01, /*destNode*/ 0x67, /*flags*/ WARP_NO_CHECKPOINT), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 928, 1050, -1248, /*angle*/ 0, 180, 0, /*bhvParam*/ BPARAM2(WARP_NODE_0A), /*bhv*/ bhvSwimmingWarp), + WARP_NODE(/*id*/ WARP_NODE_0A, /*destLevel*/ LEVEL_JRB, /*destArea*/ 2, /*destNode*/ WARP_NODE_0A, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_SUCCESS, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 1, /*destNode*/ WARP_NODE_35, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_DEATH, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 1, /*destNode*/ WARP_NODE_67, /*flags*/ WARP_NO_CHECKPOINT), JUMP_LINK(script_func_local_4), JUMP_LINK(script_func_local_5), TERRAIN(/*terrainData*/ jrb_seg7_area_2_collision), diff --git a/levels/jrb/sliding_box/geo.inc.c b/levels/jrb/sliding_box/geo.inc.c index 74d85b91..edd36ba6 100644 --- a/levels/jrb/sliding_box/geo.inc.c +++ b/levels/jrb/sliding_box/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000960 const GeoLayout jrb_geo_000960[] = { - GEO_CULLING_RADIUS(300), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, jrb_seg7_dl_070080F8), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(300), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, jrb_seg7_dl_070080F8), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/jrb/wooden_ship/geo.inc.c b/levels/jrb/wooden_ship/geo.inc.c index 80b97ded..abae94b9 100644 --- a/levels/jrb/wooden_ship/geo.inc.c +++ b/levels/jrb/wooden_ship/geo.inc.c @@ -1,55 +1,55 @@ // 0x0E000978 const GeoLayout jrb_geo_000978[] = { - GEO_CULLING_RADIUS(5000), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, jrb_seg7_dl_07008FD8), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(5000), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, jrb_seg7_dl_07008FD8), + GEO_CLOSE_NODE(), + GEO_END(), }; // 0x0E000990 const GeoLayout jrb_geo_000990[] = { - GEO_CULLING_RADIUS(5000), - GEO_OPEN_NODE(), - GEO_ASM(0, geo_update_layer_transparency), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, jrb_seg7_dl_070090B0), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(5000), + GEO_OPEN_NODE(), + GEO_ASM(0, geo_update_layer_transparency), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, jrb_seg7_dl_070090B0), + GEO_CLOSE_NODE(), + GEO_END(), }; // 0x0E0009B0 const GeoLayout jrb_geo_0009B0[] = { - GEO_CULLING_RADIUS(5000), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, jrb_seg7_dl_07009A58), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(5000), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, jrb_seg7_dl_07009A58), + GEO_CLOSE_NODE(), + GEO_END(), }; // 0x0E0009C8 const GeoLayout jrb_geo_0009C8[] = { - GEO_CULLING_RADIUS(5000), - GEO_OPEN_NODE(), - GEO_ASM(0, geo_update_layer_transparency), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, jrb_seg7_dl_07009B30), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(5000), + GEO_OPEN_NODE(), + GEO_ASM(0, geo_update_layer_transparency), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, jrb_seg7_dl_07009B30), + GEO_CLOSE_NODE(), + GEO_END(), }; // 0x0E0009E8 const GeoLayout jrb_geo_0009E8[] = { - GEO_CULLING_RADIUS(5000), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, jrb_seg7_dl_0700A608), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(5000), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, jrb_seg7_dl_0700A608), + GEO_CLOSE_NODE(), + GEO_END(), }; // 0x0E000A00 const GeoLayout jrb_geo_000A00[] = { - GEO_CULLING_RADIUS(5000), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, jrb_seg7_dl_0700AC68), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(5000), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, jrb_seg7_dl_0700AC68), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/level_defines.h b/levels/level_defines.h index c14f2523..19959a90 100644 --- a/levels/level_defines.h +++ b/levels/level_defines.h @@ -20,15 +20,15 @@ STUB_LEVEL( "", LEVEL_UNKNOWN_1, COURSE_NONE, 20000, 0x00, 0x00, 0x00, _, _) STUB_LEVEL( "", LEVEL_UNKNOWN_2, COURSE_NONE, 20000, 0x00, 0x00, 0x00, _, _) STUB_LEVEL( "", LEVEL_UNKNOWN_3, COURSE_NONE, 20000, 0x00, 0x00, 0x00, _, _) -DEFINE_LEVEL("TERESA OBAKE", LEVEL_BBH, COURSE_BBH, bbh, spooky, 28000, 0x28, 0x28, 0x28, sDynBbh, sCamBBH) +DEFINE_LEVEL("TERESA OBAKE", LEVEL_BBH, COURSE_BBH, bbh, spooky, 28000, 0x28, 0x28, 0x28, sDynBBH, sCamBBH) DEFINE_LEVEL("YYAMA1 % YSLD1", LEVEL_CCM, COURSE_CCM, ccm, snow, 17000, 0x10, 0x38, 0x38, _, sCamCCM) DEFINE_LEVEL("SELECT ROOM", LEVEL_CASTLE, COURSE_NONE, castle_inside, inside, 20000, 0x20, 0x20, 0x30, _, sCamCastle) -DEFINE_LEVEL("HORROR DUNGEON", LEVEL_HMC, COURSE_HMC, hmc, cave, 16000, 0x28, 0x28, 0x28, sDynHmc, sCamHMC) +DEFINE_LEVEL("HORROR DUNGEON", LEVEL_HMC, COURSE_HMC, hmc, cave, 16000, 0x28, 0x28, 0x28, sDynHMC, sCamHMC) DEFINE_LEVEL("SABAKU % PYRMD", LEVEL_SSL, COURSE_SSL, ssl, generic, 15000, 0x08, 0x30, 0x30, _, sCamSSL) DEFINE_LEVEL("BATTLE FIELD", LEVEL_BOB, COURSE_BOB, bob, generic, 15000, 0x08, 0x08, 0x08, _, _) DEFINE_LEVEL("YUKIYAMA2", LEVEL_SL, COURSE_SL, sl, snow, 14000, 0x10, 0x28, 0x28, _, sCamSL) -DEFINE_LEVEL("POOL KAI", LEVEL_WDW, COURSE_WDW, wdw, grass, 17000, 0x10, 0x18, 0x18, sDynWdw, _) -DEFINE_LEVEL("WTDG % TINBOTU", LEVEL_JRB, COURSE_JRB, jrb, water, 20000, 0x10, 0x18, 0x18, sDynJrb, _) +DEFINE_LEVEL("POOL KAI", LEVEL_WDW, COURSE_WDW, wdw, grass, 17000, 0x10, 0x18, 0x18, sDynWDW, _) +DEFINE_LEVEL("WTDG % TINBOTU", LEVEL_JRB, COURSE_JRB, jrb, water, 20000, 0x10, 0x18, 0x18, sDynJRB, _) DEFINE_LEVEL("BIG WORLD", LEVEL_THI, COURSE_THI, thi, grass, 20000, 0x0c, 0x0c, 0x20, _, sCamTHI) DEFINE_LEVEL("CLOCK TOWER", LEVEL_TTC, COURSE_TTC, ttc, machine, 18000, 0x18, 0x18, 0x18, _, _) DEFINE_LEVEL("RAINBOW CRUISE", LEVEL_RR, COURSE_RR, rr, sky, 20000, 0x20, 0x20, 0x20, _, sCamRR) @@ -39,7 +39,7 @@ DEFINE_LEVEL("EXT2 TIKA LAVA", LEVEL_BITFS, COURSE_BITFS, bitfs, DEFINE_LEVEL("EXT9 SUISOU", LEVEL_SA, COURSE_SA, sa, inside, 20000, 0x10, 0x10, 0x10, _, _) DEFINE_LEVEL("EXT3 HEAVEN", LEVEL_BITS, COURSE_BITS, bits, sky, 16000, 0x28, 0x28, 0x28, _, _) DEFINE_LEVEL("FIREB1 % INVLC", LEVEL_LLL, COURSE_LLL, lll, fire, 22000, 0x08, 0x30, 0x30, _, _) -DEFINE_LEVEL("WATER LAND", LEVEL_DDD, COURSE_DDD, ddd, water, 17000, 0x10, 0x20, 0x20, sDynDdd, _) +DEFINE_LEVEL("WATER LAND", LEVEL_DDD, COURSE_DDD, ddd, water, 17000, 0x10, 0x20, 0x20, sDynDDD, _) DEFINE_LEVEL("MOUNTAIN", LEVEL_WF, COURSE_WF, wf, grass, 13000, 0x08, 0x08, 0x08, _, _) DEFINE_LEVEL("ENDING", LEVEL_ENDING, COURSE_CAKE_END, ending, generic, 20000, 0x00, 0x00, 0x00, _, _) DEFINE_LEVEL("URANIWA", LEVEL_CASTLE_COURTYARD, COURSE_NONE, castle_courtyard, outside, 20000, 0x08, 0x08, 0x08, _, _) diff --git a/levels/lll/areas/1/10/geo.inc.c b/levels/lll/areas/1/10/geo.inc.c index 6d58c3e9..b26d352e 100644 --- a/levels/lll/areas/1/10/geo.inc.c +++ b/levels/lll/areas/1/10/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000A78 const GeoLayout lll_geo_000A78[] = { - GEO_CULLING_RADIUS(1300), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, lll_seg7_dl_070165C8), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(1300), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, lll_seg7_dl_070165C8), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/lll/areas/1/11/geo.inc.c b/levels/lll/areas/1/11/geo.inc.c index 16e66037..e3be5ee6 100644 --- a/levels/lll/areas/1/11/geo.inc.c +++ b/levels/lll/areas/1/11/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000A90 const GeoLayout lll_geo_000A90[] = { - GEO_CULLING_RADIUS(1000), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, lll_seg7_dl_07016B00), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(1000), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, lll_seg7_dl_07016B00), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/lll/areas/1/12/geo.inc.c b/levels/lll/areas/1/12/geo.inc.c index 6f3599ce..257b5fc4 100644 --- a/levels/lll/areas/1/12/geo.inc.c +++ b/levels/lll/areas/1/12/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000AA8 const GeoLayout lll_geo_000AA8[] = { - GEO_CULLING_RADIUS(900), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, lll_seg7_dl_070174E0), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(900), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, lll_seg7_dl_070174E0), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/lll/areas/1/13/geo.inc.c b/levels/lll/areas/1/13/geo.inc.c index 0947c8ec..5b69a54f 100644 --- a/levels/lll/areas/1/13/geo.inc.c +++ b/levels/lll/areas/1/13/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000AC0 const GeoLayout lll_geo_000AC0[] = { - GEO_CULLING_RADIUS(1000), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, lll_seg7_dl_070178A8), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(1000), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, lll_seg7_dl_070178A8), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/lll/areas/1/14/geo.inc.c b/levels/lll/areas/1/14/geo.inc.c index 13c7d3bf..614e0283 100644 --- a/levels/lll/areas/1/14/geo.inc.c +++ b/levels/lll/areas/1/14/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000AD8 const GeoLayout lll_geo_000AD8[] = { - GEO_CULLING_RADIUS(500), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, lll_seg7_dl_07017B50), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(500), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, lll_seg7_dl_07017B50), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/lll/areas/1/15/geo.inc.c b/levels/lll/areas/1/15/geo.inc.c index a1c367a8..75a70364 100644 --- a/levels/lll/areas/1/15/geo.inc.c +++ b/levels/lll/areas/1/15/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000AF0 const GeoLayout lll_geo_000AF0[] = { - GEO_CULLING_RADIUS(500), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, lll_seg7_dl_07017F40), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(500), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, lll_seg7_dl_07017F40), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/lll/areas/1/4/geo.inc.c b/levels/lll/areas/1/4/geo.inc.c index 7e78e075..252e8e64 100644 --- a/levels/lll/areas/1/4/geo.inc.c +++ b/levels/lll/areas/1/4/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E0009E0 const GeoLayout lll_geo_0009E0[] = { - GEO_CULLING_RADIUS(1700), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, lll_seg7_dl_07013D28), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(1700), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, lll_seg7_dl_07013D28), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/lll/areas/1/5/geo.inc.c b/levels/lll/areas/1/5/geo.inc.c index 47192964..351992a2 100644 --- a/levels/lll/areas/1/5/geo.inc.c +++ b/levels/lll/areas/1/5/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E0009F8 const GeoLayout lll_geo_0009F8[] = { - GEO_CULLING_RADIUS(2200), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, lll_seg7_dl_07014788), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(2200), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, lll_seg7_dl_07014788), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/lll/areas/1/6/geo.inc.c b/levels/lll/areas/1/6/geo.inc.c index e98b6def..3d65f937 100644 --- a/levels/lll/areas/1/6/geo.inc.c +++ b/levels/lll/areas/1/6/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000A10 const GeoLayout lll_geo_000A10[] = { - GEO_CULLING_RADIUS(1200), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, lll_seg7_dl_07014BD8), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(1200), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, lll_seg7_dl_07014BD8), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/lll/areas/1/7/geo.inc.c b/levels/lll/areas/1/7/geo.inc.c index 58c344f9..844a7473 100644 --- a/levels/lll/areas/1/7/geo.inc.c +++ b/levels/lll/areas/1/7/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000A28 const GeoLayout lll_geo_000A28[] = { - GEO_CULLING_RADIUS(2000), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, lll_seg7_dl_07015458), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(2000), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, lll_seg7_dl_07015458), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/lll/areas/1/8/geo.inc.c b/levels/lll/areas/1/8/geo.inc.c index 8f353dac..ff4b716a 100644 --- a/levels/lll/areas/1/8/geo.inc.c +++ b/levels/lll/areas/1/8/geo.inc.c @@ -1,9 +1,9 @@ // 0x0E000A40 const GeoLayout lll_geo_000A40[] = { - GEO_CULLING_RADIUS(1700), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, lll_seg7_dl_07015C88), - GEO_DISPLAY_LIST(LAYER_ALPHA, lll_seg7_dl_07015E20), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(1700), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, lll_seg7_dl_07015C88), + GEO_DISPLAY_LIST(LAYER_ALPHA, lll_seg7_dl_07015E20), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/lll/areas/1/9/geo.inc.c b/levels/lll/areas/1/9/geo.inc.c index 7ab21641..87eb9b75 100644 --- a/levels/lll/areas/1/9/geo.inc.c +++ b/levels/lll/areas/1/9/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000A60 const GeoLayout lll_geo_000A60[] = { - GEO_CULLING_RADIUS(1500), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, lll_seg7_dl_07016250), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(1500), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, lll_seg7_dl_07016250), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/lll/areas/1/geo.inc.c b/levels/lll/areas/1/geo.inc.c index 865cdc96..dd76b9a4 100644 --- a/levels/lll/areas/1/geo.inc.c +++ b/levels/lll/areas/1/geo.inc.c @@ -1,30 +1,30 @@ // 0x0E000E00 const GeoLayout lll_geo_000E00[] = { - GEO_NODE_SCREEN_AREA(10, SCREEN_WIDTH/2, SCREEN_HEIGHT/2, SCREEN_WIDTH/2, SCREEN_HEIGHT/2), - GEO_OPEN_NODE(), - GEO_ZBUFFER(0), - GEO_OPEN_NODE(), - GEO_NODE_ORTHO(100), - GEO_OPEN_NODE(), - GEO_BACKGROUND(BACKGROUND_FLAMING_SKY, geo_skybox_main), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ZBUFFER(1), - GEO_OPEN_NODE(), - GEO_CAMERA_FRUSTUM_WITH_FUNC(64, 100, 20000, geo_camera_fov), - GEO_OPEN_NODE(), - GEO_CAMERA(1, 0, 2000, 6000, 0, 0, -8192, geo_camera_main), + GEO_NODE_SCREEN_AREA(10, SCREEN_WIDTH/2, SCREEN_HEIGHT/2, SCREEN_WIDTH/2, SCREEN_HEIGHT/2), + GEO_OPEN_NODE(), + GEO_ZBUFFER(0), + GEO_OPEN_NODE(), + GEO_NODE_ORTHO(100), GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, lll_seg7_dl_070134E0), - GEO_DISPLAY_LIST(LAYER_ALPHA, lll_seg7_dl_070138F8), - GEO_DISPLAY_LIST(LAYER_ALPHA, lll_seg7_dl_070137C0), - GEO_ASM( 0, geo_movtex_pause_control), - GEO_ASM(0x2201, geo_movtex_draw_nocolor), - GEO_RENDER_OBJ(), - GEO_ASM( 12, geo_envfx_main), + GEO_BACKGROUND(BACKGROUND_FLAMING_SKY, geo_skybox_main), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CLOSE_NODE(), + GEO_ZBUFFER(1), + GEO_OPEN_NODE(), + GEO_CAMERA_FRUSTUM_WITH_FUNC(64, 100, 20000, geo_camera_fov), + GEO_OPEN_NODE(), + GEO_CAMERA(1, 0, 2000, 6000, 0, 0, -8192, geo_camera_main), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, lll_seg7_dl_070134E0), + GEO_DISPLAY_LIST(LAYER_ALPHA, lll_seg7_dl_070138F8), + GEO_DISPLAY_LIST(LAYER_ALPHA, lll_seg7_dl_070137C0), + GEO_ASM( 0, geo_movtex_pause_control), + GEO_ASM(0x2201, geo_movtex_draw_nocolor), + GEO_RENDER_OBJ(), + GEO_ASM( 12, geo_envfx_main), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/lll/areas/1/macro.inc.c b/levels/lll/areas/1/macro.inc.c index f4813073..c5c951f4 100644 --- a/levels/lll/areas/1/macro.inc.c +++ b/levels/lll/areas/1/macro.inc.c @@ -1,55 +1,55 @@ // 0x0701CE18 - 0x0701D018 const MacroObject lll_seg7_area_1_macro_objs[] = { - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -5800, 220, 250), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -5100, 220, 250), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -5100, 220, 1000), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -4400, 220, 1000), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -4400, 220, 1750), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -5100, 220, 1750), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -5800, 220, 1750), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -5800, 220, 1000), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 0, /*pos*/ -3728, 154, 6057, /*behParam*/ DIALOG_068), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 315, /*pos*/ 1350, 154, 5942, /*behParam*/ DIALOG_016), - MACRO_OBJECT(/*preset*/ macro_coin_line_horizontal_flying, /*yaw*/ 0, /*pos*/ -5760, 100, 3040), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_hidden_1up, /*yaw*/ 0, /*pos*/ -5100, 540, -4070, /*behParam*/ 4), - MACRO_OBJECT(/*preset*/ macro_hidden_1up_trigger, /*yaw*/ 0, /*pos*/ -5400, 320, -4070), - MACRO_OBJECT(/*preset*/ macro_hidden_1up_trigger, /*yaw*/ 0, /*pos*/ -4800, 320, -4070), - MACRO_OBJECT(/*preset*/ macro_hidden_1up_trigger, /*yaw*/ 0, /*pos*/ -5100, 320, -3770), - MACRO_OBJECT(/*preset*/ macro_hidden_1up_trigger, /*yaw*/ 0, /*pos*/ -5100, 320, -4370), - MACRO_OBJECT(/*preset*/ macro_coin_line_horizontal_flying, /*yaw*/ 90, /*pos*/ -1920, 50, -4120), - MACRO_OBJECT(/*preset*/ macro_yellow_coin, /*yaw*/ 0, /*pos*/ 3300, 50, -2692), - MACRO_OBJECT(/*preset*/ macro_yellow_coin, /*yaw*/ 0, /*pos*/ 3330, 50, -3700), - MACRO_OBJECT(/*preset*/ macro_yellow_coin, /*yaw*/ 0, /*pos*/ 4340, 50, -3700), - MACRO_OBJECT(/*preset*/ macro_yellow_coin, /*yaw*/ 0, /*pos*/ 4340, 50, -2692), - MACRO_OBJECT(/*preset*/ macro_yellow_coin, /*yaw*/ 0, /*pos*/ 0, 200, 1200), - MACRO_OBJECT(/*preset*/ macro_yellow_coin, /*yaw*/ 0, /*pos*/ 1200, 200, 0), - MACRO_OBJECT(/*preset*/ macro_yellow_coin, /*yaw*/ 0, /*pos*/ -1200, 200, 0), - MACRO_OBJECT(/*preset*/ macro_1up, /*yaw*/ 0, /*pos*/ 0, 307, -2085), - MACRO_OBJECT(/*preset*/ macro_coin_line_horizontal_flying, /*yaw*/ 90, /*pos*/ 3000, 50, 520), - MACRO_OBJECT(/*preset*/ macro_coin_ring_horizontal, /*yaw*/ 0, /*pos*/ 7160, 320, 1400), - MACRO_OBJECT(/*preset*/ macro_coin_ring_horizontal, /*yaw*/ 0, /*pos*/ 3800, 320, -5600), - MACRO_OBJECT(/*preset*/ macro_mr_i, /*yaw*/ 0, /*pos*/ 6673, 154, -3060), - MACRO_OBJECT(/*preset*/ macro_coin_ring_horizontal, /*yaw*/ 0, /*pos*/ 6673, 154, -3060), - MACRO_OBJECT(/*preset*/ macro_coin_line_horizontal, /*yaw*/ 45, /*pos*/ 6300, 755, -6580), - MACRO_OBJECT(/*preset*/ macro_1up, /*yaw*/ 0, /*pos*/ 6326, 686, -6580), - MACRO_OBJECT(/*preset*/ macro_1up, /*yaw*/ 0, /*pos*/ 0, 46, -7400), - MACRO_OBJECT(/*preset*/ macro_1up, /*yaw*/ 0, /*pos*/ -3133, 230, -2126), - MACRO_OBJECT(/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ -3320, 161, -1860), - MACRO_OBJECT(/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ -3346, 70, -1486), - MACRO_OBJECT(/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ -2760, 113, -2260), - MACRO_OBJECT(/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ -2440, 67, -2286), - MACRO_OBJECT(/*preset*/ macro_1up, /*yaw*/ 0, /*pos*/ -2333, 653, 886), - MACRO_OBJECT(/*preset*/ macro_coin_line_horizontal_flying, /*yaw*/ 0, /*pos*/ -1960, 38, 3693), - MACRO_OBJECT(/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ -6966, 41, 3906), - MACRO_OBJECT(/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ -6806, 188, 4653), - MACRO_OBJECT(/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ -6033, 70, 4973), - MACRO_OBJECT(/*preset*/ macro_1up, /*yaw*/ 0, /*pos*/ -6780, 275, -6766), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 0, /*pos*/ -3980, 154, 6057, /*behParam*/ DIALOG_086), - MACRO_OBJECT(/*preset*/ macro_jumping_box, /*yaw*/ 0, /*pos*/ 4170, 154, -1940), - MACRO_OBJECT(/*preset*/ macro_flamethrower, /*yaw*/ 0, /*pos*/ 1400, -20, 3720), - MACRO_OBJECT(/*preset*/ macro_flamethrower, /*yaw*/ 0, /*pos*/ 7100, -20, 3420), - MACRO_OBJECT(/*preset*/ macro_flamethrower, /*yaw*/ 0, /*pos*/ 7300, -20, 5160), - MACRO_OBJECT(/*preset*/ macro_flamethrower, /*yaw*/ 0, /*pos*/ 7100, -20, 5700), - MACRO_OBJECT(/*preset*/ macro_box_wing_cap, /*yaw*/ 0, /*pos*/ -5900, 460, 6400), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -5800, 220, 250), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -5100, 220, 250), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -5100, 220, 1000), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -4400, 220, 1000), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -4400, 220, 1750), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -5100, 220, 1750), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -5800, 220, 1750), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -5800, 220, 1000), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 0, /*pos*/ -3728, 154, 6057, /*bhvParam*/ DIALOG_068), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 315, /*pos*/ 1350, 154, 5942, /*bhvParam*/ DIALOG_016), + MACRO_OBJECT (/*preset*/ macro_coin_line_horizontal_flying, /*yaw*/ 0, /*pos*/ -5760, 100, 3040), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_hidden_1up, /*yaw*/ 0, /*pos*/ -5100, 540, -4070, /*bhvParam*/ 4), + MACRO_OBJECT (/*preset*/ macro_hidden_1up_trigger, /*yaw*/ 0, /*pos*/ -5400, 320, -4070), + MACRO_OBJECT (/*preset*/ macro_hidden_1up_trigger, /*yaw*/ 0, /*pos*/ -4800, 320, -4070), + MACRO_OBJECT (/*preset*/ macro_hidden_1up_trigger, /*yaw*/ 0, /*pos*/ -5100, 320, -3770), + MACRO_OBJECT (/*preset*/ macro_hidden_1up_trigger, /*yaw*/ 0, /*pos*/ -5100, 320, -4370), + MACRO_OBJECT (/*preset*/ macro_coin_line_horizontal_flying, /*yaw*/ 90, /*pos*/ -1920, 50, -4120), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_1, /*yaw*/ 0, /*pos*/ 3300, 50, -2692), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_1, /*yaw*/ 0, /*pos*/ 3330, 50, -3700), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_1, /*yaw*/ 0, /*pos*/ 4340, 50, -3700), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_1, /*yaw*/ 0, /*pos*/ 4340, 50, -2692), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_1, /*yaw*/ 0, /*pos*/ 0, 200, 1200), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_1, /*yaw*/ 0, /*pos*/ 1200, 200, 0), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_1, /*yaw*/ 0, /*pos*/ -1200, 200, 0), + MACRO_OBJECT (/*preset*/ macro_1up, /*yaw*/ 0, /*pos*/ 0, 307, -2085), + MACRO_OBJECT (/*preset*/ macro_coin_line_horizontal_flying, /*yaw*/ 90, /*pos*/ 3000, 50, 520), + MACRO_OBJECT (/*preset*/ macro_coin_ring_horizontal, /*yaw*/ 0, /*pos*/ 7160, 320, 1400), + MACRO_OBJECT (/*preset*/ macro_coin_ring_horizontal, /*yaw*/ 0, /*pos*/ 3800, 320, -5600), + MACRO_OBJECT (/*preset*/ macro_mr_i, /*yaw*/ 0, /*pos*/ 6673, 154, -3060), + MACRO_OBJECT (/*preset*/ macro_coin_ring_horizontal, /*yaw*/ 0, /*pos*/ 6673, 154, -3060), + MACRO_OBJECT (/*preset*/ macro_coin_line_horizontal, /*yaw*/ 45, /*pos*/ 6300, 755, -6580), + MACRO_OBJECT (/*preset*/ macro_1up, /*yaw*/ 0, /*pos*/ 6326, 686, -6580), + MACRO_OBJECT (/*preset*/ macro_1up, /*yaw*/ 0, /*pos*/ 0, 46, -7400), + MACRO_OBJECT (/*preset*/ macro_1up, /*yaw*/ 0, /*pos*/ -3133, 230, -2126), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ -3320, 161, -1860), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ -3346, 70, -1486), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ -2760, 113, -2260), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ -2440, 67, -2286), + MACRO_OBJECT (/*preset*/ macro_1up, /*yaw*/ 0, /*pos*/ -2333, 653, 886), + MACRO_OBJECT (/*preset*/ macro_coin_line_horizontal_flying, /*yaw*/ 0, /*pos*/ -1960, 38, 3693), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ -6966, 41, 3906), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ -6806, 188, 4653), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ -6033, 70, 4973), + MACRO_OBJECT (/*preset*/ macro_1up, /*yaw*/ 0, /*pos*/ -6780, 275, -6766), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 0, /*pos*/ -3980, 154, 6057, /*bhvParam*/ DIALOG_086), + MACRO_OBJECT (/*preset*/ macro_jumping_box, /*yaw*/ 0, /*pos*/ 4170, 154, -1940), + MACRO_OBJECT (/*preset*/ macro_flamethrower, /*yaw*/ 0, /*pos*/ 1400, -20, 3720), + MACRO_OBJECT (/*preset*/ macro_flamethrower, /*yaw*/ 0, /*pos*/ 7100, -20, 3420), + MACRO_OBJECT (/*preset*/ macro_flamethrower, /*yaw*/ 0, /*pos*/ 7300, -20, 5160), + MACRO_OBJECT (/*preset*/ macro_flamethrower, /*yaw*/ 0, /*pos*/ 7100, -20, 5700), + MACRO_OBJECT (/*preset*/ macro_box_wing_cap, /*yaw*/ 0, /*pos*/ -5900, 460, 6400), MACRO_OBJECT_END(), }; diff --git a/levels/lll/areas/2/geo.inc.c b/levels/lll/areas/2/geo.inc.c index a12fc825..ea8da767 100644 --- a/levels/lll/areas/2/geo.inc.c +++ b/levels/lll/areas/2/geo.inc.c @@ -1,33 +1,33 @@ // 0x0E000EC0 const GeoLayout lll_geo_000EC0[] = { - GEO_NODE_SCREEN_AREA(10, SCREEN_WIDTH/2, SCREEN_HEIGHT/2, SCREEN_WIDTH/2, SCREEN_HEIGHT/2), - GEO_OPEN_NODE(), - GEO_ZBUFFER(0), - GEO_OPEN_NODE(), - GEO_NODE_ORTHO(100), - GEO_OPEN_NODE(), - GEO_BACKGROUND_COLOR(0x0001), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ZBUFFER(1), - GEO_OPEN_NODE(), - GEO_CAMERA_FRUSTUM_WITH_FUNC(45, 100, 12800, geo_camera_fov), - GEO_OPEN_NODE(), - GEO_CAMERA(2, 0, 2000, 6000, 0, 0, 0, geo_camera_main), + GEO_NODE_SCREEN_AREA(10, SCREEN_WIDTH/2, SCREEN_HEIGHT/2, SCREEN_WIDTH/2, SCREEN_HEIGHT/2), + GEO_OPEN_NODE(), + GEO_ZBUFFER(0), + GEO_OPEN_NODE(), + GEO_NODE_ORTHO(100), GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, lll_seg7_dl_070235C8), - GEO_DISPLAY_LIST(LAYER_OPAQUE, lll_seg7_dl_07024C18), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, lll_seg7_dl_070255D8), - GEO_DISPLAY_LIST(LAYER_OPAQUE, lll_seg7_dl_07025A48), - GEO_DISPLAY_LIST(LAYER_ALPHA, lll_seg7_dl_07025BD8), - GEO_ASM( 0, geo_movtex_pause_control), - GEO_ASM(0x2202, geo_movtex_draw_nocolor), - GEO_ASM(0x2202, geo_movtex_draw_water_regions), - GEO_RENDER_OBJ(), - GEO_ASM( 0, geo_envfx_main), + GEO_BACKGROUND_COLOR(0x0001), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CLOSE_NODE(), + GEO_ZBUFFER(1), + GEO_OPEN_NODE(), + GEO_CAMERA_FRUSTUM_WITH_FUNC(45, 100, 12800, geo_camera_fov), + GEO_OPEN_NODE(), + GEO_CAMERA(2, 0, 2000, 6000, 0, 0, 0, geo_camera_main), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, lll_seg7_dl_070235C8), + GEO_DISPLAY_LIST(LAYER_OPAQUE, lll_seg7_dl_07024C18), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, lll_seg7_dl_070255D8), + GEO_DISPLAY_LIST(LAYER_OPAQUE, lll_seg7_dl_07025A48), + GEO_DISPLAY_LIST(LAYER_ALPHA, lll_seg7_dl_07025BD8), + GEO_ASM( 0, geo_movtex_pause_control), + GEO_ASM(0x2202, geo_movtex_draw_nocolor), + GEO_ASM(0x2202, geo_movtex_draw_water_regions), + GEO_RENDER_OBJ(), + GEO_ASM( 0, geo_envfx_main), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/lll/areas/2/macro.inc.c b/levels/lll/areas/2/macro.inc.c index 92590b4d..1c382cb1 100644 --- a/levels/lll/areas/2/macro.inc.c +++ b/levels/lll/areas/2/macro.inc.c @@ -7,8 +7,8 @@ const MacroObject lll_seg7_area_2_macro_objs[] = { MACRO_OBJECT(/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ 2520, 174, -1220), MACRO_OBJECT(/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ 2840, 249, -460), MACRO_OBJECT(/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ 2800, 449, 460), - MACRO_OBJECT(/*preset*/ macro_bully, /*yaw*/ 0, /*pos*/ 1300, 1029, 2300), - MACRO_OBJECT(/*preset*/ macro_bully, /*yaw*/ 0, /*pos*/ -960, 2442, -2610), + MACRO_OBJECT(/*preset*/ macro_small_bully, /*yaw*/ 0, /*pos*/ 1300, 1029, 2300), + MACRO_OBJECT(/*preset*/ macro_small_bully, /*yaw*/ 0, /*pos*/ -960, 2442, -2610), MACRO_OBJECT(/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ 2180, 775, 1720), MACRO_OBJECT(/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ 1700, 1029, 2100), MACRO_OBJECT(/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ 940, 1029, 2540), @@ -24,7 +24,7 @@ const MacroObject lll_seg7_area_2_macro_objs[] = { MACRO_OBJECT(/*preset*/ macro_hidden_1up_in_pole, /*yaw*/ 0, /*pos*/ 1078, 4170, -2270), MACRO_OBJECT(/*preset*/ macro_recovery_heart, /*yaw*/ 0, /*pos*/ -1627, 1750, 750), MACRO_OBJECT(/*preset*/ macro_coin_line_horizontal, /*yaw*/ 90, /*pos*/ 182, 2623, -2529), - MACRO_OBJECT(/*preset*/ macro_bouncing_fireball, /*yaw*/ 25, /*pos*/ 740, 0, -1840), - MACRO_OBJECT(/*preset*/ macro_bouncing_fireball, /*yaw*/ 225, /*pos*/ 1420, 0, -1720), + MACRO_OBJECT(/*preset*/ macro_bouncing_fireball_2, /*yaw*/ 25, /*pos*/ 740, 0, -1840), + MACRO_OBJECT(/*preset*/ macro_bouncing_fireball_2, /*yaw*/ 225, /*pos*/ 1420, 0, -1720), MACRO_OBJECT_END(), }; diff --git a/levels/lll/collapsing_wooden_platform/geo.inc.c b/levels/lll/collapsing_wooden_platform/geo.inc.c index c36cf6dc..892fe7f4 100644 --- a/levels/lll/collapsing_wooden_platform/geo.inc.c +++ b/levels/lll/collapsing_wooden_platform/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000B80 const GeoLayout lll_geo_000B80[] = { - GEO_CULLING_RADIUS(450), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, lll_seg7_dl_07019160), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(450), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, lll_seg7_dl_07019160), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/lll/drawbridge_part/geo.inc.c b/levels/lll/drawbridge_part/geo.inc.c index ee552c89..1dbaa365 100644 --- a/levels/lll/drawbridge_part/geo.inc.c +++ b/levels/lll/drawbridge_part/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000B20 const GeoLayout lll_geo_000B20[] = { - GEO_CULLING_RADIUS(850), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, lll_seg7_dl_07018680), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(850), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, lll_seg7_dl_07018680), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/lll/leveldata.c b/levels/lll/leveldata.c index 17596093..21f19c12 100644 --- a/levels/lll/leveldata.c +++ b/levels/lll/leveldata.c @@ -3,8 +3,8 @@ #include "surface_terrains.h" #include "moving_texture_macros.h" #include "level_misc_macros.h" -#include "macro_preset_names.h" -#include "special_preset_names.h" +#include "macro_presets.h" +#include "special_presets.h" #include "textures.h" #include "dialog_ids.h" diff --git a/levels/lll/long_wooden_bridge/geo.inc.c b/levels/lll/long_wooden_bridge/geo.inc.c index 359f7b49..a1afd595 100644 --- a/levels/lll/long_wooden_bridge/geo.inc.c +++ b/levels/lll/long_wooden_bridge/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000B98 const GeoLayout lll_geo_000B98[] = { - GEO_CULLING_RADIUS(900), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, lll_seg7_dl_070193E0), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(900), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, lll_seg7_dl_070193E0), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/lll/moving_octagonal_mesh_platform/geo.inc.c b/levels/lll/moving_octagonal_mesh_platform/geo.inc.c index 05ac7802..fd532985 100644 --- a/levels/lll/moving_octagonal_mesh_platform/geo.inc.c +++ b/levels/lll/moving_octagonal_mesh_platform/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000B08 const GeoLayout lll_geo_000B08[] = { - GEO_CULLING_RADIUS(550), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, lll_seg7_dl_07018380), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(550), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, lll_seg7_dl_07018380), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/lll/puzzle_piece/geo.inc.c b/levels/lll/puzzle_piece/geo.inc.c index ca199e5c..1655b7ca 100644 --- a/levels/lll/puzzle_piece/geo.inc.c +++ b/levels/lll/puzzle_piece/geo.inc.c @@ -1,139 +1,139 @@ // 0x0E000C10 const GeoLayout lll_geo_000C10[] = { - GEO_CULLING_RADIUS(350), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, lll_seg7_dl_0701A388), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, lll_seg7_dl_0701A628), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(350), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, lll_seg7_dl_0701A388), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, lll_seg7_dl_0701A628), + GEO_CLOSE_NODE(), + GEO_END(), }; // 0x0E000C30 const GeoLayout lll_geo_000C30[] = { - GEO_CULLING_RADIUS(350), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, lll_seg7_dl_0701A3B8), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, lll_seg7_dl_0701A628), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(350), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, lll_seg7_dl_0701A3B8), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, lll_seg7_dl_0701A628), + GEO_CLOSE_NODE(), + GEO_END(), }; // 0x0E000C50 const GeoLayout lll_geo_000C50[] = { - GEO_CULLING_RADIUS(350), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, lll_seg7_dl_0701A3E8), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, lll_seg7_dl_0701A628), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(350), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, lll_seg7_dl_0701A3E8), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, lll_seg7_dl_0701A628), + GEO_CLOSE_NODE(), + GEO_END(), }; // 0x0E000C70 const GeoLayout lll_geo_000C70[] = { - GEO_CULLING_RADIUS(350), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, lll_seg7_dl_0701A418), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, lll_seg7_dl_0701A628), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(350), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, lll_seg7_dl_0701A418), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, lll_seg7_dl_0701A628), + GEO_CLOSE_NODE(), + GEO_END(), }; // 0x0E000C90 const GeoLayout lll_geo_000C90[] = { - GEO_CULLING_RADIUS(350), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, lll_seg7_dl_0701A448), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, lll_seg7_dl_0701A628), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(350), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, lll_seg7_dl_0701A448), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, lll_seg7_dl_0701A628), + GEO_CLOSE_NODE(), + GEO_END(), }; // 0x0E000CB0 const GeoLayout lll_geo_000CB0[] = { - GEO_CULLING_RADIUS(350), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, lll_seg7_dl_0701A478), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, lll_seg7_dl_0701A628), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(350), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, lll_seg7_dl_0701A478), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, lll_seg7_dl_0701A628), + GEO_CLOSE_NODE(), + GEO_END(), }; // 0x0E000CD0 const GeoLayout lll_geo_000CD0[] = { - GEO_CULLING_RADIUS(350), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, lll_seg7_dl_0701A4A8), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, lll_seg7_dl_0701A628), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(350), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, lll_seg7_dl_0701A4A8), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, lll_seg7_dl_0701A628), + GEO_CLOSE_NODE(), + GEO_END(), }; // 0x0E000CF0 const GeoLayout lll_geo_000CF0[] = { - GEO_CULLING_RADIUS(350), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, lll_seg7_dl_0701A4D8), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, lll_seg7_dl_0701A628), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(350), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, lll_seg7_dl_0701A4D8), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, lll_seg7_dl_0701A628), + GEO_CLOSE_NODE(), + GEO_END(), }; // 0x0E000D10 const GeoLayout lll_geo_000D10[] = { - GEO_CULLING_RADIUS(350), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, lll_seg7_dl_0701A508), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, lll_seg7_dl_0701A628), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(350), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, lll_seg7_dl_0701A508), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, lll_seg7_dl_0701A628), + GEO_CLOSE_NODE(), + GEO_END(), }; // 0x0E000D30 const GeoLayout lll_geo_000D30[] = { - GEO_CULLING_RADIUS(350), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, lll_seg7_dl_0701A538), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, lll_seg7_dl_0701A628), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(350), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, lll_seg7_dl_0701A538), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, lll_seg7_dl_0701A628), + GEO_CLOSE_NODE(), + GEO_END(), }; // 0x0E000D50 const GeoLayout lll_geo_000D50[] = { - GEO_CULLING_RADIUS(350), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, lll_seg7_dl_0701A568), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, lll_seg7_dl_0701A628), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(350), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, lll_seg7_dl_0701A568), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, lll_seg7_dl_0701A628), + GEO_CLOSE_NODE(), + GEO_END(), }; // 0x0E000D70 const GeoLayout lll_geo_000D70[] = { - GEO_CULLING_RADIUS(350), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, lll_seg7_dl_0701A598), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, lll_seg7_dl_0701A628), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(350), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, lll_seg7_dl_0701A598), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, lll_seg7_dl_0701A628), + GEO_CLOSE_NODE(), + GEO_END(), }; // 0x0E000D90 const GeoLayout lll_geo_000D90[] = { - GEO_CULLING_RADIUS(350), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, lll_seg7_dl_0701A5C8), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, lll_seg7_dl_0701A628), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(350), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, lll_seg7_dl_0701A5C8), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, lll_seg7_dl_0701A628), + GEO_CLOSE_NODE(), + GEO_END(), }; // 0x0E000DB0 const GeoLayout lll_geo_000DB0[] = { - GEO_CULLING_RADIUS(350), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, lll_seg7_dl_0701A5F8), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, lll_seg7_dl_0701A628), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(350), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, lll_seg7_dl_0701A5F8), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, lll_seg7_dl_0701A628), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/lll/rolling_log/geo.inc.c b/levels/lll/rolling_log/geo.inc.c index ad1fb7d8..3a5aded9 100644 --- a/levels/lll/rolling_log/geo.inc.c +++ b/levels/lll/rolling_log/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000DE8 const GeoLayout lll_geo_000DE8[] = { - GEO_CULLING_RADIUS(1300), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, lll_seg7_dl_0701AD70), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(1300), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, lll_seg7_dl_0701AD70), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/lll/rotating_block_fire_bars/geo.inc.c b/levels/lll/rotating_block_fire_bars/geo.inc.c index 415b2977..32cfec94 100644 --- a/levels/lll/rotating_block_fire_bars/geo.inc.c +++ b/levels/lll/rotating_block_fire_bars/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000B38 const GeoLayout lll_geo_000B38[] = { - GEO_CULLING_RADIUS(500), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, lll_seg7_dl_07018A30), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(500), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, lll_seg7_dl_07018A30), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/lll/rotating_hexagonal_ring/geo.inc.c b/levels/lll/rotating_hexagonal_ring/geo.inc.c index cbacacfe..140ba508 100644 --- a/levels/lll/rotating_hexagonal_ring/geo.inc.c +++ b/levels/lll/rotating_hexagonal_ring/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000BB0 const GeoLayout lll_geo_000BB0[] = { - GEO_CULLING_RADIUS(2100), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, lll_seg7_dl_07019A08), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(2100), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, lll_seg7_dl_07019A08), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/lll/script.c b/levels/lll/script.c index 1322d6c2..0873972c 100644 --- a/levels/lll/script.c +++ b/levels/lll/script.c @@ -18,118 +18,118 @@ // Unlike most levels, level geometry objects in LLL are defined as regular objects instead of terrain objects. static const LevelScript script_func_local_1[] = { - OBJECT(/*model*/ MODEL_LEVEL_GEOMETRY_03, /*pos*/ 3840, 0, -5631, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvStaticObject), - OBJECT(/*model*/ MODEL_LEVEL_GEOMETRY_04, /*pos*/ 4992, 0, -639, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvStaticObject), - OBJECT(/*model*/ MODEL_LEVEL_GEOMETRY_05, /*pos*/ 7168, 0, 1408, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvStaticObject), - OBJECT(/*model*/ MODEL_LEVEL_GEOMETRY_06, /*pos*/ 0, 0, 3712, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvStaticObject), - OBJECT(/*model*/ MODEL_LEVEL_GEOMETRY_07, /*pos*/ -3199, 0, 3456, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvStaticObject), - OBJECT(/*model*/ MODEL_LEVEL_GEOMETRY_08, /*pos*/ -5119, 0, -2047, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvStaticObject), - OBJECT(/*model*/ MODEL_LEVEL_GEOMETRY_0A, /*pos*/ 0, 0, 0, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvStaticObject), - OBJECT(/*model*/ MODEL_LEVEL_GEOMETRY_0B, /*pos*/ 0, 0, 6272, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvStaticObject), - OBJECT(/*model*/ MODEL_LEVEL_GEOMETRY_0C, /*pos*/ 5632, 0, 1408, /*angle*/ 0, 270, 0, /*behParam*/ 0x00000000, /*beh*/ bhvStaticObject), - OBJECT(/*model*/ MODEL_LEVEL_GEOMETRY_0C, /*pos*/ 2048, 0, 3456, /*angle*/ 0, 180, 0, /*behParam*/ 0x00000000, /*beh*/ bhvStaticObject), - OBJECT(/*model*/ MODEL_LEVEL_GEOMETRY_0C, /*pos*/ -4607, 0, 3456, /*angle*/ 0, 270, 0, /*behParam*/ 0x00000000, /*beh*/ bhvStaticObject), - OBJECT(/*model*/ MODEL_LEVEL_GEOMETRY_0C, /*pos*/ -5119, 0, -511, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvStaticObject), - OBJECT(/*model*/ MODEL_LEVEL_GEOMETRY_0D, /*pos*/ 0, 0, -2047, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvStaticObject), + OBJECT(/*model*/ MODEL_LEVEL_GEOMETRY_03, /*pos*/ 3840, 0, -5631, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvStaticObject), + OBJECT(/*model*/ MODEL_LEVEL_GEOMETRY_04, /*pos*/ 4992, 0, -639, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvStaticObject), + OBJECT(/*model*/ MODEL_LEVEL_GEOMETRY_05, /*pos*/ 7168, 0, 1408, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvStaticObject), + OBJECT(/*model*/ MODEL_LEVEL_GEOMETRY_06, /*pos*/ 0, 0, 3712, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvStaticObject), + OBJECT(/*model*/ MODEL_LEVEL_GEOMETRY_07, /*pos*/ -3199, 0, 3456, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvStaticObject), + OBJECT(/*model*/ MODEL_LEVEL_GEOMETRY_08, /*pos*/ -5119, 0, -2047, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvStaticObject), + OBJECT(/*model*/ MODEL_LEVEL_GEOMETRY_0A, /*pos*/ 0, 0, 0, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvStaticObject), + OBJECT(/*model*/ MODEL_LEVEL_GEOMETRY_0B, /*pos*/ 0, 0, 6272, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvStaticObject), + OBJECT(/*model*/ MODEL_LEVEL_GEOMETRY_0C, /*pos*/ 5632, 0, 1408, /*angle*/ 0, 270, 0, /*bhvParam*/ 0, /*bhv*/ bhvStaticObject), + OBJECT(/*model*/ MODEL_LEVEL_GEOMETRY_0C, /*pos*/ 2048, 0, 3456, /*angle*/ 0, 180, 0, /*bhvParam*/ 0, /*bhv*/ bhvStaticObject), + OBJECT(/*model*/ MODEL_LEVEL_GEOMETRY_0C, /*pos*/ -4607, 0, 3456, /*angle*/ 0, 270, 0, /*bhvParam*/ 0, /*bhv*/ bhvStaticObject), + OBJECT(/*model*/ MODEL_LEVEL_GEOMETRY_0C, /*pos*/ -5119, 0, -511, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvStaticObject), + OBJECT(/*model*/ MODEL_LEVEL_GEOMETRY_0D, /*pos*/ 0, 0, -2047, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvStaticObject), // This behavior differs from the rest in that it actually has collision rather than being purely visual. // A likely explanation is that this object was added in after the collision model was made, and they didn't want // to redo the collision so they just added a new behavior for it. - OBJECT(/*model*/ MODEL_LEVEL_GEOMETRY_0E, /*pos*/ -5115, 300, -3200, /*angle*/ 0, 90, 0, /*behParam*/ 0x00000000, /*beh*/ bhvLllHexagonalMesh), + OBJECT(/*model*/ MODEL_LEVEL_GEOMETRY_0E, /*pos*/ -5115, 300, -3200, /*angle*/ 0, 90, 0, /*bhvParam*/ 0, /*bhv*/ bhvLLLHexagonalMesh), RETURN(), }; static const LevelScript script_func_local_2[] = { - OBJECT(/*model*/ MODEL_LLL_DRAWBRIDGE_PART, /*pos*/ -1919, 307, 3648, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvLllDrawbridgeSpawner), - OBJECT(/*model*/ MODEL_LLL_ROTATING_BLOCK_FIRE_BARS, /*pos*/ -5119, 307, -4095, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvLllRotatingBlockWithFireBars), - OBJECT(/*model*/ MODEL_LLL_ROTATING_HEXAGONAL_RING, /*pos*/ 0, 0, 0, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvLllRotatingHexagonalRing), - OBJECT(/*model*/ MODEL_LLL_SINKING_RECTANGULAR_PLATFORM, /*pos*/ 3968, 0, 1408, /*angle*/ 0, 90, 0, /*behParam*/ 0x00000000, /*beh*/ bhvLllSinkingRectangularPlatform), - OBJECT(/*model*/ MODEL_LLL_SINKING_RECTANGULAR_PLATFORM, /*pos*/ -5759, 0, 3072, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvLllSinkingRectangularPlatform), - OBJECT(/*model*/ MODEL_LLL_SINKING_RECTANGULAR_PLATFORM, /*pos*/ 2816, 0, 512, /*angle*/ 0, 90, 0, /*behParam*/ 0x00000000, /*beh*/ bhvLllSinkingRectangularPlatform), - OBJECT(/*model*/ MODEL_LLL_SINKING_RECTANGULAR_PLATFORM, /*pos*/ -1791, 0, -4095, /*angle*/ 0, 90, 0, /*behParam*/ 0x00000000, /*beh*/ bhvLllSinkingRectangularPlatform), - OBJECT(/*model*/ MODEL_LLL_SINKING_SQUARE_PLATFORMS, /*pos*/ 3840, 0, -3199, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvLllSinkingSquarePlatforms), - OBJECT(/*model*/ MODEL_LLL_TILTING_SQUARE_PLATFORM, /*pos*/ 922, -153, 2150, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvLllTiltingInvertedPyramid), - OBJECT(/*model*/ MODEL_LLL_TILTING_SQUARE_PLATFORM, /*pos*/ 1741, -153, 1741, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvLllTiltingInvertedPyramid), - OBJECT(/*model*/ MODEL_LLL_TILTING_SQUARE_PLATFORM, /*pos*/ 1741, -153, 2560, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvLllTiltingInvertedPyramid), - OBJECT(/*model*/ MODEL_LLL_TILTING_SQUARE_PLATFORM, /*pos*/ 2099, -153, -306, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvLllTiltingInvertedPyramid), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -5119, 102, 1024, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvLllBowserPuzzle), + OBJECT(/*model*/ MODEL_LLL_DRAWBRIDGE_PART, /*pos*/ -1919, 307, 3648, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvLLLDrawbridgeSpawner), + OBJECT(/*model*/ MODEL_LLL_ROTATING_BLOCK_FIRE_BARS, /*pos*/ -5119, 307, -4095, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvLLLRotatingBlockWithFireBars), + OBJECT(/*model*/ MODEL_LLL_ROTATING_HEXAGONAL_RING, /*pos*/ 0, 0, 0, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvLLLRotatingHexagonalRing), + OBJECT(/*model*/ MODEL_LLL_SINKING_RECTANGULAR_PLATFORM, /*pos*/ 3968, 0, 1408, /*angle*/ 0, 90, 0, /*bhvParam*/ 0, /*bhv*/ bhvLLLSinkingRectangularPlatform), + OBJECT(/*model*/ MODEL_LLL_SINKING_RECTANGULAR_PLATFORM, /*pos*/ -5759, 0, 3072, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvLLLSinkingRectangularPlatform), + OBJECT(/*model*/ MODEL_LLL_SINKING_RECTANGULAR_PLATFORM, /*pos*/ 2816, 0, 512, /*angle*/ 0, 90, 0, /*bhvParam*/ 0, /*bhv*/ bhvLLLSinkingRectangularPlatform), + OBJECT(/*model*/ MODEL_LLL_SINKING_RECTANGULAR_PLATFORM, /*pos*/ -1791, 0, -4095, /*angle*/ 0, 90, 0, /*bhvParam*/ 0, /*bhv*/ bhvLLLSinkingRectangularPlatform), + OBJECT(/*model*/ MODEL_LLL_SINKING_SQUARE_PLATFORMS, /*pos*/ 3840, 0, -3199, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvLLLSinkingSquarePlatforms), + OBJECT(/*model*/ MODEL_LLL_TILTING_SQUARE_PLATFORM, /*pos*/ 922, -153, 2150, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvLLLTiltingInvertedPyramid), + OBJECT(/*model*/ MODEL_LLL_TILTING_SQUARE_PLATFORM, /*pos*/ 1741, -153, 1741, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvLLLTiltingInvertedPyramid), + OBJECT(/*model*/ MODEL_LLL_TILTING_SQUARE_PLATFORM, /*pos*/ 1741, -153, 2560, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvLLLTiltingInvertedPyramid), + OBJECT(/*model*/ MODEL_LLL_TILTING_SQUARE_PLATFORM, /*pos*/ 2099, -153, -306, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvLLLTiltingInvertedPyramid), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ -5119, 102, 1024, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvLLLBowserPuzzle), RETURN(), }; static const LevelScript script_func_local_3[] = { - OBJECT(/*model*/ MODEL_LLL_MOVING_OCTAGONAL_MESH_PLATFORM, /*pos*/ 1124, 0, -4607, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvLllMovingOctagonalMeshPlatform), - OBJECT(/*model*/ MODEL_LLL_MOVING_OCTAGONAL_MESH_PLATFORM, /*pos*/ 7168, 0, 2432, /*angle*/ 0, 0, 0, /*behParam*/ 0x00010000, /*beh*/ bhvLllMovingOctagonalMeshPlatform), - OBJECT(/*model*/ MODEL_LLL_SINKING_ROCK_BLOCK, /*pos*/ 7168, 0, 7296, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvLllSinkingRockBlock), - OBJECT(/*model*/ MODEL_LLL_ROLLING_LOG, /*pos*/ 6144, 307, 6016, /*angle*/ 0, 90, 0, /*behParam*/ 0x00000000, /*beh*/ bhvLllRollingLog), - OBJECT(/*model*/ MODEL_LLL_ROTATING_HEXAGONAL_PLATFORM, /*pos*/ -5119, 0, -4095, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvLllRotatingHexagonalPlatform), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -3583, 0, -4095, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvLllFloatingWoodBridge), + OBJECT(/*model*/ MODEL_LLL_MOVING_OCTAGONAL_MESH_PLATFORM, /*pos*/ 1124, 0, -4607, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvLLLMovingOctagonalMeshPlatform), + OBJECT(/*model*/ MODEL_LLL_MOVING_OCTAGONAL_MESH_PLATFORM, /*pos*/ 7168, 0, 2432, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(0x01), /*bhv*/ bhvLLLMovingOctagonalMeshPlatform), + OBJECT(/*model*/ MODEL_LLL_SINKING_ROCK_BLOCK, /*pos*/ 7168, 0, 7296, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvLLLSinkingRockBlock), + OBJECT(/*model*/ MODEL_LLL_ROLLING_LOG, /*pos*/ 6144, 307, 6016, /*angle*/ 0, 90, 0, /*bhvParam*/ 0, /*bhv*/ bhvLLLRollingLog), + OBJECT(/*model*/ MODEL_LLL_ROTATING_HEXAGONAL_PLATFORM, /*pos*/ -5119, 0, -4095, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvLLLRotatingHexagonalPlatform), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ -3583, 0, -4095, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvLLLFloatingWoodBridge), RETURN(), }; static const LevelScript script_func_local_4[] = { - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -3199, 307, 3456, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvMrI), - OBJECT(/*model*/ MODEL_BULLY_BOSS, /*pos*/ 0, 307, -4385, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvBigBully), - OBJECT(/*model*/ MODEL_BULLY_BOSS, /*pos*/ 4046, 2234, -5521, /*angle*/ 0, 0, 0, /*behParam*/ 0x01000000, /*beh*/ bhvBigBullyWithMinions), - OBJECT(/*model*/ MODEL_BULLY, /*pos*/ -5119, 307, -2482, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvSmallBully), - OBJECT(/*model*/ MODEL_BULLY, /*pos*/ 0, 307, 3712, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvSmallBully), - OBJECT(/*model*/ MODEL_BULLY, /*pos*/ 6813, 307, 1613, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvSmallBully), - OBJECT(/*model*/ MODEL_BULLY, /*pos*/ 7168, 307, 998, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvSmallBully), - OBJECT(/*model*/ MODEL_BULLY, /*pos*/ -5130, 285, -1663, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvSmallBully), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 0, 200, -2048, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvFlamethrower), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 500, 2, 5000, /*angle*/ 0, 270, 0, /*behParam*/ 0x00000000, /*beh*/ bhvBouncingFireball), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -700, 2, 4500, /*angle*/ 0, 90, 0, /*behParam*/ 0x00000000, /*beh*/ bhvBouncingFireball), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -6300, 2, 2625, /*angle*/ 0, 90, 0, /*behParam*/ 0x00000000, /*beh*/ bhvBouncingFireball), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -3280, 2, -4854, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvBouncingFireball), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 5996, 2, -390, /*angle*/ 0, 315, 0, /*behParam*/ 0x00000000, /*beh*/ bhvBouncingFireball), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 5423, 2, -1991, /*angle*/ 0, 315, 0, /*behParam*/ 0x00000000, /*beh*/ bhvBouncingFireball), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 4921, 2, -1504, /*angle*/ 0, 90, 0, /*behParam*/ 0x00000000, /*beh*/ bhvBouncingFireball), - OBJECT_WITH_ACTS(/*model*/ MODEL_EXCLAMATION_BOX, /*pos*/ 1050, 550, 6200, /*angle*/ 0, 0, 0, /*behParam*/ 0x00030000, /*beh*/ bhvExclamationBox, /*acts*/ ACT_5 | ACT_6), + OBJECT (/*model*/ MODEL_NONE, /*pos*/ -3199, 307, 3456, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvMrI), + OBJECT (/*model*/ MODEL_BULLY_BOSS, /*pos*/ 0, 307, -4385, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(STAR_INDEX_ACT_1), /*bhv*/ bhvBigBully), + OBJECT (/*model*/ MODEL_BULLY_BOSS, /*pos*/ 4046, 2234, -5521, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(STAR_INDEX_ACT_2), /*bhv*/ bhvBigBullyWithMinions), + OBJECT (/*model*/ MODEL_BULLY, /*pos*/ -5119, 307, -2482, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvSmallBully), + OBJECT (/*model*/ MODEL_BULLY, /*pos*/ 0, 307, 3712, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvSmallBully), + OBJECT (/*model*/ MODEL_BULLY, /*pos*/ 6813, 307, 1613, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvSmallBully), + OBJECT (/*model*/ MODEL_BULLY, /*pos*/ 7168, 307, 998, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvSmallBully), + OBJECT (/*model*/ MODEL_BULLY, /*pos*/ -5130, 285, -1663, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvSmallBully), + OBJECT (/*model*/ MODEL_NONE, /*pos*/ 0, 200, -2048, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvFlamethrower), + OBJECT (/*model*/ MODEL_NONE, /*pos*/ 500, 2, 5000, /*angle*/ 0, 270, 0, /*bhvParam*/ 0, /*bhv*/ bhvBouncingFireball), + OBJECT (/*model*/ MODEL_NONE, /*pos*/ -700, 2, 4500, /*angle*/ 0, 90, 0, /*bhvParam*/ 0, /*bhv*/ bhvBouncingFireball), + OBJECT (/*model*/ MODEL_NONE, /*pos*/ -6300, 2, 2625, /*angle*/ 0, 90, 0, /*bhvParam*/ 0, /*bhv*/ bhvBouncingFireball), + OBJECT (/*model*/ MODEL_NONE, /*pos*/ -3280, 2, -4854, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvBouncingFireball), + OBJECT (/*model*/ MODEL_NONE, /*pos*/ 5996, 2, -390, /*angle*/ 0, 315, 0, /*bhvParam*/ 0, /*bhv*/ bhvBouncingFireball), + OBJECT (/*model*/ MODEL_NONE, /*pos*/ 5423, 2, -1991, /*angle*/ 0, 315, 0, /*bhvParam*/ 0, /*bhv*/ bhvBouncingFireball), + OBJECT (/*model*/ MODEL_NONE, /*pos*/ 4921, 2, -1504, /*angle*/ 0, 90, 0, /*bhvParam*/ 0, /*bhv*/ bhvBouncingFireball), + OBJECT_WITH_ACTS(/*model*/ MODEL_EXCLAMATION_BOX, /*pos*/ 1050, 550, 6200, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(EXCLAMATION_BOX_BP_KOOPA_SHELL), /*bhv*/ bhvExclamationBox, /*acts*/ ACT_5 | ACT_6), RETURN(), }; static const LevelScript script_func_local_5[] = { - OBJECT_WITH_ACTS(/*model*/ MODEL_NONE, /*pos*/ -4400, 350, 250, /*angle*/ 0, 0, 0, /*behParam*/ 0x02000000, /*beh*/ bhvHiddenRedCoinStar, /*acts*/ ALL_ACTS), - OBJECT_WITH_ACTS(/*model*/ MODEL_STAR, /*pos*/ 3100, 400, 7900, /*angle*/ 0, 0, 0, /*behParam*/ 0x03000000, /*beh*/ bhvStar, /*acts*/ ALL_ACTS), + OBJECT_WITH_ACTS(/*model*/ MODEL_NONE, /*pos*/ -4400, 350, 250, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(STAR_INDEX_ACT_3), /*bhv*/ bhvHiddenRedCoinStar, /*acts*/ ALL_ACTS), + OBJECT_WITH_ACTS(/*model*/ MODEL_STAR, /*pos*/ 3100, 400, 7900, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(STAR_INDEX_ACT_4), /*bhv*/ bhvStar, /*acts*/ ALL_ACTS), RETURN(), }; static const LevelScript script_func_local_6[] = { - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 728, 2606, -2754, /*angle*/ 0, 0, 0, /*behParam*/ 0x00380000, /*beh*/ bhvPoleGrabbing), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 1043, 2972, -2679, /*angle*/ 0, 0, 0, /*behParam*/ 0x004E0000, /*beh*/ bhvPoleGrabbing), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 1078, 3078, -2269, /*angle*/ 0, 0, 0, /*behParam*/ 0x00660000, /*beh*/ bhvPoleGrabbing), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 1413, 3222, -2190, /*angle*/ 0, 0, 0, /*behParam*/ 0x00520000, /*beh*/ bhvPoleGrabbing), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 783, 1126, -47, /*angle*/ 0, 0, 0, /*behParam*/ 0x00660000, /*beh*/ bhvPoleGrabbing), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 662, 2150, 708, /*angle*/ 0, 0, 0, /*behParam*/ 0x00660000, /*beh*/ bhvPoleGrabbing), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 2943, 476, 10, /*angle*/ 0, 270, 0, /*behParam*/ 0x00020000, /*beh*/ bhvFlamethrower), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -2759, 2350, -1108, /*angle*/ 0, 60, 0, /*behParam*/ 0x00020000, /*beh*/ bhvFlamethrower), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -2472, 2350, -1605, /*angle*/ 0, 60, 0, /*behParam*/ 0x00020000, /*beh*/ bhvFlamethrower), - OBJECT(/*model*/ MODEL_LLL_VOLCANO_FALLING_TRAP, /*pos*/ -485, 1203, 2933, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvLllVolcanoFallingTrap), - OBJECT(/*model*/ MODEL_LLL_ROTATING_BLOCK_FIRE_BARS, /*pos*/ 417, 2150, 583, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvLllRotatingBlockWithFireBars), - OBJECT(/*model*/ MODEL_CHECKERBOARD_PLATFORM, /*pos*/ -764, 0, 1664, /*angle*/ 0, 180, 0, /*behParam*/ 0x08A50000, /*beh*/ bhvPlatformOnTrack), - OBJECT(/*model*/ MODEL_CHECKERBOARD_PLATFORM, /*pos*/ 184, 980, -1366, /*angle*/ 0, 180, 0, /*behParam*/ 0x08A60000, /*beh*/ bhvPlatformOnTrack), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -26, 103, -2649, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvVolcanoSoundLoop), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 728, 2606, -2754, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(56), /*bhv*/ bhvPoleGrabbing), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 1043, 2972, -2679, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(78), /*bhv*/ bhvPoleGrabbing), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 1078, 3078, -2269, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(102), /*bhv*/ bhvPoleGrabbing), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 1413, 3222, -2190, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(82), /*bhv*/ bhvPoleGrabbing), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 783, 1126, -47, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(102), /*bhv*/ bhvPoleGrabbing), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 662, 2150, 708, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(102), /*bhv*/ bhvPoleGrabbing), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 2943, 476, 10, /*angle*/ 0, 270, 0, /*bhvParam*/ BPARAM2(0x02), /*bhv*/ bhvFlamethrower), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ -2759, 2350, -1108, /*angle*/ 0, 60, 0, /*bhvParam*/ BPARAM2(0x02), /*bhv*/ bhvFlamethrower), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ -2472, 2350, -1605, /*angle*/ 0, 60, 0, /*bhvParam*/ BPARAM2(0x02), /*bhv*/ bhvFlamethrower), + OBJECT(/*model*/ MODEL_LLL_VOLCANO_FALLING_TRAP, /*pos*/ -485, 1203, 2933, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvLLLVolcanoFallingTrap), + OBJECT(/*model*/ MODEL_LLL_ROTATING_BLOCK_FIRE_BARS, /*pos*/ 417, 2150, 583, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvLLLRotatingBlockWithFireBars), + OBJECT(/*model*/ MODEL_CHECKERBOARD_PLATFORM, /*pos*/ -764, 0, 1664, /*angle*/ 0, 180, 0, /*bhvParam*/ BPARAM1(0x08) | BPARAM2(0xA5), /*bhv*/ bhvPlatformOnTrack), + OBJECT(/*model*/ MODEL_CHECKERBOARD_PLATFORM, /*pos*/ 184, 980, -1366, /*angle*/ 0, 180, 0, /*bhvParam*/ BPARAM1(0x08) | BPARAM2(0xA6), /*bhv*/ bhvPlatformOnTrack), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ -26, 103, -2649, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvVolcanoSoundLoop), RETURN(), }; static const LevelScript script_func_local_7[] = { - OBJECT_WITH_ACTS(/*model*/ MODEL_STAR, /*pos*/ 2523, 3850, -901, /*angle*/ 0, 0, 0, /*behParam*/ 0x04000000, /*beh*/ bhvStar, /*acts*/ ALL_ACTS), - OBJECT_WITH_ACTS(/*model*/ MODEL_STAR, /*pos*/ 1800, 3400, 1450, /*angle*/ 0, 0, 0, /*behParam*/ 0x05000000, /*beh*/ bhvStar, /*acts*/ ALL_ACTS), + OBJECT_WITH_ACTS(/*model*/ MODEL_STAR, /*pos*/ 2523, 3850, -901, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(STAR_INDEX_ACT_5), /*bhv*/ bhvStar, /*acts*/ ALL_ACTS), + OBJECT_WITH_ACTS(/*model*/ MODEL_STAR, /*pos*/ 1800, 3400, 1450, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(STAR_INDEX_ACT_6), /*bhv*/ bhvStar, /*acts*/ ALL_ACTS), RETURN(), }; const LevelScript level_lll_entry[] = { INIT_LEVEL(), - LOAD_MIO0( /*seg*/ 0x07, _lll_segment_7SegmentRomStart, _lll_segment_7SegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x07, _lll_segment_7SegmentRomStart, _lll_segment_7SegmentRomEnd), LOAD_MIO0_TEXTURE(/*seg*/ 0x09, _fire_mio0SegmentRomStart, _fire_mio0SegmentRomEnd), - LOAD_MIO0( /*seg*/ 0x0A, _bitfs_skybox_mio0SegmentRomStart, _bitfs_skybox_mio0SegmentRomEnd), - LOAD_MIO0( /*seg*/ 0x0B, _effect_mio0SegmentRomStart, _effect_mio0SegmentRomEnd), - LOAD_MIO0( /*seg*/ 0x05, _group2_mio0SegmentRomStart, _group2_mio0SegmentRomEnd), - LOAD_RAW( /*seg*/ 0x0C, _group2_geoSegmentRomStart, _group2_geoSegmentRomEnd), - LOAD_MIO0( /*seg*/ 0x06, _group17_mio0SegmentRomStart, _group17_mio0SegmentRomEnd), - LOAD_RAW( /*seg*/ 0x0D, _group17_geoSegmentRomStart, _group17_geoSegmentRomEnd), - LOAD_MIO0( /*seg*/ 0x08, _common0_mio0SegmentRomStart, _common0_mio0SegmentRomEnd), - LOAD_RAW( /*seg*/ 0x0F, _common0_geoSegmentRomStart, _common0_geoSegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x0A, _bitfs_skybox_mio0SegmentRomStart, _bitfs_skybox_mio0SegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x0B, _effect_mio0SegmentRomStart, _effect_mio0SegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x05, _group2_mio0SegmentRomStart, _group2_mio0SegmentRomEnd), + LOAD_RAW (/*seg*/ 0x0C, _group2_geoSegmentRomStart, _group2_geoSegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x06, _group17_mio0SegmentRomStart, _group17_mio0SegmentRomEnd), + LOAD_RAW (/*seg*/ 0x0D, _group17_geoSegmentRomStart, _group17_geoSegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x08, _common0_mio0SegmentRomStart, _common0_mio0SegmentRomEnd), + LOAD_RAW (/*seg*/ 0x0F, _common0_geoSegmentRomStart, _common0_geoSegmentRomEnd), ALLOC_LEVEL_POOL(), - MARIO(/*model*/ MODEL_MARIO, /*behParam*/ 0x00000001, /*beh*/ bhvMario), + MARIO(/*model*/ MODEL_MARIO, /*bhvParam*/ BPARAM4(0x01), /*bhv*/ bhvMario), JUMP_LINK(script_func_global_1), JUMP_LINK(script_func_global_3), JUMP_LINK(script_func_global_18), @@ -175,16 +175,16 @@ const LevelScript level_lll_entry[] = { LOAD_MODEL_FROM_GEO(MODEL_LLL_VOLCANO_FALLING_TRAP, lll_geo_000EA8), AREA(/*index*/ 1, lll_geo_000E00), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -3839, 1154, 6272, /*angle*/ 0, 90, 0, /*behParam*/ 0x000A0000, /*beh*/ bhvSpinAirborneWarp), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 0, 105, 0, /*angle*/ 0, 0, 0, /*behParam*/ 0x190B0000, /*beh*/ bhvWarp), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -3200, 11, 3456, /*angle*/ 0, -100, 0, /*behParam*/ 0x000C0000, /*beh*/ bhvFadingWarp), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -5888, 154, 6656, /*angle*/ 0, 100, 0, /*behParam*/ 0x000D0000, /*beh*/ bhvFadingWarp), - WARP_NODE(/*id*/ 0x0A, /*destLevel*/ LEVEL_LLL, /*destArea*/ 0x01, /*destNode*/ 0x0A, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0x0B, /*destLevel*/ LEVEL_LLL, /*destArea*/ 0x02, /*destNode*/ 0x0A, /*flags*/ WARP_CHECKPOINT), - WARP_NODE(/*id*/ 0x0C, /*destLevel*/ LEVEL_LLL, /*destArea*/ 0x01, /*destNode*/ 0x0D, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0x0D, /*destLevel*/ LEVEL_LLL, /*destArea*/ 0x01, /*destNode*/ 0x0C, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0xF0, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x03, /*destNode*/ 0x32, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0xF1, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x03, /*destNode*/ 0x64, /*flags*/ WARP_NO_CHECKPOINT), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ -3839, 1154, 6272, /*angle*/ 0, 90, 0, /*bhvParam*/ BPARAM2(WARP_NODE_0A), /*bhv*/ bhvSpinAirborneWarp), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 0, 105, 0, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(25) | BPARAM2(WARP_NODE_0B), /*bhv*/ bhvWarp), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ -3200, 11, 3456, /*angle*/ 0, -100, 0, /*bhvParam*/ BPARAM2(WARP_NODE_0C), /*bhv*/ bhvFadingWarp), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ -5888, 154, 6656, /*angle*/ 0, 100, 0, /*bhvParam*/ BPARAM2(WARP_NODE_0D), /*bhv*/ bhvFadingWarp), + WARP_NODE(/*id*/ WARP_NODE_0A, /*destLevel*/ LEVEL_LLL, /*destArea*/ 1, /*destNode*/ WARP_NODE_0A, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_0B, /*destLevel*/ LEVEL_LLL, /*destArea*/ 2, /*destNode*/ WARP_NODE_0A, /*flags*/ WARP_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_0C, /*destLevel*/ LEVEL_LLL, /*destArea*/ 1, /*destNode*/ WARP_NODE_0D, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_0D, /*destLevel*/ LEVEL_LLL, /*destArea*/ 1, /*destNode*/ WARP_NODE_0C, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_SUCCESS, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 3, /*destNode*/ WARP_NODE_32, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_DEATH, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 3, /*destNode*/ WARP_NODE_64, /*flags*/ WARP_NO_CHECKPOINT), JUMP_LINK(script_func_local_1), JUMP_LINK(script_func_local_2), JUMP_LINK(script_func_local_3), @@ -198,10 +198,10 @@ const LevelScript level_lll_entry[] = { END_AREA(), AREA(/*index*/ 2, lll_geo_000EC0), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -955, 1103, -1029, /*angle*/ 0, 118, 0, /*behParam*/ 0x000A0000, /*beh*/ bhvAirborneWarp), - WARP_NODE(/*id*/ 0x0A, /*destLevel*/ LEVEL_LLL, /*destArea*/ 0x02, /*destNode*/ 0x0A, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0xF0, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x03, /*destNode*/ 0x32, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0xF1, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x03, /*destNode*/ 0x64, /*flags*/ WARP_NO_CHECKPOINT), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ -955, 1103, -1029, /*angle*/ 0, 118, 0, /*bhvParam*/ BPARAM2(WARP_NODE_0A), /*bhv*/ bhvAirborneWarp), + WARP_NODE(/*id*/ WARP_NODE_0A, /*destLevel*/ LEVEL_LLL, /*destArea*/ 2, /*destNode*/ WARP_NODE_0A, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_SUCCESS, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 3, /*destNode*/ WARP_NODE_32, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_DEATH, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 3, /*destNode*/ WARP_NODE_64, /*flags*/ WARP_NO_CHECKPOINT), JUMP_LINK(script_func_local_6), JUMP_LINK(script_func_local_7), TERRAIN(/*terrainData*/ lll_seg7_area_2_collision), diff --git a/levels/lll/sinking_rectangular_platform/geo.inc.c b/levels/lll/sinking_rectangular_platform/geo.inc.c index 089c47a0..5a9f06ae 100644 --- a/levels/lll/sinking_rectangular_platform/geo.inc.c +++ b/levels/lll/sinking_rectangular_platform/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000BC8 const GeoLayout lll_geo_000BC8[] = { - GEO_CULLING_RADIUS(1400), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, lll_seg7_dl_07019C08), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(1400), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, lll_seg7_dl_07019C08), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/lll/sinking_rock_block/geo.inc.c b/levels/lll/sinking_rock_block/geo.inc.c index b43d2f76..1ad3d02b 100644 --- a/levels/lll/sinking_rock_block/geo.inc.c +++ b/levels/lll/sinking_rock_block/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000DD0 const GeoLayout lll_geo_000DD0[] = { - GEO_CULLING_RADIUS(600), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, lll_seg7_dl_0701A878), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(600), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, lll_seg7_dl_0701A878), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/lll/sinking_square_platform/geo.inc.c b/levels/lll/sinking_square_platform/geo.inc.c index b4880439..11645abf 100644 --- a/levels/lll/sinking_square_platform/geo.inc.c +++ b/levels/lll/sinking_square_platform/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000BE0 const GeoLayout lll_geo_000BE0[] = { - GEO_CULLING_RADIUS(1800), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, lll_seg7_dl_0701A010), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(1800), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, lll_seg7_dl_0701A010), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/lll/tilting_square_platform/geo.inc.c b/levels/lll/tilting_square_platform/geo.inc.c index f35d9bbc..df346144 100644 --- a/levels/lll/tilting_square_platform/geo.inc.c +++ b/levels/lll/tilting_square_platform/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000BF8 const GeoLayout lll_geo_000BF8[] = { - GEO_CULLING_RADIUS(800), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, lll_seg7_dl_0701A1F0), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(800), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, lll_seg7_dl_0701A1F0), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/lll/volcano_falling_trap/geo.inc.c b/levels/lll/volcano_falling_trap/geo.inc.c index e97a94b4..723a1afd 100644 --- a/levels/lll/volcano_falling_trap/geo.inc.c +++ b/levels/lll/volcano_falling_trap/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000EA8 const GeoLayout lll_geo_000EA8[] = { - GEO_CULLING_RADIUS(900), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, lll_seg7_dl_07025EC0), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(900), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, lll_seg7_dl_07025EC0), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/lll/wooden_float_large/geo.inc.c b/levels/lll/wooden_float_large/geo.inc.c index 0b718c1e..79624c79 100644 --- a/levels/lll/wooden_float_large/geo.inc.c +++ b/levels/lll/wooden_float_large/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000B68 const GeoLayout lll_geo_000B68[] = { - GEO_CULLING_RADIUS(1100), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, lll_seg7_dl_07018EF8), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(1100), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, lll_seg7_dl_07018EF8), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/lll/wooden_float_small/geo.inc.c b/levels/lll/wooden_float_small/geo.inc.c index e82d3464..37443cdb 100644 --- a/levels/lll/wooden_float_small/geo.inc.c +++ b/levels/lll/wooden_float_small/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000B50 const GeoLayout lll_geo_000B50[] = { - GEO_CULLING_RADIUS(700), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, lll_seg7_dl_07018C90), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(700), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, lll_seg7_dl_07018C90), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/menu/geo.c b/levels/menu/geo.c index 466b85d4..d4d8b4b5 100644 --- a/levels/menu/geo.c +++ b/levels/menu/geo.c @@ -17,182 +17,182 @@ // 0x0E0001D0 const GeoLayout geo_menu_mario_save_button[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_SCALE(0x00, 524288), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, dl_menu_mario_save_button_base), - GEO_DISPLAY_LIST(LAYER_OPAQUE, dl_menu_save_button_back), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_SCALE(0x00, 524288), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, dl_menu_mario_save_button_base), + GEO_DISPLAY_LIST(LAYER_OPAQUE, dl_menu_save_button_back), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; // 0x0E000200 const GeoLayout geo_menu_mario_save_button_fade[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_SCALE(0x00, 524288), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, dl_menu_mario_save_button_base), - GEO_DISPLAY_LIST(LAYER_OPAQUE, dl_menu_save_button_fade_back), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_SCALE(0x00, 524288), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, dl_menu_mario_save_button_base), + GEO_DISPLAY_LIST(LAYER_OPAQUE, dl_menu_save_button_fade_back), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; // 0x0E000230 const GeoLayout geo_menu_mario_new_button[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_SCALE(0x00, 524288), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, dl_menu_mario_new_button_base), - GEO_DISPLAY_LIST(LAYER_OPAQUE, dl_menu_save_button_back), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_SCALE(0x00, 524288), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, dl_menu_mario_new_button_base), + GEO_DISPLAY_LIST(LAYER_OPAQUE, dl_menu_save_button_back), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; // 0x0E000260 const GeoLayout geo_menu_mario_new_button_fade[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_SCALE(0x00, 524288), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, dl_menu_mario_new_button_base), - GEO_DISPLAY_LIST(LAYER_OPAQUE, dl_menu_save_button_fade_back), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_SCALE(0x00, 524288), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, dl_menu_mario_new_button_base), + GEO_DISPLAY_LIST(LAYER_OPAQUE, dl_menu_save_button_fade_back), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; // 0x0E000290 const GeoLayout geo_menu_erase_button[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_SCALE(0x00, 524288), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, dl_menu_erase_button), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_SCALE(0x00, 524288), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, dl_menu_erase_button), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; // 0x0E0002B8 const GeoLayout geo_menu_copy_button[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_SCALE(0x00, 524288), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, dl_menu_copy_button), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_SCALE(0x00, 524288), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, dl_menu_copy_button), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; // 0x0E0002E0 const GeoLayout geo_menu_file_button[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_SCALE(0x00, 524288), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, dl_menu_file_button), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_SCALE(0x00, 524288), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, dl_menu_file_button), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; // 0x0E000308 const GeoLayout geo_menu_score_button[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_SCALE(0x00, 524288), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, dl_menu_score_button), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_SCALE(0x00, 524288), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, dl_menu_score_button), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; // 0x0E000330 const GeoLayout geo_menu_sound_button[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_SCALE(0x00, 524288), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, dl_menu_sound_button), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_SCALE(0x00, 524288), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, dl_menu_sound_button), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; // 0x0E000358 const GeoLayout geo_menu_generic_button[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_SCALE(0x00, 524288), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, dl_menu_generic_button), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_SCALE(0x00, 524288), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, dl_menu_generic_button), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; // 0x0E000380 const GeoLayout geo_menu_file_select_strings_and_menu_cursor[] = { - GEO_NODE_SCREEN_AREA(10, SCREEN_WIDTH/2, SCREEN_HEIGHT/2, SCREEN_WIDTH/2, SCREEN_HEIGHT/2), - GEO_OPEN_NODE(), - GEO_ZBUFFER(0), - GEO_OPEN_NODE(), - GEO_NODE_ORTHO(100), - GEO_OPEN_NODE(), - GEO_BACKGROUND_COLOR(0x0001), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ZBUFFER(1), - GEO_OPEN_NODE(), - GEO_CAMERA_FRUSTUM(45, 100, 25000), - GEO_OPEN_NODE(), - GEO_CAMERA(0, 0, 0, 1000, 0, 0, 0, 0x00000000), + GEO_NODE_SCREEN_AREA(10, SCREEN_WIDTH/2, SCREEN_HEIGHT/2, SCREEN_WIDTH/2, SCREEN_HEIGHT/2), + GEO_OPEN_NODE(), + GEO_ZBUFFER(0), + GEO_OPEN_NODE(), + GEO_NODE_ORTHO(100), GEO_OPEN_NODE(), - GEO_RENDER_OBJ(), + GEO_BACKGROUND_COLOR(0x0001), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ZBUFFER(0), - GEO_OPEN_NODE(), - GEO_ASM(0, geo_file_select_strings_and_menu_cursor), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CLOSE_NODE(), + GEO_ZBUFFER(1), + GEO_OPEN_NODE(), + GEO_CAMERA_FRUSTUM(45, 100, 25000), + GEO_OPEN_NODE(), + GEO_CAMERA(0, 0, 0, 1000, 0, 0, 0, 0x00000000), + GEO_OPEN_NODE(), + GEO_RENDER_OBJ(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ZBUFFER(0), + GEO_OPEN_NODE(), + GEO_ASM(0, geo_file_select_strings_and_menu_cursor), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; // 0x0E000408 const GeoLayout geo_menu_act_selector_strings[] = { - GEO_NODE_SCREEN_AREA(10, SCREEN_WIDTH/2, SCREEN_HEIGHT/2, SCREEN_WIDTH/2, SCREEN_HEIGHT/2), - GEO_OPEN_NODE(), - GEO_ZBUFFER(0), - GEO_OPEN_NODE(), - GEO_NODE_ORTHO(100), - GEO_OPEN_NODE(), - GEO_BACKGROUND_COLOR(0xFFFF), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ZBUFFER(1), - GEO_OPEN_NODE(), - GEO_CAMERA_FRUSTUM(45, 100, 25000), - GEO_OPEN_NODE(), - GEO_CAMERA(0, 0, 0, 1000, 0, 0, 0, 0x00000000), + GEO_NODE_SCREEN_AREA(10, SCREEN_WIDTH/2, SCREEN_HEIGHT/2, SCREEN_WIDTH/2, SCREEN_HEIGHT/2), + GEO_OPEN_NODE(), + GEO_ZBUFFER(0), + GEO_OPEN_NODE(), + GEO_NODE_ORTHO(100), GEO_OPEN_NODE(), - GEO_RENDER_OBJ(), + GEO_BACKGROUND_COLOR(0xFFFF), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ZBUFFER(0), - GEO_OPEN_NODE(), - GEO_ASM(0, geo_act_selector_strings), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CLOSE_NODE(), + GEO_ZBUFFER(1), + GEO_OPEN_NODE(), + GEO_CAMERA_FRUSTUM(45, 100, 25000), + GEO_OPEN_NODE(), + GEO_CAMERA(0, 0, 0, 1000, 0, 0, 0, 0x00000000), + GEO_OPEN_NODE(), + GEO_RENDER_OBJ(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ZBUFFER(0), + GEO_OPEN_NODE(), + GEO_ASM(0, geo_act_selector_strings), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/menu/leveldata.c b/levels/menu/leveldata.c index d5b3e511..383e5e56 100644 --- a/levels/menu/leveldata.c +++ b/levels/menu/leveldata.c @@ -1741,6 +1741,18 @@ ALIGNED8 static const Texture texture_menu_course_lower[] = { #include "levels/menu/main_menu_seg7_eu.0EDA0.rgba16.inc.c" }; +#elif defined(VERSION_CN) + +// 0x070BCE0 - 0x070CCE0 +ALIGNED8 static const Texture texture_menu_course_upper[] = { +#include "levels/menu/main_menu_seg7_cn.0BCE0.rgba16.inc.c" +}; + +// 0x0700CCE0 - 0x0700DCE0 +ALIGNED8 static const Texture texture_menu_course_lower[] = { +#include "levels/menu/main_menu_seg7_cn.0CCE0.rgba16.inc.c" +}; + #else // 0x0700D1A8 - 0x0700E1A8 diff --git a/levels/menu/script.c b/levels/menu/script.c index 25c31f00..14b18e9f 100644 --- a/levels/menu/script.c +++ b/levels/menu/script.c @@ -22,7 +22,7 @@ const LevelScript level_main_menu_entry_1[] = { INIT_LEVEL(), FIXED_LOAD(/*loadAddr*/ _goddardSegmentStart, /*romStart*/ _goddardSegmentRomStart, /*romEnd*/ _goddardSegmentRomEnd), LOAD_MIO0(/*seg*/ 0x07, _menu_segment_7SegmentRomStart, _menu_segment_7SegmentRomEnd), - LOAD_RAW(/*seg*/ 0x13, _behaviorSegmentRomStart, _behaviorSegmentRomEnd), + LOAD_RAW (/*seg*/ 0x13, _behaviorSegmentRomStart, _behaviorSegmentRomEnd), ALLOC_LEVEL_POOL(), LOAD_MODEL_FROM_GEO(MODEL_MAIN_MENU_MARIO_SAVE_BUTTON, geo_menu_mario_save_button), LOAD_MODEL_FROM_GEO(MODEL_MAIN_MENU_RED_ERASE_BUTTON, geo_menu_erase_button), @@ -36,8 +36,8 @@ const LevelScript level_main_menu_entry_1[] = { LOAD_MODEL_FROM_GEO(MODEL_MAIN_MENU_GENERIC_BUTTON, geo_menu_generic_button), AREA(/*index*/ 1, geo_menu_file_select_strings_and_menu_cursor), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 0, 0, -19000, /*angle*/ 0, 0, 0, /*behParam*/ 0x04000000, /*beh*/ bhvMenuButtonManager), - OBJECT(/*model*/ MODEL_MAIN_MENU_YELLOW_FILE_BUTTON, /*pos*/ 0, 0, -19000, /*angle*/ 0, 0, 0, /*behParam*/ 0x04000000, /*beh*/ bhvYellowBackgroundInMenu), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 0, 0, -19000, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(0x04), /*bhv*/ bhvMenuButtonManager), + OBJECT(/*model*/ MODEL_MAIN_MENU_YELLOW_FILE_BUTTON, /*pos*/ 0, 0, -19000, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(0x04), /*bhv*/ bhvYellowBackgroundInMenu), TERRAIN(/*terrainData*/ main_menu_seg7_collision), END_AREA(), @@ -66,7 +66,7 @@ const LevelScript level_main_menu_entry_2[] = { /*13*/ ALLOC_LEVEL_POOL(), /*14*/ AREA(/*index*/ 2, geo_menu_act_selector_strings), - /*16*/ OBJECT(/*model*/ MODEL_NONE, /*pos*/ 0, -100, 0, /*angle*/ 0, 0, 0, /*behParam*/ 0x04000000, /*beh*/ bhvActSelector), + /*16*/ OBJECT(/*model*/ MODEL_NONE, /*pos*/ 0, -100, 0, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(0x04), /*bhv*/ bhvActSelector), /*22*/ TERRAIN(/*terrainData*/ main_menu_seg7_collision), /*24*/ END_AREA(), diff --git a/levels/pss/areas/1/geo.inc.c b/levels/pss/areas/1/geo.inc.c index bf3c5b31..89f45f43 100644 --- a/levels/pss/areas/1/geo.inc.c +++ b/levels/pss/areas/1/geo.inc.c @@ -1,32 +1,32 @@ // 0x0E000100 const GeoLayout pss_geo_000100[] = { - GEO_NODE_SCREEN_AREA(10, SCREEN_WIDTH/2, SCREEN_HEIGHT/2, SCREEN_WIDTH/2, SCREEN_HEIGHT/2), - GEO_OPEN_NODE(), - GEO_ZBUFFER(0), - GEO_OPEN_NODE(), - GEO_NODE_ORTHO(100), - GEO_OPEN_NODE(), - GEO_BACKGROUND_COLOR(0x0001), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ZBUFFER(1), - GEO_OPEN_NODE(), - GEO_CAMERA_FRUSTUM_WITH_FUNC(45, 100, 12800, geo_camera_fov), - GEO_OPEN_NODE(), - GEO_CAMERA(9, 0, 2000, 6000, 0, 0, 0, geo_camera_main), + GEO_NODE_SCREEN_AREA(10, SCREEN_WIDTH/2, SCREEN_HEIGHT/2, SCREEN_WIDTH/2, SCREEN_HEIGHT/2), + GEO_OPEN_NODE(), + GEO_ZBUFFER(0), + GEO_OPEN_NODE(), + GEO_NODE_ORTHO(100), GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, pss_seg7_dl_0700A7C0), - GEO_DISPLAY_LIST(LAYER_OPAQUE, pss_seg7_dl_0700AFA8), - GEO_DISPLAY_LIST(LAYER_OPAQUE, pss_seg7_dl_0700B3F0), - GEO_DISPLAY_LIST(LAYER_OPAQUE, pss_seg7_dl_0700D338), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, pss_seg7_dl_0700DAD8), - GEO_DISPLAY_LIST(LAYER_OPAQUE, pss_seg7_dl_0700E2B0), - GEO_DISPLAY_LIST(LAYER_OPAQUE_DECAL, pss_seg7_dl_0700E3E8), - GEO_RENDER_OBJ(), - GEO_ASM(0, geo_envfx_main), + GEO_BACKGROUND_COLOR(0x0001), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CLOSE_NODE(), + GEO_ZBUFFER(1), + GEO_OPEN_NODE(), + GEO_CAMERA_FRUSTUM_WITH_FUNC(45, 100, 12800, geo_camera_fov), + GEO_OPEN_NODE(), + GEO_CAMERA(9, 0, 2000, 6000, 0, 0, 0, geo_camera_main), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, pss_seg7_dl_0700A7C0), + GEO_DISPLAY_LIST(LAYER_OPAQUE, pss_seg7_dl_0700AFA8), + GEO_DISPLAY_LIST(LAYER_OPAQUE, pss_seg7_dl_0700B3F0), + GEO_DISPLAY_LIST(LAYER_OPAQUE, pss_seg7_dl_0700D338), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, pss_seg7_dl_0700DAD8), + GEO_DISPLAY_LIST(LAYER_OPAQUE, pss_seg7_dl_0700E2B0), + GEO_DISPLAY_LIST(LAYER_OPAQUE_DECAL, pss_seg7_dl_0700E3E8), + GEO_RENDER_OBJ(), + GEO_ASM(0, geo_envfx_main), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/pss/areas/1/macro.inc.c b/levels/pss/areas/1/macro.inc.c index f45eab39..931e5fb3 100644 --- a/levels/pss/areas/1/macro.inc.c +++ b/levels/pss/areas/1/macro.inc.c @@ -1,45 +1,45 @@ // 0x07010F00 - 0x0701109C const MacroObject pss_seg7_macro_objs[] = { - MACRO_OBJECT(/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ -3233, 4688, -5600), - MACRO_OBJECT(/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ -5636, 4331, -5054), - MACRO_OBJECT(/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ -5980, 3453, 945), - MACRO_OBJECT(/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ -2870, 2837, 2300), - MACRO_OBJECT(/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ 3930, 274, 2425), - MACRO_OBJECT(/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ 5174, 61, 3200), - MACRO_OBJECT(/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ 5707, -128, 4565), - MACRO_OBJECT(/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ 5194, -310, 5845), - MACRO_OBJECT(/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ 3640, -543, 6450), - MACRO_OBJECT(/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ 2550, -700, 6050), - MACRO_OBJECT(/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ 1821, -921, 4616), - MACRO_OBJECT(/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ -20, -2542, -6304), - MACRO_OBJECT(/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ -1197, -2929, -4692), - MACRO_OBJECT(/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ -2565, -3268, -3525), - MACRO_OBJECT(/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ -4909, -3633, -4218), - MACRO_OBJECT(/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ -6290, -3937, -2545), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 90, /*pos*/ 3580, 6140, -5180, /*behParam*/ DIALOG_149), - MACRO_OBJECT(/*preset*/ macro_coin_line_horizontal, /*yaw*/ 90, /*pos*/ 3000, 6180, -5640), - MACRO_OBJECT(/*preset*/ macro_blue_coin_switch, /*yaw*/ 0, /*pos*/ 5423, 6140, -6540), - MACRO_OBJECT(/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ 780, 5613, -5600), - MACRO_OBJECT(/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ 2360, 5979, -5600), - MACRO_OBJECT(/*preset*/ macro_coin_line_horizontal, /*yaw*/ 0, /*pos*/ 1880, -1440, 60), - MACRO_OBJECT(/*preset*/ macro_coin_line_horizontal, /*yaw*/ 0, /*pos*/ 1860, -1760, -1720), - MACRO_OBJECT(/*preset*/ macro_coin_line_horizontal, /*yaw*/ 0, /*pos*/ 1860, -1200, 1680), - MACRO_OBJECT(/*preset*/ macro_hidden_1up_trigger, /*yaw*/ 0, /*pos*/ 1860, -1220, 1700), - MACRO_OBJECT(/*preset*/ macro_hidden_1up_trigger, /*yaw*/ 0, /*pos*/ 1880, -1460, 80), - MACRO_OBJECT(/*preset*/ macro_hidden_1up_trigger, /*yaw*/ 0, /*pos*/ 1860, -1820, -1680), - MACRO_OBJECT(/*preset*/ macro_hidden_1up_trigger, /*yaw*/ 0, /*pos*/ -6380, -4550, 6320), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_hidden_1up, /*yaw*/ 0, /*pos*/ -6380, -4500, 5980, /*behParam*/ 4), - MACRO_OBJECT(/*preset*/ macro_1up_sliding, /*yaw*/ 180, /*pos*/ 1847, -961, 3863), - MACRO_OBJECT(/*preset*/ macro_coin_line_horizontal, /*yaw*/ 90, /*pos*/ 260, 2580, 2280), - MACRO_OBJECT(/*preset*/ macro_coin_line_horizontal, /*yaw*/ 90, /*pos*/ -880, 2880, 2280), - MACRO_OBJECT(/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ -809, 5245, -5600), - MACRO_OBJECT(/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ -2409, 4877, -5600), - MACRO_OBJECT(/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ -6400, -4146, -590), - MACRO_OBJECT(/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ -6400, -4335, 1409), - MACRO_OBJECT(/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ -6400, -4530, 3481), - MACRO_OBJECT(/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ -4445, 4490, -5536), - MACRO_OBJECT(/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ -6263, 4150, -4009), - MACRO_OBJECT(/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ 1854, -2132, -4290), - MACRO_OBJECT(/*preset*/ macro_box_star_1, /*yaw*/ 0, /*pos*/ -6385, -4200, 5770), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ -3233, 4688, -5600), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ -5636, 4331, -5054), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ -5980, 3453, 945), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ -2870, 2837, 2300), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ 3930, 274, 2425), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ 5174, 61, 3200), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ 5707, -128, 4565), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ 5194, -310, 5845), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ 3640, -543, 6450), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ 2550, -700, 6050), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ 1821, -921, 4616), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ -20, -2542, -6304), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ -1197, -2929, -4692), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ -2565, -3268, -3525), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ -4909, -3633, -4218), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ -6290, -3937, -2545), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 90, /*pos*/ 3580, 6140, -5180, /*bhvParam*/ DIALOG_149), + MACRO_OBJECT (/*preset*/ macro_coin_line_horizontal, /*yaw*/ 90, /*pos*/ 3000, 6180, -5640), + MACRO_OBJECT (/*preset*/ macro_blue_coin_switch, /*yaw*/ 0, /*pos*/ 5423, 6140, -6540), + MACRO_OBJECT (/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ 780, 5613, -5600), + MACRO_OBJECT (/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ 2360, 5979, -5600), + MACRO_OBJECT (/*preset*/ macro_coin_line_horizontal, /*yaw*/ 0, /*pos*/ 1880, -1440, 60), + MACRO_OBJECT (/*preset*/ macro_coin_line_horizontal, /*yaw*/ 0, /*pos*/ 1860, -1760, -1720), + MACRO_OBJECT (/*preset*/ macro_coin_line_horizontal, /*yaw*/ 0, /*pos*/ 1860, -1200, 1680), + MACRO_OBJECT (/*preset*/ macro_hidden_1up_trigger, /*yaw*/ 0, /*pos*/ 1860, -1220, 1700), + MACRO_OBJECT (/*preset*/ macro_hidden_1up_trigger, /*yaw*/ 0, /*pos*/ 1880, -1460, 80), + MACRO_OBJECT (/*preset*/ macro_hidden_1up_trigger, /*yaw*/ 0, /*pos*/ 1860, -1820, -1680), + MACRO_OBJECT (/*preset*/ macro_hidden_1up_trigger, /*yaw*/ 0, /*pos*/ -6380, -4550, 6320), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_hidden_1up, /*yaw*/ 0, /*pos*/ -6380, -4500, 5980, /*bhvParam*/ 4), + MACRO_OBJECT (/*preset*/ macro_1up_sliding, /*yaw*/ 180, /*pos*/ 1847, -961, 3863), + MACRO_OBJECT (/*preset*/ macro_coin_line_horizontal, /*yaw*/ 90, /*pos*/ 260, 2580, 2280), + MACRO_OBJECT (/*preset*/ macro_coin_line_horizontal, /*yaw*/ 90, /*pos*/ -880, 2880, 2280), + MACRO_OBJECT (/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ -809, 5245, -5600), + MACRO_OBJECT (/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ -2409, 4877, -5600), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ -6400, -4146, -590), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ -6400, -4335, 1409), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ -6400, -4530, 3481), + MACRO_OBJECT (/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ -4445, 4490, -5536), + MACRO_OBJECT (/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ -6263, 4150, -4009), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ 1854, -2132, -4290), + MACRO_OBJECT (/*preset*/ macro_box_star_act_1, /*yaw*/ 0, /*pos*/ -6385, -4200, 5770), MACRO_OBJECT_END(), }; diff --git a/levels/pss/level.yaml b/levels/pss/level.yaml index 38d15cff..a63824e3 100644 --- a/levels/pss/level.yaml +++ b/levels/pss/level.yaml @@ -1,4 +1,4 @@ -# Princess's Secret Slide +# The Princess's Secret Slide short-name: pss full-name: The Princess's Secret Slide texture-file: ["/texture.inc.c"] diff --git a/levels/pss/leveldata.c b/levels/pss/leveldata.c index 8f98eff1..0679e194 100644 --- a/levels/pss/leveldata.c +++ b/levels/pss/leveldata.c @@ -3,8 +3,8 @@ #include "surface_terrains.h" #include "moving_texture_macros.h" #include "level_misc_macros.h" -#include "macro_preset_names.h" -#include "special_preset_names.h" +#include "macro_presets.h" +#include "special_presets.h" #include "textures.h" #include "dialog_ids.h" diff --git a/levels/pss/script.c b/levels/pss/script.c index 3547bf6b..98cc4732 100644 --- a/levels/pss/script.c +++ b/levels/pss/script.c @@ -17,23 +17,23 @@ const LevelScript level_pss_entry[] = { INIT_LEVEL(), - LOAD_MIO0( /*seg*/ 0x07, _pss_segment_7SegmentRomStart, _pss_segment_7SegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x07, _pss_segment_7SegmentRomStart, _pss_segment_7SegmentRomEnd), LOAD_MIO0_TEXTURE(/*seg*/ 0x09, _mountain_mio0SegmentRomStart, _mountain_mio0SegmentRomEnd), - LOAD_MIO0( /*seg*/ 0x05, _group8_mio0SegmentRomStart, _group8_mio0SegmentRomEnd), - LOAD_RAW( /*seg*/ 0x0C, _group8_geoSegmentRomStart, _group8_geoSegmentRomEnd), - LOAD_MIO0( /*seg*/ 0x08, _common0_mio0SegmentRomStart, _common0_mio0SegmentRomEnd), - LOAD_RAW( /*seg*/ 0x0F, _common0_geoSegmentRomStart, _common0_geoSegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x05, _group8_mio0SegmentRomStart, _group8_mio0SegmentRomEnd), + LOAD_RAW (/*seg*/ 0x0C, _group8_geoSegmentRomStart, _group8_geoSegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x08, _common0_mio0SegmentRomStart, _common0_mio0SegmentRomEnd), + LOAD_RAW (/*seg*/ 0x0F, _common0_geoSegmentRomStart, _common0_geoSegmentRomEnd), ALLOC_LEVEL_POOL(), - MARIO(/*model*/ MODEL_MARIO, /*behParam*/ 0x00000001, /*beh*/ bhvMario), + MARIO(/*model*/ MODEL_MARIO, /*bhvParam*/ BPARAM4(0x01), /*bhv*/ bhvMario), JUMP_LINK(script_func_global_1), JUMP_LINK(script_func_global_9), AREA(/*index*/ 1, pss_geo_000100), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 5632, 6751, -5631, /*angle*/ 0, 270, 0, /*behParam*/ 0x000A0000, /*beh*/ bhvAirborneWarp), - WARP_NODE(/*id*/ 0x0A, /*destLevel*/ LEVEL_PSS, /*destArea*/ 0x01, /*destNode*/ 0x0A, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0xF3, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x01, /*destNode*/ 0x20, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0xF0, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x01, /*destNode*/ 0x26, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0xF1, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x01, /*destNode*/ 0x23, /*flags*/ WARP_NO_CHECKPOINT), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 5632, 6751, -5631, /*angle*/ 0, 270, 0, /*bhvParam*/ BPARAM2(WARP_NODE_0A), /*bhv*/ bhvAirborneWarp), + WARP_NODE(/*id*/ WARP_NODE_0A, /*destLevel*/ LEVEL_PSS, /*destArea*/ 1, /*destNode*/ WARP_NODE_0A, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_WARP_FLOOR, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 1, /*destNode*/ WARP_NODE_20, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_SUCCESS, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 1, /*destNode*/ WARP_NODE_26, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_DEATH, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 1, /*destNode*/ WARP_NODE_23, /*flags*/ WARP_NO_CHECKPOINT), TERRAIN(/*terrainData*/ pss_seg7_collision), MACRO_OBJECTS(/*objList*/ pss_seg7_macro_objs), TERRAIN_TYPE(/*terrainType*/ TERRAIN_SLIDE), diff --git a/levels/rr/areas/1/10/geo.inc.c b/levels/rr/areas/1/10/geo.inc.c index 996fbe7e..626293d5 100644 --- a/levels/rr/areas/1/10/geo.inc.c +++ b/levels/rr/areas/1/10/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000720 const GeoLayout rr_geo_000720[] = { - GEO_CULLING_RADIUS(3000), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, rr_seg7_dl_0700CA38), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(3000), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, rr_seg7_dl_0700CA38), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/rr/areas/1/11/geo.inc.c b/levels/rr/areas/1/11/geo.inc.c index 9b0e2c7b..52736877 100644 --- a/levels/rr/areas/1/11/geo.inc.c +++ b/levels/rr/areas/1/11/geo.inc.c @@ -1,9 +1,9 @@ // 0x0E000738 const GeoLayout rr_geo_000738[] = { - GEO_CULLING_RADIUS(4000), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, rr_seg7_dl_0700DBD8), - GEO_DISPLAY_LIST(LAYER_ALPHA, rr_seg7_dl_0700DE88), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(4000), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, rr_seg7_dl_0700DBD8), + GEO_DISPLAY_LIST(LAYER_ALPHA, rr_seg7_dl_0700DE88), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/rr/areas/1/12/geo.inc.c b/levels/rr/areas/1/12/geo.inc.c index 6f2c8110..20c3eb73 100644 --- a/levels/rr/areas/1/12/geo.inc.c +++ b/levels/rr/areas/1/12/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000758 const GeoLayout rr_geo_000758[] = { - GEO_CULLING_RADIUS(1500), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, rr_seg7_dl_0700E178), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(1500), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, rr_seg7_dl_0700E178), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/rr/areas/1/13/geo.inc.c b/levels/rr/areas/1/13/geo.inc.c index 8f13231f..6ab534f5 100644 --- a/levels/rr/areas/1/13/geo.inc.c +++ b/levels/rr/areas/1/13/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000770 const GeoLayout rr_geo_000770[] = { - GEO_CULLING_RADIUS(1500), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, rr_seg7_dl_0700E830), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(1500), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, rr_seg7_dl_0700E830), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/rr/areas/1/14/geo.inc.c b/levels/rr/areas/1/14/geo.inc.c index 3ce92369..adaea881 100644 --- a/levels/rr/areas/1/14/geo.inc.c +++ b/levels/rr/areas/1/14/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000788 const GeoLayout rr_geo_000788[] = { - GEO_CULLING_RADIUS(4000), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, rr_seg7_dl_07012758), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(4000), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, rr_seg7_dl_07012758), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/rr/areas/1/15/geo.inc.c b/levels/rr/areas/1/15/geo.inc.c index 70cc96e3..b9c04b03 100644 --- a/levels/rr/areas/1/15/geo.inc.c +++ b/levels/rr/areas/1/15/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E0007A0 const GeoLayout rr_geo_0007A0[] = { - GEO_CULLING_RADIUS(3500), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, rr_seg7_dl_07014508), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(3500), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, rr_seg7_dl_07014508), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/rr/areas/1/16/geo.inc.c b/levels/rr/areas/1/16/geo.inc.c index 388c97b2..e598416e 100644 --- a/levels/rr/areas/1/16/geo.inc.c +++ b/levels/rr/areas/1/16/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E0007B8 const GeoLayout rr_geo_0007B8[] = { - GEO_CULLING_RADIUS(1600), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, rr_seg7_dl_07014F30), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(1600), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, rr_seg7_dl_07014F30), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/rr/areas/1/17/geo.inc.c b/levels/rr/areas/1/17/geo.inc.c index 6e3e70a6..a00fa7ee 100644 --- a/levels/rr/areas/1/17/geo.inc.c +++ b/levels/rr/areas/1/17/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E0007D0 const GeoLayout rr_geo_0007D0[] = { - GEO_CULLING_RADIUS(3800), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, rr_seg7_dl_070156B8), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(3800), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, rr_seg7_dl_070156B8), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/rr/areas/1/18/geo.inc.c b/levels/rr/areas/1/18/geo.inc.c index bd0ef753..78110399 100644 --- a/levels/rr/areas/1/18/geo.inc.c +++ b/levels/rr/areas/1/18/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E0007E8 const GeoLayout rr_geo_0007E8[] = { - GEO_CULLING_RADIUS(2500), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, rr_seg7_dl_07015C68), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(2500), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, rr_seg7_dl_07015C68), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/rr/areas/1/19/geo.inc.c b/levels/rr/areas/1/19/geo.inc.c index adafe181..cd95bd7a 100644 --- a/levels/rr/areas/1/19/geo.inc.c +++ b/levels/rr/areas/1/19/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000800 const GeoLayout rr_geo_000800[] = { - GEO_CULLING_RADIUS(4500), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, rr_seg7_dl_07017530), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(4500), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, rr_seg7_dl_07017530), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/rr/areas/1/2/geo.inc.c b/levels/rr/areas/1/2/geo.inc.c index 4cb14b3f..7e9d804e 100644 --- a/levels/rr/areas/1/2/geo.inc.c +++ b/levels/rr/areas/1/2/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000660 const GeoLayout rr_geo_000660[] = { - GEO_CULLING_RADIUS(3000), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, rr_seg7_dl_07002CC8), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(3000), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, rr_seg7_dl_07002CC8), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/rr/areas/1/20/geo.inc.c b/levels/rr/areas/1/20/geo.inc.c index e733ef1a..59f3caed 100644 --- a/levels/rr/areas/1/20/geo.inc.c +++ b/levels/rr/areas/1/20/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000818 const GeoLayout rr_geo_000818[] = { - GEO_CULLING_RADIUS(5000), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, rr_seg7_dl_07018B58), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(5000), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, rr_seg7_dl_07018B58), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/rr/areas/1/21/geo.inc.c b/levels/rr/areas/1/21/geo.inc.c index e39b1532..2d868cdf 100644 --- a/levels/rr/areas/1/21/geo.inc.c +++ b/levels/rr/areas/1/21/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000830 const GeoLayout rr_geo_000830[] = { - GEO_CULLING_RADIUS(3000), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, rr_seg7_dl_070191A0), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(3000), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, rr_seg7_dl_070191A0), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/rr/areas/1/3/geo.inc.c b/levels/rr/areas/1/3/geo.inc.c index ed48b827..8754f532 100644 --- a/levels/rr/areas/1/3/geo.inc.c +++ b/levels/rr/areas/1/3/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000678 const GeoLayout rr_geo_000678[] = { - GEO_CULLING_RADIUS(1000), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, rr_seg7_dl_07002E80), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(1000), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, rr_seg7_dl_07002E80), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/rr/areas/1/4/geo.inc.c b/levels/rr/areas/1/4/geo.inc.c index ab7e7af4..dc03c32c 100644 --- a/levels/rr/areas/1/4/geo.inc.c +++ b/levels/rr/areas/1/4/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000690 const GeoLayout rr_geo_000690[] = { - GEO_CULLING_RADIUS(3000), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, rr_seg7_dl_07004A98), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(3000), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, rr_seg7_dl_07004A98), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/rr/areas/1/5/geo.inc.c b/levels/rr/areas/1/5/geo.inc.c index 72b66008..28c765da 100644 --- a/levels/rr/areas/1/5/geo.inc.c +++ b/levels/rr/areas/1/5/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E0006A8 const GeoLayout rr_geo_0006A8[] = { - GEO_CULLING_RADIUS(3000), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, rr_seg7_dl_07005C80), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(3000), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, rr_seg7_dl_07005C80), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/rr/areas/1/6/geo.inc.c b/levels/rr/areas/1/6/geo.inc.c index 39bdb6ce..c2671555 100644 --- a/levels/rr/areas/1/6/geo.inc.c +++ b/levels/rr/areas/1/6/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E0006C0 const GeoLayout rr_geo_0006C0[] = { - GEO_CULLING_RADIUS(3500), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, rr_seg7_dl_07007E60), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(3500), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, rr_seg7_dl_07007E60), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/rr/areas/1/7/geo.inc.c b/levels/rr/areas/1/7/geo.inc.c index d431eead..b10720f3 100644 --- a/levels/rr/areas/1/7/geo.inc.c +++ b/levels/rr/areas/1/7/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E0006D8 const GeoLayout rr_geo_0006D8[] = { - GEO_CULLING_RADIUS(3500), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, rr_seg7_dl_07008258), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(3500), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, rr_seg7_dl_07008258), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/rr/areas/1/8/geo.inc.c b/levels/rr/areas/1/8/geo.inc.c index 687312ab..f7edc99e 100644 --- a/levels/rr/areas/1/8/geo.inc.c +++ b/levels/rr/areas/1/8/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E0006F0 const GeoLayout rr_geo_0006F0[] = { - GEO_CULLING_RADIUS(2800), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, rr_seg7_dl_07008E20), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(2800), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, rr_seg7_dl_07008E20), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/rr/areas/1/9/geo.inc.c b/levels/rr/areas/1/9/geo.inc.c index e54eebbe..a6c3446a 100644 --- a/levels/rr/areas/1/9/geo.inc.c +++ b/levels/rr/areas/1/9/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000708 const GeoLayout rr_geo_000708[] = { - GEO_CULLING_RADIUS(4000), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, rr_seg7_dl_0700BB48), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(4000), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, rr_seg7_dl_0700BB48), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/rr/areas/1/geo.inc.c b/levels/rr/areas/1/geo.inc.c index f899c995..3225f13b 100644 --- a/levels/rr/areas/1/geo.inc.c +++ b/levels/rr/areas/1/geo.inc.c @@ -1,31 +1,31 @@ // 0x0E0009D0 const GeoLayout rr_geo_0009D0[] = { - GEO_NODE_SCREEN_AREA(10, SCREEN_WIDTH/2, SCREEN_HEIGHT/2, SCREEN_WIDTH/2, SCREEN_HEIGHT/2), - GEO_OPEN_NODE(), - GEO_ZBUFFER(0), - GEO_OPEN_NODE(), - GEO_NODE_ORTHO(100), - GEO_OPEN_NODE(), - GEO_BACKGROUND(BACKGROUND_BELOW_CLOUDS, geo_skybox_main), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ZBUFFER(1), - GEO_OPEN_NODE(), - GEO_CAMERA_FRUSTUM_WITH_FUNC(45, 100, 20000, geo_camera_fov), - GEO_OPEN_NODE(), - GEO_CAMERA(14, 0, 2000, 6000, 0, 0, -8000, geo_camera_main), + GEO_NODE_SCREEN_AREA(10, SCREEN_WIDTH/2, SCREEN_HEIGHT/2, SCREEN_WIDTH/2, SCREEN_HEIGHT/2), + GEO_OPEN_NODE(), + GEO_ZBUFFER(0), + GEO_OPEN_NODE(), + GEO_NODE_ORTHO(100), GEO_OPEN_NODE(), - GEO_ASM(0, geo_exec_flying_carpet_timer_update), - GEO_DISPLAY_LIST(LAYER_ALPHA, dl_cruiser_metal_holes), - GEO_RENDER_OBJ(), - GEO_ASM(0, geo_envfx_main), + GEO_BACKGROUND(BACKGROUND_BELOW_CLOUDS, geo_skybox_main), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ZBUFFER(0), - GEO_OPEN_NODE(), - GEO_ASM(0, geo_cannon_circle_base), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CLOSE_NODE(), + GEO_ZBUFFER(1), + GEO_OPEN_NODE(), + GEO_CAMERA_FRUSTUM_WITH_FUNC(45, 100, 20000, geo_camera_fov), + GEO_OPEN_NODE(), + GEO_CAMERA(14, 0, 2000, 6000, 0, 0, -8000, geo_camera_main), + GEO_OPEN_NODE(), + GEO_ASM(0, geo_exec_flying_carpet_timer_update), + GEO_DISPLAY_LIST(LAYER_ALPHA, dl_cruiser_metal_holes), + GEO_RENDER_OBJ(), + GEO_ASM(0, geo_envfx_main), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ZBUFFER(0), + GEO_OPEN_NODE(), + GEO_ASM(0, geo_cannon_circle_base), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/rr/areas/1/macro.inc.c b/levels/rr/areas/1/macro.inc.c index 1b8bfcca..5a60ab7c 100644 --- a/levels/rr/areas/1/macro.inc.c +++ b/levels/rr/areas/1/macro.inc.c @@ -1,65 +1,65 @@ // 0x0702E9D8 - 0x0702EC3C const MacroObject rr_seg7_macro_objs[] = { - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -5850, -1000, -50), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -2950, -190, -50), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -5850, 1150, 50), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -5050, 800, -50), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -4550, 650, -50), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -5300, 200, -50), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -3550, 1000, -50), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -5800, -400, -50), - MACRO_OBJECT(/*preset*/ macro_bobomb_buddy_opens_cannon, /*yaw*/ 0, /*pos*/ -4200, 1648, 0), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_cannon_closed, /*yaw*/ 0, /*pos*/ 5545, 3333, -2345, /*behParam*/ 0xC0), - MACRO_OBJECT(/*preset*/ macro_box_1up, /*yaw*/ 0, /*pos*/ -6750, 2600, -50), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_circling_amp, /*yaw*/ 0, /*pos*/ 6500, -900, 900, /*behParam*/ 1), - MACRO_OBJECT(/*preset*/ macro_coin_ring_horizontal, /*yaw*/ 0, /*pos*/ 6500, -1000, 900), - MACRO_OBJECT(/*preset*/ macro_enemy_lakitu, /*yaw*/ 0, /*pos*/ 615, -584, 0), - MACRO_OBJECT(/*preset*/ macro_recovery_heart, /*yaw*/ 0, /*pos*/ -550, -1050, -50), - MACRO_OBJECT(/*preset*/ macro_coin_ring_horizontal_flying, /*yaw*/ 0, /*pos*/ 600, -1040, 1200), - MACRO_OBJECT(/*preset*/ macro_coin_ring_horizontal_flying, /*yaw*/ 0, /*pos*/ 600, -1040, -1300), - MACRO_OBJECT(/*preset*/ macro_recovery_heart, /*yaw*/ 0, /*pos*/ -7071, -1705, -31), - MACRO_OBJECT(/*preset*/ macro_bobomb, /*yaw*/ 0, /*pos*/ -3295, -1782, 524), - MACRO_OBJECT(/*preset*/ macro_bobomb, /*yaw*/ 0, /*pos*/ -5872, -1782, 572), - MACRO_OBJECT(/*preset*/ macro_fly_guy, /*yaw*/ 0, /*pos*/ 971, -3059, 4912), - MACRO_OBJECT(/*preset*/ macro_coin_line_horizontal, /*yaw*/ 0, /*pos*/ 615, -3275, 5660), - MACRO_OBJECT(/*preset*/ macro_coin_line_vertical, /*yaw*/ 0, /*pos*/ -2203, -3500, 6572), - MACRO_OBJECT(/*preset*/ macro_coin_line_horizontal, /*yaw*/ 90, /*pos*/ -1866, -1116, 4933), - MACRO_OBJECT(/*preset*/ macro_coin_line_horizontal, /*yaw*/ 90, /*pos*/ 799, -1446, 6622), - MACRO_OBJECT(/*preset*/ macro_1up, /*yaw*/ 0, /*pos*/ 6666, -1000, 6533), - MACRO_OBJECT(/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ 3960, -41, -3640), - MACRO_OBJECT(/*preset*/ macro_yellow_coin, /*yaw*/ 0, /*pos*/ 5680, 600, -2400), - MACRO_OBJECT(/*preset*/ macro_breakable_box_no_coins, /*yaw*/ 0, /*pos*/ 2560, 1000, -1600), - MACRO_OBJECT(/*preset*/ macro_goomba, /*yaw*/ 0, /*pos*/ -1440, -1960, 6640), - MACRO_OBJECT(/*preset*/ macro_1up, /*yaw*/ 0, /*pos*/ 5040, 2100, 280), - MACRO_OBJECT(/*preset*/ macro_hidden_1up_in_pole, /*yaw*/ 0, /*pos*/ 3542, 4892, -2371), - MACRO_OBJECT(/*preset*/ macro_enemy_lakitu, /*yaw*/ 0, /*pos*/ 4714, 3507, -2371), - MACRO_OBJECT(/*preset*/ macro_bobomb, /*yaw*/ 0, /*pos*/ 3485, 2889, -2057), - MACRO_OBJECT(/*preset*/ macro_bobomb, /*yaw*/ 0, /*pos*/ 2628, 2893, -2371), - MACRO_OBJECT(/*preset*/ macro_coin_ring_horizontal, /*yaw*/ 0, /*pos*/ 3542, 2923, -2371), - MACRO_OBJECT(/*preset*/ macro_coin_line_horizontal, /*yaw*/ 0, /*pos*/ -3342, 3222, -5071), - MACRO_OBJECT(/*preset*/ macro_coin_line_horizontal, /*yaw*/ 0, /*pos*/ -7771, 4352, -3871), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_circling_amp, /*yaw*/ 0, /*pos*/ -6571, 4000, -2328, /*behParam*/ 1), - MACRO_OBJECT(/*preset*/ macro_coin_line_horizontal_flying, /*yaw*/ 90, /*pos*/ -6057, 4676, -5242), - MACRO_OBJECT(/*preset*/ macro_chuckya, /*yaw*/ 0, /*pos*/ 5114, 3828, 4028), - MACRO_OBJECT(/*preset*/ macro_1up, /*yaw*/ 0, /*pos*/ -165, 3543, -2352), - MACRO_OBJECT(/*preset*/ macro_coin_line_vertical, /*yaw*/ 0, /*pos*/ 250, 1400, -180), - MACRO_OBJECT(/*preset*/ macro_1up, /*yaw*/ 0, /*pos*/ -735, 2860, -150), - MACRO_OBJECT(/*preset*/ macro_hidden_1up_in_pole, /*yaw*/ 0, /*pos*/ -2175, 2365, -60), - MACRO_OBJECT(/*preset*/ macro_blue_coin_switch, /*yaw*/ 0, /*pos*/ -6930, -1791, 521), - MACRO_OBJECT(/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ -6500, 1700, 0), - MACRO_OBJECT(/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ -6200, 1700, 0), - MACRO_OBJECT(/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ -5900, 1700, 0), - MACRO_OBJECT(/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ -5600, 1700, 0), - MACRO_OBJECT(/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ -6750, -1495, 0), - MACRO_OBJECT(/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ -5300, 1700, 0), - MACRO_OBJECT(/*preset*/ macro_fire_spitter, /*yaw*/ 0, /*pos*/ -3233, 1291, -52), - MACRO_OBJECT(/*preset*/ macro_yellow_coin, /*yaw*/ 0, /*pos*/ -7338, -2260, 6700), - MACRO_OBJECT(/*preset*/ macro_yellow_coin, /*yaw*/ 0, /*pos*/ -7338, -2260, 6350), - MACRO_OBJECT(/*preset*/ macro_yellow_coin, /*yaw*/ 0, /*pos*/ -6715, -1900, 6700), - MACRO_OBJECT(/*preset*/ macro_yellow_coin, /*yaw*/ 0, /*pos*/ -6715, -1900, 6350), - MACRO_OBJECT(/*preset*/ macro_box_1up_running_away, /*yaw*/ 0, /*pos*/ -4844, -4240, 6622), - MACRO_OBJECT(/*preset*/ macro_box_1up_running_away, /*yaw*/ 0, /*pos*/ -3428, 6770, -5128), - MACRO_OBJECT(/*preset*/ macro_box_star_6, /*yaw*/ 0, /*pos*/ 5000, 4100, 4440), - MACRO_OBJECT(/*preset*/ macro_fire_spitter, /*yaw*/ 0, /*pos*/ -6000, -440, -40), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -5850, -1000, -50), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -2950, -190, -50), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -5850, 1150, 50), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -5050, 800, -50), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -4550, 650, -50), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -5300, 200, -50), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -3550, 1000, -50), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -5800, -400, -50), + MACRO_OBJECT (/*preset*/ macro_bobomb_buddy_opens_cannon_1, /*yaw*/ 0, /*pos*/ -4200, 1648, 0), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_cannon_closed, /*yaw*/ 0, /*pos*/ 5545, 3333, -2345, /*bhvParam*/ 0xC0), + MACRO_OBJECT (/*preset*/ macro_box_1up, /*yaw*/ 0, /*pos*/ -6750, 2600, -50), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_circling_amp, /*yaw*/ 0, /*pos*/ 6500, -900, 900, /*bhvParam*/ AMP_BP_ROT_RADIUS_300), + MACRO_OBJECT (/*preset*/ macro_coin_ring_horizontal, /*yaw*/ 0, /*pos*/ 6500, -1000, 900), + MACRO_OBJECT (/*preset*/ macro_enemy_lakitu, /*yaw*/ 0, /*pos*/ 615, -584, 0), + MACRO_OBJECT (/*preset*/ macro_recovery_heart, /*yaw*/ 0, /*pos*/ -550, -1050, -50), + MACRO_OBJECT (/*preset*/ macro_coin_ring_horizontal_flying, /*yaw*/ 0, /*pos*/ 600, -1040, 1200), + MACRO_OBJECT (/*preset*/ macro_coin_ring_horizontal_flying, /*yaw*/ 0, /*pos*/ 600, -1040, -1300), + MACRO_OBJECT (/*preset*/ macro_recovery_heart, /*yaw*/ 0, /*pos*/ -7071, -1705, -31), + MACRO_OBJECT (/*preset*/ macro_bobomb, /*yaw*/ 0, /*pos*/ -3295, -1782, 524), + MACRO_OBJECT (/*preset*/ macro_bobomb, /*yaw*/ 0, /*pos*/ -5872, -1782, 572), + MACRO_OBJECT (/*preset*/ macro_fly_guy, /*yaw*/ 0, /*pos*/ 971, -3059, 4912), + MACRO_OBJECT (/*preset*/ macro_coin_line_horizontal, /*yaw*/ 0, /*pos*/ 615, -3275, 5660), + MACRO_OBJECT (/*preset*/ macro_coin_line_vertical_flying, /*yaw*/ 0, /*pos*/ -2203, -3500, 6572), + MACRO_OBJECT (/*preset*/ macro_coin_line_horizontal, /*yaw*/ 90, /*pos*/ -1866, -1116, 4933), + MACRO_OBJECT (/*preset*/ macro_coin_line_horizontal, /*yaw*/ 90, /*pos*/ 799, -1446, 6622), + MACRO_OBJECT (/*preset*/ macro_1up, /*yaw*/ 0, /*pos*/ 6666, -1000, 6533), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ 3960, -41, -3640), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_1, /*yaw*/ 0, /*pos*/ 5680, 600, -2400), + MACRO_OBJECT (/*preset*/ macro_breakable_box_no_coins, /*yaw*/ 0, /*pos*/ 2560, 1000, -1600), + MACRO_OBJECT (/*preset*/ macro_goomba, /*yaw*/ 0, /*pos*/ -1440, -1960, 6640), + MACRO_OBJECT (/*preset*/ macro_1up, /*yaw*/ 0, /*pos*/ 5040, 2100, 280), + MACRO_OBJECT (/*preset*/ macro_hidden_1up_in_pole, /*yaw*/ 0, /*pos*/ 3542, 4892, -2371), + MACRO_OBJECT (/*preset*/ macro_enemy_lakitu, /*yaw*/ 0, /*pos*/ 4714, 3507, -2371), + MACRO_OBJECT (/*preset*/ macro_bobomb, /*yaw*/ 0, /*pos*/ 3485, 2889, -2057), + MACRO_OBJECT (/*preset*/ macro_bobomb, /*yaw*/ 0, /*pos*/ 2628, 2893, -2371), + MACRO_OBJECT (/*preset*/ macro_coin_ring_horizontal, /*yaw*/ 0, /*pos*/ 3542, 2923, -2371), + MACRO_OBJECT (/*preset*/ macro_coin_line_horizontal, /*yaw*/ 0, /*pos*/ -3342, 3222, -5071), + MACRO_OBJECT (/*preset*/ macro_coin_line_horizontal, /*yaw*/ 0, /*pos*/ -7771, 4352, -3871), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_circling_amp, /*yaw*/ 0, /*pos*/ -6571, 4000, -2328, /*bhvParam*/ AMP_BP_ROT_RADIUS_300), + MACRO_OBJECT (/*preset*/ macro_coin_line_horizontal_flying, /*yaw*/ 90, /*pos*/ -6057, 4676, -5242), + MACRO_OBJECT (/*preset*/ macro_chuckya, /*yaw*/ 0, /*pos*/ 5114, 3828, 4028), + MACRO_OBJECT (/*preset*/ macro_1up, /*yaw*/ 0, /*pos*/ -165, 3543, -2352), + MACRO_OBJECT (/*preset*/ macro_coin_line_vertical_flying, /*yaw*/ 0, /*pos*/ 250, 1400, -180), + MACRO_OBJECT (/*preset*/ macro_1up, /*yaw*/ 0, /*pos*/ -735, 2860, -150), + MACRO_OBJECT (/*preset*/ macro_hidden_1up_in_pole, /*yaw*/ 0, /*pos*/ -2175, 2365, -60), + MACRO_OBJECT (/*preset*/ macro_blue_coin_switch, /*yaw*/ 0, /*pos*/ -6930, -1791, 521), + MACRO_OBJECT (/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ -6500, 1700, 0), + MACRO_OBJECT (/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ -6200, 1700, 0), + MACRO_OBJECT (/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ -5900, 1700, 0), + MACRO_OBJECT (/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ -5600, 1700, 0), + MACRO_OBJECT (/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ -6750, -1495, 0), + MACRO_OBJECT (/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ -5300, 1700, 0), + MACRO_OBJECT (/*preset*/ macro_fire_spitter, /*yaw*/ 0, /*pos*/ -3233, 1291, -52), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_1, /*yaw*/ 0, /*pos*/ -7338, -2260, 6700), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_1, /*yaw*/ 0, /*pos*/ -7338, -2260, 6350), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_1, /*yaw*/ 0, /*pos*/ -6715, -1900, 6700), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_1, /*yaw*/ 0, /*pos*/ -6715, -1900, 6350), + MACRO_OBJECT (/*preset*/ macro_box_1up_running_away, /*yaw*/ 0, /*pos*/ -4844, -4240, 6622), + MACRO_OBJECT (/*preset*/ macro_box_1up_running_away, /*yaw*/ 0, /*pos*/ -3428, 6770, -5128), + MACRO_OBJECT (/*preset*/ macro_box_star_act_6, /*yaw*/ 0, /*pos*/ 5000, 4100, 4440), + MACRO_OBJECT (/*preset*/ macro_fire_spitter, /*yaw*/ 0, /*pos*/ -6000, -440, -40), MACRO_OBJECT_END(), }; diff --git a/levels/rr/cruiser_wing/geo.inc.c b/levels/rr/cruiser_wing/geo.inc.c index a1bc92ca..439703ec 100644 --- a/levels/rr/cruiser_wing/geo.inc.c +++ b/levels/rr/cruiser_wing/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000890 const GeoLayout rr_geo_000890[] = { - GEO_CULLING_RADIUS(1200), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, rr_seg7_dl_0701A680), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(1200), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, rr_seg7_dl_0701A680), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/rr/donut_block/geo.inc.c b/levels/rr/donut_block/geo.inc.c index 30d7caa0..d0948fdf 100644 --- a/levels/rr/donut_block/geo.inc.c +++ b/levels/rr/donut_block/geo.inc.c @@ -1,9 +1,9 @@ // 0x0E000920 const GeoLayout rr_geo_000920[] = { - GEO_CULLING_RADIUS(420), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, rr_seg7_dl_0701B848), - GEO_DISPLAY_LIST(LAYER_ALPHA, rr_seg7_dl_0701B980), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(420), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, rr_seg7_dl_0701B848), + GEO_DISPLAY_LIST(LAYER_ALPHA, rr_seg7_dl_0701B980), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/rr/elevator_platform/geo.inc.c b/levels/rr/elevator_platform/geo.inc.c index 51552253..87f6381d 100644 --- a/levels/rr/elevator_platform/geo.inc.c +++ b/levels/rr/elevator_platform/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E0008F0 const GeoLayout rr_geo_0008F0[] = { - GEO_CULLING_RADIUS(500), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, rr_seg7_dl_0701B220), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(500), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, rr_seg7_dl_0701B220), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/rr/flying_carpet/geo.inc.c b/levels/rr/flying_carpet/geo.inc.c index 5adb2999..96f93e12 100644 --- a/levels/rr/flying_carpet/geo.inc.c +++ b/levels/rr/flying_carpet/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000848 const GeoLayout rr_geo_000848[] = { - GEO_CULLING_RADIUS(500), - GEO_OPEN_NODE(), - GEO_ASM(0, geo_exec_flying_carpet_create), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(500), + GEO_OPEN_NODE(), + GEO_ASM(0, geo_exec_flying_carpet_create), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/rr/l_platform/geo.inc.c b/levels/rr/l_platform/geo.inc.c index fe9a7fc2..aab1b2aa 100644 --- a/levels/rr/l_platform/geo.inc.c +++ b/levels/rr/l_platform/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000940 const GeoLayout rr_geo_000940[] = { - GEO_CULLING_RADIUS(1100), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, rr_seg7_dl_0701BD08), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(1100), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, rr_seg7_dl_0701BD08), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/rr/leveldata.c b/levels/rr/leveldata.c index 218f1e34..65515843 100644 --- a/levels/rr/leveldata.c +++ b/levels/rr/leveldata.c @@ -3,8 +3,8 @@ #include "surface_terrains.h" #include "moving_texture_macros.h" #include "level_misc_macros.h" -#include "macro_preset_names.h" -#include "special_preset_names.h" +#include "macro_presets.h" +#include "special_presets.h" #include "textures.h" #include "make_const_nonconst.h" diff --git a/levels/rr/octagonal_platform/geo.inc.c b/levels/rr/octagonal_platform/geo.inc.c index 316eef8c..4a7b9aa0 100644 --- a/levels/rr/octagonal_platform/geo.inc.c +++ b/levels/rr/octagonal_platform/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E0008A8 const GeoLayout rr_geo_0008A8[] = { - GEO_CULLING_RADIUS(1300), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, rr_seg7_dl_0701AB78), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(1300), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, rr_seg7_dl_0701AB78), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/rr/pyramid_platform/geo.inc.c b/levels/rr/pyramid_platform/geo.inc.c index 17009629..bc2f21f0 100644 --- a/levels/rr/pyramid_platform/geo.inc.c +++ b/levels/rr/pyramid_platform/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E0008D8 const GeoLayout rr_geo_0008D8[] = { - GEO_CULLING_RADIUS(700), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, rr_seg7_dl_0701AFA0), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(700), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, rr_seg7_dl_0701AFA0), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/rr/rotating_bridge_platform/geo.inc.c b/levels/rr/rotating_bridge_platform/geo.inc.c index 5706ece9..89eacf47 100644 --- a/levels/rr/rotating_bridge_platform/geo.inc.c +++ b/levels/rr/rotating_bridge_platform/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000878 const GeoLayout rr_geo_000878[] = { - GEO_CULLING_RADIUS(1500), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, rr_seg7_dl_0701A568), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(1500), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, rr_seg7_dl_0701A568), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/rr/script.c b/levels/rr/script.c index 85f925e1..ac84bce9 100644 --- a/levels/rr/script.c +++ b/levels/rr/script.c @@ -16,69 +16,69 @@ #include "levels/rr/header.h" static const LevelScript script_func_local_1[] = { - OBJECT(/*model*/ MODEL_RR_SLIDING_PLATFORM, /*pos*/ -3400, -2038, 6564, /*angle*/ 0, 0, 0, /*behParam*/ 0x02560000, /*beh*/ bhvSlidingPlatform2), - OBJECT(/*model*/ MODEL_RR_SLIDING_PLATFORM, /*pos*/ -2684, -1423, -36, /*angle*/ 0, 0, 0, /*behParam*/ 0x02590000, /*beh*/ bhvSlidingPlatform2), - OBJECT(/*model*/ MODEL_RR_FLYING_CARPET, /*pos*/ 4571, -1782, 2036, /*angle*/ 0, 180, 0, /*behParam*/ 0x00000000, /*beh*/ bhvPlatformOnTrack), - OBJECT(/*model*/ MODEL_RR_FLYING_CARPET, /*pos*/ 580, -963, -3659, /*angle*/ 0, 180, 0, /*behParam*/ 0x00010000, /*beh*/ bhvPlatformOnTrack), - OBJECT(/*model*/ MODEL_RR_FLYING_CARPET, /*pos*/ 1567, 880, -184, /*angle*/ 0, 180, 0, /*behParam*/ 0x00070000, /*beh*/ bhvPlatformOnTrack), - OBJECT(/*model*/ MODEL_RR_FLYING_CARPET, /*pos*/ 646, 880, -184, /*angle*/ 0, 0, 0, /*behParam*/ 0x00080000, /*beh*/ bhvPlatformOnTrack), - OBJECT(/*model*/ MODEL_RR_OCTAGONAL_PLATFORM, /*pos*/ 644, -1321, -1301, /*angle*/ 0, 180, 0, /*behParam*/ 0x03010000, /*beh*/ bhvOctagonalPlatformRotating), - OBJECT(/*model*/ MODEL_RR_OCTAGONAL_PLATFORM, /*pos*/ 1797, -1321, -56, /*angle*/ 0, 0, 0, /*behParam*/ 0x00010000, /*beh*/ bhvOctagonalPlatformRotating), - OBJECT(/*model*/ MODEL_RR_OCTAGONAL_PLATFORM, /*pos*/ 663, -1321, 1179, /*angle*/ 0, 180, 0, /*behParam*/ 0x03010000, /*beh*/ bhvOctagonalPlatformRotating), - OBJECT(/*model*/ MODEL_RR_OCTAGONAL_PLATFORM, /*pos*/ -502, -1321, -51, /*angle*/ 0, 0, 0, /*behParam*/ 0x00010000, /*beh*/ bhvOctagonalPlatformRotating), - OBJECT(/*model*/ MODEL_RR_ROTATING_BRIDGE_PLATFORM, /*pos*/ 5043, 1342, 300, /*angle*/ 0, 0, 0, /*behParam*/ 0x00010000, /*beh*/ bhvRrRotatingBridgePlatform), - OBJECT(/*model*/ MODEL_RR_CRUISER_WING, /*pos*/ 3473, 2422, -1821, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvRrCruiserWing), - OBJECT(/*model*/ MODEL_RR_CRUISER_WING, /*pos*/ 4084, 2431, -2883, /*angle*/ 45, 180, 180, /*behParam*/ 0x00010000, /*beh*/ bhvRrCruiserWing), - OBJECT(/*model*/ MODEL_RR_CRUISER_WING, /*pos*/ 3470, 2420, -2869, /*angle*/ 45, 180, 180, /*behParam*/ 0x00010000, /*beh*/ bhvRrCruiserWing), - OBJECT(/*model*/ MODEL_RR_CRUISER_WING, /*pos*/ 2856, 2410, -2855, /*angle*/ 45, 180, 180, /*behParam*/ 0x00010000, /*beh*/ bhvRrCruiserWing), - OBJECT(/*model*/ MODEL_RR_CRUISER_WING, /*pos*/ 4101, 2435, -1813, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvRrCruiserWing), - OBJECT(/*model*/ MODEL_RR_CRUISER_WING, /*pos*/ 2859, 2411, -1834, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvRrCruiserWing), - OBJECT(/*model*/ MODEL_RR_SEESAW_PLATFORM, /*pos*/ -6013, -2857, 6564, /*angle*/ 0, 270, 0, /*behParam*/ 0x00050000, /*beh*/ bhvSeesawPlatform), - OBJECT(/*model*/ MODEL_RR_SEESAW_PLATFORM, /*pos*/ 614, -3574, 6564, /*angle*/ 0, 270, 0, /*behParam*/ 0x00050000, /*beh*/ bhvSeesawPlatform), - OBJECT(/*model*/ MODEL_RR_SWINGING_PLATFORM, /*pos*/ -3557, -809, 4619, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvSwingPlatform), - OBJECT(/*model*/ MODEL_RR_SWINGING_PLATFORM, /*pos*/ -2213, -2582, 6257, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvSwingPlatform), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 0, 0, 0, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvDonutPlatformSpawner), - OBJECT(/*model*/ MODEL_RR_ELEVATOR_PLATFORM, /*pos*/ -2684, 1546, -36, /*angle*/ 0, 0, 0, /*behParam*/ 0x00050000, /*beh*/ bhvRrElevatorPlatform), - OBJECT(/*model*/ MODEL_RR_TRICKY_TRIANGLES, /*pos*/ 5862, -1347, 6564, /*angle*/ 0, 0, 0, /*behParam*/ 0x00020000, /*beh*/ bhvAnimatesOnFloorSwitchPress), - OBJECT(/*model*/ MODEL_PURPLE_SWITCH, /*pos*/ 4428, -1936, 6564, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvFloorSwitchAnimatesObject), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 614, -2857, 3671, /*angle*/ 0, 0, 0, /*behParam*/ 0x00CC0000, /*beh*/ bhvPoleGrabbing), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 621, -4598, 7362, /*angle*/ 0, 0, 0, /*behParam*/ 0x00750000, /*beh*/ bhvPoleGrabbing), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 5119, 3819, 3325, /*angle*/ 0, 0, 0, /*behParam*/ 0x00610000, /*beh*/ bhvPoleGrabbing), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 3554, 2891, -2327, /*angle*/ 0, 0, 0, /*behParam*/ 0x00C10000, /*beh*/ bhvPoleGrabbing), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 2680, 214, 295, /*angle*/ 0, 0, 0, /*behParam*/ 0x00620000, /*beh*/ bhvPoleGrabbing), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 3811, 1033, 295, /*angle*/ 0, 0, 0, /*behParam*/ 0x00620000, /*beh*/ bhvPoleGrabbing), + OBJECT(/*model*/ MODEL_RR_SLIDING_PLATFORM, /*pos*/ -3400, -2038, 6564, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(0x02) | BPARAM2(0x56), /*bhv*/ bhvSlidingPlatform2), + OBJECT(/*model*/ MODEL_RR_SLIDING_PLATFORM, /*pos*/ -2684, -1423, -36, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(0x02) | BPARAM2(0x59), /*bhv*/ bhvSlidingPlatform2), + OBJECT(/*model*/ MODEL_RR_FLYING_CARPET, /*pos*/ 4571, -1782, 2036, /*angle*/ 0, 180, 0, /*bhvParam*/ 0, /*bhv*/ bhvPlatformOnTrack), + OBJECT(/*model*/ MODEL_RR_FLYING_CARPET, /*pos*/ 580, -963, -3659, /*angle*/ 0, 180, 0, /*bhvParam*/ BPARAM2(0x01), /*bhv*/ bhvPlatformOnTrack), + OBJECT(/*model*/ MODEL_RR_FLYING_CARPET, /*pos*/ 1567, 880, -184, /*angle*/ 0, 180, 0, /*bhvParam*/ BPARAM2(0x07), /*bhv*/ bhvPlatformOnTrack), + OBJECT(/*model*/ MODEL_RR_FLYING_CARPET, /*pos*/ 646, 880, -184, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(0x08), /*bhv*/ bhvPlatformOnTrack), + OBJECT(/*model*/ MODEL_RR_OCTAGONAL_PLATFORM, /*pos*/ 644, -1321, -1301, /*angle*/ 0, 180, 0, /*bhvParam*/ BPARAM1(0x03) | BPARAM2(0x01), /*bhv*/ bhvOctagonalPlatformRotating), + OBJECT(/*model*/ MODEL_RR_OCTAGONAL_PLATFORM, /*pos*/ 1797, -1321, -56, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(0x01), /*bhv*/ bhvOctagonalPlatformRotating), + OBJECT(/*model*/ MODEL_RR_OCTAGONAL_PLATFORM, /*pos*/ 663, -1321, 1179, /*angle*/ 0, 180, 0, /*bhvParam*/ BPARAM1(0x03) | BPARAM2(0x01), /*bhv*/ bhvOctagonalPlatformRotating), + OBJECT(/*model*/ MODEL_RR_OCTAGONAL_PLATFORM, /*pos*/ -502, -1321, -51, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(0x01), /*bhv*/ bhvOctagonalPlatformRotating), + OBJECT(/*model*/ MODEL_RR_ROTATING_BRIDGE_PLATFORM, /*pos*/ 5043, 1342, 300, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(0x01), /*bhv*/ bhvRRRotatingBridgePlatform), + OBJECT(/*model*/ MODEL_RR_CRUISER_WING, /*pos*/ 3473, 2422, -1821, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvRRCruiserWing), + OBJECT(/*model*/ MODEL_RR_CRUISER_WING, /*pos*/ 4084, 2431, -2883, /*angle*/ 45, 180, 180, /*bhvParam*/ BPARAM2(0x01), /*bhv*/ bhvRRCruiserWing), + OBJECT(/*model*/ MODEL_RR_CRUISER_WING, /*pos*/ 3470, 2420, -2869, /*angle*/ 45, 180, 180, /*bhvParam*/ BPARAM2(0x01), /*bhv*/ bhvRRCruiserWing), + OBJECT(/*model*/ MODEL_RR_CRUISER_WING, /*pos*/ 2856, 2410, -2855, /*angle*/ 45, 180, 180, /*bhvParam*/ BPARAM2(0x01), /*bhv*/ bhvRRCruiserWing), + OBJECT(/*model*/ MODEL_RR_CRUISER_WING, /*pos*/ 4101, 2435, -1813, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvRRCruiserWing), + OBJECT(/*model*/ MODEL_RR_CRUISER_WING, /*pos*/ 2859, 2411, -1834, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvRRCruiserWing), + OBJECT(/*model*/ MODEL_RR_SEESAW_PLATFORM, /*pos*/ -6013, -2857, 6564, /*angle*/ 0, 270, 0, /*bhvParam*/ BPARAM2(0x05), /*bhv*/ bhvSeesawPlatform), + OBJECT(/*model*/ MODEL_RR_SEESAW_PLATFORM, /*pos*/ 614, -3574, 6564, /*angle*/ 0, 270, 0, /*bhvParam*/ BPARAM2(0x05), /*bhv*/ bhvSeesawPlatform), + OBJECT(/*model*/ MODEL_RR_SWINGING_PLATFORM, /*pos*/ -3557, -809, 4619, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvSwingPlatform), + OBJECT(/*model*/ MODEL_RR_SWINGING_PLATFORM, /*pos*/ -2213, -2582, 6257, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvSwingPlatform), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 0, 0, 0, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvDonutPlatformSpawner), + OBJECT(/*model*/ MODEL_RR_ELEVATOR_PLATFORM, /*pos*/ -2684, 1546, -36, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(0x05), /*bhv*/ bhvRRElevatorPlatform), + OBJECT(/*model*/ MODEL_RR_TRICKY_TRIANGLES, /*pos*/ 5862, -1347, 6564, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(0x02), /*bhv*/ bhvAnimatesOnFloorSwitchPress), + OBJECT(/*model*/ MODEL_PURPLE_SWITCH, /*pos*/ 4428, -1936, 6564, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvFloorSwitchAnimatesObject), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 614, -2857, 3671, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(204), /*bhv*/ bhvPoleGrabbing), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 621, -4598, 7362, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(117), /*bhv*/ bhvPoleGrabbing), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 5119, 3819, 3325, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(97), /*bhv*/ bhvPoleGrabbing), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 3554, 2891, -2327, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(193), /*bhv*/ bhvPoleGrabbing), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 2680, 214, 295, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(98), /*bhv*/ bhvPoleGrabbing), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 3811, 1033, 295, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(98), /*bhv*/ bhvPoleGrabbing), RETURN(), }; static const LevelScript script_func_local_2[] = { - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -5809, -1834, 5719, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvFlamethrower), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -4838, -1015, 4081, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvFlamethrower), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 3301, -1834, 5617, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvFlamethrower), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 6772, -757, -606, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvFlamethrower), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -4187, 3213, -6630, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvFlamethrower), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ -5809, -1834, 5719, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvFlamethrower), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ -4838, -1015, 4081, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvFlamethrower), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 3301, -1834, 5617, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvFlamethrower), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 6772, -757, -606, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvFlamethrower), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ -4187, 3213, -6630, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvFlamethrower), RETURN(), }; static const LevelScript script_func_local_3[] = { - OBJECT_WITH_ACTS(/*model*/ MODEL_STAR, /*pos*/ 1450, 3400, -2352, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvStar, /*acts*/ ALL_ACTS), - OBJECT_WITH_ACTS(/*model*/ MODEL_STAR, /*pos*/ -4200, 6700, -4450, /*angle*/ 0, 0, 0, /*behParam*/ 0x01000000, /*beh*/ bhvStar, /*acts*/ ALL_ACTS), - OBJECT_WITH_ACTS(/*model*/ MODEL_NONE, /*pos*/ -5150, -1400, 0, /*angle*/ 0, 0, 0, /*behParam*/ 0x02000000, /*beh*/ bhvHiddenRedCoinStar, /*acts*/ ALL_ACTS), - OBJECT_WITH_ACTS(/*model*/ MODEL_STAR, /*pos*/ -5850, -700, 4950, /*angle*/ 0, 0, 0, /*behParam*/ 0x03000000, /*beh*/ bhvStar, /*acts*/ ALL_ACTS), - OBJECT_WITH_ACTS(/*model*/ MODEL_STAR, /*pos*/ 3700, -400, 6600, /*angle*/ 0, 0, 0, /*behParam*/ 0x04000000, /*beh*/ bhvStar, /*acts*/ ALL_ACTS), + OBJECT_WITH_ACTS(/*model*/ MODEL_STAR, /*pos*/ 1450, 3400, -2352, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(STAR_INDEX_ACT_1), /*bhv*/ bhvStar, /*acts*/ ALL_ACTS), + OBJECT_WITH_ACTS(/*model*/ MODEL_STAR, /*pos*/ -4200, 6700, -4450, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(STAR_INDEX_ACT_2), /*bhv*/ bhvStar, /*acts*/ ALL_ACTS), + OBJECT_WITH_ACTS(/*model*/ MODEL_NONE, /*pos*/ -5150, -1400, 0, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(STAR_INDEX_ACT_3), /*bhv*/ bhvHiddenRedCoinStar, /*acts*/ ALL_ACTS), + OBJECT_WITH_ACTS(/*model*/ MODEL_STAR, /*pos*/ -5850, -700, 4950, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(STAR_INDEX_ACT_4), /*bhv*/ bhvStar, /*acts*/ ALL_ACTS), + OBJECT_WITH_ACTS(/*model*/ MODEL_STAR, /*pos*/ 3700, -400, 6600, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(STAR_INDEX_ACT_5), /*bhv*/ bhvStar, /*acts*/ ALL_ACTS), RETURN(), }; const LevelScript level_rr_entry[] = { INIT_LEVEL(), - LOAD_MIO0( /*seg*/ 0x07, _rr_segment_7SegmentRomStart, _rr_segment_7SegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x07, _rr_segment_7SegmentRomStart, _rr_segment_7SegmentRomEnd), LOAD_MIO0_TEXTURE(/*seg*/ 0x09, _sky_mio0SegmentRomStart, _sky_mio0SegmentRomEnd), - LOAD_MIO0( /*seg*/ 0x0A, _cloud_floor_skybox_mio0SegmentRomStart, _cloud_floor_skybox_mio0SegmentRomEnd), - LOAD_MIO0( /*seg*/ 0x05, _group11_mio0SegmentRomStart, _group11_mio0SegmentRomEnd), - LOAD_RAW( /*seg*/ 0x0C, _group11_geoSegmentRomStart, _group11_geoSegmentRomEnd), - LOAD_MIO0( /*seg*/ 0x08, _common0_mio0SegmentRomStart, _common0_mio0SegmentRomEnd), - LOAD_RAW( /*seg*/ 0x0F, _common0_geoSegmentRomStart, _common0_geoSegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x0A, _cloud_floor_skybox_mio0SegmentRomStart, _cloud_floor_skybox_mio0SegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x05, _group11_mio0SegmentRomStart, _group11_mio0SegmentRomEnd), + LOAD_RAW (/*seg*/ 0x0C, _group11_geoSegmentRomStart, _group11_geoSegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x08, _common0_mio0SegmentRomStart, _common0_mio0SegmentRomEnd), + LOAD_RAW (/*seg*/ 0x0F, _common0_geoSegmentRomStart, _common0_geoSegmentRomEnd), ALLOC_LEVEL_POOL(), - MARIO(/*model*/ MODEL_MARIO, /*behParam*/ 0x00000001, /*beh*/ bhvMario), + MARIO(/*model*/ MODEL_MARIO, /*bhvParam*/ BPARAM4(0x01), /*bhv*/ bhvMario), JUMP_LINK(script_func_global_12), JUMP_LINK(script_func_global_1), LOAD_MODEL_FROM_GEO(MODEL_LEVEL_GEOMETRY_03, rr_geo_000660), @@ -119,14 +119,14 @@ const LevelScript level_rr_entry[] = { LOAD_MODEL_FROM_GEO(MODEL_RR_TRICKY_TRIANGLES_FRAME4, rr_geo_0009B8), AREA(/*index*/ 1, rr_geo_0009D0), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 2599, -833, 2071, /*angle*/ 0, 90, 0, /*behParam*/ 0x000A0000, /*beh*/ bhvSpinAirborneWarp), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -7092, 2364, -63, /*angle*/ 0, 90, 0, /*behParam*/ 0x000B0000, /*beh*/ bhvFadingWarp), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -4213, 3379, -2815, /*angle*/ 0, 180, 0, /*behParam*/ 0x000C0000, /*beh*/ bhvFadingWarp), - WARP_NODE(/*id*/ 0x0A, /*destLevel*/ LEVEL_RR, /*destArea*/ 0x01, /*destNode*/ 0x0A, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0x0B, /*destLevel*/ LEVEL_RR, /*destArea*/ 0x01, /*destNode*/ 0x0C, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0x0C, /*destLevel*/ LEVEL_RR, /*destArea*/ 0x01, /*destNode*/ 0x0B, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0xF0, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x02, /*destNode*/ 0x3A, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0xF1, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x02, /*destNode*/ 0x6C, /*flags*/ WARP_NO_CHECKPOINT), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 2599, -833, 2071, /*angle*/ 0, 90, 0, /*bhvParam*/ BPARAM2(WARP_NODE_0A), /*bhv*/ bhvSpinAirborneWarp), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ -7092, 2364, -63, /*angle*/ 0, 90, 0, /*bhvParam*/ BPARAM2(WARP_NODE_0B), /*bhv*/ bhvFadingWarp), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ -4213, 3379, -2815, /*angle*/ 0, 180, 0, /*bhvParam*/ BPARAM2(WARP_NODE_0C), /*bhv*/ bhvFadingWarp), + WARP_NODE(/*id*/ WARP_NODE_0A, /*destLevel*/ LEVEL_RR, /*destArea*/ 1, /*destNode*/ WARP_NODE_0A, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_0B, /*destLevel*/ LEVEL_RR, /*destArea*/ 1, /*destNode*/ WARP_NODE_0C, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_0C, /*destLevel*/ LEVEL_RR, /*destArea*/ 1, /*destNode*/ WARP_NODE_0B, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_SUCCESS, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 2, /*destNode*/ WARP_NODE_3A, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_DEATH, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 2, /*destNode*/ WARP_NODE_6C, /*flags*/ WARP_NO_CHECKPOINT), JUMP_LINK(script_func_local_1), JUMP_LINK(script_func_local_2), JUMP_LINK(script_func_local_3), diff --git a/levels/rr/seesaw_platform/geo.inc.c b/levels/rr/seesaw_platform/geo.inc.c index c38957dc..42f993d3 100644 --- a/levels/rr/seesaw_platform/geo.inc.c +++ b/levels/rr/seesaw_platform/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000908 const GeoLayout rr_geo_000908[] = { - GEO_CULLING_RADIUS(1000), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, rr_seg7_dl_0701B4C0), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(1000), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, rr_seg7_dl_0701B4C0), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/rr/sliding_platform/geo.inc.c b/levels/rr/sliding_platform/geo.inc.c index 72c6adf6..df108a48 100644 --- a/levels/rr/sliding_platform/geo.inc.c +++ b/levels/rr/sliding_platform/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E0008C0 const GeoLayout rr_geo_0008C0[] = { - GEO_CULLING_RADIUS(700), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, rr_seg7_dl_0701ADF8), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(700), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, rr_seg7_dl_0701ADF8), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/rr/swinging_platform/geo.inc.c b/levels/rr/swinging_platform/geo.inc.c index 1b95ff07..34ba530e 100644 --- a/levels/rr/swinging_platform/geo.inc.c +++ b/levels/rr/swinging_platform/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000860 const GeoLayout rr_geo_000860[] = { - GEO_CULLING_RADIUS(1300), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, rr_seg7_dl_07019AE0), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(1300), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, rr_seg7_dl_07019AE0), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/rr/tricky_triangles_1/geo.inc.c b/levels/rr/tricky_triangles_1/geo.inc.c index 42a2d262..283e564e 100644 --- a/levels/rr/tricky_triangles_1/geo.inc.c +++ b/levels/rr/tricky_triangles_1/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000958 const GeoLayout rr_geo_000958[] = { - GEO_CULLING_RADIUS(1500), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, rr_seg7_dl_0701E670), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(1500), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, rr_seg7_dl_0701E670), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/rr/tricky_triangles_2/geo.inc.c b/levels/rr/tricky_triangles_2/geo.inc.c index 09f01b29..a5e0affe 100644 --- a/levels/rr/tricky_triangles_2/geo.inc.c +++ b/levels/rr/tricky_triangles_2/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000970 const GeoLayout rr_geo_000970[] = { - GEO_CULLING_RADIUS(1500), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, rr_seg7_dl_07021100), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(1500), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, rr_seg7_dl_07021100), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/rr/tricky_triangles_3/geo.inc.c b/levels/rr/tricky_triangles_3/geo.inc.c index 9dfc3b19..9614d9b6 100644 --- a/levels/rr/tricky_triangles_3/geo.inc.c +++ b/levels/rr/tricky_triangles_3/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000988 const GeoLayout rr_geo_000988[] = { - GEO_CULLING_RADIUS(1500), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, rr_seg7_dl_07023B90), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(1500), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, rr_seg7_dl_07023B90), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/rr/tricky_triangles_4/geo.inc.c b/levels/rr/tricky_triangles_4/geo.inc.c index 82f0816f..024c4653 100644 --- a/levels/rr/tricky_triangles_4/geo.inc.c +++ b/levels/rr/tricky_triangles_4/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E0009A0 const GeoLayout rr_geo_0009A0[] = { - GEO_CULLING_RADIUS(1500), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, rr_seg7_dl_07026630), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(1500), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, rr_seg7_dl_07026630), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/rr/tricky_triangles_5/geo.inc.c b/levels/rr/tricky_triangles_5/geo.inc.c index af1a02e6..bae47244 100644 --- a/levels/rr/tricky_triangles_5/geo.inc.c +++ b/levels/rr/tricky_triangles_5/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E0009B8 const GeoLayout rr_geo_0009B8[] = { - GEO_CULLING_RADIUS(1500), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, rr_seg7_dl_07028FA8), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(1500), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, rr_seg7_dl_07028FA8), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/sa/areas/1/geo.inc.c b/levels/sa/areas/1/geo.inc.c index 4920f408..702c3009 100644 --- a/levels/sa/areas/1/geo.inc.c +++ b/levels/sa/areas/1/geo.inc.c @@ -1,27 +1,27 @@ // 0x0E000170 const GeoLayout sa_geo_000170[] = { - GEO_NODE_SCREEN_AREA(10, SCREEN_WIDTH/2, SCREEN_HEIGHT/2, SCREEN_WIDTH/2, SCREEN_HEIGHT/2), - GEO_OPEN_NODE(), - GEO_ZBUFFER(0), - GEO_OPEN_NODE(), - GEO_NODE_ORTHO(100), - GEO_OPEN_NODE(), - GEO_BACKGROUND(BACKGROUND_BELOW_CLOUDS, geo_skybox_main), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ZBUFFER(1), - GEO_OPEN_NODE(), - GEO_CAMERA_FRUSTUM_WITH_FUNC(45, 100, 12800, geo_camera_fov), - GEO_OPEN_NODE(), - GEO_CAMERA(1, 0, 2000, 6000, 0, 0, 0, geo_camera_main), + GEO_NODE_SCREEN_AREA(10, SCREEN_WIDTH/2, SCREEN_HEIGHT/2, SCREEN_WIDTH/2, SCREEN_HEIGHT/2), + GEO_OPEN_NODE(), + GEO_ZBUFFER(0), + GEO_OPEN_NODE(), + GEO_NODE_ORTHO(100), GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, sa_seg7_dl_07002DE8), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, sa_seg7_dl_07002FD0), - GEO_RENDER_OBJ(), - GEO_ASM(2, geo_envfx_main), + GEO_BACKGROUND(BACKGROUND_BELOW_CLOUDS, geo_skybox_main), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CLOSE_NODE(), + GEO_ZBUFFER(1), + GEO_OPEN_NODE(), + GEO_CAMERA_FRUSTUM_WITH_FUNC(45, 100, 12800, geo_camera_fov), + GEO_OPEN_NODE(), + GEO_CAMERA(1, 0, 2000, 6000, 0, 0, 0, geo_camera_main), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, sa_seg7_dl_07002DE8), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, sa_seg7_dl_07002FD0), + GEO_RENDER_OBJ(), + GEO_ASM(2, geo_envfx_main), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/sa/areas/1/macro.inc.c b/levels/sa/areas/1/macro.inc.c index 99a81020..30d25936 100644 --- a/levels/sa/areas/1/macro.inc.c +++ b/levels/sa/areas/1/macro.inc.c @@ -1,21 +1,21 @@ // 0x07003284 - 0x07003330 const MacroObject sa_seg7_macro_objs[] = { - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -2400, -4607, -2400), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -2400, -4607, 2400), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 2400, -4607, 2400), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 2400, -4607, -2400), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 0, -2200, -1500), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -1500, -2200, 0), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 0, -2200, 1500), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 1500, -2200, 0), - MACRO_OBJECT(/*preset*/ macro_fish_group, /*yaw*/ 0, /*pos*/ 1927, -2909, 0), - MACRO_OBJECT(/*preset*/ macro_coin_ring_vertical, /*yaw*/ 90, /*pos*/ 0, -2400, -1500), - MACRO_OBJECT(/*preset*/ macro_coin_ring_vertical, /*yaw*/ 0, /*pos*/ -1500, -2400, 0), - MACRO_OBJECT(/*preset*/ macro_coin_ring_vertical, /*yaw*/ 90, /*pos*/ 0, -2400, 1500), - MACRO_OBJECT(/*preset*/ macro_coin_ring_vertical, /*yaw*/ 0, /*pos*/ 1500, -2400, 0), - MACRO_OBJECT(/*preset*/ macro_hidden_1up_trigger, /*yaw*/ 0, /*pos*/ 0, -3500, 0), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_hidden_1up, /*yaw*/ 0, /*pos*/ 0, -3800, 0, /*behParam*/ 1), - MACRO_OBJECT(/*preset*/ macro_coin_ring_horizontal_flying, /*yaw*/ 0, /*pos*/ 0, -3500, 0), - MACRO_OBJECT(/*preset*/ macro_fish_group_2, /*yaw*/ 0, /*pos*/ -1000, -4080, -1740), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -2400, -4607, -2400), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -2400, -4607, 2400), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 2400, -4607, 2400), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 2400, -4607, -2400), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 0, -2200, -1500), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -1500, -2200, 0), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 0, -2200, 1500), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 1500, -2200, 0), + MACRO_OBJECT (/*preset*/ macro_fish_spawner_few_blue, /*yaw*/ 0, /*pos*/ 1927, -2909, 0), + MACRO_OBJECT (/*preset*/ macro_coin_ring_vertical_flying, /*yaw*/ 90, /*pos*/ 0, -2400, -1500), + MACRO_OBJECT (/*preset*/ macro_coin_ring_vertical_flying, /*yaw*/ 0, /*pos*/ -1500, -2400, 0), + MACRO_OBJECT (/*preset*/ macro_coin_ring_vertical_flying, /*yaw*/ 90, /*pos*/ 0, -2400, 1500), + MACRO_OBJECT (/*preset*/ macro_coin_ring_vertical_flying, /*yaw*/ 0, /*pos*/ 1500, -2400, 0), + MACRO_OBJECT (/*preset*/ macro_hidden_1up_trigger, /*yaw*/ 0, /*pos*/ 0, -3500, 0), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_hidden_1up, /*yaw*/ 0, /*pos*/ 0, -3800, 0, /*bhvParam*/ 1), + MACRO_OBJECT (/*preset*/ macro_coin_ring_horizontal_flying, /*yaw*/ 0, /*pos*/ 0, -3500, 0), + MACRO_OBJECT (/*preset*/ macro_fish_spawner_few_cyan, /*yaw*/ 0, /*pos*/ -1000, -4080, -1740), MACRO_OBJECT_END(), }; diff --git a/levels/sa/leveldata.c b/levels/sa/leveldata.c index a36715ee..09d15e8c 100644 --- a/levels/sa/leveldata.c +++ b/levels/sa/leveldata.c @@ -3,8 +3,8 @@ #include "surface_terrains.h" #include "moving_texture_macros.h" #include "level_misc_macros.h" -#include "macro_preset_names.h" -#include "special_preset_names.h" +#include "macro_presets.h" +#include "special_presets.h" #include "textures.h" #include "make_const_nonconst.h" diff --git a/levels/sa/script.c b/levels/sa/script.c index 264d5825..75c81dbf 100644 --- a/levels/sa/script.c +++ b/levels/sa/script.c @@ -16,36 +16,36 @@ #include "levels/sa/header.h" static const LevelScript script_func_local_1[] = { - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 0, -1000, 0, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvFishSpawner), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 0, -1000, 0, /*angle*/ 0, 0, 0, /*behParam*/ 0x00020000, /*beh*/ bhvFishSpawner), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 0, -1000, 0, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(FISH_SPAWNER_BP_MANY_BLUE), /*bhv*/ bhvFishSpawner), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 0, -1000, 0, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(FISH_SPAWNER_BP_MANY_CYAN), /*bhv*/ bhvFishSpawner), RETURN(), }; static const LevelScript script_func_local_2[] = { - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 0, -4250, 0, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvHiddenRedCoinStar), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 0, -4250, 0, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(STAR_INDEX_ACT_1), /*bhv*/ bhvHiddenRedCoinStar), RETURN(), }; const LevelScript level_sa_entry[] = { INIT_LEVEL(), - LOAD_MIO0( /*seg*/ 0x07, _sa_segment_7SegmentRomStart, _sa_segment_7SegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x07, _sa_segment_7SegmentRomStart, _sa_segment_7SegmentRomEnd), LOAD_MIO0_TEXTURE(/*seg*/ 0x09, _inside_mio0SegmentRomStart, _inside_mio0SegmentRomEnd), - LOAD_MIO0( /*seg*/ 0x0A, _cloud_floor_skybox_mio0SegmentRomStart, _cloud_floor_skybox_mio0SegmentRomEnd), - LOAD_MIO0( /*seg*/ 0x0B, _effect_mio0SegmentRomStart, _effect_mio0SegmentRomEnd), - LOAD_MIO0( /*seg*/ 0x05, _group4_mio0SegmentRomStart, _group4_mio0SegmentRomEnd), - LOAD_RAW( /*seg*/ 0x0C, _group4_geoSegmentRomStart, _group4_geoSegmentRomEnd), - LOAD_MIO0( /*seg*/ 0x06, _group13_mio0SegmentRomStart, _group13_mio0SegmentRomEnd), - LOAD_RAW( /*seg*/ 0x0D, _group13_geoSegmentRomStart, _group13_geoSegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x0A, _cloud_floor_skybox_mio0SegmentRomStart, _cloud_floor_skybox_mio0SegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x0B, _effect_mio0SegmentRomStart, _effect_mio0SegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x05, _group4_mio0SegmentRomStart, _group4_mio0SegmentRomEnd), + LOAD_RAW (/*seg*/ 0x0C, _group4_geoSegmentRomStart, _group4_geoSegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x06, _group13_mio0SegmentRomStart, _group13_mio0SegmentRomEnd), + LOAD_RAW (/*seg*/ 0x0D, _group13_geoSegmentRomStart, _group13_geoSegmentRomEnd), ALLOC_LEVEL_POOL(), - MARIO(/*model*/ MODEL_MARIO, /*behParam*/ 0x00000001, /*beh*/ bhvMario), + MARIO(/*model*/ MODEL_MARIO, /*bhvParam*/ BPARAM4(0x01), /*bhv*/ bhvMario), JUMP_LINK(script_func_global_5), JUMP_LINK(script_func_global_14), AREA(/*index*/ 1, sa_geo_000170), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 0, -1535, 0, /*angle*/ 0, 90, 0, /*behParam*/ 0x000A0000, /*beh*/ bhvSwimmingWarp), - WARP_NODE(/*id*/ 0x0A, /*destLevel*/ LEVEL_SA, /*destArea*/ 0x01, /*destNode*/ 0x0A, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0xF0, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x01, /*destNode*/ 0x27, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0xF1, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x01, /*destNode*/ 0x28, /*flags*/ WARP_NO_CHECKPOINT), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 0, -1535, 0, /*angle*/ 0, 90, 0, /*bhvParam*/ BPARAM2(WARP_NODE_0A), /*bhv*/ bhvSwimmingWarp), + WARP_NODE(/*id*/ WARP_NODE_0A, /*destLevel*/ LEVEL_SA, /*destArea*/ 1, /*destNode*/ WARP_NODE_0A, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_SUCCESS, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 1, /*destNode*/ WARP_NODE_27, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_DEATH, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 1, /*destNode*/ WARP_NODE_28, /*flags*/ WARP_NO_CHECKPOINT), JUMP_LINK(script_func_local_1), JUMP_LINK(script_func_local_2), TERRAIN(/*terrainData*/ sa_seg7_collision), diff --git a/levels/scripts.c b/levels/scripts.c index 248fb83c..a4d51bcd 100644 --- a/levels/scripts.c +++ b/levels/scripts.c @@ -61,9 +61,9 @@ static const LevelScript script_L5[4]; const LevelScript level_main_scripts_entry[] = { LOAD_MIO0(/*seg*/ 0x04, _group0_mio0SegmentRomStart, _group0_mio0SegmentRomEnd), LOAD_MIO0(/*seg*/ 0x03, _common1_mio0SegmentRomStart, _common1_mio0SegmentRomEnd), - LOAD_RAW( /*seg*/ 0x17, _group0_geoSegmentRomStart, _group0_geoSegmentRomEnd), - LOAD_RAW( /*seg*/ 0x16, _common1_geoSegmentRomStart, _common1_geoSegmentRomEnd), - LOAD_RAW( /*seg*/ 0x13, _behaviorSegmentRomStart, _behaviorSegmentRomEnd), + LOAD_RAW (/*seg*/ 0x17, _group0_geoSegmentRomStart, _group0_geoSegmentRomEnd), + LOAD_RAW (/*seg*/ 0x16, _common1_geoSegmentRomStart, _common1_geoSegmentRomEnd), + LOAD_RAW (/*seg*/ 0x13, _behaviorSegmentRomStart, _behaviorSegmentRomEnd), ALLOC_LEVEL_POOL(), LOAD_MODEL_FROM_GEO(MODEL_MARIO, mario_geo), LOAD_MODEL_FROM_GEO(MODEL_SMOKE, smoke_geo), @@ -77,7 +77,7 @@ const LevelScript level_main_scripts_entry[] = { LOAD_MODEL_FROM_GEO(MODEL_STAR, star_geo), LOAD_MODEL_FROM_GEO(MODEL_TRANSPARENT_STAR, transparent_star_geo), LOAD_MODEL_FROM_GEO(MODEL_WOODEN_SIGNPOST, wooden_signpost_geo), - LOAD_MODEL_FROM_DL( MODEL_WHITE_PARTICLE_SMALL, white_particle_small_dl, LAYER_ALPHA), + LOAD_MODEL_FROM_DL (MODEL_WHITE_PARTICLE_SMALL, white_particle_small_dl, LAYER_ALPHA), LOAD_MODEL_FROM_GEO(MODEL_RED_FLAME, red_flame_geo), LOAD_MODEL_FROM_GEO(MODEL_BLUE_FLAME, blue_flame_geo), LOAD_MODEL_FROM_GEO(MODEL_BURN_SMOKE, burn_smoke_geo), @@ -86,13 +86,13 @@ const LevelScript level_main_scripts_entry[] = { LOAD_MODEL_FROM_GEO(MODEL_FISH, fish_geo), LOAD_MODEL_FROM_GEO(MODEL_FISH_SHADOW, fish_shadow_geo), LOAD_MODEL_FROM_GEO(MODEL_SPARKLES_ANIMATION, sparkles_animation_geo), - LOAD_MODEL_FROM_DL( MODEL_SAND_DUST, sand_seg3_dl_0302BCD0, LAYER_ALPHA), + LOAD_MODEL_FROM_DL (MODEL_SAND_DUST, sand_seg3_dl_0302BCD0, LAYER_ALPHA), LOAD_MODEL_FROM_GEO(MODEL_BUTTERFLY, butterfly_geo), LOAD_MODEL_FROM_GEO(MODEL_BURN_SMOKE_UNUSED, burn_smoke_geo), - LOAD_MODEL_FROM_DL( MODEL_PEBBLE, pebble_seg3_dl_0301CB00, LAYER_ALPHA), + LOAD_MODEL_FROM_DL (MODEL_PEBBLE, pebble_seg3_dl_0301CB00, LAYER_ALPHA), LOAD_MODEL_FROM_GEO(MODEL_MIST, mist_geo), LOAD_MODEL_FROM_GEO(MODEL_WHITE_PUFF, white_puff_geo), - LOAD_MODEL_FROM_DL( MODEL_WHITE_PARTICLE_DL, white_particle_dl, LAYER_ALPHA), + LOAD_MODEL_FROM_DL (MODEL_WHITE_PARTICLE_DL, white_particle_dl, LAYER_ALPHA), LOAD_MODEL_FROM_GEO(MODEL_WHITE_PARTICLE, white_particle_geo), LOAD_MODEL_FROM_GEO(MODEL_YELLOW_COIN_NO_SHADOW, yellow_coin_no_shadow_geo), LOAD_MODEL_FROM_GEO(MODEL_BLUE_COIN, blue_coin_geo), @@ -179,20 +179,20 @@ const LevelScript script_func_global_1[] = { LOAD_MODEL_FROM_GEO(MODEL_EXCLAMATION_BOX_OUTLINE, exclamation_box_outline_geo), LOAD_MODEL_FROM_GEO(MODEL_EXCLAMATION_BOX, exclamation_box_geo), LOAD_MODEL_FROM_GEO(MODEL_GOOMBA, goomba_geo), - LOAD_MODEL_FROM_DL( MODEL_EXCLAMATION_POINT, exclamation_box_outline_seg8_dl_08025F08, LAYER_ALPHA), + LOAD_MODEL_FROM_DL (MODEL_EXCLAMATION_POINT, exclamation_box_outline_seg8_dl_08025F08, LAYER_ALPHA), LOAD_MODEL_FROM_GEO(MODEL_KOOPA_SHELL, koopa_shell_geo), LOAD_MODEL_FROM_GEO(MODEL_METAL_BOX, metal_box_geo), - LOAD_MODEL_FROM_DL( MODEL_METAL_BOX_DL, metal_box_dl, LAYER_OPAQUE), + LOAD_MODEL_FROM_DL (MODEL_METAL_BOX_DL, metal_box_dl, LAYER_OPAQUE), LOAD_MODEL_FROM_GEO(MODEL_BLACK_BOBOMB, black_bobomb_geo), LOAD_MODEL_FROM_GEO(MODEL_BOBOMB_BUDDY, bobomb_buddy_geo), - LOAD_MODEL_FROM_DL( MODEL_DL_CANNON_LID, cannon_lid_seg8_dl_080048E0, LAYER_OPAQUE), + LOAD_MODEL_FROM_DL (MODEL_DL_CANNON_LID, cannon_lid_seg8_dl_080048E0, LAYER_OPAQUE), LOAD_MODEL_FROM_GEO(MODEL_BOWLING_BALL, bowling_ball_geo), LOAD_MODEL_FROM_GEO(MODEL_CANNON_BARREL, cannon_barrel_geo), LOAD_MODEL_FROM_GEO(MODEL_CANNON_BASE, cannon_base_geo), LOAD_MODEL_FROM_GEO(MODEL_HEART, heart_geo), LOAD_MODEL_FROM_GEO(MODEL_FLYGUY, flyguy_geo), LOAD_MODEL_FROM_GEO(MODEL_CHUCKYA, chuckya_geo), - LOAD_MODEL_FROM_GEO(MODEL_TRAJECTORY_MARKER_BALL, bowling_ball_track_geo), + LOAD_MODEL_FROM_GEO(MODEL_TRAJECTORY_MARKER_BALL, bowling_ball_track_geo), RETURN(), }; @@ -224,7 +224,7 @@ const LevelScript script_func_global_5[] = { LOAD_MODEL_FROM_GEO(MODEL_MANTA_RAY, manta_seg5_geo_05008D14), LOAD_MODEL_FROM_GEO(MODEL_UNAGI, unagi_geo), LOAD_MODEL_FROM_GEO(MODEL_SUSHI, sushi_geo), - LOAD_MODEL_FROM_DL( MODEL_DL_WHIRLPOOL, whirlpool_seg5_dl_05013CB8, LAYER_TRANSPARENT), + LOAD_MODEL_FROM_DL (MODEL_DL_WHIRLPOOL, whirlpool_seg5_dl_05013CB8, LAYER_TRANSPARENT), LOAD_MODEL_FROM_GEO(MODEL_CLAM_SHELL, clam_shell_geo), RETURN(), }; @@ -240,7 +240,7 @@ const LevelScript script_func_global_6[] = { }; const LevelScript script_func_global_7[] = { - LOAD_MODEL_FROM_DL( MODEL_DL_MONTY_MOLE_HOLE, monty_mole_hole_seg5_dl_05000840, LAYER_TRANSPARENT_DECAL), + LOAD_MODEL_FROM_DL (MODEL_DL_MONTY_MOLE_HOLE, monty_mole_hole_seg5_dl_05000840, LAYER_TRANSPARENT_DECAL), LOAD_MODEL_FROM_GEO(MODEL_MONTY_MOLE, monty_mole_geo), LOAD_MODEL_FROM_GEO(MODEL_UKIKI, ukiki_geo), LOAD_MODEL_FROM_GEO(MODEL_FWOOSH, fwoosh_geo), @@ -256,15 +256,15 @@ const LevelScript script_func_global_8[] = { }; const LevelScript script_func_global_9[] = { - LOAD_MODEL_FROM_DL( MODEL_CAP_SWITCH_EXCLAMATION, cap_switch_exclamation_seg5_dl_05002E00, LAYER_ALPHA), + LOAD_MODEL_FROM_DL (MODEL_CAP_SWITCH_EXCLAMATION, cap_switch_exclamation_seg5_dl_05002E00, LAYER_ALPHA), LOAD_MODEL_FROM_GEO(MODEL_CAP_SWITCH, cap_switch_geo), - LOAD_MODEL_FROM_DL( MODEL_CAP_SWITCH_BASE, cap_switch_base_seg5_dl_05003120, LAYER_OPAQUE), + LOAD_MODEL_FROM_DL (MODEL_CAP_SWITCH_BASE, cap_switch_base_seg5_dl_05003120, LAYER_OPAQUE), RETURN(), }; const LevelScript script_func_global_10[] = { LOAD_MODEL_FROM_GEO(MODEL_BOO, boo_geo), - LOAD_MODEL_FROM_GEO(MODEL_BETA_BOO_KEY, small_key_geo), + LOAD_MODEL_FROM_GEO(MODEL_BETA_BOO_KEY, small_key_geo), LOAD_MODEL_FROM_GEO(MODEL_HAUNTED_CHAIR, haunted_chair_geo), LOAD_MODEL_FROM_GEO(MODEL_MAD_PIANO, mad_piano_geo), LOAD_MODEL_FROM_GEO(MODEL_BOOKEND_PART, bookend_part_geo), diff --git a/levels/sl/areas/1/geo.inc.c b/levels/sl/areas/1/geo.inc.c index 0631851d..58461634 100644 --- a/levels/sl/areas/1/geo.inc.c +++ b/levels/sl/areas/1/geo.inc.c @@ -1,38 +1,38 @@ // 0x0E0003A8 const GeoLayout sl_geo_0003A8[] = { - GEO_NODE_SCREEN_AREA(10, SCREEN_WIDTH/2, SCREEN_HEIGHT/2, SCREEN_WIDTH/2, SCREEN_HEIGHT/2), - GEO_OPEN_NODE(), - GEO_ZBUFFER(0), - GEO_OPEN_NODE(), - GEO_NODE_ORTHO(100), - GEO_OPEN_NODE(), - GEO_BACKGROUND(BACKGROUND_SNOW_MOUNTAINS, geo_skybox_main), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ZBUFFER(1), - GEO_OPEN_NODE(), - GEO_CAMERA_FRUSTUM_WITH_FUNC(45, 100, 20000, geo_camera_fov), - GEO_OPEN_NODE(), - GEO_CAMERA(16, 0, 2000, 6000, 0, 4400, 0, geo_camera_main), + GEO_NODE_SCREEN_AREA(10, SCREEN_WIDTH/2, SCREEN_HEIGHT/2, SCREEN_WIDTH/2, SCREEN_HEIGHT/2), + GEO_OPEN_NODE(), + GEO_ZBUFFER(0), + GEO_OPEN_NODE(), + GEO_NODE_ORTHO(100), GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, sl_seg7_dl_07005478), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, sl_seg7_dl_070056B0), - GEO_DISPLAY_LIST(LAYER_OPAQUE, sl_seg7_dl_070073D0), - GEO_DISPLAY_LIST(LAYER_ALPHA, sl_seg7_dl_07007880), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, sl_seg7_dl_070088B0), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT_DECAL, sl_seg7_dl_07008D58), - GEO_DISPLAY_LIST(LAYER_OPAQUE, sl_seg7_dl_0700A5A0), - GEO_ASM( 0, geo_movtex_pause_control), - GEO_ASM(0x1001, geo_movtex_draw_water_regions), - GEO_RENDER_OBJ(), - GEO_ASM( 1, geo_envfx_main), + GEO_BACKGROUND(BACKGROUND_SNOW_MOUNTAINS, geo_skybox_main), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ZBUFFER(0), - GEO_OPEN_NODE(), - GEO_ASM(0, geo_cannon_circle_base), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CLOSE_NODE(), + GEO_ZBUFFER(1), + GEO_OPEN_NODE(), + GEO_CAMERA_FRUSTUM_WITH_FUNC(45, 100, 20000, geo_camera_fov), + GEO_OPEN_NODE(), + GEO_CAMERA(16, 0, 2000, 6000, 0, 4400, 0, geo_camera_main), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, sl_seg7_dl_07005478), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, sl_seg7_dl_070056B0), + GEO_DISPLAY_LIST(LAYER_OPAQUE, sl_seg7_dl_070073D0), + GEO_DISPLAY_LIST(LAYER_ALPHA, sl_seg7_dl_07007880), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, sl_seg7_dl_070088B0), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT_DECAL, sl_seg7_dl_07008D58), + GEO_DISPLAY_LIST(LAYER_OPAQUE, sl_seg7_dl_0700A5A0), + GEO_ASM( 0, geo_movtex_pause_control), + GEO_ASM(0x1001, geo_movtex_draw_water_regions), + GEO_RENDER_OBJ(), + GEO_ASM( 1, geo_envfx_main), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ZBUFFER(0), + GEO_OPEN_NODE(), + GEO_ASM(0, geo_cannon_circle_base), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/sl/areas/1/macro.inc.c b/levels/sl/areas/1/macro.inc.c index d75dac18..6b414b4c 100644 --- a/levels/sl/areas/1/macro.inc.c +++ b/levels/sl/areas/1/macro.inc.c @@ -1,51 +1,51 @@ // 0x0700ED94 - 0x0700EF6C const MacroObject sl_seg7_area_1_macro_objs[] = { - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 90, /*pos*/ 4086, 1024, 400, /*behParam*/ DIALOG_086), - MACRO_OBJECT(/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ 1285, 2210, 385), - MACRO_OBJECT(/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ 1728, 2560, -671), - MACRO_OBJECT(/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ 1371, 2188, -500), - MACRO_OBJECT(/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ 1814, 3174, 114), - MACRO_OBJECT(/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ 28, 3328, 1885), - MACRO_OBJECT(/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ -228, 3482, 1742), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_cannon_closed, /*yaw*/ 0, /*pos*/ 4483, 821, 1168, /*behParam*/ 0x80), - MACRO_OBJECT(/*preset*/ macro_mr_blizzard, /*yaw*/ 0, /*pos*/ -3452, 1110, -3364), - MACRO_OBJECT(/*preset*/ macro_mr_blizzard, /*yaw*/ 0, /*pos*/ 5422, 1065, -1288), - MACRO_OBJECT(/*preset*/ macro_mr_blizzard, /*yaw*/ 0, /*pos*/ -6533, 2048, -2444), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 4750, 1061, -5230), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 416, 1050, -4522), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -6560, 2040, -5080), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -6760, 2040, -1360), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -6880, 1857, 1000), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -4211, 1092, -4723), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -6271, 1390, 4764), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -529, 1050, -5329), - MACRO_OBJECT(/*preset*/ macro_spindrift, /*yaw*/ 0, /*pos*/ -3760, 1120, 1240), - MACRO_OBJECT(/*preset*/ macro_spindrift, /*yaw*/ 0, /*pos*/ 3840, 1240, -5280), - MACRO_OBJECT(/*preset*/ macro_spindrift, /*yaw*/ 0, /*pos*/ -3440, 1400, -40), - MACRO_OBJECT(/*preset*/ macro_spindrift, /*yaw*/ 0, /*pos*/ 400, 1060, 5860), - MACRO_OBJECT(/*preset*/ macro_spindrift, /*yaw*/ 0, /*pos*/ 880, 1080, 4860), - MACRO_OBJECT(/*preset*/ macro_spindrift, /*yaw*/ 0, /*pos*/ 1400, 1080, 3860), - MACRO_OBJECT(/*preset*/ macro_spindrift, /*yaw*/ 0, /*pos*/ 3400, 1660, -2920), - MACRO_OBJECT(/*preset*/ macro_spindrift, /*yaw*/ 0, /*pos*/ -3171, 1075, -4765), - MACRO_OBJECT(/*preset*/ macro_spindrift, /*yaw*/ 0, /*pos*/ -4241, 1009, -3834), - MACRO_OBJECT(/*preset*/ macro_box_koopa_shell, /*yaw*/ 0, /*pos*/ -5450, 1300, 5900), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_circling_amp, /*yaw*/ 0, /*pos*/ 4060, 900, -2940, /*behParam*/ 0), - MACRO_OBJECT(/*preset*/ macro_spindrift, /*yaw*/ 0, /*pos*/ -4096, 1125, 3062), - MACRO_OBJECT(/*preset*/ macro_spindrift, /*yaw*/ 0, /*pos*/ -4536, 1125, 3782), - MACRO_OBJECT(/*preset*/ macro_coin_line_horizontal, /*yaw*/ 65, /*pos*/ -660, 2120, 1340), - MACRO_OBJECT(/*preset*/ macro_yellow_coin, /*yaw*/ 0, /*pos*/ -1520, 1040, 940), - MACRO_OBJECT(/*preset*/ macro_yellow_coin, /*yaw*/ 0, /*pos*/ -1340, 1280, 1020), - MACRO_OBJECT(/*preset*/ macro_yellow_coin, /*yaw*/ 0, /*pos*/ -1180, 1520, 1120), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 295, /*pos*/ -835, 1125, -3856, /*behParam*/ DIALOG_061), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 180, /*pos*/ -5050, 1020, 6026, /*behParam*/ DIALOG_016), - MACRO_OBJECT(/*preset*/ macro_fly_guy, /*yaw*/ 0, /*pos*/ 2766, 1522, -3633), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 135, /*pos*/ -3600, 1024, -800, /*behParam*/ DIALOG_148), - MACRO_OBJECT(/*preset*/ macro_moneybag, /*yaw*/ 0, /*pos*/ 2440, 1024, 4840), - MACRO_OBJECT(/*preset*/ macro_moneybag, /*yaw*/ 0, /*pos*/ -2400, 1177, -4200), - MACRO_OBJECT(/*preset*/ macro_box_1up_running_away, /*yaw*/ 0, /*pos*/ -3380, 1360, -4140), - MACRO_OBJECT(/*preset*/ macro_box_star_4, /*yaw*/ 0, /*pos*/ -4700, 1300, 5850), - MACRO_OBJECT(/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ 2909, 1024, 4245), - MACRO_OBJECT(/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ 3418, 1024, 3554), - MACRO_OBJECT(/*preset*/ macro_hidden_1up_in_pole, /*yaw*/ 0, /*pos*/ 0, 5420, 0), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 90, /*pos*/ 4086, 1024, 400, /*bhvParam*/ DIALOG_086), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ 1285, 2210, 385), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ 1728, 2560, -671), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ 1371, 2188, -500), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ 1814, 3174, 114), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ 28, 3328, 1885), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ -228, 3482, 1742), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_cannon_closed, /*yaw*/ 0, /*pos*/ 4483, 821, 1168, /*bhvParam*/ 0x80), + MACRO_OBJECT (/*preset*/ macro_mr_blizzard_1, /*yaw*/ 0, /*pos*/ -3452, 1110, -3364), + MACRO_OBJECT (/*preset*/ macro_mr_blizzard_1, /*yaw*/ 0, /*pos*/ 5422, 1065, -1288), + MACRO_OBJECT (/*preset*/ macro_mr_blizzard_1, /*yaw*/ 0, /*pos*/ -6533, 2048, -2444), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 4750, 1061, -5230), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 416, 1050, -4522), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -6560, 2040, -5080), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -6760, 2040, -1360), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -6880, 1857, 1000), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -4211, 1092, -4723), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -6271, 1390, 4764), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -529, 1050, -5329), + MACRO_OBJECT (/*preset*/ macro_spindrift, /*yaw*/ 0, /*pos*/ -3760, 1120, 1240), + MACRO_OBJECT (/*preset*/ macro_spindrift, /*yaw*/ 0, /*pos*/ 3840, 1240, -5280), + MACRO_OBJECT (/*preset*/ macro_spindrift, /*yaw*/ 0, /*pos*/ -3440, 1400, -40), + MACRO_OBJECT (/*preset*/ macro_spindrift, /*yaw*/ 0, /*pos*/ 400, 1060, 5860), + MACRO_OBJECT (/*preset*/ macro_spindrift, /*yaw*/ 0, /*pos*/ 880, 1080, 4860), + MACRO_OBJECT (/*preset*/ macro_spindrift, /*yaw*/ 0, /*pos*/ 1400, 1080, 3860), + MACRO_OBJECT (/*preset*/ macro_spindrift, /*yaw*/ 0, /*pos*/ 3400, 1660, -2920), + MACRO_OBJECT (/*preset*/ macro_spindrift, /*yaw*/ 0, /*pos*/ -3171, 1075, -4765), + MACRO_OBJECT (/*preset*/ macro_spindrift, /*yaw*/ 0, /*pos*/ -4241, 1009, -3834), + MACRO_OBJECT (/*preset*/ macro_box_koopa_shell, /*yaw*/ 0, /*pos*/ -5450, 1300, 5900), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_circling_amp, /*yaw*/ 0, /*pos*/ 4060, 900, -2940, /*bhvParam*/ AMP_BP_ROT_RADIUS_200), + MACRO_OBJECT (/*preset*/ macro_spindrift, /*yaw*/ 0, /*pos*/ -4096, 1125, 3062), + MACRO_OBJECT (/*preset*/ macro_spindrift, /*yaw*/ 0, /*pos*/ -4536, 1125, 3782), + MACRO_OBJECT (/*preset*/ macro_coin_line_horizontal, /*yaw*/ 65, /*pos*/ -660, 2120, 1340), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_1, /*yaw*/ 0, /*pos*/ -1520, 1040, 940), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_1, /*yaw*/ 0, /*pos*/ -1340, 1280, 1020), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_1, /*yaw*/ 0, /*pos*/ -1180, 1520, 1120), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 295, /*pos*/ -835, 1125, -3856, /*bhvParam*/ DIALOG_061), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 180, /*pos*/ -5050, 1020, 6026, /*bhvParam*/ DIALOG_016), + MACRO_OBJECT (/*preset*/ macro_fly_guy, /*yaw*/ 0, /*pos*/ 2766, 1522, -3633), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 135, /*pos*/ -3600, 1024, -800, /*bhvParam*/ DIALOG_148), + MACRO_OBJECT (/*preset*/ macro_moneybag, /*yaw*/ 0, /*pos*/ 2440, 1024, 4840), + MACRO_OBJECT (/*preset*/ macro_moneybag, /*yaw*/ 0, /*pos*/ -2400, 1177, -4200), + MACRO_OBJECT (/*preset*/ macro_box_1up_running_away, /*yaw*/ 0, /*pos*/ -3380, 1360, -4140), + MACRO_OBJECT (/*preset*/ macro_box_star_act_4, /*yaw*/ 0, /*pos*/ -4700, 1300, 5850), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ 2909, 1024, 4245), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ 3418, 1024, 3554), + MACRO_OBJECT (/*preset*/ macro_hidden_1up_in_pole, /*yaw*/ 0, /*pos*/ 0, 5420, 0), MACRO_OBJECT_END(), }; diff --git a/levels/sl/areas/2/geo.inc.c b/levels/sl/areas/2/geo.inc.c index 1cef0cad..dca91dc1 100644 --- a/levels/sl/areas/2/geo.inc.c +++ b/levels/sl/areas/2/geo.inc.c @@ -1,29 +1,29 @@ // 0x0E000484 const GeoLayout sl_geo_000484[] = { - GEO_NODE_SCREEN_AREA(10, SCREEN_WIDTH/2, SCREEN_HEIGHT/2, SCREEN_WIDTH/2, SCREEN_HEIGHT/2), - GEO_OPEN_NODE(), - GEO_ZBUFFER(0), - GEO_OPEN_NODE(), - GEO_NODE_ORTHO(100), - GEO_OPEN_NODE(), - GEO_BACKGROUND_COLOR(0x0001), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ZBUFFER(1), - GEO_OPEN_NODE(), - GEO_CAMERA_FRUSTUM_WITH_FUNC(45, 100, 12800, geo_camera_fov), - GEO_OPEN_NODE(), - GEO_CAMERA(4, 0, 2000, 6000, 0, 0, 0, geo_camera_main), + GEO_NODE_SCREEN_AREA(10, SCREEN_WIDTH/2, SCREEN_HEIGHT/2, SCREEN_WIDTH/2, SCREEN_HEIGHT/2), + GEO_OPEN_NODE(), + GEO_ZBUFFER(0), + GEO_OPEN_NODE(), + GEO_NODE_ORTHO(100), GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, sl_seg7_dl_0700BAE8), - GEO_DISPLAY_LIST(LAYER_OPAQUE, sl_seg7_dl_0700BCF8), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, sl_seg7_dl_0700C9E8), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, sl_seg7_dl_0700CB58), - GEO_RENDER_OBJ(), - GEO_ASM(0, geo_envfx_main), + GEO_BACKGROUND_COLOR(0x0001), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CLOSE_NODE(), + GEO_ZBUFFER(1), + GEO_OPEN_NODE(), + GEO_CAMERA_FRUSTUM_WITH_FUNC(45, 100, 12800, geo_camera_fov), + GEO_OPEN_NODE(), + GEO_CAMERA(4, 0, 2000, 6000, 0, 0, 0, geo_camera_main), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, sl_seg7_dl_0700BAE8), + GEO_DISPLAY_LIST(LAYER_OPAQUE, sl_seg7_dl_0700BCF8), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, sl_seg7_dl_0700C9E8), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, sl_seg7_dl_0700CB58), + GEO_RENDER_OBJ(), + GEO_ASM(0, geo_envfx_main), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/sl/areas/2/macro.inc.c b/levels/sl/areas/2/macro.inc.c index 7603edc1..7ca9b3f3 100644 --- a/levels/sl/areas/2/macro.inc.c +++ b/levels/sl/areas/2/macro.inc.c @@ -7,7 +7,7 @@ const MacroObject sl_seg7_area_2_macro_objs[] = { MACRO_OBJECT(/*preset*/ macro_spindrift, /*yaw*/ 0, /*pos*/ 1600, 80, -800), MACRO_OBJECT(/*preset*/ macro_box_vanish_cap, /*yaw*/ 0, /*pos*/ 1660, 300, -1720), MACRO_OBJECT(/*preset*/ macro_box_three_coins, /*yaw*/ 0, /*pos*/ -720, 300, -1740), - MACRO_OBJECT(/*preset*/ macro_bobomb_buddy_opens_cannon, /*yaw*/ 0, /*pos*/ -1400, 0, -1740), + MACRO_OBJECT(/*preset*/ macro_bobomb_buddy_opens_cannon_1, /*yaw*/ 0, /*pos*/ -1400, 0, -1740), MACRO_OBJECT(/*preset*/ macro_goomba, /*yaw*/ 0, /*pos*/ -20, 0, 960), MACRO_OBJECT(/*preset*/ macro_goomba, /*yaw*/ 0, /*pos*/ 320, 0, -1220), MACRO_OBJECT(/*preset*/ macro_spindrift, /*yaw*/ 0, /*pos*/ -860, 40, 2040), diff --git a/levels/sl/leveldata.c b/levels/sl/leveldata.c index c7132a5a..d96a6a9c 100644 --- a/levels/sl/leveldata.c +++ b/levels/sl/leveldata.c @@ -3,8 +3,8 @@ #include "surface_terrains.h" #include "moving_texture_macros.h" #include "level_misc_macros.h" -#include "macro_preset_names.h" -#include "special_preset_names.h" +#include "macro_presets.h" +#include "special_presets.h" #include "textures.h" #include "dialog_ids.h" diff --git a/levels/sl/script.c b/levels/sl/script.c index 47e1338c..350940ec 100644 --- a/levels/sl/script.c +++ b/levels/sl/script.c @@ -17,69 +17,69 @@ static const LevelScript script_func_local_1[] = { - OBJECT_WITH_ACTS(/*model*/ MODEL_STAR, /*pos*/ 700, 4500, 690, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvStar, /*acts*/ ALL_ACTS), - OBJECT_WITH_ACTS(/*model*/ MODEL_STAR, /*pos*/ 4350, 1350, 4350, /*angle*/ 0, 0, 0, /*behParam*/ 0x02000000, /*beh*/ bhvStar, /*acts*/ ALL_ACTS), - OBJECT_WITH_ACTS(/*model*/ MODEL_NONE, /*pos*/ 5000, 1200, 0, /*angle*/ 0, 0, 0, /*behParam*/ 0x04000000, /*beh*/ bhvHiddenRedCoinStar, /*acts*/ ALL_ACTS), + OBJECT_WITH_ACTS(/*model*/ MODEL_STAR, /*pos*/ 700, 4500, 690, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(STAR_INDEX_ACT_1), /*bhv*/ bhvStar, /*acts*/ ALL_ACTS), + OBJECT_WITH_ACTS(/*model*/ MODEL_STAR, /*pos*/ 4350, 1350, 4350, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(STAR_INDEX_ACT_3), /*bhv*/ bhvStar, /*acts*/ ALL_ACTS), + OBJECT_WITH_ACTS(/*model*/ MODEL_NONE, /*pos*/ 5000, 1200, 0, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(STAR_INDEX_ACT_5), /*bhv*/ bhvHiddenRedCoinStar, /*acts*/ ALL_ACTS), RETURN(), }; static const LevelScript script_func_local_2[] = { - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 977, 1024, 2075, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvSnowMoundSpawn), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 977, 1024, 2075, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvSnowMoundSpawn), RETURN(), }; static const LevelScript script_func_local_3[] = { - OBJECT(/*model*/ MODEL_PENGUIN, /*pos*/ 1715, 3328, 518, /*angle*/ 0, -51, 0, /*behParam*/ 0x00000000, /*beh*/ bhvSLWalkingPenguin), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 700, 3428, 700, /*angle*/ 0, 30, 0, /*behParam*/ 0x00000000, /*beh*/ bhvSLSnowmanWind), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 480, 2300, 1370, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvIgloo), - OBJECT(/*model*/ MODEL_BIG_CHILL_BULLY, /*pos*/ 315, 1331, -4852, /*angle*/ 0, 0, 0, /*behParam*/ 0x01000000, /*beh*/ bhvBigChillBully), - OBJECT(/*model*/ MODEL_MR_BLIZZARD_HIDDEN, /*pos*/ 2954, 970, 750, /*angle*/ 0, 0, 0, /*behParam*/ 0x00020000, /*beh*/ bhvMrBlizzard), + OBJECT(/*model*/ MODEL_PENGUIN, /*pos*/ 1715, 3328, 518, /*angle*/ 0, -51, 0, /*bhvParam*/ 0, /*bhv*/ bhvSLWalkingPenguin), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 700, 3428, 700, /*angle*/ 0, 30, 0, /*bhvParam*/ 0, /*bhv*/ bhvSLSnowmanWind), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 480, 2300, 1370, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvIgloo), + OBJECT(/*model*/ MODEL_BIG_CHILL_BULLY, /*pos*/ 315, 1331, -4852, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(STAR_INDEX_ACT_2), /*bhv*/ bhvBigChillBully), + OBJECT(/*model*/ MODEL_MR_BLIZZARD_HIDDEN, /*pos*/ 2954, 970, 750, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(MR_BLIZZARD_STYPE_CAP), /*bhv*/ bhvMrBlizzard), RETURN(), }; static const LevelScript script_func_local_4[] = { - OBJECT_WITH_ACTS(/*model*/ MODEL_STAR, /*pos*/ 0, 500, 1000, /*angle*/ 0, 0, 0, /*behParam*/ 0x05000000, /*beh*/ bhvStar, /*acts*/ ALL_ACTS), + OBJECT_WITH_ACTS(/*model*/ MODEL_STAR, /*pos*/ 0, 500, 1000, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(STAR_INDEX_ACT_6), /*bhv*/ bhvStar, /*acts*/ ALL_ACTS), RETURN(), }; const LevelScript level_sl_entry[] = { INIT_LEVEL(), - LOAD_MIO0( /*seg*/ 0x07, _sl_segment_7SegmentRomStart, _sl_segment_7SegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x07, _sl_segment_7SegmentRomStart, _sl_segment_7SegmentRomEnd), LOAD_MIO0_TEXTURE(/*seg*/ 0x09, _snow_mio0SegmentRomStart, _snow_mio0SegmentRomEnd), - LOAD_MIO0( /*seg*/ 0x0B, _effect_mio0SegmentRomStart, _effect_mio0SegmentRomEnd), - LOAD_MIO0( /*seg*/ 0x0A, _ccm_skybox_mio0SegmentRomStart, _ccm_skybox_mio0SegmentRomEnd), - LOAD_MIO0( /*seg*/ 0x05, _group7_mio0SegmentRomStart, _group7_mio0SegmentRomEnd), - LOAD_RAW( /*seg*/ 0x0C, _group7_geoSegmentRomStart, _group7_geoSegmentRomEnd), - LOAD_MIO0( /*seg*/ 0x06, _group16_mio0SegmentRomStart, _group16_mio0SegmentRomEnd), - LOAD_RAW( /*seg*/ 0x0D, _group16_geoSegmentRomStart, _group16_geoSegmentRomEnd), - LOAD_MIO0( /*seg*/ 0x08, _common0_mio0SegmentRomStart, _common0_mio0SegmentRomEnd), - LOAD_RAW( /*seg*/ 0x0F, _common0_geoSegmentRomStart, _common0_geoSegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x0B, _effect_mio0SegmentRomStart, _effect_mio0SegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x0A, _ccm_skybox_mio0SegmentRomStart, _ccm_skybox_mio0SegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x05, _group7_mio0SegmentRomStart, _group7_mio0SegmentRomEnd), + LOAD_RAW (/*seg*/ 0x0C, _group7_geoSegmentRomStart, _group7_geoSegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x06, _group16_mio0SegmentRomStart, _group16_mio0SegmentRomEnd), + LOAD_RAW (/*seg*/ 0x0D, _group16_geoSegmentRomStart, _group16_geoSegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x08, _common0_mio0SegmentRomStart, _common0_mio0SegmentRomEnd), + LOAD_RAW (/*seg*/ 0x0F, _common0_geoSegmentRomStart, _common0_geoSegmentRomEnd), ALLOC_LEVEL_POOL(), - MARIO(/*model*/ MODEL_MARIO, /*behParam*/ 0x00000001, /*beh*/ bhvMario), + MARIO(/*model*/ MODEL_MARIO, /*bhvParam*/ BPARAM4(0x01), /*bhv*/ bhvMario), JUMP_LINK(script_func_global_1), JUMP_LINK(script_func_global_8), JUMP_LINK(script_func_global_17), - LOAD_MODEL_FROM_GEO(MODEL_SL_SNOW_TRIANGLE, sl_geo_000390), - LOAD_MODEL_FROM_GEO(MODEL_SL_CRACKED_ICE, sl_geo_000360), - LOAD_MODEL_FROM_GEO(MODEL_SL_CRACKED_ICE_CHUNK, sl_geo_000378), - LOAD_MODEL_FROM_GEO(MODEL_SL_SNOW_TREE, snow_tree_geo), + LOAD_MODEL_FROM_GEO(MODEL_SL_SNOW_TRIANGLE, sl_geo_000390), + LOAD_MODEL_FROM_GEO(MODEL_SL_CRACKED_ICE, sl_geo_000360), + LOAD_MODEL_FROM_GEO(MODEL_SL_CRACKED_ICE_CHUNK, sl_geo_000378), + LOAD_MODEL_FROM_GEO(MODEL_SL_SNOW_TREE, snow_tree_geo), AREA(/*index*/ 1, sl_geo_0003A8), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 5541, 2024, 443, /*angle*/ 0, 270, 0, /*behParam*/ 0x000A0000, /*beh*/ bhvSpinAirborneWarp), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 257, 2150, 1399, /*angle*/ 0, 290, 0, /*behParam*/ 0x000B0000, /*beh*/ bhvInstantActiveWarp), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 569, 2150, 1336, /*angle*/ 0, 0, 0, /*behParam*/ 0x060C0000, /*beh*/ bhvWarp), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 5468, 1056, -5400, /*angle*/ 0, -20, 0, /*behParam*/ 0x000D0000, /*beh*/ bhvFadingWarp), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -3698, 1024, -1237, /*angle*/ 0, 6, 0, /*behParam*/ 0x000E0000, /*beh*/ bhvFadingWarp), - WARP_NODE(/*id*/ 0x0A, /*destLevel*/ LEVEL_SL, /*destArea*/ 0x01, /*destNode*/ 0x0A, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0x0B, /*destLevel*/ LEVEL_SL, /*destArea*/ 0x01, /*destNode*/ 0x0B, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0x0C, /*destLevel*/ LEVEL_SL, /*destArea*/ 0x02, /*destNode*/ 0x0A, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0x0D, /*destLevel*/ LEVEL_SL, /*destArea*/ 0x01, /*destNode*/ 0x0E, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0x0E, /*destLevel*/ LEVEL_SL, /*destArea*/ 0x01, /*destNode*/ 0x0D, /*flags*/ WARP_NO_CHECKPOINT), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 5541, 2024, 443, /*angle*/ 0, 270, 0, /*bhvParam*/ BPARAM2(WARP_NODE_0A), /*bhv*/ bhvSpinAirborneWarp), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 257, 2150, 1399, /*angle*/ 0, 290, 0, /*bhvParam*/ BPARAM2(WARP_NODE_0B), /*bhv*/ bhvInstantActiveWarp), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 569, 2150, 1336, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(6) | BPARAM2(WARP_NODE_0C), /*bhv*/ bhvWarp), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 5468, 1056, -5400, /*angle*/ 0, -20, 0, /*bhvParam*/ BPARAM2(WARP_NODE_0D), /*bhv*/ bhvFadingWarp), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ -3698, 1024, -1237, /*angle*/ 0, 6, 0, /*bhvParam*/ BPARAM2(WARP_NODE_0E), /*bhv*/ bhvFadingWarp), + WARP_NODE(/*id*/ WARP_NODE_0A, /*destLevel*/ LEVEL_SL, /*destArea*/ 1, /*destNode*/ WARP_NODE_0A, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_0B, /*destLevel*/ LEVEL_SL, /*destArea*/ 1, /*destNode*/ WARP_NODE_0B, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_0C, /*destLevel*/ LEVEL_SL, /*destArea*/ 2, /*destNode*/ WARP_NODE_0A, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_0D, /*destLevel*/ LEVEL_SL, /*destArea*/ 1, /*destNode*/ WARP_NODE_0E, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_0E, /*destLevel*/ LEVEL_SL, /*destArea*/ 1, /*destNode*/ WARP_NODE_0D, /*flags*/ WARP_NO_CHECKPOINT), JUMP_LINK(script_func_local_1), JUMP_LINK(script_func_local_2), JUMP_LINK(script_func_local_3), - WARP_NODE(/*id*/ 0xF0, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x02, /*destNode*/ 0x36, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0xF1, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x02, /*destNode*/ 0x68, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_SUCCESS, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 2, /*destNode*/ WARP_NODE_36, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_DEATH, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 2, /*destNode*/ WARP_NODE_68, /*flags*/ WARP_NO_CHECKPOINT), TERRAIN(/*terrainData*/ sl_seg7_area_1_collision), MACRO_OBJECTS(/*objList*/ sl_seg7_area_1_macro_objs), SET_BACKGROUND_MUSIC(/*settingsPreset*/ 0x0000, /*seq*/ SEQ_LEVEL_SNOW), @@ -87,13 +87,13 @@ const LevelScript level_sl_entry[] = { END_AREA(), AREA(/*index*/ 2, sl_geo_000484), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 0, 0, 2867, /*angle*/ 0, 180, 0, /*behParam*/ 0x000A0000, /*beh*/ bhvInstantActiveWarp), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 0, 0, 3277, /*angle*/ 0, 0, 0, /*behParam*/ 0x140B0000, /*beh*/ bhvWarp), - WARP_NODE(/*id*/ 0x0A, /*destLevel*/ LEVEL_SL, /*destArea*/ 0x02, /*destNode*/ 0x0A, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0x0B, /*destLevel*/ LEVEL_SL, /*destArea*/ 0x01, /*destNode*/ 0x0B, /*flags*/ WARP_NO_CHECKPOINT), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 0, 0, 2867, /*angle*/ 0, 180, 0, /*bhvParam*/ BPARAM2(WARP_NODE_0A), /*bhv*/ bhvInstantActiveWarp), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 0, 0, 3277, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(20) | BPARAM2(WARP_NODE_0B), /*bhv*/ bhvWarp), + WARP_NODE(/*id*/ WARP_NODE_0A, /*destLevel*/ LEVEL_SL, /*destArea*/ 2, /*destNode*/ WARP_NODE_0A, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_0B, /*destLevel*/ LEVEL_SL, /*destArea*/ 1, /*destNode*/ WARP_NODE_0B, /*flags*/ WARP_NO_CHECKPOINT), JUMP_LINK(script_func_local_4), - WARP_NODE(/*id*/ 0xF0, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x02, /*destNode*/ 0x36, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0xF1, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x02, /*destNode*/ 0x68, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_SUCCESS, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 2, /*destNode*/ WARP_NODE_36, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_DEATH, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 2, /*destNode*/ WARP_NODE_68, /*flags*/ WARP_NO_CHECKPOINT), TERRAIN(/*terrainData*/ sl_seg7_area_2_collision), MACRO_OBJECTS(/*objList*/ sl_seg7_area_2_macro_objs), SET_BACKGROUND_MUSIC(/*settingsPreset*/ 0x0004, /*seq*/ SEQ_LEVEL_UNDERGROUND), diff --git a/levels/sl/snow_mound/geo.inc.c b/levels/sl/snow_mound/geo.inc.c index 28e4fd8c..c74ae7fe 100644 --- a/levels/sl/snow_mound/geo.inc.c +++ b/levels/sl/snow_mound/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000390 const GeoLayout sl_geo_000390[] = { - GEO_CULLING_RADIUS(350), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, sl_seg7_dl_0700A780), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(350), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, sl_seg7_dl_0700A780), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/sl/unused_cracked_ice/geo.inc.c b/levels/sl/unused_cracked_ice/geo.inc.c index 05360563..c0a64378 100644 --- a/levels/sl/unused_cracked_ice/geo.inc.c +++ b/levels/sl/unused_cracked_ice/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000360 const GeoLayout sl_geo_000360[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, sl_seg7_dl_0700A890), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, sl_seg7_dl_0700A890), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/sl/unused_ice_shard/geo.inc.c b/levels/sl/unused_ice_shard/geo.inc.c index debe7590..25abf0fd 100644 --- a/levels/sl/unused_ice_shard/geo.inc.c +++ b/levels/sl/unused_ice_shard/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000378 const GeoLayout sl_geo_000378[] = { - GEO_NODE_START(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, sl_seg7_dl_0700A980), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_NODE_START(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, sl_seg7_dl_0700A980), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/ssl/areas/1/5/geo.inc.c b/levels/ssl/areas/1/5/geo.inc.c index b03677ac..2a46f94e 100644 --- a/levels/ssl/areas/1/5/geo.inc.c +++ b/levels/ssl/areas/1/5/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E0005C0 const GeoLayout ssl_geo_0005C0[] = { - GEO_CULLING_RADIUS(2000), - GEO_OPEN_NODE(), - GEO_ASM(0x801, geo_movtex_draw_colored_2_no_update), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(2000), + GEO_OPEN_NODE(), + GEO_ASM(0x801, geo_movtex_draw_colored_2_no_update), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/ssl/areas/1/geo.inc.c b/levels/ssl/areas/1/geo.inc.c index 08ca9015..3ed05798 100644 --- a/levels/ssl/areas/1/geo.inc.c +++ b/levels/ssl/areas/1/geo.inc.c @@ -1,40 +1,40 @@ // 0x0E000648 const GeoLayout ssl_geo_000648[] = { - GEO_NODE_SCREEN_AREA(10, SCREEN_WIDTH/2, SCREEN_HEIGHT/2, SCREEN_WIDTH/2, SCREEN_HEIGHT/2), - GEO_OPEN_NODE(), - GEO_ZBUFFER(0), - GEO_OPEN_NODE(), - GEO_NODE_ORTHO(100), - GEO_OPEN_NODE(), - GEO_BACKGROUND(BACKGROUND_DESERT, geo_skybox_main), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ZBUFFER(1), - GEO_OPEN_NODE(), - GEO_CAMERA_FRUSTUM_WITH_FUNC(45, 100, 20000, geo_camera_fov), - GEO_OPEN_NODE(), - GEO_CAMERA(1, 0, 2000, 6000, -2048, 0, -1024, geo_camera_main), + GEO_NODE_SCREEN_AREA(10, SCREEN_WIDTH/2, SCREEN_HEIGHT/2, SCREEN_WIDTH/2, SCREEN_HEIGHT/2), + GEO_OPEN_NODE(), + GEO_ZBUFFER(0), + GEO_OPEN_NODE(), + GEO_NODE_ORTHO(100), GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, ssl_seg7_dl_07009F48), - GEO_DISPLAY_LIST(LAYER_OPAQUE, ssl_seg7_dl_0700BA78), - GEO_DISPLAY_LIST(LAYER_ALPHA, ssl_seg7_dl_0700BC18), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT_DECAL, ssl_seg7_dl_0700BD00), - GEO_ASM(0x0801, geo_movtex_update_horizontal), - GEO_ASM( 0, geo_movtex_pause_control), - GEO_ASM(0x0801, geo_movtex_draw_water_regions), - GEO_ASM(0x0851, geo_movtex_draw_water_regions), - GEO_ASM(0x0801, geo_movtex_draw_colored), - GEO_ASM(0x0802, geo_movtex_draw_colored), - GEO_ASM(0x0803, geo_movtex_draw_colored), - GEO_RENDER_OBJ(), - GEO_ASM( 0, geo_envfx_main), + GEO_BACKGROUND(BACKGROUND_DESERT, geo_skybox_main), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ZBUFFER(0), - GEO_OPEN_NODE(), - GEO_ASM(0, geo_cannon_circle_base), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CLOSE_NODE(), + GEO_ZBUFFER(1), + GEO_OPEN_NODE(), + GEO_CAMERA_FRUSTUM_WITH_FUNC(45, 100, 20000, geo_camera_fov), + GEO_OPEN_NODE(), + GEO_CAMERA(1, 0, 2000, 6000, -2048, 0, -1024, geo_camera_main), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, ssl_seg7_dl_07009F48), + GEO_DISPLAY_LIST(LAYER_OPAQUE, ssl_seg7_dl_0700BA78), + GEO_DISPLAY_LIST(LAYER_ALPHA, ssl_seg7_dl_0700BC18), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT_DECAL, ssl_seg7_dl_0700BD00), + GEO_ASM(0x0801, geo_movtex_update_horizontal), + GEO_ASM( 0, geo_movtex_pause_control), + GEO_ASM(0x0801, geo_movtex_draw_water_regions), + GEO_ASM(0x0851, geo_movtex_draw_water_regions), + GEO_ASM(0x0801, geo_movtex_draw_colored), + GEO_ASM(0x0802, geo_movtex_draw_colored), + GEO_ASM(0x0803, geo_movtex_draw_colored), + GEO_RENDER_OBJ(), + GEO_ASM( 0, geo_envfx_main), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ZBUFFER(0), + GEO_OPEN_NODE(), + GEO_ASM(0, geo_cannon_circle_base), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/ssl/areas/1/macro.inc.c b/levels/ssl/areas/1/macro.inc.c index 79def1ee..f0f1fc06 100644 --- a/levels/ssl/areas/1/macro.inc.c +++ b/levels/ssl/areas/1/macro.inc.c @@ -1,50 +1,50 @@ // 0x07012424 - 0x070125F2 const MacroObject ssl_seg7_area_1_macro_objs[] = { - MACRO_OBJECT(/*preset*/ macro_goomba, /*yaw*/ 0, /*pos*/ 6068, 51, 2800), - MACRO_OBJECT(/*preset*/ macro_goomba, /*yaw*/ 0, /*pos*/ 5535, 51, 3377), - MACRO_OBJECT(/*preset*/ macro_goomba, /*yaw*/ 0, /*pos*/ 5980, 51, 3911), - MACRO_OBJECT(/*preset*/ macro_pokey, /*yaw*/ 0, /*pos*/ 4602, 40, 4622), - MACRO_OBJECT(/*preset*/ macro_pokey, /*yaw*/ 0, /*pos*/ 5057, 143, 256), - MACRO_OBJECT(/*preset*/ macro_pokey, /*yaw*/ 0, /*pos*/ -6858, 8, -3711), - MACRO_OBJECT(/*preset*/ macro_pokey, /*yaw*/ 0, /*pos*/ -5372, 64, 3083), - MACRO_OBJECT(/*preset*/ macro_breakable_box_no_coins, /*yaw*/ 0, /*pos*/ 5900, 51, 4400), - MACRO_OBJECT(/*preset*/ macro_breakable_box_no_coins, /*yaw*/ 0, /*pos*/ 5900, 51, 2311), - MACRO_OBJECT(/*preset*/ macro_bobomb_buddy_opens_cannon, /*yaw*/ 0, /*pos*/ -5990, 0, -3871), - MACRO_OBJECT(/*preset*/ macro_yellow_coin, /*yaw*/ 0, /*pos*/ -5869, 1200, -2535), - MACRO_OBJECT(/*preset*/ macro_yellow_coin, /*yaw*/ 0, /*pos*/ -5896, 1200, 773), - MACRO_OBJECT(/*preset*/ macro_yellow_coin, /*yaw*/ 0, /*pos*/ 1800, 1200, 800), - MACRO_OBJECT(/*preset*/ macro_yellow_coin, /*yaw*/ 0, /*pos*/ 1805, 1200, -2536), - MACRO_OBJECT(/*preset*/ macro_box_wing_cap, /*yaw*/ 0, /*pos*/ 6900, 350, -5400), - MACRO_OBJECT(/*preset*/ macro_box_wing_cap, /*yaw*/ 0, /*pos*/ -3000, 500, 800), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_cannon_closed, /*yaw*/ 0, /*pos*/ 6863, 0, -6860, /*behParam*/ 0xC0), - MACRO_OBJECT(/*preset*/ macro_breakable_box_small, /*yaw*/ 0, /*pos*/ 5900, 50, 3440), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -4500, 1500, -3500), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -4500, 1500, 1500), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 500, 1500, -3500), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 500, 1500, 1500), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 3380, 10, -4900), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -5270, -170, -6780), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -7450, 10, 7560), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 5900, 70, 2311), - MACRO_OBJECT(/*preset*/ macro_box_koopa_shell, /*yaw*/ 0, /*pos*/ 5840, 940, 2500), - MACRO_OBJECT(/*preset*/ macro_box_wing_cap, /*yaw*/ 0, /*pos*/ 5860, 940, 4180), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 0, /*pos*/ 5702, 614, 2974, /*behParam*/ DIALOG_016), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 0, /*pos*/ -3260, 256, 800, /*behParam*/ DIALOG_032), - MACRO_OBJECT(/*preset*/ macro_hidden_1up_in_pole, /*yaw*/ 0, /*pos*/ -6000, 600, -4800), - MACRO_OBJECT(/*preset*/ macro_1up, /*yaw*/ 0, /*pos*/ -250, 0, 4200), - MACRO_OBJECT(/*preset*/ macro_fly_guy, /*yaw*/ 0, /*pos*/ 3500, 149, 5600), - MACRO_OBJECT(/*preset*/ macro_bobomb, /*yaw*/ 0, /*pos*/ 3800, 0, 6000), - MACRO_OBJECT(/*preset*/ macro_bobomb, /*yaw*/ 0, /*pos*/ 1750, 0, 6450), - MACRO_OBJECT(/*preset*/ macro_coin_line_horizontal, /*yaw*/ 0, /*pos*/ -5920, 200, -920), - MACRO_OBJECT(/*preset*/ macro_fire_spitter, /*yaw*/ 0, /*pos*/ -386, 512, -2228), - MACRO_OBJECT(/*preset*/ macro_coin_line_horizontal, /*yaw*/ 90, /*pos*/ -2290, 787, -2180), - MACRO_OBJECT(/*preset*/ macro_fire_fly_guy, /*yaw*/ 0, /*pos*/ 1440, 800, -960), - MACRO_OBJECT(/*preset*/ macro_fire_fly_guy, /*yaw*/ 0, /*pos*/ -3400, 1160, -1120), - MACRO_OBJECT(/*preset*/ macro_fire_spitter, /*yaw*/ 0, /*pos*/ -5125, 135, -3138), - MACRO_OBJECT(/*preset*/ macro_jumping_box, /*yaw*/ 0, /*pos*/ 1120, 0, 6480), - MACRO_OBJECT(/*preset*/ macro_1up, /*yaw*/ 0, /*pos*/ 5757, 230, 5761), - MACRO_OBJECT(/*preset*/ macro_jumping_box, /*yaw*/ 0, /*pos*/ -5200, 0, 1700), - MACRO_OBJECT(/*preset*/ macro_box_1up_running_away, /*yaw*/ 0, /*pos*/ -1200, 500, 800), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 0, /*pos*/ 5130, 26, -370, /*behParam*/ DIALOG_157), + MACRO_OBJECT (/*preset*/ macro_goomba, /*yaw*/ 0, /*pos*/ 6068, 51, 2800), + MACRO_OBJECT (/*preset*/ macro_goomba, /*yaw*/ 0, /*pos*/ 5535, 51, 3377), + MACRO_OBJECT (/*preset*/ macro_goomba, /*yaw*/ 0, /*pos*/ 5980, 51, 3911), + MACRO_OBJECT (/*preset*/ macro_pokey_1, /*yaw*/ 0, /*pos*/ 4602, 40, 4622), + MACRO_OBJECT (/*preset*/ macro_pokey_1, /*yaw*/ 0, /*pos*/ 5057, 143, 256), + MACRO_OBJECT (/*preset*/ macro_pokey_1, /*yaw*/ 0, /*pos*/ -6858, 8, -3711), + MACRO_OBJECT (/*preset*/ macro_pokey_1, /*yaw*/ 0, /*pos*/ -5372, 64, 3083), + MACRO_OBJECT (/*preset*/ macro_breakable_box_no_coins, /*yaw*/ 0, /*pos*/ 5900, 51, 4400), + MACRO_OBJECT (/*preset*/ macro_breakable_box_no_coins, /*yaw*/ 0, /*pos*/ 5900, 51, 2311), + MACRO_OBJECT (/*preset*/ macro_bobomb_buddy_opens_cannon_1, /*yaw*/ 0, /*pos*/ -5990, 0, -3871), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_1, /*yaw*/ 0, /*pos*/ -5869, 1200, -2535), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_1, /*yaw*/ 0, /*pos*/ -5896, 1200, 773), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_1, /*yaw*/ 0, /*pos*/ 1800, 1200, 800), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_1, /*yaw*/ 0, /*pos*/ 1805, 1200, -2536), + MACRO_OBJECT (/*preset*/ macro_box_wing_cap, /*yaw*/ 0, /*pos*/ 6900, 350, -5400), + MACRO_OBJECT (/*preset*/ macro_box_wing_cap, /*yaw*/ 0, /*pos*/ -3000, 500, 800), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_cannon_closed, /*yaw*/ 0, /*pos*/ 6863, 0, -6860, /*bhvParam*/ 0xC0), + MACRO_OBJECT (/*preset*/ macro_breakable_box_small, /*yaw*/ 0, /*pos*/ 5900, 50, 3440), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -4500, 1500, -3500), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -4500, 1500, 1500), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 500, 1500, -3500), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 500, 1500, 1500), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 3380, 10, -4900), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -5270, -170, -6780), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -7450, 10, 7560), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 5900, 70, 2311), + MACRO_OBJECT (/*preset*/ macro_box_koopa_shell, /*yaw*/ 0, /*pos*/ 5840, 940, 2500), + MACRO_OBJECT (/*preset*/ macro_box_wing_cap, /*yaw*/ 0, /*pos*/ 5860, 940, 4180), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 0, /*pos*/ 5702, 614, 2974, /*bhvParam*/ DIALOG_016), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 0, /*pos*/ -3260, 256, 800, /*bhvParam*/ DIALOG_032), + MACRO_OBJECT (/*preset*/ macro_hidden_1up_in_pole, /*yaw*/ 0, /*pos*/ -6000, 600, -4800), + MACRO_OBJECT (/*preset*/ macro_1up, /*yaw*/ 0, /*pos*/ -250, 0, 4200), + MACRO_OBJECT (/*preset*/ macro_fly_guy, /*yaw*/ 0, /*pos*/ 3500, 149, 5600), + MACRO_OBJECT (/*preset*/ macro_bobomb, /*yaw*/ 0, /*pos*/ 3800, 0, 6000), + MACRO_OBJECT (/*preset*/ macro_bobomb, /*yaw*/ 0, /*pos*/ 1750, 0, 6450), + MACRO_OBJECT (/*preset*/ macro_coin_line_horizontal, /*yaw*/ 0, /*pos*/ -5920, 200, -920), + MACRO_OBJECT (/*preset*/ macro_fire_spitter, /*yaw*/ 0, /*pos*/ -386, 512, -2228), + MACRO_OBJECT (/*preset*/ macro_coin_line_horizontal, /*yaw*/ 90, /*pos*/ -2290, 787, -2180), + MACRO_OBJECT (/*preset*/ macro_fire_fly_guy, /*yaw*/ 0, /*pos*/ 1440, 800, -960), + MACRO_OBJECT (/*preset*/ macro_fire_fly_guy, /*yaw*/ 0, /*pos*/ -3400, 1160, -1120), + MACRO_OBJECT (/*preset*/ macro_fire_spitter, /*yaw*/ 0, /*pos*/ -5125, 135, -3138), + MACRO_OBJECT (/*preset*/ macro_jumping_box, /*yaw*/ 0, /*pos*/ 1120, 0, 6480), + MACRO_OBJECT (/*preset*/ macro_1up, /*yaw*/ 0, /*pos*/ 5757, 230, 5761), + MACRO_OBJECT (/*preset*/ macro_jumping_box, /*yaw*/ 0, /*pos*/ -5200, 0, 1700), + MACRO_OBJECT (/*preset*/ macro_box_1up_running_away, /*yaw*/ 0, /*pos*/ -1200, 500, 800), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 0, /*pos*/ 5130, 26, -370, /*bhvParam*/ DIALOG_157), MACRO_OBJECT_END(), }; diff --git a/levels/ssl/areas/2/4/geo.inc.c b/levels/ssl/areas/2/4/geo.inc.c index 090dd8cd..46157eba 100644 --- a/levels/ssl/areas/2/4/geo.inc.c +++ b/levels/ssl/areas/2/4/geo.inc.c @@ -1,15 +1,15 @@ // 0x0E0005D8 const GeoLayout ssl_geo_0005D8[] = { - GEO_CULLING_RADIUS(2000), - GEO_OPEN_NODE(), - GEO_RENDER_RANGE(-1000, 4000), - GEO_OPEN_NODE(), - GEO_ASM(0x802, geo_movtex_draw_colored_2_no_update), - GEO_CLOSE_NODE(), - GEO_RENDER_RANGE(4000, 12800), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, ssl_dl_pyramid_quicksand_pit_static), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(2000), + GEO_OPEN_NODE(), + GEO_RENDER_RANGE(-1000, 4000), + GEO_OPEN_NODE(), + GEO_ASM(0x802, geo_movtex_draw_colored_2_no_update), + GEO_CLOSE_NODE(), + GEO_RENDER_RANGE(4000, 12800), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, ssl_dl_pyramid_quicksand_pit_static), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/ssl/areas/2/geo.inc.c b/levels/ssl/areas/2/geo.inc.c index f421c32f..b01fa947 100644 --- a/levels/ssl/areas/2/geo.inc.c +++ b/levels/ssl/areas/2/geo.inc.c @@ -1,33 +1,33 @@ // 0x0E0007CC const GeoLayout ssl_geo_0007CC[] = { - GEO_NODE_SCREEN_AREA(10, SCREEN_WIDTH/2, SCREEN_HEIGHT/2, SCREEN_WIDTH/2, SCREEN_HEIGHT/2), - GEO_OPEN_NODE(), - GEO_ZBUFFER(0), - GEO_OPEN_NODE(), - GEO_NODE_ORTHO(100), - GEO_OPEN_NODE(), - GEO_BACKGROUND_COLOR(0x0001), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ZBUFFER(1), - GEO_OPEN_NODE(), - GEO_CAMERA_FRUSTUM_WITH_FUNC(45, 100, 12800, geo_camera_fov), - GEO_OPEN_NODE(), - GEO_CAMERA(4, 0, 2000, 6000, 0, 0, 0, geo_camera_main), + GEO_NODE_SCREEN_AREA(10, SCREEN_WIDTH/2, SCREEN_HEIGHT/2, SCREEN_WIDTH/2, SCREEN_HEIGHT/2), + GEO_OPEN_NODE(), + GEO_ZBUFFER(0), + GEO_OPEN_NODE(), + GEO_NODE_ORTHO(100), GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, ssl_seg7_dl_0701EE80), - GEO_DISPLAY_LIST(LAYER_ALPHA, ssl_seg7_dl_0701F920), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT_DECAL, ssl_seg7_dl_0701FCE0), - GEO_ASM(0x802, geo_movtex_update_horizontal), - GEO_ASM( 0, geo_movtex_pause_control), - GEO_ASM(0x801, geo_movtex_draw_nocolor), - GEO_ASM(0x802, geo_movtex_draw_nocolor), - GEO_ASM(0x803, geo_movtex_draw_nocolor), - GEO_RENDER_OBJ(), - GEO_ASM( 0, geo_envfx_main), + GEO_BACKGROUND_COLOR(0x0001), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CLOSE_NODE(), + GEO_ZBUFFER(1), + GEO_OPEN_NODE(), + GEO_CAMERA_FRUSTUM_WITH_FUNC(45, 100, 12800, geo_camera_fov), + GEO_OPEN_NODE(), + GEO_CAMERA(4, 0, 2000, 6000, 0, 0, 0, geo_camera_main), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, ssl_seg7_dl_0701EE80), + GEO_DISPLAY_LIST(LAYER_ALPHA, ssl_seg7_dl_0701F920), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT_DECAL, ssl_seg7_dl_0701FCE0), + GEO_ASM(0x802, geo_movtex_update_horizontal), + GEO_ASM( 0, geo_movtex_pause_control), + GEO_ASM(0x801, geo_movtex_draw_nocolor), + GEO_ASM(0x802, geo_movtex_draw_nocolor), + GEO_ASM(0x803, geo_movtex_draw_nocolor), + GEO_RENDER_OBJ(), + GEO_ASM( 0, geo_envfx_main), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/ssl/areas/2/macro.inc.c b/levels/ssl/areas/2/macro.inc.c index 86d06d6c..31b43094 100644 --- a/levels/ssl/areas/2/macro.inc.c +++ b/levels/ssl/areas/2/macro.inc.c @@ -1,54 +1,54 @@ // 0x07027CD4 - 0x07027ECA const MacroObject ssl_seg7_area_2_macro_objs[] = { - MACRO_OBJECT(/*preset*/ macro_goomba, /*yaw*/ 0, /*pos*/ 3263, 778, 3157), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 270, /*pos*/ 2196, 640, -3329, /*behParam*/ DIALOG_043), - MACRO_OBJECT(/*preset*/ macro_box_1up, /*yaw*/ 0, /*pos*/ -3536, 252, -3705), - MACRO_OBJECT(/*preset*/ macro_goomba, /*yaw*/ 0, /*pos*/ 3389, 0, -1978), - MACRO_OBJECT(/*preset*/ macro_goomba, /*yaw*/ 0, /*pos*/ -3638, 0, 1928), - MACRO_OBJECT(/*preset*/ macro_box_1up, /*yaw*/ 0, /*pos*/ -1242, 252, -3957), - MACRO_OBJECT(/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ 1873, 0, -3495), - MACRO_OBJECT(/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ 1200, 0, -3495), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_circling_amp, /*yaw*/ 0, /*pos*/ 3056, 736, -3267, /*behParam*/ 1), - MACRO_OBJECT(/*preset*/ macro_goomba, /*yaw*/ 0, /*pos*/ 3263, 652, 2200), - MACRO_OBJECT(/*preset*/ macro_goomba, /*yaw*/ 0, /*pos*/ 3431, 673, -1373), - MACRO_OBJECT(/*preset*/ macro_coin_line_horizontal_flying, /*yaw*/ 90, /*pos*/ -2, 1774, 2794), - MACRO_OBJECT(/*preset*/ macro_coin_ring_horizontal_flying, /*yaw*/ 0, /*pos*/ 2694, 850, -2889), - MACRO_OBJECT(/*preset*/ macro_recovery_heart, /*yaw*/ 0, /*pos*/ -400, 1978, -2250), - MACRO_OBJECT(/*preset*/ macro_yellow_coin, /*yaw*/ 0, /*pos*/ 736, 2652, -2250), - MACRO_OBJECT(/*preset*/ macro_yellow_coin, /*yaw*/ 0, /*pos*/ 736, 2546, -2250), - MACRO_OBJECT(/*preset*/ macro_yellow_coin, /*yaw*/ 0, /*pos*/ 1368, 3263, -2250), - MACRO_OBJECT(/*preset*/ macro_yellow_coin, /*yaw*/ 0, /*pos*/ 1368, 3135, -2250), - MACRO_OBJECT(/*preset*/ macro_homing_amp, /*yaw*/ 0, /*pos*/ 1621, 3368, -1142), - MACRO_OBJECT(/*preset*/ macro_homing_amp, /*yaw*/ 0, /*pos*/ 1621, 3389, 478), - MACRO_OBJECT(/*preset*/ macro_coin_line_horizontal, /*yaw*/ 90, /*pos*/ -210, 4521, -994), - MACRO_OBJECT(/*preset*/ macro_goomba, /*yaw*/ 0, /*pos*/ -2100, 0, 3316), - MACRO_OBJECT(/*preset*/ macro_blue_coin_switch, /*yaw*/ 0, /*pos*/ -719, 0, 4772), - MACRO_OBJECT(/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ 0, 0, 2381), - MACRO_OBJECT(/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ 0, 100, 2381), - MACRO_OBJECT(/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ 0, 200, 2381), - MACRO_OBJECT(/*preset*/ macro_hidden_1up_trigger, /*yaw*/ 0, /*pos*/ 2064, -81, -1901), - MACRO_OBJECT(/*preset*/ macro_hidden_1up_trigger, /*yaw*/ 0, /*pos*/ 2569, -81, -2022), - MACRO_OBJECT(/*preset*/ macro_hidden_1up_trigger, /*yaw*/ 0, /*pos*/ 2698, -81, -2535), - MACRO_OBJECT(/*preset*/ macro_hidden_1up_trigger, /*yaw*/ 0, /*pos*/ 2698, -81, -3049), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_hidden_1up, /*yaw*/ 0, /*pos*/ 1940, -81, -1360, /*behParam*/ 4), - MACRO_OBJECT(/*preset*/ macro_hidden_star_trigger, /*yaw*/ 0, /*pos*/ -260, 2940, -600), - MACRO_OBJECT(/*preset*/ macro_hidden_star_trigger, /*yaw*/ 0, /*pos*/ 260, 1967, -600), - MACRO_OBJECT(/*preset*/ macro_hidden_star_trigger, /*yaw*/ 0, /*pos*/ -1940, 1229, -600), - MACRO_OBJECT(/*preset*/ macro_hidden_star_trigger, /*yaw*/ 0, /*pos*/ -1940, 1229, 2320), - MACRO_OBJECT(/*preset*/ macro_coin_line_vertical, /*yaw*/ 0, /*pos*/ 290, 4479, -940), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 0, /*pos*/ -3560, 0, -4065, /*behParam*/ DIALOG_103), - MACRO_OBJECT(/*preset*/ macro_hidden_star_trigger, /*yaw*/ 0, /*pos*/ 260, 3913, -600), - MACRO_OBJECT(/*preset*/ macro_yellow_coin, /*yaw*/ 0, /*pos*/ -260, 2950, -600), - MACRO_OBJECT(/*preset*/ macro_yellow_coin, /*yaw*/ 0, /*pos*/ 260, 1977, -600), - MACRO_OBJECT(/*preset*/ macro_yellow_coin, /*yaw*/ 0, /*pos*/ -1940, 1239, -600), - MACRO_OBJECT(/*preset*/ macro_yellow_coin, /*yaw*/ 0, /*pos*/ -1940, 1239, 2320), - MACRO_OBJECT(/*preset*/ macro_yellow_coin, /*yaw*/ 0, /*pos*/ 260, 3923, -600), - MACRO_OBJECT(/*preset*/ macro_goomba_triplet_spawner, /*yaw*/ 0, /*pos*/ 3181, 0, 3587), - MACRO_OBJECT(/*preset*/ macro_1up, /*yaw*/ 0, /*pos*/ -3350, 980, -1240), - MACRO_OBJECT(/*preset*/ macro_1up, /*yaw*/ 0, /*pos*/ 2870, 1050, -2640), - MACRO_OBJECT(/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ -2047, 1664, 3076), - MACRO_OBJECT(/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ -2047, 1536, 2870), - MACRO_OBJECT(/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ -1840, 1357, 3076), - MACRO_OBJECT(/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ -1840, 1408, 2870), + MACRO_OBJECT (/*preset*/ macro_goomba, /*yaw*/ 0, /*pos*/ 3263, 778, 3157), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 270, /*pos*/ 2196, 640, -3329, /*bhvParam*/ DIALOG_043), + MACRO_OBJECT (/*preset*/ macro_box_1up, /*yaw*/ 0, /*pos*/ -3536, 252, -3705), + MACRO_OBJECT (/*preset*/ macro_goomba, /*yaw*/ 0, /*pos*/ 3389, 0, -1978), + MACRO_OBJECT (/*preset*/ macro_goomba, /*yaw*/ 0, /*pos*/ -3638, 0, 1928), + MACRO_OBJECT (/*preset*/ macro_box_1up, /*yaw*/ 0, /*pos*/ -1242, 252, -3957), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ 1873, 0, -3495), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ 1200, 0, -3495), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_circling_amp, /*yaw*/ 0, /*pos*/ 3056, 736, -3267, /*bhvParam*/ AMP_BP_ROT_RADIUS_300), + MACRO_OBJECT (/*preset*/ macro_goomba, /*yaw*/ 0, /*pos*/ 3263, 652, 2200), + MACRO_OBJECT (/*preset*/ macro_goomba, /*yaw*/ 0, /*pos*/ 3431, 673, -1373), + MACRO_OBJECT (/*preset*/ macro_coin_line_horizontal_flying, /*yaw*/ 90, /*pos*/ -2, 1774, 2794), + MACRO_OBJECT (/*preset*/ macro_coin_ring_horizontal_flying, /*yaw*/ 0, /*pos*/ 2694, 850, -2889), + MACRO_OBJECT (/*preset*/ macro_recovery_heart, /*yaw*/ 0, /*pos*/ -400, 1978, -2250), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_1, /*yaw*/ 0, /*pos*/ 736, 2652, -2250), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_1, /*yaw*/ 0, /*pos*/ 736, 2546, -2250), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_1, /*yaw*/ 0, /*pos*/ 1368, 3263, -2250), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_1, /*yaw*/ 0, /*pos*/ 1368, 3135, -2250), + MACRO_OBJECT (/*preset*/ macro_homing_amp, /*yaw*/ 0, /*pos*/ 1621, 3368, -1142), + MACRO_OBJECT (/*preset*/ macro_homing_amp, /*yaw*/ 0, /*pos*/ 1621, 3389, 478), + MACRO_OBJECT (/*preset*/ macro_coin_line_horizontal, /*yaw*/ 90, /*pos*/ -210, 4521, -994), + MACRO_OBJECT (/*preset*/ macro_goomba, /*yaw*/ 0, /*pos*/ -2100, 0, 3316), + MACRO_OBJECT (/*preset*/ macro_blue_coin_switch, /*yaw*/ 0, /*pos*/ -719, 0, 4772), + MACRO_OBJECT (/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ 0, 0, 2381), + MACRO_OBJECT (/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ 0, 100, 2381), + MACRO_OBJECT (/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ 0, 200, 2381), + MACRO_OBJECT (/*preset*/ macro_hidden_1up_trigger, /*yaw*/ 0, /*pos*/ 2064, -81, -1901), + MACRO_OBJECT (/*preset*/ macro_hidden_1up_trigger, /*yaw*/ 0, /*pos*/ 2569, -81, -2022), + MACRO_OBJECT (/*preset*/ macro_hidden_1up_trigger, /*yaw*/ 0, /*pos*/ 2698, -81, -2535), + MACRO_OBJECT (/*preset*/ macro_hidden_1up_trigger, /*yaw*/ 0, /*pos*/ 2698, -81, -3049), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_hidden_1up, /*yaw*/ 0, /*pos*/ 1940, -81, -1360, /*bhvParam*/ 4), + MACRO_OBJECT (/*preset*/ macro_hidden_star_trigger, /*yaw*/ 0, /*pos*/ -260, 2940, -600), + MACRO_OBJECT (/*preset*/ macro_hidden_star_trigger, /*yaw*/ 0, /*pos*/ 260, 1967, -600), + MACRO_OBJECT (/*preset*/ macro_hidden_star_trigger, /*yaw*/ 0, /*pos*/ -1940, 1229, -600), + MACRO_OBJECT (/*preset*/ macro_hidden_star_trigger, /*yaw*/ 0, /*pos*/ -1940, 1229, 2320), + MACRO_OBJECT (/*preset*/ macro_coin_line_vertical_flying, /*yaw*/ 0, /*pos*/ 290, 4479, -940), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 0, /*pos*/ -3560, 0, -4065, /*bhvParam*/ DIALOG_103), + MACRO_OBJECT (/*preset*/ macro_hidden_star_trigger, /*yaw*/ 0, /*pos*/ 260, 3913, -600), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_1, /*yaw*/ 0, /*pos*/ -260, 2950, -600), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_1, /*yaw*/ 0, /*pos*/ 260, 1977, -600), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_1, /*yaw*/ 0, /*pos*/ -1940, 1239, -600), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_1, /*yaw*/ 0, /*pos*/ -1940, 1239, 2320), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_1, /*yaw*/ 0, /*pos*/ 260, 3923, -600), + MACRO_OBJECT (/*preset*/ macro_goomba_triplet_spawner, /*yaw*/ 0, /*pos*/ 3181, 0, 3587), + MACRO_OBJECT (/*preset*/ macro_1up, /*yaw*/ 0, /*pos*/ -3350, 980, -1240), + MACRO_OBJECT (/*preset*/ macro_1up, /*yaw*/ 0, /*pos*/ 2870, 1050, -2640), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ -2047, 1664, 3076), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ -2047, 1536, 2870), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ -1840, 1357, 3076), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ -1840, 1408, 2870), MACRO_OBJECT_END(), }; diff --git a/levels/ssl/areas/3/geo.inc.c b/levels/ssl/areas/3/geo.inc.c index ab01ed2b..109b815b 100644 --- a/levels/ssl/areas/3/geo.inc.c +++ b/levels/ssl/areas/3/geo.inc.c @@ -1,27 +1,27 @@ // 0x0E00088C const GeoLayout ssl_geo_00088C[] = { - GEO_NODE_SCREEN_AREA(10, SCREEN_WIDTH/2, SCREEN_HEIGHT/2, SCREEN_WIDTH/2, SCREEN_HEIGHT/2), - GEO_OPEN_NODE(), - GEO_ZBUFFER(0), - GEO_OPEN_NODE(), - GEO_NODE_ORTHO(100), - GEO_OPEN_NODE(), - GEO_BACKGROUND_COLOR(0x0001), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ZBUFFER(1), - GEO_OPEN_NODE(), - GEO_CAMERA_FRUSTUM_WITH_FUNC(45, 100, 12800, geo_camera_fov), - GEO_OPEN_NODE(), - GEO_CAMERA(4, 0, 2000, 6000, 0, 0, 0, geo_camera_main), + GEO_NODE_SCREEN_AREA(10, SCREEN_WIDTH/2, SCREEN_HEIGHT/2, SCREEN_WIDTH/2, SCREEN_HEIGHT/2), + GEO_OPEN_NODE(), + GEO_ZBUFFER(0), + GEO_OPEN_NODE(), + GEO_NODE_ORTHO(100), GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, ssl_seg7_dl_07021A08), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, ssl_seg7_dl_07021DE8), - GEO_RENDER_OBJ(), - GEO_ASM(0, geo_envfx_main), + GEO_BACKGROUND_COLOR(0x0001), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CLOSE_NODE(), + GEO_ZBUFFER(1), + GEO_OPEN_NODE(), + GEO_CAMERA_FRUSTUM_WITH_FUNC(45, 100, 12800, geo_camera_fov), + GEO_OPEN_NODE(), + GEO_CAMERA(4, 0, 2000, 6000, 0, 0, 0, geo_camera_main), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, ssl_seg7_dl_07021A08), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, ssl_seg7_dl_07021DE8), + GEO_RENDER_OBJ(), + GEO_ASM(0, geo_envfx_main), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/ssl/eyerok_col/geo.inc.c b/levels/ssl/eyerok_col/geo.inc.c index 9bebe774..f5021fea 100644 --- a/levels/ssl/eyerok_col/geo.inc.c +++ b/levels/ssl/eyerok_col/geo.inc.c @@ -1,2 +1 @@ // Blank File - diff --git a/levels/ssl/grindel/geo.inc.c b/levels/ssl/grindel/geo.inc.c index e89f37fe..200d59b9 100644 --- a/levels/ssl/grindel/geo.inc.c +++ b/levels/ssl/grindel/geo.inc.c @@ -1,12 +1,12 @@ // 0x0E000734 const GeoLayout ssl_geo_000734[] = { - GEO_CULLING_RADIUS(700), - GEO_OPEN_NODE(), - GEO_SHADOW(SHADOW_SQUARE_SCALABLE, 0xB4, 550), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, ssl_seg7_dl_070220A8), - GEO_DISPLAY_LIST(LAYER_ALPHA, ssl_seg7_dl_070221E8), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(700), + GEO_OPEN_NODE(), + GEO_SHADOW(SHADOW_SQUARE_SCALABLE, 0xB4, 550), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, ssl_seg7_dl_070220A8), + GEO_DISPLAY_LIST(LAYER_ALPHA, ssl_seg7_dl_070221E8), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/ssl/leveldata.c b/levels/ssl/leveldata.c index 78808757..077e18d5 100644 --- a/levels/ssl/leveldata.c +++ b/levels/ssl/leveldata.c @@ -1,12 +1,13 @@ #include #include +#include "sm64.h" #include "dialog_ids.h" #include "level_misc_macros.h" #include "macros.h" -#include "macro_preset_names.h" +#include "macro_presets.h" #include "moving_texture_macros.h" -#include "special_preset_names.h" +#include "special_presets.h" #include "surface_terrains.h" #include "textures.h" #include "types.h" diff --git a/levels/ssl/moving_pyramid_wall/geo.inc.c b/levels/ssl/moving_pyramid_wall/geo.inc.c index a15f0eb1..05fc1ee9 100644 --- a/levels/ssl/moving_pyramid_wall/geo.inc.c +++ b/levels/ssl/moving_pyramid_wall/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000794 const GeoLayout ssl_geo_000794[] = { - GEO_CULLING_RADIUS(700), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, ssl_seg7_dl_07022CF8), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(700), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, ssl_seg7_dl_07022CF8), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/ssl/pyramid_elevator/geo.inc.c b/levels/ssl/pyramid_elevator/geo.inc.c index 50c862fc..f899c262 100644 --- a/levels/ssl/pyramid_elevator/geo.inc.c +++ b/levels/ssl/pyramid_elevator/geo.inc.c @@ -1,9 +1,9 @@ // 0x0E0007AC const GeoLayout ssl_geo_0007AC[] = { - GEO_CULLING_RADIUS(900), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, ssl_seg7_dl_070233A8), - GEO_DISPLAY_LIST(LAYER_ALPHA, ssl_seg7_dl_070235C0), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(900), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, ssl_seg7_dl_070233A8), + GEO_DISPLAY_LIST(LAYER_ALPHA, ssl_seg7_dl_070235C0), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/ssl/pyramid_top/geo.inc.c b/levels/ssl/pyramid_top/geo.inc.c index 5adf3d7f..92e28d62 100644 --- a/levels/ssl/pyramid_top/geo.inc.c +++ b/levels/ssl/pyramid_top/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000618 const GeoLayout ssl_geo_000618[] = { - GEO_CULLING_RADIUS(1000), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, ssl_seg7_dl_0700BF18), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(1000), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, ssl_seg7_dl_0700BF18), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/ssl/script.c b/levels/ssl/script.c index 65aec751..37f2eac9 100644 --- a/levels/ssl/script.c +++ b/levels/ssl/script.c @@ -16,68 +16,68 @@ #include "levels/ssl/header.h" static const LevelScript script_func_local_1[] = { - OBJECT(/*model*/ MODEL_SSL_PYRAMID_TOP, /*pos*/ -2047, 1536, -1023, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvPyramidTop), + OBJECT(/*model*/ MODEL_SSL_PYRAMID_TOP, /*pos*/ -2047, 1536, -1023, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvPyramidTop), RETURN(), }; static const LevelScript script_func_local_2[] = { - OBJECT(/*model*/ MODEL_SSL_TOX_BOX, /*pos*/ -1284, 0, -5895, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvToxBox), - OBJECT(/*model*/ MODEL_SSL_TOX_BOX, /*pos*/ 1283, 0, -4865, /*angle*/ 0, 0, 0, /*behParam*/ 0x00010000, /*beh*/ bhvToxBox), - OBJECT(/*model*/ MODEL_SSL_TOX_BOX, /*pos*/ 4873, 0, -3335, /*angle*/ 0, 0, 0, /*behParam*/ 0x00020000, /*beh*/ bhvToxBox), - OBJECT(/*model*/ MODEL_TWEESTER, /*pos*/ -3600, -200, 2940, /*angle*/ 0, 0, 0, /*behParam*/ 0x00120000, /*beh*/ bhvTweester), - OBJECT_WITH_ACTS(/*model*/ MODEL_TWEESTER, /*pos*/ 1017, -200, 3832, /*angle*/ 0, 0, 0, /*behParam*/ 0x00190000, /*beh*/ bhvTweester, /*acts*/ ACT_4 | ACT_5 | ACT_6), - OBJECT_WITH_ACTS(/*model*/ MODEL_TWEESTER, /*pos*/ 3066, -200, 400, /*angle*/ 0, 0, 0, /*behParam*/ 0x00190000, /*beh*/ bhvTweester, /*acts*/ ACT_4 | ACT_5 | ACT_6), - OBJECT_WITH_ACTS(/*model*/ MODEL_KLEPTO, /*pos*/ 2200, 1174, -2820, /*angle*/ 0, 0, 0, /*behParam*/ 0x00010000, /*beh*/ bhvKlepto, /*acts*/ ACT_1), - OBJECT_WITH_ACTS(/*model*/ MODEL_KLEPTO, /*pos*/ -5963, 573, -4784, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvKlepto, /*acts*/ ACT_2 | ACT_3 | ACT_4 | ACT_5 | ACT_6), + OBJECT (/*model*/ MODEL_SSL_TOX_BOX, /*pos*/ -1284, 0, -5895, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(TOX_BOX_BP_MOVEMENT_PATTERN_1), /*bhv*/ bhvToxBox), + OBJECT (/*model*/ MODEL_SSL_TOX_BOX, /*pos*/ 1283, 0, -4865, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(TOX_BOX_BP_MOVEMENT_PATTERN_2), /*bhv*/ bhvToxBox), + OBJECT (/*model*/ MODEL_SSL_TOX_BOX, /*pos*/ 4873, 0, -3335, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(TOX_BOX_BP_MOVEMENT_PATTERN_3), /*bhv*/ bhvToxBox), + OBJECT (/*model*/ MODEL_TWEESTER, /*pos*/ -3600, -200, 2940, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(0x12), /*bhv*/ bhvTweester), + OBJECT_WITH_ACTS(/*model*/ MODEL_TWEESTER, /*pos*/ 1017, -200, 3832, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(0x19), /*bhv*/ bhvTweester, /*acts*/ ACT_4 | ACT_5 | ACT_6), + OBJECT_WITH_ACTS(/*model*/ MODEL_TWEESTER, /*pos*/ 3066, -200, 400, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(0x19), /*bhv*/ bhvTweester, /*acts*/ ACT_4 | ACT_5 | ACT_6), + OBJECT_WITH_ACTS(/*model*/ MODEL_KLEPTO, /*pos*/ 2200, 1174, -2820, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(STAR_INDEX_ACT_1) | BPARAM2(0x01), /*bhv*/ bhvKlepto, /*acts*/ ACT_1), + OBJECT_WITH_ACTS(/*model*/ MODEL_KLEPTO, /*pos*/ -5963, 573, -4784, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvKlepto, /*acts*/ ACT_2 | ACT_3 | ACT_4 | ACT_5 | ACT_6), RETURN(), }; static const LevelScript script_func_local_3[] = { - OBJECT_WITH_ACTS(/*model*/ MODEL_STAR, /*pos*/ -2050, 1200, -580, /*angle*/ 0, 0, 0, /*behParam*/ 0x01000000, /*beh*/ bhvStar, /*acts*/ ALL_ACTS), - OBJECT_WITH_ACTS(/*model*/ MODEL_NONE, /*pos*/ 6000, 800, 3500, /*angle*/ 0, 0, 0, /*behParam*/ 0x04000000, /*beh*/ bhvHiddenRedCoinStar, /*acts*/ ALL_ACTS), + OBJECT_WITH_ACTS(/*model*/ MODEL_STAR, /*pos*/ -2050, 1200, -580, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(STAR_INDEX_ACT_2), /*bhv*/ bhvStar, /*acts*/ ALL_ACTS), + OBJECT_WITH_ACTS(/*model*/ MODEL_NONE, /*pos*/ 6000, 800, 3500, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(STAR_INDEX_ACT_5), /*bhv*/ bhvHiddenRedCoinStar, /*acts*/ ALL_ACTS), RETURN(), }; static const LevelScript script_func_local_4[] = { - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 2867, 640, 2867, /*angle*/ 0, 0, 0, /*behParam*/ 0x004D0000, /*beh*/ bhvPoleGrabbing), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 0, 3200, 1331, /*angle*/ 0, 0, 0, /*behParam*/ 0x005C0000, /*beh*/ bhvPoleGrabbing), - OBJECT(/*model*/ MODEL_SSL_GRINDEL, /*pos*/ 3297, 0, 95, /*angle*/ 0, 0, 0, /*behParam*/ 0x001C0000, /*beh*/ bhvGrindel), - OBJECT(/*model*/ MODEL_SSL_GRINDEL, /*pos*/ -870, 3840, 105, /*angle*/ 0, 180, 0, /*behParam*/ 0x00000000, /*beh*/ bhvHorizontalGrindel), - OBJECT(/*model*/ MODEL_SSL_GRINDEL, /*pos*/ -3362, 0, -1385, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvHorizontalGrindel), - OBJECT(/*model*/ MODEL_SSL_SPINDEL, /*pos*/ -2458, 2109, -1430, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvSpindel), - OBJECT(/*model*/ MODEL_SSL_MOVING_PYRAMID_WALL, /*pos*/ 858, 1927, -2307, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvSslMovingPyramidWall), - OBJECT(/*model*/ MODEL_SSL_MOVING_PYRAMID_WALL, /*pos*/ 730, 1927, -2307, /*angle*/ 0, 0, 0, /*behParam*/ 0x00010000, /*beh*/ bhvSslMovingPyramidWall), - OBJECT(/*model*/ MODEL_SSL_MOVING_PYRAMID_WALL, /*pos*/ 1473, 2567, -2307, /*angle*/ 0, 0, 0, /*behParam*/ 0x00010000, /*beh*/ bhvSslMovingPyramidWall), - OBJECT(/*model*/ MODEL_SSL_MOVING_PYRAMID_WALL, /*pos*/ 1345, 2567, -2307, /*angle*/ 0, 0, 0, /*behParam*/ 0x00020000, /*beh*/ bhvSslMovingPyramidWall), - OBJECT(/*model*/ MODEL_SSL_PYRAMID_ELEVATOR, /*pos*/ 0, 4966, 256, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvPyramidElevator), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 1198, -133, 2396, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvSandSoundLoop), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 7, 1229, -708, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvSandSoundLoop), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 7, 4317, -708, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvSandSoundLoop), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 2867, 640, 2867, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(77), /*bhv*/ bhvPoleGrabbing), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 0, 3200, 1331, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(92), /*bhv*/ bhvPoleGrabbing), + OBJECT(/*model*/ MODEL_SSL_GRINDEL, /*pos*/ 3297, 0, 95, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(28), /*bhv*/ bhvGrindel), + OBJECT(/*model*/ MODEL_SSL_GRINDEL, /*pos*/ -870, 3840, 105, /*angle*/ 0, 180, 0, /*bhvParam*/ 0, /*bhv*/ bhvHorizontalGrindel), + OBJECT(/*model*/ MODEL_SSL_GRINDEL, /*pos*/ -3362, 0, -1385, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvHorizontalGrindel), + OBJECT(/*model*/ MODEL_SSL_SPINDEL, /*pos*/ -2458, 2109, -1430, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvSpindel), + OBJECT(/*model*/ MODEL_SSL_MOVING_PYRAMID_WALL, /*pos*/ 858, 1927, -2307, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(PYRAMID_WALL_BP_POSITION_HIGH), /*bhv*/ bhvSSLMovingPyramidWall), + OBJECT(/*model*/ MODEL_SSL_MOVING_PYRAMID_WALL, /*pos*/ 730, 1927, -2307, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(PYRAMID_WALL_BP_POSITION_MIDDLE), /*bhv*/ bhvSSLMovingPyramidWall), + OBJECT(/*model*/ MODEL_SSL_MOVING_PYRAMID_WALL, /*pos*/ 1473, 2567, -2307, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(PYRAMID_WALL_BP_POSITION_MIDDLE), /*bhv*/ bhvSSLMovingPyramidWall), + OBJECT(/*model*/ MODEL_SSL_MOVING_PYRAMID_WALL, /*pos*/ 1345, 2567, -2307, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(PYRAMID_WALL_BP_POSITION_LOW), /*bhv*/ bhvSSLMovingPyramidWall), + OBJECT(/*model*/ MODEL_SSL_PYRAMID_ELEVATOR, /*pos*/ 0, 4966, 256, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvPyramidElevator), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 1198, -133, 2396, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvSandSoundLoop), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 7, 1229, -708, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvSandSoundLoop), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 7, 4317, -708, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvSandSoundLoop), RETURN(), }; static const LevelScript script_func_local_5[] = { - OBJECT_WITH_ACTS(/*model*/ MODEL_STAR, /*pos*/ 500, 5050, -500, /*angle*/ 0, 0, 0, /*behParam*/ 0x02000000, /*beh*/ bhvStar, /*acts*/ ALL_ACTS), - OBJECT_WITH_ACTS(/*model*/ MODEL_NONE, /*pos*/ 900, 1400, 2350, /*angle*/ 0, 0, 0, /*behParam*/ 0x05040000, /*beh*/ bhvHiddenStar, /*acts*/ ALL_ACTS), + OBJECT_WITH_ACTS(/*model*/ MODEL_STAR, /*pos*/ 500, 5050, -500, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(STAR_INDEX_ACT_3), /*bhv*/ bhvStar, /*acts*/ ALL_ACTS), + OBJECT_WITH_ACTS(/*model*/ MODEL_NONE, /*pos*/ 900, 1400, 2350, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(STAR_INDEX_ACT_6) | BPARAM2(0x04), /*bhv*/ bhvHiddenStar, /*acts*/ ALL_ACTS), RETURN(), }; static const LevelScript script_func_local_6[] = { - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 0, -1534, -3693, /*angle*/ 0, 0, 0, /*behParam*/ 0x03000000, /*beh*/ bhvEyerokBoss), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 0, -1534, -3693, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(STAR_INDEX_ACT_4), /*bhv*/ bhvEyerokBoss), RETURN(), }; const LevelScript level_ssl_entry[] = { INIT_LEVEL(), - LOAD_MIO0( /*seg*/ 0x07, _ssl_segment_7SegmentRomStart, _ssl_segment_7SegmentRomEnd), - LOAD_MIO0( /*seg*/ 0x0A, _ssl_skybox_mio0SegmentRomStart, _ssl_skybox_mio0SegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x07, _ssl_segment_7SegmentRomStart, _ssl_segment_7SegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x0A, _ssl_skybox_mio0SegmentRomStart, _ssl_skybox_mio0SegmentRomEnd), LOAD_MIO0_TEXTURE(/*seg*/ 0x09, _generic_mio0SegmentRomStart, _generic_mio0SegmentRomEnd), - LOAD_MIO0( /*seg*/ 0x05, _group5_mio0SegmentRomStart, _group5_mio0SegmentRomEnd), - LOAD_RAW( /*seg*/ 0x0C, _group5_geoSegmentRomStart, _group5_geoSegmentRomEnd), - LOAD_MIO0( /*seg*/ 0x08, _common0_mio0SegmentRomStart, _common0_mio0SegmentRomEnd), - LOAD_RAW( /*seg*/ 0x0F, _common0_geoSegmentRomStart, _common0_geoSegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x05, _group5_mio0SegmentRomStart, _group5_mio0SegmentRomEnd), + LOAD_RAW (/*seg*/ 0x0C, _group5_geoSegmentRomStart, _group5_geoSegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x08, _common0_mio0SegmentRomStart, _common0_mio0SegmentRomEnd), + LOAD_RAW (/*seg*/ 0x0F, _common0_geoSegmentRomStart, _common0_geoSegmentRomEnd), ALLOC_LEVEL_POOL(), - MARIO(/*model*/ MODEL_MARIO, /*behParam*/ 0x00000001, /*beh*/ bhvMario), + MARIO(/*model*/ MODEL_MARIO, /*bhvParam*/ BPARAM4(0x01), /*bhv*/ bhvMario), JUMP_LINK(script_func_global_1), JUMP_LINK(script_func_global_6), LOAD_MODEL_FROM_GEO(MODEL_SSL_PALM_TREE, palm_tree_geo), @@ -91,18 +91,18 @@ const LevelScript level_ssl_entry[] = { LOAD_MODEL_FROM_GEO(MODEL_SSL_TOX_BOX, ssl_geo_000630), AREA(/*index*/ 1, ssl_geo_000648), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 653, 1038, 6566, /*angle*/ 0, 90, 0, /*behParam*/ 0x000A0000, /*beh*/ bhvSpinAirborneWarp), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -2048, 0, 56, /*angle*/ 0, 0, 0, /*behParam*/ 0x00140000, /*beh*/ bhvWarp), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -2048, 768, -1024, /*angle*/ 0, 0, 0, /*behParam*/ 0x0F1E0000, /*beh*/ bhvWarp), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 6930, 0, -4871, /*angle*/ 0, 159, 0, /*behParam*/ 0x001F0000, /*beh*/ bhvFadingWarp), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -5943, 0, -4903, /*angle*/ 0, 49, 0, /*behParam*/ 0x00200000, /*beh*/ bhvFadingWarp), - WARP_NODE(/*id*/ 0x0A, /*destLevel*/ LEVEL_SSL, /*destArea*/ 0x01, /*destNode*/ 0x0A, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0x14, /*destLevel*/ LEVEL_SSL, /*destArea*/ 0x02, /*destNode*/ 0x0A, /*flags*/ WARP_CHECKPOINT), - WARP_NODE(/*id*/ 0x1E, /*destLevel*/ LEVEL_SSL, /*destArea*/ 0x02, /*destNode*/ 0x14, /*flags*/ WARP_CHECKPOINT), - WARP_NODE(/*id*/ 0x1F, /*destLevel*/ LEVEL_SSL, /*destArea*/ 0x01, /*destNode*/ 0x20, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0x20, /*destLevel*/ LEVEL_SSL, /*destArea*/ 0x01, /*destNode*/ 0x1F, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0xF0, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x03, /*destNode*/ 0x33, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0xF1, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x03, /*destNode*/ 0x65, /*flags*/ WARP_NO_CHECKPOINT), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 653, 1038, 6566, /*angle*/ 0, 90, 0, /*bhvParam*/ BPARAM2(WARP_NODE_0A), /*bhv*/ bhvSpinAirborneWarp), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ -2048, 0, 56, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(WARP_NODE_14), /*bhv*/ bhvWarp), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ -2048, 768, -1024, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(15) | BPARAM2(WARP_NODE_1E), /*bhv*/ bhvWarp), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 6930, 0, -4871, /*angle*/ 0, 159, 0, /*bhvParam*/ BPARAM2(WARP_NODE_1F), /*bhv*/ bhvFadingWarp), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ -5943, 0, -4903, /*angle*/ 0, 49, 0, /*bhvParam*/ BPARAM2(WARP_NODE_20), /*bhv*/ bhvFadingWarp), + WARP_NODE(/*id*/ WARP_NODE_0A, /*destLevel*/ LEVEL_SSL, /*destArea*/ 1, /*destNode*/ WARP_NODE_0A, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_14, /*destLevel*/ LEVEL_SSL, /*destArea*/ 2, /*destNode*/ WARP_NODE_0A, /*flags*/ WARP_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_1E, /*destLevel*/ LEVEL_SSL, /*destArea*/ 2, /*destNode*/ WARP_NODE_14, /*flags*/ WARP_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_1F, /*destLevel*/ LEVEL_SSL, /*destArea*/ 1, /*destNode*/ WARP_NODE_20, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_20, /*destLevel*/ LEVEL_SSL, /*destArea*/ 1, /*destNode*/ WARP_NODE_1F, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_SUCCESS, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 3, /*destNode*/ WARP_NODE_33, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_DEATH, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 3, /*destNode*/ WARP_NODE_65, /*flags*/ WARP_NO_CHECKPOINT), JUMP_LINK(script_func_local_1), JUMP_LINK(script_func_local_2), JUMP_LINK(script_func_local_3), @@ -113,16 +113,16 @@ const LevelScript level_ssl_entry[] = { END_AREA(), AREA(/*index*/ 2, ssl_geo_0007CC), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 0, 300, 6451, /*angle*/ 0, 180, 0, /*behParam*/ 0x000A0000, /*beh*/ bhvAirborneWarp), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 0, 5500, 256, /*angle*/ 0, 180, 0, /*behParam*/ 0x00140000, /*beh*/ bhvAirborneWarp), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 3070, 1280, 2900, /*angle*/ 0, 180, 0, /*behParam*/ 0x00150000, /*beh*/ bhvFadingWarp), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 2546, 1150, -2647, /*angle*/ 0, 78, 0, /*behParam*/ 0x00160000, /*beh*/ bhvFadingWarp), - WARP_NODE(/*id*/ 0x0A, /*destLevel*/ LEVEL_SSL, /*destArea*/ 0x02, /*destNode*/ 0x0A, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0x14, /*destLevel*/ LEVEL_SSL, /*destArea*/ 0x02, /*destNode*/ 0x14, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0x15, /*destLevel*/ LEVEL_SSL, /*destArea*/ 0x02, /*destNode*/ 0x16, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0x16, /*destLevel*/ LEVEL_SSL, /*destArea*/ 0x02, /*destNode*/ 0x15, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0xF0, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x03, /*destNode*/ 0x33, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0xF1, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x03, /*destNode*/ 0x65, /*flags*/ WARP_NO_CHECKPOINT), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 0, 300, 6451, /*angle*/ 0, 180, 0, /*bhvParam*/ BPARAM2(WARP_NODE_0A), /*bhv*/ bhvAirborneWarp), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 0, 5500, 256, /*angle*/ 0, 180, 0, /*bhvParam*/ BPARAM2(WARP_NODE_14), /*bhv*/ bhvAirborneWarp), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 3070, 1280, 2900, /*angle*/ 0, 180, 0, /*bhvParam*/ BPARAM2(WARP_NODE_15), /*bhv*/ bhvFadingWarp), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 2546, 1150, -2647, /*angle*/ 0, 78, 0, /*bhvParam*/ BPARAM2(WARP_NODE_16), /*bhv*/ bhvFadingWarp), + WARP_NODE(/*id*/ WARP_NODE_0A, /*destLevel*/ LEVEL_SSL, /*destArea*/ 2, /*destNode*/ WARP_NODE_0A, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_14, /*destLevel*/ LEVEL_SSL, /*destArea*/ 2, /*destNode*/ WARP_NODE_14, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_15, /*destLevel*/ LEVEL_SSL, /*destArea*/ 2, /*destNode*/ WARP_NODE_16, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_16, /*destLevel*/ LEVEL_SSL, /*destArea*/ 2, /*destNode*/ WARP_NODE_15, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_SUCCESS, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 3, /*destNode*/ WARP_NODE_33, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_DEATH, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 3, /*destNode*/ WARP_NODE_65, /*flags*/ WARP_NO_CHECKPOINT), JUMP_LINK(script_func_local_4), JUMP_LINK(script_func_local_5), INSTANT_WARP(/*index*/ 3, /*destArea*/ 3, /*displace*/ 0, 0, 0), @@ -133,8 +133,8 @@ const LevelScript level_ssl_entry[] = { END_AREA(), AREA(/*index*/ 3, ssl_geo_00088C), - WARP_NODE(/*id*/ 0xF0, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x03, /*destNode*/ 0x33, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0xF1, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x03, /*destNode*/ 0x65, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_SUCCESS, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 3, /*destNode*/ WARP_NODE_33, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_DEATH, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 3, /*destNode*/ WARP_NODE_65, /*flags*/ WARP_NO_CHECKPOINT), JUMP_LINK(script_func_local_6), TERRAIN(/*terrainData*/ ssl_seg7_area_3_collision), MACRO_OBJECTS(/*objList*/ ssl_seg7_area_3_macro_objs), diff --git a/levels/ssl/spindel/geo.inc.c b/levels/ssl/spindel/geo.inc.c index d2f28d5d..331284b3 100644 --- a/levels/ssl/spindel/geo.inc.c +++ b/levels/ssl/spindel/geo.inc.c @@ -1,12 +1,12 @@ // 0x0E000764 const GeoLayout ssl_geo_000764[] = { - GEO_CULLING_RADIUS(550), - GEO_OPEN_NODE(), - GEO_SHADOW(0x00 + SHADOW_RECTANGLE_HARDCODED_OFFSET, 0xB4, 0), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, ssl_seg7_dl_070228A8), - GEO_DISPLAY_LIST(LAYER_ALPHA, ssl_seg7_dl_070229E8), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(550), + GEO_OPEN_NODE(), + GEO_SHADOW(0x00 + SHADOW_RECTANGLE_HARDCODED_OFFSET, 0xB4, 0), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, ssl_seg7_dl_070228A8), + GEO_DISPLAY_LIST(LAYER_ALPHA, ssl_seg7_dl_070229E8), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/ssl/tox_box/geo.inc.c b/levels/ssl/tox_box/geo.inc.c index e7b9f68b..fd0a6da6 100644 --- a/levels/ssl/tox_box/geo.inc.c +++ b/levels/ssl/tox_box/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000630 const GeoLayout ssl_geo_000630[] = { - GEO_CULLING_RADIUS(4000), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, ssl_seg7_dl_0700FCE0), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(4000), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, ssl_seg7_dl_0700FCE0), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/thi/areas/1/6/geo.inc.c b/levels/thi/areas/1/6/geo.inc.c index 0e4f9125..38c5345a 100644 --- a/levels/thi/areas/1/6/geo.inc.c +++ b/levels/thi/areas/1/6/geo.inc.c @@ -1,20 +1,20 @@ // 0x0E0005B0 const GeoLayout thi_geo_0005B0[] = { - GEO_CULLING_RADIUS(300), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, thi_seg7_dl_07007648), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(300), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, thi_seg7_dl_07007648), + GEO_CLOSE_NODE(), + GEO_END(), }; // 0x0E0005C8 const GeoLayout thi_geo_0005C8[] = { - GEO_CULLING_RADIUS(300), - GEO_OPEN_NODE(), - GEO_SCALE(0x00, 19660), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, thi_seg7_dl_07007648), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(300), + GEO_OPEN_NODE(), + GEO_SCALE(0x00, 19660), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, thi_seg7_dl_07007648), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/thi/areas/1/7/geo.inc.c b/levels/thi/areas/1/7/geo.inc.c index 7efb9612..4f80264e 100644 --- a/levels/thi/areas/1/7/geo.inc.c +++ b/levels/thi/areas/1/7/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E0005F0 const GeoLayout thi_geo_0005F0[] = { - GEO_CULLING_RADIUS(1200), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, thi_seg7_dl_07007930), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(1200), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, thi_seg7_dl_07007930), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/thi/areas/1/geo.inc.c b/levels/thi/areas/1/geo.inc.c index d08e130b..36ed1983 100644 --- a/levels/thi/areas/1/geo.inc.c +++ b/levels/thi/areas/1/geo.inc.c @@ -1,36 +1,36 @@ // 0x0E000608 const GeoLayout thi_geo_000608[] = { - GEO_NODE_SCREEN_AREA(10, SCREEN_WIDTH/2, SCREEN_HEIGHT/2, SCREEN_WIDTH/2, SCREEN_HEIGHT/2), - GEO_OPEN_NODE(), - GEO_ZBUFFER(0), - GEO_OPEN_NODE(), - GEO_NODE_ORTHO(100), - GEO_OPEN_NODE(), - GEO_BACKGROUND(BACKGROUND_OCEAN_SKY, geo_skybox_main), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ZBUFFER(1), - GEO_OPEN_NODE(), - GEO_CAMERA_FRUSTUM_WITH_FUNC(45, 100, 20000, geo_camera_fov), - GEO_OPEN_NODE(), - GEO_CAMERA(1, 0, 2000, 6000, 0, 0, 0, geo_camera_main), + GEO_NODE_SCREEN_AREA(10, SCREEN_WIDTH/2, SCREEN_HEIGHT/2, SCREEN_WIDTH/2, SCREEN_HEIGHT/2), + GEO_OPEN_NODE(), + GEO_ZBUFFER(0), + GEO_OPEN_NODE(), + GEO_NODE_ORTHO(100), GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, thi_seg7_dl_07005260), - GEO_DISPLAY_LIST(LAYER_OPAQUE, thi_seg7_dl_07006968), - GEO_DISPLAY_LIST(LAYER_ALPHA, thi_seg7_dl_07007008), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, thi_seg7_dl_070072E8), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT_DECAL, thi_seg7_dl_070073C0), - GEO_ASM( 0, geo_movtex_pause_control), - GEO_ASM(0x1301, geo_movtex_draw_water_regions), - GEO_RENDER_OBJ(), - GEO_ASM( 0, geo_envfx_main), + GEO_BACKGROUND(BACKGROUND_OCEAN_SKY, geo_skybox_main), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ZBUFFER(0), - GEO_OPEN_NODE(), - GEO_ASM(0, geo_cannon_circle_base), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CLOSE_NODE(), + GEO_ZBUFFER(1), + GEO_OPEN_NODE(), + GEO_CAMERA_FRUSTUM_WITH_FUNC(45, 100, 20000, geo_camera_fov), + GEO_OPEN_NODE(), + GEO_CAMERA(1, 0, 2000, 6000, 0, 0, 0, geo_camera_main), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, thi_seg7_dl_07005260), + GEO_DISPLAY_LIST(LAYER_OPAQUE, thi_seg7_dl_07006968), + GEO_DISPLAY_LIST(LAYER_ALPHA, thi_seg7_dl_07007008), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, thi_seg7_dl_070072E8), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT_DECAL, thi_seg7_dl_070073C0), + GEO_ASM( 0, geo_movtex_pause_control), + GEO_ASM(0x1301, geo_movtex_draw_water_regions), + GEO_RENDER_OBJ(), + GEO_ASM( 0, geo_envfx_main), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ZBUFFER(0), + GEO_OPEN_NODE(), + GEO_ASM(0, geo_cannon_circle_base), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/thi/areas/1/macro.inc.c b/levels/thi/areas/1/macro.inc.c index e622e4db..22d77b3b 100644 --- a/levels/thi/areas/1/macro.inc.c +++ b/levels/thi/areas/1/macro.inc.c @@ -1,44 +1,44 @@ // 0x0700DD50 - 0x0700DEE2 const MacroObject thi_seg7_area_1_macro_objs[] = { - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_cannon_closed, /*yaw*/ 0, /*pos*/ 6656, -2832, 6964, /*behParam*/ 0x80), - MACRO_OBJECT(/*preset*/ macro_coin_line_horizontal, /*yaw*/ 0, /*pos*/ 870, -502, 2828), - MACRO_OBJECT(/*preset*/ macro_hidden_1up_in_pole, /*yaw*/ 0, /*pos*/ 4800, -110, 2250), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 90, /*pos*/ 6728, -2559, 1561, /*behParam*/ DIALOG_091), - MACRO_OBJECT(/*preset*/ macro_coin_line_horizontal, /*yaw*/ 90, /*pos*/ -66, -1637, -4944), - MACRO_OBJECT(/*preset*/ macro_huge_goomba, /*yaw*/ 0, /*pos*/ 7069, -1535, -4758), - MACRO_OBJECT(/*preset*/ macro_huge_goomba, /*yaw*/ 0, /*pos*/ 7177, -1535, -3522), - MACRO_OBJECT(/*preset*/ macro_coin_line_horizontal, /*yaw*/ 0, /*pos*/ 5711, -1677, -2944), - MACRO_OBJECT(/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ -1200, -1540, 1150), - MACRO_OBJECT(/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ -250, -1540, 1150), - MACRO_OBJECT(/*preset*/ macro_hidden_1up_trigger, /*yaw*/ 0, /*pos*/ -1200, -1540, 1150), - MACRO_OBJECT(/*preset*/ macro_hidden_1up_trigger, /*yaw*/ 0, /*pos*/ -250, -1550, 1150), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_hidden_1up, /*yaw*/ 0, /*pos*/ -777, -1544, 1233, /*behParam*/ 2), - MACRO_OBJECT(/*preset*/ macro_huge_goomba, /*yaw*/ 0, /*pos*/ 4600, -1544, 3455), - MACRO_OBJECT(/*preset*/ macro_huge_goomba, /*yaw*/ 0, /*pos*/ 3444, -522, 3011), - MACRO_OBJECT(/*preset*/ macro_huge_goomba, /*yaw*/ 0, /*pos*/ -3622, -511, 3100), - MACRO_OBJECT(/*preset*/ macro_coin_line_horizontal, /*yaw*/ 0, /*pos*/ -4911, -395, -1433), - MACRO_OBJECT(/*preset*/ macro_coin_line_horizontal, /*yaw*/ 90, /*pos*/ 199, 2233, 433), - MACRO_OBJECT(/*preset*/ macro_huge_goomba, /*yaw*/ 0, /*pos*/ -3177, 1255, -2366), - MACRO_OBJECT(/*preset*/ macro_chuckya, /*yaw*/ 0, /*pos*/ -1800, 2233, -322), - MACRO_OBJECT(/*preset*/ macro_fish_group, /*yaw*/ 0, /*pos*/ -6222, -3400, -1455), - MACRO_OBJECT(/*preset*/ macro_enemy_lakitu, /*yaw*/ 0, /*pos*/ -1905, -2223, 6541), - MACRO_OBJECT(/*preset*/ macro_fire_fly_guy, /*yaw*/ 0, /*pos*/ -1911, 0, -5822), - MACRO_OBJECT(/*preset*/ macro_fire_fly_guy, /*yaw*/ 0, /*pos*/ 6493, -2186, 5189), - MACRO_OBJECT(/*preset*/ macro_1up, /*yaw*/ 0, /*pos*/ -6000, -3566, -1320), - MACRO_OBJECT(/*preset*/ macro_fish_group, /*yaw*/ 0, /*pos*/ -6550, -3450, 4100), - MACRO_OBJECT(/*preset*/ macro_fish_group, /*yaw*/ 0, /*pos*/ -1750, -3450, 7800), - MACRO_OBJECT(/*preset*/ macro_fish_group, /*yaw*/ 0, /*pos*/ 1950, -3500, 7600), - MACRO_OBJECT(/*preset*/ macro_box_1up_running_away, /*yaw*/ 0, /*pos*/ -5712, -2190, 1100), - MACRO_OBJECT(/*preset*/ macro_box_1up_running_away, /*yaw*/ 0, /*pos*/ 6022, -1722, -633), - MACRO_OBJECT(/*preset*/ macro_wooden_post, /*yaw*/ 0, /*pos*/ -5822, -2969, 5822), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 90, /*pos*/ -886, -2559, 6655, /*behParam*/ DIALOG_165), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 0, /*pos*/ -2370, -511, 2320, /*behParam*/ DIALOG_166), - MACRO_OBJECT(/*preset*/ macro_box_star_2, /*yaw*/ 0, /*pos*/ 2600, 3500, -2400), - MACRO_OBJECT(/*preset*/ macro_huge_goomba, /*yaw*/ 0, /*pos*/ -3180, -511, 2080), - MACRO_OBJECT(/*preset*/ macro_fly_guy, /*yaw*/ 0, /*pos*/ -300, -2340, 3940), - MACRO_OBJECT(/*preset*/ macro_wooden_post, /*yaw*/ 0, /*pos*/ -520, -2560, 6660), - MACRO_OBJECT(/*preset*/ macro_koopa, /*yaw*/ 0, /*pos*/ -800, -2236, 3080), - MACRO_OBJECT(/*preset*/ macro_butterfly_triplet, /*yaw*/ 0, /*pos*/ -3111, -511, 2400), - MACRO_OBJECT(/*preset*/ macro_butterfly_triplet, /*yaw*/ 0, /*pos*/ 4844, -533, 2266), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_cannon_closed, /*yaw*/ 0, /*pos*/ 6656, -2832, 6964, /*bhvParam*/ 0x80), + MACRO_OBJECT (/*preset*/ macro_coin_line_horizontal, /*yaw*/ 0, /*pos*/ 870, -502, 2828), + MACRO_OBJECT (/*preset*/ macro_hidden_1up_in_pole, /*yaw*/ 0, /*pos*/ 4800, -110, 2250), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 90, /*pos*/ 6728, -2559, 1561, /*bhvParam*/ DIALOG_091), + MACRO_OBJECT (/*preset*/ macro_coin_line_horizontal, /*yaw*/ 90, /*pos*/ -66, -1637, -4944), + MACRO_OBJECT (/*preset*/ macro_huge_goomba, /*yaw*/ 0, /*pos*/ 7069, -1535, -4758), + MACRO_OBJECT (/*preset*/ macro_huge_goomba, /*yaw*/ 0, /*pos*/ 7177, -1535, -3522), + MACRO_OBJECT (/*preset*/ macro_coin_line_horizontal, /*yaw*/ 0, /*pos*/ 5711, -1677, -2944), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ -1200, -1540, 1150), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ -250, -1540, 1150), + MACRO_OBJECT (/*preset*/ macro_hidden_1up_trigger, /*yaw*/ 0, /*pos*/ -1200, -1540, 1150), + MACRO_OBJECT (/*preset*/ macro_hidden_1up_trigger, /*yaw*/ 0, /*pos*/ -250, -1550, 1150), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_hidden_1up, /*yaw*/ 0, /*pos*/ -777, -1544, 1233, /*bhvParam*/ 2), + MACRO_OBJECT (/*preset*/ macro_huge_goomba, /*yaw*/ 0, /*pos*/ 4600, -1544, 3455), + MACRO_OBJECT (/*preset*/ macro_huge_goomba, /*yaw*/ 0, /*pos*/ 3444, -522, 3011), + MACRO_OBJECT (/*preset*/ macro_huge_goomba, /*yaw*/ 0, /*pos*/ -3622, -511, 3100), + MACRO_OBJECT (/*preset*/ macro_coin_line_horizontal, /*yaw*/ 0, /*pos*/ -4911, -395, -1433), + MACRO_OBJECT (/*preset*/ macro_coin_line_horizontal, /*yaw*/ 90, /*pos*/ 199, 2233, 433), + MACRO_OBJECT (/*preset*/ macro_huge_goomba, /*yaw*/ 0, /*pos*/ -3177, 1255, -2366), + MACRO_OBJECT (/*preset*/ macro_chuckya, /*yaw*/ 0, /*pos*/ -1800, 2233, -322), + MACRO_OBJECT (/*preset*/ macro_fish_spawner_few_blue, /*yaw*/ 0, /*pos*/ -6222, -3400, -1455), + MACRO_OBJECT (/*preset*/ macro_enemy_lakitu, /*yaw*/ 0, /*pos*/ -1905, -2223, 6541), + MACRO_OBJECT (/*preset*/ macro_fire_fly_guy, /*yaw*/ 0, /*pos*/ -1911, 0, -5822), + MACRO_OBJECT (/*preset*/ macro_fire_fly_guy, /*yaw*/ 0, /*pos*/ 6493, -2186, 5189), + MACRO_OBJECT (/*preset*/ macro_1up, /*yaw*/ 0, /*pos*/ -6000, -3566, -1320), + MACRO_OBJECT (/*preset*/ macro_fish_spawner_few_blue, /*yaw*/ 0, /*pos*/ -6550, -3450, 4100), + MACRO_OBJECT (/*preset*/ macro_fish_spawner_few_blue, /*yaw*/ 0, /*pos*/ -1750, -3450, 7800), + MACRO_OBJECT (/*preset*/ macro_fish_spawner_few_blue, /*yaw*/ 0, /*pos*/ 1950, -3500, 7600), + MACRO_OBJECT (/*preset*/ macro_box_1up_running_away, /*yaw*/ 0, /*pos*/ -5712, -2190, 1100), + MACRO_OBJECT (/*preset*/ macro_box_1up_running_away, /*yaw*/ 0, /*pos*/ 6022, -1722, -633), + MACRO_OBJECT (/*preset*/ macro_wooden_post_1, /*yaw*/ 0, /*pos*/ -5822, -2969, 5822), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 90, /*pos*/ -886, -2559, 6655, /*bhvParam*/ DIALOG_165), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 0, /*pos*/ -2370, -511, 2320, /*bhvParam*/ DIALOG_166), + MACRO_OBJECT (/*preset*/ macro_box_star_act_2, /*yaw*/ 0, /*pos*/ 2600, 3500, -2400), + MACRO_OBJECT (/*preset*/ macro_huge_goomba, /*yaw*/ 0, /*pos*/ -3180, -511, 2080), + MACRO_OBJECT (/*preset*/ macro_fly_guy, /*yaw*/ 0, /*pos*/ -300, -2340, 3940), + MACRO_OBJECT (/*preset*/ macro_wooden_post_1, /*yaw*/ 0, /*pos*/ -520, -2560, 6660), + MACRO_OBJECT (/*preset*/ macro_koopa, /*yaw*/ 0, /*pos*/ -800, -2236, 3080), + MACRO_OBJECT (/*preset*/ macro_butterfly_triplet, /*yaw*/ 0, /*pos*/ -3111, -511, 2400), + MACRO_OBJECT (/*preset*/ macro_butterfly_triplet, /*yaw*/ 0, /*pos*/ 4844, -533, 2266), MACRO_OBJECT_END(), }; diff --git a/levels/thi/areas/2/geo.inc.c b/levels/thi/areas/2/geo.inc.c index eefb7455..36e62092 100644 --- a/levels/thi/areas/2/geo.inc.c +++ b/levels/thi/areas/2/geo.inc.c @@ -2,36 +2,36 @@ // 0x0E0006D4 const GeoLayout thi_geo_0006D4[] = { - GEO_NODE_SCREEN_AREA(10, SCREEN_WIDTH/2, SCREEN_HEIGHT/2, SCREEN_WIDTH/2, SCREEN_HEIGHT/2), - GEO_OPEN_NODE(), - GEO_ZBUFFER(0), - GEO_OPEN_NODE(), - GEO_NODE_ORTHO(100), - GEO_OPEN_NODE(), - GEO_BACKGROUND(BACKGROUND_OCEAN_SKY, geo_skybox_main), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ZBUFFER(1), - GEO_OPEN_NODE(), - GEO_CAMERA_FRUSTUM_WITH_FUNC(45, 100, 12800, geo_camera_fov), - GEO_OPEN_NODE(), - GEO_CAMERA(1, 0, 2000, 6000, 0, 0, 0, geo_camera_main), + GEO_NODE_SCREEN_AREA(10, SCREEN_WIDTH/2, SCREEN_HEIGHT/2, SCREEN_WIDTH/2, SCREEN_HEIGHT/2), + GEO_OPEN_NODE(), + GEO_ZBUFFER(0), + GEO_OPEN_NODE(), + GEO_NODE_ORTHO(100), GEO_OPEN_NODE(), - GEO_SCALE(0x00, 19660), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, thi_seg7_dl_07005260), - GEO_DISPLAY_LIST(LAYER_OPAQUE, thi_seg7_dl_07006968), - GEO_DISPLAY_LIST(LAYER_ALPHA, thi_seg7_dl_07007008), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, thi_seg7_dl_070072E8), - GEO_CLOSE_NODE(), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT_DECAL, thi_seg7_dl_07007538), - GEO_ASM( 0, geo_movtex_pause_control), - GEO_ASM(0x1302, geo_movtex_draw_water_regions), - GEO_RENDER_OBJ(), - GEO_ASM( 0, geo_envfx_main), + GEO_BACKGROUND(BACKGROUND_OCEAN_SKY, geo_skybox_main), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CLOSE_NODE(), + GEO_ZBUFFER(1), + GEO_OPEN_NODE(), + GEO_CAMERA_FRUSTUM_WITH_FUNC(45, 100, 12800, geo_camera_fov), + GEO_OPEN_NODE(), + GEO_CAMERA(1, 0, 2000, 6000, 0, 0, 0, geo_camera_main), + GEO_OPEN_NODE(), + GEO_SCALE(0x00, 19660), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, thi_seg7_dl_07005260), + GEO_DISPLAY_LIST(LAYER_OPAQUE, thi_seg7_dl_07006968), + GEO_DISPLAY_LIST(LAYER_ALPHA, thi_seg7_dl_07007008), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, thi_seg7_dl_070072E8), + GEO_CLOSE_NODE(), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT_DECAL, thi_seg7_dl_07007538), + GEO_ASM( 0, geo_movtex_pause_control), + GEO_ASM(0x1302, geo_movtex_draw_water_regions), + GEO_RENDER_OBJ(), + GEO_ASM( 0, geo_envfx_main), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/thi/areas/2/macro.inc.c b/levels/thi/areas/2/macro.inc.c index a825abe4..ba92e291 100644 --- a/levels/thi/areas/2/macro.inc.c +++ b/levels/thi/areas/2/macro.inc.c @@ -1,37 +1,37 @@ // 0x0700DEE4 - 0x0700E18E const MacroObject thi_seg7_area_2_macro_objs[] = { - MACRO_OBJECT(/*preset*/ macro_bobomb_buddy_opens_cannon, /*yaw*/ 0, /*pos*/ 1902, -767, 1318), + MACRO_OBJECT(/*preset*/ macro_bobomb_buddy_opens_cannon_1, /*yaw*/ 0, /*pos*/ 1902, -767, 1318), MACRO_OBJECT(/*preset*/ macro_floor_switch_hidden_objects, /*yaw*/ 0, /*pos*/ -1380, -766, -1770), - MACRO_OBJECT(/*preset*/ macro_hidden_box, /*yaw*/ 0, /*pos*/ -1140, -970, -1920), - MACRO_OBJECT(/*preset*/ macro_hidden_box, /*yaw*/ 0, /*pos*/ -1140, -970, -1720), - MACRO_OBJECT(/*preset*/ macro_hidden_box, /*yaw*/ 0, /*pos*/ -940, -970, -1920), - MACRO_OBJECT(/*preset*/ macro_hidden_box, /*yaw*/ 0, /*pos*/ -940, -970, -1720), - MACRO_OBJECT(/*preset*/ macro_hidden_box, /*yaw*/ 0, /*pos*/ -340, -970, -2120), - MACRO_OBJECT(/*preset*/ macro_hidden_box, /*yaw*/ 0, /*pos*/ -340, -970, -1920), - MACRO_OBJECT(/*preset*/ macro_hidden_box, /*yaw*/ 0, /*pos*/ -540, -970, -1920), - MACRO_OBJECT(/*preset*/ macro_hidden_box, /*yaw*/ 0, /*pos*/ -740, -970, -1920), - MACRO_OBJECT(/*preset*/ macro_hidden_box, /*yaw*/ 0, /*pos*/ -540, -970, -1720), - MACRO_OBJECT(/*preset*/ macro_hidden_box, /*yaw*/ 0, /*pos*/ -140, -970, -2120), - MACRO_OBJECT(/*preset*/ macro_hidden_box, /*yaw*/ 0, /*pos*/ 40, -970, -2520), - MACRO_OBJECT(/*preset*/ macro_hidden_box, /*yaw*/ 0, /*pos*/ -740, -970, -1720), - MACRO_OBJECT(/*preset*/ macro_hidden_box, /*yaw*/ 0, /*pos*/ -140, -970, -2320), - MACRO_OBJECT(/*preset*/ macro_hidden_box, /*yaw*/ 0, /*pos*/ 40, -970, -2320), - MACRO_OBJECT(/*preset*/ macro_hidden_box, /*yaw*/ 0, /*pos*/ 40, -970, -3120), - MACRO_OBJECT(/*preset*/ macro_hidden_box, /*yaw*/ 0, /*pos*/ -140, -970, -2720), - MACRO_OBJECT(/*preset*/ macro_hidden_box, /*yaw*/ 0, /*pos*/ -140, -970, -3320), - MACRO_OBJECT(/*preset*/ macro_hidden_box, /*yaw*/ 0, /*pos*/ 40, -970, -3320), - MACRO_OBJECT(/*preset*/ macro_hidden_box, /*yaw*/ 0, /*pos*/ -140, -970, -2520), - MACRO_OBJECT(/*preset*/ macro_hidden_box, /*yaw*/ 0, /*pos*/ 40, -970, -2720), - MACRO_OBJECT(/*preset*/ macro_hidden_box, /*yaw*/ 0, /*pos*/ -140, -970, -3120), - MACRO_OBJECT(/*preset*/ macro_hidden_box, /*yaw*/ 0, /*pos*/ 40, -970, -2920), - MACRO_OBJECT(/*preset*/ macro_hidden_box, /*yaw*/ 0, /*pos*/ -140, -970, -2920), - MACRO_OBJECT(/*preset*/ macro_hidden_box, /*yaw*/ 0, /*pos*/ -40, -970, -3720), - MACRO_OBJECT(/*preset*/ macro_hidden_box, /*yaw*/ 0, /*pos*/ 40, -970, -3520), - MACRO_OBJECT(/*preset*/ macro_hidden_box, /*yaw*/ 0, /*pos*/ -140, -970, -3520), - MACRO_OBJECT(/*preset*/ macro_hidden_box, /*yaw*/ 0, /*pos*/ -140, -970, -1920), - MACRO_OBJECT(/*preset*/ macro_hidden_box, /*yaw*/ 0, /*pos*/ 40, -970, -2120), - MACRO_OBJECT(/*preset*/ macro_hidden_box, /*yaw*/ 0, /*pos*/ -340, -970, -1720), - MACRO_OBJECT(/*preset*/ macro_fire_piranha_plant, /*yaw*/ 0, /*pos*/ -1837, -613, -1214), + MACRO_OBJECT(/*preset*/ macro_hidden_breakable_box, /*yaw*/ 0, /*pos*/ -1140, -970, -1920), + MACRO_OBJECT(/*preset*/ macro_hidden_breakable_box, /*yaw*/ 0, /*pos*/ -1140, -970, -1720), + MACRO_OBJECT(/*preset*/ macro_hidden_breakable_box, /*yaw*/ 0, /*pos*/ -940, -970, -1920), + MACRO_OBJECT(/*preset*/ macro_hidden_breakable_box, /*yaw*/ 0, /*pos*/ -940, -970, -1720), + MACRO_OBJECT(/*preset*/ macro_hidden_breakable_box, /*yaw*/ 0, /*pos*/ -340, -970, -2120), + MACRO_OBJECT(/*preset*/ macro_hidden_breakable_box, /*yaw*/ 0, /*pos*/ -340, -970, -1920), + MACRO_OBJECT(/*preset*/ macro_hidden_breakable_box, /*yaw*/ 0, /*pos*/ -540, -970, -1920), + MACRO_OBJECT(/*preset*/ macro_hidden_breakable_box, /*yaw*/ 0, /*pos*/ -740, -970, -1920), + MACRO_OBJECT(/*preset*/ macro_hidden_breakable_box, /*yaw*/ 0, /*pos*/ -540, -970, -1720), + MACRO_OBJECT(/*preset*/ macro_hidden_breakable_box, /*yaw*/ 0, /*pos*/ -140, -970, -2120), + MACRO_OBJECT(/*preset*/ macro_hidden_breakable_box, /*yaw*/ 0, /*pos*/ 40, -970, -2520), + MACRO_OBJECT(/*preset*/ macro_hidden_breakable_box, /*yaw*/ 0, /*pos*/ -740, -970, -1720), + MACRO_OBJECT(/*preset*/ macro_hidden_breakable_box, /*yaw*/ 0, /*pos*/ -140, -970, -2320), + MACRO_OBJECT(/*preset*/ macro_hidden_breakable_box, /*yaw*/ 0, /*pos*/ 40, -970, -2320), + MACRO_OBJECT(/*preset*/ macro_hidden_breakable_box, /*yaw*/ 0, /*pos*/ 40, -970, -3120), + MACRO_OBJECT(/*preset*/ macro_hidden_breakable_box, /*yaw*/ 0, /*pos*/ -140, -970, -2720), + MACRO_OBJECT(/*preset*/ macro_hidden_breakable_box, /*yaw*/ 0, /*pos*/ -140, -970, -3320), + MACRO_OBJECT(/*preset*/ macro_hidden_breakable_box, /*yaw*/ 0, /*pos*/ 40, -970, -3320), + MACRO_OBJECT(/*preset*/ macro_hidden_breakable_box, /*yaw*/ 0, /*pos*/ -140, -970, -2520), + MACRO_OBJECT(/*preset*/ macro_hidden_breakable_box, /*yaw*/ 0, /*pos*/ 40, -970, -2720), + MACRO_OBJECT(/*preset*/ macro_hidden_breakable_box, /*yaw*/ 0, /*pos*/ -140, -970, -3120), + MACRO_OBJECT(/*preset*/ macro_hidden_breakable_box, /*yaw*/ 0, /*pos*/ 40, -970, -2920), + MACRO_OBJECT(/*preset*/ macro_hidden_breakable_box, /*yaw*/ 0, /*pos*/ -140, -970, -2920), + MACRO_OBJECT(/*preset*/ macro_hidden_breakable_box, /*yaw*/ 0, /*pos*/ -40, -970, -3720), + MACRO_OBJECT(/*preset*/ macro_hidden_breakable_box, /*yaw*/ 0, /*pos*/ 40, -970, -3520), + MACRO_OBJECT(/*preset*/ macro_hidden_breakable_box, /*yaw*/ 0, /*pos*/ -140, -970, -3520), + MACRO_OBJECT(/*preset*/ macro_hidden_breakable_box, /*yaw*/ 0, /*pos*/ -140, -970, -1920), + MACRO_OBJECT(/*preset*/ macro_hidden_breakable_box, /*yaw*/ 0, /*pos*/ 40, -970, -2120), + MACRO_OBJECT(/*preset*/ macro_hidden_breakable_box, /*yaw*/ 0, /*pos*/ -340, -970, -1720), + MACRO_OBJECT(/*preset*/ macro_fire_piranha_plant_1, /*yaw*/ 0, /*pos*/ -1837, -613, -1214), MACRO_OBJECT(/*preset*/ macro_coin_line_horizontal, /*yaw*/ 90, /*pos*/ 29, 666, 148), MACRO_OBJECT(/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ 266, -162, 829), MACRO_OBJECT(/*preset*/ macro_tiny_goomba, /*yaw*/ 0, /*pos*/ 1881, -778, 1614), @@ -51,7 +51,7 @@ const MacroObject thi_seg7_area_2_macro_objs[] = { MACRO_OBJECT(/*preset*/ macro_box_three_coins, /*yaw*/ 0, /*pos*/ 1849, -325, -183), MACRO_OBJECT(/*preset*/ macro_tiny_goomba, /*yaw*/ 0, /*pos*/ 1033, -162, 916), MACRO_OBJECT(/*preset*/ macro_tiny_goomba, /*yaw*/ 0, /*pos*/ -550, 666, -150), - MACRO_OBJECT(/*preset*/ macro_fish_group, /*yaw*/ 0, /*pos*/ 383, -1022, 2133), + MACRO_OBJECT(/*preset*/ macro_fish_spawner_few_blue, /*yaw*/ 0, /*pos*/ 383, -1022, 2133), MACRO_OBJECT(/*preset*/ macro_tiny_goomba, /*yaw*/ 0, /*pos*/ 2133, -767, 466), MACRO_OBJECT(/*preset*/ macro_tiny_goomba, /*yaw*/ 0, /*pos*/ -1033, -153, 1050), MACRO_OBJECT(/*preset*/ macro_hidden_star_trigger, /*yaw*/ 0, /*pos*/ 1980, -880, 2100), @@ -64,9 +64,9 @@ const MacroObject thi_seg7_area_2_macro_objs[] = { MACRO_OBJECT(/*preset*/ macro_fire_spitter, /*yaw*/ 0, /*pos*/ -2133, -770, 296), MACRO_OBJECT(/*preset*/ macro_fire_spitter, /*yaw*/ 0, /*pos*/ -160, -608, 666), MACRO_OBJECT(/*preset*/ macro_butterfly_triplet, /*yaw*/ 0, /*pos*/ -1693, -890, 1746), - MACRO_OBJECT(/*preset*/ macro_thi_koopa_the_quick, /*yaw*/ 0, /*pos*/ -600, -153, 800), - MACRO_OBJECT(/*preset*/ macro_hidden_box, /*yaw*/ 0, /*pos*/ -40, -970, -3920), - MACRO_OBJECT(/*preset*/ macro_yellow_coin, /*yaw*/ 0, /*pos*/ 280, -640, -4140), + MACRO_OBJECT(/*preset*/ macro_koopa_tiny, /*yaw*/ 0, /*pos*/ -600, -153, 800), + MACRO_OBJECT(/*preset*/ macro_hidden_breakable_box, /*yaw*/ 0, /*pos*/ -40, -970, -3920), + MACRO_OBJECT(/*preset*/ macro_yellow_coin_1, /*yaw*/ 0, /*pos*/ 280, -640, -4140), MACRO_OBJECT(/*preset*/ macro_tiny_goomba, /*yaw*/ 0, /*pos*/ -2020, -890, 1720), MACRO_OBJECT_END(), }; diff --git a/levels/thi/areas/3/geo.inc.c b/levels/thi/areas/3/geo.inc.c index e3a6ebaa..3c362125 100644 --- a/levels/thi/areas/3/geo.inc.c +++ b/levels/thi/areas/3/geo.inc.c @@ -1,29 +1,29 @@ // 0x0E00079C const GeoLayout thi_geo_00079C[] = { - GEO_NODE_SCREEN_AREA(10, SCREEN_WIDTH/2, SCREEN_HEIGHT/2, SCREEN_WIDTH/2, SCREEN_HEIGHT/2), - GEO_OPEN_NODE(), - GEO_ZBUFFER(0), - GEO_OPEN_NODE(), - GEO_NODE_ORTHO(100), - GEO_OPEN_NODE(), - GEO_BACKGROUND_COLOR(0x0001), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ZBUFFER(1), - GEO_OPEN_NODE(), - GEO_CAMERA_FRUSTUM_WITH_FUNC(45, 100, 12800, geo_camera_fov), - GEO_OPEN_NODE(), - GEO_CAMERA(16, 0, 2000, 6000, 0, 0, 0, geo_camera_main), + GEO_NODE_SCREEN_AREA(10, SCREEN_WIDTH/2, SCREEN_HEIGHT/2, SCREEN_WIDTH/2, SCREEN_HEIGHT/2), + GEO_OPEN_NODE(), + GEO_ZBUFFER(0), + GEO_OPEN_NODE(), + GEO_NODE_ORTHO(100), GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, thi_seg7_dl_07007C20), - GEO_DISPLAY_LIST(LAYER_OPAQUE, thi_seg7_dl_07009670), - GEO_DISPLAY_LIST(LAYER_OPAQUE, thi_seg7_dl_07009D50), - GEO_DISPLAY_LIST(LAYER_ALPHA, thi_seg7_dl_07009F58), - GEO_RENDER_OBJ(), - GEO_ASM(0, geo_envfx_main), + GEO_BACKGROUND_COLOR(0x0001), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CLOSE_NODE(), + GEO_ZBUFFER(1), + GEO_OPEN_NODE(), + GEO_CAMERA_FRUSTUM_WITH_FUNC(45, 100, 12800, geo_camera_fov), + GEO_OPEN_NODE(), + GEO_CAMERA(16, 0, 2000, 6000, 0, 0, 0, geo_camera_main), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, thi_seg7_dl_07007C20), + GEO_DISPLAY_LIST(LAYER_OPAQUE, thi_seg7_dl_07009670), + GEO_DISPLAY_LIST(LAYER_OPAQUE, thi_seg7_dl_07009D50), + GEO_DISPLAY_LIST(LAYER_ALPHA, thi_seg7_dl_07009F58), + GEO_RENDER_OBJ(), + GEO_ASM(0, geo_envfx_main), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/thi/leveldata.c b/levels/thi/leveldata.c index f00bbf30..661da4c5 100644 --- a/levels/thi/leveldata.c +++ b/levels/thi/leveldata.c @@ -3,8 +3,8 @@ #include "surface_terrains.h" #include "moving_texture_macros.h" #include "level_misc_macros.h" -#include "macro_preset_names.h" -#include "special_preset_names.h" +#include "macro_presets.h" +#include "special_presets.h" #include "textures.h" #include "dialog_ids.h" diff --git a/levels/thi/script.c b/levels/thi/script.c index dcddbc4e..b2bda1aa 100644 --- a/levels/thi/script.c +++ b/levels/thi/script.c @@ -20,76 +20,76 @@ static const LevelScript script_func_local_1[] = { }; static const LevelScript script_func_local_2[] = { - OBJECT_WITH_ACTS(/*model*/ MODEL_NONE, /*pos*/ 0, -700, -4500, /*angle*/ 0, 0, 0, /*behParam*/ 0x03000000, /*beh*/ bhvHiddenStar, /*acts*/ ALL_ACTS), + OBJECT_WITH_ACTS(/*model*/ MODEL_NONE, /*pos*/ 0, -700, -4500, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(STAR_INDEX_ACT_4), /*bhv*/ bhvHiddenStar, /*acts*/ ALL_ACTS), RETURN(), }; static const LevelScript script_func_local_3[] = { - OBJECT_WITH_ACTS(/*model*/ MODEL_NONE, /*pos*/ -1800, 800, -1500, /*angle*/ 0, 0, 0, /*behParam*/ 0x04000000, /*beh*/ bhvHiddenRedCoinStar, /*acts*/ ALL_ACTS), - OBJECT(/*model*/ MODEL_WIGGLER_HEAD, /*pos*/ 17, 1843, -62, /*angle*/ 0, 0, 0, /*behParam*/ 0x05000000, /*beh*/ bhvWigglerHead), + OBJECT_WITH_ACTS(/*model*/ MODEL_NONE, /*pos*/ -1800, 800, -1500, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(STAR_INDEX_ACT_5), /*bhv*/ bhvHiddenRedCoinStar, /*acts*/ ALL_ACTS), + OBJECT (/*model*/ MODEL_WIGGLER_HEAD, /*pos*/ 17, 1843, -62, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(STAR_INDEX_ACT_6), /*bhv*/ bhvWigglerHead), RETURN(), }; static const LevelScript script_func_local_4[] = { - OBJECT_WITH_ACTS(/*model*/ MODEL_KOOPA_WITH_SHELL, /*pos*/ -1900, -511, 2400, /*angle*/ 0, -30, 0, /*behParam*/ 0x02030000, /*beh*/ bhvKoopa, /*acts*/ ACT_3), - OBJECT_WITH_ACTS(/*model*/ MODEL_NONE, /*pos*/ 7400, -1537, -6300, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvKoopaRaceEndpoint, /*acts*/ ACT_3), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -6556, -2969, 6565, /*angle*/ 0, 0, 0, /*behParam*/ 0x00010000, /*beh*/ bhvGoombaTripletSpawner), - OBJECT(/*model*/ MODEL_GOOMBA, /*pos*/ 6517, -2559, 4327, /*angle*/ 0, 0, 0, /*behParam*/ 0x00010000, /*beh*/ bhvGoomba), - OBJECT(/*model*/ MODEL_PIRANHA_PLANT, /*pos*/ -6336, -2047, -3861, /*angle*/ 0, 0, 0, /*behParam*/ 0x00010000, /*beh*/ bhvFirePiranhaPlant), - OBJECT(/*model*/ MODEL_PIRANHA_PLANT, /*pos*/ -5740, -2047, -6578, /*angle*/ 0, 0, 0, /*behParam*/ 0x00010000, /*beh*/ bhvFirePiranhaPlant), - OBJECT(/*model*/ MODEL_PIRANHA_PLANT, /*pos*/ -6481, -2047, -5998, /*angle*/ 0, 0, 0, /*behParam*/ 0x00010000, /*beh*/ bhvFirePiranhaPlant), - OBJECT(/*model*/ MODEL_PIRANHA_PLANT, /*pos*/ -5577, -2047, -4961, /*angle*/ 0, 0, 0, /*behParam*/ 0x00010000, /*beh*/ bhvFirePiranhaPlant), - OBJECT(/*model*/ MODEL_PIRANHA_PLANT, /*pos*/ -6865, -2047, -4568, /*angle*/ 0, 0, 0, /*behParam*/ 0x00010000, /*beh*/ bhvFirePiranhaPlant), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -4413, 204, -2140, /*angle*/ 0, 0, 0, /*behParam*/ 0x00030000, /*beh*/ bhvThiBowlingBallSpawner), - OBJECT(/*model*/ MODEL_BUBBA, /*pos*/ -6241, -3300, -716, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvBubba), - OBJECT(/*model*/ MODEL_BUBBA, /*pos*/ 1624, -3300, 8142, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvBubba), + OBJECT_WITH_ACTS(/*model*/ MODEL_KOOPA_WITH_SHELL, /*pos*/ -1900, -511, 2400, /*angle*/ 0, -30, 0, /*bhvParam*/ BPARAM1(STAR_INDEX_ACT_3) | BPARAM2(KOOPA_BP_KOOPA_THE_QUICK_THI), /*bhv*/ bhvKoopa, /*acts*/ ACT_3), + OBJECT_WITH_ACTS(/*model*/ MODEL_NONE, /*pos*/ 7400, -1537, -6300, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvKoopaRaceEndpoint, /*acts*/ ACT_3), + OBJECT (/*model*/ MODEL_NONE, /*pos*/ -6556, -2969, 6565, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(GOOMBA_TRIPLET_SPAWNER_BP_EXTRA_GOOMBAS(0) | GOOMBA_SIZE_HUGE), /*bhv*/ bhvGoombaTripletSpawner), + OBJECT (/*model*/ MODEL_GOOMBA, /*pos*/ 6517, -2559, 4327, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(GOOMBA_SIZE_HUGE), /*bhv*/ bhvGoomba), + OBJECT (/*model*/ MODEL_PIRANHA_PLANT, /*pos*/ -6336, -2047, -3861, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(STAR_INDEX_ACT_1) | BPARAM2(0x01), /*bhv*/ bhvFirePiranhaPlant), + OBJECT (/*model*/ MODEL_PIRANHA_PLANT, /*pos*/ -5740, -2047, -6578, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(STAR_INDEX_ACT_1) | BPARAM2(0x01), /*bhv*/ bhvFirePiranhaPlant), + OBJECT (/*model*/ MODEL_PIRANHA_PLANT, /*pos*/ -6481, -2047, -5998, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(STAR_INDEX_ACT_1) | BPARAM2(0x01), /*bhv*/ bhvFirePiranhaPlant), + OBJECT (/*model*/ MODEL_PIRANHA_PLANT, /*pos*/ -5577, -2047, -4961, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(STAR_INDEX_ACT_1) | BPARAM2(0x01), /*bhv*/ bhvFirePiranhaPlant), + OBJECT (/*model*/ MODEL_PIRANHA_PLANT, /*pos*/ -6865, -2047, -4568, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(STAR_INDEX_ACT_1) | BPARAM2(0x01), /*bhv*/ bhvFirePiranhaPlant), + OBJECT (/*model*/ MODEL_NONE, /*pos*/ -4413, 204, -2140, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(BBALL_BP_STYPE_THI_LARGE), /*bhv*/ bhvTHIBowlingBallSpawner), + OBJECT (/*model*/ MODEL_BUBBA, /*pos*/ -6241, -3300, -716, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvBubba), + OBJECT (/*model*/ MODEL_BUBBA, /*pos*/ 1624, -3300, 8142, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvBubba), RETURN(), }; static const LevelScript script_func_local_5[] = { - OBJECT(/*model*/ MODEL_THI_HUGE_ISLAND_TOP, /*pos*/ 0, 3891, -1533, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvThiHugeIslandTop), + OBJECT(/*model*/ MODEL_THI_HUGE_ISLAND_TOP, /*pos*/ 0, 3891, -1533, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvTHIHugeIslandTop), RETURN(), }; static const LevelScript script_func_local_6[] = { - OBJECT(/*model*/ MODEL_THI_TINY_ISLAND_TOP, /*pos*/ 0, 1167, -460, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvThiTinyIslandTop), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -1382, 80, -649, /*angle*/ 0, 0, 0, /*behParam*/ 0x00040000, /*beh*/ bhvThiBowlingBallSpawner), + OBJECT(/*model*/ MODEL_THI_TINY_ISLAND_TOP, /*pos*/ 0, 1167, -460, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvTHITinyIslandTop), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ -1382, 80, -649, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(BBALL_BP_STYPE_THI_SMALL), /*bhv*/ bhvTHIBowlingBallSpawner), RETURN(), }; static const LevelScript script_func_local_7[] = { - OBJECT(/*model*/ MODEL_THI_WARP_PIPE, /*pos*/ 6656, -1536, -5632, /*angle*/ 0, 0, 0, /*behParam*/ 0x00320000, /*beh*/ bhvWarpPipe), - OBJECT(/*model*/ MODEL_THI_WARP_PIPE, /*pos*/ -5888, -2048, -5888, /*angle*/ 0, 0, 0, /*behParam*/ 0x00330000, /*beh*/ bhvWarpPipe), - OBJECT(/*model*/ MODEL_THI_WARP_PIPE, /*pos*/ -3072, 512, -3840, /*angle*/ 0, 0, 0, /*behParam*/ 0x00340000, /*beh*/ bhvWarpPipe), - WARP_NODE(/*id*/ 0x32, /*destLevel*/ LEVEL_THI, /*destArea*/ 0x02, /*destNode*/ 0x32, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0x33, /*destLevel*/ LEVEL_THI, /*destArea*/ 0x02, /*destNode*/ 0x33, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0x34, /*destLevel*/ LEVEL_THI, /*destArea*/ 0x02, /*destNode*/ 0x34, /*flags*/ WARP_NO_CHECKPOINT), + OBJECT(/*model*/ MODEL_THI_WARP_PIPE, /*pos*/ 6656, -1536, -5632, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(WARP_NODE_32), /*bhv*/ bhvWarpPipe), + OBJECT(/*model*/ MODEL_THI_WARP_PIPE, /*pos*/ -5888, -2048, -5888, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(WARP_NODE_33), /*bhv*/ bhvWarpPipe), + OBJECT(/*model*/ MODEL_THI_WARP_PIPE, /*pos*/ -3072, 512, -3840, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(WARP_NODE_34), /*bhv*/ bhvWarpPipe), + WARP_NODE(/*id*/ WARP_NODE_32, /*destLevel*/ LEVEL_THI, /*destArea*/ 2, /*destNode*/ WARP_NODE_32, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_33, /*destLevel*/ LEVEL_THI, /*destArea*/ 2, /*destNode*/ WARP_NODE_33, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_34, /*destLevel*/ LEVEL_THI, /*destArea*/ 2, /*destNode*/ WARP_NODE_34, /*flags*/ WARP_NO_CHECKPOINT), RETURN(), }; static const LevelScript script_func_local_8[] = { - OBJECT(/*model*/ MODEL_THI_WARP_PIPE, /*pos*/ 1997, -461, -1690, /*angle*/ 0, 0, 0, /*behParam*/ 0x00320000, /*beh*/ bhvWarpPipe), - OBJECT(/*model*/ MODEL_THI_WARP_PIPE, /*pos*/ -1766, -614, -1766, /*angle*/ 0, 0, 0, /*behParam*/ 0x00330000, /*beh*/ bhvWarpPipe), - OBJECT(/*model*/ MODEL_THI_WARP_PIPE, /*pos*/ -922, 154, -1152, /*angle*/ 0, 0, 0, /*behParam*/ 0x00340000, /*beh*/ bhvWarpPipe), - WARP_NODE(/*id*/ 0x32, /*destLevel*/ LEVEL_THI, /*destArea*/ 0x01, /*destNode*/ 0x32, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0x33, /*destLevel*/ LEVEL_THI, /*destArea*/ 0x01, /*destNode*/ 0x33, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0x34, /*destLevel*/ LEVEL_THI, /*destArea*/ 0x01, /*destNode*/ 0x34, /*flags*/ WARP_NO_CHECKPOINT), + OBJECT(/*model*/ MODEL_THI_WARP_PIPE, /*pos*/ 1997, -461, -1690, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(WARP_NODE_32), /*bhv*/ bhvWarpPipe), + OBJECT(/*model*/ MODEL_THI_WARP_PIPE, /*pos*/ -1766, -614, -1766, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(WARP_NODE_33), /*bhv*/ bhvWarpPipe), + OBJECT(/*model*/ MODEL_THI_WARP_PIPE, /*pos*/ -922, 154, -1152, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(WARP_NODE_34), /*bhv*/ bhvWarpPipe), + WARP_NODE(/*id*/ WARP_NODE_32, /*destLevel*/ LEVEL_THI, /*destArea*/ 1, /*destNode*/ WARP_NODE_32, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_33, /*destLevel*/ LEVEL_THI, /*destArea*/ 1, /*destNode*/ WARP_NODE_33, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_34, /*destLevel*/ LEVEL_THI, /*destArea*/ 1, /*destNode*/ WARP_NODE_34, /*flags*/ WARP_NO_CHECKPOINT), RETURN(), }; const LevelScript level_thi_entry[] = { INIT_LEVEL(), - LOAD_MIO0( /*seg*/ 0x07, _thi_segment_7SegmentRomStart, _thi_segment_7SegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x07, _thi_segment_7SegmentRomStart, _thi_segment_7SegmentRomEnd), LOAD_MIO0_TEXTURE(/*seg*/ 0x09, _grass_mio0SegmentRomStart, _grass_mio0SegmentRomEnd), - LOAD_MIO0( /*seg*/ 0x0A, _water_skybox_mio0SegmentRomStart, _water_skybox_mio0SegmentRomEnd), - LOAD_MIO0( /*seg*/ 0x05, _group11_mio0SegmentRomStart, _group11_mio0SegmentRomEnd), - LOAD_RAW( /*seg*/ 0x0C, _group11_geoSegmentRomStart, _group11_geoSegmentRomEnd), - LOAD_MIO0( /*seg*/ 0x06, _group14_mio0SegmentRomStart, _group14_mio0SegmentRomEnd), - LOAD_RAW( /*seg*/ 0x0D, _group14_geoSegmentRomStart, _group14_geoSegmentRomEnd), - LOAD_MIO0( /*seg*/ 0x08, _common0_mio0SegmentRomStart, _common0_mio0SegmentRomEnd), - LOAD_RAW( /*seg*/ 0x0F, _common0_geoSegmentRomStart, _common0_geoSegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x0A, _water_skybox_mio0SegmentRomStart, _water_skybox_mio0SegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x05, _group11_mio0SegmentRomStart, _group11_mio0SegmentRomEnd), + LOAD_RAW (/*seg*/ 0x0C, _group11_geoSegmentRomStart, _group11_geoSegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x06, _group14_mio0SegmentRomStart, _group14_mio0SegmentRomEnd), + LOAD_RAW (/*seg*/ 0x0D, _group14_geoSegmentRomStart, _group14_geoSegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x08, _common0_mio0SegmentRomStart, _common0_mio0SegmentRomEnd), + LOAD_RAW (/*seg*/ 0x0F, _common0_geoSegmentRomStart, _common0_geoSegmentRomEnd), ALLOC_LEVEL_POOL(), - MARIO(/*model*/ MODEL_MARIO, /*behParam*/ 0x00000001, /*beh*/ bhvMario), + MARIO(/*model*/ MODEL_MARIO, /*bhvParam*/ BPARAM4(0x01), /*bhv*/ bhvMario), JUMP_LINK(script_func_global_1), JUMP_LINK(script_func_global_12), JUMP_LINK(script_func_global_15), @@ -100,16 +100,16 @@ const LevelScript level_thi_entry[] = { LOAD_MODEL_FROM_GEO(MODEL_THI_TINY_ISLAND_TOP, thi_geo_0005C8), AREA(/*index*/ 1, thi_geo_000608), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -7372, -1969, 7373, /*angle*/ 0, 149, 0, /*behParam*/ 0x000A0000, /*beh*/ bhvSpinAirborneWarp), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 410, -512, 922, /*angle*/ 0, 0, 0, /*behParam*/ 0x000B0000, /*beh*/ bhvInstantActiveWarp), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 410, -512, 717, /*angle*/ 0, 0, 0, /*behParam*/ 0x050C0000, /*beh*/ bhvWarp), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 0, 3170, -1570, /*angle*/ 0, 0, 0, /*behParam*/ 0x0A0D0000, /*beh*/ bhvWarp), - WARP_NODE(/*id*/ 0x0A, /*destLevel*/ LEVEL_THI, /*destArea*/ 0x01, /*destNode*/ 0x0A, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0x0B, /*destLevel*/ LEVEL_THI, /*destArea*/ 0x01, /*destNode*/ 0x0B, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0x0C, /*destLevel*/ LEVEL_THI, /*destArea*/ 0x03, /*destNode*/ 0x0A, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0x0D, /*destLevel*/ LEVEL_THI, /*destArea*/ 0x03, /*destNode*/ 0x0B, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0xF0, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x02, /*destNode*/ 0x37, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0xF1, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x02, /*destNode*/ 0x69, /*flags*/ WARP_NO_CHECKPOINT), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ -7372, -1969, 7373, /*angle*/ 0, 149, 0, /*bhvParam*/ BPARAM2(WARP_NODE_0A), /*bhv*/ bhvSpinAirborneWarp), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 410, -512, 922, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(WARP_NODE_0B), /*bhv*/ bhvInstantActiveWarp), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 410, -512, 717, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(5) | BPARAM2(WARP_NODE_0C), /*bhv*/ bhvWarp), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 0, 3170, -1570, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(10) | BPARAM2(WARP_NODE_0D), /*bhv*/ bhvWarp), + WARP_NODE(/*id*/ WARP_NODE_0A, /*destLevel*/ LEVEL_THI, /*destArea*/ 1, /*destNode*/ WARP_NODE_0A, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_0B, /*destLevel*/ LEVEL_THI, /*destArea*/ 1, /*destNode*/ WARP_NODE_0B, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_0C, /*destLevel*/ LEVEL_THI, /*destArea*/ 3, /*destNode*/ WARP_NODE_0A, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_0D, /*destLevel*/ LEVEL_THI, /*destArea*/ 3, /*destNode*/ WARP_NODE_0B, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_SUCCESS, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 2, /*destNode*/ WARP_NODE_37, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_DEATH, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 2, /*destNode*/ WARP_NODE_69, /*flags*/ WARP_NO_CHECKPOINT), JUMP_LINK(script_func_local_7), JUMP_LINK(script_func_local_1), JUMP_LINK(script_func_local_5), @@ -121,14 +121,14 @@ const LevelScript level_thi_entry[] = { END_AREA(), AREA(/*index*/ 2, thi_geo_0006D4), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -2211, 110, 2212, /*angle*/ 0, 149, 0, /*behParam*/ 0x000A0000, /*beh*/ bhvSpinAirborneWarp), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 280, -767, -4180, /*angle*/ 0, 0, 0, /*behParam*/ 0x000B0000, /*beh*/ bhvFadingWarp), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -1638, 0, -1988, /*angle*/ 0, -126, 0, /*behParam*/ 0x000C0000, /*beh*/ bhvFadingWarp), - WARP_NODE(/*id*/ 0x0A, /*destLevel*/ LEVEL_THI, /*destArea*/ 0x02, /*destNode*/ 0x0A, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0x0B, /*destLevel*/ LEVEL_THI, /*destArea*/ 0x02, /*destNode*/ 0x0C, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0x0C, /*destLevel*/ LEVEL_THI, /*destArea*/ 0x02, /*destNode*/ 0x0B, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0xF0, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x02, /*destNode*/ 0x33, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0xF1, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x02, /*destNode*/ 0x65, /*flags*/ WARP_NO_CHECKPOINT), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ -2211, 110, 2212, /*angle*/ 0, 149, 0, /*bhvParam*/ BPARAM2(WARP_NODE_0A), /*bhv*/ bhvSpinAirborneWarp), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 280, -767, -4180, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(WARP_NODE_0B), /*bhv*/ bhvFadingWarp), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ -1638, 0, -1988, /*angle*/ 0, -126, 0, /*bhvParam*/ BPARAM2(WARP_NODE_0C), /*bhv*/ bhvFadingWarp), + WARP_NODE(/*id*/ WARP_NODE_0A, /*destLevel*/ LEVEL_THI, /*destArea*/ 2, /*destNode*/ WARP_NODE_0A, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_0B, /*destLevel*/ LEVEL_THI, /*destArea*/ 2, /*destNode*/ WARP_NODE_0C, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_0C, /*destLevel*/ LEVEL_THI, /*destArea*/ 2, /*destNode*/ WARP_NODE_0B, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_SUCCESS, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 2, /*destNode*/ WARP_NODE_33, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_DEATH, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 2, /*destNode*/ WARP_NODE_65, /*flags*/ WARP_NO_CHECKPOINT), JUMP_LINK(script_func_local_8), JUMP_LINK(script_func_local_2), JUMP_LINK(script_func_local_6), @@ -139,14 +139,14 @@ const LevelScript level_thi_entry[] = { END_AREA(), AREA(/*index*/ 3, thi_geo_00079C), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 512, 1024, 2150, /*angle*/ 0, 180, 0, /*behParam*/ 0x000A0000, /*beh*/ bhvInstantActiveWarp), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 0, 3277, 0, /*angle*/ 0, 0, 0, /*behParam*/ 0x000B0000, /*beh*/ bhvAirborneWarp), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 512, 1024, 2355, /*angle*/ 0, 0, 0, /*behParam*/ 0x050C0000, /*beh*/ bhvWarp), - WARP_NODE(/*id*/ 0x0A, /*destLevel*/ LEVEL_THI, /*destArea*/ 0x03, /*destNode*/ 0x0A, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0x0B, /*destLevel*/ LEVEL_THI, /*destArea*/ 0x03, /*destNode*/ 0x0B, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0x0C, /*destLevel*/ LEVEL_THI, /*destArea*/ 0x01, /*destNode*/ 0x0B, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0xF0, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x02, /*destNode*/ 0x37, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0xF1, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x02, /*destNode*/ 0x69, /*flags*/ WARP_NO_CHECKPOINT), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 512, 1024, 2150, /*angle*/ 0, 180, 0, /*bhvParam*/ BPARAM2(WARP_NODE_0A), /*bhv*/ bhvInstantActiveWarp), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 0, 3277, 0, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(WARP_NODE_0B), /*bhv*/ bhvAirborneWarp), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 512, 1024, 2355, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(5) | BPARAM2(WARP_NODE_0C), /*bhv*/ bhvWarp), + WARP_NODE(/*id*/ WARP_NODE_0A, /*destLevel*/ LEVEL_THI, /*destArea*/ 3, /*destNode*/ WARP_NODE_0A, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_0B, /*destLevel*/ LEVEL_THI, /*destArea*/ 3, /*destNode*/ WARP_NODE_0B, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_0C, /*destLevel*/ LEVEL_THI, /*destArea*/ 1, /*destNode*/ WARP_NODE_0B, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_SUCCESS, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 2, /*destNode*/ WARP_NODE_37, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_DEATH, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 2, /*destNode*/ WARP_NODE_69, /*flags*/ WARP_NO_CHECKPOINT), JUMP_LINK(script_func_local_3), TERRAIN(/*terrainData*/ thi_seg7_area_3_collision), MACRO_OBJECTS(/*objList*/ thi_seg7_area_3_macro_objs), diff --git a/levels/totwc/areas/1/geo.inc.c b/levels/totwc/areas/1/geo.inc.c index 57c11e95..690cc294 100644 --- a/levels/totwc/areas/1/geo.inc.c +++ b/levels/totwc/areas/1/geo.inc.c @@ -1,28 +1,28 @@ // 0x0E000188 const GeoLayout totwc_geo_000188[] = { - GEO_NODE_SCREEN_AREA(10, SCREEN_WIDTH/2, SCREEN_HEIGHT/2, SCREEN_WIDTH/2, SCREEN_HEIGHT/2), - GEO_OPEN_NODE(), - GEO_ZBUFFER(0), - GEO_OPEN_NODE(), - GEO_NODE_ORTHO(100), - GEO_OPEN_NODE(), - GEO_BACKGROUND(BACKGROUND_BELOW_CLOUDS, geo_skybox_main), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ZBUFFER(1), - GEO_OPEN_NODE(), - GEO_CAMERA_FRUSTUM_WITH_FUNC(45, 100, 25000, geo_camera_fov), - GEO_OPEN_NODE(), - GEO_CAMERA(16, 0, 2000, 6000, 0, 0, 0, geo_camera_main), + GEO_NODE_SCREEN_AREA(10, SCREEN_WIDTH/2, SCREEN_HEIGHT/2, SCREEN_WIDTH/2, SCREEN_HEIGHT/2), + GEO_OPEN_NODE(), + GEO_ZBUFFER(0), + GEO_OPEN_NODE(), + GEO_NODE_ORTHO(100), GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, totwc_seg7_dl_07005D28), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, totwc_seg7_dl_07007048), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, totwc_seg7_dl_070078B8), - GEO_RENDER_OBJ(), - GEO_ASM(0, geo_envfx_main), + GEO_BACKGROUND(BACKGROUND_BELOW_CLOUDS, geo_skybox_main), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CLOSE_NODE(), + GEO_ZBUFFER(1), + GEO_OPEN_NODE(), + GEO_CAMERA_FRUSTUM_WITH_FUNC(45, 100, 25000, geo_camera_fov), + GEO_OPEN_NODE(), + GEO_CAMERA(16, 0, 2000, 6000, 0, 0, 0, geo_camera_main), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, totwc_seg7_dl_07005D28), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, totwc_seg7_dl_07007048), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, totwc_seg7_dl_070078B8), + GEO_RENDER_OBJ(), + GEO_ASM(0, geo_envfx_main), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/totwc/areas/1/macro.inc.c b/levels/totwc/areas/1/macro.inc.c index fc788a92..aa6b48d5 100644 --- a/levels/totwc/areas/1/macro.inc.c +++ b/levels/totwc/areas/1/macro.inc.c @@ -1,32 +1,32 @@ // 0x070088AC - 0x070089C6 const MacroObject totwc_seg7_macro_objs[] = { - MACRO_OBJECT(/*preset*/ macro_box_wing_cap, /*yaw*/ 0, /*pos*/ 0, -1760, -600), - MACRO_OBJECT(/*preset*/ macro_coin_ring_vertical, /*yaw*/ 90, /*pos*/ 0, -1000, 3000), - MACRO_OBJECT(/*preset*/ macro_coin_ring_vertical, /*yaw*/ 0, /*pos*/ -3500, -200, 0), - MACRO_OBJECT(/*preset*/ macro_coin_ring_vertical, /*yaw*/ 0, /*pos*/ 4500, 1400, 0), - MACRO_OBJECT(/*preset*/ macro_coin_ring_vertical, /*yaw*/ 90, /*pos*/ 0, 600, -4000), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -100, 800, -4000), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -3500, 0, 100), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 100, -800, 3000), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 4500, 1600, -100), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 100, 800, -4000), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -3500, 0, -100), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -100, -800, 3000), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 4500, 1600, 100), - MACRO_OBJECT(/*preset*/ macro_yellow_coin, /*yaw*/ 0, /*pos*/ 2913, 1200, -2941), - MACRO_OBJECT(/*preset*/ macro_yellow_coin, /*yaw*/ 0, /*pos*/ 3954, 1400, -1817), - MACRO_OBJECT(/*preset*/ macro_yellow_coin, /*yaw*/ 0, /*pos*/ 1554, 1000, -3680), - MACRO_OBJECT(/*preset*/ macro_yellow_coin, /*yaw*/ 0, /*pos*/ -2657, 400, -2742), - MACRO_OBJECT(/*preset*/ macro_yellow_coin, /*yaw*/ 0, /*pos*/ -1485, 600, -3628), - MACRO_OBJECT(/*preset*/ macro_yellow_coin, /*yaw*/ 0, /*pos*/ -3231, 200, -1514), - MACRO_OBJECT(/*preset*/ macro_yellow_coin, /*yaw*/ 0, /*pos*/ -2197, -400, 2142), - MACRO_OBJECT(/*preset*/ macro_yellow_coin, /*yaw*/ 0, /*pos*/ -3056, -200, 1310), - MACRO_OBJECT(/*preset*/ macro_yellow_coin, /*yaw*/ 0, /*pos*/ -1144, -600, 2742), - MACRO_OBJECT(/*preset*/ macro_yellow_coin, /*yaw*/ 0, /*pos*/ 3680, 1800, 1439), - MACRO_OBJECT(/*preset*/ macro_yellow_coin, /*yaw*/ 0, /*pos*/ 2080, 2000, 2080), - MACRO_OBJECT(/*preset*/ macro_yellow_coin, /*yaw*/ 0, /*pos*/ 920, 2200, 1920), - MACRO_OBJECT(/*preset*/ macro_yellow_coin, /*yaw*/ 0, /*pos*/ -40, 2400, 1520), - MACRO_OBJECT(/*preset*/ macro_yellow_coin, /*yaw*/ 0, /*pos*/ -960, 2600, 1040), - MACRO_OBJECT(/*preset*/ macro_yellow_coin, /*yaw*/ 0, /*pos*/ -1760, 2800, 600), + MACRO_OBJECT(/*preset*/ macro_box_wing_cap, /*yaw*/ 0, /*pos*/ 0, -1760, -600), + MACRO_OBJECT(/*preset*/ macro_coin_ring_vertical_flying, /*yaw*/ 90, /*pos*/ 0, -1000, 3000), + MACRO_OBJECT(/*preset*/ macro_coin_ring_vertical_flying, /*yaw*/ 0, /*pos*/ -3500, -200, 0), + MACRO_OBJECT(/*preset*/ macro_coin_ring_vertical_flying, /*yaw*/ 0, /*pos*/ 4500, 1400, 0), + MACRO_OBJECT(/*preset*/ macro_coin_ring_vertical_flying, /*yaw*/ 90, /*pos*/ 0, 600, -4000), + MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -100, 800, -4000), + MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -3500, 0, 100), + MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 100, -800, 3000), + MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 4500, 1600, -100), + MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 100, 800, -4000), + MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -3500, 0, -100), + MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -100, -800, 3000), + MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 4500, 1600, 100), + MACRO_OBJECT(/*preset*/ macro_yellow_coin_1, /*yaw*/ 0, /*pos*/ 2913, 1200, -2941), + MACRO_OBJECT(/*preset*/ macro_yellow_coin_1, /*yaw*/ 0, /*pos*/ 3954, 1400, -1817), + MACRO_OBJECT(/*preset*/ macro_yellow_coin_1, /*yaw*/ 0, /*pos*/ 1554, 1000, -3680), + MACRO_OBJECT(/*preset*/ macro_yellow_coin_1, /*yaw*/ 0, /*pos*/ -2657, 400, -2742), + MACRO_OBJECT(/*preset*/ macro_yellow_coin_1, /*yaw*/ 0, /*pos*/ -1485, 600, -3628), + MACRO_OBJECT(/*preset*/ macro_yellow_coin_1, /*yaw*/ 0, /*pos*/ -3231, 200, -1514), + MACRO_OBJECT(/*preset*/ macro_yellow_coin_1, /*yaw*/ 0, /*pos*/ -2197, -400, 2142), + MACRO_OBJECT(/*preset*/ macro_yellow_coin_1, /*yaw*/ 0, /*pos*/ -3056, -200, 1310), + MACRO_OBJECT(/*preset*/ macro_yellow_coin_1, /*yaw*/ 0, /*pos*/ -1144, -600, 2742), + MACRO_OBJECT(/*preset*/ macro_yellow_coin_1, /*yaw*/ 0, /*pos*/ 3680, 1800, 1439), + MACRO_OBJECT(/*preset*/ macro_yellow_coin_1, /*yaw*/ 0, /*pos*/ 2080, 2000, 2080), + MACRO_OBJECT(/*preset*/ macro_yellow_coin_1, /*yaw*/ 0, /*pos*/ 920, 2200, 1920), + MACRO_OBJECT(/*preset*/ macro_yellow_coin_1, /*yaw*/ 0, /*pos*/ -40, 2400, 1520), + MACRO_OBJECT(/*preset*/ macro_yellow_coin_1, /*yaw*/ 0, /*pos*/ -960, 2600, 1040), + MACRO_OBJECT(/*preset*/ macro_yellow_coin_1, /*yaw*/ 0, /*pos*/ -1760, 2800, 600), MACRO_OBJECT_END(), }; diff --git a/levels/totwc/cloud/geo.inc.c b/levels/totwc/cloud/geo.inc.c index 6f6888e5..24451f5c 100644 --- a/levels/totwc/cloud/geo.inc.c +++ b/levels/totwc/cloud/geo.inc.c @@ -1,11 +1,11 @@ // 0x0E000160 const GeoLayout totwc_geo_000160[] = { - GEO_CULLING_RADIUS(2000), - GEO_OPEN_NODE(), - GEO_BILLBOARD(), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, totwc_seg7_dl_070079A8), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(2000), + GEO_OPEN_NODE(), + GEO_BILLBOARD(), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, totwc_seg7_dl_070079A8), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/totwc/leveldata.c b/levels/totwc/leveldata.c index 910f4e23..b300a991 100644 --- a/levels/totwc/leveldata.c +++ b/levels/totwc/leveldata.c @@ -3,8 +3,8 @@ #include "surface_terrains.h" #include "moving_texture_macros.h" #include "level_misc_macros.h" -#include "macro_preset_names.h" -#include "special_preset_names.h" +#include "macro_presets.h" +#include "special_presets.h" #include "textures.h" #include "make_const_nonconst.h" diff --git a/levels/totwc/script.c b/levels/totwc/script.c index d0172c76..7664baae 100644 --- a/levels/totwc/script.c +++ b/levels/totwc/script.c @@ -17,36 +17,36 @@ #include "levels/totwc/header.h" static const LevelScript script_func_local_1[] = { - OBJECT(/*model*/ MODEL_CAP_SWITCH, /*pos*/ 0, -2047, 10, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvCapSwitch), + OBJECT(/*model*/ MODEL_CAP_SWITCH, /*pos*/ 0, -2047, 10, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvCapSwitch), RETURN(), }; static const LevelScript script_func_local_2[] = { - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 800, -1700, 0, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvHiddenRedCoinStar), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 800, -1700, 0, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(STAR_INDEX_ACT_1), /*bhv*/ bhvHiddenRedCoinStar), RETURN(), }; const LevelScript level_totwc_entry[] = { INIT_LEVEL(), - LOAD_MIO0( /*seg*/ 0x07, _totwc_segment_7SegmentRomStart, _totwc_segment_7SegmentRomEnd), - LOAD_MIO0( /*seg*/ 0x0A, _cloud_floor_skybox_mio0SegmentRomStart, _cloud_floor_skybox_mio0SegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x07, _totwc_segment_7SegmentRomStart, _totwc_segment_7SegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x0A, _cloud_floor_skybox_mio0SegmentRomStart, _cloud_floor_skybox_mio0SegmentRomEnd), LOAD_MIO0_TEXTURE(/*seg*/ 0x09, _sky_mio0SegmentRomStart, _sky_mio0SegmentRomEnd), - LOAD_MIO0( /*seg*/ 0x05, _group8_mio0SegmentRomStart, _group8_mio0SegmentRomEnd), - LOAD_RAW( /*seg*/ 0x0C, _group8_geoSegmentRomStart, _group8_geoSegmentRomEnd), - LOAD_MIO0( /*seg*/ 0x08, _common0_mio0SegmentRomStart, _common0_mio0SegmentRomEnd), - LOAD_RAW( /*seg*/ 0x0F, _common0_geoSegmentRomStart, _common0_geoSegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x05, _group8_mio0SegmentRomStart, _group8_mio0SegmentRomEnd), + LOAD_RAW (/*seg*/ 0x0C, _group8_geoSegmentRomStart, _group8_geoSegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x08, _common0_mio0SegmentRomStart, _common0_mio0SegmentRomEnd), + LOAD_RAW (/*seg*/ 0x0F, _common0_geoSegmentRomStart, _common0_geoSegmentRomEnd), ALLOC_LEVEL_POOL(), - MARIO(/*model*/ MODEL_MARIO, /*behParam*/ 0x00000001, /*beh*/ bhvMario), + MARIO(/*model*/ MODEL_MARIO, /*bhvParam*/ BPARAM4(0x01), /*bhv*/ bhvMario), JUMP_LINK(script_func_global_1), JUMP_LINK(script_func_global_9), LOAD_MODEL_FROM_GEO(MODEL_LEVEL_GEOMETRY_03, totwc_geo_000160), AREA(/*index*/ 1, totwc_geo_000188), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -4095, 2935, 0, /*angle*/ 0, 90, 0, /*behParam*/ 0x000A0000, /*beh*/ bhvFlyingWarp), - WARP_NODE(/*id*/ 0x0A, /*destLevel*/ LEVEL_TOTWC, /*destArea*/ 0x01, /*destNode*/ 0x0A, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0xF3, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x01, /*destNode*/ 0x20, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0xF0, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x01, /*destNode*/ 0x26, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0xF1, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x01, /*destNode*/ 0x23, /*flags*/ WARP_NO_CHECKPOINT), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ -4095, 2935, 0, /*angle*/ 0, 90, 0, /*bhvParam*/ BPARAM2(WARP_NODE_0A), /*bhv*/ bhvFlyingWarp), + WARP_NODE(/*id*/ WARP_NODE_0A, /*destLevel*/ LEVEL_TOTWC, /*destArea*/ 1, /*destNode*/ WARP_NODE_0A, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_WARP_FLOOR, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 1, /*destNode*/ WARP_NODE_20, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_SUCCESS, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 1, /*destNode*/ WARP_NODE_26, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_DEATH, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 1, /*destNode*/ WARP_NODE_23, /*flags*/ WARP_NO_CHECKPOINT), JUMP_LINK(script_func_local_2), JUMP_LINK(script_func_local_1), TERRAIN(/*terrainData*/ totwc_seg7_collision), diff --git a/levels/ttc/areas/1/geo.inc.c b/levels/ttc/areas/1/geo.inc.c index 9773fc7b..06f9dd77 100644 --- a/levels/ttc/areas/1/geo.inc.c +++ b/levels/ttc/areas/1/geo.inc.c @@ -1,31 +1,31 @@ // 0x0E0003B8 const GeoLayout ttc_geo_0003B8[] = { - GEO_NODE_SCREEN_AREA(10, SCREEN_WIDTH/2, SCREEN_HEIGHT/2, SCREEN_WIDTH/2, SCREEN_HEIGHT/2), - GEO_OPEN_NODE(), - GEO_ZBUFFER(0), - GEO_OPEN_NODE(), - GEO_NODE_ORTHO(100), - GEO_OPEN_NODE(), - GEO_BACKGROUND_COLOR(0xC7FF), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ZBUFFER(1), - GEO_OPEN_NODE(), - GEO_CAMERA_FRUSTUM_WITH_FUNC(45, 100, 12800, geo_camera_fov), - GEO_OPEN_NODE(), - GEO_CAMERA(2, 0, 2000, 6000, 0, 0, 0, geo_camera_main), + GEO_NODE_SCREEN_AREA(10, SCREEN_WIDTH/2, SCREEN_HEIGHT/2, SCREEN_WIDTH/2, SCREEN_HEIGHT/2), + GEO_OPEN_NODE(), + GEO_ZBUFFER(0), + GEO_OPEN_NODE(), + GEO_NODE_ORTHO(100), GEO_OPEN_NODE(), - GEO_ASM( 0, geo_movtex_pause_control), - GEO_ASM(0x1400, geo_movtex_update_horizontal), - GEO_ASM(0x1401, geo_movtex_update_horizontal), - GEO_DISPLAY_LIST(LAYER_OPAQUE, ttc_seg7_dl_0700AD38), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, ttc_seg7_dl_0700B1D8), - GEO_DISPLAY_LIST(LAYER_ALPHA, ttc_seg7_dl_0700E878), - GEO_RENDER_OBJ(), - GEO_ASM( 0, geo_envfx_main), + GEO_BACKGROUND_COLOR(0xC7FF), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CLOSE_NODE(), + GEO_ZBUFFER(1), + GEO_OPEN_NODE(), + GEO_CAMERA_FRUSTUM_WITH_FUNC(45, 100, 12800, geo_camera_fov), + GEO_OPEN_NODE(), + GEO_CAMERA(2, 0, 2000, 6000, 0, 0, 0, geo_camera_main), + GEO_OPEN_NODE(), + GEO_ASM( 0, geo_movtex_pause_control), + GEO_ASM(0x1400, geo_movtex_update_horizontal), + GEO_ASM(0x1401, geo_movtex_update_horizontal), + GEO_DISPLAY_LIST(LAYER_OPAQUE, ttc_seg7_dl_0700AD38), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, ttc_seg7_dl_0700B1D8), + GEO_DISPLAY_LIST(LAYER_ALPHA, ttc_seg7_dl_0700E878), + GEO_RENDER_OBJ(), + GEO_ASM( 0, geo_envfx_main), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/ttc/areas/1/macro.inc.c b/levels/ttc/areas/1/macro.inc.c index 93db79e8..24768926 100644 --- a/levels/ttc/areas/1/macro.inc.c +++ b/levels/ttc/areas/1/macro.inc.c @@ -1,114 +1,114 @@ // 0x07015B24 - 0x07015F72 const MacroObject ttc_seg7_macro_objs[] = { - MACRO_OBJECT(/*preset*/ macro_ttc_rotating_cube, /*yaw*/ 45, /*pos*/ -1032, -3291, 1070), - MACRO_OBJECT(/*preset*/ macro_ttc_rotating_cube, /*yaw*/ 90, /*pos*/ -1881, 1767, -446), - MACRO_OBJECT(/*preset*/ macro_ttc_rotating_cube, /*yaw*/ 90, /*pos*/ -1870, 2068, 362), - MACRO_OBJECT(/*preset*/ macro_ttc_rotating_cube, /*yaw*/ 225, /*pos*/ -770, -4361, -423), - MACRO_OBJECT(/*preset*/ macro_ttc_rotating_cube, /*yaw*/ 135, /*pos*/ -1314, -3691, 788), - MACRO_OBJECT(/*preset*/ macro_ttc_rotating_cube, /*yaw*/ 135, /*pos*/ -1314, -2892, 1353), - MACRO_OBJECT(/*preset*/ macro_ttc_rotating_prism, /*yaw*/ 315, /*pos*/ 780, 5767, -1027), - MACRO_OBJECT(/*preset*/ macro_ttc_rotating_prism, /*yaw*/ 315, /*pos*/ 1063, 5562, -744), - MACRO_OBJECT(/*preset*/ macro_ttc_pendulum, /*yaw*/ 45, /*pos*/ -1350, 748, -1208), - MACRO_OBJECT(/*preset*/ macro_ttc_pendulum, /*yaw*/ 45, /*pos*/ -690, 901, -910), - MACRO_OBJECT(/*preset*/ macro_ttc_pendulum, /*yaw*/ 45, /*pos*/ -1389, -3030, -1028), - MACRO_OBJECT(/*preset*/ macro_ttc_pendulum, /*yaw*/ 45, /*pos*/ 937, -3867, -1041), - MACRO_OBJECT(/*preset*/ macro_ttc_large_treadmill, /*yaw*/ 135, /*pos*/ -139, -4408, -1056), - MACRO_OBJECT(/*preset*/ macro_ttc_small_treadmill, /*yaw*/ 90, /*pos*/ 618, 3656, 148), - MACRO_OBJECT(/*preset*/ macro_ttc_small_treadmill, /*yaw*/ 270, /*pos*/ 963, 3297, 608), - MACRO_OBJECT(/*preset*/ macro_ttc_small_treadmill, /*yaw*/ 90, /*pos*/ 1306, 2939, 1069), - MACRO_OBJECT(/*preset*/ macro_ttc_small_treadmill, /*yaw*/ 315, /*pos*/ -1179, -1453, -792), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_ttc_push_block, /*yaw*/ 180, /*pos*/ 174, 1248, 2040, /*behParam*/ 2), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_ttc_push_block, /*yaw*/ 45, /*pos*/ -1321, 1490, -1563, /*behParam*/ 0), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_ttc_push_block, /*yaw*/ 45, /*pos*/ -1076, 1730, -1808, /*behParam*/ 5), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_ttc_push_block, /*yaw*/ 45, /*pos*/ -1319, 1970, -1564, /*behParam*/ 10), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_ttc_push_block, /*yaw*/ 180, /*pos*/ -517, 3175, 2040, /*behParam*/ 0), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_ttc_push_block, /*yaw*/ 180, /*pos*/ -170, 1248, 2040, /*behParam*/ 1), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_ttc_push_block, /*yaw*/ 180, /*pos*/ -515, 1248, 2040, /*behParam*/ 0), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_ttc_push_block, /*yaw*/ 0, /*pos*/ -175, -1351, -2039, /*behParam*/ 0), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_ttc_push_block, /*yaw*/ 180, /*pos*/ -515, -2590, 2040, /*behParam*/ 0), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_ttc_push_block, /*yaw*/ 180, /*pos*/ 518, 3175, 2040, /*behParam*/ 3), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_ttc_push_block, /*yaw*/ 180, /*pos*/ -171, 3175, 2040, /*behParam*/ 1), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_ttc_push_block, /*yaw*/ 180, /*pos*/ 174, 3175, 2040, /*behParam*/ 2), - MACRO_OBJECT(/*preset*/ macro_ttc_rotating_hexagon, /*yaw*/ 0, /*pos*/ 1490, -2088, -873), - MACRO_OBJECT(/*preset*/ macro_ttc_rotating_hexagon, /*yaw*/ 0, /*pos*/ -708, -1606, -1589), - MACRO_OBJECT(/*preset*/ macro_ttc_rotating_hexagon, /*yaw*/ 0, /*pos*/ 954, -1627, -1448), - MACRO_OBJECT(/*preset*/ macro_ttc_rotating_hexagon, /*yaw*/ 0, /*pos*/ 1215, -1781, -1215), - MACRO_OBJECT(/*preset*/ macro_ttc_rotating_hexagon, /*yaw*/ 0, /*pos*/ 1052, -1934, -769), - MACRO_OBJECT(/*preset*/ macro_ttc_rotating_triangle, /*yaw*/ 225, /*pos*/ -620, 1229, 1233), - MACRO_OBJECT(/*preset*/ macro_ttc_rotating_triangle, /*yaw*/ 315, /*pos*/ 1050, -19, -1037), - MACRO_OBJECT(/*preset*/ macro_ttc_pit_block, /*yaw*/ 315, /*pos*/ -1100, -71, -1030), - MACRO_OBJECT(/*preset*/ macro_ttc_clock_hand, /*yaw*/ 225, /*pos*/ 0, 6011, 0), - MACRO_OBJECT(/*preset*/ macro_ttc_clock_hand, /*yaw*/ 45, /*pos*/ 0, -2487, 0), - MACRO_OBJECT(/*preset*/ macro_ttc_spinner, /*yaw*/ 135, /*pos*/ 1102, -3619, 1682), - MACRO_OBJECT(/*preset*/ macro_ttc_spinner, /*yaw*/ 90, /*pos*/ 424, -3312, 1959), - MACRO_OBJECT(/*preset*/ macro_ttc_spinner, /*yaw*/ 135, /*pos*/ 1102, -3004, 1682), - MACRO_OBJECT(/*preset*/ macro_ttc_spinner, /*yaw*/ 135, /*pos*/ 1584, -2697, 1200), - MACRO_OBJECT(/*preset*/ macro_ttc_spinner, /*yaw*/ 135, /*pos*/ 1582, -3619, 1203), - MACRO_OBJECT(/*preset*/ macro_ttc_spinner, /*yaw*/ 135, /*pos*/ -762, 4347, 1047), - MACRO_OBJECT(/*preset*/ macro_ttc_spinner, /*yaw*/ 90, /*pos*/ 424, -3926, 1959), - MACRO_OBJECT(/*preset*/ macro_ttc_spinner, /*yaw*/ 135, /*pos*/ 1102, -4233, 1682), - MACRO_OBJECT(/*preset*/ macro_ttc_spinner, /*yaw*/ 135, /*pos*/ 1102, -4848, 1682), - MACRO_OBJECT(/*preset*/ macro_ttc_spinner, /*yaw*/ 90, /*pos*/ 424, -4540, 1959), - MACRO_OBJECT(/*preset*/ macro_ttc_spinner, /*yaw*/ 315, /*pos*/ -1037, 4244, 772), - MACRO_OBJECT(/*preset*/ macro_ttc_spinner, /*yaw*/ 0, /*pos*/ 1828, 3835, -50), - MACRO_OBJECT(/*preset*/ macro_ttc_spinner, /*yaw*/ 0, /*pos*/ 1459, 3835, -357), - MACRO_OBJECT(/*preset*/ macro_ttc_spinner, /*yaw*/ 0, /*pos*/ 1091, 3835, -665), - MACRO_OBJECT(/*preset*/ macro_ttc_small_gear, /*yaw*/ 0, /*pos*/ 1580, -4854, -825), - MACRO_OBJECT(/*preset*/ macro_ttc_small_gear, /*yaw*/ 0, /*pos*/ -1692, 1022, -1157), - MACRO_OBJECT(/*preset*/ macro_ttc_small_gear, /*yaw*/ 0, /*pos*/ 2098, 7007, 2243), - MACRO_OBJECT(/*preset*/ macro_ttc_large_gear, /*yaw*/ 0, /*pos*/ 1801, -4843, -731), - MACRO_OBJECT(/*preset*/ macro_ttc_large_gear, /*yaw*/ 0, /*pos*/ -1477, 1044, -1088), - MACRO_OBJECT(/*preset*/ macro_ttc_large_gear, /*yaw*/ 0, /*pos*/ 2268, 7030, 2227), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 800, -4400, 1900), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 800, -3700, 1900), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 800, -3000, 1900), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 1780, -3300, 1000), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 1388, -3300, 1428), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 200, -3000, 2000), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 200, -3700, 2000), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 200, -4400, 2000), - MACRO_OBJECT(/*preset*/ macro_hidden_1up_in_pole, /*yaw*/ 0, /*pos*/ -1080, 90, 1575), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_ttc_elevator_platform, /*yaw*/ 45, /*pos*/ -1179, 445, 1413, /*behParam*/ 6), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_ttc_elevator_platform, /*yaw*/ 315, /*pos*/ -1524, -1454, 1129, /*behParam*/ 2), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_circling_amp, /*yaw*/ 0, /*pos*/ -980, -700, 1450, /*behParam*/ 1), - MACRO_OBJECT(/*preset*/ macro_blue_coin_switch, /*yaw*/ 45, /*pos*/ -1203, -19, -170), - MACRO_OBJECT(/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ 0, 20, -1400), - MACRO_OBJECT(/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ -250, 20, -1700), - MACRO_OBJECT(/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ 250, 20, -1700), - MACRO_OBJECT(/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ 0, 20, -2000), - MACRO_OBJECT(/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ 500, 20, -2000), - MACRO_OBJECT(/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ -500, 20, -2000), - MACRO_OBJECT(/*preset*/ macro_heave_ho, /*yaw*/ 0, /*pos*/ 880, -19, 1160), - MACRO_OBJECT(/*preset*/ macro_fire_spitter, /*yaw*/ 0, /*pos*/ 800, -2460, 160), - MACRO_OBJECT(/*preset*/ macro_coin_line_horizontal, /*yaw*/ 45, /*pos*/ -1120, -820, 1320), - MACRO_OBJECT(/*preset*/ macro_fire_spitter, /*yaw*/ 0, /*pos*/ -571, 6020, -1414), - MACRO_OBJECT(/*preset*/ macro_recovery_heart, /*yaw*/ 0, /*pos*/ 620, -5150, 1540), - MACRO_OBJECT(/*preset*/ macro_hidden_1up_trigger, /*yaw*/ 0, /*pos*/ -520, 1351, 1919), - MACRO_OBJECT(/*preset*/ macro_hidden_1up_trigger, /*yaw*/ 0, /*pos*/ -165, 1351, 1919), - MACRO_OBJECT(/*preset*/ macro_hidden_1up_trigger, /*yaw*/ 0, /*pos*/ 182, 1351, 1919), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_hidden_1up, /*yaw*/ 0, /*pos*/ 657, 1368, 1879, /*behParam*/ 3), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_circling_amp, /*yaw*/ 0, /*pos*/ -700, -2350, -700, /*behParam*/ 1), - MACRO_OBJECT(/*preset*/ macro_box_1up, /*yaw*/ 0, /*pos*/ 1883, 4150, 550), - MACRO_OBJECT(/*preset*/ macro_recovery_heart, /*yaw*/ 0, /*pos*/ -1333, 350, 1116), - MACRO_OBJECT(/*preset*/ macro_box_1up, /*yaw*/ 45, /*pos*/ -1101, 6316, -685), - MACRO_OBJECT(/*preset*/ macro_bobomb, /*yaw*/ 0, /*pos*/ 1077, -4822, 638), - MACRO_OBJECT(/*preset*/ macro_bobomb, /*yaw*/ 0, /*pos*/ 1683, -4822, 189), - MACRO_OBJECT(/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ 0, 20, -1700), - MACRO_OBJECT(/*preset*/ macro_ttc_rotating_hexagon, /*yaw*/ 0, /*pos*/ -1020, 1229, 537), - MACRO_OBJECT(/*preset*/ macro_box_ten_coins, /*yaw*/ 45, /*pos*/ 2350, 5600, 2350), - MACRO_OBJECT(/*preset*/ macro_box_ten_coins, /*yaw*/ 0, /*pos*/ 0, 4783, 0), - MACRO_OBJECT(/*preset*/ macro_box_three_coins, /*yaw*/ 45, /*pos*/ -1140, -3720, -1620), - MACRO_OBJECT(/*preset*/ macro_box_three_coins, /*yaw*/ 45, /*pos*/ 840, -2200, 860), - MACRO_OBJECT(/*preset*/ macro_yellow_coin, /*yaw*/ 0, /*pos*/ -770, -3800, -440), - MACRO_OBJECT(/*preset*/ macro_yellow_coin, /*yaw*/ 0, /*pos*/ -770, -3700, -440), - MACRO_OBJECT(/*preset*/ macro_box_ten_coins, /*yaw*/ 0, /*pos*/ 280, -4920, 1660), - MACRO_OBJECT(/*preset*/ macro_box_three_coins, /*yaw*/ 45, /*pos*/ 1240, 300, 840), - MACRO_OBJECT(/*preset*/ macro_box_three_coins, /*yaw*/ 45, /*pos*/ 520, 300, 1500), - MACRO_OBJECT(/*preset*/ macro_box_ten_coins, /*yaw*/ 0, /*pos*/ -400, 3600, 1880), - MACRO_OBJECT(/*preset*/ macro_box_three_coins, /*yaw*/ 0, /*pos*/ -40, 4160, -1280), - MACRO_OBJECT(/*preset*/ macro_box_three_coins, /*yaw*/ 45, /*pos*/ -1160, 2920, -840), - MACRO_OBJECT(/*preset*/ macro_box_ten_coins, /*yaw*/ 45, /*pos*/ -780, 6316, -1020), - MACRO_OBJECT(/*preset*/ macro_ttc_large_treadmill_2, /*yaw*/ 45, /*pos*/ 1313, 6190, 1313), - MACRO_OBJECT(/*preset*/ macro_ttc_small_treadmill_2, /*yaw*/ 0, /*pos*/ 1851, -2488, -98), + MACRO_OBJECT (/*preset*/ macro_ttc_rotating_cube, /*yaw*/ 45, /*pos*/ -1032, -3291, 1070), + MACRO_OBJECT (/*preset*/ macro_ttc_rotating_cube, /*yaw*/ 90, /*pos*/ -1881, 1767, -446), + MACRO_OBJECT (/*preset*/ macro_ttc_rotating_cube, /*yaw*/ 90, /*pos*/ -1870, 2068, 362), + MACRO_OBJECT (/*preset*/ macro_ttc_rotating_cube, /*yaw*/ 225, /*pos*/ -770, -4361, -423), + MACRO_OBJECT (/*preset*/ macro_ttc_rotating_cube, /*yaw*/ 135, /*pos*/ -1314, -3691, 788), + MACRO_OBJECT (/*preset*/ macro_ttc_rotating_cube, /*yaw*/ 135, /*pos*/ -1314, -2892, 1353), + MACRO_OBJECT (/*preset*/ macro_ttc_rotating_prism, /*yaw*/ 315, /*pos*/ 780, 5767, -1027), + MACRO_OBJECT (/*preset*/ macro_ttc_rotating_prism, /*yaw*/ 315, /*pos*/ 1063, 5562, -744), + MACRO_OBJECT (/*preset*/ macro_ttc_pendulum, /*yaw*/ 45, /*pos*/ -1350, 748, -1208), + MACRO_OBJECT (/*preset*/ macro_ttc_pendulum, /*yaw*/ 45, /*pos*/ -690, 901, -910), + MACRO_OBJECT (/*preset*/ macro_ttc_pendulum, /*yaw*/ 45, /*pos*/ -1389, -3030, -1028), + MACRO_OBJECT (/*preset*/ macro_ttc_pendulum, /*yaw*/ 45, /*pos*/ 937, -3867, -1041), + MACRO_OBJECT (/*preset*/ macro_ttc_large_treadmill_1, /*yaw*/ 135, /*pos*/ -139, -4408, -1056), + MACRO_OBJECT (/*preset*/ macro_ttc_small_treadmill_1, /*yaw*/ 90, /*pos*/ 618, 3656, 148), + MACRO_OBJECT (/*preset*/ macro_ttc_small_treadmill_1, /*yaw*/ 270, /*pos*/ 963, 3297, 608), + MACRO_OBJECT (/*preset*/ macro_ttc_small_treadmill_1, /*yaw*/ 90, /*pos*/ 1306, 2939, 1069), + MACRO_OBJECT (/*preset*/ macro_ttc_small_treadmill_1, /*yaw*/ 315, /*pos*/ -1179, -1453, -792), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_ttc_push_block, /*yaw*/ 180, /*pos*/ 174, 1248, 2040, /*bhvParam*/ 2), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_ttc_push_block, /*yaw*/ 45, /*pos*/ -1321, 1490, -1563, /*bhvParam*/ 0), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_ttc_push_block, /*yaw*/ 45, /*pos*/ -1076, 1730, -1808, /*bhvParam*/ 5), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_ttc_push_block, /*yaw*/ 45, /*pos*/ -1319, 1970, -1564, /*bhvParam*/ 10), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_ttc_push_block, /*yaw*/ 180, /*pos*/ -517, 3175, 2040, /*bhvParam*/ 0), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_ttc_push_block, /*yaw*/ 180, /*pos*/ -170, 1248, 2040, /*bhvParam*/ 1), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_ttc_push_block, /*yaw*/ 180, /*pos*/ -515, 1248, 2040, /*bhvParam*/ 0), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_ttc_push_block, /*yaw*/ 0, /*pos*/ -175, -1351, -2039, /*bhvParam*/ 0), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_ttc_push_block, /*yaw*/ 180, /*pos*/ -515, -2590, 2040, /*bhvParam*/ 0), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_ttc_push_block, /*yaw*/ 180, /*pos*/ 518, 3175, 2040, /*bhvParam*/ 3), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_ttc_push_block, /*yaw*/ 180, /*pos*/ -171, 3175, 2040, /*bhvParam*/ 1), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_ttc_push_block, /*yaw*/ 180, /*pos*/ 174, 3175, 2040, /*bhvParam*/ 2), + MACRO_OBJECT (/*preset*/ macro_ttc_rotating_hexagon, /*yaw*/ 0, /*pos*/ 1490, -2088, -873), + MACRO_OBJECT (/*preset*/ macro_ttc_rotating_hexagon, /*yaw*/ 0, /*pos*/ -708, -1606, -1589), + MACRO_OBJECT (/*preset*/ macro_ttc_rotating_hexagon, /*yaw*/ 0, /*pos*/ 954, -1627, -1448), + MACRO_OBJECT (/*preset*/ macro_ttc_rotating_hexagon, /*yaw*/ 0, /*pos*/ 1215, -1781, -1215), + MACRO_OBJECT (/*preset*/ macro_ttc_rotating_hexagon, /*yaw*/ 0, /*pos*/ 1052, -1934, -769), + MACRO_OBJECT (/*preset*/ macro_ttc_rotating_triangle, /*yaw*/ 225, /*pos*/ -620, 1229, 1233), + MACRO_OBJECT (/*preset*/ macro_ttc_rotating_triangle, /*yaw*/ 315, /*pos*/ 1050, -19, -1037), + MACRO_OBJECT (/*preset*/ macro_ttc_pit_block_1, /*yaw*/ 315, /*pos*/ -1100, -71, -1030), + MACRO_OBJECT (/*preset*/ macro_ttc_clock_hand, /*yaw*/ 225, /*pos*/ 0, 6011, 0), + MACRO_OBJECT (/*preset*/ macro_ttc_clock_hand, /*yaw*/ 45, /*pos*/ 0, -2487, 0), + MACRO_OBJECT (/*preset*/ macro_ttc_spinner, /*yaw*/ 135, /*pos*/ 1102, -3619, 1682), + MACRO_OBJECT (/*preset*/ macro_ttc_spinner, /*yaw*/ 90, /*pos*/ 424, -3312, 1959), + MACRO_OBJECT (/*preset*/ macro_ttc_spinner, /*yaw*/ 135, /*pos*/ 1102, -3004, 1682), + MACRO_OBJECT (/*preset*/ macro_ttc_spinner, /*yaw*/ 135, /*pos*/ 1584, -2697, 1200), + MACRO_OBJECT (/*preset*/ macro_ttc_spinner, /*yaw*/ 135, /*pos*/ 1582, -3619, 1203), + MACRO_OBJECT (/*preset*/ macro_ttc_spinner, /*yaw*/ 135, /*pos*/ -762, 4347, 1047), + MACRO_OBJECT (/*preset*/ macro_ttc_spinner, /*yaw*/ 90, /*pos*/ 424, -3926, 1959), + MACRO_OBJECT (/*preset*/ macro_ttc_spinner, /*yaw*/ 135, /*pos*/ 1102, -4233, 1682), + MACRO_OBJECT (/*preset*/ macro_ttc_spinner, /*yaw*/ 135, /*pos*/ 1102, -4848, 1682), + MACRO_OBJECT (/*preset*/ macro_ttc_spinner, /*yaw*/ 90, /*pos*/ 424, -4540, 1959), + MACRO_OBJECT (/*preset*/ macro_ttc_spinner, /*yaw*/ 315, /*pos*/ -1037, 4244, 772), + MACRO_OBJECT (/*preset*/ macro_ttc_spinner, /*yaw*/ 0, /*pos*/ 1828, 3835, -50), + MACRO_OBJECT (/*preset*/ macro_ttc_spinner, /*yaw*/ 0, /*pos*/ 1459, 3835, -357), + MACRO_OBJECT (/*preset*/ macro_ttc_spinner, /*yaw*/ 0, /*pos*/ 1091, 3835, -665), + MACRO_OBJECT (/*preset*/ macro_ttc_small_gear, /*yaw*/ 0, /*pos*/ 1580, -4854, -825), + MACRO_OBJECT (/*preset*/ macro_ttc_small_gear, /*yaw*/ 0, /*pos*/ -1692, 1022, -1157), + MACRO_OBJECT (/*preset*/ macro_ttc_small_gear, /*yaw*/ 0, /*pos*/ 2098, 7007, 2243), + MACRO_OBJECT (/*preset*/ macro_ttc_large_gear, /*yaw*/ 0, /*pos*/ 1801, -4843, -731), + MACRO_OBJECT (/*preset*/ macro_ttc_large_gear, /*yaw*/ 0, /*pos*/ -1477, 1044, -1088), + MACRO_OBJECT (/*preset*/ macro_ttc_large_gear, /*yaw*/ 0, /*pos*/ 2268, 7030, 2227), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 800, -4400, 1900), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 800, -3700, 1900), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 800, -3000, 1900), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 1780, -3300, 1000), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 1388, -3300, 1428), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 200, -3000, 2000), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 200, -3700, 2000), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 200, -4400, 2000), + MACRO_OBJECT (/*preset*/ macro_hidden_1up_in_pole, /*yaw*/ 0, /*pos*/ -1080, 90, 1575), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_ttc_elevator_platform, /*yaw*/ 45, /*pos*/ -1179, 445, 1413, /*bhvParam*/ 6), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_ttc_elevator_platform, /*yaw*/ 315, /*pos*/ -1524, -1454, 1129, /*bhvParam*/ 2), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_circling_amp, /*yaw*/ 0, /*pos*/ -980, -700, 1450, /*bhvParam*/ AMP_BP_ROT_RADIUS_300), + MACRO_OBJECT (/*preset*/ macro_blue_coin_switch, /*yaw*/ 45, /*pos*/ -1203, -19, -170), + MACRO_OBJECT (/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ 0, 20, -1400), + MACRO_OBJECT (/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ -250, 20, -1700), + MACRO_OBJECT (/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ 250, 20, -1700), + MACRO_OBJECT (/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ 0, 20, -2000), + MACRO_OBJECT (/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ 500, 20, -2000), + MACRO_OBJECT (/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ -500, 20, -2000), + MACRO_OBJECT (/*preset*/ macro_heave_ho, /*yaw*/ 0, /*pos*/ 880, -19, 1160), + MACRO_OBJECT (/*preset*/ macro_fire_spitter, /*yaw*/ 0, /*pos*/ 800, -2460, 160), + MACRO_OBJECT (/*preset*/ macro_coin_line_horizontal, /*yaw*/ 45, /*pos*/ -1120, -820, 1320), + MACRO_OBJECT (/*preset*/ macro_fire_spitter, /*yaw*/ 0, /*pos*/ -571, 6020, -1414), + MACRO_OBJECT (/*preset*/ macro_recovery_heart, /*yaw*/ 0, /*pos*/ 620, -5150, 1540), + MACRO_OBJECT (/*preset*/ macro_hidden_1up_trigger, /*yaw*/ 0, /*pos*/ -520, 1351, 1919), + MACRO_OBJECT (/*preset*/ macro_hidden_1up_trigger, /*yaw*/ 0, /*pos*/ -165, 1351, 1919), + MACRO_OBJECT (/*preset*/ macro_hidden_1up_trigger, /*yaw*/ 0, /*pos*/ 182, 1351, 1919), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_hidden_1up, /*yaw*/ 0, /*pos*/ 657, 1368, 1879, /*bhvParam*/ 3), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_circling_amp, /*yaw*/ 0, /*pos*/ -700, -2350, -700, /*bhvParam*/ AMP_BP_ROT_RADIUS_300), + MACRO_OBJECT (/*preset*/ macro_box_1up, /*yaw*/ 0, /*pos*/ 1883, 4150, 550), + MACRO_OBJECT (/*preset*/ macro_recovery_heart, /*yaw*/ 0, /*pos*/ -1333, 350, 1116), + MACRO_OBJECT (/*preset*/ macro_box_1up, /*yaw*/ 45, /*pos*/ -1101, 6316, -685), + MACRO_OBJECT (/*preset*/ macro_bobomb, /*yaw*/ 0, /*pos*/ 1077, -4822, 638), + MACRO_OBJECT (/*preset*/ macro_bobomb, /*yaw*/ 0, /*pos*/ 1683, -4822, 189), + MACRO_OBJECT (/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ 0, 20, -1700), + MACRO_OBJECT (/*preset*/ macro_ttc_rotating_hexagon, /*yaw*/ 0, /*pos*/ -1020, 1229, 537), + MACRO_OBJECT (/*preset*/ macro_box_ten_coins, /*yaw*/ 45, /*pos*/ 2350, 5600, 2350), + MACRO_OBJECT (/*preset*/ macro_box_ten_coins, /*yaw*/ 0, /*pos*/ 0, 4783, 0), + MACRO_OBJECT (/*preset*/ macro_box_three_coins, /*yaw*/ 45, /*pos*/ -1140, -3720, -1620), + MACRO_OBJECT (/*preset*/ macro_box_three_coins, /*yaw*/ 45, /*pos*/ 840, -2200, 860), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_1, /*yaw*/ 0, /*pos*/ -770, -3800, -440), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_1, /*yaw*/ 0, /*pos*/ -770, -3700, -440), + MACRO_OBJECT (/*preset*/ macro_box_ten_coins, /*yaw*/ 0, /*pos*/ 280, -4920, 1660), + MACRO_OBJECT (/*preset*/ macro_box_three_coins, /*yaw*/ 45, /*pos*/ 1240, 300, 840), + MACRO_OBJECT (/*preset*/ macro_box_three_coins, /*yaw*/ 45, /*pos*/ 520, 300, 1500), + MACRO_OBJECT (/*preset*/ macro_box_ten_coins, /*yaw*/ 0, /*pos*/ -400, 3600, 1880), + MACRO_OBJECT (/*preset*/ macro_box_three_coins, /*yaw*/ 0, /*pos*/ -40, 4160, -1280), + MACRO_OBJECT (/*preset*/ macro_box_three_coins, /*yaw*/ 45, /*pos*/ -1160, 2920, -840), + MACRO_OBJECT (/*preset*/ macro_box_ten_coins, /*yaw*/ 45, /*pos*/ -780, 6316, -1020), + MACRO_OBJECT (/*preset*/ macro_ttc_large_treadmill_2, /*yaw*/ 45, /*pos*/ 1313, 6190, 1313), + MACRO_OBJECT (/*preset*/ macro_ttc_small_treadmill_2, /*yaw*/ 0, /*pos*/ 1851, -2488, -98), MACRO_OBJECT_END(), }; diff --git a/levels/ttc/clock_hand/geo.inc.c b/levels/ttc/clock_hand/geo.inc.c index d8b141e7..f919a532 100644 --- a/levels/ttc/clock_hand/geo.inc.c +++ b/levels/ttc/clock_hand/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000358 const GeoLayout ttc_geo_000358[] = { - GEO_CULLING_RADIUS(1700), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, ttc_seg7_dl_07011B38), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(1700), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, ttc_seg7_dl_07011B38), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/ttc/elevator_platform/geo.inc.c b/levels/ttc/elevator_platform/geo.inc.c index 7f77cdb0..e81b0b2a 100644 --- a/levels/ttc/elevator_platform/geo.inc.c +++ b/levels/ttc/elevator_platform/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000340 const GeoLayout ttc_geo_000340[] = { - GEO_CULLING_RADIUS(380), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, ttc_seg7_dl_070116A8), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(380), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, ttc_seg7_dl_070116A8), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/ttc/large_gear/geo.inc.c b/levels/ttc/large_gear/geo.inc.c index 4f87597d..0a830fdb 100644 --- a/levels/ttc/large_gear/geo.inc.c +++ b/levels/ttc/large_gear/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E0003A0 const GeoLayout ttc_geo_0003A0[] = { - GEO_CULLING_RADIUS(300), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, ttc_seg7_dl_07012278), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(300), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, ttc_seg7_dl_07012278), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/ttc/large_treadmill/geo.inc.c b/levels/ttc/large_treadmill/geo.inc.c index 631e0fe9..d17dae69 100644 --- a/levels/ttc/large_treadmill/geo.inc.c +++ b/levels/ttc/large_treadmill/geo.inc.c @@ -1,9 +1,9 @@ // 0x0E000288 const GeoLayout ttc_geo_000288[] = { - GEO_CULLING_RADIUS(720), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, ttc_seg7_dl_0700FBB8), - GEO_ASM(0x1400, geo_movtex_draw_colored_no_update), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(720), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, ttc_seg7_dl_0700FBB8), + GEO_ASM(0x1400, geo_movtex_draw_colored_no_update), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/ttc/leveldata.c b/levels/ttc/leveldata.c index 1f5ee226..f57da02c 100644 --- a/levels/ttc/leveldata.c +++ b/levels/ttc/leveldata.c @@ -3,8 +3,8 @@ #include "surface_terrains.h" #include "moving_texture_macros.h" #include "level_misc_macros.h" -#include "macro_preset_names.h" -#include "special_preset_names.h" +#include "macro_presets.h" +#include "special_presets.h" #include "textures.h" #include "make_const_nonconst.h" diff --git a/levels/ttc/pendulum/geo.inc.c b/levels/ttc/pendulum/geo.inc.c index 2976bd1a..4e3259b9 100644 --- a/levels/ttc/pendulum/geo.inc.c +++ b/levels/ttc/pendulum/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000270 const GeoLayout ttc_geo_000270[] = { - GEO_CULLING_RADIUS(1100), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, ttc_seg7_dl_0700F760), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(1100), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, ttc_seg7_dl_0700F760), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/ttc/pit_block/geo.inc.c b/levels/ttc/pit_block/geo.inc.c index 547c917e..d790db32 100644 --- a/levels/ttc/pit_block/geo.inc.c +++ b/levels/ttc/pit_block/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000310 const GeoLayout ttc_geo_000310[] = { - GEO_CULLING_RADIUS(250), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, ttc_seg7_dl_07011040), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(250), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, ttc_seg7_dl_07011040), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/ttc/pit_block_2/geo.inc.c b/levels/ttc/pit_block_2/geo.inc.c index cbb65d6b..e6b2925d 100644 --- a/levels/ttc/pit_block_2/geo.inc.c +++ b/levels/ttc/pit_block_2/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000328 const GeoLayout ttc_geo_000328[] = { - GEO_CULLING_RADIUS(250), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, ttc_seg7_dl_07011360), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(250), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, ttc_seg7_dl_07011360), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/ttc/push_block/geo.inc.c b/levels/ttc/push_block/geo.inc.c index 2d89eb82..de06724f 100644 --- a/levels/ttc/push_block/geo.inc.c +++ b/levels/ttc/push_block/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E0002C8 const GeoLayout ttc_geo_0002C8[] = { - GEO_CULLING_RADIUS(500), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, ttc_seg7_dl_070102B8), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(500), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, ttc_seg7_dl_070102B8), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/ttc/rotating_cube/geo.inc.c b/levels/ttc/rotating_cube/geo.inc.c index 8120e547..9b54463e 100644 --- a/levels/ttc/rotating_cube/geo.inc.c +++ b/levels/ttc/rotating_cube/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000240 const GeoLayout ttc_geo_000240[] = { - GEO_CULLING_RADIUS(410), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, ttc_seg7_dl_0700ECB8), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(410), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, ttc_seg7_dl_0700ECB8), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/ttc/rotating_hexagon/geo.inc.c b/levels/ttc/rotating_hexagon/geo.inc.c index 8fdfaafb..0eb34b42 100644 --- a/levels/ttc/rotating_hexagon/geo.inc.c +++ b/levels/ttc/rotating_hexagon/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E0002E0 const GeoLayout ttc_geo_0002E0[] = { - GEO_CULLING_RADIUS(400), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, ttc_seg7_dl_07010868), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(400), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, ttc_seg7_dl_07010868), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/ttc/rotating_prism/geo.inc.c b/levels/ttc/rotating_prism/geo.inc.c index 778b0ad5..a835d6d7 100644 --- a/levels/ttc/rotating_prism/geo.inc.c +++ b/levels/ttc/rotating_prism/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000258 const GeoLayout ttc_geo_000258[] = { - GEO_CULLING_RADIUS(410), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, ttc_seg7_dl_0700EFE0), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(410), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, ttc_seg7_dl_0700EFE0), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/ttc/rotating_triangle/geo.inc.c b/levels/ttc/rotating_triangle/geo.inc.c index a9a7a98b..d939e3eb 100644 --- a/levels/ttc/rotating_triangle/geo.inc.c +++ b/levels/ttc/rotating_triangle/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E0002F8 const GeoLayout ttc_geo_0002F8[] = { - GEO_CULLING_RADIUS(520), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, ttc_seg7_dl_07010D38), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(520), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, ttc_seg7_dl_07010D38), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/ttc/script.c b/levels/ttc/script.c index 4b93de86..c871611b 100644 --- a/levels/ttc/script.c +++ b/levels/ttc/script.c @@ -16,31 +16,31 @@ #include "levels/ttc/header.h" static const LevelScript script_func_local_1[] = { - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -1080, -840, 1573, /*angle*/ 0, 0, 0, /*behParam*/ 0x00560000, /*beh*/ bhvPoleGrabbing), - OBJECT(/*model*/ MODEL_THWOMP, /*pos*/ 1919, 6191, 1919, /*angle*/ 0, 225, 0, /*behParam*/ 0x00000000, /*beh*/ bhvThwomp2), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ -1080, -840, 1573, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(86), /*bhv*/ bhvPoleGrabbing), + OBJECT(/*model*/ MODEL_THWOMP, /*pos*/ 1919, 6191, 1919, /*angle*/ 0, 225, 0, /*bhvParam*/ BPARAM2(0), /*bhv*/ bhvThwomp), RETURN(), }; static const LevelScript script_func_local_2[] = { - OBJECT_WITH_ACTS(/*model*/ MODEL_STAR, /*pos*/ -1450, -1130, -1050, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvStar, /*acts*/ ALL_ACTS), - OBJECT_WITH_ACTS(/*model*/ MODEL_STAR, /*pos*/ -1850, 300, -950, /*angle*/ 0, 0, 0, /*behParam*/ 0x01000000, /*beh*/ bhvStar, /*acts*/ ALL_ACTS), - OBJECT_WITH_ACTS(/*model*/ MODEL_STAR, /*pos*/ -1300, -2250, -1300, /*angle*/ 0, 0, 0, /*behParam*/ 0x02000000, /*beh*/ bhvStar, /*acts*/ ALL_ACTS), - OBJECT_WITH_ACTS(/*model*/ MODEL_STAR, /*pos*/ 2200, 7300, 2210, /*angle*/ 0, 0, 0, /*behParam*/ 0x03000000, /*beh*/ bhvStar, /*acts*/ ALL_ACTS), - OBJECT_WITH_ACTS(/*model*/ MODEL_STAR, /*pos*/ -1050, 2400, -790, /*angle*/ 0, 0, 0, /*behParam*/ 0x04000000, /*beh*/ bhvStar, /*acts*/ ALL_ACTS), - OBJECT_WITH_ACTS(/*model*/ MODEL_NONE, /*pos*/ 1815, -3200, 800, /*angle*/ 0, 0, 0, /*behParam*/ 0x05000000, /*beh*/ bhvHiddenRedCoinStar, /*acts*/ ALL_ACTS), + OBJECT_WITH_ACTS(/*model*/ MODEL_STAR, /*pos*/ -1450, -1130, -1050, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(STAR_INDEX_ACT_1), /*bhv*/ bhvStar, /*acts*/ ALL_ACTS), + OBJECT_WITH_ACTS(/*model*/ MODEL_STAR, /*pos*/ -1850, 300, -950, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(STAR_INDEX_ACT_2), /*bhv*/ bhvStar, /*acts*/ ALL_ACTS), + OBJECT_WITH_ACTS(/*model*/ MODEL_STAR, /*pos*/ -1300, -2250, -1300, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(STAR_INDEX_ACT_3), /*bhv*/ bhvStar, /*acts*/ ALL_ACTS), + OBJECT_WITH_ACTS(/*model*/ MODEL_STAR, /*pos*/ 2200, 7300, 2210, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(STAR_INDEX_ACT_4), /*bhv*/ bhvStar, /*acts*/ ALL_ACTS), + OBJECT_WITH_ACTS(/*model*/ MODEL_STAR, /*pos*/ -1050, 2400, -790, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(STAR_INDEX_ACT_5), /*bhv*/ bhvStar, /*acts*/ ALL_ACTS), + OBJECT_WITH_ACTS(/*model*/ MODEL_NONE, /*pos*/ 1815, -3200, 800, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(STAR_INDEX_ACT_6), /*bhv*/ bhvHiddenRedCoinStar, /*acts*/ ALL_ACTS), RETURN(), }; const LevelScript level_ttc_entry[] = { INIT_LEVEL(), - LOAD_MIO0( /*seg*/ 0x07, _ttc_segment_7SegmentRomStart, _ttc_segment_7SegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x07, _ttc_segment_7SegmentRomStart, _ttc_segment_7SegmentRomEnd), LOAD_MIO0_TEXTURE(/*seg*/ 0x09, _machine_mio0SegmentRomStart, _machine_mio0SegmentRomEnd), - LOAD_MIO0( /*seg*/ 0x05, _group1_mio0SegmentRomStart, _group1_mio0SegmentRomEnd), - LOAD_RAW( /*seg*/ 0x0C, _group1_geoSegmentRomStart, _group1_geoSegmentRomEnd), - LOAD_MIO0( /*seg*/ 0x08, _common0_mio0SegmentRomStart, _common0_mio0SegmentRomEnd), - LOAD_RAW( /*seg*/ 0x0F, _common0_geoSegmentRomStart, _common0_geoSegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x05, _group1_mio0SegmentRomStart, _group1_mio0SegmentRomEnd), + LOAD_RAW (/*seg*/ 0x0C, _group1_geoSegmentRomStart, _group1_geoSegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x08, _common0_mio0SegmentRomStart, _common0_mio0SegmentRomEnd), + LOAD_RAW (/*seg*/ 0x0F, _common0_geoSegmentRomStart, _common0_geoSegmentRomEnd), ALLOC_LEVEL_POOL(), - MARIO(/*model*/ MODEL_MARIO, /*behParam*/ 0x00000001, /*beh*/ bhvMario), + MARIO(/*model*/ MODEL_MARIO, /*bhvParam*/ BPARAM4(0x01), /*bhv*/ bhvMario), JUMP_LINK(script_func_global_1), JUMP_LINK(script_func_global_2), LOAD_MODEL_FROM_GEO(MODEL_TTC_ROTATING_CUBE, ttc_geo_000240), @@ -60,10 +60,10 @@ const LevelScript level_ttc_entry[] = { LOAD_MODEL_FROM_GEO(MODEL_TTC_LARGE_GEAR, ttc_geo_0003A0), AREA(/*index*/ 1, ttc_geo_0003B8), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 1417, -3822, -548, /*angle*/ 0, 316, 0, /*behParam*/ 0x000A0000, /*beh*/ bhvSpinAirborneWarp), - WARP_NODE(/*id*/ 0x0A, /*destLevel*/ LEVEL_TTC, /*destArea*/ 0x01, /*destNode*/ 0x0A, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0xF0, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x02, /*destNode*/ 0x35, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0xF1, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x02, /*destNode*/ 0x67, /*flags*/ WARP_NO_CHECKPOINT), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 1417, -3822, -548, /*angle*/ 0, 316, 0, /*bhvParam*/ BPARAM2(WARP_NODE_0A), /*bhv*/ bhvSpinAirborneWarp), + WARP_NODE(/*id*/ WARP_NODE_0A, /*destLevel*/ LEVEL_TTC, /*destArea*/ 1, /*destNode*/ WARP_NODE_0A, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_SUCCESS, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 2, /*destNode*/ WARP_NODE_35, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_DEATH, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 2, /*destNode*/ WARP_NODE_67, /*flags*/ WARP_NO_CHECKPOINT), JUMP_LINK(script_func_local_1), JUMP_LINK(script_func_local_2), TERRAIN(/*terrainData*/ ttc_seg7_collision_level), diff --git a/levels/ttc/small_gear/geo.inc.c b/levels/ttc/small_gear/geo.inc.c index 5c626ee4..c0f7bc7e 100644 --- a/levels/ttc/small_gear/geo.inc.c +++ b/levels/ttc/small_gear/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000388 const GeoLayout ttc_geo_000388[] = { - GEO_CULLING_RADIUS(200), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, ttc_seg7_dl_07012148), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(200), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, ttc_seg7_dl_07012148), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/ttc/small_treadmill/geo.inc.c b/levels/ttc/small_treadmill/geo.inc.c index df319cd0..d12a7019 100644 --- a/levels/ttc/small_treadmill/geo.inc.c +++ b/levels/ttc/small_treadmill/geo.inc.c @@ -1,9 +1,9 @@ // 0x0E0002A8 const GeoLayout ttc_geo_0002A8[] = { - GEO_CULLING_RADIUS(520), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, ttc_seg7_dl_0700FFE8), - GEO_ASM(0x1401, geo_movtex_draw_colored_no_update), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(520), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, ttc_seg7_dl_0700FFE8), + GEO_ASM(0x1401, geo_movtex_draw_colored_no_update), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/ttc/spinner/geo.inc.c b/levels/ttc/spinner/geo.inc.c index fd3b45d0..d4704ce3 100644 --- a/levels/ttc/spinner/geo.inc.c +++ b/levels/ttc/spinner/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000370 const GeoLayout ttc_geo_000370[] = { - GEO_CULLING_RADIUS(500), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, ttc_seg7_dl_07012028), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(500), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, ttc_seg7_dl_07012028), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/ttm/areas/1/10/geo.inc.c b/levels/ttm/areas/1/10/geo.inc.c index c572b282..f622fb6d 100644 --- a/levels/ttm/areas/1/10/geo.inc.c +++ b/levels/ttm/areas/1/10/geo.inc.c @@ -1,11 +1,11 @@ // 0x0E000880 const GeoLayout ttm_geo_000880[] = { - GEO_CULLING_RADIUS(2200), - GEO_OPEN_NODE(), - GEO_RENDER_RANGE(-3200, 10000), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, ttm_seg7_dl_0700CAE0), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(2200), + GEO_OPEN_NODE(), + GEO_RENDER_RANGE(-3200, 10000), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, ttm_seg7_dl_0700CAE0), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/ttm/areas/1/11/geo.inc.c b/levels/ttm/areas/1/11/geo.inc.c index 2b28f144..a6ee2aa7 100644 --- a/levels/ttm/areas/1/11/geo.inc.c +++ b/levels/ttm/areas/1/11/geo.inc.c @@ -1,11 +1,11 @@ // 0x0E0008A8 const GeoLayout ttm_geo_0008A8[] = { - GEO_CULLING_RADIUS(750), - GEO_OPEN_NODE(), - GEO_RENDER_RANGE(-1750, 7000), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, ttm_seg7_dl_0700CD10), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(750), + GEO_OPEN_NODE(), + GEO_RENDER_RANGE(-1750, 7000), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, ttm_seg7_dl_0700CD10), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/ttm/areas/1/12/geo.inc.c b/levels/ttm/areas/1/12/geo.inc.c index d44558c6..538899af 100644 --- a/levels/ttm/areas/1/12/geo.inc.c +++ b/levels/ttm/areas/1/12/geo.inc.c @@ -1,11 +1,11 @@ // 0x0E0008D0 const GeoLayout ttm_geo_0008D0[] = { - GEO_CULLING_RADIUS(1200), - GEO_OPEN_NODE(), - GEO_RENDER_RANGE(-2200, 8000), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, ttm_seg7_dl_0700D1D8), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(1200), + GEO_OPEN_NODE(), + GEO_RENDER_RANGE(-2200, 8000), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, ttm_seg7_dl_0700D1D8), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/ttm/areas/1/13/geo.inc.c b/levels/ttm/areas/1/13/geo.inc.c index e78313bf..799a6c85 100644 --- a/levels/ttm/areas/1/13/geo.inc.c +++ b/levels/ttm/areas/1/13/geo.inc.c @@ -1,11 +1,11 @@ // 0x0E0008F8 const GeoLayout ttm_geo_0008F8[] = { - GEO_CULLING_RADIUS(1500), - GEO_OPEN_NODE(), - GEO_RENDER_RANGE(-2100, 8000), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, ttm_seg7_dl_0700D688), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(1500), + GEO_OPEN_NODE(), + GEO_RENDER_RANGE(-2100, 8000), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, ttm_seg7_dl_0700D688), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/ttm/areas/1/14/geo.inc.c b/levels/ttm/areas/1/14/geo.inc.c index 98ee9baa..c29d6392 100644 --- a/levels/ttm/areas/1/14/geo.inc.c +++ b/levels/ttm/areas/1/14/geo.inc.c @@ -1,12 +1,12 @@ // 0x0E000920 const GeoLayout ttm_geo_000920[] = { - GEO_CULLING_RADIUS(1650), - GEO_OPEN_NODE(), - GEO_RENDER_RANGE(-2650, 5500), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, ttm_seg7_dl_0700DF78), - GEO_OPEN_NODE(), - GEO_CLOSE_NODE(), - //! Too many open nodes. Unfortunately not exploitable - GEO_END(), + GEO_CULLING_RADIUS(1650), + GEO_OPEN_NODE(), + GEO_RENDER_RANGE(-2650, 5500), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, ttm_seg7_dl_0700DF78), + GEO_OPEN_NODE(), + GEO_CLOSE_NODE(), + //! Missing close nodes. Unfortunately not exploitable + GEO_END(), }; diff --git a/levels/ttm/areas/1/15/geo.inc.c b/levels/ttm/areas/1/15/geo.inc.c index 7912e96e..f926e61e 100644 --- a/levels/ttm/areas/1/15/geo.inc.c +++ b/levels/ttm/areas/1/15/geo.inc.c @@ -1,11 +1,11 @@ // 0x0E000948 const GeoLayout ttm_geo_000948[] = { - GEO_CULLING_RADIUS(350), - GEO_OPEN_NODE(), - GEO_RENDER_RANGE(-1350, 3000), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, ttm_seg7_dl_0700E308), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(350), + GEO_OPEN_NODE(), + GEO_RENDER_RANGE(-1350, 3000), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, ttm_seg7_dl_0700E308), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/ttm/areas/1/16/geo.inc.c b/levels/ttm/areas/1/16/geo.inc.c index 2da5a56a..10d60065 100644 --- a/levels/ttm/areas/1/16/geo.inc.c +++ b/levels/ttm/areas/1/16/geo.inc.c @@ -1,9 +1,9 @@ // 0x0E000970 const GeoLayout ttm_geo_000970[] = { - GEO_CULLING_RADIUS(3200), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, ttm_seg7_dl_0700EAC8), - GEO_DISPLAY_LIST(LAYER_ALPHA, ttm_seg7_dl_0700EC58), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(3200), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, ttm_seg7_dl_0700EAC8), + GEO_DISPLAY_LIST(LAYER_ALPHA, ttm_seg7_dl_0700EC58), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/ttm/areas/1/17/geo.inc.c b/levels/ttm/areas/1/17/geo.inc.c index b4b396a2..90c6543c 100644 --- a/levels/ttm/areas/1/17/geo.inc.c +++ b/levels/ttm/areas/1/17/geo.inc.c @@ -1,12 +1,12 @@ // 0x0E000990 const GeoLayout ttm_geo_000990[] = { - GEO_CULLING_RADIUS(780), - GEO_OPEN_NODE(), - GEO_RENDER_RANGE(-1780, 5500), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, ttm_seg7_dl_0700F270), - GEO_DISPLAY_LIST(LAYER_OPAQUE, ttm_seg7_dl_0700FA18), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(780), + GEO_OPEN_NODE(), + GEO_RENDER_RANGE(-1780, 5500), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, ttm_seg7_dl_0700F270), + GEO_DISPLAY_LIST(LAYER_OPAQUE, ttm_seg7_dl_0700FA18), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/ttm/areas/1/18/geo.inc.c b/levels/ttm/areas/1/18/geo.inc.c index 9a8166eb..ed9602a2 100644 --- a/levels/ttm/areas/1/18/geo.inc.c +++ b/levels/ttm/areas/1/18/geo.inc.c @@ -1,12 +1,12 @@ // 0x0E0009C0 const GeoLayout ttm_geo_0009C0[] = { - GEO_CULLING_RADIUS(1700), - GEO_OPEN_NODE(), - GEO_RENDER_RANGE(-2700, 5000), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, ttm_seg7_dl_07010978), - GEO_DISPLAY_LIST(LAYER_ALPHA, ttm_seg7_dl_07010A68), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(1700), + GEO_OPEN_NODE(), + GEO_RENDER_RANGE(-2700, 5000), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, ttm_seg7_dl_07010978), + GEO_DISPLAY_LIST(LAYER_ALPHA, ttm_seg7_dl_07010A68), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/ttm/areas/1/19/geo.inc.c b/levels/ttm/areas/1/19/geo.inc.c index 8a887fd2..8896bd1d 100644 --- a/levels/ttm/areas/1/19/geo.inc.c +++ b/levels/ttm/areas/1/19/geo.inc.c @@ -1,11 +1,11 @@ // 0x0E0009F0 const GeoLayout ttm_geo_0009F0[] = { - GEO_CULLING_RADIUS(920), - GEO_OPEN_NODE(), - GEO_RENDER_RANGE(-1920, 5000), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, ttm_seg7_dl_07011128), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(920), + GEO_OPEN_NODE(), + GEO_RENDER_RANGE(-1920, 5000), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, ttm_seg7_dl_07011128), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/ttm/areas/1/20/geo.inc.c b/levels/ttm/areas/1/20/geo.inc.c index 30fa2945..fbadb361 100644 --- a/levels/ttm/areas/1/20/geo.inc.c +++ b/levels/ttm/areas/1/20/geo.inc.c @@ -1,11 +1,11 @@ // 0x0E000A18 const GeoLayout ttm_geo_000A18[] = { - GEO_CULLING_RADIUS(1100), - GEO_OPEN_NODE(), - GEO_RENDER_RANGE(-2100, 5000), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, ttm_seg7_dl_07011608), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(1100), + GEO_OPEN_NODE(), + GEO_RENDER_RANGE(-2100, 5000), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, ttm_seg7_dl_07011608), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/ttm/areas/1/21/geo.inc.c b/levels/ttm/areas/1/21/geo.inc.c index aaab43b9..9ccf1c1c 100644 --- a/levels/ttm/areas/1/21/geo.inc.c +++ b/levels/ttm/areas/1/21/geo.inc.c @@ -1,12 +1,12 @@ // 0x0E000A40 const GeoLayout ttm_geo_000A40[] = { - GEO_CULLING_RADIUS(900), - GEO_OPEN_NODE(), - GEO_RENDER_RANGE(-1900, 5000), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, ttm_seg7_dl_07011C78), - GEO_DISPLAY_LIST(LAYER_ALPHA, ttm_seg7_dl_07011D78), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(900), + GEO_OPEN_NODE(), + GEO_RENDER_RANGE(-1900, 5000), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, ttm_seg7_dl_07011C78), + GEO_DISPLAY_LIST(LAYER_ALPHA, ttm_seg7_dl_07011D78), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/ttm/areas/1/3/geo.inc.c b/levels/ttm/areas/1/3/geo.inc.c index beb627cc..e3c71212 100644 --- a/levels/ttm/areas/1/3/geo.inc.c +++ b/levels/ttm/areas/1/3/geo.inc.c @@ -1,12 +1,12 @@ // 0x0E000748 const GeoLayout ttm_geo_000748[] = { - GEO_CULLING_RADIUS(1800), - GEO_OPEN_NODE(), - GEO_RENDER_RANGE(-2800, 10000), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, ttm_seg7_dl_0700A8C0), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, ttm_seg7_dl_0700AB08), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(1800), + GEO_OPEN_NODE(), + GEO_RENDER_RANGE(-2800, 10000), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, ttm_seg7_dl_0700A8C0), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, ttm_seg7_dl_0700AB08), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/ttm/areas/1/4/geo.inc.c b/levels/ttm/areas/1/4/geo.inc.c index d708ee3e..7f37e14e 100644 --- a/levels/ttm/areas/1/4/geo.inc.c +++ b/levels/ttm/areas/1/4/geo.inc.c @@ -1,12 +1,12 @@ // 0x0E000778 const GeoLayout ttm_geo_000778[] = { - GEO_CULLING_RADIUS(1700), - GEO_OPEN_NODE(), - GEO_RENDER_RANGE(-2700, 6500), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, ttm_seg7_dl_0700AF90), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, ttm_seg7_dl_0700B0D0), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(1700), + GEO_OPEN_NODE(), + GEO_RENDER_RANGE(-2700, 6500), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, ttm_seg7_dl_0700AF90), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, ttm_seg7_dl_0700B0D0), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/ttm/areas/1/5/geo.inc.c b/levels/ttm/areas/1/5/geo.inc.c index f2292416..155283db 100644 --- a/levels/ttm/areas/1/5/geo.inc.c +++ b/levels/ttm/areas/1/5/geo.inc.c @@ -1,12 +1,12 @@ // 0x0E0007A8 const GeoLayout ttm_geo_0007A8[] = { - GEO_CULLING_RADIUS(1700), - GEO_OPEN_NODE(), - GEO_RENDER_RANGE(-2700, 6500), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, ttm_seg7_dl_0700B530), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, ttm_seg7_dl_0700B670), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(1700), + GEO_OPEN_NODE(), + GEO_RENDER_RANGE(-2700, 6500), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, ttm_seg7_dl_0700B530), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, ttm_seg7_dl_0700B670), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/ttm/areas/1/6/geo.inc.c b/levels/ttm/areas/1/6/geo.inc.c index f545b293..271fd1cf 100644 --- a/levels/ttm/areas/1/6/geo.inc.c +++ b/levels/ttm/areas/1/6/geo.inc.c @@ -1,12 +1,12 @@ // 0x0E0007D8 const GeoLayout ttm_geo_0007D8[] = { - GEO_CULLING_RADIUS(1700), - GEO_OPEN_NODE(), - GEO_RENDER_RANGE(-2700, 6500), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, ttm_seg7_dl_0700BAD0), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, ttm_seg7_dl_0700BC10), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(1700), + GEO_OPEN_NODE(), + GEO_RENDER_RANGE(-2700, 6500), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, ttm_seg7_dl_0700BAD0), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, ttm_seg7_dl_0700BC10), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/ttm/areas/1/7/geo.inc.c b/levels/ttm/areas/1/7/geo.inc.c index 7e129654..1e9159df 100644 --- a/levels/ttm/areas/1/7/geo.inc.c +++ b/levels/ttm/areas/1/7/geo.inc.c @@ -1,11 +1,11 @@ // 0x0E000808 const GeoLayout ttm_geo_000808[] = { - GEO_CULLING_RADIUS(650), - GEO_OPEN_NODE(), - GEO_RENDER_RANGE(-1650, 9500), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, ttm_seg7_dl_0700BE20), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(650), + GEO_OPEN_NODE(), + GEO_RENDER_RANGE(-1650, 9500), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, ttm_seg7_dl_0700BE20), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/ttm/areas/1/8/geo.inc.c b/levels/ttm/areas/1/8/geo.inc.c index b122f79b..afbd587f 100644 --- a/levels/ttm/areas/1/8/geo.inc.c +++ b/levels/ttm/areas/1/8/geo.inc.c @@ -1,11 +1,11 @@ // 0x0E000830 const GeoLayout ttm_geo_000830[] = { - GEO_CULLING_RADIUS(1900), - GEO_OPEN_NODE(), - GEO_RENDER_RANGE(-2900, 8000), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, ttm_seg7_dl_0700C070), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(1900), + GEO_OPEN_NODE(), + GEO_RENDER_RANGE(-2900, 8000), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, ttm_seg7_dl_0700C070), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/ttm/areas/1/9/geo.inc.c b/levels/ttm/areas/1/9/geo.inc.c index 3afa7f0c..64377942 100644 --- a/levels/ttm/areas/1/9/geo.inc.c +++ b/levels/ttm/areas/1/9/geo.inc.c @@ -1,11 +1,11 @@ // 0x0E000858 const GeoLayout ttm_geo_000858[] = { - GEO_CULLING_RADIUS(450), - GEO_OPEN_NODE(), - GEO_RENDER_RANGE(-1450, 5500), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, ttm_seg7_dl_0700C408), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(450), + GEO_OPEN_NODE(), + GEO_RENDER_RANGE(-1450, 5500), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, ttm_seg7_dl_0700C408), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/ttm/areas/1/geo.inc.c b/levels/ttm/areas/1/geo.inc.c index b93b3c11..249a86e4 100644 --- a/levels/ttm/areas/1/geo.inc.c +++ b/levels/ttm/areas/1/geo.inc.c @@ -1,40 +1,40 @@ // 0x0E000A70 const GeoLayout ttm_geo_000A70[] = { - GEO_NODE_SCREEN_AREA(10, SCREEN_WIDTH/2, SCREEN_HEIGHT/2, SCREEN_WIDTH/2, SCREEN_HEIGHT/2), - GEO_OPEN_NODE(), - GEO_ZBUFFER(0), - GEO_OPEN_NODE(), - GEO_NODE_ORTHO(100), - GEO_OPEN_NODE(), - GEO_BACKGROUND(BACKGROUND_OCEAN_SKY, geo_skybox_main), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ZBUFFER(1), - GEO_OPEN_NODE(), - GEO_CAMERA_FRUSTUM_WITH_FUNC(45, 100, 12800, geo_camera_fov), - GEO_OPEN_NODE(), - GEO_CAMERA(1, 0, 2000, 6000, 0, -2200, 0, geo_camera_main), + GEO_NODE_SCREEN_AREA(10, SCREEN_WIDTH/2, SCREEN_HEIGHT/2, SCREEN_WIDTH/2, SCREEN_HEIGHT/2), + GEO_OPEN_NODE(), + GEO_ZBUFFER(0), + GEO_OPEN_NODE(), + GEO_NODE_ORTHO(100), GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, ttm_seg7_dl_0700A120), - GEO_DISPLAY_LIST(LAYER_OPAQUE, ttm_seg7_dl_0700A2E0), - GEO_RENDER_OBJ(), - GEO_ASM( 0, geo_painting_update), - GEO_ASM(PAINTING_ID(0, 2), geo_painting_draw), - GEO_ASM( 0, geo_movtex_pause_control), - GEO_ASM(0x3601, geo_movtex_draw_nocolor), - GEO_ASM(0x3602, geo_movtex_draw_nocolor), - GEO_ASM(0x3603, geo_movtex_draw_nocolor), - GEO_ASM(0x3604, geo_movtex_draw_nocolor), - GEO_ASM(0x3605, geo_movtex_draw_nocolor), - GEO_ASM(0x3601, geo_movtex_draw_water_regions), - GEO_ASM( 0, geo_envfx_main), + GEO_BACKGROUND(BACKGROUND_OCEAN_SKY, geo_skybox_main), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ZBUFFER(0), - GEO_OPEN_NODE(), - GEO_ASM(0, geo_cannon_circle_base), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CLOSE_NODE(), + GEO_ZBUFFER(1), + GEO_OPEN_NODE(), + GEO_CAMERA_FRUSTUM_WITH_FUNC(45, 100, 12800, geo_camera_fov), + GEO_OPEN_NODE(), + GEO_CAMERA(1, 0, 2000, 6000, 0, -2200, 0, geo_camera_main), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, ttm_seg7_dl_0700A120), + GEO_DISPLAY_LIST(LAYER_OPAQUE, ttm_seg7_dl_0700A2E0), + GEO_RENDER_OBJ(), + GEO_ASM( 0, geo_painting_update), + GEO_ASM(PAINTING_ID(0, 2), geo_painting_draw), + GEO_ASM( 0, geo_movtex_pause_control), + GEO_ASM(0x3601, geo_movtex_draw_nocolor), + GEO_ASM(0x3602, geo_movtex_draw_nocolor), + GEO_ASM(0x3603, geo_movtex_draw_nocolor), + GEO_ASM(0x3604, geo_movtex_draw_nocolor), + GEO_ASM(0x3605, geo_movtex_draw_nocolor), + GEO_ASM(0x3601, geo_movtex_draw_water_regions), + GEO_ASM( 0, geo_envfx_main), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ZBUFFER(0), + GEO_OPEN_NODE(), + GEO_ASM(0, geo_cannon_circle_base), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/ttm/areas/1/macro.inc.c b/levels/ttm/areas/1/macro.inc.c index a19e7317..d580a70e 100644 --- a/levels/ttm/areas/1/macro.inc.c +++ b/levels/ttm/areas/1/macro.inc.c @@ -1,43 +1,43 @@ // 0x07016F18 - 0x070170A0 const MacroObject ttm_seg7_area_1_macro_objs[] = { - MACRO_OBJECT(/*preset*/ macro_bobomb_buddy_opens_cannon, /*yaw*/ 0, /*pos*/ 799, -2668, 3320), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_cannon_closed, /*yaw*/ 45, /*pos*/ 5035, -3994, -3445, /*behParam*/ 0xC0), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 90, /*pos*/ 3644, -1304, 1422, /*behParam*/ DIALOG_072), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 0, /*pos*/ 622, -4331, 5466, /*behParam*/ DIALOG_094), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 1450, -2750, -4250), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 2550, -2750, -3400), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 4150, -2700, -2800), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -1600, -1650, -2500), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -1200, -1600, -3250), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -1850, 100, -2850), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -1500, -800, -2750), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 180, /*pos*/ -1126, -3448, -4400, /*behParam*/ DIALOG_091), - MACRO_OBJECT(/*preset*/ macro_goomba_triplet_spawner, /*yaw*/ 0, /*pos*/ 1740, -4236, 5320), - MACRO_OBJECT(/*preset*/ macro_coin_ring_horizontal, /*yaw*/ 0, /*pos*/ 4540, -4607, 1060), - MACRO_OBJECT(/*preset*/ macro_1up, /*yaw*/ 0, /*pos*/ -3713, -4130, 3530), - MACRO_OBJECT(/*preset*/ macro_bobomb, /*yaw*/ 0, /*pos*/ -3507, -2480, -1046), - MACRO_OBJECT(/*preset*/ macro_bobomb, /*yaw*/ 0, /*pos*/ -3538, -2409, -61), - MACRO_OBJECT(/*preset*/ macro_bobomb, /*yaw*/ 0, /*pos*/ -3538, -2330, 1046), - MACRO_OBJECT(/*preset*/ macro_coin_line_horizontal, /*yaw*/ 82, /*pos*/ -521, -2047, 3568), - MACRO_OBJECT(/*preset*/ macro_bobomb, /*yaw*/ 0, /*pos*/ 2369, -1451, -3876), - MACRO_OBJECT(/*preset*/ macro_bobomb, /*yaw*/ 0, /*pos*/ 707, -1223, -3846), - MACRO_OBJECT(/*preset*/ macro_1up, /*yaw*/ 0, /*pos*/ -1010, -705, -3385), - MACRO_OBJECT(/*preset*/ macro_goomba_triplet_spawner, /*yaw*/ 0, /*pos*/ -584, 195, 1476), - MACRO_OBJECT(/*preset*/ macro_1up, /*yaw*/ 0, /*pos*/ 1530, 620, 1670), - MACRO_OBJECT(/*preset*/ macro_coin_line_horizontal, /*yaw*/ 0, /*pos*/ 3476, 708, -896), - MACRO_OBJECT(/*preset*/ macro_coin_line_horizontal, /*yaw*/ 125, /*pos*/ 2461, 1461, 1960), - MACRO_OBJECT(/*preset*/ macro_box_1up, /*yaw*/ 0, /*pos*/ 3261, -2553, -4092), - MACRO_OBJECT(/*preset*/ macro_coin_line_horizontal_flying, /*yaw*/ 330, /*pos*/ -1907, -861, -3138), - MACRO_OBJECT(/*preset*/ macro_hidden_box, /*yaw*/ 30, /*pos*/ 1950, 880, 1321), - MACRO_OBJECT(/*preset*/ macro_floor_switch_hidden_objects, /*yaw*/ 50, /*pos*/ -1200, 1543, 460), - MACRO_OBJECT(/*preset*/ macro_goomba_triplet_spawner, /*yaw*/ 0, /*pos*/ -600, 1177, -1340), - MACRO_OBJECT(/*preset*/ macro_fish_group, /*yaw*/ 0, /*pos*/ -780, -4580, 4440), - MACRO_OBJECT(/*preset*/ macro_hidden_box, /*yaw*/ 55, /*pos*/ -900, 1540, 580), - MACRO_OBJECT(/*preset*/ macro_chuckya, /*yaw*/ 270, /*pos*/ -2676, -2145, 2923), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 1840, -2880, -3600), - MACRO_OBJECT(/*preset*/ macro_coin_line_vertical, /*yaw*/ 0, /*pos*/ -880, 1750, 580), - MACRO_OBJECT(/*preset*/ macro_fire_fly_guy, /*yaw*/ 0, /*pos*/ 2300, -1384, 3753), - MACRO_OBJECT(/*preset*/ macro_butterfly_triplet, /*yaw*/ 0, /*pos*/ -606, 1186, -1290), - MACRO_OBJECT(/*preset*/ macro_jumping_box, /*yaw*/ 0, /*pos*/ 4980, -4607, 2680), + MACRO_OBJECT (/*preset*/ macro_bobomb_buddy_opens_cannon_1, /*yaw*/ 0, /*pos*/ 799, -2668, 3320), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_cannon_closed, /*yaw*/ 45, /*pos*/ 5035, -3994, -3445, /*bhvParam*/ 0xC0), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 90, /*pos*/ 3644, -1304, 1422, /*bhvParam*/ DIALOG_072), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 0, /*pos*/ 622, -4331, 5466, /*bhvParam*/ DIALOG_094), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 1450, -2750, -4250), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 2550, -2750, -3400), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 4150, -2700, -2800), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -1600, -1650, -2500), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -1200, -1600, -3250), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -1850, 100, -2850), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -1500, -800, -2750), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 180, /*pos*/ -1126, -3448, -4400, /*bhvParam*/ DIALOG_091), + MACRO_OBJECT (/*preset*/ macro_goomba_triplet_spawner, /*yaw*/ 0, /*pos*/ 1740, -4236, 5320), + MACRO_OBJECT (/*preset*/ macro_coin_ring_horizontal, /*yaw*/ 0, /*pos*/ 4540, -4607, 1060), + MACRO_OBJECT (/*preset*/ macro_1up, /*yaw*/ 0, /*pos*/ -3713, -4130, 3530), + MACRO_OBJECT (/*preset*/ macro_bobomb, /*yaw*/ 0, /*pos*/ -3507, -2480, -1046), + MACRO_OBJECT (/*preset*/ macro_bobomb, /*yaw*/ 0, /*pos*/ -3538, -2409, -61), + MACRO_OBJECT (/*preset*/ macro_bobomb, /*yaw*/ 0, /*pos*/ -3538, -2330, 1046), + MACRO_OBJECT (/*preset*/ macro_coin_line_horizontal, /*yaw*/ 82, /*pos*/ -521, -2047, 3568), + MACRO_OBJECT (/*preset*/ macro_bobomb, /*yaw*/ 0, /*pos*/ 2369, -1451, -3876), + MACRO_OBJECT (/*preset*/ macro_bobomb, /*yaw*/ 0, /*pos*/ 707, -1223, -3846), + MACRO_OBJECT (/*preset*/ macro_1up, /*yaw*/ 0, /*pos*/ -1010, -705, -3385), + MACRO_OBJECT (/*preset*/ macro_goomba_triplet_spawner, /*yaw*/ 0, /*pos*/ -584, 195, 1476), + MACRO_OBJECT (/*preset*/ macro_1up, /*yaw*/ 0, /*pos*/ 1530, 620, 1670), + MACRO_OBJECT (/*preset*/ macro_coin_line_horizontal, /*yaw*/ 0, /*pos*/ 3476, 708, -896), + MACRO_OBJECT (/*preset*/ macro_coin_line_horizontal, /*yaw*/ 125, /*pos*/ 2461, 1461, 1960), + MACRO_OBJECT (/*preset*/ macro_box_1up, /*yaw*/ 0, /*pos*/ 3261, -2553, -4092), + MACRO_OBJECT (/*preset*/ macro_coin_line_horizontal_flying, /*yaw*/ 330, /*pos*/ -1907, -861, -3138), + MACRO_OBJECT (/*preset*/ macro_hidden_breakable_box, /*yaw*/ 30, /*pos*/ 1950, 880, 1321), + MACRO_OBJECT (/*preset*/ macro_floor_switch_hidden_objects, /*yaw*/ 50, /*pos*/ -1200, 1543, 460), + MACRO_OBJECT (/*preset*/ macro_goomba_triplet_spawner, /*yaw*/ 0, /*pos*/ -600, 1177, -1340), + MACRO_OBJECT (/*preset*/ macro_fish_spawner_few_blue, /*yaw*/ 0, /*pos*/ -780, -4580, 4440), + MACRO_OBJECT (/*preset*/ macro_hidden_breakable_box, /*yaw*/ 55, /*pos*/ -900, 1540, 580), + MACRO_OBJECT (/*preset*/ macro_chuckya, /*yaw*/ 270, /*pos*/ -2676, -2145, 2923), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 1840, -2880, -3600), + MACRO_OBJECT (/*preset*/ macro_coin_line_vertical_flying, /*yaw*/ 0, /*pos*/ -880, 1750, 580), + MACRO_OBJECT (/*preset*/ macro_fire_fly_guy, /*yaw*/ 0, /*pos*/ 2300, -1384, 3753), + MACRO_OBJECT (/*preset*/ macro_butterfly_triplet, /*yaw*/ 0, /*pos*/ -606, 1186, -1290), + MACRO_OBJECT (/*preset*/ macro_jumping_box, /*yaw*/ 0, /*pos*/ 4980, -4607, 2680), MACRO_OBJECT_END(), }; diff --git a/levels/ttm/areas/2/geo.inc.c b/levels/ttm/areas/2/geo.inc.c index 9af13cde..fccf7495 100644 --- a/levels/ttm/areas/2/geo.inc.c +++ b/levels/ttm/areas/2/geo.inc.c @@ -1,27 +1,27 @@ // 0x0E000B5C const GeoLayout ttm_geo_000B5C[] = { - GEO_NODE_SCREEN_AREA(10, SCREEN_WIDTH/2, SCREEN_HEIGHT/2, SCREEN_WIDTH/2, SCREEN_HEIGHT/2), - GEO_OPEN_NODE(), - GEO_ZBUFFER(0), - GEO_OPEN_NODE(), - GEO_NODE_ORTHO(100), - GEO_OPEN_NODE(), - GEO_BACKGROUND_COLOR(0x0001), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ZBUFFER(1), - GEO_OPEN_NODE(), - GEO_CAMERA_FRUSTUM_WITH_FUNC(45, 100, 12800, geo_camera_fov), - GEO_OPEN_NODE(), - GEO_CAMERA(9, 0, 2000, 6000, 0, 0, 0, geo_camera_main), + GEO_NODE_SCREEN_AREA(10, SCREEN_WIDTH/2, SCREEN_HEIGHT/2, SCREEN_WIDTH/2, SCREEN_HEIGHT/2), + GEO_OPEN_NODE(), + GEO_ZBUFFER(0), + GEO_OPEN_NODE(), + GEO_NODE_ORTHO(100), GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, ttm_seg7_dl_0701D798), - GEO_DISPLAY_LIST(LAYER_OPAQUE, ttm_seg7_dl_0701DBB8), - GEO_RENDER_OBJ(), - GEO_ASM(0, geo_envfx_main), + GEO_BACKGROUND_COLOR(0x0001), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CLOSE_NODE(), + GEO_ZBUFFER(1), + GEO_OPEN_NODE(), + GEO_CAMERA_FRUSTUM_WITH_FUNC(45, 100, 12800, geo_camera_fov), + GEO_OPEN_NODE(), + GEO_CAMERA(9, 0, 2000, 6000, 0, 0, 0, geo_camera_main), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, ttm_seg7_dl_0701D798), + GEO_DISPLAY_LIST(LAYER_OPAQUE, ttm_seg7_dl_0701DBB8), + GEO_RENDER_OBJ(), + GEO_ASM(0, geo_envfx_main), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/ttm/areas/2/macro.inc.c b/levels/ttm/areas/2/macro.inc.c index 4864d011..40dc3842 100644 --- a/levels/ttm/areas/2/macro.inc.c +++ b/levels/ttm/areas/2/macro.inc.c @@ -1,15 +1,15 @@ // 0x070302C8 - 0x07030338 const MacroObject ttm_seg7_area_2_macro_objs[] = { - MACRO_OBJECT(/*preset*/ macro_hidden_1up_trigger, /*yaw*/ 0, /*pos*/ 6100, 4836, 6981), - MACRO_OBJECT(/*preset*/ macro_hidden_1up_trigger, /*yaw*/ 0, /*pos*/ 6645, 4800, 7563), - MACRO_OBJECT(/*preset*/ macro_hidden_1up_trigger, /*yaw*/ 0, /*pos*/ 7845, 4836, 6327), - MACRO_OBJECT(/*preset*/ macro_hidden_1up_trigger, /*yaw*/ 0, /*pos*/ 7263, 4836, 5745), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_hidden_1up, /*yaw*/ 0, /*pos*/ 6936, 4800, 6654, /*behParam*/ 4), - MACRO_OBJECT(/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ 6281, 4836, 6472), - MACRO_OBJECT(/*preset*/ macro_1up, /*yaw*/ 0, /*pos*/ 6754, 4800, 5963), - MACRO_OBJECT(/*preset*/ macro_1up_sliding, /*yaw*/ 0, /*pos*/ 1764, 2943, 1480), - MACRO_OBJECT(/*preset*/ macro_coin_line_horizontal, /*yaw*/ 45, /*pos*/ 2972, 3963, 2690), - MACRO_OBJECT(/*preset*/ macro_coin_line_horizontal, /*yaw*/ 45, /*pos*/ 27, 2145, -290), - MACRO_OBJECT(/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ -2763, -37, -2981), + MACRO_OBJECT (/*preset*/ macro_hidden_1up_trigger, /*yaw*/ 0, /*pos*/ 6100, 4836, 6981), + MACRO_OBJECT (/*preset*/ macro_hidden_1up_trigger, /*yaw*/ 0, /*pos*/ 6645, 4800, 7563), + MACRO_OBJECT (/*preset*/ macro_hidden_1up_trigger, /*yaw*/ 0, /*pos*/ 7845, 4836, 6327), + MACRO_OBJECT (/*preset*/ macro_hidden_1up_trigger, /*yaw*/ 0, /*pos*/ 7263, 4836, 5745), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_hidden_1up, /*yaw*/ 0, /*pos*/ 6936, 4800, 6654, /*bhvParam*/ 4), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ 6281, 4836, 6472), + MACRO_OBJECT (/*preset*/ macro_1up, /*yaw*/ 0, /*pos*/ 6754, 4800, 5963), + MACRO_OBJECT (/*preset*/ macro_1up_sliding, /*yaw*/ 0, /*pos*/ 1764, 2943, 1480), + MACRO_OBJECT (/*preset*/ macro_coin_line_horizontal, /*yaw*/ 45, /*pos*/ 2972, 3963, 2690), + MACRO_OBJECT (/*preset*/ macro_coin_line_horizontal, /*yaw*/ 45, /*pos*/ 27, 2145, -290), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ -2763, -37, -2981), MACRO_OBJECT_END(), }; diff --git a/levels/ttm/areas/3/geo.inc.c b/levels/ttm/areas/3/geo.inc.c index a59642d2..a2df4a20 100644 --- a/levels/ttm/areas/3/geo.inc.c +++ b/levels/ttm/areas/3/geo.inc.c @@ -1,28 +1,28 @@ // 0x0E000BEC const GeoLayout ttm_geo_000BEC[] = { - GEO_NODE_SCREEN_AREA(10, SCREEN_WIDTH/2, SCREEN_HEIGHT/2, SCREEN_WIDTH/2, SCREEN_HEIGHT/2), - GEO_OPEN_NODE(), - GEO_ZBUFFER(0), - GEO_OPEN_NODE(), - GEO_NODE_ORTHO(100), - GEO_OPEN_NODE(), - GEO_BACKGROUND_COLOR(0x0001), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ZBUFFER(1), - GEO_OPEN_NODE(), - GEO_CAMERA_FRUSTUM_WITH_FUNC(45, 100, 12800, geo_camera_fov), - GEO_OPEN_NODE(), - GEO_CAMERA(9, 0, 2000, 6000, 0, 0, 0, geo_camera_main), + GEO_NODE_SCREEN_AREA(10, SCREEN_WIDTH/2, SCREEN_HEIGHT/2, SCREEN_WIDTH/2, SCREEN_HEIGHT/2), + GEO_OPEN_NODE(), + GEO_ZBUFFER(0), + GEO_OPEN_NODE(), + GEO_NODE_ORTHO(100), GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, ttm_seg7_dl_070249A0), - GEO_DISPLAY_LIST(LAYER_OPAQUE, ttm_seg7_dl_07024C78), - GEO_DISPLAY_LIST(LAYER_OPAQUE, ttm_seg7_dl_07025F48), - GEO_RENDER_OBJ(), - GEO_ASM(0, geo_envfx_main), + GEO_BACKGROUND_COLOR(0x0001), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CLOSE_NODE(), + GEO_ZBUFFER(1), + GEO_OPEN_NODE(), + GEO_CAMERA_FRUSTUM_WITH_FUNC(45, 100, 12800, geo_camera_fov), + GEO_OPEN_NODE(), + GEO_CAMERA(9, 0, 2000, 6000, 0, 0, 0, geo_camera_main), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, ttm_seg7_dl_070249A0), + GEO_DISPLAY_LIST(LAYER_OPAQUE, ttm_seg7_dl_07024C78), + GEO_DISPLAY_LIST(LAYER_OPAQUE, ttm_seg7_dl_07025F48), + GEO_RENDER_OBJ(), + GEO_ASM(0, geo_envfx_main), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/ttm/areas/4/geo.inc.c b/levels/ttm/areas/4/geo.inc.c index 5dc981f8..cc583823 100644 --- a/levels/ttm/areas/4/geo.inc.c +++ b/levels/ttm/areas/4/geo.inc.c @@ -1,27 +1,27 @@ // 0x0E000C84 const GeoLayout ttm_geo_000C84[] = { - GEO_NODE_SCREEN_AREA(10, SCREEN_WIDTH/2, SCREEN_HEIGHT/2, SCREEN_WIDTH/2, SCREEN_HEIGHT/2), - GEO_OPEN_NODE(), - GEO_ZBUFFER(0), - GEO_OPEN_NODE(), - GEO_NODE_ORTHO(100), - GEO_OPEN_NODE(), - GEO_BACKGROUND_COLOR(0x0001), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ZBUFFER(1), - GEO_OPEN_NODE(), - GEO_CAMERA_FRUSTUM_WITH_FUNC(45, 100, 12800, geo_camera_fov), - GEO_OPEN_NODE(), - GEO_CAMERA(9, 0, 2000, 6000, 0, 0, 0, geo_camera_main), + GEO_NODE_SCREEN_AREA(10, SCREEN_WIDTH/2, SCREEN_HEIGHT/2, SCREEN_WIDTH/2, SCREEN_HEIGHT/2), + GEO_OPEN_NODE(), + GEO_ZBUFFER(0), + GEO_OPEN_NODE(), + GEO_NODE_ORTHO(100), GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, ttm_seg7_dl_0702A1B8), - GEO_DISPLAY_LIST(LAYER_OPAQUE, ttm_seg7_dl_0702A8A0), - GEO_RENDER_OBJ(), - GEO_ASM(0, geo_envfx_main), + GEO_BACKGROUND_COLOR(0x0001), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CLOSE_NODE(), + GEO_ZBUFFER(1), + GEO_OPEN_NODE(), + GEO_CAMERA_FRUSTUM_WITH_FUNC(45, 100, 12800, geo_camera_fov), + GEO_OPEN_NODE(), + GEO_CAMERA(9, 0, 2000, 6000, 0, 0, 0, geo_camera_main), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, ttm_seg7_dl_0702A1B8), + GEO_DISPLAY_LIST(LAYER_OPAQUE, ttm_seg7_dl_0702A8A0), + GEO_RENDER_OBJ(), + GEO_ASM(0, geo_envfx_main), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/ttm/blue_smiley/geo.inc.c b/levels/ttm/blue_smiley/geo.inc.c index bcd9bfde..e7604a84 100644 --- a/levels/ttm/blue_smiley/geo.inc.c +++ b/levels/ttm/blue_smiley/geo.inc.c @@ -1,14 +1,14 @@ // 0x0E000D14 const GeoLayout ttm_geo_000D14[] = { - GEO_CULLING_RADIUS(1000), - GEO_OPEN_NODE(), - GEO_BILLBOARD(), - GEO_OPEN_NODE(), - GEO_SCALE(0x00, 32768), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, ttm_seg7_dl_0702A9C0), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(1000), + GEO_OPEN_NODE(), + GEO_BILLBOARD(), + GEO_OPEN_NODE(), + GEO_SCALE(0x00, 32768), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, ttm_seg7_dl_0702A9C0), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/ttm/level.yaml b/levels/ttm/level.yaml index cb584762..473046d9 100644 --- a/levels/ttm/level.yaml +++ b/levels/ttm/level.yaml @@ -1,6 +1,6 @@ -# Tall Tall Mountain +# Tall, Tall Mountain short-name: ttm -full-name: Tall Tall Mountain +full-name: Tall, Tall Mountain texture-file: ["/texture.inc.c"] area-count: 4 objects: [blue_smiley, moon_smiley, rolling_log, slide_exit_podium, star_cage, star_smiley, yellow_smiley] diff --git a/levels/ttm/leveldata.c b/levels/ttm/leveldata.c index c8fb72ff..4129055f 100644 --- a/levels/ttm/leveldata.c +++ b/levels/ttm/leveldata.c @@ -3,8 +3,8 @@ #include "surface_terrains.h" #include "moving_texture_macros.h" #include "level_misc_macros.h" -#include "macro_preset_names.h" -#include "special_preset_names.h" +#include "macro_presets.h" +#include "special_presets.h" #include "textures.h" #include "dialog_ids.h" diff --git a/levels/ttm/moon_smiley/geo.inc.c b/levels/ttm/moon_smiley/geo.inc.c index 83b4f836..554ab455 100644 --- a/levels/ttm/moon_smiley/geo.inc.c +++ b/levels/ttm/moon_smiley/geo.inc.c @@ -1,14 +1,14 @@ // 0x0E000DBC const GeoLayout ttm_geo_000DBC[] = { - GEO_CULLING_RADIUS(1000), - GEO_OPEN_NODE(), - GEO_BILLBOARD(), - GEO_OPEN_NODE(), - GEO_SCALE(0x00, 32768), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, ttm_seg7_dl_0702AC78), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(1000), + GEO_OPEN_NODE(), + GEO_BILLBOARD(), + GEO_OPEN_NODE(), + GEO_SCALE(0x00, 32768), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, ttm_seg7_dl_0702AC78), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/ttm/rolling_log/geo.inc.c b/levels/ttm/rolling_log/geo.inc.c index c41b6cd7..0d7d432c 100644 --- a/levels/ttm/rolling_log/geo.inc.c +++ b/levels/ttm/rolling_log/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000730 const GeoLayout ttm_geo_000730[] = { - GEO_CULLING_RADIUS(1200), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, ttm_seg7_dl_07012270), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(1200), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, ttm_seg7_dl_07012270), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/ttm/script.c b/levels/ttm/script.c index bc593aac..a1db6d04 100644 --- a/levels/ttm/script.c +++ b/levels/ttm/script.c @@ -16,63 +16,63 @@ #include "levels/ttm/header.h" static const LevelScript script_func_local_1[] = { - OBJECT(/*model*/ MODEL_TTM_ROLLING_LOG, /*pos*/ 4360, -1722, 4001, /*angle*/ 0, 48, 0, /*behParam*/ 0x00000000, /*beh*/ bhvTtmRollingLog), + OBJECT(/*model*/ MODEL_TTM_ROLLING_LOG, /*pos*/ 4360, -1722, 4001, /*angle*/ 0, 48, 0, /*bhvParam*/ 0, /*bhv*/ bhvTTMRollingLog), RETURN(), }; static const LevelScript script_func_local_2[] = { - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -1639, 1146, -1742, /*angle*/ 0, 0, 0, /*behParam*/ 0x00010000, /*beh*/ bhvTtmBowlingBallSpawner), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 3295, -3692, 2928, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvWaterfallSoundLoop), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 2004, -1580, 1283, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvWaterfallSoundLoop), - OBJECT(/*model*/ MODEL_DL_MONTY_MOLE_HOLE, /*pos*/ -2077, -1023, -1969, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvMontyMoleHole), - OBJECT(/*model*/ MODEL_DL_MONTY_MOLE_HOLE, /*pos*/ -2500, -1023, -2157, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvMontyMoleHole), - OBJECT(/*model*/ MODEL_DL_MONTY_MOLE_HOLE, /*pos*/ -2048, -1023, -2307, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvMontyMoleHole), - OBJECT(/*model*/ MODEL_DL_MONTY_MOLE_HOLE, /*pos*/ -2351, -1023, -2416, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvMontyMoleHole), - OBJECT(/*model*/ MODEL_DL_MONTY_MOLE_HOLE, /*pos*/ -2400, -2559, -2185, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvMontyMoleHole), - OBJECT(/*model*/ MODEL_DL_MONTY_MOLE_HOLE, /*pos*/ -1435, -2559, -3118, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvMontyMoleHole), - OBJECT(/*model*/ MODEL_DL_MONTY_MOLE_HOLE, /*pos*/ -1677, -2559, -3507, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvMontyMoleHole), - OBJECT(/*model*/ MODEL_DL_MONTY_MOLE_HOLE, /*pos*/ -1869, -2559, -2704, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvMontyMoleHole), - OBJECT(/*model*/ MODEL_DL_MONTY_MOLE_HOLE, /*pos*/ -2525, -2559, -2626, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvMontyMoleHole), - OBJECT(/*model*/ MODEL_MONTY_MOLE, /*pos*/ 0, 0, 0, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvMontyMole), - OBJECT(/*model*/ MODEL_MONTY_MOLE, /*pos*/ 0, 0, 0, /*angle*/ 0, 0, 0, /*behParam*/ 0x00010000, /*beh*/ bhvMontyMole), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 3625, 560, 165, /*angle*/ 0, 330, 0, /*behParam*/ 0x00000000, /*beh*/ bhvCloud), - OBJECT_WITH_ACTS(/*model*/ MODEL_UKIKI, /*pos*/ 729, 2307, 335, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvUkiki, /*acts*/ ACT_2), - OBJECT_WITH_ACTS(/*model*/ MODEL_UKIKI, /*pos*/ 1992, -1548, 2944, /*angle*/ 0, 0, 0, /*behParam*/ 0x00010000, /*beh*/ bhvUkiki, /*acts*/ ALL_ACTS), + OBJECT (/*model*/ MODEL_NONE, /*pos*/ -1639, 1146, -1742, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(BBALL_BP_STYPE_TTM), /*bhv*/ bhvTTMBowlingBallSpawner), + OBJECT (/*model*/ MODEL_NONE, /*pos*/ 3295, -3692, 2928, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvWaterfallSoundLoop), + OBJECT (/*model*/ MODEL_NONE, /*pos*/ 2004, -1580, 1283, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvWaterfallSoundLoop), + OBJECT (/*model*/ MODEL_DL_MONTY_MOLE_HOLE, /*pos*/ -2077, -1023, -1969, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvMontyMoleHole), + OBJECT (/*model*/ MODEL_DL_MONTY_MOLE_HOLE, /*pos*/ -2500, -1023, -2157, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvMontyMoleHole), + OBJECT (/*model*/ MODEL_DL_MONTY_MOLE_HOLE, /*pos*/ -2048, -1023, -2307, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvMontyMoleHole), + OBJECT (/*model*/ MODEL_DL_MONTY_MOLE_HOLE, /*pos*/ -2351, -1023, -2416, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvMontyMoleHole), + OBJECT (/*model*/ MODEL_DL_MONTY_MOLE_HOLE, /*pos*/ -2400, -2559, -2185, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvMontyMoleHole), + OBJECT (/*model*/ MODEL_DL_MONTY_MOLE_HOLE, /*pos*/ -1435, -2559, -3118, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvMontyMoleHole), + OBJECT (/*model*/ MODEL_DL_MONTY_MOLE_HOLE, /*pos*/ -1677, -2559, -3507, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvMontyMoleHole), + OBJECT (/*model*/ MODEL_DL_MONTY_MOLE_HOLE, /*pos*/ -1869, -2559, -2704, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvMontyMoleHole), + OBJECT (/*model*/ MODEL_DL_MONTY_MOLE_HOLE, /*pos*/ -2525, -2559, -2626, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvMontyMoleHole), + OBJECT (/*model*/ MODEL_MONTY_MOLE, /*pos*/ 0, 0, 0, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(MONTY_MOLE_BP_NO_ROCK), /*bhv*/ bhvMontyMole), + OBJECT (/*model*/ MODEL_MONTY_MOLE, /*pos*/ 0, 0, 0, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(MONTY_MOLE_BP_GENERIC), /*bhv*/ bhvMontyMole), + OBJECT (/*model*/ MODEL_NONE, /*pos*/ 3625, 560, 165, /*angle*/ 0, 330, 0, /*bhvParam*/ BPARAM2(CLOUD_BP_FWOOSH), /*bhv*/ bhvCloud), + OBJECT_WITH_ACTS(/*model*/ MODEL_UKIKI, /*pos*/ 729, 2307, 335, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(UKIKI_BP_CAGE), /*bhv*/ bhvUkiki, /*acts*/ ACT_2), + OBJECT_WITH_ACTS(/*model*/ MODEL_UKIKI, /*pos*/ 1992, -1548, 2944, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(UKIKI_BP_CAP), /*bhv*/ bhvUkiki, /*acts*/ ALL_ACTS), RETURN(), }; static const LevelScript script_func_local_3[] = { - OBJECT_WITH_ACTS(/*model*/ MODEL_STAR, /*pos*/ 1200, 2600, 150, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvStar, /*acts*/ ACT_1), - OBJECT_WITH_ACTS(/*model*/ MODEL_TTM_STAR_CAGE, /*pos*/ 2496, 1670, 1492, /*angle*/ 0, 0, 0, /*behParam*/ 0x01000000, /*beh*/ bhvUkikiCage, /*acts*/ ACT_2), - OBJECT_WITH_ACTS(/*model*/ MODEL_NONE, /*pos*/ -3250, -2500, -3700, /*angle*/ 0, 0, 0, /*behParam*/ 0x02000000, /*beh*/ bhvHiddenRedCoinStar, /*acts*/ ALL_ACTS), - OBJECT_WITH_ACTS(/*model*/ MODEL_STAR, /*pos*/ -2900, -2700, 3650, /*angle*/ 0, 0, 0, /*behParam*/ 0x03000000, /*beh*/ bhvStar, /*acts*/ ALL_ACTS), - OBJECT_WITH_ACTS(/*model*/ MODEL_STAR, /*pos*/ 1800, 1200, 1050, /*angle*/ 0, 0, 0, /*behParam*/ 0x04000000, /*beh*/ bhvStar, /*acts*/ ALL_ACTS), - OBJECT_WITH_ACTS(/*model*/ MODEL_STAR, /*pos*/ 7300, -3100, 1300, /*angle*/ 0, 0, 0, /*behParam*/ 0x05000000, /*beh*/ bhvStar, /*acts*/ ALL_ACTS), + OBJECT_WITH_ACTS(/*model*/ MODEL_STAR, /*pos*/ 1200, 2600, 150, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(STAR_INDEX_ACT_1), /*bhv*/ bhvStar, /*acts*/ ACT_1), + OBJECT_WITH_ACTS(/*model*/ MODEL_TTM_STAR_CAGE, /*pos*/ 2496, 1670, 1492, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(STAR_INDEX_ACT_2), /*bhv*/ bhvUkikiCage, /*acts*/ ACT_2), + OBJECT_WITH_ACTS(/*model*/ MODEL_NONE, /*pos*/ -3250, -2500, -3700, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(STAR_INDEX_ACT_3), /*bhv*/ bhvHiddenRedCoinStar, /*acts*/ ALL_ACTS), + OBJECT_WITH_ACTS(/*model*/ MODEL_STAR, /*pos*/ -2900, -2700, 3650, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(STAR_INDEX_ACT_4), /*bhv*/ bhvStar, /*acts*/ ALL_ACTS), + OBJECT_WITH_ACTS(/*model*/ MODEL_STAR, /*pos*/ 1800, 1200, 1050, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(STAR_INDEX_ACT_5), /*bhv*/ bhvStar, /*acts*/ ALL_ACTS), + OBJECT_WITH_ACTS(/*model*/ MODEL_STAR, /*pos*/ 7300, -3100, 1300, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(STAR_INDEX_ACT_6), /*bhv*/ bhvStar, /*acts*/ ALL_ACTS), RETURN(), }; static const LevelScript script_func_local_4[] = { - OBJECT(/*model*/ MODEL_TTM_BLUE_SMILEY, /*pos*/ 4389, 3620, 624, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvStaticObject), - OBJECT(/*model*/ MODEL_TTM_YELLOW_SMILEY, /*pos*/ -1251, 2493, 2224, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvStaticObject), - OBJECT(/*model*/ MODEL_TTM_STAR_SMILEY, /*pos*/ -2547, 1365, -520, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvStaticObject), - OBJECT(/*model*/ MODEL_TTM_MOON_SMILEY, /*pos*/ -324, 989, -4090, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvStaticObject), + OBJECT(/*model*/ MODEL_TTM_BLUE_SMILEY, /*pos*/ 4389, 3620, 624, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvStaticObject), + OBJECT(/*model*/ MODEL_TTM_YELLOW_SMILEY, /*pos*/ -1251, 2493, 2224, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvStaticObject), + OBJECT(/*model*/ MODEL_TTM_STAR_SMILEY, /*pos*/ -2547, 1365, -520, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvStaticObject), + OBJECT(/*model*/ MODEL_TTM_MOON_SMILEY, /*pos*/ -324, 989, -4090, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvStaticObject), RETURN(), }; static const LevelScript script_func_local_5[] = { - OBJECT(/*model*/ MODEL_TTM_BLUE_SMILEY, /*pos*/ 7867, -959, -6085, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvStaticObject), - OBJECT(/*model*/ MODEL_TTM_BLUE_SMILEY, /*pos*/ -5241, 5329, 9466, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvStaticObject), - OBJECT(/*model*/ MODEL_TTM_YELLOW_SMILEY, /*pos*/ -1869, -5311, 7358, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvStaticObject), - OBJECT(/*model*/ MODEL_TTM_STAR_SMILEY, /*pos*/ -9095, 4262, 5348, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvStaticObject), - OBJECT(/*model*/ MODEL_TTM_MOON_SMILEY, /*pos*/ -8477, 730, -7122, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvStaticObject), - OBJECT(/*model*/ MODEL_TTM_MOON_SMILEY, /*pos*/ 6160, -6076, 7861, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvStaticObject), + OBJECT(/*model*/ MODEL_TTM_BLUE_SMILEY, /*pos*/ 7867, -959, -6085, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvStaticObject), + OBJECT(/*model*/ MODEL_TTM_BLUE_SMILEY, /*pos*/ -5241, 5329, 9466, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvStaticObject), + OBJECT(/*model*/ MODEL_TTM_YELLOW_SMILEY, /*pos*/ -1869, -5311, 7358, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvStaticObject), + OBJECT(/*model*/ MODEL_TTM_STAR_SMILEY, /*pos*/ -9095, 4262, 5348, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvStaticObject), + OBJECT(/*model*/ MODEL_TTM_MOON_SMILEY, /*pos*/ -8477, 730, -7122, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvStaticObject), + OBJECT(/*model*/ MODEL_TTM_MOON_SMILEY, /*pos*/ 6160, -6076, 7861, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvStaticObject), RETURN(), }; static const LevelScript script_func_local_6[] = { - OBJECT(/*model*/ MODEL_TTM_YELLOW_SMILEY, /*pos*/ 5157, 1974, -8292, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvStaticObject), - OBJECT(/*model*/ MODEL_TTM_STAR_SMILEY, /*pos*/ 11106, 2588, 381, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvStaticObject), - OBJECT(/*model*/ MODEL_TTM_MOON_SMILEY, /*pos*/ 37, 1974, -1124, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvStaticObject), + OBJECT(/*model*/ MODEL_TTM_YELLOW_SMILEY, /*pos*/ 5157, 1974, -8292, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvStaticObject), + OBJECT(/*model*/ MODEL_TTM_STAR_SMILEY, /*pos*/ 11106, 2588, 381, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvStaticObject), + OBJECT(/*model*/ MODEL_TTM_MOON_SMILEY, /*pos*/ 37, 1974, -1124, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvStaticObject), RETURN(), }; @@ -82,20 +82,20 @@ static const LevelScript script_func_local_7[] = { const LevelScript level_ttm_entry[] = { INIT_LEVEL(), - LOAD_MIO0( /*seg*/ 0x07, _ttm_segment_7SegmentRomStart, _ttm_segment_7SegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x07, _ttm_segment_7SegmentRomStart, _ttm_segment_7SegmentRomEnd), LOAD_MIO0_TEXTURE(/*seg*/ 0x09, _mountain_mio0SegmentRomStart, _mountain_mio0SegmentRomEnd), - LOAD_MIO0( /*seg*/ 0x0A, _water_skybox_mio0SegmentRomStart, _water_skybox_mio0SegmentRomEnd), - LOAD_MIO0( /*seg*/ 0x05, _group6_mio0SegmentRomStart, _group6_mio0SegmentRomEnd), - LOAD_RAW( /*seg*/ 0x0C, _group6_geoSegmentRomStart, _group6_geoSegmentRomEnd), - LOAD_MIO0( /*seg*/ 0x08, _common0_mio0SegmentRomStart, _common0_mio0SegmentRomEnd), - LOAD_RAW( /*seg*/ 0x0F, _common0_geoSegmentRomStart, _common0_geoSegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x0A, _water_skybox_mio0SegmentRomStart, _water_skybox_mio0SegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x05, _group6_mio0SegmentRomStart, _group6_mio0SegmentRomEnd), + LOAD_RAW (/*seg*/ 0x0C, _group6_geoSegmentRomStart, _group6_geoSegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x08, _common0_mio0SegmentRomStart, _common0_mio0SegmentRomEnd), + LOAD_RAW (/*seg*/ 0x0F, _common0_geoSegmentRomStart, _common0_geoSegmentRomEnd), ALLOC_LEVEL_POOL(), - MARIO(/*model*/ MODEL_MARIO, /*behParam*/ 0x00000001, /*beh*/ bhvMario), + MARIO(/*model*/ MODEL_MARIO, /*bhvParam*/ BPARAM4(0x01), /*bhv*/ bhvMario), JUMP_LINK(script_func_global_1), JUMP_LINK(script_func_global_7), LOAD_MODEL_FROM_GEO(MODEL_TTM_SLIDE_EXIT_PODIUM, ttm_geo_000DF4), LOAD_MODEL_FROM_GEO(MODEL_TTM_ROLLING_LOG, ttm_geo_000730), - LOAD_MODEL_FROM_GEO(MODEL_TTM_STAR_CAGE, ttm_geo_000710), + LOAD_MODEL_FROM_GEO(MODEL_TTM_STAR_CAGE, ttm_geo_000710), LOAD_MODEL_FROM_GEO(MODEL_TTM_BLUE_SMILEY, ttm_geo_000D14), LOAD_MODEL_FROM_GEO(MODEL_TTM_YELLOW_SMILEY, ttm_geo_000D4C), LOAD_MODEL_FROM_GEO(MODEL_TTM_STAR_SMILEY, ttm_geo_000D84), @@ -121,19 +121,19 @@ const LevelScript level_ttm_entry[] = { LOAD_MODEL_FROM_GEO(MODEL_LEVEL_GEOMETRY_16, ttm_geo_000A40), AREA(/*index*/ 1, ttm_geo_000A70), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 102, -3332, 5734, /*angle*/ 0, 45, 0, /*behParam*/ 0x000A0000, /*beh*/ bhvSpinAirborneWarp), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -2447, -2457, 3952, /*angle*/ 0, -105, 0, /*behParam*/ 0x00140000, /*beh*/ bhvAirborneWarp), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 2267, -3006, -3788, /*angle*/ 0, 148, 0, /*behParam*/ 0x00150000, /*beh*/ bhvFadingWarp), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -557, -3448, -4146, /*angle*/ 0, -168, 0, /*behParam*/ 0x00160000, /*beh*/ bhvFadingWarp), - WARP_NODE(/*id*/ 0x0A, /*destLevel*/ LEVEL_TTM, /*destArea*/ 0x01, /*destNode*/ 0x0A, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0x14, /*destLevel*/ LEVEL_TTM, /*destArea*/ 0x01, /*destNode*/ 0x14, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0x15, /*destLevel*/ LEVEL_TTM, /*destArea*/ 0x01, /*destNode*/ 0x16, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0x16, /*destLevel*/ LEVEL_TTM, /*destArea*/ 0x01, /*destNode*/ 0x15, /*flags*/ WARP_NO_CHECKPOINT), - PAINTING_WARP_NODE(/*id*/ 0x00, /*destLevel*/ LEVEL_TTM, /*destArea*/ 0x02, /*destNode*/ 0x0A, /*flags*/ WARP_CHECKPOINT), - PAINTING_WARP_NODE(/*id*/ 0x01, /*destLevel*/ LEVEL_TTM, /*destArea*/ 0x02, /*destNode*/ 0x0A, /*flags*/ WARP_CHECKPOINT), - PAINTING_WARP_NODE(/*id*/ 0x02, /*destLevel*/ LEVEL_TTM, /*destArea*/ 0x02, /*destNode*/ 0x0A, /*flags*/ WARP_CHECKPOINT), - WARP_NODE(/*id*/ 0xF0, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x02, /*destNode*/ 0x34, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0xF1, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x02, /*destNode*/ 0x66, /*flags*/ WARP_NO_CHECKPOINT), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 102, -3332, 5734, /*angle*/ 0, 45, 0, /*bhvParam*/ BPARAM2(WARP_NODE_0A), /*bhv*/ bhvSpinAirborneWarp), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ -2447, -2457, 3952, /*angle*/ 0, -105, 0, /*bhvParam*/ BPARAM2(WARP_NODE_14), /*bhv*/ bhvAirborneWarp), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 2267, -3006, -3788, /*angle*/ 0, 148, 0, /*bhvParam*/ BPARAM2(WARP_NODE_15), /*bhv*/ bhvFadingWarp), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ -557, -3448, -4146, /*angle*/ 0, -168, 0, /*bhvParam*/ BPARAM2(WARP_NODE_16), /*bhv*/ bhvFadingWarp), + WARP_NODE(/*id*/ WARP_NODE_0A, /*destLevel*/ LEVEL_TTM, /*destArea*/ 1, /*destNode*/ WARP_NODE_0A, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_14, /*destLevel*/ LEVEL_TTM, /*destArea*/ 1, /*destNode*/ WARP_NODE_14, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_15, /*destLevel*/ LEVEL_TTM, /*destArea*/ 1, /*destNode*/ WARP_NODE_16, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_16, /*destLevel*/ LEVEL_TTM, /*destArea*/ 1, /*destNode*/ WARP_NODE_15, /*flags*/ WARP_NO_CHECKPOINT), + PAINTING_WARP_NODE(/*id*/ WARP_NODE_00, /*destLevel*/ LEVEL_TTM, /*destArea*/ 2, /*destNode*/ WARP_NODE_0A, /*flags*/ WARP_CHECKPOINT), + PAINTING_WARP_NODE(/*id*/ WARP_NODE_01, /*destLevel*/ LEVEL_TTM, /*destArea*/ 2, /*destNode*/ WARP_NODE_0A, /*flags*/ WARP_CHECKPOINT), + PAINTING_WARP_NODE(/*id*/ WARP_NODE_02, /*destLevel*/ LEVEL_TTM, /*destArea*/ 2, /*destNode*/ WARP_NODE_0A, /*flags*/ WARP_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_SUCCESS, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 2, /*destNode*/ WARP_NODE_34, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_DEATH, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 2, /*destNode*/ WARP_NODE_66, /*flags*/ WARP_NO_CHECKPOINT), JUMP_LINK(script_func_local_1), JUMP_LINK(script_func_local_2), JUMP_LINK(script_func_local_3), @@ -144,10 +144,10 @@ const LevelScript level_ttm_entry[] = { END_AREA(), AREA(/*index*/ 2, ttm_geo_000B5C), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 7000, 5381, 6750, /*angle*/ 0, 225, 0, /*behParam*/ 0x000A0000, /*beh*/ bhvAirborneWarp), - WARP_NODE(/*id*/ 0x0A, /*destLevel*/ LEVEL_TTM, /*destArea*/ 0x02, /*destNode*/ 0x0A, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0xF0, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x02, /*destNode*/ 0x34, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0xF1, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x02, /*destNode*/ 0x66, /*flags*/ WARP_NO_CHECKPOINT), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 7000, 5381, 6750, /*angle*/ 0, 225, 0, /*bhvParam*/ BPARAM2(WARP_NODE_0A), /*bhv*/ bhvAirborneWarp), + WARP_NODE(/*id*/ WARP_NODE_0A, /*destLevel*/ LEVEL_TTM, /*destArea*/ 2, /*destNode*/ WARP_NODE_0A, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_SUCCESS, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 2, /*destNode*/ WARP_NODE_34, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_DEATH, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 2, /*destNode*/ WARP_NODE_66, /*flags*/ WARP_NO_CHECKPOINT), JUMP_LINK(script_func_local_4), TERRAIN(/*terrainData*/ ttm_seg7_area_2_collision), MACRO_OBJECTS(/*objList*/ ttm_seg7_area_2_macro_objs), @@ -157,8 +157,8 @@ const LevelScript level_ttm_entry[] = { END_AREA(), AREA(/*index*/ 3, ttm_geo_000BEC), - WARP_NODE(/*id*/ 0xF0, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x02, /*destNode*/ 0x34, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0xF1, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x02, /*destNode*/ 0x66, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_SUCCESS, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 2, /*destNode*/ WARP_NODE_34, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_DEATH, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 2, /*destNode*/ WARP_NODE_66, /*flags*/ WARP_NO_CHECKPOINT), JUMP_LINK(script_func_local_5), TERRAIN(/*terrainData*/ ttm_seg7_area_3_collision), MACRO_OBJECTS(/*objList*/ ttm_seg7_area_3_macro_objs), @@ -168,10 +168,10 @@ const LevelScript level_ttm_entry[] = { END_AREA(), AREA(/*index*/ 4, ttm_geo_000C84), - OBJECT(/*model*/ MODEL_TTM_SLIDE_EXIT_PODIUM, /*pos*/ -7285, -1866, -4812, /*angle*/ 0, 0, 0, /*behParam*/ 0x000A0000, /*beh*/ bhvExitPodiumWarp), - WARP_NODE(/*id*/ 0x0A, /*destLevel*/ LEVEL_TTM, /*destArea*/ 0x01, /*destNode*/ 0x14, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0xF0, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x02, /*destNode*/ 0x34, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0xF1, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x02, /*destNode*/ 0x66, /*flags*/ WARP_NO_CHECKPOINT), + OBJECT(/*model*/ MODEL_TTM_SLIDE_EXIT_PODIUM, /*pos*/ -7285, -1866, -4812, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(WARP_NODE_0A), /*bhv*/ bhvExitPodiumWarp), + WARP_NODE(/*id*/ WARP_NODE_0A, /*destLevel*/ LEVEL_TTM, /*destArea*/ 1, /*destNode*/ WARP_NODE_14, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_SUCCESS, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 2, /*destNode*/ WARP_NODE_34, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_DEATH, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 2, /*destNode*/ WARP_NODE_66, /*flags*/ WARP_NO_CHECKPOINT), JUMP_LINK(script_func_local_6), JUMP_LINK(script_func_local_7), TERRAIN(/*terrainData*/ ttm_seg7_area_4_collision), diff --git a/levels/ttm/slide_exit_podium/geo.inc.c b/levels/ttm/slide_exit_podium/geo.inc.c index 71b888b5..3a8f8afa 100644 --- a/levels/ttm/slide_exit_podium/geo.inc.c +++ b/levels/ttm/slide_exit_podium/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000DF4 const GeoLayout ttm_geo_000DF4[] = { - GEO_CULLING_RADIUS(8000), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, ttm_seg7_dl_0702BB60), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(8000), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, ttm_seg7_dl_0702BB60), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/ttm/star_cage/geo.inc.c b/levels/ttm/star_cage/geo.inc.c index c4cc6880..e0c7d28a 100644 --- a/levels/ttm/star_cage/geo.inc.c +++ b/levels/ttm/star_cage/geo.inc.c @@ -1,9 +1,9 @@ // 0x0E000710 const GeoLayout ttm_geo_000710[] = { - GEO_CULLING_RADIUS(300), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, ttm_seg7_dl_07013430), - GEO_DISPLAY_LIST(LAYER_ALPHA, ttm_seg7_dl_07013608), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(300), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, ttm_seg7_dl_07013430), + GEO_DISPLAY_LIST(LAYER_ALPHA, ttm_seg7_dl_07013608), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/ttm/star_smiley/geo.inc.c b/levels/ttm/star_smiley/geo.inc.c index e8033457..e6989ac5 100644 --- a/levels/ttm/star_smiley/geo.inc.c +++ b/levels/ttm/star_smiley/geo.inc.c @@ -1,14 +1,14 @@ // 0x0E000D84 const GeoLayout ttm_geo_000D84[] = { - GEO_CULLING_RADIUS(1000), - GEO_OPEN_NODE(), - GEO_BILLBOARD(), - GEO_OPEN_NODE(), - GEO_SCALE(0x00, 32768), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, ttm_seg7_dl_0702AB90), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(1000), + GEO_OPEN_NODE(), + GEO_BILLBOARD(), + GEO_OPEN_NODE(), + GEO_SCALE(0x00, 32768), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, ttm_seg7_dl_0702AB90), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/ttm/yellow_smiley/geo.inc.c b/levels/ttm/yellow_smiley/geo.inc.c index 5257789f..e966723c 100644 --- a/levels/ttm/yellow_smiley/geo.inc.c +++ b/levels/ttm/yellow_smiley/geo.inc.c @@ -1,14 +1,14 @@ // 0x0E000D4C const GeoLayout ttm_geo_000D4C[] = { - GEO_CULLING_RADIUS(1000), - GEO_OPEN_NODE(), - GEO_BILLBOARD(), - GEO_OPEN_NODE(), - GEO_SCALE(0x00, 32768), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, ttm_seg7_dl_0702AAA8), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(1000), + GEO_OPEN_NODE(), + GEO_BILLBOARD(), + GEO_OPEN_NODE(), + GEO_SCALE(0x00, 32768), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, ttm_seg7_dl_0702AAA8), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/vcutm/areas/1/geo.inc.c b/levels/vcutm/areas/1/geo.inc.c index 86b60944..da4e4204 100644 --- a/levels/vcutm/areas/1/geo.inc.c +++ b/levels/vcutm/areas/1/geo.inc.c @@ -1,29 +1,29 @@ // 0x0E000208 const GeoLayout vcutm_geo_000208[] = { - GEO_NODE_SCREEN_AREA(10, SCREEN_WIDTH/2, SCREEN_HEIGHT/2, SCREEN_WIDTH/2, SCREEN_HEIGHT/2), - GEO_OPEN_NODE(), - GEO_ZBUFFER(0), - GEO_OPEN_NODE(), - GEO_NODE_ORTHO(100), - GEO_OPEN_NODE(), - GEO_BACKGROUND_COLOR(0x0001), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ZBUFFER(1), - GEO_OPEN_NODE(), - GEO_CAMERA_FRUSTUM_WITH_FUNC(45, 100, 25000, geo_camera_fov), - GEO_OPEN_NODE(), - GEO_CAMERA(14, 0, 2000, 6000, 0, 0, 0, geo_camera_main), + GEO_NODE_SCREEN_AREA(10, SCREEN_WIDTH/2, SCREEN_HEIGHT/2, SCREEN_WIDTH/2, SCREEN_HEIGHT/2), + GEO_OPEN_NODE(), + GEO_ZBUFFER(0), + GEO_OPEN_NODE(), + GEO_NODE_ORTHO(100), GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, vcutm_seg7_dl_07007E88), - GEO_DISPLAY_LIST(LAYER_OPAQUE, vcutm_seg7_dl_07008E10), - GEO_DISPLAY_LIST(LAYER_OPAQUE, vcutm_seg7_dl_070093E8), - GEO_DISPLAY_LIST(LAYER_ALPHA, vcutm_seg7_dl_070080D0), - GEO_RENDER_OBJ(), - GEO_ASM(0, geo_envfx_main), + GEO_BACKGROUND_COLOR(0x0001), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CLOSE_NODE(), + GEO_ZBUFFER(1), + GEO_OPEN_NODE(), + GEO_CAMERA_FRUSTUM_WITH_FUNC(45, 100, 25000, geo_camera_fov), + GEO_OPEN_NODE(), + GEO_CAMERA(14, 0, 2000, 6000, 0, 0, 0, geo_camera_main), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, vcutm_seg7_dl_07007E88), + GEO_DISPLAY_LIST(LAYER_OPAQUE, vcutm_seg7_dl_07008E10), + GEO_DISPLAY_LIST(LAYER_OPAQUE, vcutm_seg7_dl_070093E8), + GEO_DISPLAY_LIST(LAYER_ALPHA, vcutm_seg7_dl_070080D0), + GEO_RENDER_OBJ(), + GEO_ASM(0, geo_envfx_main), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/vcutm/areas/1/macro.inc.c b/levels/vcutm/areas/1/macro.inc.c index 04fcfc10..98fa332a 100644 --- a/levels/vcutm/areas/1/macro.inc.c +++ b/levels/vcutm/areas/1/macro.inc.c @@ -1,35 +1,35 @@ // 0x0700AB0C - 0x0700AC44 const MacroObject vcutm_seg7_macro_objs[] = { - MACRO_OBJECT(/*preset*/ macro_box_1up, /*yaw*/ 0, /*pos*/ -3434, 2951, -3076), - MACRO_OBJECT(/*preset*/ macro_1up, /*yaw*/ 0, /*pos*/ -4711, 1594, -2532), - MACRO_OBJECT(/*preset*/ macro_1up, /*yaw*/ 0, /*pos*/ -5952, -393, -1141), - MACRO_OBJECT(/*preset*/ macro_box_vanish_cap, /*yaw*/ 0, /*pos*/ 3980, 300, -6220), - MACRO_OBJECT(/*preset*/ macro_hidden_1up_trigger, /*yaw*/ 0, /*pos*/ 4200, 0, -4940), - MACRO_OBJECT(/*preset*/ macro_hidden_1up_trigger, /*yaw*/ 0, /*pos*/ 4740, 0, -4940), - MACRO_OBJECT(/*preset*/ macro_hidden_1up_trigger, /*yaw*/ 0, /*pos*/ 4740, 0, -4400), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_hidden_1up, /*yaw*/ 0, /*pos*/ 4460, 0, -4700, /*behParam*/ 3), - MACRO_OBJECT(/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ 4200, 0, -4940), - MACRO_OBJECT(/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ 4740, 0, -4940), - MACRO_OBJECT(/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ 4740, 0, -4400), - MACRO_OBJECT(/*preset*/ macro_coin_line_horizontal, /*yaw*/ 0, /*pos*/ -2100, -3276, 20), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_circling_amp, /*yaw*/ 0, /*pos*/ -2100, -2800, -3866, /*behParam*/ 1), - MACRO_OBJECT(/*preset*/ macro_box_three_coins, /*yaw*/ 0, /*pos*/ -2145, -2160, -5963), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -5920, 4575, -4618), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -4740, 3581, -3854), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -4727, -227, -1161), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -3418, -559, -836), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -600, -1400, -6300), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 900, -1400, -6300), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 2750, -800, -6300), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 4509, 0, -5527), - MACRO_OBJECT(/*preset*/ macro_fire_spitter, /*yaw*/ 0, /*pos*/ -1740, -3240, 1580), - MACRO_OBJECT(/*preset*/ macro_fire_spitter, /*yaw*/ 0, /*pos*/ -2400, -3240, 600), - MACRO_OBJECT(/*preset*/ macro_fire_spitter, /*yaw*/ 0, /*pos*/ -1740, -3240, 0), - MACRO_OBJECT(/*preset*/ macro_fire_spitter, /*yaw*/ 0, /*pos*/ -2400, -3240, -1079), - MACRO_OBJECT(/*preset*/ macro_fire_spitter, /*yaw*/ 0, /*pos*/ -2920, -3240, 880), - MACRO_OBJECT(/*preset*/ macro_fire_spitter, /*yaw*/ 0, /*pos*/ -4000, -3240, 1600), - MACRO_OBJECT(/*preset*/ macro_box_vanish_cap, /*yaw*/ 0, /*pos*/ -6020, -2976, 1240), - MACRO_OBJECT(/*preset*/ macro_fire_spitter, /*yaw*/ 0, /*pos*/ -2100, -2840, -3866), - MACRO_OBJECT(/*preset*/ macro_fire_spitter, /*yaw*/ 0, /*pos*/ -4600, 5760, -6140), + MACRO_OBJECT (/*preset*/ macro_box_1up, /*yaw*/ 0, /*pos*/ -3434, 2951, -3076), + MACRO_OBJECT (/*preset*/ macro_1up, /*yaw*/ 0, /*pos*/ -4711, 1594, -2532), + MACRO_OBJECT (/*preset*/ macro_1up, /*yaw*/ 0, /*pos*/ -5952, -393, -1141), + MACRO_OBJECT (/*preset*/ macro_box_vanish_cap, /*yaw*/ 0, /*pos*/ 3980, 300, -6220), + MACRO_OBJECT (/*preset*/ macro_hidden_1up_trigger, /*yaw*/ 0, /*pos*/ 4200, 0, -4940), + MACRO_OBJECT (/*preset*/ macro_hidden_1up_trigger, /*yaw*/ 0, /*pos*/ 4740, 0, -4940), + MACRO_OBJECT (/*preset*/ macro_hidden_1up_trigger, /*yaw*/ 0, /*pos*/ 4740, 0, -4400), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_hidden_1up, /*yaw*/ 0, /*pos*/ 4460, 0, -4700, /*bhvParam*/ 3), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ 4200, 0, -4940), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ 4740, 0, -4940), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_2, /*yaw*/ 0, /*pos*/ 4740, 0, -4400), + MACRO_OBJECT (/*preset*/ macro_coin_line_horizontal, /*yaw*/ 0, /*pos*/ -2100, -3276, 20), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_circling_amp, /*yaw*/ 0, /*pos*/ -2100, -2800, -3866, /*bhvParam*/ AMP_BP_ROT_RADIUS_300), + MACRO_OBJECT (/*preset*/ macro_box_three_coins, /*yaw*/ 0, /*pos*/ -2145, -2160, -5963), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -5920, 4575, -4618), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -4740, 3581, -3854), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -4727, -227, -1161), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -3418, -559, -836), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -600, -1400, -6300), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 900, -1400, -6300), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 2750, -800, -6300), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 4509, 0, -5527), + MACRO_OBJECT (/*preset*/ macro_fire_spitter, /*yaw*/ 0, /*pos*/ -1740, -3240, 1580), + MACRO_OBJECT (/*preset*/ macro_fire_spitter, /*yaw*/ 0, /*pos*/ -2400, -3240, 600), + MACRO_OBJECT (/*preset*/ macro_fire_spitter, /*yaw*/ 0, /*pos*/ -1740, -3240, 0), + MACRO_OBJECT (/*preset*/ macro_fire_spitter, /*yaw*/ 0, /*pos*/ -2400, -3240, -1079), + MACRO_OBJECT (/*preset*/ macro_fire_spitter, /*yaw*/ 0, /*pos*/ -2920, -3240, 880), + MACRO_OBJECT (/*preset*/ macro_fire_spitter, /*yaw*/ 0, /*pos*/ -4000, -3240, 1600), + MACRO_OBJECT (/*preset*/ macro_box_vanish_cap, /*yaw*/ 0, /*pos*/ -6020, -2976, 1240), + MACRO_OBJECT (/*preset*/ macro_fire_spitter, /*yaw*/ 0, /*pos*/ -2100, -2840, -3866), + MACRO_OBJECT (/*preset*/ macro_fire_spitter, /*yaw*/ 0, /*pos*/ -4600, 5760, -6140), MACRO_OBJECT_END(), }; diff --git a/levels/vcutm/level.yaml b/levels/vcutm/level.yaml index c6961e8b..9ac54f52 100644 --- a/levels/vcutm/level.yaml +++ b/levels/vcutm/level.yaml @@ -1,6 +1,6 @@ # Vanish Cap under the Moat short-name: vcutm -full-name: Vanish Cap Under The Moat +full-name: Vanish Cap under the Moat texture-file: ["/texture.inc.c"] area-count: 1 objects: [seesaw] diff --git a/levels/vcutm/leveldata.c b/levels/vcutm/leveldata.c index bb2aa0ec..967b0146 100644 --- a/levels/vcutm/leveldata.c +++ b/levels/vcutm/leveldata.c @@ -3,8 +3,8 @@ #include "surface_terrains.h" #include "moving_texture_macros.h" #include "level_misc_macros.h" -#include "macro_preset_names.h" -#include "special_preset_names.h" +#include "macro_presets.h" +#include "special_presets.h" #include "textures.h" #include "make_const_nonconst.h" diff --git a/levels/vcutm/script.c b/levels/vcutm/script.c index fb52c956..1d609f7d 100644 --- a/levels/vcutm/script.c +++ b/levels/vcutm/script.c @@ -17,47 +17,47 @@ #include "levels/vcutm/header.h" static const LevelScript script_func_local_1[] = { - OBJECT(/*model*/ MODEL_VCUTM_SEESAW_PLATFORM, /*pos*/ 154, -1919, -6256, /*angle*/ 0, 270, 0, /*behParam*/ 0x00070000, /*beh*/ bhvSeesawPlatform), - OBJECT(/*model*/ MODEL_VCUTM_SEESAW_PLATFORM, /*pos*/ -2047, -3378, -2047, /*angle*/ 0, 0, 0, /*behParam*/ 0x00070000, /*beh*/ bhvSeesawPlatform), + OBJECT(/*model*/ MODEL_VCUTM_SEESAW_PLATFORM, /*pos*/ 154, -1919, -6256, /*angle*/ 0, 270, 0, /*bhvParam*/ BPARAM2(0x07), /*bhv*/ bhvSeesawPlatform), + OBJECT(/*model*/ MODEL_VCUTM_SEESAW_PLATFORM, /*pos*/ -2047, -3378, -2047, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(0x07), /*bhv*/ bhvSeesawPlatform), //! @bug invalid model IDs - model ID 0x37 isn't loaded - OBJECT(/*model*/ MODEL_VCUTM_CHECKERBOARD_PLATFORM_SPAWNER, /*pos*/ 3251, -1082, -6256, /*angle*/ 0, 270, 0, /*behParam*/ 0x014B0000, /*beh*/ bhvCheckerboardElevatorGroup), - OBJECT(/*model*/ MODEL_VCUTM_CHECKERBOARD_PLATFORM_SPAWNER, /*pos*/ 2355, -1901, -6256, /*angle*/ 0, 270, 0, /*behParam*/ 0x014B0000, /*beh*/ bhvCheckerboardElevatorGroup), - OBJECT(/*model*/ MODEL_VCUTM_CHECKERBOARD_PLATFORM_SPAWNER, /*pos*/ 1459, -1594, -6256, /*angle*/ 0, 90, 0, /*behParam*/ 0x014B0000, /*beh*/ bhvCheckerboardElevatorGroup), - OBJECT(/*model*/ MODEL_VCUTM_CHECKERBOARD_PLATFORM_SPAWNER, /*pos*/ -1151, -2413, -6256, /*angle*/ 0, 270, 0, /*behParam*/ 0x014B0000, /*beh*/ bhvCheckerboardElevatorGroup), + OBJECT(/*model*/ MODEL_VCUTM_CHECKERBOARD_PLATFORM_SPAWNER, /*pos*/ 3251, -1082, -6256, /*angle*/ 0, 270, 0, /*bhvParam*/ BPARAM1(1) | BPARAM2(75), /*bhv*/ bhvCheckerboardElevatorGroup), + OBJECT(/*model*/ MODEL_VCUTM_CHECKERBOARD_PLATFORM_SPAWNER, /*pos*/ 2355, -1901, -6256, /*angle*/ 0, 270, 0, /*bhvParam*/ BPARAM1(1) | BPARAM2(75), /*bhv*/ bhvCheckerboardElevatorGroup), + OBJECT(/*model*/ MODEL_VCUTM_CHECKERBOARD_PLATFORM_SPAWNER, /*pos*/ 1459, -1594, -6256, /*angle*/ 0, 90, 0, /*bhvParam*/ BPARAM1(1) | BPARAM2(75), /*bhv*/ bhvCheckerboardElevatorGroup), + OBJECT(/*model*/ MODEL_VCUTM_CHECKERBOARD_PLATFORM_SPAWNER, /*pos*/ -1151, -2413, -6256, /*angle*/ 0, 270, 0, /*bhvParam*/ BPARAM1(1) | BPARAM2(75), /*bhv*/ bhvCheckerboardElevatorGroup), RETURN(), }; static const LevelScript script_func_local_2[] = { - OBJECT(/*model*/ MODEL_CAP_SWITCH, /*pos*/ 4506, 26, -6246, /*angle*/ 0, 0, 0, /*behParam*/ 0x00020000, /*beh*/ bhvCapSwitch), + OBJECT(/*model*/ MODEL_CAP_SWITCH, /*pos*/ 4506, 26, -6246, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(0x02), /*bhv*/ bhvCapSwitch), RETURN(), }; static const LevelScript script_func_local_3[] = { - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 4600, 250, -4500, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvHiddenRedCoinStar), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 4600, 250, -4500, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(STAR_INDEX_ACT_1), /*bhv*/ bhvHiddenRedCoinStar), RETURN(), }; const LevelScript level_vcutm_entry[] = { INIT_LEVEL(), LOAD_MIO0_TEXTURE(/*seg*/ 0x09, _outside_mio0SegmentRomStart, _outside_mio0SegmentRomEnd), - LOAD_MIO0( /*seg*/ 0x07, _vcutm_segment_7SegmentRomStart, _vcutm_segment_7SegmentRomEnd), - LOAD_MIO0( /*seg*/ 0x05, _group8_mio0SegmentRomStart, _group8_mio0SegmentRomEnd), - LOAD_RAW( /*seg*/ 0x0C, _group8_geoSegmentRomStart, _group8_geoSegmentRomEnd), - LOAD_MIO0( /*seg*/ 0x08, _common0_mio0SegmentRomStart, _common0_mio0SegmentRomEnd), - LOAD_RAW( /*seg*/ 0x0F, _common0_geoSegmentRomStart, _common0_geoSegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x07, _vcutm_segment_7SegmentRomStart, _vcutm_segment_7SegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x05, _group8_mio0SegmentRomStart, _group8_mio0SegmentRomEnd), + LOAD_RAW (/*seg*/ 0x0C, _group8_geoSegmentRomStart, _group8_geoSegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x08, _common0_mio0SegmentRomStart, _common0_mio0SegmentRomEnd), + LOAD_RAW (/*seg*/ 0x0F, _common0_geoSegmentRomStart, _common0_geoSegmentRomEnd), ALLOC_LEVEL_POOL(), - MARIO(/*model*/ MODEL_MARIO, /*behParam*/ 0x00000001, /*beh*/ bhvMario), + MARIO(/*model*/ MODEL_MARIO, /*bhvParam*/ BPARAM4(0x01), /*bhv*/ bhvMario), JUMP_LINK(script_func_global_1), JUMP_LINK(script_func_global_9), LOAD_MODEL_FROM_GEO(MODEL_VCUTM_SEESAW_PLATFORM, vcutm_geo_0001F0), LOAD_MODEL_FROM_GEO(MODEL_VCUTM_WARP_PIPE, warp_pipe_geo), AREA(/*index*/ 1, vcutm_geo_000208), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -6143, 6734, -6143, /*angle*/ 0, 0, 0, /*behParam*/ 0x000A0000, /*beh*/ bhvAirborneWarp), - WARP_NODE(/*id*/ 0x0A, /*destLevel*/ LEVEL_VCUTM, /*destArea*/ 0x01, /*destNode*/ 0x0A, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0xF3, /*destLevel*/ LEVEL_CASTLE_GROUNDS, /*destArea*/ 0x01, /*destNode*/ 0x07, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0xF0, /*destLevel*/ LEVEL_CASTLE_GROUNDS, /*destArea*/ 0x01, /*destNode*/ 0x08, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0xF1, /*destLevel*/ LEVEL_CASTLE_GROUNDS, /*destArea*/ 0x01, /*destNode*/ 0x06, /*flags*/ WARP_NO_CHECKPOINT), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ -6143, 6734, -6143, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(WARP_NODE_0A), /*bhv*/ bhvAirborneWarp), + WARP_NODE(/*id*/ WARP_NODE_0A, /*destLevel*/ LEVEL_VCUTM, /*destArea*/ 1, /*destNode*/ WARP_NODE_0A, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_WARP_FLOOR, /*destLevel*/ LEVEL_CASTLE_GROUNDS, /*destArea*/ 1, /*destNode*/ WARP_NODE_07, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_SUCCESS, /*destLevel*/ LEVEL_CASTLE_GROUNDS, /*destArea*/ 1, /*destNode*/ WARP_NODE_08, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_DEATH, /*destLevel*/ LEVEL_CASTLE_GROUNDS, /*destArea*/ 1, /*destNode*/ WARP_NODE_06, /*flags*/ WARP_NO_CHECKPOINT), JUMP_LINK(script_func_local_3), JUMP_LINK(script_func_local_1), JUMP_LINK(script_func_local_2), diff --git a/levels/vcutm/seesaw/geo.inc.c b/levels/vcutm/seesaw/geo.inc.c index 0c644141..6728e1fc 100644 --- a/levels/vcutm/seesaw/geo.inc.c +++ b/levels/vcutm/seesaw/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E0001F0 const GeoLayout vcutm_geo_0001F0[] = { - GEO_CULLING_RADIUS(1000), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, vcutm_seg7_dl_070096E0), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(1000), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, vcutm_seg7_dl_070096E0), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/wdw/areas/1/geo.inc.c b/levels/wdw/areas/1/geo.inc.c index 662c3b91..046449e4 100644 --- a/levels/wdw/areas/1/geo.inc.c +++ b/levels/wdw/areas/1/geo.inc.c @@ -1,36 +1,36 @@ // 0x0E000658 const GeoLayout wdw_geo_000658[] = { - GEO_NODE_SCREEN_AREA(10, SCREEN_WIDTH/2, SCREEN_HEIGHT/2, SCREEN_WIDTH/2, SCREEN_HEIGHT/2), - GEO_OPEN_NODE(), - GEO_ZBUFFER(0), - GEO_OPEN_NODE(), - GEO_NODE_ORTHO(100), - GEO_OPEN_NODE(), - GEO_BACKGROUND(BACKGROUND_UNDERWATER_CITY, geo_skybox_main), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ZBUFFER(1), - GEO_OPEN_NODE(), - GEO_CAMERA_FRUSTUM_WITH_FUNC(45, 100, 12800, geo_camera_fov), - GEO_OPEN_NODE(), - GEO_CAMERA(1, 0, 2000, 6000, -4352, 0, -4352, geo_camera_main), + GEO_NODE_SCREEN_AREA(10, SCREEN_WIDTH/2, SCREEN_HEIGHT/2, SCREEN_WIDTH/2, SCREEN_HEIGHT/2), + GEO_OPEN_NODE(), + GEO_ZBUFFER(0), + GEO_OPEN_NODE(), + GEO_NODE_ORTHO(100), GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, wdw_seg7_dl_07009AB0), - GEO_DISPLAY_LIST(LAYER_ALPHA, wdw_seg7_dl_0700A138), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, wdw_seg7_dl_07012798), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT_DECAL, wdw_seg7_dl_07012908), - GEO_ASM( 0, geo_wdw_set_initial_water_level), - GEO_ASM( 0, geo_movtex_pause_control), - GEO_ASM(0x1101, geo_movtex_draw_water_regions), - GEO_RENDER_OBJ(), - GEO_ASM( 0, geo_envfx_main), + GEO_BACKGROUND(BACKGROUND_UNDERWATER_CITY, geo_skybox_main), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ZBUFFER(0), - GEO_OPEN_NODE(), - GEO_ASM(0, geo_cannon_circle_base), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CLOSE_NODE(), + GEO_ZBUFFER(1), + GEO_OPEN_NODE(), + GEO_CAMERA_FRUSTUM_WITH_FUNC(45, 100, 12800, geo_camera_fov), + GEO_OPEN_NODE(), + GEO_CAMERA(1, 0, 2000, 6000, -4352, 0, -4352, geo_camera_main), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, wdw_seg7_dl_07009AB0), + GEO_DISPLAY_LIST(LAYER_ALPHA, wdw_seg7_dl_0700A138), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, wdw_seg7_dl_07012798), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT_DECAL, wdw_seg7_dl_07012908), + GEO_ASM( 0, geo_wdw_set_initial_water_level), + GEO_ASM( 0, geo_movtex_pause_control), + GEO_ASM(0x1101, geo_movtex_draw_water_regions), + GEO_RENDER_OBJ(), + GEO_ASM( 0, geo_envfx_main), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ZBUFFER(0), + GEO_OPEN_NODE(), + GEO_ASM(0, geo_cannon_circle_base), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/wdw/areas/1/macro.inc.c b/levels/wdw/areas/1/macro.inc.c index c27d5c7c..7e3e3822 100644 --- a/levels/wdw/areas/1/macro.inc.c +++ b/levels/wdw/areas/1/macro.inc.c @@ -1,65 +1,65 @@ // 0x070160D8 - 0x0701633C const MacroObject wdw_seg7_area_1_macro_objs[] = { - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 0, /*pos*/ -2077, 2816, -660, /*behParam*/ DIALOG_081), - MACRO_OBJECT(/*preset*/ macro_bobomb_buddy_opens_cannon, /*yaw*/ 0, /*pos*/ -2, 2944, 3583), - MACRO_OBJECT(/*preset*/ macro_coin_ring_horizontal, /*yaw*/ 0, /*pos*/ -2057, 2800, -500), - MACRO_OBJECT(/*preset*/ macro_coin_line_horizontal, /*yaw*/ 90, /*pos*/ 1500, 1741, 2191), - MACRO_OBJECT(/*preset*/ macro_blue_coin_switch, /*yaw*/ 0, /*pos*/ 500, 384, 250), - MACRO_OBJECT(/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ 1124, 400, -218), - MACRO_OBJECT(/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ 1124, 400, 830), - MACRO_OBJECT(/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ 832, 400, 1194), - MACRO_OBJECT(/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ 1124, 400, 282), - MACRO_OBJECT(/*preset*/ macro_box_star_1, /*yaw*/ 0, /*pos*/ -2200, 2600, 3500), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_circling_amp, /*yaw*/ 0, /*pos*/ -1360, 3880, -1340, /*behParam*/ 2), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_circling_amp, /*yaw*/ 0, /*pos*/ 640, 700, 3720, /*behParam*/ 2), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_circling_amp, /*yaw*/ 0, /*pos*/ -2100, 2400, -500, /*behParam*/ 2), - MACRO_OBJECT(/*preset*/ macro_heave_ho, /*yaw*/ 0, /*pos*/ -2656, 2300, -1352), - MACRO_OBJECT(/*preset*/ macro_heave_ho, /*yaw*/ 0, /*pos*/ -2909, 1140, 442), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_cannon_closed, /*yaw*/ 0, /*pos*/ -2688, 3328, 3198, /*behParam*/ 0x40), - MACRO_OBJECT(/*preset*/ macro_pushable_metal_box, /*yaw*/ 0, /*pos*/ -2200, 384, 1145), - MACRO_OBJECT(/*preset*/ macro_1up, /*yaw*/ 0, /*pos*/ -1129, 3857, 1404), - MACRO_OBJECT(/*preset*/ macro_1up, /*yaw*/ 0, /*pos*/ -882, 4018, 1164), - MACRO_OBJECT(/*preset*/ macro_chuckya, /*yaw*/ 0, /*pos*/ -2963, 3840, -3063), - MACRO_OBJECT(/*preset*/ macro_heave_ho, /*yaw*/ 0, /*pos*/ -3040, 384, 1840), - MACRO_OBJECT(/*preset*/ macro_pushable_metal_box, /*yaw*/ 0, /*pos*/ -1843, 2304, -3694), - MACRO_OBJECT(/*preset*/ macro_hidden_star_trigger, /*yaw*/ 0, /*pos*/ 943, 3830, -1779), - MACRO_OBJECT(/*preset*/ macro_hidden_star_trigger, /*yaw*/ 0, /*pos*/ -2200, 384, 1145), - MACRO_OBJECT(/*preset*/ macro_hidden_star_trigger, /*yaw*/ 0, /*pos*/ -2075, 3000, -524), - MACRO_OBJECT(/*preset*/ macro_hidden_star_trigger, /*yaw*/ 0, /*pos*/ -3760, 650, 4120), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_circling_amp, /*yaw*/ 0, /*pos*/ -827, 3880, -827, /*behParam*/ 2), - MACRO_OBJECT(/*preset*/ macro_breakable_box_no_coins, /*yaw*/ 0, /*pos*/ 1360, 205, -1384), - MACRO_OBJECT(/*preset*/ macro_floor_switch_hidden_objects, /*yaw*/ 0, /*pos*/ 920, 2300, -840), - MACRO_OBJECT(/*preset*/ macro_hidden_box, /*yaw*/ 0, /*pos*/ 470, 2300, -1310), - MACRO_OBJECT(/*preset*/ macro_hidden_box, /*yaw*/ 0, /*pos*/ 470, 2500, -1510), - MACRO_OBJECT(/*preset*/ macro_hidden_box, /*yaw*/ 0, /*pos*/ 470, 2700, -1710), - MACRO_OBJECT(/*preset*/ macro_hidden_box, /*yaw*/ 0, /*pos*/ 470, 2900, -1910), - MACRO_OBJECT(/*preset*/ macro_hidden_box, /*yaw*/ 0, /*pos*/ 470, 3100, -2110), - MACRO_OBJECT(/*preset*/ macro_fire_spitter, /*yaw*/ 0, /*pos*/ 3140, 1300, 2040), - MACRO_OBJECT(/*preset*/ macro_fire_spitter, /*yaw*/ 0, /*pos*/ -20, 400, 1520), - MACRO_OBJECT(/*preset*/ macro_fire_spitter, /*yaw*/ 0, /*pos*/ -1780, 1160, -40), - MACRO_OBJECT(/*preset*/ macro_fire_spitter, /*yaw*/ 0, /*pos*/ -2280, 2320, -2280), - MACRO_OBJECT(/*preset*/ macro_fire_spitter, /*yaw*/ 0, /*pos*/ 1240, 2340, -3300), - MACRO_OBJECT(/*preset*/ macro_fire_spitter, /*yaw*/ 0, /*pos*/ -2240, 2320, 3820), - MACRO_OBJECT(/*preset*/ macro_fire_spitter, /*yaw*/ 0, /*pos*/ -220, 3860, 60), - MACRO_OBJECT(/*preset*/ macro_fire_spitter, /*yaw*/ 0, /*pos*/ -240, 400, -440), - MACRO_OBJECT(/*preset*/ macro_breakable_box_three_coins, /*yaw*/ 0, /*pos*/ 4509, 0, 3069), - MACRO_OBJECT(/*preset*/ macro_breakable_box_three_coins, /*yaw*/ 0, /*pos*/ 4509, 0, 2873), - MACRO_OBJECT(/*preset*/ macro_pushable_metal_box, /*yaw*/ 0, /*pos*/ -3689, 0, 3205), - MACRO_OBJECT(/*preset*/ macro_hidden_box, /*yaw*/ 0, /*pos*/ 470, 3100, -2310), - MACRO_OBJECT(/*preset*/ macro_breakable_box_giant, /*yaw*/ 0, /*pos*/ -3093, 300, 3300), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_circling_amp, /*yaw*/ 0, /*pos*/ -1500, 2360, 3120, /*behParam*/ 2), - MACRO_OBJECT(/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ 420, 400, 1504), - MACRO_OBJECT(/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ -12, 400, 1808), - MACRO_OBJECT(/*preset*/ macro_box_ten_coins, /*yaw*/ 0, /*pos*/ -2075, 3050, -524), - MACRO_OBJECT(/*preset*/ macro_box_ten_coins, /*yaw*/ 0, /*pos*/ 943, 3880, -1779), - MACRO_OBJECT(/*preset*/ macro_hidden_star_trigger, /*yaw*/ 0, /*pos*/ -3689, 0, 3205), - MACRO_OBJECT(/*preset*/ macro_breakable_box_three_coins, /*yaw*/ 0, /*pos*/ 4500, 0, 1240), - MACRO_OBJECT(/*preset*/ macro_box_three_coins, /*yaw*/ 0, /*pos*/ -2200, 3060, -3700), - MACRO_OBJECT(/*preset*/ macro_box_ten_coins, /*yaw*/ 0, /*pos*/ -3760, 700, 4120), - MACRO_OBJECT(/*preset*/ macro_box_three_coins, /*yaw*/ 0, /*pos*/ 3388, 1600, 1155), - MACRO_OBJECT(/*preset*/ macro_coin_line_horizontal, /*yaw*/ 90, /*pos*/ 740, 3072, -3560), - MACRO_OBJECT(/*preset*/ macro_box_star_2, /*yaw*/ 0, /*pos*/ 1550, 4350, 100), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 0, /*pos*/ 740, 3060, -3680, /*behParam*/ DIALOG_053), - MACRO_OBJECT(/*preset*/ macro_breakable_box_three_coins, /*yaw*/ 0, /*pos*/ 4500, 0, 1040), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 0, /*pos*/ -2077, 2816, -660, /*bhvParam*/ DIALOG_081), + MACRO_OBJECT (/*preset*/ macro_bobomb_buddy_opens_cannon_1, /*yaw*/ 0, /*pos*/ -2, 2944, 3583), + MACRO_OBJECT (/*preset*/ macro_coin_ring_horizontal, /*yaw*/ 0, /*pos*/ -2057, 2800, -500), + MACRO_OBJECT (/*preset*/ macro_coin_line_horizontal, /*yaw*/ 90, /*pos*/ 1500, 1741, 2191), + MACRO_OBJECT (/*preset*/ macro_blue_coin_switch, /*yaw*/ 0, /*pos*/ 500, 384, 250), + MACRO_OBJECT (/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ 1124, 400, -218), + MACRO_OBJECT (/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ 1124, 400, 830), + MACRO_OBJECT (/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ 832, 400, 1194), + MACRO_OBJECT (/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ 1124, 400, 282), + MACRO_OBJECT (/*preset*/ macro_box_star_act_1, /*yaw*/ 0, /*pos*/ -2200, 2600, 3500), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_circling_amp, /*yaw*/ 0, /*pos*/ -1360, 3880, -1340, /*bhvParam*/ AMP_BP_ROT_RADIUS_400), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_circling_amp, /*yaw*/ 0, /*pos*/ 640, 700, 3720, /*bhvParam*/ AMP_BP_ROT_RADIUS_400), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_circling_amp, /*yaw*/ 0, /*pos*/ -2100, 2400, -500, /*bhvParam*/ AMP_BP_ROT_RADIUS_400), + MACRO_OBJECT (/*preset*/ macro_heave_ho, /*yaw*/ 0, /*pos*/ -2656, 2300, -1352), + MACRO_OBJECT (/*preset*/ macro_heave_ho, /*yaw*/ 0, /*pos*/ -2909, 1140, 442), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_cannon_closed, /*yaw*/ 0, /*pos*/ -2688, 3328, 3198, /*bhvParam*/ 0x40), + MACRO_OBJECT (/*preset*/ macro_pushable_metal_box, /*yaw*/ 0, /*pos*/ -2200, 384, 1145), + MACRO_OBJECT (/*preset*/ macro_1up, /*yaw*/ 0, /*pos*/ -1129, 3857, 1404), + MACRO_OBJECT (/*preset*/ macro_1up, /*yaw*/ 0, /*pos*/ -882, 4018, 1164), + MACRO_OBJECT (/*preset*/ macro_chuckya, /*yaw*/ 0, /*pos*/ -2963, 3840, -3063), + MACRO_OBJECT (/*preset*/ macro_heave_ho, /*yaw*/ 0, /*pos*/ -3040, 384, 1840), + MACRO_OBJECT (/*preset*/ macro_pushable_metal_box, /*yaw*/ 0, /*pos*/ -1843, 2304, -3694), + MACRO_OBJECT (/*preset*/ macro_hidden_star_trigger, /*yaw*/ 0, /*pos*/ 943, 3830, -1779), + MACRO_OBJECT (/*preset*/ macro_hidden_star_trigger, /*yaw*/ 0, /*pos*/ -2200, 384, 1145), + MACRO_OBJECT (/*preset*/ macro_hidden_star_trigger, /*yaw*/ 0, /*pos*/ -2075, 3000, -524), + MACRO_OBJECT (/*preset*/ macro_hidden_star_trigger, /*yaw*/ 0, /*pos*/ -3760, 650, 4120), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_circling_amp, /*yaw*/ 0, /*pos*/ -827, 3880, -827, /*bhvParam*/ AMP_BP_ROT_RADIUS_400), + MACRO_OBJECT (/*preset*/ macro_breakable_box_no_coins, /*yaw*/ 0, /*pos*/ 1360, 205, -1384), + MACRO_OBJECT (/*preset*/ macro_floor_switch_hidden_objects, /*yaw*/ 0, /*pos*/ 920, 2300, -840), + MACRO_OBJECT (/*preset*/ macro_hidden_breakable_box, /*yaw*/ 0, /*pos*/ 470, 2300, -1310), + MACRO_OBJECT (/*preset*/ macro_hidden_breakable_box, /*yaw*/ 0, /*pos*/ 470, 2500, -1510), + MACRO_OBJECT (/*preset*/ macro_hidden_breakable_box, /*yaw*/ 0, /*pos*/ 470, 2700, -1710), + MACRO_OBJECT (/*preset*/ macro_hidden_breakable_box, /*yaw*/ 0, /*pos*/ 470, 2900, -1910), + MACRO_OBJECT (/*preset*/ macro_hidden_breakable_box, /*yaw*/ 0, /*pos*/ 470, 3100, -2110), + MACRO_OBJECT (/*preset*/ macro_fire_spitter, /*yaw*/ 0, /*pos*/ 3140, 1300, 2040), + MACRO_OBJECT (/*preset*/ macro_fire_spitter, /*yaw*/ 0, /*pos*/ -20, 400, 1520), + MACRO_OBJECT (/*preset*/ macro_fire_spitter, /*yaw*/ 0, /*pos*/ -1780, 1160, -40), + MACRO_OBJECT (/*preset*/ macro_fire_spitter, /*yaw*/ 0, /*pos*/ -2280, 2320, -2280), + MACRO_OBJECT (/*preset*/ macro_fire_spitter, /*yaw*/ 0, /*pos*/ 1240, 2340, -3300), + MACRO_OBJECT (/*preset*/ macro_fire_spitter, /*yaw*/ 0, /*pos*/ -2240, 2320, 3820), + MACRO_OBJECT (/*preset*/ macro_fire_spitter, /*yaw*/ 0, /*pos*/ -220, 3860, 60), + MACRO_OBJECT (/*preset*/ macro_fire_spitter, /*yaw*/ 0, /*pos*/ -240, 400, -440), + MACRO_OBJECT (/*preset*/ macro_breakable_box_three_coins, /*yaw*/ 0, /*pos*/ 4509, 0, 3069), + MACRO_OBJECT (/*preset*/ macro_breakable_box_three_coins, /*yaw*/ 0, /*pos*/ 4509, 0, 2873), + MACRO_OBJECT (/*preset*/ macro_pushable_metal_box, /*yaw*/ 0, /*pos*/ -3689, 0, 3205), + MACRO_OBJECT (/*preset*/ macro_hidden_breakable_box, /*yaw*/ 0, /*pos*/ 470, 3100, -2310), + MACRO_OBJECT (/*preset*/ macro_breakable_box_giant, /*yaw*/ 0, /*pos*/ -3093, 300, 3300), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_circling_amp, /*yaw*/ 0, /*pos*/ -1500, 2360, 3120, /*bhvParam*/ AMP_BP_ROT_RADIUS_400), + MACRO_OBJECT (/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ 420, 400, 1504), + MACRO_OBJECT (/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ -12, 400, 1808), + MACRO_OBJECT (/*preset*/ macro_box_ten_coins, /*yaw*/ 0, /*pos*/ -2075, 3050, -524), + MACRO_OBJECT (/*preset*/ macro_box_ten_coins, /*yaw*/ 0, /*pos*/ 943, 3880, -1779), + MACRO_OBJECT (/*preset*/ macro_hidden_star_trigger, /*yaw*/ 0, /*pos*/ -3689, 0, 3205), + MACRO_OBJECT (/*preset*/ macro_breakable_box_three_coins, /*yaw*/ 0, /*pos*/ 4500, 0, 1240), + MACRO_OBJECT (/*preset*/ macro_box_three_coins, /*yaw*/ 0, /*pos*/ -2200, 3060, -3700), + MACRO_OBJECT (/*preset*/ macro_box_ten_coins, /*yaw*/ 0, /*pos*/ -3760, 700, 4120), + MACRO_OBJECT (/*preset*/ macro_box_three_coins, /*yaw*/ 0, /*pos*/ 3388, 1600, 1155), + MACRO_OBJECT (/*preset*/ macro_coin_line_horizontal, /*yaw*/ 90, /*pos*/ 740, 3072, -3560), + MACRO_OBJECT (/*preset*/ macro_box_star_act_2, /*yaw*/ 0, /*pos*/ 1550, 4350, 100), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 0, /*pos*/ 740, 3060, -3680, /*bhvParam*/ DIALOG_053), + MACRO_OBJECT (/*preset*/ macro_breakable_box_three_coins, /*yaw*/ 0, /*pos*/ 4500, 0, 1040), MACRO_OBJECT_END(), }; diff --git a/levels/wdw/areas/2/geo.inc.c b/levels/wdw/areas/2/geo.inc.c index 352d1249..882338f7 100644 --- a/levels/wdw/areas/2/geo.inc.c +++ b/levels/wdw/areas/2/geo.inc.c @@ -1,30 +1,30 @@ // 0x0E000724 const GeoLayout wdw_geo_000724[] = { - GEO_NODE_SCREEN_AREA(10, SCREEN_WIDTH/2, SCREEN_HEIGHT/2, SCREEN_WIDTH/2, SCREEN_HEIGHT/2), - GEO_OPEN_NODE(), - GEO_ZBUFFER(0), - GEO_OPEN_NODE(), - GEO_NODE_ORTHO(100), - GEO_OPEN_NODE(), - GEO_BACKGROUND_COLOR(0x0001), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ZBUFFER(1), - GEO_OPEN_NODE(), - GEO_CAMERA_FRUSTUM_WITH_FUNC(45, 100, 12800, geo_camera_fov), - GEO_OPEN_NODE(), - GEO_CAMERA(1, 0, 2000, 6000, -4352, 0, -4352, geo_camera_main), + GEO_NODE_SCREEN_AREA(10, SCREEN_WIDTH/2, SCREEN_HEIGHT/2, SCREEN_WIDTH/2, SCREEN_HEIGHT/2), + GEO_OPEN_NODE(), + GEO_ZBUFFER(0), + GEO_OPEN_NODE(), + GEO_NODE_ORTHO(100), GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, wdw_seg7_dl_07011E48), - GEO_DISPLAY_LIST(LAYER_ALPHA, wdw_seg7_dl_07012258), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT_DECAL, wdw_seg7_dl_07012908), - GEO_ASM( 0, geo_movtex_pause_control), - GEO_ASM(0x1102, geo_movtex_draw_water_regions), - GEO_RENDER_OBJ(), - GEO_ASM( 0, geo_envfx_main), + GEO_BACKGROUND_COLOR(0x0001), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CLOSE_NODE(), + GEO_ZBUFFER(1), + GEO_OPEN_NODE(), + GEO_CAMERA_FRUSTUM_WITH_FUNC(45, 100, 12800, geo_camera_fov), + GEO_OPEN_NODE(), + GEO_CAMERA(1, 0, 2000, 6000, -4352, 0, -4352, geo_camera_main), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, wdw_seg7_dl_07011E48), + GEO_DISPLAY_LIST(LAYER_ALPHA, wdw_seg7_dl_07012258), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT_DECAL, wdw_seg7_dl_07012908), + GEO_ASM( 0, geo_movtex_pause_control), + GEO_ASM(0x1102, geo_movtex_draw_water_regions), + GEO_RENDER_OBJ(), + GEO_ASM( 0, geo_envfx_main), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/wdw/areas/2/macro.inc.c b/levels/wdw/areas/2/macro.inc.c index f2619ad9..edfb7f0f 100644 --- a/levels/wdw/areas/2/macro.inc.c +++ b/levels/wdw/areas/2/macro.inc.c @@ -1,45 +1,45 @@ // 0x07018224 - 0x070183C0 const MacroObject wdw_seg7_area_2_macro_objs[] = { - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -3720, -1131, 520), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -2930, -850, 2560), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 100, -1771, -1500), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 1820, -1387, 1020), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -370, -1795, -180), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -1180, -1795, -180), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -780, -2155, 2860), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -780, -1020, 3400), - MACRO_OBJECT(/*preset*/ macro_coin_ring_horizontal_flying, /*yaw*/ 0, /*pos*/ -772, -2320, 772), - MACRO_OBJECT(/*preset*/ macro_hidden_1up_trigger, /*yaw*/ 0, /*pos*/ -524, -2560, 524), - MACRO_OBJECT(/*preset*/ macro_hidden_1up_trigger, /*yaw*/ 0, /*pos*/ -1034, -2560, 524), - MACRO_OBJECT(/*preset*/ macro_hidden_1up_trigger, /*yaw*/ 0, /*pos*/ -1034, -2560, 1034), - MACRO_OBJECT(/*preset*/ macro_hidden_1up_trigger, /*yaw*/ 0, /*pos*/ -524, -2560, 1034), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_hidden_1up, /*yaw*/ 0, /*pos*/ -772, -2180, 772, /*behParam*/ 4), - MACRO_OBJECT(/*preset*/ macro_breakable_box_no_coins, /*yaw*/ 0, /*pos*/ -870, -300, 870), - MACRO_OBJECT(/*preset*/ macro_breakable_box_no_coins, /*yaw*/ 0, /*pos*/ -670, -300, 870), - MACRO_OBJECT(/*preset*/ macro_breakable_box_no_coins, /*yaw*/ 0, /*pos*/ -670, -300, 670), - MACRO_OBJECT(/*preset*/ macro_breakable_box_no_coins, /*yaw*/ 0, /*pos*/ -870, -300, 670), - MACRO_OBJECT(/*preset*/ macro_box_metal_cap, /*yaw*/ 0, /*pos*/ -770, 80, 770), - MACRO_OBJECT(/*preset*/ macro_box_vanish_cap, /*yaw*/ 0, /*pos*/ -1779, -2240, 3644), - MACRO_OBJECT(/*preset*/ macro_coin_line_horizontal, /*yaw*/ 0, /*pos*/ 1089, -1279, 968), - MACRO_OBJECT(/*preset*/ macro_skeeter, /*yaw*/ 0, /*pos*/ -1240, -520, 540), - MACRO_OBJECT(/*preset*/ macro_skeeter, /*yaw*/ 0, /*pos*/ -260, -620, 1560), - MACRO_OBJECT(/*preset*/ macro_floor_switch_hidden_objects, /*yaw*/ 0, /*pos*/ -1520, -2516, -1940), - MACRO_OBJECT(/*preset*/ macro_hidden_box, /*yaw*/ 0, /*pos*/ 2200, -2559, 3240), - MACRO_OBJECT(/*preset*/ macro_box_vanish_cap, /*yaw*/ 0, /*pos*/ 1300, -2260, 3740), - MACRO_OBJECT(/*preset*/ macro_fire_spitter, /*yaw*/ 0, /*pos*/ -2060, -1580, -1260), - MACRO_OBJECT(/*preset*/ macro_fire_spitter, /*yaw*/ 0, /*pos*/ 2240, -1420, 2140), - MACRO_OBJECT(/*preset*/ macro_fire_spitter, /*yaw*/ 0, /*pos*/ 2280, -1400, -100), - MACRO_OBJECT(/*preset*/ macro_fire_spitter, /*yaw*/ 0, /*pos*/ -2280, -2520, -740), - MACRO_OBJECT(/*preset*/ macro_fire_spitter, /*yaw*/ 0, /*pos*/ 720, -2520, -740), - MACRO_OBJECT(/*preset*/ macro_breakable_box_giant, /*yaw*/ 0, /*pos*/ -2930, -1000, 2560), - MACRO_OBJECT(/*preset*/ macro_breakable_box_giant, /*yaw*/ 0, /*pos*/ -3690, -1151, 520), - MACRO_OBJECT(/*preset*/ macro_breakable_box_giant, /*yaw*/ 0, /*pos*/ -1180, -1945, -180), - MACRO_OBJECT(/*preset*/ macro_breakable_box_giant, /*yaw*/ 0, /*pos*/ -370, -1945, -180), - MACRO_OBJECT(/*preset*/ macro_breakable_box_giant, /*yaw*/ 0, /*pos*/ 100, -1791, -1500), - MACRO_OBJECT(/*preset*/ macro_breakable_box_giant, /*yaw*/ 0, /*pos*/ 1820, -1407, 1020), - MACRO_OBJECT(/*preset*/ macro_breakable_box_giant, /*yaw*/ 0, /*pos*/ -780, -2175, 2810), - MACRO_OBJECT(/*preset*/ macro_coin_line_horizontal, /*yaw*/ 90, /*pos*/ 100, -1791, -2100), - MACRO_OBJECT(/*preset*/ macro_coin_line_horizontal, /*yaw*/ 0, /*pos*/ -770, -320, 2820), - MACRO_OBJECT(/*preset*/ macro_box_1up_running_away, /*yaw*/ 0, /*pos*/ 1655, -2160, -1293), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -3720, -1131, 520), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -2930, -850, 2560), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 100, -1771, -1500), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 1820, -1387, 1020), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -370, -1795, -180), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -1180, -1795, -180), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -780, -2155, 2860), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -780, -1020, 3400), + MACRO_OBJECT (/*preset*/ macro_coin_ring_horizontal_flying, /*yaw*/ 0, /*pos*/ -772, -2320, 772), + MACRO_OBJECT (/*preset*/ macro_hidden_1up_trigger, /*yaw*/ 0, /*pos*/ -524, -2560, 524), + MACRO_OBJECT (/*preset*/ macro_hidden_1up_trigger, /*yaw*/ 0, /*pos*/ -1034, -2560, 524), + MACRO_OBJECT (/*preset*/ macro_hidden_1up_trigger, /*yaw*/ 0, /*pos*/ -1034, -2560, 1034), + MACRO_OBJECT (/*preset*/ macro_hidden_1up_trigger, /*yaw*/ 0, /*pos*/ -524, -2560, 1034), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_hidden_1up, /*yaw*/ 0, /*pos*/ -772, -2180, 772, /*bhvParam*/ 4), + MACRO_OBJECT (/*preset*/ macro_breakable_box_no_coins, /*yaw*/ 0, /*pos*/ -870, -300, 870), + MACRO_OBJECT (/*preset*/ macro_breakable_box_no_coins, /*yaw*/ 0, /*pos*/ -670, -300, 870), + MACRO_OBJECT (/*preset*/ macro_breakable_box_no_coins, /*yaw*/ 0, /*pos*/ -670, -300, 670), + MACRO_OBJECT (/*preset*/ macro_breakable_box_no_coins, /*yaw*/ 0, /*pos*/ -870, -300, 670), + MACRO_OBJECT (/*preset*/ macro_box_metal_cap, /*yaw*/ 0, /*pos*/ -770, 80, 770), + MACRO_OBJECT (/*preset*/ macro_box_vanish_cap, /*yaw*/ 0, /*pos*/ -1779, -2240, 3644), + MACRO_OBJECT (/*preset*/ macro_coin_line_horizontal, /*yaw*/ 0, /*pos*/ 1089, -1279, 968), + MACRO_OBJECT (/*preset*/ macro_skeeter, /*yaw*/ 0, /*pos*/ -1240, -520, 540), + MACRO_OBJECT (/*preset*/ macro_skeeter, /*yaw*/ 0, /*pos*/ -260, -620, 1560), + MACRO_OBJECT (/*preset*/ macro_floor_switch_hidden_objects, /*yaw*/ 0, /*pos*/ -1520, -2516, -1940), + MACRO_OBJECT (/*preset*/ macro_hidden_breakable_box, /*yaw*/ 0, /*pos*/ 2200, -2559, 3240), + MACRO_OBJECT (/*preset*/ macro_box_vanish_cap, /*yaw*/ 0, /*pos*/ 1300, -2260, 3740), + MACRO_OBJECT (/*preset*/ macro_fire_spitter, /*yaw*/ 0, /*pos*/ -2060, -1580, -1260), + MACRO_OBJECT (/*preset*/ macro_fire_spitter, /*yaw*/ 0, /*pos*/ 2240, -1420, 2140), + MACRO_OBJECT (/*preset*/ macro_fire_spitter, /*yaw*/ 0, /*pos*/ 2280, -1400, -100), + MACRO_OBJECT (/*preset*/ macro_fire_spitter, /*yaw*/ 0, /*pos*/ -2280, -2520, -740), + MACRO_OBJECT (/*preset*/ macro_fire_spitter, /*yaw*/ 0, /*pos*/ 720, -2520, -740), + MACRO_OBJECT (/*preset*/ macro_breakable_box_giant, /*yaw*/ 0, /*pos*/ -2930, -1000, 2560), + MACRO_OBJECT (/*preset*/ macro_breakable_box_giant, /*yaw*/ 0, /*pos*/ -3690, -1151, 520), + MACRO_OBJECT (/*preset*/ macro_breakable_box_giant, /*yaw*/ 0, /*pos*/ -1180, -1945, -180), + MACRO_OBJECT (/*preset*/ macro_breakable_box_giant, /*yaw*/ 0, /*pos*/ -370, -1945, -180), + MACRO_OBJECT (/*preset*/ macro_breakable_box_giant, /*yaw*/ 0, /*pos*/ 100, -1791, -1500), + MACRO_OBJECT (/*preset*/ macro_breakable_box_giant, /*yaw*/ 0, /*pos*/ 1820, -1407, 1020), + MACRO_OBJECT (/*preset*/ macro_breakable_box_giant, /*yaw*/ 0, /*pos*/ -780, -2175, 2810), + MACRO_OBJECT (/*preset*/ macro_coin_line_horizontal, /*yaw*/ 90, /*pos*/ 100, -1791, -2100), + MACRO_OBJECT (/*preset*/ macro_coin_line_horizontal, /*yaw*/ 0, /*pos*/ -770, -320, 2820), + MACRO_OBJECT (/*preset*/ macro_box_1up_running_away, /*yaw*/ 0, /*pos*/ 1655, -2160, -1293), MACRO_OBJECT_END(), }; diff --git a/levels/wdw/arrow_lift/geo.inc.c b/levels/wdw/arrow_lift/geo.inc.c index de233a88..c320e014 100644 --- a/levels/wdw/arrow_lift/geo.inc.c +++ b/levels/wdw/arrow_lift/geo.inc.c @@ -1,11 +1,11 @@ // 0x0E000598 const GeoLayout wdw_geo_000598[] = { - GEO_CULLING_RADIUS(350), - GEO_OPEN_NODE(), - GEO_SHADOW(SHADOW_SQUARE_TOGGLABLE, 0x96, 110), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, wdw_seg7_dl_07012E88), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(350), + GEO_OPEN_NODE(), + GEO_SHADOW(SHADOW_SQUARE_TOGGLABLE, 0x96, 110), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, wdw_seg7_dl_07012E88), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/wdw/express_elevator/geo.inc.c b/levels/wdw/express_elevator/geo.inc.c index 80ba3e40..24c5807d 100644 --- a/levels/wdw/express_elevator/geo.inc.c +++ b/levels/wdw/express_elevator/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000610 const GeoLayout wdw_geo_000610[] = { - GEO_CULLING_RADIUS(800), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, wdw_seg7_dl_07013B70), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(800), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, wdw_seg7_dl_07013B70), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/wdw/hidden_platform/geo.inc.c b/levels/wdw/hidden_platform/geo.inc.c index b46309a4..ffddd926 100644 --- a/levels/wdw/hidden_platform/geo.inc.c +++ b/levels/wdw/hidden_platform/geo.inc.c @@ -1,11 +1,11 @@ // 0x0E0005E8 const GeoLayout wdw_geo_0005E8[] = { - GEO_CULLING_RADIUS(420), - GEO_OPEN_NODE(), - GEO_SHADOW(SHADOW_SQUARE_TOGGLABLE, 0x96, 240), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, wdw_seg7_dl_07013490), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(420), + GEO_OPEN_NODE(), + GEO_SHADOW(SHADOW_SQUARE_TOGGLABLE, 0x96, 240), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, wdw_seg7_dl_07013490), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/wdw/level.yaml b/levels/wdw/level.yaml index e8cd566b..67193e81 100644 --- a/levels/wdw/level.yaml +++ b/levels/wdw/level.yaml @@ -1,6 +1,6 @@ -# Wet Dry World +# Wet-Dry World short-name: wdw -full-name: Wet Dry World +full-name: Wet-Dry World texture-file: ["/texture.inc.c"] area-count: 2 objects: [arrow_lift, double_arrows, express_elevator, hidden_platform, rectangular_floating_platform, rotating_platform, square_floating_platform, water_level_diamond] diff --git a/levels/wdw/leveldata.c b/levels/wdw/leveldata.c index 6eba89e8..ecedd3c5 100644 --- a/levels/wdw/leveldata.c +++ b/levels/wdw/leveldata.c @@ -3,8 +3,8 @@ #include "surface_terrains.h" #include "moving_texture_macros.h" #include "level_misc_macros.h" -#include "macro_preset_names.h" -#include "special_preset_names.h" +#include "macro_presets.h" +#include "special_presets.h" #include "textures.h" #include "dialog_ids.h" diff --git a/levels/wdw/rectangular_floating_platform/geo.inc.c b/levels/wdw/rectangular_floating_platform/geo.inc.c index 374faa7d..e62a182e 100644 --- a/levels/wdw/rectangular_floating_platform/geo.inc.c +++ b/levels/wdw/rectangular_floating_platform/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000628 const GeoLayout wdw_geo_000628[] = { - GEO_CULLING_RADIUS(900), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, wdw_seg7_dl_07013E40), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(900), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, wdw_seg7_dl_07013E40), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/wdw/rotating_platform/geo.inc.c b/levels/wdw/rotating_platform/geo.inc.c index c6298d14..fd20a1c4 100644 --- a/levels/wdw/rotating_platform/geo.inc.c +++ b/levels/wdw/rotating_platform/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000640 const GeoLayout wdw_geo_000640[] = { - GEO_CULLING_RADIUS(450), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, wdw_seg7_dl_070140E0), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(450), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, wdw_seg7_dl_070140E0), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/wdw/script.c b/levels/wdw/script.c index 0c4b5980..6d71cf27 100644 --- a/levels/wdw/script.c +++ b/levels/wdw/script.c @@ -16,70 +16,70 @@ #include "levels/wdw/header.h" static const LevelScript script_func_local_1[] = { - OBJECT(/*model*/ MODEL_WDW_SQUARE_FLOATING_PLATFORM, /*pos*/ 3390, 0, 384, /*angle*/ 0, 180, 0, /*behParam*/ 0x00000000, /*beh*/ bhvWdwSquareFloatingPlatform), - OBJECT(/*model*/ MODEL_WDW_SQUARE_FLOATING_PLATFORM, /*pos*/ -767, 384, 3584, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvWdwSquareFloatingPlatform), - OBJECT(/*model*/ MODEL_WDW_SQUARE_FLOATING_PLATFORM, /*pos*/ -767, 384, 1536, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvWdwSquareFloatingPlatform), - OBJECT(/*model*/ MODEL_WDW_SQUARE_FLOATING_PLATFORM, /*pos*/ -767, 2304, -1279, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvWdwSquareFloatingPlatform), - OBJECT(/*model*/ MODEL_WDW_ARROW_LIFT, /*pos*/ -578, 2177, 3009, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvArrowLift), - OBJECT(/*model*/ MODEL_WDW_ARROW_LIFT, /*pos*/ -1474, 2177, 3393, /*angle*/ 0, 270, 0, /*behParam*/ 0x00000000, /*beh*/ bhvArrowLift), - OBJECT(/*model*/ MODEL_WDW_ARROW_LIFT, /*pos*/ -1602, 2177, 3009, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvArrowLift), - OBJECT(/*model*/ MODEL_WDW_ARROW_LIFT, /*pos*/ -1090, 2177, 3521, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvArrowLift), - OBJECT(/*model*/ MODEL_WDW_ARROW_LIFT, /*pos*/ -962, 2177, 3137, /*angle*/ 0, 90, 0, /*behParam*/ 0x00000000, /*beh*/ bhvArrowLift), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 0, 0, 0, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvInitializeChangingWaterLevel), - OBJECT(/*model*/ MODEL_WDW_WATER_LEVEL_DIAMOND, /*pos*/ 1920, 2560, -3583, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvWaterLevelDiamond), - OBJECT(/*model*/ MODEL_WDW_WATER_LEVEL_DIAMOND, /*pos*/ 3328, 256, 2918, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvWaterLevelDiamond), - OBJECT(/*model*/ MODEL_WDW_WATER_LEVEL_DIAMOND, /*pos*/ 2048, 1792, 2176, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvWaterLevelDiamond), - OBJECT(/*model*/ MODEL_WDW_WATER_LEVEL_DIAMOND, /*pos*/ 640, 1024, 3712, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvWaterLevelDiamond), - OBJECT(/*model*/ MODEL_WDW_WATER_LEVEL_DIAMOND, /*pos*/ 1810, 40, -3118, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvWaterLevelDiamond), - OBJECT(/*model*/ MODEL_PURPLE_SWITCH, /*pos*/ 3360, 1280, 3420, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvFloorSwitchHiddenObjects), - OBJECT(/*model*/ MODEL_WDW_HIDDEN_PLATFORM, /*pos*/ 2239, 1126, 3391, /*angle*/ 0, 0, 0, /*behParam*/ 0x00010000, /*beh*/ bhvHiddenObject), - OBJECT(/*model*/ MODEL_WDW_HIDDEN_PLATFORM, /*pos*/ 1215, 1357, 2751, /*angle*/ 0, 0, 0, /*behParam*/ 0x00010000, /*beh*/ bhvHiddenObject), - OBJECT(/*model*/ MODEL_WDW_HIDDEN_PLATFORM, /*pos*/ 1215, 1229, 3391, /*angle*/ 0, 0, 0, /*behParam*/ 0x00010000, /*beh*/ bhvHiddenObject), - OBJECT(/*model*/ MODEL_WDW_HIDDEN_PLATFORM, /*pos*/ 1599, 1101, 3391, /*angle*/ 0, 0, 0, /*behParam*/ 0x00010000, /*beh*/ bhvHiddenObject), - OBJECT(/*model*/ MODEL_WDW_HIDDEN_PLATFORM, /*pos*/ 2879, 1152, 3391, /*angle*/ 0, 0, 0, /*behParam*/ 0x00010000, /*beh*/ bhvHiddenObject), - OBJECT(/*model*/ MODEL_WDW_EXPRESS_ELEVATOR, /*pos*/ 1024, 3277, -2112, /*angle*/ 0, 0, 0, /*behParam*/ 0x00320000, /*beh*/ bhvWdwExpressElevatorPlatform), - OBJECT(/*model*/ MODEL_WDW_EXPRESS_ELEVATOR, /*pos*/ 1024, 3277, -1663, /*angle*/ 0, 0, 0, /*behParam*/ 0x00320000, /*beh*/ bhvWdwExpressElevator), - OBJECT(/*model*/ MODEL_WDW_RECTANGULAR_FLOATING_PLATFORM, /*pos*/ -767, 1152, 128, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvWdwRectangularFloatingPlatform), - OBJECT(/*model*/ MODEL_WDW_RECTANGULAR_FLOATING_PLATFORM, /*pos*/ -767, 2304, -2687, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvWdwRectangularFloatingPlatform), - OBJECT(/*model*/ MODEL_WDW_ROTATING_PLATFORM, /*pos*/ 734, 3840, 84, /*angle*/ 0, 0, 0, /*behParam*/ 0x46010000, /*beh*/ bhvRotatingPlatform), - OBJECT(/*model*/ MODEL_SKEETER, /*pos*/ 2956, 288, -468, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvSkeeter), - OBJECT(/*model*/ MODEL_SKEETER, /*pos*/ 184, 384, 621, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvSkeeter), + OBJECT(/*model*/ MODEL_WDW_SQUARE_FLOATING_PLATFORM, /*pos*/ 3390, 0, 384, /*angle*/ 0, 180, 0, /*bhvParam*/ 0, /*bhv*/ bhvWDWSquareFloatingPlatform), + OBJECT(/*model*/ MODEL_WDW_SQUARE_FLOATING_PLATFORM, /*pos*/ -767, 384, 3584, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvWDWSquareFloatingPlatform), + OBJECT(/*model*/ MODEL_WDW_SQUARE_FLOATING_PLATFORM, /*pos*/ -767, 384, 1536, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvWDWSquareFloatingPlatform), + OBJECT(/*model*/ MODEL_WDW_SQUARE_FLOATING_PLATFORM, /*pos*/ -767, 2304, -1279, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvWDWSquareFloatingPlatform), + OBJECT(/*model*/ MODEL_WDW_ARROW_LIFT, /*pos*/ -578, 2177, 3009, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvArrowLift), + OBJECT(/*model*/ MODEL_WDW_ARROW_LIFT, /*pos*/ -1474, 2177, 3393, /*angle*/ 0, 270, 0, /*bhvParam*/ 0, /*bhv*/ bhvArrowLift), + OBJECT(/*model*/ MODEL_WDW_ARROW_LIFT, /*pos*/ -1602, 2177, 3009, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvArrowLift), + OBJECT(/*model*/ MODEL_WDW_ARROW_LIFT, /*pos*/ -1090, 2177, 3521, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvArrowLift), + OBJECT(/*model*/ MODEL_WDW_ARROW_LIFT, /*pos*/ -962, 2177, 3137, /*angle*/ 0, 90, 0, /*bhvParam*/ 0, /*bhv*/ bhvArrowLift), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 0, 0, 0, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvInitializeChangingWaterLevel), + OBJECT(/*model*/ MODEL_WDW_WATER_LEVEL_DIAMOND, /*pos*/ 1920, 2560, -3583, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvWaterLevelDiamond), + OBJECT(/*model*/ MODEL_WDW_WATER_LEVEL_DIAMOND, /*pos*/ 3328, 256, 2918, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvWaterLevelDiamond), + OBJECT(/*model*/ MODEL_WDW_WATER_LEVEL_DIAMOND, /*pos*/ 2048, 1792, 2176, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvWaterLevelDiamond), + OBJECT(/*model*/ MODEL_WDW_WATER_LEVEL_DIAMOND, /*pos*/ 640, 1024, 3712, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvWaterLevelDiamond), + OBJECT(/*model*/ MODEL_WDW_WATER_LEVEL_DIAMOND, /*pos*/ 1810, 40, -3118, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvWaterLevelDiamond), + OBJECT(/*model*/ MODEL_PURPLE_SWITCH, /*pos*/ 3360, 1280, 3420, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvFloorSwitchHiddenObjects), + OBJECT(/*model*/ MODEL_WDW_HIDDEN_PLATFORM, /*pos*/ 2239, 1126, 3391, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(HIDDEN_OBJECT_BP_WDW_PLATFORM), /*bhv*/ bhvHiddenObject), + OBJECT(/*model*/ MODEL_WDW_HIDDEN_PLATFORM, /*pos*/ 1215, 1357, 2751, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(HIDDEN_OBJECT_BP_WDW_PLATFORM), /*bhv*/ bhvHiddenObject), + OBJECT(/*model*/ MODEL_WDW_HIDDEN_PLATFORM, /*pos*/ 1215, 1229, 3391, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(HIDDEN_OBJECT_BP_WDW_PLATFORM), /*bhv*/ bhvHiddenObject), + OBJECT(/*model*/ MODEL_WDW_HIDDEN_PLATFORM, /*pos*/ 1599, 1101, 3391, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(HIDDEN_OBJECT_BP_WDW_PLATFORM), /*bhv*/ bhvHiddenObject), + OBJECT(/*model*/ MODEL_WDW_HIDDEN_PLATFORM, /*pos*/ 2879, 1152, 3391, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(HIDDEN_OBJECT_BP_WDW_PLATFORM), /*bhv*/ bhvHiddenObject), + OBJECT(/*model*/ MODEL_WDW_EXPRESS_ELEVATOR, /*pos*/ 1024, 3277, -2112, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(0x32), /*bhv*/ bhvWDWExpressElevatorPlatform), + OBJECT(/*model*/ MODEL_WDW_EXPRESS_ELEVATOR, /*pos*/ 1024, 3277, -1663, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(0x32), /*bhv*/ bhvWDWExpressElevator), + OBJECT(/*model*/ MODEL_WDW_RECTANGULAR_FLOATING_PLATFORM, /*pos*/ -767, 1152, 128, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvWDWRectangularFloatingPlatform), + OBJECT(/*model*/ MODEL_WDW_RECTANGULAR_FLOATING_PLATFORM, /*pos*/ -767, 2304, -2687, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvWDWRectangularFloatingPlatform), + OBJECT(/*model*/ MODEL_WDW_ROTATING_PLATFORM, /*pos*/ 734, 3840, 84, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(0x46) | BPARAM2(ROTATING_PLATFORM_BP_WDW), /*bhv*/ bhvRotatingPlatform), + OBJECT(/*model*/ MODEL_SKEETER, /*pos*/ 2956, 288, -468, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvSkeeter), + OBJECT(/*model*/ MODEL_SKEETER, /*pos*/ 184, 384, 621, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvSkeeter), RETURN(), }; static const LevelScript script_func_local_2[] = { - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 0, 0, 0, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvInitializeChangingWaterLevel), - OBJECT(/*model*/ MODEL_WDW_WATER_LEVEL_DIAMOND, /*pos*/ -3583, -2508, -2047, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvWaterLevelDiamond), - OBJECT(/*model*/ MODEL_WDW_WATER_LEVEL_DIAMOND, /*pos*/ -767, -127, 1792, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvWaterLevelDiamond), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -768, -665, 3584, /*angle*/ 0, 0, 0, /*behParam*/ 0x005C0000, /*beh*/ bhvPoleGrabbing), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 0, 0, 0, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvInitializeChangingWaterLevel), + OBJECT(/*model*/ MODEL_WDW_WATER_LEVEL_DIAMOND, /*pos*/ -3583, -2508, -2047, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvWaterLevelDiamond), + OBJECT(/*model*/ MODEL_WDW_WATER_LEVEL_DIAMOND, /*pos*/ -767, -127, 1792, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvWaterLevelDiamond), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ -768, -665, 3584, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(92), /*bhv*/ bhvPoleGrabbing), RETURN(), }; static const LevelScript script_func_local_3[] = { - OBJECT_WITH_ACTS(/*model*/ MODEL_NONE, /*pos*/ 3360, 1580, 2660, /*angle*/ 0, 0, 0, /*behParam*/ 0x02000000, /*beh*/ bhvHiddenStar, /*acts*/ ALL_ACTS), - OBJECT_WITH_ACTS(/*model*/ MODEL_STAR, /*pos*/ 890, 3400, -2040, /*angle*/ 0, 0, 0, /*behParam*/ 0x03000000, /*beh*/ bhvStar, /*acts*/ ALL_ACTS), + OBJECT_WITH_ACTS(/*model*/ MODEL_NONE, /*pos*/ 3360, 1580, 2660, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(STAR_INDEX_ACT_3), /*bhv*/ bhvHiddenStar, /*acts*/ ALL_ACTS), + OBJECT_WITH_ACTS(/*model*/ MODEL_STAR, /*pos*/ 890, 3400, -2040, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(STAR_INDEX_ACT_4), /*bhv*/ bhvStar, /*acts*/ ALL_ACTS), RETURN(), }; static const LevelScript script_func_local_4[] = { - OBJECT_WITH_ACTS(/*model*/ MODEL_NONE, /*pos*/ -770, -1600, 3600, /*angle*/ 0, 0, 0, /*behParam*/ 0x04000000, /*beh*/ bhvHiddenRedCoinStar, /*acts*/ ALL_ACTS), - OBJECT_WITH_ACTS(/*model*/ MODEL_STAR, /*pos*/ 2180, -840, 3720, /*angle*/ 0, 0, 0, /*behParam*/ 0x05000000, /*beh*/ bhvStar, /*acts*/ ALL_ACTS), + OBJECT_WITH_ACTS(/*model*/ MODEL_NONE, /*pos*/ -770, -1600, 3600, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(STAR_INDEX_ACT_5), /*bhv*/ bhvHiddenRedCoinStar, /*acts*/ ALL_ACTS), + OBJECT_WITH_ACTS(/*model*/ MODEL_STAR, /*pos*/ 2180, -840, 3720, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(STAR_INDEX_ACT_6), /*bhv*/ bhvStar, /*acts*/ ALL_ACTS), RETURN(), }; const LevelScript level_wdw_entry[] = { INIT_LEVEL(), - LOAD_MIO0( /*seg*/ 0x07, _wdw_segment_7SegmentRomStart, _wdw_segment_7SegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x07, _wdw_segment_7SegmentRomStart, _wdw_segment_7SegmentRomEnd), LOAD_MIO0_TEXTURE(/*seg*/ 0x09, _grass_mio0SegmentRomStart, _grass_mio0SegmentRomEnd), - LOAD_MIO0( /*seg*/ 0x0A, _wdw_skybox_mio0SegmentRomStart, _wdw_skybox_mio0SegmentRomEnd), - LOAD_MIO0( /*seg*/ 0x05, _group1_mio0SegmentRomStart, _group1_mio0SegmentRomEnd), - LOAD_RAW( /*seg*/ 0x0C, _group1_geoSegmentRomStart, _group1_geoSegmentRomEnd), - LOAD_MIO0( /*seg*/ 0x06, _group13_mio0SegmentRomStart, _group13_mio0SegmentRomEnd), - LOAD_RAW( /*seg*/ 0x0D, _group13_geoSegmentRomStart, _group13_geoSegmentRomEnd), - LOAD_MIO0( /*seg*/ 0x08, _common0_mio0SegmentRomStart, _common0_mio0SegmentRomEnd), - LOAD_RAW( /*seg*/ 0x0F, _common0_geoSegmentRomStart, _common0_geoSegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x0A, _wdw_skybox_mio0SegmentRomStart, _wdw_skybox_mio0SegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x05, _group1_mio0SegmentRomStart, _group1_mio0SegmentRomEnd), + LOAD_RAW (/*seg*/ 0x0C, _group1_geoSegmentRomStart, _group1_geoSegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x06, _group13_mio0SegmentRomStart, _group13_mio0SegmentRomEnd), + LOAD_RAW (/*seg*/ 0x0D, _group13_geoSegmentRomStart, _group13_geoSegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x08, _common0_mio0SegmentRomStart, _common0_mio0SegmentRomEnd), + LOAD_RAW (/*seg*/ 0x0F, _common0_geoSegmentRomStart, _common0_geoSegmentRomEnd), ALLOC_LEVEL_POOL(), - MARIO(/*model*/ MODEL_MARIO, /*behParam*/ 0x00000001, /*beh*/ bhvMario), + MARIO(/*model*/ MODEL_MARIO, /*bhvParam*/ BPARAM4(0x01), /*bhv*/ bhvMario), JUMP_LINK(script_func_global_1), JUMP_LINK(script_func_global_2), JUMP_LINK(script_func_global_14), @@ -93,16 +93,16 @@ const LevelScript level_wdw_entry[] = { LOAD_MODEL_FROM_GEO(MODEL_WDW_ROTATING_PLATFORM, wdw_geo_000640), AREA(/*index*/ 1, wdw_geo_000658), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 3395, 3580, 384, /*angle*/ 0, 180, 0, /*behParam*/ 0x000A0000, /*beh*/ bhvSpinAirborneWarp), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 818, 0, 3634, /*angle*/ 0, 45, 0, /*behParam*/ 0x000B0000, /*beh*/ bhvFadingWarp), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -2865, 3328, 3065, /*angle*/ 0, 0, 0, /*behParam*/ 0x000C0000, /*beh*/ bhvFadingWarp), - WARP_NODE(/*id*/ 0x0A, /*destLevel*/ LEVEL_WDW, /*destArea*/ 0x01, /*destNode*/ 0x0A, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0x0B, /*destLevel*/ LEVEL_WDW, /*destArea*/ 0x01, /*destNode*/ 0x0C, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0x0C, /*destLevel*/ LEVEL_WDW, /*destArea*/ 0x01, /*destNode*/ 0x0B, /*flags*/ WARP_NO_CHECKPOINT), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 3395, 3580, 384, /*angle*/ 0, 180, 0, /*bhvParam*/ BPARAM2(WARP_NODE_0A), /*bhv*/ bhvSpinAirborneWarp), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 818, 0, 3634, /*angle*/ 0, 45, 0, /*bhvParam*/ BPARAM2(WARP_NODE_0B), /*bhv*/ bhvFadingWarp), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ -2865, 3328, 3065, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(WARP_NODE_0C), /*bhv*/ bhvFadingWarp), + WARP_NODE(/*id*/ WARP_NODE_0A, /*destLevel*/ LEVEL_WDW, /*destArea*/ 1, /*destNode*/ WARP_NODE_0A, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_0B, /*destLevel*/ LEVEL_WDW, /*destArea*/ 1, /*destNode*/ WARP_NODE_0C, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_0C, /*destLevel*/ LEVEL_WDW, /*destArea*/ 1, /*destNode*/ WARP_NODE_0B, /*flags*/ WARP_NO_CHECKPOINT), JUMP_LINK(script_func_local_3), JUMP_LINK(script_func_local_1), - WARP_NODE(/*id*/ 0xF0, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x02, /*destNode*/ 0x32, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0xF1, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x02, /*destNode*/ 0x64, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_SUCCESS, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 2, /*destNode*/ WARP_NODE_32, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_DEATH, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 2, /*destNode*/ WARP_NODE_64, /*flags*/ WARP_NO_CHECKPOINT), INSTANT_WARP(/*index*/ 1, /*destArea*/ 2, /*displace*/ 0, 0, 0), TERRAIN(/*terrainData*/ wdw_seg7_area_1_collision), MACRO_OBJECTS(/*objList*/ wdw_seg7_area_1_macro_objs), @@ -113,8 +113,8 @@ const LevelScript level_wdw_entry[] = { AREA(/*index*/ 2, wdw_geo_000724), JUMP_LINK(script_func_local_4), JUMP_LINK(script_func_local_2), - WARP_NODE(/*id*/ 0xF0, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x02, /*destNode*/ 0x32, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0xF1, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x02, /*destNode*/ 0x64, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_SUCCESS, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 2, /*destNode*/ WARP_NODE_32, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_DEATH, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 2, /*destNode*/ WARP_NODE_64, /*flags*/ WARP_NO_CHECKPOINT), INSTANT_WARP(/*index*/ 0, /*destArea*/ 1, /*displace*/ 0, 0, 0), TERRAIN(/*terrainData*/ wdw_seg7_area_2_collision), MACRO_OBJECTS(/*objList*/ wdw_seg7_area_2_macro_objs), diff --git a/levels/wdw/square_floating_platform/geo.inc.c b/levels/wdw/square_floating_platform/geo.inc.c index 749421de..ddad87af 100644 --- a/levels/wdw/square_floating_platform/geo.inc.c +++ b/levels/wdw/square_floating_platform/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000580 const GeoLayout wdw_geo_000580[] = { - GEO_CULLING_RADIUS(550), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, wdw_seg7_dl_07012B90), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(550), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, wdw_seg7_dl_07012B90), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/wdw/water_level_diamond/geo.inc.c b/levels/wdw/water_level_diamond/geo.inc.c index 286dc1e3..53240af0 100644 --- a/levels/wdw/water_level_diamond/geo.inc.c +++ b/levels/wdw/water_level_diamond/geo.inc.c @@ -1,11 +1,11 @@ // 0x0E0005C0 const GeoLayout wdw_geo_0005C0[] = { - GEO_CULLING_RADIUS(200), - GEO_OPEN_NODE(), - GEO_SHADOW(SHADOW_SQUARE_SCALABLE, 0x96, 90), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, wdw_seg7_dl_070131B8), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(200), + GEO_OPEN_NODE(), + GEO_SHADOW(SHADOW_SQUARE_SCALABLE, 0x96, 90), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, wdw_seg7_dl_070131B8), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/wf/areas/1/10/geo.inc.c b/levels/wf/areas/1/10/geo.inc.c index 41116411..9270d767 100644 --- a/levels/wf/areas/1/10/geo.inc.c +++ b/levels/wf/areas/1/10/geo.inc.c @@ -1,15 +1,15 @@ // 0x0E0008A8 const GeoLayout wf_geo_0008A8[] = { - GEO_CULLING_RADIUS(2700), - GEO_OPEN_NODE(), - GEO_RENDER_RANGE(-2048, 5000), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, wf_seg7_dl_070087B0), - GEO_CLOSE_NODE(), - GEO_RENDER_RANGE(5000, 32767), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, wf_seg7_dl_07008FE8), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(2700), + GEO_OPEN_NODE(), + GEO_RENDER_RANGE(-2048, 5000), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, wf_seg7_dl_070087B0), + GEO_CLOSE_NODE(), + GEO_RENDER_RANGE(5000, 32767), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, wf_seg7_dl_07008FE8), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/wf/areas/1/11/geo.inc.c b/levels/wf/areas/1/11/geo.inc.c index 0cd0c73c..c20a3b55 100644 --- a/levels/wf/areas/1/11/geo.inc.c +++ b/levels/wf/areas/1/11/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E0008E8 const GeoLayout wf_geo_0008E8[] = { - GEO_CULLING_RADIUS(400), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, wf_seg7_dl_07009278), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(400), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, wf_seg7_dl_07009278), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/wf/areas/1/12/geo.inc.c b/levels/wf/areas/1/12/geo.inc.c index 52327607..d96d1e1a 100644 --- a/levels/wf/areas/1/12/geo.inc.c +++ b/levels/wf/areas/1/12/geo.inc.c @@ -1,15 +1,15 @@ // 0x0E000900 const GeoLayout wf_geo_000900[] = { - GEO_CULLING_RADIUS(1600), - GEO_OPEN_NODE(), - GEO_RENDER_RANGE(-2048, 5000), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, wf_seg7_dl_07009780), - GEO_CLOSE_NODE(), - GEO_RENDER_RANGE(5000, 32767), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, wf_seg7_dl_07009890), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(1600), + GEO_OPEN_NODE(), + GEO_RENDER_RANGE(-2048, 5000), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, wf_seg7_dl_07009780), + GEO_CLOSE_NODE(), + GEO_RENDER_RANGE(5000, 32767), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, wf_seg7_dl_07009890), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/wf/areas/1/13/geo.inc.c b/levels/wf/areas/1/13/geo.inc.c index 0bb17d18..1af86555 100644 --- a/levels/wf/areas/1/13/geo.inc.c +++ b/levels/wf/areas/1/13/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000940 const GeoLayout wf_geo_000940[] = { - GEO_CULLING_RADIUS(800), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, wf_seg7_dl_07009DB0), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(800), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, wf_seg7_dl_07009DB0), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/wf/areas/1/14/geo.inc.c b/levels/wf/areas/1/14/geo.inc.c index 9fa12d44..cea2c579 100644 --- a/levels/wf/areas/1/14/geo.inc.c +++ b/levels/wf/areas/1/14/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000AE0 const GeoLayout wf_geo_000AE0[] = { - GEO_CULLING_RADIUS(2000), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, wf_seg7_dl_0700A170), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(2000), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, wf_seg7_dl_0700A170), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/wf/areas/1/15/geo.inc.c b/levels/wf/areas/1/15/geo.inc.c index 6e73e6a8..39efeda1 100644 --- a/levels/wf/areas/1/15/geo.inc.c +++ b/levels/wf/areas/1/15/geo.inc.c @@ -1,16 +1,16 @@ // 0x0E000958 const GeoLayout wf_geo_000958[] = { - GEO_CULLING_RADIUS(2000), - GEO_OPEN_NODE(), - GEO_RENDER_RANGE(-2000, 8000), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, wf_seg7_dl_0700ABA0), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT_DECAL, wf_seg7_dl_0700AFB8), - GEO_CLOSE_NODE(), - GEO_RENDER_RANGE(8000, 20000), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, wf_seg7_dl_0700AEC8), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(2000), + GEO_OPEN_NODE(), + GEO_RENDER_RANGE(-2000, 8000), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, wf_seg7_dl_0700ABA0), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT_DECAL, wf_seg7_dl_0700AFB8), + GEO_CLOSE_NODE(), + GEO_RENDER_RANGE(8000, 20000), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, wf_seg7_dl_0700AEC8), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/wf/areas/1/16/geo.inc.c b/levels/wf/areas/1/16/geo.inc.c index 1f4289c6..a1d47f92 100644 --- a/levels/wf/areas/1/16/geo.inc.c +++ b/levels/wf/areas/1/16/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E0009A0 const GeoLayout wf_geo_0009A0[] = { - GEO_CULLING_RADIUS(3000), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, wf_seg7_dl_0700BA28), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(3000), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, wf_seg7_dl_0700BA28), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/wf/areas/1/17/geo.inc.c b/levels/wf/areas/1/17/geo.inc.c index 2db508a7..0d87429c 100644 --- a/levels/wf/areas/1/17/geo.inc.c +++ b/levels/wf/areas/1/17/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E0009B8 const GeoLayout wf_geo_0009B8[] = { - GEO_CULLING_RADIUS(1100), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, wf_seg7_dl_0700BF50), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(1100), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, wf_seg7_dl_0700BF50), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/wf/areas/1/18/geo.inc.c b/levels/wf/areas/1/18/geo.inc.c index ac1c6746..2bab8107 100644 --- a/levels/wf/areas/1/18/geo.inc.c +++ b/levels/wf/areas/1/18/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E0009D0 const GeoLayout wf_geo_0009D0[] = { - GEO_CULLING_RADIUS(1200), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, wf_seg7_dl_0700D028), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(1200), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, wf_seg7_dl_0700D028), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/wf/areas/1/19/geo.inc.c b/levels/wf/areas/1/19/geo.inc.c index a0bde516..10a02097 100644 --- a/levels/wf/areas/1/19/geo.inc.c +++ b/levels/wf/areas/1/19/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E0009E8 const GeoLayout wf_geo_0009E8[] = { - GEO_CULLING_RADIUS(2700), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, wf_seg7_dl_0700D300), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(2700), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, wf_seg7_dl_0700D300), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/wf/areas/1/5/geo.inc.c b/levels/wf/areas/1/5/geo.inc.c index 388c6b1e..1e1975f4 100644 --- a/levels/wf/areas/1/5/geo.inc.c +++ b/levels/wf/areas/1/5/geo.inc.c @@ -1,15 +1,15 @@ // 0x0E0007E0 const GeoLayout wf_geo_0007E0[] = { - GEO_CULLING_RADIUS(600), - GEO_OPEN_NODE(), - GEO_RENDER_RANGE(-2048, 5000), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, wf_seg7_dl_07005DD8), - GEO_CLOSE_NODE(), - GEO_RENDER_RANGE(5000, 32767), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, wf_seg7_dl_07005EE8), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(600), + GEO_OPEN_NODE(), + GEO_RENDER_RANGE(-2048, 5000), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, wf_seg7_dl_07005DD8), + GEO_CLOSE_NODE(), + GEO_RENDER_RANGE(5000, 32767), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, wf_seg7_dl_07005EE8), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/wf/areas/1/6/geo.inc.c b/levels/wf/areas/1/6/geo.inc.c index fe9c2133..0ab1b064 100644 --- a/levels/wf/areas/1/6/geo.inc.c +++ b/levels/wf/areas/1/6/geo.inc.c @@ -1,15 +1,15 @@ // 0x0E000820 const GeoLayout wf_geo_000820[] = { - GEO_CULLING_RADIUS(1800), - GEO_OPEN_NODE(), - GEO_RENDER_RANGE(-2048, 5000), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, wf_seg7_dl_070064E8), - GEO_CLOSE_NODE(), - GEO_RENDER_RANGE(5000, 32767), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, wf_seg7_dl_070065F8), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(1800), + GEO_OPEN_NODE(), + GEO_RENDER_RANGE(-2048, 5000), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, wf_seg7_dl_070064E8), + GEO_CLOSE_NODE(), + GEO_RENDER_RANGE(5000, 32767), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, wf_seg7_dl_070065F8), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/wf/areas/1/7/geo.inc.c b/levels/wf/areas/1/7/geo.inc.c index 4c06e63b..5fe433af 100644 --- a/levels/wf/areas/1/7/geo.inc.c +++ b/levels/wf/areas/1/7/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000860 const GeoLayout wf_geo_000860[] = { - GEO_CULLING_RADIUS(1400), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, wf_seg7_dl_07006820), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(1400), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, wf_seg7_dl_07006820), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/wf/areas/1/8/geo.inc.c b/levels/wf/areas/1/8/geo.inc.c index d3b05de9..5cb7b18a 100644 --- a/levels/wf/areas/1/8/geo.inc.c +++ b/levels/wf/areas/1/8/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000878 const GeoLayout wf_geo_000878[] = { - GEO_CULLING_RADIUS(9000), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_ALPHA, wf_seg7_dl_07007220), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(9000), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_ALPHA, wf_seg7_dl_07007220), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/wf/areas/1/9/geo.inc.c b/levels/wf/areas/1/9/geo.inc.c index 74a12515..2768146e 100644 --- a/levels/wf/areas/1/9/geo.inc.c +++ b/levels/wf/areas/1/9/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000890 const GeoLayout wf_geo_000890[] = { - GEO_CULLING_RADIUS(1000), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, wf_seg7_dl_07007518), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(1000), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, wf_seg7_dl_07007518), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/wf/areas/1/geo.inc.c b/levels/wf/areas/1/geo.inc.c index b1c794ab..d0df37fd 100644 --- a/levels/wf/areas/1/geo.inc.c +++ b/levels/wf/areas/1/geo.inc.c @@ -1,35 +1,35 @@ // 0x0E000BF8 const GeoLayout wf_geo_000BF8[] = { - GEO_NODE_SCREEN_AREA(10, SCREEN_WIDTH/2, SCREEN_HEIGHT/2, SCREEN_WIDTH/2, SCREEN_HEIGHT/2), - GEO_OPEN_NODE(), - GEO_ZBUFFER(0), - GEO_OPEN_NODE(), - GEO_NODE_ORTHO(100), - GEO_OPEN_NODE(), - GEO_BACKGROUND(BACKGROUND_BELOW_CLOUDS, geo_skybox_main), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ZBUFFER(1), - GEO_OPEN_NODE(), - GEO_CAMERA_FRUSTUM_WITH_FUNC(45, 100, 12800, geo_camera_fov), - GEO_OPEN_NODE(), - GEO_CAMERA(1, 0, 2000, 6000, 0, 2000, 0, geo_camera_main), + GEO_NODE_SCREEN_AREA(10, SCREEN_WIDTH/2, SCREEN_HEIGHT/2, SCREEN_WIDTH/2, SCREEN_HEIGHT/2), + GEO_OPEN_NODE(), + GEO_ZBUFFER(0), + GEO_OPEN_NODE(), + GEO_NODE_ORTHO(100), GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, wf_seg7_dl_070050C8), - GEO_DISPLAY_LIST(LAYER_OPAQUE_DECAL, wf_seg7_dl_070052B8), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT_DECAL, wf_seg7_dl_07005538), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, wf_seg7_dl_07005690), - GEO_RENDER_OBJ(), - GEO_ASM( 0, geo_movtex_pause_control), - GEO_ASM(0x2401, geo_movtex_draw_water_regions), - GEO_ASM( 0, geo_envfx_main), + GEO_BACKGROUND(BACKGROUND_BELOW_CLOUDS, geo_skybox_main), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ZBUFFER(0), - GEO_OPEN_NODE(), - GEO_ASM(0, geo_cannon_circle_base), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CLOSE_NODE(), + GEO_ZBUFFER(1), + GEO_OPEN_NODE(), + GEO_CAMERA_FRUSTUM_WITH_FUNC(45, 100, 12800, geo_camera_fov), + GEO_OPEN_NODE(), + GEO_CAMERA(1, 0, 2000, 6000, 0, 2000, 0, geo_camera_main), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, wf_seg7_dl_070050C8), + GEO_DISPLAY_LIST(LAYER_OPAQUE_DECAL, wf_seg7_dl_070052B8), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT_DECAL, wf_seg7_dl_07005538), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, wf_seg7_dl_07005690), + GEO_RENDER_OBJ(), + GEO_ASM( 0, geo_movtex_pause_control), + GEO_ASM(0x2401, geo_movtex_draw_water_regions), + GEO_ASM( 0, geo_envfx_main), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ZBUFFER(0), + GEO_OPEN_NODE(), + GEO_ASM(0, geo_cannon_circle_base), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/wf/areas/1/macro.inc.c b/levels/wf/areas/1/macro.inc.c index ee3d2c05..7852e24b 100644 --- a/levels/wf/areas/1/macro.inc.c +++ b/levels/wf/areas/1/macro.inc.c @@ -1,47 +1,47 @@ // 0x07011C38 - 0x07011DE8 const MacroObject wf_seg7_macro_objs[] = { - MACRO_OBJECT(/*preset*/ macro_coin_line_horizontal, /*yaw*/ 0, /*pos*/ 3760, 960, 2740), - MACRO_OBJECT(/*preset*/ macro_coin_line_horizontal, /*yaw*/ 90, /*pos*/ -1400, 1160, 3900), - MACRO_OBJECT(/*preset*/ macro_coin_line_horizontal, /*yaw*/ 90, /*pos*/ 1254, 2586, 2299), - MACRO_OBJECT(/*preset*/ macro_coin_ring_horizontal, /*yaw*/ 0, /*pos*/ -2500, 1795, -260), - MACRO_OBJECT(/*preset*/ macro_blue_coin_switch, /*yaw*/ 0, /*pos*/ -2500, 384, -250), - MACRO_OBJECT(/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ -2500, 450, -1150), - MACRO_OBJECT(/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ -2500, 450, -900), - MACRO_OBJECT(/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ -2500, 450, -650), - MACRO_OBJECT(/*preset*/ macro_box_metal_cap, /*yaw*/ 0, /*pos*/ 2750, 1370, -3400), - MACRO_OBJECT(/*preset*/ macro_yellow_coin, /*yaw*/ 0, /*pos*/ 0, 2650, 2900), - MACRO_OBJECT(/*preset*/ macro_yellow_coin, /*yaw*/ 0, /*pos*/ -500, 2650, 2900), - MACRO_OBJECT(/*preset*/ macro_yellow_coin, /*yaw*/ 0, /*pos*/ 250, 2650, 2800), - MACRO_OBJECT(/*preset*/ macro_yellow_coin, /*yaw*/ 0, /*pos*/ -750, 2650, 2800), - MACRO_OBJECT(/*preset*/ macro_hidden_1up_in_pole, /*yaw*/ 0, /*pos*/ -2500, 4560, -256), - MACRO_OBJECT(/*preset*/ macro_hidden_1up_trigger, /*yaw*/ 0, /*pos*/ 0, 2650, 2900), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_hidden_1up, /*yaw*/ 0, /*pos*/ -250, 2650, 2400, /*behParam*/ 2), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 315, /*pos*/ 4200, 256, 5160, /*behParam*/ DIALOG_018), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 0, /*pos*/ -2540, 2560, -900, /*behParam*/ DIALOG_036), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 90, /*pos*/ 1600, 2560, 2600, /*behParam*/ DIALOG_042), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 270, /*pos*/ -2705, 2560, 59, /*behParam*/ DIALOG_051), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 180, /*pos*/ 3460, 2304, -40, /*behParam*/ DIALOG_096), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_cannon_closed, /*yaw*/ 0, /*pos*/ -1844, 1026, 3893, /*behParam*/ 0x40), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 270, /*pos*/ -2932, 386, -157, /*behParam*/ DIALOG_078), - MACRO_OBJECT(/*preset*/ macro_hidden_1up_trigger, /*yaw*/ 0, /*pos*/ -500, 2650, 2900), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -250, 2650, 2970), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 1746, 3620, -3120), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 1277, 2600, 1350), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 1585, 2595, -80), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 3350, 3000, -1520), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 2700, 3600, -900), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 3770, 1380, 650), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -270, 1720, 2250), - MACRO_OBJECT(/*preset*/ macro_coin_arrow, /*yaw*/ 135, /*pos*/ 1215, 3600, -2609), - MACRO_OBJECT(/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ -2500, 450, -1400), - MACRO_OBJECT(/*preset*/ macro_coin_ring_horizontal, /*yaw*/ 0, /*pos*/ 4611, 256, 141), - MACRO_OBJECT(/*preset*/ macro_coin_ring_horizontal, /*yaw*/ 0, /*pos*/ 1558, 922, 2329), - MACRO_OBJECT(/*preset*/ macro_coin_line_horizontal, /*yaw*/ 0, /*pos*/ 3396, 1380, 3280), - MACRO_OBJECT(/*preset*/ macro_coin_ring_horizontal_flying, /*yaw*/ 0, /*pos*/ 3234, 3345, -1787), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 0, /*pos*/ 4800, 256, 3000, /*behParam*/ DIALOG_104), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 90, /*pos*/ 2930, 1075, -3740, /*behParam*/ DIALOG_113), - MACRO_OBJECT(/*preset*/ macro_breakable_box_small, /*yaw*/ 0, /*pos*/ 4320, 256, 1880), - MACRO_OBJECT(/*preset*/ macro_breakable_box_small, /*yaw*/ 0, /*pos*/ -2940, 384, -1320), - MACRO_OBJECT(/*preset*/ macro_butterfly_triplet_2, /*yaw*/ 0, /*pos*/ 4574, 300, 1130), + MACRO_OBJECT (/*preset*/ macro_coin_line_horizontal, /*yaw*/ 0, /*pos*/ 3760, 960, 2740), + MACRO_OBJECT (/*preset*/ macro_coin_line_horizontal, /*yaw*/ 90, /*pos*/ -1400, 1160, 3900), + MACRO_OBJECT (/*preset*/ macro_coin_line_horizontal, /*yaw*/ 90, /*pos*/ 1254, 2586, 2299), + MACRO_OBJECT (/*preset*/ macro_coin_ring_horizontal, /*yaw*/ 0, /*pos*/ -2500, 1795, -260), + MACRO_OBJECT (/*preset*/ macro_blue_coin_switch, /*yaw*/ 0, /*pos*/ -2500, 384, -250), + MACRO_OBJECT (/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ -2500, 450, -1150), + MACRO_OBJECT (/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ -2500, 450, -900), + MACRO_OBJECT (/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ -2500, 450, -650), + MACRO_OBJECT (/*preset*/ macro_box_metal_cap, /*yaw*/ 0, /*pos*/ 2750, 1370, -3400), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_1, /*yaw*/ 0, /*pos*/ 0, 2650, 2900), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_1, /*yaw*/ 0, /*pos*/ -500, 2650, 2900), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_1, /*yaw*/ 0, /*pos*/ 250, 2650, 2800), + MACRO_OBJECT (/*preset*/ macro_yellow_coin_1, /*yaw*/ 0, /*pos*/ -750, 2650, 2800), + MACRO_OBJECT (/*preset*/ macro_hidden_1up_in_pole, /*yaw*/ 0, /*pos*/ -2500, 4560, -256), + MACRO_OBJECT (/*preset*/ macro_hidden_1up_trigger, /*yaw*/ 0, /*pos*/ 0, 2650, 2900), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_hidden_1up, /*yaw*/ 0, /*pos*/ -250, 2650, 2400, /*bhvParam*/ 2), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 315, /*pos*/ 4200, 256, 5160, /*bhvParam*/ DIALOG_018), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 0, /*pos*/ -2540, 2560, -900, /*bhvParam*/ DIALOG_036), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 90, /*pos*/ 1600, 2560, 2600, /*bhvParam*/ DIALOG_042), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 270, /*pos*/ -2705, 2560, 59, /*bhvParam*/ DIALOG_051), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 180, /*pos*/ 3460, 2304, -40, /*bhvParam*/ DIALOG_096), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_cannon_closed, /*yaw*/ 0, /*pos*/ -1844, 1026, 3893, /*bhvParam*/ 0x40), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 270, /*pos*/ -2932, 386, -157, /*bhvParam*/ DIALOG_078), + MACRO_OBJECT (/*preset*/ macro_hidden_1up_trigger, /*yaw*/ 0, /*pos*/ -500, 2650, 2900), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -250, 2650, 2970), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 1746, 3620, -3120), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 1277, 2600, 1350), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 1585, 2595, -80), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 3350, 3000, -1520), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 2700, 3600, -900), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 3770, 1380, 650), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -270, 1720, 2250), + MACRO_OBJECT (/*preset*/ macro_coin_arrow, /*yaw*/ 135, /*pos*/ 1215, 3600, -2609), + MACRO_OBJECT (/*preset*/ macro_hidden_blue_coin, /*yaw*/ 0, /*pos*/ -2500, 450, -1400), + MACRO_OBJECT (/*preset*/ macro_coin_ring_horizontal, /*yaw*/ 0, /*pos*/ 4611, 256, 141), + MACRO_OBJECT (/*preset*/ macro_coin_ring_horizontal, /*yaw*/ 0, /*pos*/ 1558, 922, 2329), + MACRO_OBJECT (/*preset*/ macro_coin_line_horizontal, /*yaw*/ 0, /*pos*/ 3396, 1380, 3280), + MACRO_OBJECT (/*preset*/ macro_coin_ring_horizontal_flying, /*yaw*/ 0, /*pos*/ 3234, 3345, -1787), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 0, /*pos*/ 4800, 256, 3000, /*bhvParam*/ DIALOG_104), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_wooden_signpost, /*yaw*/ 90, /*pos*/ 2930, 1075, -3740, /*bhvParam*/ DIALOG_113), + MACRO_OBJECT (/*preset*/ macro_breakable_box_small, /*yaw*/ 0, /*pos*/ 4320, 256, 1880), + MACRO_OBJECT (/*preset*/ macro_breakable_box_small, /*yaw*/ 0, /*pos*/ -2940, 384, -1320), + MACRO_OBJECT (/*preset*/ macro_butterfly_triplet_no_bombs, /*yaw*/ 0, /*pos*/ 4574, 300, 1130), MACRO_OBJECT_END(), }; diff --git a/levels/wf/beta_extending_platform/geo.inc.c b/levels/wf/beta_extending_platform/geo.inc.c index 7da09eab..53a9a498 100644 --- a/levels/wf/beta_extending_platform/geo.inc.c +++ b/levels/wf/beta_extending_platform/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000AF8 const GeoLayout wf_geo_000AF8[] = { - GEO_CULLING_RADIUS(650), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, wf_seg7_dl_0700EDC0), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(650), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, wf_seg7_dl_0700EDC0), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/wf/breakable_wall_left/geo.inc.c b/levels/wf/breakable_wall_left/geo.inc.c index 71cdd216..8e459f8a 100644 --- a/levels/wf/breakable_wall_left/geo.inc.c +++ b/levels/wf/breakable_wall_left/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000B90 const GeoLayout wf_geo_000B90[] = { - GEO_CULLING_RADIUS(690), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, wf_seg7_dl_0700F340), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(690), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, wf_seg7_dl_0700F340), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/wf/breakable_wall_right/geo.inc.c b/levels/wf/breakable_wall_right/geo.inc.c index aa16c3fa..646926c9 100644 --- a/levels/wf/breakable_wall_right/geo.inc.c +++ b/levels/wf/breakable_wall_right/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000B78 const GeoLayout wf_geo_000B78[] = { - GEO_CULLING_RADIUS(750), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, wf_seg7_dl_0700F1A8), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(750), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, wf_seg7_dl_0700F1A8), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/wf/extending_platform/geo.inc.c b/levels/wf/extending_platform/geo.inc.c index 803a9d34..80dcdf00 100644 --- a/levels/wf/extending_platform/geo.inc.c +++ b/levels/wf/extending_platform/geo.inc.c @@ -1,32 +1,32 @@ // 0x0E000B10 const GeoLayout wf_geo_000B10[] = { - GEO_CULLING_RADIUS(650), - GEO_OPEN_NODE(), - GEO_SHADOW(SHADOW_SQUARE_PERMANENT, 0x96, 420), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, wf_seg7_dl_0700F018), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(650), + GEO_OPEN_NODE(), + GEO_SHADOW(SHADOW_SQUARE_PERMANENT, 0x96, 420), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, wf_seg7_dl_0700F018), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; // 0x0E000B38 const GeoLayout wf_geo_000B38[] = { - GEO_CULLING_RADIUS(650), - GEO_OPEN_NODE(), - GEO_SHADOW(SHADOW_SQUARE_PERMANENT, 0x96, 420), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, wf_seg7_dl_0700F018), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(650), + GEO_OPEN_NODE(), + GEO_SHADOW(SHADOW_SQUARE_PERMANENT, 0x96, 420), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, wf_seg7_dl_0700F018), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; // 0x0E000B60 const GeoLayout wf_geo_000B60[] = { - GEO_CULLING_RADIUS(650), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, wf_seg7_dl_0700F018), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(650), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, wf_seg7_dl_0700F018), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/wf/kickable_board/geo.inc.c b/levels/wf/kickable_board/geo.inc.c index b9e70b61..58511ae3 100644 --- a/levels/wf/kickable_board/geo.inc.c +++ b/levels/wf/kickable_board/geo.inc.c @@ -1,18 +1,18 @@ // 0x0E000BA8 const GeoLayout wf_geo_000BA8[] = { - GEO_CULLING_RADIUS(1300), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, wf_seg7_dl_0700F610), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT_DECAL, wf_seg7_dl_0700F6C0), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(1300), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, wf_seg7_dl_0700F610), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT_DECAL, wf_seg7_dl_0700F6C0), + GEO_CLOSE_NODE(), + GEO_END(), }; // 0x0E000BC8 const GeoLayout wf_geo_000BC8[] = { - GEO_CULLING_RADIUS(1300), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, wf_seg7_dl_0700F610), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(1300), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, wf_seg7_dl_0700F610), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/wf/large_bomp/geo.inc.c b/levels/wf/large_bomp/geo.inc.c index d2615cd2..de5e9d2d 100644 --- a/levels/wf/large_bomp/geo.inc.c +++ b/levels/wf/large_bomp/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000A40 const GeoLayout wf_geo_000A40[] = { - GEO_CULLING_RADIUS(700), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, wf_seg7_dl_0700DE20), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(700), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, wf_seg7_dl_0700DE20), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/wf/leveldata.c b/levels/wf/leveldata.c index 071a395a..42269cff 100644 --- a/levels/wf/leveldata.c +++ b/levels/wf/leveldata.c @@ -3,8 +3,8 @@ #include "surface_terrains.h" #include "moving_texture_macros.h" #include "level_misc_macros.h" -#include "macro_preset_names.h" -#include "special_preset_names.h" +#include "macro_presets.h" +#include "special_presets.h" #include "textures.h" #include "dialog_ids.h" diff --git a/levels/wf/rotating_wooden_platform/geo.inc.c b/levels/wf/rotating_wooden_platform/geo.inc.c index 964c7a13..16873a1c 100644 --- a/levels/wf/rotating_wooden_platform/geo.inc.c +++ b/levels/wf/rotating_wooden_platform/geo.inc.c @@ -1,15 +1,15 @@ // 0x0E000A58 const GeoLayout wf_geo_000A58[] = { - GEO_CULLING_RADIUS(1500), - GEO_OPEN_NODE(), - GEO_RENDER_RANGE(-2048, 5000), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, wf_seg7_dl_0700E760), - GEO_CLOSE_NODE(), - GEO_RENDER_RANGE(5000, 32767), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, wf_seg7_dl_0700E9B8), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(1500), + GEO_OPEN_NODE(), + GEO_RENDER_RANGE(-2048, 5000), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, wf_seg7_dl_0700E760), + GEO_CLOSE_NODE(), + GEO_RENDER_RANGE(5000, 32767), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, wf_seg7_dl_0700E9B8), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/wf/script.c b/levels/wf/script.c index 6697b497..4ab0c206 100644 --- a/levels/wf/script.c +++ b/levels/wf/script.c @@ -19,91 +19,91 @@ // Unlike most levels, some of the level geometry objects in WF are defined as regular objects instead of terrain objects. // Some of them are still terrain objects, however. static const LevelScript script_func_local_1[] = { - OBJECT(/*model*/ MODEL_LEVEL_GEOMETRY_03, /*pos*/ 2305, 2432, -255, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvStaticObject), - OBJECT(/*model*/ MODEL_LEVEL_GEOMETRY_04, /*pos*/ 3405, 1664, -1791, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvStaticObject), - OBJECT(/*model*/ MODEL_LEVEL_GEOMETRY_05, /*pos*/ 3840, 0, -2303, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvStaticObject), - OBJECT(/*model*/ MODEL_LEVEL_GEOMETRY_05, /*pos*/ 3840, 0, -1279, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvStaticObject), - OBJECT(/*model*/ MODEL_LEVEL_GEOMETRY_06, /*pos*/ 0, 0, 0, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvStaticObject), - OBJECT(/*model*/ MODEL_LEVEL_GEOMETRY_07, /*pos*/ 1757, 3519, -3151, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvStaticObject), - OBJECT(/*model*/ MODEL_LEVEL_GEOMETRY_0A, /*pos*/ 3840, 794, 2688, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvStaticObject), - OBJECT(/*model*/ MODEL_LEVEL_GEOMETRY_0C, /*pos*/ 1408, 2522, 2431, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvStaticObject), - OBJECT(/*model*/ MODEL_WF_GIANT_POLE, /*pos*/ -2560, 2560, -256, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvGiantPole), + OBJECT(/*model*/ MODEL_LEVEL_GEOMETRY_03, /*pos*/ 2305, 2432, -255, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvStaticObject), + OBJECT(/*model*/ MODEL_LEVEL_GEOMETRY_04, /*pos*/ 3405, 1664, -1791, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvStaticObject), + OBJECT(/*model*/ MODEL_LEVEL_GEOMETRY_05, /*pos*/ 3840, 0, -2303, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvStaticObject), + OBJECT(/*model*/ MODEL_LEVEL_GEOMETRY_05, /*pos*/ 3840, 0, -1279, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvStaticObject), + OBJECT(/*model*/ MODEL_LEVEL_GEOMETRY_06, /*pos*/ 0, 0, 0, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvStaticObject), + OBJECT(/*model*/ MODEL_LEVEL_GEOMETRY_07, /*pos*/ 1757, 3519, -3151, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvStaticObject), + OBJECT(/*model*/ MODEL_LEVEL_GEOMETRY_0A, /*pos*/ 3840, 794, 2688, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvStaticObject), + OBJECT(/*model*/ MODEL_LEVEL_GEOMETRY_0C, /*pos*/ 1408, 2522, 2431, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvStaticObject), + OBJECT(/*model*/ MODEL_WF_GIANT_POLE, /*pos*/ -2560, 2560, -256, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvGiantPole), RETURN(), }; static const LevelScript script_func_local_2[] = { - OBJECT(/*model*/ MODEL_WF_SMALL_BOMP, /*pos*/ 3300, 1070, 1, /*angle*/ 0, 90, 0, /*behParam*/ 0x00000000, /*beh*/ bhvSmallBomp), - OBJECT(/*model*/ MODEL_WF_SMALL_BOMP, /*pos*/ 3300, 1070, 1281, /*angle*/ 0, 90, 0, /*behParam*/ 0x00000000, /*beh*/ bhvSmallBomp), - OBJECT(/*model*/ MODEL_WF_LARGE_BOMP, /*pos*/ 3300, 1070, 641, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvLargeBomp), - OBJECT(/*model*/ MODEL_WF_ROTATING_WOODEN_PLATFORM, /*pos*/ -255, 2560, 2304, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvWfRotatingWoodenPlatform), - OBJECT(/*model*/ MODEL_WF_SLIDING_PLATFORM, /*pos*/ 3328, 1075, -1791, /*angle*/ 0, 90, 0, /*behParam*/ 0x00020000, /*beh*/ bhvWfSlidingPlatform), - OBJECT(/*model*/ MODEL_WF_SLIDING_PLATFORM, /*pos*/ 3328, 1075, -767, /*angle*/ 0, 90, 0, /*behParam*/ 0x00010000, /*beh*/ bhvWfSlidingPlatform), - OBJECT(/*model*/ MODEL_WF_SLIDING_PLATFORM, /*pos*/ 3328, 1075, -2815, /*angle*/ 0, 90, 0, /*behParam*/ 0x00030000, /*beh*/ bhvWfSlidingPlatform), - OBJECT(/*model*/ MODEL_WF_TUMBLING_BRIDGE, /*pos*/ 1792, 2496, 1600, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvWfTumblingBridge), - OBJECT(/*model*/ MODEL_WF_BREAKABLE_WALL_RIGHT, /*pos*/ 512, 2176, 2944, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvWfBreakableWallRight), - OBJECT(/*model*/ MODEL_WF_BREAKABLE_WALL_LEFT, /*pos*/ -1023, 2176, 2944, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvWfBreakableWallLeft), - OBJECT_WITH_ACTS(/*model*/ MODEL_WF_KICKABLE_BOARD, /*pos*/ 13, 3584, -1407, /*angle*/ 0, 315, 0, /*behParam*/ 0x00000000, /*beh*/ bhvKickableBoard, /*acts*/ ACT_2 | ACT_3 | ACT_4 | ACT_5 | ACT_6), - OBJECT_WITH_ACTS(/*model*/ MODEL_1UP, /*pos*/ -384, 3584, 6, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhv1Up, /*acts*/ ACT_2 | ACT_3 | ACT_4 | ACT_5 | ACT_6), - OBJECT(/*model*/ MODEL_WF_ROTATING_PLATFORM, /*pos*/ 2304, 3584, -2303, /*angle*/ 0, 0, 0, /*behParam*/ 0x08000000, /*beh*/ bhvRotatingPlatform), - OBJECT(/*model*/ MODEL_WF_ROTATING_PLATFORM, /*pos*/ 3200, 3328, -1791, /*angle*/ 0, 0, 0, /*behParam*/ 0x08000000, /*beh*/ bhvRotatingPlatform), - OBJECT(/*model*/ MODEL_WF_ROTATING_PLATFORM, /*pos*/ 2688, 3584, -895, /*angle*/ 0, 0, 0, /*behParam*/ 0x08000000, /*beh*/ bhvRotatingPlatform), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -2495, 1331, -256, /*angle*/ 0, 0, 0, /*behParam*/ 0x003D0000, /*beh*/ bhvPoleGrabbing), + OBJECT (/*model*/ MODEL_WF_SMALL_BOMP, /*pos*/ 3300, 1070, 1, /*angle*/ 0, 90, 0, /*bhvParam*/ 0, /*bhv*/ bhvSmallBomp), + OBJECT (/*model*/ MODEL_WF_SMALL_BOMP, /*pos*/ 3300, 1070, 1281, /*angle*/ 0, 90, 0, /*bhvParam*/ 0, /*bhv*/ bhvSmallBomp), + OBJECT (/*model*/ MODEL_WF_LARGE_BOMP, /*pos*/ 3300, 1070, 641, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvLargeBomp), + OBJECT (/*model*/ MODEL_WF_ROTATING_WOODEN_PLATFORM, /*pos*/ -255, 2560, 2304, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvWFRotatingWoodenPlatform), + OBJECT (/*model*/ MODEL_WF_SLIDING_PLATFORM, /*pos*/ 3328, 1075, -1791, /*angle*/ 0, 90, 0, /*bhvParam*/ BPARAM2(WF_SLID_BRICK_PTFM_BP_MOV_VEL_15), /*bhv*/ bhvWFSlidingPlatform), + OBJECT (/*model*/ MODEL_WF_SLIDING_PLATFORM, /*pos*/ 3328, 1075, -767, /*angle*/ 0, 90, 0, /*bhvParam*/ BPARAM2(WF_SLID_BRICK_PTFM_BP_MOV_VEL_10), /*bhv*/ bhvWFSlidingPlatform), + OBJECT (/*model*/ MODEL_WF_SLIDING_PLATFORM, /*pos*/ 3328, 1075, -2815, /*angle*/ 0, 90, 0, /*bhvParam*/ BPARAM2(WF_SLID_BRICK_PTFM_BP_MOV_VEL_20), /*bhv*/ bhvWFSlidingPlatform), + OBJECT (/*model*/ MODEL_WF_TUMBLING_BRIDGE, /*pos*/ 1792, 2496, 1600, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(TUMBLING_BRIDGE_BP_WF), /*bhv*/ bhvTumblingBridge), + OBJECT (/*model*/ MODEL_WF_BREAKABLE_WALL_RIGHT, /*pos*/ 512, 2176, 2944, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvWFBreakableWallRight), + OBJECT (/*model*/ MODEL_WF_BREAKABLE_WALL_LEFT, /*pos*/ -1023, 2176, 2944, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvWFBreakableWallLeft), + OBJECT_WITH_ACTS(/*model*/ MODEL_WF_KICKABLE_BOARD, /*pos*/ 13, 3584, -1407, /*angle*/ 0, 315, 0, /*bhvParam*/ 0, /*bhv*/ bhvKickableBoard, /*acts*/ ACT_2 | ACT_3 | ACT_4 | ACT_5 | ACT_6), + OBJECT_WITH_ACTS(/*model*/ MODEL_1UP, /*pos*/ -384, 3584, 6, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(ONE_UP_BP_GENERIC), /*bhv*/ bhv1Up, /*acts*/ ACT_2 | ACT_3 | ACT_4 | ACT_5 | ACT_6), + OBJECT (/*model*/ MODEL_WF_ROTATING_PLATFORM, /*pos*/ 2304, 3584, -2303, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(0x08) | BPARAM2(ROTATING_PLATFORM_BP_WF), /*bhv*/ bhvRotatingPlatform), + OBJECT (/*model*/ MODEL_WF_ROTATING_PLATFORM, /*pos*/ 3200, 3328, -1791, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(0x08) | BPARAM2(ROTATING_PLATFORM_BP_WF), /*bhv*/ bhvRotatingPlatform), + OBJECT (/*model*/ MODEL_WF_ROTATING_PLATFORM, /*pos*/ 2688, 3584, -895, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(0x08) | BPARAM2(ROTATING_PLATFORM_BP_WF), /*bhv*/ bhvRotatingPlatform), + OBJECT (/*model*/ MODEL_NONE, /*pos*/ -2495, 1331, -256, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(61), /*bhv*/ bhvPoleGrabbing), RETURN(), }; static const LevelScript script_func_local_3[] = { - OBJECT(/*model*/ MODEL_THWOMP, /*pos*/ 3462, 1939, -1545, /*angle*/ 0, 180, 0, /*behParam*/ 0x00000000, /*beh*/ bhvThwomp), - OBJECT(/*model*/ MODEL_THWOMP, /*pos*/ 3462, 1075, -3314, /*angle*/ 0, 90, 0, /*behParam*/ 0x00000000, /*beh*/ bhvThwomp2), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -856, 922, 3819, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvBetaFishSplashSpawner), - OBJECT(/*model*/ MODEL_PIRANHA_PLANT, /*pos*/ 1822, 2560, -101, /*angle*/ 0, 90, 0, /*behParam*/ 0x00000000, /*beh*/ bhvPiranhaPlant), - OBJECT(/*model*/ MODEL_PIRANHA_PLANT, /*pos*/ 4625, 256, 5017, /*angle*/ 0, -90, 0, /*behParam*/ 0x00000000, /*beh*/ bhvPiranhaPlant), - OBJECT(/*model*/ MODEL_PIRANHA_PLANT, /*pos*/ 689, 2560, 1845, /*angle*/ 0, 90, 0, /*behParam*/ 0x00000000, /*beh*/ bhvPiranhaPlant), - OBJECT(/*model*/ MODEL_WHOMP, /*pos*/ -1545, 2560, -286, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvSmallWhomp), - OBJECT(/*model*/ MODEL_WHOMP, /*pos*/ 189, 2560, -1857, /*angle*/ 0, -135, 0, /*behParam*/ 0x00000000, /*beh*/ bhvSmallWhomp), - OBJECT(/*model*/ MODEL_BUTTERFLY, /*pos*/ 4736, 256, 4992, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvButterfly), - OBJECT(/*model*/ MODEL_BUTTERFLY, /*pos*/ 4608, 256, 5120, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvButterfly), - OBJECT(/*model*/ MODEL_BUTTERFLY, /*pos*/ 4608, 256, 4992, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvButterfly), - OBJECT(/*model*/ MODEL_BUTTERFLY, /*pos*/ 4608, 256, 4864, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvButterfly), - OBJECT(/*model*/ MODEL_BUTTERFLY, /*pos*/ 4480, 256, 4992, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvButterfly), - OBJECT(/*model*/ MODEL_BUTTERFLY, /*pos*/ 4608, 256, 256, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvButterfly), - OBJECT(/*model*/ MODEL_BUTTERFLY, /*pos*/ 4736, 256, 128, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvButterfly), - OBJECT(/*model*/ MODEL_BUTTERFLY, /*pos*/ 4480, 256, 128, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvButterfly), - OBJECT(/*model*/ MODEL_BUTTERFLY, /*pos*/ 4608, 256, 0, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvButterfly), - OBJECT(/*model*/ MODEL_BUTTERFLY, /*pos*/ 4608, 256, 128, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvButterfly), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 1035, 2880, -900, /*angle*/ 0, 45, 0, /*behParam*/ 0x00000000, /*beh*/ bhvCheckerboardElevatorGroup), - OBJECT_WITH_ACTS(/*model*/ MODEL_BULLET_BILL, /*pos*/ 1280, 3712, 968, /*angle*/ 0, 180, 0, /*behParam*/ 0x00000000, /*beh*/ bhvBulletBill, /*acts*/ ACT_2 | ACT_3 | ACT_4 | ACT_5 | ACT_6), - OBJECT_WITH_ACTS(/*model*/ MODEL_LEVEL_GEOMETRY_08, /*pos*/ 0, 3584, 0, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvTower, /*acts*/ ACT_2 | ACT_3 | ACT_4 | ACT_5 | ACT_6), - OBJECT_WITH_ACTS(/*model*/ MODEL_LEVEL_GEOMETRY_09, /*pos*/ 1280, 3584, 896, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvBulletBillCannon, /*acts*/ ACT_2 | ACT_3 | ACT_4 | ACT_5 | ACT_6), - OBJECT_WITH_ACTS(/*model*/ MODEL_NONE, /*pos*/ 0, 3483, 0, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvTowerPlatformGroup, /*acts*/ ACT_2 | ACT_3 | ACT_4 | ACT_5 | ACT_6), - OBJECT_WITH_ACTS(/*model*/ MODEL_WF_TOWER_DOOR, /*pos*/ -511, 3584, 0, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvTowerDoor, /*acts*/ ACT_2 | ACT_3 | ACT_4 | ACT_5 | ACT_6), - OBJECT_WITH_ACTS(/*model*/ MODEL_BOBOMB_BUDDY, /*pos*/ -1700, 1140, 3500, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvBobombBuddyOpensCannon, /*acts*/ ACT_3 | ACT_4 | ACT_5 | ACT_6), - OBJECT_WITH_ACTS(/*model*/ MODEL_HOOT, /*pos*/ 2560, 700, 4608, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvHoot, /*acts*/ ACT_3 | ACT_4 | ACT_5 | ACT_6), + OBJECT (/*model*/ MODEL_THWOMP, /*pos*/ 3462, 1939, -1545, /*angle*/ 0, 180, 0, /*bhvParam*/ BPARAM2(0), /*bhv*/ bhvThwomp2), + OBJECT (/*model*/ MODEL_THWOMP, /*pos*/ 3462, 1075, -3314, /*angle*/ 0, 90, 0, /*bhvParam*/ BPARAM2(0), /*bhv*/ bhvThwomp), + OBJECT (/*model*/ MODEL_NONE, /*pos*/ -856, 922, 3819, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvBetaFishSplashSpawner), + OBJECT (/*model*/ MODEL_PIRANHA_PLANT, /*pos*/ 1822, 2560, -101, /*angle*/ 0, 90, 0, /*bhvParam*/ 0, /*bhv*/ bhvPiranhaPlant), + OBJECT (/*model*/ MODEL_PIRANHA_PLANT, /*pos*/ 4625, 256, 5017, /*angle*/ 0, -90, 0, /*bhvParam*/ 0, /*bhv*/ bhvPiranhaPlant), + OBJECT (/*model*/ MODEL_PIRANHA_PLANT, /*pos*/ 689, 2560, 1845, /*angle*/ 0, 90, 0, /*bhvParam*/ 0, /*bhv*/ bhvPiranhaPlant), + OBJECT (/*model*/ MODEL_WHOMP, /*pos*/ -1545, 2560, -286, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(WHOMP_BP_SMALL), /*bhv*/ bhvSmallWhomp), + OBJECT (/*model*/ MODEL_WHOMP, /*pos*/ 189, 2560, -1857, /*angle*/ 0, -135, 0, /*bhvParam*/ BPARAM2(WHOMP_BP_SMALL), /*bhv*/ bhvSmallWhomp), + OBJECT (/*model*/ MODEL_BUTTERFLY, /*pos*/ 4736, 256, 4992, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvButterfly), + OBJECT (/*model*/ MODEL_BUTTERFLY, /*pos*/ 4608, 256, 5120, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvButterfly), + OBJECT (/*model*/ MODEL_BUTTERFLY, /*pos*/ 4608, 256, 4992, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvButterfly), + OBJECT (/*model*/ MODEL_BUTTERFLY, /*pos*/ 4608, 256, 4864, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvButterfly), + OBJECT (/*model*/ MODEL_BUTTERFLY, /*pos*/ 4480, 256, 4992, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvButterfly), + OBJECT (/*model*/ MODEL_BUTTERFLY, /*pos*/ 4608, 256, 256, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvButterfly), + OBJECT (/*model*/ MODEL_BUTTERFLY, /*pos*/ 4736, 256, 128, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvButterfly), + OBJECT (/*model*/ MODEL_BUTTERFLY, /*pos*/ 4480, 256, 128, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvButterfly), + OBJECT (/*model*/ MODEL_BUTTERFLY, /*pos*/ 4608, 256, 0, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvButterfly), + OBJECT (/*model*/ MODEL_BUTTERFLY, /*pos*/ 4608, 256, 128, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvButterfly), + OBJECT (/*model*/ MODEL_NONE, /*pos*/ 1035, 2880, -900, /*angle*/ 0, 45, 0, /*bhvParam*/ BPARAM1(0) | BPARAM2(0), /*bhv*/ bhvCheckerboardElevatorGroup), + OBJECT_WITH_ACTS(/*model*/ MODEL_BULLET_BILL, /*pos*/ 1280, 3712, 968, /*angle*/ 0, 180, 0, /*bhvParam*/ 0, /*bhv*/ bhvBulletBill, /*acts*/ ACT_2 | ACT_3 | ACT_4 | ACT_5 | ACT_6), + OBJECT_WITH_ACTS(/*model*/ MODEL_LEVEL_GEOMETRY_08, /*pos*/ 0, 3584, 0, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvTower, /*acts*/ ACT_2 | ACT_3 | ACT_4 | ACT_5 | ACT_6), + OBJECT_WITH_ACTS(/*model*/ MODEL_LEVEL_GEOMETRY_09, /*pos*/ 1280, 3584, 896, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvBulletBillCannon, /*acts*/ ACT_2 | ACT_3 | ACT_4 | ACT_5 | ACT_6), + OBJECT_WITH_ACTS(/*model*/ MODEL_NONE, /*pos*/ 0, 3483, 0, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvTowerPlatformGroup, /*acts*/ ACT_2 | ACT_3 | ACT_4 | ACT_5 | ACT_6), + OBJECT_WITH_ACTS(/*model*/ MODEL_WF_TOWER_DOOR, /*pos*/ -511, 3584, 0, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvTowerDoor, /*acts*/ ACT_2 | ACT_3 | ACT_4 | ACT_5 | ACT_6), + OBJECT_WITH_ACTS(/*model*/ MODEL_BOBOMB_BUDDY, /*pos*/ -1700, 1140, 3500, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvBobombBuddyOpensCannon, /*acts*/ ACT_3 | ACT_4 | ACT_5 | ACT_6), + OBJECT_WITH_ACTS(/*model*/ MODEL_HOOT, /*pos*/ 2560, 700, 4608, /*angle*/ 0, 0, 0, /*bhvParam*/ 0, /*bhv*/ bhvHoot, /*acts*/ ACT_3 | ACT_4 | ACT_5 | ACT_6), RETURN(), }; static const LevelScript script_func_local_4[] = { - OBJECT_WITH_ACTS(/*model*/ MODEL_WHOMP, /*pos*/ 0, 3584, 0, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvWhompKingBoss, /*acts*/ ACT_1), - OBJECT_WITH_ACTS(/*model*/ MODEL_STAR, /*pos*/ 300, 5550, 0, /*angle*/ 0, 0, 0, /*behParam*/ 0x01000000, /*beh*/ bhvStar, /*acts*/ ACT_2 | ACT_3 | ACT_4 | ACT_5 | ACT_6), - OBJECT_WITH_ACTS(/*model*/ MODEL_STAR, /*pos*/ -2500, 1500, -750, /*angle*/ 0, 0, 0, /*behParam*/ 0x02000000, /*beh*/ bhvStar, /*acts*/ ALL_ACTS), - OBJECT_WITH_ACTS(/*model*/ MODEL_NONE, /*pos*/ 4600, 550, 2500, /*angle*/ 0, 0, 0, /*behParam*/ 0x03000000, /*beh*/ bhvHiddenRedCoinStar, /*acts*/ ALL_ACTS), - OBJECT_WITH_ACTS(/*model*/ MODEL_STAR, /*pos*/ 2880, 4300, 190, /*angle*/ 0, 0, 0, /*behParam*/ 0x04000000, /*beh*/ bhvStar, /*acts*/ ALL_ACTS), - OBJECT_WITH_ACTS(/*model*/ MODEL_STAR, /*pos*/ 590, 2450, 2650, /*angle*/ 0, 0, 0, /*behParam*/ 0x05000000, /*beh*/ bhvStar, /*acts*/ ALL_ACTS), + OBJECT_WITH_ACTS(/*model*/ MODEL_WHOMP, /*pos*/ 0, 3584, 0, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(STAR_INDEX_ACT_1), /*bhv*/ bhvWhompKingBoss, /*acts*/ ACT_1), + OBJECT_WITH_ACTS(/*model*/ MODEL_STAR, /*pos*/ 300, 5550, 0, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(STAR_INDEX_ACT_2), /*bhv*/ bhvStar, /*acts*/ ACT_2 | ACT_3 | ACT_4 | ACT_5 | ACT_6), + OBJECT_WITH_ACTS(/*model*/ MODEL_STAR, /*pos*/ -2500, 1500, -750, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(STAR_INDEX_ACT_3), /*bhv*/ bhvStar, /*acts*/ ALL_ACTS), + OBJECT_WITH_ACTS(/*model*/ MODEL_NONE, /*pos*/ 4600, 550, 2500, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(STAR_INDEX_ACT_4), /*bhv*/ bhvHiddenRedCoinStar, /*acts*/ ALL_ACTS), + OBJECT_WITH_ACTS(/*model*/ MODEL_STAR, /*pos*/ 2880, 4300, 190, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(STAR_INDEX_ACT_5), /*bhv*/ bhvStar, /*acts*/ ALL_ACTS), + OBJECT_WITH_ACTS(/*model*/ MODEL_STAR, /*pos*/ 590, 2450, 2650, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(STAR_INDEX_ACT_6), /*bhv*/ bhvStar, /*acts*/ ALL_ACTS), RETURN(), }; const LevelScript level_wf_entry[] = { INIT_LEVEL(), - LOAD_MIO0( /*seg*/ 0x07, _wf_segment_7SegmentRomStart, _wf_segment_7SegmentRomEnd), - LOAD_MIO0( /*seg*/ 0x0A, _cloud_floor_skybox_mio0SegmentRomStart, _cloud_floor_skybox_mio0SegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x07, _wf_segment_7SegmentRomStart, _wf_segment_7SegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x0A, _cloud_floor_skybox_mio0SegmentRomStart, _cloud_floor_skybox_mio0SegmentRomEnd), LOAD_MIO0_TEXTURE(/*seg*/ 0x09, _grass_mio0SegmentRomStart, _grass_mio0SegmentRomEnd), - LOAD_MIO0( /*seg*/ 0x05, _group1_mio0SegmentRomStart, _group1_mio0SegmentRomEnd), - LOAD_RAW( /*seg*/ 0x0C, _group1_geoSegmentRomStart, _group1_geoSegmentRomEnd), - LOAD_MIO0( /*seg*/ 0x06, _group14_mio0SegmentRomStart, _group14_mio0SegmentRomEnd), - LOAD_RAW( /*seg*/ 0x0D, _group14_geoSegmentRomStart, _group14_geoSegmentRomEnd), - LOAD_MIO0( /*seg*/ 0x08, _common0_mio0SegmentRomStart, _common0_mio0SegmentRomEnd), - LOAD_RAW( /*seg*/ 0x0F, _common0_geoSegmentRomStart, _common0_geoSegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x05, _group1_mio0SegmentRomStart, _group1_mio0SegmentRomEnd), + LOAD_RAW (/*seg*/ 0x0C, _group1_geoSegmentRomStart, _group1_geoSegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x06, _group14_mio0SegmentRomStart, _group14_mio0SegmentRomEnd), + LOAD_RAW (/*seg*/ 0x0D, _group14_geoSegmentRomStart, _group14_geoSegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x08, _common0_mio0SegmentRomStart, _common0_mio0SegmentRomEnd), + LOAD_RAW (/*seg*/ 0x0F, _common0_geoSegmentRomStart, _common0_geoSegmentRomEnd), ALLOC_LEVEL_POOL(), - MARIO(/*model*/ MODEL_MARIO, /*behParam*/ 0x00000001, /*beh*/ bhvMario), + MARIO(/*model*/ MODEL_MARIO, /*bhvParam*/ BPARAM4(0x01), /*bhv*/ bhvMario), JUMP_LINK(script_func_global_1), JUMP_LINK(script_func_global_2), JUMP_LINK(script_func_global_15), @@ -140,14 +140,14 @@ const LevelScript level_wf_entry[] = { LOAD_MODEL_FROM_GEO(MODEL_WF_KICKABLE_BOARD_FELLED, wf_geo_000BC8), AREA(/*index*/ 1, wf_geo_000BF8), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 2600, 1256, 5120, /*angle*/ 0, 90, 0, /*behParam*/ 0x000A0000, /*beh*/ bhvSpinAirborneWarp), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -2925, 2560, -947, /*angle*/ 0, 19, 0, /*behParam*/ 0x000B0000, /*beh*/ bhvFadingWarp), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 2548, 1075, -3962, /*angle*/ 0, 51, 0, /*behParam*/ 0x000C0000, /*beh*/ bhvFadingWarp), - WARP_NODE(/*id*/ 0x0A, /*destLevel*/ LEVEL_WF, /*destArea*/ 0x01, /*destNode*/ 0x0A, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0x0B, /*destLevel*/ LEVEL_WF, /*destArea*/ 0x01, /*destNode*/ 0x0C, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0x0C, /*destLevel*/ LEVEL_WF, /*destArea*/ 0x01, /*destNode*/ 0x0B, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0xF0, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x01, /*destNode*/ 0x34, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0xF1, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x01, /*destNode*/ 0x66, /*flags*/ WARP_NO_CHECKPOINT), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 2600, 1256, 5120, /*angle*/ 0, 90, 0, /*bhvParam*/ BPARAM2(WARP_NODE_0A), /*bhv*/ bhvSpinAirborneWarp), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ -2925, 2560, -947, /*angle*/ 0, 19, 0, /*bhvParam*/ BPARAM2(WARP_NODE_0B), /*bhv*/ bhvFadingWarp), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 2548, 1075, -3962, /*angle*/ 0, 51, 0, /*bhvParam*/ BPARAM2(WARP_NODE_0C), /*bhv*/ bhvFadingWarp), + WARP_NODE(/*id*/ WARP_NODE_0A, /*destLevel*/ LEVEL_WF, /*destArea*/ 1, /*destNode*/ WARP_NODE_0A, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_0B, /*destLevel*/ LEVEL_WF, /*destArea*/ 1, /*destNode*/ WARP_NODE_0C, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_0C, /*destLevel*/ LEVEL_WF, /*destArea*/ 1, /*destNode*/ WARP_NODE_0B, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_SUCCESS, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 1, /*destNode*/ WARP_NODE_34, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_DEATH, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 1, /*destNode*/ WARP_NODE_66, /*flags*/ WARP_NO_CHECKPOINT), JUMP_LINK(script_func_local_1), JUMP_LINK(script_func_local_2), JUMP_LINK(script_func_local_3), diff --git a/levels/wf/sliding_platform/geo.inc.c b/levels/wf/sliding_platform/geo.inc.c index ebab6b8c..9c21a6b5 100644 --- a/levels/wf/sliding_platform/geo.inc.c +++ b/levels/wf/sliding_platform/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000A98 const GeoLayout wf_geo_000A98[] = { - GEO_CULLING_RADIUS(500), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, wf_seg7_dl_0700EB40), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(500), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, wf_seg7_dl_0700EB40), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/wf/small_bomp/geo.inc.c b/levels/wf/small_bomp/geo.inc.c index 93779c76..729cfb79 100644 --- a/levels/wf/small_bomp/geo.inc.c +++ b/levels/wf/small_bomp/geo.inc.c @@ -1,15 +1,15 @@ // 0x0E000A00 const GeoLayout wf_geo_000A00[] = { - GEO_CULLING_RADIUS(500), - GEO_OPEN_NODE(), - GEO_RENDER_RANGE(-2048, 5000), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, wf_seg7_dl_0700D708), - GEO_CLOSE_NODE(), - GEO_RENDER_RANGE(5000, 32767), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, wf_seg7_dl_0700D9F0), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(500), + GEO_OPEN_NODE(), + GEO_RENDER_RANGE(-2048, 5000), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, wf_seg7_dl_0700D708), + GEO_CLOSE_NODE(), + GEO_RENDER_RANGE(5000, 32767), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, wf_seg7_dl_0700D9F0), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/wf/tower_door/geo.inc.c b/levels/wf/tower_door/geo.inc.c index 1d69d066..297230a0 100644 --- a/levels/wf/tower_door/geo.inc.c +++ b/levels/wf/tower_door/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000BE0 const GeoLayout wf_geo_000BE0[] = { - GEO_CULLING_RADIUS(320), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, wf_seg7_dl_0700F7F8), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(320), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, wf_seg7_dl_0700F7F8), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/wf/tumbling_bridge_far/geo.inc.c b/levels/wf/tumbling_bridge_far/geo.inc.c index 21b371cb..17b707c6 100644 --- a/levels/wf/tumbling_bridge_far/geo.inc.c +++ b/levels/wf/tumbling_bridge_far/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000AC8 const GeoLayout wf_geo_000AC8[] = { - GEO_CULLING_RADIUS(800), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, wf_seg7_dl_0700E3D0), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(800), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, wf_seg7_dl_0700E3D0), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/wf/tumbling_bridge_near/geo.inc.c b/levels/wf/tumbling_bridge_near/geo.inc.c index 191d5080..0dc944cd 100644 --- a/levels/wf/tumbling_bridge_near/geo.inc.c +++ b/levels/wf/tumbling_bridge_near/geo.inc.c @@ -1,8 +1,8 @@ // 0x0E000AB0 const GeoLayout wf_geo_000AB0[] = { - GEO_CULLING_RADIUS(400), - GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, wf_seg7_dl_0700E0F0), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CULLING_RADIUS(400), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, wf_seg7_dl_0700E0F0), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/wmotr/areas/1/geo.inc.c b/levels/wmotr/areas/1/geo.inc.c index ba73389a..9537bf89 100644 --- a/levels/wmotr/areas/1/geo.inc.c +++ b/levels/wmotr/areas/1/geo.inc.c @@ -1,32 +1,32 @@ // 0x0E0001F0 const GeoLayout wmotr_geo_0001F0[] = { - GEO_NODE_SCREEN_AREA(10, SCREEN_WIDTH/2, SCREEN_HEIGHT/2, SCREEN_WIDTH/2, SCREEN_HEIGHT/2), - GEO_OPEN_NODE(), - GEO_ZBUFFER(0), - GEO_OPEN_NODE(), - GEO_NODE_ORTHO(100), - GEO_OPEN_NODE(), - GEO_BACKGROUND(BACKGROUND_BELOW_CLOUDS, geo_skybox_main), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ZBUFFER(1), - GEO_OPEN_NODE(), - GEO_CAMERA_FRUSTUM_WITH_FUNC(45, 100, 20000, geo_camera_fov), - GEO_OPEN_NODE(), - GEO_CAMERA(16, 0, 2000, 6000, 0, 0, 0, geo_camera_main), + GEO_NODE_SCREEN_AREA(10, SCREEN_WIDTH/2, SCREEN_HEIGHT/2, SCREEN_WIDTH/2, SCREEN_HEIGHT/2), + GEO_OPEN_NODE(), + GEO_ZBUFFER(0), + GEO_OPEN_NODE(), + GEO_NODE_ORTHO(100), GEO_OPEN_NODE(), - GEO_DISPLAY_LIST(LAYER_OPAQUE, wmotr_seg7_dl_0700C1F8), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, wmotr_seg7_dl_0700EFD8), - GEO_DISPLAY_LIST(LAYER_TRANSPARENT, wmotr_seg7_dl_07010608), - GEO_RENDER_OBJ(), - GEO_ASM(0, geo_envfx_main), + GEO_BACKGROUND(BACKGROUND_BELOW_CLOUDS, geo_skybox_main), GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_ZBUFFER(0), - GEO_OPEN_NODE(), - GEO_ASM(0, geo_cannon_circle_base), - GEO_CLOSE_NODE(), - GEO_CLOSE_NODE(), - GEO_END(), + GEO_CLOSE_NODE(), + GEO_ZBUFFER(1), + GEO_OPEN_NODE(), + GEO_CAMERA_FRUSTUM_WITH_FUNC(45, 100, 20000, geo_camera_fov), + GEO_OPEN_NODE(), + GEO_CAMERA(16, 0, 2000, 6000, 0, 0, 0, geo_camera_main), + GEO_OPEN_NODE(), + GEO_DISPLAY_LIST(LAYER_OPAQUE, wmotr_seg7_dl_0700C1F8), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, wmotr_seg7_dl_0700EFD8), + GEO_DISPLAY_LIST(LAYER_TRANSPARENT, wmotr_seg7_dl_07010608), + GEO_RENDER_OBJ(), + GEO_ASM(0, geo_envfx_main), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_ZBUFFER(0), + GEO_OPEN_NODE(), + GEO_ASM(0, geo_cannon_circle_base), + GEO_CLOSE_NODE(), + GEO_CLOSE_NODE(), + GEO_END(), }; diff --git a/levels/wmotr/areas/1/macro.inc.c b/levels/wmotr/areas/1/macro.inc.c index 2f548eed..e5109097 100644 --- a/levels/wmotr/areas/1/macro.inc.c +++ b/levels/wmotr/areas/1/macro.inc.c @@ -1,30 +1,30 @@ // 0x070136A8 - 0x070137AE const MacroObject wmotr_seg7_macro_objs[] = { - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_cannon_closed, /*yaw*/ 0, /*pos*/ -4456, 827, 191, /*behParam*/ 0x00), - MACRO_OBJECT_WITH_BEH_PARAM(/*preset*/ macro_cannon_closed, /*yaw*/ 0, /*pos*/ 3712, -2740, 5200, /*behParam*/ 0x80), - MACRO_OBJECT(/*preset*/ macro_bobomb_buddy_opens_cannon, /*yaw*/ 0, /*pos*/ 3684, -2712, 4660), - MACRO_OBJECT(/*preset*/ macro_coin_ring_horizontal_flying, /*yaw*/ 0, /*pos*/ -3050, 2100, -4200), - MACRO_OBJECT(/*preset*/ macro_box_1up, /*yaw*/ 0, /*pos*/ -2744, 4899, -4439), - MACRO_OBJECT(/*preset*/ macro_hidden_1up_in_pole, /*yaw*/ 0, /*pos*/ 3995, -1850, 5478), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -2980, 3990, -4248), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 2735, 3140, -3085), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -3640, 4600, -4200), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 4400, 240, 80), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 3440, -2680, 5240), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -600, -1360, 5040), - MACRO_OBJECT(/*preset*/ macro_box_wing_cap, /*yaw*/ 0, /*pos*/ -400, 1960, -120), - MACRO_OBJECT(/*preset*/ macro_box_wing_cap, /*yaw*/ 0, /*pos*/ -240, -1080, 4520), - MACRO_OBJECT(/*preset*/ macro_box_wing_cap, /*yaw*/ 0, /*pos*/ 3600, -2480, 5440), - MACRO_OBJECT(/*preset*/ macro_box_wing_cap, /*yaw*/ 0, /*pos*/ 3960, 520, 440), - MACRO_OBJECT(/*preset*/ macro_box_wing_cap, /*yaw*/ 0, /*pos*/ -3200, 4880, -4040), - MACRO_OBJECT(/*preset*/ macro_box_wing_cap, /*yaw*/ 0, /*pos*/ -2760, 2320, -4080), - MACRO_OBJECT(/*preset*/ macro_1up, /*yaw*/ 0, /*pos*/ -3630, -430, 3180), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 320, 1725, 40), - MACRO_OBJECT(/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -2560, 4600, -4800), - MACRO_OBJECT(/*preset*/ macro_coin_ring_vertical, /*yaw*/ 0, /*pos*/ -50, 2180, 1900), - MACRO_OBJECT(/*preset*/ macro_coin_ring_vertical, /*yaw*/ 40, /*pos*/ -2850, 1550, 2280), - MACRO_OBJECT(/*preset*/ macro_coin_ring_vertical, /*yaw*/ 85, /*pos*/ 1710, -650, 4850), - MACRO_OBJECT(/*preset*/ macro_coin_ring_vertical, /*yaw*/ 0, /*pos*/ 2350, 2300, 240), - MACRO_OBJECT(/*preset*/ macro_1up, /*yaw*/ 0, /*pos*/ -3260, 3370, -3945), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_cannon_closed, /*yaw*/ 0, /*pos*/ -4456, 827, 191, /*bhvParam*/ 0x00), + MACRO_OBJECT_WITH_BHV_PARAM(/*preset*/ macro_cannon_closed, /*yaw*/ 0, /*pos*/ 3712, -2740, 5200, /*bhvParam*/ 0x80), + MACRO_OBJECT (/*preset*/ macro_bobomb_buddy_opens_cannon_1, /*yaw*/ 0, /*pos*/ 3684, -2712, 4660), + MACRO_OBJECT (/*preset*/ macro_coin_ring_horizontal_flying, /*yaw*/ 0, /*pos*/ -3050, 2100, -4200), + MACRO_OBJECT (/*preset*/ macro_box_1up, /*yaw*/ 0, /*pos*/ -2744, 4899, -4439), + MACRO_OBJECT (/*preset*/ macro_hidden_1up_in_pole, /*yaw*/ 0, /*pos*/ 3995, -1850, 5478), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -2980, 3990, -4248), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 2735, 3140, -3085), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -3640, 4600, -4200), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 4400, 240, 80), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 3440, -2680, 5240), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -600, -1360, 5040), + MACRO_OBJECT (/*preset*/ macro_box_wing_cap, /*yaw*/ 0, /*pos*/ -400, 1960, -120), + MACRO_OBJECT (/*preset*/ macro_box_wing_cap, /*yaw*/ 0, /*pos*/ -240, -1080, 4520), + MACRO_OBJECT (/*preset*/ macro_box_wing_cap, /*yaw*/ 0, /*pos*/ 3600, -2480, 5440), + MACRO_OBJECT (/*preset*/ macro_box_wing_cap, /*yaw*/ 0, /*pos*/ 3960, 520, 440), + MACRO_OBJECT (/*preset*/ macro_box_wing_cap, /*yaw*/ 0, /*pos*/ -3200, 4880, -4040), + MACRO_OBJECT (/*preset*/ macro_box_wing_cap, /*yaw*/ 0, /*pos*/ -2760, 2320, -4080), + MACRO_OBJECT (/*preset*/ macro_1up, /*yaw*/ 0, /*pos*/ -3630, -430, 3180), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ 320, 1725, 40), + MACRO_OBJECT (/*preset*/ macro_red_coin, /*yaw*/ 0, /*pos*/ -2560, 4600, -4800), + MACRO_OBJECT (/*preset*/ macro_coin_ring_vertical_flying, /*yaw*/ 0, /*pos*/ -50, 2180, 1900), + MACRO_OBJECT (/*preset*/ macro_coin_ring_vertical_flying, /*yaw*/ 40, /*pos*/ -2850, 1550, 2280), + MACRO_OBJECT (/*preset*/ macro_coin_ring_vertical_flying, /*yaw*/ 85, /*pos*/ 1710, -650, 4850), + MACRO_OBJECT (/*preset*/ macro_coin_ring_vertical_flying, /*yaw*/ 0, /*pos*/ 2350, 2300, 240), + MACRO_OBJECT (/*preset*/ macro_1up, /*yaw*/ 0, /*pos*/ -3260, 3370, -3945), MACRO_OBJECT_END(), }; diff --git a/levels/wmotr/level.yaml b/levels/wmotr/level.yaml index a17b7179..075a88ba 100644 --- a/levels/wmotr/level.yaml +++ b/levels/wmotr/level.yaml @@ -1,6 +1,6 @@ -# Wing Mario Over the Rainbow +# Wing Mario over the Rainbow short-name: wmotr -full-name: Wing Mario Over the Rainbow +full-name: Wing Mario over the Rainbow texture-file: ["/texture.inc.c"] area-count: 1 objects: [] diff --git a/levels/wmotr/leveldata.c b/levels/wmotr/leveldata.c index d80b826c..d53095ae 100644 --- a/levels/wmotr/leveldata.c +++ b/levels/wmotr/leveldata.c @@ -3,8 +3,8 @@ #include "surface_terrains.h" #include "moving_texture_macros.h" #include "level_misc_macros.h" -#include "macro_preset_names.h" -#include "special_preset_names.h" +#include "macro_presets.h" +#include "special_presets.h" #include "textures.h" #include "make_const_nonconst.h" diff --git a/levels/wmotr/script.c b/levels/wmotr/script.c index dfbaae27..ad5d6c03 100644 --- a/levels/wmotr/script.c +++ b/levels/wmotr/script.c @@ -16,43 +16,43 @@ #include "levels/wmotr/header.h" static const LevelScript script_func_local_1[] = { - OBJECT(/*model*/ MODEL_NONE, /*pos*/ 3996, -2739, 5477, /*angle*/ 0, 0, 0, /*behParam*/ 0x00520000, /*beh*/ bhvPoleGrabbing), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -2911, 3564, -3967, /*angle*/ 0, 0, 0, /*behParam*/ 0x00540000, /*beh*/ bhvPoleGrabbing), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -3258, 3359, -3946, /*angle*/ 0, 0, 0, /*behParam*/ 0x00690000, /*beh*/ bhvPoleGrabbing), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -2639, 3154, -4369, /*angle*/ 0, 0, 0, /*behParam*/ 0x007D0000, /*beh*/ bhvPoleGrabbing), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -2980, 4048, -4248, /*angle*/ 0, 0, 0, /*behParam*/ 0x00240000, /*beh*/ bhvPoleGrabbing), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -3290, 3636, -4477, /*angle*/ 0, 0, 0, /*behParam*/ 0x004D0000, /*beh*/ bhvPoleGrabbing), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ 3996, -2739, 5477, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(82), /*bhv*/ bhvPoleGrabbing), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ -2911, 3564, -3967, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(84), /*bhv*/ bhvPoleGrabbing), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ -3258, 3359, -3946, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(105), /*bhv*/ bhvPoleGrabbing), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ -2639, 3154, -4369, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(125), /*bhv*/ bhvPoleGrabbing), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ -2980, 4048, -4248, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(36), /*bhv*/ bhvPoleGrabbing), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ -3290, 3636, -4477, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM2(77), /*bhv*/ bhvPoleGrabbing), RETURN(), }; static const LevelScript script_func_local_2[] = { - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -160, 1950, -470, /*angle*/ 0, 0, 0, /*behParam*/ 0x00000000, /*beh*/ bhvHiddenRedCoinStar), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ -160, 1950, -470, /*angle*/ 0, 0, 0, /*bhvParam*/ BPARAM1(STAR_INDEX_ACT_1), /*bhv*/ bhvHiddenRedCoinStar), RETURN(), }; const LevelScript level_wmotr_entry[] = { INIT_LEVEL(), - LOAD_MIO0( /*seg*/ 0x07, _wmotr_segment_7SegmentRomStart, _wmotr_segment_7SegmentRomEnd), - LOAD_MIO0( /*seg*/ 0x0A, _cloud_floor_skybox_mio0SegmentRomStart, _cloud_floor_skybox_mio0SegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x07, _wmotr_segment_7SegmentRomStart, _wmotr_segment_7SegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x0A, _cloud_floor_skybox_mio0SegmentRomStart, _cloud_floor_skybox_mio0SegmentRomEnd), LOAD_MIO0_TEXTURE(/*seg*/ 0x09, _sky_mio0SegmentRomStart, _sky_mio0SegmentRomEnd), - LOAD_MIO0( /*seg*/ 0x05, _group2_mio0SegmentRomStart, _group2_mio0SegmentRomEnd), - LOAD_RAW( /*seg*/ 0x0C, _group2_geoSegmentRomStart, _group2_geoSegmentRomEnd), - LOAD_MIO0( /*seg*/ 0x06, _group17_mio0SegmentRomStart, _group17_mio0SegmentRomEnd), - LOAD_RAW( /*seg*/ 0x0D, _group17_geoSegmentRomStart, _group17_geoSegmentRomEnd), - LOAD_MIO0( /*seg*/ 0x08, _common0_mio0SegmentRomStart, _common0_mio0SegmentRomEnd), - LOAD_RAW( /*seg*/ 0x0F, _common0_geoSegmentRomStart, _common0_geoSegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x05, _group2_mio0SegmentRomStart, _group2_mio0SegmentRomEnd), + LOAD_RAW (/*seg*/ 0x0C, _group2_geoSegmentRomStart, _group2_geoSegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x06, _group17_mio0SegmentRomStart, _group17_mio0SegmentRomEnd), + LOAD_RAW (/*seg*/ 0x0D, _group17_geoSegmentRomStart, _group17_geoSegmentRomEnd), + LOAD_MIO0 (/*seg*/ 0x08, _common0_mio0SegmentRomStart, _common0_mio0SegmentRomEnd), + LOAD_RAW (/*seg*/ 0x0F, _common0_geoSegmentRomStart, _common0_geoSegmentRomEnd), ALLOC_LEVEL_POOL(), - MARIO(/*model*/ MODEL_MARIO, /*behParam*/ 0x00000001, /*beh*/ bhvMario), + MARIO(/*model*/ MODEL_MARIO, /*bhvParam*/ BPARAM4(0x01), /*bhv*/ bhvMario), JUMP_LINK(script_func_global_1), JUMP_LINK(script_func_global_3), JUMP_LINK(script_func_global_18), AREA(/*index*/ 1, wmotr_geo_0001F0), - OBJECT(/*model*/ MODEL_NONE, /*pos*/ -67, 2669, -16, /*angle*/ 0, 270, 0, /*behParam*/ 0x000A0000, /*beh*/ bhvAirborneWarp), - WARP_NODE(/*id*/ 0x0A, /*destLevel*/ LEVEL_WMOTR, /*destArea*/ 0x01, /*destNode*/ 0x0A, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0xF0, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x02, /*destNode*/ 0x38, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0xF1, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 0x02, /*destNode*/ 0x6D, /*flags*/ WARP_NO_CHECKPOINT), - WARP_NODE(/*id*/ 0xF3, /*destLevel*/ LEVEL_CASTLE_GROUNDS, /*destArea*/ 0x01, /*destNode*/ 0x0A, /*flags*/ WARP_NO_CHECKPOINT), + OBJECT(/*model*/ MODEL_NONE, /*pos*/ -67, 2669, -16, /*angle*/ 0, 270, 0, /*bhvParam*/ BPARAM2(WARP_NODE_0A), /*bhv*/ bhvAirborneWarp), + WARP_NODE(/*id*/ WARP_NODE_0A, /*destLevel*/ LEVEL_WMOTR, /*destArea*/ 1, /*destNode*/ WARP_NODE_0A, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_SUCCESS, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 2, /*destNode*/ WARP_NODE_38, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_DEATH, /*destLevel*/ LEVEL_CASTLE, /*destArea*/ 2, /*destNode*/ WARP_NODE_6D, /*flags*/ WARP_NO_CHECKPOINT), + WARP_NODE(/*id*/ WARP_NODE_WARP_FLOOR, /*destLevel*/ LEVEL_CASTLE_GROUNDS, /*destArea*/ 1, /*destNode*/ WARP_NODE_0A, /*flags*/ WARP_NO_CHECKPOINT), JUMP_LINK(script_func_local_1), JUMP_LINK(script_func_local_2), TERRAIN(/*terrainData*/ wmotr_seg7_collision), diff --git a/lib/asm/__osDisableInt.s b/lib/asm/__osDisableInt.s index b19b8481..22534ee9 100644 --- a/lib/asm/__osDisableInt.s +++ b/lib/asm/__osDisableInt.s @@ -1,18 +1,40 @@ .set noreorder // don't insert nops after branches -.set gp=64 #include "macros.inc" +#include + .section .text, "ax" glabel __osDisableInt - mfc0 $t0, $12 - and $t1, $t0, -2 - mtc0 $t1, $12 - andi $v0, $t0, 1 - nop - jr $ra - nop +#ifdef VERSION_CN + la $t2, __OSGlobalIntMask + lw $t3, ($t2) + andi $t3, $t3, SR_IMASK +#endif + mfc0 $t0, C0_SR + and $t1, $t0, ~SR_IE + mtc0 $t1, C0_SR + andi $v0, $t0, SR_IE +#ifdef VERSION_CN + lw $t0, ($t2) + andi $t0, $t0, SR_IMASK + beq $t0, $t3, .Lret + lui $t2, %hi(__osRunningThread) + addiu $t2, %lo(__osRunningThread) + lw $t1, 0x118($t2) + andi $t2, $t1, SR_IMASK + and $t2, $t2, $t0 + and $t1, $t1, ~SR_IMASK + or $t1, $t1, $t2 + and $t1, $t1, ~SR_IE + mtc0 $t1, $12 + nop +#endif + nop +.Lret: + jr $ra + nop diff --git a/lib/asm/__osExceptionPreamble.s b/lib/asm/__osExceptionPreamble.s index c3b97993..9c21048e 100644 --- a/lib/asm/__osExceptionPreamble.s +++ b/lib/asm/__osExceptionPreamble.s @@ -1,24 +1,33 @@ .set noat // allow manual use of $at .set noreorder // don't insert nops after branches -.set gp=64 #include "macros.inc" +#include +#include +#include + +#if defined(VERSION_EU) || defined(VERSION_SH) +#define VERSION_EU_SH +#endif + +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) +#define VERSION_EU_SH_CN +#endif + .section .text, "ax" #ifdef AVOID_UB -.set D_80334890, D_80334890_fix +.set __osThreadTail, __osThreadTail_fix #endif glabel __osExceptionPreamble - lui $k0, %hi(__osException) - addiu $k0, %lo(__osException) + la $k0, __osException jr $k0 nop glabel __osException - lui $k0, %hi(gInterruptedThread) - addiu $k0, %lo(gInterruptedThread) + la $k0, __osThreadSave sd $at, 0x20($k0) mfc0 $k1, $12 sw $k1, 0x118($k0) @@ -30,7 +39,7 @@ glabel __osException sd $t2, 0x68($k0) sw $zero, 0x18($k0) mfc0 $t0, $13 -#if !defined(VERSION_EU) && !defined(VERSION_SH) +#ifndef VERSION_EU_SH_CN andi $t1, $t0, 0x7c li $t2, 0 bne $t1, $t2, .L80326750 @@ -57,11 +66,11 @@ glabel __osException lui $at, %hi(D_80334938) #endif move $t0, $k0 -#if !defined(VERSION_EU) && !defined(VERSION_SH) +#ifndef VERSION_EU_SH_CN sw $zero, %lo(D_80334938)($at) #endif - lui $k0, %hi(D_80334890 + 0x10) - lw $k0, %lo(D_80334890 + 0x10)($k0) + lui $k0, %hi(__osThreadTail + 0x10) + lw $k0, %lo(__osThreadTail + 0x10)($k0) ld $t1, 0x20($t0) sd $t1, 0x20($k0) ld $t1, 0x118($t0) @@ -72,15 +81,17 @@ glabel __osException sd $t1, 0x60($k0) ld $t1, 0x68($t0) sd $t1, 0x68($k0) -#if defined(VERSION_EU) || defined(VERSION_SH) +#ifdef VERSION_EU_SH lw $k1, 0x118($k0) #else .L80326794: #endif +#ifndef VERSION_CN mflo $t0 sd $t0, 0x108($k0) mfhi $t0 -#if defined(VERSION_EU) || defined(VERSION_SH) +#endif +#ifdef VERSION_EU_SH andi $t1, $k1, 0xff00 #endif sd $v0, 0x28($k0) @@ -108,11 +119,38 @@ glabel __osException sd $sp, 0xf0($k0) sd $fp, 0xf8($k0) sd $ra, 0x100($k0) -#if defined(VERSION_EU) || defined(VERSION_SH) - beqz $t1, .L802F3A18 +#ifdef VERSION_EU_SH_CN +#ifdef VERSION_CN + mflo $t0 + sd $t0, 0x108($k0) + mfhi $t0 + sd $t0, 0x110($k0) + lw $k1, 0x118($k0) + andi $t1, $k1, SR_IMASK + beqz $t1, savercp + nop + la $t0, __OSGlobalIntMask + lw $t0, ($t0) + lui $at, (0xFFFFFFFF >> 16) + ori $at, (0xFFFFFFFF & 0xFFFF) + xor $t2, $t0, $at + andi $t2, $t2, SR_IMASK + or $t4, $t1, $t2 + lui $at, (~SR_IMASK >> 16) & 0xFFFF + ori $at, (~SR_IMASK & 0xFFFF) + and $t3, $k1, $at + or $t3, $t3, $t4 + sw $t3, 0x118($k0) + andi $t0, $t0, SR_IMASK + and $t1, $t1, $t0 + lui $at, (~SR_IMASK >> 16) & 0xFFFF + ori $at, (~SR_IMASK & 0xFFFF) + and $k1, $k1, $at + or $k1, $k1, $t1 +#else + beqz $t1, savercp sd $t0, 0x110($k0) - lui $t0, %hi(__OSGlobalIntMask) - addiu $t0, %lo(__OSGlobalIntMask) + la $t0, __OSGlobalIntMask lw $t0, ($t0) li $at, -1 #ifdef VERSION_EU @@ -120,13 +158,13 @@ glabel __osException #else xor $t2, $t0, $at #endif - lui $at, (0xFFFF00FF >> 16) + lui $at, (~SR_IMASK >> 16) & 0xFFFF #ifdef VERSION_EU - andi $t0, $t0, 0xFF00 + andi $t0, $t0, SR_IMASK #else - andi $t2, $t2, 0xFF00 + andi $t2, $t2, SR_IMASK #endif - ori $at, (0xFFFF00FF & 0xFFFF) + ori $at, (~SR_IMASK & 0xFFFF) #ifdef VERSION_EU or $t1, $t1, $t0 and $k1, $k1, $at @@ -135,35 +173,43 @@ glabel __osException #else or $t4, $t1, $t2 and $t3, $k1, $at - andi $t0, $t0, 0xFF00 + andi $t0, $t0, SR_IMASK or $t3, $t3, $t4 and $t1, $t1, $t0 and $k1, $k1, $at sw $t3, 0x118($k0) or $k1, $k1, $t1 #endif +#endif -.L802F3A18: - lui $t1, %hi(MI_INTR_MASK_REG) - lw $t1, %lo(MI_INTR_MASK_REG)($t1) - beqz $t1, .L802F3A50 +savercp: + lui $t1, %hi(PHYS_TO_K1(MI_INTR_MASK_REG)) + lw $t1, %lo(PHYS_TO_K1(MI_INTR_MASK_REG))($t1) + beqz $t1, endrcp nop - lui $t0, %hi(__OSGlobalIntMask) - addiu $t0, %lo(__OSGlobalIntMask) + la $t0, __OSGlobalIntMask lw $t0, ($t0) - lw $t4, 0x128($k0) - li $at, -1 +#ifdef VERSION_CN srl $t0, $t0, 0x10 + li $at, 0xFFFFFFFF +#else + lw $t4, 0x128($k0) + li $at, 0xFFFFFFFF + srl $t0, $t0, 0x10 +#endif xor $t0, $t0, $at andi $t0, $t0, 0x3f +#ifdef VERSION_CN + lw $t4, 0x128($k0) +#endif and $t0, $t0, $t4 or $t1, $t1, $t0 -.L802F3A50: +endrcp: sw $t1, 0x128($k0) #else sd $t0, 0x110($k0) #endif - mfc0 $t0, $14 + mfc0 $t0, C0_EPC sw $t0, 0x11c($k0) lw $t0, 0x18($k0) beqz $t0, .L80326868 @@ -188,16 +234,16 @@ glabel __osException sdc1 $f28, 0x1a0($k0) sdc1 $f30, 0x1a8($k0) .L80326868: - mfc0 $t0, $13 + mfc0 $t0, C0_CAUSE sw $t0, 0x120($k0) -#if !defined(VERSION_EU) && !defined(VERSION_SH) - lui $t1, %hi(MI_INTR_MASK_REG) - lw $t1, %lo(MI_INTR_MASK_REG)($t1) +#ifndef VERSION_EU_SH_CN + lui $t1, %hi(PHYS_TO_K1(MI_INTR_MASK_REG)) + lw $t1, %lo(PHYS_TO_K1(MI_INTR_MASK_REG))($t1) sw $t1, 0x128($k0) #endif li $t1, 2 sh $t1, 0x10($k0) -#if !defined(VERSION_EU) && !defined(VERSION_SH) +#ifndef VERSION_EU_SH_CN lui $t1, %hi(D_80334934) lw $t1, %lo(D_80334934)($t1) beqz $t1, .L803268B4 @@ -217,80 +263,173 @@ glabel __osException nop lui $t2, %hi(D_C000000C) sw $zero, %lo(D_C000000C)($t2) - lui $t1, %hi(D_80334A40) - lw $t1, %lo(D_80334A40)($t1) + lui $t1, %hi(__osRdbSendMessage) + lw $t1, %lo(__osRdbSendMessage)($t1) addiu $t2, %lo(D_C000000C) beqz $t1, .L803268E8 nop jal send_mesg li $a0, 120 .L803268E8: - lui $t1, %hi(D_80334A44) - lw $t1, %lo(D_80334A44)($t1) - lui $at, %hi(D_80334A44) + lui $t1, %hi(__osRdbWriteOK) + lw $t1, %lo(__osRdbWriteOK)($t1) + lui $at, %hi(__osRdbWriteOK) addi $t1, $t1, 1 b .L80326E08 - sw $t1, %lo(D_80334A44)($at) + sw $t1, %lo(__osRdbWriteOK)($at) .L80326900: #endif - andi $t1, $t0, 0x7c - li $t2, 36 - beq $t1, $t2, .L80326B84 + andi $t1, $t0, CAUSE_EXCMASK + li $t2, EXC_BREAK + beq $t1, $t2, handle_break nop - li $t2, 44 - beq $t1, $t2, .L80326CCC + li $t2, EXC_CPU + beq $t1, $t2, handle_CpU nop - li $t2, 0 - bne $t1, $t2, .L80326BE8 + li $t2, EXC_INT + bne $t1, $t2, panic nop and $s0, $k1, $t0 -.L8032692C: - andi $t1, $s0, 0xff00 +next_interrupt: + andi $t1, $s0, SR_IMASK srl $t2, $t1, 0xc bnez $t2, .L80326944 nop srl $t2, $t1, 8 addi $t2, $t2, 0x10 .L80326944: - lui $at, %hi(D_80338610) - addu $at, $at, $t2 - lbu $t2, %lo(D_80338610)($at) - lui $at, %hi(jtbl_80338630) - addu $at, $at, $t2 - lw $t2, %lo(jtbl_80338630)($at) + // TODO: Get rid of noat +.set at + lbu $t2, __osIntOffTable($t2) + lw $t2, __osIntTable($t2) +.set noat jr $t2 nop -#if defined(VERSION_EU) || defined(VERSION_SH) -glabel L802F3B28 - li $at, -8193 - b .L8032692C +#ifdef VERSION_EU_SH_CN +glabel IP6_Hdlr + li $at, ~CAUSE_IP6 + b next_interrupt and $s0, $s0, $at -glabel L802F3B34 - li $at, -16385 - b .L8032692C +glabel IP7_Hdlr + li $at, ~CAUSE_IP7 + b next_interrupt and $s0, $s0, $at #endif -glabel L80326964 - mfc0 $t1, $11 - mtc0 $t1, $11 +glabel counter + mfc0 $t1, C0_COMPARE + mtc0 $t1, C0_COMPARE +#ifdef VERSION_CN + li $a0, 24 + jal send_mesg + nop +#else jal send_mesg li $a0, 24 - lui $at, (0xFFFF7FFF >> 16) - ori $at, (0xFFFF7FFF & 0xFFFF) - b .L8032692C +#endif + lui $at, (~CAUSE_IP8 >> 16) & 0xFFFF + ori $at, (~CAUSE_IP8 & 0xFFFF) + b next_interrupt and $s0, $s0, $at -glabel L80326984 -#if defined(VERSION_EU) || defined(VERSION_SH) - li $at, -2049 + +glabel cart +#ifdef VERSION_EU_SH_CN + li $at, ~CAUSE_IP4 and $s0, $s0, $at #endif +#ifdef VERSION_CN + la $t1, __osHwIntTable + addi $t1, $t1, 4 * 2 + lw $t2, ($t1) + beqz $t2, .L80307480 + nop + jalr $t2 + lw $sp, 4($t1) + beqz $v0, .L80307480 + nop + b redispatch + nop +.L80307480: + lui $s1, %hi(PHYS_TO_K1(MI_HW_INTR_REG)) + lw $s1, %lo(PHYS_TO_K1(MI_HW_INTR_REG))($s1) + andi $t1, $s1, 0x40 + beqz $t1, .L803074AC + nop + andi $s1, $s1, 0x3F80 + li $t1, 0 + lui $at, %hi(PHYS_TO_K1(PI_CARD_ADDR_REG)) + sw $t1, %lo(PHYS_TO_K1(PI_CARD_ADDR_REG))($at) + jal send_mesg + li $a0, 184 +.L803074AC: + andi $t1, $s1, 0x2000 + beqz $t1, .L803074D0 + nop + andi $s1, $s1, 0x1FC0 + li $t1, 0x2000 + lui $at, %hi(PHYS_TO_K1(MI_HW_INTR_REG)) + sw $t1, %lo(PHYS_TO_K1(MI_HW_INTR_REG))($at) + jal send_mesg + li $a0, 240 +.L803074D0: + andi $t1, $s1, 0x80 + beqz $t1, .L803074F4 + nop + andi $s1, $s1, 0x3F40 + li $t1, 0x4000 + lui $at, %hi(PHYS_TO_K1(MI_HW_INTR_MASK_REG)) + sw $t1, %lo(PHYS_TO_K1(MI_HW_INTR_MASK_REG))($at) + jal send_mesg + li $a0, 192 +.L803074F4: + andi $t1, $s1, 0x100 + beqz $t1, .L80307518 + nop + andi $s1, $s1, 0x3EC0 + lui $t1, 1 + lui $at, %hi(PHYS_TO_K1(MI_HW_INTR_MASK_REG)) + sw $t1, %lo(PHYS_TO_K1(MI_HW_INTR_MASK_REG))($at) + jal send_mesg + li $a0, 200 +.L80307518: + andi $t1, $s1, 0x200 + beqz $t1, .L8030753C + nop + andi $s1, $s1, 0x3DC0 + lui $t1, 4 + lui $at, %hi(PHYS_TO_K1(MI_HW_INTR_MASK_REG)) + sw $t1, %lo(PHYS_TO_K1(MI_HW_INTR_MASK_REG))($at) + jal send_mesg + li $a0, 208 +.L8030753C: + andi $t1, $s1, 0x400 + beqz $t1, .L80307560 + nop + andi $s1, $s1, 0x3BC0 + lui $t1, 0x10 + lui $at, %hi(PHYS_TO_K1(MI_HW_INTR_MASK_REG)) + sw $t1, %lo(PHYS_TO_K1(MI_HW_INTR_MASK_REG))($at) + jal send_mesg + li $a0, 216 +.L80307560: + andi $t1, $s1, 0x800 + beqz $t1, .L80307584 + nop + andi $s1, $s1, 0x37C0 + lui $t1, 0x40 + lui $at, %hi(PHYS_TO_K1(MI_HW_INTR_MASK_REG)) + sw $t1, %lo(PHYS_TO_K1(MI_HW_INTR_MASK_REG))($at) + jal send_mesg + li $a0, 224 +.L80307584: + b next_interrupt + nop +#else li $t2, 4 - lui $at, %hi(D_80334920) + lui $at, %hi(__osHwIntTable) addu $at, $at, $t2 - lw $t2, %lo(D_80334920)($at) -#if defined(VERSION_EU) || defined(VERSION_SH) - lui $sp, %hi(leoDiskStack) - addiu $sp, %lo(leoDiskStack) + lw $t2, %lo(__osHwIntTable)($at) +#ifdef VERSION_EU_SH + la $sp, leoDiskStack li $a0, 16 beqz $t2, .L803269A4 addiu $sp, $sp, 0xff0 @@ -299,202 +438,302 @@ glabel L80326984 nop #endif jalr $t2 - nop -#if defined(VERSION_EU) || defined(VERSION_SH) + nop +#ifdef VERSION_EU_SH beqz $v0, .L803269A4 #ifdef VERSION_SH li $a0, 0x10 #else nop #endif - b .L80326B9C + b redispatch nop #endif .L803269A4: jal send_mesg -#if defined(VERSION_EU) || defined(VERSION_SH) +#ifdef VERSION_EU_SH nop - b .L8032692C + b next_interrupt nop #else li $a0, 16 li $at, -2049 - b .L8032692C + b next_interrupt and $s0, $s0, $at #endif -glabel L803269B8 -#if defined(VERSION_EU) || defined(VERSION_SH) - lui $t0, %hi(__OSGlobalIntMask) - addiu $t0, %lo(__OSGlobalIntMask) +#endif +glabel rcp +#ifdef VERSION_EU_SH + la $t0, __OSGlobalIntMask lw $t0, ($t0) #endif - lui $s1, %hi(MI_INTR_REG) - lw $s1, %lo(MI_INTR_REG)($s1) -#if defined(VERSION_EU) || defined(VERSION_SH) + lui $s1, %hi(PHYS_TO_K1(MI_INTR_REG)) + lw $s1, %lo(PHYS_TO_K1(MI_INTR_REG))($s1) +#ifdef VERSION_CN + la $t0, __OSGlobalIntMask + lw $t0, ($t0) +#endif +#ifdef VERSION_EU_SH_CN srl $t0, $t0, 0x10 and $s1, $s1, $t0 #else andi $s1, $s1, 0x3f #endif - andi $t1, $s1, 1 - beqz $t1, .L80326A18 + andi $t1, $s1, MI_INTR_SP + beqz $t1, vi nop - lui $t4, %hi(SP_STATUS_REG) - lw $t4, %lo(SP_STATUS_REG)($t4) - li $t1, 8 - lui $at, %hi(SP_STATUS_REG) +#ifdef VERSION_CN + andi $s1, $s1, 0x3e +#endif + lui $t4, %hi(PHYS_TO_K1(SP_STATUS_REG)) + lw $t4, %lo(PHYS_TO_K1(SP_STATUS_REG))($t4) +#ifdef VERSION_CN + li $t1, SP_CLR_INTR | SP_CLR_SIG3 +#else + li $t1, SP_CLR_INTR +#endif + lui $at, %hi(PHYS_TO_K1(SP_STATUS_REG)) +#ifdef VERSION_CN + sw $t1, %lo(PHYS_TO_K1(SP_STATUS_REG))($at) + andi $t4, $t4, 0x300 + beqz $t4, sp_other_break + nop +#else andi $t4, $t4, 0x300 andi $s1, $s1, 0x3e - beqz $t4, .L80326A08 - sw $t1, %lo(SP_STATUS_REG)($at) + beqz $t4, sp_other_break + sw $t1, %lo(PHYS_TO_K1(SP_STATUS_REG))($at) +#endif jal send_mesg li $a0, 32 - beqz $s1, .L80326ADC + beqz $s1, no_more_rcp_ints nop - b .L80326A18 + b vi nop -.L80326A08: +sp_other_break: jal send_mesg li $a0, 88 - beqz $s1, .L80326ADC + beqz $s1, no_more_rcp_ints nop -.L80326A18: +vi: andi $t1, $s1, 8 - beqz $t1, .L80326A3C - lui $at, %hi(VI_CURRENT_REG) + beqz $t1, ai +#ifdef VERSION_CN + nop andi $s1, $s1, 0x37 - sw $zero, %lo(VI_CURRENT_REG)($at) + lui $at, %hi(PHYS_TO_K1(VI_CURRENT_REG)) +#else + lui $at, %hi(PHYS_TO_K1(VI_CURRENT_REG)) + andi $s1, $s1, 0x37 +#endif + sw $zero, %lo(PHYS_TO_K1(VI_CURRENT_REG))($at) jal send_mesg li $a0, 56 - beqz $s1, .L80326ADC + beqz $s1, no_more_rcp_ints nop -.L80326A3C: +ai: andi $t1, $s1, 4 - beqz $t1, .L80326A68 + beqz $t1, si nop - li $t1, 1 - lui $at, %hi(AI_STATUS_REG) +#ifdef VERSION_CN andi $s1, $s1, 0x3b - sw $t1, %lo(AI_STATUS_REG)($at) +#endif + li $t1, 1 + lui $at, %hi(PHYS_TO_K1(AI_STATUS_REG)) +#ifndef VERSION_CN + andi $s1, $s1, 0x3b +#endif + sw $t1, %lo(PHYS_TO_K1(AI_STATUS_REG))($at) jal send_mesg li $a0, 48 - beqz $s1, .L80326ADC + beqz $s1, no_more_rcp_ints nop -.L80326A68: +si: andi $t1, $s1, 2 - beqz $t1, .L80326A8C - lui $at, %hi(SI_STATUS_REG) + beqz $t1, pi +#ifdef VERSION_CN + nop +#else + lui $at, %hi(PHYS_TO_K1(SI_STATUS_REG)) +#endif andi $s1, $s1, 0x3d - sw $zero, %lo(SI_STATUS_REG)($at) +#ifdef VERSION_CN + lui $at, %hi(PHYS_TO_K1(SI_STATUS_REG)) +#endif + sw $zero, %lo(PHYS_TO_K1(SI_STATUS_REG))($at) jal send_mesg li $a0, 40 - beqz $s1, .L80326ADC + beqz $s1, no_more_rcp_ints nop -.L80326A8C: +pi: andi $t1, $s1, 0x10 - beqz $t1, .L80326AB8 + beqz $t1, dp nop - li $t1, 2 - lui $at, %hi(PI_STATUS_REG) +#ifdef VERSION_CN andi $s1, $s1, 0x2f - sw $t1, %lo(PI_STATUS_REG)($at) + li $t1, 2 + lui $at, %hi(PHYS_TO_K1(PI_STATUS_REG)) + sw $t1, %lo(PHYS_TO_K1(PI_STATUS_REG))($at) + la $t1, D_CN_80319658 + lw $t2, ($t1) + beqz $t2, .L803076C0 + nop + lw $sp, 4($t1) + jalr $t2 + move $a0, $v0 + bnez $v0, .L803076C8 + nop +.L803076C0: +#else + li $t1, 2 + lui $at, %hi(PHYS_TO_K1(PI_STATUS_REG)) + andi $s1, $s1, 0x2f + sw $t1, %lo(PHYS_TO_K1(PI_STATUS_REG))($at) +#endif jal send_mesg li $a0, 64 - beqz $s1, .L80326ADC +.L803076C8: + beqz $s1, no_more_rcp_ints nop -.L80326AB8: +dp: andi $t1, $s1, 0x20 - beqz $t1, .L80326ADC + beqz $t1, no_more_rcp_ints nop - li $t1, 2048 - lui $at, %hi(MI_MODE_REG) +#ifdef VERSION_CN andi $s1, $s1, 0x1f - sw $t1, %lo(MI_MODE_REG)($at) +#endif + li $t1, MI_CLR_DP_INTR + lui $at, %hi(PHYS_TO_K1(MI_MODE_REG)) +#ifndef VERSION_CN + andi $s1, $s1, 0x1f +#endif + sw $t1, %lo(PHYS_TO_K1(MI_MODE_REG))($at) jal send_mesg li $a0, 72 -.L80326ADC: +no_more_rcp_ints: li $at, -1025 - b .L8032692C + b next_interrupt and $s0, $s0, $at -glabel L80326AE8 +glabel prenmi lw $k1, 0x118($k0) li $at, -4097 - lui $t1, %hi(D_80334808) +#ifdef VERSION_CN and $k1, $k1, $at sw $k1, 0x118($k0) - addiu $t1, %lo(D_80334808) + la $t1, __osShutdown +#else + lui $t1, %hi(__osShutdown) + and $k1, $k1, $at + sw $k1, 0x118($k0) + addiu $t1, %lo(__osShutdown) +#endif lw $t2, ($t1) - beqz $t2, .L80326B14 + beqz $t2, firstnmi +#ifdef VERSION_CN + nop +#endif li $at, -4097 - b .L80326B9C + b redispatch and $s0, $s0, $at -.L80326B14: +firstnmi: li $t2, 1 sw $t2, ($t1) jal send_mesg li $a0, 112 - lui $t2, %hi(D_80334890 + 0x8) - lw $t2, %lo(D_80334890 + 0x8)($t2) +#ifdef VERSION_CN li $at, -4097 and $s0, $s0, $at +#endif + lui $t2, %hi(__osThreadTail + 0x8) + lw $t2, %lo(__osThreadTail + 0x8)($t2) +#ifndef VERSION_CN + li $at, -4097 + and $s0, $s0, $at +#endif lw $k1, 0x118($t2) +#ifdef VERSION_CN + li $at, -4097 +#endif and $k1, $k1, $at - b .L80326B9C + b redispatch sw $k1, 0x118($t2) -glabel L80326B44 +glabel sw2 li $at, -513 and $t0, $t0, $at mtc0 $t0, $13 +#ifdef VERSION_CN + li $a0, 8 + jal send_mesg + nop +#else jal send_mesg li $a0, 8 +#endif li $at, -513 - b .L8032692C + b next_interrupt and $s0, $s0, $at -glabel L80326B64 +glabel sw1 li $at, -257 and $t0, $t0, $at mtc0 $t0, $13 +#ifdef VERSION_CN + li $a0, 0 + jal send_mesg + nop +#else jal send_mesg li $a0, 0 +#endif li $at, -257 - b .L8032692C + b next_interrupt and $s0, $s0, $at -.L80326B84: +handle_break: li $t1, 1 sh $t1, 0x12($k0) jal send_mesg li $a0, 80 - b .L80326B9C + b redispatch nop -.L80326B9C: -glabel L80326B9C - lui $t2, %hi(D_80334890 + 0x8) - lw $t2, %lo(D_80334890 + 0x8)($t2) +glabel redispatch +#ifdef VERSION_CN + lw $t1, 4($k0) + lui $t2, %hi(__osThreadTail + 0x8) + lw $t2, %lo(__osThreadTail + 0x8)($t2) + lw $t3, 4($t2) + slt $at, $t1, $t3 + beqz $at, enqueue_running + nop + move $a1, $k0 + la $a0, __osThreadTail + 0x8 + jal __osEnqueueThread + nop +#else + lui $t2, %hi(__osThreadTail + 0x8) + lw $t2, %lo(__osThreadTail + 0x8)($t2) lw $t1, 4($k0) lw $t3, 4($t2) slt $at, $t1, $t3 - beqz $at, .L80326BD0 + beqz $at, enqueue_running nop - lui $a0, %hi(D_80334890 + 0x8) + lui $a0, %hi(__osThreadTail + 0x8) move $a1, $k0 jal __osEnqueueThread - addiu $a0, %lo(D_80334890 + 0x8) + addiu $a0, %lo(__osThreadTail + 0x8) +#endif j __osDispatchThread nop -.L80326BD0: - lui $t1, %hi(D_80334890 + 0x8) - addiu $t1, %lo(D_80334890 + 0x8) +enqueue_running: + la $t1, __osThreadTail + 0x8 lw $t2, ($t1) sw $t2, ($k0) j __osDispatchThread sw $k0, ($t1) -.L80326BE8: -glabel L80326BE8 - lui $at, %hi(D_80334890 + 0x14) - sw $k0, %lo(D_80334890 + 0x14)($at) +glabel panic + lui $at, %hi(__osThreadTail + 0x14) + sw $k0, %lo(__osThreadTail + 0x14)($at) li $t1, 1 sh $t1, 0x10($k0) li $t1, 2 @@ -507,11 +746,15 @@ glabel L80326BE8 nop glabel send_mesg - lui $t2, %hi(__osEventStateTab) - addiu $t2, %lo(__osEventStateTab) +#ifdef VERSION_CN + move $s2, $ra +#endif + la $t2, __osEventStateTab addu $t2, $t2, $a0 lw $t1, ($t2) +#ifndef VERSION_CN move $s2, $ra +#endif beqz $t1, .L80326CC4 nop lw $t3, 8($t1) @@ -521,9 +764,14 @@ glabel send_mesg nop lw $t5, 0xc($t1) addu $t5, $t5, $t3 +#ifdef VERSION_CN + bnez $t4, .L80326C60 + div $zero, $t5, $t4 +#else div $zero, $t5, $t4 bnez $t4, .L80326C60 nop +#endif break 7 .L80326C60: li $at, -1 @@ -533,13 +781,26 @@ glabel send_mesg nop break 6 .L80326C78: +#ifdef VERSION_CN + mfhi $t5 + lw $t4, 0x14($t1) + li $at, 4 + mult $t5, $at + mflo $t5 +#else lw $t4, 0x14($t1) mfhi $t5 sll $t5, $t5, 2 +#endif addu $t4, $t4, $t5 lw $t5, 4($t2) +#ifdef VERSION_CN + sw $t5, ($t4) + addiu $t2, $t3, 1 +#else addiu $t2, $t3, 1 sw $t5, ($t4) +#endif sw $t2, 8($t1) lw $t2, ($t1) lw $t3, ($t2) @@ -548,34 +809,51 @@ glabel send_mesg jal __osPopThread move $a0, $t1 move $t2, $v0 - lui $a0, %hi(D_80334890 + 0x8) +#ifdef VERSION_CN + move $a1, $t2 + la $a0, __osThreadTail + 0x8 + jal __osEnqueueThread + nop +#else + lui $a0, %hi(__osThreadTail + 0x8) move $a1, $t2 jal __osEnqueueThread - addiu $a0, %lo(D_80334890 + 0x8) + addiu $a0, %lo(__osThreadTail + 0x8) +#endif .L80326CC4: jr $s2 nop -.L80326CCC: +handle_CpU: // coprocessor error lui $at, 0x3000 and $t1, $t0, $at srl $t1, $t1, 0x1c li $t2, 1 - bne $t1, $t2, .L80326BE8 + bne $t1, $t2, panic nop +#ifdef VERSION_CN + li $t1, 1 + sw $t1, 0x18($k0) + lw $k1, 0x118($k0) + lui $at, 0x2000 + or $k1, $k1, $at +#else lw $k1, 0x118($k0) lui $at, 0x2000 li $t1, 1 or $k1, $k1, $at sw $t1, 0x18($k0) - b .L80326BD0 +#endif + b enqueue_running sw $k1, 0x118($k0) glabel __osEnqueueAndYield - lui $a1, %hi(D_80334890 + 0x10) - lw $a1, %lo(D_80334890 + 0x10)($a1) + lui $a1, %hi(__osThreadTail + 0x10) + lw $a1, %lo(__osThreadTail + 0x10)($a1) mfc0 $t0, $12 +#ifndef VERSION_CN lw $k1, 0x18($a1) +#endif ori $t0, $t0, 2 sw $t0, 0x118($a1) sd $s0, 0x98($a1) @@ -590,50 +868,73 @@ glabel __osEnqueueAndYield sd $sp, 0xf0($a1) sd $fp, 0xf8($a1) sd $ra, 0x100($a1) +#ifdef VERSION_CN + sw $ra, 0x11c($a1) + lw $k1, 0x18($a1) + beqz $k1, .L80326D70 + nop + cfc1 $k1, $31 + sw $k1, 0x12c($a1) +#else beqz $k1, .L80326D70 sw $ra, 0x11c($a1) cfc1 $k1, $31 +#endif sdc1 $f20, 0x180($a1) sdc1 $f22, 0x188($a1) sdc1 $f24, 0x190($a1) sdc1 $f26, 0x198($a1) sdc1 $f28, 0x1a0($a1) sdc1 $f30, 0x1a8($a1) +#ifndef VERSION_CN sw $k1, 0x12c($a1) +#endif .L80326D70: -#if defined(VERSION_EU) || defined(VERSION_SH) +#ifdef VERSION_EU_SH_CN lw $k1, 0x118($a1) andi $t1, $k1, 0xff00 beqz $t1, .L802F3FBC nop - lui $t0, %hi(__OSGlobalIntMask) - addiu $t0, %lo(__OSGlobalIntMask) + la $t0, __OSGlobalIntMask lw $t0, ($t0) - li $at, -1 + li $at, 0xFFFFFFFF xor $t0, $t0, $at - lui $at, (0xFFFF00FF >> 16) - andi $t0, $t0, 0xff00 - ori $at, (0xFFFF00FF & 0xFFFF) +#ifdef VERSION_CN + andi $t0, $t0, SR_IMASK or $t1, $t1, $t0 + li $at, ~SR_IMASK +#else + lui $at, (~SR_IMASK >> 16) & 0xFFFF + andi $t0, $t0, SR_IMASK + ori $at, (~SR_IMASK & 0xFFFF) + or $t1, $t1, $t0 +#endif and $k1, $k1, $at or $k1, $k1, $t1 sw $k1, 0x118($a1) .L802F3FBC: #endif - lui $k1, %hi(MI_INTR_MASK_REG) - lw $k1, %lo(MI_INTR_MASK_REG)($k1) -#if defined(VERSION_EU) || defined(VERSION_SH) + lui $k1, %hi(PHYS_TO_K1(MI_INTR_MASK_REG)) + lw $k1, %lo(PHYS_TO_K1(MI_INTR_MASK_REG))($k1) +#ifdef VERSION_EU_SH_CN beqz $k1, .L802F3FF4 nop - lui $k0, %hi(__OSGlobalIntMask) - addiu $k0, %lo(__OSGlobalIntMask) + la $k0, __OSGlobalIntMask lw $k0, ($k0) +#ifdef VERSION_CN + srl $k0, $k0, 0x10 + li $at, 0xFFFFFFFF + xor $k0, $k0, $at + andi $k0, $k0, 0x3f lw $t0, 0x128($a1) - li $at, -1 +#else + lw $t0, 0x128($a1) + li $at, 0xFFFFFFFF srl $k0, $k0, 0x10 xor $k0, $k0, $at andi $k0, $k0, 0x3f +#endif and $k0, $k0, $t0 or $k1, $k1, $k0 .L802F3FF4: @@ -648,9 +949,14 @@ glabel __osEnqueueAndYield // enqueue and pop look like compiled functions? but there's no easy way to extract them glabel __osEnqueueThread +#ifdef VERSION_CN + move $t9, $a0 +#endif lw $t8, ($a0) lw $t7, 4($a1) +#ifndef VERSION_CN move $t9, $a0 +#endif lw $t6, 4($t8) slt $at, $t6, $t7 bnez $at, .L80326DC4 @@ -675,35 +981,61 @@ glabel __osPopThread jr $ra sw $t9, ($a0) +#ifdef VERSION_CN +func_unused: + jr $ra + nop +#endif + glabel __osDispatchThread - lui $a0, %hi(D_80334890 + 0x8) +#ifdef VERSION_CN + la $a0, __osThreadTail + 0x8 jal __osPopThread - addiu $a0, %lo(D_80334890 + 0x8) - lui $at, %hi(D_80334890 + 0x10) - sw $v0, %lo(D_80334890 + 0x10)($at) + nop +#else + lui $a0, %hi(__osThreadTail + 0x8) + jal __osPopThread + addiu $a0, %lo(__osThreadTail + 0x8) +#endif + lui $at, %hi(__osThreadTail + 0x10) + sw $v0, %lo(__osThreadTail + 0x10)($at) li $t0, 4 sh $t0, 0x10($v0) move $k0, $v0 -#if defined(VERSION_EU) || defined(VERSION_SH) +#ifdef VERSION_EU_SH_CN +#ifdef VERSION_CN + lw $k1, 0x118($k0) + la $t0, __OSGlobalIntMask + lw $t0, ($t0) + andi $t0, $t0, SR_IMASK + andi $t1, $k1, SR_IMASK + and $t1, $t1, $t0 + li $at, ~SR_IMASK +#else lui $t0, %hi(__OSGlobalIntMask) lw $k1, 0x118($k0) addiu $t0, %lo(__OSGlobalIntMask) lw $t0, ($t0) - lui $at, (0xFFFF00FF >> 16) - andi $t1, $k1, 0xff00 - ori $at, (0xFFFF00FF & 0xFFFF) - andi $t0, $t0, 0xff00 + lui $at, (~SR_IMASK >> 16) & 0xFFFF + andi $t1, $k1, SR_IMASK + ori $at, (~SR_IMASK & 0xFFFF) + andi $t0, $t0, SR_IMASK and $t1, $t1, $t0 +#endif and $k1, $k1, $at or $k1, $k1, $t1 mtc0 $k1, $12 #endif .L80326E08: +#ifndef VERSION_CN ld $k1, 0x108($k0) +#endif ld $at, 0x20($k0) ld $v0, 0x28($k0) +#ifndef VERSION_CN mtlo $k1 ld $k1, 0x110($k0) +#endif ld $v1, 0x30($k0) ld $a0, 0x38($k0) ld $a1, 0x40($k0) @@ -728,13 +1060,21 @@ glabel __osDispatchThread ld $t8, 0xd8($k0) ld $t9, 0xe0($k0) ld $gp, 0xe8($k0) +#ifndef VERSION_CN mthi $k1 +#endif ld $sp, 0xf0($k0) ld $fp, 0xf8($k0) ld $ra, 0x100($k0) +#ifdef VERSION_CN + ld $k1, 0x108($k0) + mtlo $k1 + ld $k1, 0x110($k0) + mthi $k1 +#endif lw $k1, 0x11c($k0) mtc0 $k1, $14 -#if !defined(VERSION_EU) && !defined(VERSION_SH) +#ifndef VERSION_EU_SH_CN lw $k1, 0x118($k0) mtc0 $k1, $12 #endif @@ -761,20 +1101,23 @@ glabel __osDispatchThread ldc1 $f30, 0x1a8($k0) .L80326EF0: lw $k1, 0x128($k0) -#if defined(VERSION_EU) || defined(VERSION_SH) - lui $k0, %hi(__OSGlobalIntMask) - addiu $k0, %lo(__OSGlobalIntMask) +#ifdef VERSION_EU_SH_CN + la $k0, __OSGlobalIntMask lw $k0, ($k0) srl $k0, $k0, 0x10 and $k1, $k1, $k0 #endif sll $k1, $k1, 1 - lui $k0, %hi(D_803386D0) - addiu $k0, %lo(D_803386D0) + la $k0, __osRcpImTable addu $k1, $k1, $k0 lhu $k1, ($k1) - lui $k0, %hi(MI_INTR_MASK_REG) - addiu $k0, %lo(MI_INTR_MASK_REG) +#ifdef VERSION_CN + li $k0, PHYS_TO_K1(MI_INTR_MASK_REG) +#else + // TODO: is this an la? + lui $k0, %hi(PHYS_TO_K1(MI_INTR_MASK_REG)) + addiu $k0, %lo(PHYS_TO_K1(MI_INTR_MASK_REG)) +#endif sw $k1, ($k0) nop nop @@ -787,40 +1130,54 @@ glabel __osCleanupThread .section .data -glabel D_80334920 +glabel __osHwIntTable + .word 0 + .word 0 + .word 0 + .word 0 + .word 0 +#ifdef VERSION_CN + // CN: table is now 2 words per entry (handler, sp) .word 0 .word 0 .word 0 .word 0 .word 0 +// Is this part of __osHwIntTable? +glabel D_CN_80319658 + .word 0 +#endif + +#ifndef VERSION_EU_SH_CN glabel D_80334934 .word 0 glabel D_80334938 .word 0 .word 0 +#endif .section .rodata -glabel D_80338610 +glabel __osIntOffTable .byte 0x00,0x14,0x18,0x18,0x1C,0x1C,0x1C,0x1C,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x00,0x04,0x08,0x08,0x0C,0x0C,0x0C,0x0C,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10 -glabel jtbl_80338630 - .word L80326B9C - .word L80326B64 - .word L80326B44 - .word L803269B8 - .word L80326984 - .word L80326AE8 -#if defined(VERSION_EU) || defined(VERSION_SH) - .word L802F3B28 - .word L802F3B34 +glabel __osIntTable + .word redispatch + .word sw1 + .word sw2 + .word rcp + .word cart + .word prenmi +#ifdef VERSION_EU_SH_CN + .word IP6_Hdlr + .word IP7_Hdlr #else - .word L80326BE8 - .word L80326BE8 + .word panic + .word panic #endif - .word L80326964 + .word counter .word 0 .word 0 .word 0 diff --git a/lib/asm/__osGetCause.s b/lib/asm/__osGetCause.s index 56371707..770e2edb 100644 --- a/lib/asm/__osGetCause.s +++ b/lib/asm/__osGetCause.s @@ -1,5 +1,4 @@ .set noreorder // don't insert nops after branches -.set gp=64 #include "macros.inc" diff --git a/lib/asm/__osGetSR.s b/lib/asm/__osGetSR.s index 0ed57883..96d71a8a 100644 --- a/lib/asm/__osGetSR.s +++ b/lib/asm/__osGetSR.s @@ -1,5 +1,4 @@ .set noreorder // don't insert nops after branches -.set gp=64 #include "macros.inc" diff --git a/lib/asm/__osProbeTLB.s b/lib/asm/__osProbeTLB.s index 5f955bc9..e6369c93 100644 --- a/lib/asm/__osProbeTLB.s +++ b/lib/asm/__osProbeTLB.s @@ -1,6 +1,5 @@ .set noat // allow manual use of $at .set noreorder // don't insert nops after branches -.set gp=64 #include "macros.inc" @@ -10,7 +9,7 @@ glabel __osProbeTLB mfc0 $t0, $10 andi $t1, $t0, 0xff - li $at, -8192 + li $at, 0xFFFFE000 and $t2, $a0, $at or $t1, $t1, $t2 mtc0 $t1, $10 @@ -58,7 +57,3 @@ glabel __osProbeTLB mtc0 $t0, $10 jr $ra nop - - nop - nop - diff --git a/lib/asm/__osRestoreInt.s b/lib/asm/__osRestoreInt.s index 9b2c80ff..5d11c9f2 100644 --- a/lib/asm/__osRestoreInt.s +++ b/lib/asm/__osRestoreInt.s @@ -1,19 +1,16 @@ .set noreorder // don't insert nops after branches -.set gp=64 #include "macros.inc" +#include .section .text, "ax" glabel __osRestoreInt - mfc0 $t0, $12 + mfc0 $t0, C0_SR or $t0, $t0, $a0 - mtc0 $t0, $12 + mtc0 $t0, C0_SR nop nop jr $ra nop - - nop - diff --git a/lib/asm/__osSetCompare.s b/lib/asm/__osSetCompare.s index 2df90585..df66a566 100644 --- a/lib/asm/__osSetCompare.s +++ b/lib/asm/__osSetCompare.s @@ -1,15 +1,65 @@ +.set noat .set noreorder // don't insert nops after branches -.set gp=64 #include "macros.inc" +#include + .section .text, "ax" +#ifdef VERSION_CN + glabel __osSetCompare - mtc0 $a0, $11 + addiu $sp, $sp, -0x38 + sd $ra, 0x30($sp) + sd $fp, 0x28($sp) + move $fp, $sp + sw $a0, 0x3c($fp) + lw $v0, 0x3c($fp) + beqz $v0, .L8030A25C + nop + jal __osDisableInt + nop + sw $v0, 0x20($fp) + lw $v0, 0x3c($fp) + lui $v1, %hi(sLastHighestCount2) # $v1, 0x8032 + lw $v1, %lo(sLastHighestCount2)($v1) + sltu $v0, $v0, $v1 + lui $v1, %hi(sNumCountOverflows2) # $v1, 0x8032 + lw $v1, %lo(sNumCountOverflows2)($v1) + addu $v0, $v0, $v1 + sw $v0, 0x24($fp) + lwu $v0, 0x24($fp) + dsll32 $v1, $v0, 0 + lwu $a0, 0x3c($fp) + or $v0, $v1, $a0 + move $a0, $v0 + dsll $v1, $a0, 1 + daddu $v1, $v1, $v0 + dsll $a0, $v1, 6 + li $at, 125 + ddivu $zero, $a0, $at + mflo $v0 + dsll32 $v0, $v0, 0 + dsra32 $v0, $v0, 0 + sw $v0, 0x3c($fp) + jal __osRestoreInt + lw $a0, 0x20($fp) +.L8030A25C: + lw $a1, 0x3c($fp) + mtc0 $a1, C0_COMPARE + move $sp, $fp + ld $ra, 0x30($sp) + ld $fp, 0x28($sp) + jr $ra + addiu $sp, $sp, 0x38 + +#else + +glabel __osSetCompare + mtc0 $a0, C0_COMPARE jr $ra nop - nop - +#endif diff --git a/lib/asm/__osSetFpcCsr.s b/lib/asm/__osSetFpcCsr.s index 0d5e75bc..c11fcd85 100644 --- a/lib/asm/__osSetFpcCsr.s +++ b/lib/asm/__osSetFpcCsr.s @@ -1,5 +1,4 @@ .set noreorder // don't insert nops after branches -.set gp=64 #include "macros.inc" diff --git a/lib/asm/__osSetSR.s b/lib/asm/__osSetSR.s index 00544244..fc89627f 100644 --- a/lib/asm/__osSetSR.s +++ b/lib/asm/__osSetSR.s @@ -1,5 +1,4 @@ .set noreorder // don't insert nops after branches -.set gp=64 #include "macros.inc" diff --git a/lib/asm/__osSetWatchLo.s b/lib/asm/__osSetWatchLo.s new file mode 100644 index 00000000..48e0667d --- /dev/null +++ b/lib/asm/__osSetWatchLo.s @@ -0,0 +1,13 @@ +.set noreorder // don't insert nops after branches + +#include "macros.inc" + + +.section .text, "ax" + +glabel __osSetWatchLo + mtc0 $a0, $18 + nop + jr $ra + nop + diff --git a/lib/asm/__os_eu_802ef550.s b/lib/asm/__os_eu_802ef550.s index 4f723ddb..15ac8f3f 100644 --- a/lib/asm/__os_eu_802ef550.s +++ b/lib/asm/__os_eu_802ef550.s @@ -1,6 +1,5 @@ -.set noreorder // don't insert nops after branches -.set gp=64 .set noat +.set noreorder // don't insert nops after branches #include "macros.inc" diff --git a/lib/asm/bcopy.s b/lib/asm/bcopy.s index e4f26909..859455c9 100644 --- a/lib/asm/bcopy.s +++ b/lib/asm/bcopy.s @@ -1,27 +1,45 @@ .set noat // allow manual use of $at .set noreorder // don't insert nops after branches -.set gp=64 #include "macros.inc" .section .text, "ax" +//TODO There seem to be patterns in these iQue diffs. Can we figure out what's causing them? Could this have been written in C? +//also ifdef hell lol + glabel bcopy beqz $a2, .L80323A4C move $a3, $a1 +#ifdef VERSION_CN + beq $a0, $a1, .L80323A4C + nop + slt $at, $a1, $a0 + bnez $at, .L80323A14 + nop + add $v0, $a0, $a2 + slt $at, $a1, $v0 + beqz $at, .L80323A14 + nop + b .L80323B78 + nop +.L80323A14: + slti $at, $a2, 0x10 +#else beq $a0, $a1, .L80323A4C slt $at, $a1, $a0 bnezl $at, .L80323A14 slti $at, $a2, 0x10 add $v0, $a0, $a2 slt $at, $a1, $v0 - beql $at, $zero, .L80323A14 + beqzl $at, .L80323A14 slti $at, $a2, 0x10 b .L80323B78 slti $at, $a2, 0x10 slti $at, $a2, 0x10 .L80323A14: +#endif bnez $at, .L80323A2C nop andi $v0, $a0, 3 @@ -35,14 +53,38 @@ glabel bcopy .L80323A38: lb $v0, ($a0) addiu $a0, $a0, 1 +#ifdef VERSION_CN + sb $v0, ($a1) + bne $a0, $v1, .L80323A38 + addiu $a1, $a1, 1 +#else addiu $a1, $a1, 1 bne $a0, $v1, .L80323A38 sb $v0, -1($a1) +#endif .L80323A4C: jr $ra move $v0, $a3 .L80323A54: +#ifdef VERSION_CN + beqz $v0, .L80323AB8 + nop + li $at, 1 + beq $v0, $at, .L80323A9C + nop + li $at, 2 + beq $v0, $at, .L80323A88 + nop + lb $v0, ($a0) + addiu $a0, $a0, 1 + sb $v0, ($a1) + addiu $a1, $a1, 1 + b .L80323AB8 + addiu $a2, $a2, -1 +.L80323A88: + lh $v0, ($a0) +#else beqz $v0, .L80323AB8 li $at, 1 beq $v0, $at, .L80323A9C @@ -57,23 +99,42 @@ glabel bcopy sb $v0, -1($a1) lh $v0, ($a0) .L80323A88: +#endif addiu $a0, $a0, 2 +#ifdef VERSION_CN + sh $v0, ($a1) + addiu $a1, $a1, 2 + b .L80323AB8 + addiu $a2, $a2, -2 +#else addiu $a1, $a1, 2 addiu $a2, $a2, -2 b .L80323AB8 sh $v0, -2($a1) +#endif .L80323A9C: lb $v0, ($a0) lh $v1, 1($a0) addiu $a0, $a0, 3 +#ifdef VERSION_CN + sb $v0, ($a1) + sh $v1, 1($a1) +#endif addiu $a1, $a1, 3 addiu $a2, $a2, -3 +#ifndef VERSION_CN sb $v0, -3($a1) sh $v1, -2($a1) +#endif .L80323AB8: slti $at, $a2, 0x20 +#ifdef VERSION_CN + bnez $at, .L80323B14 + nop +#else bnezl $at, .L80323B18 slti $at, $a2, 0x10 +#endif lw $v0, ($a0) lw $v1, 4($a0) lw $t0, 8($a0) @@ -83,7 +144,18 @@ glabel bcopy lw $t4, 0x18($a0) lw $t5, 0x1c($a0) addiu $a0, $a0, 0x20 +#ifdef VERSION_CN + sw $v0, ($a1) + sw $v1, 4($a1) + sw $t0, 8($a1) + sw $t1, 0xc($a1) + sw $t2, 0x10($a1) + sw $t3, 0x14($a1) + sw $t4, 0x18($a1) + sw $t5, 0x1c($a1) +#endif addiu $a1, $a1, 0x20 +#ifndef VERSION_CN addiu $a2, $a2, -0x20 sw $v0, -0x20($a1) sw $v1, -0x1c($a1) @@ -92,25 +164,47 @@ glabel bcopy sw $t2, -0x10($a1) sw $t3, -0xc($a1) sw $t4, -8($a1) +#endif b .L80323AB8 +#ifdef VERSION_CN + addiu $a2, $a2, -0x20 +#else sw $t5, -4($a1) +#endif .L80323B14: slti $at, $a2, 0x10 .L80323B18: +#ifdef VERSION_CN + bnez $at, .L80323B50 + nop +#else bnezl $at, .L80323B54 slti $at, $a2, 4 +#endif lw $v0, ($a0) lw $v1, 4($a0) lw $t0, 8($a0) lw $t1, 0xc($a0) addiu $a0, $a0, 0x10 +#ifdef VERSION_CN + sw $v0, ($a1) + sw $v1, 4($a1) + sw $t0, 8($a1) + sw $t1, 0xc($a1) +#endif addiu $a1, $a1, 0x10 +#ifndef VERSION_CN addiu $a2, $a2, -0x10 sw $v0, -0x10($a1) sw $v1, -0xc($a1) sw $t0, -8($a1) +#endif b .L80323B14 +#ifdef VERSION_CN + addiu $a2, $a2, -0x10 +#else sw $t1, -4($a1) +#endif .L80323B50: slti $at, $a2, 4 .L80323B54: @@ -118,15 +212,32 @@ glabel bcopy nop lw $v0, ($a0) addiu $a0, $a0, 4 +#ifdef VERSION_CN + sw $v0, ($a1) +#endif addiu $a1, $a1, 4 +#ifndef VERSION_CN addiu $a2, $a2, -4 +#endif b .L80323B50 +#ifdef VERSION_CN + addiu $a2, $a2, -4 +#else sw $v0, -4($a1) slti $at, $a2, 0x10 +#endif .L80323B78: add $a0, $a0, $a2 +#ifdef VERSION_CN + add $a1, $a1, $a2 + slti $at, $a2, 0x10 +#endif bnez $at, .L80323B94 +#ifdef VERSION_CN + nop +#else add $a1, $a1, $a2 +#endif andi $v0, $a0, 3 andi $v1, $a1, 3 beq $v0, $v1, .L80323BC4 @@ -140,44 +251,94 @@ glabel bcopy .L80323BA8: lb $v0, ($a0) addiu $a0, $a0, -1 +#ifdef VERSION_CN + sb $v0, 0($a1) +#else addiu $a1, $a1, -1 +#endif bne $a0, $v1, .L80323BA8 +#ifdef VERSION_CN + addiu $a1, $a1, -1 +#else sb $v0, 1($a1) +#endif jr $ra move $v0, $a3 .L80323BC4: beqz $v0, .L80323C28 +#ifdef VERSION_CN + nop +#endif li $at, 3 beq $v0, $at, .L80323C0C +#ifdef VERSION_CN + nop +#endif li $at, 2 +#ifdef VERSION_CN + beq $v0, $at, .L80323BF4 + nop +#else beql $v0, $at, .L80323BF8 lh $v0, -2($a0) +#endif lb $v0, -1($a0) addiu $a0, $a0, -1 +#ifdef VERSION_CN + sb $v0, -1($a1) +#endif addiu $a1, $a1, -1 +#ifndef VERSION_CN addiu $a2, $a2, -1 +#endif b .L80323C28 +#ifdef VERSION_CN + addiu $a2, $a2, -1 +#else sb $v0, ($a1) +#endif +.L80323BF4: lh $v0, -2($a0) .L80323BF8: addiu $a0, $a0, -2 +#ifdef VERSION_CN + sh $v0, -2($a1) +#endif addiu $a1, $a1, -2 +#ifndef VERSION_CN addiu $a2, $a2, -2 +#endif b .L80323C28 +#ifdef VERSION_CN + addiu $a2, $a2, -2 +#else sh $v0, ($a1) +#endif .L80323C0C: lb $v0, -1($a0) lh $v1, -3($a0) addiu $a0, $a0, -3 +#ifdef VERSION_CN + sb $v0, -1($a1) + sh $v1, -3($a1) + addiu $a1, $a1, -3 + addiu $a2, $a2, -3 +#else addiu $a1, $a1, -3 addiu $a2, $a2, -3 sb $v0, 2($a1) sh $v1, ($a1) +#endif .L80323C28: slti $at, $a2, 0x20 +#ifdef VERSION_CN + bnez $at, .L80323C84 + nop +#else bnezl $at, .L80323C88 slti $at, $a2, 0x10 +#endif lw $v0, -4($a0) lw $v1, -8($a0) lw $t0, -0xc($a0) @@ -187,6 +348,17 @@ glabel bcopy lw $t4, -0x1c($a0) lw $t5, -0x20($a0) addiu $a0, $a0, -0x20 +#ifdef VERSION_CN + sw $v0, -4($a1) + sw $v1, -8($a1) + sw $t0, -0xc($a1) + sw $t1, -0x10($a1) + sw $t2, -0x14($a1) + sw $t3, -0x18($a1) + sw $t4, -0x1c($a1) + sw $t5, -0x20($a1) + addiu $a1, $a1, -0x20 +#else addiu $a1, $a1, -0x20 addiu $a2, $a2, -0x20 sw $v0, 0x1c($a1) @@ -196,25 +368,47 @@ glabel bcopy sw $t2, 0xc($a1) sw $t3, 8($a1) sw $t4, 4($a1) +#endif b .L80323C28 +#ifdef VERSION_CN + addiu $a2, $a2, -0x20 +#else sw $t5, ($a1) +#endif .L80323C84: slti $at, $a2, 0x10 .L80323C88: +#ifdef VERSION_CN + bnez $at, .L80323CC0 + nop +#else bnezl $at, .L80323CC4 slti $at, $a2, 4 +#endif lw $v0, -4($a0) lw $v1, -8($a0) lw $t0, -0xc($a0) lw $t1, -0x10($a0) addiu $a0, $a0, -0x10 +#ifdef VERSION_CN + sw $v0, -4($a1) + sw $v1, -8($a1) + sw $t0, -0xc($a1) + sw $t1, -0x10($a1) + addiu $a1, $a1, -0x10 +#else addiu $a1, $a1, -0x10 addiu $a2, $a2, -0x10 sw $v0, 0xc($a1) sw $v1, 8($a1) sw $t0, 4($a1) +#endif b .L80323C84 +#ifdef VERSION_CN + addiu $a2, $a2, -0x10 +#else sw $t1, ($a1) +#endif .L80323CC0: slti $at, $a2, 4 .L80323CC4: @@ -222,11 +416,19 @@ glabel bcopy nop lw $v0, -4($a0) addiu $a0, $a0, -4 +#ifdef VERSION_CN + sw $v0, -4($a1) +#endif addiu $a1, $a1, -4 +#ifndef VERSION_CN addiu $a2, $a2, -4 +#endif b .L80323CC0 +#ifdef VERSION_CN + addiu $a2, $a2, -4 +#else sw $v0, ($a1) nop nop nop - +#endif diff --git a/lib/asm/bzero.s b/lib/asm/bzero.s index 1e073acb..cc542f67 100644 --- a/lib/asm/bzero.s +++ b/lib/asm/bzero.s @@ -1,13 +1,61 @@ .set noreorder // don't insert nops after branches -.set gp=64 #include "macros.inc" // this file is probably handwritten +//TODO There seem to be patterns in these iQue diffs. Can we figure out what's causing them? Could this have been written in C? See also bcopy.s. + .section .text, "ax" glabel bzero + +#ifdef VERSION_CN + negu $v1, $a0 + blt $a1, 0xc, .L80303790 + nop + andi $v1, $v1, 3 + beqz $v1, .L80303734 + subu $a1, $a1, $v1 + swl $zero, ($a0) + addu $a0, $a0, $v1 +.L80303734: + and $a3, $a1, -32 + beqz $a3, .L80303770 + subu $a1, $a1, $a3 + addu $a3, $a3, $a0 +.L80303748: + sw $zero, ($a0) + sw $zero, 4($a0) + sw $zero, 8($a0) + sw $zero, 0xc($a0) + addiu $a0, $a0, 0x20 + sw $zero, -0x10($a0) + sw $zero, -0xc($a0) + sw $zero, -8($a0) + bne $a0, $a3, .L80303748 + sw $zero, -4($a0) +.L80303770: + and $a3, $a1, -4 + beqz $a3, .L80303790 + subu $a1, $a1, $a3 + addu $a3, $a3, $a0 +.L80303784: + addiu $a0, $a0, 4 + bne $a0, $a3, .L80303784 + sw $zero, -4($a0) +.L80303790: + blez $a1, .L803037A8 + nop + addu $a1, $a1, $a0 +.L8030379C: + addiu $a0, $a0, 1 + bne $a0, $a1, .L8030379C + sb $zero, -1($a0) +.L803037A8: + jr $ra + nop +#else blt $a1, 0xc, .L803236BC negu $v1, $a0 andi $v1, $v1, 3 @@ -50,4 +98,5 @@ glabel bzero sb $zero, -1($a0) .L803236D4: jr $ra +#endif diff --git a/lib/asm/guMtxF2L.s b/lib/asm/guMtxF2L.s new file mode 100644 index 00000000..481213e3 --- /dev/null +++ b/lib/asm/guMtxF2L.s @@ -0,0 +1,46 @@ +.set noat +.set noreorder // don't insert nops after branches + +#include "macros.inc" + + +.section .text, "ax" + +#ifdef VERSION_CN + +.balign 32 + +glabel guMtxF2L + li $at, 0x47800000 // 65536.000000 + mtc1 $at, $f0 + lui $t9, 0xffff + addiu $t8, $a1, 0x20 +.L80306C70: + lwc1 $f4, ($a0) + mul.s $f6, $f4, $f0 + trunc.w.s $f8, $f6 + lwc1 $f10, 4($a0) + mul.s $f16, $f10, $f0 + trunc.w.s $f18, $f16 + mfc1 $t0, $f8 + mfc1 $t1, $f18 + and $t2, $t0, $t9 + srl $t3, $t1, 0x10 + or $t4, $t2, $t3 + sw $t4, ($a1) + sll $t5, $t0, 0x10 + andi $t6, $t1, 0xffff + or $t7, $t5, $t6 + sw $t7, 0x20($a1) + addiu $a1, $a1, 4 + bne $a1, $t8, .L80306C70 + addiu $a0, $a0, 8 + jr $ra + nop + + nop + nop + nop + nop + +#endif diff --git a/lib/asm/guMtxIdentF.s b/lib/asm/guMtxIdentF.s new file mode 100644 index 00000000..8cbb4d49 --- /dev/null +++ b/lib/asm/guMtxIdentF.s @@ -0,0 +1,32 @@ +.set noreorder // don't insert nops after branches + +#include "macros.inc" + + +.section .text, "ax" + +#ifdef VERSION_CN + +.balign 32 + +glabel guMtxIdentF + lui $t0, 0x3f80 + sw $t0, ($a0) + sw $zero, 4($a0) + sw $zero, 8($a0) + sw $zero, 0xc($a0) + sw $zero, 0x10($a0) + sw $t0, 0x14($a0) + sw $zero, 0x18($a0) + sw $zero, 0x1c($a0) + sw $zero, 0x20($a0) + sw $zero, 0x24($a0) + sw $t0, 0x28($a0) + sw $zero, 0x2c($a0) + sw $zero, 0x30($a0) + sw $zero, 0x34($a0) + sw $zero, 0x38($a0) + jr $ra + sw $t0, 0x3c($a0) + +#endif diff --git a/lib/asm/guNormalize.s b/lib/asm/guNormalize.s new file mode 100644 index 00000000..a02ad034 --- /dev/null +++ b/lib/asm/guNormalize.s @@ -0,0 +1,33 @@ +.set noreorder // don't insert nops after branches + +#include "macros.inc" + + +.section .text, "ax" + +#ifdef VERSION_CN + +glabel guNormalize + lwc1 $f4, ($a0) + lwc1 $f6, ($a1) + lwc1 $f8, ($a2) + mul.s $f10, $f4, $f4 + li $t0, 0x3F800000 # 1.000000 + mul.s $f16, $f6, $f6 + add.s $f18, $f10, $f16 + mul.s $f16, $f8, $f8 + add.s $f10, $f16, $f18 + mtc1 $t0, $f18 + sqrt.s $f16, $f10 + div.s $f10, $f18, $f16 + mul.s $f16, $f4, $f10 + nop + mul.s $f18, $f6, $f10 + nop + mul.s $f4, $f8, $f10 + swc1 $f16, ($a0) + swc1 $f18, ($a1) + jr $ra + swc1 $f4, ($a2) + +#endif diff --git a/lib/asm/guScale.s b/lib/asm/guScale.s new file mode 100644 index 00000000..c315e4c7 --- /dev/null +++ b/lib/asm/guScale.s @@ -0,0 +1,55 @@ +.set noat +.set noreorder // don't insert nops after branches + +#include "macros.inc" + + +.section .text, "ax" + +#ifdef VERSION_CN + +.balign 32 + +glabel guScale + li $at, 0x47800000 // 65536.000000 + mtc1 $at, $f4 + mtc1 $a1, $f6 + mul.s $f8, $f6, $f4 + trunc.w.s $f10, $f8 + mfc1 $t1, $f10 + srl $t2, $t1, 0x10 + sll $t0, $t2, 0x10 + sw $t0, ($a0) + sll $t2, $t1, 0x10 + sw $t2, 0x20($a0) + mtc1 $a2, $f6 + mul.s $f8, $f6, $f4 + trunc.w.s $f10, $f8 + mfc1 $t1, $f10 + srl $t0, $t1, 0x10 + sw $t0, 8($a0) + andi $t2, $t1, 0xffff + sw $t2, 0x28($a0) + mtc1 $a3, $f6 + mul.s $f8, $f6, $f4 + trunc.w.s $f10, $f8 + mfc1 $t1, $f10 + srl $t2, $t1, 0x10 + sll $t0, $t2, 0x10 + sw $t0, 0x14($a0) + sll $t2, $t1, 0x10 + sw $t2, 0x34($a0) + li $t0, 1 + sw $t0, 0x1c($a0) + sw $zero, 4($a0) + sw $zero, 0xc($a0) + sw $zero, 0x10($a0) + sw $zero, 0x18($a0) + sw $zero, 0x24($a0) + sw $zero, 0x2c($a0) + sw $zero, 0x30($a0) + sw $zero, 0x38($a0) + jr $ra + sw $zero, 0x3c($a0) + +#endif diff --git a/lib/asm/guTranslate.s b/lib/asm/guTranslate.s new file mode 100644 index 00000000..c0e02559 --- /dev/null +++ b/lib/asm/guTranslate.s @@ -0,0 +1,65 @@ +.set noat +.set noreorder // don't insert nops after branches + +#include "macros.inc" + + +.section .text, "ax" + +#ifdef VERSION_CN + +.balign 16 + +glabel guTranslate + li $at, 0x47800000 // 65536.000000 + mtc1 $at, $f4 + mtc1 $a1, $f6 + mul.s $f8, $f6, $f4 + trunc.w.s $f10, $f8 + mfc1 $t1, $f10 + mtc1 $a2, $f6 + mul.s $f8, $f6, $f4 + trunc.w.s $f10, $f8 + mfc1 $t3, $f10 + srl $t2, $t1, 0x10 + sll $t0, $t2, 0x10 + srl $t2, $t3, 0x10 + or $t0, $t0, $t2 + sw $t0, 0x18($a0) + sll $t0, $t1, 0x10 + sll $t2, $t3, 0x10 + srl $t2, $t2, 0x10 + or $t0, $t0, $t2 + sw $t0, 0x38($a0) + mtc1 $a3, $f6 + mul.s $f8, $f6, $f4 + trunc.w.s $f10, $f8 + mfc1 $t1, $f10 + srl $t2, $t1, 0x10 + sll $t0, $t2, 0x10 + addiu $t0, $t0, 1 + sw $t0, 0x1c($a0) + sll $t2, $t1, 0x10 + sw $t2, 0x3c($a0) + sw $zero, ($a0) + sw $zero, 4($a0) + sw $zero, 8($a0) + sw $zero, 0xc($a0) + sw $zero, 0x10($a0) + sw $zero, 0x14($a0) + sw $zero, 0x20($a0) + sw $zero, 0x24($a0) + sw $zero, 0x28($a0) + sw $zero, 0x2c($a0) + sw $zero, 0x30($a0) + sw $zero, 0x34($a0) + lui $t0, 1 + ori $t0, $t0, 0 + sw $t0, ($a0) + sw $t0, 0x14($a0) + lui $t0, (0x00000001 >> 16) # lui $t0, 0 + ori $t0, (0x00000001 & 0xFFFF) # ori $t0, $t0, 1 + jr $ra + sw $t0, 8($a0) + +#endif diff --git a/lib/asm/iQueKernelCalls.s b/lib/asm/iQueKernelCalls.s new file mode 100644 index 00000000..9dcde049 --- /dev/null +++ b/lib/asm/iQueKernelCalls.s @@ -0,0 +1,42 @@ +.set noat +.set noreorder // don't insert nops after branches + +#include "macros.inc" + +.macro def label, num + glabel \label + li $v0, \num + lui $t0, (0xA4300014 >> 16) + ori $t0, (0xA4300014 & 0xFFFF) + lw $t1, ($t0) // traps the iQue OS and performs the function + nop + jr $ra + nop +.endm + + +.section .text, "ax" + +def skGetId, 0x0 +def skLaunchSetup, 0x1 +def skLaunch, 0x2 +def skRecryptListValid, 0x3 +def skRecryptBegin, 0x4 +def skRecryptData, 0x5 +def skRecryptComputeState, 0x6 +def skRecryptEnd, 0x7 +def skSignHash, 0x8 +def skVerifyHash, 0x9 +def skGetConsumption, 0xa +def skAdvanceTicketWindow, 0xb +def skSetLimit, 0xc +def skExit, 0xd +def skKeepAlive, 0xe + +// developer calls +def sk0f, 0x0f +def sk10, 0x10 +def sk11, 0x11 +def sk12, 0x12 +def sk13, 0x13 +def sk14, 0x14 diff --git a/lib/asm/llmuldiv_gcc.s b/lib/asm/llmuldiv_gcc.s index 1582f878..9ef338ee 100644 --- a/lib/asm/llmuldiv_gcc.s +++ b/lib/asm/llmuldiv_gcc.s @@ -1,10 +1,11 @@ // assembler directives .set noat // allow manual use of $at .set noreorder // don't insert nops after branches -.set gp=64 #include "macros.inc" +#ifndef VERSION_CN + .section .text, "ax" @@ -98,3 +99,5 @@ glabel __divdi3 dsra32 $v1, $v1, 0 jr $ra dsra32 $v0, $v0, 0 + +#endif diff --git a/lib/asm/osGetCount.s b/lib/asm/osGetCount.s index b47b66ae..aa4f3316 100644 --- a/lib/asm/osGetCount.s +++ b/lib/asm/osGetCount.s @@ -1,11 +1,78 @@ .set noreorder // don't insert nops after branches -.set gp=64 #include "macros.inc" - .section .text, "ax" +#ifdef VERSION_CN + +glabel osGetCount + addiu $sp, $sp, -0x38 + sd $ra, 0x30($sp) + sd $fp, 0x28($sp) + jal __osDisableInt + move $fp, $sp + sw $v0, 0x24($fp) + mfc0 $a1, $9 + sw $a1, 0x20($fp) + lw $v0, 0x20($fp) + lui $v1, %hi(sLastHighestCount) # $v1, 0x8032 + lw $v1, %lo(sLastHighestCount)($v1) + sltu $v0, $v0, $v1 + beqz $v0, .L80304FCC + nop + lui $v0, %hi(sNumCountOverflows) # $v0, 0x8032 + lw $v0, %lo(sNumCountOverflows)($v0) + addiu $v1, $v0, 1 + sw $v1, sNumCountOverflows +.L80304FCC: + lw $v0, 0x20($fp) + sw $v0, sLastHighestCount + lui $v0, %hi(sNumCountOverflows) // $v0, 0x8032 + lwu $v0, %lo(sNumCountOverflows)($v0) + dsll32 $v1, $v0, 0 + lwu $a0, 0x20($fp) + or $v0, $v1, $a0 + move $a0, $v0 + dsll $v1, $a0, 5 + dsubu $v1, $v1, $v0 + dsll $a0, $v1, 2 + daddu $a0, $a0, $v0 +.set noat // gas seems to add an extra mflo $zero after, if we don't manually use $at + li $at, 192 + ddivu $zero, $a0, $at +.set at + mflo $v0 + dsll32 $v0, $v0, 0 + dsra32 $v0, $v0, 0 + sw $v0, 0x20($fp) + lw $v0, 0x20($fp) + lui $v1, %hi(sLastHighestCount2) // $v1, 0x8032 + lw $v1, %lo(sLastHighestCount2)($v1) + sltu $v0, $v0, $v1 + beqz $v0, .L80305044 + nop + lui $v0, %hi(sNumCountOverflows2) // $v0, 0x8032 + lw $v0, %lo(sNumCountOverflows2)($v0) + addiu $v1, $v0, 1 + sw $v1, sNumCountOverflows2 +.L80305044: + lw $v0, 0x20($fp) + sw $v0, sLastHighestCount2 + jal __osRestoreInt + lw $a0, 0x24($fp) + lw $v1, 0x20($fp) + j .L80305064 + move $v0, $v1 +.L80305064: + move $sp, $fp + ld $ra, 0x30($sp) + ld $fp, 0x28($sp) + jr $ra + addiu $sp, $sp, 0x38 + +#else + glabel osGetCount mfc0 $v0, $9 jr $ra @@ -13,3 +80,4 @@ glabel osGetCount nop +#endif diff --git a/lib/asm/osInvalDCache.s b/lib/asm/osInvalDCache.s index dca94af6..54bba4e8 100644 --- a/lib/asm/osInvalDCache.s +++ b/lib/asm/osInvalDCache.s @@ -1,6 +1,5 @@ .set noat // allow manual use of $at .set noreorder // don't insert nops after branches -.set gp=64 #include "macros.inc" @@ -9,42 +8,49 @@ glabel osInvalDCache blez $a1, .L80323500 - nop + nop li $t3, 8192 sltu $at, $a1, $t3 beqz $at, .L80323508 - nop + nop move $t0, $a0 addu $t1, $a0, $a1 sltu $at, $t0, $t1 beqz $at, .L80323500 - nop + nop +#ifdef VERSION_CN + addiu $t1, $t1, -0x10 andi $t2, $t0, 0xf beqz $t2, .L803234D0 - addiu $t1, $t1, -0x10 + nop +#else + andi $t2, $t0, 0xf + beqz $t2, .L803234D0 + addiu $t1, $t1, -0x10 +#endif subu $t0, $t0, $t2 cache 0x15, ($t0) sltu $at, $t0, $t1 beqz $at, .L80323500 - nop + nop addiu $t0, $t0, 0x10 .L803234D0: andi $t2, $t1, 0xf beqz $t2, .L803234F0 - nop + nop subu $t1, $t1, $t2 cache 0x15, 0x10($t1) sltu $at, $t1, $t0 bnez $at, .L80323500 - nop + nop .L803234F0: cache 0x11, ($t0) sltu $at, $t0, $t1 bnez $at, .L803234F0 - addiu $t0, $t0, 0x10 + addiu $t0, $t0, 0x10 .L80323500: jr $ra - nop + nop .L80323508: li $t0, K0BASE diff --git a/lib/asm/osInvalICache.s b/lib/asm/osInvalICache.s index fd9ea6a7..1d92d4df 100644 --- a/lib/asm/osInvalICache.s +++ b/lib/asm/osInvalICache.s @@ -1,6 +1,5 @@ .set noat // allow manual use of $at .set noreorder // don't insert nops after branches -.set gp=64 #include "macros.inc" @@ -19,8 +18,13 @@ glabel osInvalICache sltu $at, $t0, $t1 beqz $at, .L80323728 nop +#ifdef VERSION_CN + addiu $t1, $t1, -0x20 + andi $t2, $t0, 0x1f +#else andi $t2, $t0, 0x1f addiu $t1, $t1, -0x20 +#endif subu $t0, $t0, $t2 .L80323718: cache 0x10, ($t0) diff --git a/lib/asm/osMapTLB.s b/lib/asm/osMapTLB.s index 1910cd9d..891e4f11 100644 --- a/lib/asm/osMapTLB.s +++ b/lib/asm/osMapTLB.s @@ -1,5 +1,4 @@ .set noreorder // don't insert nops after branches -.set gp=64 #include "macros.inc" diff --git a/lib/asm/osMapTLBRdb.s b/lib/asm/osMapTLBRdb.s index 4bcba1d1..04c13e2a 100644 --- a/lib/asm/osMapTLBRdb.s +++ b/lib/asm/osMapTLBRdb.s @@ -1,6 +1,5 @@ .set noat // allow manual use of $at .set noreorder // don't insert nops after branches -.set gp=64 #include "macros.inc" diff --git a/lib/asm/osSetIntMask.s b/lib/asm/osSetIntMask.s index 6ea380e5..d5d70da6 100644 --- a/lib/asm/osSetIntMask.s +++ b/lib/asm/osSetIntMask.s @@ -1,34 +1,35 @@ .set noat // allow manual use of $at .set noreorder // don't insert nops after branches -.set gp=64 #include "macros.inc" -.eqv MI_INTR_MASK_REG, 0xA430000C +#include +#include +#include .section .text, "ax" glabel osSetIntMask -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) mfc0 $t4, $12 - andi $v0, $t4, 0xff01 + andi $v0, $t4, OS_IM_CPU lui $t0, %hi(__OSGlobalIntMask) // $t0, 0x8030 addiu $t0, %lo(__OSGlobalIntMask) // addiu $t0, $t0, 0x208c lw $t3, ($t0) - li $at, -1 + li $at, 0xFFFFFFFF xor $t0, $t3, $at - andi $t0, $t0, 0xff00 + andi $t0, $t0, SR_IMASK or $v0, $v0, $t0 #else mfc0 $t1, $12 - andi $v0, $t1, 0xff01 + andi $v0, $t1, OS_IM_CPU #endif - lui $t2, %hi(MI_INTR_MASK_REG) // $t2, 0xa430 - lw $t2, %lo(MI_INTR_MASK_REG)($t2) -#if defined(VERSION_EU) || defined(VERSION_SH) + lui $t2, %hi(PHYS_TO_K1(MI_INTR_MASK_REG)) // $t2, 0xa430 + lw $t2, %lo(PHYS_TO_K1(MI_INTR_MASK_REG))($t2) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) beqz $t2, .L80200074 srl $t1, $t3, 0x10 - li $at, -1 + li $at, 0xFFFFFFFF xor $t1, $t1, $at andi $t1, $t1, 0x3f or $t2, $t2, $t1 @@ -38,23 +39,23 @@ glabel osSetIntMask or $v0, $v0, $t2 lui $at, 0x3f and $t0, $a0, $at -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) and $t0, $t0, $t3 #endif srl $t0, $t0, 0xf - lui $t2, %hi(D_803386D0) + lui $t2, %hi(__osRcpImTable) addu $t2, $t2, $t0 - lhu $t2, %lo(D_803386D0)($t2) - lui $at, %hi(MI_INTR_MASK_REG) // $at, 0xa430 - sw $t2, %lo(MI_INTR_MASK_REG)($at) - andi $t0, $a0, 0xff01 -#if defined(VERSION_EU) || defined(VERSION_SH) + lhu $t2, %lo(__osRcpImTable)($t2) + lui $at, %hi(PHYS_TO_K1(MI_INTR_MASK_REG)) // $at, 0xa430 + sw $t2, %lo(PHYS_TO_K1(MI_INTR_MASK_REG))($at) + andi $t0, $a0, OS_IM_CPU +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) andi $t1, $t3, 0xff00 and $t0, $t0, $t1 #endif lui $at, (0xFFFF00FF >> 16) // lui $at, 0xffff ori $at, (0xFFFF00FF & 0xFFFF) // ori $at, $at, 0xff -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) and $t4, $t4, $at or $t4, $t4, $t0 mtc0 $t4, $12 @@ -71,7 +72,7 @@ glabel osSetIntMask .section .rodata -glabel D_803386D0 +glabel __osRcpImTable .half 0x0555 .half 0x0556 .half 0x0559 diff --git a/lib/asm/osUnmapTLBAll.s b/lib/asm/osUnmapTLBAll.s index 1548c162..ff692c3f 100644 --- a/lib/asm/osUnmapTLBAll.s +++ b/lib/asm/osUnmapTLBAll.s @@ -1,5 +1,4 @@ .set noreorder // don't insert nops after branches -.set gp=64 #include "macros.inc" @@ -8,7 +7,11 @@ glabel osUnmapTLBAll mfc0 $t0, $10 +#ifdef VERSION_CN + li $t1, 30 +#else li $t1, 31 +#endif lui $t2, 0x8000 mtc0 $t2, $10 mtc0 $zero, $2 @@ -20,13 +23,12 @@ glabel osUnmapTLBAll nop nop addi $t1, $t1, -1 +#ifdef VERSION_CN + bgez $t1, .L80321588 +#else bnezl $t1, .L80321588 #bnezl, bnez but with likely hint +#endif nop mtc0 $t0, $10 jr $ra nop - - nop - nop - nop - diff --git a/lib/asm/osWritebackDCache.s b/lib/asm/osWritebackDCache.s index e4a2ab0c..3d506ecb 100644 --- a/lib/asm/osWritebackDCache.s +++ b/lib/asm/osWritebackDCache.s @@ -1,5 +1,4 @@ .set noreorder // don't insert nops after branches -.set gp=64 #include "macros.inc" @@ -16,8 +15,13 @@ glabel osWritebackDCache addu $t1, $a0, $a1 bgeu $t0, $t1, .osWritebackDCacheReturn nop +#ifdef VERSION_CN + addiu $t1, $t1, -0x10 + andi $t2, $t0, 0xf +#else andi $t2, $t0, 0xf addiu $t1, $t1, -0x10 +#endif subu $t0, $t0, $t2 .L80324E28: cache 0x19, ($t0) diff --git a/lib/asm/osWritebackDCacheAll.s b/lib/asm/osWritebackDCacheAll.s index bb5fa41d..d194e8f7 100644 --- a/lib/asm/osWritebackDCacheAll.s +++ b/lib/asm/osWritebackDCacheAll.s @@ -1,6 +1,5 @@ .set noat // allow manual use of $at .set noreorder // don't insert nops after branches -.set gp=64 #include "macros.inc" diff --git a/lib/asm/parameters.s b/lib/asm/parameters.s index 5b402250..0921794c 100644 --- a/lib/asm/parameters.s +++ b/lib/asm/parameters.s @@ -1,6 +1,6 @@ .macro gsymbol sym addr .global \sym -.set \sym, \addr +.equ \sym, \addr #ifndef VERSION_JP nop nop @@ -16,7 +16,7 @@ gsymbol osCiCId 0x80000310 gsymbol osVersion 0x80000314 gsymbol osMemSize 0x80000318 gsymbol osAppNmiBuffer 0x8000031C -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) nop nop nop @@ -25,4 +25,10 @@ nop nop nop nop +#ifdef VERSION_CN +nop +nop +nop +nop +#endif #endif diff --git a/lib/asm/sqrtf.s b/lib/asm/sqrtf.s index 70984e56..91cd3eb5 100644 --- a/lib/asm/sqrtf.s +++ b/lib/asm/sqrtf.s @@ -1,6 +1,5 @@ .set noat // allow manual use of $at .set noreorder // don't insert nops after branches -.set gp=64 #include "macros.inc" diff --git a/lib/src/D_802F4380.c b/lib/src/D_802F4380.c deleted file mode 100644 index 7183ab1d..00000000 --- a/lib/src/D_802F4380.c +++ /dev/null @@ -1,147 +0,0 @@ -#include "libultra_internal.h" -#include "hardware.h" -#include "new_func.h" -#include "macros.h" - -#if defined(VERSION_EU) -u32 D_802F4380() { - u32 sp3c; - u32 sp38; - u32 sp34; - __OSTranxInfo *sp30; - __OSBlockInfo *sp2c; - u32 sp28; - UNUSED __OSBlockInfo *sp24; - if (!EU_D_80302090) { - return 0; - } - sp30 = &__osDiskHandle->transferInfo; - sp2c = &sp30->block[sp30->blockNum]; - sp38 = HW_REG(PI_STATUS_REG, u32); - if (sp38 & PI_STATUS_BUSY) { - HW_REG(PI_STATUS_REG, u32) = PI_STATUS_RESET_CONTROLLER | PI_STATUS_CLEAR_INTR; - WAIT_ON_IOBUSY(sp38); - sp3c = HW_REG(ASIC_STATUS, u32); - if (sp3c & MECHANIC_INTERRUPT) { - WAIT_ON_IOBUSY(sp38); - HW_REG(ASIC_BM_CTL, u32) = sp30->bmCtlShadow | MECHANIC_INTERRUPT_RESET; - } - sp30->errStatus = 75; - func_802F4A20(); - return 1; - } - WAIT_ON_IOBUSY(sp38); - sp3c = HW_REG(ASIC_STATUS, u32); - if (sp3c & MECHANIC_INTERRUPT) { - WAIT_ON_IOBUSY(sp38); - HW_REG(ASIC_BM_CTL, u32) = sp30->bmCtlShadow | MECHANIC_INTERRUPT_RESET; - sp30->errStatus = 0; - return 0; - } - if (sp3c & BUFFER_MANAGER_ERROR) { - sp30->errStatus = 3; - func_802F4A20(); - return 1; - } - if (sp30->cmdType == 1) { - if ((sp3c & DATA_REQUEST) == 0) { - if (sp30->sectorNum + 1 != sp30->transferMode * 85) { - sp30->errStatus = 6; - func_802F4A20(); - return 1; - } - HW_REG(PI_STATUS_REG, u32) = PI_STATUS_CLEAR_INTR; - __OSGlobalIntMask |= 0x00100401; - sp30->errStatus = 0; - func_802F4B08(); - return 1; - } - sp2c->dramAddr = (void *) ((u32) sp2c->dramAddr + sp2c->sectorSize); - sp30->sectorNum++; - osEPiRawStartDma(__osDiskHandle, 1, 0x05000400, sp2c->dramAddr, sp2c->sectorSize); - return 1; - } - if (sp30->cmdType == 0) { - if (sp30->transferMode == 3) { - if ((s32)(sp2c->C1ErrNum + 17) < sp30->sectorNum) { - sp30->errStatus = 0; - func_802F4A20(); - return 1; - } - if ((sp3c & DATA_REQUEST) == 0) { - sp30->errStatus = 17; - func_802F4A20(); - return 1; - } - } else { - sp2c->dramAddr = (void *) ((u32) sp2c->dramAddr + sp2c->sectorSize); - } - sp34 = HW_REG(ASIC_BM_STATUS, u32); - if (((C1_SINGLE & sp34) && (C1_DOUBLE & sp34)) || (sp34 & MICRO_STATUS)) { - if (sp2c->C1ErrNum > 3) { - if (sp30->transferMode != 3 || sp30->sectorNum > 0x52) { - sp30->errStatus = 17; - func_802F4A20(); - return 1; - } - } else { - sp28 = sp2c->C1ErrNum; - sp2c->C1ErrSector[sp28] = sp30->sectorNum + 1; - } - sp2c->C1ErrNum++; - } - if (sp3c & C2_TRANSFER) { - if (sp30->sectorNum != 87) { - sp30->errStatus = 6; - func_802F4A20(); - } - if (sp30->transferMode == 2 && sp30->blockNum == 0) { - sp30->blockNum = 1; - sp30->sectorNum = -1; - sp30->block[1].dramAddr = - (void *) ((u32) sp30->block[1].dramAddr - sp30->block[1].sectorSize); - } else { - HW_REG(PI_STATUS_REG, u32) = PI_STATUS_CLEAR_INTR; - __OSGlobalIntMask |= 0x00100401; - } - osEPiRawStartDma(__osDiskHandle, 0, 0x5000000, sp2c->C2Addr, sp2c->sectorSize * 4); - sp30->errStatus = 0; - return 1; - } - - if (sp30->sectorNum == -1 && sp30->transferMode == 2 && sp30->blockNum == 1) { - sp24 = &sp30->block[0]; - if (sp30->block[0].C1ErrNum == 0) { - if (((u32 *) sp30->block[0].C2Addr)[0] | ((u32 *) sp30->block[0].C2Addr)[1] - | ((u32 *) sp30->block[0].C2Addr)[2] | ((u32 *) sp30->block[0].C2Addr)[3]) { - sp30->errStatus = 6; - func_802F4A20(); - return 1; - } - } - sp30->errStatus = 0; - func_802F4B08(); - } - sp30->sectorNum++; - if (sp3c & DATA_REQUEST) { - if (sp30->sectorNum > 0x54) { - sp30->errStatus = 6; - func_802F4A20(); - return 1; - } - osEPiRawStartDma(__osDiskHandle, 0, 0x05000400, sp2c->dramAddr, sp2c->sectorSize); - sp30->errStatus = 0; - return 1; - } - if (sp30->sectorNum <= 0x54) { - sp30->errStatus = 6; - func_802F4A20(); - return 1; - } - return 1; - } - sp30->errStatus = 75; - func_802F4A20(); - return 1; -} -#endif diff --git a/lib/src/EU_D_802f4330.c b/lib/src/EU_D_802f4330.c deleted file mode 100644 index ad9b3bac..00000000 --- a/lib/src/EU_D_802f4330.c +++ /dev/null @@ -1,12 +0,0 @@ -#include "libultra_internal.h" - -// an array of pointers to functions taking no arguments and returning u32... -// this is only referenced in the exception handler and here. this function is called with a0=1 and -// then the same memory address is loaded. it's definitely an array access though.. -extern u32 (*D_80334920[8])(void) ; - -void EU_D_802f4330(u32 a0, u32 a1(void)) { - register u32 int_disabled = __osDisableInt(); - D_80334920[a0] = a1; - __osRestoreInt(int_disabled); -} diff --git a/lib/src/_Ldtob.c b/lib/src/_Ldtob.c index 3656bd45..ab1067ad 100644 --- a/lib/src/_Ldtob.c +++ b/lib/src/_Ldtob.c @@ -7,9 +7,9 @@ #define BUFF_LEN 0x20 static s16 _Ldunscale(s16 *, printf_struct *); -static void _Genld(printf_struct *, u8, u8 *, s16, s16); +static void _Genld(printf_struct *, fmt_type, fmt_type *, s16, s16); -const double D_80338670[] = { 10e0L, 10e1L, 10e3L, 10e7L, 10e15L, 10e31L, 10e63L, 10e127L, 10e255L }; +const double pows[] = { 10e0L, 10e1L, 10e3L, 10e7L, 10e15L, 10e31L, 10e63L, 10e127L, 10e255L }; /* float properties */ #define _D0 0 @@ -44,10 +44,9 @@ const double D_80338670[] = { 10e0L, 10e1L, 10e3L, 10e7L, 10e15L, 10e31L, 10e63L #define _D3 3 #endif -void _Ldtob(printf_struct *args, u8 type) { - u8 buff[BUFF_LEN]; - u8 *ptr; - UNUSED u32 sp70; +void _Ldtob(printf_struct *args, fmt_type type) { + fmt_type buff[BUFF_LEN]; + fmt_type *ptr; f64 val; /* maybe struct? */ s16 err; @@ -59,12 +58,7 @@ void _Ldtob(printf_struct *args, u8 type) { f64 factor; s32 gen; s32 j; - s32 lo; - ldiv_t qr; - u8 drop; - s32 n2; - /* */ - UNUSED u8 unused[0x4]; + ptr = buff; val = args->value.f64; if (args->precision < 0) { @@ -88,11 +82,11 @@ void _Ldtob(printf_struct *args, u8 type) { } exp = exp * 30103 / 0x000186A0 - 4; if (exp < 0) { - n = (3 - exp) & ~3; + n = (-exp + 3) & ~3; exp = -n; for (i = 0; n > 0; n >>= 1, i++) { if ((n & 1) != 0) { - val *= D_80338670[i]; + val *= pows[i]; } } } else { @@ -101,25 +95,25 @@ void _Ldtob(printf_struct *args, u8 type) { exp &= ~3; for (n = exp, i = 0; n > 0; n >>= 1, i++) { if ((n & 1) != 0) { - factor *= D_80338670[i]; + factor *= pows[i]; } } val /= factor; } } - gen = ((type == 'f') ? exp + 10 : 6) + args->precision; + gen = args->precision + ((type == 'f') ? exp + 10 : 6); if (gen > 0x13) { gen = 0x13; } *ptr++ = '0'; while (gen > 0 && 0 < val) { - lo = val; + s32 lo = val; if ((gen -= 8) > 0) { val = (val - lo) * 1.0e8; } ptr = ptr + 8; for (j = 8; lo > 0 && --j >= 0;) { - qr = ldiv(lo, 10); + ldiv_t qr = ldiv(lo, 10); *--ptr = qr.rem + '0'; lo = qr.quot; } @@ -135,16 +129,13 @@ void _Ldtob(printf_struct *args, u8 type) { --gen, --exp; } - nsig = ((type == 'f') ? exp + 1 : ((type == 'e' || type == 'E') ? 1 : 0)) + args->precision; + nsig = args->precision + ((type == 'f') ? exp + 1 : ((type == 'e' || type == 'E') ? 1 : 0)); if (gen < nsig) { nsig = gen; } if (nsig > 0) { - if (nsig < gen && ptr[nsig] > '4') { - drop = '9'; - } else { - drop = '0'; - } + fmt_type drop = (nsig < gen && ptr[nsig] > '4') ? '9' : '0'; + s32 n2; for (n2 = nsig; ptr[--n2] == drop;) { nsig--; @@ -180,12 +171,12 @@ static s16 _Ldunscale(s16 *pex, printf_struct *px) { } } -static void _Genld(printf_struct *px, u8 code, u8 *p, s16 nsig, s16 xexp) { - u8 point = '.'; +static void _Genld(printf_struct *px, fmt_type code, fmt_type *p, s16 nsig, s16 xexp) { + const fmt_type point = '.'; if (nsig <= 0) { nsig = 1, - p = (u8 *) "0"; + p = (fmt_type *) "0"; } if (code == 'f' @@ -258,7 +249,7 @@ static void _Genld(printf_struct *px, u8 code, u8 *p, s16 nsig, s16 xexp) { px->part2_len += nsig; px->num_mid_zeros = px->precision - nsig; } - p = (u8 *) &px->buff[px->part2_len]; /* put exponent */ + p = (fmt_type *) &px->buff[px->part2_len]; /* put exponent */ *p++ = code; if (0 <= xexp) { *p++ = '+'; @@ -274,7 +265,7 @@ static void _Genld(printf_struct *px, u8 code, u8 *p, s16 nsig, s16 xexp) { } *p++ = xexp / 10 + '0', xexp %= 10; *p++ = xexp + '0'; - px->part3_len = p - (u8 *) &px->buff[px->part2_len]; + px->part3_len = p - (fmt_type *) &px->buff[px->part2_len]; } if ((px->flags & (FLAGS_ZERO | FLAGS_MINUS)) == FLAGS_ZERO) { /* pad with leading zeros */ int n = diff --git a/lib/src/_Litob.c b/lib/src/_Litob.c index 58ed081f..c1fbabd5 100644 --- a/lib/src/_Litob.c +++ b/lib/src/_Litob.c @@ -5,10 +5,10 @@ #define BUFF_LEN 0x18 -static u8 D_80334960[] = "0123456789abcdef"; -static u8 D_80334974[] = "0123456789ABCDEF"; +static u8 ldigs[] = "0123456789abcdef"; +static u8 udigs[] = "0123456789ABCDEF"; -void _Litob(printf_struct *args, u8 type) { +void _Litob(printf_struct *args, fmt_type type) { u8 buff[BUFF_LEN]; const u8 *num_map; s32 base; @@ -17,9 +17,9 @@ void _Litob(printf_struct *args, u8 type) { lldiv_t quotrem; if (type == 'X') { - num_map = D_80334974; + num_map = udigs; } else { - num_map = D_80334960; + num_map = ldigs; } base = (type == 'o') ? 8 : ((type != 'x' && type != 'X') ? 10 : 16); diff --git a/lib/src/_Printf.c b/lib/src/_Printf.c index e42bf042..5252a207 100644 --- a/lib/src/_Printf.c +++ b/lib/src/_Printf.c @@ -6,7 +6,7 @@ #define ATOI(i, a) \ for (i = 0; *a >= '0' && *a <= '9'; a++) \ if (i < 999) \ - i = *a + i * 10 - '0'; + i = i * 10 + *a - '0'; #define _PROUT(dst, fmt, _size) \ if (_size > 0) { \ dst = prout(dst, fmt, _size); \ @@ -25,25 +25,25 @@ _PROUT(dst, src, c); \ } -const char length_str[] = "hlL"; -const char flags_str[] = " +-#0"; -const u32 flags_arr[] = { FLAGS_SPACE, FLAGS_PLUS, FLAGS_MINUS, FLAGS_HASH, FLAGS_ZERO, 0 }; -char _spaces[] = " "; -char _zeroes[] = "00000000000000000000000000000000"; +char spaces[] = " "; +char zeroes[] = "00000000000000000000000000000000"; -static void _Putfld(printf_struct *, va_list *, u8, u8 *); +static void _Putfld(printf_struct *, va_list *, fmt_type, fmt_type *); s32 _Printf(char *(*prout)(char *, const char *, size_t), char *dst, const char *fmt, va_list args) { + static const char flags_str[] = " +-#0"; + static const u32 flags_arr[] = { FLAGS_SPACE, FLAGS_PLUS, FLAGS_MINUS, FLAGS_HASH, FLAGS_ZERO, 0 }; + printf_struct sp78; - const u8 *fmt_ptr; - u8 c; + const fmt_type *fmt_ptr; + fmt_type c; const char *flag_index; - u8 sp4c[0x20]; // probably a buffer? + fmt_type sp4c[0x20]; // probably a buffer? s32 sp48, sp44, sp40, sp3c, sp38, sp34, sp30, sp2c, sp28, sp24; sp78.size = 0; while (TRUE) { - fmt_ptr = (u8 *) fmt; -#ifdef VERSION_SH + fmt_ptr = (fmt_type *) fmt; +#if defined(VERSION_SH) || defined(VERSION_CN) // new version: don't point fmt_ptr beyond NUL character while ((c = *fmt_ptr) != 0 && c != '%') { fmt_ptr++; @@ -56,7 +56,7 @@ s32 _Printf(char *(*prout)(char *, const char *, size_t), char *dst, const char } } #endif - _PROUT(dst, fmt, fmt_ptr - (u8 *) fmt); + _PROUT(dst, fmt, fmt_ptr - (fmt_type *) fmt); if (c == 0) { return sp78.size; } @@ -86,11 +86,7 @@ s32 _Printf(char *(*prout)(char *, const char *, size_t), char *dst, const char ATOI(sp78.precision, fmt_ptr); } } - if (strchr(length_str, *fmt_ptr) != NULL) { - sp78.length = *fmt_ptr++; - } else { - sp78.length = 0; - } + sp78.length = strchr("hlL", *fmt_ptr) != NULL ? *fmt_ptr++ : '\0'; if (sp78.length == 'l' && *fmt_ptr == 'l') { sp78.length = 'L'; @@ -99,19 +95,19 @@ s32 _Printf(char *(*prout)(char *, const char *, size_t), char *dst, const char _Putfld(&sp78, &args, *fmt_ptr, sp4c); sp78.width -= sp78.part1_len + sp78.num_leading_zeros + sp78.part2_len + sp78.num_mid_zeros + sp78.part3_len + sp78.num_trailing_zeros; - _PAD(sp44, sp78.width, sp48, _spaces, !(sp78.flags & FLAGS_MINUS)); + _PAD(sp44, sp78.width, sp48, spaces, !(sp78.flags & FLAGS_MINUS)); _PROUT(dst, (char *) sp4c, sp78.part1_len); - _PAD(sp3c, sp78.num_leading_zeros, sp40, _zeroes, 1); + _PAD(sp3c, sp78.num_leading_zeros, sp40, zeroes, 1); _PROUT(dst, sp78.buff, sp78.part2_len); - _PAD(sp34, sp78.num_mid_zeros, sp38, _zeroes, 1); + _PAD(sp34, sp78.num_mid_zeros, sp38, zeroes, 1); _PROUT(dst, (char *) (&sp78.buff[sp78.part2_len]), sp78.part3_len) - _PAD(sp2c, sp78.num_trailing_zeros, sp30, _zeroes, 1); - _PAD(sp24, sp78.width, sp28, _spaces, sp78.flags & FLAGS_MINUS); + _PAD(sp2c, sp78.num_trailing_zeros, sp30, zeroes, 1); + _PAD(sp24, sp78.width, sp28, spaces, sp78.flags & FLAGS_MINUS); fmt = (char *) fmt_ptr + 1; } } -static void _Putfld(printf_struct *a0, va_list *args, u8 type, u8 *buff) { +static void _Putfld(printf_struct *a0, va_list *args, fmt_type type, fmt_type *buff) { a0->part1_len = a0->num_leading_zeros = a0->part2_len = a0->num_mid_zeros = a0->part3_len = a0->num_trailing_zeros = 0; diff --git a/lib/src/__osAiDeviceBusy.c b/lib/src/__osAiDeviceBusy.c index 261fcbab..b7ec5626 100644 --- a/lib/src/__osAiDeviceBusy.c +++ b/lib/src/__osAiDeviceBusy.c @@ -1,9 +1,9 @@ #include "libultra_internal.h" -#include "hardware.h" +#include "PR/rcp.h" s32 __osAiDeviceBusy(void) { - register s32 status = HW_REG(AI_STATUS_REG, u32); - if ((status & AI_STATUS_AI_FULL) != 0) { + register s32 status = IO_READ(AI_STATUS_REG); + if (status & AI_STATUS_FIFO_FULL) { return 1; } else { return 0; diff --git a/lib/src/__osDequeueThread.c b/lib/src/__osDequeueThread.c index 08758378..42269232 100644 --- a/lib/src/__osDequeueThread.c +++ b/lib/src/__osDequeueThread.c @@ -3,17 +3,17 @@ // these don't feel like they belong here // but it makes the most logical since there was printf data before #ifndef AVOID_UB -OSThread *D_80334890 = NULL; +OSThread *__osThreadTail = NULL; u32 D_80334894 = -1; -OSThread *D_80334898 = (OSThread *) &D_80334890; -OSThread *D_8033489C = (OSThread *) &D_80334890; -OSThread *D_803348A0 = NULL; -u32 D_803348A4 = 0; // UNKNOWN +OSThread *__osRunQueue = (OSThread *) &__osThreadTail; +OSThread *__osActiveQueue = (OSThread *) &__osThreadTail; +OSThread *__osRunningThread = { 0 }; +OSThread *__osFaultedThread = { 0 }; #else -OSThread_ListHead D_80334890_fix = {NULL, -1, (OSThread *) &D_80334890_fix, (OSThread *) &D_80334890_fix, NULL, 0}; +OSThread_ListHead __osThreadTail_fix = {NULL, -1, (OSThread *) &__osThreadTail_fix, (OSThread *) &__osThreadTail_fix, NULL, 0}; #endif -void __osDequeueThread(OSThread **queue, OSThread *thread) { +void __osDequeueThread(register OSThread **queue, register OSThread *thread) { register OSThread **a2; register OSThread *a3; a2 = queue; diff --git a/lib/src/__osDevMgrMain.c b/lib/src/__osDevMgrMain.c index e31bdaa3..3903c268 100644 --- a/lib/src/__osDevMgrMain.c +++ b/lib/src/__osDevMgrMain.c @@ -1,10 +1,18 @@ #include "libultra_internal.h" #include "macros.h" +#include "PR/os.h" -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) #include "new_func.h" +#include "PR/rcp.h" +#include "PR/ique.h" + +#define ALIGN16(val) (((val) + 0xF) & ~0xF) void __osDevMgrMain(void *args) { +#ifdef VERSION_CN + s32 loadedToTempBuffer = FALSE; +#endif OSIoMesg *mb; OSMesg em; OSMesg dummy; @@ -16,7 +24,7 @@ void __osDevMgrMain(void *args) { u32 sp2c; __OSBlockInfo *sp28; __OSTranxInfo *sp24; -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) u32 tmp; #endif #ifdef VERSION_EU @@ -43,45 +51,55 @@ void __osDevMgrMain(void *args) { sp2c = 0; } osRecvMesg(sp34->accessQueue, &dummy, OS_MESG_BLOCK); - __osResetGlobalIntMask(0x00100401); // remove magic constant! - __osEPiRawWriteIo(mb->piHandle, 0x05000510, (sp24->bmCtlShadow | 0x80000000)); - while (TRUE) { - osRecvMesg(sp34->eventQueue, &em, OS_MESG_BLOCK); -#ifdef VERSION_SH - sp24 = &mb->piHandle->transferInfo; - sp28 = &sp24->block[sp24->blockNum]; - if (sp28->errStatus == 0x1D) { - __osEPiRawWriteIo(mb->piHandle, 0x5000510, sp24->bmCtlShadow | 0x10000000); - __osEPiRawWriteIo(mb->piHandle, 0x5000510, sp24->bmCtlShadow); - __osEPiRawReadIo(mb->piHandle, 0x5000508, &tmp); - if ((tmp & 0x2000000) != 0) { - __osEPiRawWriteIo(mb->piHandle, 0x5000510, sp24->bmCtlShadow | 0x1000000); - } - sp28->errStatus = 4; - HW_REG(PI_STATUS_REG, u32) = PI_STATUS_CLEAR_INTR; - __osSetGlobalIntMask(0x100C01); + __osResetGlobalIntMask(OS_IM_PI); + osEPiRawWriteIo(mb->piHandle, 0x05000510, (sp24->bmCtlShadow | 0x80000000)); +l1: + osRecvMesg(sp34->eventQueue, &em, OS_MESG_BLOCK); +#if defined(VERSION_SH) || defined(VERSION_CN) + sp24 = &mb->piHandle->transferInfo; + sp28 = &sp24->block[sp24->blockNum]; + if (sp28->errStatus == 0x1D) { + osEPiRawWriteIo(mb->piHandle, 0x5000510, sp24->bmCtlShadow | 0x10000000); + osEPiRawWriteIo(mb->piHandle, 0x5000510, sp24->bmCtlShadow); + osEPiRawReadIo(mb->piHandle, 0x5000508, &tmp); + if ((tmp & 0x2000000) != 0) { + osEPiRawWriteIo(mb->piHandle, 0x5000510, sp24->bmCtlShadow | 0x1000000); } - osSendMesg(mb->hdr.retQueue, mb, OS_MESG_NOBLOCK); - if (sp2c != 1 || mb->piHandle->transferInfo.block[0].errStatus != 0) { - break; - } -#else - sp30 = osSendMesg(mb->hdr.retQueue, mb, OS_MESG_NOBLOCK); - if (sp2c != 1 || mb->piHandle->transferInfo.errStatus != 0) { - break; - } -#endif - sp2c = 0; + sp28->errStatus = 4; + IO_WRITE(PI_STATUS_REG, PI_STATUS_CLR_INTR); + __osSetGlobalIntMask(0x100C01); } + + osSendMesg(mb->hdr.retQueue, mb, OS_MESG_NOBLOCK); + + if (sp2c == 1 && mb->piHandle->transferInfo.block[0].errStatus == 0) { + sp2c = 0; + goto l1; + } +#else + sp30 = osSendMesg(mb->hdr.retQueue, mb, OS_MESG_NOBLOCK); + + if (sp2c == 1 && mb->piHandle->transferInfo.errStatus == 0) { + sp2c = 0; + goto l1; + } +#endif osSendMesg(sp34->accessQueue, NULL, OS_MESG_NOBLOCK); + if (mb->piHandle->transferInfo.blockNum == 1) { - func_802F71F0(); + osYieldThread(); } } else { switch (mb->hdr.type) { case 11: osRecvMesg(sp34->accessQueue, &dummy, OS_MESG_BLOCK); - ret = sp34->dma_func(OS_READ, mb->devAddr, mb->dramAddr, mb->size); +#ifdef VERSION_CN + if (__osBbIsBb == 1 && ((uintptr_t) mb->dramAddr & 0x7f) >= 0x60) { + loadedToTempBuffer = TRUE; + ret = sp34->dma_func(OS_READ, mb->devAddr, (void *) 0x80600000, mb->size); + } else +#endif + ret = sp34->dma_func(OS_READ, mb->devAddr, mb->dramAddr, mb->size); break; case 12: osRecvMesg(sp34->accessQueue, &dummy, OS_MESG_BLOCK); @@ -89,8 +107,15 @@ void __osDevMgrMain(void *args) { break; case 15: osRecvMesg(sp34->accessQueue, &dummy, OS_MESG_BLOCK); - ret = sp34->edma_func(mb->piHandle, OS_READ, mb->devAddr, mb->dramAddr, - mb->size); +#ifdef VERSION_CN + if (__osBbIsBb == 1 && ((uintptr_t) mb->dramAddr & 0x7f) >= 0x60) { + loadedToTempBuffer = TRUE; + ret = sp34->edma_func(mb->piHandle, OS_READ, mb->devAddr, (void *) 0x80600000, + mb->size); + } else +#endif + ret = sp34->edma_func(mb->piHandle, OS_READ, mb->devAddr, mb->dramAddr, + mb->size); break; case 16: osRecvMesg(sp34->accessQueue, &dummy, OS_MESG_BLOCK); @@ -108,6 +133,14 @@ void __osDevMgrMain(void *args) { } if (ret == 0) { osRecvMesg(sp34->eventQueue, &em, OS_MESG_BLOCK); +#ifdef VERSION_CN + if (__osBbIsBb == 1 && loadedToTempBuffer) { + osInvalDCache((void *) 0x80600000, ALIGN16(mb->size)); + bcopy((void *) 0x80600000, mb->dramAddr, mb->size); + osWritebackDCache(mb->dramAddr, mb->size); + loadedToTempBuffer = FALSE; + } +#endif #ifdef VERSION_EU sp30 = #endif diff --git a/lib/src/__osEPiRawReadIo.c b/lib/src/__osEPiRawReadIo.c deleted file mode 100644 index 28c403a2..00000000 --- a/lib/src/__osEPiRawReadIo.c +++ /dev/null @@ -1,11 +0,0 @@ -#include "libultra_internal.h" -#include "hardware.h" - -s32 __osEPiRawReadIo(OSPiHandle *arg0, u32 devAddr, u32 *data) { - register s32 stat; - while (stat = HW_REG(PI_STATUS_REG, s32), stat & (PI_STATUS_BUSY | PI_STATUS_IOBUSY | PI_STATUS_ERROR)) { - ; - } - *data = HW_REG(arg0->baseAddress | devAddr, s32); - return 0; -} diff --git a/lib/src/__osEPiRawWriteIo.c b/lib/src/__osEPiRawWriteIo.c deleted file mode 100644 index 539a5c65..00000000 --- a/lib/src/__osEPiRawWriteIo.c +++ /dev/null @@ -1,35 +0,0 @@ -#include "libultra_internal.h" -#include "hardware.h" - -s32 __osEPiRawWriteIo(OSPiHandle *a0, u32 a1, u32 a2) { - register u32 a3 = HW_REG(PI_STATUS_REG, u32); - while (a3 & PI_STATUS_ERROR) - a3 = HW_REG(PI_STATUS_REG, u32); - HW_REG(a0->baseAddress | a1, u32) = a2; - return 0; -} -/* -/ 0B69A0 802F71A0 3C0EA460 / lui $t6, %hi(PI_STATUS_REG) # $t6, 0xa460 -/ 0B69A4 802F71A4 8DC70010 / lw $a3, %lo(PI_STATUS_REG)($t6) -/ 0B69A8 802F71A8 27BDFFF8 / addiu $sp, $sp, -8 -/ 0B69AC 802F71AC 30EF0003 / andi $t7, $a3, 3 - -/ 0B69B0 802F71B0 11E00006 / beqz $t7, .L802F71CC -/ 0B69B4 802F71B4 00000000 / nop -.L802F71B8: -/ 0B69B8 802F71B8 3C18A460 / lui $t8, %hi(PI_STATUS_REG) # $t8, 0xa460 -/ 0B69BC 802F71BC 8F070010 / lw $a3, %lo(PI_STATUS_REG)($t8) -/ 0B69C0 802F71C0 30F90003 / andi $t9, $a3, 3 -/ 0B69C4 802F71C4 1720FFFC / bnez $t9, .L802F71B8 -/ 0B69C8 802F71C8 00000000 / nop -.L802F71CC: -/ 0B69CC 802F71CC 8C88000C / lw $t0, 0xc($a0) -/ 0B69D0 802F71D0 3C01A000 / lui $at, 0xa000 -/ 0B69D4 802F71D4 27BD0008 / addiu $sp, $sp, 8 -/ 0B69D8 802F71D8 01054825 / or $t1, $t0, $a1 -/ 0B69DC 802F71DC 01215025 / or $t2, $t1, $at -/ 0B69E0 802F71E0 AD460000 / sw $a2, ($t2) -/ 0B69E4 802F71E4 03E00008 / jr $ra -/ 0B69E8 802F71E8 00001025 / move $v0, $zero - -/ 0B69EC 802F71EC 00000000 / nop */ diff --git a/lib/src/__osGetCurrFaultedThread.c b/lib/src/__osGetCurrFaultedThread.c index f4951ff1..eede93e1 100644 --- a/lib/src/__osGetCurrFaultedThread.c +++ b/lib/src/__osGetCurrFaultedThread.c @@ -1,5 +1,5 @@ #include "libultra_internal.h" OSThread *__osGetCurrFaultedThread() { - return D_8033489C; // 80302efc + return __osActiveQueue; } diff --git a/lib/src/__osPiCreateAccessQueue.c b/lib/src/__osPiCreateAccessQueue.c index 90d4c86a..385848f9 100644 --- a/lib/src/__osPiCreateAccessQueue.c +++ b/lib/src/__osPiCreateAccessQueue.c @@ -1,8 +1,10 @@ #include "libultra_internal.h" +#include "macros.h" + #define PIAccessQueueSize 2 -OSMesg osPiMesgBuff[PIAccessQueueSize]; +FORCE_BSS OSMesg osPiMesgBuff[PIAccessQueueSize]; OSMesgQueue gOsPiMessageQueue; u32 gOsPiAccessQueueCreated = 0; diff --git a/lib/src/__osResetGlobalIntMask.c b/lib/src/__osResetGlobalIntMask.c index e6b0de27..26fbccfc 100644 --- a/lib/src/__osResetGlobalIntMask.c +++ b/lib/src/__osResetGlobalIntMask.c @@ -1,5 +1,5 @@ #include "libultra_internal.h" -#include "new_func.h" +#include "PR/os.h" void __osResetGlobalIntMask(u32 mask) { register u32 prev; diff --git a/lib/src/__osSetGlobalIntMask.c b/lib/src/__osSetGlobalIntMask.c index c800bb33..937281cf 100644 --- a/lib/src/__osSetGlobalIntMask.c +++ b/lib/src/__osSetGlobalIntMask.c @@ -1,9 +1,8 @@ #include "libultra_internal.h" -#include "hardware.h" -#include "new_func.h" +#include "PR/os.h" -void __osSetGlobalIntMask(s32 arg0) { - register u32 prev = __osDisableInt(); - __OSGlobalIntMask |= arg0; - __osRestoreInt(prev); +void __osSetGlobalIntMask(s32 mask) { + register u32 saveMask = __osDisableInt(); + __OSGlobalIntMask |= mask; + __osRestoreInt(saveMask); } diff --git a/lib/src/__osSetHWintrRoutine.c b/lib/src/__osSetHWintrRoutine.c new file mode 100644 index 00000000..0a32ede7 --- /dev/null +++ b/lib/src/__osSetHWintrRoutine.c @@ -0,0 +1,10 @@ +#include "libultra_internal.h" + +extern s32 (*__osHwIntTable[])(void) ; + +void __osSetHWIntrRoutine(OSHWIntr interrupt, s32 (*handler)(void)) { + register u32 saveMask; + saveMask = __osDisableInt(); + __osHwIntTable[interrupt] = handler; + __osRestoreInt(saveMask); +} diff --git a/lib/src/__osSiCreateAccessQueue.c b/lib/src/__osSiCreateAccessQueue.c index 06917774..00f35011 100644 --- a/lib/src/__osSiCreateAccessQueue.c +++ b/lib/src/__osSiCreateAccessQueue.c @@ -1,8 +1,10 @@ #include "libultra_internal.h" +#include "macros.h" + #define SIAccessQueueSize 2 -OSMesg osSiMesgBuff[SIAccessQueueSize]; +FORCE_BSS OSMesg osSiMesgBuff[SIAccessQueueSize]; OSMesgQueue gOsSiMessageQueue; u32 gOsSiAccessQueueCreated = 0; diff --git a/lib/src/__osSiDeviceBusy.c b/lib/src/__osSiDeviceBusy.c index 5872f134..83d5b395 100644 --- a/lib/src/__osSiDeviceBusy.c +++ b/lib/src/__osSiDeviceBusy.c @@ -1,10 +1,10 @@ #include "libultra_internal.h" -#include "hardware.h" +#include "PR/rcp.h" s32 __osSiDeviceBusy() { register u32 status; - status = HW_REG(SI_STATUS_REG, u32); - if (status & (SI_STATUS_DMA_BUSY | SI_STATUS_IO_READ_BUSY)) { + status = IO_READ(SI_STATUS_REG); + if (status & (SI_STATUS_DMA_BUSY | SI_STATUS_RD_BUSY)) { return 1; } else { return 0; diff --git a/lib/src/__osSiRawReadIo.c b/lib/src/__osSiRawReadIo.c index 03654dab..288d9411 100644 --- a/lib/src/__osSiRawReadIo.c +++ b/lib/src/__osSiRawReadIo.c @@ -1,10 +1,10 @@ #include "libultra_internal.h" -#include "hardware.h" +#include "PR/rcp.h" -s32 __osSiRawReadIo(void *a0, u32 *a1) { +s32 __osSiRawReadIo(u32 devAddr, u32 *data) { if (__osSiDeviceBusy()) { return -1; } - *a1 = HW_REG((uintptr_t) a0, u32); + *data = IO_READ(devAddr); return 0; } diff --git a/lib/src/__osSiRawStartDma.c b/lib/src/__osSiRawStartDma.c index 965b7187..83b6b882 100644 --- a/lib/src/__osSiRawStartDma.c +++ b/lib/src/__osSiRawStartDma.c @@ -1,21 +1,35 @@ #include "libultra_internal.h" -#include "hardware.h" +#include "PR/rcp.h" +#include "PR/ique.h" s32 __osSiRawStartDma(s32 dir, void *addr) { +#ifdef VERSION_CN + if (IO_READ(SI_STATUS_REG) & (SI_STATUS_DMA_BUSY | SI_STATUS_RD_BUSY)) { + return -1; + } +#else if (__osSiDeviceBusy()) { return -1; } +#endif if (dir == OS_WRITE) { osWritebackDCache(addr, 64); } - HW_REG(SI_DRAM_ADDR_REG, void *) = (void *) osVirtualToPhysical(addr); + IO_WRITE(SI_DRAM_ADDR_REG, osVirtualToPhysical(addr)); if (dir == OS_READ) { - HW_REG(SI_PIF_ADDR_RD64B_REG, u32) = 0x1FC007C0; +#ifdef VERSION_CN + if (__osBbIsBb != 0) { + u32 prev = __osDisableInt(); + skKeepAlive(); + __osRestoreInt(prev); + } +#endif + IO_WRITE(SI_PIF_ADDR_RD64B_REG, 0x1FC007C0); } else { - HW_REG(SI_PIF_ADDR_WR64B_REG, u32) = 0x1FC007C0; + IO_WRITE(SI_PIF_ADDR_WR64B_REG, 0x1FC007C0); } if (dir == OS_READ) { diff --git a/lib/src/__osSiRawWriteIo.c b/lib/src/__osSiRawWriteIo.c index 8da0a3d6..0cec9443 100644 --- a/lib/src/__osSiRawWriteIo.c +++ b/lib/src/__osSiRawWriteIo.c @@ -1,10 +1,10 @@ #include "libultra_internal.h" -#include "hardware.h" +#include "PR/rcp.h" -s32 __osSiRawWriteIo(void *a0, u32 a1) { +s32 __osSiRawWriteIo(u32 devAddr, u32 data) { if (__osSiDeviceBusy()) { return -1; } - HW_REG((uintptr_t) a0, u32) = a1; + IO_WRITE(devAddr, data); return 0; } diff --git a/lib/src/__osSpDeviceBusy.c b/lib/src/__osSpDeviceBusy.c index a40c402a..e03b4543 100644 --- a/lib/src/__osSpDeviceBusy.c +++ b/lib/src/__osSpDeviceBusy.c @@ -1,10 +1,12 @@ #include "libultra_internal.h" -#include "hardware.h" +#include "PR/rcp.h" s32 __osSpDeviceBusy() { - register u32 status = HW_REG(SP_STATUS_REG, u32); + register u32 status = IO_READ(SP_STATUS_REG); + if (status & (SPSTATUS_IO_FULL | SPSTATUS_DMA_FULL | SPSTATUS_DMA_BUSY)) { return 1; } + return 0; } diff --git a/lib/src/__osSpGetStatus.c b/lib/src/__osSpGetStatus.c index a3be17e6..2e25d140 100644 --- a/lib/src/__osSpGetStatus.c +++ b/lib/src/__osSpGetStatus.c @@ -1,6 +1,6 @@ #include "libultra_internal.h" -#include "hardware.h" +#include "PR/rcp.h" u32 __osSpGetStatus() { - return HW_REG(SP_STATUS_REG, u32); + return IO_READ(SP_STATUS_REG); } diff --git a/lib/src/__osSpRawStartDma.c b/lib/src/__osSpRawStartDma.c index 3768a5fa..1f3f761d 100644 --- a/lib/src/__osSpRawStartDma.c +++ b/lib/src/__osSpRawStartDma.c @@ -1,16 +1,18 @@ #include "libultra_internal.h" -#include "hardware.h" +#include "PR/rcp.h" s32 __osSpRawStartDma(u32 dir, void *sp_ptr, void *dram_ptr, size_t size) { if (__osSpDeviceBusy()) { return -1; } - HW_REG(SP_MEM_ADDR_REG, void *) = sp_ptr; - HW_REG(SP_DRAM_ADDR_REG, void *) = (void *) osVirtualToPhysical(dram_ptr); + + IO_WRITE(SP_MEM_ADDR_REG, sp_ptr); + IO_WRITE(SP_DRAM_ADDR_REG, osVirtualToPhysical(dram_ptr)); + if (dir == 0) { - HW_REG(SP_WR_LEN_REG, u32) = size - 1; + IO_WRITE(SP_WR_LEN_REG, size - 1); } else { - HW_REG(SP_RD_LEN_REG, u32) = size - 1; + IO_WRITE(SP_RD_LEN_REG, size - 1); } return 0; } diff --git a/lib/src/__osSpSetPc.c b/lib/src/__osSpSetPc.c index d074590c..d72d5be1 100644 --- a/lib/src/__osSpSetPc.c +++ b/lib/src/__osSpSetPc.c @@ -1,12 +1,12 @@ #include "libultra_internal.h" -#include "hardware.h" +#include "PR/rcp.h" s32 __osSpSetPc(void *pc) { - register u32 status = HW_REG(SP_STATUS_REG, u32); + register u32 status = IO_READ(SP_STATUS_REG); if (!(status & SPSTATUS_HALT)) { return -1; } else { - HW_REG(SP_PC_REG, void *) = pc; + IO_WRITE(SP_PC_REG, pc); return 0; } } diff --git a/lib/src/__osSpSetStatus.c b/lib/src/__osSpSetStatus.c index d63ac4ce..975d34d7 100644 --- a/lib/src/__osSpSetStatus.c +++ b/lib/src/__osSpSetStatus.c @@ -1,6 +1,6 @@ #include "libultra_internal.h" -#include "hardware.h" +#include "PR/rcp.h" void __osSpSetStatus(u32 status) { - HW_REG(SP_STATUS_REG, u32) = status; + IO_WRITE(SP_STATUS_REG, status); } diff --git a/lib/src/__osSyncPutChars.c b/lib/src/__osSyncPutChars.c index a27ef60f..0defdbcc 100644 --- a/lib/src/__osSyncPutChars.c +++ b/lib/src/__osSyncPutChars.c @@ -1,38 +1,33 @@ #include "libultra_internal.h" +#include "PR/rdb.h" +#include "PR/R4300.h" -typedef struct { - u8 unk00 : 2; - u8 pad : 4; - u8 unk01 : 2; - u8 unk2[3]; -} unkStruct; +u32 __osRdbSendMessage = 0; +u32 __osRdbWriteOK = 1; -u32 D_80334A40 = 0; -u32 D_80334A44 = 1; +void __osSyncPutChars(s32 type, s32 length, u8 *buf) { + rdbPacket packet; + s32 i; + u32 mask; + packet.type = type; + packet.length = length; -void __osSyncPutChars(s32 a0, s32 a1, u8 *a2) { - unkStruct sp24; - s32 sp20; - u32 sp1c; - sp24.unk00 = a0; - sp24.unk01 = a1; - - for (sp20 = 0; sp20 < a1; sp20++) { - sp24.unk2[sp20] = a2[sp20]; + for (i = 0; i < length; i++) { + packet.buf[i] = buf[i]; } - while (!__osAtomicDec(&D_80334A44)) { + while (!__osAtomicDec(&__osRdbWriteOK)) { ; } - sp1c = __osDisableInt(); + mask = __osDisableInt(); - *(u32 *) 0xC0000000 = *(u32 *) &sp24; - while (!(__osGetCause() & 0x2000)) { + *(u32 *) RDB_BASE_REG = *(u32 *) &packet; + while (!(__osGetCause() & CAUSE_IP6)) { ; } - *(u32 *) 0xC000000C = 0; - D_80334A44++; + *(u32 *) RDB_READ_INTR_REG = 0; + __osRdbWriteOK++; - __osRestoreInt(sp1c); + __osRestoreInt(mask); } diff --git a/lib/src/__osViInit.c b/lib/src/__osViInit.c index 9e0c9163..9643af04 100644 --- a/lib/src/__osViInit.c +++ b/lib/src/__osViInit.c @@ -1,87 +1,84 @@ #include "libultra_internal.h" -#include "hardware.h" +#include "PR/rcp.h" +#include "PR/os.h" OSViContext sViContexts[2] = { 0 }; OSViContext *__osViCurr = &sViContexts[0]; OSViContext *__osViNext = &sViContexts[1]; + #ifdef VERSION_EU -u32 osViClock = 0x02E6D354; // used for audio frequency calculations +u32 osViClock = VI_NTSC_CLOCK; u32 sTvType = TV_TYPE_PAL; -#elif !defined(VERSION_SH) +#elif !defined(VERSION_SH) && !defined(VERSION_CN) u32 sTvType = TV_TYPE_NTSC; -u32 osViClock = 0x02E6D354; +u32 osViClock = VI_NTSC_CLOCK; #endif -extern OSViMode D_80334990; -extern OSViMode D_803349E0; -#if defined(VERSION_EU) || defined(VERSION_SH) -extern OSViMode D_80302FD0; +extern OSViMode osViModePalLan1; +extern OSViMode osViModeMpalLan1; +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) +extern OSViMode osViModeNtscLan1; #endif void __osViInit(void) { -//#ifdef VERSION_JP #ifdef VERSION_US sTvType = osTvType; #endif + bzero(sViContexts, sizeof(sViContexts)); __osViCurr = &sViContexts[0]; __osViNext = &sViContexts[1]; __osViNext->retraceCount = 1; __osViCurr->retraceCount = 1; -#if defined(VERSION_EU) - - if (osTvType == TV_TYPE_PAL) { - __osViNext->modep = &D_80334990; - osViClock = 0x02F5B2D2; - } else if (osTvType == TV_TYPE_MPAL) { - __osViNext->modep = &D_803349E0; - osViClock = 0x02E6025C; +#if defined(VERSION_JP) + if (sTvType != TV_TYPE_PAL) { + __osViNext->modep = &osViModePalLan1; + osViClock = VI_NTSC_CLOCK; } else { - __osViNext->modep = &D_80302FD0; - osViClock = 0x02E6D354; + __osViNext->modep = &osViModeMpalLan1; + osViClock = VI_PAL_CLOCK; } - -#elif defined(VERSION_SH) - +#elif defined(VERSION_US) + if (sTvType == TV_TYPE_NTSC) { + __osViNext->modep = &osViModePalLan1; + osViClock = VI_NTSC_CLOCK; + } else { + __osViNext->modep = &osViModeMpalLan1; + osViClock = VI_MPAL_CLOCK; + } +#elif defined(VERSION_EU) + if (osTvType == TV_TYPE_PAL) { + __osViNext->modep = &osViModePalLan1; + osViClock = VI_PAL_CLOCK; + } else if (osTvType == TV_TYPE_MPAL) { + __osViNext->modep = &osViModeMpalLan1; + osViClock = VI_MPAL_CLOCK; + } else { + __osViNext->modep = &osViModeNtscLan1; + osViClock = VI_NTSC_CLOCK; + } +#else __osViNext->buffer = (void *) 0x80000000; __osViCurr->buffer = (void *) 0x80000000; if (osTvType == TV_TYPE_PAL) { - __osViNext->modep = &D_80334990; + __osViNext->modep = &osViModePalLan1; } else if (osTvType == TV_TYPE_MPAL) { - __osViNext->modep = &D_803349E0; + __osViNext->modep = &osViModeMpalLan1; } else { - __osViNext->modep = &D_80302FD0; - } - -#else - -#ifdef VERSION_JP - if (sTvType != TV_TYPE_PAL) -#else - if (sTvType == TV_TYPE_NTSC) -#endif - { - __osViNext->modep = &D_80334990; - osViClock = 0x02E6D354; - } else { - __osViNext->modep = &D_803349E0; -#if defined(VERSION_JP) - osViClock = 0x02F5B2D2; -#elif defined(VERSION_US) - osViClock = 0x02E6025C; -#endif + __osViNext->modep = &osViModeNtscLan1; } #endif - __osViNext->unk00 = 0x20; + __osViNext->unk00 = VI_STATE_BLACK; __osViNext->features = __osViNext->modep->comRegs.ctrl; + #ifndef VERSION_JP - while (HW_REG(VI_CURRENT_REG, u32) > 0xa) { + while (IO_READ(VI_CURRENT_REG) > 10) { ; } - HW_REG(VI_STATUS_REG, u32) = 0; + IO_WRITE(VI_STATUS_REG, 0); #endif __osViSwapContext(); } diff --git a/lib/src/__osViSwapContext.c b/lib/src/__osViSwapContext.c index 990cb11f..2aa963e6 100644 --- a/lib/src/__osViSwapContext.c +++ b/lib/src/__osViSwapContext.c @@ -1,36 +1,44 @@ #include "libultra_internal.h" -#include "hardware.h" +#include "PR/rcp.h" extern OSViContext *__osViNext; extern OSViContext *__osViCurr; +extern u32 __additional_scanline; + void __osViSwapContext() { - register OSViMode *s0; + register OSViMode *viMode; register OSViContext *s1; u32 origin; u32 hStart; +#ifdef VERSION_CN + u32 vStart; +#endif u32 sp34; u32 field; - register u32 s2; field = 0; s1 = __osViNext; - s0 = s1->modep; - field = HW_REG(VI_V_CURRENT_LINE_REG, u32) & 1; - s2 = osVirtualToPhysical(s1->buffer); - origin = (s0->fldRegs[field].origin) + s2; + viMode = s1->modep; + field = IO_READ(VI_V_CURRENT_LINE_REG) & 1; + origin = osVirtualToPhysical(s1->buffer) + viMode->fldRegs[field].origin; if (s1->unk00 & 2) { - s1->unk20 |= s0->comRegs.xScale & ~0xfff; + s1->unk20 |= viMode->comRegs.xScale & ~0xfff; } else { - s1->unk20 = s0->comRegs.xScale; + s1->unk20 = viMode->comRegs.xScale; } if (s1->unk00 & 4) { - sp34 = (u32)(s0->fldRegs[field].yScale & 0xfff); + sp34 = (u32)(viMode->fldRegs[field].yScale & 0xfff); s1->unk2c = s1->unk24 * sp34; - s1->unk2c |= s0->fldRegs[field].yScale & ~0xfff; + s1->unk2c |= viMode->fldRegs[field].yScale & ~0xfff; } else { - s1->unk2c = s0->fldRegs[field].yScale; + s1->unk2c = viMode->fldRegs[field].yScale; } - hStart = s0->comRegs.hStart; + +#ifdef VERSION_CN + vStart = viMode->fldRegs[field].vStart - (__additional_scanline << 0x10) + __additional_scanline; +#endif + hStart = viMode->comRegs.hStart; + if (s1->unk00 & 0x20) { hStart = 0; } @@ -42,19 +50,23 @@ void __osViSwapContext() { s1->unk2c = (s1->unk28 << 0x10) & 0x3ff0000; origin = osVirtualToPhysical(s1->buffer); } - HW_REG(VI_ORIGIN_REG, u32) = origin; - HW_REG(VI_WIDTH_REG, u32) = s0->comRegs.width; - HW_REG(VI_BURST_REG, u32) = s0->comRegs.burst; - HW_REG(VI_V_SYNC_REG, u32) = s0->comRegs.vSync; - HW_REG(VI_H_SYNC_REG, u32) = s0->comRegs.hSync; - HW_REG(VI_LEAP_REG, u32) = s0->comRegs.leap; - HW_REG(VI_H_START_REG, u32) = hStart; - HW_REG(VI_V_START_REG, u32) = s0->fldRegs[field].vStart; - HW_REG(VI_V_BURST_REG, u32) = s0->fldRegs[field].vBurst; - HW_REG(VI_INTR_REG, u32) = s0->fldRegs[field].vIntr; - HW_REG(VI_X_SCALE_REG, u32) = s1->unk20; - HW_REG(VI_Y_SCALE_REG, u32) = s1->unk2c; - HW_REG(VI_CONTROL_REG, u32) = s1->features; + IO_WRITE(VI_ORIGIN_REG, origin); + IO_WRITE(VI_WIDTH_REG, viMode->comRegs.width); + IO_WRITE(VI_BURST_REG, viMode->comRegs.burst); + IO_WRITE(VI_V_SYNC_REG, viMode->comRegs.vSync); + IO_WRITE(VI_H_SYNC_REG, viMode->comRegs.hSync); + IO_WRITE(VI_LEAP_REG, viMode->comRegs.leap); + IO_WRITE(VI_H_START_REG, hStart); +#ifdef VERSION_CN + IO_WRITE(VI_V_START_REG, vStart); +#else + IO_WRITE(VI_V_START_REG, viMode->fldRegs[field].vStart); +#endif + IO_WRITE(VI_V_BURST_REG, viMode->fldRegs[field].vBurst); + IO_WRITE(VI_INTR_REG, viMode->fldRegs[field].vIntr); + IO_WRITE(VI_X_SCALE_REG, s1->unk20); + IO_WRITE(VI_Y_SCALE_REG, s1->unk2c); + IO_WRITE(VI_CONTROL_REG, s1->features); __osViNext = __osViCurr; __osViCurr = s1; *__osViNext = *__osViCurr; diff --git a/lib/src/contramread.c b/lib/src/contramread.c index cd74bb24..19cd3f53 100644 --- a/lib/src/contramread.c +++ b/lib/src/contramread.c @@ -1,8 +1,9 @@ #include "libultra_internal.h" #include "PR/rcp.h" #include "controller.h" +#include "macros.h" -extern s32 func_8030A5C0(OSMesgQueue *, s32); +extern s32 __osPfsGetStatus(OSMesgQueue *, s32); void __osPackRamReadData(int channel, u16 address); s32 __osContRamRead(OSMesgQueue *mq, int channel, u16 address, u8 *buffer) { @@ -15,7 +16,7 @@ s32 __osContRamRead(OSMesgQueue *mq, int channel, u16 address, u8 *buffer) { ptr = (u8 *)&__osPfsPifRam; retry = 2; __osSiGetAccess(); - _osLastSentSiCmd = CONT_CMD_READ_MEMPACK; + __osContLastCmd = CONT_CMD_READ_MEMPACK; __osPackRamReadData(channel, address); ret = __osSiRawStartDma(OS_WRITE, &__osPfsPifRam); osRecvMesg(mq, NULL, OS_MESG_BLOCK); @@ -34,14 +35,14 @@ s32 __osContRamRead(OSMesgQueue *mq, int channel, u16 address, u8 *buffer) { u8 c; c = __osContDataCrc((u8*)&ramreadformat.data); if (c != ramreadformat.datacrc) { - ret = func_8030A5C0(mq, channel); + ret = __osPfsGetStatus(mq, channel); if (ret != 0) { __osSiRelAccess(); return ret; } ret = PFS_ERR_CONTRFAIL; } else { - for (i = 0; i < ARRLEN(ramreadformat.data); i++) { + for (i = 0; i < ARRAY_COUNT(ramreadformat.data); i++) { *buffer++ = ramreadformat.data[i]; } } @@ -63,7 +64,7 @@ void __osPackRamReadData(int channel, u16 address) { ptr = (u8 *)__osPfsPifRam.ramarray; - for (i = 0; i < ARRLEN(__osPfsPifRam.ramarray) + 1; i++) { // also clear pifstatus + for (i = 0; i < ARRAY_COUNT(__osPfsPifRam.ramarray) + 1; i++) { __osPfsPifRam.ramarray[i] = 0; } @@ -74,7 +75,7 @@ void __osPackRamReadData(int channel, u16 address) { ramreadformat.cmd = CONT_CMD_READ_MEMPACK; ramreadformat.address = (address << 0x5) | __osContAddressCrc(address); ramreadformat.datacrc = CONT_CMD_NOP; - for (i = 0; i < ARRLEN(ramreadformat.data); i++) { + for (i = 0; i < ARRAY_COUNT(ramreadformat.data); i++) { ramreadformat.data[i] = CONT_CMD_NOP; } if (channel != 0) { diff --git a/lib/src/contramwrite.c b/lib/src/contramwrite.c index f72d6ffd..abf21665 100644 --- a/lib/src/contramwrite.c +++ b/lib/src/contramwrite.c @@ -1,16 +1,17 @@ #include "libultra_internal.h" #include "PR/rcp.h" #include "controller.h" +#include "macros.h" -extern s32 func_8030A5C0(OSMesgQueue *, s32); -void __osPackRamWriteData(int channel, u16 address, u8 *buffer); +extern s32 __osPfsGetStatus(OSMesgQueue *, s32); +void __osPackRamWriteData(s32 channel, u16 address, u8 *buffer); -s32 __osContRamWrite(OSMesgQueue *mq, int channel, u16 address, u8 *buffer, int force) { +s32 __osContRamWrite(OSMesgQueue *mq, s32 channel, u16 address, u8 *buffer, s32 force) { s32 ret; - int i; + s32 i; u8 *ptr; __OSContRamReadFormat ramreadformat; - int retry; + s32 retry; ret = 0; ptr = (u8 *)&__osPfsPifRam; @@ -19,7 +20,7 @@ s32 __osContRamWrite(OSMesgQueue *mq, int channel, u16 address, u8 *buffer, int return 0; } __osSiGetAccess(); - _osLastSentSiCmd = CONT_CMD_WRITE_MEMPACK; + __osContLastCmd = CONT_CMD_WRITE_MEMPACK; __osPackRamWriteData(channel, address, buffer); ret = __osSiRawStartDma(OS_WRITE, &__osPfsPifRam); osRecvMesg(mq, NULL, OS_MESG_BLOCK); @@ -38,7 +39,7 @@ s32 __osContRamWrite(OSMesgQueue *mq, int channel, u16 address, u8 *buffer, int ret = CHNL_ERR(ramreadformat); if (ret == 0) { if (__osContDataCrc(buffer) != ramreadformat.datacrc) { - ret = func_8030A5C0(mq, channel); + ret = __osPfsGetStatus(mq, channel); if (ret != 0) { __osSiRelAccess(); return ret; @@ -63,7 +64,7 @@ void __osPackRamWriteData(int channel, u16 address, u8 *buffer) { ptr = (u8 *)__osPfsPifRam.ramarray; - for (i = 0; i < ARRLEN(__osPfsPifRam.ramarray) + 1; i++) { // also clear pifstatus + for (i = 0; i < ARRAY_COUNT(__osPfsPifRam.ramarray) + 1; i++) { __osPfsPifRam.ramarray[i] = 0; } @@ -74,7 +75,7 @@ void __osPackRamWriteData(int channel, u16 address, u8 *buffer) { ramreadformat.cmd = CONT_CMD_WRITE_MEMPACK; ramreadformat.address = (address << 0x5) | __osContAddressCrc(address); ramreadformat.datacrc = CONT_CMD_NOP; - for (i = 0; i < ARRLEN(ramreadformat.data); i++) { + for (i = 0; i < ARRAY_COUNT(ramreadformat.data); i++) { ramreadformat.data[i] = *buffer++; } if (channel != 0) { diff --git a/lib/src/controller.h b/lib/src/controller.h index 518b113e..df67aa43 100644 --- a/lib/src/controller.h +++ b/lib/src/controller.h @@ -5,17 +5,14 @@ #include "PR/rcp.h" //should go somewhere else but -#define ARRLEN(x) ((s32)(sizeof(x) / sizeof(x[0]))) #define CHNL_ERR(format) ((format.rxsize & CHNL_ERR_MASK) >> 4) -typedef struct -{ - /* 0x0 */ u32 ramarray[15]; +typedef struct { + /* 0x00 */ u32 ramarray[15]; /* 0x3C */ u32 pifstatus; } OSPifRam; -typedef struct -{ +typedef struct { /* 0x0 */ u8 dummy; /* 0x1 */ u8 txsize; /* 0x2 */ u8 rxsize; @@ -25,8 +22,7 @@ typedef struct /* 0x7 */ s8 stick_y; } __OSContReadFormat; -typedef struct -{ +typedef struct { /* 0x0 */ u8 dummy; /* 0x1 */ u8 txsize; /* 0x2 */ u8 rxsize; @@ -37,8 +33,7 @@ typedef struct /* 0x7 */ u8 dummy1; } __OSContRequesFormat; -typedef struct -{ +typedef struct { /* 0x0 */ u8 txsize; /* 0x1 */ u8 rxsize; /* 0x2 */ u8 cmd; @@ -47,8 +42,7 @@ typedef struct /* 0x5 */ u8 status; } __OSContRequesFormatShort; -typedef struct -{ +typedef struct { /* 0x0 */ u8 dummy; /* 0x1 */ u8 txsize; /* 0x2 */ u8 rxsize; @@ -67,8 +61,7 @@ typedef union { /* 0x0 */ u16 ipage; } __OSInodeUnit; -typedef struct -{ +typedef struct { /* 0x0 */ u32 game_code; /* 0x4 */ u16 company_code; /* 0x6 */ __OSInodeUnit start_page; @@ -79,13 +72,11 @@ typedef struct /* 0x10 */ u8 game_name[PFS_FILE_NAME_LEN]; } __OSDir; -typedef struct -{ +typedef struct { /* 0x0 */ __OSInodeUnit inode_page[128]; } __OSInode; -typedef struct -{ +typedef struct { /* 0x0 */ u32 repaired; /* 0x4 */ u32 random; /* 0x8 */ u64 serial_mid; @@ -97,8 +88,7 @@ typedef struct /* 0x1E */ u16 inverted_checksum; } __OSPackId; -typedef struct -{ +typedef struct { /* 0x0 */ u8 txsize; /* 0x1 */ u8 rxsize; /* 0x2 */ u8 cmd; @@ -160,7 +150,7 @@ s32 __osPfsDeclearPage(OSPfs *pfs, __OSInode *inode, int file_size_in_pages, int s32 __osPfsReleasePages(OSPfs *pfs, __OSInode *inode, u8 start_page, u16 *sum, u8 bank, __OSInodeUnit *last_page, int flag); s32 __osBlockSum(OSPfs *pfs, u8 page_no, u16 *sum, u8 bank); s32 __osContRamRead(OSMesgQueue *mq, int channel, u16 address, u8 *buffer); -s32 __osContRamWrite(OSMesgQueue *mq, int channel, u16 address, u8 *buffer, int force); +s32 __osContRamWrite(OSMesgQueue *mq, s32 channel, u16 address, u8 *buffer, s32 force); void __osContGetInitData(u8 *pattern, OSContStatus *data); void __osPackRequestData(u8 cmd); void __osPfsRequestData(u8 cmd); @@ -169,14 +159,14 @@ u8 __osContAddressCrc(u16 addr); u8 __osContDataCrc(u8 *data); s32 __osPfsGetStatus(OSMesgQueue *queue, int channel); -extern u8 _osLastSentSiCmd; +extern u8 __osContLastCmd; extern OSTimer __osEepromTimer; -extern OSMesg __osEepromTimerMsg; +extern OSMesg __osEepromTimerMsg[4]; extern OSMesgQueue __osEepromTimerQ; extern OSPifRam __osEepPifRam; extern OSPifRam __osContPifRam; extern OSPifRam __osPfsPifRam; -extern u8 _osContNumControllers; +extern u8 __osMaxControllers; //some version of this almost certainly existed since there's plenty of times where it's used right before a return 0 #define ERRCK(fn) \ diff --git a/lib/src/epidma.c b/lib/src/epidma.c index 3aa76f17..0206fcc7 100644 --- a/lib/src/epidma.c +++ b/lib/src/epidma.c @@ -1,4 +1,4 @@ -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) #include "PR/os_internal.h" #include "piint.h" diff --git a/lib/src/func_802F4A20.c b/lib/src/func_802F4A20.c deleted file mode 100644 index 499697d8..00000000 --- a/lib/src/func_802F4A20.c +++ /dev/null @@ -1,40 +0,0 @@ -#include "new_func.h" - -void func_802F4A20(void) { - __OSTranxInfo *sp1c; - volatile u32 sp18; - sp1c = &__osDiskHandle->transferInfo; - WAIT_ON_IOBUSY(sp18); - HW_REG(ASIC_BM_CTL, u32) = BUFFER_MANAGER_RESET | sp1c->bmCtlShadow; //should be unk10?? - WAIT_ON_IOBUSY(sp18); - HW_REG(ASIC_BM_CTL, u32) = sp1c->bmCtlShadow; - func_802F4B08(); - HW_REG(PI_STATUS_REG, u32) = PI_STATUS_CLEAR_INTR; - __OSGlobalIntMask |= 0x00100401; // TODO: fix magic numbers -} - -typedef struct OSEventMessageStruct_0_s { - OSMesgQueue *queue; - OSMesg msg; -} OSEventMessageStruct_0; - -extern OSEventMessageStruct_0 __osEventStateTab[16]; // should be OS_NUM_EVENTS + 1 I think - -void func_802F4B08(void) { - OSEventMessageStruct_0 *sp2c; - OSMesgQueue *sp28; - u32 sp24; - register OSThread *s0; - sp2c = &__osEventStateTab[OS_EVENT_PI]; - sp28 = sp2c->queue; - if (!sp28 || sp28->validCount >= sp28->msgCount) { - return; - } - sp24 = (sp28->first + sp28->validCount) % sp28->msgCount; - sp28->msg[sp24] = sp2c->msg; - sp28->validCount++; - if (sp28->mtqueue->next != NULL) { - s0 = __osPopThread(&sp28->mtqueue); - __osEnqueueThread(&D_80334898, s0); - } -} diff --git a/lib/src/func_802F71F0.c b/lib/src/func_802F71F0.c deleted file mode 100644 index e829ae47..00000000 --- a/lib/src/func_802F71F0.c +++ /dev/null @@ -1,8 +0,0 @@ -#include "libultra_internal.h" - -void func_802F71F0(void) { - register u32 s0 = __osDisableInt(); - D_803348A0->state = OS_STATE_RUNNABLE; - __osEnqueueAndYield(&D_80334898); - __osRestoreInt(s0); -} diff --git a/lib/src/guMtxF2L.c b/lib/src/guMtxF2L.c index 2b9d9359..e2ec7a5a 100644 --- a/lib/src/guMtxF2L.c +++ b/lib/src/guMtxF2L.c @@ -3,6 +3,8 @@ #include #endif +#if !defined(VERSION_CN) || !defined(TARGET_N64) + #ifndef GBI_FLOATS void guMtxF2L(float mf[4][4], Mtx *m) { int r, c; @@ -68,3 +70,5 @@ void guMtxIdent(Mtx *m) { guMtxIdentF(m->m); #endif } + +#endif diff --git a/lib/src/guNormalize.c b/lib/src/guNormalize.c index 3ac2f00b..2f8a5aa3 100644 --- a/lib/src/guNormalize.c +++ b/lib/src/guNormalize.c @@ -1,8 +1,12 @@ #include "libultra_internal.h" +#if !defined(VERSION_CN) || !defined(TARGET_N64) + void guNormalize(f32 *x, f32 *y, f32 *z) { f32 tmp = 1.0f / sqrtf(*x * *x + *y * *y + *z * *z); *x = *x * tmp; *y = *y * tmp; *z = *z * tmp; } + +#endif diff --git a/lib/src/guRotateF.c b/lib/src/guRotateF.c index c71093ae..748265ba 100644 --- a/lib/src/guRotateF.c +++ b/lib/src/guRotateF.c @@ -1,38 +1,70 @@ #include "libultra_internal.h" void guRotateF(float m[4][4], float a, float x, float y, float z) { - float sin_a; - float cos_a; - float sp2c; - float sp28; - float sp24; - float xx, yy, zz; - static float D_80365D70 = GU_PI / 180; + static f32 pi_180 = GU_PI / 180.0f; + f32 sin_a; + f32 cos_a; + f32 ab; + f32 bc; + f32 ca; + f32 t; +#ifdef VERSION_CN + f32 xs; + f32 ys; + f32 zs; +#else + f32 xx, yy, zz; +#endif guNormalize(&x, &y, &z); - a = a * D_80365D70; + a = a * pi_180; sin_a = sinf(a); cos_a = cosf(a); + t = 1 - cos_a; - sp2c = x * y * (1 - cos_a); - sp28 = y * z * (1 - cos_a); - sp24 = z * x * (1 - cos_a); + ab = x * y * t; + bc = y * z * t; + ca = z * x * t; guMtxIdentF(m); + + // TODO: Merge IDO/GCC +#ifdef VERSION_CN + xs = x * sin_a; + t = x * x; + m[0][0] = t + cos_a * (1 - t); + m[2][1] = bc - xs; + m[1][2] = bc + xs; + + ys = y * sin_a; + t = y * y; + m[1][1] = t + cos_a * (1 - t); + m[2][0] = ca + ys; + m[0][2] = ca - ys; + + zs = z * sin_a; + t = z * z; + m[2][2] = t + cos_a * (1 - t); + m[1][0] = ab - zs; + m[0][1] = ab + zs; +#else xx = x * x; - m[0][0] = (1 - xx) * cos_a + xx; - m[2][1] = sp28 - x * sin_a; - m[1][2] = sp28 + x * sin_a; + m[0][0] = xx + cos_a * (1 - xx); + m[2][1] = bc - (x * sin_a); + m[1][2] = bc + (x * sin_a); + yy = y * y; - m[1][1] = (1 - yy) * cos_a + yy; - m[2][0] = sp24 + y * sin_a; - m[0][2] = sp24 - y * sin_a; + m[1][1] = yy + cos_a * (1 - yy); + m[2][0] = ca + (y * sin_a); + m[0][2] = ca - (y * sin_a); + zz = z * z; - m[2][2] = (1 - zz) * cos_a + zz; - m[1][0] = sp2c - z * sin_a; - m[0][1] = sp2c + z * sin_a; + m[2][2] = zz + cos_a * (1 - zz); + m[1][0] = ab - (z * sin_a); + m[0][1] = ab + (z * sin_a); +#endif } void guRotate(Mtx *m, float a, float x, float y, float z) { diff --git a/lib/src/guScaleF.c b/lib/src/guScaleF.c index 15de4c69..b900a1e2 100644 --- a/lib/src/guScaleF.c +++ b/lib/src/guScaleF.c @@ -1,5 +1,7 @@ #include "libultra_internal.h" +#if !defined(VERSION_CN) || !defined(TARGET_N64) + void guScaleF(float mf[4][4], float x, float y, float z) { guMtxIdentF(mf); mf[0][0] = x; @@ -13,3 +15,5 @@ void guScale(Mtx *m, float x, float y, float z) { guScaleF(mf, x, y, z); guMtxF2L(mf, m); } + +#endif diff --git a/lib/src/guTranslateF.c b/lib/src/guTranslateF.c index 179a6a7d..e0dc1f1e 100644 --- a/lib/src/guTranslateF.c +++ b/lib/src/guTranslateF.c @@ -1,5 +1,7 @@ #include "libultra_internal.h" +#if !defined(VERSION_CN) || !defined(TARGET_N64) + void guTranslateF(float m[4][4], float x, float y, float z) { guMtxIdentF(m); m[3][0] = x; @@ -12,3 +14,5 @@ void guTranslate(Mtx *m, float x, float y, float z) { guTranslateF(mf, x, y, z); guMtxF2L(mf, m); } + +#endif diff --git a/lib/src/hardware.h b/lib/src/hardware.h deleted file mode 100644 index 564e814c..00000000 --- a/lib/src/hardware.h +++ /dev/null @@ -1,127 +0,0 @@ -#ifndef _HARDWARE_H_ -#define _HARDWARE_H_ - -#define HW_REG(reg, type) *(volatile type *)(uintptr_t)((reg) | 0xa0000000) - -#define AI_DRAM_ADDR_REG 0x04500000 -#define AI_LEN_REG 0x04500004 -#define AI_CONTROL_REG 0x04500008 -#define AI_STATUS_REG 0x0450000C -#define AI_STATUS_AI_FULL (1 << 31) -#define AI_STATUS_AI_BUSY (1 << 30) -#define AI_DACRATE_REG 0x04500010 -#define AI_BITRATE_REG 0x04500014 - -#define VI_STATUS_REG 0x04400000 -#define VI_CONTROL_REG 0x04400000 -#define VI_ORIGIN_REG 0x04400004 -#define VI_DRAM_ADDR_REG 0x04400004 -#define VI_WIDTH_REG 0x04400008 -#define VI_H_WIDTH_REG 0x04400008 -#define VI_INTR_REG 0x0440000C -#define VI_V_INTER_REG 0x0440000C -#define VI_CURRENT_REG 0x04400010 -#define VI_V_CURRENT_LINE_REG 0x04400010 -#define VI_BURST_REG 0x04400014 -#define VI_TIMING_REG 0x04400014 -#define VI_V_SYNC_REG 0x04400018 //VI vertical sync -#define VI_H_SYNC_REG 0x0440001C //VI horizontal sync -#define VI_LEAP_REG 0x04400020 //VI horizontal sync leap -#define VI_H_SYNC_LEAP_REG 0x04400020 -#define VI_H_START_REG 0x04400024 //VI horizontal video -#define VI_H_VIDEO_REG 0x04400024 -#define VI_V_START_REG 0x04400028 //VI vertical video -#define VI_V_VIDEO_REG 0x04400028 -#define VI_V_BURST_REG 0x0440002C //VI vertical burst -#define VI_X_SCALE_REG 0x04400030 //VI x-scale -#define VI_Y_SCALE_REG 0x04400034 //VI y-scale - -#define SP_IMEM_START 0x04001000 -#define SP_DMEM_START 0x04000000 - -#define SP_MEM_ADDR_REG 0x04040000 -#define SP_DRAM_ADDR_REG 0x04040004 -#define SP_RD_LEN_REG 0x04040008 -#define SP_WR_LEN_REG 0x0404000C -#define SP_STATUS_REG 0x04040010 -#define SP_PC_REG 0x04080000 - -#define PI_DRAM_ADDR_REG 0x04600000 //PI DRAM address -#define PI_CART_ADDR_REG 0x04600004 //PI pbus (cartridge) address -#define PI_RD_LEN_REG 0x04600008 //PI read length -#define PI_WR_LEN_REG 0x0460000C //PI write length -#define PI_STATUS_REG 0x04600010 //PI status -#define PI_BSD_DOM1_LAT_REG 0x04600014 //PI dom1 latency -#define PI_DOMAIN1_REG 0x04600014 -#define PI_BSD_DOM1_PWD_REG 0x04600018 //PI dom1 pulse width -#define PI_BSD_DOM1_PGS_REG 0x0460001C //PI dom1 page size -#define PI_BSD_DOM1_RLS_REG 0x04600020 //PI dom1 release -#define PI_BSD_DOM2_LAT_REG 0x04600024 //PI dom2 latency -#define PI_DOMAIN2_REG 0x04600024 -#define PI_BSD_DOM2_PWD_REG 0x04600028 //PI dom2 pulse width -#define PI_BSD_DOM2_PGS_REG 0x0460002C //PI dom2 page size -#define PI_BSD_DOM2_RLS_REG 0x04600030 //PI dom2 release - -#define PI_STATUS_BUSY 0x1 -#define PI_STATUS_IOBUSY 0x2 -#define PI_STATUS_ERROR 0x3 - -#define PI_STATUS_RESET_CONTROLLER 0x1 -#define PI_STATUS_CLEAR_INTR 0x2 - -#define SI_DRAM_ADDR_REG 0x04800000 -#define SI_PIF_ADDR_RD64B_REG 0x04800004 -#define SI_PIF_ADDR_WR64B_REG 0x04800010 -#define SI_STATUS_REG 0x04800018 - -#define SI_STATUS_DMA_BUSY 0x1 -#define SI_STATUS_IO_READ_BUSY 0x2 -#define SI_STATUS_DMA_ERROR 0x8 -#define SI_STATUS_INTERRUPT (1 << 12) - -#define MI_INIT_MODE_REG 0x04300000 -#define MI_MODE_REG MI_INIT_MODE_REG -#define MI_VERSION_REG 0x04300004 -#define MI_INTR_REG 0x04300008 -#define MI_INTR_MASK_REG 0x0430000C - -//https://github.com/LuigiBlood/64dd/wiki/Registers -#define ASIC_STATUS 0x05000508 - -#define DATA_REQUEST 0x40000000 -#define C2_TRANSFER 0x10000000 -#define BUFFER_MANAGER_ERROR 0x08000000 -#define BUFFER_MANAGER_INTERRUPT 0x04000000 -#define MECHANIC_INTERRUPT 0x02000000 -#define DISK_PRESENT 0x01000000 -#define BUSY_STATE 0x00800000 -#define RESET_STATE 0x00400000 -#define MOTOR_NOT_SPINNING 0x00100000 -#define HEAD_RETRACTED 0x00080000 -#define WRITE_PROTECT_ERROR 0x00040000 -#define MECHANIC_ERROR 0x00020000 -#define DISK_CHANGE 0x00010000 - -#define _64DD_PRESENT_MASK 0xFFFF - - -//ro -#define ASIC_BM_STATUS 0x05000510 - -#define MICRO_STATUS 0x02000000 -#define C1_DOUBLE 0x00400000 -#define C1_SINGLE 0x00200000 - -//wo -#define ASIC_BM_CTL 0x05000510 -#define BUFFER_MANAGER_RESET 0x10000000 -#define MECHANIC_INTERRUPT_RESET 0x01000000 -/*- Start Buffer Manager (0x80000000) -- Buffer Manager Mode (0x40000000) -- BM Interrupt Mask (0x20000000) -- Buffer Manager Reset (0x10000000) -- Disable OR Check? (0x08000000) -- Disable C1 Correction (0x04000000) -- Block Transfer (0x02000000) -- Mechanic Interrupt Reset (0x01000000)*/ -#endif diff --git a/lib/src/kdebugserver.c b/lib/src/kdebugserver.c index f35b67d3..2515763b 100644 --- a/lib/src/kdebugserver.c +++ b/lib/src/kdebugserver.c @@ -1,22 +1,17 @@ #include "libultra_internal.h" +#include "PR/rdb.h" -typedef struct { - u8 unk00 : 2; - u8 pad : 4; - u8 unk01 : 2; - u8 unk2[3]; -} unkStruct; +#ifndef VERSION_CN +static s32 debugState = 0; +static s32 numChars = 0; +static s32 numCharsToReceive = 0; +#endif -extern u32 D_80334A44; +extern u8 debugBuffer[0x100]; -u32 D_80334A30 = 0; -u32 D_80334A34 = 0; -s32 D_80334A38 = 0; - -extern u8 D_80365E40[0x100]; - -OSThread gInterruptedThread; +OSThread __osThreadSave; +#ifndef VERSION_CN void u32_to_string(u32 i, u8 *str) { str[0] = (i >> 0x18) & 0xff; str[1] = (i >> 0x10) & 0xff; @@ -34,29 +29,29 @@ u32 string_to_u32(u8 *str) { } void send_packet(u8 *a0, s32 a1) { - unkStruct sp1c; + rdbPacket pkt; s32 i; - sp1c.unk00 = 2; - for (sp1c.unk01 = a1, i = 0; i < a1; i++) { - sp1c.unk2[i] = a0[i]; + pkt.type = 2; + for (pkt.length = a1, i = 0; i < a1; i++) { + pkt.buf[i] = a0[i]; } - *(volatile u32 *) 0xc0000000 = *(u32 *) &sp1c; + *(volatile u32 *) RDB_BASE_REG = *(u32 *) &pkt; while (!(__osGetCause() & 0x2000)) { ; } - *(volatile u32 *) 0xc000000c = 0; + *(volatile u32 *) RDB_READ_INTR_REG = 0; } void send(u8 *buff, s32 len) { s32 i; s32 end; s32 rem; - if (!D_80334A44) { + if (!__osRdbWriteOK) { while (!(__osGetCause() & 0x2000)) { ; } - *(volatile u32 *) 0xc000000c = 0; - D_80334A44 = 1; + *(volatile u32 *) RDB_READ_INTR_REG = 0; + __osRdbWriteOK = 1; } i = 0; rem = len % 3; @@ -72,62 +67,63 @@ void send(u8 *buff, s32 len) { void process_command_memory(void) { u32 sp1c; u32 sp18; - sp1c = string_to_u32(&D_80365E40[1]); - sp18 = string_to_u32(&D_80365E40[5]); + sp1c = string_to_u32(&debugBuffer[1]); + sp18 = string_to_u32(&debugBuffer[5]); send((u8 *) (uintptr_t) sp1c, sp18); } void process_command_register(void) { - send((u8 *) &gInterruptedThread.context, sizeof(__OSThreadContext)); + send((u8 *) &__osThreadSave.context, sizeof(__OSThreadContext)); } void kdebugserver(u32 a0) { u32 sp2c; - unkStruct sp28; - *(u32 *) &sp28 = a0; - for (sp2c = 0; sp2c < sp28.unk01; sp2c++) { - D_80365E40[D_80334A34] = sp28.unk2[sp2c]; - D_80334A34++; + rdbPacket pkt; + *(u32 *) &pkt = a0; + for (sp2c = 0; sp2c < pkt.length; sp2c++) { + debugBuffer[numChars] = pkt.buf[sp2c]; + numChars++; } - D_80334A38 -= sp28.unk01; - switch (D_80334A30) { + numCharsToReceive -= pkt.length; + switch (debugState) { case 0: - switch (sp28.unk2[0]) { + switch (pkt.buf[0]) { case 1: - D_80334A30 = 1; - D_80334A38 = 9 - sp28.unk01; + debugState = 1; + numCharsToReceive = 9 - pkt.length; break; case 2: process_command_register(); - D_80334A30 = 0; - D_80334A34 = 0; - D_80334A38 = 0; + debugState = 0; + numChars = 0; + numCharsToReceive = 0; break; default: - D_80334A30 = 0; - D_80334A34 = 0; - D_80334A38 = 0; + debugState = 0; + numChars = 0; + numCharsToReceive = 0; break; } break; case 1: - if (D_80334A38 <= 0) { - if (D_80365E40[0] == 1) { + if (numCharsToReceive <= 0) { + if (debugBuffer[0] == 1) { process_command_memory(); - D_80334A30 = 0; - D_80334A34 = 0; - D_80334A38 = 0; + debugState = 0; + numChars = 0; + numCharsToReceive = 0; } else { - D_80334A30 = 0; - D_80334A34 = 0; - D_80334A38 = 0; + debugState = 0; + numChars = 0; + numCharsToReceive = 0; } } break; default: - D_80334A30 = 0; - D_80334A34 = 0; - D_80334A38 = 0; + debugState = 0; + numChars = 0; + numCharsToReceive = 0; break; } } +#endif diff --git a/lib/src/kdebugserver_stack.c b/lib/src/kdebugserver_stack.c index 62dd6151..13f88633 100644 --- a/lib/src/kdebugserver_stack.c +++ b/lib/src/kdebugserver_stack.c @@ -1,5 +1,5 @@ #include "libultra_internal.h" #if defined(VERSION_JP) || defined(VERSION_US) -u8 D_80365E40[0x100]; +u8 debugBuffer[0x100]; #endif diff --git a/lib/src/ldiv.c b/lib/src/ldiv.c index 01b04be2..566ad173 100644 --- a/lib/src/ldiv.c +++ b/lib/src/ldiv.c @@ -1,6 +1,23 @@ #include "libultra_internal.h" #include +// for some reason the order of the functions has been swapped + +#ifdef VERSION_CN +ldiv_t ldiv(long num, long denom) { + ldiv_t ret; + + ret.quot = num / denom; + ret.rem = num - denom * ret.quot; + if (ret.quot < 0 && ret.rem > 0) { + ret.quot++; + ret.rem -= denom; + } + + return ret; +} +#endif + lldiv_t lldiv(long long num, long long denom) { lldiv_t ret; @@ -14,6 +31,7 @@ lldiv_t lldiv(long long num, long long denom) { return ret; } +#ifndef VERSION_CN ldiv_t ldiv(long num, long denom) { ldiv_t ret; @@ -26,3 +44,4 @@ ldiv_t ldiv(long num, long denom) { return ret; } +#endif diff --git a/lib/src/leointerrupt.c b/lib/src/leointerrupt.c index 83a4f39e..32ffb2b7 100644 --- a/lib/src/leointerrupt.c +++ b/lib/src/leointerrupt.c @@ -1,67 +1,112 @@ #include "libultra_internal.h" #include "PR/rcp.h" #include "bstring.h" +#include "new_func.h" +#include "macros.h" #include "piint.h" #include "osint.h" u8 leoDiskStack[OS_PIM_STACKSIZE]; // technically should have a OS_LEO_STACKSIZE or something.. -#ifdef VERSION_SH - -// TODO: so many magic constants :'( static void __osLeoResume(void); static void __osLeoAbnormalResume(void); -s32 __osLeoInterrupt() { +s32 __osLeoInterrupt(void) { u32 stat; +#ifdef VERSION_EU + u32 pi_stat; +#else // VERSION_SH volatile u32 pi_stat; +#endif u32 bm_stat; __OSTranxInfo *info; __OSBlockInfo *blockInfo; + +#ifdef VERSION_EU + if (!osDDActive) { + return 0; + } +#else // VERSION_SH stat = 0; +#endif + info = &__osDiskHandle->transferInfo; blockInfo = &info->block[info->blockNum]; pi_stat = IO_READ(PI_STATUS_REG); if (pi_stat & PI_STATUS_DMA_BUSY) { +#ifdef VERSION_EU + IO_WRITE(PI_STATUS_REG, PI_STATUS_RESET | PI_STATUS_CLR_INTR); + WAIT_ON_LEO_IO_BUSY(pi_stat); + stat = IO_READ(LEO_STATUS); + if (stat & LEO_STATUS_MECHANIC_INTERRUPT) { + WAIT_ON_LEO_IO_BUSY(pi_stat); + IO_WRITE(LEO_BM_CTL, info->bmCtlShadow | LEO_BM_CTL_CLR_MECHANIC_INTR); + } + info->errStatus = LEO_ERROR_75; + __osLeoAbnormalResume(); +#else // VERSION_SH __OSGlobalIntMask = __OSGlobalIntMask & ~SR_IBIT4; //cartridge interrupt blockInfo->errStatus = LEO_ERROR_29; __osLeoResume(); +#endif return 1; } - WAIT_ON_IOBUSY(pi_stat); + WAIT_ON_LEO_IO_BUSY(pi_stat); stat = IO_READ(LEO_STATUS); if (stat & LEO_STATUS_MECHANIC_INTERRUPT) { - WAIT_ON_IOBUSY(pi_stat); + WAIT_ON_LEO_IO_BUSY(pi_stat); IO_WRITE(LEO_BM_CTL, info->bmCtlShadow | LEO_BM_CTL_CLR_MECHANIC_INTR); +#ifdef VERSION_EU + info->errStatus = LEO_ERROR_GOOD; +#else // VERSION_SH blockInfo->errStatus = LEO_ERROR_GOOD; +#endif return 0; } + +#ifdef VERSION_SH if (info->cmdType == LEO_CMD_TYPE_2) { return 1; } +#endif + if (stat & LEO_STATUS_BUFFER_MANAGER_ERROR) { - WAIT_ON_IOBUSY(pi_stat); +#ifdef VERSION_EU + info->errStatus = LEO_ERROR_3; + __osLeoAbnormalResume(); +#else //VERSION_SH + WAIT_ON_LEO_IO_BUSY(pi_stat); stat = IO_READ(LEO_STATUS); blockInfo->errStatus = LEO_ERROR_22; __osLeoResume(); IO_WRITE(PI_STATUS_REG, PI_STATUS_CLR_INTR); __OSGlobalIntMask |= OS_IM_PI; +#endif return 1; } + if (info->cmdType == LEO_CMD_TYPE_1) { if ((stat & LEO_STATUS_DATA_REQUEST) == 0) { if (info->sectorNum + 1 != info->transferMode * 85) { +#ifdef VERSION_EU + info->errStatus = LEO_ERROR_6; +#else // VERSION_SH blockInfo->errStatus = LEO_ERROR_24; +#endif __osLeoAbnormalResume(); return 1; } IO_WRITE(PI_STATUS_REG, PI_STATUS_CLR_INTR); __OSGlobalIntMask |= OS_IM_PI; +#ifdef VERSION_EU + info->errStatus = LEO_ERROR_GOOD; +#else // VERSION_SH blockInfo->errStatus = LEO_ERROR_GOOD; +#endif __osLeoResume(); return 1; } - blockInfo->dramAddr = (void *)((u32)blockInfo->dramAddr + blockInfo->sectorSize); + blockInfo->dramAddr = (void *) ((u32)blockInfo->dramAddr + blockInfo->sectorSize); info->sectorNum++; osEPiRawStartDma(__osDiskHandle, OS_WRITE, LEO_SECTOR_BUFF, blockInfo->dramAddr, blockInfo->sectorSize); return 1; @@ -69,12 +114,20 @@ s32 __osLeoInterrupt() { if (info->cmdType == LEO_CMD_TYPE_0) { if (info->transferMode == LEO_SECTOR_MODE) { if ((s32)blockInfo->C1ErrNum + 17 < info->sectorNum) { +#ifdef VERSION_EU + info->errStatus = LEO_ERROR_GOOD; +#else // VERSION_SH blockInfo->errStatus = LEO_ERROR_GOOD; +#endif __osLeoAbnormalResume(); return 1; } if ((stat & LEO_STATUS_DATA_REQUEST) == 0) { +#ifdef VERSION_EU + info->errStatus = LEO_ERROR_17; +#else // VERSION_SH blockInfo->errStatus = LEO_ERROR_23; +#endif __osLeoAbnormalResume(); return 1; } @@ -85,68 +138,107 @@ s32 __osLeoInterrupt() { if ((bm_stat & LEO_BM_STATUS_C1SINGLE && bm_stat & LEO_BM_STATUS_C1DOUBLE) || bm_stat & LEO_BM_STATUS_MICRO) { if (blockInfo->C1ErrNum > 3) { if (info->transferMode != LEO_SECTOR_MODE || info->sectorNum > 0x52) { - blockInfo->errStatus = LEO_ERROR_23; +#ifdef VERSION_EU + info->errStatus = LEO_ERROR_17; +#else // VERSION_SH + blockInfo->errStatus = LEO_ERROR_23; +#endif __osLeoAbnormalResume(); return 1; } } else { - int errNum = blockInfo->C1ErrNum; + s32 errNum = blockInfo->C1ErrNum; blockInfo->C1ErrSector[errNum] = info->sectorNum + 1; } blockInfo->C1ErrNum++; } + if (stat & LEO_STATUS_C2_TRANSFER) { if (info->sectorNum != 87) { +#ifdef VERSION_EU + info->errStatus = LEO_ERROR_6; +#else // VERSION_SH blockInfo->errStatus = LEO_ERROR_24; +#endif __osLeoAbnormalResume(); } if (info->transferMode == LEO_TRACK_MODE && info->blockNum == 0) { info->blockNum = 1; info->sectorNum = -1; info->block[1].dramAddr = (void *)((u32)info->block[1].dramAddr - info->block[1].sectorSize); - +#ifdef VERSION_SH blockInfo->errStatus = LEO_ERROR_22; +#endif } else { IO_WRITE(PI_STATUS_REG, PI_STATUS_CLR_INTR); __OSGlobalIntMask |= OS_IM_PI; +#ifdef VERSION_SH info->cmdType = LEO_CMD_TYPE_2; blockInfo->errStatus = LEO_ERROR_GOOD; +#endif } osEPiRawStartDma(__osDiskHandle, OS_READ, LEO_C2_BUFF, blockInfo->C2Addr, blockInfo->sectorSize * 4); +#ifdef VERSION_EU + info->errStatus = LEO_ERROR_GOOD; +#endif return 1; } - if (info->sectorNum == -1 && info->transferMode == LEO_TRACK_MODE && info->blockNum == 1) { __OSBlockInfo *bptr = &info->block[0]; if (bptr->C1ErrNum == 0) { if (((u32 *)bptr->C2Addr)[0] | ((u32 *)bptr->C2Addr)[1] | ((u32 *)bptr->C2Addr)[2] | ((u32 *)bptr->C2Addr)[3]) { - bptr->errStatus = LEO_ERROR_24; +#ifdef VERSION_EU + info->errStatus = LEO_ERROR_6; +#else // VERSION_SH + bptr->errStatus = LEO_ERROR_24; +#endif __osLeoAbnormalResume(); return 1; } } - bptr->errStatus = 0; +#ifdef VERSION_EU + info->errStatus = LEO_ERROR_GOOD; +#else // VERSION_SH + bptr->errStatus = LEO_ERROR_GOOD; +#endif __osLeoResume(); } info->sectorNum++; if (stat & LEO_STATUS_DATA_REQUEST) { if (info->sectorNum > 0x54) { +#ifdef VERSION_EU + info->errStatus = LEO_ERROR_6; +#else // VERSION_SH blockInfo->errStatus = LEO_ERROR_24; +#endif __osLeoAbnormalResume(); return 1; } osEPiRawStartDma(__osDiskHandle, 0, LEO_SECTOR_BUFF, blockInfo->dramAddr, blockInfo->sectorSize); - blockInfo->errStatus = LEO_ERROR_GOOD; +#ifdef VERSION_EU + info->errStatus = LEO_ERROR_GOOD; +#else // VERSION_SH + blockInfo->errStatus = LEO_ERROR_GOOD; +#endif return 1; } if (info->sectorNum <= 0x54) { +#ifdef VERSION_EU + info->errStatus = LEO_ERROR_6; +#else // VERSION_SH blockInfo->errStatus = LEO_ERROR_24; +#endif __osLeoAbnormalResume(); return 1; } return 1; } +#ifdef VERSION_EU + info->errStatus = LEO_ERROR_75; +#else // VERSION_SH blockInfo->errStatus = LEO_ERROR_4; +#endif + __osLeoAbnormalResume(); return 1; } @@ -155,9 +247,9 @@ static void __osLeoAbnormalResume(void) { __OSTranxInfo *info; u32 pi_stat; info = &__osDiskHandle->transferInfo; - WAIT_ON_IOBUSY(pi_stat); + WAIT_ON_LEO_IO_BUSY(pi_stat); IO_WRITE(LEO_BM_CTL, info->bmCtlShadow | LEO_BM_CTL_RESET); - WAIT_ON_IOBUSY(pi_stat); + WAIT_ON_LEO_IO_BUSY(pi_stat); IO_WRITE(LEO_BM_CTL, info->bmCtlShadow); __osLeoResume(); IO_WRITE(PI_STATUS_REG, PI_STATUS_CLR_INTR); @@ -177,8 +269,6 @@ static void __osLeoResume(void) { mq->msg[last] = es->message; mq->validCount++; if (mq->mtqueue->next != NULL) { - __osEnqueueThread(&D_80334898, __osPopThread(&mq->mtqueue)); + __osEnqueueThread(&__osRunQueue, __osPopThread(&mq->mtqueue)); } } - -#endif diff --git a/lib/src/libgcc/_cmpdi2.c b/lib/src/libgcc/_cmpdi2.c new file mode 100644 index 00000000..e7407d72 --- /dev/null +++ b/lib/src/libgcc/_cmpdi2.c @@ -0,0 +1,2 @@ +#define L_cmpdi2 +#include "libgcc2.inc" diff --git a/lib/src/libgcc/_divdi3.c b/lib/src/libgcc/_divdi3.c new file mode 100644 index 00000000..01efcaa8 --- /dev/null +++ b/lib/src/libgcc/_divdi3.c @@ -0,0 +1,2 @@ +#define L_divdi3 +#include "libgcc2.inc" diff --git a/lib/src/libgcc/_fixdfdi.c b/lib/src/libgcc/_fixdfdi.c new file mode 100644 index 00000000..856d6805 --- /dev/null +++ b/lib/src/libgcc/_fixdfdi.c @@ -0,0 +1,2 @@ +#define L_fixdfdi +#include "libgcc2.inc" diff --git a/lib/src/libgcc/_fixsfdi.c b/lib/src/libgcc/_fixsfdi.c new file mode 100644 index 00000000..86e089b7 --- /dev/null +++ b/lib/src/libgcc/_fixsfdi.c @@ -0,0 +1,2 @@ +#define L_fixsfdi +#include "libgcc2.inc" diff --git a/lib/src/libgcc/_fixunsdfdi.c b/lib/src/libgcc/_fixunsdfdi.c new file mode 100644 index 00000000..c6460614 --- /dev/null +++ b/lib/src/libgcc/_fixunsdfdi.c @@ -0,0 +1,2 @@ +#define L_fixunsdfdi +#include "libgcc2.inc" diff --git a/lib/src/libgcc/_fixunssfdi.c b/lib/src/libgcc/_fixunssfdi.c new file mode 100644 index 00000000..5b1b0689 --- /dev/null +++ b/lib/src/libgcc/_fixunssfdi.c @@ -0,0 +1,2 @@ +#define L_fixunssfdi +#include "libgcc2.inc" diff --git a/lib/src/libgcc/_floatdidf.c b/lib/src/libgcc/_floatdidf.c new file mode 100644 index 00000000..e358a370 --- /dev/null +++ b/lib/src/libgcc/_floatdidf.c @@ -0,0 +1,2 @@ +#define L_floatdidf +#include "libgcc2.inc" diff --git a/lib/src/libgcc/_floatdisf.c b/lib/src/libgcc/_floatdisf.c new file mode 100644 index 00000000..e5293c5a --- /dev/null +++ b/lib/src/libgcc/_floatdisf.c @@ -0,0 +1,2 @@ +#define L_floatdisf +#include "libgcc2.inc" diff --git a/lib/src/libgcc/_moddi3.c b/lib/src/libgcc/_moddi3.c new file mode 100644 index 00000000..f4494999 --- /dev/null +++ b/lib/src/libgcc/_moddi3.c @@ -0,0 +1,2 @@ +#define L_moddi3 +#include "libgcc2.inc" diff --git a/lib/src/libgcc/_udivdi3.c b/lib/src/libgcc/_udivdi3.c new file mode 100644 index 00000000..36892ea3 --- /dev/null +++ b/lib/src/libgcc/_udivdi3.c @@ -0,0 +1,2 @@ +#define L_udivdi3 +#include "libgcc2.inc" diff --git a/lib/src/libgcc/_umoddi3.c b/lib/src/libgcc/_umoddi3.c new file mode 100644 index 00000000..adfde87a --- /dev/null +++ b/lib/src/libgcc/_umoddi3.c @@ -0,0 +1,2 @@ +#define L_umoddi3 +#include "libgcc2.inc" diff --git a/lib/src/libgcc/libgcc2.inc b/lib/src/libgcc/libgcc2.inc new file mode 100644 index 00000000..5eda40ea --- /dev/null +++ b/lib/src/libgcc/libgcc2.inc @@ -0,0 +1,4021 @@ +// This file is copied from gcc 2.95.2 +// tconfig.h, machmode.h, defaults.h and stddef.h have been un-included + +#define LIBGCC2_WORDS_BIG_ENDIAN 1 +#define BITS_PER_UNIT 8 +#define inhibit_libc + +/* More subroutines needed by GCC output code on some machines. */ +/* Compile this one with gcc. */ +/* Copyright (C) 1989, 92-98, 1999 Free Software Foundation, Inc. + +This file is part of GNU CC. + +GNU CC is free software; you can redistribute it and/or modify +it under the terms of the GNU General Public License as published by +the Free Software Foundation; either version 2, or (at your option) +any later version. + +GNU CC is distributed in the hope that it will be useful, +but WITHOUT ANY WARRANTY; without even the implied warranty of +MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +GNU General Public License for more details. + +You should have received a copy of the GNU General Public License +along with GNU CC; see the file COPYING. If not, write to +the Free Software Foundation, 59 Temple Place - Suite 330, +Boston, MA 02111-1307, USA. */ + +/* As a special exception, if you link this library with other files, + some of which are compiled with GCC, to produce an executable, + this library does not by itself cause the resulting executable + to be covered by the GNU General Public License. + This exception does not however invalidate any other reasons why + the executable file might be covered by the GNU General Public License. */ + +/* It is incorrect to include config.h here, because this file is being + compiled for the target, and hence definitions concerning only the host + do not apply. */ + +//#include "tconfig.h" + +/* We disable this when inhibit_libc, so that gcc can still be built without + needing header files first. */ +/* ??? This is not a good solution, since prototypes may be required in + some cases for correct code. See also frame.c. */ +#ifndef inhibit_libc +/* fixproto guarantees these system headers exist. */ +#include +#include +#endif + +//#include "machmode.h" +//#include "defaults.h" +#ifndef L_trampoline +//#include +#endif + +/* Don't use `fancy_abort' here even if config.h says to use it. */ +#ifdef abort +#undef abort +#endif + +#if (SUPPORTS_WEAK == 1) && (defined (ASM_OUTPUT_DEF) || defined (ASM_OUTPUT_WEAK_ALIAS)) +#define WEAK_ALIAS +#endif + +/* In a cross-compilation situation, default to inhibiting compilation + of routines that use libc. */ + +#if defined(CROSS_COMPILE) && !defined(inhibit_libc) +#define inhibit_libc +#endif + +/* Permit the tm.h file to select the endianness to use just for this + file. This is used when the endianness is determined when the + compiler is run. */ + +#ifndef LIBGCC2_WORDS_BIG_ENDIAN +#define LIBGCC2_WORDS_BIG_ENDIAN WORDS_BIG_ENDIAN +#endif + +#ifndef LIBGCC2_LONG_DOUBLE_TYPE_SIZE +#define LIBGCC2_LONG_DOUBLE_TYPE_SIZE LONG_DOUBLE_TYPE_SIZE +#endif + +/* In the first part of this file, we are interfacing to calls generated + by the compiler itself. These calls pass values into these routines + which have very specific modes (rather than very specific types), and + these compiler-generated calls also expect any return values to have + very specific modes (rather than very specific types). Thus, we need + to avoid using regular C language type names in this part of the file + because the sizes for those types can be configured to be anything. + Instead we use the following special type names. */ + +typedef unsigned int UQItype __attribute__ ((mode (QI))); +typedef int SItype __attribute__ ((mode (SI))); +typedef unsigned int USItype __attribute__ ((mode (SI))); +typedef int DItype __attribute__ ((mode (DI))); +typedef unsigned int UDItype __attribute__ ((mode (DI))); + +typedef float SFtype __attribute__ ((mode (SF))); +typedef float DFtype __attribute__ ((mode (DF))); + +#if LIBGCC2_LONG_DOUBLE_TYPE_SIZE == 96 +typedef float XFtype __attribute__ ((mode (XF))); +#endif +#if LIBGCC2_LONG_DOUBLE_TYPE_SIZE == 128 +typedef float TFtype __attribute__ ((mode (TF))); +#endif + +typedef int word_type __attribute__ ((mode (__word__))); + +/* Make sure that we don't accidentally use any normal C language built-in + type names in the first part of this file. Instead we want to use *only* + the type names defined above. The following macro definitions insure + that if we *do* accidentally use some normal C language built-in type name, + we will get a syntax error. */ + +#define char bogus_type +#define short bogus_type +#define int bogus_type +#define long bogus_type +#define unsigned bogus_type +#define float bogus_type +#define double bogus_type + +#define SI_TYPE_SIZE (sizeof (SItype) * BITS_PER_UNIT) + +/* DIstructs are pairs of SItype values in the order determined by + LIBGCC2_WORDS_BIG_ENDIAN. */ + +#if LIBGCC2_WORDS_BIG_ENDIAN + struct DIstruct {SItype high, low;}; +#else + struct DIstruct {SItype low, high;}; +#endif + +/* We need this union to unpack/pack DImode values, since we don't have + any arithmetic yet. Incoming DImode parameters are stored into the + `ll' field, and the unpacked result is read from the struct `s'. */ + +typedef union +{ + struct DIstruct s; + DItype ll; +} DIunion; + +#if (defined (L_udivmoddi4) || defined (L_muldi3) || defined (L_udiv_w_sdiv)\ + || defined (L_divdi3) || defined (L_udivdi3) \ + || defined (L_moddi3) || defined (L_umoddi3)) + +#include "longlong.h" + +#endif /* udiv or mul */ + +extern DItype __fixunssfdi (SFtype a); +extern DItype __fixunsdfdi (DFtype a); +#if LIBGCC2_LONG_DOUBLE_TYPE_SIZE == 96 +extern DItype __fixunsxfdi (XFtype a); +#endif +#if LIBGCC2_LONG_DOUBLE_TYPE_SIZE == 128 +extern DItype __fixunstfdi (TFtype a); +#endif + +#if defined (L_negdi2) || defined (L_divdi3) || defined (L_moddi3) +#if defined (L_divdi3) || defined (L_moddi3) +static inline +#endif +DItype +__negdi2 (DItype u) +{ + DIunion w; + DIunion uu; + + uu.ll = u; + + w.s.low = -uu.s.low; + w.s.high = -uu.s.high - ((USItype) w.s.low > 0); + + return w.ll; +} +#endif + +/* Unless shift functions are defined whith full ANSI prototypes, + parameter b will be promoted to int if word_type is smaller than an int. */ +#ifdef L_lshrdi3 +DItype +__lshrdi3 (DItype u, word_type b) +{ + DIunion w; + word_type bm; + DIunion uu; + + if (b == 0) + return u; + + uu.ll = u; + + bm = (sizeof (SItype) * BITS_PER_UNIT) - b; + if (bm <= 0) + { + w.s.high = 0; + w.s.low = (USItype)uu.s.high >> -bm; + } + else + { + USItype carries = (USItype)uu.s.high << bm; + w.s.high = (USItype)uu.s.high >> b; + w.s.low = ((USItype)uu.s.low >> b) | carries; + } + + return w.ll; +} +#endif + +#ifdef L_ashldi3 +DItype +__ashldi3 (DItype u, word_type b) +{ + DIunion w; + word_type bm; + DIunion uu; + + if (b == 0) + return u; + + uu.ll = u; + + bm = (sizeof (SItype) * BITS_PER_UNIT) - b; + if (bm <= 0) + { + w.s.low = 0; + w.s.high = (USItype)uu.s.low << -bm; + } + else + { + USItype carries = (USItype)uu.s.low >> bm; + w.s.low = (USItype)uu.s.low << b; + w.s.high = ((USItype)uu.s.high << b) | carries; + } + + return w.ll; +} +#endif + +#ifdef L_ashrdi3 +DItype +__ashrdi3 (DItype u, word_type b) +{ + DIunion w; + word_type bm; + DIunion uu; + + if (b == 0) + return u; + + uu.ll = u; + + bm = (sizeof (SItype) * BITS_PER_UNIT) - b; + if (bm <= 0) + { + /* w.s.high = 1..1 or 0..0 */ + w.s.high = uu.s.high >> (sizeof (SItype) * BITS_PER_UNIT - 1); + w.s.low = uu.s.high >> -bm; + } + else + { + USItype carries = (USItype)uu.s.high << bm; + w.s.high = uu.s.high >> b; + w.s.low = ((USItype)uu.s.low >> b) | carries; + } + + return w.ll; +} +#endif + +#ifdef L_ffsdi2 +DItype +__ffsdi2 (DItype u) +{ + DIunion uu, w; + uu.ll = u; + w.s.high = 0; + w.s.low = ffs (uu.s.low); + if (w.s.low != 0) + return w.ll; + w.s.low = ffs (uu.s.high); + if (w.s.low != 0) + { + w.s.low += BITS_PER_UNIT * sizeof (SItype); + return w.ll; + } + return w.ll; +} +#endif + +#ifdef L_muldi3 +DItype +__muldi3 (DItype u, DItype v) +{ + DIunion w; + DIunion uu, vv; + + uu.ll = u, + vv.ll = v; + + w.ll = __umulsidi3 (uu.s.low, vv.s.low); + w.s.high += ((USItype) uu.s.low * (USItype) vv.s.high + + (USItype) uu.s.high * (USItype) vv.s.low); + + return w.ll; +} +#endif + +#ifdef L_udiv_w_sdiv +#if defined (sdiv_qrnnd) +USItype +__udiv_w_sdiv (USItype *rp, USItype a1, USItype a0, USItype d) +{ + USItype q, r; + USItype c0, c1, b1; + + if ((SItype) d >= 0) + { + if (a1 < d - a1 - (a0 >> (SI_TYPE_SIZE - 1))) + { + /* dividend, divisor, and quotient are nonnegative */ + sdiv_qrnnd (q, r, a1, a0, d); + } + else + { + /* Compute c1*2^32 + c0 = a1*2^32 + a0 - 2^31*d */ + sub_ddmmss (c1, c0, a1, a0, d >> 1, d << (SI_TYPE_SIZE - 1)); + /* Divide (c1*2^32 + c0) by d */ + sdiv_qrnnd (q, r, c1, c0, d); + /* Add 2^31 to quotient */ + q += (USItype) 1 << (SI_TYPE_SIZE - 1); + } + } + else + { + b1 = d >> 1; /* d/2, between 2^30 and 2^31 - 1 */ + c1 = a1 >> 1; /* A/2 */ + c0 = (a1 << (SI_TYPE_SIZE - 1)) + (a0 >> 1); + + if (a1 < b1) /* A < 2^32*b1, so A/2 < 2^31*b1 */ + { + sdiv_qrnnd (q, r, c1, c0, b1); /* (A/2) / (d/2) */ + + r = 2*r + (a0 & 1); /* Remainder from A/(2*b1) */ + if ((d & 1) != 0) + { + if (r >= q) + r = r - q; + else if (q - r <= d) + { + r = r - q + d; + q--; + } + else + { + r = r - q + 2*d; + q -= 2; + } + } + } + else if (c1 < b1) /* So 2^31 <= (A/2)/b1 < 2^32 */ + { + c1 = (b1 - 1) - c1; + c0 = ~c0; /* logical NOT */ + + sdiv_qrnnd (q, r, c1, c0, b1); /* (A/2) / (d/2) */ + + q = ~q; /* (A/2)/b1 */ + r = (b1 - 1) - r; + + r = 2*r + (a0 & 1); /* A/(2*b1) */ + + if ((d & 1) != 0) + { + if (r >= q) + r = r - q; + else if (q - r <= d) + { + r = r - q + d; + q--; + } + else + { + r = r - q + 2*d; + q -= 2; + } + } + } + else /* Implies c1 = b1 */ + { /* Hence a1 = d - 1 = 2*b1 - 1 */ + if (a0 >= -d) + { + q = -1; + r = a0 + d; + } + else + { + q = -2; + r = a0 + 2*d; + } + } + } + + *rp = r; + return q; +} +#else +/* If sdiv_qrnnd doesn't exist, define dummy __udiv_w_sdiv. */ +USItype +__udiv_w_sdiv (USItype *rp __attribute__ ((__unused__)), + USItype a1 __attribute__ ((__unused__)), + USItype a0 __attribute__ ((__unused__)), + USItype d __attribute__ ((__unused__))) +{ + return 0; +} +#endif +#endif + +#if (defined (L_udivdi3) || defined (L_divdi3) || \ + defined (L_umoddi3) || defined (L_moddi3)) +#define L_udivmoddi4 +#endif + +#ifdef L_udivmoddi4 +static const UQItype __clz_tab[] = +{ + 0,1,2,2,3,3,3,3,4,4,4,4,4,4,4,4,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5, + 6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6, + 7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7, + 7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7, + 8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8, + 8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8, + 8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8, + 8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8, +}; + +#if (defined (L_udivdi3) || defined (L_divdi3) || \ + defined (L_umoddi3) || defined (L_moddi3)) +static inline +#endif +UDItype +__udivmoddi4 (UDItype n, UDItype d, UDItype *rp) +{ + DIunion ww; + DIunion nn, dd; + DIunion rr; + USItype d0, d1, n0, n1, n2; + USItype q0, q1; + USItype b, bm; + + nn.ll = n; + dd.ll = d; + + d0 = dd.s.low; + d1 = dd.s.high; + n0 = nn.s.low; + n1 = nn.s.high; + +#if !UDIV_NEEDS_NORMALIZATION + if (d1 == 0) + { + if (d0 > n1) + { + /* 0q = nn / 0D */ + + udiv_qrnnd (q0, n0, n1, n0, d0); + q1 = 0; + + /* Remainder in n0. */ + } + else + { + /* qq = NN / 0d */ + + if (d0 == 0) + d0 = 1 / d0; /* Divide intentionally by zero. */ + + udiv_qrnnd (q1, n1, 0, n1, d0); + udiv_qrnnd (q0, n0, n1, n0, d0); + + /* Remainder in n0. */ + } + + if (rp != 0) + { + rr.s.low = n0; + rr.s.high = 0; + *rp = rr.ll; + } + } + +#else /* UDIV_NEEDS_NORMALIZATION */ + + if (d1 == 0) + { + if (d0 > n1) + { + /* 0q = nn / 0D */ + + count_leading_zeros (bm, d0); + + if (bm != 0) + { + /* Normalize, i.e. make the most significant bit of the + denominator set. */ + + d0 = d0 << bm; + n1 = (n1 << bm) | (n0 >> (SI_TYPE_SIZE - bm)); + n0 = n0 << bm; + } + + udiv_qrnnd (q0, n0, n1, n0, d0); + q1 = 0; + + /* Remainder in n0 >> bm. */ + } + else + { + /* qq = NN / 0d */ + + if (d0 == 0) + d0 = 1 / d0; /* Divide intentionally by zero. */ + + count_leading_zeros (bm, d0); + + if (bm == 0) + { + /* From (n1 >= d0) /\ (the most significant bit of d0 is set), + conclude (the most significant bit of n1 is set) /\ (the + leading quotient digit q1 = 1). + + This special case is necessary, not an optimization. + (Shifts counts of SI_TYPE_SIZE are undefined.) */ + + n1 -= d0; + q1 = 1; + } + else + { + /* Normalize. */ + + b = SI_TYPE_SIZE - bm; + + d0 = d0 << bm; + n2 = n1 >> b; + n1 = (n1 << bm) | (n0 >> b); + n0 = n0 << bm; + + udiv_qrnnd (q1, n1, n2, n1, d0); + } + + /* n1 != d0... */ + + udiv_qrnnd (q0, n0, n1, n0, d0); + + /* Remainder in n0 >> bm. */ + } + + if (rp != 0) + { + rr.s.low = n0 >> bm; + rr.s.high = 0; + *rp = rr.ll; + } + } +#endif /* UDIV_NEEDS_NORMALIZATION */ + + else + { + if (d1 > n1) + { + /* 00 = nn / DD */ + + q0 = 0; + q1 = 0; + + /* Remainder in n1n0. */ + if (rp != 0) + { + rr.s.low = n0; + rr.s.high = n1; + *rp = rr.ll; + } + } + else + { + /* 0q = NN / dd */ + + count_leading_zeros (bm, d1); + if (bm == 0) + { + /* From (n1 >= d1) /\ (the most significant bit of d1 is set), + conclude (the most significant bit of n1 is set) /\ (the + quotient digit q0 = 0 or 1). + + This special case is necessary, not an optimization. */ + + /* The condition on the next line takes advantage of that + n1 >= d1 (true due to program flow). */ + if (n1 > d1 || n0 >= d0) + { + q0 = 1; + sub_ddmmss (n1, n0, n1, n0, d1, d0); + } + else + q0 = 0; + + q1 = 0; + + if (rp != 0) + { + rr.s.low = n0; + rr.s.high = n1; + *rp = rr.ll; + } + } + else + { + USItype m1, m0; + /* Normalize. */ + + b = SI_TYPE_SIZE - bm; + + d1 = (d1 << bm) | (d0 >> b); + d0 = d0 << bm; + n2 = n1 >> b; + n1 = (n1 << bm) | (n0 >> b); + n0 = n0 << bm; + + udiv_qrnnd (q0, n1, n2, n1, d1); + umul_ppmm (m1, m0, q0, d0); + + if (m1 > n1 || (m1 == n1 && m0 > n0)) + { + q0--; + sub_ddmmss (m1, m0, m1, m0, d1, d0); + } + + q1 = 0; + + /* Remainder in (n1n0 - m1m0) >> bm. */ + if (rp != 0) + { + sub_ddmmss (n1, n0, n1, n0, m1, m0); + rr.s.low = (n1 << b) | (n0 >> bm); + rr.s.high = n1 >> bm; + *rp = rr.ll; + } + } + } + } + + ww.s.low = q0; + ww.s.high = q1; + return ww.ll; +} +#endif + +#ifdef L_divdi3 +UDItype __udivmoddi4 (); + +DItype +__divdi3 (DItype u, DItype v) +{ + word_type c = 0; + DIunion uu, vv; + DItype w; + + uu.ll = u; + vv.ll = v; + + if (uu.s.high < 0) + c = ~c, + uu.ll = __negdi2 (uu.ll); + if (vv.s.high < 0) + c = ~c, + vv.ll = __negdi2 (vv.ll); + + w = __udivmoddi4 (uu.ll, vv.ll, (UDItype *) 0); + if (c) + w = __negdi2 (w); + + return w; +} +#endif + +#ifdef L_moddi3 +UDItype __udivmoddi4 (); +DItype +__moddi3 (DItype u, DItype v) +{ + word_type c = 0; + DIunion uu, vv; + DItype w; + + uu.ll = u; + vv.ll = v; + + if (uu.s.high < 0) + c = ~c, + uu.ll = __negdi2 (uu.ll); + if (vv.s.high < 0) + vv.ll = __negdi2 (vv.ll); + + (void) __udivmoddi4 (uu.ll, vv.ll, &w); + if (c) + w = __negdi2 (w); + + return w; +} +#endif + +#ifdef L_umoddi3 +UDItype __udivmoddi4 (); +UDItype +__umoddi3 (UDItype u, UDItype v) +{ + UDItype w; + + (void) __udivmoddi4 (u, v, &w); + + return w; +} +#endif + +#ifdef L_udivdi3 +UDItype __udivmoddi4 (); +UDItype +__udivdi3 (UDItype n, UDItype d) +{ + return __udivmoddi4 (n, d, (UDItype *) 0); +} +#endif + +#ifdef L_cmpdi2 +word_type +__cmpdi2 (DItype a, DItype b) +{ + DIunion au, bu; + + au.ll = a, bu.ll = b; + + if (au.s.high < bu.s.high) + return 0; + else if (au.s.high > bu.s.high) + return 2; + if ((USItype) au.s.low < (USItype) bu.s.low) + return 0; + else if ((USItype) au.s.low > (USItype) bu.s.low) + return 2; + return 1; +} +#endif + +#ifdef L_ucmpdi2 +word_type +__ucmpdi2 (DItype a, DItype b) +{ + DIunion au, bu; + + au.ll = a, bu.ll = b; + + if ((USItype) au.s.high < (USItype) bu.s.high) + return 0; + else if ((USItype) au.s.high > (USItype) bu.s.high) + return 2; + if ((USItype) au.s.low < (USItype) bu.s.low) + return 0; + else if ((USItype) au.s.low > (USItype) bu.s.low) + return 2; + return 1; +} +#endif + +#if defined(L_fixunstfdi) && (LIBGCC2_LONG_DOUBLE_TYPE_SIZE == 128) +#define WORD_SIZE (sizeof (SItype) * BITS_PER_UNIT) +#define HIGH_WORD_COEFF (((UDItype) 1) << WORD_SIZE) + +DItype +__fixunstfdi (TFtype a) +{ + TFtype b; + UDItype v; + + if (a < 0) + return 0; + + /* Compute high word of result, as a flonum. */ + b = (a / HIGH_WORD_COEFF); + /* Convert that to fixed (but not to DItype!), + and shift it into the high word. */ + v = (USItype) b; + v <<= WORD_SIZE; + /* Remove high part from the TFtype, leaving the low part as flonum. */ + a -= (TFtype)v; + /* Convert that to fixed (but not to DItype!) and add it in. + Sometimes A comes out negative. This is significant, since + A has more bits than a long int does. */ + if (a < 0) + v -= (USItype) (- a); + else + v += (USItype) a; + return v; +} +#endif + +#if defined(L_fixtfdi) && (LIBGCC2_LONG_DOUBLE_TYPE_SIZE == 128) +DItype +__fixtfdi (TFtype a) +{ + if (a < 0) + return - __fixunstfdi (-a); + return __fixunstfdi (a); +} +#endif + +#if defined(L_fixunsxfdi) && (LIBGCC2_LONG_DOUBLE_TYPE_SIZE == 96) +#define WORD_SIZE (sizeof (SItype) * BITS_PER_UNIT) +#define HIGH_WORD_COEFF (((UDItype) 1) << WORD_SIZE) + +DItype +__fixunsxfdi (XFtype a) +{ + XFtype b; + UDItype v; + + if (a < 0) + return 0; + + /* Compute high word of result, as a flonum. */ + b = (a / HIGH_WORD_COEFF); + /* Convert that to fixed (but not to DItype!), + and shift it into the high word. */ + v = (USItype) b; + v <<= WORD_SIZE; + /* Remove high part from the XFtype, leaving the low part as flonum. */ + a -= (XFtype)v; + /* Convert that to fixed (but not to DItype!) and add it in. + Sometimes A comes out negative. This is significant, since + A has more bits than a long int does. */ + if (a < 0) + v -= (USItype) (- a); + else + v += (USItype) a; + return v; +} +#endif + +#if defined(L_fixxfdi) && (LIBGCC2_LONG_DOUBLE_TYPE_SIZE == 96) +DItype +__fixxfdi (XFtype a) +{ + if (a < 0) + return - __fixunsxfdi (-a); + return __fixunsxfdi (a); +} +#endif + +#ifdef L_fixunsdfdi +#define WORD_SIZE (sizeof (SItype) * BITS_PER_UNIT) +#define HIGH_WORD_COEFF (((UDItype) 1) << WORD_SIZE) + +DItype +__fixunsdfdi (DFtype a) +{ + DFtype b; + UDItype v; + + if (a < 0) + return 0; + + /* Compute high word of result, as a flonum. */ + b = (a / HIGH_WORD_COEFF); + /* Convert that to fixed (but not to DItype!), + and shift it into the high word. */ + v = (USItype) b; + v <<= WORD_SIZE; + /* Remove high part from the DFtype, leaving the low part as flonum. */ + a -= (DFtype)v; + /* Convert that to fixed (but not to DItype!) and add it in. + Sometimes A comes out negative. This is significant, since + A has more bits than a long int does. */ + if (a < 0) + v -= (USItype) (- a); + else + v += (USItype) a; + return v; +} +#endif + +#ifdef L_fixdfdi +DItype +__fixdfdi (DFtype a) +{ + if (a < 0) + return - __fixunsdfdi (-a); + return __fixunsdfdi (a); +} +#endif + +#ifdef L_fixunssfdi +#define WORD_SIZE (sizeof (SItype) * BITS_PER_UNIT) +#define HIGH_WORD_COEFF (((UDItype) 1) << WORD_SIZE) + +DItype +__fixunssfdi (SFtype original_a) +{ + /* Convert the SFtype to a DFtype, because that is surely not going + to lose any bits. Some day someone else can write a faster version + that avoids converting to DFtype, and verify it really works right. */ + DFtype a = original_a; + DFtype b; + UDItype v; + + if (a < 0) + return 0; + + /* Compute high word of result, as a flonum. */ + b = (a / HIGH_WORD_COEFF); + /* Convert that to fixed (but not to DItype!), + and shift it into the high word. */ + v = (USItype) b; + v <<= WORD_SIZE; + /* Remove high part from the DFtype, leaving the low part as flonum. */ + a -= (DFtype)v; + /* Convert that to fixed (but not to DItype!) and add it in. + Sometimes A comes out negative. This is significant, since + A has more bits than a long int does. */ + if (a < 0) + v -= (USItype) (- a); + else + v += (USItype) a; + return v; +} +#endif + +#ifdef L_fixsfdi +DItype +__fixsfdi (SFtype a) +{ + if (a < 0) + return - __fixunssfdi (-a); + return __fixunssfdi (a); +} +#endif + +#if defined(L_floatdixf) && (LIBGCC2_LONG_DOUBLE_TYPE_SIZE == 96) +#define WORD_SIZE (sizeof (SItype) * BITS_PER_UNIT) +#define HIGH_HALFWORD_COEFF (((UDItype) 1) << (WORD_SIZE / 2)) +#define HIGH_WORD_COEFF (((UDItype) 1) << WORD_SIZE) + +XFtype +__floatdixf (DItype u) +{ + XFtype d; + + d = (SItype) (u >> WORD_SIZE); + d *= HIGH_HALFWORD_COEFF; + d *= HIGH_HALFWORD_COEFF; + d += (USItype) (u & (HIGH_WORD_COEFF - 1)); + + return d; +} +#endif + +#if defined(L_floatditf) && (LIBGCC2_LONG_DOUBLE_TYPE_SIZE == 128) +#define WORD_SIZE (sizeof (SItype) * BITS_PER_UNIT) +#define HIGH_HALFWORD_COEFF (((UDItype) 1) << (WORD_SIZE / 2)) +#define HIGH_WORD_COEFF (((UDItype) 1) << WORD_SIZE) + +TFtype +__floatditf (DItype u) +{ + TFtype d; + + d = (SItype) (u >> WORD_SIZE); + d *= HIGH_HALFWORD_COEFF; + d *= HIGH_HALFWORD_COEFF; + d += (USItype) (u & (HIGH_WORD_COEFF - 1)); + + return d; +} +#endif + +#ifdef L_floatdidf +#define WORD_SIZE (sizeof (SItype) * BITS_PER_UNIT) +#define HIGH_HALFWORD_COEFF (((UDItype) 1) << (WORD_SIZE / 2)) +#define HIGH_WORD_COEFF (((UDItype) 1) << WORD_SIZE) + +DFtype +__floatdidf (DItype u) +{ + DFtype d; + + d = (SItype) (u >> WORD_SIZE); + d *= HIGH_HALFWORD_COEFF; + d *= HIGH_HALFWORD_COEFF; + d += (USItype) (u & (HIGH_WORD_COEFF - 1)); + + return d; +} +#endif + +#ifdef L_floatdisf +#define WORD_SIZE (sizeof (SItype) * BITS_PER_UNIT) +#define HIGH_HALFWORD_COEFF (((UDItype) 1) << (WORD_SIZE / 2)) +#define HIGH_WORD_COEFF (((UDItype) 1) << WORD_SIZE) +#define DI_SIZE (sizeof (DItype) * BITS_PER_UNIT) + +/* Define codes for all the float formats that we know of. Note + that this is copied from real.h. */ + +#define UNKNOWN_FLOAT_FORMAT 0 +#define IEEE_FLOAT_FORMAT 1 +#define VAX_FLOAT_FORMAT 2 +#define IBM_FLOAT_FORMAT 3 + +/* Default to IEEE float if not specified. Nearly all machines use it. */ +#ifndef HOST_FLOAT_FORMAT +#define HOST_FLOAT_FORMAT IEEE_FLOAT_FORMAT +#endif + +#if HOST_FLOAT_FORMAT == IEEE_FLOAT_FORMAT +#define DF_SIZE 53 +#define SF_SIZE 24 +#endif + +#if HOST_FLOAT_FORMAT == IBM_FLOAT_FORMAT +#define DF_SIZE 56 +#define SF_SIZE 24 +#endif + +#if HOST_FLOAT_FORMAT == VAX_FLOAT_FORMAT +#define DF_SIZE 56 +#define SF_SIZE 24 +#endif + +SFtype +__floatdisf (DItype u) +{ + /* Do the calculation in DFmode + so that we don't lose any of the precision of the high word + while multiplying it. */ + DFtype f; + + /* Protect against double-rounding error. + Represent any low-order bits, that might be truncated in DFmode, + by a bit that won't be lost. The bit can go in anywhere below the + rounding position of the SFmode. A fixed mask and bit position + handles all usual configurations. It doesn't handle the case + of 128-bit DImode, however. */ + if (DF_SIZE < DI_SIZE + && DF_SIZE > (DI_SIZE - DF_SIZE + SF_SIZE)) + { +#define REP_BIT ((USItype) 1 << (DI_SIZE - DF_SIZE)) + if (! (- ((DItype) 1 << DF_SIZE) < u + && u < ((DItype) 1 << DF_SIZE))) + { + if ((USItype) u & (REP_BIT - 1)) + u |= REP_BIT; + } + } + f = (SItype) (u >> WORD_SIZE); + f *= HIGH_HALFWORD_COEFF; + f *= HIGH_HALFWORD_COEFF; + f += (USItype) (u & (HIGH_WORD_COEFF - 1)); + + return (SFtype) f; +} +#endif + +#if defined(L_fixunsxfsi) && LIBGCC2_LONG_DOUBLE_TYPE_SIZE == 96 +/* Reenable the normal types, in case limits.h needs them. */ +#undef char +#undef short +#undef int +#undef long +#undef unsigned +#undef float +#undef double +#undef MIN +#undef MAX +#include + +USItype +__fixunsxfsi (XFtype a) +{ + if (a >= - (DFtype) LONG_MIN) + return (SItype) (a + LONG_MIN) - LONG_MIN; + return (SItype) a; +} +#endif + +#ifdef L_fixunsdfsi +/* Reenable the normal types, in case limits.h needs them. */ +#undef char +#undef short +#undef int +#undef long +#undef unsigned +#undef float +#undef double +#undef MIN +#undef MAX +#include + +USItype +__fixunsdfsi (DFtype a) +{ + if (a >= - (DFtype) LONG_MIN) + return (SItype) (a + LONG_MIN) - LONG_MIN; + return (SItype) a; +} +#endif + +#ifdef L_fixunssfsi +/* Reenable the normal types, in case limits.h needs them. */ +#undef char +#undef short +#undef int +#undef long +#undef unsigned +#undef float +#undef double +#undef MIN +#undef MAX +#include + +USItype +__fixunssfsi (SFtype a) +{ + if (a >= - (SFtype) LONG_MIN) + return (SItype) (a + LONG_MIN) - LONG_MIN; + return (SItype) a; +} +#endif + +/* From here on down, the routines use normal data types. */ + +#define SItype bogus_type +#define USItype bogus_type +#define DItype bogus_type +#define UDItype bogus_type +#define SFtype bogus_type +#define DFtype bogus_type + +#undef char +#undef short +#undef int +#undef long +#undef unsigned +#undef float +#undef double + +#ifdef L__gcc_bcmp + +/* Like bcmp except the sign is meaningful. + Result is negative if S1 is less than S2, + positive if S1 is greater, 0 if S1 and S2 are equal. */ + +int +__gcc_bcmp (unsigned char *s1, unsigned char *s2, size_t size) +{ + while (size > 0) + { + unsigned char c1 = *s1++, c2 = *s2++; + if (c1 != c2) + return c1 - c2; + size--; + } + return 0; +} + +#endif + +#ifdef L__dummy +void +__dummy () {} +#endif + +#ifdef L_varargs +#ifdef __i860__ +#if defined(__svr4__) || defined(__alliant__) + asm (" .text"); + asm (" .align 4"); + +/* The Alliant needs the added underscore. */ + asm (".globl __builtin_saveregs"); +asm ("__builtin_saveregs:"); + asm (".globl ___builtin_saveregs"); +asm ("___builtin_saveregs:"); + + asm (" andnot 0x0f,%sp,%sp"); /* round down to 16-byte boundary */ + asm (" adds -96,%sp,%sp"); /* allocate stack space for reg save + area and also for a new va_list + structure */ + /* Save all argument registers in the arg reg save area. The + arg reg save area must have the following layout (according + to the svr4 ABI): + + struct { + union { + float freg[8]; + double dreg[4]; + } float_regs; + long ireg[12]; + }; + */ + + asm (" fst.q %f8, 0(%sp)"); /* save floating regs (f8-f15) */ + asm (" fst.q %f12,16(%sp)"); + + asm (" st.l %r16,32(%sp)"); /* save integer regs (r16-r27) */ + asm (" st.l %r17,36(%sp)"); + asm (" st.l %r18,40(%sp)"); + asm (" st.l %r19,44(%sp)"); + asm (" st.l %r20,48(%sp)"); + asm (" st.l %r21,52(%sp)"); + asm (" st.l %r22,56(%sp)"); + asm (" st.l %r23,60(%sp)"); + asm (" st.l %r24,64(%sp)"); + asm (" st.l %r25,68(%sp)"); + asm (" st.l %r26,72(%sp)"); + asm (" st.l %r27,76(%sp)"); + + asm (" adds 80,%sp,%r16"); /* compute the address of the new + va_list structure. Put in into + r16 so that it will be returned + to the caller. */ + + /* Initialize all fields of the new va_list structure. This + structure looks like: + + typedef struct { + unsigned long ireg_used; + unsigned long freg_used; + long *reg_base; + long *mem_ptr; + } va_list; + */ + + asm (" st.l %r0, 0(%r16)"); /* nfixed */ + asm (" st.l %r0, 4(%r16)"); /* nfloating */ + asm (" st.l %sp, 8(%r16)"); /* __va_ctl points to __va_struct. */ + asm (" bri %r1"); /* delayed return */ + asm (" st.l %r28,12(%r16)"); /* pointer to overflow args */ + +#else /* not __svr4__ */ +#if defined(__PARAGON__) + /* + * we'll use SVR4-ish varargs but need SVR3.2 assembler syntax, + * and we stand a better chance of hooking into libraries + * compiled by PGI. [andyp@ssd.intel.com] + */ + asm (" .text"); + asm (" .align 4"); + asm (".globl __builtin_saveregs"); +asm ("__builtin_saveregs:"); + asm (".globl ___builtin_saveregs"); +asm ("___builtin_saveregs:"); + + asm (" andnot 0x0f,sp,sp"); /* round down to 16-byte boundary */ + asm (" adds -96,sp,sp"); /* allocate stack space for reg save + area and also for a new va_list + structure */ + /* Save all argument registers in the arg reg save area. The + arg reg save area must have the following layout (according + to the svr4 ABI): + + struct { + union { + float freg[8]; + double dreg[4]; + } float_regs; + long ireg[12]; + }; + */ + + asm (" fst.q f8, 0(sp)"); + asm (" fst.q f12,16(sp)"); + asm (" st.l r16,32(sp)"); + asm (" st.l r17,36(sp)"); + asm (" st.l r18,40(sp)"); + asm (" st.l r19,44(sp)"); + asm (" st.l r20,48(sp)"); + asm (" st.l r21,52(sp)"); + asm (" st.l r22,56(sp)"); + asm (" st.l r23,60(sp)"); + asm (" st.l r24,64(sp)"); + asm (" st.l r25,68(sp)"); + asm (" st.l r26,72(sp)"); + asm (" st.l r27,76(sp)"); + + asm (" adds 80,sp,r16"); /* compute the address of the new + va_list structure. Put in into + r16 so that it will be returned + to the caller. */ + + /* Initialize all fields of the new va_list structure. This + structure looks like: + + typedef struct { + unsigned long ireg_used; + unsigned long freg_used; + long *reg_base; + long *mem_ptr; + } va_list; + */ + + asm (" st.l r0, 0(r16)"); /* nfixed */ + asm (" st.l r0, 4(r16)"); /* nfloating */ + asm (" st.l sp, 8(r16)"); /* __va_ctl points to __va_struct. */ + asm (" bri r1"); /* delayed return */ + asm (" st.l r28,12(r16)"); /* pointer to overflow args */ +#else /* not __PARAGON__ */ + asm (" .text"); + asm (" .align 4"); + + asm (".globl ___builtin_saveregs"); + asm ("___builtin_saveregs:"); + asm (" mov sp,r30"); + asm (" andnot 0x0f,sp,sp"); + asm (" adds -96,sp,sp"); /* allocate sufficient space on the stack */ + +/* Fill in the __va_struct. */ + asm (" st.l r16, 0(sp)"); /* save integer regs (r16-r27) */ + asm (" st.l r17, 4(sp)"); /* int fixed[12] */ + asm (" st.l r18, 8(sp)"); + asm (" st.l r19,12(sp)"); + asm (" st.l r20,16(sp)"); + asm (" st.l r21,20(sp)"); + asm (" st.l r22,24(sp)"); + asm (" st.l r23,28(sp)"); + asm (" st.l r24,32(sp)"); + asm (" st.l r25,36(sp)"); + asm (" st.l r26,40(sp)"); + asm (" st.l r27,44(sp)"); + + asm (" fst.q f8, 48(sp)"); /* save floating regs (f8-f15) */ + asm (" fst.q f12,64(sp)"); /* int floating[8] */ + +/* Fill in the __va_ctl. */ + asm (" st.l sp, 80(sp)"); /* __va_ctl points to __va_struct. */ + asm (" st.l r28,84(sp)"); /* pointer to more args */ + asm (" st.l r0, 88(sp)"); /* nfixed */ + asm (" st.l r0, 92(sp)"); /* nfloating */ + + asm (" adds 80,sp,r16"); /* return address of the __va_ctl. */ + asm (" bri r1"); + asm (" mov r30,sp"); + /* recover stack and pass address to start + of data. */ +#endif /* not __PARAGON__ */ +#endif /* not __svr4__ */ +#else /* not __i860__ */ +#ifdef __sparc__ + asm (".global __builtin_saveregs"); + asm ("__builtin_saveregs:"); + asm (".global ___builtin_saveregs"); + asm ("___builtin_saveregs:"); +#ifdef NEED_PROC_COMMAND + asm (".proc 020"); +#endif + asm ("st %i0,[%fp+68]"); + asm ("st %i1,[%fp+72]"); + asm ("st %i2,[%fp+76]"); + asm ("st %i3,[%fp+80]"); + asm ("st %i4,[%fp+84]"); + asm ("retl"); + asm ("st %i5,[%fp+88]"); +#ifdef NEED_TYPE_COMMAND + asm (".type __builtin_saveregs,#function"); + asm (".size __builtin_saveregs,.-__builtin_saveregs"); +#endif +#else /* not __sparc__ */ +#if defined(__MIPSEL__) | defined(__R3000__) | defined(__R2000__) | defined(__mips__) + + asm (" .text"); +#ifdef __mips16 + asm (" .set nomips16"); +#endif + asm (" .ent __builtin_saveregs"); + asm (" .globl __builtin_saveregs"); + asm ("__builtin_saveregs:"); + asm (" sw $4,0($30)"); + asm (" sw $5,4($30)"); + asm (" sw $6,8($30)"); + asm (" sw $7,12($30)"); + asm (" j $31"); + asm (" .end __builtin_saveregs"); +#else /* not __mips__, etc. */ + +void * +__builtin_saveregs () +{ + abort (); +} + +#endif /* not __mips__ */ +#endif /* not __sparc__ */ +#endif /* not __i860__ */ +#endif + +#ifdef L_eprintf +#ifndef inhibit_libc + +#undef NULL /* Avoid errors if stdio.h and our stddef.h mismatch. */ +#include +/* This is used by the `assert' macro. */ +extern void __eprintf (const char *, const char *, unsigned int, const char *) + __attribute__ ((__noreturn__)); + +void +__eprintf (const char *string, const char *expression, + unsigned int line, const char *filename) +{ + fprintf (stderr, string, expression, line, filename); + fflush (stderr); + abort (); +} + +#endif +#endif + +#ifdef L_bb + +/* Structure emitted by -a */ +struct bb +{ + long zero_word; + const char *filename; + long *counts; + long ncounts; + struct bb *next; + const unsigned long *addresses; + + /* Older GCC's did not emit these fields. */ + long nwords; + const char **functions; + const long *line_nums; + const char **filenames; + char *flags; +}; + +#ifdef BLOCK_PROFILER_CODE +BLOCK_PROFILER_CODE +#else +#ifndef inhibit_libc + +/* Simple minded basic block profiling output dumper for + systems that don't provide tcov support. At present, + it requires atexit and stdio. */ + +#undef NULL /* Avoid errors if stdio.h and our stddef.h mismatch. */ +#include +char *ctime (); + +#include "gbl-ctors.h" +#include "gcov-io.h" +#include + +static struct bb *bb_head; + +/* Return the number of digits needed to print a value */ +/* __inline__ */ static int num_digits (long value, int base) +{ + int minus = (value < 0 && base != 16); + unsigned long v = (minus) ? -value : value; + int ret = minus; + + do + { + v /= base; + ret++; + } + while (v); + + return ret; +} + +void +__bb_exit_func (void) +{ + FILE *da_file, *file; + long time_value; + int i; + + if (bb_head == 0) + return; + + i = strlen (bb_head->filename) - 3; + + if (!strcmp (bb_head->filename+i, ".da")) + { + /* Must be -fprofile-arcs not -a. + Dump data in a form that gcov expects. */ + + struct bb *ptr; + + for (ptr = bb_head; ptr != (struct bb *) 0; ptr = ptr->next) + { + /* If the file exists, and the number of counts in it is the same, + then merge them in. */ + + if ((da_file = fopen (ptr->filename, "r")) != 0) + { + long n_counts = 0; + + if (__read_long (&n_counts, da_file, 8) != 0) + { + fprintf (stderr, "arc profiling: Can't read output file %s.\n", + ptr->filename); + continue; + } + + if (n_counts == ptr->ncounts) + { + int i; + + for (i = 0; i < n_counts; i++) + { + long v = 0; + + if (__read_long (&v, da_file, 8) != 0) + { + fprintf (stderr, "arc profiling: Can't read output file %s.\n", + ptr->filename); + break; + } + ptr->counts[i] += v; + } + } + + if (fclose (da_file) == EOF) + fprintf (stderr, "arc profiling: Error closing output file %s.\n", + ptr->filename); + } + if ((da_file = fopen (ptr->filename, "w")) == 0) + { + fprintf (stderr, "arc profiling: Can't open output file %s.\n", + ptr->filename); + continue; + } + + /* ??? Should first write a header to the file. Preferably, a 4 byte + magic number, 4 bytes containing the time the program was + compiled, 4 bytes containing the last modification time of the + source file, and 4 bytes indicating the compiler options used. + + That way we can easily verify that the proper source/executable/ + data file combination is being used from gcov. */ + + if (__write_long (ptr->ncounts, da_file, 8) != 0) + { + + fprintf (stderr, "arc profiling: Error writing output file %s.\n", + ptr->filename); + } + else + { + int j; + long *count_ptr = ptr->counts; + int ret = 0; + for (j = ptr->ncounts; j > 0; j--) + { + if (__write_long (*count_ptr, da_file, 8) != 0) + { + ret=1; + break; + } + count_ptr++; + } + if (ret) + fprintf (stderr, "arc profiling: Error writing output file %s.\n", + ptr->filename); + } + + if (fclose (da_file) == EOF) + fprintf (stderr, "arc profiling: Error closing output file %s.\n", + ptr->filename); + } + + return; + } + + /* Must be basic block profiling. Emit a human readable output file. */ + + file = fopen ("bb.out", "a"); + + if (!file) + perror ("bb.out"); + + else + { + struct bb *ptr; + + /* This is somewhat type incorrect, but it avoids worrying about + exactly where time.h is included from. It should be ok unless + a void * differs from other pointer formats, or if sizeof (long) + is < sizeof (time_t). It would be nice if we could assume the + use of rationale standards here. */ + + time ((void *) &time_value); + fprintf (file, "Basic block profiling finished on %s\n", ctime ((void *) &time_value)); + + /* We check the length field explicitly in order to allow compatibility + with older GCC's which did not provide it. */ + + for (ptr = bb_head; ptr != (struct bb *) 0; ptr = ptr->next) + { + int i; + int func_p = (ptr->nwords >= sizeof (struct bb) + && ptr->nwords <= 1000 + && ptr->functions); + int line_p = (func_p && ptr->line_nums); + int file_p = (func_p && ptr->filenames); + int addr_p = (ptr->addresses != 0); + long ncounts = ptr->ncounts; + long cnt_max = 0; + long line_max = 0; + long addr_max = 0; + int file_len = 0; + int func_len = 0; + int blk_len = num_digits (ncounts, 10); + int cnt_len; + int line_len; + int addr_len; + + fprintf (file, "File %s, %ld basic blocks \n\n", + ptr->filename, ncounts); + + /* Get max values for each field. */ + for (i = 0; i < ncounts; i++) + { + const char *p; + int len; + + if (cnt_max < ptr->counts[i]) + cnt_max = ptr->counts[i]; + + if (addr_p && addr_max < ptr->addresses[i]) + addr_max = ptr->addresses[i]; + + if (line_p && line_max < ptr->line_nums[i]) + line_max = ptr->line_nums[i]; + + if (func_p) + { + p = (ptr->functions[i]) ? (ptr->functions[i]) : ""; + len = strlen (p); + if (func_len < len) + func_len = len; + } + + if (file_p) + { + p = (ptr->filenames[i]) ? (ptr->filenames[i]) : ""; + len = strlen (p); + if (file_len < len) + file_len = len; + } + } + + addr_len = num_digits (addr_max, 16); + cnt_len = num_digits (cnt_max, 10); + line_len = num_digits (line_max, 10); + + /* Now print out the basic block information. */ + for (i = 0; i < ncounts; i++) + { + fprintf (file, + " Block #%*d: executed %*ld time(s)", + blk_len, i+1, + cnt_len, ptr->counts[i]); + + if (addr_p) + fprintf (file, " address= 0x%.*lx", addr_len, + ptr->addresses[i]); + + if (func_p) + fprintf (file, " function= %-*s", func_len, + (ptr->functions[i]) ? ptr->functions[i] : ""); + + if (line_p) + fprintf (file, " line= %*ld", line_len, ptr->line_nums[i]); + + if (file_p) + fprintf (file, " file= %s", + (ptr->filenames[i]) ? ptr->filenames[i] : ""); + + fprintf (file, "\n"); + } + + fprintf (file, "\n"); + fflush (file); + } + + fprintf (file, "\n\n"); + fclose (file); + } +} + +void +__bb_init_func (struct bb *blocks) +{ + /* User is supposed to check whether the first word is non-0, + but just in case.... */ + + if (blocks->zero_word) + return; + +#ifdef ON_EXIT + /* Initialize destructor. */ + if (!bb_head) + ON_EXIT (__bb_exit_func, 0); +#endif + + /* Set up linked list. */ + blocks->zero_word = 1; + blocks->next = bb_head; + bb_head = blocks; +} + +#ifndef MACHINE_STATE_SAVE +#define MACHINE_STATE_SAVE(ID) +#endif +#ifndef MACHINE_STATE_RESTORE +#define MACHINE_STATE_RESTORE(ID) +#endif + +/* Number of buckets in hashtable of basic block addresses. */ + +#define BB_BUCKETS 311 + +/* Maximum length of string in file bb.in. */ + +#define BBINBUFSIZE 500 + +/* BBINBUFSIZE-1 with double quotes. We could use #BBINBUFSIZE or + "BBINBUFSIZE" but want to avoid trouble with preprocessors. */ + +#define BBINBUFSIZESTR "499" + +struct bb_edge +{ + struct bb_edge *next; + unsigned long src_addr; + unsigned long dst_addr; + unsigned long count; +}; + +enum bb_func_mode +{ + TRACE_KEEP = 0, TRACE_ON = 1, TRACE_OFF = 2 +}; + +struct bb_func +{ + struct bb_func *next; + char *funcname; + char *filename; + enum bb_func_mode mode; +}; + +/* This is the connection to the outside world. + The BLOCK_PROFILER macro must set __bb.blocks + and __bb.blockno. */ + +struct { + unsigned long blockno; + struct bb *blocks; +} __bb; + +/* Vars to store addrs of source and destination basic blocks + of a jump. */ + +static unsigned long bb_src = 0; +static unsigned long bb_dst = 0; + +static FILE *bb_tracefile = (FILE *) 0; +static struct bb_edge **bb_hashbuckets = (struct bb_edge **) 0; +static struct bb_func *bb_func_head = (struct bb_func *) 0; +static unsigned long bb_callcount = 0; +static int bb_mode = 0; + +static unsigned long *bb_stack = (unsigned long *) 0; +static size_t bb_stacksize = 0; + +static int reported = 0; + +/* Trace modes: +Always : Print execution frequencies of basic blocks + to file bb.out. +bb_mode & 1 != 0 : Dump trace of basic blocks to file bbtrace[.gz] +bb_mode & 2 != 0 : Print jump frequencies to file bb.out. +bb_mode & 4 != 0 : Cut call instructions from basic block flow. +bb_mode & 8 != 0 : Insert return instructions in basic block flow. +*/ + +#ifdef HAVE_POPEN + +/*#include */ +#include +/*#include */ + +/* Commands executed by gopen. */ + +#define GOPENDECOMPRESS "gzip -cd " +#define GOPENCOMPRESS "gzip -c >" + +/* Like fopen but pipes through gzip. mode may only be "r" or "w". + If it does not compile, simply replace gopen by fopen and delete + '.gz' from any first parameter to gopen. */ + +static FILE * +gopen (char *fn, char *mode) +{ + int use_gzip; + char *p; + + if (mode[1]) + return (FILE *) 0; + + if (mode[0] != 'r' && mode[0] != 'w') + return (FILE *) 0; + + p = fn + strlen (fn)-1; + use_gzip = ((p[-1] == '.' && (p[0] == 'Z' || p[0] == 'z')) + || (p[-2] == '.' && p[-1] == 'g' && p[0] == 'z')); + + if (use_gzip) + { + if (mode[0]=='r') + { + FILE *f; + char *s = (char *) malloc (sizeof (char) * strlen (fn) + + sizeof (GOPENDECOMPRESS)); + strcpy (s, GOPENDECOMPRESS); + strcpy (s + (sizeof (GOPENDECOMPRESS)-1), fn); + f = popen (s, mode); + free (s); + return f; + } + + else + { + FILE *f; + char *s = (char *) malloc (sizeof (char) * strlen (fn) + + sizeof (GOPENCOMPRESS)); + strcpy (s, GOPENCOMPRESS); + strcpy (s + (sizeof (GOPENCOMPRESS)-1), fn); + if (!(f = popen (s, mode))) + f = fopen (s, mode); + free (s); + return f; + } + } + + else + return fopen (fn, mode); +} + +static int +gclose (FILE *f) +{ + struct stat buf; + + if (f != 0) + { + if (!fstat (fileno (f), &buf) && S_ISFIFO (buf.st_mode)) + return pclose (f); + + return fclose (f); + } + return 0; +} + +#endif /* HAVE_POPEN */ + +/* Called once per program. */ + +static void +__bb_exit_trace_func () +{ + FILE *file = fopen ("bb.out", "a"); + struct bb_func *f; + struct bb *b; + + if (!file) + perror ("bb.out"); + + if (bb_mode & 1) + { + if (!bb_tracefile) + perror ("bbtrace"); + else +#ifdef HAVE_POPEN + gclose (bb_tracefile); +#else + fclose (bb_tracefile); +#endif /* HAVE_POPEN */ + } + + /* Check functions in `bb.in'. */ + + if (file) + { + long time_value; + const struct bb_func *p; + int printed_something = 0; + struct bb *ptr; + long blk; + + /* This is somewhat type incorrect. */ + time ((void *) &time_value); + + for (p = bb_func_head; p != (struct bb_func *) 0; p = p->next) + { + for (ptr = bb_head; ptr != (struct bb *) 0; ptr = ptr->next) + { + if (!ptr->filename || (p->filename != (char *) 0 && strcmp (p->filename, ptr->filename))) + continue; + for (blk = 0; blk < ptr->ncounts; blk++) + { + if (!strcmp (p->funcname, ptr->functions[blk])) + goto found; + } + } + + if (!printed_something) + { + fprintf (file, "Functions in `bb.in' not executed during basic block profiling on %s\n", ctime ((void *) &time_value)); + printed_something = 1; + } + + fprintf (file, "\tFunction %s", p->funcname); + if (p->filename) + fprintf (file, " of file %s", p->filename); + fprintf (file, "\n" ); + +found: ; + } + + if (printed_something) + fprintf (file, "\n"); + + } + + if (bb_mode & 2) + { + if (!bb_hashbuckets) + { + if (!reported) + { + fprintf (stderr, "Profiler: out of memory\n"); + reported = 1; + } + return; + } + + else if (file) + { + long time_value; + int i; + unsigned long addr_max = 0; + unsigned long cnt_max = 0; + int cnt_len; + int addr_len; + + /* This is somewhat type incorrect, but it avoids worrying about + exactly where time.h is included from. It should be ok unless + a void * differs from other pointer formats, or if sizeof (long) + is < sizeof (time_t). It would be nice if we could assume the + use of rationale standards here. */ + + time ((void *) &time_value); + fprintf (file, "Basic block jump tracing"); + + switch (bb_mode & 12) + { + case 0: + fprintf (file, " (with call)"); + break; + + case 4: + /* Print nothing. */ + break; + + case 8: + fprintf (file, " (with call & ret)"); + break; + + case 12: + fprintf (file, " (with ret)"); + break; + } + + fprintf (file, " finished on %s\n", ctime ((void *) &time_value)); + + for (i = 0; i < BB_BUCKETS; i++) + { + struct bb_edge *bucket = bb_hashbuckets[i]; + for ( ; bucket; bucket = bucket->next ) + { + if (addr_max < bucket->src_addr) + addr_max = bucket->src_addr; + if (addr_max < bucket->dst_addr) + addr_max = bucket->dst_addr; + if (cnt_max < bucket->count) + cnt_max = bucket->count; + } + } + addr_len = num_digits (addr_max, 16); + cnt_len = num_digits (cnt_max, 10); + + for ( i = 0; i < BB_BUCKETS; i++) + { + struct bb_edge *bucket = bb_hashbuckets[i]; + for ( ; bucket; bucket = bucket->next ) + { + fprintf (file, "Jump from block 0x%.*lx to " + "block 0x%.*lx executed %*lu time(s)\n", + addr_len, bucket->src_addr, + addr_len, bucket->dst_addr, + cnt_len, bucket->count); + } + } + + fprintf (file, "\n"); + + } + } + + if (file) + fclose (file); + + /* Free allocated memory. */ + + f = bb_func_head; + while (f) + { + struct bb_func *old = f; + + f = f->next; + if (old->funcname) free (old->funcname); + if (old->filename) free (old->filename); + free (old); + } + + if (bb_stack) + free (bb_stack); + + if (bb_hashbuckets) + { + int i; + + for (i = 0; i < BB_BUCKETS; i++) + { + struct bb_edge *old, *bucket = bb_hashbuckets[i]; + + while (bucket) + { + old = bucket; + bucket = bucket->next; + free (old); + } + } + free (bb_hashbuckets); + } + + for (b = bb_head; b; b = b->next) + if (b->flags) free (b->flags); +} + +/* Called once per program. */ + +static void +__bb_init_prg () +{ + + FILE *file; + char buf[BBINBUFSIZE]; + const char *p; + const char *pos; + enum bb_func_mode m; + +#ifdef ON_EXIT + /* Initialize destructor. */ + ON_EXIT (__bb_exit_func, 0); +#endif + + if (!(file = fopen ("bb.in", "r"))) + return; + + while(fscanf (file, " %" BBINBUFSIZESTR "s ", buf) != EOF) + { + p = buf; + if (*p == '-') + { + m = TRACE_OFF; + p++; + } + else + { + m = TRACE_ON; + } + if (!strcmp (p, "__bb_trace__")) + bb_mode |= 1; + else if (!strcmp (p, "__bb_jumps__")) + bb_mode |= 2; + else if (!strcmp (p, "__bb_hidecall__")) + bb_mode |= 4; + else if (!strcmp (p, "__bb_showret__")) + bb_mode |= 8; + else + { + struct bb_func *f = (struct bb_func *) malloc (sizeof (struct bb_func)); + if (f) + { + unsigned long l; + f->next = bb_func_head; + if ((pos = strchr (p, ':'))) + { + if (!(f->funcname = (char *) malloc (strlen (pos+1)+1))) + continue; + strcpy (f->funcname, pos+1); + l = pos-p; + if ((f->filename = (char *) malloc (l+1))) + { + strncpy (f->filename, p, l); + f->filename[l] = '\0'; + } + else + f->filename = (char *) 0; + } + else + { + if (!(f->funcname = (char *) malloc (strlen (p)+1))) + continue; + strcpy (f->funcname, p); + f->filename = (char *) 0; + } + f->mode = m; + bb_func_head = f; + } + } + } + fclose (file); + +#ifdef HAVE_POPEN + + if (bb_mode & 1) + bb_tracefile = gopen ("bbtrace.gz", "w"); + +#else + + if (bb_mode & 1) + bb_tracefile = fopen ("bbtrace", "w"); + +#endif /* HAVE_POPEN */ + + if (bb_mode & 2) + { + bb_hashbuckets = (struct bb_edge **) + malloc (BB_BUCKETS * sizeof (struct bb_edge *)); + if (bb_hashbuckets) + memset (bb_hashbuckets, 0, BB_BUCKETS * sizeof (struct bb_edge *)); + } + + if (bb_mode & 12) + { + bb_stacksize = 10; + bb_stack = (unsigned long *) malloc (bb_stacksize * sizeof (*bb_stack)); + } + +#ifdef ON_EXIT + /* Initialize destructor. */ + ON_EXIT (__bb_exit_trace_func, 0); +#endif + +} + +/* Called upon entering a basic block. */ + +void +__bb_trace_func () +{ + struct bb_edge *bucket; + + MACHINE_STATE_SAVE("1") + + if (!bb_callcount || (__bb.blocks->flags && (__bb.blocks->flags[__bb.blockno] & TRACE_OFF))) + goto skip; + + bb_dst = __bb.blocks->addresses[__bb.blockno]; + __bb.blocks->counts[__bb.blockno]++; + + if (bb_tracefile) + { + fwrite (&bb_dst, sizeof (unsigned long), 1, bb_tracefile); + } + + if (bb_hashbuckets) + { + struct bb_edge **startbucket, **oldnext; + + oldnext = startbucket + = & bb_hashbuckets[ (((int) bb_src*8) ^ (int) bb_dst) % BB_BUCKETS ]; + bucket = *startbucket; + + for (bucket = *startbucket; bucket; + oldnext = &(bucket->next), bucket = *oldnext) + { + if (bucket->src_addr == bb_src + && bucket->dst_addr == bb_dst) + { + bucket->count++; + *oldnext = bucket->next; + bucket->next = *startbucket; + *startbucket = bucket; + goto ret; + } + } + + bucket = (struct bb_edge *) malloc (sizeof (struct bb_edge)); + + if (!bucket) + { + if (!reported) + { + fprintf (stderr, "Profiler: out of memory\n"); + reported = 1; + } + } + + else + { + bucket->src_addr = bb_src; + bucket->dst_addr = bb_dst; + bucket->next = *startbucket; + *startbucket = bucket; + bucket->count = 1; + } + } + +ret: + bb_src = bb_dst; + +skip: + ; + + MACHINE_STATE_RESTORE("1") + +} + +/* Called when returning from a function and `__bb_showret__' is set. */ + +static void +__bb_trace_func_ret () +{ + struct bb_edge *bucket; + + if (!bb_callcount || (__bb.blocks->flags && (__bb.blocks->flags[__bb.blockno] & TRACE_OFF))) + goto skip; + + if (bb_hashbuckets) + { + struct bb_edge **startbucket, **oldnext; + + oldnext = startbucket + = & bb_hashbuckets[ (((int) bb_dst * 8) ^ (int) bb_src) % BB_BUCKETS ]; + bucket = *startbucket; + + for (bucket = *startbucket; bucket; + oldnext = &(bucket->next), bucket = *oldnext) + { + if (bucket->src_addr == bb_dst + && bucket->dst_addr == bb_src) + { + bucket->count++; + *oldnext = bucket->next; + bucket->next = *startbucket; + *startbucket = bucket; + goto ret; + } + } + + bucket = (struct bb_edge *) malloc (sizeof (struct bb_edge)); + + if (!bucket) + { + if (!reported) + { + fprintf (stderr, "Profiler: out of memory\n"); + reported = 1; + } + } + + else + { + bucket->src_addr = bb_dst; + bucket->dst_addr = bb_src; + bucket->next = *startbucket; + *startbucket = bucket; + bucket->count = 1; + } + } + +ret: + bb_dst = bb_src; + +skip: + ; + +} + +/* Called upon entering the first function of a file. */ + +static void +__bb_init_file (struct bb *blocks) +{ + + const struct bb_func *p; + long blk, ncounts = blocks->ncounts; + const char **functions = blocks->functions; + + /* Set up linked list. */ + blocks->zero_word = 1; + blocks->next = bb_head; + bb_head = blocks; + + blocks->flags = 0; + if (!bb_func_head + || !(blocks->flags = (char *) malloc (sizeof (char) * blocks->ncounts))) + return; + + for (blk = 0; blk < ncounts; blk++) + blocks->flags[blk] = 0; + + for (blk = 0; blk < ncounts; blk++) + { + for (p = bb_func_head; p; p = p->next) + { + if (!strcmp (p->funcname, functions[blk]) + && (!p->filename || !strcmp (p->filename, blocks->filename))) + { + blocks->flags[blk] |= p->mode; + } + } + } + +} + +/* Called when exiting from a function. */ + +void +__bb_trace_ret () +{ + + MACHINE_STATE_SAVE("2") + + if (bb_callcount) + { + if ((bb_mode & 12) && bb_stacksize > bb_callcount) + { + bb_src = bb_stack[bb_callcount]; + if (bb_mode & 8) + __bb_trace_func_ret (); + } + + bb_callcount -= 1; + } + + MACHINE_STATE_RESTORE("2") + +} + +/* Called when entering a function. */ + +void +__bb_init_trace_func (struct bb *blocks, unsigned long blockno) +{ + static int trace_init = 0; + + MACHINE_STATE_SAVE("3") + + if (!blocks->zero_word) + { + if (!trace_init) + { + trace_init = 1; + __bb_init_prg (); + } + __bb_init_file (blocks); + } + + if (bb_callcount) + { + + bb_callcount += 1; + + if (bb_mode & 12) + { + if (bb_callcount >= bb_stacksize) + { + size_t newsize = bb_callcount + 100; + + bb_stack = (unsigned long *) realloc (bb_stack, newsize); + if (! bb_stack) + { + if (!reported) + { + fprintf (stderr, "Profiler: out of memory\n"); + reported = 1; + } + bb_stacksize = 0; + goto stack_overflow; + } + bb_stacksize = newsize; + } + bb_stack[bb_callcount] = bb_src; + + if (bb_mode & 4) + bb_src = 0; + + } + +stack_overflow:; + + } + + else if (blocks->flags && (blocks->flags[blockno] & TRACE_ON)) + { + bb_callcount = 1; + bb_src = 0; + + if (bb_stack) + bb_stack[bb_callcount] = bb_src; + } + + MACHINE_STATE_RESTORE("3") +} + +#endif /* not inhibit_libc */ +#endif /* not BLOCK_PROFILER_CODE */ +#endif /* L_bb */ + +#ifdef L_shtab +unsigned int __shtab[] = { + 0x00000001, 0x00000002, 0x00000004, 0x00000008, + 0x00000010, 0x00000020, 0x00000040, 0x00000080, + 0x00000100, 0x00000200, 0x00000400, 0x00000800, + 0x00001000, 0x00002000, 0x00004000, 0x00008000, + 0x00010000, 0x00020000, 0x00040000, 0x00080000, + 0x00100000, 0x00200000, 0x00400000, 0x00800000, + 0x01000000, 0x02000000, 0x04000000, 0x08000000, + 0x10000000, 0x20000000, 0x40000000, 0x80000000 + }; +#endif + +#ifdef L_clear_cache +/* Clear part of an instruction cache. */ + +#define INSN_CACHE_PLANE_SIZE (INSN_CACHE_SIZE / INSN_CACHE_DEPTH) + +void +__clear_cache (char *beg, char *end) +{ +#ifdef CLEAR_INSN_CACHE + CLEAR_INSN_CACHE (beg, end); +#else +#ifdef INSN_CACHE_SIZE + static char array[INSN_CACHE_SIZE + INSN_CACHE_PLANE_SIZE + INSN_CACHE_LINE_WIDTH]; + static int initialized; + int offset; + void *start_addr + void *end_addr; + typedef (*function_ptr) (); + +#if (INSN_CACHE_SIZE / INSN_CACHE_LINE_WIDTH) < 16 + /* It's cheaper to clear the whole cache. + Put in a series of jump instructions so that calling the beginning + of the cache will clear the whole thing. */ + + if (! initialized) + { + int ptr = (((int) array + INSN_CACHE_LINE_WIDTH - 1) + & -INSN_CACHE_LINE_WIDTH); + int end_ptr = ptr + INSN_CACHE_SIZE; + + while (ptr < end_ptr) + { + *(INSTRUCTION_TYPE *)ptr + = JUMP_AHEAD_INSTRUCTION + INSN_CACHE_LINE_WIDTH; + ptr += INSN_CACHE_LINE_WIDTH; + } + *(INSTRUCTION_TYPE *) (ptr - INSN_CACHE_LINE_WIDTH) = RETURN_INSTRUCTION; + + initialized = 1; + } + + /* Call the beginning of the sequence. */ + (((function_ptr) (((int) array + INSN_CACHE_LINE_WIDTH - 1) + & -INSN_CACHE_LINE_WIDTH)) + ()); + +#else /* Cache is large. */ + + if (! initialized) + { + int ptr = (((int) array + INSN_CACHE_LINE_WIDTH - 1) + & -INSN_CACHE_LINE_WIDTH); + + while (ptr < (int) array + sizeof array) + { + *(INSTRUCTION_TYPE *)ptr = RETURN_INSTRUCTION; + ptr += INSN_CACHE_LINE_WIDTH; + } + + initialized = 1; + } + + /* Find the location in array that occupies the same cache line as BEG. */ + + offset = ((int) beg & -INSN_CACHE_LINE_WIDTH) & (INSN_CACHE_PLANE_SIZE - 1); + start_addr = (((int) (array + INSN_CACHE_PLANE_SIZE - 1) + & -INSN_CACHE_PLANE_SIZE) + + offset); + + /* Compute the cache alignment of the place to stop clearing. */ +#if 0 /* This is not needed for gcc's purposes. */ + /* If the block to clear is bigger than a cache plane, + we clear the entire cache, and OFFSET is already correct. */ + if (end < beg + INSN_CACHE_PLANE_SIZE) +#endif + offset = (((int) (end + INSN_CACHE_LINE_WIDTH - 1) + & -INSN_CACHE_LINE_WIDTH) + & (INSN_CACHE_PLANE_SIZE - 1)); + +#if INSN_CACHE_DEPTH > 1 + end_addr = (start_addr & -INSN_CACHE_PLANE_SIZE) + offset; + if (end_addr <= start_addr) + end_addr += INSN_CACHE_PLANE_SIZE; + + for (plane = 0; plane < INSN_CACHE_DEPTH; plane++) + { + int addr = start_addr + plane * INSN_CACHE_PLANE_SIZE; + int stop = end_addr + plane * INSN_CACHE_PLANE_SIZE; + + while (addr != stop) + { + /* Call the return instruction at ADDR. */ + ((function_ptr) addr) (); + + addr += INSN_CACHE_LINE_WIDTH; + } + } +#else /* just one plane */ + do + { + /* Call the return instruction at START_ADDR. */ + ((function_ptr) start_addr) (); + + start_addr += INSN_CACHE_LINE_WIDTH; + } + while ((start_addr % INSN_CACHE_SIZE) != offset); +#endif /* just one plane */ +#endif /* Cache is large */ +#endif /* Cache exists */ +#endif /* CLEAR_INSN_CACHE */ +} + +#endif /* L_clear_cache */ + +#ifdef L_trampoline + +/* Jump to a trampoline, loading the static chain address. */ + +#if defined(WINNT) && ! defined(__CYGWIN__) && ! defined (_UWIN) + +long getpagesize() +{ +#ifdef _ALPHA_ + return 8192; +#else + return 4096; +#endif +} + +#ifdef i386 +extern int VirtualProtect (char *, int, int, int *) __attribute__((stdcall)); +#endif + +int +mprotect (char *addr, int len, int prot) +{ + int np, op; + + if (prot == 7) + np = 0x40; + else if (prot == 5) + np = 0x20; + else if (prot == 4) + np = 0x10; + else if (prot == 3) + np = 0x04; + else if (prot == 1) + np = 0x02; + else if (prot == 0) + np = 0x01; + + if (VirtualProtect (addr, len, np, &op)) + return 0; + else + return -1; +} + +#endif /* WINNT && ! __CYGWIN__ && ! _UWIN */ + +#ifdef TRANSFER_FROM_TRAMPOLINE +TRANSFER_FROM_TRAMPOLINE +#endif + +#if defined (NeXT) && defined (__MACH__) + +/* Make stack executable so we can call trampolines on stack. + This is called from INITIALIZE_TRAMPOLINE in next.h. */ +#ifdef NeXTStep21 + #include +#else + #include +#endif + +void +__enable_execute_stack (char *addr) +{ + kern_return_t r; + char *eaddr = addr + TRAMPOLINE_SIZE; + vm_address_t a = (vm_address_t) addr; + + /* turn on execute access on stack */ + r = vm_protect (task_self (), a, TRAMPOLINE_SIZE, FALSE, VM_PROT_ALL); + if (r != KERN_SUCCESS) + { + mach_error("vm_protect VM_PROT_ALL", r); + exit(1); + } + + /* We inline the i-cache invalidation for speed */ + +#ifdef CLEAR_INSN_CACHE + CLEAR_INSN_CACHE (addr, eaddr); +#else + __clear_cache ((int) addr, (int) eaddr); +#endif +} + +#endif /* defined (NeXT) && defined (__MACH__) */ + +#ifdef __convex__ + +/* Make stack executable so we can call trampolines on stack. + This is called from INITIALIZE_TRAMPOLINE in convex.h. */ + +#include +#include +#include + +void +__enable_execute_stack () +{ + int fp; + static unsigned lowest = USRSTACK; + unsigned current = (unsigned) &fp & -NBPG; + + if (lowest > current) + { + unsigned len = lowest - current; + mremap (current, &len, PROT_READ | PROT_WRITE | PROT_EXEC, MAP_PRIVATE); + lowest = current; + } + + /* Clear instruction cache in case an old trampoline is in it. */ + asm ("pich"); +} +#endif /* __convex__ */ + +#ifdef __sysV88__ + +/* Modified from the convex -code above. */ + +#include +#include +#include + +void +__enable_execute_stack () +{ + int save_errno; + static unsigned long lowest = USRSTACK; + unsigned long current = (unsigned long) &save_errno & -NBPC; + + /* Ignore errno being set. memctl sets errno to EINVAL whenever the + address is seen as 'negative'. That is the case with the stack. */ + + save_errno=errno; + if (lowest > current) + { + unsigned len=lowest-current; + memctl(current,len,MCT_TEXT); + lowest = current; + } + else + memctl(current,NBPC,MCT_TEXT); + errno=save_errno; +} + +#endif /* __sysV88__ */ + +#ifdef __sysV68__ + +#include +#include + +/* Motorola forgot to put memctl.o in the libp version of libc881.a, + so define it here, because we need it in __clear_insn_cache below */ +/* On older versions of this OS, no memctl or MCT_TEXT are defined; + hence we enable this stuff only if MCT_TEXT is #define'd. */ + +#ifdef MCT_TEXT +asm("\n\ + global memctl\n\ +memctl:\n\ + movq &75,%d0\n\ + trap &0\n\ + bcc.b noerror\n\ + jmp cerror%\n\ +noerror:\n\ + movq &0,%d0\n\ + rts"); +#endif + +/* Clear instruction cache so we can call trampolines on stack. + This is called from FINALIZE_TRAMPOLINE in mot3300.h. */ + +void +__clear_insn_cache () +{ +#ifdef MCT_TEXT + int save_errno; + + /* Preserve errno, because users would be surprised to have + errno changing without explicitly calling any system-call. */ + save_errno = errno; + + /* Keep it simple : memctl (MCT_TEXT) always fully clears the insn cache. + No need to use an address derived from _start or %sp, as 0 works also. */ + memctl(0, 4096, MCT_TEXT); + errno = save_errno; +#endif +} + +#endif /* __sysV68__ */ + +#ifdef __pyr__ + +#undef NULL /* Avoid errors if stdio.h and our stddef.h mismatch. */ +#include +#include +#include +#include +#include + +/* Modified from the convex -code above. + mremap promises to clear the i-cache. */ + +void +__enable_execute_stack () +{ + int fp; + if (mprotect (((unsigned int)&fp/PAGSIZ)*PAGSIZ, PAGSIZ, + PROT_READ|PROT_WRITE|PROT_EXEC)) + { + perror ("mprotect in __enable_execute_stack"); + fflush (stderr); + abort (); + } +} +#endif /* __pyr__ */ + +#if defined (sony_news) && defined (SYSTYPE_BSD) + +#include +#include +#include +#include +#include + +/* cacheflush function for NEWS-OS 4.2. + This function is called from trampoline-initialize code + defined in config/mips/mips.h. */ + +void +cacheflush (char *beg, int size, int flag) +{ + if (syscall (SYS_sysnews, NEWS_CACHEFLUSH, beg, size, FLUSH_BCACHE)) + { + perror ("cache_flush"); + fflush (stderr); + abort (); + } +} + +#endif /* sony_news */ +#endif /* L_trampoline */ + +#ifndef __CYGWIN__ +#ifdef L__main + +#include "gbl-ctors.h" +/* Some systems use __main in a way incompatible with its use in gcc, in these + cases use the macros NAME__MAIN to give a quoted symbol and SYMBOL__MAIN to + give the same symbol without quotes for an alternative entry point. You + must define both, or neither. */ +#ifndef NAME__MAIN +#define NAME__MAIN "__main" +#define SYMBOL__MAIN __main +#endif + +#ifdef INIT_SECTION_ASM_OP +#undef HAS_INIT_SECTION +#define HAS_INIT_SECTION +#endif + +#if !defined (HAS_INIT_SECTION) || !defined (OBJECT_FORMAT_ELF) +/* Run all the global destructors on exit from the program. */ + +void +__do_global_dtors () +{ +#ifdef DO_GLOBAL_DTORS_BODY + DO_GLOBAL_DTORS_BODY; +#else + static func_ptr *p = __DTOR_LIST__ + 1; + while (*p) + { + p++; + (*(p-1)) (); + } +#endif +} +#endif + +#ifndef HAS_INIT_SECTION +/* Run all the global constructors on entry to the program. */ + +#ifndef ON_EXIT +#define ON_EXIT(a, b) +#else +/* Make sure the exit routine is pulled in to define the globals as + bss symbols, just in case the linker does not automatically pull + bss definitions from the library. */ + +extern int _exit_dummy_decl; +int *_exit_dummy_ref = &_exit_dummy_decl; +#endif /* ON_EXIT */ + +void +__do_global_ctors () +{ + DO_GLOBAL_CTORS_BODY; + ON_EXIT (__do_global_dtors, 0); +} +#endif /* no HAS_INIT_SECTION */ + +#if !defined (HAS_INIT_SECTION) || defined (INVOKE__main) +/* Subroutine called automatically by `main'. + Compiling a global function named `main' + produces an automatic call to this function at the beginning. + + For many systems, this routine calls __do_global_ctors. + For systems which support a .init section we use the .init section + to run __do_global_ctors, so we need not do anything here. */ + +void +SYMBOL__MAIN () +{ + /* Support recursive calls to `main': run initializers just once. */ + static int initialized; + if (! initialized) + { + initialized = 1; + __do_global_ctors (); + } +} +#endif /* no HAS_INIT_SECTION or INVOKE__main */ + +#endif /* L__main */ +#endif /* __CYGWIN__ */ + +#ifdef L_ctors + +#include "gbl-ctors.h" + +/* Provide default definitions for the lists of constructors and + destructors, so that we don't get linker errors. These symbols are + intentionally bss symbols, so that gld and/or collect will provide + the right values. */ + +/* We declare the lists here with two elements each, + so that they are valid empty lists if no other definition is loaded. + + If we are using the old "set" extensions to have the gnu linker + collect ctors and dtors, then we __CTOR_LIST__ and __DTOR_LIST__ + must be in the bss/common section. + + Long term no port should use those extensions. But many still do. */ +#if !defined(INIT_SECTION_ASM_OP) && !defined(CTOR_LISTS_DEFINED_EXTERNALLY) +#if defined (ASM_OUTPUT_CONSTRUCTOR) || defined (USE_COLLECT2) +func_ptr __CTOR_LIST__[2] = {0, 0}; +func_ptr __DTOR_LIST__[2] = {0, 0}; +#else +func_ptr __CTOR_LIST__[2]; +func_ptr __DTOR_LIST__[2]; +#endif +#endif /* no INIT_SECTION_ASM_OP and not CTOR_LISTS_DEFINED_EXTERNALLY */ +#endif /* L_ctors */ + +#ifdef L_exit + +#include "gbl-ctors.h" + +#ifdef NEED_ATEXIT +# ifdef ON_EXIT +# undef ON_EXIT +# endif +int _exit_dummy_decl = 0; /* prevent compiler & linker warnings */ +#endif + +#ifndef ON_EXIT + +#ifdef NEED_ATEXIT +# include + +static func_ptr *atexit_chain = 0; +static long atexit_chain_length = 0; +static volatile long last_atexit_chain_slot = -1; + +int atexit (func_ptr func) +{ + if (++last_atexit_chain_slot == atexit_chain_length) + { + atexit_chain_length += 32; + if (atexit_chain) + atexit_chain = (func_ptr *) realloc (atexit_chain, atexit_chain_length + * sizeof (func_ptr)); + else + atexit_chain = (func_ptr *) malloc (atexit_chain_length + * sizeof (func_ptr)); + if (! atexit_chain) + { + atexit_chain_length = 0; + last_atexit_chain_slot = -1; + errno = ENOMEM; + return (-1); + } + } + atexit_chain[last_atexit_chain_slot] = func; + return (0); +} +#endif /* NEED_ATEXIT */ + +/* If we have no known way of registering our own __do_global_dtors + routine so that it will be invoked at program exit time, then we + have to define our own exit routine which will get this to happen. */ + +extern void __do_global_dtors (); +extern void __bb_exit_func (); +extern void _cleanup (); +extern void _exit () __attribute__ ((noreturn)); + +void +exit (int status) +{ +#if !defined (INIT_SECTION_ASM_OP) || !defined (OBJECT_FORMAT_ELF) +#ifdef NEED_ATEXIT + if (atexit_chain) + { + for ( ; last_atexit_chain_slot-- >= 0; ) + { + (*atexit_chain[last_atexit_chain_slot + 1]) (); + atexit_chain[last_atexit_chain_slot + 1] = 0; + } + free (atexit_chain); + atexit_chain = 0; + } +#else /* No NEED_ATEXIT */ + __do_global_dtors (); +#endif /* No NEED_ATEXIT */ +#endif /* !defined (INIT_SECTION_ASM_OP) || !defined (OBJECT_FORMAT_ELF) */ +/* In gbl-ctors.h, ON_EXIT is defined if HAVE_ATEXIT is defined. In + __bb_init_func and _bb_init_prg, __bb_exit_func is registered with + ON_EXIT if ON_EXIT is defined. Thus we must not call __bb_exit_func here + if HAVE_ATEXIT is defined. */ +#ifndef HAVE_ATEXIT +#ifndef inhibit_libc + __bb_exit_func (); +#endif +#endif /* !HAVE_ATEXIT */ +#ifdef EXIT_BODY + EXIT_BODY; +#else + _cleanup (); +#endif + _exit (status); +} + +#else /* ON_EXIT defined */ +int _exit_dummy_decl = 0; /* prevent compiler & linker warnings */ + +# ifndef HAVE_ATEXIT +/* Provide a fake for atexit() using ON_EXIT. */ +int atexit (func_ptr func) +{ + return ON_EXIT (func, NULL); +} +# endif /* HAVE_ATEXIT */ +#endif /* ON_EXIT defined */ + +#endif /* L_exit */ + +#ifdef L_eh + +#include "gthr.h" + +/* Shared exception handling support routines. */ + +extern void __default_terminate (void) __attribute__ ((__noreturn__)); + +void +__default_terminate () +{ + abort (); +} + +void (*__terminate_func)() = __default_terminate; + +void +__terminate () +{ + (*__terminate_func)(); +} + +void * +__throw_type_match (void *catch_type, void *throw_type, void *obj) +{ +#if 0 + printf ("__throw_type_match (): catch_type = %s, throw_type = %s\n", + catch_type, throw_type); +#endif + if (strcmp ((const char *)catch_type, (const char *)throw_type) == 0) + return obj; + return 0; +} + +void +__empty () +{ +} + + +/* Include definitions of EH context and table layout */ + +#include "eh-common.h" +#ifndef inhibit_libc +#include +#endif + +/* Allocate and return a new EH context structure. */ + +extern void __throw (); + +static void * +new_eh_context () +{ + struct eh_full_context { + struct eh_context c; + void *top_elt[2]; + } *ehfc = (struct eh_full_context *) malloc (sizeof *ehfc); + + if (! ehfc) + __terminate (); + + memset (ehfc, 0, sizeof *ehfc); + + ehfc->c.dynamic_handler_chain = (void **) ehfc->top_elt; + + /* This should optimize out entirely. This should always be true, + but just in case it ever isn't, don't allow bogus code to be + generated. */ + + if ((void*)(&ehfc->c) != (void*)ehfc) + __terminate (); + + return &ehfc->c; +} + +#if __GTHREADS +static __gthread_key_t eh_context_key; + +/* Destructor for struct eh_context. */ +static void +eh_context_free (void *ptr) +{ + __gthread_key_dtor (eh_context_key, ptr); + if (ptr) + free (ptr); +} +#endif + +/* Pointer to function to return EH context. */ + +static struct eh_context *eh_context_initialize (); +static struct eh_context *eh_context_static (); +#if __GTHREADS +static struct eh_context *eh_context_specific (); +#endif + +static struct eh_context *(*get_eh_context) () = &eh_context_initialize; + +/* Routine to get EH context. + This one will simply call the function pointer. */ + +void * +__get_eh_context () +{ + return (void *) (*get_eh_context) (); +} + +/* Get and set the language specific info pointer. */ + +void ** +__get_eh_info () +{ + struct eh_context *eh = (*get_eh_context) (); + return &eh->info; +} + +#if __GTHREADS +static void +eh_threads_initialize () +{ + /* Try to create the key. If it fails, revert to static method, + otherwise start using thread specific EH contexts. */ + if (__gthread_key_create (&eh_context_key, &eh_context_free) == 0) + get_eh_context = &eh_context_specific; + else + get_eh_context = &eh_context_static; +} +#endif /* no __GTHREADS */ + +/* Initialize EH context. + This will be called only once, since we change GET_EH_CONTEXT + pointer to another routine. */ + +static struct eh_context * +eh_context_initialize () +{ +#if __GTHREADS + + static __gthread_once_t once = __GTHREAD_ONCE_INIT; + /* Make sure that get_eh_context does not point to us anymore. + Some systems have dummy thread routines in their libc that + return a success (Solaris 2.6 for example). */ + if (__gthread_once (&once, eh_threads_initialize) != 0 + || get_eh_context == &eh_context_initialize) + { + /* Use static version of EH context. */ + get_eh_context = &eh_context_static; + } + +#else /* no __GTHREADS */ + + /* Use static version of EH context. */ + get_eh_context = &eh_context_static; + +#endif /* no __GTHREADS */ + + return (*get_eh_context) (); +} + +/* Return a static EH context. */ + +static struct eh_context * +eh_context_static () +{ + static struct eh_context eh; + static int initialized; + static void *top_elt[2]; + + if (! initialized) + { + initialized = 1; + memset (&eh, 0, sizeof eh); + eh.dynamic_handler_chain = top_elt; + } + return &eh; +} + +#if __GTHREADS +/* Return a thread specific EH context. */ + +static struct eh_context * +eh_context_specific () +{ + struct eh_context *eh; + eh = (struct eh_context *) __gthread_getspecific (eh_context_key); + if (! eh) + { + eh = new_eh_context (); + if (__gthread_setspecific (eh_context_key, (void *) eh) != 0) + __terminate (); + } + + return eh; +} +#endif __GTHREADS + +/* Support routines for setjmp/longjmp exception handling. */ + +/* Calls to __sjthrow are generated by the compiler when an exception + is raised when using the setjmp/longjmp exception handling codegen + method. */ + +#ifdef DONT_USE_BUILTIN_SETJMP +extern void longjmp (void *, int); +#endif + +/* Routine to get the head of the current thread's dynamic handler chain + use for exception handling. */ + +void *** +__get_dynamic_handler_chain () +{ + struct eh_context *eh = (*get_eh_context) (); + return &eh->dynamic_handler_chain; +} + +/* This is used to throw an exception when the setjmp/longjmp codegen + method is used for exception handling. + + We call __terminate if there are no handlers left. Otherwise we run the + cleanup actions off the dynamic cleanup stack, and pop the top of the + dynamic handler chain, and use longjmp to transfer back to the associated + handler. */ + +extern void __sjthrow (void) __attribute__ ((__noreturn__)); + +void +__sjthrow () +{ + struct eh_context *eh = (*get_eh_context) (); + void ***dhc = &eh->dynamic_handler_chain; + void *jmpbuf; + void (*func)(void *, int); + void *arg; + void ***cleanup; + + /* The cleanup chain is one word into the buffer. Get the cleanup + chain. */ + cleanup = (void***)&(*dhc)[1]; + + /* If there are any cleanups in the chain, run them now. */ + if (cleanup[0]) + { + double store[200]; + void **buf = (void**)store; + buf[1] = 0; + buf[0] = (*dhc); + + /* try { */ +#ifdef DONT_USE_BUILTIN_SETJMP + if (! setjmp (&buf[2])) +#else + if (! __builtin_setjmp (&buf[2])) +#endif + { + *dhc = buf; + while (cleanup[0]) + { + func = (void(*)(void*, int))cleanup[0][1]; + arg = (void*)cleanup[0][2]; + + /* Update this before running the cleanup. */ + cleanup[0] = (void **)cleanup[0][0]; + + (*func)(arg, 2); + } + *dhc = buf[0]; + } + /* catch (...) */ + else + { + __terminate (); + } + } + + /* We must call terminate if we try and rethrow an exception, when + there is no exception currently active and when there are no + handlers left. */ + if (! eh->info || (*dhc)[0] == 0) + __terminate (); + + /* Find the jmpbuf associated with the top element of the dynamic + handler chain. The jumpbuf starts two words into the buffer. */ + jmpbuf = &(*dhc)[2]; + + /* Then we pop the top element off the dynamic handler chain. */ + *dhc = (void**)(*dhc)[0]; + + /* And then we jump to the handler. */ + +#ifdef DONT_USE_BUILTIN_SETJMP + longjmp (jmpbuf, 1); +#else + __builtin_longjmp (jmpbuf, 1); +#endif +} + +/* Run cleanups on the dynamic cleanup stack for the current dynamic + handler, then pop the handler off the dynamic handler stack, and + then throw. This is used to skip the first handler, and transfer + control to the next handler in the dynamic handler stack. */ + +extern void __sjpopnthrow (void) __attribute__ ((__noreturn__)); + +void +__sjpopnthrow () +{ + struct eh_context *eh = (*get_eh_context) (); + void ***dhc = &eh->dynamic_handler_chain; + void (*func)(void *, int); + void *arg; + void ***cleanup; + + /* The cleanup chain is one word into the buffer. Get the cleanup + chain. */ + cleanup = (void***)&(*dhc)[1]; + + /* If there are any cleanups in the chain, run them now. */ + if (cleanup[0]) + { + double store[200]; + void **buf = (void**)store; + buf[1] = 0; + buf[0] = (*dhc); + + /* try { */ +#ifdef DONT_USE_BUILTIN_SETJMP + if (! setjmp (&buf[2])) +#else + if (! __builtin_setjmp (&buf[2])) +#endif + { + *dhc = buf; + while (cleanup[0]) + { + func = (void(*)(void*, int))cleanup[0][1]; + arg = (void*)cleanup[0][2]; + + /* Update this before running the cleanup. */ + cleanup[0] = (void **)cleanup[0][0]; + + (*func)(arg, 2); + } + *dhc = buf[0]; + } + /* catch (...) */ + else + { + __terminate (); + } + } + + /* Then we pop the top element off the dynamic handler chain. */ + *dhc = (void**)(*dhc)[0]; + + __sjthrow (); +} + +/* Support code for all exception region-based exception handling. */ + +int +__eh_rtime_match (void *rtime) +{ + void *info; + __eh_matcher matcher; + void *ret; + + info = *(__get_eh_info ()); + matcher = ((__eh_info *)info)->match_function; + if (! matcher) + { +#ifndef inhibit_libc + fprintf (stderr, "Internal Compiler Bug: No runtime type matcher."); +#endif + return 0; + } + ret = (*matcher) (info, rtime, (void *)0); + return (ret != NULL); +} + +/* This value identifies the place from which an exception is being + thrown. */ + +#ifdef EH_TABLE_LOOKUP + +EH_TABLE_LOOKUP + +#else + +#ifdef DWARF2_UNWIND_INFO + + +/* Return the table version of an exception descriptor */ + +short +__get_eh_table_version (exception_descriptor *table) +{ + return table->lang.version; +} + +/* Return the originating table language of an exception descriptor */ + +short +__get_eh_table_language (exception_descriptor *table) +{ + return table->lang.language; +} + +/* This routine takes a PC and a pointer to the exception region TABLE for + its translation unit, and returns the address of the exception handler + associated with the closest exception table handler entry associated + with that PC, or 0 if there are no table entries the PC fits in. + + In the advent of a tie, we have to give the last entry, as it represents + an inner block. */ + +static void * +old_find_exception_handler (void *pc, old_exception_table *table) +{ + if (table) + { + int pos; + int best = -1; + + /* We can't do a binary search because the table isn't guaranteed + to be sorted from function to function. */ + for (pos = 0; table[pos].start_region != (void *) -1; ++pos) + { + if (table[pos].start_region <= pc && table[pos].end_region > pc) + { + /* This can apply. Make sure it is at least as small as + the previous best. */ + if (best == -1 || (table[pos].end_region <= table[best].end_region + && table[pos].start_region >= table[best].start_region)) + best = pos; + } + /* But it is sorted by starting PC within a function. */ + else if (best >= 0 && table[pos].start_region > pc) + break; + } + if (best != -1) + return table[best].exception_handler; + } + + return (void *) 0; +} + +/* find_exception_handler finds the correct handler, if there is one, to + handle an exception. + returns a pointer to the handler which controlled should be transferred + to, or NULL if there is nothing left. + Parameters: + PC - pc where the exception originates. If this is a rethrow, + then this starts out as a pointer to the exception table + entry we wish to rethrow out of. + TABLE - exception table for the current module. + EH_INFO - eh info pointer for this exception. + RETHROW - 1 if this is a rethrow. (see incoming value of PC). + CLEANUP - returned flag indicating whether this is a cleanup handler. +*/ +static void * +find_exception_handler (void *pc, exception_descriptor *table, + __eh_info *eh_info, int rethrow, int *cleanup) +{ + + void *retval = NULL; + *cleanup = 1; + if (table) + { + int pos = 0; + /* The new model assumed the table is sorted inner-most out so the + first region we find which matches is the correct one */ + + exception_table *tab = &(table->table[0]); + + /* Subtract 1 from the PC to avoid hitting the next region */ + if (rethrow) + { + /* pc is actually the region table entry to rethrow out of */ + pos = ((exception_table *) pc) - tab; + pc = ((exception_table *) pc)->end_region - 1; + + /* The label is always on the LAST handler entry for a region, + so we know the next entry is a different region, even if the + addresses are the same. Make sure its not end of table tho. */ + if (tab[pos].start_region != (void *) -1) + pos++; + } + else + pc--; + + /* We can't do a binary search because the table is in inner-most + to outermost address ranges within functions */ + for ( ; tab[pos].start_region != (void *) -1; pos++) + { + if (tab[pos].start_region <= pc && tab[pos].end_region > pc) + { + if (tab[pos].match_info) + { + __eh_matcher matcher = eh_info->match_function; + /* match info but no matcher is NOT a match */ + if (matcher) + { + void *ret = (*matcher)((void *) eh_info, + tab[pos].match_info, table); + if (ret) + { + if (retval == NULL) + retval = tab[pos].exception_handler; + *cleanup = 0; + break; + } + } + } + else + { + if (retval == NULL) + retval = tab[pos].exception_handler; + } + } + } + } + return retval; +} +#endif /* DWARF2_UNWIND_INFO */ +#endif /* EH_TABLE_LOOKUP */ + +#ifdef DWARF2_UNWIND_INFO +/* Support code for exception handling using static unwind information. */ + +#include "frame.h" + +/* This type is used in get_reg and put_reg to deal with ABIs where a void* + is smaller than a word, such as the Irix 6 n32 ABI. We cast twice to + avoid a warning about casting between int and pointer of different + sizes. */ + +typedef int ptr_type __attribute__ ((mode (pointer))); + +#ifdef INCOMING_REGNO +/* Is the saved value for register REG in frame UDATA stored in a register + window in the previous frame? */ + +/* ??? The Sparc INCOMING_REGNO references TARGET_FLAT. This allows us + to use the macro here. One wonders, though, that perhaps TARGET_FLAT + compiled functions won't work with the frame-unwind stuff here. + Perhaps the entireity of in_reg_window should be conditional on having + seen a DW_CFA_GNU_window_save? */ +#define target_flags 0 + +static int +in_reg_window (int reg, frame_state *udata) +{ + if (udata->saved[reg] == REG_SAVED_REG) + return INCOMING_REGNO (reg) == reg; + if (udata->saved[reg] != REG_SAVED_OFFSET) + return 0; + +#ifdef STACK_GROWS_DOWNWARD + return udata->reg_or_offset[reg] > 0; +#else + return udata->reg_or_offset[reg] < 0; +#endif +} +#else +static inline int in_reg_window (int reg, frame_state *udata) { return 0; } +#endif /* INCOMING_REGNO */ + +/* Get the address of register REG as saved in UDATA, where SUB_UDATA is a + frame called by UDATA or 0. */ + +static word_type * +get_reg_addr (unsigned reg, frame_state *udata, frame_state *sub_udata) +{ + while (udata->saved[reg] == REG_SAVED_REG) + { + reg = udata->reg_or_offset[reg]; + if (in_reg_window (reg, udata)) + { + udata = sub_udata; + sub_udata = NULL; + } + } + if (udata->saved[reg] == REG_SAVED_OFFSET) + return (word_type *)(udata->cfa + udata->reg_or_offset[reg]); + else + abort (); +} + +/* Get the value of register REG as saved in UDATA, where SUB_UDATA is a + frame called by UDATA or 0. */ + +static inline void * +get_reg (unsigned reg, frame_state *udata, frame_state *sub_udata) +{ + return (void *)(ptr_type) *get_reg_addr (reg, udata, sub_udata); +} + +/* Overwrite the saved value for register REG in frame UDATA with VAL. */ + +static inline void +put_reg (unsigned reg, void *val, frame_state *udata) +{ + *get_reg_addr (reg, udata, NULL) = (word_type)(ptr_type) val; +} + +/* Copy the saved value for register REG from frame UDATA to frame + TARGET_UDATA. Unlike the previous two functions, this can handle + registers that are not one word large. */ + +static void +copy_reg (unsigned reg, frame_state *udata, frame_state *target_udata) +{ + word_type *preg = get_reg_addr (reg, udata, NULL); + word_type *ptreg = get_reg_addr (reg, target_udata, NULL); + + memcpy (ptreg, preg, __builtin_dwarf_reg_size (reg)); +} + +/* Retrieve the return address for frame UDATA. */ + +static inline void * +get_return_addr (frame_state *udata, frame_state *sub_udata) +{ + return __builtin_extract_return_addr + (get_reg (udata->retaddr_column, udata, sub_udata)); +} + +/* Overwrite the return address for frame UDATA with VAL. */ + +static inline void +put_return_addr (void *val, frame_state *udata) +{ + val = __builtin_frob_return_addr (val); + put_reg (udata->retaddr_column, val, udata); +} + +/* Given the current frame UDATA and its return address PC, return the + information about the calling frame in CALLER_UDATA. */ + +static void * +next_stack_level (void *pc, frame_state *udata, frame_state *caller_udata) +{ + caller_udata = __frame_state_for (pc, caller_udata); + if (! caller_udata) + return 0; + + /* Now go back to our caller's stack frame. If our caller's CFA register + was saved in our stack frame, restore it; otherwise, assume the CFA + register is SP and restore it to our CFA value. */ + if (udata->saved[caller_udata->cfa_reg]) + caller_udata->cfa = get_reg (caller_udata->cfa_reg, udata, 0); + else + caller_udata->cfa = udata->cfa; + caller_udata->cfa += caller_udata->cfa_offset; + + return caller_udata; +} + +/* Hook to call before __terminate if only cleanup handlers remain. */ +void +__unwinding_cleanup () +{ +} + +/* throw_helper performs some of the common grunt work for a throw. This + routine is called by throw and rethrows. This is pretty much split + out from the old __throw routine. An addition has been added which allows + for a dummy call to a routine __unwinding_cleanup() when there are nothing + but cleanups remaining. This allows a debugger to examine the state + at which the throw was executed, before any cleanups, rather than + at the terminate point after the stack has been unwound. + + EH is the current eh_context structure. + PC is the address of the call to __throw. + MY_UDATA is the unwind information for __throw. + OFFSET_P is where we return the SP adjustment offset. */ + +static void * +throw_helper (eh, pc, my_udata, offset_p) + struct eh_context *eh; + void *pc; + frame_state *my_udata; + long *offset_p; +{ + frame_state ustruct2, *udata = &ustruct2; + frame_state ustruct; + frame_state *sub_udata = &ustruct; + void *saved_pc = pc; + void *handler; + void *handler_p; + void *pc_p; + frame_state saved_ustruct; + int new_eh_model; + int cleanup = 0; + int only_cleanup = 0; + int rethrow = 0; + int saved_state = 0; + long args_size; + __eh_info *eh_info = (__eh_info *)eh->info; + + /* Do we find a handler based on a re-throw PC? */ + if (eh->table_index != (void *) 0) + rethrow = 1; + + memcpy (udata, my_udata, sizeof (*udata)); + + handler = (void *) 0; + for (;;) + { + frame_state *p = udata; + udata = next_stack_level (pc, udata, sub_udata); + sub_udata = p; + + /* If we couldn't find the next frame, we lose. */ + if (! udata) + break; + + if (udata->eh_ptr == NULL) + new_eh_model = 0; + else + new_eh_model = (((exception_descriptor *)(udata->eh_ptr))-> + runtime_id_field == NEW_EH_RUNTIME); + + if (rethrow) + { + rethrow = 0; + handler = find_exception_handler (eh->table_index, udata->eh_ptr, + eh_info, 1, &cleanup); + eh->table_index = (void *)0; + } + else + if (new_eh_model) + handler = find_exception_handler (pc, udata->eh_ptr, eh_info, + 0, &cleanup); + else + handler = old_find_exception_handler (pc, udata->eh_ptr); + + /* If we found one, we can stop searching, if its not a cleanup. + for cleanups, we save the state, and keep looking. This allows + us to call a debug hook if there are nothing but cleanups left. */ + if (handler) + { + if (cleanup) + { + if (!saved_state) + { + saved_ustruct = *udata; + handler_p = handler; + pc_p = pc; + saved_state = 1; + only_cleanup = 1; + } + } + else + { + only_cleanup = 0; + break; + } + } + + /* Otherwise, we continue searching. We subtract 1 from PC to avoid + hitting the beginning of the next region. */ + pc = get_return_addr (udata, sub_udata) - 1; + } + + if (saved_state) + { + udata = &saved_ustruct; + handler = handler_p; + pc = pc_p; + if (only_cleanup) + __unwinding_cleanup (); + } + + /* If we haven't found a handler by now, this is an unhandled + exception. */ + if (! handler) + __terminate(); + + eh->handler_label = handler; + + args_size = udata->args_size; + + if (pc == saved_pc) + /* We found a handler in the throw context, no need to unwind. */ + udata = my_udata; + else + { + int i; + + /* Unwind all the frames between this one and the handler by copying + their saved register values into our register save slots. */ + + /* Remember the PC where we found the handler. */ + void *handler_pc = pc; + + /* Start from the throw context again. */ + pc = saved_pc; + memcpy (udata, my_udata, sizeof (*udata)); + + while (pc != handler_pc) + { + frame_state *p = udata; + udata = next_stack_level (pc, udata, sub_udata); + sub_udata = p; + + for (i = 0; i < FIRST_PSEUDO_REGISTER; ++i) + if (i != udata->retaddr_column && udata->saved[i]) + { + /* If you modify the saved value of the return address + register on the SPARC, you modify the return address for + your caller's frame. Don't do that here, as it will + confuse get_return_addr. */ + if (in_reg_window (i, udata) + && udata->saved[udata->retaddr_column] == REG_SAVED_REG + && udata->reg_or_offset[udata->retaddr_column] == i) + continue; + copy_reg (i, udata, my_udata); + } + + pc = get_return_addr (udata, sub_udata) - 1; + } + + /* But we do need to update the saved return address register from + the last frame we unwind, or the handler frame will have the wrong + return address. */ + if (udata->saved[udata->retaddr_column] == REG_SAVED_REG) + { + i = udata->reg_or_offset[udata->retaddr_column]; + if (in_reg_window (i, udata)) + copy_reg (i, udata, my_udata); + } + } + /* udata now refers to the frame called by the handler frame. */ + + /* We adjust SP by the difference between __throw's CFA and the CFA for + the frame called by the handler frame, because those CFAs correspond + to the SP values at the two call sites. We need to further adjust by + the args_size of the handler frame itself to get the handler frame's + SP from before the args were pushed for that call. */ +#ifdef STACK_GROWS_DOWNWARD + *offset_p = udata->cfa - my_udata->cfa + args_size; +#else + *offset_p = my_udata->cfa - udata->cfa - args_size; +#endif + + return handler; +} + + +/* We first search for an exception handler, and if we don't find + it, we call __terminate on the current stack frame so that we may + use the debugger to walk the stack and understand why no handler + was found. + + If we find one, then we unwind the frames down to the one that + has the handler and transfer control into the handler. */ + +/*extern void __throw(void) __attribute__ ((__noreturn__));*/ + +void +__throw () +{ + struct eh_context *eh = (*get_eh_context) (); + void *pc, *handler; + long offset; + + /* XXX maybe make my_ustruct static so we don't have to look it up for + each throw. */ + frame_state my_ustruct, *my_udata = &my_ustruct; + + /* This is required for C++ semantics. We must call terminate if we + try and rethrow an exception, when there is no exception currently + active. */ + if (! eh->info) + __terminate (); + + /* Start at our stack frame. */ +label: + my_udata = __frame_state_for (&&label, my_udata); + if (! my_udata) + __terminate (); + + /* We need to get the value from the CFA register. */ + my_udata->cfa = __builtin_dwarf_cfa (); + + /* Do any necessary initialization to access arbitrary stack frames. + On the SPARC, this means flushing the register windows. */ + __builtin_unwind_init (); + + /* Now reset pc to the right throw point. */ + pc = __builtin_extract_return_addr (__builtin_return_address (0)) - 1; + + handler = throw_helper (eh, pc, my_udata, &offset); + + /* Now go! */ + + __builtin_eh_return ((void *)eh, offset, handler); + + /* Epilogue: restore the handler frame's register values and return + to the stub. */ +} + +/*extern void __rethrow(void *) __attribute__ ((__noreturn__));*/ + +void +__rethrow (index) + void *index; +{ + struct eh_context *eh = (*get_eh_context) (); + void *pc, *handler; + long offset; + + /* XXX maybe make my_ustruct static so we don't have to look it up for + each throw. */ + frame_state my_ustruct, *my_udata = &my_ustruct; + + /* This is required for C++ semantics. We must call terminate if we + try and rethrow an exception, when there is no exception currently + active. */ + if (! eh->info) + __terminate (); + + /* This is the table index we want to rethrow from. The value of + the END_REGION label is used for the PC of the throw, and the + search begins with the next table entry. */ + eh->table_index = index; + + /* Start at our stack frame. */ +label: + my_udata = __frame_state_for (&&label, my_udata); + if (! my_udata) + __terminate (); + + /* We need to get the value from the CFA register. */ + my_udata->cfa = __builtin_dwarf_cfa (); + + /* Do any necessary initialization to access arbitrary stack frames. + On the SPARC, this means flushing the register windows. */ + __builtin_unwind_init (); + + /* Now reset pc to the right throw point. */ + pc = __builtin_extract_return_addr (__builtin_return_address (0)) - 1; + + handler = throw_helper (eh, pc, my_udata, &offset); + + /* Now go! */ + + __builtin_eh_return ((void *)eh, offset, handler); + + /* Epilogue: restore the handler frame's register values and return + to the stub. */ +} +#endif /* DWARF2_UNWIND_INFO */ + +#endif /* L_eh */ + +#ifdef L_pure +#ifndef inhibit_libc +/* This gets us __GNU_LIBRARY__. */ +#undef NULL /* Avoid errors if stdio.h and our stddef.h mismatch. */ +#include + +#ifdef __GNU_LIBRARY__ + /* Avoid forcing the library's meaning of `write' on the user program + by using the "internal" name (for use within the library) */ +#define write(fd, buf, n) __write((fd), (buf), (n)) +#endif +#endif /* inhibit_libc */ + +#define MESSAGE "pure virtual method called\n" + +void +__pure_virtual () +{ +#ifndef inhibit_libc + write (2, MESSAGE, sizeof (MESSAGE) - 1); +#endif + __terminate (); +} +#endif diff --git a/lib/src/libgcc/longlong.h b/lib/src/libgcc/longlong.h new file mode 100644 index 00000000..d0f7cad8 --- /dev/null +++ b/lib/src/libgcc/longlong.h @@ -0,0 +1,242 @@ +// This file is copied from gcc 2.95.2 +// Asm code except mips has been removed + +/* longlong.h -- definitions for mixed size 32/64 bit arithmetic. + Copyright (C) 1991, 92, 94, 95, 96, 1997, 1998 Free Software Foundation, Inc. + + This definition file is free software; you can redistribute it + and/or modify it under the terms of the GNU General Public + License as published by the Free Software Foundation; either + version 2, or (at your option) any later version. + + This definition file is distributed in the hope that it will be + useful, but WITHOUT ANY WARRANTY; without even the implied + warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. + See the GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program; if not, write to the Free Software + Foundation, Inc., 59 Temple Place - Suite 330, + Boston, MA 02111-1307, USA. */ + +#ifndef SI_TYPE_SIZE +#define SI_TYPE_SIZE 32 +#endif + +#define __BITS4 (SI_TYPE_SIZE / 4) +#define __ll_B (1L << (SI_TYPE_SIZE / 2)) +#define __ll_lowpart(t) ((USItype) (t) % __ll_B) +#define __ll_highpart(t) ((USItype) (t) / __ll_B) + +/* Define auxiliary asm macros. + + 1) umul_ppmm(high_prod, low_prod, multipler, multiplicand) + multiplies two USItype integers MULTIPLER and MULTIPLICAND, + and generates a two-part USItype product in HIGH_PROD and + LOW_PROD. + + 2) __umulsidi3(a,b) multiplies two USItype integers A and B, + and returns a UDItype product. This is just a variant of umul_ppmm. + + 3) udiv_qrnnd(quotient, remainder, high_numerator, low_numerator, + denominator) divides a two-word unsigned integer, composed by the + integers HIGH_NUMERATOR and LOW_NUMERATOR, by DENOMINATOR and + places the quotient in QUOTIENT and the remainder in REMAINDER. + HIGH_NUMERATOR must be less than DENOMINATOR for correct operation. + If, in addition, the most significant bit of DENOMINATOR must be 1, + then the pre-processor symbol UDIV_NEEDS_NORMALIZATION is defined to 1. + + 4) sdiv_qrnnd(quotient, remainder, high_numerator, low_numerator, + denominator). Like udiv_qrnnd but the numbers are signed. The + quotient is rounded towards 0. + + 5) count_leading_zeros(count, x) counts the number of zero-bits from + the msb to the first non-zero bit. This is the number of steps X + needs to be shifted left to set the msb. Undefined for X == 0. + + 6) add_ssaaaa(high_sum, low_sum, high_addend_1, low_addend_1, + high_addend_2, low_addend_2) adds two two-word unsigned integers, + composed by HIGH_ADDEND_1 and LOW_ADDEND_1, and HIGH_ADDEND_2 and + LOW_ADDEND_2 respectively. The result is placed in HIGH_SUM and + LOW_SUM. Overflow (i.e. carry out) is not stored anywhere, and is + lost. + + 7) sub_ddmmss(high_difference, low_difference, high_minuend, + low_minuend, high_subtrahend, low_subtrahend) subtracts two + two-word unsigned integers, composed by HIGH_MINUEND_1 and + LOW_MINUEND_1, and HIGH_SUBTRAHEND_2 and LOW_SUBTRAHEND_2 + respectively. The result is placed in HIGH_DIFFERENCE and + LOW_DIFFERENCE. Overflow (i.e. carry out) is not stored anywhere, + and is lost. + + If any of these macros are left undefined for a particular CPU, + C macros are used. */ + +/* The CPUs come in alphabetical order below. + + Please add support for more CPUs here, or improve the current support + for the CPUs below! + (E.g. WE32100, IBM360.) */ + +#if defined (__GNUC__) && !defined (NO_ASM) + +/* We sometimes need to clobber "cc" with gcc2, but that would not be + understood by gcc1. Use cpp to avoid major code duplication. */ +#if __GNUC__ < 2 +#define __CLOBBER_CC +#define __AND_CLOBBER_CC +#else /* __GNUC__ >= 2 */ +#define __CLOBBER_CC : "cc" +#define __AND_CLOBBER_CC , "cc" +#endif /* __GNUC__ < 2 */ + +#if defined (__mips__) +#define umul_ppmm(w1, w0, u, v) \ + __asm__ ("multu %2,%3" \ + : "=l" ((USItype) (w0)), \ + "=h" ((USItype) (w1)) \ + : "d" ((USItype) (u)), \ + "d" ((USItype) (v))) +#define UMUL_TIME 10 +#define UDIV_TIME 100 +#endif /* __mips__ */ + +#endif /* __GNUC__ */ + +/* If this machine has no inline assembler, use C macros. */ + +#if !defined (add_ssaaaa) +#define add_ssaaaa(sh, sl, ah, al, bh, bl) \ + do { \ + USItype __x; \ + __x = (al) + (bl); \ + (sh) = (ah) + (bh) + (__x < (al)); \ + (sl) = __x; \ + } while (0) +#endif + +#if !defined (sub_ddmmss) +#define sub_ddmmss(sh, sl, ah, al, bh, bl) \ + do { \ + USItype __x; \ + __x = (al) - (bl); \ + (sh) = (ah) - (bh) - (__x > (al)); \ + (sl) = __x; \ + } while (0) +#endif + +#if !defined (umul_ppmm) +#define umul_ppmm(w1, w0, u, v) \ + do { \ + USItype __x0, __x1, __x2, __x3; \ + USItype __ul, __vl, __uh, __vh; \ + \ + __ul = __ll_lowpart (u); \ + __uh = __ll_highpart (u); \ + __vl = __ll_lowpart (v); \ + __vh = __ll_highpart (v); \ + \ + __x0 = (USItype) __ul * __vl; \ + __x1 = (USItype) __ul * __vh; \ + __x2 = (USItype) __uh * __vl; \ + __x3 = (USItype) __uh * __vh; \ + \ + __x1 += __ll_highpart (__x0);/* this can't give carry */ \ + __x1 += __x2; /* but this indeed can */ \ + if (__x1 < __x2) /* did we get it? */ \ + __x3 += __ll_B; /* yes, add it in the proper pos. */ \ + \ + (w1) = __x3 + __ll_highpart (__x1); \ + (w0) = __ll_lowpart (__x1) * __ll_B + __ll_lowpart (__x0); \ + } while (0) +#endif + +#if !defined (__umulsidi3) +#define __umulsidi3(u, v) \ + ({DIunion __w; \ + umul_ppmm (__w.s.high, __w.s.low, u, v); \ + __w.ll; }) +#endif + +/* Define this unconditionally, so it can be used for debugging. */ +#define __udiv_qrnnd_c(q, r, n1, n0, d) \ + do { \ + USItype __d1, __d0, __q1, __q0; \ + USItype __r1, __r0, __m; \ + __d1 = __ll_highpart (d); \ + __d0 = __ll_lowpart (d); \ + \ + __r1 = (n1) % __d1; \ + __q1 = (n1) / __d1; \ + __m = (USItype) __q1 * __d0; \ + __r1 = __r1 * __ll_B | __ll_highpart (n0); \ + if (__r1 < __m) \ + { \ + __q1--, __r1 += (d); \ + if (__r1 >= (d)) /* i.e. we didn't get carry when adding to __r1 */\ + if (__r1 < __m) \ + __q1--, __r1 += (d); \ + } \ + __r1 -= __m; \ + \ + __r0 = __r1 % __d1; \ + __q0 = __r1 / __d1; \ + __m = (USItype) __q0 * __d0; \ + __r0 = __r0 * __ll_B | __ll_lowpart (n0); \ + if (__r0 < __m) \ + { \ + __q0--, __r0 += (d); \ + if (__r0 >= (d)) \ + if (__r0 < __m) \ + __q0--, __r0 += (d); \ + } \ + __r0 -= __m; \ + \ + (q) = (USItype) __q1 * __ll_B | __q0; \ + (r) = __r0; \ + } while (0) + +/* If the processor has no udiv_qrnnd but sdiv_qrnnd, go through + __udiv_w_sdiv (defined in libgcc or elsewhere). */ +#if !defined (udiv_qrnnd) && defined (sdiv_qrnnd) +#define udiv_qrnnd(q, r, nh, nl, d) \ + do { \ + USItype __r; \ + (q) = __udiv_w_sdiv (&__r, nh, nl, d); \ + (r) = __r; \ + } while (0) +#endif + +/* If udiv_qrnnd was not defined for this processor, use __udiv_qrnnd_c. */ +#if !defined (udiv_qrnnd) +#define UDIV_NEEDS_NORMALIZATION 1 +#define udiv_qrnnd __udiv_qrnnd_c +#endif + +#if !defined (count_leading_zeros) +//extern const UQItype __clz_tab[]; +#define count_leading_zeros(count, x) \ + do { \ + USItype __xr = (x); \ + USItype __a; \ + \ + if (SI_TYPE_SIZE <= 32) \ + { \ + __a = __xr < ((USItype)1<<2*__BITS4) \ + ? (__xr < ((USItype)1<<__BITS4) ? 0 : __BITS4) \ + : (__xr < ((USItype)1<<3*__BITS4) ? 2*__BITS4 : 3*__BITS4); \ + } \ + else \ + { \ + for (__a = SI_TYPE_SIZE - 8; __a > 0; __a -= 8) \ + if (((__xr >> __a) & 0xff) != 0) \ + break; \ + } \ + \ + (count) = SI_TYPE_SIZE - (__clz_tab[__xr >> __a] + __a); \ + } while (0) +#endif + +#ifndef UDIV_NEEDS_NORMALIZATION +#define UDIV_NEEDS_NORMALIZATION 0 +#endif diff --git a/lib/src/libultra_internal.h b/lib/src/libultra_internal.h index 5639c6ac..bb7e2a0f 100644 --- a/lib/src/libultra_internal.h +++ b/lib/src/libultra_internal.h @@ -20,30 +20,20 @@ typedef struct OSThread_ListHead_s } OSThread_ListHead; // Now fix the symbols to the new one. -extern OSThread_ListHead D_80334890_fix; +extern OSThread_ListHead __osThreadTail_fix; -#define D_80334890 D_80334890_fix.next -#define D_80334894 D_80334890_fix.priority -#define D_80334898 D_80334890_fix.queue -#define D_8033489C D_80334890_fix.tlnext -#define D_803348A0 D_80334890_fix.unk10 - -// Fix for the EEPROM array. -extern u32 D_80365E00[16]; - -// alias the last array element correctly -#define D_80365E3C D_80365E00[15] +#define __osThreadTail __osThreadTail_fix.next +#define D_80334894 __osThreadTail_fix.priority +#define __osRunQueue __osThreadTail_fix.queue +#define __osActiveQueue __osThreadTail_fix.tlnext +#define __osRunningThread __osThreadTail_fix.unk10 #else // Original OSThread_ListHead definitions -extern OSThread *D_80334890; +extern OSThread *__osThreadTail; extern u32 D_80334894; -extern OSThread *D_80334898; -extern OSThread *D_8033489C; -extern OSThread *D_803348A0; - -// Original EEPROM definitions -extern u32 D_80365E00[15]; -extern u32 D_80365E3C; +extern OSThread *__osRunQueue; +extern OSThread *__osActiveQueue; +extern OSThread *__osRunningThread; #endif typedef struct { @@ -53,7 +43,7 @@ typedef struct { OSMesgQueue *eventQueue; OSMesgQueue *accessQueue; s32 (*dma_func)(s32, u32, void *, size_t); -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) s32 (*edma_func)(OSPiHandle*, s32, u32, void *, size_t); #else u64 force_align; @@ -76,9 +66,9 @@ void __osPiGetAccess(void); void __osSetSR(u32); u32 __osGetSR(void); void __osSetFpcCsr(u32); -s32 __osSiRawReadIo(void *, u32 *); -s32 __osSiRawWriteIo(void *, u32); -s32 osPiRawReadIo(u32 a0, u32 *a1); +s32 __osSiRawReadIo(u32, u32 *); +s32 __osSiRawWriteIo(u32, u32); +s32 osPiRawReadIo(u32, u32 *); void __osSpSetStatus(u32); u32 __osSpGetStatus(void); s32 __osSpSetPc(void *); @@ -96,4 +86,5 @@ s32 __osAiDeviceBusy(void); void __osDispatchThread(void); u32 __osGetCause(void); s32 __osAtomicDec(u32 *); +void __osSetHWIntrRoutine(OSHWIntr interrupt, s32 (*handler)(void)); #endif diff --git a/lib/src/math/cosf.c b/lib/src/math/cosf.c index 2b01c12a..9f74cf29 100644 --- a/lib/src/math/cosf.c +++ b/lib/src/math/cosf.c @@ -58,7 +58,6 @@ float cosf(float x) dn = dx * rpi.d + .5; if (0 <= dn) { - n = dn + .5; } else @@ -67,13 +66,15 @@ float cosf(float x) } dn = n; - dx -= (dn - .5) * pihi.d; - dx -= (dn - .5) * pilo.d; + dn -= .5; + dx -= dn * pihi.d; + dx -= dn * pilo.d; + xsq = dx * dx; poly = (((((P[4].d * xsq) + P[3].d) * xsq) + P[2].d) * xsq) + P[1].d; - result = ((dx * xsq) * poly) + dx; + result = dx + ((dx * xsq) * poly); if ((n & 0x1) == 0) { diff --git a/lib/src/math/llmuldiv.c b/lib/src/math/llmuldiv.c index e64b9d0c..2af91aae 100644 --- a/lib/src/math/llmuldiv.c +++ b/lib/src/math/llmuldiv.c @@ -7,7 +7,7 @@ unsigned long long __ull_rem(unsigned long long a0, unsigned long long a1) return a0 % a1; } unsigned long long __ull_div(unsigned long long a0, unsigned long long a1) -{ +{ return a0 / a1; } @@ -34,19 +34,19 @@ unsigned long long __ll_mul(unsigned long long a0, unsigned long long a1) void __ull_divremi(unsigned long long *div, unsigned long long *rem, unsigned long long a2, unsigned short a3) { *div = a2 / a3; - *rem = a2 % a3; -} + *rem = a2 % a3; +} long long __ll_mod(long long a0, long long a1) { long long tmp = a0 % a1; if ((tmp < 0 && a1 > 0) || (tmp > 0 && a1 < 0)) { - tmp += a1; + tmp += a1; } return tmp; } - + long long __ll_rshift(long long a0, long long a1) { return a0 >> a1; diff --git a/lib/src/math/sinf.c b/lib/src/math/sinf.c index bdc83168..0a5076c5 100644 --- a/lib/src/math/sinf.c +++ b/lib/src/math/sinf.c @@ -56,7 +56,7 @@ float sinf(float x) poly = (((((P[4].d * xsq) + P[3].d) * xsq) + P[2].d) * xsq) + P[1].d; - result = ((dx * xsq) * poly) + dx; + result = dx + ((dx * xsq) * poly); return result; } @@ -90,7 +90,7 @@ float sinf(float x) poly = (((((P[4].d * xsq) + P[3].d) * xsq) + P[2].d) * xsq) + P[1].d; - result = ((dx * xsq) * poly) + dx; + result = dx + ((dx * xsq) * poly); if ((n & 0x1) == 0) { diff --git a/lib/src/motor.c b/lib/src/motor.c index 3183fe22..acd58a4f 100644 --- a/lib/src/motor.c +++ b/lib/src/motor.c @@ -2,6 +2,19 @@ #include "PR/os_pi.h" #include "libultra_internal.h" #include "controller.h" +#include "macros.h" + +#ifdef VERSION_CN + +s32 __osMotorAccess(UNUSED OSPfs *pfs, UNUSED s32 action) { + return PFS_ERR_INVALID; +} + +s32 osMotorInit(UNUSED OSMesgQueue *mq, UNUSED OSPfs *pfs, UNUSED int channel) { + return PFS_ERR_DEVICE; +} + +#else void _MakeMotorData(int channel, u16 address, u8 *buffer, OSPifRam *mdata); u32 __osMotorinitialized[MAXCONTROLLERS] = { 0, 0, 0, 0 }; @@ -22,7 +35,7 @@ s32 osMotorStop(OSPfs *pfs) { } __osSiGetAccess(); - _osLastSentSiCmd = CONT_CMD_WRITE_MEMPACK; + __osContLastCmd = CONT_CMD_WRITE_MEMPACK; __osSiRawStartDma(OS_WRITE, &_MotorStopData[pfs->channel]); osRecvMesg(pfs->queue, NULL, OS_MESG_BLOCK); ret = __osSiRawStartDma(OS_READ, &__osPfsPifRam); @@ -58,7 +71,7 @@ s32 osMotorStart(OSPfs *pfs) { __osSiGetAccess(); - _osLastSentSiCmd = CONT_CMD_WRITE_MEMPACK; + __osContLastCmd = CONT_CMD_WRITE_MEMPACK; __osSiRawStartDma(OS_WRITE, &_MotorStartData[pfs->channel]); osRecvMesg(pfs->queue, NULL, OS_MESG_BLOCK); ret = __osSiRawStartDma(OS_READ, &__osPfsPifRam); @@ -86,7 +99,7 @@ void _MakeMotorData(int channel, u16 address, u8 *buffer, OSPifRam *mdata) { int i; ptr = (u8 *) mdata->ramarray; - for (i = 0; i < ARRLEN(mdata->ramarray); i++) { + for (i = 0; i < ARRAY_COUNT(mdata->ramarray); i++) { mdata->ramarray[i] = 0; } mdata->pifstatus = CONT_CMD_EXE; @@ -97,7 +110,7 @@ void _MakeMotorData(int channel, u16 address, u8 *buffer, OSPifRam *mdata) { ramreadformat.address = (address << 0x5) | __osContAddressCrc(address); ramreadformat.datacrc = CONT_CMD_NOP; - for (i = 0; i < ARRLEN(ramreadformat.data); i++) { + for (i = 0; i < ARRAY_COUNT(ramreadformat.data); i++) { ramreadformat.data[i] = *buffer++; } if (channel != 0) { @@ -119,7 +132,7 @@ s32 osMotorInit(OSMesgQueue *mq, OSPfs *pfs, int channel) { pfs->status = 0; pfs->activebank = 128; - for (i = 0; i < ARRLEN(temp); i++) { + for (i = 0; i < ARRAY_COUNT(temp); i++) { temp[i] = 254; } @@ -142,7 +155,7 @@ s32 osMotorInit(OSMesgQueue *mq, OSPfs *pfs, int channel) { return PFS_ERR_DEVICE; } - for (i = 0; i < ARRLEN(temp); i++) { + for (i = 0; i < ARRAY_COUNT(temp); i++) { temp[i] = 128; } @@ -166,7 +179,7 @@ s32 osMotorInit(OSMesgQueue *mq, OSPfs *pfs, int channel) { } if (!__osMotorinitialized[channel]) { - for (i = 0; i < ARRLEN(_motorstartbuf); i++) { + for (i = 0; i < ARRAY_COUNT(_motorstartbuf); i++) { _motorstartbuf[i] = 1; _motorstopbuf[i] = 0; } @@ -176,3 +189,5 @@ s32 osMotorInit(OSMesgQueue *mq, OSPfs *pfs, int channel) { } return 0; } + +#endif diff --git a/lib/src/new_func.h b/lib/src/new_func.h index f966f6d3..824412da 100644 --- a/lib/src/new_func.h +++ b/lib/src/new_func.h @@ -2,27 +2,13 @@ #define NEW_FUNC_H #include "libultra_internal.h" -#include "hardware.h" -#define WAIT_ON_IOBUSY(var) \ - var = HW_REG(PI_STATUS_REG, u32); \ - while (var & PI_STATUS_IOBUSY) \ - var = HW_REG(PI_STATUS_REG, u32); +extern u32 osDDActive; -extern u32 EU_D_80302090; - -extern OSPiHandle *__osDiskHandle; //possibly __osPiTable - -extern volatile u32 __OSGlobalIntMask; -s32 osEPiRawStartDma(OSPiHandle *arg0, s32 dir, u32 cart_addr, void *dram_addr, u32 size); -void func_802F4B08(void); -void func_802F4A20(void); void __osResetGlobalIntMask(u32 mask); -void __osEPiRawWriteIo(OSPiHandle*, u32, u32); -void func_802F71F0(void); -#ifdef VERSION_SH +void osYieldThread(void); +#if defined(VERSION_SH) || defined(VERSION_CN) void __osSetGlobalIntMask(s32 arg0); -s32 __osEPiRawReadIo(OSPiHandle *arg0, u32 devAddr, u32 *arg2); #endif #endif diff --git a/lib/src/osAiGetLength.c b/lib/src/osAiGetLength.c index 08458a7a..ba730b62 100644 --- a/lib/src/osAiGetLength.c +++ b/lib/src/osAiGetLength.c @@ -1,7 +1,6 @@ #include "libultra_internal.h" -#include "osAi.h" -#include "hardware.h" +#include "PR/rcp.h" u32 osAiGetLength() { - return HW_REG(AI_LEN_REG, u32); + return IO_READ(AI_LEN_REG); } diff --git a/lib/src/osAiSetFrequency.c b/lib/src/osAiSetFrequency.c index 5cc8bc93..5aaee8a8 100644 --- a/lib/src/osAiSetFrequency.c +++ b/lib/src/osAiSetFrequency.c @@ -1,34 +1,38 @@ #include "libultra_internal.h" -#include "osAi.h" -#include "hardware.h" +#include "PR/rcp.h" +#include "osint.h" #include "macros.h" -extern s32 osViClock; - s32 osAiSetFrequency(u32 freq) { - register u32 a1; - register s32 a2; + register u32 dacRate; +#ifdef VERSION_CN + register u32 bitRate; +#else + register s32 bitRate; +#endif register float ftmp; ftmp = osViClock / (float) freq + .5f; - a1 = ftmp; + dacRate = ftmp; - if (a1 < 0x84) { + if (dacRate < AI_MIN_DAC_RATE) { return -1; } - a2 = (a1 / 66) & 0xff; - if (a2 > 16) { - a2 = 16; + bitRate = (dacRate / 66) & 0xff; + if (bitRate > AI_MAX_BIT_RATE) { + bitRate = AI_MAX_BIT_RATE; } - HW_REG(AI_DACRATE_REG, u32) = a1 - 1; - HW_REG(AI_BITRATE_REG, u32) = a2 - 1; - HW_REG(AI_CONTROL_REG, u32) = 1; // enable dma - return osViClock / (s32) a1; + IO_WRITE(AI_DACRATE_REG, dacRate - 1); + IO_WRITE(AI_BITRATE_REG, bitRate - 1); +#ifndef VERSION_CN + IO_WRITE(AI_CONTROL_REG, AI_CONTROL_DMA_ON); +#endif + return osViClock / (s32) dacRate; } -#ifndef VERSION_SH +#if !defined(VERSION_SH) && !defined(VERSION_CN) // put some extra jr $ra's down there please UNUSED static void filler1(void) { } diff --git a/lib/src/osAiSetNextBuffer.c b/lib/src/osAiSetNextBuffer.c index cc27ae4c..10b7bd26 100644 --- a/lib/src/osAiSetNextBuffer.c +++ b/lib/src/osAiSetNextBuffer.c @@ -1,8 +1,5 @@ #include "libultra_internal.h" -#include "osAi.h" -#include "hardware.h" - -u8 D_80334820 = 0; +#include "PR/rcp.h" /** * It is worth noting that a previous hardware bug has been fixed by a software @@ -19,22 +16,38 @@ u8 D_80334820 = 0; */ s32 osAiSetNextBuffer(void *buff, u32 len) { - u8 *sp1c = buff; - if (D_80334820 != 0) { - sp1c -= 0x2000; - } - - if ((((uintptr_t) buff + len) & 0x3fff) == 0x2000) { - D_80334820 = 1; - } else { - D_80334820 = 0; - } + static u8 hdwrBugFlag = 0; + char *bptr; +#ifdef VERSION_CN if (__osAiDeviceBusy()) { return -1; } +#endif - HW_REG(AI_DRAM_ADDR_REG, void *) = (void *) osVirtualToPhysical(sp1c); - HW_REG(AI_LEN_REG, u32) = len; + bptr = buff; + + if (hdwrBugFlag != 0) { + bptr -= 0x2000; + } + +#ifdef VERSION_CN + if ((((uintptr_t) buff + len) & 0x1fff) == 0) { +#else + if ((((uintptr_t) buff + len) & 0x3fff) == 0x2000) { +#endif + hdwrBugFlag = 1; + } else { + hdwrBugFlag = 0; + } + +#ifndef VERSION_CN + if (__osAiDeviceBusy()) { + return -1; + } +#endif + + IO_WRITE(AI_DRAM_ADDR_REG, osVirtualToPhysical(bptr)); + IO_WRITE(AI_LEN_REG, len); return 0; } diff --git a/lib/src/osCartRomInit.c b/lib/src/osCartRomInit.c index 84ea3b63..937cf1e1 100644 --- a/lib/src/osCartRomInit.c +++ b/lib/src/osCartRomInit.c @@ -4,8 +4,72 @@ #include "PR/os_pi.h" #include "PR/os.h" #include "libultra_internal.h" +#include "piint.h" -OSPiHandle CartRomHandle; +OSPiHandle __Dom1SpeedParam; + +#ifdef VERSION_CN + +OSPiHandle __CartRomHandle; + +OSPiHandle* osCartRomInit(void) { + register u32 a; + register s32 status; + register u32 prevInt; + register u32 lastLatency; + register u32 lastPageSize; + register u32 lastRelDuration; + register u32 lastPulse; + + static u32 notInitialized = 1; + + __osPiGetAccess(); + + if (!notInitialized) { + __osPiRelAccess(); + return &__CartRomHandle; + } + + notInitialized = 0; + __CartRomHandle.type = DEVICE_TYPE_CART; + __CartRomHandle.baseAddress = PHYS_TO_K1(PI_DOM1_ADDR2); + __CartRomHandle.domain = 0; + __CartRomHandle.speed = 0; + bzero(&__CartRomHandle.transferInfo, sizeof(__OSTranxInfo)); + + WAIT_ON_IO_BUSY(status); + + lastLatency = IO_READ(PI_BSD_DOM1_LAT_REG); + lastPageSize = IO_READ(PI_BSD_DOM1_PGS_REG); + lastRelDuration = IO_READ(PI_BSD_DOM1_RLS_REG); + lastPulse = IO_READ(PI_BSD_DOM1_PWD_REG); + + IO_WRITE(PI_BSD_DOM1_LAT_REG, 0xff); + IO_WRITE(PI_BSD_DOM1_PGS_REG, 0); + IO_WRITE(PI_BSD_DOM1_RLS_REG, 3); + IO_WRITE(PI_BSD_DOM1_PWD_REG, 0xff); + + a = IO_READ(__CartRomHandle.baseAddress); + __CartRomHandle.latency = a & 0xFF; + __CartRomHandle.pageSize = (a >> 0x10) & 0xF; + __CartRomHandle.relDuration = (a >> 0x14) & 0xF; + __CartRomHandle.pulse = (a >> 8) & 0xFF; + + IO_WRITE(PI_BSD_DOM1_LAT_REG, lastLatency); + IO_WRITE(PI_BSD_DOM1_PGS_REG, lastPageSize); + IO_WRITE(PI_BSD_DOM1_RLS_REG, lastRelDuration); + IO_WRITE(PI_BSD_DOM1_PWD_REG, lastPulse); + + prevInt = __osDisableInt(); + __CartRomHandle.next = __osPiTable; + __osPiTable = &__CartRomHandle; + __osRestoreInt(prevInt); + __osPiRelAccess(); + + return &__CartRomHandle; +} + +#else OSPiHandle *osCartRomInit(void) { u32 domain; @@ -13,26 +77,28 @@ OSPiHandle *osCartRomInit(void) { domain = 0; - if (CartRomHandle.baseAddress == PHYS_TO_K1(PI_DOM1_ADDR2)) { - return &CartRomHandle; + if (__Dom1SpeedParam.baseAddress == PHYS_TO_K1(PI_DOM1_ADDR2)) { + return &__Dom1SpeedParam; } - CartRomHandle.type = DEVICE_TYPE_CART; - CartRomHandle.baseAddress = PHYS_TO_K1(PI_DOM1_ADDR2); + __Dom1SpeedParam.type = DEVICE_TYPE_CART; + __Dom1SpeedParam.baseAddress = PHYS_TO_K1(PI_DOM1_ADDR2); osPiRawReadIo(0, &domain); - CartRomHandle.latency = domain & 0xff; - CartRomHandle.pulse = (domain >> 8) & 0xff; - CartRomHandle.pageSize = (domain >> 0x10) & 0xf; - CartRomHandle.relDuration = (domain >> 0x14) & 0xf; - CartRomHandle.domain = PI_DOMAIN1; - //CartRomHandle.speed = 0; + __Dom1SpeedParam.latency = domain & 0xff; + __Dom1SpeedParam.pulse = (domain >> 8) & 0xff; + __Dom1SpeedParam.pageSize = (domain >> 0x10) & 0xf; + __Dom1SpeedParam.relDuration = (domain >> 0x14) & 0xf; + __Dom1SpeedParam.domain = PI_DOMAIN1; + //__Dom1SpeedParam.speed = 0; - bzero(&CartRomHandle.transferInfo, sizeof(__OSTranxInfo)); + bzero(&__Dom1SpeedParam.transferInfo, sizeof(__OSTranxInfo)); saveMask = __osDisableInt(); - CartRomHandle.next = __osPiTable; - __osPiTable = &CartRomHandle; + __Dom1SpeedParam.next = __osPiTable; + __osPiTable = &__Dom1SpeedParam; __osRestoreInt(saveMask); - return &CartRomHandle; + return &__Dom1SpeedParam; } + +#endif diff --git a/lib/src/osContInit.c b/lib/src/osContInit.c index d5454008..ce3aa8ab 100644 --- a/lib/src/osContInit.c +++ b/lib/src/osContInit.c @@ -1,19 +1,27 @@ #include "libultra_internal.h" #include "osContInternal.h" +#include "PR/os.h" +#include "controller.h" +#include "PR/ique.h" void __osPackRequestData(u8); void __osContGetInitData(u8 *, OSContStatus *); u32 _osContInitialized = 0; // probably initialized -extern u64 osClockRate; +#ifdef VERSION_CN +#define CLOCK_RATE (62500000ULL * 3 / 4) +#else +#define CLOCK_RATE osClockRate +#endif // these probably belong in EEPROMlongread or something -u8 _osLastSentSiCmd; -u8 _osContNumControllers; -OSTimer D_80365D28; -OSMesgQueue _osContMesgQueue; -OSMesg _osContMesgBuff[4]; +u8 __osContLastCmd; +u8 __osMaxControllers; +OSTimer __osEepromTimer; +OSMesgQueue __osEepromTimerQ; +OSMesg __osEepromTimerMsg[4]; + s32 osContInit(OSMesgQueue *mq, u8 *bitpattern, OSContStatus *status) { OSMesg mesg; u32 ret = 0; @@ -26,63 +34,86 @@ s32 osContInit(OSMesgQueue *mq, u8 *bitpattern, OSContStatus *status) { } _osContInitialized = 1; currentTime = osGetTime(); - if (500000 * osClockRate / 1000000 > currentTime) { + if (500000 * CLOCK_RATE / 1000000 > currentTime) { osCreateMesgQueue(&timerMesgQueue, &mesg, 1); - osSetTimer(&timer, 500000 * osClockRate / 1000000 - currentTime, 0, &timerMesgQueue, &mesg); + osSetTimer(&timer, 500000 * CLOCK_RATE / 1000000 - currentTime, 0, &timerMesgQueue, &mesg); osRecvMesg(&timerMesgQueue, &mesg, OS_MESG_BLOCK); } - _osContNumControllers = 4; // TODO: figure out what it means -#if defined(VERSION_EU) || defined(VERSION_SH) + __osMaxControllers = MAXCONTROLLERS; +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) __osPackRequestData(0); #else __osPackRequestData(255); #endif - ret = __osSiRawStartDma(OS_WRITE, _osContCmdBuf); + ret = __osSiRawStartDma(OS_WRITE, __osContPifRam.ramarray); osRecvMesg(mq, &mesg, OS_MESG_BLOCK); - ret = __osSiRawStartDma(OS_READ, _osContCmdBuf); + ret = __osSiRawStartDma(OS_READ, __osContPifRam.ramarray); osRecvMesg(mq, &mesg, OS_MESG_BLOCK); __osContGetInitData(bitpattern, status); #if defined(VERSION_EU) || defined(VERSION_SH) - _osLastSentSiCmd = 0; + __osContLastCmd = CONT_CMD_REQUEST_STATUS; +#elif defined(VERSION_CN) + __osContLastCmd = 0xfd; #else - _osLastSentSiCmd = 255; + __osContLastCmd = CONT_CMD_RESET; #endif __osSiCreateAccessQueue(); - osCreateMesgQueue(&_osContMesgQueue, _osContMesgBuff, 1); + osCreateMesgQueue(&__osEepromTimerQ, __osEepromTimerMsg, 1); return ret; } + void __osContGetInitData(u8 *bitpattern, OSContStatus *status) { - OSContPackedRequest *cmdBufPtr; + u8 *cmdBufPtr; OSContPackedRequest response; s32 i; u8 sp7; sp7 = 0; - cmdBufPtr = &(_osContCmdBuf[0].request); - for (i = 0; i < _osContNumControllers; i++, cmdBufPtr++, status++) { + cmdBufPtr = (u8 *) __osContPifRam.ramarray; + for (i = 0; i < __osMaxControllers; i++, cmdBufPtr += sizeof(OSContPackedRequest), status++) { response = *(OSContPackedRequest *) cmdBufPtr; status->errnum = (response.rxLen & 0xc0) >> 4; if (status->errnum == 0) { status->type = response.data2 << 8 | response.data1; +#ifdef VERSION_CN + status->status = __osBbPakAddress[i] != NULL ? 1 : 0; +#else status->status = response.data3; +#endif sp7 |= 1 << i; } } +#ifdef VERSION_CN + if (__osBbIsBb != 0 && __osBbHackFlags != 0) { + OSContStatus tmp; + status -= __osMaxControllers; + sp7 = (sp7 & ~((1 << __osBbHackFlags) | 1)) | + ((sp7 & 1) << __osBbHackFlags) | + ((sp7 & (1 << __osBbHackFlags)) >> __osBbHackFlags); + tmp = *status; + *status = status[__osBbHackFlags]; + status[__osBbHackFlags] = tmp; + } +#endif *bitpattern = sp7; } + void __osPackRequestData(u8 command) { - OSContPackedRequest *cmdBufPtr; + u8 *cmdBufPtr; OSContPackedRequest request; s32 i; - // some kind of weird zeroing code - for (i = 0; i < 0x10; i++) { - *((u32 *) &_osContCmdBuf + i) = 0; +#ifdef VERSION_CN + for (i = 0; i < ARRAY_COUNT(__osContPifRam.ramarray); i++) { +#else + for (i = 0; i < ARRAY_COUNT(__osContPifRam.ramarray) + 1; i++) { +#endif + __osContPifRam.ramarray[i] = 0; } - _osContPifCtrl = 1; - cmdBufPtr = &_osContCmdBuf[0].request; + __osContPifRam.pifstatus = 1; + cmdBufPtr = (u8 *) __osContPifRam.ramarray; request.padOrEnd = 255; request.txLen = 1; request.rxLen = 3; @@ -92,8 +123,9 @@ void __osPackRequestData(u8 command) { request.data3 = 255; request.data4 = 255; - for (i = 0; i < _osContNumControllers; i++) { - *cmdBufPtr++ = request; + for (i = 0; i < __osMaxControllers; i++) { + * (OSContPackedRequest *) cmdBufPtr = request; + cmdBufPtr += sizeof(OSContPackedRequest); } - cmdBufPtr->padOrEnd = 254; + *cmdBufPtr = 254; } diff --git a/lib/src/osContInternal.h b/lib/src/osContInternal.h index 0f628205..997fe4c9 100644 --- a/lib/src/osContInternal.h +++ b/lib/src/osContInternal.h @@ -32,16 +32,4 @@ typedef union { u32 as_raw[2]; } OSContPackedStruct; -#ifdef AVOID_UB -// Fix the OSContPackedStruct array -extern OSContPackedStruct _osContCmdBuf[8]; - -// And fix the last element -#define _osContPifCtrl _osContCmdBuf[7].as_raw[1] -#else -// Original OSContPackedStruct definitions -extern OSContPackedStruct _osContCmdBuf[7]; -extern u32 _osContPifCtrl; -#endif - #endif diff --git a/lib/src/osContStartReadData.c b/lib/src/osContStartReadData.c index 4362223a..0c7abcae 100644 --- a/lib/src/osContStartReadData.c +++ b/lib/src/osContStartReadData.c @@ -1,64 +1,86 @@ #include "libultra_internal.h" #include "osContInternal.h" +#include "PR/ique.h" #include +#include "controller.h" -#ifndef AVOID_UB -ALIGNED8 OSContPackedStruct _osContCmdBuf[7]; -UNUSED static u32 unused; // padding between these two variables -u32 _osContPifCtrl; -#else -// Reordered gcc vars above will disturb the aliasing done to access all 8 members of this array, hence AVOID_UB. -ALIGNED8 OSContPackedStruct _osContCmdBuf[8]; -#endif +ALIGNED8 OSPifRam __osContPifRam; -extern u8 _osLastSentSiCmd; -extern u8 _osContNumControllers; +extern u8 __osContLastCmd; +extern u8 __osMaxControllers; void __osPackReadData(void); + s32 osContStartReadData(OSMesgQueue *mesg) { +#ifdef VERSION_CN + s32 ret; +#else s32 ret = 0; s32 i; +#endif __osSiGetAccess(); - if (_osLastSentSiCmd != 1) { + if (__osContLastCmd != CONT_CMD_READ_BUTTON) { __osPackReadData(); - ret = __osSiRawStartDma(OS_WRITE, _osContCmdBuf); + ret = __osSiRawStartDma(OS_WRITE, __osContPifRam.ramarray); osRecvMesg(mesg, NULL, OS_MESG_BLOCK); } - for (i = 0; i < 0x10; i++) { - *((u32 *) &_osContCmdBuf + i) = 255; +#ifndef VERSION_CN + for (i = 0; i < ARRAY_COUNT(__osContPifRam.ramarray) + 1; i++) { + __osContPifRam.ramarray[i] = 0xff; } + __osContPifRam.pifstatus = 0; +#endif - _osContPifCtrl = 0; - ret = __osSiRawStartDma(OS_READ, _osContCmdBuf); - _osLastSentSiCmd = 1; + ret = __osSiRawStartDma(OS_READ, __osContPifRam.ramarray); +#ifdef VERSION_CN + __osContLastCmd = 0xfd; +#else + __osContLastCmd = CONT_CMD_READ_BUTTON; +#endif __osSiRelAccess(); return ret; } + void osContGetReadData(OSContPad *pad) { - OSContPackedRead *cmdBufPtr; + u8 *cmdBufPtr; OSContPackedRead response; s32 i; - cmdBufPtr = &_osContCmdBuf[0].read; - for (i = 0; i < _osContNumControllers; i++, cmdBufPtr++, pad++) { - response = *cmdBufPtr; + cmdBufPtr = (u8 *) __osContPifRam.ramarray; + for (i = 0; i < __osMaxControllers; i++, cmdBufPtr += sizeof(OSContPackedRead), pad++) { + response = * (OSContPackedRead *) cmdBufPtr; pad->errnum = (response.rxLen & 0xc0) >> 4; if (pad->errnum == 0) { pad->button = response.button; pad->stick_x = response.rawStickX; pad->stick_y = response.rawStickY; } - }; + } +#ifdef VERSION_CN + if (__osBbIsBb != 0 && __osBbHackFlags != 0) { + OSContPad tmp; + pad -= __osMaxControllers; + tmp = *pad; + *pad = pad[__osBbHackFlags]; + pad[__osBbHackFlags] = tmp; + } +#endif } + void __osPackReadData() { - OSContPackedRead *cmdBufPtr; + u8 *cmdBufPtr; OSContPackedRead request; s32 i; - cmdBufPtr = &_osContCmdBuf[0].read; - for (i = 0; i < 0x10; i++) { - *((u32 *) &_osContCmdBuf + i) = 0; + cmdBufPtr = (u8 *) __osContPifRam.ramarray; + +#ifdef VERSION_CN + for (i = 0; i < ARRAY_COUNT(__osContPifRam.ramarray); i++) { +#else + for (i = 0; i < ARRAY_COUNT(__osContPifRam.ramarray) + 1; i++) { +#endif + __osContPifRam.ramarray[i] = 0; } - _osContPifCtrl = 1; + __osContPifRam.pifstatus = 1; request.padOrEnd = 255; request.txLen = 1; request.rxLen = 4; @@ -66,8 +88,9 @@ void __osPackReadData() { request.button = 65535; request.rawStickX = -1; request.rawStickY = -1; - for (i = 0; i < _osContNumControllers; i++) { - *cmdBufPtr++ = request; + for (i = 0; i < __osMaxControllers; i++) { + * (OSContPackedRead *) cmdBufPtr = request; + cmdBufPtr += sizeof(OSContPackedRead); } - cmdBufPtr->padOrEnd = 254; + *cmdBufPtr = 254; } diff --git a/lib/src/osCreateMesgQueue.c b/lib/src/osCreateMesgQueue.c index 727c0af7..c8ac4901 100644 --- a/lib/src/osCreateMesgQueue.c +++ b/lib/src/osCreateMesgQueue.c @@ -1,11 +1,10 @@ #include "libultra_internal.h" void osCreateMesgQueue(OSMesgQueue *mq, OSMesg *msgBuf, s32 count) { - mq->mtqueue = (OSThread *) &D_80334890; //? - mq->fullqueue = (OSThread *) &D_80334890; + mq->mtqueue = (OSThread *) &__osThreadTail; + mq->fullqueue = (OSThread *) &__osThreadTail; mq->validCount = 0; mq->first = 0; mq->msgCount = count; mq->msg = msgBuf; - return; } diff --git a/lib/src/osCreatePiManager.c b/lib/src/osCreatePiManager.c index 890cfe32..7014d9c3 100644 --- a/lib/src/osCreatePiManager.c +++ b/lib/src/osCreatePiManager.c @@ -1,23 +1,25 @@ #include "libultra_internal.h" +#include "PR/os.h" +#include "piint.h" + +#include "macros.h" #define OS_PI_MGR_MESG_BUFF_SIZE 1 -#ifdef VERSION_SH // TODO: In libreultra this is in an include -extern OSPiHandle *CartRomHandle; -extern OSPiHandle *LeoDiskHandle; -#endif +OSDevMgr __osPiDevMgr = { 0 }; -OSMgrArgs __osPiDevMgr = { 0 }; -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) OSPiHandle *__osPiTable = NULL; #endif -#ifdef VERSION_SH -OSPiHandle **__osCurrentHandle[2] = { &CartRomHandle, &LeoDiskHandle }; + +#if defined(VERSION_SH) || defined(VERSION_CN) +OSPiHandle *__osCurrentHandle[2] = { &__Dom1SpeedParam, &__Dom2SpeedParam }; #endif -OSThread piMgrThread; -u32 piMgrStack[0x400]; // stack bottom -OSMesgQueue __osPiMesgQueue; -OSMesg piMgrMesgBuff[OS_PI_MGR_MESG_BUFF_SIZE + 1]; + +FORCE_BSS OSThread piMgrThread; +FORCE_BSS u32 piMgrStack[0x400]; // stack bottom +FORCE_BSS OSMesgQueue piEventQueue; +FORCE_BSS OSMesg piEventBuf[OS_PI_MGR_MESG_BUFF_SIZE + 1]; extern u32 gOsPiAccessQueueCreated; extern OSMesgQueue gOsPiMessageQueue; @@ -28,13 +30,13 @@ void osCreatePiManager(OSPri pri, OSMesgQueue *cmdQ, OSMesg *cmdBuf, s32 cmdMsgC OSPri newPri; OSPri currentPri; - if (!__osPiDevMgr.initialized) { + if (!__osPiDevMgr.active) { osCreateMesgQueue(cmdQ, cmdBuf, cmdMsgCnt); - osCreateMesgQueue(&__osPiMesgQueue, &piMgrMesgBuff[0], OS_PI_MGR_MESG_BUFF_SIZE); + osCreateMesgQueue(&piEventQueue, &piEventBuf[0], OS_PI_MGR_MESG_BUFF_SIZE); if (!gOsPiAccessQueueCreated) { __osPiCreateAccessQueue(); } // what is this constant geez - osSetEventMesg(OS_EVENT_PI, &__osPiMesgQueue, (void *) 0x22222222); + osSetEventMesg(OS_EVENT_PI, &piEventQueue, (void *) 0x22222222); newPri = -1; currentPri = osGetThreadPri(NULL); if (currentPri < pri) { @@ -42,14 +44,14 @@ void osCreatePiManager(OSPri pri, OSMesgQueue *cmdQ, OSMesg *cmdBuf, s32 cmdMsgC osSetThreadPri(NULL, pri); } int_disabled = __osDisableInt(); - __osPiDevMgr.initialized = TRUE; - __osPiDevMgr.mgrThread = &piMgrThread; + __osPiDevMgr.active = TRUE; + __osPiDevMgr.thread = &piMgrThread; __osPiDevMgr.cmdQueue = cmdQ; - __osPiDevMgr.eventQueue = &__osPiMesgQueue; - __osPiDevMgr.accessQueue = &gOsPiMessageQueue; - __osPiDevMgr.dma_func = osPiRawStartDma; -#if defined(VERSION_EU) || defined(VERSION_SH) - __osPiDevMgr.edma_func = osEPiRawStartDma; + __osPiDevMgr.evtQueue = &piEventQueue; + __osPiDevMgr.acsQueue = &gOsPiMessageQueue; + __osPiDevMgr.dma = osPiRawStartDma; +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) + __osPiDevMgr.edma = osEPiRawStartDma; #endif osCreateThread(&piMgrThread, 0, __osDevMgrMain, (void *) &__osPiDevMgr, &piMgrStack[0x400], pri); osStartThread(&piMgrThread); diff --git a/lib/src/osCreateThread.c b/lib/src/osCreateThread.c index b4e283f2..1598dcbb 100644 --- a/lib/src/osCreateThread.c +++ b/lib/src/osCreateThread.c @@ -1,4 +1,5 @@ #include "libultra_internal.h" +#include void __osCleanupThread(void); @@ -7,8 +8,9 @@ void __osCleanupThread(void); #pragma GCC diagnostic ignored "-Wpointer-to-int-cast" void osCreateThread(OSThread *thread, OSId id, void (*entry)(void *), void *arg, void *sp, OSPri pri) { - register u32 int_disabled; - u32 tmp; + register u32 saveMask; + OSIntMask mask; + thread->id = id; thread->priority = pri; thread->next = NULL; @@ -17,18 +19,19 @@ void osCreateThread(OSThread *thread, OSId id, void (*entry)(void *), void *arg, thread->context.a0 = (u64) arg; thread->context.sp = (u64) sp - 16; thread->context.ra = (u64) __osCleanupThread; - tmp = OS_IM_ALL; - thread->context.sr = 65283; - thread->context.rcp = (tmp & 0x3f0000) >> 16; - thread->context.fpcsr = (u32) 0x01000800; + + mask = OS_IM_ALL; + thread->context.sr = (mask & OS_IM_CPU) | SR_EXL; + thread->context.rcp = (mask & RCP_IMASK) >> RCP_IMASKSHIFT; + thread->context.fpcsr = (u32) (FPCSR_FS | FPCSR_EV); thread->fp = 0; thread->state = OS_STATE_STOPPED; thread->flags = 0; - int_disabled = __osDisableInt(); - thread->tlnext = D_8033489C; + saveMask = __osDisableInt(); + thread->tlnext = __osActiveQueue; - D_8033489C = thread; - __osRestoreInt(int_disabled); + __osActiveQueue = thread; + __osRestoreInt(saveMask); } #pragma GCC diagnostic pop diff --git a/lib/src/osCreateViManager.c b/lib/src/osCreateViManager.c index 67776ed6..f78c4cbd 100644 --- a/lib/src/osCreateViManager.c +++ b/lib/src/osCreateViManager.c @@ -18,12 +18,19 @@ extern u32 __osBaseCounter; extern u32 __osViIntrCount; void viMgrMain(void *); +#ifdef VERSION_CN +u32 __additional_scanline = 0; +#endif + void osCreateViManager(OSPri pri) { u32 int_disabled; OSPri newPri; OSPri currentPri; if (!viMgrMainArgs.initialized) { __osTimerServicesInit(); +#ifdef VERSION_CN + __additional_scanline = 0; +#endif osCreateMesgQueue(&__osViMesgQueue, &viMgrMesgBuff[0], OS_VI_MANAGER_MESSAGE_BUFF_SIZE); viEventViMesg.hdr.type = 13; viEventViMesg.hdr.pri = 0; @@ -46,7 +53,7 @@ void osCreateViManager(OSPri pri) { viMgrMainArgs.eventQueue = &__osViMesgQueue; viMgrMainArgs.accessQueue = NULL; viMgrMainArgs.dma_func = NULL; -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) viMgrMainArgs.edma_func = NULL; #endif diff --git a/lib/src/osDestroyThread.c b/lib/src/osDestroyThread.c index 215ce073..2f5c989d 100644 --- a/lib/src/osDestroyThread.c +++ b/lib/src/osDestroyThread.c @@ -8,28 +8,38 @@ void osDestroyThread(OSThread *thread) { int_disabled = __osDisableInt(); if (thread == NULL) { - thread = D_803348A0; + thread = __osRunningThread; } else if (thread->state != OS_STATE_STOPPED) { __osDequeueThread(thread->queue, thread); } - if (D_8033489C == thread) { - D_8033489C = D_8033489C->tlnext; + if (__osActiveQueue == thread) { + __osActiveQueue = __osActiveQueue->tlnext; } else { - s1 = D_8033489C; + s1 = __osActiveQueue; +#ifdef VERSION_CN + while (s1->priority != -1) { + s2 = s1->tlnext; + if (s2 == thread) { + s1->tlnext = thread->tlnext; + break; + } + s1 = s2; + } +#else s2 = s1->tlnext; while (s2 != NULL) { if (s2 == thread) { s1->tlnext = thread->tlnext; break; - } else { - s1 = s2; - s2 = s1->tlnext; } + s1 = s2; + s2 = s1->tlnext; } +#endif } - if (thread == D_803348A0) { + if (thread == __osRunningThread) { __osDispatchThread(); } diff --git a/lib/src/osEPiRawReadIo.c b/lib/src/osEPiRawReadIo.c new file mode 100644 index 00000000..1f1ab384 --- /dev/null +++ b/lib/src/osEPiRawReadIo.c @@ -0,0 +1,20 @@ +#include "libultra_internal.h" +#include "PR/rcp.h" +#include "piint.h" + +s32 osEPiRawReadIo(OSPiHandle *pihandle, u32 devAddr, u32 *data) { + register s32 stat; +#ifdef VERSION_CN + u32 domain; +#endif + +#ifdef VERSION_CN + EPI_SYNC(pihandle, stat, domain); +#else + WAIT_ON_IO_BUSY(stat); +#endif + + *data = IO_READ(pihandle->baseAddress | devAddr); + + return 0; +} diff --git a/lib/src/osEPiRawStartDma.c b/lib/src/osEPiRawStartDma.c index 0ca8aef9..610b8583 100644 --- a/lib/src/osEPiRawStartDma.c +++ b/lib/src/osEPiRawStartDma.c @@ -1,61 +1,131 @@ #include "libultra_internal.h" -#include "hardware.h" +#include "PR/rcp.h" +#include "PR/ique.h" #include "new_func.h" #include "PR/R4300.h" -// TODO: This define is from piint.h, but including that causes problems... -#define UPDATE_REG(reg, var) \ - if (cHandle->var != pihandle->var) \ - IO_WRITE(reg, pihandle->var); +#include "piint.h" + // TODO: This define is from os.h, but including that causes problems... #define PI_DOMAIN1 0 -// TODO: These defines are from PR/rcp.h, but including that causes problems... -#define IO_WRITE(addr, data) (*(vu32 *) PHYS_TO_K1(addr) = (u32)(data)) -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) extern OSPiHandle *__osCurrentHandle[2]; #endif -s32 osEPiRawStartDma(OSPiHandle *pihandle, s32 dir, u32 cart_addr, void *dram_addr, u32 size) { -#ifdef VERSION_SH +s32 osEPiRawStartDma(OSPiHandle *pihandle, s32 dir, u32 devAddr, void *dram_addr, u32 size) { +#ifdef VERSION_CN + u64 dummyBuf[2]; + u32 status; + u32 domain; + u32 buf; + u32 mask; + u16 *tmp; + u32 i; + u32 end; +#elif defined(VERSION_SH) u32 status; u32 domain; #else - register int status; + register u32 status; #endif - status = HW_REG(PI_STATUS_REG, u32); - while (status & PI_STATUS_ERROR) - status = HW_REG(PI_STATUS_REG, u32); -#ifdef VERSION_SH // TODO: This is the EPI_SYNC macro - domain = pihandle->domain; - if (__osCurrentHandle[domain] != pihandle) { - OSPiHandle *cHandle = __osCurrentHandle[domain]; - if (domain == PI_DOMAIN1) { - UPDATE_REG(PI_BSD_DOM1_LAT_REG, latency); - UPDATE_REG(PI_BSD_DOM1_PGS_REG, pageSize); - UPDATE_REG(PI_BSD_DOM1_RLS_REG, relDuration); - UPDATE_REG(PI_BSD_DOM1_PWD_REG, pulse); - } else { - UPDATE_REG(PI_BSD_DOM2_LAT_REG, latency); - UPDATE_REG(PI_BSD_DOM2_PGS_REG, pageSize); - UPDATE_REG(PI_BSD_DOM2_RLS_REG, relDuration); - UPDATE_REG(PI_BSD_DOM2_PWD_REG, pulse); +#if defined(VERSION_SH) || defined(VERSION_CN) + EPI_SYNC(pihandle, status, domain); +#else + WAIT_ON_IO_BUSY(status); +#endif + +#ifdef VERSION_CN + if (dir == OS_READ) { + mask = 1; + + for (i = 1; i <= pihandle->pageSize + 2; i++) { + mask *= 2; + } + + if ((devAddr & (mask - 1)) == mask - 2) { + osEPiRawReadIo(pihandle, devAddr - 2, &buf); + + tmp = (u16 *) PHYS_TO_K1(dram_addr); + *(tmp++) = (u16) buf; + + devAddr += 2; + dram_addr = tmp; + size -= 2; + + if (size >= 4) { + osEPiRawReadIo(pihandle, devAddr, &buf); + + tmp = (u16 *) dram_addr; + *(tmp++) = buf >> 16; + *(tmp++) = (u16) buf; + + devAddr += 4; + dram_addr = tmp; + size -= 4; + + if (size != 0) { + osEPiRawReadIo(pihandle, devAddr, &buf); + + tmp = (u16 *) PHYS_TO_K1(dram_addr); + *(tmp++) = buf >> 16; + + devAddr += 2; + dram_addr = tmp; + size -= 2; + } + } + } + + end = devAddr + size; + + if (((end & (mask - 1)) == 2) | (size == 2)) { + if (end & 2) { + osEPiRawReadIo(pihandle, end - 2, &buf); + tmp = (u16 *) PHYS_TO_K1(dram_addr) + (size - 2) / 2; + *tmp = buf >> 16; + } else { + osEPiRawReadIo(pihandle, end - 4, &buf); + tmp = (u16 *) PHYS_TO_K1(dram_addr) + (size - 2) / 2; + *tmp = (u16) buf; + } + + size -= 2; + } + + if (size == 0) { + size = 8; + dram_addr = dummyBuf; + devAddr = 0; } - __osCurrentHandle[domain] = pihandle; } #endif - HW_REG(PI_DRAM_ADDR_REG, void *) = (void *) osVirtualToPhysical(dram_addr); - HW_REG(PI_CART_ADDR_REG, void *) = (void *) (((uintptr_t) pihandle->baseAddress | cart_addr) & 0x1fffffff); + IO_WRITE(PI_DRAM_ADDR_REG, osVirtualToPhysical(dram_addr)); + IO_WRITE(PI_CART_ADDR_REG, K1_TO_PHYS(pihandle->baseAddress | devAddr)); + +#ifdef VERSION_CN + if ((u32) dir >= 2U) { + return -1; + } + + if ((pihandle->baseAddress | devAddr) <= 0x400) { + IO_WRITE(dir == OS_READ ? PI_EX_WR_LEN_REG : PI_EX_RD_LEN_REG, size - 1); + } else { + IO_WRITE(dir == OS_READ ? PI_WR_LEN_REG : PI_RD_LEN_REG, size - 1); + } +#else switch (dir) { case OS_READ: - HW_REG(PI_WR_LEN_REG, u32) = size - 1; + IO_WRITE(PI_WR_LEN_REG, size - 1); break; case OS_WRITE: - HW_REG(PI_RD_LEN_REG, u32) = size - 1; + IO_WRITE(PI_RD_LEN_REG, size - 1); break; default: return -1; } +#endif return 0; } + diff --git a/lib/src/osEPiRawWriteIo.c b/lib/src/osEPiRawWriteIo.c new file mode 100644 index 00000000..1f67b70e --- /dev/null +++ b/lib/src/osEPiRawWriteIo.c @@ -0,0 +1,20 @@ +#include "libultra_internal.h" +#include "PR/rcp.h" +#include "piint.h" + +s32 osEPiRawWriteIo(OSPiHandle *pihandle, u32 devAddr, u32 data) { + register u32 stat; +#ifdef VERSION_CN + u32 domain; +#endif + +#ifdef VERSION_CN + EPI_SYNC(pihandle, stat, domain); +#else + WAIT_ON_IO_BUSY(stat); +#endif + + IO_WRITE(pihandle->baseAddress | devAddr, data); + + return 0; +} diff --git a/lib/src/osEepromLongRead.c b/lib/src/osEepromLongRead.c index 3260d138..628690dc 100644 --- a/lib/src/osEepromLongRead.c +++ b/lib/src/osEepromLongRead.c @@ -1,17 +1,14 @@ #include "libultra_internal.h" +#include "controller.h" -extern u64 osClockRate; -extern u8 D_80365D20; -extern u8 _osContNumControllers; -extern OSTimer D_80365D28; // not sure what this is yet -extern OSMesgQueue _osContMesgQueue; -extern OSMesg _osContMesgBuff[4]; - -s32 osEepromLongRead(OSMesgQueue *mq, u8 address, u8 *buffer, int nbytes) { +s32 osEepromLongRead(OSMesgQueue *mq, u8 address, u8 *buffer, s32 nbytes) { s32 status = 0; + +#ifndef VERSION_CN if (address > 0x40) { return -1; } +#endif while (nbytes > 0) { status = osEepromRead(mq, address, buffer); @@ -19,11 +16,13 @@ s32 osEepromLongRead(OSMesgQueue *mq, u8 address, u8 *buffer, int nbytes) { return status; } - nbytes -= 8; + nbytes -= EEPROM_BLOCK_SIZE; address++; - buffer += 8; - osSetTimer(&D_80365D28, 12000 * osClockRate / 1000000, 0, &_osContMesgQueue, _osContMesgBuff); - osRecvMesg(&_osContMesgQueue, NULL, OS_MESG_BLOCK); + buffer += EEPROM_BLOCK_SIZE; +#ifndef VERSION_CN + osSetTimer(&__osEepromTimer, 12000 * osClockRate / 1000000, 0, &__osEepromTimerQ, __osEepromTimerMsg); + osRecvMesg(&__osEepromTimerQ, NULL, OS_MESG_BLOCK); +#endif } return status; diff --git a/lib/src/osEepromLongWrite.c b/lib/src/osEepromLongWrite.c index 69d367e3..97ae82d9 100644 --- a/lib/src/osEepromLongWrite.c +++ b/lib/src/osEepromLongWrite.c @@ -1,18 +1,19 @@ #include "libultra_internal.h" +#include "controller.h" -extern u64 osClockRate; -extern u8 D_80365D20; -extern u8 _osContNumControllers; -extern OSTimer D_80365D28; -extern OSMesgQueue _osContMesgQueue; -extern OSMesg _osContMesgBuff[4]; -// exactly the same as osEepromLongRead except for osEepromWrite call +#ifdef VERSION_CN +#define CLOCK_RATE (62500000ULL * 3 / 4) +#else +#define CLOCK_RATE osClockRate +#endif s32 osEepromLongWrite(OSMesgQueue *mq, u8 address, u8 *buffer, int nbytes) { s32 result = 0; +#ifndef VERSION_CN if (address > 0x40) { return -1; } +#endif while (nbytes > 0) { result = osEepromWrite(mq, address, buffer); @@ -20,11 +21,11 @@ s32 osEepromLongWrite(OSMesgQueue *mq, u8 address, u8 *buffer, int nbytes) { return result; } - nbytes -= 8; + nbytes -= EEPROM_BLOCK_SIZE; address++; - buffer += 8; - osSetTimer(&D_80365D28, 12000 * osClockRate / 1000000, 0, &_osContMesgQueue, _osContMesgBuff); - osRecvMesg(&_osContMesgQueue, NULL, OS_MESG_BLOCK); + buffer += EEPROM_BLOCK_SIZE; + osSetTimer(&__osEepromTimer, 12000 * CLOCK_RATE / 1000000, 0, &__osEepromTimerQ, __osEepromTimerMsg); + osRecvMesg(&__osEepromTimerQ, NULL, OS_MESG_BLOCK); } return result; diff --git a/lib/src/osEepromProbe.c b/lib/src/osEepromProbe.c index d550b846..5924906e 100644 --- a/lib/src/osEepromProbe.c +++ b/lib/src/osEepromProbe.c @@ -1,24 +1,26 @@ +#include "macros.h" #include "libultra_internal.h" -// TODO: merge with osEepromWrite -typedef struct { - u16 unk00; - u8 unk02; - u8 unk03; -} unkStruct; +extern u32 __osBbEepromSize; -s32 __osEepStatus(OSMesgQueue *, unkStruct *); -s32 osEepromProbe(OSMesgQueue *mq) { - s32 status = 0; - unkStruct sp18; +s32 __osEepStatus(OSMesgQueue *, OSContStatus *); +s32 osEepromProbe(UNUSED OSMesgQueue *mq) { + s32 ret = 0; +#ifndef VERSION_CN + OSContStatus status; +#endif __osSiGetAccess(); - status = __osEepStatus(mq, &sp18); - if (status == 0 && (sp18.unk00 & 0x8000) != 0) { - status = 1; - } else { - status = 0; +#ifdef VERSION_CN + if (__osBbEepromSize == 0x200) { + ret = EEPROM_TYPE_4K; + } else if (__osBbEepromSize == 0x800) { + ret = EEPROM_TYPE_16K; } +#else + ret = __osEepStatus(mq, &status); + ret = (ret == 0 && (status.type & CONT_EEPROM) != 0) ? EEPROM_TYPE_4K : 0; +#endif __osSiRelAccess(); - return status; + return ret; } diff --git a/lib/src/osEepromRead.c b/lib/src/osEepromRead.c index 7f3a0292..26de2b62 100644 --- a/lib/src/osEepromRead.c +++ b/lib/src/osEepromRead.c @@ -1,102 +1,115 @@ #include "libultra_internal.h" +#include "PR/ique.h" +#include "controller.h" +#include "macros.h" -extern u8 _osLastSentSiCmd; +#ifdef VERSION_CN -typedef struct { - u16 unk00; - u8 unk02; - u8 unk03; -} unkStruct; -typedef struct { - u8 unk00; - u8 unk01; - u8 unk02; - u8 unk03; - u8 unk04; - u8 unk05; - u8 unk06; - u8 unk07; -} unkStruct3; +s32 osEepromRead(UNUSED OSMesgQueue *mq, u8 address, u8 *buffer) { + s32 ret = 0; + s32 i; -typedef struct { - u8 unk00; - u8 unk01; - u8 unk02; - u8 unk03; - unkStruct3 unk04; -} unkStruct2; - -s32 __osEepStatus(OSMesgQueue *, unkStruct *); -s32 __osPackEepReadData(u8); - -s32 osEepromRead(OSMesgQueue *mq, u8 address, u8 *buffer) { - s32 sp34; - s32 sp30; - u8 *sp2c; - unkStruct sp28; - unkStruct2 sp20; - sp34 = 0; - sp30 = 0; - sp2c = (u8 *) &D_80365E00; - if (address > 0x40) { - return -1; - } __osSiGetAccess(); - sp34 = __osEepStatus(mq, &sp28); - if (sp34 != 0 || sp28.unk00 != 0x8000) { - return 8; + if (__osBbEepromSize == 0x200) { + if (address >= 0x200 / 8) { + ret = -1; + } + } else if (__osBbEepromSize != 0x800) { + ret = 8; } - while (sp28.unk02 & 0x80) { - __osEepStatus(mq, &sp28); - } - __osPackEepReadData(address); - sp34 = __osSiRawStartDma(OS_WRITE, &D_80365E00); - osRecvMesg(mq, NULL, OS_MESG_BLOCK); - for (sp30 = 0; sp30 < 0x10; sp30++) { - (D_80365E00)[sp30] = 255; - } - D_80365E3C = 0; - sp34 = __osSiRawStartDma(OS_READ, D_80365E00); - _osLastSentSiCmd = 4; - osRecvMesg(mq, NULL, OS_MESG_BLOCK); - for (sp30 = 0; sp30 < 4; sp30++) { - sp2c++; - } - sp20 = *(unkStruct2 *) sp2c; - sp34 = (sp20.unk01 & 0xc0) >> 4; - if (sp34 == 0) { - for (sp30 = 0; sp30 < 8; sp30++) { - *buffer++ = ((u8 *) &sp20.unk04)[sp30]; + + if (ret == 0) { + for (i = 0; i < 8; i++) { + buffer[i] = (__osBbEepromAddress + address * 8)[i]; } } + __osSiRelAccess(); - return sp34; + return ret; } -s32 __osPackEepReadData(u8 address) { - u8 *sp14; - unkStruct2 sp8; - s32 sp4; - sp14 = (u8 *) &D_80365E00; - for (sp4 = 0; sp4 < 0x10; sp4++) { - D_80365E00[sp4] = 255; +#else + +void __osPackEepReadData(u8); + +s32 osEepromRead(OSMesgQueue *mq, u8 address, u8 *buffer) { + s32 ret = 0; + s32 i = 0; + u8 *ptr = (u8 *) &__osEepPifRam.ramarray; + OSContStatus sdata; + __OSContEepromFormat eepromformat; + + if (address > EEPROM_MAXBLOCKS) { + return -1; } - D_80365E3C = 1; - sp8.unk00 = 2; - sp8.unk01 = 8; - sp8.unk02 = 4; - sp8.unk03 = address; - for (sp4 = 0; sp4 < 8; sp4++) { - ((u8 *) &sp8.unk04)[sp4] = 0; + + __osSiGetAccess(); + ret = __osEepStatus(mq, &sdata); + if (ret != 0 || sdata.type != CONT_EEPROM) { + + return CONT_NO_RESPONSE_ERROR; } - for (sp4 = 0; sp4 < 4; sp4++) { - *sp14++ = 0; + + while (sdata.status & CONT_EEPROM_BUSY) { + __osEepStatus(mq, &sdata); } - *(unkStruct2 *) sp14 = sp8; - sp14 += 0xc; - *sp14 = 254; -#ifdef AVOID_UB - return 0; -#endif + __osPackEepReadData(address); + + ret = __osSiRawStartDma(OS_WRITE, &__osEepPifRam); + osRecvMesg(mq, NULL, OS_MESG_BLOCK); + + for (i = 0; i < ARRAY_COUNT(__osEepPifRam.ramarray) + 1; i++) { + __osEepPifRam.ramarray[i] = CONT_CMD_NOP; + } + __osEepPifRam.pifstatus = 0; + + ret = __osSiRawStartDma(OS_READ, &__osEepPifRam); + __osContLastCmd = CONT_CMD_READ_EEPROM; + osRecvMesg(mq, NULL, OS_MESG_BLOCK); + + for (i = 0; i < 4; i++) { + ptr++; + } + + eepromformat = *(__OSContEepromFormat *) ptr; + ret = CHNL_ERR(eepromformat); + + if (ret == 0) { + for (i = 0; i < 8; i++) { + *buffer++ = eepromformat.data[i]; + } + } + + __osSiRelAccess(); + return ret; } + +void __osPackEepReadData(u8 address) { + u8 *ptr = (u8 *) &__osEepPifRam.ramarray; + __OSContEepromFormat eepromformat; + s32 i; + + for (i = 0; i < ARRAY_COUNT(__osEepPifRam.ramarray) + 1; i++) { + __osEepPifRam.ramarray[i] = CONT_CMD_NOP; + } + __osEepPifRam.pifstatus = CONT_CMD_EXE; + + eepromformat.txsize = CONT_CMD_READ_EEPROM_TX; + eepromformat.rxsize = CONT_CMD_READ_EEPROM_RX; + eepromformat.cmd = CONT_CMD_READ_EEPROM; + eepromformat.address = address; + for (i = 0; i < ARRAY_COUNT(eepromformat.data); i++) { + eepromformat.data[i] = 0; + } + + for (i = 0; i < 4; i++) { + *ptr++ = 0; + } + + *(__OSContEepromFormat *) ptr = eepromformat; + ptr += sizeof(__OSContEepromFormat); + *ptr = CONT_CMD_END; +} + +#endif diff --git a/lib/src/osEepromWrite.c b/lib/src/osEepromWrite.c index 67c42a59..68069b1b 100644 --- a/lib/src/osEepromWrite.c +++ b/lib/src/osEepromWrite.c @@ -1,170 +1,168 @@ #include "libultra_internal.h" #include "osContInternal.h" +#include "PR/ique.h" +#include "controller.h" +#include "macros.h" + +#ifdef VERSION_CN + +s32 osEepromWrite(UNUSED OSMesgQueue *mq, u8 address, u8 *buffer) { + s32 ret = 0; + s32 i; + + __osSiGetAccess(); + + if (__osBbEepromSize == 0x200) { + if (address >= 0x200 / 8) { + ret = -1; + } + } else if (__osBbEepromSize != 0x800) { + ret = 8; + } + + if (ret == 0) { + for (i = 0; i < 8; i++) { + (__osBbEepromAddress + address * 8)[i] = buffer[i]; + } + } + + __osSiRelAccess(); + return ret; +} -#ifndef AVOID_UB -ALIGNED8 u32 D_80365E00[15]; -u32 D_80365E3C; #else -// Certain code accesses the 16th element (D_80365E3C) in this array, making a seperate -// definition UB when gcc rearranges those. -ALIGNED8 u32 D_80365E00[16]; -#endif -extern u8 _osLastSentSiCmd; -typedef struct { - u16 unk00; - u8 unk02; - u8 unk03; -} unkStruct; -typedef struct { - u8 unk00; - u8 unk01; - u8 unk02; - u8 unk03; - u8 unk04; - u8 unk05; - u8 unk06; - u8 unk07; -} unkStruct3; +OSPifRam __osEepPifRam; -typedef struct { - u8 unk00; - u8 unk01; - u8 unk02; - u8 unk03; - unkStruct3 unk04; -} unkStruct2; - -s32 __osEepStatus(OSMesgQueue *, unkStruct *); -s32 __osPackEepWriteData(u8, u8 *); +void __osPackEepWriteData(u8, u8 *); s32 osEepromWrite(OSMesgQueue *mq, u8 address, u8 *buffer) { - s32 sp34; - s32 sp30; - u8 *sp2c; - unkStruct2 sp20; - unkStruct sp1c; - sp34 = 0; - sp2c = (u8 *) &D_80365E00; + s32 ret = 0; + s32 i; + u8 *ptr = (u8 *) &__osEepPifRam.ramarray; + __OSContEepromFormat eepromformat; + OSContStatus sdata; - if (address > 0x40) { + if (address > EEPROM_MAXBLOCKS) { return -1; } __osSiGetAccess(); - sp34 = __osEepStatus(mq, &sp1c); + ret = __osEepStatus(mq, &sdata); - if (sp34 != 0 || sp1c.unk00 != 0x8000) { - return 8; + if (ret != 0 || sdata.type != CONT_EEPROM) { + return CONT_NO_RESPONSE_ERROR; } - while (sp1c.unk02 & 0x80) { - __osEepStatus(mq, &sp1c); + while (sdata.status & CONT_EEPROM_BUSY) { + __osEepStatus(mq, &sdata); } __osPackEepWriteData(address, buffer); - sp34 = __osSiRawStartDma(OS_WRITE, &D_80365E00); + ret = __osSiRawStartDma(OS_WRITE, &__osEepPifRam); osRecvMesg(mq, NULL, OS_MESG_BLOCK); - for (sp30 = 0; sp30 < 0x10; sp30++) { - (D_80365E00)[sp30] = 255; + for (i = 0; i < ARRAY_COUNT(__osEepPifRam.ramarray) + 1; i++) { + __osEepPifRam.ramarray[i] = CONT_CMD_NOP; } - D_80365E3C = 0; - sp34 = __osSiRawStartDma(OS_READ, D_80365E00); - _osLastSentSiCmd = 5; + __osEepPifRam.pifstatus = 0; + ret = __osSiRawStartDma(OS_READ, &__osEepPifRam); + __osContLastCmd = CONT_CMD_WRITE_EEPROM; osRecvMesg(mq, NULL, OS_MESG_BLOCK); - for (sp30 = 0; sp30 < 4; sp30++) { - sp2c++; + for (i = 0; i < 4; i++) { + ptr++; } - sp20 = *(unkStruct2 *) sp2c; - sp34 = (sp20.unk01 & 0xc0) >> 4; + eepromformat = *(__OSContEepromFormat *) ptr; + ret = CHNL_ERR(eepromformat); __osSiRelAccess(); - return sp34; + return ret; } -s32 __osPackEepWriteData(u8 address, u8 *buffer) { - u8 *sp14; - unkStruct2 sp8; - s32 sp4; - sp14 = (u8 *) &D_80365E00; - for (sp4 = 0; sp4 < 0x10; sp4++) { - D_80365E00[sp4] = 255; +void __osPackEepWriteData(u8 address, u8 *buffer) { + u8 *ptr = (u8 *) &__osEepPifRam.ramarray; + __OSContEepromFormat eepromformat; + s32 i; + + for (i = 0; i < ARRAY_COUNT(__osEepPifRam.ramarray) + 1; i++) { + __osEepPifRam.ramarray[i] = CONT_CMD_NOP; } - D_80365E3C = 1; - sp8.unk00 = 10; - sp8.unk01 = 1; - sp8.unk02 = 5; - sp8.unk03 = address; - for (sp4 = 0; sp4 < 8; sp4++) { - ((u8 *) &sp8.unk04)[sp4] = *buffer++; + __osEepPifRam.pifstatus = CONT_CMD_EXE; + + eepromformat.txsize = CONT_CMD_WRITE_EEPROM_TX; + eepromformat.rxsize = CONT_CMD_WRITE_EEPROM_RX; + eepromformat.cmd = CONT_CMD_WRITE_EEPROM; + eepromformat.address = address; + + for (i = 0; i < ARRAY_COUNT(eepromformat.data); i++) { + eepromformat.data[i] = *buffer++; } - for (sp4 = 0; sp4 < 4; sp4++) { - *sp14++ = 0; + + for (i = 0; i < 4; i++) { + *ptr++ = 0; + } + *(__OSContEepromFormat *) ptr = eepromformat; + ptr += sizeof(__OSContEepromFormat); + *ptr = CONT_CMD_END; +} + +s32 __osEepStatus(OSMesgQueue *mq, OSContStatus *data) { + u32 ret = 0; + s32 i; + u8 *ptr = (u8 *) __osEepPifRam.ramarray; + __OSContRequesFormat requestformat; + + for (i = 0; i < ARRAY_COUNT(__osEepPifRam.ramarray) + 1; i++) { + __osEepPifRam.ramarray[i] = 0; + } + __osEepPifRam.pifstatus = CONT_CMD_EXE; + + ptr = (u8 *) __osEepPifRam.ramarray; + for (i = 0; i < 4; i++) { + *ptr++ = 0; + } + + requestformat.dummy = CONT_CMD_NOP; + requestformat.txsize = CONT_CMD_REQUEST_STATUS_TX; + requestformat.rxsize = CONT_CMD_REQUEST_STATUS_RX; + requestformat.cmd = CONT_CMD_REQUEST_STATUS; + requestformat.typeh = CONT_CMD_NOP; + requestformat.typel = CONT_CMD_NOP; + requestformat.status = CONT_CMD_NOP; + requestformat.dummy1 = CONT_CMD_NOP; + *(__OSContRequesFormat *) ptr = requestformat; + + ptr += sizeof(__OSContRequesFormat); + *ptr = CONT_CMD_END; + + ret = __osSiRawStartDma(OS_WRITE, &__osEepPifRam); + osRecvMesg(mq, NULL, OS_MESG_BLOCK); + + __osContLastCmd = CONT_CMD_WRITE_EEPROM; + + ret = __osSiRawStartDma(OS_READ, &__osEepPifRam); + osRecvMesg(mq, NULL, OS_MESG_BLOCK); + + if (ret != 0) { + return ret; + } + + ptr = (u8 *) __osEepPifRam.ramarray; + for (i = 0; i < 4; i++) { + *ptr++ = 0; + } + + requestformat = *(__OSContRequesFormat *) ptr; + data->errnum = CHNL_ERR(requestformat); + data->type = (requestformat.typel << 8) | requestformat.typeh; + data->status = requestformat.status; + if (data->errnum != 0) { + return data->errnum; } - *(unkStruct2 *) sp14 = sp8; - sp14 += 0xc; - *sp14 = 254; -#ifdef AVOID_UB return 0; +} + #endif -} - -s32 __osEepStatus(OSMesgQueue *a0, unkStruct *a1) { - u32 sp2c = 0; - s32 sp28; - u8 *sp24 = (u8 *) D_80365E00; - unkStruct3 sp1c; - - for (sp28 = 0; sp28 < 0x10; sp28++) { - D_80365E00[sp28] = 0; - } - - D_80365E3C = 1; - sp24 = (u8 *) D_80365E00; - for (sp28 = 0; sp28 < 4; sp28++) { - *sp24++ = 0; - } - - sp1c.unk00 = 255; - sp1c.unk01 = 1; - sp1c.unk02 = 3; - sp1c.unk03 = 0; - sp1c.unk04 = 255; - sp1c.unk05 = 255; - sp1c.unk06 = 255; - sp1c.unk07 = 255; - *(unkStruct3 *) sp24 = sp1c; - - sp24 += 8; - sp24[0] = 254; - - sp2c = __osSiRawStartDma(OS_WRITE, D_80365E00); - osRecvMesg(a0, NULL, OS_MESG_BLOCK); - - _osLastSentSiCmd = 5; - - sp2c = __osSiRawStartDma(OS_READ, D_80365E00); - osRecvMesg(a0, NULL, OS_MESG_BLOCK); - - if (sp2c != 0) { - return sp2c; - } - - sp24 = (u8 *) D_80365E00; - for (sp28 = 0; sp28 < 4; sp28++) { - *sp24++ = 0; - } - - sp1c = *(unkStruct3 *) sp24; - a1->unk03 = (sp1c.unk02 & 0xc0) >> 4; - a1->unk00 = (sp1c.unk05 << 8) | sp1c.unk04; - a1->unk02 = sp1c.unk06; - if (a1->unk03 != 0) { - return a1->unk03; - } - return 0; -} diff --git a/lib/src/osGetThreadPri.c b/lib/src/osGetThreadPri.c index 7b5b58c4..43a0145b 100644 --- a/lib/src/osGetThreadPri.c +++ b/lib/src/osGetThreadPri.c @@ -2,7 +2,7 @@ OSPri osGetThreadPri(OSThread *thread) { if (thread == NULL) { - thread = D_803348A0; + thread = __osRunningThread; } return thread->priority; } diff --git a/lib/src/osInitialize.c b/lib/src/osInitialize.c index ba73024b..33c182df 100644 --- a/lib/src/osInitialize.c +++ b/lib/src/osInitialize.c @@ -1,101 +1,182 @@ #include "libultra_internal.h" -#include "hardware.h" +#include "PR/R4300.h" +#include "piint.h" +#include "PR/rcp.h" +#include "PR/ique.h" #include -#define PIF_ADDR_START (void *) 0x1FC007FC - typedef struct { - u32 instr00; - u32 instr01; - u32 instr02; - u32 instr03; -} exceptionPreamble; + u32 inst1; + u32 inst2; + u32 inst3; + u32 inst4; +} __osExceptionVector; +extern __osExceptionVector __osExceptionPreamble; -#if defined(VERSION_EU) || defined(VERSION_SH) -extern u32 EU_D_802f4330(u32, void (*)); -extern void D_802F4380(); - -#endif -u32 D_80365CD0; // maybe initialized? -u64 osClockRate = 62500000; - -#ifdef VERSION_SH -u32 osViClock = 0x02E6D354; +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) +extern u32 __osSetHWintrRoutine(OSHWIntr, s32 (*)); +extern s32 __osLeoInterrupt(void); #endif -u32 D_80334808 = 0; // used in __osException +u32 __osFinalrom; // maybe initialized? +u64 osClockRate = OS_CLOCK_RATE; -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_SH) || defined(VERSION_CN) +u32 osViClock = VI_NTSC_CLOCK; +#endif + +u32 __osShutdown = 0; // used in __osException + +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) u32 EU_D_80336C40; u32 EU_D_80336C44; u32 __OSGlobalIntMask = OS_IM_ALL; -u32 EU_D_80302090 = 0; +u32 osDDActive = 0; u8 EU_unusedZeroes[8] = { 0 }; #endif -#define EXCEPTION_TLB_MISS 0x80000000 -#define EXCEPTION_XTLB_MISS 0x80000080 -#define EXCEPTION_CACHE_ERROR 0x80000100 -#define EXCEPTION_GENERAL 0x80000180 -extern u32 osResetType; -extern exceptionPreamble __osExceptionPreamble; +#ifdef VERSION_CN -void osInitialize(void) { - u32 sp34; - u32 sp30 = 0; +void __createSpeedParam(void) { + __Dom1SpeedParam.type = DEVICE_TYPE_INIT; + __Dom1SpeedParam.latency = IO_READ(PI_BSD_DOM1_LAT_REG); + __Dom1SpeedParam.pulse = IO_READ(PI_BSD_DOM1_PWD_REG); + __Dom1SpeedParam.pageSize = IO_READ(PI_BSD_DOM1_PGS_REG); + __Dom1SpeedParam.relDuration = IO_READ(PI_BSD_DOM1_RLS_REG); -#if defined(VERSION_EU) - UNUSED u32 eu_sp34; - UNUSED u32 eu_sp30; + __Dom2SpeedParam.type = DEVICE_TYPE_INIT; + __Dom2SpeedParam.latency = IO_READ(PI_BSD_DOM2_LAT_REG); + __Dom2SpeedParam.pulse = IO_READ(PI_BSD_DOM2_PWD_REG); + __Dom2SpeedParam.pageSize = IO_READ(PI_BSD_DOM2_PGS_REG); + __Dom2SpeedParam.relDuration = IO_READ(PI_BSD_DOM2_RLS_REG); +} #endif - UNUSED u32 sp2c; - D_80365CD0 = TRUE; - __osSetSR(__osGetSR() | 0x20000000); - __osSetFpcCsr(0x01000800); - while (__osSiRawReadIo(PIF_ADDR_START, &sp34)) { - ; + +#ifdef VERSION_CN +void __osInitialize_common(void) +#else +void osInitialize(void) +#endif +{ + u32 pifdata; +#ifndef VERSION_CN + u32 clock = 0; +#endif +#ifdef VERSION_CN + u32 intrMask1, intrMask2; +#endif + +#ifdef VERSION_EU + u32 leoStatus; + u32 status; +#endif + + UNUSED u32 ptr; + + __osFinalrom = TRUE; + __osSetSR(__osGetSR() | SR_CU1); + __osSetFpcCsr(FPCSR_FS | FPCSR_EV); +#ifdef VERSION_CN + __osSetWatchLo(0x4900000); + intrMask1 = IO_WRITE(MI_HW_INTR_MASK_REG, 0x22000); + intrMask2 = IO_WRITE(MI_HW_INTR_MASK_REG, 0x11000); + __osBbIsBb = (intrMask1 & 0x140) == 0x140 && (intrMask2 & 0x140) == 0 ? 1 : 0; + if (__osBbIsBb != 0 && (IO_READ(PI_MISC_REG) & 0xC0000000) != 0) { + __osBbIsBb = 2; } - while (__osSiRawWriteIo(PIF_ADDR_START, sp34 | 8)) { - ; + if (__osBbIsBb != 0) { + osTvType = TV_TYPE_NTSC; + osRomType = DEVICE_TYPE_CART; + osResetType = RESET_TYPE_COLD_RESET; + osVersion = 1; + osMemSize = 4 * 1024 * 1024; } - *(exceptionPreamble *) EXCEPTION_TLB_MISS = __osExceptionPreamble; - *(exceptionPreamble *) EXCEPTION_XTLB_MISS = __osExceptionPreamble; - *(exceptionPreamble *) EXCEPTION_CACHE_ERROR = __osExceptionPreamble; - *(exceptionPreamble *) EXCEPTION_GENERAL = __osExceptionPreamble; - osWritebackDCache((void *) 0x80000000, - EXCEPTION_GENERAL + sizeof(exceptionPreamble) - EXCEPTION_TLB_MISS); - osInvalICache((void *) 0x80000000, - EXCEPTION_GENERAL + sizeof(exceptionPreamble) - EXCEPTION_TLB_MISS); + if (__osBbIsBb == 0) { +#endif + while (__osSiRawReadIo(PIF_RAM_END - 3, &pifdata)) { + ; + } + while (__osSiRawWriteIo(PIF_RAM_END - 3, pifdata | 8)) { + ; + } +#ifdef VERSION_CN + } +#endif + *(__osExceptionVector *) UT_VEC = __osExceptionPreamble; + *(__osExceptionVector *) XUT_VEC = __osExceptionPreamble; + *(__osExceptionVector *) ECC_VEC = __osExceptionPreamble; + *(__osExceptionVector *) E_VEC = __osExceptionPreamble; + osWritebackDCache((void *) UT_VEC, E_VEC - UT_VEC + sizeof(__osExceptionVector)); + osInvalICache((void *) UT_VEC, E_VEC - UT_VEC + sizeof(__osExceptionVector)); +#ifdef VERSION_CN + __createSpeedParam(); + osUnmapTLBAll(); +#endif osMapTLBRdb(); - osPiRawReadIo(4, &sp30); - sp30 &= ~0xf; - if (sp30) { - osClockRate = sp30; +#ifndef VERSION_CN + osPiRawReadIo(4, &clock); + clock &= ~0xf; + if (clock) { + osClockRate = clock; } +#endif osClockRate = osClockRate * 3 / 4; if (osResetType == RESET_TYPE_COLD_RESET) { bzero(osAppNmiBuffer, sizeof(osAppNmiBuffer)); } -#if defined(VERSION_SH) +#if defined(VERSION_SH) || defined(VERSION_CN) if (osTvType == TV_TYPE_PAL) { - osViClock = 0x02F5B2D2; + osViClock = VI_PAL_CLOCK; } else if (osTvType == TV_TYPE_MPAL) { - osViClock = 0x02E6025C; + osViClock = VI_MPAL_CLOCK; } else { - osViClock = 0x02E6D354; + osViClock = VI_NTSC_CLOCK; } #elif defined(VERSION_EU) - eu_sp30 = HW_REG(PI_STATUS_REG, u32); - while (eu_sp30 & PI_STATUS_ERROR) { - eu_sp30 = HW_REG(PI_STATUS_REG, u32); - }; - if (!((eu_sp34 = HW_REG(ASIC_STATUS, u32)) & _64DD_PRESENT_MASK)) { - EU_D_80302090 = 1; - EU_D_802f4330(1, D_802F4380); + WAIT_ON_IO_BUSY(status); + + if (!((leoStatus = IO_READ(LEO_STATUS)) & LEO_STATUS_PRESENCE_MASK)) { + osDDActive = 1; + __osSetHWIntrRoutine(1, __osLeoInterrupt); } else { - EU_D_80302090 = 0; + osDDActive = 0; } #endif + +#ifdef VERSION_CN + if (__osGetCause() & 0x1000) { + while (TRUE) { + } + } + if (__osBbIsBb == 0) { + __osBbEepromSize = 0x200; + __osBbPakSize = 0x8000; + __osBbFlashSize = 0x20000; + __osBbEepromAddress = (u8 *) 0x803FFE00; + __osBbPakAddress[0] = (u32 *) 0x803F7E00; + __osBbPakAddress[1] = NULL; + __osBbPakAddress[2] = NULL; + __osBbPakAddress[3] = NULL; + __osBbFlashAddress = 0x803E0000; + __osBbSramSize = __osBbFlashSize; + __osBbSramAddress = __osBbFlashAddress; + } + if (__osBbIsBb != 0) { + IO_WRITE(PI_BASE_REG+0x64, IO_READ(PI_BASE_REG+0x64) & 0x7FFFFFFF); + IO_WRITE(MI_HW_INTR_MASK_REG, 0x20000); + IO_WRITE(SI_BASE_REG+0x0C, 0); // a "reserved" register + IO_WRITE(SI_BASE_REG+0x1C, (IO_READ(SI_BASE_REG+0x1C) & 0x80FFFFFF) | 0x2F400000); + } + + IO_WRITE(AI_CONTROL_REG, 1); + IO_WRITE(AI_DACRATE_REG, 0x3fff); + IO_WRITE(AI_BITRATE_REG, 0xf); +#endif } + +#ifdef VERSION_CN +void __osInitialize_autodetect(void) { +} +#endif diff --git a/lib/src/osInitializeIQueWrapper.c b/lib/src/osInitializeIQueWrapper.c new file mode 100644 index 00000000..a65157da --- /dev/null +++ b/lib/src/osInitializeIQueWrapper.c @@ -0,0 +1,21 @@ +#include "ultra64.h" +#include "PR/os.h" + +#ifdef VERSION_CN +s32 osMotorStart(OSPfs *pfs) { + return __osMotorAccess(pfs, MOTOR_START); +} + +s32 osMotorStop(OSPfs *pfs) { + return __osMotorAccess(pfs, MOTOR_STOP); +} + +static void osInitializeWrapper(void) { + __osInitialize_common(); + __osInitialize_autodetect(); +} + +void osInitialize(void) { + osInitializeWrapper(); +} +#endif diff --git a/lib/src/osJamMesg.c b/lib/src/osJamMesg.c index 72513135..a4b5e8ff 100644 --- a/lib/src/osJamMesg.c +++ b/lib/src/osJamMesg.c @@ -3,9 +3,9 @@ s32 osJamMesg(OSMesgQueue *mq, OSMesg msg, s32 flag) { register s32 int_disabled; int_disabled = __osDisableInt(); - while (mq->validCount >= mq->msgCount) { + while (MQ_IS_FULL(mq)) { if (flag == OS_MESG_BLOCK) { - D_803348A0->state = OS_STATE_WAITING; + __osRunningThread->state = OS_STATE_WAITING; __osEnqueueAndYield(&mq->fullqueue); } else { __osRestoreInt(int_disabled); diff --git a/lib/src/osLeoDiskInit.c b/lib/src/osLeoDiskInit.c index 066aab8a..32176cee 100644 --- a/lib/src/osLeoDiskInit.c +++ b/lib/src/osLeoDiskInit.c @@ -1,34 +1,31 @@ #include "libultra_internal.h" -#include "hardware.h" +#include "PR/rcp.h" +#include "PR/os.h" -// this file must include some globally referenced data because it is not called anywhere -// data, comes shortly before _Ldtob I think, before crash_screen - -extern OSPiHandle *__osPiTable; -// bss -OSPiHandle LeoDiskHandle; +OSPiHandle __Dom2SpeedParam; OSPiHandle *__osDiskHandle; OSPiHandle *osLeoDiskInit(void) { - s32 sp1c; - LeoDiskHandle.type = 2; - LeoDiskHandle.baseAddress = (0xa0000000 | 0x05000000); - LeoDiskHandle.latency = 3; - LeoDiskHandle.pulse = 6; - LeoDiskHandle.pageSize = 6; - LeoDiskHandle.relDuration = 2; + s32 saveMask; + + __Dom2SpeedParam.type = DEVICE_TYPE_64DD; + __Dom2SpeedParam.baseAddress = PHYS_TO_K1(PI_DOM2_ADDR1); + __Dom2SpeedParam.latency = 3; + __Dom2SpeedParam.pulse = 6; + __Dom2SpeedParam.pageSize = 6; + __Dom2SpeedParam.relDuration = 2; #ifdef VERSION_SH - LeoDiskHandle.domain = 1; + __Dom2SpeedParam.domain = 1; #endif - HW_REG(PI_BSD_DOM2_LAT_REG, u32) = LeoDiskHandle.latency; - HW_REG(PI_BSD_DOM2_PWD_REG, u32) = LeoDiskHandle.pulse; - HW_REG(PI_BSD_DOM2_PGS_REG, u32) = LeoDiskHandle.pageSize; - HW_REG(PI_BSD_DOM2_RLS_REG, u32) = LeoDiskHandle.relDuration; - bzero(&LeoDiskHandle.transferInfo, sizeof(__OSTranxInfo)); - sp1c = __osDisableInt(); - LeoDiskHandle.next = __osPiTable; - __osPiTable = &LeoDiskHandle; - __osDiskHandle = &LeoDiskHandle; - __osRestoreInt(sp1c); - return &LeoDiskHandle; + IO_WRITE(PI_BSD_DOM2_LAT_REG, __Dom2SpeedParam.latency); + IO_WRITE(PI_BSD_DOM2_PWD_REG, __Dom2SpeedParam.pulse); + IO_WRITE(PI_BSD_DOM2_PGS_REG, __Dom2SpeedParam.pageSize); + IO_WRITE(PI_BSD_DOM2_RLS_REG, __Dom2SpeedParam.relDuration); + bzero(&__Dom2SpeedParam.transferInfo, sizeof(__OSTranxInfo)); + saveMask = __osDisableInt(); + __Dom2SpeedParam.next = __osPiTable; + __osPiTable = &__Dom2SpeedParam; + __osDiskHandle = &__Dom2SpeedParam; + __osRestoreInt(saveMask); + return &__Dom2SpeedParam; } diff --git a/lib/src/osPfsIsPlug.c b/lib/src/osPfsIsPlug.c index 6165e329..5fc5b8fa 100644 --- a/lib/src/osPfsIsPlug.c +++ b/lib/src/osPfsIsPlug.c @@ -1,6 +1,7 @@ #include "PR/os_pi.h" #include "libultra_internal.h" #include "controller.h" +#include "macros.h" OSPifRam __osPfsPifRam; @@ -23,17 +24,17 @@ s32 osPfsIsPlug(OSMesgQueue *queue, u8 *pattern) { ret = __osSiRawStartDma(OS_READ, &__osPfsPifRam); osRecvMesg(queue, &dummy, OS_MESG_BLOCK); __osPfsGetInitData(&bitpattern, data); - for (channel = 0; channel < _osContNumControllers; channel++) { + for (channel = 0; channel < __osMaxControllers; channel++) { if ((data[channel].status & CONT_ADDR_CRC_ER) == 0) { crc_error_cnt--; break; } } - if (_osContNumControllers == channel) { + if (__osMaxControllers == channel) { crc_error_cnt = 0; } if (crc_error_cnt < 1) { - for (channel = 0; channel < _osContNumControllers; channel++) { + for (channel = 0; channel < __osMaxControllers; channel++) { if (data[channel].errnum == 0 && (data[channel].status & CONT_CARD_ON) != 0) { bits |= 1 << channel; } @@ -50,9 +51,9 @@ void __osPfsRequestData(u8 cmd) { __OSContRequesFormat requestformat; int i; - _osLastSentSiCmd = cmd; + __osContLastCmd = cmd; - for (i = 0; i < ARRLEN(__osPfsPifRam.ramarray) + 1; i++) { // also clear pifstatus + for (i = 0; i < ARRAY_COUNT(__osPfsPifRam.ramarray) + 1; i++) { // also clear pifstatus __osPfsPifRam.ramarray[i] = 0; } @@ -67,7 +68,7 @@ void __osPfsRequestData(u8 cmd) { requestformat.typel = CONT_CMD_NOP; requestformat.status = CONT_CMD_NOP; requestformat.dummy1 = CONT_CMD_NOP; - for (i = 0; i < _osContNumControllers; i++) { + for (i = 0; i < __osMaxControllers; i++) { *(__OSContRequesFormat *)ptr = requestformat; ptr += sizeof(__OSContRequesFormat); } @@ -81,7 +82,7 @@ void __osPfsGetInitData(u8 *pattern, OSContStatus *data) { u8 bits; bits = 0; ptr = (u8 *)&__osPfsPifRam; - for (i = 0; i < _osContNumControllers; i++, ptr += sizeof(__OSContRequesFormat)) { + for (i = 0; i < __osMaxControllers; i++, ptr += sizeof(__OSContRequesFormat)) { requestformat = *(__OSContRequesFormat *)ptr; data->errnum = CHNL_ERR(requestformat); if (data->errnum == 0) { diff --git a/lib/src/osPiGetCmdQueue.c b/lib/src/osPiGetCmdQueue.c index 457abc65..ebe4cc6c 100644 --- a/lib/src/osPiGetCmdQueue.c +++ b/lib/src/osPiGetCmdQueue.c @@ -1,9 +1,8 @@ #include "libultra_internal.h" - -extern OSMgrArgs __osPiDevMgr; +#include "piint.h" OSMesgQueue *osPiGetCmdQueue(void) { - if (!__osPiDevMgr.initialized) { + if (!__osPiDevMgr.active) { return NULL; } return __osPiDevMgr.cmdQueue; diff --git a/lib/src/osPiRawReadIo.c b/lib/src/osPiRawReadIo.c index 07270788..a212d7a8 100644 --- a/lib/src/osPiRawReadIo.c +++ b/lib/src/osPiRawReadIo.c @@ -1,14 +1,11 @@ #include "libultra_internal.h" -#include "hardware.h" +#include "PR/rcp.h" +#include "piint.h" -extern u32 osRomBase; +s32 osPiRawReadIo(u32 devAddr, u32 *data) { + register u32 status; -s32 osPiRawReadIo(u32 a0, u32 *a1) { - register int status; - status = HW_REG(PI_STATUS_REG, u32); - while (status & (PI_STATUS_BUSY | PI_STATUS_IOBUSY | PI_STATUS_ERROR)) { - status = HW_REG(PI_STATUS_REG, u32); - } - *a1 = HW_REG(osRomBase | a0, u32); + WAIT_ON_IO_BUSY(status); + *data = IO_READ(osRomBase | devAddr); return 0; } diff --git a/lib/src/osPiRawStartDma.c b/lib/src/osPiRawStartDma.c index ca6044e6..347d1dac 100644 --- a/lib/src/osPiRawStartDma.c +++ b/lib/src/osPiRawStartDma.c @@ -1,56 +1,25 @@ #include "libultra_internal.h" -#include "hardware.h" - -extern u32 osRomBase; // TODO: figure out why this is like this +#include "PR/rcp.h" +#include "piint.h" s32 osPiRawStartDma(s32 dir, u32 cart_addr, void *dram_addr, size_t size) { - register int status; - status = HW_REG(PI_STATUS_REG, u32); - while (status & (PI_STATUS_BUSY | PI_STATUS_IOBUSY | PI_STATUS_ERROR)) { - status = HW_REG(PI_STATUS_REG, u32); - } + register u32 status; - HW_REG(PI_DRAM_ADDR_REG, void *) = (void *) osVirtualToPhysical(dram_addr); + WAIT_ON_IO_BUSY(status); - HW_REG(PI_CART_ADDR_REG, void *) = (void *) (((uintptr_t) osRomBase | cart_addr) & 0x1fffffff); + IO_WRITE(PI_DRAM_ADDR_REG, osVirtualToPhysical(dram_addr)); + + IO_WRITE(PI_CART_ADDR_REG, K1_TO_PHYS((uintptr_t) osRomBase | cart_addr)); switch (dir) { - case 0: - HW_REG(PI_WR_LEN_REG, u32) = size - 1; + case OS_READ: + IO_WRITE(PI_WR_LEN_REG, size - 1); break; - case 1: - HW_REG(PI_RD_LEN_REG, u32) = size - 1; + case OS_WRITE: + IO_WRITE(PI_RD_LEN_REG, size - 1); break; default: return -1; - break; } return 0; } - -#ifdef VERSION_EU -/*s32 osPiRawStartDma_2(s32 dir, u32 cart_addr, void *dram_addr, size_t size) { - register int status; - status = HW_REG(PI_STATUS_REG, u32); - while (status & (PI_STATUS_BUSY | PI_STATUS_IOBUSY | PI_STATUS_ERROR)) { - status = HW_REG(PI_STATUS_REG, u32); - } - - HW_REG(PI_DRAM_ADDR_REG, void *) = (void *) osVirtualToPhysical(dram_addr); - - HW_REG(PI_CART_ADDR_REG, void *) = (void *) (((uintptr_t) osRomBase | cart_addr) & 0x1fffffff); - - switch (dir) { - case 0: - HW_REG(PI_WR_LEN_REG, u32) = size - 1; - break; - case 1: - HW_REG(PI_RD_LEN_REG, u32) = size - 1; - break; - default: - return -1; - break; - } - return 0; -}*/ -#endif diff --git a/lib/src/osPiStartDma.c b/lib/src/osPiStartDma.c index f71d9e23..0a07d530 100644 --- a/lib/src/osPiStartDma.c +++ b/lib/src/osPiStartDma.c @@ -1,12 +1,11 @@ #include "libultra_internal.h" - -extern OSMgrArgs __osPiDevMgr; +#include "piint.h" s32 osPiStartDma(OSIoMesg *mb, s32 priority, s32 direction, uintptr_t devAddr, void *vAddr, size_t nbytes, OSMesgQueue *mq) { register s32 result; register OSMesgQueue *cmdQueue; - if (!__osPiDevMgr.initialized) { + if (!__osPiDevMgr.active) { return -1; } @@ -22,7 +21,7 @@ s32 osPiStartDma(OSIoMesg *mb, s32 priority, s32 direction, uintptr_t devAddr, v mb->dramAddr = vAddr; mb->devAddr = devAddr; mb->size = nbytes; -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) mb->piHandle = NULL; #endif diff --git a/lib/src/osRecvMesg.c b/lib/src/osRecvMesg.c index 057ec9f0..db68e2cc 100644 --- a/lib/src/osRecvMesg.c +++ b/lib/src/osRecvMesg.c @@ -2,16 +2,16 @@ s32 osRecvMesg(OSMesgQueue *mq, OSMesg *msg, s32 flag) { register u32 int_disabled; - register OSThread *thread; int_disabled = __osDisableInt(); while (!mq->validCount) { if (!flag) { __osRestoreInt(int_disabled); return -1; + } else { + __osRunningThread->state = OS_STATE_WAITING; + __osEnqueueAndYield(&mq->mtqueue); } - D_803348A0->state = OS_STATE_WAITING; - __osEnqueueAndYield(&mq->mtqueue); } if (msg != NULL) { @@ -22,8 +22,7 @@ s32 osRecvMesg(OSMesgQueue *mq, OSMesg *msg, s32 flag) { mq->validCount--; if (mq->fullqueue->next != NULL) { - thread = __osPopThread(&mq->fullqueue); - osStartThread(thread); + osStartThread(__osPopThread(&mq->fullqueue)); } __osRestoreInt(int_disabled); diff --git a/lib/src/osSendMesg.c b/lib/src/osSendMesg.c index f0d02fff..596ca729 100644 --- a/lib/src/osSendMesg.c +++ b/lib/src/osSendMesg.c @@ -3,12 +3,11 @@ s32 osSendMesg(OSMesgQueue *mq, OSMesg msg, s32 flag) { register u32 int_disabled; register s32 index; - register OSThread *s2; int_disabled = __osDisableInt(); - while (mq->validCount >= mq->msgCount) { + while (MQ_IS_FULL(mq)) { if (flag == OS_MESG_BLOCK) { - D_803348A0->state = 8; + __osRunningThread->state = 8; __osEnqueueAndYield(&mq->fullqueue); } else { __osRestoreInt(int_disabled); @@ -21,8 +20,7 @@ s32 osSendMesg(OSMesgQueue *mq, OSMesg msg, s32 flag) { mq->validCount++; if (mq->mtqueue->next != NULL) { - s2 = __osPopThread(&mq->mtqueue); - osStartThread(s2); + osStartThread(__osPopThread(&mq->mtqueue)); } __osRestoreInt(int_disabled); diff --git a/lib/src/osSetEventMesg.c b/lib/src/osSetEventMesg.c index 4610b4b1..3c50487a 100644 --- a/lib/src/osSetEventMesg.c +++ b/lib/src/osSetEventMesg.c @@ -1,18 +1,30 @@ #include "libultra_internal.h" +#include "osint.h" -typedef struct OSEventMessageStruct_0_s { - OSMesgQueue *queue; - OSMesg msg; -} OSEventMessageStruct_0; +__OSEventState __osEventStateTab[OS_NUM_EVENTS]; -OSEventMessageStruct_0 __osEventStateTab[16]; +#ifdef VERSION_CN +u32 __osPreNMI = 0; +#endif void osSetEventMesg(OSEvent e, OSMesgQueue *mq, OSMesg msg) { register u32 int_disabled; - OSEventMessageStruct_0 *msgs; + __OSEventState *msgs; int_disabled = __osDisableInt(); + msgs = __osEventStateTab + e; - msgs->queue = mq; - msgs->msg = msg; + msgs->messageQueue = mq; + msgs->message = msg; + +#ifdef VERSION_CN + if (e == OS_EVENT_PRENMI) { + if (__osShutdown && !__osPreNMI) { + osSendMesg(mq, msg, OS_MESG_NOBLOCK); + } + + __osPreNMI = TRUE; + } +#endif + __osRestoreInt(int_disabled); } diff --git a/lib/src/osSetThreadPri.c b/lib/src/osSetThreadPri.c index 1c782534..84a9a4c1 100644 --- a/lib/src/osSetThreadPri.c +++ b/lib/src/osSetThreadPri.c @@ -3,20 +3,20 @@ void osSetThreadPri(OSThread *thread, OSPri pri) { register u32 int_disabled = __osDisableInt(); if (thread == NULL) { - thread = D_803348A0; + thread = __osRunningThread; } if (thread->priority != pri) { thread->priority = pri; - if (thread != D_803348A0) { + if (thread != __osRunningThread) { if (thread->state != OS_STATE_STOPPED) { __osDequeueThread(thread->queue, thread); __osEnqueueThread(thread->queue, thread); } } - if (D_803348A0->priority < D_80334898->priority) { - D_803348A0->state = OS_STATE_RUNNABLE; - __osEnqueueAndYield(&D_80334898); + if (__osRunningThread->priority < __osRunQueue->priority) { + __osRunningThread->state = OS_STATE_RUNNABLE; + __osEnqueueAndYield(&__osRunQueue); } } diff --git a/lib/src/osSetTimer.c b/lib/src/osSetTimer.c index fc1258cf..54dcc3aa 100644 --- a/lib/src/osSetTimer.c +++ b/lib/src/osSetTimer.c @@ -1,23 +1,49 @@ #include "libultra_internal.h" +#include "osint.h" -extern OSTimer *__osTimerList; -extern u64 __osInsertTimer(OSTimer *); +#pragma GCC diagnostic ignored "-Wunused-but-set-variable" -u32 osSetTimer(OSTimer *t, OSTime countdown, OSTime interval, OSMesgQueue *mq, OSMesg msg) { +u32 osSetTimer(OSTimer *timer, OSTime countdown, OSTime interval, OSMesgQueue *mq, OSMesg msg) { OSTime time; - t->next = NULL; - t->prev = NULL; - t->interval = interval; - if (countdown != 0) { - t->remaining = countdown; +#ifdef VERSION_CN + OSTimer *next; + u32 count; + u32 remaining; + u32 prevInt; +#endif + + timer->next = NULL; + timer->prev = NULL; + timer->interval = interval; + timer->remaining = countdown != 0 ? countdown : interval; + timer->mq = mq; + timer->msg = msg; + +#ifdef VERSION_CN + prevInt = __osDisableInt(); + if (__osTimerList->next == __osTimerList) { } else { - t->remaining = interval; + next = __osTimerList->next; + count = osGetCount(); + remaining = count - __osTimerCounter; + + if (remaining < next->remaining) { + next->remaining -= remaining; + } else { + next->remaining = 1; + } } - t->mq = mq; - t->msg = msg; - time = __osInsertTimer(t); - if (__osTimerList->next == t) { + + time = __osInsertTimer(timer); + __osSetTimerIntr(__osTimerList->next->remaining); + + __osRestoreInt(prevInt); +#else + time = __osInsertTimer(timer); + if (__osTimerList->next == timer) { __osSetTimerIntr(time); } +#endif + return 0; } diff --git a/lib/src/osSpTaskLoadGo.c b/lib/src/osSpTaskLoadGo.c index 2843b442..6adb6cf9 100644 --- a/lib/src/osSpTaskLoadGo.c +++ b/lib/src/osSpTaskLoadGo.c @@ -1,5 +1,5 @@ #include "libultra_internal.h" -#include "hardware.h" +#include "PR/rcp.h" #include #define _osVirtualToPhysical(ptr) \ @@ -7,10 +7,11 @@ ptr = (void *) osVirtualToPhysical(ptr); \ } -OSTask D_803638B0; +FORCE_BSS OSTask tmpTask; + OSTask *_VirtualToPhysicalTask(OSTask *task) { OSTask *physicalTask; - physicalTask = &D_803638B0; + physicalTask = &tmpTask; bcopy(task, physicalTask, sizeof(OSTask)); _osVirtualToPhysical(physicalTask->t.ucode); _osVirtualToPhysical(physicalTask->t.ucode_data); @@ -29,9 +30,9 @@ void osSpTaskLoad(OSTask *task) { physicalTask->t.ucode_data = physicalTask->t.yield_data_ptr; physicalTask->t.ucode_data_size = physicalTask->t.yield_data_size; task->t.flags &= ~M_TASK_FLAG0; -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) if (physicalTask->t.flags & M_TASK_FLAG2) { - physicalTask->t.ucode = (u64*)HW_REG((uintptr_t)task->t.yield_data_ptr + 0xBFC, u64*); + physicalTask->t.ucode = (u64 *) IO_READ((uintptr_t)task->t.yield_data_ptr + 0xBFC); } #endif } diff --git a/lib/src/osSpTaskYielded.c b/lib/src/osSpTaskYielded.c index fa0dcbc2..67616950 100644 --- a/lib/src/osSpTaskYielded.c +++ b/lib/src/osSpTaskYielded.c @@ -4,11 +4,7 @@ OSYieldResult osSpTaskYielded(OSTask *task) { s32 status; u32 int_disabledult; status = __osSpGetStatus(); - if (status & SPSTATUS_SIGNAL1_SET) { - int_disabledult = 1; - } else { - int_disabledult = 0; - } + int_disabledult = (status & SPSTATUS_SIGNAL1_SET) != 0 ? 1 : 0; if (status & SPSTATUS_SIGNAL0_SET) { task->t.flags |= int_disabledult; task->t.flags &= ~(M_TASK_FLAG1); diff --git a/lib/src/osStartThread.c b/lib/src/osStartThread.c index c241e388..af51060e 100644 --- a/lib/src/osStartThread.c +++ b/lib/src/osStartThread.c @@ -2,36 +2,34 @@ void osStartThread(OSThread *thread) { register u32 int_disabled; - register uintptr_t state; int_disabled = __osDisableInt(); - state = thread->state; - if (state != OS_STATE_STOPPED) { - if (state == OS_STATE_WAITING) { - do { - } while (0); - thread->state = OS_STATE_RUNNABLE; - __osEnqueueThread(&D_80334898, thread); - } - } else { - if (thread->queue == NULL || thread->queue == &D_80334898) { + switch (thread->state) { + case OS_STATE_WAITING: thread->state = OS_STATE_RUNNABLE; + __osEnqueueThread(&__osRunQueue, thread); + break; + case OS_STATE_STOPPED: + if (thread->queue == NULL || thread->queue == &__osRunQueue) { + thread->state = OS_STATE_RUNNABLE; - __osEnqueueThread(&D_80334898, thread); - } else { - thread->state = OS_STATE_WAITING; - __osEnqueueThread(thread->queue, thread); - state = (uintptr_t) __osPopThread(thread->queue); - __osEnqueueThread(&D_80334898, (OSThread *) state); - } + __osEnqueueThread(&__osRunQueue, thread); + } else { + thread->state = OS_STATE_WAITING; + __osEnqueueThread(thread->queue, thread); + __osEnqueueThread(&__osRunQueue, __osPopThread(thread->queue)); + } + break; } - if (D_803348A0 == NULL) { + + if (__osRunningThread == NULL) { __osDispatchThread(); } else { - if (D_803348A0->priority < D_80334898->priority) { - D_803348A0->state = OS_STATE_RUNNABLE; - __osEnqueueAndYield(&D_80334898); + if (__osRunningThread->priority < __osRunQueue->priority) { + __osRunningThread->state = OS_STATE_RUNNABLE; + __osEnqueueAndYield(&__osRunQueue); } } + __osRestoreInt(int_disabled); } diff --git a/lib/src/osSyncPrintf.c b/lib/src/osSyncPrintf.c new file mode 100644 index 00000000..f9a89861 --- /dev/null +++ b/lib/src/osSyncPrintf.c @@ -0,0 +1,11 @@ +#include "macros.h" + +#ifdef VERSION_CN + +// ? +void func_cn_80304B30(void) {} + +void osSyncPrintf(UNUSED const char *fmt, ...) {} +void osAsyncPrintf(UNUSED const char *fmt, ...) {} + +#endif diff --git a/lib/src/osTimer.c b/lib/src/osTimer.c index 2c13925b..a9dbbc20 100644 --- a/lib/src/osTimer.c +++ b/lib/src/osTimer.c @@ -11,10 +11,8 @@ void __osTimerServicesInit(void) { __osCurrentTime = 0; __osBaseCounter = 0; __osViIntrCount = 0; - __osTimerList->prev = __osTimerList; - __osTimerList->next = __osTimerList->prev; - __osTimerList->remaining = 0; - __osTimerList->interval = __osTimerList->remaining; + __osTimerList->next = __osTimerList->prev = __osTimerList; + __osTimerList->interval = __osTimerList->remaining = 0; __osTimerList->mq = NULL; __osTimerList->msg = NULL; } @@ -28,7 +26,7 @@ void __osTimerInterrupt(void) { return; } - while (TRUE) { + for (;;) { t = __osTimerList->next; if (t == __osTimerList) { __osSetCompare(0); @@ -41,28 +39,33 @@ void __osTimerInterrupt(void) { if (elapsedCycles < t->remaining) { t->remaining -= elapsedCycles; __osSetTimerIntr(t->remaining); - return; - } else { - t->prev->next = t->next; - t->next->prev = t->prev; - t->next = NULL; - t->prev = NULL; - if (t->mq != NULL) { - osSendMesg(t->mq, t->msg, OS_MESG_NOBLOCK); - } - if (t->interval != 0) { - t->remaining = t->interval; - __osInsertTimer(t); - } + break; + } + t->prev->next = t->next; + t->next->prev = t->prev; + t->next = NULL; + t->prev = NULL; + if (t->mq != NULL) { + osSendMesg(t->mq, t->msg, OS_MESG_NOBLOCK); + } + if (t->interval != 0) { + t->remaining = t->interval; + __osInsertTimer(t); } } } void __osSetTimerIntr(OSTime time) { OSTime newTime; - s32 savedMask = __osDisableInt(); + s32 savedMask; +#ifdef VERSION_CN + if (time < 468) { + time = 468; + } +#endif + savedMask = __osDisableInt(); __osTimerCounter = osGetCount(); - newTime = time + __osTimerCounter; + newTime = __osTimerCounter + time; __osSetCompare(newTime); __osRestoreInt(savedMask); } diff --git a/lib/src/osViData.c b/lib/src/osViData.c index 6f392106..42923b54 100644 --- a/lib/src/osViData.c +++ b/lib/src/osViData.c @@ -1,7 +1,85 @@ #include "libultra_internal.h" -#if defined(VERSION_EU) || defined(VERSION_SH) -OSViMode D_80334990 = { +#ifdef VERSION_CN + +OSViMode osViModeNtscLan1 = { + /*type*/ 2, + /*comRegs*/ + { /*ctrl*/ 4382, + /*width*/ 320, + /*burst*/ 65348153, + /*vSync*/ 525, + /*hSync*/ 3093, + /*leap*/ 202705941, + /*hStart*/ 7078636, + /*xScale*/ 512, + /*vCurrent*/ 0 }, + /*fldRegs*/ + { { /*origin*/ 640, + /*yScale*/ 1024, + /*vStart*/ 2425343, + /*vBurst*/ 918020, + /*vIntr*/ 2 }, + { /*origin*/ 640, + /*yScale*/ 1024, + /*vStart*/ 2425343, + /*vBurst*/ 918020, + /*vIntr*/ 2 } } +}; + +OSViMode osViModePalLan1 = { + /*type*/ 16, + /*comRegs*/ + { /*ctrl*/ 4382, + /*width*/ 320, + /*burst*/ 72621626, + /*vSync*/ 625, + /*hSync*/ 1510505, + /*leap*/ 208604269, + /*hStart*/ 8389376, + /*xScale*/ 512, + /*vCurrent*/ 0 }, + /*fldRegs*/ + { { /*origin*/ 640, + /*yScale*/ 1024, + /*vStart*/ 6226489, + /*vBurst*/ 590443, + /*vIntr*/ 2 }, + { /*origin*/ 640, + /*yScale*/ 1024, + /*vStart*/ 6226489, + /*vBurst*/ 590443, + /*vIntr*/ 2 } } +}; + +OSViMode osViModeMpalLan1 = { + /*type*/ 30, + /*comRegs*/ + { /*ctrl*/ 4382, + /*width*/ 320, + /*burst*/ 73735737, + /*vSync*/ 525, + /*hSync*/ 265233, + /*leap*/ 202968090, + /*hStart*/ 7078636, + /*xScale*/ 512, + /*vCurrent*/ 0 }, + /*fldRegs*/ + { { /*origin*/ 640, + /*yScale*/ 1024, + /*vStart*/ 2425343, + /*vBurst*/ 918020, + /*vIntr*/ 2 }, + { /*origin*/ 640, + /*yScale*/ 1024, + /*vStart*/ 2425343, + /*vBurst*/ 918020, + /*vIntr*/ 2 } } +}; + +#elif defined(VERSION_EU) || defined(VERSION_SH) + +OSViMode osViModePalLan1 = { /*type*/ 16, /*comRegs*/ { /*ctrl*/ 12574, @@ -35,7 +113,7 @@ OSViMode D_80334990 = { /*vIntr*/ 2 } } }; -OSViMode D_803349E0 = { +OSViMode osViModeMpalLan1 = { /*type*/ 30, //osViModePalLan1 /*comRegs*/ { /*ctrl*/ 12574, @@ -60,32 +138,7 @@ OSViMode D_803349E0 = { /*vIntr*/ 2 } } }; -OSViMode D_80302FD0 = { - /*type*/ 2, - /*comRegs*/ - { /*ctrl*/ 12574, - /*width*/ 320, - /*burst*/ 65348153, - /*vSync*/ 525, - /*hSync*/ 3093, - /*leap*/ 202705941, - /*hStart*/ 7078636, - /*xScale*/ 512, - /*vCurrent*/ 0 }, - /*fldRegs*/ - { { /*origin*/ 640, - /*yScale*/ 1024, - /*vStart*/ 2425343, - /*vBurst*/ 918020, - /*vIntr*/ 2 }, - { /*origin*/ 640, - /*yScale*/ 1024, - /*vStart*/ 2425343, - /*vBurst*/ 918020, - /*vIntr*/ 2 } } -}; -#else -OSViMode D_80334990 = { +OSViMode osViModeNtscLan1 = { /*type*/ 2, /*comRegs*/ { /*ctrl*/ 12574, @@ -110,7 +163,34 @@ OSViMode D_80334990 = { /*vIntr*/ 2 } } }; -OSViMode D_803349E0 = { +#else + +OSViMode osViModePalLan1 = { + /*type*/ 2, + /*comRegs*/ + { /*ctrl*/ 12574, + /*width*/ 320, + /*burst*/ 65348153, + /*vSync*/ 525, + /*hSync*/ 3093, + /*leap*/ 202705941, + /*hStart*/ 7078636, + /*xScale*/ 512, + /*vCurrent*/ 0 }, + /*fldRegs*/ + { { /*origin*/ 640, + /*yScale*/ 1024, + /*vStart*/ 2425343, + /*vBurst*/ 918020, + /*vIntr*/ 2 }, + { /*origin*/ 640, + /*yScale*/ 1024, + /*vStart*/ 2425343, + /*vBurst*/ 918020, + /*vIntr*/ 2 } } +}; + +OSViMode osViModeMpalLan1 = { /*type*/ 16, /*comRegs*/ { /*ctrl*/ 12574, diff --git a/lib/src/osViSetMode.c b/lib/src/osViSetMode.c index 716596fb..1820f257 100644 --- a/lib/src/osViSetMode.c +++ b/lib/src/osViSetMode.c @@ -1,9 +1,16 @@ #include "libultra_internal.h" +extern u32 __osBbIsBb; + extern OSViContext *__osViNext; void osViSetMode(OSViMode *mode) { register u32 int_disabled = __osDisableInt(); +#ifdef VERSION_CN + if (__osBbIsBb != 0) { + mode->comRegs.ctrl &= ~0x2000; + } +#endif __osViNext->modep = mode; __osViNext->unk00 = 1; __osViNext->features = __osViNext->modep->comRegs.ctrl; diff --git a/lib/src/osViTable.c b/lib/src/osViTable.c index 424f7cca..553f0e9f 100644 --- a/lib/src/osViTable.c +++ b/lib/src/osViTable.c @@ -1,10 +1,26 @@ #include "libultra_internal.h" +#if defined(VERSION_SH) || defined(VERSION_CN) +#define COMMON_BURST 72621626 +#define COMMON_HSYNC 1510505 +#define COMMON_LEAP 208604269 +#else +#define COMMON_BURST 67380026 +#define COMMON_HSYNC 1379433 +#define COMMON_LEAP 208604270 +#endif + +#ifdef VERSION_CN +#define CN_SUB 8192 +#else +#define CN_SUB 0 +#endif + OSViMode osViModeTable[] = { /*osViModeNtscLpn1*/ { /*type*/ 0, /*comRegs*/ - { /*ctrl*/ 12814, + { /*ctrl*/ 12814 - CN_SUB, /*width*/ 320, /*burst*/ 65348153, /*vSync*/ 525, @@ -27,7 +43,7 @@ OSViMode osViModeTable[] = { /*osViModeNtscLpf1*/ { /*type*/ 1, /*comRegs*/ - { /*ctrl*/ 12878, + { /*ctrl*/ 12878 - CN_SUB, /*width*/ 320, /*burst*/ 65348153, /*vSync*/ 524, @@ -50,7 +66,7 @@ OSViMode osViModeTable[] = { /*osViModeNtscLan1*/ { /*type*/ 2, /*comRegs*/ - { /*ctrl*/ 12574, + { /*ctrl*/ 12574 - CN_SUB, /*width*/ 320, /*burst*/ 65348153, /*vSync*/ 525, @@ -73,7 +89,7 @@ OSViMode osViModeTable[] = { /*osViModeNtscLaf1*/ { /*type*/ 3, /*comRegs*/ - { /*ctrl*/ 12382, + { /*ctrl*/ 12382 - CN_SUB, /*width*/ 320, /*burst*/ 65348153, /*vSync*/ 524, @@ -96,7 +112,7 @@ OSViMode osViModeTable[] = { /*osViModeNtscLpn2*/ { /*type*/ 4, /*comRegs*/ - { /*ctrl*/ 13071, + { /*ctrl*/ 13071 - CN_SUB, /*width*/ 320, /*burst*/ 65348153, /*vSync*/ 525, @@ -119,7 +135,7 @@ OSViMode osViModeTable[] = { /*osViModeNtscLpf2*/ { /*type*/ 5, /*comRegs*/ - { /*ctrl*/ 12879, + { /*ctrl*/ 12879 - CN_SUB, /*width*/ 320, /*burst*/ 65348153, /*vSync*/ 524, @@ -142,7 +158,7 @@ OSViMode osViModeTable[] = { /*osViModeNtscLan2*/ { /*type*/ 6, /*comRegs*/ - { /*ctrl*/ 12319, + { /*ctrl*/ 12319 - CN_SUB, /*width*/ 320, /*burst*/ 65348153, /*vSync*/ 525, @@ -165,7 +181,7 @@ OSViMode osViModeTable[] = { /*osViModeNtscLaf2*/ { /*type*/ 7, /*comRegs*/ - { /*ctrl*/ 12383, + { /*ctrl*/ 12383 - CN_SUB, /*width*/ 320, /*burst*/ 65348153, /*vSync*/ 524, @@ -188,7 +204,7 @@ OSViMode osViModeTable[] = { /*osViModeNtscHpn1*/ { /*type*/ 8, /*comRegs*/ - { /*ctrl*/ 12878, + { /*ctrl*/ 12878 - CN_SUB, /*width*/ 1280, /*burst*/ 65348153, /*vSync*/ 524, @@ -211,7 +227,7 @@ OSViMode osViModeTable[] = { /*osViModeNtscHpf1*/ { /*type*/ 9, /*comRegs*/ - { /*ctrl*/ 12878, + { /*ctrl*/ 12878 - CN_SUB, /*width*/ 640, /*burst*/ 65348153, /*vSync*/ 524, @@ -234,7 +250,7 @@ OSViMode osViModeTable[] = { /*osViModeNtscHan1*/ { /*type*/ 10, /*comRegs*/ - { /*ctrl*/ 12382, + { /*ctrl*/ 12382 - CN_SUB, /*width*/ 1280, /*burst*/ 65348153, /*vSync*/ 524, @@ -257,7 +273,7 @@ OSViMode osViModeTable[] = { /*osViModeNtscHaf1*/ { /*type*/ 11, /*comRegs*/ - { /*ctrl*/ 12382, + { /*ctrl*/ 12382 - CN_SUB, /*width*/ 640, /*burst*/ 65348153, /*vSync*/ 524, @@ -280,7 +296,7 @@ OSViMode osViModeTable[] = { /*osViModeNtscHpn2*/ { /*type*/ 12, /*comRegs*/ - { /*ctrl*/ 13135, + { /*ctrl*/ 13135 - CN_SUB, /*width*/ 1280, /*burst*/ 65348153, /*vSync*/ 524, @@ -303,7 +319,7 @@ OSViMode osViModeTable[] = { /*osViModeNtscHpf2*/ { /*type*/ 13, /*comRegs*/ - { /*ctrl*/ 12879, + { /*ctrl*/ 12879 - CN_SUB, /*width*/ 640, /*burst*/ 65348153, /*vSync*/ 524, @@ -324,25 +340,16 @@ OSViMode osViModeTable[] = { /*vBurst*/ 918020, /*vIntr*/ 2 } } }, -#if defined(VERSION_JP) || defined(VERSION_EU) || defined(VERSION_SH) +#ifndef VERSION_US /*osViModePalLpn1*/ { /*type*/ 14, /*comRegs*/ - { /*ctrl*/ 12814, + { /*ctrl*/ 12814 - CN_SUB, /*width*/ 320, -#ifdef VERSION_SH - /*burst*/ 72621626, -#else - /*burst*/ 67380026, -#endif + /*burst*/ COMMON_BURST, /*vSync*/ 625, -#ifdef VERSION_SH - /*hSync*/ 1510505, - /*leap*/ 208604269, -#else - /*hSync*/ 1379433, - /*leap*/ 208604270, -#endif + /*hSync*/ COMMON_HSYNC, + /*leap*/ COMMON_LEAP, /*hStart*/ 8389376, /*xScale*/ 512, /*vCurrent*/ 0 }, @@ -360,21 +367,12 @@ OSViMode osViModeTable[] = { /*osViModePalLpf1*/ { /*type*/ 15, /*comRegs*/ - { /*ctrl*/ 12878, + { /*ctrl*/ 12878 - CN_SUB, /*width*/ 320, -#ifdef VERSION_SH - /*burst*/ 72621626, -#else - /*burst*/ 67380026, -#endif + /*burst*/ COMMON_BURST, /*vSync*/ 624, -#ifdef VERSION_SH - /*hSync*/ 1510505, - /*leap*/ 208604269, -#else - /*hSync*/ 1379433, - /*leap*/ 208604270, -#endif + /*hSync*/ COMMON_HSYNC, + /*leap*/ COMMON_LEAP, /*hStart*/ 8389376, /*xScale*/ 512, /*vCurrent*/ 0 }, @@ -392,21 +390,12 @@ OSViMode osViModeTable[] = { /*osViModePalLan1*/ { /*type*/ 16, /*comRegs*/ - { /*ctrl*/ 12574, + { /*ctrl*/ 12574 - CN_SUB, /*width*/ 320, -#ifdef VERSION_SH - /*burst*/ 72621626, -#else - /*burst*/ 67380026, -#endif + /*burst*/ COMMON_BURST, /*vSync*/ 625, -#ifdef VERSION_SH - /*hSync*/ 1510505, - /*leap*/ 208604269, -#else - /*hSync*/ 1379433, - /*leap*/ 208604270, -#endif + /*hSync*/ COMMON_HSYNC, + /*leap*/ COMMON_LEAP, /*hStart*/ 8389376, /*xScale*/ 512, /*vCurrent*/ 0 }, @@ -424,21 +413,12 @@ OSViMode osViModeTable[] = { /*osViModePalLaf1*/ { /*type*/ 17, /*comRegs*/ - { /*ctrl*/ 12382, + { /*ctrl*/ 12382 - CN_SUB, /*width*/ 320, -#ifdef VERSION_SH - /*burst*/ 72621626, -#else - /*burst*/ 67380026, -#endif + /*burst*/ COMMON_BURST, /*vSync*/ 624, -#ifdef VERSION_SH - /*hSync*/ 1510505, - /*leap*/ 208604269, -#else - /*hSync*/ 1379433, - /*leap*/ 208604270, -#endif + /*hSync*/ COMMON_HSYNC, + /*leap*/ COMMON_LEAP, /*hStart*/ 8389376, /*xScale*/ 512, /*vCurrent*/ 0 }, @@ -456,21 +436,12 @@ OSViMode osViModeTable[] = { /*osViModePalLpn2*/ { /*type*/ 18, /*comRegs*/ - { /*ctrl*/ 13071, + { /*ctrl*/ 13071 - CN_SUB, /*width*/ 320, -#ifdef VERSION_SH - /*burst*/ 72621626, -#else - /*burst*/ 67380026, -#endif + /*burst*/ COMMON_BURST, /*vSync*/ 625, -#ifdef VERSION_SH - /*hSync*/ 1510505, - /*leap*/ 208604269, -#else - /*hSync*/ 1379433, - /*leap*/ 208604270, -#endif + /*hSync*/ COMMON_HSYNC, + /*leap*/ COMMON_LEAP, /*hStart*/ 8389376, /*xScale*/ 512, /*vCurrent*/ 0 }, @@ -488,21 +459,12 @@ OSViMode osViModeTable[] = { /*osViModePalLpf2*/ { /*type*/ 19, /*comRegs*/ - { /*ctrl*/ 12879, + { /*ctrl*/ 12879 - CN_SUB, /*width*/ 320, -#ifdef VERSION_SH - /*burst*/ 72621626, -#else - /*burst*/ 67380026, -#endif + /*burst*/ COMMON_BURST, /*vSync*/ 624, -#ifdef VERSION_SH - /*hSync*/ 1510505, - /*leap*/ 208604269, -#else - /*hSync*/ 1379433, - /*leap*/ 208604270, -#endif + /*hSync*/ COMMON_HSYNC, + /*leap*/ COMMON_LEAP, /*hStart*/ 8389376, /*xScale*/ 512, /*vCurrent*/ 0 }, @@ -520,21 +482,12 @@ OSViMode osViModeTable[] = { /*osViModePalLan2*/ { /*type*/ 20, /*comRegs*/ - { /*ctrl*/ 12319, + { /*ctrl*/ 12319 - CN_SUB, /*width*/ 320, -#ifdef VERSION_SH - /*burst*/ 72621626, -#else - /*burst*/ 67380026, -#endif + /*burst*/ COMMON_BURST, /*vSync*/ 625, -#ifdef VERSION_SH - /*hSync*/ 1510505, - /*leap*/ 208604269, -#else - /*hSync*/ 1379433, - /*leap*/ 208604270, -#endif + /*hSync*/ COMMON_HSYNC, + /*leap*/ COMMON_LEAP, /*hStart*/ 8389376, /*xScale*/ 512, /*vCurrent*/ 0 }, @@ -552,21 +505,12 @@ OSViMode osViModeTable[] = { /*osViModePalLaf2*/ { /*type*/ 21, /*comRegs*/ - { /*ctrl*/ 12383, + { /*ctrl*/ 12383 - CN_SUB, /*width*/ 320, -#ifdef VERSION_SH - /*burst*/ 72621626, -#else - /*burst*/ 67380026, -#endif + /*burst*/ COMMON_BURST, /*vSync*/ 624, -#ifdef VERSION_SH - /*hSync*/ 1510505, - /*leap*/ 208604269, -#else - /*hSync*/ 1379433, - /*leap*/ 208604270, -#endif + /*hSync*/ COMMON_HSYNC, + /*leap*/ COMMON_LEAP, /*hStart*/ 8389376, /*xScale*/ 512, /*vCurrent*/ 0 }, @@ -584,21 +528,12 @@ OSViMode osViModeTable[] = { /*osViModePalHpn1*/ { /*type*/ 22, /*comRegs*/ - { /*ctrl*/ 12878, + { /*ctrl*/ 12878 - CN_SUB, /*width*/ 1280, -#ifdef VERSION_SH - /*burst*/ 72621626, -#else - /*burst*/ 67380026, -#endif + /*burst*/ COMMON_BURST, /*vSync*/ 624, -#ifdef VERSION_SH - /*hSync*/ 1510505, - /*leap*/ 208604269, -#else - /*hSync*/ 1379433, - /*leap*/ 208604270, -#endif + /*hSync*/ COMMON_HSYNC, + /*leap*/ COMMON_LEAP, /*hStart*/ 8389376, /*xScale*/ 1024, /*vCurrent*/ 0 }, @@ -616,21 +551,12 @@ OSViMode osViModeTable[] = { /*osViModePalHpf1*/ { /*type*/ 23, /*comRegs*/ - { /*ctrl*/ 12878, + { /*ctrl*/ 12878 - CN_SUB, /*width*/ 640, -#ifdef VERSION_SH - /*burst*/ 72621626, -#else - /*burst*/ 67380026, -#endif + /*burst*/ COMMON_BURST, /*vSync*/ 624, -#ifdef VERSION_SH - /*hSync*/ 1510505, - /*leap*/ 208604269, -#else - /*hSync*/ 1379433, - /*leap*/ 208604270, -#endif + /*hSync*/ COMMON_HSYNC, + /*leap*/ COMMON_LEAP, /*hStart*/ 8389376, /*xScale*/ 1024, /*vCurrent*/ 0 }, @@ -648,21 +574,12 @@ OSViMode osViModeTable[] = { /*osViModePalHan1*/ { /*type*/ 24, /*comRegs*/ - { /*ctrl*/ 12382, + { /*ctrl*/ 12382 - CN_SUB, /*width*/ 1280, -#ifdef VERSION_SH - /*burst*/ 72621626, -#else - /*burst*/ 67380026, -#endif + /*burst*/ COMMON_BURST, /*vSync*/ 624, -#ifdef VERSION_SH - /*hSync*/ 1510505, - /*leap*/ 208604269, -#else - /*hSync*/ 1379433, - /*leap*/ 208604270, -#endif + /*hSync*/ COMMON_HSYNC, + /*leap*/ COMMON_LEAP, /*hStart*/ 8389376, /*xScale*/ 1024, /*vCurrent*/ 0 }, @@ -680,21 +597,12 @@ OSViMode osViModeTable[] = { /*osViModePalHaf1*/ { /*type*/ 25, /*comRegs*/ - { /*ctrl*/ 12382, + { /*ctrl*/ 12382 - CN_SUB, /*width*/ 640, -#ifdef VERSION_SH - /*burst*/ 72621626, -#else - /*burst*/ 67380026, -#endif + /*burst*/ COMMON_BURST, /*vSync*/ 624, -#ifdef VERSION_SH - /*hSync*/ 1510505, - /*leap*/ 208604269, -#else - /*hSync*/ 1379433, - /*leap*/ 208604270, -#endif + /*hSync*/ COMMON_HSYNC, + /*leap*/ COMMON_LEAP, /*hStart*/ 8389376, /*xScale*/ 1024, /*vCurrent*/ 0 }, @@ -712,21 +620,12 @@ OSViMode osViModeTable[] = { /*osViModePalHpn2*/ { /*type*/ 26, /*comRegs*/ - { /*ctrl*/ 13135, + { /*ctrl*/ 13135 - CN_SUB, /*width*/ 1280, -#ifdef VERSION_SH - /*burst*/ 72621626, -#else - /*burst*/ 67380026, -#endif + /*burst*/ COMMON_BURST, /*vSync*/ 624, -#ifdef VERSION_SH - /*hSync*/ 1510505, - /*leap*/ 208604269, -#else - /*hSync*/ 1379433, - /*leap*/ 208604270, -#endif + /*hSync*/ COMMON_HSYNC, + /*leap*/ COMMON_LEAP, /*hStart*/ 8389376, /*xScale*/ 1024, /*vCurrent*/ 0 }, @@ -744,21 +643,12 @@ OSViMode osViModeTable[] = { /*osViModePalHpf2*/ { /*type*/ 27, /*comRegs*/ - { /*ctrl*/ 12879, + { /*ctrl*/ 12879 - CN_SUB, /*width*/ 640, -#ifdef VERSION_SH - /*burst*/ 72621626, -#else - /*burst*/ 67380026, -#endif + /*burst*/ COMMON_BURST, /*vSync*/ 624, -#ifdef VERSION_SH - /*hSync*/ 1510505, - /*leap*/ 208604269, -#else - /*hSync*/ 1379433, - /*leap*/ 208604270, -#endif + /*hSync*/ COMMON_HSYNC, + /*leap*/ COMMON_LEAP, /*hStart*/ 8389376, /*xScale*/ 1024, /*vCurrent*/ 0 }, @@ -774,11 +664,12 @@ OSViMode osViModeTable[] = { /*vBurst*/ 852585, /*vIntr*/ 2 } } }, #endif -#if defined(VERSION_US) || defined(VERSION_EU) || defined (VERSION_SH) + +#ifndef VERSION_JP /*osViModePalLpn1*/ { /*type*/ 28, /*comRegs*/ - { /*ctrl*/ 12814, + { /*ctrl*/ 12814 - CN_SUB, /*width*/ 320, /*burst*/ 73735737, /*vSync*/ 525, @@ -801,7 +692,7 @@ OSViMode osViModeTable[] = { /*osViModePalLpf1*/ { /*type*/ 29, /*comRegs*/ - { /*ctrl*/ 12878, + { /*ctrl*/ 12878 - CN_SUB, /*width*/ 320, /*burst*/ 73735737, /*vSync*/ 524, @@ -824,7 +715,7 @@ OSViMode osViModeTable[] = { /*osViModePalLan1*/ { /*type*/ 30, /*comRegs*/ - { /*ctrl*/ 12574, + { /*ctrl*/ 12574 - CN_SUB, /*width*/ 320, /*burst*/ 73735737, /*vSync*/ 525, @@ -847,7 +738,7 @@ OSViMode osViModeTable[] = { /*osViModePalLaf1*/ { /*type*/ 31, /*comRegs*/ - { /*ctrl*/ 12382, + { /*ctrl*/ 12382 - CN_SUB, /*width*/ 320, /*burst*/ 73735737, /*vSync*/ 524, @@ -870,7 +761,7 @@ OSViMode osViModeTable[] = { /*osViModePalLpn2*/ { /*type*/ 32, /*comRegs*/ - { /*ctrl*/ 13071, + { /*ctrl*/ 13071 - CN_SUB, /*width*/ 320, /*burst*/ 73735737, /*vSync*/ 525, @@ -893,7 +784,7 @@ OSViMode osViModeTable[] = { /*osViModePalLpf2*/ { /*type*/ 33, /*comRegs*/ - { /*ctrl*/ 12879, + { /*ctrl*/ 12879 - CN_SUB, /*width*/ 320, /*burst*/ 73735737, /*vSync*/ 524, @@ -916,7 +807,7 @@ OSViMode osViModeTable[] = { /*osViModePalLan2*/ { /*type*/ 34, /*comRegs*/ - { /*ctrl*/ 12319, + { /*ctrl*/ 12319 - CN_SUB, /*width*/ 320, /*burst*/ 73735737, /*vSync*/ 525, @@ -939,7 +830,7 @@ OSViMode osViModeTable[] = { /*osViModePalLaf2*/ { /*type*/ 35, /*comRegs*/ - { /*ctrl*/ 12383, + { /*ctrl*/ 12383 - CN_SUB, /*width*/ 320, /*burst*/ 73735737, /*vSync*/ 524, @@ -962,7 +853,7 @@ OSViMode osViModeTable[] = { /*osViModePalHpn1*/ { /*type*/ 36, /*comRegs*/ - { /*ctrl*/ 12878, + { /*ctrl*/ 12878 - CN_SUB, /*width*/ 1280, /*burst*/ 73735737, /*vSync*/ 524, @@ -985,7 +876,7 @@ OSViMode osViModeTable[] = { /*osViModePalHpf1*/ { /*type*/ 37, /*comRegs*/ - { /*ctrl*/ 12878, + { /*ctrl*/ 12878 - CN_SUB, /*width*/ 640, /*burst*/ 73735737, /*vSync*/ 524, @@ -1008,7 +899,7 @@ OSViMode osViModeTable[] = { /*osViModePalHan1*/ { /*type*/ 38, /*comRegs*/ - { /*ctrl*/ 12382, + { /*ctrl*/ 12382 - CN_SUB, /*width*/ 1280, /*burst*/ 73735737, /*vSync*/ 524, @@ -1031,7 +922,7 @@ OSViMode osViModeTable[] = { /*osViModePalHaf1*/ { /*type*/ 39, /*comRegs*/ - { /*ctrl*/ 12382, + { /*ctrl*/ 12382 - CN_SUB, /*width*/ 640, /*burst*/ 73735737, /*vSync*/ 524, @@ -1054,7 +945,7 @@ OSViMode osViModeTable[] = { /*osViModePalHpn2*/ { /*type*/ 40, /*comRegs*/ - { /*ctrl*/ 13135, + { /*ctrl*/ 13135 - CN_SUB, /*width*/ 1280, /*burst*/ 73735737, /*vSync*/ 524, @@ -1077,7 +968,7 @@ OSViMode osViModeTable[] = { /*osViModePalHpf2*/ { /*type*/ 41, /*comRegs*/ - { /*ctrl*/ 12879, + { /*ctrl*/ 12879 - CN_SUB, /*width*/ 640, /*burst*/ 73735737, /*vSync*/ 524, @@ -1099,3 +990,7 @@ OSViMode osViModeTable[] = { /*vIntr*/ 2 } } } #endif }; + +#ifdef VERSION_CN +s8 unk_cn_803191c0[] = {0x2A, 0x00, 0x00, 0x00, 0x00, 0x00, 0x12, 0x0E, 0x00, 0x00, 0x01, 0x40, 0x04, 0x54, 0x1E, 0x3A, 0x00, 0x00, 0x02, 0x71, 0x00, 0x17, 0x0C, 0x69, 0x0C, 0x6F, 0x0C, 0x6D, 0x00, 0x80, 0x03, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x80, 0x00, 0x00, 0x04, 0x00, 0x00, 0x2F, 0x02, 0x69, 0x00, 0x09, 0x02, 0x6B, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x02, 0x80, 0x00, 0x00, 0x04, 0x00, 0x00, 0x2F, 0x02, 0x69, 0x00, 0x09, 0x02, 0x6B, 0x00, 0x00, 0x00, 0x02, 0x2B, 0x00, 0x00, 0x00, 0x00, 0x00, 0x12, 0x4E, 0x00, 0x00, 0x01, 0x40, 0x04, 0x54, 0x1E, 0x3A, 0x00, 0x00, 0x02, 0x70, 0x00, 0x17, 0x0C, 0x69, 0x0C, 0x6F, 0x0C, 0x6D, 0x00, 0x80, 0x03, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x80, 0x01, 0x00, 0x04, 0x00, 0x00, 0x2D, 0x02, 0x67, 0x00, 0x09, 0x02, 0x6B, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x02, 0x80, 0x03, 0x00, 0x04, 0x00, 0x00, 0x2F, 0x02, 0x69, 0x00, 0x0D, 0x02, 0x69, 0x00, 0x00, 0x00, 0x02, 0x2C, 0x00, 0x00, 0x00, 0x00, 0x00, 0x11, 0x1E, 0x00, 0x00, 0x01, 0x40, 0x04, 0x54, 0x1E, 0x3A, 0x00, 0x00, 0x02, 0x71, 0x00, 0x17, 0x0C, 0x69, 0x0C, 0x6F, 0x0C, 0x6D, 0x00, 0x80, 0x03, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x80, 0x00, 0x00, 0x04, 0x00, 0x00, 0x2F, 0x02, 0x69, 0x00, 0x09, 0x02, 0x6B, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x02, 0x80, 0x00, 0x00, 0x04, 0x00, 0x00, 0x2F, 0x02, 0x69, 0x00, 0x09, 0x02, 0x6B, 0x00, 0x00, 0x00, 0x02, 0x2D, 0x00, 0x00, 0x00, 0x00, 0x00, 0x10, 0x5E, 0x00, 0x00, 0x01, 0x40, 0x04, 0x54, 0x1E, 0x3A, 0x00, 0x00, 0x02, 0x70, 0x00, 0x17, 0x0C, 0x69, 0x0C, 0x6F, 0x0C, 0x6D, 0x00, 0x80, 0x03, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x80, 0x01, 0x00, 0x04, 0x00, 0x00, 0x2D, 0x02, 0x67, 0x00, 0x09, 0x02, 0x6B, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x02, 0x80, 0x03, 0x00, 0x04, 0x00, 0x00, 0x2F, 0x02, 0x69, 0x00, 0x0D, 0x02, 0x69, 0x00, 0x00, 0x00, 0x02, 0x2E, 0x00, 0x00, 0x00, 0x00, 0x00, 0x13, 0x0F, 0x00, 0x00, 0x01, 0x40, 0x04, 0x54, 0x1E, 0x3A, 0x00, 0x00, 0x02, 0x71, 0x00, 0x17, 0x0C, 0x69, 0x0C, 0x6F, 0x0C, 0x6D, 0x00, 0x80, 0x03, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x05, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x2F, 0x02, 0x69, 0x00, 0x09, 0x02, 0x6B, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x05, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x2F, 0x02, 0x69, 0x00, 0x09, 0x02, 0x6B, 0x00, 0x00, 0x00, 0x02, 0x2F, 0x00, 0x00, 0x00, 0x00, 0x00, 0x12, 0x4F, 0x00, 0x00, 0x01, 0x40, 0x04, 0x54, 0x1E, 0x3A, 0x00, 0x00, 0x02, 0x70, 0x00, 0x17, 0x0C, 0x69, 0x0C, 0x6F, 0x0C, 0x6D, 0x00, 0x80, 0x03, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x05, 0x00, 0x01, 0x00, 0x04, 0x00, 0x00, 0x2D, 0x02, 0x67, 0x00, 0x09, 0x02, 0x6B, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x05, 0x00, 0x03, 0x00, 0x04, 0x00, 0x00, 0x2F, 0x02, 0x69, 0x00, 0x0D, 0x02, 0x69, 0x00, 0x00, 0x00, 0x02, 0x30, 0x00, 0x00, 0x00, 0x00, 0x00, 0x10, 0x1F, 0x00, 0x00, 0x01, 0x40, 0x04, 0x54, 0x1E, 0x3A, 0x00, 0x00, 0x02, 0x71, 0x00, 0x17, 0x0C, 0x69, 0x0C, 0x6F, 0x0C, 0x6D, 0x00, 0x80, 0x03, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x05, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x2F, 0x02, 0x69, 0x00, 0x09, 0x02, 0x6B, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x05, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x2F, 0x02, 0x69, 0x00, 0x09, 0x02, 0x6B, 0x00, 0x00, 0x00, 0x02, 0x31, 0x00, 0x00, 0x00, 0x00, 0x00, 0x10, 0x5F, 0x00, 0x00, 0x01, 0x40, 0x04, 0x54, 0x1E, 0x3A, 0x00, 0x00, 0x02, 0x70, 0x00, 0x17, 0x0C, 0x69, 0x0C, 0x6F, 0x0C, 0x6D, 0x00, 0x80, 0x03, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x05, 0x00, 0x01, 0x00, 0x04, 0x00, 0x00, 0x2D, 0x02, 0x67, 0x00, 0x09, 0x02, 0x6B, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x05, 0x00, 0x03, 0x00, 0x04, 0x00, 0x00, 0x2F, 0x02, 0x69, 0x00, 0x0D, 0x02, 0x69, 0x00, 0x00, 0x00, 0x02, 0x32, 0x00, 0x00, 0x00, 0x00, 0x00, 0x12, 0x4E, 0x00, 0x00, 0x05, 0x00, 0x04, 0x54, 0x1E, 0x3A, 0x00, 0x00, 0x02, 0x70, 0x00, 0x17, 0x0C, 0x69, 0x0C, 0x6F, 0x0C, 0x6D, 0x00, 0x80, 0x03, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x05, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x2D, 0x02, 0x67, 0x00, 0x09, 0x02, 0x6B, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x0A, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x2F, 0x02, 0x69, 0x00, 0x0D, 0x02, 0x69, 0x00, 0x00, 0x00, 0x02, 0x33, 0x00, 0x00, 0x00, 0x00, 0x00, 0x12, 0x4E, 0x00, 0x00, 0x02, 0x80, 0x04, 0x54, 0x1E, 0x3A, 0x00, 0x00, 0x02, 0x70, 0x00, 0x17, 0x0C, 0x69, 0x0C, 0x6F, 0x0C, 0x6D, 0x00, 0x80, 0x03, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x05, 0x00, 0x02, 0x00, 0x08, 0x00, 0x00, 0x2D, 0x02, 0x67, 0x00, 0x09, 0x02, 0x6B, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x0A, 0x00, 0x02, 0x00, 0x08, 0x00, 0x00, 0x2F, 0x02, 0x69, 0x00, 0x0D, 0x02, 0x69, 0x00, 0x00, 0x00, 0x02, 0x34, 0x00, 0x00, 0x00, 0x00, 0x00, 0x10, 0x5E, 0x00, 0x00, 0x05, 0x00, 0x04, 0x54, 0x1E, 0x3A, 0x00, 0x00, 0x02, 0x70, 0x00, 0x17, 0x0C, 0x69, 0x0C, 0x6F, 0x0C, 0x6D, 0x00, 0x80, 0x03, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x05, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x2D, 0x02, 0x67, 0x00, 0x09, 0x02, 0x6B, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x0A, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x2F, 0x02, 0x69, 0x00, 0x0D, 0x02, 0x69, 0x00, 0x00, 0x00, 0x02, 0x35, 0x00, 0x00, 0x00, 0x00, 0x00, 0x10, 0x5E, 0x00, 0x00, 0x02, 0x80, 0x04, 0x54, 0x1E, 0x3A, 0x00, 0x00, 0x02, 0x70, 0x00, 0x17, 0x0C, 0x69, 0x0C, 0x6F, 0x0C, 0x6D, 0x00, 0x80, 0x03, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x05, 0x00, 0x02, 0x00, 0x08, 0x00, 0x00, 0x2D, 0x02, 0x67, 0x00, 0x09, 0x02, 0x6B, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x0A, 0x00, 0x02, 0x00, 0x08, 0x00, 0x00, 0x2F, 0x02, 0x69, 0x00, 0x0D, 0x02, 0x69, 0x00, 0x00, 0x00, 0x02, 0x36, 0x00, 0x00, 0x00, 0x00, 0x00, 0x13, 0x4F, 0x00, 0x00, 0x05, 0x00, 0x04, 0x54, 0x1E, 0x3A, 0x00, 0x00, 0x02, 0x70, 0x00, 0x17, 0x0C, 0x69, 0x0C, 0x6F, 0x0C, 0x6D, 0x00, 0x80, 0x03, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0A, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x2D, 0x02, 0x67, 0x00, 0x09, 0x02, 0x6B, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x14, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x2F, 0x02, 0x69, 0x00, 0x0D, 0x02, 0x69, 0x00, 0x00, 0x00, 0x02, 0x37, 0x00, 0x00, 0x00, 0x00, 0x00, 0x12, 0x4F, 0x00, 0x00, 0x02, 0x80, 0x04, 0x54, 0x1E, 0x3A, 0x00, 0x00, 0x02, 0x70, 0x00, 0x17, 0x0C, 0x69, 0x0C, 0x6F, 0x0C, 0x6D, 0x00, 0x80, 0x03, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0A, 0x00, 0x02, 0x00, 0x08, 0x00, 0x00, 0x2D, 0x02, 0x67, 0x00, 0x09, 0x02, 0x6B, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x14, 0x00, 0x02, 0x00, 0x08, 0x00, 0x00, 0x2F, 0x02, 0x69, 0x00, 0x0D, 0x02, 0x69, 0x00, 0x00, 0x00, 0x02}; +#endif diff --git a/lib/src/osVirtualToPhysical.c b/lib/src/osVirtualToPhysical.c index b1fb1a55..b6e3d2db 100644 --- a/lib/src/osVirtualToPhysical.c +++ b/lib/src/osVirtualToPhysical.c @@ -1,10 +1,11 @@ #include "libultra_internal.h" +#include "PR/R4300.h" uintptr_t osVirtualToPhysical(void *addr) { - if ((uintptr_t) addr >= 0x80000000 && (uintptr_t) addr < 0xa0000000) { - return ((uintptr_t) addr & 0x1fffffff); - } else if ((uintptr_t) addr >= 0xa0000000 && (uintptr_t) addr < 0xc0000000) { - return ((uintptr_t) addr & 0x1fffffff); + if (IS_KSEG0(addr)) { + return K0_TO_PHYS(addr); + } else if (IS_KSEG1(addr)) { + return (K1_TO_PHYS(addr)); } else { return __osProbeTLB(addr); } diff --git a/lib/src/osYieldThread.c b/lib/src/osYieldThread.c new file mode 100644 index 00000000..1685890e --- /dev/null +++ b/lib/src/osYieldThread.c @@ -0,0 +1,8 @@ +#include "libultra_internal.h" + +void osYieldThread(void) { + register u32 saveMask = __osDisableInt(); + __osRunningThread->state = OS_STATE_RUNNABLE; + __osEnqueueAndYield(&__osRunQueue); + __osRestoreInt(saveMask); +} diff --git a/lib/src/osint.h b/lib/src/osint.h index ba5d7db5..0be4830b 100644 --- a/lib/src/osint.h +++ b/lib/src/osint.h @@ -7,11 +7,6 @@ typedef struct __OSEventState OSMesgQueue *messageQueue; OSMesg message; } __OSEventState; -extern struct __osThreadTail -{ - OSThread *next; - OSPri priority; -} __osThreadTail; //maybe should be in exceptasm.h? extern void __osEnqueueAndYield(OSThread **); @@ -27,12 +22,12 @@ extern u32 __osProbeTLB(void *); extern int __osSpDeviceBusy(void); #ifdef AVOID_UB -extern OSThread_ListHead D_80334890_fix; +extern OSThread_ListHead __osThreadTail_fix; #else extern OSThread *__osRunningThread; -extern OSThread *D_8033489C; +extern OSThread *__osActiveQueue; extern OSThread *__osFaultedThread; -extern OSThread *D_80334898; +extern OSThread *__osRunQueue; #endif extern OSTimer *__osTimerList; @@ -47,6 +42,7 @@ extern __OSEventState __osEventStateTab[OS_NUM_EVENTS]; //not sure if this should be here extern s32 osViClock; +extern u32 __osShutdown; extern void __osTimerServicesInit(void); extern s32 __osAiDeviceBusy(void); extern int __osDpDeviceBusy(void); diff --git a/lib/src/pfsgetstatus.c b/lib/src/pfsgetstatus.c index 3497bfa3..520cb345 100644 --- a/lib/src/pfsgetstatus.c +++ b/lib/src/pfsgetstatus.c @@ -1,68 +1,26 @@ #include "libultra_internal.h" #include "controller.h" -void __osPfsRequestOneChannel(int channel); -void __osPfsGetOneChannelData(int channel, OSContStatus *data); - -s32 __osPfsGetStatus(OSMesgQueue *queue, int channel) { - s32 ret; +s32 __osPfsGetStatus(OSMesgQueue *queue, s32 channel) { + s32 ret = 0; OSMesg dummy; - OSContStatus data; - ret = 0; - __osPfsRequestOneChannel(channel); + u8 pattern; + OSContStatus data[4]; + + __osPfsRequestData(CONT_CMD_REQUEST_STATUS); ret = __osSiRawStartDma(OS_WRITE, &__osPfsPifRam); osRecvMesg(queue, &dummy, OS_MESG_BLOCK); ret = __osSiRawStartDma(OS_READ, &__osPfsPifRam); osRecvMesg(queue, &dummy, OS_MESG_BLOCK); - __osPfsGetOneChannelData(channel, &data); - if (((data.status & CONT_CARD_ON) != 0) && ((data.status & CONT_CARD_PULL) != 0)) { + __osPfsGetInitData(&pattern, data); + if (data[channel].status & CONT_CARD_ON && data[channel].status & CONT_CARD_PULL) { return PFS_ERR_NEW_PACK; } - if ((data.errnum != 0) || ((data.status & CONT_CARD_ON) == 0)) { + if (data[channel].errnum || !(data[channel].status & CONT_CARD_ON)) { return PFS_ERR_NOPACK; } - if ((data.status & CONT_ADDR_CRC_ER) != 0) { + if (data[channel].status & CONT_ADDR_CRC_ER) { return PFS_ERR_CONTRFAIL; } return ret; } - -void __osPfsRequestOneChannel(int channel) { - u8 *ptr; - __OSContRequesFormatShort requestformat; - int i; - - _osLastSentSiCmd = CONT_CMD_REQUEST_STATUS; - __osPfsPifRam.pifstatus = CONT_CMD_EXE; - ptr = (u8 *)&__osPfsPifRam; - - requestformat.txsize = CONT_CMD_REQUEST_STATUS_TX; - requestformat.rxsize = CONT_CMD_REQUEST_STATUS_RX; - requestformat.cmd = CONT_CMD_REQUEST_STATUS; - requestformat.typeh = CONT_CMD_NOP; - requestformat.typel = CONT_CMD_NOP; - requestformat.status = CONT_CMD_NOP; - for (i = 0; i < channel; i++) { - *ptr++ = 0; - } - - *(__OSContRequesFormatShort *)ptr = requestformat; - ptr += sizeof(__OSContRequesFormatShort); - *ptr = CONT_CMD_END; -} - -void __osPfsGetOneChannelData(int channel, OSContStatus *data) { - u8 *ptr; - __OSContRequesFormatShort requestformat; - int i; - ptr = (u8*)&__osPfsPifRam; - for (i = 0; i < channel; i++) { - ptr++; - } - requestformat = *(__OSContRequesFormatShort *)ptr; - data->errnum = CHNL_ERR(requestformat); - if (data->errnum == 0) { - data->type = (requestformat.typel << 8) | (requestformat.typeh); - data->status = requestformat.status; - } -} diff --git a/lib/src/piint.h b/lib/src/piint.h index f2793962..335abddc 100644 --- a/lib/src/piint.h +++ b/lib/src/piint.h @@ -88,16 +88,20 @@ #define LEO_CMD_TYPE_2 2 //TODO: name #define LEO_ERROR_GOOD 0 +#define LEO_ERROR_3 3 // #define LEO_ERROR_4 4 //maybe busy? +#define LEO_ERROR_6 6 // +#define LEO_ERROR_17 17 // #define LEO_ERROR_22 22 // #define LEO_ERROR_23 23 //unrecovered read error? #define LEO_ERROR_24 24 //no reference position found? #define LEO_ERROR_29 29 // +#define LEO_ERROR_75 75 // extern OSDevMgr __osPiDevMgr; extern OSPiHandle *__osCurrentHandle[2]; -extern OSPiHandle CartRomHandle; -extern OSPiHandle LeoDiskHandle; +extern OSPiHandle __Dom1SpeedParam; +extern OSPiHandle __Dom2SpeedParam; extern OSMesgQueue __osPiAccessQueue; extern u32 __osPiAccessQueueEnabled; @@ -110,38 +114,78 @@ OSMesgQueue *osPiGetCmdQueue(void); #define OS_RAMROM_STACKSIZE 1024 -#define WAIT_ON_IOBUSY(stat) \ +#define WAIT_ON_IO_BUSY(stat) \ stat = IO_READ(PI_STATUS_REG); \ while (stat & (PI_STATUS_IO_BUSY | PI_STATUS_DMA_BUSY)) \ stat = IO_READ(PI_STATUS_REG); +#ifdef VERSION_EU +#define WAIT_ON_LEO_IO_BUSY(stat) \ + stat = IO_READ(PI_STATUS_REG); \ + while (stat & PI_STATUS_IO_BUSY) \ + stat = IO_READ(PI_STATUS_REG); +#else +#define WAIT_ON_LEO_IO_BUSY WAIT_ON_IO_BUSY +#endif + #define UPDATE_REG(reg, var) \ if (cHandle->var != pihandle->var) \ IO_WRITE(reg, pihandle->var); -#define EPI_SYNC(pihandle, stat, domain) \ - \ - WAIT_ON_IOBUSY(stat) \ - \ - domain = pihandle->domain; \ - if (__osCurrentHandle[domain] != pihandle) \ - { \ - OSPiHandle *cHandle = __osCurrentHandle[domain]; \ - if (domain == PI_DOMAIN1) \ - { \ - UPDATE_REG(PI_BSD_DOM1_LAT_REG, latency); \ - UPDATE_REG(PI_BSD_DOM1_PGS_REG, pageSize); \ - UPDATE_REG(PI_BSD_DOM1_RLS_REG, relDuration); \ - UPDATE_REG(PI_BSD_DOM1_PWD_REG, pulse); \ - } \ - else \ - { \ - UPDATE_REG(PI_BSD_DOM2_LAT_REG, latency); \ - UPDATE_REG(PI_BSD_DOM2_PGS_REG, pageSize); \ - UPDATE_REG(PI_BSD_DOM2_RLS_REG, relDuration); \ - UPDATE_REG(PI_BSD_DOM2_PWD_REG, pulse); \ - } \ - __osCurrentHandle[domain] = pihandle; \ +#ifdef VERSION_CN +#define EPI_SYNC(pihandle, stat, domain) \ + \ + WAIT_ON_IO_BUSY(stat) \ + \ + domain = pihandle->domain; \ + if (__osCurrentHandle[domain]->type != pihandle->type) \ + { \ + OSPiHandle *cHandle = __osCurrentHandle[domain]; \ + if (domain == PI_DOMAIN1) \ + { \ + UPDATE_REG(PI_BSD_DOM1_LAT_REG, latency); \ + UPDATE_REG(PI_BSD_DOM1_PGS_REG, pageSize); \ + UPDATE_REG(PI_BSD_DOM1_RLS_REG, relDuration); \ + UPDATE_REG(PI_BSD_DOM1_PWD_REG, pulse); \ + } \ + else \ + { \ + UPDATE_REG(PI_BSD_DOM2_LAT_REG, latency); \ + UPDATE_REG(PI_BSD_DOM2_PGS_REG, pageSize); \ + UPDATE_REG(PI_BSD_DOM2_RLS_REG, relDuration); \ + UPDATE_REG(PI_BSD_DOM2_PWD_REG, pulse); \ + } \ + cHandle->type = pihandle->type; \ + cHandle->latency = pihandle->latency; \ + cHandle->pageSize = pihandle->pageSize; \ + cHandle->relDuration = pihandle->relDuration; \ + cHandle->pulse = pihandle->pulse; \ } +#else +#define EPI_SYNC(pihandle, stat, domain) \ + \ + WAIT_ON_IO_BUSY(stat) \ + \ + domain = pihandle->domain; \ + if (__osCurrentHandle[domain] != pihandle) \ + { \ + OSPiHandle *cHandle = __osCurrentHandle[domain]; \ + if (domain == PI_DOMAIN1) \ + { \ + UPDATE_REG(PI_BSD_DOM1_LAT_REG, latency); \ + UPDATE_REG(PI_BSD_DOM1_PGS_REG, pageSize); \ + UPDATE_REG(PI_BSD_DOM1_RLS_REG, relDuration); \ + UPDATE_REG(PI_BSD_DOM1_PWD_REG, pulse); \ + } \ + else \ + { \ + UPDATE_REG(PI_BSD_DOM2_LAT_REG, latency); \ + UPDATE_REG(PI_BSD_DOM2_PGS_REG, pageSize); \ + UPDATE_REG(PI_BSD_DOM2_RLS_REG, relDuration); \ + UPDATE_REG(PI_BSD_DOM2_PWD_REG, pulse); \ + } \ + __osCurrentHandle[domain] = pihandle; \ + } +#endif #endif diff --git a/lib/src/printf.h b/lib/src/printf.h index 5d798a19..a4222930 100644 --- a/lib/src/printf.h +++ b/lib/src/printf.h @@ -2,6 +2,12 @@ #define _PRINTF_H_ #include +#ifdef VERSION_CN +typedef char fmt_type; +#else +typedef u8 fmt_type; +#endif + typedef struct { union { @@ -22,7 +28,7 @@ typedef struct /* 28 */ s32 width; /* 2c */ u32 size; /* 30 */ u32 flags; - /* 34 */ u8 length; + /* 34 */ fmt_type length; } printf_struct; #define FLAGS_SPACE 1 @@ -31,6 +37,6 @@ typedef struct #define FLAGS_HASH 8 #define FLAGS_ZERO 16 s32 _Printf(char *(*prout)(char *, const char *, size_t), char *dst, const char *fmt, va_list args); -void _Litob(printf_struct *args, u8 type); -void _Ldtob(printf_struct *args, u8 type); +void _Litob(printf_struct *args, fmt_type type); +void _Ldtob(printf_struct *args, fmt_type type); #endif diff --git a/lib/src/string.c b/lib/src/string.c index dbffaa1d..fafe7fa9 100644 --- a/lib/src/string.c +++ b/lib/src/string.c @@ -1,6 +1,29 @@ #include "libultra_internal.h" #include +#ifdef VERSION_CN + +char *strchr(const char *str, s32 ch) { + char c = ch; + while (*str != c) { + if (*str == 0) { + return NULL; + } + str++; + } + return (char *) str; +} + +size_t strlen(const char *str) { + const char *ptr = str; + while (*ptr) { + ptr++; + } + return ptr - str; +} + +#endif + void *memcpy(void *dst, const void *src, size_t size) { u8 *_dst = dst; const u8 *_src = src; @@ -11,6 +34,8 @@ void *memcpy(void *dst, const void *src, size_t size) { return dst; } +#ifndef VERSION_CN + size_t strlen(const char *str) { const u8 *ptr = (const u8 *) str; while (*ptr) { @@ -29,3 +54,5 @@ char *strchr(const char *str, s32 ch) { } return (char *) str; } + +#endif diff --git a/lib/src/unk_shindou_file_3.c b/lib/src/unk_shindou_file_3.c deleted file mode 100644 index d18e7b3c..00000000 --- a/lib/src/unk_shindou_file_3.c +++ /dev/null @@ -1,26 +0,0 @@ -#include "libultra_internal.h" -#include "controller.h" - -s32 func_8030A5C0(OSMesgQueue *arg0, s32 arg1) { // TODO: This is almost certainly __osPfsGetStatus. - s32 sp34 = 0; - OSMesg sp30; - u8 sp2f; - OSContStatus sp1c[4]; - __osPfsRequestData(0); - sp34 = __osSiRawStartDma(1, &__osPfsPifRam); - osRecvMesg(arg0, &sp30, 1); - sp34 = __osSiRawStartDma(0, &__osPfsPifRam); - osRecvMesg(arg0, &sp30, 1); - __osPfsGetInitData(&sp2f, sp1c); - if (sp1c[arg1].status & CONT_CARD_ON && sp1c[arg1].status & CONT_CARD_PULL) { - return 2; - } - if (sp1c[arg1].errnum || !(sp1c[arg1].status & CONT_CARD_ON)) { - return 1; - } - if (sp1c[arg1].status & CONT_ADDR_CRC_ER) { - return 4; - } - return sp34; - -} diff --git a/rsp/audio.s b/rsp/audio.s index 901a7d0d..852979f0 100644 --- a/rsp/audio.s +++ b/rsp/audio.s @@ -8,6 +8,12 @@ .error "armips 0.11 or newer is required" .endif +.ifdef VERSION_SH +.definelabel VERSION_SH_CN, 1 +.elseifdef VERSION_CN +.definelabel VERSION_SH_CN, 1 +.endif + .macro jumpTableEntry, addr .dh addr & 0xFFFF .endmacro @@ -35,7 +41,7 @@ dispatchTable: jumpTableEntry cmd_SPNOOP jumpTableEntry cmd_ADPCM jumpTableEntry cmd_CLEARBUFF -.ifdef VERSION_SH +.ifdef VERSION_SH_CN jumpTableEntry cmd_SPNOOP jumpTableEntry cmd_ADDMIXER @@ -98,7 +104,7 @@ data0040: .dh 0x0000, 0x0000, 0x0001, 0x0000, 0x0000, 0x0000, 0x0001, 0x0000 // 0x00000090 .dh 0x0000, 0x0000, 0x0000, 0x0001, 0x0000, 0x0000, 0x0000, 0x0001 // 0x000000a0 .dh 0x2000, 0x4000, 0x6000, 0x8000, 0xa000, 0xc000, 0xe000, 0xffff // 0x000000b0 -.ifdef VERSION_SH +.ifdef VERSION_SH_CN .dh 0x0000, 0xFFFF, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000 .dh 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000 .endif @@ -134,7 +140,7 @@ data0040: .dh 0xffb6, 0x1338, 0x655e, 0x07ab, 0xffbf, 0x11f0, 0x65cd, 0x087d // 0x00000290 .dh 0xffc8, 0x10b4, 0x6626, 0x095a, 0xffd0, 0x0f83, 0x6669, 0x0a44 // 0x000002a0 .dh 0xffd8, 0x0e5f, 0x6696, 0x0b39, 0xffdf, 0x0d46, 0x66ad, 0x0c39 // 0x000002b0 -.ifdef VERSION_SH +.ifdef VERSION_SH_CN .dh 0xFFFF, 0xDFFF, 0xBFFF, 0x9FFF, 0x7FFF, 0x5FFF, 0x3FFF, 0x1FFF .dh 0x0000, 0x2000, 0x4000, 0x6000, 0x8000, 0xA000, 0xC000, 0xE000 .dh 0x0000, 0x0002, 0x0004, 0x0006, 0x0008, 0x000A, 0x000C, 0x000E @@ -142,7 +148,7 @@ data0040: .definelabel segmentTable, 0x320 -.ifdef VERSION_SH +.ifdef VERSION_SH_CN .definelabel audioStruct, 0x320 .else .definelabel audioStruct, 0x360 @@ -161,7 +167,7 @@ audio_rate_hi_left equ 0x12 // 0x372 (shared) audio_rate_lo_left equ 0x14 // 0x374 audio_target_right equ 0x16 // 0x376 audio_rate_hi_right equ 0x18 // 0x378 -.ifdef VERSION_SH +.ifdef VERSION_SH_CN .definelabel audio_rate_lo_right, 0x04 // 0x37a .else .definelabel audio_rate_lo_right, 0x1a // 0x37a @@ -169,7 +175,7 @@ audio_rate_hi_right equ 0x18 // 0x378 audio_dry_gain equ 0x1c // 0x37c audio_wet_gain equ 0x1e // 0x37e -.ifdef VERSION_SH +.ifdef VERSION_SH_CN .definelabel nextTaskEntry, 0x340 .definelabel adpcmTable, 0x3c0 .else @@ -203,7 +209,7 @@ audio_wet_gain equ 0x1e // 0x37e nop jal audio_04001150 nop -.ifndef VERSION_SH +.ifndef VERSION_SH_CN addi $2, $zero, 0x000f addi $1, $zero, segmentTable @@audio_040010c8: @@ -254,14 +260,14 @@ audio_04001150: addi $5, $ra, 0x0000 add $2, $zero, $28 addi $3, $27, 0x0000 -.ifdef VERSION_SH +.ifdef VERSION_SH_CN addi $4, $3, -0x80 .else addi $4, $3, -0x0140 .endif blez $4, @@audio_0400116c addi $1, $zero, nextTaskEntry -.ifdef VERSION_SH +.ifdef VERSION_SH_CN addi $3, $zero, 0x80 .else addi $3, $zero, 0x0140 @@ -305,21 +311,21 @@ dma_write_start: cmd_CLEARBUFF: andi $3, $25, 0xffff beqz $3, cmd_SPNOOP -.ifndef VERSION_SH +.ifndef VERSION_SH_CN addi $4, $zero, dmemBase .endif andi $2, $26, 0xffff -.ifndef VERSION_SH +.ifndef VERSION_SH_CN add $2, $2, $4 .endif -.ifdef VERSION_SH +.ifdef VERSION_SH_CN vxor $v0, $v0, $v0 .else vxor $v1, $v1, $v1 .endif addi $3, $3, -0x10 @@audio_040011f8: -.ifdef VERSION_SH +.ifdef VERSION_SH_CN sdv $v0[0], 0x0($2) sdv $v0[0], 0x8($2) .else @@ -332,7 +338,7 @@ cmd_CLEARBUFF: j cmd_SPNOOP nop -.ifndef VERSION_SH +.ifndef VERSION_SH_CN cmd_LOADBUFF: lhu $3, (audio_count)($24) beqz $3, cmd_SPNOOP @@ -390,7 +396,7 @@ cmd_LOADADPCM: mtc0 $zero, SP_SEMAPHORE .endif cmd_SEGMENT: -.ifndef VERSION_SH +.ifndef VERSION_SH_CN sll $3, $25, 8 // Least significant 24-bits offset srl $3, $3, 8 srl $2, $25, 24 // Most significant 8-bits segment number @@ -400,7 +406,7 @@ cmd_SEGMENT: sw $3, (segmentTable)($4) .endif -.ifndef VERSION_SH +.ifndef VERSION_SH_CN cmd_SETBUFF: addi $1, $26, dmemBase srl $2, $25, 16 @@ -420,7 +426,7 @@ cmd_SETBUFF: sh $2, (audio_aux_buf1)($24) .endif -.ifdef VERSION_SH +.ifdef VERSION_SH_CN cmd_SETBUFF: srl $2, $25, 16 sh $26, 0($24) @@ -459,7 +465,7 @@ cmd_SETVOL: sh $25, (audio_rate_lo_right)($24) cmd_INTERLEAVE: -.ifdef VERSION_SH +.ifdef VERSION_SH_CN andi $a0, $k0, 0xffff srl $at, $k0, 12 andi $at, $at, 0xff0 @@ -511,7 +517,7 @@ cmd_INTERLEAVE: addi $3, $3, 0x10 .endif bgtz $1, @@audio_040013a8 -.ifdef VERSION_SH +.ifdef VERSION_SH_CN ssv $v2[6], 0xFE($a0) .else addi $4, $4, 0x20 @@ -523,11 +529,11 @@ cmd_DMEMMOVE: andi $1, $25, 0xffff beqz $1, cmd_SPNOOP andi $2, $26, 0xffff -.ifndef VERSION_SH +.ifndef VERSION_SH_CN addi $2, $2, dmemBase .endif srl $3, $25, 16 -.ifndef VERSION_SH +.ifndef VERSION_SH_CN addi $3, $3, dmemBase .endif @@audio_04001424: @@ -545,7 +551,7 @@ cmd_DMEMMOVE: cmd_SETLOOP: sll $1, $25, 8 srl $1, $1, 8 -.ifndef VERSION_SH +.ifndef VERSION_SH_CN srl $3, $25, 24 sll $3, $3, 2 lw $2, (segmentTable)($3) @@ -553,7 +559,7 @@ cmd_SETLOOP: sw $1, (audio_loop_value)($24) .endif j cmd_SPNOOP -.ifdef VERSION_SH +.ifdef VERSION_SH_CN sw $at, 0x10($t8) .else nop @@ -571,27 +577,27 @@ cmd_ADPCM: vxor $v14, $v14, $v14 lhu $18, (audio_count)($24) vxor $v15, $v15, $v15 -.ifndef VERSION_SH +.ifndef VERSION_SH_CN lui $1, 0x00ff .endif vxor $v16, $v16, $v16 -.ifdef VERSION_SH +.ifdef VERSION_SH_CN sll $s1, $t9, 8 .else ori $1, $1, 0xffff .endif vxor $v17, $v17, $v17 -.ifndef VERSION_SH +.ifndef VERSION_SH_CN and $17, $25, $1 .endif vxor $v18, $v18, $v18 -.ifdef VERSION_SH +.ifdef VERSION_SH_CN srl $s1, $s1, 8 .else srl $2, $25, 24 .endif vxor $v19, $v19, $v19 -.ifndef VERSION_SH +.ifndef VERSION_SH_CN sll $2, $2, 2 lw $3, (segmentTable)($2) add $17, $17, $3 // last frame addr @@ -616,7 +622,7 @@ cmd_ADPCM: nop mtc0 $zero, SP_SEMAPHORE @@audio_0400150c: -.ifdef VERSION_SH +.ifdef VERSION_SH_CN addi $16, $zero, 0x0050 .else addi $16, $zero, 0x0030 @@ -754,7 +760,7 @@ cmd_ADPCM: mtc0 $zero, SP_SEMAPHORE cmd_POLEF: // unused by SM64 -.ifndef VERSION_SH +.ifndef VERSION_SH_CN lqv $v31[0], 0x0000($zero) vxor $v28, $v28, $v28 lhu $21, (audio_in_buf)($24) @@ -790,14 +796,14 @@ cmd_POLEF: // unused by SM64 addi $3, $zero, 7 .endif @@dma_read_busy: -.ifndef VERSION_SH +.ifndef VERSION_SH_CN mfc0 $5, SP_DMA_BUSY bnez $5, @@dma_read_busy nop mtc0 $zero, SP_SEMAPHORE .endif @@audio_040017a0: -.ifndef VERSION_SH +.ifndef VERSION_SH_CN addi $13, $zero, adpcmTable addi $1, $zero, 0x0004 mtc2 $1, $v14[0] @@ -824,7 +830,7 @@ cmd_POLEF: // unused by SM64 ldv $v30[8], 0x08($21) .endif @@audio_04001800: -.ifndef VERSION_SH +.ifndef VERSION_SH_CN vmudh $v16, $v25, $v28[6] addi $21, $21, 0x10 vmadh $v16, $v24, $v28[7] @@ -853,13 +859,13 @@ cmd_POLEF: // unused by SM64 addi $3, $zero, 7 .endif @@dma_write_busy: -.ifndef VERSION_SH +.ifndef VERSION_SH_CN mfc0 $5, SP_DMA_BUSY bnez $5, @@dma_write_busy nop .endif @@audio_04001874: -.ifndef VERSION_SH +.ifndef VERSION_SH_CN j cmd_SPNOOP mtc0 $zero, SP_SEMAPHORE .endif @@ -868,7 +874,7 @@ cmd_RESAMPLE: lh $8, (audio_in_buf)($24) lh $19, (audio_out_buf)($24) lh $18, (audio_count)($24) -.ifdef VERSION_SH +.ifdef VERSION_SH_CN sll $v0, $t9, 8 srl $v0, $v0, 8 .else @@ -902,7 +908,7 @@ cmd_RESAMPLE: @@audio_040018e8: andi $10, $7, 0x02 // A_LOOP? A_OUT? beqz $10, @@audio_04001908 -.ifdef VERSION_SH +.ifdef VERSION_SH_CN ldv $v16[0], 0x00($23) addi $t0, $t0, -4 ssv $v16[0], 0x00($t0) @@ -919,7 +925,7 @@ cmd_RESAMPLE: .endif @@audio_04001908: -.ifdef VERSION_SH +.ifdef VERSION_SH_CN andi $t2, $a3, 4 beqz $t2, @@audio_c4104 nop @@ -937,19 +943,19 @@ cmd_RESAMPLE: @@audio_c4104: .endif addi $8, $8, -8 -.ifdef VERSION_SH +.ifdef VERSION_SH_CN sdv $v16[0], 0x00($8) .endif @@audio_c410c: lsv $v23[14], 0x08($23) // saved pitch_accumulator -.ifdef VERSION_SH +.ifdef VERSION_SH_CN ldv $v16[0], 0x00($8) .else ldv $v16[0], 0x00($23) // saved next 4 unprocessed samples sdv $v16[0], 0x00($8) // store them before the input samples .endif mtc2 $8, $v18[4] -.ifdef VERSION_SH +.ifdef VERSION_SH_CN addi $10, $zero, 0x100 .else addi $10, $zero, 0xc0 @@ -958,7 +964,7 @@ cmd_RESAMPLE: mtc2 $26, $v18[8] // pitch addi $10, $zero, 0x40 mtc2 $10, $v18[10] -.ifdef VERSION_SH +.ifdef VERSION_SH_CN addi $9, $zero, 0x60 .else addi $9, $zero, data0040 @@ -1073,7 +1079,7 @@ cmd_RESAMPLE: ssv $v23[0], 0x08($23) ldv $v16[0], 0x00($17) sdv $v16[0], 0x00($23) -.ifndef VERSION_SH +.ifndef VERSION_SH_CN lh $6, (audio_in_buf)($24) addi $17, $17, 8 sub $5, $17, $6 @@ -1099,7 +1105,7 @@ cmd_RESAMPLE: j cmd_SPNOOP mtc0 $zero, SP_SEMAPHORE -.ifdef VERSION_SH +.ifdef VERSION_SH_CN cmd_DMEMMOVE2: srl $t7, $k0, 16 andi $t7, $t7, 0xff @@ -1175,7 +1181,7 @@ cmd_DOWNSAMPLE_HALF: nop .endif -.ifndef VERSION_SH +.ifndef VERSION_SH_CN cmd_ENVMIXER: lui $4, 0x00ff ori $4, $4, 0xffff @@ -1417,7 +1423,7 @@ cmd_MIXER: nop .endif -.ifdef VERSION_SH +.ifdef VERSION_SH_CN cmd_ENVMIXER: vxor $v4, $v4, $v4 vxor $v0, $v0, $v0 diff --git a/sm64.cn.sha1 b/sm64.cn.sha1 new file mode 100644 index 00000000..0fbba07c --- /dev/null +++ b/sm64.cn.sha1 @@ -0,0 +1 @@ +2e1db2780985a1f068077dc0444b685f39cd90ec build/cn/sm64.cn.z64 diff --git a/sm64.ld b/sm64.ld index 250de7a5..c88b5c0e 100755 --- a/sm64.ld +++ b/sm64.ld @@ -1,14 +1,20 @@ OUTPUT_ARCH (mips) /* include/segments.h defines SEG_POOL_START, SEG_POOL_END, SEG_BUFFERS, - * SEG_GODDARD, SEG_MAIN, SEG_ENGINE, SEG_FRAMEBUFFERS */ + * SEG_GODDARD, SEG_ENGINE, SEG_FRAMEBUFFERS */ #include "segments.h" #include "config.h" +#ifndef USE_EXT_RAM +#define ADDR_OR_ALIGN(addr) (addr) +#else +#define ADDR_OR_ALIGN(addr) ALIGN(0x1000) +#endif + #define BEGIN_SEG(name, addr) \ _##name##SegmentStart = ADDR(.name); \ _##name##SegmentRomStart = __romPos; \ - .name addr : AT(__romPos) + .name (addr) : AT(__romPos) #define END_SEG(name) \ _##name##SegmentEnd = ADDR(.name) + SIZEOF(.name); \ @@ -23,1105 +29,1323 @@ OUTPUT_ARCH (mips) _##name##SegmentNoloadEnd = ADDR(.name.noload) + SIZEOF(.name.noload); #define MIO0_SEG(name, segAddr) \ - BEGIN_SEG(name##_mio0, segAddr) \ - { \ - BUILD_DIR/bin/name.mio0.o(.data); \ - . = ALIGN(0x10); \ - } \ - END_SEG(name##_mio0) + BEGIN_SEG(name##_mio0, segAddr) \ + { \ + BUILD_DIR/bin/name.mio0.o(.data); \ + . = ALIGN(0x10); \ + } \ + END_SEG(name##_mio0) #define MIO0_EU_SEG(name, segAddr) \ - BEGIN_SEG(name##_mio0, segAddr) \ - { \ - BUILD_DIR/bin/eu/name.mio0.o(.data); \ - . = ALIGN(0x10); \ - } \ - END_SEG(name##_mio0) + BEGIN_SEG(name##_mio0, segAddr) \ + { \ + BUILD_DIR/bin/eu/name.mio0.o(.data); \ + . = ALIGN(0x10); \ + } \ + END_SEG(name##_mio0) #define STANDARD_LEVEL(name) \ - BEGIN_SEG(name##_segment_7, 0x07000000) \ - { \ - BUILD_DIR/levels/name/leveldata.mio0.o(.data); \ - . = ALIGN(0x10); \ - } \ - END_SEG(name##_segment_7) \ - BEGIN_SEG(name, 0x0E000000) \ - { \ - BUILD_DIR/levels/name/script.o(.data); \ - BUILD_DIR/levels/name/geo.o(.data); \ - } \ - END_SEG(name) + BEGIN_SEG(name##_segment_7, 0x07000000) \ + { \ + BUILD_DIR/levels/name/leveldata.mio0.o(.data); \ + . = ALIGN(0x10); \ + } \ + END_SEG(name##_segment_7) \ + BEGIN_SEG(name, 0x0E000000) \ + { \ + BUILD_DIR/levels/name/script.o(.data); \ + BUILD_DIR/levels/name/geo.o(.data); \ + } \ + END_SEG(name) #define STANDARD_OBJECTS(name, segAddr, geoAddr) \ - BEGIN_SEG(name##_mio0, segAddr) \ - { \ - BUILD_DIR/actors/name.mio0.o(.data); \ - . = ALIGN(0x10); \ - } \ - END_SEG(name##_mio0) \ - BEGIN_SEG(name##_geo, geoAddr) \ - { \ - BUILD_DIR/actors/name##_geo.o(.data); \ - } \ - END_SEG(name##_geo) + BEGIN_SEG(name##_mio0, segAddr) \ + { \ + BUILD_DIR/actors/name.mio0.o(.data); \ + . = ALIGN(0x10); \ + } \ + END_SEG(name##_mio0) \ + BEGIN_SEG(name##_geo, geoAddr) \ + { \ + BUILD_DIR/actors/name##_geo.o(.data); \ + } \ + END_SEG(name##_geo) + +#define CREATE_LO_HI_PAIR(name, value) \ + name##Hi = (value) >> 16; \ + name##Lo = (value) & 0xffff; SECTIONS { - __romPos = 0; + __romPos = 0; - BEGIN_SEG(boot, 0x04000000) - { - BUILD_DIR/asm/rom_header.o(.text); - BUILD_DIR/asm/boot.o(.text); - } - END_SEG(boot) + BEGIN_SEG(boot, 0x04000000) + { + BUILD_DIR/asm/rom_header.o(.text); + BUILD_DIR/asm/boot.o(.text); + BUILD_DIR/asm/ipl3_font.o(.text); + } + END_SEG(boot) - . = 0x80000400; - BEGIN_NOLOAD(zbuffer) { - BUILD_DIR/src/buffers/zbuffer.o(.bss*); - } + . = 0x80000400; + BEGIN_NOLOAD(zbuffer) { + BUILD_DIR/src/buffers/zbuffer.o(.bss*); + } - /* lib/src/__osDevMgrMain.c and lib/src/osCreateViManager.c contain infinite - * loops compiled without -g, which cause the return statements and the .o - * files themselves to be aligned to 32-byte boundaries. But the linker - * Nintendo used did not respect .o file alignment, and aligned the files - * only to 16 bytes, in some cases misaligning them. We force the same to - * happen using the SUBALIGN directive. This is harmless; the alignment is - * just an optimization. */ - BEGIN_SEG(main, SEG_MAIN) SUBALIGN(16) - { - BUILD_DIR/asm/entry.o(.text); - BUILD_DIR/src/game/crash_screen.o(.text); - BUILD_DIR/src/game/main.o(.text); - BUILD_DIR/src/game/game_init.o(.text); - BUILD_DIR/src/game/sound_init.o(.text); -#if ENABLE_RUMBLE - BUILD_DIR/src/game/rumble_init.o(.text); +#ifdef VERSION_CN + gZBufferEnd = .; #endif - BUILD_DIR/src/game/level_update.o(.text); - BUILD_DIR/src/game/interaction.o(.text); - BUILD_DIR/src/game/mario.o(.text); - BUILD_DIR/src/game/mario_step.o(.text); - BUILD_DIR/src/game/mario_actions_cutscene.o(.text); - BUILD_DIR/src/game/mario_actions_automatic.o(.text); - BUILD_DIR/src/game/mario_actions_stationary.o(.text); - BUILD_DIR/src/game/mario_actions_moving.o(.text); - BUILD_DIR/src/game/mario_actions_airborne.o(.text); - BUILD_DIR/src/game/mario_actions_submerged.o(.text); - BUILD_DIR/src/game/mario_actions_object.o(.text); - BUILD_DIR/src/game/level_geo.o(.text); - BUILD_DIR/src/game/mario_misc.o(.text); - BUILD_DIR/src/game/memory.o(.text); - BUILD_DIR/src/game/save_file.o(.text); - BUILD_DIR/src/game/area.o(.text); - BUILD_DIR/src/game/rendering_graph_node.o(.text); - BUILD_DIR/src/game/profiler.o(.text); - BUILD_DIR/asm/decompress.o(.text); - BUILD_DIR/src/game/camera.o(.text); - BUILD_DIR/src/game/debug_course.o(.text); - BUILD_DIR/src/game/object_list_processor.o(.text); -#ifndef VERSION_EU - BUILD_DIR/src/game/object_helpers.o(.text); -#endif - BUILD_DIR/src/game/behavior_actions.o(.text); - BUILD_DIR/src/game/platform_displacement.o(.text); -#ifndef VERSION_EU - BUILD_DIR/src/game/object_collision.o(.text); - BUILD_DIR/src/game/spawn_object.o(.text); -#endif - BUILD_DIR/src/game/spawn_sound.o(.text); - BUILD_DIR/src/game/debug.o(.text); - BUILD_DIR/src/game/screen_transition.o(.text); - BUILD_DIR/src/game/shadow.o(.text); - BUILD_DIR/src/game/skybox.o(.text); - BUILD_DIR/src/game/moving_texture.o(.text); - BUILD_DIR/src/game/geo_misc.o(.text); - BUILD_DIR/src/game/paintings.o(.text); - BUILD_DIR/src/game/print.o(.text); - BUILD_DIR/src/game/ingame_menu.o(.text); - BUILD_DIR/src/game/envfx_snow.o(.text); - BUILD_DIR/src/game/envfx_bubbles.o(.text); - BUILD_DIR/src/game/macro_special_objects.o(.text); - BUILD_DIR/src/game/hud.o(.text); - BUILD_DIR/src/game/obj_behaviors.o(.text); - BUILD_DIR/src/game/obj_behaviors_2.o(.text); -#ifdef VERSION_SH - BUILD_DIR/src/audio/synthesis_sh.o(.text); + + . = SEG_BUFFERS; + BEGIN_NOLOAD(buffers) + { + BUILD_DIR/src/buffers/buffers.o(.bss*); +#if defined(VERSION_SH) || defined(VERSION_CN) + BUILD_DIR/src/audio/port_sh.o(.bss*); #else - BUILD_DIR/src/audio/synthesis.o(.text); + BUILD_DIR/src/audio/globals_start.o(.bss*); + BUILD_DIR/src/audio/synthesis.o(.bss*); + BUILD_DIR/src/audio/heap.o(.bss*); + BUILD_DIR/src/audio/load.o(.bss*); + BUILD_DIR/src/audio/data.o(.bss*); #endif - BUILD_DIR/src/audio/heap.o(.text); - BUILD_DIR/src/audio/load.o(.text); -#ifdef VERSION_SH - BUILD_DIR/src/audio/load_sh.o(.text); - BUILD_DIR/src/audio/port_sh.o(.text); -#endif - BUILD_DIR/src/audio/playback.o(.text); - BUILD_DIR/src/audio/effects.o(.text); - BUILD_DIR/src/audio/seqplayer.o(.text); -#ifdef VERSION_SH - BUILD_DIR/libultra.a:osDriveRomInit.o(.text); -#endif - BUILD_DIR/src/audio/external.o(.text); - BUILD_DIR/src/audio/port_eu.o(.text); -#if defined(VERSION_EU) || defined(VERSION_SH) - BUILD_DIR/libultra.a:string.o(.text); - BUILD_DIR/libultra.a:_Printf.o(.text); - BUILD_DIR/libultra.a:llmuldiv.o(.text); - BUILD_DIR/libultra.a:osInitialize.o(.text); - BUILD_DIR/libultra.a:osSetTime.o(.text); - BUILD_DIR/libultra.a:osGetTime.o(.text); - BUILD_DIR/libultra.a:osWritebackDCacheAll.o(.text); - BUILD_DIR/libultra.a:osViBlack.o(.text); - BUILD_DIR/libultra.a:osViSwapBuffer.o(.text); - BUILD_DIR/libultra.a:__osGetCurrFaultedThread.o(.text); - BUILD_DIR/libultra.a:osSetEventMesg.o(.text); - BUILD_DIR/libultra.a:osRecvMesg.o(.text); - BUILD_DIR/libultra.a:parameters.o(.text); - BUILD_DIR/libultra.a:osCreateMesgQueue.o(.text); - BUILD_DIR/libultra.a:osCreateThread.o(.text); - BUILD_DIR/libultra.a:osStartThread.o(.text); - BUILD_DIR/libultra.a:osMapTLB.o(.text); - BUILD_DIR/libultra.a:osUnmapTLBAll.o(.text); - BUILD_DIR/libultra.a:sprintf.o(.text); - BUILD_DIR/libultra.a:osViSetEvent.o(.text); - BUILD_DIR/libultra.a:osSpTaskLoadGo.o(.text); - BUILD_DIR/libultra.a:osSpTaskYield.o(.text); - BUILD_DIR/libultra.a:osSendMesg.o(.text); - BUILD_DIR/libultra.a:osSpTaskYielded.o(.text); - BUILD_DIR/libultra.a:osCreateViManager.o(.text); - BUILD_DIR/libultra.a:osViSetMode.o(.text); - BUILD_DIR/libultra.a:osViSetSpecialFeatures.o(.text); - BUILD_DIR/libultra.a:osCreatePiManager.o(.text); - BUILD_DIR/libultra.a:osSetThreadPri.o(.text); - BUILD_DIR/libultra.a:osViSwapBuffer.o(.text); - BUILD_DIR/libultra.a:sqrtf.o(.text); - BUILD_DIR/libultra.a:osContStartReadData.o(.text); - BUILD_DIR/libultra.a:osContInit.o(.text); - BUILD_DIR/libultra.a:osEepromProbe.o(.text); -#if ENABLE_RUMBLE - BUILD_DIR/libultra.a:motor.o(.text); -#endif - BUILD_DIR/libultra.a:osInvalDCache.o(.text); - BUILD_DIR/libultra.a:osPiStartDma.o(.text); - BUILD_DIR/libultra.a:bzero.o(.text); - BUILD_DIR/libultra.a:osInvalICache.o(.text); - BUILD_DIR/libultra.a:osEepromLongRead.o(.text); - BUILD_DIR/libultra.a:osEepromLongWrite.o(.text); - BUILD_DIR/libultra.a:bcopy.o(.text); - BUILD_DIR/libultra.a:guOrthoF.o(.text); - BUILD_DIR/libultra.a:guPerspectiveF.o(.text); - BUILD_DIR/libultra.a:llconv.o(.text); - BUILD_DIR/libultra.a:cosf.o(.text); - BUILD_DIR/libultra.a:sinf.o(.text); - BUILD_DIR/libultra.a:guTranslateF.o(.text); - BUILD_DIR/libultra.a:guRotateF.o(.text); - BUILD_DIR/libultra.a:guScaleF.o(.text); - BUILD_DIR/libultra.a:osAiSetFrequency.o(.text); -#ifdef VERSION_SH - BUILD_DIR/libultra.a:osCartRomInit.o(.text); - BUILD_DIR/libultra.a:epidma.o(.text); -#endif #ifdef VERSION_EU - BUILD_DIR/libultra.a:alBnkfNew.o(.text); -#endif - BUILD_DIR/libultra.a:osAiGetLength.o(.text); - BUILD_DIR/libultra.a:osAiSetNextBuffer.o(.text); -#ifdef VERSION_SH - BUILD_DIR/libultra.a:osGetCount.o(.text); - BUILD_DIR/libultra.a:__osDisableInt.o(.text); - BUILD_DIR/libultra.a:__osRestoreInt.o(.text); -#endif - BUILD_DIR/libultra.a:_Litob.o(.text); - BUILD_DIR/libultra.a:_Ldtob.o(.text); - BUILD_DIR/libultra.a:__osSetSR.o(.text); - BUILD_DIR/libultra.a:__osGetSR.o(.text); - BUILD_DIR/libultra.a:__osSetFpcCsr.o(.text); - BUILD_DIR/libultra.a:__osSiRawReadIo.o(.text); - BUILD_DIR/libultra.a:__osSiRawWriteIo.o(.text); - BUILD_DIR/libultra.a:__osExceptionPreamble.o(.text); - BUILD_DIR/libultra.a:osWritebackDCache.o(.text); - BUILD_DIR/libultra.a:osMapTLBRdb.o(.text); - BUILD_DIR/libultra.a:osPiRawReadIo.o(.text); - BUILD_DIR/libultra.a:EU_D_802f4330.o(.text); - BUILD_DIR/libultra.a:D_802F4380.o(.text); - BUILD_DIR/libultra.a:func_802F4A20.o(.text); - BUILD_DIR/libultra.a:osTimer.o(.text); -#ifdef VERSION_EU - BUILD_DIR/libultra.a:__osDisableInt.o(.text); - BUILD_DIR/libultra.a:__osRestoreInt.o(.text); - BUILD_DIR/libultra.a:osGetCount.o(.text); -#endif - BUILD_DIR/libultra.a:__osViInit.o(.text); - BUILD_DIR/libultra.a:__osDequeueThread.o(.text); - BUILD_DIR/libultra.a:osVirtualToPhysical.o(.text); - BUILD_DIR/libultra.a:__osSpSetStatus.o(.text); - BUILD_DIR/libultra.a:__osSpSetPc.o(.text); - BUILD_DIR/libultra.a:__osSpRawStartDma.o(.text); - BUILD_DIR/libultra.a:__osSpDeviceBusy.o(.text); - BUILD_DIR/libultra.a:__osSpGetStatus.o(.text); - BUILD_DIR/libultra.a:osGetThreadPri.o(.text); - BUILD_DIR/libultra.a:__osViGetCurrentContext.o(.text); - BUILD_DIR/libultra.a:__osViSwapContext.o(.text); -#ifdef VERSION_SH - BUILD_DIR/libultra.a:osLeoDiskInit.o(.text); -#endif - BUILD_DIR/libultra.a:__osPiCreateAccessQueue.o(.text); - BUILD_DIR/libultra.a:osPiRawStartDma.o(.text); - BUILD_DIR/libultra.a:osEPiRawStartDma.o(.text); - BUILD_DIR/libultra.a:__osDevMgrMain.o(.text); - BUILD_DIR/libultra.a:__osSiCreateAccessQueue.o(.text); - BUILD_DIR/libultra.a:__osSiRawStartDma.o(.text); - BUILD_DIR/libultra.a:osSetTimer.o(.text); - BUILD_DIR/libultra.a:osEepromWrite.o(.text); -#if ENABLE_RUMBLE - BUILD_DIR/libultra.a:osPfsIsPlug.o(.text); - BUILD_DIR/libultra.a:crc.o(.text); - BUILD_DIR/libultra.a:contramwrite.o(.text); - BUILD_DIR/libultra.a:contramread.o(.text); -#endif - BUILD_DIR/libultra.a:osJamMesg.o(.text); - BUILD_DIR/libultra.a:osPiGetCmdQueue.o(.text); - BUILD_DIR/libultra.a:osEepromRead.o(.text); - BUILD_DIR/libultra.a:guMtxF2L.o(.text); - BUILD_DIR/libultra.a:guNormalize.o(.text); - BUILD_DIR/libultra.a:__osAiDeviceBusy.o(.text); - BUILD_DIR/libultra.a:ldiv.o(.text); - BUILD_DIR/libultra.a:__osSiDeviceBusy.o(.text); -#ifdef VERSION_SH - BUILD_DIR/libultra.a:leointerrupt.o(.text); -#endif - BUILD_DIR/libultra.a:osSetIntMask.o(.text); - BUILD_DIR/libultra.a:osDestroyThread.o(.text); -#ifdef VERSION_EU - BUILD_DIR/libultra.a:osLeoDiskInit.o(.text); -#endif - BUILD_DIR/libultra.a:__osSetCompare.o(.text); - BUILD_DIR/libultra.a:__osDequeueThread.o(.text); - BUILD_DIR/libultra.a:__osProbeTLB.o(.text); - BUILD_DIR/libultra.a:__osResetGlobalIntMask.o(.text); - BUILD_DIR/libultra.a:__osEPiRawWriteIo.o(.text); -#ifdef VERSION_SH - BUILD_DIR/libultra.a:__osEPiRawReadIo.o(.text); - BUILD_DIR/libultra.a:__osSetGlobalIntMask.o(.text); -#endif - BUILD_DIR/libultra.a:func_802F71F0.o(.text); -#if ENABLE_RUMBLE - BUILD_DIR/libultra.a:unk_shindou_file_3.o(.text); -#endif - BUILD_DIR/lib/rsp.o(.text); + . = ALIGN(0x200); #else - BUILD_DIR/src/game*.o(.text); - BUILD_DIR/src/audio*.o(.text); - BUILD_DIR/libultra.a:parameters.o(.text); - BUILD_DIR/libultra.a:osSetTime.o(.text); - BUILD_DIR/libultra.a:osMapTLB.o(.text); - BUILD_DIR/libultra.a:osUnmapTLBAll.o(.text); - BUILD_DIR/libultra.a:sprintf.o(.text); - BUILD_DIR/libultra.a:osCreateMesgQueue.o(.text); - BUILD_DIR/libultra.a:osSetEventMesg.o(.text); - BUILD_DIR/libultra.a:osViSetEvent.o(.text); - BUILD_DIR/libultra.a:osCreateThread.o(.text); - BUILD_DIR/libultra.a:osRecvMesg.o(.text); - BUILD_DIR/libultra.a:osSpTaskLoadGo.o(.text); - BUILD_DIR/libultra.a:osSpTaskYield.o(.text); - BUILD_DIR/libultra.a:osSendMesg.o(.text); - BUILD_DIR/libultra.a:osSpTaskYielded.o(.text); - BUILD_DIR/libultra.a:osStartThread.o(.text); - BUILD_DIR/libultra.a:osWritebackDCacheAll.o(.text); - BUILD_DIR/libultra.a:osCreateViManager.o(.text); - BUILD_DIR/libultra.a:osViSetMode.o(.text); - BUILD_DIR/libultra.a:osViBlack.o(.text); - BUILD_DIR/libultra.a:osViSetSpecialFeatures.o(.text); - BUILD_DIR/libultra.a:osCreatePiManager.o(.text); - BUILD_DIR/libultra.a:osSetThreadPri.o(.text); - BUILD_DIR/libultra.a:osInitialize.o(.text); - BUILD_DIR/libultra.a:osViSwapBuffer.o(.text); - BUILD_DIR/libultra.a:sqrtf.o(.text); - BUILD_DIR/libultra.a:osContStartReadData.o(.text); - BUILD_DIR/libultra.a:osContInit.o(.text); - BUILD_DIR/libultra.a:osEepromProbe.o(.text); -#if ENABLE_RUMBLE - BUILD_DIR/libultra.a:motor.o(.text); + . = ALIGN(0x1000); #endif - BUILD_DIR/libultra.a:llmuldiv.o(.text); - BUILD_DIR/libultra.a:llmuldiv_gcc.o(.text); - BUILD_DIR/libultra.a:osInvalDCache.o(.text); - BUILD_DIR/libultra.a:osPiStartDma.o(.text); - BUILD_DIR/libultra.a:bzero.o(.text); - BUILD_DIR/libultra.a:osInvalICache.o(.text); - BUILD_DIR/libultra.a:osEepromLongRead.o(.text); - BUILD_DIR/libultra.a:osEepromLongWrite.o(.text); - BUILD_DIR/libultra.a:bcopy.o(.text); - BUILD_DIR/libultra.a:guOrthoF.o(.text); - BUILD_DIR/libultra.a:guPerspectiveF.o(.text); - BUILD_DIR/libultra.a:osGetTime.o(.text); - BUILD_DIR/libultra.a:llconv.o(.text); - BUILD_DIR/libultra.a:cosf.o(.text); - BUILD_DIR/libultra.a:sinf.o(.text); - BUILD_DIR/libultra.a:guTranslateF.o(.text); - BUILD_DIR/libultra.a:guRotateF.o(.text); - BUILD_DIR/libultra.a:guScaleF.o(.text); - BUILD_DIR/libultra.a:osAiSetFrequency.o(.text); - BUILD_DIR/libultra.a:alBnkfNew.o(.text); - BUILD_DIR/libultra.a:osWritebackDCache.o(.text); - BUILD_DIR/libultra.a:osAiGetLength.o(.text); - BUILD_DIR/libultra.a:osAiSetNextBuffer.o(.text); - BUILD_DIR/libultra.a:osTimer.o(.text); - BUILD_DIR/libultra.a:_Printf.o(.text); - BUILD_DIR/libultra.a:string.o(.text); - BUILD_DIR/libultra.a:__osDequeueThread.o(.text); - BUILD_DIR/libultra.a:__osDisableInt.o(.text); - BUILD_DIR/libultra.a:__osRestoreInt.o(.text); - BUILD_DIR/libultra.a:__osViInit.o(.text); - BUILD_DIR/libultra.a:__osExceptionPreamble.o(.text); - BUILD_DIR/libultra.a:osVirtualToPhysical.o(.text); - BUILD_DIR/libultra.a:__osSpSetStatus.o(.text); - BUILD_DIR/libultra.a:__osSpSetPc.o(.text); - BUILD_DIR/libultra.a:__osSpRawStartDma.o(.text); - BUILD_DIR/libultra.a:__osSpDeviceBusy.o(.text); - BUILD_DIR/libultra.a:__osSpGetStatus.o(.text); - BUILD_DIR/libultra.a:osGetThreadPri.o(.text); - BUILD_DIR/libultra.a:__osViGetCurrentContext.o(.text); - BUILD_DIR/libultra.a:__osViSwapContext.o(.text); - BUILD_DIR/libultra.a:osGetCount.o(.text); - BUILD_DIR/libultra.a:__osPiCreateAccessQueue.o(.text); - BUILD_DIR/libultra.a:osPiRawStartDma.o(.text); - BUILD_DIR/libultra.a:__osDevMgrMain.o(.text); - BUILD_DIR/libultra.a:__osSetSR.o(.text); - BUILD_DIR/libultra.a:__osGetSR.o(.text); - BUILD_DIR/libultra.a:__osSetFpcCsr.o(.text); - BUILD_DIR/libultra.a:__osSiRawReadIo.o(.text); - BUILD_DIR/libultra.a:__osSiRawWriteIo.o(.text); - BUILD_DIR/libultra.a:osMapTLBRdb.o(.text); - BUILD_DIR/libultra.a:osPiRawReadIo.o(.text); +#if defined(VERSION_SH) || defined(VERSION_CN) + . += 0xB000; +#endif + BUILD_DIR/src/buffers/gfx_output_buffer.o(.bss*); + } + END_NOLOAD(buffers) + + /* lib/src/__osDevMgrMain.c and lib/src/osCreateViManager.c contain infinite + * loops compiled without -g, which cause the return statements and the .o + * files themselves to be aligned to 32-byte boundaries. But the linker + * Nintendo used did not respect .o file alignment, and aligned the files + * only to 16 bytes, in some cases misaligning them. We force the same to + * happen using the SUBALIGN directive. This is harmless; the alignment is + * just an optimization. */ + BEGIN_SEG(main, ) +#ifndef VERSION_CN + SUBALIGN(16) +#endif + { + BUILD_DIR/asm/entry.o(.text); + BUILD_DIR/src/game/crash_screen.o(.text); + BUILD_DIR/src/game/main.o(.text); + BUILD_DIR/src/game/game_init.o(.text); +#ifdef VERSION_CN + . += 0x10; +#endif + BUILD_DIR/src/game/sound_init.o(.text); +#if ENABLE_RUMBLE + BUILD_DIR/src/game/rumble_init.o(.text); +#endif + BUILD_DIR/src/game/level_update.o(.text); + BUILD_DIR/src/game/interaction.o(.text); + BUILD_DIR/src/game/mario.o(.text); + BUILD_DIR/src/game/mario_step.o(.text); + BUILD_DIR/src/game/mario_actions_cutscene.o(.text); + BUILD_DIR/src/game/mario_actions_automatic.o(.text); + BUILD_DIR/src/game/mario_actions_stationary.o(.text); + BUILD_DIR/src/game/mario_actions_moving.o(.text); + BUILD_DIR/src/game/mario_actions_airborne.o(.text); + BUILD_DIR/src/game/mario_actions_submerged.o(.text); + BUILD_DIR/src/game/mario_actions_object.o(.text); + BUILD_DIR/src/game/level_geo.o(.text); + BUILD_DIR/src/game/mario_misc.o(.text); + BUILD_DIR/src/game/memory.o(.text); + BUILD_DIR/src/game/save_file.o(.text); + BUILD_DIR/src/game/area.o(.text); + BUILD_DIR/src/game/rendering_graph_node.o(.text); + BUILD_DIR/src/game/profiler.o(.text); + BUILD_DIR/asm/decompress.o(.text); + BUILD_DIR/src/game/camera.o(.text); + BUILD_DIR/src/game/debug_course.o(.text); + BUILD_DIR/src/game/object_list_processor.o(.text); +#ifndef VERSION_EU + BUILD_DIR/src/game/object_helpers.o(.text); +#endif + BUILD_DIR/src/game/behavior_actions.o(.text); + BUILD_DIR/src/game/platform_displacement.o(.text); +#ifndef VERSION_EU + BUILD_DIR/src/game/object_collision.o(.text); + BUILD_DIR/src/game/spawn_object.o(.text); +#endif + BUILD_DIR/src/game/spawn_sound.o(.text); + BUILD_DIR/src/game/debug.o(.text); + BUILD_DIR/src/game/screen_transition.o(.text); + BUILD_DIR/src/game/shadow.o(.text); + BUILD_DIR/src/game/skybox.o(.text); + BUILD_DIR/src/game/moving_texture.o(.text); + BUILD_DIR/src/game/geo_misc.o(.text); + BUILD_DIR/src/game/paintings.o(.text); + BUILD_DIR/src/game/print.o(.text); + BUILD_DIR/src/game/ingame_menu.o(.text); + BUILD_DIR/src/game/envfx_snow.o(.text); + BUILD_DIR/src/game/envfx_bubbles.o(.text); + BUILD_DIR/src/game/macro_special_objects.o(.text); + BUILD_DIR/src/game/hud.o(.text); + BUILD_DIR/src/game/obj_behaviors.o(.text); + BUILD_DIR/src/game/obj_behaviors_2.o(.text); +#if defined(VERSION_SH) || defined(VERSION_CN) + BUILD_DIR/src/audio/synthesis_sh.o(.text); +#else + BUILD_DIR/src/audio/synthesis.o(.text); +#endif + BUILD_DIR/src/audio/heap.o(.text); + BUILD_DIR/src/audio/load.o(.text); +#if defined(VERSION_SH) || defined(VERSION_CN) + BUILD_DIR/src/audio/load_sh.o(.text); + BUILD_DIR/src/audio/port_sh.o(.text); +#endif + BUILD_DIR/src/audio/playback.o(.text); + BUILD_DIR/src/audio/effects.o(.text); + BUILD_DIR/src/audio/seqplayer.o(.text); +#if defined(VERSION_SH) || defined(VERSION_CN) + BUILD_DIR/libultra.a:osDriveRomInit.o(.text); +#endif + BUILD_DIR/src/audio/external.o(.text); + BUILD_DIR/src/audio/port_eu.o(.text); + +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) +#ifdef VERSION_CN + BUILD_DIR/libultra.a:osInitializeIQueWrapper.o(.text); + BUILD_DIR/libultra.a:osAiGetLength.o(.text); + BUILD_DIR/libultra.a:osAiSetFrequency.o(.text); + BUILD_DIR/libultra.a:osAiSetNextBuffer.o(.text); + BUILD_DIR/libultra.a:osInvalDCache.o(.text); + BUILD_DIR/libultra.a:osInvalICache.o(.text); + BUILD_DIR/libultra.a:osWritebackDCacheAll.o(.text); + BUILD_DIR/libultra.a:osContStartReadData.o(.text); + BUILD_DIR/libultra.a:osContInit.o(.text); + BUILD_DIR/libultra.a:osVirtualToPhysical.o(.text); + BUILD_DIR/libultra.a:sqrtf.o(.text); + BUILD_DIR/libultra.a:cosf.o(.text); + BUILD_DIR/libultra.a:guOrthoF.o(.text); + BUILD_DIR/libultra.a:guPerspectiveF.o(.text); + BUILD_DIR/libultra.a:sinf.o(.text); + BUILD_DIR/libultra.a:bcopy.o(.text); + BUILD_DIR/libultra.a:bzero.o(.text); + BUILD_DIR/libultra.a:llmuldiv.o(.text); + BUILD_DIR/libultra.a:llconv.o(.text); +#endif + BUILD_DIR/libultra.a:string.o(.text); + BUILD_DIR/libultra.a:_Printf.o(.text); +#ifdef VERSION_CN + BUILD_DIR/libultra.a:sprintf.o(.text); + BUILD_DIR/libultra.a:osSyncPrintf.o(.text); + BUILD_DIR/libultra.a:osCreateMesgQueue.o(.text); + BUILD_DIR/libultra.a:osRecvMesg.o(.text); + BUILD_DIR/libultra.a:osSendMesg.o(.text); + BUILD_DIR/libultra.a:osSetEventMesg.o(.text); + BUILD_DIR/libultra.a:osGetCount.o(.text); + BUILD_DIR/libultra.a:osSpTaskLoadGo.o(.text); + BUILD_DIR/libultra.a:osSpTaskYield.o(.text); + BUILD_DIR/libultra.a:osSpTaskYielded.o(.text); + BUILD_DIR/libultra.a:__osSiRawStartDma.o(.text); + BUILD_DIR/libultra.a:__osSiCreateAccessQueue.o(.text); + BUILD_DIR/libultra.a:osCreateThread.o(.text); + BUILD_DIR/libultra.a:osSetThreadPri.o(.text); + BUILD_DIR/libultra.a:osStartThread.o(.text); + BUILD_DIR/libultra.a:__osDequeueThread.o(.text); + BUILD_DIR/libultra.a:__osGetCurrFaultedThread.o(.text); + BUILD_DIR/libultra.a:osGetTime.o(.text); + BUILD_DIR/libultra.a:osSetTime.o(.text); + BUILD_DIR/libultra.a:osSetTimer.o(.text); + BUILD_DIR/libultra.a:osTimer.o(.text); + BUILD_DIR/libultra.a:osMapTLB.o(.text); + BUILD_DIR/libultra.a:__osProbeTLB.o(.text); + BUILD_DIR/libultra.a:osUnmapTLBAll.o(.text); + BUILD_DIR/libultra.a:osCreateViManager.o(.text); + BUILD_DIR/libultra.a:osViSetEvent.o(.text); + BUILD_DIR/libultra.a:osViSetMode.o(.text); + BUILD_DIR/libultra.a:osViSetSpecialFeatures.o(.text); + BUILD_DIR/libultra.a:osViSwapBuffer.o(.text); + BUILD_DIR/libultra.a:__osViSwapContext.o(.text); + BUILD_DIR/libultra.a:osViBlack.o(.text); + BUILD_DIR/libultra.a:guMtxIdentF.o(.text); + BUILD_DIR/libultra.a:guMtxF2L.o(.text); + BUILD_DIR/libultra.a:guScale.o(.text); + BUILD_DIR/libultra.a:guTranslate.o(.text); + BUILD_DIR/libultra.a:guRotateF.o(.text); + BUILD_DIR/libultra.a:osEepromProbe.o(.text); + BUILD_DIR/libultra.a:osEepromLongWrite.o(.text); + BUILD_DIR/libultra.a:osEepromLongRead.o(.text); + BUILD_DIR/libultra.a:__osExceptionPreamble.o(.text); + BUILD_DIR/libultra.a:__osDisableInt.o(.text); + BUILD_DIR/libultra.a:__osRestoreInt.o(.text); + BUILD_DIR/libultra.a:osSetIntMask.o(.text); + BUILD_DIR/libultra.a:osCreatePiManager.o(.text); + BUILD_DIR/libultra.a:osEPiRawStartDma.o(.text); + BUILD_DIR/libultra.a:epidma.o(.text); + BUILD_DIR/libultra.a:osCartRomInit.o(.text); + BUILD_DIR/libultra.a:__osDevMgrMain.o(.text); + BUILD_DIR/libultra.a:__osPiCreateAccessQueue.o(.text); + BUILD_DIR/libultra.a:osPiStartDma.o(.text); + BUILD_DIR/libultra.a:iQueKernelCalls.o(.text); + BUILD_DIR/libultra.a:motor.o(.text); + BUILD_DIR/libultra.a:parameters.o(.text); + BUILD_DIR/libultra.a:osInitialize.o(.text); + BUILD_DIR/libultra.a:__osAiDeviceBusy.o(.text); + BUILD_DIR/libultra.a:osWritebackDCache.o(.text); + BUILD_DIR/libultra.a:_Litob.o(.text); + BUILD_DIR/libultra.a:_Ldtob.o(.text); + BUILD_DIR/libultra.a:osJamMesg.o(.text); + BUILD_DIR/libultra.a:__osGetCause.o(.text); + BUILD_DIR/libultra.a:__osGetSR.o(.text); + BUILD_DIR/libultra.a:__osSetFpcCsr.o(.text); + BUILD_DIR/libultra.a:__osSetSR.o(.text); + BUILD_DIR/libultra.a:__osSetWatchLo.o(.text); + BUILD_DIR/libultra.a:__osSetCompare.o(.text); + BUILD_DIR/libultra.a:__osSpDeviceBusy.o(.text); + BUILD_DIR/libultra.a:__osSpGetStatus.o(.text); + BUILD_DIR/libultra.a:__osSpSetStatus.o(.text); + BUILD_DIR/libultra.a:__osSpSetPc.o(.text); + BUILD_DIR/libultra.a:__osSpRawStartDma.o(.text); + BUILD_DIR/libultra.a:__osSiRawReadIo.o(.text); + BUILD_DIR/libultra.a:__osSiRawWriteIo.o(.text); + BUILD_DIR/libultra.a:osDestroyThread.o(.text); + BUILD_DIR/libultra.a:osGetThreadPri.o(.text); + BUILD_DIR/libultra.a:osYieldThread.o(.text); + BUILD_DIR/libultra.a:osMapTLBRdb.o(.text); + BUILD_DIR/libultra.a:__osViInit.o(.text); + BUILD_DIR/libultra.a:__osViGetCurrentContext.o(.text); + BUILD_DIR/libultra.a:guNormalize.o(.text); + BUILD_DIR/libultra.a:osEepromRead.o(.text); + BUILD_DIR/libultra.a:osEepromWrite.o(.text); + BUILD_DIR/libultra.a:__osSetGlobalIntMask.o(.text); + BUILD_DIR/libultra.a:__osResetGlobalIntMask.o(.text); + BUILD_DIR/libultra.a:osPiRawStartDma.o(.text); + BUILD_DIR/libultra.a:osPiGetCmdQueue.o(.text); + BUILD_DIR/libultra.a:osEPiRawReadIo.o(.text); + BUILD_DIR/libultra.a:osEPiRawWriteIo.o(.text); + BUILD_DIR/libultra.a:ldiv.o(.text); + BUILD_DIR/libultra.a:__osSiDeviceBusy.o(.text); +#endif +#ifndef VERSION_CN + BUILD_DIR/libultra.a:llmuldiv.o(.text); + BUILD_DIR/libultra.a:osInitialize.o(.text); + BUILD_DIR/libultra.a:osSetTime.o(.text); + BUILD_DIR/libultra.a:osGetTime.o(.text); + BUILD_DIR/libultra.a:osWritebackDCacheAll.o(.text); + BUILD_DIR/libultra.a:osViBlack.o(.text); + BUILD_DIR/libultra.a:osViSwapBuffer.o(.text); + BUILD_DIR/libultra.a:__osGetCurrFaultedThread.o(.text); + BUILD_DIR/libultra.a:osSetEventMesg.o(.text); + BUILD_DIR/libultra.a:osRecvMesg.o(.text); + BUILD_DIR/libultra.a:parameters.o(.text); + BUILD_DIR/libultra.a:osCreateMesgQueue.o(.text); + BUILD_DIR/libultra.a:osCreateThread.o(.text); + BUILD_DIR/libultra.a:osStartThread.o(.text); + BUILD_DIR/libultra.a:osMapTLB.o(.text); + BUILD_DIR/libultra.a:osUnmapTLBAll.o(.text); + BUILD_DIR/libultra.a:sprintf.o(.text); + BUILD_DIR/libultra.a:osViSetEvent.o(.text); + BUILD_DIR/libultra.a:osSpTaskLoadGo.o(.text); + BUILD_DIR/libultra.a:osSpTaskYield.o(.text); + BUILD_DIR/libultra.a:osSendMesg.o(.text); + BUILD_DIR/libultra.a:osSpTaskYielded.o(.text); + BUILD_DIR/libultra.a:osCreateViManager.o(.text); + BUILD_DIR/libultra.a:osViSetMode.o(.text); + BUILD_DIR/libultra.a:osViSetSpecialFeatures.o(.text); + BUILD_DIR/libultra.a:osCreatePiManager.o(.text); + BUILD_DIR/libultra.a:osSetThreadPri.o(.text); + BUILD_DIR/libultra.a:sqrtf.o(.text); + BUILD_DIR/libultra.a:osContStartReadData.o(.text); + BUILD_DIR/libultra.a:osContInit.o(.text); + BUILD_DIR/libultra.a:osEepromProbe.o(.text); +#if ENABLE_RUMBLE + BUILD_DIR/libultra.a:motor.o(.text); +#endif + BUILD_DIR/libultra.a:osInvalDCache.o(.text); + BUILD_DIR/libultra.a:osPiStartDma.o(.text); + BUILD_DIR/libultra.a:bzero.o(.text); + BUILD_DIR/libultra.a:osInvalICache.o(.text); + BUILD_DIR/libultra.a:osEepromLongRead.o(.text); + BUILD_DIR/libultra.a:osEepromLongWrite.o(.text); + BUILD_DIR/libultra.a:bcopy.o(.text); + BUILD_DIR/libultra.a:guOrthoF.o(.text); + BUILD_DIR/libultra.a:guPerspectiveF.o(.text); + BUILD_DIR/libultra.a:llconv.o(.text); + BUILD_DIR/libultra.a:cosf.o(.text); + BUILD_DIR/libultra.a:sinf.o(.text); + BUILD_DIR/libultra.a:guTranslateF.o(.text); + BUILD_DIR/libultra.a:guRotateF.o(.text); + BUILD_DIR/libultra.a:guScaleF.o(.text); + BUILD_DIR/libultra.a:osAiSetFrequency.o(.text); +#endif +#ifdef VERSION_SH + BUILD_DIR/libultra.a:osCartRomInit.o(.text); + BUILD_DIR/libultra.a:epidma.o(.text); +#endif +#ifdef VERSION_EU + BUILD_DIR/libultra.a:alBnkfNew.o(.text); +#endif +#ifndef VERSION_CN + BUILD_DIR/libultra.a:osAiGetLength.o(.text); + BUILD_DIR/libultra.a:osAiSetNextBuffer.o(.text); +#endif +#ifdef VERSION_SH + BUILD_DIR/libultra.a:osGetCount.o(.text); + BUILD_DIR/libultra.a:__osDisableInt.o(.text); + BUILD_DIR/libultra.a:__osRestoreInt.o(.text); +#endif +#ifndef VERSION_CN + BUILD_DIR/libultra.a:_Litob.o(.text); + BUILD_DIR/libultra.a:_Ldtob.o(.text); + BUILD_DIR/libultra.a:__osSetSR.o(.text); + BUILD_DIR/libultra.a:__osGetSR.o(.text); + BUILD_DIR/libultra.a:__osSetFpcCsr.o(.text); + BUILD_DIR/libultra.a:__osSiRawReadIo.o(.text); + BUILD_DIR/libultra.a:__osSiRawWriteIo.o(.text); + BUILD_DIR/libultra.a:__osExceptionPreamble.o(.text); + BUILD_DIR/libultra.a:osWritebackDCache.o(.text); + BUILD_DIR/libultra.a:osMapTLBRdb.o(.text); +#endif + BUILD_DIR/libultra.a:osPiRawReadIo.o(.text); + BUILD_DIR/libultra.a:__osSetHWintrRoutine.o(.text); +#ifdef VERSION_EU + BUILD_DIR/libultra.a:leointerrupt.o(.text); +#endif +#ifndef VERSION_CN + BUILD_DIR/libultra.a:osTimer.o(.text); +#endif +#ifdef VERSION_EU + BUILD_DIR/libultra.a:__osDisableInt.o(.text); + BUILD_DIR/libultra.a:__osRestoreInt.o(.text); + BUILD_DIR/libultra.a:osGetCount.o(.text); +#endif +#ifndef VERSION_CN + BUILD_DIR/libultra.a:__osViInit.o(.text); + BUILD_DIR/libultra.a:__osDequeueThread.o(.text); + BUILD_DIR/libultra.a:osVirtualToPhysical.o(.text); + BUILD_DIR/libultra.a:__osSpSetStatus.o(.text); + BUILD_DIR/libultra.a:__osSpSetPc.o(.text); + BUILD_DIR/libultra.a:__osSpRawStartDma.o(.text); + BUILD_DIR/libultra.a:__osSpDeviceBusy.o(.text); + BUILD_DIR/libultra.a:__osSpGetStatus.o(.text); + BUILD_DIR/libultra.a:osGetThreadPri.o(.text); + BUILD_DIR/libultra.a:__osViGetCurrentContext.o(.text); + BUILD_DIR/libultra.a:__osViSwapContext.o(.text); +#ifdef VERSION_SH + BUILD_DIR/libultra.a:osLeoDiskInit.o(.text); +#endif + BUILD_DIR/libultra.a:__osPiCreateAccessQueue.o(.text); + BUILD_DIR/libultra.a:osPiRawStartDma.o(.text); + BUILD_DIR/libultra.a:osEPiRawStartDma.o(.text); + BUILD_DIR/libultra.a:__osDevMgrMain.o(.text); + BUILD_DIR/libultra.a:__osSiCreateAccessQueue.o(.text); + BUILD_DIR/libultra.a:__osSiRawStartDma.o(.text); + BUILD_DIR/libultra.a:osSetTimer.o(.text); + BUILD_DIR/libultra.a:osEepromWrite.o(.text); +#endif +#if ENABLE_RUMBLE + BUILD_DIR/libultra.a:osPfsIsPlug.o(.text); + BUILD_DIR/libultra.a:crc.o(.text); + BUILD_DIR/libultra.a:contramwrite.o(.text); + BUILD_DIR/libultra.a:contramread.o(.text); +#endif +#ifndef VERSION_CN + BUILD_DIR/libultra.a:osJamMesg.o(.text); + BUILD_DIR/libultra.a:osPiGetCmdQueue.o(.text); + BUILD_DIR/libultra.a:osEepromRead.o(.text); + BUILD_DIR/libultra.a:guMtxF2L.o(.text); + BUILD_DIR/libultra.a:guNormalize.o(.text); + BUILD_DIR/libultra.a:__osAiDeviceBusy.o(.text); + BUILD_DIR/libultra.a:ldiv.o(.text); + BUILD_DIR/libultra.a:__osSiDeviceBusy.o(.text); +#endif +#ifdef VERSION_SH + BUILD_DIR/libultra.a:leointerrupt.o(.text); +#endif + BUILD_DIR/libultra.a:osSetIntMask.o(.text); +#ifndef VERSION_CN + BUILD_DIR/libultra.a:osDestroyThread.o(.text); +#endif +#ifdef VERSION_EU + BUILD_DIR/libultra.a:osLeoDiskInit.o(.text); +#endif +#ifndef VERSION_CN + BUILD_DIR/libultra.a:__osSetCompare.o(.text); + BUILD_DIR/libultra.a:__osProbeTLB.o(.text); + BUILD_DIR/libultra.a:__osResetGlobalIntMask.o(.text); + BUILD_DIR/libultra.a:osEPiRawWriteIo.o(.text); +#endif +#ifdef VERSION_SH + BUILD_DIR/libultra.a:osEPiRawReadIo.o(.text); + BUILD_DIR/libultra.a:__osSetGlobalIntMask.o(.text); +#endif +#ifndef VERSION_CN + BUILD_DIR/libultra.a:osYieldThread.o(.text); +#endif +#if ENABLE_RUMBLE + BUILD_DIR/libultra.a:pfsgetstatus.o(.text); +#endif +#ifdef VERSION_CN + BUILD_DIR/libgcc.a:_divdi3.o(.text); + BUILD_DIR/libgcc.a:_moddi3.o(.text); + BUILD_DIR/libgcc.a:_udivdi3.o(.text); + BUILD_DIR/libgcc.a:_umoddi3.o(.text); + BUILD_DIR/libgcc.a:_cmpdi2.o(.text); + BUILD_DIR/libgcc.a:_floatdidf.o(.text); + BUILD_DIR/libgcc.a:_floatdisf.o(.text); + BUILD_DIR/libgcc.a:_fixunsdfdi.o(.text); + BUILD_DIR/libgcc.a:_fixdfdi.o(.text); + BUILD_DIR/libgcc.a:_fixunssfdi.o(.text); + BUILD_DIR/libgcc.a:_fixsfdi.o(.text); +#endif + BUILD_DIR/lib/rsp.o(.text); +#else + BUILD_DIR/src/game*.o(.text); + BUILD_DIR/src/audio*.o(.text); + BUILD_DIR/libultra.a:parameters.o(.text); + BUILD_DIR/libultra.a:osSetTime.o(.text); + BUILD_DIR/libultra.a:osMapTLB.o(.text); + BUILD_DIR/libultra.a:osUnmapTLBAll.o(.text); + BUILD_DIR/libultra.a:sprintf.o(.text); + BUILD_DIR/libultra.a:osCreateMesgQueue.o(.text); + BUILD_DIR/libultra.a:osSetEventMesg.o(.text); + BUILD_DIR/libultra.a:osViSetEvent.o(.text); + BUILD_DIR/libultra.a:osCreateThread.o(.text); + BUILD_DIR/libultra.a:osRecvMesg.o(.text); + BUILD_DIR/libultra.a:osSpTaskLoadGo.o(.text); + BUILD_DIR/libultra.a:osSpTaskYield.o(.text); + BUILD_DIR/libultra.a:osSendMesg.o(.text); + BUILD_DIR/libultra.a:osSpTaskYielded.o(.text); + BUILD_DIR/libultra.a:osStartThread.o(.text); + BUILD_DIR/libultra.a:osWritebackDCacheAll.o(.text); + BUILD_DIR/libultra.a:osCreateViManager.o(.text); + BUILD_DIR/libultra.a:osViSetMode.o(.text); + BUILD_DIR/libultra.a:osViBlack.o(.text); + BUILD_DIR/libultra.a:osViSetSpecialFeatures.o(.text); + BUILD_DIR/libultra.a:osCreatePiManager.o(.text); + BUILD_DIR/libultra.a:osSetThreadPri.o(.text); + BUILD_DIR/libultra.a:osInitialize.o(.text); + BUILD_DIR/libultra.a:osViSwapBuffer.o(.text); + BUILD_DIR/libultra.a:sqrtf.o(.text); + BUILD_DIR/libultra.a:osContStartReadData.o(.text); + BUILD_DIR/libultra.a:osContInit.o(.text); + BUILD_DIR/libultra.a:osEepromProbe.o(.text); +#if ENABLE_RUMBLE + BUILD_DIR/libultra.a:motor.o(.text); +#endif + BUILD_DIR/libultra.a:llmuldiv.o(.text); + BUILD_DIR/libultra.a:llmuldiv_gcc.o(.text); + BUILD_DIR/libultra.a:osInvalDCache.o(.text); + BUILD_DIR/libultra.a:osPiStartDma.o(.text); + BUILD_DIR/libultra.a:bzero.o(.text); + BUILD_DIR/libultra.a:osInvalICache.o(.text); + BUILD_DIR/libultra.a:osEepromLongRead.o(.text); + BUILD_DIR/libultra.a:osEepromLongWrite.o(.text); + BUILD_DIR/libultra.a:bcopy.o(.text); + BUILD_DIR/libultra.a:guOrthoF.o(.text); + BUILD_DIR/libultra.a:guPerspectiveF.o(.text); + BUILD_DIR/libultra.a:osGetTime.o(.text); + BUILD_DIR/libultra.a:llconv.o(.text); + BUILD_DIR/libultra.a:cosf.o(.text); + BUILD_DIR/libultra.a:sinf.o(.text); + BUILD_DIR/libultra.a:guTranslateF.o(.text); + BUILD_DIR/libultra.a:guRotateF.o(.text); + BUILD_DIR/libultra.a:guScaleF.o(.text); + BUILD_DIR/libultra.a:osAiSetFrequency.o(.text); + BUILD_DIR/libultra.a:alBnkfNew.o(.text); + BUILD_DIR/libultra.a:osWritebackDCache.o(.text); + BUILD_DIR/libultra.a:osAiGetLength.o(.text); + BUILD_DIR/libultra.a:osAiSetNextBuffer.o(.text); + BUILD_DIR/libultra.a:osTimer.o(.text); + BUILD_DIR/libultra.a:_Printf.o(.text); + BUILD_DIR/libultra.a:string.o(.text); + BUILD_DIR/libultra.a:__osDequeueThread.o(.text); + BUILD_DIR/libultra.a:__osDisableInt.o(.text); + BUILD_DIR/libultra.a:__osRestoreInt.o(.text); + BUILD_DIR/libultra.a:__osViInit.o(.text); + BUILD_DIR/libultra.a:__osExceptionPreamble.o(.text); + BUILD_DIR/libultra.a:osVirtualToPhysical.o(.text); + BUILD_DIR/libultra.a:__osSpSetStatus.o(.text); + BUILD_DIR/libultra.a:__osSpSetPc.o(.text); + BUILD_DIR/libultra.a:__osSpRawStartDma.o(.text); + BUILD_DIR/libultra.a:__osSpDeviceBusy.o(.text); + BUILD_DIR/libultra.a:__osSpGetStatus.o(.text); + BUILD_DIR/libultra.a:osGetThreadPri.o(.text); + BUILD_DIR/libultra.a:__osViGetCurrentContext.o(.text); + BUILD_DIR/libultra.a:__osViSwapContext.o(.text); + BUILD_DIR/libultra.a:osGetCount.o(.text); + BUILD_DIR/libultra.a:__osPiCreateAccessQueue.o(.text); + BUILD_DIR/libultra.a:osPiRawStartDma.o(.text); + BUILD_DIR/libultra.a:__osDevMgrMain.o(.text); + BUILD_DIR/libultra.a:__osSetSR.o(.text); + BUILD_DIR/libultra.a:__osGetSR.o(.text); + BUILD_DIR/libultra.a:__osSetFpcCsr.o(.text); + BUILD_DIR/libultra.a:__osSiRawReadIo.o(.text); + BUILD_DIR/libultra.a:__osSiRawWriteIo.o(.text); + BUILD_DIR/libultra.a:osMapTLBRdb.o(.text); + BUILD_DIR/libultra.a:osPiRawReadIo.o(.text); #ifdef VERSION_JP - . += 0x40; + . += 0x40; #endif - BUILD_DIR/libultra.a:__osSiCreateAccessQueue.o(.text); - BUILD_DIR/libultra.a:__osSiRawStartDma.o(.text); - BUILD_DIR/libultra.a:osSetTimer.o(.text); - BUILD_DIR/libultra.a:osEepromWrite.o(.text); + BUILD_DIR/libultra.a:__osSiCreateAccessQueue.o(.text); + BUILD_DIR/libultra.a:__osSiRawStartDma.o(.text); + BUILD_DIR/libultra.a:osSetTimer.o(.text); + BUILD_DIR/libultra.a:osEepromWrite.o(.text); #if ENABLE_RUMBLE - BUILD_DIR/libultra.a:osPfsIsPlug.o(.text); - BUILD_DIR/libultra.a:crc.o(.text); - BUILD_DIR/libultra.a:contramwrite.o(.text); - BUILD_DIR/libultra.a:contramread.o(.text); + BUILD_DIR/libultra.a:osPfsIsPlug.o(.text); + BUILD_DIR/libultra.a:crc.o(.text); + BUILD_DIR/libultra.a:contramwrite.o(.text); + BUILD_DIR/libultra.a:contramread.o(.text); #endif - BUILD_DIR/libultra.a:osJamMesg.o(.text); - BUILD_DIR/libultra.a:osPiGetCmdQueue.o(.text); - BUILD_DIR/libultra.a:osEepromRead.o(.text); - BUILD_DIR/libultra.a:guMtxF2L.o(.text); - BUILD_DIR/libultra.a:guMtxIdentF.o(.text); - BUILD_DIR/libultra.a:guNormalize.o(.text); - BUILD_DIR/libultra.a:__osAiDeviceBusy.o(.text); - BUILD_DIR/libultra.a:__osSetCompare.o(.text); - BUILD_DIR/libultra.a:_Litob.o(.text); - BUILD_DIR/libultra.a:_Ldtob.o(.text); - BUILD_DIR/libultra.a:kdebugserver.o(.text); - BUILD_DIR/libultra.a:__osSyncPutChars.o(.text); - BUILD_DIR/libultra.a:osSetIntMask.o(.text); - BUILD_DIR/libultra.a:osDestroyThread.o(.text); - BUILD_DIR/libultra.a:__osProbeTLB.o(.text); - BUILD_DIR/libultra.a:__osSiDeviceBusy.o(.text); - BUILD_DIR/libultra.a:ldiv.o(.text); - BUILD_DIR/libultra.a:__osGetCause.o(.text); - BUILD_DIR/libultra.a:__osAtomicDec.o(.text); - BUILD_DIR/libultra.a:guLookAtRef.o(.text); /* Fast3DEX2 only */ + BUILD_DIR/libultra.a:osJamMesg.o(.text); + BUILD_DIR/libultra.a:osPiGetCmdQueue.o(.text); + BUILD_DIR/libultra.a:osEepromRead.o(.text); + BUILD_DIR/libultra.a:guMtxF2L.o(.text); + BUILD_DIR/libultra.a:guMtxIdentF.o(.text); + BUILD_DIR/libultra.a:guNormalize.o(.text); + BUILD_DIR/libultra.a:__osAiDeviceBusy.o(.text); + BUILD_DIR/libultra.a:__osSetCompare.o(.text); + BUILD_DIR/libultra.a:_Litob.o(.text); + BUILD_DIR/libultra.a:_Ldtob.o(.text); + BUILD_DIR/libultra.a:kdebugserver.o(.text); + BUILD_DIR/libultra.a:__osSyncPutChars.o(.text); + BUILD_DIR/libultra.a:osSetIntMask.o(.text); + BUILD_DIR/libultra.a:osDestroyThread.o(.text); + BUILD_DIR/libultra.a:__osProbeTLB.o(.text); + BUILD_DIR/libultra.a:__osSiDeviceBusy.o(.text); + BUILD_DIR/libultra.a:ldiv.o(.text); + BUILD_DIR/libultra.a:__osGetCause.o(.text); + BUILD_DIR/libultra.a:__osAtomicDec.o(.text); + BUILD_DIR/libultra.a:guLookAtRef.o(.text); /* Fast3DEX2 only */ #if ENABLE_RUMBLE - BUILD_DIR/libultra.a:unk_shindou_file_3.o(.text); + BUILD_DIR/libultra.a:pfsgetstatus.o(.text); #endif - BUILD_DIR/lib/rsp.o(.text); + BUILD_DIR/lib/rsp.o(.text); #endif - /* data */ - BUILD_DIR/src/game/crash_screen.o(.data*); - BUILD_DIR/src/game/main.o(.data*); - BUILD_DIR/src/game/game_init.o(.data*); - BUILD_DIR/src/game/sound_init.o(.data*); + /* data */ + BUILD_DIR/src/game/crash_screen.o(.data*); + BUILD_DIR/src/game/main.o(.data*); + BUILD_DIR/src/game/game_init.o(.data*); + BUILD_DIR/src/game/sound_init.o(.data*); #if ENABLE_RUMBLE - BUILD_DIR/src/game/rumble_init.o(.data*); + BUILD_DIR/src/game/rumble_init.o(.data*); #endif - BUILD_DIR/src/game/level_update.o(.data*); - BUILD_DIR/src/game/interaction.o(.data*); - BUILD_DIR/src/game/mario.o(.data*); - BUILD_DIR/src/game/mario_step.o(.data*); - BUILD_DIR/src/game/mario_actions_cutscene.o(.data*); - BUILD_DIR/src/game/mario_actions_moving.o(.data*); - BUILD_DIR/src/game/mario_actions_submerged.o(.data*); - BUILD_DIR/src/game/mario_actions_object.o(.data*); - BUILD_DIR/src/game/mario_misc.o(.data*); - BUILD_DIR/src/game/memory.o(.data*); - BUILD_DIR/src/game/save_file.o(.data*); - BUILD_DIR/src/game/area.o(.data*); - BUILD_DIR/src/game/rendering_graph_node.o(.data*); - BUILD_DIR/src/game/profiler.o(.data*); - BUILD_DIR/src/game/camera.o(.data*); - BUILD_DIR/src/game/object_list_processor.o(.data*); + BUILD_DIR/src/game/level_update.o(.data*); + BUILD_DIR/src/game/interaction.o(.data*); + BUILD_DIR/src/game/mario.o(.data*); + BUILD_DIR/src/game/mario_step.o(.data*); + BUILD_DIR/src/game/mario_actions_cutscene.o(.data*); + BUILD_DIR/src/game/mario_actions_moving.o(.data*); + BUILD_DIR/src/game/mario_actions_submerged.o(.data*); + BUILD_DIR/src/game/mario_actions_object.o(.data*); + BUILD_DIR/src/game/mario_misc.o(.data*); + BUILD_DIR/src/game/memory.o(.data*); + BUILD_DIR/src/game/save_file.o(.data*); + BUILD_DIR/src/game/area.o(.data*); + BUILD_DIR/src/game/rendering_graph_node.o(.data*); + BUILD_DIR/src/game/profiler.o(.data*); + BUILD_DIR/src/game/camera.o(.data*); + BUILD_DIR/src/game/object_list_processor.o(.data*); #ifndef VERSION_EU - BUILD_DIR/src/game/object_helpers.o(.data*); + BUILD_DIR/src/game/object_helpers.o(.data*); #endif - BUILD_DIR/src/game/behavior_actions.o(.data*); - BUILD_DIR/src/game/platform_displacement.o(.data*); - BUILD_DIR/src/game/spawn_sound.o(.data*); - BUILD_DIR/src/game/debug.o(.data*); - BUILD_DIR/src/game/screen_transition.o(.data*); - BUILD_DIR/src/game/shadow.o(.data*); - BUILD_DIR/src/game/skybox.o(.data*); - BUILD_DIR/src/game/moving_texture.o(.data*); - BUILD_DIR/src/game/geo_misc.o(.data*); - BUILD_DIR/src/game/paintings.o(.data*); - BUILD_DIR/src/game/print.o(.data*); - BUILD_DIR/src/game/ingame_menu.o(.data*); - BUILD_DIR/src/game/envfx_snow.o(.data*); - BUILD_DIR/src/game/envfx_bubbles.o(.data*); - BUILD_DIR/src/game/macro_special_objects.o(.data*); - BUILD_DIR/src/game/hud.o(.data*); - BUILD_DIR/src/game/obj_behaviors.o(.data*); - BUILD_DIR/src/game/obj_behaviors_2.o(.data*); + BUILD_DIR/src/game/behavior_actions.o(.data*); + BUILD_DIR/src/game/platform_displacement.o(.data*); + BUILD_DIR/src/game/spawn_sound.o(.data*); + BUILD_DIR/src/game/debug.o(.data*); + BUILD_DIR/src/game/screen_transition.o(.data*); + BUILD_DIR/src/game/shadow.o(.data*); + BUILD_DIR/src/game/skybox.o(.data*); + BUILD_DIR/src/game/moving_texture.o(.data*); + BUILD_DIR/src/game/geo_misc.o(.data*); + BUILD_DIR/src/game/paintings.o(.data*); + BUILD_DIR/src/game/print.o(.data*); + BUILD_DIR/src/game/ingame_menu.o(.data*); + BUILD_DIR/src/game/envfx_snow.o(.data*); + BUILD_DIR/src/game/envfx_bubbles.o(.data*); + BUILD_DIR/src/game/macro_special_objects.o(.data*); + BUILD_DIR/src/game/hud.o(.data*); + BUILD_DIR/src/game/obj_behaviors.o(.data*); + BUILD_DIR/src/game/obj_behaviors_2.o(.data*); #ifndef VERSION_EU - /* wildcard doesn't match on EU due to files being moved to engine/ */ - BUILD_DIR/src/game*.o(.data*); + /* wildcard doesn't match on EU due to files being moved to engine/ */ + BUILD_DIR/src/game*.o(.data*); #endif -#ifdef VERSION_SH - BUILD_DIR/src/audio/synthesis_sh.o(.data*); +#if defined(VERSION_SH) || defined(VERSION_CN) + BUILD_DIR/src/audio/synthesis_sh.o(.data*); #else - BUILD_DIR/src/audio/synthesis.o(.data*); + BUILD_DIR/src/audio/synthesis.o(.data*); #endif - BUILD_DIR/src/audio/heap.o(.data*); - BUILD_DIR/src/audio/load.o(.data*); - BUILD_DIR/src/audio/playback.o(.data*); - BUILD_DIR/src/audio/effects.o(.data*); - BUILD_DIR/src/audio/seqplayer.o(.data*); -#ifdef VERSION_SH - BUILD_DIR/src/audio/data.o(.data*); - BUILD_DIR/src/audio/shindou_debug_prints.o(.data*); - BUILD_DIR/src/audio/port_sh.o(.data*); - BUILD_DIR/src/audio/external.o(.data*); - BUILD_DIR/src/audio/audio_session_presets_sh.o(.data*); + BUILD_DIR/src/audio/heap.o(.data*); + BUILD_DIR/src/audio/load.o(.data*); + BUILD_DIR/src/audio/playback.o(.data*); + BUILD_DIR/src/audio/effects.o(.data*); + BUILD_DIR/src/audio/seqplayer.o(.data*); +#if defined(VERSION_SH) || defined(VERSION_CN) + BUILD_DIR/src/audio/data.o(.data*); + BUILD_DIR/src/audio/shindou_debug_prints.o(.data*); + BUILD_DIR/src/audio/port_sh.o(.data*); + BUILD_DIR/src/audio/external.o(.data*); + BUILD_DIR/src/audio/audio_session_presets_sh.o(.data*); #else - BUILD_DIR/src/audio/external.o(.data*); - BUILD_DIR/src/audio/port_eu.o(.data*); - BUILD_DIR/src/audio/data.o(.data*); + BUILD_DIR/src/audio/external.o(.data*); + BUILD_DIR/src/audio/port_eu.o(.data*); + BUILD_DIR/src/audio/data.o(.data*); #endif -#if defined(VERSION_EU) || defined(VERSION_SH) - BUILD_DIR/libultra.a:_Printf.o(.data*); - BUILD_DIR/libultra.a:osInitialize.o(.data*); - BUILD_DIR/libultra.a:osCreateViManager.o(.data*); - BUILD_DIR/libultra.a:osViTable.o(.data*); - BUILD_DIR/libultra.a:osCreatePiManager.o(.data*); - BUILD_DIR/libultra.a:osContInit.o(.data*); -#if ENABLE_RUMBLE - BUILD_DIR/libultra.a:motor.o(.data*); -#endif - BUILD_DIR/libultra.a:osAiSetNextBuffer.o(.data*); - BUILD_DIR/libultra.a:_Litob.o(.data*); - BUILD_DIR/libultra.a:__osExceptionPreamble.o(.data*); - BUILD_DIR/libultra.a:osTimer.o(.data*); - BUILD_DIR/libultra.a:__osViInit.o(.data*); - BUILD_DIR/libultra.a:__osDequeueThread.o(.data*); - BUILD_DIR/libultra.a:__osPiCreateAccessQueue.o(.data*); - BUILD_DIR/libultra.a:__osSiCreateAccessQueue.o(.data*); - BUILD_DIR/libultra.a:osViData.o(.data*); -#else - BUILD_DIR/libultra.a:osViTable.o(.data*); - BUILD_DIR/libultra.a:osCreateViManager.o(.data*); - BUILD_DIR/libultra.a:osCreatePiManager.o(.data*); - BUILD_DIR/libultra.a:osInitialize.o(.data*); - BUILD_DIR/libultra.a:osContInit.o(.data*); -#if ENABLE_RUMBLE - BUILD_DIR/libultra.a:motor.o(.data*); -#endif - BUILD_DIR/libultra.a:osAiSetNextBuffer.o(.data*); - BUILD_DIR/libultra.a:osTimer.o(.data*); - BUILD_DIR/libultra.a:_Printf.o(.data*); - BUILD_DIR/libultra.a:__osDequeueThread.o(.data*); - BUILD_DIR/libultra.a:__osViInit.o(.data*); - BUILD_DIR/libultra.a:__osExceptionPreamble.o(.data*); - BUILD_DIR/libultra.a:__osPiCreateAccessQueue.o(.data*); - BUILD_DIR/libultra.a:__osSiCreateAccessQueue.o(.data*); - BUILD_DIR/libultra.a:_Litob.o(.data*); - BUILD_DIR/libultra.a:_Ldtob.o(.data*); - BUILD_DIR/libultra.a:osViData.o(.data*); - BUILD_DIR/libultra.a:kdebugserver.o(.data*); - BUILD_DIR/libultra.a:__osSyncPutChars.o(.data*); - BUILD_DIR/libultra.a:guRotateF.o(.data*); - BUILD_DIR/libultra.a:*.o(.data*); +#ifdef VERSION_CN + BUILD_DIR/libultra.a:osAiSetNextBuffer.o(.data*); + BUILD_DIR/libultra.a:osContInit.o(.data*); + BUILD_DIR/libultra.a:_Printf.o(.data*); + BUILD_DIR/libultra.a:osSetEventMesg.o(.data*); + BUILD_DIR/libultra.a:__osSiCreateAccessQueue.o(.data*); + BUILD_DIR/libultra.a:__osDequeueThread.o(.data*); + BUILD_DIR/libultra.a:osTimer.o(.data*); + BUILD_DIR/libultra.a:osCreateViManager.o(.data*); + BUILD_DIR/libultra.a:osViTable.o(.data*); + BUILD_DIR/libultra.a:guRotateF.o(.data*); + BUILD_DIR/libultra.a:__osExceptionPreamble.o(.data*); + BUILD_DIR/libultra.a:osCreatePiManager.o(.data*); + BUILD_DIR/libultra.a:osCartRomInit.o(.data*); + BUILD_DIR/libultra.a:__osPiCreateAccessQueue.o(.data*); + BUILD_DIR/libultra.a:osInitialize.o(.data*); + BUILD_DIR/libultra.a:_Litob.o(.data*); + BUILD_DIR/libultra.a:__osViInit.o(.data*); + BUILD_DIR/libultra.a:osViData.o(.data*); #endif - /* rodata */ - BUILD_DIR/src/game/crash_screen.o(.rodata*); - BUILD_DIR/src/game/main.o(.rodata*); - BUILD_DIR/src/game/game_init.o(.rodata*); - BUILD_DIR/src/game/sound_init.o(.rodata*); - BUILD_DIR/src/game/level_update.o(.rodata*); - BUILD_DIR/src/game/interaction.o(.rodata*); - BUILD_DIR/src/game/mario.o(.rodata*); - BUILD_DIR/src/game/mario_step.o(.rodata*); - BUILD_DIR/src/game/mario_actions_cutscene.o(.rodata*); - BUILD_DIR/src/game/mario_actions_automatic.o(.rodata*); - BUILD_DIR/src/game/mario_actions_stationary.o(.rodata*); - BUILD_DIR/src/game/mario_actions_moving.o(.rodata*); - BUILD_DIR/src/game/mario_actions_airborne.o(.rodata*); - BUILD_DIR/src/game/mario_actions_submerged.o(.rodata*); - BUILD_DIR/src/game/mario_actions_object.o(.rodata*); - BUILD_DIR/src/game/mario_misc.o(.rodata*); - BUILD_DIR/src/game/area.o(.rodata*); - BUILD_DIR/src/game/rendering_graph_node.o(.rodata*); - BUILD_DIR/src/game/camera.o(.rodata*); - BUILD_DIR/src/game/object_list_processor.o(.rodata*); -#ifndef VERSION_EU - BUILD_DIR/src/game/object_helpers.o(.rodata*); +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) + BUILD_DIR/libultra.a:_Printf.o(.data*); + BUILD_DIR/libultra.a:osInitialize.o(.data*); + BUILD_DIR/libultra.a:osCreateViManager.o(.data*); + BUILD_DIR/libultra.a:osViTable.o(.data*); + BUILD_DIR/libultra.a:osCreatePiManager.o(.data*); + BUILD_DIR/libultra.a:osContInit.o(.data*); +#if ENABLE_RUMBLE + BUILD_DIR/libultra.a:motor.o(.data*); #endif - BUILD_DIR/src/game/behavior_actions.o(.rodata*); -#ifndef VERSION_EU - BUILD_DIR/src/game/object_collision.o(.rodata*); - BUILD_DIR/src/game/spawn_object.o(.rodata*); + BUILD_DIR/libultra.a:osAiSetNextBuffer.o(.data*); + BUILD_DIR/libultra.a:_Litob.o(.data*); + BUILD_DIR/libultra.a:__osExceptionPreamble.o(.data*); + BUILD_DIR/libultra.a:osTimer.o(.data*); + BUILD_DIR/libultra.a:__osViInit.o(.data*); + BUILD_DIR/libultra.a:__osDequeueThread.o(.data*); + BUILD_DIR/libultra.a:__osPiCreateAccessQueue.o(.data*); + BUILD_DIR/libultra.a:__osSiCreateAccessQueue.o(.data*); + BUILD_DIR/libultra.a:osViData.o(.data*); +#else + BUILD_DIR/libultra.a:osViTable.o(.data*); + BUILD_DIR/libultra.a:osCreateViManager.o(.data*); + BUILD_DIR/libultra.a:osCreatePiManager.o(.data*); + BUILD_DIR/libultra.a:osInitialize.o(.data*); + BUILD_DIR/libultra.a:osContInit.o(.data*); +#if ENABLE_RUMBLE + BUILD_DIR/libultra.a:motor.o(.data*); #endif - BUILD_DIR/libultra.a:__osDisableInt.o(.text); - BUILD_DIR/libultra.a:__osRestoreInt.o(.text); - BUILD_DIR/src/game/spawn_sound.o(.rodata*); - BUILD_DIR/src/game/debug.o(.rodata*); - BUILD_DIR/src/game/screen_transition.o(.rodata*); - BUILD_DIR/src/game/shadow.o(.rodata*); - BUILD_DIR/src/game/skybox.o(.rodata*); - BUILD_DIR/src/game/moving_texture.o(.rodata*); - BUILD_DIR/src/game/geo_misc.o(.rodata*); - BUILD_DIR/src/game/paintings.o(.rodata*); - BUILD_DIR/src/game/print.o(.rodata*); - BUILD_DIR/src/game/ingame_menu.o(.rodata*); - BUILD_DIR/src/game/envfx_snow.o(.rodata*); - BUILD_DIR/src/game/envfx_bubbles.o(.rodata*); - BUILD_DIR/src/game/macro_special_objects.o(.rodata*); - BUILD_DIR/src/game/hud.o(.rodata*); - BUILD_DIR/src/game/obj_behaviors.o(.rodata*); - BUILD_DIR/src/game/obj_behaviors_2.o(.rodata*); + BUILD_DIR/libultra.a:osAiSetNextBuffer.o(.data*); + BUILD_DIR/libultra.a:osTimer.o(.data*); + BUILD_DIR/libultra.a:_Printf.o(.data*); + BUILD_DIR/libultra.a:__osDequeueThread.o(.data*); + BUILD_DIR/libultra.a:__osViInit.o(.data*); + BUILD_DIR/libultra.a:__osExceptionPreamble.o(.data*); + BUILD_DIR/libultra.a:__osPiCreateAccessQueue.o(.data*); + BUILD_DIR/libultra.a:__osSiCreateAccessQueue.o(.data*); + BUILD_DIR/libultra.a:_Litob.o(.data*); + BUILD_DIR/libultra.a:_Ldtob.o(.data*); + BUILD_DIR/libultra.a:osViData.o(.data*); + BUILD_DIR/libultra.a:kdebugserver.o(.data*); + BUILD_DIR/libultra.a:__osSyncPutChars.o(.data*); + BUILD_DIR/libultra.a:guRotateF.o(.data*); + BUILD_DIR/libultra.a:*.o(.data*); +#endif + + /* rodata */ + BUILD_DIR/src/game/crash_screen.o(.rodata*); + BUILD_DIR/src/game/main.o(.rodata*); + BUILD_DIR/src/game/game_init.o(.rodata*); + BUILD_DIR/src/game/sound_init.o(.rodata*); + BUILD_DIR/src/game/rumble_init.o(.rodata*); + BUILD_DIR/src/game/level_update.o(.rodata*); + BUILD_DIR/src/game/interaction.o(.rodata*); + BUILD_DIR/src/game/mario.o(.rodata*); + BUILD_DIR/src/game/mario_step.o(.rodata*); + BUILD_DIR/src/game/mario_actions_cutscene.o(.rodata*); + BUILD_DIR/src/game/mario_actions_automatic.o(.rodata*); + BUILD_DIR/src/game/mario_actions_stationary.o(.rodata*); + BUILD_DIR/src/game/mario_actions_moving.o(.rodata*); + BUILD_DIR/src/game/mario_actions_airborne.o(.rodata*); + BUILD_DIR/src/game/mario_actions_submerged.o(.rodata*); + BUILD_DIR/src/game/mario_actions_object.o(.rodata*); + BUILD_DIR/src/game/mario_misc.o(.rodata*); + BUILD_DIR/src/game/memory.o(.rodata*); + BUILD_DIR/src/game/area.o(.rodata*); + BUILD_DIR/src/game/rendering_graph_node.o(.rodata*); + BUILD_DIR/src/game/camera.o(.rodata*); + BUILD_DIR/src/game/object_list_processor.o(.rodata*); +#ifndef VERSION_EU + BUILD_DIR/src/game/object_helpers.o(.rodata*); +#endif + BUILD_DIR/src/game/behavior_actions.o(.rodata*); +#ifndef VERSION_EU + BUILD_DIR/src/game/object_collision.o(.rodata*); + BUILD_DIR/src/game/spawn_object.o(.rodata*); +#endif + BUILD_DIR/libultra.a:__osDisableInt.o(.text); + BUILD_DIR/libultra.a:__osRestoreInt.o(.text); + BUILD_DIR/src/game/spawn_sound.o(.rodata*); + BUILD_DIR/src/game/debug.o(.rodata*); + BUILD_DIR/src/game/screen_transition.o(.rodata*); + BUILD_DIR/src/game/shadow.o(.rodata*); + BUILD_DIR/src/game/skybox.o(.rodata*); + BUILD_DIR/src/game/moving_texture.o(.rodata*); + BUILD_DIR/src/game/geo_misc.o(.rodata*); + BUILD_DIR/src/game/paintings.o(.rodata*); + BUILD_DIR/src/game/print.o(.rodata*); + BUILD_DIR/src/game/ingame_menu.o(.rodata*); + BUILD_DIR/src/game/envfx_snow.o(.rodata*); + BUILD_DIR/src/game/envfx_bubbles.o(.rodata*); + BUILD_DIR/src/game/macro_special_objects.o(.rodata*); + BUILD_DIR/src/game/hud.o(.rodata*); + BUILD_DIR/src/game/obj_behaviors.o(.rodata*); + BUILD_DIR/src/game/obj_behaviors_2.o(.rodata*); #if defined(VERSION_JP) || defined(VERSION_US) - BUILD_DIR/src/game*.o(.rodata*); + BUILD_DIR/src/game*.o(.rodata*); #endif -#ifdef VERSION_SH - BUILD_DIR/src/audio/synthesis_sh.o(.rodata*); - BUILD_DIR/src/audio/heap.o(.rodata*); - BUILD_DIR/src/audio/load_sh.o(.rodata*); - BUILD_DIR/src/audio/port_sh.o(.rodata*); +#if defined(VERSION_SH) || defined(VERSION_CN) + BUILD_DIR/src/audio/synthesis_sh.o(.rodata*); + BUILD_DIR/src/audio/heap.o(.rodata*); + BUILD_DIR/src/audio/load_sh.o(.rodata*); + BUILD_DIR/src/audio/port_sh.o(.rodata*); #else - BUILD_DIR/src/audio/synthesis.o(.rodata*); - BUILD_DIR/src/audio/heap.o(.rodata*); - BUILD_DIR/src/audio/load.o(.rodata*); + BUILD_DIR/src/audio/synthesis.o(.rodata*); + BUILD_DIR/src/audio/heap.o(.rodata*); + BUILD_DIR/src/audio/load.o(.rodata*); #endif - BUILD_DIR/src/audio/playback.o(.rodata*); - BUILD_DIR/src/audio/effects.o(.rodata*); - BUILD_DIR/src/audio/seqplayer.o(.rodata*); - BUILD_DIR/src/audio/external.o(.rodata*); - BUILD_DIR/src/audio/port_eu.o(.rodata*); - BUILD_DIR/src/audio*.o(.rodata*); + BUILD_DIR/src/audio/playback.o(.rodata*); + BUILD_DIR/src/audio/effects.o(.rodata*); + BUILD_DIR/src/audio/seqplayer.o(.rodata*); + BUILD_DIR/src/audio/external.o(.rodata*); + BUILD_DIR/src/audio/port_eu.o(.rodata*); + BUILD_DIR/src/audio*.o(.rodata*); #if defined(VERSION_EU) || defined(VERSION_SH) - BUILD_DIR/libultra.a:_Printf.o(.rodata*); + BUILD_DIR/libultra.a:_Printf.o(.rodata*); #endif - BUILD_DIR/libultra.a:guPerspectiveF.o(.rodata*); - BUILD_DIR/libultra.a:llconv.o(.rodata*); - BUILD_DIR/libultra.a:cosf.o(.rodata*); - BUILD_DIR/libultra.a:sinf.o(.rodata*); - BUILD_DIR/libultra.a:guRotateF.o(.rodata*); +#ifndef VERSION_CN + BUILD_DIR/libultra.a:guPerspectiveF.o(.rodata*); +#endif + BUILD_DIR/libultra.a:llconv.o(.rodata*); + BUILD_DIR/libultra.a:cosf.o(.rodata*); +#ifdef VERSION_CN + BUILD_DIR/libultra.a:guPerspectiveF.o(.rodata*); +#endif + BUILD_DIR/libultra.a:sinf.o(.rodata*); + BUILD_DIR/libultra.a:guRotateF.o(.rodata*); #if defined(VERSION_EU) || defined(VERSION_SH) - BUILD_DIR/libultra.a:_Litob.o(.rodata*); - BUILD_DIR/libultra.a:_Ldtob.o(.rodata*); - BUILD_DIR/libultra.a:__osExceptionPreamble.o(.rodata*); - BUILD_DIR/libultra.a:__osDevMgrMain.o(.rodata*); - BUILD_DIR/libultra.a:NaN.o(.rodata*); + BUILD_DIR/libultra.a:_Litob.o(.rodata*); + BUILD_DIR/libultra.a:_Ldtob.o(.rodata*); + BUILD_DIR/libultra.a:__osExceptionPreamble.o(.rodata*); + BUILD_DIR/libultra.a:__osDevMgrMain.o(.rodata*); + BUILD_DIR/libultra.a:NaN.o(.rodata*); #else - BUILD_DIR/libultra.a:_Printf.o(.rodata*); - BUILD_DIR/libultra.a:__osExceptionPreamble.o(.rodata*); - BUILD_DIR/libultra.a:NaN.o(.rodata*); - BUILD_DIR/libultra.a:_Litob.o(.rodata*); - BUILD_DIR/libultra.a:_Ldtob.o(.rodata*); + BUILD_DIR/libultra.a:_Printf.o(.rodata*); + BUILD_DIR/libultra.a:__osExceptionPreamble.o(.rodata*); +#ifdef VERSION_CN + BUILD_DIR/libultra.a:osSetIntMask.o(.rodata*); + BUILD_DIR/libultra.a:__osDevMgrMain.o(.rodata*); +#endif + BUILD_DIR/libultra.a:NaN.o(.rodata*); + BUILD_DIR/libultra.a:_Litob.o(.rodata*); + BUILD_DIR/libultra.a:_Ldtob.o(.rodata*); #endif - BUILD_DIR/libultra.a:osSetIntMask.o(.rodata*); - BUILD_DIR/libultra.a:guLookAtRef.o(.rodata*); /* Fast3DEX2 only */ + BUILD_DIR/libultra.a:osSetIntMask.o(.rodata*); + BUILD_DIR/libultra.a:guLookAtRef.o(.rodata*); /* Fast3DEX2 only */ + +#ifdef VERSION_CN + BUILD_DIR/libgcc.a:_divdi3.o(.rodata*); + BUILD_DIR/libgcc.a:_moddi3.o(.rodata*); + BUILD_DIR/libgcc.a:_udivdi3.o(.rodata*); + BUILD_DIR/libgcc.a:_umoddi3.o(.rodata*); + BUILD_DIR/libgcc.a:_cmpdi2.o(.rodata*); + BUILD_DIR/libgcc.a:_floatdidf.o(.rodata*); + BUILD_DIR/libgcc.a:_floatdisf.o(.rodata*); + BUILD_DIR/libgcc.a:_fixunsdfdi.o(.rodata*); + BUILD_DIR/libgcc.a:_fixdfdi.o(.rodata*); + BUILD_DIR/libgcc.a:_fixunssfdi.o(.rodata*); + BUILD_DIR/libgcc.a:_fixsfdi.o(.rodata*); +#endif #ifndef VERSION_EU - BUILD_DIR/libultra.a:*.o(.rodata*); + BUILD_DIR/libultra.a:*.o(.rodata*); #endif - /* audio blobs, should really be moved into a separate file */ -#ifdef VERSION_SH - BUILD_DIR/src/audio/load_sh.o(.data*); + /* audio blobs, should really be moved into a separate file */ +#if defined(VERSION_SH) || defined(VERSION_CN) + BUILD_DIR/src/audio/load_sh.o(.data*); #endif - BUILD_DIR/lib/rsp.o(.rodata*); - } - END_SEG(main) - BEGIN_NOLOAD(main) - { - BUILD_DIR/src/game/crash_screen.o(.bss*); - BUILD_DIR/src/game/main.o(.bss*); - BUILD_DIR/src/game/game_init.o(.bss*); - BUILD_DIR/src/game/sound_init.o(.bss*); + BUILD_DIR/lib/rsp.o(.rodata*); + } + END_SEG(main) + + BEGIN_NOLOAD(main) + { + BUILD_DIR/src/game/cn_common_syms_1.o(.bss*); + BUILD_DIR/src/game/crash_screen.o(.bss*); + BUILD_DIR/src/game/main.o(.bss*); + BUILD_DIR/src/game/game_init.o(.bss*); + BUILD_DIR/src/game/sound_init.o(.bss*); #if ENABLE_RUMBLE - BUILD_DIR/src/game/rumble_init.o(.bss*); + BUILD_DIR/src/game/rumble_init.o(.bss*); #endif - BUILD_DIR/src/game/level_update.o(.bss*); - BUILD_DIR/src/game/interaction.o(.bss*); - BUILD_DIR/src/game/mario.o(.bss*); - BUILD_DIR/src/game/mario_actions_cutscene.o(.bss*); - BUILD_DIR/src/game/mario_actions_moving.o(.bss*); - BUILD_DIR/src/game/mario_actions_submerged.o(.bss*); - BUILD_DIR/src/game/mario_misc.o(.bss*); - BUILD_DIR/src/game/memory.o(.bss*); - BUILD_DIR/src/game/save_file.o(.bss*); - BUILD_DIR/src/game/area.o(.bss*); - BUILD_DIR/src/game/rendering_graph_node.o(.bss*); - BUILD_DIR/src/game/profiler.o(.bss*); - BUILD_DIR/src/game/camera.o(.bss*); - BUILD_DIR/src/game/object_list_processor.o(.bss*); + BUILD_DIR/src/game/level_update.o(.bss*); + BUILD_DIR/src/game/interaction.o(.bss*); + BUILD_DIR/src/game/mario.o(.bss*); + BUILD_DIR/src/game/mario_actions_cutscene.o(.bss*); + BUILD_DIR/src/game/mario_actions_moving.o(.bss*); + BUILD_DIR/src/game/mario_actions_submerged.o(.bss*); + BUILD_DIR/src/game/mario_misc.o(.bss*); + BUILD_DIR/src/game/memory.o(.bss*); + BUILD_DIR/src/game/save_file.o(.bss*); + BUILD_DIR/src/game/area.o(.bss*); + BUILD_DIR/src/game/rendering_graph_node.o(.bss*); + BUILD_DIR/src/game/profiler.o(.bss*); + BUILD_DIR/src/game/camera.o(.bss*); + BUILD_DIR/src/game/object_list_processor.o(.bss*); #ifndef VERSION_EU - BUILD_DIR/src/game/object_helpers.o(.bss*); + BUILD_DIR/src/game/object_helpers.o(.bss*); #endif - BUILD_DIR/src/game/behavior_actions.o(.bss*); - BUILD_DIR/src/game/debug.o(.bss*); - BUILD_DIR/src/game/shadow.o(.bss*); - BUILD_DIR/src/game/skybox.o(.bss*); - BUILD_DIR/src/game/moving_texture.o(.bss*); - BUILD_DIR/src/game/geo_misc.o(.bss*); - BUILD_DIR/src/game/paintings.o(.bss*); - BUILD_DIR/src/game/print.o(.bss*); - BUILD_DIR/src/game/ingame_menu.o(.bss*); - BUILD_DIR/src/game/envfx_snow.o(.bss*); - BUILD_DIR/src/game/envfx_bubbles.o(.bss*); - BUILD_DIR/src/game/macro_special_objects.o(.bss*); - BUILD_DIR/src/game/hud.o(.bss*); - BUILD_DIR/src/game/obj_behaviors.o(.bss*); - BUILD_DIR/src/game/obj_behaviors_2.o(.bss*); -#ifndef VERSION_EU - BUILD_DIR/src/game*.o(.bss*); + BUILD_DIR/src/game/behavior_actions.o(.bss*); + BUILD_DIR/src/game/debug.o(.bss*); + BUILD_DIR/src/game/shadow.o(.bss*); + BUILD_DIR/src/game/skybox.o(.bss*); + BUILD_DIR/src/game/moving_texture.o(.bss*); + BUILD_DIR/src/game/geo_misc.o(.bss*); + BUILD_DIR/src/game/paintings.o(.bss*); + BUILD_DIR/src/game/print.o(.bss*); + BUILD_DIR/src/game/ingame_menu.o(.bss*); + BUILD_DIR/src/game/envfx_snow.o(.bss*); + BUILD_DIR/src/game/envfx_bubbles.o(.bss*); + BUILD_DIR/src/game/macro_special_objects.o(.bss*); + BUILD_DIR/src/game/hud.o(.bss*); + BUILD_DIR/src/game/obj_behaviors.o(.bss*); + BUILD_DIR/src/game/obj_behaviors_2.o(.bss*); +#if !defined(VERSION_EU) && !defined(VERSION_CN) + BUILD_DIR/src/game*.o(.bss*); #endif - BUILD_DIR/src/audio/external.o(.bss*); + BUILD_DIR/src/audio/external.o(.bss*); #ifdef VERSION_EU - BUILD_DIR/src/audio/port_eu.o(.bss*); + BUILD_DIR/src/audio/port_eu.o(.bss*); #endif -#ifdef VERSION_SH - BUILD_DIR/src/audio/globals_start.o(.bss*); - BUILD_DIR/src/audio/synthesis_sh.o(.bss*); - BUILD_DIR/src/audio/heap.o(.bss*); - BUILD_DIR/src/audio/load_sh.o(.bss*); - BUILD_DIR/src/audio/data.o(.bss*); +#if defined(VERSION_SH) || defined(VERSION_CN) + BUILD_DIR/src/audio/globals_start.o(.bss*); + BUILD_DIR/src/audio/synthesis_sh.o(.bss*); + BUILD_DIR/src/audio/heap.o(.bss*); + BUILD_DIR/src/audio/load_sh.o(.bss*); + BUILD_DIR/src/audio/data.o(.bss*); #endif -#if defined(VERSION_EU) || defined(VERSION_SH) - BUILD_DIR/libultra.a:osInitialize.o(.bss*); - BUILD_DIR/libultra.a:osSetEventMesg.o(.bss*); - BUILD_DIR/libultra.a:osSpTaskLoadGo.o(.bss*); - BUILD_DIR/libultra.a:osCreateViManager.o(.bss*); - BUILD_DIR/libultra.a:osCreatePiManager.o(.bss*); - BUILD_DIR/libultra.a:osContStartReadData.o(.bss*); - BUILD_DIR/libultra.a:osContInit.o(.bss*); -#if ENABLE_RUMBLE - BUILD_DIR/libultra.a:motor.o(.bss*); +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) + BUILD_DIR/libultra.a:osInitialize.o(.bss*); + BUILD_DIR/libultra.a:osSetEventMesg.o(.bss*); + BUILD_DIR/libultra.a:osSpTaskLoadGo.o(.bss*); +#ifdef VERSION_CN + BUILD_DIR/libultra.a:__osSiCreateAccessQueue.o(.bss*); #endif - BUILD_DIR/libultra.a:guRotateF.o(.bss*); + BUILD_DIR/libultra.a:osCreateViManager.o(.bss*); + BUILD_DIR/libultra.a:osCreatePiManager.o(.bss*); + BUILD_DIR/libultra.a:osContStartReadData.o(.bss*); + BUILD_DIR/libultra.a:osContInit.o(.bss*); +#if ENABLE_RUMBLE + BUILD_DIR/libultra.a:motor.o(.bss*); +#endif + BUILD_DIR/libultra.a:guRotateF.o(.bss*); #ifdef VERSION_SH - BUILD_DIR/libultra.a:osCartRomInit.o(.bss*); + BUILD_DIR/libultra.a:osCartRomInit.o(.bss*); #endif #ifdef VERSION_EU - BUILD_DIR/libultra.a:leointerrupt.o(.bss*); + BUILD_DIR/libultra.a:leointerrupt.o(.bss*); #endif - BUILD_DIR/libultra.a:osTimer.o(.bss*); + BUILD_DIR/libultra.a:osTimer.o(.bss*); #ifdef VERSION_SH - BUILD_DIR/libultra.a:osLeoDiskInit.o(.bss*); + BUILD_DIR/libultra.a:osLeoDiskInit.o(.bss*); +#endif + BUILD_DIR/libultra.a:__osPiCreateAccessQueue.o(.bss*); +#ifndef VERSION_CN + BUILD_DIR/libultra.a:__osSiCreateAccessQueue.o(.bss*); #endif - BUILD_DIR/libultra.a:__osPiCreateAccessQueue.o(.bss*); - BUILD_DIR/libultra.a:__osSiCreateAccessQueue.o(.bss*); #if ENABLE_RUMBLE - BUILD_DIR/libultra.a:osPfsIsPlug.o(.bss*); + BUILD_DIR/libultra.a:osPfsIsPlug.o(.bss*); #endif - BUILD_DIR/libultra.a:osEepromWrite.o(.bss*); - BUILD_DIR/libultra.a:kdebugserver.o(.bss*); + BUILD_DIR/libultra.a:osEepromWrite.o(.bss*); + BUILD_DIR/libultra.a:kdebugserver.o(.bss*); #ifdef VERSION_SH - BUILD_DIR/libultra.a:leointerrupt.o(.bss*); + BUILD_DIR/libultra.a:leointerrupt.o(.bss*); #endif #ifdef VERSION_EU - BUILD_DIR/libultra.a:osLeoDiskInit.o(.bss*); + BUILD_DIR/libultra.a:osLeoDiskInit.o(.bss*); #endif - BUILD_DIR/libultra.a:_Printf.o(.bss*); - BUILD_DIR/libultra.a:osAiSetNextBuffer.o(.bss*); - BUILD_DIR/libultra.a:EU_D_802f4330.o(.bss*); + BUILD_DIR/libultra.a:_Printf.o(.bss*); + BUILD_DIR/libultra.a:osAiSetNextBuffer.o(.bss*); + BUILD_DIR/libultra.a:__osSetHWintrRoutine.o(.bss*); #else - BUILD_DIR/libultra.a:osSetEventMesg.o(.bss*); - BUILD_DIR/libultra.a:osSpTaskLoadGo.o(.bss*); - BUILD_DIR/libultra.a:osCreateViManager.o(.bss*); - BUILD_DIR/libultra.a:osCreatePiManager.o(.bss*); - BUILD_DIR/libultra.a:osInitialize.o(.bss*); - BUILD_DIR/libultra.a:osContStartReadData.o(.bss*); - BUILD_DIR/libultra.a:osContInit.o(.bss*); + BUILD_DIR/libultra.a:osSetEventMesg.o(.bss*); + BUILD_DIR/libultra.a:osSpTaskLoadGo.o(.bss*); + BUILD_DIR/libultra.a:osCreateViManager.o(.bss*); + BUILD_DIR/libultra.a:osCreatePiManager.o(.bss*); + BUILD_DIR/libultra.a:osInitialize.o(.bss*); + BUILD_DIR/libultra.a:osContStartReadData.o(.bss*); + BUILD_DIR/libultra.a:osContInit.o(.bss*); #if ENABLE_RUMBLE - BUILD_DIR/libultra.a:motor.o(.bss*); + BUILD_DIR/libultra.a:motor.o(.bss*); #endif - BUILD_DIR/libultra.a:guRotateF.o(.bss*); - BUILD_DIR/libultra.a:osTimer.o(.bss*); - BUILD_DIR/libultra.a:_Printf.o(.bss*); - BUILD_DIR/libultra.a:__osPiCreateAccessQueue.o(.bss*); - BUILD_DIR/libultra.a:__osSiCreateAccessQueue.o(.bss*); + BUILD_DIR/libultra.a:guRotateF.o(.bss*); + BUILD_DIR/libultra.a:osTimer.o(.bss*); + BUILD_DIR/libultra.a:_Printf.o(.bss*); + BUILD_DIR/libultra.a:__osPiCreateAccessQueue.o(.bss*); + BUILD_DIR/libultra.a:__osSiCreateAccessQueue.o(.bss*); #if ENABLE_RUMBLE - BUILD_DIR/libultra.a:osPfsIsPlug.o(.bss*); + BUILD_DIR/libultra.a:osPfsIsPlug.o(.bss*); #endif - BUILD_DIR/libultra.a:osEepromWrite.o(.bss*); - BUILD_DIR/libultra.a:kdebugserver_stack.o(.bss*); - BUILD_DIR/libultra.a:kdebugserver.o(.bss*); + BUILD_DIR/libultra.a:osEepromWrite.o(.bss*); + BUILD_DIR/libultra.a:kdebugserver_stack.o(.bss*); + BUILD_DIR/libultra.a:kdebugserver.o(.bss*); #endif - BUILD_DIR/libultra.a:*.o(.bss*); - . = ALIGN(0x8); - } - END_NOLOAD(main) - _mainSegmentNoloadSizeLo = SIZEOF (.main.noload) & 0xffff; - _mainSegmentNoloadSizeHi = SIZEOF (.main.noload) >> 16; - ASSERT((. <= SEG_ENGINE), "Error: main segment extended into engine.") + BUILD_DIR/libultra.a:*.o(.bss*); - BEGIN_SEG(engine, SEG_ENGINE) - { - BUILD_DIR/src/engine/math_util.o(.text); - BUILD_DIR/src/engine/graph_node.o(.text); - BUILD_DIR/src/engine/graph_node_manager.o(.text); - BUILD_DIR/src/engine/geo_layout.o(.text); - BUILD_DIR/src/engine/level_script.o(.text); - BUILD_DIR/src/engine/surface_collision.o(.text); - BUILD_DIR/src/engine/surface_load.o(.text); - BUILD_DIR/src/engine/behavior_script.o(.text); + BUILD_DIR/src/game/cn_common_syms_2.o(.bss*); + + . = ALIGN(0x8); + } + END_NOLOAD(main) + +#ifdef VERSION_CN + // Hack for CN to make asm/entry.s match, since we aren't using + // the original assembler and so can't get lui/ori from la pseudo + CREATE_LO_HI_PAIR(_mainSegmentNoloadStart, ADDR (.main.noload)) + CREATE_LO_HI_PAIR(gIdleThreadStack, gIdleThreadStack) + CREATE_LO_HI_PAIR(main_func, main_func) +#endif + + CREATE_LO_HI_PAIR(_mainSegmentNoloadSize, SIZEOF (.main.noload)) + + BEGIN_SEG(engine, ADDR_OR_ALIGN(SEG_ENGINE)) + { + BUILD_DIR/src/engine/math_util.o(.text); + BUILD_DIR/src/engine/graph_node.o(.text); + BUILD_DIR/src/engine/graph_node_manager.o(.text); + BUILD_DIR/src/engine/geo_layout.o(.text); + BUILD_DIR/src/engine/level_script.o(.text); + BUILD_DIR/src/engine/surface_collision.o(.text); + BUILD_DIR/src/engine/surface_load.o(.text); + BUILD_DIR/src/engine/behavior_script.o(.text); #ifdef VERSION_EU - BUILD_DIR/src/game/object_collision.o(.text); - BUILD_DIR/src/game/spawn_object.o(.text); - BUILD_DIR/src/game/object_helpers.o(.text); + BUILD_DIR/src/game/object_collision.o(.text); + BUILD_DIR/src/game/spawn_object.o(.text); + BUILD_DIR/src/game/object_helpers.o(.text); #endif - BUILD_DIR/src/engine*.o(.text); - /* data */ - BUILD_DIR/src/engine/graph_node.o(.data*); - BUILD_DIR/src/engine/graph_node_manager.o(.data*); - BUILD_DIR/src/engine/math_util.o(.data*); - BUILD_DIR/src/engine/geo_layout.o(.data*); - BUILD_DIR/src/engine/level_script.o(.data*); - BUILD_DIR/src/engine/behavior_script.o(.data*); + BUILD_DIR/src/engine*.o(.text); + /* data */ + BUILD_DIR/src/engine/graph_node.o(.data*); + BUILD_DIR/src/engine/graph_node_manager.o(.data*); + BUILD_DIR/src/engine/math_util.o(.data*); + BUILD_DIR/src/engine/geo_layout.o(.data*); + BUILD_DIR/src/engine/level_script.o(.data*); + BUILD_DIR/src/engine/behavior_script.o(.data*); #ifdef VERSION_EU - BUILD_DIR/src/game/object_collision.o(.data*); - BUILD_DIR/src/game/spawn_object.o(.data*); - BUILD_DIR/src/game/object_helpers.o(.data*); + BUILD_DIR/src/game/object_collision.o(.data*); + BUILD_DIR/src/game/spawn_object.o(.data*); + BUILD_DIR/src/game/object_helpers.o(.data*); #endif - BUILD_DIR/src/engine*.o(.data*); - /* rodata */ - BUILD_DIR/src/engine/math_util.o(.rodata*); - BUILD_DIR/src/engine/level_script.o(.rodata*); - BUILD_DIR/src/engine/surface_collision.o(.rodata*); - BUILD_DIR/src/engine/surface_load.o(.rodata*); + BUILD_DIR/src/engine*.o(.data*); + /* rodata */ + BUILD_DIR/src/engine/math_util.o(.rodata*); + BUILD_DIR/src/engine/level_script.o(.rodata*); + BUILD_DIR/src/engine/surface_collision.o(.rodata*); + BUILD_DIR/src/engine/surface_load.o(.rodata*); #ifdef VERSION_EU - BUILD_DIR/src/game/object_collision.o(.rodata*); - BUILD_DIR/src/game/spawn_object.o(.rodata*); - BUILD_DIR/src/game/object_helpers.o(.rodata*); + BUILD_DIR/src/game/object_collision.o(.rodata*); + BUILD_DIR/src/game/spawn_object.o(.rodata*); + BUILD_DIR/src/game/object_helpers.o(.rodata*); #endif - BUILD_DIR/src/engine*.o(.rodata*); - } - END_SEG(engine) - BEGIN_NOLOAD(engine) - { - BUILD_DIR/src/engine/math_util.o(.bss*); - BUILD_DIR/src/engine/geo_layout.o(.bss*); - BUILD_DIR/src/engine/level_script.o(.bss*); - BUILD_DIR/src/engine/surface_collision.o(.bss*); - BUILD_DIR/src/engine/surface_load.o(.bss*); - BUILD_DIR/src/engine/behavior_script.o(.bss*); +#ifdef VERSION_CN + BUILD_DIR/src/engine/stub.o(.rodata*); +#endif + BUILD_DIR/src/engine*.o(.rodata*); + } + END_SEG(engine) + BEGIN_NOLOAD(engine) + { + BUILD_DIR/src/engine/math_util.o(.bss*); + BUILD_DIR/src/engine/geo_layout.o(.bss*); + BUILD_DIR/src/engine/level_script.o(.bss*); + BUILD_DIR/src/engine/surface_collision.o(.bss*); + BUILD_DIR/src/engine/surface_load.o(.bss*); + BUILD_DIR/src/engine/behavior_script.o(.bss*); #ifdef VERSION_EU - BUILD_DIR/src/game/object_collision.o(.bss*); - BUILD_DIR/src/game/spawn_object.o(.bss*); - BUILD_DIR/src/game/object_helpers.o(.bss*); + BUILD_DIR/src/game/object_collision.o(.bss*); + BUILD_DIR/src/game/spawn_object.o(.bss*); + BUILD_DIR/src/game/object_helpers.o(.bss*); #endif - BUILD_DIR/src/engine*.o(.bss*); - } - END_NOLOAD(engine) + BUILD_DIR/src/engine*.o(.bss*); + } + END_NOLOAD(engine) - ASSERT((. <= SEG_FRAMEBUFFERS), "Error: engine segment extended into framebuffers.") + . = ADDR_OR_ALIGN(SEG_FRAMEBUFFERS); + BEGIN_NOLOAD(framebuffers) + { + BUILD_DIR/src/buffers/framebuffers.o(.bss*); + } + END_NOLOAD(framebuffers) - . = SEG_FRAMEBUFFERS; - BEGIN_NOLOAD(framebuffers) - { - BUILD_DIR/src/buffers/framebuffers.o(.bss*); - } - END_NOLOAD(framebuffers) + BEGIN_SEG(entry, 0x10000000) + { + BUILD_DIR/levels/entry.o(.data); + } + END_SEG(entry) - __expansionRamStart = 0x80400000; - ASSERT((. <= __expansionRamStart), "Error: RDRAM expanded into Expansion RAM, despite Expansion RAM not being defined.") - - BEGIN_SEG(entry, 0x10000000) - { - BUILD_DIR/levels/entry.o(.data); - } - END_SEG(entry) - - /* load MIO0 and level data */ - MIO0_SEG(segment2, 0x02000000) + /* load MIO0 and level data */ + MIO0_SEG(segment2, 0x02000000) #ifdef VERSION_EU - MIO0_EU_SEG(translation_en, 0x19000000) - MIO0_EU_SEG(translation_fr, 0x19000000) - MIO0_EU_SEG(translation_de, 0x19000000) + MIO0_EU_SEG(translation_en, 0x19000000) + MIO0_EU_SEG(translation_fr, 0x19000000) + MIO0_EU_SEG(translation_de, 0x19000000) #endif - /* mario actor group */ - STANDARD_OBJECTS(group0, 0x04000000, 0x17000000) + /* mario actor group */ + STANDARD_OBJECTS(group0, 0x04000000, 0x17000000) - /* load the other actor groups */ - STANDARD_OBJECTS(group1, 0x05000000, 0x0C000000) - STANDARD_OBJECTS(group2, 0x05000000, 0x0C000000) - STANDARD_OBJECTS(group3, 0x05000000, 0x0C000000) - STANDARD_OBJECTS(group4, 0x05000000, 0x0C000000) - STANDARD_OBJECTS(group5, 0x05000000, 0x0C000000) - STANDARD_OBJECTS(group6, 0x05000000, 0x0C000000) - STANDARD_OBJECTS(group7, 0x05000000, 0x0C000000) - STANDARD_OBJECTS(group8, 0x05000000, 0x0C000000) - STANDARD_OBJECTS(group9, 0x05000000, 0x0C000000) - STANDARD_OBJECTS(group10, 0x05000000, 0x0C000000) - STANDARD_OBJECTS(group11, 0x05000000, 0x0C000000) - STANDARD_OBJECTS(group12, 0x06000000, 0x0D000000) - STANDARD_OBJECTS(group13, 0x06000000, 0x0D000000) - STANDARD_OBJECTS(group14, 0x06000000, 0x0D000000) - STANDARD_OBJECTS(group15, 0x06000000, 0x0D000000) - STANDARD_OBJECTS(group16, 0x06000000, 0x0D000000) - STANDARD_OBJECTS(group17, 0x06000000, 0x0D000000) + /* load the other actor groups */ + STANDARD_OBJECTS(group1, 0x05000000, 0x0C000000) + STANDARD_OBJECTS(group2, 0x05000000, 0x0C000000) + STANDARD_OBJECTS(group3, 0x05000000, 0x0C000000) + STANDARD_OBJECTS(group4, 0x05000000, 0x0C000000) + STANDARD_OBJECTS(group5, 0x05000000, 0x0C000000) + STANDARD_OBJECTS(group6, 0x05000000, 0x0C000000) + STANDARD_OBJECTS(group7, 0x05000000, 0x0C000000) + STANDARD_OBJECTS(group8, 0x05000000, 0x0C000000) + STANDARD_OBJECTS(group9, 0x05000000, 0x0C000000) + STANDARD_OBJECTS(group10, 0x05000000, 0x0C000000) + STANDARD_OBJECTS(group11, 0x05000000, 0x0C000000) + STANDARD_OBJECTS(group12, 0x06000000, 0x0D000000) + STANDARD_OBJECTS(group13, 0x06000000, 0x0D000000) + STANDARD_OBJECTS(group14, 0x06000000, 0x0D000000) + STANDARD_OBJECTS(group15, 0x06000000, 0x0D000000) + STANDARD_OBJECTS(group16, 0x06000000, 0x0D000000) + STANDARD_OBJECTS(group17, 0x06000000, 0x0D000000) - /* load the common actor groups */ - STANDARD_OBJECTS(common0, 0x08000000, 0x0F000000) - STANDARD_OBJECTS(common1, 0x03000000, 0x16000000) + /* load the common actor groups */ + STANDARD_OBJECTS(common0, 0x08000000, 0x0F000000) + STANDARD_OBJECTS(common1, 0x03000000, 0x16000000) - /* use segmented addressing for behaviors */ - BEGIN_SEG(behavior, 0x13000000) - { - BUILD_DIR/data/behavior_data.o(.data); - } - END_SEG(behavior) + /* use segmented addressing for behaviors */ + BEGIN_SEG(behavior, 0x13000000) + { + BUILD_DIR/data/behavior_data.o(.data); + } + END_SEG(behavior) - /* 0x8016F000 21D7D0-255EC0 [386F0] */ - BEGIN_SEG(goddard, SEG_GODDARD) - { - BUILD_DIR/src/menu/title_screen.o(.text); - BUILD_DIR/src/menu/intro_geo.o(.text); - BUILD_DIR/src/menu/file_select.o(.text); - BUILD_DIR/src/menu/star_select.o(.text); - BUILD_DIR/src/menu*.o(.text); - BUILD_DIR/libgoddard.a:gd_main.o(.text); - BUILD_DIR/libgoddard.a:gd_memory.o(.text); - BUILD_DIR/libgoddard.a:sfx.o(.text); - BUILD_DIR/libgoddard.a:draw_objects.o(.text); - BUILD_DIR/libgoddard.a:objects.o(.text); - BUILD_DIR/libgoddard.a:skin_movement.o(.text); - BUILD_DIR/libgoddard.a:particles.o(.text); - BUILD_DIR/libgoddard.a:dynlist_proc.o(.text); - BUILD_DIR/libgoddard.a:old_menu.o(.text); - BUILD_DIR/libgoddard.a:debug_utils.o(.text); - BUILD_DIR/libgoddard.a:joints.o(.text); - BUILD_DIR/libgoddard.a:skin.o(.text); - BUILD_DIR/libgoddard.a:gd_math.o(.text); - BUILD_DIR/libgoddard.a:shape_helper.o(.text); - BUILD_DIR/libgoddard.a:renderer.o(.text); - BUILD_DIR/libgoddard.a:*.o(.text); - /* data, rodata, per file */ - BUILD_DIR/src/menu/title_screen.o(.data*); - BUILD_DIR/src/menu/title_screen.o(.rodata*); - BUILD_DIR/src/menu/intro_geo.o(.data*); - BUILD_DIR/src/menu/file_select.o(.data*); - BUILD_DIR/src/menu/file_select.o(.rodata*); - BUILD_DIR/src/menu/star_select.o(.data*); - BUILD_DIR/src/menu/star_select.o(.rodata*); - BUILD_DIR/src/menu*.o(.data*); - BUILD_DIR/src/menu*.o(.rodata*); - /* goddard subsystem data */ - BUILD_DIR/libgoddard.a:gd_main.o(.data*); - BUILD_DIR/libgoddard.a:draw_objects.o(.data*); - BUILD_DIR/libgoddard.a:objects.o(.data*); - BUILD_DIR/libgoddard.a:particles.o(.data*); - BUILD_DIR/libgoddard.a:dynlist_proc.o(.data*); - BUILD_DIR/libgoddard.a:debug_utils.o(.data*); - BUILD_DIR/libgoddard.a:joints.o(.data*); - BUILD_DIR/libgoddard.a:shape_helper.o(.data*); - BUILD_DIR/libgoddard.a:renderer.o(.data*); - /* goddard subsystem rodata */ - BUILD_DIR/libgoddard.a:gd_main.o(.rodata*); - BUILD_DIR/libgoddard.a:gd_memory.o(.rodata*); - BUILD_DIR/libgoddard.a:draw_objects.o(.rodata*); - BUILD_DIR/libgoddard.a:objects.o(.rodata*); - BUILD_DIR/libgoddard.a:skin_movement.o(.rodata*); - BUILD_DIR/libgoddard.a:particles.o(.rodata*); - BUILD_DIR/libgoddard.a:dynlist_proc.o(.rodata*); - BUILD_DIR/libgoddard.a:old_menu.o(.rodata*); - BUILD_DIR/libgoddard.a:debug_utils.o(.rodata*); - BUILD_DIR/libgoddard.a:joints.o(.rodata*); - BUILD_DIR/libgoddard.a:skin.o(.rodata*); - BUILD_DIR/libgoddard.a:gd_math.o(.rodata*); - BUILD_DIR/libgoddard.a:shape_helper.o(.rodata*); - BUILD_DIR/libgoddard.a:renderer.o(.rodata*); - } - END_SEG(goddard) - BEGIN_NOLOAD(goddard) - { - BUILD_DIR/src/menu/intro_geo.o(.bss*); - BUILD_DIR/src/menu/file_select.o(.bss*); - BUILD_DIR/src/menu/star_select.o(.bss*); - BUILD_DIR/src/menu*.o(.bss*); - BUILD_DIR/libgoddard.a:gd_main.o(.bss*); - BUILD_DIR/libgoddard.a:gd_memory.o(.bss*); - BUILD_DIR/libgoddard.a:sfx.o(.bss*); - BUILD_DIR/libgoddard.a:draw_objects.o(.bss*); - BUILD_DIR/libgoddard.a:objects.o(.bss*); - BUILD_DIR/libgoddard.a:skin_movement.o(.bss*); - BUILD_DIR/libgoddard.a:particles.o(.bss*); - BUILD_DIR/libgoddard.a:dynlist_proc.o(.bss*); - BUILD_DIR/libgoddard.a:old_menu.o(.bss*); - BUILD_DIR/libgoddard.a:debug_utils.o(.bss*); - BUILD_DIR/libgoddard.a:joints.o(.bss*); - BUILD_DIR/libgoddard.a:skin.o(.bss*); - BUILD_DIR/libgoddard.a:shape_helper.o(.bss*); - BUILD_DIR/libgoddard.a:renderer.o(.bss*); - BUILD_DIR/libgoddard.a:*.o(.bss*); - } - END_NOLOAD(goddard) + /* 0x8016F000 21D7D0-255EC0 [386F0] */ + BEGIN_SEG(goddard, SEG_GODDARD) + { + BUILD_DIR/src/menu/title_screen.o(.text); + BUILD_DIR/src/menu/intro_geo.o(.text); + BUILD_DIR/src/menu/file_select.o(.text); + BUILD_DIR/src/menu/star_select.o(.text); + BUILD_DIR/src/menu*.o(.text); + BUILD_DIR/libgoddard.a:gd_main.o(.text); + BUILD_DIR/libgoddard.a:gd_memory.o(.text); + BUILD_DIR/libgoddard.a:sfx.o(.text); + BUILD_DIR/libgoddard.a:draw_objects.o(.text); + BUILD_DIR/libgoddard.a:objects.o(.text); + BUILD_DIR/libgoddard.a:skin_movement.o(.text); + BUILD_DIR/libgoddard.a:particles.o(.text); + BUILD_DIR/libgoddard.a:dynlist_proc.o(.text); + BUILD_DIR/libgoddard.a:old_menu.o(.text); + BUILD_DIR/libgoddard.a:debug_utils.o(.text); + BUILD_DIR/libgoddard.a:joints.o(.text); + BUILD_DIR/libgoddard.a:skin.o(.text); + BUILD_DIR/libgoddard.a:gd_math.o(.text); + BUILD_DIR/libgoddard.a:shape_helper.o(.text); + BUILD_DIR/libgoddard.a:renderer.o(.text); + BUILD_DIR/libgoddard.a:*.o(.text); + /* data, rodata, per file */ + BUILD_DIR/src/menu/title_screen.o(.data*); + BUILD_DIR/src/menu/title_screen.o(.rodata*); + BUILD_DIR/src/menu/intro_geo.o(.data*); + BUILD_DIR/src/menu/file_select.o(.data*); + BUILD_DIR/src/menu/file_select.o(.rodata*); + BUILD_DIR/src/menu/star_select.o(.data*); + BUILD_DIR/src/menu/star_select.o(.rodata*); + BUILD_DIR/src/menu*.o(.data*); + BUILD_DIR/src/menu*.o(.rodata*); + /* goddard subsystem data */ + BUILD_DIR/libgoddard.a:gd_main.o(.data*); + BUILD_DIR/libgoddard.a:draw_objects.o(.data*); + BUILD_DIR/libgoddard.a:objects.o(.data*); + BUILD_DIR/libgoddard.a:particles.o(.data*); + BUILD_DIR/libgoddard.a:dynlist_proc.o(.data*); + BUILD_DIR/libgoddard.a:debug_utils.o(.data*); + BUILD_DIR/libgoddard.a:joints.o(.data*); + BUILD_DIR/libgoddard.a:shape_helper.o(.data*); + BUILD_DIR/libgoddard.a:renderer.o(.data*); + /* goddard subsystem rodata */ + BUILD_DIR/libgoddard.a:gd_main.o(.rodata*); + BUILD_DIR/libgoddard.a:gd_memory.o(.rodata*); + BUILD_DIR/libgoddard.a:draw_objects.o(.rodata*); + BUILD_DIR/libgoddard.a:objects.o(.rodata*); + BUILD_DIR/libgoddard.a:skin_movement.o(.rodata*); + BUILD_DIR/libgoddard.a:particles.o(.rodata*); + BUILD_DIR/libgoddard.a:dynlist_proc.o(.rodata*); + BUILD_DIR/libgoddard.a:old_menu.o(.rodata*); + BUILD_DIR/libgoddard.a:debug_utils.o(.rodata*); + BUILD_DIR/libgoddard.a:joints.o(.rodata*); + BUILD_DIR/libgoddard.a:skin.o(.rodata*); + BUILD_DIR/libgoddard.a:gd_math.o(.rodata*); + BUILD_DIR/libgoddard.a:shape_helper.o(.rodata*); + BUILD_DIR/libgoddard.a:renderer.o(.rodata*); + } + END_SEG(goddard) + BEGIN_NOLOAD(goddard) + { + BUILD_DIR/src/menu/intro_geo.o(.bss*); + BUILD_DIR/src/menu/file_select.o(.bss*); + BUILD_DIR/src/menu/star_select.o(.bss*); + BUILD_DIR/src/menu*.o(.bss*); + BUILD_DIR/libgoddard.a:gd_main.o(.bss*); + BUILD_DIR/libgoddard.a:gd_memory.o(.bss*); + BUILD_DIR/libgoddard.a:sfx.o(.bss*); + BUILD_DIR/libgoddard.a:draw_objects.o(.bss*); + BUILD_DIR/libgoddard.a:objects.o(.bss*); + BUILD_DIR/libgoddard.a:skin_movement.o(.bss*); + BUILD_DIR/libgoddard.a:particles.o(.bss*); + BUILD_DIR/libgoddard.a:dynlist_proc.o(.bss*); + BUILD_DIR/libgoddard.a:old_menu.o(.bss*); + BUILD_DIR/libgoddard.a:debug_utils.o(.bss*); + BUILD_DIR/libgoddard.a:joints.o(.bss*); + BUILD_DIR/libgoddard.a:skin.o(.bss*); + BUILD_DIR/libgoddard.a:shape_helper.o(.bss*); + BUILD_DIR/libgoddard.a:renderer.o(.bss*); + BUILD_DIR/libgoddard.a:*.o(.bss*); + } + END_NOLOAD(goddard) - ASSERT((. <= SEG_POOL_END), "Error: extended past pool end.") + /* 0x268020 0x268020-0 [0] */ + BEGIN_SEG(intro, 0x14000000) + { + BUILD_DIR/levels/intro/script.o(.data); + BUILD_DIR/levels/intro/geo.o(.data); + } + END_SEG(intro) + BEGIN_SEG(intro_segment_7, 0x07000000) + { + BUILD_DIR/levels/intro/leveldata.mio0.o(.data); + . = ALIGN(0x10); + } + END_SEG(intro_segment_7) - . = SEG_BUFFERS; - BEGIN_NOLOAD(buffers) - { - BUILD_DIR/src/buffers/buffers.o(.bss*); - BUILD_DIR/src/audio/globals_start.o(.bss*); -#ifdef VERSION_SH - BUILD_DIR/src/audio/port_sh.o(.bss*); -#else - BUILD_DIR/src/audio/synthesis.o(.bss*); - BUILD_DIR/src/audio/heap.o(.bss*); - BUILD_DIR/src/audio/load.o(.bss*); - BUILD_DIR/src/audio/data.o(.bss*); -#endif - BUILD_DIR/src/audio*.o(.bss*); + MIO0_SEG(debug_level_select, 0x07000000) + MIO0_SEG(title_screen_bg, 0x0A000000) -#ifdef VERSION_EU - . = ALIGN(0x200); -#else - . = ALIGN(0x1000); -#endif -#ifdef VERSION_SH - . += 0xB000; -#endif - BUILD_DIR/src/buffers/gfx_output_buffer.o(.bss*); - } - END_NOLOAD(buffers) + /* 271B20-2A42A0 [32780] */ + BEGIN_SEG(gd_dynlists, 0x04000000) + { + BUILD_DIR/libgoddard.a:dynlist_test_cube.o(.data); + BUILD_DIR/libgoddard.a:dynlist_unused.o(.data); + BUILD_DIR/libgoddard.a:dynlist_mario_face.o(.data); + BUILD_DIR/libgoddard.a:dynlists_mario_eyes.o(.data); + BUILD_DIR/libgoddard.a:dynlists_mario_eyebrows_mustache.o(.data); + BUILD_DIR/libgoddard.a:dynlist_mario_master.o(.data); + BUILD_DIR/libgoddard.a:anim_mario_mustache_right.o(.data); + BUILD_DIR/libgoddard.a:anim_mario_mustache_left.o(.data); + BUILD_DIR/libgoddard.a:anim_mario_lips_1.o(.data); + BUILD_DIR/libgoddard.a:anim_mario_lips_2.o(.data); + BUILD_DIR/libgoddard.a:anim_mario_eyebrows_1.o(.data); + BUILD_DIR/libgoddard.a:anim_group_1.o(.data); + BUILD_DIR/libgoddard.a:anim_group_2.o(.data); + BUILD_DIR/libgoddard.a:dynlist_test_cube.o(.rodata*); + BUILD_DIR/libgoddard.a:dynlist_unused.o(.rodata*); + BUILD_DIR/libgoddard.a:*.o(.data); + BUILD_DIR/libgoddard.a:*.o(.rodata); + } + END_SEG(gd_dynlists) - ASSERT((. <= SEG_MAIN), "Error: buffers segment extended into main") + gMainLevels = __romPos; - /* 0x268020 0x268020-0 [0] */ - BEGIN_SEG(intro, 0x14000000) - { - BUILD_DIR/levels/intro/script.o(.data); - BUILD_DIR/levels/intro/geo.o(.data); - } - END_SEG(intro) - BEGIN_SEG(intro_segment_7, 0x07000000) - { - BUILD_DIR/levels/intro/leveldata.mio0.o(.data); - . = ALIGN(0x10); - } - END_SEG(intro_segment_7) + BEGIN_SEG(menu, 0x14000000) + { + BUILD_DIR/levels/menu/script.o(.data); + BUILD_DIR/levels/menu/geo.o(.data); + } + END_SEG(menu) + BEGIN_SEG(menu_segment_7, 0x07000000) + { + BUILD_DIR/levels/menu/leveldata.mio0.o(.data); + . = ALIGN(0x10); + } + END_SEG(menu_segment_7) - MIO0_SEG(debug_level_select, 0x07000000) - MIO0_SEG(title_screen_bg, 0x0A000000) + BEGIN_SEG(scripts, 0x15000000) + { + BUILD_DIR/levels/scripts.o(.data); + } + END_SEG(scripts) - /* 271B20-2A42A0 [32780] */ - BEGIN_SEG(gd_dynlists, 0x04000000) - { - BUILD_DIR/libgoddard.a:dynlist_test_cube.o(.data); - BUILD_DIR/libgoddard.a:dynlist_unused.o(.data); - BUILD_DIR/libgoddard.a:dynlist_mario_face.o(.data); - BUILD_DIR/libgoddard.a:dynlists_mario_eyes.o(.data); - BUILD_DIR/libgoddard.a:dynlists_mario_eyebrows_mustache.o(.data); - BUILD_DIR/libgoddard.a:dynlist_mario_master.o(.data); - BUILD_DIR/libgoddard.a:anim_mario_mustache_right.o(.data); - BUILD_DIR/libgoddard.a:anim_mario_mustache_left.o(.data); - BUILD_DIR/libgoddard.a:anim_mario_lips_1.o(.data); - BUILD_DIR/libgoddard.a:anim_mario_lips_2.o(.data); - BUILD_DIR/libgoddard.a:anim_mario_eyebrows_1.o(.data); - BUILD_DIR/libgoddard.a:anim_group_1.o(.data); - BUILD_DIR/libgoddard.a:anim_group_2.o(.data); - BUILD_DIR/libgoddard.a:dynlist_test_cube.o(.rodata*); - BUILD_DIR/libgoddard.a:dynlist_unused.o(.rodata*); - BUILD_DIR/libgoddard.a:*.o(.data); - BUILD_DIR/libgoddard.a:*.o(.rodata); - } - END_SEG(gd_dynlists) + MIO0_SEG(water_skybox, 0x0A000000) + MIO0_SEG(ccm_skybox, 0x0A000000) + MIO0_SEG(clouds_skybox, 0x0A000000) + MIO0_SEG(bitfs_skybox, 0x0A000000) + MIO0_SEG(wdw_skybox, 0x0A000000) + MIO0_SEG(cloud_floor_skybox, 0x0A000000) + MIO0_SEG(ssl_skybox, 0x0A000000) + MIO0_SEG(bbh_skybox, 0x0A000000) + MIO0_SEG(bidw_skybox, 0x0A000000) + MIO0_SEG(bits_skybox, 0x0A000000) - gMainLevels = __romPos; - - BEGIN_SEG(menu, 0x14000000) - { - BUILD_DIR/levels/menu/script.o(.data); - BUILD_DIR/levels/menu/geo.o(.data); - } - END_SEG(menu) - BEGIN_SEG(menu_segment_7, 0x07000000) - { - BUILD_DIR/levels/menu/leveldata.mio0.o(.data); - . = ALIGN(0x10); - } - END_SEG(menu_segment_7) - - BEGIN_SEG(scripts, 0x15000000) - { - BUILD_DIR/levels/scripts.o(.data); - } - END_SEG(scripts) - - MIO0_SEG(water_skybox, 0x0A000000) - MIO0_SEG(ccm_skybox, 0x0A000000) - MIO0_SEG(clouds_skybox, 0x0A000000) - MIO0_SEG(bitfs_skybox, 0x0A000000) - MIO0_SEG(wdw_skybox, 0x0A000000) - MIO0_SEG(cloud_floor_skybox, 0x0A000000) - MIO0_SEG(ssl_skybox, 0x0A000000) - MIO0_SEG(bbh_skybox, 0x0A000000) - MIO0_SEG(bidw_skybox, 0x0A000000) - MIO0_SEG(bits_skybox, 0x0A000000) - - // Texture bins - MIO0_SEG(fire, 0x09000000) - MIO0_SEG(spooky, 0x09000000) - MIO0_SEG(generic, 0x09000000) - MIO0_SEG(water, 0x09000000) - MIO0_SEG(sky, 0x09000000) - MIO0_SEG(snow, 0x09000000) - MIO0_SEG(cave, 0x09000000) - MIO0_SEG(machine, 0x09000000) - MIO0_SEG(mountain, 0x09000000) - MIO0_SEG(grass, 0x09000000) - MIO0_SEG(outside, 0x09000000) - MIO0_SEG(inside, 0x09000000) - MIO0_SEG(effect, 0x0B000000) + // Texture bins + MIO0_SEG(fire, 0x09000000) + MIO0_SEG(spooky, 0x09000000) + MIO0_SEG(generic, 0x09000000) + MIO0_SEG(water, 0x09000000) + MIO0_SEG(sky, 0x09000000) + MIO0_SEG(snow, 0x09000000) + MIO0_SEG(cave, 0x09000000) + MIO0_SEG(machine, 0x09000000) + MIO0_SEG(mountain, 0x09000000) + MIO0_SEG(grass, 0x09000000) + MIO0_SEG(outside, 0x09000000) + MIO0_SEG(inside, 0x09000000) + MIO0_SEG(effect, 0x0B000000) #define STUB_LEVEL(_0, _1, _2, _3, _4, _5, _6, _7, _8) #define DEFINE_LEVEL(_0, _1, _2, folder, _4, _5, _6, _7, _8, _9, _10) STANDARD_LEVEL(folder) - #include "levels/level_defines.h" + #include "levels/level_defines.h" #undef STUB_LEVEL #undef DEFINE_LEVEL - /* 4E9FA0-? [?] */ - BEGIN_SEG(assets, __romPos) - { - BUILD_DIR/assets/mario_anim_data.o(.data); - BUILD_DIR/assets/mario_anim_data.o(.rodata); - BUILD_DIR/assets/demo_data.o(.data); - BUILD_DIR/sound/sound_data.o(.data); - } - END_SEG(assets) + /* 4E9FA0-? [?] */ + BEGIN_SEG(assets, __romPos) + { + BUILD_DIR/assets/mario_anim_data.o(.data); + BUILD_DIR/assets/mario_anim_data.o(.rodata); + BUILD_DIR/assets/demo_data.o(.data); + BUILD_DIR/sound/sound_data.o(.data); + } + END_SEG(assets) - /* Discard everything not specifically mentioned above. */ - /DISCARD/ : - { - *(*); - } + /* Discard everything not specifically mentioned above. */ + /DISCARD/ : + { + *(*); + } + + ASSERT((_goddardSegmentNoloadEnd <= SEG_POOL_END), "Error: menu segment extended past pool end") + ASSERT((_mainSegmentNoloadEnd <= _engineSegmentStart), "Error: main segment extended into engine.") + ASSERT((_engineSegmentNoloadEnd <= _framebuffersSegmentNoloadStart), "Error: engine segment extended into framebuffers.") + ASSERT((_framebuffersSegmentNoloadEnd <= RDRAM_END), "Error: framebuffers segment extended past RDRAM end") } diff --git a/sound/sequences.json b/sound/sequences.json index 1470c97d..c1a5dc6a 100644 --- a/sound/sequences.json +++ b/sound/sequences.json @@ -34,5 +34,5 @@ "1F_cutscene_victory": ["1A"], "20_cutscene_ending": ["23"], "21_menu_file_select": ["24"], - "22_cutscene_lakitu": {"ifdef": ["VERSION_US", "VERSION_EU", "VERSION_SH"], "banks": ["1B"]} + "22_cutscene_lakitu": {"ifdef": ["VERSION_US", "VERSION_EU", "VERSION_SH", "VERSION_CN"], "banks": ["1B"]} } diff --git a/sound/sequences/00_sound_player.s b/sound/sequences/00_sound_player.s index 1d1e0173..9d7dd557 100644 --- a/sound/sequences/00_sound_player.s +++ b/sound/sequences/00_sound_player.s @@ -6,7 +6,7 @@ sequence_start: seq_setmutebhv 0x60 seq_setmutescale 0 -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) seq_setvol 100 #else seq_setvol 127 @@ -89,7 +89,7 @@ chan_dyncall .poll_023589: chan_delay1 chan_ioreadval 0 -chan_bltz .skip_023589 // if we have a signal: +chan_bltz .skip_023589 // if we have a signal: chan_beqz .force_stop_023589 // told to stop chan_jump .start_playing_023589 // told to play something else .skip_023589: @@ -2074,7 +2074,7 @@ chan_setlayer 0, .layer_C3C chan_end .layer_C3C: -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) layer_transpose 2 #endif layer_portamento 0x82, 41, 127 @@ -2113,7 +2113,7 @@ chan_setlayer 0, .layer_C6C chan_end .layer_C6C: -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) layer_transpose 1 #endif layer_portamento 0x82, 44, 200 @@ -2693,13 +2693,13 @@ layer_jump .layer_C4E layer_end #endif -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) .chan_unused_F9A_eu: chan_setbank 8 chan_setinstr 0 chan_setlayer 0, .layer_FA2_eu chan_end - + .layer_FA2_eu: layer_delay 0x5 layer_end @@ -3402,7 +3402,7 @@ chan_setbank 9 chan_setinstr 3 chan_setval 40 chan_call .set_reverb -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) chan_setreverb 40 #endif chan_setlayer 0, .layer_141A @@ -3410,7 +3410,7 @@ chan_end .layer_141A: layer_transpose 24 -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) layer_note1 51, 0xc, 90 #endif layer_note1 39, 0x4, 90 @@ -4155,7 +4155,7 @@ layer_end chan_setlayer 1, .layer_1902 chan_setlayer 2, .layer_1907 #else - #if defined(VERSION_EU) || defined(VERSION_SH) + #if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) chan_setbank 9 chan_setinstr 3 #else @@ -7509,7 +7509,7 @@ layer_end chan_reservenotes 4 chan_setbank 9 chan_setinstr 2 -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) chan_setval 15 .set EXIT_PIPE_NOTE_VELOCITY, 106 #else @@ -7831,7 +7831,7 @@ chan_end .layer_3146: layer_delay 0x6 - #ifdef VERSION_SH + #if defined(VERSION_SH) || defined(VERSION_CN) .set RED_COIN_NOTE_VELOCITY_SUB, 10 #else .set RED_COIN_NOTE_VELOCITY_SUB, 0 @@ -8153,7 +8153,7 @@ envelope_goto 2 .envelope_341C: envelope_line 25 32760 envelope_line 60 10000 -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) envelope_hang #else envelope_goto 2 diff --git a/sound/sound_banks/07.json b/sound/sound_banks/07.json index 4b37d3c3..ec5bc9ed 100644 --- a/sound/sound_banks/07.json +++ b/sound/sound_banks/07.json @@ -106,7 +106,7 @@ "sound": "0C" }, "inst13": { - "ifdef": ["VERSION_US", "VERSION_EU", "VERSION_SH"], + "ifdef": ["VERSION_US", "VERSION_EU", "VERSION_SH", "VERSION_CN"], "release_rate": 208, "envelope": "envelope5", "sound": "0D_chain_chomp_bark" diff --git a/sound/sound_banks/08_mario.json b/sound/sound_banks/08_mario.json index 0bf286ee..a4d44b52 100644 --- a/sound/sound_banks/08_mario.json +++ b/sound/sound_banks/08_mario.json @@ -91,67 +91,67 @@ "sound": "0F_mario_snoring2" }, "inst16": { - "ifdef": ["VERSION_US", "VERSION_EU", "VERSION_SH"], + "ifdef": ["VERSION_US", "VERSION_EU", "VERSION_SH", "VERSION_CN"], "release_rate": 208, "envelope": "envelope0", "sound": "10_mario_doh" }, "inst17": { - "ifdef": ["VERSION_US", "VERSION_EU", "VERSION_SH"], + "ifdef": ["VERSION_US", "VERSION_EU", "VERSION_SH", "VERSION_CN"], "release_rate": 208, "envelope": "envelope0", "sound": "11_mario_game_over" }, "inst18": { - "ifdef": ["VERSION_US", "VERSION_EU", "VERSION_SH"], + "ifdef": ["VERSION_US", "VERSION_EU", "VERSION_SH", "VERSION_CN"], "release_rate": 208, "envelope": "envelope0", "sound": "12_mario_hello" }, "inst19": { - "ifdef": ["VERSION_US", "VERSION_EU", "VERSION_SH"], + "ifdef": ["VERSION_US", "VERSION_EU", "VERSION_SH", "VERSION_CN"], "release_rate": 208, "envelope": "envelope0", "sound": "13_mario_press_start_to_play" }, "inst20": { - "ifdef": ["VERSION_US", "VERSION_EU", "VERSION_SH"], + "ifdef": ["VERSION_US", "VERSION_EU", "VERSION_SH", "VERSION_CN"], "release_rate": 208, "envelope": "envelope0", "sound": "14_mario_twirl_bounce" }, "inst21": { - "ifdef": ["VERSION_US", "VERSION_EU", "VERSION_SH"], + "ifdef": ["VERSION_US", "VERSION_EU", "VERSION_SH", "VERSION_CN"], "release_rate": 208, "envelope": "envelope0", "sound": "15_mario_snoring3" }, "inst22": { - "ifdef": ["VERSION_US", "VERSION_EU", "VERSION_SH"], + "ifdef": ["VERSION_US", "VERSION_EU", "VERSION_SH", "VERSION_CN"], "release_rate": 208, "envelope": "envelope0", - "sound": {"ifdef": ["VERSION_SH"], "then": "16_mario_bye_bye", "else": "16_mario_so_longa_bowser"} + "sound": {"ifdef": ["VERSION_SH", "VERSION_CN"], "then": "16_mario_bye_bye", "else": "16_mario_so_longa_bowser"} }, "inst23": { - "ifdef": ["VERSION_US", "VERSION_EU", "VERSION_SH"], + "ifdef": ["VERSION_US", "VERSION_EU", "VERSION_SH", "VERSION_CN"], "release_rate": 208, "envelope": "envelope0", "sound": "17_mario_ima_tired" }, "inst24": { - "ifdef": ["VERSION_US", "VERSION_EU", "VERSION_SH"], + "ifdef": ["VERSION_US", "VERSION_EU", "VERSION_SH", "VERSION_CN"], "release_rate": 208, "envelope": "envelope0", "sound": "18_mario_waha" }, "inst25": { - "ifdef": ["VERSION_US", "VERSION_EU", "VERSION_SH"], + "ifdef": ["VERSION_US", "VERSION_EU", "VERSION_SH", "VERSION_CN"], "release_rate": 208, "envelope": "envelope0", "sound": "19_mario_yippee" }, "inst26": { - "ifdef": ["VERSION_US", "VERSION_EU", "VERSION_SH"], + "ifdef": ["VERSION_US", "VERSION_EU", "VERSION_SH", "VERSION_CN"], "release_rate": 208, "envelope": "envelope0", "sound": "1A_mario_lets_a_go" diff --git a/sound/sound_banks/0A_mario_peach.json b/sound/sound_banks/0A_mario_peach.json index 79286d5d..9707fb63 100644 --- a/sound/sound_banks/0A_mario_peach.json +++ b/sound/sound_banks/0A_mario_peach.json @@ -81,55 +81,55 @@ "sound": "0D_mario_thank_you_playing_my_game" }, "inst14": { - "ifdef": ["VERSION_US", "VERSION_EU", "VERSION_SH"], + "ifdef": ["VERSION_US", "VERSION_EU", "VERSION_SH", "VERSION_CN"], "release_rate": 208, "envelope": "envelope0", "sound": "0E_peach_dear_mario" }, "inst15": { - "ifdef": ["VERSION_US", "VERSION_EU", "VERSION_SH"], + "ifdef": ["VERSION_US", "VERSION_EU", "VERSION_SH", "VERSION_CN"], "release_rate": 208, "envelope": "envelope0", "sound": "0F_peach_mario" }, "inst16": { - "ifdef": ["VERSION_US", "VERSION_EU", "VERSION_SH"], + "ifdef": ["VERSION_US", "VERSION_EU", "VERSION_SH", "VERSION_CN"], "release_rate": 208, "envelope": "envelope0", "sound": "10_peach_power_of_the_stars" }, "inst17": { - "ifdef": ["VERSION_US", "VERSION_EU", "VERSION_SH"], + "ifdef": ["VERSION_US", "VERSION_EU", "VERSION_SH", "VERSION_CN"], "release_rate": 208, "envelope": "envelope0", "sound": "11_peach_thanks_to_you" }, "inst18": { - "ifdef": ["VERSION_US", "VERSION_EU", "VERSION_SH"], + "ifdef": ["VERSION_US", "VERSION_EU", "VERSION_SH", "VERSION_CN"], "release_rate": 208, "envelope": "envelope0", "sound": "12_peach_thank_you_mario" }, "inst19": { - "ifdef": ["VERSION_US", "VERSION_EU", "VERSION_SH"], + "ifdef": ["VERSION_US", "VERSION_EU", "VERSION_SH", "VERSION_CN"], "release_rate": 208, "envelope": "envelope0", "sound": "13_peach_something_special" }, "inst20": { - "ifdef": ["VERSION_US", "VERSION_EU", "VERSION_SH"], + "ifdef": ["VERSION_US", "VERSION_EU", "VERSION_SH", "VERSION_CN"], "release_rate": 208, "envelope": "envelope0", "sound": "14_peach_bake_a_cake" }, "inst21": { - "ifdef": ["VERSION_US", "VERSION_EU", "VERSION_SH"], + "ifdef": ["VERSION_US", "VERSION_EU", "VERSION_SH", "VERSION_CN"], "release_rate": 208, "envelope": "envelope0", "sound": "15_peach_for_mario" }, "inst22": { - "ifdef": ["VERSION_US", "VERSION_EU", "VERSION_SH"], + "ifdef": ["VERSION_US", "VERSION_EU", "VERSION_SH", "VERSION_CN"], "release_rate": 208, "envelope": "envelope0", "sound": "16_peach_mario2" diff --git a/sound/sound_banks/0B.json b/sound/sound_banks/0B.json index 1ec7d90a..3004e5f8 100644 --- a/sound/sound_banks/0B.json +++ b/sound/sound_banks/0B.json @@ -51,29 +51,29 @@ "normal_range_lo": 29, "normal_range_hi": 63, "envelope": "envelope0", - "sound_lo": "3B_banjo_2", - "sound": "3C_acoustic_guitar", - "sound_hi": "3D" + "sound_lo": "3B_acoustic_guitar_A1", + "sound": "3C_acoustic_guitar_E3", + "sound_hi": "3D_acoustic_guitar_B6" }, "inst1": { "release_rate": 208, "envelope": "envelope1", - "sound": "2E_accordion" + "sound": "2E_accordion_C4" }, "inst2": { "release_rate": 208, "envelope": "envelope2", - "sound": "2E_accordion" + "sound": "2E_accordion_C4" }, "inst3": { "release_rate": 208, "envelope": "envelope3", - "sound": "16_french_horns" + "sound": "16_french_horns_C3" }, "inst4": { "release_rate": 208, "envelope": "envelope4", - "sound": "16_french_horns" + "sound": "16_french_horns_C3" }, "inst5": { "release_rate": 10, diff --git a/sound/sound_banks/0C.json b/sound/sound_banks/0C.json index 2b35bbe1..9c2089ac 100644 --- a/sound/sound_banks/0C.json +++ b/sound/sound_banks/0C.json @@ -93,69 +93,69 @@ "normal_range_lo": 29, "normal_range_hi": 63, "envelope": "envelope0", - "sound_lo": "3B_banjo_2", - "sound": "3C_acoustic_guitar", - "sound_hi": "3D" + "sound_lo": "3B_acoustic_guitar_A1", + "sound": "3C_acoustic_guitar_E3", + "sound_hi": "3D_acoustic_guitar_B6" }, "inst1": { "release_rate": 24, "normal_range_lo": 29, "normal_range_hi": 61, "envelope": "envelope1", - "sound_lo": "3B_banjo_2", - "sound": "3C_acoustic_guitar", - "sound_hi": "3D" + "sound_lo": "3B_acoustic_guitar_A1", + "sound": "3C_acoustic_guitar_E3", + "sound_hi": "3D_acoustic_guitar_B6" }, "inst2": { "release_rate": 38, "normal_range_lo": 29, "normal_range_hi": 61, "envelope": "envelope2", - "sound_lo": "3B_banjo_2", - "sound": "3C_acoustic_guitar", - "sound_hi": "3D" + "sound_lo": "3B_acoustic_guitar_A1", + "sound": "3C_acoustic_guitar_E3", + "sound_hi": "3D_acoustic_guitar_B6" }, "inst3": { "release_rate": 38, "normal_range_lo": 29, "normal_range_hi": 61, "envelope": "envelope3", - "sound_lo": "3B_banjo_2", - "sound": "3C_acoustic_guitar", - "sound_hi": "3D" + "sound_lo": "3B_acoustic_guitar_A1", + "sound": "3C_acoustic_guitar_E3", + "sound_hi": "3D_acoustic_guitar_B6" }, "inst4": { "release_rate": 38, "normal_range_lo": 29, "normal_range_hi": 61, "envelope": "envelope4", - "sound_lo": "3B_banjo_2", - "sound": "3C_acoustic_guitar", - "sound_hi": "3D" + "sound_lo": "3B_acoustic_guitar_A1", + "sound": "3C_acoustic_guitar_E3", + "sound_hi": "3D_acoustic_guitar_B6" }, "inst5": { "release_rate": 38, "normal_range_lo": 29, "normal_range_hi": 61, "envelope": "envelope5", - "sound_lo": "3B_banjo_2", - "sound": "3C_acoustic_guitar", - "sound_hi": "3D" + "sound_lo": "3B_acoustic_guitar_A1", + "sound": "3C_acoustic_guitar_E3", + "sound_hi": "3D_acoustic_guitar_B6" }, "inst6": { "release_rate": 208, "envelope": "envelope6", - "sound": "21_sine_bass" + "sound": "21_sine_bass_Bb2" }, "inst7": { "release_rate": 114, "envelope": "envelope7", - "sound": "34_alto_flute" + "sound": "34_alto_flute_A4" }, "inst8": { "release_rate": 208, "envelope": "envelope8", - "sound": "34_alto_flute" + "sound": "34_alto_flute_A4" }, "percussion": [ {"release_rate": 10, "pan": 62, "envelope": "envelope9", "sound": {"sample": "06_kick_drum_1", "tuning": 0.210224}}, @@ -251,7 +251,7 @@ "inst12": { "release_rate": 10, "envelope": "envelope13", - "sound": "42_vibraphone" + "sound": "42_vibraphone_F#4" } }, "instrument_list": [ diff --git a/sound/sound_banks/0D.json b/sound/sound_banks/0D.json index 6d02f429..25f9028c 100644 --- a/sound/sound_banks/0D.json +++ b/sound/sound_banks/0D.json @@ -74,40 +74,40 @@ "release_rate": 100, "normal_range_lo": 41, "envelope": "envelope0", - "sound_lo": "00", - "sound": "01_banjo_1" + "sound_lo": "00_banjo_D2", + "sound": "01_banjo_A2" }, "inst1": { "release_rate": 100, "normal_range_lo": 41, "envelope": "envelope1", - "sound_lo": "00", - "sound": "01_banjo_1" + "sound_lo": "00_banjo_D2", + "sound": "01_banjo_A2" }, "inst2": { "release_rate": 180, "envelope": "envelope2", - "sound": "02" + "sound": "02_violin_B2" }, "inst3": { "release_rate": 208, "envelope": "envelope3", - "sound": "02" + "sound": "02_violin_B2" }, "inst4": { "release_rate": 76, "envelope": "envelope4", - "sound": "03_human_whistle" + "sound": "03_human_whistle_C3" }, "inst5": { "release_rate": 53, "envelope": "envelope5", - "sound": "04_bright_piano" + "sound": "04_bright_piano_G#3" }, "inst6": { "release_rate": 208, "envelope": "envelope6", - "sound": "05_acoustic_bass" + "sound": "05_acoustic_bass_A1" }, "percussion": [ {"release_rate": 10, "pan": 62, "envelope": "envelope7", "sound": {"sample": "06_kick_drum_1", "tuning": 0.210224}}, diff --git a/sound/sound_banks/0E.json b/sound/sound_banks/0E.json index c4404e47..76f9544f 100644 --- a/sound/sound_banks/0E.json +++ b/sound/sound_banks/0E.json @@ -51,49 +51,49 @@ "normal_range_lo": 27, "normal_range_hi": 46, "envelope": "envelope0", - "sound_lo": "23_strings_1", - "sound": "24_strings_2", - "sound_hi": "25_strings_3" + "sound_lo": "23_strings_Eb2", + "sound": "24_strings_G#2", + "sound_hi": "25_strings_F#3" }, "inst1": { "release_rate": 15, "normal_range_lo": 27, "normal_range_hi": 46, "envelope": "envelope1", - "sound_lo": "23_strings_1", - "sound": "24_strings_2", - "sound_hi": "25_strings_3" + "sound_lo": "23_strings_Eb2", + "sound": "24_strings_G#2", + "sound_hi": "25_strings_F#3" }, "inst2": { "release_rate": 15, "normal_range_lo": 27, "normal_range_hi": 46, "envelope": "envelope2", - "sound_lo": "23_strings_1", - "sound": "24_strings_2", - "sound_hi": "25_strings_3" + "sound_lo": "23_strings_Eb2", + "sound": "24_strings_G#2", + "sound_hi": "25_strings_F#3" }, "inst3": { "release_rate": 43, "normal_range_hi": 47, "envelope": "envelope3", - "sound": "46_pizzicato_strings_1", - "sound_hi": "47_pizzicato_strings_2" + "sound": "46_pizzicato_strings_Bb2", + "sound_hi": "47_pizzicato_strings_Bb3" }, "inst4": { "release_rate": 119, "envelope": "envelope4", - "sound": "2D_trombone" + "sound": "2D_trombone_Bb2" }, "inst5": { "release_rate": 10, "envelope": "envelope5", - "sound": "26_crystal_rhodes" + "sound": "26_crystal_rhodes_C4" }, "inst6": { "release_rate": 10, "envelope": "envelope6", - "sound": "26_crystal_rhodes" + "sound": "26_crystal_rhodes_C4" } }, "instrument_list": [ diff --git a/sound/sound_banks/0F.json b/sound/sound_banks/0F.json index 4924e196..e5722fa7 100644 --- a/sound/sound_banks/0F.json +++ b/sound/sound_banks/0F.json @@ -33,24 +33,24 @@ "normal_range_lo": 55, "normal_range_hi": 56, "envelope": "envelope0", - "sound_lo": "2A", - "sound": "2B", - "sound_hi": "2C" + "sound_lo": "2A_tabla_riff_1", + "sound": "2B_tabla_riff_2", + "sound_hi": "2C_tabla_riff_3" }, "inst1": { "release_rate": 10, "envelope": "envelope1", - "sound": "22_boys_choir" + "sound": "22_boys_choir_Bb4" }, "inst2": { "release_rate": 90, "envelope": "envelope2", - "sound": "28_sitar_1" + "sound": "28_sitar_1_A2" }, "inst3": { "release_rate": 10, "envelope": "envelope3", - "sound": "39_sitar_2" + "sound": "39_sitar_2_C#3" } }, "instrument_list": [ diff --git a/sound/sound_banks/10.json b/sound/sound_banks/10.json index 1edec836..99e240cb 100644 --- a/sound/sound_banks/10.json +++ b/sound/sound_banks/10.json @@ -49,32 +49,32 @@ "inst0": { "release_rate": 10, "envelope": "envelope0", - "sound": "3E_monk_choir" + "sound": "3E_monk_choir_B2" }, "inst1": { "release_rate": 10, "envelope": "envelope1", - "sound": "3E_monk_choir" + "sound": "3E_monk_choir_B2" }, "inst2": { "release_rate": 208, "envelope": "envelope2", - "sound": "3F" + "sound": "3F_small_gamelan" }, "inst3": { "release_rate": 10, "envelope": "envelope3", - "sound": "40_bell" + "sound": "40_fu_yin_gong_C4" }, "inst4": { "release_rate": 10, "envelope": "envelope4", - "sound": "40_bell" + "sound": "40_fu_yin_gong_C4" }, "inst5": { "release_rate": 10, "envelope": "envelope5", - "sound": "40_bell" + "sound": "40_fu_yin_gong_C4" }, "percussion": [ {"release_rate": 10, "pan": 62, "envelope": "envelope6", "sound": {"sample": "06_kick_drum_1", "tuning": 0.210224}}, diff --git a/sound/sound_banks/11.json b/sound/sound_banks/11.json index 69dc21c1..01d71023 100644 --- a/sound/sound_banks/11.json +++ b/sound/sound_banks/11.json @@ -94,37 +94,37 @@ "inst1": { "release_rate": 208, "envelope": "envelope1", - "sound": "21_sine_bass" + "sound": "21_sine_bass_Bb2" }, "inst2": { "release_rate": 208, "envelope": "envelope2", - "sound": "35_gospel_organ" + "sound": "35_gospel_organ_F4" }, "inst3": { "release_rate": 10, "envelope": "envelope3", - "sound": "48_steel_drum" + "sound": "48_steel_drum_C#3" }, "inst4": { "release_rate": 208, "envelope": "envelope4", - "sound": "19_brass" + "sound": "19_brass_Eb3" }, "inst5": { "release_rate": 208, "envelope": "envelope5", - "sound": "1A_slap_bass" + "sound": "1A_slap_bass_G#2" }, "inst6": { "release_rate": 128, "envelope": "envelope6", - "sound": "1B_organ_2" + "sound": "1B_percussive_synth_Eb3" }, "inst7": { "release_rate": 208, "envelope": "envelope7", - "sound": "1C" + "sound": "1C_les_paul_guitar_E2" }, "percussion": [ {"release_rate": 10, "pan": 62, "envelope": "envelope8", "sound": {"sample": "06_kick_drum_1", "tuning": 0.210224}}, diff --git a/sound/sound_banks/12.json b/sound/sound_banks/12.json index 93f34b34..b6bd1ba9 100644 --- a/sound/sound_banks/12.json +++ b/sound/sound_banks/12.json @@ -61,17 +61,17 @@ "inst0": { "release_rate": 10, "envelope": "envelope0", - "sound": "30_rarefaction-lahna" + "sound": "30_rarefaction-lahna_E4" }, "inst1": { "release_rate": 208, "envelope": "envelope1", - "sound": "31_rarefaction-convolution" + "sound": "31_rarefaction-convolution_Eb2" }, "inst2": { "release_rate": 208, "envelope": "envelope2", - "sound": "31_rarefaction-convolution" + "sound": "31_rarefaction-convolution_Eb2" }, "inst3": { "release_rate": 10, @@ -101,21 +101,21 @@ "inst6": { "release_rate": 208, "envelope": "envelope6", - "sound": "29_orchestra_hit" + "sound": "29_orchestra_hit_C3" }, "inst7": { "release_rate": 114, "envelope": "envelope7", - "sound": "34_alto_flute" + "sound": "34_alto_flute_A4" }, "inst8": { "release_rate": 15, "normal_range_lo": 27, "normal_range_hi": 46, "envelope": "envelope8", - "sound_lo": "23_strings_1", - "sound": "24_strings_2", - "sound_hi": "25_strings_3" + "sound_lo": "23_strings_Eb2", + "sound": "24_strings_G#2", + "sound_hi": "25_strings_F#3" } }, "instrument_list": [ diff --git a/sound/sound_banks/13.json b/sound/sound_banks/13.json index 53da9e97..46bf8b39 100644 --- a/sound/sound_banks/13.json +++ b/sound/sound_banks/13.json @@ -57,23 +57,23 @@ "normal_range_lo": 27, "normal_range_hi": 46, "envelope": "envelope0", - "sound_lo": "23_strings_1", - "sound": "24_strings_2", - "sound_hi": "25_strings_3" + "sound_lo": "23_strings_Eb2", + "sound": "24_strings_G#2", + "sound_hi": "25_strings_F#3" }, "inst1": { "release_rate": 15, "normal_range_lo": 27, "normal_range_hi": 46, "envelope": "envelope1", - "sound_lo": "23_strings_1", - "sound": "24_strings_2", - "sound_hi": "25_strings_3" + "sound_lo": "23_strings_Eb2", + "sound": "24_strings_G#2", + "sound_hi": "25_strings_F#3" }, "inst2": { "release_rate": 208, "envelope": "envelope2", - "sound": "21_sine_bass" + "sound": "21_sine_bass_Bb2" }, "percussion": [ {"release_rate": 10, "pan": 62, "envelope": "envelope3", "sound": {"sample": "06_kick_drum_1", "tuning": 0.210224}}, @@ -160,12 +160,12 @@ "inst5": { "release_rate": 10, "envelope": "envelope6", - "sound": "26_crystal_rhodes" + "sound": "26_crystal_rhodes_C4" }, "inst6": { "release_rate": 10, "envelope": "envelope7", - "sound": "26_crystal_rhodes" + "sound": "26_crystal_rhodes_C4" } }, "instrument_list": [ diff --git a/sound/sound_banks/14_piranha_music_box.json b/sound/sound_banks/14_piranha_music_box.json index 2a920394..1aa3f78e 100644 --- a/sound/sound_banks/14_piranha_music_box.json +++ b/sound/sound_banks/14_piranha_music_box.json @@ -1,6 +1,6 @@ { "date": "1996-03-19", - "sample_bank": {"ifdef": ["VERSION_SH"], "then": "instruments", "else": "piranha_music_box"}, + "sample_bank": {"ifdef": ["VERSION_SH", "VERSION_CN"], "then": "instruments", "else": "piranha_music_box"}, "envelopes": { "envelope0": [ [6, 32700], @@ -37,27 +37,27 @@ "inst0": { "release_rate": 119, "envelope": "envelope0", - "sound": {"ifdef": ["VERSION_SH"], "then": "3A_music_box", "else": "00_music_box"} + "sound": {"ifdef": ["VERSION_SH", "VERSION_CN"], "then": "3A_music_box_C5", "else": "00_music_box_C5"} }, "inst1": { "release_rate": 119, "envelope": "envelope1", - "sound": {"ifdef": ["VERSION_SH"], "then": "3A_music_box", "else": "00_music_box"} + "sound": {"ifdef": ["VERSION_SH", "VERSION_CN"], "then": "3A_music_box_C5", "else": "00_music_box_C5"} }, "inst2": { "release_rate": 119, "envelope": "envelope2", - "sound": {"ifdef": ["VERSION_SH"], "then": "3A_music_box", "else": "00_music_box"} + "sound": {"ifdef": ["VERSION_SH", "VERSION_CN"], "then": "3A_music_box_C5", "else": "00_music_box_C5"} }, "inst3": { "release_rate": 119, "envelope": "envelope3", - "sound": {"ifdef": ["VERSION_SH"], "then": "3A_music_box", "else": "00_music_box"} + "sound": {"ifdef": ["VERSION_SH", "VERSION_CN"], "then": "3A_music_box_C5", "else": "00_music_box_C5"} }, "inst4": { "release_rate": 119, "envelope": "envelope4", - "sound": {"ifdef": ["VERSION_SH"], "then": "3A_music_box", "else": "00_music_box"} + "sound": {"ifdef": ["VERSION_SH", "VERSION_CN"], "then": "3A_music_box_C5", "else": "00_music_box_C5"} } }, "instrument_list": [ diff --git a/sound/sound_banks/15.json b/sound/sound_banks/15.json index c89e2e94..eb45ef4d 100644 --- a/sound/sound_banks/15.json +++ b/sound/sound_banks/15.json @@ -81,22 +81,22 @@ "inst2": { "release_rate": 10, "envelope": "envelope2", - "sound": "21_sine_bass" + "sound": "21_sine_bass_Bb2" }, "inst3": { "release_rate": 208, "envelope": "envelope3", - "sound": "1A_slap_bass" + "sound": "1A_slap_bass_G#2" }, "inst4": { "release_rate": 114, "envelope": "envelope4", - "sound": "21_sine_bass" + "sound": "21_sine_bass_Bb2" }, "inst5": { "release_rate": 53, "envelope": "envelope5", - "sound": "04_bright_piano" + "sound": "04_bright_piano_G#3" }, "inst6": { "release_rate": 208, @@ -106,12 +106,12 @@ "inst7": { "release_rate": 10, "envelope": "envelope7", - "sound": "22_boys_choir" + "sound": "22_boys_choir_Bb4" }, "inst8": { "release_rate": 10, "envelope": "envelope8", - "sound": "22_boys_choir" + "sound": "22_boys_choir_Bb4" }, "percussion": [ {"release_rate": 10, "pan": 62, "envelope": "envelope9", "sound": {"sample": "06_kick_drum_1", "tuning": 0.210224}}, diff --git a/sound/sound_banks/16_course_start.json b/sound/sound_banks/16_course_start.json index cd348d2f..3e4bca2b 100644 --- a/sound/sound_banks/16_course_start.json +++ b/sound/sound_banks/16_course_start.json @@ -1,6 +1,6 @@ { "date": "1996-03-19", - "sample_bank": {"ifdef": ["VERSION_SH"], "then": "instruments", "else": "course_start"}, + "sample_bank": {"ifdef": ["VERSION_SH", "VERSION_CN"], "then": "instruments", "else": "course_start"}, "envelopes": { "envelope0": [ [2, 32700], @@ -19,12 +19,12 @@ "inst0": { "release_rate": 208, "envelope": "envelope0", - "sound": {"ifdef": ["VERSION_SH"], "then": "45b_la", "else": "00_la"} + "sound": {"ifdef": ["VERSION_SH", "VERSION_CN"], "then": "45b_la_E3", "else": "00_la_E3"} }, "inst1": { "release_rate": 208, "envelope": "envelope1", - "sound": {"ifdef": ["VERSION_SH"], "then": "45b_la", "else": "00_la"} + "sound": {"ifdef": ["VERSION_SH", "VERSION_CN"], "then": "45b_la_E3", "else": "00_la_E3"} } }, "instrument_list": [ diff --git a/sound/sound_banks/17.json b/sound/sound_banks/17.json index d0fab404..63563ca2 100644 --- a/sound/sound_banks/17.json +++ b/sound/sound_banks/17.json @@ -63,37 +63,37 @@ "normal_range_lo": 29, "normal_range_hi": 63, "envelope": "envelope0", - "sound_lo": "3B_banjo_2", - "sound": "3C_acoustic_guitar", - "sound_hi": "3D" + "sound_lo": "3B_acoustic_guitar_A1", + "sound": "3C_acoustic_guitar_E3", + "sound_hi": "3D_acoustic_guitar_B6" }, "inst1": { "release_rate": 208, "envelope": "envelope1", - "sound": "05_acoustic_bass" + "sound": "05_acoustic_bass_A1" }, "inst2": { "release_rate": 15, "normal_range_lo": 27, "normal_range_hi": 46, "envelope": "envelope2", - "sound_lo": "23_strings_1", - "sound": "24_strings_2", - "sound_hi": "25_strings_3" + "sound_lo": "23_strings_Eb2", + "sound": "24_strings_G#2", + "sound_hi": "25_strings_F#3" }, "inst3": { "release_rate": 15, "normal_range_lo": 27, "normal_range_hi": 46, "envelope": "envelope3", - "sound_lo": "23_strings_1", - "sound": "24_strings_2", - "sound_hi": "25_strings_3" + "sound_lo": "23_strings_Eb2", + "sound": "24_strings_G#2", + "sound_hi": "25_strings_F#3" }, "inst4": { "release_rate": 10, "envelope": "envelope4", - "sound": "26_crystal_rhodes" + "sound": "26_crystal_rhodes_C4" }, "percussion": [ {"release_rate": 10, "pan": 62, "envelope": "envelope5", "sound": {"sample": "06_kick_drum_1", "tuning": 0.210224}}, diff --git a/sound/sound_banks/18.json b/sound/sound_banks/18.json index 6f09dbb4..da40131f 100644 --- a/sound/sound_banks/18.json +++ b/sound/sound_banks/18.json @@ -61,22 +61,22 @@ "inst0": { "release_rate": 208, "envelope": "envelope0", - "sound": "35_gospel_organ" + "sound": "35_gospel_organ_F4" }, "inst1": { "release_rate": 208, "envelope": "envelope1", - "sound": "36_sawtooth_synth" + "sound": "36_sawtooth_synth_Eb1" }, "inst2": { "release_rate": 208, "envelope": "envelope2", - "sound": "37_square_synth" + "sound": "37_square_synth_C5" }, "inst3": { "release_rate": 208, "envelope": "envelope3", - "sound": "29_orchestra_hit" + "sound": "29_orchestra_hit_C3" }, "percussion": [ {"release_rate": 10, "pan": 62, "envelope": "envelope4", "sound": {"sample": "06_kick_drum_1", "tuning": 0.210224}}, diff --git a/sound/sound_banks/19.json b/sound/sound_banks/19.json index 1591ea88..2d743fd3 100644 --- a/sound/sound_banks/19.json +++ b/sound/sound_banks/19.json @@ -79,50 +79,50 @@ "inst0": { "release_rate": 10, "envelope": "envelope0", - "sound": "22_boys_choir" + "sound": "22_boys_choir_Bb4" }, "inst1": { "release_rate": 208, "envelope": "envelope1", - "sound": "19_brass" + "sound": "19_brass_Eb3" }, "inst2": { "release_rate": 15, "normal_range_lo": 27, "normal_range_hi": 46, "envelope": "envelope2", - "sound_lo": "23_strings_1", - "sound": "24_strings_2", - "sound_hi": "25_strings_3" + "sound_lo": "23_strings_Eb2", + "sound": "24_strings_G#2", + "sound_hi": "25_strings_F#3" }, "inst3": { "release_rate": 90, "envelope": "envelope3", - "sound": "28_sitar_1" + "sound": "28_sitar_1_A2" }, "inst4": { "release_rate": 208, "envelope": "envelope4", - "sound": "29_orchestra_hit" + "sound": "29_orchestra_hit_C3" }, "inst5": { "release_rate": 100, "normal_range_lo": 55, "normal_range_hi": 56, "envelope": "envelope5", - "sound_lo": "2A", - "sound": "2B", - "sound_hi": "2C" + "sound_lo": "2A_tabla_riff_1", + "sound": "2B_tabla_riff_2", + "sound_hi": "2C_tabla_riff_3" }, "inst6": { "release_rate": 208, "envelope": "envelope6", - "sound": "19_brass" + "sound": "19_brass_Eb3" }, "inst7": { "release_rate": 10, "envelope": "envelope7", - "sound": "22_boys_choir" + "sound": "22_boys_choir_Bb4" }, "percussion": [ {"release_rate": 10, "pan": 62, "envelope": "envelope8", "sound": {"sample": "06_kick_drum_1", "tuning": 0.210224}}, diff --git a/sound/sound_banks/1A.json b/sound/sound_banks/1A.json index a648d86a..1b8c21bc 100644 --- a/sound/sound_banks/1A.json +++ b/sound/sound_banks/1A.json @@ -61,34 +61,34 @@ "inst0": { "release_rate": 67, "envelope": "envelope0", - "sound": "17_trumpet" + "sound": "17_trumpet_C#3" }, "inst1": { "release_rate": 119, "envelope": "envelope1", - "sound": "2D_trombone" + "sound": "2D_trombone_Bb2" }, "inst2": { "release_rate": 208, "envelope": "envelope2", - "sound": "16_french_horns" + "sound": "16_french_horns_C3" }, "inst3": { "release_rate": 24, "normal_range_lo": 42, "envelope": "envelope3", - "sound_lo": "14_strings_5", - "sound": "15_strings_4" + "sound_lo": "14_strings_Eb2", + "sound": "15_strings_B3" }, "inst4": { "release_rate": 208, "envelope": "envelope4", - "sound": "19_brass" + "sound": "19_brass_Eb3" }, "inst5": { "release_rate": 10, "envelope": "envelope5", - "sound": "26_crystal_rhodes" + "sound": "26_crystal_rhodes_C4" }, "inst6": { "release_rate": 10, diff --git a/sound/sound_banks/1B.json b/sound/sound_banks/1B.json index 472df84a..754cac38 100644 --- a/sound/sound_banks/1B.json +++ b/sound/sound_banks/1B.json @@ -62,32 +62,32 @@ "release_rate": 24, "normal_range_lo": 42, "envelope": "envelope0", - "sound_lo": "14_strings_5", - "sound": "15_strings_4" + "sound_lo": "14_strings_Eb2", + "sound": "15_strings_B3" }, "inst1": { "release_rate": 24, "normal_range_lo": 42, "envelope": "envelope1", - "sound_lo": "14_strings_5", - "sound": "15_strings_4" + "sound_lo": "14_strings_Eb2", + "sound": "15_strings_B3" }, "inst2": { "release_rate": 208, "envelope": "envelope2", - "sound": "16_french_horns" + "sound": "16_french_horns_C3" }, "inst3": { "release_rate": 67, "envelope": "envelope3", - "sound": "17_trumpet" + "sound": "17_trumpet_C#3" }, "inst4": { "release_rate": 24, "normal_range_lo": 42, "envelope": "envelope4", - "sound_lo": "14_strings_5", - "sound": "15_strings_4" + "sound_lo": "14_strings_Eb2", + "sound": "15_strings_B3" }, "inst5": { "release_rate": 10, diff --git a/sound/sound_banks/1C_endless_stairs.json b/sound/sound_banks/1C_endless_stairs.json index 2f4f5058..fd74be20 100644 --- a/sound/sound_banks/1C_endless_stairs.json +++ b/sound/sound_banks/1C_endless_stairs.json @@ -43,38 +43,38 @@ "inst0": { "release_rate": 119, "envelope": "envelope0", - "sound": "3A_music_box" + "sound": "3A_music_box_C5" }, "inst1": { "release_rate": 119, "envelope": "envelope1", - "sound": "3A_music_box" + "sound": "3A_music_box_C5" }, "inst2": { "release_rate": 119, "envelope": "envelope2", - "sound": "3A_music_box" + "sound": "3A_music_box_C5" }, "inst3": { "release_rate": 24, "normal_range_lo": 42, "envelope": "envelope3", - "sound_lo": "14_strings_5", - "sound": "15_strings_4" + "sound_lo": "14_strings_Eb2", + "sound": "15_strings_B3" }, "inst4": { "release_rate": 24, "normal_range_lo": 42, "envelope": "envelope4", - "sound_lo": "14_strings_5", - "sound": "15_strings_4" + "sound_lo": "14_strings_Eb2", + "sound": "15_strings_B3" }, "inst5": { "release_rate": 24, "normal_range_lo": 42, "envelope": "envelope5", - "sound_lo": "14_strings_5", - "sound": "15_strings_4" + "sound_lo": "14_strings_Eb2", + "sound": "15_strings_B3" } }, "instrument_list": [ diff --git a/sound/sound_banks/1D_bowser_organ.json b/sound/sound_banks/1D_bowser_organ.json index 64f26213..31f752e2 100644 --- a/sound/sound_banks/1D_bowser_organ.json +++ b/sound/sound_banks/1D_bowser_organ.json @@ -1,6 +1,6 @@ { "date": "1996-03-19", - "sample_bank": {"ifdef": ["VERSION_SH"], "then": "instruments", "else": "bowser_organ"}, + "sample_bank": {"ifdef": ["VERSION_SH", "VERSION_CN"], "then": "instruments", "else": "bowser_organ"}, "envelopes": { "envelope0": [ [2, 32700], @@ -44,41 +44,41 @@ "release_rate": 19, "normal_range_hi": 50, "envelope": "envelope0", - "sound": {"ifdef": ["VERSION_SH"], "then": "34b_organ", "else": "00_organ_1"}, - "sound_hi": {"ifdef": ["VERSION_SH"], "then": "34c_organ_lq", "else": "01_organ_1_lq"} + "sound": {"ifdef": ["VERSION_SH", "VERSION_CN"], "then": "34b_organ_C3", "else": "00_organ_C3"}, + "sound_hi": {"ifdef": ["VERSION_SH", "VERSION_CN"], "then": "34c_organ_C4", "else": "01_organ_C4"} }, "inst1": { "release_rate": 19, "normal_range_hi": 50, "envelope": "envelope1", - "sound": {"ifdef": ["VERSION_SH"], "then": "34b_organ", "else": "00_organ_1"}, - "sound_hi": {"ifdef": ["VERSION_SH"], "then": "34c_organ_lq", "else": "01_organ_1_lq"} + "sound": {"ifdef": ["VERSION_SH", "VERSION_CN"], "then": "34b_organ_C3", "else": "00_organ_C3"}, + "sound_hi": {"ifdef": ["VERSION_SH", "VERSION_CN"], "then": "34c_organ_C4", "else": "01_organ_C4"} }, "inst2": { "release_rate": 19, "normal_range_hi": 50, "envelope": "envelope2", - "sound": {"ifdef": ["VERSION_SH"], "then": "34b_organ", "else": "00_organ_1"}, - "sound_hi": {"ifdef": ["VERSION_SH"], "then": "34c_organ_lq", "else": "01_organ_1_lq"} + "sound": {"ifdef": ["VERSION_SH", "VERSION_CN"], "then": "34b_organ_C3", "else": "00_organ_C3"}, + "sound_hi": {"ifdef": ["VERSION_SH", "VERSION_CN"], "then": "34c_organ_C4", "else": "01_organ_C4"} }, "inst3": { "release_rate": 19, "normal_range_hi": 50, "envelope": "envelope3", - "sound": {"ifdef": ["VERSION_SH"], "then": "34b_organ", "else": "00_organ_1"}, - "sound_hi": {"ifdef": ["VERSION_SH"], "then": "34c_organ_lq", "else": "01_organ_1_lq"} + "sound": {"ifdef": ["VERSION_SH", "VERSION_CN"], "then": "34b_organ_C3", "else": "00_organ_C3"}, + "sound_hi": {"ifdef": ["VERSION_SH", "VERSION_CN"], "then": "34c_organ_C4", "else": "01_organ_C4"} }, "inst4": { "release_rate": 19, "normal_range_hi": 50, "envelope": "envelope4", - "sound": {"ifdef": ["VERSION_SH"], "then": "34b_organ", "else": "00_organ_1"}, - "sound_hi": {"ifdef": ["VERSION_SH"], "then": "34c_organ_lq", "else": "01_organ_1_lq"} + "sound": {"ifdef": ["VERSION_SH", "VERSION_CN"], "then": "34b_organ_C3", "else": "00_organ_C3"}, + "sound_hi": {"ifdef": ["VERSION_SH", "VERSION_CN"], "then": "34c_organ_C4", "else": "01_organ_C4"} }, "inst5": { "release_rate": 10, "envelope": "envelope5", - "sound": {"ifdef": ["VERSION_SH"], "then": "22_boys_choir", "else": "02_boys_choir"} + "sound": {"ifdef": ["VERSION_SH", "VERSION_CN"], "then": "22_boys_choir_Bb4", "else": "02_boys_choir_Bb4"} } }, "instrument_list": [ diff --git a/sound/sound_banks/1E.json b/sound/sound_banks/1E.json index 2b458354..4cca82c7 100644 --- a/sound/sound_banks/1E.json +++ b/sound/sound_banks/1E.json @@ -31,30 +31,30 @@ "inst0": { "release_rate": 255, "envelope": "envelope0", - "sound": "27_harpsichord" + "sound": "27_harpsichord_F3" }, "inst1": { "release_rate": 255, "envelope": "envelope1", - "sound": "27_harpsichord" + "sound": "27_harpsichord_F3" }, "inst2": { "release_rate": 15, "normal_range_lo": 27, "normal_range_hi": 46, "envelope": "envelope2", - "sound_lo": "23_strings_1", - "sound": "24_strings_2", - "sound_hi": "25_strings_3" + "sound_lo": "23_strings_Eb2", + "sound": "24_strings_G#2", + "sound_hi": "25_strings_F#3" }, "inst3": { "release_rate": 15, "normal_range_lo": 27, "normal_range_hi": 46, "envelope": "envelope3", - "sound_lo": "23_strings_1", - "sound": "24_strings_2", - "sound_hi": "25_strings_3" + "sound_lo": "23_strings_Eb2", + "sound": "24_strings_G#2", + "sound_hi": "25_strings_F#3" } }, "instrument_list": [ diff --git a/sound/sound_banks/1F.json b/sound/sound_banks/1F.json index 66d2697f..da585e59 100644 --- a/sound/sound_banks/1F.json +++ b/sound/sound_banks/1F.json @@ -31,12 +31,12 @@ "inst0": { "release_rate": 208, "envelope": "envelope0", - "sound": "2E_accordion" + "sound": "2E_accordion_C4" }, "inst1": { "release_rate": 208, "envelope": "envelope1", - "sound": "2E_accordion" + "sound": "2E_accordion_C4" }, "inst2": { "release_rate": 208, diff --git a/sound/sound_banks/20.json b/sound/sound_banks/20.json index 498a3824..5e1773a0 100644 --- a/sound/sound_banks/20.json +++ b/sound/sound_banks/20.json @@ -25,21 +25,21 @@ "inst0": { "release_rate": 208, "envelope": "envelope0", - "sound": "16_french_horns" + "sound": "16_french_horns_C3" }, "inst1": { "release_rate": 208, "envelope": "envelope1", - "sound": "16_french_horns" + "sound": "16_french_horns_C3" }, "inst2": { "release_rate": 15, "normal_range_lo": 27, "normal_range_hi": 46, "envelope": "envelope2", - "sound_lo": "23_strings_1", - "sound": "24_strings_2", - "sound_hi": "25_strings_3" + "sound_lo": "23_strings_Eb2", + "sound": "24_strings_G#2", + "sound_hi": "25_strings_F#3" } }, "instrument_list": [ diff --git a/sound/sound_banks/21.json b/sound/sound_banks/21.json index c33c4e87..e14426a2 100644 --- a/sound/sound_banks/21.json +++ b/sound/sound_banks/21.json @@ -25,17 +25,17 @@ "inst0": { "release_rate": 208, "envelope": "envelope0", - "sound": "2E_accordion" + "sound": "2E_accordion_C4" }, "inst1": { "release_rate": 208, "envelope": "envelope1", - "sound": "2E_accordion" + "sound": "2E_accordion_C4" }, "inst2": { "release_rate": 10, "envelope": "envelope2", - "sound": "26_crystal_rhodes" + "sound": "26_crystal_rhodes_C4" } }, "instrument_list": [ diff --git a/sound/sound_banks/22.json b/sound/sound_banks/22.json index 3a80b4aa..7e2ba768 100644 --- a/sound/sound_banks/22.json +++ b/sound/sound_banks/22.json @@ -49,22 +49,22 @@ "inst0": { "release_rate": 208, "envelope": "envelope0", - "sound": "19_brass" + "sound": "19_brass_Eb3" }, "inst1": { "release_rate": 208, "envelope": "envelope1", - "sound": "1A_slap_bass" + "sound": "1A_slap_bass_G#2" }, "inst2": { "release_rate": 128, "envelope": "envelope2", - "sound": "1B_organ_2" + "sound": "1B_percussive_synth_Eb3" }, "inst3": { "release_rate": 208, "envelope": "envelope3", - "sound": "1C" + "sound": "1C_les_paul_guitar_E2" }, "percussion": [ {"release_rate": 10, "pan": 62, "envelope": "envelope4", "sound": {"sample": "06_kick_drum_1", "tuning": 0.210224}}, diff --git a/sound/sound_banks/23.json b/sound/sound_banks/23.json index 848d2f79..46e9ca50 100644 --- a/sound/sound_banks/23.json +++ b/sound/sound_banks/23.json @@ -45,42 +45,42 @@ "normal_range_lo": 27, "normal_range_hi": 46, "envelope": "envelope0", - "sound_lo": "23_strings_1", - "sound": "24_strings_2", - "sound_hi": "25_strings_3" + "sound_lo": "23_strings_Eb2", + "sound": "24_strings_G#2", + "sound_hi": "25_strings_F#3" }, "inst1": { "release_rate": 15, "normal_range_lo": 27, "normal_range_hi": 46, "envelope": "envelope1", - "sound_lo": "23_strings_1", - "sound": "24_strings_2", - "sound_hi": "25_strings_3" + "sound_lo": "23_strings_Eb2", + "sound": "24_strings_G#2", + "sound_hi": "25_strings_F#3" }, "inst2": { "release_rate": 15, "normal_range_lo": 27, "normal_range_hi": 46, "envelope": "envelope2", - "sound_lo": "23_strings_1", - "sound": "24_strings_2", - "sound_hi": "25_strings_3" + "sound_lo": "23_strings_Eb2", + "sound": "24_strings_G#2", + "sound_hi": "25_strings_F#3" }, "inst3": { "release_rate": 10, "envelope": "envelope3", - "sound": "26_crystal_rhodes" + "sound": "26_crystal_rhodes_C4" }, "inst4": { "release_rate": 10, "envelope": "envelope4", - "sound": "26_crystal_rhodes" + "sound": "26_crystal_rhodes_C4" }, "inst5": { "release_rate": 255, "envelope": "envelope5", - "sound": "27_harpsichord" + "sound": "27_harpsichord_F3" } }, "instrument_list": [ diff --git a/sound/sound_banks/24.json b/sound/sound_banks/24.json index d205b003..828ad682 100644 --- a/sound/sound_banks/24.json +++ b/sound/sound_banks/24.json @@ -37,19 +37,19 @@ "inst0": { "release_rate": 43, "envelope": "envelope0", - "sound": "41_pan_flute" + "sound": "41_pan_flute_C3" }, "inst1": { "release_rate": 24, "normal_range_lo": 42, "envelope": "envelope1", - "sound_lo": "14_strings_5", - "sound": "15_strings_4" + "sound_lo": "14_strings_Eb2", + "sound": "15_strings_B3" }, "inst2": { "release_rate": 43, "envelope": "envelope3", - "sound": "41_pan_flute" + "sound": "41_pan_flute_C3" }, "percussion": [ {"release_rate": 10, "pan": 62, "envelope": "envelope2", "sound": {"sample": "06_kick_drum_1", "tuning": 0.210224}}, @@ -120,7 +120,7 @@ "inst3": { "release_rate": 10, "envelope": "envelope4", - "sound": "22_boys_choir" + "sound": "22_boys_choir_Bb4" } }, "instrument_list": [ diff --git a/sound/sound_banks/25.json b/sound/sound_banks/25.json index 82db2dc8..10e1dda7 100644 --- a/sound/sound_banks/25.json +++ b/sound/sound_banks/25.json @@ -97,34 +97,34 @@ "inst0": { "release_rate": 19, "envelope": "envelope0", - "sound": "43_harmonica" + "sound": "43_harmonica_C4" }, "inst1": { "release_rate": 208, "envelope": "envelope1", - "sound": "1A_slap_bass" + "sound": "1A_slap_bass_G#2" }, "inst2": { "release_rate": 208, "envelope": "envelope2", - "sound": "1C" + "sound": "1C_les_paul_guitar_E2" }, "inst3": { "release_rate": 10, "envelope": "envelope3", - "sound": "26_crystal_rhodes" + "sound": "26_crystal_rhodes_C4" }, "inst4": { "release_rate": 34, "envelope": "envelope4", - "sound": "44_grand_piano" + "sound": "44_grand_piano_F#5" }, "inst5": { "release_rate": 53, "normal_range_hi": 50, "envelope": "envelope5", - "sound": "16_french_horns", - "sound_hi": "45_french_horns_lq" + "sound": "16_french_horns_C3", + "sound_hi": "45_french_horns_C4" }, "inst6": { "release_rate": 10, @@ -154,31 +154,31 @@ "inst9": { "release_rate": 43, "envelope": "envelope9", - "sound": "41_pan_flute" + "sound": "41_pan_flute_C3" }, "inst10": { "release_rate": 15, "normal_range_lo": 27, "normal_range_hi": 46, "envelope": "envelope10", - "sound_lo": "23_strings_1", - "sound": "24_strings_2", - "sound_hi": "25_strings_3" + "sound_lo": "23_strings_Eb2", + "sound": "24_strings_G#2", + "sound_hi": "25_strings_F#3" }, "inst11": { "release_rate": 10, "envelope": "envelope12", - "sound": "44_grand_piano" + "sound": "44_grand_piano_F#5" }, "inst12": { "release_rate": 10, "envelope": "envelope13", - "sound": "26_crystal_rhodes" + "sound": "26_crystal_rhodes_C4" }, "inst13": { "release_rate": 34, "envelope": "envelope14", - "sound": "43_harmonica" + "sound": "43_harmonica_C4" }, "percussion": [ {"release_rate": 10, "pan": 62, "envelope": "envelope11", "sound": {"sample": "06_kick_drum_1", "tuning": 0.210224}}, diff --git a/sound/sound_data.c b/sound/sound_data.c index 84c6616a..2984889c 100644 --- a/sound/sound_data.c +++ b/sound/sound_data.c @@ -10,7 +10,7 @@ unsigned char gMusicData[] = { #include "sound/sequences.bin.inc.c" }; -#ifndef VERSION_SH +#if !defined(VERSION_SH) && !defined(VERSION_CN) unsigned char gBankSetsData[] = { #include "sound/bank_sets.inc.c" }; diff --git a/src/audio/audio_session_presets_sh.c b/src/audio/audio_session_presets_sh.c index 958ec15a..6da66159 100644 --- a/src/audio/audio_session_presets_sh.c +++ b/src/audio/audio_session_presets_sh.c @@ -1,7 +1,7 @@ #include "internal.h" #include "data.h" -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) struct ReverbSettingsEU sReverbSettings[] = { {0x01, 0x30, 0x2fff, 0x0000, 0x0000, -1, 0x3000, 0x0000, 0x0000}, diff --git a/src/audio/data.c b/src/audio/data.c index f8495bbb..f5217f08 100644 --- a/src/audio/data.c +++ b/src/audio/data.c @@ -100,7 +100,7 @@ u16 gAudioCosineTable[128] = { // Transforms a pitch scale factor in -127..127 into a frequency scale factor // between -1 and +1 octave. // gPitchBendFrequencyScale[k] = 0.5 * 2^(k/127) -#ifndef VERSION_SH +#if !defined(VERSION_SH) && !defined(VERSION_CN) #if defined(VERSION_EU) f32 gPitchBendFrequencyScale[256] = { 0.5f, @@ -186,7 +186,7 @@ struct NoteSubEu gZeroNoteSub = { 0 }; struct NoteSubEu gDefaultNoteSub = { 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, { NULL } }; #endif -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) s16 sSawtoothWaves[256] = { 0, 1023, 2047, 3071, 4095, 5119, 6143, 7167, 8191, 9215, 10239, 11263, 0x2FFF, 13311, 0x37FF, 15359, 0x3FFF, 17407, 0x47FF, 19455, 0x4FFF, 21503, @@ -379,7 +379,7 @@ s16 sSawtoothWave[0x40] = { s16 *gWaveSamples[4] = { sSawtoothWave, sTriangleWave, sSineWave, sSquareWave }; #endif -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) s32 unk_sh_data_0[2] = {0, 0}; f32 gPitchBendFrequencyScale[256] = { 0.5f, 0.5f, 0.502736f, 0.505488f, 0.508254f, 0.511036f, 0.513833f, 0.516645f, 0.519472f, @@ -414,7 +414,7 @@ f32 gPitchBendFrequencyScale[256] = { }; #endif -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) f32 unk_sh_data_1[] = { 0.890899f, 0.890899f, 0.89171f, 0.892521f, 0.893333f, 0.894146f, 0.89496f, 0.895774f, 0.89659f, 0.897406f, 0.898222f, 0.89904f, 0.899858f, 0.900677f, 0.901496f, 0.902317f, @@ -486,7 +486,7 @@ u8 unk_sh_data2[4] = { 0, 0, 0, 0 }; struct NoteSubEu gZeroNoteSub = { 0 }; struct NoteSubEu gDefaultNoteSub = { 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, { NULL }, -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) 0 #endif }; @@ -506,11 +506,11 @@ u8 euUnknownData_8030194c[4] = { 0x40, 0x20, 0x10, 0x08 }; u16 gHeadsetPanQuantization[0x10] = { 0x40, 0x40, 0x30, 0x30, 0x20, 0x20, 0x10, 0, 0, 0, }; -#elif !defined(VERSION_SH) +#elif defined(VERSION_JP) || defined(VERSION_US) u16 gHeadsetPanQuantization[10] = { 0x40, 0x30, 0x20, 0x10, 0, 0, 0, 0, 0, 0 }; #endif -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) s16 euUnknownData_80301950[64] = { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 500, 0, 0, 0, 0, 0, 0, 0, 500, 0, 0, 0, 0, 0, 0, 0, 500, 0, 0, 0, 0, 0, 0, 0, 500, 0, 0, 0, 0, @@ -710,7 +710,7 @@ f32 gVolRampingRhs128[128] = { }; #endif -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) u16 unk_sh_data_3[] = { // 30 entries // pattern: @@ -879,7 +879,7 @@ u16 unk_sh_data_4[] = { }; #endif -#ifndef VERSION_SH +#if !defined(VERSION_SH) && !defined(VERSION_CN) s16 gTatumsPerBeat = TATUMS_PER_BEAT; s8 gUnusedCount80333EE8 = UNUSED_COUNT_80333EE8; s32 gAudioHeapSize = DOUBLE_SIZE_ON_64_BIT(AUDIO_HEAP_SIZE); @@ -901,7 +901,7 @@ s8 sUnused8033EF8 = 24; volatile s32 gAudioFrameCount; -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) s32 gCurrAudioFrameDmaCount; #else volatile s32 gCurrAudioFrameDmaCount; @@ -916,7 +916,7 @@ u64 *gAudioCmd; struct SPTask *gAudioTask; struct SPTask gAudioTasks[2]; -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) f32 D_EU_802298D0; s32 gRefreshRate; #endif @@ -931,11 +931,11 @@ u16 gUnused80226E98[0x10]; u32 gAudioRandom; -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) s32 gAudioErrorFlags; #endif -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) volatile u32 gAudioLoadLockSH; struct EuAudioCmd sAudioCmd[0x100]; u8 D_SH_80350F18; diff --git a/src/audio/data.h b/src/audio/data.h index ee8b30b1..26672d19 100644 --- a/src/audio/data.h +++ b/src/audio/data.h @@ -13,14 +13,14 @@ #define NUMAIBUFFERS 3 // constant .data -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) extern struct AudioSessionSettingsEU gAudioSessionPresets[]; #else extern struct AudioSessionSettings gAudioSessionPresets[18]; #endif extern u16 D_80332388[128]; // unused -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) extern f32 gPitchBendFrequencyScale[256]; #else extern f32 gPitchBendFrequencyScale[255]; @@ -32,14 +32,14 @@ extern u8 gDefaultShortNoteDurationTable[16]; extern s8 gVibratoCurve[16]; extern struct AdsrEnvelope gDefaultEnvelope[3]; -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) extern s16 gEuUnknownWave7[256]; extern s16 *gWaveSamples[6]; #else extern s16 *gWaveSamples[4]; #endif -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) extern u8 euUnknownData_8030194c[4]; #ifdef VERSION_EU extern u16 gHeadsetPanQuantization[0x10]; @@ -74,7 +74,7 @@ extern volatile s32 gAudioLoadLock; extern volatile s32 gAudioFrameCount; // number of DMAs performed during this frame -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) extern s32 gCurrAudioFrameDmaCount; #else extern volatile s32 gCurrAudioFrameDmaCount; @@ -89,14 +89,14 @@ extern u64 *gAudioCmd; extern struct SPTask *gAudioTask; extern struct SPTask gAudioTasks[2]; -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) extern f32 D_EU_802298D0; extern s32 gRefreshRate; #endif extern s16 *gAiBuffers[NUMAIBUFFERS]; extern s16 gAiBufferLengths[NUMAIBUFFERS]; -#if defined(VERSION_SH) +#if defined(VERSION_SH) || defined(VERSION_CN) #define AIBUFFER_LEN 0xb00 #elif defined(VERSION_EU) #define AIBUFFER_LEN (0xa0 * 17) @@ -109,7 +109,7 @@ extern u16 gUnused80226E98[0x10]; extern u32 gAudioRandom; -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) extern f32 unk_sh_data_1[]; extern volatile u32 gAudioLoadLockSH; @@ -134,7 +134,7 @@ extern OSMesgQueue D_SH_80350F90; // address written to D_SH_80350F90 extern OSMesgQueue *D_SH_80350FA8; #endif -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) #define UNUSED_COUNT_80333EE8 24 #define AUDIO_HEAP_SIZE 0x2c500 #define AUDIO_INIT_POOL_SIZE 0x2c00 @@ -144,7 +144,7 @@ extern OSMesgQueue *D_SH_80350FA8; #define AUDIO_INIT_POOL_SIZE 0x2500 #endif -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) extern u32 D_SH_80315EF0; extern u16 D_SH_80315EF4; extern u16 D_SH_80315EF8; diff --git a/src/audio/effects.c b/src/audio/effects.c index 91c2f034..4bd17723 100644 --- a/src/audio/effects.c +++ b/src/audio/effects.c @@ -11,7 +11,7 @@ #define US_FLOAT2(x) x #endif -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) void sequence_channel_process_sound(struct SequenceChannel *seqChannel, s32 recalculateVolume) { f32 channelVolume; s32 i; @@ -21,7 +21,7 @@ void sequence_channel_process_sound(struct SequenceChannel *seqChannel, s32 reca if (seqChannel->seqPlayer->muted && (seqChannel->muteBehavior & MUTE_BEHAVIOR_SOFTEN) != 0) { channelVolume = seqChannel->seqPlayer->muteVolumeScale * channelVolume; } -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) seqChannel->appliedVolume = channelVolume * channelVolume; #else seqChannel->appliedVolume = channelVolume; @@ -32,7 +32,7 @@ void sequence_channel_process_sound(struct SequenceChannel *seqChannel, s32 reca seqChannel->pan = seqChannel->newPan * seqChannel->panChannelWeight; } - for (i = 0; i < 4; ++i) { + for (i = 0; i < 4; i++) { struct SequenceChannelLayer *layer = seqChannel->layers[i]; if (layer != NULL && layer->enabled && layer->note != NULL) { if (layer->notePropertiesNeedInit) { @@ -86,7 +86,7 @@ void sequence_player_process_sound(struct SequencePlayer *seqPlayer) { if (seqPlayer->fadeRemainingFrames != 0) { seqPlayer->fadeVolume += seqPlayer->fadeVelocity; -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) seqPlayer->recalculateVolume = TRUE; #endif @@ -98,7 +98,7 @@ void sequence_player_process_sound(struct SequencePlayer *seqPlayer) { } if (--seqPlayer->fadeRemainingFrames == 0) { -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) if (seqPlayer->state == 2) { sequence_player_disable(seqPlayer); return; @@ -121,7 +121,7 @@ void sequence_player_process_sound(struct SequencePlayer *seqPlayer) { } } -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) if (seqPlayer->recalculateVolume) { seqPlayer->appliedFadeVolume = seqPlayer->fadeVolume * seqPlayer->fadeVolumeScale; } @@ -131,7 +131,7 @@ void sequence_player_process_sound(struct SequencePlayer *seqPlayer) { for (i = 0; i < CHANNELS_MAX; i++) { if (IS_SEQUENCE_CHANNEL_VALID(seqPlayer->channels[i]) == TRUE && seqPlayer->channels[i]->enabled == TRUE) { -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) sequence_channel_process_sound(seqPlayer->channels[i], seqPlayer->recalculateVolume); #else sequence_channel_process_sound(seqPlayer->channels[i]); @@ -139,7 +139,7 @@ void sequence_player_process_sound(struct SequencePlayer *seqPlayer) { } } -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) seqPlayer->recalculateVolume = FALSE; #endif } @@ -156,7 +156,7 @@ f32 get_portamento_freq_scale(struct Portamento *p) { p->cur += p->speed; v0 = (u32) p->cur; -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) if (v0 > 127) #else if (v0 >= 127) @@ -165,7 +165,7 @@ f32 get_portamento_freq_scale(struct Portamento *p) { v0 = 127; } -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) result = US_FLOAT(1.0) + p->extent * (gPitchBendFrequencyScale[v0 + 128] - US_FLOAT(1.0)); #else result = US_FLOAT(1.0) + p->extent * (gPitchBendFrequencyScale[v0 + 127] - US_FLOAT(1.0)); @@ -173,7 +173,7 @@ f32 get_portamento_freq_scale(struct Portamento *p) { return result; } -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) s16 get_vibrato_pitch_change(struct VibratoState *vib) { s32 index; vib->time += (s32) vib->rate; @@ -253,7 +253,7 @@ f32 get_vibrato_freq_scale(struct VibratoState *vib) { pitchChange = get_vibrato_pitch_change(vib); extent = (f32) vib->extent / US_FLOAT(4096.0); -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) result = US_FLOAT(1.0) + extent * (gPitchBendFrequencyScale[pitchChange + 128] - US_FLOAT(1.0)); #else result = US_FLOAT(1.0) + extent * (gPitchBendFrequencyScale[pitchChange + 127] - US_FLOAT(1.0)); @@ -262,7 +262,7 @@ f32 get_vibrato_freq_scale(struct VibratoState *vib) { } void note_vibrato_update(struct Note *note) { -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) if (note->portamento.mode != 0) { note->portamentoFreqScale = get_portamento_freq_scale(¬e->portamento); } @@ -282,7 +282,7 @@ void note_vibrato_update(struct Note *note) { void note_vibrato_init(struct Note *note) { struct VibratoState *vib; UNUSED struct SequenceChannel *seqChannel; -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) struct NotePlaybackState *seqPlayerState = (struct NotePlaybackState *) ¬e->priority; #endif @@ -303,7 +303,7 @@ void note_vibrato_init(struct Note *note) { vib->active = TRUE; vib->time = 0; -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) vib->curve = gWaveSamples[2]; vib->seqChannel = note->parentLayer->seqChannel; if ((vib->extentChangeTimer = vib->seqChannel->vibratoExtentChangeDelay) == 0) { @@ -345,10 +345,10 @@ void note_vibrato_init(struct Note *note) { void adsr_init(struct AdsrState *adsr, struct AdsrEnvelope *envelope, UNUSED s16 *volOut) { adsr->action = 0; adsr->state = ADSR_STATE_DISABLED; -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) adsr->delay = 0; adsr->envelope = envelope; -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) adsr->sustain = 0.0f; #endif adsr->current = 0.0f; @@ -361,13 +361,13 @@ void adsr_init(struct AdsrState *adsr, struct AdsrEnvelope *envelope, UNUSED s16 #endif } -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) f32 adsr_update(struct AdsrState *adsr) { #else s32 adsr_update(struct AdsrState *adsr) { #endif u8 action = adsr->action; -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) u8 state = adsr->state; switch (state) { #else @@ -396,7 +396,7 @@ s32 adsr_update(struct AdsrState *adsr) { adsr->state = ADSR_STATE_LOOP; // fallthrough -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) restart: #endif case ADSR_STATE_LOOP: @@ -410,7 +410,7 @@ s32 adsr_update(struct AdsrState *adsr) { break; case ADSR_GOTO: adsr->envIndex = BSWAP16(adsr->envelope[adsr->envIndex].arg); -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) goto restart; #else break; @@ -420,15 +420,15 @@ s32 adsr_update(struct AdsrState *adsr) { break; default: -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) if (adsr->delay >= 4) { adsr->delay = adsr->delay * gAudioBufferParameters.updatesPerFrame -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) / gAudioBufferParameters.presetUnk4 #endif / 4; } -#if defined(VERSION_SH) +#if defined(VERSION_SH) || defined(VERSION_CN) if (adsr->delay == 0) { adsr->delay = 1; } @@ -452,7 +452,7 @@ s32 adsr_update(struct AdsrState *adsr) { // fallthrough case ADSR_STATE_FADE: -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) adsr->current += adsr->velocity; #else adsr->currentHiRes += adsr->velocity; @@ -469,14 +469,14 @@ s32 adsr_update(struct AdsrState *adsr) { case ADSR_STATE_DECAY: case ADSR_STATE_RELEASE: { adsr->current -= adsr->fadeOutVel; -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) if (adsr->sustain != 0.0f && state == ADSR_STATE_DECAY) { #else if (adsr->sustain != 0 && adsr->state == ADSR_STATE_DECAY) { #endif if (adsr->current < adsr->sustain) { adsr->current = adsr->sustain; -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) adsr->delay = 128; #else adsr->delay = adsr->sustain / 16; @@ -486,7 +486,7 @@ s32 adsr_update(struct AdsrState *adsr) { break; } -#if defined(VERSION_SH) +#if defined(VERSION_SH) || defined(VERSION_CN) if (adsr->current < 0.00001f) { adsr->current = 0.0f; adsr->state = ADSR_STATE_DISABLED; @@ -520,14 +520,14 @@ s32 adsr_update(struct AdsrState *adsr) { if ((action & ADSR_ACTION_RELEASE)) { adsr->state = ADSR_STATE_RELEASE; -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) adsr->action = action & ~ADSR_ACTION_RELEASE; #else adsr->action = action & ~(ADSR_ACTION_RELEASE | ADSR_ACTION_DECAY); #endif } -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) if (adsr->current < 0.0f) { return 0.0f; } diff --git a/src/audio/effects.h b/src/audio/effects.h index a6de1ab9..05491e80 100644 --- a/src/audio/effects.h +++ b/src/audio/effects.h @@ -37,7 +37,7 @@ void sequence_player_process_sound(struct SequencePlayer *seqPlayer); void note_vibrato_update(struct Note *note); void note_vibrato_init(struct Note *note); void adsr_init(struct AdsrState *adsr, struct AdsrEnvelope *envelope, s16 *volOut); -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) f32 adsr_update(struct AdsrState *adsr); #else s32 adsr_update(struct AdsrState *adsr); diff --git a/src/audio/external.c b/src/audio/external.c index 0c0283ff..a5140d76 100644 --- a/src/audio/external.c +++ b/src/audio/external.c @@ -13,7 +13,7 @@ #include "seq_ids.h" #include "dialog_ids.h" -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) #define EU_FLOAT(x) x##f #else #define EU_FLOAT(x) x @@ -63,7 +63,7 @@ struct SequenceQueueItem { }; // size = 0x2 // data -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) // moved to bss in data.c s32 gAudioErrorFlags2 = 0; #else @@ -166,18 +166,18 @@ u8 sSoundRequestCount = 0; #define DYN3(cond1, val1, cond2, val2, cond3, val3, res) \ (s16)(1 << (15 - cond1) | 1 << (15 - cond2) | 1 << (15 - cond3) | res), val1, val2, val3 -s16 sDynBbh[] = { +s16 sDynBBH[] = { SEQ_LEVEL_SPOOKY, DYN1(MARIO_IS_IN_ROOM, BBH_OUTSIDE_ROOM, 6), DYN1(MARIO_IS_IN_ROOM, BBH_NEAR_MERRY_GO_ROUND_ROOM, 6), 5, }; -s16 sDynDdd[] = { +s16 sDynDDD[] = { SEQ_LEVEL_WATER, DYN2(MARIO_X_LT, -800, MARIO_IS_IN_AREA, AREA_DDD_WHIRLPOOL & 0xf, 0), DYN3(MARIO_Y_GE, -2000, MARIO_X_LT, 470, MARIO_IS_IN_AREA, AREA_DDD_WHIRLPOOL & 0xf, 0), DYN2(MARIO_Y_GE, 100, MARIO_IS_IN_AREA, AREA_DDD_SUB & 0xf, 2), 1, }; -s16 sDynJrb[] = { +s16 sDynJRB[] = { SEQ_LEVEL_WATER, DYN2(MARIO_Y_GE, 945, MARIO_X_LT, -5260, 0), DYN1(MARIO_IS_IN_AREA, AREA_JRB_SHIP & 0xf, 0), @@ -186,11 +186,11 @@ s16 sDynJrb[] = { 1, 5, // bogus entry, ignored (was JRB originally intended to have spooky music?) }; -s16 sDynWdw[] = { +s16 sDynWDW[] = { SEQ_LEVEL_UNDERGROUND, DYN2(MARIO_Y_LT, -670, MARIO_IS_IN_AREA, AREA_WDW_MAIN & 0xf, 4), DYN1(MARIO_IS_IN_AREA, AREA_WDW_TOWN & 0xf, 4), 3, }; -s16 sDynHmc[] = { +s16 sDynHMC[] = { SEQ_LEVEL_UNDERGROUND, DYN2(MARIO_X_GE, 0, MARIO_Y_LT, -203, 4), DYN2(MARIO_X_LT, 0, MARIO_Y_LT, -2400, 4), 3, }; @@ -353,7 +353,7 @@ u8 sBackgroundMusicMaxTargetVolume = TARGET_VOLUME_UNSET; u8 D_80332120 = 0; u8 D_80332124 = 0; -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) u8 D_EU_80300558 = 0; #endif @@ -368,7 +368,7 @@ u8 sUnused8033323C = 0; // never read, set to 0 #if defined(VERSION_JP) || defined(VERSION_US) s16 *gCurrAiBuffer; #endif -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) s8 D_SH_80343CD0_pad[0x20]; s32 D_SH_80343CF0; s8 D_SH_80343CF8_pad[0x8]; @@ -397,7 +397,7 @@ u8 sBackgroundMusicTargetVolume; static u8 sLowerBackgroundMusicVolume; struct SequenceQueueItem sBackgroundMusicQueue[MAX_BACKGROUND_MUSIC_QUEUE_SIZE]; -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) s32 unk_sh_8034754C; #endif @@ -509,7 +509,7 @@ void unused_8031E568(void) { } #endif -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) const char unusedErrorStr1[] = "Error : Queue is not empty ( %x ) \n"; const char unusedErrorStr2[] = "specchg error\n"; #endif @@ -518,10 +518,10 @@ const char unusedErrorStr2[] = "specchg error\n"; * Fade out a sequence player * Called from threads: thread5_game_loop */ -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) void audio_reset_session_eu(s32 presetId) { OSMesg mesg; -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) osRecvMesg(D_SH_80350FA8, &mesg, OS_MESG_NOBLOCK); osSendMesg(D_SH_80350F88, (OSMesg) presetId, OS_MESG_NOBLOCK); osRecvMesg(D_SH_80350FA8, &mesg, OS_MESG_BLOCK); @@ -583,7 +583,7 @@ static void seq_player_fade_to_percentage_of_volume(s32 player, FadeT fadeDurati struct SequencePlayer *seqPlayer = &gSequencePlayers[player]; f32 targetVolume; -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) if (seqPlayer->state == 2) { return; } @@ -602,7 +602,7 @@ static void seq_player_fade_to_percentage_of_volume(s32 player, FadeT fadeDurati return; } seqPlayer->fadeVelocity = (targetVolume - seqPlayer->fadeVolume) / fadeDuration; -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) seqPlayer->state = 0; #else seqPlayer->state = SEQUENCE_PLAYER_STATE_4; @@ -617,7 +617,7 @@ static void seq_player_fade_to_percentage_of_volume(s32 player, FadeT fadeDurati static void seq_player_fade_to_normal_volume(s32 player, FadeT fadeDuration) { struct SequencePlayer *seqPlayer = &gSequencePlayers[player]; -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) if (seqPlayer->state == 2) { return; } @@ -633,7 +633,7 @@ static void seq_player_fade_to_normal_volume(s32 player, FadeT fadeDuration) { return; } seqPlayer->fadeVelocity = (seqPlayer->volume - seqPlayer->fadeVolume) / fadeDuration; -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) seqPlayer->state = 0; #else seqPlayer->state = SEQUENCE_PLAYER_STATE_2; @@ -663,7 +663,7 @@ static void seq_player_fade_to_target_volume(s32 player, FadeT fadeDuration, u8 seqPlayer->fadeVelocity = (((f32)(FLOAT_CAST(targetVolume) / EU_FLOAT(127.0)) - seqPlayer->fadeVolume) / (f32) fadeDuration); -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) seqPlayer->state = 0; #else seqPlayer->state = SEQUENCE_PLAYER_STATE_4; @@ -672,7 +672,7 @@ static void seq_player_fade_to_target_volume(s32 player, FadeT fadeDuration, u8 seqPlayer->fadeRemainingFrames = fadeDuration; } -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) #ifdef VERSION_EU extern void func_802ad7a0(void); #else @@ -1329,7 +1329,7 @@ static void noop_8031EEC8(void) { */ void audio_signal_game_loop_tick(void) { sGameLoopTicked = 1; -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) maybe_tick_game_sound(); #endif noop_8031EEC8(); @@ -1387,7 +1387,7 @@ static void update_game_sound(void) { case SOUND_BANK_MOVING: if (!(sSoundBanks[bank][soundIndex].soundBits & SOUND_CONSTANT_FREQUENCY)) { if (sSoundMovingSpeed[bank] > 8) { -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) func_802ad728( 0x02020000 | ((channelIndex & 0xff) << 8), get_sound_volume(bank, soundIndex, VOLUME_RANGE_UNK1)); @@ -1397,7 +1397,7 @@ static void update_game_sound(void) { value; #endif } else { -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) func_802ad728(0x02020000 | ((channelIndex & 0xff) << 8), get_sound_volume(bank, soundIndex, VOLUME_RANGE_UNK1) * ((sSoundMovingSpeed[bank] + 8.0f) / 16)); @@ -1407,7 +1407,7 @@ static void update_game_sound(void) { (sSoundMovingSpeed[bank] + 8.0f) / 16 * value; #endif } -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) func_802ad770(0x03020000 | ((channelIndex & 0xff) << 8), get_sound_pan(*sSoundBanks[bank][soundIndex].x, *sSoundBanks[bank][soundIndex].z)); @@ -1419,7 +1419,7 @@ static void update_game_sound(void) { if ((sSoundBanks[bank][soundIndex].soundBits & SOUNDARGS_MASK_SOUNDID) == (SOUND_MOVING_FLYING & SOUNDARGS_MASK_SOUNDID)) { -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) func_802ad728( 0x04020000 | ((channelIndex & 0xff) << 8), get_sound_freq_scale(bank, soundIndex) @@ -1430,7 +1430,7 @@ static void update_game_sound(void) { ((f32) sSoundMovingSpeed[bank] / US_FLOAT(80.0)) + value; #endif } else { -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) func_802ad728( 0x04020000 | ((channelIndex & 0xff) << 8), get_sound_freq_scale(bank, soundIndex) @@ -1441,7 +1441,7 @@ static void update_game_sound(void) { ((f32) sSoundMovingSpeed[bank] / US_FLOAT(400.0)) + value; #endif } -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) func_802ad770(0x05020000 | ((channelIndex & 0xff) << 8), get_sound_reverb(bank, soundIndex, channelIndex)); #else @@ -1453,7 +1453,7 @@ static void update_game_sound(void) { } // fallthrough case SOUND_BANK_MENU: -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) func_802ad728(0x02020000 | ((channelIndex & 0xff) << 8), 1); func_802ad770(0x03020000 | ((channelIndex & 0xff) << 8), 64); func_802ad728(0x04020000 | ((channelIndex & 0xff) << 8), @@ -1466,7 +1466,7 @@ static void update_game_sound(void) { break; case SOUND_BANK_ACTION: case SOUND_BANK_VOICE: -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) func_802ad770(0x05020000 | ((channelIndex & 0xff) << 8), get_sound_reverb(bank, soundIndex, channelIndex)); func_802ad728(0x02020000 | ((channelIndex & 0xff) << 8), @@ -1496,7 +1496,7 @@ static void update_game_sound(void) { case SOUND_BANK_AIR: case SOUND_BANK_GENERAL2: case SOUND_BANK_OBJ2: -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) func_802ad770(0x05020000 | ((channelIndex & 0xff) << 8), get_sound_reverb(bank, soundIndex, channelIndex)); func_802ad728(0x02020000 | ((channelIndex & 0xff) << 8), @@ -1571,7 +1571,7 @@ static void update_game_sound(void) { case SOUND_BANK_MOVING: if (!(sSoundBanks[bank][soundIndex].soundBits & SOUND_CONSTANT_FREQUENCY)) { if (sSoundMovingSpeed[bank] > 8) { -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) func_802ad728( 0x02020000 | ((channelIndex & 0xff) << 8), get_sound_volume(bank, soundIndex, VOLUME_RANGE_UNK1)); @@ -1581,7 +1581,7 @@ static void update_game_sound(void) { value; #endif } else { -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) func_802ad728(0x02020000 | ((channelIndex & 0xff) << 8), get_sound_volume(bank, soundIndex, VOLUME_RANGE_UNK1) * ((sSoundMovingSpeed[bank] + 8.0f) / 16)); @@ -1591,7 +1591,7 @@ static void update_game_sound(void) { (sSoundMovingSpeed[bank] + 8.0f) / 16 * value; #endif } -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) func_802ad770(0x03020000 | ((channelIndex & 0xff) << 8), get_sound_pan(*sSoundBanks[bank][soundIndex].x, *sSoundBanks[bank][soundIndex].z)); @@ -1603,7 +1603,7 @@ static void update_game_sound(void) { if ((sSoundBanks[bank][soundIndex].soundBits & SOUNDARGS_MASK_SOUNDID) == (SOUND_MOVING_FLYING & SOUNDARGS_MASK_SOUNDID)) { -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) func_802ad728( 0x04020000 | ((channelIndex & 0xff) << 8), get_sound_freq_scale(bank, soundIndex) @@ -1614,7 +1614,7 @@ static void update_game_sound(void) { ((f32) sSoundMovingSpeed[bank] / US_FLOAT(80.0)) + value; #endif } else { -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) func_802ad728( 0x04020000 | ((channelIndex & 0xff) << 8), get_sound_freq_scale(bank, soundIndex) @@ -1625,7 +1625,7 @@ static void update_game_sound(void) { ((f32) sSoundMovingSpeed[bank] / US_FLOAT(400.0)) + value; #endif } -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) func_802ad770(0x05020000 | ((channelIndex & 0xff) << 8), get_sound_reverb(bank, soundIndex, channelIndex)); #else @@ -1637,7 +1637,7 @@ static void update_game_sound(void) { } // fallthrough case SOUND_BANK_MENU: -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) func_802ad728(0x02020000 | ((channelIndex & 0xff) << 8), 1); func_802ad770(0x03020000 | ((channelIndex & 0xff) << 8), 64); func_802ad728(0x04020000 | ((channelIndex & 0xff) << 8), @@ -1650,7 +1650,7 @@ static void update_game_sound(void) { break; case SOUND_BANK_ACTION: case SOUND_BANK_VOICE: -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) func_802ad770(0x05020000 | ((channelIndex & 0xff) << 8), get_sound_reverb(bank, soundIndex, channelIndex)); func_802ad728(0x02020000 | ((channelIndex & 0xff) << 8), @@ -1680,7 +1680,7 @@ static void update_game_sound(void) { case SOUND_BANK_AIR: case SOUND_BANK_GENERAL2: case SOUND_BANK_OBJ2: -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) func_802ad770(0x05020000 | ((channelIndex & 0xff) << 8), get_sound_reverb(bank, soundIndex, channelIndex)); func_802ad728(0x02020000 | ((channelIndex & 0xff) << 8), @@ -1737,7 +1737,7 @@ static void seq_player_play_sequence(u8 player, u8 seqId, u16 arg2) { D_80360928[player][i].remainingFrames = 0; } -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) func_802ad770(0x46000000 | ((u8)(u32) player) << 16, seqId & SEQ_VARIATION); func_802ad74c(0x82000000 | ((u8)(u32) player) << 16 | ((u8)(seqId & SEQ_BASE_ID)) << 8, arg2); @@ -1768,7 +1768,7 @@ static void seq_player_play_sequence(u8 player, u8 seqId, u16 arg2) { * Called from threads: thread5_game_loop */ void seq_player_fade_out(u8 player, u16 fadeDuration) { -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) #ifdef VERSION_EU u32 fd = fadeDuration; #else @@ -1824,7 +1824,7 @@ static void func_8031F96C(u8 player) { if (gSequencePlayers[player].channels[i] != &gSequenceChannelNone && D_80360928[player][i].remainingFrames != 0) { D_80360928[player][i].current += D_80360928[player][i].velocity; -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) func_802ad728(0x01000000 | (player & 0xff) << 16 | (i & 0xff) << 8, D_80360928[player][i].current); #else @@ -1835,7 +1835,7 @@ static void func_8031F96C(u8 player) { #if defined(VERSION_EU) func_802ad728(0x01000000 | (player & 0xff) << 16 | (i & 0xff) << 8, FLOAT_CAST(D_80360928[player][i].target) / 127.0); -#elif defined(VERSION_SH) +#elif defined(VERSION_SH) || defined(VERSION_CN) func_802ad728(0x01000000 | (player & 0xff) << 16 | (i & 0xff) << 8, FLOAT_CAST(D_80360928[player][i].target) / 127.0f); #else @@ -2109,7 +2109,7 @@ void set_audio_muted(u8 muted) { u8 i; for (i = 0; i < SEQUENCE_PLAYERS; i++) { -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) if (muted) { func_802ad74c(0xf1000000, 0); } else { @@ -2499,7 +2499,7 @@ u16 get_current_background_music(void) { * Called from threads: thread4_sound, thread5_game_loop (EU only) */ void func_80320ED8(void) { -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) if (D_EU_80300558 != 0) { D_EU_80300558--; } @@ -2577,7 +2577,7 @@ void func_803210D4(u16 fadeDuration) { } if (gSequencePlayers[SEQ_PLAYER_LEVEL].enabled == TRUE) { -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) func_802ad74c(0x83000000, fadeDuration); #else seq_player_fade_to_zero_volume(SEQ_PLAYER_LEVEL, fadeDuration); @@ -2585,7 +2585,7 @@ void func_803210D4(u16 fadeDuration) { } if (gSequencePlayers[SEQ_PLAYER_ENV].enabled == TRUE) { -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) func_802ad74c(0x83010000, fadeDuration); #else seq_player_fade_to_zero_volume(SEQ_PLAYER_ENV, fadeDuration); @@ -2607,7 +2607,7 @@ void func_803210D4(u16 fadeDuration) { void play_course_clear(void) { seq_player_play_sequence(SEQ_PLAYER_ENV, SEQ_EVENT_CUTSCENE_COLLECT_STAR, 0); sBackgroundMusicMaxTargetVolume = TARGET_VOLUME_IS_PRESENT_FLAG | 0; -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) D_EU_80300558 = 2; #endif begin_background_music_fade(50); @@ -2619,7 +2619,7 @@ void play_course_clear(void) { void play_peachs_jingle(void) { seq_player_play_sequence(SEQ_PLAYER_ENV, SEQ_EVENT_PEACH_MESSAGE, 0); sBackgroundMusicMaxTargetVolume = TARGET_VOLUME_IS_PRESENT_FLAG | 0; -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) D_EU_80300558 = 2; #endif begin_background_music_fade(50); @@ -2635,7 +2635,7 @@ void play_peachs_jingle(void) { void play_puzzle_jingle(void) { seq_player_play_sequence(SEQ_PLAYER_ENV, SEQ_EVENT_SOLVE_PUZZLE, 0); sBackgroundMusicMaxTargetVolume = TARGET_VOLUME_IS_PRESENT_FLAG | 20; -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) D_EU_80300558 = 2; #endif begin_background_music_fade(50); @@ -2647,7 +2647,7 @@ void play_puzzle_jingle(void) { void play_star_fanfare(void) { seq_player_play_sequence(SEQ_PLAYER_ENV, SEQ_EVENT_HIGH_SCORE, 0); sBackgroundMusicMaxTargetVolume = TARGET_VOLUME_IS_PRESENT_FLAG | 20; -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) D_EU_80300558 = 2; #endif begin_background_music_fade(50); @@ -2662,7 +2662,7 @@ void play_power_star_jingle(u8 arg0) { } seq_player_play_sequence(SEQ_PLAYER_ENV, SEQ_EVENT_CUTSCENE_STAR_SPAWN, 0); sBackgroundMusicMaxTargetVolume = TARGET_VOLUME_IS_PRESENT_FLAG | 20; -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) D_EU_80300558 = 2; #endif begin_background_music_fade(50); @@ -2674,7 +2674,7 @@ void play_power_star_jingle(u8 arg0) { void play_race_fanfare(void) { seq_player_play_sequence(SEQ_PLAYER_ENV, SEQ_EVENT_RACE, 0); sBackgroundMusicMaxTargetVolume = TARGET_VOLUME_IS_PRESENT_FLAG | 20; -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) D_EU_80300558 = 2; #endif begin_background_music_fade(50); @@ -2686,7 +2686,7 @@ void play_race_fanfare(void) { void play_toads_jingle(void) { seq_player_play_sequence(SEQ_PLAYER_ENV, SEQ_EVENT_TOAD_MESSAGE, 0); sBackgroundMusicMaxTargetVolume = TARGET_VOLUME_IS_PRESENT_FLAG | 20; -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) D_EU_80300558 = 2; #endif begin_background_music_fade(50); @@ -2705,7 +2705,7 @@ void sound_reset(u8 presetId) { sGameLoopTicked = 0; disable_all_sequence_players(); sound_init(); -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) func_802ad74c(0xF2000000, 0); #endif #if defined(VERSION_JP) || defined(VERSION_US) diff --git a/src/audio/heap.c b/src/audio/heap.c index 4b84c001..5b23438b 100644 --- a/src/audio/heap.c +++ b/src/audio/heap.c @@ -39,7 +39,7 @@ struct SoundMultiPool gSeqLoadedPool; struct SoundMultiPool gBankLoadedPool; struct SoundMultiPool gUnusedLoadedPool; -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) struct Unk1Pool gUnkPool1; struct UnkPool gUnkPool2; struct UnkPool gUnkPool3; @@ -50,13 +50,13 @@ struct PoolSplit2 sSeqAndBankPoolSplit; struct PoolSplit sPersistentCommonPoolSplit; struct PoolSplit sTemporaryCommonPoolSplit; -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) u8 gUnkLoadStatus[0x40]; #endif u8 gBankLoadStatus[0x40]; u8 gSeqLoadStatus[0x100]; -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) volatile u8 gAudioResetStatus; u8 gAudioResetPresetIdToLoad; s32 gAudioResetFadeOutFramesLeft; @@ -66,7 +66,7 @@ u8 gAudioUnusedBuffer[0x1000]; extern s32 gMaxAudioCmds; -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) void *get_bank_or_seq_inner(s32 poolIdx, s32 arg1, s32 bankId); struct UnkEntry *func_sh_802f1ec4(u32 size); void func_sh_802f2158(struct UnkEntry *entry); @@ -168,7 +168,7 @@ void build_vol_rampings_table(s32 UNUSED unused, s32 len) { void reset_bank_and_seq_load_status(void) { s32 i; -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) for (i = 0; i < 64; i++) { if (gBankLoadStatus[i] != SOUND_LOAD_STATUS_5) { gBankLoadStatus[i] = SOUND_LOAD_STATUS_NOT_LOADED; @@ -204,17 +204,19 @@ void discard_bank(s32 bankId) { struct Note *note = &gNotes[i]; #if defined(VERSION_EU) - if (note->noteSubEu.bankId == bankId) { + if (note->noteSubEu.bankId == bankId) #else - if (note->bankId == bankId) { + if (note->bankId == bankId) #endif + { // (These prints are unclear. Arguments are picked semi-randomly.) eu_stubbed_printf_1("Warning:Kill Note %x \n", i); -#ifdef VERSION_SH - if (note->unkSH34 == NOTE_PRIORITY_DISABLED && note->priority) { +#if defined(VERSION_SH) || defined(VERSION_CN) + if (note->unkSH34 == NOTE_PRIORITY_DISABLED && note->priority) #else - if (note->priority >= NOTE_PRIORITY_MIN) { + if (note->priority >= NOTE_PRIORITY_MIN) #endif + { eu_stubbed_printf_3("Kill Voice %d (ID %d) %d\n", note->waveId, bankId, note->priority); eu_stubbed_printf_0("Warning: Running Sequence's data disappear!\n"); @@ -233,7 +235,7 @@ void discard_sequence(s32 seqId) { for (i = 0; i < SEQUENCE_PLAYERS; i++) { if (gSequencePlayers[i].enabled && gSequencePlayers[i].seqId == seqId) { -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) sequence_player_disable(&gSequencePlayers[i]); #else sequence_player_disable(gSequencePlayers + i); @@ -243,7 +245,7 @@ void discard_sequence(s32 seqId) { } void *soundAlloc(struct SoundAllocPool *pool, u32 size) { -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) u8 *start; u8 *pos; u32 alignedSize = ALIGN16(size); @@ -258,7 +260,7 @@ void *soundAlloc(struct SoundAllocPool *pool, u32 size) { eu_stubbed_printf_1("Heap OverFlow : Not Allocate %d!\n", size); return NULL; } -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) pool->numAllocatedEntries++; #endif return start; @@ -281,7 +283,7 @@ void *soundAlloc(struct SoundAllocPool *pool, u32 size) { #endif } -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) void *sound_alloc_uninitialized(struct SoundAllocPool *pool, u32 size) { u8 *start; u32 alignedSize = ALIGN16(size); @@ -300,7 +302,7 @@ void *sound_alloc_uninitialized(struct SoundAllocPool *pool, u32 size) { void sound_alloc_pool_init(struct SoundAllocPool *pool, void *memAddr, u32 size) { pool->cur = pool->start = (u8 *) ALIGN16((uintptr_t) memAddr); -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) pool->size = size - ((uintptr_t) memAddr & 0xf); #else pool->size = size; @@ -319,7 +321,7 @@ void temporary_pool_clear(struct TemporaryPool *temporary) { temporary->pool.cur = temporary->pool.start; temporary->nextSide = 0; temporary->entries[0].ptr = temporary->pool.start; -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) temporary->entries[1].ptr = temporary->pool.start + temporary->pool.size; #else temporary->entries[1].ptr = temporary->pool.size + temporary->pool.start; @@ -339,7 +341,7 @@ void sound_init_main_pools(s32 sizeForAudioInitPool) { sound_alloc_pool_init(&gAudioSessionPool, gAudioHeap + sizeForAudioInitPool, gAudioHeapSize - sizeForAudioInitPool); } -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) #define SOUND_ALLOC_FUNC sound_alloc_uninitialized #else #define SOUND_ALLOC_FUNC soundAlloc @@ -385,14 +387,14 @@ UNUSED static void unused_803163D4(void) { } #endif -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) void *alloc_bank_or_seq(s32 poolIdx, s32 size, s32 arg3, s32 id) { #else void *alloc_bank_or_seq(struct SoundMultiPool *arg0, s32 arg1, s32 size, s32 arg3, s32 id) { #endif // arg3 = 0, 1 or 2? -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) struct SoundMultiPool *arg0; #define isSound poolIdx #endif @@ -409,7 +411,7 @@ void *alloc_bank_or_seq(struct SoundMultiPool *arg0, s32 arg1, s32 size, s32 arg u32 nullID = -1; UNUSED s32 i; u8 *table; -#ifndef VERSION_SH +#if !defined(VERSION_SH) && !defined(VERSION_CN) u8 isSound; #endif #if defined(VERSION_JP) || defined(VERSION_US) @@ -421,7 +423,7 @@ void *alloc_bank_or_seq(struct SoundMultiPool *arg0, s32 arg1, s32 size, s32 arg u32 leftAvail, rightAvail; #endif -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) switch (poolIdx) { case 0: arg0 = &gSeqLoadedPool; @@ -442,7 +444,7 @@ void *alloc_bank_or_seq(struct SoundMultiPool *arg0, s32 arg1, s32 size, s32 arg if (arg3 == 0) { tp = &arg0->temporary; -#ifndef VERSION_SH +#if !defined(VERSION_SH) && !defined(VERSION_CN) if (arg0 == &gSeqLoadedPool) { table = gSeqLoadStatus; isSound = FALSE; @@ -452,7 +454,7 @@ void *alloc_bank_or_seq(struct SoundMultiPool *arg0, s32 arg1, s32 size, s32 arg } #endif -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) if (tp->entries[0].id == (s8)nullID) { firstVal = SOUND_LOAD_STATUS_NOT_LOADED; } else { @@ -505,7 +507,7 @@ void *alloc_bank_or_seq(struct SoundMultiPool *arg0, s32 arg1, s32 size, s32 arg } #endif -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) if (poolIdx == 1) { if (firstVal == SOUND_LOAD_STATUS_4) { for (i = 0; i < gMaxSimultaneousNotes; i++) { @@ -651,7 +653,7 @@ void *alloc_bank_or_seq(struct SoundMultiPool *arg0, s32 arg1, s32 size, s32 arg pool->cur = pool->start + size; -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) if (tp->entries[1].id != (s32)nullID) #endif if (tp->entries[1].ptr < pool->cur) { @@ -671,7 +673,7 @@ void *alloc_bank_or_seq(struct SoundMultiPool *arg0, s32 arg1, s32 size, s32 arg } tp->entries[1].id = (s32)nullID; -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) tp->entries[1].ptr = pool->start + pool->size; #else tp->entries[1].ptr = pool->size + pool->start; @@ -682,7 +684,7 @@ void *alloc_bank_or_seq(struct SoundMultiPool *arg0, s32 arg1, s32 size, s32 arg break; case 1: -#if defined(VERSION_SH) +#if defined(VERSION_SH) || defined(VERSION_CN) tp->entries[1].ptr = (u8 *) ((uintptr_t) (pool->start + pool->size - size) & ~0x0f); #elif defined(VERSION_EU) tp->entries[1].ptr = pool->start + pool->size - size - 0x10; @@ -692,7 +694,7 @@ void *alloc_bank_or_seq(struct SoundMultiPool *arg0, s32 arg1, s32 size, s32 arg tp->entries[1].id = id; tp->entries[1].size = size; -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) if (tp->entries[0].id != (s32)nullID) #endif if (tp->entries[1].ptr < pool->cur) { @@ -728,8 +730,8 @@ void *alloc_bank_or_seq(struct SoundMultiPool *arg0, s32 arg1, s32 size, s32 arg return ret; } -#if defined(VERSION_EU) || defined(VERSION_SH) -#ifdef VERSION_SH +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) +#if defined(VERSION_SH) || defined(VERSION_CN) ret = sound_alloc_uninitialized(&arg0->persistent.pool, size); #else ret = soundAlloc(&arg0->persistent.pool, arg1 * size); @@ -748,7 +750,7 @@ void *alloc_bank_or_seq(struct SoundMultiPool *arg0, s32 arg1, s32 size, s32 arg #if defined(VERSION_EU) eu_stubbed_printf_0("MEMORY:StayHeap OVERFLOW."); return alloc_bank_or_seq(arg0, arg1, size, 0, id); -#elif defined(VERSION_SH) +#elif defined(VERSION_SH) || defined(VERSION_CN) return alloc_bank_or_seq(poolIdx, size, 0, id); #else // Prevent tail call optimization. @@ -756,7 +758,7 @@ void *alloc_bank_or_seq(struct SoundMultiPool *arg0, s32 arg1, s32 size, s32 arg return ret; #endif case 1: -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) case 0: #endif eu_stubbed_printf_1("MEMORY:StayHeap OVERFLOW (REQ:%d)", arg1 * size); @@ -768,17 +770,17 @@ void *alloc_bank_or_seq(struct SoundMultiPool *arg0, s32 arg1, s32 size, s32 arg // Because the buffer is small enough that more don't fit? arg0->persistent.entries[arg0->persistent.numEntries].id = id; arg0->persistent.entries[arg0->persistent.numEntries].size = size; -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) return arg0->persistent.entries[arg0->persistent.numEntries++].ptr; #else arg0->persistent.numEntries++; return arg0->persistent.entries[arg0->persistent.numEntries - 1].ptr; #endif -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) #undef isSound #endif } -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) void *get_bank_or_seq(s32 poolIdx, s32 arg1, s32 id) { void *ret; @@ -835,7 +837,7 @@ void *get_bank_or_seq_inner(s32 poolIdx, s32 arg1, s32 bankId) { return NULL; } #endif -#ifndef VERSION_SH +#if !defined(VERSION_SH) && !defined(VERSION_CN) void *get_bank_or_seq(struct SoundMultiPool *arg0, s32 arg1, s32 id) { u32 i; UNUSED void *ret; @@ -862,7 +864,7 @@ void *get_bank_or_seq(struct SoundMultiPool *arg0, s32 arg1, s32 id) { } if (arg1 == 2) { -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) return get_bank_or_seq(arg0, 0, id); #else // Prevent tail call optimization by using a temporary. @@ -876,7 +878,7 @@ void *get_bank_or_seq(struct SoundMultiPool *arg0, s32 arg1, s32 id) { } #endif -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) void func_eu_802e27e4_unused(f32 arg0, f32 arg1, u16 *arg2) { s32 i; f32 tmp[16]; @@ -910,7 +912,7 @@ void func_eu_802e27e4_unused(f32 arg0, f32 arg1, u16 *arg2) { } #endif -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) void fill_zero_filter(s16 filter[]) { s32 i; for (i = 0; i < 8; i++) { @@ -972,7 +974,7 @@ void decrease_reverb_gain(void) { #endif } -#if defined(VERSION_SH) +#if defined(VERSION_SH) || defined(VERSION_CN) void clear_curr_ai_buffer(void) { s32 currIndex = gCurrAiBufferIndex; s32 i; @@ -984,11 +986,11 @@ void clear_curr_ai_buffer(void) { #endif -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) s32 audio_shut_down_and_reset_step(void) { s32 i; s32 j; -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) s32 num = gAudioBufferParameters.presetUnk4 == 2 ? 2 : 1; #endif @@ -997,7 +999,7 @@ s32 audio_shut_down_and_reset_step(void) { for (i = 0; i < SEQUENCE_PLAYERS; i++) { sequence_player_disable(&gSequencePlayers[i]); } -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) gAudioResetFadeOutFramesLeft = 4 / num; #else gAudioResetFadeOutFramesLeft = 4; @@ -1015,7 +1017,7 @@ s32 audio_shut_down_and_reset_step(void) { gNotes[i].adsr.action |= ADSR_ACTION_RELEASE; } } -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) gAudioResetFadeOutFramesLeft = 16 / num; #else gAudioResetFadeOutFramesLeft = 16; @@ -1026,7 +1028,7 @@ s32 audio_shut_down_and_reset_step(void) { case 3: if (gAudioResetFadeOutFramesLeft != 0) { gAudioResetFadeOutFramesLeft--; -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) if (1) { } #endif @@ -1037,7 +1039,7 @@ s32 audio_shut_down_and_reset_step(void) { gAiBuffers[i][j] = 0; } } -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) gAudioResetFadeOutFramesLeft = 4 / num; #else gAudioResetFadeOutFramesLeft = 4; @@ -1046,14 +1048,14 @@ s32 audio_shut_down_and_reset_step(void) { } break; case 2: -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) clear_curr_ai_buffer(); #endif if (gAudioResetFadeOutFramesLeft != 0) { gAudioResetFadeOutFramesLeft--; } else { gAudioResetStatus--; -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) func_sh_802f23ec(); #endif } @@ -1061,7 +1063,7 @@ s32 audio_shut_down_and_reset_step(void) { case 1: audio_reset_session(); gAudioResetStatus = 0; -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) for (i = 0; i < NUMAIBUFFERS; i++) { gAiBufferLengths[i] = gAudioBufferParameters.maxAiBufferLength; for (j = 0; j < (s32) (AIBUFFER_LEN / sizeof(s16)); j++) { @@ -1070,7 +1072,7 @@ s32 audio_shut_down_and_reset_step(void) { } #endif } -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) if (gAudioResetFadeOutFramesLeft) { } #endif @@ -1140,8 +1142,9 @@ void audio_reset_session(void) { } for (i = 0; i < gMaxSimultaneousNotes; i++) { - if (gNotes[i].enabled) + if (gNotes[i].enabled) { break; + } } if (i == gMaxSimultaneousNotes) { @@ -1178,13 +1181,13 @@ void audio_reset_session(void) { #endif gSampleDmaNumListItems = 0; -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) gAudioBufferParameters.frequency = preset->frequency; gAudioBufferParameters.aiFrequency = osAiSetFrequency(gAudioBufferParameters.frequency); gAudioBufferParameters.samplesPerFrameTarget = ALIGN16(gAudioBufferParameters.frequency / gRefreshRate); gAudioBufferParameters.minAiBufferLength = gAudioBufferParameters.samplesPerFrameTarget - 0x10; gAudioBufferParameters.maxAiBufferLength = gAudioBufferParameters.samplesPerFrameTarget + 0x10; -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) gAudioBufferParameters.updatesPerFrame = (gAudioBufferParameters.samplesPerFrameTarget + 0x10) / 192 + 1; gAudioBufferParameters.samplesPerUpdate = (gAudioBufferParameters.samplesPerFrameTarget / gAudioBufferParameters.updatesPerFrame) & -8; #else @@ -1194,7 +1197,7 @@ void audio_reset_session(void) { gAudioBufferParameters.samplesPerUpdateMax = gAudioBufferParameters.samplesPerUpdate + 8; gAudioBufferParameters.samplesPerUpdateMin = gAudioBufferParameters.samplesPerUpdate - 8; gAudioBufferParameters.resampleRate = 32000.0f / FLOAT_CAST(gAudioBufferParameters.frequency); -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) gAudioBufferParameters.unkUpdatesPerFrameScaled = (1.0f / 256.0f) / gAudioBufferParameters.updatesPerFrame; #else gAudioBufferParameters.unkUpdatesPerFrameScaled = (3.0f / 1280.0f) / gAudioBufferParameters.updatesPerFrame; @@ -1211,7 +1214,7 @@ void audio_reset_session(void) { gAudioBufferParameters.minAiBufferLength *= gAudioBufferParameters.presetUnk4; gAudioBufferParameters.updatesPerFrame *= gAudioBufferParameters.presetUnk4; -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) if (gAudioBufferParameters.presetUnk4 >= 2) { gAudioBufferParameters.maxAiBufferLength -= 0x10; } @@ -1263,7 +1266,7 @@ void audio_reset_session(void) { gMaxAudioCmds = gMaxSimultaneousNotes * 20 * updatesPerFrame + 320; #endif -#if defined(VERSION_SH) +#if defined(VERSION_SH) || defined(VERSION_CN) persistentMem = DOUBLE_SIZE_ON_64_BIT(preset->persistentSeqMem + preset->persistentBankMem + preset->unk18 + preset->unkMem28 + 0x10); temporaryMem = DOUBLE_SIZE_ON_64_BIT(preset->temporarySeqMem + preset->temporaryBankMem + preset->unk24 + preset->unkMem2C + 0x10); #elif defined(VERSION_EU) @@ -1283,7 +1286,7 @@ void audio_reset_session(void) { seq_and_bank_pool_init(&sSeqAndBankPoolSplit); sPersistentCommonPoolSplit.wantSeq = DOUBLE_SIZE_ON_64_BIT(preset->persistentSeqMem); sPersistentCommonPoolSplit.wantBank = DOUBLE_SIZE_ON_64_BIT(preset->persistentBankMem); -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) sPersistentCommonPoolSplit.wantUnused = preset->unk18; #else sPersistentCommonPoolSplit.wantUnused = 0; @@ -1291,13 +1294,13 @@ void audio_reset_session(void) { persistent_pools_init(&sPersistentCommonPoolSplit); sTemporaryCommonPoolSplit.wantSeq = DOUBLE_SIZE_ON_64_BIT(preset->temporarySeqMem); sTemporaryCommonPoolSplit.wantBank = DOUBLE_SIZE_ON_64_BIT(preset->temporaryBankMem); -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) sTemporaryCommonPoolSplit.wantUnused = preset->unk24; #else sTemporaryCommonPoolSplit.wantUnused = 0; #endif temporary_pools_init(&sTemporaryCommonPoolSplit); -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) unk_pools_init(preset->unkMem28, preset->unkMem2C); #endif reset_bank_and_seq_load_status(); @@ -1312,7 +1315,7 @@ void audio_reset_session(void) { note_init_all(); init_note_free_list(); -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) gNoteSubsEu = soundAlloc(&gNotesAndBuffersPool, (gAudioBufferParameters.updatesPerFrame * gMaxSimultaneousNotes) * sizeof(struct NoteSubEu)); for (j = 0; j != 2; j++) { @@ -1326,7 +1329,7 @@ void audio_reset_session(void) { for (j = 0; j < gNumSynthesisReverbs; j++) { reverb = &gSynthesisReverbs[j]; reverbSettings = &preset->reverbSettings[j]; -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) reverb->downsampleRate = reverbSettings->downsampleRate; reverb->windowSize = reverbSettings->windowSize * 64; reverb->windowSize /= reverb->downsampleRate; @@ -1335,7 +1338,7 @@ void audio_reset_session(void) { reverb->downsampleRate = reverbSettings->downsampleRate; #endif reverb->reverbGain = reverbSettings->gain; -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) reverb->panRight = reverbSettings->unk4; reverb->panLeft = reverbSettings->unk6; reverb->unk5 = reverbSettings->unk8; @@ -1349,11 +1352,11 @@ void audio_reset_session(void) { reverb->curFrame = 0; reverb->bufSizePerChannel = reverb->windowSize; reverb->framesLeftToIgnore = 2; -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) reverb->resampleFlags = A_INIT; #endif if (reverb->downsampleRate != 1) { -#ifndef VERSION_SH +#if !defined(VERSION_SH) && !defined(VERSION_CN) reverb->resampleFlags = A_INIT; #endif reverb->resampleRate = 0x8000 / reverb->downsampleRate; @@ -1370,7 +1373,7 @@ void audio_reset_session(void) { reverb->items[1][i].toDownsampleRight = mem + DEFAULT_LEN_1CH / sizeof(s16); } } -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) if (reverbSettings->unkC != 0) { reverb->unk108 = sound_alloc_uninitialized(&gNotesAndBuffersPool, 16 * sizeof(s16)); reverb->unk100 = sound_alloc_uninitialized(&gNotesAndBuffersPool, 8 * sizeof(s16)); @@ -1426,7 +1429,7 @@ void audio_reset_session(void) { build_vol_rampings_table(0, gAudioBufferParameters.samplesPerUpdate); #endif -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) D_SH_8034F68C = 0; D_SH_803479B4 = 4096; #endif @@ -1440,7 +1443,7 @@ void audio_reset_session(void) { #endif } -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) void *unk_pool1_lookup(s32 poolIdx, s32 id) { s32 i; diff --git a/src/audio/heap.h b/src/audio/heap.h index 7f9632b5..c3c36e67 100644 --- a/src/audio/heap.h +++ b/src/audio/heap.h @@ -25,7 +25,7 @@ struct SoundAllocPool { struct SeqOrBankEntry { u8 *ptr; u32 size; -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) s16 poolIndex; s16 id; #else @@ -93,7 +93,7 @@ extern struct SoundAllocPool gPersistentCommonPool; extern struct SoundAllocPool gTemporaryCommonPool; extern struct SoundMultiPool gSeqLoadedPool; extern struct SoundMultiPool gBankLoadedPool; -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) extern struct Unk1Pool gUnkPool1; extern struct UnkPool gUnkPool2; extern struct UnkPool gUnkPool3; @@ -103,7 +103,7 @@ extern u8 gSeqLoadStatus[256]; extern volatile u8 gAudioResetStatus; extern u8 gAudioResetPresetIdToLoad; -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) extern volatile u8 gAudioResetStatus; #endif @@ -111,14 +111,14 @@ void *soundAlloc(struct SoundAllocPool *pool, u32 size); void *sound_alloc_uninitialized(struct SoundAllocPool *pool, u32 size); void sound_init_main_pools(s32 sizeForAudioInitPool); void sound_alloc_pool_init(struct SoundAllocPool *pool, void *memAddr, u32 size); -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) void *alloc_bank_or_seq(s32 poolIdx, s32 size, s32 arg3, s32 id); void *get_bank_or_seq(s32 poolIdx, s32 arg1, s32 id); #else void *alloc_bank_or_seq(struct SoundMultiPool *arg0, s32 arg1, s32 size, s32 arg3, s32 id); void *get_bank_or_seq(struct SoundMultiPool *arg0, s32 arg1, s32 id); #endif -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) s32 audio_shut_down_and_reset_step(void); void audio_reset_session(void); #else @@ -126,7 +126,7 @@ void audio_reset_session(struct AudioSessionSettings *preset); #endif void discard_bank(s32 bankId); -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) void fill_filter(s16 filter[8], s32 arg1, s32 arg2); u8 *func_sh_802f1d40(u32 size, s32 bank, u8 *arg2, s8 medium); u8 *func_sh_802f1d90(u32 size, s32 bank, u8 *arg2, s8 medium); diff --git a/src/audio/internal.h b/src/audio/internal.h index f91c3a2e..1ca40b06 100644 --- a/src/audio/internal.h +++ b/src/audio/internal.h @@ -5,7 +5,7 @@ #include "types.h" -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) #define SEQUENCE_PLAYERS 4 #define SEQUENCE_CHANNELS 48 #define SEQUENCE_LAYERS 64 @@ -120,7 +120,7 @@ struct NotePool { struct VibratoState { /*0x00, 0x00*/ struct SequenceChannel *seqChannel; /*0x04, 0x04*/ u32 time; -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) /* , 0x08*/ s16 *curve; /* , 0x0C*/ f32 extent; /* , 0x10*/ f32 rate; @@ -167,7 +167,7 @@ struct AdpcmBook { }; struct AudioBankSample { -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) /* 0x00 */ u32 codec : 4; /* 0x00 */ u32 medium : 2; /* 0x00 */ u32 bit1 : 1; @@ -180,7 +180,7 @@ struct AudioBankSample { u8 *sampleAddr; struct AdpcmLoop *loop; struct AdpcmBook *book; -#ifndef VERSION_SH +#if !defined(VERSION_SH) && !defined(VERSION_CN) u32 sampleSize; // never read. either 0 or 1 mod 9, depending on padding #endif }; @@ -215,12 +215,12 @@ struct AudioBank { }; // dynamic size struct CtlEntry { -#ifndef VERSION_SH +#if !defined(VERSION_SH) && !defined(VERSION_CN) u8 unused; #endif u8 numInstruments; u8 numDrums; -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) u8 bankId1; u8 bankId2; #endif @@ -238,7 +238,7 @@ struct M64ScriptState { // Also known as a Group, according to debug strings. struct SequencePlayer { /*US/JP, EU, SH */ -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) /*0x000, 0x000, 0x000*/ u8 enabled : 1; #else /*0x000, 0x000*/ volatile u8 enabled : 1; @@ -247,10 +247,10 @@ struct SequencePlayer { /*0x000, 0x000*/ u8 muted : 1; /*0x000, 0x000*/ u8 seqDmaInProgress : 1; /*0x000, 0x000*/ u8 bankDmaInProgress : 1; -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) /* 0x000*/ u8 recalculateVolume : 1; #endif -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) /* 0x000*/ u8 unkSh: 1; #endif #if defined(VERSION_JP) || defined(VERSION_US) @@ -267,7 +267,7 @@ struct SequencePlayer { /*0x008, ?????*/ u8 loadingBankNumInstruments; /*0x009, ?????*/ u8 loadingBankNumDrums; #endif -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) /* , 0x007, 0x007*/ s8 seqVariationEu[1]; #endif /*0x00A, 0x008*/ u16 tempo; // beats per minute in JP, tatums per minute in US/EU @@ -275,12 +275,12 @@ struct SequencePlayer { #if defined(VERSION_JP) || defined(VERSION_US) /*0x00E, 0x010*/ u16 fadeRemainingFrames; #endif -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) /* 0x00C*/ s16 tempoAdd; #endif /*0x010, 0x00C, 0x00E*/ s16 transposition; /*0x012, 0x00E, 0x010*/ u16 delay; -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) /*0x00E, 0x010, 0x012*/ u16 fadeRemainingFrames; /* , 0x012, 0x014*/ u16 fadeTimerUnkEu; #endif @@ -289,7 +289,7 @@ struct SequencePlayer { /*0x01C, 0x01C*/ f32 fadeVelocity; // set to 0.0f /*0x020, 0x020, 0x024*/ f32 volume; // set to 0.0f /*0x024, 0x024*/ f32 muteVolumeScale; // set to 0.5f -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) /* , 0x028, 0x02C*/ f32 fadeVolumeScale; /* , 0x02C*/ f32 appliedFadeVolume; #else @@ -316,7 +316,7 @@ struct SequencePlayer { struct AdsrSettings { u8 releaseRate; -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) u8 sustain; #else u16 sustain; // sustain level, 2^16 = max @@ -334,7 +334,7 @@ struct AdsrState { #endif /*0x08, 0x02*/ s16 envIndex; /*0x0A, 0x04*/ s16 delay; -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) /* , 0x08*/ f32 sustain; /* , 0x0C*/ f32 velocity; /* , 0x10*/ f32 fadeOutVel; @@ -378,13 +378,13 @@ struct ReverbInfo { struct NoteAttributes { u8 reverbVol; -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) u8 synthesisVolume; // UQ4.4, although 0 <= x < 1 is rounded up to 1 #endif -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) u8 pan; #endif -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) union ReverbBits reverbBits; #endif f32 freqScale; @@ -392,7 +392,7 @@ struct NoteAttributes { #if defined(VERSION_JP) || defined(VERSION_US) f32 pan; #endif -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) s16 *filter; #endif }; // size = 0x10 @@ -409,7 +409,7 @@ struct SequenceChannel { /*0x00, 0x00*/ u8 stereoHeadsetEffects : 1; /*0x00, ????*/ u8 largeNotes : 1; // notes specify duration and velocity /*0x00, ????*/ u8 unused : 1; // never read, set to 0 -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) /* , 0x01*/ union { struct { u8 freqScale : 1; @@ -423,11 +423,11 @@ struct SequenceChannel { /*0x02, 0x03, 0x03*/ u8 muteBehavior; /*0x03, 0x04, 0x04*/ u8 reverbVol; // until EU: Q1.7, after EU: UQ0.8 /*0x04, ????*/ u8 notePriority; // 0-3 -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) u8 unkSH06; // some priority #endif /*0x05, 0x06*/ u8 bankId; -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) /* , 0x07*/ u8 reverbIndex; /* , 0x08, 0x09*/ u8 bookOffset; /* , 0x09*/ u8 newPan; @@ -435,7 +435,7 @@ struct SequenceChannel { #else /*0x06, */ u8 updatesPerFrameUnused; #endif -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) /* 0x0C*/ u8 synthesisVolume; // UQ4.4, although 0 <= x < 1 is rounded up to 1 #endif /*0x08, 0x0C, 0x0E*/ u16 vibratoRateStart; // initially 0x800 @@ -465,14 +465,14 @@ struct SequenceChannel { /*0x3C, 0x40*/ struct Instrument *instrument; /*0x40, 0x44*/ struct SequencePlayer *seqPlayer; /*0x44, 0x48*/ struct SequenceChannelLayer *layers[LAYERS_MAX]; -#ifndef VERSION_SH +#if !defined(VERSION_SH) && !defined(VERSION_CN) /*0x54, 0x58 */ s8 soundScriptIO[8]; // bridge between sound script and audio lib. For player 2, // [0] contains enabled, [4] contains sound ID, [5] contains reverb adjustment #endif /*0x5C, 0x60*/ struct M64ScriptState scriptState; /*0x78, 0x7C*/ struct AdsrSettings adsr; /*0x80, 0x84*/ struct NotePool notePool; -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) /* 0xC0*/ s8 soundScriptIO[8]; // bridge between sound script and audio lib. For player 2, // [0] contains enabled, [4] contains sound ID, [5] contains reverb adjustment /* 0xC8*/ u16 unkC8; @@ -487,11 +487,11 @@ struct SequenceChannelLayer { /*0x00, 0x00*/ u8 finished : 1; /*0x00, 0x00*/ u8 stopSomething : 1; // ? /*0x00, 0x00*/ u8 continuousNotes : 1; // keep the same note for consecutive notes with the same sound -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) /* , 0x00*/ u8 unusedEu0b8 : 1; /* , 0x00*/ u8 notePropertiesNeedInit : 1; /* , 0x00*/ u8 ignoreDrumPan : 1; -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) /* , , 0x01 */ union ReverbBits reverbBits; #endif /* , 0x01, 0x02*/ u8 instOrWave; @@ -499,7 +499,7 @@ struct SequenceChannelLayer { /*0x01, 0x02, 0x03*/ u8 status; // 0x03 in SH /*0x02, 0x03*/ u8 noteDuration; // set to 0x80 /*0x03, 0x04*/ u8 portamentoTargetNote; -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) /* , 0x05*/ u8 pan; // 0..128 /* , 0x06, 0x07*/ u8 notePan; #endif @@ -510,7 +510,7 @@ struct SequenceChannelLayer { // (m64 instruction encoding only allows referring to the limited range // 0..0x3f; this makes 0x40..0x7f accessible as well) /*0x20, 0x24, 0x24*/ f32 freqScale; -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) /* 0x28*/ f32 freqScaleMultiplier; #endif /*0x24, 0x28, 0x2C*/ f32 velocitySquare; @@ -538,13 +538,13 @@ struct SequenceChannelLayer { #endif }; // size = 0x80 -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) struct NoteSynthesisState { /*0x00*/ u8 restart; /*0x01*/ u8 sampleDmaIndex; /*0x02*/ u8 prevHeadsetPanRight; /*0x03*/ u8 prevHeadsetPanLeft; -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) /* 0x04*/ u8 reverbVol; /* 0x05*/ u8 unk5; #endif @@ -559,7 +559,7 @@ struct NotePlaybackState { /*0x04, 0x00, 0x00*/ u8 priority; /* 0x01, 0x01*/ u8 waveId; /* 0x02, 0x02*/ u8 sampleCountIndex; -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) /* 0x03*/ u8 bankId; /* 0x04*/ u8 unkSH34; #endif @@ -602,7 +602,7 @@ struct NoteSubEu { s16 *samples; struct AudioBankSound *audioBankSound; } sound; -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) /*0x10*/ s16 *filter; #endif }; @@ -622,7 +622,7 @@ struct Note { /*0x04, 0x30, 0x30*/ u8 priority; /* 0x31, 0x31*/ u8 waveId; /* 0x32, 0x32*/ u8 sampleCountIndex; -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) /* 0x33*/ u8 bankId; /* 0x34*/ u8 unkSH34; #endif @@ -699,7 +699,7 @@ struct Note { struct NoteSynthesisBuffers { s16 adpcmdecState[0x10]; s16 finalResampleState[0x10]; -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) s16 unk[0x10]; s16 filterBuffer[0x20]; s16 panSamplesBuffer[0x20]; @@ -745,12 +745,12 @@ struct AudioSessionSettingsEU { /* 0x0E */ u16 unk3; // always 0 /* 0x10 */ u32 persistentSeqMem; /* 0x14 */ u32 persistentBankMem; -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) /* 0x18 */ u32 unk18; // always 0 #endif /* 0x18, 0x1C */ u32 temporarySeqMem; /* 0x1C, 0x20 */ u32 temporaryBankMem; -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) /* 0x24 */ u32 unk24; // always 0 /* 0x28 */ u32 unkMem28; // always 0 /* 0x2C */ u32 unkMem2C; // always 0 @@ -825,7 +825,7 @@ struct EuAudioCmd { } u2; }; -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) struct PendingDmaSample { u8 medium; u8 bankId; diff --git a/src/audio/load.c b/src/audio/load.c index 896032dd..aa0c71d9 100644 --- a/src/audio/load.c +++ b/src/audio/load.c @@ -1,4 +1,4 @@ -#ifndef VERSION_SH +#if !defined(VERSION_SH) && !defined(VERSION_CN) #include #include @@ -71,7 +71,7 @@ struct CtlEntry *gCtlEntries; // sh: 0x803505F8 #if defined(VERSION_EU) u32 padEuBss1; struct AudioBufferParametersEU gAudioBufferParameters; -#elif defined(VERSION_US) || defined(VERSION_JP) +#else s32 gAiFrequency; #endif diff --git a/src/audio/load.h b/src/audio/load.h index 63379d21..11e05546 100644 --- a/src/audio/load.h +++ b/src/audio/load.h @@ -36,11 +36,11 @@ extern ALSeqFile *gSeqFileHeader; extern u8 *gAlBankSets; extern struct CtlEntry *gCtlEntries; -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) extern struct AudioBufferParametersEU gAudioBufferParameters; #endif extern s32 gAiFrequency; -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) extern s16 gCurrAiBufferLength; extern s32 D_SH_8034F68C; #endif @@ -53,7 +53,7 @@ extern s16 gTempoInternalToExternal; extern s8 gAudioUpdatesPerFrame; // = 4 extern s8 gSoundMode; -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) extern OSMesgQueue gUnkQueue1; struct UnkStructSH8034EC88 { @@ -78,25 +78,25 @@ extern struct UnkStructSH8034EC88 D_SH_8034EC88[0x80]; void audio_dma_partial_copy_async(uintptr_t *devAddr, u8 **vAddr, ssize_t *remaining, OSMesgQueue *queue, OSIoMesg *mesg); void decrease_sample_dma_ttls(void); -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) void *dma_sample_data(uintptr_t devAddr, u32 size, s32 arg2, u8 *dmaIndexRef, s32 medium); #else void *dma_sample_data(uintptr_t devAddr, u32 size, s32 arg2, u8 *dmaIndexRef); #endif void init_sample_dma_buffers(s32 arg0); -#if defined(VERSION_SH) +#if defined(VERSION_SH) || defined(VERSION_CN) void patch_audio_bank(s32 bankId, struct AudioBank *mem, struct PatchStruct *patchInfo); #else void patch_audio_bank(struct AudioBank *mem, u8 *offset, u32 numInstruments, u32 numDrums); #endif -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) void preload_sequence(u32 seqId, s32 preloadMask); #else void preload_sequence(u32 seqId, u8 preloadMask); #endif void load_sequence(u32 player, u32 seqId, s32 loadAsync); -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) void func_sh_802f3158(s32 seqId, s32 arg1, s32 arg2, OSMesgQueue *retQueue); u8 *func_sh_802f3220(u32 seqId, u32 *a1); struct AudioBankSample *func_sh_802f4978(s32 bankId, s32 idx); diff --git a/src/audio/load_sh.c b/src/audio/load_sh.c index 99593a28..ac57be1f 100644 --- a/src/audio/load_sh.c +++ b/src/audio/load_sh.c @@ -1,4 +1,4 @@ -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) #include #include @@ -983,7 +983,6 @@ void func_sh_802f41e4(s32 audioResetStatus) { func_sh_802f4dcc(audioResetStatus); } -#if defined(VERSION_SH) u8 gShindouSoundBanksHeader[] = { #include "sound/ctl_header.inc.c" }; @@ -999,7 +998,6 @@ u8 gShindouSampleBanksHeader[] = { u8 gShindouSequencesHeader[] = { #include "sound/sequences_header.inc.c" }; -#endif // (void) must be omitted from parameters void audio_init() { diff --git a/src/audio/playback.c b/src/audio/playback.c index ff42e765..333d0840 100644 --- a/src/audio/playback.c +++ b/src/audio/playback.c @@ -11,8 +11,8 @@ void note_set_resampling_rate(struct Note *note, f32 resamplingRateInput); -#if defined(VERSION_EU) || defined(VERSION_SH) -#ifdef VERSION_SH +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) +#if defined(VERSION_SH) || defined(VERSION_CN) void note_set_vel_pan_reverb(struct Note *note, struct ReverbInfo *reverbInfo) #else void note_set_vel_pan_reverb(struct Note *note, f32 velocity, u8 pan, u8 reverbVol) @@ -34,7 +34,7 @@ void note_set_vel_pan_reverb(struct Note *note, f32 velocity, u8 pan, u8 reverbV struct ReverbBitsData reverbBits; #endif -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) note_set_resampling_rate(note, reverbInfo->freqScale); velocity = reverbInfo->velocity; pan = reverbInfo->pan; @@ -46,7 +46,7 @@ void note_set_vel_pan_reverb(struct Note *note, f32 velocity, u8 pan, u8 reverbV #endif if (note->noteSubEu.stereoHeadsetEffects && gSoundMode == SOUND_MODE_HEADSET) { -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) smallPanIndex = pan >> 1; #else smallPanIndex = pan >> 3; @@ -64,7 +64,7 @@ void note_set_vel_pan_reverb(struct Note *note, f32 velocity, u8 pan, u8 reverbV volLeft = gHeadsetPanVolume[pan]; volRight = gHeadsetPanVolume[127 - pan]; } else if (sub->stereoHeadsetEffects && gSoundMode == SOUND_MODE_STEREO) { -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) strongRight = FALSE; strongLeft = FALSE; sub->headsetPanRight = 0; @@ -89,7 +89,7 @@ void note_set_vel_pan_reverb(struct Note *note, f32 velocity, u8 pan, u8 reverbV sub->stereoStrongRight = strongRight; sub->stereoStrongLeft = strongLeft; -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) switch (reverbBits.stereoHeadsetEffects) { case 0: sub->stereoStrongRight = reverbBits.strongRight; @@ -118,7 +118,7 @@ void note_set_vel_pan_reverb(struct Note *note, f32 velocity, u8 pan, u8 reverbV volRight = gDefaultPanVolume[127 - pan]; } -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) if (velocity < 0.0f) { velocity = 0.0f; } @@ -146,7 +146,7 @@ void note_set_vel_pan_reverb(struct Note *note, f32 velocity, u8 pan, u8 reverbV //! @bug for the change to UQ0.7, the if statement should also have been changed accordingly if (sub->reverbVol != reverbVol) { -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) sub->reverbVol = reverbVol >> 1; #else sub->reverbVol = reverbVol; @@ -162,7 +162,7 @@ void note_set_vel_pan_reverb(struct Note *note, f32 velocity, u8 pan, u8 reverbV } } -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) #define MIN_RESAMPLING_RATE 1.99998f #else #define MIN_RESAMPLING_RATE 1.99996f @@ -255,7 +255,7 @@ struct Instrument *get_instrument_inner(s32 bankId, s32 instId) { struct Drum *get_drum(s32 bankId, s32 drumId) { struct Drum *drum; -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) if (IS_BANK_LOAD_COMPLETE(bankId) == FALSE) { stubbed_printf("Audio: voiceman: No bank error %d\n", bankId); gAudioErrorFlags = bankId + 0x10000000; @@ -287,7 +287,7 @@ struct Drum *get_drum(s32 bankId, s32 drumId) { #endif #endif // VERSION_EU -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) void note_init_for_layer(struct Note *note, struct SequenceChannelLayer *seqLayer); #else s32 note_init_for_layer(struct Note *note, struct SequenceChannelLayer *seqLayer); @@ -299,11 +299,11 @@ void note_init(struct Note *note) { } else { adsr_init(¬e->adsr, note->parentLayer->adsr.envelope, ¬e->adsrVolScale); } -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) note->unkSH34 = 0; #endif note->adsr.state = ADSR_STATE_INITIAL; -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) note->noteSubEu = gDefaultNoteSub; #else note_init_volume(note); @@ -311,7 +311,7 @@ void note_init(struct Note *note) { #endif } -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) #define note_disable2 note_disable void note_disable(struct Note *note) { if (note->noteSubEu.needsInit == TRUE) { @@ -323,14 +323,14 @@ void note_disable(struct Note *note) { } #endif note->priority = NOTE_PRIORITY_DISABLED; -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) note->unkSH34 = 0; #endif note->parentLayer = NO_LAYER; note->prevParentLayer = NO_LAYER; note->noteSubEu.enabled = FALSE; note->noteSubEu.finished = FALSE; -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) note->adsr.state = ADSR_STATE_DISABLED; note->adsr.current = 0; #endif @@ -343,7 +343,7 @@ void note_disable2(struct Note *note) { void process_notes(void) { f32 scale; -#ifndef VERSION_SH +#if !defined(VERSION_SH) && !defined(VERSION_CN) f32 frequency; #if defined(VERSION_JP) || defined(VERSION_US) u8 reverbVol; @@ -355,10 +355,10 @@ void process_notes(void) { #endif #endif struct Note *note; -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) struct NotePlaybackState *playbackState; struct NoteSubEu *noteSubEu; -#ifndef VERSION_SH +#ifdef VERSION_EU UNUSED u8 pad[12]; u8 reverbVol; UNUSED u8 pad3; @@ -389,7 +389,7 @@ void process_notes(void) { for (i = 0; i < gMaxSimultaneousNotes; i++) { note = &gNotes[i]; -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) playbackState = (struct NotePlaybackState *) ¬e->priority; if (note->parentLayer != NO_LAYER) { #ifndef NO_SEGMENTED_MEMORY @@ -397,7 +397,7 @@ void process_notes(void) { continue; } #endif -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) if (note != playbackState->parentLayer->note && playbackState->unkSH34 == 0) { playbackState->adsr.action |= ADSR_ACTION_RELEASE; playbackState->adsr.fadeOutVel = gAudioBufferParameters.updatesPerFrameInv; @@ -456,11 +456,11 @@ void process_notes(void) { #endif d: if (playbackState->priority != NOTE_PRIORITY_DISABLED) { -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) if (1) {} #endif noteSubEu = ¬e->noteSubEu; -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) if (playbackState->unkSH34 >= 1 || noteSubEu->finished) { #else if (playbackState->priority == NOTE_PRIORITY_STOPPING || noteSubEu->finished) { @@ -490,7 +490,7 @@ void process_notes(void) { goto skip; } } -#ifndef VERSION_SH +#if !defined(VERSION_SH) && !defined(VERSION_CN) if (1) { } #endif @@ -504,7 +504,7 @@ void process_notes(void) { scale = adsr_update(&playbackState->adsr); note_vibrato_update(note); attributes = &playbackState->attributes; -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) if (playbackState->unkSH34 == 1 || playbackState->unkSH34 == 2) { reverbInfo.freqScale = attributes->freqScale; reverbInfo.velocity = attributes->velocity; @@ -631,7 +631,7 @@ void process_notes(void) { #undef POP } -#if defined(VERSION_SH) +#if defined(VERSION_SH) || defined(VERSION_CN) // These three are matching but have been moved from above in shindou: struct AudioBankSound *instrument_get_audio_bank_sound(struct Instrument *instrument, s32 semitone) { struct AudioBankSound *sound; @@ -701,7 +701,7 @@ void seq_channel_layer_decay_release_internal(struct SequenceChannelLayer *seqLa return; } -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) seqLayer->status = SOUND_LOAD_STATUS_NOT_LOADED; #endif @@ -724,7 +724,7 @@ void seq_channel_layer_decay_release_internal(struct SequenceChannelLayer *seqLa if (note->parentLayer != seqLayer) { -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) if (note->parentLayer == NO_LAYER && note->wantedParentLayer == NO_LAYER && note->prevParentLayer == seqLayer && target != ADSR_STATE_DECAY) { // Just guessing that this printf goes here... it's hard to parse. @@ -736,19 +736,19 @@ void seq_channel_layer_decay_release_internal(struct SequenceChannelLayer *seqLa return; } -#ifndef VERSION_SH +#if !defined(VERSION_SH) && !defined(VERSION_CN) seqLayer->status = SOUND_LOAD_STATUS_NOT_LOADED; #endif if (note->adsr.state != ADSR_STATE_DECAY) { attributes->freqScale = seqLayer->noteFreqScale; attributes->velocity = seqLayer->noteVelocity; attributes->pan = seqLayer->notePan; -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) attributes->reverbBits = seqLayer->reverbBits; #endif if (seqLayer->seqChannel != NULL) { attributes->reverbVol = seqLayer->seqChannel->reverbVol; -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) attributes->synthesisVolume = seqLayer->seqChannel->synthesisVolume; attributes->filter = seqLayer->seqChannel->filter; if (seqLayer->seqChannel->seqPlayer->muted && (seqLayer->seqChannel->muteBehavior & 8) != 0) { @@ -757,31 +757,31 @@ void seq_channel_layer_decay_release_internal(struct SequenceChannelLayer *seqLa note->priority = seqLayer->seqChannel->unkSH06; #endif } -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) else { #endif note->priority = NOTE_PRIORITY_STOPPING; -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) } #endif note->prevParentLayer = note->parentLayer; note->parentLayer = NO_LAYER; if (target == ADSR_STATE_RELEASE) { -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) note->adsr.fadeOutVel = gAudioBufferParameters.updatesPerFrameInv; #else note->adsr.fadeOutVel = 0x8000 / gAudioUpdatesPerFrame; #endif note->adsr.action |= ADSR_ACTION_RELEASE; -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) note->unkSH34 = 2; #endif } else { -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) note->unkSH34 = 1; #endif note->adsr.action |= ADSR_ACTION_DECAY; -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) if (seqLayer->adsr.releaseRate == 0) { note->adsr.fadeOutVel = seqLayer->seqChannel->adsr.releaseRate * gAudioBufferParameters.unkUpdatesPerFrameScaled; } else { @@ -813,7 +813,7 @@ void seq_channel_layer_note_release(struct SequenceChannelLayer *seqLayer) { seq_channel_layer_decay_release_internal(seqLayer, ADSR_STATE_RELEASE); } -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) s32 build_synthetic_wave(struct Note *note, struct SequenceChannelLayer *seqLayer, s32 waveId) { f32 freqScale; f32 ratio; @@ -910,7 +910,7 @@ void build_synthetic_wave(struct Note *note, struct SequenceChannelLayer *seqLay #endif void init_synthetic_wave(struct Note *note, struct SequenceChannelLayer *seqLayer) { -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) s32 sampleCountIndex; s32 waveSampleCountIndex; s32 waveId = seqLayer->instOrWave; @@ -919,7 +919,7 @@ void init_synthetic_wave(struct Note *note, struct SequenceChannelLayer *seqLaye } sampleCountIndex = note->sampleCountIndex; waveSampleCountIndex = build_synthetic_wave(note, seqLayer, waveId); -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) note->synthesisState.samplePosInt = note->synthesisState.samplePosInt * euUnknownData_8030194c[waveSampleCountIndex] / euUnknownData_8030194c[sampleCountIndex]; #else // Not a real change. Just temporary so I can remove this variable. note->synthesisState.samplePosInt = note->synthesisState.samplePosInt * gDefaultShortNoteVelocityTable[waveSampleCountIndex] / gDefaultShortNoteVelocityTable[sampleCountIndex]; @@ -993,7 +993,7 @@ void note_pool_clear(struct NotePool *pool) { break; } -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) for (;;) { cur = source->next; if (cur == source) { @@ -1108,7 +1108,7 @@ struct Note *pop_node_with_lower_prio(struct AudioListItem *list, s32 limit) { } } -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) if (best == NULL) { return NULL; } @@ -1122,13 +1122,13 @@ struct Note *pop_node_with_lower_prio(struct AudioListItem *list, s32 limit) { } #endif -#ifndef VERSION_SH +#if !defined(VERSION_SH) && !defined(VERSION_CN) audio_list_remove(best); #endif return best->u.value; } -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) void note_init_for_layer(struct Note *note, struct SequenceChannelLayer *seqLayer) { UNUSED s32 pad[4]; s16 instId; @@ -1159,7 +1159,7 @@ void note_init_for_layer(struct Note *note, struct SequenceChannelLayer *seqLaye if (sub->isSyntheticWave) { build_synthetic_wave(note, seqLayer, instId); } -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) note->bankId = seqLayer->seqChannel->bankId; #else sub->bankId = seqLayer->seqChannel->bankId; @@ -1198,13 +1198,13 @@ void func_80319728(struct Note *note, struct SequenceChannelLayer *seqLayer) { void note_release_and_take_ownership(struct Note *note, struct SequenceChannelLayer *seqLayer) { note->wantedParentLayer = seqLayer; -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) note->priority = seqLayer->seqChannel->notePriority; #else note->priority = NOTE_PRIORITY_STOPPING; #endif -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) note->adsr.fadeOutVel = gAudioBufferParameters.updatesPerFrameInv; #else note->adsr.fadeOutVel = 0x8000 / gAudioUpdatesPerFrame; @@ -1215,7 +1215,7 @@ void note_release_and_take_ownership(struct Note *note, struct SequenceChannelLa struct Note *alloc_note_from_disabled(struct NotePool *pool, struct SequenceChannelLayer *seqLayer) { struct Note *note = audio_list_pop_back(&pool->disabled); if (note != NULL) { -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) note_init_for_layer(note, seqLayer); #else if (note_init_for_layer(note, seqLayer) == TRUE) { @@ -1238,11 +1238,11 @@ struct Note *alloc_note_from_decaying(struct NotePool *pool, struct SequenceChan } struct Note *alloc_note_from_active(struct NotePool *pool, struct SequenceChannelLayer *seqLayer) { -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) struct Note *rNote; #endif struct Note *aNote; -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) s32 rPriority, aPriority; rPriority = aPriority = 0x10; @@ -1258,7 +1258,7 @@ struct Note *alloc_note_from_active(struct NotePool *pool, struct SequenceChanne if (aNote == NULL) { eu_stubbed_printf_0("Audio: C-Alloc : lowerPrio is NULL\n"); } else { -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) aPriority = aNote->priority; #else func_80319728(aNote, seqLayer); @@ -1266,7 +1266,7 @@ struct Note *alloc_note_from_active(struct NotePool *pool, struct SequenceChanne #endif } -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) if (rNote == NULL && aNote == NULL) { return NULL; } @@ -1293,13 +1293,13 @@ struct Note *alloc_note(struct SequenceChannelLayer *seqLayer) { if (policy & NOTE_ALLOC_LAYER) { ret = seqLayer->note; if (ret != NULL && ret->prevParentLayer == seqLayer -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) && ret->wantedParentLayer == NO_LAYER #endif ) { note_release_and_take_ownership(ret, seqLayer); audio_list_remove(&ret->listItem); -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) audio_list_push_back(&ret->listItem.pool->releasing, &ret->listItem); #else audio_list_push_back(&gNoteFreeLists.releasing, &ret->listItem); @@ -1312,7 +1312,7 @@ struct Note *alloc_note(struct SequenceChannelLayer *seqLayer) { if (!(ret = alloc_note_from_disabled(&seqLayer->seqChannel->notePool, seqLayer)) && !(ret = alloc_note_from_decaying(&seqLayer->seqChannel->notePool, seqLayer)) && !(ret = alloc_note_from_active(&seqLayer->seqChannel->notePool, seqLayer))) { -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) goto null_return; #else eu_stubbed_printf_0("Sub Limited Warning: Drop Voice"); @@ -1330,7 +1330,7 @@ struct Note *alloc_note(struct SequenceChannelLayer *seqLayer) { && !(ret = alloc_note_from_decaying(&seqLayer->seqChannel->seqPlayer->notePool, seqLayer)) && !(ret = alloc_note_from_active(&seqLayer->seqChannel->notePool, seqLayer)) && !(ret = alloc_note_from_active(&seqLayer->seqChannel->seqPlayer->notePool, seqLayer))) { -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) goto null_return; #else eu_stubbed_printf_0("Warning: Drop Voice"); @@ -1345,7 +1345,7 @@ struct Note *alloc_note(struct SequenceChannelLayer *seqLayer) { if (!(ret = alloc_note_from_disabled(&gNoteFreeLists, seqLayer)) && !(ret = alloc_note_from_decaying(&gNoteFreeLists, seqLayer)) && !(ret = alloc_note_from_active(&gNoteFreeLists, seqLayer))) { -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) goto null_return; #else eu_stubbed_printf_0("Warning: Drop Voice"); @@ -1365,7 +1365,7 @@ struct Note *alloc_note(struct SequenceChannelLayer *seqLayer) { && !(ret = alloc_note_from_active(&seqLayer->seqChannel->notePool, seqLayer)) && !(ret = alloc_note_from_active(&seqLayer->seqChannel->seqPlayer->notePool, seqLayer)) && !(ret = alloc_note_from_active(&gNoteFreeLists, seqLayer))) { -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) goto null_return; #else eu_stubbed_printf_0("Warning: Drop Voice"); @@ -1375,7 +1375,7 @@ struct Note *alloc_note(struct SequenceChannelLayer *seqLayer) { } return ret; -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) null_return: seqLayer->status = SOUND_LOAD_STATUS_NOT_LOADED; return NULL; @@ -1427,7 +1427,7 @@ void note_init_all(void) { for (i = 0; i < gMaxSimultaneousNotes; i++) { note = &gNotes[i]; -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) note->noteSubEu = gZeroNoteSub; #else note->enabled = FALSE; @@ -1436,13 +1436,13 @@ void note_init_all(void) { note->stereoHeadsetEffects = FALSE; #endif note->priority = NOTE_PRIORITY_DISABLED; -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) note->unkSH34 = 0; #endif note->parentLayer = NO_LAYER; note->wantedParentLayer = NO_LAYER; note->prevParentLayer = NO_LAYER; -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) note->waveId = 0; #else note->reverbVol = 0; @@ -1461,7 +1461,7 @@ void note_init_all(void) { note->vibratoState.active = FALSE; note->portamento.cur = 0.0f; note->portamento.speed = 0.0f; -#if defined(VERSION_SH) +#if defined(VERSION_SH) || defined(VERSION_CN) note->synthesisState.synthesisBuffers = sound_alloc_uninitialized(&gNotesAndBuffersPool, sizeof(struct NoteSynthesisBuffers)); #elif defined(VERSION_EU) note->synthesisState.synthesisBuffers = soundAlloc(&gNotesAndBuffersPool, sizeof(struct NoteSynthesisBuffers)); diff --git a/src/audio/port_sh.c b/src/audio/port_sh.c index e7fae5b0..e96f7c32 100644 --- a/src/audio/port_sh.c +++ b/src/audio/port_sh.c @@ -1,5 +1,5 @@ -#ifdef VERSION_SH -// TODO: merge this with port_eu.c? +#if defined(VERSION_SH) || defined(VERSION_CN) +// TODO: merge this with port_eu.c #include diff --git a/src/audio/seqplayer.c b/src/audio/seqplayer.c index 13ee393b..b65fa609 100644 --- a/src/audio/seqplayer.c +++ b/src/audio/seqplayer.c @@ -15,7 +15,7 @@ #define PORTAMENTO_MODE_4 4 #define PORTAMENTO_MODE_5 5 -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) void seq_channel_layer_process_script_part1(struct SequenceChannelLayer *layer); s32 seq_channel_layer_process_script_part2(struct SequenceChannelLayer *layer); s32 seq_channel_layer_process_script_part3(struct SequenceChannelLayer *layer, s32 cmd); @@ -38,7 +38,7 @@ void sequence_channel_init(struct SequenceChannel *seqChannel) { seqChannel->stereoHeadsetEffects = FALSE; seqChannel->transposition = 0; seqChannel->largeNotes = FALSE; -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) seqChannel->bookOffset = 0; seqChannel->changes.as_u8 = 0xff; seqChannel->scriptState.depth = 0; @@ -56,11 +56,11 @@ void sequence_channel_init(struct SequenceChannel *seqChannel) { seqChannel->noteUnused = NULL; #endif seqChannel->reverbVol = 0; -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) seqChannel->synthesisVolume = 0; #endif seqChannel->notePriority = NOTE_PRIORITY_DEFAULT; -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) seqChannel->unkSH06 = 1; #endif seqChannel->delay = 0; @@ -77,10 +77,10 @@ void sequence_channel_init(struct SequenceChannel *seqChannel) { seqChannel->vibratoRateChangeDelay = 0; seqChannel->vibratoExtentChangeDelay = 0; seqChannel->vibratoDelay = 0; -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) seqChannel->filter = NULL; #endif -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) seqChannel->volume = 1.0f; seqChannel->volumeScale = 1.0f; seqChannel->freqScale = 1.0f; @@ -98,7 +98,7 @@ s32 seq_channel_set_layer(struct SequenceChannel *seqChannel, s32 layerIndex) { struct SequenceChannelLayer *layer; if (seqChannel->layers[layerIndex] == NULL) { -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) struct SequenceChannelLayer *layer; #endif layer = audio_list_pop_back(&gLayerFreeList); @@ -119,17 +119,17 @@ s32 seq_channel_set_layer(struct SequenceChannel *seqChannel, s32 layerIndex) { layer->stopSomething = FALSE; layer->continuousNotes = FALSE; layer->finished = FALSE; -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) layer->ignoreDrumPan = FALSE; #endif -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) layer->reverbBits.asByte = 0x40; #endif layer->portamento.mode = 0; layer->scriptState.depth = 0; layer->status = SOUND_LOAD_STATUS_NOT_LOADED; layer->noteDuration = 0x80; -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) layer->pan = 0x40; #endif layer->transposition = 0; @@ -138,10 +138,10 @@ s32 seq_channel_set_layer(struct SequenceChannel *seqChannel, s32 layerIndex) { layer->delayUnused = 0; layer->note = NULL; layer->instrument = NULL; -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) layer->freqScale = 1.0f; layer->velocitySquare = 0.0f; -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) layer->freqScaleMultiplier = 1.0f; #endif layer->instOrWave = 0xff; @@ -164,7 +164,7 @@ void seq_channel_layer_free(struct SequenceChannel *seqChannel, s32 layerIndex) struct SequenceChannelLayer *layer = seqChannel->layers[layerIndex]; if (layer != NULL) { -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) audio_list_push_back(&gLayerFreeList, &layer->listItem); #else struct AudioListItem *item = &layer->listItem; @@ -197,7 +197,7 @@ struct SequenceChannel *allocate_sequence_channel(void) { s32 i; for (i = 0; i < ARRAY_COUNT(gSequenceChannels); i++) { if (gSequenceChannels[i].seqPlayer == NULL) { -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) return &gSequenceChannels[i]; #else return gSequenceChannels + i; @@ -232,7 +232,7 @@ void sequence_player_init_channels(struct SequencePlayer *seqPlayer, u16 channel seqChannel->noteAllocPolicy = seqPlayer->noteAllocPolicy; } } -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) channelBits = channelBits >> 1; #else channelBits >>= 1; @@ -253,7 +253,7 @@ void sequence_player_disable_channels(struct SequencePlayer *seqPlayer, u16 chan sequence_channel_disable(seqChannel); seqChannel->seqPlayer = NULL; } -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) else { #ifdef VERSION_EU stubbed_printf("Audio:Track: Warning SUBTRACK PARENT CHANGED\n"); @@ -263,7 +263,7 @@ void sequence_player_disable_channels(struct SequencePlayer *seqPlayer, u16 chan seqPlayer->channels[i] = &gSequenceChannelNone; } } -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) channelBits = channelBits >> 1; #else channelBits >>= 1; @@ -310,7 +310,7 @@ void sequence_player_disable(struct SequencePlayer *seqPlayer) { seqPlayer->enabled = FALSE; if (IS_SEQ_LOAD_COMPLETE(seqPlayer->seqId) -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) && gSeqLoadStatus[seqPlayer->seqId] != 5 #endif ) { @@ -318,11 +318,11 @@ void sequence_player_disable(struct SequencePlayer *seqPlayer) { } if (IS_BANK_LOAD_COMPLETE(seqPlayer->defaultBank[0]) -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) && gBankLoadStatus[seqPlayer->defaultBank[0]] != 5 #endif ) { -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) gBankLoadStatus[seqPlayer->defaultBank[0]] = 4; #else gBankLoadStatus[seqPlayer->defaultBank[0]] = SOUND_LOAD_STATUS_DISCARDABLE; @@ -332,7 +332,7 @@ void sequence_player_disable(struct SequencePlayer *seqPlayer) { // (Note that if this is called from alloc_bank_or_seq, the side will get swapped // later in that function. Thus, we signal that we want to load into the slot // of the bank that we no longer need.) -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) if (seqPlayer->defaultBank[0] == gBankLoadedPool.temporary.entries[0].id) { gBankLoadedPool.temporary.nextSide = 1; } else if (seqPlayer->defaultBank[0] == gBankLoadedPool.temporary.entries[1].id) { @@ -387,7 +387,7 @@ void init_layer_freelist(void) { gLayerFreeList.pool = NULL; for (i = 0; i < ARRAY_COUNT(gSequenceLayers); i++) { -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) gSequenceLayers[i].listItem.u.value = &gSequenceLayers[i]; #else gSequenceLayers[i].listItem.u.value = gSequenceLayers + i; @@ -398,7 +398,7 @@ void init_layer_freelist(void) { } u8 m64_read_u8(struct M64ScriptState *state) { -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) return *(state->pc++); #else u8 *midiArg = state->pc++; @@ -421,7 +421,7 @@ u16 m64_read_compressed_u16(struct M64ScriptState *state) { return ret; } -#if defined(VERSION_SH) +#if defined(VERSION_SH) || defined(VERSION_CN) void seq_channel_layer_process_script(struct SequenceChannelLayer *layer) { s32 cmd; @@ -517,7 +517,7 @@ void seq_channel_layer_process_script(struct SequenceChannelLayer *layer) { seqChannel = layer->seqChannel; seqPlayer = seqChannel->seqPlayer; -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) layer->notePropertiesNeedInit = TRUE; #endif @@ -570,7 +570,7 @@ void seq_channel_layer_process_script(struct SequenceChannelLayer *layer) { state->pc = seqPlayer->seqData + sp3A; break; -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) case 0xf4: state->pc += (s8)m64_read_u8(state); break; @@ -582,7 +582,7 @@ void seq_channel_layer_process_script(struct SequenceChannelLayer *layer) { if (cmd == 0xc1) { layer->velocitySquare = (f32)(temp_a0_5 * temp_a0_5); } else { -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) layer->pan = temp_a0_5; #else layer->pan = (f32) temp_a0_5 / US_FLOAT(128.0); @@ -673,7 +673,7 @@ void seq_channel_layer_process_script(struct SequenceChannelLayer *layer) { layer->portamento.mode = 0; break; -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) case 0xcb: sp3A = m64_read_s16(state); layer->adsr.envelope = (struct AdsrEnvelope *) (seqPlayer->seqData + sp3A); @@ -732,7 +732,7 @@ void seq_channel_layer_process_script(struct SequenceChannelLayer *layer) { // the remaining bits are used for the semitone cmd -= (cmd & 0xc0); -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) layer->velocitySquare = (f32)(vel) * (f32)vel; #else layer->velocitySquare = vel * vel; @@ -758,7 +758,7 @@ void seq_channel_layer_process_script(struct SequenceChannelLayer *layer) { } layer->delay = sp3A; -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) layer->duration = layer->noteDuration * sp3A >> 8; #else layer->duration = layer->noteDuration * sp3A / 256; @@ -771,9 +771,11 @@ void seq_channel_layer_process_script(struct SequenceChannelLayer *layer) { ) { layer->stopSomething = TRUE; } else { -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) s32 temp = layer->instOrWave; - if (temp == 0xff) temp = seqChannel->instOrWave; + if (temp == 0xff) { + temp = seqChannel->instOrWave; + } if (temp == 0) #else if (seqChannel->instOrWave == 0) @@ -803,7 +805,7 @@ void seq_channel_layer_process_script(struct SequenceChannelLayer *layer) { } else { layer->adsr.envelope = drum->envelope; layer->adsr.releaseRate = drum->releaseRate; -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) if (!layer->ignoreDrumPan) { layer->pan = drum->pan; } @@ -823,7 +825,7 @@ void seq_channel_layer_process_script(struct SequenceChannelLayer *layer) { if (cmd >= 0x80) { layer->stopSomething = TRUE; } else { -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) if (layer->instOrWave == 0xffu) { instrument = seqChannel->instrument; } else { @@ -875,7 +877,7 @@ void seq_channel_layer_process_script(struct SequenceChannelLayer *layer) { case PORTAMENTO_MODE_2: case PORTAMENTO_MODE_4: -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) default: #endif freqScale = temp_f2; @@ -885,7 +887,7 @@ void seq_channel_layer_process_script(struct SequenceChannelLayer *layer) { break; } -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) portamento->extent = temp_f2 / freqScale - 1.0f; #else portamento->extent = sp24 / freqScale - US_FLOAT(1.0); @@ -940,7 +942,7 @@ void seq_channel_layer_process_script(struct SequenceChannelLayer *layer) { seq_channel_layer_note_decay(layer); cmd = TRUE; } -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) else if (layer != layer->note->parentLayer) { cmd = TRUE; } @@ -956,7 +958,7 @@ void seq_channel_layer_process_script(struct SequenceChannelLayer *layer) { if (layer->note != NULL && layer->note->parentLayer == layer) { note_vibrato_init(layer->note); } -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) if (seqChannel) { } #endif @@ -972,7 +974,7 @@ u8 audioString107[] = "Error: Your assignchannel is stolen.\n"; #include "copt/seq_channel_layer_process_script_copt.inc.c" #endif -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) void seq_channel_layer_process_script_part1(struct SequenceChannelLayer *layer) { if (!layer->continuousNotes) { seq_channel_layer_note_decay(layer); @@ -1401,7 +1403,7 @@ s32 seq_channel_layer_process_script_part3(struct SequenceChannelLayer *layer, s u8 get_instrument(struct SequenceChannel *seqChannel, u8 instId, struct Instrument **instOut, struct AdsrSettings *adsr) { struct Instrument *inst; -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) inst = get_instrument_inner(seqChannel->bankId, instId); if (inst == NULL) { *instOut = NULL; @@ -1463,7 +1465,7 @@ void set_instrument(struct SequenceChannel *seqChannel, u8 instId) { seqChannel->instOrWave = 0; seqChannel->instrument = (struct Instrument *) 1; } else { -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) if ((seqChannel->instOrWave = get_instrument(seqChannel, instId, &seqChannel->instrument, &seqChannel->adsr)) == 0) #else @@ -1521,7 +1523,7 @@ void sequence_channel_process_script(struct SequenceChannel *seqChannel) { if (seqChannel->delay == 0) { for (;;) { cmd = m64_read_u8(state); -#if !defined(VERSION_EU) && !defined(VERSION_SH) +#if defined(VERSION_JP) || defined(VERSION_US) if (cmd == 0xff) { // chan_end if (state->depth == 0) { sequence_channel_disable(seqChannel); @@ -1542,7 +1544,7 @@ void sequence_channel_process_script(struct SequenceChannel *seqChannel) { } #endif -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) if (cmd >= 0xb0) #else if (cmd > 0xc0) @@ -1550,7 +1552,7 @@ void sequence_channel_process_script(struct SequenceChannel *seqChannel) { { switch (cmd) { case 0xff: // chan_end -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) if (state->depth == 0) { sequence_channel_disable(seqChannel); goto out; @@ -1560,7 +1562,7 @@ void sequence_channel_process_script(struct SequenceChannel *seqChannel) { #endif break; -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) case 0xfe: // chan_delay1 goto out; @@ -1577,7 +1579,7 @@ void sequence_channel_process_script(struct SequenceChannel *seqChannel) { eu_stubbed_printf_0("Audio:Track :Call Macro Level Over Error!\n"); } sp5A = m64_read_s16(state); -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) state->stack[state->depth++] = state->pc; #else state->depth++, state->stack[state->depth - 1] = state->pc; @@ -1590,7 +1592,7 @@ void sequence_channel_process_script(struct SequenceChannel *seqChannel) { eu_stubbed_printf_0("Audio:Track :Loops Macro Level Over Error!\n"); } state->remLoopIters[state->depth] = m64_read_u8(state); -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) state->stack[state->depth++] = state->pc; #else state->depth++, state->stack[state->depth - 1] = state->pc; @@ -1615,29 +1617,34 @@ void sequence_channel_process_script(struct SequenceChannel *seqChannel) { case 0xf9: // chan_bltz case 0xf5: // chan_bgez sp5A = m64_read_s16(state); - if (cmd == 0xfa && value != 0) + if (cmd == 0xfa && value != 0) { break; - if (cmd == 0xf9 && value >= 0) + } + if (cmd == 0xf9 && value >= 0) { break; - if (cmd == 0xf5 && value < 0) + } + if (cmd == 0xf5 && value < 0) { break; + } state->pc = seqPlayer->seqData + sp5A; break; -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) case 0xf4: // chan_jump_rel case 0xf3: // chan_beqz_rel case 0xf2: // chan_bltz_rel temp = m64_read_u8(state); - if (cmd == 0xf3 && value != 0) + if (cmd == 0xf3 && value != 0) { break; - if (cmd == 0xf2 && value >= 0) + } + if (cmd == 0xf2 && value >= 0) { break; + } state->pc += temp; break; #endif -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) case 0xf1: // chan_reservenotes #else case 0xf2: // chan_reservenotes @@ -1646,7 +1653,7 @@ void sequence_channel_process_script(struct SequenceChannel *seqChannel) { note_pool_fill(&seqChannel->notePool, m64_read_u8(state)); break; -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) case 0xf0: // chan_unreservenotes #else case 0xf1: // chan_unreservenotes @@ -1661,7 +1668,7 @@ void sequence_channel_process_script(struct SequenceChannel *seqChannel) { case 0xc5: // chan_dynsetdyntable if (value != -1) { -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) seqData = (*seqChannel->dynTable)[value]; sp38 = (u16)((seqData[0] << 8) + seqData[1]); seqChannel->dynTable = (void *) (seqPlayer->seqData + sp38); @@ -1672,7 +1679,7 @@ void sequence_channel_process_script(struct SequenceChannel *seqChannel) { } break; -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) case 0xeb: // chan_setbankandinstr cmd = m64_read_u8(state); // Switch to the cmd's (0-indexed) bank in this sequence's @@ -1683,7 +1690,7 @@ void sequence_channel_process_script(struct SequenceChannel *seqChannel) { loBits = *(sp38 + gAlBankSets); cmd = gAlBankSets[(s32)sp38 + loBits - cmd]; -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) if (get_bank_or_seq(1, 2, cmd) != NULL) #else if (get_bank_or_seq(&gBankLoadedPool, 2, cmd) != NULL) @@ -1710,14 +1717,14 @@ void sequence_channel_process_script(struct SequenceChannel *seqChannel) { case 0xdf: // chan_setvol sequence_channel_set_volume(seqChannel, m64_read_u8(state)); -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) seqChannel->changes.as_bitfields.volume = TRUE; #endif break; case 0xe0: // chan_setvolscale seqChannel->volumeScale = FLOAT_CAST(m64_read_u8(state)) / US_FLOAT(128.0); -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) seqChannel->changes.as_bitfields.volume = TRUE; #endif break; @@ -1725,25 +1732,25 @@ void sequence_channel_process_script(struct SequenceChannel *seqChannel) { case 0xde: // chan_freqscale; pitch bend using raw frequency multiplier N/2^15 (N is u16) sp5A = m64_read_s16(state); seqChannel->freqScale = FLOAT_CAST(sp5A) / US_FLOAT(32768.0); -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) seqChannel->changes.as_bitfields.freqScale = TRUE; #endif break; case 0xd3: // chan_pitchbend; pitch bend by <= 1 octave in either direction (-127..127) // (m64_read_u8(state) is really s8 here) -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) cmd = m64_read_u8(state) + 128; #else cmd = m64_read_u8(state) + 127; #endif seqChannel->freqScale = gPitchBendFrequencyScale[cmd]; -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) seqChannel->changes.as_bitfields.freqScale = TRUE; #endif break; -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) case 0xee: cmd = m64_read_u8(state) + 0x80; seqChannel->freqScale = unk_sh_data_1[cmd]; @@ -1752,7 +1759,7 @@ void sequence_channel_process_script(struct SequenceChannel *seqChannel) { #endif case 0xdd: // chan_setpan -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) seqChannel->newPan = m64_read_u8(state); seqChannel->changes.as_bitfields.pan = TRUE; #else @@ -1761,7 +1768,7 @@ void sequence_channel_process_script(struct SequenceChannel *seqChannel) { break; case 0xdc: // chan_setpanmix; set proportion of pan to come from channel (0..128) -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) seqChannel->panChannelWeight = m64_read_u8(state); seqChannel->changes.as_bitfields.pan = TRUE; #else @@ -1831,7 +1838,7 @@ void sequence_channel_process_script(struct SequenceChannel *seqChannel) { // bank set. Note that in the binary format (not in the JSON!) // the banks are listed backwards, so we counts from the back. // (gAlBankSets[offset] is number of banks) -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) sp38 = ((u16 *) gAlBankSets)[seqPlayer->seqId]; loBits = *(sp38 + gAlBankSets); cmd = gAlBankSets[(s32)sp38 + loBits - cmd]; @@ -1840,7 +1847,7 @@ void sequence_channel_process_script(struct SequenceChannel *seqChannel) { loBits = *(sp5A + gAlBankSets); cmd = gAlBankSets[sp5A + loBits - cmd]; #endif -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) if (get_bank_or_seq(1, 2, cmd) != NULL) #else if (get_bank_or_seq(&gBankLoadedPool, 2, cmd) != NULL) @@ -1854,7 +1861,7 @@ void sequence_channel_process_script(struct SequenceChannel *seqChannel) { case 0xc7: // chan_writeseq; write to sequence data (!) { -#if !defined(VERSION_EU) && !defined(VERSION_SH) +#if defined(VERSION_JP) || defined(VERSION_US) u8 *seqData; #endif cmd = m64_read_u8(state); @@ -1877,7 +1884,7 @@ void sequence_channel_process_script(struct SequenceChannel *seqChannel) { } break; -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) case 0xcd: sequence_channel_disable(seqPlayer->channels[m64_read_u8(state)]); break; @@ -1885,7 +1892,7 @@ void sequence_channel_process_script(struct SequenceChannel *seqChannel) { case 0xca: // chan_setmutebhv seqChannel->muteBehavior = m64_read_u8(state); -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) seqChannel->changes.as_bitfields.volume = TRUE; #endif break; @@ -1895,7 +1902,7 @@ void sequence_channel_process_script(struct SequenceChannel *seqChannel) { value = seqPlayer->seqData[sp38]; break; -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) case 0xce: seqChannel->unkC8 = m64_read_s16(state); break; @@ -1917,26 +1924,26 @@ void sequence_channel_process_script(struct SequenceChannel *seqChannel) { break; case 0xd2: // chan_setsustain -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) seqChannel->adsr.sustain = m64_read_u8(state); #else seqChannel->adsr.sustain = m64_read_u8(state) << 8; #endif break; -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) case 0xe5: seqChannel->reverbIndex = m64_read_u8(state); break; #endif case 0xe4: // chan_dyncall if (value != -1) { -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) if (state->depth >= 4) { eu_stubbed_printf_0("Audio:Track: CTBLCALL Macro Level Over Error!\n"); } #endif seqData = (*seqChannel->dynTable)[value]; -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) state->stack[state->depth++] = state->pc; sp38 = (u16)((seqData[0] << 8) + seqData[1]); state->pc = seqPlayer->seqData + sp38; @@ -1952,7 +1959,7 @@ void sequence_channel_process_script(struct SequenceChannel *seqChannel) { } break; -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) case 0xe6: seqChannel->bookOffset = m64_read_u8(state); break; @@ -1994,7 +2001,7 @@ void sequence_channel_process_script(struct SequenceChannel *seqChannel) { break; case 0xe9: // chan_setnotepriority -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) cmd = m64_read_u8(state); if ((cmd & 0xf) != 0) { seqChannel->notePriority = cmd & 0xf; @@ -2008,7 +2015,7 @@ void sequence_channel_process_script(struct SequenceChannel *seqChannel) { #endif break; #endif -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) case 0xed: seqChannel->synthesisVolume = m64_read_u8(state); break; @@ -2062,7 +2069,7 @@ void sequence_channel_process_script(struct SequenceChannel *seqChannel) { #endif } } else { -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) if (cmd >= 0x80) { loBits = cmd & 7; switch (cmd & 0xf8) { @@ -2099,7 +2106,7 @@ void sequence_channel_process_script(struct SequenceChannel *seqChannel) { loBits = cmd & 0xf; switch (cmd & 0xf0) { -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) case 0x00: seqChannel->delay = loBits; goto out; @@ -2127,7 +2134,7 @@ void sequence_channel_process_script(struct SequenceChannel *seqChannel) { seqChannel->soundScriptIO[loBits] = value; break; -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) case 0x60: #else case 0x80: // chan_ioreadval; read data from audio lib @@ -2143,7 +2150,7 @@ void sequence_channel_process_script(struct SequenceChannel *seqChannel) { value -= seqChannel->soundScriptIO[loBits]; break; -#ifndef VERSION_SH +#if !defined(VERSION_SH) && !defined(VERSION_CN) #ifdef VERSION_EU // sh: 0x00 case 0x60: // chan_delayshort @@ -2180,7 +2187,7 @@ void sequence_channel_process_script(struct SequenceChannel *seqChannel) { #endif #endif -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) case 0x20: #else case 0x10: // chan_startchannel @@ -2189,7 +2196,7 @@ void sequence_channel_process_script(struct SequenceChannel *seqChannel) { sequence_channel_enable(seqPlayer, loBits, seqPlayer->seqData + sp5A); break; -#ifndef VERSION_SH +#if !defined(VERSION_SH) && !defined(VERSION_CN) case 0x20: // chan_disablechannel sequence_channel_disable(seqPlayer->channels[loBits]); break; @@ -2205,13 +2212,13 @@ void sequence_channel_process_script(struct SequenceChannel *seqChannel) { value = seqPlayer->channels[loBits]->soundScriptIO[cmd]; break; } -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) } #endif } } } -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) out: #endif @@ -2224,7 +2231,7 @@ void sequence_channel_process_script(struct SequenceChannel *seqChannel) { void sequence_player_process_sequence(struct SequencePlayer *seqPlayer) { u8 cmd; -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) UNUSED u32 pad; #endif u8 loBits; @@ -2234,7 +2241,7 @@ void sequence_player_process_sequence(struct SequencePlayer *seqPlayer) { u16 u16v; u8 *seqData; struct M64ScriptState *state; -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) s32 temp32; #endif @@ -2242,7 +2249,7 @@ void sequence_player_process_sequence(struct SequencePlayer *seqPlayer) { return; } -#ifndef VERSION_SH +#if !defined(VERSION_SH) && !defined(VERSION_CN) if (seqPlayer->bankDmaInProgress == TRUE) { #ifdef VERSION_EU if (osRecvMesg(&seqPlayer->bankDmaMesgQueue, NULL, 0) == -1) { @@ -2309,7 +2316,7 @@ void sequence_player_process_sequence(struct SequencePlayer *seqPlayer) { // If discarded, bail out. if (IS_SEQ_LOAD_COMPLETE(seqPlayer->seqId) == FALSE || ( -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) seqPlayer->defaultBank[0] != 0xff && #endif IS_BANK_LOAD_COMPLETE(seqPlayer->defaultBank[0]) == FALSE)) { @@ -2319,12 +2326,12 @@ void sequence_player_process_sequence(struct SequencePlayer *seqPlayer) { } // Remove possible SOUND_LOAD_STATUS_DISCARDABLE marks. -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) if (gSeqLoadStatus[seqPlayer->seqId] != 5) #endif gSeqLoadStatus[seqPlayer->seqId] = SOUND_LOAD_STATUS_COMPLETE; -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) if (gBankLoadStatus[seqPlayer->defaultBank[0]] != 5) #endif gBankLoadStatus[seqPlayer->defaultBank[0]] = SOUND_LOAD_STATUS_COMPLETE; @@ -2335,7 +2342,7 @@ void sequence_player_process_sequence(struct SequencePlayer *seqPlayer) { // Check if we surpass the number of ticks needed for a tatum, else stop. seqPlayer->tempoAcc += seqPlayer->tempo; -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) seqPlayer->tempoAcc += seqPlayer->tempoAdd; #endif if (seqPlayer->tempoAcc < gTempoInternalToExternal) { @@ -2351,7 +2358,7 @@ void sequence_player_process_sequence(struct SequencePlayer *seqPlayer) { #endif seqPlayer->delay--; } else { -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) seqPlayer->recalculateVolume = 1; #endif for (;;) { @@ -2361,7 +2368,7 @@ void sequence_player_process_sequence(struct SequencePlayer *seqPlayer) { sequence_player_disable(seqPlayer); break; } -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) state->pc = state->stack[--state->depth]; #else state->depth--, state->pc = state->stack[state->depth]; @@ -2388,7 +2395,7 @@ void sequence_player_process_sequence(struct SequencePlayer *seqPlayer) { if (0 && state->depth >= 4) { eu_stubbed_printf_0("Macro Level Over Error!\n"); } -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) state->stack[state->depth++] = state->pc; #else state->depth++, state->stack[state->depth - 1] = state->pc; @@ -2401,7 +2408,7 @@ void sequence_player_process_sequence(struct SequencePlayer *seqPlayer) { eu_stubbed_printf_0("Macro Level Over Error!\n"); } state->remLoopIters[state->depth] = m64_read_u8(state); -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) state->stack[state->depth++] = state->pc; #else state->depth++, state->stack[state->depth - 1] = state->pc; @@ -2434,7 +2441,7 @@ void sequence_player_process_sequence(struct SequencePlayer *seqPlayer) { state->pc = seqPlayer->seqData + u16v; break; -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) case 0xf4: case 0xf3: case 0xf2: @@ -2449,7 +2456,7 @@ void sequence_player_process_sequence(struct SequencePlayer *seqPlayer) { break; #endif -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) case 0xf1: // seq_reservenotes #else case 0xf2: // seq_reservenotes @@ -2458,7 +2465,7 @@ void sequence_player_process_sequence(struct SequencePlayer *seqPlayer) { note_pool_fill(&seqPlayer->notePool, m64_read_u8(state)); break; -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) case 0xf0: // seq_unreservenotes #else case 0xf1: // seq_unreservenotes @@ -2475,10 +2482,10 @@ void sequence_player_process_sequence(struct SequencePlayer *seqPlayer) { break; case 0xdd: // seq_settempo (bpm) -#ifndef VERSION_SH +#if !defined(VERSION_SH) && !defined(VERSION_CN) case 0xdc: // seq_addtempo (bpm) #endif -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) seqPlayer->tempo = m64_read_u8(state) * TEMPO_SCALE; #else temp = m64_read_u8(state); @@ -2500,13 +2507,13 @@ void sequence_player_process_sequence(struct SequencePlayer *seqPlayer) { } break; -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) case 0xdc: // seq_addtempo (bpm) seqPlayer->tempoAdd = (s8) m64_read_u8(state) * TEMPO_SCALE; break; #endif -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) case 0xda: cmd = m64_read_u8(state); u16v = m64_read_s16(state); @@ -2574,7 +2581,7 @@ void sequence_player_process_sequence(struct SequencePlayer *seqPlayer) { break; #endif -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) case 0xd9: temp = m64_read_u8(state); seqPlayer->fadeVolumeScale = (s8) temp / 127.0f; @@ -2624,7 +2631,7 @@ void sequence_player_process_sequence(struct SequencePlayer *seqPlayer) { break; case 0xc9: // seq_bitand -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) value &= m64_read_u8(state); #else value = m64_read_u8(state) & value; @@ -2635,7 +2642,7 @@ void sequence_player_process_sequence(struct SequencePlayer *seqPlayer) { value = value - m64_read_u8(state); break; -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) case 0xc7: cmd = m64_read_u8(state); u16v = m64_read_s16(state); @@ -2656,7 +2663,7 @@ void sequence_player_process_sequence(struct SequencePlayer *seqPlayer) { loBits = cmd & 0xf; switch (cmd & 0xf0) { case 0x00: // seq_testchdisabled -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) value = seqPlayer->channels[loBits]->finished; #else if (IS_SEQUENCE_CHANNEL_VALID(seqPlayer->channels[loBits]) == TRUE) { @@ -2671,7 +2678,7 @@ void sequence_player_process_sequence(struct SequencePlayer *seqPlayer) { case 0x40: break; case 0x50: // seq_subvariation -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) value -= seqPlayer->seqVariationEu[0]; #else value -= seqPlayer->seqVariation; @@ -2680,14 +2687,14 @@ void sequence_player_process_sequence(struct SequencePlayer *seqPlayer) { case 0x60: break; case 0x70: // seq_setvariation -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) seqPlayer->seqVariationEu[0] = value; #else seqPlayer->seqVariation = value; #endif break; case 0x80: // seq_getvariation -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) value = seqPlayer->seqVariationEu[0]; #else value = seqPlayer->seqVariation; @@ -2699,7 +2706,7 @@ void sequence_player_process_sequence(struct SequencePlayer *seqPlayer) { break; case 0xa0: break; -#if !defined(VERSION_EU) && !defined(VERSION_SH) +#if defined(VERSION_JP) || defined(VERSION_US) case 0xd8: // (this makes no sense) break; case 0xd9: @@ -2715,7 +2722,7 @@ void sequence_player_process_sequence(struct SequencePlayer *seqPlayer) { } for (i = 0; i < CHANNELS_MAX; i++) { -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) if (IS_SEQUENCE_CHANNEL_VALID(seqPlayer->channels[i]) == TRUE) { sequence_channel_process_script(seqPlayer->channels[i]); } @@ -2732,7 +2739,7 @@ void process_sequences(UNUSED s32 iterationsRemaining) { s32 i; for (i = 0; i < SEQUENCE_PLAYERS; i++) { if (gSequencePlayers[i].enabled == TRUE) { -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) sequence_player_process_sequence(&gSequencePlayers[i]); sequence_player_process_sound(&gSequencePlayers[i]); #else @@ -2749,38 +2756,38 @@ void process_sequences(UNUSED s32 iterationsRemaining) { void init_sequence_player(u32 player) { struct SequencePlayer *seqPlayer = &gSequencePlayers[player]; -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) sequence_player_disable(seqPlayer); #endif -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) seqPlayer->unkSh = FALSE; #else seqPlayer->muted = FALSE; #endif seqPlayer->delay = 0; -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) seqPlayer->state = 1; #else seqPlayer->state = SEQUENCE_PLAYER_STATE_0; #endif seqPlayer->fadeRemainingFrames = 0; -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) seqPlayer->fadeTimerUnkEu = 0; #endif seqPlayer->tempoAcc = 0; seqPlayer->tempo = 120 * TEMPO_SCALE; // 120 BPM -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) seqPlayer->tempoAdd = 0; #endif seqPlayer->transposition = 0; -#ifndef VERSION_SH +#if !defined(VERSION_SH) && !defined(VERSION_CN) seqPlayer->muteBehavior = MUTE_BEHAVIOR_STOP_SCRIPT | MUTE_BEHAVIOR_STOP_NOTES | MUTE_BEHAVIOR_SOFTEN; #endif seqPlayer->noteAllocPolicy = 0; seqPlayer->shortNoteVelocityTable = gDefaultShortNoteVelocityTable; seqPlayer->shortNoteDurationTable = gDefaultShortNoteDurationTable; seqPlayer->fadeVolume = 1.0f; -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) seqPlayer->fadeVolumeScale = 1.0f; #endif seqPlayer->fadeVelocity = 0.0f; @@ -2825,12 +2832,12 @@ void init_sequence_players(void) { gSequencePlayers[i].channels[j] = &gSequenceChannelNone; } -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) gSequencePlayers[i].seqVariationEu[0] = -1; #else gSequencePlayers[i].seqVariation = -1; #endif -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) gSequencePlayers[i].muteBehavior = MUTE_BEHAVIOR_STOP_SCRIPT | MUTE_BEHAVIOR_STOP_NOTES | MUTE_BEHAVIOR_SOFTEN; gSequencePlayers[i].enabled = FALSE; gSequencePlayers[i].muted = FALSE; diff --git a/src/audio/shindou_debug_prints.c b/src/audio/shindou_debug_prints.c index 261d4521..3088d429 100644 --- a/src/audio/shindou_debug_prints.c +++ b/src/audio/shindou_debug_prints.c @@ -1,6 +1,6 @@ #include -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) // synthesis.c char shindouDebugPrint1[] = "Terminate-Canceled Channel %d,Phase %d\n"; char shindouDebugPrint2[] = "S->W\n"; diff --git a/src/audio/synthesis.c b/src/audio/synthesis.c index 224a0007..5bc8c784 100644 --- a/src/audio/synthesis.c +++ b/src/audio/synthesis.c @@ -1,4 +1,4 @@ -#ifndef VERSION_SH +#if !defined(VERSION_SH) && !defined(VERSION_CN) #include #include "synthesis.h" diff --git a/src/audio/synthesis.h b/src/audio/synthesis.h index b6465ac2..1f1fb9b0 100644 --- a/src/audio/synthesis.h +++ b/src/audio/synthesis.h @@ -3,7 +3,7 @@ #include "internal.h" -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) #define DEFAULT_LEN_1CH 0x180 #define DEFAULT_LEN_2CH 0x300 #else @@ -11,7 +11,7 @@ #define DEFAULT_LEN_2CH 0x280 #endif -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) #define MAX_UPDATES_PER_FRAME 5 #else #define MAX_UPDATES_PER_FRAME 4 @@ -32,19 +32,19 @@ struct SynthesisReverb { /*0x01, 0x01, 0x01*/ u8 useReverb; /*0x02, 0x02, 0x02*/ u8 framesLeftToIgnore; /*0x03, 0x03, 0x03*/ u8 curFrame; -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) /* 0x04, 0x04*/ u8 downsampleRate; -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) /* 0x05*/ s8 unk5; #endif /* 0x06, 0x06*/ u16 windowSize; // same as bufSizePerChannel #endif -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) /* 0x08*/ u16 unk08; #endif /*0x04, 0x08, 0x0A*/ u16 reverbGain; /*0x06, 0x0A, 0x0C*/ u16 resampleRate; -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) /* 0x0E*/ u16 panRight; /* 0x10*/ u16 panLeft; #endif @@ -60,7 +60,7 @@ struct SynthesisReverb { /*0x24, 0x28, 0x30*/ s16 *unk24; // never read /*0x28, 0x2C, 0x34*/ s16 *unk28; // never read /*0x2C, 0x30, 0x38*/ struct ReverbRingBufferItem items[2][MAX_UPDATES_PER_FRAME]; -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) // Only used in sh: /* 0x100*/ s16 *unk100; /* 0x104*/ s16 *unk104; @@ -68,7 +68,7 @@ struct SynthesisReverb { /* 0x10C*/ s16 *unk10C; #endif }; // 0xCC <= size <= 0x100 -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) extern struct SynthesisReverb gSynthesisReverbs[4]; extern s8 gNumSynthesisReverbs; extern struct NoteSubEu *gNoteSubsEu; @@ -80,7 +80,7 @@ extern f32 *gCurrentRightVolRamping; // Points to any of the three right buffers extern struct SynthesisReverb gSynthesisReverb; #endif -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) extern s16 D_SH_803479B4; #endif diff --git a/src/audio/synthesis_sh.c b/src/audio/synthesis_sh.c index d27df362..66759cbf 100644 --- a/src/audio/synthesis_sh.c +++ b/src/audio/synthesis_sh.c @@ -1,4 +1,4 @@ -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) #include #include "synthesis.h" diff --git a/src/buffers/buffers.c b/src/buffers/buffers.c index 0a7b6f7f..908e9a3d 100644 --- a/src/buffers/buffers.c +++ b/src/buffers/buffers.c @@ -1,23 +1,47 @@ #include #include "buffers.h" -#include "config.h" ALIGNED8 u8 gDecompressionHeap[0xD000]; + #if defined(VERSION_EU) ALIGNED16 u8 gAudioHeap[DOUBLE_SIZE_ON_64_BIT(0x31200) - 0x3800]; #elif defined(VERSION_SH) ALIGNED16 u8 gAudioHeap[DOUBLE_SIZE_ON_64_BIT(0x31200) - 0x4800]; +#elif defined(VERSION_CN) +ALIGNED16 u8 gAudioHeap[DOUBLE_SIZE_ON_64_BIT(0x31200) - 0x4C00]; #else ALIGNED16 u8 gAudioHeap[DOUBLE_SIZE_ON_64_BIT(0x31200)]; #endif -ALIGNED8 u8 gIdleThreadStack[0x800]; -ALIGNED8 u8 gThread3Stack[0x2000]; -ALIGNED8 u8 gThread4Stack[0x2000]; -ALIGNED8 u8 gThread5Stack[0x2000]; +#ifdef VERSION_CN + +// iQue BSS reordering + +// 0x200 bytes +ALIGNED8 struct SaveBuffer gSaveBuffer; +// 0x190a0 bytes +struct GfxPool gGfxPools[2]; +ALIGNED8 u8 gThread4Stack[STACKSIZE]; #if ENABLE_RUMBLE -ALIGNED8 u8 gThread6Stack[0x2000]; +ALIGNED8 u8 gThread6Stack[STACKSIZE]; +#endif +ALIGNED8 u8 gThread5Stack[STACKSIZE]; +// 0x400 bytes +ALIGNED8 u8 gGfxSPTaskStack[SP_DRAM_STACK_SIZE8]; +// 0xc00 bytes for f3dex, 0x900 otherwise +ALIGNED8 u8 gGfxSPTaskYieldBuffer[OS_YIELD_DATA_SIZE]; +ALIGNED8 u8 gThread3Stack[STACKSIZE + 0x400]; +ALIGNED8 u8 gIdleThreadStack[IDLE_STACKSIZE]; + +#else + +ALIGNED8 u8 gIdleThreadStack[IDLE_STACKSIZE]; +ALIGNED8 u8 gThread3Stack[STACKSIZE]; +ALIGNED8 u8 gThread4Stack[STACKSIZE]; +ALIGNED8 u8 gThread5Stack[STACKSIZE]; +#if ENABLE_RUMBLE +ALIGNED8 u8 gThread6Stack[STACKSIZE]; #endif // 0x400 bytes ALIGNED8 u8 gGfxSPTaskStack[SP_DRAM_STACK_SIZE8]; @@ -28,6 +52,7 @@ ALIGNED8 struct SaveBuffer gSaveBuffer; // 0x190a0 bytes struct GfxPool gGfxPools[2]; +#endif // Yield buffer for audio, 0x400 bytes. Stubbed out post-JP since the audio // task never yields. @@ -38,5 +63,5 @@ ALIGNED8 u8 gAudioSPTaskYieldBuffer[OS_YIELD_AUDIO_SIZE]; // Probably Thread 2 stack space. Unreferenced, and stubbed out with f3dex to // avoid an overflowing .buffers segment. #if !defined(F3DEX_GBI_SHARED) && !defined(VERSION_EU) -ALIGNED8 u8 gUnusedThread2Stack[0x1400]; +ALIGNED8 u8 gUnusedThread2Stack[UNUSED_STACKSIZE]; #endif diff --git a/src/buffers/gfx_output_buffer.c b/src/buffers/gfx_output_buffer.c index d948d420..bfc33c03 100644 --- a/src/buffers/gfx_output_buffer.c +++ b/src/buffers/gfx_output_buffer.c @@ -1,12 +1,4 @@ #include #include "gfx_output_buffer.h" -#ifdef VERSION_EU -// 0x17e00 bytes, aligned to a 0x200-byte boundary through sm64.ld. The alignment -// wastes 0x100 bytes of space. -u64 gGfxSPTaskOutputBuffer[0x2fc0]; -#else -// 0x1f000 bytes, aligned to a 0x1000-byte boundary through sm64.ld. (This results -// in a bunch of unused space: ~0x100 in JP, ~0x300 in US.) -u64 gGfxSPTaskOutputBuffer[0x3e00]; -#endif +u64 gGfxSPTaskOutputBuffer[GFX_OUTPUT_BUFFER_SIZE]; diff --git a/src/buffers/gfx_output_buffer.h b/src/buffers/gfx_output_buffer.h index db693b23..dc16635f 100644 --- a/src/buffers/gfx_output_buffer.h +++ b/src/buffers/gfx_output_buffer.h @@ -4,9 +4,15 @@ #include #ifdef VERSION_EU -extern u64 gGfxSPTaskOutputBuffer[0x2fc0]; +// 0x17e00 bytes, aligned to a 0x200-byte boundary through sm64.ld. The alignment +// wastes 0x100 bytes of space. +#define GFX_OUTPUT_BUFFER_SIZE 0x2fc0 #else -extern u64 gGfxSPTaskOutputBuffer[0x3e00]; +// 0x1f000 bytes, aligned to a 0x1000-byte boundary through sm64.ld. (This results +// in a bunch of unused space: ~0x100 in JP, ~0x300 in US.) +#define GFX_OUTPUT_BUFFER_SIZE 0x3e00 #endif +extern u64 gGfxSPTaskOutputBuffer[GFX_OUTPUT_BUFFER_SIZE]; + #endif // GFX_OUTPUT_BUFFER_H diff --git a/src/buffers/zbuffer.h b/src/buffers/zbuffer.h index bb02f597..079e44e0 100644 --- a/src/buffers/zbuffer.h +++ b/src/buffers/zbuffer.h @@ -7,5 +7,6 @@ #include "macros.h" extern u16 gZBuffer[SCREEN_WIDTH * SCREEN_HEIGHT]; +extern s32 gZBufferEnd; #endif // ZBUFFER_H diff --git a/src/engine/behavior_script.c b/src/engine/behavior_script.c index 64039c94..264ffc26 100644 --- a/src/engine/behavior_script.c +++ b/src/engine/behavior_script.c @@ -188,7 +188,7 @@ static s32 bhv_cmd_spawn_child_with_param(void) { struct Object *child = spawn_object_at_origin(gCurrentObject, 0, modelID, behavior); obj_copy_pos_and_angle(child, gCurrentObject); - child->oBehParams2ndByte = bhvParam; + child->oBhvParams2ndByte = bhvParam; gCurBhvCommand += 3; return BHV_PROC_CONTINUE; diff --git a/src/engine/graph_node.c b/src/engine/graph_node.c index 4b2447e7..66b49b22 100644 --- a/src/engine/graph_node.c +++ b/src/engine/graph_node.c @@ -739,7 +739,7 @@ void geo_obj_init_animation(struct GraphNodeObject *graphNode, struct Animation if (graphNode->animInfo.curAnim != anim) { graphNode->animInfo.curAnim = anim; - graphNode->animInfo.animFrame = anim->startFrame + ((anim->flags & ANIM_FLAG_FORWARD) ? 1 : -1); + graphNode->animInfo.animFrame = anim->startFrame + ((anim->flags & ANIM_FLAG_BACKWARD) ? 1 : -1); graphNode->animInfo.animAccel = 0; graphNode->animInfo.animYTrans = 0; } @@ -756,7 +756,7 @@ void geo_obj_init_animation_accel(struct GraphNodeObject *graphNode, struct Anim graphNode->animInfo.curAnim = anim; graphNode->animInfo.animYTrans = 0; graphNode->animInfo.animFrameAccelAssist = - (anim->startFrame << 16) + ((anim->flags & ANIM_FLAG_FORWARD) ? animAccel : -animAccel); + (anim->startFrame << 16) + ((anim->flags & ANIM_FLAG_BACKWARD) ? animAccel : -animAccel); graphNode->animInfo.animFrame = graphNode->animInfo.animFrameAccelAssist >> 16; } @@ -801,7 +801,7 @@ s16 geo_update_animation_frame(struct AnimInfo *obj, s32 *accelAssist) { return obj->animFrame; } - if (anim->flags & ANIM_FLAG_FORWARD) { + if (anim->flags & ANIM_FLAG_BACKWARD) { if (obj->animAccel != 0) { result = obj->animFrameAccelAssist - obj->animAccel; } else { diff --git a/src/engine/level_script.c b/src/engine/level_script.c index b0463393..0ec43411 100644 --- a/src/engine/level_script.c +++ b/src/engine/level_script.c @@ -290,6 +290,7 @@ static void level_cmd_load_mario_head(void) { gdm_setup(); gdm_maketestdl(CMD_GET(s16, 2)); } else { + CN_DEBUG_PRINTF(("face anime memory overflow\n")); } sCurrentCmd = CMD_NEXT; @@ -682,6 +683,7 @@ static void level_cmd_set_transition(void) { } static void level_cmd_nop(void) { + CN_DEBUG_PRINTF(("BAD: seqBlankColor\n")); sCurrentCmd = CMD_NEXT; } @@ -823,6 +825,9 @@ struct LevelCommand *level_script_execute(struct LevelCommand *cmd) { sCurrentCmd = cmd; while (sScriptStatus == SCRIPT_RUNNING) { + CN_DEBUG_PRINTF(("%08X: ", sCurrentCmd)); + CN_DEBUG_PRINTF(("%02d\n", sCurrentCmd->type)); + LevelScriptJumpTable[sCurrentCmd->type](); } diff --git a/src/engine/stub.c b/src/engine/stub.c new file mode 100644 index 00000000..64350f7a --- /dev/null +++ b/src/engine/stub.c @@ -0,0 +1,4 @@ +#ifdef VERSION_CN +const char D_CN_80388B10[] = "error\n"; +#endif + diff --git a/src/engine/surface_collision.c b/src/engine/surface_collision.c index c59a1436..741307be 100644 --- a/src/engine/surface_collision.c +++ b/src/engine/surface_collision.c @@ -185,8 +185,8 @@ s32 find_wall_collisions(struct WallCollisionData *colData) { struct SurfaceNode *node; s16 cellX, cellZ; s32 numCollisions = 0; - s16 x = colData->x; - s16 z = colData->z; + TerrainData x = colData->x; + TerrainData z = colData->z; colData->numWalls = 0; @@ -315,9 +315,9 @@ f32 find_ceil(f32 posX, f32 posY, f32 posZ, struct Surface **pceil) { //! (Parallel Universes) Because position is casted to an s16, reaching higher // float locations can return ceilings despite them not existing there. // (Dynamic ceilings will unload due to the range.) - s16 x = (s16) posX; - s16 y = (s16) posY; - s16 z = (s16) posZ; + TerrainData x = (TerrainData) posX; + TerrainData y = (TerrainData) posY; + TerrainData z = (TerrainData) posZ; *pceil = NULL; @@ -491,9 +491,9 @@ f32 unused_find_dynamic_floor(f32 xPos, f32 yPos, f32 zPos, struct Surface **pfl f32 floorHeight = FLOOR_LOWER_LIMIT; // Would normally cause PUs, but dynamic floors unload at that range. - s16 x = (s16) xPos; - s16 y = (s16) yPos; - s16 z = (s16) zPos; + TerrainData x = (TerrainData) xPos; + TerrainData y = (TerrainData) yPos; + TerrainData z = (TerrainData) zPos; // Each level is split into cells to limit load, find the appropriate cell. s16 cellX = ((x + LEVEL_BOUNDARY_MAX) / CELL_SIZE) & NUM_CELLS_INDEX; @@ -522,9 +522,9 @@ f32 find_floor(f32 xPos, f32 yPos, f32 zPos, struct Surface **pfloor) { //! (Parallel Universes) Because position is casted to an s16, reaching higher // float locations can return floors despite them not existing there. // (Dynamic floors will unload due to the range.) - s16 x = (s16) xPos; - s16 y = (s16) yPos; - s16 z = (s16) zPos; + TerrainData x = (TerrainData) xPos; + TerrainData y = (TerrainData) yPos; + TerrainData z = (TerrainData) zPos; *pfloor = NULL; @@ -591,10 +591,10 @@ f32 find_floor(f32 xPos, f32 yPos, f32 zPos, struct Surface **pfloor) { f32 find_water_level(f32 x, f32 z) { s32 i; s32 numRegions; - s16 val; + TerrainData val; f32 loX, hiX, loZ, hiZ; f32 waterLevel = FLOOR_LOWER_LIMIT; - s16 *p = gEnvironmentRegions; + TerrainData *p = gEnvironmentRegions; if (p != NULL) { numRegions = *p++; @@ -627,10 +627,10 @@ f32 find_poison_gas_level(f32 x, f32 z) { s32 i; s32 numRegions; UNUSED u8 filler[4]; - s16 val; + TerrainData val; f32 loX, hiX, loZ, hiZ; f32 gasLevel = FLOOR_LOWER_LIMIT; - s16 *p = gEnvironmentRegions; + TerrainData *p = gEnvironmentRegions; if (p != NULL) { numRegions = *p++; diff --git a/src/engine/surface_collision.h b/src/engine/surface_collision.h index f4695081..3f932d67 100644 --- a/src/engine/surface_collision.h +++ b/src/engine/surface_collision.h @@ -13,7 +13,7 @@ #define CELL_HEIGHT_LIMIT 20000 #define FLOOR_LOWER_LIMIT -11000 #define FLOOR_LOWER_LIMIT_MISC (FLOOR_LOWER_LIMIT + 1000) -// same as FLOOR_LOWER_LIMIT_MISC, explicitly for shadow.c +// same as FLOOR_LOWER_LIMIT_MISC, explicitly for shadow.c // It doesn't match if ".0" is removed or ".f" is added #define FLOOR_LOWER_LIMIT_SHADOW (FLOOR_LOWER_LIMIT + 1000.0) diff --git a/src/engine/surface_load.c b/src/engine/surface_load.c index 399423f0..8437bf00 100644 --- a/src/engine/surface_load.c +++ b/src/engine/surface_load.c @@ -44,10 +44,8 @@ static struct SurfaceNode *alloc_surface_node(void) { node->next = NULL; - //! A bounds check! If there's more surface nodes than 7000 allowed, - // we, um... - // Perhaps originally just debug feedback? if (gSurfaceNodesAllocated >= 7000) { + CN_DEBUG_PRINTF((" mcMakeBGCheckList OVERFLOW\n")); } return node; @@ -62,10 +60,8 @@ static struct Surface *alloc_surface(void) { struct Surface *surface = &sSurfacePool[gSurfacesAllocated]; gSurfacesAllocated++; - //! A bounds check! If there's more surfaces than the 2300 allowed, - // we, um... - // Perhaps originally just debug feedback? if (gSurfacesAllocated >= sSurfacePoolSize) { + CN_DEBUG_PRINTF((" mcMakeBGCheckData OVERFLOW\n")); } surface->type = 0; @@ -163,7 +159,7 @@ static void add_surface_to_cell(s16 dynamic, s16 cellX, s16 cellZ, struct Surfac /** * Returns the lowest of three values. */ -static s16 min_3(s16 a0, s16 a1, s16 a2) { +static s16 min_3(TerrainData a0, TerrainData a1, TerrainData a2) { if (a1 < a0) { a0 = a1; } @@ -178,7 +174,7 @@ static s16 min_3(s16 a0, s16 a1, s16 a2) { /** * Returns the highest of three values. */ -static s16 max_3(s16 a0, s16 a1, s16 a2) { +static s16 max_3(TerrainData a0, TerrainData a1, TerrainData a2) { if (a1 > a0) { a0 = a1; } @@ -195,7 +191,7 @@ static s16 max_3(s16 a0, s16 a1, s16 a2) { * time). This function determines the lower cell for a given x/z position. * @param coord The coordinate to test */ -static s16 lower_cell_index(s16 coord) { +static s16 lower_cell_index(TerrainData coord) { s16 index; // Move from range [-0x2000, 0x2000) to [0, 0x4000) @@ -227,7 +223,7 @@ static s16 lower_cell_index(s16 coord) { * time). This function determines the upper cell for a given x/z position. * @param coord The coordinate to test */ -static s16 upper_cell_index(s16 coord) { +static s16 upper_cell_index(TerrainData coord) { s16 index; // Move from range [-0x2000, 0x2000) to [0, 0x4000) @@ -297,7 +293,7 @@ UNUSED static void stub_surface_load_1(void) { * @param vertexData The raw data containing vertex positions * @param vertexIndices Helper which tells positions in vertexData to start reading vertices */ -static struct Surface *read_surface_data(s16 *vertexData, s16 **vertexIndices) { +static struct Surface *read_surface_data(TerrainData *vertexData, TerrainData **vertexIndices) { struct Surface *surface; register s32 x1, y1, z1; register s32 x2, y2, z2; @@ -305,7 +301,7 @@ static struct Surface *read_surface_data(s16 *vertexData, s16 **vertexIndices) { s32 maxY, minY; f32 nx, ny, nz; f32 mag; - s16 offset1, offset2, offset3; + TerrainData offset1, offset2, offset3; offset1 = 3 * (*vertexIndices)[0]; offset2 = 3 * (*vertexIndices)[1]; @@ -385,7 +381,7 @@ static struct Surface *read_surface_data(s16 *vertexData, s16 **vertexIndices) { * Returns whether a surface has exertion/moves Mario * based on the surface type. */ -static s32 surface_has_force(s16 surfaceType) { +static s32 surface_has_force(TerrainData surfaceType) { s32 hasForce = FALSE; switch (surfaceType) { @@ -402,6 +398,7 @@ static s32 surface_has_force(s16 surfaceType) { default: break; } + return hasForce; } @@ -409,7 +406,7 @@ static s32 surface_has_force(s16 surfaceType) { * Returns whether a surface should have the * SURFACE_FLAG_NO_CAM_COLLISION flag. */ -static s32 surf_has_no_cam_collision(s16 surfaceType) { +static s32 surf_has_no_cam_collision(TerrainData surfaceType) { s32 flags = 0; switch (surfaceType) { @@ -431,11 +428,11 @@ static s32 surf_has_no_cam_collision(s16 surfaceType) { * Load in the surfaces for a given surface type. This includes setting the flags, * exertion, and room. */ -static void load_static_surfaces(s16 **data, s16 *vertexData, s16 surfaceType, s8 **surfaceRooms) { +static void load_static_surfaces(TerrainData **data, TerrainData *vertexData, TerrainData surfaceType, RoomData **surfaceRooms) { s32 i; s32 numSurfaces; struct Surface *surface; - s8 room = 0; + RoomData room = 0; s16 hasForce = surface_has_force(surfaceType); s16 flags = surf_has_no_cam_collision(surfaceType); @@ -473,10 +470,10 @@ static void load_static_surfaces(s16 **data, s16 *vertexData, s16 surfaceType, s /** * Read the data for vertices for reference by triangles. */ -static s16 *read_vertex_data(s16 **data) { +static TerrainData *read_vertex_data(TerrainData **data) { s32 numVertices; UNUSED u8 filler[16]; - s16 *vertexData; + TerrainData *vertexData; numVertices = *(*data); (*data)++; @@ -490,7 +487,7 @@ static s16 *read_vertex_data(s16 **data) { /** * Loads in special environmental regions, such as water, poison gas, and JRB fog. */ -static void load_environmental_regions(s16 **data) { +static void load_environmental_regions(TerrainData **data) { s32 numRegions; s32 i; @@ -498,11 +495,12 @@ static void load_environmental_regions(s16 **data) { numRegions = *(*data)++; if (numRegions > 20) { + CN_DEBUG_PRINTF(("Error Water Over\n")); } for (i = 0; i < numRegions; i++) { - UNUSED s16 val, loX, loZ, hiX, hiZ; - s16 height; + UNUSED TerrainData val, loX, loZ, hiX, hiZ; + TerrainData height; val = *(*data)++; @@ -533,14 +531,14 @@ void alloc_surface_pools(void) { /** * Get the size of the terrain data, to get the correct size when copying later. */ -u32 get_area_terrain_size(s16 *data) { - s16 *startPos = data; +u32 get_area_terrain_size(TerrainData *data) { + TerrainData *startPos = data; s32 end = FALSE; - s16 terrainLoadType; + TerrainData terrainLoadType; s32 numVertices; s32 numRegions; s32 numSurfaces; - s16 hasForce; + TerrainData hasForce; while (!end) { terrainLoadType = *data++; @@ -584,9 +582,9 @@ u32 get_area_terrain_size(s16 *data) { * Process the level file, loading in vertices, surfaces, some objects, and environmental * boxes (water, gas, JRB fog). */ -void load_area_terrain(s16 index, s16 *data, s8 *surfaceRooms, s16 *macroObjects) { - s16 terrainLoadType; - s16 *vertexData; +void load_area_terrain(s16 index, TerrainData *data, RoomData *surfaceRooms, s16 *macroObjects) { + TerrainData terrainLoadType; + TerrainData *vertexData; UNUSED u8 filler[4]; // Initialize the data for this. @@ -618,7 +616,8 @@ void load_area_terrain(s16 index, s16 *data, s8 *surfaceRooms, s16 *macroObjects break; } else if (TERRAIN_LOAD_IS_SURFACE_TYPE_HIGH(terrainLoadType)) { load_static_surfaces(&data, vertexData, terrainLoadType, &surfaceRooms); - continue; + } else { + CN_DEBUG_PRINTF((" BGCode Error \n")); } } @@ -656,8 +655,8 @@ UNUSED static void unused_80383604(void) { /** * Applies an object's transformation to the object's vertices. */ -void transform_object_vertices(s16 **data, s16 *vertexData) { - register s16 *vertices; +void transform_object_vertices(TerrainData **data, TerrainData *vertexData) { + register TerrainData *vertices; register f32 vx, vy, vz; register s32 numVertices; @@ -685,9 +684,9 @@ void transform_object_vertices(s16 **data, s16 *vertexData) { vz = *(vertices++); //! No bounds check on vertex data - *vertexData++ = (s16)(vx * m[0][0] + vy * m[1][0] + vz * m[2][0] + m[3][0]); - *vertexData++ = (s16)(vx * m[0][1] + vy * m[1][1] + vz * m[2][1] + m[3][1]); - *vertexData++ = (s16)(vx * m[0][2] + vy * m[1][2] + vz * m[2][2] + m[3][2]); + *vertexData++ = (TerrainData)(vx * m[0][0] + vy * m[1][0] + vz * m[2][0] + m[3][0]); + *vertexData++ = (TerrainData)(vx * m[0][1] + vy * m[1][1] + vz * m[2][1] + m[3][1]); + *vertexData++ = (TerrainData)(vx * m[0][2] + vy * m[1][2] + vz * m[2][2] + m[3][2]); } *data = vertices; @@ -696,12 +695,12 @@ void transform_object_vertices(s16 **data, s16 *vertexData) { /** * Load in the surfaces for the gCurrentObject. This includes setting the flags, exertion, and room. */ -void load_object_surfaces(s16 **data, s16 *vertexData) { +void load_object_surfaces(TerrainData **data, TerrainData *vertexData) { s32 surfaceType; s32 i; s32 numSurfaces; - s16 hasForce; - s16 flags; + TerrainData hasForce; + TerrainData flags; s16 room; surfaceType = *(*data); @@ -717,7 +716,7 @@ void load_object_surfaces(s16 **data, s16 *vertexData) { // The DDD warp is initially loaded at the origin and moved to the proper // position in paintings.c and doesn't update its room, so set it here. - if (gCurrentObject->behavior == segmented_to_virtual(bhvDddWarp)) { + if (gCurrentObject->behavior == segmented_to_virtual(bhvDDDWarp)) { room = 5; } else { room = 0; @@ -754,9 +753,9 @@ void load_object_surfaces(s16 **data, s16 *vertexData) { */ void load_object_collision_model(void) { UNUSED u8 filler[4]; - s16 vertexData[600]; + TerrainData vertexData[600]; - s16 *collisionData = gCurrentObject->collisionData; + TerrainData *collisionData = gCurrentObject->collisionData; f32 marioDist = gCurrentObject->oDistanceToMario; f32 tangibleDist = gCurrentObject->oCollisionDistance; diff --git a/src/engine/surface_load.h b/src/engine/surface_load.h index e00e2bc0..4e04699a 100644 --- a/src/engine/surface_load.h +++ b/src/engine/surface_load.h @@ -33,9 +33,9 @@ extern s16 sSurfacePoolSize; void alloc_surface_pools(void); #ifdef NO_SEGMENTED_MEMORY -u32 get_area_terrain_size(s16 *data); +u32 get_area_terrain_size(TerrainData *data); #endif -void load_area_terrain(s16 index, s16 *data, s8 *surfaceRooms, s16 *macroObjects); +void load_area_terrain(s16 index, TerrainData *data, RoomData *surfaceRooms, s16 *macroObjects); void clear_dynamic_surfaces(void); void load_object_collision_model(void); diff --git a/src/game/area.c b/src/game/area.c index bca1ceaa..0c56be39 100644 --- a/src/game/area.c +++ b/src/game/area.c @@ -106,6 +106,9 @@ void set_warp_transition_rgb(u8 red, u8 green, u8 blue) { } void print_intro_text(void) { +#ifdef VERSION_CN + u8 sp18[] = { 0xB0, 0x00 }; // TODO: iQue colorful text +#endif #ifdef VERSION_EU s32 language = eu_get_language(); #endif @@ -119,8 +122,12 @@ void print_intro_text(void) { } else { #ifdef VERSION_EU print_text(20, 20, "START"); +#else +#ifdef VERSION_CN + print_text_centered(60, 38, (char *) sp18); #else print_text_centered(60, 38, "PRESS"); +#endif print_text_centered(60, 20, "START"); #endif } @@ -132,7 +139,7 @@ u32 get_mario_spawn_type(struct Object *o) { const BehaviorScript *behavior = virtual_to_segmented(0x13, o->behavior); for (i = 0; i < 20; i++) { - if (sWarpBhvSpawnTable[i] == behavior) { + if (behavior == sWarpBhvSpawnTable[i]) { return sSpawnTypeFromWarpBhv[i]; } } @@ -151,9 +158,9 @@ struct ObjectWarpNode *area_get_warp_node(u8 id) { } struct ObjectWarpNode *area_get_warp_node_from_params(struct Object *o) { - u8 sp1F = (o->oBehParams & 0x00FF0000) >> 16; + u8 id = (o->oBhvParams & 0x00FF0000) >> 16; - return area_get_warp_node(sp1F); + return area_get_warp_node(id); } void load_obj_warp_nodes(void) { diff --git a/src/game/area.h b/src/game/area.h index 9141005b..55179662 100644 --- a/src/game/area.h +++ b/src/game/area.h @@ -59,8 +59,8 @@ struct Area { /*0x01*/ s8 flags; // Only has 1 flag: 0x01 = Is this the active area? /*0x02*/ u16 terrainType; // default terrain of the level (set from level script cmd 0x31) /*0x04*/ struct GraphNodeRoot *unk04; // geometry layout data - /*0x08*/ s16 *terrainData; // collision data (set from level script cmd 0x2E) - /*0x0C*/ s8 *surfaceRooms; // (set from level script cmd 0x2F) + /*0x08*/ TerrainData *terrainData; // collision data (set from level script cmd 0x2E) + /*0x0C*/ RoomData *surfaceRooms; // (set from level script cmd 0x2F) /*0x10*/ s16 *macroObjects; // Macro Objects Ptr (set from level script cmd 0x39) /*0x14*/ struct ObjectWarpNode *warpNodes; /*0x18*/ struct WarpNode *paintingWarpNodes; diff --git a/src/game/behavior_actions.c b/src/game/behavior_actions.c index 9800146f..4a29e15e 100644 --- a/src/game/behavior_actions.c +++ b/src/game/behavior_actions.c @@ -80,7 +80,7 @@ static s16 sBooHitRotations[] = { // not in behavior file static struct SpawnParticlesInfo sMistParticles = { - /* behParam: */ 2, + /* bhvParam: */ 2, /* count: */ 20, /* model: */ MODEL_MIST, /* offsetY: */ 0, @@ -144,14 +144,13 @@ void spawn_mist_particles_variable(s32 count, s32 offsetY, f32 size) { // not sure what this is doing here. not in a behavior file. Gfx *geo_move_mario_part_from_parent(s32 run, UNUSED struct GraphNode *node, Mat4 mtx) { - Mat4 sp20; - if (run == TRUE) { - struct Object *sp1C = (struct Object *) gCurGraphNodeObject; - if (sp1C == gMarioObject && sp1C->prevObj != NULL) { + Mat4 sp20; + struct Object *obj = (struct Object *) gCurGraphNodeObject; + if (obj == gMarioObject && obj->prevObj != NULL) { create_transformation_from_matrices(sp20, mtx, *gCurGraphNodeCamera->matrixPtr); - obj_update_pos_from_parent_transformation(sp20, sp1C->prevObj); - obj_set_gfx_pos_from_pos(sp1C->prevObj); + obj_update_pos_from_parent_transformation(sp20, obj->prevObj); + obj_set_gfx_pos_from_pos(obj->prevObj); } } diff --git a/src/game/behavior_actions.h b/src/game/behavior_actions.h index 97939170..eba084e9 100644 --- a/src/game/behavior_actions.h +++ b/src/game/behavior_actions.h @@ -65,8 +65,8 @@ void bhv_warp_loop(void); void bhv_white_puff_exploding_loop(void); void bhv_spawned_star_init(void); void bhv_spawned_star_loop(void); -void bhv_coin_init(void); -void bhv_coin_loop(void); +void bhv_spawned_coin_init(void); +void bhv_spawned_coin_loop(void); void bhv_coin_inside_boo_loop(void); void bhv_coin_formation_init(void); void bhv_coin_formation_spawn_loop(void); @@ -424,8 +424,8 @@ void bhv_treasure_chest_ship_init(void); void bhv_treasure_chest_ship_loop(void); void bhv_treasure_chest_jrb_init(void); void bhv_treasure_chest_jrb_loop(void); -void bhv_treasure_chest_init(void); -void bhv_treasure_chest_loop(void); +void bhv_treasure_chest_ddd_init(void); +void bhv_treasure_chest_ddd_loop(void); void bhv_treasure_chest_bottom_init(void); void bhv_treasure_chest_bottom_loop(void); void bhv_treasure_chest_top_loop(void); diff --git a/src/game/behaviors/activated_bf_plat.inc.c b/src/game/behaviors/activated_bf_plat.inc.c index 8b6399b7..b18f1c46 100644 --- a/src/game/behaviors/activated_bf_plat.inc.c +++ b/src/game/behaviors/activated_bf_plat.inc.c @@ -28,7 +28,7 @@ static Collision const *sActivatedBackAndForthPlatformCollisionModels[] = { */ void bhv_activated_back_and_forth_platform_init(void) { // Equivalent to the first behavior param byte & 3 (last 2 bits of the byte). - s32 platformType = ((u16)(o->oBehParams >> 16) & 0x0300) >> 8; + s32 platformType = ((u16)(o->oBhvParams >> 16) & ACTIVATED_BF_PLAT_BP_MASK_TYPE) >> 8; // The BitS arrow platform should flip 180º (0x8000 angle units), but // there is no reason for the other platforms to flip. @@ -42,18 +42,18 @@ void bhv_activated_back_and_forth_platform_init(void) { segmented_to_virtual(sActivatedBackAndForthPlatformCollisionModels[platformType]); // Max distance the platform should move. - // Equivalent to 50 * (oBehParams2ndByte & 0x7F), i.e. 50 * (oBehParams2ndByte % 128). + // Equivalent to 50 * (oBhvParams2ndByte & 0x7F), i.e. 50 * (oBhvParams2ndByte % 128). // The maximum possible value of this is 50 * 127 = 6350. // It's 50 * 97 = 4850 in BitS and 50 * 31 = 1550 in BitFS. - o->oActivatedBackAndForthPlatformMaxOffset = 50.0f * ((u16)(o->oBehParams >> 16) & 0x007F); + o->oActivatedBackAndForthPlatformMaxOffset = 50.0f * ((u16)(o->oBhvParams >> 16) & 0x007F); if (platformType == ACTIVATED_BF_PLAT_TYPE_BITFS_ELEVATOR) { o->oActivatedBackAndForthPlatformMaxOffset -= 12.0f; } // Truthy/falsy value that determines the direction of movement. - // Equivalent to oBehParams2ndByte & 0x80, i.e. the most significant bit of oBehParams2ndByte. - o->oActivatedBackAndForthPlatformVertical = (u16)(o->oBehParams >> 16) & 0x0080; + // Equivalent to oBhvParams2ndByte & 0x80, i.e. the most significant bit of oBhvParams2ndByte. + o->oActivatedBackAndForthPlatformVertical = (u16)(o->oBhvParams >> 16) & 0x0080; o->oActivatedBackAndForthPlatformStartYaw = o->oFaceAngleYaw; } diff --git a/src/game/behaviors/amp.inc.c b/src/game/behaviors/amp.inc.c index 4fbdadb7..7b5f2f74 100644 --- a/src/game/behaviors/amp.inc.c +++ b/src/game/behaviors/amp.inc.c @@ -243,7 +243,7 @@ void bhv_circling_amp_init(void) { o->oAnimState = 1; // Determine the radius of the circling amp's circle - switch (o->oBehParams2ndByte) { + switch (o->oBhvParams2ndByte) { case AMP_BP_ROT_RADIUS_200: o->oAmpRadiusOfRotation = 200.0f; break; @@ -331,7 +331,7 @@ static void circling_amp_idle_loop(void) { void bhv_circling_amp_loop(void) { switch (o->oAction) { case AMP_ACT_IDLE: - if (o->oBehParams2ndByte == AMP_BP_ROT_RADIUS_0) { + if (o->oBhvParams2ndByte == AMP_BP_ROT_RADIUS_0) { fixed_circling_amp_idle_loop(); } else { circling_amp_idle_loop(); diff --git a/src/game/behaviors/animated_floor_switch.inc.c b/src/game/behaviors/animated_floor_switch.inc.c index e0e8471f..826fe5d5 100644 --- a/src/game/behaviors/animated_floor_switch.inc.c +++ b/src/game/behaviors/animated_floor_switch.inc.c @@ -37,16 +37,16 @@ void bhv_animates_on_floor_switch_press_init(void) { void bhv_animates_on_floor_switch_press_loop(void) { if (o->oFloorSwitchPressAnimationUnk100 != 0) { - if (o->parentObj->oAction != 2) { + if (o->parentObj->oAction != PURPLE_SWITCH_ACT_TICKING) { o->oFloorSwitchPressAnimationUnk100 = 0; } if (o->oFloorSwitchPressAnimationUnkFC != 0) { - o->oFloorSwitchPressAnimationUnkF4 = D_80331ACC[o->oBehParams2ndByte]; + o->oFloorSwitchPressAnimationUnkF4 = D_80331ACC[o->oBhvParams2ndByte]; } else { o->oFloorSwitchPressAnimationUnkF4 = 0; } - } else if (o->parentObj->oAction == 2) { + } else if (o->parentObj->oAction == PURPLE_SWITCH_ACT_TICKING) { o->oFloorSwitchPressAnimationUnkFC ^= 1; o->oFloorSwitchPressAnimationUnk100 = 1; } @@ -71,7 +71,7 @@ void bhv_animates_on_floor_switch_press_loop(void) { } o->collisionData = segmented_to_virtual( - D_80331A54[o->oBehParams2ndByte][o->oFloorSwitchPressAnimationUnkF8 / 2].collision); + D_80331A54[o->oBhvParams2ndByte][o->oFloorSwitchPressAnimationUnkF8 / 2].collision); - cur_obj_set_model(D_80331A54[o->oBehParams2ndByte][o->oFloorSwitchPressAnimationUnkF8 / 2].model); + cur_obj_set_model(D_80331A54[o->oBhvParams2ndByte][o->oFloorSwitchPressAnimationUnkF8 / 2].model); } diff --git a/src/game/behaviors/bbh_tilting_trap.inc.c b/src/game/behaviors/bbh_tilting_trap.inc.c index 6f35cf06..40010a09 100644 --- a/src/game/behaviors/bbh_tilting_trap.inc.c +++ b/src/game/behaviors/bbh_tilting_trap.inc.c @@ -1,12 +1,12 @@ /** - * Behavior for bhvBbhTiltingTrapPlatform. + * Behavior for bhvBBHTiltingTrapPlatform. * This is the tilting platform trap in the upper floor of BBH * that drops the player into the merry-go-round area. */ /** - * Update function for bhvBbhTiltingTrapPlatform. + * Update function for bhvBBHTiltingTrapPlatform. */ void bhv_bbh_tilting_trap_platform_loop(void) { UNUSED u8 filler[4]; diff --git a/src/game/behaviors/bird.inc.c b/src/game/behaviors/bird.inc.c index 11d51058..e11d026f 100644 --- a/src/game/behaviors/bird.inc.c +++ b/src/game/behaviors/bird.inc.c @@ -16,10 +16,10 @@ static void bird_act_inactive(void) { // Start flying if the object is a spawned bird or if it's a spawner bird // and Mario is within 2000 units. - if (o->oBehParams2ndByte == BIRD_BP_SPAWNED || o->oDistanceToMario < 2000.0f) { + if (o->oBhvParams2ndByte == BIRD_BP_SPAWNED || o->oDistanceToMario < 2000.0f) { // If the object is a spawner bird, play the sound of birds flying away, // and spawn 6 spawned birds (which will start flying on the next frame). - if (o->oBehParams2ndByte != BIRD_BP_SPAWNED) { + if (o->oBhvParams2ndByte != BIRD_BP_SPAWNED) { s32 i; cur_obj_play_sound_2(SOUND_GENERAL_BIRDS_FLY_AWAY); @@ -68,7 +68,7 @@ static void bird_act_fly(void) { } else { // If the bird is a spawner bird, fly towards its home; otherwise, // fly towards the bird's spawner bird. - if (o->oBehParams2ndByte != BIRD_BP_SPAWNED) { + if (o->oBhvParams2ndByte != BIRD_BP_SPAWNED) { distance = cur_obj_lateral_dist_to_home(); // The spawner bird will start with its downwards (positive) pitch diff --git a/src/game/behaviors/bobomb.inc.c b/src/game/behaviors/bobomb.inc.c index 4db4137b..2d4b1c24 100644 --- a/src/game/behaviors/bobomb.inc.c +++ b/src/game/behaviors/bobomb.inc.c @@ -20,9 +20,9 @@ void bhv_bobomb_init(void) { } void bobomb_spawn_coin(void) { - if (!((o->oBehParams >> 8) & 0x01)) { + if (!((o->oBhvParams >> 8) & 0x01)) { obj_spawn_yellow_coins(o, 1); - o->oBehParams = 0x100; + o->oBhvParams = 0x100; set_object_respawn_info_bits(o, 1); } } @@ -83,7 +83,7 @@ void bobomb_act_patrol(void) { void bobomb_act_chase_mario(void) { UNUSED u8 filler[4]; - s16 animFrame = ++o->header.gfx.animInfo.animFrame; + s16 animFrame = ++o->header.gfx.animInfo.animFrame; s16 collisionFlags; o->oForwardVel = 20.0f; @@ -172,7 +172,7 @@ void stationary_bobomb_free_loop(void) { } void bobomb_free_loop(void) { - if (o->oBehParams2ndByte == BOBOMB_BP_STYPE_GENERIC) { + if (o->oBhvParams2ndByte == BOBOMB_BP_STYPE_GENERIC) { generic_bobomb_free_loop(); } else { stationary_bobomb_free_loop(); @@ -379,7 +379,7 @@ void bobomb_buddy_act_talk(void) { switch (o->oBobombBuddyRole) { case BOBOMB_BUDDY_ROLE_ADVICE: - if (cutscene_object_with_dialog(CUTSCENE_DIALOG, o, o->oBehParams2ndByte) + if (cutscene_object_with_dialog(CUTSCENE_DIALOG, o, o->oBhvParams2ndByte) != BOBOMB_BUDDY_BP_STYPE_GENERIC) { set_mario_npc_dialog(MARIO_DIALOG_STOP); diff --git a/src/game/behaviors/boo.inc.c b/src/game/behaviors/boo.inc.c index 1f935acd..f053ef00 100644 --- a/src/game/behaviors/boo.inc.c +++ b/src/game/behaviors/boo.inc.c @@ -88,7 +88,7 @@ void bhv_courtyard_boo_triplet_init(void) { } else { for (i = 0; i < 3; i++) { struct Object *boo = spawn_object_relative( - 1, sCourtyardBooTripletPositions[i][0], sCourtyardBooTripletPositions[i][1], + BOO_BP_GENERIC, sCourtyardBooTripletPositions[i][0], sCourtyardBooTripletPositions[i][1], sCourtyardBooTripletPositions[i][2], o, MODEL_BOO, bhvGhostHuntBoo); boo->oMoveAngleYaw = random_u16(); @@ -321,31 +321,31 @@ static s32 boo_get_attack_status(void) { } // boo idle/chasing movement? -static void boo_chase_mario(f32 a0, s16 a1, f32 a2) { - f32 sp1C; - s16 sp1A; +static void boo_chase_mario(f32 a0, s16 turnSpeed, f32 velMultiplier) { + f32 dy; + s16 targetYaw; if (boo_vanish_or_appear()) { o->oInteractType = INTERACT_BOUNCE_TOP; if (cur_obj_lateral_dist_from_mario_to_home() > 1500.0f) { - sp1A = cur_obj_angle_to_home(); + targetYaw = cur_obj_angle_to_home(); } else { - sp1A = o->oAngleToMario; + targetYaw = o->oAngleToMario; } - cur_obj_rotate_yaw_toward(sp1A, a1); + cur_obj_rotate_yaw_toward(targetYaw, turnSpeed); o->oVelY = 0.0f; if (!mario_is_in_air_action()) { - sp1C = o->oPosY - gMarioObject->oPosY; - if (a0 < sp1C && sp1C < 500.0f) { - o->oVelY = increment_velocity_toward_range - (o->oPosY, gMarioObject->oPosY + 50.0f, 10.0f, 2.0f); + dy = o->oPosY - gMarioObject->oPosY; + if (a0 < dy && dy < 500.0f) { + o->oVelY = increment_velocity_toward_range( + o->oPosY, gMarioObject->oPosY + 50.0f, 10.0f, 2.0f); } } - cur_obj_set_vel_from_mario_vel(10.0f - o->oBooNegatedAggressiveness, a2); + cur_obj_set_vel_from_mario_vel(10.0f - o->oBooNegatedAggressiveness, velMultiplier); if (o->oForwardVel != 0.0f) { boo_oscillate(FALSE); @@ -362,7 +362,7 @@ static void boo_chase_mario(f32 a0, s16 a1, f32 a2) { static void boo_act_0(void) { o->activeFlags |= ACTIVE_FLAG_MOVE_THROUGH_GRATE; - if (o->oBehParams2ndByte == 2) { + if (o->oBhvParams2ndByte == BOO_BP_MERRY_GO_ROUND) { o->oRoom = 10; } @@ -376,7 +376,7 @@ static void boo_act_0(void) { if (boo_should_be_active()) { // Condition is met if the object is bhvBalconyBigBoo or bhvMerryGoRoundBoo - if (o->oBehParams2ndByte == 2) { + if (o->oBhvParams2ndByte == BOO_BP_MERRY_GO_ROUND) { o->oBooParentBigBoo = NULL; o->oAction = 5; } else { @@ -434,7 +434,7 @@ static void boo_act_2(void) { static void boo_act_3(void) { if (boo_update_during_death()) { - if (o->oBehParams2ndByte != 0) { + if (o->oBhvParams2ndByte != BOO_BP_GHOST_HUNT) { obj_mark_for_deletion(o); } else { o->oAction = 4; @@ -528,18 +528,18 @@ static void big_boo_act_0(void) { static void big_boo_act_1(void) { s32 attackStatus; - s16 sp22; - f32 sp1C; + s16 turnSpeed; + f32 velMultiplier; if (o->oHealth == 3) { - sp22 = 0x180; sp1C = 0.5f; + turnSpeed = 0x180; velMultiplier = 0.5f; } else if (o->oHealth == 2) { - sp22 = 0x240; sp1C = 0.6f; + turnSpeed = 0x240; velMultiplier = 0.6f; } else { - sp22 = 0x300; sp1C = 0.8f; + turnSpeed = 0x300; velMultiplier = 0.8f; } - boo_chase_mario(-100.0f, sp22, sp1C); + boo_chase_mario(-100.0f, turnSpeed, velMultiplier); attackStatus = boo_get_attack_status(); @@ -604,11 +604,11 @@ static void big_boo_act_3(void) { obj_set_angle(o, 0, 0, 0); - if (o->oBehParams2ndByte == 0) { + if (o->oBhvParams2ndByte == BIG_BOO_BP_GHOST_HUNT) { big_boo_spawn_ghost_hunt_star(); - } else if (o->oBehParams2ndByte == 1) { + } else if (o->oBhvParams2ndByte == BIG_BOO_BP_MERRY_GO_ROUND) { big_boo_spawn_merry_go_round_star(); - } else { + } else { // BIG_BOO_BP_BALCONY big_boo_spawn_balcony_star(); } } @@ -629,11 +629,11 @@ static void big_boo_act_4(void) { boo_stop(); #endif - if (o->oBehParams2ndByte == 0) { + if (o->oBhvParams2ndByte == BIG_BOO_BP_GHOST_HUNT) { obj_set_pos(o, 973, 0, 626); if (o->oTimer > 60 && o->oDistanceToMario < 600.0f) { - obj_set_pos(o, 973, 0, 717); + obj_set_pos(o, 973, 0, 717); spawn_object_relative(0, 0, 0, 0, o, MODEL_BBH_STAIRCASE_STEP, bhvBooStaircase); spawn_object_relative(1, 0, 0, -200, o, MODEL_BBH_STAIRCASE_STEP, bhvBooStaircase); @@ -686,7 +686,7 @@ static void boo_with_cage_act_0(void) { static void boo_with_cage_act_1(void) { s32 attackStatus; - boo_chase_mario(100.0f, 512, 0.5f); + boo_chase_mario(100.0f, 0x200, 0.5f); attackStatus = boo_get_attack_status(); @@ -720,7 +720,7 @@ void bhv_boo_with_cage_init(void) { obj_mark_for_deletion(o); } else { struct Object *cage = spawn_object(o, MODEL_HAUNTED_CAGE, bhvBooCage); - cage->oBehParams = o->oBehParams; + cage->oBhvParams = o->oBhvParams; } } @@ -760,8 +760,8 @@ void bhv_merry_go_round_boo_manager_loop(void) { } if (o->oMerryGoRoundBooManagerNumBoosKilled >= 5) { - struct Object *boo = spawn_object(o, MODEL_BOO, bhvMerryGoRoundBigBoo); - obj_copy_behavior_params(boo, o); + struct Object *bigBoo = spawn_object(o, MODEL_BOO, bhvMerryGoRoundBigBoo); + obj_copy_behavior_params(bigBoo, o); o->oAction = 2; @@ -859,7 +859,7 @@ void bhv_boo_in_castle_loop(void) { void bhv_boo_staircase(void) { f32 targetY; - switch (o->oBehParams2ndByte) { + switch (o->oBhvParams2ndByte) { case 1: targetY = 0.0f; break; @@ -899,7 +899,7 @@ void bhv_boo_staircase(void) { break; case 3: - if (o->oTimer == 0 && o->oBehParams2ndByte == 1) { + if (o->oTimer == 0 && o->oBhvParams2ndByte == 1) { play_puzzle_jingle(); } diff --git a/src/game/behaviors/bowling_ball.inc.c b/src/game/behaviors/bowling_ball.inc.c index 34fefb36..42bc0c09 100644 --- a/src/game/behaviors/bowling_ball.inc.c +++ b/src/game/behaviors/bowling_ball.inc.c @@ -12,7 +12,7 @@ static struct ObjectHitbox sBowlingBallHitbox = { /* hurtboxHeight: */ 0, }; -static Trajectory sThiHugeMetalBallTraj[] = { +static Trajectory sTHIHugeMetalBallTraj[] = { TRAJECTORY_POS(0, /*pos*/ -4786, 101, -2166), TRAJECTORY_POS(1, /*pos*/ -5000, 81, -2753), TRAJECTORY_POS(2, /*pos*/ -5040, 33, -3846), @@ -26,7 +26,7 @@ static Trajectory sThiHugeMetalBallTraj[] = { TRAJECTORY_END(), }; -static Trajectory sThiTinyMetalBallTraj[] = { +static Trajectory sTHITinyMetalBallTraj[] = { TRAJECTORY_POS(0, /*pos*/ -1476, 29, -680), TRAJECTORY_POS(1, /*pos*/ -1492, 14, -1072), TRAJECTORY_POS(2, /*pos*/ -1500, 3, -1331), @@ -54,7 +54,7 @@ void bowling_ball_set_hitbox(void) { } void bowling_ball_set_waypoints(void) { - switch (o->oBehParams2ndByte) { + switch (o->oBhvParams2ndByte) { case BBALL_BP_STYPE_BOB_UPPER: o->oPathedStartWaypoint = segmented_to_virtual(bob_seg7_metal_ball_path0); break; @@ -68,11 +68,11 @@ void bowling_ball_set_waypoints(void) { break; case BBALL_BP_STYPE_THI_LARGE: - o->oPathedStartWaypoint = (struct Waypoint *) sThiHugeMetalBallTraj; + o->oPathedStartWaypoint = (struct Waypoint *) sTHIHugeMetalBallTraj; break; case BBALL_BP_STYPE_THI_SMALL: - o->oPathedStartWaypoint = (struct Waypoint *) sThiTinyMetalBallTraj; + o->oPathedStartWaypoint = (struct Waypoint *) sTHITinyMetalBallTraj; break; } } @@ -87,7 +87,7 @@ void bhv_bowling_ball_roll_loop(void) { bowling_ball_set_waypoints(); collisionFlags = object_step(); - //! Uninitialzed parameter, but the parameter is unused in the called function + //! Uninitialized parameter, but the parameter is unused in the called function followStatus = cur_obj_follow_path(followStatus); o->oBowlingBallTargetYaw = o->oPathedTargetYaw; @@ -120,12 +120,12 @@ void bhv_bowling_ball_initialize_loop(void) { bowling_ball_set_waypoints(); - //! Uninitialzed parameter, but the parameter is unused in the called function + //! Uninitialized parameter, but the parameter is unused in the called function followStatus = cur_obj_follow_path(followStatus); o->oMoveAngleYaw = o->oPathedTargetYaw; - switch (o->oBehParams2ndByte) { + switch (o->oBhvParams2ndByte) { case BBALL_BP_STYPE_BOB_UPPER: o->oForwardVel = 20.0f; break; @@ -162,7 +162,7 @@ void bhv_bowling_ball_loop(void) { break; } - if (o->oBehParams2ndByte != BBALL_BP_STYPE_THI_SMALL) { + if (o->oBhvParams2ndByte != BBALL_BP_STYPE_THI_SMALL) { set_camera_shake_from_point(SHAKE_POS_BOWLING_BALL, o->oPosX, o->oPosY, o->oPosZ); } @@ -170,7 +170,7 @@ void bhv_bowling_ball_loop(void) { } void bhv_generic_bowling_ball_spawner_init(void) { - switch (o->oBehParams2ndByte) { + switch (o->oBhvParams2ndByte) { case BBALL_BP_STYPE_BOB_UPPER: o->oBBallSpawnerMaxSpawnDist = 7000.0f; o->oBBallSpawnerSpawnOdds = 2.0f; @@ -202,7 +202,7 @@ void bhv_generic_bowling_ball_spawner_loop(void) { if (is_point_within_radius_of_mario(o->oPosX, o->oPosY, o->oPosZ, o->oBBallSpawnerMaxSpawnDist) && (s32)(random_float() * o->oBBallSpawnerSpawnOdds) == 0) { struct Object *bowlingBall = spawn_object(o, MODEL_BOWLING_BALL, bhvBowlingBall); - bowlingBall->oBehParams2ndByte = o->oBehParams2ndByte; + bowlingBall->oBhvParams2ndByte = o->oBhvParams2ndByte; } } } @@ -221,7 +221,7 @@ void bhv_thi_bowling_ball_spawner_loop(void) { if (is_point_within_radius_of_mario(o->oPosX, o->oPosY, o->oPosZ, 12000) && (s32)(random_float() * 1.5) == 0) { struct Object *bowlingBall = spawn_object(o, MODEL_BOWLING_BALL, bhvBowlingBall); - bowlingBall->oBehParams2ndByte = o->oBehParams2ndByte; + bowlingBall->oBhvParams2ndByte = o->oBhvParams2ndByte; } } } diff --git a/src/game/behaviors/bowser.inc.c b/src/game/behaviors/bowser.inc.c index 2cd9a96c..c4e3e410 100644 --- a/src/game/behaviors/bowser.inc.c +++ b/src/game/behaviors/bowser.inc.c @@ -156,7 +156,7 @@ void bhv_bowser_body_anchor_loop(void) { * Bowser's shockwave attack, spawns only in BitS */ s32 bowser_spawn_shockwave(void) { - if (o->oBehParams2ndByte == BOWSER_BP_BITS) { + if (o->oBhvParams2ndByte == BOWSER_BP_BITS) { struct Object *wave = spawn_object(o, MODEL_BOWSER_WAVE, bhvBowserShockWave); wave->oPosY = o->oFloorHeight; return TRUE; @@ -235,7 +235,7 @@ void bowser_init_camera_actions(void) { } else if (o->oBowserCamAct == BOWSER_CAM_ACT_WALK) { o->oAction = BOWSER_ACT_INTRO_WALK; // Start with a big jump in BitFS to do a platform tilt - } else if (o->oBehParams2ndByte == BOWSER_BP_BITFS) { + } else if (o->oBhvParams2ndByte == BOWSER_BP_BITFS) { o->oAction = BOWSER_ACT_BIG_JUMP; } else { o->oAction = BOWSER_ACT_DEFAULT; @@ -410,7 +410,7 @@ void bowser_bits_action_list(void) { /** * Sets big jump action, not much to say - * Never gets called since oBowserBitsJustJump is always FALSE + * Never gets called since oBowserBitSJustJump is always FALSE */ void bowser_set_act_big_jump(void) { o->oAction = BOWSER_ACT_BIG_JUMP; @@ -422,9 +422,9 @@ void bowser_set_act_big_jump(void) { void bowser_bits_actions(void) { switch (o->oBowserIsReacting) { case FALSE: - // oBowserBitsJustJump never changes value, + // oBowserBitSJustJump never changes value, // so its always FALSE, maybe a debug define - if (o->oBowserBitsJustJump == FALSE) { + if (o->oBowserBitSJustJump == FALSE) { bowser_bits_action_list(); } else { bowser_set_act_big_jump(); @@ -475,9 +475,9 @@ void bowser_act_default(void) { o->oForwardVel = 0.0f; o->oVelY = 0.0f; // Set level specific actions - if (o->oBehParams2ndByte == BOWSER_BP_BITDW) { + if (o->oBhvParams2ndByte == BOWSER_BP_BITDW) { bowser_bitdw_actions(); - } else if (o->oBehParams2ndByte == BOWSER_BP_BITFS) { + } else if (o->oBhvParams2ndByte == BOWSER_BP_BITFS) { bowser_bitfs_actions(); } else { // BOWSER_BP_BITS bowser_bits_actions(); @@ -510,7 +510,7 @@ void bowser_act_walk_to_mario(void) { // Set turning speed depending of the health // Also special case for BitFS - if (o->oBehParams2ndByte == BOWSER_BP_BITFS) { + if (o->oBhvParams2ndByte == BOWSER_BP_BITFS) { turnSpeed = 0x400; } else { // BOWSER_BP_BITDW or BOWSER_BP_BITS if (o->oHealth >= 3) { @@ -698,7 +698,7 @@ s32 bowser_land(void) { cur_obj_start_cam_event(o, CAM_EVENT_BOWSER_JUMP); // Set status attacks in BitDW since the other levels // have different attacks defined - if (o->oBehParams2ndByte == BOWSER_BP_BITDW) { + if (o->oBhvParams2ndByte == BOWSER_BP_BITDW) { if (o->oDistanceToMario < 850.0f) { gMarioObject->oInteractStatus |= INT_STATUS_MARIO_KNOCKBACK_DMG; } else { @@ -715,7 +715,7 @@ s32 bowser_land(void) { * Makes Bowser do a second hop speed only in BitS */ void bowser_short_second_hop(void) { - if (o->oBehParams2ndByte == BOWSER_BP_BITS && o->oBowserStatus & BOWSER_STATUS_BIG_JUMP) { + if (o->oBhvParams2ndByte == BOWSER_BP_BITS && o->oBowserStatus & BOWSER_STATUS_BIG_JUMP) { if (o->oBowserDistToCenter > 1000.0f) { o->oForwardVel = 60.0f; } @@ -732,7 +732,7 @@ void bowser_act_big_jump(void) { // Set jump animation if (bowser_set_anim_jump()) { // Set vel depending of the stage and status - if (o->oBehParams2ndByte == BOWSER_BP_BITS && o->oBowserStatus & BOWSER_STATUS_BIG_JUMP) { + if (o->oBhvParams2ndByte == BOWSER_BP_BITS && o->oBowserStatus & BOWSER_STATUS_BIG_JUMP) { o->oVelY = 70.0f; } else { o->oVelY = 80.0f; @@ -744,7 +744,7 @@ void bowser_act_big_jump(void) { } else if (o->oSubAction == 1) { #if BUGFIX_BOWSER_FALLEN_OFF_STAGE // Reset Bowser back on stage in BitS if he doesn't land properly - if (o->oBehParams2ndByte == BOWSER_BP_BITS && o->oBowserStatus & BOWSER_STATUS_BIG_JUMP) { + if (o->oBhvParams2ndByte == BOWSER_BP_BITS && o->oBowserStatus & BOWSER_STATUS_BIG_JUMP) { bowser_reset_fallen_off_stage(); } #endif @@ -756,7 +756,7 @@ void bowser_act_big_jump(void) { // Spawn shockwave (BitS only) if is not on a platform bowser_spawn_shockwave(); // Tilt platform in BitFS - if (o->oBehParams2ndByte == BOWSER_BP_BITFS) { + if (o->oBhvParams2ndByte == BOWSER_BP_BITFS) { o->oAction = BOWSER_ACT_TILT_LAVA_PLATFORM; } } else { @@ -952,7 +952,7 @@ void bowser_act_charge_mario(void) { cur_obj_init_animation_with_sound(BOWSER_ANIM_RUN_STOP); if (cur_obj_check_if_near_animation_end()) { // Set time delay to go to default action - if (o->oBehParams2ndByte == BOWSER_BP_BITS) { + if (o->oBhvParams2ndByte == BOWSER_BP_BITS) { time = 10; } else { time = 30; @@ -1103,11 +1103,11 @@ void bowser_act_jump_onto_stage(void) { bowser_spawn_shockwave(); // If is on a dynamic floor in BitS, then jump // because of the falling platform - } else if (o->oBehParams2ndByte == BOWSER_BP_BITS) { + } else if (o->oBhvParams2ndByte == BOWSER_BP_BITS) { o->oAction = BOWSER_ACT_BIG_JUMP; } // If is on a dynamic floor in BitFS, then tilt platform - if (o->oBehParams2ndByte == BOWSER_BP_BITFS) { + if (o->oBhvParams2ndByte == BOWSER_BP_BITFS) { o->oAction = BOWSER_ACT_TILT_LAVA_PLATFORM; } } @@ -1161,7 +1161,7 @@ void bowser_act_dance(void) { * Spawns a Key in BitDW/BitFS or Grand Star in BitS */ void bowser_spawn_collectable(void) { - if (o->oBehParams2ndByte == BOWSER_BP_BITS) { + if (o->oBhvParams2ndByte == BOWSER_BP_BITS) { gSecondCameraFocus = spawn_object(o, MODEL_STAR, bhvGrandStar); } else { gSecondCameraFocus = spawn_object(o, MODEL_BOWSER_KEY, bhvBowserKey); @@ -1176,7 +1176,7 @@ void bowser_spawn_collectable(void) { void bowser_fly_back_dead(void) { cur_obj_init_animation_with_sound(BOWSER_ANIM_FLIP_DOWN); // More knockback in BitS - if (o->oBehParams2ndByte == BOWSER_BP_BITS) { + if (o->oBhvParams2ndByte == BOWSER_BP_BITS) { o->oForwardVel = -400.0f; } else { o->oForwardVel = -200.0f; @@ -1284,7 +1284,7 @@ s32 bowser_dead_default_stage_ending(void) { // Play Bowser defeated dialog if (cur_obj_update_dialog(MARIO_DIALOG_LOOK_UP, (DIALOG_FLAG_TEXT_DEFAULT | DIALOG_FLAG_TIME_STOP_ENABLED), - sBowserDefeatedDialogText[o->oBehParams2ndByte], 0)) { + sBowserDefeatedDialogText[o->oBhvParams2ndByte], 0)) { // Dialog is done, fade out music and play explode sound effect o->oBowserTimer++; cur_obj_play_sound_2(SOUND_GENERAL2_BOWSER_EXPLODE); @@ -1366,7 +1366,7 @@ void bowser_act_dead(void) { o->oBowserTimer = 0; // Set different (final) subaction in BitS // Non-BitS Bowser uses default subaction and sets dithering - if (o->oBehParams2ndByte == BOWSER_BP_BITS) { + if (o->oBhvParams2ndByte == BOWSER_BP_BITS) { o->oSubAction = BOWSER_SUB_ACT_DEAD_FINAL_END; } else { o->activeFlags |= ACTIVE_FLAG_DITHERED_ALPHA; @@ -1772,7 +1772,7 @@ void bhv_bowser_init(void) { } else { // LEVEL_BOWSER_1 level = BOWSER_BP_BITDW; } - o->oBehParams2ndByte = level; + o->oBhvParams2ndByte = level; // Set health and rainbow light depending of the level o->oBowserRainbowLight = sBowserRainbowLight[level]; o->oHealth = sBowserHealth[level]; diff --git a/src/game/behaviors/bowser_falling_platform.inc.c b/src/game/behaviors/bowser_falling_platform.inc.c index 85da27a7..2c9785d8 100644 --- a/src/game/behaviors/bowser_falling_platform.inc.c +++ b/src/game/behaviors/bowser_falling_platform.inc.c @@ -22,16 +22,16 @@ struct BowserFallingPlatformData sBowserFallingPlatform[] = { }; void falling_bowser_plat_act_start(void) { - o->oBitsPlatformBowser = cur_obj_nearest_object_with_behavior(bhvBowser); - obj_set_collision_data(o, sBowserFallingPlatform[o->oBehParams2ndByte].collision); - if (o->oBitsPlatformBowser != NULL) { + o->oBitSPlatformBowser = cur_obj_nearest_object_with_behavior(bhvBowser); + obj_set_collision_data(o, sBowserFallingPlatform[o->oBhvParams2ndByte].collision); + if (o->oBitSPlatformBowser != NULL) { o->oAction = BOWSER_BITS_PLAT_ACT_CHECK; } } void falling_bowser_plat_act_check(void) { UNUSED u8 filler[4]; - struct Object *bowser = o->oBitsPlatformBowser; + struct Object *bowser = o->oBitSPlatformBowser; if (bowser->platform == o) { if (bowser->oAction == BOWSER_ACT_BIG_JUMP @@ -46,13 +46,13 @@ void falling_bowser_plat_act_check(void) { } if (o->oSubAction == 0) { - o->oBitsPlatformTimer = 0; + o->oBitSPlatformTimer = 0; } else { if ((gDebugInfo[DEBUG_PAGE_EFFECTINFO][6] + 20) - * (o->oBehParams2ndByte - 1) < o->oBitsPlatformTimer) { + * (o->oBhvParams2ndByte - 1) < o->oBitSPlatformTimer) { o->oAction = BOWSER_BITS_PLAT_ACT_FALL; } - o->oBitsPlatformTimer++; + o->oBitSPlatformTimer++; } } @@ -60,7 +60,7 @@ void falling_bowser_plat_act_fall(void) { Vec3f pos; s16 angle; f32 val; - UNUSED struct Object *bowser = o->oBitsPlatformBowser; + UNUSED struct Object *bowser = o->oBitSPlatformBowser; if (o->oTimer == 0 || o->oTimer == 22) { cur_obj_play_sound_2(SOUND_GENERAL_BOWSER_PLATFORM_2); @@ -75,17 +75,17 @@ void falling_bowser_plat_act_fall(void) { } if (!(o->oTimer & 1) && o->oTimer < 14) { - angle = sBowserFallingPlatform[o->oBehParams2ndByte].angle + angle = sBowserFallingPlatform[o->oBhvParams2ndByte].angle + (gDebugInfo[DEBUG_PAGE_EFFECTINFO][1] << 8); val = -(o->oTimer / 2) * 290 + 1740; vec3f_copy_2(pos, &o->oPosX); - o->oPosX = sBowserFallingPlatform[o->oBehParams2ndByte].posX + sins(angle + 0x14B0) * val; - o->oPosZ = sBowserFallingPlatform[o->oBehParams2ndByte].posZ + coss(angle + 0x14B0) * val; + o->oPosX = sBowserFallingPlatform[o->oBhvParams2ndByte].posX + sins(angle + 0x14B0) * val; + o->oPosZ = sBowserFallingPlatform[o->oBhvParams2ndByte].posZ + coss(angle + 0x14B0) * val; o->oPosY = 307.0f; spawn_mist_particles_variable(4, 0, 100.0f); - o->oPosX = sBowserFallingPlatform[o->oBehParams2ndByte].posX + sins(angle - 0x14B0) * val; - o->oPosZ = sBowserFallingPlatform[o->oBehParams2ndByte].posZ + coss(angle - 0x14B0) * val; - spawn_mist_particles_variable(4, 0, 100); + o->oPosX = sBowserFallingPlatform[o->oBhvParams2ndByte].posX + sins(angle - 0x14B0) * val; + o->oPosZ = sBowserFallingPlatform[o->oBhvParams2ndByte].posZ + coss(angle - 0x14B0) * val; + spawn_mist_particles_variable(4, 0, 100.0f); vec3f_copy_2(&o->oPosX, pos); } diff --git a/src/game/behaviors/bowser_flame.inc.c b/src/game/behaviors/bowser_flame.inc.c index 08a6d670..2e6838fd 100644 --- a/src/game/behaviors/bowser_flame.inc.c +++ b/src/game/behaviors/bowser_flame.inc.c @@ -146,7 +146,7 @@ void bhv_flame_moving_forward_growing_loop(void) { void bhv_flame_floating_landing_init(void) { o->oAnimState = (s32)(random_float() * 10.0f); o->oMoveAngleYaw = random_u16(); - if (o->oBehParams2ndByte != 0) { + if (o->oBhvParams2ndByte != 0) { o->oForwardVel = random_float() * 5.0f; } else { o->oForwardVel = random_float() * 70.0f; @@ -169,12 +169,12 @@ void bhv_flame_floating_landing_loop(void) { obj_mark_for_deletion(o); } - if (o->oVelY < sFlameFloatingYLimit[o->oBehParams2ndByte]) { - o->oVelY = sFlameFloatingYLimit[o->oBehParams2ndByte]; + if (o->oVelY < sFlameFloatingYLimit[o->oBhvParams2ndByte]) { + o->oVelY = sFlameFloatingYLimit[o->oBhvParams2ndByte]; } if (o->oMoveFlags & OBJ_MOVE_LANDED) { - if (o->oBehParams2ndByte == 0) { + if (o->oBhvParams2ndByte == 0) { spawn_object(o, MODEL_RED_FLAME, bhvFlameLargeBurningOut); } else { spawn_object(o, MODEL_NONE, bhvBlueFlamesGroup); //? wonder if they meant MODEL_BLUE_FLAME? @@ -210,7 +210,7 @@ void bhv_blue_bowser_flame_loop(void) { cur_obj_move_standard(78); if (o->oTimer > 20) { - if (o->oBehParams2ndByte == 0) { + if (o->oBhvParams2ndByte == 0) { for (i = 0; i < 3; i++) { spawn_object_relative_with_scale(0, 0, 0, 0, 5.0f, o, MODEL_RED_FLAME, bhvFlameFloatingLanding); diff --git a/src/game/behaviors/bowser_key_cutscene.inc.c b/src/game/behaviors/bowser_key_cutscene.inc.c index 6f3ac484..01bec52e 100644 --- a/src/game/behaviors/bowser_key_cutscene.inc.c +++ b/src/game/behaviors/bowser_key_cutscene.inc.c @@ -2,8 +2,8 @@ Gfx *geo_scale_bowser_key(s32 run, struct GraphNode *node, UNUSED f32 mtx[4][4]) { if (run == TRUE) { - struct Object *sp4 = (struct Object *) gCurGraphNodeObject; - ((struct GraphNodeScale *) node->next)->scale = sp4->oBowserKeyScale; + struct Object *obj = (struct Object *) gCurGraphNodeObject; + ((struct GraphNodeScale *) node->next)->scale = obj->oBowserKeyScale; } return NULL; } diff --git a/src/game/behaviors/bowser_puzzle_piece.inc.c b/src/game/behaviors/bowser_puzzle_piece.inc.c index aaed6022..88c8a694 100644 --- a/src/game/behaviors/bowser_puzzle_piece.inc.c +++ b/src/game/behaviors/bowser_puzzle_piece.inc.c @@ -105,7 +105,7 @@ void bhv_lll_bowser_puzzle_spawn_pieces(f32 pieceWidth) { // Spawn all 14 puzzle pieces. for (i = 0; i < 14; i++) { - bhv_lll_bowser_puzzle_spawn_piece(sBowserPuzzlePieces[i].model, bhvLllBowserPuzzlePiece, + bhv_lll_bowser_puzzle_spawn_piece(sBowserPuzzlePieces[i].model, bhvLLLBowserPuzzlePiece, sBowserPuzzlePieces[i].xOffset * pieceWidth / 10.0f, sBowserPuzzlePieces[i].zOffset * pieceWidth / 10.0f, sBowserPuzzlePieces[i].initialAction, @@ -197,7 +197,7 @@ void bhv_lll_bowser_puzzle_piece_update(void) { } } -void bhv_lll_bowser_puzzle_piece_move(f32 xOffset, f32 zOffset, s32 duration, UNUSED s32 a3) { +void bhv_lll_bowser_puzzle_piece_move(f32 xOffset, f32 zOffset, s32 duration, UNUSED s32 unused) { // For the first 20 frames, shake the puzzle piece up and down. if (o->oTimer < 20) { if (o->oTimer % 2) { diff --git a/src/game/behaviors/breakable_wall.inc.c b/src/game/behaviors/breakable_wall.inc.c index 53e21de0..b0c7d8aa 100644 --- a/src/game/behaviors/breakable_wall.inc.c +++ b/src/game/behaviors/breakable_wall.inc.c @@ -5,7 +5,7 @@ void bhv_wf_breakable_wall_loop(void) { cur_obj_become_tangible(); if (obj_check_if_collided_with_object(o, gMarioObject)) { - if (cur_obj_has_behavior(bhvWfBreakableWallRight)) { + if (cur_obj_has_behavior(bhvWFBreakableWallRight)) { play_puzzle_jingle(); } diff --git a/src/game/behaviors/bully.inc.c b/src/game/behaviors/bully.inc.c index 85340bc1..4b252ab8 100644 --- a/src/game/behaviors/bully.inc.c +++ b/src/game/behaviors/bully.inc.c @@ -29,7 +29,7 @@ void bhv_small_bully_init(void) { o->oHomeX = o->oPosX; o->oHomeZ = o->oPosZ; - o->oBehParams2ndByte = BULLY_BP_SIZE_SMALL; + o->oBhvParams2ndByte = BULLY_BP_SIZE_SMALL; o->oGravity = 4.0; o->oFriction = 0.91; o->oBuoyancy = 1.3; @@ -43,7 +43,7 @@ void bhv_big_bully_init(void) { o->oHomeX = o->oPosX; o->oHomeY = o->oPosY; o->oHomeZ = o->oPosZ; - o->oBehParams2ndByte = BULLY_BP_SIZE_BIG; + o->oBhvParams2ndByte = BULLY_BP_SIZE_BIG; o->oGravity = 5.0; o->oFriction = 0.93; o->oBuoyancy = 1.3; @@ -53,11 +53,11 @@ void bhv_big_bully_init(void) { void bully_check_mario_collision(void) { if ( -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) o->oAction != BULLY_ACT_LAVA_DEATH && o->oAction != BULLY_ACT_DEATH_PLANE_DEATH && #endif o->oInteractStatus & INT_STATUS_INTERACTED) { - if (o->oBehParams2ndByte == BULLY_BP_SIZE_SMALL) { + if (o->oBhvParams2ndByte == BULLY_BP_SIZE_SMALL) { cur_obj_play_sound_2(SOUND_OBJ2_BULLY_ATTACKED); } else { cur_obj_play_sound_2(SOUND_OBJ2_LARGE_BULLY_ATTACKED); @@ -79,7 +79,7 @@ void bully_act_chase_mario(void) { if (o->oTimer < 10) { o->oForwardVel = 3.0; obj_turn_toward_object(o, gMarioObject, 16, 0x1000); - } else if (o->oBehParams2ndByte == BULLY_BP_SIZE_SMALL) { + } else if (o->oBhvParams2ndByte == BULLY_BP_SIZE_SMALL) { o->oForwardVel = 20.0; if (o->oTimer > 30) { o->oTimer = 0; @@ -151,7 +151,7 @@ void bully_play_stomping_sound(void) { switch (o->oAction) { case BULLY_ACT_PATROL: if (animFrame == 0 || animFrame == 12) { - if (o->oBehParams2ndByte == BULLY_BP_SIZE_SMALL) { + if (o->oBhvParams2ndByte == BULLY_BP_SIZE_SMALL) { cur_obj_play_sound_2(SOUND_OBJ_BULLY_WALK); } else { cur_obj_play_sound_2(SOUND_OBJ_BULLY_WALKING); @@ -162,7 +162,7 @@ void bully_play_stomping_sound(void) { case BULLY_ACT_CHASE_MARIO: case BULLY_ACT_BACK_UP: if (animFrame == 0 || animFrame == 5) { - if (o->oBehParams2ndByte == BULLY_BP_SIZE_SMALL) { + if (o->oBhvParams2ndByte == BULLY_BP_SIZE_SMALL) { cur_obj_play_sound_2(SOUND_OBJ_BULLY_WALK); } else { cur_obj_play_sound_2(SOUND_OBJ_BULLY_WALKING); @@ -200,7 +200,7 @@ void bully_spawn_coin(void) { void bully_act_level_death(void) { if (obj_lava_death() == TRUE) { - if (o->oBehParams2ndByte == BULLY_BP_SIZE_SMALL) { + if (o->oBhvParams2ndByte == BULLY_BP_SIZE_SMALL) { if (o->oBullySubtype == BULLY_STYPE_MINION) { o->parentObj->oBullyKBTimerAndMinionKOCounter++; } @@ -212,7 +212,7 @@ void bully_act_level_death(void) { spawn_default_star(130.0f, 1600.0f, -4335.0f); } else { spawn_default_star(0, 950.0f, -6800.0f); - spawn_object_abs_with_rot(o, 0, MODEL_NONE, bhvLllTumblingBridge, + spawn_object_abs_with_rot(o, 0, MODEL_NONE, bhvLLLTumblingBridge, 0, 154, -5631, 0, 0, 0); } } @@ -273,7 +273,7 @@ void big_bully_spawn_minion(s32 x, s32 y, s32 z, s16 yaw) { struct Object *bully = spawn_object_abs_with_rot(o, 0, MODEL_BULLY, bhvSmallBully, x, y, z, 0, yaw, 0); bully->oBullySubtype = BULLY_STYPE_MINION; - bully->oBehParams2ndByte = BULLY_BP_SIZE_SMALL; + bully->oBhvParams2ndByte = BULLY_BP_SIZE_SMALL; } void bhv_big_bully_with_minions_init(void) { diff --git a/src/game/behaviors/camera_lakitu.inc.c b/src/game/behaviors/camera_lakitu.inc.c index b3371198..2292e140 100644 --- a/src/game/behaviors/camera_lakitu.inc.c +++ b/src/game/behaviors/camera_lakitu.inc.c @@ -11,7 +11,7 @@ * Spawn cloud if not the intro lakitu. */ void bhv_camera_lakitu_init(void) { - if (o->oBehParams2ndByte != CAMERA_LAKITU_BP_FOLLOW_CAMERA) { + if (o->oBhvParams2ndByte != CAMERA_LAKITU_BP_FOLLOW_CAMERA) { // Despawn unless this is the very beginning of the game if (gNeverEnteredCastle != TRUE) { obj_mark_for_deletion(o); @@ -116,7 +116,7 @@ static void camera_lakitu_intro_act_show_dialog(void) { } } } - } else if (cur_obj_update_dialog_with_cutscene(MARIO_DIALOG_LOOK_UP, + } else if (cur_obj_update_dialog_with_cutscene(MARIO_DIALOG_LOOK_UP, DIALOG_FLAG_TURN_TO_MARIO, CUTSCENE_DIALOG, DIALOG_034)) { o->oCameraLakituFinishedDialog = TRUE; } @@ -140,7 +140,7 @@ void bhv_camera_lakitu_update(void) { if (!(o->activeFlags & ACTIVE_FLAG_IN_DIFFERENT_ROOM)) { obj_update_blinking(&o->oCameraLakituBlinkTimer, 20, 40, 4); - if (o->oBehParams2ndByte != CAMERA_LAKITU_BP_FOLLOW_CAMERA) { + if (o->oBhvParams2ndByte != CAMERA_LAKITU_BP_FOLLOW_CAMERA) { switch (o->oAction) { case CAMERA_LAKITU_INTRO_ACT_TRIGGER_CUTSCENE: camera_lakitu_intro_act_trigger_cutscene(); diff --git a/src/game/behaviors/cannon.inc.c b/src/game/behaviors/cannon.inc.c index 2b0dac0d..37a9cd00 100644 --- a/src/game/behaviors/cannon.inc.c +++ b/src/game/behaviors/cannon.inc.c @@ -11,9 +11,9 @@ void opened_cannon_act_0(void) { o->oPosY = o->oHomeY; o->oPosZ = o->oHomeZ; o->oMoveAnglePitch = 0; - o->oMoveAngleYaw = (s16)(o->oBehParams2ndByte << 8); + o->oMoveAngleYaw = (s16)(o->oBhvParams2ndByte << 8); o->oCannonUnkF4 = 0; - o->oCannonUnk10C = 0; + o->oCannonUnk10C = FALSE; cur_obj_enable_rendering(); cur_obj_become_tangible(); } @@ -21,10 +21,10 @@ void opened_cannon_act_0(void) { if (o->oDistanceToMario < 500.0f) { cur_obj_become_tangible(); cur_obj_enable_rendering(); - if (o->oInteractStatus & INT_STATUS_INTERACTED + if ((o->oInteractStatus & INT_STATUS_INTERACTED) && !(o->oInteractStatus & INT_STATUS_TOUCHED_BOB_OMB)) { // bob-omb explodes when it gets into a cannon o->oAction = 4; - o->oCannonUnk10C = 1; + o->oCannonUnk10C = TRUE; o->oCannonUnkF8 = 1; } else { o->oInteractStatus = 0; @@ -32,7 +32,7 @@ void opened_cannon_act_0(void) { } else { cur_obj_become_intangible(); cur_obj_disable_rendering(); - o->oCannonUnk10C = 0; + o->oCannonUnk10C = FALSE; } } @@ -65,7 +65,7 @@ void opened_cannon_act_6(void) { } else { if (o->oTimer < 22) { o->oMoveAngleYaw = - sins(o->oCannonUnkF4) * 0x4000 + ((s16)(o->oBehParams2ndByte << 8)); + sins(o->oCannonUnkF4) * 0x4000 + ((s16)(o->oBhvParams2ndByte << 8)); o->oCannonUnkF4 += 0x400; } else if (o->oTimer < 26) { } else { @@ -99,7 +99,7 @@ void opened_cannon_act_1(void) { cur_obj_become_intangible(); cur_obj_disable_rendering(); - o->oCannonUnk10C = 0; + o->oCannonUnk10C = FALSE; gMarioShotFromCannon = TRUE; } @@ -127,7 +127,7 @@ void (*sOpenedCannonActions[])(void) = { void bhv_cannon_base_loop(void) { cur_obj_call_action_function(sOpenedCannonActions); - if (o->oCannonUnkF8) { + if (o->oCannonUnkF8 != 0) { o->oCannonUnkF8++; } diff --git a/src/game/behaviors/cannon_door.inc.c b/src/game/behaviors/cannon_door.inc.c index 52ab3e86..4407e7a4 100644 --- a/src/game/behaviors/cannon_door.inc.c +++ b/src/game/behaviors/cannon_door.inc.c @@ -5,7 +5,7 @@ void bhv_cannon_closed_init(void) { // If the cannon is open, spawn a cannon and despawn the object. struct Object *cannon = spawn_object(o, MODEL_CANNON_BASE, bhvCannon); - cannon->oBehParams2ndByte = o->oBehParams2ndByte; + cannon->oBhvParams2ndByte = o->oBhvParams2ndByte; cannon->oPosX = o->oHomeX; cannon->oPosY = o->oHomeY; cannon->oPosZ = o->oHomeZ; diff --git a/src/game/behaviors/capswitch.inc.c b/src/game/behaviors/capswitch.inc.c index aecde91d..39c983a5 100644 --- a/src/game/behaviors/capswitch.inc.c +++ b/src/game/behaviors/capswitch.inc.c @@ -3,14 +3,14 @@ UNUSED u8 sCapSwitchText[] = { DIALOG_010, DIALOG_011, DIALOG_012 }; void cap_switch_act_0(void) { - o->oAnimState = o->oBehParams2ndByte; + o->oAnimState = o->oBhvParams2ndByte; cur_obj_scale(0.5f); o->oPosY += 71.0f; spawn_object_relative_with_scale(0, 0, -71, 0, 0.5f, o, MODEL_CAP_SWITCH_BASE, bhvCapSwitchBase); if (gCurrLevelNum != LEVEL_UNKNOWN_32) { - if (save_file_get_flags() & sCapSaveFlags[o->oBehParams2ndByte]) { + if (save_file_get_flags() & sCapSaveFlags[o->oBhvParams2ndByte]) { o->oAction = 3; o->header.gfx.scale[1] = 0.1f; } else { @@ -23,7 +23,7 @@ void cap_switch_act_0(void) { void cap_switch_act_1(void) { if (cur_obj_is_mario_on_platform()) { - save_file_set_flags(sCapSaveFlags[o->oBehParams2ndByte]); + save_file_set_flags(sCapSaveFlags[o->oBhvParams2ndByte]); o->oAction = 2; cur_obj_play_sound_2(SOUND_GENERAL_ACTIVATE_CAP_SWITCH); } @@ -35,16 +35,16 @@ void cap_switch_act_2(void) { if (o->oTimer == 4) { cur_obj_shake_screen(SHAKE_POS_SMALL); spawn_mist_particles(); - spawn_triangle_break_particles(60, MODEL_CARTOON_STAR, 0.3f, o->oBehParams2ndByte); + spawn_triangle_break_particles(60, MODEL_CARTOON_STAR, 0.3f, o->oBhvParams2ndByte); #if ENABLE_RUMBLE queue_rumble_data(5, 80); #endif } } else { //! Neither of these flags are defined in this function so they do nothing. - // On an extra note, there's a specific check for this cutscene and + // On an extra note, there's a specific check for this cutscene and // there's no dialog defined since the cutscene itself calls the dialog. - s32 dialogResponse = cur_obj_update_dialog_with_cutscene(MARIO_DIALOG_LOOK_FRONT, + s32 dialogResponse = cur_obj_update_dialog_with_cutscene(MARIO_DIALOG_LOOK_FRONT, (DIALOG_FLAG_TEXT_RESPONSE | DIALOG_FLAG_UNK_CAPSWITCH), CUTSCENE_CAP_SWITCH_PRESS, 0); if (dialogResponse) { o->oAction = 3; diff --git a/src/game/behaviors/chain_chomp.inc.c b/src/game/behaviors/chain_chomp.inc.c index 54c136c9..a7189513 100644 --- a/src/game/behaviors/chain_chomp.inc.c +++ b/src/game/behaviors/chain_chomp.inc.c @@ -30,8 +30,8 @@ static struct ObjectHitbox sChainChompHitbox = { void bhv_chain_chomp_chain_part_update(void) { if (o->parentObj->oAction == CHAIN_CHOMP_ACT_UNLOAD_CHAIN) { obj_mark_for_deletion(o); - } else if (o->oBehParams2ndByte != CHAIN_CHOMP_CHAIN_PART_BP_PIVOT) { - struct ChainSegment *segment = &o->parentObj->oChainChompSegments[o->oBehParams2ndByte]; + } else if (o->oBhvParams2ndByte != CHAIN_CHOMP_CHAIN_PART_BP_PIVOT) { + struct ChainSegment *segment = &o->parentObj->oChainChompSegments[o->oBhvParams2ndByte]; // Set position relative to the pivot o->oPosX = o->parentObj->parentObj->oPosX + segment->posX; @@ -256,7 +256,7 @@ static void chain_chomp_released_trigger_cutscene(void) { //! Can delay this if we get into a cutscene-unfriendly action after the // last post ground pound and before this - if (set_mario_npc_dialog(MARIO_DIALOG_LOOK_UP) == MARIO_DIALOG_STATUS_SPEAK + if (set_mario_npc_dialog(MARIO_DIALOG_LOOK_UP) == MARIO_DIALOG_STATUS_SPEAK && (o->oMoveFlags & OBJ_MOVE_MASK_ON_GROUND) && cutscene_object(CUTSCENE_STAR_SPAWN, o) == 1) { o->oChainChompReleaseStatus = CHAIN_CHOMP_RELEASED_LUNGE_AROUND; o->oTimer = 0; @@ -503,7 +503,7 @@ void bhv_wooden_post_update(void) { if (o->oWoodenPostOffsetY != 0.0f) { o->oPosY = o->oHomeY + o->oWoodenPostOffsetY; - } else if (!(o->oBehParams & WOODEN_POST_BP_NO_COINS_MASK)) { + } else if (!(o->oBhvParams & WOODEN_POST_BP_NO_COINS_MASK)) { // Reset the timer once mario is far enough if (o->oDistanceToMario > 400.0f) { o->oTimer = o->oWoodenPostTotalMarioAngle = 0; @@ -535,7 +535,7 @@ void bhv_chain_chomp_gate_update(void) { if (o->parentObj->oChainChompHitGate) { spawn_mist_particles_with_sound(SOUND_GENERAL_WALL_EXPLOSION); set_camera_shake_from_point(SHAKE_POS_SMALL, o->oPosX, o->oPosY, o->oPosZ); - spawn_mist_particles_variable(0, 0x7F, 200.0f); + spawn_mist_particles_variable(0, 127, 200.0f); spawn_triangle_break_particles(30, MODEL_DIRT_ANIMATION, 3.0f, 4); obj_mark_for_deletion(o); } diff --git a/src/game/behaviors/checkerboard_platform.inc.c b/src/game/behaviors/checkerboard_platform.inc.c index bfba5f0a..4b1bd40b 100644 --- a/src/game/behaviors/checkerboard_platform.inc.c +++ b/src/game/behaviors/checkerboard_platform.inc.c @@ -18,14 +18,14 @@ void bhv_checkerboard_elevator_group_init(void) { s32 i; struct Object *sp2C; - if (o->oBehParams2ndByte == 0) { - o->oBehParams2ndByte = 65; + if (o->oBhvParams2ndByte == 0) { + o->oBhvParams2ndByte = 65; } - sp3C = o->oBehParams2ndByte * 10; - sp34 = (o->oBehParams >> 24) & 0xFF; + sp3C = o->oBhvParams2ndByte * 10; + sp34 = (o->oBhvParams >> 24) & 0xFF; - for (i = 0; i < 2; i++) { + for (i = 0; i <= 1; i++) { if (i == 0) { sp38 = -D_8032F754[sp34].unk0; } else { @@ -59,7 +59,7 @@ void checkerboard_plat_act_rotate(s32 a0, s16 a1) { } void bhv_checkerboard_platform_init(void) { - o->oCheckerBoardPlatformUnkFC = o->parentObj->oBehParams2ndByte; + o->oCheckerBoardPlatformUnkFC = o->parentObj->oBhvParams2ndByte; } void bhv_checkerboard_platform_loop(void) { @@ -73,7 +73,7 @@ void bhv_checkerboard_platform_loop(void) { switch (o->oAction) { case 0: - if (o->oBehParams2ndByte == 0) { + if (o->oBhvParams2ndByte == 0) { o->oAction = 1; } else { o->oAction = 3; diff --git a/src/game/behaviors/chuckya.inc.c b/src/game/behaviors/chuckya.inc.c index 6cc87f42..fe625b6e 100644 --- a/src/game/behaviors/chuckya.inc.c +++ b/src/game/behaviors/chuckya.inc.c @@ -8,9 +8,9 @@ struct UnusedChuckyaData { struct UnusedChuckyaData sUnusedChuckyaData[] = { { 2, 0.f, 1.f }, - { 2, 10.f, 1.f }, - { 2, 20.f, 1.f }, - { 2, 20.f, 1.f }, + { 2, 10.f, 1.f }, + { 2, 20.f, 1.f }, + { 2, 20.f, 1.f }, { 8, 10.f, 1.f }, }; @@ -102,11 +102,11 @@ s32 approach_forward_vel(f32 *forwardVel, f32 spC, f32 sp10) { void chuckya_act_0(void) { s32 sp3C; + UNUSED u8 filler[16]; + s32 sp28; #ifdef AVOID_UB sp3C = 0; #endif - UNUSED u8 filler[16]; - s32 sp28; if (o->oTimer == 0) { o->oChuckyaUnkFC = 0; diff --git a/src/game/behaviors/cloud.inc.c b/src/game/behaviors/cloud.inc.c index 0efc7806..05300544 100644 --- a/src/game/behaviors/cloud.inc.c +++ b/src/game/behaviors/cloud.inc.c @@ -22,7 +22,7 @@ static void cloud_act_spawn_parts(void) { s32 i; // Spawn the pieces of the cloud itself - for (i = 0; i < 5; i++) { + for (i = 0; i <= 4; i++) { cloudPart = spawn_object_relative(i, 0, 0, 0, o, MODEL_MIST, bhvCloudPart); if (cloudPart != NULL) { @@ -30,7 +30,7 @@ static void cloud_act_spawn_parts(void) { } } - if (o->oBehParams2ndByte == CLOUD_BP_FWOOSH) { + if (o->oBhvParams2ndByte == CLOUD_BP_FWOOSH) { // Spawn fwoosh's face spawn_object_relative(5, 0, 0, 0, o, MODEL_FWOOSH, bhvCloudPart); @@ -117,7 +117,7 @@ static void cloud_act_main(void) { o->oMoveAngleYaw = o->parentObj->oFaceAngleYaw; } - } else if (o->oBehParams2ndByte != CLOUD_BP_FWOOSH) { + } else if (o->oBhvParams2ndByte != CLOUD_BP_FWOOSH) { // This code should never run, since a lakitu cloud should always have // a parent if (o->oDistanceToMario > 1500.0f) { @@ -138,7 +138,7 @@ static void cloud_act_main(void) { * This action informs the cloud parts to despawn. */ static void cloud_act_unload(void) { - if (o->oBehParams2ndByte != CLOUD_BP_FWOOSH) { + if (o->oBhvParams2ndByte != CLOUD_BP_FWOOSH) { obj_mark_for_deletion(o); } else { o->oAction = CLOUD_ACT_FWOOSH_HIDDEN; @@ -175,10 +175,10 @@ void bhv_cloud_part_update(void) { obj_mark_for_deletion(o); } else { f32 scale = 2.0f / 3.0f * o->parentObj->header.gfx.scale[0]; - s16 angleFromCenter = o->parentObj->oFaceAngleYaw + 0x10000 / 5 * o->oBehParams2ndByte; + s16 angleFromCenter = o->parentObj->oFaceAngleYaw + 0x10000 / 5 * o->oBhvParams2ndByte; // Takes 32 frames to cycle - s16 localOffsetPhase = 0x800 * gGlobalTimer + 0x4000 * o->oBehParams2ndByte; + s16 localOffsetPhase = 0x800 * gGlobalTimer + 0x4000 * o->oBhvParams2ndByte; f32 localOffset; f32 cloudRadius; @@ -186,7 +186,7 @@ void bhv_cloud_part_update(void) { cur_obj_scale(scale); // Cap fwoosh's face size - if (o->oBehParams2ndByte == 5 && scale > 2.0f) { + if (o->oBhvParams2ndByte == 5 && scale > 2.0f) { scale = o->header.gfx.scale[1] = 2.0f; } @@ -198,7 +198,7 @@ void bhv_cloud_part_update(void) { o->oPosX = o->parentObj->oCloudCenterX + cloudRadius * sins(angleFromCenter) + localOffset; o->oPosY = - o->parentObj->oCloudCenterY + localOffset + scale * sCloudPartHeights[o->oBehParams2ndByte]; + o->parentObj->oCloudCenterY + localOffset + scale * sCloudPartHeights[o->oBhvParams2ndByte]; o->oPosZ = o->parentObj->oPosZ + cloudRadius * coss(angleFromCenter) + localOffset; diff --git a/src/game/behaviors/coffin.inc.c b/src/game/behaviors/coffin.inc.c index d675fdcd..32835287 100644 --- a/src/game/behaviors/coffin.inc.c +++ b/src/game/behaviors/coffin.inc.c @@ -63,7 +63,7 @@ void bhv_coffin_spawner_loop(void) { * Also controls laying the coffin down after it has stood up. */ void coffin_act_idle(void) { - if (o->oBehParams2ndByte != COFFIN_BP_STATIC) { + if (o->oBhvParams2ndByte != COFFIN_BP_STATIC) { // Lay down if standing if (o->oFaceAnglePitch != 0) { o->oAngleVelPitch = approach_s16_symmetric(o->oAngleVelPitch, -2000, 200); diff --git a/src/game/behaviors/coin.inc.c b/src/game/behaviors/coin.inc.c index bbd07fcd..ee85eb66 100644 --- a/src/game/behaviors/coin.inc.c +++ b/src/game/behaviors/coin.inc.c @@ -12,17 +12,6 @@ struct ObjectHitbox sYellowCoinHitbox = { /* hurtboxHeight: */ 0, }; -s16 sCoinArrowPositions[][2] = { - { 0, -150 }, - { 0, -50 }, - { 0, 50 }, - { 0, 150 }, - { -50, 100 }, - { -100, 50 }, - { 50, 100 }, - { 100, 50 }, -}; - s32 bhv_coin_sparkles_init(void) { if (o->oInteractStatus & INT_STATUS_INTERACTED && !(o->oInteractStatus & INT_STATUS_TOUCHED_BOB_OMB)) { @@ -66,8 +55,8 @@ void bhv_temp_coin_loop(void) { bhv_coin_sparkles_init(); } -void bhv_coin_init(void) { - o->oVelY = random_float() * 10.0f + 30 + o->oCoinUnk110; +void bhv_spawned_coin_init(void) { + o->oVelY = random_float() * 10.0f + 30.0f + o->oCoinBaseVelY; o->oForwardVel = random_float() * 10.0f; o->oMoveAngleYaw = random_u16(); @@ -76,21 +65,21 @@ void bhv_coin_init(void) { cur_obj_become_intangible(); } -void bhv_coin_loop(void) { - struct Surface *sp1C; +void bhv_spawned_coin_loop(void) { + struct Surface *floor; cur_obj_update_floor_and_walls(); cur_obj_if_hit_wall_bounce_away(); cur_obj_move_standard(-62); - if ((sp1C = o->oFloor) != NULL) { + if ((floor = o->oFloor) != NULL) { if (o->oMoveFlags & OBJ_MOVE_ON_GROUND) { o->oSubAction = 1; } if (o->oSubAction == 1) { o->oBounciness = 0; - if (sp1C->normal.y < 0.9) { - s16 sp1A = atan2s(sp1C->normal.z, sp1C->normal.x); + if (floor->normal.y < 0.9) { + s16 sp1A = atan2s(floor->normal.z, floor->normal.x); cur_obj_rotate_yaw_toward(sp1A, 0x400); } } @@ -100,7 +89,7 @@ void bhv_coin_loop(void) { cur_obj_play_sound_2(SOUND_GENERAL_COIN_SPURT); } - if (o->oVelY < 0) { + if (o->oVelY < 0.0f) { cur_obj_become_tangible(); } @@ -117,12 +106,12 @@ void bhv_coin_loop(void) { if (o->oMoveFlags & OBJ_MOVE_BOUNCE) { #ifndef VERSION_JP - if (o->oCoinUnk1B0 < 5) { + if (o->oCoinNumBounceSoundPlayed < 5) { +#endif cur_obj_play_sound_2(SOUND_GENERAL_COIN_DROP); +#ifndef VERSION_JP } - o->oCoinUnk1B0++; -#else - cur_obj_play_sound_2(SOUND_GENERAL_COIN_DROP); + o->oCoinNumBounceSoundPlayed++; #endif } @@ -139,7 +128,7 @@ void bhv_coin_formation_spawn_loop(void) { obj_set_hitbox(o, &sYellowCoinHitbox); bhv_init_room(); - if (o->oCoinUnkF8) { + if (o->oCoinOnGround) { o->oPosY += 300.0f; cur_obj_update_floor_height(); @@ -157,94 +146,110 @@ void bhv_coin_formation_spawn_loop(void) { } } else { if (bhv_coin_sparkles_init()) { - o->parentObj->oCoinUnkF4 |= bit_shift_left(o->oBehParams2ndByte); + o->parentObj->oCoinCollectedFlags |= bit_shift_left(o->oBhvParams2ndByte); } o->oAnimState++; } - if (o->parentObj->oAction == 2) { + if (o->parentObj->oAction == COIN_FORMATION_ACT_RESPAWN_COINS) { obj_mark_for_deletion(o); } } -void spawn_coin_in_formation(s32 sp50, s32 sp54) { - struct Object *sp4C; - Vec3i sp40; - s32 sp3C = 1; - s32 sp38 = 1; +s16 sCoinArrowPositions[][2] = { + { 0, -150 }, + { 0, -50 }, + { 0, 50 }, + { 0, 150 }, + { -50, 100 }, + { -100, 50 }, + { 50, 100 }, + { 100, 50 }, +}; - sp40[0] = sp40[1] = sp40[2] = 0; +void spawn_coin_in_formation(s32 coinIndex, s32 coinFormationFlags) { + struct Object *coinSpawner; + Vec3i pos; + s32 setSpawner = TRUE; + s32 onGround = TRUE; - switch (sp54 & 7) { - case 0: - sp40[2] = 160 * (sp50 - 2); - if (sp50 > 4) { - sp3C = 0; + pos[0] = pos[1] = pos[2] = 0; + + switch (coinFormationFlags & COIN_FORMATION_BP_FLAG_MASK) { + case COIN_FORMATION_BP_LINE_HORIZONTAL: + pos[2] = 160 * (coinIndex - 2); + if (coinIndex > 4) { + setSpawner = FALSE; } break; - case 1: - sp38 = 0; - sp40[1] = 160 * sp50 * 0.8; // 128 * sp50 - if (sp50 > 4) { - sp3C = 0; + + case COIN_FORMATION_BP_LINE_VERTICAL: + onGround = FALSE; + pos[1] = 160 * coinIndex * 0.8; // 128 * coinIndex + if (coinIndex > 4) { + setSpawner = FALSE; } break; - case 2: - sp40[0] = sins(sp50 << 13) * 300.0f; - sp40[2] = coss(sp50 << 13) * 300.0f; + + case COIN_FORMATION_BP_RING_HORIZONTAL: + pos[0] = sins(coinIndex << 13) * 300.0f; + pos[2] = coss(coinIndex << 13) * 300.0f; break; - case 3: - sp38 = 0; - sp40[0] = coss(sp50 << 13) * 200.0f; - sp40[1] = sins(sp50 << 13) * 200.0f + 200.0f; + + case COIN_FORMATION_BP_RING_VERTICAL: + onGround = FALSE; + pos[0] = coss(coinIndex << 13) * 200.0f; + pos[1] = sins(coinIndex << 13) * 200.0f + 200.0f; break; - case 4: - sp40[0] = sCoinArrowPositions[sp50][0]; - sp40[2] = sCoinArrowPositions[sp50][1]; + + case COIN_FORMATION_BP_ARROW: + pos[0] = sCoinArrowPositions[coinIndex][0]; + pos[2] = sCoinArrowPositions[coinIndex][1]; break; } - if (sp54 & 0x10) { - sp38 = 0; + if (coinFormationFlags & COIN_FORMATION_BP_FLAG_FLYING) { + onGround = FALSE; } - if (sp3C) { - sp4C = spawn_object_relative(sp50, sp40[0], sp40[1], sp40[2], o, MODEL_YELLOW_COIN, - bhvCoinFormationSpawn); - sp4C->oCoinUnkF8 = sp38; + if (setSpawner) { + coinSpawner = spawn_object_relative(coinIndex, pos[0], pos[1], pos[2], o, + MODEL_YELLOW_COIN, bhvCoinFormationSpawn); + coinSpawner->oCoinOnGround = onGround; } } void bhv_coin_formation_init(void) { - o->oCoinUnkF4 = (o->oBehParams >> 8) & 0xFF; + o->oCoinCollectedFlags = (o->oBhvParams >> 8) & 0xFF; } void bhv_coin_formation_loop(void) { - s32 bitIndex; + s32 coinIndex; switch (o->oAction) { - case 0: + case COIN_FORMATION_ACT_SPAWN_COINS: if (o->oDistanceToMario < 2000.0f) { - for (bitIndex = 0; bitIndex < 8; bitIndex++) { - if (!(o->oCoinUnkF4 & (1 << bitIndex))) { - spawn_coin_in_formation(bitIndex, o->oBehParams2ndByte); + for (coinIndex = 0; coinIndex <= 7; coinIndex++) { + if (!(o->oCoinCollectedFlags & (1 << coinIndex))) { + spawn_coin_in_formation(coinIndex, o->oBhvParams2ndByte); } } o->oAction++; } break; - case 1: + + case COIN_FORMATION_ACT_IDLE: if (o->oDistanceToMario > 2100.0f) { o->oAction++; } break; - case 2: - o->oAction = 0; + + case COIN_FORMATION_ACT_RESPAWN_COINS: + o->oAction = COIN_FORMATION_ACT_SPAWN_COINS; break; } - // Casting to u8 doesn't seem to match - set_object_respawn_info_bits(o, o->oCoinUnkF4 & 0xFF); + set_object_respawn_info_bits(o, o->oCoinCollectedFlags & 0xFF); } void coin_inside_boo_act_1(void) { @@ -311,11 +316,11 @@ void bhv_coin_sparkles_loop(void) { } void bhv_golden_coin_sparkles_loop(void) { - struct Object *sp2C; + struct Object *sparkles; UNUSED u8 filler[4]; f32 sp24 = 30.0f; - sp2C = spawn_object(o, MODEL_SPARKLES, bhvCoinSparkles); - sp2C->oPosX += random_float() * sp24 - sp24 / 2; - sp2C->oPosZ += random_float() * sp24 - sp24 / 2; + sparkles = spawn_object(o, MODEL_SPARKLES, bhvCoinSparkles); + sparkles->oPosX += random_float() * sp24 - sp24 / 2; + sparkles->oPosZ += random_float() * sp24 - sp24 / 2; } diff --git a/src/game/behaviors/controllable_platform.inc.c b/src/game/behaviors/controllable_platform.inc.c index ae03dc8a..f8b70745 100644 --- a/src/game/behaviors/controllable_platform.inc.c +++ b/src/game/behaviors/controllable_platform.inc.c @@ -11,7 +11,7 @@ void controllable_platform_act_1(void) { } void controllable_platform_act_2(void) { - if (o->oBehParams2ndByte == D_80331694) { + if (o->oBhvParams2ndByte == D_80331694) { return; } @@ -30,8 +30,8 @@ void bhv_controllable_platform_sub_loop(void) { } if (gMarioObject->platform == o) { - D_80331694 = o->oBehParams2ndByte; -#ifdef VERSION_SH + D_80331694 = o->oBhvParams2ndByte; +#if defined(VERSION_SH) || defined(VERSION_CN) o->parentObj->header.gfx.node.flags &= ~GRAPH_RENDER_INVISIBLE; #endif o->oAction = 1; @@ -61,16 +61,16 @@ void bhv_controllable_platform_init(void) { sp34 = spawn_object_rel_with_rot(o, MODEL_HMC_METAL_ARROW_PLATFORM, bhvControllablePlatformSub, 0, 51, 204, 0, 0, 0); - sp34->oBehParams2ndByte = 1; + sp34->oBhvParams2ndByte = 1; sp34 = spawn_object_rel_with_rot(o, MODEL_HMC_METAL_ARROW_PLATFORM, bhvControllablePlatformSub, 0, 51, -204, 0, -0x8000, 0); - sp34->oBehParams2ndByte = 2; + sp34->oBhvParams2ndByte = 2; sp34 = spawn_object_rel_with_rot(o, MODEL_HMC_METAL_ARROW_PLATFORM, bhvControllablePlatformSub, 204, 51, 0, 0, 0x4000, 0); - sp34->oBehParams2ndByte = 3; + sp34->oBhvParams2ndByte = 3; sp34 = spawn_object_rel_with_rot(o, MODEL_HMC_METAL_ARROW_PLATFORM, bhvControllablePlatformSub, -204, 51, 0, 0, -0x4000, 0); - sp34->oBehParams2ndByte = 4; + sp34->oBhvParams2ndByte = 4; D_80331694 = 0; diff --git a/src/game/behaviors/corkbox.inc.c b/src/game/behaviors/corkbox.inc.c index df2d7955..febecdc6 100644 --- a/src/game/behaviors/corkbox.inc.c +++ b/src/game/behaviors/corkbox.inc.c @@ -43,7 +43,7 @@ void bhv_respawner_loop(void) { if (!is_point_within_radius_of_mario(o->oPosX, o->oPosY, o->oPosZ, o->oRespawnerMinSpawnDist)) { struct Object *spawnedObject = spawn_object(o, o->oRespawnerModelToRespawn, o->oRespawnerBehaviorToRespawn); - spawnedObject->oBehParams = o->oBehParams; + spawnedObject->oBhvParams = o->oBhvParams; o->activeFlags = ACTIVE_FLAG_DEACTIVATED; } } @@ -51,7 +51,7 @@ void bhv_respawner_loop(void) { void create_respawner(s32 model, const BehaviorScript *behToSpawn, s32 minSpawnDist) { struct Object *respawner = spawn_object_abs_with_rot(o, 0, MODEL_NONE, bhvRespawner, o->oHomeX, o->oHomeY, o->oHomeZ, 0, 0, 0); - respawner->oBehParams = o->oBehParams; + respawner->oBhvParams = o->oBhvParams; respawner->oRespawnerModelToRespawn = model; respawner->oRespawnerMinSpawnDist = minSpawnDist; respawner->oRespawnerBehaviorToRespawn = behToSpawn; diff --git a/src/game/behaviors/cruiser.inc.c b/src/game/behaviors/cruiser.inc.c index 71b22c03..d56b87b1 100644 --- a/src/game/behaviors/cruiser.inc.c +++ b/src/game/behaviors/cruiser.inc.c @@ -6,7 +6,7 @@ void bhv_rr_cruiser_wing_init(void) { } void bhv_rr_cruiser_wing_loop(void) { - if (o->oBehParams2ndByte == 0) { + if (o->oBhvParams2ndByte == 0) { o->oFaceAngleYaw = o->oRRCruiserWingUnkF4 + sins(o->oTimer * 0x400) * 8192.0f; o->oFaceAnglePitch = o->oRRCruiserWingUnkF8 + coss(o->oTimer * 0x400) * 2048.0f; } else { diff --git a/src/game/behaviors/ddd_pole.inc.c b/src/game/behaviors/ddd_pole.inc.c index 86e5312a..d465f08d 100644 --- a/src/game/behaviors/ddd_pole.inc.c +++ b/src/game/behaviors/ddd_pole.inc.c @@ -5,7 +5,7 @@ void bhv_ddd_pole_init(void) { obj_mark_for_deletion(o); } else { o->hitboxDownOffset = 100.0f; - o->oDDDPoleMaxOffset = 100.0f * o->oBehParams2ndByte; + o->oDDDPoleMaxOffset = 100.0f * o->oBhvParams2ndByte; } } diff --git a/src/game/behaviors/ddd_warp.inc.c b/src/game/behaviors/ddd_warp.inc.c index 15b00be4..5e97435a 100644 --- a/src/game/behaviors/ddd_warp.inc.c +++ b/src/game/behaviors/ddd_warp.inc.c @@ -1,7 +1,7 @@ // ddd_warp.inc.c void bhv_ddd_warp_loop(void) { - if (gDddPaintingStatus & BOWSERS_SUB_BEATEN) { + if (gDDDPaintingStatus & BOWSERS_SUB_BEATEN) { o->collisionData = segmented_to_virtual(inside_castle_seg7_collision_ddd_warp_2); } else { o->collisionData = segmented_to_virtual(inside_castle_seg7_collision_ddd_warp); diff --git a/src/game/behaviors/donut_platform.inc.c b/src/game/behaviors/donut_platform.inc.c index 4c0eefc5..844ce24b 100644 --- a/src/game/behaviors/donut_platform.inc.c +++ b/src/game/behaviors/donut_platform.inc.c @@ -41,7 +41,7 @@ void bhv_donut_platform_update(void) { if (o->oTimer != 0 && ((o->oMoveFlags & OBJ_MOVE_MASK_ON_GROUND) || o->oDistanceToMario > 2500.0f)) { o->parentObj->oDonutPlatformSpawnerSpawnedPlatforms = o->parentObj->oDonutPlatformSpawnerSpawnedPlatforms - & ((1 << o->oBehParams2ndByte) ^ 0xFFFFFFFF); + & ((1 << o->oBhvParams2ndByte) ^ 0xFFFFFFFF); if (o->oDistanceToMario > 2500.0f) { obj_mark_for_deletion(o); diff --git a/src/game/behaviors/dorrie.inc.c b/src/game/behaviors/dorrie.inc.c index 8919677b..89b24deb 100644 --- a/src/game/behaviors/dorrie.inc.c +++ b/src/game/behaviors/dorrie.inc.c @@ -65,7 +65,7 @@ void dorrie_act_lower_head(void) { if (o->oTimer > 150) { dorrie_begin_head_raise(FALSE); } else if (gMarioObject->platform == o) { - if (o->oDorrieForwardDistToMario > 830.0f + if (o->oDorrieForwardDistToMario > 830.0f && set_mario_npc_dialog(MARIO_DIALOG_LOOK_UP) == MARIO_DIALOG_STATUS_START) { dorrie_begin_head_raise(TRUE); } else if (o->oDorrieForwardDistToMario > 320.0f) { diff --git a/src/game/behaviors/drawbridge.inc.c b/src/game/behaviors/drawbridge.inc.c index 6630b6b5..cb47576c 100644 --- a/src/game/behaviors/drawbridge.inc.c +++ b/src/game/behaviors/drawbridge.inc.c @@ -3,12 +3,12 @@ void bhv_lll_drawbridge_spawner_loop(void) { struct Object *drawbridge1, *drawbridge2; - drawbridge1 = spawn_object(o, MODEL_LLL_DRAWBRIDGE_PART, bhvLllDrawbridge); + drawbridge1 = spawn_object(o, MODEL_LLL_DRAWBRIDGE_PART, bhvLLLDrawbridge); drawbridge1->oMoveAngleYaw = o->oMoveAngleYaw; drawbridge1->oPosX += coss(o->oMoveAngleYaw) * 640.0f; drawbridge1->oPosZ += sins(o->oMoveAngleYaw) * 640.0f; - drawbridge2 = spawn_object(o, MODEL_LLL_DRAWBRIDGE_PART, bhvLllDrawbridge); + drawbridge2 = spawn_object(o, MODEL_LLL_DRAWBRIDGE_PART, bhvLLLDrawbridge); drawbridge2->oMoveAngleYaw = o->oMoveAngleYaw + 0x8000; drawbridge2->oPosX += coss(o->oMoveAngleYaw) * -640.0f; drawbridge2->oPosZ += sins(o->oMoveAngleYaw) * -640.0f; diff --git a/src/game/behaviors/elevator.inc.c b/src/game/behaviors/elevator.inc.c index 7d2ec042..d7968edc 100644 --- a/src/game/behaviors/elevator.inc.c +++ b/src/game/behaviors/elevator.inc.c @@ -101,15 +101,15 @@ void elevator_act_3(void) { } void bhv_elevator_init(void) { - s32 sp1C = sElevatorHeights[o->oBehParams2ndByte * 3 + 2]; + s32 sp1C = sElevatorHeights[o->oBhvParams2ndByte * 3 + 2]; if (sp1C == 0) { - o->oElevatorUnkF4 = sElevatorHeights[o->oBehParams2ndByte * 3]; + o->oElevatorUnkF4 = sElevatorHeights[o->oBhvParams2ndByte * 3]; o->oElevatorUnkF8 = o->oHomeY; o->oElevatorUnkFC = (o->oElevatorUnkF4 + o->oElevatorUnkF8) / 2; - o->oElevatorUnk100 = cur_obj_has_behavior(bhvRrElevatorPlatform); + o->oElevatorUnk100 = cur_obj_has_behavior(bhvRRElevatorPlatform); } else { - o->oElevatorUnkF4 = sElevatorHeights[o->oBehParams2ndByte * 3]; - o->oElevatorUnkF8 = sElevatorHeights[o->oBehParams2ndByte * 3 + 1]; + o->oElevatorUnkF4 = sElevatorHeights[o->oBhvParams2ndByte * 3]; + o->oElevatorUnkF8 = sElevatorHeights[o->oBhvParams2ndByte * 3 + 1]; o->oElevatorUnkFC = (o->oElevatorUnkF4 + o->oElevatorUnkF8) / 2; o->oElevatorUnk100 = 2; } diff --git a/src/game/behaviors/exclamation_box.inc.c b/src/game/behaviors/exclamation_box.inc.c index bc664769..442c88f7 100644 --- a/src/game/behaviors/exclamation_box.inc.c +++ b/src/game/behaviors/exclamation_box.inc.c @@ -12,31 +12,31 @@ struct ObjectHitbox sExclamationBoxHitbox = { /* hurtboxHeight: */ 30, }; -struct Struct802C0DF0 { - u8 unk0; - u8 unk1; - u8 unk2; +struct ExclamationBoxContents { + u8 id; + u8 unused; + u8 bhvParams1stByte; u8 model; const BehaviorScript *behavior; }; -struct Struct802C0DF0 sExclamationBoxContents[] = { - { 0, 0, 0, MODEL_MARIOS_WING_CAP, bhvWingCap }, - { 1, 0, 0, MODEL_MARIOS_METAL_CAP, bhvMetalCap }, - { 2, 0, 0, MODEL_MARIOS_CAP, bhvVanishCap }, - { 3, 0, 0, MODEL_KOOPA_SHELL, bhvKoopaShell }, - { 4, 0, 0, MODEL_YELLOW_COIN, bhvSingleCoinGetsSpawned }, - { 5, 0, 0, MODEL_NONE, bhvThreeCoinsSpawn }, - { 6, 0, 0, MODEL_NONE, bhvTenCoinsSpawn }, - { 7, 0, 0, MODEL_1UP, bhv1upWalking }, - { 8, 0, 0, MODEL_STAR, bhvSpawnedStar }, - { 9, 0, 0, MODEL_1UP, bhv1upRunningAway }, - { 10, 0, 1, MODEL_STAR, bhvSpawnedStar }, - { 11, 0, 2, MODEL_STAR, bhvSpawnedStar }, - { 12, 0, 3, MODEL_STAR, bhvSpawnedStar }, - { 13, 0, 4, MODEL_STAR, bhvSpawnedStar }, - { 14, 0, 5, MODEL_STAR, bhvSpawnedStar }, - { 99, 0, 0, 0, NULL } +struct ExclamationBoxContents sExclamationBoxContents[] = { + { EXCLAMATION_BOX_BP_WING_CAP, 0, 0, MODEL_MARIOS_WING_CAP, bhvWingCap }, + { EXCLAMATION_BOX_BP_METAL_CAP, 0, 0, MODEL_MARIOS_METAL_CAP, bhvMetalCap }, + { EXCLAMATION_BOX_BP_VANISH_CAP, 0, 0, MODEL_MARIOS_CAP, bhvVanishCap }, + { EXCLAMATION_BOX_BP_KOOPA_SHELL, 0, 0, MODEL_KOOPA_SHELL, bhvKoopaShell }, + { EXCLAMATION_BOX_BP_ONE_COIN, 0, 0, MODEL_YELLOW_COIN, bhvSingleCoinGetsSpawned }, + { EXCLAMATION_BOX_BP_THREE_COINS, 0, 0, MODEL_NONE, bhvThreeCoinsSpawn }, + { EXCLAMATION_BOX_BP_TEN_COINS, 0, 0, MODEL_NONE, bhvTenCoinsSpawn }, + { EXCLAMATION_BOX_BP_1UP_WALKING, 0, 0, MODEL_1UP, bhv1UpWalking }, + { EXCLAMATION_BOX_BP_STAR_ACT_1, 0, STAR_INDEX_ACT_1, MODEL_STAR, bhvSpawnedStar }, + { EXCLAMATION_BOX_BP_1UP_RUNNING_AWAY, 0, 0, MODEL_1UP, bhv1UpRunningAway }, + { EXCLAMATION_BOX_BP_STAR_ACT_2, 0, STAR_INDEX_ACT_2, MODEL_STAR, bhvSpawnedStar }, + { EXCLAMATION_BOX_BP_STAR_ACT_3, 0, STAR_INDEX_ACT_3, MODEL_STAR, bhvSpawnedStar }, + { EXCLAMATION_BOX_BP_STAR_ACT_4, 0, STAR_INDEX_ACT_4, MODEL_STAR, bhvSpawnedStar }, + { EXCLAMATION_BOX_BP_STAR_ACT_5, 0, STAR_INDEX_ACT_5, MODEL_STAR, bhvSpawnedStar }, + { EXCLAMATION_BOX_BP_STAR_ACT_6, 0, STAR_INDEX_ACT_6, MODEL_STAR, bhvSpawnedStar }, + { EXCLAMATION_BOX_BP_END, 0, 0, MODEL_NONE, NULL }, }; void bhv_rotating_exclamation_box_loop(void) { @@ -46,28 +46,30 @@ void bhv_rotating_exclamation_box_loop(void) { } void exclamation_box_act_0(void) { - if (o->oBehParams2ndByte < 3) { - o->oAnimState = o->oBehParams2ndByte; - if ((save_file_get_flags() & sCapSaveFlags[o->oBehParams2ndByte]) - || ((o->oBehParams >> 24) & 0xFF)) { + if (o->oBhvParams2ndByte <= EXCLAMATION_BOX_BP_SPECIAL_CAP_END) { + o->oAnimState = o->oBhvParams2ndByte; + if ((save_file_get_flags() & sCapSaveFlags[o->oBhvParams2ndByte]) + || ((o->oBhvParams >> 24) & 0xFF)) { o->oAction = 2; } else { o->oAction = 1; } } else { - o->oAnimState = 3; + o->oAnimState = EXCLAMATION_BOX_ANIM_STATE_DEFAULT; o->oAction = 2; } } void exclamation_box_act_1(void) { cur_obj_become_intangible(); + if (o->oTimer == 0) { spawn_object(o, MODEL_EXCLAMATION_POINT, bhvRotatingExclamationMark); cur_obj_set_model(MODEL_EXCLAMATION_BOX_OUTLINE); } - if ((save_file_get_flags() & sCapSaveFlags[o->oBehParams2ndByte]) - || ((o->oBehParams >> 24) & 0xFF)) { + + if ((save_file_get_flags() & sCapSaveFlags[o->oBhvParams2ndByte]) + || ((o->oBhvParams >> 24) & 0xFF)) { o->oAction = 2; cur_obj_set_model(MODEL_EXCLAMATION_BOX); } @@ -75,6 +77,7 @@ void exclamation_box_act_1(void) { void exclamation_box_act_2(void) { obj_set_hitbox(o, &sExclamationBoxHitbox); + if (o->oTimer == 0) { cur_obj_unhide(); cur_obj_become_tangible(); @@ -82,6 +85,7 @@ void exclamation_box_act_2(void) { o->oPosY = o->oHomeY; o->oGraphYOffset = 0.0f; } + if (cur_obj_was_attacked_or_ground_pounded()) { cur_obj_become_intangible(); o->oExclamationBoxUnkFC = 0x4000; @@ -93,16 +97,20 @@ void exclamation_box_act_2(void) { queue_rumble_data(5, 80); #endif } + load_object_collision_model(); } void exclamation_box_act_3(void) { UNUSED u8 filler[4]; + cur_obj_move_using_fvel_and_gravity(); + if (o->oVelY < 0.0f) { o->oVelY = 0.0f; o->oGravity = 0.0f; } + o->oExclamationBoxUnkF8 = (sins(o->oExclamationBoxUnkFC) + 1.0) * 0.3 + 0.0; o->oExclamationBoxUnkF4 = (-sins(o->oExclamationBoxUnkFC) + 1.0) * 0.5 + 1.0; o->oGraphYOffset = (-sins(o->oExclamationBoxUnkFC) + 1.0) * 26.0; @@ -110,36 +118,38 @@ void exclamation_box_act_3(void) { o->header.gfx.scale[0] = o->oExclamationBoxUnkF4 * 2.0f; o->header.gfx.scale[1] = o->oExclamationBoxUnkF8 * 2.0f; o->header.gfx.scale[2] = o->oExclamationBoxUnkF4 * 2.0f; + if (o->oTimer == 7) { o->oAction = 4; } } -void exclamation_box_spawn_contents(struct Struct802C0DF0 *a0, u8 a1) { - struct Object *sp1C = NULL; +void exclamation_box_spawn_contents(struct ExclamationBoxContents *contents, u8 targetContentsID) { + struct Object *contentsObj = NULL; - while (a0->unk0 != 99) { - if (a1 == a0->unk0) { - sp1C = spawn_object(o, a0->model, a0->behavior); - sp1C->oVelY = 20.0f; - sp1C->oForwardVel = 3.0f; - sp1C->oMoveAngleYaw = gMarioObject->oMoveAngleYaw; - o->oBehParams |= a0->unk2 << 24; - if (a0->model == MODEL_STAR) { + while (contents->id != EXCLAMATION_BOX_BP_END) { + if (targetContentsID == contents->id) { + contentsObj = spawn_object(o, contents->model, contents->behavior); + contentsObj->oVelY = 20.0f; + contentsObj->oForwardVel = 3.0f; + contentsObj->oMoveAngleYaw = gMarioObject->oMoveAngleYaw; + o->oBhvParams |= contents->bhvParams1stByte << 24; + if (contents->model == MODEL_STAR) { o->oFlags |= OBJ_FLAG_PERSISTENT_RESPAWN; } break; } - a0++; + contents++; } } void exclamation_box_act_4(void) { - exclamation_box_spawn_contents(sExclamationBoxContents, o->oBehParams2ndByte); + exclamation_box_spawn_contents(sExclamationBoxContents, o->oBhvParams2ndByte); spawn_mist_particles_variable(0, 0, 46.0f); spawn_triangle_break_particles(20, MODEL_CARTOON_STAR, 0.3f, o->oAnimState); create_sound_spawner(SOUND_GENERAL_BREAK_BOX); - if (o->oBehParams2ndByte < 3) { + + if (o->oBhvParams2ndByte <= EXCLAMATION_BOX_BP_SPECIAL_CAP_END) { o->oAction = 5; cur_obj_hide(); } else { diff --git a/src/game/behaviors/eyerok.inc.c b/src/game/behaviors/eyerok.inc.c index 89799afd..341c6512 100644 --- a/src/game/behaviors/eyerok.inc.c +++ b/src/game/behaviors/eyerok.inc.c @@ -182,7 +182,7 @@ static void eyerok_hand_pound_ground(void) { static void eyerok_hand_act_sleep(void) { if (o->parentObj->oAction != EYEROK_BOSS_ACT_SLEEP - && ++o->oEyerokHandWakeUpTimer > -3 * o->oBehParams2ndByte) { + && ++o->oEyerokHandWakeUpTimer > -3 * o->oBhvParams2ndByte) { if (cur_obj_check_if_near_animation_end()) { o->parentObj->oEyerokBossNumHands++; o->oAction = EYEROK_HAND_ACT_IDLE; @@ -190,19 +190,19 @@ static void eyerok_hand_act_sleep(void) { } else { approach_f32_ptr(&o->oPosX, o->oHomeX, 15.0f); o->oPosY = o->oHomeY - + (200 * o->oBehParams2ndByte + 400) + + (200 * o->oBhvParams2ndByte + 400) * sins((s16)(absf(o->oPosX - o->oHomeX) / 724.0f * 0x8000)); obj_face_yaw_approach(o->oMoveAngleYaw, 400); } } else { - if (o->oBehParams2ndByte < 0) { + if (o->oBhvParams2ndByte < 0) { o->collisionData = segmented_to_virtual(&ssl_seg7_collision_070284B0); } else { o->collisionData = segmented_to_virtual(&ssl_seg7_collision_07028370); } cur_obj_reverse_animation(); - o->oPosX = o->oHomeX + 724.0f * o->oBehParams2ndByte; + o->oPosX = o->oHomeX + 724.0f * o->oBhvParams2ndByte; } } @@ -216,7 +216,7 @@ static void eyerok_hand_act_idle(void) { o->oGravity = 0.0f; } } else if (o->parentObj->oEyerokBossUnk1AC == 0 && o->parentObj->oEyerokBossActiveHand != 0) { - if (o->parentObj->oEyerokBossActiveHand == o->oBehParams2ndByte) { + if (o->parentObj->oEyerokBossActiveHand == o->oBhvParams2ndByte) { if (eyerok_check_mario_relative_z(400) || random_u16() % 2 != 0) { o->oAction = EYEROK_HAND_ACT_TARGET_MARIO; o->oMoveAngleYaw = o->oAngleToMario; @@ -242,7 +242,7 @@ static void eyerok_hand_act_idle(void) { } static void eyerok_hand_act_open(void) { - o->parentObj->oEyerokBossUnk1AC = o->oBehParams2ndByte; + o->parentObj->oEyerokBossUnk1AC = o->oBhvParams2ndByte; if (cur_obj_init_anim_and_check_if_end(4)) { o->oAction = EYEROK_HAND_ACT_SHOW_EYE; @@ -271,7 +271,7 @@ static void eyerok_hand_act_show_eye(void) { if (o->oAnimState < 3) { o->oAnimState++; } else if (cur_obj_check_if_near_animation_end()) { - UNUSED s16 val06 = (s16)(o->oAngleToMario - o->oFaceAngleYaw) * o->oBehParams2ndByte; + UNUSED s16 val06 = (s16)(o->oAngleToMario - o->oFaceAngleYaw) * o->oBhvParams2ndByte; o->oAction = EYEROK_HAND_ACT_CLOSE; } } else { @@ -303,7 +303,7 @@ static void eyerok_hand_act_close(void) { if (o->parentObj->oEyerokBossNumHands != 2) { o->oAction = EYEROK_HAND_ACT_RETREAT; - o->parentObj->oEyerokBossActiveHand = o->oBehParams2ndByte; + o->parentObj->oEyerokBossActiveHand = o->oBhvParams2ndByte; } else if (o->parentObj->oEyerokBossActiveHand == 0) { o->oAction = EYEROK_HAND_ACT_IDLE; o->parentObj->oEyerokBossUnk1AC = 0; @@ -331,7 +331,7 @@ static void eyerok_hand_act_recover(void) { static void eyerok_hand_act_become_active(void) { if (o->parentObj->oEyerokBossActiveHand == 0 || o->parentObj->oEyerokBossNumHands != 2) { o->oAction = EYEROK_HAND_ACT_RETREAT; - o->parentObj->oEyerokBossActiveHand = o->oBehParams2ndByte; + o->parentObj->oEyerokBossActiveHand = o->oBhvParams2ndByte; } } @@ -363,9 +363,9 @@ static void eyerok_hand_act_retreat(void) { if (approach_f32_ptr(&o->oPosY, o->oHomeY, 20.0f) && distToHome == 0.0f && o->oFaceAngleYaw == 0) { o->oAction = EYEROK_HAND_ACT_IDLE; - o->parentObj->oEyerokBossActiveHand -= o->oBehParams2ndByte; + o->parentObj->oEyerokBossActiveHand -= o->oBhvParams2ndByte; - if (o->parentObj->oEyerokBossUnk1AC == o->oBehParams2ndByte) { + if (o->parentObj->oEyerokBossUnk1AC == o->oBhvParams2ndByte) { o->parentObj->oEyerokBossUnk1AC = 0; } } @@ -439,12 +439,12 @@ static void eyerok_hand_act_fist_sweep(void) { static void eyerok_hand_act_begin_double_pound(void) { if (o->parentObj->oEyerokBossUnk104 < 0 - || o->parentObj->oEyerokBossActiveHand == o->oBehParams2ndByte) { + || o->parentObj->oEyerokBossActiveHand == o->oBhvParams2ndByte) { o->oAction = EYEROK_HAND_ACT_DOUBLE_POUND; o->oMoveAngleYaw = (s32)(o->oFaceAngleYaw - 0x4000 * o->parentObj->oEyerokBossUnk108); } else { f32 sp4 = o->parentObj->oPosX + 400.0f * o->parentObj->oEyerokBossUnk108 - - 180.0f * o->oBehParams2ndByte; + - 180.0f * o->oBhvParams2ndByte; o->oPosX = o->oHomeX + (sp4 - o->oHomeX) * o->parentObj->oEyerokBossUnk110; o->oPosY = o->oHomeY + 300.0f * o->parentObj->oEyerokBossUnk110; @@ -455,13 +455,13 @@ static void eyerok_hand_act_begin_double_pound(void) { static void eyerok_hand_act_double_pound(void) { if (o->parentObj->oEyerokBossNumHands != 2) { - o->parentObj->oEyerokBossActiveHand = o->oBehParams2ndByte; + o->parentObj->oEyerokBossActiveHand = o->oBhvParams2ndByte; } if (o->parentObj->oEyerokBossUnk104 == 1) { o->oAction = EYEROK_HAND_ACT_RETREAT; - o->parentObj->oEyerokBossUnk1AC = o->oBehParams2ndByte; - } else if (o->parentObj->oEyerokBossActiveHand == o->oBehParams2ndByte) { + o->parentObj->oEyerokBossUnk1AC = o->oBhvParams2ndByte; + } else if (o->parentObj->oEyerokBossActiveHand == o->oBhvParams2ndByte) { if (o->oMoveFlags & OBJ_MOVE_MASK_ON_GROUND) { if (o->oGravity < -15.0f) { o->parentObj->oEyerokBossActiveHand = 0; @@ -540,5 +540,5 @@ void bhv_eyerok_hand_loop(void) { } load_object_collision_model(); - o->header.gfx.scale[0] = 1.5f * o->oBehParams2ndByte; + o->header.gfx.scale[0] = 1.5f * o->oBhvParams2ndByte; } diff --git a/src/game/behaviors/falling_pillar.inc.c b/src/game/behaviors/falling_pillar.inc.c index 6d8fe380..9ebaad68 100644 --- a/src/game/behaviors/falling_pillar.inc.c +++ b/src/game/behaviors/falling_pillar.inc.c @@ -128,7 +128,7 @@ void bhv_falling_pillar_hitbox_loop(void) { f32 x = o->parentObj->oPosX; f32 y = o->parentObj->oPosY; f32 z = o->parentObj->oPosZ; - f32 yOffset = o->oBehParams2ndByte * 400 + 300; + f32 yOffset = o->oBhvParams2ndByte * 400 + 300; // Update position of hitboxes so they fall with the pillar. o->oPosX = sins(pitch) * sins(yaw) * yOffset + x; diff --git a/src/game/behaviors/falling_rising_platform.inc.c b/src/game/behaviors/falling_rising_platform.inc.c index 38dd7192..6616deed 100644 --- a/src/game/behaviors/falling_rising_platform.inc.c +++ b/src/game/behaviors/falling_rising_platform.inc.c @@ -1,14 +1,14 @@ // falling_rising_platform.inc.c void bhv_squishable_platform_loop(void) { - o->header.gfx.scale[1] = (sins(o->oBitfsPlatformTimer) + 1.0) * 0.3 + 0.4; - o->oBitfsPlatformTimer += 0x80; + o->header.gfx.scale[1] = (sins(o->oBitFSPlatformTimer) + 1.0) * 0.3 + 0.4; + o->oBitFSPlatformTimer += 0x80; } void bhv_bitfs_sinking_platform_loop(void) { //! f32 double conversion error accumulates on Wii VC causing the platform to rise up - o->oPosY -= sins(o->oBitfsPlatformTimer) * 0.58; - o->oBitfsPlatformTimer += 0x100; + o->oPosY -= sins(o->oBitFSPlatformTimer) * 0.58; + o->oBitFSPlatformTimer += 0x100; } // TODO: Named incorrectly. fix @@ -17,14 +17,14 @@ void bhv_ddd_moving_pole_loop(void) { } void bhv_bitfs_sinking_cage_platform_loop(void) { - if (o->oBehParams2ndByte != 0) { + if (o->oBhvParams2ndByte != 0) { if (o->oTimer == 0) { o->oPosY -= 300.0f; } - o->oPosY += sins(o->oBitfsPlatformTimer) * 7.0f; + o->oPosY += sins(o->oBitFSPlatformTimer) * 7.0f; } else { - o->oPosY -= sins(o->oBitfsPlatformTimer) * 3.0f; + o->oPosY -= sins(o->oBitFSPlatformTimer) * 3.0f; } - o->oBitfsPlatformTimer += 0x100; + o->oBitFSPlatformTimer += 0x100; } diff --git a/src/game/behaviors/ferris_wheel.inc.c b/src/game/behaviors/ferris_wheel.inc.c index 2fdaf047..2a98887d 100644 --- a/src/game/behaviors/ferris_wheel.inc.c +++ b/src/game/behaviors/ferris_wheel.inc.c @@ -32,16 +32,16 @@ void bhv_ferris_wheel_axle_init(void) { s32 i; o->collisionData = - segmented_to_virtual(sFerrisWheelProperties[o->oBehParams2ndByte].axleCollision); + segmented_to_virtual(sFerrisWheelProperties[o->oBhvParams2ndByte].axleCollision); for (i = 0; i < 4; i++) { platform = spawn_object_relative(i, 0, 0, 0, o, - sFerrisWheelProperties[o->oBehParams2ndByte].platformModel, + sFerrisWheelProperties[o->oBhvParams2ndByte].platformModel, bhvFerrisWheelPlatform); if (platform != NULL) { platform->collisionData = - segmented_to_virtual(sFerrisWheelProperties[o->oBehParams2ndByte].platformCollision); + segmented_to_virtual(sFerrisWheelProperties[o->oBhvParams2ndByte].platformCollision); } } } @@ -56,7 +56,7 @@ void bhv_ferris_wheel_platform_update(void) { obj_perform_position_op(POS_OP_SAVE_POSITION); - offsetAngle = o->parentObj->oFaceAngleRoll + o->oBehParams2ndByte * 0x4000; + offsetAngle = o->parentObj->oFaceAngleRoll + o->oBhvParams2ndByte * 0x4000; offsetXZ = 400.0f * coss(offsetAngle); o->oPosX = o->parentObj->oPosX + offsetXZ * sins(o->parentObj->oMoveAngleYaw) diff --git a/src/game/behaviors/fire_piranha_plant.inc.c b/src/game/behaviors/fire_piranha_plant.inc.c index be1ea9cb..1982b4ed 100644 --- a/src/game/behaviors/fire_piranha_plant.inc.c +++ b/src/game/behaviors/fire_piranha_plant.inc.c @@ -33,14 +33,14 @@ s32 sNumActiveFirePiranhaPlants; s32 sNumKilledFirePiranhaPlants; void bhv_fire_piranha_plant_init(void) { - o->oFirePiranhaPlantNeutralScale = D_80331B5C[(u16)(o->oBehParams >> 16)]; + o->oFirePiranhaPlantNeutralScale = D_80331B5C[(u16)(o->oBhvParams >> 16)]; obj_set_hitbox(o, &sFirePiranhaPlantHitbox); - if ((u16)(o->oBehParams >> 16) != 0) { + if ((u16)(o->oBhvParams >> 16) != 0) { o->oFlags |= OBJ_FLAG_PERSISTENT_RESPAWN; o->oHealth = 1; - if (o->oBehParams & 0x0000FF00) { + if (o->oBhvParams & 0x0000FF00) { o->oNumLootCoins = 0; } else { o->oNumLootCoins = 2; @@ -67,7 +67,7 @@ static void fire_piranha_plant_act_hide(void) { sNumActiveFirePiranhaPlants--; o->oFirePiranhaPlantActive = FALSE; - if ((u16)(o->oBehParams >> 16) != 0 && o->oHealth == 0) { + if ((u16)(o->oBhvParams >> 16) != 0 && o->oHealth == 0) { if (++sNumKilledFirePiranhaPlants == 5) { spawn_default_star(-6300.0f, -1850.0f, -6300.0f); } diff --git a/src/game/behaviors/fish.inc.c b/src/game/behaviors/fish.inc.c index 7ef29699..a4d8093c 100644 --- a/src/game/behaviors/fish.inc.c +++ b/src/game/behaviors/fish.inc.c @@ -5,8 +5,8 @@ */ /** - * Spawns fish with settings chosen by oBehParams2ndByte. - * These settings are animations, colour, and spawn quantity. + * Spawns fish with settings chosen by oBhvParams2ndByte. + * These settings are animations, color, and spawn quantity. */ static void fish_spawner_act_spawn(void) { s32 i; @@ -15,7 +15,7 @@ static void fish_spawner_act_spawn(void) { f32 minDistToMario; const struct Animation * const *fishAnimation; - switch (o->oBehParams2ndByte) { + switch (o->oBhvParams2ndByte) { // Cases need to be on one line to match with and without optimizations. case FISH_SPAWNER_BP_MANY_BLUE: model = MODEL_FISH; schoolQuantity = 20; minDistToMario = 1500.0f; fishAnimation = blue_fish_seg3_anims_0301C2B0; @@ -40,7 +40,7 @@ static void fish_spawner_act_spawn(void) { if (o->oDistanceToMario < minDistToMario || gCurrLevelNum == LEVEL_SA) { for (i = 0; i < schoolQuantity; i++) { struct Object *fishObject = spawn_object(o, model, bhvFish); - fishObject->oBehParams2ndByte = o->oBehParams2ndByte; + fishObject->oBhvParams2ndByte = o->oBhvParams2ndByte; obj_init_animation_with_sound(fishObject, fishAnimation, 0); obj_translate_xyz_random(fishObject, 700.0f); } @@ -81,7 +81,7 @@ void bhv_fish_spawner_loop(void) { static void fish_vertical_roam(s32 speed) { f32 parentY = o->parentObj->oPosY; - // If the stage is Secret Aquarium, the fish can + // If the stage is Secret Aquarium, the fish can // travel as far vertically as they wish. if (gCurrLevelNum == LEVEL_SA) { if (500.0f < absf(o->oPosY - o->oFishGoalY)) { diff --git a/src/game/behaviors/flame.inc.c b/src/game/behaviors/flame.inc.c index 801b1fa5..f33aaf18 100644 --- a/src/game/behaviors/flame.inc.c +++ b/src/game/behaviors/flame.inc.c @@ -1,7 +1,7 @@ // flame.inc.c void bhv_small_piranha_flame_loop(void) { - if ((u16)(o->oBehParams >> 16) == 0) { + if ((u16)(o->oBhvParams >> 16) == 0) { if (o->oTimer > 0) { obj_mark_for_deletion(o); } else { diff --git a/src/game/behaviors/flamethrower.inc.c b/src/game/behaviors/flamethrower.inc.c index ae0922aa..b2c0fc9b 100644 --- a/src/game/behaviors/flamethrower.inc.c +++ b/src/game/behaviors/flamethrower.inc.c @@ -9,13 +9,13 @@ void bhv_flamethrower_flame_loop(void) { obj_translate_xyz_random(o, 10.0f); } - if (o->oBehParams2ndByte == 2) { + if (o->oBhvParams2ndByte == 2) { scale = o->oTimer * (o->oForwardVel - 6.0f) / 100.0 + 2.0; } else { scale = o->oTimer * (o->oForwardVel - 20.0) / 100.0 + 1.0; } - if (o->oBehParams2ndByte == 3) { + if (o->oBhvParams2ndByte == 3) { o->hitboxHeight = 200.0f; o->hitboxDownOffset = 150.0f; o->oVelY = -28.0f; @@ -34,7 +34,7 @@ void bhv_flamethrower_flame_loop(void) { cur_obj_scale(scale); - if (o->oBehParams2ndByte == 4) { + if (o->oBhvParams2ndByte == 4) { o->oPosY += o->oForwardVel; // weird? } else { cur_obj_move_using_fvel_and_gravity(); @@ -63,11 +63,11 @@ void bhv_flamethrower_loop(void) { model = MODEL_RED_FLAME; flameVel = 95.0f; - if (o->oBehParams2ndByte == 1) { + if (o->oBhvParams2ndByte == 1) { model = MODEL_BLUE_FLAME; } - if (o->oBehParams2ndByte == 2) { + if (o->oBhvParams2ndByte == 2) { flameVel = 50.0f; } @@ -83,7 +83,7 @@ void bhv_flamethrower_loop(void) { o->oFlameThowerUnk110 = sp34; - flame = spawn_object_relative(o->oBehParams2ndByte, 0, 0, 0, o, model, bhvFlamethrowerFlame); + flame = spawn_object_relative(o->oBhvParams2ndByte, 0, 0, 0, o, model, bhvFlamethrowerFlame); flame->oForwardVel = flameVel; cur_obj_play_sound_1(SOUND_AIR_BLOW_FIRE); diff --git a/src/game/behaviors/fly_guy.inc.c b/src/game/behaviors/fly_guy.inc.c index d5911582..afc6c01d 100644 --- a/src/game/behaviors/fly_guy.inc.c +++ b/src/game/behaviors/fly_guy.inc.c @@ -71,7 +71,7 @@ static void fly_guy_act_approach_mario(void) { if (abs_angle_diff(o->oAngleToMario, o->oFaceAngleYaw) < 0x2000 && (o->oPosY - gMarioObject->oPosY > 400.0f || o->oDistanceToMario < 400.0f)) { // Either shoot fire or lunge - if (o->oBehParams2ndByte != 0 && random_u16() % 2) { + if (o->oBhvParams2ndByte != FLY_GUY_BP_GENERIC && random_u16() % 2) { o->oAction = FLY_GUY_ACT_SHOOT_FIRE; o->oFlyGuyScaleVel = 0.06f; } else { diff --git a/src/game/behaviors/flying_bookend_switch.inc.c b/src/game/behaviors/flying_bookend_switch.inc.c index 91d7fdc9..9ea647ad 100644 --- a/src/game/behaviors/flying_bookend_switch.inc.c +++ b/src/game/behaviors/flying_bookend_switch.inc.c @@ -270,7 +270,7 @@ void bhv_book_switch_loop(void) { cur_obj_become_intangible(); if (approach_f32_ptr(&o->oBookSwitchUnkF4, 0.0f, 20.0f) && o->oAction != 0) { - if (o->parentObj->oBookSwitchManagerUnkF4 == o->oBehParams2ndByte) { + if (o->parentObj->oBookSwitchManagerUnkF4 == o->oBhvParams2ndByte) { play_sound(SOUND_GENERAL2_RIGHT_ANSWER, gGlobalSoundSource); o->parentObj->oBookSwitchManagerUnkF4++; } else { diff --git a/src/game/behaviors/goomba.inc.c b/src/game/behaviors/goomba.inc.c index 7089c34f..b0e55384 100644 --- a/src/game/behaviors/goomba.inc.c +++ b/src/game/behaviors/goomba.inc.c @@ -80,15 +80,15 @@ void bhv_goomba_triplet_spawner_update(void) { // is not used in the game s32 dAngle = 0x10000 - / (((o->oBehParams2ndByte & GOOMBA_TRIPLET_SPAWNER_BP_EXTRA_GOOMBAS_MASK) >> 2) + 3); + / (((o->oBhvParams2ndByte & GOOMBA_TRIPLET_SPAWNER_BP_EXTRA_GOOMBAS_MASK) >> 2) + 3); for (angle = 0, goombaFlag = 1 << 8; angle < 0xFFFF; angle += dAngle, goombaFlag <<= 1) { // Only spawn goombas which haven't been killed yet - if (!(o->oBehParams & goombaFlag)) { + if (!(o->oBhvParams & goombaFlag)) { s16 dx = 500.0f * coss(angle); s16 dz = 500.0f * sins(angle); - spawn_object_relative((o->oBehParams2ndByte & GOOMBA_TRIPLET_SPAWNER_BP_SIZE_MASK) + spawn_object_relative((o->oBhvParams2ndByte & GOOMBA_BP_SIZE_MASK) | (goombaFlag >> 6), dx, 0, dz, o, MODEL_GOOMBA, bhvGoomba); } } @@ -106,7 +106,7 @@ void bhv_goomba_triplet_spawner_update(void) { * Initialization function for goomba. */ void bhv_goomba_init(void) { - o->oGoombaSize = o->oBehParams2ndByte & GOOMBA_BP_SIZE_MASK; + o->oGoombaSize = o->oBhvParams2ndByte & GOOMBA_BP_SIZE_MASK; o->oGoombaScale = sGoombaProperties[o->oGoombaSize].scale; o->oDeathSound = sGoombaProperties[o->oGoombaSize].deathSound; @@ -138,10 +138,10 @@ static void goomba_begin_jump(void) { static void mark_goomba_as_dead(void) { if (o->parentObj != o) { set_object_respawn_info_bits( - o->parentObj, (o->oBehParams2ndByte & GOOMBA_BP_TRIPLET_FLAG_MASK) >> 2); + o->parentObj, (o->oBhvParams2ndByte & GOOMBA_BP_TRIPLET_RESPAWN_FLAG_MASK) >> 2); - o->parentObj->oBehParams = - o->parentObj->oBehParams | (o->oBehParams2ndByte & GOOMBA_BP_TRIPLET_FLAG_MASK) << 6; + o->parentObj->oBhvParams = + o->parentObj->oBhvParams | (o->oBhvParams2ndByte & GOOMBA_BP_TRIPLET_RESPAWN_FLAG_MASK) << 6; } } diff --git a/src/game/behaviors/grill_door.inc.c b/src/game/behaviors/grill_door.inc.c index 99ce3583..6c309ebf 100644 --- a/src/game/behaviors/grill_door.inc.c +++ b/src/game/behaviors/grill_door.inc.c @@ -18,7 +18,7 @@ void bhv_openable_cage_door_loop(void) { } } else if (o->oAction == 1) { if (o->oTimer < 64) { - o->oMoveAngleYaw -= o->oBehParams2ndByte * 0x100; + o->oMoveAngleYaw -= o->oBhvParams2ndByte * 0x100; } else { o->oAction++; } @@ -26,41 +26,41 @@ void bhv_openable_cage_door_loop(void) { } void bhv_openable_grill_loop(void) { - struct Object *grillObj; + struct Object *obj; s32 grillIdx; switch (o->oAction) { case 0: - grillIdx = o->oBehParams2ndByte; + grillIdx = o->oBhvParams2ndByte; - grillObj = spawn_object_relative(-1, gOpenableGrills[grillIdx].halfWidth, 0, 0, o, - gOpenableGrills[grillIdx].modelID, bhvOpenableCageDoor); - grillObj->oMoveAngleYaw += 0x8000; - obj_set_collision_data(grillObj, gOpenableGrills[grillIdx].collision); + obj = spawn_object_relative(-1, gOpenableGrills[grillIdx].halfWidth, 0, 0, o, + gOpenableGrills[grillIdx].modelID, bhvOpenableCageDoor); + obj->oMoveAngleYaw += 0x8000; + obj_set_collision_data(obj, gOpenableGrills[grillIdx].collision); - grillObj = spawn_object_relative(1, -gOpenableGrills[grillIdx].halfWidth, 0, 0, o, - gOpenableGrills[grillIdx].modelID, bhvOpenableCageDoor); - obj_set_collision_data(grillObj, gOpenableGrills[grillIdx].collision); + obj = spawn_object_relative(1, -gOpenableGrills[grillIdx].halfWidth, 0, 0, o, + gOpenableGrills[grillIdx].modelID, bhvOpenableCageDoor); + obj_set_collision_data(obj, gOpenableGrills[grillIdx].collision); o->oAction++; break; case 1: - if ((o->oOpenableGrillUnkF4 = + if ((o->oOpenableGrillPurpleSwitch = cur_obj_nearest_object_with_behavior(bhvFloorSwitchGrills)) != NULL) { o->oAction++; } break; case 2: - grillObj = o->oOpenableGrillUnkF4; + obj = o->oOpenableGrillPurpleSwitch; - if (grillObj->oAction == 2) { + if (obj->oAction == PURPLE_SWITCH_ACT_TICKING) { o->oOpenableGrillUnk88 = 2; cur_obj_play_sound_2(SOUND_GENERAL_CAGE_OPEN); o->oAction++; - if (o->oBehParams2ndByte != 0) { + if (o->oBhvParams2ndByte != OPENABLE_GRILL_BP_BOB) { play_puzzle_jingle(); } } diff --git a/src/game/behaviors/ground_particles.inc.c b/src/game/behaviors/ground_particles.inc.c index aff00af5..56ee9547 100644 --- a/src/game/behaviors/ground_particles.inc.c +++ b/src/game/behaviors/ground_particles.inc.c @@ -6,7 +6,7 @@ void bhv_pound_white_puffs_init(void) { } static struct SpawnParticlesInfo sGlobalMistParticles = { - /* behParam: */ 3, + /* bhvParam: */ 3, /* count: */ 20, /* model: */ MODEL_MIST, /* offsetY: */ 20, @@ -25,7 +25,7 @@ void spawn_mist_from_global(void) { } static struct SpawnParticlesInfo sSandParticles = { - /* behParam: */ 0, + /* bhvParam: */ 0, /* count: */ 5, /* model: */ MODEL_SAND_DUST, /* offsetY: */ 0, @@ -62,7 +62,7 @@ void clear_particle_flags(u32 flags) { } static struct SpawnParticlesInfo sSnowParticles = { - /* behParam: */ 0, + /* bhvParam: */ 0, /* count: */ 5, /* model: */ MODEL_WHITE_PARTICLE_DL, /* offsetY: */ 0, diff --git a/src/game/behaviors/heave_ho.inc.c b/src/game/behaviors/heave_ho.inc.c index 2a8ab260..cd43a2c7 100644 --- a/src/game/behaviors/heave_ho.inc.c +++ b/src/game/behaviors/heave_ho.inc.c @@ -1,7 +1,9 @@ // heave_ho.inc.c -s16 D_8032F460[][2] = { { 30, 0 }, { 42, 1 }, { 52, 0 }, { 64, 1 }, { 74, 0 }, - { 86, 1 }, { 96, 0 }, { 108, 1 }, { 118, 0 }, { -1, 0 }, }; +s16 D_8032F460[][2] = { + { 30, 0 }, { 42, 1 }, { 52, 0 }, { 64, 1 }, { 74, 0 }, + { 86, 1 }, { 96, 0 }, { 108, 1 }, { 118, 0 }, { -1, 0 }, +}; void bhv_heave_ho_throw_mario_loop(void) { o->oParentRelativePosX = 200.0f; diff --git a/src/game/behaviors/hidden_star.inc.c b/src/game/behaviors/hidden_star.inc.c index 9dd2c1e3..f041a24a 100644 --- a/src/game/behaviors/hidden_star.inc.c +++ b/src/game/behaviors/hidden_star.inc.c @@ -6,7 +6,7 @@ void bhv_hidden_star_init(void) { if (count == 0) { struct Object *star = spawn_object_abs_with_rot(o, 0, MODEL_STAR, bhvStar, o->oPosX, o->oPosY, o->oPosZ, 0, 0, 0); - star->oBehParams = o->oBehParams; + star->oBhvParams = o->oBhvParams; o->activeFlags = ACTIVE_FLAG_DEACTIVATED; } diff --git a/src/game/behaviors/hoot.inc.c b/src/game/behaviors/hoot.inc.c index 238d2754..d7f6cfde 100644 --- a/src/game/behaviors/hoot.inc.c +++ b/src/game/behaviors/hoot.inc.c @@ -255,7 +255,7 @@ void bhv_hoot_loop(void) { case HOOT_AVAIL_WANTS_TO_TALK: hoot_awake_loop(); - if (set_mario_npc_dialog(MARIO_DIALOG_LOOK_UP) == MARIO_DIALOG_STATUS_SPEAK + if (set_mario_npc_dialog(MARIO_DIALOG_LOOK_UP) == MARIO_DIALOG_STATUS_SPEAK && cutscene_object_with_dialog(CUTSCENE_DIALOG, o, DIALOG_044)) { set_mario_npc_dialog(MARIO_DIALOG_STOP); diff --git a/src/game/behaviors/intro_lakitu.inc.c b/src/game/behaviors/intro_lakitu.inc.c index 7ca8055d..a41d5cf5 100644 --- a/src/game/behaviors/intro_lakitu.inc.c +++ b/src/game/behaviors/intro_lakitu.inc.c @@ -82,7 +82,7 @@ void bhv_intro_lakitu_loop(void) { o->oIntroLakituSplineSegment = 0.0f; o->oIntroLakituSplineSegmentProgress = 0.0f; o->oIntroLakituCloud = - spawn_object_relative_with_scale(1, 0, 0, 0, 2.0f, o, MODEL_MIST, bhvCloud); + spawn_object_relative_with_scale(CLOUD_BP_LAKITU_CLOUD, 0, 0, 0, 2.0f, o, MODEL_MIST, bhvCloud); if (gCamera->cutscene == CUTSCENE_END_WAVING) { o->oAction = 100; @@ -110,7 +110,7 @@ void bhv_intro_lakitu_loop(void) { } switch (o->oTimer) { -#if defined(VERSION_US) || defined(VERSION_SH) +#if defined(VERSION_US) || defined(VERSION_SH) || defined(VERSION_CN) case 534: cur_obj_play_sound_2(SOUND_ACTION_FLYING_FAST); break; diff --git a/src/game/behaviors/jrb_ship.inc.c b/src/game/behaviors/jrb_ship.inc.c index 0918d8d0..b675b3dc 100644 --- a/src/game/behaviors/jrb_ship.inc.c +++ b/src/game/behaviors/jrb_ship.inc.c @@ -51,18 +51,18 @@ void bhv_jrb_sliding_box_loop(void) { Vec3f sp20; s16 sp1E; - if (o->oJrbSlidingBoxUnkF4 == NULL) { + if (o->oJRBSlidingBoxUnkF4 == NULL) { sp3C = cur_obj_nearest_object_with_behavior(bhvInSunkenShip3); if (sp3C != NULL) { // NULL check only for assignment, not for dereference? - o->oJrbSlidingBoxUnkF4 = sp3C; + o->oJRBSlidingBoxUnkF4 = sp3C; } o->oParentRelativePosX = o->oPosX - sp3C->oPosX; o->oParentRelativePosY = o->oPosY - sp3C->oPosY; o->oParentRelativePosZ = o->oPosZ - sp3C->oPosZ; } else { - sp3C = o->oJrbSlidingBoxUnkF4; + sp3C = o->oJRBSlidingBoxUnkF4; sp40[0] = sp3C->oFaceAnglePitch; sp40[1] = sp3C->oFaceAngleYaw; @@ -96,17 +96,17 @@ void bhv_jrb_sliding_box_loop(void) { o->oFaceAnglePitch = sp1E; } - o->oJrbSlidingBoxUnkFC = sins(o->oJrbSlidingBoxUnkF8) * 20.0f; - o->oJrbSlidingBoxUnkF8 += 0x100; - o->oParentRelativePosZ += o->oJrbSlidingBoxUnkFC; + o->oJRBSlidingBoxUnkFC = sins(o->oJRBSlidingBoxUnkF8) * 20.0f; + o->oJRBSlidingBoxUnkF8 += 0x100; + o->oParentRelativePosZ += o->oJRBSlidingBoxUnkFC; - if (gMarioObject->oPosY > 1000.0f && absf(o->oJrbSlidingBoxUnkFC) > 3.0f) { + if (gMarioObject->oPosY > 1000.0f && absf(o->oJRBSlidingBoxUnkFC) > 3.0f) { cur_obj_play_sound_1(SOUND_AIR_ROUGH_SLIDE); } obj_set_hitbox(o, &sSkullSlidingBoxHitbox); - if (!(o->oJrbSlidingBoxUnkF8 & 0x7FFF)) { + if (!(o->oJRBSlidingBoxUnkF8 & 0x7FFF)) { cur_obj_become_tangible(); } diff --git a/src/game/behaviors/king_bobomb.inc.c b/src/game/behaviors/king_bobomb.inc.c index 3c35449d..56736263 100644 --- a/src/game/behaviors/king_bobomb.inc.c +++ b/src/game/behaviors/king_bobomb.inc.c @@ -4,11 +4,11 @@ Gfx *geo_update_held_mario_pos(s32 run, UNUSED struct GraphNode *node, Mat4 mtx) { if (run == TRUE) { Mat4 sp20; - struct Object *sp1C = (struct Object *) gCurGraphNodeObject; - if (sp1C->prevObj != NULL) { + struct Object *obj = (struct Object *) gCurGraphNodeObject; + if (obj->prevObj != NULL) { create_transformation_from_matrices(sp20, mtx, *gCurGraphNodeCamera->matrixPtr); - obj_update_pos_from_parent_transformation(sp20, sp1C->prevObj); - obj_set_gfx_pos_from_pos(sp1C->prevObj); + obj_update_pos_from_parent_transformation(sp20, obj->prevObj); + obj_set_gfx_pos_from_pos(obj->prevObj); } } @@ -200,7 +200,7 @@ void king_bobomb_act_6(void) { void king_bobomb_act_7(void) { cur_obj_init_animation_with_sound(2); - if (cur_obj_update_dialog_with_cutscene(MARIO_DIALOG_LOOK_UP, + if (cur_obj_update_dialog_with_cutscene(MARIO_DIALOG_LOOK_UP, DIALOG_FLAG_TEXT_DEFAULT, CUTSCENE_DIALOG, DIALOG_116)) { create_sound_spawner(SOUND_OBJ_KING_WHOMP_DEATH); @@ -319,7 +319,7 @@ void king_bobomb_act_5(void) { // bobomb returns home break; case 4: - if (cur_obj_update_dialog_with_cutscene(MARIO_DIALOG_LOOK_UP, + if (cur_obj_update_dialog_with_cutscene(MARIO_DIALOG_LOOK_UP, DIALOG_FLAG_TURN_TO_MARIO, CUTSCENE_DIALOG, DIALOG_128)) { o->oAction = 2; } diff --git a/src/game/behaviors/klepto.inc.c b/src/game/behaviors/klepto.inc.c index 9a1e10b3..6b122c96 100644 --- a/src/game/behaviors/klepto.inc.c +++ b/src/game/behaviors/klepto.inc.c @@ -76,7 +76,7 @@ static void klepto_anim_dive(void) { } void bhv_klepto_init(void) { - if (o->oBehParams2ndByte != 0) { + if (o->oBhvParams2ndByte != 0) { o->oAnimState = KLEPTO_ANIM_STATE_HOLDING_STAR; } else { o->oKleptoStartPosX = o->oPosX; @@ -297,7 +297,7 @@ static void klepto_act_retreat(void) { static void klepto_act_reset_position(void) { if (o->oTimer < 300) { klepto_circle_target(300.0f, 20.0f); - } else if (o->oBehParams2ndByte != 0) { + } else if (o->oBhvParams2ndByte != 0) { o->oHomeX = -2000.0f; o->oHomeZ = -1000.0f; o->oHomeY = o->oKleptoDistanceToTarget = 9999.0f; diff --git a/src/game/behaviors/koopa.inc.c b/src/game/behaviors/koopa.inc.c index 04b345c9..d634e3c0 100644 --- a/src/game/behaviors/koopa.inc.c +++ b/src/game/behaviors/koopa.inc.c @@ -51,8 +51,8 @@ static u8 sKoopaShelledAttackHandlers[] = { * Data to control the behavior of each instance of Koopa the Quick. */ struct KoopaTheQuickProperties { - s16 initText; - s16 winText; + s16 initDialogID; + s16 winDialogID; Trajectory const *path; Vec3s starPos; }; @@ -69,7 +69,7 @@ static struct KoopaTheQuickProperties sKoopaTheQuickProperties[] = { * Initialization function. */ void bhv_koopa_init(void) { - if ((o->oKoopaMovementType = o->oBehParams2ndByte) == KOOPA_BP_TINY) { + if ((o->oKoopaMovementType = o->oBhvParams2ndByte) == KOOPA_BP_TINY) { // Tiny koopa in THI o->oKoopaMovementType = KOOPA_BP_NORMAL; o->oKoopaAgility = 1.6f / 3.0f; @@ -517,7 +517,7 @@ static void koopa_the_quick_act_wait_before_race(void) { */ static void koopa_the_quick_act_show_init_text(void) { s32 response = obj_update_race_proposition_dialog( - sKoopaTheQuickProperties[o->oKoopaTheQuickRaceIndex].initText); + sKoopaTheQuickProperties[o->oKoopaTheQuickRaceIndex].initDialogID); if (response == DIALOG_RESPONSE_YES) { UNUSED u8 filler[4]; @@ -721,7 +721,7 @@ static void koopa_the_quick_act_after_race(void) { } else { // Mario won o->parentObj->oKoopaRaceEndpointDialog = - sKoopaTheQuickProperties[o->oKoopaTheQuickRaceIndex].winText; + sKoopaTheQuickProperties[o->oKoopaTheQuickRaceIndex].winDialogID; } } else { // KtQ won @@ -731,7 +731,7 @@ static void koopa_the_quick_act_after_race(void) { o->oFlags &= ~OBJ_FLAG_ACTIVE_FROM_AFAR; } } else if (o->parentObj->oKoopaRaceEndpointDialog > 0) { - s32 dialogResponse = cur_obj_update_dialog_with_cutscene(MARIO_DIALOG_LOOK_UP, + s32 dialogResponse = cur_obj_update_dialog_with_cutscene(MARIO_DIALOG_LOOK_UP, DIALOG_FLAG_TURN_TO_MARIO, CUTSCENE_DIALOG, o->parentObj->oKoopaRaceEndpointDialog); if (dialogResponse != 0) { o->parentObj->oKoopaRaceEndpointDialog = DIALOG_NONE; diff --git a/src/game/behaviors/lll_floating_wood_piece.inc.c b/src/game/behaviors/lll_floating_wood_piece.inc.c index 6abb42a1..8f019911 100644 --- a/src/game/behaviors/lll_floating_wood_piece.inc.c +++ b/src/game/behaviors/lll_floating_wood_piece.inc.c @@ -5,8 +5,8 @@ void bhv_lll_wood_piece_loop(void) { o->oPosY -= 100.0f; } - o->oPosY += sins(o->oLllWoodPieceOscillationTimer) * 3.0f; - o->oLllWoodPieceOscillationTimer += 0x400; + o->oPosY += sins(o->oLLLWoodPieceOscillationTimer) * 3.0f; + o->oLLLWoodPieceOscillationTimer += 0x400; if (o->parentObj->oAction == 2) { obj_mark_for_deletion(o); @@ -22,8 +22,8 @@ void bhv_lll_floating_wood_bridge_loop(void) { if (o->oDistanceToMario < 2500.0f) { for (i = 1; i < 4; i++) { sp3C = spawn_object_relative(0, (i - 2) * 300, 0, 0, o, - MODEL_LLL_WOOD_BRIDGE, bhvLllWoodPiece); - sp3C->oLllWoodPieceOscillationTimer = i * 0x1000; + MODEL_LLL_WOOD_BRIDGE, bhvLLLWoodPiece); + sp3C->oLLLWoodPieceOscillationTimer = i * 0x1000; } o->oAction = 1; } diff --git a/src/game/behaviors/lll_octagonal_rotating_mesh.inc.c b/src/game/behaviors/lll_octagonal_rotating_mesh.inc.c index 054723fd..7cf52c97 100644 --- a/src/game/behaviors/lll_octagonal_rotating_mesh.inc.c +++ b/src/game/behaviors/lll_octagonal_rotating_mesh.inc.c @@ -73,7 +73,7 @@ void bhv_lll_moving_octagonal_mesh_platform_loop(void) { o->oAction++; } else { o->oHorizontalMovementUnkF8 = - lll_octagonal_mesh_move(D_8032F8C8[o->oBehParams2ndByte], o->oHorizontalMovementUnkF8); + lll_octagonal_mesh_move(D_8032F8C8[o->oBhvParams2ndByte], o->oHorizontalMovementUnkF8); } print_debug_top_down_objectinfo("number %d\n", o->oHorizontalMovementUnkF8); diff --git a/src/game/behaviors/lll_rotating_hex_flame.inc.c b/src/game/behaviors/lll_rotating_hex_flame.inc.c index 4637f317..6193b66c 100644 --- a/src/game/behaviors/lll_rotating_hex_flame.inc.c +++ b/src/game/behaviors/lll_rotating_hex_flame.inc.c @@ -1,9 +1,9 @@ // lll_rotating_hex_flame.inc.c void bhv_lll_rotating_hex_flame_loop(void) { - f32 sp24 = o->oLllRotatingHexFlameUnkF4; - f32 sp20 = o->oLllRotatingHexFlameUnkF8; - f32 sp1C = o->oLllRotatingHexFlameUnkFC; + f32 sp24 = o->oLLLRotatingHexFlameUnkF4; + f32 sp20 = o->oLLLRotatingHexFlameUnkF8; + f32 sp1C = o->oLLLRotatingHexFlameUnkFC; cur_obj_set_pos_relative(o->parentObj, sp24, sp20, sp1C); o->oPosY = o->parentObj->oPosY + 100.0f; @@ -21,13 +21,13 @@ void fire_bar_spawn_flames(s16 a0) { f32 sp1C = sins(a0) * 200.0f; f32 sp18 = coss(a0) * 200.0f; - sp20 = o->oBehParams2ndByte == 0 ? 4 : 3; + sp20 = o->oBhvParams2ndByte == 0 ? 4 : 3; for (i = 0; i < sp20; i++) { - sp2C = spawn_object(o, MODEL_RED_FLAME, bhvLllRotatingHexFlame); - sp2C->oLllRotatingHexFlameUnkF4 += sp1C; - sp2C->oLllRotatingHexFlameUnkF8 = o->oPosY - 200.0f; - sp2C->oLllRotatingHexFlameUnkFC += sp18; + sp2C = spawn_object(o, MODEL_RED_FLAME, bhvLLLRotatingHexFlame); + sp2C->oLLLRotatingHexFlameUnkF4 += sp1C; + sp2C->oLLLRotatingHexFlameUnkF8 = o->oPosY - 200.0f; + sp2C->oLLLRotatingHexFlameUnkFC += sp18; obj_scale_xyz(sp2C, 6.0f, 6.0f, 6.0f); sp1C += sins(a0) * 150.0f; sp18 += coss(a0) * 150.0f; @@ -69,7 +69,7 @@ void (*sRotatingCwFireBarsActions[])(void) = { void bhv_lll_rotating_block_fire_bars_loop(void) { cur_obj_call_action_function(sRotatingCwFireBarsActions); - if (o->oBehParams2ndByte == 0) { + if (o->oBhvParams2ndByte == 0) { load_object_collision_model(); } } diff --git a/src/game/behaviors/lll_sinking_rectangle.inc.c b/src/game/behaviors/lll_sinking_rectangle.inc.c index 22d8fd8a..af3598af 100644 --- a/src/game/behaviors/lll_sinking_rectangle.inc.c +++ b/src/game/behaviors/lll_sinking_rectangle.inc.c @@ -7,8 +7,8 @@ void sinking_rectangular_plat_actions(f32 a0, s32 a1) { break; case 1: - o->oPosY -= sins(o->oLllWoodPieceOscillationTimer) * a0; - o->oLllWoodPieceOscillationTimer += a1; + o->oPosY -= sins(o->oLLLWoodPieceOscillationTimer) * a0; + o->oLLLWoodPieceOscillationTimer += a1; break; case 2: @@ -24,8 +24,8 @@ void bhv_lll_sinking_rectangular_platform_loop(void) { if (o->oMoveAngleYaw != 0) { sinking_rectangular_plat_actions(sp1C, sp18); } else { - o->oFaceAnglePitch = sins(o->oLllWoodPieceOscillationTimer) * 0x200; - o->oLllWoodPieceOscillationTimer += 0x100; + o->oFaceAnglePitch = sins(o->oLLLWoodPieceOscillationTimer) * 0x200; + o->oLLLWoodPieceOscillationTimer += 0x100; } } diff --git a/src/game/behaviors/manta_ray.inc.c b/src/game/behaviors/manta_ray.inc.c index 62224840..f8c61d4b 100644 --- a/src/game/behaviors/manta_ray.inc.c +++ b/src/game/behaviors/manta_ray.inc.c @@ -6,15 +6,15 @@ * These rings contain a significant bug that is documented in water_ring.inc.c */ -static Trajectory sMantaRayTraj[] = { - TRAJECTORY_POS(0, /*pos*/ -4500, -1380, -40), - TRAJECTORY_POS(1, /*pos*/ -4120, -2240, 740), - TRAJECTORY_POS(2, /*pos*/ -3280, -3080, 1040), - TRAJECTORY_POS(3, /*pos*/ -2240, -3320, 720), - TRAJECTORY_POS(4, /*pos*/ -1840, -3140, -280), - TRAJECTORY_POS(5, /*pos*/ -2320, -2480, -1100), - TRAJECTORY_POS(6, /*pos*/ -3220, -1600, -1360), - TRAJECTORY_POS(7, /*pos*/ -4180, -1020, -1040), +static Trajectory sMantaRayTraj[] = { + TRAJECTORY_POS(0, /*pos*/ -4500, -1380, -40), + TRAJECTORY_POS(1, /*pos*/ -4120, -2240, 740), + TRAJECTORY_POS(2, /*pos*/ -3280, -3080, 1040), + TRAJECTORY_POS(3, /*pos*/ -2240, -3320, 720), + TRAJECTORY_POS(4, /*pos*/ -1840, -3140, -280), + TRAJECTORY_POS(5, /*pos*/ -2320, -2480, -1100), + TRAJECTORY_POS(6, /*pos*/ -3220, -1600, -1360), + TRAJECTORY_POS(7, /*pos*/ -4180, -1020, -1040), TRAJECTORY_END(), }; @@ -48,6 +48,7 @@ static void manta_ray_move(void) { #endif o->oPathedStartWaypoint = (struct Waypoint *) sMantaRayTraj; + //! Uninitialized parameter, but the parameter is unused in the called function pathStatus = cur_obj_follow_path(pathStatus); o->oMantaTargetYaw = o->oPathedTargetYaw; diff --git a/src/game/behaviors/mips.inc.c b/src/game/behaviors/mips.inc.c index 0aed1ec9..8c2d3410 100644 --- a/src/game/behaviors/mips.inc.c +++ b/src/game/behaviors/mips.inc.c @@ -14,7 +14,7 @@ void bhv_mips_init(void) { // If the player has >= 15 stars and hasn't collected first MIPS star... if (save_file_get_total_star_count(gCurrSaveFileNum - 1, COURSE_MIN - 1, COURSE_MAX - 1) >= 15 && !(starFlags & SAVE_FLAG_TO_STAR_FLAG(SAVE_FLAG_COLLECTED_MIPS_STAR_1))) { - o->oBehParams2ndByte = 0; + o->oBhvParams2ndByte = MIPS_BP_15_STARS; #ifndef VERSION_JP o->oMipsForwardVelocity = 40.0f; #endif @@ -22,7 +22,7 @@ void bhv_mips_init(void) { // If the player has >= 50 stars and hasn't collected second MIPS star... else if (save_file_get_total_star_count(gCurrSaveFileNum - 1, COURSE_MIN - 1, COURSE_MAX - 1) >= 50 && !(starFlags & SAVE_FLAG_TO_STAR_FLAG(SAVE_FLAG_COLLECTED_MIPS_STAR_2))) { - o->oBehParams2ndByte = 1; + o->oBhvParams2ndByte = MIPS_BP_50_STARS; #ifndef VERSION_JP o->oMipsForwardVelocity = 45.0f; #endif @@ -109,16 +109,18 @@ void bhv_mips_act_wait_for_nearby_mario(void) { void bhv_mips_act_follow_path(void) { s16 collisionFlags = 0; s32 followStatus; -#ifdef AVOID_UB - followStatus = 0; -#endif // Retrieve current waypoint. struct Waypoint **pathBase = segmented_to_virtual(&inside_castle_seg7_trajectory_mips); struct Waypoint *waypoint = segmented_to_virtual(*(pathBase + o->oMipsStartWaypointIndex)); +#ifdef AVOID_UB + followStatus = 0; +#endif + // Set start waypoint and follow the path from there. o->oPathedStartWaypoint = waypoint; + //! Uninitialized parameter, but the parameter is unused in the called function followStatus = cur_obj_follow_path(followStatus); // Update velocity and angle and do movement. @@ -187,7 +189,7 @@ void bhv_mips_act_idle(void) { // Spawn a star if he was just picked up for the first time. if (o->oMipsStarStatus == MIPS_STAR_STATUS_SHOULD_SPAWN_STAR) { - bhv_spawn_star_no_level_exit(o->oBehParams2ndByte + 3); + bhv_spawn_star_no_level_exit(STAR_INDEX_ACT_4 + o->oBhvParams2ndByte); o->oMipsStarStatus = MIPS_STAR_STATUS_ALREADY_SPAWNED_STAR; } } @@ -233,9 +235,9 @@ void bhv_mips_held(void) { // If MIPS hasn't spawned his star yet... if (o->oMipsStarStatus == MIPS_STAR_STATUS_HAVENT_SPAWNED_STAR) { // Choose dialog based on which MIPS encounter this is. - if (o->oBehParams2ndByte == 0) { + if (o->oBhvParams2ndByte == MIPS_BP_15_STARS) { dialogID = DIALOG_084; - } else { + } else { // MIPS_BP_50_STARS dialogID = DIALOG_162; } diff --git a/src/game/behaviors/monty_mole.inc.c b/src/game/behaviors/monty_mole.inc.c index 884774ad..0396c268 100644 --- a/src/game/behaviors/monty_mole.inc.c +++ b/src/game/behaviors/monty_mole.inc.c @@ -108,7 +108,7 @@ void bhv_monty_mole_hole_update(void) { */ void monty_mole_spawn_dirt_particles(s8 offsetY, s8 velYBase) { static struct SpawnParticlesInfo montyMoleRiseFromGroundParticles = { - /* behParam: */ 0, + /* bhvParam: */ 0, /* count: */ 3, /* model: */ MODEL_SAND_DUST, /* offsetY: */ 0, @@ -142,7 +142,7 @@ void bhv_monty_mole_init(void) { static void monty_mole_act_select_hole(void) { f32 minDistToMario; - if (o->oBehParams2ndByte != MONTY_MOLE_BP_NO_ROCK) { + if (o->oBhvParams2ndByte != MONTY_MOLE_BP_NO_ROCK) { minDistToMario = 200.0f; } else if (gMarioStates[0].forwardVel < 8.0f) { minDistToMario = 100.0f; @@ -206,7 +206,7 @@ static void monty_mole_act_spawn_rock(void) { struct Object *rock; if (cur_obj_init_anim_and_check_if_end(2)) { - if (o->oBehParams2ndByte != MONTY_MOLE_BP_NO_ROCK + if (o->oBhvParams2ndByte != MONTY_MOLE_BP_NO_ROCK && abs_angle_diff(o->oAngleToMario, o->oMoveAngleYaw) < 0x4000 && (rock = spawn_object(o, MODEL_PEBBLE, bhvMontyMoleRock)) != NULL) { o->prevObj = rock; @@ -376,7 +376,7 @@ void bhv_monty_mole_update(void) { if (distToLastKill < 1500.0f) { if (sMontyMoleKillStreak == 7) { play_puzzle_jingle(); - spawn_object(o, MODEL_1UP, bhv1upWalking); + spawn_object(o, MODEL_1UP, bhv1UpWalking); } } else { sMontyMoleKillStreak = 0; @@ -445,7 +445,7 @@ static struct ObjectHitbox sMontyMoleRockHitbox = { * The particles that spawn when a monty mole rock breaks. */ static struct SpawnParticlesInfo sMontyMoleRockBreakParticles = { - /* behParam: */ 0, + /* bhvParam: */ 0, /* count: */ 2, /* model: */ MODEL_PEBBLE, /* offsetY: */ 10, diff --git a/src/game/behaviors/mr_blizzard.inc.c b/src/game/behaviors/mr_blizzard.inc.c index 019f85e3..124cabec 100644 --- a/src/game/behaviors/mr_blizzard.inc.c +++ b/src/game/behaviors/mr_blizzard.inc.c @@ -17,7 +17,7 @@ struct ObjectHitbox sMrBlizzardHitbox = { void mr_blizzard_spawn_white_particles(s8 count, s8 offsetY, s8 forwardVelBase, s8 velYBase, s8 sizeBase) { static struct SpawnParticlesInfo D_80331A00 = { - /* behParam: */ 0, + /* bhvParam: */ 0, /* count: */ 6, /* model: */ MODEL_WHITE_PARTICLE, /* offsetY: */ 0, @@ -44,14 +44,14 @@ void mr_blizzard_spawn_white_particles(s8 count, s8 offsetY, s8 forwardVelBase, * Mr. Blizzard initialization function. */ void bhv_mr_blizzard_init(void) { - if (o->oBehParams2ndByte == MR_BLIZZARD_STYPE_JUMPING) { + if (o->oBhvParams2ndByte == MR_BLIZZARD_STYPE_JUMPING) { // Jumping Mr. Blizzard. o->oAction = MR_BLIZZARD_ACT_JUMP; o->oMrBlizzardGraphYOffset = 24.0f; o->oMrBlizzardTargetMoveYaw = o->oMoveAngleYaw; } else { // Cap wearing Mr. Blizzard from SL. - if ((o->oBehParams2ndByte != MR_BLIZZARD_STYPE_NO_CAP) + if ((o->oBhvParams2ndByte != MR_BLIZZARD_STYPE_GENERIC) && (save_file_get_flags() & SAVE_FLAG_CAP_ON_MR_BLIZZARD)) { o->oAnimState = 1; } @@ -239,7 +239,7 @@ static void mr_blizzard_act_death(void) { if (o->oMrBlizzardScale != 0.0f) { if ((o->oMrBlizzardScale -= 0.03f) <= 0.0f) { o->oMrBlizzardScale = 0.0f; - if (!(o->oBehParams & 0x0000FF00)) { + if (!(o->oBhvParams & 0x0000FF00)) { obj_spawn_loot_yellow_coins(o, o->oNumLootCoins, 20.0f); set_object_respawn_info_bits(o, 1); } diff --git a/src/game/behaviors/mr_i.inc.c b/src/game/behaviors/mr_i.inc.c index cbf0a759..9335f428 100644 --- a/src/game/behaviors/mr_i.inc.c +++ b/src/game/behaviors/mr_i.inc.c @@ -89,7 +89,7 @@ void mr_i_act_3(void) { f32 sp20; f32 sp1C; - if (o->oBehParams2ndByte != 0) { + if (o->oBhvParams2ndByte != 0) { sp1C = 2.0f; } else { sp1C = 1.0f; @@ -132,7 +132,7 @@ void mr_i_act_3(void) { cur_obj_become_intangible(); spawn_mist_particles(); o->oMrIScale = sp1C * 0.6; - if (o->oBehParams2ndByte != 0) { + if (o->oBhvParams2ndByte != 0) { o->oPosY += 100.0f; spawn_default_star(1370, 2000.0f, -320.0f); obj_mark_for_deletion(o); @@ -158,7 +158,7 @@ void mr_i_act_2(void) { s16 sp1C; if (o->oTimer == 0) { - if (o->oBehParams2ndByte != 0) { + if (o->oBhvParams2ndByte != 0) { o->oMrIUnkF4 = 200; } else { o->oMrIUnkF4 = 120; @@ -274,7 +274,7 @@ void mr_i_act_0(void) { o->oMoveAngleYaw = 0; o->oMoveAngleRoll = 0; #endif - cur_obj_scale(o->oBehParams2ndByte + 1); + cur_obj_scale(o->oBhvParams2ndByte + 1); if (o->oTimer == 0) { cur_obj_set_pos_to_home(); diff --git a/src/game/behaviors/mushroom_1up.inc.c b/src/game/behaviors/mushroom_1up.inc.c index ae0a7735..91ad6582 100644 --- a/src/game/behaviors/mushroom_1up.inc.c +++ b/src/game/behaviors/mushroom_1up.inc.c @@ -22,11 +22,11 @@ void bhv_1up_common_init(void) { void bhv_1up_init(void) { bhv_1up_common_init(); - if (o->oBehParams2ndByte == 1) { + if (o->oBhvParams2ndByte == ONE_UP_BP_BEAT_BITDW_BOWSER) { if (!(save_file_get_flags() & (SAVE_FLAG_HAVE_KEY_1 | SAVE_FLAG_UNLOCKED_BASEMENT_DOOR))) { o->activeFlags = ACTIVE_FLAG_DEACTIVATED; } - } else if (o->oBehParams2ndByte == 2) { + } else if (o->oBhvParams2ndByte == ONE_UP_BP_BEAT_BITFS_BOWSER) { if (!(save_file_get_flags() & (SAVE_FLAG_HAVE_KEY_2 | SAVE_FLAG_UNLOCKED_UPSTAIRS_DOOR))) { o->activeFlags = ACTIVE_FLAG_DEACTIVATED; } @@ -229,7 +229,7 @@ void bhv_1up_hidden_loop(void) { switch (o->oAction) { case 0: o->header.gfx.node.flags |= GRAPH_RENDER_INVISIBLE; - if (o->o1UpHiddenUnkF4 == o->oBehParams2ndByte) { + if (o->oHidden1UpNumTouchedTriggers == o->oBhvParams2ndByte) { o->oVelY = 40.0f; o->oAction = 3; o->header.gfx.node.flags &= ~GRAPH_RENDER_INVISIBLE; @@ -268,9 +268,9 @@ void bhv_1up_hidden_loop(void) { void bhv_1up_hidden_trigger_loop(void) { if (obj_check_if_collided_with_object(o, gMarioObject) == TRUE) { - struct Object *sp1C = cur_obj_nearest_object_with_behavior(bhvHidden1up); - if (sp1C != NULL) { - sp1C->o1UpHiddenUnkF4++; + struct Object *hidden1Up = cur_obj_nearest_object_with_behavior(bhvHidden1Up); + if (hidden1Up != NULL) { + hidden1Up->oHidden1UpNumTouchedTriggers++; } o->activeFlags = ACTIVE_FLAG_DEACTIVATED; @@ -283,7 +283,7 @@ void bhv_1up_hidden_in_pole_loop(void) { switch (o->oAction) { case 0: o->header.gfx.node.flags |= GRAPH_RENDER_INVISIBLE; - if (o->o1UpHiddenUnkF4 == o->oBehParams2ndByte) { + if (o->oHidden1UpNumTouchedTriggers == o->oBhvParams2ndByte) { o->oVelY = 40.0f; o->oAction = 3; o->header.gfx.node.flags &= ~GRAPH_RENDER_INVISIBLE; @@ -315,9 +315,9 @@ void bhv_1up_hidden_in_pole_loop(void) { void bhv_1up_hidden_in_pole_trigger_loop(void) { if (obj_check_if_collided_with_object(o, gMarioObject) == TRUE) { - struct Object *sp1C = cur_obj_nearest_object_with_behavior(bhvHidden1upInPole); - if (sp1C != NULL) { - sp1C->o1UpHiddenUnkF4++; + struct Object *hidden1Up = cur_obj_nearest_object_with_behavior(bhvHidden1UpInPole); + if (hidden1Up != NULL) { + hidden1Up->oHidden1UpNumTouchedTriggers++; } o->activeFlags = ACTIVE_FLAG_DEACTIVATED; @@ -327,9 +327,9 @@ void bhv_1up_hidden_in_pole_trigger_loop(void) { void bhv_1up_hidden_in_pole_spawner_loop(void) { if (is_point_within_radius_of_mario(o->oPosX, o->oPosY, o->oPosZ, 700)) { s8 i; - spawn_object_relative(2, 0, 50, 0, o, MODEL_1UP, bhvHidden1upInPole); - for (i = 0; i < 2; i++) { - spawn_object_relative(0, 0, i * -200, 0, o, MODEL_NONE, bhvHidden1upInPoleTrigger); + spawn_object_relative(2, 0, 50, 0, o, MODEL_1UP, bhvHidden1UpInPole); + for (i = 0; i <= 1; i++) { + spawn_object_relative(0, 0, i * -200, 0, o, MODEL_NONE, bhvHidden1UpInPoleTrigger); } o->activeFlags = ACTIVE_FLAG_DEACTIVATED; diff --git a/src/game/behaviors/orange_number.inc.c b/src/game/behaviors/orange_number.inc.c index 3b5554d8..422fbd21 100644 --- a/src/game/behaviors/orange_number.inc.c +++ b/src/game/behaviors/orange_number.inc.c @@ -1,7 +1,7 @@ // orange_number.inc.c void bhv_orange_number_init(void) { - o->oAnimState = o->oBehParams2ndByte; + o->oAnimState = o->oBhvParams2ndByte; o->oVelY = 26.0f; } diff --git a/src/game/behaviors/platform_on_track.inc.c b/src/game/behaviors/platform_on_track.inc.c index 51007e62..1650cb49 100644 --- a/src/game/behaviors/platform_on_track.inc.c +++ b/src/game/behaviors/platform_on_track.inc.c @@ -44,7 +44,7 @@ static void platform_on_track_reset(void) { * begin blinking, and finally reset. */ static void platform_on_track_mario_not_on_platform(void) { - if (!((u16)(o->oBehParams >> 16) & PLATFORM_ON_TRACK_BP_DONT_DISAPPEAR)) { + if (!((u16)(o->oBhvParams >> 16) & PLATFORM_ON_TRACK_BP_DONT_DISAPPEAR)) { // Once oTimer reaches 150, blink 40 times if (cur_obj_wait_then_blink(150, 40)) { platform_on_track_reset(); @@ -58,8 +58,8 @@ static void platform_on_track_mario_not_on_platform(void) { */ void bhv_platform_on_track_init(void) { if (!(o->activeFlags & ACTIVE_FLAG_IN_DIFFERENT_ROOM)) { - s16 pathIndex = (u16)(o->oBehParams >> 16) & PLATFORM_ON_TRACK_BP_MASK_PATH; - o->oPlatformOnTrackType = ((u16)(o->oBehParams >> 16) & PLATFORM_ON_TRACK_BP_MASK_TYPE) >> 4; + s16 pathIndex = (u16)(o->oBhvParams >> 16) & PLATFORM_ON_TRACK_BP_MASK_PATH; + o->oPlatformOnTrackType = ((u16)(o->oBhvParams >> 16) & PLATFORM_ON_TRACK_BP_MASK_TYPE) >> 4; o->oPlatformOnTrackIsNotSkiLift = o->oPlatformOnTrackType - PLATFORM_ON_TRACK_TYPE_SKI_LIFT; @@ -70,7 +70,7 @@ void bhv_platform_on_track_init(void) { o->oPlatformOnTrackIsNotHMC = pathIndex - 4; - o->oBehParams2ndByte = o->oMoveAngleYaw; // TODO: Weird? + o->oBhvParams2ndByte = o->oMoveAngleYaw; // TODO: Weird? if (o->oPlatformOnTrackType == PLATFORM_ON_TRACK_TYPE_CHECKERED) { o->header.gfx.scale[1] = 2.0f; @@ -93,7 +93,7 @@ static void platform_on_track_act_init(void) { o->oPosY = o->oHomeY = o->oPlatformOnTrackStartWaypoint->pos[1]; o->oPosZ = o->oHomeZ = o->oPlatformOnTrackStartWaypoint->pos[2]; - o->oFaceAngleYaw = o->oBehParams2ndByte; + o->oFaceAngleYaw = o->oBhvParams2ndByte; o->oForwardVel = o->oVelX = o->oVelY = o->oVelZ = o->oPlatformOnTrackDistMovedSinceLastBall = 0.0f; o->oPlatformOnTrackWasStoodOn = FALSE; @@ -142,7 +142,7 @@ static void platform_on_track_act_move_along_track(void) { // Fall after reaching the last waypoint if desired if (o->oPlatformOnTrackPrevWaypointFlags == WAYPOINT_FLAGS_END - && !((u16)(o->oBehParams >> 16) & PLATFORM_ON_TRACK_BP_RETURN_TO_START)) { + && !((u16)(o->oBhvParams >> 16) & PLATFORM_ON_TRACK_BP_RETURN_TO_START)) { o->oAction = PLATFORM_ON_TRACK_ACT_FALL; } else { // The ski lift should pause or stop after reaching a special waypoint @@ -189,7 +189,7 @@ static void platform_on_track_act_move_along_track(void) { // after reappearing // Turn face yaw and compute yaw vel - if (!((u16)(o->oBehParams >> 16) & PLATFORM_ON_TRACK_BP_DONT_TURN_YAW)) { + if (!((u16)(o->oBhvParams >> 16) & PLATFORM_ON_TRACK_BP_DONT_TURN_YAW)) { s16 targetFaceYaw = o->oMoveAngleYaw + 0x4000; s16 yawSpeed = abs_angle_diff(targetFaceYaw, o->oFaceAngleYaw) / 20; @@ -200,7 +200,7 @@ static void platform_on_track_act_move_along_track(void) { } // Turn face roll and compute roll vel - if (((u16)(o->oBehParams >> 16) & PLATFORM_ON_TRACK_BP_DONT_TURN_ROLL)) { + if (((u16)(o->oBhvParams >> 16) & PLATFORM_ON_TRACK_BP_DONT_TURN_ROLL)) { s16 rollSpeed = abs_angle_diff(o->oMoveAnglePitch, o->oFaceAngleRoll) / 20; initialAngle = o->oFaceAngleRoll; @@ -310,7 +310,7 @@ void bhv_platform_on_track_update(void) { void bhv_track_ball_update(void) { // Despawn after the elevator passes this ball s16 relativeIndex = - (s16) o->oBehParams2ndByte - (s16) o->parentObj->oPlatformOnTrackBaseBallIndex - 1; + (s16) o->oBhvParams2ndByte - (s16) o->parentObj->oPlatformOnTrackBaseBallIndex - 1; if (relativeIndex < 1 || relativeIndex > 5) { obj_mark_for_deletion(o); } diff --git a/src/game/behaviors/pokey.inc.c b/src/game/behaviors/pokey.inc.c index 9f870869..25571a65 100644 --- a/src/game/behaviors/pokey.inc.c +++ b/src/game/behaviors/pokey.inc.c @@ -58,15 +58,15 @@ void bhv_pokey_body_part_update(void) { // index by killing two body parts on the frame before a new part // spawns, but one of the body parts shifts upward immediately, // so not very interesting - if (o->oBehParams2ndByte > 1 - && !(o->parentObj->oPokeyAliveBodyPartFlags & (1 << (o->oBehParams2ndByte - 1)))) { + if (o->oBhvParams2ndByte > 1 + && !(o->parentObj->oPokeyAliveBodyPartFlags & (1 << (o->oBhvParams2ndByte - 1)))) { o->parentObj->oPokeyAliveBodyPartFlags = - o->parentObj->oPokeyAliveBodyPartFlags | 1 << (o->oBehParams2ndByte - 1); + o->parentObj->oPokeyAliveBodyPartFlags | 1 << (o->oBhvParams2ndByte - 1); o->parentObj->oPokeyAliveBodyPartFlags = - o->parentObj->oPokeyAliveBodyPartFlags & ((1 << o->oBehParams2ndByte) ^ ~0); + o->parentObj->oPokeyAliveBodyPartFlags & ((1 << o->oBhvParams2ndByte) ^ ~0); - o->oBehParams2ndByte--; + o->oBhvParams2ndByte--; } // Set the bottom body part size, and gradually increase it. @@ -76,19 +76,19 @@ void bhv_pokey_body_part_update(void) { // was above it will instantly shrink and begin expanding in its // place. else if (o->parentObj->oPokeyBottomBodyPartSize < 1.0f - && o->oBehParams2ndByte + 1 == o->parentObj->oPokeyNumAliveBodyParts) { + && o->oBhvParams2ndByte + 1 == o->parentObj->oPokeyNumAliveBodyParts) { approach_f32_ptr(&o->parentObj->oPokeyBottomBodyPartSize, 1.0f, 0.1f); cur_obj_scale(o->parentObj->oPokeyBottomBodyPartSize * 3.0f); } //! Pausing causes jumps in offset angle - offsetAngle = o->oBehParams2ndByte * 0x4000 + gGlobalTimer * 0x800; + offsetAngle = o->oBhvParams2ndByte * 0x4000 + gGlobalTimer * 0x800; o->oPosX = o->parentObj->oPosX + coss(offsetAngle) * 6.0f; o->oPosZ = o->parentObj->oPosZ + sins(offsetAngle) * 6.0f; // This is the height of the tower beneath the body part baseHeight = o->parentObj->oPosY - + (120 * (o->parentObj->oPokeyNumAliveBodyParts - o->oBehParams2ndByte) - 240) + + (120 * (o->parentObj->oPokeyNumAliveBodyParts - o->oBhvParams2ndByte) - 240) + 120.0f * o->parentObj->oPokeyBottomBodyPartSize; // We treat the base height as a minimum height, allowing the body @@ -99,7 +99,7 @@ void bhv_pokey_body_part_update(void) { } // Only the head has loot coins - if (o->oBehParams2ndByte == 0) { + if (o->oBhvParams2ndByte == 0) { o->oNumLootCoins = 1; } else { o->oNumLootCoins = 0; @@ -110,7 +110,7 @@ void bhv_pokey_body_part_update(void) { if (obj_handle_attacks(&sPokeyBodyPartHitbox, o->oAction, sPokeyBodyPartAttackHandlers)) { o->parentObj->oPokeyNumAliveBodyParts--; - if (o->oBehParams2ndByte == 0) { + if (o->oBhvParams2ndByte == 0) { o->parentObj->oPokeyHeadWasKilled = TRUE; // Last minute change to blue coins - not sure why they didn't // just set it to -1 above @@ -118,7 +118,7 @@ void bhv_pokey_body_part_update(void) { } o->parentObj->oPokeyAliveBodyPartFlags = - o->parentObj->oPokeyAliveBodyPartFlags & ((1 << o->oBehParams2ndByte) ^ ~0); + o->parentObj->oPokeyAliveBodyPartFlags & ((1 << o->oBhvParams2ndByte) ^ ~0); } else if (o->parentObj->oPokeyHeadWasKilled) { cur_obj_become_intangible(); @@ -130,7 +130,7 @@ void bhv_pokey_body_part_update(void) { // Die in order from top to bottom // If a new body part spawns after the head has been killed, its // death delay will be 0 - o->oPokeyBodyPartDeathDelayAfterHeadKilled = (o->oBehParams2ndByte << 2) + 20; + o->oPokeyBodyPartDeathDelayAfterHeadKilled = (o->oBhvParams2ndByte << 2) + 20; } cur_obj_move_standard(-78); diff --git a/src/game/behaviors/pole.inc.c b/src/game/behaviors/pole.inc.c index 1066e003..79acf19f 100644 --- a/src/game/behaviors/pole.inc.c +++ b/src/game/behaviors/pole.inc.c @@ -14,10 +14,10 @@ */ void bhv_pole_init(void) { /** - * This is equivalent to using `o->oBehParams2ndByte` according to + * This is equivalent to using `o->oBhvParams2ndByte` according to * `spawn_objects_from_info`. */ - s32 tenthHitboxHeight = (o->oBehParams >> 16) & 0xFF; + s32 tenthHitboxHeight = (o->oBhvParams >> 16) & 0xFF; o->hitboxHeight = tenthHitboxHeight * 10; } diff --git a/src/game/behaviors/purple_switch.inc.c b/src/game/behaviors/purple_switch.inc.c index a5157746..5531ff57 100644 --- a/src/game/behaviors/purple_switch.inc.c +++ b/src/game/behaviors/purple_switch.inc.c @@ -15,12 +15,12 @@ void bhv_purple_switch_loop(void) { * Set the switch's model and scale. If Mario is standing near the * switch's middle section, transition to the pressed state. */ - case PURPLE_SWITCH_IDLE: + case PURPLE_SWITCH_ACT_IDLE: cur_obj_set_model(MODEL_PURPLE_SWITCH); cur_obj_scale(1.5f); if (gMarioObject->platform == o && !(gMarioStates[0].action & MARIO_UNKNOWN_13)) { if (lateral_dist_between_objects(o, gMarioObject) < 127.5) { - o->oAction = PURPLE_SWITCH_PRESSED; + o->oAction = PURPLE_SWITCH_ACT_PRESSED; } } break; @@ -29,11 +29,11 @@ void bhv_purple_switch_loop(void) { * Collapse the switch downward, play a sound, and shake the screen. * Immediately transition to the ticking state. */ - case PURPLE_SWITCH_PRESSED: + case PURPLE_SWITCH_ACT_PRESSED: cur_obj_scale_over_time(2, 3, 1.5f, 0.2f); if (o->oTimer == 3) { cur_obj_play_sound_2(SOUND_GENERAL2_PURPLE_SWITCH); - o->oAction = PURPLE_SWITCH_TICKING; + o->oAction = PURPLE_SWITCH_ACT_TICKING; cur_obj_shake_screen(SHAKE_POS_SMALL); #if ENABLE_RUMBLE queue_rumble_data(5, 80); @@ -45,9 +45,9 @@ void bhv_purple_switch_loop(void) { * Play a continuous ticking sound that gets faster when time is almost * up. When time is up, move to a waiting-while-pressed state. */ - case PURPLE_SWITCH_TICKING: - if (o->oBehParams2ndByte != 0) { - if (o->oBehParams2ndByte == 1 && gMarioObject->platform != o) { + case PURPLE_SWITCH_ACT_TICKING: + if (o->oBhvParams2ndByte != 0) { + if (o->oBhvParams2ndByte == 1 && gMarioObject->platform != o) { o->oAction++; } else { if (o->oTimer < 360) { @@ -56,7 +56,7 @@ void bhv_purple_switch_loop(void) { play_sound(SOUND_GENERAL2_SWITCH_TICK_SLOW, gGlobalSoundSource); } if (o->oTimer > 400) { - o->oAction = PURPLE_SWITCH_WAIT_FOR_MARIO_TO_GET_OFF; + o->oAction = PURPLE_SWITCH_ACT_WAIT_FOR_MARIO_TO_GET_OFF; } } } @@ -66,10 +66,10 @@ void bhv_purple_switch_loop(void) { * Make the switch look unpressed again, and transition back to the * idle state. */ - case PURPLE_SWITCH_UNPRESSED: + case PURPLE_SWITCH_ACT_UNPRESSED: cur_obj_scale_over_time(2, 3, 0.2f, 1.5f); if (o->oTimer == 3) { - o->oAction = PURPLE_SWITCH_IDLE; + o->oAction = PURPLE_SWITCH_ACT_IDLE; } break; @@ -78,9 +78,9 @@ void bhv_purple_switch_loop(void) { * him to get off the switch, and when he does so, transition to the * unpressed state. */ - case PURPLE_SWITCH_WAIT_FOR_MARIO_TO_GET_OFF: + case PURPLE_SWITCH_ACT_WAIT_FOR_MARIO_TO_GET_OFF: if (!cur_obj_is_mario_on_platform()) { - o->oAction = PURPLE_SWITCH_UNPRESSED; + o->oAction = PURPLE_SWITCH_ACT_UNPRESSED; } break; } diff --git a/src/game/behaviors/pyramid_elevator.inc.c b/src/game/behaviors/pyramid_elevator.inc.c index ac089de9..34d49c02 100644 --- a/src/game/behaviors/pyramid_elevator.inc.c +++ b/src/game/behaviors/pyramid_elevator.inc.c @@ -26,9 +26,9 @@ void bhv_pyramid_elevator_loop(void) { * Do not move until Mario stands on the elevator. When he does, * transition to the starting state. */ - case PYRAMID_ELEVATOR_IDLE: + case PYRAMID_ELEVATOR_ACT_IDLE: if (gMarioObject->platform == o) { - o->oAction = PYRAMID_ELEVATOR_START_MOVING; + o->oAction = PYRAMID_ELEVATOR_ACT_START_MOVING; } break; @@ -36,10 +36,10 @@ void bhv_pyramid_elevator_loop(void) { * Use a sine wave to start the elevator's movement with a small jolt. * After a certain amount of time, transition to a constant-velocity state. */ - case PYRAMID_ELEVATOR_START_MOVING: + case PYRAMID_ELEVATOR_ACT_START_MOVING: o->oPosY = o->oHomeY - sins(o->oTimer * 0x1000) * 10.0f; if (o->oTimer == 8) { - o->oAction = PYRAMID_ELEVATOR_CONSTANT_VELOCITY; + o->oAction = PYRAMID_ELEVATOR_ACT_CONSTANT_VELOCITY; } break; @@ -47,12 +47,12 @@ void bhv_pyramid_elevator_loop(void) { * Move downwards with constant velocity. Once at the bottom of the * track, transition to the final state. */ - case PYRAMID_ELEVATOR_CONSTANT_VELOCITY: + case PYRAMID_ELEVATOR_ACT_CONSTANT_VELOCITY: o->oVelY = -10.0f; o->oPosY += o->oVelY; if (o->oPosY < 128.0f) { o->oPosY = 128.0f; - o->oAction = PYRAMID_ELEVATOR_AT_BOTTOM; + o->oAction = PYRAMID_ELEVATOR_ACT_AT_BOTTOM; } break; @@ -60,7 +60,7 @@ void bhv_pyramid_elevator_loop(void) { * Use a sine wave to stop the elevator's movement with a small jolt. * Then, remain at the bottom of the track. */ - case PYRAMID_ELEVATOR_AT_BOTTOM: + case PYRAMID_ELEVATOR_ACT_AT_BOTTOM: o->oPosY = sins(o->oTimer * 0x1000) * 10.0f + 128.0f; if (o->oTimer >= 8) { o->oVelY = 0; @@ -81,7 +81,7 @@ void bhv_pyramid_elevator_trajectory_marker_ball_loop(void) { elevator = cur_obj_nearest_object_with_behavior(bhvPyramidElevator); if (elevator != NULL) { - if (elevator->oAction != PYRAMID_ELEVATOR_IDLE) { + if (elevator->oAction != PYRAMID_ELEVATOR_ACT_IDLE) { o->activeFlags = ACTIVE_FLAG_DEACTIVATED; } } diff --git a/src/game/behaviors/pyramid_top.inc.c b/src/game/behaviors/pyramid_top.inc.c index 14b6bc2f..44b77782 100644 --- a/src/game/behaviors/pyramid_top.inc.c +++ b/src/game/behaviors/pyramid_top.inc.c @@ -71,7 +71,7 @@ void bhv_pyramid_top_explode(void) { struct Object *pyramidFragment; s16 i; - spawn_mist_particles_variable(0, 0, 690); + spawn_mist_particles_variable(0, 0, 690.0f); // Generate 30 pyramid fragments with random properties. for (i = 0; i < 30; i++) { diff --git a/src/game/behaviors/pyramid_wall.inc.c b/src/game/behaviors/pyramid_wall.inc.c index 8306aca6..3ced69ac 100644 --- a/src/game/behaviors/pyramid_wall.inc.c +++ b/src/game/behaviors/pyramid_wall.inc.c @@ -1,6 +1,6 @@ /** - * Behavior for bhvSslMovingPyramidWall. + * Behavior for bhvSSLMovingPyramidWall. * * This controls the moving walls found within Shifting Sand Land's pyramid. * Each wall starts at an initial position and moves up or down at a constant @@ -12,7 +12,7 @@ * positions. */ void bhv_ssl_moving_pyramid_wall_init(void) { - switch (o->oBehParams2ndByte) { + switch (o->oBhvParams2ndByte) { case PYRAMID_WALL_BP_POSITION_HIGH: break; diff --git a/src/game/behaviors/racing_penguin.inc.c b/src/game/behaviors/racing_penguin.inc.c index 21639ec1..3f5537f7 100644 --- a/src/game/behaviors/racing_penguin.inc.c +++ b/src/game/behaviors/racing_penguin.inc.c @@ -1,21 +1,21 @@ // racing_penguin.inc.c struct RacingPenguinData { - s16 text; + s16 dialogID; f32 radius; f32 height; }; static struct RacingPenguinData sRacingPenguinData[] = { - { DIALOG_055, 200.0f, 200.0f }, - { DIALOG_164, 350.0f, 250.0f }, + /* RACING_PENGUIN_BP_THIN */ { DIALOG_055, 200.0f, 200.0f }, + /* RACING_PENGUIN_BP_FAT */ { DIALOG_164, 350.0f, 250.0f }, }; void bhv_racing_penguin_init(void) { if (gMarioState->numStars == 120) { cur_obj_scale(8.0f); o->header.gfx.scale[1] = 5.0f; - o->oBehParams2ndByte = 1; + o->oBhvParams2ndByte = RACING_PENGUIN_BP_FAT; } } @@ -27,7 +27,7 @@ static void racing_penguin_act_wait_for_mario(void) { } static void racing_penguin_act_show_init_text(void) { - s32 response = obj_update_race_proposition_dialog(sRacingPenguinData[o->oBehParams2ndByte].text); + s32 response = obj_update_race_proposition_dialog(sRacingPenguinData[o->oBhvParams2ndByte].dialogID); if (response == DIALOG_RESPONSE_YES) { struct Object *child; @@ -141,7 +141,7 @@ static void racing_penguin_act_show_final_text(void) { } } else if (o->oRacingPenguinFinalTextbox > 0) { s32 textResult; - if ((textResult = cur_obj_update_dialog_with_cutscene(MARIO_DIALOG_LOOK_UP, + if ((textResult = cur_obj_update_dialog_with_cutscene(MARIO_DIALOG_LOOK_UP, DIALOG_FLAG_TURN_TO_MARIO, CUTSCENE_DIALOG, o->oRacingPenguinFinalTextbox))) { o->oRacingPenguinFinalTextbox = -1; o->oTimer = 0; @@ -182,8 +182,8 @@ void bhv_racing_penguin_update(void) { cur_obj_move_standard(78); cur_obj_align_gfx_with_floor(); - cur_obj_push_mario_away_from_cylinder(sRacingPenguinData[o->oBehParams2ndByte].radius, - sRacingPenguinData[o->oBehParams2ndByte].height); + cur_obj_push_mario_away_from_cylinder(sRacingPenguinData[o->oBhvParams2ndByte].radius, + sRacingPenguinData[o->oBhvParams2ndByte].height); } void bhv_penguin_race_finish_line_update(void) { diff --git a/src/game/behaviors/rotating_octagonal_plat.inc.c b/src/game/behaviors/rotating_octagonal_plat.inc.c index 3e644848..72e536ca 100644 --- a/src/game/behaviors/rotating_octagonal_plat.inc.c +++ b/src/game/behaviors/rotating_octagonal_plat.inc.c @@ -8,8 +8,8 @@ static const Collision *sOctagonalPlatformCollision[] = { static s16 sOctagonalPlatformAngularVelocities[] = { 300, -300, 600, -600 }; void bhv_rotating_octagonal_plat_init(void) { - o->collisionData = segmented_to_virtual(sOctagonalPlatformCollision[(o->oBehParams >> 16) & 0xFF]); - o->oAngleVelYaw = sOctagonalPlatformAngularVelocities[(o->oBehParams >> 24) & 0xFF]; + o->collisionData = segmented_to_virtual(sOctagonalPlatformCollision[(o->oBhvParams >> 16) & 0xFF]); + o->oAngleVelYaw = sOctagonalPlatformAngularVelocities[(o->oBhvParams >> 24) & 0xFF]; } void bhv_rotating_octagonal_plat_loop(void) { diff --git a/src/game/behaviors/rotating_platform.inc.c b/src/game/behaviors/rotating_platform.inc.c index 9f381b8e..ea48a666 100644 --- a/src/game/behaviors/rotating_platform.inc.c +++ b/src/game/behaviors/rotating_platform.inc.c @@ -3,28 +3,28 @@ #include "levels/wf/header.h" #include "levels/wdw/header.h" -struct WFRotatingPlatformData { +struct RotatingPlatformData { s16 unused; s16 scale; const Collision *collisionData; s16 collisionDistance; }; -struct WFRotatingPlatformData sWFRotatingPlatformData[] = { - { 0, 100, wf_seg7_collision_rotating_platform, 2000 }, - { 0, 150, wdw_seg7_collision_070186B4, 1000 }, +struct RotatingPlatformData sRotatingPlatformData[] = { + /* ROTATING_PLATFORM_BP_WF */ { 0, 100, wf_seg7_collision_rotating_platform, 2000 }, + /* ROTATING_PLATFORM_BP_WDW */ { 0, 150, wdw_seg7_collision_070186B4, 1000 }, }; void bhv_wf_rotating_wooden_platform_loop(void) { - if (o->oAction == 0) { + if (o->oAction == WF_ROTATING_WOODEN_PLATFORM_ACT_IDLE) { o->oAngleVelYaw = 0; if (o->oTimer > 60) { o->oAction++; } - } else { + } else { // WF_ROTATING_WOODEN_PLATFORM_ACT_ROTATING o->oAngleVelYaw = 0x100; if (o->oTimer > 126) { - o->oAction = 0; + o->oAction = WF_ROTATING_WOODEN_PLATFORM_ACT_IDLE; } cur_obj_play_sound_1(SOUND_ENV_ELEVATOR2); } @@ -32,12 +32,12 @@ void bhv_wf_rotating_wooden_platform_loop(void) { } void bhv_rotating_platform_loop(void) { - s8 sp1F = o->oBehParams >> 24; + s8 bhvParams1stByte = o->oBhvParams >> 24; if (o->oTimer == 0) { - obj_set_collision_data(o, sWFRotatingPlatformData[o->oBehParams2ndByte].collisionData); - o->oCollisionDistance = sWFRotatingPlatformData[o->oBehParams2ndByte].collisionDistance; - cur_obj_scale(sWFRotatingPlatformData[o->oBehParams2ndByte].scale * 0.01f); + obj_set_collision_data(o, sRotatingPlatformData[o->oBhvParams2ndByte].collisionData); + o->oCollisionDistance = sRotatingPlatformData[o->oBhvParams2ndByte].collisionDistance; + cur_obj_scale(sRotatingPlatformData[o->oBhvParams2ndByte].scale * 0.01f); } - o->oAngleVelYaw = sp1F << 4; + o->oAngleVelYaw = bhvParams1stByte << 4; o->oFaceAngleYaw += o->oAngleVelYaw; } diff --git a/src/game/behaviors/seesaw_platform.inc.c b/src/game/behaviors/seesaw_platform.inc.c index 5b2e4bc1..b55078be 100644 --- a/src/game/behaviors/seesaw_platform.inc.c +++ b/src/game/behaviors/seesaw_platform.inc.c @@ -21,11 +21,11 @@ static Collision const *sSeesawPlatformCollisionModels[] = { * Init function for bhvSeesawPlatform. */ void bhv_seesaw_platform_init(void) { - o->collisionData = segmented_to_virtual(sSeesawPlatformCollisionModels[o->oBehParams2ndByte]); + o->collisionData = segmented_to_virtual(sSeesawPlatformCollisionModels[o->oBhvParams2ndByte]); // The S-shaped seesaw platform in BitS is large, so increase its collision // distance - if (o->oBehParams2ndByte == 2) { + if (o->oBhvParams2ndByte == 2) { o->oCollisionDistance = 2000.0f; } } diff --git a/src/game/behaviors/sliding_platform.inc.c b/src/game/behaviors/sliding_platform.inc.c index 1b8f73ce..a1466846 100644 --- a/src/game/behaviors/sliding_platform.inc.c +++ b/src/game/behaviors/sliding_platform.inc.c @@ -5,7 +5,7 @@ void bhv_wf_sliding_platform_init(void) { o->oPosX += 2.0f; o->oHomeX = o->oPosX; - switch (o->oBehParams2ndByte) { + switch (o->oBhvParams2ndByte) { case WF_SLID_BRICK_PTFM_BP_MOV_VEL_10: o->oWFSlidBrickPtfmMovVel = 10.0f; break; diff --git a/src/game/behaviors/sliding_platform_2.inc.c b/src/game/behaviors/sliding_platform_2.inc.c index 853bc409..888d1dc2 100644 --- a/src/game/behaviors/sliding_platform_2.inc.c +++ b/src/game/behaviors/sliding_platform_2.inc.c @@ -12,19 +12,19 @@ static Collision const *sSlidingPlatform2CollisionData[] = { }; void bhv_sliding_plat_2_init(void) { - s32 collisionDataIndex = ((u16)(o->oBehParams >> 16) & 0x0380) >> 7; + s32 collisionDataIndex = ((u16)(o->oBhvParams >> 16) & 0x0380) >> 7; o->collisionData = segmented_to_virtual(sSlidingPlatform2CollisionData[collisionDataIndex]); - o->oBackAndForthPlatformPathLength = 50.0f * ((u16)(o->oBehParams >> 16) & 0x003F); + o->oBackAndForthPlatformPathLength = 50.0f * ((u16)(o->oBhvParams >> 16) & 0x003F); if (collisionDataIndex < 5 || collisionDataIndex > 6) { o->oBackAndForthPlatformVel = 15.0f; - if ((u16)(o->oBehParams >> 16) & 0x0040) { + if ((u16)(o->oBhvParams >> 16) & 0x0040) { o->oMoveAngleYaw += 0x8000; } } else { o->oBackAndForthPlatformVel = 10.0f; - if ((u16)(o->oBehParams >> 16) & 0x0040) { + if ((u16)(o->oBhvParams >> 16) & 0x0040) { o->oBackAndForthPlatformDirection = -1.0f; } else { o->oBackAndForthPlatformDirection = 1.0f; diff --git a/src/game/behaviors/snow_mound.inc.c b/src/game/behaviors/snow_mound.inc.c index 3710f86e..6d233fcd 100644 --- a/src/game/behaviors/snow_mound.inc.c +++ b/src/game/behaviors/snow_mound.inc.c @@ -25,7 +25,7 @@ void bhv_sliding_snow_mound_loop(void) { } void bhv_snow_mound_spawn_loop(void) { - struct Object *sp1C; + struct Object *snowMound; if (!is_point_within_radius_of_mario(o->oPosX, o->oPosY, o->oPosZ, 6000) || o->oPosY + 1000.0f < gMarioObject->header.gfx.pos[1]) { @@ -33,12 +33,12 @@ void bhv_snow_mound_spawn_loop(void) { } if (o->oTimer == 64 || o->oTimer == 128 || o->oTimer == 192 || o->oTimer == 224 || o->oTimer == 256) { - sp1C = spawn_object(o, MODEL_SL_SNOW_TRIANGLE, bhvSlidingSnowMound); + snowMound = spawn_object(o, MODEL_SL_SNOW_TRIANGLE, bhvSlidingSnowMound); } if (o->oTimer == 256) { - sp1C->header.gfx.scale[0] = 2.0f; - sp1C->header.gfx.scale[1] = 2.0f; + snowMound->header.gfx.scale[0] = 2.0f; + snowMound->header.gfx.scale[1] = 2.0f; } if (o->oTimer >= 256) { diff --git a/src/game/behaviors/snowman.inc.c b/src/game/behaviors/snowman.inc.c index 93ed9dfd..6fda98bc 100644 --- a/src/game/behaviors/snowman.inc.c +++ b/src/game/behaviors/snowman.inc.c @@ -60,6 +60,7 @@ void snowmans_bottom_act_1(void) { o->oPathedStartWaypoint = segmented_to_virtual(&ccm_seg7_trajectory_snowman); collisionFlags = object_step_without_floor_orient(); + //! Uninitialized parameter, but the parameter is unused in the called function followStatus = cur_obj_follow_path(followStatus); o->oSnowmansBottomUnkF8 = o->oPathedTargetYaw; o->oMoveAngleYaw = approach_s16_symmetric(o->oMoveAngleYaw, o->oSnowmansBottomUnkF8, 0x400); @@ -165,7 +166,7 @@ void bhv_snowmans_bottom_loop(void) { void bhv_snowmans_head_init(void) { u8 starFlags = save_file_get_star_flags(gCurrSaveFileNum - 1, COURSE_NUM_TO_INDEX(gCurrCourseNum)); - s8 sp36 = (o->oBehParams >> 24) & 0xFF; + s8 sp36 = (o->oBhvParams >> 24) & 0xFF; cur_obj_scale(0.7f); diff --git a/src/game/behaviors/snufit.inc.c b/src/game/behaviors/snufit.inc.c index d3a9fc59..a66cb304 100644 --- a/src/game/behaviors/snufit.inc.c +++ b/src/game/behaviors/snufit.inc.c @@ -31,7 +31,7 @@ struct ObjectHitbox sSnufitBulletHitbox = { }; /** - * This geo function shifts snufit's mask when it shrinks down, + * This geo function shifts snufit's mask when it shrinks down, * since the parts move independently. */ Gfx *geo_snufit_move_mask(s32 callContext, struct GraphNode *node, UNUSED Mat4 *c) { @@ -193,7 +193,7 @@ void bhv_snufit_balls_loop(void) { o->oGravity = -4.0f; cur_obj_become_intangible(); - } else if (o->oAction == 1 + } else if (o->oAction == 1 || (o->oMoveFlags & (OBJ_MOVE_MASK_ON_GROUND | OBJ_MOVE_HIT_WALL))) { // The Snufit shot Mario and has fulfilled its lonely existance. //! The above check could theoretically be avoided by finding a geometric diff --git a/src/game/behaviors/sound_birds.inc.c b/src/game/behaviors/sound_birds.inc.c index 214c0c40..dd15324f 100644 --- a/src/game/behaviors/sound_birds.inc.c +++ b/src/game/behaviors/sound_birds.inc.c @@ -5,7 +5,7 @@ void bhv_birds_sound_loop(void) { return; } - switch (o->oBehParams2ndByte) { + switch (o->oBhvParams2ndByte) { case 0: cur_obj_play_sound_1(SOUND_OBJ2_BIRD_CHIRP1); break; diff --git a/src/game/behaviors/sparkle_spawn_star.inc.c b/src/game/behaviors/sparkle_spawn_star.inc.c index f9d7510b..52515285 100644 --- a/src/game/behaviors/sparkle_spawn_star.inc.c +++ b/src/game/behaviors/sparkle_spawn_star.inc.c @@ -13,14 +13,16 @@ struct ObjectHitbox sSparkleSpawnStarHitbox = { }; void bhv_spawned_star_init(void) { - s32 sp24; + s32 starIndex; if (!(o->oInteractionSubtype & INT_SUBTYPE_NO_EXIT)) { - o->oBehParams = o->parentObj->oBehParams; + o->oBhvParams = o->parentObj->oBhvParams; } - sp24 = (o->oBehParams >> 24) & 0xFF; - if (bit_shift_left(sp24) & save_file_get_star_flags(gCurrSaveFileNum - 1, COURSE_NUM_TO_INDEX(gCurrCourseNum))) { + starIndex = (o->oBhvParams >> 24) & 0xFF; + + if (bit_shift_left(starIndex) + & save_file_get_star_flags(gCurrSaveFileNum - 1, COURSE_NUM_TO_INDEX(gCurrCourseNum))) { cur_obj_set_model(MODEL_TRANSPARENT_STAR); } @@ -69,7 +71,7 @@ void bhv_spawned_star_loop(void) { set_time_stop_flags(TIME_STOP_ENABLED | TIME_STOP_MARIO_AND_DOORS); o->activeFlags |= ACTIVE_FLAG_INITIATED_TIME_STOP; o->oAngleVelYaw = 0x800; - if (o->oBehParams2ndByte == 0) { + if (o->oBhvParams2ndByte == 0) { set_home_to_mario(); } else { set_y_home_to_pos(); @@ -123,9 +125,9 @@ void bhv_spawned_star_loop(void) { o->oInteractStatus = 0; } -void bhv_spawn_star_no_level_exit(u32 sp20) { - struct Object *sp1C = spawn_object(o, MODEL_STAR, bhvSpawnedStarNoLevelExit); - sp1C->oBehParams = sp20 << 24; - sp1C->oInteractionSubtype = INT_SUBTYPE_NO_EXIT; - obj_set_angle(sp1C, 0, 0, 0); +void bhv_spawn_star_no_level_exit(u32 starIndex) { + struct Object *star = spawn_object(o, MODEL_STAR, bhvSpawnedStarNoLevelExit); + star->oBhvParams = starIndex << 24; + star->oInteractionSubtype = INT_SUBTYPE_NO_EXIT; + obj_set_angle(star, 0, 0, 0); } diff --git a/src/game/behaviors/spawn_star.inc.c b/src/game/behaviors/spawn_star.inc.c index 96f71a63..9a0ee301 100644 --- a/src/game/behaviors/spawn_star.inc.c +++ b/src/game/behaviors/spawn_star.inc.c @@ -13,10 +13,10 @@ static struct ObjectHitbox sCollectStarHitbox = { }; void bhv_collect_star_init(void) { - s8 starId = (o->oBehParams >> 24) & 0xFF; + s8 starIndex = (o->oBhvParams >> 24) & 0xFF; u8 currentLevelStarFlags = save_file_get_star_flags(gCurrSaveFileNum - 1, COURSE_NUM_TO_INDEX(gCurrCourseNum)); - if (currentLevelStarFlags & (1 << starId)) { + if (currentLevelStarFlags & (1 << starIndex)) { o->header.gfx.sharedChild = gLoadedGraphNodes[MODEL_TRANSPARENT_STAR]; } else { o->header.gfx.sharedChild = gLoadedGraphNodes[MODEL_STAR]; @@ -41,7 +41,7 @@ void bhv_star_spawn_init(void) { o->oForwardVel = o->oStarSpawnDisFromHome / 30.0f; o->oStarSpawnUnkFC = o->oPosY; - if (o->oBehParams2ndByte == 0 || gCurrCourseNum == COURSE_BBH) { + if (o->oBhvParams2ndByte == 0 || gCurrCourseNum == COURSE_BBH) { cutscene_object(CUTSCENE_STAR_SPAWN, o); } else { cutscene_object(CUTSCENE_RED_COIN_STAR_SPAWN, o); @@ -111,32 +111,32 @@ void bhv_star_spawn_loop(void) { } } -struct Object *spawn_star(struct Object *sp30, f32 sp34, f32 sp38, f32 sp3C) { - sp30 = spawn_object_abs_with_rot(o, 0, MODEL_STAR, bhvStarSpawnCoordinates, o->oPosX, o->oPosY, - o->oPosZ, 0, 0, 0); - sp30->oBehParams = o->oBehParams; - sp30->oHomeX = sp34; - sp30->oHomeY = sp38; - sp30->oHomeZ = sp3C; - sp30->oFaceAnglePitch = 0; - sp30->oFaceAngleRoll = 0; - return sp30; +struct Object *spawn_star(struct Object *star, f32 homeX, f32 homeY, f32 homeZ) { + star = spawn_object_abs_with_rot(o, 0, MODEL_STAR, bhvStarSpawnCoordinates, + o->oPosX, o->oPosY, o->oPosZ, 0, 0, 0); + star->oBhvParams = o->oBhvParams; + star->oHomeX = homeX; + star->oHomeY = homeY; + star->oHomeZ = homeZ; + star->oFaceAnglePitch = 0; + star->oFaceAngleRoll = 0; + return star; } -void spawn_default_star(f32 sp20, f32 sp24, f32 sp28) { - struct Object *sp1C = spawn_star(sp1C, sp20, sp24, sp28); - sp1C->oBehParams2ndByte = 0; +void spawn_default_star(f32 homeX, f32 homeY, f32 homeZ) { + struct Object *star = spawn_star(star, homeX, homeY, homeZ); + star->oBhvParams2ndByte = 0; } -void spawn_red_coin_cutscene_star(f32 sp20, f32 sp24, f32 sp28) { - struct Object *sp1C = spawn_star(sp1C, sp20, sp24, sp28); - sp1C->oBehParams2ndByte = 1; +void spawn_red_coin_cutscene_star(f32 homeX, f32 homeY, f32 homeZ) { + struct Object *star = spawn_star(star, homeX, homeY, homeZ); + star->oBhvParams2ndByte = 1; } -void spawn_no_exit_star(f32 sp20, f32 sp24, f32 sp28) { - struct Object *sp1C = spawn_star(sp1C, sp20, sp24, sp28); - sp1C->oBehParams2ndByte = 1; - sp1C->oInteractionSubtype |= INT_SUBTYPE_NO_EXIT; +void spawn_no_exit_star(f32 homeX, f32 homeY, f32 homeZ) { + struct Object *star = spawn_star(star, homeX, homeY, homeZ); + star->oBhvParams2ndByte = 1; + star->oInteractionSubtype |= INT_SUBTYPE_NO_EXIT; } void bhv_hidden_red_coin_star_init(void) { @@ -150,7 +150,7 @@ void bhv_hidden_red_coin_star_init(void) { if (count == 0) { struct Object *star = spawn_object_abs_with_rot(o, 0, MODEL_STAR, bhvStar, o->oPosX, o->oPosY, o->oPosZ, 0, 0, 0); - star->oBehParams = o->oBehParams; + star->oBhvParams = o->oBhvParams; o->activeFlags = ACTIVE_FLAG_DEACTIVATED; } diff --git a/src/game/behaviors/square_platform_cycle.inc.c b/src/game/behaviors/square_platform_cycle.inc.c index a3525a82..c4f639f3 100644 --- a/src/game/behaviors/square_platform_cycle.inc.c +++ b/src/game/behaviors/square_platform_cycle.inc.c @@ -14,7 +14,7 @@ void bhv_squarish_path_moving_loop(void) { switch (o->oAction) { case 0: - o->oAction = (o->oBehParams2ndByte & 3) + 1; + o->oAction = (o->oBhvParams2ndByte & 0x03) + 1; break; case 1: if (square_plat_set_yaw_until_timer(0, 60)) { diff --git a/src/game/behaviors/strong_wind_particle.inc.c b/src/game/behaviors/strong_wind_particle.inc.c index 993c22a7..a753bf10 100644 --- a/src/game/behaviors/strong_wind_particle.inc.c +++ b/src/game/behaviors/strong_wind_particle.inc.c @@ -26,7 +26,7 @@ void bhv_strong_wind_particle_loop(void) { o->oForwardVel = coss(o->oMoveAnglePitch) * 100.0f; o->oVelY = sins(o->oMoveAnglePitch) * -100.0f; - o->oMoveAngleYaw += random_f32_around_zero(o->oBehParams2ndByte * 500); // Wind spread + o->oMoveAngleYaw += random_f32_around_zero(o->oBhvParams2ndByte * 500); // Wind spread o->oOpacity = 100; } diff --git a/src/game/behaviors/switch_hidden_objects.inc.c b/src/game/behaviors/switch_hidden_objects.inc.c index 0dc44789..5561554d 100644 --- a/src/game/behaviors/switch_hidden_objects.inc.c +++ b/src/game/behaviors/switch_hidden_objects.inc.c @@ -13,51 +13,52 @@ struct ObjectHitbox sBreakableBoxHitbox = { }; void breakable_box_init(void) { - o->oHiddenObjectUnkF4 = NULL; + o->oHiddenObjectPurpleSwitch = NULL; o->oAnimState = 1; - switch (o->oBehParams2ndByte) { - case 0: + switch (o->oBhvParams2ndByte) { + case BREAKABLE_BOX_BP_NO_COINS: o->oNumLootCoins = 0; break; - case 1: + case BREAKABLE_BOX_BP_3_COINS: o->oNumLootCoins = 3; break; - case 2: + case BREAKABLE_BOX_BP_5_COINS: o->oNumLootCoins = 5; break; - case 3: + case BREAKABLE_BOX_BP_GIANT: cur_obj_scale(1.5f); break; } } void hidden_breakable_box_actions(void) { - struct Object *sp1C; + struct Object *purpleSwitch; obj_set_hitbox(o, &sBreakableBoxHitbox); cur_obj_set_model(MODEL_BREAKABLE_BOX_SMALL); - if (o->oAction == 0) { + if (o->oAction == HIDDEN_OBJECT_ACT_INACTIVE) { cur_obj_disable_rendering(); cur_obj_become_intangible(); if (o->oTimer == 0) { breakable_box_init(); } - if (o->oHiddenObjectUnkF4 == NULL) { - o->oHiddenObjectUnkF4 = cur_obj_nearest_object_with_behavior(bhvFloorSwitchHiddenObjects); + if (o->oHiddenObjectPurpleSwitch == NULL) { + o->oHiddenObjectPurpleSwitch = + cur_obj_nearest_object_with_behavior(bhvFloorSwitchHiddenObjects); } - if ((sp1C = o->oHiddenObjectUnkF4) != NULL) { - if (sp1C->oAction == 2) { + if ((purpleSwitch = o->oHiddenObjectPurpleSwitch) != NULL) { + if (purpleSwitch->oAction == PURPLE_SWITCH_ACT_TICKING) { o->oAction++; cur_obj_enable_rendering(); cur_obj_unhide(); } } - } else if (o->oAction == 1) { + } else if (o->oAction == HIDDEN_OBJECT_ACT_ACTIVE) { cur_obj_become_tangible(); if (cur_obj_wait_then_blink(360, 20)) { - o->oAction = 0; + o->oAction = HIDDEN_OBJECT_ACT_INACTIVE; } if (cur_obj_was_attacked_or_ground_pounded()) { spawn_mist_particles(); @@ -66,49 +67,50 @@ void hidden_breakable_box_actions(void) { cur_obj_play_sound_2(SOUND_GENERAL_BREAK_BOX); } load_object_collision_model(); - } else { + } else { // HIDDEN_OBJECT_ACT_BROKEN cur_obj_become_intangible(); cur_obj_disable_rendering(); o->oInteractStatus = 0; - if ((sp1C = o->oHiddenObjectUnkF4) != NULL) { - if (sp1C->oAction == 0) { - o->oAction = 0; + if ((purpleSwitch = o->oHiddenObjectPurpleSwitch) != NULL) { + if (purpleSwitch->oAction == PURPLE_SWITCH_ACT_IDLE) { + o->oAction = HIDDEN_OBJECT_ACT_INACTIVE; } } } } -void hidden_unbreakable_box_actions(void) { - struct Object *sp1C; +void hidden_wdw_platform_actions(void) { + struct Object *purpleSwitch; obj_set_collision_data(o, wdw_seg7_collision_07018528); - if (o->oAction == 0) { + if (o->oAction == HIDDEN_OBJECT_ACT_INACTIVE) { cur_obj_disable_rendering(); cur_obj_become_intangible(); - if (o->oHiddenObjectUnkF4 == NULL) { - o->oHiddenObjectUnkF4 = cur_obj_nearest_object_with_behavior(bhvFloorSwitchHiddenObjects); + if (o->oHiddenObjectPurpleSwitch == NULL) { + o->oHiddenObjectPurpleSwitch = + cur_obj_nearest_object_with_behavior(bhvFloorSwitchHiddenObjects); } - if ((sp1C = o->oHiddenObjectUnkF4) != NULL) { - if (sp1C->oAction == 2) { + if ((purpleSwitch = o->oHiddenObjectPurpleSwitch) != NULL) { + if (purpleSwitch->oAction == PURPLE_SWITCH_ACT_TICKING) { o->oAction++; cur_obj_enable_rendering(); cur_obj_unhide(); } } - } else { + } else { // HIDDEN_OBJECT_ACT_ACTIVE cur_obj_become_tangible(); if (cur_obj_wait_then_blink(360, 20)) { - o->oAction = 0; + o->oAction = HIDDEN_OBJECT_ACT_INACTIVE; } load_object_collision_model(); } } void bhv_hidden_object_loop(void) { - if (o->oBehParams2ndByte == 0) { - hidden_breakable_box_actions(); // Confused, that function has code depending on the action + if (o->oBhvParams2ndByte == HIDDEN_OBJECT_BP_BREAKABLE_BOX) { + hidden_breakable_box_actions(); } else { - hidden_unbreakable_box_actions(); + hidden_wdw_platform_actions(); } } diff --git a/src/game/behaviors/thi_top.inc.c b/src/game/behaviors/thi_top.inc.c index 8b5a9bca..dece40a1 100644 --- a/src/game/behaviors/thi_top.inc.c +++ b/src/game/behaviors/thi_top.inc.c @@ -1,7 +1,7 @@ // thi_top.inc.c -static struct SpawnParticlesInfo sThiTopPuffs = { - /* behParam: */ 0, +static struct SpawnParticlesInfo sTHITopPuffs = { + /* bhvParam: */ 0, /* count: */ 30, /* model: */ MODEL_WHITE_PARTICLE_SMALL, /* offsetY: */ 0, @@ -32,7 +32,7 @@ void bhv_thi_tiny_island_top_loop(void) { if (o->oDistanceToMario < 500.0f) { if (gMarioStates[0].action == ACT_GROUND_POUND_LAND) { o->oAction++; - cur_obj_spawn_particles(&sThiTopPuffs); + cur_obj_spawn_particles(&sTHITopPuffs); spawn_triangle_break_particles(20, MODEL_DIRT_ANIMATION, 0.3f, 3); cur_obj_play_sound_2(SOUND_GENERAL_ACTIVATE_CAP_SWITCH); cur_obj_hide(); diff --git a/src/game/behaviors/thwomp.inc.c b/src/game/behaviors/thwomp.inc.c index 00093c9d..41157d3d 100644 --- a/src/game/behaviors/thwomp.inc.c +++ b/src/game/behaviors/thwomp.inc.c @@ -1,25 +1,25 @@ // thwomp.inc.c -void grindel_thwomp_act_4(void) { +void grindel_thwomp_act_idle_at_bottom(void) { if (o->oTimer == 0) { - o->oThwompRandomTimer = random_float() * 10.0f + 20.0f; + o->oGrindelThwompRandomTimer = random_float() * 10.0f + 20.0f; // [20, 29] } - if (o->oTimer > o->oThwompRandomTimer) { - o->oAction = 0; + if (o->oTimer > o->oGrindelThwompRandomTimer) { + o->oAction = GRINDEL_THWOMP_ACT_RAISE; } } -void grindel_thwomp_act_2(void) { +void grindel_thwomp_act_lower(void) { o->oVelY += -4.0f; o->oPosY += o->oVelY; if (o->oPosY < o->oHomeY) { o->oPosY = o->oHomeY; o->oVelY = 0.0f; - o->oAction = 3; + o->oAction = GRINDEL_THWOMP_ACT_LAND; } } -void grindel_thwomp_act_3(void) { +void grindel_thwomp_act_land(void) { if (o->oTimer == 0) { if (o->oDistanceToMario < 1500.0f) { cur_obj_shake_screen(SHAKE_POS_SMALL); @@ -27,22 +27,22 @@ void grindel_thwomp_act_3(void) { } } if (o->oTimer >= 10) { - o->oAction = 4; + o->oAction = GRINDEL_THWOMP_ACT_IDLE_AT_BOTTOM; } } -void grindel_thwomp_act_1(void) { +void grindel_thwomp_act_idle_at_top(void) { if (o->oTimer == 0) { - o->oThwompRandomTimer = random_float() * 30.0f + 10.0f; + o->oGrindelThwompRandomTimer = random_float() * 30.0f + 10.0f; // [10, 39] } - if (o->oTimer > o->oThwompRandomTimer) { - o->oAction = 2; + if (o->oTimer > o->oGrindelThwompRandomTimer) { + o->oAction = GRINDEL_THWOMP_ACT_LOWER; } } -void grindel_thwomp_act_0(void) { - if (o->oBehParams2ndByte + 40 < o->oTimer) { - o->oAction = 1; +void grindel_thwomp_act_raise(void) { + if (o->oTimer > o->oBhvParams2ndByte + 40) { + o->oAction = GRINDEL_THWOMP_ACT_IDLE_AT_TOP; o->oPosY += 5.0f; } else { o->oPosY += 10.0f; @@ -50,11 +50,11 @@ void grindel_thwomp_act_0(void) { } void (*sGrindelThwompActions[])(void) = { - grindel_thwomp_act_0, - grindel_thwomp_act_1, - grindel_thwomp_act_2, - grindel_thwomp_act_3, - grindel_thwomp_act_4, + grindel_thwomp_act_raise, + grindel_thwomp_act_idle_at_top, + grindel_thwomp_act_lower, + grindel_thwomp_act_land, + grindel_thwomp_act_idle_at_bottom, }; void bhv_grindel_thwomp_loop(void) { diff --git a/src/game/behaviors/tilting_inverted_pyramid.inc.c b/src/game/behaviors/tilting_inverted_pyramid.inc.c index 77193dc7..9c09f04c 100644 --- a/src/game/behaviors/tilting_inverted_pyramid.inc.c +++ b/src/game/behaviors/tilting_inverted_pyramid.inc.c @@ -94,7 +94,7 @@ void bhv_tilting_inverted_pyramid_loop(void) { dy = 500.0f; dz = gMarioObject->oPosZ - o->oPosZ; d = sqrtf(dx * dx + dy * dy + dz * dz); - + //! Always true since dy = 500, making d >= 500. if (d != 0.0f) { // Normalizing @@ -120,7 +120,7 @@ void bhv_tilting_inverted_pyramid_loop(void) { o->oTiltingPyramidMarioOnPlatform = FALSE; } - // Approach the normals by 0.01f towards the new goal, then create a transform matrix and orient the object. + // Approach the normals by 0.01f towards the new goal, then create a transform matrix and orient the object. // Outside of the other conditionals since it needs to tilt regardless of whether Mario is on. o->oTiltingPyramidNormalX = approach_by_increment(dx, o->oTiltingPyramidNormalX, 0.01f); o->oTiltingPyramidNormalY = approach_by_increment(dy, o->oTiltingPyramidNormalY, 0.01f); diff --git a/src/game/behaviors/tower_platform.inc.c b/src/game/behaviors/tower_platform.inc.c index aca5c371..ea2ec202 100644 --- a/src/game/behaviors/tower_platform.inc.c +++ b/src/game/behaviors/tower_platform.inc.c @@ -99,14 +99,14 @@ void spawn_wf_platform_group(void) { o->oPlatformSpawnerUnk104 = 380.0f; o->oPlatformSpawnerUnk108 = 3.0f; - spawn_and_init_wf_platforms(MODEL_WF_TOWER_SQUARE_PLATORM, bhvWfSolidTowerPlatform); - spawn_and_init_wf_platforms(MODEL_WF_TOWER_SQUARE_PLATORM, bhvWfSlidingTowerPlatform); - spawn_and_init_wf_platforms(MODEL_WF_TOWER_SQUARE_PLATORM, bhvWfSolidTowerPlatform); - spawn_and_init_wf_platforms(MODEL_WF_TOWER_SQUARE_PLATORM, bhvWfSlidingTowerPlatform); - spawn_and_init_wf_platforms(MODEL_WF_TOWER_SQUARE_PLATORM, bhvWfSolidTowerPlatform); - spawn_and_init_wf_platforms(MODEL_WF_TOWER_SQUARE_PLATORM, bhvWfSlidingTowerPlatform); - spawn_and_init_wf_platforms(MODEL_WF_TOWER_SQUARE_PLATORM, bhvWfSolidTowerPlatform); - spawn_and_init_wf_platforms(MODEL_WF_TOWER_SQUARE_PLATORM_ELEVATOR, bhvWfElevatorTowerPlatform); + spawn_and_init_wf_platforms(MODEL_WF_TOWER_SQUARE_PLATORM, bhvWFSolidTowerPlatform); + spawn_and_init_wf_platforms(MODEL_WF_TOWER_SQUARE_PLATORM, bhvWFSlidingTowerPlatform); + spawn_and_init_wf_platforms(MODEL_WF_TOWER_SQUARE_PLATORM, bhvWFSolidTowerPlatform); + spawn_and_init_wf_platforms(MODEL_WF_TOWER_SQUARE_PLATORM, bhvWFSlidingTowerPlatform); + spawn_and_init_wf_platforms(MODEL_WF_TOWER_SQUARE_PLATORM, bhvWFSolidTowerPlatform); + spawn_and_init_wf_platforms(MODEL_WF_TOWER_SQUARE_PLATORM, bhvWFSlidingTowerPlatform); + spawn_and_init_wf_platforms(MODEL_WF_TOWER_SQUARE_PLATORM, bhvWFSolidTowerPlatform); + spawn_and_init_wf_platforms(MODEL_WF_TOWER_SQUARE_PLATORM_ELEVATOR, bhvWFElevatorTowerPlatform); } void bhv_tower_platform_group_loop(void) { diff --git a/src/game/behaviors/tox_box.inc.c b/src/game/behaviors/tox_box.inc.c index 47c25b20..3751df8a 100644 --- a/src/game/behaviors/tox_box.inc.c +++ b/src/game/behaviors/tox_box.inc.c @@ -1,12 +1,81 @@ // tox_box.inc.c -s8 D_8032F8F0[] = { 4, 1, 4, 1, 6, 1, 6, 1, 5, 1, 5, 1, 6, 1, 6, 1, 5, 1, 2, 4, 1, 4, 1, 4, 1, 2, - 5, 1, 5, 1, 7, 1, 7, 1, 4, 1, 4, 1, 7, 1, 7, 1, 5, 1, 5, 1, 5, 1, 2, 4, 1, -1 }; -s8 D_8032F924[] = { 4, 1, 4, 1, 7, 1, 7, 1, 7, 1, 2, 6, 1, 6, 1, 6, 1, 5, - 1, 5, 1, 6, 1, 5, 1, 5, 1, 2, 4, 1, 4, 1, 7, 1, -1 }; -s8 D_8032F948[] = { 4, 1, 4, 1, 4, 1, 4, 1, 4, 1, 2, 5, 1, 5, 1, 5, 1, 5, - 1, 5, 1, 7, 1, 2, 6, 1, 6, 1, 5, 1, 2, 4, 1, 7, 1, -1 }; -s8 *D_8032F96C[] = { D_8032F8F0, D_8032F924, D_8032F948 }; +#define FORWARD TOX_BOX_ACT_ROLL_FORWARD, TOX_BOX_ACT_ROLL_LAND +#define BACKWARD TOX_BOX_ACT_ROLL_BACKWARD, TOX_BOX_ACT_ROLL_LAND +#define RIGHT TOX_BOX_ACT_ROLL_RIGHT, TOX_BOX_ACT_ROLL_LAND +#define LEFT TOX_BOX_ACT_ROLL_LEFT, TOX_BOX_ACT_ROLL_LAND +#define IDLE TOX_BOX_ACT_IDLE +#define END TOX_BOX_ACT_TABLE_END + +s8 sToxBoxActionTable1[] = { + FORWARD, FORWARD, RIGHT, RIGHT, BACKWARD, BACKWARD, RIGHT, RIGHT, BACKWARD, IDLE, + + FORWARD, FORWARD, FORWARD, IDLE, + + BACKWARD, BACKWARD, LEFT, LEFT, FORWARD, FORWARD, LEFT, LEFT, BACKWARD, BACKWARD, BACKWARD, IDLE, + + FORWARD, END, +}; + +s8 sToxBoxActionTable2[] = { + FORWARD, FORWARD, LEFT, LEFT, LEFT, IDLE, + + RIGHT, RIGHT, RIGHT, BACKWARD, BACKWARD, RIGHT, BACKWARD, BACKWARD, IDLE, + + FORWARD, FORWARD, LEFT, END, +}; + +s8 sToxBoxActionTable3[] = { + FORWARD, FORWARD, FORWARD, FORWARD, FORWARD, IDLE, + + BACKWARD, BACKWARD, BACKWARD, BACKWARD, BACKWARD, LEFT, IDLE, + + RIGHT, RIGHT, BACKWARD, IDLE, + + FORWARD, LEFT, END, +}; + +#undef FORWARD +#undef BACKWARD +#undef RIGHT +#undef LEFT +#undef IDLE +#undef END + +/* + * (number = table, v = direction, * = idle) + * + * +---+ +---+ + * |1 *| |1 *| + * +---+---+---+ +---+ +---+ +---+ + * | 1 | 1 | 1 | |1 v| |2 *| | | + * +---+---+---+ +---+---+---+---+---+ +---+---+---+ + * | 1 | | 1 | | 1 | | | | 2 | | | | | + * +---+---+ +---+---+---+---+---+---+---+---+---+---+---+---+ + * | |1 *| | 1 | 1 | 1 | | 2 |2 v| | | | | + * +---+---+ +---+---+---+ +---+---+---+---+ +---+ + * | 2 | + * +---+---+---+---+---+---+---+ +---+ + * | 2 | 2 | 2 |2 *| | |3 *| | | + * +---+---+---+---+---+---+---+---+---+ + * | 3 |3 v|3 *| + * +---+---+---+ + * | 3 | + * +---+ + * | 3 | + * +---+ + * | 3 | + * +---+ + * | 3 | + * +---+ + * |3 *| + * +---+ + */ +s8 *sToxBoxActionTables[] = { + /* TOX_BOX_BP_MOVEMENT_PATTERN_1 */ sToxBoxActionTable1, + /* TOX_BOX_BP_MOVEMENT_PATTERN_2 */ sToxBoxActionTable2, + /* TOX_BOX_BP_MOVEMENT_PATTERN_3 */ sToxBoxActionTable3, +}; void tox_box_shake_screen(void) { if (o->oDistanceToMario < 3000.0f) { @@ -14,10 +83,10 @@ void tox_box_shake_screen(void) { } } -void tox_box_move(f32 forwardVel, f32 a1, s16 deltaPitch, s16 deltaRoll) { +void tox_box_move(f32 forwardVel, f32 upVel, s16 deltaPitch, s16 deltaRoll) { o->oPosY = 99.41124 * sins((f32)(o->oTimer + 1) / 8 * 0x8000) + o->oHomeY + 3.0f; o->oForwardVel = forwardVel; - o->oUpVel = a1; + o->oUpVel = upVel; o->oFaceAnglePitch += deltaPitch; if ((s16) o->oFaceAnglePitch < 0) { @@ -28,28 +97,28 @@ void tox_box_move(f32 forwardVel, f32 a1, s16 deltaPitch, s16 deltaRoll) { cur_obj_set_pos_via_transform(); if (o->oTimer == 7) { - o->oAction = cur_obj_progress_direction_table(); + o->oAction = cur_obj_progress_action_table(); cur_obj_play_sound_2(SOUND_GENERAL_UNK46); } } -void tox_box_act_4(void) { +void tox_box_act_roll_forward(void) { tox_box_move(64.0f, 0.0f, 0x800, 0); } -void tox_box_act_5(void) { +void tox_box_act_roll_backward(void) { tox_box_move(-64.0f, 0.0f, -0x800, 0); } -void tox_box_act_6(void) { +void tox_box_act_roll_right(void) { tox_box_move(0.0f, -64.0f, 0, 0x800); } -void tox_box_act_7(void) { +void tox_box_act_roll_left(void) { tox_box_move(0.0f, 64.0f, 0, -0x800); } -void tox_box_act_1(void) { +void tox_box_act_roll_land(void) { o->oForwardVel = 0.0f; if (o->oTimer == 0) { @@ -59,36 +128,36 @@ void tox_box_act_1(void) { o->oPosY = o->oHomeY + 3.0f; if (o->oTimer == 20) { - o->oAction = cur_obj_progress_direction_table(); + o->oAction = cur_obj_progress_action_table(); } } -void tox_box_act_2(void) { +void tox_box_act_idle(void) { if (o->oTimer == 20) { - o->oAction = cur_obj_progress_direction_table(); + o->oAction = cur_obj_progress_action_table(); } } -void tox_box_act_3(void) { +void tox_box_act_unused_idle(void) { if (o->oTimer == 20) { - o->oAction = cur_obj_progress_direction_table(); + o->oAction = cur_obj_progress_action_table(); } } -void tox_box_act_0(void) { - s8 *sp1C = D_8032F96C[o->oBehParams2ndByte]; - o->oAction = cur_obj_set_direction_table(sp1C); +void tox_box_act_init(void) { + s8 *actionTable = sToxBoxActionTables[o->oBhvParams2ndByte]; + o->oAction = cur_obj_set_action_table(actionTable); } void (*sToxBoxActions[])(void) = { - tox_box_act_0, - tox_box_act_1, - tox_box_act_2, - tox_box_act_3, - tox_box_act_4, - tox_box_act_5, - tox_box_act_6, - tox_box_act_7, + tox_box_act_init, + tox_box_act_roll_land, + tox_box_act_idle, + tox_box_act_unused_idle, + tox_box_act_roll_forward, + tox_box_act_roll_backward, + tox_box_act_roll_right, + tox_box_act_roll_left, }; void bhv_tox_box_loop(void) { diff --git a/src/game/behaviors/treasure_chest.inc.c b/src/game/behaviors/treasure_chest.inc.c index 55a6b0cc..e1fe6d60 100644 --- a/src/game/behaviors/treasure_chest.inc.c +++ b/src/game/behaviors/treasure_chest.inc.c @@ -39,8 +39,8 @@ void bhv_treasure_chest_top_loop(void) { if (o->oFaceAnglePitch < -0x4000) { o->oFaceAnglePitch = -0x4000; o->oAction++; - if (o->parentObj->oBehParams2ndByte != 4) { - spawn_orange_number(o->parentObj->oBehParams2ndByte, 0, -40, 0); + if (o->parentObj->oBhvParams2ndByte != 4) { + spawn_orange_number(o->parentObj->oBhvParams2ndByte, 0, -40, 0); } } break; @@ -71,7 +71,7 @@ void bhv_treasure_chest_bottom_loop(void) { if (obj_check_if_facing_toward_angle(o->oMoveAngleYaw, gMarioObject->header.gfx.angle[1] + 0x8000, 0x3000) && is_point_within_radius_of_mario(o->oPosX, o->oPosY, o->oPosZ, 150) && !o->parentObj->oTreasureChestUnkF8) { - if (o->parentObj->oTreasureChestUnkF4 == o->oBehParams2ndByte) { + if (o->parentObj->oTreasureChestUnkF4 == o->oBhvParams2ndByte) { play_sound(SOUND_GENERAL2_RIGHT_ANSWER, gGlobalSoundSource); o->parentObj->oTreasureChestUnkF4++; o->oAction = 1; @@ -106,7 +106,7 @@ void bhv_treasure_chest_bottom_loop(void) { void spawn_treasure_chest(s8 sp3B, s32 x, s32 y, s32 z, s16 yaw) { struct Object *sp34 = spawn_object_abs_with_rot(o, 0, MODEL_TREASURE_CHEST_BASE, bhvTreasureChestBottom, x, y, z, 0, yaw, 0); - sp34->oBehParams2ndByte = sp3B; + sp34->oBhvParams2ndByte = sp3B; } void bhv_treasure_chest_ship_init(void) { @@ -176,7 +176,7 @@ void bhv_treasure_chest_jrb_loop(void) { } } -void bhv_treasure_chest_init(void) { +void bhv_treasure_chest_ddd_init(void) { spawn_treasure_chest(1, -4500, -5119, 1300, -0x6001); spawn_treasure_chest(2, -1800, -5119, 1050, 0x1FFF); spawn_treasure_chest(3, -4500, -5119, -1100, 9102); @@ -186,7 +186,7 @@ void bhv_treasure_chest_init(void) { o->oTreasureChestUnkFC = 0; } -void bhv_treasure_chest_loop(void) { +void bhv_treasure_chest_ddd_loop(void) { switch (o->oAction) { case 0: if (o->oTreasureChestUnkF4 == 5) { diff --git a/src/game/behaviors/triplet_butterfly.inc.c b/src/game/behaviors/triplet_butterfly.inc.c index d39a3164..025cae42 100644 --- a/src/game/behaviors/triplet_butterfly.inc.c +++ b/src/game/behaviors/triplet_butterfly.inc.c @@ -1,11 +1,5 @@ // triplet_butterfly.inc.c -struct TripletButterflyActivationData { - s32 model; - const BehaviorScript *behavior; - f32 scale; -}; - static struct ObjectHitbox sTripletButterflyExplodeHitbox = { /* interactType: */ INTERACT_MR_BLIZZARD, /* downOffset: */ 50, @@ -18,17 +12,23 @@ static struct ObjectHitbox sTripletButterflyExplodeHitbox = { /* hurtboxHeight: */ 50, }; +struct TripletButterflyActivationData { + s32 model; + const BehaviorScript *behavior; + f32 scale; +}; + static struct TripletButterflyActivationData sTripletButterflyActivationData[] = { - { MODEL_BOWLING_BALL, NULL, 0.5f }, - { MODEL_1UP, bhv1upWalking, 1.0f }, + /* TRIPLET_BUTTERFLY_TYPE_EXPLODES */ { MODEL_BOWLING_BALL, NULL, 0.5f }, + /* TRIPLET_BUTTERFLY_TYPE_SPAWN_1UP */ { MODEL_1UP, bhv1UpWalking, 1.0f }, }; static void triplet_butterfly_act_init(void) { - s32 butterflyNum = o->oBehParams2ndByte & TRIPLET_BUTTERFLY_BP_BUTTERFLY_NUM; + s32 butterflySpawnType = o->oBhvParams2ndByte & TRIPLET_BUTTERFLY_BP_SPAWN_TYPE_MASK; s32 i; - if (butterflyNum != 0 || o->oDistanceToMario < 200.0f) { - if (butterflyNum == 0) { + if (butterflySpawnType != TRIPLET_BUTTERFLY_BP_SPAWN_TYPE_SPAWNER || o->oDistanceToMario < 200.0f) { + if (butterflySpawnType == TRIPLET_BUTTERFLY_BP_SPAWN_TYPE_SPAWNER) { for (i = 1; i <= 2; i++) { spawn_object_relative(i, 0, 0, 0, o, MODEL_BUTTERFLY, bhvTripletButterfly); } @@ -37,16 +37,16 @@ static void triplet_butterfly_act_init(void) { } //! TODO: Describe this glitch - if (o->parentObj->oTripletButterflySelectedButterfly == o->oBehParams2ndByte) { + if (o->parentObj->oTripletButterflySelectedButterfly == o->oBhvParams2ndByte) { o->oTripletButterflyType = TRIPLET_BUTTERFLY_TYPE_SPAWN_1UP; - } else if (o->parentObj->oBehParams2ndByte & TRIPLET_BUTTERFLY_BP_NO_BOMBS) { + } else if (o->parentObj->oBhvParams2ndByte & TRIPLET_BUTTERFLY_BP_NO_BOMBS) { o->oTripletButterflyType = TRIPLET_BUTTERFLY_TYPE_NORMAL; } // Default butterfly type is TRIPLET_BUTTERFLY_TYPE_EXPLODES o->oAction = TRIPLET_BUTTERFLY_ACT_WANDER; - o->oTripletButterflyBaseYaw = o->oBehParams2ndByte * (0x10000 / 3); + o->oTripletButterflyBaseYaw = o->oBhvParams2ndByte * (0x10000 / 3); o->oMoveAngleYaw = (s32)(o->oTripletButterflyBaseYaw + random_linear_offset(0, 0x5555)); o->oTripletButterflySpeed = random_linear_offset(15, 15); diff --git a/src/game/behaviors/ttc_2d_rotator.inc.c b/src/game/behaviors/ttc_2d_rotator.inc.c index a403381c..a439965e 100644 --- a/src/game/behaviors/ttc_2d_rotator.inc.c +++ b/src/game/behaviors/ttc_2d_rotator.inc.c @@ -38,8 +38,8 @@ static s16 sTTC2DRotatorTimeBetweenTurns[][4] = { */ void bhv_ttc_2d_rotator_init(void) { o->oTTC2DRotatorMinTimeUntilNextTurn = - sTTC2DRotatorTimeBetweenTurns[o->oBehParams2ndByte][gTTCSpeedSetting]; - o->oTTC2DRotatorIncrement = o->oTTC2DRotatorSpeed = sTTC2DRotatorSpeeds[o->oBehParams2ndByte]; + sTTC2DRotatorTimeBetweenTurns[o->oBhvParams2ndByte][gTTCSpeedSetting]; + o->oTTC2DRotatorIncrement = o->oTTC2DRotatorSpeed = sTTC2DRotatorSpeeds[o->oBhvParams2ndByte]; } /** @@ -82,7 +82,7 @@ void bhv_ttc_2d_rotator_update(void) { } o->oAngleVelYaw = o->oFaceAngleYaw - startYaw; - if (o->oBehParams2ndByte == TTC_2D_ROTATOR_BP_HAND) { + if (o->oBhvParams2ndByte == TTC_2D_ROTATOR_BP_HAND) { load_object_collision_model(); } } diff --git a/src/game/behaviors/ttc_cog.inc.c b/src/game/behaviors/ttc_cog.inc.c index 7d15c911..d1d306d7 100644 --- a/src/game/behaviors/ttc_cog.inc.c +++ b/src/game/behaviors/ttc_cog.inc.c @@ -27,8 +27,8 @@ static s16 sTTCCogNormalSpeeds[] = { 200, 400 }; */ void bhv_ttc_cog_init(void) { o->collisionData = segmented_to_virtual( - sTTCCogCollisionModels[(o->oBehParams2ndByte & TTC_COG_BP_SHAPE_MASK) >> 1]); - o->oTTCCogDir = sTTCCogDirections[o->oBehParams2ndByte & TTC_COG_BP_DIR_MASK]; + sTTCCogCollisionModels[(o->oBhvParams2ndByte & TTC_COG_BP_SHAPE_MASK) >> 1]); + o->oTTCCogDir = sTTCCogDirections[o->oBhvParams2ndByte & TTC_COG_BP_DIR_MASK]; } /** diff --git a/src/game/behaviors/ttc_elevator.inc.c b/src/game/behaviors/ttc_elevator.inc.c index f0f4fe12..41a51b74 100644 --- a/src/game/behaviors/ttc_elevator.inc.c +++ b/src/game/behaviors/ttc_elevator.inc.c @@ -17,10 +17,10 @@ static s8 sTTCElevatorSpeeds[] = { * Init function for bhvTTCElevator. */ void bhv_ttc_elevator_init(void) { - // If behParam is nonzero, then move 100 * behParam units. Otherwise default + // If bhvParam is nonzero, then move 100 * bhvParam units. Otherwise default // to 500 f32 peakOffset = - ((o->oBehParams >> 16) & 0xFFFF) ? 100.0f * ((o->oBehParams >> 16) & 0xFFFF) : 500.0f; + ((o->oBhvParams >> 16) & 0xFFFF) ? 100.0f * ((o->oBhvParams >> 16) & 0xFFFF) : 500.0f; o->oTTCElevatorPeakY = o->oPosY + peakOffset; } diff --git a/src/game/behaviors/ttc_moving_bar.inc.c b/src/game/behaviors/ttc_moving_bar.inc.c index fb6efe05..be972324 100644 --- a/src/game/behaviors/ttc_moving_bar.inc.c +++ b/src/game/behaviors/ttc_moving_bar.inc.c @@ -30,7 +30,7 @@ void bhv_ttc_moving_bar_init(void) { // This causes the first cycle to start at different times for different // bars - o->oTTCMovingBarStoppedTimer = 10 * o->oBehParams2ndByte; + o->oTTCMovingBarStoppedTimer = 10 * o->oBhvParams2ndByte; o->oMoveAngleYaw = 0x4000 - o->oMoveAngleYaw; } diff --git a/src/game/behaviors/ttc_pit_block.inc.c b/src/game/behaviors/ttc_pit_block.inc.c index ccc45f58..6424f1bd 100644 --- a/src/game/behaviors/ttc_pit_block.inc.c +++ b/src/game/behaviors/ttc_pit_block.inc.c @@ -37,7 +37,7 @@ static struct TTCPitBlockProperties sTTCPitBlockProperties[][2] = { * Init function for bhvTTCPitBlock. */ void bhv_ttc_pit_block_init(void) { - o->collisionData = segmented_to_virtual(sTTCPitBlockCollisionModels[o->oBehParams2ndByte]); + o->collisionData = segmented_to_virtual(sTTCPitBlockCollisionModels[o->oBhvParams2ndByte]); o->oTTCPitBlockPeakY = o->oPosY + 330.0f; diff --git a/src/game/behaviors/ttc_rotating_solid.inc.c b/src/game/behaviors/ttc_rotating_solid.inc.c index 6a7a5a5b..a12ddefd 100644 --- a/src/game/behaviors/ttc_rotating_solid.inc.c +++ b/src/game/behaviors/ttc_rotating_solid.inc.c @@ -26,9 +26,9 @@ static u8 sTTCRotatingSolidInitialDelays[] = { * Init function for bhvTTCRotatingSolid. */ void bhv_ttc_rotating_solid_init(void) { - o->collisionData = segmented_to_virtual(sTTCRotatingSolidCollisionModels[o->oBehParams2ndByte]); + o->collisionData = segmented_to_virtual(sTTCRotatingSolidCollisionModels[o->oBhvParams2ndByte]); - o->oTTCRotatingSolidNumSides = o->oBehParams2ndByte == TTC_ROTATING_SOLID_BP_CUBE ? 4 : 3; + o->oTTCRotatingSolidNumSides = o->oBhvParams2ndByte == TTC_ROTATING_SOLID_BP_CUBE ? 4 : 3; o->oTTCRotatingSolidRotationDelay = sTTCRotatingSolidInitialDelays[gTTCSpeedSetting]; } diff --git a/src/game/behaviors/ttc_treadmill.inc.c b/src/game/behaviors/ttc_treadmill.inc.c index 4a6c210b..f2025e50 100644 --- a/src/game/behaviors/ttc_treadmill.inc.c +++ b/src/game/behaviors/ttc_treadmill.inc.c @@ -25,7 +25,8 @@ extern s16 ttc_movtex_tris_big_surface_treadmill[]; extern s16 ttc_movtex_tris_small_surface_treadmill[]; void bhv_ttc_treadmill_init(void) { - o->collisionData = segmented_to_virtual(sTTCTreadmillCollisionModels[o->oBehParams2ndByte & 0x01]); + o->collisionData = segmented_to_virtual( + sTTCTreadmillCollisionModels[o->oBhvParams2ndByte & TTC_TREADMILL_BP_FLAG_MASK]); o->oTTCTreadmillBigSurface = segmented_to_virtual(ttc_movtex_tris_big_surface_treadmill); o->oTTCTreadmillSmallSurface = segmented_to_virtual(ttc_movtex_tris_small_surface_treadmill); diff --git a/src/game/behaviors/tumbling_bridge.inc.c b/src/game/behaviors/tumbling_bridge.inc.c index 8caf618c..7f08ce36 100644 --- a/src/game/behaviors/tumbling_bridge.inc.c +++ b/src/game/behaviors/tumbling_bridge.inc.c @@ -5,7 +5,7 @@ #include "levels/lll/header.h" #include "levels/bitfs/header.h" -struct Struct8032F34C { +struct TumblingBridgeData { s16 numBridgeSections; s16 bridgeRelativeStartingXorZ; s16 platformWidth; @@ -13,11 +13,11 @@ struct Struct8032F34C { const Collision *collision; }; -struct Struct8032F34C sTumblingBridgeParams[] = { - { 9, -512, 0x80, MODEL_WF_TUMBLING_BRIDGE_PART, wf_seg7_collision_tumbling_bridge }, - { 9, -412, 103, MODEL_BBH_TUMBLING_PLATFORM_PART, bbh_seg7_collision_07026B1C }, - { 9, -512, 0x80, MODEL_LLL_FALLING_PLATFORM, lll_seg7_collision_0701D21C }, - { 9, -512, 0x80, MODEL_BITFS_TUMBLING_PLATFORM_PART, bitfs_seg7_collision_07015288 }, +struct TumblingBridgeData sTumblingBridgeData[] = { + /* TUMBLING_BRIDGE_BP_WF */ { 9, -512, 128, MODEL_WF_TUMBLING_BRIDGE_PART, wf_seg7_collision_tumbling_bridge }, + /* TUMBLING_BRIDGE_BP_BBH */ { 9, -412, 103, MODEL_BBH_TUMBLING_PLATFORM_PART, bbh_seg7_collision_07026B1C }, + /* TUMBLING_BRIDGE_BP_LLL */ { 9, -512, 128, MODEL_LLL_FALLING_PLATFORM, lll_seg7_collision_0701D21C }, + /* TUMBLING_BRIDGE_BP_BITFS */ { 9, -512, 128, MODEL_BITFS_TUMBLING_PLATFORM_PART, bitfs_seg7_collision_07015288 }, }; void bhv_tumbling_bridge_platform_loop(void) { @@ -64,25 +64,25 @@ void bhv_tumbling_bridge_platform_loop(void) { void tumbling_bridge_act_1(void) { struct Object *platformObj; s32 i; - s32 bridgeID = o->oBehParams2ndByte; + s32 bridgeID = o->oBhvParams2ndByte; s32 relativePlatformX; s32 relativePlatformZ; s32 relativePlatformY = 0; s32 relativeInitialPlatformY = 0; - for (i = 0; i < sTumblingBridgeParams[bridgeID].numBridgeSections; i++) { + for (i = 0; i < sTumblingBridgeData[bridgeID].numBridgeSections; i++) { relativePlatformX = 0; relativePlatformZ = 0; - if (bridgeID == 3) { - relativePlatformX = sTumblingBridgeParams[bridgeID].bridgeRelativeStartingXorZ - + sTumblingBridgeParams[bridgeID].platformWidth * i; + if (bridgeID == TUMBLING_BRIDGE_BP_BITFS) { + relativePlatformX = sTumblingBridgeData[bridgeID].bridgeRelativeStartingXorZ + + sTumblingBridgeData[bridgeID].platformWidth * i; } else { - relativePlatformZ = sTumblingBridgeParams[bridgeID].bridgeRelativeStartingXorZ - + sTumblingBridgeParams[bridgeID].platformWidth * i; + relativePlatformZ = sTumblingBridgeData[bridgeID].bridgeRelativeStartingXorZ + + sTumblingBridgeData[bridgeID].platformWidth * i; } - if (cur_obj_has_behavior(bhvLllTumblingBridge)) { + if (cur_obj_has_behavior(bhvLLLTumblingBridge)) { if (i % 3 == 0) { relativePlatformY -= 150; } @@ -91,9 +91,9 @@ void tumbling_bridge_act_1(void) { platformObj = spawn_object_relative( 0, relativePlatformX, relativePlatformY + relativeInitialPlatformY, relativePlatformZ, o, - sTumblingBridgeParams[bridgeID].model, bhvTumblingBridgePlatform); + sTumblingBridgeData[bridgeID].model, bhvTumblingBridgePlatform); - obj_set_collision_data(platformObj, sTumblingBridgeParams[bridgeID].collision); + obj_set_collision_data(platformObj, sTumblingBridgeData[bridgeID].collision); } o->oAction = 2; @@ -101,7 +101,7 @@ void tumbling_bridge_act_1(void) { void tumbling_bridge_act_2(void) { cur_obj_hide(); - if (cur_obj_has_behavior(bhvLllTumblingBridge)) { + if (cur_obj_has_behavior(bhvLLLTumblingBridge)) { cur_obj_unhide(); } else if (o->oDistanceToMario > 1200.0f) { o->oAction = 3; @@ -115,7 +115,7 @@ void tumbling_bridge_act_3(void) { } void tumbling_bridge_act_0(void) { - if (cur_obj_has_behavior(bhvLllTumblingBridge) || o->oDistanceToMario < 1000.0f) { + if (cur_obj_has_behavior(bhvLLLTumblingBridge) || o->oDistanceToMario < 1000.0f) { o->oAction = 1; } } diff --git a/src/game/behaviors/tuxie.inc.c b/src/game/behaviors/tuxie.inc.c index c3c98f98..058b45f3 100644 --- a/src/game/behaviors/tuxie.inc.c +++ b/src/game/behaviors/tuxie.inc.c @@ -50,8 +50,8 @@ void tuxies_mother_act_1(void) { case 0: cur_obj_init_animation_with_sound(3); if (!cur_obj_is_mario_on_platform()) { - s32 sp2C = (o->oBehParams >> 16) & 0xFF; - s32 sp28 = (o->prevObj->oBehParams >> 16) & 0xFF; + s32 sp2C = (o->oBhvParams >> 16) & 0xFF; + s32 sp28 = (o->prevObj->oBhvParams >> 16) & 0xFF; s32 dialogID; if (sp2C == sp28) { @@ -59,7 +59,7 @@ void tuxies_mother_act_1(void) { } else { dialogID = DIALOG_059; } - if (cur_obj_update_dialog_with_cutscene(MARIO_DIALOG_LOOK_UP, + if (cur_obj_update_dialog_with_cutscene(MARIO_DIALOG_LOOK_UP, DIALOG_FLAG_TURN_TO_MARIO, CUTSCENE_DIALOG, dialogID)) { if (dialogID == DIALOG_058) { o->oSubAction = 1; @@ -129,7 +129,7 @@ void tuxies_mother_act_0(void) { } break; case 1: - if (cur_obj_update_dialog_with_cutscene(MARIO_DIALOG_LOOK_UP, + if (cur_obj_update_dialog_with_cutscene(MARIO_DIALOG_LOOK_UP, DIALOG_FLAG_TURN_TO_MARIO, CUTSCENE_DIALOG, DIALOG_057)) { o->oSubAction++; } @@ -357,5 +357,6 @@ Gfx *geo_switch_tuxie_mother_eyes(s32 run, struct GraphNode *node, UNUSED Mat4 * } } } + return NULL; } diff --git a/src/game/behaviors/tweester.inc.c b/src/game/behaviors/tweester.inc.c index 8bd28c63..4fcca71c 100644 --- a/src/game/behaviors/tweester.inc.c +++ b/src/game/behaviors/tweester.inc.c @@ -72,7 +72,7 @@ void tweester_act_idle(void) { * After Mario is twirling, then return home. */ void tweester_act_chase(void) { - f32 activationRadius = o->oBehParams2ndByte * 100; + f32 activationRadius = o->oBhvParams2ndByte * 100; o->oAngleToHome = cur_obj_angle_to_home(); cur_obj_play_sound_1(SOUND_ENV_WIND1); @@ -138,7 +138,7 @@ void (*sTweesterActions[])(void) = { }; /** - * Loop behavior for Tweester. + * Loop behavior for Tweester. * Loads the hitbox and calls its relevant action. */ void bhv_tweester_loop(void) { diff --git a/src/game/behaviors/ukiki.inc.c b/src/game/behaviors/ukiki.inc.c index ffc3e2d5..831b4a16 100644 --- a/src/game/behaviors/ukiki.inc.c +++ b/src/game/behaviors/ukiki.inc.c @@ -11,7 +11,7 @@ * or makes him wait to respawn if in water. */ void handle_cap_ukiki_reset(void) { - if (o->oBehParams2ndByte == UKIKI_CAP) { + if (o->oBhvParams2ndByte == UKIKI_BP_CAP) { if (cur_obj_mario_far_away()) { cur_obj_set_pos_to_home_and_stop(); o->oAction = UKIKI_ACT_IDLE; @@ -26,7 +26,7 @@ void handle_cap_ukiki_reset(void) { * the cap ukiki. */ s32 is_cap_ukiki_and_mario_has_normal_cap_on_head(void) { - if (o->oBehParams2ndByte == UKIKI_CAP + if (o->oBhvParams2ndByte == UKIKI_BP_CAP && does_mario_have_normal_cap_on_head(gMarioState)) { return TRUE; } @@ -38,11 +38,9 @@ s32 is_cap_ukiki_and_mario_has_normal_cap_on_head(void) { * Unused copy of geo_update_projectile_pos_from_parent. Perhaps a copy paste mistake. */ Gfx *geo_update_projectile_pos_from_parent_copy(s32 run,UNUSED struct GraphNode *node, Mat4 mtx) { - Mat4 mtx2; - if (run == TRUE) { - // TODO: change global type to Object pointer - struct Object *obj = (struct Object *) gCurGraphNodeObject; + Mat4 mtx2; + struct Object *obj = (struct Object *) gCurGraphNodeObject; // TODO: change global type to Object pointer if (obj->prevObj != NULL) { create_transformation_from_matrices(mtx2, mtx, *gCurGraphNodeCamera->matrixPtr); @@ -159,7 +157,7 @@ void ukiki_act_idle(void) { o->oUkikiTextState = UKIKI_TEXT_HAS_CAP; } - if (o->oBehParams2ndByte == UKIKI_CAP) { + if (o->oBhvParams2ndByte == UKIKI_BP_CAP) { if (o->oPosY < -1550.0f) { o->oAction = UKIKI_ACT_RETURN_HOME; } @@ -377,7 +375,7 @@ void ukiki_act_go_to_cage(void) { case UKIKI_SUB_ACT_CAGE_TALK_TO_MARIO: cur_obj_init_animation_with_sound(UKIKI_ANIM_HANDSTAND); - if (cur_obj_update_dialog_with_cutscene(MARIO_DIALOG_LOOK_DOWN, + if (cur_obj_update_dialog_with_cutscene(MARIO_DIALOG_LOOK_DOWN, DIALOG_FLAG_TURN_TO_MARIO, CUTSCENE_DIALOG, DIALOG_080)) { o->oSubAction++; } @@ -573,7 +571,7 @@ void cap_ukiki_held_loop(void) { break; case UKIKI_TEXT_HAS_CAP: - if (cur_obj_update_dialog(MARIO_DIALOG_LOOK_UP, + if (cur_obj_update_dialog(MARIO_DIALOG_LOOK_UP, (DIALOG_FLAG_TEXT_DEFAULT | DIALOG_FLAG_TIME_STOP_ENABLED), DIALOG_101, 0)) { mario_retrieve_cap(); set_mario_npc_dialog(MARIO_DIALOG_STOP); @@ -593,7 +591,7 @@ void cap_ukiki_held_loop(void) { * Initializatation for ukiki, determines if it has Mario's cap. */ void bhv_ukiki_init(void) { - if ((o->oBehParams2ndByte == UKIKI_CAP) + if ((o->oBhvParams2ndByte == UKIKI_BP_CAP) && (save_file_get_flags() & SAVE_FLAG_CAP_ON_UKIKI)) { o->oUkikiTextState = UKIKI_TEXT_HAS_CAP; o->oUkikiHasCap |= UKIKI_CAP_ON; @@ -616,7 +614,7 @@ void bhv_ukiki_loop(void) { cur_obj_unrender_set_action_and_anim(UKIKI_ANIM_HELD, 0); obj_copy_pos(o, gMarioObject); - if (o->oBehParams2ndByte == UKIKI_CAP) { + if (o->oBhvParams2ndByte == UKIKI_BP_CAP) { cap_ukiki_held_loop(); } else { cage_ukiki_held_loop(); diff --git a/src/game/behaviors/unagi.inc.c b/src/game/behaviors/unagi.inc.c index 33f37609..51235502 100644 --- a/src/game/behaviors/unagi.inc.c +++ b/src/game/behaviors/unagi.inc.c @@ -13,9 +13,9 @@ struct ObjectHitbox sUnagiHitbox = { }; void bhv_unagi_init(void) { - if (o->oBehParams2ndByte != 1) { + if (o->oBhvParams2ndByte != 1) { o->oPathedStartWaypoint = segmented_to_virtual(jrb_seg7_trajectory_unagi_1); - if (o->oBehParams2ndByte == 0) { + if (o->oBhvParams2ndByte == 0) { o->oFaceAnglePitch = -7600; } else { o->oAction = 1; @@ -174,7 +174,7 @@ void bhv_unagi_subobject_loop(void) { if (o->parentObj->oUnagiUnk1B2 == 0) { obj_mark_for_deletion(o); } else { - f32 val04 = 300.0f * o->oBehParams2ndByte; + f32 val04 = 300.0f * o->oBhvParams2ndByte; o->oPosY = o->parentObj->oPosY - val04 * sins(o->parentObj->oFaceAnglePitch) * 1.13f; @@ -183,15 +183,15 @@ void bhv_unagi_subobject_loop(void) { o->oPosX = o->parentObj->oPosX + val04 * sins(o->parentObj->oFaceAngleYaw); o->oPosZ = o->parentObj->oPosZ + val04 * coss(o->parentObj->oFaceAngleYaw); - if (o->oBehParams2ndByte == -4) { + if (o->oBhvParams2ndByte == -4) { if (o->parentObj->oAnimState != 0 && o->oDistanceToMario < 150.0f) { - o->oBehParams = o->parentObj->oBehParams; + o->oBhvParams = o->parentObj->oBhvParams; spawn_default_star(6833.0f, -3654.0f, 2230.0f); o->parentObj->oAnimState = 0; } } else { obj_check_attacks(&sUnagiHitbox, o->oAction); - if (o->oBehParams2ndByte == 3) { + if (o->oBhvParams2ndByte == 3) { o->parentObj->oUnagiUnk1AC = o->oDistanceToMario; } } diff --git a/src/game/behaviors/warp.inc.c b/src/game/behaviors/warp.inc.c index 0e910186..f0b08ee1 100644 --- a/src/game/behaviors/warp.inc.c +++ b/src/game/behaviors/warp.inc.c @@ -2,14 +2,14 @@ void bhv_warp_loop(void) { if (o->oTimer == 0) { - u16 sp6 = (o->oBehParams >> 24) & 0xFF; + u16 bhvParams1stByte = (o->oBhvParams >> 24) & 0xFF; - if (sp6 == 0) { + if (bhvParams1stByte == 0x00) { o->hitboxRadius = 50.0f; - } else if (sp6 == 0xFF) { + } else if (bhvParams1stByte == 0xFF) { o->hitboxRadius = 10000.0f; } else { - o->hitboxRadius = sp6 * 10.0; + o->hitboxRadius = bhvParams1stByte * 10.0; } o->hitboxHeight = 50.0f; } @@ -20,14 +20,14 @@ void bhv_warp_loop(void) { // identical to the above function except for o->hitboxRadius void bhv_fading_warp_loop() { if (o->oTimer == 0) { - u16 sp6 = (o->oBehParams >> 24) & 0xFF; + u16 bhvParams1stByte = (o->oBhvParams >> 24) & 0xFF; - if (sp6 == 0) { + if (bhvParams1stByte == 0x00) { o->hitboxRadius = 85.0f; - } else if (sp6 == 0xFF) { + } else if (bhvParams1stByte == 0xFF) { o->hitboxRadius = 10000.0f; } else { - o->hitboxRadius = sp6 * 10.0; + o->hitboxRadius = bhvParams1stByte * 10.0; } o->hitboxHeight = 50.0f; } diff --git a/src/game/behaviors/water_bomb.inc.c b/src/game/behaviors/water_bomb.inc.c index 889ca462..68362c1b 100644 --- a/src/game/behaviors/water_bomb.inc.c +++ b/src/game/behaviors/water_bomb.inc.c @@ -30,7 +30,7 @@ static struct ObjectHitbox sWaterBombHitbox = { */ void bhv_water_bomb_spawner_update(void) { f32 latDistToMario; - f32 spawnerRadius = 50 * (u16)(o->oBehParams >> 16) + 200.0f; + f32 spawnerRadius = 50 * (u16)(o->oBhvParams >> 16) + 200.0f; latDistToMario = lateral_dist_between_objects(o, gMarioObject); @@ -68,7 +68,7 @@ void bhv_water_bomb_spawner_update(void) { */ void water_bomb_spawn_explode_particles(s8 offsetY, s8 forwardVelRange, s8 velYBase) { static struct SpawnParticlesInfo waterBombExplodeParticles = { - /* behParam: */ 0, + /* bhvParam: */ 0, /* count: */ 5, /* model: */ MODEL_BUBBLE, /* offsetY: */ 20, @@ -176,7 +176,7 @@ static void water_bomb_act_explode(void) { */ static void water_bomb_act_shot_from_cannon(void) { static struct SpawnParticlesInfo waterBombCannonParticle = { - /* behParam: */ 0, + /* bhvParam: */ 0, /* count: */ 1, /* model: */ MODEL_BUBBLE, /* offsetY: */ 236, diff --git a/src/game/behaviors/water_bomb_cannon.inc.c b/src/game/behaviors/water_bomb_cannon.inc.c index a2134821..525ba57e 100644 --- a/src/game/behaviors/water_bomb_cannon.inc.c +++ b/src/game/behaviors/water_bomb_cannon.inc.c @@ -50,7 +50,7 @@ void water_bomb_cannon_act_0(void) { void water_bomb_cannon_act_1(void) { if (o->oDistanceToMario > 2500.0f) { o->oAction = 2; - } else if (o->oBehParams2ndByte == 0) { + } else if (o->oBhvParams2ndByte == 0) { if (o->oWaterCannonUnkF4 != 0) { o->oWaterCannonUnkF4--; } else { diff --git a/src/game/behaviors/white_puff_explode.inc.c b/src/game/behaviors/white_puff_explode.inc.c index 8b153da5..a823fd22 100644 --- a/src/game/behaviors/white_puff_explode.inc.c +++ b/src/game/behaviors/white_puff_explode.inc.c @@ -4,7 +4,7 @@ void bhv_white_puff_exploding_loop(void) { if (o->oTimer == 0) { cur_obj_compute_vel_xz(); o->oWhitePuffUnkF4 = o->header.gfx.scale[0]; - switch (o->oBehParams2ndByte) { + switch (o->oBhvParams2ndByte) { case 2: o->oOpacity = 254; o->oWhitePuffUnkF8 = -21; diff --git a/src/game/behaviors/whomp.inc.c b/src/game/behaviors/whomp.inc.c index fe39da7c..2aefe255 100644 --- a/src/game/behaviors/whomp.inc.c +++ b/src/game/behaviors/whomp.inc.c @@ -21,7 +21,7 @@ void whomp_init(void) { cur_obj_init_animation_with_accel_and_sound(0, 1.0f); cur_obj_set_pos_to_home(); - if (o->oBehParams2ndByte != 0) { + if (o->oBhvParams2ndByte != WHOMP_BP_SMALL) { gSecondCameraFocus = o; cur_obj_scale(2.0f); if (o->oSubAction == 0) { @@ -32,7 +32,7 @@ void whomp_init(void) { cur_obj_set_pos_to_home(); o->oHealth = 3; } - } else if (cur_obj_update_dialog_with_cutscene(MARIO_DIALOG_LOOK_UP, + } else if (cur_obj_update_dialog_with_cutscene(MARIO_DIALOG_LOOK_UP, DIALOG_FLAG_TURN_TO_MARIO, CUTSCENE_DIALOG, DIALOG_114)) { o->oAction = 2; } @@ -213,7 +213,7 @@ void whomp_on_ground_general(void) { o->oAngleVelYaw = 0; o->oAngleVelRoll = 0; - if (o->oBehParams2ndByte != 0) { + if (o->oBhvParams2ndByte != WHOMP_BP_SMALL) { king_whomp_on_ground(); } else { whomp_on_ground(); @@ -227,7 +227,7 @@ void whomp_on_ground_general(void) { } else { o->oAngleVelPitch = 0; o->oFaceAnglePitch = 0; - if (o->oBehParams2ndByte != 0) { + if (o->oBhvParams2ndByte != WHOMP_BP_SMALL) { o->oAction = 2; } else { o->oAction = 1; @@ -236,8 +236,8 @@ void whomp_on_ground_general(void) { } void whomp_die(void) { - if (o->oBehParams2ndByte != 0) { - if (cur_obj_update_dialog_with_cutscene(MARIO_DIALOG_LOOK_UP, + if (o->oBhvParams2ndByte != WHOMP_BP_SMALL) { + if (cur_obj_update_dialog_with_cutscene(MARIO_DIALOG_LOOK_UP, DIALOG_FLAG_TEXT_DEFAULT, CUTSCENE_DIALOG, DIALOG_115)) { obj_set_angle(o, 0, 0, 0); cur_obj_hide(); @@ -282,7 +282,7 @@ void bhv_whomp_loop(void) { cur_obj_call_action_function(sWhompActions); cur_obj_move_standard(-20); if (o->oAction != 9) { - if (o->oBehParams2ndByte != 0) { + if (o->oBhvParams2ndByte != WHOMP_BP_SMALL) { cur_obj_hide_if_mario_far_away_y(2000.0f); } else { cur_obj_hide_if_mario_far_away_y(1000.0f); diff --git a/src/game/behaviors/wiggler.inc.c b/src/game/behaviors/wiggler.inc.c index 5ba10254..ee9a973e 100644 --- a/src/game/behaviors/wiggler.inc.c +++ b/src/game/behaviors/wiggler.inc.c @@ -66,7 +66,7 @@ void bhv_wiggler_body_part_update(void) { f32 dy; f32 dz; f32 dxz; - struct ChainSegment *segment = &o->parentObj->oWigglerSegments[o->oBehParams2ndByte]; + struct ChainSegment *segment = &o->parentObj->oWigglerSegments[o->oBhvParams2ndByte]; f32 posOffset; cur_obj_scale(o->parentObj->header.gfx.scale[0]); @@ -91,7 +91,7 @@ void bhv_wiggler_body_part_update(void) { // the floor o->oPosY += -30.0f; cur_obj_update_floor_height(); - if (o->oFloorHeight > o->oPosY) { // TODO: Check ineq swap + if (o->oFloorHeight > o->oPosY) { o->oPosY = o->oFloorHeight; } } @@ -300,7 +300,7 @@ static void wiggler_act_jumped_on(void) { // defeated) or go back to walking if (o->header.gfx.scale[1] >= 4.0f) { if (o->oTimer > 30) { - if (cur_obj_update_dialog_with_cutscene(MARIO_DIALOG_LOOK_UP, + if (cur_obj_update_dialog_with_cutscene(MARIO_DIALOG_LOOK_UP, DIALOG_FLAG_NONE, CUTSCENE_DIALOG, attackText[o->oHealth - 2])) { // Because we don't want the wiggler to disappear after being // defeated, we leave its health at 1 diff --git a/src/game/camera.c b/src/game/camera.c index 216fe0e3..0925e961 100644 --- a/src/game/camera.c +++ b/src/game/camera.c @@ -271,7 +271,7 @@ s16 sCutsceneShot; */ s16 gCutsceneTimer; s16 unused8033B3E8; -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) s16 unused8033B3E82; #endif /** @@ -3571,7 +3571,7 @@ void unused_object_angle_to_vec3s(Vec3s dst, struct Object *o) { * u is a value between 0 and 1 that represents the position along the spline, * and a0-a3 are parameters that define the spline. * - * The spline is described at www2.cs.uregina.ca/~anima/408/Notes/Interpolation/UniformBSpline.htm + * The spline is described at http://www2.cs.uregina.ca/~anima/UniformBSpline.htm */ void evaluate_cubic_spline(f32 u, Vec3f Q, Vec3f a0, Vec3f a1, Vec3f a2, Vec3f a3) { f32 B[4]; @@ -5607,7 +5607,7 @@ void set_fixed_cam_axis_sa_lobby(UNUSED s16 preset) { * Generally, block area mode changes if: * Mario is wearing the metal cap, or at the water's surface, or the camera is in Mario mode * - * However, if the level is WDW, DDD, or COTMC (levels that have metal cap and water): + * However, if the level is WDW, DDD, or CotMC (levels that have metal cap and water): * Only block area mode changes if Mario is in a cannon, * or if the camera is in Mario mode and Mario is not swimming or in water with the metal cap */ @@ -6884,7 +6884,7 @@ s16 unused_dialog_cutscene_response(u8 cutscene) { } // if playing this cutscene and Mario responded, return the response - if ((gCamera->cutscene == cutscene) && (sCutsceneDialogResponse)) { + if ((gCamera->cutscene == cutscene) && (sCutsceneDialogResponse != DIALOG_RESPONSE_NONE)) { return sCutsceneDialogResponse; } else { return 0; @@ -7024,7 +7024,7 @@ static UNUSED void unused_cutscene_mario_dialog_looking_up(UNUSED struct Camera * Lower the volume (US only) and start the peach letter background music */ BAD_RETURN(s32) cutscene_intro_peach_start_letter_music(UNUSED struct Camera *c) { -#if defined(VERSION_US) || defined(VERSION_SH) +#if defined(VERSION_US) || defined(VERSION_SH) || defined(VERSION_CN) seq_player_lower_volume(SEQ_PLAYER_LEVEL, 60, 40); #endif cutscene_intro_peach_play_message_music(); @@ -8313,7 +8313,7 @@ BAD_RETURN(s32) cutscene_exit_fall_to_castle_grounds_warp(struct Camera *c) { } /** - * Cutscene that plays when Mario falls from WMOTR. + * Cutscene that plays when Mario falls from WMotR. */ BAD_RETURN(s32) cutscene_exit_fall_to_castle_grounds(struct Camera *c) { cutscene_event(cutscene_exit_fall_to_castle_grounds_warp, c, 0, 0); @@ -9380,7 +9380,7 @@ BAD_RETURN(s32) cutscene_cap_switch_press_pan_left(struct Camera *c) { * Create a dialog box with the cap switch's text. */ BAD_RETURN(s32) cutscene_cap_switch_press_create_dialog(UNUSED struct Camera *c) { - create_dialog_box_with_response(gCutsceneFocus->oBehParams2ndByte + DIALOG_010); + create_dialog_box_with_response(gCutsceneFocus->oBhvParams2ndByte + DIALOG_010); } static UNUSED BAD_RETURN(s32) unused_cap_switch_retrieve_info(struct Camera *c) { @@ -9413,7 +9413,7 @@ BAD_RETURN(s32) cutscene_cap_switch_press(struct Camera *c) { if ((get_dialog_id() == DIALOG_NONE) && (sCutsceneVars[4].angle[0] != 0)) { sCutsceneDialogResponse = sCutsceneVars[4].angle[0]; if (sCutsceneVars[4].angle[0] == 1) { - cap_switch_save(gCutsceneFocus->oBehParams2ndByte); + cap_switch_save(gCutsceneFocus->oBhvParams2ndByte); } stop_cutscene_and_retrieve_stored_info(c); transition_next_state(c, 30); @@ -9602,7 +9602,7 @@ BAD_RETURN(s32) play_sound_intro_turn_on_hud(UNUSED struct Camera *c) { * Fly to the pipe. Near the end, the camera jumps to Lakitu's position and the hud turns on. */ BAD_RETURN(s32) cutscene_intro_peach_fly_to_pipe(struct Camera *c) { -#if defined(VERSION_US) || defined(VERSION_SH) +#if defined(VERSION_US) || defined(VERSION_SH) || defined(VERSION_CN) cutscene_event(play_sound_intro_turn_on_hud, c, 818, 818); #elif defined(VERSION_EU) cutscene_event(play_sound_intro_turn_on_hud, c, 673, 673); @@ -9737,46 +9737,46 @@ BAD_RETURN(s32) cutscene_credits_reset_spline(UNUSED struct Camera *c) { cutscene_reset_spline(); } -extern struct CutsceneSplinePoint sBobCreditsSplinePositions[]; -extern struct CutsceneSplinePoint sBobCreditsSplineFocus[]; -extern struct CutsceneSplinePoint sWfCreditsSplinePositions[]; -extern struct CutsceneSplinePoint sWfCreditsSplineFocus[]; -extern struct CutsceneSplinePoint sJrbCreditsSplinePositions[]; -extern struct CutsceneSplinePoint sJrbCreditsSplineFocus[]; -extern struct CutsceneSplinePoint sCcmSlideCreditsSplinePositions[]; -extern struct CutsceneSplinePoint sCcmSlideCreditsSplineFocus[]; -extern struct CutsceneSplinePoint sBbhCreditsSplinePositions[]; -extern struct CutsceneSplinePoint sBbhCreditsSplineFocus[]; -extern struct CutsceneSplinePoint sHmcCreditsSplinePositions[]; -extern struct CutsceneSplinePoint sHmcCreditsSplineFocus[]; -extern struct CutsceneSplinePoint sThiWigglerCreditsSplinePositions[]; -extern struct CutsceneSplinePoint sThiWigglerCreditsSplineFocus[]; +extern struct CutsceneSplinePoint sBoBCreditsSplinePositions[]; +extern struct CutsceneSplinePoint sBoBCreditsSplineFocus[]; +extern struct CutsceneSplinePoint sWFCreditsSplinePositions[]; +extern struct CutsceneSplinePoint sWFCreditsSplineFocus[]; +extern struct CutsceneSplinePoint sJRBCreditsSplinePositions[]; +extern struct CutsceneSplinePoint sJRBCreditsSplineFocus[]; +extern struct CutsceneSplinePoint sCCMSlideCreditsSplinePositions[]; +extern struct CutsceneSplinePoint sCCMSlideCreditsSplineFocus[]; +extern struct CutsceneSplinePoint sBBHCreditsSplinePositions[]; +extern struct CutsceneSplinePoint sBBHCreditsSplineFocus[]; +extern struct CutsceneSplinePoint sHMCCreditsSplinePositions[]; +extern struct CutsceneSplinePoint sHMCCreditsSplineFocus[]; +extern struct CutsceneSplinePoint sTHIWigglerCreditsSplinePositions[]; +extern struct CutsceneSplinePoint sTHIWigglerCreditsSplineFocus[]; extern struct CutsceneSplinePoint sVolcanoCreditsSplinePositions[]; extern struct CutsceneSplinePoint sVolcanoCreditsSplineFocus[]; -extern struct CutsceneSplinePoint sSslCreditsSplinePositions[]; -extern struct CutsceneSplinePoint sSslCreditsSplineFocus[]; -extern struct CutsceneSplinePoint sDddCreditsSplinePositions[]; -extern struct CutsceneSplinePoint sDddCreditsSplineFocus[]; -extern struct CutsceneSplinePoint sSlCreditsSplinePositions[]; -extern struct CutsceneSplinePoint sSlCreditsSplineFocus[]; -extern struct CutsceneSplinePoint sWdwCreditsSplinePositions[]; -extern struct CutsceneSplinePoint sWdwCreditsSplineFocus[]; -extern struct CutsceneSplinePoint sTtmCreditsSplinePositions[]; -extern struct CutsceneSplinePoint sTtmCreditsSplineFocus[]; -extern struct CutsceneSplinePoint sThiHugeCreditsSplinePositions[]; -extern struct CutsceneSplinePoint sThiHugeCreditsSplineFocus[]; -extern struct CutsceneSplinePoint sTtcCreditsSplinePositions[]; -extern struct CutsceneSplinePoint sTtcCreditsSplineFocus[]; -extern struct CutsceneSplinePoint sRrCreditsSplinePositions[]; -extern struct CutsceneSplinePoint sRrCreditsSplineFocus[]; -extern struct CutsceneSplinePoint sSaCreditsSplinePositions[]; -extern struct CutsceneSplinePoint sSaCreditsSplineFocus[]; -extern struct CutsceneSplinePoint sCotmcCreditsSplinePositions[]; -extern struct CutsceneSplinePoint sCotmcCreditsSplineFocus[]; -extern struct CutsceneSplinePoint sDddSubCreditsSplinePositions[]; -extern struct CutsceneSplinePoint sDddSubCreditsSplineFocus[]; -extern struct CutsceneSplinePoint sCcmOutsideCreditsSplinePositions[]; -extern struct CutsceneSplinePoint sCcmOutsideCreditsSplineFocus[]; +extern struct CutsceneSplinePoint sSSLCreditsSplinePositions[]; +extern struct CutsceneSplinePoint sSSLCreditsSplineFocus[]; +extern struct CutsceneSplinePoint sDDDCreditsSplinePositions[]; +extern struct CutsceneSplinePoint sDDDCreditsSplineFocus[]; +extern struct CutsceneSplinePoint sSLCreditsSplinePositions[]; +extern struct CutsceneSplinePoint sSLCreditsSplineFocus[]; +extern struct CutsceneSplinePoint sWDWCreditsSplinePositions[]; +extern struct CutsceneSplinePoint sWDWCreditsSplineFocus[]; +extern struct CutsceneSplinePoint sTTMCreditsSplinePositions[]; +extern struct CutsceneSplinePoint sTTMCreditsSplineFocus[]; +extern struct CutsceneSplinePoint sTHIHugeCreditsSplinePositions[]; +extern struct CutsceneSplinePoint sTHIHugeCreditsSplineFocus[]; +extern struct CutsceneSplinePoint sTTCCreditsSplinePositions[]; +extern struct CutsceneSplinePoint sTTCCreditsSplineFocus[]; +extern struct CutsceneSplinePoint sRRCreditsSplinePositions[]; +extern struct CutsceneSplinePoint sRRCreditsSplineFocus[]; +extern struct CutsceneSplinePoint sSACreditsSplinePositions[]; +extern struct CutsceneSplinePoint sSACreditsSplineFocus[]; +extern struct CutsceneSplinePoint sCotMCCreditsSplinePositions[]; +extern struct CutsceneSplinePoint sCotMCCreditsSplineFocus[]; +extern struct CutsceneSplinePoint sDDDSubCreditsSplinePositions[]; +extern struct CutsceneSplinePoint sDDDSubCreditsSplineFocus[]; +extern struct CutsceneSplinePoint sCCMOutsideCreditsSplinePositions[]; +extern struct CutsceneSplinePoint sCCMOutsideCreditsSplineFocus[]; /** * Follow splines through the courses of the game. @@ -9788,96 +9788,96 @@ BAD_RETURN(s32) cutscene_credits(struct Camera *c) { switch (gCurrLevelArea) { case AREA_BOB: - pos = sBobCreditsSplinePositions; - focus = sBobCreditsSplineFocus; + pos = sBoBCreditsSplinePositions; + focus = sBoBCreditsSplineFocus; break; case AREA_WF: - pos = sWfCreditsSplinePositions; - focus = sWfCreditsSplineFocus; + pos = sWFCreditsSplinePositions; + focus = sWFCreditsSplineFocus; break; case AREA_JRB_MAIN: - pos = sJrbCreditsSplinePositions; - focus = sJrbCreditsSplineFocus; + pos = sJRBCreditsSplinePositions; + focus = sJRBCreditsSplineFocus; break; case AREA_CCM_SLIDE: - pos = sCcmSlideCreditsSplinePositions; - focus = sCcmSlideCreditsSplineFocus; + pos = sCCMSlideCreditsSplinePositions; + focus = sCCMSlideCreditsSplineFocus; break; case AREA_BBH: - pos = sBbhCreditsSplinePositions; - focus = sBbhCreditsSplineFocus; + pos = sBBHCreditsSplinePositions; + focus = sBBHCreditsSplineFocus; break; case AREA_HMC: - pos = sHmcCreditsSplinePositions; - focus = sHmcCreditsSplineFocus; + pos = sHMCCreditsSplinePositions; + focus = sHMCCreditsSplineFocus; break; case AREA_THI_WIGGLER: - pos = sThiWigglerCreditsSplinePositions; - focus = sThiWigglerCreditsSplineFocus; + pos = sTHIWigglerCreditsSplinePositions; + focus = sTHIWigglerCreditsSplineFocus; break; case AREA_LLL_VOLCANO: pos = sVolcanoCreditsSplinePositions; focus = sVolcanoCreditsSplineFocus; break; case AREA_SSL_OUTSIDE: - pos = sSslCreditsSplinePositions; - focus = sSslCreditsSplineFocus; + pos = sSSLCreditsSplinePositions; + focus = sSSLCreditsSplineFocus; break; case AREA_DDD_WHIRLPOOL: - pos = sDddCreditsSplinePositions; - focus = sDddCreditsSplineFocus; + pos = sDDDCreditsSplinePositions; + focus = sDDDCreditsSplineFocus; break; case AREA_SL_OUTSIDE: - pos = sSlCreditsSplinePositions; - focus = sSlCreditsSplineFocus; + pos = sSLCreditsSplinePositions; + focus = sSLCreditsSplineFocus; break; case AREA_WDW_MAIN: - pos = sWdwCreditsSplinePositions; - focus = sWdwCreditsSplineFocus; + pos = sWDWCreditsSplinePositions; + focus = sWDWCreditsSplineFocus; break; case AREA_TTM_OUTSIDE: - pos = sTtmCreditsSplinePositions; - focus = sTtmCreditsSplineFocus; + pos = sTTMCreditsSplinePositions; + focus = sTTMCreditsSplineFocus; break; case AREA_THI_HUGE: - pos = sThiHugeCreditsSplinePositions; - focus = sThiHugeCreditsSplineFocus; + pos = sTHIHugeCreditsSplinePositions; + focus = sTHIHugeCreditsSplineFocus; break; case AREA_TTC: - pos = sTtcCreditsSplinePositions; - focus = sTtcCreditsSplineFocus; + pos = sTTCCreditsSplinePositions; + focus = sTTCCreditsSplineFocus; break; case AREA_RR: - pos = sRrCreditsSplinePositions; - focus = sRrCreditsSplineFocus; + pos = sRRCreditsSplinePositions; + focus = sRRCreditsSplineFocus; break; case AREA_SA: - pos = sSaCreditsSplinePositions; - focus = sSaCreditsSplineFocus; + pos = sSACreditsSplinePositions; + focus = sSACreditsSplineFocus; break; case AREA_COTMC: - pos = sCotmcCreditsSplinePositions; - focus = sCotmcCreditsSplineFocus; + pos = sCotMCCreditsSplinePositions; + focus = sCotMCCreditsSplineFocus; break; case AREA_DDD_SUB: - pos = sDddSubCreditsSplinePositions; - focus = sDddSubCreditsSplineFocus; + pos = sDDDSubCreditsSplinePositions; + focus = sDDDSubCreditsSplineFocus; break; case AREA_CCM_OUTSIDE: //! Checks if the "Snowman's Lost His Head" star was collected. The credits likely would //! have avoided the snowman if the player didn't collect that star, but in the end the //! developers decided against it. if (save_file_get_star_flags(gCurrSaveFileNum - 1, COURSE_NUM_TO_INDEX(gCurrCourseNum)) & (1 << 4)) { - pos = sCcmOutsideCreditsSplinePositions; - focus = sCcmOutsideCreditsSplineFocus; + pos = sCCMOutsideCreditsSplinePositions; + focus = sCCMOutsideCreditsSplineFocus; } else { - pos = sCcmOutsideCreditsSplinePositions; - focus = sCcmOutsideCreditsSplineFocus; + pos = sCCMOutsideCreditsSplinePositions; + focus = sCCMOutsideCreditsSplineFocus; } break; default: - pos = sCcmOutsideCreditsSplinePositions; - focus = sCcmOutsideCreditsSplineFocus; + pos = sCCMOutsideCreditsSplinePositions; + focus = sCCMOutsideCreditsSplineFocus; } copy_spline_segment(sCurCreditsSplinePos, pos); @@ -10381,7 +10381,7 @@ struct Cutscene sCutsceneEnding[] = { { cutscene_ending_kiss, 0x10b }, #else { cutscene_ending_mario_land_closeup, 75 }, -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) { cutscene_ending_stars_free_peach, 431 }, #else { cutscene_ending_stars_free_peach, 386 }, @@ -10389,7 +10389,7 @@ struct Cutscene sCutsceneEnding[] = { { cutscene_ending_peach_appears, 139 }, { cutscene_ending_peach_descends, 590 }, { cutscene_ending_mario_to_peach, 95 }, -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) { cutscene_ending_peach_wakeup, 455 }, { cutscene_ending_dialog, 286 }, #else @@ -10567,7 +10567,7 @@ struct Cutscene sCutsceneExitWaterfall[] = { }; /** - * Cutscene that plays when Mario falls from WMOTR. + * Cutscene that plays when Mario falls from WMotR. */ struct Cutscene sCutsceneFallToCastleGrounds[] = { { cutscene_exit_fall_to_castle_grounds, 73 }, @@ -10836,7 +10836,7 @@ STATIC_ASSERT(ARRAY_COUNT(sZoomOutAreaMasks) - 1 == LEVEL_MAX / 2, "Make sure yo * TODO: Separate these into their own file(s) */ -struct CutsceneSplinePoint sBobCreditsSplinePositions[] = { +struct CutsceneSplinePoint sBoBCreditsSplinePositions[] = { { 1, 0, { 5984, 3255, 4975 } }, { 2, 0, { 4423, 3315, 1888 } }, { 3, 0, { 776, 2740, -1825 } }, @@ -10844,7 +10844,7 @@ struct CutsceneSplinePoint sBobCreditsSplinePositions[] = { { -1, 0, { 741, 4387, -5474 } } }; -struct CutsceneSplinePoint sBobCreditsSplineFocus[] = { +struct CutsceneSplinePoint sBoBCreditsSplineFocus[] = { { 0, 30, { 5817, 3306, 4507 } }, { 0, 40, { 4025, 3378, 1593 } }, { 0, 50, { 1088, 2652, -2205 } }, @@ -10852,7 +10852,7 @@ struct CutsceneSplinePoint sBobCreditsSplineFocus[] = { { -1, 60, { 1231, 4400, -5649 } } }; -struct CutsceneSplinePoint sWfCreditsSplinePositions[] = { +struct CutsceneSplinePoint sWFCreditsSplinePositions[] = { { 0, 0, { -301, 1399, 2643 } }, { 0, 0, { -182, 2374, 4572 } }, { 0, 0, { 4696, 3864, 413 } }, @@ -10860,7 +10860,7 @@ struct CutsceneSplinePoint sWfCreditsSplinePositions[] = { { -1, 0, { 1783, 4891, -1516 } } }; -struct CutsceneSplinePoint sWfCreditsSplineFocus[] = { +struct CutsceneSplinePoint sWFCreditsSplineFocus[] = { { 1, 30, { -249, 1484, 2153 } }, { 2, 40, { -200, 2470, 4082 } }, { 3, 40, { 4200, 3916, 370 } }, @@ -10868,7 +10868,7 @@ struct CutsceneSplinePoint sWfCreditsSplineFocus[] = { { -1, 40, { 1523, 4976, -1072 } } }; -struct CutsceneSplinePoint sJrbCreditsSplinePositions[] = { +struct CutsceneSplinePoint sJRBCreditsSplinePositions[] = { { 0, 0, { 5538, -4272, 2376 } }, { 0, 0, { 5997, -3303, 2261 } }, { 0, 0, { 6345, -3255, 2179 } }, @@ -10876,7 +10876,7 @@ struct CutsceneSplinePoint sJrbCreditsSplinePositions[] = { { -1, 0, { 6694, -3203, 2116 } } }; -struct CutsceneSplinePoint sJrbCreditsSplineFocus[] = { +struct CutsceneSplinePoint sJRBCreditsSplineFocus[] = { { 0, 50, { 5261, -4683, 2443 } }, { 0, 50, { 5726, -3675, 2456 } }, { 0, 50, { 6268, -2817, 2409 } }, @@ -10884,7 +10884,7 @@ struct CutsceneSplinePoint sJrbCreditsSplineFocus[] = { { -1, 50, { 7186, -3153, 2041 } } }; -struct CutsceneSplinePoint sCcmSlideCreditsSplinePositions[] = { +struct CutsceneSplinePoint sCCMSlideCreditsSplinePositions[] = { { 0, 0, { -6324, 6745, -5626 } }, { 1, 0, { -6324, 6745, -5626 } }, { 2, 0, { -6108, 6762, -5770 } }, @@ -10892,7 +10892,7 @@ struct CutsceneSplinePoint sCcmSlideCreditsSplinePositions[] = { { -1, 0, { -5672, 6790, -5979 } } }; -struct CutsceneSplinePoint sCcmSlideCreditsSplineFocus[] = { +struct CutsceneSplinePoint sCCMSlideCreditsSplineFocus[] = { { 0, 50, { -5911, 6758, -5908 } }, { 1, 50, { -5911, 6758, -5908 } }, { 2, 50, { -5652, 6814, -5968 } }, @@ -10900,21 +10900,21 @@ struct CutsceneSplinePoint sCcmSlideCreditsSplineFocus[] = { { -1, 50, { -5179, 6804, -6060 } } }; -struct CutsceneSplinePoint sBbhCreditsSplinePositions[] = { +struct CutsceneSplinePoint sBBHCreditsSplinePositions[] = { { 1, 0, { 1088, 341, 2447 } }, { 2, 0, { 1338, 610, 2808 } }, { 3, 0, { 2267, 1612, 2966 } }, { -1, 0, { 2296, 1913, 2990 } } }; -struct CutsceneSplinePoint sBbhCreditsSplineFocus[] = { +struct CutsceneSplinePoint sBBHCreditsSplineFocus[] = { { 1, 50, { 1160, 263, 1958 } }, { 2, 50, { 1034, 472, 2436 } }, { 3, 50, { 1915, 1833, 2688 } }, { -1, 50, { 2134, 2316, 2742 } } }; -struct CutsceneSplinePoint sHmcCreditsSplinePositions[] = { +struct CutsceneSplinePoint sHMCCreditsSplinePositions[] = { { 1, 0, { -5952, 1807, -5882 } }, { 2, 0, { -5623, 1749, -4863 } }, { 3, 0, { -5472, 1955, -2520 } }, @@ -10922,7 +10922,7 @@ struct CutsceneSplinePoint sHmcCreditsSplinePositions[] = { { -1, 0, { -5547, 391, -721 } } }; -struct CutsceneSplinePoint sHmcCreditsSplineFocus[] = { +struct CutsceneSplinePoint sHMCCreditsSplineFocus[] = { { 1, 210, { -5952, 1884, -6376 } }, { 2, 58, { -5891, 1711, -5283 } }, { 3, 30, { -5595, 1699, -2108 } }, @@ -10930,13 +10930,13 @@ struct CutsceneSplinePoint sHmcCreditsSplineFocus[] = { { -1, 31, { -5548, -85, -572 } } }; -struct CutsceneSplinePoint sThiWigglerCreditsSplinePositions[] = { +struct CutsceneSplinePoint sTHIWigglerCreditsSplinePositions[] = { { 1, 0, { -1411, 2474, -1276 } }, { 2, 0, { -1606, 2479, -434 } }, { -1, 0, { -1170, 2122, 1337 } } }; -struct CutsceneSplinePoint sThiWigglerCreditsSplineFocus[] = { +struct CutsceneSplinePoint sTHIWigglerCreditsSplineFocus[] = { { 1, 50, { -1053, 2512, -928 } }, { 2, 50, { -1234, 2377, -114 } }, { -1, 50, { -758, 2147, 1054 } } @@ -10960,7 +10960,7 @@ struct CutsceneSplinePoint sVolcanoCreditsSplineFocus[] = { { -1, 50, { 1002, 460, -694 } } }; -struct CutsceneSplinePoint sSslCreditsSplinePositions[] = { +struct CutsceneSplinePoint sSSLCreditsSplinePositions[] = { { 0, 0, { -4262, 4658, -5015 } }, { 0, 0, { -3274, 2963, -4661 } }, { 0, 0, { -2568, 812, -6528 } }, @@ -10969,7 +10969,7 @@ struct CutsceneSplinePoint sSslCreditsSplinePositions[] = { { -1, 0, { 2724, 660, -6298 } } }; -struct CutsceneSplinePoint sSslCreditsSplineFocus[] = { +struct CutsceneSplinePoint sSSLCreditsSplineFocus[] = { { 0, 50, { -4083, 4277, -4745 } }, { 0, 50, { -2975, 2574, -4759 } }, { 0, 50, { -2343, 736, -6088 } }, @@ -10978,7 +10978,7 @@ struct CutsceneSplinePoint sSslCreditsSplineFocus[] = { { -1, 50, { 2448, 612, -5884 } } }; -struct CutsceneSplinePoint sDddCreditsSplinePositions[] = { +struct CutsceneSplinePoint sDDDCreditsSplinePositions[] = { { 0, 0, { -874, -4933, 366 } }, { 0, 0, { -1463, -4782, 963 } }, { 0, 0, { -1893, -4684, 1303 } }, @@ -10988,7 +10988,7 @@ struct CutsceneSplinePoint sDddCreditsSplinePositions[] = { { -1, 0, { -4681, -1084, -623 } } }; -struct CutsceneSplinePoint sDddCreditsSplineFocus[] = { +struct CutsceneSplinePoint sDDDCreditsSplineFocus[] = { { 0, 50, { -1276, -4683, 622 } }, { 0, 50, { -1858, -4407, 1097 } }, { 0, 50, { -2324, -4332, 1318 } }, @@ -10998,35 +10998,35 @@ struct CutsceneSplinePoint sDddCreditsSplineFocus[] = { { -1, 50, { -4665, -664, -1007 } } }; -struct CutsceneSplinePoint sSlCreditsSplinePositions[] = { +struct CutsceneSplinePoint sSLCreditsSplinePositions[] = { { 0, 0, { 939, 6654, 6196 } }, { 0, 0, { 1873, 5160, 3714 } }, { 0, 0, { 3120, 3564, 1314 } }, { -1, 0, { 2881, 4231, 573 } } }; -struct CutsceneSplinePoint sSlCreditsSplineFocus[] = { +struct CutsceneSplinePoint sSLCreditsSplineFocus[] = { { 0, 50, { 875, 6411, 5763 } }, { 0, 50, { 1659, 4951, 3313 } }, { 0, 50, { 2630, 3565, 1215 } }, { -1, 50, { 2417, 4056, 639 } } }; -struct CutsceneSplinePoint sWdwCreditsSplinePositions[] = { +struct CutsceneSplinePoint sWDWCreditsSplinePositions[] = { { 0, 0, { 3927, 2573, 3685 } }, { 0, 0, { 2389, 2054, 1210 } }, { 0, 0, { 2309, 2069, 22 } }, { -1, 0, { 2122, 2271, -979 } } }; -struct CutsceneSplinePoint sWdwCreditsSplineFocus[] = { +struct CutsceneSplinePoint sWDWCreditsSplineFocus[] = { { 0, 50, { 3637, 2460, 3294 } }, { 0, 50, { 1984, 2067, 918 } }, { 0, 50, { 1941, 2255, -261 } }, { -1, 50, { 1779, 2587, -1158 } } }; -struct CutsceneSplinePoint sTtmCreditsSplinePositions[] = { +struct CutsceneSplinePoint sTTMCreditsSplinePositions[] = { { 0, 0, { 386, 2535, 644 } }, { 0, 0, { 1105, 2576, 918 } }, { 0, 0, { 3565, 2261, 2098 } }, @@ -11035,7 +11035,7 @@ struct CutsceneSplinePoint sTtmCreditsSplinePositions[] = { { -1, 0, { 3917, -3130, 3656 } } }; -struct CutsceneSplinePoint sTtmCreditsSplineFocus[] = { +struct CutsceneSplinePoint sTTMCreditsSplineFocus[] = { { 1, 50, { 751, 2434, 318 } }, { 2, 50, { 768, 2382, 603 } }, { 3, 60, { 3115, 2086, 1969 } }, @@ -11044,7 +11044,7 @@ struct CutsceneSplinePoint sTtmCreditsSplineFocus[] = { { -1, 50, { 4172, -3385, 4001 } } }; -struct CutsceneSplinePoint sThiHugeCreditsSplinePositions[] = { +struct CutsceneSplinePoint sTHIHugeCreditsSplinePositions[] = { { 0, 0, { 6990, -1000, -4858 } }, { 0, 0, { 7886, -1055, 2878 } }, { 0, 0, { 1952, -1481, 10920 } }, @@ -11054,7 +11054,7 @@ struct CutsceneSplinePoint sThiHugeCreditsSplinePositions[] = { { -1, 0, { -3246, 416, 3286 } } }; -struct CutsceneSplinePoint sThiHugeCreditsSplineFocus[] = { +struct CutsceneSplinePoint sTHIHugeCreditsSplineFocus[] = { { 1, 70, { 7022, -965, -5356 } }, { 2, 40, { 7799, -915, 2405 } }, { 3, 60, { 1878, -1137, 10568 } }, @@ -11064,35 +11064,35 @@ struct CutsceneSplinePoint sThiHugeCreditsSplineFocus[] = { { -1, 50, { -2875, 182, 3045 } } }; -struct CutsceneSplinePoint sTtcCreditsSplinePositions[] = { +struct CutsceneSplinePoint sTTCCreditsSplinePositions[] = { { 1, 0, { -1724, 277, -994 } }, { 2, 0, { -1720, 456, -995 } }, { 3, 0, { -1655, 810, -1014 } }, { -1, 0, { -1753, 883, -1009 } } }; -struct CutsceneSplinePoint sTtcCreditsSplineFocus[] = { +struct CutsceneSplinePoint sTTCCreditsSplineFocus[] = { { 1, 50, { -1554, 742, -1063 } }, { 2, 50, { -1245, 571, -1102 } }, { 3, 50, { -1220, 603, -1151 } }, { -1, 50, { -1412, 520, -1053 } } }; -struct CutsceneSplinePoint sRrCreditsSplinePositions[] = { +struct CutsceneSplinePoint sRRCreditsSplinePositions[] = { { 0, 0, { -1818, 4036, 97 } }, { 0, 0, { -575, 3460, -505 } }, { 0, 0, { 1191, 3611, -1134 } }, { -1, 0, { 2701, 3777, -3686 } } }; -struct CutsceneSplinePoint sRrCreditsSplineFocus[] = { +struct CutsceneSplinePoint sRRCreditsSplineFocus[] = { { 0, 50, { -1376, 3885, -81 } }, { 0, 50, { -146, 3343, -734 } }, { 0, 50, { 1570, 3446, -1415 } }, { -1, 50, { 2794, 3627, -3218 } } }; -struct CutsceneSplinePoint sSaCreditsSplinePositions[] = { +struct CutsceneSplinePoint sSACreditsSplinePositions[] = { { 0, 0, { -295, -396, -585 } }, { 1, 0, { -295, -396, -585 } }, { 2, 0, { -292, -856, -573 } }, @@ -11100,7 +11100,7 @@ struct CutsceneSplinePoint sSaCreditsSplinePositions[] = { { -1, 0, { 175, -856, -654 } } }; -struct CutsceneSplinePoint sSaCreditsSplineFocus[] = { +struct CutsceneSplinePoint sSACreditsSplineFocus[] = { { 0, 50, { -175, -594, -142 } }, { 1, 50, { -175, -594, -142 } }, { 2, 50, { -195, -956, -92 } }, @@ -11108,7 +11108,7 @@ struct CutsceneSplinePoint sSaCreditsSplineFocus[] = { { -1, 50, { -307, -956, -537 } } }; -struct CutsceneSplinePoint sCotmcCreditsSplinePositions[] = { +struct CutsceneSplinePoint sCotMCCreditsSplinePositions[] = { { 0, 0, { -296, 495, 1607 } }, { 0, 0, { -430, 541, 654 } }, { 0, 0, { -466, 601, -359 } }, @@ -11116,7 +11116,7 @@ struct CutsceneSplinePoint sCotmcCreditsSplinePositions[] = { { -1, 0, { -95, 366, -2922 } } }; -struct CutsceneSplinePoint sCotmcCreditsSplineFocus[] = { +struct CutsceneSplinePoint sCotMCCreditsSplineFocus[] = { { 0, 50, { -176, 483, 2092 } }, { 0, 50, { -122, 392, 1019 } }, { 0, 50, { -268, 450, -792 } }, @@ -11124,7 +11124,7 @@ struct CutsceneSplinePoint sCotmcCreditsSplineFocus[] = { { -1, 50, { -51, 355, -3420 } } }; -struct CutsceneSplinePoint sDddSubCreditsSplinePositions[] = { +struct CutsceneSplinePoint sDDDSubCreditsSplinePositions[] = { { 0, 0, { 4656, 2171, 5028 } }, { 0, 0, { 4548, 1182, 4596 } }, { 0, 0, { 5007, 813, 3257 } }, @@ -11132,7 +11132,7 @@ struct CutsceneSplinePoint sDddSubCreditsSplinePositions[] = { { -1, 0, { 4644, 774, 113 } } }; -struct CutsceneSplinePoint sDddSubCreditsSplineFocus[] = { +struct CutsceneSplinePoint sDDDSubCreditsSplineFocus[] = { { 0, 50, { 4512, 2183, 4549 } }, { 0, 50, { 4327, 838, 4308 } }, { 0, 50, { 4774, 749, 2819 } }, @@ -11140,14 +11140,14 @@ struct CutsceneSplinePoint sDddSubCreditsSplineFocus[] = { { -1, 50, { 4194, 885, -75 } } }; -struct CutsceneSplinePoint sCcmOutsideCreditsSplinePositions[] = { +struct CutsceneSplinePoint sCCMOutsideCreditsSplinePositions[] = { { 1, 0, { 1427, -1387, 5409 } }, { 2, 0, { -1646, -1536, 4526 } }, { 3, 0, { -3852, -1448, 3913 } }, { -1, 0, { -5199, -1366, 1886 } } }; -struct CutsceneSplinePoint sCcmOutsideCreditsSplineFocus[] = { +struct CutsceneSplinePoint sCCMOutsideCreditsSplineFocus[] = { { 1, 50, { 958, -1481, 5262 } }, { 2, 50, { -2123, -1600, 4391 } }, { 3, 50, { -3957, -1401, 3426 } }, diff --git a/src/game/cn_common_syms_1.c b/src/game/cn_common_syms_1.c new file mode 100644 index 00000000..6dd4b66e --- /dev/null +++ b/src/game/cn_common_syms_1.c @@ -0,0 +1,29 @@ +#include + +#include "macros.h" + +// This file is used to place iQue COMMON/.scommon symbols in the right locations. + +#ifdef VERSION_CN +FORCE_BSS u32 __osBaseCounter; +FORCE_BSS s16 gSaveOptSelectIndex; +FORCE_BSS s32 sNumCountOverflows; +FORCE_BSS s32 sLastHighestCount; +FORCE_BSS u32 __osViIntrCount; +FORCE_BSS s16 gCurrActNum; +FORCE_BSS u8 __osMaxControllers; +FORCE_BSS OSTime __osCurrentTime; +FORCE_BSS s16 gMenuOptSelectIndex; +FORCE_BSS s32 sLastHighestCount2; +FORCE_BSS u8 __osContLastCmd; +FORCE_BSS OSMesg __osEepromTimerMsg; +FORCE_BSS u32 __osTimerCounter; +FORCE_BSS s16 gCurrAreaIndex; +FORCE_BSS s32 sNumCountOverflows2; +FORCE_BSS struct MemoryPool *gEffectsMemoryPool; +FORCE_BSS s8 gNeverEnteredCastle; +FORCE_BSS s8 gRedCoinsCollected; +FORCE_BSS s16 gSavedCourseNum; +FORCE_BSS u32 __osFinalrom; +FORCE_BSS s16 gCurrCourseNum; +#endif diff --git a/src/game/cn_common_syms_2.c b/src/game/cn_common_syms_2.c new file mode 100644 index 00000000..d817ca05 --- /dev/null +++ b/src/game/cn_common_syms_2.c @@ -0,0 +1,103 @@ +#include + +#include "macros.h" +#include "types.h" + +// This file is used to place iQue COMMON/.scommon symbols in the right locations. + +#ifdef VERSION_CN +// Can't include the .h files directly because they have extern declarations +struct HudDisplay { + /*0x00*/ s16 lives; + /*0x02*/ s16 coins; + /*0x04*/ s16 stars; + /*0x06*/ s16 wedges; + /*0x08*/ s16 keys; + /*0x0A*/ s16 flags; + /*0x0C*/ u16 timer; +}; + +typedef struct { + /* 0x00 */ u32 ramarray[15]; + /* 0x3C */ u32 pifstatus; +} OSPifRam; + +struct SpawnInfo { + /*0x00*/ Vec3s startPos; + /*0x06*/ Vec3s startAngle; + /*0x0C*/ s8 areaIndex; + /*0x0D*/ s8 activeAreaIndex; + /*0x10*/ u32 behaviorArg; + /*0x14*/ void *behaviorScript; + /*0x18*/ struct GraphNode *model; + /*0x1C*/ struct SpawnInfo *next; +}; + +struct WarpTransitionData { + /*0x00*/ u8 red; + /*0x01*/ u8 green; + /*0x02*/ u8 blue; + + /*0x04*/ s16 startTexRadius; + /*0x06*/ s16 endTexRadius; + /*0x08*/ s16 startTexX; + /*0x0A*/ s16 startTexY; + /*0x0C*/ s16 endTexX; + /*0x0E*/ s16 endTexY; + + /*0x10*/ s16 texTimer; // always 0, does seems to affect transition when disabled +}; + +struct WarpTransition { + /*0x00*/ u8 isActive; // Is the transition active. (either TRUE or FALSE) + /*0x01*/ u8 type; // Determines the type of transition to use (circle, star, etc.) + /*0x02*/ u8 time; // Amount of time to complete the transition (in frames) + /*0x03*/ u8 pauseRendering; // Should the game stop rendering. (either TRUE or FALSE) + /*0x04*/ struct WarpTransitionData data; +}; + +typedef struct __OSEventState +{ + OSMesgQueue *messageQueue; + OSMesg message; +} __OSEventState; + +struct Area { + /*0x00*/ s8 index; + /*0x01*/ s8 flags; // Only has 1 flag: 0x01 = Is this the active area? + /*0x02*/ u16 terrainType; // default terrain of the level (set from level script cmd 0x31) + /*0x04*/ struct GraphNodeRoot *unk04; // geometry layout data + /*0x08*/ TerrainData *terrainData; // collision data (set from level script cmd 0x2E) + /*0x0C*/ RoomData *surfaceRooms; // (set from level script cmd 0x2F) + /*0x10*/ s16 *macroObjects; // Macro Objects Ptr (set from level script cmd 0x39) + /*0x14*/ struct ObjectWarpNode *warpNodes; + /*0x18*/ struct WarpNode *paintingWarpNodes; + /*0x1C*/ struct InstantWarp *instantWarps; + /*0x20*/ struct SpawnInfo *objectSpawnInfos; + /*0x24*/ struct Camera *camera; + /*0x28*/ struct UnusedArea28 *unused; // Filled by level script 0x3A, but is unused. + /*0x2C*/ struct Whirlpool *whirlpools[2]; + /*0x34*/ u8 dialog[2]; // Level start dialog number (set by level script cmd 0x30) + /*0x36*/ u16 musicParam; + /*0x38*/ u16 musicParam2; +}; + +FORCE_BSS struct HudDisplay gHudDisplay; +FORCE_BSS OSThread __osThreadSave; +FORCE_BSS OSPifRam __osContPifRam; +FORCE_BSS OSPiHandle __Dom2SpeedParam; +FORCE_BSS struct SpawnInfo gPlayerSpawnInfos[1]; +FORCE_BSS struct GraphNode *D_8033A160[0x100]; +FORCE_BSS OSPiHandle __CartRomHandle; +FORCE_BSS u8 sBssPad[0x48]; //! TODO: What is this space in the bss? +FORCE_BSS OSMesgQueue gOsPiMessageQueue; +FORCE_BSS OSPiHandle __Dom1SpeedParam; +FORCE_BSS OSTimer __osBaseTimer; +FORCE_BSS struct WarpTransition gWarpTransition; +FORCE_BSS OSTimer __osEepromTimer; +FORCE_BSS struct MarioState gMarioStates[1]; +FORCE_BSS __OSEventState __osEventStateTab[OS_NUM_EVENTS]; +FORCE_BSS OSMesgQueue __osEepromTimerQ; +FORCE_BSS struct Area gAreaData[8]; +FORCE_BSS OSMesgQueue gOsSiMessageQueue; +#endif diff --git a/src/game/crash_screen.c b/src/game/crash_screen.c index 64a0f81a..5381bc18 100644 --- a/src/game/crash_screen.c +++ b/src/game/crash_screen.c @@ -4,7 +4,7 @@ #include "sm64.h" -#if defined(TARGET_N64) && (defined(VERSION_EU) || defined(VERSION_SH)) +#if defined(TARGET_N64) && (defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN)) #include "lib/src/printf.h" @@ -118,7 +118,7 @@ void crash_screen_print(s32 x, s32 y, const char *fmt, ...) { if (size > 0) { ptr = buf; -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) while (size > 0) { #else while (*ptr) { @@ -130,7 +130,7 @@ void crash_screen_print(s32 x, s32 y, const char *fmt, ...) { crash_screen_draw_glyph(x, y, glyph); } -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) size--; #endif @@ -189,7 +189,7 @@ void draw_crash_screen(OSThread *thread) { cause = 17; } -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) osWritebackDCacheAll(); #endif diff --git a/src/game/envfx_snow.c b/src/game/envfx_snow.c index 3b55ced8..f421bc47 100644 --- a/src/game/envfx_snow.c +++ b/src/game/envfx_snow.c @@ -269,7 +269,7 @@ void envfx_update_snow_blizzard(s32 snowCylinderX, s32 snowCylinderY, s32 snowCy /*! Unused function. Checks whether a position is laterally within 3000 units * to the point (x: 3380, z: -520). Considering there is an unused blizzard * snow mode, this could have been used to check whether Mario is in a - * 'blizzard area'. In Cool Cool Mountain and Snowman's Land the area lies + * 'blizzard area'. In Cool, Cool Mountain and Snowman's Land the area lies * near the starting point and doesn't seem meaningful. Notably, the point is * close to the entrance of SL, so maybe there were plans for an extra hint to * find it. The radius of 3000 units is quite large for that though, covering diff --git a/src/game/game_init.c b/src/game/game_init.c index 4be1c7b5..89da5bf5 100644 --- a/src/game/game_init.c +++ b/src/game/game_init.c @@ -104,7 +104,7 @@ void init_rdp(void) { gDPSetColorDither(gDisplayListHead++, G_CD_MAGICSQ); gDPSetCycleType(gDisplayListHead++, G_CYC_FILL); -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) gDPSetAlphaDither(gDisplayListHead++, G_AD_PATTERN); #endif gDPPipeSync(gDisplayListHead++); @@ -407,7 +407,7 @@ UNUSED static void record_demo(void) { rawStickY = 0; } - // Rrecord the distinct input and timer so long as they are unique. + // Record the distinct input and timer so long as they are unique. // If the timer hits 0xFF, reset the timer for the next demo input. if (gRecordedDemoInput.timer == 0xFF || buttonMask != gRecordedDemoInput.buttonMask || rawStickX != gRecordedDemoInput.rawStickX || rawStickY != gRecordedDemoInput.rawStickY) { @@ -643,14 +643,21 @@ void setup_game_memory(void) { void thread5_game_loop(UNUSED void *arg) { struct LevelCommand *addr; + CN_DEBUG_PRINTF(("start gfx thread\n")); + setup_game_memory(); #if ENABLE_RUMBLE init_rumble_pak_scheduler_queue(); #endif + + CN_DEBUG_PRINTF(("init ctrl\n")); init_controllers(); + CN_DEBUG_PRINTF(("done ctrl\n")); + #if ENABLE_RUMBLE create_thread_6(); #endif + save_file_load_all(); set_vblank_handler(2, &gGameVblankHandler, &gGameVblankQueue, (OSMesg) 1); diff --git a/src/game/geo_misc.c b/src/game/geo_misc.c index 2fb8c5ef..7c34157f 100644 --- a/src/game/geo_misc.c +++ b/src/game/geo_misc.c @@ -43,10 +43,11 @@ s8 gFlyingCarpetState; * Texture coordinates are s10.5 fixed-point, which means you should left-shift the actual coordinates by 5. */ #ifndef GBI_FLOATS -void make_vertex(Vtx *vtx, s32 n, s16 x, s16 y, s16 z, s16 tx, s16 ty, u8 r, u8 g, u8 b, u8 a) { +void make_vertex(Vtx *vtx, s32 n, s16 x, s16 y, s16 z, s16 tx, s16 ty, u8 r, u8 g, u8 b, u8 a) #else -void make_vertex(Vtx *vtx, s32 n, f32 x, f32 y, f32 z, s16 tx, s16 ty, u8 r, u8 g, u8 b, u8 a) { +void make_vertex(Vtx *vtx, s32 n, f32 x, f32 y, f32 z, s16 tx, s16 ty, u8 r, u8 g, u8 b, u8 a) #endif +{ vtx[n].v.ob[0] = x; vtx[n].v.ob[1] = y; vtx[n].v.ob[2] = z; diff --git a/src/game/hud.c b/src/game/hud.c index 5a0f6806..2d94dce7 100644 --- a/src/game/hud.c +++ b/src/game/hud.c @@ -27,16 +27,6 @@ struct PowerMeterHUD { f32 unused; }; -struct UnusedHUDStruct { - u32 unused1; - u16 unused2; - u16 unused3; -}; - -struct CameraHUD { - s16 status; -}; - // Stores health segmented value defined by numHealthWedges // When the HUD is rendered this value is 8, full health. static s16 sPowerMeterStoredHealth; @@ -53,9 +43,15 @@ static struct PowerMeterHUD sPowerMeterHUD = { // when the power meter is hidden. s32 sPowerMeterVisibleTimer = 0; -UNUSED static struct UnusedHUDStruct sUnusedHUDValues = { 0x00, 0x0A, 0x00 }; +// TODO: fakediff? +#ifndef VERSION_CN +UNUSED static s32 sUnusedHUDValue1 = 0; +UNUSED static s16 sUnusedHUDValue2 = 10; +#else +UNUSED static s32 sUnusedHUDValue2 = 10; +#endif -static struct CameraHUD sCameraHUD = { CAM_STATUS_NONE }; +static s16 sCameraHUDStatus = CAM_STATUS_NONE; /** * Renders a rgba16 16x16 glyph texture from a table list. @@ -325,7 +321,10 @@ void render_hud_timer(void) { u16 timerValFrames = gHudDisplay.timer; u16 timerMins = timerValFrames / (30 * 60); u16 timerSecs = (timerValFrames - (timerMins * 1800)) / 30; - u16 timerFracSecs = ((timerValFrames - (timerMins * 1800) - (timerSecs * 30)) & 0xFFFF) / 3; + u16 timerFracSecs = ((u16) (timerValFrames - (timerMins * 1800) - (timerSecs * 30))) / 3; +#ifdef VERSION_CN + u8 timeString[2]; +#endif #ifdef VERSION_EU switch (eu_get_language()) { @@ -339,6 +338,10 @@ void render_hud_timer(void) { print_text(GFX_DIMENSIONS_RECT_FROM_RIGHT_EDGE(150), 185, "ZEIT"); break; } +#elif defined(VERSION_CN) + timeString[0] = 0xC0; // TODO: iQue colorful text + timeString[1] = 0x00; + print_text_centered(GFX_DIMENSIONS_RECT_FROM_RIGHT_EDGE(150), 185, (const char *) timeString); #else print_text(GFX_DIMENSIONS_RECT_FROM_RIGHT_EDGE(150), 185, "TIME"); #endif @@ -358,11 +361,11 @@ void render_hud_timer(void) { * defined in update_camera_status. */ void set_hud_camera_status(s16 status) { - sCameraHUD.status = status; + sCameraHUDStatus = status; } /** - * Renders camera HUD glyphs using a table list, depending of + * Renders camera HUD glyphs using a table list. Depending on * the camera status called, a defined glyph is rendered. */ void render_hud_camera_status(void) { @@ -370,14 +373,14 @@ void render_hud_camera_status(void) { s32 x = GFX_DIMENSIONS_RECT_FROM_RIGHT_EDGE(54); s32 y = 205; - if (sCameraHUD.status == CAM_STATUS_NONE) { + if (sCameraHUDStatus == CAM_STATUS_NONE) { return; } gSPDisplayList(gDisplayListHead++, dl_hud_img_begin); render_hud_tex_lut(x, y, (*cameraLUT)[GLYPH_CAM_CAMERA]); - switch (sCameraHUD.status & CAM_STATUS_MODE_GROUP) { + switch (sCameraHUDStatus & CAM_STATUS_MODE_GROUP) { case CAM_STATUS_MARIO: render_hud_tex_lut(x + 16, y, (*cameraLUT)[GLYPH_CAM_MARIO_HEAD]); break; @@ -389,7 +392,7 @@ void render_hud_camera_status(void) { break; } - switch (sCameraHUD.status & CAM_STATUS_C_MODE_GROUP) { + switch (sCameraHUDStatus & CAM_STATUS_C_MODE_GROUP) { case CAM_STATUS_C_DOWN: render_hud_small_tex_lut(x + 4, y + 16, (*cameraLUT)[GLYPH_CAM_ARROW_DOWN]); break; diff --git a/src/game/ingame_menu.c b/src/game/ingame_menu.c index 5c74037f..0ac715ba 100644 --- a/src/game/ingame_menu.c +++ b/src/game/ingame_menu.c @@ -28,26 +28,42 @@ #define LANGUAGE_FUNCTION gInGameLanguage #endif -u16 gDialogColorFadeTimer; -s8 gLastDialogLineNum; -s32 gDialogVariable; -u16 gDialogTextAlpha; -#if defined(VERSION_EU) +FORCE_BSS u16 gMenuTextColorTransTimer; +FORCE_BSS s8 gLastDialogLineNum; +FORCE_BSS s32 gDialogVariable; +FORCE_BSS u16 gMenuTextAlpha; +#ifdef VERSION_EU s16 gDialogX; s16 gDialogY; #endif -s16 gCutsceneMsgXOffset; -s16 gCutsceneMsgYOffset; +FORCE_BSS s16 gCutsceneMsgXOffset; +FORCE_BSS s16 gCutsceneMsgYOffset; s8 gRedCoinsCollected; extern u8 gLastCompletedCourseNum; extern u8 gLastCompletedStarNum; -enum DialogBoxState { - DIALOG_STATE_OPENING, - DIALOG_STATE_VERTICAL, - DIALOG_STATE_HORIZONTAL, - DIALOG_STATE_CLOSING +enum MenuState { + MENU_STATE_0, + MENU_STATE_1, + MENU_STATE_2, + MENU_STATE_3, + MENU_STATE_DEFAULT = MENU_STATE_0, + + // Dialog + MENU_STATE_DIALOG_OPENING = MENU_STATE_0, + MENU_STATE_DIALOG_OPEN = MENU_STATE_1, + MENU_STATE_DIALOG_SCROLLING = MENU_STATE_2, + MENU_STATE_DIALOG_CLOSING = MENU_STATE_3, + + // Pause Screen + MENU_STATE_PAUSE_SCREEN_OPENING = MENU_STATE_0, + MENU_STATE_PAUSE_SCREEN_COURSE = MENU_STATE_1, + MENU_STATE_PAUSE_SCREEN_CASTLE = MENU_STATE_2, + + // Course Complete Screen + MENU_STATE_COURSE_COMPLETE_SCREEN_OPENING = MENU_STATE_0, + MENU_STATE_COURSE_COMPLETE_SCREEN_OPEN = MENU_STATE_1 }; enum DialogBoxPageState { @@ -61,10 +77,10 @@ enum DialogBoxType { DIALOG_TYPE_ZOOM // used in signposts and wall signs and etc }; -#define DEFAULT_DIALOG_BOX_ANGLE 90.0f -#define DEFAULT_DIALOG_BOX_SCALE 19.0f +#define DIALOG_BOX_ANGLE_DEFAULT 90.0f +#define DIALOG_BOX_SCALE_DEFAULT 19.0f -#if defined(VERSION_US) || defined(VERSION_EU) +#if defined(VERSION_US) || defined(VERSION_EU) || defined(VERSION_CN) u8 gDialogCharWidths[256] = { // TODO: Is there a way to auto generate this? 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 6, 6, 6, 6, 6, 6, 6, 6, 5, 6, 6, 5, 8, 8, 6, 6, 6, 6, 6, 5, 6, 6, @@ -97,24 +113,23 @@ u8 gDialogCharWidths[256] = { // TODO: Is there a way to auto generate this? }; #endif -s8 gDialogBoxState = DIALOG_STATE_OPENING; -f32 gDialogBoxOpenTimer = DEFAULT_DIALOG_BOX_ANGLE; -f32 gDialogBoxScale = DEFAULT_DIALOG_BOX_SCALE; +s8 gMenuState = MENU_STATE_DEFAULT; +f32 gDialogBoxAngle = DIALOG_BOX_ANGLE_DEFAULT; +f32 gDialogBoxScale = DIALOG_BOX_SCALE_DEFAULT; s16 gDialogScrollOffsetY = 0; s8 gDialogBoxType = DIALOG_TYPE_ROTATE; s16 gDialogID = DIALOG_NONE; -s16 gLastDialogPageStrPos = 0; -s16 gDialogTextPos = 0; +s16 gNextDialogPageStartStrIndex = 0; +s16 gDialogPageStartStrIndex = 0; #ifdef VERSION_EU s32 gInGameLanguage = LANGUAGE_ENGLISH; #endif -s8 gDialogLineNum = 1; -s8 gLastDialogResponse = 0; +s8 gMenuLineNum = 1; +s8 gDialogWithChoice = FALSE; u8 gMenuHoldKeyIndex = 0; u8 gMenuHoldKeyTimer = 0; s32 gDialogResponse = DIALOG_RESPONSE_NONE; - void create_dl_identity_matrix(void) { Mtx *matrix = (Mtx *) alloc_display_list(sizeof(Mtx)); @@ -209,6 +224,33 @@ void create_dl_ortho_matrix(void) { #if defined(VERSION_US) || defined(VERSION_EU) UNUSED #endif +#ifdef VERSION_CN +static u8 *alloc_ia8_text_from_i1(u8 *in) { + s32 i, j; + u8 l, r; + u8 bitMask = 0x80; + u8 *out = alloc_display_list(8 * 8); + + if (out == NULL) { + return NULL; + } + + for (i = 0; i < 16; i++) { + for (j = 0; j < 8;) { + r = 0; + l = ((in[i] & (bitMask >> j)) >> (7 - j)) != 0 ? 0xF0 : 0x00; + j++; + r = ((in[i] & (bitMask >> j)) >> (7 - j)) != 0 ? 0x0F : 0x00; + out[i * 4 + j / 2] = l | r; + CN_DEBUG_PRINTF(("%x, ", out[i * 4 + j / 2])); + j++; + } + CN_DEBUG_PRINTF(("\n")); + } + + return out; +} +#else static u8 *alloc_ia8_text_from_i1(u16 *in, s16 width, s16 height) { s32 inPos; u16 bitMask; @@ -238,8 +280,14 @@ static u8 *alloc_ia8_text_from_i1(u16 *in, s16 width, s16 height) { return out; } +#endif -void render_generic_char(u8 c) { +#ifdef VERSION_CN +void render_generic_char(u16 c) +#else +void render_generic_char(u8 c) +#endif +{ void **fontLUT = segmented_to_virtual(main_font_lut); void *packedTexture = segmented_to_virtual(fontLUT[c]); #if defined(VERSION_JP) || defined(VERSION_SH) @@ -315,10 +363,22 @@ void render_uppercase_diacritic(s16 *xPos, s16 *yPos, u8 letter, u8 diacritic) { } #endif // VERSION_EU -#if defined(VERSION_US) || defined(VERSION_EU) +#ifdef VERSION_CN +void render_generic_char_cn(u16 c) { + void **fontLUT = segmented_to_virtual(main_font_lut); + void *packedTexture = segmented_to_virtual(fontLUT[c]); + void *unpackedTexture = alloc_ia8_text_from_i1(packedTexture); + + gDPPipeSync(gDisplayListHead++); + gDPSetTextureImage(gDisplayListHead++, G_IM_FMT_IA, G_IM_SIZ_16b, 1, VIRTUAL_TO_PHYSICAL(unpackedTexture)); + gSPDisplayList(gDisplayListHead++, dl_ia_text_tex_settings); +} +#endif + +#if defined(VERSION_US) || defined(VERSION_EU) || defined(VERSION_CN) +// First byte is length, rest is string struct MultiTextEntry { - u8 length; - u8 str[4]; + u8 str[5]; }; #define TEXT_THE_RAW ASCII_TO_DIALOG('t'), ASCII_TO_DIALOG('h'), ASCII_TO_DIALOG('e'), 0x00 @@ -331,7 +391,7 @@ enum MultiStringIDs { STRING_THE, STRING_YOU }; * 0: 'the' * 1: 'you' */ -#if defined(VERSION_US) +#if defined(VERSION_US) || defined(VERSION_CN) void render_multi_text_string(s8 multiTextID) #elif defined(VERSION_EU) void render_multi_text_string(s16 *xPos, s16 *yPos, s8 multiTextID) @@ -339,31 +399,38 @@ void render_multi_text_string(s16 *xPos, s16 *yPos, s8 multiTextID) { s8 i; struct MultiTextEntry textLengths[2] = { - { 3, { TEXT_THE_RAW } }, - { 3, { TEXT_YOU_RAW } }, + { { 3, TEXT_THE_RAW } }, + { { 3, TEXT_YOU_RAW } }, }; - for (i = 0; i < textLengths[multiTextID].length; i++) { -#if defined(VERSION_US) - render_generic_char(textLengths[multiTextID].str[i]); + for (i = 0; i < textLengths[multiTextID].str[0]; i++) { +#if defined(VERSION_US) || defined(VERSION_CN) + render_generic_char(textLengths[multiTextID].str[1 + i]); create_dl_translation_matrix( - MENU_MTX_NOPUSH, (f32)(gDialogCharWidths[textLengths[multiTextID].str[i]]), 0.0f, 0.0f); + MENU_MTX_NOPUSH, (f32)(gDialogCharWidths[textLengths[multiTextID].str[1 + i]]), 0.0f, 0.0f); #elif defined(VERSION_EU) - render_generic_char_at_pos(*xPos, *yPos, textLengths[multiTextID].str[i]); - *xPos += gDialogCharWidths[textLengths[multiTextID].str[i]]; + render_generic_char_at_pos(*xPos, *yPos, textLengths[multiTextID].str[1 + i]); + *xPos += gDialogCharWidths[textLengths[multiTextID].str[1 + i]]; #endif } } #endif #if defined(VERSION_JP) || defined(VERSION_SH) + #define CUR_CHAR str[strPos] #define MAX_STRING_WIDTH 18 #define CHAR_WIDTH_SPACE 5.0f #define CHAR_WIDTH_DEFAULT 10.0f +#elif defined(VERSION_CN) + #define CUR_CHAR strChar + #define MAX_STRING_WIDTH 18 + #define CHAR_WIDTH_SPACE gDialogCharWidths[DIALOG_CHAR_SPACE] + #define CHAR_WIDTH_DEFAULT gDialogCharWidths[CUR_CHAR] #else + #define CUR_CHAR str[strPos] #define MAX_STRING_WIDTH 16 - #define CHAR_WIDTH_SPACE (f32)(gDialogCharWidths[DIALOG_CHAR_SPACE]) - #define CHAR_WIDTH_DEFAULT (f32)(gDialogCharWidths[str[strPos]]) + #define CHAR_WIDTH_SPACE gDialogCharWidths[DIALOG_CHAR_SPACE] + #define CHAR_WIDTH_DEFAULT gDialogCharWidths[CUR_CHAR] #endif /** @@ -378,82 +445,102 @@ void print_generic_string(s16 x, s16 y, const u8 *str) { s16 xCoord = x; s16 yCoord = 240 - y; #endif +#ifdef VERSION_CN + s32 strChar; +#endif #ifndef VERSION_EU create_dl_translation_matrix(MENU_MTX_PUSH, x, y, 0.0f); #endif - while (str[strPos] != DIALOG_CHAR_TERMINATOR) { - switch (str[strPos]) { -#ifdef VERSION_EU - case DIALOG_CHAR_SPACE: - xCoord += 5; - break; - case DIALOG_CHAR_NEWLINE: - yCoord += 16; - xCoord = x; - lineNum++; - break; - case DIALOG_CHAR_LOWER_A_GRAVE: - case DIALOG_CHAR_LOWER_A_CIRCUMFLEX: - case DIALOG_CHAR_LOWER_A_UMLAUT: - render_lowercase_diacritic(&xCoord, &yCoord, ASCII_TO_DIALOG('a'), str[strPos] & 0xF); - break; - case DIALOG_CHAR_UPPER_A_UMLAUT: // @bug grave and circumflex (0x64-0x65) are absent here - render_uppercase_diacritic(&xCoord, &yCoord, ASCII_TO_DIALOG('A'), str[strPos] & 0xF); - break; - case DIALOG_CHAR_LOWER_E_GRAVE: - case DIALOG_CHAR_LOWER_E_CIRCUMFLEX: - case DIALOG_CHAR_LOWER_E_UMLAUT: - case DIALOG_CHAR_LOWER_E_ACUTE: - render_lowercase_diacritic(&xCoord, &yCoord, ASCII_TO_DIALOG('e'), str[strPos] & 0xF); - break; - case DIALOG_CHAR_UPPER_E_GRAVE: - case DIALOG_CHAR_UPPER_E_CIRCUMFLEX: - case DIALOG_CHAR_UPPER_E_UMLAUT: - case DIALOG_CHAR_UPPER_E_ACUTE: - render_uppercase_diacritic(&xCoord, &yCoord, ASCII_TO_DIALOG('E'), str[strPos] & 0xF); - break; - case DIALOG_CHAR_LOWER_U_GRAVE: - case DIALOG_CHAR_LOWER_U_CIRCUMFLEX: - case DIALOG_CHAR_LOWER_U_UMLAUT: - render_lowercase_diacritic(&xCoord, &yCoord, ASCII_TO_DIALOG('u'), str[strPos] & 0xF); - break; - case DIALOG_CHAR_UPPER_U_UMLAUT: // @bug grave and circumflex (0x84-0x85) are absent here - render_uppercase_diacritic(&xCoord, &yCoord, ASCII_TO_DIALOG('U'), str[strPos] & 0xF); - break; - case DIALOG_CHAR_LOWER_O_CIRCUMFLEX: - case DIALOG_CHAR_LOWER_O_UMLAUT: - render_lowercase_diacritic(&xCoord, &yCoord, ASCII_TO_DIALOG('o'), str[strPos] & 0xF); - break; - case DIALOG_CHAR_UPPER_O_UMLAUT: // @bug circumflex (0x95) is absent here - render_uppercase_diacritic(&xCoord, &yCoord, ASCII_TO_DIALOG('O'), str[strPos] & 0xF); - break; - case DIALOG_CHAR_LOWER_I_CIRCUMFLEX: - case DIALOG_CHAR_LOWER_I_UMLAUT: - render_lowercase_diacritic(&xCoord, &yCoord, DIALOG_CHAR_I_NO_DIA, str[strPos] & 0xF); - break; -#else // i.e. not EU - case DIALOG_CHAR_DAKUTEN: - mark = DIALOG_MARK_DAKUTEN; - break; - case DIALOG_CHAR_PERIOD_OR_HANDAKUTEN: - mark = DIALOG_MARK_HANDAKUTEN; - break; - case DIALOG_CHAR_NEWLINE: +#ifdef VERSION_CN + while (str[strPos] != DIALOG_CHAR_SPECIAL_MODIFIER || str[strPos + 1] != DIALOG_CHAR_TERMINATOR) { + strChar = str[strPos] << 8 | str[strPos + 1]; +#else + while (str[strPos] != SPECIAL_CHAR(DIALOG_CHAR_TERMINATOR)) { +#endif + switch (CUR_CHAR) { +#ifdef VERSION_CN + case SPECIAL_CHAR(DIALOG_CHAR_NEWLINE): gSPPopMatrix(gDisplayListHead++, G_MTX_MODELVIEW); create_dl_translation_matrix(MENU_MTX_PUSH, x, y - (lineNum * MAX_STRING_WIDTH), 0.0f); lineNum++; break; - case DIALOG_CHAR_PERIOD: + case SPECIAL_CHAR(DIALOG_CHAR_STAR_OPEN): // ??? + create_dl_translation_matrix(MENU_MTX_NOPUSH, 32.0f, 0.0f, 0.0f); + break; +#endif +#ifdef VERSION_EU + case SPECIAL_CHAR(DIALOG_CHAR_SPACE): + xCoord += 5; + break; + case SPECIAL_CHAR(DIALOG_CHAR_NEWLINE): + yCoord += 16; + xCoord = x; + lineNum++; + break; + case SPECIAL_CHAR(DIALOG_CHAR_LOWER_A_GRAVE): + case SPECIAL_CHAR(DIALOG_CHAR_LOWER_A_CIRCUMFLEX): + case SPECIAL_CHAR(DIALOG_CHAR_LOWER_A_UMLAUT): + render_lowercase_diacritic(&xCoord, &yCoord, ASCII_TO_DIALOG('a'), CUR_CHAR & 0xF); + break; + case SPECIAL_CHAR(DIALOG_CHAR_UPPER_A_UMLAUT): // @bug grave and circumflex (0x64-0x65) are absent here + render_uppercase_diacritic(&xCoord, &yCoord, ASCII_TO_DIALOG('A'), CUR_CHAR & 0xF); + break; + case SPECIAL_CHAR(DIALOG_CHAR_LOWER_E_GRAVE): + case SPECIAL_CHAR(DIALOG_CHAR_LOWER_E_CIRCUMFLEX): + case SPECIAL_CHAR(DIALOG_CHAR_LOWER_E_UMLAUT): + case SPECIAL_CHAR(DIALOG_CHAR_LOWER_E_ACUTE): + render_lowercase_diacritic(&xCoord, &yCoord, ASCII_TO_DIALOG('e'), CUR_CHAR & 0xF); + break; + case SPECIAL_CHAR(DIALOG_CHAR_UPPER_E_GRAVE): + case SPECIAL_CHAR(DIALOG_CHAR_UPPER_E_CIRCUMFLEX): + case SPECIAL_CHAR(DIALOG_CHAR_UPPER_E_UMLAUT): + case SPECIAL_CHAR(DIALOG_CHAR_UPPER_E_ACUTE): + render_uppercase_diacritic(&xCoord, &yCoord, ASCII_TO_DIALOG('E'), CUR_CHAR & 0xF); + break; + case SPECIAL_CHAR(DIALOG_CHAR_LOWER_U_GRAVE): + case SPECIAL_CHAR(DIALOG_CHAR_LOWER_U_CIRCUMFLEX): + case SPECIAL_CHAR(DIALOG_CHAR_LOWER_U_UMLAUT): + render_lowercase_diacritic(&xCoord, &yCoord, ASCII_TO_DIALOG('u'), CUR_CHAR & 0xF); + break; + case SPECIAL_CHAR(DIALOG_CHAR_UPPER_U_UMLAUT): // @bug grave and circumflex (0x84-0x85) are absent here + render_uppercase_diacritic(&xCoord, &yCoord, ASCII_TO_DIALOG('U'), CUR_CHAR & 0xF); + break; + case SPECIAL_CHAR(DIALOG_CHAR_LOWER_O_CIRCUMFLEX): + case SPECIAL_CHAR(DIALOG_CHAR_LOWER_O_UMLAUT): + render_lowercase_diacritic(&xCoord, &yCoord, ASCII_TO_DIALOG('o'), CUR_CHAR & 0xF); + break; + case SPECIAL_CHAR(DIALOG_CHAR_UPPER_O_UMLAUT): // @bug circumflex (0x95) is absent here + render_uppercase_diacritic(&xCoord, &yCoord, ASCII_TO_DIALOG('O'), CUR_CHAR & 0xF); + break; + case SPECIAL_CHAR(DIALOG_CHAR_LOWER_I_CIRCUMFLEX): + case SPECIAL_CHAR(DIALOG_CHAR_LOWER_I_UMLAUT): + render_lowercase_diacritic(&xCoord, &yCoord, DIALOG_CHAR_I_NO_DIA, CUR_CHAR & 0xF); + break; +#else // i.e. not EU + case SPECIAL_CHAR(DIALOG_CHAR_DAKUTEN): + mark = DIALOG_MARK_DAKUTEN; + break; + case SPECIAL_CHAR(DIALOG_CHAR_PERIOD_OR_HANDAKUTEN): + mark = DIALOG_MARK_HANDAKUTEN; + break; +#ifndef VERSION_CN + case SPECIAL_CHAR(DIALOG_CHAR_NEWLINE): + gSPPopMatrix(gDisplayListHead++, G_MTX_MODELVIEW); + create_dl_translation_matrix(MENU_MTX_PUSH, x, y - (lineNum * MAX_STRING_WIDTH), 0.0f); + lineNum++; + break; +#endif + case SPECIAL_CHAR(DIALOG_CHAR_PERIOD): create_dl_translation_matrix(MENU_MTX_PUSH, -2.0f, -5.0f, 0.0f); render_generic_char(DIALOG_CHAR_PERIOD_OR_HANDAKUTEN); gSPPopMatrix(gDisplayListHead++, G_MTX_MODELVIEW); break; #endif -#if defined(VERSION_US) || defined(VERSION_EU) - case DIALOG_CHAR_SLASH: +#if defined(VERSION_US) || defined(VERSION_EU) || defined(VERSION_CN) + case SPECIAL_CHAR(DIALOG_CHAR_SLASH): #ifdef VERSION_EU xCoord += gDialogCharWidths[DIALOG_CHAR_SPACE] * 2; #else @@ -461,14 +548,14 @@ void print_generic_string(s16 x, s16 y, const u8 *str) { MENU_MTX_NOPUSH, (f32)(gDialogCharWidths[DIALOG_CHAR_SPACE] * 2), 0.0f, 0.0f); #endif break; - case DIALOG_CHAR_MULTI_THE: + case SPECIAL_CHAR(DIALOG_CHAR_MULTI_THE): #ifdef VERSION_EU render_multi_text_string(&xCoord, &yCoord, STRING_THE); #else render_multi_text_string(STRING_THE); #endif break; - case DIALOG_CHAR_MULTI_YOU: + case SPECIAL_CHAR(DIALOG_CHAR_MULTI_YOU): #ifdef VERSION_EU render_multi_text_string(&xCoord, &yCoord, STRING_YOU); #else @@ -478,7 +565,7 @@ void print_generic_string(s16 x, s16 y, const u8 *str) { #endif #ifndef VERSION_EU - case DIALOG_CHAR_SPACE: + case SPECIAL_CHAR(DIALOG_CHAR_SPACE): create_dl_translation_matrix(MENU_MTX_NOPUSH, CHAR_WIDTH_SPACE, 0.0f, 0.0f); break; #ifdef VERSION_JP @@ -488,10 +575,20 @@ void print_generic_string(s16 x, s16 y, const u8 *str) { default: #ifdef VERSION_EU - render_generic_char_at_pos(xCoord, yCoord, str[strPos]); - xCoord += gDialogCharWidths[str[strPos]]; + render_generic_char_at_pos(xCoord, yCoord, CUR_CHAR); + xCoord += gDialogCharWidths[CUR_CHAR]; #else - render_generic_char(str[strPos]); +#ifdef VERSION_CN + if (strChar >= 0x0100) { + strChar = (strChar - 0xFF) * 2 + 0xFE; + render_generic_char_cn(strChar); + create_dl_translation_matrix(MENU_MTX_NOPUSH, 8.0f, 0.0f, 0.0f); + render_generic_char_cn(strChar + 1); + create_dl_translation_matrix(MENU_MTX_NOPUSH, 8.0f, 0.0f, 0.0f); + break; + } +#endif + render_generic_char(CUR_CHAR); if (mark != DIALOG_MARK_NONE) { create_dl_translation_matrix(MENU_MTX_PUSH, 5.0f, 5.0f, 0.0f); render_generic_char(DIALOG_CHAR_MARK_START + mark); @@ -506,7 +603,11 @@ void print_generic_string(s16 x, s16 y, const u8 *str) { #endif } +#ifdef VERSION_CN + strPos += 2; +#else strPos++; +#endif } #ifndef VERSION_EU @@ -539,6 +640,9 @@ void print_hud_lut_string(s8 hudLUT, s16 x, s16 y, const u8 *str) { u32 curX = x; u32 curY = y; +#ifdef VERSION_CN + u32 xOffset = 0; +#else u32 xStride; // X separation if (hudLUT == HUD_LUT_JPMENU) { @@ -550,11 +654,17 @@ void print_hud_lut_string(s8 hudLUT, s16 x, s16 y, const u8 *str) { xStride = 12; //? Shindou uses this. #endif } +#endif - while (str[strPos] != GLOBAR_CHAR_TERMINATOR) { + while (str[strPos] != GLOBAL_CHAR_TERMINATOR) { #ifndef VERSION_JP switch (str[strPos]) { -#ifdef VERSION_EU +#ifdef VERSION_CN + case GLOBAL_CHAR_NEWLINE: + curY += 16; + curX -= xOffset; + break; +#elif defined(VERSION_EU) case GLOBAL_CHAR_SPACE: curX += xStride / 2; break; @@ -579,19 +689,33 @@ void print_hud_lut_string(s8 hudLUT, s16 x, s16 y, const u8 *str) { #endif gDPPipeSync(gDisplayListHead++); +#ifndef VERSION_CN if (hudLUT == HUD_LUT_JPMENU) { gDPSetTextureImage(gDisplayListHead++, G_IM_FMT_RGBA, G_IM_SIZ_16b, 1, hudLUT1[str[strPos]]); } if (hudLUT == HUD_LUT_GLOBAL) { +#endif gDPSetTextureImage(gDisplayListHead++, G_IM_FMT_RGBA, G_IM_SIZ_16b, 1, hudLUT2[str[strPos]]); +#ifndef VERSION_CN } +#endif gSPDisplayList(gDisplayListHead++, dl_rgba16_load_tex_block); gSPTextureRectangle(gDisplayListHead++, curX << 2, curY << 2, (curX + 16) << 2, (curY + 16) << 2, G_TX_RENDERTILE, 0, 0, 1 << 10, 1 << 10); +#ifdef VERSION_CN + if (str[strPos] < 0x3A) { + curX += 12; + xOffset += 12; + } else { + curX += 16; + xOffset += 16; + } +#else curX += xStride; +#endif #ifndef VERSION_JP } #endif @@ -666,7 +790,7 @@ void print_menu_generic_string(s16 x, s16 y, const u8 *str) { mark = DIALOG_MARK_NONE; } #endif -#if defined(VERSION_JP) || defined(VERSION_SH) +#if defined(VERSION_JP) || defined(VERSION_SH) || defined(VERSION_CN) curX += 9; #else curX += gDialogCharWidths[str[strPos]]; @@ -689,7 +813,7 @@ void print_credits_string(s16 x, s16 y, const u8 *str) { G_TX_CLAMP, 3, G_TX_NOLOD, G_TX_CLAMP, 3, G_TX_NOLOD); gDPSetTileSize(gDisplayListHead++, G_TX_RENDERTILE, 0, 0, (8 - 1) << G_TEXTURE_IMAGE_FRAC, (8 - 1) << G_TEXTURE_IMAGE_FRAC); - while (str[strPos] != GLOBAR_CHAR_TERMINATOR) { + while (str[strPos] != GLOBAL_CHAR_TERMINATOR) { switch (str[strPos]) { case GLOBAL_CHAR_SPACE: curX += 4; @@ -762,16 +886,28 @@ void handle_menu_scrolling(s8 scrollDirection, s8 *currentIndex, s8 minIndex, s8 } // EU has both get_str_x_pos_from_center and get_str_x_pos_from_center_scale -// JP, US and Shindou only implement one or the other -#if defined(VERSION_US) || defined(VERSION_EU) +// JP, US, Shindou and iQue only implement one or the other +#if defined(VERSION_US) || defined(VERSION_EU) || defined(VERSION_CN) s16 get_str_x_pos_from_center(s16 centerPos, u8 *str, UNUSED f32 scale) { s16 strPos = 0; f32 spacesWidth = 0.0f; +#ifdef VERSION_CN + while (!(str[strPos] == DIALOG_CHAR_SPECIAL_MODIFIER && str[strPos + 1] == DIALOG_CHAR_TERMINATOR)) { + u16 character = (str[strPos] << 8) | str[strPos + 1]; + if (character <= 0xFF) { + spacesWidth += gDialogCharWidths[character]; + } else { + spacesWidth += 16.0; + } + strPos += 2; + } +#else while (str[strPos] != DIALOG_CHAR_TERMINATOR) { spacesWidth += gDialogCharWidths[str[strPos]]; strPos++; } +#endif // return the x position of where the string starts as half the string's // length from the position of the provided center. return (s16)(centerPos - (s16)(spacesWidth / 2.0)); @@ -800,15 +936,27 @@ s16 get_str_x_pos_from_center_scale(s16 centerPos, u8 *str, f32 scale) { } #endif -#if defined(VERSION_US) || defined(VERSION_EU) +#if defined(VERSION_US) || defined(VERSION_EU) || defined(VERSION_CN) s16 get_string_width(u8 *str) { s16 strPos = 0; s16 width = 0; +#ifdef VERSION_CN + while (!(str[strPos] == DIALOG_CHAR_SPECIAL_MODIFIER && str[strPos + 1] == DIALOG_CHAR_TERMINATOR)) { + u16 character = (str[strPos] << 8) | str[strPos + 1]; + if (character <= 0xFF) { + width += gDialogCharWidths[character]; + } else { + width += 16; + } + strPos += 2; + } +#else while (str[strPos] != DIALOG_CHAR_TERMINATOR) { width += gDialogCharWidths[str[strPos]]; strPos++; } +#endif return width; } #endif @@ -868,17 +1016,62 @@ void int_to_str(s32 num, u8 *dst) { digit3 = (num - digit1 * 100) - (digit2 * 10); if (digit1 != 0) { - dst[pos++] = digit1; + dst[pos] = digit1; pos++; } if (digit2 != 0 || digit1 != 0) { - dst[pos++] = digit2; + dst[pos] = digit2; pos++; } - dst[pos++] = digit3; + dst[pos] = digit3; + pos++; dst[pos] = DIALOG_CHAR_TERMINATOR; } +#ifdef VERSION_CN +void int_to_str_2(s32 num, u8 *dst) { + s32 digit1; + s32 digit2; + s32 digit3; + + s8 pos = 0; + + if (num > 999) { + dst[0] = 0x00; + dst[1] = 0x00; + dst[2] = DIALOG_CHAR_SPECIAL_MODIFIER; + dst[3] = DIALOG_CHAR_TERMINATOR; + return; + } + + digit1 = num / 100; + digit2 = (num - digit1 * 100) / 10; + digit3 = (num - digit1 * 100) - (digit2 * 10); + + if (digit1 != 0) { + dst[pos] = 0x00; + pos++; + dst[pos] = digit1; + pos++; + } + + if (digit2 != 0 || digit1 != 0) { + dst[pos] = 0x00; + pos++; + dst[pos] = digit2; + pos++; + } + + dst[pos] = 0x00; + pos++; + dst[pos] = digit3; + pos++; + dst[pos] = DIALOG_CHAR_SPECIAL_MODIFIER; + pos++; + dst[pos] = DIALOG_CHAR_TERMINATOR; +} +#endif + s16 get_dialog_id(void) { return gDialogID; } @@ -909,7 +1102,7 @@ void create_dialog_box_with_response(s16 dialog) { if (gDialogID == DIALOG_NONE) { gDialogID = dialog; gDialogBoxType = DIALOG_TYPE_ROTATE; - gLastDialogResponse = 1; + gDialogWithChoice = TRUE; } } @@ -920,13 +1113,13 @@ void reset_dialog_render_state(void) { trigger_cutscene_dialog(2); } - gDialogBoxScale = 19.0f; - gDialogBoxOpenTimer = 90.0f; - gDialogBoxState = DIALOG_STATE_OPENING; + gDialogBoxScale = DIALOG_BOX_SCALE_DEFAULT; + gDialogBoxAngle = DIALOG_BOX_ANGLE_DEFAULT; + gMenuState = MENU_STATE_DEFAULT; gDialogID = DIALOG_NONE; - gDialogTextPos = 0; - gLastDialogResponse = 0; - gLastDialogPageStrPos = 0; + gDialogPageStartStrIndex = 0; + gDialogWithChoice = FALSE; + gNextDialogPageStartStrIndex = 0; gDialogResponse = DIALOG_RESPONSE_NONE; } @@ -941,21 +1134,23 @@ void reset_dialog_render_state(void) { #endif void render_dialog_box_type(struct DialogEntry *dialog, s8 linesPerBox) { +#ifndef VERSION_CN UNUSED u8 filler[4]; +#endif create_dl_translation_matrix(MENU_MTX_NOPUSH, dialog->leftOffset, dialog->width, 0); switch (gDialogBoxType) { case DIALOG_TYPE_ROTATE: // Renders a dialog black box with zoom and rotation - if (gDialogBoxState == DIALOG_STATE_OPENING || gDialogBoxState == DIALOG_STATE_CLOSING) { + if (gMenuState == MENU_STATE_DIALOG_OPENING || gMenuState == MENU_STATE_DIALOG_CLOSING) { create_dl_scale_matrix(MENU_MTX_NOPUSH, 1.0 / gDialogBoxScale, 1.0 / gDialogBoxScale, 1.0f); // convert the speed into angle - create_dl_rotation_matrix(MENU_MTX_NOPUSH, gDialogBoxOpenTimer * 4.0f, 0, 0, 1.0f); + create_dl_rotation_matrix(MENU_MTX_NOPUSH, gDialogBoxAngle * 4.0f, 0, 0, 1.0f); } gDPSetEnvColor(gDisplayListHead++, 0, 0, 0, 150); break; case DIALOG_TYPE_ZOOM: // Renders a dialog white box with zoom - if (gDialogBoxState == DIALOG_STATE_OPENING || gDialogBoxState == DIALOG_STATE_CLOSING) { + if (gMenuState == MENU_STATE_DIALOG_OPENING || gMenuState == MENU_STATE_DIALOG_CLOSING) { create_dl_translation_matrix(MENU_MTX_NOPUSH, 65.0 - (65.0 / gDialogBoxScale), (40.0 / gDialogBoxScale) - 40, 0); create_dl_scale_matrix(MENU_MTX_NOPUSH, 1.0 / gDialogBoxScale, 1.0 / gDialogBoxScale, 1.0f); @@ -965,22 +1160,26 @@ void render_dialog_box_type(struct DialogEntry *dialog, s8 linesPerBox) { } create_dl_translation_matrix(MENU_MTX_PUSH, X_VAL1, Y_VAL1, 0); +#ifdef VERSION_CN + create_dl_scale_matrix(MENU_MTX_NOPUSH, 1.1f, ((f32)(linesPerBox + 1) / Y_VAL2) + 0.1, 1.0f); +#else create_dl_scale_matrix(MENU_MTX_NOPUSH, 1.1f, ((f32) linesPerBox / Y_VAL2) + 0.1, 1.0f); +#endif gSPDisplayList(gDisplayListHead++, dl_draw_text_bg_box); gSPPopMatrix(gDisplayListHead++, G_MTX_MODELVIEW); } void change_and_flash_dialog_text_color_lines(s8 colorMode, s8 lineNum) { - u8 colorFade; + u8 color; - if (colorMode == 1) { + if (colorMode == 1) { // unused if (lineNum == 1) { gDPSetEnvColor(gDisplayListHead++, 255, 255, 255, 255); } else { - if (lineNum == gDialogLineNum) { - colorFade = (gSineTable[gDialogColorFadeTimer >> 4] * 50.0f) + 200.0f; - gDPSetEnvColor(gDisplayListHead++, colorFade, colorFade, colorFade, 255); + if (lineNum == gMenuLineNum) { + color = sins(gMenuTextColorTransTimer) * 50.0f + 200.0f; + gDPSetEnvColor(gDisplayListHead++, color, color, color, 255); } else { gDPSetEnvColor(gDisplayListHead++, 200, 200, 200, 255); } @@ -1019,6 +1218,9 @@ void render_generic_dialog_char_at_pos(struct DialogEntry *dialog, s16 x, s16 y, #if defined(VERSION_JP) || defined(VERSION_SH) #define X_VAL3 5.0f #define Y_VAL3 20 +#elif defined(VERSION_CN) + #define X_VAL3 0.0f + #define Y_VAL3 20 #else #define X_VAL3 0.0f #define Y_VAL3 16 @@ -1077,7 +1279,7 @@ void render_star_count_dialog_text(s8 *xMatrix, s16 *linePos) #if defined(VERSION_JP) || defined(VERSION_SH) create_dl_translation_matrix(MENU_MTX_NOPUSH, 10 * *xMatrix, 0, 0); render_generic_char(tensDigit); -#elif defined(VERSION_US) +#elif defined(VERSION_US) || defined(VERSION_CN) if (*xMatrix != 1) { create_dl_translation_matrix( MENU_MTX_NOPUSH, (f32)(gDialogCharWidths[DIALOG_CHAR_SPACE] * *xMatrix), 0, 0); @@ -1105,7 +1307,7 @@ void render_star_count_dialog_text(s8 *xMatrix, s16 *linePos) #if defined(VERSION_JP) || defined(VERSION_SH) create_dl_translation_matrix(MENU_MTX_NOPUSH, 10 * *xMatrix, 0, 0); render_generic_char(onesDigit); -#elif defined(VERSION_US) +#elif defined(VERSION_US) || defined(VERSION_CN) if (*xMatrix != 1) { create_dl_translation_matrix( MENU_MTX_NOPUSH, (f32)(gDialogCharWidths[DIALOG_CHAR_SPACE] * (*xMatrix - 1)), 0, 0); @@ -1123,7 +1325,7 @@ void render_star_count_dialog_text(s8 *xMatrix, s16 *linePos) #endif } -#if defined(VERSION_US) || defined(VERSION_EU) +#if defined(VERSION_US) || defined(VERSION_EU) || defined(VERSION_CN) #ifdef VERSION_EU void render_multi_text_string_lines(s8 multiTextId, s8 lineNum, s8 linesPerBox, UNUSED s8 xMatrix, s8 lowerBound, struct DialogEntry *dialog) #else @@ -1132,31 +1334,31 @@ void render_multi_text_string_lines(s8 multiTextId, s8 lineNum, s16 *linePos, s8 { s8 i; struct MultiTextEntry textLengths[2] = { - { 3, { TEXT_THE_RAW } }, - { 3, { TEXT_YOU_RAW } }, + { { 3, TEXT_THE_RAW } }, + { { 3, TEXT_YOU_RAW } }, }; if (lineNum >= lowerBound && lineNum <= (lowerBound + linesPerBox)) { -#ifdef VERSION_US +#ifndef VERSION_EU if (*linePos != 0 || xMatrix != 1) { create_dl_translation_matrix( MENU_MTX_NOPUSH, (gDialogCharWidths[DIALOG_CHAR_SPACE] * (xMatrix - 1)), 0, 0); } #endif - for (i = 0; i < textLengths[multiTextId].length; i++) { + for (i = 0; i < textLengths[multiTextId].str[0]; i++) { #ifdef VERSION_EU - render_generic_dialog_char_at_pos(dialog, gDialogX, gDialogY, textLengths[multiTextId].str[i]); - gDialogX += gDialogCharWidths[textLengths[multiTextId].str[i]]; + render_generic_dialog_char_at_pos(dialog, gDialogX, gDialogY, textLengths[multiTextId].str[1 + i]); + gDialogX += gDialogCharWidths[textLengths[multiTextId].str[1 + i]]; #else - render_generic_char(textLengths[multiTextId].str[i]); + render_generic_char(textLengths[multiTextId].str[1 + i]); create_dl_translation_matrix( - MENU_MTX_NOPUSH, (gDialogCharWidths[textLengths[multiTextId].str[i]]), 0, 0); + MENU_MTX_NOPUSH, (gDialogCharWidths[textLengths[multiTextId].str[1 + i]]), 0, 0); #endif } } -#ifdef VERSION_US - linePos += textLengths[multiTextId].length; +#ifndef VERSION_EU + linePos += textLengths[multiTextId].str[0]; #endif } #endif @@ -1189,41 +1391,53 @@ void handle_dialog_text_and_pages(s8 colorMode, struct DialogEntry *dialog) void handle_dialog_text_and_pages(s8 colorMode, struct DialogEntry *dialog, s8 lowerBound) #endif { - UNUSED u8 filler[8]; + UNUSED u64 filler; #ifdef VERSION_EU s16 startY = 14; #endif +#ifdef VERSION_CN + s32 strChar; +#else u8 strChar; +#endif u8 *str = segmented_to_virtual(dialog->str); s8 lineNum = 1; s8 totalLines; s8 pageState = DIALOG_PAGE_STATE_NONE; - UNUSED s8 mark = DIALOG_MARK_NONE; // unused in US and EU + UNUSED s8 mark = DIALOG_MARK_NONE; // only used in JP and SH s8 xMatrix = 1; s8 linesPerBox = dialog->linesPerBox; - s16 strIdx; + s16 strIndex; #ifndef VERSION_EU s16 linePos = 0; #endif - if (gDialogBoxState == DIALOG_STATE_HORIZONTAL) { + if (gMenuState == MENU_STATE_DIALOG_SCROLLING) { // If scrolling, consider the number of lines for both // the current page and the page being scrolled to. +#ifdef VERSION_CN + totalLines = linesPerBox * 2 - 1; +#else totalLines = linesPerBox * 2 + 1; +#endif } else { +#ifdef VERSION_CN + totalLines = linesPerBox; +#else totalLines = linesPerBox + 1; +#endif } gSPDisplayList(gDisplayListHead++, dl_ia_text_begin); - strIdx = gDialogTextPos; + strIndex = gDialogPageStartStrIndex; #ifdef VERSION_EU gDialogX = 0; gDialogY = startY; #endif - if (gDialogBoxState == DIALOG_STATE_HORIZONTAL) { + if (gMenuState == MENU_STATE_DIALOG_SCROLLING) { #ifdef VERSION_EU gDialogY -= gDialogScrollOffsetY; #else @@ -1237,16 +1451,21 @@ void handle_dialog_text_and_pages(s8 colorMode, struct DialogEntry *dialog, s8 l while (pageState == DIALOG_PAGE_STATE_NONE) { change_and_flash_dialog_text_color_lines(colorMode, lineNum); - strChar = str[strIdx]; + +#ifdef VERSION_CN + strChar = str[strIndex] << 8 | str[strIndex + 1]; +#else + strChar = str[strIndex]; +#endif switch (strChar) { - case DIALOG_CHAR_TERMINATOR: + case SPECIAL_CHAR(DIALOG_CHAR_TERMINATOR): pageState = DIALOG_PAGE_STATE_END; #ifndef VERSION_EU gSPPopMatrix(gDisplayListHead++, G_MTX_MODELVIEW); #endif break; - case DIALOG_CHAR_NEWLINE: + case SPECIAL_CHAR(DIALOG_CHAR_NEWLINE): lineNum++; #ifdef VERSION_EU handle_dialog_scroll_page_state(lineNum, totalLines, &pageState, &xMatrix); @@ -1260,60 +1479,71 @@ void handle_dialog_text_and_pages(s8 colorMode, struct DialogEntry *dialog, s8 l break; #ifdef VERSION_EU - case DIALOG_CHAR_LOWER_A_GRAVE: - case DIALOG_CHAR_LOWER_A_CIRCUMFLEX: - case DIALOG_CHAR_LOWER_A_UMLAUT: + case SPECIAL_CHAR(DIALOG_CHAR_LOWER_A_GRAVE): + case SPECIAL_CHAR(DIALOG_CHAR_LOWER_A_CIRCUMFLEX): + case SPECIAL_CHAR(DIALOG_CHAR_LOWER_A_UMLAUT): render_dialog_lowercase_diacritic(dialog, ASCII_TO_DIALOG('a'), strChar & 0xF); break; - case DIALOG_CHAR_UPPER_A_GRAVE: - case DIALOG_CHAR_UPPER_A_CIRCUMFLEX: - case DIALOG_CHAR_UPPER_A_UMLAUT: + case SPECIAL_CHAR(DIALOG_CHAR_UPPER_A_GRAVE): + case SPECIAL_CHAR(DIALOG_CHAR_UPPER_A_CIRCUMFLEX): + case SPECIAL_CHAR(DIALOG_CHAR_UPPER_A_UMLAUT): render_dialog_uppercase_diacritic(dialog, ASCII_TO_DIALOG('A'), strChar & 0xF); break; - case DIALOG_CHAR_LOWER_E_GRAVE: - case DIALOG_CHAR_LOWER_E_CIRCUMFLEX: - case DIALOG_CHAR_LOWER_E_UMLAUT: - case DIALOG_CHAR_LOWER_E_ACUTE: + case SPECIAL_CHAR(DIALOG_CHAR_LOWER_E_GRAVE): + case SPECIAL_CHAR(DIALOG_CHAR_LOWER_E_CIRCUMFLEX): + case SPECIAL_CHAR(DIALOG_CHAR_LOWER_E_UMLAUT): + case SPECIAL_CHAR(DIALOG_CHAR_LOWER_E_ACUTE): render_dialog_lowercase_diacritic(dialog, ASCII_TO_DIALOG('e'), strChar & 0xF); break; - case DIALOG_CHAR_UPPER_E_GRAVE: - case DIALOG_CHAR_UPPER_E_CIRCUMFLEX: - case DIALOG_CHAR_UPPER_E_UMLAUT: - case DIALOG_CHAR_UPPER_E_ACUTE: + case SPECIAL_CHAR(DIALOG_CHAR_UPPER_E_GRAVE): + case SPECIAL_CHAR(DIALOG_CHAR_UPPER_E_CIRCUMFLEX): + case SPECIAL_CHAR(DIALOG_CHAR_UPPER_E_UMLAUT): + case SPECIAL_CHAR(DIALOG_CHAR_UPPER_E_ACUTE): render_dialog_uppercase_diacritic(dialog, ASCII_TO_DIALOG('E'), strChar & 0xF); break; - case DIALOG_CHAR_LOWER_U_GRAVE: - case DIALOG_CHAR_LOWER_U_CIRCUMFLEX: - case DIALOG_CHAR_LOWER_U_UMLAUT: + case SPECIAL_CHAR(DIALOG_CHAR_LOWER_U_GRAVE): + case SPECIAL_CHAR(DIALOG_CHAR_LOWER_U_CIRCUMFLEX): + case SPECIAL_CHAR(DIALOG_CHAR_LOWER_U_UMLAUT): render_dialog_lowercase_diacritic(dialog, ASCII_TO_DIALOG('u'), strChar & 0xF); break; - case DIALOG_CHAR_UPPER_U_GRAVE: - case DIALOG_CHAR_UPPER_U_CIRCUMFLEX: - case DIALOG_CHAR_UPPER_U_UMLAUT: + case SPECIAL_CHAR(DIALOG_CHAR_UPPER_U_GRAVE): + case SPECIAL_CHAR(DIALOG_CHAR_UPPER_U_CIRCUMFLEX): + case SPECIAL_CHAR(DIALOG_CHAR_UPPER_U_UMLAUT): render_dialog_uppercase_diacritic(dialog, ASCII_TO_DIALOG('U'), strChar & 0xF); break; - case DIALOG_CHAR_LOWER_O_CIRCUMFLEX: - case DIALOG_CHAR_LOWER_O_UMLAUT: + case SPECIAL_CHAR(DIALOG_CHAR_LOWER_O_CIRCUMFLEX): + case SPECIAL_CHAR(DIALOG_CHAR_LOWER_O_UMLAUT): render_dialog_lowercase_diacritic(dialog, ASCII_TO_DIALOG('o'), strChar & 0xF); break; - case DIALOG_CHAR_UPPER_O_CIRCUMFLEX: - case DIALOG_CHAR_UPPER_O_UMLAUT: + case SPECIAL_CHAR(DIALOG_CHAR_UPPER_O_CIRCUMFLEX): + case SPECIAL_CHAR(DIALOG_CHAR_UPPER_O_UMLAUT): render_dialog_uppercase_diacritic(dialog, ASCII_TO_DIALOG('O'), strChar & 0xF); break; - case DIALOG_CHAR_LOWER_I_CIRCUMFLEX: - case DIALOG_CHAR_LOWER_I_UMLAUT: + case SPECIAL_CHAR(DIALOG_CHAR_LOWER_I_CIRCUMFLEX): + case SPECIAL_CHAR(DIALOG_CHAR_LOWER_I_UMLAUT): render_dialog_lowercase_diacritic(dialog, DIALOG_CHAR_I_NO_DIA, strChar & 0xF); break; #else - case DIALOG_CHAR_DAKUTEN: + case SPECIAL_CHAR(DIALOG_CHAR_DAKUTEN): +#ifndef VERSION_CN mark = DIALOG_MARK_DAKUTEN; +#endif break; - case DIALOG_CHAR_PERIOD_OR_HANDAKUTEN: + case SPECIAL_CHAR(DIALOG_CHAR_PERIOD_OR_HANDAKUTEN): +#ifndef VERSION_CN mark = DIALOG_MARK_HANDAKUTEN; +#endif break; #endif - case DIALOG_CHAR_SPACE: +#ifdef VERSION_CN + case SPECIAL_CHAR(DIALOG_CHAR_STAR_OPEN): // ??? + xMatrix += 2; + linePos += 2; + break; +#endif + + case SPECIAL_CHAR(DIALOG_CHAR_SPACE): #ifdef VERSION_EU gDialogX += gDialogCharWidths[DIALOG_CHAR_SPACE]; #else @@ -1329,11 +1559,11 @@ void handle_dialog_text_and_pages(s8 colorMode, struct DialogEntry *dialog, s8 l break; #if defined(VERSION_JP) || defined(VERSION_SH) - case DIALOG_CHAR_PERIOD: + case SPECIAL_CHAR(DIALOG_CHAR_PERIOD): adjust_pos_and_print_period_char(&xMatrix, &linePos); break; #else - case DIALOG_CHAR_SLASH: + case SPECIAL_CHAR(DIALOG_CHAR_SLASH): #ifdef VERSION_EU gDialogX += gDialogCharWidths[DIALOG_CHAR_SPACE] * 2; #else @@ -1341,7 +1571,7 @@ void handle_dialog_text_and_pages(s8 colorMode, struct DialogEntry *dialog, s8 l linePos += 2; #endif break; - case DIALOG_CHAR_MULTI_THE: + case SPECIAL_CHAR(DIALOG_CHAR_MULTI_THE): #ifdef VERSION_EU render_multi_text_string_lines(STRING_THE, lineNum, linesPerBox, xMatrix, lowerBound, dialog); #else @@ -1349,7 +1579,7 @@ void handle_dialog_text_and_pages(s8 colorMode, struct DialogEntry *dialog, s8 l #endif xMatrix = 1; break; - case DIALOG_CHAR_MULTI_YOU: + case SPECIAL_CHAR(DIALOG_CHAR_MULTI_YOU): #ifdef VERSION_EU render_multi_text_string_lines(STRING_YOU, lineNum, linesPerBox, xMatrix, lowerBound, dialog); #else @@ -1359,7 +1589,7 @@ void handle_dialog_text_and_pages(s8 colorMode, struct DialogEntry *dialog, s8 l break; #endif - case DIALOG_CHAR_STAR_COUNT: + case SPECIAL_CHAR(DIALOG_CHAR_STAR_COUNT): #ifdef VERSION_EU render_star_count_dialog_text(dialog, &xMatrix); #else @@ -1368,14 +1598,45 @@ void handle_dialog_text_and_pages(s8 colorMode, struct DialogEntry *dialog, s8 l break; #ifdef VERSION_EU - case DIALOG_CHAR_DOUBLE_LOW_QUOTE: + case SPECIAL_CHAR(DIALOG_CHAR_DOUBLE_LOW_QUOTE): render_generic_dialog_char_at_pos(dialog, gDialogX, gDialogY + 8, 0xF6); gDialogX += gDialogCharWidths[0xF6]; break; #endif default: // any other character -#if defined(VERSION_JP) || defined(VERSION_SH) +#ifdef VERSION_CN + if (strChar >= 0x0100) { + strChar = strChar * 2 - 0x0100; + + if (lineNum < lowerBound || lineNum > (lowerBound + linesPerBox)) { + break; + } + + if (linePos != 0 || xMatrix != 1) { + create_dl_translation_matrix(MENU_MTX_NOPUSH, gDialogCharWidths[DIALOG_CHAR_SPACE] * (xMatrix - 1), 0.0f, 0.0f); + } + + render_generic_char_cn(strChar); + create_dl_translation_matrix(MENU_MTX_NOPUSH, 8.0f, 0.0f, 0.0f); + render_generic_char_cn(strChar + 1); + create_dl_translation_matrix(MENU_MTX_NOPUSH, 8.0f, 0.0f, 0.0f); + } else { + if (lineNum < lowerBound || lineNum > (lowerBound + linesPerBox)) { + break; + } + + if (linePos != 0 || xMatrix != 1) { + create_dl_translation_matrix(MENU_MTX_NOPUSH, gDialogCharWidths[DIALOG_CHAR_SPACE] * (xMatrix - 1), 0.0f, 0.0f); + } + + render_generic_char(strChar); + create_dl_translation_matrix(MENU_MTX_NOPUSH, gDialogCharWidths[strChar], 0.0f, 0.0f); + } + + xMatrix = 1; + linePos++; +#elif defined(VERSION_JP) || defined(VERSION_SH) #ifdef VERSION_SH if (lineNum >= lowerBound && lineNum <= (lowerBound + linesPerBox)) { #endif @@ -1418,22 +1679,22 @@ void handle_dialog_text_and_pages(s8 colorMode, struct DialogEntry *dialog, s8 l #ifdef VERSION_JP if (linePos == 12) { - if (str[strIdx + 1] == DIALOG_CHAR_PERIOD) { + if (str[strIndex + 1] == DIALOG_CHAR_PERIOD) { adjust_pos_and_print_period_char(&xMatrix, &linePos); - strIdx++; + strIndex++; } - if (str[strIdx + 1] == DIALOG_CHAR_COMMA) { + if (str[strIndex + 1] == DIALOG_CHAR_COMMA) { create_dl_translation_matrix(MENU_MTX_NOPUSH, 10 * xMatrix, 0, 0); render_generic_char(DIALOG_CHAR_COMMA); - strIdx++; + strIndex++; } - if (str[strIdx + 1] == DIALOG_CHAR_NEWLINE) { - strIdx++; + if (str[strIndex + 1] == DIALOG_CHAR_NEWLINE) { + strIndex++; } - if (str[strIdx + 1] == DIALOG_CHAR_TERMINATOR) { + if (str[strIndex + 1] == DIALOG_CHAR_TERMINATOR) { pageState = DIALOG_PAGE_STATE_END; gSPPopMatrix(gDisplayListHead++, G_MTX_MODELVIEW); break; // exit loop @@ -1444,16 +1705,20 @@ void handle_dialog_text_and_pages(s8 colorMode, struct DialogEntry *dialog, s8 l } #endif - strIdx++; +#ifdef VERSION_CN + strIndex += 2; +#else + strIndex++; +#endif } gSPDisplayList(gDisplayListHead++, dl_ia_text_end); - if (gDialogBoxState == DIALOG_STATE_VERTICAL) { + if (gMenuState == MENU_STATE_DIALOG_OPEN) { if (pageState == DIALOG_PAGE_STATE_END) { - gLastDialogPageStrPos = -1; + gNextDialogPageStartStrIndex = -1; } else { - gLastDialogPageStrPos = strIdx; + gNextDialogPageStartStrIndex = strIndex; } } @@ -1465,23 +1730,28 @@ void handle_dialog_text_and_pages(s8 colorMode, struct DialogEntry *dialog, s8 l #define X_VAL4_2 25 #define Y_VAL4_1 1 #define Y_VAL4_2 20 +#elif defined(VERSION_CN) + #define X_VAL4_1 58 + #define X_VAL4_2 0 + #define Y_VAL4_1 2 + #define Y_VAL4_2 20 #else #define X_VAL4_1 56 - #define X_VAL4_2 47 + #define X_VAL4_2 9 #define Y_VAL4_1 2 #define Y_VAL4_2 16 #endif void render_dialog_triangle_choice(void) { - if (gDialogBoxState == DIALOG_STATE_VERTICAL) { - handle_menu_scrolling(MENU_SCROLL_HORIZONTAL, &gDialogLineNum, 1, 2); + if (gMenuState == MENU_STATE_DIALOG_OPEN) { + handle_menu_scrolling(MENU_SCROLL_HORIZONTAL, &gMenuLineNum, 1, 2); } - create_dl_translation_matrix(MENU_MTX_NOPUSH, (gDialogLineNum * X_VAL4_1) - X_VAL4_2, Y_VAL4_1 - (gLastDialogLineNum * Y_VAL4_2), 0); + create_dl_translation_matrix(MENU_MTX_NOPUSH, ((gMenuLineNum - 1) * X_VAL4_1) + X_VAL4_2, Y_VAL4_1 - (gLastDialogLineNum * Y_VAL4_2), 0); - if (gDialogBoxType == DIALOG_TYPE_ROTATE) { + if (gDialogBoxType == DIALOG_TYPE_ROTATE) { // White Text gDPSetEnvColor(gDisplayListHead++, 255, 255, 255, 255); - } else { + } else { // Black Text gDPSetEnvColor(gDisplayListHead++, 0, 0, 0, 255); } @@ -1503,6 +1773,11 @@ void render_dialog_triangle_choice(void) { #define Y_VAL5_1 -16 #define Y_VAL5_2 3 #define X_Y_VAL6 0.5f +#elif defined(VERSION_CN) + #define X_VAL5 118.0f + #define Y_VAL5_1 -18 + #define Y_VAL5_2 5 + #define X_Y_VAL6 0.8f #endif void render_dialog_triangle_next(s8 linesPerBox) { @@ -1514,7 +1789,7 @@ void render_dialog_triangle_next(s8 linesPerBox) { create_dl_translation_matrix(MENU_MTX_PUSH, X_VAL5, (linesPerBox * Y_VAL5_1) + Y_VAL5_2, 0); create_dl_scale_matrix(MENU_MTX_NOPUSH, X_Y_VAL6, X_Y_VAL6, 1.0f); - create_dl_rotation_matrix(MENU_MTX_NOPUSH, -DEFAULT_DIALOG_BOX_ANGLE, 0, 0, 1.0f); + create_dl_rotation_matrix(MENU_MTX_NOPUSH, -90.0f, 0, 0, 1.0f); if (gDialogBoxType == DIALOG_TYPE_ROTATE) { // White Text gDPSetEnvColor(gDisplayListHead++, 255, 255, 255, 255); @@ -1552,14 +1827,14 @@ void handle_special_dialog_text(s16 dialogID) { // dialog ID tables, in order } for (i = 0; i < (s16) ARRAY_COUNT(dialogRaceSound); i++) { - if (dialogRaceSound[i] == dialogID && gDialogLineNum == 1) { + if (dialogRaceSound[i] == dialogID && gMenuLineNum == DIALOG_RESPONSE_YES) { play_race_fanfare(); return; } } for (i = 0; i < (s16) ARRAY_COUNT(dialogStarSound); i++) { - if (dialogStarSound[i] == dialogID && gDialogLineNum == 1) { + if (dialogStarSound[i] == dialogID && gMenuLineNum == DIALOG_RESPONSE_YES) { play_sound(SOUND_MENU_STAR_SOUND, gGlobalSoundSource); return; } @@ -1575,6 +1850,17 @@ void handle_special_dialog_text(s16 dialogID) { // dialog ID tables, in order s16 gMenuMode = MENU_MODE_NONE; +#ifdef VERSION_CN +u8 gEndCutsceneStrEn0[] = { TEXT_EMPTY_STRING }; +u8 gEndCutsceneStrEn1[] = { TEXT_EMPTY_STRING }; +u8 gEndCutsceneStrEn2[] = { TEXT_EMPTY_STRING }; +u8 gEndCutsceneStrEn3[] = { TEXT_EMPTY_STRING }; +u8 gEndCutsceneStrEn4[] = { TEXT_EMPTY_STRING }; +u8 gEndCutsceneStrEn5[] = { TEXT_EMPTY_STRING }; +u8 gEndCutsceneStrEn6[] = { TEXT_EMPTY_STRING }; +u8 gEndCutsceneStrEn7[] = { TEXT_EMPTY_STRING }; +u8 gEndCutsceneStrEn8[] = { TEXT_EMPTY_STRING }; +#else u8 gEndCutsceneStrEn0[] = { TEXT_FILE_MARIO_EXCLAMATION }; u8 gEndCutsceneStrEn1[] = { TEXT_POWER_STARS_RESTORED }; u8 gEndCutsceneStrEn2[] = { TEXT_THANKS_TO_YOU }; @@ -1584,6 +1870,7 @@ u8 gEndCutsceneStrEn5[] = { TEXT_LISTEN_EVERYBODY }; u8 gEndCutsceneStrEn6[] = { TEXT_LETS_HAVE_CAKE }; u8 gEndCutsceneStrEn7[] = { TEXT_FOR_MARIO }; u8 gEndCutsceneStrEn8[] = { TEXT_FILE_MARIO_QUESTION }; +#endif u8 *gEndCutsceneStringsEn[] = { gEndCutsceneStrEn0, @@ -1665,7 +1952,7 @@ s8 gDialogCourseActNum = 1; #define DIAG_VAL4 4 #else #define DIAG_VAL1 16 -#ifdef VERSION_US +#if defined(VERSION_US) || defined(VERSION_CN) #define DIAG_VAL2 240 #else #define DIAG_VAL2 238 @@ -1680,7 +1967,7 @@ void render_dialog_entries(void) { #endif void **dialogTable; struct DialogEntry *dialog; -#if defined(VERSION_US) || defined(VERSION_SH) +#if defined(VERSION_US) || defined(VERSION_SH) || defined(VERSION_CN) s8 lowerBound; #endif @@ -1703,7 +1990,7 @@ void render_dialog_entries(void) { dialog = segmented_to_virtual(dialogTable[gDialogID]); // if the dialog entry is invalid, set the ID to DIALOG_NONE. - if (segmented_to_virtual(NULL) == dialog) { + if (dialog == segmented_to_virtual(NULL)) { gDialogID = DIALOG_NONE; return; } @@ -1713,40 +2000,40 @@ void render_dialog_entries(void) { gDialogY = 0; #endif - switch (gDialogBoxState) { - case DIALOG_STATE_OPENING: - if (gDialogBoxOpenTimer == DEFAULT_DIALOG_BOX_ANGLE) { + switch (gMenuState) { + case MENU_STATE_DIALOG_OPENING: + if (gDialogBoxAngle == DIALOG_BOX_ANGLE_DEFAULT) { play_dialog_sound(gDialogID); play_sound(SOUND_MENU_MESSAGE_APPEAR, gGlobalSoundSource); } if (gDialogBoxType == DIALOG_TYPE_ROTATE) { - gDialogBoxOpenTimer -= 7.5; + gDialogBoxAngle -= 7.5; gDialogBoxScale -= 1.5; } else { - gDialogBoxOpenTimer -= 10.0; + gDialogBoxAngle -= 10.0; gDialogBoxScale -= 2.0; } - if (gDialogBoxOpenTimer == 0.0f) { - gDialogBoxState = DIALOG_STATE_VERTICAL; - gDialogLineNum = 1; + if (gDialogBoxAngle == 0.0f) { + gMenuState = MENU_STATE_DIALOG_OPEN; + gMenuLineNum = 1; } #ifndef VERSION_JP lowerBound = 1; #endif break; - case DIALOG_STATE_VERTICAL: - gDialogBoxOpenTimer = 0.0f; + case MENU_STATE_DIALOG_OPEN: + gDialogBoxAngle = 0.0f; if ((gPlayer3Controller->buttonPressed & A_BUTTON) - || (gPlayer3Controller->buttonPressed & B_BUTTON)) { - if (gLastDialogPageStrPos == -1) { + || (gPlayer3Controller->buttonPressed & B_BUTTON)) { + if (gNextDialogPageStartStrIndex == -1) { handle_special_dialog_text(gDialogID); - gDialogBoxState = DIALOG_STATE_CLOSING; + gMenuState = MENU_STATE_DIALOG_CLOSING; } else { - gDialogBoxState = DIALOG_STATE_HORIZONTAL; + gMenuState = MENU_STATE_DIALOG_SCROLLING; play_sound(SOUND_MENU_MESSAGE_NEXT_PAGE, gGlobalSoundSource); } } @@ -1755,12 +2042,12 @@ void render_dialog_entries(void) { #endif break; - case DIALOG_STATE_HORIZONTAL: + case MENU_STATE_DIALOG_SCROLLING: gDialogScrollOffsetY += dialog->linesPerBox * 2; if (gDialogScrollOffsetY >= dialog->linesPerBox * DIAG_VAL1) { - gDialogTextPos = gLastDialogPageStrPos; - gDialogBoxState = DIALOG_STATE_VERTICAL; + gDialogPageStartStrIndex = gNextDialogPageStartStrIndex; + gMenuState = MENU_STATE_DIALOG_OPEN; gDialogScrollOffsetY = 0; } #ifndef VERSION_JP @@ -1768,8 +2055,8 @@ void render_dialog_entries(void) { #endif break; - case DIALOG_STATE_CLOSING: - if (gDialogBoxOpenTimer == 20.0f) { + case MENU_STATE_DIALOG_CLOSING: + if (gDialogBoxAngle == 20.0f) { level_set_transition(0, NULL); play_sound(SOUND_MENU_MESSAGE_DISAPPEAR, gGlobalSoundSource); @@ -1777,18 +2064,18 @@ void render_dialog_entries(void) { trigger_cutscene_dialog(2); } - gDialogResponse = gDialogLineNum; + gDialogResponse = gMenuLineNum; } - gDialogBoxOpenTimer = gDialogBoxOpenTimer + 10.0f; - gDialogBoxScale = gDialogBoxScale + 2.0f; + gDialogBoxAngle += 10.0f; + gDialogBoxScale += 2.0f; - if (gDialogBoxOpenTimer == DEFAULT_DIALOG_BOX_ANGLE) { - gDialogBoxState = DIALOG_STATE_OPENING; + if (gDialogBoxAngle == DIALOG_BOX_ANGLE_DEFAULT) { + gMenuState = MENU_STATE_DEFAULT; gDialogID = DIALOG_NONE; - gDialogTextPos = 0; - gLastDialogResponse = 0; - gLastDialogPageStrPos = 0; + gDialogPageStartStrIndex = 0; + gDialogWithChoice = FALSE; + gNextDialogPageStartStrIndex = 0; gDialogResponse = DIALOG_RESPONSE_NONE; } #ifndef VERSION_JP @@ -1799,6 +2086,20 @@ void render_dialog_entries(void) { render_dialog_box_type(dialog, dialog->linesPerBox); +#ifdef VERSION_CN +// This isn't really a diff. The iQue compiler doesn't allow the use of ifdefs inside a macro for some reason, so those were eliminated. +#ifdef WIDESCREEN +#define ulx 0 +#define lrx SCREEN_WIDTH +#else +#define ulx ensure_nonnegative(dialog->leftOffset) +#define lrx ensure_nonnegative(dialog->leftOffset + DIAG_VAL3) +#endif + gDPSetScissor(gDisplayListHead++, G_SC_NON_INTERLACE, ulx, ensure_nonnegative(DIAG_VAL2 - dialog->width), + lrx, ensure_nonnegative((256 - dialog->width) + (dialog->linesPerBox * 80 / DIAG_VAL4))); +#undef ulx +#undef lrx +#else gDPSetScissor( gDisplayListHead++, G_SC_NON_INTERLACE, // Horizontal scissoring isn't really required and can potentially mess up widescreen enhancements. @@ -1824,6 +2125,7 @@ void render_dialog_entries(void) { ensure_nonnegative((240 - dialog->width) + (dialog->linesPerBox * 80 / DIAG_VAL4)) #endif ); +#endif #ifdef VERSION_JP handle_dialog_text_and_pages(0, dialog); @@ -1831,7 +2133,7 @@ void render_dialog_entries(void) { handle_dialog_text_and_pages(0, dialog, lowerBound); #endif - if (gLastDialogPageStrPos == -1 && gLastDialogResponse == 1) { + if (gNextDialogPageStartStrIndex == -1 && gDialogWithChoice == TRUE) { render_dialog_triangle_choice(); } @@ -1845,7 +2147,7 @@ void render_dialog_entries(void) { #define BORDER_HEIGHT 1 #endif - if (gLastDialogPageStrPos != -1 && gDialogBoxState == DIALOG_STATE_VERTICAL) { + if (gNextDialogPageStartStrIndex != -1 && gMenuState == MENU_STATE_DIALOG_OPEN) { render_dialog_triangle_next(dialog->linesPerBox); } } @@ -1913,12 +2215,12 @@ void print_credits_str_ascii(s16 x, s16 y, const char *str) { u8 c = str[pos]; u8 creditStr[100]; - while (c != 0) { + while (c != '\0') { creditStr[pos++] = ascii_to_credits_char(c); c = str[pos]; } - creditStr[pos] = GLOBAR_CHAR_TERMINATOR; + creditStr[pos] = GLOBAL_CHAR_TERMINATOR; print_credits_string(x, y, creditStr); } @@ -2103,12 +2405,12 @@ void render_hud_cannon_reticle(void) { gSPPopMatrix(gDisplayListHead++, G_MTX_MODELVIEW); create_dl_translation_matrix(MENU_MTX_PUSH, 8.0f, -20.0f, 0); - create_dl_rotation_matrix(MENU_MTX_NOPUSH, DEFAULT_DIALOG_BOX_ANGLE, 0, 0, 1.0f); + create_dl_rotation_matrix(MENU_MTX_NOPUSH, 90.0f, 0, 0, 1.0f); gSPDisplayList(gDisplayListHead++, dl_draw_triangle); gSPPopMatrix(gDisplayListHead++, G_MTX_MODELVIEW); create_dl_translation_matrix(MENU_MTX_PUSH, -8.0f, 20.0f, 0); - create_dl_rotation_matrix(MENU_MTX_NOPUSH, -DEFAULT_DIALOG_BOX_ANGLE, 0, 0, 1.0f); + create_dl_rotation_matrix(MENU_MTX_NOPUSH, -90.0f, 0, 0, 1.0f); gSPDisplayList(gDisplayListHead++, dl_draw_triangle); gSPPopMatrix(gDisplayListHead++, G_MTX_MODELVIEW); @@ -2145,7 +2447,7 @@ void shade_screen(void) { } void print_animated_red_coin(s16 x, s16 y) { - s32 globalTimer = gGlobalTimer; + u32 globalTimer = gGlobalTimer; create_dl_translation_matrix(MENU_MTX_PUSH, x, y, 0); create_dl_scale_matrix(MENU_MTX_NOPUSH, 0.2f, 0.2f, 1.0f); @@ -2189,25 +2491,35 @@ u8 gTextCourse[][7] = { #if defined(VERSION_JP) || defined(VERSION_SH) #define CRS_NUM_X1 93 -#elif defined(VERSION_US) +#elif defined(VERSION_US) || defined(VERSION_CN) #define CRS_NUM_X1 100 #elif defined(VERSION_EU) #define CRS_NUM_X1 get_string_width(LANGUAGE_ARRAY(textCourse)) + 51 #endif -#ifdef VERSION_EU +#if defined(VERSION_EU) #define TXT_COURSE_X 48 #define TXT_STAR_X 89 #define ACT_NAME_X 107 - #define LVL_NAME_X 108 - #define SECRET_LVL_NAME_X get_str_x_pos_from_center(159, &courseName[3], 10.0f) + #define CRS_NAME_START 3 + #define CRS_NAME_X 108 + #define SECRET_CRS_NAME_X get_str_x_pos_from_center(159, &courseName[CRS_NAME_START], 10.0f) #define MYSCORE_X 48 +#elif defined(VERSION_CN) + #define TXT_COURSE_X 63 + #define TXT_STAR_X 98 + #define ACT_NAME_X 112 + #define CRS_NAME_START 6 + #define CRS_NAME_X 117 + #define SECRET_CRS_NAME_X 94 + #define MYSCORE_X 42 #else #define TXT_COURSE_X 63 #define TXT_STAR_X 98 #define ACT_NAME_X 116 - #define LVL_NAME_X 117 - #define SECRET_LVL_NAME_X 94 + #define CRS_NAME_START 3 + #define CRS_NAME_X 117 + #define SECRET_CRS_NAME_X 94 #define MYSCORE_X 62 #endif @@ -2222,7 +2534,7 @@ void render_pause_my_score_coins(void) { u8 textCourse[] = { TEXT_COURSE }; u8 textMyScore[] = { TEXT_MY_SCORE }; #endif - u8 textStar[] = { TEXT_STAR }; + u8 textStar[] = { TEXT_STAR_DIFF }; u8 textUnfilledStar[] = { TEXT_UNFILLED_STAR }; u8 strCourseNum[4]; @@ -2259,7 +2571,7 @@ void render_pause_my_score_coins(void) { #endif gSPDisplayList(gDisplayListHead++, dl_rgba16_text_begin); - gDPSetEnvColor(gDisplayListHead++, 255, 255, 255, gDialogTextAlpha); + gDPSetEnvColor(gDisplayListHead++, 255, 255, 255, gMenuTextAlpha); if (courseIndex <= COURSE_NUM_TO_INDEX(COURSE_STAGES_MAX)) { print_hud_my_score_coins(1, gCurrSaveFileNum - 1, courseIndex, 178, 103); @@ -2269,7 +2581,7 @@ void render_pause_my_score_coins(void) { gSPDisplayList(gDisplayListHead++, dl_rgba16_text_end); gSPDisplayList(gDisplayListHead++, dl_ia_text_begin); - gDPSetEnvColor(gDisplayListHead++, 255, 255, 255, gDialogTextAlpha); + gDPSetEnvColor(gDisplayListHead++, 255, 255, 255, gMenuTextAlpha); if (courseIndex <= COURSE_NUM_TO_INDEX(COURSE_STAGES_MAX) && save_file_get_course_star_count(gCurrSaveFileNum - 1, courseIndex) != 0) { @@ -2280,7 +2592,7 @@ void render_pause_my_score_coins(void) { if (courseIndex <= COURSE_NUM_TO_INDEX(COURSE_STAGES_MAX)) { print_generic_string(TXT_COURSE_X, 157, LANGUAGE_ARRAY(textCourse)); - int_to_str(gCurrCourseNum, strCourseNum); + INT_TO_STR_DIFF(gCurrCourseNum, strCourseNum); print_generic_string(CRS_NUM_X1, 157, strCourseNum); actName = segmented_to_virtual(actNameTbl[COURSE_NUM_TO_INDEX(gCurrCourseNum) * 6 + gDialogCourseActNum - 1]); @@ -2293,14 +2605,14 @@ void render_pause_my_score_coins(void) { print_generic_string(ACT_NAME_X, 140, actName); #ifndef VERSION_JP - print_generic_string(LVL_NAME_X, 157, &courseName[3]); + print_generic_string(CRS_NAME_X, 157, &courseName[CRS_NAME_START]); } else { - print_generic_string(SECRET_LVL_NAME_X, 157, &courseName[3]); + print_generic_string(SECRET_CRS_NAME_X, 157, &courseName[CRS_NAME_START]); #endif } #ifdef VERSION_JP - print_generic_string(LVL_NAME_X, 157, &courseName[3]); + print_generic_string(CRS_NAME_X, 157, &courseName[CRS_NAME_START]); #endif gSPDisplayList(gDisplayListHead++, dl_ia_text_end); @@ -2317,8 +2629,8 @@ void render_pause_my_score_coins(void) { #endif void render_pause_camera_options(s16 x, s16 y, s8 *index, s16 xIndex) { - u8 textLakituMario[] = { TEXT_LAKITU_MARIO }; - u8 textLakituStop[] = { TEXT_LAKITU_STOP }; + UNUSED_CN u8 textLakituMario[] = { TEXT_LAKITU_MARIO }; + UNUSED_CN u8 textLakituStop[] = { TEXT_LAKITU_STOP }; #ifdef VERSION_EU u8 textNormalUpClose[][20] = { { TEXT_NORMAL_UPCLOSE }, @@ -2338,16 +2650,21 @@ void render_pause_camera_options(s16 x, s16 y, s8 *index, s16 xIndex) { handle_menu_scrolling(MENU_SCROLL_HORIZONTAL, index, 1, 2); gSPDisplayList(gDisplayListHead++, dl_ia_text_begin); - gDPSetEnvColor(gDisplayListHead++, 255, 255, 255, gDialogTextAlpha); + gDPSetEnvColor(gDisplayListHead++, 255, 255, 255, gMenuTextAlpha); +#ifdef VERSION_CN + print_generic_string(x + 14, y + 2, textNormalUpClose); + print_generic_string(x + 124, y + 2, textNormalFixed); +#else print_generic_string(x + 14, y + 2, textLakituMario); print_generic_string(x + TXT1_X, y - 13, LANGUAGE_ARRAY(textNormalUpClose)); print_generic_string(x + 124, y + 2, textLakituStop); print_generic_string(x + TXT2_X, y - 13, LANGUAGE_ARRAY(textNormalFixed)); +#endif gSPDisplayList(gDisplayListHead++, dl_ia_text_end); - create_dl_translation_matrix(MENU_MTX_PUSH, ((*index - 1) * xIndex) + x, y + Y_VAL7, 0); - gDPSetEnvColor(gDisplayListHead++, 255, 255, 255, gDialogTextAlpha); + create_dl_translation_matrix(MENU_MTX_PUSH, x + ((*index - 1) * xIndex), y + Y_VAL7, 0); + gDPSetEnvColor(gDisplayListHead++, 255, 255, 255, gMenuTextAlpha); gSPDisplayList(gDisplayListHead++, dl_draw_triangle); gSPPopMatrix(gDisplayListHead++, G_MTX_MODELVIEW); @@ -2364,9 +2681,18 @@ void render_pause_camera_options(s16 x, s16 y, s8 *index, s16 xIndex) { #if defined(VERSION_JP) || defined(VERSION_SH) #define X_VAL8 0 #define Y_VAL8 4 -#else + #define Y_OFFSET1 17 + #define Y_OFFSET2 33 +#elif defined(VERSION_US) || defined(VERSION_EU) #define X_VAL8 4 #define Y_VAL8 2 + #define Y_OFFSET1 17 + #define Y_OFFSET2 33 +#elif defined(VERSION_CN) + #define X_VAL8 4 + #define Y_VAL8 2 + #define Y_OFFSET1 20 + #define Y_OFFSET2 38 #endif void render_pause_course_options(s16 x, s16 y, s8 *index, s16 yIndex) { @@ -2395,18 +2721,18 @@ void render_pause_course_options(s16 x, s16 y, s8 *index, s16 yIndex) { handle_menu_scrolling(MENU_SCROLL_VERTICAL, index, 1, 3); gSPDisplayList(gDisplayListHead++, dl_ia_text_begin); - gDPSetEnvColor(gDisplayListHead++, 255, 255, 255, gDialogTextAlpha); + gDPSetEnvColor(gDisplayListHead++, 255, 255, 255, gMenuTextAlpha); print_generic_string(x + 10, y - 2, LANGUAGE_ARRAY(textContinue)); - print_generic_string(x + 10, y - 17, LANGUAGE_ARRAY(textExitCourse)); + print_generic_string(x + 10, y - Y_OFFSET1, LANGUAGE_ARRAY(textExitCourse)); if (*index != MENU_OPT_CAMERA_ANGLE_R) { - print_generic_string(x + 10, y - 33, LANGUAGE_ARRAY(textCameraAngleR)); + print_generic_string(x + 10, y - Y_OFFSET2, LANGUAGE_ARRAY(textCameraAngleR)); gSPDisplayList(gDisplayListHead++, dl_ia_text_end); create_dl_translation_matrix(MENU_MTX_PUSH, x - X_VAL8, (y - ((*index - 1) * yIndex)) - Y_VAL8, 0); - gDPSetEnvColor(gDisplayListHead++, 255, 255, 255, gDialogTextAlpha); + gDPSetEnvColor(gDisplayListHead++, 255, 255, 255, gMenuTextAlpha); gSPDisplayList(gDisplayListHead++, dl_draw_triangle); gSPPopMatrix(gDisplayListHead++, G_MTX_MODELVIEW); } @@ -2424,8 +2750,8 @@ void render_pause_castle_menu_box(s16 x, s16 y) { gSPPopMatrix(gDisplayListHead++, G_MTX_MODELVIEW); create_dl_translation_matrix(MENU_MTX_PUSH, x + 6, y - 28, 0); - create_dl_rotation_matrix(MENU_MTX_NOPUSH, DEFAULT_DIALOG_BOX_ANGLE, 0, 0, 1.0f); - gDPSetEnvColor(gDisplayListHead++, 255, 255, 255, gDialogTextAlpha); + create_dl_rotation_matrix(MENU_MTX_NOPUSH, 90.0f, 0, 0, 1.0f); + gDPSetEnvColor(gDisplayListHead++, 255, 255, 255, gMenuTextAlpha); gSPDisplayList(gDisplayListHead++, dl_draw_triangle); gSPPopMatrix(gDisplayListHead++, G_MTX_MODELVIEW); @@ -2436,23 +2762,25 @@ void render_pause_castle_menu_box(s16 x, s16 y) { } void highlight_last_course_complete_stars(void) { - u8 doneCourseIndex; + u8 completedCourseIndex; if (gLastCompletedCourseNum == COURSE_NONE) { - doneCourseIndex = 0; + completedCourseIndex = 0; } else { - doneCourseIndex = COURSE_NUM_TO_INDEX(gLastCompletedCourseNum); + completedCourseIndex = COURSE_NUM_TO_INDEX(gLastCompletedCourseNum); - if (doneCourseIndex >= COURSE_NUM_TO_INDEX(COURSE_BONUS_STAGES)) { - doneCourseIndex = COURSE_NUM_TO_INDEX(COURSE_BONUS_STAGES); + if (completedCourseIndex >= COURSE_NUM_TO_INDEX(COURSE_BONUS_STAGES)) { + completedCourseIndex = COURSE_NUM_TO_INDEX(COURSE_BONUS_STAGES); } } - gDialogLineNum = doneCourseIndex; + gMenuLineNum = completedCourseIndex; } -#ifdef VERSION_EU +#if defined(VERSION_EU) #define PAUSE_X get_str_x_pos_from_center_scale(SCREEN_WIDTH / 2, textPause, 12.0f) +#elif defined(VERSION_CN) + #define PAUSE_X 113 #else #define PAUSE_X 123 #endif @@ -2461,7 +2789,7 @@ void print_hud_pause_colorful_str(void) { u8 textPause[] = { TEXT_PAUSE }; gSPDisplayList(gDisplayListHead++, dl_rgba16_text_begin); - gDPSetEnvColor(gDisplayListHead++, 255, 255, 255, gDialogTextAlpha); + gDPSetEnvColor(gDisplayListHead++, 255, 255, 255, gMenuTextAlpha); print_hud_lut_string(HUD_LUT_GLOBAL, PAUSE_X, 81, textPause); @@ -2471,7 +2799,11 @@ void print_hud_pause_colorful_str(void) { void render_pause_castle_course_stars(s16 x, s16 y, s16 fileIndex, s16 courseIndex) { s16 hasStar = 0; - u8 str[COURSE_STAGES_COUNT * 2]; +#ifdef VERSION_CN + u8 str[60]; +#else + u8 str[30]; +#endif u8 textStar[] = { TEXT_STAR }; @@ -2487,23 +2819,50 @@ void render_pause_castle_course_stars(s16 x, s16 y, s16 fileIndex, s16 courseInd while (hasStar != starCount) { if (starFlags & (1 << nextStar)) { +#ifdef VERSION_CN + str[nextStar * 4] = 0x00; + str[nextStar * 4 + 1] = DIALOG_CHAR_STAR_FILLED; +#else str[nextStar * 2] = DIALOG_CHAR_STAR_FILLED; +#endif hasStar++; } else { +#ifdef VERSION_CN + str[nextStar * 4] = 0x00; + str[nextStar * 4 + 1] = DIALOG_CHAR_STAR_OPEN; +#else str[nextStar * 2] = DIALOG_CHAR_STAR_OPEN; +#endif } +#ifdef VERSION_CN + str[nextStar * 4 + 2] = DIALOG_CHAR_SPECIAL_MODIFIER; + str[nextStar * 4 + 3] = DIALOG_CHAR_SPACE; +#else str[nextStar * 2 + 1] = DIALOG_CHAR_SPACE; +#endif nextStar++; } if (starCount == nextStar && starCount != 6) { +#ifdef VERSION_CN + str[nextStar * 4] = DIALOG_CHAR_SPECIAL_MODIFIER; + str[nextStar * 4 + 1] = DIALOG_CHAR_SLASH; //! Meant to be DIALOG_CHAR_STAR_OPEN? + str[nextStar * 4 + 2] = DIALOG_CHAR_SPECIAL_MODIFIER; + str[nextStar * 4 + 3] = DIALOG_CHAR_SPACE; +#else str[nextStar * 2] = DIALOG_CHAR_STAR_OPEN; str[nextStar * 2 + 1] = DIALOG_CHAR_SPACE; +#endif nextStar++; } +#ifdef VERSION_CN + str[nextStar * 4] = DIALOG_CHAR_SPECIAL_MODIFIER; + str[nextStar * 4 + 1] = DIALOG_CHAR_TERMINATOR; +#else str[nextStar * 2] = DIALOG_CHAR_TERMINATOR; +#endif print_generic_string(x + 14, y + 13, str); } @@ -2525,7 +2884,7 @@ void render_pause_castle_main_strings(s16 x, s16 y) { void *courseName; u8 strVal[8]; - s16 prevCourseIndex = gDialogLineNum; + s16 prevCourseIndex = gMenuLineNum; #ifdef VERSION_EU switch (gInGameLanguage) { @@ -2542,45 +2901,45 @@ void render_pause_castle_main_strings(s16 x, s16 y) { #endif handle_menu_scrolling( - MENU_SCROLL_VERTICAL, &gDialogLineNum, + MENU_SCROLL_VERTICAL, &gMenuLineNum, COURSE_NUM_TO_INDEX(COURSE_MIN) - 1, COURSE_NUM_TO_INDEX(COURSE_BONUS_STAGES) + 1 ); - if (gDialogLineNum == COURSE_NUM_TO_INDEX(COURSE_BONUS_STAGES) + 1) { - gDialogLineNum = COURSE_NUM_TO_INDEX(COURSE_MIN); // Exceeded max, set to min + if (gMenuLineNum == COURSE_NUM_TO_INDEX(COURSE_BONUS_STAGES) + 1) { + gMenuLineNum = COURSE_NUM_TO_INDEX(COURSE_MIN); // Exceeded max, set to min } - if (gDialogLineNum == COURSE_NUM_TO_INDEX(COURSE_MIN) - 1) { - gDialogLineNum = COURSE_NUM_TO_INDEX(COURSE_BONUS_STAGES); // Exceeded min, set to max + if (gMenuLineNum == COURSE_NUM_TO_INDEX(COURSE_MIN) - 1) { + gMenuLineNum = COURSE_NUM_TO_INDEX(COURSE_BONUS_STAGES); // Exceeded min, set to max } - if (gDialogLineNum != COURSE_NUM_TO_INDEX(COURSE_BONUS_STAGES)) { - while (save_file_get_course_star_count(gCurrSaveFileNum - 1, gDialogLineNum) == 0) { - if (gDialogLineNum >= prevCourseIndex) { - gDialogLineNum++; + if (gMenuLineNum != COURSE_NUM_TO_INDEX(COURSE_BONUS_STAGES)) { + while (save_file_get_course_star_count(gCurrSaveFileNum - 1, gMenuLineNum) == 0) { + if (gMenuLineNum >= prevCourseIndex) { + gMenuLineNum++; } else { - gDialogLineNum--; + gMenuLineNum--; } - if (gDialogLineNum == COURSE_NUM_TO_INDEX(COURSE_STAGES_MAX) + 1 - || gDialogLineNum == COURSE_NUM_TO_INDEX(COURSE_MIN) - 1) { - gDialogLineNum = COURSE_NUM_TO_INDEX(COURSE_BONUS_STAGES); + if (gMenuLineNum == COURSE_NUM_TO_INDEX(COURSE_STAGES_MAX) + 1 + || gMenuLineNum == COURSE_NUM_TO_INDEX(COURSE_MIN) - 1) { + gMenuLineNum = COURSE_NUM_TO_INDEX(COURSE_BONUS_STAGES); break; } } } gSPDisplayList(gDisplayListHead++, dl_ia_text_begin); - gDPSetEnvColor(gDisplayListHead++, 255, 255, 255, gDialogTextAlpha); + gDPSetEnvColor(gDisplayListHead++, 255, 255, 255, gMenuTextAlpha); - if (gDialogLineNum <= COURSE_NUM_TO_INDEX(COURSE_STAGES_MAX)) { // Main courses - courseName = segmented_to_virtual(courseNameTbl[gDialogLineNum]); - render_pause_castle_course_stars(x, y, gCurrSaveFileNum - 1, gDialogLineNum); + if (gMenuLineNum <= COURSE_NUM_TO_INDEX(COURSE_STAGES_MAX)) { // Main courses + courseName = segmented_to_virtual(courseNameTbl[gMenuLineNum]); + render_pause_castle_course_stars(x, y, gCurrSaveFileNum - 1, gMenuLineNum); print_generic_string(x + 34, y - 5, textCoin); #ifdef VERSION_EU print_generic_string(x + 44, y - 5, textX); #endif - int_to_str(save_file_get_course_coin_score(gCurrSaveFileNum - 1, gDialogLineNum), strVal); + INT_TO_STR_DIFF(save_file_get_course_coin_score(gCurrSaveFileNum - 1, gMenuLineNum), strVal); print_generic_string(x + 54, y - 5, strVal); #ifdef VERSION_EU print_generic_string(x - 17, y + 30, courseName); @@ -2589,7 +2948,7 @@ void render_pause_castle_main_strings(s16 x, s16 y) { u8 textStarX[] = { TEXT_STAR_X }; courseName = segmented_to_virtual(courseNameTbl[COURSE_MAX]); print_generic_string(x + 40, y + 13, textStarX); - int_to_str(save_file_get_total_star_count(gCurrSaveFileNum - 1, COURSE_BONUS_STAGES - 1, COURSE_MAX - 1), strVal); + INT_TO_STR_DIFF(save_file_get_total_star_count(gCurrSaveFileNum - 1, COURSE_BONUS_STAGES - 1, COURSE_MAX - 1), strVal); print_generic_string(x + 60, y + 13, strVal); #ifdef VERSION_EU print_generic_string(get_str_x_pos_from_center(x + 51, courseName, 10.0f), y + 30, courseName); @@ -2604,56 +2963,56 @@ void render_pause_castle_main_strings(s16 x, s16 y) { } s8 gCourseCompleteCoinsEqual = FALSE; -s32 gCourseDoneMenuTimer = 0; +s32 gCourseCompleteScreenTimer = 0; s32 gCourseCompleteCoins = 0; s8 gHudFlash = 0; -s16 render_pause_courses_and_castle(void) { +s16 render_pause_screen(void) { s16 index; #ifdef VERSION_EU gInGameLanguage = eu_get_language(); #endif - switch (gDialogBoxState) { - case DIALOG_STATE_OPENING: - gDialogLineNum = MENU_OPT_DEFAULT; - gDialogTextAlpha = 0; + switch (gMenuState) { + case MENU_STATE_PAUSE_SCREEN_OPENING: + gMenuLineNum = MENU_OPT_DEFAULT; + gMenuTextAlpha = 0; level_set_transition(-1, NULL); play_sound(SOUND_MENU_PAUSE, gGlobalSoundSource); if (gCurrCourseNum >= COURSE_MIN && gCurrCourseNum <= COURSE_MAX) { change_dialog_camera_angle(); - gDialogBoxState = DIALOG_STATE_VERTICAL; + gMenuState = MENU_STATE_PAUSE_SCREEN_COURSE; } else { highlight_last_course_complete_stars(); - gDialogBoxState = DIALOG_STATE_HORIZONTAL; + gMenuState = MENU_STATE_PAUSE_SCREEN_CASTLE; } break; - case DIALOG_STATE_VERTICAL: + case MENU_STATE_PAUSE_SCREEN_COURSE: shade_screen(); render_pause_my_score_coins(); render_pause_red_coins(); if (gMarioStates[0].action & ACT_FLAG_PAUSE_EXIT) { - render_pause_course_options(99, 93, &gDialogLineNum, 15); + render_pause_course_options(99, 93, &gMenuLineNum, 15); } #ifdef VERSION_EU - if (gPlayer3Controller->buttonPressed & (A_BUTTON | Z_TRIG | START_BUTTON)) + if (gPlayer3Controller->buttonPressed & (A_BUTTON | START_BUTTON | Z_TRIG)) #else - if (gPlayer3Controller->buttonPressed & A_BUTTON - || gPlayer3Controller->buttonPressed & START_BUTTON) + if ((gPlayer3Controller->buttonPressed & A_BUTTON) + || (gPlayer3Controller->buttonPressed & START_BUTTON)) #endif { level_set_transition(0, NULL); play_sound(SOUND_MENU_PAUSE_2, gGlobalSoundSource); - gDialogBoxState = DIALOG_STATE_OPENING; + gMenuState = MENU_STATE_DEFAULT; gMenuMode = MENU_MODE_NONE; - if (gDialogLineNum == MENU_OPT_EXIT_COURSE) { - index = gDialogLineNum; + if (gMenuLineNum == MENU_OPT_EXIT_COURSE) { + index = gMenuLineNum; } else { // MENU_OPT_CONTINUE or MENU_OPT_CAMERA_ANGLE_R index = MENU_OPT_DEFAULT; } @@ -2662,31 +3021,31 @@ s16 render_pause_courses_and_castle(void) { } break; - case DIALOG_STATE_HORIZONTAL: + case MENU_STATE_PAUSE_SCREEN_CASTLE: shade_screen(); print_hud_pause_colorful_str(); render_pause_castle_menu_box(160, 143); render_pause_castle_main_strings(104, 60); #ifdef VERSION_EU - if (gPlayer3Controller->buttonPressed & (A_BUTTON | Z_TRIG | START_BUTTON)) + if (gPlayer3Controller->buttonPressed & (A_BUTTON | START_BUTTON | Z_TRIG)) #else - if (gPlayer3Controller->buttonPressed & A_BUTTON - || gPlayer3Controller->buttonPressed & START_BUTTON) + if ((gPlayer3Controller->buttonPressed & A_BUTTON) + || (gPlayer3Controller->buttonPressed & START_BUTTON)) #endif { level_set_transition(0, NULL); play_sound(SOUND_MENU_PAUSE_2, gGlobalSoundSource); gMenuMode = MENU_MODE_NONE; - gDialogBoxState = DIALOG_STATE_OPENING; + gMenuState = MENU_STATE_DEFAULT; return MENU_OPT_DEFAULT; } break; } - if (gDialogTextAlpha < 250) { - gDialogTextAlpha += 25; + if (gMenuTextAlpha < 250) { + gMenuTextAlpha += 25; } return MENU_OPT_NONE; @@ -2696,18 +3055,27 @@ s16 render_pause_courses_and_castle(void) { #define TXT_HISCORE_X 112 #define TXT_HISCORE_Y 48 #define TXT_CONGRATS_X 60 + #define TXT_CONGRATS_Y 67 #elif defined(VERSION_US) #define TXT_HISCORE_X 109 #define TXT_HISCORE_Y 36 #define TXT_CONGRATS_X 70 + #define TXT_CONGRATS_Y 67 #elif defined(VERSION_EU) #define TXT_HISCORE_X get_str_x_pos_from_center_scale(160, LANGUAGE_ARRAY(textHiScore), 12.0f) #define TXT_HISCORE_Y 36 #define TXT_CONGRATS_X get_str_x_pos_from_center_scale(160, LANGUAGE_ARRAY(textCongratulations), 12.0f) + #define TXT_CONGRATS_Y 67 #elif defined(VERSION_SH) #define TXT_HISCORE_X 118 #define TXT_HISCORE_Y 48 #define TXT_CONGRATS_X 70 + #define TXT_CONGRATS_Y 67 +#elif defined(VERSION_CN) + #define TXT_HISCORE_X 109 + #define TXT_HISCORE_Y 26 + #define TXT_CONGRATS_X 100 + #define TXT_CONGRATS_Y 62 #endif #define HUD_PRINT_HISCORE 0 @@ -2730,15 +3098,15 @@ void print_hud_course_complete_string(s8 str) { u8 textCongratulations[] = { TEXT_HUD_CONGRATULATIONS }; #endif - u8 colorFade = sins(gDialogColorFadeTimer) * 50.0f + 200.0f; + u8 color = sins(gMenuTextColorTransTimer) * 50.0f + 200.0f; gSPDisplayList(gDisplayListHead++, dl_rgba16_text_begin); - gDPSetEnvColor(gDisplayListHead++, colorFade, colorFade, colorFade, 255); + gDPSetEnvColor(gDisplayListHead++, color, color, color, 255); if (str == HUD_PRINT_HISCORE) { print_hud_lut_string(HUD_LUT_GLOBAL, TXT_HISCORE_X, TXT_HISCORE_Y, LANGUAGE_ARRAY(textHiScore)); } else { // HUD_PRINT_CONGRATULATIONS - print_hud_lut_string(HUD_LUT_GLOBAL, TXT_CONGRATS_X, 67, LANGUAGE_ARRAY(textCongratulations)); + print_hud_lut_string(HUD_LUT_GLOBAL, TXT_CONGRATS_X, TXT_CONGRATS_Y, LANGUAGE_ARRAY(textCongratulations)); } gSPDisplayList(gDisplayListHead++, dl_rgba16_text_end); @@ -2768,7 +3136,7 @@ void print_hud_course_complete_coins(s16 x, s16 y) { print_hud_course_complete_string(HUD_PRINT_HISCORE); } } else { - if ((gCourseDoneMenuTimer & 1) || gHudDisplay.coins > 70) { + if ((gCourseCompleteScreenTimer & 1) || gHudDisplay.coins > 70) { gCourseCompleteCoins++; play_sound(SOUND_MENU_YOSHI_GAIN_LIVES, gGlobalSoundSource); @@ -2778,14 +3146,14 @@ void print_hud_course_complete_coins(s16 x, s16 y) { } } - if (gHudDisplay.coins == gCourseCompleteCoins && gGotFileCoinHiScore) { + if (gCourseCompleteCoins == gHudDisplay.coins && gGotFileCoinHiScore) { play_sound(SOUND_MENU_MARIO_CASTLE_WARP2, gGlobalSoundSource); } } } -void play_star_fanfare_and_flash_hud(s32 arg, u8 starNum) { - if (gHudDisplay.coins == gCourseCompleteCoins && (gCurrCourseStarFlags & starNum) == 0 && gHudFlash == 0) { +void play_star_fanfare_and_flash_hud(s32 arg, u8 starFlag) { + if (gCourseCompleteCoins == gHudDisplay.coins && !(gCurrCourseStarFlags & starFlag) && gHudFlash == 0) { play_star_fanfare(); gHudFlash = arg; } @@ -2822,8 +3190,8 @@ void render_course_complete_lvl_info_and_hud_str(void) { u8 textSymStar[] = { GLYPH_STAR, GLYPH_SPACE }; #else u8 textCourse[] = { TEXT_COURSE }; - UNUSED u8 textCatch[] = { TEXT_CATCH }; // unused in US - UNUSED u8 textClear[] = { TEXT_CLEAR }; + UNUSED u8 textCatch[] = { TEXT_CATCH }; // unused in US and iQue + u8 textClear[] = { TEXT_CLEAR }; u8 textSymStar[] = { GLYPH_STAR, GLYPH_SPACE }; #endif @@ -2867,13 +3235,13 @@ void render_course_complete_lvl_info_and_hud_str(void) { // Print course number gSPDisplayList(gDisplayListHead++, dl_ia_text_begin); - int_to_str(gLastCompletedCourseNum, strCourseNum); + INT_TO_STR_DIFF(gLastCompletedCourseNum, strCourseNum); - gDPSetEnvColor(gDisplayListHead++, 0, 0, 0, gDialogTextAlpha); + gDPSetEnvColor(gDisplayListHead++, 0, 0, 0, gMenuTextAlpha); print_generic_string(65, 165, LANGUAGE_ARRAY(textCourse)); print_generic_string(CRS_NUM_X2, 165, strCourseNum); - gDPSetEnvColor(gDisplayListHead++, 255, 255, 255, gDialogTextAlpha); + gDPSetEnvColor(gDisplayListHead++, 255, 255, 255, gMenuTextAlpha); print_generic_string(63, 167, LANGUAGE_ARRAY(textCourse)); print_generic_string(CRS_NUM_X3, 167, strCourseNum); @@ -2884,7 +3252,7 @@ void render_course_complete_lvl_info_and_hud_str(void) { // Print course name and clear text gSPDisplayList(gDisplayListHead++, dl_ia_text_begin); - gDPSetEnvColor(gDisplayListHead++, 0, 0, 0, gDialogTextAlpha); + gDPSetEnvColor(gDisplayListHead++, 0, 0, 0, gMenuTextAlpha); #ifdef VERSION_EU centerX = get_str_x_pos_from_center(153, name, 12.0f); #endif @@ -2893,7 +3261,7 @@ void render_course_complete_lvl_info_and_hud_str(void) { print_generic_string(TXT_CLEAR_X1, 130, textClear); #endif - gDPSetEnvColor(gDisplayListHead++, 255, 255, 255, gDialogTextAlpha); + gDPSetEnvColor(gDisplayListHead++, 255, 255, 255, gMenuTextAlpha); print_generic_string(TXT_NAME_X2, 132, name); #ifndef VERSION_EU print_generic_string(TXT_CLEAR_X2, 132, textClear); @@ -2916,7 +3284,7 @@ void render_course_complete_lvl_info_and_hud_str(void) { // Print star glyph gSPDisplayList(gDisplayListHead++, dl_rgba16_text_begin); - gDPSetEnvColor(gDisplayListHead++, 255, 255, 255, gDialogTextAlpha); + gDPSetEnvColor(gDisplayListHead++, 255, 255, 255, gMenuTextAlpha); print_hud_lut_string(HUD_LUT_GLOBAL, 55, 77, textSymStar); gSPDisplayList(gDisplayListHead++, dl_rgba16_text_end); @@ -2924,13 +3292,13 @@ void render_course_complete_lvl_info_and_hud_str(void) { // Print act name and catch text gSPDisplayList(gDisplayListHead++, dl_ia_text_begin); - gDPSetEnvColor(gDisplayListHead++, 0, 0, 0, gDialogTextAlpha); + gDPSetEnvColor(gDisplayListHead++, 0, 0, 0, gMenuTextAlpha); print_generic_string(76, 145, name); #if defined(VERSION_JP) || defined(VERSION_SH) print_generic_string(220, 145, textCatch); #endif - gDPSetEnvColor(gDisplayListHead++, 255, 255, 255, gDialogTextAlpha); + gDPSetEnvColor(gDisplayListHead++, 255, 255, 255, gMenuTextAlpha); print_generic_string(74, 147, name); #if defined(VERSION_JP) || defined(VERSION_SH) print_generic_string(218, 147, textCatch); @@ -2959,9 +3327,9 @@ void render_course_complete_lvl_info_and_hud_str(void) { #endif #ifdef VERSION_EU -void render_save_confirmation(s16 y, s8 *index, s16 sp6e) +void render_save_confirmation(s16 y, s8 *index, s16 yOffset) #else -void render_save_confirmation(s16 x, s16 y, s8 *index, s16 sp6e) +void render_save_confirmation(s16 x, s16 y, s8 *index, s16 yOffset) #endif { #ifdef VERSION_EU @@ -2990,7 +3358,7 @@ void render_save_confirmation(s16 x, s16 y, s8 *index, s16 sp6e) handle_menu_scrolling(MENU_SCROLL_VERTICAL, index, 1, 3); gSPDisplayList(gDisplayListHead++, dl_ia_text_begin); - gDPSetEnvColor(gDisplayListHead++, 255, 255, 255, gDialogTextAlpha); + gDPSetEnvColor(gDisplayListHead++, 255, 255, 255, gMenuTextAlpha); print_generic_string(TXT_SAVEOPTIONS_X, y + TXT_SAVECONT_Y, LANGUAGE_ARRAY(textSaveAndContinue)); print_generic_string(TXT_SAVEOPTIONS_X, y - TXT_SAVEQUIT_Y, LANGUAGE_ARRAY(textSaveAndQuit)); @@ -2998,9 +3366,9 @@ void render_save_confirmation(s16 x, s16 y, s8 *index, s16 sp6e) gSPDisplayList(gDisplayListHead++, dl_ia_text_end); - create_dl_translation_matrix(MENU_MTX_PUSH, X_VAL9, y - ((*index - 1) * sp6e), 0); + create_dl_translation_matrix(MENU_MTX_PUSH, X_VAL9, y - ((*index - 1) * yOffset), 0); - gDPSetEnvColor(gDisplayListHead++, 255, 255, 255, gDialogTextAlpha); + gDPSetEnvColor(gDisplayListHead++, 255, 255, 255, gMenuTextAlpha); gSPDisplayList(gDisplayListHead++, dl_draw_triangle); gSPPopMatrix(gDisplayListHead++, G_MTX_MODELVIEW); @@ -3012,39 +3380,39 @@ s16 render_course_complete_screen(void) { gInGameLanguage = eu_get_language(); #endif - switch (gDialogBoxState) { - case DIALOG_STATE_OPENING: + switch (gMenuState) { + case MENU_STATE_COURSE_COMPLETE_SCREEN_OPENING: render_course_complete_lvl_info_and_hud_str(); - if (gCourseDoneMenuTimer > 100 && gCourseCompleteCoinsEqual == TRUE) { - gDialogBoxState = DIALOG_STATE_VERTICAL; + if (gCourseCompleteScreenTimer > 100 && gCourseCompleteCoinsEqual == TRUE) { + gMenuState = MENU_STATE_COURSE_COMPLETE_SCREEN_OPEN; level_set_transition(-1, NULL); - gDialogTextAlpha = 0; - gDialogLineNum = MENU_OPT_DEFAULT; + gMenuTextAlpha = 0; + gMenuLineNum = MENU_OPT_DEFAULT; } break; - case DIALOG_STATE_VERTICAL: + case MENU_STATE_COURSE_COMPLETE_SCREEN_OPEN: shade_screen(); render_course_complete_lvl_info_and_hud_str(); #ifdef VERSION_EU - render_save_confirmation(86, &gDialogLineNum, 20); + render_save_confirmation(86, &gMenuLineNum, 20); #else - render_save_confirmation(100, 86, &gDialogLineNum, 20); + render_save_confirmation(100, 86, &gMenuLineNum, 20); #endif - if (gCourseDoneMenuTimer > 110 - && (gPlayer3Controller->buttonPressed & A_BUTTON - || gPlayer3Controller->buttonPressed & START_BUTTON + if (gCourseCompleteScreenTimer > 110 + && ((gPlayer3Controller->buttonPressed & A_BUTTON) + || (gPlayer3Controller->buttonPressed & START_BUTTON) #ifdef VERSION_EU - || gPlayer3Controller->buttonPressed & Z_TRIG + || (gPlayer3Controller->buttonPressed & Z_TRIG) #endif )) { level_set_transition(0, NULL); play_sound(SOUND_MENU_STAR_SOUND, gGlobalSoundSource); - gDialogBoxState = DIALOG_STATE_OPENING; + gMenuState = MENU_STATE_DEFAULT; gMenuMode = MENU_MODE_NONE; - index = gDialogLineNum; - gCourseDoneMenuTimer = 0; + index = gMenuLineNum; + gCourseCompleteScreenTimer = 0; gCourseCompleteCoins = 0; gCourseCompleteCoinsEqual = FALSE; gHudFlash = 0; @@ -3054,11 +3422,11 @@ s16 render_course_complete_screen(void) { break; } - if (gDialogTextAlpha < 250) { - gDialogTextAlpha += 25; + if (gMenuTextAlpha < 250) { + gMenuTextAlpha += 25; } - gCourseDoneMenuTimer++; + gCourseCompleteScreenTimer++; return MENU_OPT_NONE; } @@ -3071,10 +3439,10 @@ s16 render_menus_and_dialogs(void) { if (gMenuMode != MENU_MODE_NONE) { switch (gMenuMode) { case MENU_MODE_UNUSED_0: - index = render_pause_courses_and_castle(); + index = render_pause_screen(); break; case MENU_MODE_RENDER_PAUSE_SCREEN: - index = render_pause_courses_and_castle(); + index = render_pause_screen(); break; case MENU_MODE_RENDER_COURSE_COMPLETE_SCREEN: index = render_course_complete_screen(); @@ -3084,7 +3452,7 @@ s16 render_menus_and_dialogs(void) { break; } - gDialogColorFadeTimer = (s16) gDialogColorFadeTimer + 0x1000; + gMenuTextColorTransTimer = (s16) gMenuTextColorTransTimer + 0x1000; } else if (gDialogID != DIALOG_NONE) { // The Peach "Dear Mario" message needs to be repositioned separately if (gDialogID == DIALOG_020) { @@ -3093,7 +3461,7 @@ s16 render_menus_and_dialogs(void) { } render_dialog_entries(); - gDialogColorFadeTimer = (s16) gDialogColorFadeTimer + 0x1000; + gMenuTextColorTransTimer = (s16) gMenuTextColorTransTimer + 0x1000; } return index; diff --git a/src/game/ingame_menu.h b/src/game/ingame_menu.h index d341855e..c875c7dc 100644 --- a/src/game/ingame_menu.h +++ b/src/game/ingame_menu.h @@ -27,6 +27,13 @@ #define HUD_LUT_DIFF HUD_LUT_GLOBAL #endif +// They didn't change it everywhere in iQue +#ifdef VERSION_CN +#define HUD_LUT_DIFF2 HUD_LUT_JPMENU +#else +#define HUD_LUT_DIFF2 HUD_LUT_DIFF +#endif + enum MenuMode { MENU_MODE_NONE = -1, MENU_MODE_UNUSED_0, @@ -47,7 +54,7 @@ struct DialogEntry { }; // EU only -enum HudSpecialHUDChars { +enum HudSpecialCharsEU { HUD_CHAR_A_UMLAUT = 0x3A, HUD_CHAR_O_UMLAUT = 0x3B, HUD_CHAR_U_UMLAUT = 0x3C @@ -55,7 +62,10 @@ enum HudSpecialHUDChars { enum SpecialFontChars { GLOBAL_CHAR_SPACE = 0x9E, - GLOBAR_CHAR_TERMINATOR = 0xFF +#ifdef VERSION_CN + GLOBAL_CHAR_NEWLINE = 0xFE, +#endif + GLOBAL_CHAR_TERMINATOR = 0xFF }; enum DialogMark { @@ -96,7 +106,7 @@ enum DialogSpecialChars { DIALOG_CHAR_I_NO_DIA = 0xEB, // 'i' without diacritic DIALOG_CHAR_DOUBLE_LOW_QUOTE = 0xF0, // German opening quotation mark #endif -#if defined(VERSION_US) || defined(VERSION_EU) +#if defined(VERSION_US) || defined(VERSION_EU) || defined(VERSION_CN) DIALOG_CHAR_SLASH = 0xD0, DIALOG_CHAR_MULTI_THE = 0xD1, // 'the' DIALOG_CHAR_MULTI_YOU = 0xD2, // 'you' @@ -115,6 +125,13 @@ enum DialogSpecialChars { DIALOG_CHAR_TERMINATOR = 0xFF }; +#ifdef VERSION_CN +#define DIALOG_CHAR_SPECIAL_MODIFIER 0xFF +#define SPECIAL_CHAR(x) (DIALOG_CHAR_SPECIAL_MODIFIER << 8 | (x)) +#else +#define SPECIAL_CHAR(x) (x) +#endif + // gDialogResponse enum DialogResponseDefines { DIALOG_RESPONSE_NONE, @@ -124,10 +141,10 @@ enum DialogResponseDefines { }; extern s32 gDialogResponse; -extern u16 gDialogColorFadeTimer; +extern u16 gMenuTextColorTransTimer; extern s8 gLastDialogLineNum; extern s32 gDialogVariable; -extern u16 gDialogTextAlpha; +extern u16 gMenuTextAlpha; extern s16 gCutsceneMsgXOffset; extern s16 gCutsceneMsgYOffset; extern s8 gRedCoinsCollected; @@ -135,11 +152,13 @@ extern s8 gRedCoinsCollected; void create_dl_identity_matrix(void); void create_dl_translation_matrix(s8 pushOp, f32 x, f32 y, f32 z); void create_dl_ortho_matrix(void); + void print_generic_string(s16 x, s16 y, const u8 *str); void print_hud_lut_string(s8 hudLUT, s16 x, s16 y, const u8 *str); void print_menu_generic_string(s16 x, s16 y, const u8 *str); + void handle_menu_scrolling(s8 scrollDirection, s8 *currentIndex, s8 minIndex, s8 maxIndex); -#if defined(VERSION_US) || defined(VERSION_EU) +#if defined(VERSION_US) || defined(VERSION_EU) || defined(VERSION_CN) s16 get_str_x_pos_from_center(s16 centerPos, u8 *str, f32 scale); #endif #if defined(VERSION_JP) || defined(VERSION_SH) @@ -149,7 +168,19 @@ s16 get_str_x_pos_from_center(s16 centerPos, u8 *str, f32 scale); s16 get_str_x_pos_from_center_scale(s16 centerPos, u8 *str, f32 scale); #endif void print_hud_my_score_coins(s32 useCourseCoinScore, s8 fileIndex, s8 courseIndex, s16 x, s16 y); + void int_to_str(s32 num, u8 *dst); + +#ifdef VERSION_CN +void int_to_str_2(s32 num, u8 *dst); +#endif + +#ifdef VERSION_CN +#define INT_TO_STR_DIFF int_to_str_2 +#else +#define INT_TO_STR_DIFF int_to_str +#endif + s16 get_dialog_id(void); void create_dialog_box(s16 dialog); void create_dialog_box_with_var(s16 dialog, s32 dialogVar); diff --git a/src/game/interaction.c b/src/game/interaction.c index c35d1b3e..ea6e4559 100644 --- a/src/game/interaction.c +++ b/src/game/interaction.c @@ -129,7 +129,7 @@ static u32 sBackwardKnockbackActions[][3] = { static u8 sDisplayingDoorText = FALSE; static u8 sJustTeleported = FALSE; -static u8 sPssSlideStarted = FALSE; +static u8 sPSSSlideStarted = FALSE; /** * Returns the type of cap Mario is wearing. @@ -746,10 +746,11 @@ u32 interact_coin(struct MarioState *m, UNUSED u32 interactType, struct Object * o->oInteractStatus = INT_STATUS_INTERACTED; - if (COURSE_IS_MAIN_COURSE(gCurrCourseNum) && m->numCoins - o->oDamageOrCoinValue < 100 - && m->numCoins >= 100) { - bhv_spawn_star_no_level_exit(6); + if (COURSE_IS_MAIN_COURSE(gCurrCourseNum) + && m->numCoins - o->oDamageOrCoinValue < 100 && m->numCoins >= 100) { + bhv_spawn_star_no_level_exit(STAR_INDEX_100_COINS); } + #if ENABLE_RUMBLE if (o->oDamageOrCoinValue >= 2) { queue_rumble_data(5, 80); @@ -807,7 +808,7 @@ u32 interact_star_or_key(struct MarioState *m, UNUSED u32 interactType, struct O m->interactObj = o; m->usedObj = o; - starIndex = (o->oBehParams >> 24) & 0x1F; + starIndex = (o->oBhvParams >> 24) & 0x1F; save_file_collect_star_or_key(m->numCoins, starIndex); m->numStars = @@ -902,7 +903,7 @@ u32 interact_warp(struct MarioState *m, UNUSED u32 interactType, struct Object * u32 interact_warp_door(struct MarioState *m, UNUSED u32 interactType, struct Object *o) { u32 doorAction = 0; u32 saveFlags = save_file_get_flags(); - s16 warpDoorId = o->oBehParams >> 24; + s16 warpDoorId = o->oBhvParams >> 24; u32 actionArg; if (m->action == ACT_WALKING || m->action == ACT_DECELERATING) { @@ -957,14 +958,14 @@ u32 interact_warp_door(struct MarioState *m, UNUSED u32 interactType, struct Obj u32 get_door_save_file_flag(struct Object *door) { u32 saveFileFlag = 0; - s16 requiredNumStars = door->oBehParams >> 24; + s16 requiredNumStars = door->oBhvParams >> 24; - s16 isCcmDoor = door->oPosX < 0.0f; - s16 isPssDoor = door->oPosY > 500.0f; + s16 isCCMDoor = door->oPosX < 0.0f; + s16 isPSSDoor = door->oPosY > 500.0f; switch (requiredNumStars) { case 1: - if (isPssDoor) { + if (isPSSDoor) { saveFileFlag = SAVE_FLAG_UNLOCKED_PSS_DOOR; } else { saveFileFlag = SAVE_FLAG_UNLOCKED_WF_DOOR; @@ -972,7 +973,7 @@ u32 get_door_save_file_flag(struct Object *door) { break; case 3: - if (isCcmDoor) { + if (isCCMDoor) { saveFileFlag = SAVE_FLAG_UNLOCKED_CCM_DOOR; } else { saveFileFlag = SAVE_FLAG_UNLOCKED_JRB_DOOR; @@ -996,7 +997,7 @@ u32 get_door_save_file_flag(struct Object *door) { } u32 interact_door(struct MarioState *m, UNUSED u32 interactType, struct Object *o) { - s16 requiredNumStars = o->oBehParams >> 24; + s16 requiredNumStars = o->oBhvParams >> 24; s16 numStars = save_file_get_total_star_count(gCurrSaveFileNum - 1, COURSE_MIN - 1, COURSE_MAX - 1); if (m->action == ACT_WALKING || m->action == ACT_DECELERATING) { @@ -1142,7 +1143,7 @@ u32 interact_strong_wind(struct MarioState *m, UNUSED u32 interactType, struct O m->usedObj = o; m->faceAngle[1] = o->oMoveAngleYaw + 0x8000; - m->unkC4 = 0.4f; + m->gettingBlownGravity = 0.4f; m->forwardVel = -24.0f; m->vel[1] = 12.0f; @@ -1510,7 +1511,7 @@ u32 interact_pole(struct MarioState *m, UNUSED u32 interactType, struct Object * s32 actionId = m->action & ACT_ID_MASK; if (actionId >= 0x080 && actionId < 0x0A0) { if (!(m->prevAction & ACT_FLAG_ON_POLE) || m->usedObj != o) { -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) f32 velConv = m->forwardVel; // conserve the velocity. struct Object *marioObj = m->marioObj; u32 lowSpeed; @@ -1521,7 +1522,7 @@ u32 interact_pole(struct MarioState *m, UNUSED u32 interactType, struct Object * mario_stop_riding_and_holding(m); -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) lowSpeed = (velConv <= 10.0f); #endif @@ -1540,7 +1541,7 @@ u32 interact_pole(struct MarioState *m, UNUSED u32 interactType, struct Object * //! @bug Using m->forwardVel here is assumed to be 0.0f due to the set from earlier. // This is fixed in the Shindou version. -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) marioObj->oMarioPoleYawVel = (s32)(velConv * 0x100 + 0x1000); #else marioObj->oMarioPoleYawVel = (s32)(m->forwardVel * 0x100 + 0x1000); @@ -1838,19 +1839,19 @@ void pss_begin_slide(UNUSED struct MarioState *m) { if (!(gHudDisplay.flags & HUD_DISPLAY_FLAG_TIMER)) { level_control_timer(TIMER_CONTROL_SHOW); level_control_timer(TIMER_CONTROL_START); - sPssSlideStarted = TRUE; + sPSSSlideStarted = TRUE; } } void pss_end_slide(struct MarioState *m) { //! This flag isn't set on death or level entry, allowing double star spawn - if (sPssSlideStarted) { + if (sPSSSlideStarted) { u16 slideTime = level_control_timer(TIMER_CONTROL_STOP); if (slideTime < 630) { - m->marioObj->oBehParams = (1 << 24); + m->marioObj->oBhvParams = (STAR_INDEX_ACT_2 << 24); spawn_default_star(-6358.0f, -4300.0f, 4700.0f); } - sPssSlideStarted = FALSE; + sPSSSlideStarted = FALSE; } } diff --git a/src/game/level_update.c b/src/game/level_update.c index 03d44077..a6186c38 100644 --- a/src/game/level_update.c +++ b/src/game/level_update.c @@ -40,23 +40,13 @@ #define WARP_TYPE_CHANGE_AREA 2 #define WARP_TYPE_SAME_AREA 3 -#define WARP_NODE_F0 0xF0 -#define WARP_NODE_DEATH 0xF1 -#define WARP_NODE_F2 0xF2 -#define WARP_NODE_WARP_FLOOR 0xF3 -#define WARP_NODE_CREDITS_START 0xF8 -#define WARP_NODE_CREDITS_NEXT 0xF9 -#define WARP_NODE_CREDITS_END 0xFA - -#define WARP_NODE_CREDITS_MIN 0xF8 - // TODO: Make these ifdefs better const char *credits01[] = { "1GAME DIRECTOR", "SHIGERU MIYAMOTO" }; const char *credits02[] = { "2ASSISTANT DIRECTORS", "YOSHIAKI KOIZUMI", "TAKASHI TEZUKA" }; const char *credits03[] = { "2SYSTEM PROGRAMMERS", "YASUNARI NISHIDA", "YOSHINORI TANIMOTO" }; const char *credits04[] = { "3PROGRAMMERS", "HAJIME YAJIMA", "DAIKI IWAMOTO", "TOSHIO IWAWAKI" }; -#if defined(VERSION_JP) || defined(VERSION_SH) +#if defined(VERSION_JP) || defined(VERSION_SH) || defined(VERSION_CN) const char *credits05[] = { "1CAMERA PROGRAMMER", "TAKUMI KAWAGOE" }; const char *credits06[] = { "1MARIO FACE PROGRAMMER", "GILES GODDARD" }; @@ -73,8 +63,8 @@ const char *credits14[] = { "1CG DESIGNER", "MASANAO ARIMOTO" }; const char *credits15[] = { "3TECHNICAL SUPPORT", "TAKAO SAWANO", "HIROHITO YOSHIMOTO", "HIROTO YADA" }; const char *credits16[] = { "1TECHNICAL SUPPORT", "SGI. 64PROJECT STAFF" }; const char *credits17[] = { "2PROGRESS MANAGEMENT", "KIMIYOSHI FUKUI", "KEIZO KATO" }; -#else // VERSION_SH -// Shindou combines sound effects and sound programmer in order to make room for Mario voice and Peach voice +#else // VERSION_SH || VERSION_CN +// Shindou and iQue combine sound effects and sound programmer in order to make room for Mario voice and Peach voice const char *credits11[] = { "4SOUND EFFECTS", "SOUND PROGRAMMER", "YOJI INAGAKI", "HIDEAKI SHIMIZU" }; const char *credits12[] = { "23D ANIMATORS", "YOSHIAKI KOIZUMI", "SATORU TAKIZAWA" }; const char *credits13[] = { "1CG DESIGNER", "MASANAO ARIMOTO" }; @@ -94,13 +84,13 @@ const char *credits08[] = { "3COURSE DESIGNERS", "YOSHIKI HARUHANA", "MAKOTO MIY #ifdef VERSION_US const char *credits09[] = { "1SOUND COMPOSER", "KOJI KONDO" }; // ...as well as sound effects and sound programmer in order to make room for screen text writer, Mario voice, and Peach voice -const char *credits10[] = { "4SOUND EFFECTS", "SOUND PROGRAMMER", "YOJI INAGAKI", "HIDEAKI SHIMIZU" }; +const char *credits10[] = { "4SOUND EFFECTS", "SOUND PROGRAMMER", "YOJI INAGAKI", "HIDEAKI SHIMIZU" }; const char *credits11[] = { "23-D ANIMATORS", "YOSHIAKI KOIZUMI", "SATORU TAKIZAWA" }; const char *credits12[] = { "1ADDITIONAL GRAPHICS", "MASANAO ARIMOTO" }; const char *credits13[] = { "3TECHNICAL SUPPORT", "TAKAO SAWANO", "HIROHITO YOSHIMOTO", "HIROTO YADA" }; const char *credits14[] = { "1TECHNICAL SUPPORT", "SGI N64 PROJECT STAFF" }; const char *credits15[] = { "2PROGRESS MANAGEMENT", "KIMIYOSHI FUKUI", "KEIZO KATO" }; -const char *credits16[] = { "5SCREEN TEXT WRITER", "TRANSLATION", "LESLIE SWAN", "MINA AKINO", "HIRO YAMADA" }; +const char *credits16[] = { "5SCREEN TEXT WRITER", "TRANSLATION", "LESLIE SWAN", "MINA AKINO", "HIRO YAMADA" }; #else // VERSION_EU // ...as well as sound composer, sound effects, and sound programmer, and... const char *credits09[] = { "7SOUND COMPOSER", "SOUND EFFECTS", "SOUND PROGRAMMER", "KOJI KONDO", "YOJI INAGAKI", "HIDEAKI SHIMIZU" }; @@ -120,7 +110,8 @@ const char *credits16[] = { "4SCREEN TEXT WRITER", "GERMAN TRANSLATION", "THOMAS const char *credits17[] = { "4MARIO VOICE", "PEACH VOICE", "CHARLES MARTINET", "LESLIE SWAN" }; #endif -#if defined(VERSION_JP) || defined(VERSION_SH) +#if defined(VERSION_JP) || defined(VERSION_SH) || defined(VERSION_CN) +// iQue uses this despite Jyoho Kaihatubu being Japanese const char *credits18[] = { "3SPECIAL THANKS TO", "JYOHO KAIHATUBU", "ALL NINTENDO", "MARIO CLUB STAFF" }; #elif defined(VERSION_US) const char *credits18[] = { "3SPECIAL THANKS TO", "EAD STAFF", "ALL NINTENDO PERSONNEL", "MARIO CLUB STAFF" }; @@ -128,9 +119,14 @@ const char *credits18[] = { "3SPECIAL THANKS TO", "EAD STAFF", "ALL NINTENDO PER const char *credits18[] = { "3SPECIAL THANKS TO", "EAD STAFF", "ALL NINTENDO PERSONNEL", "SUPER MARIO CLUB STAFF" }; #endif +#ifdef VERSION_CN +// iQue combines producer and executive producer in order to make room for China production +const char *credits19[] = { "4PRODUCER", "EXECUTIVE PRODUCER", "SHIGERU MIYAMOTO", "HIROSHI YAMAUCHI" }; +const char *credits20[] = { "1CHINA PRODUCTION", "IQUE ENGINEERING" }; +#else const char *credits19[] = { "1PRODUCER", "SHIGERU MIYAMOTO" }; const char *credits20[] = { "1EXECUTIVE PRODUCER", "HIROSHI YAMAUCHI" }; - +#endif struct CreditsEntry sCreditsSequence[] = { { LEVEL_CASTLE_GROUNDS, 1, 1, -128, { 0, 8000, 0 }, NULL }, @@ -160,27 +156,25 @@ struct CreditsEntry sCreditsSequence[] = { struct MarioState gMarioStates[1]; struct HudDisplay gHudDisplay; -s16 sCurrPlayMode; -u16 D_80339ECA; -s16 sTransitionTimer; -void (*sTransitionUpdate)(s16 *); -struct WarpDest sWarpDest; -s16 D_80339EE0; -s16 sDelayedWarpOp; -s16 sDelayedWarpTimer; -s16 sSourceWarpNodeId; -s32 sDelayedWarpArg; -#if defined(VERSION_EU) || defined(VERSION_SH) -s16 unusedEULevelUpdateBss1; -#endif -s8 sTimerRunning; + +FORCE_BSS s16 sCurrPlayMode; +FORCE_BSS u16 D_80339ECA; +FORCE_BSS s16 sTransitionTimer; +FORCE_BSS void (*sTransitionUpdate)(s16 *); +FORCE_BSS struct WarpDest sWarpDest; +FORCE_BSS s16 D_80339EE0; +FORCE_BSS s16 sDelayedWarpOp; +FORCE_BSS s16 sDelayedWarpTimer; +FORCE_BSS s16 sSourceWarpNodeId; +FORCE_BSS s32 sDelayedWarpArg; +FORCE_BSS s16 sUnusedLevelUpdateBss; +FORCE_BSS s8 sTimerRunning; s8 gNeverEnteredCastle; struct MarioState *gMarioState = &gMarioStates[0]; -u8 unused1[4] = { 0 }; +u8 unused1[2] = { 0 }; s8 sWarpCheckpointActive = FALSE; u8 unused2[4]; -u8 unused3[2]; u16 level_control_timer(s32 timerOp) { switch (timerOp) { @@ -248,7 +242,7 @@ void stub_level_update_1(void) { void load_level_init_text(u32 arg) { s32 gotAchievement; - u32 dialogID = gCurrentArea->dialog[arg]; + s32 dialogID = gCurrentArea->dialog[arg]; switch (dialogID) { case DIALOG_129: @@ -289,7 +283,7 @@ void init_door_warp(struct SpawnInfo *spawnInfo, u32 arg1) { } void set_mario_initial_cap_powerup(struct MarioState *m) { - u32 capCourseIndex = gCurrCourseNum - COURSE_CAP_COURSES; + s32 capCourseIndex = gCurrCourseNum - COURSE_CAP_COURSES; switch (capCourseIndex) { case COURSE_COTMC - COURSE_CAP_COURSES: @@ -512,7 +506,7 @@ void warp_credits(void) { vec3s_set(gPlayerSpawnInfos[0].startPos, gCurrCreditsEntry->marioPos[0], gCurrCreditsEntry->marioPos[1], gCurrCreditsEntry->marioPos[2]); - vec3s_set(gPlayerSpawnInfos[0].startAngle, 0, 0x100 * gCurrCreditsEntry->marioAngle, 0); + vec3s_set(gPlayerSpawnInfos[0].startAngle, 0, gCurrCreditsEntry->marioAngle << 8, 0); gPlayerSpawnInfos[0].areaIndex = sWarpDest.areaIdx; @@ -713,7 +707,7 @@ s16 level_trigger_warp(struct MarioState *m, s32 warpOp) { switch (warpOp) { case WARP_OP_DEMO_NEXT: case WARP_OP_DEMO_END: sDelayedWarpTimer = 20; // Must be one line to match on -O2 - sSourceWarpNodeId = WARP_NODE_F0; + sSourceWarpNodeId = WARP_NODE_SUCCESS; gSavedCourseNum = COURSE_NONE; val04 = FALSE; play_transition(WARP_TRANSITION_FADE_INTO_STAR, 0x14, 0x00, 0x00, 0x00); @@ -721,7 +715,7 @@ s16 level_trigger_warp(struct MarioState *m, s32 warpOp) { case WARP_OP_CREDITS_END: sDelayedWarpTimer = 60; - sSourceWarpNodeId = WARP_NODE_F0; + sSourceWarpNodeId = WARP_NODE_SUCCESS; val04 = FALSE; gSavedCourseNum = COURSE_NONE; play_transition(WARP_TRANSITION_FADE_INTO_COLOR, 0x3C, 0x00, 0x00, 0x00); @@ -729,7 +723,7 @@ s16 level_trigger_warp(struct MarioState *m, s32 warpOp) { case WARP_OP_STAR_EXIT: sDelayedWarpTimer = 32; - sSourceWarpNodeId = WARP_NODE_F0; + sSourceWarpNodeId = WARP_NODE_SUCCESS; gSavedCourseNum = COURSE_NONE; play_transition(WARP_TRANSITION_FADE_INTO_MARIO, 0x20, 0x00, 0x00, 0x00); break; @@ -757,24 +751,24 @@ s16 level_trigger_warp(struct MarioState *m, s32 warpOp) { play_transition(WARP_TRANSITION_FADE_INTO_CIRCLE, 0x14, 0x00, 0x00, 0x00); break; - case WARP_OP_UNKNOWN_01: // enter totwc + case WARP_OP_UNKNOWN_01: // enter TotWC sDelayedWarpTimer = 30; - sSourceWarpNodeId = WARP_NODE_F2; + sSourceWarpNodeId = WARP_NODE_TOTWC; play_transition(WARP_TRANSITION_FADE_INTO_COLOR, 0x1E, 0xFF, 0xFF, 0xFF); #ifndef VERSION_JP play_sound(SOUND_MENU_STAR_SOUND, gGlobalSoundSource); #endif break; - case WARP_OP_UNKNOWN_02: // bbh enter + case WARP_OP_UNKNOWN_02: // enter BBH sDelayedWarpTimer = 30; - sSourceWarpNodeId = (m->usedObj->oBehParams & 0x00FF0000) >> 16; + sSourceWarpNodeId = (m->usedObj->oBhvParams & 0x00FF0000) >> 16; play_transition(WARP_TRANSITION_FADE_INTO_COLOR, 0x1E, 0xFF, 0xFF, 0xFF); break; case WARP_OP_TELEPORT: sDelayedWarpTimer = 20; - sSourceWarpNodeId = (m->usedObj->oBehParams & 0x00FF0000) >> 16; + sSourceWarpNodeId = (m->usedObj->oBhvParams & 0x00FF0000) >> 16; val04 = !music_changed_through_warp(sSourceWarpNodeId); play_transition(WARP_TRANSITION_FADE_INTO_COLOR, 0x14, 0xFF, 0xFF, 0xFF); break; @@ -782,14 +776,14 @@ s16 level_trigger_warp(struct MarioState *m, s32 warpOp) { case WARP_OP_WARP_DOOR: sDelayedWarpTimer = 20; sDelayedWarpArg = m->actionArg; - sSourceWarpNodeId = (m->usedObj->oBehParams & 0x00FF0000) >> 16; + sSourceWarpNodeId = (m->usedObj->oBhvParams & 0x00FF0000) >> 16; val04 = !music_changed_through_warp(sSourceWarpNodeId); play_transition(WARP_TRANSITION_FADE_INTO_CIRCLE, 0x14, 0x00, 0x00, 0x00); break; case WARP_OP_WARP_OBJECT: sDelayedWarpTimer = 20; - sSourceWarpNodeId = (m->usedObj->oBehParams & 0x00FF0000) >> 16; + sSourceWarpNodeId = (m->usedObj->oBhvParams & 0x00FF0000) >> 16; val04 = !music_changed_through_warp(sSourceWarpNodeId); play_transition(WARP_TRANSITION_FADE_INTO_STAR, 0x14, 0x00, 0x00, 0x00); break; @@ -1166,13 +1160,7 @@ s32 init_level(void) { sDelayedWarpOp = WARP_OP_NONE; sTransitionTimer = 0; D_80339EE0 = 0; - - if (gCurrCreditsEntry == NULL) { - gHudDisplay.flags = HUD_DISPLAY_DEFAULT; - } else { - gHudDisplay.flags = HUD_DISPLAY_NONE; - } - + gHudDisplay.flags = gCurrCreditsEntry == NULL ? HUD_DISPLAY_DEFAULT : HUD_DISPLAY_NONE; sTimerRunning = FALSE; if (sWarpDest.type != WARP_TYPE_NOT_WARPING) { diff --git a/src/game/level_update.h b/src/game/level_update.h index b55d2737..787d0032 100644 --- a/src/game/level_update.h +++ b/src/game/level_update.h @@ -49,6 +49,77 @@ #define MARIO_SPAWN_LAUNCH_DEATH 0x25 #define MARIO_SPAWN_UNKNOWN_27 0x27 +enum WarpNodes { + WARP_NODE_00, + WARP_NODE_01, + WARP_NODE_02, + WARP_NODE_03, + WARP_NODE_04, + WARP_NODE_05, + WARP_NODE_06, + WARP_NODE_07, + WARP_NODE_08, + WARP_NODE_09, + WARP_NODE_0A, + WARP_NODE_0B, + WARP_NODE_0C, + WARP_NODE_0D, + WARP_NODE_0E, + WARP_NODE_0F, + WARP_NODE_10, + WARP_NODE_11, + WARP_NODE_14 = 0x14, + WARP_NODE_15, + WARP_NODE_16, + WARP_NODE_17, + WARP_NODE_18, + WARP_NODE_19, + WARP_NODE_1A, + WARP_NODE_1B, + WARP_NODE_1C, + WARP_NODE_1D, + WARP_NODE_1E, + WARP_NODE_1F, + WARP_NODE_20, + WARP_NODE_21, + WARP_NODE_22, + WARP_NODE_23, + WARP_NODE_24, + WARP_NODE_25, + WARP_NODE_26, + WARP_NODE_27, + WARP_NODE_28, + WARP_NODE_29, + WARP_NODE_2A, + WARP_NODE_32 = 0x32, + WARP_NODE_33, + WARP_NODE_34, + WARP_NODE_35, + WARP_NODE_36, + WARP_NODE_37, + WARP_NODE_38, + WARP_NODE_3A = 0x3A, + WARP_NODE_64 = 0x64, + WARP_NODE_65, + WARP_NODE_66, + WARP_NODE_67, + WARP_NODE_68, + WARP_NODE_69, + WARP_NODE_6B = 0x6B, + WARP_NODE_6C, + WARP_NODE_6D, + + // Special Warps + WARP_NODE_SUCCESS = 0xF0, + WARP_NODE_DEATH = 0xF1, + WARP_NODE_TOTWC = 0xF2, + WARP_NODE_WARP_FLOOR = 0xF3, + WARP_NODE_CREDITS_START = 0xF8, + WARP_NODE_CREDITS_MIN = WARP_NODE_CREDITS_START, + WARP_NODE_CREDITS_NEXT = 0xF9, + WARP_NODE_CREDITS_END = 0xFA +}; + struct CreditsEntry { /*0x00*/ u8 levelNum; @@ -85,7 +156,7 @@ extern s16 sDelayedWarpOp; extern s16 sDelayedWarpTimer; extern s16 sSourceWarpNodeId; extern s32 sDelayedWarpArg; -extern u8 unused3[2]; +extern s16 sUnusedLevelUpdateBss; extern s8 sTimerRunning; struct HudDisplay { diff --git a/src/game/macro_special_objects.c b/src/game/macro_special_objects.c index bd02e19c..48b82dc0 100644 --- a/src/game/macro_special_objects.c +++ b/src/game/macro_special_objects.c @@ -4,12 +4,10 @@ #include "object_helpers.h" #include "macro_special_objects.h" #include "object_list_processor.h" - #include "behavior_data.h" -#include "macro_presets.h" - -#include "special_presets.h" +#include "macro_presets.inc.c" +#include "special_presets.inc.c" /* * Converts the rotation value supplied by macro objects into one @@ -40,27 +38,27 @@ s16 convert_rotation(s16 inRotation) { /* * Spawns an object at an absolute location with rotation around the y-axis and - * parameters filling up the upper 2 bytes of newObj->oBehParams. + * parameters filling up the upper 2 bytes of newObj->oBhvParams. * The object will not spawn if 'behavior' is NULL. */ void spawn_macro_abs_yrot_2params(s32 model, const BehaviorScript *behavior, s16 x, s16 y, s16 z, s16 ry, s16 params) { if (behavior != NULL) { struct Object *newObj = spawn_object_abs_with_rot( &gMacroObjectDefaultParent, 0, model, behavior, x, y, z, 0, convert_rotation(ry), 0); - newObj->oBehParams = ((u32) params) << 16; + newObj->oBhvParams = ((u32) params) << 16; } } /* * Spawns an object at an absolute location with rotation around the y-axis and - * a single parameter filling up the upper byte of newObj->oBehParams. + * a single parameter filling up the upper byte of newObj->oBhvParams. * The object will not spawn if 'behavior' is NULL. */ void spawn_macro_abs_yrot_param1(s32 model, const BehaviorScript *behavior, s16 x, s16 y, s16 z, s16 ry, s16 param) { if (behavior != NULL) { struct Object *newObj = spawn_object_abs_with_rot( &gMacroObjectDefaultParent, 0, model, behavior, x, y, z, 0, convert_rotation(ry), 0); - newObj->oBehParams = ((u32) param) << 24; + newObj->oBhvParams = ((u32) param) << 24; } } @@ -79,31 +77,29 @@ void spawn_macro_abs_special(s32 model, const BehaviorScript *behavior, s16 x, s newObj->oMacroUnk110 = (f32) unkC; } -UNUSED static void spawn_macro_coin_unknown(const BehaviorScript *behavior, s16 a1[]) { - struct Object *sp3C; - s16 model; - - model = bhvYellowCoin == behavior ? MODEL_YELLOW_COIN : MODEL_NONE; - - sp3C = spawn_object_abs_with_rot(&gMacroObjectDefaultParent, 0, model, behavior, - a1[1], a1[2], a1[3], 0, convert_rotation(a1[0]), 0); - - sp3C->oUnk1A8 = a1[4]; - sp3C->oBehParams = (a1[4] & 0xFF) >> 16; -} - -struct LoadedPreset { - /*0x00*/ const BehaviorScript *behavior; - /*0x04*/ s16 param; // huh? why does the below function swap these.. just use the struct.. - /*0x06*/ s16 model; -}; - #define MACRO_OBJ_Y_ROT 0 #define MACRO_OBJ_X 1 #define MACRO_OBJ_Y 2 #define MACRO_OBJ_Z 3 #define MACRO_OBJ_PARAMS 4 +UNUSED static void spawn_macro_coin_unknown(const BehaviorScript *behavior, s16 objInfo[]) { + struct Object *coin; + s16 model = bhvYellowCoin == behavior ? MODEL_YELLOW_COIN : MODEL_NONE; + + coin = spawn_object_abs_with_rot(&gMacroObjectDefaultParent, 0, model, behavior, + objInfo[MACRO_OBJ_X], objInfo[MACRO_OBJ_Y], objInfo[MACRO_OBJ_Z], + 0, convert_rotation(objInfo[MACRO_OBJ_Y_ROT]), 0); + coin->oUnusedBhvParams = objInfo[MACRO_OBJ_PARAMS]; + coin->oBhvParams = (objInfo[MACRO_OBJ_PARAMS] & 0xFF) >> 16; +} + +struct LoadedPreset { + /* 0x00 */ const BehaviorScript *behavior; + /* 0x04 */ s16 param; // huh? why does the below function swap these.. just use the struct.. + /* 0x06 */ s16 model; +}; + void spawn_macro_objects(s16 areaIndex, s16 *macroObjList) { UNUSED u8 filler[4]; s32 presetID; @@ -120,7 +116,7 @@ void spawn_macro_objects(s16 areaIndex, s16 *macroObjList) { break; } - presetID = (*macroObjList & 0x1FF) - 31; // Preset identifier for MacroObjectPresets array + presetID = (*macroObjList & 0x1FF) - 31; // Preset identifier for sMacroObjectPresets array if (presetID < 0) { break; @@ -133,10 +129,10 @@ void spawn_macro_objects(s16 areaIndex, s16 *macroObjList) { macroObject[MACRO_OBJ_Z] = *macroObjList++; // Z position macroObject[MACRO_OBJ_PARAMS] = *macroObjList++; // Behavior params - // Get the preset values from the MacroObjectPresets list. - preset.model = MacroObjectPresets[presetID].model; - preset.behavior = MacroObjectPresets[presetID].behavior; - preset.param = MacroObjectPresets[presetID].param; + // Get the preset values from the sMacroObjectPresets list. + preset.model = sMacroObjectPresets[presetID].model; + preset.behavior = sMacroObjectPresets[presetID].behavior; + preset.param = sMacroObjectPresets[presetID].param; if (preset.param != 0) { macroObject[MACRO_OBJ_PARAMS] = @@ -160,10 +156,10 @@ void spawn_macro_objects(s16 areaIndex, s16 *macroObjList) { 0 // Z-rotation ); - newObj->oUnk1A8 = macroObject[MACRO_OBJ_PARAMS]; - newObj->oBehParams = ((macroObject[MACRO_OBJ_PARAMS] & 0x00FF) << 16) + newObj->oUnusedBhvParams = macroObject[MACRO_OBJ_PARAMS]; + newObj->oBhvParams = ((macroObject[MACRO_OBJ_PARAMS] & 0x00FF) << 16) + (macroObject[MACRO_OBJ_PARAMS] & 0xFF00); - newObj->oBehParams2ndByte = macroObject[MACRO_OBJ_PARAMS] & 0x00FF; + newObj->oBhvParams2ndByte = macroObject[MACRO_OBJ_PARAMS] & 0x00FF; newObj->respawnInfoType = RESPAWN_INFO_TYPE_16; newObj->respawnInfo = macroObjList - 1; newObj->parentObj = newObj; @@ -208,11 +204,11 @@ void spawn_macro_objects_hardcoded(s16 areaIndex, s16 *macroObjList) { break; case 1: spawn_macro_abs_yrot_2params(MODEL_BBH_TILTING_FLOOR_PLATFORM, - bhvBbhTiltingTrapPlatform, macroObjX, macroObjY, macroObjZ, + bhvBBHTiltingTrapPlatform, macroObjX, macroObjY, macroObjZ, macroObjRY, 0); break; case 2: - spawn_macro_abs_yrot_2params(MODEL_BBH_TUMBLING_PLATFORM, bhvBbhTumblingBridge, + spawn_macro_abs_yrot_2params(MODEL_BBH_TUMBLING_PLATFORM, bhvBBHTumblingBridge, macroObjX, macroObjY, macroObjZ, macroObjRY, 0); break; case 3: @@ -237,7 +233,7 @@ void spawn_macro_objects_hardcoded(s16 areaIndex, s16 *macroObjList) { } } -void spawn_special_objects(s16 areaIndex, s16 **specialObjList) { +void spawn_special_objects(s16 areaIndex, TerrainData **specialObjList) { s32 numOfSpecialObjects; s32 i; s32 offset; @@ -269,20 +265,20 @@ void spawn_special_objects(s16 areaIndex, s16 **specialObjList) { offset = 0; while (TRUE) { - if (SpecialObjectPresets[offset].preset_id == presetID) { + if (sSpecialObjectPresets[offset].presetID == presetID) { break; } - if (SpecialObjectPresets[offset].preset_id == 0xFF) { + if (sSpecialObjectPresets[offset].presetID == special_null_end) { } offset++; } - model = SpecialObjectPresets[offset].model; - behavior = SpecialObjectPresets[offset].behavior; - type = SpecialObjectPresets[offset].type; - defaultParam = SpecialObjectPresets[offset].defParam; + model = sSpecialObjectPresets[offset].model; + behavior = sSpecialObjectPresets[offset].behavior; + type = sSpecialObjectPresets[offset].type; + defaultParam = sSpecialObjectPresets[offset].defParam; switch (type) { case SPTYPE_NO_YROT_OR_PARAMS: @@ -340,13 +336,13 @@ u32 get_special_objects_size(s16 *data) { offset = 0; while (TRUE) { - if (SpecialObjectPresets[offset].preset_id == presetID) { + if (sSpecialObjectPresets[offset].presetID == presetID) { break; } offset++; } - switch (SpecialObjectPresets[offset].type) { + switch (sSpecialObjectPresets[offset].type) { case SPTYPE_NO_YROT_OR_PARAMS: break; case SPTYPE_YROT_NO_PARAMS: diff --git a/src/game/macro_special_objects.h b/src/game/macro_special_objects.h index d8bdc237..acef0a93 100644 --- a/src/game/macro_special_objects.h +++ b/src/game/macro_special_objects.h @@ -13,7 +13,7 @@ void spawn_macro_abs_special(s32 model, const BehaviorScript *behavior, s16 x, s void spawn_macro_objects(s16 areaIndex, s16 *macroObjList); void spawn_macro_objects_hardcoded(s16 areaIndex, s16 *macroObjList); -void spawn_special_objects(s16 areaIndex, s16 **specialObjList); +void spawn_special_objects(s16 areaIndex, TerrainData **specialObjList); #ifdef NO_SEGMENTED_MEMORY u32 get_special_objects_size(s16 *data); #endif diff --git a/src/game/main.c b/src/game/main.c index 3d6de1fe..4d8bf9b7 100644 --- a/src/game/main.c +++ b/src/game/main.c @@ -9,6 +9,7 @@ #include "profiler.h" #include "buffers/buffers.h" #include "segments.h" +#include "segment_symbols.h" #include "main.h" #include "rumble_init.h" @@ -141,7 +142,7 @@ void create_thread(OSThread *thread, OSId id, void (*entry)(void *), void *arg, osCreateThread(thread, id, entry, arg, sp, pri); } -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) extern void func_sh_802f69cc(void); #endif @@ -151,7 +152,7 @@ void handle_nmi_request(void) { stop_sounds_in_continuous_banks(); sound_banks_disable(SEQ_PLAYER_SFX, SOUND_BANKS_BACKGROUND); fadeout_music(90); -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) func_sh_802f69cc(); #endif } @@ -222,7 +223,7 @@ void handle_vblank(void) { stub_main_3(); gNumVblanks++; -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) if (gResetTimer > 0 && gResetTimer < 100) { gResetTimer++; } @@ -419,12 +420,12 @@ void turn_off_audio(void) { * Initialize hardware, start main thread, then idle. */ void thread1_idle(UNUSED void *arg) { -#if defined(VERSION_US) || defined(VERSION_SH) +#if defined(VERSION_US) || defined(VERSION_SH) || defined(VERSION_CN) s32 sp24 = osTvType; #endif osCreateViManager(OS_PRIORITY_VIMGR); -#if defined(VERSION_US) || defined(VERSION_SH) +#if defined(VERSION_US) || defined(VERSION_SH) || defined(VERSION_CN) if (sp24 == TV_TYPE_NTSC) { osViSetMode(&osViModeTable[OS_VI_NTSC_LAN1]); } else { diff --git a/src/game/main.h b/src/game/main.h index 91f99015..e0a670ae 100644 --- a/src/game/main.h +++ b/src/game/main.h @@ -3,42 +3,16 @@ #include "config.h" -struct RumbleData { - u8 unk00; - u8 unk01; - s16 unk02; - s16 unk04; -}; - -struct StructSH8031D9B0 { - s16 unk00; - s16 unk02; - s16 unk04; - s16 unk06; - s16 unk08; - s16 unk0A; - s16 unk0C; - s16 unk0E; -}; - extern OSThread D_80339210; extern OSThread gIdleThread; extern OSThread gMainThread; extern OSThread gGameLoopThread; extern OSThread gSoundThread; -#if ENABLE_RUMBLE -extern OSThread gRumblePakThread; - -extern s32 gRumblePakPfs; // Actually an OSPfs but we don't have that header yet -#endif extern OSMesgQueue gPIMesgQueue; extern OSMesgQueue gIntrMesgQueue; extern OSMesgQueue gSPTaskMesgQueue; -#if ENABLE_RUMBLE -extern OSMesgQueue gRumblePakSchedulerMesgQueue; -extern OSMesgQueue gRumbleThreadVIMesgQueue; -#endif + extern OSMesg gDmaMesgBuf[1]; extern OSMesg gPIMesgBuf[32]; extern OSMesg gSIEventMesgBuf[1]; @@ -48,13 +22,6 @@ extern OSIoMesg gDmaIoMesg; extern OSMesg gMainReceivedMesg; extern OSMesgQueue gDmaMesgQueue; extern OSMesgQueue gSIEventMesgQueue; -#if ENABLE_RUMBLE -extern OSMesg gRumblePakSchedulerMesgBuf[1]; -extern OSMesg gRumbleThreadVIMesgBuf[1]; - -extern struct RumbleData gRumbleDataQueue[3]; -extern struct StructSH8031D9B0 gCurrRumbleSettings; -#endif extern struct VblankHandler *gVblankHandler1; extern struct VblankHandler *gVblankHandler2; diff --git a/src/game/mario.c b/src/game/mario.c index cc5e8646..32c63c90 100644 --- a/src/game/mario.c +++ b/src/game/mario.c @@ -79,7 +79,7 @@ s16 set_mario_animation(struct MarioState *m, s32 targetAnimID) { if (targetAnim->flags & ANIM_FLAG_2) { o->header.gfx.animInfo.animFrame = targetAnim->startFrame; } else { - if (targetAnim->flags & ANIM_FLAG_FORWARD) { + if (targetAnim->flags & ANIM_FLAG_BACKWARD) { o->header.gfx.animInfo.animFrame = targetAnim->startFrame + 1; } else { o->header.gfx.animInfo.animFrame = targetAnim->startFrame - 1; @@ -111,7 +111,7 @@ s16 set_mario_anim_with_accel(struct MarioState *m, s32 targetAnimID, s32 accel) if (targetAnim->flags & ANIM_FLAG_2) { o->header.gfx.animInfo.animFrameAccelAssist = (targetAnim->startFrame << 0x10); } else { - if (targetAnim->flags & ANIM_FLAG_FORWARD) { + if (targetAnim->flags & ANIM_FLAG_BACKWARD) { o->header.gfx.animInfo.animFrameAccelAssist = (targetAnim->startFrame << 0x10) + accel; } else { o->header.gfx.animInfo.animFrameAccelAssist = (targetAnim->startFrame << 0x10) - accel; @@ -134,13 +134,13 @@ void set_anim_to_frame(struct MarioState *m, s16 animFrame) { struct Animation *curAnim = animInfo->curAnim; if (animInfo->animAccel != 0) { - if (curAnim->flags & ANIM_FLAG_FORWARD) { + if (curAnim->flags & ANIM_FLAG_BACKWARD) { animInfo->animFrameAccelAssist = (animFrame << 0x10) + animInfo->animAccel; } else { animInfo->animFrameAccelAssist = (animFrame << 0x10) - animInfo->animAccel; } } else { - if (curAnim->flags & ANIM_FLAG_FORWARD) { + if (curAnim->flags & ANIM_FLAG_BACKWARD) { animInfo->animFrame = animFrame + 1; } else { animInfo->animFrame = animFrame - 1; @@ -155,7 +155,7 @@ s32 is_anim_past_frame(struct MarioState *m, s16 animFrame) { struct Animation *curAnim = animInfo->curAnim; if (animInfo->animAccel != 0) { - if (curAnim->flags & ANIM_FLAG_FORWARD) { + if (curAnim->flags & ANIM_FLAG_BACKWARD) { isPastFrame = (animInfo->animFrameAccelAssist > acceleratedFrame) && (acceleratedFrame >= (animInfo->animFrameAccelAssist - animInfo->animAccel)); @@ -165,7 +165,7 @@ s32 is_anim_past_frame(struct MarioState *m, s16 animFrame) { && (acceleratedFrame <= (animInfo->animFrameAccelAssist + animInfo->animAccel)); } } else { - if (curAnim->flags & ANIM_FLAG_FORWARD) { + if (curAnim->flags & ANIM_FLAG_BACKWARD) { isPastFrame = (animInfo->animFrame == (animFrame + 1)); } else { isPastFrame = ((animInfo->animFrame + 1) == animFrame); @@ -1329,7 +1329,7 @@ void update_mario_geometry_inputs(struct MarioState *m) { m->floorHeight = find_floor(m->pos[0], m->pos[1], m->pos[2], &m->floor); } - m->ceilHeight = vec3f_find_ceil(&m->pos[0], m->floorHeight, &m->ceil); + m->ceilHeight = vec3f_find_ceil(m->pos, m->floorHeight, &m->ceil); gasLevel = find_poison_gas_level(m->pos[0], m->pos[2]); m->waterLevel = find_water_level(m->pos[0], m->pos[2]); @@ -1393,7 +1393,7 @@ void update_mario_inputs(struct MarioState *m) { if (!(m->input & (INPUT_NONZERO_ANALOG | INPUT_A_PRESSED))) { m->input |= INPUT_UNKNOWN_5; } - + // These 3 flags are defined by Bowser stomping attacks if (m->marioObj->oInteractStatus & (INT_STATUS_MARIO_STUNNED | INT_STATUS_MARIO_KNOCKBACK_DMG | INT_STATUS_MARIO_SHOCKWAVE)) { diff --git a/src/game/mario_actions_airborne.c b/src/game/mario_actions_airborne.c index 60c7c091..0d9a5395 100644 --- a/src/game/mario_actions_airborne.c +++ b/src/game/mario_actions_airborne.c @@ -1271,8 +1271,8 @@ s32 act_getting_blown(struct MarioState *m) { m->forwardVel += 0.8f; } - if (m->vel[1] < 0.0f && m->unkC4 < 4.0f) { - m->unkC4 += 0.05f; + if (m->vel[1] < 0.0f && m->gettingBlownGravity < 4.0f) { + m->gettingBlownGravity += 0.05f; } } diff --git a/src/game/mario_actions_automatic.c b/src/game/mario_actions_automatic.c index 40235766..f973c665 100644 --- a/src/game/mario_actions_automatic.c +++ b/src/game/mario_actions_automatic.c @@ -567,13 +567,12 @@ s32 act_ledge_grab(struct MarioState *m) { } return let_go_of_ledge(m); } + if (m->actionTimer == 10 && (m->input & INPUT_NONZERO_ANALOG) #ifdef VERSION_EU - // On EU, you can't slow climb up ledges while holding A. - if (m->actionTimer == 10 && (m->input & INPUT_NONZERO_ANALOG) && !(m->input & INPUT_A_DOWN)) -#else - if (m->actionTimer == 10 && (m->input & INPUT_NONZERO_ANALOG)) + // On EU, you can't slow climb up ledges while holding A. + && !(m->input & INPUT_A_DOWN) #endif - { + ) { if (intendedDYaw >= -0x4000 && intendedDYaw <= 0x4000) { if (hasSpaceForMario) { return set_mario_action(m, ACT_LEDGE_CLIMB_SLOW_1, 0); diff --git a/src/game/mario_actions_cutscene.c b/src/game/mario_actions_cutscene.c index ab797405..fcee2c29 100644 --- a/src/game/mario_actions_cutscene.c +++ b/src/game/mario_actions_cutscene.c @@ -514,7 +514,7 @@ s32 act_reading_sign(struct MarioState *m) { m->pos[2] += marioObj->oMarioReadingSignDPosZ / 11.0f; // create the text box if (m->actionTimer++ == 10) { - create_dialog_inverted_box(m->usedObj->oBehParams2ndByte); + create_dialog_inverted_box(m->usedObj->oBhvParams2ndByte); m->actionState = 2; } break; @@ -800,7 +800,7 @@ s32 act_unlocking_key_door(struct MarioState *m) { stop_and_set_height_to_floor(m); if (is_anim_at_end(m)) { - if (m->usedObj->oBehParams >> 24 == 1) { + if (m->usedObj->oBhvParams >> 24 == 1) { save_file_set_flags(SAVE_FLAG_UNLOCKED_UPSTAIRS_DOOR); save_file_clear_flags(SAVE_FLAG_HAVE_KEY_2); } else { @@ -2053,7 +2053,7 @@ static void end_peach_cutscene_summon_jumbo_star(struct MarioState *m) { #if defined(VERSION_EU) #define TIMER_FADE_IN_PEACH 201 #define TIMER_DESCEND_PEACH 280 -#elif defined(VERSION_SH) +#elif defined(VERSION_SH) || defined(VERSION_CN) #define TIMER_FADE_IN_PEACH 276 #define TIMER_DESCEND_PEACH 400 #else @@ -2186,15 +2186,15 @@ static void end_peach_cutscene_dialog_1(struct MarioState *m) { } switch (m->actionTimer) { -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) case 110: #else case 80: #endif sEndPeachAnimation = 6; break; - -#ifdef VERSION_SH + +#if defined(VERSION_SH) || defined(VERSION_CN) case 111: #else case 81: @@ -2202,7 +2202,7 @@ static void end_peach_cutscene_dialog_1(struct MarioState *m) { D_8032CBE4 = 3; break; -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) case 175: #else case 145: @@ -2210,7 +2210,7 @@ static void end_peach_cutscene_dialog_1(struct MarioState *m) { D_8032CBE4 = 2; break; -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) case 258: #else case 228: @@ -2219,7 +2219,7 @@ static void end_peach_cutscene_dialog_1(struct MarioState *m) { D_8032CBE8 = 1; break; -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) case 260: #else case 230: @@ -2231,7 +2231,7 @@ static void end_peach_cutscene_dialog_1(struct MarioState *m) { #endif break; -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) case 305: #else case 275: @@ -2240,7 +2240,7 @@ static void end_peach_cutscene_dialog_1(struct MarioState *m) { D_8032CBE8 = 0; break; -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) case 320: #else case 290: @@ -2251,7 +2251,7 @@ static void end_peach_cutscene_dialog_1(struct MarioState *m) { #endif break; -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) case 510: #else case 480: @@ -2264,7 +2264,7 @@ static void end_peach_cutscene_dialog_1(struct MarioState *m) { #if defined(VERSION_EU) #define TIMER_SOMETHING_SPECIAL 150 #define TIMER_PEACH_KISS 260 -#elif defined(VERSION_SH) +#elif defined(VERSION_SH) || defined(VERSION_CN) #define TIMER_SOMETHING_SPECIAL 170 #define TIMER_PEACH_KISS 250 #else @@ -2280,7 +2280,7 @@ static void end_peach_cutscene_dialog_2(struct MarioState *m) { sEndPeachAnimation = 9; switch (m->actionTimer) { -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) case 39: #else case 29: @@ -2291,15 +2291,15 @@ static void end_peach_cutscene_dialog_2(struct MarioState *m) { #endif break; -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) case 65: -#else +#else case 45: #endif D_8032CBE8 = 1; break; -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) case 105: #else case 75: @@ -2569,7 +2569,7 @@ static s32 act_end_peach_cutscene(struct MarioState *m) { #define TIMER_CREDITS_SHOW 51 #define TIMER_CREDITS_PROGRESS 80 #define TIMER_CREDITS_WARP 160 -#elif defined(VERSION_SH) +#elif defined(VERSION_SH) || defined(VERSION_CN) #define TIMER_CREDITS_SHOW 61 #define TIMER_CREDITS_PROGRESS 90 #define TIMER_CREDITS_WARP 204 diff --git a/src/game/mario_actions_moving.c b/src/game/mario_actions_moving.c index 071ea66c..9da6abb8 100644 --- a/src/game/mario_actions_moving.c +++ b/src/game/mario_actions_moving.c @@ -1845,7 +1845,7 @@ s32 act_hold_freefall_land(struct MarioState *m) { } s32 act_long_jump_land(struct MarioState *m) { -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) // BLJ (Backwards Long Jump) speed build up fix, crushing SimpleFlips's dreams since July 1997 if (m->forwardVel < 0.0f) { m->forwardVel = 0.0f; diff --git a/src/game/mario_misc.c b/src/game/mario_misc.c index b2eb7ddb..92641df6 100644 --- a/src/game/mario_misc.c +++ b/src/game/mario_misc.c @@ -123,22 +123,22 @@ static void toad_message_opaque(void) { } static void toad_message_talking(void) { - if (cur_obj_update_dialog_with_cutscene(MARIO_DIALOG_LOOK_DOWN, - DIALOG_FLAG_TURN_TO_MARIO, CUTSCENE_DIALOG, gCurrentObject->oToadMessageDialogId)) { + if (cur_obj_update_dialog_with_cutscene(MARIO_DIALOG_LOOK_DOWN, + DIALOG_FLAG_TURN_TO_MARIO, CUTSCENE_DIALOG, gCurrentObject->oToadMessageDialogID)) { gCurrentObject->oToadMessageRecentlyTalked = TRUE; gCurrentObject->oToadMessageState = TOAD_MESSAGE_FADING; - switch (gCurrentObject->oToadMessageDialogId) { + switch (gCurrentObject->oToadMessageDialogID) { case TOAD_STAR_1_DIALOG: - gCurrentObject->oToadMessageDialogId = TOAD_STAR_1_DIALOG_AFTER; - bhv_spawn_star_no_level_exit(0); + gCurrentObject->oToadMessageDialogID = TOAD_STAR_1_DIALOG_AFTER; + bhv_spawn_star_no_level_exit(STAR_INDEX_ACT_1); break; case TOAD_STAR_2_DIALOG: - gCurrentObject->oToadMessageDialogId = TOAD_STAR_2_DIALOG_AFTER; - bhv_spawn_star_no_level_exit(1); + gCurrentObject->oToadMessageDialogID = TOAD_STAR_2_DIALOG_AFTER; + bhv_spawn_star_no_level_exit(STAR_INDEX_ACT_2); break; case TOAD_STAR_3_DIALOG: - gCurrentObject->oToadMessageDialogId = TOAD_STAR_3_DIALOG_AFTER; - bhv_spawn_star_no_level_exit(2); + gCurrentObject->oToadMessageDialogID = TOAD_STAR_3_DIALOG_AFTER; + bhv_spawn_star_no_level_exit(STAR_INDEX_ACT_3); break; } } @@ -182,31 +182,32 @@ void bhv_toad_message_loop(void) { void bhv_toad_message_init(void) { s32 saveFlags = save_file_get_flags(); s32 starCount = save_file_get_total_star_count(gCurrSaveFileNum - 1, COURSE_MIN - 1, COURSE_MAX - 1); - s32 dialogId = (gCurrentObject->oBehParams >> 24) & 0xFF; + s32 dialogID = (gCurrentObject->oBhvParams >> 24) & 0xFF; s32 enoughStars = TRUE; - switch (dialogId) { + switch (dialogID) { case TOAD_STAR_1_DIALOG: enoughStars = (starCount >= TOAD_STAR_1_REQUIREMENT); if (saveFlags & SAVE_FLAG_COLLECTED_TOAD_STAR_1) { - dialogId = TOAD_STAR_1_DIALOG_AFTER; + dialogID = TOAD_STAR_1_DIALOG_AFTER; } break; case TOAD_STAR_2_DIALOG: enoughStars = (starCount >= TOAD_STAR_2_REQUIREMENT); if (saveFlags & SAVE_FLAG_COLLECTED_TOAD_STAR_2) { - dialogId = TOAD_STAR_2_DIALOG_AFTER; + dialogID = TOAD_STAR_2_DIALOG_AFTER; } break; case TOAD_STAR_3_DIALOG: enoughStars = (starCount >= TOAD_STAR_3_REQUIREMENT); if (saveFlags & SAVE_FLAG_COLLECTED_TOAD_STAR_3) { - dialogId = TOAD_STAR_3_DIALOG_AFTER; + dialogID = TOAD_STAR_3_DIALOG_AFTER; } break; } + if (enoughStars) { - gCurrentObject->oToadMessageDialogId = dialogId; + gCurrentObject->oToadMessageDialogID = dialogID; gCurrentObject->oToadMessageRecentlyTalked = FALSE; gCurrentObject->oToadMessageState = TOAD_MESSAGE_FADED; gCurrentObject->oOpacity = 81; @@ -644,5 +645,6 @@ Gfx *geo_mirror_mario_backface_culling(s32 callContext, struct GraphNode *node, } asGenerated->fnNode.node.flags = (asGenerated->fnNode.node.flags & 0xFF) | (LAYER_OPAQUE << 8); } + return gfx; } diff --git a/src/game/mario_step.c b/src/game/mario_step.c index c3da0cbb..9f442fc4 100644 --- a/src/game/mario_step.c +++ b/src/game/mario_step.c @@ -552,7 +552,7 @@ void apply_gravity(struct MarioState *m) { m->vel[1] = -65.0f; } } else if (m->action == ACT_GETTING_BLOWN) { - m->vel[1] -= m->unkC4; + m->vel[1] -= m->gettingBlownGravity; if (m->vel[1] < -75.0f) { m->vel[1] = -75.0f; } diff --git a/src/game/memory.c b/src/game/memory.c index dcc9223d..0d081568 100644 --- a/src/game/memory.c +++ b/src/game/memory.c @@ -4,13 +4,14 @@ #define INCLUDED_FROM_MEMORY_C +#include "buffers/zbuffer.h" #include "buffers/buffers.h" #include "decompress.h" #include "game_init.h" #include "main.h" #include "memory.h" -#include "segment_symbols.h" #include "segments.h" +#include "segment_symbols.h" // round up to the next multiple #define ALIGN4(val) (((val) + 0x3) & ~0x3) @@ -40,6 +41,7 @@ struct MemoryPool { struct MemoryBlock freeList; }; +// Double declared to preserve US bss ordering. extern uintptr_t sSegmentTable[32]; extern u32 sPoolFreeSpace; extern u8 *sPoolStart; @@ -54,13 +56,12 @@ extern struct MainPoolBlock *sPoolListHeadR; */ struct MemoryPool *gEffectsMemoryPool; -uintptr_t sSegmentTable[32]; -u32 sPoolFreeSpace; -u8 *sPoolStart; -u8 *sPoolEnd; -struct MainPoolBlock *sPoolListHeadL; -struct MainPoolBlock *sPoolListHeadR; - +FORCE_BSS uintptr_t sSegmentTable[32]; +FORCE_BSS u32 sPoolFreeSpace; +FORCE_BSS u8 *sPoolStart; +FORCE_BSS u8 *sPoolEnd; +FORCE_BSS struct MainPoolBlock *sPoolListHeadL; +FORCE_BSS struct MainPoolBlock *sPoolListHeadR; static struct MainPoolState *gMainPoolState = NULL; @@ -112,8 +113,12 @@ void move_segment_table_to_dmem(void) { * that grow inward from the left and right. It therefore only supports * freeing the object that was most recently allocated from a side. */ -void main_pool_init(void *start, void *end) { +void main_pool_init(UNUSED_CN void *start, void *end) { +#if defined(VERSION_CN) && !defined(USE_EXT_RAM) + sPoolStart = (u8 *) ALIGN16((uintptr_t) &gZBufferEnd) + 16; +#else sPoolStart = (u8 *) ALIGN16((uintptr_t) start) + 16; +#endif sPoolEnd = (u8 *) ALIGN16((uintptr_t) end - 15) - 16; sPoolFreeSpace = sPoolEnd - sPoolStart; @@ -332,7 +337,10 @@ void *load_segment_decompress(s32 segment, u8 *srcStart, u8 *srcEnd) { dma_read(compressed, srcStart, srcEnd); dest = main_pool_alloc(*size, MEMORY_POOL_LEFT); if (dest != NULL) { + CN_DEBUG_PRINTF(("start decompress\n")); decompress(compressed, dest); + CN_DEBUG_PRINTF(("end decompress\n")); + set_segment_base_addr(segment, dest); main_pool_free(compressed); } else { @@ -481,7 +489,7 @@ void *mem_pool_alloc(struct MemoryPool *pool, u32 size) { /** * Free a block that was allocated using mem_pool_alloc. */ -void mem_pool_free(struct MemoryPool *pool, void *addr) { +BAD_RETURN(s32) mem_pool_free(struct MemoryPool *pool, void *addr) { struct MemoryBlock *block = (struct MemoryBlock *) ((u8 *) addr - sizeof(struct MemoryBlock)); struct MemoryBlock *freeList = pool->freeList.next; @@ -503,21 +511,25 @@ void mem_pool_free(struct MemoryPool *pool, void *addr) { if (freeList < block && block < freeList->next) { break; } + freeList = freeList->next; } - if ((u8 *) freeList + freeList->size == (u8 *) block) { + + if (block == (struct MemoryBlock *) ((u8 *) freeList + freeList->size)) { freeList->size += block->size; block = freeList; } else { block->next = freeList->next; freeList->next = block; } + if (block->next != NULL && (u8 *) block->next == (u8 *) block + block->size) { block->size = block->size + block->next->size; block->next = block->next->next; } } } + // nothing is returned, but must have non-void return type for render_text_labels to match on iQue } void *alloc_display_list(u32 size) { @@ -535,7 +547,7 @@ void *alloc_display_list(u32 size) { static struct DmaTable *load_dma_table_address(u8 *srcAddr) { struct DmaTable *table = dynamic_dma_read(srcAddr, srcAddr + sizeof(u32), MEMORY_POOL_LEFT); - u32 size = table->count * sizeof(struct OffsetSizePair) + + u32 size = table->count * sizeof(struct OffsetSizePair) + sizeof(struct DmaTable) - sizeof(struct OffsetSizePair); main_pool_free(table); @@ -560,7 +572,7 @@ s32 load_patchable_table(struct DmaHandlerList *list, s32 index) { u8 *addr = table->srcAddr + table->anim[index].offset; s32 size = table->anim[index].size; - if (list->currentAddr != addr) { + if (addr != list->currentAddr) { dma_read(list->bufTarget, addr, addr + size); list->currentAddr = addr; ret = TRUE; diff --git a/src/game/memory.h b/src/game/memory.h index 0d958b8e..6bf3ca23 100644 --- a/src/game/memory.h +++ b/src/game/memory.h @@ -75,7 +75,7 @@ struct AllocOnlyPool *alloc_only_pool_resize(struct AllocOnlyPool *pool, u32 siz struct MemoryPool *mem_pool_init(u32 size, u32 side); void *mem_pool_alloc(struct MemoryPool *pool, u32 size); -void mem_pool_free(struct MemoryPool *pool, void *addr); +BAD_RETURN(s32) mem_pool_free(struct MemoryPool *pool, void *addr); void *alloc_display_list(u32 size); void setup_dma_table_list(struct DmaHandlerList *list, void *srcAddr, void *buffer); diff --git a/src/game/moving_texture.c b/src/game/moving_texture.c index 175b854a..86ffa2b7 100644 --- a/src/game/moving_texture.c +++ b/src/game/moving_texture.c @@ -118,7 +118,7 @@ s8 gMovtexVtxColor = MOVTEX_VTX_COLOR_DEFAULT; float gPaintingMarioYEntry = 0.0f; /// Variable to ensure the initial Wet-Dry World water level is set only once -s32 gWdwWaterLevelSet = FALSE; +s32 gWDWWaterLevelSet = FALSE; extern u8 ssl_quicksand[]; extern u8 ssl_pyramid_sand[]; @@ -243,7 +243,7 @@ struct MovtexObject gMovtexNonColored[] = { { MOVTEX_COTMC_WATER, TEXTURE_WATER, 14, cotmc_movtex_tris_water, cotmc_dl_water_begin, cotmc_dl_water_end, cotmc_dl_water, 0xff, 0xff, 0xff, 0xb4, LAYER_TRANSPARENT_INTER }, - // Tall Tall mountain has water going from the top to the bottom of the mountain. + // Tall, Tall mountain has water going from the top to the bottom of the mountain. { MOVTEX_TTM_BEGIN_WATERFALL, TEXTURE_WATER, 6, ttm_movtex_tris_begin_waterfall, dl_waterbox_rgba16_begin, dl_waterbox_end, ttm_dl_waterfall, 0xff, 0xff, 0xff, 0xb4, LAYER_TRANSPARENT }, @@ -308,9 +308,9 @@ Gfx *geo_wdw_set_initial_water_level(s32 callContext, UNUSED struct GraphNode *n // Why was this global variable needed when they could just check for GEO_CONTEXT_AREA_LOAD? if (callContext != GEO_CONTEXT_RENDER) { - gWdwWaterLevelSet = FALSE; + gWDWWaterLevelSet = FALSE; } else if (callContext == GEO_CONTEXT_RENDER && gEnvironmentRegions != NULL - && !gWdwWaterLevelSet) { + && !gWDWWaterLevelSet) { if (gPaintingMarioYEntry <= 1382.4) { wdwWaterHeight = 31; } else if (gPaintingMarioYEntry >= 1600.0) { @@ -321,7 +321,7 @@ Gfx *geo_wdw_set_initial_water_level(s32 callContext, UNUSED struct GraphNode *n for (i = 0; i < *gEnvironmentRegions; i++) { gEnvironmentRegions[i * 6 + 6] = wdwWaterHeight; } - gWdwWaterLevelSet = TRUE; + gWDWWaterLevelSet = TRUE; } return NULL; } @@ -670,8 +670,9 @@ Gfx *geo_movtex_draw_water_regions(s32 callContext, struct GraphNode *node, UNUS waterId = gEnvironmentRegions[i * 6 + 1]; waterY = gEnvironmentRegions[i * 6 + 6]; subList = movtex_gen_quads_id(waterId, waterY, quadCollection); - if (subList != NULL) + if (subList != NULL) { gSPDisplayList(gfx++, VIRTUAL_TO_PHYSICAL(subList)); + } } gSPDisplayList(gfx++, dl_waterbox_end); gSPEndDisplayList(gfx); diff --git a/src/game/obj_behaviors.c b/src/game/obj_behaviors.c index 68c78e23..d2a45c97 100644 --- a/src/game/obj_behaviors.c +++ b/src/game/obj_behaviors.c @@ -100,7 +100,6 @@ Gfx UNUSED *geo_obj_transparency_something(s32 callContext, struct GraphNode *no obj = (struct Object *) node; unusedObject = (struct Object *) node; - if (gCurGraphNodeHeldObject != NULL) { heldObject = gCurGraphNodeHeldObject->objNode; } @@ -753,14 +752,14 @@ s8 obj_lava_death(void) { /** * Spawns an orange number object relatively, such as those that count up for secrets. */ -void spawn_orange_number(s8 behParam, s16 relX, s16 relY, s16 relZ) { +void spawn_orange_number(s8 bhvParam, s16 relX, s16 relY, s16 relZ) { struct Object *orangeNumber; - if (behParam >= 10) { + if (bhvParam >= 10) { return; } - orangeNumber = spawn_object_relative(behParam, relX, relY, relZ, o, MODEL_NUMBER, bhvOrangeNumber); + orangeNumber = spawn_object_relative(bhvParam, relX, relY, relZ, o, MODEL_NUMBER, bhvOrangeNumber); orangeNumber->oPosY += 25.0f; } diff --git a/src/game/obj_behaviors.h b/src/game/obj_behaviors.h index 9755984f..f4442189 100644 --- a/src/game/obj_behaviors.h +++ b/src/game/obj_behaviors.h @@ -160,6 +160,6 @@ void bhv_free_bowling_ball_roll_loop(void); /* likely unused */ void bhv_free_bowling_ball_loop(void); /* likely unused */ void bhv_rr_cruiser_wing_init(void); void bhv_rr_cruiser_wing_loop(void); -void spawn_default_star(f32 sp20, f32 sp24, f32 sp28); +void spawn_default_star(f32 homeX, f32 homeY, f32 homeZ); #endif // OBJ_BEHAVIORS_H diff --git a/src/game/obj_behaviors_2.c b/src/game/obj_behaviors_2.c index 3715a137..f6149218 100644 --- a/src/game/obj_behaviors_2.c +++ b/src/game/obj_behaviors_2.c @@ -70,7 +70,6 @@ extern struct Object *sMasterTreadmill; */ struct Object *sMasterTreadmill; - f32 sObjSavedPosX; f32 sObjSavedPosY; f32 sObjSavedPosZ; @@ -159,7 +158,7 @@ static void platform_on_track_update_pos_or_spawn_ball(s32 ballIndex, f32 x, f32 f32 dz; f32 distToNextWaypoint; - if (ballIndex == 0 || ((u16)(o->oBehParams >> 16) & 0x0080)) { + if (ballIndex == 0 || ((u16)(o->oBhvParams >> 16) & 0x0080)) { initialPrevWaypoint = o->oPlatformOnTrackPrevWaypoint; nextWaypoint = initialPrevWaypoint; @@ -180,7 +179,7 @@ static void platform_on_track_update_pos_or_spawn_ball(s32 ballIndex, f32 x, f32 o->oPlatformOnTrackPrevWaypointFlags = WAYPOINT_FLAGS_END; } - if (((u16)(o->oBehParams >> 16) & PLATFORM_ON_TRACK_BP_RETURN_TO_START)) { + if (((u16)(o->oBhvParams >> 16) & PLATFORM_ON_TRACK_BP_RETURN_TO_START)) { nextWaypoint = o->oPlatformOnTrackStartWaypoint; } else { return; @@ -625,8 +624,8 @@ static void obj_die_if_health_non_positive(void) { spawn_mist_particles(); } - if ((s32)o->oNumLootCoins < 0) { - spawn_object(o, MODEL_BLUE_COIN, bhvMrIBlueCoin); + if (o->oNumLootCoins < 0) { + spawn_object(o, MODEL_BLUE_COIN, bhvSpawnedBlueCoin); } else { obj_spawn_loot_yellow_coins(o, o->oNumLootCoins, 20.0f); } @@ -787,7 +786,7 @@ static void obj_act_squished(f32 baseScale) { if (approach_f32_ptr(&o->header.gfx.scale[1], targetScaleY, baseScale * 0.14f)) { o->header.gfx.scale[0] = o->header.gfx.scale[2] = baseScale * 2.0f - o->header.gfx.scale[1]; - if (o->oTimer >= 16) { + if (o->oTimer > 15) { obj_die_if_health_non_positive(); } } diff --git a/src/game/object_helpers.c b/src/game/object_helpers.c index 338d5263..54cf24f4 100644 --- a/src/game/object_helpers.c +++ b/src/game/object_helpers.c @@ -27,7 +27,7 @@ #include "spawn_object.h" #include "spawn_sound.h" -static s8 sBbhStairJiggleOffsets[] = { -8, 8, -4, 4 }; +static s8 sBBHStairJiggleOffsets[] = { -8, 8, -4, 4 }; static s16 sPowersOfTwo[] = { 0x01, 0x02, 0x04, 0x08, 0x10, 0x20, 0x40, 0x80 }; static s8 sLevelsWithRooms[] = { LEVEL_BBH, LEVEL_CASTLE, LEVEL_HMC, -1 }; @@ -36,17 +36,16 @@ static s32 clear_move_flag(u32 *, s32); #define o gCurrentObject Gfx *geo_update_projectile_pos_from_parent(s32 callContext, UNUSED struct GraphNode *node, Mat4 mtx) { - Mat4 sp20; - struct Object *sp1C; - if (callContext == GEO_CONTEXT_RENDER) { - sp1C = (struct Object *) gCurGraphNodeObject; // TODO: change global type to Object pointer - if (sp1C->prevObj) { + Mat4 sp20; + struct Object *obj = (struct Object *) gCurGraphNodeObject; // TODO: change global type to Object pointer + if (obj->prevObj) { create_transformation_from_matrices(sp20, mtx, *gCurGraphNodeCamera->matrixPtr); - obj_update_pos_from_parent_transformation(sp20, sp1C->prevObj); - obj_set_gfx_pos_from_pos(sp1C->prevObj); + obj_update_pos_from_parent_transformation(sp20, obj->prevObj); + obj_set_gfx_pos_from_pos(obj->prevObj); } } + return NULL; } @@ -134,10 +133,11 @@ Gfx *geo_update_layer_transparency(s32 callContext, struct GraphNode *node, UNUS * o32 calling convention. */ #ifdef AVOID_UB -Gfx *geo_switch_anim_state(s32 callContext, struct GraphNode *node, UNUSED void *context) { +Gfx *geo_switch_anim_state(s32 callContext, struct GraphNode *node, UNUSED void *context) #else -Gfx *geo_switch_anim_state(s32 callContext, struct GraphNode *node) { +Gfx *geo_switch_anim_state(s32 callContext, struct GraphNode *node) #endif +{ struct Object *obj; struct GraphNodeSwitchCase *switchCase; @@ -167,10 +167,11 @@ Gfx *geo_switch_anim_state(s32 callContext, struct GraphNode *node) { //! @bug Same issue as geo_switch_anim_state. #ifdef AVOID_UB -Gfx *geo_switch_area(s32 callContext, struct GraphNode *node, UNUSED void *context) { +Gfx *geo_switch_area(s32 callContext, struct GraphNode *node, UNUSED void *context) #else -Gfx *geo_switch_area(s32 callContext, struct GraphNode *node) { +Gfx *geo_switch_area(s32 callContext, struct GraphNode *node) #endif +{ s16 sp26; struct Surface *sp20; UNUSED struct Object *sp1C = @@ -257,9 +258,9 @@ void create_transformation_from_matrices(Mat4 a0, Mat4 a1, Mat4 a2) { a0[3][1] = a1[3][0] * a2[1][0] + a1[3][1] * a2[1][1] + a1[3][2] * a2[1][2] - sp8; a0[3][2] = a1[3][0] * a2[2][0] + a1[3][1] * a2[2][1] + a1[3][2] * a2[2][2] - sp4; - a0[0][3] = 0; - a0[1][3] = 0; - a0[2][3] = 0; + a0[0][3] = 0.0f; + a0[1][3] = 0.0f; + a0[2][3] = 0.0f; a0[3][3] = 1.0f; } @@ -583,8 +584,8 @@ struct Object *spawn_object_relative(s16 behaviorParam, s16 relativePosX, s16 re obj_set_parent_relative_pos(obj, relativePosX, relativePosY, relativePosZ); obj_build_relative_transform(obj); - obj->oBehParams2ndByte = behaviorParam; - obj->oBehParams = (behaviorParam & 0xFF) << 16; + obj->oBhvParams2ndByte = behaviorParam; + obj->oBhvParams = (behaviorParam & 0xFF) << 16; return obj; } @@ -732,8 +733,8 @@ void cur_obj_init_animation_with_accel_and_sound(s32 animIndex, f32 accel) { } void obj_init_animation_with_sound(struct Object *obj, const struct Animation * const* animations, s32 animIndex) { - struct Animation **anims = (struct Animation **)animations; - obj->oAnimations = (struct Animation **)animations; + struct Animation **anims = (struct Animation **) animations; + obj->oAnimations = (struct Animation **) animations; geo_obj_init_animation(&obj->header.gfx, &anims[animIndex]); obj->oSoundStateID = animIndex; } @@ -907,13 +908,9 @@ s32 count_objects_with_behavior(const BehaviorScript *behavior) { struct Object *cur_obj_find_nearby_held_actor(const BehaviorScript *behavior, f32 maxDist) { const BehaviorScript *behaviorAddr = segmented_to_virtual(behavior); - struct ObjectNode *listHead; - struct Object *obj; - struct Object *foundObj; - - listHead = &gObjectLists[OBJ_LIST_GENACTOR]; - obj = (struct Object *) listHead->next; - foundObj = NULL; + struct ObjectNode *listHead = &gObjectLists[OBJ_LIST_GENACTOR]; + struct Object *obj = (struct Object *) listHead->next; + struct Object *foundObj = NULL; while ((struct Object *) listHead != obj) { if (obj->behavior == behaviorAddr) { @@ -946,14 +943,14 @@ void cur_obj_change_action(s32 action) { cur_obj_reset_timer_and_subaction(); } -void cur_obj_set_vel_from_mario_vel(f32 f12, f32 f14) { - f32 sp4 = gMarioStates[0].forwardVel; - f32 sp0 = f12 * f14; +void cur_obj_set_vel_from_mario_vel(f32 objBaseForwardVel, f32 multiplier) { + f32 marioForwardVel = gMarioStates[0].forwardVel; + f32 objForwardVel = objBaseForwardVel * multiplier; - if (sp4 < sp0) { - o->oForwardVel = sp0; + if (marioForwardVel < objForwardVel) { + o->oForwardVel = objForwardVel; } else { - o->oForwardVel = sp4 * f14; + o->oForwardVel = marioForwardVel * multiplier; } } @@ -964,10 +961,12 @@ BAD_RETURN(s16) cur_obj_reverse_animation(void) { } BAD_RETURN(s32) cur_obj_extend_animation_if_at_end(void) { - s32 sp4 = o->header.gfx.animInfo.animFrame; + s32 animFrame = o->header.gfx.animInfo.animFrame; s32 sp0 = o->header.gfx.animInfo.curAnim->loopEnd - 2; - if (sp4 == sp0) o->header.gfx.animInfo.animFrame--; + if (animFrame == sp0) { + o->header.gfx.animInfo.animFrame--; + } } s32 cur_obj_check_if_near_animation_end(void) { @@ -1056,7 +1055,7 @@ void cur_obj_set_y_vel_and_animation(f32 yVel, s32 animIndex) { void cur_obj_unrender_set_action_and_anim(s32 animIndex, s32 action) { cur_obj_become_intangible(); cur_obj_disable_rendering(); - + // only set animation if non-negative value if (animIndex >= 0) { cur_obj_init_animation_with_sound(animIndex); @@ -1549,8 +1548,8 @@ void cur_obj_set_pos_to_home(void) { void cur_obj_set_pos_to_home_and_stop(void) { cur_obj_set_pos_to_home(); - o->oForwardVel = 0; - o->oVelY = 0; + o->oForwardVel = 0.0f; + o->oVelY = 0.0f; } void cur_obj_shake_y(f32 amount) { @@ -1588,7 +1587,7 @@ void cur_obj_set_hurtbox_radius_and_height(f32 radius, f32 height) { o->hurtboxHeight = height; } -static void obj_spawn_loot_coins(struct Object *obj, s32 numCoins, f32 sp30, +static void obj_spawn_loot_coins(struct Object *obj, s32 numCoins, f32 baseVelY, const BehaviorScript *coinBehavior, s16 posJitter, s16 model) { s32 i; @@ -1611,16 +1610,16 @@ static void obj_spawn_loot_coins(struct Object *obj, s32 numCoins, f32 sp30, coin = spawn_object(obj, model, coinBehavior); obj_translate_xz_random(coin, posJitter); coin->oPosY = spawnHeight; - coin->oCoinUnk110 = sp30; + coin->oCoinBaseVelY = baseVelY; } } -void obj_spawn_loot_blue_coins(struct Object *obj, s32 numCoins, f32 sp28, s16 posJitter) { - obj_spawn_loot_coins(obj, numCoins, sp28, bhvBlueCoinJumping, posJitter, MODEL_BLUE_COIN); +void obj_spawn_loot_blue_coins(struct Object *obj, s32 numCoins, f32 baseVelY, s16 posJitter) { + obj_spawn_loot_coins(obj, numCoins, baseVelY, bhvBlueCoinJumping, posJitter, MODEL_BLUE_COIN); } -void obj_spawn_loot_yellow_coins(struct Object *obj, s32 numCoins, f32 sp28) { - obj_spawn_loot_coins(obj, numCoins, sp28, bhvSingleCoinGetsSpawned, 0, MODEL_YELLOW_COIN); +void obj_spawn_loot_yellow_coins(struct Object *obj, s32 numCoins, f32 baseVelY) { + obj_spawn_loot_coins(obj, numCoins, baseVelY, bhvSingleCoinGetsSpawned, 0, MODEL_YELLOW_COIN); } void cur_obj_spawn_loot_coin_at_mario_pos(void) { @@ -2105,7 +2104,7 @@ void cur_obj_spawn_particles(struct SpawnParticlesInfo *info) { particle = spawn_object(o, info->model, bhvWhitePuffExplosion); - particle->oBehParams2ndByte = info->behParam; + particle->oBhvParams2ndByte = info->bhvParam; particle->oMoveAngleYaw = random_u16(); particle->oGravity = info->gravity; particle->oDragStrength = info->dragStrength; @@ -2193,9 +2192,9 @@ void spawn_mist_particles(void) { spawn_mist_particles_variable(0, 0, 46.0f); } -void spawn_mist_particles_with_sound(u32 sp18) { +void spawn_mist_particles_with_sound(u32 soundMagic) { spawn_mist_particles_variable(0, 0, 46.0f); - create_sound_spawner(sp18); + create_sound_spawner(soundMagic); } void cur_obj_push_mario_away(f32 radius) { @@ -2238,30 +2237,30 @@ void bhv_dust_smoke_loop(void) { UNUSED static void stub_obj_helpers_2(void) { } -s32 cur_obj_set_direction_table(s8 *a0) { - o->oToxBoxMovementPattern = a0; - o->oToxBoxMovementStep = 0; +s32 cur_obj_set_action_table(s8 *actionTable) { + o->oToxBoxActionTable = actionTable; + o->oToxBoxActionStep = 0; - return *(s8 *) o->oToxBoxMovementPattern; + return *(s8 *) o->oToxBoxActionTable; } -s32 cur_obj_progress_direction_table(void) { - s8 spF; - s8 *sp8 = o->oToxBoxMovementPattern; - s32 sp4 = o->oToxBoxMovementStep + 1; +s32 cur_obj_progress_action_table(void) { + s8 nextAction; + s8 *actionTable = o->oToxBoxActionTable; + s32 nextActionIndex = o->oToxBoxActionStep + 1; - if (sp8[sp4] != -1) { - spF = sp8[sp4]; - o->oToxBoxMovementStep++; + if (actionTable[nextActionIndex] != TOX_BOX_ACT_TABLE_END) { + nextAction = actionTable[nextActionIndex]; + o->oToxBoxActionStep++; } else { - spF = sp8[0]; - o->oToxBoxMovementStep = 0; + nextAction = actionTable[0]; + o->oToxBoxActionStep = 0; } - return spF; + return nextAction; } -void stub_obj_helpers_3(UNUSED s32 sp0, UNUSED s32 sp4) { +void stub_obj_helpers_3(UNUSED s32 arg0, UNUSED s32 arg1) { } void cur_obj_scale_over_time(s32 a0, s32 a1, f32 sp10, f32 sp14) { @@ -2318,7 +2317,7 @@ s32 jiggle_bbh_stair(s32 a0) { return TRUE; } - o->oPosY += sBbhStairJiggleOffsets[a0]; + o->oPosY += sBBHStairJiggleOffsets[a0]; return FALSE; } @@ -2330,8 +2329,8 @@ void cur_obj_call_action_function(void (*actionFunctions[])(void)) { static struct Object *spawn_star_with_no_lvl_exit(s32 sp20, s32 sp24) { struct Object *sp1C = spawn_object(o, MODEL_STAR, bhvSpawnedStarNoLevelExit); sp1C->oSparkleSpawnUnk1B0 = sp24; - sp1C->oBehParams = o->oBehParams; - sp1C->oBehParams2ndByte = sp20; + sp1C->oBhvParams = o->oBhvParams; + sp1C->oBhvParams2ndByte = sp20; return sp1C; } @@ -2461,9 +2460,8 @@ s32 cur_obj_set_hitbox_and_die_if_attacked(struct ObjectHitbox *hitbox, s32 deat return interacted; } - -void obj_explode_and_spawn_coins(f32 sp18, s32 sp1C) { - spawn_mist_particles_variable(0, 0, sp18); +void obj_explode_and_spawn_coins(f32 mistParticleSize, s32 sp1C) { + spawn_mist_particles_variable(0, 0, mistParticleSize); spawn_triangle_break_particles(30, MODEL_DIRT_ANIMATION, 3.0f, 4); obj_mark_for_deletion(o); @@ -2824,8 +2822,8 @@ s32 cur_obj_was_attacked_or_ground_pounded(void) { } void obj_copy_behavior_params(struct Object *dst, struct Object *src) { - dst->oBehParams = src->oBehParams; - dst->oBehParams2ndByte = src->oBehParams2ndByte; + dst->oBhvParams = src->oBhvParams; + dst->oBhvParams2ndByte = src->oBhvParams2ndByte; } void cur_obj_init_animation_and_anim_frame(s32 animIndex, s32 animFrame) { @@ -2900,7 +2898,7 @@ s32 cur_obj_check_interacted(void) { void cur_obj_spawn_loot_blue_coin(void) { if (o->oNumLootCoins >= 5) { - spawn_object(o, MODEL_BLUE_COIN, bhvMrIBlueCoin); + spawn_object(o, MODEL_BLUE_COIN, bhvSpawnedBlueCoin); o->oNumLootCoins -= 5; } } diff --git a/src/game/object_helpers.h b/src/game/object_helpers.h index fcd985b4..187468a6 100644 --- a/src/game/object_helpers.h +++ b/src/game/object_helpers.h @@ -49,7 +49,7 @@ struct Struct802A272C { }; struct SpawnParticlesInfo { - /*0x00*/ s8 behParam; + /*0x00*/ s8 bhvParam; /*0x01*/ s8 count; /*0x02*/ u8 model; /*0x03*/ s8 offsetY; @@ -139,7 +139,7 @@ s32 count_unimportant_objects(void); s32 count_objects_with_behavior(const BehaviorScript *behavior); struct Object *cur_obj_find_nearby_held_actor(const BehaviorScript *behavior, f32 maxDist); void cur_obj_change_action(s32 action); -void cur_obj_set_vel_from_mario_vel(f32 f12,f32 f14); +void cur_obj_set_vel_from_mario_vel(f32 objBaseForwardVel, f32 multiplier); BAD_RETURN(s16) cur_obj_reverse_animation(void); BAD_RETURN(s32) cur_obj_extend_animation_if_at_end(void); s32 cur_obj_check_if_near_animation_end(void); @@ -182,12 +182,12 @@ void cur_obj_set_pos_to_home(void); void cur_obj_set_pos_to_home_and_stop(void); void cur_obj_shake_y(f32 amount); void cur_obj_start_cam_event(UNUSED struct Object *obj, s32 cameraEvent); -void set_mario_interact_true_if_in_range(UNUSED s32 sp0, UNUSED s32 sp4, f32 sp8); +void set_mario_interact_true_if_in_range(UNUSED s32 arg0, UNUSED s32 arg1, f32 range); void obj_set_billboard(struct Object *obj); void cur_obj_set_hitbox_radius_and_height(f32 radius, f32 height); void cur_obj_set_hurtbox_radius_and_height(f32 radius, f32 height); -void obj_spawn_loot_blue_coins(struct Object *obj, s32 numCoins, f32 sp28, s16 posJitter); -void obj_spawn_loot_yellow_coins(struct Object *obj, s32 numCoins, f32 sp28); +void obj_spawn_loot_blue_coins(struct Object *obj, s32 numCoins, f32 baseVelY, s16 posJitter); +void obj_spawn_loot_yellow_coins(struct Object *obj, s32 numCoins, f32 baseVelY); void cur_obj_spawn_loot_coin_at_mario_pos(void); s32 cur_obj_advance_looping_anim(void); s32 cur_obj_resolve_wall_collisions(void); @@ -229,12 +229,12 @@ s32 absi(s32 a0); s32 cur_obj_wait_then_blink(s32 timeUntilBlinking, s32 numBlinks); s32 cur_obj_is_mario_ground_pounding_platform(void); void spawn_mist_particles(void); -void spawn_mist_particles_with_sound(u32 sp18); +void spawn_mist_particles_with_sound(u32 soundMagic); void cur_obj_push_mario_away(f32 radius); void cur_obj_push_mario_away_from_cylinder(f32 radius, f32 extentY); -s32 cur_obj_set_direction_table(s8 *a0); -s32 cur_obj_progress_direction_table(void); -void stub_obj_helpers_3(UNUSED s32 sp0, UNUSED s32 sp4); +s32 cur_obj_set_action_table(s8 *actionTable); +s32 cur_obj_progress_action_table(void); +void stub_obj_helpers_3(UNUSED s32 arg0, UNUSED s32 arg1); void cur_obj_scale_over_time(s32 a0, s32 a1, f32 sp10, f32 sp14); void cur_obj_set_pos_to_home_with_debug(void); s32 cur_obj_is_mario_on_platform(void); @@ -247,7 +247,7 @@ s32 is_mario_moving_fast_or_in_air(s32 speedThreshold); s32 is_item_in_array(s8 item, s8 *array); void cur_obj_enable_rendering_if_mario_in_room(void); s32 cur_obj_set_hitbox_and_die_if_attacked(struct ObjectHitbox *hitbox, s32 deathSound, s32 noLootCoins); -void obj_explode_and_spawn_coins(f32 sp18, s32 sp1C); +void obj_explode_and_spawn_coins(f32 mistParticleSize, s32 sp1C); void obj_set_collision_data(struct Object *obj, const void *segAddr); void cur_obj_if_hit_wall_bounce_away(void); s32 cur_obj_hide_if_mario_far_away_y(f32 distY); diff --git a/src/game/object_list_processor.c b/src/game/object_list_processor.c index 80a49fb6..a2590a22 100644 --- a/src/game/object_list_processor.c +++ b/src/game/object_list_processor.c @@ -146,9 +146,9 @@ struct MemoryPool *gObjectMemoryPool; s16 gCheckingSurfaceCollisionsForCamera; s16 gFindFloorIncludeSurfaceIntangible; -s16 *gEnvironmentRegions; +TerrainData *gEnvironmentRegions; s32 gEnvironmentLevels[20]; -s8 gDoorAdjacentRooms[60][2]; +RoomData gDoorAdjacentRooms[60][2]; s16 gMarioCurrentRoom; s16 D_8035FEE2; s16 D_8035FEE4; @@ -483,10 +483,10 @@ void spawn_objects_from_info(UNUSED s32 unused, struct SpawnInfo *spawnInfo) { // Behavior parameters are often treated as four separate bytes, but // are stored as an s32. - object->oBehParams = spawnInfo->behaviorArg; + object->oBhvParams = spawnInfo->behaviorArg; // The second byte of the behavior parameters is copied over to a special field // as it is the most frequently used by objects. - object->oBehParams2ndByte = ((spawnInfo->behaviorArg) >> 16) & 0xFF; + object->oBhvParams2ndByte = ((spawnInfo->behaviorArg) >> 16) & 0xFF; object->behavior = script; object->unused1 = 0; diff --git a/src/game/object_list_processor.h b/src/game/object_list_processor.h index aed11fb9..5bea549f 100644 --- a/src/game/object_list_processor.h +++ b/src/game/object_list_processor.h @@ -99,9 +99,9 @@ extern struct MemoryPool *gObjectMemoryPool; extern s16 gCheckingSurfaceCollisionsForCamera; extern s16 gFindFloorIncludeSurfaceIntangible; -extern s16 *gEnvironmentRegions; +extern TerrainData *gEnvironmentRegions; extern s32 gEnvironmentLevels[20]; -extern s8 gDoorAdjacentRooms[60][2]; +extern RoomData gDoorAdjacentRooms[60][2]; extern s16 gMarioCurrentRoom; extern s16 D_8035FEE2; extern s16 D_8035FEE4; diff --git a/src/game/paintings.c b/src/game/paintings.c index 481db8f3..08706d9a 100644 --- a/src/game/paintings.c +++ b/src/game/paintings.c @@ -162,9 +162,9 @@ struct Painting *gRipplingPainting; /** * Whether the DDD painting is moved forward, should being moving backwards, or has already moved backwards. */ -s8 gDddPaintingStatus; +s8 gDDDPaintingStatus; -struct Painting *sHmcPaintings[] = { +struct Painting *sHMCPaintings[] = { &cotmc_painting, NULL, }; @@ -175,15 +175,15 @@ struct Painting *sInsideCastlePaintings[] = { &ttm_painting, &ttc_painting, &sl_painting, &thi_huge_painting, NULL, }; -struct Painting *sTtmPaintings[] = { +struct Painting *sTTMPaintings[] = { &ttm_slide_painting, NULL, }; struct Painting **sPaintingGroups[] = { - sHmcPaintings, + sHMCPaintings, sInsideCastlePaintings, - sTtmPaintings, + sTTMPaintings, }; s16 gPaintingUpdateCounter = 1; @@ -1102,7 +1102,7 @@ void reset_painting(struct Painting *painting) { * When the painting reaches backPos, a save flag is set so that the painting will spawn at backPos * whenever it loads. * - * This function also sets gDddPaintingStatus, which controls the warp: + * This function also sets gDDDPaintingStatus, which controls the warp: * 0 (0b00): set x coordinate to frontPos * 2 (0b10): set x coordinate to backPos * 3 (0b11): same as 2. Bit 0 is ignored @@ -1120,12 +1120,12 @@ void move_ddd_painting(struct Painting *painting, f32 frontPos, f32 backPos, f32 if (!bowsersSubBeaten && !dddBack) { // If we haven't collected the star or moved the painting, put the painting at the front painting->posX = frontPos; - gDddPaintingStatus = 0; + gDDDPaintingStatus = 0; } else if (bowsersSubBeaten && !dddBack) { // If we've collected the star but not moved the painting back, // Each frame, move the painting by a certain speed towards the back area. painting->posX += speed; - gDddPaintingStatus = BOWSERS_SUB_BEATEN; + gDDDPaintingStatus = BOWSERS_SUB_BEATEN; if (painting->posX >= backPos) { painting->posX = backPos; // Tell the save file that we've moved DDD back. @@ -1134,7 +1134,7 @@ void move_ddd_painting(struct Painting *painting, f32 frontPos, f32 backPos, f32 } else if (bowsersSubBeaten && dddBack) { // If the painting has already moved back, place it in the back position. painting->posX = backPos; - gDddPaintingStatus = BOWSERS_SUB_BEATEN | DDD_BACK; + gDDDPaintingStatus = BOWSERS_SUB_BEATEN | DDD_BACK; } } diff --git a/src/game/paintings.h b/src/game/paintings.h index 8c930331..10fcd819 100644 --- a/src/game/paintings.h +++ b/src/game/paintings.h @@ -132,7 +132,7 @@ extern f32 gPaintingMarioZPos; extern struct PaintingMeshVertex *gPaintingMesh; extern Vec3f *gPaintingTriNorms; extern struct Painting *gRipplingPainting; -extern s8 gDddPaintingStatus; +extern s8 gDDDPaintingStatus; Gfx *geo_painting_draw(s32 callContext, struct GraphNode *node, UNUSED void *context); Gfx *geo_painting_update(s32 callContext, UNUSED struct GraphNode *node, UNUSED Mat4 c); diff --git a/src/game/print.c b/src/game/print.c index c804cb4a..d02b39a5 100644 --- a/src/game/print.c +++ b/src/game/print.c @@ -2,6 +2,7 @@ #include #include "config.h" +#include "gfx_dimensions.h" #include "game_init.h" #include "memory.h" #include "print.h" @@ -23,7 +24,7 @@ struct TextLabel { * Stores the text to be rendered on screen * and how they are to be rendered. */ -struct TextLabel *sTextLabels[52]; +FORCE_BSS struct TextLabel *sTextLabels[52]; s16 sTextLabelsCount = 0; /** @@ -98,11 +99,10 @@ void format_integer(s32 n, s32 base, char *dest, s32 *totalLength, u8 width, s8 powBase = int_pow(base, i); digit = n / powBase; - // FIXME: Why doesn't [] match? if (digit < 10) { - *(dest + len + numDigits - 1 - i) = digit + '0'; + *(dest + len + (numDigits - 1) - i) = digit + '0'; } else { - *(dest + len + numDigits - 1 - i) = digit + '7'; + *(dest + len + (numDigits - 1) - i) = digit + '7'; } n -= digit * powBase; @@ -153,7 +153,7 @@ void parse_width_field(const char *str, s32 *srcIndex, u8 *width, s8 *zeroPad) { // Sum the digits to calculate the total width. for (i = 0; i < digitsLen - 1; i++) { - *width = *width + digits[i] * ((digitsLen - i - 1) * 10); + *width = *width + ((digitsLen - i - 1) * 10) * digits[i]; } *width = *width + digits[digitsLen - 1]; @@ -185,7 +185,7 @@ void print_text_fmt_int(s32 x, s32 y, const char *str, s32 n) { c = str[srcIndex]; - while (c != 0) { + while (c != '\0') { if (c == '%') { srcIndex++; @@ -236,7 +236,7 @@ void print_text(s32 x, s32 y, const char *str) { c = str[srcIndex]; // Set the array with the text to print while finding length. - while (c != 0) { + while (c != '\0') { sTextLabels[sTextLabelsCount]->buffer[length] = c; length++; srcIndex++; @@ -256,6 +256,9 @@ void print_text_centered(s32 x, s32 y, const char *str) { UNUSED s32 unused2 = 0; s32 length = 0; s32 srcIndex = 0; +#ifdef VERSION_CN + s32 width = 0; +#endif // Don't continue if there is no memory to do so. if ((sTextLabels[sTextLabelsCount] = mem_pool_alloc(gEffectsMemoryPool, @@ -266,7 +269,14 @@ void print_text_centered(s32 x, s32 y, const char *str) { c = str[srcIndex]; // Set the array with the text to print while finding length. - while (c != 0) { + while (c != '\0') { +#ifdef VERSION_CN + if ((u8) c == 0xB0 || (u8) c == 0xC0) { + width = 16; + } else { + width = 12; + } +#endif sTextLabels[sTextLabelsCount]->buffer[length] = c; length++; srcIndex++; @@ -274,7 +284,11 @@ void print_text_centered(s32 x, s32 y, const char *str) { } sTextLabels[sTextLabelsCount]->length = length; - sTextLabels[sTextLabelsCount]->x = x - length * 12 / 2; +#ifdef VERSION_CN + sTextLabels[sTextLabelsCount]->x = x - width * length / 2; +#else + sTextLabels[sTextLabelsCount]->x = x - 12 * length / 2; +#endif sTextLabels[sTextLabelsCount]->y = y; sTextLabelsCount++; } @@ -353,7 +367,11 @@ void add_glyph_texture(s8 glyphIndex) { const u8 *const *glyphs = segmented_to_virtual(main_hud_lut); gDPPipeSync(gDisplayListHead++); +#ifdef VERSION_CN + gDPSetTextureImage(gDisplayListHead++, G_IM_FMT_RGBA, G_IM_SIZ_16b, 1, glyphs[(u8) glyphIndex]); +#else gDPSetTextureImage(gDisplayListHead++, G_IM_FMT_RGBA, G_IM_SIZ_16b, 1, glyphs[glyphIndex]); +#endif gSPDisplayList(gDisplayListHead++, dl_hud_img_load_tex_block); } @@ -383,8 +401,13 @@ void clip_to_bounds(s32 *x, s32 *y) { /** * Renders the glyph that's set at the given position. */ +#ifdef VERSION_CN +void render_textrect(s32 x, s32 y, s32 pos, s32 width) { + s32 rectBaseX = x + pos * width; +#else void render_textrect(s32 x, s32 y, s32 pos) { s32 rectBaseX = x + pos * 12; +#endif s32 rectBaseY = 224 - y; s32 rectX; s32 rectY; @@ -427,7 +450,19 @@ void render_text_labels(void) { for (i = 0; i < sTextLabelsCount; i++) { for (j = 0; j < sTextLabels[i]->length; j++) { +#ifdef VERSION_CN + if ((u8) sTextLabels[i]->buffer[j] < 0xA0) { + glyphIndex = char_to_glyph_index(sTextLabels[i]->buffer[j]); + } else if ((u8) sTextLabels[i]->buffer[j] == 0xB0) { + glyphIndex = 0xB0; + } else if ((u8) sTextLabels[i]->buffer[j] == 0xC0) { + glyphIndex = 0xC0; + } else { + glyphIndex = GLYPH_SPACE; + } +#else glyphIndex = char_to_glyph_index(sTextLabels[i]->buffer[j]); +#endif if (glyphIndex != GLYPH_SPACE) { #ifdef VERSION_EU @@ -443,6 +478,37 @@ void render_text_labels(void) { add_glyph_texture(glyphIndex); render_textrect(sTextLabels[i]->x, sTextLabels[i]->y, j); } +#elif defined(VERSION_CN) + if ((u8) glyphIndex == 0xB0) { + add_glyph_texture(0x92); + render_textrect(45, 50, 0, 16); + add_glyph_texture(0x93); + render_textrect(45, 50, 1, 16); + add_glyph_texture(0x94); + render_textrect(45, 34, 0, 16); + add_glyph_texture(0x95); + render_textrect(45, 34, 1, 16); + } else if ((u8) glyphIndex == 0xC0) { + add_glyph_texture(0xAE); + render_textrect(GFX_DIMENSIONS_RECT_FROM_RIGHT_EDGE(150), 193, 0, 16); + add_glyph_texture(0xAF); + render_textrect(GFX_DIMENSIONS_RECT_FROM_RIGHT_EDGE(150), 193, 1, 16); + add_glyph_texture(0xB0); + render_textrect(GFX_DIMENSIONS_RECT_FROM_RIGHT_EDGE(150), 177, 0, 16); + add_glyph_texture(0xB1); + render_textrect(GFX_DIMENSIONS_RECT_FROM_RIGHT_EDGE(150), 177, 1, 16); + add_glyph_texture(0xB2); + render_textrect(GFX_DIMENSIONS_RECT_FROM_RIGHT_EDGE(150), 193, 2, 16); + add_glyph_texture(0xB3); + render_textrect(GFX_DIMENSIONS_RECT_FROM_RIGHT_EDGE(150), 193, 3, 16); + add_glyph_texture(0xB4); + render_textrect(GFX_DIMENSIONS_RECT_FROM_RIGHT_EDGE(150), 177, 2, 16); + add_glyph_texture(0xB5); + render_textrect(GFX_DIMENSIONS_RECT_FROM_RIGHT_EDGE(150), 177, 3, 16); + } else { + add_glyph_texture(glyphIndex); + render_textrect(sTextLabels[i]->x, sTextLabels[i]->y, j, 12); + } #else add_glyph_texture(glyphIndex); render_textrect(sTextLabels[i]->x, sTextLabels[i]->y, j); diff --git a/src/game/rendering_graph_node.c b/src/game/rendering_graph_node.c index 8ea0d399..23430689 100644 --- a/src/game/rendering_graph_node.c +++ b/src/game/rendering_graph_node.c @@ -455,12 +455,15 @@ static void geo_process_billboard(struct GraphNodeBillboard *node) { mtxf_to_mtx(mtx, gMatStack[gMatStackIndex]); gMatStackFixed[gMatStackIndex] = mtx; + if (node->displayList != NULL) { geo_append_display_list(node->displayList, node->node.flags >> 8); } + if (node->node.children != NULL) { geo_process_node_and_siblings(node->node.children); } + gMatStackIndex--; } @@ -704,6 +707,7 @@ static void geo_process_shadow(struct GraphNodeShadow *node) { gMatStackIndex--; } } + if (node->node.children != NULL) { geo_process_node_and_siblings(node->node.children); } diff --git a/src/game/rumble_init.c b/src/game/rumble_init.c index 6c89f86f..d9fb4619 100644 --- a/src/game/rumble_init.c +++ b/src/game/rumble_init.c @@ -1,39 +1,34 @@ +#include "config.h" + +#if ENABLE_RUMBLE + #include +#include #include "macros.h" #include "buffers/buffers.h" #include "main.h" #include "rumble_init.h" -#include "config.h" -#if ENABLE_RUMBLE +FORCE_BSS OSThread gRumblePakThread; -OSThread gRumblePakThread; +FORCE_BSS OSPfs gRumblePakPfs; -s32 gRumblePakPfs; // Actually an OSPfs but we don't have that header yet +FORCE_BSS OSMesg gRumblePakSchedulerMesgBuf; +FORCE_BSS OSMesgQueue gRumblePakSchedulerMesgQueue; +FORCE_BSS OSMesg gRumbleThreadVIMesgBuf; +FORCE_BSS OSMesgQueue gRumbleThreadVIMesgQueue; -s8 D_SH_8031D8F8[0x60]; - -OSMesg gRumblePakSchedulerMesgBuf[1]; -OSMesgQueue gRumblePakSchedulerMesgQueue; -OSMesg gRumbleThreadVIMesgBuf[1]; -OSMesgQueue gRumbleThreadVIMesgQueue; - -struct RumbleData gRumbleDataQueue[3]; -struct StructSH8031D9B0 gCurrRumbleSettings; +FORCE_BSS struct RumbleData gRumbleDataQueue[3]; +FORCE_BSS struct StructSH8031D9B0 gCurrRumbleSettings; s32 sRumblePakThreadActive = FALSE; s32 sRumblePakActive = FALSE; s32 sRumblePakErrorCount = 0; s32 gRumblePakTimer = 0; -// These void* are OSPfs* but we don't have that header -extern s32 osMotorStop(void *); -extern s32 osMotorStart(void *); -extern u32 osMotorInit(OSMesgQueue *, void *, s32); - void init_rumble_pak_scheduler_queue(void) { - osCreateMesgQueue(&gRumblePakSchedulerMesgQueue, gRumblePakSchedulerMesgBuf, 1); + osCreateMesgQueue(&gRumblePakSchedulerMesgQueue, &gRumblePakSchedulerMesgBuf, 1); osSendMesg(&gRumblePakSchedulerMesgQueue, (OSMesg) 0, OS_MESG_NOBLOCK); } @@ -53,7 +48,11 @@ static void start_rumble(void) { block_until_rumble_pak_free(); +#ifdef VERSION_CN + if (!__osMotorAccess(&gRumblePakPfs, MOTOR_START)) { +#else if (!osMotorStart(&gRumblePakPfs)) { +#endif sRumblePakErrorCount = 0; } else { sRumblePakErrorCount++; @@ -69,7 +68,11 @@ static void stop_rumble(void) { block_until_rumble_pak_free(); +#ifdef VERSION_CN + if (!__osMotorAccess(&gRumblePakPfs, MOTOR_STOP)) { +#else if (!osMotorStop(&gRumblePakPfs)) { +#endif sRumblePakErrorCount = 0; } else { sRumblePakErrorCount++; @@ -241,10 +244,13 @@ void func_sh_8024CA04(void) { static void thread6_rumble_loop(UNUSED void *a0) { OSMesg msg; - cancel_rumble(); + CN_DEBUG_PRINTF(("start motor thread\n")); + cancel_rumble(); sRumblePakThreadActive = TRUE; + CN_DEBUG_PRINTF(("go motor thread\n")); + while (TRUE) { // Block until VI osRecvMesg(&gRumbleThreadVIMesgQueue, &msg, OS_MESG_BLOCK); @@ -257,7 +263,7 @@ static void thread6_rumble_loop(UNUSED void *a0) { sRumblePakActive = FALSE; } } else if (gNumVblanks % 60 == 0) { - sRumblePakActive = osMotorInit(&gSIEventMesgQueue, &gRumblePakPfs, gPlayer1Controller->port) < 1; + sRumblePakActive = osMotorInit(&gSIEventMesgQueue, &gRumblePakPfs, gPlayer1Controller->port) == 0; sRumblePakErrorCount = 0; } @@ -268,10 +274,14 @@ static void thread6_rumble_loop(UNUSED void *a0) { } void cancel_rumble(void) { - sRumblePakActive = osMotorInit(&gSIEventMesgQueue, &gRumblePakPfs, gPlayer1Controller->port) < 1; + sRumblePakActive = osMotorInit(&gSIEventMesgQueue, &gRumblePakPfs, gPlayer1Controller->port) == 0; if (sRumblePakActive) { +#ifdef VERSION_CN + __osMotorAccess(&gRumblePakPfs, MOTOR_STOP); +#else osMotorStop(&gRumblePakPfs); +#endif } gRumbleDataQueue[0].unk00 = 0; @@ -285,7 +295,7 @@ void cancel_rumble(void) { } void create_thread_6(void) { - osCreateMesgQueue(&gRumbleThreadVIMesgQueue, gRumbleThreadVIMesgBuf, 1); + osCreateMesgQueue(&gRumbleThreadVIMesgQueue, &gRumbleThreadVIMesgBuf, 1); osCreateThread(&gRumblePakThread, 6, thread6_rumble_loop, NULL, gThread6Stack + 0x2000, 30); osStartThread(&gRumblePakThread); } @@ -295,8 +305,10 @@ void rumble_thread_update_vi(void) { return; } - // 0x56525443 = 'VRTC' - osSendMesg(&gRumbleThreadVIMesgQueue, (OSMesg) 0x56525443, OS_MESG_NOBLOCK); +#pragma GCC diagnostic push +#pragma GCC diagnostic ignored "-Wmultichar" + osSendMesg(&gRumbleThreadVIMesgQueue, (OSMesg) 'VRTC', OS_MESG_NOBLOCK); +#pragma GCC diagnostic pop } #endif diff --git a/src/game/rumble_init.h b/src/game/rumble_init.h index cc47d75b..bc9b43e5 100644 --- a/src/game/rumble_init.h +++ b/src/game/rumble_init.h @@ -1,12 +1,40 @@ #ifndef RUMBLE_INIT_H #define RUMBLE_INIT_H -#include - #include "config.h" #if ENABLE_RUMBLE +struct RumbleData { + u8 unk00; + u8 unk01; + s16 unk02; + s16 unk04; +}; + +struct StructSH8031D9B0 { + s16 unk00; + s16 unk02; + s16 unk04; + s16 unk06; + s16 unk08; + s16 unk0A; + s16 unk0C; + s16 unk0E; +}; + +extern OSThread gRumblePakThread; + +extern OSPfs gRumblePakPfs; + +extern OSMesg gRumblePakSchedulerMesgBuf; +extern OSMesgQueue gRumblePakSchedulerMesgQueue; +extern OSMesg gRumbleThreadVIMesgBuf; +extern OSMesgQueue gRumbleThreadVIMesgQueue; + +extern struct RumbleData gRumbleDataQueue[3]; +extern struct StructSH8031D9B0 gCurrRumbleSettings; + extern s32 gRumblePakTimer; void init_rumble_pak_scheduler_queue(void); diff --git a/src/game/segment7.h b/src/game/segment7.h index 6692ac6b..54aceb64 100644 --- a/src/game/segment7.h +++ b/src/game/segment7.h @@ -24,8 +24,8 @@ extern const u8 eu_course_strings_de_table[]; #endif // from intro_segment7 -extern Gfx *intro_seg7_dl_0700B3A0; -extern Gfx *intro_seg7_dl_0700C6A0; +extern Gfx *intro_seg7_dl_logo; +extern Gfx *intro_seg7_dl_copyright; extern f32 intro_seg7_table_0700C790[]; extern f32 intro_seg7_table_0700C880[]; diff --git a/src/game/sound_init.c b/src/game/sound_init.c index c4bad21c..1ef5331b 100644 --- a/src/game/sound_init.c +++ b/src/game/sound_init.c @@ -349,7 +349,7 @@ void thread4_sound(UNUSED void *arg) { if (gResetTimer < 25) { struct SPTask *spTask; profiler_log_thread4_time(); - spTask = create_next_audio_frame_task(); + spTask = create_next_audio_frame_task(); if (spTask != NULL) { dispatch_audio_sptask(spTask); } diff --git a/src/goddard/draw_objects.c b/src/goddard/draw_objects.c index 85974d50..60c438e6 100644 --- a/src/goddard/draw_objects.c +++ b/src/goddard/draw_objects.c @@ -1,6 +1,10 @@ #include #include +#if defined(VERSION_JP) || defined(VERSION_US) +#include "prevent_bss_reordering.h" +#endif + #include "debug_utils.h" #include "dynlist_proc.h" #include "gd_macros.h" @@ -1269,7 +1273,7 @@ static void find_thisface_verts(struct ObjFace *face, struct ObjGroup *vertexGrp struct ListNode *node; for (i = 0; i < face->vtxCount; i++) { - // find the vertex or particle whose index in vertexGrp equals face->vertices[i] + // find the vertex or particle whose index in vertexGrp equals face->vertices[i] node = vertexGrp->firstMember; currIndex = 0; while (node != NULL) { diff --git a/src/goddard/dynlist_proc.c b/src/goddard/dynlist_proc.c index 82ddae28..f999c5a6 100644 --- a/src/goddard/dynlist_proc.c +++ b/src/goddard/dynlist_proc.c @@ -1228,7 +1228,7 @@ void d_map_materials(DynObjName name) { /** * For all faces in the current `ObjGroup`, resolve their vertex indices to - * `ObjVertex` pointers that point to vertices in the specified vertex group. + * `ObjVertex` pointers that point to vertices in the specified vertex group. * Also compute normals for all faces in the current `ObjGroup` and all vertices * in the specified vertex group. * See `map_vertices()` for more info. @@ -2635,7 +2635,7 @@ void d_set_parm_ptr(enum DParmPtr param, void *ptr) { fatal_printf("dsetparmp() too many points"); } // `ptr` here is a vertex index, not an actual pointer. - // These vertex indices later get converted to `ObjVertex` pointers when `find_thisface_verts` is called. + // These vertex indices later get converted to `ObjVertex` pointers when `find_thisface_verts` is called. ((struct ObjFace *) sDynListCurObj)->vertices[((struct ObjFace *) sDynListCurObj)->vtxCount++] = ptr; break; default: diff --git a/src/goddard/dynlists/dynlist_macros.h b/src/goddard/dynlists/dynlist_macros.h index decb8fa9..cbde7263 100644 --- a/src/goddard/dynlists/dynlist_macros.h +++ b/src/goddard/dynlists/dynlist_macros.h @@ -24,7 +24,7 @@ /** * Set the initial position of the current object - * Supported Objs: joints, particles, nets, vertices, cameras + * Supported Objs: joints, particles, nets, vertices, cameras */ #define SetInitialPosition(x, y, z) \ { 1, {0}, {0}, {(x), (y), (z)} } @@ -150,7 +150,7 @@ { 19, {0}, {(void *)(type)}, {0.0, 0.0, 0.0} } /** - * Set the current shape's material group to the specified group. + * Set the current shape's material group to the specified group. * Supported Objs: shapes */ #define SetMaterialGroup(mtlGrpName) \ diff --git a/src/goddard/dynlists/dynlist_mario_face.c b/src/goddard/dynlists/dynlist_mario_face.c index e742dd54..b504f785 100644 --- a/src/goddard/dynlists/dynlist_mario_face.c +++ b/src/goddard/dynlists/dynlist_mario_face.c @@ -354,7 +354,7 @@ struct DynList dynlist_mario_face_shape[] = { MakeDynObj(D_DATA_GRP, DYNOBJ_MARIO_FACE_TRI_GROUP), LinkWithPtr(&mario_Face_FaceInfo), - StartGroup(DYNOBJ_MARIO_FACE_MTL_GROUP), + StartGroup(DYNOBJ_MARIO_FACE_MTL_GROUP), // Teeth color MakeDynObj(D_MATERIAL, 0), SetId(0), @@ -366,7 +366,7 @@ struct DynList dynlist_mario_face_shape[] = { SetAmbient(0.883, 0.602, 0.408), SetDiffuse(0.883, 0.602, 0.408), // Shadow on back of hat - MakeDynObj(D_MATERIAL, 0), + MakeDynObj(D_MATERIAL, 0), SetId(2), SetAmbient(0.362, 0.0, 0.0), SetDiffuse(0.362, 0.0, 0.0), diff --git a/src/goddard/dynlists/dynlist_mario_master.c b/src/goddard/dynlists/dynlist_mario_master.c index 6a5b19ca..e359280b 100644 --- a/src/goddard/dynlists/dynlist_mario_master.c +++ b/src/goddard/dynlists/dynlist_mario_master.c @@ -1089,7 +1089,7 @@ struct DynList dynlist_mario_master[] = { AttachTo(0x0, DYNOBJ_MARIO_MAIN_ANIMATOR), SetNodeGroup(DYNOBJ_RIGHT_EYELID_ANIMDATA_GROUP), LinkWith(DYNOBJ_RIGHT_EYELID_JOINT_1), - + // whole head animator? MakeDynObj(D_DATA_GRP, DYNOBJ_MARIO_HEAD_ANIMDATA_GROUP), LinkWithPtr(&anim_mario_intro), diff --git a/src/goddard/gd_macros.h b/src/goddard/gd_macros.h index 9b65978d..afc4603b 100644 --- a/src/goddard/gd_macros.h +++ b/src/goddard/gd_macros.h @@ -3,7 +3,7 @@ /** * @file gd_macros.h - * + * * Common macros that Goddard used throughout the Mario Head subsytem code. */ diff --git a/src/goddard/gd_math.c b/src/goddard/gd_math.c index baf43dd8..7cbe0b30 100644 --- a/src/goddard/gd_math.c +++ b/src/goddard/gd_math.c @@ -514,7 +514,7 @@ f32 gd_mat4f_det(Mat4f *mtx) { * returns the determinant. */ f32 gd_3x3_det(f32 r0c0, f32 r0c1, f32 r0c2, - f32 r1c0, f32 r1c1, f32 r1c2, + f32 r1c0, f32 r1c1, f32 r1c2, f32 r2c0, f32 r2c1, f32 r2c2) { f32 det; @@ -654,7 +654,7 @@ void gd_shift_mat_up(Mat4f *mtx) { * | 0 w^2+i^2-j^2-k^2 2ij+2wk 2ik+2wj | * | 0 2ij-2wk w^2+j^2-i^2-k^2 2jk+2wi | * | 0 2ik+2wj 2jk-2wi w^2+k^2-i^2-j^2 | - * + * * Potentially broken if 'mtx' is not an identity matrix/zero'ed. */ void UNUSED gd_create_quat_rot_mat(f32 quat[4], UNUSED s32 unused, Mat4f *mtx) { @@ -698,10 +698,10 @@ void UNUSED gd_create_quat_rot_mat(f32 quat[4], UNUSED s32 unused, Mat4f *mtx) { * Creates a rotation matrix to multiply the primary matrix by. * s/c are sin(angle)/cos(angle). That angular rotation is about vector * 'vec'. - * + * * Matrix has form- * - * | (1-c)z^2+c (1-c)zy-sx (1-c)xz-sy 0 | + * | (1-c)z^2+c (1-c)zy-sx (1-c)xz-sy 0 | * | (1-c)zy-sx (1-c)y^2+c (1-c)xy-sz 0 | * | (1-c)xz-sy (1-c)xy-sz (1-c)x^2+c 0 | * | 0 0 0 1 | diff --git a/src/goddard/gd_math.h b/src/goddard/gd_math.h index 53c35397..1028dc83 100644 --- a/src/goddard/gd_math.h +++ b/src/goddard/gd_math.h @@ -24,7 +24,7 @@ enum GdRotAxis { void gd_adjunct_mat4f(Mat4f *src, Mat4f *dst); f32 gd_mat4f_det(Mat4f *mtx); f32 gd_3x3_det(f32 r0c0, f32 r0c1, f32 r0c2, - f32 r1c0, f32 r1c1, f32 r1c2, + f32 r1c0, f32 r1c1, f32 r1c2, f32 r2c0, f32 r2c1, f32 r2c2); f32 gd_2x2_det(f32 a, f32 b, f32 c, f32 d); diff --git a/src/goddard/gd_types.h b/src/goddard/gd_types.h index cff1fff6..f654ab85 100644 --- a/src/goddard/gd_types.h +++ b/src/goddard/gd_types.h @@ -472,7 +472,7 @@ struct ObjGadget { /* 0x38 */ f32 rangeMin; /* 0x3C */ f32 rangeMax; /* 0x40 */ struct GdVec3f size; // size (x = width, y = height) - /* 0x4C */ struct ObjGroup *valueGrp; // group containing `ObjValPtr`s controlled by this gadget + /* 0x4C */ struct ObjGroup *valueGrp; // group containing `ObjValPtr`s controlled by this gadget /* 0x50 */ struct ObjShape *shapePtr; /* 0x54 */ struct ObjGroup *unk54; //node group? /* 0x58 */ u8 filler2[4]; @@ -604,7 +604,7 @@ struct ObjValPtr { /* 0x14 */ struct GdObj *obj; // maybe just a void *? /* 0x18 */ uintptr_t offset; // value pointed to is `obj` + `offset` /* 0x1C */ enum ValPtrType datatype; - /* 0x20 */ s32 flag; // TODO: better name for this? If 0x40000, then `offset` is an offset to a field in `obj`. Otherwise, `obj` is NULL, and `offset` is the address of a variable. + /* 0x20 */ s32 flag; // TODO: better name for this? If 0x40000, then `offset` is an offset to a field in `obj`. Otherwise, `obj` is NULL, and `offset` is the address of a variable. }; /* sizeof = 0x24 */ enum GdLightFlags { diff --git a/src/goddard/joints.c b/src/goddard/joints.c index 00178efb..53dc6677 100644 --- a/src/goddard/joints.c +++ b/src/goddard/joints.c @@ -1,6 +1,6 @@ #include -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) #include "prevent_bss_reordering.h" #endif diff --git a/src/goddard/objects.c b/src/goddard/objects.c index b1d136cd..cb02381a 100644 --- a/src/goddard/objects.c +++ b/src/goddard/objects.c @@ -120,7 +120,7 @@ void get_some_bounding_box(struct GdBoundingBox *a0) { /* @ 22A6A0 for 0x24 */ void stub_objects_1(UNUSED struct ObjGroup *a0, UNUSED struct GdObj *a1) { - UNUSED u8 sp00[8]; + UNUSED u8 filler[8]; /* Debug stub? */ return; } @@ -870,8 +870,9 @@ s32 group_contains_obj(struct ObjGroup *group, struct GdObj *obj) { struct ListNode *node = group->firstMember; while (node != NULL) { - if (node->obj->index == obj->index) + if (node->obj->index == obj->index) { return TRUE; + } node = node->next; } @@ -879,7 +880,7 @@ s32 group_contains_obj(struct ObjGroup *group, struct GdObj *obj) { } /** - * Unused (not called) - this shows details about all objects in the main object linked list + * Unused (not called) - this shows details about all objects in the main object linked list */ void show_details(enum ObjTypeFlag type) { enum ObjTypeFlag curObjType; diff --git a/src/goddard/renderer.c b/src/goddard/renderer.c index 75ff7338..294f16c4 100644 --- a/src/goddard/renderer.c +++ b/src/goddard/renderer.c @@ -84,7 +84,7 @@ struct DynListBankInfo { }; // bss -#if defined(VERSION_EU) || defined(VERSION_SH) +#if defined(VERSION_EU) || defined(VERSION_SH) || defined(VERSION_CN) static OSMesgQueue D_801BE830; // controller msg queue static OSMesg D_801BE848[10]; u8 EUpad1[0x40]; @@ -506,11 +506,11 @@ static Gfx gd_dl_sparkle[] = { gsSPClearGeometryMode(G_TEXTURE_GEN | G_TEXTURE_GEN_LINEAR), gsDPSetRenderMode(G_RM_AA_ZB_TEX_EDGE, G_RM_NOOP2), gsSPTexture(0x8000, 0x8000, 0, G_TX_RENDERTILE, G_ON), - gsDPSetTile(G_IM_FMT_RGBA, G_IM_SIZ_16b, 0, 0, G_TX_LOADTILE, 0, G_TX_WRAP | G_TX_NOMIRROR, G_TX_NOMASK, G_TX_NOLOD, + gsDPSetTile(G_IM_FMT_RGBA, G_IM_SIZ_16b, 0, 0, G_TX_LOADTILE, 0, G_TX_WRAP | G_TX_NOMIRROR, G_TX_NOMASK, G_TX_NOLOD, G_TX_WRAP | G_TX_NOMIRROR, G_TX_NOMASK, G_TX_NOLOD), gsDPLoadSync(), gsDPLoadBlock(G_TX_LOADTILE, 0, 0, 32 * 32 - 1, CALC_DXT(32, G_IM_SIZ_16b_BYTES)), - gsDPSetTile(G_IM_FMT_RGBA, G_IM_SIZ_16b, 8, 0, G_TX_RENDERTILE, 0, G_TX_WRAP | G_TX_NOMIRROR, G_TX_NOMASK, G_TX_NOLOD, + gsDPSetTile(G_IM_FMT_RGBA, G_IM_SIZ_16b, 8, 0, G_TX_RENDERTILE, 0, G_TX_WRAP | G_TX_NOMIRROR, G_TX_NOMASK, G_TX_NOLOD, G_TX_WRAP | G_TX_NOMIRROR, G_TX_NOMASK, G_TX_NOLOD), gsDPSetTileSize(0, 0, 0, (32 - 1) << G_TEXTURE_IMAGE_FRAC, (32 - 1) << G_TEXTURE_IMAGE_FRAC), gsSPVertex(gd_vertex_sparkle, 4, 0), @@ -659,7 +659,7 @@ static Gfx gd_dl_mario_face_shine[] = { gsDPSetTexturePersp(G_TP_PERSP), gsDPSetTextureFilter(G_TF_BILERP), gsDPSetCombineMode(G_CC_HILITERGBA, G_CC_HILITERGBA), - gsDPLoadTextureBlock(gd_texture_mario_face_shine, G_IM_FMT_IA, G_IM_SIZ_8b, 32, 32, 0, + gsDPLoadTextureBlock(gd_texture_mario_face_shine, G_IM_FMT_IA, G_IM_SIZ_8b, 32, 32, 0, G_TX_WRAP | G_TX_NOMIRROR, G_TX_WRAP | G_TX_NOMIRROR, 5, 5, G_TX_NOLOD, G_TX_NOLOD), gsDPPipeSync(), gsSPEndDisplayList(), @@ -1278,7 +1278,7 @@ void gd_vblank(void) { } /** - * Copies the player1 controller data from p1cont to sGdContPads[0]. + * Copies the player1 controller data from p1cont to sGdContPads[0]. */ void gd_copy_p1_contpad(OSContPad *p1cont) { u32 i; // 24 @@ -2397,7 +2397,7 @@ void parse_p1_controller(void) { OSContPad *currInputs; OSContPad *prevInputs; - // Copy current inputs to previous + // Copy current inputs to previous u8 *src = (u8 *) gdctrl; u8 *dest = (u8 *) gdctrl->prevFrame; for (i = 0; i < sizeof(struct GdControl); i++) { @@ -3317,7 +3317,7 @@ void stub_renderer_14(UNUSED s8 *arg0) { * functions from IRIS GL. * @param buf pointer to an array of 16-bit values * @param len maximum number of values to store - */ + */ void init_pick_buf(s16 *buf, s32 len) { buf[0] = 0; buf[1] = 0; @@ -3776,7 +3776,7 @@ struct GdObj *load_dynlist(struct DynList *dynlist) { fatal_printf("load_dynlist() unkown bank"); } -#define PAGE_SIZE 65536 // size of a 64K TLB page +#define PAGE_SIZE 65536 // size of a 64K TLB page segSize = dynlistSegEnd - dynlistSegStart; allocSegSpace = gd_malloc_temp(segSize + PAGE_SIZE); diff --git a/src/goddard/shape_helper.c b/src/goddard/shape_helper.c index ee1dbf63..c811c918 100644 --- a/src/goddard/shape_helper.c +++ b/src/goddard/shape_helper.c @@ -161,7 +161,7 @@ void calc_face_normal(struct ObjFace *face) { p3.z = vtx3->pos.z; // calculate the cross product of edges (p2 - p1) and (p3 - p2) - // not sure why each component is multiplied by 1000. maybe to avoid loss of precision when normalizing? + // not sure why each component is multiplied by 1000. maybe to avoid loss of precision when normalizing? normal.x = (((p2.y - p1.y) * (p3.z - p2.z)) - ((p2.z - p1.z) * (p3.y - p2.y))) * mul; normal.y = (((p2.z - p1.z) * (p3.x - p2.x)) - ((p2.x - p1.x) * (p3.z - p2.z))) * mul; normal.z = (((p2.x - p1.x) * (p3.y - p2.y)) - ((p2.y - p1.y) * (p3.x - p2.x))) * mul; diff --git a/src/goddard/skin_movement.c b/src/goddard/skin_movement.c index 05cb7e31..8209d4b3 100644 --- a/src/goddard/skin_movement.c +++ b/src/goddard/skin_movement.c @@ -1,5 +1,9 @@ #include +#if defined(VERSION_SH) || defined(VERSION_CN) +#include "prevent_bss_reordering.h" +#endif + #include "debug_utils.h" #include "gd_math.h" #include "gd_types.h" diff --git a/src/menu/file_select.c b/src/menu/file_select.c index fce9a9e2..f06a09cf 100644 --- a/src/menu/file_select.c +++ b/src/menu/file_select.c @@ -28,6 +28,16 @@ #define LANGUAGE_FUNCTION sLanguageMode #endif +#ifdef VERSION_CN +#define FILE_SELECT_PRINT_STRING print_generic_string +#define FILE_SELECT_TEXT_DL_BEGIN dl_ia_text_begin +#define FILE_SELECT_TEXT_DL_END dl_ia_text_end +#else +#define FILE_SELECT_PRINT_STRING print_menu_generic_string +#define FILE_SELECT_TEXT_DL_BEGIN dl_menu_ia8_text_begin +#define FILE_SELECT_TEXT_DL_END dl_menu_ia8_text_end +#endif + /** * @file file_select.c * This file implements how the file select and it's menus render and function. @@ -60,6 +70,12 @@ static u8 sYesNoColor[2]; // The button that is selected when it is clicked. static s8 sSelectedButtonID = MENU_BUTTON_NONE; +// On iQue, the courses can't all fit on one screen; there are two pages, +// switched between with the L and R triggers. +#ifdef VERSION_CN +static s8 sScorePage = 0; +#endif + // Whether we are on the main menu or one of the submenus. static s8 sCurrentMenuLevel = MENU_LAYER_MAIN; @@ -126,163 +142,163 @@ static s8 sOpenLangSettings = FALSE; #endif #ifndef VERSION_EU -static unsigned char textReturn[] = { TEXT_RETURN }; +static u8 textReturn[] = { TEXT_RETURN }; #else -static unsigned char textReturn[][8] = {{ TEXT_RETURN }, { TEXT_RETURN_FR }, { TEXT_RETURN_DE }}; +static u8 textReturn[][8] = {{ TEXT_RETURN }, { TEXT_RETURN_FR }, { TEXT_RETURN_DE }}; #endif #ifndef VERSION_EU -static unsigned char textViewScore[] = { TEXT_CHECK_SCORE }; +static u8 textViewScore[] = { TEXT_CHECK_SCORE }; #else -static unsigned char textViewScore[][12] = {{ TEXT_CHECK_SCORE }, {TEXT_CHECK_SCORE_FR}, {TEXT_CHECK_SCORE_DE}}; +static u8 textViewScore[][12] = {{ TEXT_CHECK_SCORE }, {TEXT_CHECK_SCORE_FR}, {TEXT_CHECK_SCORE_DE}}; #endif #ifndef VERSION_EU -static unsigned char textCopyFileButton[] = { TEXT_COPY_FILE_BUTTON }; +static u8 textCopyFileButton[] = { TEXT_COPY_FILE_BUTTON }; #else -static unsigned char textCopyFileButton[][15] = {{ TEXT_COPY_FILE }, { TEXT_COPY_FILE_FR }, { TEXT_COPY_FILE_DE }}; +static u8 textCopyFileButton[][15] = {{ TEXT_COPY_FILE }, { TEXT_COPY_FILE_FR }, { TEXT_COPY_FILE_DE }}; #endif #ifndef VERSION_EU -static unsigned char textEraseFileButton[] = { TEXT_ERASE_FILE_BUTTON }; +static u8 textEraseFileButton[] = { TEXT_ERASE_FILE_BUTTON }; #else -static unsigned char textEraseFileButton[][16] = { {TEXT_ERASE_FILE}, {TEXT_ERASE_FILE_FR}, {TEXT_ERASE_FILE_DE} }; +static u8 textEraseFileButton[][16] = { {TEXT_ERASE_FILE}, {TEXT_ERASE_FILE_FR}, {TEXT_ERASE_FILE_DE} }; #endif #ifndef VERSION_EU -static unsigned char textSoundModes[][8] = { { TEXT_STEREO }, { TEXT_MONO }, { TEXT_HEADSET } }; +static u8 textSoundModes[][8] = { { TEXT_STEREO }, { TEXT_MONO }, { TEXT_HEADSET } }; #endif -static unsigned char textMarioA[] = { TEXT_FILE_MARIO_A }; -static unsigned char textMarioB[] = { TEXT_FILE_MARIO_B }; -static unsigned char textMarioC[] = { TEXT_FILE_MARIO_C }; -static unsigned char textMarioD[] = { TEXT_FILE_MARIO_D }; +static u8 textMarioA[] = { TEXT_FILE_MARIO_A }; +static u8 textMarioB[] = { TEXT_FILE_MARIO_B }; +static u8 textMarioC[] = { TEXT_FILE_MARIO_C }; +static u8 textMarioD[] = { TEXT_FILE_MARIO_D }; #ifndef VERSION_EU -static unsigned char textNew[] = { TEXT_NEW }; -static unsigned char starIcon[] = { GLYPH_STAR, GLYPH_SPACE }; -static unsigned char xIcon[] = { GLYPH_MULTIPLY, GLYPH_SPACE }; +static u8 textNew[] = { TEXT_NEW }; +static u8 starIcon[] = { GLYPH_STAR, GLYPH_SPACE }; +static u8 xIcon[] = { GLYPH_MULTIPLY, GLYPH_SPACE }; #endif #ifndef VERSION_EU -static unsigned char textSelectFile[] = { TEXT_SELECT_FILE }; +static u8 textSelectFile[] = { TEXT_SELECT_FILE }; #else -static unsigned char textSelectFile[][17] = {{ TEXT_SELECT_FILE }, { TEXT_SELECT_FILE_FR }, { TEXT_SELECT_FILE_DE }}; +static u8 textSelectFile[][17] = {{ TEXT_SELECT_FILE }, { TEXT_SELECT_FILE_FR }, { TEXT_SELECT_FILE_DE }}; #endif #ifndef VERSION_EU -static unsigned char textScore[] = { TEXT_SCORE }; +static u8 textScore[] = { TEXT_SCORE }; #else -static unsigned char textScore[][9] = {{ TEXT_SCORE }, { TEXT_SCORE_FR }, { TEXT_SCORE_DE }}; +static u8 textScore[][9] = {{ TEXT_SCORE }, { TEXT_SCORE_FR }, { TEXT_SCORE_DE }}; #endif #ifndef VERSION_EU -static unsigned char textCopy[] = { TEXT_COPY }; +static u8 textCopy[] = { TEXT_COPY }; #else -static unsigned char textCopy[][9] = {{ TEXT_COPY }, { TEXT_COPY_FR }, { TEXT_COPY_DE }}; +static u8 textCopy[][9] = {{ TEXT_COPY }, { TEXT_COPY_FR }, { TEXT_COPY_DE }}; #endif #ifndef VERSION_EU -static unsigned char textErase[] = { TEXT_ERASE }; +static u8 textErase[] = { TEXT_ERASE }; #else -static unsigned char textErase[][8] = {{ TEXT_ERASE }, { TEXT_ERASE_FR }, { TEXT_ERASE_DE }}; +static u8 textErase[][8] = {{ TEXT_ERASE }, { TEXT_ERASE_FR }, { TEXT_ERASE_DE }}; #endif #ifdef VERSION_EU -static unsigned char textOption[][9] = {{ TEXT_OPTION }, { TEXT_OPTION_FR }, { TEXT_OPTION_DE } }; +static u8 textOption[][9] = {{ TEXT_OPTION }, { TEXT_OPTION_FR }, { TEXT_OPTION_DE } }; #endif #ifndef VERSION_EU -static unsigned char textCheckFile[] = { TEXT_CHECK_FILE }; +static u8 textCheckFile[] = { TEXT_CHECK_FILE }; #else -static unsigned char textCheckFile[][18] = {{ TEXT_CHECK_FILE }, { TEXT_CHECK_FILE_FR }, { TEXT_CHECK_FILE_DE }}; +static u8 textCheckFile[][18] = {{ TEXT_CHECK_FILE }, { TEXT_CHECK_FILE_FR }, { TEXT_CHECK_FILE_DE }}; #endif #ifndef VERSION_EU -static unsigned char textNoSavedDataExists[] = { TEXT_NO_SAVED_DATA_EXISTS }; +static u8 textNoSavedDataExists[] = { TEXT_NO_SAVED_DATA_EXISTS }; #else -static unsigned char textNoSavedDataExists[][30] = {{ TEXT_NO_SAVED_DATA_EXISTS }, { TEXT_NO_SAVED_DATA_EXISTS_FR }, { TEXT_NO_SAVED_DATA_EXISTS_DE }}; +static u8 textNoSavedDataExists[][30] = {{ TEXT_NO_SAVED_DATA_EXISTS }, { TEXT_NO_SAVED_DATA_EXISTS_FR }, { TEXT_NO_SAVED_DATA_EXISTS_DE }}; #endif #ifndef VERSION_EU -static unsigned char textCopyFile[] = { TEXT_COPY_FILE }; +static u8 textCopyFile[] = { TEXT_COPY_FILE }; #else -static unsigned char textCopyFile[][16] = {{ TEXT_COPY_FILE_BUTTON }, { TEXT_COPY_FILE_BUTTON_FR }, { TEXT_COPY_FILE_BUTTON_DE }}; +static u8 textCopyFile[][16] = {{ TEXT_COPY_FILE_BUTTON }, { TEXT_COPY_FILE_BUTTON_FR }, { TEXT_COPY_FILE_BUTTON_DE }}; #endif #ifndef VERSION_EU -static unsigned char textCopyItToWhere[] = { TEXT_COPY_IT_TO_WHERE }; +static u8 textCopyItToWhere[] = { TEXT_COPY_IT_TO_WHERE }; #else -static unsigned char textCopyItToWhere[][18] = {{ TEXT_COPY_IT_TO_WHERE }, { TEXT_COPY_IT_TO_WHERE_FR }, { TEXT_COPY_IT_TO_WHERE_DE }}; +static u8 textCopyItToWhere[][18] = {{ TEXT_COPY_IT_TO_WHERE }, { TEXT_COPY_IT_TO_WHERE_FR }, { TEXT_COPY_IT_TO_WHERE_DE }}; +#endif + +#if !defined(VERSION_EU) +static u8 textNoSavedDataExistsCopy[] = { TEXT_NO_SAVED_DATA_EXISTS }; #endif #ifndef VERSION_EU -static unsigned char textNoSavedDataExistsCopy[] = { TEXT_NO_SAVED_DATA_EXISTS }; -#endif - -#ifndef VERSION_EU -static unsigned char textCopyCompleted[] = { TEXT_COPYING_COMPLETED }; +static u8 textCopyCompleted[] = { TEXT_COPYING_COMPLETED }; #else -static unsigned char textCopyCompleted[][18] = {{ TEXT_COPYING_COMPLETED }, { TEXT_COPYING_COMPLETED_FR }, { TEXT_COPYING_COMPLETED_DE }}; +static u8 textCopyCompleted[][18] = {{ TEXT_COPYING_COMPLETED }, { TEXT_COPYING_COMPLETED_FR }, { TEXT_COPYING_COMPLETED_DE }}; #endif #ifndef VERSION_EU -static unsigned char textSavedDataExists[] = { TEXT_SAVED_DATA_EXISTS }; +static u8 textSavedDataExists[] = { TEXT_SAVED_DATA_EXISTS }; #else -static unsigned char textSavedDataExists[][20] = {{ TEXT_SAVED_DATA_EXISTS }, { TEXT_SAVED_DATA_EXISTS_FR }, { TEXT_SAVED_DATA_EXISTS_DE }}; +static u8 textSavedDataExists[][20] = {{ TEXT_SAVED_DATA_EXISTS }, { TEXT_SAVED_DATA_EXISTS_FR }, { TEXT_SAVED_DATA_EXISTS_DE }}; #endif #ifndef VERSION_EU -static unsigned char textNoFileToCopyFrom[] = { TEXT_NO_FILE_TO_COPY_FROM }; +static u8 textNoFileToCopyFrom[] = { TEXT_NO_FILE_TO_COPY_FROM }; #else -static unsigned char textNoFileToCopyFrom[][21] = {{ TEXT_NO_FILE_TO_COPY_FROM }, { TEXT_NO_FILE_TO_COPY_FROM_FR }, { TEXT_NO_FILE_TO_COPY_FROM_DE }}; +static u8 textNoFileToCopyFrom[][21] = {{ TEXT_NO_FILE_TO_COPY_FROM }, { TEXT_NO_FILE_TO_COPY_FROM_FR }, { TEXT_NO_FILE_TO_COPY_FROM_DE }}; #endif #ifndef VERSION_EU -static unsigned char textYes[] = { TEXT_YES }; +static u8 textYes[] = { TEXT_YES }; #else -static unsigned char textYes[][4] = {{ TEXT_YES }, { TEXT_YES_FR }, { TEXT_YES_DE }}; +static u8 textYes[][4] = {{ TEXT_YES }, { TEXT_YES_FR }, { TEXT_YES_DE }}; #endif #ifndef VERSION_EU -static unsigned char textNo[] = { TEXT_NO }; +static u8 textNo[] = { TEXT_NO }; #else -static unsigned char textNo[][5] = {{ TEXT_NO }, { TEXT_NO_FR }, { TEXT_NO_DE }}; +static u8 textNo[][5] = {{ TEXT_NO }, { TEXT_NO_FR }, { TEXT_NO_DE }}; #endif #ifdef VERSION_EU // In EU, Erase File and Sound Select strings are outside it's print string function -static unsigned char textEraseFile[][17] = { +static u8 textEraseFile[][17] = { { TEXT_ERASE_FILE_BUTTON }, { TEXT_ERASE_FILE_BUTTON_FR }, { TEXT_ERASE_FILE_BUTTON_DE } }; -static unsigned char textSure[][8] = {{ TEXT_SURE }, { TEXT_SURE_FR }, { TEXT_SURE_DE }}; -static unsigned char textMarioAJustErased[][20] = { +static u8 textSure[][8] = {{ TEXT_SURE }, { TEXT_SURE_FR }, { TEXT_SURE_DE }}; +static u8 textMarioAJustErased[][20] = { { TEXT_FILE_MARIO_A_JUST_ERASED }, { TEXT_FILE_MARIO_A_JUST_ERASED_FR }, { TEXT_FILE_MARIO_A_JUST_ERASED_DE } }; -static unsigned char textSoundSelect[][13] = { +static u8 textSoundSelect[][13] = { { TEXT_SOUND_SELECT }, { TEXT_SOUND_SELECT_FR }, { TEXT_SOUND_SELECT_DE } }; -static unsigned char textLanguageSelect[][17] = { +static u8 textLanguageSelect[][17] = { { TEXT_LANGUAGE_SELECT }, { TEXT_LANGUAGE_SELECT_FR }, { TEXT_LANGUAGE_SELECT_DE } }; -static unsigned char textSoundModes[][10] = { +static u8 textSoundModes[][10] = { { TEXT_STEREO }, { TEXT_MONO }, { TEXT_HEADSET }, { TEXT_STEREO_FR }, { TEXT_MONO_FR }, { TEXT_HEADSET_FR }, { TEXT_STEREO_DE }, { TEXT_MONO_DE }, { TEXT_HEADSET_DE } }; -static unsigned char textLanguage[][9] = {{ TEXT_ENGLISH }, { TEXT_FRENCH }, { TEXT_GERMAN }}; +static u8 textLanguage[][9] = {{ TEXT_ENGLISH }, { TEXT_FRENCH }, { TEXT_GERMAN }}; -static unsigned char textMario[] = { TEXT_MARIO }; -static unsigned char textHiScore[][15] = {{ TEXT_HI_SCORE }, { TEXT_HI_SCORE_FR }, { TEXT_HI_SCORE_DE }}; -static unsigned char textMyScore[][10] = {{ TEXT_MY_SCORE }, { TEXT_MY_SCORE_FR }, { TEXT_MY_SCORE_DE }}; +static u8 textMario[] = { TEXT_MARIO }; +static u8 textHiScore[][15] = {{ TEXT_HI_SCORE }, { TEXT_HI_SCORE_FR }, { TEXT_HI_SCORE_DE }}; +static u8 textMyScore[][10] = {{ TEXT_MY_SCORE }, { TEXT_MY_SCORE_FR }, { TEXT_MY_SCORE_DE }}; -static unsigned char textNew[][5] = {{ TEXT_NEW }, { TEXT_NEW_FR }, { TEXT_NEW_DE }}; -static unsigned char starIcon[] = { GLYPH_STAR, GLYPH_SPACE }; -static unsigned char xIcon[] = { GLYPH_MULTIPLY, GLYPH_SPACE }; +static u8 textNew[][5] = {{ TEXT_NEW }, { TEXT_NEW_FR }, { TEXT_NEW_DE }}; +static u8 starIcon[] = { GLYPH_STAR, GLYPH_SPACE }; +static u8 xIcon[] = { GLYPH_MULTIPLY, GLYPH_SPACE }; #endif /** @@ -800,7 +816,7 @@ void copy_action_file_button(struct Object *copyButton, s32 copyFileButtonID) { gLoadedGraphNodes[MODEL_MAIN_MENU_MARIO_SAVE_BUTTON_FADE]; } else { // If clicked in a existing save file, play buzz sound - if (MENU_BUTTON_COPY_FILE_A + sSelectedFileIndex == copyFileButtonID) { + if (copyFileButtonID == MENU_BUTTON_COPY_FILE_A + sSelectedFileIndex) { play_sound(SOUND_MENU_CAMERA_BUZZ, gGlobalSoundSource); #if ENABLE_RUMBLE queue_rumble_data(5, 80); @@ -966,7 +982,7 @@ void erase_action_file_button(struct Object *eraseButton, s32 eraseFileButtonID) } break; case ERASE_PHASE_PROMPT: // Erase Menu "SURE? YES NO" Phase (after a file is selected) - if (MENU_BUTTON_ERASE_MIN + sSelectedFileIndex == eraseFileButtonID) { + if (eraseFileButtonID == MENU_BUTTON_ERASE_MIN + sSelectedFileIndex) { // If clicked in a existing save file, play click sound and zoom out button // Note: The prompt functions are actually called when the ERASE_MSG_PROMPT // message is displayed with print_erase_menu_prompt @@ -1636,6 +1652,11 @@ void handle_cursor_button_input(void) { } else if (gPlayer3Controller->buttonPressed & A_BUTTON) { sScoreFileCoinScoreMode = 1 - sScoreFileCoinScoreMode; play_sound(SOUND_MENU_CLICK_FILE_SELECT, gGlobalSoundSource); +#ifdef VERSION_CN + } else if ((gPlayer3Controller->buttonPressed & L_TRIG) || (gPlayer3Controller->buttonPressed & R_TRIG)) { + sScorePage = 1 - sScorePage; + play_sound(SOUND_MENU_CLICK_FILE_SELECT, gGlobalSoundSource); +#endif } } else { // If cursor is clicked if (gPlayer3Controller->buttonPressed @@ -1699,12 +1720,14 @@ void print_menu_cursor(void) { handle_controller_cursor_input(); create_dl_translation_matrix(MENU_MTX_PUSH, sCursorPos[0] + 160.0f - 5.0, sCursorPos[1] + 120.0f - 25.0, 0.0f); // Get the right graphic to use for the cursor. - if (sCursorClickingTimer == 0) + if (sCursorClickingTimer == 0) { // Idle gSPDisplayList(gDisplayListHead++, dl_menu_idle_hand); - if (sCursorClickingTimer != 0) + } + if (sCursorClickingTimer != 0) { // Grabbing gSPDisplayList(gDisplayListHead++, dl_menu_grabbing_hand); + } gSPPopMatrix(gDisplayListHead++, G_MTX_MODELVIEW); if (sCursorClickingTimer != 0) { sCursorClickingTimer++; // This is a very strange way to implement a timer? It counts up and @@ -1718,7 +1741,7 @@ void print_menu_cursor(void) { /** * Prints a hud string depending of the hud table list defined with text fade properties. */ -void print_hud_lut_string_fade(s8 hudLUT, s16 x, s16 y, const unsigned char *text) { +void print_hud_lut_string_fade(s8 hudLUT, s16 x, s16 y, const u8 *text) { gSPDisplayList(gDisplayListHead++, dl_rgba16_text_begin); gDPSetEnvColor(gDisplayListHead++, 255, 255, 255, sTextBaseAlpha - sTextFadeAlpha); print_hud_lut_string(hudLUT, x, y, text); @@ -1728,7 +1751,7 @@ void print_hud_lut_string_fade(s8 hudLUT, s16 x, s16 y, const unsigned char *tex /** * Prints a generic white string with text fade properties. */ -void print_generic_string_fade(s16 x, s16 y, const unsigned char *text) { +void print_generic_string_fade(s16 x, s16 y, const u8 *text) { gSPDisplayList(gDisplayListHead++, dl_ia_text_begin); gDPSetEnvColor(gDisplayListHead++, 255, 255, 255, sTextBaseAlpha - sTextFadeAlpha); print_generic_string(x, y, text); @@ -1774,15 +1797,20 @@ void print_save_file_star_count(s8 fileIndex, s16 x, s16 y) { } // Print star count int_to_str(starCount, starCountText); - print_hud_lut_string(HUD_LUT_GLOBAL, x + offset + 16, y, starCountText); + print_hud_lut_string(HUD_LUT_GLOBAL, x + (offset + 16), y, starCountText); } else { // Print "new" text +#ifdef VERSION_CN + print_hud_lut_string(HUD_LUT_GLOBAL, x - 2, y - 5, LANGUAGE_ARRAY(textNew)); +#else print_hud_lut_string(HUD_LUT_GLOBAL, x, y, LANGUAGE_ARRAY(textNew)); +#endif } } #if defined(VERSION_JP) || defined(VERSION_SH) #define SELECT_FILE_X 96 + #define SELECT_FILE_Y 35 #define SCORE_X 50 #define COPY_X 115 #define ERASE_X 180 @@ -1795,8 +1823,11 @@ void print_save_file_star_count(s8 fileIndex, s16 x, s16 y) { #define SAVEFILE_X2 209 #define MARIOTEXT_X1 92 #define MARIOTEXT_X2 207 + #define MARIOTEXT_Y1 65 + #define MARIOTEXT_Y2 105 #elif defined(VERSION_US) #define SELECT_FILE_X 93 + #define SELECT_FILE_Y 35 #define SCORE_X 52 #define COPY_X 117 #define ERASE_X 177 @@ -1805,11 +1836,28 @@ void print_save_file_star_count(s8 fileIndex, s16 x, s16 y) { #define SAVEFILE_X2 209 #define MARIOTEXT_X1 92 #define MARIOTEXT_X2 207 + #define MARIOTEXT_Y1 65 + #define MARIOTEXT_Y2 105 #elif defined(VERSION_EU) #define SAVEFILE_X1 97 #define SAVEFILE_X2 204 #define MARIOTEXT_X1 97 #define MARIOTEXT_X2 204 + #define MARIOTEXT_Y1 65 + #define MARIOTEXT_Y2 105 +#elif defined(VERSION_CN) + #define SELECT_FILE_X 106 + #define SELECT_FILE_Y 25 + #define SCORE_X 52 + #define COPY_X 113 + #define ERASE_X 177 + #define SOUNDMODE_X1 sSoundTextX + #define SAVEFILE_X1 92 + #define SAVEFILE_X2 209 + #define MARIOTEXT_X1 92 + #define MARIOTEXT_X2 207 + #define MARIOTEXT_Y1 164 + #define MARIOTEXT_Y2 124 #endif /** @@ -1820,7 +1868,7 @@ void print_save_file_star_count(s8 fileIndex, s16 x, s16 y) { * Same rule applies for score, copy and erase strings. */ void print_main_menu_strings(void) { -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) // The current sound mode is automatically centered on US and Shindou. static s16 sSoundTextX; // TODO: There should be a way to make this match on both US and Shindou. #endif @@ -1828,7 +1876,7 @@ void print_main_menu_strings(void) { gSPDisplayList(gDisplayListHead++, dl_rgba16_text_begin); gDPSetEnvColor(gDisplayListHead++, 255, 255, 255, sTextBaseAlpha); #ifndef VERSION_EU - print_hud_lut_string(HUD_LUT_DIFF, SELECT_FILE_X, 35, textSelectFile); + print_hud_lut_string(HUD_LUT_DIFF2, SELECT_FILE_X, SELECT_FILE_Y, textSelectFile); #endif // Print file star counts print_save_file_star_count(SAVE_FILE_A, SAVEFILE_X1, 78); @@ -1849,14 +1897,15 @@ void print_main_menu_strings(void) { print_generic_string(SOUNDMODE_X1, 39, textSoundModes[sSoundMode]); gSPDisplayList(gDisplayListHead++, dl_ia_text_end); #endif + // Print file names - gSPDisplayList(gDisplayListHead++, dl_menu_ia8_text_begin); + gSPDisplayList(gDisplayListHead++, FILE_SELECT_TEXT_DL_BEGIN); gDPSetEnvColor(gDisplayListHead++, 255, 255, 255, sTextBaseAlpha); - print_menu_generic_string(MARIOTEXT_X1, 65, textMarioA); - print_menu_generic_string(MARIOTEXT_X2, 65, textMarioB); - print_menu_generic_string(MARIOTEXT_X1, 105, textMarioC); - print_menu_generic_string(MARIOTEXT_X2, 105, textMarioD); - gSPDisplayList(gDisplayListHead++, dl_menu_ia8_text_end); + FILE_SELECT_PRINT_STRING(MARIOTEXT_X1, MARIOTEXT_Y1, textMarioA); + FILE_SELECT_PRINT_STRING(MARIOTEXT_X2, MARIOTEXT_Y1, textMarioB); + FILE_SELECT_PRINT_STRING(MARIOTEXT_X1, MARIOTEXT_Y2, textMarioC); + FILE_SELECT_PRINT_STRING(MARIOTEXT_X2, MARIOTEXT_Y2, textMarioD); + gSPDisplayList(gDisplayListHead++, FILE_SELECT_TEXT_DL_END); } #ifdef VERSION_EU @@ -1894,13 +1943,20 @@ void print_main_lang_strings(void) { #if defined(VERSION_JP) || defined(VERSION_SH) #define CHECK_FILE_X 90 + #define CHECK_FILE_Y 35 #define NOSAVE_DATA_X1 90 #elif defined(VERSION_US) #define CHECK_FILE_X 95 + #define CHECK_FILE_Y 35 #define NOSAVE_DATA_X1 99 #elif defined(VERSION_EU) #define CHECK_FILE_X checkFileX + #define CHECK_FILE_Y 35 #define NOSAVE_DATA_X1 noSaveDataX +#elif defined(VERSION_CN) + #define CHECK_FILE_X 106 + #define CHECK_FILE_Y 25 + #define NOSAVE_DATA_X1 99 #endif /** @@ -1916,7 +1972,7 @@ void score_menu_display_message(s8 messageID) { #ifdef VERSION_EU checkFileX = get_str_x_pos_from_center_scale(160, LANGUAGE_ARRAY(textCheckFile), 12.0f); #endif - print_hud_lut_string_fade(HUD_LUT_DIFF, CHECK_FILE_X, 35, LANGUAGE_ARRAY(textCheckFile)); + print_hud_lut_string_fade(HUD_LUT_DIFF, CHECK_FILE_X, CHECK_FILE_Y, LANGUAGE_ARRAY(textCheckFile)); break; case SCORE_MSG_NOSAVE_DATA: #ifdef VERSION_EU @@ -1931,14 +1987,30 @@ void score_menu_display_message(s8 messageID) { #define RETURN_X 45 #define COPYFILE_X1 128 #define ERASEFILE_X1 228 + #define SCORE_FILE_Y1 62 + #define SCORE_FILE_Y2 105 #elif defined(VERSION_US) #define RETURN_X 44 #define COPYFILE_X1 135 #define ERASEFILE_X1 231 + #define SCORE_FILE_Y1 62 + #define SCORE_FILE_Y2 105 #elif defined(VERSION_EU) #define RETURN_X centeredX #define COPYFILE_X1 centeredX #define ERASEFILE_X1 centeredX +#elif defined(VERSION_CN) + #define RETURN_X 44 + #define COPYFILE_X1 135 + #define ERASEFILE_X1 231 + #define SCORE_FILE_Y1 164 + #define SCORE_FILE_Y2 121 +#endif + +#ifdef VERSION_CN + #define RETURN_X_OLD 45 // this X wasn't changed in all places +#else + #define RETURN_X_OLD RETURN_X #endif #ifdef VERSION_EU @@ -1997,17 +2069,17 @@ void print_score_menu_strings(void) { print_generic_string(ERASEFILE_X1, 35, LANGUAGE_ARRAY(textEraseFileButton)); gSPDisplayList(gDisplayListHead++, dl_ia_text_end); + // Print file names #ifdef VERSION_EU print_main_menu_strings(); #else - // Print file names - gSPDisplayList(gDisplayListHead++, dl_menu_ia8_text_begin); + gSPDisplayList(gDisplayListHead++, FILE_SELECT_TEXT_DL_BEGIN); gDPSetEnvColor(gDisplayListHead++, 255, 255, 255, sTextBaseAlpha); - print_menu_generic_string(89, 62, textMarioA); - print_menu_generic_string(211, 62, textMarioB); - print_menu_generic_string(89, 105, textMarioC); - print_menu_generic_string(211, 105, textMarioD); - gSPDisplayList(gDisplayListHead++, dl_menu_ia8_text_end); + FILE_SELECT_PRINT_STRING(89, SCORE_FILE_Y1, textMarioA); + FILE_SELECT_PRINT_STRING(211, SCORE_FILE_Y1, textMarioB); + FILE_SELECT_PRINT_STRING(89, SCORE_FILE_Y2, textMarioC); + FILE_SELECT_PRINT_STRING(211, SCORE_FILE_Y2, textMarioD); + gSPDisplayList(gDisplayListHead++, FILE_SELECT_TEXT_DL_END); #endif } @@ -2018,6 +2090,7 @@ void print_score_menu_strings(void) { #define NOSAVE_DATA_X2 90 #define COPYCOMPLETE_X 90 #define SAVE_EXISTS_X1 90 + #define COPY_FILE_Y 35 #elif defined(VERSION_US) #define NOFILE_COPY_X 119 #define COPY_FILE_X 104 @@ -2025,6 +2098,7 @@ void print_score_menu_strings(void) { #define NOSAVE_DATA_X2 101 #define COPYCOMPLETE_X 110 #define SAVE_EXISTS_X1 110 + #define COPY_FILE_Y 35 #elif defined(VERSION_EU) #define NOFILE_COPY_X centeredX #define COPY_FILE_X centeredX @@ -2032,6 +2106,15 @@ void print_score_menu_strings(void) { #define NOSAVE_DATA_X2 centeredX #define COPYCOMPLETE_X centeredX #define SAVE_EXISTS_X1 centeredX + #define COPY_FILE_Y 35 +#elif defined(VERSION_CN) + #define NOFILE_COPY_X 119 + #define COPY_FILE_X 104 + #define COPYIT_WHERE_X 109 + #define NOSAVE_DATA_X2 101 + #define COPYCOMPLETE_X 110 + #define SAVE_EXISTS_X1 110 + #define COPY_FILE_Y 25 #endif /** @@ -2053,7 +2136,7 @@ void copy_menu_display_message(s8 messageID) { #ifdef VERSION_EU centeredX = get_str_x_pos_from_center_scale(160, textCopyFile[sLanguageMode], 12.0f); #endif - print_hud_lut_string_fade(HUD_LUT_DIFF, COPY_FILE_X, 35, LANGUAGE_ARRAY(textCopyFile)); + print_hud_lut_string_fade(HUD_LUT_DIFF, COPY_FILE_X, COPY_FILE_Y, LANGUAGE_ARRAY(textCopyFile)); } break; case COPY_MSG_COPY_WHERE: @@ -2133,15 +2216,26 @@ void copy_menu_update_message(void) { #if defined(VERSION_JP) #define VIEWSCORE_X1 133 #define ERASEFILE_X2 220 + #define COPY_FILE_Y1 62 + #define COPY_FILE_Y2 105 #elif defined(VERSION_US) #define VIEWSCORE_X1 128 #define ERASEFILE_X2 230 + #define COPY_FILE_Y1 62 + #define COPY_FILE_Y2 105 #elif defined(VERSION_EU) #define VIEWSCORE_X1 centeredX #define ERASEFILE_X2 centeredX #elif defined(VERSION_SH) #define VIEWSCORE_X1 133 #define ERASEFILE_X2 230 + #define COPY_FILE_Y1 62 + #define COPY_FILE_Y2 105 +#elif defined(VERSION_CN) + #define VIEWSCORE_X1 128 + #define ERASEFILE_X2 230 + #define COPY_FILE_Y1 164 + #define COPY_FILE_Y2 121 #endif /** @@ -2182,17 +2276,18 @@ void print_copy_menu_strings(void) { #endif print_generic_string(ERASEFILE_X2, 35, LANGUAGE_ARRAY(textEraseFileButton)); gSPDisplayList(gDisplayListHead++, dl_ia_text_end); + + // Print file names #ifdef VERSION_EU print_main_menu_strings(); #else - // Print file names - gSPDisplayList(gDisplayListHead++, dl_menu_ia8_text_begin); + gSPDisplayList(gDisplayListHead++, FILE_SELECT_TEXT_DL_BEGIN); gDPSetEnvColor(gDisplayListHead++, 255, 255, 255, sTextBaseAlpha); - print_menu_generic_string(89, 62, textMarioA); - print_menu_generic_string(211, 62, textMarioB); - print_menu_generic_string(89, 105, textMarioC); - print_menu_generic_string(211, 105, textMarioD); - gSPDisplayList(gDisplayListHead++, dl_menu_ia8_text_end); + FILE_SELECT_PRINT_STRING(89, COPY_FILE_Y1, textMarioA); + FILE_SELECT_PRINT_STRING(211, COPY_FILE_Y1, textMarioB); + FILE_SELECT_PRINT_STRING(89, COPY_FILE_Y2, textMarioC); + FILE_SELECT_PRINT_STRING(211, COPY_FILE_Y2, textMarioD); + gSPDisplayList(gDisplayListHead++, FILE_SELECT_TEXT_DL_END); #endif } @@ -2204,42 +2299,67 @@ void print_copy_menu_strings(void) { #endif #define MENU_ERASE_YES_MIN_X 145 #define MENU_ERASE_YES_MAX_X 164 +#elif defined(VERSION_CN) + #define CURSOR_X (x + 70) + #define MENU_ERASE_YES_MIN_X 144 + #define MENU_ERASE_YES_MAX_X 173 #else #define CURSOR_X (x + 70) #define MENU_ERASE_YES_MIN_X 140 #define MENU_ERASE_YES_MAX_X 169 #endif -#define MENU_ERASE_YES_NO_MIN_Y 191 -#define MENU_ERASE_YES_NO_MAX_Y 210 -#ifdef VERSION_SH - #define MENU_ERASE_NO_MIN_X 194 - #define MENU_ERASE_NO_MAX_X 213 -#else +#ifdef VERSION_CN + #define MENU_ERASE_YES_NO_MIN_Y 191 + #define MENU_ERASE_YES_NO_MAX_Y 210 #define MENU_ERASE_NO_MIN_X 189 #define MENU_ERASE_NO_MAX_X 218 + #define MENU_ERASE_YES_X_OFFSET 60 +#elif defined(VERSION_SH) + #define MENU_ERASE_YES_NO_MIN_Y 191 + #define MENU_ERASE_YES_NO_MAX_Y 210 + #define MENU_ERASE_NO_MIN_X 194 + #define MENU_ERASE_NO_MAX_X 213 + #define MENU_ERASE_YES_X_OFFSET 56 +#else + #define MENU_ERASE_YES_NO_MIN_Y 191 + #define MENU_ERASE_YES_NO_MAX_Y 210 + #define MENU_ERASE_NO_MIN_X 189 + #define MENU_ERASE_NO_MAX_X 218 + #define MENU_ERASE_YES_X_OFFSET 56 #endif /** * Prints the "YES NO" prompt and checks if one of the prompts are hovered to do it's functions. */ void print_erase_menu_prompt(s16 x, s16 y) { - s16 colorFade = gGlobalTimer << 12; + s16 colorTransTimer = gGlobalTimer * (1 << 12); s16 cursorX = sCursorPos[0] + CURSOR_X; s16 cursorY = sCursorPos[1] + 120.0f; + // TODO: Merge IDO/GCC if (cursorX < MENU_ERASE_YES_MAX_X && cursorX >= MENU_ERASE_YES_MIN_X && - cursorY < MENU_ERASE_YES_NO_MAX_Y && cursorY >= MENU_ERASE_YES_NO_MIN_Y) { +#ifdef VERSION_CN + (u16) (cursorY - MENU_ERASE_YES_NO_MIN_Y) < MENU_ERASE_YES_NO_MAX_Y - MENU_ERASE_YES_NO_MIN_Y +#else + cursorY < MENU_ERASE_YES_NO_MAX_Y && cursorY >= MENU_ERASE_YES_NO_MIN_Y +#endif + ) { // Fade "YES" string color but keep "NO" gray - sYesNoColor[0] = sins(colorFade) * 50.0f + 205.0f; + sYesNoColor[0] = sins(colorTransTimer) * 50.0f + 205.0f; sYesNoColor[1] = 150; sEraseYesNoHoverState = MENU_ERASE_HOVER_YES; - } else if (cursorX < MENU_ERASE_NO_MAX_X && cursorX >= MENU_ERASE_NO_MIN_X - && cursorY < MENU_ERASE_YES_NO_MAX_Y && cursorY >= MENU_ERASE_YES_NO_MIN_Y) { + } else if (cursorX < MENU_ERASE_NO_MAX_X && cursorX >= MENU_ERASE_NO_MIN_X && +#ifdef VERSION_CN + (u16) (cursorY - MENU_ERASE_YES_NO_MIN_Y) < MENU_ERASE_YES_NO_MAX_Y - MENU_ERASE_YES_NO_MIN_Y +#else + cursorY < MENU_ERASE_YES_NO_MAX_Y && cursorY >= MENU_ERASE_YES_NO_MIN_Y +#endif + ) { // Fade "NO" string color but keep "YES" gray sYesNoColor[0] = 150; - sYesNoColor[1] = sins(colorFade) * 50.0f + 205.0f; + sYesNoColor[1] = sins(colorTransTimer) * 50.0f + 205.0f; sEraseYesNoHoverState = MENU_ERASE_HOVER_NO; } else { // Don't fade both strings and keep them gray @@ -2282,7 +2402,7 @@ void print_erase_menu_prompt(s16 x, s16 y) { // Print "YES NO" strings gSPDisplayList(gDisplayListHead++, dl_ia_text_begin); gDPSetEnvColor(gDisplayListHead++, sYesNoColor[0], sYesNoColor[0], sYesNoColor[0], sTextBaseAlpha); - print_generic_string(x + 56, y, LANGUAGE_ARRAY(textYes)); + print_generic_string(x + MENU_ERASE_YES_X_OFFSET, y, LANGUAGE_ARRAY(textYes)); gDPSetEnvColor(gDisplayListHead++, sYesNoColor[1], sYesNoColor[1], sYesNoColor[1], sTextBaseAlpha); print_generic_string(x + 98, y, LANGUAGE_ARRAY(textNo)); gSPDisplayList(gDisplayListHead++, dl_ia_text_end); @@ -2298,22 +2418,32 @@ void print_erase_menu_prompt(s16 x, s16 y) { #else #define ERASE_FILE_X 111 #endif + #define ERASE_FILE_Y 35 #define NOSAVE_DATA_X3 90 #define MARIO_ERASED_VAR 3 #define MARIO_ERASED_X 90 #define SAVE_EXISTS_X2 90 #elif defined(VERSION_US) #define ERASE_FILE_X 98 + #define ERASE_FILE_Y 35 #define NOSAVE_DATA_X3 100 #define MARIO_ERASED_VAR 6 #define MARIO_ERASED_X 100 #define SAVE_EXISTS_X2 100 #elif defined(VERSION_EU) #define ERASE_FILE_X centeredX + #define ERASE_FILE_Y 35 #define NOSAVE_DATA_X3 centeredX #define MARIO_ERASED_VAR 6 #define MARIO_ERASED_X centeredX #define SAVE_EXISTS_X2 centeredX +#elif defined(VERSION_CN) + #define ERASE_FILE_X 106 + #define ERASE_FILE_Y 25 + #define NOSAVE_DATA_X3 100 + #define MARIO_ERASED_VAR 15 + #define MARIO_ERASED_X 100 + #define SAVE_EXISTS_X2 100 #endif /** @@ -2325,11 +2455,11 @@ void erase_menu_display_message(s8 messageID) { #endif #ifndef VERSION_EU - unsigned char textEraseFile[] = { TEXT_ERASE_FILE }; - unsigned char textSure[] = { TEXT_SURE }; - unsigned char textNoSavedDataExists[] = { TEXT_NO_SAVED_DATA_EXISTS }; - unsigned char textMarioAJustErased[] = { TEXT_FILE_MARIO_A_JUST_ERASED }; - unsigned char textSavedDataExists[] = { TEXT_SAVED_DATA_EXISTS }; + u8 textEraseFile[] = { TEXT_ERASE_FILE }; + u8 textSure[] = { TEXT_SURE }; + u8 textNoSavedDataExists[] = { TEXT_NO_SAVED_DATA_EXISTS }; + u8 textMarioAJustErased[] = { TEXT_FILE_MARIO_A_JUST_ERASED }; + u8 textSavedDataExists[] = { TEXT_SAVED_DATA_EXISTS }; #endif switch (messageID) { @@ -2337,7 +2467,7 @@ void erase_menu_display_message(s8 messageID) { #ifdef VERSION_EU centeredX = get_str_x_pos_from_center_scale(160, textEraseFile[sLanguageMode], 12.0f); #endif - print_hud_lut_string_fade(HUD_LUT_DIFF, ERASE_FILE_X, 35, LANGUAGE_ARRAY(textEraseFile)); + print_hud_lut_string_fade(HUD_LUT_DIFF, ERASE_FILE_X, ERASE_FILE_Y, LANGUAGE_ARRAY(textEraseFile)); break; case ERASE_MSG_PROMPT: print_generic_string_fade(90, 190, LANGUAGE_ARRAY(textSure)); @@ -2410,9 +2540,18 @@ void erase_menu_update_message(void) { #if defined(VERSION_JP) || defined(VERSION_SH) #define VIEWSCORE_X2 133 #define COPYFILE_X2 223 + #define ERASE_FILE_Y1 62 + #define ERASE_FILE_Y2 105 +#elif defined(VERSION_CN) + #define VIEWSCORE_X2 129 + #define COPYFILE_X2 228 + #define ERASE_FILE_Y1 164 + #define ERASE_FILE_Y2 121 #else #define VIEWSCORE_X2 127 #define COPYFILE_X2 233 + #define ERASE_FILE_Y1 62 + #define ERASE_FILE_Y2 105 #endif /** @@ -2452,30 +2591,35 @@ void print_erase_menu_strings(void) { centeredX = get_str_x_pos_from_center(249, textCopyFileButton[sLanguageMode], 10.0f); print_generic_string(centeredX, 35, textCopyFileButton[sLanguageMode]); #else - print_generic_string(RETURN_X, 35, textReturn); + print_generic_string(RETURN_X_OLD, 35, textReturn); print_generic_string(VIEWSCORE_X2, 35, textViewScore); print_generic_string(COPYFILE_X2, 35, textCopyFileButton); #endif gSPDisplayList(gDisplayListHead++, dl_ia_text_end); + // Print file names #ifdef VERSION_EU print_main_menu_strings(); #else - // Print file names - gSPDisplayList(gDisplayListHead++, dl_menu_ia8_text_begin); + gSPDisplayList(gDisplayListHead++, FILE_SELECT_TEXT_DL_BEGIN); gDPSetEnvColor(gDisplayListHead++, 255, 255, 255, sTextBaseAlpha); - print_menu_generic_string(89, 62, textMarioA); - print_menu_generic_string(211, 62, textMarioB); - print_menu_generic_string(89, 105, textMarioC); - print_menu_generic_string(211, 105, textMarioD); - gSPDisplayList(gDisplayListHead++, dl_menu_ia8_text_end); + FILE_SELECT_PRINT_STRING(89, ERASE_FILE_Y1, textMarioA); + FILE_SELECT_PRINT_STRING(211, ERASE_FILE_Y1, textMarioB); + FILE_SELECT_PRINT_STRING(89, ERASE_FILE_Y2, textMarioC); + FILE_SELECT_PRINT_STRING(211, ERASE_FILE_Y2, textMarioD); + gSPDisplayList(gDisplayListHead++, FILE_SELECT_TEXT_DL_END); #endif } #if defined(VERSION_JP) || defined(VERSION_SH) #define SOUND_HUD_X 96 + #define SOUND_HUD_Y 35 #elif defined(VERSION_US) #define SOUND_HUD_X 88 + #define SOUND_HUD_Y 35 +#elif defined(VERSION_CN) + #define SOUND_HUD_X 106 + #define SOUND_HUD_Y 55 #endif /** @@ -2486,14 +2630,14 @@ void print_erase_menu_strings(void) { void print_sound_mode_menu_strings(void) { s32 mode; -#if defined(VERSION_US) || defined(VERSION_SH) +#if defined(VERSION_US) || defined(VERSION_SH) || defined(VERSION_CN) s16 textX; #elif defined(VERSION_EU) s32 textX; #endif #ifndef VERSION_EU - unsigned char textSoundSelect[] = { TEXT_SOUND_SELECT }; + u8 textSoundSelect[] = { TEXT_SOUND_SELECT }; #endif // Print "SOUND SELECT" text @@ -2504,7 +2648,7 @@ void print_sound_mode_menu_strings(void) { print_hud_lut_string(HUD_LUT_DIFF, 47, 32, textSoundSelect[sLanguageMode]); print_hud_lut_string(HUD_LUT_DIFF, 47, 101, textLanguageSelect[sLanguageMode]); #else - print_hud_lut_string(HUD_LUT_DIFF, SOUND_HUD_X, 35, textSoundSelect); + print_hud_lut_string(HUD_LUT_DIFF, SOUND_HUD_X, SOUND_HUD_Y, textSoundSelect); #endif gSPDisplayList(gDisplayListHead++, dl_rgba16_text_end); @@ -2538,7 +2682,7 @@ void print_sound_mode_menu_strings(void) { #else // Print sound mode names for (mode = 0; mode < 3; mode++) { - if (mode == sSoundMode) { + if (sSoundMode == mode) { gDPSetEnvColor(gDisplayListHead++, 255, 255, 255, sTextBaseAlpha); } else { gDPSetEnvColor(gDisplayListHead++, 0, 0, 0, sTextBaseAlpha); @@ -2561,22 +2705,32 @@ void print_sound_mode_menu_strings(void) { gSPDisplayList(gDisplayListHead++, dl_ia_text_end); } -unsigned char textStarX[] = { TEXT_STAR_X }; +#ifndef VERSION_CN +u8 textStarX[] = { TEXT_STAR_X }; +#endif /** * Prints castle secret stars collected in a score menu save file. */ void print_score_file_castle_secret_stars(s8 fileIndex, s16 x, s16 y) { - unsigned char secretStarsText[20]; - // Print "[star] x" - print_menu_generic_string(x, y, textStarX); - // Print number of castle secret stars - int_to_str(save_file_get_total_star_count(fileIndex, COURSE_BONUS_STAGES - 1, COURSE_MAX - 1), - secretStarsText); -#ifdef VERSION_EU - print_menu_generic_string(x + 20, y, secretStarsText); +#ifdef VERSION_CN + u8 secretStarsText[36]; + u8 textStarX[] = { TEXT_STAR_X }; #else - print_menu_generic_string(x + 16, y, secretStarsText); + u8 secretStarsText[20]; +#endif + + // Print "[star] x" + FILE_SELECT_PRINT_STRING(x, y, textStarX); + + // Print number of castle secret stars + INT_TO_STR_DIFF(save_file_get_total_star_count(fileIndex, COURSE_BONUS_STAGES - 1, COURSE_MAX - 1), + secretStarsText); + +#ifdef VERSION_EU + FILE_SELECT_PRINT_STRING(x + 20, y, secretStarsText); +#else + FILE_SELECT_PRINT_STRING(x + 16, y, secretStarsText); #endif } @@ -2594,41 +2748,54 @@ void print_score_file_castle_secret_stars(s8 fileIndex, s16 x, s16 y) { * Prints course coins collected in a score menu save file. */ void print_score_file_course_coin_score(s8 fileIndex, s16 courseIndex, s16 x, s16 y) { - unsigned char coinScoreText[20]; +#ifdef VERSION_CN + u8 coinScoreText[36]; +#else + u8 coinScoreText[20]; +#endif + u8 stars = save_file_get_star_flags(fileIndex, courseIndex); - unsigned char textCoinX[] = { TEXT_COIN_X }; - unsigned char textStar[] = { TEXT_STAR }; + u8 textCoinX[] = { TEXT_COIN_X }; + u8 textStar[] = { TEXT_STAR }; + #if defined(VERSION_JP) || defined(VERSION_SH) #define LENGTH 5 +#elif defined(VERSION_CN) + #define LENGTH 16 #else #define LENGTH 8 #endif - unsigned char fileNames[][LENGTH] = { + u8 fileNames[][LENGTH] = { { TEXT_4DASHES }, // huh? { TEXT_SCORE_MARIO_A }, { TEXT_SCORE_MARIO_B }, { TEXT_SCORE_MARIO_C }, { TEXT_SCORE_MARIO_D }, }; #undef LENGTH + // MYSCORE if (sScoreFileCoinScoreMode == 0) { // Print "[coin] x" - print_menu_generic_string(x + 25, y, textCoinX); + FILE_SELECT_PRINT_STRING(x + 25, y, textCoinX); + // Print coin score - int_to_str(save_file_get_course_coin_score(fileIndex, courseIndex), coinScoreText); - print_menu_generic_string(x + 41, y, coinScoreText); + INT_TO_STR_DIFF(save_file_get_course_coin_score(fileIndex, courseIndex), coinScoreText); + FILE_SELECT_PRINT_STRING(x + 41, y, coinScoreText); + // If collected, print 100 coin star if (stars & (1 << 6)) { - print_menu_generic_string(x + 70, y, textStar); + FILE_SELECT_PRINT_STRING(x + 70, y, textStar); } } // HISCORE else { // Print "[coin] x" - print_menu_generic_string(x + HISCORE_COIN_ICON_X, y, textCoinX); + FILE_SELECT_PRINT_STRING(x + HISCORE_COIN_ICON_X, y, textCoinX); + // Print coin highscore - int_to_str((u16) save_file_get_max_coin_score(courseIndex) & 0xFFFF, coinScoreText); - print_menu_generic_string(x + HISCORE_COIN_TEXT_X, y, coinScoreText); + INT_TO_STR_DIFF((u16) save_file_get_max_coin_score(courseIndex) & 0xFFFF, coinScoreText); + FILE_SELECT_PRINT_STRING(x + HISCORE_COIN_TEXT_X, y, coinScoreText); + // Print coin highscore file - print_menu_generic_string(x + HISCORE_COIN_NAMES_X, y, + FILE_SELECT_PRINT_STRING(x + HISCORE_COIN_NAMES_X, y, fileNames[(save_file_get_max_coin_score(courseIndex) >> 16) & 0xFFFF]); } } @@ -2638,7 +2805,13 @@ void print_score_file_course_coin_score(s8 fileIndex, s16 courseIndex, s16 x, s1 */ void print_score_file_star_score(s8 fileIndex, s16 courseIndex, s16 x, s16 y) { s16 i = 0; - unsigned char starScoreText[19]; + +#ifdef VERSION_CN + u8 starScoreText[36]; +#else + u8 starScoreText[19]; +#endif + u8 stars = save_file_get_star_flags(fileIndex, courseIndex); s8 starCount = save_file_get_course_star_count(fileIndex, courseIndex); // Don't count 100 coin star @@ -2647,15 +2820,28 @@ void print_score_file_star_score(s8 fileIndex, s16 courseIndex, s16 x, s16 y) { } // Add 1 star character for every star collected for (i = 0; i < starCount; i++) { +#ifdef VERSION_CN + starScoreText[i * 2] = 0x00; + starScoreText[i * 2 + 1] = DIALOG_CHAR_STAR_FILLED; +#else starScoreText[i] = DIALOG_CHAR_STAR_FILLED; +#endif } + // Terminating byte +#ifdef VERSION_CN + starScoreText[i * 2] = DIALOG_CHAR_TERMINATOR; + starScoreText[i * 2 + 1] = DIALOG_CHAR_TERMINATOR; +#else starScoreText[i] = DIALOG_CHAR_TERMINATOR; - print_menu_generic_string(x, y, starScoreText); +#endif + + FILE_SELECT_PRINT_STRING(x, y, starScoreText); } #if defined(VERSION_JP) || defined(VERSION_SH) #define MARIO_X 28 + #define MARIO_Y 15 #define FILE_LETTER_X 86 #ifdef VERSION_JP #define LEVEL_NUM_PAD 0 @@ -2668,8 +2854,22 @@ void print_score_file_star_score(s8 fileIndex, s16 courseIndex, s16 x, s16 y) { #define STAR_SCORE_X 152 #define MYSCORE_X 237 #define HISCORE_X 237 + #define MYSCORE_Y 24 + #define HISCORE_Y 24 +#elif defined(VERSION_CN) + #define MARIO_X 25 + #define MARIO_Y 9 + #define FILE_LETTER_X 95 + #define SECRET_STARS_PAD 6 + #define LEVEL_NAME_X 26 + #define STAR_SCORE_X 171 + #define MYSCORE_X 238 + #define HISCORE_X 231 + #define MYSCORE_Y 200 + #define HISCORE_Y 200 #else #define MARIO_X 25 + #define MARIO_Y 15 #define FILE_LETTER_X 95 #define LEVEL_NUM_PAD 3 #define SECRET_STARS_PAD 6 @@ -2682,30 +2882,52 @@ void print_score_file_star_score(s8 fileIndex, s16 courseIndex, s16 x, s16 y) { #define MYSCORE_X 238 #define HISCORE_X 231 #endif + #define MYSCORE_Y 24 + #define HISCORE_Y 24 #endif #ifdef VERSION_EU #include "game/segment7.h" #endif +#define PRINT_COURSE_NAME_CN(courseIndex, shift) \ + FILE_SELECT_PRINT_STRING(LEVEL_NAME_X, 14 + 21 * (9 - courseIndex) + shift, \ + segmented_to_virtual(levelNameTable[courseIndex - 1])); + +#define PRINT_COURSE_SCORES_CN(courseIndex, shift) \ + print_score_file_star_score(fileIndex, courseIndex - 1, STAR_SCORE_X, 14 + 21 * (9 - courseIndex) + shift); \ + print_score_file_course_coin_score(fileIndex, courseIndex - 1, 213, 14 + 21 * (9 - courseIndex) + shift); + +#define PRINT_COURSE_NAME_AND_SCORES(courseIndex, pad) \ + FILE_SELECT_PRINT_STRING(LEVEL_NAME_X + (pad * LEVEL_NUM_PAD), 23 + 12 * courseIndex, \ + segmented_to_virtual(levelNameTable[courseIndex - 1])); \ + print_score_file_star_score(fileIndex, courseIndex - 1, STAR_SCORE_X, 23 + 12 * courseIndex); \ + print_score_file_course_coin_score(fileIndex, courseIndex - 1, 213, 23 + 12 * courseIndex); + /** * Prints save file score strings that shows when a save file is chosen inside the score menu. */ void print_save_file_scores(s8 fileIndex) { #ifndef VERSION_EU - unsigned char textMario[] = { TEXT_MARIO }; + + u8 textMario[] = { TEXT_MARIO }; #ifdef VERSION_JP - unsigned char textFileLetter[] = { TEXT_ZERO }; + u8 textFileLetter[] = { TEXT_ZERO }; void **levelNameTable = segmented_to_virtual(seg2_course_name_table); #endif - unsigned char textHiScore[] = { TEXT_HI_SCORE }; - unsigned char textMyScore[] = { TEXT_MY_SCORE }; -#if defined(VERSION_US) || defined(VERSION_SH) - unsigned char textFileLetter[] = { TEXT_ZERO }; + u8 textHiScore[] = { TEXT_HI_SCORE }; + u8 textMyScore[] = { TEXT_MY_SCORE }; +#ifdef VERSION_CN + u8 textArrowL[] = { TEXT_ARROW_L }; + u8 textRArrow[] = { TEXT_R_ARROW }; +#endif +#ifndef VERSION_JP + u8 textFileLetter[] = { TEXT_ZERO }; void **levelNameTable = segmented_to_virtual(seg2_course_name_table); #endif + #else - unsigned char textFileLetter[] = { TEXT_ZERO }; + u8 textFileLetter[] = { TEXT_ZERO }; void **levelNameTable; switch (sLanguageMode) { @@ -2726,63 +2948,114 @@ void print_save_file_scores(s8 fileIndex) { // Print file name at top gSPDisplayList(gDisplayListHead++, dl_rgba16_text_begin); gDPSetEnvColor(gDisplayListHead++, 255, 255, 255, sTextBaseAlpha); - print_hud_lut_string(HUD_LUT_DIFF, MARIO_X, 15, textMario); + print_hud_lut_string(HUD_LUT_DIFF, MARIO_X, MARIO_Y, textMario); print_hud_lut_string(HUD_LUT_GLOBAL, FILE_LETTER_X, 15, textFileLetter); // Print save file star count at top print_save_file_star_count(fileIndex, 124, 15); gSPDisplayList(gDisplayListHead++, dl_rgba16_text_end); + // Print course scores - gSPDisplayList(gDisplayListHead++, dl_menu_ia8_text_begin); + gSPDisplayList(gDisplayListHead++, FILE_SELECT_TEXT_DL_BEGIN); gDPSetEnvColor(gDisplayListHead++, 255, 255, 255, sTextBaseAlpha); -//! Huge print list, for loops exist for a reason! -#define PRINT_COURSE_SCORES(courseIndex, pad) \ - print_menu_generic_string(LEVEL_NAME_X + (pad * LEVEL_NUM_PAD), 23 + 12 * courseIndex, \ - segmented_to_virtual(levelNameTable[courseIndex - 1])); \ - print_score_file_star_score(fileIndex, courseIndex - 1, STAR_SCORE_X, 23 + 12 * courseIndex); \ - print_score_file_course_coin_score(fileIndex, courseIndex - 1, 213, 23 + 12 * courseIndex); + //! Huge print list, for loops exist for a reason! +#ifdef VERSION_CN + if (sScorePage == 0) { + PRINT_COURSE_NAME_CN(COURSE_SSL, 0) + PRINT_COURSE_NAME_CN(COURSE_LLL, 0) + PRINT_COURSE_NAME_CN(COURSE_HMC, 0) + PRINT_COURSE_NAME_CN(COURSE_BBH, 0) + PRINT_COURSE_NAME_CN(COURSE_CCM, 0) + PRINT_COURSE_NAME_CN(COURSE_JRB, 0) + PRINT_COURSE_NAME_CN(COURSE_WF, 0) + PRINT_COURSE_NAME_CN(COURSE_BOB, 0) + PRINT_COURSE_SCORES_CN(COURSE_SSL, 0) + PRINT_COURSE_SCORES_CN(COURSE_LLL, 0) + PRINT_COURSE_SCORES_CN(COURSE_HMC, 0) + PRINT_COURSE_SCORES_CN(COURSE_BBH, 0) + PRINT_COURSE_SCORES_CN(COURSE_CCM, 0) + PRINT_COURSE_SCORES_CN(COURSE_JRB, 0) + PRINT_COURSE_SCORES_CN(COURSE_WF, 0) + PRINT_COURSE_SCORES_CN(COURSE_BOB, 0) + } else if (sScorePage == 1) { + // Print castle secret stars text + print_generic_string(LEVEL_NAME_X, 23 + 12 * 1, + segmented_to_virtual(levelNameTable[25])); + + PRINT_COURSE_NAME_CN(COURSE_RR, 168) + PRINT_COURSE_NAME_CN(COURSE_TTC, 168) + PRINT_COURSE_NAME_CN(COURSE_THI, 168) + PRINT_COURSE_NAME_CN(COURSE_TTM, 168) + PRINT_COURSE_NAME_CN(COURSE_WDW, 168) + PRINT_COURSE_NAME_CN(COURSE_SL, 168) + PRINT_COURSE_NAME_CN(COURSE_DDD, 168) + + // Print castle secret stars score + print_score_file_castle_secret_stars(fileIndex, STAR_SCORE_X, 23 + 12 * 1); + + PRINT_COURSE_SCORES_CN(COURSE_RR, 168) + PRINT_COURSE_SCORES_CN(COURSE_TTC, 168) + PRINT_COURSE_SCORES_CN(COURSE_THI, 168) + PRINT_COURSE_SCORES_CN(COURSE_TTM, 168) + PRINT_COURSE_SCORES_CN(COURSE_WDW, 168) + PRINT_COURSE_SCORES_CN(COURSE_SL, 168) + PRINT_COURSE_SCORES_CN(COURSE_DDD, 168) + } +#else // Course values are indexed, from Bob-omb Battlefield to Rainbow Ride - PRINT_COURSE_SCORES(COURSE_BOB, 1) - PRINT_COURSE_SCORES(COURSE_WF, 1) - PRINT_COURSE_SCORES(COURSE_JRB, 1) - PRINT_COURSE_SCORES(COURSE_CCM, 1) - PRINT_COURSE_SCORES(COURSE_BBH, 1) - PRINT_COURSE_SCORES(COURSE_HMC, 1) - PRINT_COURSE_SCORES(COURSE_LLL, 1) - PRINT_COURSE_SCORES(COURSE_SSL, 1) - PRINT_COURSE_SCORES(COURSE_DDD, 1) - PRINT_COURSE_SCORES(COURSE_SL, 0) - PRINT_COURSE_SCORES(COURSE_WDW, 0) - PRINT_COURSE_SCORES(COURSE_TTM, 0) - PRINT_COURSE_SCORES(COURSE_THI, 0) - PRINT_COURSE_SCORES(COURSE_TTC, 0) - PRINT_COURSE_SCORES(COURSE_RR, 0) -#undef PRINT_COURSE_SCORES + PRINT_COURSE_NAME_AND_SCORES(COURSE_BOB, 1) + PRINT_COURSE_NAME_AND_SCORES(COURSE_WF, 1) + PRINT_COURSE_NAME_AND_SCORES(COURSE_JRB, 1) + PRINT_COURSE_NAME_AND_SCORES(COURSE_CCM, 1) + PRINT_COURSE_NAME_AND_SCORES(COURSE_BBH, 1) + PRINT_COURSE_NAME_AND_SCORES(COURSE_HMC, 1) + PRINT_COURSE_NAME_AND_SCORES(COURSE_LLL, 1) + PRINT_COURSE_NAME_AND_SCORES(COURSE_SSL, 1) + PRINT_COURSE_NAME_AND_SCORES(COURSE_DDD, 1) + PRINT_COURSE_NAME_AND_SCORES(COURSE_SL, 0) + PRINT_COURSE_NAME_AND_SCORES(COURSE_WDW, 0) + PRINT_COURSE_NAME_AND_SCORES(COURSE_TTM, 0) + PRINT_COURSE_NAME_AND_SCORES(COURSE_THI, 0) + PRINT_COURSE_NAME_AND_SCORES(COURSE_TTC, 0) + PRINT_COURSE_NAME_AND_SCORES(COURSE_RR, 0) // Print castle secret stars text - print_menu_generic_string(LEVEL_NAME_X + SECRET_STARS_PAD, 23 + 12 * 16, + FILE_SELECT_PRINT_STRING(LEVEL_NAME_X + SECRET_STARS_PAD, 23 + 12 * 16, segmented_to_virtual(levelNameTable[25])); // Print castle secret stars score print_score_file_castle_secret_stars(fileIndex, STAR_SCORE_X, 23 + 12 * 16); +#endif // Print current coin score mode if (sScoreFileCoinScoreMode == 0) { - print_menu_generic_string(MYSCORE_X, 24, LANGUAGE_ARRAY(textMyScore)); + FILE_SELECT_PRINT_STRING(MYSCORE_X, MYSCORE_Y, LANGUAGE_ARRAY(textMyScore)); } else { - print_menu_generic_string(HISCORE_X, 24, LANGUAGE_ARRAY(textHiScore)); + FILE_SELECT_PRINT_STRING(HISCORE_X, HISCORE_Y, LANGUAGE_ARRAY(textHiScore)); } - gSPDisplayList(gDisplayListHead++, dl_menu_ia8_text_end); +#ifdef VERSION_CN + // Print L and R button indicators + FILE_SELECT_PRINT_STRING(30, 17, textArrowL); + FILE_SELECT_PRINT_STRING(270, 17, textRArrow); +#endif + + gSPDisplayList(gDisplayListHead++, FILE_SELECT_TEXT_DL_END); } +#undef PRINT_COURSE_NAME_CN +#undef PRINT_COURSE_SCORES_CN +#undef PRINT_COURSE_NAME_AND_SCORES + /** * Prints file select strings depending on the menu selected. * Also checks if all saves exists and defines text and main menu timers. */ static void print_file_select_strings(void) { +#ifndef VERSION_CN UNUSED u8 filler[8]; +#endif create_dl_ortho_matrix(); switch (sSelectedButtonID) { @@ -2854,7 +3127,7 @@ Gfx *geo_file_select_strings_and_menu_cursor(s32 callContext, UNUSED struct Grap */ s32 lvl_init_menu_values_and_cursor_pos(UNUSED s32 arg, UNUSED s32 unused) { #ifdef VERSION_EU - s8 fileNum; + s8 fileIndex; #endif sSelectedButtonID = MENU_BUTTON_NONE; sCurrentMenuLevel = MENU_LAYER_MAIN; @@ -2894,8 +3167,8 @@ s32 lvl_init_menu_values_and_cursor_pos(UNUSED s32 arg, UNUSED s32 unused) { #ifdef VERSION_EU sLanguageMode = eu_get_language(); - for (fileNum = 0; fileNum < 4; fileNum++) { - if (save_file_exists(fileNum) == TRUE) { + for (fileIndex = 0; fileIndex <= 3; fileIndex++) { + if (save_file_exists(fileIndex) == TRUE) { sOpenLangSettings = FALSE; break; } else { @@ -2918,3 +3191,7 @@ s32 lvl_update_obj_and_load_file_selected(UNUSED s32 arg, UNUSED s32 unused) { area_update_objects(); return sSelectedFileNum; } + +#undef FILE_SELECT_PRINT_STRING +#undef FILE_SELECT_TEXT_DL_BEGIN +#undef FILE_SELECT_TEXT_DL_END diff --git a/src/menu/intro_geo.c b/src/menu/intro_geo.c index efbbfbbb..bfa85b8d 100644 --- a/src/menu/intro_geo.c +++ b/src/menu/intro_geo.c @@ -27,7 +27,7 @@ struct GraphNodeMore { }; // intro geo bss -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) static u16 *sFramebuffers[3]; #endif static s32 sGameOverFrameCounter; @@ -82,7 +82,7 @@ Gfx *geo_intro_super_mario_64_logo(s32 state, struct GraphNode *node, UNUSED voi guScale(scaleMat, scaleX, scaleY, scaleZ); gSPMatrix(dlIter++, scaleMat, G_MTX_MODELVIEW | G_MTX_MUL | G_MTX_PUSH); - gSPDisplayList(dlIter++, &intro_seg7_dl_0700B3A0); // draw model + gSPDisplayList(dlIter++, &intro_seg7_dl_logo); // draw model gSPPopMatrix(dlIter++, G_MTX_MODELVIEW); gSPEndDisplayList(dlIter); @@ -116,7 +116,7 @@ Gfx *geo_intro_tm_copyright(s32 state, struct GraphNode *node, UNUSED void *cont gDPSetRenderMode(dlIter++, G_RM_AA_XLU_SURF, G_RM_AA_XLU_SURF2); break; } - gSPDisplayList(dlIter++, &intro_seg7_dl_0700C6A0); // draw model + gSPDisplayList(dlIter++, &intro_seg7_dl_copyright); // draw model gSPEndDisplayList(dlIter); // Once the "Super Mario 64" logo has just about zoomed fully, fade in the "TM" and copyright text @@ -167,7 +167,7 @@ static Gfx *intro_backdrop_one_image(s32 index, s8 *backgroundTable) { guTranslate(mtx, xCoords[index], yCoords[index], 0.0f); gSPMatrix(displayListIter++, mtx, G_MTX_MODELVIEW | G_MTX_LOAD | G_MTX_PUSH); gSPDisplayList(displayListIter++, &title_screen_bg_dl_0A000118); - for (i = 0; i < 4; ++i) { + for (i = 0; i < 4; i++) { gDPLoadTextureBlock(displayListIter++, vIntroBgTable[i], G_IM_FMT_RGBA, G_IM_SIZ_16b, 80, 20, 0, G_TX_CLAMP, G_TX_CLAMP, 7, 6, G_TX_NOLOD, G_TX_NOLOD) gSPDisplayList(displayListIter++, introBackgroundDlRows[i]); @@ -204,7 +204,7 @@ Gfx *geo_intro_regular_backdrop(s32 state, struct GraphNode *node, UNUSED void * graphNode->node.flags = (graphNode->node.flags & 0xFF) | (LAYER_OPAQUE << 8); gSPDisplayList(dlIter++, &dl_proj_mtx_fullscreen); gSPDisplayList(dlIter++, &title_screen_bg_dl_0A000100); - for (i = 0; i < 12; ++i) { + for (i = 0; i < 12; i++) { gSPDisplayList(dlIter++, intro_backdrop_one_image(i, backgroundTable)); } gSPDisplayList(dlIter++, &title_screen_bg_dl_0A000190); @@ -233,8 +233,9 @@ Gfx *geo_intro_gameover_backdrop(s32 state, struct GraphNode *node, UNUSED void if (state != 1) { // reset sGameOverFrameCounter = 0; sGameOverTableIndex = -2; - for (i = 0; i < ARRAY_COUNT(gameOverBackgroundTable); ++i) + for (i = 0; i < ARRAY_COUNT(gameOverBackgroundTable); i++) { gameOverBackgroundTable[i] = INTRO_BACKGROUND_GAME_OVER; + } } else { // draw dl = alloc_display_list(16 * sizeof(*dl)); dlIter = dl; @@ -262,15 +263,16 @@ Gfx *geo_intro_gameover_backdrop(s32 state, struct GraphNode *node, UNUSED void // draw all the tiles gSPDisplayList(dlIter++, &dl_proj_mtx_fullscreen); gSPDisplayList(dlIter++, &title_screen_bg_dl_0A000100); - for (j = 0; j < ARRAY_COUNT(gameOverBackgroundTable); ++j) + for (j = 0; j < ARRAY_COUNT(gameOverBackgroundTable); j++) { gSPDisplayList(dlIter++, intro_backdrop_one_image(j, gameOverBackgroundTable)); + } gSPDisplayList(dlIter++, &title_screen_bg_dl_0A000190); gSPEndDisplayList(dlIter); } return dl; } -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) extern Gfx title_screen_bg_dl_0A0065E8[]; extern Gfx title_screen_bg_dl_0A006618[]; @@ -335,6 +337,73 @@ Gfx *intro_draw_face(u16 *image, s32 imageW, s32 imageH) { return dl; } +#ifdef VERSION_CN + +// TODO: See whether this matches other game versions too, clearly there was no actual +// substantive change in this function +u16 *intro_sample_framebuffer(s32 imageW, s32 imageH, s32 sampleW, s32 sampleH) { + u16 *fb; + u16 *image; + s32 xIndex; + s32 yIndex; + f32 size; + f32 r, g, b; + s32 iy, ix, sy, sx; + s32 xOffset, yOffset; + u16 fbr, fbg, fbb; + f32 f1, f2, f3; + + fb = sFramebuffers[sRenderingFramebuffer]; + image = alloc_display_list(imageW * imageH * sizeof(u16)); + + if (image == NULL) { + return image; + } + + for (iy = 0; iy < imageH; iy++) { + yOffset = 80; + + for (ix = 0; ix < imageW; ix++) { + xOffset = 120; + + r = 0; + g = 0; + b = 0; + + for (sy = 0; sy < sampleH; sy++) { + for (sx = 0; sx < sampleW; sx++) { + yIndex = (sampleH * iy + yOffset) + sy; + xIndex = (sampleW * ix + xOffset) + sx; + + fbr = fb[320 * yIndex + xIndex]; + fbg = fb[320 * yIndex + xIndex]; + fbb = fb[320 * yIndex + xIndex]; + + f1 = (fbr >> 0xB) & 0x1F; + f2 = (fbg >> 0x6) & 0x1F; + f3 = (fbb >> 0x1) & 0x1F; + + r += f1; + g += f2; + b += f3; + } + } + + size = sampleW * sampleH; + + fbr = ((u16) (r / size + 0.5) << 0xB) & 0xF800; + fbg = ((u16) (g / size + 0.5) << 0x6) & 0x7C0; + fbb = ((u16) (b / size + 0.5) << 0x1) & 0x3E; + + image[imageH * iy + ix] = fbr + fbg + fbb + 1; + } + } + + return image; +} + +#else + u16 *intro_sample_framebuffer(s32 imageW, s32 imageH, s32 sampleW, s32 sampleH) { u16 *fb; u16 *image; @@ -389,12 +458,16 @@ u16 *intro_sample_framebuffer(s32 imageW, s32 imageH, s32 sampleW, s32 sampleH) return image; } +#endif + Gfx *geo_intro_face_easter_egg(s32 state, struct GraphNode *node, UNUSED void *context) { - struct GraphNodeGenerated *genNode = (struct GraphNodeGenerated *)node; + struct GraphNodeGenerated *genNode; u16 *image; Gfx *dl = NULL; s32 i; + genNode = (struct GraphNodeGenerated *) node; + if (state != 1) { sFramebuffers[0] = gFramebuffer0; sFramebuffers[1] = gFramebuffer1; @@ -403,7 +476,6 @@ Gfx *geo_intro_face_easter_egg(s32 state, struct GraphNode *node, UNUSED void *c for (i = 0; i < 48; i++) { sFaceVisible[i] = 0; } - } else if (state == 1) { if (sFaceCounter == 0) { if (gPlayer1Controller->buttonPressed & Z_TRIG) { diff --git a/src/menu/intro_geo.h b/src/menu/intro_geo.h index bedafb67..9797fd0b 100644 --- a/src/menu/intro_geo.h +++ b/src/menu/intro_geo.h @@ -12,7 +12,7 @@ Gfx *geo_intro_tm_copyright(s32 sp40, struct GraphNode *sp44, UNUSED void *conte Gfx *geo_intro_regular_backdrop(s32 sp48, struct GraphNode *sp4c, UNUSED void *context); Gfx *geo_intro_gameover_backdrop(s32 sp40, struct GraphNode *sp44, UNUSED void *context); -#ifdef VERSION_SH +#if defined(VERSION_SH) || defined(VERSION_CN) Gfx *geo_intro_face_easter_egg(s32 state, struct GraphNode *node, UNUSED void *context); Gfx *geo_intro_rumble_pak_graphic(s32 state, struct GraphNode *node, UNUSED void *context); #endif diff --git a/src/menu/star_select.c b/src/menu/star_select.c index f7d1d740..68995d27 100644 --- a/src/menu/star_select.c +++ b/src/menu/star_select.c @@ -149,7 +149,8 @@ void bhv_act_selector_init(void) { for (i = 0; i < sVisibleStars; i++) { sStarSelectorModels[i] = spawn_object_abs_with_rot(gCurrentObject, 0, selectorModelIDs[i], bhvActSelectorStarType, - 75 + sVisibleStars * -75 + i * 152, 248, -300, 0, 0, 0); + (sVisibleStars - 1) * -75 + i * 152, 248, -300, 0, 0, 0); + sStarSelectorModels[i]->oStarSelectorSize = 1.0f; } @@ -176,7 +177,7 @@ void bhv_act_selector_loop(void) { starIndexCounter = sSelectableStarIndex; for (i = 0; i < sVisibleStars; i++) { // Can the star be selected (is it either already completed or the first non-completed mission) - if ((stars & (1 << i)) || i + 1 == sInitSelectedActNum) { + if ((stars & (1 << i)) || i == sInitSelectedActNum - 1) { if (starIndexCounter == 0) { // We have reached the sSelectableStarIndex-th selectable star. sSelectedActIndex = i; break; @@ -262,6 +263,7 @@ void print_act_selector_strings(void) { #else unsigned char myScore[] = { TEXT_MYSCORE }; #endif + unsigned char starNumbers[] = { TEXT_ZERO }; #ifdef VERSION_EU @@ -311,15 +313,23 @@ void print_act_selector_strings(void) { gDPSetEnvColor(gDisplayListHead++, 0, 0, 0, 255); // Print the "MY SCORE" text if the coin score is more than 0 if (save_file_get_course_coin_score(gCurrSaveFileNum - 1, COURSE_NUM_TO_INDEX(gCurrCourseNum)) != 0) { + // TODO: Macros for all these hardcoded positions would be nice #ifdef VERSION_EU print_generic_string(95, 118, myScore[language]); +#elif defined(VERSION_CN) + print_generic_string(89, 118, myScore); #else print_generic_string(102, 118, myScore); #endif } +#ifdef VERSION_CN + lvlNameX = get_str_x_pos_from_center(160, currLevelName + 6, 16.0f); + print_generic_string(lvlNameX, 30, currLevelName + 6); +#else lvlNameX = get_str_x_pos_from_center(160, currLevelName + 3, 10.0f); print_generic_string(lvlNameX, 33, currLevelName + 3); +#endif gSPDisplayList(gDisplayListHead++, dl_ia_text_end); @@ -329,38 +339,56 @@ void print_act_selector_strings(void) { print_course_number(); #endif +#ifdef VERSION_CN + gSPDisplayList(gDisplayListHead++, dl_ia_text_begin); +#else gSPDisplayList(gDisplayListHead++, dl_menu_ia8_text_begin); +#endif gDPSetEnvColor(gDisplayListHead++, 0, 0, 0, 255); + // Print the name of the selected act. if (sVisibleStars != 0) { selectedActName = segmented_to_virtual(actNameTbl[COURSE_NUM_TO_INDEX(gCurrCourseNum) * 6 + sSelectedActIndex]); +#ifdef VERSION_CN + actNameX = get_str_x_pos_from_center(ACT_NAME_X, selectedActName, 16.0f); + print_generic_string(actNameX, 141, selectedActName); +#else actNameX = get_str_x_pos_from_center(ACT_NAME_X, selectedActName, 8.0f); print_menu_generic_string(actNameX, 81, selectedActName); +#endif } +#ifdef VERSION_CN + gSPDisplayList(gDisplayListHead++, dl_ia_text_end); + + gSPDisplayList(gDisplayListHead++, dl_menu_ia8_text_begin); + gDPSetEnvColor(gDisplayListHead++, 0, 0, 0, 255); +#endif + // Print the numbers above each star. for (i = 1; i <= sVisibleStars; i++) { starNumbers[0] = i; #ifdef VERSION_EU - print_menu_generic_string(143 - sVisibleStars * 15 + i * 30, 38, starNumbers); + print_menu_generic_string(128 - (sVisibleStars - 1) * 15 + i * 30, 38, starNumbers); #else - print_menu_generic_string(139 - sVisibleStars * 17 + i * 34, 38, starNumbers); + print_menu_generic_string(122 - (sVisibleStars - 1) * 17 + i * 34, 38, starNumbers); #endif } gSPDisplayList(gDisplayListHead++, dl_menu_ia8_text_end); - } +} /** * Geo function that Print act selector strings. *!@bug: This geo function is missing the third param. Harmless in practice due to o32 convention. */ #ifdef AVOID_UB -Gfx *geo_act_selector_strings(s16 callContext, UNUSED struct GraphNode *node, UNUSED void *context) { +Gfx *geo_act_selector_strings(s16 callContext, UNUSED struct GraphNode *node, UNUSED void *context) #else -Gfx *geo_act_selector_strings(s16 callContext, UNUSED struct GraphNode *node) { +Gfx *geo_act_selector_strings(s16 callContext, UNUSED struct GraphNode *node) #endif +{ if (callContext == GEO_CONTEXT_RENDER) { print_act_selector_strings(); } @@ -402,10 +430,11 @@ s32 lvl_update_obj_and_load_act_button_actions(UNUSED s32 arg, UNUSED s32 unused #ifndef VERSION_EU if ((gPlayer3Controller->buttonPressed & A_BUTTON) || (gPlayer3Controller->buttonPressed & START_BUTTON) - || (gPlayer3Controller->buttonPressed & B_BUTTON)) { + || (gPlayer3Controller->buttonPressed & B_BUTTON)) #else - if ((gPlayer3Controller->buttonPressed & (A_BUTTON | START_BUTTON | B_BUTTON | Z_TRIG))) { + if (gPlayer3Controller->buttonPressed & (A_BUTTON | START_BUTTON | B_BUTTON | Z_TRIG)) #endif + { #ifdef VERSION_JP play_sound(SOUND_MENU_STAR_SOUND, gGlobalSoundSource); #else diff --git a/text/cn/courses.h b/text/cn/courses.h new file mode 100644 index 00000000..0494a13e --- /dev/null +++ b/text/cn/courses.h @@ -0,0 +1,80 @@ +COURSE_ACTS(COURSE_BOB, _(" 1 炸弹王国"), + _(" 山顶上的炸弹王") , _(" 喏库诺库的田径锦标赛") , _(" 空中岛屿"), + _(" 炸弹王国的8枚红色硬币") , _(" 长翅膀的马力欧") , _(" 汪汪看守的铁门")) + +COURSE_ACTS(COURSE_WF, _(" 2 嘭嘭要塞"), + _(" 疯狂的嘭嘭王") , _(" 要塞之巅") , _(" 射向蓝天"), + _(" 浮岛上的红色硬币") , _(" 空降到摇篮岛") , _(" 破壁摘星")) + +COURSE_ACTS(COURSE_JRB, _(" 3 海盗湾"), + _(" 沉船里的宝藏") , _(" 出来玩吧海鳗") , _(" 海底岩洞的财宝"), + _(" 浮船上的红色硬币") , _(" 发射到石柱平台") , _(" 穿越急流")) + +COURSE_ACTS(COURSE_CCM, _(" 4 酷冰冰雪山"), + _(" 企鹅的滑梯") , _(" 该回家了企鹅宝宝") , _(" 大企鹅的滑雪比赛"), + _(" 冰雪中的8枚红色硬币") , _(" 帮助雪人寻找脑袋") , _(" 要用踢墙跳了")) + +COURSE_ACTS(COURSE_BBH, _(" 5 大嘘嘘鬼的城堡"), + _(" 马力欧猎鬼记") , _(" 嘘嘘鬼的旋转木马") , _(" 书房密室"), + _(" 寻找8枚红色硬币") , _(" 大嘘嘘鬼的阳台") , _(" 密室里的大眼睛")) + +COURSE_ACTS(COURSE_HMC, _(" 6 迷失洞窟"), + _(" 洞穴里的海怪") , _(" 移动平台的红色硬币") , _(" 金属马力欧"), + _(" 通过毒气洞窟") , _(" 迷宫里的紧急出口") , _(" 小心落下的巨石")) + +COURSE_ACTS(COURSE_LLL, _(" 7 岩浆地狱"), + _(" 融化斗斗帮主") , _(" 打败斗斗帮") , _(" 15块拼图中的8枚红色硬币"), + _(" 灼热的滚木陷阱") , _(" 跳进火山") , _(" 火山里的电梯之旅")) + +COURSE_ACTS(COURSE_SSL, _(" 8 酷热沙漠"), + _(" 还给我星星  秃鹫") , _(" 金字塔顶的闪光") , _(" 法老的珍宝"), + _(" 立于四柱之颠") , _(" 为了8枚红色硬币自由飞翔") , _(" 金字塔之谜")) + +COURSE_ACTS(COURSE_DDD, _(" 9 恐怖船坞"), + _(" 酷霸王的潜水艇") , _(" 湍流中的宝箱") , _(" 天才的杂技演员"), + _(" 急流勇进") , _(" 鳐鱼的奖励") , _(" 帽子收藏家")) + +COURSE_ACTS(COURSE_SL, _("10 雪人王国"), + _(" 大头雪人") , _(" 寒冷的斗斗") , _(" 冰雕迷宫"), + _(" 冰冻池塘圆舞曲") , _(" 雪地滑板与红色硬币") , _(" 爱斯基摩人的小屋")) + +COURSE_ACTS(COURSE_WDW, _("11 水下遗迹"), + _(" 箭头跳板") , _(" 水城之巅") , _(" 天空和水下的秘密"), + _(" 快速电梯——抓紧时间") , _(" 小镇里的8枚红色硬币") , _(" 快速穿过小镇")) + +COURSE_ACTS(COURSE_TTM, _("12 高高山脉"), + _(" 攀登高高的山脉") , _(" 神秘的小猴呦奇的笼子") , _(" 蘑菇上的红色硬币"), + _(" 山间滑道") , _(" 惊险水帘洞") , _(" 孤独的蘑菇")) + +COURSE_ACTS(COURSE_THI, _("13 小人国大人国"), + _(" 食人花") , _(" 大人国之巅") , _(" 喏库喏库又回来了"), + _(" 小人国的五个秘密") , _(" 花之子的红色硬币") , _(" 蠕动的花之子")) + +COURSE_ACTS(COURSE_TTC, _("14 摇摆古钟"), + _(" 跳进笼子") , _(" 小洞和钟摆") , _(" 跳上指针"), + _(" 时钟的顶楼") , _(" 恰好踏在移动的木块上") , _(" 正点的红色硬币")) + +COURSE_ACTS(COURSE_RR, _("15 彩虹之旅"), + _(" 穿梭在彩虹之间的飞行船") , _(" 云中城堡") , _(" 迷宫中收集硬币"), + _(" 风中摇荡") , _(" 狡猾的三角") , _(" 在彩虹之上的某处")) + +SECRET_STAR(COURSE_BITDW, _("   黑暗世界的酷霸王")) +SECRET_STAR(COURSE_BITFS, _("   火海中的酷霸王")) +SECRET_STAR(COURSE_BITS, _("   天空之城的酷霸王")) +SECRET_STAR(COURSE_PSS, _("   公主的秘密滑梯")) +SECRET_STAR(COURSE_COTMC, _("   金属帽的瀑布石洞")) +SECRET_STAR(COURSE_TOTWC, _("   飞行帽之塔")) +SECRET_STAR(COURSE_VCUTM, _("   护城河里的隐身帽")) +SECRET_STAR(COURSE_WMOTR, _("   飞越彩虹")) +SECRET_STAR(COURSE_SA, _("   秘密水族馆")) +SECRET_STAR(COURSE_CAKE_END, _("")) + +CASTLE_SECRET_STARS(_("   城堡里的隐藏星")) + +EXTRA_TEXT(0, _(" 城堡中的隐藏星")) +EXTRA_TEXT(1, _("")) +EXTRA_TEXT(2, _("")) +EXTRA_TEXT(3, _("")) +EXTRA_TEXT(4, _("")) +EXTRA_TEXT(5, _("")) +EXTRA_TEXT(6, _("")) diff --git a/text/cn/dialogs.h b/text/cn/dialogs.h new file mode 100644 index 00000000..99e6bf59 --- /dev/null +++ b/text/cn/dialogs.h @@ -0,0 +1,2306 @@ +// Parameters: dialog enum ID, (unused), lines per box, left offset, width + +DEFINE_DIALOG(DIALOG_000, 1, 6, 30, 200, _("\ +哇!你闯入炸弹\n\ +王国的战场啦。\n\ +你可以在这个壁\n\ +画世界里找到酷\n\ +霸王偷走的\n\ +力量之星。\n\ + \n\ +你可以先去问问\n\ +炸弹兵(按[B]键\n\ +开始对话),从\n\ +他和他的伙伴那\n\ +里可以得到帮\n\ +助。\n\ + \n\ +如果需要察看路\n\ +标,面对它,按\n\ +[B]键。按[A]键或[B]\n\ +键来翻页。你还\n\ +可以站在其他人\n\ +面前,按[B]键来\n\ +和他们对话。")) + +DEFINE_DIALOG(DIALOG_001, 1, 4, 95, 200, _("\ +当心!如果你在\n\ +这里瞎逛,随时\n\ +有可能被水珠炸\n\ +弹炸伤!那些敌\n\ +对的炸弹兵非常\n\ +好战,他们总是\n\ +想方设法来攻击\n\ +你。\n\ + \n\ +自从炸弹王得到\n\ +了力量之星,这\n\ +片草原就变得战\n\ +火纷飞。你能帮\n\ +我们找回力量之\n\ +星吗?穿过这座\n\ +桥,沿着左上的\n\ +小路可以找到炸\n\ +弹王。如果你夺\n\ +回力量之星,记\n\ +得一定要回来看\n\ +看我啊。")) + +DEFINE_DIALOG(DIALOG_002, 1, 4, 95, 200, _("\ +嘿!你听着,前\n\ +面很危险,一定\n\ +要小心噢!听好\n\ +我的忠告!\n\ + \n\ +穿过前面的两座\n\ +桥以后,一定要\n\ +小心天上坠落的\n\ +水珠炸弹。\n\ + \n\ +在山顶,你会找\n\ +到炸弹王,他可\n\ +是非常强大噢,\n\ +千万不要让他\n\ +抓到你啊!\n\ + \n\ +我们是站在你一\n\ +边的炸弹兵,你\n\ +随时都可以来找\n\ +我们帮忙。")) + +DEFINE_DIALOG(DIALOG_003, 1, 5, 95, 200, _("\ +谢谢,马力欧!\n\ +现在的炸弹王只\n\ +是一个哑弹了,\n\ +哈哈!但是,真\n\ +正的战斗才刚刚\n\ +开始。\n\ + \n\ +其余的力量之星\n\ +被其他敌人拿走\n\ +了。只有夺回更\n\ +多的力量之星,\n\ +你才可以打开通\n\ +往其它新世界的\n\ +大门。我的伙伴\n\ +们正在等着你,\n\ +别忘了去找他们\n\ +啊!他们会为你\n\ +准备好大炮的。")) + +DEFINE_DIALOG(DIALOG_004, 1, 3, 95, 200, _("\ +我们是爱好和平\n\ +的炸弹兵,所以\n\ +我们不用大炮。\n\ + \n\ +我们不会介意你\n\ +从大炮中发射出\n\ +去,我们会为你\n\ +准备好这一关卡\n\ +的所有大炮。\n\ +一路顺风!")) + +DEFINE_DIALOG(DIALOG_005, 1, 4, 30, 200, _("\ +嘿,马力欧。真\n\ +的是你打败了炸\n\ +弹王吗?厉害!\n\ +你一定很强大而\n\ +且行动迅速吧?\n\ +不过,你到底有\n\ +多快呢?可以追\n\ +上我吗?我可是\n\ +大名鼎鼎的喏库\n\ +喏库!哈…哈!\n\ +你赢不了我的!\n\ +你可以来试试,\n\ +我们来打个赌,\n\ +你和我来一次赛\n\ +跑比赛,终点就\n\ +是你打败炸弹王\n\ +的那个山顶。你\n\ +看怎么样?当我\n\ +说“开始”,就\n\ +开始比赛!\n\ + \n\ +好了,预备…\n\ + \n\ +  开始!  不")) + +DEFINE_DIALOG(DIALOG_006, 1, 3, 30, 200, _("\ +嘿!!!别当我\n\ +是傻瓜。下次记\n\ +得跑完全程!等\n\ +你真的想比赛的\n\ +时候再来找我!")) + +DEFINE_DIALOG(DIALOG_007, 1, 5, 30, 200, _("\ +哈呼…哈呼…\n\ +哇!你…真是…\n\ +好快…啊!真是\n\ +个疯子!这个给\n\ +你吧,你赢了!\n\ +我愿赌服输。")) + +DEFINE_DIALOG(DIALOG_008, 1, 4, 30, 200, _("\ +千万当心那个满\n\ +嘴铁牙带着锁链\n\ +的家伙!它很危\n\ +险!你靠近它,\n\ +按[C]▲键仔细看。\n\ +吓坏了,是吗?\n\ +再看看木桩上的\n\ +那枚红色硬币!\n\ + \n\ +当你收集了八枚\n\ +这样的硬币后,\n\ +桥那边的草地上\n\ +就会出现一颗\n\ +力量之星。")) + +DEFINE_DIALOG(DIALOG_009, 1, 5, 30, 200, _("\ +哇!好久不见!\n\ +你跑得更快了?\n\ +还是你更加狡猾\n\ +了?还是那些星\n\ +星给了你力量?\n\ +上次输给你我真\n\ +不甘心。现在是\n\ +我的主场,我们\n\ +再来比比如何?\n\ +终点就是风之峡\n\ +谷。预备?\n\ + \n\ +  开始!  不")) + +DEFINE_DIALOG(DIALOG_010, 1, 4, 30, 200, _("\ +你踩了飞行帽的\n\ +开关。戴上飞行\n\ +帽,你就可以在\n\ +空中飞翔了。\n\ + \n\ +从现在开始,所\n\ +有你找到的红色\n\ +砖块里都会跳出\n\ +飞行帽。\n\ + \n\ +要保存游戏吗?\n\ + \n\ +  是        否")) + +DEFINE_DIALOG(DIALOG_011, 1, 4, 30, 200, _("\ +你踩了金属帽的\n\ +开关。金属帽会\n\ +让马力欧无敌。\n\ + \n\ +从现在开始,所\n\ +有你找到的绿色\n\ +砖块里都会跳出\n\ +金属帽。\n\ + \n\ +要保存游戏吗?\n\ + \n\ +  是        否")) + +DEFINE_DIALOG(DIALOG_012, 1, 4, 30, 200, _("\ +你踩了隐身帽的\n\ +开关。隐身帽会\n\ +让马力欧透明,\n\ +敌人将看不见马\n\ +力欧。\n\ + \n\ +从现在开始,所\n\ +有你找到的蓝色\n\ +砖块里都会跳出\n\ +隐身帽。\n\ + \n\ +要保存游戏吗?\n\ + \n\ +  是        否")) + +DEFINE_DIALOG(DIALOG_013, 1, 5, 30, 200, _("\ +你已经夺回了\n\ +100枚硬币!\n\ +马力欧从城堡中\n\ +得到了更多的力\n\ +量。\n\ + \n\ +要保存游戏吗?\n\ + \n\ +  是        否")) + +DEFINE_DIALOG(DIALOG_014, 1, 4, 30, 200, _("\ +哇!又一颗力量\n\ +之星!马力欧从\n\ +城堡中得到了更\n\ +多的力量。\n\ + \n\ +要保存游戏吗?\n\ + \n\ +  没错!   不")) + +DEFINE_DIALOG(DIALOG_015, 1, 4, 30, 200, _("\ +你可以用拳头来\n\ +打败敌人。按[A]\n\ +键跳跃,按[B]键\n\ +出拳,按[A]键再\n\ +按[B]键踢脚。如\n\ +果你要把什么东\n\ +西举起来,也是\n\ +按[B]键,如果要\n\ +把它们扔出去,\n\ +再按一次[B]键。")) + +DEFINE_DIALOG(DIALOG_016, 1, 3, 30, 200, _("\ +跳上那个闪光的\n\ +龟壳,乘着它到\n\ +任何你想去的地\n\ +方!用它还可以\n\ +压碎那些敌人!")) + +DEFINE_DIALOG(DIALOG_017, 1, 4, 30, 200, _("\ +我是这里的统治\n\ +者炸弹王。\n\ + \n\ +你怎么敢爬上我\n\ +的山?你凭什么\n\ +站在我炸弹王的\n\ +山顶?你虽然侥\n\ +幸地躲过了我的\n\ +守卫,但永远不\n\ +可能逃出我的手\n\ +掌心…\n\ + \n\ +…你永远不可能\n\ +夺走我的力量之\n\ +星。马力欧,我\n\ +现在就要和你决\n\ +斗!\n\ + \n\ +如果你要我的力\n\ +量之星,你必须\n\ +在决斗中证明你\n\ +自己。\n\ + \n\ +你可以从我身后\n\ +抱起我,并把我\n\ +摔到这皇室的草\n\ +地上吗?我想你\n\ +永远也办不到!")) + +DEFINE_DIALOG(DIALOG_018, 1, 4, 30, 200, _("\ +我好困阿…我要\n\ +睡了…我可不希\n\ +望被别人打扰。\n\ +所以,请你走路\n\ +轻一点。")) + +DEFINE_DIALOG(DIALOG_019, 1, 2, 30, 200, _("\ +嘘!在走廊里请\n\ +放轻你的脚步!")) + +DEFINE_DIALOG(DIALOG_020, 1, 6, 95, 150, _("\ +亲爱的马力欧:\n\ +请到城堡来,我\n\ +特意为你烤了一\n\ +个大蛋糕。\n\ + \n\ +      桃花公主")) + +DEFINE_DIALOG(DIALOG_021, 1, 5, 95, 200, _("\ +欢迎你啊!\n\ + \n\ +这里没人!快滚\n\ +吧!不要再回来\n\ +了!\n\ + \n\ +哇…哈哈…哈!")) + +DEFINE_DIALOG(DIALOG_022, 1, 2, 95, 200, _("\ +你需要一把钥匙\n\ +来打开这扇门。")) + +DEFINE_DIALOG(DIALOG_023, 1, 3, 95, 200, _("\ +这把钥匙不行。\n\ +也许这是地下室\n\ +的钥匙。")) + +DEFINE_DIALOG(DIALOG_024, 1, 5, 95, 200, _("\ +你需要力量之星\n\ +来打开这扇门。\n\ +打败城堡中某幅\n\ +壁画中的敌人,\n\ +就能夺回一颗力\n\ +量之心。")) + +DEFINE_DIALOG(DIALOG_025, 1, 4, 95, 200, _("\ +打开这扇门需要\n\ +3颗力量之星。\n\ +你还缺少[%]颗。")) + +DEFINE_DIALOG(DIALOG_026, 1, 4, 95, 200, _("\ +打开这扇门需要\n\ +8颗力量之星。\n\ +你还缺少[%]颗。")) + +DEFINE_DIALOG(DIALOG_027, 1, 4, 95, 200, _("\ +打开这扇门需要\n\ +30颗力量之星。\n\ +你还缺少[%]颗。")) + +DEFINE_DIALOG(DIALOG_028, 1, 4, 95, 200, _("\ +打开这扇门需要\n\ +50颗力量之星。\n\ +你还缺少[%]颗。")) + +DEFINE_DIALOG(DIALOG_029, 1, 5, 95, 200, _("\ +要打开通往\n\ +“无尽的楼梯”\n\ +的门需要70颗\n\ +力量之星。\n\ + \n\ +哈…哈…哈!")) + +DEFINE_DIALOG(DIALOG_030, 1, 6, 30, 200, _("\ + \n\ +嗨!现在是朱盖\n\ +木兄弟的现场插\n\ +播,报道马力欧\n\ +的最新进展。他\n\ +已经学会了悄悄\n\ +接近敌人的技\n\ +巧,方法如下:\n\ +马力欧为了不让\n\ +脚步发出声音,\n\ +必须走得非常缓\n\ +慢。\n\ + \n\ +再次重播以前报\n\ +道过的摄像机使\n\ +用技巧,按[C]◀键\n\ +和[C]▶键从不同角\n\ +度来看马力欧,\n\ +按[C]▼键从远处观\n\ +察马力欧。如果\n\ +摄影机不能再移\n\ +动了,我们会用\n\ +嘟嘟声警告你。\n\ +这里是朱盖木兄\n\ +弟,现场报道完\n\ +毕。")) + +DEFINE_DIALOG(DIALOG_031, 1, 5, 30, 200, _("\ +不可能!你又赢\n\ +了我?!我花了\n\ +所有的积蓄买了\n\ +这双酷霸王1号\n\ +火箭跑鞋。我想\n\ +我应该把这颗力\n\ +量之星交给胜利\n\ +者,拿去吧!\n\ +马力欧,\n\ +恭喜你了!")) + +DEFINE_DIALOG(DIALOG_032, 1, 5, 30, 200, _("\ +如果你拿到了飞\n\ +行帽,你就可以\n\ +飞行了!带上飞\n\ +行帽,来一个三\n\ +级跳,在一条直\n\ +线上连续跳三次\n\ +就可以起飞了。\n\ +如果你戴着飞行\n\ +帽,从大炮里发\n\ +射出来的话,你\n\ +可以飞得更高!\n\ +在飞行过程中,\n\ +按[C]键可以左右\n\ +环视,按[Z]键可\n\ +以降落。")) + +DEFINE_DIALOG(DIALOG_033, 1, 6, 30, 200, _("\ +你好!你通过传\n\ +送管道来到了\n\ +桃花公主的城\n\ +堡。手柄的使用\n\ +很简单:按[A]键\n\ +来跳跃,按[B]键\n\ +来进攻或者读路\n\ +牌,用摇杆来控\n\ +制马力欧的行\n\ +动。好了,向城\n\ +堡出发!")) + +DEFINE_DIALOG(DIALOG_034, 1, 6, 30, 200, _("\ +下午好!这里是\n\ +朱盖木兄弟在公\n\ +主的城堡外向您\n\ +现场报道!\n\ + \n\ +马力欧已经到达\n\ +了现场,我们将\n\ +实况转播他在城\n\ +堡找回丢失的力\n\ +量之星。\n\ + \n\ +作为转播专家,\n\ +我们将选择最佳\n\ +角度来拍摄,但\n\ +你也可以按[C]键\n\ +来控制。\n\ + \n\ +如果摄影机不能\n\ +再移动了,我们\n\ +会用嘟嘟声警告\n\ +你。你还可以停\n\ +下来,按[C]▲键来\n\ +观察周围情况。\n\ + \n\ +按[A]键继续玩,\n\ +按[R]键可以切换\n\ +摄影机的视点。\n\ +一路上还会有很\n\ +多标记来帮你复\n\ +习这些操作。\n\ + \n\ +这是朱盖木兄弟\n\ +向您现场报导!")) + +DEFINE_DIALOG(DIALOG_035, 1, 5, 30, 200, _("\ +这里一共有四个\n\ +摄影机,或者说\n\ +『[C]』键。按[C]▲键\n\ +后,可以使用摇\n\ +杆来环视四周。\n\ + \n\ +一般来说,你会\n\ +从朱盖木的摄影\n\ +机来看马力欧。\n\ +这是推荐使用的\n\ +正常视点。\n\ + \n\ +你可以按[C]▶键来\n\ +改变角度。按[R]\n\ +键,切换到马力\n\ +欧的摄影机,摄\n\ +影机紧跟在马力\n\ +欧的身后。再按\n\ +一次[R]键,切换\n\ +到朱盖木的视\n\ +点。不管用朱盖\n\ +木的视点还是马\n\ +力欧的视点,按\n\ +[C]▼键来从远处观\n\ +察马力欧。")) + +DEFINE_DIALOG(DIALOG_036, 1, 5, 30, 200, _("\ +了望台\n\ +按[C]▲键环视四\n\ +周。别遗漏任何\n\ +东西哦。\n\ + \n\ +按[R]键切换到马\n\ +力欧的视点,再\n\ +按一次[R]键切换\n\ +回朱盖木的视\n\ +点。暂停游戏,\n\ +切换到“固定视\n\ +点”模式,按[R]\n\ +键把视点固定。\n\ +去试试看吧!")) + +DEFINE_DIALOG(DIALOG_037, 1, 2, 30, 200, _("\ +我赢了!你输\n\ +了!哈哈哈哈!\n\ +你不慢,但是我\n\ +是更好的滑雪运\n\ +动员!")) + +DEFINE_DIALOG(DIALOG_038, 1, 3, 95, 200, _("\ +力量之星起作用\n\ +了,门慢慢打开\n\ +了。")) + +DEFINE_DIALOG(DIALOG_039, 1, 4, 30, 200, _("\ +炸弹王有旨:\n\ +此处禁止参观。\n\ + \n\ +我绝对不会放弃\n\ +我的力量之星,\n\ +它的光芒之下隐\n\ +藏着城堡的能\n\ +量。\n\ +它是酷霸王赏赐\n\ +给我的宝物,它\n\ +会在我的国土里\n\ +保存得很好的!\n\ +我绝对不会透露\n\ +它的位置。不\n\ +过,可能有一点\n\ +点提示:在每一\n\ +个关卡的开始,\n\ +注意力量之星的\n\ +名字。\n\ + \n\ +——炸弹王")) + +DEFINE_DIALOG(DIALOG_040, 1, 3, 30, 200, _("\ +注意!警告!\n\ +下面是冰川的裂\n\ +缝。")) + +DEFINE_DIALOG(DIALOG_041, 1, 3, 30, 200, _("\ +我赢了!你输\n\ +了!哈哈哈!\n\ + \n\ +这就是你和我喏\n\ +库喏库比赛的结\n\ +果!\n\ + \n\ +下次祝你好运!")) + +DEFINE_DIALOG(DIALOG_042, 1, 4, 30, 200, _("\ +当心!独木桥!\n\ +小心慢行!\n\ + \n\ +你可以跳起抓住\n\ +峭壁的边缘,悬\n\ +挂在那里;慢慢\n\ +地往悬崖边走,\n\ +你也能抓住峭壁\n\ +的边缘。当你想\n\ +放手,可以按[Z]\n\ +键或向马力欧身\n\ +后的方向拉摇\n\ +杆。向上推摇杆\n\ +可以使马力欧爬\n\ +上峭壁。按[A]键\n\ +则是快速爬上峭\n\ +壁。")) + +DEFINE_DIALOG(DIALOG_043, 1, 5, 30, 200, _("\ +如果你跳起来并\n\ +且按住[A]键,你\n\ +就可以挂在高处\n\ +的物体上,就像\n\ +你抓住天上的飞\n\ +鸟一样。")) + +DEFINE_DIALOG(DIALOG_044, 1, 5, 95, 200, _("\ +是谁啊?谁吵醒\n\ +我了?现在还是\n\ +白天,我要睡\n\ +觉!\n\ + \n\ +喂!既然我醒\n\ +了,就跟我一起\n\ +来一次短途飞\n\ +行,如何?按住\n\ +[A]键抓住我,松\n\ +开[A]键,跳下。\n\ +只要我还飞得\n\ +动,我会带你到\n\ +任何你想去的\n\ +地方。\n\ +好了,我飞的时\n\ +候你要抓牢,并\n\ +注意我的影子。")) + +DEFINE_DIALOG(DIALOG_045, 1, 6, 95, 200, _("\ +哈呼…我快要飞\n\ +不动了。马力\n\ +欧,你应该紧急\n\ +着陆了,按[A]键\n\ +着陆。好吧,\n\ +再见了,\n\ + \n\ +再见!")) + +DEFINE_DIALOG(DIALOG_046, 1, 5, 30, 200, _("\ +你必须掌握非常\n\ +重要的三种跳跃\n\ +技巧。\n\ + \n\ +首先,试试看三\n\ +级跳。\n\ +先快跑,然后连\n\ +续跳三次,一、\n\ +二、三!如果你\n\ +掌握了正确的时\n\ +机,你就会跳得\n\ +非常高。\n\ + \n\ +接下来是远跳。\n\ +先跑起来,按[Z]\n\ +键蹲下,然后按\n\ +[A]键起跳,你可\n\ +以跳得很远。\n\ + \n\ +如果你要做踢墙\n\ +跳,按[A]键对着\n\ +墙起跳,当你碰\n\ +到墙壁时再次起\n\ +跳,你就可以跳\n\ +得更高。\n\ + \n\ +记住了吗?三级\n\ +跳,远跳和踢墙\n\ +跳。练习、练\n\ +习、再练习!\n\ +不学会它们,你\n\ +是没有希望拿到\n\ +所有的力量之星\n\ +的。")) + +DEFINE_DIALOG(DIALOG_047, 1, 2, 95, 200, _("\ +嗨!我会为你准\n\ +备好大炮!")) + +DEFINE_DIALOG(DIALOG_048, 1, 4, 30, 200, _("\ +雪山顶\n\ +小心雪山路滑!\n\ +请先去小木屋!")) + +DEFINE_DIALOG(DIALOG_049, 1, 5, 30, 200, _("\ +还记得那个踢墙\n\ +跳的技巧吗?那\n\ +是你到达非常高\n\ +的地方必须要掌\n\ +握的技巧。\n\ +使用摇杆从一面\n\ +墙跳到另一面\n\ +墙,掌握好摇杆\n\ +的方向来获得弹\n\ +跳动力。记住!\n\ +熟能生巧啊。")) + +DEFINE_DIALOG(DIALOG_050, 1, 4, 30, 200, _("\ +当你在斜面上\n\ +时,按住[Z]键来\n\ +蹲下滑行!\n\ +或在空中时按[Z]\n\ +键来用屁股重击\n\ +地面!\n\ +如果你站立不\n\ +动,蹲下,再起\n\ +跳,你就可来一\n\ +个后空翻!\n\ +记住了吗?\n\ +还有,跑动时,\n\ +蹲下起跳可以远\n\ +跳,或是蹲下,\n\ +爬行…\n\ +哦,还是慢慢\n\ +来,别担心学不\n\ +会。")) + +DEFINE_DIALOG(DIALOG_051, 1, 6, 30, 200, _("\ +攀爬非常容易!\n\ +如果你跳起来的\n\ +时候,碰到树、\n\ +旗杆或柱子,你\n\ +会自动地抓住它\n\ +们。如果再次按\n\ +[A]键,就可以跳\n\ +下。\n\ + \n\ +当你抓住旗杆、\n\ +柱子或是树时,\n\ +可以左右拔动摇\n\ +杆来围绕它们旋\n\ +转。当你爬到顶\n\ +时,向上推摇杆\n\ +可以做一个单手\n\ +倒立。以单手倒\n\ +立姿势跳下时可\n\ +以做一个漂亮的\n\ +落地动作。")) + +DEFINE_DIALOG(DIALOG_052, 1, 5, 30, 200, _("\ +原地站立按[Z]键\n\ +蹲下,再按[A]键\n\ +可以做一个很高\n\ +的后空翻。\n\ + \n\ +如果你要做侧空\n\ +翻,你可以先跑\n\ +起来,做一个急\n\ +转弯然后起跳。\n\ +无论你是做后空\n\ +翻还是侧空翻,\n\ +你的滞空时间都\n\ +很长。")) + +DEFINE_DIALOG(DIALOG_053, 1, 5, 30, 200, _("\ +有些时候,如果\n\ +你穿过一个圆环\n\ +或发现了一个隐\n\ +藏地点,就会有\n\ +一个红色的数字\n\ +出现。\n\ +如果你能触发5\n\ +个这样的数字,\n\ +就会有一个隐藏\n\ +的力量之星出\n\ +现。")) + +DEFINE_DIALOG(DIALOG_054, 1, 5, 30, 200, _("\ +欢迎来到冰雪滑\n\ +道!准备好!把\n\ +摇杆向前推可以\n\ +加速,向后拉摇\n\ +杆来减速。")) + +DEFINE_DIALOG(DIALOG_055, 1, 4, 30, 200, _("\ +嗨!马力欧,老\n\ +兄,最近如何?\n\ +你看起来好像雪\n\ +滑得不错。我一\n\ +看就知道你速度\n\ +挺快。不过,你\n\ +知道的,我可是\n\ +世界滑雪冠军!\n\ +你说什么?来场\n\ +比赛?\n\ +预备… \n\ + \n\ +  开始!  不")) + +DEFINE_DIALOG(DIALOG_056, 1, 6, 30, 200, _("\ +啊!你破了我的\n\ +纪录!太让人难\n\ +以置信了!你真\n\ +是太棒了!你终\n\ +于证明了你是最\n\ +快的。\n\ +我没有金牌给\n\ +你,但可以给你\n\ +这颗星星。\n\ +你赢得了它!")) + +DEFINE_DIALOG(DIALOG_057, 1, 4, 30, 200, _("\ +天啊!我的孩\n\ +子!你看到我的\n\ +孩子了吗?她是\n\ +我世界上最最爱\n\ +的孩子啊。(人\n\ +家都说她长得很\n\ +像我)我怎么也\n\ +想不起来我把她\n\ +拉在什么地方\n\ +了。\n\ +让我仔细想想,\n\ +我停下来抓\n\ +鱼,找一些冰\n\ +块,我,哦!\n\ + \n\ +我还是想不起!")) + +DEFINE_DIALOG(DIALOG_058, 1, 4, 30, 200, _("\ +你找到了我最珍\n\ +爱的孩子!你究\n\ +竟到哪里去了\n\ +啊?孩子!我要\n\ +怎么感谢你才好\n\ +呢?马力欧。\n\ +哦,我有…这个\n\ +力量之星。\n\ +拿去,请接受我\n\ +永远的感激之\n\ +情。")) + +DEFINE_DIALOG(DIALOG_059, 1, 4, 30, 200, _("\ +那不是我的孩\n\ +子!她根本一点\n\ +都不像我!她的\n\ +父母肯定担心死\n\ +了!")) + +DEFINE_DIALOG(DIALOG_060, 1, 4, 30, 200, _("\ +注意!\n\ +潜水必读!\n\ + \n\ +如果你在水下潜\n\ +的时间太长,你\n\ +就会缺氧。\n\ + \n\ +这时,你可以回\n\ +到水面上换气,\n\ +或在水底找一个\n\ +气泡或硬币来呼\n\ +吸。\n\ +按[A]键游泳。按\n\ +住[A]键可以慢慢\n\ +地稳稳地游。有\n\ +节奏地按[A]键可\n\ +以加快游泳的速\n\ +度。向上推摇\n\ +杆,并且按[A]键\n\ +来潜水。\n\ + \n\ +向下拉摇杆,并\n\ +同时按[A]键可以\n\ +回到水面。\n\ + \n\ +在接近水边的水\n\ +面,向下拉摇\n\ +杆,再按[A]键可\n\ +以跳出水面。")) + +DEFINE_DIALOG(DIALOG_061, 1, 4, 30, 200, _("\ + \n\ +注意!这里的水\n\ +很冷。千万不要\n\ +在这里游泳!\n\ +不是玩笑!\n\ + \n\ +——企鹅")) + +DEFINE_DIALOG(DIALOG_062, 1, 3, 30, 200, _("\ +藏在绿色砖块里\n\ +的就是神奇的金\n\ +属帽。\n\ +戴上它,你就可\n\ +以不怕火烧,也\n\ +不用担心敌人的\n\ +攻击,甚至在水\n\ +里你都不用呼\n\ +吸。\n\ + \n\ +但唯一的缺点就\n\ +是:你不能游泳\n\ +了!")) + +DEFINE_DIALOG(DIALOG_063, 1, 5, 30, 200, _("\ +隐身帽就藏在蓝\n\ +色的砖块里。如\n\ +果你戴上它,眼\n\ +睛先生也会被你\n\ +迷惑,因为谁也\n\ +看不见你。\n\ +就连大嘘嘘鬼也\n\ +会被你骗过去。\n\ +你还可以穿过一\n\ +些秘密的墙壁。")) + +DEFINE_DIALOG(DIALOG_064, 1, 5, 30, 200, _("\ +当你戴上了从红\n\ +色砖块里得到的\n\ +飞行帽时,你就\n\ +可以通过三级跳\n\ +起飞。\n\ +用摇杆控制马力\n\ +欧的方向,向下\n\ +拉摇杆可以上\n\ +升,向上推摇杆\n\ +下降。按[Z]键着\n\ +陆。")) + +DEFINE_DIALOG(DIALOG_065, 1, 6, 30, 200, _("\ +接下来是游泳\n\ +课!\n\ +按[A]键来蛙泳,\n\ +如果你按键频率\n\ +合适,就可以游\n\ +得很快。\n\ + \n\ +按住[A]键可以打\n\ +水前进,虽然\n\ +慢,但很稳。向\n\ +上推摇杆可以潜\n\ +水,向下拉则是\n\ +回到水面上。如\n\ +果要跳出水面,\n\ +则是向下拉住摇\n\ +杆,然后按[A]键\n\ +就可以了。\n\ + \n\ +怎么样,很简单\n\ +吧!\n\ + \n\ +别忘了,马力欧\n\ +在水底是不能呼\n\ +吸的,如果能量\n\ +表的值很低的时\n\ +候,记得回到水\n\ +面上让马力欧喘\n\ +一下气。\n\ + \n\ +还有一件事情:\n\ +你不能够打开水\n\ +下的门。")) + +DEFINE_DIALOG(DIALOG_066, 1, 5, 30, 200, _("\ +马力欧,是我,\n\ +桃花公主!\n\ + \n\ +你一定要小心!\n\ +酷霸王非常残\n\ +忍!他会喷出恐\n\ +怖的火焰把你烧\n\ +成焦炭。你要绕\n\ +到他的后面,按\n\ +[B]键抓住它的尾\n\ +巴。然后旋转摇\n\ +杆,你转得越\n\ +快,你就可以把\n\ +他扔得越远。\n\ + \n\ +按[C]键环视四周。\n\ +你必须把酷霸王\n\ +扔到四个角落的\n\ +炸弹上。瞄准好\n\ +后,再按[B]键把\n\ +酷霸王扔出去。\n\ + \n\ +祝你好运,马力\n\ +欧,我们的命运\n\ +就靠你了。")) + +DEFINE_DIALOG(DIALOG_067, 1, 5, 30, 200, _("\ +你的运气真是太\n\ +好了,马力欧!\n\ +桃花公主并不在\n\ +这里。哈哈哈!\n\ +好了,来吧,看\n\ +看你能不能抓住\n\ +我的尾巴!象你\n\ +这样的懦夫不可\n\ +能把我扔出去!\n\ +决不可能!\n\ +哈哈。")) + +DEFINE_DIALOG(DIALOG_068, 1, 5, 30, 200, _("\ +这里是岩浆地\n\ +狱!\n\ +如果你不小心被\n\ +火烧到,或是掉\n\ +进了岩浆,你会\n\ +被烫得满地乱\n\ +跳。但你仍然可\n\ +以控制马力欧。\n\ +只要你保持冷\n\ +静。")) + +DEFINE_DIALOG(DIALOG_069, 1, 6, 30, 200, _("\ +有时,你会在壁\n\ +画世界的尽头撞\n\ +上一些看不见的\n\ +墙壁,如果你正\n\ +在飞行的话,就\n\ +会被反弹回来。")) + +DEFINE_DIALOG(DIALOG_070, 1, 5, 30, 200, _("\ +你可以随时从壁\n\ +画的世界返回到\n\ +城堡。让马力欧\n\ +停下来后,\n\ +按START键\n\ +暂停游戏,选择\n\ +“退出关卡”就\n\ +可以了。\n\ + \n\ +你并不需要在一\n\ +个关卡中找到所\n\ +有的力量之星再\n\ +到另一个关卡中\n\ +去。\n\ + \n\ +你可以先到其它\n\ +地方去找力量之\n\ +星,然后再回来\n\ +拿比较难获得的\n\ +力量之星,这时\n\ +你也会变得熟练\n\ +多了。\n\ + \n\ +每当你找到一颗\n\ +力量之星时,关\n\ +于下一颗星的提\n\ +示就会显示到那\n\ +一关卡的开始画\n\ +面上。\n\ + \n\ +当然,你可以去\n\ +寻找任何一颗力\n\ +量之星,并不一\n\ +定要去找提示所\n\ +指的那一颗。")) + +DEFINE_DIALOG(DIALOG_071, 1, 3, 30, 200, _("\ +前方危险!\n\ +当心奇怪的烟!\n\ +不要吸气!如果\n\ +感到眩晕,跑到\n\ +更高处去呼吸呼\n\ +吸新鲜的空气!\n\ +圆圈:躲避所\n\ +箭头:出入口")) + +DEFINE_DIALOG(DIALOG_072, 1, 5, 30, 200, _("\ +前面有大风!把\n\ +帽子戴紧!以免\n\ +被风吹走,否\n\ +则,你必须在这\n\ +座山找回你的帽\n\ +子。")) + +DEFINE_DIALOG(DIALOG_073, 1, 4, 95, 200, _("\ +啊哈,朋友,这\n\ +里有我沉没的财\n\ +宝。如果你想得\n\ +到它的话,你要\n\ +按照正确的顺序\n\ +打开箱子。是什\n\ +么顺序呢?你知\n\ +道吗?\n\ + \n\ +我是决不会说出 \n\ +来的。\n\ + \n\ +——船长")) + +DEFINE_DIALOG(DIALOG_074, 1, 5, 30, 200, _("\ +你可以抓住悬崖\n\ +或一些建筑物的\n\ +边缘,并悬挂在\n\ +上面。\n\ + \n\ +如果想跳下来,\n\ +向马力欧背对的\n\ +方向拉摇杆,或\n\ +按[Z]键。\n\ +要爬上悬崖,可\n\ +以向上推摇杆或\n\ +按[A]键,这样可\n\ +以快速地爬上悬\n\ +崖。")) + +DEFINE_DIALOG(DIALOG_075, 1, 5, 30, 200, _("\ +马力欧!!我的\n\ +城堡陷入了危\n\ +机。我知道这是\n\ +酷霸王干的,而\n\ +且我知道你是唯\n\ +一可以解救我们\n\ +的人!\n\ +城堡里的门已经\n\ +被酷霸王封起来\n\ +了,只有力量之\n\ +星的能量才能打\n\ +开它们。\n\ + \n\ +但是城堡里还有\n\ +一些秘密通道,\n\ +酷霸王还没有发\n\ +现它们。\n\ + \n\ +其中一个通道就\n\ +在这个房间里,\n\ +而且那里还有一\n\ +颗力量之星!\n\ + \n\ +马力欧,去找到\n\ +这颗隐藏的力量\n\ +之星吧,它会帮\n\ +助你的。请你一\n\ +定要救救我们,\n\ +帮我们找回所有\n\ +的力量之星,把\n\ +我们从这个恐怖\n\ +的监狱中解救出\n\ +来。")) + +DEFINE_DIALOG(DIALOG_076, 1, 6, 30, 200, _("\ +感谢力量之星的\n\ +能量,城堡又恢\n\ +复了生机。马力\n\ +欧,你一定要给\n\ +酷霸王最后一击。\n\ + \n\ +现在,让我告诉\n\ +你一些关于城堡\n\ +的秘密吧。在那\n\ +些有镜子的房间\n\ +里,仔细的去找\n\ +一些在镜子中不\n\ +反射的东西。等\n\ +你去水城的时\n\ +候,你可以来一\n\ +个超高跳,跳进\n\ +壁画当中。猜猜\n\ +看,我们会看见\n\ +什么?")) + +DEFINE_DIALOG(DIALOG_077, 1, 2, 150, 200, _("\ +你要去撞击这里\n\ +的柱子,这是法\n\ +令!")) + +DEFINE_DIALOG(DIALOG_078, 1, 5, 30, 200, _("\ +你可以按[Z]键用\n\ +力撞击地面上的\n\ +蓝色硬币砖块去\n\ +获得蓝色硬币。\n\ +一个蓝色硬币相\n\ +当于五个黄色硬\n\ +币。但是你的动\n\ +作一定要快,否\n\ +则它就会消失,\n\ +那就太可惜了。")) + +DEFINE_DIALOG(DIALOG_079, 1, 4, 30, 200, _("\ +哇哦!放我走!\n\ +嘻嘻!我只是开\n\ +个玩笑而已。难\n\ +道你没有点幽默\n\ +感吗?\n\ +但是,你听我\n\ +说,我们做个交\n\ +易吧。如果你放\n\ +我走的话,我可\n\ +以给你一个难得\n\ +的宝物。\n\ + \n\ +怎么样?接受我\n\ +的条件吗?\n\ + \n\ +  放        不放")) + +DEFINE_DIALOG(DIALOG_080, 1, 1, 30, 200, _("\ +咿嘿嘿嘿!")) + +DEFINE_DIALOG(DIALOG_081, 1, 4, 30, 200, _("\ +神秘的水位。\n\ +答案在哪里呢?\n\ +这座城市非常欢\n\ +迎那些当他们进\n\ +入时有深度的访\n\ +问者。")) + +DEFINE_DIALOG(DIALOG_082, 1, 4, 30, 200, _("\ +带好你的帽子\n\ +啊,如果你丢了\n\ +帽子,你会很容\n\ +易受到敌人的伤\n\ +害。\n\ + \n\ +如果你真的丢了\n\ +帽子的话,你要\n\ +在这个关卡中找\n\ +到它。它就在你\n\ +丢掉的地方。\n\ +哦,孩子,桃花\n\ +公主的情况看起\n\ +来不太好,她现\n\ +在还被困在城堡\n\ +的某面墙里。你\n\ +一定要帮助她\n\ +啊。你知道墙里\n\ +的世界有很多敌\n\ +人吗?真的!酷\n\ +霸王的军队也在\n\ +那里。哦,这个\n\ +给你吧,我早为\n\ +你准备好了。")) + +DEFINE_DIALOG(DIALOG_083, 1, 6, 30, 200, _("\ +这个钟有一点奇\n\ +怪啊,你跳进去\n\ +的时候,注意那\n\ +个大指针的位\n\ +置。噢,你瞧我\n\ +发现了什么!这\n\ +里!马力欧,快\n\ +来啊!")) + +DEFINE_DIALOG(DIALOG_084, 1, 3, 30, 200, _("\ +哦!放开我,你\n\ +这个家伙!我要\n\ +迟到了!已经这\n\ +么晚了!我必须\n\ +要赶快了!什\n\ +么?这个闪闪发\n\ +光的东西?是我\n\ +的!我是发现\n\ +者!收藏者!失\n\ +主!啊!晚了,\n\ +来不及了,迟到\n\ +了!哦!拿去!\n\ +那是酷霸王的礼\n\ +物!\n\ +好了,快让我走\n\ +吧!我有约会!\n\ +我不能迟到!")) + +DEFINE_DIALOG(DIALOG_085, 1, 5, 30, 200, _("\ +你在这个房子里\n\ +是不会有机会\n\ +的。如果你走出\n\ +这里一步,你就\n\ +会得到……盗墓者\n\ +…奖章 ")) + +DEFINE_DIALOG(DIALOG_086, 1, 3, 30, 200, _("\ +一直绕圈跑可以\n\ +让一些坏家伙眼\n\ +花缭乱。")) + +DEFINE_DIALOG(DIALOG_087, 1, 4, 30, 200, _("\ +不光是圣诞老人\n\ +才可以钻进烟\n\ +囱,你也可以,\n\ +请进吧。\n\ + \n\ +——小屋主人")) + +DEFINE_DIALOG(DIALOG_088, 1, 5, 30, 200, _("\ +工作电梯\n\ +如果要从这里出\n\ +去,抓住左边的\n\ +柱子,小心地滑\n\ +下去。")) + +DEFINE_DIALOG(DIALOG_089, 1, 5, 95, 200, _("\ +两条路都充满了\n\ +危险。小心啊。\n\ +如果你现在还不\n\ +会远跳,啧啧,\n\ +走右边的一条路\n\ +吧。\n\ + \n\ +右:工作电梯 \n\ +      浓雾迷宫\n\ + \n\ +左:黑洞\n\ +      地下湖\n\ + \n\ +红色圆圈:\n\ +        电梯2\n\ +        地下湖\n\ +     \n\ +箭头:你在这里")) + +DEFINE_DIALOG(DIALOG_090, 1, 6, 30, 200, _("\ +哇哈哈哈!\n\ +你终于落入我的\n\ +陷阱了!我果然\n\ +没有猜错。我警\n\ +告你,『朋友』!\n\ +当心你的脚步!")) + +DEFINE_DIALOG(DIALOG_091, 2, 2, 30, 200, _("\ +危险!\n\ +狂风!\n\ +但你可以乘风而\n\ +行。")) + +DEFINE_DIALOG(DIALOG_092, 1, 5, 30, 200, _("\ +又是你!马力\n\ +欧!你又来烦我\n\ +了!难道你没看\n\ +见我刚刚开心一\n\ +会儿吗?快点把\n\ +那些星星还给\n\ +我!我的手下们\n\ +需要它们!\n\ +哈哈哈!")) + +DEFINE_DIALOG(DIALOG_093, 1, 5, 30, 200, _("\ +马力欧!又是\n\ +你!正好,我正\n\ +想吐火烤烤什么\n\ +东西!你的星星\n\ +对我根本没有作\n\ +用!你的朋友们\n\ +都被困在墙壁里\n\ +了…\n\ +你再也看不到桃\n\ +花公主了!\n\ +哈哈哈哈!")) + +DEFINE_DIALOG(DIALOG_094, 1, 4, 30, 200, _("\ +如何顺利地跑上\n\ +斜坡呢?还记不\n\ +记得远跳?跑起\n\ +来,按[Z]键再起\n\ +跳!")) + +DEFINE_DIALOG(DIALOG_095, 1, 4, 30, 200, _("\ +你可以站在一个\n\ +标记的前面,按\n\ +[B]键来读上面的\n\ +内容。\n\ + \n\ +当你要和别人讲\n\ +话时,站在他们\n\ +面前,按[B]键。\n\ +一定要夺回这一\n\ +关卡酷霸王偷走\n\ +的力量之星。")) + +DEFINE_DIALOG(DIALOG_096, 1, 4, 30, 200, _("\ +从这里开始,路\n\ +会变得很窄。当\n\ +心点。任何人都\n\ +不可以去山顶。\n\ +如果你不想有什\n\ +么意外的话,记\n\ +得放慢你的脚\n\ +步,轻轻地走,\n\ +千万别吵醒正在\n\ +睡觉的人。")) + +DEFINE_DIALOG(DIALOG_097, 1, 5, 30, 200, _("\ +别做胆小鬼啊。\n\ +如果有人要推你\n\ +的话,用力反击\n\ +吧。这可是一对\n\ +一的较量,失败\n\ +者是不会有好下\n\ +场的。")) + +DEFINE_DIALOG(DIALOG_098, 1, 2, 95, 200, _("\ +快到这儿来… \n\ +呵…呵呵… ")) + +DEFINE_DIALOG(DIALOG_099, 1, 5, 95, 200, _("\ +哦呵呵… \n\ +你是我的了。\n\ +哼哼!\n\ +我可以安然无恙\n\ +地穿过这面墙,\n\ +你能吗?\n\ +呵呵…呵呵…… ")) + +DEFINE_DIALOG(DIALOG_100, 1, 3, 95, 200, _("\ +哈,我拦住它\n\ +啦!是我的啦!\n\ +嘿,嘿,嘿嘿!")) + +DEFINE_DIALOG(DIALOG_101, 1, 3, 95, 200, _("\ +啊欠,走…吧… \n\ +你让我透不过气\n\ +了,咳呵,我被\n\ +你害苦了!这顶\n\ +帽子?哦,好\n\ +吧,拿去吧。这\n\ +顶帽子真酷,不\n\ +过,我会还回来\n\ +的。我觉得我比\n\ +你更合适戴它。\n\ +呵呵…呵呵… ")) + +DEFINE_DIALOG(DIALOG_102, 1, 5, 30, 200, _("\ +嘘,这些嘘嘘鬼\n\ +非常非常害羞,\n\ +如果你看着它们,\n\ +它们就会消失。\n\ +但如果你转过\n\ +身,它们就会重\n\ +新出现。在它们\n\ +消失时攻击它们\n\ +是没用的,你要\n\ +悄悄地绕到它们\n\ +身后才能打到它\n\ +们。")) + +DEFINE_DIALOG(DIALOG_103, 1, 4, 95, 200, _("\ +四个塔上一定有\n\ +一个塔在发光…\n\ +在那个塔的顶\n\ +端将可以看到\n\ +灯光在闪烁。")) + +DEFINE_DIALOG(DIALOG_104, 1, 5, 30, 200, _("\ +在你面前暗色的\n\ +星星只是一个\n\ +『星星的标记』。\n\ +当你收集到所有\n\ +8枚红色硬币,\n\ +星星就在这里出\n\ +现。")) + +DEFINE_DIALOG(DIALOG_105, 1, 3, 95, 200, _("\ +准备发射!来\n\ +吧,跳进大炮!\n\ + \n\ +你可以用四门大\n\ +炮到达有星星的\n\ +空中岛屿,用摇\n\ +杆瞄准,然后按\n\ +[A]键发射。\n\ + \n\ +如果你够敏捷,\n\ +抓住小树或杆\n\ +子,你便可以登\n\ +上小岛了。")) + +DEFINE_DIALOG(DIALOG_106, 1, 2, 95, 200, _("\ +准备发射!来吧,\n\ +跳进大炮!")) + +DEFINE_DIALOG(DIALOG_107, 1, 3, 95, 200, _("\ +鬼,鬼… \n\ +不要… \n\ +…死了!\n\ +呵呵…呵呵… \n\ +你能…活着离\n\ +开这里吗?")) + +DEFINE_DIALOG(DIALOG_108, 1, 2, 95, 200, _("\ +轰!这个城堡的\n\ +恶作剧之王大嘘\n\ +嘘鬼来啦。\n\ +哈哈…哈哈… ")) + +DEFINE_DIALOG(DIALOG_109, 1, 4, 95, 200, _("\ +哦…不… \n\ +跟你说说我丧失\n\ +身体的经历吧,\n\ +我的身体已经融\n\ +化掉了!有没有\n\ +人拖你寻找脑\n\ +袋?我一定可以\n\ +得到一个新的身\n\ +体的!哦,我的\n\ +脸可能会冻成这\n\ +样!")) + +DEFINE_DIALOG(DIALOG_110, 1, 5, 95, 200, _("\ +我需要在肩上架\n\ +个好脑袋。你知\n\ +道谁需要强壮的\n\ +身体?如果你知\n\ +道的话,我就跟\n\ +你走。")) + +DEFINE_DIALOG(DIALOG_111, 1, 4, 95, 200, _("\ +太好了!多完美\n\ +的身体啊!这是\n\ +给你的礼物,我\n\ +担保它能使你觉\n\ +得更温暖。")) + +DEFINE_DIALOG(DIALOG_112, 1, 4, 30, 200, _("\ +尽量收集更多的\n\ +硬币!它们能补\n\ +充你的能量值。\n\ + \n\ +你可以检查一下\n\ +你在15个关卡\n\ +里一共收集了多\n\ +少硬币。\n\ + \n\ +你也可以触摸旋\n\ +转的心来恢复能\n\ +量。\n\ + \n\ +你越快穿过心,\n\ +就能恢复越多的\n\ +能量。")) + +DEFINE_DIALOG(DIALOG_113, 1, 6, 30, 200, _("\ +红色,绿色,蓝\n\ +色的砖块里藏有\n\ +很特殊的帽子。\n\ +踩在隐秘关卡里\n\ +的开关上就可以\n\ +激活这些藏有帽\n\ +子的砖块。")) + +DEFINE_DIALOG(DIALOG_114, 1, 5, 95, 200, _("\ +真让人气愤!我\n\ +们帮你建造房屋\n\ +和城堡,铺设道\n\ +路,你却还在我\n\ +们身上散步。你\n\ +说过一声谢谢\n\ +吗?没有!\n\ +好吧,既然你不\n\ +准备从我身上拿\n\ +开你的臭脚,那\n\ +我就要把你压\n\ +碎!\n\ +来吧,懦夫!")) + +DEFINE_DIALOG(DIALOG_115, 1, 5, 95, 200, _("\ +不,又被压碎\n\ +了!我只是一块\n\ +垫脚的石头而\n\ +已,不是沙砾。\n\ +嗯,我投降,你\n\ +赢了,拿去吧!")) + +DEFINE_DIALOG(DIALOG_116, 1, 5, 95, 200, _("\ +什…么… \n\ +你就是打败炸弹\n\ +王的小东西?你\n\ +也许能很快打败\n\ +我,但是如果你\n\ +想抓住酷霸王的\n\ +尾巴,你就必须\n\ +更快!我想我的\n\ +手下会从你这儿\n\ +得到一些教训,\n\ +马力欧,我会遵\n\ +守诺言,这是你\n\ +的星星。\n\ + \n\ +如果你想再见到\n\ +我,你可以从菜\n\ +单里选择这颗星\n\ +星。再见啦!!")) + +DEFINE_DIALOG(DIALOG_117, 1, 2, 95, 200, _("\ +谁…在…走?\n\ +谁…打破了…\n\ +封印?\n\ +谁…吵醒了…\n\ +老人?\n\ +我们不喜欢光… \n\ +哦哦哦哦… \n\ +我们不喜欢入侵\n\ +者… \n\ +战斗吧… \n\ +来吧…\n\ +来吧…!")) + +DEFINE_DIALOG(DIALOG_118, 1, 6, 95, 200, _("\ +哦…哦…哦…\n\ +怎么啦?\n\ +我们怎么像鹅卵\n\ +石一样被压碎\n\ +了?你太强大\n\ +了!你统治了古\n\ +老的金字塔。\n\ +今天… \n\ +你获得了力量之\n\ +星… \n\ +我们沉睡在… \n\ +在黑暗中… ")) + +DEFINE_DIALOG(DIALOG_119, 1, 6, 30, 200, _("\ +啊,我太粗心。\n\ +这出乎了我的意\n\ +料…但我仍然拥\n\ +有星星的力量,\n\ +拥有桃花公主。\n\ +哈哈…哈哈… \n\ +你不会再从我这\n\ +儿得到任何星\n\ +星!我跟你没\n\ +完,不过,我先\n\ +放你走,你会为\n\ +此付出代价的!")) + +DEFINE_DIALOG(DIALOG_120, 1, 4, 30, 200, _("\ +噢!我输了?星\n\ +星的力量打败了\n\ +我… \n\ +这次打个平手。\n\ +下次,我的状态\n\ +会很好的。\n\ + \n\ +如果你现在想要\n\ +见你可爱的公\n\ +主,到塔的最顶\n\ +层来吧。\n\ +我等着你!\n\ +哈哈哈哈… ")) + +DEFINE_DIALOG(DIALOG_121, 1, 5, 30, 200, _("\ +不,不可能!\n\ +你打败了我,马\n\ +力欧?!我给了\n\ +那些军队力量,\n\ +但是它们正在消\n\ +失!啊!我看到\n\ +和平正在重回世\n\ +界!我无法忍\n\ +受!哼…一切还\n\ +没有结束… \n\ +\n\ +来,我的军队!\n\ +让我们一起来看\n\ +看这场战斗的结\n\ +局!\n\ +哈哈…")) + +DEFINE_DIALOG(DIALOG_122, 1, 4, 30, 200, _("\ +黑洞\n\ +右:工作电梯 \n\ +      浓雾迷宫\n\ + \n\ +左:黑洞\n\ +      地下湖")) + +DEFINE_DIALOG(DIALOG_123, 1, 4, 30, 200, _("\ +金属洞穴\n\ +右:通向瀑布\n\ +左:金属帽开关")) + +DEFINE_DIALOG(DIALOG_124, 1, 4, 30, 200, _("\ +工作电梯\n\ +危险!\n\ +请仔细阅读使用\n\ +说明!\n\ +电梯会朝激活的\n\ +箭头方向行驶。")) + +DEFINE_DIALOG(DIALOG_125, 1, 3, 30, 200, _("\ +迷失洞窟出口\n\ +危险!已关闭。\n\ +请往回走。")) + +DEFINE_DIALOG(DIALOG_126, 2, 3, 30, 200, _("\ +上:黑洞\n\ +右:工作电梯\n\ +      迷失洞窟")) + +DEFINE_DIALOG(DIALOG_127, 3, 4, 30, 200, _("\ +地下湖泊\n\ +右:金属洞穴\n\ +左:废弃矿洞\n\ +    (关闭)\n\ + \n\ +这里住着一条温\n\ +顺的海龙王,敲\n\ +打它的后背可以\n\ +让它低下头。可\n\ +别成为它的午餐\n\ +噢!")) + +DEFINE_DIALOG(DIALOG_128, 1, 4, 95, 200, _("\ +你和我战斗必须\n\ +尊敬我!你把我\n\ +扔到圈外是违反\n\ +皇室规则的。")) + +DEFINE_DIALOG(DIALOG_129, 1, 5, 30, 200, _("\ +欢迎来到护城河\n\ +里的隐身帽关\n\ +卡!当你踏上帽\n\ +子的开关,所有\n\ +的蓝色砖块就会\n\ +变成实心。当你\n\ +戴上隐身帽时,\n\ +你会消失,并且\n\ +可以躲避敌人和\n\ +穿越许多障碍。\n\ +快去试一试吧!")) + +DEFINE_DIALOG(DIALOG_130, 1, 5, 30, 200, _("\ +欢迎来到金属帽\n\ +的瀑布石洞关\n\ +卡!一旦你踩上\n\ +金属帽开关,绿\n\ +色的砖块会变成\n\ +实心的。当你戴\n\ +上金属帽后,你\n\ +就可以在水下漫\n\ +步了!快去试一\n\ +试吧!")) + +DEFINE_DIALOG(DIALOG_131, 1, 5, 30, 200, _("\ +欢迎来到飞行帽\n\ +之塔关卡!踩上\n\ +位于彩虹塔顶的\n\ +红色开关,所有\n\ +的红色砖块将变\n\ +为实心的。\n\ + \n\ +快戴上飞行帽!\n\ +来个三级跳,按\n\ +[Z]键着陆。\n\ + \n\ +就象你驾驶飞机\n\ +一样,遥杆向下\n\ +拉时,飞机上\n\ +升;向前推时,\n\ +飞机下降。")) + +DEFINE_DIALOG(DIALOG_132, 1, 4, 30, 200, _("\ +哇哦,马力欧,\n\ +你不许耍赖哦!\n\ +不能抄近路哦!\n\ +现在,我知道你\n\ +懂道理。这次,\n\ +你被取消资格!\n\ +下次,我们再公\n\ +平竞争!")) + +DEFINE_DIALOG(DIALOG_133, 1, 6, 30, 200, _("\ +见到你真高兴!\n\ +公主…我…这么\n\ +说吧,大家都被\n\ +困在城堡的墙壁\n\ +里了。\n\ + \n\ +酷霸王偷走了城\n\ +堡的力量之星,\n\ +他正利用城堡之\n\ +星的力量创造自\n\ +己的壁画和墙壁\n\ +里的世界。\n\ + \n\ +请快去找力量之\n\ +星!一旦找到它\n\ +们,你可以借助\n\ +它们的力量打开\n\ +被酷霸王封印的\n\ +门。\n\ + \n\ +第一层有四个房\n\ +间。你可以从有\n\ +炸弹人画像的房\n\ +间开始。那是唯\n\ +一没有被他封印\n\ +的房间。当你收\n\ +集到八颗力量之\n\ +星,你就可以打\n\ +开那个有颗巨大\n\ +星星的门。公主\n\ +就在那等你呢!")) + +DEFINE_DIALOG(DIALOG_134, 1, 5, 30, 200, _("\ +力量之星的名称\n\ +也是找到它们的\n\ +提示哦。它们会\n\ +在每关开始时出\n\ +现。\n\ + \n\ +你不用按顺序收\n\ +集。如果你不去\n\ +找一些特殊的星\n\ +星,你就会找不\n\ +到一些其它的星\n\ +星、敌人或特殊\n\ +的物品。\n\ +等你收集到一些\n\ +力量之星后,你\n\ +就可以尝试其它\n\ +关卡了。\n\ +我们都要指望你\n\ +了!")) + +DEFINE_DIALOG(DIALOG_135, 1, 5, 30, 200, _("\ +我亲眼看见酷霸\n\ +王偷走了星星!\n\ + \n\ +他在每个关卡里\n\ +藏了六颗星星,\n\ +但是除非你激活\n\ +了几个特殊帽子\n\ +的开关,你才能\n\ +找到全部的星\n\ +星。\n\ + \n\ +如果你想去见见\n\ +那些被你打败的\n\ +敌人,只要选择\n\ +你从他那里得到\n\ +的星星的名字就\n\ +可以了。")) + +DEFINE_DIALOG(DIALOG_136, 1, 6, 30, 200, _("\ +哇哦!你已经获\n\ +得到那么多力量\n\ +之星啦?\n\ +加油,马力欧!\n\ +我打赌你一定马\n\ +上就可以带我们\n\ +离开这里了!\n\ + \n\ +尽管这样,你还\n\ +是要小心点。酷\n\ +霸王他们一伙人\n\ +设了许多陷阱。\n\ +听我的话:当你\n\ +要恢复能量时,\n\ +记得去收集硬\n\ +币。黄色的可以\n\ +恢复一格能量;\n\ +红色的可以恢复\n\ +两格,蓝色的可\n\ +以恢复五格哦!\n\ + \n\ +只要压碎蓝色硬\n\ +币的砖块,蓝色\n\ +硬币就会出现。\n\ + \n\ +当然,如果你从\n\ +很高的地方掉下\n\ +来,你也可以在\n\ +着陆时重击地面\n\ +来减轻伤害。")) + +DEFINE_DIALOG(DIALOG_137, 1, 6, 30, 200, _("\ +谢谢,马力欧!\n\ +因为你夺回了力\n\ +量之星,把酷霸\n\ +王从这里赶了出\n\ +去,城堡恢复了\n\ +能量。\n\ +哦,顺便问一\n\ +下,你收集硬币\n\ +了吗?在这15\n\ +个关卡里,每收\n\ +集到100枚硬\n\ +币就会出现一个\n\ +特殊的星星哦!")) + +DEFINE_DIALOG(DIALOG_138, 1, 3, 30, 200, _("\ +下面:地下湖\n\ +左面:黑洞\n\ +右面:迷失洞窟\n\ +       (已关闭)")) + +DEFINE_DIALOG(DIALOG_139, 1, 6, 30, 200, _("\ +上面:自动电梯\n\ +电梯自动启动,\n\ +到达预定关卡。\n\ +它也会自动消\n\ +失!。")) + +DEFINE_DIALOG(DIALOG_140, 1, 6, 30, 200, _("\ +电梯区域:\n\ +右边:迷失洞窟\n\ +         入口\n\ +左边:黑洞入口\n\ +         电梯 1\n\ +箭头:你在这里")) + +DEFINE_DIALOG(DIALOG_141, 1, 5, 150, 200, _("\ +你找到了1颗被\n\ +盗的力量之星!\n\ +现在你可以打开\n\ +城堡里一些被封\n\ +印的门了。\n\ +试一试二楼公主\n\ +的房间和一楼的\n\ +有嘭嘭要塞壁画\n\ +的房间。\n\ +酷霸王那伙人仍\n\ +然在不断强大之\n\ +中,所以你不能\n\ +掉以轻心。快来\n\ +救我们吧,马力\n\ +欧!继续寻找力\n\ +量之星!")) + +DEFINE_DIALOG(DIALOG_142, 1, 5, 150, 200, _("\ +你已经夺回了3\n\ +颗力量之星啦!\n\ +现在你可以打开\n\ +有3标记的大门\n\ +了。\n\ + \n\ +如果你乐意,你\n\ +可以从打开封印\n\ +的关卡回来。前\n\ +面的敌人很难\n\ +缠,所以一定小\n\ +心!")) + +DEFINE_DIALOG(DIALOG_143, 1, 6, 150, 200, _("\ +你夺回了8颗力\n\ +量之星了哦!现\n\ +在你可以打开那\n\ +个有大星星的门\n\ +了!但是酷霸王\n\ +也在那里…你听\n\ +见公主的声音了\n\ +吗?")) + +DEFINE_DIALOG(DIALOG_144, 1, 6, 150, 200, _("\ +你夺回了30颗\n\ +力量之星了哦!\n\ +现在你可以打开\n\ +那个有大星星的\n\ +门了!但在你走\n\ +之前,那些事情\n\ +做的怎么样了?\n\ + \n\ +你有没有把那两\n\ +个圆柱压下去?\n\ +你也没有把你的\n\ +帽子给丢了吧?\n\ +如果掉了,你就\n\ +不得不到秃鹫强\n\ +哥那里去把它找\n\ +回来!\n\ +他们说酷霸王已\n\ +经潜出大海,进\n\ +入地下了。你有\n\ +没有把他困住?")) + +DEFINE_DIALOG(DIALOG_145, 1, 6, 150, 200, _("\ +你夺回了50颗\n\ +力量之星啊!\n\ +现在快去三楼打\n\ +开星星之门。\n\ +酷霸王就在那里\n\ +等你。\n\ + \n\ +你找到了所有的\n\ +金属帽开关了\n\ +么?红的,绿的\n\ +和蓝的?你从彩\n\ +色砖块里得到的\n\ +帽子很有用的。\n\ +抓紧吧,快去第\n\ +三层吧。")) + +DEFINE_DIALOG(DIALOG_146, 1, 6, 150, 200, _("\ +你已经找到了\n\ +70颗力量之星\n\ +了!你揭开了无\n\ +尽楼梯的秘密,\n\ +真是多亏了你\n\ +——酷霸王就在最\n\ +上面!去吧!\n\ +去迎接你最后的\n\ +挑战吧!")) + +DEFINE_DIALOG(DIALOG_147, 1, 5, 30, 200, _("\ +你用了帽子砖块\n\ +了吗?说真的,\n\ +你应该用用哦!\n\ + \n\ +你要按下城堡隐\n\ +藏关卡的彩色的\n\ +帽子开关,才能\n\ +使它们都变成实\n\ +心的,这样你才\n\ +可以撞碎。\n\ +想去隐藏关卡\n\ +吗?重新获得一\n\ +些力量之星就行。\n\ + \n\ +帽子砖块非常有\n\ +用!红色的是飞\n\ +行帽;绿的是金\n\ +属帽;蓝的是隐\n\ +形帽。")) + +DEFINE_DIALOG(DIALOG_148, 1, 6, 30, 200, _("\ +雪人之山就在前\n\ +面了!当心啊!\n\ +不要企图用三级\n\ +跳越过冰块射手\n\ +哦。\n\ + \n\ +如果你掉进了冰\n\ +水池塘,你的能\n\ +量会迅速减少,\n\ +而且不会自动恢\n\ +复。\n\ +       -雪人")) + +DEFINE_DIALOG(DIALOG_149, 1, 3, 30, 200, _("\ +欢迎来到桃花公\n\ +主的秘密滑道!\n\ +这里有藏着一颗\n\ +连酷霸王都找不\n\ +到的星星哦!\n\ +在下滑过程中,\n\ +遥杆向前加速,\n\ +向后当然是减速\n\ +啦。如果你滑得\n\ +够快的话,你会\n\ +赢得星星哦!")) + +DEFINE_DIALOG(DIALOG_150, 1, 5, 30, 200, _("\ +哇啊啊啊!你淹\n\ +了我的房子啊!\n\ +为什么啊?看看\n\ +这里乱糟糟的!\n\ +我该怎么办啊?\n\ + \n\ +屋顶蹋了,地板\n\ +淹了…该怎么办\n\ +啊,该怎么办\n\ +啊?呜…呜… \n\ +我要疯了!!!\n\ +当我得到这星星\n\ +时,所有的事情\n\ +都开始变糟了…\n\ +这颗亮晶晶的星\n\ +星,让我感觉怪\n\ +怪的… ")) + +DEFINE_DIALOG(DIALOG_151, 1, 4, 30, 200, _("\ +我再也受不了\n\ +了!你踩在我湿\n\ +透的身上,现在\n\ +我真的要疯了!\n\ +哇啊… ")) + +DEFINE_DIALOG(DIALOG_152, 1, 3, 30, 200, _("\ +哇!叔叔!\n\ +叔叔!\n\ +好吧,我给!\n\ +拿着这颗星!\n\ +哦!\n\ +我感觉好多了,\n\ +不再需要它了。\n\ +如果在晚上,我\n\ +可以透过天花板\n\ +看见许多星星。\n\ +它们使我感到…\n\ +平静。任何时候\n\ +都欢迎你回来看\n\ +看我。")) + +DEFINE_DIALOG(DIALOG_153, 1, 4, 30, 200, _("\ +嗨!谁在那儿?\n\ +什么东西在我身\n\ +上爬啊!\n\ +难道是冰蚂蚁?\n\ +还是雪跳蚤?\n\ +不管这么多了,\n\ +无论是什么,把\n\ +我惹烦了!我想\n\ +我要把它吹走!")) + +DEFINE_DIALOG(DIALOG_154, 1, 5, 30, 200, _("\ +抓紧你的帽子!\n\ +如果丢了它,你\n\ +会很容易受伤\n\ +噢。万一不小心\n\ +丢失了帽子,一\n\ +定要马上回头去\n\ +寻找啊!\n\ +公主可还被困在\n\ +墙壁中的某处。\n\ +快,快去找啊,\n\ +马力欧!\n\ + \n\ +噢,你知道在墙\n\ +里和壁画中都隐\n\ +藏着秘密世界,\n\ +是吧?")) + +DEFINE_DIALOG(DIALOG_155, 1, 6, 30, 200, _("\ +谢谢力量之星的\n\ +能量,城堡里又\n\ +出现了生机。\n\ +快,马力欧,是\n\ +时候教训酷霸王\n\ +了!\n\ + \n\ +这里,让我告诉\n\ +你一些关于城堡\n\ +的事吧。在那个\n\ +有镜子的房间,\n\ +一定要仔细注意\n\ +没有被镜子反射\n\ +到的物品。还有\n\ +当你要去水城的\n\ +时候,你可以高\n\ +高跃起进入壁\n\ +画。")) + +DEFINE_DIALOG(DIALOG_156, 1, 5, 30, 200, _("\ +那个钟里的世界\n\ +太奇怪了,注意\n\ +那个大指针的位\n\ +置。")) + +DEFINE_DIALOG(DIALOG_157, 1, 5, 30, 200, _("\ +当心!千万不要\n\ +被流沙吞没了。\n\ + \n\ +如果你陷入沙\n\ +中,就不能起跳\n\ +了。流沙没过你\n\ +的头,你就会被\n\ +闷死。\n\ + \n\ +黑暗地区可是一\n\ +个无底的深渊!")) + +DEFINE_DIALOG(DIALOG_158, 1, 6, 30, 200, _("\ +1 如果你做连\n\ +续的跳跃,而且\n\ +按键时间合适的\n\ +话,你会越跳越\n\ +高。如果你正在\n\ +快跑时做连续跳\n\ +跃,而且按键时\n\ +间合适的话,你\n\ +就可以做一个三\n\ +级跳远了。\n\ + \n\ +2 先往墙壁上\n\ +跳,在碰到墙壁\n\ +时,再次起跳,\n\ +你就可以来一个\n\ +踢墙跳,用它可\n\ +以反弹到更高的\n\ +地方。")) + +DEFINE_DIALOG(DIALOG_159, 1, 6, 30, 200, _("\ +如果你先站立不\n\ +动,按[Z]键下\n\ +蹲,然后起跳,\n\ +就可来一个后空\n\ +翻。要来一个远\n\ +跳,先跑起来,\n\ +按下[Z]键,再起\n\ +跳。")) + +DEFINE_DIALOG(DIALOG_160, 1, 4, 30, 200, _("\ +要使用身体滑行\n\ +攻击,在快跑中\n\ +按下[B]键。要想\n\ +在滑行中站住,\n\ +按[A]或者[B]键。")) + +DEFINE_DIALOG(DIALOG_161, 1, 4, 30, 200, _("\ + \n\ +马力欧!!!\n\ +那真的是你吗?\n\ +从上一次冒险到\n\ +现在,我们都没\n\ +有见过面啊!他\n\ +们告诉我,如果\n\ +我等在这里就有\n\ +可能见到你,不\n\ +过,我真的准备\n\ +要放弃了!\n\ + \n\ +天啊?你真的击\n\ +败了酷霸王吗?\n\ +而且你夺回了所\n\ +有的力量之星,\n\ +救出了公主?\n\ + \n\ +我就知道你一定\n\ +能行的!\n\ + \n\ +现在我要告诉你\n\ +一个非常特别的\n\ +消息。\n\ + \n\ +十分感谢你玩\n\ +神游马力欧!虽\n\ +然游戏结束了,\n\ +但是欢乐还没有\n\ +结束。下面是我\n\ +们为你准备的大\n\ +礼物,希望你能\n\ +够喜欢!\n\ + \n\ + \n\ +神游马力欧小组")) + +DEFINE_DIALOG(DIALOG_162, 1, 4, 30, 200, _("\ +不,不,不!怎\n\ +么又是你!你有\n\ +没有看见,我现\n\ +在真的很忙?\n\ + \n\ +我真的没有时间\n\ +跟你争论什么关\n\ +于星星的事。\n\ + \n\ +这个,拿去吧,\n\ +我现在要马上走\n\ +了。让我走吧!")) + +DEFINE_DIALOG(DIALOG_163, 1, 5, 30, 200, _("\ + \n\ +不…!你这次真\n\ +的把我给打败\n\ +了,马力欧!我\n\ +真的不能容忍我\n\ +竟然输给你了。\n\ + \n\ +我的部队真是群\n\ +废物!他们已经\n\ +交出了所有的力\n\ +量之星!什么?\n\ +有120颗?\n\ + \n\ +真是不可思议,\n\ +啊!有一些我也\n\ +无法找到??!\n\ +!!!\n\ + \n\ +现在,我看到世\n\ +界终于重归和平\n\ +了…噢!我好恨\n\ +和平啊!我不想\n\ +看到这个,我要\n\ +离开这儿!\n\ + \n\ +你等着,我会回\n\ +来的。到那时,\n\ +要让你的摇杆冒\n\ +烟!\n\ + \n\ +哇哈哈哈哈!")) + +DEFINE_DIALOG(DIALOG_164, 1, 4, 30, 200, _("\ +马力欧!你怎么\n\ +了?我已经很久\n\ +没有上滑道了,\n\ +都快不成样子\n\ +了。\n\ + \n\ +我一直在期待和\n\ +一位滑雪老手来\n\ +进行一场精彩的\n\ +比赛。\n\ + \n\ +你想和我比吗?\n\ + \n\ +预备…\n\ + \n\ +  开始!  不")) + +DEFINE_DIALOG(DIALOG_165, 1, 5, 30, 200, _("\ +我对那些由于绕\n\ +着柱子跑而昏倒\n\ +的人决不承担任\n\ +何责任。")) + +DEFINE_DIALOG(DIALOG_166, 1, 4, 30, 200, _("\ +我外出训练去\n\ +了,会很快回来\n\ +的。\n\ + \n\ +你以后再来吧。\n\ + \n\ +——喏库喏库")) + +DEFINE_DIALOG(DIALOG_167, 1, 4, 30, 200, _("\ +公主的城堡就在\n\ +前面。\n\ + \n\ +按[A]键跳跃,按\n\ +[Z]键蹲下,按[B]\n\ +键出拳、读标记\n\ +或者抓起东西。\n\ +再按[B]键扔掉你\n\ +刚刚抓起的东\n\ +西。")) + +DEFINE_DIALOG(DIALOG_168, 1, 5, 30, 200, _("\ +嗨!撞掉它!这\n\ +已经是你第二次\n\ +抓住我了。现\n\ +在,你是在找它\n\ +吧,马力欧!")) + +DEFINE_DIALOG(DIALOG_169, 1, 4, 30, 200, _("\ +不准进来!\n\ +就是说你!\n\ +哇哈哈哈!\n\ + \n\ +任何私自进洞的\n\ +人,一定会遇到\n\ +灾难的。\n\ + \n\ +——船长")) diff --git a/text/de/dialogs.h b/text/de/dialogs.h index fba15c16..a6c9f0cc 100644 --- a/text/de/dialogs.h +++ b/text/de/dialogs.h @@ -330,11 +330,11 @@ unachtsam, wenn Du Dich\n\ leise, also langsam,\n\ bewegst.\n\ Die Kameraposition kannst\n\ -Du durch [C]> und [C]<\n\ +Du durch [C]▶ und [C]◀\n\ verändern, um einen\n\ Überblick zu erhalten.\n\ Das Weitwinkelobjektiv\n\ -wird mit [C]| eingesetzt.\n\ +wird mit [C]▼ eingesetzt.\n\ Details der Umgebung\n\ werden so sichtbar!\n\ Ein Warnton erklingt,\n\ @@ -417,7 +417,7 @@ zum Hauptfilm!")) DEFINE_DIALOG(DIALOG_035, 1, 5, 30, 200, _("\ Die [C]-Knöpfe dienen der\n\ Steuerung der Kamera.\n\ -Benutze den ^-Knopf, um\n\ +Benutze den ▲-Knopf, um\n\ die Kamera mit dem\n\ Analog-Stick zu bewegen.\n\ Normalerweise sorgt ein\n\ @@ -431,7 +431,7 @@ Drückst Du die [R]-Taste,\n\ wechselst Du zwischen\n\ Lakitus und Marios\n\ Sicht hin und her. Drücke\n\ -|, um den Zoom oder\n\ +▼, um den Zoom oder\n\ das Weitwinkelobjektiv zu\n\ aktivieren. Dies ist in\n\ allen Perspektiven möglich.\n\ @@ -443,7 +443,7 @@ dem Bildschirm befindet.")) DEFINE_DIALOG(DIALOG_036, 1, 5, 30, 200, _("\ AUSSICHTSPLATTFORM\n\ -Drücke ^ und genieße die\n\ +Drücke ▲ und genieße die\n\ Aussicht. Vielleicht\n\ entdeckst Du Geheimnisse\n\ Deiner Umgebung.\n\ diff --git a/text/debug_text.inc.c b/text/debug_text.inc.c new file mode 100644 index 00000000..25b922e3 --- /dev/null +++ b/text/debug_text.inc.c @@ -0,0 +1,36 @@ +// == debug table == + +#ifndef VERSION_EU + +// (this wasn't translated for US, and was removed in EU) + +static const u8 Debug0[] = { + _("STAGE SELECT\n" + " つづける?\n" + " 1 マウンテン\n" + " 2 ファイアーバブル\n" + " 3 スノースライダー\n" + " 4 ウォーターランド\n" + "   クッパ1ごう\n" + " もどる") +}; + +static const u8 Debug1[] = { + _("PAUSE    \n" + " つづける?\n" + " やめる ?") +}; + +static const struct DialogEntry debug_text_entry_0 = { + 1, 8, 30, 200, Debug0 +}; + +static const struct DialogEntry debug_text_entry_1 = { + 1, 3, 100, 150, Debug1 +}; + +const struct DialogEntry *const seg2_debug_text_table[] = { + &debug_text_entry_0, &debug_text_entry_1, NULL, +}; + +#endif diff --git a/text/define_text.inc.c b/text/define_text.inc.c index d33031f6..a7925f17 100644 --- a/text/define_text.inc.c +++ b/text/define_text.inc.c @@ -1,41 +1,3 @@ -// == debug table == - -#ifndef VERSION_EU - -// (this wasn't translated for US, and was removed in EU) - -static const u8 Debug0[] = { - _("STAGE SELECT\n" - " つづける?\n" - " 1 マウンテン\n" - " 2 ファイアーバブル\n" - " 3 スノースライダー\n" - " 4 ウォーターランド\n" - "   クッパ1ごう\n" - " もどる") -}; - -static const u8 Debug1[] = { - _("PAUSE    \n" - " つづける?\n" - " やめる ?") -}; - -static const struct DialogEntry debug_text_entry_0 = { - 1, 8, 30, 200, Debug0 -}; - -static const struct DialogEntry debug_text_entry_1 = { - 1, 3, 100, 150, Debug1 -}; - -const struct DialogEntry *const seg2_debug_text_table[] = { - &debug_text_entry_0, &debug_text_entry_1, NULL, -}; - -#endif - - // == dialog == // (defines en_dialog_table etc.) diff --git a/text/fr/dialogs.h b/text/fr/dialogs.h index 26e8c1fb..26588b4c 100644 --- a/text/fr/dialogs.h +++ b/text/fr/dialogs.h @@ -159,7 +159,7 @@ DEFINE_DIALOG(DIALOG_008, 1, 5, 30, 200, _("\ ATTENTION AU CHOMP\n\ ENCHAINE!!!\n\ Danger! Approchez-vous\n\ -et appuyez sur [C]^ pour\n\ +et appuyez sur [C]▲ pour\n\ jeter un oeil.\n\ Impressionnant, non?\n\ Avez-vous remarqué la\n\ @@ -373,8 +373,8 @@ pour ne pas faire de bruit\n\ et ainsi surprendre vos\n\ ennemis.\n\ Vous pouvez déplacer ma\n\ -caméra avec [C]> et [C]<.\n\ -Appuyez sur [C]| pour voir\n\ +caméra avec [C]▶ et [C]◀.\n\ +Appuyez sur [C]▼ pour voir\n\ de loin.\n\ Lorsque ma caméra ne\n\ peut plus se déplacer,\n\ @@ -439,7 +439,7 @@ la caméra, un signal\n\ sonore retentira.\n\ Pour jeter un oeil autour\n\ de Mario, arrêtez-vous\n\ -et appuyez sur [C]^.\n\ +et appuyez sur [C]▲.\n\ Appuyez sur le bouton [A]\n\ pour revenir au jeu.\n\ \n\ @@ -456,7 +456,7 @@ meilleures images...")) DEFINE_DIALOG(DIALOG_035, 1, 6, 30, 200, _("\ Il existe quatre boutons\n\ -[C]. En appuyant sur [C]^ et\n\ +[C]. En appuyant sur [C]▲ et\n\ en bougeant le stick\n\ multidirectionnel, vous\n\ pourrez jeter un oeil aux\n\ @@ -469,14 +469,14 @@ sur [R] et ainsi utiliser\n\ la 『caméra-Mario』.\n\ Appuyez sur [R] à nouveau\n\ pour utiliser la caméra de\n\ -Lakitu. Appuyez sur [C]|\n\ +Lakitu. Appuyez sur [C]▼\n\ pour voir Mario de loin,\n\ quelque soit le mode de\n\ vue que vous utilisez.")) DEFINE_DIALOG(DIALOG_036, 1, 4, 30, 200, _("\ --PANORAMA--\n\ -Appuyez sur [C]^ pour jeter\n\ +Appuyez sur [C]▲ pour jeter\n\ un coup d'oeil. Profitez\n\ de la vue!\n\ Appuyez sur [R] pour\n\ diff --git a/text/us/dialogs.h b/text/us/dialogs.h index 34a18b20..8ec520b8 100644 --- a/text/us/dialogs.h +++ b/text/us/dialogs.h @@ -140,7 +140,7 @@ it, fair and square!")) DEFINE_DIALOG(DIALOG_008, 1, 4, 30, 200, _("\ BEWARE OF CHAIN CHOMP\n\ Extreme Danger!\n\ -Get close and press [C]^\n\ +Get close and press [C]▲\n\ for a better look.\n\ Scary, huh?\n\ See the Red Coin on top\n\ @@ -352,8 +352,8 @@ order to walk quietly.\n\ And wrapping up filming\n\ techniques reported on\n\ earlier, you can take a\n\ -look around using [C]> and\n\ -[C]<. Press [C]| to view the\n\ +look around using [C]▶ and\n\ +[C]◀. Press [C]▼ to view the\n\ action from a distance.\n\ When you can't move the\n\ camera any farther, the\n\ @@ -424,7 +424,7 @@ If we can't adjust the\n\ view any further, we'll\n\ buzz. To take a look at\n\ the surroundings, stop\n\ -and press [C]^.\n\ +and press [C]▲.\n\ \n\ Press [A] to resume play.\n\ Switch camera modes with\n\ @@ -438,7 +438,7 @@ Lakitu Bros.")) DEFINE_DIALOG(DIALOG_035, 1, 5, 30, 200, _("\ There are four camera, or\n\ -『[C],』 Buttons. Press [C]^\n\ +『[C],』 Buttons. Press [C]▲\n\ to look around using the\n\ Control Stick.\n\ \n\ @@ -448,19 +448,19 @@ It is the camera\n\ recommended for normal\n\ play.\n\ You can change angles by\n\ -pressing [C]>. If you press\n\ +pressing [C]▶. If you press\n\ [R], the view switches to\n\ Mario's camera, which\n\ is directly behind him.\n\ Press [R] again to return\n\ to Lakitu's camera. Press\n\ -[C]| to see Mario from\n\ +[C]▼ to see Mario from\n\ afar, using either\n\ Lakitu's or Mario's view.")) DEFINE_DIALOG(DIALOG_036, 1, 5, 30, 200, _("\ OBSERVATION PLATFORM\n\ -Press [C]^ to take a look\n\ +Press [C]▲ to take a look\n\ around. Don't miss\n\ anything!\n\ \n\ diff --git a/tools/.gitignore b/tools/.gitignore index 7be0668f..1abd8943 100644 --- a/tools/.gitignore +++ b/tools/.gitignore @@ -2,10 +2,6 @@ /aiff_extract_codebook /armips /extract_data_for_mio -/mio0 -/n64cksum -/n64graphics -/n64graphics_ci /patch_elf_32bit /skyconv /tabledesign diff --git a/tools/Makefile b/tools/Makefile index 92a39168..f3f9496f 100644 --- a/tools/Makefile +++ b/tools/Makefile @@ -5,9 +5,9 @@ HOST_ENV := $(patsubst MINGW%,MinGW,$(HOST_ENV)) CC := gcc CXX := g++ -CFLAGS := -I . -Wall -Wextra -Wno-unused-parameter -pedantic -O2 -s +CFLAGS := -I . -I sm64tools -Wall -Wextra -Wno-unused-parameter -pedantic -O2 -s LDFLAGS := -lm -ALL_PROGRAMS := armips n64graphics n64graphics_ci mio0 n64cksum textconv patch_elf_32bit aifc_decode aiff_extract_codebook vadpcm_enc tabledesign extract_data_for_mio skyconv +ALL_PROGRAMS := armips textconv patch_elf_32bit aifc_decode aiff_extract_codebook vadpcm_enc tabledesign extract_data_for_mio skyconv LIBAUDIOFILE := audiofile/libaudiofile.a # Only build armips from tools if it is not found on the system @@ -19,17 +19,6 @@ endif default: all -n64graphics_SOURCES := n64graphics.c utils.c -n64graphics_CFLAGS := -DN64GRAPHICS_STANDALONE - -n64graphics_ci_SOURCES := n64graphics_ci_dir/n64graphics_ci.c n64graphics_ci_dir/exoquant/exoquant.c n64graphics_ci_dir/utils.c - -mio0_SOURCES := libmio0.c -mio0_CFLAGS := -DMIO0_STANDALONE - -n64cksum_SOURCES := n64cksum.c utils.c -n64cksum_CFLAGS := -DN64CKSUM_STANDALONE - textconv_SOURCES := textconv.c utf8.c hashtable.c patch_elf_32bit_SOURCES := patch_elf_32bit.c @@ -48,7 +37,7 @@ vadpcm_enc_CFLAGS := -Wno-unused-result -Wno-uninitialized -Wno-sign-compare -W extract_data_for_mio_SOURCES := extract_data_for_mio.c -skyconv_SOURCES := skyconv.c n64graphics.c utils.c +skyconv_SOURCES := skyconv.c sm64tools/n64graphics.c sm64tools/utils.c armips: CC := $(CXX) armips_SOURCES := armips.cpp @@ -60,24 +49,25 @@ endif all-except-recomp: $(LIBAUDIOFILE) $(BUILD_PROGRAMS) -all: all-except-recomp ido5.3_recomp +all: all-except-recomp ido-static-recomp clean: $(RM) $(ALL_PROGRAMS) $(MAKE) -C audiofile clean - $(MAKE) -C ido5.3_recomp clean + $(MAKE) -C ido-static-recomp clean define COMPILE $(1): $($1_SOURCES) $$(CC) $(CFLAGS) $($1_CFLAGS) $$^ -o $$@ $($1_LDFLAGS) $(LDFLAGS) endef -ido5.3_recomp: - $(MAKE) -C ido5.3_recomp +ido-static-recomp: + @$(MAKE) -C ido-static-recomp setup + @$(MAKE) -C ido-static-recomp $(foreach p,$(BUILD_PROGRAMS),$(eval $(call COMPILE,$(p)))) $(LIBAUDIOFILE): @$(MAKE) -C audiofile -.PHONY: all all-except-recomp clean default ido5.3_recomp +.PHONY: all all-except-recomp clean default ido-static-recomp diff --git a/tools/asm-processor/.gitignore b/tools/asm-processor/.gitignore new file mode 100644 index 00000000..cc5bba4b --- /dev/null +++ b/tools/asm-processor/.gitignore @@ -0,0 +1,2 @@ +*.o +*.py[cod] diff --git a/tools/asm-processor/LICENSE b/tools/asm-processor/LICENSE new file mode 100644 index 00000000..cf1ab25d --- /dev/null +++ b/tools/asm-processor/LICENSE @@ -0,0 +1,24 @@ +This is free and unencumbered software released into the public domain. + +Anyone is free to copy, modify, publish, use, compile, sell, or +distribute this software, either in source code form or as a compiled +binary, for any purpose, commercial or non-commercial, and by any +means. + +In jurisdictions that recognize copyright laws, the author or authors +of this software dedicate any and all copyright interest in the +software to the public domain. We make this dedication for the benefit +of the public at large and to the detriment of our heirs and +successors. We intend this dedication to be an overt act of +relinquishment in perpetuity of all present and future rights to this +software under copyright law. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, +EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. +IN NO EVENT SHALL THE AUTHORS BE LIABLE FOR ANY CLAIM, DAMAGES OR +OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, +ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR +OTHER DEALINGS IN THE SOFTWARE. + +For more information, please refer to diff --git a/tools/asm-processor/README.md b/tools/asm-processor/README.md new file mode 100644 index 00000000..009147c0 --- /dev/null +++ b/tools/asm-processor/README.md @@ -0,0 +1,112 @@ +# asm-processor + +Pre-process .c files and post-process .o files to enable embedding MIPS assembly into IDO-compiled C. + +## Usage + +Let's say you have a file compiled with `-g` on the IDO compiler, that looks like this: +```c +float func4(void) { + "func4"; + return 0.2f; +} +``` + +This script enables replacing it by: +```asm +GLOBAL_ASM( +.rdata +.word 0x66756e63 # func +.word 0x34000000 # 4\0\0\0 + +.late_rodata +glabel rv +.word 0x3e4ccccd # 0.2f + +.text +glabel func4 +lui $at, %hi(rv) +jr $ra +lwc1 $f0, %lo(rv)($at) +jr $ra +nop +jr $ra +nop +) +``` + +To compile the file, run `python3 build.py $CC -- $AS $ASFLAGS -- $CFLAGS -o out.o in.c`, where $CC points to an IDO binary (5.3/7.1 and recomp/qemu all supported), $AS is e.g. `mips-linux-gnu-as`, $ASFLAGS e.g. `-march=vr4300 -mabi=32` and $CFLAGS e.g. `-Wab,-r4300_mul -non_shared -G 0 -Xcpluscomm -g`. build.py may be customized as needed. + +In addition to an .o file, build.py also generates a .d file with Makefile dependencies for .s files referenced by the input .c file. +This functionality may be removed if not needed. + +Reading assembly from file is also supported, by either `GLOBAL_ASM("file.s")` or `#pragma GLOBAL_ASM("file.s")`. + +### What is supported? + +`.text`, `.data`, `.bss` and `.rodata` sections, `.word`/`.incbin`, `.ascii`/`.asciz`, and `-g`, `-g3`, `-O1`, `-O2`, `-framepointer` and `-mips1`/`-mips2` flags to the IDO compiler. + +### What is not supported? + +* complicated assembly (.ifdef, macro declarations/calls other than `glabel`, pseudo-instructions that expand to several real instructions) +* non-IDO compilers +* `-O3` (due to function reordering) + +C `#ifdef`s only work outside of `GLOBAL_ASM` calls, but is otherwise able to replace `.ifdef`. + +### What's up with "late rodata"? + +The IDO compiler emits rodata in two passes: first array/string contents, then large literals/switch jump tables. + +Data declared within `.rdata`/`.section .rodata` will end up in the first half, and `.late_rodata`/`.section .late_rodata` in the second half. + +### How does it work? + +It's a bit of a hack! +The basic idea is replace `GLOBAL_ASM` blocks with dummy C functions/global vars of the same sections sizes as the assembly. +Then the C file gets compiled, and the dummy contents overwritten with the injected assembly. + +To accomplish this, asm-processor has logic for guessing the size of assembly contents +(which assumes the assembly isn't too complicated, e.g. no macros), +and for emitting C code of exact sizes for a bunch of different IDO compiler flags. + +The assembler code is padded with nops to line it up with its correct position in the C; +this allows C and asm ELF files to be merged easily without having to fix up e.g. symbol addresses. + +The most difficult part is `late_rodata`, which is hard to create programmatically. +asm-processor does that by emitting code that uses dummy float literals/double literals/jump tables, +assembles the late_rodata at another location of the .rodata section, then overwrites the dummy rodata. +This does require some movement of symbols and relocations, and quite a bit of care in what code to +emit and how to preserve .double alignment. + +It's worth noting some alternative ways in which asm-processor would have been implemented: +- One idea to get rid of the C/asm size estimations is to emit arbitrary code, and then move code, +symbols and relocations to the correct place after the sizes are known. +Given the machinery for `late_rodata` this wouldn't have been too difficult, and it would have the upside of improved portability. +There is a big downside, however: using dummy code of incorrect size throws off alignment and can introduce unintended padding. +Fixing this would require running multiple passes of asm-processor, with one compile per `ASM_GLOBAL`. +- Another idea is to run the compiler with -S to emit assembly, modify the emitted assembly, then run the assembler +(which in IDO's case may perform additional instruction reordering etc.). +This option has not been investigated in much detail, and would perhaps be superior to the current implementation. +It does have a few unknowns to it, e.g. instruction encoding differences between GNU `as` and IDO's assembler, +how to avoid reordering the injected assembly, and how .rodata/.late_rodata are implemented. + +### Testing + +There are a few tests to ensure you don't break anything when hacking on asm-processor: `./run-tests.sh` should exit without output if they pass, or else output a diff from previous to new version. + +Tests need the environment variable `MIPS_CC` set to point to the IDO 7.1 compiler, with Pascal support enabled. + +For example if asm-processor is cloned in the same directory as [ido static recomp](https://github.com/decompals/ido-static-recomp) and the working directory is asm-processor, tests can be run using: + +```sh +MIPS_CC=../ido-static-recomp/build/7.1/out/cc ./run-tests.sh +``` + +Or using [qemu-irix](https://github.com/zeldaret/oot/releases/tag/0.1q) (don't forget `chmod u+x qemu-irix`) to emulate IDO: + +```sh +MIPS_CC='./qemu-irix -silent -L ../ido-static-recomp/ido/7.1/ ../ido-static-recomp/ido/7.1/usr/bin/cc' ./run-tests.sh +``` + +To skip running Pascal tests, remove the `tests/*.p` glob from `run-tests.sh`. diff --git a/tools/asm-processor/add-test.sh b/tools/asm-processor/add-test.sh new file mode 100644 index 00000000..708548e5 --- /dev/null +++ b/tools/asm-processor/add-test.sh @@ -0,0 +1,5 @@ +#!/usr/bin/env bash +for A in "$@"; do + OBJDUMPFLAGS="-srt" + ./compile-test.sh "$A" && mips-linux-gnu-objdump $OBJDUMPFLAGS "${A%.*}.o" > "${A%.*}.objdump" +done diff --git a/tools/asm_processor/asm-processor.py b/tools/asm-processor/asm_processor.py similarity index 63% rename from tools/asm_processor/asm-processor.py rename to tools/asm-processor/asm_processor.py index ea18c384..ff53a272 100644 --- a/tools/asm_processor/asm-processor.py +++ b/tools/asm-processor/asm_processor.py @@ -81,6 +81,21 @@ R_MIPS_26 = 4 R_MIPS_HI16 = 5 R_MIPS_LO16 = 6 +MIPS_DEBUG_ST_STATIC = 2 +MIPS_DEBUG_ST_STATIC_PROC = 14 + + +class ElfFormat: + def __init__(self, is_big_endian): + self.is_big_endian = is_big_endian + self.struct_char = ">" if is_big_endian else "<" + + def pack(self, fmt, *args): + return struct.pack(self.struct_char + fmt, *args) + + def unpack(self, fmt, data): + return struct.unpack(self.struct_char + fmt, data) + class ElfHeader: """ @@ -104,9 +119,9 @@ class ElfHeader: def __init__(self, data): self.e_ident = data[:EI_NIDENT] - self.e_type, self.e_machine, self.e_version, self.e_entry, self.e_phoff, self.e_shoff, self.e_flags, self.e_ehsize, self.e_phentsize, self.e_phnum, self.e_shentsize, self.e_shnum, self.e_shstrndx = struct.unpack('>HHIIIIIHHHHHH', data[EI_NIDENT:]) assert self.e_ident[EI_CLASS] == 1 # 32-bit - assert self.e_ident[EI_DATA] == 2 # big-endian + self.fmt = ElfFormat(is_big_endian=(self.e_ident[EI_DATA] == 2)) + self.e_type, self.e_machine, self.e_version, self.e_entry, self.e_phoff, self.e_shoff, self.e_flags, self.e_ehsize, self.e_phentsize, self.e_phnum, self.e_shentsize, self.e_shnum, self.e_shstrndx = self.fmt.unpack('HHIIIIIHHHHHH', data[EI_NIDENT:]) assert self.e_type == 1 # relocatable assert self.e_machine == 8 # MIPS I Architecture assert self.e_phoff == 0 # no program header @@ -114,7 +129,7 @@ class ElfHeader: assert self.e_shstrndx != SHN_UNDEF def to_bin(self): - return self.e_ident + struct.pack('>HHIIIIIHHHHHH', self.e_type, + return self.e_ident + self.fmt.pack('HHIIIIIHHHHHH', self.e_type, self.e_machine, self.e_version, self.e_entry, self.e_phoff, self.e_shoff, self.e_flags, self.e_ehsize, self.e_phentsize, self.e_phnum, self.e_shentsize, self.e_shnum, self.e_shstrndx) @@ -132,35 +147,42 @@ class Symbol: } Elf32_Sym; """ - def __init__(self, data, strtab): - self.st_name, self.st_value, self.st_size, st_info, self.st_other, self.st_shndx = struct.unpack('>IIIBBH', data) + def __init__(self, fmt, data, strtab, name=None): + self.fmt = fmt + self.st_name, self.st_value, self.st_size, st_info, self.st_other, self.st_shndx = fmt.unpack('IIIBBH', data) assert self.st_shndx != SHN_XINDEX, "too many sections (SHN_XINDEX not supported)" self.bind = st_info >> 4 self.type = st_info & 15 - self.name = strtab.lookup_str(self.st_name) + self.name = name if name is not None else strtab.lookup_str(self.st_name) self.visibility = self.st_other & 3 + @staticmethod + def from_parts(fmt, st_name, st_value, st_size, st_info, st_other, st_shndx, strtab, name): + header = fmt.pack('IIIBBH', st_name, st_value, st_size, st_info, st_other, st_shndx) + return Symbol(fmt, header, strtab, name) + def to_bin(self): st_info = (self.bind << 4) | self.type - return struct.pack('>IIIBBH', self.st_name, self.st_value, self.st_size, st_info, self.st_other, self.st_shndx) + return self.fmt.pack('IIIBBH', self.st_name, self.st_value, self.st_size, st_info, self.st_other, self.st_shndx) class Relocation: - def __init__(self, data, sh_type): + def __init__(self, fmt, data, sh_type): + self.fmt = fmt self.sh_type = sh_type if sh_type == SHT_REL: - self.r_offset, self.r_info = struct.unpack('>II', data) + self.r_offset, self.r_info = fmt.unpack('II', data) else: - self.r_offset, self.r_info, self.r_addend = struct.unpack('>III', data) + self.r_offset, self.r_info, self.r_addend = fmt.unpack('III', data) self.sym_index = self.r_info >> 8 self.rel_type = self.r_info & 0xff def to_bin(self): self.r_info = (self.sym_index << 8) | self.rel_type if self.sh_type == SHT_REL: - return struct.pack('>II', self.r_offset, self.r_info) + return self.fmt.pack('II', self.r_offset, self.r_info) else: - return struct.pack('>III', self.r_offset, self.r_info, self.r_addend) + return self.fmt.pack('III', self.r_offset, self.r_info, self.r_addend) class Section: @@ -179,8 +201,9 @@ class Section: } Elf32_Shdr; """ - def __init__(self, header, data, index): - self.sh_name, self.sh_type, self.sh_flags, self.sh_addr, self.sh_offset, self.sh_size, self.sh_link, self.sh_info, self.sh_addralign, self.sh_entsize = struct.unpack('>IIIIIIIIII', header) + def __init__(self, fmt, header, data, index): + self.fmt = fmt + self.sh_name, self.sh_type, self.sh_flags, self.sh_addr, self.sh_offset, self.sh_size, self.sh_link, self.sh_info, self.sh_addralign, self.sh_entsize = fmt.unpack('IIIIIIIIII', header) assert not self.sh_flags & SHF_LINK_ORDER if self.sh_entsize != 0: assert self.sh_size % self.sh_entsize == 0 @@ -192,9 +215,9 @@ class Section: self.relocated_by = [] @staticmethod - def from_parts(sh_name, sh_type, sh_flags, sh_link, sh_info, sh_addralign, sh_entsize, data, index): - header = struct.pack('>IIIIIIIIII', sh_name, sh_type, sh_flags, 0, 0, len(data), sh_link, sh_info, sh_addralign, sh_entsize) - return Section(header, data, index) + def from_parts(fmt, sh_name, sh_type, sh_flags, sh_link, sh_info, sh_addralign, sh_entsize, data, index): + header = fmt.pack('IIIIIIIIII', sh_name, sh_type, sh_flags, 0, 0, len(data), sh_link, sh_info, sh_addralign, sh_entsize) + return Section(fmt, header, data, index) def lookup_str(self, index): assert self.sh_type == SHT_STRTAB @@ -214,7 +237,7 @@ class Section: def header_to_bin(self): if self.sh_type != SHT_NOBITS: self.sh_size = len(self.data) - return struct.pack('>IIIIIIIIII', self.sh_name, self.sh_type, self.sh_flags, self.sh_addr, self.sh_offset, self.sh_size, self.sh_link, self.sh_info, self.sh_addralign, self.sh_entsize) + return self.fmt.pack('IIIIIIIIII', self.sh_name, self.sh_type, self.sh_flags, self.sh_addr, self.sh_offset, self.sh_size, self.sh_link, self.sh_info, self.sh_addralign, self.sh_entsize) def late_init(self, sections): if self.sh_type == SHT_SYMTAB: @@ -243,14 +266,14 @@ class Section: self.strtab = sections[self.sh_link] entries = [] for i in range(0, self.sh_size, self.sh_entsize): - entries.append(Symbol(self.data[i:i+self.sh_entsize], self.strtab)) + entries.append(Symbol(self.fmt, self.data[i:i+self.sh_entsize], self.strtab)) self.symbol_entries = entries def init_relocs(self): assert self.is_rel() entries = [] for i in range(0, self.sh_size, self.sh_entsize): - entries.append(Relocation(self.data[i:i+self.sh_entsize], self.sh_type)) + entries.append(Relocation(self.fmt, self.data[i:i+self.sh_entsize], self.sh_type)) self.relocations = entries def local_symbols(self): @@ -261,6 +284,43 @@ class Section: assert self.sh_type == SHT_SYMTAB return self.symbol_entries[self.sh_info:] + def relocate_mdebug(self, original_offset): + assert self.sh_type == SHT_MIPS_DEBUG + new_data = bytearray(self.data) + shift_by = self.sh_offset - original_offset + + # Update the file-relative offsets in the Symbolic HDRR + hdrr_magic, hdrr_vstamp, hdrr_ilineMax, hdrr_cbLine, \ + hdrr_cbLineOffset, hdrr_idnMax, hdrr_cbDnOffset, hdrr_ipdMax, \ + hdrr_cbPdOffset, hdrr_isymMax, hdrr_cbSymOffset, hdrr_ioptMax, \ + hdrr_cbOptOffset, hdrr_iauxMax, hdrr_cbAuxOffset, hdrr_issMax, \ + hdrr_cbSsOffset, hdrr_issExtMax, hdrr_cbSsExtOffset, hdrr_ifdMax, \ + hdrr_cbFdOffset, hdrr_crfd, hdrr_cbRfdOffset, hdrr_iextMax, \ + hdrr_cbExtOffset = self.fmt.unpack("HHIIIIIIIIIIIIIIIIIIIIIII", self.data[0:0x60]) + + assert hdrr_magic == 0x7009, "Invalid magic value for .mdebug symbolic header" + + hdrr_cbLineOffset += shift_by + hdrr_cbDnOffset += shift_by + hdrr_cbPdOffset += shift_by + hdrr_cbSymOffset += shift_by + hdrr_cbOptOffset += shift_by + hdrr_cbAuxOffset += shift_by + hdrr_cbSsOffset += shift_by + hdrr_cbSsExtOffset += shift_by + hdrr_cbFdOffset += shift_by + hdrr_cbRfdOffset += shift_by + hdrr_cbExtOffset += shift_by + + new_data[0:0x60] = self.fmt.pack("HHIIIIIIIIIIIIIIIIIIIIIII", hdrr_magic, hdrr_vstamp, hdrr_ilineMax, hdrr_cbLine, \ + hdrr_cbLineOffset, hdrr_idnMax, hdrr_cbDnOffset, hdrr_ipdMax, \ + hdrr_cbPdOffset, hdrr_isymMax, hdrr_cbSymOffset, hdrr_ioptMax, \ + hdrr_cbOptOffset, hdrr_iauxMax, hdrr_cbAuxOffset, hdrr_issMax, \ + hdrr_cbSsOffset, hdrr_issExtMax, hdrr_cbSsExtOffset, hdrr_ifdMax, \ + hdrr_cbFdOffset, hdrr_crfd, hdrr_cbRfdOffset, hdrr_iextMax, \ + hdrr_cbExtOffset) + + self.data = bytes(new_data) class ElfFile: def __init__(self, data): @@ -268,15 +328,16 @@ class ElfFile: assert data[:4] == b'\x7fELF', "not an ELF file" self.elf_header = ElfHeader(data[0:52]) + self.fmt = self.elf_header.fmt offset, size = self.elf_header.e_shoff, self.elf_header.e_shentsize - null_section = Section(data[offset:offset + size], data, 0) + null_section = Section(self.fmt, data[offset:offset + size], data, 0) num_sections = self.elf_header.e_shnum or null_section.sh_size self.sections = [null_section] for i in range(1, num_sections): ind = offset + i * size - self.sections.append(Section(data[ind:ind + size], data, i)) + self.sections.append(Section(self.fmt, data[ind:ind + size], data, i)) symtab = None for s in self.sections: @@ -300,7 +361,7 @@ class ElfFile: def add_section(self, name, sh_type, sh_flags, sh_link, sh_info, sh_addralign, sh_entsize, data): shstr = self.sections[self.elf_header.e_shstrndx] sh_name = shstr.add_str(name) - s = Section.from_parts(sh_name=sh_name, sh_type=sh_type, + s = Section.from_parts(self.fmt, sh_name=sh_name, sh_type=sh_type, sh_flags=sh_flags, sh_link=sh_link, sh_info=sh_info, sh_addralign=sh_addralign, sh_entsize=sh_entsize, data=data, index=len(self.sections)) @@ -309,7 +370,7 @@ class ElfFile: s.late_init(self.sections) return s - def drop_irrelevant_sections(self): + def drop_mdebug_gptab(self): # We can only drop sections at the end, since otherwise section # references might be wrong. Luckily, these sections typically are. while self.sections[-1].sh_type in [SHT_MIPS_DEBUG, SHT_MIPS_GPTAB]: @@ -332,7 +393,11 @@ class ElfFile: for s in self.sections: if s.sh_type != SHT_NOBITS and s.sh_type != SHT_NULL: pad_out(s.sh_addralign) + old_offset = s.sh_offset s.sh_offset = outidx + if s.sh_type == SHT_MIPS_DEBUG and s.sh_offset != old_offset: + # The .mdebug section has moved, relocate offsets + s.relocate_mdebug(old_offset) write_out(s.data) pad_out(4) @@ -372,14 +437,18 @@ class Failure(Exception): class GlobalState: - def __init__(self, min_instr_count, skip_instr_count, use_jtbl_for_rodata): + def __init__(self, min_instr_count, skip_instr_count, use_jtbl_for_rodata, prelude_if_late_rodata, mips1, pascal): # A value that hopefully never appears as a 32-bit rodata constant (or we # miscompile late rodata). Increases by 1 in each step. self.late_rodata_hex = 0xE0123456 + self.valuectr = 0 self.namectr = 0 self.min_instr_count = min_instr_count self.skip_instr_count = skip_instr_count self.use_jtbl_for_rodata = use_jtbl_for_rodata + self.prelude_if_late_rodata = prelude_if_late_rodata + self.mips1 = mips1 + self.pascal = pascal def next_late_rodata_hex(self): dummy_bytes = struct.pack('>I', self.late_rodata_hex) @@ -393,6 +462,36 @@ class GlobalState: self.namectr += 1 return '_asmpp_{}{}'.format(cat, self.namectr) + def func_prologue(self, name): + if self.pascal: + return " ".join([ + "procedure {}();".format(name), + "type", + " pi = ^integer;", + " pf = ^single;", + " pd = ^double;", + "var", + " vi: pi;", + " vf: pf;", + " vd: pd;", + "begin", + " vi := vi;", + " vf := vf;", + " vd := vd;", + ]) + else: + return 'void {}(void) {{'.format(name) + + def func_epilogue(self): + if self.pascal: + return "end;" + else: + return "}" + + def pascal_assignment(self, tp, val): + self.valuectr += 1 + address = (8 * self.valuectr) & 0x7FFF + return 'v{} := p{}({}); v{}^ := {};'.format(tp, tp, address, tp, val) Function = namedtuple('Function', ['text_glabels', 'asm_conts', 'late_rodata_dummy_bytes', 'jtbl_rodata_size', 'late_rodata_asm_conts', 'fn_desc', 'data']) @@ -426,6 +525,7 @@ class GlobalAsmBlock: def count_quoted_size(self, line, z, real_line, output_enc): line = line.encode(output_enc).decode('latin1') in_quote = False + has_comma = True num_parts = 0 ret = 0 i = 0 @@ -436,10 +536,15 @@ class GlobalAsmBlock: if not in_quote: if c == '"': in_quote = True + if z and not has_comma: + self.fail(".asciiz with glued strings is not supported due to GNU as version diffs") num_parts += 1 + elif c == ',': + has_comma = True else: if c == '"': in_quote = False + has_comma = False continue ret += 1 if c != '\\': @@ -504,7 +609,7 @@ class GlobalAsmBlock: self.text_glabels.append(line.split()[1]) if not line: pass # empty line - elif line.startswith('glabel ') or (' ' not in line and line.endswith(':')): + elif line.startswith('glabel ') or line.startswith('dlabel ') or line.startswith('endlabel ') or (' ' not in line and line.endswith(':')): pass # label elif line.startswith('.section') or line in ['.text', '.data', '.rdata', '.rodata', '.bss', '.late_rodata']: # section change @@ -524,7 +629,7 @@ class GlobalAsmBlock: changed_section = True elif line.startswith('.incbin'): self.add_sized(int(line.split(',')[-1].strip(), 0), real_line) - elif line.startswith('.word') or line.startswith('.float'): + elif line.startswith('.word') or line.startswith('.gpword') or line.startswith('.float'): self.align4() self.add_sized(4 * len(line.split(',')), real_line) elif line.startswith('.double'): @@ -600,12 +705,19 @@ class GlobalAsmBlock: size = self.fn_section_sizes['.late_rodata'] // 4 skip_next = False needs_double = (self.late_rodata_alignment != 0) + extra_mips1_nop = False + if state.pascal: + jtbl_size = 9 if state.mips1 else 8 + jtbl_min_rodata_size = 2 + else: + jtbl_size = 11 if state.mips1 else 9 + jtbl_min_rodata_size = 5 for i in range(size): if skip_next: skip_next = False continue - # Jump tables give 9 instructions for >= 5 words of rodata, and should be - # emitted when: + # Jump tables give 9 instructions (11 with -mips1) for >= 5 words of rodata, + # and should be emitted when: # - -O2 or -O2 -g3 are used, which give the right codegen # - we have emitted our first .float/.double (to ensure that we find the # created rodata in the binary) @@ -616,11 +728,18 @@ class GlobalAsmBlock: # - we have at least 10 more instructions to go in this function (otherwise our # function size computation will be wrong since the delay slot goes unused) if (not needs_double and state.use_jtbl_for_rodata and i >= 1 and - size - i >= 5 and num_instr - len(late_rodata_fn_output) >= 10): - cases = " ".join("case {}:".format(case) for case in range(size - i)) - late_rodata_fn_output.append("switch (*(volatile int*)0) { " + cases + " ; }") - late_rodata_fn_output.extend([""] * 8) + size - i >= jtbl_min_rodata_size and + num_instr - len(late_rodata_fn_output) >= jtbl_size + 1): + if state.pascal: + cases = " ".join("{}: ;".format(case) for case in range(size - i)) + line = "case 0 of " + cases + " otherwise end;" + else: + cases = " ".join("case {}:".format(case) for case in range(size - i)) + line = "switch (*(volatile int*)0) { " + cases + " ; }" + late_rodata_fn_output.append(line) + late_rodata_fn_output.extend([""] * (jtbl_size - 1)) jtbl_rodata_size = (size - i) * 4 + extra_mips1_nop = i != 2 break dummy_bytes = state.next_late_rodata_hex() late_rodata_dummy_bytes.append(dummy_bytes) @@ -628,20 +747,36 @@ class GlobalAsmBlock: dummy_bytes2 = state.next_late_rodata_hex() late_rodata_dummy_bytes.append(dummy_bytes2) fval, = struct.unpack('>d', dummy_bytes + dummy_bytes2) - late_rodata_fn_output.append('*(volatile double*)0 = {};'.format(fval)) + if state.pascal: + line = state.pascal_assignment('d', fval) + else: + line = '*(volatile double*)0 = {};'.format(fval) + late_rodata_fn_output.append(line) skip_next = True - needs_double = True + needs_double = False + if state.mips1: + # mips1 does not have ldc1/sdc1 + late_rodata_fn_output.append('') + late_rodata_fn_output.append('') + extra_mips1_nop = False else: fval, = struct.unpack('>f', dummy_bytes) - late_rodata_fn_output.append('*(volatile float*)0 = {}f;'.format(fval)) + if state.pascal: + line = state.pascal_assignment('f', fval) + else: + line = '*(volatile float*)0 = {}f;'.format(fval) + late_rodata_fn_output.append(line) + extra_mips1_nop = True late_rodata_fn_output.append('') late_rodata_fn_output.append('') + if state.mips1 and extra_mips1_nop: + late_rodata_fn_output.append('') text_name = None if self.fn_section_sizes['.text'] > 0 or late_rodata_fn_output: text_name = state.make_name('func') - src[0] = 'void {}(void) {{'.format(text_name) - src[self.num_lines] = '}' + src[0] = state.func_prologue(text_name) + src[self.num_lines] = state.func_epilogue() instr_count = self.fn_section_sizes['.text'] // 4 if instr_count < state.min_instr_count: self.fail("too short .text block") @@ -649,6 +784,7 @@ class GlobalAsmBlock: tot_skipped = 0 fn_emitted = 0 fn_skipped = 0 + skipping = True rodata_stack = late_rodata_fn_output[::-1] for (line, count) in self.fn_ins_inds: for _ in range(count): @@ -657,16 +793,28 @@ class GlobalAsmBlock: # Don't let functions become too large. When a function reaches 284 # instructions, and -O2 -framepointer flags are passed, the IRIX # compiler decides it is a great idea to start optimizing more. + # Also, Pascal cannot handle too large functions before it runs out + # of unique statements to write. fn_emitted = 0 fn_skipped = 0 - src[line] += ' }} void {}(void) {{ '.format(state.make_name('large_func')) - if fn_skipped < state.skip_instr_count: + skipping = True + src[line] += (' ' + state.func_epilogue() + ' ' + + state.func_prologue(state.make_name('large_func')) + ' ') + if ( + skipping and + fn_skipped < state.skip_instr_count + + (state.prelude_if_late_rodata if rodata_stack else 0) + ): fn_skipped += 1 tot_skipped += 1 - elif rodata_stack: - src[line] += rodata_stack.pop() else: - src[line] += '*(volatile int*)0 = 0;' + skipping = False + if rodata_stack: + src[line] += rodata_stack.pop() + elif state.pascal: + src[line] += state.pascal_assignment('i', '0') + else: + src[line] += '*(volatile int*)0 = 0;' tot_emitted += 1 fn_emitted += 1 if rodata_stack: @@ -680,16 +828,24 @@ class GlobalAsmBlock: rodata_name = None if self.fn_section_sizes['.rodata'] > 0: + if state.pascal: + self.fail(".rodata isn't supported with Pascal for now") rodata_name = state.make_name('rodata') src[self.num_lines] += ' const char {}[{}] = {{1}};'.format(rodata_name, self.fn_section_sizes['.rodata']) data_name = None if self.fn_section_sizes['.data'] > 0: data_name = state.make_name('data') - src[self.num_lines] += ' char {}[{}] = {{1}};'.format(data_name, self.fn_section_sizes['.data']) + if state.pascal: + line = ' var {}: packed array[1..{}] of char := [otherwise: 0];'.format(data_name, self.fn_section_sizes['.data']) + else: + line = ' char {}[{}] = {{1}};'.format(data_name, self.fn_section_sizes['.data']) + src[self.num_lines] += line bss_name = None if self.fn_section_sizes['.bss'] > 0: + if state.pascal: + self.fail(".bss isn't supported with Pascal") bss_name = state.make_name('bss') src[self.num_lines] += ' char {}[{}];'.format(bss_name, self.fn_section_sizes['.bss']) @@ -714,42 +870,64 @@ float_regexpr = re.compile(r"[-+]?[0-9]*\.?[0-9]+([eE][-+]?[0-9]+)?f") def repl_float_hex(m): return str(struct.unpack(">I", struct.pack(">f", float(m.group(0).strip().rstrip("f"))))[0]) -def parse_source(f, opt, framepointer, input_enc, output_enc, print_source=None): - if opt in ['O2', 'O1']: - if framepointer: +Opts = namedtuple('Opts', ['opt', 'framepointer', 'mips1', 'kpic', 'pascal', 'input_enc', 'output_enc']) + +def parse_source(f, opts, out_dependencies, print_source=None): + if opts.opt in ['O1', 'O2']: + if opts.framepointer: min_instr_count = 6 skip_instr_count = 5 else: min_instr_count = 2 skip_instr_count = 1 - elif opt == 'g': - if framepointer: + elif opts.opt == 'O0': + if opts.framepointer: + min_instr_count = 8 + skip_instr_count = 8 + else: + min_instr_count = 4 + skip_instr_count = 4 + elif opts.opt == 'g': + if opts.framepointer: min_instr_count = 7 skip_instr_count = 7 else: min_instr_count = 4 skip_instr_count = 4 - else: - if opt != 'g3': - raise Failure("must pass one of -g, -O1, -O2, -O2 -g3") - if framepointer: + elif opts.opt == 'g3': + if opts.framepointer: min_instr_count = 4 skip_instr_count = 4 else: min_instr_count = 2 skip_instr_count = 2 + else: + raise Failure("must pass one of -g, -O0, -O1, -O2, -O2 -g3") + prelude_if_late_rodata = 0 + if opts.kpic: + # Without optimizations, the PIC prelude always takes up 3 instructions. + # With optimizations, the prelude is optimized out if there's no late rodata. + if opts.opt in ('g3', 'O2'): + prelude_if_late_rodata = 3 + else: + min_instr_count += 3 + skip_instr_count += 3 use_jtbl_for_rodata = False - if opt in ['O2', 'g3'] and not framepointer: + if opts.opt in ['O2', 'g3'] and not opts.framepointer and not opts.kpic: use_jtbl_for_rodata = True - state = GlobalState(min_instr_count, skip_instr_count, use_jtbl_for_rodata) + state = GlobalState(min_instr_count, skip_instr_count, use_jtbl_for_rodata, prelude_if_late_rodata, opts.mips1, opts.pascal) + output_enc = opts.output_enc global_asm = None asm_functions = [] - output_lines = [] + output_lines = [ + '#line 1 "' + f.name + '"' + ] is_cutscene_data = False + is_early_include = False for line_no, raw_line in enumerate(f, 1): raw_line = raw_line.rstrip() @@ -769,61 +947,78 @@ def parse_source(f, opt, framepointer, input_enc, output_enc, print_source=None) global_asm = None else: global_asm.process_line(raw_line, output_enc) + elif line in ['GLOBAL_ASM(', '#pragma GLOBAL_ASM(']: + global_asm = GlobalAsmBlock("GLOBAL_ASM block at line " + str(line_no)) + start_index = len(output_lines) + elif ((line.startswith('GLOBAL_ASM("') or line.startswith('#pragma GLOBAL_ASM("')) + and line.endswith('")')): + fname = line[line.index('(') + 2 : -2] + out_dependencies.append(fname) + global_asm = GlobalAsmBlock(fname) + with open(fname, encoding=opts.input_enc) as f: + for line2 in f: + global_asm.process_line(line2.rstrip(), output_enc) + src, fn = global_asm.finish(state) + output_lines[-1] = ''.join(src) + asm_functions.append(fn) + global_asm = None + elif line == '#pragma asmproc recurse': + # C includes qualified as + # #pragma asmproc recurse + # #include "file.c" + # will be processed recursively when encountered + is_early_include = True + elif is_early_include: + # Previous line was a #pragma asmproc recurse + is_early_include = False + if not line.startswith("#include "): + raise Failure("#pragma asmproc recurse must be followed by an #include ") + fpath = os.path.dirname(f.name) + fname = os.path.join(fpath, line[line.index(' ') + 2 : -1]) + out_dependencies.append(fname) + include_src = StringIO() + with open(fname, encoding=opts.input_enc) as include_file: + parse_source(include_file, opts, out_dependencies, include_src) + include_src.write('#line ' + str(line_no + 1) + ' "' + f.name + '"') + output_lines[-1] = include_src.getvalue() + include_src.close() else: - if line in ['GLOBAL_ASM(', '#pragma GLOBAL_ASM(']: - global_asm = GlobalAsmBlock("GLOBAL_ASM block at line " + str(line_no)) - start_index = len(output_lines) - elif ((line.startswith('GLOBAL_ASM("') or line.startswith('#pragma GLOBAL_ASM("')) - and line.endswith('")')): - fname = line[line.index('(') + 2 : -2] - global_asm = GlobalAsmBlock(fname) - with open(fname, encoding=input_enc) as f: - for line2 in f: - global_asm.process_line(line2.rstrip(), output_enc) - src, fn = global_asm.finish(state) - output_lines[-1] = ''.join(src) - asm_functions.append(fn) - global_asm = None - elif line.startswith('#include "') and line.endswith('" EARLY'): - # C includes qualified with EARLY (i.e. #include "file.c" EARLY) will be - # processed recursively when encountered - fpath = os.path.dirname(f.name) - fname = line[line.index(' ') + 2 : -7] - include_src = StringIO() - with open(fpath + os.path.sep + fname, encoding=input_enc) as include_file: - parse_source(include_file, opt, framepointer, input_enc, output_enc, include_src) - output_lines[-1] = include_src.getvalue() - include_src.write('#line ' + str(line_no) + '\n') - include_src.close() - else: - # This is a hack to replace all floating-point numbers in an array of a particular type - # (in this case CutsceneData) with their corresponding IEEE-754 hexadecimal representation - if cutscene_data_regexpr.search(line) is not None: - is_cutscene_data = True - elif line.endswith("};"): - is_cutscene_data = False - if is_cutscene_data: - raw_line = re.sub(float_regexpr, repl_float_hex, raw_line) - output_lines[-1] = raw_line + # This is a hack to replace all floating-point numbers in an array of a particular type + # (in this case CutsceneData) with their corresponding IEEE-754 hexadecimal representation + if cutscene_data_regexpr.search(line) is not None: + is_cutscene_data = True + elif line.endswith("};"): + is_cutscene_data = False + if is_cutscene_data: + raw_line = re.sub(float_regexpr, repl_float_hex, raw_line) + output_lines[-1] = raw_line if print_source: if isinstance(print_source, StringIO): for line in output_lines: print_source.write(line + '\n') else: + newline_encoded = "\n".encode(output_enc) for line in output_lines: - print_source.write(line.encode(output_enc) + b'\n') + try: + line_encoded = line.encode(output_enc) + except UnicodeEncodeError: + print("Failed to encode a line to", output_enc) + print("The line:", line) + print("The line, utf-8-encoded:", line.encode("utf-8")) + raise + print_source.write(line_encoded) + print_source.write(newline_encoded) print_source.flush() - if print_source != sys.stdout.buffer: - print_source.close() return asm_functions -def fixup_objfile(objfile_name, functions, asm_prelude, assembler, output_enc): +def fixup_objfile(objfile_name, functions, asm_prelude, assembler, output_enc, drop_mdebug_gptab, convert_statics): SECTIONS = ['.data', '.text', '.rodata', '.bss'] with open(objfile_name, 'rb') as f: objfile = ElfFile(f.read()) + fmt = objfile.fmt prev_locs = { '.text': 0, @@ -848,6 +1043,7 @@ def fixup_objfile(objfile_name, functions, asm_prelude, assembler, output_enc): # simplicity we pad with nops/.space so that addresses match exactly, so we # don't have to fix up relocations/symbol references. all_text_glabels = set() + func_sizes = {} for function in functions: ifdefed = False for sectype, (temp_name, size) in function.data.items(): @@ -861,6 +1057,11 @@ def fixup_objfile(objfile_name, functions, asm_prelude, assembler, output_enc): loc = loc[1] prev_loc = prev_locs[sectype] if loc < prev_loc: + # If the dummy C generates too little asm, and we have two + # consecutive GLOBAL_ASM blocks, we detect that error here. + # On the other hand, if it generates too much, we don't have + # a good way of discovering that error: it's indistinguishable + # from a static symbol occurring after the GLOBAL_ASM block. raise Failure("Wrongly computed size for section {} (diff {}). This is an asm-processor bug!".format(sectype, prev_loc- loc)) if loc != prev_loc: asm.append('.section ' + sectype) @@ -870,6 +1071,8 @@ def fixup_objfile(objfile_name, functions, asm_prelude, assembler, output_enc): else: asm.append('.space {}'.format(loc - prev_loc)) to_copy[sectype].append((loc, size, temp_name, function.fn_desc)) + if function.text_glabels: + func_sizes[function.text_glabels[0]] = size prev_locs[sectype] = loc + size if not ifdefed: all_text_glabels.update(function.text_glabels) @@ -890,7 +1093,10 @@ def fixup_objfile(objfile_name, functions, asm_prelude, assembler, output_enc): if any(late_rodata_asm): late_rodata_source_name_start = '_asmpp_late_rodata_start' late_rodata_source_name_end = '_asmpp_late_rodata_end' - asm.append('.rdata') + asm.append('.section .late_rodata') + # Put some padding at the start to avoid conflating symbols with + # references to the whole section. + asm.append('.word 0, 0') asm.append('glabel {}'.format(late_rodata_source_name_start)) for conts in late_rodata_asm: asm.extend(conts) @@ -912,16 +1118,21 @@ def fixup_objfile(objfile_name, functions, asm_prelude, assembler, output_enc): with open(o_name, 'rb') as f: asm_objfile = ElfFile(f.read()) - # Remove some clutter from objdump output - objfile.drop_irrelevant_sections() + # Remove clutter from objdump output for tests, and make the tests + # portable by avoiding absolute paths. Outside of tests .mdebug is + # useful for showing source together with asm, though. + mdebug_section = objfile.find_section('.mdebug') + if drop_mdebug_gptab: + objfile.drop_mdebug_gptab() # Unify reginfo sections target_reginfo = objfile.find_section('.reginfo') - source_reginfo_data = list(asm_objfile.find_section('.reginfo').data) - data = list(target_reginfo.data) - for i in range(20): - data[i] |= source_reginfo_data[i] - target_reginfo.data = bytes(data) + if target_reginfo is not None: + source_reginfo_data = list(asm_objfile.find_section('.reginfo').data) + data = list(target_reginfo.data) + for i in range(20): + data[i] |= source_reginfo_data[i] + target_reginfo.data = bytes(data) # Move over section contents modified_text_positions = set() @@ -958,7 +1169,7 @@ def fixup_objfile(objfile_name, functions, asm_prelude, assembler, output_enc): # of another way of doing it. moved_late_rodata = {} if any(all_late_rodata_dummy_bytes) or any(all_jtbl_rodata_size): - source = asm_objfile.find_section('.rodata') + source = asm_objfile.find_section('.late_rodata') target = objfile.find_section('.rodata') source_pos = asm_objfile.symtab.find_symbol_in_section(late_rodata_source_name_start, source) source_end = asm_objfile.symtab.find_symbol_in_section(late_rodata_source_name_end, source) @@ -967,6 +1178,8 @@ def fixup_objfile(objfile_name, functions, asm_prelude, assembler, output_enc): new_data = list(target.data) for dummy_bytes_list, jtbl_rodata_size in zip(all_late_rodata_dummy_bytes, all_jtbl_rodata_size): for index, dummy_bytes in enumerate(dummy_bytes_list): + if not fmt.is_big_endian: + dummy_bytes = dummy_bytes[::-1] pos = target.data.index(dummy_bytes, last_rodata_pos) # This check is nice, but makes time complexity worse for large files: if SLOW_CHECKS and target.data.find(dummy_bytes, pos + 4) != -1: @@ -1002,7 +1215,7 @@ def fixup_objfile(objfile_name, functions, asm_prelude, assembler, output_enc): # Find relocated symbols relocated_symbols = set() - for sectype in SECTIONS: + for sectype in SECTIONS + ['.late_rodata']: for obj in [asm_objfile, objfile]: sec = obj.find_section(sectype) if sec is None: @@ -1012,42 +1225,133 @@ def fixup_objfile(objfile_name, functions, asm_prelude, assembler, output_enc): relocated_symbols.add(obj.symtab.symbol_entries[rel.sym_index]) # Move over symbols, deleting the temporary function labels. - # Sometimes this naive procedure results in duplicate symbols, or UNDEF - # symbols that are also defined the same .o file. Hopefully that's fine. - # Skip over local symbols that aren't used relocated against, to avoid - # conflicts. - new_local_syms = [s for s in objfile.symtab.local_symbols() if not is_temp_name(s.name)] - new_global_syms = [s for s in objfile.symtab.global_symbols() if not is_temp_name(s.name)] + # Skip over new local symbols that aren't relocated against, to + # avoid conflicts. + empty_symbol = objfile.symtab.symbol_entries[0] + new_syms = [s for s in objfile.symtab.symbol_entries[1:] if not is_temp_name(s.name)] + for i, s in enumerate(asm_objfile.symtab.symbol_entries): is_local = (i < asm_objfile.symtab.sh_info) if is_local and s not in relocated_symbols: continue if is_temp_name(s.name): + assert s not in relocated_symbols continue if s.st_shndx not in [SHN_UNDEF, SHN_ABS]: section_name = asm_objfile.sections[s.st_shndx].name - if section_name not in SECTIONS: - raise Failure("generated assembly .o must only have symbols for .text, .data, .rodata, ABS and UNDEF, but found " + section_name) - s.st_shndx = objfile.find_section(section_name).index + target_section_name = section_name + if section_name == ".late_rodata": + target_section_name = ".rodata" + elif section_name not in SECTIONS: + raise Failure("generated assembly .o must only have symbols for .text, .data, .rodata, .late_rodata, ABS and UNDEF, but found " + section_name) + objfile_section = objfile.find_section(target_section_name) + if objfile_section is None: + raise Failure("generated assembly .o has section that real objfile lacks: " + target_section_name) + s.st_shndx = objfile_section.index # glabel's aren't marked as functions, making objdump output confusing. Fix that. if s.name in all_text_glabels: s.type = STT_FUNC - if objfile.sections[s.st_shndx].name == '.rodata' and s.st_value in moved_late_rodata: + if s.name in func_sizes: + s.st_size = func_sizes[s.name] + if section_name == '.late_rodata': + if s.st_value == 0: + # This must be a symbol corresponding to the whole .late_rodata + # section, being referred to from a relocation. + # Moving local symbols is tricky, because it requires fixing up + # lo16/hi16 relocation references to .late_rodata+. + # Just disallow it for now. + raise Failure("local symbols in .late_rodata are not allowed") s.st_value = moved_late_rodata[s.st_value] s.st_name += strtab_adj - if is_local: - new_local_syms.append(s) + new_syms.append(s) + make_statics_global = convert_statics in ("global", "global-with-filename") + + # Add static symbols from .mdebug, so they can be referred to from GLOBAL_ASM + if mdebug_section and convert_statics != "no": + strtab_index = len(objfile.symtab.strtab.data) + new_strtab_data = [] + ifd_max, cb_fd_offset = fmt.unpack('II', mdebug_section.data[18*4 : 20*4]) + cb_sym_offset, = fmt.unpack('I', mdebug_section.data[9*4 : 10*4]) + cb_ss_offset, = fmt.unpack('I', mdebug_section.data[15*4 : 16*4]) + for i in range(ifd_max): + offset = cb_fd_offset + 18*4*i + iss_base, _, isym_base, csym = fmt.unpack('IIII', objfile.data[offset + 2*4 : offset + 6*4]) + for j in range(csym): + offset2 = cb_sym_offset + 12 * (isym_base + j) + iss, value, st_sc_index = fmt.unpack('III', objfile.data[offset2 : offset2 + 12]) + st = (st_sc_index >> 26) + sc = (st_sc_index >> 21) & 0x1f + if st in [MIPS_DEBUG_ST_STATIC, MIPS_DEBUG_ST_STATIC_PROC]: + symbol_name_offset = cb_ss_offset + iss_base + iss + symbol_name_offset_end = objfile.data.find(b'\0', symbol_name_offset) + assert symbol_name_offset_end != -1 + symbol_name = objfile.data[symbol_name_offset : symbol_name_offset_end + 1] + emitted_symbol_name = symbol_name + if convert_statics == "global-with-filename": + # Change the emitted symbol name to include the filename, + # but don't let that affect deduplication logic. + emitted_symbol_name = objfile_name.encode("utf-8") + b":" + symbol_name + section_name = {1: '.text', 2: '.data', 3: '.bss', 15: '.rodata'}[sc] + section = objfile.find_section(section_name) + symtype = STT_FUNC if sc == 1 else STT_OBJECT + binding = STB_GLOBAL if make_statics_global else STB_LOCAL + sym = Symbol.from_parts( + fmt, + st_name=strtab_index, + st_value=value, + st_size=0, + st_info=(binding << 4 | symtype), + st_other=STV_DEFAULT, + st_shndx=section.index, + strtab=objfile.symtab.strtab, + name=symbol_name[:-1].decode('latin1')) + strtab_index += len(emitted_symbol_name) + new_strtab_data.append(emitted_symbol_name) + new_syms.append(sym) + objfile.symtab.strtab.data += b''.join(new_strtab_data) + + # Get rid of duplicate symbols, favoring ones that are not UNDEF. + # Skip this for unnamed local symbols though. + new_syms.sort(key=lambda s: 0 if s.st_shndx != SHN_UNDEF else 1) + old_syms = [] + newer_syms = [] + name_to_sym = {} + for s in new_syms: + if s.name == "_gp_disp": + s.type = STT_OBJECT + if s.bind == STB_LOCAL and s.st_shndx == SHN_UNDEF: + raise Failure("local symbol \"" + s.name + "\" is undefined") + if not s.name: + if s.bind != STB_LOCAL: + raise Failure("global symbol with no name") + newer_syms.append(s) else: - new_global_syms.append(s) - new_syms = new_local_syms + new_global_syms + existing = name_to_sym.get(s.name) + if not existing: + name_to_sym[s.name] = s + newer_syms.append(s) + elif s.st_shndx != SHN_UNDEF: + raise Failure("symbol \"" + s.name + "\" defined twice") + else: + s.replace_by = existing + old_syms.append(s) + new_syms = newer_syms + + # Put local symbols in front, with the initial dummy entry first, and + # _gp_disp at the end if it exists. + new_syms.insert(0, empty_symbol) + new_syms.sort(key=lambda s: (s.bind != STB_LOCAL, s.name == "_gp_disp")) + num_local_syms = sum(1 for s in new_syms if s.bind == STB_LOCAL) + for i, s in enumerate(new_syms): s.new_index = i + for s in old_syms: + s.new_index = s.replace_by.new_index objfile.symtab.data = b''.join(s.to_bin() for s in new_syms) - objfile.symtab.sh_info = len(new_local_syms) + objfile.symtab.sh_info = num_local_syms - # Move over relocations + # Fix up relocation symbol references for sectype in SECTIONS: - source = asm_objfile.find_section(sectype) target = objfile.find_section(sectype) if target is not None: @@ -1059,34 +1363,38 @@ def fixup_objfile(objfile_name, functions, asm_prelude, assembler, output_enc): sectype == '.rodata' and rel.r_offset in jtbl_rodata_positions): # don't include relocations for late_rodata dummy code continue - # hopefully we don't have relocations for local or - # temporary symbols, so new_index exists rel.sym_index = objfile.symtab.symbol_entries[rel.sym_index].new_index nrels.append(rel) reltab.relocations = nrels reltab.data = b''.join(rel.to_bin() for rel in nrels) - if not source: + # Move over relocations + for sectype in SECTIONS + ['.late_rodata']: + source = asm_objfile.find_section(sectype) + if source is None or not source.data: continue - target_reltab = objfile.find_section('.rel' + sectype) - target_reltaba = objfile.find_section('.rela' + sectype) + target_sectype = '.rodata' if sectype == '.late_rodata' else sectype + target = objfile.find_section(target_sectype) + assert target is not None, target_sectype + target_reltab = objfile.find_section('.rel' + target_sectype) + target_reltaba = objfile.find_section('.rela' + target_sectype) for reltab in source.relocated_by: for rel in reltab.relocations: rel.sym_index = asm_objfile.symtab.symbol_entries[rel.sym_index].new_index - if sectype == '.rodata' and rel.r_offset in moved_late_rodata: + if sectype == '.late_rodata': rel.r_offset = moved_late_rodata[rel.r_offset] new_data = b''.join(rel.to_bin() for rel in reltab.relocations) if reltab.sh_type == SHT_REL: if not target_reltab: - target_reltab = objfile.add_section('.rel' + sectype, + target_reltab = objfile.add_section('.rel' + target_sectype, sh_type=SHT_REL, sh_flags=0, sh_link=objfile.symtab.index, sh_info=target.index, sh_addralign=4, sh_entsize=8, data=b'') target_reltab.data += new_data else: if not target_reltaba: - target_reltaba = objfile.add_section('.rela' + sectype, + target_reltaba = objfile.add_section('.rela' + target_sectype, sh_type=SHT_RELA, sh_flags=0, sh_link=objfile.symtab.index, sh_info=target.index, sh_addralign=4, sh_entsize=12, data=b'') @@ -1107,37 +1415,51 @@ def run_wrapped(argv, outfile, functions): parser.add_argument('--post-process', dest='objfile', help="path to .o file to post-process") parser.add_argument('--assembler', dest='assembler', help="assembler command (e.g. \"mips-linux-gnu-as -march=vr4300 -mabi=32\")") parser.add_argument('--asm-prelude', dest='asm_prelude', help="path to a file containing a prelude to the assembly file (with .set and .macro directives, e.g.)") - parser.add_argument('--input-enc', default='latin1', help="Input encoding (default: latin1)") - parser.add_argument('--output-enc', default='latin1', help="Output encoding (default: latin1)") + parser.add_argument('--input-enc', default='latin1', help="input encoding (default: %(default)s)") + parser.add_argument('--output-enc', default='latin1', help="output encoding (default: %(default)s)") + parser.add_argument('--drop-mdebug-gptab', dest='drop_mdebug_gptab', action='store_true', help="drop mdebug and gptab sections") + parser.add_argument('--convert-statics', dest='convert_statics', choices=["no", "local", "global", "global-with-filename"], default="local", help="change static symbol visibility (default: %(default)s)") + parser.add_argument('--force', dest='force', action='store_true', help="force processing of files without GLOBAL_ASM blocks") parser.add_argument('-framepointer', dest='framepointer', action='store_true') + parser.add_argument('-mips1', dest='mips1', action='store_true') parser.add_argument('-g3', dest='g3', action='store_true') + parser.add_argument('-KPIC', dest='kpic', action='store_true') group = parser.add_mutually_exclusive_group(required=True) + group.add_argument('-O0', dest='opt', action='store_const', const='O0') group.add_argument('-O1', dest='opt', action='store_const', const='O1') group.add_argument('-O2', dest='opt', action='store_const', const='O2') group.add_argument('-g', dest='opt', action='store_const', const='g') args = parser.parse_args(argv) opt = args.opt + pascal = any(args.filename.endswith(ext) for ext in (".p", ".pas", ".pp")) if args.g3: if opt != 'O2': raise Failure("-g3 is only supported together with -O2") opt = 'g3' + if args.mips1 and (opt not in ('O1', 'O2') or args.framepointer): + raise Failure("-mips1 is only supported together with -O1 or -O2") + if pascal and opt not in ('O1', 'O2', 'g3'): + raise Failure("Pascal is only supported together with -O1, -O2 or -O2 -g3") + opts = Opts(opt, args.framepointer, args.mips1, args.kpic, pascal, args.input_enc, args.output_enc) if args.objfile is None: with open(args.filename, encoding=args.input_enc) as f: - return parse_source(f, opt=opt, framepointer=args.framepointer, input_enc=args.input_enc, output_enc=args.output_enc, print_source=outfile) + deps = [] + functions = parse_source(f, opts, out_dependencies=deps, print_source=outfile) + return functions, deps else: if args.assembler is None: raise Failure("must pass assembler command") if functions is None: with open(args.filename, encoding=args.input_enc) as f: - functions = parse_source(f, opt=opt, framepointer=args.framepointer, input_enc=args.input_enc, output_enc=args.output_enc) - if not functions: + functions = parse_source(f, opts, out_dependencies=[]) + if not functions and not args.force: return asm_prelude = b'' if args.asm_prelude: with open(args.asm_prelude, 'rb') as f: asm_prelude = f.read() - fixup_objfile(args.objfile, functions, asm_prelude, args.assembler, args.output_enc) + fixup_objfile(args.objfile, functions, asm_prelude, args.assembler, args.output_enc, args.drop_mdebug_gptab, args.convert_statics) def run(argv, outfile=sys.stdout.buffer, functions=None): try: diff --git a/tools/asm-processor/build.py b/tools/asm-processor/build.py new file mode 100644 index 00000000..efbaade4 --- /dev/null +++ b/tools/asm-processor/build.py @@ -0,0 +1,114 @@ +#!/usr/bin/env python3 +import sys +from pathlib import Path +import shlex +import subprocess +import tempfile +import uuid +import asm_processor + +# Boolean for debugging purposes +# Preprocessed files are temporary, set to True to keep a copy +keep_preprocessed_files = False + +dir_path = Path(__file__).resolve().parent +asm_prelude_path = dir_path / "prelude.inc" + +all_args = sys.argv[1:] +sep0 = next(index for index, arg in enumerate(all_args) if not arg.startswith("-")) +sep1 = all_args.index("--") +sep2 = all_args.index("--", sep1 + 1) + +asmproc_flags = all_args[:sep0] +compiler = all_args[sep0:sep1] + +assembler_args = all_args[sep1 + 1 : sep2] +assembler_sh = " ".join(shlex.quote(x) for x in assembler_args) + + +compile_args = all_args[sep2 + 1 :] + +in_file = Path(compile_args[-1]) +del compile_args[-1] + +out_ind = compile_args.index("-o") +out_file = Path(compile_args[out_ind + 1]) +del compile_args[out_ind + 1] +del compile_args[out_ind] + + +in_dir = in_file.resolve().parent +opt_flags = [ + x for x in compile_args if x in {"-g3", "-g", "-O0", "-O1", "-O2", "-framepointer", "-KPIC"} +] +if "-mips2" not in compile_args: + opt_flags.append("-mips1") + +asmproc_flags += opt_flags + [str(in_file)] + +# Drop .mdebug and .gptab sections from resulting binaries. This makes +# resulting .o files much smaller and speeds up builds, but loses line +# number debug data. +# asmproc_flags += ["--drop-mdebug-gptab"] + +# Convert encoding before compiling. +# asmproc_flags += ["--input-enc", "utf-8", "--output-enc", "euc-jp"] + +with tempfile.TemporaryDirectory(prefix="asm_processor") as tmpdirname: + tmpdir_path = Path(tmpdirname) + preprocessed_filename = "preprocessed_" + uuid.uuid4().hex + in_file.suffix + preprocessed_path = tmpdir_path / preprocessed_filename + + with preprocessed_path.open("wb") as f: + functions, deps = asm_processor.run(asmproc_flags, outfile=f) + + if keep_preprocessed_files: + import shutil + + keep_output_dir = Path("./asm_processor_preprocessed") + keep_output_dir.mkdir(parents=True, exist_ok=True) + + shutil.copy( + preprocessed_path, + keep_output_dir / (in_file.stem + "_" + preprocessed_filename), + ) + + compile_cmdline = ( + compiler + + compile_args + + ["-I", str(in_dir), "-o", str(out_file), str(preprocessed_path)] + ) + + try: + subprocess.check_call(compile_cmdline) + except subprocess.CalledProcessError as e: + print("Failed to compile file " + str(in_file) + ". Command line:") + print() + print(" ".join(shlex.quote(x) for x in compile_cmdline)) + print() + sys.exit(55) + + asm_processor.run( + asmproc_flags + + [ + "--post-process", + str(out_file), + "--assembler", + assembler_sh, + "--asm-prelude", + str(asm_prelude_path), + ], + functions=functions, + ) + + deps_file = out_file.with_suffix(".asmproc.d") + if deps: + with deps_file.open("w") as f: + f.write(str(out_file) + ": " + " \\\n ".join(deps) + "\n") + for dep in deps: + f.write("\n" + dep + ":\n") + else: + try: + deps_file.unlink() + except OSError: + pass diff --git a/tools/asm-processor/compile-test.sh b/tools/asm-processor/compile-test.sh new file mode 100644 index 00000000..65516629 --- /dev/null +++ b/tools/asm-processor/compile-test.sh @@ -0,0 +1,26 @@ +#!/bin/bash +set -o pipefail +INPUT="$1" +OUTPUT="${INPUT%.*}.o" + +rm -f "$OUTPUT" + +CC="$MIPS_CC" # ido 7.1 via recomp or qemu-irix +AS="mips-linux-gnu-as" +ASFLAGS="-march=vr4300 -mabi=32" +OPTFLAGS=$(grep 'COMPILE-FLAGS: ' $INPUT | sed 's#^.*COMPILE-FLAGS: ##' | sed 's#}$##') +ASMPFLAGS=$(grep 'ASMP-FLAGS: ' $INPUT | sed 's#^.*ASMP-FLAGS: ##' | sed 's#}$##') +ISET=$(grep 'COMPILE-ISET: ' $INPUT | sed 's#^.*COMPILE-ISET: ##' | sed 's#}$##') +if [[ -z "$OPTFLAGS" ]]; then + OPTFLAGS="-g" +fi +CFLAGS="-Wab,-r4300_mul -G 0 -Xcpluscomm -fullwarn -wlint -woff 819,820,852,821 -signed -c" +if [[ -z "$ISET" ]]; then + CFLAGS="$CFLAGS -mips2" +fi +if [[ "$OPTFLAGS" != *-KPIC* ]]; then + CFLAGS="$CFLAGS -non_shared" +fi + +set -e +python3 build.py --drop-mdebug-gptab $ASMPFLAGS $CC -- $AS $ASFLAGS -- $CFLAGS $OPTFLAGS $ISET -o "$OUTPUT" "$INPUT" diff --git a/tools/asm-processor/prelude.inc b/tools/asm-processor/prelude.inc new file mode 100644 index 00000000..3e58ff14 --- /dev/null +++ b/tools/asm-processor/prelude.inc @@ -0,0 +1,43 @@ +.set noat +.set noreorder +.set gp=64 +.macro glabel label + .global \label + \label: +.endm + + +# Float register aliases (o32 ABI, odd ones are rarely used) + +.set $fv0, $f0 +.set $fv0f, $f1 +.set $fv1, $f2 +.set $fv1f, $f3 +.set $ft0, $f4 +.set $ft0f, $f5 +.set $ft1, $f6 +.set $ft1f, $f7 +.set $ft2, $f8 +.set $ft2f, $f9 +.set $ft3, $f10 +.set $ft3f, $f11 +.set $fa0, $f12 +.set $fa0f, $f13 +.set $fa1, $f14 +.set $fa1f, $f15 +.set $ft4, $f16 +.set $ft4f, $f17 +.set $ft5, $f18 +.set $ft5f, $f19 +.set $fs0, $f20 +.set $fs0f, $f21 +.set $fs1, $f22 +.set $fs1f, $f23 +.set $fs2, $f24 +.set $fs2f, $f25 +.set $fs3, $f26 +.set $fs3f, $f27 +.set $fs4, $f28 +.set $fs4f, $f29 +.set $fs5, $f30 +.set $fs5f, $f31 diff --git a/tools/asm-processor/run-tests.sh b/tools/asm-processor/run-tests.sh new file mode 100644 index 00000000..5cae0a74 --- /dev/null +++ b/tools/asm-processor/run-tests.sh @@ -0,0 +1,6 @@ +#!/usr/bin/env bash +for A in tests/*.c tests/*.p; do + OBJDUMPFLAGS=-srt + echo $A + ./compile-test.sh "$A" && mips-linux-gnu-objdump $OBJDUMPFLAGS "${A%.*}.o" | diff - "${A%.*}.objdump" || echo FAIL "$A" +done diff --git a/tools/asm-processor/tests/ascii.c b/tools/asm-processor/tests/ascii.c new file mode 100644 index 00000000..bb27d252 --- /dev/null +++ b/tools/asm-processor/tests/ascii.c @@ -0,0 +1,19 @@ +void foo(void) { "abcdef"; } + +GLOBAL_ASM( +.rdata + .ascii "AB" + .ascii "CD", "EF" + .ascii "GH\n\n\n\0\11\222\3333\44444\x1234567\n\nIJK" +) + +void bar(void) { "hello"; } + +GLOBAL_ASM( +.rdata + .asciiz "12" + .asciiz "34", "56" + .asciiz "78\n\n\n\0\11\222\3333\44444\x1234567\n\n9A" +) + +void baz(void) { "ghijkl"; } diff --git a/tools/asm-processor/tests/ascii.objdump b/tools/asm-processor/tests/ascii.objdump new file mode 100644 index 00000000..bf42638a --- /dev/null +++ b/tools/asm-processor/tests/ascii.objdump @@ -0,0 +1,29 @@ + +tests/ascii.o: file format elf32-tradbigmips + +SYMBOL TABLE: +00000000 l d .text 00000030 .text +00000000 l d .rodata 00000050 .rodata +00000000 g F .text 00000010 foo +00000010 g F .text 00000010 bar +00000020 g F .text 00000010 baz + + +Contents of section .text: + 0000 03e00008 00000000 03e00008 00000000 ................ + 0010 03e00008 00000000 03e00008 00000000 ................ + 0020 03e00008 00000000 03e00008 00000000 ................ +Contents of section .rodata: + 0000 61626364 65660000 41424344 45464748 abcdef..ABCDEFGH + 0010 0a0a0a00 0992db33 24343467 0a0a494a .......3$44g..IJ + 0020 4b000000 68656c6c 6f000000 31320033 K...hello...12.3 + 0030 34003536 0037380a 0a0a0009 92db3324 4.56.78.......3$ + 0040 3434670a 0a394100 6768696a 6b6c0000 44g..9A.ghijkl.. +Contents of section .options: + 0000 01200000 00000000 80000000 00000000 . .............. + 0010 00000000 00000000 00000000 00007ff0 ................ + 0020 07100000 00000000 00000000 00000000 ................ + 0030 08100000 00000000 00000000 00000000 ................ +Contents of section .reginfo: + 0000 80000000 00000000 00000000 00000000 ................ + 0010 00000000 00007ff0 ........ diff --git a/tools/asm-processor/tests/comments.c b/tools/asm-processor/tests/comments.c new file mode 100644 index 00000000..4c936699 --- /dev/null +++ b/tools/asm-processor/tests/comments.c @@ -0,0 +1,6 @@ +const char before[] = "^"; +GLOBAL_ASM( +.rdata +.asciz "aaaa /* bbbb */ # cccc", /**//**//**//**/ /*/ "xxxx" /*/ /* dddd " eeee */ "# ffff" # gggg "hhhh" /* iiii */ +) +const char after[] = "$"; diff --git a/tools/asm-processor/tests/comments.objdump b/tools/asm-processor/tests/comments.objdump new file mode 100644 index 00000000..246df209 --- /dev/null +++ b/tools/asm-processor/tests/comments.objdump @@ -0,0 +1,21 @@ + +tests/comments.o: file format elf32-tradbigmips + +SYMBOL TABLE: +00000000 l d .rodata 00000030 .rodata +00000000 g O .rodata 00000002 before +00000024 g O .rodata 00000002 after + + +Contents of section .rodata: + 0000 5e000000 61616161 202f2a20 62626262 ^...aaaa /* bbbb + 0010 202a2f20 23206363 63630023 20666666 */ # cccc.# fff + 0020 66000000 24000000 00000000 00000000 f...$........... +Contents of section .options: + 0000 01200000 00000000 00000000 00000000 . .............. + 0010 00000000 00000000 00000000 00007ff0 ................ + 0020 07100000 00000000 00000000 00000000 ................ + 0030 08100000 00000000 00000000 00000000 ................ +Contents of section .reginfo: + 0000 00000000 00000000 00000000 00000000 ................ + 0010 00000000 00007ff0 ........ diff --git a/tools/asm-processor/tests/force.c b/tools/asm-processor/tests/force.c new file mode 100644 index 00000000..03b630c1 --- /dev/null +++ b/tools/asm-processor/tests/force.c @@ -0,0 +1,17 @@ +// COMPILE-FLAGS: -O2 +// ASMP-FLAGS: --convert-statics=global-with-filename --force +static int xtext(int a, int b, int c); +const int rodata1[] = {1}; +static const int rodata2[] = {2}; +int data1[] = {3}; +static int data2[] = {4}; +int bss1; +static int bss2; + +static int xtext(int a, int b, int c) { + return 1; +} + +void baz(void) { + xtext(bss2, rodata2[0], data2[0]); +} diff --git a/tools/asm-processor/tests/force.objdump b/tools/asm-processor/tests/force.objdump new file mode 100644 index 00000000..7ef70247 --- /dev/null +++ b/tools/asm-processor/tests/force.objdump @@ -0,0 +1,47 @@ + +tests/force.o: file format elf32-tradbigmips + +SYMBOL TABLE: +00000000 l d .text 00000050 .text +00000000 l d .rodata 00000010 .rodata +00000000 l d .data 00000010 .data +00000000 l d .bss 00000010 .bss +00000000 g O .rodata 00000004 rodata1 +00000000 g O .data 00000004 data1 +00000000 g O .bss 00000004 bss1 +00000014 g F .text 00000034 baz +00000004 g O .rodata 00000000 tests/force.o:rodata2 +00000004 g O .data 00000000 tests/force.o:data2 +00000004 g O .bss 00000000 tests/force.o:bss2 +00000000 g F .text 00000000 tests/force.o:xtext + + +RELOCATION RECORDS FOR [.text]: +OFFSET TYPE VALUE +0000001c R_MIPS_HI16 .bss +00000034 R_MIPS_LO16 .bss +00000020 R_MIPS_HI16 .rodata +0000002c R_MIPS_LO16 .rodata +00000024 R_MIPS_HI16 .data +00000028 R_MIPS_LO16 .data +00000030 R_MIPS_26 .text + + +Contents of section .text: + 0000 afa40000 afa50004 afa60008 03e00008 ................ + 0010 24020001 27bdffe8 afbf0014 3c040000 $...'.......<... + 0020 3c050000 3c060000 8cc60004 8ca50004 <...<........... + 0030 0c000000 8c840004 8fbf0014 27bd0018 ............'... + 0040 03e00008 00000000 00000000 00000000 ................ +Contents of section .rodata: + 0000 00000001 00000002 00000000 00000000 ................ +Contents of section .data: + 0000 00000003 00000004 00000000 00000000 ................ +Contents of section .options: + 0000 01200000 00000000 a0000074 00000000 . .........t.... + 0010 00000000 00000000 00000000 00007ff0 ................ + 0020 07100000 00000000 00000000 00000000 ................ + 0030 08100000 00000000 00000000 00000000 ................ +Contents of section .reginfo: + 0000 a0000074 00000000 00000000 00000000 ...t............ + 0010 00000000 00007ff0 ........ diff --git a/tools/asm-processor/tests/kpic-o1.c b/tools/asm-processor/tests/kpic-o1.c new file mode 100644 index 00000000..4d3346d2 --- /dev/null +++ b/tools/asm-processor/tests/kpic-o1.c @@ -0,0 +1,93 @@ +// COMPILE-FLAGS: -O1 -KPIC +GLOBAL_ASM( +glabel foo +addiu $a0, $a0, 1 +addiu $a0, $a0, 2 +addiu $a0, $a0, 3 +addiu $a0, $a0, 4 +addiu $a0, $a0, 5 +addiu $a0, $a0, 6 +addiu $a0, $a0, 7 +addiu $a0, $a0, 8 +addiu $a0, $a0, 9 +addiu $a0, $a0, 10 +addiu $a0, $a0, 11 +addiu $a0, $a0, 12 +) +GLOBAL_ASM( +.late_rodata +.float 1 +.text +glabel float_fn +addiu $a0, $a0, 13 +addiu $a0, $a0, 14 +addiu $a0, $a0, 15 +addiu $a0, $a0, 16 +addiu $a0, $a0, 17 +addiu $a0, $a0, 18 +addiu $a0, $a0, 19 +addiu $a0, $a0, 20 +addiu $a0, $a0, 21 +addiu $a0, $a0, 22 +addiu $a0, $a0, 23 +addiu $a0, $a0, 24 +addiu $a0, $a0, 25 +addiu $a0, $a0, 26 +addiu $a0, $a0, 27 +addiu $a0, $a0, 28 +addiu $a0, $a0, 29 +addiu $a0, $a0, 30 +) +GLOBAL_ASM( +.late_rodata +.late_rodata_alignment 4 +.float 2 +.double 1 +.double 2 +.double 3 +.double 4 +.double 5 +.double 6 +.double 7 +.double 8 +.text +glabel doubles +addiu $a0, $a0, 31 +addiu $a0, $a0, 32 +addiu $a0, $a0, 33 +addiu $a0, $a0, 34 +addiu $a0, $a0, 35 +addiu $a0, $a0, 36 +addiu $a0, $a0, 37 +addiu $a0, $a0, 38 +addiu $a0, $a0, 39 +addiu $a0, $a0, 40 +addiu $a0, $a0, 41 +addiu $a0, $a0, 42 +addiu $a0, $a0, 43 +addiu $a0, $a0, 44 +addiu $a0, $a0, 45 +addiu $a0, $a0, 46 +addiu $a0, $a0, 47 +addiu $a0, $a0, 48 +addiu $a0, $a0, 49 +addiu $a0, $a0, 50 +addiu $a0, $a0, 51 +addiu $a0, $a0, 52 +addiu $a0, $a0, 53 +addiu $a0, $a0, 54 +addiu $a0, $a0, 55 +addiu $a0, $a0, 56 +addiu $a0, $a0, 57 +addiu $a0, $a0, 58 +addiu $a0, $a0, 59 +addiu $a0, $a0, 60 +addiu $a0, $a0, 61 +addiu $a0, $a0, 62 +addiu $a0, $a0, 63 +addiu $a0, $a0, 64 +addiu $a0, $a0, 65 +addiu $a0, $a0, 66 +addiu $a0, $a0, 67 +addiu $a0, $a0, 68 +) diff --git a/tools/asm-processor/tests/kpic-o1.objdump b/tools/asm-processor/tests/kpic-o1.objdump new file mode 100644 index 00000000..6e336753 --- /dev/null +++ b/tools/asm-processor/tests/kpic-o1.objdump @@ -0,0 +1,46 @@ + +tests/kpic-o1.o: file format elf32-tradbigmips + +SYMBOL TABLE: +00000000 l d .text 00000110 .text +00000000 l d .rodata 00000050 .rodata +00000000 g F .text 00000030 foo +00000030 g F .text 00000048 float_fn +00000078 g F .text 00000098 doubles +00000000 O *UND* 00000000 _gp_disp + + +RELOCATION RECORDS FOR [.text]: (none) + +Contents of section .text: + 0000 24840001 24840002 24840003 24840004 $...$...$...$... + 0010 24840005 24840006 24840007 24840008 $...$...$...$... + 0020 24840009 2484000a 2484000b 2484000c $...$...$...$... + 0030 2484000d 2484000e 2484000f 24840010 $...$...$...$... + 0040 24840011 24840012 24840013 24840014 $...$...$...$... + 0050 24840015 24840016 24840017 24840018 $...$...$...$... + 0060 24840019 2484001a 2484001b 2484001c $...$...$...$... + 0070 2484001d 2484001e 2484001f 24840020 $...$...$...$.. + 0080 24840021 24840022 24840023 24840024 $..!$.."$..#$..$ + 0090 24840025 24840026 24840027 24840028 $..%$..&$..'$..( + 00a0 24840029 2484002a 2484002b 2484002c $..)$..*$..+$.., + 00b0 2484002d 2484002e 2484002f 24840030 $..-$...$../$..0 + 00c0 24840031 24840032 24840033 24840034 $..1$..2$..3$..4 + 00d0 24840035 24840036 24840037 24840038 $..5$..6$..7$..8 + 00e0 24840039 2484003a 2484003b 2484003c $..9$..:$..;$..< + 00f0 2484003d 2484003e 2484003f 24840040 $..=$..>$..?$..@ + 0100 24840041 24840042 24840043 24840044 $..A$..B$..C$..D +Contents of section .rodata: + 0000 3f800000 40000000 3ff00000 00000000 ?...@...?....... + 0010 40000000 00000000 40080000 00000000 @.......@....... + 0020 40100000 00000000 40140000 00000000 @.......@....... + 0030 40180000 00000000 401c0000 00000000 @.......@....... + 0040 40200000 00000000 00000000 00000000 @ .............. +Contents of section .options: + 0000 01200000 00000000 92000002 00000000 . .............. + 0010 000f0ff0 00000000 00000000 00000000 ................ + 0020 07100000 00000000 00000000 00000000 ................ + 0030 08100000 00000000 00000000 00000000 ................ +Contents of section .reginfo: + 0000 92000012 00000000 000f0ff0 00000000 ................ + 0010 00000000 00000000 ........ diff --git a/tools/asm-processor/tests/kpic-o2.c b/tools/asm-processor/tests/kpic-o2.c new file mode 100644 index 00000000..f037341c --- /dev/null +++ b/tools/asm-processor/tests/kpic-o2.c @@ -0,0 +1,92 @@ +// COMPILE-FLAGS: -O2 -KPIC +GLOBAL_ASM( +glabel foo +addiu $a0, $a0, 1 +addiu $a0, $a0, 2 +addiu $a0, $a0, 3 +addiu $a0, $a0, 4 +addiu $a0, $a0, 5 +addiu $a0, $a0, 6 +addiu $a0, $a0, 7 +addiu $a0, $a0, 8 +addiu $a0, $a0, 9 +addiu $a0, $a0, 10 +addiu $a0, $a0, 11 +addiu $a0, $a0, 12 +) +GLOBAL_ASM( +.late_rodata +.float 1 +.text +glabel float_fn +addiu $a0, $a0, 13 +addiu $a0, $a0, 14 +addiu $a0, $a0, 15 +addiu $a0, $a0, 16 +addiu $a0, $a0, 17 +addiu $a0, $a0, 18 +addiu $a0, $a0, 19 +addiu $a0, $a0, 20 +addiu $a0, $a0, 21 +addiu $a0, $a0, 22 +addiu $a0, $a0, 23 +addiu $a0, $a0, 24 +addiu $a0, $a0, 25 +addiu $a0, $a0, 26 +addiu $a0, $a0, 27 +addiu $a0, $a0, 28 +addiu $a0, $a0, 29 +addiu $a0, $a0, 30 +) +GLOBAL_ASM( +.late_rodata +.float 2 +.double 1 +.double 2 +.double 3 +.double 4 +.double 5 +.double 6 +.double 7 +.double 8 +.text +glabel doubles +addiu $a0, $a0, 31 +addiu $a0, $a0, 32 +addiu $a0, $a0, 33 +addiu $a0, $a0, 34 +addiu $a0, $a0, 35 +addiu $a0, $a0, 36 +addiu $a0, $a0, 37 +addiu $a0, $a0, 38 +addiu $a0, $a0, 39 +addiu $a0, $a0, 40 +addiu $a0, $a0, 41 +addiu $a0, $a0, 42 +addiu $a0, $a0, 43 +addiu $a0, $a0, 44 +addiu $a0, $a0, 45 +addiu $a0, $a0, 46 +addiu $a0, $a0, 47 +addiu $a0, $a0, 48 +addiu $a0, $a0, 49 +addiu $a0, $a0, 50 +addiu $a0, $a0, 51 +addiu $a0, $a0, 52 +addiu $a0, $a0, 53 +addiu $a0, $a0, 54 +addiu $a0, $a0, 55 +addiu $a0, $a0, 56 +addiu $a0, $a0, 57 +addiu $a0, $a0, 58 +addiu $a0, $a0, 59 +addiu $a0, $a0, 60 +addiu $a0, $a0, 61 +addiu $a0, $a0, 62 +addiu $a0, $a0, 63 +addiu $a0, $a0, 64 +addiu $a0, $a0, 65 +addiu $a0, $a0, 66 +addiu $a0, $a0, 67 +addiu $a0, $a0, 68 +) diff --git a/tools/asm-processor/tests/kpic-o2.objdump b/tools/asm-processor/tests/kpic-o2.objdump new file mode 100644 index 00000000..abf87aeb --- /dev/null +++ b/tools/asm-processor/tests/kpic-o2.objdump @@ -0,0 +1,46 @@ + +tests/kpic-o2.o: file format elf32-tradbigmips + +SYMBOL TABLE: +00000000 l d .text 00000110 .text +00000000 l d .rodata 00000050 .rodata +00000000 g F .text 00000030 foo +00000030 g F .text 00000048 float_fn +00000078 g F .text 00000098 doubles +00000000 O *UND* 00000000 _gp_disp + + +RELOCATION RECORDS FOR [.text]: (none) + +Contents of section .text: + 0000 24840001 24840002 24840003 24840004 $...$...$...$... + 0010 24840005 24840006 24840007 24840008 $...$...$...$... + 0020 24840009 2484000a 2484000b 2484000c $...$...$...$... + 0030 2484000d 2484000e 2484000f 24840010 $...$...$...$... + 0040 24840011 24840012 24840013 24840014 $...$...$...$... + 0050 24840015 24840016 24840017 24840018 $...$...$...$... + 0060 24840019 2484001a 2484001b 2484001c $...$...$...$... + 0070 2484001d 2484001e 2484001f 24840020 $...$...$...$.. + 0080 24840021 24840022 24840023 24840024 $..!$.."$..#$..$ + 0090 24840025 24840026 24840027 24840028 $..%$..&$..'$..( + 00a0 24840029 2484002a 2484002b 2484002c $..)$..*$..+$.., + 00b0 2484002d 2484002e 2484002f 24840030 $..-$...$../$..0 + 00c0 24840031 24840032 24840033 24840034 $..1$..2$..3$..4 + 00d0 24840035 24840036 24840037 24840038 $..5$..6$..7$..8 + 00e0 24840039 2484003a 2484003b 2484003c $..9$..:$..;$..< + 00f0 2484003d 2484003e 2484003f 24840040 $..=$..>$..?$..@ + 0100 24840041 24840042 24840043 24840044 $..A$..B$..C$..D +Contents of section .rodata: + 0000 3f800000 40000000 3ff00000 00000000 ?...@...?....... + 0010 40000000 00000000 40080000 00000000 @.......@....... + 0020 40100000 00000000 40140000 00000000 @.......@....... + 0030 40180000 00000000 401c0000 00000000 @.......@....... + 0040 40200000 00000000 00000000 00000000 @ .............. +Contents of section .options: + 0000 01200000 00000000 92000002 00000000 . .............. + 0010 000f0ff0 00000000 00000000 00000000 ................ + 0020 07100000 00000000 00000000 00000000 ................ + 0030 08100000 00000000 00000000 00000000 ................ +Contents of section .reginfo: + 0000 92000012 00000000 000f0ff0 00000000 ................ + 0010 00000000 00000000 ........ diff --git a/tools/asm-processor/tests/label-sameline.c b/tools/asm-processor/tests/label-sameline.c new file mode 100644 index 00000000..a35b43d8 --- /dev/null +++ b/tools/asm-processor/tests/label-sameline.c @@ -0,0 +1,7 @@ +GLOBAL_ASM( +.rdata +.word 0x12345678 +glabel blah +.word blah2 + /*a*/ blah2: /*b*/ .word blah /*c*/ +) diff --git a/tools/asm-processor/tests/label-sameline.objdump b/tools/asm-processor/tests/label-sameline.objdump new file mode 100644 index 00000000..1f1aacff --- /dev/null +++ b/tools/asm-processor/tests/label-sameline.objdump @@ -0,0 +1,25 @@ + +tests/label-sameline.o: file format elf32-tradbigmips + +SYMBOL TABLE: +00000000 l d .rodata 00000010 .rodata +00000000 l d .rodata 00000000 +00000004 g .rodata 00000000 blah + + +RELOCATION RECORDS FOR [.rodata]: +OFFSET TYPE VALUE +00000004 R_MIPS_32 +00000008 R_MIPS_32 blah + + +Contents of section .rodata: + 0000 12345678 00000008 00000000 00000000 .4Vx............ +Contents of section .options: + 0000 01200000 00000000 00000000 00000000 . .............. + 0010 00000000 00000000 00000000 00007ff0 ................ + 0020 07100000 00000000 00000000 00000000 ................ + 0030 08100000 00000000 00000000 00000000 ................ +Contents of section .reginfo: + 0000 00000000 00000000 00000000 00000000 ................ + 0010 00000000 00007ff0 ........ diff --git a/tools/asm-processor/tests/large.c b/tools/asm-processor/tests/large.c new file mode 100644 index 00000000..4ffb4ac1 --- /dev/null +++ b/tools/asm-processor/tests/large.c @@ -0,0 +1,164 @@ + +GLOBAL_ASM( +glabel test + +addiu $sp, $sp, -24 + sw $zero, 4($sp) +lw $t6, 4($sp) +addu $t7, $a0, $t6 +sb $zero, ($t7) +lw $t8, 4($sp) +addiu $t9, $t8, 1 +slt $at, $t9, $a1 + sw $t9, 4($sp) + nop +jr $ra + addiu $sp, $sp, 24 +addiu $sp, $sp, -24 + sw $zero, 4($sp) +lw $t6, 4($sp) +addu $t7, $a0, $t6 +sb $zero, ($t7) +lw $t8, 4($sp) +addiu $t9, $t8, 1 +slt $at, $t9, $a1 + sw $t9, 4($sp) + nop +jr $ra + addiu $sp, $sp, 24 +addiu $sp, $sp, -24 + sw $zero, 4($sp) +lw $t6, 4($sp) +addu $t7, $a0, $t6 +sb $zero, ($t7) +lw $t8, 4($sp) +addiu $t9, $t8, 1 +slt $at, $t9, $a1 + sw $t9, 4($sp) + nop +jr $ra + addiu $sp, $sp, 24 +addiu $sp, $sp, -24 + sw $zero, 4($sp) +lw $t6, 4($sp) +addu $t7, $a0, $t6 +sb $zero, ($t7) +lw $t8, 4($sp) +addiu $t9, $t8, 1 +slt $at, $t9, $a1 + sw $t9, 4($sp) + nop +jr $ra + addiu $sp, $sp, 24 +addiu $sp, $sp, -24 + sw $zero, 4($sp) +lw $t6, 4($sp) +addu $t7, $a0, $t6 +sb $zero, ($t7) +lw $t8, 4($sp) +addiu $t9, $t8, 1 +slt $at, $t9, $a1 + sw $t9, 4($sp) + nop +jr $ra + addiu $sp, $sp, 24 +addiu $sp, $sp, -24 + sw $zero, 4($sp) +lw $t6, 4($sp) +addu $t7, $a0, $t6 +sb $zero, ($t7) +lw $t8, 4($sp) +addiu $t9, $t8, 1 +slt $at, $t9, $a1 + sw $t9, 4($sp) + nop +jr $ra + addiu $sp, $sp, 24 +addiu $sp, $sp, -24 + sw $zero, 4($sp) +lw $t6, 4($sp) +addu $t7, $a0, $t6 +sb $zero, ($t7) +lw $t8, 4($sp) +addiu $t9, $t8, 1 +slt $at, $t9, $a1 + sw $t9, 4($sp) + nop +jr $ra + addiu $sp, $sp, 24 +addiu $sp, $sp, -24 + sw $zero, 4($sp) +lw $t6, 4($sp) +addu $t7, $a0, $t6 +sb $zero, ($t7) +lw $t8, 4($sp) +addiu $t9, $t8, 1 +slt $at, $t9, $a1 + sw $t9, 4($sp) + nop +jr $ra + addiu $sp, $sp, 24 +addiu $sp, $sp, -24 + sw $zero, 4($sp) +lw $t6, 4($sp) +addu $t7, $a0, $t6 +sb $zero, ($t7) +lw $t8, 4($sp) +addiu $t9, $t8, 1 +slt $at, $t9, $a1 + sw $t9, 4($sp) + nop +jr $ra + addiu $sp, $sp, 24 +addiu $sp, $sp, -24 + sw $zero, 4($sp) +lw $t6, 4($sp) +addu $t7, $a0, $t6 +sb $zero, ($t7) +lw $t8, 4($sp) +addiu $t9, $t8, 1 +slt $at, $t9, $a1 + sw $t9, 4($sp) + nop +jr $ra + addiu $sp, $sp, 24 +addiu $sp, $sp, -24 + sw $zero, 4($sp) +lw $t6, 4($sp) +addu $t7, $a0, $t6 +sb $zero, ($t7) +lw $t8, 4($sp) +addiu $t9, $t8, 1 +slt $at, $t9, $a1 + sw $t9, 4($sp) + nop +jr $ra + addiu $sp, $sp, 24 +addiu $sp, $sp, -24 + sw $zero, 4($sp) +lw $t6, 4($sp) +addu $t7, $a0, $t6 +sb $zero, ($t7) +lw $t8, 4($sp) +addiu $t9, $t8, 1 +slt $at, $t9, $a1 + sw $t9, 4($sp) + nop +jr $ra + addiu $sp, $sp, 24 +addiu $sp, $sp, -24 + sw $zero, 4($sp) +lw $t6, 4($sp) +addu $t7, $a0, $t6 +sb $zero, ($t7) +lw $t8, 4($sp) +addiu $t9, $t8, 1 +slt $at, $t9, $a1 + sw $t9, 4($sp) + nop +jr $ra + addiu $sp, $sp, 24 + +) + +void foo(void) {} diff --git a/tools/asm-processor/tests/large.objdump b/tools/asm-processor/tests/large.objdump new file mode 100644 index 00000000..17409a7a --- /dev/null +++ b/tools/asm-processor/tests/large.objdump @@ -0,0 +1,58 @@ + +tests/large.o: file format elf32-tradbigmips + +SYMBOL TABLE: +00000000 l d .text 00000280 .text +00000270 g F .text 00000010 foo +00000000 g F .text 00000270 test + + +Contents of section .text: + 0000 27bdffe8 afa00004 8fae0004 008e7821 '.............x! + 0010 a1e00000 8fb80004 27190001 0325082a ........'....%.* + 0020 afb90004 00000000 03e00008 27bd0018 ............'... + 0030 27bdffe8 afa00004 8fae0004 008e7821 '.............x! + 0040 a1e00000 8fb80004 27190001 0325082a ........'....%.* + 0050 afb90004 00000000 03e00008 27bd0018 ............'... + 0060 27bdffe8 afa00004 8fae0004 008e7821 '.............x! + 0070 a1e00000 8fb80004 27190001 0325082a ........'....%.* + 0080 afb90004 00000000 03e00008 27bd0018 ............'... + 0090 27bdffe8 afa00004 8fae0004 008e7821 '.............x! + 00a0 a1e00000 8fb80004 27190001 0325082a ........'....%.* + 00b0 afb90004 00000000 03e00008 27bd0018 ............'... + 00c0 27bdffe8 afa00004 8fae0004 008e7821 '.............x! + 00d0 a1e00000 8fb80004 27190001 0325082a ........'....%.* + 00e0 afb90004 00000000 03e00008 27bd0018 ............'... + 00f0 27bdffe8 afa00004 8fae0004 008e7821 '.............x! + 0100 a1e00000 8fb80004 27190001 0325082a ........'....%.* + 0110 afb90004 00000000 03e00008 27bd0018 ............'... + 0120 27bdffe8 afa00004 8fae0004 008e7821 '.............x! + 0130 a1e00000 8fb80004 27190001 0325082a ........'....%.* + 0140 afb90004 00000000 03e00008 27bd0018 ............'... + 0150 27bdffe8 afa00004 8fae0004 008e7821 '.............x! + 0160 a1e00000 8fb80004 27190001 0325082a ........'....%.* + 0170 afb90004 00000000 03e00008 27bd0018 ............'... + 0180 27bdffe8 afa00004 8fae0004 008e7821 '.............x! + 0190 a1e00000 8fb80004 27190001 0325082a ........'....%.* + 01a0 afb90004 00000000 03e00008 27bd0018 ............'... + 01b0 27bdffe8 afa00004 8fae0004 008e7821 '.............x! + 01c0 a1e00000 8fb80004 27190001 0325082a ........'....%.* + 01d0 afb90004 00000000 03e00008 27bd0018 ............'... + 01e0 27bdffe8 afa00004 8fae0004 008e7821 '.............x! + 01f0 a1e00000 8fb80004 27190001 0325082a ........'....%.* + 0200 afb90004 00000000 03e00008 27bd0018 ............'... + 0210 27bdffe8 afa00004 8fae0004 008e7821 '.............x! + 0220 a1e00000 8fb80004 27190001 0325082a ........'....%.* + 0230 afb90004 00000000 03e00008 27bd0018 ............'... + 0240 27bdffe8 afa00004 8fae0004 008e7821 '.............x! + 0250 a1e00000 8fb80004 27190001 0325082a ........'....%.* + 0260 afb90004 00000000 03e00008 27bd0018 ............'... + 0270 03e00008 00000000 03e00008 00000000 ................ +Contents of section .options: + 0000 01200000 00000000 80000000 00000000 . .............. + 0010 00000000 00000000 00000000 00007ff0 ................ + 0020 07100000 00000000 00000000 00000000 ................ + 0030 08100000 00000000 00000000 00000000 ................ +Contents of section .reginfo: + 0000 a300c032 00000000 00000000 00000000 ...2............ + 0010 00000000 00007ff0 ........ diff --git a/tools/asm-processor/tests/late_rodata_align.c b/tools/asm-processor/tests/late_rodata_align.c new file mode 100644 index 00000000..7367c792 --- /dev/null +++ b/tools/asm-processor/tests/late_rodata_align.c @@ -0,0 +1,80 @@ +GLOBAL_ASM( +.late_rodata + .float 4.1 + .float 4.2 + .float 4.3 + .float 4.4 +.text +glabel a + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop +) + +float foo(void) { "foo"; return 1.1f; } + +GLOBAL_ASM( +.late_rodata +.late_rodata_alignment 4 + .float 5.1 + .float 5.2 + .float 5.3 + .float 5.4 +.text +glabel b + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop +) + +float bar(void) { "bar"; return 1.2f; } + +GLOBAL_ASM( +.late_rodata +.late_rodata_alignment 8 + .float 6.1 + .float 6.2 + .float 6.3 + .float 6.4 + .float 6.5 +.text +glabel c + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop +) + diff --git a/tools/asm-processor/tests/late_rodata_align.objdump b/tools/asm-processor/tests/late_rodata_align.objdump new file mode 100644 index 00000000..87c05e86 --- /dev/null +++ b/tools/asm-processor/tests/late_rodata_align.objdump @@ -0,0 +1,51 @@ + +tests/late_rodata_align.o: file format elf32-tradbigmips + +SYMBOL TABLE: +00000000 l d .text 000000f0 .text +00000000 l d .rodata 00000050 .rodata +00000040 g F .text 0000001c foo +00000090 g F .text 0000001c bar +00000000 g F .text 00000040 a +0000005c g F .text 00000034 b +000000ac g F .text 00000038 c + + +RELOCATION RECORDS FOR [.text]: +OFFSET TYPE VALUE +00000040 R_MIPS_HI16 .rodata +00000048 R_MIPS_LO16 .rodata +00000090 R_MIPS_HI16 .rodata +00000098 R_MIPS_LO16 .rodata + + +Contents of section .text: + 0000 00000000 00000000 00000000 00000000 ................ + 0010 00000000 00000000 00000000 00000000 ................ + 0020 00000000 00000000 00000000 00000000 ................ + 0030 00000000 00000000 00000000 00000000 ................ + 0040 3c010000 03e00008 c4200018 03e00008 <........ ...... + 0050 00000000 03e00008 00000000 00000000 ................ + 0060 00000000 00000000 00000000 00000000 ................ + 0070 00000000 00000000 00000000 00000000 ................ + 0080 00000000 00000000 00000000 00000000 ................ + 0090 3c010000 03e00008 c420002c 03e00008 <........ .,.... + 00a0 00000000 03e00008 00000000 00000000 ................ + 00b0 00000000 00000000 00000000 00000000 ................ + 00c0 00000000 00000000 00000000 00000000 ................ + 00d0 00000000 00000000 00000000 00000000 ................ + 00e0 00000000 00000000 00000000 00000000 ................ +Contents of section .rodata: + 0000 666f6f00 62617200 40833333 40866666 foo.bar.@.33@.ff + 0010 4089999a 408ccccd 3f8ccccd 40a33333 @...@...?...@.33 + 0020 40a66666 40a9999a 40accccd 3f99999a @.ff@...@...?... + 0030 40c33333 40c66666 40c9999a 40cccccd @.33@.ff@...@... + 0040 40d00000 00000000 00000000 00000000 @............... +Contents of section .options: + 0000 01200000 00000000 80000002 00000000 . .............. + 0010 000005f1 00000000 00000000 00007ff0 ................ + 0020 07100000 00000000 00000000 00000000 ................ + 0030 08100000 00000000 00000000 00000000 ................ +Contents of section .reginfo: + 0000 80000002 00000000 000005f1 00000000 ................ + 0010 00000000 00007ff0 ........ diff --git a/tools/asm-processor/tests/late_rodata_doubles.c b/tools/asm-processor/tests/late_rodata_doubles.c new file mode 100644 index 00000000..0a27b414 --- /dev/null +++ b/tools/asm-processor/tests/late_rodata_doubles.c @@ -0,0 +1,83 @@ +GLOBAL_ASM( +.late_rodata + .float 4.1 +.text +glabel a + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop +) + +float foo(void) { + return 4.15f; +} + +GLOBAL_ASM( +.late_rodata + .float 4.2 + .word 0 + .double 4.3 +.text +glabel b + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop +) + +float bar(void) { + return 4.4f; +} + +GLOBAL_ASM( +.late_rodata + .float 4.55 + .double 4.6 +.text +glabel c + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop +) + +float baz(void) { + return 4.6f; +} diff --git a/tools/asm-processor/tests/late_rodata_doubles.objdump b/tools/asm-processor/tests/late_rodata_doubles.objdump new file mode 100644 index 00000000..84d7e67f --- /dev/null +++ b/tools/asm-processor/tests/late_rodata_doubles.objdump @@ -0,0 +1,55 @@ + +tests/late_rodata_doubles.o: file format elf32-tradbigmips + +SYMBOL TABLE: +00000000 l d .text 00000120 .text +00000000 l d .rodata 00000030 .rodata +00000040 g F .text 0000001c foo +0000009c g F .text 0000001c bar +000000f8 g F .text 0000001c baz +00000000 g F .text 00000040 a +0000005c g F .text 00000040 b +000000b8 g F .text 00000040 c + + +RELOCATION RECORDS FOR [.text]: +OFFSET TYPE VALUE +00000040 R_MIPS_HI16 .rodata +00000048 R_MIPS_LO16 .rodata +0000009c R_MIPS_HI16 .rodata +000000a4 R_MIPS_LO16 .rodata +000000f8 R_MIPS_HI16 .rodata +00000100 R_MIPS_LO16 .rodata + + +Contents of section .text: + 0000 00000000 00000000 00000000 00000000 ................ + 0010 00000000 00000000 00000000 00000000 ................ + 0020 00000000 00000000 00000000 00000000 ................ + 0030 00000000 00000000 00000000 00000000 ................ + 0040 3c010000 03e00008 c4200004 03e00008 <........ ...... + 0050 00000000 03e00008 00000000 00000000 ................ + 0060 00000000 00000000 00000000 00000000 ................ + 0070 00000000 00000000 00000000 00000000 ................ + 0080 00000000 00000000 00000000 00000000 ................ + 0090 00000000 00000000 00000000 3c010000 ............<... + 00a0 03e00008 c4200018 03e00008 00000000 ..... .......... + 00b0 03e00008 00000000 00000000 00000000 ................ + 00c0 00000000 00000000 00000000 00000000 ................ + 00d0 00000000 00000000 00000000 00000000 ................ + 00e0 00000000 00000000 00000000 00000000 ................ + 00f0 00000000 00000000 3c010000 03e00008 ........<....... + 0100 c4200028 03e00008 00000000 03e00008 . .(............ + 0110 00000000 00000000 00000000 00000000 ................ +Contents of section .rodata: + 0000 40833333 4084cccd 40866666 00000000 @.33@...@.ff.... + 0010 40113333 33333333 408ccccd 4091999a @.333333@...@... + 0020 40126666 66666666 40933333 00000000 @.ffffff@.33.... +Contents of section .options: + 0000 01200000 00000000 80000002 00000000 . .............. + 0010 000000f1 00000000 00000000 00007ff0 ................ + 0020 07100000 00000000 00000000 00000000 ................ + 0030 08100000 00000000 00000000 00000000 ................ +Contents of section .reginfo: + 0000 80000002 00000000 000000f1 00000000 ................ + 0010 00000000 00007ff0 ........ diff --git a/tools/asm-processor/tests/late_rodata_doubles_mips1.c b/tools/asm-processor/tests/late_rodata_doubles_mips1.c new file mode 100644 index 00000000..b97261f6 --- /dev/null +++ b/tools/asm-processor/tests/late_rodata_doubles_mips1.c @@ -0,0 +1,86 @@ +// COMPILE-FLAGS: -O2 +// COMPILE-ISET: -mips1 +// exact copy of late_rodata_doubles.c except for the -mips1 -O2 additions +GLOBAL_ASM( +.late_rodata + .float 4.1 +.text +glabel a + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop +) + +float foo(void) { + return 4.15f; +} + +GLOBAL_ASM( +.late_rodata + .float 4.2 + .word 0 + .double 4.3 +.text +glabel b + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop +) + +float bar(void) { + return 4.4f; +} + +GLOBAL_ASM( +.late_rodata + .float 4.55 + .double 4.6 +.text +glabel c + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop +) + +float baz(void) { + return 4.6f; +} diff --git a/tools/asm-processor/tests/late_rodata_doubles_mips1.objdump b/tools/asm-processor/tests/late_rodata_doubles_mips1.objdump new file mode 100644 index 00000000..8fac85f4 --- /dev/null +++ b/tools/asm-processor/tests/late_rodata_doubles_mips1.objdump @@ -0,0 +1,52 @@ + +tests/late_rodata_doubles_mips1.o: file format elf32-tradbigmips + +SYMBOL TABLE: +00000000 l d .text 000000f0 .text +00000000 l d .rodata 00000030 .rodata +00000040 g F .text 00000010 foo +00000090 g F .text 00000010 bar +000000e0 g F .text 00000010 baz +00000000 g F .text 00000040 a +00000050 g F .text 00000040 b +000000a0 g F .text 00000040 c + + +RELOCATION RECORDS FOR [.text]: +OFFSET TYPE VALUE +00000040 R_MIPS_HI16 .rodata +00000044 R_MIPS_LO16 .rodata +00000090 R_MIPS_HI16 .rodata +00000094 R_MIPS_LO16 .rodata +000000e0 R_MIPS_HI16 .rodata +000000e4 R_MIPS_LO16 .rodata + + +Contents of section .text: + 0000 00000000 00000000 00000000 00000000 ................ + 0010 00000000 00000000 00000000 00000000 ................ + 0020 00000000 00000000 00000000 00000000 ................ + 0030 00000000 00000000 00000000 00000000 ................ + 0040 3c010000 c4200004 03e00008 00000000 <.... .......... + 0050 00000000 00000000 00000000 00000000 ................ + 0060 00000000 00000000 00000000 00000000 ................ + 0070 00000000 00000000 00000000 00000000 ................ + 0080 00000000 00000000 00000000 00000000 ................ + 0090 3c010000 c4200018 03e00008 00000000 <.... .......... + 00a0 00000000 00000000 00000000 00000000 ................ + 00b0 00000000 00000000 00000000 00000000 ................ + 00c0 00000000 00000000 00000000 00000000 ................ + 00d0 00000000 00000000 00000000 00000000 ................ + 00e0 3c010000 c4200028 03e00008 00000000 <.... .(........ +Contents of section .rodata: + 0000 40833333 4084cccd 40866666 00000000 @.33@...@.ff.... + 0010 40113333 33333333 408ccccd 4091999a @.333333@...@... + 0020 40126666 66666666 40933333 00000000 @.ffffff@.33.... +Contents of section .options: + 0000 01200000 00000000 80000002 00000000 . .............. + 0010 000c0011 00000000 00000000 00007ff0 ................ + 0020 07100000 00000000 00000000 00000000 ................ + 0030 08100000 00000000 00000000 00000000 ................ +Contents of section .reginfo: + 0000 80000002 00000000 000c0011 00000000 ................ + 0010 00000000 00007ff0 ........ diff --git a/tools/asm-processor/tests/late_rodata_jtbl.c b/tools/asm-processor/tests/late_rodata_jtbl.c new file mode 100644 index 00000000..3c2a5bba --- /dev/null +++ b/tools/asm-processor/tests/late_rodata_jtbl.c @@ -0,0 +1,153 @@ +// COMPILE-FLAGS: -O2 +GLOBAL_ASM( +.late_rodata +.double 1 +.double 2 +.double 3 +.double 4 +.double 5 +.double 6 +.double 7 +.double 8 +.text +glabel doubles1 +nop +nop +nop +nop +nop +nop +nop +nop +nop +nop +nop +nop +nop +nop +nop +nop +nop +nop +nop +nop +nop +nop +nop +) + +float a(void) { return 1.1f; } + +GLOBAL_ASM( +.late_rodata +.float 1 +.double 2 +.double 3 +.double 4 +.double 5 +.double 6 +.double 7 +.double 8 +.double 9 +.float 10 +.text +glabel doubles2 +nop +nop +nop +nop +nop +nop +nop +nop +nop +nop +nop +nop +nop +nop +nop +nop +nop +nop +nop +nop +nop +nop +nop +) + +GLOBAL_ASM( +glabel a2 +move $a0, $a0 +nop +nop +nop +jr $ra +move $a0, $a0 +) + +GLOBAL_ASM( +.late_rodata + +glabel jtbl +.word case0, case1, case2, case3, case4, case5, case6, case7, case8, case9, case10 +.word case11, case12, case13, case14, case15, case16, case17, case18, case19, case20 +.word case21, case22, case23, case24, case25, case26 + +.text +glabel foo +sltiu $at, $a0, 0xa +beqz $at, .L756E659B + sll $t7, $a0, 2 +lui $at, %hi(jtbl) +addu $at, $at, $t7 +lw $t7, %lo(jtbl)($at) +jr $t7 + nop +case0: addiu $a0, $a0, 1 +case1: addiu $a0, $a0, 1 +case2: addiu $a0, $a0, 1 +case3: addiu $a0, $a0, 1 +case4: addiu $a0, $a0, 1 +case5: addiu $a0, $a0, 1 +case6: addiu $a0, $a0, 1 +case7: addiu $a0, $a0, 1 +case8: addiu $a0, $a0, 1 +case9: addiu $a0, $a0, 1 +case10: addiu $a0, $a0, 1 +case11: addiu $a0, $a0, 1 +case12: addiu $a0, $a0, 1 +case13: addiu $a0, $a0, 1 +case14: addiu $a0, $a0, 1 +case15: addiu $a0, $a0, 1 +case16: addiu $a0, $a0, 1 +case17: addiu $a0, $a0, 1 +case18: addiu $a0, $a0, 1 +case19: addiu $a0, $a0, 1 +case20: addiu $a0, $a0, 1 +case21: addiu $a0, $a0, 1 +case22: addiu $a0, $a0, 1 +case23: addiu $a0, $a0, 1 +case24: addiu $a0, $a0, 1 +case25: addiu $a0, $a0, 1 +case26: +jr $ra + addiu $v0, $a0, 1 + +.L756E659B: +addiu $v0, $zero, 2 +jr $ra + nop +) + +GLOBAL_ASM( +glabel b2 +move $a0, $a0 +nop +nop +jr $ra +move $a0, $a0 +) + +float b(void) { return 1.2f; } diff --git a/tools/asm-processor/tests/late_rodata_jtbl.objdump b/tools/asm-processor/tests/late_rodata_jtbl.objdump new file mode 100644 index 00000000..44bb6e84 --- /dev/null +++ b/tools/asm-processor/tests/late_rodata_jtbl.objdump @@ -0,0 +1,110 @@ + +tests/late_rodata_jtbl.o: file format elf32-tradbigmips + +SYMBOL TABLE: +00000000 l d .text 000001a0 .text +00000000 l d .rodata 00000100 .rodata +00000000 l d .text 00000000 +0000005c g F .text 0000000c a +0000018c g F .text 0000000c b +00000000 g F .text 0000005c doubles1 +00000068 g F .text 0000005c doubles2 +000000c4 g F .text 00000018 a2 +000000dc g F .text 0000009c foo +0000008c g .rodata 00000000 jtbl +00000178 g F .text 00000014 b2 + + +RELOCATION RECORDS FOR [.text]: +OFFSET TYPE VALUE +0000005c R_MIPS_HI16 .rodata +00000064 R_MIPS_LO16 .rodata +0000018c R_MIPS_HI16 .rodata +00000194 R_MIPS_LO16 .rodata +000000e8 R_MIPS_HI16 jtbl +000000f0 R_MIPS_LO16 jtbl + + +RELOCATION RECORDS FOR [.rodata]: +OFFSET TYPE VALUE +0000008c R_MIPS_32 +00000090 R_MIPS_32 +00000094 R_MIPS_32 +00000098 R_MIPS_32 +0000009c R_MIPS_32 +000000a0 R_MIPS_32 +000000a4 R_MIPS_32 +000000a8 R_MIPS_32 +000000ac R_MIPS_32 +000000b0 R_MIPS_32 +000000b4 R_MIPS_32 +000000b8 R_MIPS_32 +000000bc R_MIPS_32 +000000c0 R_MIPS_32 +000000c4 R_MIPS_32 +000000c8 R_MIPS_32 +000000cc R_MIPS_32 +000000d0 R_MIPS_32 +000000d4 R_MIPS_32 +000000d8 R_MIPS_32 +000000dc R_MIPS_32 +000000e0 R_MIPS_32 +000000e4 R_MIPS_32 +000000e8 R_MIPS_32 +000000ec R_MIPS_32 +000000f0 R_MIPS_32 +000000f4 R_MIPS_32 + + +Contents of section .text: + 0000 00000000 00000000 00000000 00000000 ................ + 0010 00000000 00000000 00000000 00000000 ................ + 0020 00000000 00000000 00000000 00000000 ................ + 0030 00000000 00000000 00000000 00000000 ................ + 0040 00000000 00000000 00000000 00000000 ................ + 0050 00000000 00000000 00000000 3c010000 ............<... + 0060 03e00008 c4200040 00000000 00000000 ..... .@........ + 0070 00000000 00000000 00000000 00000000 ................ + 0080 00000000 00000000 00000000 00000000 ................ + 0090 00000000 00000000 00000000 00000000 ................ + 00a0 00000000 00000000 00000000 00000000 ................ + 00b0 00000000 00000000 00000000 00000000 ................ + 00c0 00000000 00802025 00000000 00000000 ...... %........ + 00d0 00000000 03e00008 00802025 2c81000a .......... %,... + 00e0 10200022 00047880 3c010000 002f0821 . ."..x.<..../.! + 00f0 8c2f0000 01e00008 00000000 24840001 ./..........$... + 0100 24840001 24840001 24840001 24840001 $...$...$...$... + 0110 24840001 24840001 24840001 24840001 $...$...$...$... + 0120 24840001 24840001 24840001 24840001 $...$...$...$... + 0130 24840001 24840001 24840001 24840001 $...$...$...$... + 0140 24840001 24840001 24840001 24840001 $...$...$...$... + 0150 24840001 24840001 24840001 24840001 $...$...$...$... + 0160 24840001 03e00008 24820001 24020002 $.......$...$... + 0170 03e00008 00000000 00802025 00000000 .......... %.... + 0180 00000000 03e00008 00802025 3c010000 .......... %<... + 0190 03e00008 c42000f8 00000000 00000000 ..... .......... +Contents of section .rodata: + 0000 3ff00000 00000000 40000000 00000000 ?.......@....... + 0010 40080000 00000000 40100000 00000000 @.......@....... + 0020 40140000 00000000 40180000 00000000 @.......@....... + 0030 401c0000 00000000 40200000 00000000 @.......@ ...... + 0040 3f8ccccd 3f800000 40000000 00000000 ?...?...@....... + 0050 40080000 00000000 40100000 00000000 @.......@....... + 0060 40140000 00000000 40180000 00000000 @.......@....... + 0070 401c0000 00000000 40200000 00000000 @.......@ ...... + 0080 40220000 00000000 41200000 000000fc @"......A ...... + 0090 00000100 00000104 00000108 0000010c ................ + 00a0 00000110 00000114 00000118 0000011c ................ + 00b0 00000120 00000124 00000128 0000012c ... ...$...(..., + 00c0 00000130 00000134 00000138 0000013c ...0...4...8...< + 00d0 00000140 00000144 00000148 0000014c ...@...D...H...L + 00e0 00000150 00000154 00000158 0000015c ...P...T...X...\ + 00f0 00000160 00000164 3f99999a 00000000 ...`...d?....... +Contents of section .options: + 0000 01200000 00000000 80004002 00000000 . ........@..... + 0010 000000f1 00000000 00000000 00007ff0 ................ + 0020 07100000 00000000 00000000 00000000 ................ + 0030 08100000 00000000 00000000 00000000 ................ +Contents of section .reginfo: + 0000 8000c016 00000000 000000f1 00000000 ................ + 0010 00000000 00007ff0 ........ diff --git a/tools/asm-processor/tests/late_rodata_jtbl_mips1.c b/tools/asm-processor/tests/late_rodata_jtbl_mips1.c new file mode 100644 index 00000000..505f4c1d --- /dev/null +++ b/tools/asm-processor/tests/late_rodata_jtbl_mips1.c @@ -0,0 +1,155 @@ +// COMPILE-FLAGS: -O2 +// COMPILE-ISET: -mips1 +// exact copy of late_rodata_jtbl.c except for the -mips1 addition +GLOBAL_ASM( +.late_rodata +.double 1 +.double 2 +.double 3 +.double 4 +.double 5 +.double 6 +.double 7 +.double 8 +.text +glabel doubles1 +nop +nop +nop +nop +nop +nop +nop +nop +nop +nop +nop +nop +nop +nop +nop +nop +nop +nop +nop +nop +nop +nop +nop +) + +float a(void) { return 1.1f; } + +GLOBAL_ASM( +.late_rodata +.float 1 +.double 2 +.double 3 +.double 4 +.double 5 +.double 6 +.double 7 +.double 8 +.double 9 +.float 10 +.text +glabel doubles2 +nop +nop +nop +nop +nop +nop +nop +nop +nop +nop +nop +nop +nop +nop +nop +nop +nop +nop +nop +nop +nop +nop +nop +) + +GLOBAL_ASM( +glabel a2 +move $a0, $a0 +nop +nop +nop +jr $ra +move $a0, $a0 +) + +GLOBAL_ASM( +.late_rodata + +glabel jtbl +.word case0, case1, case2, case3, case4, case5, case6, case7, case8, case9, case10 +.word case11, case12, case13, case14, case15, case16, case17, case18, case19, case20 +.word case21, case22, case23, case24, case25, case26 + +.text +glabel foo +sltiu $at, $a0, 0xa +beqz $at, .L756E659B + sll $t7, $a0, 2 +lui $at, %hi(jtbl) +addu $at, $at, $t7 +lw $t7, %lo(jtbl)($at) +jr $t7 + nop +case0: addiu $a0, $a0, 1 +case1: addiu $a0, $a0, 1 +case2: addiu $a0, $a0, 1 +case3: addiu $a0, $a0, 1 +case4: addiu $a0, $a0, 1 +case5: addiu $a0, $a0, 1 +case6: addiu $a0, $a0, 1 +case7: addiu $a0, $a0, 1 +case8: addiu $a0, $a0, 1 +case9: addiu $a0, $a0, 1 +case10: addiu $a0, $a0, 1 +case11: addiu $a0, $a0, 1 +case12: addiu $a0, $a0, 1 +case13: addiu $a0, $a0, 1 +case14: addiu $a0, $a0, 1 +case15: addiu $a0, $a0, 1 +case16: addiu $a0, $a0, 1 +case17: addiu $a0, $a0, 1 +case18: addiu $a0, $a0, 1 +case19: addiu $a0, $a0, 1 +case20: addiu $a0, $a0, 1 +case21: addiu $a0, $a0, 1 +case22: addiu $a0, $a0, 1 +case23: addiu $a0, $a0, 1 +case24: addiu $a0, $a0, 1 +case25: addiu $a0, $a0, 1 +case26: +jr $ra + addiu $v0, $a0, 1 + +.L756E659B: +addiu $v0, $zero, 2 +jr $ra + nop +) + +GLOBAL_ASM( +glabel b2 +move $a0, $a0 +nop +nop +jr $ra +move $a0, $a0 +) + +float b(void) { return 1.2f; } diff --git a/tools/asm-processor/tests/late_rodata_jtbl_mips1.objdump b/tools/asm-processor/tests/late_rodata_jtbl_mips1.objdump new file mode 100644 index 00000000..d37c8bb9 --- /dev/null +++ b/tools/asm-processor/tests/late_rodata_jtbl_mips1.objdump @@ -0,0 +1,110 @@ + +tests/late_rodata_jtbl_mips1.o: file format elf32-tradbigmips + +SYMBOL TABLE: +00000000 l d .text 000001a0 .text +00000000 l d .rodata 00000100 .rodata +00000000 l d .text 00000000 +0000005c g F .text 00000010 a +00000190 g F .text 00000010 b +00000000 g F .text 0000005c doubles1 +0000006c g F .text 0000005c doubles2 +000000c8 g F .text 00000018 a2 +000000e0 g F .text 0000009c foo +0000008c g .rodata 00000000 jtbl +0000017c g F .text 00000014 b2 + + +RELOCATION RECORDS FOR [.text]: +OFFSET TYPE VALUE +0000005c R_MIPS_HI16 .rodata +00000060 R_MIPS_LO16 .rodata +00000190 R_MIPS_HI16 .rodata +00000194 R_MIPS_LO16 .rodata +000000ec R_MIPS_HI16 jtbl +000000f4 R_MIPS_LO16 jtbl + + +RELOCATION RECORDS FOR [.rodata]: +OFFSET TYPE VALUE +0000008c R_MIPS_32 +00000090 R_MIPS_32 +00000094 R_MIPS_32 +00000098 R_MIPS_32 +0000009c R_MIPS_32 +000000a0 R_MIPS_32 +000000a4 R_MIPS_32 +000000a8 R_MIPS_32 +000000ac R_MIPS_32 +000000b0 R_MIPS_32 +000000b4 R_MIPS_32 +000000b8 R_MIPS_32 +000000bc R_MIPS_32 +000000c0 R_MIPS_32 +000000c4 R_MIPS_32 +000000c8 R_MIPS_32 +000000cc R_MIPS_32 +000000d0 R_MIPS_32 +000000d4 R_MIPS_32 +000000d8 R_MIPS_32 +000000dc R_MIPS_32 +000000e0 R_MIPS_32 +000000e4 R_MIPS_32 +000000e8 R_MIPS_32 +000000ec R_MIPS_32 +000000f0 R_MIPS_32 +000000f4 R_MIPS_32 + + +Contents of section .text: + 0000 00000000 00000000 00000000 00000000 ................ + 0010 00000000 00000000 00000000 00000000 ................ + 0020 00000000 00000000 00000000 00000000 ................ + 0030 00000000 00000000 00000000 00000000 ................ + 0040 00000000 00000000 00000000 00000000 ................ + 0050 00000000 00000000 00000000 3c010000 ............<... + 0060 c4200040 03e00008 00000000 00000000 . .@............ + 0070 00000000 00000000 00000000 00000000 ................ + 0080 00000000 00000000 00000000 00000000 ................ + 0090 00000000 00000000 00000000 00000000 ................ + 00a0 00000000 00000000 00000000 00000000 ................ + 00b0 00000000 00000000 00000000 00000000 ................ + 00c0 00000000 00000000 00802025 00000000 .......... %.... + 00d0 00000000 00000000 03e00008 00802025 .............. % + 00e0 2c81000a 10200022 00047880 3c010000 ,.... ."..x.<... + 00f0 002f0821 8c2f0000 01e00008 00000000 ./.!./.......... + 0100 24840001 24840001 24840001 24840001 $...$...$...$... + 0110 24840001 24840001 24840001 24840001 $...$...$...$... + 0120 24840001 24840001 24840001 24840001 $...$...$...$... + 0130 24840001 24840001 24840001 24840001 $...$...$...$... + 0140 24840001 24840001 24840001 24840001 $...$...$...$... + 0150 24840001 24840001 24840001 24840001 $...$...$...$... + 0160 24840001 24840001 03e00008 24820001 $...$.......$... + 0170 24020002 03e00008 00000000 00802025 $............. % + 0180 00000000 00000000 03e00008 00802025 .............. % + 0190 3c010000 c42000f8 03e00008 00000000 <.... .......... +Contents of section .rodata: + 0000 3ff00000 00000000 40000000 00000000 ?.......@....... + 0010 40080000 00000000 40100000 00000000 @.......@....... + 0020 40140000 00000000 40180000 00000000 @.......@....... + 0030 401c0000 00000000 40200000 00000000 @.......@ ...... + 0040 3f8ccccd 3f800000 40000000 00000000 ?...?...@....... + 0050 40080000 00000000 40100000 00000000 @.......@....... + 0060 40140000 00000000 40180000 00000000 @.......@....... + 0070 401c0000 00000000 40200000 00000000 @.......@ ...... + 0080 40220000 00000000 41200000 00000100 @"......A ...... + 0090 00000104 00000108 0000010c 00000110 ................ + 00a0 00000114 00000118 0000011c 00000120 ............... + 00b0 00000124 00000128 0000012c 00000130 ...$...(...,...0 + 00c0 00000134 00000138 0000013c 00000140 ...4...8...<...@ + 00d0 00000144 00000148 0000014c 00000150 ...D...H...L...P + 00e0 00000154 00000158 0000015c 00000160 ...T...X...\...` + 00f0 00000164 00000168 3f99999a 00000000 ...d...h?....... +Contents of section .options: + 0000 01200000 00000000 80004002 00000000 . ........@..... + 0010 000000f1 00000000 00000000 00007ff0 ................ + 0020 07100000 00000000 00000000 00000000 ................ + 0030 08100000 00000000 00000000 00000000 ................ +Contents of section .reginfo: + 0000 8000c016 00000000 000000f1 00000000 ................ + 0010 00000000 00007ff0 ........ diff --git a/tools/asm-processor/tests/late_rodata_misaligned_doubles.c b/tools/asm-processor/tests/late_rodata_misaligned_doubles.c new file mode 100644 index 00000000..a453dbdd --- /dev/null +++ b/tools/asm-processor/tests/late_rodata_misaligned_doubles.c @@ -0,0 +1,77 @@ +GLOBAL_ASM( +.late_rodata + .float 4.01 + .word 0 + .double 4.02 +.text +glabel a + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop +) + +double foo(void) { return 4.03; } + +GLOBAL_ASM( +.late_rodata + .float 4.04 + .double 4.05 +.text +glabel b + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop +) + +double bar(void) { return 4.06; } +float baz(void) { return 4.07f; } + +GLOBAL_ASM( +.late_rodata + .double 4.08 +.text +glabel c + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop + nop +) + diff --git a/tools/asm-processor/tests/late_rodata_misaligned_doubles.objdump b/tools/asm-processor/tests/late_rodata_misaligned_doubles.objdump new file mode 100644 index 00000000..cdba84de --- /dev/null +++ b/tools/asm-processor/tests/late_rodata_misaligned_doubles.objdump @@ -0,0 +1,56 @@ + +tests/late_rodata_misaligned_doubles.o: file format elf32-tradbigmips + +SYMBOL TABLE: +00000000 l d .text 00000120 .text +00000000 l d .rodata 00000040 .rodata +00000040 g F .text 0000001c foo +0000009c g F .text 0000001c bar +000000b8 g F .text 0000001c baz +00000000 g F .text 00000040 a +0000005c g F .text 00000040 b +000000d4 g F .text 00000040 c + + +RELOCATION RECORDS FOR [.text]: +OFFSET TYPE VALUE +00000040 R_MIPS_HI16 .rodata +00000048 R_MIPS_LO16 .rodata +0000009c R_MIPS_HI16 .rodata +000000a4 R_MIPS_LO16 .rodata +000000b8 R_MIPS_HI16 .rodata +000000c0 R_MIPS_LO16 .rodata + + +Contents of section .text: + 0000 00000000 00000000 00000000 00000000 ................ + 0010 00000000 00000000 00000000 00000000 ................ + 0020 00000000 00000000 00000000 00000000 ................ + 0030 00000000 00000000 00000000 00000000 ................ + 0040 3c010000 03e00008 d4200010 03e00008 <........ ...... + 0050 00000000 03e00008 00000000 00000000 ................ + 0060 00000000 00000000 00000000 00000000 ................ + 0070 00000000 00000000 00000000 00000000 ................ + 0080 00000000 00000000 00000000 00000000 ................ + 0090 00000000 00000000 00000000 3c010000 ............<... + 00a0 03e00008 d4200028 03e00008 00000000 ..... .(........ + 00b0 03e00008 00000000 3c010000 03e00008 ........<....... + 00c0 c4200030 03e00008 00000000 03e00008 . .0............ + 00d0 00000000 00000000 00000000 00000000 ................ + 00e0 00000000 00000000 00000000 00000000 ................ + 00f0 00000000 00000000 00000000 00000000 ................ + 0100 00000000 00000000 00000000 00000000 ................ + 0110 00000000 00000000 00000000 00000000 ................ +Contents of section .rodata: + 0000 408051ec 00000000 4010147a e147ae14 @.Q.....@..z.G.. + 0010 40101eb8 51eb851f 00000000 408147ae @...Q.......@.G. + 0020 40103333 33333333 40103d70 a3d70a3d @.333333@.=p...= + 0030 40823d71 00000000 401051eb 851eb852 @.=q....@.Q....R +Contents of section .options: + 0000 01200000 00000000 80000002 00000000 . .............. + 0010 000000f3 00000000 00000000 00007ff0 ................ + 0020 07100000 00000000 00000000 00000000 ................ + 0030 08100000 00000000 00000000 00000000 ................ +Contents of section .reginfo: + 0000 80000002 00000000 000000f3 00000000 ................ + 0010 00000000 00007ff0 ........ diff --git a/tools/asm-processor/tests/line-continuation-separate-file.s b/tools/asm-processor/tests/line-continuation-separate-file.s new file mode 100644 index 00000000..e1301804 --- /dev/null +++ b/tools/asm-processor/tests/line-continuation-separate-file.s @@ -0,0 +1,4 @@ +.rdata + label: .asciiz "1\n\ +2", \ + "34", "56" diff --git a/tools/asm-processor/tests/line-continuation.asmproc.d b/tools/asm-processor/tests/line-continuation.asmproc.d new file mode 100644 index 00000000..687dd1ae --- /dev/null +++ b/tools/asm-processor/tests/line-continuation.asmproc.d @@ -0,0 +1,3 @@ +tests/line-continuation.o: tests/line-continuation-separate-file.s + +tests/line-continuation-separate-file.s: diff --git a/tools/asm-processor/tests/line-continuation.c b/tools/asm-processor/tests/line-continuation.c new file mode 100644 index 00000000..d5ab0937 --- /dev/null +++ b/tools/asm-processor/tests/line-continuation.c @@ -0,0 +1,22 @@ +void foo(void) { "abcdef"; } + +GLOBAL_ASM( +.rdata + .ascii "AB" \ + "CD", "EF" + .ascii "GH\n\n\n\0\11\222\3333\44444\x1234567\n\nIJK" +) + +void bar(void) { "hello"; } + +GLOBAL_ASM( +.rdata + .asciiz "1\ +2" + .asciiz "34", "56" + .asciiz "78\n\n\n\0\11\222\3333\44444\x1234567\n\n9A" +) + +void baz(void) { "ghijkl"; } + +GLOBAL_ASM("tests/line-continuation-separate-file.s") diff --git a/tools/asm-processor/tests/line-continuation.objdump b/tools/asm-processor/tests/line-continuation.objdump new file mode 100644 index 00000000..038766fd --- /dev/null +++ b/tools/asm-processor/tests/line-continuation.objdump @@ -0,0 +1,30 @@ + +tests/line-continuation.o: file format elf32-tradbigmips + +SYMBOL TABLE: +00000000 l d .text 00000030 .text +00000000 l d .rodata 00000060 .rodata +00000000 g F .text 00000010 foo +00000010 g F .text 00000010 bar +00000020 g F .text 00000010 baz + + +Contents of section .text: + 0000 03e00008 00000000 03e00008 00000000 ................ + 0010 03e00008 00000000 03e00008 00000000 ................ + 0020 03e00008 00000000 03e00008 00000000 ................ +Contents of section .rodata: + 0000 61626364 65660000 41424344 45464748 abcdef..ABCDEFGH + 0010 0a0a0a00 0992db33 24343467 0a0a494a .......3$44g..IJ + 0020 4b000000 68656c6c 6f000000 31320033 K...hello...12.3 + 0030 34003536 0037380a 0a0a0009 92db3324 4.56.78.......3$ + 0040 3434670a 0a394100 6768696a 6b6c0000 44g..9A.ghijkl.. + 0050 310a3200 33340035 36000000 00000000 1.2.34.56....... +Contents of section .options: + 0000 01200000 00000000 80000000 00000000 . .............. + 0010 00000000 00000000 00000000 00007ff0 ................ + 0020 07100000 00000000 00000000 00000000 ................ + 0030 08100000 00000000 00000000 00000000 ................ +Contents of section .reginfo: + 0000 80000000 00000000 00000000 00000000 ................ + 0010 00000000 00007ff0 ........ diff --git a/tools/asm-processor/tests/o0.c b/tools/asm-processor/tests/o0.c new file mode 100644 index 00000000..6f8e5e41 --- /dev/null +++ b/tools/asm-processor/tests/o0.c @@ -0,0 +1,28 @@ +// COMPILE-FLAGS: -O0 + +int a(void) { return 1; } +GLOBAL_ASM( +glabel foo +addiu $a0, $a0, 1 +addiu $a0, $a0, 2 +addiu $a0, $a0, 3 +jr $ra +addiu $a0, $a0, 4 +) +float b(void) { return 1.2f; } +GLOBAL_ASM( +.late_rodata +glabel float1 +.float 12.34 + +.text +glabel bar +addiu $a0, $a0, 5 +addiu $a0, $a0, 6 +addiu $a0, $a0, 7 +addiu $a0, $a0, 8 +lui $v0, %hi(float1 + 1) +jr $ra +addiu $v0, $v0, %lo(float1 + 1) +) +float c(void) { return 1.3f; } diff --git a/tools/asm-processor/tests/o0.objdump b/tools/asm-processor/tests/o0.objdump new file mode 100644 index 00000000..f94ec7a0 --- /dev/null +++ b/tools/asm-processor/tests/o0.objdump @@ -0,0 +1,44 @@ + +tests/o0.o: file format elf32-tradbigmips + +SYMBOL TABLE: +00000000 l d .text 00000090 .text +00000000 l d .rodata 00000010 .rodata +00000000 g F .text 0000001c a +00000030 g F .text 00000020 b +0000006c g F .text 00000020 c +0000001c g F .text 00000014 foo +00000050 g F .text 0000001c bar +00000004 g .rodata 00000000 float1 + + +RELOCATION RECORDS FOR [.text]: +OFFSET TYPE VALUE +00000030 R_MIPS_HI16 .rodata +00000034 R_MIPS_LO16 .rodata +0000006c R_MIPS_HI16 .rodata +00000070 R_MIPS_LO16 .rodata +00000060 R_MIPS_HI16 float1 +00000068 R_MIPS_LO16 float1 + + +Contents of section .text: + 0000 24020001 03e00008 00000000 03e00008 $............... + 0010 00000000 03e00008 00000000 24840001 ............$... + 0020 24840002 24840003 03e00008 24840004 $...$.......$... + 0030 3c010000 c4200000 03e00008 00000000 <.... .......... + 0040 03e00008 00000000 03e00008 00000000 ................ + 0050 24840005 24840006 24840007 24840008 $...$...$...$... + 0060 3c020000 03e00008 24420001 3c010000 <.......$B..<... + 0070 c4200008 03e00008 00000000 03e00008 . .............. + 0080 00000000 03e00008 00000000 00000000 ................ +Contents of section .rodata: + 0000 3f99999a 414570a4 3fa66666 00000000 ?...AEp.?.ff.... +Contents of section .options: + 0000 01200000 00000000 80000006 00000000 . .............. + 0010 00000011 00000000 00000000 00007ff0 ................ + 0020 07100000 00000000 00000000 00000000 ................ + 0030 08100000 00000000 00000000 00000000 ................ +Contents of section .reginfo: + 0000 80000016 00000000 00000011 00000000 ................ + 0010 00000000 00007ff0 ........ diff --git a/tools/asm-processor/tests/o2.c b/tools/asm-processor/tests/o2.c new file mode 100644 index 00000000..144a604e --- /dev/null +++ b/tools/asm-processor/tests/o2.c @@ -0,0 +1,26 @@ +// COMPILE-FLAGS: -O2 + +int a(void) { return 1; } +GLOBAL_ASM( +glabel foo +addiu $a0, $a0, 1 +addiu $a0, $a0, 2 +addiu $a0, $a0, 3 +jr $ra +addiu $a0, $a0, 4 +) +float b(void) { return 1.2f; } +GLOBAL_ASM( +.late_rodata +glabel float1 +.float 12.34 + +.text +glabel bar +addiu $a0, $a0, 5 +addiu $a0, $a0, 6 +lui $v0, %hi(float1 + 1) +jr $ra +addiu $v0, $v0, %lo(float1 + 1) +) +float c(void) { return 1.3f; } diff --git a/tools/asm-processor/tests/o2.objdump b/tools/asm-processor/tests/o2.objdump new file mode 100644 index 00000000..61e3fb0e --- /dev/null +++ b/tools/asm-processor/tests/o2.objdump @@ -0,0 +1,40 @@ + +tests/o2.o: file format elf32-tradbigmips + +SYMBOL TABLE: +00000000 l d .text 00000050 .text +00000000 l d .rodata 00000010 .rodata +00000000 g F .text 00000008 a +0000001c g F .text 0000000c b +0000003c g F .text 0000000c c +00000008 g F .text 00000014 foo +00000028 g F .text 00000014 bar +00000004 g .rodata 00000000 float1 + + +RELOCATION RECORDS FOR [.text]: +OFFSET TYPE VALUE +0000001c R_MIPS_HI16 .rodata +00000024 R_MIPS_LO16 .rodata +0000003c R_MIPS_HI16 .rodata +00000044 R_MIPS_LO16 .rodata +00000030 R_MIPS_HI16 float1 +00000038 R_MIPS_LO16 float1 + + +Contents of section .text: + 0000 03e00008 24020001 24840001 24840002 ....$...$...$... + 0010 24840003 03e00008 24840004 3c010000 $.......$...<... + 0020 03e00008 c4200000 24840005 24840006 ..... ..$...$... + 0030 3c020000 03e00008 24420001 3c010000 <.......$B..<... + 0040 03e00008 c4200008 00000000 00000000 ..... .......... +Contents of section .rodata: + 0000 3f99999a 414570a4 3fa66666 00000000 ?...AEp.?.ff.... +Contents of section .options: + 0000 01200000 00000000 80000006 00000000 . .............. + 0010 00000011 00000000 00000000 00007ff0 ................ + 0020 07100000 00000000 00000000 00000000 ................ + 0030 08100000 00000000 00000000 00000000 ................ +Contents of section .reginfo: + 0000 80000016 00000000 00000011 00000000 ................ + 0010 00000000 00007ff0 ........ diff --git a/tools/asm-processor/tests/pascal.objdump b/tools/asm-processor/tests/pascal.objdump new file mode 100644 index 00000000..cb3740f0 --- /dev/null +++ b/tools/asm-processor/tests/pascal.objdump @@ -0,0 +1,137 @@ + +tests/pascal.o: file format elf32-tradbigmips + +SYMBOL TABLE: +00000000 l d .text 000000e0 .text +00000000 l d .rodata 00000030 .rodata +00000000 l d .data 00000010 .data +00000000 l d .bss 00000010 .bss +00000000 l O .bss 00000000 $dat +00000000 g F .text 0000000c foo +000000d0 g F .text 0000000c bar +0000000c g F .text 00000004 test +00000048 g F .text 00000004 test2 +0000008c g F .text 00000044 test3 +00000000 *UND* 00000000 get +00000000 *UND* 00000000 put +00000000 *UND* 00000000 pascal_close +00000000 *UND* 00000000 fflush +00000000 *UND* 00000000 filesize +00000000 *UND* 00000000 curpos +00000000 *UND* 00000000 seek +00000000 *UND* 00000000 eof +00000000 *UND* 00000000 eoln +00000000 *UND* 00000000 page +00000000 *UND* 00000000 reset +00000000 *UND* 00000000 rewrite +00000000 *UND* 00000000 cos +00000000 *UND* 00000000 exp +00000000 *UND* 00000000 sqrt +00000000 *UND* 00000000 log +00000000 *UND* 00000000 atan +00000000 *UND* 00000000 sin +00000000 *UND* 00000000 __random_float +00000000 *UND* 00000000 clock +00000000 *UND* 00000000 exit +00000000 *UND* 00000000 __date +00000000 *UND* 00000000 __time +00000000 *UND* 00000000 get_arg +00000000 *UND* 00000000 new +00000000 *UND* 00000000 dispose +00000000 *UND* 00000000 initfile +00000000 *UND* 00000000 peek_char +00000000 *UND* 00000000 next_char +00000000 *UND* 00000000 readln +00000000 *UND* 00000000 read_int64 +00000000 *UND* 00000000 read_card64 +00000000 *UND* 00000000 read_integer +00000000 *UND* 00000000 read_cardinal +00000000 *UND* 00000000 read_integer_range +00000000 *UND* 00000000 read_real +00000000 *UND* 00000000 read_double +00000000 *UND* 00000000 read_extended +00000000 *UND* 00000000 read_string +00000000 *UND* 00000000 read_enum +00000000 *UND* 00000000 read_char +00000000 *UND* 00000000 read_char_range +00000000 *UND* 00000000 read_boolean +00000000 *UND* 00000000 read_set +00000000 *UND* 00000000 writeln +00000000 *UND* 00000000 write_int64 +00000000 *UND* 00000000 write_card64 +00000000 *UND* 00000000 write_integer +00000000 *UND* 00000000 write_cardinal +00000000 *UND* 00000000 write_boolean +00000000 *UND* 00000000 write_char +00000000 *UND* 00000000 write_real +00000000 *UND* 00000000 write_double +00000000 *UND* 00000000 write_extended +00000000 *UND* 00000000 write_string +00000000 *UND* 00000000 write_enum +00000000 *UND* 00000000 write_set +00000000 *UND* 00000000 caseerror +00000000 *UND* 00000000 __pc_nloc_goto +00000000 *UND* 00000000 memcpy +00000000 *UND* 00000000 __in_range +00000000 *UND* 00000000 __ll_mul +00000000 *UND* 00000000 __ll_div +00000000 *UND* 00000000 __ull_div +00000000 *UND* 00000000 __ll_mod +00000000 *UND* 00000000 __ll_rem +00000000 *UND* 00000000 __ull_rem +00000000 *UND* 00000000 __ll_lshift +00000000 *UND* 00000000 __ll_rshift +00000000 *UND* 00000000 __ll_to_f +00000000 *UND* 00000000 __ull_to_f +00000000 *UND* 00000000 __ll_to_d +00000000 *UND* 00000000 __ull_to_d +00000000 *UND* 00000000 __f_ll_ll +00000000 *UND* 00000000 __f_to_ull +00000000 *UND* 00000000 __d_to_ll +00000000 *UND* 00000000 __d_to_ull +00000000 *UND* 00000000 round64 +00000000 *UND* 00000000 trunc64 +00000000 *UND* 00000000 max64 +00000000 *UND* 00000000 min64 +00000000 *UND* 00000000 abs64 +00000000 *UND* 00000000 odd64 +00000000 *UND* 00000000 trapNaN +00000000 *UND* 00000008 input +00000000 *UND* 00000008 output +00000000 *UND* 00000008 err +00000000 *UND* 00000008 __Argc + + +RELOCATION RECORDS FOR [.text]: (none) + +RELOCATION RECORDS FOR [.rodata]: (none) + +Contents of section .text: + 0000 00041080 03e00008 00441023 27bdffe8 .........D.#'... + 0010 18a00009 afa00004 8fae0004 008e7821 ..............x! + 0020 a1e00000 8fb80004 27190001 0325082a ........'....%.* + 0030 1420fff9 afb90004 10000001 00000000 . .............. + 0040 03e00008 27bd0018 00000000 00000000 ....'........... + 0050 00000000 00000000 00000000 00000000 ................ + 0060 00000000 00000000 00000000 00000000 ................ + 0070 00000000 00000000 00000000 00000000 ................ + 0080 00000000 00000000 00000000 00000000 ................ + 0090 00000000 00000000 00000000 00000000 ................ + 00a0 00000000 00000000 00000000 00000000 ................ + 00b0 00000000 00000000 00000000 00000000 ................ + 00c0 00000000 00000000 00000000 00000000 ................ + 00d0 00041080 03e00008 00441023 00000000 .........D.#.... +Contents of section .rodata: + 0000 00123123 00456456 00789789 00000001 ..1#.EdV.x...... + 0010 3ff19999 9999999a 00000002 00000003 ?............... + 0020 4000cccc cccccccd 00000000 00000000 @............... +Contents of section .data: + 0000 00002323 00003434 00000000 00000000 ..##..44........ +Contents of section .options: + 0000 01200000 00000000 80004016 00000000 . ........@..... + 0010 000000f0 00000000 00000000 00007ff0 ................ + 0020 07100000 00000000 00000000 00000000 ................ + 0030 08100000 00000000 00000000 00000000 ................ +Contents of section .reginfo: + 0000 a300c036 00000000 000000f0 00000000 ...6............ + 0010 00000000 00007ff0 ........ diff --git a/tools/asm-processor/tests/pascal.p b/tools/asm-processor/tests/pascal.p new file mode 100644 index 00000000..0886126a --- /dev/null +++ b/tools/asm-processor/tests/pascal.p @@ -0,0 +1,95 @@ +{ COMPILE-FLAGS: -O2 } + +function foo(x: integer): integer; +begin + foo := x * 3 +end; + +GLOBAL_ASM( +.section .data +.word 0x2323 + +.late_rodata +.word 0x123123 +.word 0x456456 +.word 0x789789 +.text +glabel test +/* 000090 00400090 27BDFFF8 */ addiu $sp, $sp, -24 +/* 000094 00400094 18A00009 */ blez $a1, .L004000BC +/* 000098 00400098 AFA00004 */ sw $zero, 4($sp) +.L0040009C: +/* 00009C 0040009C 8FAE0004 */ lw $t6, 4($sp) +/* 0000A0 004000A0 008E7821 */ addu $t7, $a0, $t6 +/* 0000A4 004000A4 A1E00000 */ sb $zero, ($t7) +/* 0000A8 004000A8 8FB80004 */ lw $t8, 4($sp) +/* 0000AC 004000AC 27190001 */ addiu $t9, $t8, 1 +/* 0000B0 004000B0 0325082A */ slt $at, $t9, $a1 +/* 0000B4 004000B4 1420FFF9 */ bnez $at, .L0040009C +/* 0000B8 004000B8 AFB90004 */ sw $t9, 4($sp) +.L004000BC: +/* 0000BC 004000BC 10000001 */ b .L004000C4 +/* 0000C0 004000C0 00000000 */ nop +.L004000C4: +/* 0000C4 004000C4 03E00008 */ jr $ra +/* 0000C8 004000C8 27BD0008 */ addiu $sp, $sp, 24 +) + +GLOBAL_ASM( +.section .data +.word 0x3434 + +.late_rodata +.word 0x1 +.double 1.1 +.word 0x2, 0x3 +.text +glabel test2 +nop +nop +nop +nop +nop +nop +nop +nop +nop +nop +nop +nop +nop +nop +nop +nop +nop +) + +GLOBAL_ASM( +.late_rodata +.double 2.1 +.text +glabel test3 +nop +nop +nop +nop +nop +nop +nop +nop +nop +nop +nop +nop +nop +nop +nop +nop +nop +) + +function bar(x: integer): integer; +begin + return x * 3 +end; + diff --git a/tools/asm-processor/tests/static-global.c b/tools/asm-processor/tests/static-global.c new file mode 100644 index 00000000..a7f61690 --- /dev/null +++ b/tools/asm-processor/tests/static-global.c @@ -0,0 +1,33 @@ +// COMPILE-FLAGS: -O2 +// ASMP-FLAGS: --convert-statics=global +static int xtext(int a, int b, int c); +const int rodata1[] = {1}; +static const int rodata2[] = {2}; +int data1[] = {3}; +static int data2[] = {4}; +int bss1; +static int bss2; + +GLOBAL_ASM( +glabel bar +lui $a0, %hi(rodata2) +lw $a0, %lo(rodata2)($a0) +lui $a1, %hi(data2) +lw $a1, %lo(data2)($a0) +lui $a2, %hi(bss2) +lw $a2, %lo(bss2)($a0) +jal xtext +nop +jr $ra +nop +nop +nop +) + +static int xtext(int a, int b, int c) { + return 1; +} + +void baz(void) { + xtext(bss2, rodata2[0], data2[0]); +} diff --git a/tools/asm-processor/tests/static-global.objdump b/tools/asm-processor/tests/static-global.objdump new file mode 100644 index 00000000..a519e4f4 --- /dev/null +++ b/tools/asm-processor/tests/static-global.objdump @@ -0,0 +1,58 @@ + +tests/static-global.o: file format elf32-tradbigmips + +SYMBOL TABLE: +00000000 l d .text 00000080 .text +00000000 l d .rodata 00000010 .rodata +00000000 l d .data 00000010 .data +00000000 l d .bss 00000010 .bss +00000000 g O .rodata 00000004 rodata1 +00000000 g O .data 00000004 data1 +00000000 g O .bss 00000004 bss1 +00000044 g F .text 00000034 baz +00000000 g F .text 00000030 bar +00000004 g O .rodata 00000000 rodata2 +00000004 g O .data 00000000 data2 +00000004 g O .bss 00000000 bss2 +00000030 g F .text 00000000 xtext + + +RELOCATION RECORDS FOR [.text]: +OFFSET TYPE VALUE +0000004c R_MIPS_HI16 .bss +00000064 R_MIPS_LO16 .bss +00000050 R_MIPS_HI16 .rodata +0000005c R_MIPS_LO16 .rodata +00000054 R_MIPS_HI16 .data +00000058 R_MIPS_LO16 .data +00000060 R_MIPS_26 .text +00000000 R_MIPS_HI16 rodata2 +00000004 R_MIPS_LO16 rodata2 +00000008 R_MIPS_HI16 data2 +0000000c R_MIPS_LO16 data2 +00000010 R_MIPS_HI16 bss2 +00000014 R_MIPS_LO16 bss2 +00000018 R_MIPS_26 xtext + + +Contents of section .text: + 0000 3c040000 8c840000 3c050000 8c850000 <.......<....... + 0010 3c060000 8c860000 0c000000 00000000 <............... + 0020 03e00008 00000000 00000000 00000000 ................ + 0030 afa40000 afa50004 afa60008 03e00008 ................ + 0040 24020001 27bdffe8 afbf0014 3c040000 $...'.......<... + 0050 3c050000 3c060000 8cc60004 8ca50004 <...<........... + 0060 0c00000c 8c840004 8fbf0014 27bd0018 ............'... + 0070 03e00008 00000000 00000000 00000000 ................ +Contents of section .rodata: + 0000 00000001 00000002 00000000 00000000 ................ +Contents of section .data: + 0000 00000003 00000004 00000000 00000000 ................ +Contents of section .options: + 0000 01200000 00000000 a0000074 00000000 . .........t.... + 0010 00000000 00000000 00000000 00007ff0 ................ + 0020 07100000 00000000 00000000 00000000 ................ + 0030 08100000 00000000 00000000 00000000 ................ +Contents of section .reginfo: + 0000 a0000074 00000000 00000000 00000000 ...t............ + 0010 00000000 00007ff0 ........ diff --git a/tools/asm-processor/tests/static.c b/tools/asm-processor/tests/static.c new file mode 100644 index 00000000..c265021e --- /dev/null +++ b/tools/asm-processor/tests/static.c @@ -0,0 +1,32 @@ +// COMPILE-FLAGS: -O2 +static int xtext(int a, int b, int c); +const int rodata1[] = {1}; +static const int rodata2[] = {2}; +int data1[] = {3}; +static int data2[] = {4}; +int bss1; +static int bss2; + +GLOBAL_ASM( +glabel bar +lui $a0, %hi(rodata2) +lw $a0, %lo(rodata2)($a0) +lui $a1, %hi(data2) +lw $a1, %lo(data2)($a0) +lui $a2, %hi(bss2) +lw $a2, %lo(bss2)($a0) +jal xtext +nop +jr $ra +nop +nop +nop +) + +static int xtext(int a, int b, int c) { + return 1; +} + +void baz(void) { + xtext(bss2, rodata2[0], data2[0]); +} diff --git a/tools/asm-processor/tests/static.objdump b/tools/asm-processor/tests/static.objdump new file mode 100644 index 00000000..dd62c94c --- /dev/null +++ b/tools/asm-processor/tests/static.objdump @@ -0,0 +1,58 @@ + +tests/static.o: file format elf32-tradbigmips + +SYMBOL TABLE: +00000000 l d .text 00000080 .text +00000000 l d .rodata 00000010 .rodata +00000000 l d .data 00000010 .data +00000000 l d .bss 00000010 .bss +00000004 l O .rodata 00000000 rodata2 +00000004 l O .data 00000000 data2 +00000004 l O .bss 00000000 bss2 +00000030 l F .text 00000000 xtext +00000000 g O .rodata 00000004 rodata1 +00000000 g O .data 00000004 data1 +00000000 g O .bss 00000004 bss1 +00000044 g F .text 00000034 baz +00000000 g F .text 00000030 bar + + +RELOCATION RECORDS FOR [.text]: +OFFSET TYPE VALUE +0000004c R_MIPS_HI16 .bss +00000064 R_MIPS_LO16 .bss +00000050 R_MIPS_HI16 .rodata +0000005c R_MIPS_LO16 .rodata +00000054 R_MIPS_HI16 .data +00000058 R_MIPS_LO16 .data +00000060 R_MIPS_26 .text +00000000 R_MIPS_HI16 rodata2 +00000004 R_MIPS_LO16 rodata2 +00000008 R_MIPS_HI16 data2 +0000000c R_MIPS_LO16 data2 +00000010 R_MIPS_HI16 bss2 +00000014 R_MIPS_LO16 bss2 +00000018 R_MIPS_26 xtext + + +Contents of section .text: + 0000 3c040000 8c840000 3c050000 8c850000 <.......<....... + 0010 3c060000 8c860000 0c000000 00000000 <............... + 0020 03e00008 00000000 00000000 00000000 ................ + 0030 afa40000 afa50004 afa60008 03e00008 ................ + 0040 24020001 27bdffe8 afbf0014 3c040000 $...'.......<... + 0050 3c050000 3c060000 8cc60004 8ca50004 <...<........... + 0060 0c00000c 8c840004 8fbf0014 27bd0018 ............'... + 0070 03e00008 00000000 00000000 00000000 ................ +Contents of section .rodata: + 0000 00000001 00000002 00000000 00000000 ................ +Contents of section .data: + 0000 00000003 00000004 00000000 00000000 ................ +Contents of section .options: + 0000 01200000 00000000 a0000074 00000000 . .........t.... + 0010 00000000 00000000 00000000 00007ff0 ................ + 0020 07100000 00000000 00000000 00000000 ................ + 0030 08100000 00000000 00000000 00000000 ................ +Contents of section .reginfo: + 0000 a0000074 00000000 00000000 00000000 ...t............ + 0010 00000000 00007ff0 ........ diff --git a/tools/asm-processor/tests/test1.c b/tools/asm-processor/tests/test1.c new file mode 100644 index 00000000..475555a7 --- /dev/null +++ b/tools/asm-processor/tests/test1.c @@ -0,0 +1,71 @@ + +GLOBAL_ASM( +.rdata +.word 0x1212 +) + +GLOBAL_ASM( +.late_rodata +.word 0x123123 +.text +glabel test +/* 000090 00400090 27BDFFF8 */ addiu $sp, $sp, -24 +/* 000094 00400094 18A00009 */ blez $a1, .L004000BC +/* 000098 00400098 AFA00004 */ sw $zero, 4($sp) +.L0040009C: +/* 00009C 0040009C 8FAE0004 */ lw $t6, 4($sp) +/* 0000A0 004000A0 008E7821 */ addu $t7, $a0, $t6 +/* 0000A4 004000A4 A1E00000 */ sb $zero, ($t7) +/* 0000A8 004000A8 8FB80004 */ lw $t8, 4($sp) +/* 0000AC 004000AC 27190001 */ addiu $t9, $t8, 1 +/* 0000B0 004000B0 0325082A */ slt $at, $t9, $a1 +/* 0000B4 004000B4 1420FFF9 */ bnez $at, .L0040009C +/* 0000B8 004000B8 AFB90004 */ sw $t9, 4($sp) +.L004000BC: +/* 0000BC 004000BC 10000001 */ b .L004000C4 +/* 0000C0 004000C0 00000000 */ nop +.L004000C4: +/* 0000C4 004000C4 03E00008 */ jr $ra +/* 0000C8 004000C8 27BD0008 */ addiu $sp, $sp, 24 +) + +char bss1[3]; +GLOBAL_ASM( +.bss +bss2: +.space 3 +) +char bss3[3]; +char bss4[3]; +const int rodata1[2] = {1}; +extern int some_rodata; + +unsigned g(float, int); +unsigned f(void) { + return g(1.1f, some_rodata); +} + +GLOBAL_ASM( +.rdata +glabel some_rodata +.word 0x1313 +.text +.late_rodata +.word 0x321321 +.text +glabel g +/* 0000C0 004000C0 27BDFFE8 */ addiu $sp, $sp, -0x18 +/* 0000C4 004000C4 AFBF0014 */ sw $ra, 0x14($sp) +/* 0000C8 004000C8 240E0004 */ addiu $t6, $zero, 4 +/* 0000CC 004000CC 3C010041 */ lui $at, %hi(D_410100) +/* 0000D0 004000D0 AC2E0100 */ sw $t6, %lo(D_410100)($at) +/* 0000D4 004000D4 0C10002C */ jal func_004000B0 +/* 0000D8 004000D8 00000000 */ nop +/* 0000DC 004000DC 10000001 */ b .L004000E4 +/* 0000E0 004000E0 00000000 */ nop +.L004000E4: +/* 0000E4 004000E4 8FBF0014 */ lw $ra, 0x14($sp) +/* 0000E8 004000E8 27BD0018 */ addiu $sp, $sp, 0x18 +/* 0000EC 004000EC 03E00008 */ jr $ra +/* 0000F0 004000F0 00000000 */ nop +) diff --git a/tools/asm-processor/tests/test1.objdump b/tools/asm-processor/tests/test1.objdump new file mode 100644 index 00000000..b97ae46e --- /dev/null +++ b/tools/asm-processor/tests/test1.objdump @@ -0,0 +1,54 @@ + +tests/test1.o: file format elf32-tradbigmips + +SYMBOL TABLE: +00000000 l d .text 000000b0 .text +00000000 l d .rodata 00000020 .rodata +00000000 l d .bss 00000010 .bss +00000000 g O .bss 00000003 bss1 +00000008 g O .bss 00000003 bss3 +0000000c g O .bss 00000003 bss4 +00000004 g O .rodata 00000008 rodata1 +0000003c g F .text 0000003c f +00000000 g F .text 0000003c test +0000000c g .rodata 00000000 some_rodata +00000078 g F .text 00000004 g +00000000 *UND* 00000000 D_410100 +00000000 *UND* 00000000 func_004000B0 + + +RELOCATION RECORDS FOR [.text]: +OFFSET TYPE VALUE +00000044 R_MIPS_HI16 .rodata +00000054 R_MIPS_LO16 .rodata +00000048 R_MIPS_HI16 some_rodata +0000004c R_MIPS_LO16 some_rodata +00000050 R_MIPS_26 g +00000084 R_MIPS_HI16 D_410100 +00000088 R_MIPS_LO16 D_410100 +0000008c R_MIPS_26 func_004000B0 + + +Contents of section .text: + 0000 27bdffe8 18a00009 afa00004 8fae0004 '............... + 0010 008e7821 a1e00000 8fb80004 27190001 ..x!........'... + 0020 0325082a 1420fff9 afb90004 10000001 .%.*. .......... + 0030 00000000 03e00008 27bd0018 27bdffe8 ........'...'... + 0040 afbf0014 3c010000 3c050000 8ca50000 ....<...<....... + 0050 0c000000 c42c0014 10000003 00000000 .....,.......... + 0060 10000001 00000000 8fbf0014 27bd0018 ............'... + 0070 03e00008 00000000 27bdffe8 afbf0014 ........'....... + 0080 240e0004 3c010000 ac2e0000 0c000000 $...<........... + 0090 00000000 10000001 00000000 8fbf0014 ................ + 00a0 27bd0018 03e00008 00000000 00000000 '............... +Contents of section .rodata: + 0000 00001212 00000001 00000000 00001313 ................ + 0010 00123123 3f8ccccd 00321321 00000000 ..1#?....2.!.... +Contents of section .options: + 0000 01200000 00000000 a0000022 00000000 . .........".... + 0010 00001010 00000000 00000000 00007ff0 ................ + 0020 07100000 00000000 00000000 00000000 ................ + 0030 08100000 00000000 00000000 00000000 ................ +Contents of section .reginfo: + 0000 a300c032 00000000 00001010 00000000 ...2............ + 0010 00000000 00007ff0 ........ diff --git a/tools/asm-processor/tests/test2.c b/tools/asm-processor/tests/test2.c new file mode 100644 index 00000000..15969feb --- /dev/null +++ b/tools/asm-processor/tests/test2.c @@ -0,0 +1,69 @@ +const char buf1[1] = {1}; +float func1(void) { + "func1"; + return 0.1f; +} +const char buf2[1] = {2}; +void func2(void) { + *(volatile float*)0 = -3.5792360305786133f; + *(volatile float*)0 = -3.5792362689971924f; + // "func2"; + // return 0.2f; +} +const char buf3[1] = {3}; +int func3(int x) { + switch(x) { + case 0: + return 1; + case 1: + return 2; + case 2: + return 3; + case 3: + return 4; + case 4: + return 5; + case 5: + return 4; + case 6: + return 4; + case 7: + return 4; + default: + return 3; + } +} + +#if 1 +GLOBAL_ASM( +.rdata +.word 0x66756e63 # func +.word 0x34000000 # 4\0\0\0 +.word jumptarget + 4 + +.late_rodata +glabel rv +.word 0x3e4ccccd # 0.2f +.word jumptarget + 8 + +.text +glabel func4 +lui $at, %hi(rv) +glabel jumptarget +jr $ra +lwc1 $f0, %lo(rv)($at) +jr $ra +nop +jr $ra +nop +jr $ra +nop +jr $ra +nop +) +#else +float func4(void) { + "func4"; + return 0.2f; +} +#endif diff --git a/tools/asm-processor/tests/test2.objdump b/tools/asm-processor/tests/test2.objdump new file mode 100644 index 00000000..276ed9f1 --- /dev/null +++ b/tools/asm-processor/tests/test2.objdump @@ -0,0 +1,76 @@ + +tests/test2.o: file format elf32-tradbigmips + +SYMBOL TABLE: +00000000 l d .text 000000f0 .text +00000000 l d .rodata 00000060 .rodata +00000000 g O .rodata 00000001 buf1 +00000000 g F .text 0000001c func1 +0000000c g O .rodata 00000001 buf2 +0000001c g F .text 00000028 func2 +00000010 g O .rodata 00000001 buf3 +00000044 g F .text 0000007c func3 +000000c4 g F .text 00000000 jumptarget +000000c0 g F .text 0000000c func4 +0000004c g .rodata 00000000 rv + + +RELOCATION RECORDS FOR [.text]: +OFFSET TYPE VALUE +00000000 R_MIPS_HI16 .rodata +00000008 R_MIPS_LO16 .rodata +0000001c R_MIPS_HI16 .rodata +00000020 R_MIPS_LO16 .rodata +00000028 R_MIPS_HI16 .rodata +0000002c R_MIPS_LO16 .rodata +00000054 R_MIPS_HI16 .rodata +0000005c R_MIPS_LO16 .rodata +000000c0 R_MIPS_HI16 rv +000000c8 R_MIPS_LO16 rv + + +RELOCATION RECORDS FOR [.rodata]: +OFFSET TYPE VALUE +0000002c R_MIPS_32 .text +00000030 R_MIPS_32 .text +00000034 R_MIPS_32 .text +00000038 R_MIPS_32 .text +0000003c R_MIPS_32 .text +00000040 R_MIPS_32 .text +00000044 R_MIPS_32 .text +00000048 R_MIPS_32 .text +0000001c R_MIPS_32 jumptarget +00000050 R_MIPS_32 jumptarget + + +Contents of section .text: + 0000 3c010000 03e00008 c4200020 03e00008 <........ . .... + 0010 00000000 03e00008 00000000 3c010000 ............<... + 0020 c4240024 e4040000 3c010000 c4260028 .$.$....<....&.( + 0030 e4060000 03e00008 00000000 03e00008 ................ + 0040 00000000 2c810008 10200017 00000000 ....,.... ...... + 0050 00047080 3c010000 002e0821 8c2e002c ..p.<......!..., + 0060 01c00008 00000000 03e00008 24020001 ............$... + 0070 03e00008 24020002 03e00008 24020003 ....$.......$... + 0080 03e00008 24020004 03e00008 24020005 ....$.......$... + 0090 03e00008 24020004 03e00008 24020004 ....$.......$... + 00a0 03e00008 24020004 03e00008 24020003 ....$.......$... + 00b0 03e00008 00000000 03e00008 00000000 ................ + 00c0 3c010000 03e00008 c4200000 03e00008 <........ ...... + 00d0 00000000 03e00008 00000000 03e00008 ................ + 00e0 00000000 03e00008 00000000 00000000 ................ +Contents of section .rodata: + 0000 01000000 66756e63 31000000 02000000 ....func1....... + 0010 03000000 66756e63 34000000 00000004 ....func4....... + 0020 3dcccccd c0651234 c0651235 00000068 =....e.4.e.5...h + 0030 00000070 00000078 00000080 00000088 ...p...x........ + 0040 00000090 00000098 000000a0 3e4ccccd ............>L.. + 0050 00000008 00000000 00000000 00000000 ................ +Contents of section .options: + 0000 01200000 00000000 80004016 00000000 . ........@..... + 0010 00000051 00000000 00000000 00007ff0 ...Q............ + 0020 07100000 00000000 00000000 00000000 ................ + 0030 08100000 00000000 00000000 00000000 ................ +Contents of section .reginfo: + 0000 80004016 00000000 00000051 00000000 ..@........Q.... + 0010 00000000 00007ff0 ........ diff --git a/tools/asm-processor/tests/test3.c b/tools/asm-processor/tests/test3.c new file mode 100644 index 00000000..d74bb4cb --- /dev/null +++ b/tools/asm-processor/tests/test3.c @@ -0,0 +1,70 @@ + +GLOBAL_ASM( +.rdata +.word 321321 +.text +glabel test +/* 000090 00400090 27BDFFF8 */ addiu $sp, $sp, -24 +/* 000094 00400094 18A00009 */ blez $a1, .L004000BC +/* 000098 00400098 AFA00004 */ sw $zero, 4($sp) +.L0040009C: +/* 00009C 0040009C 8FAE0004 */ lw $t6, 4($sp) +/* 0000A0 004000A0 008E7821 */ addu $t7, $a0, $t6 +/* 0000A4 004000A4 A1E00000 */ sb $zero, ($t7) +/* 0000A8 004000A8 8FB80004 */ lw $t8, 4($sp) +/* 0000AC 004000AC 27190001 */ addiu $t9, $t8, 1 +/* 0000B0 004000B0 0325082A */ slt $at, $t9, $a1 +/* 0000B4 004000B4 1420FFF9 */ bnez $at, .L0040009C +/* 0000B8 004000B8 AFB90004 */ sw $t9, 4($sp) +.L004000BC: +/* 0000BC 004000BC 10000001 */ b .L004000C4 +/* 0000C0 004000C0 00000000 */ nop +.L004000C4: +/* 0000C4 004000C4 03E00008 */ jr $ra +/* 0000C8 004000C8 27BD0008 */ addiu $sp, $sp, 24 +) + +// static -> no symbols +// bss +char globalBuf[4]; +const char constBuf[4]; + +// data +char globalBufInit[4] = {1}; + +// rodata +const char constBufInit[4] = {1}; +const char constBufInit2[1] = {2}; +const char constBufInit3[1] = {3}; + +unsigned g(void); +unsigned f(void) { + // aligns to 4 or 8 byte boundary (char -> 4, double -> 8) + double x = 5.1; + float y = 5.2f; + float z = 5.3f; + "Hello "; + "World"; + return g(); +} + +GLOBAL_ASM( +.rdata +.word 123123 +.text +glabel g +/* 0000C0 004000C0 27BDFFE8 */ addiu $sp, $sp, -0x18 +/* 0000C4 004000C4 AFBF0014 */ sw $ra, 0x14($sp) +/* 0000C8 004000C8 240E0004 */ addiu $t6, $zero, 4 +/* 0000CC 004000CC 3C010041 */ lui $at, %hi(D_410100) +/* 0000D0 004000D0 AC2E0100 */ sw $t6, %lo(D_410100)($at) +/* 0000D4 004000D4 0C10002C */ jal func_004000B0 +/* 0000D8 004000D8 00000000 */ nop +/* 0000DC 004000DC 10000001 */ b .L004000E4 +/* 0000E0 004000E0 00000000 */ nop +.L004000E4: +/* 0000E4 004000E4 8FBF0014 */ lw $ra, 0x14($sp) +/* 0000E8 004000E8 27BD0018 */ addiu $sp, $sp, 0x18 +/* 0000EC 004000EC 03E00008 */ jr $ra +/* 0000F0 004000F0 00000000 */ nop +) diff --git a/tools/asm-processor/tests/test3.objdump b/tools/asm-processor/tests/test3.objdump new file mode 100644 index 00000000..bfa7f6e3 --- /dev/null +++ b/tools/asm-processor/tests/test3.objdump @@ -0,0 +1,64 @@ + +tests/test3.o: file format elf32-tradbigmips + +SYMBOL TABLE: +00000000 l d .text 000000d0 .text +00000000 l d .rodata 00000040 .rodata +00000000 l d .data 00000010 .data +00000000 l d .bss 00000010 .bss +00000000 g O .bss 00000004 globalBuf +00000004 g O .bss 00000004 constBuf +00000000 g O .data 00000004 globalBufInit +00000004 g O .rodata 00000004 constBufInit +00000008 g O .rodata 00000001 constBufInit2 +0000000c g O .rodata 00000001 constBufInit3 +0000003c g F .text 00000054 f +00000000 g F .text 00000004 test +00000090 g F .text 00000004 g +00000000 *UND* 00000000 D_410100 +00000000 *UND* 00000000 func_004000B0 + + +RELOCATION RECORDS FOR [.text]: +OFFSET TYPE VALUE +00000044 R_MIPS_HI16 .rodata +00000048 R_MIPS_LO16 .rodata +00000050 R_MIPS_HI16 .rodata +00000054 R_MIPS_LO16 .rodata +0000005c R_MIPS_HI16 .rodata +00000060 R_MIPS_LO16 .rodata +00000068 R_MIPS_26 g +0000009c R_MIPS_HI16 D_410100 +000000a0 R_MIPS_LO16 D_410100 +000000a4 R_MIPS_26 func_004000B0 + + +Contents of section .text: + 0000 27bdffe8 18a00009 afa00004 8fae0004 '............... + 0010 008e7821 a1e00000 8fb80004 27190001 ..x!........'... + 0020 0325082a 1420fff9 afb90004 10000001 .%.*. .......... + 0030 00000000 03e00008 27bd0018 27bdffd8 ........'...'... + 0040 afbf0014 3c010000 d4240028 f7a40020 ....<....$.(... + 0050 3c010000 c4260030 e7a6001c 3c010000 <....&.0....<... + 0060 c4280034 e7a80018 0c000000 00000000 .(.4............ + 0070 10000003 00000000 10000001 00000000 ................ + 0080 8fbf0014 27bd0028 03e00008 00000000 ....'..(........ + 0090 27bdffe8 afbf0014 240e0004 3c010000 '.......$...<... + 00a0 ac2e0000 0c000000 00000000 10000001 ................ + 00b0 00000000 8fbf0014 27bd0018 03e00008 ........'....... + 00c0 00000000 00000000 00000000 00000000 ................ +Contents of section .rodata: + 0000 0004e729 01000000 02000000 03000000 ...)............ + 0010 48656c6c 6f202000 576f726c 64000000 Hello .World... + 0020 0001e0f3 00000000 40146666 66666666 ........@.ffffff + 0030 40a66666 40a9999a 00000000 00000000 @.ff@........... +Contents of section .data: + 0000 01000000 00000000 00000000 00000000 ................ +Contents of section .options: + 0000 01200000 00000000 a0000002 00000000 . .............. + 0010 00000170 00000000 00000000 00007ff0 ...p............ + 0020 07100000 00000000 00000000 00000000 ................ + 0030 08100000 00000000 00000000 00000000 ................ +Contents of section .reginfo: + 0000 a300c032 00000000 00000170 00000000 ...2.......p.... + 0010 00000000 00007ff0 ........ diff --git a/tools/asm_processor/build.py b/tools/asm_processor/build.py deleted file mode 100644 index 228dcb03..00000000 --- a/tools/asm_processor/build.py +++ /dev/null @@ -1,36 +0,0 @@ -#!/usr/bin/env python3 -import sys -import os -import shlex -import subprocess -import tempfile - -dir_path = os.path.dirname(os.path.realpath(__file__)) -asm_processor = ['python3', os.path.join(dir_path, "asm-processor.py")] -prelude = os.path.join(dir_path, "prelude.inc") - -all_args = sys.argv[1:] -sep1 = all_args.index('--') -sep2 = all_args.index('--', sep1+1) - -compiler = all_args[:sep1] - -assembler = all_args[sep1+1:sep2] -assembler_sh = ' '.join(shlex.quote(x) for x in assembler) - -compile_args = all_args[sep2+1:] -in_file = compile_args[-1] -out_ind = compile_args.index('-o') -out_file = compile_args[out_ind + 1] -del compile_args[-1] -del compile_args[out_ind + 1] -del compile_args[out_ind] - -in_dir = os.path.split(os.path.realpath(in_file))[0] -opt_flags = [x for x in compile_args if x in ['-g', '-O2', '-O1', '-framepointer']] - -preprocessed_file = tempfile.NamedTemporaryFile(prefix='preprocessed', suffix='.c') - -subprocess.check_call(asm_processor + opt_flags + [in_file], stdout=preprocessed_file) -subprocess.check_call(compiler + compile_args + ['-I', in_dir, '-o', out_file, preprocessed_file.name]) -subprocess.check_call(asm_processor + opt_flags + [in_file, '--post-process', out_file, '--assembler', assembler_sh, '--asm-prelude', prelude]) diff --git a/tools/asm_processor/prelude.inc b/tools/asm_processor/prelude.inc deleted file mode 100644 index 0c111a2a..00000000 --- a/tools/asm_processor/prelude.inc +++ /dev/null @@ -1,5 +0,0 @@ -.set noat -.set noreorder -.set gp=64 -.include "macros.inc" - diff --git a/tools/assemble_sound.py b/tools/assemble_sound.py index f4a81d26..46406b16 100755 --- a/tools/assemble_sound.py +++ b/tools/assemble_sound.py @@ -944,7 +944,7 @@ def main(): args.append(a) defines_set = {d.split("=")[0] for d in defines} - is_shindou = "VERSION_SH" in defines_set + is_shindou = ("VERSION_SH" in defines_set or "VERSION_CN" in defines_set) if sequences_out_file is not None and not need_help: write_sequences( diff --git a/tools/create_patch.sh b/tools/create_patch.sh index ea75d9cc..689f11dd 100755 --- a/tools/create_patch.sh +++ b/tools/create_patch.sh @@ -21,5 +21,5 @@ fi git add . # Generate the patch. git diff -p --staged > "$1" -# Undo the 'git add'. +# Undo the 'git add'. git reset diff --git a/tools/gen_asset_list.cpp b/tools/gen_asset_list.cpp index 050bd118..d0d1b5de 100644 --- a/tools/gen_asset_list.cpp +++ b/tools/gen_asset_list.cpp @@ -23,7 +23,7 @@ using namespace std; const char* OUTPUT_FILE = "assets.json"; const size_t CHUNK_SIZE = 16; -const vector LANGS = {"jp", "us", "eu", "sh"}; +const vector LANGS = {"jp", "us", "eu", "sh", "cn"}; typedef uint8_t u8; typedef uint64_t u64; diff --git a/tools/ido-static-recomp/.clang-format b/tools/ido-static-recomp/.clang-format new file mode 100644 index 00000000..c7b900f0 --- /dev/null +++ b/tools/ido-static-recomp/.clang-format @@ -0,0 +1,23 @@ +IndentWidth: 4 +Language: Cpp +UseTab: Never +ColumnLimit: 120 +PointerAlignment: Left +BreakBeforeBraces: Attach +SpaceAfterCStyleCast: false +Cpp11BracedListStyle: false +IndentCaseLabels: true +BinPackArguments: true +BinPackParameters: true +AlignAfterOpenBracket: Align +AlignOperands: true +BreakBeforeTernaryOperators: true +BreakBeforeBinaryOperators: None +AllowShortBlocksOnASingleLine: true +AllowShortIfStatementsOnASingleLine: false +AllowShortLoopsOnASingleLine: false +AllowShortCaseLabelsOnASingleLine: false +AllowShortFunctionsOnASingleLine: false +AlignEscapedNewlines: Left +AlignTrailingComments: true +SortIncludes: false diff --git a/tools/ido-static-recomp/.gitignore b/tools/ido-static-recomp/.gitignore new file mode 100644 index 00000000..e36efc8d --- /dev/null +++ b/tools/ido-static-recomp/.gitignore @@ -0,0 +1,10 @@ +.idea/ +build/ +.vscode/ + +qemu-irix + +ctx.c.m2c +*.s + +.DS_Store diff --git a/tools/ido-static-recomp/DOCS.md b/tools/ido-static-recomp/DOCS.md new file mode 100644 index 00000000..1953751c --- /dev/null +++ b/tools/ido-static-recomp/DOCS.md @@ -0,0 +1,19 @@ +# Custom Functionality + +## Redirection +IDO recomp currently has two forms of path redirection, both involving the `/usr` folder. + +### `/usr/lib` +In order for users to not having to worry about installing the binaries in particular locations in `/usr/lib`, recomp automatically redirects `/usr/lib/` paths. This is done by determining the location of `cc` and redirecting to the same directory. This does mean all the binaries and `err.english.cc` are expected to be a part of a single flattened directory. + +It is also possible to override the auto redirect by using the environment variable `USR_LIB` with the desired redirection path. This can be used if the binaries are not in a flattened directory with `cc` or if on Linux and are unable to read `/proc/self/exe`. + +Wrapper functions implementing this redirection: +* `init_file` +* `wrapper_execvp` + +### /usr/include +The other form of redirection is completely optional and is done by setting the environment variable `USR_INCLUDE` to the desired redirection path. This will than redirect all opened files files there. This is done so that the `mdebug` section file paths will still use `/usr/include` path, but the files themselves can be located elsewhere for greater flexibility. + +Wrapper functions implementing this redirection: +* `wrapper_open` diff --git a/tools/ido-static-recomp/Makefile b/tools/ido-static-recomp/Makefile new file mode 100644 index 00000000..69a50d16 --- /dev/null +++ b/tools/ido-static-recomp/Makefile @@ -0,0 +1,231 @@ +# Build options can be changed by modifying the makefile or by building with 'make SETTING=value'. +# It is also possible to override the settings in Defaults in a file called .make_options as 'SETTING=value'. + +-include .make_options + +#### Defaults #### + +# if WERROR is 1, pass -Werror to CC, so warnings would be treated as errors +WERROR ?= 0 +# if RELEASE is 1 strip binaries as well as enable optimizations +RELEASE ?= 1 +# On Mac, set this to `universal` to build universal (x86+ARM) binaries +TARGET ?= native +# Set to 1 to build with sanitization enabled +# N.B. cannot be used for `make setup` at the moment due to recomp.cpp not respecting it +ASAN ?= 0 + +# IDO 5.3 only for Super Mario 64 +IDO_VERSION := IDO53 +IDO_TC := cc acpp as0 as1 cfe copt ugen ujoin uld umerge uopt usplit + + +# -- determine the host environment and target +# | Host | Targets | +# |-------|-------------------| +# | macOS | native, universal | +# | linux | native | +# | win | native | + +UNAME_S := $(shell uname -s) +UNAME_P := $(shell uname -p) + +MAKE := make +ifeq ($(OS),Windows_NT) + DETECTED_OS := windows +else ifeq ($(UNAME_S),Linux) + DETECTED_OS := linux +else ifeq ($(UNAME_S),Darwin) + DETECTED_OS := macos + MAKE := gmake + CPPFLAGS += -xc++ +else + $(error Unsupported host OS for Makefile) +endif + +RABBITIZER := tools/rabbitizer +RABBITIZER_LIB := $(RABBITIZER)/build/librabbitizerpp.a + +CC := gcc +CXX := g++ +STRIP := strip + +CSTD ?= -std=c11 +CFLAGS ?= -MMD -fno-strict-aliasing -I. +CXXSTD ?= -std=c++17 +CXXFLAGS ?= -MMD +WARNINGS ?= -Wall -Wextra +LDFLAGS ?= -lm +RECOMP_FLAGS ?= + +ifneq ($(WERROR),0) + WARNINGS += -Werror +endif + +ifeq ($(RELEASE),1) + OPTFLAGS ?= -Os +else + OPTFLAGS ?= -Og -g3 + STRIP := @: +endif + +ifneq ($(ASAN),0) + CFLAGS += -fsanitize=address -fsanitize=pointer-compare -fsanitize=pointer-subtract -fsanitize=undefined -fno-sanitize-recover=all + CXXFLAGS += -fsanitize=address -fsanitize=pointer-compare -fsanitize=pointer-subtract -fsanitize=undefined -fno-sanitize-recover=all +endif + + +ifeq ($(DETECTED_OS),windows) + CXXFLAGS += -static +endif + +# -- Build Directories +# designed to work with Make 3.81 (macOS/last GPL-2 version) +# https://ismail.badawi.io/blog/automatic-directory-creation-in-make/ +BUILD_BASE ?= build +BUILD_DIR := $(BUILD_BASE) +BUILT_BIN := $(BUILD_DIR)/out + + +# -- Location of original IDO binaries in SM64 repo +IRIX_USR_DIR ?= ../ido5.3_compiler/usr + +# -- Location of the irix tool chain error messages +ERR_STRS := $(BUILT_BIN)/err.english.cc + +RECOMP_ELF := $(BUILD_BASE)/recomp.elf +LIBC_IMPL_O := libc_impl.o + +TARGET_BINARIES := $(foreach binary,$(IDO_TC),$(BUILT_BIN)/$(binary)) +O_FILES := $(foreach binary,$(IDO_TC),$(BUILD_DIR)/$(binary).o) +C_FILES := $(O_FILES:.o=.c) + +# Automatic dependency files +DEP_FILES := $(O_FILES:.o=.d) + +# create build directories +$(shell mkdir -p $(BUILT_BIN)) + +# per-file flags +# 5.3 ugen relies on UB stack reads +# to emulate, pass the conservative flag to `recomp` +$(BUILD_BASE)/ugen.c: RECOMP_FLAGS := --conservative + +$(RECOMP_ELF): CXXFLAGS += -I$(RABBITIZER)/include -I$(RABBITIZER)/cplusplus/include +$(RECOMP_ELF): LDFLAGS += -L$(RABBITIZER)/build -lrabbitizerpp + +ifneq ($(DETECTED_OS),windows) +# For traceback +$(RECOMP_ELF): LDFLAGS += -ldl +endif +ifeq ($(DETECTED_OS),linux) +# For traceback +$(RECOMP_ELF): LDFLAGS += -Wl,-export-dynamic +endif + +# Too many warnings, disable everything for now... +$(RECOMP_ELF): WARNINGS += -Wpedantic -Wno-shadow -Wno-unused-variable -Wno-unused-but-set-variable -Wno-unused-parameter -Wno-implicit-fallthrough +%/$(LIBC_IMPL_O): CFLAGS += -D$(IDO_VERSION) +# TODO: fix warnings +%/$(LIBC_IMPL_O): WARNINGS += -Wno-unused-parameter -Wno-unused-variable -Wno-unused-but-set-variable -Wno-sign-compare -Wno-deprecated-declarations + +#### Main Targets ### + +all: $(TARGET_BINARIES) $(ERR_STRS) + +setup: + $(MAKE) -C $(RABBITIZER) static CC=$(CC) CXX=$(CXX) DEBUG=$(DEBUG) + $(MAKE) $(RECOMP_ELF) + +clean: + $(RM) -r $(BUILD_DIR) + +distclean: + $(RM) -r $(BUILD_BASE) + $(MAKE) -C $(RABBITIZER) distclean + +c_files: $(C_FILES) + + +.PHONY: all clean distclean setup +.DEFAULT_GOAL := all +# Prevent removing intermediate files +.SECONDARY: + + +#### Various Recipes #### + +$(BUILD_BASE)/%.elf: %.cpp + $(CXX) $(CXXSTD) $(OPTFLAGS) $(CXXFLAGS) $(WARNINGS) -o $@ $^ $(LDFLAGS) + + +$(BUILD_DIR)/%.c: $(IRIX_USR_DIR)/lib/% + $(RECOMP_ELF) $(RECOMP_FLAGS) $< > $@ || ($(RM) -f $@ && false) + +# cc and strip are special and are stored in the `bin` folder instead of the `lib` one +$(BUILD_DIR)/%.c: $(IRIX_USR_DIR)/bin/% + $(RECOMP_ELF) $(RECOMP_FLAGS) $< > $@ || ($(RM) -f $@ && false) + + +$(BUILT_BIN)/%.cc: $(IRIX_USR_DIR)/lib/%.cc + cp $^ $@ + + +ifeq ($(TARGET),universal) +MACOS_FAT_TARGETS ?= arm64-apple-macos11 x86_64-apple-macos10.14 + +FAT_FOLDERS := $(foreach target,$(MACOS_FAT_TARGETS),$(BUILD_DIR)/$(target)) + +# create build directories +$(shell mkdir -p $(FAT_FOLDERS)) + +# TODO: simplify +FAT_BINARIES := $(foreach binary,$(IDO_TC),$(BUILT_BIN)/arm64-apple-macos11/$(binary)) \ + $(foreach binary,$(IDO_TC),$(BUILT_BIN)/x86_64-apple-macos10.14/$(binary)) + +$(BUILT_BIN)/%: $(BUILD_DIR)/arm64-apple-macos11/% $(BUILD_DIR)/x86_64-apple-macos10.14/% | $(ERR_STRS) + lipo -create -output $@ $^ + + +$(BUILD_DIR)/arm64-apple-macos11/%: $(BUILD_DIR)/arm64-apple-macos11/%.o $(BUILD_DIR)/arm64-apple-macos11/$(LIBC_IMPL_O) | $(ERR_STRS) + $(CC) $(CSTD) $(OPTFLAGS) $(CFLAGS) -target arm64-apple-macos11 -o $@ $^ $(LDFLAGS) + $(STRIP) $@ + +$(BUILD_DIR)/x86_64-apple-macos10.14/%: $(BUILD_DIR)/x86_64-apple-macos10.14/%.o $(BUILD_DIR)/x86_64-apple-macos10.14/$(LIBC_IMPL_O) | $(ERR_STRS) + $(CC) $(CSTD) $(OPTFLAGS) $(CFLAGS) -target x86_64-apple-macos10.14 -o $@ $^ $(LDFLAGS) + $(STRIP) $@ + +$(BUILD_DIR)/arm64-apple-macos11/%.o: $(BUILD_DIR)/%.c + $(CC) -c $(CSTD) $(OPTFLAGS) $(CFLAGS) -target arm64-apple-macos11 -o $@ $< + +$(BUILD_DIR)/x86_64-apple-macos10.14/%.o: $(BUILD_DIR)/%.c + $(CC) -c $(CSTD) $(OPTFLAGS) $(CFLAGS) -target x86_64-apple-macos10.14 -o $@ $< + + +$(BUILD_DIR)/arm64-apple-macos11/$(LIBC_IMPL_O): libc_impl.c + $(CC) -c $(CSTD) $(OPTFLAGS) $(CFLAGS) $(WARNINGS) -target arm64-apple-macos11 -o $@ $< + +$(BUILD_DIR)/x86_64-apple-macos10.14/$(LIBC_IMPL_O): libc_impl.c + $(CC) -c $(CSTD) $(OPTFLAGS) $(CFLAGS) $(WARNINGS) -target x86_64-apple-macos10.14 -o $@ $< + +else +$(BUILT_BIN)/%: $(BUILD_DIR)/%.o $(BUILD_DIR)/$(LIBC_IMPL_O) | $(ERR_STRS) + $(CC) $(CSTD) $(OPTFLAGS) $(CFLAGS) -o $@ $^ $(LDFLAGS) + $(STRIP) $@ + +$(BUILD_DIR)/%.o: $(BUILD_DIR)/%.c + $(CC) -c $(CSTD) $(OPTFLAGS) $(CFLAGS) -o $@ $< + + +$(BUILD_DIR)/$(LIBC_IMPL_O): libc_impl.c + $(CC) -c $(CSTD) $(OPTFLAGS) $(CFLAGS) $(WARNINGS) -o $@ $< +endif + +# Remove built-in rules, to improve performance +MAKEFLAGS += --no-builtin-rules + +-include $(DEP_FILES) + +# --- Debugging +# run `make print-VARIABLE` to debug that variable +print-% : ; $(info $* is a $(flavor $*) variable set to [$($*)]) @true diff --git a/tools/ido-static-recomp/README.md b/tools/ido-static-recomp/README.md new file mode 100644 index 00000000..83ae760f --- /dev/null +++ b/tools/ido-static-recomp/README.md @@ -0,0 +1,66 @@ +# Static Recompilation of IRIX Programs + +Convert selected IRIX C toolchain programs into modern Linux or macOS programs + +## Supported Programs + +* IDO 5.3 + * cc, acpp, as0, as1, cfe, copt, ugen, ujoin, uld, umerge, uopt, usplit, ld, strip, upas +* IDO 7.1 + * cc, acpp, as0, as1, cfe, ugen, ujoin, uld, umerge, uopt, usplit, upas + +## Dependencies + +### Linux (Debian / Ubuntu) + +```bash +sudo apt-get install build-essential +``` + +### macOS + +[Install homebrew](https://brew.sh/) and then: + +```bash +brew install make +``` + +## Building + +First build the recomp binary itself + +```bash +make setup +``` + +```bash +make VERSION=5.3 +make VERSION=7.1 +``` + +The build artifacts are located in `build/{7.1|5.3}/out`. Add `-j{thread num}` for multithreaded building. + +By default, debug builds are created with less optimizations, debug flags, and unstripped binaries. +Add `RELEASE=1` to build release builds with optimizations and stripped binaries. + +### Creating Universal ARM/x86_64 macOS Builds + +By default, make build script create native binaries on macOS. This was done to minimize the time to build the recompiled suite. +In order to create "fat," universal ARM and x86_64, pass `TARGET=universal` to `gmake`. + +### Manual Building + +Example for compiling `as1` in a Linux environment: + +```bash +make -C tools/rabbitizer +g++ -Itools/rabbitizer/include -Itools/rabbitizer/cplusplus/include recomp.cpp -o recomp.elf -g -Ltools/rabbitizer/build -lrabbitizerpp +./recomp.elf ido/7.1/usr/lib/as1 > as1_c.c +gcc libc_impl.c as1_c.c -o as1 -g -fno-strict-aliasing -lm -DIDO71 +``` + +Use the same approach for `cc`, `cfe`, `uopt`, `ugen`, `as1` (and `copt` if you need that). + +Use `-DIDO53` instead of `-DIDO71` if the program you are trying to recompile was compiled with IDO 5.3 rather than IDO 7.1. + +To compile `ugen` for IDO 5.3, add `--conservative` when invoking `./recomp.elf`. This mimics UB present in `ugen53`. That program reads uninitialized stack memory and its result depends on that stack memory. diff --git a/tools/ido5.3_recomp/elf.h b/tools/ido-static-recomp/elf.h similarity index 100% rename from tools/ido5.3_recomp/elf.h rename to tools/ido-static-recomp/elf.h diff --git a/tools/ido5.3_recomp/header.h b/tools/ido-static-recomp/header.h similarity index 91% rename from tools/ido5.3_recomp/header.h rename to tools/ido-static-recomp/header.h index b4cd0d31..0a72f1ab 100644 --- a/tools/ido5.3_recomp/header.h +++ b/tools/ido-static-recomp/header.h @@ -13,12 +13,6 @@ #define RM_RP 2 #define RM_RM 3 -union FloatReg { - float f[2]; - uint32_t w[2]; - double d; -}; - #define cvt_w_d(f) \ ((fcsr & RM_RZ) ? ((isnan(f) || f <= -2147483649.0 || f >= 2147483648.0) ? (fcsr |= 0x40, 2147483647) : (int)f) : (assert(0), 0)) diff --git a/tools/ido5.3_recomp/helpers.h b/tools/ido-static-recomp/helpers.h similarity index 79% rename from tools/ido5.3_recomp/helpers.h rename to tools/ido-static-recomp/helpers.h index b2bd2351..9e031e0f 100644 --- a/tools/ido5.3_recomp/helpers.h +++ b/tools/ido-static-recomp/helpers.h @@ -3,6 +3,8 @@ #include +#define MEM_F64(a) (double_from_memory(mem, a)) +#define MEM_F32(a) (*(float *)(mem + a)) #define MEM_U32(a) (*(uint32_t *)(mem + a)) #define MEM_S32(a) (*(int32_t *)(mem + a)) #define MEM_U16(a) (*(uint16_t *)(mem + ((a) ^ 2))) diff --git a/tools/ido5.3_recomp/libc_impl.c b/tools/ido-static-recomp/libc_impl.c similarity index 60% rename from tools/ido5.3_recomp/libc_impl.c rename to tools/ido-static-recomp/libc_impl.c index af4ca713..a6a11b96 100644 --- a/tools/ido5.3_recomp/libc_impl.c +++ b/tools/ido-static-recomp/libc_impl.c @@ -16,8 +16,10 @@ #ifdef __CYGWIN__ #include #endif + #ifdef __APPLE__ - #include +#include +#include #endif #include @@ -33,17 +35,19 @@ #include "libc_impl.h" #include "helpers.h" +#include "header.h" #define MIN(a, b) ((a) < (b) ? (a) : (b)) #define MAX(a, b) ((a) > (b) ? (a) : (b)) -#define STRING(param) size_t param##_len = wrapper_strlen(mem, param##_addr); \ - char param[param##_len + 1]; \ - for (size_t i = 0; i <= param##_len; i++) { \ - param[i] = MEM_S8(param##_addr + i); \ +#define STRING(param) \ + size_t param##_len = wrapper_strlen(mem, param##_addr); \ + char param[param##_len + 1]; \ + for (size_t i = 0; i <= param##_len; i++) { \ + param[i] = MEM_S8(param##_addr + i); \ } -#if !defined(IDO53) && !defined(IDO71) +#if !defined(IDO53) && !defined(IDO71) && !defined(IDO72) #define IDO71 #endif @@ -68,12 +72,21 @@ #define LIBC_SIZE 0x3000 #endif +#ifdef IDO72 +// IDO 7.2 +#define IOB_ADDR 0x0fb49454 +#define ERRNO_ADDR 0x0fb49290 +#define CTYPE_ADDR 0x0fb46db0 +#define LIBC_ADDR 0x0fb46000 +#define LIBC_SIZE 0x4000 +#endif + #define STDIN_ADDR IOB_ADDR #define STDOUT_ADDR (IOB_ADDR + 0x10) #define STDERR_ADDR (IOB_ADDR + 0x20) -#define STDIN ((struct FILE_irix *)&MEM_U32(STDIN_ADDR)) -#define STDOUT ((struct FILE_irix *)&MEM_U32(STDOUT_ADDR)) -#define STDERR ((struct FILE_irix *)&MEM_U32(STDERR_ADDR)) +#define STDIN ((struct FILE_irix*)&MEM_U32(STDIN_ADDR)) +#define STDOUT ((struct FILE_irix*)&MEM_U32(STDOUT_ADDR)) +#define STDERR ((struct FILE_irix*)&MEM_U32(STDERR_ADDR)) #define MALLOC_BINS_ADDR custom_libc_data_addr #define STRTOK_DATA_ADDR (MALLOC_BINS_ADDR + (30 - 3) * 4) @@ -89,9 +102,9 @@ #define IOEOF 0020 /* EOF reached on read */ #define IOERR 0040 /* I/O error from system */ -#define IOREAD 0001 /* currently reading */ -#define IOWRT 0002 /* currently writing */ -#define IORW 0200 /* opened for reading and writing */ +#define IOREAD 0001 /* currently reading */ +#define IOWRT 0002 /* currently writing */ +#define IORW 0200 /* opened for reading and writing */ #define IOMYBUF 0010 /* stdio malloc()'d buffer */ #define STDIO_BUFSIZE 16384 @@ -110,10 +123,13 @@ struct FILE_irix { uint8_t _flag; }; +typedef uint64_t (*fptr_trampoline)(uint8_t* mem, uint32_t sp, uint32_t a0, uint32_t a1, uint32_t a2, uint32_t a3, + uint32_t fp_dest); + static struct { struct { - uint64_t (*trampoline)(uint8_t *mem, uint32_t sp, uint32_t a0, uint32_t a1, uint32_t a2, uint32_t a3, uint32_t fp_dest); - uint8_t *mem; + fptr_trampoline trampoline; + uint8_t* mem; uint32_t fp_dest; } handlers[65]; volatile uint32_t recursion_level; @@ -132,102 +148,123 @@ static uint32_t custom_libc_data_addr; #define _B 0100 /* Blank */ #define _X 0200 /* heXadecimal digit */ -static char ctype[] = { 0, - -/* 0 1 2 3 4 5 6 7 */ - -/* 0*/ _C, _C, _C, _C, _C, _C, _C, _C, -/* 10*/ _C, _S|_C, _S|_C, _S|_C, _S|_C, _S|_C, _C, _C, -/* 20*/ _C, _C, _C, _C, _C, _C, _C, _C, -/* 30*/ _C, _C, _C, _C, _C, _C, _C, _C, -/* 40*/ _S|_B, _P, _P, _P, _P, _P, _P, _P, -/* 50*/ _P, _P, _P, _P, _P, _P, _P, _P, -/* 60*/ _N|_X, _N|_X, _N|_X, _N|_X, _N|_X, _N|_X, _N|_X, _N|_X, -/* 70*/ _N|_X, _N|_X, _P, _P, _P, _P, _P, _P, -/*100*/ _P, _U|_X, _U|_X, _U|_X, _U|_X, _U|_X, _U|_X, _U, -/*110*/ _U, _U, _U, _U, _U, _U, _U, _U, -/*120*/ _U, _U, _U, _U, _U, _U, _U, _U, -/*130*/ _U, _U, _U, _P, _P, _P, _P, _P, -/*140*/ _P, _L|_X, _L|_X, _L|_X, _L|_X, _L|_X, _L|_X, _L, -/*150*/ _L, _L, _L, _L, _L, _L, _L, _L, -/*160*/ _L, _L, _L, _L, _L, _L, _L, _L, -/*170*/ _L, _L, _L, _P, _P, _P, _P, _C, -/*200*/ 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0 +static char ctype[] = { + 0, + // clang-format off +/* 00 01 02 03 04 05 06 07 */ +/* 0 */ _C, _C, _C, _C, _C, _C, _C, _C, +/* 010 */ _C, _S|_C, _S|_C, _S|_C, _S|_C, _S|_C, _C, _C, +/* 020 */ _C, _C, _C, _C, _C, _C, _C, _C, +/* 030 */ _C, _C, _C, _C, _C, _C, _C, _C, +/* 040 */ _S|_B, _P, _P, _P, _P, _P, _P, _P, +/* 050 */ _P, _P, _P, _P, _P, _P, _P, _P, +/* 060 */ _N|_X, _N|_X, _N|_X, _N|_X, _N|_X, _N|_X, _N|_X, _N|_X, +/* 070 */ _N|_X, _N|_X, _P, _P, _P, _P, _P, _P, +/* 0100 */ _P, _U|_X, _U|_X, _U|_X, _U|_X, _U|_X, _U|_X, _U, +/* 0110 */ _U, _U, _U, _U, _U, _U, _U, _U, +/* 0120 */ _U, _U, _U, _U, _U, _U, _U, _U, +/* 0130 */ _U, _U, _U, _P, _P, _P, _P, _P, +/* 0140 */ _P, _L|_X, _L|_X, _L|_X, _L|_X, _L|_X, _L|_X, _L, +/* 0150 */ _L, _L, _L, _L, _L, _L, _L, _L, +/* 0160 */ _L, _L, _L, _L, _L, _L, _L, _L, +/* 0170 */ _L, _L, _L, _P, _P, _P, _P, _C, +/* 0200 */ 0, 0, 0, 0, 0, 0, 0, 0, +/* 0210 */ 0, 0, 0, 0, 0, 0, 0, 0, +/* 0220 */ 0, 0, 0, 0, 0, 0, 0, 0, +/* 0230 */ 0, 0, 0, 0, 0, 0, 0, 0, +/* 0240 */ 0, 0, 0, 0, 0, 0, 0, 0, +/* 0250 */ 0, 0, 0, 0, 0, 0, 0, 0, +/* 0260 */ 0, 0, 0, 0, 0, 0, 0, 0, +/* 0270 */ 0, 0, 0, 0, 0, 0, 0, 0, +/* 0300 */ 0, 0, 0, 0, 0, 0, 0, 0, +/* 0310 */ 0, 0, 0, 0, 0, 0, 0, 0, +/* 0320 */ 0, 0, 0, 0, 0, 0, 0, 0, +/* 0330 */ 0, 0, 0, 0, 0, 0, 0, 0, +/* 0340 */ 0, 0, 0, 0, 0, 0, 0, 0, +/* 0350 */ 0, 0, 0, 0, 0, 0, 0, 0, +/* 0360 */ 0, 0, 0, 0, 0, 0, 0, 0, +/* 0370 */ 0, 0, 0, 0, 0, 0, 0, 0, + // clang-format on }; -#define REDIRECT_USR_LIB -#ifdef REDIRECT_USR_LIB -static char bin_dir[PATH_MAX + 1]; -#endif +static char usr_lib_redirect[PATH_MAX + 1]; +static char usr_include_redirect[PATH_MAX + 1]; + static int g_file_max = 3; -#if defined(__CYGWIN__) || defined(__APPLE__) + +/* Compilation Target/Emulation Host Page Size Determination */ +#if defined(__CYGWIN__) || (defined(__linux__) && defined(__aarch64__)) +#define RUNTIME_PAGESIZE +/* ARM64 linux can have page sizes of 4kb, 16kb, or 64kb */ +/* Set in main before running the translated code */ static size_t g_Pagesize; + +#define TRUNC_PAGE(x) ((x) & ~(g_Pagesize - 1)) +#define ROUND_PAGE(x) (TRUNC_PAGE((x) + (g_Pagesize - 1))) + +#elif defined(__APPLE__) +/* https://developer.apple.com/documentation/apple-silicon/addressing-architectural-differences-in-your-macos-code */ +#define TRUNC_PAGE(x) (trunc_page((x))) +#define ROUND_PAGE(x) (round_page((x))) + +#else +/* A fixed 4KB page size for x64 linux (is there anything else?) */ +#define TRUNC_PAGE(x) ((x) & ~(0x1000 - 1)) +#define ROUND_PAGE(x) (TRUNC_PAGE((x) + (0x1000 - 1))) +#endif /* PageSize Macros */ + +static uint8_t* memory_map(size_t length) { +#ifdef __CYGWIN__ + uint8_t* mem = mmap(0, length, PROT_NONE, MAP_PRIVATE | MAP_ANONYMOUS | MAP_NORESERVE, -1, 0); +#else + uint8_t* mem = mmap(0, length, PROT_NONE, MAP_PRIVATE | MAP_ANONYMOUS, -1, 0); #endif -static uint8_t *memory_map(size_t length) -{ -#if defined(__CYGWIN__) || defined(__APPLE__) - uint8_t *mem = mmap(0, length, PROT_NONE, MAP_PRIVATE | MAP_ANONYMOUS | MAP_NORESERVE, -1, 0); - g_Pagesize = sysconf(_SC_PAGESIZE); - assert(((uintptr_t)mem & (g_Pagesize-1)) == 0); -#else - uint8_t *mem = mmap(0, length, PROT_NONE, MAP_PRIVATE | MAP_ANONYMOUS, -1, 0); -#endif + assert(TRUNC_PAGE((uintptr_t)mem) == (uintptr_t)mem && + "Page size too small, try increasing `page_size` in recomp.cpp"); if (mem == MAP_FAILED) { - perror("mmap"); + perror("mmap (memory_map)"); exit(1); } return mem; } -static void memory_allocate(uint8_t *mem, uint32_t start, uint32_t end) -{ +static void memory_allocate(uint8_t* mem, uint32_t start, uint32_t end) { assert(start >= MEM_REGION_START); assert(end <= MEM_REGION_START + MEM_REGION_SIZE); -#if defined(__CYGWIN__) || defined(__APPLE__) - uintptr_t _start = ((uintptr_t)mem + start) & ~(g_Pagesize-1); - uintptr_t _end = ((uintptr_t)mem + end + (g_Pagesize-1)) & ~(g_Pagesize-1); + // `start` will be passed to mmap, + // so it has to be host aligned in order to keep the guest's pages valid + assert(start == TRUNC_PAGE(start) && "Page size too small, try increasing `page_size` in recomp.cpp"); +#ifdef __CYGWIN__ + uintptr_t _start = TRUNC_PAGE((uintptr_t)mem + start); + uintptr_t _end = ROUND_PAGE((uintptr_t)mem + end); - if(mprotect((void*)_start, _end - _start, PROT_READ | PROT_WRITE) < 0) { - perror("mprotect"); + if (mprotect((void*)_start, _end - _start, PROT_READ | PROT_WRITE) < 0) { + perror("mprotect (memory_allocate)"); exit(1); } #else - if (mmap(mem + start, end - start, PROT_READ | PROT_WRITE, MAP_FIXED | MAP_PRIVATE | MAP_ANONYMOUS, -1, 0) == MAP_FAILED) { - perror("mmap"); + void* addr = (void*)TRUNC_PAGE((uintptr_t)mem + start); + size_t len = end - start; + + if (mmap(addr, len, PROT_READ | PROT_WRITE, MAP_FIXED | MAP_PRIVATE | MAP_ANONYMOUS, -1, 0) == MAP_FAILED) { + perror("mmap (memory_allocate)"); exit(1); } -#endif +#endif /* __CYGWIN__ */ } -static void memory_unmap(uint8_t *mem, size_t length) -{ +static void memory_unmap(uint8_t* mem, size_t length) { if (munmap(mem, length)) { perror("munmap"); exit(1); } } - -static void free_all_file_bufs(uint8_t *mem) { - struct FILE_irix *f = (struct FILE_irix *)&MEM_U32(IOB_ADDR); +static void free_all_file_bufs(uint8_t* mem) { + struct FILE_irix* f = (struct FILE_irix*)&MEM_U32(IOB_ADDR); for (int i = 0; i < g_file_max; i++) { if (f[i]._flag & IOMYBUF) { wrapper_free(mem, f[i]._base_addr); @@ -235,10 +272,32 @@ static void free_all_file_bufs(uint8_t *mem) { } } -static void find_bin_dir(void) { -#ifdef REDIRECT_USR_LIB +void get_env_var(char* out, char* name) { + char* env = getenv(name); + + if (env == NULL) { // No environment variable found, so just return empty string + out[0] = '\0'; + return; + } + + if (snprintf(out, PATH_MAX, "%s", env) >= PATH_MAX) { + fprintf(stderr, "Error: Environment variable %s is too large\n", name); + exit(1); + } + +} + +static void init_usr_lib_redirect(void) { + char path[PATH_MAX + 1] = { 0 }; + + get_env_var(path, "USR_LIB"); + + if (path[0] != '\0') { + strcpy(usr_lib_redirect, path); + return; + } + // gets the current executable's path - char path[PATH_MAX + 1] = {0}; #ifdef __CYGWIN__ uint32_t size = GetModuleFileName(NULL, path, PATH_MAX); if (size == 0 || size == PATH_MAX) { @@ -256,34 +315,82 @@ static void find_bin_dir(void) { } #endif - strcpy(bin_dir, dirname(path)); -#endif + strcpy(usr_lib_redirect, dirname(path)); } -int main(int argc, char *argv[]) { - int ret; +static void init_usr_include_redirect(void) { + char path[PATH_MAX + 1] = {0}; - find_bin_dir(); + get_env_var(path, "USR_INCLUDE"); - uint8_t *mem = memory_map(MEM_REGION_SIZE); - mem -= MEM_REGION_START; - int run(uint8_t *mem, int argc, char *argv[]); - ret = run(mem, argc, argv); + strcpy(usr_include_redirect, path); +} + +static void init_redirect_paths(void) { + init_usr_lib_redirect(); + init_usr_include_redirect(); +} + +/** + * Redirects `path` by replacing the initial segment `from` by `to`. The result is placed in `out`. + * If `path` does not have `from` as its initial segment, or there is no `to`, the original path is used. + * If an error occurs, an error message will be printed, and the program exited. +*/ +void redirect_path(char* out, const char* path, const char* from, const char* to) { + int from_len = strlen(from); + + if(!strncmp(path, from, from_len) && (to[0] != '\0')) { + char redirected_path[PATH_MAX + 1] = {0}; + int n; + + n = snprintf(redirected_path, sizeof(redirected_path), "%s%s", to, path + from_len); + + if (n >= 0 && n < sizeof(redirected_path)) { + strcpy(out, redirected_path); + } else { + fprintf(stderr, "Error: Unable to redirect %s->%s for %s\n", from, to, path); + exit(1); + } + } else { + strcpy(out, path); + } +} + +void final_cleanup(uint8_t* mem) { wrapper_fflush(mem, 0); free_all_file_bufs(mem); mem += MEM_REGION_START; memory_unmap(mem, MEM_REGION_SIZE); +} + +int main(int argc, char* argv[]) { + int ret; + + init_redirect_paths(); +#ifdef RUNTIME_PAGESIZE + g_Pagesize = sysconf(_SC_PAGESIZE); +#endif /* RUNTIME_PAGESIZE */ + + uint8_t* mem = memory_map(MEM_REGION_SIZE); + mem -= MEM_REGION_START; + int run(uint8_t * mem, int argc, char* argv[]); + ret = run(mem, argc, argv); + final_cleanup(mem); return ret; } -void mmap_initial_data_range(uint8_t *mem, uint32_t start, uint32_t end) { +void mmap_initial_data_range(uint8_t* mem, uint32_t start, uint32_t end) { custom_libc_data_addr = end; +#ifdef __APPLE__ + end += vm_page_size; +#else end += 4096; +#endif /* __APPLE__ */ memory_allocate(mem, start, end); cur_sbrk = end; } -void setup_libc_data(uint8_t *mem) { +void setup_libc_data(uint8_t* mem) { memory_allocate(mem, LIBC_ADDR, (LIBC_ADDR + LIBC_SIZE)); for (size_t i = 0; i < sizeof(ctype); i++) { MEM_S8(CTYPE_ADDR + i) = ctype[i]; @@ -296,7 +403,7 @@ void setup_libc_data(uint8_t *mem) { STDERR->_file = 2; } -static uint32_t strcpy1(uint8_t *mem, uint32_t dest_addr, const char *str) { +static uint32_t strcpy1(uint8_t* mem, uint32_t dest_addr, const char* str) { for (;;) { char c = *str; ++str; @@ -308,7 +415,7 @@ static uint32_t strcpy1(uint8_t *mem, uint32_t dest_addr, const char *str) { } } -static uint32_t strcpy2(uint8_t *mem, uint32_t dest_addr, uint32_t src_addr) { +static uint32_t strcpy2(uint8_t* mem, uint32_t dest_addr, uint32_t src_addr) { for (;;) { char c = MEM_S8(src_addr); ++src_addr; @@ -320,48 +427,14 @@ static uint32_t strcpy2(uint8_t *mem, uint32_t dest_addr, uint32_t src_addr) { } } -uint32_t wrapper_sbrk(uint8_t *mem, int increment) { +uint32_t wrapper_sbrk(uint8_t* mem, int increment) { uint32_t old = cur_sbrk; - memory_allocate(mem, old, (old + increment)); - cur_sbrk += increment; + size_t alignedInc = ROUND_PAGE(old + increment) - old; + memory_allocate(mem, old, old + alignedInc); + cur_sbrk += alignedInc; return old; } -#if 0 -uint32_t wrapper_malloc(uint8_t *mem, uint32_t size) { - uint32_t orig_size = size; - size += 8; - size = (size + 0xfff) & ~0xfff; - uint32_t ret = wrapper_sbrk(mem, size); - MEM_U32(ret) = orig_size; - return ret + 8; -} - -uint32_t wrapper_calloc(uint8_t *mem, uint32_t num, uint32_t size) { - uint64_t new_size = (uint64_t)num * size; - assert(new_size == (uint32_t)new_size); - uint32_t ret = wrapper_malloc(mem, new_size); - return wrapper_memset(mem, ret, 0, new_size); -} - -uint32_t wrapper_realloc(uint8_t *mem, uint32_t data_addr, uint32_t size) { - if (data_addr == 0) { - return wrapper_malloc(mem, size); - } - uint32_t orig_size = MEM_U32(data_addr - 8); - if (size < orig_size || orig_size < 4088 && size < 4088) { - MEM_U32(data_addr - 8) = size; - return data_addr; - } - uint32_t new_addr = wrapper_malloc(mem, size); - return wrapper_memcpy(mem, new_addr, data_addr, MIN(size, orig_size)); -} - -void wrapper_free(uint8_t *mem, uint32_t data_addr) { - // NOP -} -#else - /* Simple bin-based malloc algorithm @@ -404,7 +477,7 @@ size_t mem_allocated; size_t max_mem_used; size_t num_sbrks; size_t num_allocs; -uint32_t wrapper_malloc(uint8_t *mem, uint32_t size) { +uint32_t wrapper_malloc(uint8_t* mem, uint32_t size) { int bin = -1; for (int i = 3; i < 30; i++) { if (size <= (1 << i)) { @@ -425,10 +498,10 @@ uint32_t wrapper_malloc(uint8_t *mem, uint32_t size) { uint32_t sbrk_request = 0x10000; if (8 + item_size > sbrk_request) { sbrk_request = 8 + item_size; - sbrk_request = (sbrk_request + 0xfff) & ~0xfff; + sbrk_request = ROUND_PAGE(sbrk_request); } uint32_t left_over = sbrk_request % (8 + item_size); - sbrk_request -= left_over & ~0xfff; + sbrk_request -= left_over & ~(4096 - 1); mem_allocated += sbrk_request; ++num_sbrks; node_ptr = wrapper_sbrk(mem, sbrk_request); @@ -450,14 +523,14 @@ uint32_t wrapper_malloc(uint8_t *mem, uint32_t size) { return node_ptr + 8; } -uint32_t wrapper_calloc(uint8_t *mem, uint32_t num, uint32_t size) { +uint32_t wrapper_calloc(uint8_t* mem, uint32_t num, uint32_t size) { uint64_t new_size = (uint64_t)num * size; assert(new_size == (uint32_t)new_size); uint32_t ret = wrapper_malloc(mem, new_size); return wrapper_memset(mem, ret, 0, new_size); } -uint32_t wrapper_realloc(uint8_t *mem, uint32_t data_addr, uint32_t size) { +uint32_t wrapper_realloc(uint8_t* mem, uint32_t data_addr, uint32_t size) { if (data_addr == 0) { return wrapper_malloc(mem, size); } else { @@ -480,10 +553,18 @@ uint32_t wrapper_realloc(uint8_t *mem, uint32_t data_addr, uint32_t size) { } } -void wrapper_free(uint8_t *mem, uint32_t data_addr) { +void wrapper_free(uint8_t* mem, uint32_t data_addr) { + if (data_addr == 0) { + return; + } uint32_t node_ptr = data_addr - 8; int bin = MEM_U32(node_ptr); uint32_t size = MEM_U32(node_ptr + 4); + if (size == 0) { + // Double free. IDO 5.3 strip relies on this. + fprintf(stderr, "warning: double free: 0x%x\n", data_addr); + return; + } uint32_t list_ptr = MALLOC_BINS_ADDR + (bin - 3) * 4; assert(bin >= 3 && bin < 30); assert(size <= (1 << bin)); @@ -492,10 +573,9 @@ void wrapper_free(uint8_t *mem, uint32_t data_addr) { MEM_U32(list_ptr) = node_ptr; mem_used -= size; } -#endif -int wrapper_fscanf(uint8_t *mem, uint32_t fp_addr, uint32_t format_addr, uint32_t sp) { - struct FILE_irix *f = (struct FILE_irix *)&MEM_U32(fp_addr); +int wrapper_fscanf(uint8_t* mem, uint32_t fp_addr, uint32_t format_addr, uint32_t sp) { + struct FILE_irix* f = (struct FILE_irix*)&MEM_U32(fp_addr); STRING(format) // for debug int ret = 0; @@ -517,12 +597,11 @@ int wrapper_fscanf(uint8_t *mem, uint32_t fp_addr, uint32_t format_addr, uint32_ return ret; } if (!isspace(ch)) { - //wrapper_ungetc(mem, ch, fp_addr); break; } } bool l = false; - continue_format: + continue_format: switch (c) { case 'l': assert(!l && "ll not implemented in fscanf"); @@ -530,8 +609,7 @@ int wrapper_fscanf(uint8_t *mem, uint32_t fp_addr, uint32_t format_addr, uint32_ c = MEM_S8(format_addr); ++format_addr; goto continue_format; - case 'd': - { + case 'd': { int64_t num = 0; int sign = 1; bool found_first = false; @@ -572,7 +650,7 @@ int wrapper_fscanf(uint8_t *mem, uint32_t fp_addr, uint32_t format_addr, uint32_ } else if (c == '\0') { break; } else { - percent: + percent: ch = wrapper_fgetc(mem, fp_addr); if (ch == -1) { break; @@ -586,7 +664,7 @@ int wrapper_fscanf(uint8_t *mem, uint32_t fp_addr, uint32_t format_addr, uint32_ return ret; } -int wrapper_printf(uint8_t *mem, uint32_t format_addr, uint32_t sp) { +int wrapper_printf(uint8_t* mem, uint32_t format_addr, uint32_t sp) { STRING(format) if (!strcmp(format, " child died due to signal %d.\n")) { printf(format, MEM_U32(sp + 4)); @@ -596,7 +674,7 @@ int wrapper_printf(uint8_t *mem, uint32_t format_addr, uint32_t sp) { return 0; } -int wrapper_sprintf(uint8_t *mem, uint32_t str_addr, uint32_t format_addr, uint32_t sp) { +int wrapper_sprintf(uint8_t* mem, uint32_t str_addr, uint32_t format_addr, uint32_t sp) { STRING(format) // for debug char temp[32]; @@ -636,8 +714,11 @@ int wrapper_sprintf(uint8_t *mem, uint32_t str_addr, uint32_t format_addr, uint3 ++pos; uint32_t zeros = 0; bool zero_prefix = false; - continue_format: + continue_format: switch (c) { + case '\0': + goto finish_str; + case '0': do { c = MEM_S8(format_addr + pos); @@ -726,39 +807,50 @@ int wrapper_sprintf(uint8_t *mem, uint32_t str_addr, uint32_t format_addr, uint3 } } +finish_str: MEM_S8(str_addr) = '\0'; - STRING(orig_str) // for debug - //printf("result: '%s' '%s'\n", format, orig_str); return ret; } -int wrapper_fprintf(uint8_t *mem, uint32_t fp_addr, uint32_t format_addr, uint32_t sp) { - struct FILE_irix *f = (struct FILE_irix *)&MEM_U32(fp_addr); +int wrapper_fprintf(uint8_t* mem, uint32_t fp_addr, uint32_t format_addr, uint32_t sp) { + struct FILE_irix* f = (struct FILE_irix*)&MEM_U32(fp_addr); STRING(format) sp += 8; - /*if (!strcmp(format, "%s")) { - uint32_t s_addr = MEM_U32(sp); - STRING(s) - if (fp_addr == STDERR_ADDR) { - fprintf(stderr, "%s", s); - fflush(stderr); - return 1; - } + + // Special-case this one format string. This seems to be the only one that uses `%f` or width specifiers. + if (!strcmp(format, "%.2fu %.2fs %u:%04.1f %.0f%%\n") && fp_addr == STDERR_ADDR) { + double arg0 = MEM_F64(sp + 0); + double arg1 = MEM_F64(sp + 8); + uint32_t arg2 = MEM_U32(sp + 16); + double arg3 = MEM_F64(sp + 24); + double arg4 = MEM_F64(sp + 32); + fprintf(stderr, format, arg0, arg1, arg2, arg3, arg4); + fflush(stderr); + return 1; } - if (!strcmp(format, "%s: %s: ")) { - uint32_t s1_addr = MEM_U32(sp), s2_addr = MEM_U32(sp + 4); - STRING(s1) - STRING(s2) - if (fp_addr == STDERR_ADDR) { - fprintf(stderr, "%s: %s: ", s1, s2); - fflush(stderr); - return 1; + if (strcmp(format, "%s phase time: %.2fu %.2fs %u:%04.1f %.0f%%\n") == 0 && fp_addr == STDERR_ADDR) { + if (wrapper_fputs(mem, MEM_U32(sp), fp_addr) == -1) { + return 0; } - }*/ + sp += 4; + // align + sp += 4; + + double arg0 = MEM_F64(sp + 0); + double arg1 = MEM_F64(sp + 8); + uint32_t arg2 = MEM_U32(sp + 16); + double arg3 = MEM_F64(sp + 24); + double arg4 = MEM_F64(sp + 32); + fprintf(stderr, " phase time: %.2fu %.2fs %u:%04.1f %.0f%%\n", arg0, arg1, arg2, arg3, arg4); + fflush(stderr); + return 1; + } int ret = 0; for (;;) { + int width = 1; uint32_t pos = format_addr; char ch = MEM_S8(pos); + while (ch != '%' && ch != '\0') { ++pos; ch = MEM_S8(pos); @@ -773,32 +865,28 @@ int wrapper_fprintf(uint8_t *mem, uint32_t fp_addr, uint32_t format_addr, uint32 } ++pos; ch = MEM_S8(pos); + if (ch >= '1' && ch <= '9') { + ++pos; + width = ch - '0'; + ch = MEM_S8(pos); + } + switch (ch) { case 'd': - { - char buf[32]; - sprintf(buf, "%d", MEM_U32(sp)); - strcpy1(mem, INTBUF_ADDR, buf); - if (wrapper_fputs(mem, INTBUF_ADDR, fp_addr) == -1) { - return ret; - } - sp += 4; - ++ret; - break; - } - case 's': - { - if (wrapper_fputs(mem, MEM_U32(sp), fp_addr) == -1) { - return ret; - } - sp += 4; - ++ret; - break; - } + case 'x': + case 'X': case 'c': - { + case 'u': { char buf[32]; - sprintf(buf, "%c", MEM_U32(sp)); + + char formatSpecifier[0x100] = { 0 }; + + formatSpecifier[0] = '%'; + formatSpecifier[1] = width + '0'; + formatSpecifier[2] = ch; + + sprintf(buf, formatSpecifier, MEM_U32(sp)); + strcpy1(mem, INTBUF_ADDR, buf); if (wrapper_fputs(mem, INTBUF_ADDR, fp_addr) == -1) { return ret; @@ -807,6 +895,14 @@ int wrapper_fprintf(uint8_t *mem, uint32_t fp_addr, uint32_t format_addr, uint32 ++ret; break; } + case 's': { + if (wrapper_fputs(mem, MEM_U32(sp), fp_addr) == -1) { + return ret; + } + sp += 4; + ++ret; + break; + } default: fprintf(stderr, "missing format: '%s'\n", format); assert(0 && "non-implemented fprintf format"); @@ -816,12 +912,12 @@ int wrapper_fprintf(uint8_t *mem, uint32_t fp_addr, uint32_t format_addr, uint32 return ret; } -int wrapper__doprnt(uint8_t *mem, uint32_t format_addr, uint32_t params_addr, uint32_t fp_addr) { +int wrapper__doprnt(uint8_t* mem, uint32_t format_addr, uint32_t params_addr, uint32_t fp_addr) { assert(0 && "_doprnt not implemented"); return 0; } -uint32_t wrapper_strlen(uint8_t *mem, uint32_t str_addr) { +uint32_t wrapper_strlen(uint8_t* mem, uint32_t str_addr) { uint32_t len = 0; while (MEM_S8(str_addr) != '\0') { ++str_addr; @@ -830,8 +926,12 @@ uint32_t wrapper_strlen(uint8_t *mem, uint32_t str_addr) { return len; } -int wrapper_open(uint8_t *mem, uint32_t pathname_addr, int flags, int mode) { +int wrapper_open(uint8_t* mem, uint32_t pathname_addr, int flags, int mode) { STRING(pathname) + + char rpathname[PATH_MAX + 1]; + redirect_path(rpathname, pathname, "/usr/include", usr_include_redirect); + int f = flags & O_ACCMODE; if (flags & 0x100) { f |= O_CREAT; @@ -848,12 +948,13 @@ int wrapper_open(uint8_t *mem, uint32_t pathname_addr, int flags, int mode) { if (flags & 0x08) { f |= O_APPEND; } - int fd = open(pathname, f, mode); + + int fd = open(rpathname, f, mode); MEM_U32(ERRNO_ADDR) = errno; return fd; } -int wrapper_creat(uint8_t *mem, uint32_t pathname_addr, int mode) { +int wrapper_creat(uint8_t* mem, uint32_t pathname_addr, int mode) { STRING(pathname) int ret = creat(pathname, mode); if (ret < 0) { @@ -862,7 +963,7 @@ int wrapper_creat(uint8_t *mem, uint32_t pathname_addr, int mode) { return ret; } -int wrapper_access(uint8_t *mem, uint32_t pathname_addr, int mode) { +int wrapper_access(uint8_t* mem, uint32_t pathname_addr, int mode) { STRING(pathname) int ret = access(pathname, mode); if (ret != 0) { @@ -871,7 +972,7 @@ int wrapper_access(uint8_t *mem, uint32_t pathname_addr, int mode) { return ret; } -int wrapper_rename(uint8_t *mem, uint32_t oldpath_addr, uint32_t newpath_addr) { +int wrapper_rename(uint8_t* mem, uint32_t oldpath_addr, uint32_t newpath_addr) { STRING(oldpath) STRING(newpath) int ret = rename(oldpath, newpath); @@ -881,9 +982,9 @@ int wrapper_rename(uint8_t *mem, uint32_t oldpath_addr, uint32_t newpath_addr) { return ret; } -int wrapper_utime(uint8_t *mem, uint32_t filename_addr, uint32_t times_addr) { +int wrapper_utime(uint8_t* mem, uint32_t filename_addr, uint32_t times_addr) { STRING(filename) - struct utimbuf buf = {0, 0}; + struct utimbuf buf = { 0, 0 }; int ret = utime(filename, times_addr == 0 ? NULL : &buf); if (ret == 0) { if (times_addr != 0) { @@ -896,7 +997,7 @@ int wrapper_utime(uint8_t *mem, uint32_t filename_addr, uint32_t times_addr) { return ret; } -int wrapper_flock(uint8_t *mem, int fd, int operation) { +int wrapper_flock(uint8_t* mem, int fd, int operation) { int ret = flock(fd, operation); if (ret != 0) { MEM_U32(ERRNO_ADDR) = errno; @@ -904,7 +1005,7 @@ int wrapper_flock(uint8_t *mem, int fd, int operation) { return ret; } -int wrapper_chmod(uint8_t *mem, uint32_t path_addr, uint32_t mode) { +int wrapper_chmod(uint8_t* mem, uint32_t path_addr, uint32_t mode) { STRING(path) int ret = chmod(path, mode); if (ret < 0) { @@ -917,11 +1018,11 @@ int wrapper_umask(int mode) { return umask(mode); } -uint32_t wrapper_ecvt(uint8_t *mem, double number, int ndigits, uint32_t decpt_addr, uint32_t sign_addr) { +uint32_t wrapper_ecvt(uint8_t* mem, double number, int ndigits, uint32_t decpt_addr, uint32_t sign_addr) { assert(0); } -uint32_t wrapper_fcvt(uint8_t *mem, double number, int ndigits, uint32_t decpt_addr, uint32_t sign_addr) { +uint32_t wrapper_fcvt(uint8_t* mem, double number, int ndigits, uint32_t decpt_addr, uint32_t sign_addr) { assert(0); } @@ -933,23 +1034,23 @@ float wrapper_sqrtf(float v) { return sqrtf(v); } -int wrapper_atoi(uint8_t *mem, uint32_t nptr_addr) { +int wrapper_atoi(uint8_t* mem, uint32_t nptr_addr) { STRING(nptr) return atoi(nptr); } -int wrapper_atol(uint8_t *mem, uint32_t nptr_addr) { +int wrapper_atol(uint8_t* mem, uint32_t nptr_addr) { return wrapper_atoi(mem, nptr_addr); } -double wrapper_atof(uint8_t *mem, uint32_t nptr_addr) { +double wrapper_atof(uint8_t* mem, uint32_t nptr_addr) { STRING(nptr); return atof(nptr); } -int wrapper_strtol(uint8_t *mem, uint32_t nptr_addr, uint32_t endptr_addr, int base) { +int wrapper_strtol(uint8_t* mem, uint32_t nptr_addr, uint32_t endptr_addr, int base) { STRING(nptr) - char *endptr = NULL; + char* endptr = NULL; int64_t res = strtoll(nptr, endptr_addr != 0 ? &endptr : NULL, base); if (res > INT_MAX) { MEM_U32(ERRNO_ADDR) = ERANGE; @@ -965,9 +1066,9 @@ int wrapper_strtol(uint8_t *mem, uint32_t nptr_addr, uint32_t endptr_addr, int b return res; } -uint32_t wrapper_strtoul(uint8_t *mem, uint32_t nptr_addr, uint32_t endptr_addr, int base) { +uint32_t wrapper_strtoul(uint8_t* mem, uint32_t nptr_addr, uint32_t endptr_addr, int base) { STRING(nptr) - char *endptr = NULL; + char* endptr = NULL; uint64_t res = strtoull(nptr, endptr_addr != 0 ? &endptr : NULL, base); if (res > INT_MAX) { MEM_U32(ERRNO_ADDR) = ERANGE; @@ -979,9 +1080,37 @@ uint32_t wrapper_strtoul(uint8_t *mem, uint32_t nptr_addr, uint32_t endptr_addr, return res; } -double wrapper_strtod(uint8_t *mem, uint32_t nptr_addr, uint32_t endptr_addr) { +int64_t wrapper_strtoll(uint8_t* mem, uint32_t nptr_addr, uint32_t endptr_addr, int base) { STRING(nptr) - char *endptr = NULL; + char* endptr = NULL; + errno = 0; + int64_t res = strtoll(nptr, endptr_addr != 0 ? &endptr : NULL, base); + if (errno != 0) { + MEM_U32(ERRNO_ADDR) = errno; + } + if (endptr != NULL) { + MEM_U32(endptr_addr) = nptr_addr + (uint32_t)(endptr - nptr); + } + return res; +} + +uint64_t wrapper_strtoull(uint8_t* mem, uint32_t nptr_addr, uint32_t endptr_addr, int base) { + STRING(nptr) + char* endptr = NULL; + errno = 0; + uint64_t res = strtoull(nptr, endptr_addr != 0 ? &endptr : NULL, base); + if (errno != 0) { + MEM_U32(ERRNO_ADDR) = errno; + } + if (endptr != NULL) { + MEM_U32(endptr_addr) = nptr_addr + (uint32_t)(endptr - nptr); + } + return res; +} + +double wrapper_strtod(uint8_t* mem, uint32_t nptr_addr, uint32_t endptr_addr) { + STRING(nptr) + char* endptr = NULL; errno = 0; double res = strtod(nptr, endptr_addr != 0 ? &endptr : NULL); if (errno != 0) { @@ -993,7 +1122,7 @@ double wrapper_strtod(uint8_t *mem, uint32_t nptr_addr, uint32_t endptr_addr) { return res; } -uint32_t wrapper_strchr(uint8_t *mem, uint32_t str_addr, int c) { +uint32_t wrapper_strchr(uint8_t* mem, uint32_t str_addr, int c) { c = c & 0xff; for (;;) { unsigned char ch = MEM_U8(str_addr); @@ -1007,7 +1136,7 @@ uint32_t wrapper_strchr(uint8_t *mem, uint32_t str_addr, int c) { } } -uint32_t wrapper_strrchr(uint8_t *mem, uint32_t str_addr, int c) { +uint32_t wrapper_strrchr(uint8_t* mem, uint32_t str_addr, int c) { c = c & 0xff; uint32_t ret = 0; for (;;) { @@ -1022,7 +1151,7 @@ uint32_t wrapper_strrchr(uint8_t *mem, uint32_t str_addr, int c) { } } -uint32_t wrapper_strcspn(uint8_t *mem, uint32_t str_addr, uint32_t invalid_addr) { +uint32_t wrapper_strcspn(uint8_t* mem, uint32_t str_addr, uint32_t invalid_addr) { STRING(invalid) uint32_t n = strlen(invalid); uint32_t pos = 0; @@ -1039,7 +1168,7 @@ uint32_t wrapper_strcspn(uint8_t *mem, uint32_t str_addr, uint32_t invalid_addr) return pos; } -uint32_t wrapper_strpbrk(uint8_t *mem, uint32_t str_addr, uint32_t accept_addr) { +uint32_t wrapper_strpbrk(uint8_t* mem, uint32_t str_addr, uint32_t accept_addr) { STRING(accept) uint32_t n = strlen(accept); char c; @@ -1054,7 +1183,7 @@ uint32_t wrapper_strpbrk(uint8_t *mem, uint32_t str_addr, uint32_t accept_addr) return 0; } -static void stat_common(uint8_t *mem, uint32_t buf_addr, struct stat *statbuf) { +static void stat_common(uint8_t* mem, uint32_t buf_addr, struct stat* statbuf) { struct irix_stat { int st_dev; int pad1[3]; @@ -1089,17 +1218,17 @@ static void stat_common(uint8_t *mem, uint32_t buf_addr, struct stat *statbuf) { s.st_ctim.tv_sec = statbuf->st_ctimespec.tv_sec; s.st_ctim.tv_nsec = statbuf->st_ctimespec.tv_nsec; #else - s.st_atim.tv_sec = statbuf->st_atim.tv_sec; - s.st_atim.tv_nsec = statbuf->st_atim.tv_nsec; - s.st_mtim.tv_sec = statbuf->st_mtim.tv_sec; - s.st_mtim.tv_nsec = statbuf->st_mtim.tv_nsec; - s.st_ctim.tv_sec = statbuf->st_ctim.tv_sec; - s.st_ctim.tv_nsec = statbuf->st_ctim.tv_nsec; + s.st_atim.tv_sec = statbuf->st_atim.tv_sec; + s.st_atim.tv_nsec = statbuf->st_atim.tv_nsec; + s.st_mtim.tv_sec = statbuf->st_mtim.tv_sec; + s.st_mtim.tv_nsec = statbuf->st_mtim.tv_nsec; + s.st_ctim.tv_sec = statbuf->st_ctim.tv_sec; + s.st_ctim.tv_nsec = statbuf->st_ctim.tv_nsec; #endif memcpy(&MEM_U32(buf_addr), &s, sizeof(s)); } -int wrapper_fstat(uint8_t *mem, int fildes, uint32_t buf_addr) { +int wrapper_fstat(uint8_t* mem, int fildes, uint32_t buf_addr) { struct stat statbuf; if (fstat(fildes, &statbuf) < 0) { MEM_U32(ERRNO_ADDR) = errno; @@ -1110,7 +1239,7 @@ int wrapper_fstat(uint8_t *mem, int fildes, uint32_t buf_addr) { } } -int wrapper_stat(uint8_t *mem, uint32_t pathname_addr, uint32_t buf_addr) { +int wrapper_stat(uint8_t* mem, uint32_t pathname_addr, uint32_t buf_addr) { STRING(pathname) struct stat statbuf; if (stat(pathname, &statbuf) < 0) { @@ -1122,7 +1251,7 @@ int wrapper_stat(uint8_t *mem, uint32_t pathname_addr, uint32_t buf_addr) { } } -int wrapper_ftruncate(uint8_t *mem, int fd, int length) { +int wrapper_ftruncate(uint8_t* mem, int fd, int length) { int ret = ftruncate(fd, length); if (ret != 0) { MEM_U32(ERRNO_ADDR) = errno; @@ -1130,25 +1259,52 @@ int wrapper_ftruncate(uint8_t *mem, int fd, int length) { return ret; } -void wrapper_bcopy(uint8_t *mem, uint32_t src_addr, uint32_t dst_addr, uint32_t len) { - wrapper_memcpy(mem, dst_addr, src_addr, len); +int wrapper_truncate(uint8_t* mem, uint32_t pathname_addr, int length) { + STRING(pathname) + int ret = truncate(pathname, length); + if (ret != 0) { + MEM_U32(ERRNO_ADDR) = errno; + } + return ret; } -uint32_t wrapper_memcpy(uint8_t *mem, uint32_t dst_addr, uint32_t src_addr, uint32_t len) { - uint32_t saved = dst_addr; +void wrapper_bcopy(uint8_t* mem, uint32_t src_addr, uint32_t dst_addr, uint32_t len) { if (dst_addr % 4 == 0 && src_addr % 4 == 0 && len % 4 == 0) { - memcpy(&MEM_U32(dst_addr), &MEM_U32(src_addr), len); + // Use memmove to copy regions that are 4-byte aligned. + // This prevents the byte-swapped mem from causing issues when copying normally. + // Memmove handles overlapping copies correctly, so overlap does not need to be checked. + memmove(&MEM_U32(dst_addr), &MEM_U32(src_addr), len); + } else if (dst_addr > src_addr) { + // Perform a reverse byte-swapped copy when the destination is ahead of the source. + // This prevents overwriting the source contents before they're read. + dst_addr += len - 1; + src_addr += len - 1; + while (len--) { + MEM_U8(dst_addr) = MEM_U8(src_addr); + --dst_addr; + --src_addr; + } } else { + // Otherwise, perform a normal byte-swapped copy. while (len--) { MEM_U8(dst_addr) = MEM_U8(src_addr); ++dst_addr; ++src_addr; } } - return saved; } -uint32_t wrapper_memccpy(uint8_t *mem, uint32_t dst_addr, uint32_t src_addr, int c, uint32_t len) { +/** + * IRIX's memcpy seems to allow overlapping destination and source pointers, while the C standard dictates + * both pointer should not overlap, (UB otherwise). + * Because of this, we only use host bcopy since it can handle overlapping regions + */ +uint32_t wrapper_memcpy(uint8_t* mem, uint32_t dst_addr, uint32_t src_addr, uint32_t len) { + wrapper_bcopy(mem, src_addr, dst_addr, len); + return dst_addr; +} + +uint32_t wrapper_memccpy(uint8_t* mem, uint32_t dst_addr, uint32_t src_addr, int c, uint32_t len) { while (len--) { uint8_t ch = MEM_U8(src_addr); MEM_U8(dst_addr) = ch; @@ -1161,8 +1317,8 @@ uint32_t wrapper_memccpy(uint8_t *mem, uint32_t dst_addr, uint32_t src_addr, int return 0; } -int wrapper_read(uint8_t *mem, int fd, uint32_t buf_addr, uint32_t nbytes) { - uint8_t *buf = (uint8_t *)malloc(nbytes); +int wrapper_read(uint8_t* mem, int fd, uint32_t buf_addr, uint32_t nbytes) { + uint8_t* buf = (uint8_t*)malloc(nbytes); ssize_t ret = read(fd, buf, nbytes); if (ret < 0) { MEM_U32(ERRNO_ADDR) = errno; @@ -1175,8 +1331,8 @@ int wrapper_read(uint8_t *mem, int fd, uint32_t buf_addr, uint32_t nbytes) { return (int)ret; } -int wrapper_write(uint8_t *mem, int fd, uint32_t buf_addr, uint32_t nbytes) { - uint8_t *buf = (uint8_t *)malloc(nbytes); +int wrapper_write(uint8_t* mem, int fd, uint32_t buf_addr, uint32_t nbytes) { + uint8_t* buf = (uint8_t*)malloc(nbytes); for (size_t i = 0; i < nbytes; i++) { buf[i] = MEM_U8(buf_addr + i); } @@ -1188,7 +1344,7 @@ int wrapper_write(uint8_t *mem, int fd, uint32_t buf_addr, uint32_t nbytes) { return (int)ret; } -static uint32_t init_file(uint8_t *mem, int fd, int i, const char *path, const char *mode) { +static uint32_t init_file(uint8_t* mem, int fd, int i, const char* path, const char* mode) { int flags = O_RDONLY; if (strcmp(mode, "r") == 0 || strcmp(mode, "rb") == 0) { flags = O_RDONLY; @@ -1204,23 +1360,17 @@ static uint32_t init_file(uint8_t *mem, int fd, int i, const char *path, const c flags = O_RDWR | O_CREAT | O_APPEND; } if (fd == -1) { + char rpathname[PATH_MAX + 1]; + redirect_path(rpathname, path, "/usr/lib", usr_lib_redirect); + + fd = open(rpathname, flags, 0666); -#ifdef REDIRECT_USR_LIB - char fixed_path[PATH_MAX + 1]; - if (!strcmp(path, "/usr/lib/err.english.cc") && bin_dir[0] != '\0') { - int n = snprintf(fixed_path, sizeof(fixed_path), "%s/err.english.cc", bin_dir); - if (n >= 0 && n < sizeof(fixed_path)) { - path = fixed_path; - } - } -#endif - fd = open(path, flags, 0666); if (fd < 0) { MEM_U32(ERRNO_ADDR) = errno; return 0; } } - struct FILE_irix *f = (struct FILE_irix *)&MEM_U32(IOB_ADDR); + struct FILE_irix* f = (struct FILE_irix*)&MEM_U32(IOB_ADDR); uint32_t ret = 0; if (i == -1) { for (i = 3; i < NFILE; i++) { @@ -1243,22 +1393,25 @@ static uint32_t init_file(uint8_t *mem, int fd, int i, const char *path, const c return ret; } -uint32_t wrapper_fopen(uint8_t *mem, uint32_t path_addr, uint32_t mode_addr) { +uint32_t wrapper_fopen(uint8_t* mem, uint32_t path_addr, uint32_t mode_addr) { + assert(path_addr != 0); + assert(mode_addr != 0); + STRING(path) STRING(mode) return init_file(mem, -1, -1, path, mode); } -uint32_t wrapper_freopen(uint8_t *mem, uint32_t path_addr, uint32_t mode_addr, uint32_t fp_addr) { +uint32_t wrapper_freopen(uint8_t* mem, uint32_t path_addr, uint32_t mode_addr, uint32_t fp_addr) { STRING(path) STRING(mode) - struct FILE_irix *f = (struct FILE_irix *)&MEM_U32(fp_addr); + struct FILE_irix* f = (struct FILE_irix*)&MEM_U32(fp_addr); wrapper_fclose(mem, fp_addr); - return init_file(mem, -1, f - (struct FILE_irix *)&MEM_U32(IOB_ADDR), path, mode); + return init_file(mem, -1, f - (struct FILE_irix*)&MEM_U32(IOB_ADDR), path, mode); } -int wrapper_fclose(uint8_t *mem, uint32_t fp_addr) { - struct FILE_irix *f = (struct FILE_irix *)&MEM_U32(fp_addr); +int wrapper_fclose(uint8_t* mem, uint32_t fp_addr) { + struct FILE_irix* f = (struct FILE_irix*)&MEM_U32(fp_addr); wrapper_fflush(mem, fp_addr); if (f->_flag & IOMYBUF) { wrapper_free(mem, f->_base_addr); @@ -1268,8 +1421,8 @@ int wrapper_fclose(uint8_t *mem, uint32_t fp_addr) { return 0; } -static int flush_all(uint8_t *mem) { - struct FILE_irix *f = (struct FILE_irix *)&MEM_U32(IOB_ADDR); +static int flush_all(uint8_t* mem) { + struct FILE_irix* f = (struct FILE_irix*)&MEM_U32(IOB_ADDR); int ret = 0; for (int i = 0; i < g_file_max; i++) { if (f[i]._flag & IOWRT) { @@ -1279,12 +1432,12 @@ static int flush_all(uint8_t *mem) { return ret; } -int wrapper_fflush(uint8_t *mem, uint32_t fp_addr) { +int wrapper_fflush(uint8_t* mem, uint32_t fp_addr) { if (fp_addr == 0) { // Flush all return flush_all(mem); } - struct FILE_irix *f = (struct FILE_irix *)&MEM_U32(fp_addr); + struct FILE_irix* f = (struct FILE_irix*)&MEM_U32(fp_addr); if (f->_flag & IOWRT) { int p = 0; int to_flush = f->_ptr_addr - f->_base_addr; @@ -1304,8 +1457,16 @@ int wrapper_fflush(uint8_t *mem, uint32_t fp_addr) { return 0; } -int wrapper_ftell(uint8_t *mem, uint32_t fp_addr) { - struct FILE_irix *f = (struct FILE_irix *)&MEM_U32(fp_addr); +int wrapper_fchown(uint8_t* mem, int fd, int owner, int group) { + int ret = fchown(fd, owner, group); + if (ret != 0) { + MEM_U32(ERRNO_ADDR) = errno; + } + return ret; +} + +int wrapper_ftell(uint8_t* mem, uint32_t fp_addr) { + struct FILE_irix* f = (struct FILE_irix*)&MEM_U32(fp_addr); int adjust; if (f->_cnt < 0) { f->_cnt = 0; @@ -1327,14 +1488,14 @@ int wrapper_ftell(uint8_t *mem, uint32_t fp_addr) { return res; } -void wrapper_rewind(uint8_t *mem, uint32_t fp_addr) { +void wrapper_rewind(uint8_t* mem, uint32_t fp_addr) { (void)wrapper_fseek(mem, fp_addr, 0, SEEK_SET); - struct FILE_irix *f = (struct FILE_irix *)&MEM_U32(fp_addr); + struct FILE_irix* f = (struct FILE_irix*)&MEM_U32(fp_addr); f->_flag &= ~IOERR; } -int wrapper_fseek(uint8_t *mem, uint32_t fp_addr, int offset, int origin) { - struct FILE_irix *f = (struct FILE_irix *)&MEM_U32(fp_addr); +int wrapper_fseek(uint8_t* mem, uint32_t fp_addr, int offset, int origin) { + struct FILE_irix* f = (struct FILE_irix*)&MEM_U32(fp_addr); int c, p; f->_flag &= ~IOEOF; if (f->_flag & IOREAD) { @@ -1374,7 +1535,7 @@ int wrapper_fseek(uint8_t *mem, uint32_t fp_addr, int offset, int origin) { return 0; } -int wrapper_lseek(uint8_t *mem, int fd, int offset, int whence) { +int wrapper_lseek(uint8_t* mem, int fd, int offset, int whence) { int ret = (int)lseek(fd, offset, whence); if (ret == -1) { MEM_U32(ERRNO_ADDR) = errno; @@ -1382,7 +1543,7 @@ int wrapper_lseek(uint8_t *mem, int fd, int offset, int whence) { return ret; } -int wrapper_dup(uint8_t *mem, int fd) { +int wrapper_dup(uint8_t* mem, int fd) { fd = dup(fd); if (fd < 0) { MEM_U32(ERRNO_ADDR) = errno; @@ -1390,7 +1551,7 @@ int wrapper_dup(uint8_t *mem, int fd) { return fd; } -int wrapper_dup2(uint8_t *mem, int oldfd, int newfd) { +int wrapper_dup2(uint8_t* mem, int oldfd, int newfd) { int fd = dup2(oldfd, newfd); if (fd < 0) { MEM_U32(ERRNO_ADDR) = errno; @@ -1398,7 +1559,7 @@ int wrapper_dup2(uint8_t *mem, int oldfd, int newfd) { return fd; } -int wrapper_pipe(uint8_t *mem, uint32_t pipefd_addr) { +int wrapper_pipe(uint8_t* mem, uint32_t pipefd_addr) { int pipefd[2]; int ret = pipe(pipefd); if (ret == 0) { @@ -1410,17 +1571,17 @@ int wrapper_pipe(uint8_t *mem, uint32_t pipefd_addr) { return ret; } -void wrapper_perror(uint8_t *mem, uint32_t str_addr) { +void wrapper_perror(uint8_t* mem, uint32_t str_addr) { STRING(str) perror(str); } -int wrapper_fdopen(uint8_t *mem, int fd, uint32_t mode_addr) { +int wrapper_fdopen(uint8_t* mem, int fd, uint32_t mode_addr) { STRING(mode) return init_file(mem, fd, -1, NULL, mode); } -uint32_t wrapper_memset(uint8_t *mem, uint32_t dest_addr, int byte, uint32_t n) { +uint32_t wrapper_memset(uint8_t* mem, uint32_t dest_addr, int byte, uint32_t n) { uint32_t saved = dest_addr; if (dest_addr % 4 == 0 && n % 4 == 0) { memset(&MEM_U32(dest_addr), byte, n); @@ -1433,7 +1594,7 @@ uint32_t wrapper_memset(uint8_t *mem, uint32_t dest_addr, int byte, uint32_t n) return saved; } -int wrapper_bcmp(uint8_t *mem, uint32_t s1_addr, uint32_t s2_addr, uint32_t n) { +int wrapper_bcmp(uint8_t* mem, uint32_t s1_addr, uint32_t s2_addr, uint32_t n) { while (n--) { if (MEM_U8(s1_addr) != MEM_U8(s2_addr)) { return 1; @@ -1444,7 +1605,7 @@ int wrapper_bcmp(uint8_t *mem, uint32_t s1_addr, uint32_t s2_addr, uint32_t n) { return 0; } -int wrapper_memcmp(uint8_t *mem, uint32_t s1_addr, uint32_t s2_addr, uint32_t n) { +int wrapper_memcmp(uint8_t* mem, uint32_t s1_addr, uint32_t s2_addr, uint32_t n) { while (n--) { unsigned char c1 = MEM_U8(s1_addr); unsigned char c2 = MEM_U8(s2_addr); @@ -1464,7 +1625,7 @@ int wrapper_getpid(void) { return getpid(); } -int wrapper_getpgrp(uint8_t *mem) { +int wrapper_getpgrp(uint8_t* mem) { int ret = getpgrp(); if (ret == -1) { MEM_U32(ERRNO_ADDR) = errno; @@ -1472,7 +1633,7 @@ int wrapper_getpgrp(uint8_t *mem) { return ret; } -int wrapper_remove(uint8_t *mem, uint32_t path_addr) { +int wrapper_remove(uint8_t* mem, uint32_t path_addr) { STRING(path) int ret = remove(path); if (ret < 0) { @@ -1481,7 +1642,7 @@ int wrapper_remove(uint8_t *mem, uint32_t path_addr) { return ret; } -int wrapper_unlink(uint8_t *mem, uint32_t path_addr) { +int wrapper_unlink(uint8_t* mem, uint32_t path_addr) { if (path_addr == 0) { fprintf(stderr, "Warning: unlink with NULL as arguement\n"); MEM_U32(ERRNO_ADDR) = EFAULT; @@ -1495,7 +1656,7 @@ int wrapper_unlink(uint8_t *mem, uint32_t path_addr) { return ret; } -int wrapper_close(uint8_t *mem, int fd) { +int wrapper_close(uint8_t* mem, int fd) { int ret = close(fd); if (ret < 0) { MEM_U32(ERRNO_ADDR) = errno; @@ -1503,7 +1664,7 @@ int wrapper_close(uint8_t *mem, int fd) { return ret; } -int wrapper_strcmp(uint8_t *mem, uint32_t s1_addr, uint32_t s2_addr) { +int wrapper_strcmp(uint8_t* mem, uint32_t s1_addr, uint32_t s2_addr) { for (;;) { char c1 = MEM_S8(s1_addr); char c2 = MEM_S8(s2_addr); @@ -1518,7 +1679,7 @@ int wrapper_strcmp(uint8_t *mem, uint32_t s1_addr, uint32_t s2_addr) { } } -int wrapper_strncmp(uint8_t *mem, uint32_t s1_addr, uint32_t s2_addr, uint32_t n) { +int wrapper_strncmp(uint8_t* mem, uint32_t s1_addr, uint32_t s2_addr, uint32_t n) { if (n == 0) { return 0; } @@ -1536,7 +1697,7 @@ int wrapper_strncmp(uint8_t *mem, uint32_t s1_addr, uint32_t s2_addr, uint32_t n } } -uint32_t wrapper_strcpy(uint8_t *mem, uint32_t dest_addr, uint32_t src_addr) { +uint32_t wrapper_strcpy(uint8_t* mem, uint32_t dest_addr, uint32_t src_addr) { uint32_t saved = dest_addr; for (;;) { char c = MEM_S8(src_addr); @@ -1549,7 +1710,7 @@ uint32_t wrapper_strcpy(uint8_t *mem, uint32_t dest_addr, uint32_t src_addr) { } } -uint32_t wrapper_strncpy(uint8_t *mem, uint32_t dest_addr, uint32_t src_addr, uint32_t n) { +uint32_t wrapper_strncpy(uint8_t* mem, uint32_t dest_addr, uint32_t src_addr, uint32_t n) { uint32_t i; for (i = 0; i < n && MEM_S8(src_addr) != '\0'; i++) { MEM_S8(dest_addr + i) = MEM_S8(src_addr + i); @@ -1560,7 +1721,7 @@ uint32_t wrapper_strncpy(uint8_t *mem, uint32_t dest_addr, uint32_t src_addr, ui return dest_addr; } -uint32_t wrapper_strcat(uint8_t *mem, uint32_t dest_addr, uint32_t src_addr) { +uint32_t wrapper_strcat(uint8_t* mem, uint32_t dest_addr, uint32_t src_addr) { uint32_t saved = dest_addr; while (MEM_S8(dest_addr) != '\0') { ++dest_addr; @@ -1574,7 +1735,7 @@ uint32_t wrapper_strcat(uint8_t *mem, uint32_t dest_addr, uint32_t src_addr) { return saved; } -uint32_t wrapper_strncat(uint8_t *mem, uint32_t dest_addr, uint32_t src_addr, uint32_t n) { +uint32_t wrapper_strncat(uint8_t* mem, uint32_t dest_addr, uint32_t src_addr, uint32_t n) { uint32_t saved = dest_addr; while (MEM_S8(dest_addr) != '\0') { ++dest_addr; @@ -1588,7 +1749,7 @@ uint32_t wrapper_strncat(uint8_t *mem, uint32_t dest_addr, uint32_t src_addr, ui return saved; } -uint32_t wrapper_strtok(uint8_t *mem, uint32_t str_addr, uint32_t delimiters_addr) { +uint32_t wrapper_strtok(uint8_t* mem, uint32_t str_addr, uint32_t delimiters_addr) { if (str_addr == 0) { str_addr = MEM_U32(STRTOK_DATA_ADDR); } @@ -1599,8 +1760,7 @@ uint32_t wrapper_strtok(uint8_t *mem, uint32_t str_addr, uint32_t delimiters_add uint32_t p; for (p = str_addr; MEM_S8(p) != '\0'; p++) { uint32_t q; - for (q = delimiters_addr; MEM_S8(q) != '\0' && MEM_S8(q) != MEM_S8(p); q++) { - } + for (q = delimiters_addr; MEM_S8(q) != '\0' && MEM_S8(q) != MEM_S8(p); q++) {} if (MEM_S8(q) == '\0') { break; } @@ -1611,8 +1771,7 @@ uint32_t wrapper_strtok(uint8_t *mem, uint32_t str_addr, uint32_t delimiters_add uint32_t ret = p; for (;;) { uint32_t q; - for (q = delimiters_addr; MEM_S8(q) != '\0' && MEM_S8(q) != MEM_S8(p); q++) { - } + for (q = delimiters_addr; MEM_S8(q) != '\0' && MEM_S8(q) != MEM_S8(p); q++) {} if (MEM_S8(q) != '\0') { MEM_S8(p) = '\0'; MEM_U32(STRTOK_DATA_ADDR) = ++p; @@ -1627,7 +1786,7 @@ uint32_t wrapper_strtok(uint8_t *mem, uint32_t str_addr, uint32_t delimiters_add } } -uint32_t wrapper_strstr(uint8_t *mem, uint32_t str1_addr, uint32_t str2_addr) { +uint32_t wrapper_strstr(uint8_t* mem, uint32_t str1_addr, uint32_t str2_addr) { for (;;) { if (MEM_S8(str1_addr) == '\0') { return 0; @@ -1650,7 +1809,7 @@ uint32_t wrapper_strstr(uint8_t *mem, uint32_t str1_addr, uint32_t str2_addr) { } } -uint32_t wrapper_strdup(uint8_t *mem, uint32_t str_addr) { +uint32_t wrapper_strdup(uint8_t* mem, uint32_t str_addr) { uint32_t len = wrapper_strlen(mem, str_addr) + 1; uint32_t ret = wrapper_malloc(mem, len); if (ret == 0) { @@ -1668,8 +1827,8 @@ int wrapper_tolower(int c) { return tolower(c); } -int wrapper_gethostname(uint8_t *mem, uint32_t name_addr, uint32_t len) { - char buf[256] = {0}; +int wrapper_gethostname(uint8_t* mem, uint32_t name_addr, uint32_t len) { + char buf[256] = { 0 }; if (len > 256) { len = 256; } @@ -1684,7 +1843,7 @@ int wrapper_gethostname(uint8_t *mem, uint32_t name_addr, uint32_t len) { return ret; } -int wrapper_isatty(uint8_t *mem, int fd) { +int wrapper_isatty(uint8_t* mem, int fd) { int ret = isatty(fd); if (ret == 0) { MEM_U32(ERRNO_ADDR) = errno; @@ -1692,13 +1851,13 @@ int wrapper_isatty(uint8_t *mem, int fd) { return ret; } -uint32_t wrapper_strftime(uint8_t *mem, uint32_t ptr_addr, uint32_t maxsize, uint32_t format_addr, uint32_t timeptr_addr) { - //assert(0 && "strftime not implemented"); +uint32_t wrapper_strftime(uint8_t* mem, uint32_t ptr_addr, uint32_t maxsize, uint32_t format_addr, + uint32_t timeptr_addr) { MEM_S8(ptr_addr) = 0; return 0; } -int wrapper_times(uint8_t *mem, uint32_t buffer_addr) { +int wrapper_times(uint8_t* mem, uint32_t buffer_addr) { struct tms_irix { int tms_utime; int tms_stime; @@ -1714,6 +1873,10 @@ int wrapper_times(uint8_t *mem, uint32_t buffer_addr) { r.tms_stime = t.tms_stime; r.tms_cutime = t.tms_cutime; r.tms_cstime = t.tms_cstime; + MEM_U32(buffer_addr + 0x0) = t.tms_utime; + MEM_U32(buffer_addr + 0x4) = t.tms_stime; + MEM_U32(buffer_addr + 0x8) = t.tms_cutime; + MEM_U32(buffer_addr + 0xC) = t.tms_cstime; } return (int)ret; } @@ -1722,9 +1885,9 @@ int wrapper_clock(void) { return (int)clock(); } -uint32_t wrapper_ctime(uint8_t *mem, uint32_t timep_addr) { +uint32_t wrapper_ctime(uint8_t* mem, uint32_t timep_addr) { time_t t = MEM_S32(timep_addr); - char *res = ctime(&t); + char* res = ctime(&t); size_t len = strlen(res) + 1; uint32_t ret_addr = wrapper_malloc(mem, len); uint32_t pos = ret_addr; @@ -1734,11 +1897,9 @@ uint32_t wrapper_ctime(uint8_t *mem, uint32_t timep_addr) { ++res; } return ret_addr; - //assert(0 && "ctime not implemented"); - //return 0; } -uint32_t wrapper_localtime(uint8_t *mem, uint32_t timep_addr) { +uint32_t wrapper_localtime(uint8_t* mem, uint32_t timep_addr) { time_t t = MEM_S32(timep_addr); struct irix_tm { int tm_sec; @@ -1752,8 +1913,8 @@ uint32_t wrapper_localtime(uint8_t *mem, uint32_t timep_addr) { int tm_isdst; }; uint32_t ret = wrapper_malloc(mem, sizeof(struct irix_tm)); - struct irix_tm *r = (struct irix_tm *)&MEM_U32(ret); - struct tm *l = localtime(&t); + struct irix_tm* r = (struct irix_tm*)&MEM_U32(ret); + struct tm* l = localtime(&t); r->tm_sec = l->tm_sec; r->tm_min = l->tm_min; r->tm_hour = l->tm_hour; @@ -1766,14 +1927,21 @@ uint32_t wrapper_localtime(uint8_t *mem, uint32_t timep_addr) { return ret; } -int wrapper_setvbuf(uint8_t *mem, uint32_t fp_addr, uint32_t buf_addr, int mode, uint32_t size) { - struct FILE_irix *f = (struct FILE_irix *)&MEM_U32(fp_addr); +int wrapper_setvbuf(uint8_t* mem, uint32_t fp_addr, uint32_t buf_addr, int mode, uint32_t size) { + struct FILE_irix* f = (struct FILE_irix*)&MEM_U32(fp_addr); wrapper_fflush(mem, fp_addr); if ((f->_flag & IOMYBUF) && f->_base_addr != 0) { wrapper_free(mem, f->_base_addr); } size &= ~0xf; f->_flag &= ~IOMYBUF; + + if (buf_addr == 0) { + assert(size > 0); + buf_addr = wrapper_malloc(mem, size); + f->_flag |= IOMYBUF; + } + f->_base_addr = buf_addr; f->_ptr_addr = buf_addr; f->_cnt = 0; @@ -1781,16 +1949,16 @@ int wrapper_setvbuf(uint8_t *mem, uint32_t fp_addr, uint32_t buf_addr, int mode, return 0; } -int wrapper___semgetc(uint8_t *mem, uint32_t fp_addr) { +int wrapper___semgetc(uint8_t* mem, uint32_t fp_addr) { assert(0); } -int wrapper___semputc(uint8_t *mem, int c, uint32_t fp_addr) { +int wrapper___semputc(uint8_t* mem, int c, uint32_t fp_addr) { assert(0); } -int wrapper_fgetc(uint8_t *mem, uint32_t fp_addr) { - struct FILE_irix *f = (struct FILE_irix *)&MEM_U32(fp_addr); +int wrapper_fgetc(uint8_t* mem, uint32_t fp_addr) { + struct FILE_irix* f = (struct FILE_irix*)&MEM_U32(fp_addr); if (--f->_cnt < 0) { return wrapper___filbuf(mem, fp_addr); } else { @@ -1800,7 +1968,7 @@ int wrapper_fgetc(uint8_t *mem, uint32_t fp_addr) { } } -int wrapper_fgets(uint8_t *mem, uint32_t str_addr, int count, uint32_t fp_addr) { +int wrapper_fgets(uint8_t* mem, uint32_t str_addr, int count, uint32_t fp_addr) { bool modified = false; uint32_t saved = str_addr; for (count--; count > 0; count--) { @@ -1820,16 +1988,16 @@ int wrapper_fgets(uint8_t *mem, uint32_t str_addr, int count, uint32_t fp_addr) return saved; } -static void file_assign_buffer(uint8_t *mem, struct FILE_irix *f) { +static void file_assign_buffer(uint8_t* mem, struct FILE_irix* f) { f->_base_addr = wrapper_malloc(mem, STDIO_BUFSIZE); f->_ptr_addr = f->_base_addr; f->_flag |= IOMYBUF; f->_cnt = 0; - bufendtab[f - (struct FILE_irix *)&MEM_U32(IOB_ADDR)] = STDIO_BUFSIZE; + bufendtab[f - (struct FILE_irix*)&MEM_U32(IOB_ADDR)] = STDIO_BUFSIZE; } -int wrapper___filbuf(uint8_t *mem, uint32_t fp_addr) { - struct FILE_irix *f = (struct FILE_irix *)&MEM_U32(fp_addr); +int wrapper___filbuf(uint8_t* mem, uint32_t fp_addr) { + struct FILE_irix* f = (struct FILE_irix*)&MEM_U32(fp_addr); if (!(f->_flag & IOREAD)) { if (f->_flag & IORW) { f->_flag |= IOREAD; @@ -1858,14 +2026,14 @@ int wrapper___filbuf(uint8_t *mem, uint32_t fp_addr) { return ret; } -int wrapper___flsbuf(uint8_t *mem, int ch, uint32_t fp_addr) { - struct FILE_irix *f = (struct FILE_irix *)&MEM_U32(fp_addr); +int wrapper___flsbuf(uint8_t* mem, int ch, uint32_t fp_addr) { + struct FILE_irix* f = (struct FILE_irix*)&MEM_U32(fp_addr); if (wrapper_fflush(mem, fp_addr) != 0) { return -1; } if (f->_base_addr == 0) { file_assign_buffer(mem, f); - f->_cnt = bufendtab[f - (struct FILE_irix *)&MEM_U32(IOB_ADDR)]; + f->_cnt = bufendtab[f - (struct FILE_irix*)&MEM_U32(IOB_ADDR)]; } MEM_U8(f->_ptr_addr) = ch; ++f->_ptr_addr; @@ -1879,8 +2047,8 @@ int wrapper___flsbuf(uint8_t *mem, int ch, uint32_t fp_addr) { return ch; } -int wrapper_ungetc(uint8_t *mem, int ch, uint32_t fp_addr) { - struct FILE_irix *f = (struct FILE_irix *)&MEM_U32(fp_addr); +int wrapper_ungetc(uint8_t* mem, int ch, uint32_t fp_addr) { + struct FILE_irix* f = (struct FILE_irix*)&MEM_U32(fp_addr); if (ch == -1 || f->_ptr_addr == f->_base_addr) { return -1; } @@ -1891,7 +2059,7 @@ int wrapper_ungetc(uint8_t *mem, int ch, uint32_t fp_addr) { return ch; } -uint32_t wrapper_gets(uint8_t *mem, uint32_t str_addr) { +uint32_t wrapper_gets(uint8_t* mem, uint32_t str_addr) { uint32_t p, str0 = str_addr; int n; @@ -1924,8 +2092,8 @@ uint32_t wrapper_gets(uint8_t *mem, uint32_t str_addr) { return str0; } -uint32_t wrapper_fread(uint8_t *mem, uint32_t data_addr, uint32_t size, uint32_t count, uint32_t fp_addr) { - struct FILE_irix *f = (struct FILE_irix *)&MEM_U32(fp_addr); +uint32_t wrapper_fread(uint8_t* mem, uint32_t data_addr, uint32_t size, uint32_t count, uint32_t fp_addr) { + struct FILE_irix* f = (struct FILE_irix*)&MEM_U32(fp_addr); int nleft = count * size; int n; for (;;) { @@ -1946,11 +2114,11 @@ uint32_t wrapper_fread(uint8_t *mem, uint32_t data_addr, uint32_t size, uint32_t } } -uint32_t wrapper_fwrite(uint8_t *mem, uint32_t data_addr, uint32_t size, uint32_t count, uint32_t fp_addr) { - struct FILE_irix *f = (struct FILE_irix *)&MEM_U32(fp_addr); +uint32_t wrapper_fwrite(uint8_t* mem, uint32_t data_addr, uint32_t size, uint32_t count, uint32_t fp_addr) { + struct FILE_irix* f = (struct FILE_irix*)&MEM_U32(fp_addr); if (size > 0 && count > 0 && f->_base_addr == 0) { file_assign_buffer(mem, f); - f->_cnt = bufendtab[f - (struct FILE_irix *)&MEM_U32(IOB_ADDR)]; + f->_cnt = bufendtab[f - (struct FILE_irix*)&MEM_U32(IOB_ADDR)]; f->_flag |= IOWRT; } uint32_t num_written = 0; @@ -1980,18 +2148,20 @@ uint32_t wrapper_fwrite(uint8_t *mem, uint32_t data_addr, uint32_t size, uint32_ return num_written; } -int wrapper_fputs(uint8_t *mem, uint32_t str_addr, uint32_t fp_addr) { +int wrapper_fputs(uint8_t* mem, uint32_t str_addr, uint32_t fp_addr) { + assert(str_addr != 0); + uint32_t len = wrapper_strlen(mem, str_addr); uint32_t ret = wrapper_fwrite(mem, str_addr, 1, len, fp_addr); return ret == 0 && len != 0 ? -1 : 0; } -int wrapper_puts(uint8_t *mem, uint32_t str_addr) { +int wrapper_puts(uint8_t* mem, uint32_t str_addr) { int ret = wrapper_fputs(mem, str_addr, STDOUT_ADDR); if (ret != 0) { return ret; } - struct FILE_irix *f = STDOUT; + struct FILE_irix* f = STDOUT; if (--f->_cnt < 0) { if (wrapper___flsbuf(mem, '\n', STDOUT_ADDR) != '\n') { return -1; @@ -2003,7 +2173,7 @@ int wrapper_puts(uint8_t *mem, uint32_t str_addr) { return 0; } -uint32_t wrapper_getcwd(uint8_t *mem, uint32_t buf_addr, uint32_t size) { +uint32_t wrapper_getcwd(uint8_t* mem, uint32_t buf_addr, uint32_t size) { char buf[size]; if (getcwd(buf, size) == NULL) { MEM_U32(ERRNO_ADDR) = errno; @@ -2017,7 +2187,7 @@ uint32_t wrapper_getcwd(uint8_t *mem, uint32_t buf_addr, uint32_t size) { } } -int wrapper_time(uint8_t *mem, uint32_t tloc_addr) { +int wrapper_time(uint8_t* mem, uint32_t tloc_addr) { time_t ret = time(NULL); if (ret == (time_t)-1) { MEM_U32(ERRNO_ADDR) = errno; @@ -2027,7 +2197,7 @@ int wrapper_time(uint8_t *mem, uint32_t tloc_addr) { return ret; } -void wrapper_bzero(uint8_t *mem, uint32_t str_addr, uint32_t n) { +void wrapper_bzero(uint8_t* mem, uint32_t str_addr, uint32_t n) { while (n--) { MEM_U8(str_addr) = 0; ++str_addr; @@ -2040,7 +2210,7 @@ int wrapper_fp_class_d(double d) { double d; } bits; bits.d = d; - uint32_t a2 = bits.w[1]; + uint32_t a2 = bits.w[1]; uint32_t a1 = a2 >> 20; uint32_t a0 = a1; a2 &= 0xfffff; @@ -2067,7 +2237,7 @@ double wrapper_ldexp(double d, int i) { return ldexp(d, i); } -int64_t wrapper___ll_mul(int64_t a0, int64_t a1) { +uint64_t wrapper___ll_mul(uint64_t a0, uint64_t a1) { return a0 * a1; } @@ -2079,12 +2249,12 @@ int64_t wrapper___ll_rem(uint64_t a0, int64_t a1) { return a0 % a1; } -int64_t wrapper___ll_lshift(int64_t a0, uint64_t shift) { - return a0 << (shift & 0x3f); +uint64_t wrapper___ll_lshift(uint64_t a0, uint64_t shift) { + return a0 << (shift & 0x3F); } int64_t wrapper___ll_rshift(int64_t a0, uint64_t shift) { - return a0 >> (shift & 0x3f); + return a0 >> (shift & 0x3F); } uint64_t wrapper___ull_div(uint64_t a0, uint64_t a1) { @@ -2131,42 +2301,43 @@ double wrapper___ll_to_d(int64_t v) { return v; } -void wrapper_abort(uint8_t *mem) { +void wrapper_abort(uint8_t* mem) { abort(); } -void wrapper_exit(uint8_t *mem, int status) { +void wrapper_exit(uint8_t* mem, int status) { + final_cleanup(mem); exit(status); } -void wrapper__exit(uint8_t *mem, int status) { +void wrapper__exit(uint8_t* mem, int status) { assert(0 && "_exit not implemented"); // exit() is already overridden } -void wrapper__cleanup(uint8_t *mem) { +void wrapper__cleanup(uint8_t* mem) { } -uint32_t wrapper__rld_new_interface(uint8_t *mem, uint32_t operation, uint32_t sp) { +uint32_t wrapper__rld_new_interface(uint8_t* mem, uint32_t operation, uint32_t sp) { assert(0 && "_rld_new_interface not implemented"); return 0; } -void wrapper__exithandle(uint8_t *mem) { +void wrapper__exithandle(uint8_t* mem) { assert(0 && "_exithandle not implemented"); } -int wrapper__prctl(uint8_t *mem, int operation, uint32_t sp) { +int wrapper__prctl(uint8_t* mem, int operation, uint32_t sp) { assert(0 && "_prctl not implemented"); return 0; } -double wrapper__atod(uint8_t *mem, uint32_t buffer_addr, int ndigits, int dexp) { +double wrapper__atod(uint8_t* mem, uint32_t buffer_addr, int ndigits, int dexp) { // ftp://atoum.hst.nerim.net/irix/src/irix-6.5.5-src/6.5.5/m/irix/lib/libc/src/math/atod.c assert(0 && "_atod not implemented"); return 0.0; } -int wrapper_pathconf(uint8_t *mem, uint32_t path_addr, int name) { +int wrapper_pathconf(uint8_t* mem, uint32_t path_addr, int name) { STRING(path) if (name == 5) { errno = 0; @@ -2180,81 +2351,106 @@ int wrapper_pathconf(uint8_t *mem, uint32_t path_addr, int name) { return 0; } -uint32_t wrapper_getenv(uint8_t *mem, uint32_t name_addr) { - // Return null for everything, for now - return 0; +uint32_t wrapper_getenv(uint8_t* mem, uint32_t name_addr) { + STRING(name); + const char* value = getenv(name); + if (value == NULL) { + return 0; + } + size_t value_size = strlen(value) + 1; + uint32_t buf_addr = wrapper_malloc(mem, value_size); + strcpy1(mem, buf_addr, value); + return buf_addr; } -uint32_t wrapper_gettxt(uint8_t *mem, uint32_t msgid_addr, uint32_t default_str_addr) { +uint32_t wrapper_gettxt(uint8_t* mem, uint32_t msgid_addr, uint32_t default_str_addr) { // Return default for now return default_str_addr; } -uint32_t wrapper_setlocale(uint8_t *mem, int category, uint32_t locale_addr) { +uint32_t wrapper_setlocale(uint8_t* mem, int category, uint32_t locale_addr) { assert(locale_addr != 0); STRING(locale) assert(category == 6); // LC_ALL - char *ret = setlocale(LC_ALL, locale); + char* ret = setlocale(LC_ALL, locale); // Let's hope the caller doesn't use the return value return 0; } -uint32_t wrapper_mmap(uint8_t *mem, uint32_t addr, uint32_t length, int prot, int flags, int fd, int offset) { +uint32_t wrapper_mmap(uint8_t* mem, uint32_t addr, uint32_t length, int prot, int flags, int fd, int offset) { + if (addr == 0 && prot == (prot & 3) && flags == 2) { + // Read/write, map private. Just make a copy. + uint8_t* ptr = mmap(0, length, PROT_READ, MAP_PRIVATE, fd, offset); + if (ptr == MAP_FAILED) { + MEM_U32(ERRNO_ADDR) = errno; + return -1; + } + uint32_t out = wrapper_malloc(mem, length); + for (uint32_t i = 0; i < length; i++) { + MEM_S8(out + i) = ptr[i]; + } + munmap(ptr, length); + return out; + } assert(0 && "mmap not implemented"); return 0; } -int wrapper_munmap(uint8_t *mem, uint32_t addr, uint32_t length) { - assert(0 && "munmap not implemented"); +int wrapper_munmap(uint8_t* mem, uint32_t addr, uint32_t length) { return 0; } -int wrapper_mprotect(uint8_t *mem, uint32_t addr, uint32_t length, int prot) { +int wrapper_mprotect(uint8_t* mem, uint32_t addr, uint32_t length, int prot) { assert(0 && "mprotect not implemented"); return 0; } -int wrapper_sysconf(uint8_t *mem, int name) { +int wrapper_sysconf(uint8_t* mem, int name) { assert(0 && "sysconf not implemented"); return 0; } -int wrapper_getpagesize(uint8_t *mem) { +int wrapper_getpagesize(uint8_t* mem) { return 4096; } -int wrapper_strerror(uint8_t *mem, int errnum) { +int wrapper_strerror(uint8_t* mem, int errnum) { errno = errnum; perror("strerror"); assert(0 && "strerror not implemented"); return 0; } -int wrapper_ioctl(uint8_t *mem, int fd, uint32_t request, uint32_t sp) { +int wrapper_ioctl(uint8_t* mem, int fd, uint32_t request, uint32_t sp) { assert(0 && "ioctl not implemented"); return 0; } -int wrapper_fcntl(uint8_t *mem, int fd, int cmd, uint32_t sp) { +int wrapper_fcntl(uint8_t* mem, int fd, int cmd, uint32_t sp) { assert(0 && "fcntl not implemented"); return 0; } static void signal_handler(int signum) { uint32_t level = signal_context.recursion_level++; - uint8_t *mem = signal_context.handlers[signum].mem; + uint8_t* mem = signal_context.handlers[signum].mem; uint32_t fp_dest = signal_context.handlers[signum].fp_dest; uint32_t sp = SIGNAL_HANDLER_STACK_START - 16 - level * 0x1000; signal_context.handlers[signum].trampoline(mem, sp, signum, 0, 0, 0, fp_dest); signal_context.recursion_level--; } -uint32_t wrapper_signal(uint8_t *mem, int signum, uint64_t (*trampoline)(uint8_t *mem, uint32_t sp, uint32_t a0, uint32_t a1, uint32_t a2, uint32_t a3, uint32_t fp_dest), uint32_t handler_addr, uint32_t sp) { - //assert(0 && "signal not implemented"); +uint32_t wrapper_signal(uint8_t* mem, int signum, + uint64_t (*trampoline)(uint8_t* mem, uint32_t sp, uint32_t a0, uint32_t a1, uint32_t a2, + uint32_t a3, uint32_t fp_dest), + uint32_t handler_addr, uint32_t sp) { return 0; } -uint32_t wrapper_sigset(uint8_t *mem, int signum, uint64_t (*trampoline)(uint8_t *mem, uint32_t sp, uint32_t a0, uint32_t a1, uint32_t a2, uint32_t a3, uint32_t fp_dest), uint32_t disp_addr, uint32_t sp) { +uint32_t wrapper_sigset(uint8_t* mem, int signum, + uint64_t (*trampoline)(uint8_t* mem, uint32_t sp, uint32_t a0, uint32_t a1, uint32_t a2, + uint32_t a3, uint32_t fp_dest), + uint32_t disp_addr, uint32_t sp) { void (*handler)(int) = signal_handler; if ((int)disp_addr >= -1 && (int)disp_addr <= 1) { @@ -2284,21 +2480,19 @@ uint32_t wrapper_sigset(uint8_t *mem, int signum, uint64_t (*trampoline)(uint8_t return (uint32_t)(uintptr_t)sigset(signum, handler); // for now only support SIG_DFL etc. as return value } -int wrapper_get_fpc_csr(uint8_t *mem) { - //assert(0 && "get_fpc_csr not implemented"); +int wrapper_get_fpc_csr(uint8_t* mem) { return 0; } -int wrapper_set_fpc_csr(uint8_t *mem, int csr) { - //assert(0 && "set_fpc_csr not implemented"); +int wrapper_set_fpc_csr(uint8_t* mem, int csr) { return 0; } -int wrapper_setjmp(uint8_t *mem, uint32_t addr) { +int wrapper_setjmp(uint8_t* mem, uint32_t addr) { return 0; } -void wrapper_longjmp(uint8_t *mem, uint32_t addr, int status) { +void wrapper_longjmp(uint8_t* mem, uint32_t addr, int status) { assert(0 && "longjmp not implemented"); } @@ -2342,7 +2536,7 @@ uint32_t wrapper_mktemp(uint8_t *mem, uint32_t template_addr) { return template_addr; } -int wrapper_mkstemp(uint8_t *mem, uint32_t name_addr) { +int wrapper_mkstemp(uint8_t* mem, uint32_t name_addr) { STRING(name) int fd = mkstemp(name); if (fd < 0) { @@ -2353,9 +2547,21 @@ int wrapper_mkstemp(uint8_t *mem, uint32_t name_addr) { return fd; } -uint32_t wrapper_tmpfile(uint8_t *mem) { +uint32_t wrapper_tmpfile(uint8_t* mem) { // create and fopen a temporary file that is removed when the program exits - char name[] = "/tmp/copt_temp_XXXXXX"; + const char* tmpdir = getenv("TMPDIR"); + if (tmpdir == NULL) { + tmpdir = "/tmp"; + } + + char name[PATH_MAX + 1] = { 0 }; + int n = snprintf(name, sizeof(name), "%s/copt_temp_XXXXXX", tmpdir); + if (n < 0 || n >= sizeof(name)) { + // This isn't the best errno code, but it is one that can be returned by tmpfile + MEM_U32(ERRNO_ADDR) = EACCES; + return 0; + } + int fd = mkstemp(name); if (fd < 0) { MEM_U32(ERRNO_ADDR) = errno; @@ -2373,14 +2579,14 @@ uint32_t wrapper_tmpfile(uint8_t *mem) { return ret; } -int wrapper_wait(uint8_t *mem, uint32_t wstatus_addr) { +int wrapper_wait(uint8_t* mem, uint32_t wstatus_addr) { int wstatus; pid_t ret = wait(&wstatus); MEM_S32(wstatus_addr) = wstatus; return ret; } -int wrapper_kill(uint8_t *mem, int pid, int sig) { +int wrapper_kill(uint8_t* mem, int pid, int sig) { int ret = kill(pid, sig); if (ret != 0) { MEM_U32(ERRNO_ADDR) = errno; @@ -2388,23 +2594,23 @@ int wrapper_kill(uint8_t *mem, int pid, int sig) { return ret; } -int wrapper_execlp(uint8_t *mem, uint32_t file_addr, uint32_t sp) { +int wrapper_execlp(uint8_t* mem, uint32_t file_addr, uint32_t sp) { uint32_t argv_addr = sp + 4; return wrapper_execvp(mem, file_addr, argv_addr); } -int wrapper_execv(uint8_t *mem, uint32_t pathname_addr, uint32_t argv_addr) { +int wrapper_execv(uint8_t* mem, uint32_t pathname_addr, uint32_t argv_addr) { STRING(pathname) uint32_t argc = 0; while (MEM_U32(argv_addr + argc * 4) != 0) { ++argc; } - char *argv[argc + 1]; + char* argv[argc + 1]; for (uint32_t i = 0; i < argc; i++) { uint32_t str_addr = MEM_U32(argv_addr + i * 4); uint32_t len = wrapper_strlen(mem, str_addr) + 1; - argv[i] = (char *)malloc(len); - char *pos = argv[i]; + argv[i] = (char*)malloc(len); + char* pos = argv[i]; while (len--) { *pos++ = MEM_S8(str_addr); ++str_addr; @@ -2419,18 +2625,18 @@ int wrapper_execv(uint8_t *mem, uint32_t pathname_addr, uint32_t argv_addr) { return -1; } -int wrapper_execvp(uint8_t *mem, uint32_t file_addr, uint32_t argv_addr) { +int wrapper_execvp(uint8_t* mem, uint32_t file_addr, uint32_t argv_addr) { STRING(file) uint32_t argc = 0; while (MEM_U32(argv_addr + argc * 4) != 0) { ++argc; } - char *argv[argc + 1]; + char* argv[argc + 1]; for (uint32_t i = 0; i < argc; i++) { uint32_t str_addr = MEM_U32(argv_addr + i * 4); uint32_t len = wrapper_strlen(mem, str_addr) + 1; - argv[i] = (char *)malloc(len); - char *pos = argv[i]; + argv[i] = (char*)malloc(len); + char* pos = argv[i]; while (len--) { *pos++ = MEM_S8(str_addr); ++str_addr; @@ -2438,25 +2644,10 @@ int wrapper_execvp(uint8_t *mem, uint32_t file_addr, uint32_t argv_addr) { } argv[argc] = NULL; -#ifdef REDIRECT_USR_LIB - if (!strncmp(file, "/usr/lib/", 9) && bin_dir[0] != '\0') { - char fixed_path[PATH_MAX + 1]; -#ifdef __CYGWIN__ - int n = snprintf(fixed_path, sizeof(fixed_path), "%s/%s.exe", bin_dir, file + 9); -#else - int n = snprintf(fixed_path, sizeof(fixed_path), "%s/%s", bin_dir, file + 9); -#endif - if (n > 0 && n < sizeof(fixed_path)) { - execvp(fixed_path, argv); - } else { - execvp(file, argv); - } - } else { - execvp(file, argv); - } -#else - execvp(file, argv); -#endif + char rfile[PATH_MAX + 1]; + redirect_path(rfile, file, "/usr/lib", usr_lib_redirect); + + execvp(rfile, argv); MEM_U32(ERRNO_ADDR) = errno; for (uint32_t i = 0; i < argc; i++) { @@ -2465,7 +2656,7 @@ int wrapper_execvp(uint8_t *mem, uint32_t file_addr, uint32_t argv_addr) { return -1; } -int wrapper_fork(uint8_t *mem) { +int wrapper_fork(uint8_t* mem) { int ret = fork(); if (ret == -1) { MEM_U32(ERRNO_ADDR) = errno; @@ -2473,19 +2664,16 @@ int wrapper_fork(uint8_t *mem) { return ret; } -int wrapper_system(uint8_t *mem, uint32_t command_addr) { +int wrapper_system(uint8_t* mem, uint32_t command_addr) { STRING(command) return system(command); // no errno } -static int name_compare(uint8_t *mem, uint32_t a_addr, uint32_t b_addr) { - //printf("pc=0x00438180\n"); +static int name_compare(uint8_t* mem, uint32_t a_addr, uint32_t b_addr) { return wrapper_strcmp(mem, MEM_U32(a_addr), MEM_U32(b_addr)); } -static uint32_t tsearch_tfind(uint8_t *mem, uint32_t key_addr, uint32_t rootp_addr, uint32_t compar_addr, bool insert) { - //assert(compar_addr == 0x438180); // name_compare in as1 - +static uint32_t tsearch_tfind(uint8_t* mem, uint32_t key_addr, uint32_t rootp_addr, uint32_t compar_addr, bool insert) { if (rootp_addr == 0) { return 0; } @@ -2510,34 +2698,274 @@ static uint32_t tsearch_tfind(uint8_t *mem, uint32_t key_addr, uint32_t rootp_ad return 0; } -uint32_t wrapper_tsearch(uint8_t *mem, uint32_t key_addr, uint32_t rootp_addr, uint32_t compar_addr) { +uint32_t wrapper_tsearch(uint8_t* mem, uint32_t key_addr, uint32_t rootp_addr, uint32_t compar_addr) { return tsearch_tfind(mem, key_addr, rootp_addr, compar_addr, true); } -uint32_t wrapper_tfind(uint8_t *mem, uint32_t key_addr, uint32_t rootp_addr, uint32_t compar_addr) { +uint32_t wrapper_tfind(uint8_t* mem, uint32_t key_addr, uint32_t rootp_addr, uint32_t compar_addr) { return tsearch_tfind(mem, key_addr, rootp_addr, compar_addr, false); } -uint32_t wrapper_qsort(uint8_t *mem, uint32_t base_addr, uint32_t num, uint32_t size, uint64_t (*trampoline)(uint8_t *mem, uint32_t sp, uint32_t a0, uint32_t a1, uint32_t a2, uint32_t a3, uint32_t fp_dest), uint32_t compare_addr, uint32_t sp) { - assert(0 && "qsort not implemented"); +// qsort implementation from SGI libc, originally derived from +// https://people.ece.ubc.ca/~eddieh/glu_dox/d7/da4/qsort_8c_source.html (public domain) + +#define CMP(x, y) (int32_t)(trampoline(mem, sp, (x), (y), 0, 0, compare_addr) >> 32) + +static void qst(uint8_t* mem, uint32_t start, uint32_t end, fptr_trampoline trampoline, uint32_t compare_addr, + uint32_t sp, uint32_t size, uint32_t minSortSize, uint32_t medianOfThreeThreshold); + +uint32_t wrapper_qsort(uint8_t* mem, uint32_t base_addr, uint32_t count, uint32_t size, fptr_trampoline trampoline, + uint32_t compare_addr, uint32_t sp) { + uint32_t end; + uint32_t it; + uint32_t prevIt; + uint32_t byteIt; + uint32_t hi; + uint32_t insPos; + uint32_t cur; + uint32_t smallest; + uint8_t temp; + + if (count < 2) { + return 0; + } + + end = base_addr + (count * size); + + if (count >= 4) { + // run a rough quicksort + qst(mem, base_addr, end, trampoline, compare_addr, sp, size, size * 4, size * 6); + // the smallest element will be one of the first 4 + hi = base_addr + size * 4; + } else { + hi = end; + } + + // Find the smallest element and swap it to the front + smallest = base_addr; + for (it = base_addr + size; it < hi; it += size) { + if (CMP(smallest, it) > 0) { + smallest = it; + } + } + + if (smallest != base_addr) { + for (it = base_addr; it < base_addr + size; smallest++, it++) { + temp = MEM_U8(smallest); + MEM_U8(smallest) = MEM_U8(it); + MEM_U8(it) = temp; + } + } + + // Do insertion sort on the rest of the elements + for (cur = base_addr + size; cur < end; cur += size) { + + // Find where cur should go + insPos = cur - size; + while (CMP(insPos, cur) > 0) { + if (base_addr == insPos) { + // This isn't logically possible, because we've put the smallest element first. + // But it can happen if the comparator function is faulty, and it's best not to + // write out of bounds in that situation. + break; + } + insPos -= size; + } + insPos += size; + + if (insPos == cur) { + continue; + } + + for (byteIt = cur + size; --byteIt >= cur;) { + temp = MEM_U8(byteIt); + prevIt = byteIt; + for (it = byteIt - size; it >= insPos; it -= size) { + MEM_U8(prevIt) = MEM_U8(it); + prevIt = it; + } + MEM_U8(prevIt) = temp; + } + } + return 0; } -uint32_t wrapper_regcmp(uint8_t *mem, uint32_t string1_addr, uint32_t sp) { +static void qst(uint8_t* mem, uint32_t start, uint32_t end, fptr_trampoline trampoline, uint32_t compare_addr, + uint32_t sp, uint32_t size, uint32_t minSortSize, uint32_t medianOfThreeThreshold) { + uint32_t sizeAfterPivot; + uint32_t sizeBeforePivot; + uint32_t totalSize; + int32_t i; + uint32_t afterPivot; + uint32_t last; + uint32_t newPartitionFirst; + uint32_t median; + uint32_t partitionFirst; + uint32_t partitionLast; + uint32_t pivot; + uint32_t swapWith; + uint8_t temp; + + totalSize = end - start; + do { + last = end - size; + pivot = partitionFirst = (((totalSize / size) >> 1) * size) + start; + if (totalSize >= medianOfThreeThreshold) { + // compute median of three + median = CMP(start, pivot) > 0 ? start : pivot; + if (CMP(median, last) > 0) { + median = median == start ? pivot : start; + median = CMP(median, last) < 0 ? last : median; + } + + // swap the median so it ends up in the middle + if (median != pivot) { + // Fake-match: use partitionFirst here instead of e.g. swapWith. + i = size; + do { + temp = MEM_U8(partitionFirst); + MEM_U8(partitionFirst) = MEM_U8(median); + MEM_U8(median) = temp; + partitionFirst++; + median++; + i--; + } while (i != 0); + } + } + + // Partition the elements start, ..., pivot, ..., last, such that values smaller than the + // pivot are on the left, and values greater than the pivot are on the right (equal ones can + // go wherever). The pivot may end up getting swapped into another position in the process. + + partitionFirst = start; + partitionLast = last; + + // Loop invariant: Elements partitionFirst, ..., partitionLast remain to be partitioned, + // and pivot is in that range. + for (;;) { + while (partitionFirst < pivot && CMP(partitionFirst, pivot) < 0) { + // Skip over smaller values on the left. + partitionFirst += size; + } + + while (pivot < partitionLast) { + if (CMP(pivot, partitionLast) < 0) { + // Skip over greater values on the right. + partitionLast -= size; + } else { + // We have found a value we cannot skip over. Put it at the front. + // If the pivot was at the front, it gets swapped to the last position, + // otherwise, the value at the front is something we know isn't smaller + // than the pivot, so we can skip partitioning it. + newPartitionFirst = partitionFirst + size; + if (partitionFirst == pivot) { + swapWith = partitionLast; + pivot = partitionLast; + } else { + swapWith = partitionLast; + partitionLast -= size; + } + goto swapFront; + } + } + + // We have hit up against the pivot at the end. Swap it to the front to we can + // skip over it. The front element is known to not be smaller than the pivot, + // except if the pivot is at the front also, i.e. if the range has been reduced + // down to size 1 -- in that case it's time to break out of the loop. + partitionLast -= size; + if (partitionFirst == pivot) { + break; + } + swapWith = pivot; + pivot = partitionFirst; + newPartitionFirst = partitionFirst; + + swapFront: + i = size; + do { + temp = MEM_U8(partitionFirst); + MEM_U8(partitionFirst) = MEM_U8(swapWith); + MEM_U8(swapWith) = temp; + partitionFirst++; + swapWith++; + i--; + } while (i != 0); + partitionFirst = newPartitionFirst; + } + + afterPivot = pivot + size; + sizeBeforePivot = pivot - start; + sizeAfterPivot = end - afterPivot; + totalSize = sizeBeforePivot; + if (sizeAfterPivot >= sizeBeforePivot) { + if (sizeBeforePivot >= minSortSize) { + qst(mem, start, pivot, trampoline, compare_addr, sp, size, minSortSize, medianOfThreeThreshold); + } + start = afterPivot; + totalSize = sizeAfterPivot; + } else { + if (sizeAfterPivot >= minSortSize) { + qst(mem, afterPivot, end, trampoline, compare_addr, sp, size, minSortSize, medianOfThreeThreshold); + } + end = pivot; + } + } while (totalSize >= minSortSize); +} + +#undef CMP + +uint32_t wrapper_regcmp(uint8_t* mem, uint32_t string1_addr, uint32_t sp) { STRING(string1); fprintf(stderr, "regex string: %s\n", string1); assert(0 && "regcmp not implemented"); return 0; } -uint32_t wrapper_regex(uint8_t *mem, uint32_t re_addr, uint32_t subject_addr, uint32_t sp) { +uint32_t wrapper_regex(uint8_t* mem, uint32_t re_addr, uint32_t subject_addr, uint32_t sp) { STRING(subject); assert(0 && "regex not implemented"); return 0; } -void wrapper___assert(uint8_t *mem, uint32_t assertion_addr, uint32_t file_addr, int line) { +void wrapper___assert(uint8_t* mem, uint32_t assertion_addr, uint32_t file_addr, int line) { STRING(assertion) STRING(file) __assert(assertion, file, line); } + +union host_doubleword { + uint64_t ww; + double d; +}; + +union FloatReg FloatReg_from_double(double d) { + union host_doubleword val; + union FloatReg floatreg; + + val.d = d; + + floatreg.w[0] = val.ww & 0xFFFFFFFF; + floatreg.w[1] = (val.ww >> 32) & 0xFFFFFFFF; + + return floatreg; +} + +double double_from_FloatReg(union FloatReg floatreg) { + union host_doubleword val; + + val.ww = floatreg.w[1]; + val.ww <<= 32; + val.ww |= floatreg.w[0]; + return val.d; +} + +double double_from_memory(uint8_t* mem, uint32_t address) { + union host_doubleword val; + + val.ww = MEM_U32(address); + val.ww <<= 32; + val.ww |= MEM_U32(address + 4); + return val.d; +} diff --git a/tools/ido5.3_recomp/libc_impl.h b/tools/ido-static-recomp/libc_impl.h similarity index 93% rename from tools/ido5.3_recomp/libc_impl.h rename to tools/ido-static-recomp/libc_impl.h index 0f1d920f..b9f50b37 100644 --- a/tools/ido5.3_recomp/libc_impl.h +++ b/tools/ido-static-recomp/libc_impl.h @@ -1,5 +1,14 @@ +#ifndef LIBC_IMPL_H +#define LIBC_IMPL_H + #include +union FloatReg { + float f[2]; + uint32_t w[2]; + //double d; +}; + void mmap_initial_data_range(uint8_t *mem, uint32_t start, uint32_t end); void setup_libc_data(uint8_t *mem); @@ -31,6 +40,8 @@ int wrapper_atol(uint8_t *mem, uint32_t nptr_addr); double wrapper_atof(uint8_t *mem, uint32_t nptr_addr); int wrapper_strtol(uint8_t *mem, uint32_t nptr_addr, uint32_t endptr_addr, int base); uint32_t wrapper_strtoul(uint8_t *mem, uint32_t nptr_addr, uint32_t endptr_addr, int base); +int64_t wrapper_strtoll(uint8_t *mem, uint32_t nptr_addr, uint32_t endptr_addr, int base); +uint64_t wrapper_strtoull(uint8_t *mem, uint32_t nptr_addr, uint32_t endptr_addr, int base); double wrapper_strtod(uint8_t *mem, uint32_t nptr_addr, uint32_t endptr_addr); uint32_t wrapper_strchr(uint8_t *mem, uint32_t str_addr, int c); uint32_t wrapper_strrchr(uint8_t *mem, uint32_t str_addr, int c); @@ -39,6 +50,7 @@ uint32_t wrapper_strpbrk(uint8_t *mem, uint32_t str_addr, uint32_t accept_addr); int wrapper_fstat(uint8_t *mem, int fildes, uint32_t buf_addr); int wrapper_stat(uint8_t *mem, uint32_t pathname_addr, uint32_t buf_addr); int wrapper_ftruncate(uint8_t *mem, int fd, int length); +int wrapper_truncate(uint8_t *mem, uint32_t pathname_addr, int length); void wrapper_bcopy(uint8_t *mem, uint32_t src_addr, uint32_t dst_addr, uint32_t len); uint32_t wrapper_memcpy(uint8_t *mem, uint32_t dst_addr, uint32_t src_addr, uint32_t len); uint32_t wrapper_memccpy(uint8_t *mem, uint32_t dst_addr, uint32_t src_addr, int c, uint32_t len); @@ -48,6 +60,7 @@ uint32_t wrapper_fopen(uint8_t *mem, uint32_t path_addr, uint32_t mode_addr); uint32_t wrapper_freopen(uint8_t *mem, uint32_t path_addr, uint32_t mode_addr, uint32_t fp_addr); int wrapper_fclose(uint8_t *mem, uint32_t fp_addr); int wrapper_fflush(uint8_t *mem, uint32_t fp_addr); +int wrapper_fchown(uint8_t *mem, int fd, int owner, int group); int wrapper_ftell(uint8_t *mem, uint32_t fp_addr); void wrapper_rewind(uint8_t *mem, uint32_t fp_addr); int wrapper_fseek(uint8_t *mem, uint32_t fp_addr, int offset, int origin); @@ -101,10 +114,10 @@ int wrapper_time(uint8_t *mem, uint32_t tloc_addr); void wrapper_bzero(uint8_t *mem, uint32_t str_addr, uint32_t n); int wrapper_fp_class_d(double d); double wrapper_ldexp(double d, int i); -int64_t wrapper___ll_mul(int64_t a0, int64_t a1); +uint64_t wrapper___ll_mul(uint64_t a0, uint64_t a1); int64_t wrapper___ll_div(int64_t a0, int64_t a1); int64_t wrapper___ll_rem(uint64_t a0, int64_t a1); -int64_t wrapper___ll_lshift(int64_t a0, uint64_t shift); +uint64_t wrapper___ll_lshift(uint64_t a0, uint64_t shift); int64_t wrapper___ll_rshift(int64_t a0, uint64_t shift); uint64_t wrapper___ull_div(uint64_t a0, uint64_t a1); uint64_t wrapper___ull_rem(uint64_t a0, uint64_t a1); @@ -161,3 +174,9 @@ uint32_t wrapper_qsort(uint8_t *mem, uint32_t base_addr, uint32_t num, uint32_t uint32_t wrapper_regcmp(uint8_t *mem, uint32_t string1_addr, uint32_t sp); uint32_t wrapper_regex(uint8_t *mem, uint32_t re_addr, uint32_t subject_addr, uint32_t sp); void wrapper___assert(uint8_t *mem, uint32_t assertion_addr, uint32_t file_addr, int line); + +union FloatReg FloatReg_from_double(double d); +double double_from_FloatReg(union FloatReg floatreg); +double double_from_memory(uint8_t *mem, uint32_t address); + +#endif diff --git a/tools/ido-static-recomp/recomp.cpp b/tools/ido-static-recomp/recomp.cpp new file mode 100644 index 00000000..683e750d --- /dev/null +++ b/tools/ido-static-recomp/recomp.cpp @@ -0,0 +1,3813 @@ +#include +#include +#include +#include +#include +#include + +#include +#include +#include +#include +#include + +#include "rabbitizer.hpp" +#include "rabbitizer.h" + +#include "elf.h" + +#if defined(_WIN32) && !defined(__CYGWIN__) +#include +#endif /* _WIN32 && !__CYGWIN__ */ + +#if !defined(_MSC_VER) && !defined(__CYGWIN__) && !defined(_WIN32) +#define UNIX_PLATFORM +#endif + +#ifdef UNIX_PLATFORM +// TODO: determine if any of those headers are not required +#include +#include +#include // for __cxa_demangle +#include // for dladdr +#include +#include +#endif + +#ifndef FULL_TRACEBACK +// Change to non-zero to have full traceback, including names not exported +#define FULL_TRACEBACK 0 +#endif + +// set this to 1 when testing a new program, to verify that no false function pointers are found +#define INSPECT_FUNCTION_POINTERS 0 + +#ifndef TRACE +#define TRACE 0 +#endif + +#define LABELS_64_BIT 1 + +#ifndef DUMP_INSTRUCTIONS +// Set to non-zero to dump actual disassembly when dumping C code +#define DUMP_INSTRUCTIONS 0 +#endif + +#define u32be(x) (uint32_t)(((x & 0xff) << 24) + ((x & 0xff00) << 8) + ((x & 0xff0000) >> 8) + ((uint32_t)(x) >> 24)) +#define u16be(x) (uint16_t)(((x & 0xff) << 8) + ((x & 0xff00) >> 8)) +#define read_u32_be(buf) (uint32_t)(((buf)[0] << 24) + ((buf)[1] << 16) + ((buf)[2] << 8) + ((buf)[3])) + +#define UniqueId_cpu_li rabbitizer::InstrId::UniqueId::cpu_USERDEF_00 +#define UniqueId_cpu_la rabbitizer::InstrId::UniqueId::cpu_USERDEF_01 + +using namespace std; + +struct Edge { + uint32_t i; + uint8_t function_entry : 1; + uint8_t function_exit : 1; + uint8_t extern_function : 1; + uint8_t function_pointer : 1; +}; + +struct Insn { + // base instruction + rabbitizer::InstructionCpu instruction; + + // + bool is_global_got_memop; + bool no_following_successor; + + // patching instructions + bool patched; + // lui pairs + uint32_t patched_addr; + // immediates are 16 bits wide, but they can be either signed or unsigned + // a 32 bits signed member can hold all those possible values + int32_t patched_imms; + rabbitizer::Registers::Cpu::GprO32 lila_dst_reg; + int linked_insn; + union { + uint32_t linked_value; + float linked_float; + }; + + // jumptable instructions + uint32_t jtbl_addr; + uint32_t num_cases; + rabbitizer::Registers::Cpu::GprO32 index_reg; + + // graph + vector successors; + vector predecessors; + uint64_t b_liveout; + uint64_t b_livein; + uint64_t f_livein; + uint64_t f_liveout; + + Insn(uint32_t word, uint32_t vram) : instruction(word, vram) { + this->is_global_got_memop = false; + this->no_following_successor = false; + + this->patched = false; + this->patched_addr = 0; + this->patched_imms = 0; + this->lila_dst_reg = rabbitizer::Registers::Cpu::GprO32::GPR_O32_zero; + this->linked_insn = -1; + this->linked_value = 0; + + this->jtbl_addr = 0; + this->num_cases = 0; + this->index_reg = rabbitizer::Registers::Cpu::GprO32::GPR_O32_zero; + + this->b_liveout = 0; + this->b_livein = 0; + this->f_livein = 0; + this->f_liveout = 0; + } + + void patchInstruction(rabbitizer::InstrId::UniqueId instructionId) { + this->patched = true; + RabbitizerInstruction* innerInstr = this->instruction.getCPtr(); + innerInstr->uniqueId = (RabbitizerInstrId)(instructionId); + innerInstr->descriptor = &RabbitizerInstrDescriptor_Descriptors[innerInstr->uniqueId]; + } + + void patchAddress(rabbitizer::InstrId::UniqueId instructionId, uint32_t newAddress) { + this->patchInstruction(instructionId); + this->patched_addr = newAddress; + } + + uint32_t getAddress() const { + if (this->patched && this->patched_addr != 0) { + return this->patched_addr; + } + + if (this->instruction.hasOperandAlias(rabbitizer::OperandType::cpu_label)) { + return this->instruction.getInstrIndexAsVram(); + } + + if (this->instruction.isBranch()) { + return this->instruction.getVram() + this->instruction.getBranchOffset(); + } + + assert(!"unreachable code"); + } + + void patchImmediate(int32_t newImmediate) { + this->patched = true; + this->patched_imms = newImmediate; + } + + int32_t getImmediate() const { + if (this->patched) { + return this->patched_imms; + } + + return this->instruction.getProcessedImmediate(); + } + + std::string disassemble() const { + char buffer[0x1000]; + int32_t imm; + + switch (this->instruction.getUniqueId()) { + case UniqueId_cpu_li: + imm = this->getImmediate(); + if (imm >= 0) { + sprintf(buffer, "li %s, 0x%X", RabbitizerRegister_getNameGpr((int)this->lila_dst_reg), + imm); + } else { + sprintf(buffer, "li %s, %i", RabbitizerRegister_getNameGpr((int)this->lila_dst_reg), imm); + } + return buffer; + + case UniqueId_cpu_la: + sprintf(buffer, "la %s, 0x%X", RabbitizerRegister_getNameGpr((int)this->lila_dst_reg), + this->getAddress()); + return buffer; + + default: + return this->instruction.disassembleInstruction(0); + } + } +}; + +struct Function { + vector returns; // points to delay slots + uint32_t end_addr; // address after end + uint32_t nargs; + uint32_t nret; + bool v0_in; + bool referenced_by_function_pointer; +}; + +bool conservative; + +const uint8_t* text_section; +uint32_t text_section_len; +uint32_t text_vaddr; + +const uint8_t* rodata_section; +uint32_t rodata_section_len; +uint32_t rodata_vaddr; + +const uint8_t* data_section; +uint32_t data_section_len; +uint32_t data_vaddr; + +uint32_t bss_section_len; +uint32_t bss_vaddr; + +vector insns; +set label_addresses; +vector got_globals; +vector got_locals; +uint32_t gp_value; +uint32_t gp_value_adj; + +map symbol_names; + +vector> data_function_pointers; +set la_function_pointers; +map functions; +uint32_t main_addr; +uint32_t mcount_addr; +uint32_t procedure_table_start; +uint32_t procedure_table_len; + +#define FLAG_NO_MEM 1 +#define FLAG_VARARG 2 + +/** + * Struct containing information on external functions that are called using the wrappers in `libc_impl.c`. + * + * name: function name + * params: first char is return type, subsequent chars are argument types. Key to chars used: + * - 'v' void + * - 'i' signed int (int32_t) + * - 'u' unsigned int (uint32_t) + * - 'p' pointer (uintptr_t) + * - 'f' float + * - 'd' double + * - 'l' signed long long (int64_t) + * - 'j' unsigned long long (uint64_t) + * - 't' trampoline + * + * flags: use defines above + */ +const struct ExternFunction { + const char* name; + const char* params; + int flags; +} extern_functions[] = { + { "exit", "vi", 0 }, // override exit from application + { "abort", "v", 0 }, + { "sbrk", "pi", 0 }, + { "malloc", "pu", 0 }, + { "calloc", "puu", 0 }, + { "realloc", "ppu", 0 }, + { "free", "vp", 0 }, + { "fscanf", "ipp", FLAG_VARARG }, + { "printf", "ip", FLAG_VARARG }, + { "sprintf", "ipp", FLAG_VARARG }, + { "fprintf", "ipp", FLAG_VARARG }, + { "_doprnt", "ippp", 0 }, + { "strlen", "up", 0 }, + { "open", "ipii", 0 }, + { "creat", "ipi", 0 }, + { "access", "ipi", 0 }, + { "rename", "ipp", 0 }, + { "utime", "ipp", 0 }, + { "flock", "iii", 0 }, + { "chmod", "ipu", 0 }, + { "umask", "ii", FLAG_NO_MEM }, + { "ecvt", "pdipp", 0 }, + { "fcvt", "pdipp", 0 }, + { "sqrt", "dd", FLAG_NO_MEM }, + { "sqrtf", "ff", FLAG_NO_MEM }, + { "atoi", "ip", 0 }, + { "atol", "ip", 0 }, + { "atof", "dp", 0 }, + { "strtol", "ippi", 0 }, + { "strtoul", "uppi", 0 }, + { "strtoll", "lppi", 0 }, + { "strtoull", "jppi", 0 }, + { "strtod", "dpp", 0 }, + { "strchr", "ppi", 0 }, + { "strrchr", "ppi", 0 }, + { "strcspn", "upp", 0 }, + { "strpbrk", "ppp", 0 }, + { "fstat", "iip", 0 }, + { "stat", "ipp", 0 }, + { "ftruncate", "iii", 0 }, + { "truncate", "ipi", 0}, + { "bcopy", "vppu", 0 }, + { "memcpy", "pppu", 0 }, + { "memccpy", "pppiu", 0 }, + { "read", "iipu", 0 }, + { "write", "iipu", 0 }, + { "fopen", "ppp", 0 }, + { "freopen", "pppp", 0 }, + { "fclose", "ip", 0 }, + { "ftell", "ip", 0 }, + { "rewind", "vp", 0 }, + { "fseek", "ipii", 0 }, + { "lseek", "iiii", 0 }, + { "fflush", "ip", 0 }, + { "fchown", "iiii", 0 }, + { "dup", "ii", 0 }, + { "dup2", "iii", 0 }, + { "pipe", "ip", 0 }, + { "perror", "vp", 0 }, + { "fdopen", "iip", 0 }, + { "memset", "ppiu", 0 }, + { "bcmp", "ippu", 0 }, + { "memcmp", "ippu", 0 }, + { "getpid", "i", FLAG_NO_MEM }, + { "getpgrp", "i", 0 }, + { "remove", "ip", 0 }, + { "unlink", "ip", 0 }, + { "close", "ii", 0 }, + { "strcmp", "ipp", 0 }, + { "strncmp", "ippu", 0 }, + { "strcpy", "ppp", 0 }, + { "strncpy", "pppu", 0 }, + { "strcat", "ppp", 0 }, + { "strncat", "pppu", 0 }, + { "strtok", "ppp", 0 }, + { "strstr", "ppp", 0 }, + { "strdup", "pp", 0 }, + { "toupper", "ii", FLAG_NO_MEM }, + { "tolower", "ii", FLAG_NO_MEM }, + { "gethostname", "ipu", 0 }, + { "isatty", "ii", 0 }, + { "strftime", "upupp", 0 }, + { "times", "ip", 0 }, + { "clock", "i", FLAG_NO_MEM }, + { "ctime", "pp", 0 }, + { "localtime", "pp", 0 }, + { "setvbuf", "ippiu", 0 }, + { "__semgetc", "ip", 0 }, + { "__semputc", "iip", 0 }, + { "fgetc", "ip", 0 }, + { "fgets", "ipip", 0 }, + { "__filbuf", "ip", 0 }, + { "__flsbuf", "iip", 0 }, + { "ungetc", "iip", 0 }, + { "gets", "pp", 0 }, + { "fread", "upuup", 0 }, + { "fwrite", "upuup", 0 }, + { "fputs", "ipp", 0 }, + { "puts", "ip", 0 }, + { "getcwd", "ppu", 0 }, + { "time", "ip", 0 }, + { "bzero", "vpu", 0 }, + { "fp_class_d", "id", FLAG_NO_MEM }, + { "ldexp", "ddi", FLAG_NO_MEM }, + { "__ll_mul", "lll", FLAG_NO_MEM }, + { "__ll_div", "lll", FLAG_NO_MEM }, + { "__ll_rem", "ljl", FLAG_NO_MEM }, + { "__ll_lshift", "llj", FLAG_NO_MEM }, + { "__ll_rshift", "llj", FLAG_NO_MEM }, + { "__ull_div", "jjj", FLAG_NO_MEM }, + { "__ull_rem", "jjj", FLAG_NO_MEM }, + { "__ull_rshift", "jjj", FLAG_NO_MEM }, + { "__d_to_ull", "jd", FLAG_NO_MEM }, + { "__d_to_ll", "ld", FLAG_NO_MEM }, + { "__f_to_ull", "jf", FLAG_NO_MEM }, + { "__f_to_ll", "lf", FLAG_NO_MEM }, + { "__ull_to_f", "fj", FLAG_NO_MEM }, + { "__ll_to_f", "fl", FLAG_NO_MEM }, + { "__ull_to_d", "dj", FLAG_NO_MEM }, + { "__ll_to_d", "dl", FLAG_NO_MEM }, + { "_exit", "vi", 0 }, + { "_cleanup", "v", 0 }, + { "_rld_new_interface", "pu", FLAG_VARARG }, + { "_exithandle", "v", 0 }, + { "_prctl", "ii", FLAG_VARARG }, + { "_atod", "dpii", 0 }, + { "pathconf", "ipi", 0 }, + { "getenv", "pp", 0 }, + { "gettxt", "ppp", 0 }, + { "setlocale", "pip", 0 }, + { "mmap", "ppuiiii", 0 }, + { "munmap", "ipu", 0 }, + { "mprotect", "ipui", 0 }, + { "sysconf", "ii", 0 }, + { "getpagesize", "i", 0 }, + { "strerror", "pi", 0 }, + { "ioctl", "iiu", FLAG_VARARG }, + { "fcntl", "iii", FLAG_VARARG }, + { "signal", "pit", 0 }, + { "sigset", "pit", 0 }, + { "get_fpc_csr", "i", 0 }, + { "set_fpc_csr", "ii", 0 }, + { "setjmp", "ip", 0 }, + { "longjmp", "vpi", 0 }, + { "tempnam", "ppp", 0 }, + { "tmpnam", "pp", 0 }, + { "mktemp", "pp", 0 }, + { "mkstemp", "ip", 0 }, + { "tmpfile", "p", 0 }, + { "wait", "ip", 0 }, + { "kill", "iii", 0 }, + { "execlp", "ip", FLAG_VARARG }, + { "execv", "ipp", 0 }, + { "execvp", "ipp", 0 }, + { "fork", "i", 0 }, + { "system", "ip", 0 }, + { "tsearch", "pppp", 0 }, + { "tfind", "pppp", 0 }, + { "qsort", "vpuut", 0 }, + { "regcmp", "pp", FLAG_VARARG }, + { "regex", "ppp", FLAG_VARARG }, + { "__assert", "vppi", 0 }, +}; + +void disassemble(void) { + uint32_t i; + + RabbitizerConfig_Cfg.misc.omit0XOnSmallImm = true; + RabbitizerConfig_Cfg.misc.opcodeLJust -= 8; + RabbitizerConfig_Cfg.misc.upperCaseImm = false; + insns.reserve(1 + text_section_len / sizeof(uint32_t)); // +1 for dummy instruction + + for (i = 0; i < text_section_len; i += sizeof(uint32_t)) { + uint32_t word = read_u32_be(&text_section[i]); + Insn insn(word, text_vaddr + i); + insns.push_back(insn); + } + + { + // Add dummy NOP instruction to avoid out of bounds + Insn insn(0x00000000, text_vaddr + i); + insn.no_following_successor = true; + insns.push_back(insn); + } +} + +void add_function(uint32_t addr) { + if (addr >= text_vaddr && addr < text_vaddr + text_section_len) { + functions[addr]; + } +} + +map::iterator find_function(uint32_t addr) { + if (functions.size() == 0) { + return functions.end(); + } + + auto it = functions.upper_bound(addr); + + if (it == functions.begin()) { + return functions.end(); + } + + --it; + return it; +} + +rabbitizer::Registers::Cpu::GprO32 get_dest_reg(const Insn& insn) { + switch (insn.instruction.getUniqueId()) { + case rabbitizer::InstrId::UniqueId::cpu_jalr: + // jalr technically modifies rd, so an empty case is here to avoid crashing + break; + + case UniqueId_cpu_li: + case UniqueId_cpu_la: + return insn.lila_dst_reg; + + default: + if (insn.instruction.modifiesRt()) { + return insn.instruction.GetO32_rt(); + } else if (insn.instruction.modifiesRd()) { + return insn.instruction.GetO32_rd(); + } + break; + } + + return rabbitizer::Registers::Cpu::GprO32::GPR_O32_zero; +} + +// try to find a matching LUI for a given register +void link_with_lui(int offset, rabbitizer::Registers::Cpu::GprO32 reg, int mem_imm) { +#define MAX_LOOKBACK 128 + // don't attempt to compute addresses for zero offset + // end search after some sane max number of instructions + int end_search = std::max(0, offset - MAX_LOOKBACK); + + for (int search = offset - 1; search >= end_search; search--) { + switch (insns[search].instruction.getUniqueId()) { + case rabbitizer::InstrId::UniqueId::cpu_lui: + if (reg == insns[search].instruction.GetO32_rt()) { + goto loop_end; + } + continue; + + case rabbitizer::InstrId::UniqueId::cpu_lw: + case rabbitizer::InstrId::UniqueId::cpu_ld: + case rabbitizer::InstrId::UniqueId::cpu_addiu: + case rabbitizer::InstrId::UniqueId::cpu_add: + case rabbitizer::InstrId::UniqueId::cpu_sub: + case rabbitizer::InstrId::UniqueId::cpu_subu: + if (reg == get_dest_reg(insns[search])) { + if ((insns[search].instruction.getUniqueId() == rabbitizer::InstrId::UniqueId::cpu_lw) && + insns[search].instruction.GetO32_rs() == rabbitizer::Registers::Cpu::GprO32::GPR_O32_gp) { + int mem_imm0 = insns[search].instruction.getProcessedImmediate(); + uint32_t got_entry = (mem_imm0 + gp_value_adj) / sizeof(uint32_t); + + if (got_entry < got_locals.size()) { + // used for static functions + uint32_t addr = got_locals[got_entry] + mem_imm; + insns[search].linked_insn = offset; + insns[search].linked_value = addr; + insns[offset].linked_insn = search; + insns[offset].linked_value = addr; + + // Patch instruction to contain full address + insns[search].lila_dst_reg = get_dest_reg(insns[search]); + insns[search].patchAddress(UniqueId_cpu_la, addr); + + // Patch instruction to have offset 0 + switch (insns[offset].instruction.getUniqueId()) { + case rabbitizer::InstrId::UniqueId::cpu_addiu: { + rabbitizer::Registers::Cpu::GprO32 dst_reg = insns[offset].instruction.GetO32_rt(); + insns[offset].patchInstruction(rabbitizer::InstrId::UniqueId::cpu_move); + // Patch the destination register too + insns[offset].instruction.Set_rd(dst_reg); + } + + if (addr >= text_vaddr && addr < text_vaddr + text_section_len) { + add_function(addr); + } + goto loop_end; + + case rabbitizer::InstrId::UniqueId::cpu_lb: + case rabbitizer::InstrId::UniqueId::cpu_lbu: + case rabbitizer::InstrId::UniqueId::cpu_sb: + case rabbitizer::InstrId::UniqueId::cpu_lh: + case rabbitizer::InstrId::UniqueId::cpu_lhu: + case rabbitizer::InstrId::UniqueId::cpu_sh: + case rabbitizer::InstrId::UniqueId::cpu_lw: + case rabbitizer::InstrId::UniqueId::cpu_sw: + case rabbitizer::InstrId::UniqueId::cpu_ldc1: + case rabbitizer::InstrId::UniqueId::cpu_lwc1: + case rabbitizer::InstrId::UniqueId::cpu_swc1: + insns[offset].patchImmediate(0); + goto loop_end; + + default: + assert(0 && "Unsupported instruction type"); + } + } + goto loop_end; + } else { + // ignore: reg is pointer, offset is probably struct data member + goto loop_end; + } + } + + continue; + + case rabbitizer::InstrId::UniqueId::cpu_jr: + if ((insns[search].instruction.GetO32_rs() == rabbitizer::Registers::Cpu::GprO32::GPR_O32_ra) && + (offset - search >= 2)) { + // stop looking when previous `jr ra` is hit, + // but ignore if `offset` is branch delay slot for this `jr ra` + goto loop_end; + } + continue; + + default: + continue; + } + } +loop_end:; +} + +// for a given `jalr t9`, find the matching t9 load +void link_with_jalr(int offset) { + // end search after some sane max number of instructions + int end_search = std::max(0, offset - MAX_LOOKBACK); + + for (int search = offset - 1; search >= end_search; search--) { + if (get_dest_reg(insns[search]) == rabbitizer::Registers::Cpu::GprO32::GPR_O32_t9) { + // should be a switch with returns + switch (insns[search].instruction.getUniqueId()) { + case rabbitizer::InstrId::UniqueId::cpu_lw: + case UniqueId_cpu_la: + if (insns[search].is_global_got_memop || + (insns[search].instruction.getUniqueId() == UniqueId_cpu_la)) { + insns[search].linked_insn = offset; + insns[offset].linked_insn = search; + insns[offset].linked_value = insns[search].linked_value; + + insns[offset].patchAddress(rabbitizer::InstrId::UniqueId::cpu_jal, insns[search].linked_value); + + insns[search].patchInstruction(rabbitizer::InstrId::UniqueId::cpu_nop); + insns[search].is_global_got_memop = false; + + add_function(insns[search].linked_value); + } + return; + + case rabbitizer::InstrId::UniqueId::cpu_addiu: + if (insns[search].linked_insn != -1) { + uint32_t first = insns[search].linked_insn; + + // not describing as patched since instruction not edited + insns[search].linked_insn = offset; + insns[offset].linked_insn = first; + insns[offset].linked_value = insns[search].linked_value; + } + return; + + case rabbitizer::InstrId::UniqueId::cpu_ld: + case rabbitizer::InstrId::UniqueId::cpu_addu: + case rabbitizer::InstrId::UniqueId::cpu_add: + case rabbitizer::InstrId::UniqueId::cpu_sub: + case rabbitizer::InstrId::UniqueId::cpu_subu: + return; + + default: + break; + } + } else if ((insns[search].instruction.getUniqueId() == rabbitizer::InstrId::UniqueId::cpu_jr) && + (insns[search].instruction.GetO32_rs() == rabbitizer::Registers::Cpu::GprO32::GPR_O32_ra)) { + // stop looking when previous `jr ra` is hit + return; + } + } +} + +// TODO: uniformise use of insn vs insns[i] +void pass1(void) { + for (size_t i = 0; i < insns.size(); i++) { + Insn& insn = insns[i]; + + // TODO: replace with BAL. Or just fix properly + if (insn.instruction.getUniqueId() == rabbitizer::InstrId::UniqueId::cpu_bal) { + insn.patchAddress(rabbitizer::InstrId::UniqueId::cpu_jal, + insn.instruction.getVram() + insn.instruction.getBranchOffset()); + } + + if (insn.instruction.isJump()) { + if (insn.instruction.getUniqueId() == rabbitizer::InstrId::UniqueId::cpu_jal || + insn.instruction.getUniqueId() == rabbitizer::InstrId::UniqueId::cpu_j) { + uint32_t target = insn.getAddress(); + + label_addresses.insert(target); + add_function(target); + } else if (insn.instruction.getUniqueId() == rabbitizer::InstrId::UniqueId::cpu_jr) { + // sltiu $at, $ty, z + // sw $reg, offset($sp) (very seldom, one or more, usually in func entry) + // lw $gp, offset($sp) (if PIC, and very seldom) + // beqz $at, .L + // some other instruction (not always) + // lui $at, %hi(jtbl) + // sll $tx, $ty, 2 + // addu $at, $at, $tx + // lw $tx, %lo(jtbl)($at) + // nop (code compiled with 5.3) + // addu $tx, $tx, $gp (if PIC) + // jr $tx + + // IDO 7.1: + // lw at,offset(gp) + // andi t9,t8,0x3f + // sll t9,t9,0x2 + // addu at,at,t9 + // lw t9,offset(at) + // addu t9,t9,gp + // jr t9 + + // IDO 5.3: + // lw at,offset(gp) + // andi t3,t2,0x3f + // sll t3,t3,0x2 + // addu at,at,t3 + // something + // lw t3,offset(at) + // something + // addu t3,t3,gp + // jr t3 + if (i >= 7 && rodata_section != NULL) { + bool is_pic = + (insns[i - 1].instruction.getUniqueId() == rabbitizer::InstrId::UniqueId::cpu_addu) && + (insns[i - 1].instruction.GetO32_rt() == rabbitizer::Registers::Cpu::GprO32::GPR_O32_gp); + bool has_nop = + insns[i - is_pic - 1].instruction.getUniqueId() == rabbitizer::InstrId::UniqueId::cpu_nop; + bool has_extra = insns[i - is_pic - has_nop - 5].instruction.getUniqueId() != + rabbitizer::InstrId::UniqueId::cpu_beqz; + int lw = i - (int)is_pic - (int)has_nop - 1; + + if (insns[lw].instruction.getUniqueId() != rabbitizer::InstrId::UniqueId::cpu_lw) { + --lw; + } + + if ((insns[lw].instruction.getUniqueId() == rabbitizer::InstrId::UniqueId::cpu_lw) && + (insns[lw].linked_insn != -1)) { + int sltiu_index = -1; + int andi_index = -1; + uint32_t addu_index = lw - 1; + uint32_t num_cases; + bool found = false; + bool and_variant = false; + int end = 14; + + if (insns[addu_index].instruction.getUniqueId() != rabbitizer::InstrId::UniqueId::cpu_addu) { + --addu_index; + } + + if (insns[addu_index].instruction.getUniqueId() != rabbitizer::InstrId::UniqueId::cpu_addu) { + goto skip; + } + + if (insns[addu_index - 1].instruction.getUniqueId() != rabbitizer::InstrId::UniqueId::cpu_sll) { + goto skip; + } + + if (get_dest_reg(insns[addu_index - 1]) != insn.instruction.GetO32_rs()) { + goto skip; + } + + for (int j = 3; j <= 4; j++) { + if (insns[lw - j].instruction.getUniqueId() == rabbitizer::InstrId::UniqueId::cpu_andi) { + andi_index = lw - j; + break; + } + } + + if (i == 368393) { + // In copt + end = 18; + } + + for (int j = 5; j <= end; j++) { + if ((insns[lw - has_extra - j].instruction.getUniqueId() == + rabbitizer::InstrId::UniqueId::cpu_sltiu) && + (insns[lw - has_extra - j].instruction.GetO32_rt() == + rabbitizer::Registers::Cpu::GprO32::GPR_O32_at)) { + sltiu_index = j; + break; + } + + if (insns[lw - has_extra - j].instruction.getUniqueId() == + rabbitizer::InstrId::UniqueId::cpu_jr) { + // Prevent going into a previous switch + break; + } + } + + if (sltiu_index != -1) { + andi_index = -1; + } + + if (sltiu_index != -1 && insns[lw - has_extra - sltiu_index].instruction.getUniqueId() == + rabbitizer::InstrId::UniqueId::cpu_sltiu) { + num_cases = insns[lw - has_extra - sltiu_index].instruction.getProcessedImmediate(); + found = true; + } else if (andi_index != -1) { + num_cases = insns[andi_index].instruction.getProcessedImmediate() + 1; + found = true; + and_variant = true; + } else if (i == 219382) { + // Special hard case in copt where the initial sltiu is in another basic block + found = true; + num_cases = 13; + } else if (i == 370995) { + // Special hard case in copt where the initial sltiu is in another basic block + found = true; + num_cases = 12; + } + + if (found) { + uint32_t jtbl_addr = insns[lw].linked_value; + + if (is_pic) { + insns[i - 1].patchInstruction(rabbitizer::InstrId::UniqueId::cpu_nop); + } + + insn.jtbl_addr = jtbl_addr; + insn.num_cases = num_cases; + insn.index_reg = insns[addu_index - 1].instruction.GetO32_rt(); + insns[lw].patchInstruction(rabbitizer::InstrId::UniqueId::cpu_nop); + + insns[addu_index].patchInstruction(rabbitizer::InstrId::UniqueId::cpu_nop); + + insns[addu_index - 1].patchInstruction(rabbitizer::InstrId::UniqueId::cpu_nop); + + if (!and_variant) { + insns[addu_index - 2].patchInstruction(rabbitizer::InstrId::UniqueId::cpu_nop); + } + + if (jtbl_addr < rodata_vaddr || + jtbl_addr + num_cases * sizeof(uint32_t) > rodata_vaddr + rodata_section_len) { + fprintf(stderr, "jump table outside rodata\n"); + exit(EXIT_FAILURE); + } + + for (uint32_t i = 0; i < num_cases; i++) { + uint32_t target_addr = + read_u32_be(rodata_section + (jtbl_addr - rodata_vaddr) + i * sizeof(uint32_t)); + + target_addr += gp_value; + // printf("%08X\n", target_addr); + label_addresses.insert(target_addr); + } + } + skip:; + } + } + } else if (insn.instruction.getUniqueId() == rabbitizer::InstrId::UniqueId::cpu_jalr) { + // empty + } else { + assert(!"Unreachable code"); + } + } else if (insn.instruction.isBranch()) { + uint32_t target = insn.getAddress(); + + label_addresses.insert(target); + } + + switch (insns[i].instruction.getUniqueId()) { + // find floating point LI + case rabbitizer::InstrId::UniqueId::cpu_mtc1: { + rabbitizer::Registers::Cpu::GprO32 rt = insns[i].instruction.GetO32_rt(); + + for (int s = i - 1; s >= 0; s--) { + switch (insns[s].instruction.getUniqueId()) { + case rabbitizer::InstrId::UniqueId::cpu_lui: + if (insns[s].instruction.GetO32_rt() == rt) { + float f; + uint32_t lui_imm = insns[s].instruction.getProcessedImmediate() << 16; + + memcpy(&f, &lui_imm, sizeof(f)); + // link up the LUI with this instruction and the float + insns[s].linked_insn = i; + insns[s].linked_float = f; + // rewrite LUI instruction to be LI + insns[s].lila_dst_reg = get_dest_reg(insns[s]); + insns[s].patchInstruction(UniqueId_cpu_li); + insns[s].patchImmediate(lui_imm); + } + goto loop_end; + + case rabbitizer::InstrId::UniqueId::cpu_lw: + case rabbitizer::InstrId::UniqueId::cpu_ld: + case rabbitizer::InstrId::UniqueId::cpu_lh: + case rabbitizer::InstrId::UniqueId::cpu_lhu: + case rabbitizer::InstrId::UniqueId::cpu_lb: + case rabbitizer::InstrId::UniqueId::cpu_lbu: + case rabbitizer::InstrId::UniqueId::cpu_addiu: + if (rt == insns[s].instruction.GetO32_rt()) { + goto loop_end; + } + continue; + + case rabbitizer::InstrId::UniqueId::cpu_add: + case rabbitizer::InstrId::UniqueId::cpu_sub: + case rabbitizer::InstrId::UniqueId::cpu_subu: + if (rt == insns[s].instruction.GetO32_rd()) { + goto loop_end; + } + continue; + + case rabbitizer::InstrId::UniqueId::cpu_jr: + if (insns[s].instruction.GetO32_rs() == rabbitizer::Registers::Cpu::GprO32::GPR_O32_ra) { + goto loop_end; + } + continue; + + default: + continue; + } + } + loop_end:; + } break; + + case rabbitizer::InstrId::UniqueId::cpu_sd: + case rabbitizer::InstrId::UniqueId::cpu_sw: + case rabbitizer::InstrId::UniqueId::cpu_sh: + case rabbitizer::InstrId::UniqueId::cpu_sb: + case rabbitizer::InstrId::UniqueId::cpu_lb: + case rabbitizer::InstrId::UniqueId::cpu_lbu: + case rabbitizer::InstrId::UniqueId::cpu_ld: + case rabbitizer::InstrId::UniqueId::cpu_ldl: + case rabbitizer::InstrId::UniqueId::cpu_ldr: + case rabbitizer::InstrId::UniqueId::cpu_lh: + case rabbitizer::InstrId::UniqueId::cpu_lhu: + case rabbitizer::InstrId::UniqueId::cpu_lw: + case rabbitizer::InstrId::UniqueId::cpu_lwu: + case rabbitizer::InstrId::UniqueId::cpu_ldc1: + case rabbitizer::InstrId::UniqueId::cpu_lwc1: + case rabbitizer::InstrId::UniqueId::cpu_lwc2: + case rabbitizer::InstrId::UniqueId::cpu_swc1: + case rabbitizer::InstrId::UniqueId::cpu_swc2: { + rabbitizer::Registers::Cpu::GprO32 mem_rs = insns[i].instruction.GetO32_rs(); + int32_t mem_imm = insns[i].instruction.getProcessedImmediate(); + + if (mem_rs == rabbitizer::Registers::Cpu::GprO32::GPR_O32_gp) { + unsigned int got_entry = (mem_imm + gp_value_adj) / sizeof(unsigned int); + + if (got_entry >= got_locals.size()) { + got_entry -= got_locals.size(); + if (got_entry < got_globals.size()) { + assert(insn.instruction.getUniqueId() == rabbitizer::InstrId::UniqueId::cpu_lw); + unsigned int dest_vaddr = got_globals[got_entry]; + + insns[i].is_global_got_memop = true; + insns[i].linked_value = dest_vaddr; + + // patch to LA + insns[i].lila_dst_reg = get_dest_reg(insns[i]); + insns[i].patchAddress(UniqueId_cpu_la, dest_vaddr); + } + } + } else { + link_with_lui(i, mem_rs, mem_imm); + } + } break; + + case rabbitizer::InstrId::UniqueId::cpu_addiu: + case rabbitizer::InstrId::UniqueId::cpu_ori: { + // could be insn? + rabbitizer::Registers::Cpu::GprO32 rt = insns[i].instruction.GetO32_rt(); + rabbitizer::Registers::Cpu::GprO32 rs = insns[i].instruction.GetO32_rs(); + int32_t imm = insns[i].instruction.getProcessedImmediate(); + + if (rs == rabbitizer::Registers::Cpu::GprO32::GPR_O32_zero) { // becomes LI + insns[i].lila_dst_reg = get_dest_reg(insns[i]); + insns[i].patchInstruction(UniqueId_cpu_li); + insns[i].patchImmediate(imm); + } else if (rt != rabbitizer::Registers::Cpu::GprO32::GPR_O32_gp) { // only look for LUI if rt and rs are + // the same + link_with_lui(i, rs, imm); + } + } break; + + case rabbitizer::InstrId::UniqueId::cpu_jalr: { + rabbitizer::Registers::Cpu::GprO32 rs = insn.instruction.GetO32_rs(); + + if (rs == rabbitizer::Registers::Cpu::GprO32::GPR_O32_t9) { + link_with_jalr(i); + if (insn.linked_insn != -1) { + insn.patchAddress(rabbitizer::InstrId::UniqueId::cpu_jal, insn.linked_value); + + label_addresses.insert(insn.linked_value); + add_function(insn.linked_value); + } + } + } break; + + default: + break; + } + + if ((insn.instruction.getUniqueId() == rabbitizer::InstrId::UniqueId::cpu_addu) && + (insn.instruction.GetO32_rd() == rabbitizer::Registers::Cpu::GprO32::GPR_O32_gp) && + (insn.instruction.GetO32_rs() == rabbitizer::Registers::Cpu::GprO32::GPR_O32_gp) && + (insn.instruction.GetO32_rt() == rabbitizer::Registers::Cpu::GprO32::GPR_O32_t9) && i >= 2) { + for (size_t j = i - 2; j <= i; j++) { + insns[j].patchInstruction(rabbitizer::InstrId::UniqueId::cpu_nop); + } + } + } +} + +uint32_t addr_to_i(uint32_t addr) { + return (addr - text_vaddr) / 4; +} + +void pass2(void) { + // Find returns in each function + for (size_t i = 0; i < insns.size(); i++) { + uint32_t addr = text_vaddr + i * 4; + Insn& insn = insns[i]; + + if ((insn.instruction.getUniqueId() == rabbitizer::InstrId::UniqueId::cpu_jr) && + (insn.instruction.GetO32_rs() == rabbitizer::Registers::Cpu::GprO32::GPR_O32_ra)) { + auto it = find_function(addr); + assert(it != functions.end()); + + it->second.returns.push_back(addr + 4); + } + + if (insn.instruction.getUniqueId() == UniqueId_cpu_la) { + uint32_t faddr = insn.getAddress(); + + if ((text_vaddr <= faddr) && (faddr < text_vaddr + text_section_len)) { + la_function_pointers.insert(faddr); + functions[faddr].referenced_by_function_pointer = true; +#if INSPECT_FUNCTION_POINTERS + fprintf(stderr, "la function pointer: 0x%x at 0x%x\n", faddr, addr); +#endif + } + } + } + + for (auto it = functions.begin(); it != functions.end(); ++it) { + if (it->second.returns.size() == 0) { + uint32_t i = addr_to_i(it->first); + auto str_it = symbol_names.find(it->first); + + if (str_it != symbol_names.end() && str_it->second == "__start") { + + } else if (str_it != symbol_names.end() && str_it->second == "xmalloc") { + // orig 5.3: + /* + 496bf4: 3c1c0fb9 lui gp,0xfb9 + 496bf8: 279c366c addiu gp,gp,13932 + 496bfc: 0399e021 addu gp,gp,t9 + 496c00: 27bdffd8 addiu sp,sp,-40 + 496c04: 8f858de8 lw a1,-29208(gp) + 496c08: 10000006 b 496c24 + 496c0c: afbf0020 sw ra,32(sp) + */ + + // jal alloc_new + // lui $a1, malloc_scb + // jr $ra + // nop + uint32_t alloc_new_addr = text_vaddr + (i + 7) * 4; + + insns[i].patchAddress(rabbitizer::InstrId::UniqueId::cpu_jal, alloc_new_addr); + + assert(symbol_names.count(alloc_new_addr) && symbol_names[alloc_new_addr] == "alloc_new"); + i++; + + // LA + if (insns[i + 5].instruction.getUniqueId() == UniqueId_cpu_la) { + // 7.1 + insns[i] = insns[i + 5]; + } else { + // 5.3 + insns[i] = insns[i + 3]; + } + i++; + + // JR $RA + insns[i].patched = true; + insns[i].instruction = rabbitizer::InstructionCpu(0x03E00008, insns[i].instruction.getVram()); + it->second.returns.push_back(text_vaddr + i * 4 + 4); + i++; + + for (uint32_t j = 0; j < 4; j++) { + // NOP + insns[i].patched = true; + insns[i].instruction = rabbitizer::InstructionCpu(0, insns[i].instruction.getVram()); + i++; + } + } else if (str_it != symbol_names.end() && str_it->second == "xfree") { + // jal alloc_dispose + // lui $a1, malloc_scb + // jr $ra + // nop + uint32_t alloc_dispose_addr = text_vaddr + (i + 4) * 4; + + if (symbol_names.count(alloc_dispose_addr + 4) && + symbol_names[alloc_dispose_addr + 4] == "alloc_dispose") { + alloc_dispose_addr += 4; + } + + insns[i].patchAddress(rabbitizer::InstrId::UniqueId::cpu_jal, alloc_dispose_addr); + assert(symbol_names.count(alloc_dispose_addr) && symbol_names[alloc_dispose_addr] == "alloc_dispose"); + i++; + + insns[i] = insns[i + 2]; + i++; + + // JR $RA + insns[i].patched = true; + insns[i].instruction = rabbitizer::InstructionCpu(0x03E00008, insns[i].instruction.getVram()); + it->second.returns.push_back(text_vaddr + i * 4 + 4); + i++; + + // NOP + insns[i].patched = true; + insns[i].instruction = rabbitizer::InstructionCpu(0, insns[i].instruction.getVram()); + } else if ((insns[i].instruction.getUniqueId() == rabbitizer::InstrId::UniqueId::cpu_lw) && + (insns[i + 1].instruction.getUniqueId() == rabbitizer::InstrId::UniqueId::cpu_move) && + (insns[i + 2].instruction.getUniqueId() == rabbitizer::InstrId::UniqueId::cpu_jalr)) { + /* + 408f50: 8f998010 lw t9,-32752(gp) + 408f54: 03e07821 move t7,ra + 408f58: 0320f809 jalr t9 + */ + } else if (it->first > mcount_addr) { + fprintf(stderr, "no ret: 0x%x\n", it->first); + abort(); + } + } + + auto next = it; + + ++next; + if (next == functions.end()) { + it->second.end_addr = text_vaddr + text_section_len; + } else { + it->second.end_addr = next->first; + } + } +} + +void add_edge(uint32_t from, uint32_t to, bool function_entry = false, bool function_exit = false, + bool extern_function = false, bool function_pointer = false) { + Edge fe = Edge(), be = Edge(); + + fe.i = to; + be.i = from; + fe.function_entry = function_entry; + be.function_entry = function_entry; + fe.function_exit = function_exit; + be.function_exit = function_exit; + fe.extern_function = extern_function; + be.extern_function = extern_function; + fe.function_pointer = function_pointer; + be.function_pointer = function_pointer; + insns[from].successors.push_back(fe); + insns[to].predecessors.push_back(be); +} + +void pass3(void) { + // Build graph + for (size_t i = 0; i < insns.size(); i++) { + uint32_t addr = text_vaddr + i * 4; + Insn& insn = insns[i]; + + if (insn.no_following_successor) { + continue; + } + + switch (insn.instruction.getUniqueId()) { + case rabbitizer::InstrId::UniqueId::cpu_beq: + case rabbitizer::InstrId::UniqueId::cpu_bgez: + case rabbitizer::InstrId::UniqueId::cpu_bgtz: + case rabbitizer::InstrId::UniqueId::cpu_blez: + case rabbitizer::InstrId::UniqueId::cpu_bltz: + case rabbitizer::InstrId::UniqueId::cpu_bne: + case rabbitizer::InstrId::UniqueId::cpu_beqz: + case rabbitizer::InstrId::UniqueId::cpu_bnez: + case rabbitizer::InstrId::UniqueId::cpu_bc1f: + case rabbitizer::InstrId::UniqueId::cpu_bc1t: + add_edge(i, i + 1); + add_edge(i + 1, addr_to_i(insn.getAddress())); + break; + + case rabbitizer::InstrId::UniqueId::cpu_beql: + case rabbitizer::InstrId::UniqueId::cpu_bgezl: + case rabbitizer::InstrId::UniqueId::cpu_bgtzl: + case rabbitizer::InstrId::UniqueId::cpu_blezl: + case rabbitizer::InstrId::UniqueId::cpu_bltzl: + case rabbitizer::InstrId::UniqueId::cpu_bnel: + case rabbitizer::InstrId::UniqueId::cpu_bc1fl: + case rabbitizer::InstrId::UniqueId::cpu_bc1tl: + add_edge(i, i + 1); + add_edge(i, i + 2); + add_edge(i + 1, addr_to_i(insn.getAddress())); + insns[i + 1].no_following_successor = true; // don't inspect delay slot + break; + + case rabbitizer::InstrId::UniqueId::cpu_b: + case rabbitizer::InstrId::UniqueId::cpu_j: + add_edge(i, i + 1); + add_edge(i + 1, addr_to_i(insn.getAddress())); + insns[i + 1].no_following_successor = true; // don't inspect delay slot + break; + + case rabbitizer::InstrId::UniqueId::cpu_jr: { + add_edge(i, i + 1); + + if (insn.jtbl_addr != 0) { + uint32_t jtbl_pos = insn.jtbl_addr - rodata_vaddr; + + assert(jtbl_pos < rodata_section_len && + jtbl_pos + insn.num_cases * sizeof(uint32_t) <= rodata_section_len); + + for (uint32_t j = 0; j < insn.num_cases; j++) { + uint32_t dest_addr = read_u32_be(rodata_section + jtbl_pos + j * sizeof(uint32_t)) + gp_value; + + add_edge(i + 1, addr_to_i(dest_addr)); + } + } else { + assert(insn.instruction.GetO32_rs() == rabbitizer::Registers::Cpu::GprO32::GPR_O32_ra && + "jump to address in register not supported"); + } + + insns[i + 1].no_following_successor = true; // don't inspect delay slot + break; + } + + case rabbitizer::InstrId::UniqueId::cpu_jal: { + add_edge(i, i + 1); + + uint32_t dest = insn.getAddress(); + + if (dest > mcount_addr && dest >= text_vaddr && dest < text_vaddr + text_section_len) { + add_edge(i + 1, addr_to_i(dest), true); + + auto it = functions.find(dest); + assert(it != functions.end()); + + for (uint32_t ret_instr : it->second.returns) { + add_edge(addr_to_i(ret_instr), i + 2, false, true); + } + } else { + add_edge(i + 1, i + 2, false, false, true); + } + + insns[i + 1].no_following_successor = true; // don't inspect delay slot + break; + } + + case rabbitizer::InstrId::UniqueId::cpu_jalr: + // function pointer + add_edge(i, i + 1); + add_edge(i + 1, i + 2, false, false, false, true); + insns[i + 1].no_following_successor = true; // don't inspect delay slot + break; + + default: + add_edge(i, i + 1); + break; + } + } +} + +#define GPR_O32_hi (rabbitizer::Registers::Cpu::GprO32)((int)rabbitizer::Registers::Cpu::GprO32::GPR_O32_ra + 1) +#define GPR_O32_lo (rabbitizer::Registers::Cpu::GprO32)((int)rabbitizer::Registers::Cpu::GprO32::GPR_O32_ra + 2) + +uint64_t map_reg(rabbitizer::Registers::Cpu::GprO32 reg) { + return (uint64_t)1 << ((int)reg - (int)rabbitizer::Registers::Cpu::GprO32::GPR_O32_zero + 1); +} + +uint64_t temporary_regs(void) { + // clang-format off + return + map_reg(rabbitizer::Registers::Cpu::GprO32::GPR_O32_t0) | + map_reg(rabbitizer::Registers::Cpu::GprO32::GPR_O32_t1) | + map_reg(rabbitizer::Registers::Cpu::GprO32::GPR_O32_t2) | + map_reg(rabbitizer::Registers::Cpu::GprO32::GPR_O32_t3) | + map_reg(rabbitizer::Registers::Cpu::GprO32::GPR_O32_t4) | + map_reg(rabbitizer::Registers::Cpu::GprO32::GPR_O32_t5) | + map_reg(rabbitizer::Registers::Cpu::GprO32::GPR_O32_t6) | + map_reg(rabbitizer::Registers::Cpu::GprO32::GPR_O32_t7) | + map_reg(rabbitizer::Registers::Cpu::GprO32::GPR_O32_t8) | + map_reg(rabbitizer::Registers::Cpu::GprO32::GPR_O32_t9); + // clang-format on +} + +typedef enum { + /* 0 */ TYPE_NOP, // No arguments + /* 1 */ TYPE_S, // in + /* 2 */ TYPE_D, // 1 out + /* 3 */ TYPE_D_S, // out, in +} TYPE; + +TYPE insn_to_type(Insn& insn) { + switch (insn.instruction.getUniqueId()) { + case rabbitizer::InstrId::UniqueId::cpu_add_s: + case rabbitizer::InstrId::UniqueId::cpu_add_d: + return TYPE_NOP; + + case rabbitizer::InstrId::UniqueId::cpu_add: + case rabbitizer::InstrId::UniqueId::cpu_addu: + return TYPE_D_S; + + case rabbitizer::InstrId::UniqueId::cpu_addi: + case rabbitizer::InstrId::UniqueId::cpu_addiu: + case rabbitizer::InstrId::UniqueId::cpu_andi: + case rabbitizer::InstrId::UniqueId::cpu_ori: + case rabbitizer::InstrId::UniqueId::cpu_lb: + case rabbitizer::InstrId::UniqueId::cpu_lbu: + case rabbitizer::InstrId::UniqueId::cpu_lh: + case rabbitizer::InstrId::UniqueId::cpu_lhu: + case rabbitizer::InstrId::UniqueId::cpu_lw: + case rabbitizer::InstrId::UniqueId::cpu_lwl: + // case rabbitizer::InstrId::UniqueId::cpu_lwr: + case rabbitizer::InstrId::UniqueId::cpu_move: + case rabbitizer::InstrId::UniqueId::cpu_negu: + case rabbitizer::InstrId::UniqueId::cpu_not: + case rabbitizer::InstrId::UniqueId::cpu_sll: + case rabbitizer::InstrId::UniqueId::cpu_slti: + case rabbitizer::InstrId::UniqueId::cpu_sltiu: + case rabbitizer::InstrId::UniqueId::cpu_sra: + case rabbitizer::InstrId::UniqueId::cpu_srl: + case rabbitizer::InstrId::UniqueId::cpu_xori: + return TYPE_D_S; + + case rabbitizer::InstrId::UniqueId::cpu_mfhi: + return TYPE_D_S; + + case rabbitizer::InstrId::UniqueId::cpu_mflo: + return TYPE_D_S; + + case rabbitizer::InstrId::UniqueId::cpu_and: + case rabbitizer::InstrId::UniqueId::cpu_or: + case rabbitizer::InstrId::UniqueId::cpu_nor: + case rabbitizer::InstrId::UniqueId::cpu_sllv: + case rabbitizer::InstrId::UniqueId::cpu_slt: + case rabbitizer::InstrId::UniqueId::cpu_sltu: + case rabbitizer::InstrId::UniqueId::cpu_srav: + case rabbitizer::InstrId::UniqueId::cpu_srlv: + case rabbitizer::InstrId::UniqueId::cpu_subu: + case rabbitizer::InstrId::UniqueId::cpu_xor: + return TYPE_D_S; + + case rabbitizer::InstrId::UniqueId::cpu_cfc1: + case rabbitizer::InstrId::UniqueId::cpu_mfc1: + case UniqueId_cpu_li: + case UniqueId_cpu_la: + case rabbitizer::InstrId::UniqueId::cpu_lui: + return TYPE_D; + + case rabbitizer::InstrId::UniqueId::cpu_ctc1: + case rabbitizer::InstrId::UniqueId::cpu_bgez: + case rabbitizer::InstrId::UniqueId::cpu_bgezl: + case rabbitizer::InstrId::UniqueId::cpu_bgtz: + case rabbitizer::InstrId::UniqueId::cpu_bgtzl: + case rabbitizer::InstrId::UniqueId::cpu_blez: + case rabbitizer::InstrId::UniqueId::cpu_blezl: + case rabbitizer::InstrId::UniqueId::cpu_bltz: + case rabbitizer::InstrId::UniqueId::cpu_bltzl: + case rabbitizer::InstrId::UniqueId::cpu_beqz: + case rabbitizer::InstrId::UniqueId::cpu_bnez: + case rabbitizer::InstrId::UniqueId::cpu_mtc1: + return TYPE_S; + + case rabbitizer::InstrId::UniqueId::cpu_beq: + case rabbitizer::InstrId::UniqueId::cpu_beql: + case rabbitizer::InstrId::UniqueId::cpu_bne: + case rabbitizer::InstrId::UniqueId::cpu_bnel: + case rabbitizer::InstrId::UniqueId::cpu_sb: + case rabbitizer::InstrId::UniqueId::cpu_sh: + case rabbitizer::InstrId::UniqueId::cpu_sw: + case rabbitizer::InstrId::UniqueId::cpu_swl: + // case rabbitizer::InstrId::UniqueId::cpu_swr: + case rabbitizer::InstrId::UniqueId::cpu_tne: + case rabbitizer::InstrId::UniqueId::cpu_teq: + case rabbitizer::InstrId::UniqueId::cpu_tge: + case rabbitizer::InstrId::UniqueId::cpu_tgeu: + case rabbitizer::InstrId::UniqueId::cpu_tlt: + return TYPE_S; + + case rabbitizer::InstrId::UniqueId::cpu_div: + return TYPE_D_S; + + case rabbitizer::InstrId::UniqueId::cpu_div_s: + case rabbitizer::InstrId::UniqueId::cpu_div_d: + return TYPE_NOP; + + case rabbitizer::InstrId::UniqueId::cpu_divu: + case rabbitizer::InstrId::UniqueId::cpu_mult: + case rabbitizer::InstrId::UniqueId::cpu_multu: + return TYPE_D_S; + + case rabbitizer::InstrId::UniqueId::cpu_neg_s: + case rabbitizer::InstrId::UniqueId::cpu_neg_d: + return TYPE_NOP; + + case rabbitizer::InstrId::UniqueId::cpu_jalr: + return TYPE_S; + + case rabbitizer::InstrId::UniqueId::cpu_jr: + if (insn.jtbl_addr != 0) { + insn.instruction.Set_rs(insn.index_reg); + } + if (insn.instruction.GetO32_rs() == rabbitizer::Registers::Cpu::GprO32::GPR_O32_ra) { + return TYPE_NOP; + } + return TYPE_S; + + case rabbitizer::InstrId::UniqueId::cpu_lwc1: + case rabbitizer::InstrId::UniqueId::cpu_ldc1: + case rabbitizer::InstrId::UniqueId::cpu_swc1: + case rabbitizer::InstrId::UniqueId::cpu_sdc1: + return TYPE_S; + + default: + return TYPE_NOP; + } +} + +uint64_t get_dest_reg_mask(const Insn& insn) { + switch (insn.instruction.getUniqueId()) { + case rabbitizer::InstrId::UniqueId::cpu_div: + case rabbitizer::InstrId::UniqueId::cpu_divu: + case rabbitizer::InstrId::UniqueId::cpu_mult: + case rabbitizer::InstrId::UniqueId::cpu_multu: + return map_reg(GPR_O32_lo) | map_reg(GPR_O32_hi); + + default: + return map_reg(get_dest_reg(insn)); + } +} + +uint64_t get_single_source_reg_mask(const rabbitizer::InstructionCpu& instr) { + switch (instr.getUniqueId()) { + case rabbitizer::InstrId::UniqueId::cpu_mflo: + return map_reg(GPR_O32_lo); + case rabbitizer::InstrId::UniqueId::cpu_mfhi: + return map_reg(GPR_O32_hi); + + default: + break; + } + if (instr.hasOperandAlias(rabbitizer::OperandType::cpu_rs)) { + return map_reg(instr.GetO32_rs()); + } else if (instr.hasOperandAlias(rabbitizer::OperandType::cpu_rt)) { + return map_reg(instr.GetO32_rt()); + } else { + return 0; + } +} + +uint64_t get_all_source_reg_mask(const rabbitizer::InstructionCpu& instr) { + uint64_t ret = 0; + + switch (instr.getUniqueId()) { + case rabbitizer::InstrId::UniqueId::cpu_mflo: + ret |= map_reg(GPR_O32_lo); + case rabbitizer::InstrId::UniqueId::cpu_mfhi: + ret |= map_reg(GPR_O32_hi); + + default: + break; + } + + if (instr.hasOperandAlias(rabbitizer::OperandType::cpu_rs)) { + ret |= map_reg(instr.GetO32_rs()); + } + if (instr.hasOperandAlias(rabbitizer::OperandType::cpu_rt) && !instr.modifiesRt()) { + ret |= map_reg(instr.GetO32_rt()); + } + return ret; +} + +void pass4(void) { + vector q; // TODO: Why is this called q? + uint64_t livein_func_start = 1U | map_reg(rabbitizer::Registers::Cpu::GprO32::GPR_O32_a0) | + map_reg(rabbitizer::Registers::Cpu::GprO32::GPR_O32_a1) | + map_reg(rabbitizer::Registers::Cpu::GprO32::GPR_O32_sp) | + map_reg(rabbitizer::Registers::Cpu::GprO32::GPR_O32_zero); + + q.push_back(main_addr); + insns[addr_to_i(main_addr)].f_livein = livein_func_start; + + for (auto& it : data_function_pointers) { + q.push_back(it.second); + insns[addr_to_i(it.second)].f_livein = livein_func_start | + map_reg(rabbitizer::Registers::Cpu::GprO32::GPR_O32_a2) | + map_reg(rabbitizer::Registers::Cpu::GprO32::GPR_O32_a3); + } + + for (auto& addr : la_function_pointers) { + q.push_back(addr); + insns[addr_to_i(addr)].f_livein = livein_func_start | map_reg(rabbitizer::Registers::Cpu::GprO32::GPR_O32_a2) | + map_reg(rabbitizer::Registers::Cpu::GprO32::GPR_O32_a3); + } + + while (!q.empty()) { + uint32_t addr = q.back(); + q.pop_back(); + uint32_t i = addr_to_i(addr); + Insn& insn = insns[i]; + uint64_t live = insn.f_livein | 1U; + uint64_t src_regs_map; + + switch (insn_to_type(insn)) { + case TYPE_D: + live |= get_dest_reg_mask(insn); + break; + + case TYPE_D_S: + src_regs_map = get_all_source_reg_mask(insn.instruction); + if ((live & src_regs_map) == src_regs_map) { + live |= get_dest_reg_mask(insn); + } + break; + + case TYPE_S: + case TYPE_NOP: + break; + } + + if ((insn.f_liveout | live) == insn.f_liveout) { + // No new bits + continue; + } + + live |= insn.f_liveout; + insn.f_liveout = live; + + bool function_entry = false; + + for (Edge& e : insn.successors) { + uint64_t new_live = live; + + if (e.function_exit) { + new_live &= 1U | map_reg(rabbitizer::Registers::Cpu::GprO32::GPR_O32_v0) | + map_reg(rabbitizer::Registers::Cpu::GprO32::GPR_O32_v1) | + map_reg(rabbitizer::Registers::Cpu::GprO32::GPR_O32_zero); + } else if (e.function_entry) { + new_live &= 1U | map_reg(rabbitizer::Registers::Cpu::GprO32::GPR_O32_v0) | + map_reg(rabbitizer::Registers::Cpu::GprO32::GPR_O32_a0) | + map_reg(rabbitizer::Registers::Cpu::GprO32::GPR_O32_a1) | + map_reg(rabbitizer::Registers::Cpu::GprO32::GPR_O32_a2) | + map_reg(rabbitizer::Registers::Cpu::GprO32::GPR_O32_a3) | + map_reg(rabbitizer::Registers::Cpu::GprO32::GPR_O32_sp) | + map_reg(rabbitizer::Registers::Cpu::GprO32::GPR_O32_zero); + function_entry = true; + } else if (e.extern_function) { + string_view name; + size_t extern_function_id; + uint32_t address = insns[i - 1].getAddress(); + + // TODO: Can this only ever be a J-type instruction? + auto it = symbol_names.find(address); + const ExternFunction* found_fn = nullptr; + + if (it != symbol_names.end()) { + name = it->second; + + for (auto& fn : extern_functions) { + if (name == fn.name) { + found_fn = &fn; + break; + } + } + + if (found_fn == nullptr) { + fprintf(stderr, "missing extern function: %s\n", string(name).c_str()); + } + } + + assert(found_fn); + + char ret_type = found_fn->params[0]; + + new_live &= ~(map_reg(rabbitizer::Registers::Cpu::GprO32::GPR_O32_v0) | + map_reg(rabbitizer::Registers::Cpu::GprO32::GPR_O32_a0) | + map_reg(rabbitizer::Registers::Cpu::GprO32::GPR_O32_a1) | + map_reg(rabbitizer::Registers::Cpu::GprO32::GPR_O32_a2) | + map_reg(rabbitizer::Registers::Cpu::GprO32::GPR_O32_a3) | + map_reg(rabbitizer::Registers::Cpu::GprO32::GPR_O32_v1) | temporary_regs()); + + switch (ret_type) { + case 'i': + case 'u': + case 'p': + new_live |= map_reg(rabbitizer::Registers::Cpu::GprO32::GPR_O32_v0); + break; + + case 'f': + break; + + case 'd': + break; + + case 'v': + break; + + case 'l': + case 'j': + new_live |= map_reg(rabbitizer::Registers::Cpu::GprO32::GPR_O32_v0) | + map_reg(rabbitizer::Registers::Cpu::GprO32::GPR_O32_v1); + break; + } + } else if (e.function_pointer) { + new_live &= ~(map_reg(rabbitizer::Registers::Cpu::GprO32::GPR_O32_v0) | + map_reg(rabbitizer::Registers::Cpu::GprO32::GPR_O32_a0) | + map_reg(rabbitizer::Registers::Cpu::GprO32::GPR_O32_a1) | + map_reg(rabbitizer::Registers::Cpu::GprO32::GPR_O32_a2) | + map_reg(rabbitizer::Registers::Cpu::GprO32::GPR_O32_a3) | + map_reg(rabbitizer::Registers::Cpu::GprO32::GPR_O32_v1) | temporary_regs()); + new_live |= map_reg(rabbitizer::Registers::Cpu::GprO32::GPR_O32_v0) | + map_reg(rabbitizer::Registers::Cpu::GprO32::GPR_O32_v1); + } + + if ((insns[e.i].f_livein | new_live) != insns[e.i].f_livein) { + insns[e.i].f_livein |= new_live; + q.push_back(text_vaddr + e.i * sizeof(uint32_t)); + } + } + + if (function_entry) { + // add one edge that skips the function call, for callee-saved register liveness propagation + live &= ~(map_reg(rabbitizer::Registers::Cpu::GprO32::GPR_O32_v0) | + map_reg(rabbitizer::Registers::Cpu::GprO32::GPR_O32_a0) | + map_reg(rabbitizer::Registers::Cpu::GprO32::GPR_O32_a1) | + map_reg(rabbitizer::Registers::Cpu::GprO32::GPR_O32_a2) | + map_reg(rabbitizer::Registers::Cpu::GprO32::GPR_O32_a3) | + map_reg(rabbitizer::Registers::Cpu::GprO32::GPR_O32_v1) | temporary_regs()); + + if ((insns[i + 1].f_livein | live) != insns[i + 1].f_livein) { + insns[i + 1].f_livein |= live; + q.push_back(text_vaddr + (i + 1) * sizeof(uint32_t)); + } + } + } +} + +void pass5(void) { + vector q; + + assert(functions.count(main_addr)); + + q = functions[main_addr].returns; + for (auto addr : q) { + insns[addr_to_i(addr)].b_liveout = 1U | map_reg(rabbitizer::Registers::Cpu::GprO32::GPR_O32_v0); + } + + for (auto& it : data_function_pointers) { + for (auto addr : functions[it.second].returns) { + q.push_back(addr); + insns[addr_to_i(addr)].b_liveout = 1U | map_reg(rabbitizer::Registers::Cpu::GprO32::GPR_O32_v0) | + map_reg(rabbitizer::Registers::Cpu::GprO32::GPR_O32_v1); + } + } + + for (auto& func_addr : la_function_pointers) { + for (auto addr : functions[func_addr].returns) { + q.push_back(addr); + insns[addr_to_i(addr)].b_liveout = 1U | map_reg(rabbitizer::Registers::Cpu::GprO32::GPR_O32_v0) | + map_reg(rabbitizer::Registers::Cpu::GprO32::GPR_O32_v1); + } + } + + for (auto& insn : insns) { + if (insn.f_livein != 0) { + q.push_back(insn.instruction.getVram()); + } + } + + while (!q.empty()) { + uint32_t addr = q.back(); + + q.pop_back(); + + uint32_t i = addr_to_i(addr); + Insn& insn = insns[i]; + uint64_t live = insn.b_liveout | 1; + + switch (insn_to_type(insn)) { + case TYPE_S: + live |= get_all_source_reg_mask(insn.instruction); + break; + + case TYPE_D: + live &= ~get_dest_reg_mask(insn); + break; + + case TYPE_D_S: + if (live & get_dest_reg_mask(insn)) { + live &= ~get_dest_reg_mask(insn); + live |= get_all_source_reg_mask(insn.instruction); + } + break; + + case TYPE_NOP: + break; + } + + if ((insn.b_livein | live) == insn.b_livein) { + // No new bits + continue; + } + + live |= insn.b_livein; + insn.b_livein = live; + + bool function_exit = false; + + for (Edge& e : insn.predecessors) { + uint64_t new_live = live; + + if (e.function_exit) { + new_live &= 1U | map_reg(rabbitizer::Registers::Cpu::GprO32::GPR_O32_v0) | + map_reg(rabbitizer::Registers::Cpu::GprO32::GPR_O32_v1); + function_exit = true; + } else if (e.function_entry) { + new_live &= 1U | map_reg(rabbitizer::Registers::Cpu::GprO32::GPR_O32_v0) | + map_reg(rabbitizer::Registers::Cpu::GprO32::GPR_O32_a0) | + map_reg(rabbitizer::Registers::Cpu::GprO32::GPR_O32_a1) | + map_reg(rabbitizer::Registers::Cpu::GprO32::GPR_O32_a2) | + map_reg(rabbitizer::Registers::Cpu::GprO32::GPR_O32_a3) | + map_reg(rabbitizer::Registers::Cpu::GprO32::GPR_O32_sp); + } else if (e.extern_function) { + string_view name; + size_t extern_function_id; + const ExternFunction* found_fn = nullptr; + uint32_t address = insns[i - 2].getAddress(); + // TODO: Can this only ever be a J-type instruction? + auto it = symbol_names.find(address); + + if (it != symbol_names.end()) { + name = it->second; + for (auto& fn : extern_functions) { + if (name == fn.name) { + found_fn = &fn; + break; + } + } + } + + assert(found_fn); + + uint64_t args = 1U; + + if (found_fn->flags & FLAG_VARARG) { + // Assume the worst, that all four registers are used + for (int j = 0; j < 4; j++) { + args |= map_reg((rabbitizer::Registers::Cpu::GprO32)( + (int)rabbitizer::Registers::Cpu::GprO32::GPR_O32_a0 + j)); + } + } + + int pos = 0; + int pos_float = 0; + bool only_floats_so_far = true; + + for (const char* p = found_fn->params + 1; *p != '\0'; ++p) { + switch (*p) { + case 'i': + case 'u': + case 'p': + case 't': + only_floats_so_far = false; + if (pos < 4) { + args |= map_reg((rabbitizer::Registers::Cpu::GprO32)( + (int)rabbitizer::Registers::Cpu::GprO32::GPR_O32_a0 + pos)); + } + ++pos; + break; + + case 'f': + if (only_floats_so_far && pos_float < 4) { + pos_float += 2; + } else if (pos < 4) { + args |= map_reg((rabbitizer::Registers::Cpu::GprO32)( + (int)rabbitizer::Registers::Cpu::GprO32::GPR_O32_a0 + pos)); + } + ++pos; + break; + + case 'd': + // !!! + if (pos % 1 != 0) { + ++pos; + } + if (only_floats_so_far && pos_float < 4) { + pos_float += 2; + } else if (pos < 4) { + args |= map_reg((rabbitizer::Registers::Cpu::GprO32)( + (int)rabbitizer::Registers::Cpu::GprO32::GPR_O32_a0 + pos)) | + map_reg((rabbitizer::Registers::Cpu::GprO32)( + (int)rabbitizer::Registers::Cpu::GprO32::GPR_O32_a0 + pos + 1)); + } + pos += 2; + break; + + case 'l': + case 'j': + if (pos % 1 != 0) { + ++pos; + } + only_floats_so_far = false; + if (pos < 4) { + args |= map_reg((rabbitizer::Registers::Cpu::GprO32)( + (int)rabbitizer::Registers::Cpu::GprO32::GPR_O32_a0 + pos)) | + map_reg((rabbitizer::Registers::Cpu::GprO32)( + (int)rabbitizer::Registers::Cpu::GprO32::GPR_O32_a0 + pos + 1)); + } + pos += 2; + break; + } + } + args |= map_reg(rabbitizer::Registers::Cpu::GprO32::GPR_O32_sp); + new_live &= ~(map_reg(rabbitizer::Registers::Cpu::GprO32::GPR_O32_v0) | + map_reg(rabbitizer::Registers::Cpu::GprO32::GPR_O32_a0) | + map_reg(rabbitizer::Registers::Cpu::GprO32::GPR_O32_a1) | + map_reg(rabbitizer::Registers::Cpu::GprO32::GPR_O32_a2) | + map_reg(rabbitizer::Registers::Cpu::GprO32::GPR_O32_a3) | + map_reg(rabbitizer::Registers::Cpu::GprO32::GPR_O32_v1) | temporary_regs()); + new_live |= args; + } else if (e.function_pointer) { + new_live &= ~(map_reg(rabbitizer::Registers::Cpu::GprO32::GPR_O32_v0) | + map_reg(rabbitizer::Registers::Cpu::GprO32::GPR_O32_a0) | + map_reg(rabbitizer::Registers::Cpu::GprO32::GPR_O32_a1) | + map_reg(rabbitizer::Registers::Cpu::GprO32::GPR_O32_a2) | + map_reg(rabbitizer::Registers::Cpu::GprO32::GPR_O32_a3) | + map_reg(rabbitizer::Registers::Cpu::GprO32::GPR_O32_v1) | temporary_regs()); + new_live |= map_reg(rabbitizer::Registers::Cpu::GprO32::GPR_O32_a0) | + map_reg(rabbitizer::Registers::Cpu::GprO32::GPR_O32_a1) | + map_reg(rabbitizer::Registers::Cpu::GprO32::GPR_O32_a2) | + map_reg(rabbitizer::Registers::Cpu::GprO32::GPR_O32_a3); + } + + if ((insns[e.i].b_liveout | new_live) != insns[e.i].b_liveout) { + insns[e.i].b_liveout |= new_live; + q.push_back(text_vaddr + e.i * sizeof(uint32_t)); + } + } + + if (function_exit) { + // add one edge that skips the function call, for callee-saved register liveness propagation + live &= ~(map_reg(rabbitizer::Registers::Cpu::GprO32::GPR_O32_v0) | + map_reg(rabbitizer::Registers::Cpu::GprO32::GPR_O32_a0) | + map_reg(rabbitizer::Registers::Cpu::GprO32::GPR_O32_a1) | + map_reg(rabbitizer::Registers::Cpu::GprO32::GPR_O32_a2) | + map_reg(rabbitizer::Registers::Cpu::GprO32::GPR_O32_a3) | + map_reg(rabbitizer::Registers::Cpu::GprO32::GPR_O32_v1) | temporary_regs()); + + if ((insns[i - 1].b_liveout | live) != insns[i - 1].b_liveout) { + insns[i - 1].b_liveout |= live; + q.push_back(text_vaddr + (i - 1) * sizeof(uint32_t)); + } + } + } +} + +void pass6(void) { + for (auto& it : functions) { + uint32_t addr = it.first; + Function& f = it.second; + + for (uint32_t ret : f.returns) { + Insn& i = insns[addr_to_i(ret)]; + + if (i.f_liveout & i.b_liveout & map_reg(rabbitizer::Registers::Cpu::GprO32::GPR_O32_v1)) { + f.nret = 2; + } else if ((i.f_liveout & i.b_liveout & map_reg(rabbitizer::Registers::Cpu::GprO32::GPR_O32_v0)) && + f.nret == 0) { + f.nret = 1; + } + } + + Insn& insn = insns.at(addr_to_i(addr)); + + for (int i = 0; i < 4; i++) { + if (insn.f_livein & insn.b_livein & + map_reg( + (rabbitizer::Registers::Cpu::GprO32)((int)rabbitizer::Registers::Cpu::GprO32::GPR_O32_a0 + i))) { + f.nargs = 1 + i; + } + } + f.v0_in = (insn.f_livein & insn.b_livein & map_reg(rabbitizer::Registers::Cpu::GprO32::GPR_O32_v0)) != 0 && + !f.referenced_by_function_pointer; + } +} + +void dump(void) { + for (size_t i = 0; i < insns.size(); i++) { + Insn& insn = insns[i]; + uint32_t vaddr = text_vaddr + i * sizeof(uint32_t); + if (label_addresses.count(vaddr)) { + if (symbol_names.count(vaddr)) { + printf("L%08x: //%s\n", vaddr, symbol_names[vaddr].c_str()); + } else { + printf("L%08x:\n", vaddr); + } + } + + // TODO: construct an immediate override for the instructions + printf("\t%s", insn.disassemble().c_str()); + if (insn.patched) { + printf("\t[patched, immediate now 0x%X]", insn.patched_addr); + } + printf("\n"); + } +} + +const char* r(uint32_t reg) { + static const char* regs[] = { + /* */ "zero", "at", "v0", "v1", + /* */ "a0", "a1", "a2", "a3", + /* */ "t0", "t1", "t2", "t3", "t4", "t5", "t6", "t7", + /* */ "s0", "s1", "s2", "s3", "s4", "s5", "s6", "s7", + /* */ "t8", "t9", "k0", "k1", "gp", "sp", "fp", "ra", + }; + + assert(reg < std::size(regs)); + return regs[reg]; +} + +const char* wr(uint32_t reg) { + // clang-format off + static const char *regs[] = { + "f0.w[0]", "f0.w[1]", + "f2.w[0]", "f2.w[1]", + "f4.w[0]", "f4.w[1]", + "f6.w[0]", "f6.w[1]", + "f8.w[0]", "f8.w[1]", + "f10.w[0]", "f10.w[1]", + "f12.w[0]", "f12.w[1]", + "f14.w[0]", "f14.w[1]", + "f16.w[0]", "f16.w[1]", + "f18.w[0]", "f18.w[1]", + "f20.w[0]", "f20.w[1]", + "f22.w[0]", "f22.w[1]", + "f24.w[0]", "f24.w[1]", + "f26.w[0]", "f26.w[1]", + "f28.w[0]", "f28.w[1]", + "f30.w[0]", "f30.w[1]" + }; + // clang-format on + + size_t index = reg - (int)rabbitizer::Registers::Cpu::Cop1O32::COP1_O32_fv0; + + assert(index < std::size(regs)); + return regs[index]; +} + +const char* fr(uint32_t reg) { + // clang-format off + static const char *regs[] = { + "f0.f[0]", "f0.f[1]", + "f2.f[0]", "f2.f[1]", + "f4.f[0]", "f4.f[1]", + "f6.f[0]", "f6.f[1]", + "f8.f[0]", "f8.f[1]", + "f10.f[0]", "f10.f[1]", + "f12.f[0]", "f12.f[1]", + "f14.f[0]", "f14.f[1]", + "f16.f[0]", "f16.f[1]", + "f18.f[0]", "f18.f[1]", + "f20.f[0]", "f20.f[1]", + "f22.f[0]", "f22.f[1]", + "f24.f[0]", "f24.f[1]", + "f26.f[0]", "f26.f[1]", + "f28.f[0]", "f28.f[1]", + "f30.f[0]", "f30.f[1]", + }; + // clang-format on + + size_t index = reg - (int)rabbitizer::Registers::Cpu::Cop1O32::COP1_O32_fv0; + + assert(index < std::size(regs)); + return regs[index]; +} + +const char* dr(uint32_t reg) { + // clang-format off + static const char *regs[] = { + "f0", + "f2", + "f4", + "f6", + "f8", + "f10", + "f12", + "f14", + "f16", + "f18", + "f20", + "f22", + "f24", + "f26", + "f28", + "f30" + }; + // clang-format on + + size_t index = reg - (int)rabbitizer::Registers::Cpu::Cop1O32::COP1_O32_fv0; + + assert(index % 2 == 0); + index /= 2; + assert(index < std::size(regs)); + return regs[index]; +} + +void dump_instr(int i); + +void dump_cond_branch(int i, const char* lhs, const char* op, const char* rhs) { + Insn& insn = insns[i]; + const char* cast1 = ""; + const char* cast2 = ""; + + if (strcmp(op, "==") && strcmp(op, "!=")) { + cast1 = "(int)"; + if (strcmp(rhs, "0")) { + cast2 = "(int)"; + } + } + printf("if (%s%s %s %s%s) {\n", cast1, lhs, op, cast2, rhs); + dump_instr(i + 1); + + uint32_t addr = insn.getAddress(); + + printf("goto L%x;}\n", addr); +} + +void dump_cond_branch_likely(int i, const char* lhs, const char* op, const char* rhs) { + uint32_t target = text_vaddr + (i + 2) * sizeof(uint32_t); + + dump_cond_branch(i, lhs, op, rhs); + if (!TRACE) { + printf("else goto L%x;\n", target); + } else { + printf("else {printf(\"pc=0x%08x (ignored)\\n\"); goto L%x;}\n", text_vaddr + (i + 1) * 4, target); + } + label_addresses.insert(target); +} + +void dump_jal(int i, uint32_t imm) { + string_view name; + auto it = symbol_names.find(imm); + const ExternFunction* found_fn = nullptr; + + // Check for an external function at the address in the immediate. If it does not exist, function is internal + if (it != symbol_names.end()) { + name = it->second; + for (auto& fn : extern_functions) { + if (name == fn.name) { + found_fn = &fn; + break; + } + } + } + + dump_instr(i + 1); + + if (found_fn != nullptr) { + if (found_fn->flags & FLAG_VARARG) { + for (int j = 0; j < 4; j++) { + printf("MEM_U32(sp + %d) = %s;\n", j * 4, r((int)rabbitizer::Registers::Cpu::GprO32::GPR_O32_a0 + j)); + } + } + + const char ret_type = found_fn->params[0]; + + switch (ret_type) { + case 'v': + break; + + case 'i': + case 'u': + case 'p': + printf("%s = ", r((int)rabbitizer::Registers::Cpu::GprO32::GPR_O32_v0)); + break; + + case 'f': + printf("%s = ", fr((int)rabbitizer::Registers::Cpu::Cop1O32::COP1_O32_fv0)); + break; + + case 'd': + printf("tempf64 = "); + break; + + case 'l': + case 'j': + printf("temp64 = "); + break; + } + + printf("wrapper_%s(", string(name).c_str()); + + bool first = true; + + if (!(found_fn->flags & FLAG_NO_MEM)) { + printf("mem"); + first = false; + } + + int pos = 0; + int pos_float = 0; + bool only_floats_so_far = true; + bool needs_sp = false; + + for (const char* p = &found_fn->params[1]; *p != '\0'; ++p) { + if (!first) { + printf(", "); + } + + first = false; + + switch (*p) { + case 't': + printf("trampoline, "); + needs_sp = true; + // fallthrough + case 'i': + case 'u': + case 'p': + only_floats_so_far = false; + if (pos < 4) { + printf("%s", r((int)rabbitizer::Registers::Cpu::GprO32::GPR_O32_a0 + pos)); + } else { + printf("MEM_%c32(sp + %d)", *p == 'i' ? 'S' : 'U', pos * 4); + } + ++pos; + break; + + case 'f': + if (only_floats_so_far && pos_float < 4) { + printf("%s", fr((int)rabbitizer::Registers::Cpu::Cop1O32::COP1_O32_fa0 + pos_float)); + pos_float += 2; + } else if (pos < 4) { + printf("BITCAST_U32_TO_F32(%s)", r((int)rabbitizer::Registers::Cpu::GprO32::GPR_O32_a0 + pos)); + } else { + printf("BITCAST_U32_TO_F32(MEM_U32(sp + %d))", pos * 4); + } + ++pos; + break; + + case 'd': + if (pos % 1 != 0) { + ++pos; + } + if (only_floats_so_far && pos_float < 4) { + printf("double_from_FloatReg(%s)", + dr((int)rabbitizer::Registers::Cpu::Cop1O32::COP1_O32_fa0 + pos_float)); + pos_float += 2; + } else if (pos < 4) { + printf("BITCAST_U64_TO_F64(((uint64_t)%s << 32) | (uint64_t)%s)", + r((int)rabbitizer::Registers::Cpu::GprO32::GPR_O32_a0 + pos), + r((int)rabbitizer::Registers::Cpu::GprO32::GPR_O32_a0 + pos + 1)); + } else { + printf("BITCAST_U64_TO_F64(((uint64_t)MEM_U32(sp + %d) << 32) | " + "(uint64_t)MEM_U32(sp + " + "%d))", + pos * 4, (pos + 1) * 4); + } + pos += 2; + break; + + case 'l': + case 'j': + if (pos % 1 != 0) { + ++pos; + } + only_floats_so_far = false; + if (*p == 'l') { + printf("(int64_t)"); + } + if (pos < 4) { + printf("(((uint64_t)%s << 32) | (uint64_t)%s)", + r((int)rabbitizer::Registers::Cpu::GprO32::GPR_O32_a0 + pos), + r((int)rabbitizer::Registers::Cpu::GprO32::GPR_O32_a0 + pos + 1)); + } else { + printf("(((uint64_t)MEM_U32(sp + %d) << 32) | (uint64_t)MEM_U32(sp + %d))", pos * 4, + (pos + 1) * 4); + } + pos += 2; + break; + } + } + + if ((found_fn->flags & FLAG_VARARG) || needs_sp) { + printf("%s%s", first ? "" : ", ", r((int)rabbitizer::Registers::Cpu::GprO32::GPR_O32_sp)); + } + + printf(");\n"); + + if (ret_type == 'l' || ret_type == 'j') { + printf("%s = (uint32_t)(temp64 >> 32);\n", r((int)rabbitizer::Registers::Cpu::GprO32::GPR_O32_v0)); + printf("%s = (uint32_t)temp64;\n", r((int)rabbitizer::Registers::Cpu::GprO32::GPR_O32_v1)); + } else if (ret_type == 'd') { + printf("%s = FloatReg_from_double(tempf64);\n", dr((int)rabbitizer::Registers::Cpu::Cop1O32::COP1_O32_fv0)); + } + } else { + Function& f = functions.find(imm)->second; + + if (f.nret == 1) { + printf("v0 = "); + } else if (f.nret == 2) { + printf("temp64 = "); + } + + if (!name.empty()) { + printf("f_%s", string(name).c_str()); + } else { + printf("func_%x", imm); + } + + printf("(mem, sp"); + + if (f.v0_in) { + printf(", %s", r((int)rabbitizer::Registers::Cpu::GprO32::GPR_O32_v0)); + } + + for (uint32_t i = 0; i < f.nargs; i++) { + printf(", %s", r((int)rabbitizer::Registers::Cpu::GprO32::GPR_O32_a0 + i)); + } + + printf(");\n"); + + if (f.nret == 2) { + printf("%s = (uint32_t)(temp64 >> 32);\n", r((int)rabbitizer::Registers::Cpu::GprO32::GPR_O32_v0)); + printf("%s = (uint32_t)temp64;\n", r((int)rabbitizer::Registers::Cpu::GprO32::GPR_O32_v1)); + } + } + + printf("goto L%x;\n", text_vaddr + (i + 2) * 4); + label_addresses.insert(text_vaddr + (i + 2) * 4); +} + +void dump_instr(int i) { + Insn& insn = insns[i]; + + const char* symbol_name = NULL; + if (symbol_names.count(text_vaddr + i * sizeof(uint32_t)) != 0) { + symbol_name = symbol_names[text_vaddr + i * sizeof(uint32_t)].c_str(); + printf("//%s:\n", symbol_name); + } + + if (TRACE) { + printf("++cnt; printf(\"pc=0x%08x%s%s\\n\"); ", text_vaddr + i * 4, symbol_name ? " " : "", + symbol_name ? symbol_name : ""); + } + + uint64_t src_regs_map; + if (!insn.instruction.isJump() && !insn.instruction.isBranch() && !conservative) { + switch (insn_to_type(insn)) { + case TYPE_S: + src_regs_map = get_all_source_reg_mask(insn.instruction); + if (!((insn.f_livein & src_regs_map) == src_regs_map)) { + printf("// fdead %llx ", (unsigned long long)insn.f_livein); + } + break; + + case TYPE_D_S: { + uint64_t reg_mask = get_all_source_reg_mask(insn.instruction); + + if ((insn.f_livein & reg_mask) != reg_mask) { + printf("// fdead %llx ", (unsigned long long)insn.f_livein); + break; + } + } + // fallthrough + case TYPE_D: + if (!(insn.b_liveout & get_dest_reg_mask(insn))) { +#if 0 + printf("// %i bdead %llx %llx ", i, (unsigned long long)insn.b_liveout, + (unsigned long long)get_dest_reg_mask(insn)); +#else + printf("// bdead %llx ", (unsigned long long)insn.b_liveout); +#endif + } + break; + + case TYPE_NOP: + break; + } + } + + int32_t imm; + char buf[0x100]; + switch (insn.instruction.getUniqueId()) { + case rabbitizer::InstrId::UniqueId::cpu_add: + case rabbitizer::InstrId::UniqueId::cpu_addu: + if (insn.instruction.GetO32_rs() == rabbitizer::Registers::Cpu::GprO32::GPR_O32_zero) { + printf("%s = %s;\n", r((int)insn.instruction.GetO32_rd()), r((int)insn.instruction.GetO32_rt())); + } else if (insn.instruction.GetO32_rt() == rabbitizer::Registers::Cpu::GprO32::GPR_O32_zero) { + printf("%s = %s;\n", r((int)insn.instruction.GetO32_rd()), r((int)insn.instruction.GetO32_rs())); + } else { + printf("%s = %s + %s;\n", r((int)insn.instruction.GetO32_rd()), r((int)insn.instruction.GetO32_rs()), + r((int)insn.instruction.GetO32_rt())); + } + break; + + case rabbitizer::InstrId::UniqueId::cpu_add_s: + printf("%s = %s + %s;\n", fr((int)insn.instruction.GetO32_fd()), fr((int)insn.instruction.GetO32_fs()), + fr((int)insn.instruction.GetO32_ft())); + break; + + case rabbitizer::InstrId::UniqueId::cpu_add_d: + printf("%s = FloatReg_from_double(double_from_FloatReg(%s) + double_from_FloatReg(%s));\n", + dr((int)insn.instruction.GetO32_fd()), dr((int)insn.instruction.GetO32_fs()), + dr((int)insn.instruction.GetO32_ft())); + break; + + case rabbitizer::InstrId::UniqueId::cpu_addi: + case rabbitizer::InstrId::UniqueId::cpu_addiu: + imm = insn.getImmediate(); + if (insn.instruction.GetO32_rs() == rabbitizer::Registers::Cpu::GprO32::GPR_O32_zero) { + printf("%s = 0x%x;\n", r((int)insn.instruction.GetO32_rt()), imm); + } else { + printf("%s = %s + 0x%x;\n", r((int)insn.instruction.GetO32_rt()), r((int)insn.instruction.GetO32_rs()), + imm); + } + break; + + case rabbitizer::InstrId::UniqueId::cpu_and: + printf("%s = %s & %s;\n", r((int)insn.instruction.GetO32_rd()), r((int)insn.instruction.GetO32_rs()), + r((int)insn.instruction.GetO32_rt())); + break; + + case rabbitizer::InstrId::UniqueId::cpu_andi: + imm = insn.getImmediate(); + printf("%s = %s & 0x%x;\n", r((int)insn.instruction.GetO32_rt()), r((int)insn.instruction.GetO32_rs()), + imm); + break; + + case rabbitizer::InstrId::UniqueId::cpu_beq: + dump_cond_branch(i, r((int)insn.instruction.GetO32_rs()), "==", r((int)insn.instruction.GetO32_rt())); + break; + + case rabbitizer::InstrId::UniqueId::cpu_beql: + dump_cond_branch_likely(i, r((int)insn.instruction.GetO32_rs()), + "==", r((int)insn.instruction.GetO32_rt())); + break; + + case rabbitizer::InstrId::UniqueId::cpu_bgez: + dump_cond_branch(i, r((int)insn.instruction.GetO32_rs()), ">=", "0"); + break; + + case rabbitizer::InstrId::UniqueId::cpu_bgezl: + dump_cond_branch_likely(i, r((int)insn.instruction.GetO32_rs()), ">=", "0"); + break; + + case rabbitizer::InstrId::UniqueId::cpu_bgtz: + dump_cond_branch(i, r((int)insn.instruction.GetO32_rs()), ">", "0"); + break; + + case rabbitizer::InstrId::UniqueId::cpu_bgtzl: + dump_cond_branch_likely(i, r((int)insn.instruction.GetO32_rs()), ">", "0"); + break; + + case rabbitizer::InstrId::UniqueId::cpu_blez: + dump_cond_branch(i, r((int)insn.instruction.GetO32_rs()), "<=", "0"); + break; + + case rabbitizer::InstrId::UniqueId::cpu_blezl: + dump_cond_branch_likely(i, r((int)insn.instruction.GetO32_rs()), "<=", "0"); + break; + + case rabbitizer::InstrId::UniqueId::cpu_bltz: + dump_cond_branch(i, r((int)insn.instruction.GetO32_rs()), "<", "0"); + break; + + case rabbitizer::InstrId::UniqueId::cpu_bltzl: + dump_cond_branch_likely(i, r((int)insn.instruction.GetO32_rs()), "<", "0"); + break; + + case rabbitizer::InstrId::UniqueId::cpu_bne: + dump_cond_branch(i, r((int)insn.instruction.GetO32_rs()), "!=", r((int)insn.instruction.GetO32_rt())); + break; + + case rabbitizer::InstrId::UniqueId::cpu_bnel: + dump_cond_branch_likely(i, r((int)insn.instruction.GetO32_rs()), + "!=", r((int)insn.instruction.GetO32_rt())); + break; + + case rabbitizer::InstrId::UniqueId::cpu_break: + printf("abort();\n"); + break; + + case rabbitizer::InstrId::UniqueId::cpu_beqz: + dump_cond_branch(i, r((int)insn.instruction.GetO32_rs()), "==", "0"); + break; + + case rabbitizer::InstrId::UniqueId::cpu_b: + dump_instr(i + 1); + imm = insn.getAddress(); + printf("goto L%x;\n", imm); + break; + + case rabbitizer::InstrId::UniqueId::cpu_bc1f: + printf("if (!cf) {\n"); + dump_instr(i + 1); + imm = insn.getAddress(); + printf("goto L%x;}\n", imm); + break; + + case rabbitizer::InstrId::UniqueId::cpu_bc1t: + printf("if (cf) {\n"); + dump_instr(i + 1); + imm = insn.getAddress(); + printf("goto L%x;}\n", imm); + break; + + case rabbitizer::InstrId::UniqueId::cpu_bc1fl: { + uint32_t target = text_vaddr + (i + 2) * sizeof(uint32_t); + printf("if (!cf) {\n"); + dump_instr(i + 1); + imm = insn.getAddress(); + printf("goto L%x;}\n", imm); + if (!TRACE) { + printf("else goto L%x;\n", target); + } else { + printf("else {printf(\"pc=0x%08x (ignored)\\n\"); goto L%x;}\n", text_vaddr + (i + 1) * 4, target); + } + label_addresses.insert(target); + } break; + + case rabbitizer::InstrId::UniqueId::cpu_bc1tl: { + uint32_t target = text_vaddr + (i + 2) * sizeof(uint32_t); + printf("if (cf) {\n"); + dump_instr(i + 1); + imm = insn.getAddress(); + printf("goto L%x;}\n", imm); + if (!TRACE) { + printf("else goto L%x;\n", target); + } else { + printf("else {printf(\"pc=0x%08x (ignored)\\n\"); goto L%x;}\n", text_vaddr + (i + 1) * 4, target); + } + label_addresses.insert(target); + } break; + + case rabbitizer::InstrId::UniqueId::cpu_bnez: + dump_cond_branch(i, r((int)insn.instruction.GetO32_rs()), "!=", "0"); + break; + + case rabbitizer::InstrId::UniqueId::cpu_c_lt_s: + printf("cf = %s < %s;\n", fr((int)insn.instruction.GetO32_fs()), fr((int)insn.instruction.GetO32_ft())); + break; + + case rabbitizer::InstrId::UniqueId::cpu_c_le_s: + printf("cf = %s <= %s;\n", fr((int)insn.instruction.GetO32_fs()), fr((int)insn.instruction.GetO32_ft())); + break; + + case rabbitizer::InstrId::UniqueId::cpu_c_eq_s: + printf("cf = %s == %s;\n", fr((int)insn.instruction.GetO32_fs()), fr((int)insn.instruction.GetO32_ft())); + break; + + case rabbitizer::InstrId::UniqueId::cpu_c_lt_d: + printf("cf = double_from_FloatReg(%s) < double_from_FloatReg(%s);\n", dr((int)insn.instruction.GetO32_fs()), + dr((int)insn.instruction.GetO32_ft())); + break; + + case rabbitizer::InstrId::UniqueId::cpu_c_le_d: + printf("cf = double_from_FloatReg(%s) <= double_from_FloatReg(%s);\n", + dr((int)insn.instruction.GetO32_fs()), dr((int)insn.instruction.GetO32_ft())); + break; + + case rabbitizer::InstrId::UniqueId::cpu_c_eq_d: + printf("cf = double_from_FloatReg(%s) == double_from_FloatReg(%s);\n", + dr((int)insn.instruction.GetO32_fs()), dr((int)insn.instruction.GetO32_ft())); + break; + + case rabbitizer::InstrId::UniqueId::cpu_cvt_s_w: + printf("%s = (int)%s;\n", fr((int)insn.instruction.GetO32_fd()), wr((int)insn.instruction.GetO32_fs())); + break; + + case rabbitizer::InstrId::UniqueId::cpu_cvt_d_w: + printf("%s = FloatReg_from_double((int)%s);\n", dr((int)insn.instruction.GetO32_fd()), + wr((int)insn.instruction.GetO32_fs())); + break; + + case rabbitizer::InstrId::UniqueId::cpu_cvt_d_s: + printf("%s = FloatReg_from_double(%s);\n", dr((int)insn.instruction.GetO32_fd()), + fr((int)insn.instruction.GetO32_fs())); + break; + + case rabbitizer::InstrId::UniqueId::cpu_cvt_s_d: + printf("%s = double_from_FloatReg(%s);\n", fr((int)insn.instruction.GetO32_fd()), + dr((int)insn.instruction.GetO32_fs())); + break; + + case rabbitizer::InstrId::UniqueId::cpu_cvt_w_d: + printf("%s = cvt_w_d(double_from_FloatReg(%s));\n", wr((int)insn.instruction.GetO32_fd()), + dr((int)insn.instruction.GetO32_fs())); + break; + + case rabbitizer::InstrId::UniqueId::cpu_cvt_w_s: + printf("%s = cvt_w_s(%s);\n", wr((int)insn.instruction.GetO32_fd()), fr((int)insn.instruction.GetO32_fs())); + break; + + case rabbitizer::InstrId::UniqueId::cpu_cvt_l_d: + case rabbitizer::InstrId::UniqueId::cpu_cvt_l_s: + case rabbitizer::InstrId::UniqueId::cpu_cvt_s_l: + case rabbitizer::InstrId::UniqueId::cpu_cvt_d_l: + goto unimplemented; + + case rabbitizer::InstrId::UniqueId::cpu_cfc1: + assert(insn.instruction.Get_cop1cs() == rabbitizer::Registers::Cpu::Cop1Control::COP1_CONTROL_FpcCsr); + printf("%s = fcsr;\n", r((int)insn.instruction.GetO32_rt())); + break; + + case rabbitizer::InstrId::UniqueId::cpu_ctc1: + assert(insn.instruction.Get_cop1cs() == rabbitizer::Registers::Cpu::Cop1Control::COP1_CONTROL_FpcCsr); + printf("fcsr = %s;\n", r((int)insn.instruction.GetO32_rt())); + break; + + case rabbitizer::InstrId::UniqueId::cpu_div: + printf("lo = (int)%s / (int)%s; ", r((int)insn.instruction.GetO32_rs()), + r((int)insn.instruction.GetO32_rt())); + printf("hi = (int)%s %% (int)%s;\n", r((int)insn.instruction.GetO32_rs()), + r((int)insn.instruction.GetO32_rt())); + break; + + case rabbitizer::InstrId::UniqueId::cpu_divu: + printf("lo = %s / %s; ", r((int)insn.instruction.GetO32_rs()), r((int)insn.instruction.GetO32_rt())); + printf("hi = %s %% %s;\n", r((int)insn.instruction.GetO32_rs()), r((int)insn.instruction.GetO32_rt())); + break; + + case rabbitizer::InstrId::UniqueId::cpu_div_s: + printf("%s = %s / %s;\n", fr((int)insn.instruction.GetO32_fd()), fr((int)insn.instruction.GetO32_fs()), + fr((int)insn.instruction.GetO32_ft())); + break; + + case rabbitizer::InstrId::UniqueId::cpu_div_d: + printf("%s = FloatReg_from_double(double_from_FloatReg(%s) / double_from_FloatReg(%s));\n", + dr((int)insn.instruction.GetO32_fd()), dr((int)insn.instruction.GetO32_fs()), + dr((int)insn.instruction.GetO32_ft())); + break; + + case rabbitizer::InstrId::UniqueId::cpu_mov_s: + printf("%s = %s;\n", fr((int)insn.instruction.GetO32_fd()), fr((int)insn.instruction.GetO32_fs())); + break; + + case rabbitizer::InstrId::UniqueId::cpu_mov_d: + printf("%s = %s;\n", dr((int)insn.instruction.GetO32_fd()), dr((int)insn.instruction.GetO32_fs())); + break; + + case rabbitizer::InstrId::UniqueId::cpu_mul_s: + printf("%s = %s * %s;\n", fr((int)insn.instruction.GetO32_fd()), fr((int)insn.instruction.GetO32_fs()), + fr((int)insn.instruction.GetO32_ft())); + break; + + case rabbitizer::InstrId::UniqueId::cpu_mul_d: + printf("%s = FloatReg_from_double(double_from_FloatReg(%s) * double_from_FloatReg(%s));\n", + dr((int)insn.instruction.GetO32_fd()), dr((int)insn.instruction.GetO32_fs()), + dr((int)insn.instruction.GetO32_ft())); + break; + + case rabbitizer::InstrId::UniqueId::cpu_negu: + printf("%s = -%s;\n", r((int)insn.instruction.GetO32_rd()), r((int)insn.instruction.GetO32_rt())); + break; + + case rabbitizer::InstrId::UniqueId::cpu_neg_s: + printf("%s = -%s;\n", fr((int)insn.instruction.GetO32_fd()), fr((int)insn.instruction.GetO32_fs())); + break; + + case rabbitizer::InstrId::UniqueId::cpu_neg_d: + printf("%s = FloatReg_from_double(-double_from_FloatReg(%s));\n", dr((int)insn.instruction.GetO32_fd()), + dr((int)insn.instruction.GetO32_fs())); + break; + + case rabbitizer::InstrId::UniqueId::cpu_sub: + if (insn.instruction.GetO32_rs() == rabbitizer::Registers::Cpu::GprO32::GPR_O32_zero) { + printf("%s = -%s;\n", r((int)insn.instruction.GetO32_rd()), r((int)insn.instruction.GetO32_rt())); + break; + } else { + goto unimplemented; + } + + case rabbitizer::InstrId::UniqueId::cpu_sub_s: + printf("%s = %s - %s;\n", fr((int)insn.instruction.GetO32_fd()), fr((int)insn.instruction.GetO32_fs()), + fr((int)insn.instruction.GetO32_ft())); + break; + + case rabbitizer::InstrId::UniqueId::cpu_sub_d: + printf("%s = FloatReg_from_double(double_from_FloatReg(%s) - double_from_FloatReg(%s));\n", + dr((int)insn.instruction.GetO32_fd()), dr((int)insn.instruction.GetO32_fs()), + dr((int)insn.instruction.GetO32_ft())); + break; + + // Jumps + + case rabbitizer::InstrId::UniqueId::cpu_j: + dump_instr(i + 1); + imm = insn.getAddress(); + printf("goto L%x;\n", imm); + break; + + case rabbitizer::InstrId::UniqueId::cpu_jal: + imm = insn.getAddress(); + dump_jal(i, imm); + break; + + case rabbitizer::InstrId::UniqueId::cpu_jalr: + printf("fp_dest = %s;\n", r((int)insn.instruction.GetO32_rs())); + dump_instr(i + 1); + printf("temp64 = trampoline(mem, sp, %s, %s, %s, %s, fp_dest);\n", + r((int)rabbitizer::Registers::Cpu::GprO32::GPR_O32_a0), + r((int)rabbitizer::Registers::Cpu::GprO32::GPR_O32_a1), + r((int)rabbitizer::Registers::Cpu::GprO32::GPR_O32_a2), + r((int)rabbitizer::Registers::Cpu::GprO32::GPR_O32_a3)); + printf("%s = (uint32_t)(temp64 >> 32);\n", r((int)rabbitizer::Registers::Cpu::GprO32::GPR_O32_v0)); + printf("%s = (uint32_t)temp64;\n", r((int)rabbitizer::Registers::Cpu::GprO32::GPR_O32_v1)); + printf("goto L%x;\n", text_vaddr + (i + 2) * 4); + label_addresses.insert(text_vaddr + (i + 2) * 4); + break; + + case rabbitizer::InstrId::UniqueId::cpu_jr: + // TODO: understand why the switch version fails, and why only it needs the nop + if (insn.jtbl_addr != 0) { + uint32_t jtbl_pos = insn.jtbl_addr - rodata_vaddr; + + assert(jtbl_pos < rodata_section_len && + jtbl_pos + insn.num_cases * sizeof(uint32_t) <= rodata_section_len); +#if 1 + printf(";static void *const Lswitch%x[] = {\n", insn.jtbl_addr); + + for (uint32_t i = 0; i < insn.num_cases; i++) { + uint32_t dest_addr = read_u32_be(rodata_section + jtbl_pos + i * sizeof(uint32_t)) + gp_value; + printf("&&L%x,\n", dest_addr); + label_addresses.insert(dest_addr); + } + + printf("};\n"); + printf("dest = Lswitch%x[%s];\n", insn.jtbl_addr, r((int)insn.index_reg)); + dump_instr(i + 1); + printf("goto *dest;\n"); +#else + // This block produces a switch instead of an array of labels. + // It is not being used because currently it is a bit bugged. + // It has been keep as a reference and with the main intention to fix it + + assert(insns[i + 1].id == MIPS_INS_NOP); + printf("switch (%s) {\n", r(insn.index_reg)); + + for (uint32_t i = 0; i < insn.num_cases; i++) { + uint32_t dest_addr = read_u32_be(rodata_section + jtbl_pos + i * sizeof(uint32_t)) + gp_value; + printf("case %u: goto L%x;\n", i, dest_addr); + label_addresses.insert(dest_addr); + } + + printf("}\n"); +#endif + } else { + if (insn.instruction.GetO32_rs() != rabbitizer::Registers::Cpu::GprO32::GPR_O32_ra) { + printf("UNSUPPORTED JR %s (no jumptable available)\n", r((int)insn.instruction.GetO32_rs())); + } else { + dump_instr(i + 1); + switch (find_function(text_vaddr + i * sizeof(uint32_t))->second.nret) { + case 0: + printf("return;\n"); + break; + + case 1: + printf("return v0;\n"); + break; + + case 2: + printf("return ((uint64_t)v0 << 32) | v1;\n"); + break; + } + } + } + break; + + case rabbitizer::InstrId::UniqueId::cpu_lb: + imm = insn.getImmediate(); + printf("%s = MEM_S8(%s + %d);\n", r((int)insn.instruction.GetO32_rt()), + r((int)insn.instruction.GetO32_rs()), imm); + break; + + case rabbitizer::InstrId::UniqueId::cpu_lbu: + imm = insn.getImmediate(); + printf("%s = MEM_U8(%s + %d);\n", r((int)insn.instruction.GetO32_rt()), + r((int)insn.instruction.GetO32_rs()), imm); + break; + + case rabbitizer::InstrId::UniqueId::cpu_lh: + imm = insn.getImmediate(); + printf("%s = MEM_S16(%s + %d);\n", r((int)insn.instruction.GetO32_rt()), + r((int)insn.instruction.GetO32_rs()), imm); + break; + + case rabbitizer::InstrId::UniqueId::cpu_lhu: + imm = insn.getImmediate(); + printf("%s = MEM_U16(%s + %d);\n", r((int)insn.instruction.GetO32_rt()), + r((int)insn.instruction.GetO32_rs()), imm); + break; + + case rabbitizer::InstrId::UniqueId::cpu_lui: + imm = insn.getImmediate(); + printf("%s = 0x%x;\n", r((int)insn.instruction.GetO32_rt()), imm << 16); + break; + + case rabbitizer::InstrId::UniqueId::cpu_lw: + imm = insn.getImmediate(); + printf("%s = MEM_U32(%s + %d);\n", r((int)insn.instruction.GetO32_rt()), + r((int)insn.instruction.GetO32_rs()), imm); + break; + + case rabbitizer::InstrId::UniqueId::cpu_lwc1: + imm = insn.getImmediate(); + printf("%s = MEM_U32(%s + %d);\n", wr((int)insn.instruction.GetO32_ft()), + r((int)insn.instruction.GetO32_rs()), imm); + break; + + case rabbitizer::InstrId::UniqueId::cpu_ldc1: + imm = insn.getImmediate(); + assert(((int)insn.instruction.GetO32_ft() - (int)rabbitizer::Registers::Cpu::Cop1O32::COP1_O32_fv0) % 2 == + 0); + printf("%s = MEM_U32(%s + %d);\n", wr((int)insn.instruction.GetO32_ft() + 1), + r((int)insn.instruction.GetO32_rs()), imm); + printf("%s = MEM_U32(%s + %d + 4);\n", wr((int)insn.instruction.GetO32_ft()), + r((int)insn.instruction.GetO32_rs()), imm); + break; + + case rabbitizer::InstrId::UniqueId::cpu_lwl: { + const char* reg = r((int)insn.instruction.GetO32_rt()); + + imm = insn.getImmediate(); + + printf("%s = %s + %d; ", reg, r((int)insn.instruction.GetO32_rs()), imm); + printf("%s = ((uint32_t)MEM_U8(%s) << 24) | (MEM_U8(%s + 1) << 16) | (MEM_U8(%s + 2) << 8) | MEM_U8(%s + 3);\n", reg, + reg, reg, reg, reg); + } break; + + case rabbitizer::InstrId::UniqueId::cpu_lwr: + printf("//%s\n", insn.disassemble().c_str()); + break; + + case UniqueId_cpu_la: { + uint32_t addr = insn.getAddress(); + + printf("%s = 0x%x;", r((int)insn.lila_dst_reg), addr); + if ((text_vaddr <= addr) && (addr < text_vaddr + text_section_len)) { + printf(" // function pointer"); + label_addresses.insert(addr); + } + printf("\n"); + } break; + + case UniqueId_cpu_li: + imm = insn.getImmediate(); + + printf("%s = 0x%x;\n", r((int)insn.lila_dst_reg), imm); + break; + + case rabbitizer::InstrId::UniqueId::cpu_mfc1: + printf("%s = %s;\n", r((int)insn.instruction.GetO32_rt()), wr((int)insn.instruction.GetO32_fs())); + break; + + case rabbitizer::InstrId::UniqueId::cpu_mfhi: + printf("%s = hi;\n", r((int)insn.instruction.GetO32_rd())); + break; + + case rabbitizer::InstrId::UniqueId::cpu_mflo: + printf("%s = lo;\n", r((int)insn.instruction.GetO32_rd())); + break; + + case rabbitizer::InstrId::UniqueId::cpu_move: + printf("%s = %s;\n", r((int)insn.instruction.GetO32_rd()), r((int)insn.instruction.GetO32_rs())); + break; + + case rabbitizer::InstrId::UniqueId::cpu_mtc1: + printf("%s = %s;\n", wr((int)insn.instruction.GetO32_fs()), r((int)insn.instruction.GetO32_rt())); + break; + + case rabbitizer::InstrId::UniqueId::cpu_mult: + printf("lo = %s * %s;\n", r((int)insn.instruction.GetO32_rs()), r((int)insn.instruction.GetO32_rt())); + printf("hi = (uint32_t)((int64_t)(int)%s * (int64_t)(int)%s >> 32);\n", + r((int)insn.instruction.GetO32_rs()), r((int)insn.instruction.GetO32_rt())); + break; + + case rabbitizer::InstrId::UniqueId::cpu_multu: + printf("lo = %s * %s;\n", r((int)insn.instruction.GetO32_rs()), r((int)insn.instruction.GetO32_rt())); + printf("hi = (uint32_t)((uint64_t)%s * (uint64_t)%s >> 32);\n", r((int)insn.instruction.GetO32_rs()), + r((int)insn.instruction.GetO32_rt())); + break; + + case rabbitizer::InstrId::UniqueId::cpu_sqrt_s: + printf("%s = sqrtf(%s);\n", fr((int)insn.instruction.GetO32_fd()), fr((int)insn.instruction.GetO32_fs())); + break; + + case rabbitizer::InstrId::UniqueId::cpu_nor: + printf("%s = ~(%s | %s);\n", r((int)insn.instruction.GetO32_rd()), r((int)insn.instruction.GetO32_rs()), + r((int)insn.instruction.GetO32_rt())); + break; + + case rabbitizer::InstrId::UniqueId::cpu_not: + printf("%s = ~%s;\n", r((int)insn.instruction.GetO32_rd()), r((int)insn.instruction.GetO32_rs())); + break; + + case rabbitizer::InstrId::UniqueId::cpu_or: + printf("%s = %s | %s;\n", r((int)insn.instruction.GetO32_rd()), r((int)insn.instruction.GetO32_rs()), + r((int)insn.instruction.GetO32_rt())); + break; + + case rabbitizer::InstrId::UniqueId::cpu_ori: + imm = insn.getImmediate(); + printf("%s = %s | 0x%x;\n", r((int)insn.instruction.GetO32_rt()), r((int)insn.instruction.GetO32_rs()), + imm); + break; + + case rabbitizer::InstrId::UniqueId::cpu_sb: + imm = insn.getImmediate(); + printf("MEM_U8(%s + %d) = (uint8_t)%s;\n", r((int)insn.instruction.GetO32_rs()), imm, + r((int)insn.instruction.GetO32_rt())); + break; + + case rabbitizer::InstrId::UniqueId::cpu_sh: + imm = insn.getImmediate(); + printf("MEM_U16(%s + %d) = (uint16_t)%s;\n", r((int)insn.instruction.GetO32_rs()), imm, + r((int)insn.instruction.GetO32_rt())); + break; + + case rabbitizer::InstrId::UniqueId::cpu_sll: + printf("%s = %s << %d;\n", r((int)insn.instruction.GetO32_rd()), r((int)insn.instruction.GetO32_rt()), + insn.instruction.Get_sa()); + break; + + case rabbitizer::InstrId::UniqueId::cpu_sllv: + printf("%s = %s << (%s & 0x1f);\n", r((int)insn.instruction.GetO32_rd()), + r((int)insn.instruction.GetO32_rt()), r((int)insn.instruction.GetO32_rs())); + break; + + case rabbitizer::InstrId::UniqueId::cpu_slt: + printf("%s = (int)%s < (int)%s;\n", r((int)insn.instruction.GetO32_rd()), + r((int)insn.instruction.GetO32_rs()), r((int)insn.instruction.GetO32_rt())); + break; + + case rabbitizer::InstrId::UniqueId::cpu_slti: + imm = insn.getImmediate(); + printf("%s = (int)%s < (int)0x%x;\n", r((int)insn.instruction.GetO32_rt()), + r((int)insn.instruction.GetO32_rs()), imm); + break; + + case rabbitizer::InstrId::UniqueId::cpu_sltiu: + imm = insn.getImmediate(); + printf("%s = %s < 0x%x;\n", r((int)insn.instruction.GetO32_rt()), r((int)insn.instruction.GetO32_rs()), + imm); + break; + + case rabbitizer::InstrId::UniqueId::cpu_sltu: + printf("%s = %s < %s;\n", r((int)insn.instruction.GetO32_rd()), r((int)insn.instruction.GetO32_rs()), + r((int)insn.instruction.GetO32_rt())); + break; + + case rabbitizer::InstrId::UniqueId::cpu_sra: + printf("%s = (int)%s >> %d;\n", r((int)insn.instruction.GetO32_rd()), r((int)insn.instruction.GetO32_rt()), + insn.instruction.Get_sa()); + break; + + case rabbitizer::InstrId::UniqueId::cpu_srav: + printf("%s = (int)%s >> (%s & 0x1f);\n", r((int)insn.instruction.GetO32_rd()), + r((int)insn.instruction.GetO32_rt()), r((int)insn.instruction.GetO32_rs())); + break; + + case rabbitizer::InstrId::UniqueId::cpu_srl: + printf("%s = %s >> %d;\n", r((int)insn.instruction.GetO32_rd()), r((int)insn.instruction.GetO32_rt()), + insn.instruction.Get_sa()); + break; + + case rabbitizer::InstrId::UniqueId::cpu_srlv: + printf("%s = %s >> (%s & 0x1f);\n", r((int)insn.instruction.GetO32_rd()), + r((int)insn.instruction.GetO32_rt()), r((int)insn.instruction.GetO32_rs())); + break; + + case rabbitizer::InstrId::UniqueId::cpu_subu: + printf("%s = %s - %s;\n", r((int)insn.instruction.GetO32_rd()), r((int)insn.instruction.GetO32_rs()), + r((int)insn.instruction.GetO32_rt())); + break; + + case rabbitizer::InstrId::UniqueId::cpu_sw: + imm = insn.getImmediate(); + printf("MEM_U32(%s + %d) = %s;\n", r((int)insn.instruction.GetO32_rs()), imm, + r((int)insn.instruction.GetO32_rt())); + break; + + case rabbitizer::InstrId::UniqueId::cpu_swc1: + imm = insn.getImmediate(); + printf("MEM_U32(%s + %d) = %s;\n", r((int)insn.instruction.GetO32_rs()), imm, + wr((int)insn.instruction.GetO32_ft())); + break; + + case rabbitizer::InstrId::UniqueId::cpu_sdc1: + assert(((int)insn.instruction.GetO32_ft() - (int)rabbitizer::Registers::Cpu::Cop1O32::COP1_O32_fv0) % 2 == + 0); + imm = insn.getImmediate(); + printf("MEM_U32(%s + %d) = %s;\n", r((int)insn.instruction.GetO32_rs()), imm, + wr((int)insn.instruction.GetO32_ft() + 1)); + printf("MEM_U32(%s + %d + 4) = %s;\n", r((int)insn.instruction.GetO32_rs()), imm, + wr((int)insn.instruction.GetO32_ft())); + break; + + case rabbitizer::InstrId::UniqueId::cpu_swl: + imm = insn.getImmediate(); + for (int i = 0; i < 4; i++) { + printf("MEM_U8(%s + %d + %d) = (uint8_t)(%s >> %d);\n", r((int)insn.instruction.GetO32_rs()), imm, i, + r((int)insn.instruction.GetO32_rt()), (3 - i) * 8); + } + break; + + case rabbitizer::InstrId::UniqueId::cpu_swr: + printf("//%s\n", insn.disassemble().c_str()); + break; + + case rabbitizer::InstrId::UniqueId::cpu_trunc_w_s: + printf("%s = (int)%s;\n", wr((int)insn.instruction.GetO32_fd()), fr((int)insn.instruction.GetO32_fs())); + break; + + case rabbitizer::InstrId::UniqueId::cpu_trunc_w_d: + printf("%s = (int)double_from_FloatReg(%s);\n", wr((int)insn.instruction.GetO32_fd()), + dr((int)insn.instruction.GetO32_fs())); + break; + + case rabbitizer::InstrId::UniqueId::cpu_trunc_l_d: + case rabbitizer::InstrId::UniqueId::cpu_trunc_l_s: + goto unimplemented; + + case rabbitizer::InstrId::UniqueId::cpu_xor: + printf("%s = %s ^ %s;\n", r((int)insn.instruction.GetO32_rd()), r((int)insn.instruction.GetO32_rs()), + r((int)insn.instruction.GetO32_rt())); + break; + + case rabbitizer::InstrId::UniqueId::cpu_xori: + imm = insn.getImmediate(); + printf("%s = %s ^ 0x%x;\n", r((int)insn.instruction.GetO32_rt()), r((int)insn.instruction.GetO32_rs()), + imm); + break; + + case rabbitizer::InstrId::UniqueId::cpu_tne: + imm = insn.instruction.Get_code_lower(); + printf("assert(%s == %s && \"tne %d\");\n", r((int)insn.instruction.GetO32_rs()), + r((int)insn.instruction.GetO32_rt()), imm); + break; + + case rabbitizer::InstrId::UniqueId::cpu_teq: + imm = insn.instruction.Get_code_lower(); + printf("assert(%s != %s && \"teq %d\");\n", r((int)insn.instruction.GetO32_rs()), + r((int)insn.instruction.GetO32_rt()), imm); + break; + + case rabbitizer::InstrId::UniqueId::cpu_tge: + imm = insn.instruction.Get_code_lower(); + printf("assert((int)%s < (int)%s && \"tge %d\");\n", r((int)insn.instruction.GetO32_rs()), + r((int)insn.instruction.GetO32_rt()), imm); + break; + + case rabbitizer::InstrId::UniqueId::cpu_tgeu: + imm = insn.instruction.Get_code_lower(); + printf("assert(%s < %s && \"tgeu %d\");\n", r((int)insn.instruction.GetO32_rs()), + r((int)insn.instruction.GetO32_rt()), imm); + break; + + case rabbitizer::InstrId::UniqueId::cpu_tlt: + imm = insn.instruction.Get_code_lower(); + printf("assert((int)%s >= (int)%s && \"tlt %d\");\n", r((int)insn.instruction.GetO32_rs()), + r((int)insn.instruction.GetO32_rt()), imm); + break; + + case rabbitizer::InstrId::UniqueId::cpu_nop: + printf("//nop;\n"); + break; + + default: + unimplemented: + printf("UNIMPLEMENTED 0x%X : %s\n", insn.instruction.getRaw(), insn.disassemble().c_str()); + break; + } +} + +void inspect_data_function_pointers(vector>& ret, const uint8_t* section, + uint32_t section_vaddr, uint32_t len) { + for (uint32_t i = 0; i < len; i += 4) { + uint32_t addr = read_u32_be(section + i); + + if (addr == 0x430b00 || addr == 0x433b00) { + // in as1, not function pointers (normal integers) + continue; + } + + if (addr == 0x4a0000) { + // in copt + continue; + } + + if (section_vaddr + i >= procedure_table_start && + section_vaddr + i < procedure_table_start + procedure_table_len) { + // some linking table with a "all" functions, in as1 5.3 + continue; + } + + if ((addr >= text_vaddr) && (addr < text_vaddr + text_section_len) && ((addr % 4) == 0)) { +#if INSPECT_FUNCTION_POINTERS + fprintf(stderr, "assuming function pointer 0x%x at 0x%x\n", addr, section_vaddr + i); +#endif + ret.push_back(make_pair(section_vaddr + i, addr)); + label_addresses.insert(addr); + functions[addr].referenced_by_function_pointer = true; + } + } +} + +void dump_function_signature(Function& f, uint32_t vaddr) { + printf("static "); + switch (f.nret) { + case 0: + printf("void "); + break; + + case 1: + printf("uint32_t "); + break; + + case 2: + printf("uint64_t "); + break; + } + + auto name_it = symbol_names.find(vaddr); + + if (name_it != symbol_names.end()) { + printf("f_%s", name_it->second.c_str()); + } else { + printf("func_%x", vaddr); + } + + printf("(uint8_t *mem, uint32_t sp"); + + if (f.v0_in) { + printf(", uint32_t %s", r((int)rabbitizer::Registers::Cpu::GprO32::GPR_O32_v0)); + } + + for (uint32_t i = 0; i < f.nargs; i++) { + printf(", uint32_t %s", r((int)rabbitizer::Registers::Cpu::GprO32::GPR_O32_a0 + i)); + } + + printf(")"); +} + +void dump_c(void) { + map symbol_names_inv; + + for (auto& it : symbol_names) { + symbol_names_inv[it.second] = it.first; + } + + uint32_t min_addr = UINT32_MAX; + uint32_t max_addr = 0; + + if (data_section_len > 0) { + min_addr = std::min(min_addr, data_vaddr); + max_addr = std::max(max_addr, data_vaddr + data_section_len); + } + if (rodata_section_len > 0) { + min_addr = std::min(min_addr, rodata_vaddr); + max_addr = std::max(max_addr, rodata_vaddr + rodata_section_len); + } + if (bss_section_len) { + min_addr = std::min(min_addr, bss_vaddr); + max_addr = std::max(max_addr, bss_vaddr + bss_section_len); + } + + // 64 kB. Supposedly the worst-case smallest permitted page size, increase if necessary. + // Ensures the hardcoded min_addr and max_addr are sufficiently aligned for the machine running the + // recompiled binaries (and not just the one doing the original recomp build). + uint32_t page_size = 0x10000; + + min_addr = min_addr & ~(page_size - 1); + max_addr = (max_addr + (page_size - 1)) & ~(page_size - 1); + + uint32_t stack_bottom = min_addr; + min_addr -= 0x100000; // 1 MB stack + stack_bottom -= 0x10; // for main's stack frame + + printf("#include \"header.h\"\n"); + + if (conservative) { + printf("static uint32_t s0, s1, s2, s3, s4, s5, s6, s7, fp;\n"); + } + + printf("static const uint32_t rodata[] = {\n"); + + for (size_t i = 0; i < rodata_section_len; i += 4) { + printf("0x%x,%s", read_u32_be(rodata_section + i), i % 32 == 28 ? "\n" : ""); + } + + printf("};\n"); + printf("static const uint32_t data[] = {\n"); + + for (size_t i = 0; i < data_section_len; i += 4) { + printf("0x%x,%s", read_u32_be(data_section + i), i % 32 == 28 ? "\n" : ""); + } + + printf("};\n"); + + /* if (!data_function_pointers.empty()) { + printf("static const struct { uint32_t orig_addr; void *recompiled_addr; } data_function_pointers[] = {\n"); + for (auto item : data_function_pointers) { + printf("{0x%x, &&L%x},\n", item.first, item.second); + } + printf("};\n"); + } */ + + if (TRACE) { + printf("static unsigned long long int cnt = 0;\n"); + } + + for (auto& f_it : functions) { + uint32_t addr = f_it.first; + auto& ins = insns.at(addr_to_i(addr)); + + if (ins.f_livein != 0) { + // Function is used + dump_function_signature(f_it.second, addr); + printf(";\n"); + } + } + + if (!data_function_pointers.empty() || !la_function_pointers.empty()) { + printf("uint64_t trampoline(uint8_t *mem, uint32_t sp, uint32_t a0, uint32_t a1, uint32_t a2, uint32_t a3, " + "uint32_t fp_dest) {\n"); + printf("switch (fp_dest) {\n"); + + for (auto& it : functions) { + Function& f = it.second; + + if (f.referenced_by_function_pointer) { + printf("case 0x%x: ", it.first); + + if (f.nret == 1) { + printf("return (uint64_t)"); + } else if (f.nret == 2) { + printf("return "); + } + + auto name_it = symbol_names.find(it.first); + + if (name_it != symbol_names.end()) { + printf("f_%s", name_it->second.c_str()); + } else { + printf("func_%x", it.first); + } + + printf("(mem, sp"); + + for (unsigned int i = 0; i < f.nargs; i++) { + printf(", a%d", i); + } + + printf(")"); + + if (f.nret == 1) { + printf(" << 32"); + } + + printf(";"); + + if (f.nret == 0) { + printf(" return 0;"); + } + + printf("\n"); + } + } + + printf("default: abort();"); + printf("}\n"); + printf("}\n"); + } + + printf("int run(uint8_t *mem, int argc, char *argv[]) {\n"); + printf("mmap_initial_data_range(mem, 0x%x, 0x%x);\n", min_addr, max_addr); + + printf("memcpy(mem + 0x%x, rodata, 0x%x);\n", rodata_vaddr, rodata_section_len); + printf("memcpy(mem + 0x%x, data, 0x%x);\n", data_vaddr, data_section_len); + + /* if (!data_function_pointers.empty()) { + if (!LABELS_64_BIT) { + printf("for (int i = 0; i < %d; i++) MEM_U32(data_function_pointers[i].orig_addr) = + (uint32_t)(uintptr_t)data_function_pointers[i].recompiled_addr;\n", (int)data_function_pointers.size()); } else { + printf("for (int i = 0; i < %d; i++) MEM_U32(data_function_pointers[i].orig_addr) = + (uint32_t)((uintptr_t)data_function_pointers[i].recompiled_addr - (uintptr_t)&&Loffset);\n", + (int)data_function_pointers.size()); + } + } */ + + printf("MEM_S32(0x%x) = argc;\n", symbol_names_inv.at("__Argc")); + printf("MEM_S32(0x%x) = argc;\n", stack_bottom); + printf("uint32_t al = argc * 4; for (int i = 0; i < argc; i++) al += strlen(argv[i]) + 1;\n"); + printf("uint32_t arg_addr = wrapper_malloc(mem, al);\n"); + printf("MEM_U32(0x%x) = arg_addr;\n", symbol_names_inv.at("__Argv")); + printf("MEM_U32(0x%x) = arg_addr;\n", stack_bottom + 4); + printf("uint32_t arg_strpos = arg_addr + argc * 4;\n"); + printf("for (int i = 0; i < argc; i++) {MEM_U32(arg_addr + i * 4) = arg_strpos; uint32_t p = 0; do { " + "MEM_S8(arg_strpos) = argv[i][p]; ++arg_strpos; } while (argv[i][p++] != '\\0');}\n"); + + printf("setup_libc_data(mem);\n"); + + // printf("gp = 0x%x;\n", gp_value); // only to recreate the outcome when ugen reads uninitialized stack memory + + printf("int ret = f_main(mem, 0x%x", stack_bottom); + + Function& main_func = functions[main_addr]; + + if (main_func.nargs >= 1) { + printf(", argc"); + } + + if (main_func.nargs >= 2) { + printf(", arg_addr"); + } + + printf(");\n"); + + if (TRACE) { + printf("end: fprintf(stderr, \"cnt: %%llu\\n\", cnt);\n"); + } + + printf("return ret;\n"); + printf("}\n"); + + for (auto& f_it : functions) { + Function& f = f_it.second; + uint32_t start_addr = f_it.first; + uint32_t end_addr = f.end_addr; + + if (insns[addr_to_i(start_addr)].f_livein == 0) { + // Non-used function, skip + continue; + } + + printf("\n"); + dump_function_signature(f, start_addr); + printf(" {\n"); + printf("const uint32_t zero = 0;\n"); + + if (!conservative) { + printf("uint32_t at = 0, v1 = 0, t0 = 0, t1 = 0, t2 = 0,\n"); + printf("t3 = 0, t4 = 0, t5 = 0, t6 = 0, t7 = 0, s0 = 0, s1 = 0, s2 = 0, s3 = 0, s4 = 0, s5 = 0,\n"); + printf("s6 = 0, s7 = 0, t8 = 0, t9 = 0, gp = 0, fp = 0, s8 = 0, ra = 0;\n"); + } else { + printf("uint32_t at = 0, v1 = 0, t0 = 0, t1 = 0, t2 = 0,\n"); + printf("t3 = 0, t4 = 0, t5 = 0, t6 = 0, t7 = 0, t8 = 0, t9 = 0, gp = 0x10000, ra = 0x10000;\n"); + } + + printf("uint32_t lo = 0, hi = 0;\n"); + printf("int cf = 0;\n"); + printf("uint64_t temp64;\n"); + printf("double tempf64;\n"); + printf("uint32_t fp_dest;\n"); + printf("void *dest;\n"); + + if (!f.v0_in) { + printf("uint32_t v0 = 0;\n"); + } + + for (uint32_t j = f.nargs; j < 4; j++) { + printf("uint32_t %s = 0;\n", r((int)rabbitizer::Registers::Cpu::GprO32::GPR_O32_a0 + j)); + } + + for (size_t i = addr_to_i(start_addr), end_i = addr_to_i(end_addr); i < end_i; i++) { + Insn& insn = insns[i]; + uint32_t vaddr = text_vaddr + i * 4; + if (label_addresses.count(vaddr)) { + printf("L%x:\n", vaddr); + } +#if DUMP_INSTRUCTIONS + printf("// %s:\n", insn.disassemble().c_str()); +#endif + dump_instr(i); + } + + printf("}\n"); + } + /* for (size_t i = 0; i < insns.size(); i++) { + Insn& insn = insns[i]; + uint32_t vaddr = text_vaddr + i * 4; + auto fn_it = functions.find(vaddr); + + if (fn_it != functions.end()) { + Function& f = fn_it->second; + + printf("}\n\n"); + + switch (f.nret) { + case 0: + printf("void "); + break; + + case 1: + printf("uint32_t "); + break; + + case 2: + printf("uint64_t "); + break; + } + + auto name_it = symbol_names.find(vaddr); + + if (name_it != symbol_names.end()) { + printf("%s", name_it->second.c_str()); + } else { + printf("func_%x", vaddr); + } + + printf("(uint8_t *mem, uint32_t sp"); + + if (f.v0_in) { + printf(", uint32_t %s", r(MIPS_REG_V0)); + } + + for (uint32_t i = 0; i < f.nargs; i++) { + printf(", uint32_t %s", r(MIPS_REG_A0 + i)); + } + + printf(") {\n"); + printf("const uint32_t zero = 0;\n"); + printf("uint32_t at = 0, v1 = 0, t0 = 0, t1 = 0, t2 = 0,\n"); + printf("t3 = 0, t4 = 0, t5 = 0, t6 = 0, t7 = 0, s0 = 0, s1 = 0, s2 = 0, s3 = 0, s4 = 0, s5 = 0,\n"); + printf("s6 = 0, s7 = 0, t8 = 0, t9 = 0, gp = 0, fp = 0, s8 = 0, ra = 0;\n"); + printf("uint32_t lo = 0, hi = 0;\n"); + printf("int cf = 0;\n"); + + if (!f.v0_in) { + printf("uint32_t v0 = 0;\n"); + } + + for (uint32_t j = f.nargs; j < 4; j++) { + printf("uint32_t %s = 0;\n", r(MIPS_REG_A0 + j)); + } + } + + if (label_addresses.count(vaddr)) { + printf("L%x:\n", vaddr); + } + + dump_instr(i); + } */ +} + +void parse_elf(const uint8_t* data, size_t file_len) { + Elf32_Ehdr* ehdr; + Elf32_Shdr *shdr, *str_shdr, *sym_shdr = NULL, *dynsym_shdr, *dynamic_shdr, *reginfo_shdr, *got_shdr, + *sym_strtab = NULL, *sym_dynstr; + int text_section_index = -1; + int symtab_section_index = -1; + int dynsym_section_index = -1; + int reginfo_section_index = -1; + int dynamic_section_index = -1; + int got_section_index = -1; + int rodata_section_index = -1; + int data_section_index = -1; + int bss_section_index = -1; + uint32_t text_offset = 0; + uint32_t vaddr_adj = 0; + + if (file_len < 4 || data[0] != 0x7f || data[1] != 'E' || data[2] != 'L' || data[3] != 'F') { + fprintf(stderr, "Not an ELF file.\n"); + exit(EXIT_FAILURE); + } + + ehdr = (Elf32_Ehdr*)data; + if (ehdr->e_ident[EI_DATA] != 2 || u16be(ehdr->e_machine) != 8) { + fprintf(stderr, "Not big-endian MIPS.\n"); + exit(EXIT_FAILURE); + } + + if (u16be(ehdr->e_shstrndx) == 0) { + // (We could look at program headers instead in this case.) + fprintf(stderr, "Missing section headers; stripped binaries are not yet supported.\n"); + exit(EXIT_FAILURE); + } + +#define SECTION(index) (Elf32_Shdr*)(data + u32be(ehdr->e_shoff) + (index)*u16be(ehdr->e_shentsize)) +#define STR(strtab, offset) (const char*)(data + u32be(strtab->sh_offset) + offset) + + str_shdr = SECTION(u16be(ehdr->e_shstrndx)); + for (int i = 0; i < u16be(ehdr->e_shnum); i++) { + shdr = SECTION(i); + + const char* name = STR(str_shdr, u32be(shdr->sh_name)); + + if (strcmp(name, ".text") == 0) { + text_offset = u32be(shdr->sh_offset); + text_vaddr = u32be(shdr->sh_addr); + vaddr_adj = text_vaddr - u32be(shdr->sh_addr); + text_section_len = u32be(shdr->sh_size); + text_section = data + text_offset; + text_section_index = i; + } + + if (u32be(shdr->sh_type) == SHT_SYMTAB) { + symtab_section_index = i; + } + + if (u32be(shdr->sh_type) == SHT_DYNSYM) { + dynsym_section_index = i; + } + + if (u32be(shdr->sh_type) == SHT_MIPS_REGINFO) { + reginfo_section_index = i; + } + + if (u32be(shdr->sh_type) == SHT_DYNAMIC) { + dynamic_section_index = i; + } + + if (strcmp(name, ".got") == 0) { + got_section_index = i; + } + + if (strcmp(name, ".rodata") == 0) { + rodata_section_index = i; + } + + if (strcmp(name, ".data") == 0) { + data_section_index = i; + } + + if (strcmp(name, ".bss") == 0) { + bss_section_index = i; + } + } + + if (text_section_index == -1) { + fprintf(stderr, "Missing .text section.\n"); + exit(EXIT_FAILURE); + } + + if (symtab_section_index == -1 && dynsym_section_index == -1) { + fprintf(stderr, "Missing .symtab or .dynsym section.\n"); + exit(EXIT_FAILURE); + } + + if (dynsym_section_index != -1) { + if (reginfo_section_index == -1) { + fprintf(stderr, "Missing .reginfo section.\n"); + exit(EXIT_FAILURE); + } + + if (dynamic_section_index == -1) { + fprintf(stderr, "Missing .dynamic section.\n"); + exit(EXIT_FAILURE); + } + + if (got_section_index == -1) { + fprintf(stderr, "Missing .got section.\n"); + exit(EXIT_FAILURE); + } + } + + if (rodata_section_index != -1) { + shdr = SECTION(rodata_section_index); + uint32_t size = u32be(shdr->sh_size); + rodata_section = data + u32be(shdr->sh_offset); + rodata_section_len = size; + rodata_vaddr = u32be(shdr->sh_addr); + } + + if (data_section_index != -1) { + shdr = SECTION(data_section_index); + uint32_t size = u32be(shdr->sh_size); + data_section = data + u32be(shdr->sh_offset); + data_section_len = size; + data_vaddr = u32be(shdr->sh_addr); + } + + if (bss_section_index != -1) { + shdr = SECTION(bss_section_index); + uint32_t size = u32be(shdr->sh_size); + bss_section_len = size; + bss_vaddr = u32be(shdr->sh_addr); + } + + // add symbols + if (symtab_section_index != -1) { + sym_shdr = SECTION(symtab_section_index); + sym_strtab = SECTION(u32be(sym_shdr->sh_link)); + assert(0 && ".symtab not supported - use a program with .dynsym instead"); + + assert(u32be(sym_shdr->sh_entsize) == sizeof(Elf32_Sym)); + for (uint32_t i = 0; i < u32be(sym_shdr->sh_size); i += sizeof(Elf32_Sym)) { + Elf32_Sym* sym = (Elf32_Sym*)(data + u32be(sym_shdr->sh_offset) + i); + const char* name = STR(sym_strtab, u32be(sym->st_name)); + uint32_t addr = u32be(sym->st_value); + + if (u16be(sym->st_shndx) != text_section_index || name[0] == '.') { + continue; + } + + addr += vaddr_adj; + // disasm_label_add(state, name, addr, u32be(sym->st_size), true); + } + } + + if (dynsym_section_index != -1) { + dynsym_shdr = SECTION(dynsym_section_index); + sym_dynstr = SECTION(u32be(dynsym_shdr->sh_link)); + reginfo_shdr = SECTION(reginfo_section_index); + dynamic_shdr = SECTION(dynamic_section_index); + got_shdr = SECTION(got_section_index); + + Elf32_RegInfo* reg_info = (Elf32_RegInfo*)(data + u32be(reginfo_shdr->sh_offset)); + uint32_t gp_base = u32be(reg_info->ri_gp_value); // gp should have this value through the program run + uint32_t got_start = 0; + uint32_t local_got_no = 0; + uint32_t first_got_sym = 0; + uint32_t dynsym_no = 0; // section size can't be used due to alignment 16 padding + + assert(u32be(dynamic_shdr->sh_entsize) == sizeof(Elf32_Dyn)); + for (uint32_t i = 0; i < u32be(dynamic_shdr->sh_size); i += sizeof(Elf32_Dyn)) { + Elf32_Dyn* dyn = (Elf32_Dyn*)(data + u32be(dynamic_shdr->sh_offset) + i); + + if (u32be(dyn->d_tag) == DT_PLTGOT) { + got_start = u32be(dyn->d_un.d_ptr); + } + + if (u32be(dyn->d_tag) == DT_MIPS_LOCAL_GOTNO) { + local_got_no = u32be(dyn->d_un.d_val); + } + + if (u32be(dyn->d_tag) == DT_MIPS_GOTSYM) { + first_got_sym = u32be(dyn->d_un.d_val); + } + + if (u32be(dyn->d_tag) == DT_MIPS_SYMTABNO) { + dynsym_no = u32be(dyn->d_un.d_val); + } + } + + assert(got_start != 0); + + // value to add to asm gp offset, for example 32752, if -32752(gp) refers to the first entry in got. + uint32_t gp_adj = gp_base - got_start; + + assert(gp_adj < 0x10000); + + assert(u32be(dynsym_shdr->sh_entsize) == sizeof(Elf32_Sym)); + + uint32_t global_got_no = dynsym_no - first_got_sym; + // global_got_entry *global_entries = (global_got_entry *)calloc(global_got_no, sizeof(global_got_entry)); + + got_globals.resize(global_got_no); + + uint32_t common_start = ~0U; + vector common_order; + + for (uint32_t i = 0; i < dynsym_no; i++) { + Elf32_Sym* sym = (Elf32_Sym*)(data + u32be(dynsym_shdr->sh_offset) + i * sizeof(Elf32_Sym)); + const char* name = STR(sym_dynstr, u32be(sym->st_name)); + uint32_t addr = u32be(sym->st_value); + + addr += vaddr_adj; + + uint8_t type = ELF32_ST_TYPE(sym->st_info); + + if (!strcmp(name, "_procedure_table")) { + procedure_table_start = addr; + } else if (!strcmp(name, "_procedure_table_size")) { + procedure_table_len = 40 * u32be(sym->st_value); + } + + if ((u16be(sym->st_shndx) == SHN_MIPS_TEXT && type == STT_FUNC) || + (type == STT_OBJECT && + (u16be(sym->st_shndx) == SHN_MIPS_ACOMMON || u16be(sym->st_shndx) == SHN_MIPS_DATA))) { + // disasm_label_add(state, name, addr, u32be(sym->st_size), true); + if (type == STT_OBJECT) {} + + if (u16be(sym->st_shndx) == SHN_MIPS_ACOMMON) { + if (addr < common_start) { + common_start = addr; + } + + common_order.push_back(name); + } + + if (type == STT_FUNC) { + add_function(addr); + + if (strcmp(name, "main") == 0) { + main_addr = addr; + } + + if (strcmp(name, "_mcount") == 0) { + mcount_addr = addr; + } + + symbol_names[addr] = name; + } + } + + if (i >= first_got_sym) { + uint32_t got_value = u32be(*(uint32_t*)(data + u32be(got_shdr->sh_offset) + + (local_got_no + (i - first_got_sym)) * sizeof(uint32_t))); + + if (u16be(sym->st_shndx) == SHN_MIPS_TEXT && type == STT_FUNC) { + // got_globals[i - first_got_sym] = got_value; + // label_addresses.insert(got_value); + got_globals[i - first_got_sym] = addr; // to include the 3 instr gp header thing + label_addresses.insert(addr); + } else if (type == STT_OBJECT && + (u16be(sym->st_shndx) == SHN_UNDEF || u16be(sym->st_shndx) == SHN_COMMON)) { + // symbol defined externally (for example in libc) + got_globals[i - first_got_sym] = got_value; + } else { + got_globals[i - first_got_sym] = addr; + } + + symbol_names[got_globals[i - first_got_sym]] = name; + } + } + + uint32_t* local_entries = (uint32_t*)calloc(local_got_no, sizeof(uint32_t)); + got_locals.resize(local_got_no); + for (uint32_t i = 0; i < local_got_no; i++) { + uint32_t* entry = (uint32_t*)(data + u32be(got_shdr->sh_offset) + i * sizeof(uint32_t)); + got_locals[i] = u32be(*entry); + } + + gp_value = gp_base; + gp_value_adj = gp_adj; + + free(local_entries); + } + + // add relocations + for (int i = 0; i < u16be(ehdr->e_shnum); i++) { + Elf32_Rel* prevHi = NULL; + + shdr = SECTION(i); + if (u32be(shdr->sh_type) != SHT_REL || u32be(shdr->sh_info) != (uint32_t)text_section_index) + continue; + + if (sym_shdr == NULL) { + fprintf(stderr, "Relocations without .symtab section\n"); + exit(EXIT_FAILURE); + } + + assert(u32be(shdr->sh_link) == (uint32_t)symtab_section_index); + assert(u32be(shdr->sh_entsize) == sizeof(Elf32_Rel)); + + for (uint32_t i = 0; i < u32be(shdr->sh_size); i += sizeof(Elf32_Rel)) { + Elf32_Rel* rel = (Elf32_Rel*)(data + u32be(shdr->sh_offset) + i); + uint32_t offset = text_offset + u32be(rel->r_offset); + uint32_t symIndex = ELF32_R_SYM(u32be(rel->r_info)); + uint32_t rtype = ELF32_R_TYPE(u32be(rel->r_info)); + const char* symName = "0"; + + if (symIndex != STN_UNDEF) { + Elf32_Sym* sym = (Elf32_Sym*)(data + u32be(sym_shdr->sh_offset) + symIndex * sizeof(Elf32_Sym)); + + symName = STR(sym_strtab, u32be(sym->st_name)); + } + + if (rtype == R_MIPS_HI16) { + if (prevHi != NULL) { + fprintf(stderr, "Consecutive R_MIPS_HI16.\n"); + exit(EXIT_FAILURE); + } + + prevHi = rel; + continue; + } + + if (rtype == R_MIPS_LO16) { + int32_t addend = (int16_t)((data[offset + 2] << 8) + data[offset + 3]); + + if (prevHi != NULL) { + uint32_t offset2 = text_offset + u32be(prevHi->r_offset); + + addend += (uint32_t)((data[offset2 + 2] << 8) + data[offset2 + 3]) << 16; + // add_reloc(state, offset2, symName, addend, out_range.vaddr); + } + prevHi = NULL; + // add_reloc(state, offset, symName, addend, out_range.vaddr); + } else if (rtype == R_MIPS_26) { + int32_t addend = (u32be(*(uint32_t*)(data + offset)) & ((1 << 26) - 1)) << 2; + + if (addend >= (1 << 27)) { + addend -= 1 << 28; + } + // add_reloc(state, offset, symName, addend, out_range.vaddr); + } + + else { + fprintf(stderr, "Bad relocation type %d.\n", rtype); + exit(EXIT_FAILURE); + } + } + + if (prevHi != NULL) { + fprintf(stderr, "R_MIPS_HI16 without matching R_MIPS_LO16.\n"); + exit(EXIT_FAILURE); + } + } +} +#undef SECTION +#undef STR + +size_t read_file(const char* file_name, uint8_t** data) { + FILE* in; + uint8_t* in_buf = NULL; + long file_size; + long bytes_read; + + in = fopen(file_name, "rb"); + assert(in != nullptr); + + // allocate buffer to read from offset to end of file + fseek(in, 0, SEEK_END); + file_size = ftell(in); + assert(file_size != -1L); + + in_buf = (uint8_t*)malloc(file_size); + fseek(in, 0, SEEK_SET); + + // read bytes + bytes_read = fread(in_buf, 1, file_size, in); + assert(bytes_read == file_size); + + fclose(in); + *data = in_buf; + return bytes_read; +} + +#ifdef UNIX_PLATFORM +void crashHandler(int sig) { + void* array[4096]; + const size_t nMaxFrames = std::size(array); + size_t size = backtrace(array, nMaxFrames); + char** symbols = backtrace_symbols(array, nMaxFrames); + + fprintf(stderr, "\n recomp crashed. (Signal: %i)\n", sig); + + // Feel free to add more crash messages. + const char* crashEasterEgg[] = { + "\tIT'S A SECRET TO EVERYBODY. \n\tBut it shouldn't be, you'd better ask about it!", + "\tI AM ERROR.", + "\tGRUMBLE,GRUMBLE...", + "\tDODONGO DISLIKES SMOKE \n\tAnd recomp dislikes whatever you fed it.", + "\tMay the way of the Hero lead \n\tto the debugger.", + "\tTHE WIND FISH SLUMBERS LONG... \n\tTHE HERO'S LIFE GONE... ", + "\tSEA BEARS FOAM, SLEEP BEARS DREAMS. \n\tBOTH END IN THE SAME WAY CRASSSH!", + "\tYou've met with a terrible fate, haven't you?", + "\tMaster, I calculate a 100% probability that recomp has crashed. \n\tAdditionally, the " + "batteries in your Wii Remote are nearly depleted.", + "\t CONGRATURATIONS! \n" + "\tAll Pages are displayed.\n" + "\t THANK YOU! \n" + "\t You are great debugger!", + "\tRCP is HUNG UP!!\n" + "\tOh! MY GOD!!", + }; + + srand(time(nullptr)); + auto easterIndex = rand() % std::size(crashEasterEgg); + + fprintf(stderr, "\n%s\n\n", crashEasterEgg[easterIndex]); + + fprintf(stderr, "Traceback:\n"); + for (size_t i = 1; i < size; i++) { + Dl_info info; + uint32_t gotAddress = dladdr(array[i], &info); + std::string functionName(symbols[i]); + + if (gotAddress != 0 && info.dli_sname != nullptr) { + int32_t status; + char* demangled = abi::__cxa_demangle(info.dli_sname, nullptr, nullptr, &status); + const char* nameFound = info.dli_sname; + + if (status == 0) { + nameFound = demangled; + } + + { + char auxBuffer[0x8000]; + + snprintf(auxBuffer, std::size(auxBuffer), "%s (+0x%lX)", nameFound, + (char*)array[i] - (char*)info.dli_saddr); + functionName = auxBuffer; + } + free(demangled); + +#if FULL_TRACEBACK == 0 + fprintf(stderr, "%-3zd %s\n", i, functionName.c_str()); +#endif + } + +#if FULL_TRACEBACK != 0 + fprintf(stderr, "%-3zd %s\n", i, functionName.c_str()); +#endif + } + + fprintf(stderr, "\n"); + + free(symbols); + exit(1); +} +#endif + +int main(int argc, char* argv[]) { + const char* filename = argv[1]; + + if (strcmp(filename, "--conservative") == 0) { + conservative = true; + filename = argv[2]; + } + +#ifdef UNIX_PLATFORM + signal(SIGSEGV, crashHandler); + signal(SIGABRT, crashHandler); +#endif + + uint8_t* data; + size_t len = read_file(filename, &data); + + parse_elf(data, len); + disassemble(); + inspect_data_function_pointers(data_function_pointers, rodata_section, rodata_vaddr, rodata_section_len); + inspect_data_function_pointers(data_function_pointers, data_section, data_vaddr, data_section_len); + pass1(); + pass2(); + pass3(); + pass4(); + pass5(); + pass6(); + // dump(); + dump_c(); + free(data); + + return 0; +} diff --git a/tools/ido-static-recomp/tools/rabbitizer/.clang-format b/tools/ido-static-recomp/tools/rabbitizer/.clang-format new file mode 100644 index 00000000..414e3cff --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/.clang-format @@ -0,0 +1,23 @@ +IndentWidth: 4 +Language: Cpp +UseTab: Never +ColumnLimit: 160 +PointerAlignment: Right +BreakBeforeBraces: Attach +SpaceAfterCStyleCast: false +Cpp11BracedListStyle: false +IndentCaseLabels: true +BinPackArguments: true +BinPackParameters: true +AlignAfterOpenBracket: Align +AlignOperands: true +BreakBeforeTernaryOperators: true +BreakBeforeBinaryOperators: None +AllowShortBlocksOnASingleLine: true +AllowShortIfStatementsOnASingleLine: false +AllowShortLoopsOnASingleLine: false +AllowShortCaseLabelsOnASingleLine: false +AllowShortFunctionsOnASingleLine: false +AlignEscapedNewlines: Left +AlignTrailingComments: true +SortIncludes: false diff --git a/tools/ido-static-recomp/tools/rabbitizer/.clang-tidy b/tools/ido-static-recomp/tools/rabbitizer/.clang-tidy new file mode 100644 index 00000000..8534b8a6 --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/.clang-tidy @@ -0,0 +1,9 @@ +Checks: 'readability-*,-readability-magic-numbers,clang-diagnostic-*,clang-analyzer-*,-clang-analyzer-security.insecureAPI.DeprecatedOrUnsafeBufferHandling,bugprone*,-bugprone-branch-clone,modernize*,performance*,portability*,diagnostic-*,analyzer-*,misc*,-misc-no-recursion' +WarningsAsErrors: '' +HeaderFilterRegex: '(src|include)\/.*\.h$' +FormatStyle: 'file' +CheckOptions: + # Require argument names to match exactly (instead of allowing a name to be a prefix/suffix of another) + # Note: 'true' is expected by clang-tidy 12+ but '1' is used for compatibility with older versions + - key: readability-inconsistent-declaration-parameter-name.Strict + value: 1 diff --git a/tools/ido-static-recomp/tools/rabbitizer/.gitattributes b/tools/ido-static-recomp/tools/rabbitizer/.gitattributes new file mode 100644 index 00000000..dfe07704 --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/.gitattributes @@ -0,0 +1,2 @@ +# Auto detect text files and perform LF normalization +* text=auto diff --git a/tools/ido-static-recomp/tools/rabbitizer/.github/workflows/ci.yml b/tools/ido-static-recomp/tools/rabbitizer/.github/workflows/ci.yml new file mode 100644 index 00000000..6baeb371 --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/.github/workflows/ci.yml @@ -0,0 +1,54 @@ +name: Build and upload to PyPI + +# Build on every branch push, tag push, and pull request change: +on: [push, pull_request] + +jobs: + build_wheels: + name: Build wheels on ${{ matrix.os }} + runs-on: ${{ matrix.os }} + strategy: + matrix: + os: [ubuntu-latest, macos-latest, windows-latest] + + steps: + - uses: actions/checkout@v2 + + - name: Build wheels + uses: pypa/cibuildwheel@v2.5.0 + env: + CIBW_ARCHS_WINDOWS: "auto" + CIBW_ARCHS_LINUX: "auto" + CIBW_ARCHS_MACOS: "all" + + - uses: actions/upload-artifact@v2 + with: + path: ./wheelhouse/*.whl + + build_sdist: + name: Build source distribution + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v2 + + - name: Build sdist + run: pipx run build --sdist + + - uses: actions/upload-artifact@v2 + with: + path: dist/*.tar.gz + + upload_pypi: + needs: [build_wheels, build_sdist] + runs-on: ubuntu-latest + if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags/') + steps: + - uses: actions/download-artifact@v2 + with: + name: artifact + path: dist + + - uses: pypa/gh-action-pypi-publish@v1.4.2 + with: + user: __token__ + password: ${{ secrets.pypi_password }} diff --git a/tools/ido-static-recomp/tools/rabbitizer/.github/workflows/make.yml b/tools/ido-static-recomp/tools/rabbitizer/.github/workflows/make.yml new file mode 100644 index 00000000..3079d9e3 --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/.github/workflows/make.yml @@ -0,0 +1,14 @@ +name: make + +# Build on every branch push, tag push, and pull request change: +on: [push, pull_request] + +jobs: + build: + + runs-on: ubuntu-latest + + steps: + - uses: actions/checkout@v3 + - name: make + run: make WERROR=1 diff --git a/tools/ido-static-recomp/tools/rabbitizer/.gitignore b/tools/ido-static-recomp/tools/rabbitizer/.gitignore new file mode 100644 index 00000000..e433d8d7 --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/.gitignore @@ -0,0 +1,215 @@ +# https://raw.githubusercontent.com/github/gitignore/main/C.gitignore +# https://raw.githubusercontent.com/github/gitignore/main/Python.gitignore + +# Prerequisites +*.d + +# Object files +*.o +*.ko +*.obj +*.elf + +# Linker output +*.ilk +*.map +*.exp + +# Precompiled Headers +*.gch +*.pch + +# Libraries +*.lib +*.a +*.la +*.lo + +# Shared objects (inc. Windows DLLs) +*.dll +*.so +*.so.* +*.dylib + +# Executables +*.exe +*.out +*.app +*.i*86 +*.x86_64 +*.hex + +# Debug files +*.dSYM/ +*.su +*.idb +*.pdb + +# Kernel Module Compile Results +*.mod* +*.cmd +.tmp_versions/ +modules.order +Module.symvers +Mkfile.old +dkms.conf + + + +# Byte-compiled / optimized / DLL files +__pycache__/ +*.py[cod] +*$py.class + +# C extensions +*.so + +# Distribution / packaging +.Python +build/ +develop-eggs/ +dist/ +downloads/ +eggs/ +.eggs/ +lib/ +lib64/ +parts/ +sdist/ +var/ +wheels/ +share/python-wheels/ +*.egg-info/ +.installed.cfg +*.egg +MANIFEST + +# PyInstaller +# Usually these files are written by a python script from a template +# before PyInstaller builds the exe, so as to inject date/other infos into it. +*.manifest +*.spec + +# Installer logs +pip-log.txt +pip-delete-this-directory.txt + +# Unit test / coverage reports +htmlcov/ +.tox/ +.nox/ +.coverage +.coverage.* +.cache +nosetests.xml +coverage.xml +*.cover +*.py,cover +.hypothesis/ +.pytest_cache/ +cover/ + +# Translations +*.mo +*.pot + +# Django stuff: +*.log +local_settings.py +db.sqlite3 +db.sqlite3-journal + +# Flask stuff: +instance/ +.webassets-cache + +# Scrapy stuff: +.scrapy + +# Sphinx documentation +docs/_build/ + +# PyBuilder +.pybuilder/ +target/ + +# Jupyter Notebook +.ipynb_checkpoints + +# IPython +profile_default/ +ipython_config.py + +# pyenv +# For a library or package, you might want to ignore these files since the code is +# intended to run in multiple environments; otherwise, check them in: +# .python-version + +# pipenv +# According to pypa/pipenv#598, it is recommended to include Pipfile.lock in version control. +# However, in case of collaboration, if having platform-specific dependencies or dependencies +# having no cross-platform support, pipenv may install dependencies that don't work, or not +# install all needed dependencies. +#Pipfile.lock + +# poetry +# Similar to Pipfile.lock, it is generally recommended to include poetry.lock in version control. +# This is especially recommended for binary packages to ensure reproducibility, and is more +# commonly ignored for libraries. +# https://python-poetry.org/docs/basic-usage/#commit-your-poetrylock-file-to-version-control +#poetry.lock + +# pdm +# Similar to Pipfile.lock, it is generally recommended to include pdm.lock in version control. +#pdm.lock +# pdm stores project-wide configurations in .pdm.toml, but it is recommended to not include it +# in version control. +# https://pdm.fming.dev/#use-with-ide +.pdm.toml + +# PEP 582; used by e.g. github.com/David-OConnor/pyflow and github.com/pdm-project/pdm +__pypackages__/ + +# Celery stuff +celerybeat-schedule +celerybeat.pid + +# SageMath parsed files +*.sage.py + +# Environments +.env +.venv +env/ +venv/ +ENV/ +env.bak/ +venv.bak/ + +# Spyder project settings +.spyderproject +.spyproject + +# Rope project settings +.ropeproject + +# mkdocs documentation +/site + +# mypy +.mypy_cache/ +.dmypy.json +dmypy.json + +# Pyre type checker +.pyre/ + +# pytype static type analyzer +.pytype/ + +# Cython debug symbols +cython_debug/ + + +.vscode/ + diff --git a/tools/ido-static-recomp/tools/rabbitizer/.gitrepo b/tools/ido-static-recomp/tools/rabbitizer/.gitrepo new file mode 100644 index 00000000..cbd77990 --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/.gitrepo @@ -0,0 +1,12 @@ +; DO NOT EDIT (unless you know what you are doing) +; +; This subdirectory is a git "subrepo", and this file is maintained by the +; git-subrepo command. See https://github.com/git-commands/git-subrepo#readme +; +[subrepo] + remote = git@github.com:Decompollaborate/rabbitizer.git + branch = develop + commit = 72bf240f468d30286888212b5fb773fae94340f6 + parent = fa84f928c510147d6083b979efb28a5a07eefe10 + method = merge + cmdver = 0.4.3 diff --git a/tools/ido-static-recomp/tools/rabbitizer/LICENSE b/tools/ido-static-recomp/tools/rabbitizer/LICENSE new file mode 100644 index 00000000..10a2aa35 --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/LICENSE @@ -0,0 +1,21 @@ +MIT License + +Copyright (c) 2022 Decompollaborate + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/tools/ido-static-recomp/tools/rabbitizer/MANIFEST.in b/tools/ido-static-recomp/tools/rabbitizer/MANIFEST.in new file mode 100644 index 00000000..1e60716c --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/MANIFEST.in @@ -0,0 +1,6 @@ +# SPDX-FileCopyrightText: © 2022 Decompollaborate +# SPDX-License-Identifier: MIT + +include **/*.h +include **/**/*.h +graft include diff --git a/tools/ido-static-recomp/tools/rabbitizer/Makefile b/tools/ido-static-recomp/tools/rabbitizer/Makefile new file mode 100644 index 00000000..e0b92c36 --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/Makefile @@ -0,0 +1,140 @@ +# Build options can be changed by modifying the makefile or by building with 'make SETTING=value'. +DEBUG ?= 0 +WERROR ?= 0 +ASAN ?= 0 +EXPERIMENTAL ?= 0 +SANITY_CHECKS ?= 1 + +CC := clang +CXX := clang++ +AR := ar +IINC := -I include +IINC_XX := -I include -I cplusplus/include +CSTD := -std=c11 +CXXSTD := -std=c++17 +CFLAGS := -fPIC +CXXFLAGS := -fPIC +LDFLAGS := -Lbuild -lrabbitizer +LDXXFLAGS := -Lbuild -lrabbitizerpp +WARNINGS := -Wall -Wextra -Wpedantic +# WARNINGS := -Wall -Wextra -Wpedantic -Wpadded +WARNINGS += -Werror=vla -Werror=switch -Werror=implicit-fallthrough -Werror=unused-function -Werror=unused-parameter -Werror=shadow +WARNINGS_C := -Werror=implicit-function-declaration -Werror=incompatible-pointer-types +WARNINGS_CXX := + +ifeq ($(CC),gcc) + WARNINGS += -Wno-cast-function-type +endif + +ifeq ($(DEBUG),0) + OPTFLAGS := -Os -g +else + OPTFLAGS := -O0 -g3 + CFLAGS += -DDEVELOPMENT=1 + CXXFLAGS += -DDEVELOPMENT=1 +endif + +ifneq ($(WERROR),0) + WARNINGS += -Werror +endif + +ifneq ($(ASAN),0) + CFLAGS += -fsanitize=address -fsanitize=pointer-compare -fsanitize=pointer-subtract -fsanitize=undefined + CXXFLAGS += -fsanitize=address -fsanitize=pointer-compare -fsanitize=pointer-subtract -fsanitize=undefined +endif + +ifneq ($(EXPERIMENTAL),0) + CFLAGS += -DEXPERIMENTAL + CXXFLAGS += -DEXPERIMENTAL +endif + +ifneq ($(SANITY_CHECKS),0) + CFLAGS += -DRAB_SANITY_CHECKS=1 + CXXFLAGS += -DRAB_SANITY_CHECKS=1 +endif + + +SRC_DIRS := $(shell find src -type d) +C_FILES := $(foreach dir,$(SRC_DIRS),$(wildcard $(dir)/*.c)) +H_FILES := $(foreach dir,$(IINC),$(wildcard $(dir)/**/*.h)) +O_FILES := $(foreach f,$(C_FILES:.c=.o),build/$f) + +SRCXX_DIRS := $(shell find cplusplus/src -type d) +CXX_FILES := $(foreach dir,$(SRCXX_DIRS),$(wildcard $(dir)/*.cpp)) +HXX_FILES := $(foreach dir,$(IINC_XX),$(wildcard $(dir)/**/*.hpp)) +OXX_FILES := $(foreach f,$(CXX_FILES:.cpp=.o),build/$f) + +DEP_FILES := $(O_FILES:%.o=%.d) $(OXX_FILES:%.o=%.d) + +TESTS_DIRS := $(shell find tests -type d) + +STATIC_LIB := build/librabbitizer.a +DYNAMIC_LIB := build/librabbitizer.so + +STATIC_LIB_XX := build/librabbitizerpp.a +DYNAMIC_LIB_XX := build/librabbitizerpp.so + +# create build directories +$(shell mkdir -p $(foreach dir,$(SRC_DIRS) $(SRCXX_DIRS) $(TESTS_DIRS),build/$(dir))) + + +# Dependencies of libraries + +$(STATIC_LIB): $(O_FILES) +$(DYNAMIC_LIB): $(O_FILES) + +$(STATIC_LIB_XX): $(O_FILES) $(OXX_FILES) +$(DYNAMIC_LIB_XX): $(O_FILES) $(OXX_FILES) + + +#### Main Targets ### + +all: static tests + +static: $(STATIC_LIB) $(STATIC_LIB_XX) +dynamic: $(DYNAMIC_LIB) $(DYNAMIC_LIB_XX) + +clean: + $(RM) -rf build + +distclean: clean + $(RM) -rf dist rabbitizer.egg-info .mypy_cache + +format: + clang-format-11 -i -style=file $(C_FILES) + clang-format-11 -i -style=file $(CXX_FILES) + +tidy: + clang-tidy-11 -p . --fix --fix-errors $(C_FILES) $(H_FILES) -- $(CSTD) $(OPTFLAGS) $(IINC) $(WARNINGS) $(WARNINGS_C) $(CFLAGS) + +tests: build/test.elf build/rsptest.elf build/r5900test.elf build/registersTrackerTest.elf build/tests/cplusplus/test.elf + +.PHONY: all clean distclean format tidy tests +.DEFAULT_GOAL := all +.SECONDARY: + + +#### Various Recipes #### + +build/%.elf: %.c | $(STATIC_LIB) + $(CC) -MMD $(CSTD) $(OPTFLAGS) $(IINC) $(WARNINGS) $(WARNINGS_C) $(CFLAGS) -o $@ $^ $(LDFLAGS) + +build/%.elf: %.cpp | $(STATIC_LIB_XX) + $(CXX) -MMD $(CXXSTD) $(OPTFLAGS) $(IINC_XX) $(WARNINGS) $(WARNINGS_CXX) $(CXXFLAGS) -o $@ $^ $(LDXXFLAGS) + +build/%.a: + $(AR) rcs $@ $^ + +build/%.so: + $(CC) -shared -o $@ $^ + +build/%.o: %.c +# The -MMD flags additionaly creates a .d file with the same name as the .o file. + $(CC) -MMD -c $(CSTD) $(OPTFLAGS) $(IINC) $(WARNINGS) $(WARNINGS_C) $(CFLAGS) -o $@ $< + +build/%.o: %.cpp +# The -MMD flags additionaly creates a .d file with the same name as the .o file. + $(CXX) -MMD -c $(CXXSTD) $(OPTFLAGS) $(IINC_XX) $(WARNINGS) $(WARNINGS_CXX) $(CXXFLAGS) -o $@ $< + + +-include $(DEP_FILES) diff --git a/tools/ido-static-recomp/tools/rabbitizer/README.md b/tools/ido-static-recomp/tools/rabbitizer/README.md new file mode 100644 index 00000000..18bc794c --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/README.md @@ -0,0 +1,55 @@ +# rabbitizer + +[![PyPI - Downloads](https://img.shields.io/pypi/dm/rabbitizer)](https://pypi.org/project/rabbitizer/) +![GitHub](https://img.shields.io/github/license/Decompollaborate/rabbitizer) +![GitHub release (latest SemVer)](https://img.shields.io/github/v/release/Decompollaborate/rabbitizer) +![PyPI](https://img.shields.io/pypi/v/rabbitizer) +![GitHub contributors](https://img.shields.io/github/contributors/Decompollaborate/rabbitizer?logo=purple) + +A MIPS instruction decoder API. + +Currently supports all the CPU instructions for MIPS I, II, III and IV. + +## Installing + +The recommended way to install is using from the PyPi release, via `pip`: + +```bash +pip install rabbitizer +``` + +In case you want to mess with the latest development version without wanting to clone the repository, then you could use the following command: + +```bash +pip install git+https://github.com/Decompollaborate/rabbitizer.git@develop +``` + +NOTE: Installing the development version is not recommended. Proceed at your own risk. + +## Features + +- Should produces matching assembly. +- Fully written in C for fast decoding. +- Python bindings. + - The minimal Python version is 3.7, older versions are not guaranteed to work. +- Includes some minor tools to build your own pointer/symbol detection. +- Configurable, many features can be turned on and off. +- MIPS instructions features: + - Named registers for MIPS VR4300's coprocessors. + - Support for many pseudoinstructions. + - Properly handle move to/from coprocessor instructions. + - Support for numeric, o32, n32 and n64 ABI register names. +- Some workarounds for some specific compilers/assemblers: + - `SN64`: + - `div`/`divu` fix: tweaks a bit the produced `div`, `divu` and `break` instructions. +- N64 RSP instruction decoding support. + - RSP decoding has been tested to build back to matching assemblies with [armips](https://github.com/Kingcom/armips/). +- R5900 (PS2's Emotion Engine processor) decoding support. + +## References + +- R5900: + - EmotionEngine instruction decoding: + - Official documentation from Toshiba: + - VU instruction manual: + - GNU binutils: diff --git a/tools/ido-static-recomp/tools/rabbitizer/cplusplus/include/analysis/LoPairingInfo.hpp b/tools/ido-static-recomp/tools/rabbitizer/cplusplus/include/analysis/LoPairingInfo.hpp new file mode 100644 index 00000000..020761a5 --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/cplusplus/include/analysis/LoPairingInfo.hpp @@ -0,0 +1,36 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +#ifndef RABBITIZER_LO_PAIRING_INFO_HPP +#define RABBITIZER_LO_PAIRING_INFO_HPP +#pragma once + +#include "analysis/RabbitizerLoPairingInfo.h" + + +namespace rabbitizer { + class LoPairingInfo { + protected: + RabbitizerLoPairingInfo pairingInfo; + + public: + LoPairingInfo(); + LoPairingInfo(const RabbitizerLoPairingInfo &pairingInfo); + + /** + * Returns a pointer to the inner RabbitizerLoPairingInfo. + * It is recommended to not mess with it unless you know what you are doing. + */ + RabbitizerLoPairingInfo *getCPtr(); + const RabbitizerLoPairingInfo *getCPtr() const; + + int getInstrOffset() const; + int64_t getValue() const; + bool shouldProcess() const; + bool isGpRel() const; + bool isGpGot() const; + }; +}; + + +#endif diff --git a/tools/ido-static-recomp/tools/rabbitizer/cplusplus/include/analysis/RegistersTracker.hpp b/tools/ido-static-recomp/tools/rabbitizer/cplusplus/include/analysis/RegistersTracker.hpp new file mode 100644 index 00000000..d3e1cb9e --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/cplusplus/include/analysis/RegistersTracker.hpp @@ -0,0 +1,49 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +#ifndef RABBITIZER_REGISTERS_TRACKER_HPP +#define RABBITIZER_REGISTERS_TRACKER_HPP +#pragma once + +#include "analysis/RabbitizerRegistersTracker.h" + +#include "analysis/LoPairingInfo.hpp" +#include "instructions/InstructionBase.hpp" + + +namespace rabbitizer { + class RegistersTracker { + protected: + RabbitizerRegistersTracker tracker; + + public: + RegistersTracker(); + RegistersTracker(const RegistersTracker &other); + virtual ~RegistersTracker(); + + /** + * Returns a pointer to the inner RabbitizerRegistersTracker. + * It is recommended to not mess with it unless you know what you are doing. + */ + RabbitizerRegistersTracker *getCPtr(); + const RabbitizerRegistersTracker *getCPtr() const; + + bool moveRegisters(const InstructionBase &instr); + void overwriteRegisters(const InstructionBase &instr, int instrOffset); + void unsetRegistersAfterFuncCall(const InstructionBase &instr, const InstructionBase &prevInstr); + bool getAddressIfCanSetType(const InstructionBase &instr, int instrOffset, uint32_t *dstAddress) const; + bool getJrInfo(const InstructionBase &instr, int *dstOffset, uint32_t *dstAddress) const; + + void processLui(const InstructionBase &instr, int instrOffset); + void processLui(const InstructionBase &instr, int instrOffset, const InstructionBase &prevInstr); + void processGpLoad(const InstructionBase &instr, int instrOffset); + bool getLuiOffsetForConstant(const InstructionBase &instr, int *dstOffset) const; + void processConstant(const InstructionBase &instr, uint32_t value, int offset); + LoPairingInfo preprocessLoAndGetInfo(const InstructionBase &instr, int instrOffset); + void processLo(const InstructionBase &instr, uint32_t value, int offset); + bool hasLoButNoHi(const InstructionBase &instr) const; + }; +}; + + +#endif diff --git a/tools/ido-static-recomp/tools/rabbitizer/cplusplus/include/instructions/InstrId.hpp b/tools/ido-static-recomp/tools/rabbitizer/cplusplus/include/instructions/InstrId.hpp new file mode 100644 index 00000000..59bf46f5 --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/cplusplus/include/instructions/InstrId.hpp @@ -0,0 +1,38 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +#ifndef RABBITIZER_INSTRID_HPP +#define RABBITIZER_INSTRID_HPP +#pragma once + +#include + + +namespace rabbitizer { + namespace InstrId { + #define RABBITIZER_DEF_INSTR_ID(prefix, caseBits, name, ...) \ + prefix##_##name, + + #define RABBITIZER_DEF_INSTR_ID_ALTNAME(prefix, caseBits, name, altname, ...) \ + RABBITIZER_DEF_INSTR_ID(prefix, caseBits, name, __VA_ARGS__) + + enum class UniqueId { + #include "instructions/instr_id/RabbitizerInstrId_cpu.inc" + + #include "instructions/instr_id/RabbitizerInstrId_rsp.inc" + + #include "instructions/instr_id/RabbitizerInstrId_r5900.inc" + + ALL_MAX = RABBITIZER_DEF_INSTR_ID(r5900, , MAX, ) + }; + + #undef RABBITIZER_DEF_INSTR_ID + #undef RABBITIZER_DEF_INSTR_ID_ALTNAME + + + std::string getOpcodeName(UniqueId uniqueId); + }; +}; + + +#endif diff --git a/tools/ido-static-recomp/tools/rabbitizer/cplusplus/include/instructions/InstructionBase.hpp b/tools/ido-static-recomp/tools/rabbitizer/cplusplus/include/instructions/InstructionBase.hpp new file mode 100644 index 00000000..ced9901a --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/cplusplus/include/instructions/InstructionBase.hpp @@ -0,0 +1,253 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +#ifndef RABBITIZER_INSTRUCTION_BASE_HPP +#define RABBITIZER_INSTRUCTION_BASE_HPP +#pragma once + +#include +#include + +#include "instructions/RabbitizerInstruction.h" + +#include "instructions/Registers.hpp" +#include "instructions/OperandType.hpp" +#include "instructions/InstrId.hpp" + + +namespace rabbitizer { + class InstructionBase { + protected: + RabbitizerInstruction instr; + + InstructionBase() = default; + virtual ~InstructionBase() = default; + + public: + /** + * Returns a pointer to the inner RabbitizerInstruction. + * It is recommended to not mess with it unless you know what you are doing. + */ + RabbitizerInstruction *getCPtr(); + const RabbitizerInstruction *getCPtr() const; + + /* getters */ + + uint8_t Get_opcode() const; + uint8_t Get_sa() const; + uint8_t Get_function() const; + + Registers::Cpu::GprO32 GetO32_rs() const; + Registers::Cpu::GprO32 GetO32_rt() const; + Registers::Cpu::GprO32 GetO32_rd() const; + + Registers::Cpu::GprN32 GetN32_rs() const; + Registers::Cpu::GprN32 GetN32_rt() const; + Registers::Cpu::GprN32 GetN32_rd() const; + + Registers::Cpu::Cop0 Get_cop0d() const; + + uint32_t Get_instr_index() const; + uint16_t Get_immediate() const; + + Registers::Cpu::Cop1O32 GetO32_fs() const; + Registers::Cpu::Cop1O32 GetO32_ft() const; + Registers::Cpu::Cop1O32 GetO32_fd() const; + + Registers::Cpu::Cop1N32 GetN32_fs() const; + Registers::Cpu::Cop1N32 GetN32_ft() const; + Registers::Cpu::Cop1N32 GetN32_fd() const; + + Registers::Cpu::Cop1N64 GetN64_fs() const; + Registers::Cpu::Cop1N64 GetN64_ft() const; + Registers::Cpu::Cop1N64 GetN64_fd() const; + + Registers::Cpu::Cop1Control Get_cop1cs() const; + + Registers::Cpu::Cop2 Get_cop2t() const; + + uint8_t Get_op() const; + + uint32_t Get_code() const; + uint32_t Get_code_upper() const; + uint32_t Get_code_lower() const; + + uint32_t Get_copraw() const; + + uint8_t Get_fmt() const; + uint8_t Get_fc() const; + uint8_t Get_cond() const; + + uint8_t Get_tf() const; + uint8_t Get_nd() const; + uint8_t Get_bc_fmt() const; + + uint8_t Get_stype() const; + + /* getters */ + + + /* setters */ + + void Set_opcode(uint8_t val); + void Set_sa(uint8_t val); + void Set_function(uint8_t val); + + void Set_rs(Registers::Cpu::GprO32 val); + void Set_rt(Registers::Cpu::GprO32 val); + void Set_rd(Registers::Cpu::GprO32 val); + + void Set_rs(Registers::Cpu::GprN32 val); + void Set_rt(Registers::Cpu::GprN32 val); + void Set_rd(Registers::Cpu::GprN32 val); + + void Set_cop0d(Registers::Cpu::Cop0 val); + + void Set_instr_index(uint32_t val); + void Set_immediate(uint16_t val); + + void Set_fs(Registers::Cpu::Cop1O32 val); + void Set_ft(Registers::Cpu::Cop1O32 val); + void Set_fd(Registers::Cpu::Cop1O32 val); + + void Set_fs(Registers::Cpu::Cop1N32 val); + void Set_ft(Registers::Cpu::Cop1N32 val); + void Set_fd(Registers::Cpu::Cop1N32 val); + + void Set_fs(Registers::Cpu::Cop1N64 val); + void Set_ft(Registers::Cpu::Cop1N64 val); + void Set_fd(Registers::Cpu::Cop1N64 val); + + void Set_cop1cs(Registers::Cpu::Cop1Control val); + + void Set_cop2t(Registers::Cpu::Cop2 val); + + void Set_op(uint8_t val); + + void Set_code(uint32_t val); + void Set_code_upper(uint32_t val); + void Set_code_lower(uint32_t val); + + void Set_copraw(uint32_t val); + + void Set_fmt(uint8_t val); + void Set_fc(uint8_t val); + void Set_cond(uint8_t val); + + void Set_tf(uint8_t val); + void Set_nd(uint8_t val); + void Set_bc_fmt(uint8_t val); + + void Set_stype(uint8_t val); + + /* setters */ + + + /* more getters */ + + uint32_t getRaw() const; + + InstrId::UniqueId getUniqueId() const; + uint32_t getVram() const; + bool isInHandwrittenFunction() const; + + int32_t getProcessedImmediate() const; + uint32_t getInstrIndexAsVram() const; + + int32_t getBranchOffset() const; + int32_t getGenericBranchOffset(uint32_t currentVram) const; + + + std::string getOpcodeName() const; + + /* more getters */ + + + /* */ + + void blankOut(); + + + /* Instruction examination */ + + bool isImplemented() const; + bool isLikelyHandwritten() const; + bool isNop() const; + bool isUnconditionalBranch() const; + bool isJrRa() const; + bool isJrNotRa() const; + bool hasDelaySlot() const; + + std::string mapInstrToType() const; + + bool sameOpcode(const InstructionBase &other) const; + bool sameOpcodeButDifferentArguments(const InstructionBase &other) const; + + bool hasOperand(OperandType operand) const; + bool hasOperandAlias(OperandType operand) const; + + uint32_t getValidBits() const; + bool isValid() const; + + /* Instruction examination */ + + + /* Instruction descriptor */ + + bool isUnknownType() const; + bool isJType() const; + bool isIType() const; + bool isRType() const; + bool isRegimmType() const; + + // TODO + // RabbitizerInstrSuffix instrSuffix() const; + + bool isBranch() const; + bool isBranchLikely() const; + bool isJump() const; + bool isTrap() const; + + bool isFloat() const; + bool isDouble() const; + + bool isUnsigned() const; + + bool modifiesRt() const; + bool modifiesRd() const; + + bool notEmitedByCompilers() const; + + bool canBeHi() const; + bool canBeLo() const; + bool doesLink() const; + bool doesDereference() const; + bool doesLoad() const; + bool doesStore() const; + bool maybeIsMove() const; + + bool isPseudo() const; + + /* Instruction descriptor */ + + + /* Disassembly */ + + bool mustDisasmAsData() const; + + std::string disassembleOperands() const; + std::string disassembleOperands(std::string_view immOverride) const; + + std::string disassembleInstruction(int extraLJust) const; + std::string disassembleInstruction(int extraLJust, std::string_view immOverride) const; + + std::string disassembleAsData(int extraLJust) const; + + std::string disassemble(int extraLJust) const; + std::string disassemble(int extraLJust, std::string_view immOverride) const; + + /* Disassembly */ + }; +}; + +#endif diff --git a/tools/ido-static-recomp/tools/rabbitizer/cplusplus/include/instructions/InstructionCpu.hpp b/tools/ido-static-recomp/tools/rabbitizer/cplusplus/include/instructions/InstructionCpu.hpp new file mode 100644 index 00000000..ef2eec54 --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/cplusplus/include/instructions/InstructionCpu.hpp @@ -0,0 +1,20 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +#ifndef RABBITIZER_INSTRUCTION_CPU_HPP +#define RABBITIZER_INSTRUCTION_CPU_HPP +#pragma once + +#include "InstructionBase.hpp" + + +namespace rabbitizer { + class InstructionCpu : public InstructionBase { + public: + InstructionCpu(uint32_t word, uint32_t vram); + virtual ~InstructionCpu(); + }; +}; + + +#endif diff --git a/tools/ido-static-recomp/tools/rabbitizer/cplusplus/include/instructions/InstructionR5900.hpp b/tools/ido-static-recomp/tools/rabbitizer/cplusplus/include/instructions/InstructionR5900.hpp new file mode 100644 index 00000000..0be3a271 --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/cplusplus/include/instructions/InstructionR5900.hpp @@ -0,0 +1,41 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +#ifndef RABBITIZER_INSTRUCTION_R5900_HPP +#define RABBITIZER_INSTRUCTION_R5900_HPP +#pragma once + +#include "InstructionBase.hpp" + + +namespace rabbitizer { + class InstructionR5900 : public InstructionBase { + public: + InstructionR5900(uint32_t word, uint32_t vram); + virtual ~InstructionR5900(); + + Registers::R5900::VF GetR5900_vfs() const; + Registers::R5900::VF GetR5900_vft() const; + Registers::R5900::VF GetR5900_vfd() const; + + Registers::R5900::VI GetR5900_vis() const; + Registers::R5900::VI GetR5900_vit() const; + Registers::R5900::VI GetR5900_vid() const; + + uint8_t GetR5900_mmi_function() const; + uint8_t GetR5900_fhi_flo() const; + + uint8_t GetR5900_xyzw_x() const; + uint8_t GetR5900_xyzw_y() const; + uint8_t GetR5900_xyzw_z() const; + uint8_t GetR5900_xyzw_w() const; + uint8_t GetR5900_n() const; + uint8_t GetR5900_l() const; + uint8_t GetR5900_m() const; + + uint8_t GetR5900_imm5() const; + }; +}; + + +#endif diff --git a/tools/ido-static-recomp/tools/rabbitizer/cplusplus/include/instructions/InstructionRsp.hpp b/tools/ido-static-recomp/tools/rabbitizer/cplusplus/include/instructions/InstructionRsp.hpp new file mode 100644 index 00000000..f2d32a13 --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/cplusplus/include/instructions/InstructionRsp.hpp @@ -0,0 +1,40 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +#ifndef RABBITIZER_INSTRUCTION_RSP_HPP +#define RABBITIZER_INSTRUCTION_RSP_HPP +#pragma once + +#include "InstructionBase.hpp" + + +namespace rabbitizer { + class InstructionRsp : public InstructionBase { + public: + InstructionRsp(uint32_t word, uint32_t vram); + virtual ~InstructionRsp(); + + Registers::Rsp::Gpr GetRsp_rs() const; + Registers::Rsp::Gpr GetRsp_rt() const; + Registers::Rsp::Gpr GetRsp_rd() const; + + Registers::Rsp::Cop0 GetRsp_cop0d() const; + + Registers::Rsp::Cop2 GetRsp_cop2t() const; + + Registers::Rsp::Cop2Control GetRsp_cop2cd() const; + + Registers::Rsp::Vector GetRsp_vs() const; + Registers::Rsp::Vector GetRsp_vt() const; + Registers::Rsp::Vector GetRsp_vd() const; + + uint8_t GetRsp_elementhigh() const; + uint8_t GetRsp_elementlow() const; + + uint8_t GetRsp_index() const; + uint8_t GetRsp_de() const; + }; +}; + + +#endif diff --git a/tools/ido-static-recomp/tools/rabbitizer/cplusplus/include/instructions/OperandType.hpp b/tools/ido-static-recomp/tools/rabbitizer/cplusplus/include/instructions/OperandType.hpp new file mode 100644 index 00000000..abd728ad --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/cplusplus/include/instructions/OperandType.hpp @@ -0,0 +1,27 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +#ifndef RABBITIZER_OPERAND_TYPE_HPP +#define RABBITIZER_OPERAND_TYPE_HPP +#pragma once + + +namespace rabbitizer { + #define RAB_DEF_OPERAND(prefix, operand) \ + prefix##_##operand, + + enum class OperandType { + RAB_DEF_OPERAND(ALL, INVALID) + + #include "instructions/operands/RabbitizerOperandType_cpu.inc" + #include "instructions/operands/RabbitizerOperandType_rsp.inc" + #include "instructions/operands/RabbitizerOperandType_r5900.inc" + + RAB_DEF_OPERAND(ALL, MAX) + }; + + #undef RAB_DEF_OPERAND +}; + + +#endif diff --git a/tools/ido-static-recomp/tools/rabbitizer/cplusplus/include/instructions/Registers.hpp b/tools/ido-static-recomp/tools/rabbitizer/cplusplus/include/instructions/Registers.hpp new file mode 100644 index 00000000..ceddd8f8 --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/cplusplus/include/instructions/Registers.hpp @@ -0,0 +1,94 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +#ifndef RABBITIZER_REGISTER_HPP +#define RABBITIZER_REGISTER_HPP +#pragma once + + +namespace rabbitizer { + + namespace Registers { + #define RABBITIZER_DEF_REG(prefix, name, numeric) \ + prefix##_##name + + #define RABBITIZER_DEF_REG_NODOLLAR(prefix, name, numeric) \ + prefix##_##name + + namespace Cpu { + enum class GprO32 { + #include "instructions/registers/RabbitizerRegister_GprO32.inc" + }; + + enum class GprN32 { + #include "instructions/registers/RabbitizerRegister_GprN32.inc" + }; + + + enum class Cop0 { + #include "instructions/registers/RabbitizerRegister_Cop0.inc" + }; + + // Float registers + enum class Cop1O32 { + #include "instructions/registers/RabbitizerRegister_Cop1O32.inc" + }; + + enum class Cop1N32 { + #include "instructions/registers/RabbitizerRegister_Cop1N32.inc" + }; + + enum class Cop1N64 { + #include "instructions/registers/RabbitizerRegister_Cop1N64.inc" + }; + + enum class Cop1Control { + #include "instructions/registers/RabbitizerRegister_Cop1Control.inc" + }; + + enum class Cop2 { + #include "instructions/registers/RabbitizerRegister_Cop2.inc" + }; + }; + + + namespace Rsp { + enum class Gpr { + #include "instructions/registers/RabbitizerRegister_RspGpr.inc" + }; + + enum class Cop0 { + #include "instructions/registers/RabbitizerRegister_RspCop0.inc" + }; + + enum class Cop2 { + #include "instructions/registers/RabbitizerRegister_RspCop2.inc" + }; + + enum class Cop2Control { + #include "instructions/registers/RabbitizerRegister_RspCop2Control.inc" + }; + + enum class Vector { + #include "instructions/registers/RabbitizerRegister_RspVector.inc" + }; + }; + + + namespace R5900 { + enum class VF { + #include "instructions/registers/RabbitizerRegister_R5900VF.inc" + }; + + enum class VI { + #include "instructions/registers/RabbitizerRegister_R5900VI.inc" + }; + }; + + #undef RABBITIZER_DEF_REG + #undef RABBITIZER_DEF_REG_NODOLLAR + }; +}; + + +#endif diff --git a/tools/ido-static-recomp/tools/rabbitizer/cplusplus/include/rabbitizer.hpp b/tools/ido-static-recomp/tools/rabbitizer/cplusplus/include/rabbitizer.hpp new file mode 100644 index 00000000..332101e8 --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/cplusplus/include/rabbitizer.hpp @@ -0,0 +1,26 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +#ifndef RABBITIZER_HPP +#define RABBITIZER_HPP +#pragma once + + +#include "common/RabbitizerVersion.h" +#include "common/RabbitizerConfig.h" + +#include "instructions/OperandType.hpp" +#include "instructions/InstrId.hpp" +//#include "instructions/InstrSuffix.hpp" +//#include "instructions/InstrDescriptor.hpp" +#include "instructions/Registers.hpp" +#include "instructions/InstructionBase.hpp" +#include "instructions/InstructionCpu.hpp" +#include "instructions/InstructionRsp.hpp" +#include "instructions/InstructionR5900.hpp" + +#include "analysis/LoPairingInfo.hpp" +#include "analysis/RegistersTracker.hpp" + + +#endif diff --git a/tools/ido-static-recomp/tools/rabbitizer/cplusplus/src/analysis/LoPairingInfo.cpp b/tools/ido-static-recomp/tools/rabbitizer/cplusplus/src/analysis/LoPairingInfo.cpp new file mode 100644 index 00000000..d6fba253 --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/cplusplus/src/analysis/LoPairingInfo.cpp @@ -0,0 +1,34 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +#include "analysis/LoPairingInfo.hpp" + +using namespace rabbitizer; + +LoPairingInfo::LoPairingInfo() : pairingInfo{} { +} +LoPairingInfo::LoPairingInfo(const RabbitizerLoPairingInfo &newPairingInfo) : pairingInfo{ newPairingInfo } { +} + +RabbitizerLoPairingInfo *LoPairingInfo::getCPtr() { + return &this->pairingInfo; +} +const RabbitizerLoPairingInfo *LoPairingInfo::getCPtr() const { + return &this->pairingInfo; +} + +int LoPairingInfo::getInstrOffset() const { + return this->pairingInfo.instrOffset; +} +int64_t LoPairingInfo::getValue() const { + return this->pairingInfo.value; +} +bool LoPairingInfo::shouldProcess() const { + return this->pairingInfo.shouldProcess; +} +bool LoPairingInfo::isGpRel() const { + return this->pairingInfo.isGpRel; +} +bool LoPairingInfo::isGpGot() const { + return this->pairingInfo.isGpGot; +} diff --git a/tools/ido-static-recomp/tools/rabbitizer/cplusplus/src/analysis/RegistersTracker.cpp b/tools/ido-static-recomp/tools/rabbitizer/cplusplus/src/analysis/RegistersTracker.cpp new file mode 100644 index 00000000..5294d58f --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/cplusplus/src/analysis/RegistersTracker.cpp @@ -0,0 +1,64 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +#include "analysis/RegistersTracker.hpp" + +using namespace rabbitizer; + +RegistersTracker::RegistersTracker() { + RabbitizerRegistersTracker_init(&this->tracker, NULL); +} +RegistersTracker::RegistersTracker(const RegistersTracker &other) { + RabbitizerRegistersTracker_init(&this->tracker, &other.tracker); +} +RegistersTracker::~RegistersTracker() { + RabbitizerRegistersTracker_destroy(&this->tracker); +} + +RabbitizerRegistersTracker *RegistersTracker::getCPtr() { + return &this->tracker; +} +const RabbitizerRegistersTracker *RegistersTracker::getCPtr() const { + return &this->tracker; +} + +bool RegistersTracker::moveRegisters(const InstructionBase &instr) { + return RabbitizerRegistersTracker_moveRegisters(&this->tracker, instr.getCPtr()); +} +void RegistersTracker::overwriteRegisters(const InstructionBase &instr, int instrOffset) { + RabbitizerRegistersTracker_overwriteRegisters(&this->tracker, instr.getCPtr(), instrOffset); +} +void RegistersTracker::unsetRegistersAfterFuncCall(const InstructionBase &instr, const InstructionBase &prevInstr) { + RabbitizerRegistersTracker_unsetRegistersAfterFuncCall(&this->tracker, instr.getCPtr(), prevInstr.getCPtr()); +} +bool RegistersTracker::getAddressIfCanSetType(const InstructionBase &instr, int instrOffset, uint32_t *dstAddress) const { + return RabbitizerRegistersTracker_getAddressIfCanSetType(&this->tracker, instr.getCPtr(), instrOffset, dstAddress); +} +bool RegistersTracker::getJrInfo(const InstructionBase &instr, int *dstOffset, uint32_t *dstAddress) const { + return RabbitizerRegistersTracker_getJrInfo(&this->tracker, instr.getCPtr(), dstOffset, dstAddress); +} + +void RegistersTracker::processLui(const InstructionBase &instr, int instrOffset) { + RabbitizerRegistersTracker_processLui(&this->tracker, instr.getCPtr(), instrOffset, NULL); +} +void RegistersTracker::processLui(const InstructionBase &instr, int instrOffset, const InstructionBase &prevInstr) { + RabbitizerRegistersTracker_processLui(&this->tracker, instr.getCPtr(), instrOffset, prevInstr.getCPtr()); +} +void RegistersTracker::processGpLoad(const InstructionBase &instr, int instrOffset) { + RabbitizerRegistersTracker_processGpLoad(&this->tracker, instr.getCPtr(), instrOffset); +} +bool RegistersTracker::getLuiOffsetForConstant(const InstructionBase &instr, int *dstOffset) const { + return RabbitizerRegistersTracker_getLuiOffsetForConstant(&this->tracker, instr.getCPtr(), dstOffset); +} +void RegistersTracker::processConstant(const InstructionBase &instr, uint32_t value, int offset) { + RabbitizerRegistersTracker_processConstant(&this->tracker, instr.getCPtr(), value, offset); +} +LoPairingInfo RegistersTracker::preprocessLoAndGetInfo(const InstructionBase &instr, int instrOffset) { + return RabbitizerRegistersTracker_preprocessLoAndGetInfo(&this->tracker, instr.getCPtr(), instrOffset); +} +void RegistersTracker::processLo(const InstructionBase &instr, uint32_t value, int offset) { + RabbitizerRegistersTracker_processLo(&this->tracker, instr.getCPtr(), value, offset); +} +bool RegistersTracker::hasLoButNoHi(const InstructionBase &instr) const { + return RabbitizerRegistersTracker_hasLoButNoHi(&this->tracker, instr.getCPtr()); +} diff --git a/tools/ido-static-recomp/tools/rabbitizer/cplusplus/src/instructions/InstrId.cpp b/tools/ido-static-recomp/tools/rabbitizer/cplusplus/src/instructions/InstrId.cpp new file mode 100644 index 00000000..03e28d01 --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/cplusplus/src/instructions/InstrId.cpp @@ -0,0 +1,14 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +#include "instructions/InstrId.hpp" + +#include "instructions/RabbitizerInstrId.h" + +using namespace rabbitizer; + +std::string InstrId::getOpcodeName(InstrId::UniqueId uniqueId) { + RabbitizerInstrId id = static_cast(uniqueId); + + return std::string(RabbitizerInstrId_getOpcodeName(id)); +} diff --git a/tools/ido-static-recomp/tools/rabbitizer/cplusplus/src/instructions/InstructionBase.cpp b/tools/ido-static-recomp/tools/rabbitizer/cplusplus/src/instructions/InstructionBase.cpp new file mode 100644 index 00000000..4f5ad5be --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/cplusplus/src/instructions/InstructionBase.cpp @@ -0,0 +1,1036 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +#include "instructions/InstructionBase.hpp" + +#include + +#include "instructions/RabbitizerInstruction.h" +#include "instructions/RabbitizerInstructionR5900.h" + +using namespace rabbitizer; + +RabbitizerInstruction *InstructionBase::getCPtr() { + return &this->instr; +} +const RabbitizerInstruction *InstructionBase::getCPtr() const { + return &this->instr; +} + +/* getters */ + +uint8_t InstructionBase::Get_opcode() const { + return RAB_INSTR_GET_opcode(&this->instr); +} +uint8_t InstructionBase::Get_sa() const { +#ifdef RAB_SANITY_CHECKS + if (!hasOperandAlias(OperandType::cpu_sa)) { + // TODO: make a rabbitizer exception class + throw std::runtime_error("Instruction '" + getOpcodeName() + "' does not have 'sa' operand."); + } +#endif + + return RAB_INSTR_GET_sa(&this->instr); +} +uint8_t InstructionBase::Get_function() const { + /* + #ifdef RAB_SANITY_CHECKS + if (!hasOperandAlias(OperandType::cpu_function)) { + // TODO: make a rabbitizer exception class + throw std::runtime_error("Instruction '" + getOpcodeName() + "' does not have 'function' operand."); + } + #endif + */ + + return RAB_INSTR_GET_function(&this->instr); +} + +Registers::Cpu::GprO32 InstructionBase::GetO32_rs() const { +#ifdef RAB_SANITY_CHECKS + if (!hasOperandAlias(OperandType::cpu_rs)) { + // TODO: make a rabbitizer exception class + throw std::runtime_error("Instruction '" + getOpcodeName() + "' does not have 'rs' operand."); + } +#endif + + return static_cast(RAB_INSTR_GET_rs(&this->instr)); +} +Registers::Cpu::GprO32 InstructionBase::GetO32_rt() const { +#ifdef RAB_SANITY_CHECKS + if (!hasOperandAlias(OperandType::cpu_rt)) { + // TODO: make a rabbitizer exception class + throw std::runtime_error("Instruction '" + getOpcodeName() + "' does not have 'rt' operand."); + } +#endif + + return static_cast(RAB_INSTR_GET_rt(&this->instr)); +} +Registers::Cpu::GprO32 InstructionBase::GetO32_rd() const { +#ifdef RAB_SANITY_CHECKS + if (!hasOperandAlias(OperandType::cpu_rd)) { + // TODO: make a rabbitizer exception class + throw std::runtime_error("Instruction '" + getOpcodeName() + "' does not have 'rd' operand."); + } +#endif + + return static_cast(RAB_INSTR_GET_rd(&this->instr)); +} + +Registers::Cpu::GprN32 InstructionBase::GetN32_rs() const { +#ifdef RAB_SANITY_CHECKS + if (!hasOperandAlias(OperandType::cpu_rs)) { + // TODO: make a rabbitizer exception class + throw std::runtime_error("Instruction '" + getOpcodeName() + "' does not have 'rs' operand."); + } +#endif + + return static_cast(RAB_INSTR_GET_rs(&this->instr)); +} +Registers::Cpu::GprN32 InstructionBase::GetN32_rt() const { +#ifdef RAB_SANITY_CHECKS + if (!hasOperandAlias(OperandType::cpu_rt)) { + // TODO: make a rabbitizer exception class + throw std::runtime_error("Instruction '" + getOpcodeName() + "' does not have 'rt' operand."); + } +#endif + + return static_cast(RAB_INSTR_GET_rt(&this->instr)); +} +Registers::Cpu::GprN32 InstructionBase::GetN32_rd() const { +#ifdef RAB_SANITY_CHECKS + if (!hasOperandAlias(OperandType::cpu_rd)) { + // TODO: make a rabbitizer exception class + throw std::runtime_error("Instruction '" + getOpcodeName() + "' does not have 'rd' operand."); + } +#endif + + return static_cast(RAB_INSTR_GET_rd(&this->instr)); +} + +Registers::Cpu::Cop0 InstructionBase::Get_cop0d() const { +#ifdef RAB_SANITY_CHECKS + if (!hasOperandAlias(OperandType::cpu_cop0d)) { + // TODO: make a rabbitizer exception class + throw std::runtime_error("Instruction '" + getOpcodeName() + "' does not have 'cop0d' operand."); + } +#endif + + return static_cast(RAB_INSTR_GET_cop0d(&this->instr)); +} + +uint32_t InstructionBase::Get_instr_index() const { +#ifdef RAB_SANITY_CHECKS + if (!hasOperandAlias(OperandType::cpu_label)) { + // TODO: make a rabbitizer exception class + throw std::runtime_error("Instruction '" + getOpcodeName() + "' does not have 'label' operand."); + } +#endif + + return RAB_INSTR_GET_instr_index(&this->instr); +} +uint16_t InstructionBase::Get_immediate() const { +#ifdef RAB_SANITY_CHECKS + if (!hasOperandAlias(OperandType::cpu_immediate)) { + // TODO: make a rabbitizer exception class + throw std::runtime_error("Instruction '" + getOpcodeName() + "' does not have 'immediate' operand."); + } +#endif + + return RAB_INSTR_GET_immediate(&this->instr); +} + +Registers::Cpu::Cop1O32 InstructionBase::GetO32_fs() const { +#ifdef RAB_SANITY_CHECKS + if (!hasOperandAlias(OperandType::cpu_fs)) { + // TODO: make a rabbitizer exception class + throw std::runtime_error("Instruction '" + getOpcodeName() + "' does not have 'fs' operand."); + } +#endif + + return static_cast(RAB_INSTR_GET_fs(&this->instr)); +} +Registers::Cpu::Cop1O32 InstructionBase::GetO32_ft() const { +#ifdef RAB_SANITY_CHECKS + if (!hasOperandAlias(OperandType::cpu_ft)) { + // TODO: make a rabbitizer exception class + throw std::runtime_error("Instruction '" + getOpcodeName() + "' does not have 'ft' operand."); + } +#endif + + return static_cast(RAB_INSTR_GET_ft(&this->instr)); +} +Registers::Cpu::Cop1O32 InstructionBase::GetO32_fd() const { +#ifdef RAB_SANITY_CHECKS + if (!hasOperandAlias(OperandType::cpu_fd)) { + // TODO: make a rabbitizer exception class + throw std::runtime_error("Instruction '" + getOpcodeName() + "' does not have 'fd' operand."); + } +#endif + + return static_cast(RAB_INSTR_GET_fd(&this->instr)); +} + +Registers::Cpu::Cop1N32 InstructionBase::GetN32_fs() const { +#ifdef RAB_SANITY_CHECKS + if (!hasOperandAlias(OperandType::cpu_fs)) { + // TODO: make a rabbitizer exception class + throw std::runtime_error("Instruction '" + getOpcodeName() + "' does not have 'fs' operand."); + } +#endif + + return static_cast(RAB_INSTR_GET_fs(&this->instr)); +} +Registers::Cpu::Cop1N32 InstructionBase::GetN32_ft() const { +#ifdef RAB_SANITY_CHECKS + if (!hasOperandAlias(OperandType::cpu_ft)) { + // TODO: make a rabbitizer exception class + throw std::runtime_error("Instruction '" + getOpcodeName() + "' does not have 'ft' operand."); + } +#endif + + return static_cast(RAB_INSTR_GET_ft(&this->instr)); +} +Registers::Cpu::Cop1N32 InstructionBase::GetN32_fd() const { +#ifdef RAB_SANITY_CHECKS + if (!hasOperandAlias(OperandType::cpu_fd)) { + // TODO: make a rabbitizer exception class + throw std::runtime_error("Instruction '" + getOpcodeName() + "' does not have 'fd' operand."); + } +#endif + + return static_cast(RAB_INSTR_GET_fd(&this->instr)); +} + +Registers::Cpu::Cop1N64 InstructionBase::GetN64_fs() const { +#ifdef RAB_SANITY_CHECKS + if (!hasOperandAlias(OperandType::cpu_fs)) { + // TODO: make a rabbitizer exception class + throw std::runtime_error("Instruction '" + getOpcodeName() + "' does not have 'fs' operand."); + } +#endif + + return static_cast(RAB_INSTR_GET_fs(&this->instr)); +} +Registers::Cpu::Cop1N64 InstructionBase::GetN64_ft() const { +#ifdef RAB_SANITY_CHECKS + if (!hasOperandAlias(OperandType::cpu_ft)) { + // TODO: make a rabbitizer exception class + throw std::runtime_error("Instruction '" + getOpcodeName() + "' does not have 'ft' operand."); + } +#endif + + return static_cast(RAB_INSTR_GET_ft(&this->instr)); +} +Registers::Cpu::Cop1N64 InstructionBase::GetN64_fd() const { +#ifdef RAB_SANITY_CHECKS + if (!hasOperandAlias(OperandType::cpu_fd)) { + // TODO: make a rabbitizer exception class + throw std::runtime_error("Instruction '" + getOpcodeName() + "' does not have 'fd' operand."); + } +#endif + + return static_cast(RAB_INSTR_GET_fd(&this->instr)); +} + +Registers::Cpu::Cop1Control InstructionBase::Get_cop1cs() const { +#ifdef RAB_SANITY_CHECKS + if (!hasOperandAlias(OperandType::cpu_cop1cs)) { + // TODO: make a rabbitizer exception class + throw std::runtime_error("Instruction '" + getOpcodeName() + "' does not have 'cop1cs' operand."); + } +#endif + + return static_cast(RAB_INSTR_GET_cop1cs(&this->instr)); +} + +Registers::Cpu::Cop2 InstructionBase::Get_cop2t() const { +#ifdef RAB_SANITY_CHECKS + if (!hasOperandAlias(OperandType::cpu_cop2t)) { + // TODO: make a rabbitizer exception class + throw std::runtime_error("Instruction '" + getOpcodeName() + "' does not have 'cop2t' operand."); + } +#endif + + return static_cast(RAB_INSTR_GET_cop2t(&this->instr)); +} + +uint8_t InstructionBase::Get_op() const { +#ifdef RAB_SANITY_CHECKS + if (!hasOperandAlias(OperandType::cpu_op)) { + // TODO: make a rabbitizer exception class + throw std::runtime_error("Instruction '" + getOpcodeName() + "' does not have 'op' operand."); + } +#endif + + return RAB_INSTR_GET_op(&this->instr); +} + +uint32_t InstructionBase::Get_code() const { +#ifdef RAB_SANITY_CHECKS + if (!hasOperandAlias(OperandType::cpu_code)) { + // TODO: make a rabbitizer exception class + throw std::runtime_error("Instruction '" + getOpcodeName() + "' does not have 'code' operand."); + } +#endif + + return RAB_INSTR_GET_code(&this->instr); +} +uint32_t InstructionBase::Get_code_upper() const { +#if 0 +#ifdef RAB_SANITY_CHECKS + if (!hasOperandAlias(OperandType::cpu_code_upper)) { + // TODO: make a rabbitizer exception class + throw std::runtime_error("Instruction '" + getOpcodeName() + "' does not have 'code_upper' operand."); + } +#endif +#endif + + return RAB_INSTR_GET_code_upper(&this->instr); +} +uint32_t InstructionBase::Get_code_lower() const { +#ifdef RAB_SANITY_CHECKS + if (!hasOperandAlias(OperandType::cpu_code_lower)) { + // TODO: make a rabbitizer exception class + throw std::runtime_error("Instruction '" + getOpcodeName() + "' does not have 'code_lower' operand."); + } +#endif + + return RAB_INSTR_GET_code_lower(&this->instr); +} + +uint32_t InstructionBase::Get_copraw() const { +#ifdef RAB_SANITY_CHECKS + if (!hasOperandAlias(OperandType::cpu_copraw)) { + // TODO: make a rabbitizer exception class + throw std::runtime_error("Instruction '" + getOpcodeName() + "' does not have 'copraw' operand."); + } +#endif + + return RAB_INSTR_GET_copraw(&this->instr); +} + +uint8_t InstructionBase::Get_fmt() const { + return RAB_INSTR_GET_fmt(&this->instr); +} +uint8_t InstructionBase::Get_fc() const { + return RAB_INSTR_GET_fc(&this->instr); +} +uint8_t InstructionBase::Get_cond() const { + return RAB_INSTR_GET_cond(&this->instr); +} + +uint8_t InstructionBase::Get_tf() const { + return RAB_INSTR_GET_tf(&this->instr); +} +uint8_t InstructionBase::Get_nd() const { + return RAB_INSTR_GET_nd(&this->instr); +} +uint8_t InstructionBase::Get_bc_fmt() const { + return RAB_INSTR_GET_bc_fmt(&this->instr); +} + +uint8_t InstructionBase::Get_stype() const { + return RAB_INSTR_GET_stype(&this->instr); +} + +/* getters */ + +/* setters */ + +void InstructionBase::Set_opcode(uint8_t val) { + this->instr.word = RAB_INSTR_PACK_opcode(this->instr.word, val); +} +void InstructionBase::Set_sa(uint8_t val) { +#ifdef RAB_SANITY_CHECKS + if (!hasOperandAlias(OperandType::cpu_sa)) { + // TODO: make a rabbitizer exception class + throw std::runtime_error("Instruction '" + getOpcodeName() + "' does not have 'sa' operand."); + } +#endif + + this->instr.word = RAB_INSTR_PACK_sa(this->instr.word, val); +} +void InstructionBase::Set_function(uint8_t val) { + this->instr.word = RAB_INSTR_PACK_function(this->instr.word, val); +} + +void InstructionBase::Set_rs(Registers::Cpu::GprO32 val) { +#ifdef RAB_SANITY_CHECKS + if (!hasOperandAlias(OperandType::cpu_rs)) { + // TODO: make a rabbitizer exception class + throw std::runtime_error("Instruction '" + getOpcodeName() + "' does not have 'rs' operand."); + } +#endif + + this->instr.word = RAB_INSTR_PACK_rs(this->instr.word, static_cast(val)); +} +void InstructionBase::Set_rt(Registers::Cpu::GprO32 val) { +#ifdef RAB_SANITY_CHECKS + if (!hasOperandAlias(OperandType::cpu_rt)) { + // TODO: make a rabbitizer exception class + throw std::runtime_error("Instruction '" + getOpcodeName() + "' does not have 'rt' operand."); + } +#endif + + this->instr.word = RAB_INSTR_PACK_rt(this->instr.word, static_cast(val)); +} +void InstructionBase::Set_rd(Registers::Cpu::GprO32 val) { +#ifdef RAB_SANITY_CHECKS + if (!hasOperandAlias(OperandType::cpu_rd)) { + // TODO: make a rabbitizer exception class + throw std::runtime_error("Instruction '" + getOpcodeName() + "' does not have 'rd' operand."); + } +#endif + + this->instr.word = RAB_INSTR_PACK_rd(this->instr.word, static_cast(val)); +} + +void InstructionBase::Set_rs(Registers::Cpu::GprN32 val) { +#ifdef RAB_SANITY_CHECKS + if (!hasOperandAlias(OperandType::cpu_rs)) { + // TODO: make a rabbitizer exception class + throw std::runtime_error("Instruction '" + getOpcodeName() + "' does not have 'rs' operand."); + } +#endif + + this->instr.word = RAB_INSTR_PACK_rs(this->instr.word, static_cast(val)); +} +void InstructionBase::Set_rt(Registers::Cpu::GprN32 val) { +#ifdef RAB_SANITY_CHECKS + if (!hasOperandAlias(OperandType::cpu_rt)) { + // TODO: make a rabbitizer exception class + throw std::runtime_error("Instruction '" + getOpcodeName() + "' does not have 'rt' operand."); + } +#endif + + this->instr.word = RAB_INSTR_PACK_rt(this->instr.word, static_cast(val)); +} +void InstructionBase::Set_rd(Registers::Cpu::GprN32 val) { +#ifdef RAB_SANITY_CHECKS + if (!hasOperandAlias(OperandType::cpu_rd)) { + // TODO: make a rabbitizer exception class + throw std::runtime_error("Instruction '" + getOpcodeName() + "' does not have 'rd' operand."); + } +#endif + + this->instr.word = RAB_INSTR_PACK_rd(this->instr.word, static_cast(val)); +} + +void InstructionBase::Set_cop0d(Registers::Cpu::Cop0 val) { +#ifdef RAB_SANITY_CHECKS + if (!hasOperandAlias(OperandType::cpu_cop0d)) { + // TODO: make a rabbitizer exception class + throw std::runtime_error("Instruction '" + getOpcodeName() + "' does not have 'cop0d' operand."); + } +#endif + + this->instr.word = RAB_INSTR_PACK_cop0d(this->instr.word, static_cast(val)); +} + +void InstructionBase::Set_instr_index(uint32_t val) { +#ifdef RAB_SANITY_CHECKS + if (!hasOperandAlias(OperandType::cpu_label)) { + // TODO: make a rabbitizer exception class + throw std::runtime_error("Instruction '" + getOpcodeName() + "' does not have 'label' operand."); + } +#endif + + this->instr.word = RAB_INSTR_PACK_instr_index(this->instr.word, val); +} +void InstructionBase::Set_immediate(uint16_t val) { +#ifdef RAB_SANITY_CHECKS + if (!hasOperandAlias(OperandType::cpu_immediate)) { + // TODO: make a rabbitizer exception class + throw std::runtime_error("Instruction '" + getOpcodeName() + "' does not have 'immediate' operand."); + } +#endif + + this->instr.word = RAB_INSTR_PACK_immediate(this->instr.word, val); +} + +void InstructionBase::Set_fs(Registers::Cpu::Cop1O32 val) { +#ifdef RAB_SANITY_CHECKS + if (!hasOperandAlias(OperandType::cpu_fs)) { + // TODO: make a rabbitizer exception class + throw std::runtime_error("Instruction '" + getOpcodeName() + "' does not have 'fs' operand."); + } +#endif + + this->instr.word = RAB_INSTR_PACK_fs(this->instr.word, static_cast(val)); +} +void InstructionBase::Set_ft(Registers::Cpu::Cop1O32 val) { +#ifdef RAB_SANITY_CHECKS + if (!hasOperandAlias(OperandType::cpu_ft)) { + // TODO: make a rabbitizer exception class + throw std::runtime_error("Instruction '" + getOpcodeName() + "' does not have 'ft' operand."); + } +#endif + + this->instr.word = RAB_INSTR_PACK_ft(this->instr.word, static_cast(val)); +} +void InstructionBase::Set_fd(Registers::Cpu::Cop1O32 val) { +#ifdef RAB_SANITY_CHECKS + if (!hasOperandAlias(OperandType::cpu_fd)) { + // TODO: make a rabbitizer exception class + throw std::runtime_error("Instruction '" + getOpcodeName() + "' does not have 'fd' operand."); + } +#endif + + this->instr.word = RAB_INSTR_PACK_fd(this->instr.word, static_cast(val)); +} + +void InstructionBase::Set_fs(Registers::Cpu::Cop1N32 val) { +#ifdef RAB_SANITY_CHECKS + if (!hasOperandAlias(OperandType::cpu_fs)) { + // TODO: make a rabbitizer exception class + throw std::runtime_error("Instruction '" + getOpcodeName() + "' does not have 'fs' operand."); + } +#endif + + this->instr.word = RAB_INSTR_PACK_fs(this->instr.word, static_cast(val)); +} +void InstructionBase::Set_ft(Registers::Cpu::Cop1N32 val) { +#ifdef RAB_SANITY_CHECKS + if (!hasOperandAlias(OperandType::cpu_ft)) { + // TODO: make a rabbitizer exception class + throw std::runtime_error("Instruction '" + getOpcodeName() + "' does not have 'ft' operand."); + } +#endif + + this->instr.word = RAB_INSTR_PACK_ft(this->instr.word, static_cast(val)); +} +void InstructionBase::Set_fd(Registers::Cpu::Cop1N32 val) { +#ifdef RAB_SANITY_CHECKS + if (!hasOperandAlias(OperandType::cpu_fd)) { + // TODO: make a rabbitizer exception class + throw std::runtime_error("Instruction '" + getOpcodeName() + "' does not have 'fd' operand."); + } +#endif + + this->instr.word = RAB_INSTR_PACK_fd(this->instr.word, static_cast(val)); +} + +void InstructionBase::Set_fs(Registers::Cpu::Cop1N64 val) { +#ifdef RAB_SANITY_CHECKS + if (!hasOperandAlias(OperandType::cpu_fs)) { + // TODO: make a rabbitizer exception class + throw std::runtime_error("Instruction '" + getOpcodeName() + "' does not have 'fs' operand."); + } +#endif + + this->instr.word = RAB_INSTR_PACK_fs(this->instr.word, static_cast(val)); +} +void InstructionBase::Set_ft(Registers::Cpu::Cop1N64 val) { +#ifdef RAB_SANITY_CHECKS + if (!hasOperandAlias(OperandType::cpu_ft)) { + // TODO: make a rabbitizer exception class + throw std::runtime_error("Instruction '" + getOpcodeName() + "' does not have 'ft' operand."); + } +#endif + + this->instr.word = RAB_INSTR_PACK_ft(this->instr.word, static_cast(val)); +} +void InstructionBase::Set_fd(Registers::Cpu::Cop1N64 val) { +#ifdef RAB_SANITY_CHECKS + if (!hasOperandAlias(OperandType::cpu_fd)) { + // TODO: make a rabbitizer exception class + throw std::runtime_error("Instruction '" + getOpcodeName() + "' does not have 'fd' operand."); + } +#endif + + this->instr.word = RAB_INSTR_PACK_fd(this->instr.word, static_cast(val)); +} + +void InstructionBase::Set_cop1cs(Registers::Cpu::Cop1Control val) { +#ifdef RAB_SANITY_CHECKS + if (!hasOperandAlias(OperandType::cpu_cop1cs)) { + // TODO: make a rabbitizer exception class + throw std::runtime_error("Instruction '" + getOpcodeName() + "' does not have 'cop1cs' operand."); + } +#endif + + this->instr.word = RAB_INSTR_PACK_cop1cs(this->instr.word, static_cast(val)); +} + +void InstructionBase::Set_cop2t(Registers::Cpu::Cop2 val) { +#ifdef RAB_SANITY_CHECKS + if (!hasOperandAlias(OperandType::cpu_cop2t)) { + // TODO: make a rabbitizer exception class + throw std::runtime_error("Instruction '" + getOpcodeName() + "' does not have 'cop2t' operand."); + } +#endif + + this->instr.word = RAB_INSTR_PACK_cop2t(this->instr.word, static_cast(val)); +} + +void InstructionBase::Set_op(uint8_t val) { +#ifdef RAB_SANITY_CHECKS + if (!hasOperandAlias(OperandType::cpu_op)) { + // TODO: make a rabbitizer exception class + throw std::runtime_error("Instruction '" + getOpcodeName() + "' does not have 'op' operand."); + } +#endif + + this->instr.word = RAB_INSTR_PACK_op(this->instr.word, val); +} + +void InstructionBase::Set_code(uint32_t val) { +#ifdef RAB_SANITY_CHECKS + if (!hasOperandAlias(OperandType::cpu_code)) { + // TODO: make a rabbitizer exception class + throw std::runtime_error("Instruction '" + getOpcodeName() + "' does not have 'code' operand."); + } +#endif + + this->instr.word = RAB_INSTR_PACK_code(this->instr.word, val); +} + +void InstructionBase::Set_code_upper(uint32_t val) { +#if 0 +#ifdef RAB_SANITY_CHECKS + if (!hasOperandAlias(OperandType::cpu_code_upper)) { + // TODO: make a rabbitizer exception class + throw std::runtime_error("Instruction '" + getOpcodeName() + "' does not have 'code_upper' operand."); + } +#endif +#endif + + this->instr.word = RAB_INSTR_PACK_code_upper(this->instr.word, val); +} + +void InstructionBase::Set_code_lower(uint32_t val) { +#ifdef RAB_SANITY_CHECKS + if (!hasOperandAlias(OperandType::cpu_code_lower)) { + // TODO: make a rabbitizer exception class + throw std::runtime_error("Instruction '" + getOpcodeName() + "' does not have 'code_lower' operand."); + } +#endif + + this->instr.word = RAB_INSTR_PACK_code_lower(this->instr.word, val); +} + +void InstructionBase::Set_copraw(uint32_t val) { +#ifdef RAB_SANITY_CHECKS + if (!hasOperandAlias(OperandType::cpu_copraw)) { + // TODO: make a rabbitizer exception class + throw std::runtime_error("Instruction '" + getOpcodeName() + "' does not have 'copraw' operand."); + } +#endif + + this->instr.word = RAB_INSTR_PACK_copraw(this->instr.word, val); +} + +void InstructionBase::Set_fmt(uint8_t val) { + this->instr.word = RAB_INSTR_PACK_fmt(this->instr.word, val); +} +void InstructionBase::Set_fc(uint8_t val) { + this->instr.word = RAB_INSTR_PACK_fc(this->instr.word, val); +} +void InstructionBase::Set_cond(uint8_t val) { + this->instr.word = RAB_INSTR_PACK_cond(this->instr.word, val); +} + +void InstructionBase::Set_tf(uint8_t val) { + this->instr.word = RAB_INSTR_PACK_tf(this->instr.word, val); +} +void InstructionBase::Set_nd(uint8_t val) { + this->instr.word = RAB_INSTR_PACK_nd(this->instr.word, val); +} +void InstructionBase::Set_bc_fmt(uint8_t val) { + this->instr.word = RAB_INSTR_PACK_bc_fmt(this->instr.word, val); +} + +void InstructionBase::Set_stype(uint8_t val) { + this->instr.word = RAB_INSTR_PACK_stype(this->instr.word, val); +} + +/* setters */ + +/* more getters */ + +uint32_t InstructionBase::getRaw() const { + return RabbitizerInstruction_getRaw(&this->instr); +} + +InstrId::UniqueId InstructionBase::getUniqueId() const { + return static_cast(this->instr.uniqueId); +} +uint32_t InstructionBase::getVram() const { + return this->instr.vram; +} +bool InstructionBase::isInHandwrittenFunction() const { + return this->instr.inHandwrittenFunction; +} + +int32_t InstructionBase::getProcessedImmediate() const { +#ifdef RAB_SANITY_CHECKS + if (!hasOperandAlias(OperandType::cpu_immediate)) { + // TODO: make a rabbitizer exception class + throw std::runtime_error("Instruction '" + getOpcodeName() + "' does not have 'immediate' operand."); + } +#endif + + return RabbitizerInstruction_getProcessedImmediate(&this->instr); +} +uint32_t InstructionBase::getInstrIndexAsVram() const { +#ifdef RAB_SANITY_CHECKS + if (!hasOperandAlias(OperandType::cpu_label)) { + // TODO: make a rabbitizer exception class + throw std::runtime_error("Instruction '" + getOpcodeName() + "' does not have 'label' operand."); + } +#endif + + return RabbitizerInstruction_getInstrIndexAsVram(&this->instr); +} + +int32_t InstructionBase::getBranchOffset() const { +#ifdef RAB_SANITY_CHECKS + if (!hasOperandAlias(OperandType::cpu_branch_target_label)) { + // TODO: make a rabbitizer exception class + throw std::runtime_error("Instruction '" + getOpcodeName() + "' does not have 'branch_target_label' operand."); + } +#endif + + return RabbitizerInstruction_getBranchOffset(&this->instr); +} +int32_t InstructionBase::getGenericBranchOffset(uint32_t currentVram) const { +#ifdef RAB_SANITY_CHECKS + if (!hasOperandAlias(OperandType::cpu_branch_target_label) && !hasOperandAlias(OperandType::cpu_label)) { + // TODO: make a rabbitizer exception class + throw std::runtime_error("Instruction '" + getOpcodeName() + "' does not have either 'branch_target_label' or 'label' operands."); + } +#endif + + return RabbitizerInstruction_getGenericBranchOffset(&this->instr, currentVram); +} + +std::string InstructionBase::getOpcodeName() const { + return InstrId::getOpcodeName(getUniqueId()); +} + +/* more getters */ + +/* */ + +void InstructionBase::blankOut() { + RabbitizerInstruction_blankOut(&this->instr); +} + +/* Instruction examination */ + +bool InstructionBase::isImplemented() const { + return RabbitizerInstruction_isImplemented(&this->instr); +} +bool InstructionBase::isLikelyHandwritten() const { + return RabbitizerInstruction_isLikelyHandwritten(&this->instr); +} +bool InstructionBase::isNop() const { + return RabbitizerInstruction_isNop(&this->instr); +} +bool InstructionBase::isUnconditionalBranch() const { + return RabbitizerInstruction_isUnconditionalBranch(&this->instr); +} +bool InstructionBase::isJrRa() const { + return RabbitizerInstruction_isJrRa(&this->instr); +} +bool InstructionBase::isJrNotRa() const { + return RabbitizerInstruction_isJrNotRa(&this->instr); +} +bool InstructionBase::hasDelaySlot() const { + return RabbitizerInstruction_hasDelaySlot(&this->instr); +} + +std::string InstructionBase::mapInstrToType() const { + return std::string(RabbitizerInstruction_mapInstrToType(&this->instr)); +} + +bool InstructionBase::sameOpcode(const InstructionBase &other) const { + return RabbitizerInstruction_sameOpcode(&this->instr, &other.instr); +} +bool InstructionBase::sameOpcodeButDifferentArguments(const InstructionBase &other) const { + return RabbitizerInstruction_sameOpcodeButDifferentArguments(&this->instr, &other.instr); +} + +bool InstructionBase::hasOperand(OperandType operand) const { + return RabbitizerInstruction_hasOperand(&this->instr, static_cast(operand)); +} +bool InstructionBase::hasOperandAlias(OperandType operand) const { + return RabbitizerInstruction_hasOperandAlias(&this->instr, static_cast(operand)); +} + +uint32_t InstructionBase::getValidBits() const { + return RabbitizerInstruction_getValidBits(&this->instr); +} +bool InstructionBase::isValid() const { + return RabbitizerInstruction_isValid(&this->instr); +} + +/* Instruction examination */ + +/* Instruction descriptor */ + +bool InstructionBase::isUnknownType() const { + return RabbitizerInstrDescriptor_isUnknownType(this->instr.descriptor); +} +bool InstructionBase::isJType() const { + return RabbitizerInstrDescriptor_isJType(this->instr.descriptor); +} +bool InstructionBase::isIType() const { + return RabbitizerInstrDescriptor_isIType(this->instr.descriptor); +} +bool InstructionBase::isRType() const { + return RabbitizerInstrDescriptor_isRType(this->instr.descriptor); +} +bool InstructionBase::isRegimmType() const { + return RabbitizerInstrDescriptor_isRegimmType(this->instr.descriptor); +} + +// TODO +// RabbitizerInstrSuffix instrSuffix() const; + +bool InstructionBase::isBranch() const { + return RabbitizerInstrDescriptor_isBranch(this->instr.descriptor); +} +bool InstructionBase::isBranchLikely() const { + return RabbitizerInstrDescriptor_isBranchLikely(this->instr.descriptor); +} +bool InstructionBase::isJump() const { + return RabbitizerInstrDescriptor_isJump(this->instr.descriptor); +} +bool InstructionBase::isTrap() const { + return RabbitizerInstrDescriptor_isTrap(this->instr.descriptor); +} + +bool InstructionBase::isFloat() const { + return RabbitizerInstrDescriptor_isFloat(this->instr.descriptor); +} +bool InstructionBase::isDouble() const { + return RabbitizerInstrDescriptor_isDouble(this->instr.descriptor); +} + +bool InstructionBase::isUnsigned() const { + return RabbitizerInstrDescriptor_isUnsigned(this->instr.descriptor); +} + +bool InstructionBase::modifiesRt() const { + return RabbitizerInstrDescriptor_modifiesRt(this->instr.descriptor); +} +bool InstructionBase::modifiesRd() const { + return RabbitizerInstrDescriptor_modifiesRd(this->instr.descriptor); +} + +bool InstructionBase::notEmitedByCompilers() const { + return RabbitizerInstrDescriptor_notEmitedByCompilers(this->instr.descriptor); +} + +bool InstructionBase::canBeHi() const { + return RabbitizerInstrDescriptor_canBeHi(this->instr.descriptor); +} +bool InstructionBase::canBeLo() const { + return RabbitizerInstrDescriptor_canBeLo(this->instr.descriptor); +} +bool InstructionBase::doesLink() const { + return RabbitizerInstrDescriptor_doesLink(this->instr.descriptor); +} +bool InstructionBase::doesDereference() const { + return RabbitizerInstrDescriptor_doesDereference(this->instr.descriptor); +} +bool InstructionBase::doesLoad() const { + return RabbitizerInstrDescriptor_doesLoad(this->instr.descriptor); +} +bool InstructionBase::doesStore() const { + return RabbitizerInstrDescriptor_doesStore(this->instr.descriptor); +} +bool InstructionBase::maybeIsMove() const { + return RabbitizerInstrDescriptor_maybeIsMove(this->instr.descriptor); +} + +bool InstructionBase::isPseudo() const { + return RabbitizerInstrDescriptor_isPseudo(this->instr.descriptor); +} + +/* Instruction descriptor */ + +/* Disassembly */ + +bool InstructionBase::mustDisasmAsData() const { + return RabbitizerInstruction_mustDisasmAsData(&this->instr); +} + +std::string InstructionBase::disassembleOperands() const { + const char *immOverridePtr = NULL; + size_t immOverrideLength = 0; + size_t bufferSize; + size_t disassmbledSize; + char *buffer; + + bufferSize = RabbitizerInstruction_getSizeForBufferOperandsDisasm(&instr, immOverrideLength); + + buffer = (char *)malloc(bufferSize + 1); + if (buffer == NULL) { + throw std::runtime_error("buffer == NULL"); + } + + disassmbledSize = RabbitizerInstruction_disassembleOperands(&instr, buffer, immOverridePtr, immOverrideLength); + + std::string output(buffer); + free(buffer); + + if (disassmbledSize > bufferSize) { + throw std::runtime_error("disassmbledSize > bufferSize"); + } + + return output; +} +std::string InstructionBase::disassembleOperands(std::string_view immOverride) const { + const char *immOverridePtr = immOverride.data(); + size_t immOverrideLength = immOverride.size(); + size_t bufferSize; + size_t disassmbledSize; + char *buffer; + + bufferSize = RabbitizerInstruction_getSizeForBufferOperandsDisasm(&instr, immOverrideLength); + + buffer = (char *)malloc(bufferSize + 1); + if (buffer == NULL) { + throw std::runtime_error("buffer == NULL"); + } + + disassmbledSize = RabbitizerInstruction_disassembleOperands(&instr, buffer, immOverridePtr, immOverrideLength); + + std::string output(buffer); + free(buffer); + + if (disassmbledSize > bufferSize) { + throw std::runtime_error("disassmbledSize > bufferSize"); + } + + return output; +} + +std::string InstructionBase::disassembleInstruction(int extraLJust) const { + const char *immOverridePtr = NULL; + size_t immOverrideLength = 0; + size_t bufferSize; + size_t disassmbledSize; + char *buffer; + + bufferSize = RabbitizerInstruction_getSizeForBufferInstrDisasm(&instr, immOverrideLength, extraLJust); + + buffer = (char *)malloc(bufferSize + 1); + if (buffer == NULL) { + throw std::runtime_error("buffer == NULL"); + } + + disassmbledSize = RabbitizerInstruction_disassembleInstruction(&instr, buffer, immOverridePtr, immOverrideLength, extraLJust); + + std::string output(buffer); + free(buffer); + + if (disassmbledSize > bufferSize) { + throw std::runtime_error("disassmbledSize > bufferSize"); + } + + return output; +} +std::string InstructionBase::disassembleInstruction(int extraLJust, std::string_view immOverride) const { + const char *immOverridePtr = immOverride.data(); + size_t immOverrideLength = immOverride.size(); + size_t bufferSize; + size_t disassmbledSize; + char *buffer; + + bufferSize = RabbitizerInstruction_getSizeForBufferInstrDisasm(&instr, immOverrideLength, extraLJust); + + buffer = (char *)malloc(bufferSize + 1); + if (buffer == NULL) { + throw std::runtime_error("buffer == NULL"); + } + + disassmbledSize = RabbitizerInstruction_disassembleInstruction(&instr, buffer, immOverridePtr, immOverrideLength, extraLJust); + + std::string output(buffer); + free(buffer); + + if (disassmbledSize > bufferSize) { + throw std::runtime_error("disassmbledSize > bufferSize"); + } + + return output; +} + +std::string InstructionBase::disassembleAsData(int extraLJust) const { + size_t bufferSize; + size_t disassmbledSize; + char *buffer; + + bufferSize = RabbitizerInstruction_getSizeForBufferDataDisasm(&instr, extraLJust); + + buffer = (char *)malloc(bufferSize + 1); + if (buffer == NULL) { + throw std::runtime_error("buffer == NULL"); + } + + disassmbledSize = RabbitizerInstruction_disassembleAsData(&instr, buffer, extraLJust); + + std::string output(buffer); + free(buffer); + + if (disassmbledSize > bufferSize) { + throw std::runtime_error("disassmbledSize > bufferSize"); + } + + return output; +} + +std::string InstructionBase::disassemble(int extraLJust) const { + const char *immOverridePtr = NULL; + size_t immOverrideLength = 0; + size_t bufferSize; + size_t disassmbledSize; + char *buffer; + + bufferSize = RabbitizerInstruction_getSizeForBuffer(&instr, immOverrideLength, extraLJust); + + buffer = (char *)malloc(bufferSize + 1); + if (buffer == NULL) { + throw std::runtime_error("buffer == NULL"); + } + + disassmbledSize = RabbitizerInstruction_disassemble(&instr, buffer, immOverridePtr, immOverrideLength, extraLJust); + + std::string output(buffer); + free(buffer); + + if (disassmbledSize > bufferSize) { + throw std::runtime_error("disassmbledSize > bufferSize"); + } + + return output; +} + +std::string InstructionBase::disassemble(int extraLJust, std::string_view immOverride) const { + const char *immOverridePtr = immOverride.data(); + size_t immOverrideLength = immOverride.size(); + size_t bufferSize; + size_t disassmbledSize; + char *buffer; + + bufferSize = RabbitizerInstruction_getSizeForBuffer(&instr, immOverrideLength, extraLJust); + + buffer = (char *)malloc(bufferSize + 1); + if (buffer == NULL) { + throw std::runtime_error("buffer == NULL"); + } + + disassmbledSize = RabbitizerInstruction_disassemble(&instr, buffer, immOverridePtr, immOverrideLength, extraLJust); + + std::string output(buffer); + free(buffer); + + if (disassmbledSize > bufferSize) { + throw std::runtime_error("disassmbledSize > bufferSize"); + } + + return output; +} diff --git a/tools/ido-static-recomp/tools/rabbitizer/cplusplus/src/instructions/InstructionCpu.cpp b/tools/ido-static-recomp/tools/rabbitizer/cplusplus/src/instructions/InstructionCpu.cpp new file mode 100644 index 00000000..9488b9a3 --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/cplusplus/src/instructions/InstructionCpu.cpp @@ -0,0 +1,15 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +#include "instructions/InstructionCpu.hpp" + +using namespace rabbitizer; + +InstructionCpu::InstructionCpu(uint32_t word, uint32_t vram) : InstructionBase() { + RabbitizerInstruction_init(&this->instr, word, vram); + RabbitizerInstruction_processUniqueId(&this->instr); +} + +InstructionCpu::~InstructionCpu() { + RabbitizerInstruction_destroy(&this->instr); +} diff --git a/tools/ido-static-recomp/tools/rabbitizer/cplusplus/src/instructions/InstructionR5900.cpp b/tools/ido-static-recomp/tools/rabbitizer/cplusplus/src/instructions/InstructionR5900.cpp new file mode 100644 index 00000000..0fe00630 --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/cplusplus/src/instructions/InstructionR5900.cpp @@ -0,0 +1,118 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +#include "instructions/InstructionR5900.hpp" + +#include + +#include "instructions/RabbitizerInstructionR5900.h" + +using namespace rabbitizer; + +InstructionR5900::InstructionR5900(uint32_t word, uint32_t vram) : InstructionBase() { + RabbitizerInstructionR5900_init(&this->instr, word, vram); + RabbitizerInstructionR5900_processUniqueId(&this->instr); +} + +InstructionR5900::~InstructionR5900() { + RabbitizerInstructionR5900_destroy(&this->instr); +} + +Registers::R5900::VF InstructionR5900::GetR5900_vfs() const { +#ifdef RAB_SANITY_CHECKS + if (!hasOperandAlias(OperandType::rsp_rs)) { + // TODO: make a rabbitizer exception class + throw std::runtime_error("Instruction '" + getOpcodeName() + "' does not have 'vfs' operand."); + } +#endif + + return static_cast(RAB_INSTR_R5900_GET_vfs(&this->instr)); +} + +Registers::R5900::VF InstructionR5900::GetR5900_vft() const { +#ifdef RAB_SANITY_CHECKS + if (!hasOperandAlias(OperandType::rsp_rt)) { + // TODO: make a rabbitizer exception class + throw std::runtime_error("Instruction '" + getOpcodeName() + "' does not have 'vft' operand."); + } +#endif + + return static_cast(RAB_INSTR_R5900_GET_vft(&this->instr)); +} + +Registers::R5900::VF InstructionR5900::GetR5900_vfd() const { +#ifdef RAB_SANITY_CHECKS + if (!hasOperandAlias(OperandType::rsp_rd)) { + // TODO: make a rabbitizer exception class + throw std::runtime_error("Instruction '" + getOpcodeName() + "' does not have 'vfd' operand."); + } +#endif + + return static_cast(RAB_INSTR_R5900_GET_vfd(&this->instr)); +} + +Registers::R5900::VI InstructionR5900::GetR5900_vis() const { +#ifdef RAB_SANITY_CHECKS + if (!hasOperandAlias(OperandType::rsp_rs)) { + // TODO: make a rabbitizer exception class + throw std::runtime_error("Instruction '" + getOpcodeName() + "' does not have 'vis' operand."); + } +#endif + + return static_cast(RAB_INSTR_R5900_GET_vis(&this->instr)); +} + +Registers::R5900::VI InstructionR5900::GetR5900_vit() const { +#ifdef RAB_SANITY_CHECKS + if (!hasOperandAlias(OperandType::rsp_rt)) { + // TODO: make a rabbitizer exception class + throw std::runtime_error("Instruction '" + getOpcodeName() + "' does not have 'vit' operand."); + } +#endif + + return static_cast(RAB_INSTR_R5900_GET_vit(&this->instr)); +} + +Registers::R5900::VI InstructionR5900::GetR5900_vid() const { +#ifdef RAB_SANITY_CHECKS + if (!hasOperandAlias(OperandType::rsp_rd)) { + // TODO: make a rabbitizer exception class + throw std::runtime_error("Instruction '" + getOpcodeName() + "' does not have 'vid' operand."); + } +#endif + + return static_cast(RAB_INSTR_R5900_GET_vid(&this->instr)); +} + +uint8_t InstructionR5900::GetR5900_mmi_function() const { + return RAB_INSTR_R5900_GET_mmi_function(&this->instr); +} +uint8_t InstructionR5900::GetR5900_fhi_flo() const { + return RAB_INSTR_R5900_GET_fhi_flo(&this->instr); +} + +uint8_t InstructionR5900::GetR5900_xyzw_x() const { + return RAB_INSTR_R5900_GET_xyzw_x(&this->instr); +} +uint8_t InstructionR5900::GetR5900_xyzw_y() const { + return RAB_INSTR_R5900_GET_xyzw_y(&this->instr); +} +uint8_t InstructionR5900::GetR5900_xyzw_z() const { + return RAB_INSTR_R5900_GET_xyzw_z(&this->instr); +} +uint8_t InstructionR5900::GetR5900_xyzw_w() const { + return RAB_INSTR_R5900_GET_xyzw_w(&this->instr); +} +uint8_t InstructionR5900::GetR5900_n() const { + return RAB_INSTR_R5900_GET_n(&this->instr); +} +uint8_t InstructionR5900::GetR5900_l() const { + return RAB_INSTR_R5900_GET_l(&this->instr); +} +uint8_t InstructionR5900::GetR5900_m() const { + return RAB_INSTR_R5900_GET_m(&this->instr); +} + +uint8_t InstructionR5900::GetR5900_imm5() const { + return RAB_INSTR_R5900_GET_imm5(&this->instr); +} diff --git a/tools/ido-static-recomp/tools/rabbitizer/cplusplus/src/instructions/InstructionRsp.cpp b/tools/ido-static-recomp/tools/rabbitizer/cplusplus/src/instructions/InstructionRsp.cpp new file mode 100644 index 00000000..891a0351 --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/cplusplus/src/instructions/InstructionRsp.cpp @@ -0,0 +1,128 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +#include "instructions/InstructionRsp.hpp" + +#include + +#include "instructions/RabbitizerInstructionRsp.h" + +using namespace rabbitizer; + +InstructionRsp::InstructionRsp(uint32_t word, uint32_t vram) : InstructionBase() { + RabbitizerInstructionRsp_init(&this->instr, word, vram); + RabbitizerInstructionRsp_processUniqueId(&this->instr); +} + +InstructionRsp::~InstructionRsp() { + RabbitizerInstructionRsp_destroy(&this->instr); +} + +Registers::Rsp::Gpr InstructionRsp::GetRsp_rs() const { +#ifdef RAB_SANITY_CHECKS + if (!hasOperandAlias(OperandType::rsp_rs)) { + // TODO: make a rabbitizer exception class + throw std::runtime_error("Instruction '" + getOpcodeName() + "' does not have 'rs' operand."); + } +#endif + + return static_cast(RAB_INSTR_GET_rs(&this->instr)); +} +Registers::Rsp::Gpr InstructionRsp::GetRsp_rt() const { +#ifdef RAB_SANITY_CHECKS + if (!hasOperandAlias(OperandType::rsp_rt)) { + // TODO: make a rabbitizer exception class + throw std::runtime_error("Instruction '" + getOpcodeName() + "' does not have 'rt' operand."); + } +#endif + + return static_cast(RAB_INSTR_GET_rt(&this->instr)); +} +Registers::Rsp::Gpr InstructionRsp::GetRsp_rd() const { +#ifdef RAB_SANITY_CHECKS + if (!hasOperandAlias(OperandType::rsp_rd)) { + // TODO: make a rabbitizer exception class + throw std::runtime_error("Instruction '" + getOpcodeName() + "' does not have 'rd' operand."); + } +#endif + + return static_cast(RAB_INSTR_GET_rd(&this->instr)); +} + +Registers::Rsp::Cop0 InstructionRsp::GetRsp_cop0d() const { +#ifdef RAB_SANITY_CHECKS + if (!hasOperandAlias(OperandType::rsp_cop0d)) { + // TODO: make a rabbitizer exception class + throw std::runtime_error("Instruction '" + getOpcodeName() + "' does not have 'cop0d' operand."); + } +#endif + + return static_cast(RAB_INSTR_GET_cop0d(&this->instr)); +} + +Registers::Rsp::Cop2 InstructionRsp::GetRsp_cop2t() const { +#ifdef RAB_SANITY_CHECKS + if (!hasOperandAlias(OperandType::rsp_cop2t)) { + // TODO: make a rabbitizer exception class + throw std::runtime_error("Instruction '" + getOpcodeName() + "' does not have 'cop2t' operand."); + } +#endif + + return static_cast(RAB_INSTR_RSP_GET_cop2t(&this->instr)); +} + +Registers::Rsp::Cop2Control InstructionRsp::GetRsp_cop2cd() const { +#ifdef RAB_SANITY_CHECKS + if (!hasOperandAlias(OperandType::rsp_cop2t)) { + // TODO: make a rabbitizer exception class + throw std::runtime_error("Instruction '" + getOpcodeName() + "' does not have 'cop2cd' operand."); + } +#endif + + return static_cast(RAB_INSTR_RSP_GET_cop2cd(&this->instr)); +} + +Registers::Rsp::Vector InstructionRsp::GetRsp_vs() const { +#ifdef RAB_SANITY_CHECKS + if (!hasOperandAlias(OperandType::rsp_vs)) { + // TODO: make a rabbitizer exception class + throw std::runtime_error("Instruction '" + getOpcodeName() + "' does not have 'vs' operand."); + } +#endif + + return static_cast(RAB_INSTR_RSP_GET_vs(&this->instr)); +} +Registers::Rsp::Vector InstructionRsp::GetRsp_vt() const { +#ifdef RAB_SANITY_CHECKS + if (!hasOperandAlias(OperandType::rsp_vt)) { + // TODO: make a rabbitizer exception class + throw std::runtime_error("Instruction '" + getOpcodeName() + "' does not have 'vt' operand."); + } +#endif + + return static_cast(RAB_INSTR_RSP_GET_vt(&this->instr)); +} +Registers::Rsp::Vector InstructionRsp::GetRsp_vd() const { +#ifdef RAB_SANITY_CHECKS + if (!hasOperandAlias(OperandType::rsp_vd)) { + // TODO: make a rabbitizer exception class + throw std::runtime_error("Instruction '" + getOpcodeName() + "' does not have 'vd' operand."); + } +#endif + + return static_cast(RAB_INSTR_RSP_GET_vd(&this->instr)); +} + +uint8_t InstructionRsp::GetRsp_elementhigh() const { + return RAB_INSTR_RSP_GET_elementhigh(&this->instr); +} +uint8_t InstructionRsp::GetRsp_elementlow() const { + return RAB_INSTR_RSP_GET_elementlow(&this->instr); +} + +uint8_t InstructionRsp::GetRsp_index() const { + return RAB_INSTR_RSP_GET_index(&this->instr); +} +uint8_t InstructionRsp::GetRsp_de() const { + return RAB_INSTR_RSP_GET_de(&this->instr); +} diff --git a/tools/ido-static-recomp/tools/rabbitizer/include/analysis/RabbitizerLoPairingInfo.h b/tools/ido-static-recomp/tools/rabbitizer/include/analysis/RabbitizerLoPairingInfo.h new file mode 100644 index 00000000..b6a70ed2 --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/include/analysis/RabbitizerLoPairingInfo.h @@ -0,0 +1,34 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +#ifndef RABBITIZER_LO_PAIRING_INFO_H +#define RABBITIZER_LO_PAIRING_INFO_H +#pragma once + +#include + +#include "common/Utils.h" + +#ifdef __cplusplus +extern "C" { +#endif + + +typedef struct RabbitizerLoPairingInfo { + int instrOffset; + int64_t value; // could be either an unsigned 32 bits number or a signed one, so use 64 bits to ensure it fits + bool shouldProcess; + bool isGpRel; + bool isGpGot; +} RabbitizerLoPairingInfo; + + +NON_NULL(1) +void RabbitizerLoPairingInfo_Init(RabbitizerLoPairingInfo *self); + + +#ifdef __cplusplus +} +#endif + +#endif diff --git a/tools/ido-static-recomp/tools/rabbitizer/include/analysis/RabbitizerRegistersTracker.h b/tools/ido-static-recomp/tools/rabbitizer/include/analysis/RabbitizerRegistersTracker.h new file mode 100644 index 00000000..36ccbd56 --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/include/analysis/RabbitizerRegistersTracker.h @@ -0,0 +1,65 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +#ifndef RABBITIZER_REGISTERS_TRACKER_H +#define RABBITIZER_REGISTERS_TRACKER_H +#pragma once + +#include "common/Utils.h" +#include "RabbitizerTrackedRegisterState.h" +#include "RabbitizerLoPairingInfo.h" +#include "instructions/RabbitizerInstruction.h" + +#ifdef __cplusplus +extern "C" { +#endif + +#define RAB_REGISTERS_COUNT 32 + + +typedef struct RabbitizerRegistersTracker { + RabbitizerTrackedRegisterState registers[RAB_REGISTERS_COUNT]; +} RabbitizerRegistersTracker; + +// TODO: Change functions which use parameters as a way to return values into actual structs returned by the functions + +NON_NULL(1) +void RabbitizerRegistersTracker_init(RabbitizerRegistersTracker *self, const RabbitizerRegistersTracker *other); +NON_NULL(1) +void RabbitizerRegistersTracker_destroy(RabbitizerRegistersTracker *self); + +NON_NULL(1, 2) +bool RabbitizerRegistersTracker_moveRegisters(RabbitizerRegistersTracker *self, const RabbitizerInstruction *instr); +NON_NULL(1, 2) +void RabbitizerRegistersTracker_overwriteRegisters(RabbitizerRegistersTracker *self, const RabbitizerInstruction *instr, int instrOffset); +NON_NULL(1, 2, 3) +void RabbitizerRegistersTracker_unsetRegistersAfterFuncCall(RabbitizerRegistersTracker *self, const RabbitizerInstruction *instr, const RabbitizerInstruction *prevInstr); +NON_NULL(1, 2, 4) +bool RabbitizerRegistersTracker_getAddressIfCanSetType(const RabbitizerRegistersTracker *self, const RabbitizerInstruction *instr, int instrOffset, uint32_t *dstAddress); +NON_NULL(1, 2, 3, 4) +bool RabbitizerRegistersTracker_getJrInfo(const RabbitizerRegistersTracker *self, const RabbitizerInstruction *instr, int *dstOffset, uint32_t *dstAddress); + +// prevInstr can be NULL +NON_NULL(1, 2) +void RabbitizerRegistersTracker_processLui(RabbitizerRegistersTracker *self, const RabbitizerInstruction *instr, int instrOffset, const RabbitizerInstruction *prevInstr); +NON_NULL(1, 2) +void RabbitizerRegistersTracker_processGpLoad(RabbitizerRegistersTracker *self, const RabbitizerInstruction *instr, int instrOffset); +NON_NULL(1, 2, 3) +bool RabbitizerRegistersTracker_getLuiOffsetForConstant(const RabbitizerRegistersTracker *self, const RabbitizerInstruction *instr, int *dstOffset); +NON_NULL(1, 2) +void RabbitizerRegistersTracker_processConstant(RabbitizerRegistersTracker *self, const RabbitizerInstruction *instr, uint32_t value, int offset); +NON_NULL(1, 2, 4, 5) // deprecated +bool RabbitizerRegistersTracker_getLuiOffsetForLo(RabbitizerRegistersTracker *self, const RabbitizerInstruction *instr, int instrOffset, int *dstOffset, bool *dstIsGp); +NODISCARD NON_NULL(1, 2) +RabbitizerLoPairingInfo RabbitizerRegistersTracker_preprocessLoAndGetInfo(RabbitizerRegistersTracker *self, const RabbitizerInstruction *instr, int instrOffset); +NON_NULL(1, 2) +void RabbitizerRegistersTracker_processLo(RabbitizerRegistersTracker *self, const RabbitizerInstruction *instr, uint32_t value, int offset); +NON_NULL(1, 2) +bool RabbitizerRegistersTracker_hasLoButNoHi(const RabbitizerRegistersTracker *self, const RabbitizerInstruction *instr); + + +#ifdef __cplusplus +} +#endif + +#endif diff --git a/tools/ido-static-recomp/tools/rabbitizer/include/analysis/RabbitizerTrackedRegisterState.h b/tools/ido-static-recomp/tools/rabbitizer/include/analysis/RabbitizerTrackedRegisterState.h new file mode 100644 index 00000000..daf4b2da --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/include/analysis/RabbitizerTrackedRegisterState.h @@ -0,0 +1,80 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +#ifndef RABBITIZER_TRACKED_REGISTER_STATE_H +#define RABBITIZER_TRACKED_REGISTER_STATE_H +#pragma once + +#include +#include +#include + +#include "common/Utils.h" + +#ifdef __cplusplus +extern "C" { +#endif + + +typedef struct RabbitizerTrackedRegisterState { + int registerNum; + + bool hasLuiValue; + int luiOffset; // The offset of last lui which set a value to this register + bool luiSetOnBranchLikely; + + bool hasGpGot; + int gpGotOffset; + + bool hasLoValue; + int loOffset; + bool dereferenced; + int dereferenceOffset; + + uint32_t value; +} RabbitizerTrackedRegisterState; + + +NON_NULL(1) +void RabbitizerTrackedRegisterState_init(RabbitizerTrackedRegisterState *self, int registerNum); +NON_NULL(1) +void RabbitizerTrackedRegisterState_destroy(RabbitizerTrackedRegisterState *self); + +NON_NULL(1) +void RabbitizerTrackedRegisterState_clear(RabbitizerTrackedRegisterState *self); +NON_NULL(1) +void RabbitizerTrackedRegisterState_clearHi(RabbitizerTrackedRegisterState *self); +NON_NULL(1) +void RabbitizerTrackedRegisterState_clearGp(RabbitizerTrackedRegisterState *self); +NON_NULL(1) +void RabbitizerTrackedRegisterState_clearLo(RabbitizerTrackedRegisterState *self); + +NON_NULL(1, 2) +void RabbitizerTrackedRegisterState_copyState(RabbitizerTrackedRegisterState *self, const RabbitizerTrackedRegisterState *other); + +NON_NULL(1) +void RabbitizerTrackedRegisterState_setHi(RabbitizerTrackedRegisterState *self, uint32_t value, int offset); +NON_NULL(1) +void RabbitizerTrackedRegisterState_setGpLoad(RabbitizerTrackedRegisterState *self, uint32_t value, int offset); +NON_NULL(1) +void RabbitizerTrackedRegisterState_setLo(RabbitizerTrackedRegisterState *self, uint32_t value, int offset); + +NON_NULL(1) +void RabbitizerTrackedRegisterState_deref(RabbitizerTrackedRegisterState *self, int offset); +NON_NULL(1, 2) +void RabbitizerTrackedRegisterState_dereferenceState(RabbitizerTrackedRegisterState *self, const RabbitizerTrackedRegisterState *other, int offset); + +NODISCARD NON_NULL(1) PURE +bool RabbitizerTrackedRegisterState_hasAnyValue(const RabbitizerTrackedRegisterState *self); +NODISCARD NON_NULL(1) PURE +bool RabbitizerTrackedRegisterState_wasSetInCurrentOffset(const RabbitizerTrackedRegisterState *self, int offset); + +NON_NULL(1) +void RabbitizerTrackedRegisterState_fprint(const RabbitizerTrackedRegisterState *self, FILE* outFile); + + +#ifdef __cplusplus +} +#endif + +#endif diff --git a/tools/ido-static-recomp/tools/rabbitizer/include/common/Abi.inc b/tools/ido-static-recomp/tools/rabbitizer/include/common/Abi.inc new file mode 100644 index 00000000..fa01d92f --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/include/common/Abi.inc @@ -0,0 +1,7 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +RABBITIZER_DEF_ABI(NUMERIC), +RABBITIZER_DEF_ABI(O32), +RABBITIZER_DEF_ABI(N32), +RABBITIZER_DEF_ABI(N64), diff --git a/tools/ido-static-recomp/tools/rabbitizer/include/common/RabbitizerConfig.h b/tools/ido-static-recomp/tools/rabbitizer/include/common/RabbitizerConfig.h new file mode 100644 index 00000000..8b9def78 --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/include/common/RabbitizerConfig.h @@ -0,0 +1,83 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +#ifndef RABBITIZER_CONFIG_H +#define RABBITIZER_CONFIG_H + +#include + +#ifdef __cplusplus +extern "C" { +#endif + + +#define RABBITIZER_DEF_ABI(name) RABBITIZER_ABI_##name + +typedef enum RabbitizerAbi { + #include "Abi.inc" + + RABBITIZER_DEF_ABI(MAX), +} RabbitizerAbi; + +#undef RABBITIZER_DEF_ABI + +RabbitizerAbi RabbitizerAbi_fromStr(const char *name); + + +typedef struct RabbitizerConfig_RegisterNames { + bool namedRegisters; // Enables using named registers. This option takes precedence over the other named register options + RabbitizerAbi gprAbiNames; // The ABI names to be used for general purpose registers when disassembling the main processor's instructions + RabbitizerAbi fprAbiNames; // The ABI names to be used for floating point registers when disassembling the floating point (coprocessor 1) instructions + bool userFpcCsr; // Use FpcCsr as register $31 for the FP control/status register + bool vr4300Cop0NamedRegisters; // Use named registers for VR4300's coprocessor 0 registers + bool vr4300RspCop0NamedRegisters; // Use named registers for VR4300's RSP's coprocessor 0 registers +} RabbitizerConfig_RegisterNames; + +typedef struct RabbitizerConfig_PseudoInstr { + bool enablePseudos; // Produce pseudo instructions (like `move` or `b`) whenever those may match the desired original instruction + bool pseudoBeqz; + bool pseudoBnez; + bool pseudoB; + bool pseudoMove; + bool pseudoNot; + bool pseudoNegu; + bool pseudoBal; +} RabbitizerConfig_PseudoInstr; + +typedef struct RabbitizerConfig_ToolchainTweaks { + bool treatJAsUnconditionalBranch; //! @deprecated + /** + * Enables a few fixes for SN64's assembler related to div/divu instructions + * + * - SN64's assembler doesn't like assembling `div $0, a, b` with .set noat active. + * Removing the $0 fixes this issue (but not for handwritten asm) + * + * - SN64's assembler expands div to have break if dividing by zero + * However, the break it generates is different than the one it generates with `break N` + * So we replace break instrutions for SN64 with the exact word that the assembler generates when expanding div + */ + bool sn64DivFix; +} RabbitizerConfig_ToolchainTweaks; + +typedef struct RabbitizerConfig_Misc { + int opcodeLJust; // The minimal number of characters to left-align the opcode name + bool unknownInstrComment; // Generate a pseudo-disassembly comment when disassembling non implemented instructions + bool omit0XOnSmallImm; + bool upperCaseImm; +} RabbitizerConfig_Misc; + +typedef struct RabbitizerConfig { + RabbitizerConfig_RegisterNames regNames; + RabbitizerConfig_PseudoInstr pseudos; + RabbitizerConfig_ToolchainTweaks toolchainTweaks; + RabbitizerConfig_Misc misc; +} RabbitizerConfig; + +extern RabbitizerConfig RabbitizerConfig_Cfg; + + +#ifdef __cplusplus +} +#endif + +#endif diff --git a/tools/ido-static-recomp/tools/rabbitizer/include/common/RabbitizerVersion.h b/tools/ido-static-recomp/tools/rabbitizer/include/common/RabbitizerVersion.h new file mode 100644 index 00000000..d59e716f --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/include/common/RabbitizerVersion.h @@ -0,0 +1,33 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +#ifndef RABBITIZER_VERSION_H +#define RABBITIZER_VERSION_H + +#include "Utils.h" + +#ifdef __cplusplus +extern "C" { +#endif + + +// Header version +#define RAB_VERSION_MAJOR 1 +#define RAB_VERSION_MINOR 2 +#define RAB_VERSION_PATCH 3 + +#define RAB_VERSION_STR RAB_STRINGIFY(RAB_VERSION_MAJOR) "." RAB_STRINGIFY(RAB_VERSION_MINOR) "." RAB_STRINGIFY(RAB_VERSION_PATCH) + +// Compiled library version +extern const int RabVersion_Major; +extern const int RabVersion_Minor; +extern const int RabVersion_Patch; + +extern const char RabVersion_Str[]; + + +#ifdef __cplusplus +} +#endif + +#endif diff --git a/tools/ido-static-recomp/tools/rabbitizer/include/common/Utils.h b/tools/ido-static-recomp/tools/rabbitizer/include/common/Utils.h new file mode 100644 index 00000000..6255a04a --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/include/common/Utils.h @@ -0,0 +1,116 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +#ifndef RABBITIZER_UTILS_H +#define RABBITIZER_UTILS_H + +#include +#include + +#ifdef __cplusplus +extern "C" { +#endif + + +#if !defined(__GNUC__) && !defined(__clang__) +#define __attribute__(x) +#endif + +#if __STDC_VERSION__ >= 202000L +#define CONST [[gnu::const]] +#define DEPRECATED(reason) [[deprecated (reason)]] +#define FALLTHROUGH [[fallthrough]] +#define NODISCARD [[nodiscard]] +#define NORETURN [[noreturn]] +#define NON_NULL(...) [[gnu::nonnull (__VA_ARGS__)]] +#define PURE [[gnu::pure]] +#define RETURNS_NON_NULL [[gnu::returns_nonnull]] +#define UNUSED [[maybe_unused]] +#else +#define CONST __attribute__((const)) +#define DEPRECATED(reason) __attribute__((deprecated (reason))) +#define FALLTHROUGH __attribute__((fallthrough)) +#define NODISCARD __attribute__((warn_unused_result)) +#define NORETURN _Noreturn +#define NON_NULL(...) __attribute__((nonnull (__VA_ARGS__))) +#define PURE __attribute__((pure)) +#define RETURNS_NON_NULL __attribute__((returns_nonnull)) +#define UNUSED __attribute__((unused)) +#endif + + +#if defined(_MSC_VER) +# define UNREACHABLE __assume(0) +#elif defined(__GNUC__) || defined(__clang__) +# define UNREACHABLE __builtin_unreachable() +#else +# define UNREACHABLE +#endif + + +#define ARRAY_COUNT(arr) (sizeof(arr) / sizeof((arr)[0])) + +#define RAB_STRINGIFY(x) #x + +#define MASK(v, w) ((v) & ((1 << (w)) - 1)) + +/* + * the SHIFT macros take a value, a shift amount, and a width. + * + * For the left shift, the lower bits of the value are masked, + * then shifted left. + * + * For the right shift, the value is shifted right, then the lower bits + * are masked. + * + * (NOTE: SHIFTL(v, 0, 32) won't work, just use an assignment) + * + */ +#define SHIFTL(v, s, w) (MASK((v), (w)) << (s)) +#define SHIFTR(v, s, w) (MASK((v) >> (s), (w))) + +#define BITREPACK(fullword, v, s, w) ((SHIFTR((fullword), (s)+(w), 32-((s)+(w))) << ((s)+(w))) | SHIFTL((v), (s), (w)) | MASK((fullword), (s))) +#define BITREPACK_RIGHT(fullword, v, s, w) (SHIFTL((v), (s), (w)) | MASK((fullword), (s))) + + +#define RABUTILS_BUFFER_ADVANCE(buffer, totalSize, expression) \ + do { \ + size_t __tempSize = expression; \ + (buffer) += __tempSize; \ + (totalSize) += __tempSize; \ + } while (0) + +#define RABUTILS_BUFFER_WRITE_CHAR(buffer, totalSize, character) \ + do { \ + *(buffer) = (character); \ + RABUTILS_BUFFER_ADVANCE(buffer, totalSize, 1); \ + } while (0) + +#define RABUTILS_BUFFER_SPRINTF(buffer, totalSize, format, ...) \ + do { \ + int _len = sprintf(buffer, format, __VA_ARGS__); \ + assert(_len > 0); \ + RABUTILS_BUFFER_ADVANCE(buffer, totalSize, _len); \ + } while (0) + +#define RABUTILS_BUFFER_CPY(buffer, totalSize, string) \ + do { \ + size_t _tempSize = strlen(string); \ + memcpy(buffer, string, _tempSize); \ + RABUTILS_BUFFER_ADVANCE(buffer, totalSize, _tempSize); \ + } while (0) + + +CONST NODISCARD +int32_t RabbitizerUtils_From2Complement(uint32_t number, int bits); +NON_NULL(1) +size_t RabbitizerUtils_CharFill(char *dst, int count, char fillchar); +NON_NULL(1, 3) +size_t RabbitizerUtils_escapeString(char *dst, size_t dstSize, const char *src, size_t srcSize); + + +#ifdef __cplusplus +} +#endif + +#endif diff --git a/tools/ido-static-recomp/tools/rabbitizer/include/instructions/InstrCategory.inc b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/InstrCategory.inc new file mode 100644 index 00000000..9a6d85c1 --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/InstrCategory.inc @@ -0,0 +1,6 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +RABBITIZER_DEF_INSTR_CATEGORY(CPU), +RABBITIZER_DEF_INSTR_CATEGORY(RSP), // N64 +RABBITIZER_DEF_INSTR_CATEGORY(R5900), // PS2's Emotion Engine diff --git a/tools/ido-static-recomp/tools/rabbitizer/include/instructions/RabbitizerInstrDescriptor.h b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/RabbitizerInstrDescriptor.h new file mode 100644 index 00000000..e92f7971 --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/RabbitizerInstrDescriptor.h @@ -0,0 +1,141 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +#ifndef RABBITIZER_INSTRDESCRIPTOR_H +#define RABBITIZER_INSTRDESCRIPTOR_H +#pragma once + +#include + +#include "common/Utils.h" +#include "RabbitizerOperandType.h" +#include "RabbitizerInstrId.h" +#include "RabbitizerInstrSuffix.h" + +#ifdef __cplusplus +extern "C" { +#endif + + +typedef enum RabbitizerInstrType { + RABBITIZER_INSTR_TYPE_UNKNOWN, + RABBITIZER_INSTR_TYPE_J, + RABBITIZER_INSTR_TYPE_I, + RABBITIZER_INSTR_TYPE_R, + RABBITIZER_INSTR_TYPE_REGIMM, + RABBITIZER_INSTR_TYPE_MAX, +} RabbitizerInstrType; + +typedef enum RabbitizerArchitectureVersion { + RABBITIZER_ARCHVERSION_INVALID=-1, + RABBITIZER_ARCHVERSION_UNKNOWN, + RABBITIZER_ARCHVERSION_MIPS_I, + RABBITIZER_ARCHVERSION_MIPS_II, + RABBITIZER_ARCHVERSION_MIPS_III, + RABBITIZER_ARCHVERSION_MIPS_IV +} RabbitizerArchitectureVersion; + +typedef struct RabbitizerInstrDescriptor { + RabbitizerOperandType operands[4]; + RabbitizerInstrType instrType; + + RabbitizerInstrSuffix instrSuffix; + + bool isBranch; + bool isBranchLikely; + bool isJump; + bool isTrap; + + bool isFloat; + bool isDouble; + + bool isUnsigned; + + bool modifiesRt; + bool modifiesRd; + + bool notEmitedByCompilers; + + bool canBeHi; + bool canBeLo; + bool doesLink; // "and link" family of instructions + bool doesDereference; + bool doesLoad; // loads data from memory + bool doesStore; // stores data to memory + bool maybeIsMove; + + bool isPseudo; + + RabbitizerArchitectureVersion architectureVersion; // TODO: consider removing +} RabbitizerInstrDescriptor; + +// TODO: less redundant name +extern const RabbitizerInstrDescriptor RabbitizerInstrDescriptor_Descriptors[]; + + +NODISCARD NON_NULL(1) PURE +bool RabbitizerInstrDescriptor_isUnknownType(const RabbitizerInstrDescriptor *self); +NODISCARD NON_NULL(1) PURE +bool RabbitizerInstrDescriptor_isJType(const RabbitizerInstrDescriptor *self); +NODISCARD NON_NULL(1) PURE +bool RabbitizerInstrDescriptor_isIType(const RabbitizerInstrDescriptor *self); +NODISCARD NON_NULL(1) PURE +bool RabbitizerInstrDescriptor_isRType(const RabbitizerInstrDescriptor *self); +NODISCARD NON_NULL(1) PURE +bool RabbitizerInstrDescriptor_isRegimmType(const RabbitizerInstrDescriptor *self); + +NODISCARD NON_NULL(1) PURE +RabbitizerInstrSuffix RabbitizerInstrDescriptor_instrSuffix(const RabbitizerInstrDescriptor *self); + +NODISCARD NON_NULL(1) PURE +bool RabbitizerInstrDescriptor_isBranch(const RabbitizerInstrDescriptor *self); +NODISCARD NON_NULL(1) PURE +bool RabbitizerInstrDescriptor_isBranchLikely(const RabbitizerInstrDescriptor *self); +NODISCARD NON_NULL(1) PURE +bool RabbitizerInstrDescriptor_isJump(const RabbitizerInstrDescriptor *self); +NODISCARD NON_NULL(1) PURE +bool RabbitizerInstrDescriptor_isTrap(const RabbitizerInstrDescriptor *self); + +NODISCARD NON_NULL(1) PURE +bool RabbitizerInstrDescriptor_isFloat(const RabbitizerInstrDescriptor *self); +NODISCARD NON_NULL(1) PURE +bool RabbitizerInstrDescriptor_isDouble(const RabbitizerInstrDescriptor *self); + +NODISCARD NON_NULL(1) PURE +bool RabbitizerInstrDescriptor_isUnsigned(const RabbitizerInstrDescriptor *self); + +NODISCARD NON_NULL(1) PURE +bool RabbitizerInstrDescriptor_modifiesRt(const RabbitizerInstrDescriptor *self); +NODISCARD NON_NULL(1) PURE +bool RabbitizerInstrDescriptor_modifiesRd(const RabbitizerInstrDescriptor *self); + +NODISCARD NON_NULL(1) PURE +bool RabbitizerInstrDescriptor_notEmitedByCompilers(const RabbitizerInstrDescriptor *self); + +NODISCARD NON_NULL(1) PURE +bool RabbitizerInstrDescriptor_canBeHi(const RabbitizerInstrDescriptor *self); +NODISCARD NON_NULL(1) PURE +bool RabbitizerInstrDescriptor_canBeLo(const RabbitizerInstrDescriptor *self); +NODISCARD NON_NULL(1) PURE +bool RabbitizerInstrDescriptor_doesLink(const RabbitizerInstrDescriptor *self); +NODISCARD NON_NULL(1) PURE +bool RabbitizerInstrDescriptor_doesDereference(const RabbitizerInstrDescriptor *self); +NODISCARD NON_NULL(1) PURE +bool RabbitizerInstrDescriptor_doesLoad(const RabbitizerInstrDescriptor *self); +NODISCARD NON_NULL(1) PURE +bool RabbitizerInstrDescriptor_doesStore(const RabbitizerInstrDescriptor *self); +NODISCARD NON_NULL(1) PURE +bool RabbitizerInstrDescriptor_maybeIsMove(const RabbitizerInstrDescriptor *self); + +NODISCARD NON_NULL(1) PURE +bool RabbitizerInstrDescriptor_isPseudo(const RabbitizerInstrDescriptor *self); + +NODISCARD NON_NULL(1) PURE +RabbitizerArchitectureVersion RabbitizerInstrDescriptor_getArchitectureVersion(const RabbitizerInstrDescriptor *self); + + +#ifdef __cplusplus +} +#endif + +#endif diff --git a/tools/ido-static-recomp/tools/rabbitizer/include/instructions/RabbitizerInstrId.h b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/RabbitizerInstrId.h new file mode 100644 index 00000000..c3838211 --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/RabbitizerInstrId.h @@ -0,0 +1,46 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +#ifndef RABBITIZER_INSTRID_H +#define RABBITIZER_INSTRID_H +#pragma once + +#include "common/Utils.h" + +#ifdef __cplusplus +extern "C" { +#endif + + +#define RABBITIZER_DEF_INSTR_ID(prefix, caseBits, name, ...) \ + RABBITIZER_INSTR_ID_##prefix##_##name, + +#define RABBITIZER_DEF_INSTR_ID_ALTNAME(prefix, caseBits, name, altname, ...) \ + RABBITIZER_DEF_INSTR_ID(prefix, caseBits, name, __VA_ARGS__) + +typedef enum RabbitizerInstrId { + #include "instructions/instr_id/RabbitizerInstrId_cpu.inc" + + #include "instructions/instr_id/RabbitizerInstrId_rsp.inc" + + #include "instructions/instr_id/RabbitizerInstrId_r5900.inc" + + RABBITIZER_INSTR_ID_ALL_MAX = RABBITIZER_DEF_INSTR_ID(r5900, , MAX, ) +} RabbitizerInstrId; + +#undef RABBITIZER_DEF_INSTR_ID +#undef RABBITIZER_DEF_INSTR_ID_ALTNAME + + +extern const char *RabbitizerInstrId_Names[]; + + +CONST NODISCARD RETURNS_NON_NULL +const char *RabbitizerInstrId_getOpcodeName(RabbitizerInstrId uniqueId); + + +#ifdef __cplusplus +} +#endif + +#endif diff --git a/tools/ido-static-recomp/tools/rabbitizer/include/instructions/RabbitizerInstrSuffix.h b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/RabbitizerInstrSuffix.h new file mode 100644 index 00000000..7c59e334 --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/RabbitizerInstrSuffix.h @@ -0,0 +1,36 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +#ifndef RABBITIZER_INSTRSUFFIX_H +#define RABBITIZER_INSTRSUFFIX_H +#pragma once + +#include "common/Utils.h" + +#ifdef __cplusplus +extern "C" { +#endif + + +struct RabbitizerInstruction; + +typedef enum RabbitizerInstrSuffix { + RABINSTRSUFFIX_NONE, + + RABINSTRSUFFIX_R5900_xyzw, + + RABINSTRSUFFIX_MAX +} RabbitizerInstrSuffix; + +CONST NODISCARD NON_NULL(1) +size_t RabbitizerInstrSuffix_getSizeForBuffer(const struct RabbitizerInstruction *self, RabbitizerInstrSuffix instrSuffix); + +CONST NODISCARD NON_NULL(1, 2) +size_t RabbitizerInstrSuffix_processSuffix(const struct RabbitizerInstruction *self, char *dst, RabbitizerInstrSuffix instrSuffix); + + +#ifdef __cplusplus +} +#endif + +#endif diff --git a/tools/ido-static-recomp/tools/rabbitizer/include/instructions/RabbitizerInstruction.h b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/RabbitizerInstruction.h new file mode 100644 index 00000000..17e3bab9 --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/RabbitizerInstruction.h @@ -0,0 +1,263 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +#ifndef RABBITIZER_INSTRUCTION_H +#define RABBITIZER_INSTRUCTION_H +#pragma once + +#include +#include +#include + +#include "common/Utils.h" + +#include "RabbitizerInstrId.h" +#include "RabbitizerInstrDescriptor.h" + +#ifdef __cplusplus +extern "C" { +#endif + + +#define RABBITIZER_DEF_INSTR_CATEGORY(name) RABBITIZER_INSTRCAT_##name + +typedef enum RabbitizerInstrCategory { + #include "instructions/InstrCategory.inc" + + RABBITIZER_DEF_INSTR_CATEGORY(MAX), +} RabbitizerInstrCategory; + +#undef RABBITIZER_DEF_INSTR_CATEGORY + + +typedef struct RabbitizerInstruction { + uint32_t word; + uint32_t _mandatorybits; + + RabbitizerInstrId uniqueId; + const RabbitizerInstrDescriptor *descriptor; + + uint32_t vram; + bool _handwrittenCategory; + bool inHandwrittenFunction; + RabbitizerInstrCategory category; +} RabbitizerInstruction; + + +#define RAB_INSTR_GET_opcode(self) (SHIFTR((self)->word, 26, 6)) +#define RAB_INSTR_GET_rs(self) (SHIFTR((self)->word, 21, 5)) +#define RAB_INSTR_GET_rt(self) (SHIFTR((self)->word, 16, 5)) +#define RAB_INSTR_GET_rd(self) (SHIFTR((self)->word, 11, 5)) +#define RAB_INSTR_GET_sa(self) (SHIFTR((self)->word, 6, 5)) +#define RAB_INSTR_GET_function(self) (SHIFTR((self)->word, 0, 6)) + +#define RAB_INSTR_GET_cop0d(self) (SHIFTR((self)->word, 11, 5)) + +#define RAB_INSTR_GET_instr_index(self) (SHIFTR((self)->word, 0, 26)) +#define RAB_INSTR_GET_immediate(self) (SHIFTR((self)->word, 0, 16)) + +#define RAB_INSTR_GET_fs(self) (SHIFTR((self)->word, 11, 5)) +#define RAB_INSTR_GET_ft(self) (SHIFTR((self)->word, 16, 5)) +#define RAB_INSTR_GET_fd(self) (SHIFTR((self)->word, 6, 5)) +#define RAB_INSTR_GET_cop1cs(self) (SHIFTR((self)->word, 11, 5)) + +#define RAB_INSTR_GET_op(self) (SHIFTR((self)->word, 16, 5)) + +#define RAB_INSTR_GET_code(self) (SHIFTR((self)->word, 6, 20)) +#define RAB_INSTR_GET_code_upper(self) (SHIFTR((self)->word, 16, 10)) +#define RAB_INSTR_GET_code_lower(self) (SHIFTR((self)->word, 6, 10)) + +#define RAB_INSTR_GET_copraw(self) (SHIFTR((self)->word, 0, 25)) + +#define RAB_INSTR_GET_fmt(self) (SHIFTR((self)->word, 21, 5)) +#define RAB_INSTR_GET_fc(self) (SHIFTR((self)->word, 4, 2)) +#define RAB_INSTR_GET_cond(self) (SHIFTR((self)->word, 0, 4)) + +#define RAB_INSTR_GET_cop2t(self) (SHIFTR((self)->word, 16, 5)) + +#define RAB_INSTR_GET_tf(self) (SHIFTR((self)->word, 16, 1)) +#define RAB_INSTR_GET_nd(self) (SHIFTR((self)->word, 17, 1)) +#define RAB_INSTR_GET_bc_fmt(self) (SHIFTR((self)->word, 16, 5)) + +#define RAB_INSTR_GET_stype(self) (SHIFTR((self)->word, 6, 5)) + + +#define RAB_INSTR_PACK_opcode(word, value) (BITREPACK_RIGHT((word), (value), 26, 6)) +#define RAB_INSTR_PACK_rs(word, value) (BITREPACK((word), (value), 21, 5)) +#define RAB_INSTR_PACK_rt(word, value) (BITREPACK((word), (value), 16, 5)) +#define RAB_INSTR_PACK_rd(word, value) (BITREPACK((word), (value), 11, 5)) +#define RAB_INSTR_PACK_sa(word, value) (BITREPACK((word), (value), 6, 5)) +#define RAB_INSTR_PACK_function(word, value) (BITREPACK((word), (value), 0, 6)) + +#define RAB_INSTR_PACK_cop0d(word, value) (BITREPACK((word), (value), 11, 5)) + +#define RAB_INSTR_PACK_instr_index(word, value) (BITREPACK((word), (value), 0, 26)) +#define RAB_INSTR_PACK_immediate(word, value) (BITREPACK((word), (value), 0, 16)) + +#define RAB_INSTR_PACK_code(word, value) (BITREPACK((word), (value), 6, 20)) +#define RAB_INSTR_PACK_code_upper(word, value) (BITREPACK((word), (value), 16, 10)) +#define RAB_INSTR_PACK_code_lower(word, value) (BITREPACK((word), (value), 6, 10)) + +#define RAB_INSTR_PACK_copraw(word, value) (BITREPACK((word), (value), 0, 25)) + +#define RAB_INSTR_PACK_fmt(word, value) (BITREPACK((word), (value), 21, 5)) +#define RAB_INSTR_PACK_fc(word, value) (BITREPACK((word), (value), 4, 2)) +#define RAB_INSTR_PACK_cond(word, value) (BITREPACK((word), (value), 0, 4)) + +#define RAB_INSTR_PACK_fs(word, value) (BITREPACK((word), (value), 11, 5)) +#define RAB_INSTR_PACK_ft(word, value) (BITREPACK((word), (value), 16, 5)) +#define RAB_INSTR_PACK_fd(word, value) (BITREPACK((word), (value), 6, 5)) +#define RAB_INSTR_PACK_cop1cs(word, value) (BITREPACK((word), (value), 11, 5)) + +#define RAB_INSTR_PACK_op(word, value) (BITREPACK((word), (value), 16, 5)) + +#define RAB_INSTR_PACK_cop2t(word, value) (BITREPACK((word), (value), 16, 5)) + +#define RAB_INSTR_PACK_tf(word, value) (BITREPACK((word), (value), 16, 1)) +#define RAB_INSTR_PACK_nd(word, value) (BITREPACK((word), (value), 17, 1)) +#define RAB_INSTR_PACK_bc_fmt(word, value) (BITREPACK((word), (value), 16, 5)) + +#define RAB_INSTR_PACK_stype(word, value) (BITREPACK((word), (value), 6, 5)) + + +NON_NULL(1) +void RabbitizerInstruction_init(RabbitizerInstruction *self, uint32_t word, uint32_t vram); +NON_NULL(1) +void RabbitizerInstruction_destroy(RabbitizerInstruction* self); + + +/* Process uniqueId */ + +NON_NULL(1) +void RabbitizerInstruction_processUniqueId_Normal(RabbitizerInstruction *self); +NON_NULL(1) +void RabbitizerInstruction_processUniqueId_Special(RabbitizerInstruction *self); +NON_NULL(1) +void RabbitizerInstruction_processUniqueId_Regimm(RabbitizerInstruction *self); + +NON_NULL(1) +void RabbitizerInstruction_processUniqueId_Coprocessor0_BC0(RabbitizerInstruction *self); +NON_NULL(1) +void RabbitizerInstruction_processUniqueId_Coprocessor0_Tlb(RabbitizerInstruction *self); + +NON_NULL(1) +void RabbitizerInstruction_processUniqueId_Coprocessor0(RabbitizerInstruction *self); + +NON_NULL(1) +void RabbitizerInstruction_processUniqueId_Coprocessor1_BC1(RabbitizerInstruction *self); +NON_NULL(1) +void RabbitizerInstruction_processUniqueId_Coprocessor1_FpuS(RabbitizerInstruction *self); +NON_NULL(1) +void RabbitizerInstruction_processUniqueId_Coprocessor1_FpuD(RabbitizerInstruction *self); +NON_NULL(1) +void RabbitizerInstruction_processUniqueId_Coprocessor1_FpuW(RabbitizerInstruction *self); +NON_NULL(1) +void RabbitizerInstruction_processUniqueId_Coprocessor1_FpuL(RabbitizerInstruction *self); + +NON_NULL(1) +void RabbitizerInstruction_processUniqueId_Coprocessor1(RabbitizerInstruction *self); + +NON_NULL(1) +void RabbitizerInstruction_processUniqueId_Coprocessor2(RabbitizerInstruction *self); +NON_NULL(1) +void RabbitizerInstruction_processUniqueId(RabbitizerInstruction *self); + +/* Process uniqueId */ + + +/* General getters */ + +NODISCARD NON_NULL(1) PURE +uint32_t RabbitizerInstruction_getRaw(const RabbitizerInstruction *self); + +NODISCARD NON_NULL(1) PURE +uint32_t RabbitizerInstruction_getImmediate(const RabbitizerInstruction *self); +NODISCARD NON_NULL(1) PURE +int32_t RabbitizerInstruction_getProcessedImmediate(const RabbitizerInstruction *self); +NODISCARD NON_NULL(1) PURE +uint32_t RabbitizerInstruction_getInstrIndex(const RabbitizerInstruction *self); +NODISCARD NON_NULL(1) PURE +uint32_t RabbitizerInstruction_getInstrIndexAsVram(const RabbitizerInstruction *self); + +NODISCARD NON_NULL(1) PURE +int32_t RabbitizerInstruction_getBranchOffset(const RabbitizerInstruction *self); +NODISCARD NON_NULL(1) PURE +int32_t RabbitizerInstruction_getGenericBranchOffset(const RabbitizerInstruction *self, uint32_t currentVram); + +/* General getters */ + +NON_NULL(1) +void RabbitizerInstruction_blankOut(RabbitizerInstruction *self); + + +/* Instruction examination */ + +NODISCARD NON_NULL(1) PURE +bool RabbitizerInstruction_isImplemented(const RabbitizerInstruction *self); +NODISCARD NON_NULL(1) PURE +bool RabbitizerInstruction_isLikelyHandwritten(const RabbitizerInstruction *self); +NODISCARD NON_NULL(1) PURE +bool RabbitizerInstruction_isNop(const RabbitizerInstruction *self); +NODISCARD NON_NULL(1) PURE +bool RabbitizerInstruction_isUnconditionalBranch(const RabbitizerInstruction *self); +NODISCARD NON_NULL(1) PURE +bool RabbitizerInstruction_isJrRa(const RabbitizerInstruction *self); +NODISCARD NON_NULL(1) PURE +bool RabbitizerInstruction_isJrNotRa(const RabbitizerInstruction *self); +NODISCARD NON_NULL(1) PURE +bool RabbitizerInstruction_hasDelaySlot(const RabbitizerInstruction *self); + +NODISCARD NON_NULL(1) PURE +const char *RabbitizerInstruction_mapInstrToType(const RabbitizerInstruction *self); + +NODISCARD NON_NULL(1, 2) PURE +bool RabbitizerInstruction_sameOpcode(const RabbitizerInstruction *self, const RabbitizerInstruction *other); +NODISCARD NON_NULL(1, 2) PURE +bool RabbitizerInstruction_sameOpcodeButDifferentArguments(const RabbitizerInstruction *self, const RabbitizerInstruction *other); + +NODISCARD NON_NULL(1) PURE +bool RabbitizerInstruction_hasOperand(const RabbitizerInstruction *self, RabbitizerOperandType operand); +NODISCARD NON_NULL(1) PURE +bool RabbitizerInstruction_hasOperandAlias(const RabbitizerInstruction *self, RabbitizerOperandType operand); + +NODISCARD NON_NULL(1) PURE +uint32_t RabbitizerInstruction_getValidBits(const RabbitizerInstruction *self); +NODISCARD NON_NULL(1) PURE +bool RabbitizerInstruction_isValid(const RabbitizerInstruction *self); + +/* Instruction examination */ + + +/* Disassembly */ + +NODISCARD NON_NULL(1) PURE +bool RabbitizerInstruction_mustDisasmAsData(const RabbitizerInstruction *self); + +NODISCARD NON_NULL(1) PURE +size_t RabbitizerInstruction_getSizeForBufferOperandsDisasm(const RabbitizerInstruction *self, size_t immOverrideLength); +NON_NULL(1, 2) +size_t RabbitizerInstruction_disassembleOperands(const RabbitizerInstruction *self, char *dst, const char *immOverride, size_t immOverrideLength); + +NODISCARD NON_NULL(1) PURE +size_t RabbitizerInstruction_getSizeForBufferInstrDisasm(const RabbitizerInstruction *self, size_t immOverrideLength, int extraLJust); +NON_NULL(1, 2) +size_t RabbitizerInstruction_disassembleInstruction(const RabbitizerInstruction *self, char *dst, const char *immOverride, size_t immOverrideLength, int extraLJust); + +NODISCARD NON_NULL(1) PURE +size_t RabbitizerInstruction_getSizeForBufferDataDisasm(const RabbitizerInstruction *self, int extraLJust); +NON_NULL(1, 2) +size_t RabbitizerInstruction_disassembleAsData(const RabbitizerInstruction *self, char *dst, int extraLJust); + +NODISCARD NON_NULL(1) PURE +size_t RabbitizerInstruction_getSizeForBuffer(const RabbitizerInstruction *self, size_t immOverrideLength, int extraLJust); +NON_NULL(1, 2) +size_t RabbitizerInstruction_disassemble(const RabbitizerInstruction *self, char *dst, const char *immOverride, size_t immOverrideLength, int extraLJust); + +/* Disassembly */ + + +#ifdef __cplusplus +} +#endif + +#endif diff --git a/tools/ido-static-recomp/tools/rabbitizer/include/instructions/RabbitizerInstructionR5900.h b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/RabbitizerInstructionR5900.h new file mode 100644 index 00000000..af5e809e --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/RabbitizerInstructionR5900.h @@ -0,0 +1,87 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +#ifndef RABBITIZER_INSTRUCTION_R5900_H +#define RABBITIZER_INSTRUCTION_R5900_H +#pragma once + +#include "RabbitizerInstruction.h" + +#ifdef __cplusplus +extern "C" { +#endif + + +#define RAB_INSTR_R5900_GET_mmi_function(self) (SHIFTR((self)->word, 6, 5)) +#define RAB_INSTR_R5900_GET_fhi_flo(self) ((SHIFTR((self)->word, 6, 5) << 2) | SHIFTR((self)->word, 0, 2)) + +#define RAB_INSTR_R5900_GET_vfs(self) (SHIFTR((self)->word, 11, 5)) +#define RAB_INSTR_R5900_GET_vft(self) (SHIFTR((self)->word, 16, 5)) +#define RAB_INSTR_R5900_GET_vfd(self) (SHIFTR((self)->word, 6, 5)) + +#define RAB_INSTR_R5900_GET_xyzw_x(self) (SHIFTR((self)->word, 24, 1)) +#define RAB_INSTR_R5900_GET_xyzw_y(self) (SHIFTR((self)->word, 23, 1)) +#define RAB_INSTR_R5900_GET_xyzw_z(self) (SHIFTR((self)->word, 22, 1)) +#define RAB_INSTR_R5900_GET_xyzw_w(self) (SHIFTR((self)->word, 21, 1)) +#define RAB_INSTR_R5900_GET_n(self) (SHIFTR((self)->word, 0, 2)) +#define RAB_INSTR_R5900_GET_l(self) (SHIFTR((self)->word, 21, 2)) +#define RAB_INSTR_R5900_GET_m(self) (SHIFTR((self)->word, 23, 2)) + +#define RAB_INSTR_R5900_GET_vis(self) (SHIFTR((self)->word, 11, 5)) +#define RAB_INSTR_R5900_GET_vit(self) (SHIFTR((self)->word, 16, 5)) +#define RAB_INSTR_R5900_GET_vid(self) (SHIFTR((self)->word, 6, 5)) + +#define RAB_INSTR_R5900_GET_imm5(self) (SHIFTR((self)->word, 6, 5)) + + +#define RAB_INSTR_R5900_PACK_mmi_function(word, value) (BITREPACK((word), (value), 6, 5)) +#define RAB_INSTR_R5900_PACK_fhi_flo(word, value) (BITREPACK(BITREPACK((word), (value) >> 2, 6, 5), (value), 0, 2)) + +#define RAB_INSTR_R5900_PACK_vfs(word, value) (BITREPACK((word), (value), 11, 5)) +#define RAB_INSTR_R5900_PACK_vft(word, value) (BITREPACK((word), (value), 16, 5)) +#define RAB_INSTR_R5900_PACK_vfd(word, value) (BITREPACK((word), (value), 6, 5)) + +#define RAB_INSTR_R5900_PACK_xyzw_x(word, value) (BITREPACK((word), (value), 24, 1)) +#define RAB_INSTR_R5900_PACK_xyzw_y(word, value) (BITREPACK((word), (value), 23, 1)) +#define RAB_INSTR_R5900_PACK_xyzw_z(word, value) (BITREPACK((word), (value), 22, 1)) +#define RAB_INSTR_R5900_PACK_xyzw_w(word, value) (BITREPACK((word), (value), 21, 1)) +#define RAB_INSTR_R5900_PACK_n(word, value) (BITREPACK((word), (value), 0, 2)) +#define RAB_INSTR_R5900_PACK_l(word, value) (BITREPACK((word), (value), 21, 2)) +#define RAB_INSTR_R5900_PACK_m(word, value) (BITREPACK((word), (value), 23, 2)) + +#define RAB_INSTR_R5900_PACK_vis(word, value) (BITREPACK((word), (value), 11, 5)) +#define RAB_INSTR_R5900_PACK_vit(word, value) (BITREPACK((word), (value), 16, 5)) +#define RAB_INSTR_R5900_PACK_vid(word, value) (BITREPACK((word), (value), 6, 5)) + +#define RAB_INSTR_R5900_PACK_imm5(word, value) (BITREPACK((word), (value), 6, 5)) + + +NON_NULL(1) +void RabbitizerInstructionR5900_init(RabbitizerInstruction *self, uint32_t word, uint32_t vram); +NON_NULL(1) +void RabbitizerInstructionR5900_destroy(RabbitizerInstruction *self); + +NON_NULL(1) +void RabbitizerInstructionR5900_processUniqueId_Normal(RabbitizerInstruction *self); +NON_NULL(1) +void RabbitizerInstructionR5900_processUniqueId_Special(RabbitizerInstruction *self); +NON_NULL(1) +void RabbitizerInstructionR5900_processUniqueId_Regimm(RabbitizerInstruction *self); +NON_NULL(1) +void RabbitizerInstructionR5900_processUniqueId_Coprocessor0(RabbitizerInstruction *self); +NON_NULL(1) +void RabbitizerInstructionR5900_processUniqueId_Coprocessor1(RabbitizerInstruction *self); +NON_NULL(1) +void RabbitizerInstructionR5900_processUniqueId_Coprocessor2(RabbitizerInstruction *self); +NON_NULL(1) +void RabbitizerInstructionR5900_processUniqueId_MMI(RabbitizerInstruction *self); + +NON_NULL(1) +void RabbitizerInstructionR5900_processUniqueId(RabbitizerInstruction *self); + + +#ifdef __cplusplus +} +#endif + +#endif diff --git a/tools/ido-static-recomp/tools/rabbitizer/include/instructions/RabbitizerInstructionRsp.h b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/RabbitizerInstructionRsp.h new file mode 100644 index 00000000..b2fb40d5 --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/RabbitizerInstructionRsp.h @@ -0,0 +1,70 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +#ifndef RABBITIZER_INSTRUCTION_RSP_H +#define RABBITIZER_INSTRUCTION_RSP_H +#pragma once + +#include "RabbitizerInstruction.h" + +#ifdef __cplusplus +extern "C" { +#endif + + +#define RAB_INSTR_RSP_GET_cop2t(self) (SHIFTR((self)->word, 16, 5)) +#define RAB_INSTR_RSP_GET_cop2cd(self) (SHIFTR((self)->word, 11, 5)) + +#define RAB_INSTR_RSP_GET_vs(self) (SHIFTR((self)->word, 11, 5)) +#define RAB_INSTR_RSP_GET_vt(self) (SHIFTR((self)->word, 16, 5)) +#define RAB_INSTR_RSP_GET_vd(self) (SHIFTR((self)->word, 6, 5)) + +#define RAB_INSTR_RSP_GET_elementhigh(self) (SHIFTR((self)->word, 21, 4)) +#define RAB_INSTR_RSP_GET_elementlow(self) (SHIFTR((self)->word, 7, 4)) +#define RAB_INSTR_RSP_GET_OFFSET_VECTOR_RAW(self) (SHIFTR((self)->word, 0, 7)) + +#define RAB_INSTR_RSP_GET_index(self) (SHIFTR((self)->word, 7, 4)) +#define RAB_INSTR_RSP_GET_de(self) (SHIFTR((self)->word, 11, 5)) + + +#define RAB_INSTR_RSP_PACK_cop2t(word, value) (BITREPACK((word), value, 16, 5)) +#define RAB_INSTR_RSP_PACK_cop2cd(word, value) (BITREPACK((word), value, 11, 5)) + +#define RAB_INSTR_RSP_PACK_vs(word, value) (BITREPACK((word), value, 11, 5)) +#define RAB_INSTR_RSP_PACK_vt(word, value) (BITREPACK((word), value, 16, 5)) +#define RAB_INSTR_RSP_PACK_vd(word, value) (BITREPACK((word), value, 6, 5)) + +#define RAB_INSTR_RSP_PACK_elementhigh(word, value) (BITREPACK((word), value, 21, 4)) +#define RAB_INSTR_RSP_PACK_elementlow(word, value) (BITREPACK((word), value, 7, 4)) + +#define RAB_INSTR_RSP_PACK_index(word, value) (BITREPACK((word), value, 7, 4)) +#define RAB_INSTR_RSP_PACK_offset(word, value) (BITREPACK((word), value, 0, 7)) +#define RAB_INSTR_RSP_PACK_de(word, value) (BITREPACK((word), value, 11, 5)) + + +NON_NULL(1) +void RabbitizerInstructionRsp_init(RabbitizerInstruction *self, uint32_t word, uint32_t vram); +NON_NULL(1) +void RabbitizerInstructionRsp_destroy(RabbitizerInstruction *self); + + +NON_NULL(1) +void RabbitizerInstructionRsp_processUniqueId_Normal(RabbitizerInstruction *self); +NON_NULL(1) +void RabbitizerInstructionRsp_processUniqueId_Special(RabbitizerInstruction *self); +NON_NULL(1) +void RabbitizerInstructionRsp_processUniqueId_Regimm(RabbitizerInstruction *self); + +NON_NULL(1) +void RabbitizerInstructionRsp_processUniqueId(RabbitizerInstruction *self); + + +NODISCARD NON_NULL(1) PURE +uint16_t RabbitizerInstructionRsp_GetOffsetVector(const RabbitizerInstruction *self); + + +#ifdef __cplusplus +} +#endif + +#endif diff --git a/tools/ido-static-recomp/tools/rabbitizer/include/instructions/RabbitizerOperandType.h b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/RabbitizerOperandType.h new file mode 100644 index 00000000..58c26594 --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/RabbitizerOperandType.h @@ -0,0 +1,33 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +#ifndef RABBITIZER_OPERAND_TYPE_H +#define RABBITIZER_OPERAND_TYPE_H +#pragma once + +#ifdef __cplusplus +extern "C" { +#endif + + +#define RAB_DEF_OPERAND(prefix, operand) \ + RAB_OPERAND_##prefix##_##operand, + +typedef enum RabbitizerOperandType { + RAB_DEF_OPERAND(ALL, INVALID) + +#include "operands/RabbitizerOperandType_cpu.inc" +#include "operands/RabbitizerOperandType_rsp.inc" +#include "operands/RabbitizerOperandType_r5900.inc" + + RAB_DEF_OPERAND(ALL, MAX) +} RabbitizerOperandType; + +#undef RAB_DEF_OPERAND + + +#ifdef __cplusplus +} +#endif + +#endif diff --git a/tools/ido-static-recomp/tools/rabbitizer/include/instructions/RabbitizerRegister.h b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/RabbitizerRegister.h new file mode 100644 index 00000000..1c6421cd --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/RabbitizerRegister.h @@ -0,0 +1,143 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +#ifndef RABBITIZER_REGISTER_H +#define RABBITIZER_REGISTER_H +#pragma once + +#include + +#include "common/Utils.h" + +#ifdef __cplusplus +extern "C" { +#endif + + +#define RABBITIZER_DEF_REG(prefix, name, numeric) \ + RABBITIZER_REG_##prefix##_##name + +#define RABBITIZER_DEF_REG_NODOLLAR(prefix, name, numeric) \ + RABBITIZER_REG_##prefix##_##name + + +typedef enum RabbitizerRegister_GprO32 { + #include "instructions/registers/RabbitizerRegister_GprO32.inc" +} RabbitizerRegister_GprO32; + +typedef enum RabbitizerRegister_GprN32 { + #include "instructions/registers/RabbitizerRegister_GprN32.inc" +} RabbitizerRegister_GprN32; + +typedef enum RabbitizerRegister_Cop0 { + #include "instructions/registers/RabbitizerRegister_Cop0.inc" +} RabbitizerRegister_Cop0; + +// Float registers +typedef enum RabbitizerRegister_Cop1O32 { + #include "instructions/registers/RabbitizerRegister_Cop1O32.inc" +} RabbitizerRegister_Cop1O32; + +typedef enum RabbitizerRegister_Cop1N32 { + #include "instructions/registers/RabbitizerRegister_Cop1N32.inc" +} RabbitizerRegister_Cop1N32; + +typedef enum RabbitizerRegister_Cop1N64 { + #include "instructions/registers/RabbitizerRegister_Cop1N64.inc" +} RabbitizerRegister_Cop1N64; + +typedef enum RabbitizerRegister_Cop1Control { + #include "instructions/registers/RabbitizerRegister_Cop1Control.inc" +} RabbitizerRegister_Cop1Control; + +typedef enum RabbitizerRegister_Cop2 { + #include "instructions/registers/RabbitizerRegister_Cop2.inc" +} RabbitizerRegister_Cop2; + + +/* RSP */ + +typedef enum RabbitizerRegister_RspGpr { + #include "instructions/registers/RabbitizerRegister_RspGpr.inc" +} RabbitizerRegister_RspGpr; + +typedef enum RabbitizerRegister_RspCop0 { + #include "instructions/registers/RabbitizerRegister_RspCop0.inc" +} RabbitizerRegister_RspCop0; + +typedef enum RabbitizerRegister_RspCop2 { + #include "instructions/registers/RabbitizerRegister_RspCop2.inc" +} RabbitizerRegister_RspCop2; + +typedef enum RabbitizerRegister_RspCop2Control { + #include "instructions/registers/RabbitizerRegister_RspCop2Control.inc" +} RabbitizerRegister_RspCop2Control; + +typedef enum RabbitizerRegister_RspVector { + #include "instructions/registers/RabbitizerRegister_RspVector.inc" +} RabbitizerRegister_RspVector; + +/* RSP */ + +/* R5900 */ + +typedef enum RabbitizerRegister_R5900VF { + #include "instructions/registers/RabbitizerRegister_R5900VF.inc" +} RabbitizerRegister_R5900VF; + +typedef enum RabbitizerRegister_R5900VI { + #include "instructions/registers/RabbitizerRegister_R5900VI.inc" +} RabbitizerRegister_R5900VI; + +/* R5900 */ + + +#undef RABBITIZER_DEF_REG +#undef RABBITIZER_DEF_REG_NODOLLAR + + +extern const char *RabbitizerRegister_GprO32_Names[][2]; +extern const char *RabbitizerRegister_GprN32_Names[][2]; +extern const char *RabbitizerRegister_Cop0_Names[][2]; +extern const char *RabbitizerRegister_Cop1O32_Names[][2]; +extern const char *RabbitizerRegister_Cop1N32_Names[][2]; +extern const char *RabbitizerRegister_Cop1N64_Names[][2]; +extern const char *RabbitizerRegister_Cop2_Names[][2]; +extern const char *RabbitizerRegister_RspGpr_Names[][2]; +extern const char *RabbitizerRegister_RspCop0_Names[][2]; +extern const char *RabbitizerRegister_RspVector_Names[][2]; + + +NODISCARD PURE RETURNS_NON_NULL +const char *RabbitizerRegister_getNameGpr(uint8_t regValue); +NODISCARD PURE RETURNS_NON_NULL +const char *RabbitizerRegister_getNameCop0(uint8_t regValue); +NODISCARD PURE RETURNS_NON_NULL +const char *RabbitizerRegister_getNameCop1(uint8_t regValue); +NODISCARD PURE RETURNS_NON_NULL +const char *RabbitizerRegister_getNameCop1Control(uint8_t regValue); +NODISCARD PURE RETURNS_NON_NULL +const char *RabbitizerRegister_getNameCop2(uint8_t regValue); + +NODISCARD PURE RETURNS_NON_NULL +const char *RabbitizerRegister_getNameRspGpr(uint8_t regValue); +NODISCARD PURE RETURNS_NON_NULL +const char *RabbitizerRegister_getNameRspCop0(uint8_t regValue); +NODISCARD PURE RETURNS_NON_NULL +const char *RabbitizerRegister_getNameRspCop2(uint8_t regValue); +NODISCARD PURE RETURNS_NON_NULL +const char *RabbitizerRegister_getNameRspCop2Control(uint8_t regValue); +NODISCARD PURE RETURNS_NON_NULL +const char *RabbitizerRegister_getNameRspVector(uint8_t regValue); + +NODISCARD PURE RETURNS_NON_NULL +const char *RabbitizerRegister_getNameR5900VF(uint8_t regValue); +NODISCARD PURE RETURNS_NON_NULL +const char *RabbitizerRegister_getNameR5900VI(uint8_t regValue); + + +#ifdef __cplusplus +} +#endif + +#endif diff --git a/tools/ido-static-recomp/tools/rabbitizer/include/instructions/instr_id/RabbitizerInstrId_cpu.inc b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/instr_id/RabbitizerInstrId_cpu.inc new file mode 100644 index 00000000..dbbb9818 --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/instr_id/RabbitizerInstrId_cpu.inc @@ -0,0 +1,40 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +RABBITIZER_DEF_INSTR_ID(cpu, , INVALID, .operands={RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_rt, RAB_OPERAND_cpu_immediate}) + +#include "instructions/instr_id/cpu/cpu_normal.inc" +#include "instructions/instr_id/cpu/cpu_special.inc" +#include "instructions/instr_id/cpu/cpu_regimm.inc" +#include "instructions/instr_id/cpu/cpu_cop0.inc" +#include "instructions/instr_id/cpu/cpu_cop0_bc0.inc" +#include "instructions/instr_id/cpu/cpu_cop0_tlb.inc" +#include "instructions/instr_id/cpu/cpu_cop1.inc" +#include "instructions/instr_id/cpu/cpu_cop1_bc1.inc" +#include "instructions/instr_id/cpu/cpu_cop1_fpu_s.inc" +#include "instructions/instr_id/cpu/cpu_cop1_fpu_d.inc" +#include "instructions/instr_id/cpu/cpu_cop1_fpu_w.inc" +#include "instructions/instr_id/cpu/cpu_cop1_fpu_l.inc" + +RABBITIZER_DEF_INSTR_ID(cpu, , USERDEF_00, .operands={0}) +RABBITIZER_DEF_INSTR_ID(cpu, , USERDEF_01, .operands={0}) +RABBITIZER_DEF_INSTR_ID(cpu, , USERDEF_02, .operands={0}) +RABBITIZER_DEF_INSTR_ID(cpu, , USERDEF_03, .operands={0}) +RABBITIZER_DEF_INSTR_ID(cpu, , USERDEF_04, .operands={0}) +RABBITIZER_DEF_INSTR_ID(cpu, , USERDEF_05, .operands={0}) +RABBITIZER_DEF_INSTR_ID(cpu, , USERDEF_06, .operands={0}) +RABBITIZER_DEF_INSTR_ID(cpu, , USERDEF_07, .operands={0}) +RABBITIZER_DEF_INSTR_ID(cpu, , USERDEF_08, .operands={0}) +RABBITIZER_DEF_INSTR_ID(cpu, , USERDEF_09, .operands={0}) +RABBITIZER_DEF_INSTR_ID(cpu, , USERDEF_10, .operands={0}) +RABBITIZER_DEF_INSTR_ID(cpu, , USERDEF_11, .operands={0}) +RABBITIZER_DEF_INSTR_ID(cpu, , USERDEF_12, .operands={0}) +RABBITIZER_DEF_INSTR_ID(cpu, , USERDEF_13, .operands={0}) +RABBITIZER_DEF_INSTR_ID(cpu, , USERDEF_14, .operands={0}) +RABBITIZER_DEF_INSTR_ID(cpu, , USERDEF_15, .operands={0}) +RABBITIZER_DEF_INSTR_ID(cpu, , USERDEF_16, .operands={0}) +RABBITIZER_DEF_INSTR_ID(cpu, , USERDEF_17, .operands={0}) +RABBITIZER_DEF_INSTR_ID(cpu, , USERDEF_18, .operands={0}) +RABBITIZER_DEF_INSTR_ID(cpu, , USERDEF_19, .operands={0}) + +RABBITIZER_DEF_INSTR_ID(cpu, , MAX, .operands={0}) diff --git a/tools/ido-static-recomp/tools/rabbitizer/include/instructions/instr_id/RabbitizerInstrId_r5900.inc b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/instr_id/RabbitizerInstrId_r5900.inc new file mode 100644 index 00000000..10f11126 --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/instr_id/RabbitizerInstrId_r5900.inc @@ -0,0 +1,46 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +RABBITIZER_DEF_INSTR_ID(r5900, , INVALID, .operands={RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_rt, RAB_OPERAND_cpu_immediate}, .instrType=RABBITIZER_INSTR_TYPE_UNKNOWN, .architectureVersion=-1) + +#include "instructions/instr_id/r5900/r5900_normal.inc" +#include "instructions/instr_id/r5900/r5900_special.inc" +#include "instructions/instr_id/r5900/r5900_regimm.inc" + +#include "instructions/instr_id/r5900/r5900_mmi.inc" +#include "instructions/instr_id/r5900/r5900_mmi_0.inc" +#include "instructions/instr_id/r5900/r5900_mmi_1.inc" +#include "instructions/instr_id/r5900/r5900_mmi_2.inc" +#include "instructions/instr_id/r5900/r5900_mmi_3.inc" + +#include "instructions/instr_id/r5900/r5900_cop0_tlb.inc" + +#include "instructions/instr_id/r5900/r5900_cop1_fpu_s.inc" + +#include "instructions/instr_id/r5900/r5900_cop2.inc" +#include "instructions/instr_id/r5900/r5900_cop2_bc2.inc" +#include "instructions/instr_id/r5900/r5900_cop2_special1.inc" +#include "instructions/instr_id/r5900/r5900_cop2_special2.inc" + +RABBITIZER_DEF_INSTR_ID(r5900, , USERDEF_00, .operands={0}) +RABBITIZER_DEF_INSTR_ID(r5900, , USERDEF_01, .operands={0}) +RABBITIZER_DEF_INSTR_ID(r5900, , USERDEF_02, .operands={0}) +RABBITIZER_DEF_INSTR_ID(r5900, , USERDEF_03, .operands={0}) +RABBITIZER_DEF_INSTR_ID(r5900, , USERDEF_04, .operands={0}) +RABBITIZER_DEF_INSTR_ID(r5900, , USERDEF_05, .operands={0}) +RABBITIZER_DEF_INSTR_ID(r5900, , USERDEF_06, .operands={0}) +RABBITIZER_DEF_INSTR_ID(r5900, , USERDEF_07, .operands={0}) +RABBITIZER_DEF_INSTR_ID(r5900, , USERDEF_08, .operands={0}) +RABBITIZER_DEF_INSTR_ID(r5900, , USERDEF_09, .operands={0}) +RABBITIZER_DEF_INSTR_ID(r5900, , USERDEF_10, .operands={0}) +RABBITIZER_DEF_INSTR_ID(r5900, , USERDEF_11, .operands={0}) +RABBITIZER_DEF_INSTR_ID(r5900, , USERDEF_12, .operands={0}) +RABBITIZER_DEF_INSTR_ID(r5900, , USERDEF_13, .operands={0}) +RABBITIZER_DEF_INSTR_ID(r5900, , USERDEF_14, .operands={0}) +RABBITIZER_DEF_INSTR_ID(r5900, , USERDEF_15, .operands={0}) +RABBITIZER_DEF_INSTR_ID(r5900, , USERDEF_16, .operands={0}) +RABBITIZER_DEF_INSTR_ID(r5900, , USERDEF_17, .operands={0}) +RABBITIZER_DEF_INSTR_ID(r5900, , USERDEF_18, .operands={0}) +RABBITIZER_DEF_INSTR_ID(r5900, , USERDEF_19, .operands={0}) + +RABBITIZER_DEF_INSTR_ID(r5900, , MAX, .operands={0}) diff --git a/tools/ido-static-recomp/tools/rabbitizer/include/instructions/instr_id/RabbitizerInstrId_rsp.inc b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/instr_id/RabbitizerInstrId_rsp.inc new file mode 100644 index 00000000..2fcaa854 --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/instr_id/RabbitizerInstrId_rsp.inc @@ -0,0 +1,41 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +// RSP instructions +RABBITIZER_DEF_INSTR_ID(rsp, , INVALID, .operands={RAB_OPERAND_rsp_vd, RAB_OPERAND_rsp_vs, RAB_OPERAND_rsp_vt_elementhigh}) + +#include "instructions/instr_id/rsp/rsp_cop2.inc" +#include "instructions/instr_id/rsp/rsp_cop2_vu.inc" + +#include "instructions/instr_id/rsp/rsp_normal_lwc2.inc" +#include "instructions/instr_id/rsp/rsp_normal_swc2.inc" + +// CPU instructions but with rsp registers + +#include "instructions/instr_id/rsp/rsp_normal.inc" +#include "instructions/instr_id/rsp/rsp_special.inc" +#include "instructions/instr_id/rsp/rsp_regimm.inc" +#include "instructions/instr_id/rsp/rsp_cop0.inc" + +RABBITIZER_DEF_INSTR_ID(rsp, , USERDEF_00, .operands={0}) +RABBITIZER_DEF_INSTR_ID(rsp, , USERDEF_01, .operands={0}) +RABBITIZER_DEF_INSTR_ID(rsp, , USERDEF_02, .operands={0}) +RABBITIZER_DEF_INSTR_ID(rsp, , USERDEF_03, .operands={0}) +RABBITIZER_DEF_INSTR_ID(rsp, , USERDEF_04, .operands={0}) +RABBITIZER_DEF_INSTR_ID(rsp, , USERDEF_05, .operands={0}) +RABBITIZER_DEF_INSTR_ID(rsp, , USERDEF_06, .operands={0}) +RABBITIZER_DEF_INSTR_ID(rsp, , USERDEF_07, .operands={0}) +RABBITIZER_DEF_INSTR_ID(rsp, , USERDEF_08, .operands={0}) +RABBITIZER_DEF_INSTR_ID(rsp, , USERDEF_09, .operands={0}) +RABBITIZER_DEF_INSTR_ID(rsp, , USERDEF_10, .operands={0}) +RABBITIZER_DEF_INSTR_ID(rsp, , USERDEF_11, .operands={0}) +RABBITIZER_DEF_INSTR_ID(rsp, , USERDEF_12, .operands={0}) +RABBITIZER_DEF_INSTR_ID(rsp, , USERDEF_13, .operands={0}) +RABBITIZER_DEF_INSTR_ID(rsp, , USERDEF_14, .operands={0}) +RABBITIZER_DEF_INSTR_ID(rsp, , USERDEF_15, .operands={0}) +RABBITIZER_DEF_INSTR_ID(rsp, , USERDEF_16, .operands={0}) +RABBITIZER_DEF_INSTR_ID(rsp, , USERDEF_17, .operands={0}) +RABBITIZER_DEF_INSTR_ID(rsp, , USERDEF_18, .operands={0}) +RABBITIZER_DEF_INSTR_ID(rsp, , USERDEF_19, .operands={0}) + +RABBITIZER_DEF_INSTR_ID(rsp, , MAX, .operands={0}) diff --git a/tools/ido-static-recomp/tools/rabbitizer/include/instructions/instr_id/cpu/cpu_cop0.inc b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/instr_id/cpu/cpu_cop0.inc new file mode 100644 index 00000000..0aa3df49 --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/instr_id/cpu/cpu_cop0.inc @@ -0,0 +1,10 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +// OP rt, cop0d +RABBITIZER_DEF_INSTR_ID(cpu, 0x00, mfc0, .operands={RAB_OPERAND_cpu_rt, RAB_OPERAND_cpu_cop0d}, .instrType=RABBITIZER_INSTR_TYPE_UNKNOWN, .modifiesRt=true, .notEmitedByCompilers=true) // Move word From CP0 +RABBITIZER_DEF_INSTR_ID(cpu, 0x01, dmfc0, .operands={RAB_OPERAND_cpu_rt, RAB_OPERAND_cpu_cop0d}, .instrType=RABBITIZER_INSTR_TYPE_UNKNOWN, .modifiesRt=true) // Doubleword Move From CP0 +RABBITIZER_DEF_INSTR_ID(cpu, 0x02, cfc0, .operands={RAB_OPERAND_cpu_rt, RAB_OPERAND_cpu_cop0d}, .instrType=RABBITIZER_INSTR_TYPE_UNKNOWN, .modifiesRt=true) // Move control word From CP0 +RABBITIZER_DEF_INSTR_ID(cpu, 0x04, mtc0, .operands={RAB_OPERAND_cpu_rt, RAB_OPERAND_cpu_cop0d}, .instrType=RABBITIZER_INSTR_TYPE_UNKNOWN, .notEmitedByCompilers=true) // Move word to CP0 +RABBITIZER_DEF_INSTR_ID(cpu, 0x05, dmtc0, .operands={RAB_OPERAND_cpu_rt, RAB_OPERAND_cpu_cop0d}, .instrType=RABBITIZER_INSTR_TYPE_UNKNOWN) // Doubleword Move To CP0 +RABBITIZER_DEF_INSTR_ID(cpu, 0x06, ctc0, .operands={RAB_OPERAND_cpu_rt, RAB_OPERAND_cpu_cop0d}, .instrType=RABBITIZER_INSTR_TYPE_UNKNOWN) // Move control word To CP0 diff --git a/tools/ido-static-recomp/tools/rabbitizer/include/instructions/instr_id/cpu/cpu_cop0_bc0.inc b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/instr_id/cpu/cpu_cop0_bc0.inc new file mode 100644 index 00000000..0165039b --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/instr_id/cpu/cpu_cop0_bc0.inc @@ -0,0 +1,8 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +// OP IMM +RABBITIZER_DEF_INSTR_ID(cpu, 0x00, bc0f, .operands={RAB_OPERAND_cpu_branch_target_label}, .instrType=RABBITIZER_INSTR_TYPE_UNKNOWN, .isBranch=true) // Branch on FP False +RABBITIZER_DEF_INSTR_ID(cpu, 0x01, bc0t, .operands={RAB_OPERAND_cpu_branch_target_label}, .instrType=RABBITIZER_INSTR_TYPE_UNKNOWN, .isBranch=true) // Branch on FP True +RABBITIZER_DEF_INSTR_ID(cpu, 0x02, bc0fl, .operands={RAB_OPERAND_cpu_branch_target_label}, .instrType=RABBITIZER_INSTR_TYPE_UNKNOWN, .isBranch=true, .isBranchLikely=true) // Branch on FP False Likely +RABBITIZER_DEF_INSTR_ID(cpu, 0x03, bc0tl, .operands={RAB_OPERAND_cpu_branch_target_label}, .instrType=RABBITIZER_INSTR_TYPE_UNKNOWN, .isBranch=true, .isBranchLikely=true) // Branch on FP True Likely diff --git a/tools/ido-static-recomp/tools/rabbitizer/include/instructions/instr_id/cpu/cpu_cop0_tlb.inc b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/instr_id/cpu/cpu_cop0_tlb.inc new file mode 100644 index 00000000..65b808e3 --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/instr_id/cpu/cpu_cop0_tlb.inc @@ -0,0 +1,12 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +// OP +RABBITIZER_DEF_INSTR_ID(cpu, 0x01, tlbr, .operands={0}, .instrType=RABBITIZER_INSTR_TYPE_UNKNOWN, .notEmitedByCompilers=true) // Read Indexed TLB Entry +RABBITIZER_DEF_INSTR_ID(cpu, 0x02, tlbwi, .operands={0}, .instrType=RABBITIZER_INSTR_TYPE_UNKNOWN, .notEmitedByCompilers=true) // Write Indexed TLB Entry + +RABBITIZER_DEF_INSTR_ID(cpu, 0x06, tlbwr, .operands={0}, .instrType=RABBITIZER_INSTR_TYPE_UNKNOWN) // Write Random TLB Entry + +RABBITIZER_DEF_INSTR_ID(cpu, 0x08, tlbp, .operands={0}, .instrType=RABBITIZER_INSTR_TYPE_UNKNOWN, .notEmitedByCompilers=true) // Probe TLB for Matching Entry + +RABBITIZER_DEF_INSTR_ID(cpu, 0x18, eret, .operands={0}, .instrType=RABBITIZER_INSTR_TYPE_UNKNOWN, .notEmitedByCompilers=true) // Return from Exception diff --git a/tools/ido-static-recomp/tools/rabbitizer/include/instructions/instr_id/cpu/cpu_cop1.inc b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/instr_id/cpu/cpu_cop1.inc new file mode 100644 index 00000000..e6defc81 --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/instr_id/cpu/cpu_cop1.inc @@ -0,0 +1,12 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +// OP rt, fs +RABBITIZER_DEF_INSTR_ID(cpu, 0x00, mfc1, .operands={RAB_OPERAND_cpu_rt, RAB_OPERAND_cpu_fs}, .instrType=RABBITIZER_INSTR_TYPE_UNKNOWN, .isFloat=true, .modifiesRt=true) // Move Word From Floating-Point +RABBITIZER_DEF_INSTR_ID(cpu, 0x01, dmfc1, .operands={RAB_OPERAND_cpu_rt, RAB_OPERAND_cpu_fs}, .instrType=RABBITIZER_INSTR_TYPE_UNKNOWN, .isFloat=true, .modifiesRt=true) // Doubleword Move From Floating-Point +RABBITIZER_DEF_INSTR_ID(cpu, 0x04, mtc1, .operands={RAB_OPERAND_cpu_rt, RAB_OPERAND_cpu_fs}, .instrType=RABBITIZER_INSTR_TYPE_UNKNOWN, .isFloat=true) // Move Word to Floating-Point +RABBITIZER_DEF_INSTR_ID(cpu, 0x05, dmtc1, .operands={RAB_OPERAND_cpu_rt, RAB_OPERAND_cpu_fs}, .instrType=RABBITIZER_INSTR_TYPE_UNKNOWN, .isFloat=true) // Doubleword Move To Floating-Point + +// OP rt, cop1cs +RABBITIZER_DEF_INSTR_ID(cpu, 0x02, cfc1, .operands={RAB_OPERAND_cpu_rt, RAB_OPERAND_cpu_cop1cs}, .instrType=RABBITIZER_INSTR_TYPE_UNKNOWN, .isFloat=true, .modifiesRt=true) // Move Control Word from Floating-Point +RABBITIZER_DEF_INSTR_ID(cpu, 0x06, ctc1, .operands={RAB_OPERAND_cpu_rt, RAB_OPERAND_cpu_cop1cs}, .instrType=RABBITIZER_INSTR_TYPE_UNKNOWN, .isFloat=true) // Move Control Word to Floating-Point diff --git a/tools/ido-static-recomp/tools/rabbitizer/include/instructions/instr_id/cpu/cpu_cop1_bc1.inc b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/instr_id/cpu/cpu_cop1_bc1.inc new file mode 100644 index 00000000..e339cd4d --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/instr_id/cpu/cpu_cop1_bc1.inc @@ -0,0 +1,8 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +// OP IMM +RABBITIZER_DEF_INSTR_ID(cpu, 0x00, bc1f, .operands={RAB_OPERAND_cpu_branch_target_label}, .instrType=RABBITIZER_INSTR_TYPE_UNKNOWN, .isBranch=true) +RABBITIZER_DEF_INSTR_ID(cpu, 0x01, bc1t, .operands={RAB_OPERAND_cpu_branch_target_label}, .instrType=RABBITIZER_INSTR_TYPE_UNKNOWN, .isBranch=true) +RABBITIZER_DEF_INSTR_ID(cpu, 0x02, bc1fl, .operands={RAB_OPERAND_cpu_branch_target_label}, .instrType=RABBITIZER_INSTR_TYPE_UNKNOWN, .isBranch=true, .isBranchLikely=true) +RABBITIZER_DEF_INSTR_ID(cpu, 0x03, bc1tl, .operands={RAB_OPERAND_cpu_branch_target_label}, .instrType=RABBITIZER_INSTR_TYPE_UNKNOWN, .isBranch=true, .isBranchLikely=true) diff --git a/tools/ido-static-recomp/tools/rabbitizer/include/instructions/instr_id/cpu/cpu_cop1_fpu_d.inc b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/instr_id/cpu/cpu_cop1_fpu_d.inc new file mode 100644 index 00000000..a512496c --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/instr_id/cpu/cpu_cop1_fpu_d.inc @@ -0,0 +1,48 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +// OP fd, fs, ft +RABBITIZER_DEF_INSTR_ID_ALTNAME(cpu, 0x00, add_d, add.d, .operands={RAB_OPERAND_cpu_fd, RAB_OPERAND_cpu_fs, RAB_OPERAND_cpu_ft}, .instrType=RABBITIZER_INSTR_TYPE_UNKNOWN, .isFloat=true) // Floating-Point Add +RABBITIZER_DEF_INSTR_ID_ALTNAME(cpu, 0x01, sub_d, sub.d, .operands={RAB_OPERAND_cpu_fd, RAB_OPERAND_cpu_fs, RAB_OPERAND_cpu_ft}, .instrType=RABBITIZER_INSTR_TYPE_UNKNOWN, .isFloat=true) // Floating-Point Sub +RABBITIZER_DEF_INSTR_ID_ALTNAME(cpu, 0x02, mul_d, mul.d, .operands={RAB_OPERAND_cpu_fd, RAB_OPERAND_cpu_fs, RAB_OPERAND_cpu_ft}, .instrType=RABBITIZER_INSTR_TYPE_UNKNOWN, .isFloat=true) // Floating-Point Multiply +RABBITIZER_DEF_INSTR_ID_ALTNAME(cpu, 0x03, div_d, div.d, .operands={RAB_OPERAND_cpu_fd, RAB_OPERAND_cpu_fs, RAB_OPERAND_cpu_ft}, .instrType=RABBITIZER_INSTR_TYPE_UNKNOWN, .isFloat=true) // Floating-Point Divide + +// OP fd, fs +RABBITIZER_DEF_INSTR_ID_ALTNAME(cpu, 0x04, sqrt_d, sqrt.d, .operands={RAB_OPERAND_cpu_fd, RAB_OPERAND_cpu_fs}, .instrType=RABBITIZER_INSTR_TYPE_UNKNOWN, .isFloat=true) // Floating-Point Square Root +RABBITIZER_DEF_INSTR_ID_ALTNAME(cpu, 0x05, abs_d, abs.d, .operands={RAB_OPERAND_cpu_fd, RAB_OPERAND_cpu_fs}, .instrType=RABBITIZER_INSTR_TYPE_UNKNOWN, .isFloat=true) // Floating-Point Absolute Value +RABBITIZER_DEF_INSTR_ID_ALTNAME(cpu, 0x06, mov_d, mov.d, .operands={RAB_OPERAND_cpu_fd, RAB_OPERAND_cpu_fs}, .instrType=RABBITIZER_INSTR_TYPE_UNKNOWN, .isFloat=true) // Floating-Point Move +RABBITIZER_DEF_INSTR_ID_ALTNAME(cpu, 0x07, neg_d, neg.d, .operands={RAB_OPERAND_cpu_fd, RAB_OPERAND_cpu_fs}, .instrType=RABBITIZER_INSTR_TYPE_UNKNOWN, .isFloat=true) // Floating-Point Negate + +RABBITIZER_DEF_INSTR_ID_ALTNAME(cpu, 0x08, round_l_d, round.l.d, .operands={RAB_OPERAND_cpu_fd, RAB_OPERAND_cpu_fs}, .instrType=RABBITIZER_INSTR_TYPE_UNKNOWN, .isFloat=true) // Floating-Point Round to Long Fixed-Point +RABBITIZER_DEF_INSTR_ID_ALTNAME(cpu, 0x09, trunc_l_d, trunc.l.d, .operands={RAB_OPERAND_cpu_fd, RAB_OPERAND_cpu_fs}, .instrType=RABBITIZER_INSTR_TYPE_UNKNOWN, .isFloat=true) // Floating-Point Truncate to Long Fixed-Point +RABBITIZER_DEF_INSTR_ID_ALTNAME(cpu, 0x0A, ceil_l_d, ceil.l.d, .operands={RAB_OPERAND_cpu_fd, RAB_OPERAND_cpu_fs}, .instrType=RABBITIZER_INSTR_TYPE_UNKNOWN, .isFloat=true) // Floating-Point Ceiling Convert to Long Fixed-Point +RABBITIZER_DEF_INSTR_ID_ALTNAME(cpu, 0x0B, floor_l_d, floor.l.d, .operands={RAB_OPERAND_cpu_fd, RAB_OPERAND_cpu_fs}, .instrType=RABBITIZER_INSTR_TYPE_UNKNOWN, .isFloat=true) // Floating-Point Floor Convert to Long Fixed-Point + +RABBITIZER_DEF_INSTR_ID_ALTNAME(cpu, 0x0C, round_w_d, round.w.d, .operands={RAB_OPERAND_cpu_fd, RAB_OPERAND_cpu_fs}, .instrType=RABBITIZER_INSTR_TYPE_UNKNOWN, .isFloat=true) // Floating-Point Round to Word Fixed-Point +RABBITIZER_DEF_INSTR_ID_ALTNAME(cpu, 0x0D, trunc_w_d, trunc.w.d, .operands={RAB_OPERAND_cpu_fd, RAB_OPERAND_cpu_fs}, .instrType=RABBITIZER_INSTR_TYPE_UNKNOWN, .isFloat=true) // Floating-Point Truncate to Word Fixed-Point +RABBITIZER_DEF_INSTR_ID_ALTNAME(cpu, 0x0E, ceil_w_d, ceil.w.d, .operands={RAB_OPERAND_cpu_fd, RAB_OPERAND_cpu_fs}, .instrType=RABBITIZER_INSTR_TYPE_UNKNOWN, .isFloat=true) // Floating-Point Ceiling Convert to Word Fixed-Point +RABBITIZER_DEF_INSTR_ID_ALTNAME(cpu, 0x0F, floor_w_d, floor.w.d, .operands={RAB_OPERAND_cpu_fd, RAB_OPERAND_cpu_fs}, .instrType=RABBITIZER_INSTR_TYPE_UNKNOWN, .isFloat=true) // Floating-Point Floor Convert to Word Fixed-Point + +// OP fd, fs +RABBITIZER_DEF_INSTR_ID_ALTNAME(cpu, 0x20, cvt_s_d, cvt.s.d, .operands={RAB_OPERAND_cpu_fd, RAB_OPERAND_cpu_fs}, .instrType=RABBITIZER_INSTR_TYPE_UNKNOWN, .isFloat=true, .isDouble=true) +RABBITIZER_DEF_INSTR_ID_ALTNAME(cpu, 0x24, cvt_w_d, cvt.w.d, .operands={RAB_OPERAND_cpu_fd, RAB_OPERAND_cpu_fs}, .instrType=RABBITIZER_INSTR_TYPE_UNKNOWN, .isFloat=true, .isDouble=true) +RABBITIZER_DEF_INSTR_ID_ALTNAME(cpu, 0x25, cvt_l_d, cvt.l.d, .operands={RAB_OPERAND_cpu_fd, RAB_OPERAND_cpu_fs}, .instrType=RABBITIZER_INSTR_TYPE_UNKNOWN, .isFloat=true, .isDouble=true) + +// OP fs, ft +RABBITIZER_DEF_INSTR_ID_ALTNAME(cpu, 0x30, c_f_d, c.f.d, .operands={RAB_OPERAND_cpu_fs, RAB_OPERAND_cpu_ft}, .instrType=RABBITIZER_INSTR_TYPE_UNKNOWN, .isFloat=true) +RABBITIZER_DEF_INSTR_ID_ALTNAME(cpu, 0x31, c_un_d, c.un.d, .operands={RAB_OPERAND_cpu_fs, RAB_OPERAND_cpu_ft}, .instrType=RABBITIZER_INSTR_TYPE_UNKNOWN, .isFloat=true) +RABBITIZER_DEF_INSTR_ID_ALTNAME(cpu, 0x32, c_eq_d, c.eq.d, .operands={RAB_OPERAND_cpu_fs, RAB_OPERAND_cpu_ft}, .instrType=RABBITIZER_INSTR_TYPE_UNKNOWN, .isFloat=true) +RABBITIZER_DEF_INSTR_ID_ALTNAME(cpu, 0x33, c_ueq_d, c.ueq.d, .operands={RAB_OPERAND_cpu_fs, RAB_OPERAND_cpu_ft}, .instrType=RABBITIZER_INSTR_TYPE_UNKNOWN, .isFloat=true) +RABBITIZER_DEF_INSTR_ID_ALTNAME(cpu, 0x34, c_olt_d, c.olt.d, .operands={RAB_OPERAND_cpu_fs, RAB_OPERAND_cpu_ft}, .instrType=RABBITIZER_INSTR_TYPE_UNKNOWN, .isFloat=true) +RABBITIZER_DEF_INSTR_ID_ALTNAME(cpu, 0x35, c_ult_d, c.ult.d, .operands={RAB_OPERAND_cpu_fs, RAB_OPERAND_cpu_ft}, .instrType=RABBITIZER_INSTR_TYPE_UNKNOWN, .isFloat=true) +RABBITIZER_DEF_INSTR_ID_ALTNAME(cpu, 0x36, c_ole_d, c.ole.d, .operands={RAB_OPERAND_cpu_fs, RAB_OPERAND_cpu_ft}, .instrType=RABBITIZER_INSTR_TYPE_UNKNOWN, .isFloat=true) +RABBITIZER_DEF_INSTR_ID_ALTNAME(cpu, 0x37, c_ule_d, c.ule.d, .operands={RAB_OPERAND_cpu_fs, RAB_OPERAND_cpu_ft}, .instrType=RABBITIZER_INSTR_TYPE_UNKNOWN, .isFloat=true) + +RABBITIZER_DEF_INSTR_ID_ALTNAME(cpu, 0x38, c_df_d, c.df.d, .operands={RAB_OPERAND_cpu_fs, RAB_OPERAND_cpu_ft}, .instrType=RABBITIZER_INSTR_TYPE_UNKNOWN, .isFloat=true) +RABBITIZER_DEF_INSTR_ID_ALTNAME(cpu, 0x39, c_ngle_d, c.ngle.d, .operands={RAB_OPERAND_cpu_fs, RAB_OPERAND_cpu_ft}, .instrType=RABBITIZER_INSTR_TYPE_UNKNOWN, .isFloat=true) +RABBITIZER_DEF_INSTR_ID_ALTNAME(cpu, 0x3A, c_deq_d, c.deq.d, .operands={RAB_OPERAND_cpu_fs, RAB_OPERAND_cpu_ft}, .instrType=RABBITIZER_INSTR_TYPE_UNKNOWN, .isFloat=true) +RABBITIZER_DEF_INSTR_ID_ALTNAME(cpu, 0x3B, c_ngl_d, c.ngl.d, .operands={RAB_OPERAND_cpu_fs, RAB_OPERAND_cpu_ft}, .instrType=RABBITIZER_INSTR_TYPE_UNKNOWN, .isFloat=true) +RABBITIZER_DEF_INSTR_ID_ALTNAME(cpu, 0x3C, c_lt_d, c.lt.d, .operands={RAB_OPERAND_cpu_fs, RAB_OPERAND_cpu_ft}, .instrType=RABBITIZER_INSTR_TYPE_UNKNOWN, .isFloat=true) +RABBITIZER_DEF_INSTR_ID_ALTNAME(cpu, 0x3D, c_nge_d, c.nge.d, .operands={RAB_OPERAND_cpu_fs, RAB_OPERAND_cpu_ft}, .instrType=RABBITIZER_INSTR_TYPE_UNKNOWN, .isFloat=true) +RABBITIZER_DEF_INSTR_ID_ALTNAME(cpu, 0x3E, c_le_d, c.le.d, .operands={RAB_OPERAND_cpu_fs, RAB_OPERAND_cpu_ft}, .instrType=RABBITIZER_INSTR_TYPE_UNKNOWN, .isFloat=true) +RABBITIZER_DEF_INSTR_ID_ALTNAME(cpu, 0x3F, c_ngt_d, c.ngt.d, .operands={RAB_OPERAND_cpu_fs, RAB_OPERAND_cpu_ft}, .instrType=RABBITIZER_INSTR_TYPE_UNKNOWN, .isFloat=true) diff --git a/tools/ido-static-recomp/tools/rabbitizer/include/instructions/instr_id/cpu/cpu_cop1_fpu_l.inc b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/instr_id/cpu/cpu_cop1_fpu_l.inc new file mode 100644 index 00000000..48eea054 --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/instr_id/cpu/cpu_cop1_fpu_l.inc @@ -0,0 +1,6 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +// OP fd, fs +RABBITIZER_DEF_INSTR_ID_ALTNAME(cpu, 0x20, cvt_s_l, cvt.s.l, .operands={RAB_OPERAND_cpu_fd, RAB_OPERAND_cpu_fs}, .instrType=RABBITIZER_INSTR_TYPE_UNKNOWN, .isFloat=true) +RABBITIZER_DEF_INSTR_ID_ALTNAME(cpu, 0x21, cvt_d_l, cvt.d.l, .operands={RAB_OPERAND_cpu_fd, RAB_OPERAND_cpu_fs}, .instrType=RABBITIZER_INSTR_TYPE_UNKNOWN, .isFloat=true, .isDouble=true) diff --git a/tools/ido-static-recomp/tools/rabbitizer/include/instructions/instr_id/cpu/cpu_cop1_fpu_s.inc b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/instr_id/cpu/cpu_cop1_fpu_s.inc new file mode 100644 index 00000000..4271429b --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/instr_id/cpu/cpu_cop1_fpu_s.inc @@ -0,0 +1,48 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +// OP fd, fs, ft +RABBITIZER_DEF_INSTR_ID_ALTNAME(cpu, 0x00, add_s, add.s, .operands={RAB_OPERAND_cpu_fd, RAB_OPERAND_cpu_fs, RAB_OPERAND_cpu_ft}, .instrType=RABBITIZER_INSTR_TYPE_UNKNOWN, .isFloat=true) // Floating-Point Add +RABBITIZER_DEF_INSTR_ID_ALTNAME(cpu, 0x01, sub_s, sub.s, .operands={RAB_OPERAND_cpu_fd, RAB_OPERAND_cpu_fs, RAB_OPERAND_cpu_ft}, .instrType=RABBITIZER_INSTR_TYPE_UNKNOWN, .isFloat=true) // Floating-Point Sub +RABBITIZER_DEF_INSTR_ID_ALTNAME(cpu, 0x02, mul_s, mul.s, .operands={RAB_OPERAND_cpu_fd, RAB_OPERAND_cpu_fs, RAB_OPERAND_cpu_ft}, .instrType=RABBITIZER_INSTR_TYPE_UNKNOWN, .isFloat=true) // Floating-Point Multiply +RABBITIZER_DEF_INSTR_ID_ALTNAME(cpu, 0x03, div_s, div.s, .operands={RAB_OPERAND_cpu_fd, RAB_OPERAND_cpu_fs, RAB_OPERAND_cpu_ft}, .instrType=RABBITIZER_INSTR_TYPE_UNKNOWN, .isFloat=true) // Floating-Point Divide + +// OP fd, fs +RABBITIZER_DEF_INSTR_ID_ALTNAME(cpu, 0x04, sqrt_s, sqrt.s, .operands={RAB_OPERAND_cpu_fd, RAB_OPERAND_cpu_fs}, .instrType=RABBITIZER_INSTR_TYPE_UNKNOWN, .isFloat=true) // Floating-Point Square Root +RABBITIZER_DEF_INSTR_ID_ALTNAME(cpu, 0x05, abs_s, abs.s, .operands={RAB_OPERAND_cpu_fd, RAB_OPERAND_cpu_fs}, .instrType=RABBITIZER_INSTR_TYPE_UNKNOWN, .isFloat=true) // Floating-Point Absolute Value +RABBITIZER_DEF_INSTR_ID_ALTNAME(cpu, 0x06, mov_s, mov.s, .operands={RAB_OPERAND_cpu_fd, RAB_OPERAND_cpu_fs}, .instrType=RABBITIZER_INSTR_TYPE_UNKNOWN, .isFloat=true) // Floating-Point Move +RABBITIZER_DEF_INSTR_ID_ALTNAME(cpu, 0x07, neg_s, neg.s, .operands={RAB_OPERAND_cpu_fd, RAB_OPERAND_cpu_fs}, .instrType=RABBITIZER_INSTR_TYPE_UNKNOWN, .isFloat=true) // Floating-Point Negate + +RABBITIZER_DEF_INSTR_ID_ALTNAME(cpu, 0x08, round_l_s, round.l.s, .operands={RAB_OPERAND_cpu_fd, RAB_OPERAND_cpu_fs}, .instrType=RABBITIZER_INSTR_TYPE_UNKNOWN, .isFloat=true) // Floating-Point Round to Long Fixed-Point +RABBITIZER_DEF_INSTR_ID_ALTNAME(cpu, 0x09, trunc_l_s, trunc.l.s, .operands={RAB_OPERAND_cpu_fd, RAB_OPERAND_cpu_fs}, .instrType=RABBITIZER_INSTR_TYPE_UNKNOWN, .isFloat=true) // Floating-Point Truncate to Long Fixed-Point +RABBITIZER_DEF_INSTR_ID_ALTNAME(cpu, 0x0A, ceil_l_s, ceil.l.s, .operands={RAB_OPERAND_cpu_fd, RAB_OPERAND_cpu_fs}, .instrType=RABBITIZER_INSTR_TYPE_UNKNOWN, .isFloat=true) // Floating-Point Ceiling Convert to Long Fixed-Point +RABBITIZER_DEF_INSTR_ID_ALTNAME(cpu, 0x0B, floor_l_s, floor.l.s, .operands={RAB_OPERAND_cpu_fd, RAB_OPERAND_cpu_fs}, .instrType=RABBITIZER_INSTR_TYPE_UNKNOWN, .isFloat=true) // Floating-Point Floor Convert to Long Fixed-Point + +RABBITIZER_DEF_INSTR_ID_ALTNAME(cpu, 0x0C, round_w_s, round.w.s, .operands={RAB_OPERAND_cpu_fd, RAB_OPERAND_cpu_fs}, .instrType=RABBITIZER_INSTR_TYPE_UNKNOWN, .isFloat=true) // Floating-Point Round to Word Fixed-Point +RABBITIZER_DEF_INSTR_ID_ALTNAME(cpu, 0x0D, trunc_w_s, trunc.w.s, .operands={RAB_OPERAND_cpu_fd, RAB_OPERAND_cpu_fs}, .instrType=RABBITIZER_INSTR_TYPE_UNKNOWN, .isFloat=true) // Floating-Point Truncate to Word Fixed-Point +RABBITIZER_DEF_INSTR_ID_ALTNAME(cpu, 0x0E, ceil_w_s, ceil.w.s, .operands={RAB_OPERAND_cpu_fd, RAB_OPERAND_cpu_fs}, .instrType=RABBITIZER_INSTR_TYPE_UNKNOWN, .isFloat=true) // Floating-Point Ceiling Convert to Word Fixed-Point +RABBITIZER_DEF_INSTR_ID_ALTNAME(cpu, 0x0F, floor_w_s, floor.w.s, .operands={RAB_OPERAND_cpu_fd, RAB_OPERAND_cpu_fs}, .instrType=RABBITIZER_INSTR_TYPE_UNKNOWN, .isFloat=true) // Floating-Point Floor Convert to Word Fixed-Point + +// OP fd, fs +RABBITIZER_DEF_INSTR_ID_ALTNAME(cpu, 0x21, cvt_d_s, cvt.d.s, .operands={RAB_OPERAND_cpu_fd, RAB_OPERAND_cpu_fs}, .instrType=RABBITIZER_INSTR_TYPE_UNKNOWN, .isFloat=true, .isDouble=true) +RABBITIZER_DEF_INSTR_ID_ALTNAME(cpu, 0x24, cvt_w_s, cvt.w.s, .operands={RAB_OPERAND_cpu_fd, RAB_OPERAND_cpu_fs}, .instrType=RABBITIZER_INSTR_TYPE_UNKNOWN, .isFloat=true) +RABBITIZER_DEF_INSTR_ID_ALTNAME(cpu, 0x25, cvt_l_s, cvt.l.s, .operands={RAB_OPERAND_cpu_fd, RAB_OPERAND_cpu_fs}, .instrType=RABBITIZER_INSTR_TYPE_UNKNOWN, .isFloat=true) + +// OP fs, ft +RABBITIZER_DEF_INSTR_ID_ALTNAME(cpu, 0x30, c_f_s, c.f.s, .operands={RAB_OPERAND_cpu_fs, RAB_OPERAND_cpu_ft}, .instrType=RABBITIZER_INSTR_TYPE_UNKNOWN, .isFloat=true) +RABBITIZER_DEF_INSTR_ID_ALTNAME(cpu, 0x31, c_un_s, c.un.s, .operands={RAB_OPERAND_cpu_fs, RAB_OPERAND_cpu_ft}, .instrType=RABBITIZER_INSTR_TYPE_UNKNOWN, .isFloat=true) +RABBITIZER_DEF_INSTR_ID_ALTNAME(cpu, 0x32, c_eq_s, c.eq.s, .operands={RAB_OPERAND_cpu_fs, RAB_OPERAND_cpu_ft}, .instrType=RABBITIZER_INSTR_TYPE_UNKNOWN, .isFloat=true) +RABBITIZER_DEF_INSTR_ID_ALTNAME(cpu, 0x33, c_ueq_s, c.ueq.s, .operands={RAB_OPERAND_cpu_fs, RAB_OPERAND_cpu_ft}, .instrType=RABBITIZER_INSTR_TYPE_UNKNOWN, .isFloat=true) +RABBITIZER_DEF_INSTR_ID_ALTNAME(cpu, 0x34, c_olt_s, c.olt.s, .operands={RAB_OPERAND_cpu_fs, RAB_OPERAND_cpu_ft}, .instrType=RABBITIZER_INSTR_TYPE_UNKNOWN, .isFloat=true) +RABBITIZER_DEF_INSTR_ID_ALTNAME(cpu, 0x35, c_ult_s, c.ult.s, .operands={RAB_OPERAND_cpu_fs, RAB_OPERAND_cpu_ft}, .instrType=RABBITIZER_INSTR_TYPE_UNKNOWN, .isFloat=true) +RABBITIZER_DEF_INSTR_ID_ALTNAME(cpu, 0x36, c_ole_s, c.ole.s, .operands={RAB_OPERAND_cpu_fs, RAB_OPERAND_cpu_ft}, .instrType=RABBITIZER_INSTR_TYPE_UNKNOWN, .isFloat=true) +RABBITIZER_DEF_INSTR_ID_ALTNAME(cpu, 0x37, c_ule_s, c.ule.s, .operands={RAB_OPERAND_cpu_fs, RAB_OPERAND_cpu_ft}, .instrType=RABBITIZER_INSTR_TYPE_UNKNOWN, .isFloat=true) + +RABBITIZER_DEF_INSTR_ID_ALTNAME(cpu, 0x38, c_sf_s, c.sf.s, .operands={RAB_OPERAND_cpu_fs, RAB_OPERAND_cpu_ft}, .instrType=RABBITIZER_INSTR_TYPE_UNKNOWN, .isFloat=true) +RABBITIZER_DEF_INSTR_ID_ALTNAME(cpu, 0x39, c_ngle_s, c.ngle.s, .operands={RAB_OPERAND_cpu_fs, RAB_OPERAND_cpu_ft}, .instrType=RABBITIZER_INSTR_TYPE_UNKNOWN, .isFloat=true) +RABBITIZER_DEF_INSTR_ID_ALTNAME(cpu, 0x3A, c_seq_s, c.seq.s, .operands={RAB_OPERAND_cpu_fs, RAB_OPERAND_cpu_ft}, .instrType=RABBITIZER_INSTR_TYPE_UNKNOWN, .isFloat=true) +RABBITIZER_DEF_INSTR_ID_ALTNAME(cpu, 0x3B, c_ngl_s, c.ngl.s, .operands={RAB_OPERAND_cpu_fs, RAB_OPERAND_cpu_ft}, .instrType=RABBITIZER_INSTR_TYPE_UNKNOWN, .isFloat=true) +RABBITIZER_DEF_INSTR_ID_ALTNAME(cpu, 0x3C, c_lt_s, c.lt.s, .operands={RAB_OPERAND_cpu_fs, RAB_OPERAND_cpu_ft}, .instrType=RABBITIZER_INSTR_TYPE_UNKNOWN, .isFloat=true) +RABBITIZER_DEF_INSTR_ID_ALTNAME(cpu, 0x3D, c_nge_s, c.nge.s, .operands={RAB_OPERAND_cpu_fs, RAB_OPERAND_cpu_ft}, .instrType=RABBITIZER_INSTR_TYPE_UNKNOWN, .isFloat=true) +RABBITIZER_DEF_INSTR_ID_ALTNAME(cpu, 0x3E, c_le_s, c.le.s, .operands={RAB_OPERAND_cpu_fs, RAB_OPERAND_cpu_ft}, .instrType=RABBITIZER_INSTR_TYPE_UNKNOWN, .isFloat=true) +RABBITIZER_DEF_INSTR_ID_ALTNAME(cpu, 0x3F, c_ngt_s, c.ngt.s, .operands={RAB_OPERAND_cpu_fs, RAB_OPERAND_cpu_ft}, .instrType=RABBITIZER_INSTR_TYPE_UNKNOWN, .isFloat=true) diff --git a/tools/ido-static-recomp/tools/rabbitizer/include/instructions/instr_id/cpu/cpu_cop1_fpu_w.inc b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/instr_id/cpu/cpu_cop1_fpu_w.inc new file mode 100644 index 00000000..9d07b6dc --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/instr_id/cpu/cpu_cop1_fpu_w.inc @@ -0,0 +1,6 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +// OP fd, fs +RABBITIZER_DEF_INSTR_ID_ALTNAME(cpu, 0x20, cvt_s_w, cvt.s.w, .operands={RAB_OPERAND_cpu_fd, RAB_OPERAND_cpu_fs}, .instrType=RABBITIZER_INSTR_TYPE_UNKNOWN, .isFloat=true) +RABBITIZER_DEF_INSTR_ID_ALTNAME(cpu, 0x21, cvt_d_w, cvt.d.w, .operands={RAB_OPERAND_cpu_fd, RAB_OPERAND_cpu_fs}, .instrType=RABBITIZER_INSTR_TYPE_UNKNOWN, .isFloat=true, .isDouble=true) diff --git a/tools/ido-static-recomp/tools/rabbitizer/include/instructions/instr_id/cpu/cpu_normal.inc b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/instr_id/cpu/cpu_normal.inc new file mode 100644 index 00000000..cc93fa5c --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/instr_id/cpu/cpu_normal.inc @@ -0,0 +1,83 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +// OP LABEL +RABBITIZER_DEF_INSTR_ID(cpu, 0x02, j, .operands={RAB_OPERAND_cpu_label}, .instrType=RABBITIZER_INSTR_TYPE_J, .isJump=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_I) // Jump +RABBITIZER_DEF_INSTR_ID(cpu, 0x03, jal, .operands={RAB_OPERAND_cpu_label}, .instrType=RABBITIZER_INSTR_TYPE_J, .isJump=true, .doesLink=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_I) // Jump And Link + +// OP rs, rt, IMM +RABBITIZER_DEF_INSTR_ID(cpu, 0x04, beq, .operands={RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_rt, RAB_OPERAND_cpu_branch_target_label}, .instrType=RABBITIZER_INSTR_TYPE_I, .isBranch=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_I) // Branch on EQual +RABBITIZER_DEF_INSTR_ID(cpu, 0x05, bne, .operands={RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_rt, RAB_OPERAND_cpu_branch_target_label}, .instrType=RABBITIZER_INSTR_TYPE_I, .isBranch=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_I) // Branch on Not Equal +RABBITIZER_DEF_INSTR_ID(cpu, 0x14, beql, .operands={RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_rt, RAB_OPERAND_cpu_branch_target_label}, .instrType=RABBITIZER_INSTR_TYPE_I, .isBranch=true, .isBranchLikely=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_II) // Branch on EQual Likely +RABBITIZER_DEF_INSTR_ID(cpu, 0x15, bnel, .operands={RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_rt, RAB_OPERAND_cpu_branch_target_label}, .instrType=RABBITIZER_INSTR_TYPE_I, .isBranch=true, .isBranchLikely=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_II) // Branch on Not Equal Likely + +// OP rs, IMM +RABBITIZER_DEF_INSTR_ID(cpu, 0x06, blez, .operands={RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_branch_target_label}, .instrType=RABBITIZER_INSTR_TYPE_I, .isBranch=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_I) // Branch on Less than or Equal to Zero +RABBITIZER_DEF_INSTR_ID(cpu, 0x16, blezl, .operands={RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_branch_target_label}, .instrType=RABBITIZER_INSTR_TYPE_I, .isBranch=true, .isBranchLikely=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_II) // Branch on Less than or Equal to Zero Likely +RABBITIZER_DEF_INSTR_ID(cpu, 0x07, bgtz, .operands={RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_branch_target_label}, .instrType=RABBITIZER_INSTR_TYPE_I, .isBranch=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_I) // Branch on Greater Than Zero +RABBITIZER_DEF_INSTR_ID(cpu, 0x17, bgtzl, .operands={RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_branch_target_label}, .instrType=RABBITIZER_INSTR_TYPE_I, .isBranch=true, .isBranchLikely=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_II) // Branch on Greater Than Zero Likely + +// OP rt, rs, IMM +RABBITIZER_DEF_INSTR_ID(cpu, 0x08, addi, .operands={RAB_OPERAND_cpu_rt, RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_immediate}, .instrType=RABBITIZER_INSTR_TYPE_I, .modifiesRt=true, .notEmitedByCompilers=true, .canBeLo=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_I) // Add Immediate +RABBITIZER_DEF_INSTR_ID(cpu, 0x09, addiu, .operands={RAB_OPERAND_cpu_rt, RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_immediate}, .instrType=RABBITIZER_INSTR_TYPE_I, .modifiesRt=true, .canBeLo=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_I) // Add Immediate Unsigned Word +RABBITIZER_DEF_INSTR_ID(cpu, 0x0A, slti, .operands={RAB_OPERAND_cpu_rt, RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_immediate}, .instrType=RABBITIZER_INSTR_TYPE_I, .modifiesRt=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_I) // Set on Less Than Immediate +RABBITIZER_DEF_INSTR_ID(cpu, 0x0B, sltiu, .operands={RAB_OPERAND_cpu_rt, RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_immediate}, .instrType=RABBITIZER_INSTR_TYPE_I, .modifiesRt=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_I) // Set on Less Than Immediate Unsigned +RABBITIZER_DEF_INSTR_ID(cpu, 0x0C, andi, .operands={RAB_OPERAND_cpu_rt, RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_immediate}, .instrType=RABBITIZER_INSTR_TYPE_I, .isUnsigned=true, .modifiesRt=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_I) // And Immediate +RABBITIZER_DEF_INSTR_ID(cpu, 0x0D, ori, .operands={RAB_OPERAND_cpu_rt, RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_immediate}, .instrType=RABBITIZER_INSTR_TYPE_I, .isUnsigned=true, .modifiesRt=true, .canBeLo=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_I) // Or Immediate +RABBITIZER_DEF_INSTR_ID(cpu, 0x0E, xori, .operands={RAB_OPERAND_cpu_rt, RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_immediate}, .instrType=RABBITIZER_INSTR_TYPE_I, .isUnsigned=true, .modifiesRt=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_I) // eXclusive OR Immediate +RABBITIZER_DEF_INSTR_ID(cpu, 0x18, daddi, .operands={RAB_OPERAND_cpu_rt, RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_immediate}, .instrType=RABBITIZER_INSTR_TYPE_I, .modifiesRt=true, .canBeLo=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_III) // Doubleword add Immediate +RABBITIZER_DEF_INSTR_ID(cpu, 0x19, daddiu, .operands={RAB_OPERAND_cpu_rt, RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_immediate}, .instrType=RABBITIZER_INSTR_TYPE_I, .modifiesRt=true, .canBeLo=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_III) // Doubleword add Immediate Unsigned + +// OP rt, IMM +RABBITIZER_DEF_INSTR_ID(cpu, 0x0F, lui, .operands={RAB_OPERAND_cpu_rt, RAB_OPERAND_cpu_immediate}, .instrType=RABBITIZER_INSTR_TYPE_I, .isUnsigned=true, .modifiesRt=true, .canBeHi=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_I) // Load Upper Immediate + +// OP rt, IMM(base) +RABBITIZER_DEF_INSTR_ID(cpu, 0x1A, ldl, .operands={RAB_OPERAND_cpu_rt, RAB_OPERAND_cpu_immediate_base}, .instrType=RABBITIZER_INSTR_TYPE_I, .modifiesRt=true, .canBeLo=true, .doesDereference=true, .doesLoad=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_III) // Load Doubleword Left +RABBITIZER_DEF_INSTR_ID(cpu, 0x1B, ldr, .operands={RAB_OPERAND_cpu_rt, RAB_OPERAND_cpu_immediate_base}, .instrType=RABBITIZER_INSTR_TYPE_I, .modifiesRt=true, .canBeLo=true, .doesDereference=true, .doesLoad=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_III) // Load Doubleword Right +RABBITIZER_DEF_INSTR_ID(cpu, 0x20, lb, .operands={RAB_OPERAND_cpu_rt, RAB_OPERAND_cpu_immediate_base}, .instrType=RABBITIZER_INSTR_TYPE_I, .modifiesRt=true, .canBeLo=true, .doesDereference=true, .doesLoad=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_I) // Load Byte +RABBITIZER_DEF_INSTR_ID(cpu, 0x21, lh, .operands={RAB_OPERAND_cpu_rt, RAB_OPERAND_cpu_immediate_base}, .instrType=RABBITIZER_INSTR_TYPE_I, .modifiesRt=true, .canBeLo=true, .doesDereference=true, .doesLoad=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_I) // Load Halfword +RABBITIZER_DEF_INSTR_ID(cpu, 0x22, lwl, .operands={RAB_OPERAND_cpu_rt, RAB_OPERAND_cpu_immediate_base}, .instrType=RABBITIZER_INSTR_TYPE_I, .modifiesRt=true, .canBeLo=true, .doesDereference=true, .doesLoad=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_I) // Load Word Left +RABBITIZER_DEF_INSTR_ID(cpu, 0x23, lw, .operands={RAB_OPERAND_cpu_rt, RAB_OPERAND_cpu_immediate_base}, .instrType=RABBITIZER_INSTR_TYPE_I, .modifiesRt=true, .canBeLo=true, .doesDereference=true, .doesLoad=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_I) // Load Word +RABBITIZER_DEF_INSTR_ID(cpu, 0x24, lbu, .operands={RAB_OPERAND_cpu_rt, RAB_OPERAND_cpu_immediate_base}, .instrType=RABBITIZER_INSTR_TYPE_I, .modifiesRt=true, .canBeLo=true, .doesDereference=true, .doesLoad=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_I) // Load Byte Insigned +RABBITIZER_DEF_INSTR_ID(cpu, 0x25, lhu, .operands={RAB_OPERAND_cpu_rt, RAB_OPERAND_cpu_immediate_base}, .instrType=RABBITIZER_INSTR_TYPE_I, .modifiesRt=true, .canBeLo=true, .doesDereference=true, .doesLoad=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_I) // Load Halfword Unsigned +RABBITIZER_DEF_INSTR_ID(cpu, 0x26, lwr, .operands={RAB_OPERAND_cpu_rt, RAB_OPERAND_cpu_immediate_base}, .instrType=RABBITIZER_INSTR_TYPE_I, .modifiesRt=true, .canBeLo=true, .doesDereference=true, .doesLoad=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_I) // Load Word Right +RABBITIZER_DEF_INSTR_ID(cpu, 0x27, lwu, .operands={RAB_OPERAND_cpu_rt, RAB_OPERAND_cpu_immediate_base}, .instrType=RABBITIZER_INSTR_TYPE_I, .modifiesRt=true, .canBeLo=true, .doesDereference=true, .doesLoad=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_III) // Load Word Unsigned +RABBITIZER_DEF_INSTR_ID(cpu, 0x28, sb, .operands={RAB_OPERAND_cpu_rt, RAB_OPERAND_cpu_immediate_base}, .instrType=RABBITIZER_INSTR_TYPE_I, .canBeLo=true, .doesDereference=true, .doesStore=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_I) // Store Byte +RABBITIZER_DEF_INSTR_ID(cpu, 0x29, sh, .operands={RAB_OPERAND_cpu_rt, RAB_OPERAND_cpu_immediate_base}, .instrType=RABBITIZER_INSTR_TYPE_I, .canBeLo=true, .doesDereference=true, .doesStore=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_I) // Store Halfword +RABBITIZER_DEF_INSTR_ID(cpu, 0x2A, swl, .operands={RAB_OPERAND_cpu_rt, RAB_OPERAND_cpu_immediate_base}, .instrType=RABBITIZER_INSTR_TYPE_I, .canBeLo=true, .doesDereference=true, .doesStore=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_I) // Store Word Left +RABBITIZER_DEF_INSTR_ID(cpu, 0x2B, sw, .operands={RAB_OPERAND_cpu_rt, RAB_OPERAND_cpu_immediate_base}, .instrType=RABBITIZER_INSTR_TYPE_I, .canBeLo=true, .doesDereference=true, .doesStore=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_I) // Store Word +RABBITIZER_DEF_INSTR_ID(cpu, 0x2C, sdl, .operands={RAB_OPERAND_cpu_rt, RAB_OPERAND_cpu_immediate_base}, .instrType=RABBITIZER_INSTR_TYPE_I, .canBeLo=true, .doesDereference=true, .doesStore=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_III) // Store Doubleword Left +RABBITIZER_DEF_INSTR_ID(cpu, 0x2D, sdr, .operands={RAB_OPERAND_cpu_rt, RAB_OPERAND_cpu_immediate_base}, .instrType=RABBITIZER_INSTR_TYPE_I, .canBeLo=true, .doesDereference=true, .doesStore=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_III) // Store Doubleword Right +RABBITIZER_DEF_INSTR_ID(cpu, 0x2E, swr, .operands={RAB_OPERAND_cpu_rt, RAB_OPERAND_cpu_immediate_base}, .instrType=RABBITIZER_INSTR_TYPE_I, .canBeLo=true, .doesDereference=true, .doesStore=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_I) // Store Word Right +RABBITIZER_DEF_INSTR_ID(cpu, 0x30, ll, .operands={RAB_OPERAND_cpu_rt, RAB_OPERAND_cpu_immediate_base}, .instrType=RABBITIZER_INSTR_TYPE_I, .modifiesRt=true, .canBeLo=true, .doesDereference=true, .doesLoad=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_II) // Load Linked word +RABBITIZER_DEF_INSTR_ID(cpu, 0x33, pref, .operands={RAB_OPERAND_cpu_rt, RAB_OPERAND_cpu_immediate_base}, .instrType=RABBITIZER_INSTR_TYPE_I, .modifiesRt=true, .canBeLo=true, .doesDereference=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_IV) // Prefetch +RABBITIZER_DEF_INSTR_ID(cpu, 0x34, lld, .operands={RAB_OPERAND_cpu_rt, RAB_OPERAND_cpu_immediate_base}, .instrType=RABBITIZER_INSTR_TYPE_I, .modifiesRt=true, .canBeLo=true, .doesDereference=true, .doesLoad=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_III) // Load Linked Doubleword +RABBITIZER_DEF_INSTR_ID(cpu, 0x37, ld, .operands={RAB_OPERAND_cpu_rt, RAB_OPERAND_cpu_immediate_base}, .instrType=RABBITIZER_INSTR_TYPE_I, .modifiesRt=true, .canBeLo=true, .doesDereference=true, .doesLoad=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_III) // Load Doubleword +RABBITIZER_DEF_INSTR_ID(cpu, 0x38, sc, .operands={RAB_OPERAND_cpu_rt, RAB_OPERAND_cpu_immediate_base}, .instrType=RABBITIZER_INSTR_TYPE_I, .canBeLo=true, .doesDereference=true, .doesStore=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_II) // Store Conditional word +RABBITIZER_DEF_INSTR_ID(cpu, 0x3C, scd, .operands={RAB_OPERAND_cpu_rt, RAB_OPERAND_cpu_immediate_base}, .instrType=RABBITIZER_INSTR_TYPE_I, .canBeLo=true, .doesDereference=true, .doesStore=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_III) // Store Conditional Doubleword +RABBITIZER_DEF_INSTR_ID(cpu, 0x3F, sd, .operands={RAB_OPERAND_cpu_rt, RAB_OPERAND_cpu_immediate_base}, .instrType=RABBITIZER_INSTR_TYPE_I, .canBeLo=true, .doesDereference=true, .doesStore=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_III) // Store Doubleword + +// OP op, IMM(base) +RABBITIZER_DEF_INSTR_ID(cpu, 0x2F, cache, .operands={RAB_OPERAND_cpu_op, RAB_OPERAND_cpu_immediate_base}, .instrType=RABBITIZER_INSTR_TYPE_I, .notEmitedByCompilers=true) // Cache + +// OP ft, IMM(base) +RABBITIZER_DEF_INSTR_ID(cpu, 0x31, lwc1, .operands={RAB_OPERAND_cpu_ft, RAB_OPERAND_cpu_immediate_base}, .instrType=RABBITIZER_INSTR_TYPE_I, .isFloat=true, .canBeLo=true, .doesDereference=true, .doesLoad=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_I) // Load Word to Coprocessor z +RABBITIZER_DEF_INSTR_ID(cpu, 0x35, ldc1, .operands={RAB_OPERAND_cpu_ft, RAB_OPERAND_cpu_immediate_base}, .instrType=RABBITIZER_INSTR_TYPE_I, .isFloat=true, .isDouble=true, .canBeLo=true, .doesDereference=true, .doesLoad=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_II) // Load Doubleword to Coprocessor z +RABBITIZER_DEF_INSTR_ID(cpu, 0x39, swc1, .operands={RAB_OPERAND_cpu_ft, RAB_OPERAND_cpu_immediate_base}, .instrType=RABBITIZER_INSTR_TYPE_I, .isFloat=true, .canBeLo=true, .doesDereference=true, .doesStore=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_I) // Store Word from Coprocessor z +RABBITIZER_DEF_INSTR_ID(cpu, 0x3D, sdc1, .operands={RAB_OPERAND_cpu_ft, RAB_OPERAND_cpu_immediate_base}, .instrType=RABBITIZER_INSTR_TYPE_I, .isFloat=true, .isDouble=true, .canBeLo=true, .doesDereference=true, .doesStore=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_II) // Store Doubleword from Coprocessor z + +// OP cop2t, IMM(base) +RABBITIZER_DEF_INSTR_ID(cpu, 0x32, lwc2, .operands={RAB_OPERAND_cpu_cop2t, RAB_OPERAND_cpu_immediate_base}, .instrType=RABBITIZER_INSTR_TYPE_I, .canBeLo=true, .doesDereference=true, .doesLoad=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_I) // Load Word to Coprocessor z +RABBITIZER_DEF_INSTR_ID(cpu, 0x36, ldc2, .operands={RAB_OPERAND_cpu_cop2t, RAB_OPERAND_cpu_immediate_base}, .instrType=RABBITIZER_INSTR_TYPE_I, .canBeLo=true, .doesDereference=true, .doesLoad=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_II) // Load Doubleword to Coprocessor z +RABBITIZER_DEF_INSTR_ID(cpu, 0x3A, swc2, .operands={RAB_OPERAND_cpu_cop2t, RAB_OPERAND_cpu_immediate_base}, .instrType=RABBITIZER_INSTR_TYPE_I, .canBeLo=true, .doesDereference=true, .doesStore=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_I) // Store Word from Coprocessor z +RABBITIZER_DEF_INSTR_ID(cpu, 0x3E, sdc2, .operands={RAB_OPERAND_cpu_cop2t, RAB_OPERAND_cpu_immediate_base}, .instrType=RABBITIZER_INSTR_TYPE_I, .canBeLo=true, .doesDereference=true, .doesStore=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_II) // Store Doubleword from Coprocessor z + + +// Pseudo-Instruction Unique IDs + +// OP IMM +RABBITIZER_DEF_INSTR_ID(cpu, -0x03, b, .operands={RAB_OPERAND_cpu_branch_target_label}, .instrType=RABBITIZER_INSTR_TYPE_I, .isBranch=true, .isPseudo=true) // Branch (unconditional) + +// OP rs, IMM +RABBITIZER_DEF_INSTR_ID(cpu, -0x04, beqz, .operands={RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_branch_target_label}, .instrType=RABBITIZER_INSTR_TYPE_I, .isBranch=true, .isPseudo=true) // Branch on EQual Zero +RABBITIZER_DEF_INSTR_ID(cpu, -0x05, bnez, .operands={RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_branch_target_label}, .instrType=RABBITIZER_INSTR_TYPE_I, .isBranch=true, .isPseudo=true) // Branch on Not Equal Zero diff --git a/tools/ido-static-recomp/tools/rabbitizer/include/instructions/instr_id/cpu/cpu_regimm.inc b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/instr_id/cpu/cpu_regimm.inc new file mode 100644 index 00000000..4d47123b --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/instr_id/cpu/cpu_regimm.inc @@ -0,0 +1,25 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +// OP rs, IMM +RABBITIZER_DEF_INSTR_ID(cpu, 0x00, bltz, .operands={RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_branch_target_label}, .instrType=RABBITIZER_INSTR_TYPE_REGIMM, .isBranch=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_I) // Branch on Less Than Zero +RABBITIZER_DEF_INSTR_ID(cpu, 0x01, bgez, .operands={RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_branch_target_label}, .instrType=RABBITIZER_INSTR_TYPE_REGIMM, .isBranch=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_I) // Branch on Greater than or Equal to Zero +RABBITIZER_DEF_INSTR_ID(cpu, 0x02, bltzl, .operands={RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_branch_target_label}, .instrType=RABBITIZER_INSTR_TYPE_REGIMM, .isBranch=true, .isBranchLikely=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_II) // Branch on Less Than Zero Likely +RABBITIZER_DEF_INSTR_ID(cpu, 0x03, bgezl, .operands={RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_branch_target_label}, .instrType=RABBITIZER_INSTR_TYPE_REGIMM, .isBranch=true, .isBranchLikely=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_II) // Branch on Greater than or Equal to Zero Likely + +RABBITIZER_DEF_INSTR_ID(cpu, 0x08, tgei, .operands={RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_immediate}, .instrType=RABBITIZER_INSTR_TYPE_REGIMM, .isTrap=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_II) +RABBITIZER_DEF_INSTR_ID(cpu, 0x09, tgeiu, .operands={RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_immediate}, .instrType=RABBITIZER_INSTR_TYPE_REGIMM, .isTrap=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_II) +RABBITIZER_DEF_INSTR_ID(cpu, 0x0A, tlti, .operands={RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_immediate}, .instrType=RABBITIZER_INSTR_TYPE_REGIMM, .isTrap=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_II) +RABBITIZER_DEF_INSTR_ID(cpu, 0x0B, tltiu, .operands={RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_immediate}, .instrType=RABBITIZER_INSTR_TYPE_REGIMM, .isTrap=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_II) +RABBITIZER_DEF_INSTR_ID(cpu, 0x0C, teqi, .operands={RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_immediate}, .instrType=RABBITIZER_INSTR_TYPE_REGIMM, .isTrap=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_II) +RABBITIZER_DEF_INSTR_ID(cpu, 0x0E, tnei, .operands={RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_immediate}, .instrType=RABBITIZER_INSTR_TYPE_REGIMM, .isTrap=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_II) + +RABBITIZER_DEF_INSTR_ID(cpu, 0x10, bltzal, .operands={RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_branch_target_label}, .instrType=RABBITIZER_INSTR_TYPE_REGIMM, .isBranch=true, .doesLink=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_I) // Branch on Less Than Zero and Link +RABBITIZER_DEF_INSTR_ID(cpu, 0x11, bgezal, .operands={RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_branch_target_label}, .instrType=RABBITIZER_INSTR_TYPE_REGIMM, .isBranch=true, .doesLink=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_I) // Branch on Greater Than or Equal to Zero and Link +RABBITIZER_DEF_INSTR_ID(cpu, 0x12, bltzall, .operands={RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_branch_target_label}, .instrType=RABBITIZER_INSTR_TYPE_REGIMM, .isBranch=true, .isBranchLikely=true, .doesLink=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_II) // Branch on Less Than Zero and Link Likely +RABBITIZER_DEF_INSTR_ID(cpu, 0x13, bgezall, .operands={RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_branch_target_label}, .instrType=RABBITIZER_INSTR_TYPE_REGIMM, .isBranch=true, .isBranchLikely=true, .doesLink=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_II) // Branch on Greater Than or Equal to Zero and Link Likely + + +// Pseudo-Instruction Unique IDs + +RABBITIZER_DEF_INSTR_ID(cpu, -0x11, bal, .operands={RAB_OPERAND_cpu_branch_target_label}, .instrType=RABBITIZER_INSTR_TYPE_REGIMM, .isBranch=true, .doesLink=true, .isPseudo=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_I) // Branch and Link diff --git a/tools/ido-static-recomp/tools/rabbitizer/include/instructions/instr_id/cpu/cpu_special.inc b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/instr_id/cpu/cpu_special.inc new file mode 100644 index 00000000..1adb970a --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/instr_id/cpu/cpu_special.inc @@ -0,0 +1,93 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +// OP rd, rt, sa +RABBITIZER_DEF_INSTR_ID(cpu, 0x00, sll, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rt, RAB_OPERAND_cpu_sa}, .instrType=RABBITIZER_INSTR_TYPE_R, .modifiesRd=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_I) // Shift word Left Logical +RABBITIZER_DEF_INSTR_ID(cpu, 0x02, srl, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rt, RAB_OPERAND_cpu_sa}, .instrType=RABBITIZER_INSTR_TYPE_R, .modifiesRd=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_I) // Shift word Right Logical +RABBITIZER_DEF_INSTR_ID(cpu, 0x03, sra, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rt, RAB_OPERAND_cpu_sa}, .instrType=RABBITIZER_INSTR_TYPE_R, .modifiesRd=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_I) // Shift word Right Arithmetic +RABBITIZER_DEF_INSTR_ID(cpu, 0x38, dsll, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rt, RAB_OPERAND_cpu_sa}, .instrType=RABBITIZER_INSTR_TYPE_R, .modifiesRd=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_III) // Doubleword Shift Left Logical +RABBITIZER_DEF_INSTR_ID(cpu, 0x3A, dsrl, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rt, RAB_OPERAND_cpu_sa}, .instrType=RABBITIZER_INSTR_TYPE_R, .modifiesRd=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_III) // Doubleword Shift Right Logical +RABBITIZER_DEF_INSTR_ID(cpu, 0x3B, dsra, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rt, RAB_OPERAND_cpu_sa}, .instrType=RABBITIZER_INSTR_TYPE_R, .modifiesRd=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_III) // Doubleword Shift Right Arithmetic +RABBITIZER_DEF_INSTR_ID(cpu, 0x3C, dsll32, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rt, RAB_OPERAND_cpu_sa}, .instrType=RABBITIZER_INSTR_TYPE_R, .modifiesRd=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_III) // Doubleword Shift Left Logical plus 32 +RABBITIZER_DEF_INSTR_ID(cpu, 0x3E, dsrl32, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rt, RAB_OPERAND_cpu_sa}, .instrType=RABBITIZER_INSTR_TYPE_R, .modifiesRd=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_III) // Doubleword Shift Right Logical plus 32 +RABBITIZER_DEF_INSTR_ID(cpu, 0x3F, dsra32, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rt, RAB_OPERAND_cpu_sa}, .instrType=RABBITIZER_INSTR_TYPE_R, .modifiesRd=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_III) // Doubleword Shift Right Arithmetic plus 32 + +// OP rd, rt, rs +RABBITIZER_DEF_INSTR_ID(cpu, 0x14, dsllv, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rt, RAB_OPERAND_cpu_rs}, .instrType=RABBITIZER_INSTR_TYPE_R, .modifiesRd=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_III) // Doubleword Shift Left Logical Variable +RABBITIZER_DEF_INSTR_ID(cpu, 0x16, dsrlv, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rt, RAB_OPERAND_cpu_rs}, .instrType=RABBITIZER_INSTR_TYPE_R, .modifiesRd=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_III) // Doubleword Shift Right Logical Variable +RABBITIZER_DEF_INSTR_ID(cpu, 0x17, dsrav, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rt, RAB_OPERAND_cpu_rs}, .instrType=RABBITIZER_INSTR_TYPE_R, .modifiesRd=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_III) // Doubleword Shift Right Arithmetic Variable +RABBITIZER_DEF_INSTR_ID(cpu, 0x04, sllv, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rt, RAB_OPERAND_cpu_rs}, .instrType=RABBITIZER_INSTR_TYPE_R, .modifiesRd=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_I) // Shift word Left Logical Variable +RABBITIZER_DEF_INSTR_ID(cpu, 0x06, srlv, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rt, RAB_OPERAND_cpu_rs}, .instrType=RABBITIZER_INSTR_TYPE_R, .modifiesRd=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_I) // Shift word Right Logical Variable +RABBITIZER_DEF_INSTR_ID(cpu, 0x07, srav, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rt, RAB_OPERAND_cpu_rs}, .instrType=RABBITIZER_INSTR_TYPE_R, .modifiesRd=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_I) // Shift word Right Arithmetic Variable + +// OP rs +RABBITIZER_DEF_INSTR_ID(cpu, 0x11, mthi, .operands={RAB_OPERAND_cpu_rs}, .instrType=RABBITIZER_INSTR_TYPE_R, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_I) // Move To HI register +RABBITIZER_DEF_INSTR_ID(cpu, 0x13, mtlo, .operands={RAB_OPERAND_cpu_rs}, .instrType=RABBITIZER_INSTR_TYPE_R, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_I) // Move To LO register +RABBITIZER_DEF_INSTR_ID(cpu, 0x08, jr, .operands={RAB_OPERAND_cpu_rs}, .instrType=RABBITIZER_INSTR_TYPE_R, .isJump=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_I) // Jump Register +RABBITIZER_DEF_INSTR_ID(cpu, 0x09, jalr, .operands={RAB_OPERAND_cpu_rs}, .instrType=RABBITIZER_INSTR_TYPE_R, .isJump=true, .modifiesRd=true, .doesLink=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_I) // Jump And Link Register + +// OP rd, rs +RABBITIZER_DEF_INSTR_ID_ALTNAME(cpu, -0x09, jalr_rd, jalr, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rs}, .instrType=RABBITIZER_INSTR_TYPE_R, .isJump=true, .modifiesRd=true, .doesLink=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_I) // Jump And Link Register // Special case for rd != 31 + +// OP rd +RABBITIZER_DEF_INSTR_ID(cpu, 0x10, mfhi, .operands={RAB_OPERAND_cpu_rd}, .instrType=RABBITIZER_INSTR_TYPE_R, .modifiesRd=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_I) // Move From HI register +RABBITIZER_DEF_INSTR_ID(cpu, 0x12, mflo, .operands={RAB_OPERAND_cpu_rd}, .instrType=RABBITIZER_INSTR_TYPE_R, .modifiesRd=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_I) // Move From LO register + +// OP rd, rs, rt +RABBITIZER_DEF_INSTR_ID(cpu, 0x0A, movz, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_rt}, .instrType=RABBITIZER_INSTR_TYPE_R, .modifiesRd=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_IV) // MOVe conditional on Zero +RABBITIZER_DEF_INSTR_ID(cpu, 0x0B, movn, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_rt}, .instrType=RABBITIZER_INSTR_TYPE_R, .modifiesRd=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_IV) // MOVe conditional on Not zero +RABBITIZER_DEF_INSTR_ID(cpu, 0x1A, div, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_rt}, .instrType=RABBITIZER_INSTR_TYPE_R, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_I) // DIVide word +RABBITIZER_DEF_INSTR_ID(cpu, 0x1B, divu, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_rt}, .instrType=RABBITIZER_INSTR_TYPE_R, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_I) // DIVide Unsigned word + +RABBITIZER_DEF_INSTR_ID_ALTNAME(cpu, -0x1A, sn64_div, div, .operands={RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_rt}, .instrType=RABBITIZER_INSTR_TYPE_R, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_I) // DIVide word +RABBITIZER_DEF_INSTR_ID_ALTNAME(cpu, -0x1B, sn64_divu, divu, .operands={RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_rt}, .instrType=RABBITIZER_INSTR_TYPE_R, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_I) // DIVide Unsigned word + +RABBITIZER_DEF_INSTR_ID(cpu, 0x1E, ddiv, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_rt}, .instrType=RABBITIZER_INSTR_TYPE_R, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_III) // Doubleword DIVide +RABBITIZER_DEF_INSTR_ID(cpu, 0x1F, ddivu, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_rt}, .instrType=RABBITIZER_INSTR_TYPE_R, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_III) // Doubleword DIVide Unsigned +// RABBITIZER_DEF_INSTR_ID(cpu, , ddiv, .operands={RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_rt}, .instrType=RABBITIZER_INSTR_TYPE_R, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_III) +// RABBITIZER_DEF_INSTR_ID(cpu, , ddivu, .operands={RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_rt}, .instrType=RABBITIZER_INSTR_TYPE_R, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_III) +RABBITIZER_DEF_INSTR_ID(cpu, 0x20, add, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_rt}, .instrType=RABBITIZER_INSTR_TYPE_R, .modifiesRd=true, .notEmitedByCompilers=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_I) // ADD word +RABBITIZER_DEF_INSTR_ID(cpu, 0x21, addu, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_rt}, .instrType=RABBITIZER_INSTR_TYPE_R, .modifiesRd=true, .maybeIsMove=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_I) // ADD Unsigned word +RABBITIZER_DEF_INSTR_ID(cpu, 0x22, sub, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_rt}, .instrType=RABBITIZER_INSTR_TYPE_R, .modifiesRd=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_I) // Subtract word +RABBITIZER_DEF_INSTR_ID(cpu, 0x23, subu, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_rt}, .instrType=RABBITIZER_INSTR_TYPE_R, .modifiesRd=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_I) // SUBtract Unsigned word +RABBITIZER_DEF_INSTR_ID(cpu, 0x24, and, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_rt}, .instrType=RABBITIZER_INSTR_TYPE_R, .modifiesRd=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_I) // AND +RABBITIZER_DEF_INSTR_ID(cpu, 0x25, or, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_rt}, .instrType=RABBITIZER_INSTR_TYPE_R, .modifiesRd=true, .maybeIsMove=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_I) // OR +RABBITIZER_DEF_INSTR_ID(cpu, 0x26, xor, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_rt}, .instrType=RABBITIZER_INSTR_TYPE_R, .modifiesRd=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_I) // eXclusive OR +RABBITIZER_DEF_INSTR_ID(cpu, 0x27, nor, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_rt}, .instrType=RABBITIZER_INSTR_TYPE_R, .modifiesRd=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_I) // Not OR +RABBITIZER_DEF_INSTR_ID(cpu, 0x2A, slt, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_rt}, .instrType=RABBITIZER_INSTR_TYPE_R, .modifiesRd=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_I) // Set on Less Than +RABBITIZER_DEF_INSTR_ID(cpu, 0x2B, sltu, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_rt}, .instrType=RABBITIZER_INSTR_TYPE_R, .modifiesRd=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_I) // Set on Less Than Unsigned +RABBITIZER_DEF_INSTR_ID(cpu, 0x2C, dadd, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_rt}, .instrType=RABBITIZER_INSTR_TYPE_R, .modifiesRd=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_III) // Doubleword Add +RABBITIZER_DEF_INSTR_ID(cpu, 0x2D, daddu, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_rt}, .instrType=RABBITIZER_INSTR_TYPE_R, .modifiesRd=true, .maybeIsMove=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_III) // Doubleword Add Unsigned +RABBITIZER_DEF_INSTR_ID(cpu, 0x2E, dsub, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_rt}, .instrType=RABBITIZER_INSTR_TYPE_R, .modifiesRd=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_III) // Doubleword SUBtract +RABBITIZER_DEF_INSTR_ID(cpu, 0x2F, dsubu, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_rt}, .instrType=RABBITIZER_INSTR_TYPE_R, .modifiesRd=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_III) // Doubleword SUBtract Unsigned + +// OP code +RABBITIZER_DEF_INSTR_ID(cpu, 0x0C, syscall, .operands={RAB_OPERAND_cpu_code}, .instrType=RABBITIZER_INSTR_TYPE_R, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_I) // SYStem CALL +RABBITIZER_DEF_INSTR_ID(cpu, 0x0D, break, .operands={RAB_OPERAND_cpu_code}, .instrType=RABBITIZER_INSTR_TYPE_R, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_I) // Break +RABBITIZER_DEF_INSTR_ID(cpu, 0x0F, sync, .operands={0}, .instrType=RABBITIZER_INSTR_TYPE_R, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_II) // Sync + +// OP rs, rt +RABBITIZER_DEF_INSTR_ID(cpu, 0x18, mult, .operands={RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_rt}, .instrType=RABBITIZER_INSTR_TYPE_R, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_I) // MULTtiply word +RABBITIZER_DEF_INSTR_ID(cpu, 0x19, multu, .operands={RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_rt}, .instrType=RABBITIZER_INSTR_TYPE_R, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_I) // MULTtiply Unsigned word +RABBITIZER_DEF_INSTR_ID(cpu, 0x1C, dmult, .operands={RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_rt}, .instrType=RABBITIZER_INSTR_TYPE_R, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_III) // Doubleword MULTiply +RABBITIZER_DEF_INSTR_ID(cpu, 0x1D, dmultu, .operands={RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_rt}, .instrType=RABBITIZER_INSTR_TYPE_R, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_III) // Doubleword MULTiply Unsigned + +RABBITIZER_DEF_INSTR_ID(cpu, 0x30, tge, .operands={RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_rt, RAB_OPERAND_cpu_code_lower}, .instrType=RABBITIZER_INSTR_TYPE_R, .isTrap=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_II) // Trap if Greater or Equal +RABBITIZER_DEF_INSTR_ID(cpu, 0x31, tgeu, .operands={RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_rt, RAB_OPERAND_cpu_code_lower}, .instrType=RABBITIZER_INSTR_TYPE_R, .isTrap=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_II) // Trap if Greater or Equal Unsigned +RABBITIZER_DEF_INSTR_ID(cpu, 0x32, tlt, .operands={RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_rt, RAB_OPERAND_cpu_code_lower}, .instrType=RABBITIZER_INSTR_TYPE_R, .isTrap=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_II) // Trap if Less Than +RABBITIZER_DEF_INSTR_ID(cpu, 0x33, tltu, .operands={RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_rt, RAB_OPERAND_cpu_code_lower}, .instrType=RABBITIZER_INSTR_TYPE_R, .isTrap=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_II) // Trap if Less Than Unsigned +RABBITIZER_DEF_INSTR_ID(cpu, 0x34, teq, .operands={RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_rt, RAB_OPERAND_cpu_code_lower}, .instrType=RABBITIZER_INSTR_TYPE_R, .isTrap=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_II) // Trap if EQual +RABBITIZER_DEF_INSTR_ID(cpu, 0x36, tne, .operands={RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_rt, RAB_OPERAND_cpu_code_lower}, .instrType=RABBITIZER_INSTR_TYPE_R, .isTrap=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_II) // Trap if Not Equal + + +// Pseudo-Instruction Unique IDs + +// OP +RABBITIZER_DEF_INSTR_ID(cpu, -0x01, nop, .operands={0}, .instrType=RABBITIZER_INSTR_TYPE_R, .isPseudo=true) // No OPeration + +// OP rd, rs +RABBITIZER_DEF_INSTR_ID(cpu, -0x25, move, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rs}, .instrType=RABBITIZER_INSTR_TYPE_R, .modifiesRd=true, .maybeIsMove=true, .isPseudo=true) // Move +RABBITIZER_DEF_INSTR_ID(cpu, -0x27, not, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rs}, .instrType=RABBITIZER_INSTR_TYPE_R, .modifiesRd=true, .isPseudo=true) // Not + +// OP rd, rt +RABBITIZER_DEF_INSTR_ID(cpu, -0x23, negu, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rt}, .instrType=RABBITIZER_INSTR_TYPE_R, .modifiesRd=true, .isPseudo=true) diff --git a/tools/ido-static-recomp/tools/rabbitizer/include/instructions/instr_id/r5900/r5900_cop0_tlb.inc b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/instr_id/r5900/r5900_cop0_tlb.inc new file mode 100644 index 00000000..5173361a --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/instr_id/r5900/r5900_cop0_tlb.inc @@ -0,0 +1,23 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +/* + 31--------26-25------21--------------------------------5--------0 + | = COP0 | TLB | | fmt | + ------6----------5----------------------------------------------- + |--000--|--001--|--010--|--011--|--100--|--101--|--110--|--111--| lo +000 | --- | TLBR | TLBWI | --- | --- | --- | TLBWR | --- | +001 | TLBP | --- | --- | --- | --- | --- | --- | --- | +010 | --- | --- | --- | --- | --- | --- | --- | --- | +011 | ERET | --- | --- | --- | --- | --- | --- | --- | +100 | --- | --- | --- | --- | --- | --- | --- | --- | +101 | --- | --- | --- | --- | --- | --- | --- | --- | +110 | --- | --- | --- | --- | --- | --- | --- | --- | +111 | EI | DI | --- | --- | --- | --- | --- | --- | + hi |-------|-------|-------|-------|-------|-------|-------|-------| +*/ + +// The other instructions are implemented using the main CPU table + +RABBITIZER_DEF_INSTR_ID(r5900, 0x38, ei, .operands={0}) +RABBITIZER_DEF_INSTR_ID(r5900, 0x39, di, .operands={0}) diff --git a/tools/ido-static-recomp/tools/rabbitizer/include/instructions/instr_id/r5900/r5900_cop1_fpu_s.inc b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/instr_id/r5900/r5900_cop1_fpu_s.inc new file mode 100644 index 00000000..730e7e91 --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/instr_id/r5900/r5900_cop1_fpu_s.inc @@ -0,0 +1,46 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +/* + 31--------26-25------21 -------------------------------5--------0 + | = COP1 | = S | | function| + ------6----------5-----------------------------------------6----- + |--000--|--001--|--010--|--011--|--100--|--101--|--110--|--111--| lo +000 | ADD.S | SUB.S | MUL.S | DIV.S | SQRT.S| ABS.S | MOV.S | NEG.S | +001 | --- | --- | --- | --- | --- | --- | --- | --- | +010 | --- | --- | --- | --- | --- | --- |RSQRT.S| --- | +011 | ADDA.S| SUBA.S| MULA.S| --- | MADD.S| MSUB.S|MADDA.S|MSUBA.S| +100 | --- | --- | --- | --- | CVT.W | --- | --- | --- | +101 | MAX.S | MIN.S | --- | --- | --- | --- | --- | --- | +110 | C.F | --- | C.EQ | --- | C.LT | --- | C.LE | --- | +111 | --- | --- | --- | --- | --- | --- | --- | --- | + hi |-------|-------|-------|-------|-------|-------|-------|-------| +*/ + +// The other instructions are implemented using the main CPU table + +RABBITIZER_DEF_INSTR_ID_ALTNAME(r5900, 0x04, c1__sqrt_s, c1, .operands={RAB_OPERAND_cpu_copraw}) + +RABBITIZER_DEF_INSTR_ID_ALTNAME(r5900, 0x16, rsqrt_s, rsqrt.s, .operands={RAB_OPERAND_cpu_fd, RAB_OPERAND_cpu_fs, RAB_OPERAND_cpu_ft}, .isFloat=true) // floating point Reciprocal SQuare RooT + +RABBITIZER_DEF_INSTR_ID_ALTNAME(r5900, 0x18, adda_s, adda.s, .operands={RAB_OPERAND_cpu_fs, RAB_OPERAND_cpu_ft}, .isFloat=true) // floating point ADD to Accumulator +RABBITIZER_DEF_INSTR_ID_ALTNAME(r5900, 0x19, suba_s, suba.s, .operands={RAB_OPERAND_cpu_fs, RAB_OPERAND_cpu_ft}, .isFloat=true) // floating point SUBtract to Accumulator +RABBITIZER_DEF_INSTR_ID_ALTNAME(r5900, 0x1A, mula_s, mula.s, .operands={RAB_OPERAND_cpu_fs, RAB_OPERAND_cpu_ft}, .isFloat=true) // floating point MULtiply to Accumulator + +RABBITIZER_DEF_INSTR_ID_ALTNAME(r5900, 0x1C, madd_s, madd.s, .operands={RAB_OPERAND_cpu_fd, RAB_OPERAND_cpu_fs, RAB_OPERAND_cpu_ft}, .isFloat=true) // floating point Multiply-ADD +RABBITIZER_DEF_INSTR_ID_ALTNAME(r5900, 0x1D, msub_s, msub.s, .operands={RAB_OPERAND_cpu_fd, RAB_OPERAND_cpu_fs, RAB_OPERAND_cpu_ft}, .isFloat=true) // floating point Multiply abd SUBtract +RABBITIZER_DEF_INSTR_ID_ALTNAME(r5900, 0x1E, madda_s, madda.s, .operands={RAB_OPERAND_cpu_fs, RAB_OPERAND_cpu_ft}, .isFloat=true) // floating point Multiply-ADD Accumulator +RABBITIZER_DEF_INSTR_ID_ALTNAME(r5900, 0x1F, msuba_s, msuba.s, .operands={RAB_OPERAND_cpu_fs, RAB_OPERAND_cpu_ft}, .isFloat=true) // floating point Multiply SUBtract from Accumulator + +RABBITIZER_DEF_INSTR_ID_ALTNAME(r5900, 0x28, max_s, max.s, .operands={RAB_OPERAND_cpu_fd, RAB_OPERAND_cpu_fs, RAB_OPERAND_cpu_ft}, .isFloat=true) // floating point MAXimum +RABBITIZER_DEF_INSTR_ID_ALTNAME(r5900, 0x29, min_s, min.s, .operands={RAB_OPERAND_cpu_fd, RAB_OPERAND_cpu_fs, RAB_OPERAND_cpu_ft}, .isFloat=true) // floating point MINimum + +// Due to the R5900's FPU being non properly complaint the instruction cvt.w.s always behaves as trunc.w.s because is because EE can only do round-to-zero. +// Assemblers like GAS workaround this issue by decoding cvt.w.s as trunc.w.s, so we mimic that behaviour to allow assembling with GAS. +// Here's some reading about the binutils rationale: +// https://sourceware.org/legacy-ml/binutils/2012-11/msg00360.html +// https://sourceware.org/pipermail/binutils/2013-January/079863.html +RABBITIZER_DEF_INSTR_ID_ALTNAME(r5900, 0x24, trunc_w_s, trunc.w.s, .operands={RAB_OPERAND_cpu_fd, RAB_OPERAND_cpu_fs}, .isFloat=true) // Floating-Point Truncate to Word Fixed-Point + +RABBITIZER_DEF_INSTR_ID_ALTNAME(r5900, 0x34, c_lt_s, c.lt.s, .operands={RAB_OPERAND_cpu_fs, RAB_OPERAND_cpu_ft}, .isFloat=true) +RABBITIZER_DEF_INSTR_ID_ALTNAME(r5900, 0x36, c_le_s, c.le.s, .operands={RAB_OPERAND_cpu_fs, RAB_OPERAND_cpu_ft}, .isFloat=true) diff --git a/tools/ido-static-recomp/tools/rabbitizer/include/instructions/instr_id/r5900/r5900_cop2.inc b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/instr_id/r5900/r5900_cop2.inc new file mode 100644 index 00000000..fae81904 --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/instr_id/r5900/r5900_cop2.inc @@ -0,0 +1,21 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +/* + 31--------26-25------21 ----------------------------------------0 + | = COP2 | fmt | | + ------6----------5----------------------------------------------- + |--000--|--001--|--010--|--011--|--100--|--101--|--110--|--111--| lo + 00 | --- | QMFC2 | CFC2 | --- | --- | QMTC2 | CTC2 | --- | + 01 | *1 | --- | --- | --- | --- | --- | --- | --- | + 10 | *2 | *2 | *2 | *2 | *2 | *2 | *2 | *2 | + 11 | *2 | *2 | *2 | *2 | *2 | *2 | *2 | *2 | + hi |-------|-------|-------|-------|-------|-------|-------|-------| + *1 = BC instructions, see BC2 list *2 =see special1 table +*/ + +// TODO: properties +RABBITIZER_DEF_INSTR_ID(r5900, 0x01, qmfc2, .operands={RAB_OPERAND_cpu_rt, RAB_OPERAND_r5900_vfs}) +RABBITIZER_DEF_INSTR_ID(r5900, 0x02, cfc2, .operands={RAB_OPERAND_cpu_rt, RAB_OPERAND_r5900_vis}) +RABBITIZER_DEF_INSTR_ID(r5900, 0x05, qmtc2, .operands={RAB_OPERAND_cpu_rt, RAB_OPERAND_r5900_vfs}) +RABBITIZER_DEF_INSTR_ID(r5900, 0x06, ctc2, .operands={RAB_OPERAND_cpu_rt, RAB_OPERAND_r5900_vis}) diff --git a/tools/ido-static-recomp/tools/rabbitizer/include/instructions/instr_id/r5900/r5900_cop2_bc2.inc b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/instr_id/r5900/r5900_cop2_bc2.inc new file mode 100644 index 00000000..734e0d4f --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/instr_id/r5900/r5900_cop2_bc2.inc @@ -0,0 +1,21 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +/* + 31--------26-25------21-20------16------------------------------0 + | = COP0 | BC2 | fmt | | + ------6----------5----------5------------------------------------ + |--000--|--001--|--010--|--011--|--100--|--101--|--110--|--111--| lo + 00 | BC2F | BC2T | BC2FL | BC2TL | --- | --- | --- | --- | + 01 | --- | --- | --- | --- | --- | --- | --- | --- | + 10 | --- | --- | --- | --- | --- | --- | --- | --- | + 11 | --- | --- | --- | --- | --- | --- | --- | --- | + hi |-------|-------|-------|-------|-------|-------|-------|-------| +*/ + +// TODO: operands and properties + +RABBITIZER_DEF_INSTR_ID(r5900, 0x00, bc2f, .operands={RAB_OPERAND_cpu_branch_target_label}, .isBranch=true) +RABBITIZER_DEF_INSTR_ID(r5900, 0x01, bc2t, .operands={RAB_OPERAND_cpu_branch_target_label}, .isBranch=true) +RABBITIZER_DEF_INSTR_ID(r5900, 0x02, bc2fl, .operands={RAB_OPERAND_cpu_branch_target_label}, .isBranch=true, .isBranchLikely=true) +RABBITIZER_DEF_INSTR_ID(r5900, 0x03, bc2tl, .operands={RAB_OPERAND_cpu_branch_target_label}, .isBranch=true, .isBranchLikely=true) diff --git a/tools/ido-static-recomp/tools/rabbitizer/include/instructions/instr_id/r5900/r5900_cop2_special1.inc b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/instr_id/r5900/r5900_cop2_special1.inc new file mode 100644 index 00000000..043c911f --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/instr_id/r5900/r5900_cop2_special1.inc @@ -0,0 +1,82 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +/* + 31---------26-25-----21-20-----------------------------5--------0 + | =COP2 | Special1 | |function| + ------6----------5------------------------------------------6---- + |--000--|--001--|--010--|--011--|--100--|--101--|--110--|--111--| lo +000 |VADDx |VADDy |VADDz |VADDw |VSUBx |VSUBy |VSUBz |VSUBw | +001 |VMADDx |VMADDy |VMADDz |VMADDw |VMSUBx |VMSUBy |VMSUBz |VMSUBw | +010 |VMAXx |VMAXy |VMAXz |VMAXw |VMINIx |VMINIy |VMINIz |VMINIw | +011 |VMULx |VMULy |VMULz |VMULw |VMULq |VMAXi |VMULi |VMINIi | +100 |VADDq |VMADDq |VADDi |VMADDi |VSUBq |VMSUBq |VSUbi |VMSUBi | +101 |VADD |VMADD |VMUL |VMAX |VSUB |VMSUB |VOPMSUB|VMINI | +110 |VIADD |VISUB |VIADDI | --- |VIAND |VIOR | --- | --- | +111 |VCALLMS|VCALLMSR| --- | --- | *1 | *1 | *1 | *1 | + hi |-------|-------|-------|-------|-------|-------|-------|-------| + *1=see special2 table +*/ + +// TODO: properties + +RABBITIZER_DEF_INSTR_ID(r5900, 0x00, vaddx, .operands={RAB_OPERAND_r5900_vfdxyzw, RAB_OPERAND_r5900_vfsxyzw, RAB_OPERAND_r5900_vftn}, .instrSuffix=RABINSTRSUFFIX_R5900_xyzw, .isFloat=true) // ADD broadcast +RABBITIZER_DEF_INSTR_ID(r5900, 0x01, vaddy, .operands={RAB_OPERAND_r5900_vfdxyzw, RAB_OPERAND_r5900_vfsxyzw, RAB_OPERAND_r5900_vftn}, .instrSuffix=RABINSTRSUFFIX_R5900_xyzw, .isFloat=true) // ADD broadcast +RABBITIZER_DEF_INSTR_ID(r5900, 0x02, vaddz, .operands={RAB_OPERAND_r5900_vfdxyzw, RAB_OPERAND_r5900_vfsxyzw, RAB_OPERAND_r5900_vftn}, .instrSuffix=RABINSTRSUFFIX_R5900_xyzw, .isFloat=true) // ADD broadcast +RABBITIZER_DEF_INSTR_ID(r5900, 0x03, vaddw, .operands={RAB_OPERAND_r5900_vfdxyzw, RAB_OPERAND_r5900_vfsxyzw, RAB_OPERAND_r5900_vftn}, .instrSuffix=RABINSTRSUFFIX_R5900_xyzw, .isFloat=true) // ADD broadcast +RABBITIZER_DEF_INSTR_ID(r5900, 0x04, vsubx, .operands={RAB_OPERAND_r5900_vfdxyzw, RAB_OPERAND_r5900_vfsxyzw, RAB_OPERAND_r5900_vftn}, .instrSuffix=RABINSTRSUFFIX_R5900_xyzw, .isFloat=true) // SUBtract broadcast +RABBITIZER_DEF_INSTR_ID(r5900, 0x05, vsuby, .operands={RAB_OPERAND_r5900_vfdxyzw, RAB_OPERAND_r5900_vfsxyzw, RAB_OPERAND_r5900_vftn}, .instrSuffix=RABINSTRSUFFIX_R5900_xyzw, .isFloat=true) // SUBtract broadcast +RABBITIZER_DEF_INSTR_ID(r5900, 0x06, vsubz, .operands={RAB_OPERAND_r5900_vfdxyzw, RAB_OPERAND_r5900_vfsxyzw, RAB_OPERAND_r5900_vftn}, .instrSuffix=RABINSTRSUFFIX_R5900_xyzw, .isFloat=true) // SUBtract broadcast +RABBITIZER_DEF_INSTR_ID(r5900, 0x07, vsubw, .operands={RAB_OPERAND_r5900_vfdxyzw, RAB_OPERAND_r5900_vfsxyzw, RAB_OPERAND_r5900_vftn}, .instrSuffix=RABINSTRSUFFIX_R5900_xyzw, .isFloat=true) // SUBtract broadcast +RABBITIZER_DEF_INSTR_ID(r5900, 0x08, vmaddx, .operands={RAB_OPERAND_r5900_vfdxyzw, RAB_OPERAND_r5900_vfsxyzw, RAB_OPERAND_r5900_vftn}, .instrSuffix=RABINSTRSUFFIX_R5900_xyzw, .isFloat=true) // Multiply-ADD broadcast +RABBITIZER_DEF_INSTR_ID(r5900, 0x09, vmaddy, .operands={RAB_OPERAND_r5900_vfdxyzw, RAB_OPERAND_r5900_vfsxyzw, RAB_OPERAND_r5900_vftn}, .instrSuffix=RABINSTRSUFFIX_R5900_xyzw, .isFloat=true) // Multiply-ADD broadcast +RABBITIZER_DEF_INSTR_ID(r5900, 0x0A, vmaddz, .operands={RAB_OPERAND_r5900_vfdxyzw, RAB_OPERAND_r5900_vfsxyzw, RAB_OPERAND_r5900_vftn}, .instrSuffix=RABINSTRSUFFIX_R5900_xyzw, .isFloat=true) // Multiply-ADD broadcast +RABBITIZER_DEF_INSTR_ID(r5900, 0x0B, vmaddw, .operands={RAB_OPERAND_r5900_vfdxyzw, RAB_OPERAND_r5900_vfsxyzw, RAB_OPERAND_r5900_vftn}, .instrSuffix=RABINSTRSUFFIX_R5900_xyzw, .isFloat=true) // Multiply-ADD broadcast +RABBITIZER_DEF_INSTR_ID(r5900, 0x0C, vmsubx, .operands={RAB_OPERAND_r5900_vfdxyzw, RAB_OPERAND_r5900_vfsxyzw, RAB_OPERAND_r5900_vftn}, .instrSuffix=RABINSTRSUFFIX_R5900_xyzw, .isFloat=true) // Multiply-SUBtract broadcast +RABBITIZER_DEF_INSTR_ID(r5900, 0x0D, vmsuby, .operands={RAB_OPERAND_r5900_vfdxyzw, RAB_OPERAND_r5900_vfsxyzw, RAB_OPERAND_r5900_vftn}, .instrSuffix=RABINSTRSUFFIX_R5900_xyzw, .isFloat=true) // Multiply-SUBtract broadcast +RABBITIZER_DEF_INSTR_ID(r5900, 0x0E, vmsubz, .operands={RAB_OPERAND_r5900_vfdxyzw, RAB_OPERAND_r5900_vfsxyzw, RAB_OPERAND_r5900_vftn}, .instrSuffix=RABINSTRSUFFIX_R5900_xyzw, .isFloat=true) // Multiply-SUBtract broadcast +RABBITIZER_DEF_INSTR_ID(r5900, 0x0F, vmsubw, .operands={RAB_OPERAND_r5900_vfdxyzw, RAB_OPERAND_r5900_vfsxyzw, RAB_OPERAND_r5900_vftn}, .instrSuffix=RABINSTRSUFFIX_R5900_xyzw, .isFloat=true) // Multiply-SUBtract broadcast + +RABBITIZER_DEF_INSTR_ID(r5900, 0x10, vmaxx, .operands={RAB_OPERAND_r5900_vfdxyzw, RAB_OPERAND_r5900_vfsxyzw, RAB_OPERAND_r5900_vftn}, .instrSuffix=RABINSTRSUFFIX_R5900_xyzw, .isFloat=true) // MAXimum broadcast +RABBITIZER_DEF_INSTR_ID(r5900, 0x11, vmaxy, .operands={RAB_OPERAND_r5900_vfdxyzw, RAB_OPERAND_r5900_vfsxyzw, RAB_OPERAND_r5900_vftn}, .instrSuffix=RABINSTRSUFFIX_R5900_xyzw, .isFloat=true) // MAXimum broadcast +RABBITIZER_DEF_INSTR_ID(r5900, 0x12, vmaxz, .operands={RAB_OPERAND_r5900_vfdxyzw, RAB_OPERAND_r5900_vfsxyzw, RAB_OPERAND_r5900_vftn}, .instrSuffix=RABINSTRSUFFIX_R5900_xyzw, .isFloat=true) // MAXimum broadcast +RABBITIZER_DEF_INSTR_ID(r5900, 0x13, vmaxw, .operands={RAB_OPERAND_r5900_vfdxyzw, RAB_OPERAND_r5900_vfsxyzw, RAB_OPERAND_r5900_vftn}, .instrSuffix=RABINSTRSUFFIX_R5900_xyzw, .isFloat=true) // MAXimum broadcast +RABBITIZER_DEF_INSTR_ID(r5900, 0x14, vminix, .operands={RAB_OPERAND_r5900_vfdxyzw, RAB_OPERAND_r5900_vfsxyzw, RAB_OPERAND_r5900_vftn}, .instrSuffix=RABINSTRSUFFIX_R5900_xyzw, .isFloat=true) // MINimum broadcast +RABBITIZER_DEF_INSTR_ID(r5900, 0x15, vminiy, .operands={RAB_OPERAND_r5900_vfdxyzw, RAB_OPERAND_r5900_vfsxyzw, RAB_OPERAND_r5900_vftn}, .instrSuffix=RABINSTRSUFFIX_R5900_xyzw, .isFloat=true) // MINimum broadcast +RABBITIZER_DEF_INSTR_ID(r5900, 0x16, vminiz, .operands={RAB_OPERAND_r5900_vfdxyzw, RAB_OPERAND_r5900_vfsxyzw, RAB_OPERAND_r5900_vftn}, .instrSuffix=RABINSTRSUFFIX_R5900_xyzw, .isFloat=true) // MINimum broadcast +RABBITIZER_DEF_INSTR_ID(r5900, 0x17, vminiw, .operands={RAB_OPERAND_r5900_vfdxyzw, RAB_OPERAND_r5900_vfsxyzw, RAB_OPERAND_r5900_vftn}, .instrSuffix=RABINSTRSUFFIX_R5900_xyzw, .isFloat=true) // MINimum broadcast +RABBITIZER_DEF_INSTR_ID(r5900, 0x18, vmulx, .operands={RAB_OPERAND_r5900_vfdxyzw, RAB_OPERAND_r5900_vfsxyzw, RAB_OPERAND_r5900_vftn}, .instrSuffix=RABINSTRSUFFIX_R5900_xyzw, .isFloat=true) // MULtiply broadcast +RABBITIZER_DEF_INSTR_ID(r5900, 0x19, vmuly, .operands={RAB_OPERAND_r5900_vfdxyzw, RAB_OPERAND_r5900_vfsxyzw, RAB_OPERAND_r5900_vftn}, .instrSuffix=RABINSTRSUFFIX_R5900_xyzw, .isFloat=true) // MULtiply broadcast +RABBITIZER_DEF_INSTR_ID(r5900, 0x1A, vmulz, .operands={RAB_OPERAND_r5900_vfdxyzw, RAB_OPERAND_r5900_vfsxyzw, RAB_OPERAND_r5900_vftn}, .instrSuffix=RABINSTRSUFFIX_R5900_xyzw, .isFloat=true) // MULtiply broadcast +RABBITIZER_DEF_INSTR_ID(r5900, 0x1B, vmulw, .operands={RAB_OPERAND_r5900_vfdxyzw, RAB_OPERAND_r5900_vfsxyzw, RAB_OPERAND_r5900_vftn}, .instrSuffix=RABINSTRSUFFIX_R5900_xyzw, .isFloat=true) // MULtiply broadcast +RABBITIZER_DEF_INSTR_ID(r5900, 0x1C, vmulq, .operands={RAB_OPERAND_r5900_vfdxyzw, RAB_OPERAND_r5900_vfsxyzw, RAB_OPERAND_r5900_Q}, .instrSuffix=RABINSTRSUFFIX_R5900_xyzw, .isFloat=true) // MULtiply Q +RABBITIZER_DEF_INSTR_ID(r5900, 0x1D, vmaxi, .operands={RAB_OPERAND_r5900_vfdxyzw, RAB_OPERAND_r5900_vfsxyzw, RAB_OPERAND_r5900_I}, .instrSuffix=RABINSTRSUFFIX_R5900_xyzw, .isFloat=true) // MAXimum I +RABBITIZER_DEF_INSTR_ID(r5900, 0x1E, vmuli, .operands={RAB_OPERAND_r5900_vfdxyzw, RAB_OPERAND_r5900_vfsxyzw, RAB_OPERAND_r5900_I}, .instrSuffix=RABINSTRSUFFIX_R5900_xyzw, .isFloat=true) // MULtiply I +RABBITIZER_DEF_INSTR_ID(r5900, 0x1F, vminii, .operands={RAB_OPERAND_r5900_vfdxyzw, RAB_OPERAND_r5900_vfsxyzw, RAB_OPERAND_r5900_I}, .instrSuffix=RABINSTRSUFFIX_R5900_xyzw, .isFloat=true) // MINImum I + +RABBITIZER_DEF_INSTR_ID(r5900, 0x20, vaddq, .operands={RAB_OPERAND_r5900_vfdxyzw, RAB_OPERAND_r5900_vfsxyzw, RAB_OPERAND_r5900_Q}, .instrSuffix=RABINSTRSUFFIX_R5900_xyzw, .isFloat=true) // ADD Q +RABBITIZER_DEF_INSTR_ID(r5900, 0x21, vmaddq, .operands={RAB_OPERAND_r5900_vfdxyzw, RAB_OPERAND_r5900_vfsxyzw, RAB_OPERAND_r5900_Q}, .instrSuffix=RABINSTRSUFFIX_R5900_xyzw, .isFloat=true) // Multiply-ADD Q +RABBITIZER_DEF_INSTR_ID(r5900, 0x22, vaddi, .operands={RAB_OPERAND_r5900_vfdxyzw, RAB_OPERAND_r5900_vfsxyzw, RAB_OPERAND_r5900_I}, .instrSuffix=RABINSTRSUFFIX_R5900_xyzw, .isFloat=true) // ADD I +RABBITIZER_DEF_INSTR_ID(r5900, 0x23, vmaddi, .operands={RAB_OPERAND_r5900_vfdxyzw, RAB_OPERAND_r5900_vfsxyzw, RAB_OPERAND_r5900_I}, .instrSuffix=RABINSTRSUFFIX_R5900_xyzw, .isFloat=true) // Multiply-ADD I +RABBITIZER_DEF_INSTR_ID(r5900, 0x24, vsubq, .operands={RAB_OPERAND_r5900_vfdxyzw, RAB_OPERAND_r5900_vfsxyzw, RAB_OPERAND_r5900_Q}, .instrSuffix=RABINSTRSUFFIX_R5900_xyzw, .isFloat=true) // SUBtract Q +RABBITIZER_DEF_INSTR_ID(r5900, 0x25, vmsubq, .operands={RAB_OPERAND_r5900_vfdxyzw, RAB_OPERAND_r5900_vfsxyzw, RAB_OPERAND_r5900_Q}, .instrSuffix=RABINSTRSUFFIX_R5900_xyzw, .isFloat=true) // Multiply-SUBtract Q +RABBITIZER_DEF_INSTR_ID(r5900, 0x26, vsubi, .operands={RAB_OPERAND_r5900_vfdxyzw, RAB_OPERAND_r5900_vfsxyzw, RAB_OPERAND_r5900_I}, .instrSuffix=RABINSTRSUFFIX_R5900_xyzw, .isFloat=true) // SUBtract I +RABBITIZER_DEF_INSTR_ID(r5900, 0x27, vmsubi, .operands={RAB_OPERAND_r5900_vfdxyzw, RAB_OPERAND_r5900_vfsxyzw, RAB_OPERAND_r5900_I}, .instrSuffix=RABINSTRSUFFIX_R5900_xyzw, .isFloat=true) // Multiply-SUBtract I +RABBITIZER_DEF_INSTR_ID(r5900, 0x28, vadd, .operands={RAB_OPERAND_r5900_vfdxyzw, RAB_OPERAND_r5900_vfsxyzw, RAB_OPERAND_r5900_vftxyzw}, .instrSuffix=RABINSTRSUFFIX_R5900_xyzw, .isFloat=true) // ADD +RABBITIZER_DEF_INSTR_ID(r5900, 0x29, vmadd, .operands={RAB_OPERAND_r5900_vfdxyzw, RAB_OPERAND_r5900_vfsxyzw, RAB_OPERAND_r5900_vftxyzw}, .instrSuffix=RABINSTRSUFFIX_R5900_xyzw, .isFloat=true) // Multiply-ADD +RABBITIZER_DEF_INSTR_ID(r5900, 0x2A, vmul, .operands={RAB_OPERAND_r5900_vfdxyzw, RAB_OPERAND_r5900_vfsxyzw, RAB_OPERAND_r5900_vftxyzw}, .instrSuffix=RABINSTRSUFFIX_R5900_xyzw, .isFloat=true) // MULtiply +RABBITIZER_DEF_INSTR_ID(r5900, 0x2B, vmax, .operands={RAB_OPERAND_r5900_vfdxyzw, RAB_OPERAND_r5900_vfsxyzw, RAB_OPERAND_r5900_vftxyzw}, .instrSuffix=RABINSTRSUFFIX_R5900_xyzw, .isFloat=true) // MAXimum +RABBITIZER_DEF_INSTR_ID(r5900, 0x2C, vsub, .operands={RAB_OPERAND_r5900_vfdxyzw, RAB_OPERAND_r5900_vfsxyzw, RAB_OPERAND_r5900_vftxyzw}, .instrSuffix=RABINSTRSUFFIX_R5900_xyzw, .isFloat=true) // SUBtract +RABBITIZER_DEF_INSTR_ID(r5900, 0x2D, vmsub, .operands={RAB_OPERAND_r5900_vfdxyzw, RAB_OPERAND_r5900_vfsxyzw, RAB_OPERAND_r5900_vftxyzw}, .instrSuffix=RABINSTRSUFFIX_R5900_xyzw, .isFloat=true) // Multiply-SUBtract +RABBITIZER_DEF_INSTR_ID(r5900, 0x2E, vopmsub, .operands={RAB_OPERAND_r5900_vfdxyzw, RAB_OPERAND_r5900_vfsxyzw, RAB_OPERAND_r5900_vftxyzw}, .instrSuffix=RABINSTRSUFFIX_R5900_xyzw, .isFloat=true) // Outer product post decrement +RABBITIZER_DEF_INSTR_ID(r5900, 0x2F, vmini, .operands={RAB_OPERAND_r5900_vfdxyzw, RAB_OPERAND_r5900_vfsxyzw, RAB_OPERAND_r5900_vftxyzw}, .instrSuffix=RABINSTRSUFFIX_R5900_xyzw, .isFloat=true) // MINImum + +RABBITIZER_DEF_INSTR_ID(r5900, 0x30, viadd, .operands={RAB_OPERAND_r5900_vid, RAB_OPERAND_r5900_vis, RAB_OPERAND_r5900_vit}) // Integer ADD +RABBITIZER_DEF_INSTR_ID(r5900, 0x31, visub, .operands={RAB_OPERAND_r5900_vid, RAB_OPERAND_r5900_vis, RAB_OPERAND_r5900_vit}) // Integer SUBtract +RABBITIZER_DEF_INSTR_ID(r5900, 0x32, viaddi, .operands={RAB_OPERAND_r5900_vit, RAB_OPERAND_r5900_vis, RAB_OPERAND_r5900_immediate5}) // Integer ADD Immediate +RABBITIZER_DEF_INSTR_ID(r5900, 0x34, viand, .operands={RAB_OPERAND_r5900_vid, RAB_OPERAND_r5900_vis, RAB_OPERAND_r5900_vit}) // Integer AND +RABBITIZER_DEF_INSTR_ID(r5900, 0x35, vior, .operands={RAB_OPERAND_r5900_vid, RAB_OPERAND_r5900_vis, RAB_OPERAND_r5900_vit}) // Integer OR + +// TODO: operands and properties +RABBITIZER_DEF_INSTR_ID(r5900, 0x38, vcallms, .operands={0}) +RABBITIZER_DEF_INSTR_ID(r5900, 0x39, vcallmsr, .operands={RAB_OPERAND_r5900_vis}) diff --git a/tools/ido-static-recomp/tools/rabbitizer/include/instructions/instr_id/r5900/r5900_cop2_special2.inc b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/instr_id/r5900/r5900_cop2_special2.inc new file mode 100644 index 00000000..6558540f --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/instr_id/r5900/r5900_cop2_special2.inc @@ -0,0 +1,125 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +/* + 31---------26-25-----21-20------------------11-10------6-5-2-1--0 + | =COP2 | Special2 | | fhi |1111|flo| + ------6----------5----------------------------------------------- +Note: opcode is flo | (fhi * 4). + |--000--|--001--|--010--|--011--|--100--|--101--|--110--|--111--| lo +0000 |VADDAx |VADDAy |VADDAz |VADDAw |VSUBAx |VSUBAy |VSUBAz |VSUBAw | +0001 |VMADDAx|VMADDAy|VMADDAz|VMADDAw|VMSUBAx|VMSUBAy|VMSUBAz|VMSUBAw| +0010 |VITOF0 |VITOF4 |VITOF12|VITOF15|VFTOI0 |VFTOI4 |VFTOI12|VFTOI15| +0011 |VMULAx |VMULAy |VMULAz |VMULAw |VMULAq |VABS |VMULAi |VCLIPw | +0100 |VADDAq |VMADDAq|VADDAi |VMADDAi|VSUBAq |VMSUBAq|VSUBAi |VMSUBAi| +0101 |VADDA |VMADDA |VMULA | --- |VSUBA |VMSUBA |VOPMULA|VNOP | +0110 |VMOVE |VMR32 | --- | --- |VLQI |VSQI |VLQD |VSQD | +0111 |VDIV |VSQRT |VRSQRT |VWAITQ |VMTIR |VMFIR |VILWR |VISWR | +1000 |VRNEXT |VRGET |VRINIT |VRXOR | --- | --- | --- | --- | +1001 | --- | --- | --- | --- | --- | --- | --- | --- | +1010 | --- | --- | --- | --- | --- | --- | --- | --- | +1011 | --- | --- | --- | --- | --- | --- | --- | --- | +1100 | --- | --- | --- | --- | --- | --- | --- | --- | +1101 | --- | --- | --- | --- | --- | --- | --- | --- | +1110 | --- | --- | --- | --- | --- | --- | --- | --- | +1111 | --- | --- | --- | --- | --- | --- | --- | --- | + hi |-------|-------|-------|-------|-------|-------|-------|-------| +*/ + +// TODO: operands and properties + +RABBITIZER_DEF_INSTR_ID(r5900, 0x00, vaddax, .operands={RAB_OPERAND_r5900_ACCxyzw, RAB_OPERAND_r5900_vfsxyzw, RAB_OPERAND_r5900_vftn}, .instrSuffix=RABINSTRSUFFIX_R5900_xyzw, .isFloat=true) // Add accumulator broadcast +RABBITIZER_DEF_INSTR_ID(r5900, 0x01, vadday, .operands={RAB_OPERAND_r5900_ACCxyzw, RAB_OPERAND_r5900_vfsxyzw, RAB_OPERAND_r5900_vftn}, .instrSuffix=RABINSTRSUFFIX_R5900_xyzw, .isFloat=true) // Add accumulator broadcast +RABBITIZER_DEF_INSTR_ID(r5900, 0x02, vaddaz, .operands={RAB_OPERAND_r5900_ACCxyzw, RAB_OPERAND_r5900_vfsxyzw, RAB_OPERAND_r5900_vftn}, .instrSuffix=RABINSTRSUFFIX_R5900_xyzw, .isFloat=true) // Add accumulator broadcast +RABBITIZER_DEF_INSTR_ID(r5900, 0x03, vaddaw, .operands={RAB_OPERAND_r5900_ACCxyzw, RAB_OPERAND_r5900_vfsxyzw, RAB_OPERAND_r5900_vftn}, .instrSuffix=RABINSTRSUFFIX_R5900_xyzw, .isFloat=true) // Add accumulator broadcast +RABBITIZER_DEF_INSTR_ID(r5900, 0x04, vsubax, .operands={RAB_OPERAND_r5900_ACCxyzw, RAB_OPERAND_r5900_vfsxyzw, RAB_OPERAND_r5900_vftn}, .instrSuffix=RABINSTRSUFFIX_R5900_xyzw, .isFloat=true) // Multiply and substract accumulator broadcast +RABBITIZER_DEF_INSTR_ID(r5900, 0x05, vsubay, .operands={RAB_OPERAND_r5900_ACCxyzw, RAB_OPERAND_r5900_vfsxyzw, RAB_OPERAND_r5900_vftn}, .instrSuffix=RABINSTRSUFFIX_R5900_xyzw, .isFloat=true) // Multiply and substract accumulator broadcast +RABBITIZER_DEF_INSTR_ID(r5900, 0x06, vsubaz, .operands={RAB_OPERAND_r5900_ACCxyzw, RAB_OPERAND_r5900_vfsxyzw, RAB_OPERAND_r5900_vftn}, .instrSuffix=RABINSTRSUFFIX_R5900_xyzw, .isFloat=true) // Multiply and substract accumulator broadcast +RABBITIZER_DEF_INSTR_ID(r5900, 0x07, vsubaw, .operands={RAB_OPERAND_r5900_ACCxyzw, RAB_OPERAND_r5900_vfsxyzw, RAB_OPERAND_r5900_vftn}, .instrSuffix=RABINSTRSUFFIX_R5900_xyzw, .isFloat=true) // Multiply and substract accumulator broadcast +RABBITIZER_DEF_INSTR_ID(r5900, 0x08, vmaddax, .operands={RAB_OPERAND_r5900_ACCxyzw, RAB_OPERAND_r5900_vfsxyzw, RAB_OPERAND_r5900_vftn}, .instrSuffix=RABINSTRSUFFIX_R5900_xyzw) // Multiply and add accumulator broadcast +RABBITIZER_DEF_INSTR_ID(r5900, 0x09, vmadday, .operands={RAB_OPERAND_r5900_ACCxyzw, RAB_OPERAND_r5900_vfsxyzw, RAB_OPERAND_r5900_vftn}, .instrSuffix=RABINSTRSUFFIX_R5900_xyzw) // Multiply and add accumulator broadcast +RABBITIZER_DEF_INSTR_ID(r5900, 0x0A, vmaddaz, .operands={RAB_OPERAND_r5900_ACCxyzw, RAB_OPERAND_r5900_vfsxyzw, RAB_OPERAND_r5900_vftn}, .instrSuffix=RABINSTRSUFFIX_R5900_xyzw) // Multiply and add accumulator broadcast +RABBITIZER_DEF_INSTR_ID(r5900, 0x0B, vmaddaw, .operands={RAB_OPERAND_r5900_ACCxyzw, RAB_OPERAND_r5900_vfsxyzw, RAB_OPERAND_r5900_vftn}, .instrSuffix=RABINSTRSUFFIX_R5900_xyzw) // Multiply and add accumulator broadcast +RABBITIZER_DEF_INSTR_ID(r5900, 0x0C, vmsubax, .operands={RAB_OPERAND_r5900_ACCxyzw, RAB_OPERAND_r5900_vfsxyzw, RAB_OPERAND_r5900_vftn}, .instrSuffix=RABINSTRSUFFIX_R5900_xyzw, .isFloat=true) // Multiply and substract accumulator broadcast +RABBITIZER_DEF_INSTR_ID(r5900, 0x0D, vmsubay, .operands={RAB_OPERAND_r5900_ACCxyzw, RAB_OPERAND_r5900_vfsxyzw, RAB_OPERAND_r5900_vftn}, .instrSuffix=RABINSTRSUFFIX_R5900_xyzw, .isFloat=true) // Multiply and substract accumulator broadcast +RABBITIZER_DEF_INSTR_ID(r5900, 0x0E, vmsubaz, .operands={RAB_OPERAND_r5900_ACCxyzw, RAB_OPERAND_r5900_vfsxyzw, RAB_OPERAND_r5900_vftn}, .instrSuffix=RABINSTRSUFFIX_R5900_xyzw, .isFloat=true) // Multiply and substract accumulator broadcast +RABBITIZER_DEF_INSTR_ID(r5900, 0x0F, vmsubaw, .operands={RAB_OPERAND_r5900_ACCxyzw, RAB_OPERAND_r5900_vfsxyzw, RAB_OPERAND_r5900_vftn}, .instrSuffix=RABINSTRSUFFIX_R5900_xyzw, .isFloat=true) // Multiply and substract accumulator broadcast + +RABBITIZER_DEF_INSTR_ID(r5900, 0x10, vitof0, .operands={RAB_OPERAND_r5900_vftxyzw, RAB_OPERAND_r5900_vfsxyzw}, .instrSuffix=RABINSTRSUFFIX_R5900_xyzw, .isFloat=true) // Integer to floating point +RABBITIZER_DEF_INSTR_ID(r5900, 0x11, vitof4, .operands={RAB_OPERAND_r5900_vftxyzw, RAB_OPERAND_r5900_vfsxyzw}, .instrSuffix=RABINSTRSUFFIX_R5900_xyzw, .isFloat=true) // Integer to floating point +RABBITIZER_DEF_INSTR_ID(r5900, 0x12, vitof12, .operands={RAB_OPERAND_r5900_vftxyzw, RAB_OPERAND_r5900_vfsxyzw}, .instrSuffix=RABINSTRSUFFIX_R5900_xyzw, .isFloat=true) // Integer to floating point +RABBITIZER_DEF_INSTR_ID(r5900, 0x13, vitof15, .operands={RAB_OPERAND_r5900_vftxyzw, RAB_OPERAND_r5900_vfsxyzw}, .instrSuffix=RABINSTRSUFFIX_R5900_xyzw, .isFloat=true) // Integer to floating point +RABBITIZER_DEF_INSTR_ID(r5900, 0x14, vftoi0, .operands={RAB_OPERAND_r5900_vftxyzw, RAB_OPERAND_r5900_vfsxyzw}, .instrSuffix=RABINSTRSUFFIX_R5900_xyzw, .isFloat=true) // Floating to integer +RABBITIZER_DEF_INSTR_ID(r5900, 0x15, vftoi4, .operands={RAB_OPERAND_r5900_vftxyzw, RAB_OPERAND_r5900_vfsxyzw}, .instrSuffix=RABINSTRSUFFIX_R5900_xyzw, .isFloat=true) // Floating to integer +RABBITIZER_DEF_INSTR_ID(r5900, 0x16, vftoi12, .operands={RAB_OPERAND_r5900_vftxyzw, RAB_OPERAND_r5900_vfsxyzw}, .instrSuffix=RABINSTRSUFFIX_R5900_xyzw, .isFloat=true) // Floating to integer +RABBITIZER_DEF_INSTR_ID(r5900, 0x17, vftoi15, .operands={RAB_OPERAND_r5900_vftxyzw, RAB_OPERAND_r5900_vfsxyzw}, .instrSuffix=RABINSTRSUFFIX_R5900_xyzw, .isFloat=true) // Floating to integer + +RABBITIZER_DEF_INSTR_ID(r5900, 0x18, vmulax, .operands={RAB_OPERAND_r5900_ACCxyzw, RAB_OPERAND_r5900_vfsxyzw, RAB_OPERAND_r5900_vftn}, .instrSuffix=RABINSTRSUFFIX_R5900_xyzw) +RABBITIZER_DEF_INSTR_ID(r5900, 0x19, vmulay, .operands={RAB_OPERAND_r5900_ACCxyzw, RAB_OPERAND_r5900_vfsxyzw, RAB_OPERAND_r5900_vftn}, .instrSuffix=RABINSTRSUFFIX_R5900_xyzw) +RABBITIZER_DEF_INSTR_ID(r5900, 0x1A, vmulaz, .operands={RAB_OPERAND_r5900_ACCxyzw, RAB_OPERAND_r5900_vfsxyzw, RAB_OPERAND_r5900_vftn}, .instrSuffix=RABINSTRSUFFIX_R5900_xyzw) +RABBITIZER_DEF_INSTR_ID(r5900, 0x1B, vmulaw, .operands={RAB_OPERAND_r5900_ACCxyzw, RAB_OPERAND_r5900_vfsxyzw, RAB_OPERAND_r5900_vftn}, .instrSuffix=RABINSTRSUFFIX_R5900_xyzw) +// TODO +RABBITIZER_DEF_INSTR_ID(r5900, 0x1C, vmulaq, .operands={RAB_OPERAND_r5900_ACCxyzw, RAB_OPERAND_r5900_vfsxyzw, RAB_OPERAND_r5900_Q}, .instrSuffix=RABINSTRSUFFIX_R5900_xyzw) + +RABBITIZER_DEF_INSTR_ID(r5900, 0x1D, vabs, .operands={RAB_OPERAND_r5900_vftxyzw, RAB_OPERAND_r5900_vfsxyzw}, .instrSuffix=RABINSTRSUFFIX_R5900_xyzw, .isFloat=true) // Absolute + +// TODO +RABBITIZER_DEF_INSTR_ID(r5900, 0x1E, vmulai, .operands={RAB_OPERAND_r5900_ACCxyzw, RAB_OPERAND_r5900_vfsxyzw, RAB_OPERAND_r5900_I}, .instrSuffix=RABINSTRSUFFIX_R5900_xyzw) + +RABBITIZER_DEF_INSTR_ID(r5900, 0x1F, vclipw, .operands={RAB_OPERAND_r5900_vfsxyzw, RAB_OPERAND_r5900_vftn}, .instrSuffix=RABINSTRSUFFIX_R5900_xyzw, .isFloat=true) // Clip + +RABBITIZER_DEF_INSTR_ID(r5900, 0x20, vaddaq, .operands={RAB_OPERAND_r5900_ACCxyzw, RAB_OPERAND_r5900_vfsxyzw, RAB_OPERAND_r5900_Q}, .instrSuffix=RABINSTRSUFFIX_R5900_xyzw, .isFloat=true) // Add accumulator Q +RABBITIZER_DEF_INSTR_ID(r5900, 0x21, vmaddaq, .operands={RAB_OPERAND_r5900_ACCxyzw, RAB_OPERAND_r5900_vfsxyzw, RAB_OPERAND_r5900_Q}, .instrSuffix=RABINSTRSUFFIX_R5900_xyzw, .isFloat=true) // Multiply and add accumulator Q +RABBITIZER_DEF_INSTR_ID(r5900, 0x22, vaddai, .operands={RAB_OPERAND_r5900_ACCxyzw, RAB_OPERAND_r5900_vfsxyzw, RAB_OPERAND_r5900_I}, .instrSuffix=RABINSTRSUFFIX_R5900_xyzw, .isFloat=true) // Add accumulator I +RABBITIZER_DEF_INSTR_ID(r5900, 0x23, vmaddai, .operands={RAB_OPERAND_r5900_ACCxyzw, RAB_OPERAND_r5900_vfsxyzw, RAB_OPERAND_r5900_I}, .instrSuffix=RABINSTRSUFFIX_R5900_xyzw, .isFloat=true) // Multiply and add accumulator I +RABBITIZER_DEF_INSTR_ID(r5900, 0x24, vsubaq, .operands={RAB_OPERAND_r5900_ACCxyzw, RAB_OPERAND_r5900_vfsxyzw, RAB_OPERAND_r5900_Q}, .instrSuffix=RABINSTRSUFFIX_R5900_xyzw, .isFloat=true) // Subtract accumulator Q +RABBITIZER_DEF_INSTR_ID(r5900, 0x25, vmsubaq, .operands={RAB_OPERAND_r5900_ACCxyzw, RAB_OPERAND_r5900_vfsxyzw, RAB_OPERAND_r5900_Q}, .instrSuffix=RABINSTRSUFFIX_R5900_xyzw, .isFloat=true) // Multiply and Subtract accumulator Q +RABBITIZER_DEF_INSTR_ID(r5900, 0x26, vsubai, .operands={RAB_OPERAND_r5900_ACCxyzw, RAB_OPERAND_r5900_vfsxyzw, RAB_OPERAND_r5900_I}, .instrSuffix=RABINSTRSUFFIX_R5900_xyzw, .isFloat=true) // Subtract accumulator I +RABBITIZER_DEF_INSTR_ID(r5900, 0x27, vmsubai, .operands={RAB_OPERAND_r5900_ACCxyzw, RAB_OPERAND_r5900_vfsxyzw, RAB_OPERAND_r5900_I}, .instrSuffix=RABINSTRSUFFIX_R5900_xyzw, .isFloat=true) // Multiply and Subtract accumulator I +RABBITIZER_DEF_INSTR_ID(r5900, 0x28, vadda, .operands={RAB_OPERAND_r5900_ACCxyzw, RAB_OPERAND_r5900_vftxyzw, RAB_OPERAND_r5900_vfsxyzw}, .instrSuffix=RABINSTRSUFFIX_R5900_xyzw, .isFloat=true) // Add accumulator +RABBITIZER_DEF_INSTR_ID(r5900, 0x29, vmadda, .operands={RAB_OPERAND_r5900_ACCxyzw, RAB_OPERAND_r5900_vfsxyzw, RAB_OPERAND_r5900_vftxyzw}, .instrSuffix=RABINSTRSUFFIX_R5900_xyzw, .isFloat=true) // Multiply and add accumulator + +// TODO +RABBITIZER_DEF_INSTR_ID(r5900, 0x2A, vmula, .operands={RAB_OPERAND_r5900_ACCxyzw, RAB_OPERAND_r5900_vfsxyzw, RAB_OPERAND_r5900_vftxyzw}, .instrSuffix=RABINSTRSUFFIX_R5900_xyzw) + +RABBITIZER_DEF_INSTR_ID(r5900, 0x2C, vsuba, .operands={RAB_OPERAND_r5900_ACCxyzw, RAB_OPERAND_r5900_vfsxyzw, RAB_OPERAND_r5900_vftxyzw}, .instrSuffix=RABINSTRSUFFIX_R5900_xyzw, .isFloat=true) +RABBITIZER_DEF_INSTR_ID(r5900, 0x2D, vmsuba, .operands={RAB_OPERAND_r5900_ACCxyzw, RAB_OPERAND_r5900_vftxyzw, RAB_OPERAND_r5900_vfsxyzw}, .instrSuffix=RABINSTRSUFFIX_R5900_xyzw, .isFloat=true) // Multiply and substract accumulator +RABBITIZER_DEF_INSTR_ID(r5900, 0x2E, vopmula, .operands={RAB_OPERAND_r5900_ACCxyzw, RAB_OPERAND_r5900_vfsxyzw, RAB_OPERAND_r5900_vftxyzw}, .instrSuffix=RABINSTRSUFFIX_R5900_xyzw, .isFloat=true) // Outer product pre increment +RABBITIZER_DEF_INSTR_ID(r5900, 0x2F, vnop, .operands={0}) // No operation + +RABBITIZER_DEF_INSTR_ID(r5900, 0x30, vmove, .operands={RAB_OPERAND_r5900_vftxyzw, RAB_OPERAND_r5900_vfsxyzw}, .instrSuffix=RABINSTRSUFFIX_R5900_xyzw, .isFloat=true) // Move floating point registers +RABBITIZER_DEF_INSTR_ID(r5900, 0x31, vmr32, .operands={RAB_OPERAND_r5900_vftxyzw, RAB_OPERAND_r5900_vfsxyzw}, .instrSuffix=RABINSTRSUFFIX_R5900_xyzw, .isFloat=true) // Move and rotate per word +RABBITIZER_DEF_INSTR_ID(r5900, 0x34, vlqi, .operands={RAB_OPERAND_r5900_vftxyzw, RAB_OPERAND_r5900_vis_postincr}, .instrSuffix=RABINSTRSUFFIX_R5900_xyzw, .isFloat=true) // Load quadraword post increment +RABBITIZER_DEF_INSTR_ID(r5900, 0x35, vsqi, .operands={RAB_OPERAND_r5900_vfsxyzw, RAB_OPERAND_r5900_vit_postincr}, .instrSuffix=RABINSTRSUFFIX_R5900_xyzw, .isFloat=true) // Store quadraword post increment +RABBITIZER_DEF_INSTR_ID(r5900, 0x36, vlqd, .operands={RAB_OPERAND_r5900_vftxyzw, RAB_OPERAND_r5900_vis_predecr}, .instrSuffix=RABINSTRSUFFIX_R5900_xyzw, .isFloat=true) // Load quadraword pre decrement +RABBITIZER_DEF_INSTR_ID(r5900, 0x37, vsqd, .operands={RAB_OPERAND_r5900_vfsxyzw, RAB_OPERAND_r5900_vit_predecr}, .instrSuffix=RABINSTRSUFFIX_R5900_xyzw, .isFloat=true) // Store quadraword pre decrement + +RABBITIZER_DEF_INSTR_ID(r5900, 0x38, vdiv, .operands={RAB_OPERAND_r5900_Q, RAB_OPERAND_r5900_vfsl, RAB_OPERAND_r5900_vftm}) +RABBITIZER_DEF_INSTR_ID(r5900, 0x39, vsqrt, .operands={RAB_OPERAND_r5900_Q, RAB_OPERAND_r5900_vftm}) +RABBITIZER_DEF_INSTR_ID(r5900, 0x3A, vrsqrt, .operands={RAB_OPERAND_r5900_Q, RAB_OPERAND_r5900_vfsl,RAB_OPERAND_r5900_vftm}) + +RABBITIZER_DEF_INSTR_ID(r5900, 0x3B, vwaitq, .operands={0}) // Wait Q operation + +RABBITIZER_DEF_INSTR_ID(r5900, 0x3C, vmtir, .operands={RAB_OPERAND_r5900_vit, RAB_OPERAND_r5900_vfsl}) + +RABBITIZER_DEF_INSTR_ID(r5900, 0x3D, vmfir, .operands={RAB_OPERAND_r5900_vftxyzw, RAB_OPERAND_r5900_vis}, .instrSuffix=RABINSTRSUFFIX_R5900_xyzw, .isFloat=true) // Move from integer register + +RABBITIZER_DEF_INSTR_ID(r5900, 0x3E, vilwr, .operands={RAB_OPERAND_r5900_vit, RAB_OPERAND_r5900_vis}, .isFloat=true, .doesDereference=true, .doesLoad=true) // Integer load word register +RABBITIZER_DEF_INSTR_ID(r5900, 0x3F, viswr, .operands={RAB_OPERAND_r5900_vit, RAB_OPERAND_r5900_vis}, .isFloat=true, .doesDereference=true, .doesStore=true) // Integer store word register +/* +"vilwr.w", RAB_OPERAND_r5900_vit,(RAB_OPERAND_r5900_vis) +"vilwr.x", RAB_OPERAND_r5900_vit,(RAB_OPERAND_r5900_vis) +"vilwr.y", RAB_OPERAND_r5900_vit,(RAB_OPERAND_r5900_vis) +"vilwr.z", RAB_OPERAND_r5900_vit,(RAB_OPERAND_r5900_vis) +"viswr.w", RAB_OPERAND_r5900_vit,(RAB_OPERAND_r5900_vis) +"viswr.x", RAB_OPERAND_r5900_vit,(RAB_OPERAND_r5900_vis) +"viswr.y", RAB_OPERAND_r5900_vit,(RAB_OPERAND_r5900_vis) +"viswr.z", RAB_OPERAND_r5900_vit,(RAB_OPERAND_r5900_vis) +*/ + +RABBITIZER_DEF_INSTR_ID(r5900, 0x40, vrnext, .operands={RAB_OPERAND_r5900_vftxyzw, RAB_OPERAND_r5900_R}, .instrSuffix=RABINSTRSUFFIX_R5900_xyzw, .isFloat=true) // R next +RABBITIZER_DEF_INSTR_ID(r5900, 0x41, vrget, .operands={RAB_OPERAND_r5900_vftxyzw, RAB_OPERAND_r5900_R}, .instrSuffix=RABINSTRSUFFIX_R5900_xyzw, .isFloat=true) // R move + +// TODO +RABBITIZER_DEF_INSTR_ID(r5900, 0x42, vrinit, .operands={RAB_OPERAND_r5900_R, RAB_OPERAND_r5900_vfsl}) +RABBITIZER_DEF_INSTR_ID(r5900, 0x43, vrxor, .operands={RAB_OPERAND_r5900_R, RAB_OPERAND_r5900_vfsl}) diff --git a/tools/ido-static-recomp/tools/rabbitizer/include/instructions/instr_id/r5900/r5900_mmi.inc b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/instr_id/r5900/r5900_mmi.inc new file mode 100644 index 00000000..1cc9bf5c --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/instr_id/r5900/r5900_mmi.inc @@ -0,0 +1,49 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +/* + 31---------26------------------------------------------5--------0 + | = MMI | | function| + ------6----------------------------------------------------6----- + |--000--|--001--|--010--|--011--|--100--|--101--|--110--|--111--| lo +000 | MADD | MADDU | --- | --- | PLZCW | --- | --- | --- | +001 | *1 | *2 | --- | --- | --- | --- | --- | --- | +010 | MFHI1 | MTHI1 | MFLO1 | MTLO1 | --- | --- | --- | --- | +011 | MULT1 | MULTU1| DIV1 | DIVU1 | --- | --- | --- | --- | +100 | MADD1 | MADDU1| --- | --- | --- | --- | --- | --- | +101 | *3 | *4 | --- | --- | --- | --- | --- | --- | +110 | PMFHL | PMTHL | --- | --- | PSLLH | --- | PSRLH | PSRAH | +111 | --- | --- | --- | --- | PSLLW | --- | PSRLW | PSRAW | + hi |-------|-------|-------|-------|-------|-------|-------|-------| + *1 = MMI0 list *2 = MMI2 list + *3 = MMI1 list *4 = MMI3 list +*/ + +RABBITIZER_DEF_INSTR_ID(r5900, 0x00, madd, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_rt}, .modifiesRd=true) // Multiply-ADD word +RABBITIZER_DEF_INSTR_ID(r5900, 0x01, maddu, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_rt}, .modifiesRd=true) // Multiply-ADD Unsigned word +RABBITIZER_DEF_INSTR_ID(r5900, 0x04, plzcw, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rs}, .modifiesRd=true) // Parallel Leading Zero or one Count Word + +RABBITIZER_DEF_INSTR_ID(r5900, 0x10, mfhi1, .operands={RAB_OPERAND_cpu_rd}, .modifiesRd=true) // Move From HI1 register +RABBITIZER_DEF_INSTR_ID(r5900, 0x11, mthi1, .operands={RAB_OPERAND_cpu_rs}) // Move To HI1 register +RABBITIZER_DEF_INSTR_ID(r5900, 0x12, mflo1, .operands={RAB_OPERAND_cpu_rd}) // Move From LO1 register +RABBITIZER_DEF_INSTR_ID(r5900, 0x13, mtlo1, .operands={RAB_OPERAND_cpu_rs}) // Move To LO1 register + +RABBITIZER_DEF_INSTR_ID(r5900, 0x18, mult1, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_rt}, .modifiesRd=true) // MULTiply word pipeline 1 +RABBITIZER_DEF_INSTR_ID(r5900, 0x19, multu1, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_rt}, .modifiesRd=true) // MULTiply Unsigned word pipeline 1 +RABBITIZER_DEF_INSTR_ID(r5900, 0x1A, div1, .operands={RAB_OPERAND_cpu_zero, RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_rt}) // DIVide word pipeline 1 +RABBITIZER_DEF_INSTR_ID(r5900, 0x1B, divu1, .operands={RAB_OPERAND_cpu_zero, RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_rt}) // DIVide Unsigned word pipeline 1 + +RABBITIZER_DEF_INSTR_ID(r5900, 0x20, madd1, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_rt}, .modifiesRd=true) // Multiply-ADD word pipeline 1 +RABBITIZER_DEF_INSTR_ID(r5900, 0x21, maddu1, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_rt}, .modifiesRd=true) // Multiply-ADD Unsigned word pipeline 1 + +// TODO: check this two instruction, it is supposed to have an extra .fmt +RABBITIZER_DEF_INSTR_ID(r5900, 0x30, pmfhl, .operands={RAB_OPERAND_cpu_rd}, .modifiesRd=true) // Parallel Move From Hi/Lo register +RABBITIZER_DEF_INSTR_ID(r5900, 0x31, pmthl, .operands={RAB_OPERAND_cpu_rs}) // Parallel Move To Hi/Lo register + +RABBITIZER_DEF_INSTR_ID(r5900, 0x34, psllh, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rt, RAB_OPERAND_cpu_sa}, .modifiesRd=true) // Parallel Shift Left Logical Halfword +RABBITIZER_DEF_INSTR_ID(r5900, 0x36, psrlh, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rt, RAB_OPERAND_cpu_sa}, .modifiesRd=true) // Parallel Shift Right Logical Halfword +RABBITIZER_DEF_INSTR_ID(r5900, 0x37, psrah, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rt, RAB_OPERAND_cpu_sa}, .modifiesRd=true) // Parallel Shift Right Arithmetic Halfword + +RABBITIZER_DEF_INSTR_ID(r5900, 0x3C, psllw, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rt, RAB_OPERAND_cpu_sa}, .modifiesRd=true) // Parallel Shift Left Logical Word +RABBITIZER_DEF_INSTR_ID(r5900, 0x3E, psrlw, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rt, RAB_OPERAND_cpu_sa}, .modifiesRd=true) // Parallel Shift Right Logical Word +RABBITIZER_DEF_INSTR_ID(r5900, 0x3F, psraw, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rt, RAB_OPERAND_cpu_sa}, .modifiesRd=true) // Parallel Shift Right Arithmetic Word diff --git a/tools/ido-static-recomp/tools/rabbitizer/include/instructions/instr_id/r5900/r5900_mmi_0.inc b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/instr_id/r5900/r5900_mmi_0.inc new file mode 100644 index 00000000..d9203e52 --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/instr_id/r5900/r5900_mmi_0.inc @@ -0,0 +1,50 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +/* + 31---------26------------------------------10--------6-5--------0 + | | |function | MMI0 | + ------6----------------------------------------------------6----- + |---00--|---01--|---10--|---11--| lo +000 |PADDW | PSUBW | PCGTW | PMAXW | +001 |PADDH | PSUBH | PCGTH | PMAXH | +010 |PADDB | PSUBB | PCGTB | --- | +011 | --- | --- | --- | --- | +100 |PADDSW |PSUBSW |PEXTLW | PPACW | +101 |PADDSH |PSUBSH |PEXTLH | PPACH | +110 |PADDSB |PSUBSB |PEXTLB | PPACB | +111 | --- | --- | PEXT5 | PPAC5 | + hi |-------|-------|-------|-------| +*/ + +RABBITIZER_DEF_INSTR_ID(r5900, 0x00, paddw, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_rt}, .modifiesRd=true) // Parallel ADD Word +RABBITIZER_DEF_INSTR_ID(r5900, 0x01, psubw, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_rt}, .modifiesRd=true) // Parallel SUBtract Word +RABBITIZER_DEF_INSTR_ID(r5900, 0x02, pcgtw, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_rt}, .modifiesRd=true) // Parallel Compare for Greater Than Word +RABBITIZER_DEF_INSTR_ID(r5900, 0x03, pmaxw, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_rt}, .modifiesRd=true) // Parallel MAXimum Word + +RABBITIZER_DEF_INSTR_ID(r5900, 0x04, paddh, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_rt}, .modifiesRd=true) // Parallel ADD Halfword +RABBITIZER_DEF_INSTR_ID(r5900, 0x05, psubh, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_rt}, .modifiesRd=true) // Parallel SUBtract Halfword +RABBITIZER_DEF_INSTR_ID(r5900, 0x06, pcgth, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_rt}, .modifiesRd=true) // Parallel Compare for Greater Than Halfword +RABBITIZER_DEF_INSTR_ID(r5900, 0x07, pmaxh, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_rt}, .modifiesRd=true) // Parallel MAXimum Halfword + +RABBITIZER_DEF_INSTR_ID(r5900, 0x08, paddb, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_rt}, .modifiesRd=true) // Parallel ADD Byte +RABBITIZER_DEF_INSTR_ID(r5900, 0x09, psubb, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_rt}, .modifiesRd=true) // Parallel SUBtract Byte +RABBITIZER_DEF_INSTR_ID(r5900, 0x0A, pcgtb, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_rt}, .modifiesRd=true) // Parallel Compare for Greater Than Byte + +RABBITIZER_DEF_INSTR_ID(r5900, 0x10, paddsw, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_rt}, .modifiesRd=true) // Parallel ADD with Signed saturation Word +RABBITIZER_DEF_INSTR_ID(r5900, 0x11, psubsw, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_rt}, .modifiesRd=true) // Parallel SUBtract with Signed saturation Word +RABBITIZER_DEF_INSTR_ID(r5900, 0x12, pextlw, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_rt}, .modifiesRd=true) // Parallel EXTend Lower from Word +RABBITIZER_DEF_INSTR_ID(r5900, 0x13, ppacw, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_rt}, .modifiesRd=true) // Parallel PACk to Word + +RABBITIZER_DEF_INSTR_ID(r5900, 0x14, paddsh, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_rt}, .modifiesRd=true) // Parallel ADD with Signed saturation Halfword +RABBITIZER_DEF_INSTR_ID(r5900, 0x15, psubsh, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_rt}, .modifiesRd=true) // Parallel SUBtract with Signed saturation Halfword +RABBITIZER_DEF_INSTR_ID(r5900, 0x16, pextlh, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_rt}, .modifiesRd=true) // Parallel EXTend Lower from Halfword +RABBITIZER_DEF_INSTR_ID(r5900, 0x17, ppach, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_rt}, .modifiesRd=true) // Parallel PACk to Halfword + +RABBITIZER_DEF_INSTR_ID(r5900, 0x18, paddsb, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_rt}, .modifiesRd=true) // Parallel ADD with Signed saturation Bytes +RABBITIZER_DEF_INSTR_ID(r5900, 0x19, psubsb, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_rt}, .modifiesRd=true) // Parallel SUBtract with Signed saturation Bytes +RABBITIZER_DEF_INSTR_ID(r5900, 0x1A, pextlb, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_rt}, .modifiesRd=true) // Parallel EXTend Lower from Bytes +RABBITIZER_DEF_INSTR_ID(r5900, 0x1B, ppacb, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_rt}, .modifiesRd=true) // Parallel PACk to Bytes + +RABBITIZER_DEF_INSTR_ID(r5900, 0x1E, pext5, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rt}, .modifiesRd=true) // Parallel EXTend from 5-bits +RABBITIZER_DEF_INSTR_ID(r5900, 0x1F, ppac5, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rt}, .modifiesRd=true) // Parallel PACk to 5-bits diff --git a/tools/ido-static-recomp/tools/rabbitizer/include/instructions/instr_id/r5900/r5900_mmi_1.inc b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/instr_id/r5900/r5900_mmi_1.inc new file mode 100644 index 00000000..64573223 --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/instr_id/r5900/r5900_mmi_1.inc @@ -0,0 +1,43 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +/* + 31---------26------------------------------------------5--------0 + | | |function | MMI1 | + ------6----------------------------------------------------6----- + |---00--|---01--|---10--|---11--| lo +000 | --- | PABSW | PCEQW | PMINW | +001 |PADSBH | PABSH | PCEQH | PMINH | +010 | --- | --- | PCEQB | --- | +011 | --- | --- | --- | --- | +100 |PADDUW |PSUBUW |PEXTUW | --- | +101 |PADDUH |PSUBUH |PEXTUH | --- | +110 |PADDUB |PSUBUB |PEXTUB | QFSRV | +111 | --- | --- | --- | --- | + hi |-------|-------|-------|-------| +*/ + +// TODO: operands and properties +RABBITIZER_DEF_INSTR_ID(r5900, 0x01, pabsw, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rt}, .modifiesRd=true) // Parallel ABSolute Word +RABBITIZER_DEF_INSTR_ID(r5900, 0x02, pceqw, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_rt}, .modifiesRd=true) // Parallel Compare for EQual Word +RABBITIZER_DEF_INSTR_ID(r5900, 0x03, pminw, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_rt}, .modifiesRd=true) // Parallel MINimum Word + +RABBITIZER_DEF_INSTR_ID(r5900, 0x04, padsbh, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_rt}, .modifiesRd=true) // Parallel ADd/SuBtract Halfword +RABBITIZER_DEF_INSTR_ID(r5900, 0x05, pabsh, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rt}, .modifiesRd=true) // Parallel ABSolute Halfword +RABBITIZER_DEF_INSTR_ID(r5900, 0x06, pceqh, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_rt}, .modifiesRd=true) // Parallel Compare for EQual Halfword +RABBITIZER_DEF_INSTR_ID(r5900, 0x07, pminh, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_rt}, .modifiesRd=true) // Parallel MINimum Halfword + +RABBITIZER_DEF_INSTR_ID(r5900, 0x0A, pceqb, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_rt}, .modifiesRd=true) // Parallel Compare for EQual Byte + +RABBITIZER_DEF_INSTR_ID(r5900, 0x10, padduw, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_rt}, .modifiesRd=true) // Parallel ADD Unsigned saturation Word +RABBITIZER_DEF_INSTR_ID(r5900, 0x11, psubuw, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_rt}, .modifiesRd=true) // Parallel SUBtract Unsigned saturation Word +RABBITIZER_DEF_INSTR_ID(r5900, 0x12, pextuw, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_rt}, .modifiesRd=true) // Parallel EXTend Upper from Word + +RABBITIZER_DEF_INSTR_ID(r5900, 0x14, padduh, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_rt}, .modifiesRd=true) // Parallel ADD Unsigned saturation Halfword +RABBITIZER_DEF_INSTR_ID(r5900, 0x15, psubuh, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_rt}, .modifiesRd=true) // Parallel SUBtract Unsigned saturation Halfword +RABBITIZER_DEF_INSTR_ID(r5900, 0x16, pextuh, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_rt}, .modifiesRd=true) // Parallel EXTend Upper from Halfword + +RABBITIZER_DEF_INSTR_ID(r5900, 0x18, paddub, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_rt}, .modifiesRd=true) // Parallel ADD Unsigned saturation Byte +RABBITIZER_DEF_INSTR_ID(r5900, 0x19, psubub, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_rt}, .modifiesRd=true) // Parallel SUBtract Unsigned saturation Byte +RABBITIZER_DEF_INSTR_ID(r5900, 0x1A, pextub, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_rt}, .modifiesRd=true) // Parallel EXTend Upper from Byte +RABBITIZER_DEF_INSTR_ID(r5900, 0x1B, qfsrv, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_rt}, .modifiesRd=true) // Quadword Funnel Shift Right Variable diff --git a/tools/ido-static-recomp/tools/rabbitizer/include/instructions/instr_id/r5900/r5900_mmi_2.inc b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/instr_id/r5900/r5900_mmi_2.inc new file mode 100644 index 00000000..a7cd357f --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/instr_id/r5900/r5900_mmi_2.inc @@ -0,0 +1,48 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +/* + 31---------26------------------------------------------5--------0 + | | |function | MMI2 | + ------6----------------------------------------------------6----- + |---00--|---01--|---10--|---11--| lo +000 |PMADDW | --- |PSLLVW |PSRLVW | +001 |PMSUBW | --- | --- | --- | +010 |PMFHI |PMFLO |PINTH | --- | +011 |PMULTW |PDIVW |PCPYLD | --- | +100 |PMADDH |PHMADH | PAND | PXOR | +101 |PMSUBH |PHMSBH | --- | --- | +110 | --- | --- | PEXEH | PREVH | +111 |PMULTH |PDIVBW | PEXEW |PROT3W | + hi |-------|-------|-------|-------| +*/ + +RABBITIZER_DEF_INSTR_ID(r5900, 0x00, pmaddw, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_rt}, .modifiesRd=true) // Parallel Multiply-ADD Word +RABBITIZER_DEF_INSTR_ID(r5900, 0x02, psllvw, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rt, RAB_OPERAND_cpu_rs}, .modifiesRd=true) // Parallel Shift Left Logical Variable Word +RABBITIZER_DEF_INSTR_ID(r5900, 0x03, psrlvw, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rt, RAB_OPERAND_cpu_rs}, .modifiesRd=true) // Parallel Shift Right Logical Variable Word + +RABBITIZER_DEF_INSTR_ID(r5900, 0x04, pmsubw, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_rt}, .modifiesRd=true) // Parallel Multiply-SUBtract Word + +RABBITIZER_DEF_INSTR_ID(r5900, 0x08, pmfhi, .operands={RAB_OPERAND_cpu_rd}, .modifiesRd=true) // Parallel Move From HI register +RABBITIZER_DEF_INSTR_ID(r5900, 0x09, pmflo, .operands={RAB_OPERAND_cpu_rd}, .modifiesRd=true) // Parallel Move From LO register +RABBITIZER_DEF_INSTR_ID(r5900, 0x0A, pinth, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_rt}, .modifiesRd=true) // Parallel INTerleave Halfword + +RABBITIZER_DEF_INSTR_ID(r5900, 0x0C, pmultw, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_rt}, .modifiesRd=true) // Parallel MULTiply Word +RABBITIZER_DEF_INSTR_ID(r5900, 0x0D, pdivw, .operands={RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_rt}) // Parallel DIVide Word +RABBITIZER_DEF_INSTR_ID(r5900, 0x0E, pcpyld, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_rt}, .modifiesRd=true) // Parallel CoPY Lower Doubleword + +RABBITIZER_DEF_INSTR_ID(r5900, 0x10, pmaddh, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_rt}, .modifiesRd=true) // Parallel Multiply-ADD Halfword +RABBITIZER_DEF_INSTR_ID(r5900, 0x11, phmadh, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_rt}, .modifiesRd=true) // Parallel Horizontal Multiply-ADd Halfword +RABBITIZER_DEF_INSTR_ID(r5900, 0x12, pand, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_rt}, .modifiesRd=true) // Parallel AND +RABBITIZER_DEF_INSTR_ID(r5900, 0x13, pxor, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_rt}, .modifiesRd=true) // Parallel eXclusive OR + +RABBITIZER_DEF_INSTR_ID(r5900, 0x14, pmsubh, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_rt}, .modifiesRd=true) // Parallel Multiply-SUBtract Halfword +RABBITIZER_DEF_INSTR_ID(r5900, 0x15, phmsbh, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_rt}, .modifiesRd=true) // Parallel Horizontal Multiply-Subtract Halfword + +RABBITIZER_DEF_INSTR_ID(r5900, 0x1A, pexeh, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rt}, .modifiesRd=true) // Parallel EXchange Even Halfword +RABBITIZER_DEF_INSTR_ID(r5900, 0x1B, prevh, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rt}, .modifiesRd=true) // Parallel REVerse Halfword + +RABBITIZER_DEF_INSTR_ID(r5900, 0x1C, pmulth, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_rt}, .modifiesRd=true) // Parallel Multiply Halfword +RABBITIZER_DEF_INSTR_ID(r5900, 0x1D, pdivbw, .operands={RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_rt}, .modifiesRd=true) // Parallel DIVide Broadcast Word +RABBITIZER_DEF_INSTR_ID(r5900, 0x1E, pexew, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rt}, .modifiesRd=true) // Parallel EXchange Even Word +RABBITIZER_DEF_INSTR_ID(r5900, 0x1F, prot3w, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rt}, .modifiesRd=true) // Parallel ROTate 3 Words left diff --git a/tools/ido-static-recomp/tools/rabbitizer/include/instructions/instr_id/r5900/r5900_mmi_3.inc b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/instr_id/r5900/r5900_mmi_3.inc new file mode 100644 index 00000000..21edadd5 --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/instr_id/r5900/r5900_mmi_3.inc @@ -0,0 +1,37 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +/* + 31---------26------------------------------------------5--------0 + | | |function | MMI3 | + ------6----------------------------------------------------6----- + |---00--|---01--|---10--|---11--| lo +000 |PMADDUW| --- | --- |PSRAVW | +001 | --- | --- | --- | --- | +010 |PMTHI | PMTLO |PINTEH | --- | +011 |PMULTUW| PDIVUW|PCPYUD | --- | +100 | --- | --- | POR | PNOR | +101 | --- | --- | --- | --- | +110 | --- | --- | PEXCH | PCPYH | +111 | --- | --- | PEXCW | --- | + hi |-------|-------|-------|-------| +*/ + +RABBITIZER_DEF_INSTR_ID(r5900, 0x00, pmadduw, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_rt}, .modifiesRd=true) // Parallel Multiply-ADD Unsigned Word +RABBITIZER_DEF_INSTR_ID(r5900, 0x03, psravw, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rt, RAB_OPERAND_cpu_rs}, .modifiesRd=true) // Parallel Shift Right Arithmetic Variable Word + +RABBITIZER_DEF_INSTR_ID(r5900, 0x08, pmthi, .operands={RAB_OPERAND_cpu_rs}) // Parallel Move To HI register +RABBITIZER_DEF_INSTR_ID(r5900, 0x09, pmtlo, .operands={RAB_OPERAND_cpu_rs}) // Parallel Move To LO register +RABBITIZER_DEF_INSTR_ID(r5900, 0x0A, pinteh, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_rt}, .modifiesRd=true) // Parallel INTerleave Even Halfword + +RABBITIZER_DEF_INSTR_ID(r5900, 0x0C, pmultuw, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_rt}, .modifiesRd=true) // Parallel MULTiply Unsigned Word +RABBITIZER_DEF_INSTR_ID(r5900, 0x0D, pdivuw, .operands={RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_rt}) // Prallel DIVide Unsigned Word +RABBITIZER_DEF_INSTR_ID(r5900, 0x0E, pcpyud, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_rt}, .modifiesRd=true) // Parallel CoPY Upper Doubleword + +RABBITIZER_DEF_INSTR_ID(r5900, 0x12, por, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_rt}, .modifiesRd=true) // Parallel OR +RABBITIZER_DEF_INSTR_ID(r5900, 0x13, pnor, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_rt}, .modifiesRd=true) // Parallel Not OR + +RABBITIZER_DEF_INSTR_ID(r5900, 0x1A, pexch, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rt}, .modifiesRd=true) // Parallel EXchange Center Halfword +RABBITIZER_DEF_INSTR_ID(r5900, 0x1B, pcpyh, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rt}, .modifiesRd=true) // Parallel CoPY Halfword + +RABBITIZER_DEF_INSTR_ID(r5900, 0x1E, pexcw, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rt}, .modifiesRd=true) // Parallel EXchange Center Word diff --git a/tools/ido-static-recomp/tools/rabbitizer/include/instructions/instr_id/r5900/r5900_normal.inc b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/instr_id/r5900/r5900_normal.inc new file mode 100644 index 00000000..d5bd5c23 --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/instr_id/r5900/r5900_normal.inc @@ -0,0 +1,31 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +/* + 31---------26---------------------------------------------------0 + | opcode | | + ------6---------------------------------------------------------- + |--000--|--001--|--010--|--011--|--100--|--101--|--110--|--111--| lo +000 | *1 | *2 | J | JAL | BEQ | BNE | BLEZ | BGTZ | +001 | ADDI | ADDIU | SLTI | SLTIU | ANDI | ORI | XORI | LUI | +010 | *3 | *4 | *5 | --- | BEQL | BNEL | BLEZL | BGTZL | +011 | DADDI |DADDIU | LDL | LDR | *6 | --- | LQ | SQ | +100 | LB | LH | LWL | LW | LBU | LHU | LWR | LWU | +101 | SB | SH | SWL | SW | SDL | SDR | SWR | CACHE | +110 | --- | LWC1 | --- | PREF | --- | --- | LQC2 | LD | +111 | --- | SWC1 | --- | --- | --- | --- | SQC2 | SD | + hi |-------|-------|-------|-------|-------|-------|-------|-------| + *1 = SPECIAL, see SPECIAL list *2 = REGIMM, see REGIMM list + *3 = COP0 *4 = COP1 + *5 = COP2 *6 = MMI table +*/ + +// The other instructions are implemented using the main CPU table + + +RABBITIZER_DEF_INSTR_ID(r5900, 0x1E, lq, .operands={RAB_OPERAND_cpu_rt, RAB_OPERAND_cpu_immediate_base}, .instrType=RABBITIZER_INSTR_TYPE_I, .modifiesRt=true, .canBeLo=true, .doesDereference=true, .doesLoad=true) // Load Quadword +RABBITIZER_DEF_INSTR_ID(r5900, 0x1F, sq, .operands={RAB_OPERAND_cpu_rt, RAB_OPERAND_cpu_immediate_base}, .instrType=RABBITIZER_INSTR_TYPE_I, .canBeLo=true, .doesDereference=true, .doesStore=true) // Store Quadword + +RABBITIZER_DEF_INSTR_ID(r5900, 0x36, lqc2, .operands={RAB_OPERAND_r5900_vft, RAB_OPERAND_cpu_immediate_base}, .canBeLo=true, .doesDereference=true, .doesLoad=true) + +RABBITIZER_DEF_INSTR_ID(r5900, 0x3E, sqc2, .operands={RAB_OPERAND_r5900_vft, RAB_OPERAND_cpu_immediate_base}, .canBeLo=true, .doesDereference=true, .doesStore=true) diff --git a/tools/ido-static-recomp/tools/rabbitizer/include/instructions/instr_id/r5900/r5900_regimm.inc b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/instr_id/r5900/r5900_regimm.inc new file mode 100644 index 00000000..c1f27a2a --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/instr_id/r5900/r5900_regimm.inc @@ -0,0 +1,20 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +/* + 31---------26----------20-------16------------------------------0 + | = REGIMM | | rt | | + ------6---------------------5------------------------------------ + |--000--|--001--|--010--|--011--|--100--|--101--|--110--|--111--| lo + 00 | BLTZ | BGEZ | BLTZL | BGEZL | --- | --- | --- | --- | + 01 | TGEI | TGEIU | TLTI | TLTIU | TEQI | --- | TNEI | --- | + 10 | BLTZAL| BGEZAL|BLTZALL|BGEZALL| --- | --- | --- | --- | + 11 | MTSAB | MTSAH | --- | --- | --- | --- | --- | --- | + hi |-------|-------|-------|-------|-------|-------|-------|-------| +*/ + +// The other instructions are implemented using the main CPU table + +// OP rs, IMM +RABBITIZER_DEF_INSTR_ID(r5900, 0x18, mtsab, .operands={RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_immediate}, .instrType=RABBITIZER_INSTR_TYPE_REGIMM) +RABBITIZER_DEF_INSTR_ID(r5900, 0x19, mtsah, .operands={RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_immediate}, .instrType=RABBITIZER_INSTR_TYPE_REGIMM) diff --git a/tools/ido-static-recomp/tools/rabbitizer/include/instructions/instr_id/r5900/r5900_special.inc b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/instr_id/r5900/r5900_special.inc new file mode 100644 index 00000000..22e1bb73 --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/instr_id/r5900/r5900_special.inc @@ -0,0 +1,27 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +/* + 31---------26------------------------------------------5--------0 + | = SPECIAL | | function| + ------6----------------------------------------------------6----- + |--000--|--001--|--010--|--011--|--100--|--101--|--110--|--111--| lo +000 | SLL | --- | SRL | SRA | SLLV | --- | SRLV | SRAV | +001 | JR | JALR | MOVZ | MOVN |SYSCALL| BREAK | --- | SYNC | +010 | MFHI | MTHI | MFLO | MTLO | DSLLV | --- | DSRLV | DSRAV | +011 | MULT | MULTU | DIV | DIVU | ---- | --- | ---- | ----- | +100 | ADD | ADDU | SUB | SUBU | AND | OR | XOR | NOR | +101 | MFSA | MTSA | SLT | SLTU | DADD | DADDU | DSUB | DSUBU | +110 | TGE | TGEU | TLT | TLTU | TEQ | --- | TNE | --- | +111 | DSLL | --- | DSRL | DSRA |DSLL32 | --- |DSRL32 |DSRA32 | + hi |-------|-------|-------|-------|-------|-------|-------|-------| +*/ + +// The other instructions are implemented using the main CPU table + +RABBITIZER_DEF_INSTR_ID_ALTNAME(r5900, -0x0F, sync_p, sync.p, .operands={0}, .instrType=RABBITIZER_INSTR_TYPE_R, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_II) // Sync + +RABBITIZER_DEF_INSTR_ID(r5900, 0x18, mult, .operands={RAB_OPERAND_cpu_rd, RAB_OPERAND_cpu_rs, RAB_OPERAND_cpu_rt}, .instrType=RABBITIZER_INSTR_TYPE_R, .modifiesRd=true) // MULTtiply word + +RABBITIZER_DEF_INSTR_ID(r5900, 0x28, mfsa, .operands={RAB_OPERAND_cpu_rd}, .modifiesRd=true) // Move From Shift Amount register +RABBITIZER_DEF_INSTR_ID(r5900, 0x29, mtsa, .operands={RAB_OPERAND_cpu_rs}) // Move To Shift Amount register diff --git a/tools/ido-static-recomp/tools/rabbitizer/include/instructions/instr_id/rsp/rsp_cop0.inc b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/instr_id/rsp/rsp_cop0.inc new file mode 100644 index 00000000..c6c7d0ea --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/instr_id/rsp/rsp_cop0.inc @@ -0,0 +1,6 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +// OP rt, cop0d +RABBITIZER_DEF_INSTR_ID(rsp, 0x00, mfc0, .operands={RAB_OPERAND_rsp_rt, RAB_OPERAND_rsp_cop0d}, .instrType=RABBITIZER_INSTR_TYPE_UNKNOWN, .modifiesRt=true, .notEmitedByCompilers=true) // Move word From CP0 +RABBITIZER_DEF_INSTR_ID(rsp, 0x04, mtc0, .operands={RAB_OPERAND_rsp_rt, RAB_OPERAND_rsp_cop0d}, .instrType=RABBITIZER_INSTR_TYPE_UNKNOWN, .notEmitedByCompilers=true) // Move word to CP0 diff --git a/tools/ido-static-recomp/tools/rabbitizer/include/instructions/instr_id/rsp/rsp_cop2.inc b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/instr_id/rsp/rsp_cop2.inc new file mode 100644 index 00000000..344891db --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/instr_id/rsp/rsp_cop2.inc @@ -0,0 +1,10 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +// OP cop2t, vd[index] +RABBITIZER_DEF_INSTR_ID(rsp, 0x00, mfc2, .operands={RAB_OPERAND_rsp_cop2t, RAB_OPERAND_rsp_vs_index}, .modifiesRt=true) +RABBITIZER_DEF_INSTR_ID(rsp, 0x04, mtc2, .operands={RAB_OPERAND_rsp_cop2t, RAB_OPERAND_rsp_vs_index}) + +// OP rt, cop2cd +RABBITIZER_DEF_INSTR_ID(rsp, 0x02, cfc2, .operands={RAB_OPERAND_cpu_rt, RAB_OPERAND_rsp_cop2cd}, .modifiesRt=true) +RABBITIZER_DEF_INSTR_ID(rsp, 0x06, ctc2, .operands={RAB_OPERAND_cpu_rt, RAB_OPERAND_rsp_cop2cd}) diff --git a/tools/ido-static-recomp/tools/rabbitizer/include/instructions/instr_id/rsp/rsp_cop2_vu.inc b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/instr_id/rsp/rsp_cop2_vu.inc new file mode 100644 index 00000000..4a927a59 --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/instr_id/rsp/rsp_cop2_vu.inc @@ -0,0 +1,53 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +// OP vd, vs, vt[elementhigh] +RABBITIZER_DEF_INSTR_ID(rsp, 0x00, vmulf, .operands={RAB_OPERAND_rsp_vd, RAB_OPERAND_rsp_vs, RAB_OPERAND_rsp_vt_elementhigh}) +RABBITIZER_DEF_INSTR_ID(rsp, 0x01, vmulu, .operands={RAB_OPERAND_rsp_vd, RAB_OPERAND_rsp_vs, RAB_OPERAND_rsp_vt_elementhigh}) +RABBITIZER_DEF_INSTR_ID(rsp, 0x02, vrndp, .operands={RAB_OPERAND_rsp_vd, RAB_OPERAND_rsp_vs, RAB_OPERAND_rsp_vt_elementhigh}) +RABBITIZER_DEF_INSTR_ID(rsp, 0x03, vmulq, .operands={RAB_OPERAND_rsp_vd, RAB_OPERAND_rsp_vs, RAB_OPERAND_rsp_vt_elementhigh}) +RABBITIZER_DEF_INSTR_ID(rsp, 0x04, vmudl, .operands={RAB_OPERAND_rsp_vd, RAB_OPERAND_rsp_vs, RAB_OPERAND_rsp_vt_elementhigh}) +RABBITIZER_DEF_INSTR_ID(rsp, 0x05, vmudm, .operands={RAB_OPERAND_rsp_vd, RAB_OPERAND_rsp_vs, RAB_OPERAND_rsp_vt_elementhigh}) +RABBITIZER_DEF_INSTR_ID(rsp, 0x06, vmudn, .operands={RAB_OPERAND_rsp_vd, RAB_OPERAND_rsp_vs, RAB_OPERAND_rsp_vt_elementhigh}) +RABBITIZER_DEF_INSTR_ID(rsp, 0x07, vmudh, .operands={RAB_OPERAND_rsp_vd, RAB_OPERAND_rsp_vs, RAB_OPERAND_rsp_vt_elementhigh}) +RABBITIZER_DEF_INSTR_ID(rsp, 0x08, vmacf, .operands={RAB_OPERAND_rsp_vd, RAB_OPERAND_rsp_vs, RAB_OPERAND_rsp_vt_elementhigh}) +RABBITIZER_DEF_INSTR_ID(rsp, 0x09, vmacu, .operands={RAB_OPERAND_rsp_vd, RAB_OPERAND_rsp_vs, RAB_OPERAND_rsp_vt_elementhigh}) +RABBITIZER_DEF_INSTR_ID(rsp, 0x0A, vrndn, .operands={RAB_OPERAND_rsp_vd, RAB_OPERAND_rsp_vs, RAB_OPERAND_rsp_vt_elementhigh}) +RABBITIZER_DEF_INSTR_ID(rsp, 0x0B, vmacq, .operands={RAB_OPERAND_rsp_vd, RAB_OPERAND_rsp_vs, RAB_OPERAND_rsp_vt_elementhigh}) +RABBITIZER_DEF_INSTR_ID(rsp, 0x0C, vmadl, .operands={RAB_OPERAND_rsp_vd, RAB_OPERAND_rsp_vs, RAB_OPERAND_rsp_vt_elementhigh}) +RABBITIZER_DEF_INSTR_ID(rsp, 0x0D, vmadm, .operands={RAB_OPERAND_rsp_vd, RAB_OPERAND_rsp_vs, RAB_OPERAND_rsp_vt_elementhigh}) +RABBITIZER_DEF_INSTR_ID(rsp, 0x0E, vmadn, .operands={RAB_OPERAND_rsp_vd, RAB_OPERAND_rsp_vs, RAB_OPERAND_rsp_vt_elementhigh}) +RABBITIZER_DEF_INSTR_ID(rsp, 0x0F, vmadh, .operands={RAB_OPERAND_rsp_vd, RAB_OPERAND_rsp_vs, RAB_OPERAND_rsp_vt_elementhigh}) +RABBITIZER_DEF_INSTR_ID(rsp, 0x10, vadd, .operands={RAB_OPERAND_rsp_vd, RAB_OPERAND_rsp_vs, RAB_OPERAND_rsp_vt_elementhigh}) +RABBITIZER_DEF_INSTR_ID(rsp, 0x11, vsub, .operands={RAB_OPERAND_rsp_vd, RAB_OPERAND_rsp_vs, RAB_OPERAND_rsp_vt_elementhigh}) +RABBITIZER_DEF_INSTR_ID(rsp, 0x13, vabs, .operands={RAB_OPERAND_rsp_vd, RAB_OPERAND_rsp_vs, RAB_OPERAND_rsp_vt_elementhigh}) +RABBITIZER_DEF_INSTR_ID(rsp, 0x14, vaddc, .operands={RAB_OPERAND_rsp_vd, RAB_OPERAND_rsp_vs, RAB_OPERAND_rsp_vt_elementhigh}) +RABBITIZER_DEF_INSTR_ID(rsp, 0x15, vsubc, .operands={RAB_OPERAND_rsp_vd, RAB_OPERAND_rsp_vs, RAB_OPERAND_rsp_vt_elementhigh}) +RABBITIZER_DEF_INSTR_ID(rsp, 0x1D, vsar, .operands={RAB_OPERAND_rsp_vd, RAB_OPERAND_rsp_vs, RAB_OPERAND_rsp_vt_elementhigh}) +RABBITIZER_DEF_INSTR_ID(rsp, 0x28, vand, .operands={RAB_OPERAND_rsp_vd, RAB_OPERAND_rsp_vs, RAB_OPERAND_rsp_vt_elementhigh}) +RABBITIZER_DEF_INSTR_ID(rsp, 0x29, vnand, .operands={RAB_OPERAND_rsp_vd, RAB_OPERAND_rsp_vs, RAB_OPERAND_rsp_vt_elementhigh}) +RABBITIZER_DEF_INSTR_ID(rsp, 0x2A, vor, .operands={RAB_OPERAND_rsp_vd, RAB_OPERAND_rsp_vs, RAB_OPERAND_rsp_vt_elementhigh}) +RABBITIZER_DEF_INSTR_ID(rsp, 0x2B, vnor, .operands={RAB_OPERAND_rsp_vd, RAB_OPERAND_rsp_vs, RAB_OPERAND_rsp_vt_elementhigh}) +RABBITIZER_DEF_INSTR_ID(rsp, 0x2C, vxor, .operands={RAB_OPERAND_rsp_vd, RAB_OPERAND_rsp_vs, RAB_OPERAND_rsp_vt_elementhigh}) +RABBITIZER_DEF_INSTR_ID(rsp, 0x2D, vnxor, .operands={RAB_OPERAND_rsp_vd, RAB_OPERAND_rsp_vs, RAB_OPERAND_rsp_vt_elementhigh}) + +RABBITIZER_DEF_INSTR_ID(rsp, 0x20, vlt, .operands={RAB_OPERAND_rsp_vd, RAB_OPERAND_rsp_vs, RAB_OPERAND_rsp_vt_elementhigh}) +RABBITIZER_DEF_INSTR_ID(rsp, 0x21, veq, .operands={RAB_OPERAND_rsp_vd, RAB_OPERAND_rsp_vs, RAB_OPERAND_rsp_vt_elementhigh}) +RABBITIZER_DEF_INSTR_ID(rsp, 0x22, vne, .operands={RAB_OPERAND_rsp_vd, RAB_OPERAND_rsp_vs, RAB_OPERAND_rsp_vt_elementhigh}) +RABBITIZER_DEF_INSTR_ID(rsp, 0x23, vge, .operands={RAB_OPERAND_rsp_vd, RAB_OPERAND_rsp_vs, RAB_OPERAND_rsp_vt_elementhigh}) +RABBITIZER_DEF_INSTR_ID(rsp, 0x24, vcl, .operands={RAB_OPERAND_rsp_vd, RAB_OPERAND_rsp_vs, RAB_OPERAND_rsp_vt_elementhigh}) +RABBITIZER_DEF_INSTR_ID(rsp, 0x25, vch, .operands={RAB_OPERAND_rsp_vd, RAB_OPERAND_rsp_vs, RAB_OPERAND_rsp_vt_elementhigh}) +RABBITIZER_DEF_INSTR_ID(rsp, 0x26, vcr, .operands={RAB_OPERAND_rsp_vd, RAB_OPERAND_rsp_vs, RAB_OPERAND_rsp_vt_elementhigh}) +RABBITIZER_DEF_INSTR_ID(rsp, 0x27, vmrg, .operands={RAB_OPERAND_rsp_vd, RAB_OPERAND_rsp_vs, RAB_OPERAND_rsp_vt_elementhigh}) + +// OP vd[de], vt[elementhigh] +RABBITIZER_DEF_INSTR_ID(rsp, 0x30, vrcp, .operands={RAB_OPERAND_rsp_vd_de, RAB_OPERAND_rsp_vt_elementhigh}) +RABBITIZER_DEF_INSTR_ID(rsp, 0x31, vrcpl, .operands={RAB_OPERAND_rsp_vd_de, RAB_OPERAND_rsp_vt_elementhigh}) // operands may be wrong +RABBITIZER_DEF_INSTR_ID(rsp, 0x32, vrcph, .operands={RAB_OPERAND_rsp_vd_de, RAB_OPERAND_rsp_vt_elementhigh}) +RABBITIZER_DEF_INSTR_ID(rsp, 0x33, vmov, .operands={RAB_OPERAND_rsp_vd_de, RAB_OPERAND_rsp_vt_elementhigh}) +RABBITIZER_DEF_INSTR_ID(rsp, 0x34, vrsq, .operands={RAB_OPERAND_rsp_vd_de, RAB_OPERAND_rsp_vt_elementhigh}) +RABBITIZER_DEF_INSTR_ID(rsp, 0x35, vrsql, .operands={RAB_OPERAND_rsp_vd_de, RAB_OPERAND_rsp_vt_elementhigh}) +RABBITIZER_DEF_INSTR_ID(rsp, 0x36, vrsqh, .operands={RAB_OPERAND_rsp_vd_de, RAB_OPERAND_rsp_vt_elementhigh}) + +// OP +RABBITIZER_DEF_INSTR_ID(rsp, 0x37, vnop, .operands={0}) diff --git a/tools/ido-static-recomp/tools/rabbitizer/include/instructions/instr_id/rsp/rsp_normal.inc b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/instr_id/rsp/rsp_normal.inc new file mode 100644 index 00000000..be73f5a0 --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/instr_id/rsp/rsp_normal.inc @@ -0,0 +1,53 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +// OP LABEL +RABBITIZER_DEF_INSTR_ID(rsp, 0x02, j, .operands={RAB_OPERAND_cpu_label}, .instrType=RABBITIZER_INSTR_TYPE_J, .isJump=true) // Jump +RABBITIZER_DEF_INSTR_ID(rsp, 0x03, jal, .operands={RAB_OPERAND_cpu_label}, .instrType=RABBITIZER_INSTR_TYPE_J, .isJump=true, .doesLink=true) // Jump And Link + +// OP rs, rt, IMM +RABBITIZER_DEF_INSTR_ID(rsp, 0x04, beq, .operands={RAB_OPERAND_rsp_rs, RAB_OPERAND_rsp_rt, RAB_OPERAND_cpu_branch_target_label}, .instrType=RABBITIZER_INSTR_TYPE_REGIMM, .isBranch=true) // Branch on EQual +RABBITIZER_DEF_INSTR_ID(rsp, 0x05, bne, .operands={RAB_OPERAND_rsp_rs, RAB_OPERAND_rsp_rt, RAB_OPERAND_cpu_branch_target_label}, .instrType=RABBITIZER_INSTR_TYPE_REGIMM, .isBranch=true) // Branch on Not Equal + +// OP rs, IMM +RABBITIZER_DEF_INSTR_ID(rsp, 0x06, blez, .operands={RAB_OPERAND_rsp_rs, RAB_OPERAND_cpu_branch_target_label}, .instrType=RABBITIZER_INSTR_TYPE_REGIMM, .isBranch=true) // Branch on Less than or Equal to Zero +RABBITIZER_DEF_INSTR_ID(rsp, 0x07, bgtz, .operands={RAB_OPERAND_rsp_rs, RAB_OPERAND_cpu_branch_target_label}, .instrType=RABBITIZER_INSTR_TYPE_REGIMM, .isBranch=true) // Branch on Greater Than Zero + +// OP rt, rs, IMM +RABBITIZER_DEF_INSTR_ID(rsp, 0x08, addi, .operands={RAB_OPERAND_rsp_rt, RAB_OPERAND_rsp_rs, RAB_OPERAND_cpu_immediate}, .instrType=RABBITIZER_INSTR_TYPE_I, .modifiesRt=true, .notEmitedByCompilers=true, .canBeLo=true) // Add Immediate +RABBITIZER_DEF_INSTR_ID(rsp, 0x09, addiu, .operands={RAB_OPERAND_rsp_rt, RAB_OPERAND_rsp_rs, RAB_OPERAND_cpu_immediate}, .instrType=RABBITIZER_INSTR_TYPE_I, .modifiesRt=true, .canBeLo=true) // Add Immediate Unsigned Word +RABBITIZER_DEF_INSTR_ID(rsp, 0x0A, slti, .operands={RAB_OPERAND_rsp_rt, RAB_OPERAND_rsp_rs, RAB_OPERAND_cpu_immediate}, .instrType=RABBITIZER_INSTR_TYPE_I, .modifiesRt=true) // Set on Less Than Immediate +RABBITIZER_DEF_INSTR_ID(rsp, 0x0B, sltiu, .operands={RAB_OPERAND_rsp_rt, RAB_OPERAND_rsp_rs, RAB_OPERAND_cpu_immediate}, .instrType=RABBITIZER_INSTR_TYPE_I, .modifiesRt=true) // Set on Less Than Immediate Unsigned +RABBITIZER_DEF_INSTR_ID(rsp, 0x0C, andi, .operands={RAB_OPERAND_rsp_rt, RAB_OPERAND_rsp_rs, RAB_OPERAND_cpu_immediate}, .instrType=RABBITIZER_INSTR_TYPE_I, .isUnsigned=true, .modifiesRt=true) // And Immediate +RABBITIZER_DEF_INSTR_ID(rsp, 0x0D, ori, .operands={RAB_OPERAND_rsp_rt, RAB_OPERAND_rsp_rs, RAB_OPERAND_cpu_immediate}, .instrType=RABBITIZER_INSTR_TYPE_I, .isUnsigned=true, .modifiesRt=true, .canBeLo=true) // Or Immediate +RABBITIZER_DEF_INSTR_ID(rsp, 0x0E, xori, .operands={RAB_OPERAND_rsp_rt, RAB_OPERAND_rsp_rs, RAB_OPERAND_cpu_immediate}, .instrType=RABBITIZER_INSTR_TYPE_I, .isUnsigned=true, .modifiesRt=true) // eXclusive OR Immediate + +// OP rt, IMM +RABBITIZER_DEF_INSTR_ID(rsp, 0x0F, lui, .operands={RAB_OPERAND_rsp_rt, RAB_OPERAND_cpu_immediate}, .instrType=RABBITIZER_INSTR_TYPE_I, .isUnsigned=true, .modifiesRt=true, .canBeHi=true) // Load Upper Immediate + +// OP rt, IMM(base) +RABBITIZER_DEF_INSTR_ID(rsp, 0x20, lb, .operands={RAB_OPERAND_rsp_rt, RAB_OPERAND_rsp_immediate_base}, .instrType=RABBITIZER_INSTR_TYPE_I, .modifiesRt=true, .canBeLo=true, .doesDereference=true, .doesLoad=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_I) // Load Byte +RABBITIZER_DEF_INSTR_ID(rsp, 0x21, lh, .operands={RAB_OPERAND_rsp_rt, RAB_OPERAND_rsp_immediate_base}, .instrType=RABBITIZER_INSTR_TYPE_I, .modifiesRt=true, .canBeLo=true, .doesDereference=true, .doesLoad=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_I) // Load Halfword +RABBITIZER_DEF_INSTR_ID(rsp, 0x23, lw, .operands={RAB_OPERAND_rsp_rt, RAB_OPERAND_rsp_immediate_base}, .instrType=RABBITIZER_INSTR_TYPE_I, .modifiesRt=true, .canBeLo=true, .doesDereference=true, .doesLoad=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_I) // Load Word +RABBITIZER_DEF_INSTR_ID(rsp, 0x24, lbu, .operands={RAB_OPERAND_rsp_rt, RAB_OPERAND_rsp_immediate_base}, .instrType=RABBITIZER_INSTR_TYPE_I, .modifiesRt=true, .canBeLo=true, .doesDereference=true, .doesLoad=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_I) // Load Byte Insigned +RABBITIZER_DEF_INSTR_ID(rsp, 0x25, lhu, .operands={RAB_OPERAND_rsp_rt, RAB_OPERAND_rsp_immediate_base}, .instrType=RABBITIZER_INSTR_TYPE_I, .modifiesRt=true, .canBeLo=true, .doesDereference=true, .doesLoad=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_I) // Load Halfword Unsigned +RABBITIZER_DEF_INSTR_ID(rsp, 0x28, sb, .operands={RAB_OPERAND_rsp_rt, RAB_OPERAND_rsp_immediate_base}, .instrType=RABBITIZER_INSTR_TYPE_I, .canBeLo=true, .doesDereference=true, .doesStore=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_I) // Store Byte +RABBITIZER_DEF_INSTR_ID(rsp, 0x29, sh, .operands={RAB_OPERAND_rsp_rt, RAB_OPERAND_rsp_immediate_base}, .instrType=RABBITIZER_INSTR_TYPE_I, .canBeLo=true, .doesDereference=true, .doesStore=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_I) // Store Halfword +RABBITIZER_DEF_INSTR_ID(rsp, 0x2B, sw, .operands={RAB_OPERAND_rsp_rt, RAB_OPERAND_rsp_immediate_base}, .instrType=RABBITIZER_INSTR_TYPE_I, .canBeLo=true, .doesDereference=true, .doesStore=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_I) // Store Word +RABBITIZER_DEF_INSTR_ID(rsp, 0x33, pref, .operands={RAB_OPERAND_rsp_rt, RAB_OPERAND_rsp_immediate_base}, .instrType=RABBITIZER_INSTR_TYPE_I, .modifiesRt=true, .canBeLo=true, .doesDereference=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_IV) // Prefetch + +RABBITIZER_DEF_INSTR_ID(rsp, 0x2F, cache, .operands={RAB_OPERAND_cpu_op, RAB_OPERAND_rsp_immediate_base}, .instrType=RABBITIZER_INSTR_TYPE_I, .notEmitedByCompilers=true) // Cache + +// OP ft, IMM(base) +RABBITIZER_DEF_INSTR_ID(rsp, 0x31, lwc1, .operands={RAB_OPERAND_cpu_ft, RAB_OPERAND_rsp_immediate_base}, .instrType=RABBITIZER_INSTR_TYPE_I, .isFloat=true, .canBeLo=true, .doesDereference=true, .doesLoad=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_I) // Load Word to Coprocessor z +RABBITIZER_DEF_INSTR_ID(rsp, 0x39, swc1, .operands={RAB_OPERAND_cpu_ft, RAB_OPERAND_rsp_immediate_base}, .instrType=RABBITIZER_INSTR_TYPE_I, .isFloat=true, .canBeLo=true, .doesDereference=true, .doesStore=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_I) // Store Word from Coprocessor z + + +// Pseudo-Instruction Unique IDs + +// OP IMM +RABBITIZER_DEF_INSTR_ID(rsp, -0x03, b, .operands={RAB_OPERAND_cpu_branch_target_label}, .instrType=RABBITIZER_INSTR_TYPE_REGIMM, .isBranch=true) // Branch (unconditional) + +// OP rs, IMM +RABBITIZER_DEF_INSTR_ID(rsp, -0x04, beqz, .operands={RAB_OPERAND_rsp_rs, RAB_OPERAND_cpu_branch_target_label}, .instrType=RABBITIZER_INSTR_TYPE_REGIMM, .isBranch=true) // Branch on EQual Zero +RABBITIZER_DEF_INSTR_ID(rsp, -0x05, bnez, .operands={RAB_OPERAND_rsp_rs, RAB_OPERAND_cpu_branch_target_label}, .instrType=RABBITIZER_INSTR_TYPE_REGIMM, .isBranch=true) // Branch on Not Equal Zero diff --git a/tools/ido-static-recomp/tools/rabbitizer/include/instructions/instr_id/rsp/rsp_normal_lwc2.inc b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/instr_id/rsp/rsp_normal_lwc2.inc new file mode 100644 index 00000000..4440fb09 --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/instr_id/rsp/rsp_normal_lwc2.inc @@ -0,0 +1,15 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +// OP vt[elementlow], offset(vs) +RABBITIZER_DEF_INSTR_ID(rsp, 0x00, lbv, .operands={RAB_OPERAND_rsp_vt_elementlow, RAB_OPERAND_rsp_offset_rs}) +RABBITIZER_DEF_INSTR_ID(rsp, 0x01, lsv, .operands={RAB_OPERAND_rsp_vt_elementlow, RAB_OPERAND_rsp_offset_rs}) +RABBITIZER_DEF_INSTR_ID(rsp, 0x02, llv, .operands={RAB_OPERAND_rsp_vt_elementlow, RAB_OPERAND_rsp_offset_rs}) +RABBITIZER_DEF_INSTR_ID(rsp, 0x03, ldv, .operands={RAB_OPERAND_rsp_vt_elementlow, RAB_OPERAND_rsp_offset_rs}) +RABBITIZER_DEF_INSTR_ID(rsp, 0x04, lqv, .operands={RAB_OPERAND_rsp_vt_elementlow, RAB_OPERAND_rsp_offset_rs}) +RABBITIZER_DEF_INSTR_ID(rsp, 0x05, lrv, .operands={RAB_OPERAND_rsp_vt_elementlow, RAB_OPERAND_rsp_offset_rs}) +RABBITIZER_DEF_INSTR_ID(rsp, 0x06, lpv, .operands={RAB_OPERAND_rsp_vt_elementlow, RAB_OPERAND_rsp_offset_rs}) +RABBITIZER_DEF_INSTR_ID(rsp, 0x07, luv, .operands={RAB_OPERAND_rsp_vt_elementlow, RAB_OPERAND_rsp_offset_rs}) +RABBITIZER_DEF_INSTR_ID(rsp, 0x08, lhv, .operands={RAB_OPERAND_rsp_vt_elementlow, RAB_OPERAND_rsp_offset_rs}) +RABBITIZER_DEF_INSTR_ID(rsp, 0x09, lfv, .operands={RAB_OPERAND_rsp_vt_elementlow, RAB_OPERAND_rsp_offset_rs}) +RABBITIZER_DEF_INSTR_ID(rsp, 0x0B, ltv, .operands={RAB_OPERAND_rsp_vt_elementlow, RAB_OPERAND_rsp_offset_rs}) diff --git a/tools/ido-static-recomp/tools/rabbitizer/include/instructions/instr_id/rsp/rsp_normal_swc2.inc b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/instr_id/rsp/rsp_normal_swc2.inc new file mode 100644 index 00000000..996c69f2 --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/instr_id/rsp/rsp_normal_swc2.inc @@ -0,0 +1,17 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +// OP vt[elementlow], offset(vs) +RABBITIZER_DEF_INSTR_ID(rsp, 0x00, sbv, .operands={RAB_OPERAND_rsp_vt_elementlow, RAB_OPERAND_rsp_offset_rs}) +RABBITIZER_DEF_INSTR_ID(rsp, 0x01, ssv, .operands={RAB_OPERAND_rsp_vt_elementlow, RAB_OPERAND_rsp_offset_rs}) +RABBITIZER_DEF_INSTR_ID(rsp, 0x02, slv, .operands={RAB_OPERAND_rsp_vt_elementlow, RAB_OPERAND_rsp_offset_rs}) +RABBITIZER_DEF_INSTR_ID(rsp, 0x03, sdv, .operands={RAB_OPERAND_rsp_vt_elementlow, RAB_OPERAND_rsp_offset_rs}) +RABBITIZER_DEF_INSTR_ID(rsp, 0x04, sqv, .operands={RAB_OPERAND_rsp_vt_elementlow, RAB_OPERAND_rsp_offset_rs}) +RABBITIZER_DEF_INSTR_ID(rsp, 0x05, srv, .operands={RAB_OPERAND_rsp_vt_elementlow, RAB_OPERAND_rsp_offset_rs}) +RABBITIZER_DEF_INSTR_ID(rsp, 0x06, spv, .operands={RAB_OPERAND_rsp_vt_elementlow, RAB_OPERAND_rsp_offset_rs}) +RABBITIZER_DEF_INSTR_ID(rsp, 0x07, suv, .operands={RAB_OPERAND_rsp_vt_elementlow, RAB_OPERAND_rsp_offset_rs}) +RABBITIZER_DEF_INSTR_ID(rsp, 0x08, shv, .operands={RAB_OPERAND_rsp_vt_elementlow, RAB_OPERAND_rsp_offset_rs}) +RABBITIZER_DEF_INSTR_ID(rsp, 0x09, sfv, .operands={RAB_OPERAND_rsp_vt_elementlow, RAB_OPERAND_rsp_offset_rs}) +RABBITIZER_DEF_INSTR_ID(rsp, 0x0B, stv, .operands={RAB_OPERAND_rsp_vt_elementlow, RAB_OPERAND_rsp_offset_rs}) + +RABBITIZER_DEF_INSTR_ID(rsp, -0x07, swv, .operands={RAB_OPERAND_rsp_vt_elementlow, RAB_OPERAND_rsp_offset_rs}) diff --git a/tools/ido-static-recomp/tools/rabbitizer/include/instructions/instr_id/rsp/rsp_regimm.inc b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/instr_id/rsp/rsp_regimm.inc new file mode 100644 index 00000000..c2132f94 --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/instr_id/rsp/rsp_regimm.inc @@ -0,0 +1,14 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +// OP rs, IMM +RABBITIZER_DEF_INSTR_ID(rsp, 0x00, bltz, .operands={RAB_OPERAND_rsp_rs, RAB_OPERAND_cpu_branch_target_label}, .instrType=RABBITIZER_INSTR_TYPE_REGIMM, .isBranch=true) // Branch on Less Than Zero +RABBITIZER_DEF_INSTR_ID(rsp, 0x01, bgez, .operands={RAB_OPERAND_rsp_rs, RAB_OPERAND_cpu_branch_target_label}, .instrType=RABBITIZER_INSTR_TYPE_REGIMM, .isBranch=true) // Branch on Greater than or Equal to Zero + +RABBITIZER_DEF_INSTR_ID(rsp, 0x10, bltzal, .operands={RAB_OPERAND_rsp_rs, RAB_OPERAND_cpu_branch_target_label}, .instrType=RABBITIZER_INSTR_TYPE_REGIMM, .isBranch=true, .doesLink=true) // Branch on Less Than Zero and Link +RABBITIZER_DEF_INSTR_ID(rsp, 0x11, bgezal, .operands={RAB_OPERAND_rsp_rs, RAB_OPERAND_cpu_branch_target_label}, .instrType=RABBITIZER_INSTR_TYPE_REGIMM, .isBranch=true, .doesLink=true) // Branch on Greater Than or Equal to Zero and Link + + +// Pseudo-Instruction Unique IDs + +RABBITIZER_DEF_INSTR_ID(rsp, -0x11, bal, .operands={RAB_OPERAND_cpu_branch_target_label}, .instrType=RABBITIZER_INSTR_TYPE_REGIMM, .isBranch=true, .doesLink=true, .isPseudo=true, .architectureVersion=RABBITIZER_ARCHVERSION_MIPS_I) // Branch and Link diff --git a/tools/ido-static-recomp/tools/rabbitizer/include/instructions/instr_id/rsp/rsp_special.inc b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/instr_id/rsp/rsp_special.inc new file mode 100644 index 00000000..9f12212d --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/instr_id/rsp/rsp_special.inc @@ -0,0 +1,49 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +// OP rd, rt, sa +RABBITIZER_DEF_INSTR_ID(rsp, 0x00, sll, .operands={RAB_OPERAND_rsp_rd, RAB_OPERAND_rsp_rt, RAB_OPERAND_cpu_sa}, .instrType=RABBITIZER_INSTR_TYPE_R, .modifiesRd=true) // Shift word Left Logical +RABBITIZER_DEF_INSTR_ID(rsp, 0x02, srl, .operands={RAB_OPERAND_rsp_rd, RAB_OPERAND_rsp_rt, RAB_OPERAND_cpu_sa}, .instrType=RABBITIZER_INSTR_TYPE_R, .modifiesRd=true) // Shift word Right Logical +RABBITIZER_DEF_INSTR_ID(rsp, 0x03, sra, .operands={RAB_OPERAND_rsp_rd, RAB_OPERAND_rsp_rt, RAB_OPERAND_cpu_sa}, .instrType=RABBITIZER_INSTR_TYPE_R, .modifiesRd=true) // Shift word Right Arithmetic + +// OP rd, rt, rs +RABBITIZER_DEF_INSTR_ID(rsp, 0x04, sllv, .operands={RAB_OPERAND_rsp_rd, RAB_OPERAND_rsp_rt, RAB_OPERAND_rsp_rs}, .instrType=RABBITIZER_INSTR_TYPE_R, .modifiesRd=true) // Shift word Left Logical Variable +RABBITIZER_DEF_INSTR_ID(rsp, 0x06, srlv, .operands={RAB_OPERAND_rsp_rd, RAB_OPERAND_rsp_rt, RAB_OPERAND_rsp_rs}, .instrType=RABBITIZER_INSTR_TYPE_R, .modifiesRd=true) // Shift word Right Logical Variable +RABBITIZER_DEF_INSTR_ID(rsp, 0x07, srav, .operands={RAB_OPERAND_rsp_rd, RAB_OPERAND_rsp_rt, RAB_OPERAND_rsp_rs}, .instrType=RABBITIZER_INSTR_TYPE_R, .modifiesRd=true) // Shift word Right Arithmetic Variable + +// OP rs +RABBITIZER_DEF_INSTR_ID(rsp, 0x08, jr, .operands={RAB_OPERAND_rsp_rs}, .instrType=RABBITIZER_INSTR_TYPE_R, .isJump=true) // Jump Register +RABBITIZER_DEF_INSTR_ID(rsp, 0x09, jalr, .operands={RAB_OPERAND_rsp_rs}, .instrType=RABBITIZER_INSTR_TYPE_R, .isJump=true, .modifiesRd=true, .doesLink=true) // Jump And Link Register + +// OP rd, rs +RABBITIZER_DEF_INSTR_ID_ALTNAME(rsp, -0x09, jalr_rd, jalr, .operands={RAB_OPERAND_rsp_rd, RAB_OPERAND_rsp_rs}, .instrType=RABBITIZER_INSTR_TYPE_R, .isJump=true, .modifiesRd=true, .doesLink=true) // Jump And Link Register // Special case for rd != 31 + +// OP rd, rs, rt +RABBITIZER_DEF_INSTR_ID(rsp, 0x0A, movz, .operands={RAB_OPERAND_rsp_rd, RAB_OPERAND_rsp_rs, RAB_OPERAND_rsp_rt}, .instrType=RABBITIZER_INSTR_TYPE_R, .modifiesRd=true) // MOVe conditional on Zero +RABBITIZER_DEF_INSTR_ID(rsp, 0x0B, movn, .operands={RAB_OPERAND_rsp_rd, RAB_OPERAND_rsp_rs, RAB_OPERAND_rsp_rt}, .instrType=RABBITIZER_INSTR_TYPE_R, .modifiesRd=true) // MOVe conditional on Not zero + +RABBITIZER_DEF_INSTR_ID(rsp, 0x20, add, .operands={RAB_OPERAND_rsp_rd, RAB_OPERAND_rsp_rs, RAB_OPERAND_rsp_rt}, .instrType=RABBITIZER_INSTR_TYPE_R, .modifiesRd=true, .notEmitedByCompilers=true) // ADD word +RABBITIZER_DEF_INSTR_ID(rsp, 0x21, addu, .operands={RAB_OPERAND_rsp_rd, RAB_OPERAND_rsp_rs, RAB_OPERAND_rsp_rt}, .instrType=RABBITIZER_INSTR_TYPE_R, .modifiesRd=true) // ADD Unsigned word +RABBITIZER_DEF_INSTR_ID(rsp, 0x22, sub, .operands={RAB_OPERAND_rsp_rd, RAB_OPERAND_rsp_rs, RAB_OPERAND_rsp_rt}, .instrType=RABBITIZER_INSTR_TYPE_R, .modifiesRd=true) // Subtract word +RABBITIZER_DEF_INSTR_ID(rsp, 0x23, subu, .operands={RAB_OPERAND_rsp_rd, RAB_OPERAND_rsp_rs, RAB_OPERAND_rsp_rt}, .instrType=RABBITIZER_INSTR_TYPE_R, .modifiesRd=true) // SUBtract Unsigned word +RABBITIZER_DEF_INSTR_ID(rsp, 0x24, and, .operands={RAB_OPERAND_rsp_rd, RAB_OPERAND_rsp_rs, RAB_OPERAND_rsp_rt}, .instrType=RABBITIZER_INSTR_TYPE_R, .modifiesRd=true) // AND +RABBITIZER_DEF_INSTR_ID(rsp, 0x25, or, .operands={RAB_OPERAND_rsp_rd, RAB_OPERAND_rsp_rs, RAB_OPERAND_rsp_rt}, .instrType=RABBITIZER_INSTR_TYPE_R, .modifiesRd=true) // OR +RABBITIZER_DEF_INSTR_ID(rsp, 0x26, xor, .operands={RAB_OPERAND_rsp_rd, RAB_OPERAND_rsp_rs, RAB_OPERAND_rsp_rt}, .instrType=RABBITIZER_INSTR_TYPE_R, .modifiesRd=true) // eXclusive OR +RABBITIZER_DEF_INSTR_ID(rsp, 0x27, nor, .operands={RAB_OPERAND_rsp_rd, RAB_OPERAND_rsp_rs, RAB_OPERAND_rsp_rt}, .instrType=RABBITIZER_INSTR_TYPE_R, .modifiesRd=true) // Not OR +RABBITIZER_DEF_INSTR_ID(rsp, 0x2A, slt, .operands={RAB_OPERAND_rsp_rd, RAB_OPERAND_rsp_rs, RAB_OPERAND_rsp_rt}, .instrType=RABBITIZER_INSTR_TYPE_R, .modifiesRd=true) // Set on Less Than +RABBITIZER_DEF_INSTR_ID(rsp, 0x2B, sltu, .operands={RAB_OPERAND_rsp_rd, RAB_OPERAND_rsp_rs, RAB_OPERAND_rsp_rt}, .instrType=RABBITIZER_INSTR_TYPE_R, .modifiesRd=true) // Set on Less Than Unsigned + +// OP code +RABBITIZER_DEF_INSTR_ID(rsp, 0x0D, break, .operands={RAB_OPERAND_cpu_code}, .instrType=RABBITIZER_INSTR_TYPE_R) // Break + + +// Pseudo-Instruction Unique IDs +// OP +RABBITIZER_DEF_INSTR_ID(rsp, -0x01, nop, .operands={0}, .instrType=RABBITIZER_INSTR_TYPE_R) // No OPeration + +// OP rd, rs +RABBITIZER_DEF_INSTR_ID(rsp, -0x25, move, .operands={RAB_OPERAND_rsp_rd, RAB_OPERAND_rsp_rs}, .instrType=RABBITIZER_INSTR_TYPE_R, .modifiesRd=true) // Move +RABBITIZER_DEF_INSTR_ID(rsp, -0x27, not, .operands={RAB_OPERAND_rsp_rd, RAB_OPERAND_rsp_rs}, .instrType=RABBITIZER_INSTR_TYPE_R, .modifiesRd=true) // Not + +// OP rd, rt +RABBITIZER_DEF_INSTR_ID(rsp, -0x23, negu, .operands={RAB_OPERAND_rsp_rd, RAB_OPERAND_rsp_rt}, .instrType=RABBITIZER_INSTR_TYPE_R, .modifiesRd=true) diff --git a/tools/ido-static-recomp/tools/rabbitizer/include/instructions/operands/RabbitizerOperandType_cpu.inc b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/operands/RabbitizerOperandType_cpu.inc new file mode 100644 index 00000000..bb863366 --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/operands/RabbitizerOperandType_cpu.inc @@ -0,0 +1,25 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +RAB_DEF_OPERAND(cpu, rs) +RAB_DEF_OPERAND(cpu, rt) +RAB_DEF_OPERAND(cpu, rd) +RAB_DEF_OPERAND(cpu, sa) +RAB_DEF_OPERAND(cpu, zero) // $zero +// RAB_DEF_OPERAND(cpu, function) +RAB_DEF_OPERAND(cpu, cop0d) +RAB_DEF_OPERAND(cpu, fs) +RAB_DEF_OPERAND(cpu, ft) +RAB_DEF_OPERAND(cpu, fd) +RAB_DEF_OPERAND(cpu, cop1cs) // Coprocessor 1 control fs +RAB_DEF_OPERAND(cpu, cop2t) +RAB_DEF_OPERAND(cpu, op) +RAB_DEF_OPERAND(cpu, code) +RAB_DEF_OPERAND(cpu, code_lower) +RAB_DEF_OPERAND(cpu, copraw) +RAB_DEF_OPERAND(cpu, label) +RAB_DEF_OPERAND(cpu, immediate) +RAB_DEF_OPERAND(cpu, branch_target_label) + +// composed/aliased operands +RAB_DEF_OPERAND(cpu, immediate_base) diff --git a/tools/ido-static-recomp/tools/rabbitizer/include/instructions/operands/RabbitizerOperandType_r5900.inc b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/operands/RabbitizerOperandType_r5900.inc new file mode 100644 index 00000000..36cb6efc --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/operands/RabbitizerOperandType_r5900.inc @@ -0,0 +1,33 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +RAB_DEF_OPERAND(r5900, I) +RAB_DEF_OPERAND(r5900, Q) +RAB_DEF_OPERAND(r5900, R) +RAB_DEF_OPERAND(r5900, ACC) +RAB_DEF_OPERAND(r5900, ACCxyzw) +RAB_DEF_OPERAND(r5900, vfs) +RAB_DEF_OPERAND(r5900, vft) +RAB_DEF_OPERAND(r5900, vfd) +RAB_DEF_OPERAND(r5900, vfsxyzw) +RAB_DEF_OPERAND(r5900, vftxyzw) +RAB_DEF_OPERAND(r5900, vfdxyzw) +RAB_DEF_OPERAND(r5900, vfsn) +RAB_DEF_OPERAND(r5900, vftn) +RAB_DEF_OPERAND(r5900, vfdn) +RAB_DEF_OPERAND(r5900, vfsl) +RAB_DEF_OPERAND(r5900, vftl) +RAB_DEF_OPERAND(r5900, vfdl) +RAB_DEF_OPERAND(r5900, vfsm) +RAB_DEF_OPERAND(r5900, vftm) +RAB_DEF_OPERAND(r5900, vfdm) +RAB_DEF_OPERAND(r5900, vis) +RAB_DEF_OPERAND(r5900, vit) +RAB_DEF_OPERAND(r5900, vid) +RAB_DEF_OPERAND(r5900, vis_predecr) +RAB_DEF_OPERAND(r5900, vit_predecr) +RAB_DEF_OPERAND(r5900, vid_predecr) +RAB_DEF_OPERAND(r5900, vis_postincr) +RAB_DEF_OPERAND(r5900, vit_postincr) +RAB_DEF_OPERAND(r5900, vid_postincr) +RAB_DEF_OPERAND(r5900, immediate5) diff --git a/tools/ido-static-recomp/tools/rabbitizer/include/instructions/operands/RabbitizerOperandType_rsp.inc b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/operands/RabbitizerOperandType_rsp.inc new file mode 100644 index 00000000..7bae435d --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/operands/RabbitizerOperandType_rsp.inc @@ -0,0 +1,24 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +RAB_DEF_OPERAND(rsp, rs) +RAB_DEF_OPERAND(rsp, rt) +RAB_DEF_OPERAND(rsp, rd) +RAB_DEF_OPERAND(rsp, cop0d) +RAB_DEF_OPERAND(rsp, cop2t) +RAB_DEF_OPERAND(rsp, cop2cd) // Coprocessor 2 control rd +RAB_DEF_OPERAND(rsp, vs) +RAB_DEF_OPERAND(rsp, vt) +RAB_DEF_OPERAND(rsp, vd) +// RAB_DEF_OPERAND(rsp, elementhigh) +// RAB_DEF_OPERAND(rsp, elementlow) +// RAB_DEF_OPERAND(rsp, index) +// RAB_DEF_OPERAND(rsp, offset) + +// composed/aliased operands +RAB_DEF_OPERAND(rsp, vt_elementhigh) +RAB_DEF_OPERAND(rsp, vt_elementlow) +RAB_DEF_OPERAND(rsp, vd_de) +RAB_DEF_OPERAND(rsp, vs_index) +RAB_DEF_OPERAND(rsp, offset_rs) +RAB_DEF_OPERAND(rsp, immediate_base) diff --git a/tools/ido-static-recomp/tools/rabbitizer/include/instructions/registers/RabbitizerRegister_Cop0.inc b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/registers/RabbitizerRegister_Cop0.inc new file mode 100644 index 00000000..9d3d63d2 --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/registers/RabbitizerRegister_Cop0.inc @@ -0,0 +1,35 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + + RABBITIZER_DEF_REG_NODOLLAR(COP0, Index, 0), + RABBITIZER_DEF_REG_NODOLLAR(COP0, Random, 1), + RABBITIZER_DEF_REG_NODOLLAR(COP0, EntryLo0, 2), + RABBITIZER_DEF_REG_NODOLLAR(COP0, EntryLo1, 3), + RABBITIZER_DEF_REG_NODOLLAR(COP0, Context, 4), + RABBITIZER_DEF_REG_NODOLLAR(COP0, PageMask, 5), + RABBITIZER_DEF_REG_NODOLLAR(COP0, Wired, 6), + RABBITIZER_DEF_REG_NODOLLAR(COP0, Reserved07, 7), + RABBITIZER_DEF_REG_NODOLLAR(COP0, BadVaddr, 8), + RABBITIZER_DEF_REG_NODOLLAR(COP0, Count, 9), + RABBITIZER_DEF_REG_NODOLLAR(COP0, EntryHi, 10), + RABBITIZER_DEF_REG_NODOLLAR(COP0, Compare, 11), + RABBITIZER_DEF_REG_NODOLLAR(COP0, Status, 12), + RABBITIZER_DEF_REG_NODOLLAR(COP0, Cause, 13), + RABBITIZER_DEF_REG_NODOLLAR(COP0, EPC, 14), + RABBITIZER_DEF_REG_NODOLLAR(COP0, PRevID, 15), + RABBITIZER_DEF_REG_NODOLLAR(COP0, Config, 16), + RABBITIZER_DEF_REG_NODOLLAR(COP0, LLAddr, 17), + RABBITIZER_DEF_REG_NODOLLAR(COP0, WatchLo, 18), + RABBITIZER_DEF_REG_NODOLLAR(COP0, WatchHi, 19), + RABBITIZER_DEF_REG_NODOLLAR(COP0, XContext, 20), + RABBITIZER_DEF_REG_NODOLLAR(COP0, Reserved21, 21), + RABBITIZER_DEF_REG_NODOLLAR(COP0, Reserved22, 22), + RABBITIZER_DEF_REG_NODOLLAR(COP0, Reserved23, 23), + RABBITIZER_DEF_REG_NODOLLAR(COP0, Reserved24, 24), + RABBITIZER_DEF_REG_NODOLLAR(COP0, Reserved25, 25), + RABBITIZER_DEF_REG_NODOLLAR(COP0, PErr, 26), + RABBITIZER_DEF_REG_NODOLLAR(COP0, CacheErr, 27), + RABBITIZER_DEF_REG_NODOLLAR(COP0, TagLo, 28), + RABBITIZER_DEF_REG_NODOLLAR(COP0, TagHi, 29), + RABBITIZER_DEF_REG_NODOLLAR(COP0, ErrorEPC, 30), + RABBITIZER_DEF_REG_NODOLLAR(COP0, Reserved31, 31), diff --git a/tools/ido-static-recomp/tools/rabbitizer/include/instructions/registers/RabbitizerRegister_Cop1Control.inc b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/registers/RabbitizerRegister_Cop1Control.inc new file mode 100644 index 00000000..cad6bde5 --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/registers/RabbitizerRegister_Cop1Control.inc @@ -0,0 +1,35 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + + RABBITIZER_DEF_REG(COP1_CONTROL, 0, 0), + RABBITIZER_DEF_REG(COP1_CONTROL, 1, 1), + RABBITIZER_DEF_REG(COP1_CONTROL, 2, 2), + RABBITIZER_DEF_REG(COP1_CONTROL, 3, 3), + RABBITIZER_DEF_REG(COP1_CONTROL, 4, 4), + RABBITIZER_DEF_REG(COP1_CONTROL, 5, 5), + RABBITIZER_DEF_REG(COP1_CONTROL, 6, 6), + RABBITIZER_DEF_REG(COP1_CONTROL, 7, 7), + RABBITIZER_DEF_REG(COP1_CONTROL, 8, 8), + RABBITIZER_DEF_REG(COP1_CONTROL, 9, 9), + RABBITIZER_DEF_REG(COP1_CONTROL, 10, 10), + RABBITIZER_DEF_REG(COP1_CONTROL, 11, 11), + RABBITIZER_DEF_REG(COP1_CONTROL, 12, 12), + RABBITIZER_DEF_REG(COP1_CONTROL, 13, 13), + RABBITIZER_DEF_REG(COP1_CONTROL, 14, 14), + RABBITIZER_DEF_REG(COP1_CONTROL, 15, 15), + RABBITIZER_DEF_REG(COP1_CONTROL, 16, 16), + RABBITIZER_DEF_REG(COP1_CONTROL, 17, 17), + RABBITIZER_DEF_REG(COP1_CONTROL, 18, 18), + RABBITIZER_DEF_REG(COP1_CONTROL, 19, 19), + RABBITIZER_DEF_REG(COP1_CONTROL, 20, 20), + RABBITIZER_DEF_REG(COP1_CONTROL, 21, 21), + RABBITIZER_DEF_REG(COP1_CONTROL, 22, 22), + RABBITIZER_DEF_REG(COP1_CONTROL, 23, 23), + RABBITIZER_DEF_REG(COP1_CONTROL, 24, 24), + RABBITIZER_DEF_REG(COP1_CONTROL, 25, 25), + RABBITIZER_DEF_REG(COP1_CONTROL, 26, 26), + RABBITIZER_DEF_REG(COP1_CONTROL, 27, 27), + RABBITIZER_DEF_REG(COP1_CONTROL, 28, 28), + RABBITIZER_DEF_REG(COP1_CONTROL, 29, 29), + RABBITIZER_DEF_REG(COP1_CONTROL, 30, 30), + RABBITIZER_DEF_REG(COP1_CONTROL, FpcCsr, 31), diff --git a/tools/ido-static-recomp/tools/rabbitizer/include/instructions/registers/RabbitizerRegister_Cop1N32.inc b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/registers/RabbitizerRegister_Cop1N32.inc new file mode 100644 index 00000000..affe4948 --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/registers/RabbitizerRegister_Cop1N32.inc @@ -0,0 +1,35 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + + RABBITIZER_DEF_REG(COP1_N32, fv0, f0), + RABBITIZER_DEF_REG(COP1_N32, ft14, f1), + RABBITIZER_DEF_REG(COP1_N32, fv1, f2), + RABBITIZER_DEF_REG(COP1_N32, ft15, f3), + RABBITIZER_DEF_REG(COP1_N32, ft0, f4), + RABBITIZER_DEF_REG(COP1_N32, ft1, f5), + RABBITIZER_DEF_REG(COP1_N32, ft2, f6), + RABBITIZER_DEF_REG(COP1_N32, ft3, f7), + RABBITIZER_DEF_REG(COP1_N32, ft4, f8), + RABBITIZER_DEF_REG(COP1_N32, ft5, f9), + RABBITIZER_DEF_REG(COP1_N32, ft6, f10), + RABBITIZER_DEF_REG(COP1_N32, ft7, f11), + RABBITIZER_DEF_REG(COP1_N32, fa0, f12), + RABBITIZER_DEF_REG(COP1_N32, fa1, f13), + RABBITIZER_DEF_REG(COP1_N32, fa2, f14), + RABBITIZER_DEF_REG(COP1_N32, fa3, f15), + RABBITIZER_DEF_REG(COP1_N32, fa4, f16), + RABBITIZER_DEF_REG(COP1_N32, fa5, f17), + RABBITIZER_DEF_REG(COP1_N32, fa6, f18), + RABBITIZER_DEF_REG(COP1_N32, fa7, f19), + RABBITIZER_DEF_REG(COP1_N32, fs0, f20), + RABBITIZER_DEF_REG(COP1_N32, ft8, f21), + RABBITIZER_DEF_REG(COP1_N32, fs1, f22), + RABBITIZER_DEF_REG(COP1_N32, ft9, f23), + RABBITIZER_DEF_REG(COP1_N32, fs2, f24), + RABBITIZER_DEF_REG(COP1_N32, ft10, f25), + RABBITIZER_DEF_REG(COP1_N32, fs3, f26), + RABBITIZER_DEF_REG(COP1_N32, ft11, f27), + RABBITIZER_DEF_REG(COP1_N32, fs4, f28), + RABBITIZER_DEF_REG(COP1_N32, ft12, f29), + RABBITIZER_DEF_REG(COP1_N32, fs5, f30), + RABBITIZER_DEF_REG(COP1_N32, ft13, f31), diff --git a/tools/ido-static-recomp/tools/rabbitizer/include/instructions/registers/RabbitizerRegister_Cop1N64.inc b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/registers/RabbitizerRegister_Cop1N64.inc new file mode 100644 index 00000000..1388c93d --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/registers/RabbitizerRegister_Cop1N64.inc @@ -0,0 +1,35 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + + RABBITIZER_DEF_REG(COP1_N64, fv0, f0), + RABBITIZER_DEF_REG(COP1_N64, ft12, f1), + RABBITIZER_DEF_REG(COP1_N64, fv1, f2), + RABBITIZER_DEF_REG(COP1_N64, ft13, f3), + RABBITIZER_DEF_REG(COP1_N64, ft0, f4), + RABBITIZER_DEF_REG(COP1_N64, ft1, f5), + RABBITIZER_DEF_REG(COP1_N64, ft2, f6), + RABBITIZER_DEF_REG(COP1_N64, ft3, f7), + RABBITIZER_DEF_REG(COP1_N64, ft4, f8), + RABBITIZER_DEF_REG(COP1_N64, ft5, f9), + RABBITIZER_DEF_REG(COP1_N64, ft6, f10), + RABBITIZER_DEF_REG(COP1_N64, ft7, f11), + RABBITIZER_DEF_REG(COP1_N64, fa0, f12), + RABBITIZER_DEF_REG(COP1_N64, fa1, f13), + RABBITIZER_DEF_REG(COP1_N64, fa2, f14), + RABBITIZER_DEF_REG(COP1_N64, fa3, f15), + RABBITIZER_DEF_REG(COP1_N64, fa4, f16), + RABBITIZER_DEF_REG(COP1_N64, fa5, f17), + RABBITIZER_DEF_REG(COP1_N64, fa6, f18), + RABBITIZER_DEF_REG(COP1_N64, fa7, f19), + RABBITIZER_DEF_REG(COP1_N64, ft8, f20), + RABBITIZER_DEF_REG(COP1_N64, ft9, f21), + RABBITIZER_DEF_REG(COP1_N64, ft10, f22), + RABBITIZER_DEF_REG(COP1_N64, ft11, f23), + RABBITIZER_DEF_REG(COP1_N64, fs0, f24), + RABBITIZER_DEF_REG(COP1_N64, fs1, f25), + RABBITIZER_DEF_REG(COP1_N64, fs2, f26), + RABBITIZER_DEF_REG(COP1_N64, fs3, f27), + RABBITIZER_DEF_REG(COP1_N64, fs4, f28), + RABBITIZER_DEF_REG(COP1_N64, fs5, f29), + RABBITIZER_DEF_REG(COP1_N64, fs6, f30), + RABBITIZER_DEF_REG(COP1_N64, fs7, f31), diff --git a/tools/ido-static-recomp/tools/rabbitizer/include/instructions/registers/RabbitizerRegister_Cop1O32.inc b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/registers/RabbitizerRegister_Cop1O32.inc new file mode 100644 index 00000000..44ba53e1 --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/registers/RabbitizerRegister_Cop1O32.inc @@ -0,0 +1,35 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + + RABBITIZER_DEF_REG(COP1_O32, fv0, f0), + RABBITIZER_DEF_REG(COP1_O32, fv0f, f1), + RABBITIZER_DEF_REG(COP1_O32, fv1, f2), + RABBITIZER_DEF_REG(COP1_O32, fv1f, f3), + RABBITIZER_DEF_REG(COP1_O32, ft0, f4), + RABBITIZER_DEF_REG(COP1_O32, ft0f, f5), + RABBITIZER_DEF_REG(COP1_O32, ft1, f6), + RABBITIZER_DEF_REG(COP1_O32, ft1f, f7), + RABBITIZER_DEF_REG(COP1_O32, ft2, f8), + RABBITIZER_DEF_REG(COP1_O32, ft2f, f9), + RABBITIZER_DEF_REG(COP1_O32, ft3, f10), + RABBITIZER_DEF_REG(COP1_O32, ft3f, f11), + RABBITIZER_DEF_REG(COP1_O32, fa0, f12), + RABBITIZER_DEF_REG(COP1_O32, fa0f, f13), + RABBITIZER_DEF_REG(COP1_O32, fa1, f14), + RABBITIZER_DEF_REG(COP1_O32, fa1f, f15), + RABBITIZER_DEF_REG(COP1_O32, ft4, f16), + RABBITIZER_DEF_REG(COP1_O32, ft4f, f17), + RABBITIZER_DEF_REG(COP1_O32, ft5, f18), + RABBITIZER_DEF_REG(COP1_O32, ft5f, f19), + RABBITIZER_DEF_REG(COP1_O32, fs0, f20), + RABBITIZER_DEF_REG(COP1_O32, fs0f, f21), + RABBITIZER_DEF_REG(COP1_O32, fs1, f22), + RABBITIZER_DEF_REG(COP1_O32, fs1f, f23), + RABBITIZER_DEF_REG(COP1_O32, fs2, f24), + RABBITIZER_DEF_REG(COP1_O32, fs2f, f25), + RABBITIZER_DEF_REG(COP1_O32, fs3, f26), + RABBITIZER_DEF_REG(COP1_O32, fs3f, f27), + RABBITIZER_DEF_REG(COP1_O32, fs4, f28), + RABBITIZER_DEF_REG(COP1_O32, fs4f, f29), + RABBITIZER_DEF_REG(COP1_O32, fs5, f30), + RABBITIZER_DEF_REG(COP1_O32, fs5f, f31), diff --git a/tools/ido-static-recomp/tools/rabbitizer/include/instructions/registers/RabbitizerRegister_Cop2.inc b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/registers/RabbitizerRegister_Cop2.inc new file mode 100644 index 00000000..84e40f32 --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/registers/RabbitizerRegister_Cop2.inc @@ -0,0 +1,35 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + + RABBITIZER_DEF_REG(COP2, 0, 0), + RABBITIZER_DEF_REG(COP2, 1, 1), + RABBITIZER_DEF_REG(COP2, 2, 2), + RABBITIZER_DEF_REG(COP2, 3, 3), + RABBITIZER_DEF_REG(COP2, 4, 4), + RABBITIZER_DEF_REG(COP2, 5, 5), + RABBITIZER_DEF_REG(COP2, 6, 6), + RABBITIZER_DEF_REG(COP2, 7, 7), + RABBITIZER_DEF_REG(COP2, 8, 8), + RABBITIZER_DEF_REG(COP2, 9, 9), + RABBITIZER_DEF_REG(COP2, 10, 10), + RABBITIZER_DEF_REG(COP2, 11, 11), + RABBITIZER_DEF_REG(COP2, 12, 12), + RABBITIZER_DEF_REG(COP2, 13, 13), + RABBITIZER_DEF_REG(COP2, 14, 14), + RABBITIZER_DEF_REG(COP2, 15, 15), + RABBITIZER_DEF_REG(COP2, 16, 16), + RABBITIZER_DEF_REG(COP2, 17, 17), + RABBITIZER_DEF_REG(COP2, 18, 18), + RABBITIZER_DEF_REG(COP2, 19, 19), + RABBITIZER_DEF_REG(COP2, 20, 20), + RABBITIZER_DEF_REG(COP2, 21, 21), + RABBITIZER_DEF_REG(COP2, 22, 22), + RABBITIZER_DEF_REG(COP2, 23, 23), + RABBITIZER_DEF_REG(COP2, 24, 24), + RABBITIZER_DEF_REG(COP2, 25, 25), + RABBITIZER_DEF_REG(COP2, 26, 26), + RABBITIZER_DEF_REG(COP2, 27, 27), + RABBITIZER_DEF_REG(COP2, 28, 28), + RABBITIZER_DEF_REG(COP2, 29, 29), + RABBITIZER_DEF_REG(COP2, 30, 30), + RABBITIZER_DEF_REG(COP2, 31, 31), diff --git a/tools/ido-static-recomp/tools/rabbitizer/include/instructions/registers/RabbitizerRegister_GprN32.inc b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/registers/RabbitizerRegister_GprN32.inc new file mode 100644 index 00000000..a937136b --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/registers/RabbitizerRegister_GprN32.inc @@ -0,0 +1,35 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + + RABBITIZER_DEF_REG(GPR_N32, zero, 0), + RABBITIZER_DEF_REG(GPR_N32, at, 1), + RABBITIZER_DEF_REG(GPR_N32, v0, 2), + RABBITIZER_DEF_REG(GPR_N32, v1, 3), + RABBITIZER_DEF_REG(GPR_N32, a0, 4), + RABBITIZER_DEF_REG(GPR_N32, a1, 5), + RABBITIZER_DEF_REG(GPR_N32, a2, 6), + RABBITIZER_DEF_REG(GPR_N32, a3, 7), + RABBITIZER_DEF_REG(GPR_N32, a4, 8), + RABBITIZER_DEF_REG(GPR_N32, a5, 9), + RABBITIZER_DEF_REG(GPR_N32, a6, 10), + RABBITIZER_DEF_REG(GPR_N32, a7, 11), + RABBITIZER_DEF_REG(GPR_N32, t0, 12), + RABBITIZER_DEF_REG(GPR_N32, t1, 13), + RABBITIZER_DEF_REG(GPR_N32, t2, 14), + RABBITIZER_DEF_REG(GPR_N32, t3, 15), + RABBITIZER_DEF_REG(GPR_N32, s0, 16), + RABBITIZER_DEF_REG(GPR_N32, s1, 17), + RABBITIZER_DEF_REG(GPR_N32, s2, 18), + RABBITIZER_DEF_REG(GPR_N32, s3, 19), + RABBITIZER_DEF_REG(GPR_N32, s4, 20), + RABBITIZER_DEF_REG(GPR_N32, s5, 21), + RABBITIZER_DEF_REG(GPR_N32, s6, 22), + RABBITIZER_DEF_REG(GPR_N32, s7, 23), + RABBITIZER_DEF_REG(GPR_N32, t8, 24), + RABBITIZER_DEF_REG(GPR_N32, t9, 25), + RABBITIZER_DEF_REG(GPR_N32, k0, 26), + RABBITIZER_DEF_REG(GPR_N32, k1, 27), + RABBITIZER_DEF_REG(GPR_N32, gp, 28), + RABBITIZER_DEF_REG(GPR_N32, sp, 29), + RABBITIZER_DEF_REG(GPR_N32, fp, 30), + RABBITIZER_DEF_REG(GPR_N32, ra, 31), diff --git a/tools/ido-static-recomp/tools/rabbitizer/include/instructions/registers/RabbitizerRegister_GprO32.inc b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/registers/RabbitizerRegister_GprO32.inc new file mode 100644 index 00000000..26685fe5 --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/registers/RabbitizerRegister_GprO32.inc @@ -0,0 +1,35 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + + RABBITIZER_DEF_REG(GPR_O32, zero, 0), + RABBITIZER_DEF_REG(GPR_O32, at, 1), + RABBITIZER_DEF_REG(GPR_O32, v0, 2), + RABBITIZER_DEF_REG(GPR_O32, v1, 3), + RABBITIZER_DEF_REG(GPR_O32, a0, 4), + RABBITIZER_DEF_REG(GPR_O32, a1, 5), + RABBITIZER_DEF_REG(GPR_O32, a2, 6), + RABBITIZER_DEF_REG(GPR_O32, a3, 7), + RABBITIZER_DEF_REG(GPR_O32, t0, 8), + RABBITIZER_DEF_REG(GPR_O32, t1, 9), + RABBITIZER_DEF_REG(GPR_O32, t2, 10), + RABBITIZER_DEF_REG(GPR_O32, t3, 11), + RABBITIZER_DEF_REG(GPR_O32, t4, 12), + RABBITIZER_DEF_REG(GPR_O32, t5, 13), + RABBITIZER_DEF_REG(GPR_O32, t6, 14), + RABBITIZER_DEF_REG(GPR_O32, t7, 15), + RABBITIZER_DEF_REG(GPR_O32, s0, 16), + RABBITIZER_DEF_REG(GPR_O32, s1, 17), + RABBITIZER_DEF_REG(GPR_O32, s2, 18), + RABBITIZER_DEF_REG(GPR_O32, s3, 19), + RABBITIZER_DEF_REG(GPR_O32, s4, 20), + RABBITIZER_DEF_REG(GPR_O32, s5, 21), + RABBITIZER_DEF_REG(GPR_O32, s6, 22), + RABBITIZER_DEF_REG(GPR_O32, s7, 23), + RABBITIZER_DEF_REG(GPR_O32, t8, 24), + RABBITIZER_DEF_REG(GPR_O32, t9, 25), + RABBITIZER_DEF_REG(GPR_O32, k0, 26), + RABBITIZER_DEF_REG(GPR_O32, k1, 27), + RABBITIZER_DEF_REG(GPR_O32, gp, 28), + RABBITIZER_DEF_REG(GPR_O32, sp, 29), + RABBITIZER_DEF_REG(GPR_O32, fp, 30), + RABBITIZER_DEF_REG(GPR_O32, ra, 31), diff --git a/tools/ido-static-recomp/tools/rabbitizer/include/instructions/registers/RabbitizerRegister_R5900VF.inc b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/registers/RabbitizerRegister_R5900VF.inc new file mode 100644 index 00000000..afb88dd5 --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/registers/RabbitizerRegister_R5900VF.inc @@ -0,0 +1,35 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +RABBITIZER_DEF_REG(R5900_VF, vf0, 0), +RABBITIZER_DEF_REG(R5900_VF, vf1, 1), +RABBITIZER_DEF_REG(R5900_VF, vf2, 2), +RABBITIZER_DEF_REG(R5900_VF, vf3, 3), +RABBITIZER_DEF_REG(R5900_VF, vf4, 4), +RABBITIZER_DEF_REG(R5900_VF, vf5, 5), +RABBITIZER_DEF_REG(R5900_VF, vf6, 6), +RABBITIZER_DEF_REG(R5900_VF, vf7, 7), +RABBITIZER_DEF_REG(R5900_VF, vf8, 8), +RABBITIZER_DEF_REG(R5900_VF, vf9, 9), +RABBITIZER_DEF_REG(R5900_VF, vf10, 10), +RABBITIZER_DEF_REG(R5900_VF, vf11, 11), +RABBITIZER_DEF_REG(R5900_VF, vf12, 12), +RABBITIZER_DEF_REG(R5900_VF, vf13, 13), +RABBITIZER_DEF_REG(R5900_VF, vf14, 14), +RABBITIZER_DEF_REG(R5900_VF, vf15, 15), +RABBITIZER_DEF_REG(R5900_VF, vf16, 16), +RABBITIZER_DEF_REG(R5900_VF, vf17, 17), +RABBITIZER_DEF_REG(R5900_VF, vf18, 18), +RABBITIZER_DEF_REG(R5900_VF, vf19, 19), +RABBITIZER_DEF_REG(R5900_VF, vf20, 20), +RABBITIZER_DEF_REG(R5900_VF, vf21, 21), +RABBITIZER_DEF_REG(R5900_VF, vf22, 22), +RABBITIZER_DEF_REG(R5900_VF, vf23, 23), +RABBITIZER_DEF_REG(R5900_VF, vf24, 24), +RABBITIZER_DEF_REG(R5900_VF, vf25, 25), +RABBITIZER_DEF_REG(R5900_VF, vf26, 26), +RABBITIZER_DEF_REG(R5900_VF, vf27, 27), +RABBITIZER_DEF_REG(R5900_VF, vf28, 28), +RABBITIZER_DEF_REG(R5900_VF, vf29, 29), +RABBITIZER_DEF_REG(R5900_VF, vf30, 30), +RABBITIZER_DEF_REG(R5900_VF, vf31, 31), diff --git a/tools/ido-static-recomp/tools/rabbitizer/include/instructions/registers/RabbitizerRegister_R5900VI.inc b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/registers/RabbitizerRegister_R5900VI.inc new file mode 100644 index 00000000..3e8e9f82 --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/registers/RabbitizerRegister_R5900VI.inc @@ -0,0 +1,35 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +RABBITIZER_DEF_REG(R5900_VI, vi0, 0), +RABBITIZER_DEF_REG(R5900_VI, vi1, 1), +RABBITIZER_DEF_REG(R5900_VI, vi2, 2), +RABBITIZER_DEF_REG(R5900_VI, vi3, 3), +RABBITIZER_DEF_REG(R5900_VI, vi4, 4), +RABBITIZER_DEF_REG(R5900_VI, vi5, 5), +RABBITIZER_DEF_REG(R5900_VI, vi6, 6), +RABBITIZER_DEF_REG(R5900_VI, vi7, 7), +RABBITIZER_DEF_REG(R5900_VI, vi8, 8), +RABBITIZER_DEF_REG(R5900_VI, vi9, 9), +RABBITIZER_DEF_REG(R5900_VI, vi10, 10), +RABBITIZER_DEF_REG(R5900_VI, vi11, 11), +RABBITIZER_DEF_REG(R5900_VI, vi12, 12), +RABBITIZER_DEF_REG(R5900_VI, vi13, 13), +RABBITIZER_DEF_REG(R5900_VI, vi14, 14), +RABBITIZER_DEF_REG(R5900_VI, vi15, 15), +RABBITIZER_DEF_REG(R5900_VI, vi16, 16), +RABBITIZER_DEF_REG(R5900_VI, vi17, 17), +RABBITIZER_DEF_REG(R5900_VI, vi18, 18), +RABBITIZER_DEF_REG(R5900_VI, vi19, 19), +RABBITIZER_DEF_REG(R5900_VI, vi20, 20), +RABBITIZER_DEF_REG(R5900_VI, vi21, 21), +RABBITIZER_DEF_REG(R5900_VI, vi22, 22), +RABBITIZER_DEF_REG(R5900_VI, vi23, 23), +RABBITIZER_DEF_REG(R5900_VI, vi24, 24), +RABBITIZER_DEF_REG(R5900_VI, vi25, 25), +RABBITIZER_DEF_REG(R5900_VI, vi26, 26), +RABBITIZER_DEF_REG(R5900_VI, vi27, 27), +RABBITIZER_DEF_REG(R5900_VI, vi28, 28), +RABBITIZER_DEF_REG(R5900_VI, vi29, 29), +RABBITIZER_DEF_REG(R5900_VI, vi30, 30), +RABBITIZER_DEF_REG(R5900_VI, vi31, 31), diff --git a/tools/ido-static-recomp/tools/rabbitizer/include/instructions/registers/RabbitizerRegister_RspCop0.inc b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/registers/RabbitizerRegister_RspCop0.inc new file mode 100644 index 00000000..fdac94d1 --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/registers/RabbitizerRegister_RspCop0.inc @@ -0,0 +1,19 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + + RABBITIZER_DEF_REG_NODOLLAR(RSP_COP0, SP_MEM_ADDR, 0), + RABBITIZER_DEF_REG_NODOLLAR(RSP_COP0, SP_DRAM_ADDR, 1), + RABBITIZER_DEF_REG_NODOLLAR(RSP_COP0, SP_RD_LEN, 2), + RABBITIZER_DEF_REG_NODOLLAR(RSP_COP0, SP_WR_LEN, 3), + RABBITIZER_DEF_REG_NODOLLAR(RSP_COP0, SP_STATUS, 4), + RABBITIZER_DEF_REG_NODOLLAR(RSP_COP0, SP_DMA_FULL, 5), + RABBITIZER_DEF_REG_NODOLLAR(RSP_COP0, SP_DMA_BUSY, 6), + RABBITIZER_DEF_REG_NODOLLAR(RSP_COP0, SP_SEMAPHORE, 7), + RABBITIZER_DEF_REG_NODOLLAR(RSP_COP0, DPC_START, 8), + RABBITIZER_DEF_REG_NODOLLAR(RSP_COP0, DPC_END, 9), + RABBITIZER_DEF_REG_NODOLLAR(RSP_COP0, DPC_CURRENT, 10), + RABBITIZER_DEF_REG_NODOLLAR(RSP_COP0, DPC_STATUS, 11), + RABBITIZER_DEF_REG_NODOLLAR(RSP_COP0, DPC_CLOCK, 12), + RABBITIZER_DEF_REG_NODOLLAR(RSP_COP0, DPC_BUFBUSY, 13), + RABBITIZER_DEF_REG_NODOLLAR(RSP_COP0, DPC_PIPEBUSY, 14), + RABBITIZER_DEF_REG_NODOLLAR(RSP_COP0, DPC_TMEM, 15), diff --git a/tools/ido-static-recomp/tools/rabbitizer/include/instructions/registers/RabbitizerRegister_RspCop2.inc b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/registers/RabbitizerRegister_RspCop2.inc new file mode 100644 index 00000000..d22b673f --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/registers/RabbitizerRegister_RspCop2.inc @@ -0,0 +1,35 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + + RABBITIZER_DEF_REG(RSP_COP2, 0, 0), + RABBITIZER_DEF_REG(RSP_COP2, 1, 1), + RABBITIZER_DEF_REG(RSP_COP2, 2, 2), + RABBITIZER_DEF_REG(RSP_COP2, 3, 3), + RABBITIZER_DEF_REG(RSP_COP2, 4, 4), + RABBITIZER_DEF_REG(RSP_COP2, 5, 5), + RABBITIZER_DEF_REG(RSP_COP2, 6, 6), + RABBITIZER_DEF_REG(RSP_COP2, 7, 7), + RABBITIZER_DEF_REG(RSP_COP2, 8, 8), + RABBITIZER_DEF_REG(RSP_COP2, 9, 9), + RABBITIZER_DEF_REG(RSP_COP2, 10, 10), + RABBITIZER_DEF_REG(RSP_COP2, 11, 11), + RABBITIZER_DEF_REG(RSP_COP2, 12, 12), + RABBITIZER_DEF_REG(RSP_COP2, 13, 13), + RABBITIZER_DEF_REG(RSP_COP2, 14, 14), + RABBITIZER_DEF_REG(RSP_COP2, 15, 15), + RABBITIZER_DEF_REG(RSP_COP2, 16, 16), + RABBITIZER_DEF_REG(RSP_COP2, 17, 17), + RABBITIZER_DEF_REG(RSP_COP2, 18, 18), + RABBITIZER_DEF_REG(RSP_COP2, 19, 19), + RABBITIZER_DEF_REG(RSP_COP2, 20, 20), + RABBITIZER_DEF_REG(RSP_COP2, 21, 21), + RABBITIZER_DEF_REG(RSP_COP2, 22, 22), + RABBITIZER_DEF_REG(RSP_COP2, 23, 23), + RABBITIZER_DEF_REG(RSP_COP2, 24, 24), + RABBITIZER_DEF_REG(RSP_COP2, 25, 25), + RABBITIZER_DEF_REG(RSP_COP2, 26, 26), + RABBITIZER_DEF_REG(RSP_COP2, 27, 27), + RABBITIZER_DEF_REG(RSP_COP2, 28, 28), + RABBITIZER_DEF_REG(RSP_COP2, 29, 29), + RABBITIZER_DEF_REG(RSP_COP2, 30, 30), + RABBITIZER_DEF_REG(RSP_COP2, 31, 31), diff --git a/tools/ido-static-recomp/tools/rabbitizer/include/instructions/registers/RabbitizerRegister_RspCop2Control.inc b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/registers/RabbitizerRegister_RspCop2Control.inc new file mode 100644 index 00000000..0f730f31 --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/registers/RabbitizerRegister_RspCop2Control.inc @@ -0,0 +1,35 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + + RABBITIZER_DEF_REG(RSP_COP2_CONTROL, 0, 0), + RABBITIZER_DEF_REG(RSP_COP2_CONTROL, 1, 1), + RABBITIZER_DEF_REG(RSP_COP2_CONTROL, 2, 2), + RABBITIZER_DEF_REG(RSP_COP2_CONTROL, 3, 3), + RABBITIZER_DEF_REG(RSP_COP2_CONTROL, 4, 4), + RABBITIZER_DEF_REG(RSP_COP2_CONTROL, 5, 5), + RABBITIZER_DEF_REG(RSP_COP2_CONTROL, 6, 6), + RABBITIZER_DEF_REG(RSP_COP2_CONTROL, 7, 7), + RABBITIZER_DEF_REG(RSP_COP2_CONTROL, 8, 8), + RABBITIZER_DEF_REG(RSP_COP2_CONTROL, 9, 9), + RABBITIZER_DEF_REG(RSP_COP2_CONTROL, 10, 10), + RABBITIZER_DEF_REG(RSP_COP2_CONTROL, 11, 11), + RABBITIZER_DEF_REG(RSP_COP2_CONTROL, 12, 12), + RABBITIZER_DEF_REG(RSP_COP2_CONTROL, 13, 13), + RABBITIZER_DEF_REG(RSP_COP2_CONTROL, 14, 14), + RABBITIZER_DEF_REG(RSP_COP2_CONTROL, 15, 15), + RABBITIZER_DEF_REG(RSP_COP2_CONTROL, 16, 16), + RABBITIZER_DEF_REG(RSP_COP2_CONTROL, 17, 17), + RABBITIZER_DEF_REG(RSP_COP2_CONTROL, 18, 18), + RABBITIZER_DEF_REG(RSP_COP2_CONTROL, 19, 19), + RABBITIZER_DEF_REG(RSP_COP2_CONTROL, 20, 20), + RABBITIZER_DEF_REG(RSP_COP2_CONTROL, 21, 21), + RABBITIZER_DEF_REG(RSP_COP2_CONTROL, 22, 22), + RABBITIZER_DEF_REG(RSP_COP2_CONTROL, 23, 23), + RABBITIZER_DEF_REG(RSP_COP2_CONTROL, 24, 24), + RABBITIZER_DEF_REG(RSP_COP2_CONTROL, 25, 25), + RABBITIZER_DEF_REG(RSP_COP2_CONTROL, 26, 26), + RABBITIZER_DEF_REG(RSP_COP2_CONTROL, 27, 27), + RABBITIZER_DEF_REG(RSP_COP2_CONTROL, 28, 28), + RABBITIZER_DEF_REG(RSP_COP2_CONTROL, 29, 29), + RABBITIZER_DEF_REG(RSP_COP2_CONTROL, 30, 30), + RABBITIZER_DEF_REG(COP1_CONTROL, 31, 31), diff --git a/tools/ido-static-recomp/tools/rabbitizer/include/instructions/registers/RabbitizerRegister_RspGpr.inc b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/registers/RabbitizerRegister_RspGpr.inc new file mode 100644 index 00000000..490926cd --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/registers/RabbitizerRegister_RspGpr.inc @@ -0,0 +1,35 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + + RABBITIZER_DEF_REG(RSP_GPR, zero, 0), + RABBITIZER_DEF_REG(RSP_GPR, 1, 1), + RABBITIZER_DEF_REG(RSP_GPR, 2, 2), + RABBITIZER_DEF_REG(RSP_GPR, 3, 3), + RABBITIZER_DEF_REG(RSP_GPR, 4, 4), + RABBITIZER_DEF_REG(RSP_GPR, 5, 5), + RABBITIZER_DEF_REG(RSP_GPR, 6, 6), + RABBITIZER_DEF_REG(RSP_GPR, 7, 7), + RABBITIZER_DEF_REG(RSP_GPR, 8, 8), + RABBITIZER_DEF_REG(RSP_GPR, 9, 9), + RABBITIZER_DEF_REG(RSP_GPR, 10, 10), + RABBITIZER_DEF_REG(RSP_GPR, 11, 11), + RABBITIZER_DEF_REG(RSP_GPR, 12, 12), + RABBITIZER_DEF_REG(RSP_GPR, 13, 13), + RABBITIZER_DEF_REG(RSP_GPR, 14, 14), + RABBITIZER_DEF_REG(RSP_GPR, 15, 15), + RABBITIZER_DEF_REG(RSP_GPR, 16, 16), + RABBITIZER_DEF_REG(RSP_GPR, 17, 17), + RABBITIZER_DEF_REG(RSP_GPR, 18, 18), + RABBITIZER_DEF_REG(RSP_GPR, 19, 19), + RABBITIZER_DEF_REG(RSP_GPR, 20, 20), + RABBITIZER_DEF_REG(RSP_GPR, 21, 21), + RABBITIZER_DEF_REG(RSP_GPR, 22, 22), + RABBITIZER_DEF_REG(RSP_GPR, 23, 23), + RABBITIZER_DEF_REG(RSP_GPR, 24, 24), + RABBITIZER_DEF_REG(RSP_GPR, 25, 25), + RABBITIZER_DEF_REG(RSP_GPR, 26, 26), + RABBITIZER_DEF_REG(RSP_GPR, 27, 27), + RABBITIZER_DEF_REG(RSP_GPR, 28, 28), + RABBITIZER_DEF_REG(RSP_GPR, 29, 29), + RABBITIZER_DEF_REG(RSP_GPR, 30, 30), + RABBITIZER_DEF_REG(RSP_GPR, ra, 31), diff --git a/tools/ido-static-recomp/tools/rabbitizer/include/instructions/registers/RabbitizerRegister_RspVector.inc b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/registers/RabbitizerRegister_RspVector.inc new file mode 100644 index 00000000..c2676d91 --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/include/instructions/registers/RabbitizerRegister_RspVector.inc @@ -0,0 +1,35 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + + RABBITIZER_DEF_REG(RSP_VECTOR, v0, 0), + RABBITIZER_DEF_REG(RSP_VECTOR, v1, 1), + RABBITIZER_DEF_REG(RSP_VECTOR, v2, 2), + RABBITIZER_DEF_REG(RSP_VECTOR, v3, 3), + RABBITIZER_DEF_REG(RSP_VECTOR, v4, 4), + RABBITIZER_DEF_REG(RSP_VECTOR, v5, 5), + RABBITIZER_DEF_REG(RSP_VECTOR, v6, 6), + RABBITIZER_DEF_REG(RSP_VECTOR, v7, 7), + RABBITIZER_DEF_REG(RSP_VECTOR, v8, 8), + RABBITIZER_DEF_REG(RSP_VECTOR, v9, 9), + RABBITIZER_DEF_REG(RSP_VECTOR, v10, 10), + RABBITIZER_DEF_REG(RSP_VECTOR, v11, 11), + RABBITIZER_DEF_REG(RSP_VECTOR, v12, 12), + RABBITIZER_DEF_REG(RSP_VECTOR, v13, 13), + RABBITIZER_DEF_REG(RSP_VECTOR, v14, 14), + RABBITIZER_DEF_REG(RSP_VECTOR, v15, 15), + RABBITIZER_DEF_REG(RSP_VECTOR, v16, 16), + RABBITIZER_DEF_REG(RSP_VECTOR, v17, 17), + RABBITIZER_DEF_REG(RSP_VECTOR, v18, 18), + RABBITIZER_DEF_REG(RSP_VECTOR, v19, 19), + RABBITIZER_DEF_REG(RSP_VECTOR, v20, 20), + RABBITIZER_DEF_REG(RSP_VECTOR, v21, 21), + RABBITIZER_DEF_REG(RSP_VECTOR, v22, 22), + RABBITIZER_DEF_REG(RSP_VECTOR, v23, 23), + RABBITIZER_DEF_REG(RSP_VECTOR, v24, 24), + RABBITIZER_DEF_REG(RSP_VECTOR, v25, 25), + RABBITIZER_DEF_REG(RSP_VECTOR, v26, 26), + RABBITIZER_DEF_REG(RSP_VECTOR, v27, 27), + RABBITIZER_DEF_REG(RSP_VECTOR, v28, 28), + RABBITIZER_DEF_REG(RSP_VECTOR, v29, 29), + RABBITIZER_DEF_REG(RSP_VECTOR, v30, 30), + RABBITIZER_DEF_REG(RSP_VECTOR, v31, 31), diff --git a/tools/ido-static-recomp/tools/rabbitizer/include/rabbitizer.h b/tools/ido-static-recomp/tools/rabbitizer/include/rabbitizer.h new file mode 100644 index 00000000..5bae2d58 --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/include/rabbitizer.h @@ -0,0 +1,25 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +#ifndef RABBITIZER_H +#define RABBITIZER_H +#pragma once + +#include "common/Utils.h" +#include "common/RabbitizerVersion.h" +#include "common/RabbitizerConfig.h" + +#include "instructions/RabbitizerOperandType.h" +#include "instructions/RabbitizerInstrId.h" +#include "instructions/RabbitizerInstrSuffix.h" +#include "instructions/RabbitizerInstrDescriptor.h" +#include "instructions/RabbitizerRegister.h" +#include "instructions/RabbitizerInstruction.h" +#include "instructions/RabbitizerInstructionRsp.h" +#include "instructions/RabbitizerInstructionR5900.h" + +#include "analysis/RabbitizerTrackedRegisterState.h" +#include "analysis/RabbitizerLoPairingInfo.h" +#include "analysis/RabbitizerRegistersTracker.h" + +#endif diff --git a/tools/ido-static-recomp/tools/rabbitizer/pyproject.toml b/tools/ido-static-recomp/tools/rabbitizer/pyproject.toml new file mode 100644 index 00000000..35a5cb29 --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/pyproject.toml @@ -0,0 +1,9 @@ +# SPDX-FileCopyrightText: © 2022 Decompollaborate +# SPDX-License-Identifier: MIT + +[build-system] +requires = ["setuptools>=61.0", "wheel"] +build-backend = "setuptools.build_meta" + +[tool.cibuildwheel] +skip = ["cp36-*"] diff --git a/tools/ido-static-recomp/tools/rabbitizer/r5900test.c b/tools/ido-static-recomp/tools/rabbitizer/r5900test.c new file mode 100644 index 00000000..bc83f4db --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/r5900test.c @@ -0,0 +1,47 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +#include "instructions/RabbitizerInstructionR5900.h" + +#include +#include +#include +#include + + +int main() { + uint32_t word; + RabbitizerInstruction instr; + char *buffer; + int extraLJust = 5; +#if 1 + uint32_t validbits; +#endif + + word = 0x4BE1634B; + + RabbitizerInstructionR5900_init(&instr, word, 0x00100000); + + RabbitizerInstructionR5900_processUniqueId(&instr); + + buffer = malloc(RabbitizerInstruction_getSizeForBuffer(&instr, 0, extraLJust) + 1); + assert(buffer != NULL); + + RabbitizerInstruction_disassemble(&instr, buffer, NULL, 0, extraLJust); + + printf("%08X: %s\n", word, buffer); + +#if 1 + validbits = RabbitizerInstruction_getValidBits(&instr); + + printf("word: %08X\n", instr.word); + printf("mandatory bits: %08X\n", instr._mandatorybits); + printf("valid bits: %08X\n", validbits); + printf("invalid bits: %08X\n", (~validbits) & instr.word); +#endif + + free(buffer); + RabbitizerInstructionR5900_destroy(&instr); + + return 0; +} diff --git a/tools/ido-static-recomp/tools/rabbitizer/rabbitizer/Config.pyi b/tools/ido-static-recomp/tools/rabbitizer/rabbitizer/Config.pyi new file mode 100644 index 00000000..c639b4f1 --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/rabbitizer/Config.pyi @@ -0,0 +1,46 @@ +#!/usr/bin/env python3 + +# SPDX-FileCopyrightText: © 2022 Decompollaborate +# SPDX-License-Identifier: MIT + +from __future__ import annotations + +from .Enum import Enum + + +class Abi: + NUMERIC: Enum + O32: Enum + N32: Enum + N64: Enum + + @staticmethod + def fromStr(name: str | None) -> Enum: ... + + +class _RabbitizerConfig: + regNames_namedRegisters: bool = True + regNames_gprAbiNames: Enum = Abi.O32 + regNames_fprAbiNames: Enum = Abi.NUMERIC + regNames_userFpcCsr: bool = True + regNames_vr4300Cop0NamedRegisters: bool = True + regNames_vr4300RspCop0NamedRegisters: bool = True + + pseudos_enablePseudos: bool = True + pseudos_pseudoBeqz: bool = True + pseudos_pseudoBnez: bool = True + pseudos_pseudoB: bool = True + pseudos_pseudoMove: bool = True + pseudos_pseudoNot: bool = True + pseudos_pseudoNegu: bool = True + pseudos_pseudoBal: bool = True + + toolchainTweaks_sn64DivFix: bool = False + toolchainTweaks_treatJAsUnconditionalBranch: bool = False + + misc_opcodeLJust: int = 11 + misc_unknownInstrComment: bool = True + misc_omit0XOnSmallImm: bool = False + misc_upperCaseImm: bool = True + +config: _RabbitizerConfig diff --git a/tools/ido-static-recomp/tools/rabbitizer/rabbitizer/Enum.pyi b/tools/ido-static-recomp/tools/rabbitizer/rabbitizer/Enum.pyi new file mode 100644 index 00000000..afa18969 --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/rabbitizer/Enum.pyi @@ -0,0 +1,24 @@ +#!/usr/bin/env python3 + +# SPDX-FileCopyrightText: © 2022 Decompollaborate +# SPDX-License-Identifier: MIT + +from __future__ import annotations + + +class Enum: + name: str + value: int + + def __init__(self, enumType: str, name: str, value: int) -> None: ... + + def __reduce__(self) -> tuple: ... + + def __lt__(self, __o: object) -> bool: ... + def __le__(self, __o: object) -> bool: ... + def __eq__(self, __o: object) -> bool: ... + def __gt__(self, __o: object) -> bool: ... + def __ge__(self, __o: object) -> bool: ... + + def __repr__(self) -> str: ... + def __str__(self) -> str: ... diff --git a/tools/ido-static-recomp/tools/rabbitizer/rabbitizer/InstrCategory.pyi b/tools/ido-static-recomp/tools/rabbitizer/rabbitizer/InstrCategory.pyi new file mode 100644 index 00000000..7d4b7e56 --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/rabbitizer/InstrCategory.pyi @@ -0,0 +1,15 @@ +#!/usr/bin/env python3 + +# SPDX-FileCopyrightText: © 2022 Decompollaborate +# SPDX-License-Identifier: MIT + +from __future__ import annotations + +from .Enum import Enum + + +class InstrCategory: + CPU: Enum + RSP: Enum + R5900: Enum + MAX: Enum diff --git a/tools/ido-static-recomp/tools/rabbitizer/rabbitizer/InstrId.pyi b/tools/ido-static-recomp/tools/rabbitizer/rabbitizer/InstrId.pyi new file mode 100644 index 00000000..87e87bf3 --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/rabbitizer/InstrId.pyi @@ -0,0 +1,631 @@ +#!/usr/bin/env python3 + +# SPDX-FileCopyrightText: © 2022 Decompollaborate +# SPDX-License-Identifier: MIT + +from __future__ import annotations + +from .Enum import Enum + + +class InstrId: + cpu_INVALID: Enum + cpu_mthi: Enum + cpu_mtlo: Enum + cpu_jr: Enum + cpu_jalr: Enum + cpu_jalr_rd: Enum + cpu_mfhi: Enum + cpu_mflo: Enum + cpu_mult: Enum + cpu_multu: Enum + cpu_dmult: Enum + cpu_dmultu: Enum + cpu_tge: Enum + cpu_tgeu: Enum + cpu_tlt: Enum + cpu_tltu: Enum + cpu_teq: Enum + cpu_tne: Enum + cpu_movz: Enum + cpu_movn: Enum + cpu_div: Enum + cpu_divu: Enum + cpu_sn64_div: Enum + cpu_sn64_divu: Enum + cpu_ddiv: Enum + cpu_ddivu: Enum + cpu_add: Enum + cpu_addu: Enum + cpu_sub: Enum + cpu_subu: Enum + cpu_and: Enum + cpu_or: Enum + cpu_xor: Enum + cpu_nor: Enum + cpu_slt: Enum + cpu_sltu: Enum + cpu_dadd: Enum + cpu_daddu: Enum + cpu_dsub: Enum + cpu_dsubu: Enum + cpu_syscall: Enum + cpu_break: Enum + cpu_sync: Enum + cpu_dsllv: Enum + cpu_dsrlv: Enum + cpu_dsrav: Enum + cpu_sllv: Enum + cpu_srlv: Enum + cpu_srav: Enum + cpu_sll: Enum + cpu_srl: Enum + cpu_sra: Enum + cpu_dsll: Enum + cpu_dsrl: Enum + cpu_dsra: Enum + cpu_dsll32: Enum + cpu_dsrl32: Enum + cpu_dsra32: Enum + cpu_bltz: Enum + cpu_bgez: Enum + cpu_bltzl: Enum + cpu_bgezl: Enum + cpu_tgei: Enum + cpu_tgeiu: Enum + cpu_tlti: Enum + cpu_tltiu: Enum + cpu_bltzal: Enum + cpu_bgezal: Enum + cpu_bltzall: Enum + cpu_bgezall: Enum + cpu_bal: Enum + cpu_teqi: Enum + cpu_tnei: Enum + cpu_j: Enum + cpu_jal: Enum + cpu_beq: Enum + cpu_bne: Enum + cpu_beql: Enum + cpu_bnel: Enum + cpu_blez: Enum + cpu_bgtz: Enum + cpu_blezl: Enum + cpu_bgtzl: Enum + cpu_lui: Enum + cpu_andi: Enum + cpu_ori: Enum + cpu_xori: Enum + cpu_addi: Enum + cpu_addiu: Enum + cpu_daddi: Enum + cpu_daddiu: Enum + cpu_slti: Enum + cpu_sltiu: Enum + cpu_ldl: Enum + cpu_ldr: Enum + cpu_lb: Enum + cpu_lh: Enum + cpu_lwl: Enum + cpu_lw: Enum + cpu_lbu: Enum + cpu_lhu: Enum + cpu_lwr: Enum + cpu_lwu: Enum + cpu_sb: Enum + cpu_sh: Enum + cpu_swl: Enum + cpu_sw: Enum + cpu_sdl: Enum + cpu_sdr: Enum + cpu_swr: Enum + cpu_ll: Enum + cpu_pref: Enum + cpu_lld: Enum + cpu_ld: Enum + cpu_sc: Enum + cpu_scd: Enum + cpu_sd: Enum + cpu_lwc1: Enum + cpu_ldc1: Enum + cpu_swc1: Enum + cpu_sdc1: Enum + cpu_lwc2: Enum + cpu_ldc2: Enum + cpu_swc2: Enum + cpu_sdc2: Enum + cpu_mfc0: Enum + cpu_dmfc0: Enum + cpu_cfc0: Enum + cpu_mtc0: Enum + cpu_dmtc0: Enum + cpu_ctc0: Enum + cpu_tlbr: Enum + cpu_tlbwi: Enum + cpu_tlbwr: Enum + cpu_tlbp: Enum + cpu_eret: Enum + cpu_bc0t: Enum + cpu_bc0f: Enum + cpu_bc0tl: Enum + cpu_bc0fl: Enum + cpu_mfc1: Enum + cpu_dmfc1: Enum + cpu_mtc1: Enum + cpu_dmtc1: Enum + cpu_cfc1: Enum + cpu_ctc1: Enum + cpu_bc1f: Enum + cpu_bc1t: Enum + cpu_bc1fl: Enum + cpu_bc1tl: Enum + cpu_add_s: Enum + cpu_sub_s: Enum + cpu_mul_s: Enum + cpu_div_s: Enum + cpu_add_d: Enum + cpu_sub_d: Enum + cpu_mul_d: Enum + cpu_div_d: Enum + cpu_sqrt_s: Enum + cpu_abs_s: Enum + cpu_mov_s: Enum + cpu_neg_s: Enum + cpu_sqrt_d: Enum + cpu_abs_d: Enum + cpu_mov_d: Enum + cpu_neg_d: Enum + cpu_round_l_s: Enum + cpu_trunc_l_s: Enum + cpu_ceil_l_s: Enum + cpu_floor_l_s: Enum + cpu_round_l_d: Enum + cpu_trunc_l_d: Enum + cpu_ceil_l_d: Enum + cpu_floor_l_d: Enum + cpu_round_w_s: Enum + cpu_trunc_w_s: Enum + cpu_ceil_w_s: Enum + cpu_floor_w_s: Enum + cpu_round_w_d: Enum + cpu_trunc_w_d: Enum + cpu_ceil_w_d: Enum + cpu_floor_w_d: Enum + cpu_c_f_s: Enum + cpu_c_un_s: Enum + cpu_c_eq_s: Enum + cpu_c_ueq_s: Enum + cpu_c_olt_s: Enum + cpu_c_ult_s: Enum + cpu_c_ole_s: Enum + cpu_c_ule_s: Enum + cpu_c_f_d: Enum + cpu_c_un_d: Enum + cpu_c_eq_d: Enum + cpu_c_ueq_d: Enum + cpu_c_olt_d: Enum + cpu_c_ult_d: Enum + cpu_c_ole_d: Enum + cpu_c_ule_d: Enum + cpu_c_sf_s: Enum + cpu_c_ngle_s: Enum + cpu_c_seq_s: Enum + cpu_c_ngl_s: Enum + cpu_c_lt_s: Enum + cpu_c_nge_s: Enum + cpu_c_le_s: Enum + cpu_c_ngt_s: Enum + cpu_c_sf_d: Enum + cpu_c_ngle_d: Enum + cpu_c_seq_d: Enum + cpu_c_ngl_d: Enum + cpu_c_lt_d: Enum + cpu_c_nge_d: Enum + cpu_c_le_d: Enum + cpu_c_ngt_d: Enum + cpu_cvt_s_d: Enum + cpu_cvt_s_w: Enum + cpu_cvt_s_l: Enum + cpu_cvt_d_s: Enum + cpu_cvt_d_w: Enum + cpu_cvt_d_l: Enum + cpu_cvt_w_s: Enum + cpu_cvt_w_d: Enum + cpu_cvt_l_s: Enum + cpu_cvt_l_d: Enum + cpu_nop: Enum + cpu_beqz: Enum + cpu_bnez: Enum + cpu_b: Enum + cpu_move: Enum + cpu_not: Enum + cpu_negu: Enum + cpu_MAX: Enum + + rsp_INVALID: Enum + rsp_vmulf: Enum + rsp_vmulu: Enum + rsp_vrndp: Enum + rsp_vmulq: Enum + rsp_vmudl: Enum + rsp_vmudm: Enum + rsp_vmudn: Enum + rsp_vmudh: Enum + rsp_vmacf: Enum + rsp_vmacu: Enum + rsp_vrndn: Enum + rsp_vmacq: Enum + rsp_vmadl: Enum + rsp_vmadm: Enum + rsp_vmadn: Enum + rsp_vmadh: Enum + rsp_vadd: Enum + rsp_vsub: Enum + rsp_vabs: Enum + rsp_vaddc: Enum + rsp_vsubc: Enum + rsp_vsar: Enum + rsp_vand: Enum + rsp_vnand: Enum + rsp_vor: Enum + rsp_vnor: Enum + rsp_vxor: Enum + rsp_vnxor: Enum + rsp_vlt: Enum + rsp_veq: Enum + rsp_vne: Enum + rsp_vge: Enum + rsp_vcl: Enum + rsp_vch: Enum + rsp_vcr: Enum + rsp_vmrg: Enum + rsp_vrcp: Enum + rsp_vrcpl: Enum + rsp_vrcph: Enum + rsp_vmov: Enum + rsp_vrsq: Enum + rsp_vrsql: Enum + rsp_vrsqh: Enum + rsp_vnop: Enum + rsp_mfc2: Enum + rsp_mtc2: Enum + rsp_cfc2: Enum + rsp_ctc2: Enum + rsp_sbv: Enum + rsp_ssv: Enum + rsp_slv: Enum + rsp_sdv: Enum + rsp_sqv: Enum + rsp_srv: Enum + rsp_spv: Enum + rsp_suv: Enum + rsp_swv: Enum + rsp_shv: Enum + rsp_sfv: Enum + rsp_stv: Enum + rsp_lbv: Enum + rsp_lsv: Enum + rsp_llv: Enum + rsp_ldv: Enum + rsp_lqv: Enum + rsp_lrv: Enum + rsp_lpv: Enum + rsp_luv: Enum + rsp_lhv: Enum + rsp_lfv: Enum + rsp_ltv: Enum + rsp_jr: Enum + rsp_jalr: Enum + rsp_jalr_rd: Enum + rsp_movz: Enum + rsp_movn: Enum + rsp_add: Enum + rsp_addu: Enum + rsp_sub: Enum + rsp_subu: Enum + rsp_and: Enum + rsp_or: Enum + rsp_xor: Enum + rsp_nor: Enum + rsp_slt: Enum + rsp_sltu: Enum + rsp_break: Enum + rsp_sllv: Enum + rsp_srlv: Enum + rsp_srav: Enum + rsp_sll: Enum + rsp_srl: Enum + rsp_sra: Enum + rsp_bltz: Enum + rsp_bgez: Enum + rsp_bltzal: Enum + rsp_bgezal: Enum + rsp_bal: Enum + rsp_j: Enum + rsp_jal: Enum + rsp_beq: Enum + rsp_bne: Enum + rsp_blez: Enum + rsp_bgtz: Enum + rsp_lui: Enum + rsp_andi: Enum + rsp_ori: Enum + rsp_xori: Enum + rsp_addi: Enum + rsp_addiu: Enum + rsp_slti: Enum + rsp_sltiu: Enum + rsp_lb: Enum + rsp_lh: Enum + rsp_lw: Enum + rsp_lbu: Enum + rsp_lhu: Enum + rsp_sb: Enum + rsp_sh: Enum + rsp_sw: Enum + rsp_pref: Enum + rsp_lwc1: Enum + rsp_swc1: Enum + rsp_mfc0: Enum + rsp_mtc0: Enum + rsp_nop: Enum + rsp_beqz: Enum + rsp_bnez: Enum + rsp_b: Enum + rsp_move: Enum + rsp_not: Enum + rsp_negu: Enum + rsp_MAX: Enum + + r5900_INVALID: Enum + r5900_lq: Enum + r5900_sq: Enum + r5900_lqc2: Enum + r5900_sqc2: Enum + r5900_sync_p: Enum + r5900_mfsa: Enum + r5900_mtsa: Enum + r5900_mtsab: Enum + r5900_mtsah: Enum + r5900_madd: Enum + r5900_maddu: Enum + r5900_plzcw: Enum + r5900_mfhi1: Enum + r5900_mthi1: Enum + r5900_mflo1: Enum + r5900_mtlo1: Enum + r5900_mult1: Enum + r5900_multu1: Enum + r5900_div1: Enum + r5900_divu1: Enum + r5900_madd1: Enum + r5900_maddu1: Enum + r5900_pmfhl: Enum + r5900_pmthl: Enum + r5900_psllh: Enum + r5900_psrlh: Enum + r5900_psrah: Enum + r5900_psllw: Enum + r5900_psrlw: Enum + r5900_psraw: Enum + r5900_paddw: Enum + r5900_psubw: Enum + r5900_pcgtw: Enum + r5900_pmaxw: Enum + r5900_paddh: Enum + r5900_psubh: Enum + r5900_pcgth: Enum + r5900_pmaxh: Enum + r5900_paddb: Enum + r5900_psubb: Enum + r5900_pcgtb: Enum + r5900_paddsw: Enum + r5900_psubsw: Enum + r5900_pextlw: Enum + r5900_ppacw: Enum + r5900_paddsh: Enum + r5900_psubsh: Enum + r5900_pextlh: Enum + r5900_ppach: Enum + r5900_paddsb: Enum + r5900_psubsb: Enum + r5900_pextlb: Enum + r5900_ppacb: Enum + r5900_pext5: Enum + r5900_ppac5: Enum + r5900_pabsw: Enum + r5900_pceqw: Enum + r5900_pminw: Enum + r5900_padsbh: Enum + r5900_pabsh: Enum + r5900_pceqh: Enum + r5900_pminh: Enum + r5900_pceqb: Enum + r5900_padduw: Enum + r5900_psubuw: Enum + r5900_pextuw: Enum + r5900_padduh: Enum + r5900_psubuh: Enum + r5900_pextuh: Enum + r5900_paddub: Enum + r5900_psubub: Enum + r5900_pextub: Enum + r5900_qfsrv: Enum + r5900_pmaddw: Enum + r5900_psllvw: Enum + r5900_psrlvw: Enum + r5900_pmsubw: Enum + r5900_pmfhi: Enum + r5900_pmflo: Enum + r5900_pinth: Enum + r5900_pmultw: Enum + r5900_pdivw: Enum + r5900_pcpyld: Enum + r5900_pmaddh: Enum + r5900_phmadh: Enum + r5900_pand: Enum + r5900_pxor: Enum + r5900_pmsubh: Enum + r5900_phmsbh: Enum + r5900_pexeh: Enum + r5900_prevh: Enum + r5900_pmulth: Enum + r5900_pdivbw: Enum + r5900_pexew: Enum + r5900_prot3w: Enum + r5900_pmadduw: Enum + r5900_psravw: Enum + r5900_pmthi: Enum + r5900_pmtlo: Enum + r5900_pinteh: Enum + r5900_pmultuw: Enum + r5900_pdivuw: Enum + r5900_pcpyud: Enum + r5900_por: Enum + r5900_pnor: Enum + r5900_pexch: Enum + r5900_pcpyh: Enum + r5900_pexcw: Enum + r5900_ei: Enum + r5900_di: Enum + r5900_rsqrt_s: Enum + r5900_adda_s: Enum + r5900_suba_s: Enum + r5900_mula_s: Enum + r5900_madd_s: Enum + r5900_msub_s: Enum + r5900_madda_s: Enum + r5900_msuba_s: Enum + r5900_max_s: Enum + r5900_min_s: Enum + r5900_qmfc2: Enum + r5900_cfc2: Enum + r5900_qmtc2: Enum + r5900_ctc2: Enum + r5900_bc2f: Enum + r5900_bc2t: Enum + r5900_bc2fl: Enum + r5900_bc2tl: Enum + r5900_vaddx: Enum + r5900_vaddy: Enum + r5900_vaddz: Enum + r5900_vaddw: Enum + r5900_vsubx: Enum + r5900_vsuby: Enum + r5900_vsubz: Enum + r5900_vsubw: Enum + r5900_vmaddx: Enum + r5900_vmaddy: Enum + r5900_vmaddz: Enum + r5900_vmaddw: Enum + r5900_vmsubx: Enum + r5900_vmsuby: Enum + r5900_vmsubz: Enum + r5900_vmsubw: Enum + r5900_vmaxx: Enum + r5900_vmaxy: Enum + r5900_vmaxz: Enum + r5900_vmaxw: Enum + r5900_vminix: Enum + r5900_vminiy: Enum + r5900_vminiz: Enum + r5900_vminiw: Enum + r5900_vmulx: Enum + r5900_vmuly: Enum + r5900_vmulz: Enum + r5900_vmulw: Enum + r5900_vmulq: Enum + r5900_vmaxi: Enum + r5900_vmuli: Enum + r5900_vminii: Enum + r5900_vaddq: Enum + r5900_vmaddq: Enum + r5900_vaddi: Enum + r5900_vmaddi: Enum + r5900_vsubq: Enum + r5900_vmsubq: Enum + r5900_vsubi: Enum + r5900_vmsubi: Enum + r5900_vadd: Enum + r5900_vmadd: Enum + r5900_vmul: Enum + r5900_vmax: Enum + r5900_vsub: Enum + r5900_vmsub: Enum + r5900_vopmsub: Enum + r5900_vmini: Enum + r5900_viadd: Enum + r5900_visub: Enum + r5900_viaddi: Enum + r5900_viand: Enum + r5900_vior: Enum + r5900_vcallms: Enum + r5900_callmsr: Enum + r5900_vaddax: Enum + r5900_vadday: Enum + r5900_vaddaz: Enum + r5900_vaddaw: Enum + r5900_vsubax: Enum + r5900_vsubay: Enum + r5900_vsubaz: Enum + r5900_vsubaw: Enum + r5900_vvmaddx: Enum + r5900_vvmaddy: Enum + r5900_vvmaddz: Enum + r5900_vvmaddw: Enum + r5900_vmsubax: Enum + r5900_vmsubay: Enum + r5900_vmsubaz: Enum + r5900_vmsubaw: Enum + r5900_vitof0: Enum + r5900_vitof4: Enum + r5900_vitof12: Enum + r5900_vitof15: Enum + r5900_vftoi0: Enum + r5900_vftoi4: Enum + r5900_vftoi12: Enum + r5900_vftoi15: Enum + r5900_vmulax: Enum + r5900_vmulay: Enum + r5900_vmulaz: Enum + r5900_vmulaw: Enum + r5900_vmulaq: Enum + r5900_vabs: Enum + r5900_vmulai: Enum + r5900_vclipw: Enum + r5900_vaddaq: Enum + r5900_vmaddaq: Enum + r5900_vaddai: Enum + r5900_vmaddai: Enum + r5900_vsubaq: Enum + r5900_vmsubaq: Enum + r5900_vsubai: Enum + r5900_vmsubai: Enum + r5900_vadda: Enum + r5900_vmadda: Enum + r5900_vmula: Enum + r5900_vsuba: Enum + r5900_vmsuba: Enum + r5900_vopmula: Enum + r5900_vnop: Enum + r5900_vmove: Enum + r5900_vmr32: Enum + r5900_vlqi: Enum + r5900_vsqi: Enum + r5900_vlqd: Enum + r5900_vsqd: Enum + r5900_vdiv: Enum + r5900_vsqrt: Enum + r5900_vrsqrt: Enum + r5900_vwaitq: Enum + r5900_vmtir: Enum + r5900_vmfir: Enum + r5900_vilwr: Enum + r5900_viswr: Enum + r5900_vrnext: Enum + r5900_vrget: Enum + r5900_vrinit: Enum + r5900_vrxor: Enum + r5900_MAX: Enum + + ALL_MAX: Enum diff --git a/tools/ido-static-recomp/tools/rabbitizer/rabbitizer/LoPairingInfo.pyi b/tools/ido-static-recomp/tools/rabbitizer/rabbitizer/LoPairingInfo.pyi new file mode 100644 index 00000000..70e2a1b7 --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/rabbitizer/LoPairingInfo.pyi @@ -0,0 +1,16 @@ +#!/usr/bin/env python3 + +# SPDX-FileCopyrightText: © 2022 Decompollaborate +# SPDX-License-Identifier: MIT + +from __future__ import annotations + + +class LoPairingInfo: + instrOffset: int + value: int + shouldProcess: bool + isGpRel: bool + isGpGot: bool + + def __init__(self): ... diff --git a/tools/ido-static-recomp/tools/rabbitizer/rabbitizer/RegGprN32.pyi b/tools/ido-static-recomp/tools/rabbitizer/rabbitizer/RegGprN32.pyi new file mode 100644 index 00000000..54443526 --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/rabbitizer/RegGprN32.pyi @@ -0,0 +1,43 @@ +#!/usr/bin/env python3 + +# SPDX-FileCopyrightText: © 2022 Decompollaborate +# SPDX-License-Identifier: MIT + +from __future__ import annotations + +from .Enum import Enum + + +class RegGprN32: + zero: Enum + at: Enum + v0: Enum + v1: Enum + a0: Enum + a1: Enum + a2: Enum + a3: Enum + a4: Enum + a5: Enum + a6: Enum + a7: Enum + t0: Enum + t1: Enum + t2: Enum + t3: Enum + s0: Enum + s1: Enum + s2: Enum + s3: Enum + s4: Enum + s5: Enum + s6: Enum + s7: Enum + t8: Enum + t9: Enum + k0: Enum + k1: Enum + gp: Enum + sp: Enum + fp: Enum + ra: Enum diff --git a/tools/ido-static-recomp/tools/rabbitizer/rabbitizer/RegGprO32.pyi b/tools/ido-static-recomp/tools/rabbitizer/rabbitizer/RegGprO32.pyi new file mode 100644 index 00000000..f145ca3d --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/rabbitizer/RegGprO32.pyi @@ -0,0 +1,43 @@ +#!/usr/bin/env python3 + +# SPDX-FileCopyrightText: © 2022 Decompollaborate +# SPDX-License-Identifier: MIT + +from __future__ import annotations + +from .Enum import Enum + + +class RegGprO32: + zero: Enum + at: Enum + v0: Enum + v1: Enum + a0: Enum + a1: Enum + a2: Enum + a3: Enum + t0: Enum + t1: Enum + t2: Enum + t3: Enum + t4: Enum + t5: Enum + t6: Enum + t7: Enum + s0: Enum + s1: Enum + s2: Enum + s3: Enum + s4: Enum + s5: Enum + s6: Enum + s7: Enum + t8: Enum + t9: Enum + k0: Enum + k1: Enum + gp: Enum + sp: Enum + fp: Enum + ra: Enum diff --git a/tools/ido-static-recomp/tools/rabbitizer/rabbitizer/RegistersTracker.pyi b/tools/ido-static-recomp/tools/rabbitizer/rabbitizer/RegistersTracker.pyi new file mode 100644 index 00000000..967ba493 --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/rabbitizer/RegistersTracker.pyi @@ -0,0 +1,28 @@ +#!/usr/bin/env python3 + +# SPDX-FileCopyrightText: © 2022 Decompollaborate +# SPDX-License-Identifier: MIT + +from __future__ import annotations + +from .rabbitizer import Instruction +from .LoPairingInfo import LoPairingInfo + + +class RegistersTracker: + def __init__(self, other: RegistersTracker|None=None): ... + + def moveRegisters(self, instr: Instruction) -> bool: ... + def overwriteRegisters(self, instr: Instruction, instructionOffset: int) -> None: ... + def unsetRegistersAfterFuncCall(self, instr: Instruction, prevInstr: Instruction) -> None: ... + def getAddressIfCanSetType(self, instr: Instruction, instrOffset: int) -> int|None: ... + def getJrInfo(self, instr: Instruction) -> tuple[int, int]|None: ... + + def processLui(self, instr: Instruction, instrOffset: int, prevInstr: Instruction|None=None) -> None: ... + def processGpLoad(self, instr: Instruction, instrOffset: int) -> None: ... + def getLuiOffsetForConstant(self, instr: Instruction) -> int|None: ... + def processConstant(self, instr: Instruction, value: int, offset: int) -> None: ... + def getLuiOffsetForLo(self, instr: Instruction, instrOffset: int) -> tuple[int, bool, bool]: ... #! deprecated + def preprocessLoAndGetInfo(self, instr: Instruction, instrOffset: int) -> LoPairingInfo: ... + def processLo(self, instr: Instruction, value: int, offset: int) -> None: ... + def hasLoButNoHi(self, instr: Instruction) -> bool: ... diff --git a/tools/ido-static-recomp/tools/rabbitizer/rabbitizer/TrackedRegisterState.pyi b/tools/ido-static-recomp/tools/rabbitizer/rabbitizer/TrackedRegisterState.pyi new file mode 100644 index 00000000..36ba693e --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/rabbitizer/TrackedRegisterState.pyi @@ -0,0 +1,24 @@ +#!/usr/bin/env python3 + +# SPDX-FileCopyrightText: © 2022 Decompollaborate +# SPDX-License-Identifier: MIT + +from __future__ import annotations + + +class RegistersTracker: + registerNum: int + + hasLuiValue: bool + luiOffset: int # The offset of last lui which set a value to this register + luiSetOnBranchLikely: bool + + hasGpGot: bool + gpGotOffset: int + + hasLoValue: bool + loOffset: int + dereferenced: bool + dereferenceOffset: int + + value: int diff --git a/tools/ido-static-recomp/tools/rabbitizer/rabbitizer/Utils.pyi b/tools/ido-static-recomp/tools/rabbitizer/rabbitizer/Utils.pyi new file mode 100644 index 00000000..7215556f --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/rabbitizer/Utils.pyi @@ -0,0 +1,14 @@ +#!/usr/bin/env python3 + +# SPDX-FileCopyrightText: © 2022 Decompollaborate +# SPDX-License-Identifier: MIT + +from __future__ import annotations + + +class Utils: + @staticmethod + def from2Complement(number: int, bits: int) -> int: ... + + @staticmethod + def escapeString(src: str) -> str: ... diff --git a/tools/ido-static-recomp/tools/rabbitizer/rabbitizer/__init__.pyi b/tools/ido-static-recomp/tools/rabbitizer/rabbitizer/__init__.pyi new file mode 100644 index 00000000..1bc27a7f --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/rabbitizer/__init__.pyi @@ -0,0 +1,21 @@ +#!/usr/bin/env python3 + +# SPDX-FileCopyrightText: © 2022 Decompollaborate +# SPDX-License-Identifier: MIT + +from __future__ import annotations + +from .Utils import * + +from .Enum import * +from .InstrCategory import * +from .InstrId import * + +from .RegGprO32 import * +from .RegGprN32 import * + +from .Config import * + +from .rabbitizer import * + +from .RegistersTracker import * diff --git a/tools/ido-static-recomp/tools/rabbitizer/rabbitizer/enums/enums_utils.c b/tools/ido-static-recomp/tools/rabbitizer/rabbitizer/enums/enums_utils.c new file mode 100644 index 00000000..081dcdaf --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/rabbitizer/enums/enums_utils.c @@ -0,0 +1,38 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +#include "enums_utils.h" + + +int rabbitizer_EnumMetadata_Initialize(PyObject *submodule, RabbitizerEnumMetadata *enumValues) { + for (size_t i = 0; enumValues[i].enumType != 0; i++) { + PyObject *args; + + args = Py_BuildValue("ssi", enumValues[i].enumType, enumValues[i].name, enumValues[i].value); + if (args == NULL) { + goto error; + } + + enumValues[i].instance = PyObject_CallObject((PyObject*)&rabbitizer_type_Enum_TypeObject, args); + Py_DECREF(args); + if (enumValues[i].instance == NULL) { + goto error; + } + + enumValues[i].isInstanced = true; + if (PyModule_AddObject(submodule, enumValues[i].name, enumValues[i].instance) < 0) { + goto error; + } + } + return 0; + +error: + for (size_t i = 0; enumValues[i].enumType != 0; i++) { + if (enumValues[i].isInstanced) { + Py_DECREF(enumValues[i].instance); + } + enumValues[i].isInstanced = false; + } + + return -1; +} diff --git a/tools/ido-static-recomp/tools/rabbitizer/rabbitizer/enums/enums_utils.h b/tools/ido-static-recomp/tools/rabbitizer/rabbitizer/enums/enums_utils.h new file mode 100644 index 00000000..6cb8604f --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/rabbitizer/enums/enums_utils.h @@ -0,0 +1,85 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +#ifndef RABBITIZER_ENUMS_UTILS_H +#define RABBITIZER_ENUMS_UTILS_H +#pragma once + + +#define PY_SSIZE_T_CLEAN +#include +#include "structmember.h" + +#include + + +extern PyTypeObject rabbitizer_type_Enum_TypeObject; + + +typedef struct PyRabbitizerEnum { + PyObject_HEAD + PyObject *enumType; + PyObject *name; + int value; +} PyRabbitizerEnum; + +typedef struct RabbitizerEnumMetadata { + const char *enumType; + const char *name; + int value; + bool isInstanced; + PyObject *instance; +} RabbitizerEnumMetadata; + + +int rabbitizer_EnumMetadata_Initialize(PyObject *submodule, RabbitizerEnumMetadata *enumValues); + + +#define DECL_ENUM(enumName) \ + extern RabbitizerEnumMetadata rabbitizer_enum_##enumName##_enumvalues[]; \ + PyObject *rabbitizer_enum_##enumName##_Init(void); \ + /* Return true if o is of this enum type */ \ + int rabbitizer_enum_##enumName##_Check(PyObject *o); + +#define DEF_ENUM(enumName, docs) \ + static PyModuleDef rabbitizer_enum_##enumName##_module = { \ + PyModuleDef_HEAD_INIT, \ + .m_name = "rabbitizer." #enumName, \ + .m_doc = PyDoc_STR(docs), \ + .m_size = -1, \ + .m_methods = rabbitizer_enum_##enumName##_methods, \ + }; \ + PyObject *rabbitizer_enum_##enumName##_Init(void) { \ + PyObject *submodule; \ + if (PyType_Ready(&rabbitizer_type_Enum_TypeObject) < 0) { \ + return NULL; \ + } \ + submodule = PyModule_Create(&rabbitizer_enum_##enumName##_module); \ + if (submodule == NULL) { \ + return NULL; \ + } \ + if (rabbitizer_EnumMetadata_Initialize(submodule, rabbitizer_enum_##enumName##_enumvalues) < 0) { \ + Py_DECREF(submodule); \ + return NULL; \ + } \ + return submodule; \ + } \ + /* Return true if o is of this enum type */ \ + int rabbitizer_enum_##enumName##_Check(PyObject *o) { \ + int isInstance = PyObject_IsInstance(o, (PyObject*)&rabbitizer_type_Enum_TypeObject); \ + int enumTypeCmp; \ + if (isInstance < 0) { \ + /* An error happened */ \ + /* PyObject_IsInstance already sets an exception, so nothing else to do here */ \ + return -1; \ + } \ + if (isInstance == 0) { \ + /* `other` isn't an instance of the Enum type */ \ + return 0; \ + } \ + /* Check if both enums have the same `enumType` */ \ + enumTypeCmp = PyUnicode_CompareWithASCIIString(((PyRabbitizerEnum*)o)->enumType, #enumName); \ + return enumTypeCmp == 0; \ + } + +#endif diff --git a/tools/ido-static-recomp/tools/rabbitizer/rabbitizer/enums/rabbitizer_enum_Abi.c b/tools/ido-static-recomp/tools/rabbitizer/rabbitizer/enums/rabbitizer_enum_Abi.c new file mode 100644 index 00000000..a0d5fb09 --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/rabbitizer/enums/rabbitizer_enum_Abi.c @@ -0,0 +1,48 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +#include "enums_utils.h" +#include "common/RabbitizerConfig.h" +#include "common/Utils.h" + + +#define RABBITIZER_DEF_ABI(name) { "Abi", #name, RABBITIZER_ABI_##name, false, NULL } + +RabbitizerEnumMetadata rabbitizer_enum_Abi_enumvalues[] = { + #include "common/Abi.inc" + RABBITIZER_DEF_ABI(MAX), + + { 0 }, +}; + +#undef RABBITIZER_DEF_ABI + + +static PyObject *rabbitizer_enum_Abi_fromStr(UNUSED PyObject *self, PyObject *args, PyObject *kwds) { + static char *kwlist[] = { "name", NULL }; + const char *name = NULL; + RabbitizerAbi abi; + PyObject *ret; + + if (!PyArg_ParseTupleAndKeywords(args, kwds, "z", kwlist, &name)) { + return NULL; + } + + abi = RabbitizerAbi_fromStr(name); + + ret = rabbitizer_enum_Abi_enumvalues[abi].instance; + Py_INCREF(ret); + return ret; +} + + +#define METHOD_NO_ARGS(name, docs) { #name, (PyCFunction) rabbitizer_enum_Abi_##name, METH_NOARGS, PyDoc_STR(docs) } +#define METHOD_ARGS(name, docs) { #name, (PyCFunction) rabbitizer_enum_Abi_##name, METH_VARARGS | METH_KEYWORDS, PyDoc_STR(docs) } + +static PyMethodDef rabbitizer_enum_Abi_methods[] = { + METHOD_ARGS(fromStr, ""), + + { 0 }, +}; + +DEF_ENUM(Abi, "") diff --git a/tools/ido-static-recomp/tools/rabbitizer/rabbitizer/enums/rabbitizer_enum_InstrCategory.c b/tools/ido-static-recomp/tools/rabbitizer/rabbitizer/enums/rabbitizer_enum_InstrCategory.c new file mode 100644 index 00000000..fbc94dda --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/rabbitizer/enums/rabbitizer_enum_InstrCategory.c @@ -0,0 +1,23 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +#include "enums_utils.h" +#include "instructions/RabbitizerInstruction.h" + + +#define RABBITIZER_DEF_INSTR_CATEGORY(name) { "InstrCategory", #name, RABBITIZER_INSTRCAT_##name, false, NULL } + +RabbitizerEnumMetadata rabbitizer_enum_InstrCategory_enumvalues[] = { + #include "instructions/InstrCategory.inc" + RABBITIZER_DEF_INSTR_CATEGORY(MAX), + + { 0 }, +}; + +#undef RABBITIZER_DEF_INSTR_CATEGORY + +static PyMethodDef rabbitizer_enum_InstrCategory_methods[] = { + { 0 }, +}; + +DEF_ENUM(InstrCategory, "") diff --git a/tools/ido-static-recomp/tools/rabbitizer/rabbitizer/enums/rabbitizer_enum_InstrId.c b/tools/ido-static-recomp/tools/rabbitizer/rabbitizer/enums/rabbitizer_enum_InstrId.c new file mode 100644 index 00000000..fabf612d --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/rabbitizer/enums/rabbitizer_enum_InstrId.c @@ -0,0 +1,29 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +#include "enums_utils.h" +#include "instructions/RabbitizerInstrId.h" + + +#define RABBITIZER_DEF_INSTR_ID(prefix, caseBits, name, ...) { "InstrId", #prefix "_" #name, RABBITIZER_INSTR_ID_##prefix##_##name, false, NULL }, +#define RABBITIZER_DEF_INSTR_ID_ALTNAME(prefix, caseBits, name, altname, ...) RABBITIZER_DEF_INSTR_ID(prefix, caseBits, name, __VA_ARGS__) + +RabbitizerEnumMetadata rabbitizer_enum_InstrId_enumvalues[] = { + #include "instructions/instr_id/RabbitizerInstrId_cpu.inc" + + #include "instructions/instr_id/RabbitizerInstrId_rsp.inc" + + #include "instructions/instr_id/RabbitizerInstrId_r5900.inc" + + RABBITIZER_DEF_INSTR_ID(ALL, , MAX, ) + { 0 }, +}; + +#undef RABBITIZER_DEF_INSTR_ID +#undef RABBITIZER_DEF_INSTR_ID_ALTNAME + +static PyMethodDef rabbitizer_enum_InstrId_methods[] = { + { 0 }, +}; + +DEF_ENUM(InstrId, "") diff --git a/tools/ido-static-recomp/tools/rabbitizer/rabbitizer/enums/rabbitizer_type_Enum.c b/tools/ido-static-recomp/tools/rabbitizer/rabbitizer/enums/rabbitizer_type_Enum.c new file mode 100644 index 00000000..299fb386 --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/rabbitizer/enums/rabbitizer_type_Enum.c @@ -0,0 +1,211 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +#include "rabbitizer_module.h" +#include "enums_utils.h" +#include "common/Utils.h" + + +static void rabbitizer_type_Enum_dealloc(PyRabbitizerEnum *self) { + Py_XDECREF(self->enumType); + Py_XDECREF(self->name); + Py_TYPE(self)->tp_free((PyObject *) self); +} + +static PyObject *rabbitizer_type_Enum_new(PyTypeObject *type, UNUSED PyObject *args, UNUSED PyObject *kwds) { + PyRabbitizerEnum *self = (PyRabbitizerEnum *) type->tp_alloc(type, 0); + + if (self == NULL) { + return NULL; + } + + self->enumType = PyUnicode_FromString(""); + if (self->enumType == NULL) { + Py_DECREF(self); + return NULL; + } + self->name = PyUnicode_FromString(""); + if (self->name == NULL) { + Py_DECREF(self); + return NULL; + } + self->value = 0; + + return (PyObject *) self; +} + +static int rabbitizer_type_Enum_init(PyRabbitizerEnum *self, PyObject *args, PyObject *kwds) { + static char *kwlist[] = { "enumType", "name", "value", NULL }; + PyObject *enumType = NULL; + PyObject *name = NULL; + + if (!PyArg_ParseTupleAndKeywords(args, kwds, "UUi", kwlist, &enumType, &name, &self->value)) { + return -1; + } + + if (enumType != NULL) { + PyObject *tmp = NULL; + + tmp = self->enumType; + Py_INCREF(enumType); + self->enumType = enumType; + Py_DECREF(tmp); + } + if (name) { + PyObject *tmp = NULL; + + tmp = self->name; + Py_INCREF(name); + self->name = name; + Py_DECREF(tmp); + } + + return 0; +} + + +#define DEF_MEMBER_GET_INT(name) \ + static PyObject *rabbitizer_type_Enum_member_get_##name(PyRabbitizerEnum *self, PyObject *Py_UNUSED(ignored)) { \ + return PyLong_FromLong(self->name); \ + } + +#define DEF_MEMBER_GET_OBJREF(name) \ + static PyObject *rabbitizer_type_Enum_member_get_##name(PyRabbitizerEnum *self, PyObject *Py_UNUSED(ignored)) { \ + Py_INCREF(self->name); \ + return self->name; \ + } + +DEF_MEMBER_GET_OBJREF(name) +DEF_MEMBER_GET_INT(value) + + +#define MEMBER_GET(name, docs, closure) { #name, (getter) rabbitizer_type_Enum_member_get_##name, (setter) NULL, PyDoc_STR(docs), closure } +#define MEMBER_SET(name, docs, closure) { #name, (getter) NULL, (setter) rabbitizer_type_Enum_member_set_##name, PyDoc_STR(docs), closure } +#define MEMBER_GET_SET(name, docs, closure) { #name, (getter) rabbitizer_type_Enum_member_get_##name, (setter) rabbitizer_type_Enum_member_set_##name, PyDoc_STR(docs), closure } + +static PyGetSetDef rabbitizer_type_Enum_getsetters[] = { + MEMBER_GET(name, "", NULL), + MEMBER_GET(value, "", NULL), + + { 0 }, +}; + + +// Crappy hash +Py_hash_t rabbitizer_type_Enum_hash(PyRabbitizerEnum *self) { + Py_hash_t hash = PyObject_Hash(self->enumType); + + if (hash == -1) { + return -1; + } + + return hash + self->value; +} + +// Checks for the 6 basic comparisons (==, !=, <, <=, >, >=) +PyObject *rabbitizer_type_Enum_richcompare(PyRabbitizerEnum *self, PyObject *other, int op) { + int isInstance = PyObject_IsInstance(other, (PyObject*)&rabbitizer_type_Enum_TypeObject); + int enumTypeCmp; + int otherValue; + + if (isInstance < 0) { + // An error happened + // PyObject_IsInstance already sets an exception, so nothing else to do here + return NULL; + } + + if (isInstance == 0) { + // `other` isn't an instance of the Enum type + Py_RETURN_FALSE; + } + + // Check if both enums have the same `enumType` + enumTypeCmp = PyUnicode_Compare(self->enumType, ((PyRabbitizerEnum*)other)->enumType); + if (enumTypeCmp < 0) { + // Negative could mean it isn't equal or an error occurred, so we need to check for errors + if (PyErr_Occurred() != NULL) { + return NULL; + } + Py_RETURN_FALSE; + } + if (enumTypeCmp != 0) { + Py_RETURN_FALSE; + } + + otherValue = ((PyRabbitizerEnum*)other)->value; + + // Fails to build on ci builds for some reason + // Py_RETURN_RICHCOMPARE(self->value, ((PyRabbitizerEnum*)other)->value, op); + + switch (op) { + case Py_EQ: if ((self->value) == (otherValue)) Py_RETURN_TRUE; Py_RETURN_FALSE; + case Py_NE: if ((self->value) != (otherValue)) Py_RETURN_TRUE; Py_RETURN_FALSE; + case Py_LT: if ((self->value) < (otherValue)) Py_RETURN_TRUE; Py_RETURN_FALSE; + case Py_GT: if ((self->value) > (otherValue)) Py_RETURN_TRUE; Py_RETURN_FALSE; + case Py_LE: if ((self->value) <= (otherValue)) Py_RETURN_TRUE; Py_RETURN_FALSE; + case Py_GE: if ((self->value) >= (otherValue)) Py_RETURN_TRUE; Py_RETURN_FALSE; + default: + //Py_UNREACHABLE(); + UNREACHABLE; + } +} + + +// To allow piclking the object +static PyObject *rabbitizer_type_Enum___reduce__(PyRabbitizerEnum *self, UNUSED PyObject *closure) { + PyObject *args; + PyObject *enumType; + PyObject *name; + PyObject *value; + + enumType = self->enumType; + Py_INCREF(enumType); + name = self->name; + Py_INCREF(name); + value = PyLong_FromLong(self->value); + + + args = PyTuple_Pack(3, enumType, name, value); + + return PyTuple_Pack(2, (PyObject*)&rabbitizer_type_Enum_TypeObject, args); +} + + +#define METHOD_NO_ARGS(name, docs) { #name, (PyCFunction)rabbitizer_type_Enum_##name, METH_NOARGS, PyDoc_STR(docs) } +#define METHOD_ARGS(name, docs) { #name, (PyCFunction)rabbitizer_type_Enum_##name, METH_VARARGS | METH_KEYWORDS, PyDoc_STR(docs) } + + +static PyMethodDef rabbitizer_type_Enum_methods[] = { + METHOD_ARGS(__reduce__, ""), + + { 0 }, +}; + +static PyObject *rabbitizer_type_Enum_repr(PyRabbitizerEnum *self) { + return PyUnicode_FromFormat("<%U: %U (%i)>", self->enumType, self->name, self->value); +} + +static PyObject *rabbitizer_type_Enum_str(PyRabbitizerEnum *self) { + return rabbitizer_type_Enum_repr(self); +} + +// TODO: implement hash and int + +PyTypeObject rabbitizer_type_Enum_TypeObject = { + PyVarObject_HEAD_INIT(NULL, 0) + .tp_name = "rabbitizer.Enum", + .tp_doc = PyDoc_STR("Enum"), + .tp_basicsize = sizeof(PyRabbitizerEnum), + .tp_itemsize = 0, + .tp_flags = Py_TPFLAGS_DEFAULT | Py_TPFLAGS_BASETYPE, + .tp_new = rabbitizer_type_Enum_new, + .tp_init = (initproc) rabbitizer_type_Enum_init, + .tp_dealloc = (destructor) rabbitizer_type_Enum_dealloc, + .tp_hash = (hashfunc) rabbitizer_type_Enum_hash, + .tp_richcompare = (richcmpfunc) rabbitizer_type_Enum_richcompare, + .tp_repr = (reprfunc) rabbitizer_type_Enum_repr, + .tp_str = (reprfunc) rabbitizer_type_Enum_str, + //.tp_members = rabbitizer_type_Enum_members, + .tp_methods = rabbitizer_type_Enum_methods, + .tp_getset = rabbitizer_type_Enum_getsetters, +}; diff --git a/tools/ido-static-recomp/tools/rabbitizer/rabbitizer/enums/registers/rabbitizer_enum_GprN32.c b/tools/ido-static-recomp/tools/rabbitizer/rabbitizer/enums/registers/rabbitizer_enum_GprN32.c new file mode 100644 index 00000000..6027d78f --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/rabbitizer/enums/registers/rabbitizer_enum_GprN32.c @@ -0,0 +1,28 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +#include "enums/enums_utils.h" +#include "instructions/RabbitizerRegister.h" + + +#define RABBITIZER_DEF_REG(prefix, name, numeric) \ + { "RegGprN32", #name, RABBITIZER_REG_##prefix##_##name, false, NULL } + +#define RABBITIZER_DEF_REG_NODOLLAR(prefix, name, numeric) \ + { "RegGprN32", #name, RABBITIZER_REG_##prefix##_##name, false, NULL } + +RabbitizerEnumMetadata rabbitizer_enum_RegGprN32_enumvalues[] = { + #include "instructions/registers/RabbitizerRegister_GprN32.inc" + + { 0 }, +}; + +#undef RABBITIZER_DEF_REG +#undef RABBITIZER_DEF_REG_NODOLLAR + + +static PyMethodDef rabbitizer_enum_RegGprN32_methods[] = { + { 0 }, +}; + +DEF_ENUM(RegGprN32, "") diff --git a/tools/ido-static-recomp/tools/rabbitizer/rabbitizer/enums/registers/rabbitizer_enum_GprO32.c b/tools/ido-static-recomp/tools/rabbitizer/rabbitizer/enums/registers/rabbitizer_enum_GprO32.c new file mode 100644 index 00000000..50cdabe7 --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/rabbitizer/enums/registers/rabbitizer_enum_GprO32.c @@ -0,0 +1,28 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +#include "enums/enums_utils.h" +#include "instructions/RabbitizerRegister.h" + + +#define RABBITIZER_DEF_REG(prefix, name, numeric) \ + { "RegGprO32", #name, RABBITIZER_REG_##prefix##_##name, false, NULL } + +#define RABBITIZER_DEF_REG_NODOLLAR(prefix, name, numeric) \ + { "RegGprO32", #name, RABBITIZER_REG_##prefix##_##name, false, NULL } + +RabbitizerEnumMetadata rabbitizer_enum_RegGprO32_enumvalues[] = { + #include "instructions/registers/RabbitizerRegister_GprO32.inc" + + { 0 }, +}; + +#undef RABBITIZER_DEF_REG +#undef RABBITIZER_DEF_REG_NODOLLAR + + +static PyMethodDef rabbitizer_enum_RegGprO32_methods[] = { + { 0 }, +}; + +DEF_ENUM(RegGprO32, "") diff --git a/tools/ido-static-recomp/tools/rabbitizer/rabbitizer/py.typed b/tools/ido-static-recomp/tools/rabbitizer/rabbitizer/py.typed new file mode 100644 index 00000000..e69de29b diff --git a/tools/ido-static-recomp/tools/rabbitizer/rabbitizer/rabbitizer.pyi b/tools/ido-static-recomp/tools/rabbitizer/rabbitizer/rabbitizer.pyi new file mode 100644 index 00000000..0ff63fac --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/rabbitizer/rabbitizer.pyi @@ -0,0 +1,99 @@ +#!/usr/bin/env python3 + +# SPDX-FileCopyrightText: © 2022 Decompollaborate +# SPDX-License-Identifier: MIT + +from __future__ import annotations + +from .Enum import Enum +from .InstrCategory import InstrCategory + + +class Instruction: + rs: Enum + """The value of the `rs` register for this instruction. + The type of this attribute will be either a `RegGprO32` or a `RegGprN32` depending on the current `config.regNames_gprAbiNames` value. + If the current instruction does not use the `rs` register, then a Runtime exception will be raised. + Read-only.""" + rt: Enum + """The value of the `rt` register for this instruction. + The type of this attribute will be either a `RegGprO32` or a `RegGprN32` depending on the current `config.regNames_gprAbiNames` value. + If the current instruction does not use the `rt` register, then a Runtime exception will be raised. + Read-only.""" + rd: Enum + """The value of the `rd` register for this instruction. + The type of this attribute will be either a `RegGprO32` or a `RegGprN32` depending on the current `config.regNames_gprAbiNames` value. + If the current instruction does not use the `rd` register, then a Runtime exception will be raised. + Read-only.""" + sa: int + """The value of the `sa` field for this instruction. + If the current instruction does not have a `sa` field, then a Runtime exception will be raised. + Read-only.""" + + uniqueId: Enum + """An unique identificator for the opcode of this instruction. + The type is an `InstrId` enum. + Read-only.""" + + vram: int = 0 + """The vram (virtual ram) address for this instruction""" + inHandwrittenFunction: bool = False + """Boolean value indicating if the current instruction is used on a handwritten function. This is intended to be determined by the user.""" + + + def __init__(self, word: int, vram: int=0, category: Enum=InstrCategory.CPU) -> None: ... + + def getRaw(self) -> int: ... + def getImmediate(self) -> int: ... + def getProcessedImmediate(self) -> int: ... + def getInstrIndexAsVram(self) -> int: ... + def getBranchOffset(self) -> int: ... + def getGenericBranchOffset(self, currentVram: int) -> int: ... + def getOpcodeName(self) -> str: ... + + def blankOut(self) -> None: ... + + def isImplemented(self) -> bool: ... + def isLikelyHandwritten(self) -> bool: ... + def isNop(self) -> bool: ... + def isUnconditionalBranch(self) -> bool: ... + def isJrRa(self) -> bool: ... + def isJrNotRa(self) -> bool: ... + def hasDelaySlot(self) -> bool: ... + def mapInstrToType(self) -> str|None: ... + + def sameOpcode(self, other: Instruction) -> bool: ... + def sameOpcodeButDifferentArguments(self, other: Instruction) -> bool: ... + + def isValid(self) -> bool: ... + + def isUnknownType(self) -> bool: ... + def isJType(self) -> bool: ... + def isIType(self) -> bool: ... + def isRType(self) -> bool: ... + def isRegimmType(self) -> bool: ... + def isBranch(self) -> bool: ... + def isBranchLikely(self) -> bool: ... + def isJump(self) -> bool: ... + def isTrap(self) -> bool: ... + def isFloat(self) -> bool: ... + def isDouble(self) -> bool: ... + def isUnsigned(self) -> bool: ... + def modifiesRt(self) -> bool: ... + def modifiesRd(self) -> bool: ... + def notEmitedByCompilers(self) -> bool: ... + def canBeHi(self) -> bool: ... + def canBeLo(self) -> bool: ... + def doesLink(self) -> bool: ... + def doesDereference(self) -> bool: ... + def doesLoad(self) -> bool: ... + def doesStore(self) -> bool: ... + def maybeIsMove(self) -> bool: ... + def isPseudo(self) -> bool: ... + + def disassemble(self, immOverride: str|None=None, extraLJust: int=0) -> str: ... + + def __reduce__(self) -> tuple: ... + + def __repr__(self) -> str: ... + def __str__(self) -> str: ... diff --git a/tools/ido-static-recomp/tools/rabbitizer/rabbitizer/rabbitizer_global_config.c b/tools/ido-static-recomp/tools/rabbitizer/rabbitizer/rabbitizer_global_config.c new file mode 100644 index 00000000..d02fce37 --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/rabbitizer/rabbitizer_global_config.c @@ -0,0 +1,165 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +/** + * Wrapper to expose rabbitizer's global configuration + */ + +#include "rabbitizer_module.h" +#include "common/RabbitizerConfig.h" +#include "common/Utils.h" + + +#define DEF_MEMBER_GET_BOOL(category, name) \ + static PyObject *rabbitizer_global_config_get_##category##_##name(UNUSED PyObject *self, UNUSED PyObject *closure) { \ + if (RabbitizerConfig_Cfg.category.name) { \ + Py_RETURN_TRUE; \ + } \ + Py_RETURN_FALSE; \ + } +#define DEF_MEMBER_SET_BOOL(category, name) \ + static int rabbitizer_global_config_set_##category##_##name(UNUSED PyObject *self, PyObject *value, UNUSED void *closure) { \ + if (value == NULL) { \ + PyErr_SetString(PyExc_TypeError, "Cannot delete '" #category "." #name "' attribute"); \ + return -1; \ + } \ + RabbitizerConfig_Cfg.category.name = PyObject_IsTrue(value); \ + return 0; \ + } + +#define DEF_MEMBER_GET_SET_BOOL(category, name) \ + DEF_MEMBER_GET_BOOL(category, name) \ + DEF_MEMBER_SET_BOOL(category, name) + + +#define DEF_MEMBER_GET_INT(category, name) \ + static PyObject *rabbitizer_global_config_get_##category##_##name(UNUSED PyObject *self, UNUSED PyObject *closure) { \ + return PyLong_FromLong(RabbitizerConfig_Cfg.category.name); \ + } +#define DEF_MEMBER_SET_INT(category, name, rangeCheck, minVal, maxVal) \ + static int rabbitizer_global_config_set_##category##_##name(UNUSED PyObject *self, PyObject *value, UNUSED void *closure) { \ + long val; \ + if (value == NULL) { \ + PyErr_SetString(PyExc_TypeError, "Cannot delete '" #category "_" #name "' attribute"); \ + return -1; \ + } \ + val = PyLong_AsLong(value); \ + if (val == -1) { \ + PyObject *err = PyErr_Occurred(); \ + if (err != NULL) { \ + return -1; \ + } \ + } \ + if (rangeCheck && (val < minVal || val > maxVal)) { \ + PyErr_SetString(PyExc_ValueError, "Invalid value for '" #category "_" #name "' attribute"); \ + return -1; \ + } \ + RabbitizerConfig_Cfg.category.name = val;\ + return 0; \ + } + +#define DEF_MEMBER_GET_SET_INT(category, name, rangeCheck, minVal, maxVal) \ + DEF_MEMBER_GET_INT(category, name) \ + DEF_MEMBER_SET_INT(category, name, rangeCheck, minVal, maxVal) + +#define DEF_MEMBER_GET_ABI(category, name) \ + static PyObject *rabbitizer_global_config_get_##category##_##name(UNUSED PyObject *self, UNUSED PyObject *ignored) { \ + PyObject *enumInstance = rabbitizer_enum_Abi_enumvalues[RabbitizerConfig_Cfg.category.name].instance; \ + if (enumInstance == NULL) { \ + PyErr_SetString(PyExc_RuntimeError, "Internal error: invalid enum value for '" #category "_" #name "'"); \ + return NULL; \ + } \ + Py_INCREF(enumInstance); \ + return enumInstance; \ + } +#define DEF_MEMBER_SET_ABI(category, name) \ + static int rabbitizer_global_config_set_##category##_##name(UNUSED PyObject *self, PyObject *value, UNUSED void *closure) { \ + int enumCheck; \ + if (value == NULL) { \ + PyErr_SetString(PyExc_TypeError, "Cannot delete '" #category "_" #name "' attribute"); \ + return -1; \ + } \ + enumCheck = rabbitizer_enum_Abi_Check(value); \ + if (enumCheck <= 0) { \ + if (enumCheck == 0) { \ + PyErr_SetString(PyExc_ValueError, "Invalid value for '" #category "_" #name "' attribute"); \ + } \ + return -1; \ + } \ + RabbitizerConfig_Cfg.category.name = ((PyRabbitizerEnum*)value)->value; \ + return 0; \ + } + +#define DEF_MEMBER_GET_SET_ABI(category, name) \ + DEF_MEMBER_GET_ABI(category, name) \ + DEF_MEMBER_SET_ABI(category, name) + + +#define MEMBER_GET(category, name, docs, closure) { #category "_" #name, (getter) rabbitizer_global_config_get_##category##_##name, (setter) NULL, PyDoc_STR(docs), closure } +#define MEMBER_SET(category, name, docs, closure) { #category "_" #name, (getter) NULL, (setter) rabbitizer_global_config_set_##category##_##name, PyDoc_STR(docs), closure } +#define MEMBER_GET_SET(category, name, docs, closure) { #category "_" #name, (getter) rabbitizer_global_config_get_##category##_##name, (setter) rabbitizer_global_config_set_##category##_##name, PyDoc_STR(docs), closure } + + +DEF_MEMBER_GET_SET_BOOL(regNames, namedRegisters) +DEF_MEMBER_GET_SET_ABI(regNames, gprAbiNames) +DEF_MEMBER_GET_SET_ABI(regNames, fprAbiNames) +DEF_MEMBER_GET_SET_BOOL(regNames, userFpcCsr) +DEF_MEMBER_GET_SET_BOOL(regNames, vr4300Cop0NamedRegisters) +DEF_MEMBER_GET_SET_BOOL(regNames, vr4300RspCop0NamedRegisters) + +DEF_MEMBER_GET_SET_BOOL(pseudos, enablePseudos) +DEF_MEMBER_GET_SET_BOOL(pseudos, pseudoBeqz) +DEF_MEMBER_GET_SET_BOOL(pseudos, pseudoBnez) +DEF_MEMBER_GET_SET_BOOL(pseudos, pseudoB) +DEF_MEMBER_GET_SET_BOOL(pseudos, pseudoMove) +DEF_MEMBER_GET_SET_BOOL(pseudos, pseudoNot) +DEF_MEMBER_GET_SET_BOOL(pseudos, pseudoNegu) +DEF_MEMBER_GET_SET_BOOL(pseudos, pseudoBal) + +DEF_MEMBER_GET_SET_BOOL(toolchainTweaks, treatJAsUnconditionalBranch) +DEF_MEMBER_GET_SET_BOOL(toolchainTweaks, sn64DivFix) + +DEF_MEMBER_GET_SET_INT(misc, opcodeLJust, false, 0, 0) +DEF_MEMBER_GET_SET_BOOL(misc, unknownInstrComment) +DEF_MEMBER_GET_SET_BOOL(misc, omit0XOnSmallImm) +DEF_MEMBER_GET_SET_BOOL(misc, upperCaseImm) + + +static PyGetSetDef rabbitizer_global_config_GetSets[] = { + MEMBER_GET_SET(regNames, namedRegisters, "", NULL), + MEMBER_GET_SET(regNames, gprAbiNames, "", NULL), + MEMBER_GET_SET(regNames, fprAbiNames, "", NULL), + MEMBER_GET_SET(regNames, userFpcCsr, "", NULL), + MEMBER_GET_SET(regNames, vr4300Cop0NamedRegisters, "", NULL), + MEMBER_GET_SET(regNames, vr4300RspCop0NamedRegisters, "", NULL), + + MEMBER_GET_SET(pseudos, enablePseudos, "", NULL), + MEMBER_GET_SET(pseudos, pseudoBeqz, "", NULL), + MEMBER_GET_SET(pseudos, pseudoBnez, "", NULL), + MEMBER_GET_SET(pseudos, pseudoB, "", NULL), + MEMBER_GET_SET(pseudos, pseudoMove, "", NULL), + MEMBER_GET_SET(pseudos, pseudoNot, "", NULL), + MEMBER_GET_SET(pseudos, pseudoNegu, "", NULL), + MEMBER_GET_SET(pseudos, pseudoBal, "", NULL), + + MEMBER_GET_SET(toolchainTweaks, treatJAsUnconditionalBranch, "", NULL), + MEMBER_GET_SET(toolchainTweaks, sn64DivFix, "", NULL), + + MEMBER_GET_SET(misc, opcodeLJust, "", NULL), + MEMBER_GET_SET(misc, unknownInstrComment, "", NULL), + MEMBER_GET_SET(misc, omit0XOnSmallImm, "", NULL), + MEMBER_GET_SET(misc, upperCaseImm, "", NULL), + + { 0 }, +}; + +PyTypeObject rabbitizer_global_config_TypeObject = { + PyVarObject_HEAD_INIT(NULL, 0) + .tp_name = "rabbitizer.config", + .tp_doc = PyDoc_STR(""), + .tp_basicsize = sizeof(PyObject), + .tp_itemsize = 0, + .tp_flags = Py_TPFLAGS_DEFAULT, + .tp_new = PyType_GenericNew, + .tp_getset = rabbitizer_global_config_GetSets, +}; diff --git a/tools/ido-static-recomp/tools/rabbitizer/rabbitizer/rabbitizer_module.c b/tools/ido-static-recomp/tools/rabbitizer/rabbitizer/rabbitizer_module.c new file mode 100644 index 00000000..66dec777 --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/rabbitizer/rabbitizer_module.c @@ -0,0 +1,142 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +#include "rabbitizer_module.h" + +#include + +#include "common/Utils.h" +#include "instructions/RabbitizerInstrId.h" + + +typedef enum ModuleAttributeCategory { + MODULE_ATTRIBUTE_CAT_TYPE, + MODULE_ATTRIBUTE_CAT_INIT, // submodules + MODULE_ATTRIBUTE_CAT_GLOBAL, +} ModuleAttributeCategory; + +typedef struct ModuleAttribute { + union { + PyTypeObject *type; + PyObject *(*init)(void); + PyTypeObject *global; + }; + ModuleAttributeCategory cat; + const char *name; + bool isInstanced; + PyObject *instance; +} ModuleAttributes; + +#define MODULE_ATTRIBUTE_TYPE(name) { {.type = &rabbitizer_type_##name##_TypeObject}, MODULE_ATTRIBUTE_CAT_TYPE, #name, false, NULL } +#define MODULE_ATTRIBUTE_INIT(name) { {.init = rabbitizer_submodule_##name##_Init}, MODULE_ATTRIBUTE_CAT_INIT, #name, false, NULL } +#define MODULE_ATTRIBUTE_ENUM(name) { {.init = rabbitizer_enum_##name##_Init}, MODULE_ATTRIBUTE_CAT_INIT, #name, false, NULL } +#define MODULE_ATTRIBUTE_GLOBAL(name) { {.global = &rabbitizer_global_##name##_TypeObject}, MODULE_ATTRIBUTE_CAT_GLOBAL, #name, false, NULL } + +static ModuleAttributes rabbitizer_module_attributes[] = { + MODULE_ATTRIBUTE_INIT(Utils), + MODULE_ATTRIBUTE_GLOBAL(config), + MODULE_ATTRIBUTE_TYPE(Enum), + MODULE_ATTRIBUTE_ENUM(Abi), + MODULE_ATTRIBUTE_ENUM(InstrCategory), + MODULE_ATTRIBUTE_ENUM(InstrId), + MODULE_ATTRIBUTE_ENUM(RegGprO32), + MODULE_ATTRIBUTE_ENUM(RegGprN32), + MODULE_ATTRIBUTE_TYPE(Instruction), + MODULE_ATTRIBUTE_TYPE(LoPairingInfo), + MODULE_ATTRIBUTE_TYPE(TrackedRegisterState), + MODULE_ATTRIBUTE_TYPE(RegistersTracker), +}; + +static int rabbitizer_module_attributes_Ready(void) { + // Sanity checks and PyType_Ready + for (size_t i = 0; i < ARRAY_COUNT(rabbitizer_module_attributes); i++) { + if (rabbitizer_module_attributes[i].global == NULL || rabbitizer_module_attributes[i].name == NULL) { + return -1; + } + switch (rabbitizer_module_attributes[i].cat) { + case MODULE_ATTRIBUTE_CAT_TYPE: + case MODULE_ATTRIBUTE_CAT_GLOBAL: + if (PyType_Ready(rabbitizer_module_attributes[i].type) < 0) { + return -1; + } + break; + + case MODULE_ATTRIBUTE_CAT_INIT: + break; + + default: + return -1; + } + } + + return 0; +} + +static int rabbitizer_module_attributes_Initialize(PyObject *module) { + for (size_t i = 0; i < ARRAY_COUNT(rabbitizer_module_attributes); i++) { + switch (rabbitizer_module_attributes[i].cat) { + case MODULE_ATTRIBUTE_CAT_TYPE: + rabbitizer_module_attributes[i].instance = (PyObject*) rabbitizer_module_attributes[i].type; + Py_INCREF(rabbitizer_module_attributes[i].instance); + break; + + case MODULE_ATTRIBUTE_CAT_INIT: + rabbitizer_module_attributes[i].instance = rabbitizer_module_attributes[i].init(); + if (rabbitizer_module_attributes[i].instance == NULL) { + goto error; + } + break; + + case MODULE_ATTRIBUTE_CAT_GLOBAL: + rabbitizer_module_attributes[i].instance = PyObject_CallObject((PyObject*)rabbitizer_module_attributes[i].global, NULL); + if (rabbitizer_module_attributes[i].instance == NULL) { + goto error; + } + break; + } + + rabbitizer_module_attributes[i].isInstanced = true; + if (PyModule_AddObject(module, rabbitizer_module_attributes[i].name, rabbitizer_module_attributes[i].instance) < 0) { + goto error; + } + } + + return 0; + +error: + for (size_t i = 0; i < ARRAY_COUNT(rabbitizer_module_attributes); i++) { + if (rabbitizer_module_attributes[i].isInstanced) { + Py_DECREF(rabbitizer_module_attributes[i].instance); + } + rabbitizer_module_attributes[i].isInstanced = false; + } + return -1; +} + + +static PyModuleDef rabbitizer_module = { + PyModuleDef_HEAD_INIT, + .m_name = "rabbitizer", + .m_doc = "", + .m_size = -1, +}; + +PyMODINIT_FUNC PyInit_rabbitizer(void) { + PyObject *module; + + if (rabbitizer_module_attributes_Ready() < 0) { + return NULL; + } + + module = PyModule_Create(&rabbitizer_module); + if (module == NULL) { + return NULL; + } + + if (rabbitizer_module_attributes_Initialize(module) < 0) { + Py_DECREF(module); + return NULL; + } + + return module; +} diff --git a/tools/ido-static-recomp/tools/rabbitizer/rabbitizer/rabbitizer_module.h b/tools/ido-static-recomp/tools/rabbitizer/rabbitizer/rabbitizer_module.h new file mode 100644 index 00000000..051ea67d --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/rabbitizer/rabbitizer_module.h @@ -0,0 +1,54 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +#ifndef RABBITIZER_MODULE_H +#define RABBITIZER_MODULE_H +#pragma once + +#define PY_SSIZE_T_CLEAN +#include +#include "structmember.h" + +#include "enums/enums_utils.h" + +#include "instructions/RabbitizerInstruction.h" +#include "analysis/RabbitizerTrackedRegisterState.h" +#include "analysis/RabbitizerLoPairingInfo.h" + +// TODO: clean up this... + + +typedef struct PyRabbitizerInstruction { + PyObject_HEAD + RabbitizerInstruction instr; +} PyRabbitizerInstruction; + +typedef struct PyRabbitizerTrackedRegisterState { + PyObject_HEAD + RabbitizerTrackedRegisterState registerState; +} PyRabbitizerTrackedRegisterState; + +typedef struct PyRabbitizerLoPairingInfo { + PyObject_HEAD + RabbitizerLoPairingInfo pairingInfo; +} PyRabbitizerLoPairingInfo; + + +PyObject *rabbitizer_submodule_Utils_Init(void); + +extern PyTypeObject rabbitizer_global_config_TypeObject; + +extern PyTypeObject rabbitizer_type_Enum_TypeObject; +extern PyTypeObject rabbitizer_type_Instruction_TypeObject; +extern PyTypeObject rabbitizer_type_LoPairingInfo_TypeObject; +extern PyTypeObject rabbitizer_type_TrackedRegisterState_TypeObject; +extern PyTypeObject rabbitizer_type_RegistersTracker_TypeObject; + +DECL_ENUM(Abi) +DECL_ENUM(InstrCategory) +DECL_ENUM(InstrId) + +DECL_ENUM(RegGprO32) +DECL_ENUM(RegGprN32) + +#endif diff --git a/tools/ido-static-recomp/tools/rabbitizer/rabbitizer/rabbitizer_submodule_Utils.c b/tools/ido-static-recomp/tools/rabbitizer/rabbitizer/rabbitizer_submodule_Utils.c new file mode 100644 index 00000000..31b844a8 --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/rabbitizer/rabbitizer_submodule_Utils.c @@ -0,0 +1,81 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +#include "rabbitizer_module.h" + +#include "common/Utils.h" + + +static PyObject *rabbitizer_submodule_Utils_from2Complement(UNUSED PyObject *self, PyObject *args, PyObject *kwds) { + static char *kwlist[] = { "number", "bits", NULL }; + uint32_t number = 0; + int bits = 0; + + if (!PyArg_ParseTupleAndKeywords(args, kwds, "Ii", kwlist, &number, &bits)) { + return NULL; + } + + return PyLong_FromLong(RabbitizerUtils_From2Complement(number, bits)); +} + +static PyObject *rabbitizer_submodule_Utils_escapeString(UNUSED PyObject *self, PyObject *args, PyObject *kwds) { + static char *kwlist[] = { "src", NULL }; + const char *src = NULL; + Py_ssize_t srcSize = 0; + char *dst; + size_t dstSize; + size_t wroteBytes; + PyObject *ret; + + if (!PyArg_ParseTupleAndKeywords(args, kwds, "s#", kwlist, &src, &srcSize)) { + return NULL; + } + + dstSize = 2 * srcSize; + dst = malloc(dstSize * sizeof(char)); + if (dst == NULL) { + PyErr_SetString(PyExc_RuntimeError, "Internal error on 'escapeString'"); + return NULL; + } + + wroteBytes = RabbitizerUtils_escapeString(dst, dstSize, src, srcSize); + if (wroteBytes > dstSize) { + PyErr_SetString(PyExc_RuntimeError, "Internal error on 'escapeString'"); + return NULL; + } + + ret = PyUnicode_FromStringAndSize(dst, wroteBytes); + free(dst); + return ret; +} + + +#define METHOD_NO_ARGS(name, docs) { #name, (PyCFunction) rabbitizer_submodule_Utils_##name, METH_NOARGS, PyDoc_STR(docs) } +#define METHOD_ARGS(name, docs) { #name, (PyCFunction) rabbitizer_submodule_Utils_##name, METH_VARARGS | METH_KEYWORDS, PyDoc_STR(docs) } + +static PyMethodDef rabbitizer_submodule_Utils_methods[] = { + METHOD_ARGS(from2Complement, ""), + METHOD_ARGS(escapeString, ""), + + { 0 }, +}; + + +static PyModuleDef rabbitizer_submodule_Utils_module = { + PyModuleDef_HEAD_INIT, + .m_name = "rabbitizer.Utils", + .m_doc = "", + .m_size = -1, + .m_methods = rabbitizer_submodule_Utils_methods, +}; + +PyObject *rabbitizer_submodule_Utils_Init(void) { + PyObject *submodule; + + submodule = PyModule_Create(&rabbitizer_submodule_Utils_module); + if (submodule == NULL) { + return NULL; + } + + return submodule; +} diff --git a/tools/ido-static-recomp/tools/rabbitizer/rabbitizer/rabbitizer_type_Instruction.c b/tools/ido-static-recomp/tools/rabbitizer/rabbitizer/rabbitizer_type_Instruction.c new file mode 100644 index 00000000..5471408d --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/rabbitizer/rabbitizer_type_Instruction.c @@ -0,0 +1,436 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +#include "rabbitizer_module.h" + +#include "instructions/RabbitizerInstructionRsp.h" +#include "instructions/RabbitizerInstructionR5900.h" +#include "common/RabbitizerConfig.h" + + +static void rabbitizer_type_Instruction_dealloc(PyRabbitizerInstruction *self) { + RabbitizerInstruction_destroy(&self->instr); + Py_TYPE(self)->tp_free((PyObject *) self); +} + +static int rabbitizer_type_Instruction_init(PyRabbitizerInstruction *self, PyObject *args, PyObject *kwds) { + static char *kwlist[] = { "word", "vram", "category", NULL }; + uint32_t word; + uint32_t vram; + PyObject *category = NULL; + int enumCheck; + RabbitizerInstrCategory instrCategory = RABBITIZER_INSTRCAT_CPU; + + if (!PyArg_ParseTupleAndKeywords(args, kwds, "I|IO!", kwlist, &word, &vram, &rabbitizer_type_Enum_TypeObject, &category)) { + return -1; + } + + if (category != NULL) { + enumCheck = rabbitizer_enum_InstrCategory_Check(category); + + if (enumCheck <= 0) { + if (enumCheck == 0) { + PyErr_SetString(PyExc_ValueError, "Invalid value for 'category' parameter"); + } + return -1; + } + + instrCategory = ((PyRabbitizerEnum*)category)->value; + } + + switch (instrCategory) { + case RABBITIZER_INSTRCAT_RSP: + RabbitizerInstructionRsp_init(&self->instr, word, vram); + RabbitizerInstructionRsp_processUniqueId(&self->instr); + break; + + case RABBITIZER_INSTRCAT_R5900: + RabbitizerInstructionR5900_init(&self->instr, word, vram); + RabbitizerInstructionR5900_processUniqueId(&self->instr); + break; + + case RABBITIZER_INSTRCAT_CPU: + case RABBITIZER_INSTRCAT_MAX: + RabbitizerInstruction_init(&self->instr, word, vram); + RabbitizerInstruction_processUniqueId(&self->instr); + break; + } + + return 0; +} + +static PyMemberDef rabbitizer_type_Instruction_members[] = { + { "vram", T_UINT, offsetof(PyRabbitizerInstruction, instr.vram), 0, "vram description" }, + { "inHandwrittenFunction", T_BOOL, offsetof(PyRabbitizerInstruction, instr.inHandwrittenFunction), 0, "inHandwrittenFunction description" }, + + { 0 } +}; + + +#define DEF_MEMBER_GET_UINT(name) \ + static PyObject *rabbitizer_type_Instruction_member_get_##name(PyRabbitizerInstruction *self, PyObject *Py_UNUSED(ignored)) { \ + return PyLong_FromUnsignedLong(RAB_INSTR_GET_##name(&self->instr)); \ + } + +#define DEF_MEMBER_GET_REGGPR(name) \ + static PyObject *rabbitizer_type_Instruction_member_get_##name(PyRabbitizerInstruction *self, UNUSED PyObject *closure) { \ + uint32_t reg; \ + PyObject *enumInstance = NULL; \ + \ + if (!RabbitizerInstruction_hasOperandAlias(&self->instr, RAB_OPERAND_cpu_##name)) { \ + PyErr_Format(PyExc_RuntimeError, "'%s' instruction does not reference register '" #name "'", RabbitizerInstrId_getOpcodeName(self->instr.uniqueId)); \ + return NULL; \ + } \ + \ + reg = RAB_INSTR_GET_##name(&self->instr); \ + switch (RabbitizerConfig_Cfg.regNames.gprAbiNames) { \ + case RABBITIZER_ABI_N32: \ + case RABBITIZER_ABI_N64: \ + enumInstance = rabbitizer_enum_RegGprN32_enumvalues[reg].instance; \ + break; \ + \ + default: \ + enumInstance = rabbitizer_enum_RegGprO32_enumvalues[reg].instance; \ + break; \ + } \ + \ + if (enumInstance == NULL) { \ + PyErr_SetString(PyExc_RuntimeError, "Internal error: invalid RegGpr enum value"); \ + return NULL; \ + } \ + \ + Py_INCREF(enumInstance); \ + return enumInstance; \ + } + +DEF_MEMBER_GET_REGGPR(rs) +DEF_MEMBER_GET_REGGPR(rt) +DEF_MEMBER_GET_REGGPR(rd) + +DEF_MEMBER_GET_UINT(sa) + +static PyObject *rabbitizer_type_Instruction_member_get_uniqueId(PyRabbitizerInstruction *self, PyObject *Py_UNUSED(ignored)) { + PyObject *enumInstance = rabbitizer_enum_InstrId_enumvalues[self->instr.uniqueId].instance; + + if (enumInstance == NULL) { + PyErr_SetString(PyExc_RuntimeError, "Internal error: invalid uniqueId enum value"); + return NULL; + } + + Py_INCREF(enumInstance); + return enumInstance; +} + +#define MEMBER_GET(name, docs, closure) { #name, (getter) rabbitizer_type_Instruction_member_get_##name, (setter) NULL, PyDoc_STR(docs), closure } +#define MEMBER_SET(name, docs, closure) { #name, (getter) NULL, (setter) rabbitizer_type_Instruction_member_set_##name, PyDoc_STR(docs), closure } +#define MEMBER_GET_SET(name, docs, closure) { #name, (getter) rabbitizer_type_Instruction_member_get_##name, (setter) rabbitizer_type_Instruction_member_set_##name, PyDoc_STR(docs), closure } + + +static PyGetSetDef rabbitizer_type_Instruction_getsetters[] = { + MEMBER_GET(rs, "", NULL), + MEMBER_GET(rt, "", NULL), + MEMBER_GET(rd, "", NULL), + MEMBER_GET(sa, "", NULL), + MEMBER_GET(uniqueId, "", NULL), + + { 0 } +}; + + +#define DEF_METHOD_GET_UINT(name) \ + static PyObject *rabbitizer_type_Instruction_##name(PyRabbitizerInstruction *self, PyObject *Py_UNUSED(ignored)) { \ + return PyLong_FromUnsignedLong(RabbitizerInstruction_##name(&self->instr)); \ + } + +#define DEF_METHOD_GET_INT(name) \ + static PyObject *rabbitizer_type_Instruction_##name(PyRabbitizerInstruction *self, PyObject *Py_UNUSED(ignored)) { \ + return PyLong_FromLong(RabbitizerInstruction_##name(&self->instr)); \ + } + +DEF_METHOD_GET_UINT(getRaw) +DEF_METHOD_GET_UINT(getImmediate) +DEF_METHOD_GET_INT(getProcessedImmediate) +DEF_METHOD_GET_UINT(getInstrIndexAsVram) +DEF_METHOD_GET_INT(getBranchOffset) + +static PyObject *rabbitizer_type_Instruction_getOpcodeName(PyRabbitizerInstruction *self, UNUSED PyObject *closure) { + return PyUnicode_FromString(RabbitizerInstrId_getOpcodeName(self->instr.uniqueId)); +} + +static PyObject *rabbitizer_type_Instruction_getGenericBranchOffset(PyRabbitizerInstruction *self, PyObject *args, PyObject *kwds) { + static char *kwlist[] = { "currentVram", NULL }; + uint32_t currentVram; + + if (!PyArg_ParseTupleAndKeywords(args, kwds, "I", kwlist, ¤tVram)) { + return NULL; + } + + return PyLong_FromLong(RabbitizerInstruction_getGenericBranchOffset(&self->instr, currentVram)); +} + +static PyObject *rabbitizer_type_Instruction_blankOut(PyRabbitizerInstruction *self, PyObject *Py_UNUSED(ignored)) { + RabbitizerInstruction_blankOut(&self->instr); + Py_RETURN_NONE; +} + + +#define DEF_METHOD_BOOL(name) \ + static PyObject *rabbitizer_type_Instruction_##name(PyRabbitizerInstruction *self, PyObject *Py_UNUSED(ignored)) { \ + if (RabbitizerInstruction_##name(&self->instr)) { \ + Py_RETURN_TRUE; \ + } \ + Py_RETURN_FALSE; \ + } + +DEF_METHOD_BOOL(isImplemented) +DEF_METHOD_BOOL(isLikelyHandwritten) +DEF_METHOD_BOOL(isNop) +DEF_METHOD_BOOL(isUnconditionalBranch) +DEF_METHOD_BOOL(isJrRa) +DEF_METHOD_BOOL(isJrNotRa) +DEF_METHOD_BOOL(hasDelaySlot) + +static PyObject *rabbitizer_type_Instruction_mapInstrToType(PyRabbitizerInstruction *self, PyObject *Py_UNUSED(ignored)) { + const char *type = RabbitizerInstruction_mapInstrToType(&self->instr); + + if (type != NULL) { + return PyUnicode_FromString(type); + } + Py_RETURN_NONE; +} + +static PyObject *rabbitizer_type_Instruction_sameOpcode(PyRabbitizerInstruction *self, PyObject *args, PyObject *kwds) { + static char *kwlist[] = { "other", NULL }; + PyRabbitizerInstruction *other; + + if (!PyArg_ParseTupleAndKeywords(args, kwds, "O!", kwlist, &rabbitizer_type_Instruction_TypeObject, &other)) { + return NULL; + } + + if (RabbitizerInstruction_sameOpcode(&self->instr, &other->instr)) { + Py_RETURN_TRUE; + } + Py_RETURN_FALSE; +} + +static PyObject *rabbitizer_type_Instruction_sameOpcodeButDifferentArguments(PyRabbitizerInstruction *self, PyObject *args, PyObject *kwds) { + static char *kwlist[] = { "other", NULL }; + PyRabbitizerInstruction *other; + + if (!PyArg_ParseTupleAndKeywords(args, kwds, "O!", kwlist, &rabbitizer_type_Instruction_TypeObject, &other)) { + return NULL; + } + + if (RabbitizerInstruction_sameOpcodeButDifferentArguments(&self->instr, &other->instr)) { + Py_RETURN_TRUE; + } + Py_RETURN_FALSE; +} + +DEF_METHOD_BOOL(isValid) + +#define DEF_DESCRIPTOR_METHOD_BOOL(name) \ + static PyObject *rabbitizer_type_Instruction_##name(PyRabbitizerInstruction *self, PyObject *Py_UNUSED(ignored)) { \ + if (RabbitizerInstrDescriptor_##name(self->instr.descriptor)) { \ + Py_RETURN_TRUE; \ + } \ + Py_RETURN_FALSE; \ + } + +DEF_DESCRIPTOR_METHOD_BOOL(isUnknownType) +DEF_DESCRIPTOR_METHOD_BOOL(isJType) +DEF_DESCRIPTOR_METHOD_BOOL(isIType) +DEF_DESCRIPTOR_METHOD_BOOL(isRType) +DEF_DESCRIPTOR_METHOD_BOOL(isRegimmType) +DEF_DESCRIPTOR_METHOD_BOOL(isBranch) +DEF_DESCRIPTOR_METHOD_BOOL(isBranchLikely) +DEF_DESCRIPTOR_METHOD_BOOL(isJump) +DEF_DESCRIPTOR_METHOD_BOOL(isTrap) +DEF_DESCRIPTOR_METHOD_BOOL(isFloat) +DEF_DESCRIPTOR_METHOD_BOOL(isDouble) +DEF_DESCRIPTOR_METHOD_BOOL(isUnsigned) +DEF_DESCRIPTOR_METHOD_BOOL(modifiesRt) +DEF_DESCRIPTOR_METHOD_BOOL(modifiesRd) +DEF_DESCRIPTOR_METHOD_BOOL(notEmitedByCompilers) +DEF_DESCRIPTOR_METHOD_BOOL(canBeHi) +DEF_DESCRIPTOR_METHOD_BOOL(canBeLo) +DEF_DESCRIPTOR_METHOD_BOOL(doesLink) +DEF_DESCRIPTOR_METHOD_BOOL(doesDereference) +DEF_DESCRIPTOR_METHOD_BOOL(doesLoad) +DEF_DESCRIPTOR_METHOD_BOOL(doesStore) +DEF_DESCRIPTOR_METHOD_BOOL(maybeIsMove) +DEF_DESCRIPTOR_METHOD_BOOL(isPseudo) +// TODO: create an enum type for architectureVersion +// architectureVersion + + +static PyObject *rabbitizer_type_Instruction_disassemble(PyRabbitizerInstruction *self, PyObject *args, PyObject *kwds) { + static char *kwlist[] = {"immOverride", "extraLJust", NULL}; + const char *immOverride = NULL; + size_t immOverrideLength = 0; + int extraLJust = 0; + size_t bufferSize; + char *buffer; + PyObject *ret; + + if (!PyArg_ParseTupleAndKeywords(args, kwds, "|zi", kwlist, &immOverride, &extraLJust)) { + return NULL; + } + + if (immOverride != NULL) { + immOverrideLength = strlen(immOverride); + } + + bufferSize = RabbitizerInstruction_getSizeForBuffer(&self->instr, immOverrideLength, extraLJust); + + buffer = malloc(bufferSize+1); + if (buffer == NULL) { + // TODO: signal an exception? + return NULL; + } + + RabbitizerInstruction_disassemble(&self->instr, buffer, immOverride, immOverrideLength, extraLJust); + + ret = PyUnicode_FromString(buffer); + free(buffer); + return ret; +} + + +// To allow piclking the object +static PyObject *rabbitizer_type_Instruction___reduce__(PyRabbitizerInstruction *self, UNUSED PyObject *closure) { + PyObject *args; + PyObject *word; + PyObject *vram; + PyObject *category; + + word = PyLong_FromUnsignedLong(RabbitizerInstruction_getRaw(&self->instr)); + vram = PyLong_FromUnsignedLong(self->instr.vram); + category = rabbitizer_enum_InstrCategory_enumvalues[self->instr.category].instance; + + args = PyTuple_Pack(3, word, vram, category); + + return PyTuple_Pack(2, (PyObject*)&rabbitizer_type_Instruction_TypeObject, args); +} + + +#define METHOD_NO_ARGS(name, docs) { #name, (PyCFunction)rabbitizer_type_Instruction_##name, METH_NOARGS, PyDoc_STR(docs) } +#define METHOD_ARGS(name, docs) { #name, (PyCFunction)rabbitizer_type_Instruction_##name, METH_VARARGS | METH_KEYWORDS, PyDoc_STR(docs) } + + +static PyMethodDef rabbitizer_type_Instruction_methods[] = { + METHOD_NO_ARGS(getRaw, ""), + METHOD_NO_ARGS(getImmediate, ""), + METHOD_NO_ARGS(getProcessedImmediate, ""), + METHOD_NO_ARGS(getInstrIndexAsVram, ""), + METHOD_NO_ARGS(getBranchOffset, ""), + METHOD_ARGS(getGenericBranchOffset, ""), + METHOD_NO_ARGS(getOpcodeName, ""), + + METHOD_NO_ARGS(blankOut, ""), + + METHOD_NO_ARGS(isImplemented, ""), + METHOD_NO_ARGS(isLikelyHandwritten, ""), + METHOD_NO_ARGS(isNop, ""), + METHOD_NO_ARGS(isUnconditionalBranch, ""), + METHOD_NO_ARGS(isJrRa, ""), + METHOD_NO_ARGS(isJrNotRa, ""), + METHOD_NO_ARGS(hasDelaySlot, ""), + METHOD_NO_ARGS(mapInstrToType, ""), + + METHOD_ARGS(sameOpcode, "description"), + METHOD_ARGS(sameOpcodeButDifferentArguments, "description"), + + METHOD_NO_ARGS(isValid, ""), + + METHOD_NO_ARGS(isUnknownType, ""), + METHOD_NO_ARGS(isJType, ""), + METHOD_NO_ARGS(isIType, ""), + METHOD_NO_ARGS(isRType, ""), + METHOD_NO_ARGS(isRegimmType, ""), + METHOD_NO_ARGS(isBranch, ""), + METHOD_NO_ARGS(isBranchLikely, ""), + METHOD_NO_ARGS(isJump, ""), + METHOD_NO_ARGS(isTrap, ""), + METHOD_NO_ARGS(isFloat, ""), + METHOD_NO_ARGS(isDouble, ""), + METHOD_NO_ARGS(isUnsigned, ""), + METHOD_NO_ARGS(modifiesRt, ""), + METHOD_NO_ARGS(modifiesRd, ""), + METHOD_NO_ARGS(notEmitedByCompilers, ""), + METHOD_NO_ARGS(canBeHi, ""), + METHOD_NO_ARGS(canBeLo, ""), + METHOD_NO_ARGS(doesLink, ""), + METHOD_NO_ARGS(doesDereference, ""), + METHOD_NO_ARGS(doesLoad, ""), + METHOD_NO_ARGS(doesStore, ""), + METHOD_NO_ARGS(maybeIsMove, ""), + METHOD_NO_ARGS(isPseudo, ""), + // METHOD_NO_ARGS(getArchitectureVersion, ""), + + METHOD_ARGS(disassemble, "description"), + + METHOD_ARGS(__reduce__, ""), + + { 0 }, +}; + + +static PyObject *rabbitizer_type_Instruction_repr(PyRabbitizerInstruction *self) { + PyObject *ret; + size_t disasmBufferSize; + char *bufferStart; + char *buffer; + size_t typeNameLength; + size_t extraSize = 3 + 8 + 4; // "(0x" + 32bits hex + ") # " + int len; + + typeNameLength = strlen("rabbitizer.Instruction"); + + disasmBufferSize = RabbitizerInstruction_getSizeForBuffer(&self->instr, 0, 0); + + buffer = bufferStart = malloc(disasmBufferSize+1 + typeNameLength + extraSize); + if (buffer == NULL) { + // TODO: signal an exception? + return NULL; + } + + memcpy(buffer, "rabbitizer.Instruction", typeNameLength); + buffer += typeNameLength; + + len = sprintf(buffer, "(0x%08X) # ", RabbitizerInstruction_getRaw(&self->instr)); + if (len != 15) { + // bad stuff + // TODO: exception? + } + assert(len == 15); + buffer += len; + + RabbitizerInstruction_disassemble(&self->instr, buffer, NULL, 0, 0); + + ret = PyUnicode_FromString(bufferStart); + free(bufferStart); + return ret; +} + +static PyObject *rabbitizer_type_Instruction_str(PyRabbitizerInstruction *self) { + return rabbitizer_type_Instruction_disassemble(self, Py_BuildValue("()"), Py_BuildValue("{}")); +} + + +PyTypeObject rabbitizer_type_Instruction_TypeObject = { + PyVarObject_HEAD_INIT(NULL, 0) + .tp_name = "rabbitizer.Instruction", + .tp_doc = PyDoc_STR("Instruction"), + .tp_basicsize = sizeof(PyRabbitizerInstruction), + .tp_itemsize = 0, + .tp_flags = Py_TPFLAGS_DEFAULT | Py_TPFLAGS_BASETYPE, + .tp_new = PyType_GenericNew, + .tp_init = (initproc) rabbitizer_type_Instruction_init, + .tp_dealloc = (destructor) rabbitizer_type_Instruction_dealloc, + .tp_repr = (reprfunc) rabbitizer_type_Instruction_repr, + .tp_str = (reprfunc) rabbitizer_type_Instruction_str, + .tp_members = rabbitizer_type_Instruction_members, + .tp_methods = rabbitizer_type_Instruction_methods, + .tp_getset = rabbitizer_type_Instruction_getsetters, +}; diff --git a/tools/ido-static-recomp/tools/rabbitizer/rabbitizer/rabbitizer_type_LoPairingInfo.c b/tools/ido-static-recomp/tools/rabbitizer/rabbitizer/rabbitizer_type_LoPairingInfo.c new file mode 100644 index 00000000..5a9c62cf --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/rabbitizer/rabbitizer_type_LoPairingInfo.c @@ -0,0 +1,50 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +#include "rabbitizer_module.h" + + +static void rabbitizer_type_LoPairingInfo_dealloc(PyRabbitizerLoPairingInfo *self) { + Py_TYPE(self)->tp_free((PyObject *) self); +} + +static int rabbitizer_type_LoPairingInfo_init(PyRabbitizerLoPairingInfo *self, PyObject *args, PyObject *kwds) { + static char *kwlist[] = { NULL }; + + if (!PyArg_ParseTupleAndKeywords(args, kwds, "", kwlist)) { + return -1; + } + + RabbitizerLoPairingInfo_Init(&self->pairingInfo); + + return 0; +} + + +static PyMemberDef rabbitizer_type_LoPairingInfo_members[] = { + { "instrOffset", T_INT, offsetof(PyRabbitizerLoPairingInfo, pairingInfo.instrOffset), 0, "" }, + { "value", T_LONG, offsetof(PyRabbitizerLoPairingInfo, pairingInfo.value), 0, "" }, + { "shouldProcess", T_BOOL, offsetof(PyRabbitizerLoPairingInfo, pairingInfo.shouldProcess), 0, "" }, + { "isGpRel", T_BOOL, offsetof(PyRabbitizerLoPairingInfo, pairingInfo.isGpRel), 0, "" }, + { "isGpGot", T_BOOL, offsetof(PyRabbitizerLoPairingInfo, pairingInfo.isGpGot), 0, "" }, + + { 0 } +}; + + +PyTypeObject rabbitizer_type_LoPairingInfo_TypeObject = { + PyVarObject_HEAD_INIT(NULL, 0) + .tp_name = "rabbitizer.LoPairingInfo", + .tp_doc = PyDoc_STR("LoPairingInfo"), + .tp_basicsize = sizeof(PyRabbitizerLoPairingInfo), + .tp_itemsize = 0, + .tp_flags = Py_TPFLAGS_DEFAULT | Py_TPFLAGS_BASETYPE, + .tp_new = PyType_GenericNew, + .tp_init = (initproc) rabbitizer_type_LoPairingInfo_init, + .tp_dealloc = (destructor) rabbitizer_type_LoPairingInfo_dealloc, + // .tp_repr = (reprfunc) rabbitizer_type_LoPairingInfo_repr, + // .tp_str = (reprfunc) rabbitizer_type_LoPairingInfo_str, + .tp_members = rabbitizer_type_LoPairingInfo_members, + // .tp_methods = rabbitizer_type_Instr_methods, + // .tp_getset = Instr_getsetters, +}; diff --git a/tools/ido-static-recomp/tools/rabbitizer/rabbitizer/rabbitizer_type_RegistersTracker.c b/tools/ido-static-recomp/tools/rabbitizer/rabbitizer/rabbitizer_type_RegistersTracker.c new file mode 100644 index 00000000..ec8f3642 --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/rabbitizer/rabbitizer_type_RegistersTracker.c @@ -0,0 +1,320 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +#include "rabbitizer_module.h" + +#include "analysis/RabbitizerRegistersTracker.h" + + +typedef struct PyRabbitizerRegistersTracker { + PyObject_HEAD + RabbitizerRegistersTracker tracker; +} PyRabbitizerRegistersTracker; + + +static void rabbitizer_type_RegistersTracker_dealloc(PyRabbitizerRegistersTracker *self) { + RabbitizerRegistersTracker_destroy(&self->tracker); + Py_TYPE(self)->tp_free((PyObject *) self); +} + +static int rabbitizer_type_RegistersTracker_init(PyRabbitizerRegistersTracker *self, PyObject *args, PyObject *kwds) { + static char *kwlist[] = { "other", NULL }; + PyRabbitizerRegistersTracker *pyOther = NULL; + RabbitizerRegistersTracker *other = NULL; + + if (!PyArg_ParseTupleAndKeywords(args, kwds, "|O!", kwlist, &rabbitizer_type_RegistersTracker_TypeObject, &pyOther)) { + return -1; + } + + if (pyOther != NULL) { + other = &pyOther->tracker; + } + + RabbitizerRegistersTracker_init(&self->tracker, other); + + return 0; +} + + +static PyObject *rabbitizer_type_RegistersTracker_moveRegisters(PyRabbitizerRegistersTracker *self, PyObject *args, PyObject *kwds) { + static char *kwlist[] = { "instr", NULL }; + PyRabbitizerInstruction *instr; + + if (!PyArg_ParseTupleAndKeywords(args, kwds, "O!", kwlist, &rabbitizer_type_Instruction_TypeObject, &instr)) { + return NULL; + } + + if (RabbitizerRegistersTracker_moveRegisters(&self->tracker, &instr->instr)) { + Py_RETURN_TRUE; + } + Py_RETURN_FALSE; +} + +static PyObject *rabbitizer_type_RegistersTracker_overwriteRegisters(PyRabbitizerRegistersTracker *self, PyObject *args, PyObject *kwds) { + static char *kwlist[] = { "instr", "instrOffset", NULL }; + PyRabbitizerInstruction *instr; + int instrOffset; + + if (!PyArg_ParseTupleAndKeywords(args, kwds, "O!i", kwlist, &rabbitizer_type_Instruction_TypeObject, &instr, &instrOffset)) { + return NULL; + } + + RabbitizerRegistersTracker_overwriteRegisters(&self->tracker, &instr->instr, instrOffset); + + Py_RETURN_NONE; +} + +static PyObject *rabbitizer_type_RegistersTracker_unsetRegistersAfterFuncCall(PyRabbitizerRegistersTracker *self, PyObject *args, PyObject *kwds) { + static char *kwlist[] = { "instr", "prevInstr", NULL }; + PyRabbitizerInstruction *instr; + PyRabbitizerInstruction *prevInstr; + + if (!PyArg_ParseTupleAndKeywords(args, kwds, "O!O!", kwlist, &rabbitizer_type_Instruction_TypeObject, &instr, &rabbitizer_type_Instruction_TypeObject, &prevInstr)) { + return NULL; + } + + RabbitizerRegistersTracker_unsetRegistersAfterFuncCall(&self->tracker, &instr->instr, &prevInstr->instr); + + Py_RETURN_NONE; +} + +static PyObject *rabbitizer_type_RegistersTracker_getAddressIfCanSetType(PyRabbitizerRegistersTracker *self, PyObject *args, PyObject *kwds) { + static char *kwlist[] = { "instr", "instrOffset", NULL }; + PyRabbitizerInstruction *instr; + int instrOffset; + uint32_t dstAddress = 0; + + if (!PyArg_ParseTupleAndKeywords(args, kwds, "O!i", kwlist, &rabbitizer_type_Instruction_TypeObject, &instr, &instrOffset)) { + return NULL; + } + + if (RabbitizerRegistersTracker_getAddressIfCanSetType(&self->tracker, &instr->instr, instrOffset, &dstAddress)) { + return PyLong_FromLong(dstAddress); + } + + Py_RETURN_NONE; +} + +static PyObject *rabbitizer_type_RegistersTracker_getJrInfo(PyRabbitizerRegistersTracker *self, PyObject *args, PyObject *kwds) { + static char *kwlist[] = { "instr", NULL }; + PyRabbitizerInstruction *instr; + int dstOffset = 0; + uint32_t dstAddress = 0; + + if (!PyArg_ParseTupleAndKeywords(args, kwds, "O!", kwlist, &rabbitizer_type_Instruction_TypeObject, &instr)) { + return NULL; + } + + if (RabbitizerRegistersTracker_getJrInfo(&self->tracker, &instr->instr, &dstOffset, &dstAddress)) { + return PyTuple_Pack(2, PyLong_FromLong(dstOffset), PyLong_FromLong(dstAddress)); + } + + Py_RETURN_NONE; +} + +static PyObject *rabbitizer_type_RegistersTracker_processLui(PyRabbitizerRegistersTracker *self, PyObject *args, PyObject *kwds) { + static char *kwlist[] = { "instr", "instrOffset", "prevInstr", NULL }; + PyRabbitizerInstruction *instr; + int instrOffset; + PyRabbitizerInstruction *pyPrevInstr = NULL; + RabbitizerInstruction *prevInstr = NULL; + + if (!PyArg_ParseTupleAndKeywords(args, kwds, "O!i|O!", kwlist, &rabbitizer_type_Instruction_TypeObject, &instr, &instrOffset, &rabbitizer_type_Instruction_TypeObject, &pyPrevInstr)) { + return NULL; + } + + if (pyPrevInstr != NULL) { + prevInstr = &pyPrevInstr->instr; + } + + RabbitizerRegistersTracker_processLui(&self->tracker, &instr->instr, instrOffset, prevInstr); + + Py_RETURN_NONE; +} + +static PyObject *rabbitizer_type_RegistersTracker_processGpLoad(PyRabbitizerRegistersTracker *self, PyObject *args, PyObject *kwds) { + static char *kwlist[] = { "instr", "instrOffset", NULL }; + PyRabbitizerInstruction *instr; + int instrOffset; + + if (!PyArg_ParseTupleAndKeywords(args, kwds, "O!i", kwlist, &rabbitizer_type_Instruction_TypeObject, &instr, &instrOffset)) { + return NULL; + } + + RabbitizerRegistersTracker_processGpLoad(&self->tracker, &instr->instr, instrOffset); + + Py_RETURN_NONE; +} + +static PyObject *rabbitizer_type_RegistersTracker_getLuiOffsetForConstant(PyRabbitizerRegistersTracker *self, PyObject *args, PyObject *kwds) { + static char *kwlist[] = { "instr", NULL }; + PyRabbitizerInstruction *instr; + int dstOffset = 0; + + if (!PyArg_ParseTupleAndKeywords(args, kwds, "O!", kwlist, &rabbitizer_type_Instruction_TypeObject, &instr)) { + return NULL; + } + + if (RabbitizerRegistersTracker_getLuiOffsetForConstant(&self->tracker, &instr->instr, &dstOffset)) { + return PyLong_FromLong(dstOffset); + } + + Py_RETURN_NONE; +} + +static PyObject *rabbitizer_type_RegistersTracker_processConstant(PyRabbitizerRegistersTracker *self, PyObject *args, PyObject *kwds) { + static char *kwlist[] = { "instr", "value", "instrOffset", NULL }; + PyRabbitizerInstruction *instr; + uint32_t value; + int instrOffset; + + if (!PyArg_ParseTupleAndKeywords(args, kwds, "O!Ii", kwlist, &rabbitizer_type_Instruction_TypeObject, &instr, &value, &instrOffset)) { + return NULL; + } + + RabbitizerRegistersTracker_processConstant(&self->tracker, &instr->instr, value, instrOffset); + + Py_RETURN_NONE; +} + +static PyObject *rabbitizer_type_RegistersTracker_getLuiOffsetForLo(PyRabbitizerRegistersTracker *self, PyObject *args, PyObject *kwds) { + static char *kwlist[] = { "instr", "instrOffset", NULL }; + PyRabbitizerInstruction *instr; + int instrOffset; + int dstOffset = 0; + bool dstIsGp = false; + bool validResults = false; + + if (!PyArg_ParseTupleAndKeywords(args, kwds, "O!i", kwlist, &rabbitizer_type_Instruction_TypeObject, &instr, &instrOffset)) { + return NULL; + } + + validResults = RabbitizerRegistersTracker_getLuiOffsetForLo(&self->tracker, &instr->instr, instrOffset, &dstOffset, &dstIsGp); + + return PyTuple_Pack(3, PyLong_FromLong(dstOffset), PyBool_FromLong(dstIsGp), PyBool_FromLong(validResults)); +} + +static PyObject *rabbitizer_type_RegistersTracker_preprocessLoAndGetInfo(PyRabbitizerRegistersTracker *self, PyObject *args, PyObject *kwds) { + static char *kwlist[] = { "instr", "instrOffset", NULL }; + PyRabbitizerInstruction *instr; + int instrOffset; + PyRabbitizerLoPairingInfo *ret; + + if (!PyArg_ParseTupleAndKeywords(args, kwds, "O!i", kwlist, &rabbitizer_type_Instruction_TypeObject, &instr, &instrOffset)) { + return NULL; + } + + ret = PyObject_CallObject((PyObject*)&rabbitizer_type_LoPairingInfo_TypeObject, NULL); + if (ret == NULL) { + PyErr_SetString(PyExc_RuntimeError, "Internal error: not able to instance LoPairingInfo object"); + return NULL; + } + + ret->pairingInfo = RabbitizerRegistersTracker_preprocessLoAndGetInfo(&self->tracker, &instr->instr, instrOffset); + + return ret; +} + +static PyObject *rabbitizer_type_RegistersTracker_processLo(PyRabbitizerRegistersTracker *self, PyObject *args, PyObject *kwds) { + static char *kwlist[] = { "instr", "value", "instrOffset", NULL }; + PyRabbitizerInstruction *instr; + uint32_t value; + int instrOffset; + + if (!PyArg_ParseTupleAndKeywords(args, kwds, "O!Ii", kwlist, &rabbitizer_type_Instruction_TypeObject, &instr, &value, &instrOffset)) { + return NULL; + } + + RabbitizerRegistersTracker_processLo(&self->tracker, &instr->instr, value, instrOffset); + + Py_RETURN_NONE; +} + +static PyObject *rabbitizer_type_RegistersTracker_hasLoButNoHi(PyRabbitizerRegistersTracker *self, PyObject *args, PyObject *kwds) { + static char *kwlist[] = { "instr", NULL }; + PyRabbitizerInstruction *instr; + + if (!PyArg_ParseTupleAndKeywords(args, kwds, "O!", kwlist, &rabbitizer_type_Instruction_TypeObject, &instr)) { + return NULL; + } + + if (RabbitizerRegistersTracker_hasLoButNoHi(&self->tracker, &instr->instr)) { + Py_RETURN_TRUE; + } + Py_RETURN_FALSE; +} + + +#define METHOD_NO_ARGS(name, docs) { #name, (PyCFunction)rabbitizer_type_RegistersTracker_##name, METH_NOARGS, PyDoc_STR(docs) } +#define METHOD_ARGS(name, docs) { #name, (PyCFunction)rabbitizer_type_RegistersTracker_##name, METH_VARARGS | METH_KEYWORDS, PyDoc_STR(docs) } + +static PyMethodDef rabbitizer_type_RegistersTracker_methods[] = { + METHOD_ARGS(moveRegisters, ""), + METHOD_ARGS(overwriteRegisters, ""), + METHOD_ARGS(unsetRegistersAfterFuncCall, ""), + METHOD_ARGS(getAddressIfCanSetType, ""), + METHOD_ARGS(getJrInfo, ""), + METHOD_ARGS(processLui, ""), + METHOD_ARGS(processGpLoad, ""), + METHOD_ARGS(getLuiOffsetForConstant, ""), + METHOD_ARGS(processConstant, ""), + METHOD_ARGS(getLuiOffsetForLo, ""), + METHOD_ARGS(preprocessLoAndGetInfo, ""), + METHOD_ARGS(processLo, ""), + METHOD_ARGS(hasLoButNoHi, ""), + + { 0 }, +}; + + +PyObject *rabbitizer_type_RegistersTracker___getitem__(PyRabbitizerRegistersTracker* self, Py_ssize_t index) { + RabbitizerTrackedRegisterState *state; + PyObject *args; + PyRabbitizerTrackedRegisterState *pyState; + + if (index < 0 || index >= ARRAY_COUNT(self->tracker.registers)) { + PyErr_SetString(PyExc_IndexError, "Index must be a value between 0 and 31"); + return NULL; + } + + state = &self->tracker.registers[index]; + + args = Py_BuildValue("(i)", state->registerNum); + if (args == NULL) { + PyErr_SetString(PyExc_RuntimeError, "Internal error: not able to instance TrackedRegisterState parameters"); + return NULL; + } + + pyState = PyObject_CallObject((PyObject*)&rabbitizer_type_TrackedRegisterState_TypeObject, args); + Py_DECREF(args); + if (pyState == NULL) { + PyErr_SetString(PyExc_RuntimeError, "Internal error: not able to instance TrackedRegisterState object"); + return NULL; + } + + RabbitizerTrackedRegisterState_copyState(&pyState->registerState, state); + return pyState; +} + + +static PySequenceMethods example_classSeqMethods = { + .sq_item = (ssizeargfunc)rabbitizer_type_RegistersTracker___getitem__, // sq_item +}; + + +PyTypeObject rabbitizer_type_RegistersTracker_TypeObject = { + PyVarObject_HEAD_INIT(NULL, 0) + .tp_name = "rabbitizer.RegistersTracker", + .tp_doc = PyDoc_STR("RegistersTracker"), + .tp_basicsize = sizeof(PyRabbitizerRegistersTracker), + .tp_itemsize = 0, + .tp_flags = Py_TPFLAGS_DEFAULT | Py_TPFLAGS_BASETYPE, + .tp_new = PyType_GenericNew, + .tp_init = (initproc) rabbitizer_type_RegistersTracker_init, + .tp_dealloc = (destructor) rabbitizer_type_RegistersTracker_dealloc, + // .tp_repr = (reprfunc) rabbitizer_type_RegistersTracker_repr, + .tp_as_sequence = &example_classSeqMethods, + // .tp_str = (reprfunc) rabbitizer_type_RegistersTracker_str, + .tp_methods = rabbitizer_type_RegistersTracker_methods, + // .tp_getset = rabbitizer_type_RegistersTracker_getsetters, +}; diff --git a/tools/ido-static-recomp/tools/rabbitizer/rabbitizer/rabbitizer_type_TrackedRegisterState.c b/tools/ido-static-recomp/tools/rabbitizer/rabbitizer/rabbitizer_type_TrackedRegisterState.c new file mode 100644 index 00000000..1f52e4d0 --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/rabbitizer/rabbitizer_type_TrackedRegisterState.c @@ -0,0 +1,102 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +#include "rabbitizer_module.h" + + +static void rabbitizer_type_TrackedRegisterState_dealloc(PyRabbitizerTrackedRegisterState *self) { + RabbitizerTrackedRegisterState_destroy(&self->registerState); + Py_TYPE(self)->tp_free((PyObject *) self); +} + +static int rabbitizer_type_TrackedRegisterState_init(PyRabbitizerTrackedRegisterState *self, PyObject *args, PyObject *kwds) { + static char *kwlist[] = { "registerNum", NULL }; + int registerNum; + + if (!PyArg_ParseTupleAndKeywords(args, kwds, "i", kwlist, ®isterNum)) { + return -1; + } + + RabbitizerTrackedRegisterState_init(&self->registerState, registerNum); + + return 0; +} + + +#define DEF_MEMBER_GET_BOOL(name) \ + static PyObject *rabbitizer_type_TrackedRegisterState_member_get_##name(PyRabbitizerTrackedRegisterState *self, UNUSED PyObject *closure) { \ + if (self->registerState.name) { \ + Py_RETURN_TRUE; \ + } \ + Py_RETURN_FALSE; \ + } + +#define DEF_MEMBER_GET_INT(name) \ + static PyObject *rabbitizer_type_TrackedRegisterState_member_get_##name(PyRabbitizerTrackedRegisterState *self, UNUSED PyObject *closure) { \ + return PyLong_FromLong(self->registerState.name); \ + } + +#define DEF_MEMBER_GET_UINT(name) \ + static PyObject *rabbitizer_type_TrackedRegisterState_member_get_##name(PyRabbitizerTrackedRegisterState *self, UNUSED PyObject *closure) { \ + return PyLong_FromUnsignedLong(self->registerState.name); \ + } + + +DEF_MEMBER_GET_INT(registerNum) + +DEF_MEMBER_GET_BOOL(hasLuiValue) +DEF_MEMBER_GET_INT(luiOffset) +DEF_MEMBER_GET_BOOL(luiSetOnBranchLikely) + +DEF_MEMBER_GET_BOOL(hasGpGot) +DEF_MEMBER_GET_INT(gpGotOffset) + +DEF_MEMBER_GET_BOOL(hasLoValue) +DEF_MEMBER_GET_INT(loOffset) +DEF_MEMBER_GET_BOOL(dereferenced) +DEF_MEMBER_GET_INT(dereferenceOffset) + +DEF_MEMBER_GET_UINT(value) + + +#define MEMBER_GET(name, docs, closure) { #name, (getter) rabbitizer_type_TrackedRegisterState_member_get_##name, (setter) NULL, PyDoc_STR(docs), closure } +#define MEMBER_SET(name, docs, closure) { #name, (getter) NULL, (setter) rabbitizer_type_TrackedRegisterState_member_set_##name, PyDoc_STR(docs), closure } +#define MEMBER_GET_SET(name, docs, closure) { #name, (getter) rabbitizer_type_TrackedRegisterState_member_get_##name, (setter) rabbitizer_type_TrackedRegisterState_member_set_##name, PyDoc_STR(docs), closure } + + +static PyGetSetDef rabbitizer_type_TrackedRegisterState_getsetters[] = { + MEMBER_GET(registerNum, "", NULL), + + MEMBER_GET(hasLuiValue, "", NULL), + MEMBER_GET(luiOffset, "", NULL), + MEMBER_GET(luiSetOnBranchLikely, "", NULL), + + MEMBER_GET(hasGpGot, "", NULL), + MEMBER_GET(gpGotOffset, "", NULL), + + MEMBER_GET(hasLoValue, "", NULL), + MEMBER_GET(loOffset, "", NULL), + MEMBER_GET(dereferenced, "", NULL), + MEMBER_GET(dereferenceOffset, "", NULL), + + MEMBER_GET(value, "", NULL), + + { 0 } +}; + + +PyTypeObject rabbitizer_type_TrackedRegisterState_TypeObject = { + PyVarObject_HEAD_INIT(NULL, 0) + .tp_name = "rabbitizer.TrackedRegisterState", + .tp_doc = PyDoc_STR("TrackedRegisterState"), + .tp_basicsize = sizeof(PyRabbitizerTrackedRegisterState), + .tp_itemsize = 0, + .tp_flags = Py_TPFLAGS_DEFAULT | Py_TPFLAGS_BASETYPE, + .tp_new = PyType_GenericNew, + .tp_init = (initproc) rabbitizer_type_TrackedRegisterState_init, + .tp_dealloc = (destructor) rabbitizer_type_TrackedRegisterState_dealloc, + // .tp_repr = (reprfunc) rabbitizer_type_TrackedRegisterState_repr, + // .tp_str = (reprfunc) rabbitizer_type_TrackedRegisterState_str, + // .tp_methods = rabbitizer_type_TrackedRegisterState_methods, + .tp_getset = rabbitizer_type_TrackedRegisterState_getsetters, +}; diff --git a/tools/ido-static-recomp/tools/rabbitizer/registersTrackerTest.c b/tools/ido-static-recomp/tools/rabbitizer/registersTrackerTest.c new file mode 100644 index 00000000..5aef0f83 --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/registersTrackerTest.c @@ -0,0 +1,41 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +#include "instructions/RabbitizerInstruction.h" +#include "analysis/RabbitizerRegistersTracker.h" + + +int main() { + RabbitizerRegistersTracker regsTracker; + RabbitizerInstruction instr; + uint32_t word = 0x002D0821; // addu $at, $at, $t5 + uint32_t vram = 0x0042F170; + int instrOffset = 220; + + RabbitizerRegistersTracker_init(®sTracker, NULL); + + RabbitizerInstruction_init(&instr, word, vram); + RabbitizerInstruction_processUniqueId(&instr); + + regsTracker.registers[1] = (RabbitizerTrackedRegisterState){ + .dereferenceOffset = 212, + .dereferenced = true, + .gpGotOffset = 212, + .hasGpGot = true, + .hasLoValue = true, + .hasLuiValue = false, + .loOffset = 212, + .luiOffset = 0, + .luiSetOnBranchLikely = false, + .value = 0x10010000, + .registerNum = regsTracker.registers[1].registerNum, + }; + + RabbitizerRegistersTracker_overwriteRegisters(®sTracker, &instr, instrOffset); + + RabbitizerInstruction_destroy(&instr); + + RabbitizerRegistersTracker_destroy(®sTracker); + + return 0; +} diff --git a/tools/ido-static-recomp/tools/rabbitizer/rsptest.c b/tools/ido-static-recomp/tools/rabbitizer/rsptest.c new file mode 100644 index 00000000..7aa04eef --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/rsptest.c @@ -0,0 +1,44 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +#include "instructions/RabbitizerInstructionRsp.h" + +#include +#include +#include +#include + + +int main() { + uint32_t word; + RabbitizerInstruction instr; + char *buffer; + int extraLJust = 5; + uint32_t validbits; + + //word = 0x4B01C8E8; // vand $v3, $v25, $v1[0] + word = 0x48952000; // mtc2 $21, $v4[0] + + RabbitizerInstructionRsp_init(&instr, word, 0x80000000); + + RabbitizerInstructionRsp_processUniqueId(&instr); + + buffer = malloc(RabbitizerInstruction_getSizeForBuffer(&instr, 0, extraLJust) + 1); + assert(buffer != NULL); + + RabbitizerInstruction_disassemble(&instr, buffer, NULL, 0, extraLJust); + + printf("%08X: %s\n", word, buffer); + + validbits = RabbitizerInstruction_getValidBits(&instr); + + printf("word: %08X\n", instr.word); + printf("mandatory bits: %08X\n", instr._mandatorybits); + printf("valid bits: %08X\n", validbits); + printf("invalid bits: %08X\n", (~validbits) & instr.word); + + free(buffer); + RabbitizerInstructionRsp_destroy(&instr); + + return 0; +} diff --git a/tools/ido-static-recomp/tools/rabbitizer/setup.cfg b/tools/ido-static-recomp/tools/rabbitizer/setup.cfg new file mode 100644 index 00000000..e2bd449e --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/setup.cfg @@ -0,0 +1,24 @@ +# SPDX-FileCopyrightText: © 2022 Decompollaborate +# SPDX-License-Identifier: MIT + +[metadata] +name = rabbitizer +# Version should be synced with include/common/RabbitizerVersion.h +version = 1.2.3 +author = Decompollaborate +license = MIT +description = MIPS instruction decoder +url = https://github.com/Decompollaborate/rabbitizer +project_urls = + Source = https://github.com/Decompollaborate/rabbitizer + Bug Tracker = https://github.com/Decompollaborate/rabbitizer/issues +long_description = file: README.md +long_description_content_type = text/markdown + +[options] +packages = rabbitizer + +[options.package_data] +rabbitizer = + **/*.pyi + **/py.typed diff --git a/tools/ido-static-recomp/tools/rabbitizer/setup.py b/tools/ido-static-recomp/tools/rabbitizer/setup.py new file mode 100644 index 00000000..2e048e69 --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/setup.py @@ -0,0 +1,28 @@ +# SPDX-FileCopyrightText: © 2022 Decompollaborate +# SPDX-License-Identifier: MIT + +from setuptools import setup, Extension + + +setup( + ext_modules=[ + Extension( + name="rabbitizer", + sources=["rabbitizer/rabbitizer_module.c", "rabbitizer/rabbitizer_submodule_Utils.c", "rabbitizer/rabbitizer_type_Instruction.c", "rabbitizer/rabbitizer_global_config.c", "rabbitizer/rabbitizer_type_TrackedRegisterState.c", "rabbitizer/rabbitizer_type_RegistersTracker.c", "rabbitizer/rabbitizer_type_LoPairingInfo.c", + "rabbitizer/enums/rabbitizer_type_Enum.c", "rabbitizer/enums/enums_utils.c", "rabbitizer/enums/rabbitizer_enum_InstrCategory.c", "rabbitizer/enums/rabbitizer_enum_InstrId.c", "rabbitizer/enums/rabbitizer_enum_Abi.c", + "rabbitizer/enums/registers/rabbitizer_enum_GprO32.c", "rabbitizer/enums/registers/rabbitizer_enum_GprN32.c", + "src/instructions/RabbitizerInstruction/RabbitizerInstruction_Disassemble.c", "src/instructions/RabbitizerInstruction/RabbitizerInstruction_ProcessUniqueId.c", "src/instructions/RabbitizerInstruction/RabbitizerInstruction.c", "src/instructions/RabbitizerInstruction/RabbitizerInstruction_Examination.c", + "src/instructions/RabbitizerInstructionRsp/RabbitizerInstructionRsp.c", "src/instructions/RabbitizerInstructionRsp/RabbitizerInstructionRsp_ProcessUniqueId.c", + "src/instructions/RabbitizerInstructionR5900/RabbitizerInstructionR5900.c", "src/instructions/RabbitizerInstructionR5900/RabbitizerInstructionR5900_ProcessUniqueId.c", + "src/instructions/RabbitizerInstrDescriptor.c", "src/instructions/RabbitizerInstrId.c", "src/instructions/RabbitizerRegister.c", "src/instructions/RabbitizerInstrSuffix.c", + "src/analysis/RabbitizerTrackedRegisterState.c", "src/analysis/RabbitizerRegistersTracker.c", "src/analysis/RabbitizerLoPairingInfo.c", + "src/common/Utils.c", "src/common/RabbitizerVersion.c", "src/common/RabbitizerConfig.c"], + include_dirs=["include", "rabbitizer"], + extra_compile_args = [ + "-std=c11", + "-Wall", + "-g", + ], + ), + ], +) diff --git a/tools/ido-static-recomp/tools/rabbitizer/src/analysis/RabbitizerLoPairingInfo.c b/tools/ido-static-recomp/tools/rabbitizer/src/analysis/RabbitizerLoPairingInfo.c new file mode 100644 index 00000000..0b4dc795 --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/src/analysis/RabbitizerLoPairingInfo.c @@ -0,0 +1,14 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +#include "analysis/RabbitizerLoPairingInfo.h" + +void RabbitizerLoPairingInfo_Init(RabbitizerLoPairingInfo *self) { + *self = (RabbitizerLoPairingInfo){ + .instrOffset = 0, + .value = 0, + .shouldProcess = false, + .isGpRel = false, + .isGpGot = false, + }; +} diff --git a/tools/ido-static-recomp/tools/rabbitizer/src/analysis/RabbitizerRegistersTracker.c b/tools/ido-static-recomp/tools/rabbitizer/src/analysis/RabbitizerRegistersTracker.c new file mode 100644 index 00000000..82913688 --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/src/analysis/RabbitizerRegistersTracker.c @@ -0,0 +1,425 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +#include "analysis/RabbitizerRegistersTracker.h" + +#include + +#include "common/Utils.h" +#include "common/RabbitizerConfig.h" +#include "instructions/RabbitizerRegister.h" + +// TODO: abi checks + +void RabbitizerRegistersTracker_init(RabbitizerRegistersTracker *self, const RabbitizerRegistersTracker *other) { + size_t i; + + for (i = 0; i < ARRAY_COUNT(self->registers); i++) { + RabbitizerTrackedRegisterState_init(&self->registers[i], i); + if (other != NULL) { + RabbitizerTrackedRegisterState_copyState(&self->registers[i], &other->registers[i]); + } + } +} + +void RabbitizerRegistersTracker_destroy(RabbitizerRegistersTracker *self) { + for (size_t i = 0; i < ARRAY_COUNT(self->registers); i++) { + RabbitizerTrackedRegisterState_destroy(&self->registers[i]); + } +} + +// TODO: simplify logic +bool RabbitizerRegistersTracker_moveRegisters(RabbitizerRegistersTracker *self, const RabbitizerInstruction *instr) { + RabbitizerTrackedRegisterState *dstState; + RabbitizerTrackedRegisterState *srcState; + uint8_t reg; + uint8_t rd = RAB_INSTR_GET_rd(instr); + uint8_t rs = RAB_INSTR_GET_rs(instr); + uint8_t rt = RAB_INSTR_GET_rt(instr); + + if (!RabbitizerInstrDescriptor_maybeIsMove(instr->descriptor)) { + return false; + } + if (rt == 0 && rs == 0) { + // ? + // RabbitizerTrackedRegisterState_clear(dstState); + return false; + } + + if (rt == 0) { + reg = rs; + } else if (rs == 0) { + reg = rt; + } else { + if (RabbitizerTrackedRegisterState_hasAnyValue(&self->registers[rs]) && !RabbitizerTrackedRegisterState_hasAnyValue(&self->registers[rt])) { + reg = rs; + } else if (RabbitizerTrackedRegisterState_hasAnyValue(&self->registers[rt]) && !RabbitizerTrackedRegisterState_hasAnyValue(&self->registers[rs])) { + reg = rt; + } else if (rd == rs) { // Check stuff like `addu $3, $3, $2` + reg = rt; + if (self->registers[rs].hasLuiValue || self->registers[rs].hasGpGot) { + reg = rs; + } + } else if (rd == rt) { + reg = rs; + if (self->registers[rt].hasLuiValue || self->registers[rt].hasGpGot) { + reg = rt; + } + } else { + // ? + // RabbitizerTrackedRegisterState_clear(dstState); + return false; + } + + srcState = &self->registers[reg]; + RabbitizerTrackedRegisterState_copyState(&self->registers[rd], srcState); + return true; + } + + srcState = &self->registers[reg]; + dstState = &self->registers[rd]; + + if (RabbitizerTrackedRegisterState_hasAnyValue(srcState)) { + RabbitizerTrackedRegisterState_copyState(dstState, srcState); + return true; + } + + RabbitizerTrackedRegisterState_clear(dstState); + return false; +} + +void RabbitizerRegistersTracker_overwriteRegisters(RabbitizerRegistersTracker *self, const RabbitizerInstruction *instr, int instrOffset) { + bool shouldRemove = false; + uint8_t reg = 0; + RabbitizerTrackedRegisterState *state = NULL; + + if (RabbitizerRegistersTracker_moveRegisters(self, instr)) { + return; + } + + if (RabbitizerInstrDescriptor_isFloat(instr->descriptor)) { + switch (instr->uniqueId) { + case RABBITIZER_INSTR_ID_cpu_mtc1: + case RABBITIZER_INSTR_ID_cpu_dmtc1: + case RABBITIZER_INSTR_ID_cpu_ctc1: + // IDO usually use a reg as a temp when loading a constant value + // into the float coprocessor, after that IDO never re-uses the value + // in that reg for anything else + shouldRemove = true; + reg = RAB_INSTR_GET_rt(instr); + break; + + default: + break; + } + } else if (RabbitizerInstrDescriptor_isRType(instr->descriptor) || + (RabbitizerInstrDescriptor_isBranch(instr->descriptor) && RabbitizerInstrDescriptor_isIType(instr->descriptor))) { + // $at usually is a one-use reg + uint8_t at = 0; + + if (RAB_INSTR_GET_rs(instr) == 1) { + at = RAB_INSTR_GET_rs(instr); + } else if (RAB_INSTR_GET_rt(instr) == 1) { + at = RAB_INSTR_GET_rt(instr); + } + + state = &self->registers[at]; + if (state->hasLoValue || state->hasLuiValue || state->hasGpGot) { + shouldRemove = true; + reg = at; + } + } + + if (RabbitizerInstrDescriptor_modifiesRt(instr->descriptor)) { + shouldRemove = true; + reg = RAB_INSTR_GET_rt(instr); + if (RabbitizerInstrDescriptor_canBeHi(instr->descriptor)) { + RabbitizerTrackedRegisterState_clearLo(&self->registers[RAB_INSTR_GET_rt(instr)]); + shouldRemove = false; + } + } + if (RabbitizerInstrDescriptor_modifiesRd(instr->descriptor)) { + shouldRemove = true; + reg = RAB_INSTR_GET_rd(instr); + } + + if (shouldRemove) { + state = &self->registers[reg]; +#if 0 + if (state->hasLuiValue) { + self->_printDebugInfo_clearRegister(instr, reg) + } +#endif + + RabbitizerTrackedRegisterState_clearHi(state); + if (!RabbitizerTrackedRegisterState_wasSetInCurrentOffset(state, instrOffset)) { + RabbitizerTrackedRegisterState_clearGp(state); + RabbitizerTrackedRegisterState_clearLo(state); + } + } +} + +void RabbitizerRegistersTracker_unsetRegistersAfterFuncCall(RabbitizerRegistersTracker *self, UNUSED const RabbitizerInstruction *instr, + const RabbitizerInstruction *prevInstr) { + RabbitizerTrackedRegisterState *state = NULL; + + if (!RabbitizerInstrDescriptor_doesLink(prevInstr->descriptor)) { + return; + } + + if (RabbitizerConfig_Cfg.regNames.gprAbiNames == RABBITIZER_ABI_O32 || RabbitizerConfig_Cfg.regNames.gprAbiNames == RABBITIZER_ABI_NUMERIC) { + for (size_t reg = 0; reg < ARRAY_COUNT(self->registers); reg++) { + switch (reg) { + case RABBITIZER_REG_GPR_O32_at: + case RABBITIZER_REG_GPR_O32_v0: + case RABBITIZER_REG_GPR_O32_v1: + case RABBITIZER_REG_GPR_O32_a0: + case RABBITIZER_REG_GPR_O32_a1: + case RABBITIZER_REG_GPR_O32_a2: + case RABBITIZER_REG_GPR_O32_a3: + case RABBITIZER_REG_GPR_O32_t0: + case RABBITIZER_REG_GPR_O32_t1: + case RABBITIZER_REG_GPR_O32_t2: + case RABBITIZER_REG_GPR_O32_t3: + case RABBITIZER_REG_GPR_O32_t4: + case RABBITIZER_REG_GPR_O32_t5: + case RABBITIZER_REG_GPR_O32_t6: + case RABBITIZER_REG_GPR_O32_t7: + case RABBITIZER_REG_GPR_O32_t8: + case RABBITIZER_REG_GPR_O32_t9: + case RABBITIZER_REG_GPR_O32_ra: + state = &self->registers[reg]; +#if 0 + if (state.hasLuiValue) { + self->_printDebugInfo_clearRegister(instr, reg) + } +#endif + RabbitizerTrackedRegisterState_clear(state); + break; + + default: + break; + } + } + } else if (RabbitizerConfig_Cfg.regNames.gprAbiNames == RABBITIZER_ABI_N32 || RabbitizerConfig_Cfg.regNames.gprAbiNames == RABBITIZER_ABI_N64) { + for (size_t reg = 0; reg < ARRAY_COUNT(self->registers); reg++) { + switch (reg) { + case RABBITIZER_REG_GPR_N32_at: + case RABBITIZER_REG_GPR_N32_v0: + case RABBITIZER_REG_GPR_N32_v1: + case RABBITIZER_REG_GPR_N32_a0: + case RABBITIZER_REG_GPR_N32_a1: + case RABBITIZER_REG_GPR_N32_a2: + case RABBITIZER_REG_GPR_N32_a3: + case RABBITIZER_REG_GPR_N32_a4: + case RABBITIZER_REG_GPR_N32_a5: + case RABBITIZER_REG_GPR_N32_a6: + case RABBITIZER_REG_GPR_N32_a7: + case RABBITIZER_REG_GPR_N32_t0: + case RABBITIZER_REG_GPR_N32_t1: + case RABBITIZER_REG_GPR_N32_t2: + case RABBITIZER_REG_GPR_N32_t3: + case RABBITIZER_REG_GPR_N32_t8: + case RABBITIZER_REG_GPR_N32_t9: + case RABBITIZER_REG_GPR_N32_ra: + state = &self->registers[reg]; +#if 0 + if (state.hasLuiValue) { + self->_printDebugInfo_clearRegister(instr, reg) + } +#endif + RabbitizerTrackedRegisterState_clear(state); + break; + + default: + break; + } + } + } +} + +bool RabbitizerRegistersTracker_getAddressIfCanSetType(const RabbitizerRegistersTracker *self, const RabbitizerInstruction *instr, int instrOffset, + uint32_t *dstAddress) { + const RabbitizerTrackedRegisterState *state = &self->registers[RAB_INSTR_GET_rs(instr)]; + + if (!state->hasLoValue) { + return false; + } + + if (!state->dereferenced || instrOffset == state->dereferenceOffset) { + *dstAddress = state->value; + return true; + } + + return false; +} + +bool RabbitizerRegistersTracker_getJrInfo(const RabbitizerRegistersTracker *self, const RabbitizerInstruction *instr, int *dstOffset, uint32_t *dstAddress) { + const RabbitizerTrackedRegisterState *state = &self->registers[RAB_INSTR_GET_rs(instr)]; + + if (!state->hasLoValue || !state->dereferenced) { + return false; + } + + *dstOffset = state->loOffset; + *dstAddress = state->value; + return true; +} + +// prevInstr can be NULL +void RabbitizerRegistersTracker_processLui(RabbitizerRegistersTracker *self, const RabbitizerInstruction *instr, int instrOffset, + const RabbitizerInstruction *prevInstr) { + RabbitizerTrackedRegisterState *state = NULL; + + assert(RabbitizerInstrDescriptor_canBeHi(instr->descriptor)); + + state = &self->registers[RAB_INSTR_GET_rt(instr)]; + RabbitizerTrackedRegisterState_clear(state); + RabbitizerTrackedRegisterState_setHi(state, RabbitizerInstruction_getImmediate(instr), instrOffset); + + if (prevInstr != NULL) { + // If the previous instructions is a branch likely, then nulify + // the effects of this instruction for future analysis + state->luiSetOnBranchLikely = RabbitizerInstrDescriptor_isBranchLikely(prevInstr->descriptor) || RabbitizerInstruction_isUnconditionalBranch(prevInstr); + } +} + +void RabbitizerRegistersTracker_processGpLoad(RabbitizerRegistersTracker *self, const RabbitizerInstruction *instr, int instrOffset) { + RabbitizerTrackedRegisterState *state = NULL; + + assert(RabbitizerInstrDescriptor_canBeLo(instr->descriptor)); + + state = &self->registers[RAB_INSTR_GET_rt(instr)]; + + RabbitizerTrackedRegisterState_clear(state); + RabbitizerTrackedRegisterState_setGpLoad(state, RabbitizerInstruction_getImmediate(instr), instrOffset); +} + +bool RabbitizerRegistersTracker_getLuiOffsetForConstant(const RabbitizerRegistersTracker *self, const RabbitizerInstruction *instr, int *dstOffset) { + const RabbitizerTrackedRegisterState *state = &self->registers[RAB_INSTR_GET_rs(instr)]; + + if (!state->hasLuiValue) { + return false; + } + + *dstOffset = state->luiOffset; + return true; +} + +void RabbitizerRegistersTracker_processConstant(RabbitizerRegistersTracker *self, const RabbitizerInstruction *instr, uint32_t value, int offset) { + RabbitizerTrackedRegisterState *stateDst = &self->registers[RAB_INSTR_GET_rt(instr)]; + + RabbitizerTrackedRegisterState_setLo(stateDst, value, offset); +} + +// TODO: this function should not be changing the state of the tracker +bool RabbitizerRegistersTracker_getLuiOffsetForLo(RabbitizerRegistersTracker *self, const RabbitizerInstruction *instr, int instrOffset, int *dstOffset, + bool *dstIsGp) { + const RabbitizerTrackedRegisterState *state = &self->registers[RAB_INSTR_GET_rs(instr)]; + + if (state->hasLuiValue && !state->luiSetOnBranchLikely) { + *dstOffset = state->luiOffset; + *dstIsGp = false; + return true; + } + + // TODO: abi + if (RAB_INSTR_GET_rs(instr) == 28) { // $gp + *dstOffset = 0; + *dstIsGp = true; + return true; + } + + if (RabbitizerInstrDescriptor_modifiesRt(instr->descriptor) && RabbitizerInstrDescriptor_doesDereference(instr->descriptor)) { + if (state->hasLoValue && !state->dereferenced) { + // Simulate a dereference + RabbitizerTrackedRegisterState_dereferenceState(&self->registers[RAB_INSTR_GET_rt(instr)], state, instrOffset); + } + } + + return false; +} + +RabbitizerLoPairingInfo RabbitizerRegistersTracker_preprocessLoAndGetInfo(RabbitizerRegistersTracker *self, const RabbitizerInstruction *instr, + int instrOffset) { + const RabbitizerTrackedRegisterState *state = &self->registers[RAB_INSTR_GET_rs(instr)]; + RabbitizerLoPairingInfo pairingInfo; + + RabbitizerLoPairingInfo_Init(&pairingInfo); + + if (state->hasLuiValue && !state->luiSetOnBranchLikely) { + pairingInfo.instrOffset = state->luiOffset; + pairingInfo.value = state->value; + pairingInfo.shouldProcess = true; + return pairingInfo; + } + + if ((RAB_INSTR_GET_rs(instr) == RABBITIZER_REG_GPR_O32_gp) || (RAB_INSTR_GET_rs(instr) == RABBITIZER_REG_GPR_N32_gp)) { + pairingInfo.value = state->value; + pairingInfo.isGpRel = true; + pairingInfo.shouldProcess = true; + return pairingInfo; + } + + if (state->hasGpGot) { + pairingInfo.instrOffset = state->gpGotOffset; + pairingInfo.value = state->value; + pairingInfo.shouldProcess = true; + pairingInfo.isGpGot = true; + return pairingInfo; + } + + if (RabbitizerInstrDescriptor_modifiesRt(instr->descriptor) && RabbitizerInstrDescriptor_doesDereference(instr->descriptor)) { + if (state->hasLoValue && !state->dereferenced) { + // Simulate a dereference + RabbitizerTrackedRegisterState_dereferenceState(&self->registers[RAB_INSTR_GET_rt(instr)], state, instrOffset); + } + } + + return pairingInfo; +} + +void RabbitizerRegistersTracker_processLo(RabbitizerRegistersTracker *self, const RabbitizerInstruction *instr, uint32_t value, int offset) { + RabbitizerTrackedRegisterState *stateDst; + + if (!RabbitizerInstrDescriptor_modifiesRt(instr->descriptor)) { + return; + } + + stateDst = &self->registers[RAB_INSTR_GET_rt(instr)]; + RabbitizerTrackedRegisterState_setLo(stateDst, value, offset); + if (RabbitizerInstrDescriptor_doesDereference(instr->descriptor)) { + RabbitizerTrackedRegisterState_deref(stateDst, offset); + } + if (RAB_INSTR_GET_rt(instr) == RAB_INSTR_GET_rs(instr)) { + RabbitizerTrackedRegisterState_clearHi(stateDst); + RabbitizerTrackedRegisterState_clearGp(stateDst); + } +} + +bool RabbitizerRegistersTracker_hasLoButNoHi(const RabbitizerRegistersTracker *self, const RabbitizerInstruction *instr) { + const RabbitizerTrackedRegisterState *state; + + assert(instr != NULL); + + state = &self->registers[RAB_INSTR_GET_rs(instr)]; + return state->hasLoValue && !state->hasLuiValue; +} + +#if 0 +def _printDebugInfo_clearRegister(self, instr: rabbitizer.Instruction, reg: int, currentVram: int|None=None) -> None: + if not common.GlobalConfig.PRINT_SYMBOL_FINDER_DEBUG_INFO: + return + + if currentVram is None: + return + + print("Clearing reg:") + // print() + print(f"vram: {currentVram:X}") + print(instr) + print(self->registers) + // TODO + // print(f"deleting {reg} / {instr->getRegisterName(reg)}") + print() +#endif diff --git a/tools/ido-static-recomp/tools/rabbitizer/src/analysis/RabbitizerTrackedRegisterState.c b/tools/ido-static-recomp/tools/rabbitizer/src/analysis/RabbitizerTrackedRegisterState.c new file mode 100644 index 00000000..91298945 --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/src/analysis/RabbitizerTrackedRegisterState.c @@ -0,0 +1,142 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +#include "analysis/RabbitizerTrackedRegisterState.h" + +#include + +#include "common/Utils.h" +#include "instructions/RabbitizerRegister.h" + +void RabbitizerTrackedRegisterState_init(RabbitizerTrackedRegisterState *self, int registerNum) { + self->registerNum = registerNum; + + self->hasLuiValue = false; + self->luiOffset = 0; + self->luiSetOnBranchLikely = false; + + self->hasGpGot = false; + self->gpGotOffset = 0; + + self->hasLoValue = false; + self->loOffset = 0; + self->dereferenced = false; + self->dereferenceOffset = 0; + + self->value = 0; +} + +void RabbitizerTrackedRegisterState_destroy(UNUSED RabbitizerTrackedRegisterState *self) { +} + +void RabbitizerTrackedRegisterState_clear(RabbitizerTrackedRegisterState *self) { + self->hasLuiValue = false; + self->luiOffset = 0; + self->luiSetOnBranchLikely = false; + + self->hasGpGot = false; + self->gpGotOffset = 0; + + self->hasLoValue = false; + self->loOffset = 0; + self->dereferenced = false; + self->dereferenceOffset = 0; + self->value = 0; +} + +void RabbitizerTrackedRegisterState_clearHi(RabbitizerTrackedRegisterState *self) { + self->hasLuiValue = false; + self->luiOffset = 0; + self->luiSetOnBranchLikely = false; +} + +void RabbitizerTrackedRegisterState_clearGp(RabbitizerTrackedRegisterState *self) { + self->hasGpGot = false; + self->gpGotOffset = 0; +} + +void RabbitizerTrackedRegisterState_clearLo(RabbitizerTrackedRegisterState *self) { + self->hasLoValue = false; + self->loOffset = 0; + self->dereferenced = false; + self->dereferenceOffset = 0; +} + +void RabbitizerTrackedRegisterState_copyState(RabbitizerTrackedRegisterState *self, const RabbitizerTrackedRegisterState *other) { + self->hasLuiValue = other->hasLuiValue; + self->luiOffset = other->luiOffset; + self->luiSetOnBranchLikely = other->luiSetOnBranchLikely; + + self->hasGpGot = other->hasGpGot; + self->gpGotOffset = other->gpGotOffset; + + self->hasLoValue = other->hasLoValue; + self->loOffset = other->loOffset; + self->dereferenced = other->dereferenced; + self->dereferenceOffset = other->dereferenceOffset; + + self->value = other->value; +} + +void RabbitizerTrackedRegisterState_setHi(RabbitizerTrackedRegisterState *self, uint32_t value, int offset) { + assert(!self->hasGpGot); + + self->hasLuiValue = true; + self->luiOffset = offset; + self->value = value << 16; +} + +void RabbitizerTrackedRegisterState_setGpLoad(RabbitizerTrackedRegisterState *self, uint32_t value, int offset) { + assert(!self->hasLuiValue); + + self->hasGpGot = true; + self->gpGotOffset = offset; + self->value = value; +} + +void RabbitizerTrackedRegisterState_setLo(RabbitizerTrackedRegisterState *self, uint32_t value, int offset) { + self->value = value; + self->loOffset = offset; + self->hasLoValue = true; + self->dereferenced = false; + self->dereferenceOffset = 0; +} + +void RabbitizerTrackedRegisterState_deref(RabbitizerTrackedRegisterState *self, int offset) { + self->dereferenced = true; + self->dereferenceOffset = offset; +} + +void RabbitizerTrackedRegisterState_dereferenceState(RabbitizerTrackedRegisterState *self, const RabbitizerTrackedRegisterState *other, int offset) { + assert(other->hasLoValue); + assert(!other->dereferenced); + + RabbitizerTrackedRegisterState_copyState(self, other); + RabbitizerTrackedRegisterState_deref(self, offset); +} + +bool RabbitizerTrackedRegisterState_hasAnyValue(const RabbitizerTrackedRegisterState *self) { + return self->hasLuiValue || self->hasLoValue || self->hasGpGot; +} + +bool RabbitizerTrackedRegisterState_wasSetInCurrentOffset(const RabbitizerTrackedRegisterState *self, int offset) { + return self->loOffset == offset || self->dereferenceOffset == offset; +} + +void RabbitizerTrackedRegisterState_fprint(const RabbitizerTrackedRegisterState *self, FILE *outFile) { + fprintf(outFile, "TrackedRegisterState(%i / %s)\n", self->registerNum, RabbitizerRegister_getNameGpr(self->registerNum)); + + fprintf(outFile, " hasLuiValue: %s\n", self->hasLuiValue ? "true" : "false"); + fprintf(outFile, " luiOffset: 0x%X\n", self->luiOffset); + fprintf(outFile, " luiSetOnBranchLikely: %s\n", self->luiSetOnBranchLikely ? "true" : "false"); + + fprintf(outFile, " hasGpGot: %s\n", self->hasGpGot ? "true" : "false"); + fprintf(outFile, " gpGotOffset: 0x%X\n", self->gpGotOffset); + + fprintf(outFile, " hasLoValue: %s\n", self->hasLoValue ? "true" : "false"); + fprintf(outFile, " loOffset: %X\n", self->loOffset); + fprintf(outFile, " dereferenced: %s\n", self->dereferenced ? "true" : "false"); + fprintf(outFile, " dereferenceOffset: %X\n", self->dereferenceOffset); + + fprintf(outFile, " value: %X\n", self->value); +} diff --git a/tools/ido-static-recomp/tools/rabbitizer/src/common/RabbitizerConfig.c b/tools/ido-static-recomp/tools/rabbitizer/src/common/RabbitizerConfig.c new file mode 100644 index 00000000..88b554db --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/src/common/RabbitizerConfig.c @@ -0,0 +1,50 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +#include "common/RabbitizerConfig.h" + +#include + +RabbitizerAbi RabbitizerAbi_fromStr(const char *name) { + if (name == NULL || strcmp(name, "32") == 0 || strcmp(name, "o32") == 0 || strcmp(name, "O32") == 0) { + return RABBITIZER_ABI_O32; + } + if (strcmp(name, "n32") == 0 || strcmp(name, "N32") == 0) { + return RABBITIZER_ABI_N32; + } + if (strcmp(name, "64") == 0 || strcmp(name, "n64") == 0 || strcmp(name, "N64") == 0) { + return RABBITIZER_ABI_N64; + } + return RABBITIZER_ABI_NUMERIC; +} + +RabbitizerConfig RabbitizerConfig_Cfg = { + .regNames = { + .namedRegisters = true, + .gprAbiNames = RABBITIZER_ABI_O32, + .fprAbiNames = RABBITIZER_ABI_NUMERIC, + .userFpcCsr = true, + .vr4300Cop0NamedRegisters = true, + .vr4300RspCop0NamedRegisters = true, + }, + .pseudos = { + .enablePseudos = true, + .pseudoBeqz = true, + .pseudoBnez = true, + .pseudoB = true, + .pseudoMove = true, + .pseudoNot = true, + .pseudoNegu = true, + .pseudoBal = true, + }, + .toolchainTweaks = { + .treatJAsUnconditionalBranch = false, + .sn64DivFix = false, + }, + .misc = { + .opcodeLJust = 7+4, + .unknownInstrComment = true, + .omit0XOnSmallImm = false, + .upperCaseImm = true, + } +}; diff --git a/tools/ido-static-recomp/tools/rabbitizer/src/common/RabbitizerVersion.c b/tools/ido-static-recomp/tools/rabbitizer/src/common/RabbitizerVersion.c new file mode 100644 index 00000000..f700fbfe --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/src/common/RabbitizerVersion.c @@ -0,0 +1,10 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +#include "common/RabbitizerVersion.h" + +const int RabVersion_Major = RAB_VERSION_MAJOR; +const int RabVersion_Minor = RAB_VERSION_MINOR; +const int RabVersion_Patch = RAB_VERSION_PATCH; + +const char RabVersion_Str[] = RAB_VERSION_STR; diff --git a/tools/ido-static-recomp/tools/rabbitizer/src/common/Utils.c b/tools/ido-static-recomp/tools/rabbitizer/src/common/Utils.c new file mode 100644 index 00000000..7dd02622 --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/src/common/Utils.c @@ -0,0 +1,78 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +#include "common/Utils.h" + +#include +#include + +int32_t RabbitizerUtils_From2Complement(uint32_t number, int bits) { + bool isNegative = number & (1ULL << (bits - 1)); + + if (isNegative) { + return -((~number + 1) & ((1ULL << bits) - 1)); + } + + return number; +} + +size_t RabbitizerUtils_CharFill(char *dst, int count, char fillchar) { + if (count <= 0) { + return 0; + } + + memset(dst, fillchar, count); + + return count; +} + +size_t RabbitizerUtils_escapeString(char *dst, size_t dstSize, const char *src, size_t srcSize) { + size_t srcPos = 0; + size_t dstpos = 0; + + for (; srcPos < srcSize && dstpos < dstSize; srcPos++, src++) { + // The cases of this switch are sorted by ASCII order + switch (*src) { + case '\a': + RABUTILS_BUFFER_WRITE_CHAR(dst, dstpos, '\\'); + RABUTILS_BUFFER_WRITE_CHAR(dst, dstpos, 'a'); + break; + + case '\t': + RABUTILS_BUFFER_WRITE_CHAR(dst, dstpos, '\\'); + RABUTILS_BUFFER_WRITE_CHAR(dst, dstpos, 't'); + break; + + case '\n': + RABUTILS_BUFFER_WRITE_CHAR(dst, dstpos, '\\'); + RABUTILS_BUFFER_WRITE_CHAR(dst, dstpos, 'n'); + break; + + case '\f': + RABUTILS_BUFFER_WRITE_CHAR(dst, dstpos, '\\'); + RABUTILS_BUFFER_WRITE_CHAR(dst, dstpos, 'f'); + break; + + case '\r': + RABUTILS_BUFFER_WRITE_CHAR(dst, dstpos, '\\'); + RABUTILS_BUFFER_WRITE_CHAR(dst, dstpos, 'r'); + break; + + case '"': + RABUTILS_BUFFER_WRITE_CHAR(dst, dstpos, '\\'); + RABUTILS_BUFFER_WRITE_CHAR(dst, dstpos, '"'); + break; + + case '\\': + RABUTILS_BUFFER_WRITE_CHAR(dst, dstpos, '\\'); + RABUTILS_BUFFER_WRITE_CHAR(dst, dstpos, '\\'); + break; + + default: + RABUTILS_BUFFER_WRITE_CHAR(dst, dstpos, *src); + break; + } + } + + return dstpos; +} diff --git a/tools/ido-static-recomp/tools/rabbitizer/src/instructions/RabbitizerInstrDescriptor.c b/tools/ido-static-recomp/tools/rabbitizer/src/instructions/RabbitizerInstrDescriptor.c new file mode 100644 index 00000000..a6e143f9 --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/src/instructions/RabbitizerInstrDescriptor.c @@ -0,0 +1,104 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +#include "instructions/RabbitizerInstrDescriptor.h" + +#include "instructions/RabbitizerInstruction.h" + +#define RABBITIZER_DEF_INSTR_ID(prefix, caseBits, name, ...) [RABBITIZER_INSTR_ID_##prefix##_##name] = { __VA_ARGS__ }, + +#define RABBITIZER_DEF_INSTR_ID_ALTNAME(prefix, caseBits, name, altname, ...) RABBITIZER_DEF_INSTR_ID(prefix, caseBits, name, __VA_ARGS__) + +const RabbitizerInstrDescriptor RabbitizerInstrDescriptor_Descriptors[] = { +#include "instructions/instr_id/RabbitizerInstrId_cpu.inc" +#include "instructions/instr_id/RabbitizerInstrId_rsp.inc" +#include "instructions/instr_id/RabbitizerInstrId_r5900.inc" +}; + +#undef RABBITIZER_DEF_INSTR_ID +#undef RABBITIZER_DEF_INSTR_ID_ALTNAME + +bool RabbitizerInstrDescriptor_isUnknownType(const RabbitizerInstrDescriptor *self) { + return self->instrType == RABBITIZER_INSTR_TYPE_UNKNOWN; +} +bool RabbitizerInstrDescriptor_isJType(const RabbitizerInstrDescriptor *self) { + return self->instrType == RABBITIZER_INSTR_TYPE_J; +} +bool RabbitizerInstrDescriptor_isIType(const RabbitizerInstrDescriptor *self) { + return self->instrType == RABBITIZER_INSTR_TYPE_I; +} +bool RabbitizerInstrDescriptor_isRType(const RabbitizerInstrDescriptor *self) { + return self->instrType == RABBITIZER_INSTR_TYPE_R; +} +bool RabbitizerInstrDescriptor_isRegimmType(const RabbitizerInstrDescriptor *self) { + return self->instrType == RABBITIZER_INSTR_TYPE_REGIMM; +} + +RabbitizerInstrSuffix RabbitizerInstrDescriptor_instrSuffix(const RabbitizerInstrDescriptor *self) { + return self->instrSuffix; +} + +bool RabbitizerInstrDescriptor_isBranch(const RabbitizerInstrDescriptor *self) { + return self->isBranch; +} +bool RabbitizerInstrDescriptor_isBranchLikely(const RabbitizerInstrDescriptor *self) { + return self->isBranchLikely; +} +bool RabbitizerInstrDescriptor_isJump(const RabbitizerInstrDescriptor *self) { + return self->isJump; +} +bool RabbitizerInstrDescriptor_isTrap(const RabbitizerInstrDescriptor *self) { + return self->isTrap; +} + +bool RabbitizerInstrDescriptor_isFloat(const RabbitizerInstrDescriptor *self) { + return self->isFloat; +} +bool RabbitizerInstrDescriptor_isDouble(const RabbitizerInstrDescriptor *self) { + return self->isDouble; +} + +bool RabbitizerInstrDescriptor_isUnsigned(const RabbitizerInstrDescriptor *self) { + return self->isUnsigned; +} + +bool RabbitizerInstrDescriptor_modifiesRt(const RabbitizerInstrDescriptor *self) { + return self->modifiesRt; +} +bool RabbitizerInstrDescriptor_modifiesRd(const RabbitizerInstrDescriptor *self) { + return self->modifiesRd; +} + +bool RabbitizerInstrDescriptor_notEmitedByCompilers(const RabbitizerInstrDescriptor *self) { + return self->notEmitedByCompilers; +} + +bool RabbitizerInstrDescriptor_canBeHi(const RabbitizerInstrDescriptor *self) { + return self->canBeHi; +} +bool RabbitizerInstrDescriptor_canBeLo(const RabbitizerInstrDescriptor *self) { + return self->canBeLo; +} +bool RabbitizerInstrDescriptor_doesLink(const RabbitizerInstrDescriptor *self) { + return self->doesLink; +} +bool RabbitizerInstrDescriptor_doesDereference(const RabbitizerInstrDescriptor *self) { + return self->doesDereference; +} +bool RabbitizerInstrDescriptor_doesLoad(const RabbitizerInstrDescriptor *self) { + return self->doesLoad; +} +bool RabbitizerInstrDescriptor_doesStore(const RabbitizerInstrDescriptor *self) { + return self->doesStore; +} +bool RabbitizerInstrDescriptor_maybeIsMove(const RabbitizerInstrDescriptor *self) { + return self->maybeIsMove; +} + +bool RabbitizerInstrDescriptor_isPseudo(const RabbitizerInstrDescriptor *self) { + return self->isPseudo; +} + +RabbitizerArchitectureVersion RabbitizerInstrDescriptor_getArchitectureVersion(const RabbitizerInstrDescriptor *self) { + return self->architectureVersion; +} diff --git a/tools/ido-static-recomp/tools/rabbitizer/src/instructions/RabbitizerInstrId.c b/tools/ido-static-recomp/tools/rabbitizer/src/instructions/RabbitizerInstrId.c new file mode 100644 index 00000000..b8643314 --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/src/instructions/RabbitizerInstrId.c @@ -0,0 +1,28 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +#include "instructions/RabbitizerInstrId.h" + +#include + +#define RABBITIZER_DEF_INSTR_ID(prefix, caseBits, name, ...) [RABBITIZER_INSTR_ID_##prefix##_##name] = #name, + +#define RABBITIZER_DEF_INSTR_ID_ALTNAME(prefix, caseBits, name, altname, ...) [RABBITIZER_INSTR_ID_##prefix##_##name] = #altname, + +const char *RabbitizerInstrId_Names[] = { +#include "instructions/instr_id/RabbitizerInstrId_cpu.inc" +#include "instructions/instr_id/RabbitizerInstrId_rsp.inc" +#include "instructions/instr_id/RabbitizerInstrId_r5900.inc" +}; + +#undef RABBITIZER_DEF_INSTR_ID +#undef RABBITIZER_DEF_INSTR_ID_ALTNAME + +const char *RabbitizerInstrId_getOpcodeName(RabbitizerInstrId uniqueId) { + assert(uniqueId >= RABBITIZER_INSTR_ID_cpu_INVALID && uniqueId < RABBITIZER_INSTR_ID_ALL_MAX); + assert(uniqueId != RABBITIZER_INSTR_ID_cpu_MAX); + assert(uniqueId != RABBITIZER_INSTR_ID_rsp_MAX); + assert(uniqueId != RABBITIZER_INSTR_ID_r5900_MAX); + + return RabbitizerInstrId_Names[uniqueId]; +} diff --git a/tools/ido-static-recomp/tools/rabbitizer/src/instructions/RabbitizerInstrSuffix.c b/tools/ido-static-recomp/tools/rabbitizer/src/instructions/RabbitizerInstrSuffix.c new file mode 100644 index 00000000..cef16b30 --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/src/instructions/RabbitizerInstrSuffix.c @@ -0,0 +1,62 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +#include "instructions/RabbitizerInstrSuffix.h" + +#include + +#include "common/Utils.h" +#include "instructions/RabbitizerInstruction.h" +#include "instructions/RabbitizerInstructionRsp.h" +#include "instructions/RabbitizerInstructionR5900.h" + +typedef size_t (*InstrSuffixCallback)(const RabbitizerInstruction *self, char *dst); + +size_t RabbitizerInstrSuffix_None(UNUSED const RabbitizerInstruction *self, UNUSED char *dst) { + return 0; +} + +size_t RabbitizerInstrSuffixR5900_xyzw(const RabbitizerInstruction *self, char *dst) { + size_t totalSize = 0; + + if (RAB_INSTR_R5900_GET_xyzw_x(self) || RAB_INSTR_R5900_GET_xyzw_y(self) || RAB_INSTR_R5900_GET_xyzw_z(self) || RAB_INSTR_R5900_GET_xyzw_w(self)) { + RABUTILS_BUFFER_WRITE_CHAR(dst, totalSize, '.'); + } + + if (RAB_INSTR_R5900_GET_xyzw_x(self)) { + RABUTILS_BUFFER_WRITE_CHAR(dst, totalSize, 'x'); + } + if (RAB_INSTR_R5900_GET_xyzw_y(self)) { + RABUTILS_BUFFER_WRITE_CHAR(dst, totalSize, 'y'); + } + if (RAB_INSTR_R5900_GET_xyzw_z(self)) { + RABUTILS_BUFFER_WRITE_CHAR(dst, totalSize, 'z'); + } + if (RAB_INSTR_R5900_GET_xyzw_w(self)) { + RABUTILS_BUFFER_WRITE_CHAR(dst, totalSize, 'w'); + } + + return totalSize; +} +const InstrSuffixCallback instrSuffixCallbacks[] = { + [RABINSTRSUFFIX_NONE] = RabbitizerInstrSuffix_None, + + [RABINSTRSUFFIX_R5900_xyzw] = RabbitizerInstrSuffixR5900_xyzw, +}; + +size_t RabbitizerInstrSuffix_getSizeForBuffer(UNUSED const RabbitizerInstruction *self, UNUSED RabbitizerInstrSuffix instrSuffix) { + // Just hardcode the size of the bigger possible suffix, faster than actually computing it. + return 5; +} + +size_t RabbitizerInstrSuffix_processSuffix(const RabbitizerInstruction *self, char *dst, RabbitizerInstrSuffix instrSuffix) { + InstrSuffixCallback callback; + + assert(instrSuffix >= RABINSTRSUFFIX_NONE); + assert(instrSuffix < RABINSTRSUFFIX_MAX); + + callback = instrSuffixCallbacks[instrSuffix]; + assert(callback != NULL); + + return callback(self, dst); +} diff --git a/tools/ido-static-recomp/tools/rabbitizer/src/instructions/RabbitizerInstruction/RabbitizerInstruction.c b/tools/ido-static-recomp/tools/rabbitizer/src/instructions/RabbitizerInstruction/RabbitizerInstruction.c new file mode 100644 index 00000000..5e0bf056 --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/src/instructions/RabbitizerInstruction/RabbitizerInstruction.c @@ -0,0 +1,368 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +#include "instructions/RabbitizerInstruction.h" + +#include + +#include "common/RabbitizerConfig.h" +#include "instructions/RabbitizerRegister.h" +#include "instructions/RabbitizerInstructionRsp.h" +#include "instructions/RabbitizerInstructionR5900.h" + +void RabbitizerInstruction_init(RabbitizerInstruction *self, uint32_t word, uint32_t vram) { + self->word = word; + self->_mandatorybits = 0; + + self->uniqueId = RABBITIZER_INSTR_ID_cpu_INVALID; + self->descriptor = &RabbitizerInstrDescriptor_Descriptors[self->uniqueId]; + + self->vram = vram; + self->_handwrittenCategory = false; + self->inHandwrittenFunction = false; + self->category = RABBITIZER_INSTRCAT_CPU; +} + +void RabbitizerInstruction_destroy(UNUSED RabbitizerInstruction *self) { +} + +/* General getters */ + +uint32_t RabbitizerInstruction_getRaw(const RabbitizerInstruction *self) { + return self->word; +} + +uint32_t RabbitizerInstruction_getImmediate(const RabbitizerInstruction *self) { + return RAB_INSTR_GET_immediate(self); +} +int32_t RabbitizerInstruction_getProcessedImmediate(const RabbitizerInstruction *self) { + if (RabbitizerInstrDescriptor_isUnsigned(self->descriptor)) { + return RAB_INSTR_GET_immediate(self); + } + return RabbitizerUtils_From2Complement(RAB_INSTR_GET_immediate(self), 16); +} + +uint32_t RabbitizerInstruction_getInstrIndex(const RabbitizerInstruction *self) { + return RAB_INSTR_GET_instr_index(self); +} + +uint32_t RabbitizerInstruction_getInstrIndexAsVram(const RabbitizerInstruction *self) { + uint32_t vram = RabbitizerInstruction_getInstrIndex(self) << 2; + + if (self->vram == 0) { + vram |= 0x80000000; + } else { + // Jumps are PC-region branches. The upper bits are filled with the address in the delay slot + vram |= (self->vram + 4) & 0xFF000000; + } + return vram; +} + +int32_t RabbitizerInstruction_getBranchOffset(const RabbitizerInstruction *self) { + int32_t diff = RabbitizerUtils_From2Complement(RabbitizerInstruction_getImmediate(self), 16); + + return diff * 4 + 4; +} + +int32_t RabbitizerInstruction_getGenericBranchOffset(const RabbitizerInstruction *self, uint32_t currentVram) { + if (self->uniqueId == RABBITIZER_INSTR_ID_cpu_j) { + return RabbitizerInstruction_getInstrIndexAsVram(self) - currentVram; + } + return RabbitizerInstruction_getBranchOffset(self); +} + +/* General getters */ + +void RabbitizerInstruction_blankOut(RabbitizerInstruction *self) { + size_t i; + + for (i = 0; i < ARRAY_COUNT(self->descriptor->operands) && self->descriptor->operands[i] != RAB_OPERAND_ALL_INVALID; i++) { + switch (self->descriptor->operands[i]) { + case RAB_OPERAND_cpu_rs: + self->word = RAB_INSTR_PACK_rs(self->word, 0); + break; + + case RAB_OPERAND_cpu_rt: + self->word = RAB_INSTR_PACK_rt(self->word, 0); + break; + + case RAB_OPERAND_cpu_rd: + self->word = RAB_INSTR_PACK_rd(self->word, 0); + break; + + case RAB_OPERAND_cpu_sa: + self->word = RAB_INSTR_PACK_sa(self->word, 0); + break; + + case RAB_OPERAND_cpu_zero: + break; + + case RAB_OPERAND_cpu_cop0d: + self->word = RAB_INSTR_PACK_cop0d(self->word, 0); + break; + + case RAB_OPERAND_cpu_fs: + self->word = RAB_INSTR_PACK_fs(self->word, 0); + break; + + case RAB_OPERAND_cpu_ft: + self->word = RAB_INSTR_PACK_ft(self->word, 0); + break; + + case RAB_OPERAND_cpu_fd: + self->word = RAB_INSTR_PACK_fd(self->word, 0); + break; + + case RAB_OPERAND_cpu_cop1cs: + self->word = RAB_INSTR_PACK_cop1cs(self->word, 0); + break; + + case RAB_OPERAND_cpu_cop2t: + self->word = RAB_INSTR_PACK_cop2t(self->word, 0); + break; + + case RAB_OPERAND_cpu_op: + self->word = RAB_INSTR_PACK_op(self->word, 0); + break; + + case RAB_OPERAND_cpu_code: + self->word = RAB_INSTR_PACK_code(self->word, 0); + break; + + case RAB_OPERAND_cpu_code_lower: + self->word = RAB_INSTR_PACK_code_lower(self->word, 0); + break; + + case RAB_OPERAND_cpu_copraw: + self->word = RAB_INSTR_PACK_copraw(self->word, 0); + break; + + case RAB_OPERAND_cpu_label: + self->word = RAB_INSTR_PACK_instr_index(self->word, 0); + break; + + case RAB_OPERAND_cpu_immediate: + self->word = RAB_INSTR_PACK_immediate(self->word, 0); + break; + + case RAB_OPERAND_cpu_branch_target_label: + self->word = RAB_INSTR_PACK_immediate(self->word, 0); + break; + + case RAB_OPERAND_cpu_immediate_base: + self->word = RAB_INSTR_PACK_rs(self->word, 0); + self->word = RAB_INSTR_PACK_immediate(self->word, 0); + break; + + /* rsp */ + case RAB_OPERAND_rsp_rs: + self->word = RAB_INSTR_PACK_rs(self->word, 0); + break; + + case RAB_OPERAND_rsp_rt: + self->word = RAB_INSTR_PACK_rt(self->word, 0); + break; + + case RAB_OPERAND_rsp_rd: + self->word = RAB_INSTR_PACK_rd(self->word, 0); + break; + + case RAB_OPERAND_rsp_cop0d: + self->word = RAB_INSTR_PACK_cop0d(self->word, 0); + break; + + case RAB_OPERAND_rsp_cop2t: + self->word = RAB_INSTR_RSP_PACK_cop2t(self->word, 0); + break; + + case RAB_OPERAND_rsp_cop2cd: + self->word = RAB_INSTR_RSP_PACK_cop2cd(self->word, 0); + break; + + case RAB_OPERAND_rsp_vs: + self->word = RAB_INSTR_RSP_PACK_vs(self->word, 0); + break; + + case RAB_OPERAND_rsp_vt: + self->word = RAB_INSTR_RSP_PACK_vt(self->word, 0); + break; + + case RAB_OPERAND_rsp_vd: + self->word = RAB_INSTR_RSP_PACK_vd(self->word, 0); + break; + + case RAB_OPERAND_rsp_vt_elementhigh: + self->word = RAB_INSTR_RSP_PACK_vt(self->word, 0); + self->word = RAB_INSTR_RSP_PACK_elementhigh(self->word, 0); + break; + + case RAB_OPERAND_rsp_vt_elementlow: + self->word = RAB_INSTR_RSP_PACK_vt(self->word, 0); + self->word = RAB_INSTR_RSP_PACK_elementlow(self->word, 0); + break; + + case RAB_OPERAND_rsp_vd_de: + self->word = RAB_INSTR_RSP_PACK_vd(self->word, 0); + self->word = RAB_INSTR_RSP_PACK_de(self->word, 0); + break; + + case RAB_OPERAND_rsp_vs_index: + self->word = RAB_INSTR_RSP_PACK_vs(self->word, 0); + self->word = RAB_INSTR_RSP_PACK_index(self->word, 0); + break; + + case RAB_OPERAND_rsp_offset_rs: + self->word = RAB_INSTR_RSP_PACK_offset(self->word, 0); + self->word = RAB_INSTR_PACK_rs(self->word, 0); + break; + + case RAB_OPERAND_rsp_immediate_base: + self->word = RAB_INSTR_PACK_rs(self->word, 0); + self->word = RAB_INSTR_PACK_immediate(self->word, 0); + break; + /* rsp */ + + /* r5900 */ + case RAB_OPERAND_r5900_I: + case RAB_OPERAND_r5900_Q: + case RAB_OPERAND_r5900_R: + case RAB_OPERAND_r5900_ACC: + // Not real registers encoded on the instruction itself + break; + + case RAB_OPERAND_r5900_ACCxyzw: + self->word = RAB_INSTR_R5900_PACK_xyzw_x(self->word, 0); + self->word = RAB_INSTR_R5900_PACK_xyzw_y(self->word, 0); + self->word = RAB_INSTR_R5900_PACK_xyzw_z(self->word, 0); + self->word = RAB_INSTR_R5900_PACK_xyzw_w(self->word, 0); + break; + + case RAB_OPERAND_r5900_vfs: + self->word = RAB_INSTR_R5900_PACK_vfs(self->word, 0); + break; + + case RAB_OPERAND_r5900_vft: + self->word = RAB_INSTR_R5900_PACK_vft(self->word, 0); + break; + + case RAB_OPERAND_r5900_vfd: + self->word = RAB_INSTR_R5900_PACK_vfd(self->word, 0); + break; + + case RAB_OPERAND_r5900_vfsxyzw: + self->word = RAB_INSTR_R5900_PACK_vfs(self->word, 0); + self->word = RAB_INSTR_R5900_PACK_xyzw_x(self->word, 0); + self->word = RAB_INSTR_R5900_PACK_xyzw_y(self->word, 0); + self->word = RAB_INSTR_R5900_PACK_xyzw_z(self->word, 0); + self->word = RAB_INSTR_R5900_PACK_xyzw_w(self->word, 0); + break; + + case RAB_OPERAND_r5900_vftxyzw: + self->word = RAB_INSTR_R5900_PACK_vft(self->word, 0); + self->word = RAB_INSTR_R5900_PACK_xyzw_x(self->word, 0); + self->word = RAB_INSTR_R5900_PACK_xyzw_y(self->word, 0); + self->word = RAB_INSTR_R5900_PACK_xyzw_z(self->word, 0); + self->word = RAB_INSTR_R5900_PACK_xyzw_w(self->word, 0); + break; + + case RAB_OPERAND_r5900_vfdxyzw: + self->word = RAB_INSTR_R5900_PACK_vfd(self->word, 0); + self->word = RAB_INSTR_R5900_PACK_xyzw_x(self->word, 0); + self->word = RAB_INSTR_R5900_PACK_xyzw_y(self->word, 0); + self->word = RAB_INSTR_R5900_PACK_xyzw_z(self->word, 0); + self->word = RAB_INSTR_R5900_PACK_xyzw_w(self->word, 0); + break; + + case RAB_OPERAND_r5900_vfsn: + self->word = RAB_INSTR_R5900_PACK_vfs(self->word, 0); + self->word = RAB_INSTR_R5900_PACK_n(self->word, 0); + break; + + case RAB_OPERAND_r5900_vftn: + self->word = RAB_INSTR_R5900_PACK_vft(self->word, 0); + self->word = RAB_INSTR_R5900_PACK_n(self->word, 0); + break; + + case RAB_OPERAND_r5900_vfdn: + self->word = RAB_INSTR_R5900_PACK_vfd(self->word, 0); + self->word = RAB_INSTR_R5900_PACK_n(self->word, 0); + break; + + case RAB_OPERAND_r5900_vfsl: + self->word = RAB_INSTR_R5900_PACK_vfs(self->word, 0); + self->word = RAB_INSTR_R5900_PACK_l(self->word, 0); + break; + + case RAB_OPERAND_r5900_vftl: + self->word = RAB_INSTR_R5900_PACK_vft(self->word, 0); + self->word = RAB_INSTR_R5900_PACK_l(self->word, 0); + break; + + case RAB_OPERAND_r5900_vfdl: + self->word = RAB_INSTR_R5900_PACK_vfd(self->word, 0); + self->word = RAB_INSTR_R5900_PACK_l(self->word, 0); + break; + + case RAB_OPERAND_r5900_vfsm: + self->word = RAB_INSTR_R5900_PACK_vfs(self->word, 0); + self->word = RAB_INSTR_R5900_PACK_m(self->word, 0); + break; + + case RAB_OPERAND_r5900_vftm: + self->word = RAB_INSTR_R5900_PACK_vft(self->word, 0); + self->word = RAB_INSTR_R5900_PACK_m(self->word, 0); + break; + + case RAB_OPERAND_r5900_vfdm: + self->word = RAB_INSTR_R5900_PACK_vfd(self->word, 0); + self->word = RAB_INSTR_R5900_PACK_m(self->word, 0); + break; + + case RAB_OPERAND_r5900_vis: + self->word = RAB_INSTR_R5900_PACK_vis(self->word, 0); + break; + + case RAB_OPERAND_r5900_vit: + self->word = RAB_INSTR_R5900_PACK_vit(self->word, 0); + break; + + case RAB_OPERAND_r5900_vid: + self->word = RAB_INSTR_R5900_PACK_vid(self->word, 0); + break; + + case RAB_OPERAND_r5900_vis_predecr: + self->word = RAB_INSTR_R5900_PACK_vis(self->word, 0); + break; + + case RAB_OPERAND_r5900_vit_predecr: + self->word = RAB_INSTR_R5900_PACK_vit(self->word, 0); + break; + + case RAB_OPERAND_r5900_vid_predecr: + self->word = RAB_INSTR_R5900_PACK_vid(self->word, 0); + break; + + case RAB_OPERAND_r5900_vis_postincr: + self->word = RAB_INSTR_R5900_PACK_vis(self->word, 0); + break; + + case RAB_OPERAND_r5900_vit_postincr: + self->word = RAB_INSTR_R5900_PACK_vit(self->word, 0); + break; + + case RAB_OPERAND_r5900_vid_postincr: + self->word = RAB_INSTR_R5900_PACK_vid(self->word, 0); + break; + + case RAB_OPERAND_r5900_immediate5: + self->word = RAB_INSTR_R5900_PACK_imm5(self->word, 0); + break; + /* r5900 */ + + case RAB_OPERAND_ALL_INVALID: + case RAB_OPERAND_ALL_MAX: + assert(self->descriptor->operands[i] != RAB_OPERAND_ALL_INVALID && self->descriptor->operands[i] != RAB_OPERAND_ALL_MAX); + break; + } + } +} diff --git a/tools/ido-static-recomp/tools/rabbitizer/src/instructions/RabbitizerInstruction/RabbitizerInstruction_Disassemble.c b/tools/ido-static-recomp/tools/rabbitizer/src/instructions/RabbitizerInstruction/RabbitizerInstruction_Disassemble.c new file mode 100644 index 00000000..3f94401c --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/src/instructions/RabbitizerInstruction/RabbitizerInstruction_Disassemble.c @@ -0,0 +1,986 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +#include "instructions/RabbitizerInstruction.h" +#include "instructions/RabbitizerInstructionRsp.h" +#include "instructions/RabbitizerInstructionR5900.h" + +#include +#include +#include + +#include "common/Utils.h" +#include "common/RabbitizerConfig.h" +#include "instructions/RabbitizerRegister.h" +#include "instructions/RabbitizerInstrSuffix.h" + +typedef size_t (*OperandCallback)(const RabbitizerInstruction *self, char *dst, const char *immOverride, size_t immOverrideLength); + +size_t RabbitizerOperandType_process_cpu_rs(const RabbitizerInstruction *self, char *dst, UNUSED const char *immOverride, UNUSED size_t immOverrideLength) { + size_t totalSize = 0; + const char *reg = RabbitizerRegister_getNameGpr(RAB_INSTR_GET_rs(self)); + + RABUTILS_BUFFER_CPY(dst, totalSize, reg); + return totalSize; +} + +size_t RabbitizerOperandType_process_cpu_rt(const RabbitizerInstruction *self, char *dst, UNUSED const char *immOverride, UNUSED size_t immOverrideLength) { + size_t totalSize = 0; + const char *reg = RabbitizerRegister_getNameGpr(RAB_INSTR_GET_rt(self)); + + RABUTILS_BUFFER_CPY(dst, totalSize, reg); + return totalSize; +} + +size_t RabbitizerOperandType_process_cpu_rd(const RabbitizerInstruction *self, char *dst, UNUSED const char *immOverride, UNUSED size_t immOverrideLength) { + size_t totalSize = 0; + const char *reg = RabbitizerRegister_getNameGpr(RAB_INSTR_GET_rd(self)); + + RABUTILS_BUFFER_CPY(dst, totalSize, reg); + return totalSize; +} + +size_t RabbitizerOperandType_process_cpu_zero(UNUSED const RabbitizerInstruction *self, char *dst, UNUSED const char *immOverride, + UNUSED size_t immOverrideLength) { + size_t totalSize = 0; + const char *reg = RabbitizerRegister_getNameGpr(0); + + RABUTILS_BUFFER_CPY(dst, totalSize, reg); + return totalSize; +} + +size_t RabbitizerOperandType_process_cpu_cop0d(const RabbitizerInstruction *self, char *dst, UNUSED const char *immOverride, UNUSED size_t immOverrideLength) { + size_t totalSize = 0; + const char *reg = RabbitizerRegister_getNameCop0(RAB_INSTR_GET_cop0d(self)); + + RABUTILS_BUFFER_CPY(dst, totalSize, reg); + return totalSize; +} + +size_t RabbitizerOperandType_process_cpu_fs(const RabbitizerInstruction *self, char *dst, UNUSED const char *immOverride, UNUSED size_t immOverrideLength) { + size_t totalSize = 0; + const char *reg = RabbitizerRegister_getNameCop1(RAB_INSTR_GET_fs(self)); + + RABUTILS_BUFFER_CPY(dst, totalSize, reg); + return totalSize; +} + +size_t RabbitizerOperandType_process_cpu_ft(const RabbitizerInstruction *self, char *dst, UNUSED const char *immOverride, UNUSED size_t immOverrideLength) { + size_t totalSize = 0; + const char *reg = RabbitizerRegister_getNameCop1(RAB_INSTR_GET_ft(self)); + + RABUTILS_BUFFER_CPY(dst, totalSize, reg); + return totalSize; +} + +size_t RabbitizerOperandType_process_cpu_fd(const RabbitizerInstruction *self, char *dst, UNUSED const char *immOverride, UNUSED size_t immOverrideLength) { + size_t totalSize = 0; + const char *reg = RabbitizerRegister_getNameCop1(RAB_INSTR_GET_fd(self)); + + RABUTILS_BUFFER_CPY(dst, totalSize, reg); + return totalSize; +} + +size_t RabbitizerOperandType_process_cpu_cop1cs(const RabbitizerInstruction *self, char *dst, UNUSED const char *immOverride, UNUSED size_t immOverrideLength) { + size_t totalSize = 0; + const char *reg = RabbitizerRegister_getNameCop1Control(RAB_INSTR_GET_cop1cs(self)); + + RABUTILS_BUFFER_CPY(dst, totalSize, reg); + return totalSize; +} + +size_t RabbitizerOperandType_process_cpu_cop2t(const RabbitizerInstruction *self, char *dst, UNUSED const char *immOverride, UNUSED size_t immOverrideLength) { + size_t totalSize = 0; + const char *reg = RabbitizerRegister_getNameCop2(RAB_INSTR_GET_cop2t(self)); + + RABUTILS_BUFFER_CPY(dst, totalSize, reg); + return totalSize; +} + +size_t RabbitizerOperandType_process_cpu_sa(const RabbitizerInstruction *self, char *dst, UNUSED const char *immOverride, UNUSED size_t immOverrideLength) { + size_t totalSize = 0; + +// TODO: consider making this a proper configuration +#if 0 + if (RAB_INSTR_GET_sa(self) < 10) { + RABUTILS_BUFFER_SPRINTF(dst, totalSize, "%i", RAB_INSTR_GET_sa(self)); + } else { + RABUTILS_BUFFER_SPRINTF(dst, totalSize, "0x%x", RAB_INSTR_GET_sa(self)); + } +#endif + RABUTILS_BUFFER_SPRINTF(dst, totalSize, "%i", RAB_INSTR_GET_sa(self)); + return totalSize; +} + +size_t RabbitizerOperandType_process_cpu_op(const RabbitizerInstruction *self, char *dst, UNUSED const char *immOverride, UNUSED size_t immOverrideLength) { + size_t totalSize = 0; + +// TODO: consider making this a proper configuration +#if 0 + if (RAB_INSTR_GET_op(self) < 10) { + RABUTILS_BUFFER_SPRINTF(dst, totalSize, "%i", RAB_INSTR_GET_op(self)); + } else { + RABUTILS_BUFFER_SPRINTF(dst, totalSize, "0x%x", RAB_INSTR_GET_op(self)); + } +#endif + RABUTILS_BUFFER_SPRINTF(dst, totalSize, "0x%02X", RAB_INSTR_GET_op(self)); + return totalSize; +} + +size_t RabbitizerOperandType_process_cpu_code(const RabbitizerInstruction *self, char *dst, UNUSED const char *immOverride, UNUSED size_t immOverrideLength) { + size_t totalSize = 0; + int code = RAB_INSTR_GET_code_upper(self); + int lower = RAB_INSTR_GET_code_lower(self); + + RABUTILS_BUFFER_SPRINTF(dst, totalSize, "%i", code); + if (lower) { + RABUTILS_BUFFER_SPRINTF(dst, totalSize, ", %i", lower); + } + + return totalSize; +} + +size_t RabbitizerOperandType_process_cpu_code_lower(const RabbitizerInstruction *self, char *dst, UNUSED const char *immOverride, + UNUSED size_t immOverrideLength) { + size_t totalSize = 0; + int code_lower = RAB_INSTR_GET_code_lower(self); + + RABUTILS_BUFFER_SPRINTF(dst, totalSize, "%i", code_lower); + + return totalSize; +} + +size_t RabbitizerOperandType_process_cpu_copraw(const RabbitizerInstruction *self, char *dst, UNUSED const char *immOverride, UNUSED size_t immOverrideLength) { + size_t totalSize = 0; + + RABUTILS_BUFFER_SPRINTF(dst, totalSize, "0x%X", RAB_INSTR_GET_copraw(self)); + + return totalSize; +} + +size_t RabbitizerOperandType_process_cpu_label(const RabbitizerInstruction *self, char *dst, const char *immOverride, size_t immOverrideLength) { + size_t totalSize = 0; + + if ((immOverride != NULL) && (immOverrideLength > 0)) { + memcpy(dst, immOverride, immOverrideLength); + return immOverrideLength; + } + + RABUTILS_BUFFER_SPRINTF(dst, totalSize, "func_%06X", RabbitizerInstruction_getInstrIndexAsVram(self)); + return totalSize; +} + +size_t RabbitizerOperandType_process_cpu_immediate(const RabbitizerInstruction *self, char *dst, const char *immOverride, size_t immOverrideLength) { + size_t totalSize = 0; + int32_t number; + + if ((immOverride != NULL) && (immOverrideLength > 0)) { + memcpy(dst, immOverride, immOverrideLength); + return immOverrideLength; + } + + number = RabbitizerInstruction_getProcessedImmediate(self); + if (RabbitizerConfig_Cfg.misc.omit0XOnSmallImm) { + if (number > -10 && number < 10) { + RABUTILS_BUFFER_SPRINTF(dst, totalSize, "%i", number); + return totalSize; + } + } + if (number < 0) { + if (RabbitizerConfig_Cfg.misc.upperCaseImm) { + RABUTILS_BUFFER_SPRINTF(dst, totalSize, "-0x%X", -number); + } else { + RABUTILS_BUFFER_SPRINTF(dst, totalSize, "-0x%x", -number); + } + } else { + if (RabbitizerConfig_Cfg.misc.upperCaseImm) { + RABUTILS_BUFFER_SPRINTF(dst, totalSize, "0x%X", number); + } else { + RABUTILS_BUFFER_SPRINTF(dst, totalSize, "0x%x", number); + } + } + return totalSize; +} + +size_t RabbitizerOperandType_process_cpu_branch_target_label(const RabbitizerInstruction *self, char *dst, const char *immOverride, size_t immOverrideLength) { + size_t totalSize = 0; + + if ((immOverride != NULL) && (immOverrideLength > 0)) { + memcpy(dst, immOverride, immOverrideLength); + return immOverrideLength; + } + + RABUTILS_BUFFER_CPY(dst, totalSize, ". + 4 + ("); + RABUTILS_BUFFER_ADVANCE(dst, totalSize, RabbitizerOperandType_process_cpu_immediate(self, dst, NULL, 0)); + RABUTILS_BUFFER_CPY(dst, totalSize, " << 2)"); + return totalSize; +} + +size_t RabbitizerOperandType_process_cpu_immediate_base(const RabbitizerInstruction *self, char *dst, const char *immOverride, size_t immOverrideLength) { + size_t totalSize = 0; + +// TODO: consider making this a proper configuration +#if 0 + if ((immOverride != NULL) && (immOverrideLength > 0) || RAB_INSTR_GET_immediate(self) != 0) { + RABUTILS_BUFFER_ADVANCE(dst, totalSize, RabbitizerOperandType_process_cpu_immediate(self, dst, immOverride, immOverrideLength)); + } +#endif + RABUTILS_BUFFER_ADVANCE(dst, totalSize, RabbitizerOperandType_process_cpu_immediate(self, dst, immOverride, immOverrideLength)); + + RABUTILS_BUFFER_WRITE_CHAR(dst, totalSize, '('); + RABUTILS_BUFFER_ADVANCE(dst, totalSize, RabbitizerOperandType_process_cpu_rs(self, dst, immOverride, immOverrideLength)); + RABUTILS_BUFFER_WRITE_CHAR(dst, totalSize, ')'); + + return totalSize; +} + +size_t RabbitizerOperandType_process_rsp_rs(const RabbitizerInstruction *self, char *dst, UNUSED const char *immOverride, UNUSED size_t immOverrideLength) { + size_t totalSize = 0; + const char *reg = RabbitizerRegister_getNameRspGpr(RAB_INSTR_GET_rs(self)); + + RABUTILS_BUFFER_CPY(dst, totalSize, reg); + return totalSize; +} + +size_t RabbitizerOperandType_process_rsp_rt(const RabbitizerInstruction *self, char *dst, UNUSED const char *immOverride, UNUSED size_t immOverrideLength) { + size_t totalSize = 0; + const char *reg = RabbitizerRegister_getNameRspGpr(RAB_INSTR_GET_rt(self)); + + RABUTILS_BUFFER_CPY(dst, totalSize, reg); + return totalSize; +} + +size_t RabbitizerOperandType_process_rsp_rd(const RabbitizerInstruction *self, char *dst, UNUSED const char *immOverride, UNUSED size_t immOverrideLength) { + size_t totalSize = 0; + const char *reg = RabbitizerRegister_getNameRspGpr(RAB_INSTR_GET_rd(self)); + + RABUTILS_BUFFER_CPY(dst, totalSize, reg); + return totalSize; +} + +size_t RabbitizerOperandType_process_rsp_cop0d(const RabbitizerInstruction *self, char *dst, UNUSED const char *immOverride, UNUSED size_t immOverrideLength) { + size_t totalSize = 0; + const char *reg = RabbitizerRegister_getNameRspCop0(RAB_INSTR_GET_cop0d(self)); + + RABUTILS_BUFFER_CPY(dst, totalSize, reg); + return totalSize; +} + +size_t RabbitizerOperandType_process_rsp_cop2t(const RabbitizerInstruction *self, char *dst, UNUSED const char *immOverride, UNUSED size_t immOverrideLength) { + size_t totalSize = 0; + const char *reg = RabbitizerRegister_getNameRspCop2(RAB_INSTR_RSP_GET_cop2t(self)); + + RABUTILS_BUFFER_CPY(dst, totalSize, reg); + return totalSize; +} + +size_t RabbitizerOperandType_process_rsp_cop2cd(const RabbitizerInstruction *self, char *dst, UNUSED const char *immOverride, UNUSED size_t immOverrideLength) { + size_t totalSize = 0; + const char *reg = RabbitizerRegister_getNameRspCop2Control(RAB_INSTR_RSP_GET_cop2cd(self)); + + RABUTILS_BUFFER_CPY(dst, totalSize, reg); + return totalSize; +} + +size_t RabbitizerOperandType_process_rsp_vs(const RabbitizerInstruction *self, char *dst, UNUSED const char *immOverride, UNUSED size_t immOverrideLength) { + size_t totalSize = 0; + const char *reg = RabbitizerRegister_getNameRspVector(RAB_INSTR_RSP_GET_vs(self)); + + RABUTILS_BUFFER_CPY(dst, totalSize, reg); + return totalSize; +} + +size_t RabbitizerOperandType_process_rsp_vt(const RabbitizerInstruction *self, char *dst, UNUSED const char *immOverride, UNUSED size_t immOverrideLength) { + size_t totalSize = 0; + const char *reg = RabbitizerRegister_getNameRspVector(RAB_INSTR_RSP_GET_vt(self)); + + RABUTILS_BUFFER_CPY(dst, totalSize, reg); + return totalSize; +} + +size_t RabbitizerOperandType_process_rsp_vd(const RabbitizerInstruction *self, char *dst, UNUSED const char *immOverride, UNUSED size_t immOverrideLength) { + size_t totalSize = 0; + const char *reg = RabbitizerRegister_getNameRspVector(RAB_INSTR_RSP_GET_vd(self)); + + RABUTILS_BUFFER_CPY(dst, totalSize, reg); + return totalSize; +} + +size_t RabbitizerOperandType_process_rsp_vt_elementhigh(const RabbitizerInstruction *self, char *dst, const char *immOverride, size_t immOverrideLength) { + size_t totalSize = 0; + uint8_t element; + + RABUTILS_BUFFER_ADVANCE(dst, totalSize, RabbitizerOperandType_process_rsp_vt(self, dst, immOverride, immOverrideLength)); + + element = RAB_INSTR_RSP_GET_elementhigh(self); + if (element != 0) { + if ((element & 0x8) == 0x8) { + RABUTILS_BUFFER_SPRINTF(dst, totalSize, "[%i]", element & 7); + } else if ((element & 0xC) == 0x4) { + RABUTILS_BUFFER_SPRINTF(dst, totalSize, "[%ih]", element & (~0xC)); + } else if ((element & 0xE) == 0x2) { + RABUTILS_BUFFER_SPRINTF(dst, totalSize, "[%iq]", element & (~0xE)); + } else { + RABUTILS_BUFFER_SPRINTF(dst, totalSize, "[%i]", element); + } + } + return totalSize; +} + +size_t RabbitizerOperandType_process_rsp_vt_elementlow(const RabbitizerInstruction *self, char *dst, const char *immOverride, size_t immOverrideLength) { + size_t totalSize = 0; + + RABUTILS_BUFFER_ADVANCE(dst, totalSize, RabbitizerOperandType_process_rsp_vt(self, dst, immOverride, immOverrideLength)); + + RABUTILS_BUFFER_SPRINTF(dst, totalSize, "[%i]", RAB_INSTR_RSP_GET_elementlow(self)); + return totalSize; +} + +size_t RabbitizerOperandType_process_rsp_vd_de(const RabbitizerInstruction *self, char *dst, const char *immOverride, size_t immOverrideLength) { + size_t totalSize = 0; + uint8_t de; + + RABUTILS_BUFFER_ADVANCE(dst, totalSize, RabbitizerOperandType_process_rsp_vd(self, dst, immOverride, immOverrideLength)); + + de = RAB_INSTR_RSP_GET_de(self); + if ((de & 0x8) == 0x8) { + RABUTILS_BUFFER_SPRINTF(dst, totalSize, "[%i]", de & (~0x8)); + } else if ((de & 0xC) == 0x4) { + RABUTILS_BUFFER_SPRINTF(dst, totalSize, "[%ih]", de & (~0xC)); + } else if ((de & 0xE) == 0x2) { + RABUTILS_BUFFER_SPRINTF(dst, totalSize, "[%iq]", de & (~0xE)); + } else { + RABUTILS_BUFFER_SPRINTF(dst, totalSize, "[%i]", de); + } + return totalSize; +} + +size_t RabbitizerOperandType_process_rsp_vs_index(const RabbitizerInstruction *self, char *dst, const char *immOverride, size_t immOverrideLength) { + size_t totalSize = 0; + + RABUTILS_BUFFER_ADVANCE(dst, totalSize, RabbitizerOperandType_process_rsp_vs(self, dst, immOverride, immOverrideLength)); + + RABUTILS_BUFFER_SPRINTF(dst, totalSize, "[%i]", RAB_INSTR_RSP_GET_index(self)); + return totalSize; +} + +size_t RabbitizerOperandType_process_rsp_offset_rs(const RabbitizerInstruction *self, char *dst, const char *immOverride, size_t immOverrideLength) { + size_t totalSize = 0; + + RABUTILS_BUFFER_SPRINTF(dst, totalSize, "0x%X", RabbitizerInstructionRsp_GetOffsetVector(self)); + + RABUTILS_BUFFER_WRITE_CHAR(dst, totalSize, '('); + RABUTILS_BUFFER_ADVANCE(dst, totalSize, RabbitizerOperandType_process_rsp_rs(self, dst, immOverride, immOverrideLength)); + RABUTILS_BUFFER_WRITE_CHAR(dst, totalSize, ')'); + return totalSize; +} + +size_t RabbitizerOperandType_process_rsp_immediate_base(const RabbitizerInstruction *self, char *dst, const char *immOverride, size_t immOverrideLength) { + size_t totalSize = 0; + +// TODO: consider making this a proper configuration +#if 0 + if ((immOverride != NULL) && (immOverrideLength > 0) || RAB_INSTR_GET_immediate(self) != 0) { + RABUTILS_BUFFER_ADVANCE(dst, totalSize, RabbitizerOperandType_process_cpu_immediate(self, dst, immOverride, immOverrideLength)); + } +#endif + RABUTILS_BUFFER_ADVANCE(dst, totalSize, RabbitizerOperandType_process_cpu_immediate(self, dst, immOverride, immOverrideLength)); + + RABUTILS_BUFFER_WRITE_CHAR(dst, totalSize, '('); + RABUTILS_BUFFER_ADVANCE(dst, totalSize, RabbitizerOperandType_process_rsp_rs(self, dst, immOverride, immOverrideLength)); + RABUTILS_BUFFER_WRITE_CHAR(dst, totalSize, ')'); + + return totalSize; +} + +size_t RabbitizerOperandType_process_r5900_I(UNUSED const RabbitizerInstruction *self, char *dst, UNUSED const char *immOverride, + UNUSED size_t immOverrideLength) { + size_t totalSize = 0; + + RABUTILS_BUFFER_CPY(dst, totalSize, "$I"); + + return totalSize; +} + +size_t RabbitizerOperandType_process_r5900_Q(UNUSED const RabbitizerInstruction *self, char *dst, UNUSED const char *immOverride, + UNUSED size_t immOverrideLength) { + size_t totalSize = 0; + + RABUTILS_BUFFER_CPY(dst, totalSize, "$Q"); + + return totalSize; +} + +size_t RabbitizerOperandType_process_r5900_R(UNUSED const RabbitizerInstruction *self, char *dst, UNUSED const char *immOverride, + UNUSED size_t immOverrideLength) { + size_t totalSize = 0; + + RABUTILS_BUFFER_CPY(dst, totalSize, "$R"); + + return totalSize; +} + +size_t RabbitizerOperandType_process_r5900_ACC(UNUSED const RabbitizerInstruction *self, char *dst, UNUSED const char *immOverride, + UNUSED size_t immOverrideLength) { + size_t totalSize = 0; + + RABUTILS_BUFFER_CPY(dst, totalSize, "$ACC"); + + return totalSize; +} + +size_t RabbitizerOperandType_process_r5900_ACCxyzw(const RabbitizerInstruction *self, char *dst, const char *immOverride, size_t immOverrideLength) { + size_t totalSize = 0; + + RABUTILS_BUFFER_ADVANCE(dst, totalSize, RabbitizerOperandType_process_r5900_ACC(self, dst, immOverride, immOverrideLength)); + +#if 0 + if (RAB_INSTR_R5900_GET_xyzw_x(self)) { + RABUTILS_BUFFER_WRITE_CHAR(dst, totalSize, 'x'); + } + if (RAB_INSTR_R5900_GET_xyzw_y(self)) { + RABUTILS_BUFFER_WRITE_CHAR(dst, totalSize, 'y'); + } + if (RAB_INSTR_R5900_GET_xyzw_z(self)) { + RABUTILS_BUFFER_WRITE_CHAR(dst, totalSize, 'z'); + } + if (RAB_INSTR_R5900_GET_xyzw_w(self)) { + RABUTILS_BUFFER_WRITE_CHAR(dst, totalSize, 'w'); + } +#endif + + return totalSize; +} + +size_t RabbitizerOperandType_process_r5900_vfs(const RabbitizerInstruction *self, char *dst, UNUSED const char *immOverride, UNUSED size_t immOverrideLength) { + size_t totalSize = 0; + const char *reg = RabbitizerRegister_getNameR5900VF(RAB_INSTR_R5900_GET_vfs(self)); + + RABUTILS_BUFFER_CPY(dst, totalSize, reg); + return totalSize; +} + +size_t RabbitizerOperandType_process_r5900_vft(const RabbitizerInstruction *self, char *dst, UNUSED const char *immOverride, UNUSED size_t immOverrideLength) { + size_t totalSize = 0; + const char *reg = RabbitizerRegister_getNameR5900VF(RAB_INSTR_R5900_GET_vft(self)); + + RABUTILS_BUFFER_CPY(dst, totalSize, reg); + return totalSize; +} + +size_t RabbitizerOperandType_process_r5900_vfd(const RabbitizerInstruction *self, char *dst, UNUSED const char *immOverride, UNUSED size_t immOverrideLength) { + size_t totalSize = 0; + const char *reg = RabbitizerRegister_getNameR5900VF(RAB_INSTR_R5900_GET_vfd(self)); + + RABUTILS_BUFFER_CPY(dst, totalSize, reg); + return totalSize; +} + +size_t RabbitizerOperandType_process_r5900_vfsxyzw(const RabbitizerInstruction *self, char *dst, const char *immOverride, size_t immOverrideLength) { + size_t totalSize = 0; + + RABUTILS_BUFFER_ADVANCE(dst, totalSize, RabbitizerOperandType_process_r5900_vfs(self, dst, immOverride, immOverrideLength)); + +#if 0 + if (RAB_INSTR_R5900_GET_xyzw_x(self)) { + RABUTILS_BUFFER_WRITE_CHAR(dst, totalSize, 'x'); + } + if (RAB_INSTR_R5900_GET_xyzw_y(self)) { + RABUTILS_BUFFER_WRITE_CHAR(dst, totalSize, 'y'); + } + if (RAB_INSTR_R5900_GET_xyzw_z(self)) { + RABUTILS_BUFFER_WRITE_CHAR(dst, totalSize, 'z'); + } + if (RAB_INSTR_R5900_GET_xyzw_w(self)) { + RABUTILS_BUFFER_WRITE_CHAR(dst, totalSize, 'w'); + } +#endif + + return totalSize; +} + +size_t RabbitizerOperandType_process_r5900_vftxyzw(const RabbitizerInstruction *self, char *dst, const char *immOverride, size_t immOverrideLength) { + size_t totalSize = 0; + + RABUTILS_BUFFER_ADVANCE(dst, totalSize, RabbitizerOperandType_process_r5900_vft(self, dst, immOverride, immOverrideLength)); + +#if 0 + if (RAB_INSTR_R5900_GET_xyzw_x(self)) { + RABUTILS_BUFFER_WRITE_CHAR(dst, totalSize, 'x'); + } + if (RAB_INSTR_R5900_GET_xyzw_y(self)) { + RABUTILS_BUFFER_WRITE_CHAR(dst, totalSize, 'y'); + } + if (RAB_INSTR_R5900_GET_xyzw_z(self)) { + RABUTILS_BUFFER_WRITE_CHAR(dst, totalSize, 'z'); + } + if (RAB_INSTR_R5900_GET_xyzw_w(self)) { + RABUTILS_BUFFER_WRITE_CHAR(dst, totalSize, 'w'); + } +#endif + + return totalSize; +} + +size_t RabbitizerOperandType_process_r5900_vfdxyzw(const RabbitizerInstruction *self, char *dst, const char *immOverride, size_t immOverrideLength) { + size_t totalSize = 0; + + RABUTILS_BUFFER_ADVANCE(dst, totalSize, RabbitizerOperandType_process_r5900_vfd(self, dst, immOverride, immOverrideLength)); + +#if 0 + if (RAB_INSTR_R5900_GET_xyzw_x(self)) { + RABUTILS_BUFFER_WRITE_CHAR(dst, totalSize, 'x'); + } + if (RAB_INSTR_R5900_GET_xyzw_y(self)) { + RABUTILS_BUFFER_WRITE_CHAR(dst, totalSize, 'y'); + } + if (RAB_INSTR_R5900_GET_xyzw_z(self)) { + RABUTILS_BUFFER_WRITE_CHAR(dst, totalSize, 'z'); + } + if (RAB_INSTR_R5900_GET_xyzw_w(self)) { + RABUTILS_BUFFER_WRITE_CHAR(dst, totalSize, 'w'); + } +#endif + + return totalSize; +} + +size_t RabbitizerOperandType_process_r5900_vfsn(const RabbitizerInstruction *self, char *dst, const char *immOverride, size_t immOverrideLength) { + size_t totalSize = 0; + uint8_t n; + + RABUTILS_BUFFER_ADVANCE(dst, totalSize, RabbitizerOperandType_process_r5900_vfs(self, dst, immOverride, immOverrideLength)); + + n = RAB_INSTR_R5900_GET_n(self); + RABUTILS_BUFFER_WRITE_CHAR(dst, totalSize, "xyzw"[n]); + + return totalSize; +} + +size_t RabbitizerOperandType_process_r5900_vftn(const RabbitizerInstruction *self, char *dst, const char *immOverride, size_t immOverrideLength) { + size_t totalSize = 0; + uint8_t n; + + RABUTILS_BUFFER_ADVANCE(dst, totalSize, RabbitizerOperandType_process_r5900_vft(self, dst, immOverride, immOverrideLength)); + + n = RAB_INSTR_R5900_GET_n(self); + RABUTILS_BUFFER_WRITE_CHAR(dst, totalSize, "xyzw"[n]); + + return totalSize; +} + +size_t RabbitizerOperandType_process_r5900_vfdn(const RabbitizerInstruction *self, char *dst, const char *immOverride, size_t immOverrideLength) { + size_t totalSize = 0; + uint8_t n; + + RABUTILS_BUFFER_ADVANCE(dst, totalSize, RabbitizerOperandType_process_r5900_vfd(self, dst, immOverride, immOverrideLength)); + + n = RAB_INSTR_R5900_GET_n(self); + RABUTILS_BUFFER_WRITE_CHAR(dst, totalSize, "xyzw"[n]); + + return totalSize; +} + +size_t RabbitizerOperandType_process_r5900_vfsl(const RabbitizerInstruction *self, char *dst, const char *immOverride, size_t immOverrideLength) { + size_t totalSize = 0; + uint8_t n; + + RABUTILS_BUFFER_ADVANCE(dst, totalSize, RabbitizerOperandType_process_r5900_vfs(self, dst, immOverride, immOverrideLength)); + + n = RAB_INSTR_R5900_GET_l(self); + RABUTILS_BUFFER_WRITE_CHAR(dst, totalSize, "xyzw"[n]); + + return totalSize; +} + +size_t RabbitizerOperandType_process_r5900_vftl(const RabbitizerInstruction *self, char *dst, const char *immOverride, size_t immOverrideLength) { + size_t totalSize = 0; + uint8_t n; + + RABUTILS_BUFFER_ADVANCE(dst, totalSize, RabbitizerOperandType_process_r5900_vft(self, dst, immOverride, immOverrideLength)); + + n = RAB_INSTR_R5900_GET_l(self); + RABUTILS_BUFFER_WRITE_CHAR(dst, totalSize, "xyzw"[n]); + + return totalSize; +} + +size_t RabbitizerOperandType_process_r5900_vfdl(const RabbitizerInstruction *self, char *dst, const char *immOverride, size_t immOverrideLength) { + size_t totalSize = 0; + uint8_t n; + + RABUTILS_BUFFER_ADVANCE(dst, totalSize, RabbitizerOperandType_process_r5900_vfd(self, dst, immOverride, immOverrideLength)); + + n = RAB_INSTR_R5900_GET_l(self); + RABUTILS_BUFFER_WRITE_CHAR(dst, totalSize, "xyzw"[n]); + + return totalSize; +} + +size_t RabbitizerOperandType_process_r5900_vfsm(const RabbitizerInstruction *self, char *dst, const char *immOverride, size_t immOverrideLength) { + size_t totalSize = 0; + uint8_t n; + + RABUTILS_BUFFER_ADVANCE(dst, totalSize, RabbitizerOperandType_process_r5900_vfs(self, dst, immOverride, immOverrideLength)); + + n = RAB_INSTR_R5900_GET_m(self); + RABUTILS_BUFFER_WRITE_CHAR(dst, totalSize, "xyzw"[n]); + + return totalSize; +} + +size_t RabbitizerOperandType_process_r5900_vftm(const RabbitizerInstruction *self, char *dst, const char *immOverride, size_t immOverrideLength) { + size_t totalSize = 0; + uint8_t n; + + RABUTILS_BUFFER_ADVANCE(dst, totalSize, RabbitizerOperandType_process_r5900_vft(self, dst, immOverride, immOverrideLength)); + + n = RAB_INSTR_R5900_GET_m(self); + RABUTILS_BUFFER_WRITE_CHAR(dst, totalSize, "xyzw"[n]); + + return totalSize; +} + +size_t RabbitizerOperandType_process_r5900_vfdm(const RabbitizerInstruction *self, char *dst, const char *immOverride, size_t immOverrideLength) { + size_t totalSize = 0; + uint8_t n; + + RABUTILS_BUFFER_ADVANCE(dst, totalSize, RabbitizerOperandType_process_r5900_vfd(self, dst, immOverride, immOverrideLength)); + + n = RAB_INSTR_R5900_GET_m(self); + RABUTILS_BUFFER_WRITE_CHAR(dst, totalSize, "xyzw"[n]); + + return totalSize; +} + +size_t RabbitizerOperandType_process_r5900_vis(const RabbitizerInstruction *self, char *dst, UNUSED const char *immOverride, UNUSED size_t immOverrideLength) { + size_t totalSize = 0; + const char *reg = RabbitizerRegister_getNameR5900VI(RAB_INSTR_R5900_GET_vis(self)); + + RABUTILS_BUFFER_CPY(dst, totalSize, reg); + return totalSize; +} + +size_t RabbitizerOperandType_process_r5900_vit(const RabbitizerInstruction *self, char *dst, UNUSED const char *immOverride, UNUSED size_t immOverrideLength) { + size_t totalSize = 0; + const char *reg = RabbitizerRegister_getNameR5900VI(RAB_INSTR_R5900_GET_vit(self)); + + RABUTILS_BUFFER_CPY(dst, totalSize, reg); + return totalSize; +} + +size_t RabbitizerOperandType_process_r5900_vid(const RabbitizerInstruction *self, char *dst, UNUSED const char *immOverride, UNUSED size_t immOverrideLength) { + size_t totalSize = 0; + const char *reg = RabbitizerRegister_getNameR5900VI(RAB_INSTR_R5900_GET_vid(self)); + + RABUTILS_BUFFER_CPY(dst, totalSize, reg); + return totalSize; +} + +size_t RabbitizerOperandType_process_r5900_vis_predecr(const RabbitizerInstruction *self, char *dst, const char *immOverride, size_t immOverrideLength) { + size_t totalSize = 0; + + RABUTILS_BUFFER_WRITE_CHAR(dst, totalSize, '('); + RABUTILS_BUFFER_WRITE_CHAR(dst, totalSize, '-'); + RABUTILS_BUFFER_WRITE_CHAR(dst, totalSize, '-'); + + RABUTILS_BUFFER_ADVANCE(dst, totalSize, RabbitizerOperandType_process_r5900_vis(self, dst, immOverride, immOverrideLength)); + + RABUTILS_BUFFER_WRITE_CHAR(dst, totalSize, ')'); + + return totalSize; +} + +size_t RabbitizerOperandType_process_r5900_vit_predecr(const RabbitizerInstruction *self, char *dst, const char *immOverride, size_t immOverrideLength) { + size_t totalSize = 0; + + RABUTILS_BUFFER_WRITE_CHAR(dst, totalSize, '('); + RABUTILS_BUFFER_WRITE_CHAR(dst, totalSize, '-'); + RABUTILS_BUFFER_WRITE_CHAR(dst, totalSize, '-'); + + RABUTILS_BUFFER_ADVANCE(dst, totalSize, RabbitizerOperandType_process_r5900_vit(self, dst, immOverride, immOverrideLength)); + + RABUTILS_BUFFER_WRITE_CHAR(dst, totalSize, ')'); + + return totalSize; +} + +size_t RabbitizerOperandType_process_r5900_vid_predecr(const RabbitizerInstruction *self, char *dst, const char *immOverride, size_t immOverrideLength) { + size_t totalSize = 0; + + RABUTILS_BUFFER_WRITE_CHAR(dst, totalSize, '('); + RABUTILS_BUFFER_WRITE_CHAR(dst, totalSize, '-'); + RABUTILS_BUFFER_WRITE_CHAR(dst, totalSize, '-'); + + RABUTILS_BUFFER_ADVANCE(dst, totalSize, RabbitizerOperandType_process_r5900_vid(self, dst, immOverride, immOverrideLength)); + + RABUTILS_BUFFER_WRITE_CHAR(dst, totalSize, ')'); + + return totalSize; +} + +size_t RabbitizerOperandType_process_r5900_vis_postincr(const RabbitizerInstruction *self, char *dst, const char *immOverride, size_t immOverrideLength) { + size_t totalSize = 0; + + RABUTILS_BUFFER_WRITE_CHAR(dst, totalSize, '('); + + RABUTILS_BUFFER_ADVANCE(dst, totalSize, RabbitizerOperandType_process_r5900_vis(self, dst, immOverride, immOverrideLength)); + + RABUTILS_BUFFER_WRITE_CHAR(dst, totalSize, '+'); + RABUTILS_BUFFER_WRITE_CHAR(dst, totalSize, '+'); + RABUTILS_BUFFER_WRITE_CHAR(dst, totalSize, ')'); + + return totalSize; +} + +size_t RabbitizerOperandType_process_r5900_vit_postincr(const RabbitizerInstruction *self, char *dst, const char *immOverride, size_t immOverrideLength) { + size_t totalSize = 0; + + RABUTILS_BUFFER_WRITE_CHAR(dst, totalSize, '('); + + RABUTILS_BUFFER_ADVANCE(dst, totalSize, RabbitizerOperandType_process_r5900_vit(self, dst, immOverride, immOverrideLength)); + + RABUTILS_BUFFER_WRITE_CHAR(dst, totalSize, '+'); + RABUTILS_BUFFER_WRITE_CHAR(dst, totalSize, '+'); + RABUTILS_BUFFER_WRITE_CHAR(dst, totalSize, ')'); + + return totalSize; +} + +size_t RabbitizerOperandType_process_r5900_vid_postincr(const RabbitizerInstruction *self, char *dst, const char *immOverride, size_t immOverrideLength) { + size_t totalSize = 0; + + RABUTILS_BUFFER_WRITE_CHAR(dst, totalSize, '('); + + RABUTILS_BUFFER_ADVANCE(dst, totalSize, RabbitizerOperandType_process_r5900_vid(self, dst, immOverride, immOverrideLength)); + + RABUTILS_BUFFER_WRITE_CHAR(dst, totalSize, '+'); + RABUTILS_BUFFER_WRITE_CHAR(dst, totalSize, '+'); + RABUTILS_BUFFER_WRITE_CHAR(dst, totalSize, ')'); + + return totalSize; +} + +size_t RabbitizerOperandType_process_r5900_immediate5(const RabbitizerInstruction *self, char *dst, const char *immOverride, size_t immOverrideLength) { + size_t totalSize = 0; + int32_t number; + + if ((immOverride != NULL) && (immOverrideLength > 0)) { + memcpy(dst, immOverride, immOverrideLength); + return immOverrideLength; + } + + number = RAB_INSTR_R5900_GET_imm5(self); + if (RabbitizerConfig_Cfg.misc.omit0XOnSmallImm) { + if (number > -10 && number < 10) { + RABUTILS_BUFFER_SPRINTF(dst, totalSize, "%i", number); + return totalSize; + } + } + if (number < 0) { + if (RabbitizerConfig_Cfg.misc.upperCaseImm) { + RABUTILS_BUFFER_SPRINTF(dst, totalSize, "-0x%X", -number); + } else { + RABUTILS_BUFFER_SPRINTF(dst, totalSize, "-0x%x", -number); + } + } else { + if (RabbitizerConfig_Cfg.misc.upperCaseImm) { + RABUTILS_BUFFER_SPRINTF(dst, totalSize, "0x%X", number); + } else { + RABUTILS_BUFFER_SPRINTF(dst, totalSize, "0x%x", number); + } + } + return totalSize; +} + +#define RAB_DEF_OPERAND(prefix, operand) [RAB_OPERAND_##prefix##_##operand] = RabbitizerOperandType_process_##prefix##_##operand, + +const OperandCallback instrOpercandCallbacks[] = { +#include "instructions/operands/RabbitizerOperandType_cpu.inc" +#include "instructions/operands/RabbitizerOperandType_rsp.inc" +#include "instructions/operands/RabbitizerOperandType_r5900.inc" +}; + +#undef RAB_DEF_OPERAND + +size_t RabbitizerInstruction_getSizeForBufferOperandsDisasm(const RabbitizerInstruction *self, size_t immOverrideLength) { + size_t totalSize = 0; + char auxBuffer[0x100] = { 0 }; + char immOverride[0x100] = { 0 }; + + for (size_t i = 0; i < ARRAY_COUNT(self->descriptor->operands) && self->descriptor->operands[i] != RAB_OPERAND_ALL_INVALID; i++) { + RabbitizerOperandType operand; + OperandCallback callback; + + if (i != 0) { + totalSize += 2; + } + + operand = self->descriptor->operands[i]; + assert(operand > RAB_OPERAND_ALL_INVALID); + assert(operand < RAB_OPERAND_ALL_MAX); + + callback = instrOpercandCallbacks[operand]; + assert(callback != NULL); + totalSize += callback(self, auxBuffer, immOverride, immOverrideLength); + } + + return totalSize; +} + +size_t RabbitizerInstruction_disassembleOperands(const RabbitizerInstruction *self, char *dst, const char *immOverride, size_t immOverrideLength) { + size_t totalSize = 0; + + for (size_t i = 0; i < ARRAY_COUNT(self->descriptor->operands) && self->descriptor->operands[i] != RAB_OPERAND_ALL_INVALID; i++) { + RabbitizerOperandType operand; + OperandCallback callback; + + if (i != 0) { + RABUTILS_BUFFER_WRITE_CHAR(dst, totalSize, ','); + RABUTILS_BUFFER_WRITE_CHAR(dst, totalSize, ' '); + } + + operand = self->descriptor->operands[i]; + assert(operand > RAB_OPERAND_ALL_INVALID); + assert(operand < RAB_OPERAND_ALL_MAX); + + callback = instrOpercandCallbacks[operand]; + assert(callback != NULL); + + RABUTILS_BUFFER_ADVANCE(dst, totalSize, callback(self, dst, immOverride, immOverrideLength)); + } + + *dst = '\0'; + return totalSize; +} + +size_t RabbitizerInstruction_getSizeForBufferInstrDisasm(const RabbitizerInstruction *self, size_t immOverrideLength, int extraLJust) { + size_t totalSize = 0; + size_t opcodeNameLength; + + opcodeNameLength = strlen(RabbitizerInstrId_getOpcodeName(self->uniqueId)); + + totalSize += opcodeNameLength; + + totalSize += RabbitizerInstrSuffix_getSizeForBuffer(self, self->descriptor->instrSuffix); + + if (self->descriptor->operands[0] == RAB_OPERAND_ALL_INVALID) { + // There are no operands + return totalSize; + } + + if (RabbitizerConfig_Cfg.misc.opcodeLJust > 0) { + totalSize += RabbitizerConfig_Cfg.misc.opcodeLJust; + } + if (extraLJust > 0) { + totalSize += extraLJust; + } + totalSize++; + + totalSize += RabbitizerInstruction_getSizeForBufferOperandsDisasm(self, immOverrideLength); + + return totalSize; +} + +size_t RabbitizerInstruction_disassembleInstruction(const RabbitizerInstruction *self, char *dst, const char *immOverride, size_t immOverrideLength, + int extraLJust) { + size_t totalSize = 0; + const char *opcodeName = RabbitizerInstrId_getOpcodeName(self->uniqueId); + + RABUTILS_BUFFER_CPY(dst, totalSize, opcodeName); + + RABUTILS_BUFFER_ADVANCE(dst, totalSize, RabbitizerInstrSuffix_processSuffix(self, dst, self->descriptor->instrSuffix)); + + if (self->descriptor->operands[0] == RAB_OPERAND_ALL_INVALID) { + // There are no operands + *dst = '\0'; + return totalSize; + } + + RABUTILS_BUFFER_ADVANCE(dst, totalSize, RabbitizerUtils_CharFill(dst, RabbitizerConfig_Cfg.misc.opcodeLJust + extraLJust - totalSize, ' ')); + RABUTILS_BUFFER_WRITE_CHAR(dst, totalSize, ' '); + + RABUTILS_BUFFER_ADVANCE(dst, totalSize, RabbitizerInstruction_disassembleOperands(self, dst, immOverride, immOverrideLength)); + + *dst = '\0'; + return totalSize; +} + +size_t RabbitizerInstruction_getSizeForBufferDataDisasm(UNUSED const RabbitizerInstruction *self, int extraLJust) { + size_t totalSize = 0; + + totalSize += strlen(".word"); + totalSize += RabbitizerConfig_Cfg.misc.opcodeLJust + extraLJust; + totalSize += 11; + return totalSize; +} + +size_t RabbitizerInstruction_disassembleAsData(const RabbitizerInstruction *self, char *dst, int extraLJust) { + size_t totalSize = 0; + + RABUTILS_BUFFER_CPY(dst, totalSize, ".word"); + + RABUTILS_BUFFER_ADVANCE(dst, totalSize, RabbitizerUtils_CharFill(dst, RabbitizerConfig_Cfg.misc.opcodeLJust + extraLJust - totalSize, ' ')); + + RABUTILS_BUFFER_SPRINTF(dst, totalSize, " 0x%08X", RabbitizerInstruction_getRaw(self)); + return totalSize; +} + +bool RabbitizerInstruction_mustDisasmAsData(const RabbitizerInstruction *self) { + if (RabbitizerConfig_Cfg.toolchainTweaks.sn64DivFix) { + if (self->uniqueId == RABBITIZER_INSTR_ID_cpu_break) { + return true; + } + } + + if (!RabbitizerInstruction_isValid(self)) { + return true; + } + return false; +} + +size_t RabbitizerInstruction_getSizeForBuffer(const RabbitizerInstruction *self, size_t immOverrideLength, int extraLJust) { + if (!RabbitizerInstruction_isImplemented(self) || RabbitizerInstruction_mustDisasmAsData(self)) { + size_t totalSize = RabbitizerInstruction_getSizeForBufferDataDisasm(self, extraLJust); + + if (RabbitizerConfig_Cfg.misc.unknownInstrComment) { + totalSize += 40; + totalSize += 3; + totalSize += RabbitizerInstruction_getSizeForBufferInstrDisasm(self, immOverrideLength, extraLJust); + totalSize += 11; + } + return totalSize; + } + + return RabbitizerInstruction_getSizeForBufferInstrDisasm(self, immOverrideLength, extraLJust); +} + +size_t RabbitizerInstruction_disassemble(const RabbitizerInstruction *self, char *dst, const char *immOverride, size_t immOverrideLength, int extraLJust) { + assert(dst != NULL); + + if (!RabbitizerInstruction_isImplemented(self) || RabbitizerInstruction_mustDisasmAsData(self)) { + size_t totalSize = 0; + + RABUTILS_BUFFER_ADVANCE(dst, totalSize, RabbitizerInstruction_disassembleAsData(self, dst, extraLJust)); + + if (RabbitizerConfig_Cfg.misc.unknownInstrComment) { + uint32_t validBits; + + RABUTILS_BUFFER_ADVANCE(dst, totalSize, RabbitizerUtils_CharFill(dst, 40 - totalSize, ' ')); + + RABUTILS_BUFFER_WRITE_CHAR(dst, totalSize, ' '); + RABUTILS_BUFFER_WRITE_CHAR(dst, totalSize, '#'); + RABUTILS_BUFFER_WRITE_CHAR(dst, totalSize, ' '); + + RABUTILS_BUFFER_ADVANCE(dst, totalSize, RabbitizerInstruction_disassembleInstruction(self, dst, immOverride, immOverrideLength, extraLJust)); + + validBits = RabbitizerInstruction_getValidBits(self); + + RABUTILS_BUFFER_SPRINTF(dst, totalSize, " # %08X", ((~validBits) & self->word)); + } + + return totalSize; + } + + return RabbitizerInstruction_disassembleInstruction(self, dst, immOverride, immOverrideLength, extraLJust); +} diff --git a/tools/ido-static-recomp/tools/rabbitizer/src/instructions/RabbitizerInstruction/RabbitizerInstruction_Examination.c b/tools/ido-static-recomp/tools/rabbitizer/src/instructions/RabbitizerInstruction/RabbitizerInstruction_Examination.c new file mode 100644 index 00000000..136e4aa6 --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/src/instructions/RabbitizerInstruction/RabbitizerInstruction_Examination.c @@ -0,0 +1,840 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +#include "instructions/RabbitizerInstruction.h" + +#include + +#include "common/RabbitizerConfig.h" +#include "instructions/RabbitizerInstructionRsp.h" +#include "instructions/RabbitizerInstructionR5900.h" +#include "instructions/RabbitizerRegister.h" + +bool RabbitizerInstruction_isImplemented(const RabbitizerInstruction *self) { + switch (self->uniqueId) { + case RABBITIZER_INSTR_ID_cpu_INVALID: + case RABBITIZER_INSTR_ID_rsp_INVALID: + case RABBITIZER_INSTR_ID_r5900_INVALID: + return false; + + default: + return true; + } +} + +bool RabbitizerInstruction_isLikelyHandwritten(const RabbitizerInstruction *self) { + if (self->_handwrittenCategory) { + return true; + } + + if (RabbitizerInstrDescriptor_isIType(self->descriptor) && !RabbitizerInstrDescriptor_isFloat(self->descriptor)) { + if (RAB_INSTR_GET_rs(self) == RABBITIZER_REG_GPR_O32_k0 || RAB_INSTR_GET_rs(self) == RABBITIZER_REG_GPR_O32_k1) { + return true; + } + if (RAB_INSTR_GET_rt(self) == RABBITIZER_REG_GPR_O32_k0 || RAB_INSTR_GET_rt(self) == RABBITIZER_REG_GPR_O32_k1) { + return true; + } + } + + if (RabbitizerInstrDescriptor_notEmitedByCompilers(self->descriptor)) { + return true; + } + + return false; +} + +bool RabbitizerInstruction_isNop(const RabbitizerInstruction *self) { + return self->word == 0; +} + +bool RabbitizerInstruction_isUnconditionalBranch(const RabbitizerInstruction *self) { + if (self->uniqueId == RABBITIZER_INSTR_ID_cpu_b) { + return true; + } + if (self->uniqueId == RABBITIZER_INSTR_ID_cpu_beq && RAB_INSTR_GET_rt(self) == 0 && RAB_INSTR_GET_rs(self) == 0) { + return true; + } + if (RabbitizerConfig_Cfg.toolchainTweaks.treatJAsUnconditionalBranch && self->uniqueId == RABBITIZER_INSTR_ID_cpu_j) { + return true; + } + return false; +} + +bool RabbitizerInstruction_isJrRa(const RabbitizerInstruction *self) { + if (self->uniqueId == RABBITIZER_INSTR_ID_cpu_jr) { + // TODO: abi stuffs + return RAB_INSTR_GET_rs(self) == RABBITIZER_REG_GPR_O32_ra; + } + return false; +} + +bool RabbitizerInstruction_isJrNotRa(const RabbitizerInstruction *self) { + if (self->uniqueId == RABBITIZER_INSTR_ID_cpu_jr) { + // TODO: abi stuffs + return RAB_INSTR_GET_rs(self) != RABBITIZER_REG_GPR_O32_ra; + } + return false; +} + +bool RabbitizerInstruction_hasDelaySlot(const RabbitizerInstruction *self) { + return RabbitizerInstrDescriptor_isBranch(self->descriptor) || RabbitizerInstrDescriptor_isJump(self->descriptor); +} + +const char *RabbitizerInstruction_mapInstrToType(const RabbitizerInstruction *self) { + if (RabbitizerInstrDescriptor_isDouble(self->descriptor)) { + return "f64"; + } + if (RabbitizerInstrDescriptor_isFloat(self->descriptor)) { + return "f32"; + } + if (self->uniqueId == RABBITIZER_INSTR_ID_cpu_lwu) { + return "u32"; + } + if (self->uniqueId == RABBITIZER_INSTR_ID_cpu_lh || self->uniqueId == RABBITIZER_INSTR_ID_cpu_sh) { + return "s16"; + } + if (self->uniqueId == RABBITIZER_INSTR_ID_cpu_lhu) { + return "u16"; + } + if (self->uniqueId == RABBITIZER_INSTR_ID_cpu_lb || self->uniqueId == RABBITIZER_INSTR_ID_cpu_sb) { + return "s8"; + } + if (self->uniqueId == RABBITIZER_INSTR_ID_cpu_lbu) { + return "u8"; + } + if (self->uniqueId == RABBITIZER_INSTR_ID_cpu_ld || self->uniqueId == RABBITIZER_INSTR_ID_cpu_sd) { + return "s64"; + } + return NULL; +} + +bool RabbitizerInstruction_sameOpcode(const RabbitizerInstruction *self, const RabbitizerInstruction *other) { + if (!RabbitizerInstruction_isImplemented(self) || !RabbitizerInstruction_isImplemented(other)) { + return false; + } + return self->uniqueId == other->uniqueId; +} + +bool RabbitizerInstruction_sameOpcodeButDifferentArguments(const RabbitizerInstruction *self, const RabbitizerInstruction *other) { + if (!RabbitizerInstruction_sameOpcode(self, other)) { + return false; + } + return RabbitizerInstruction_getRaw(self) != RabbitizerInstruction_getRaw(other); +} + +bool RabbitizerInstruction_hasOperand(const RabbitizerInstruction *self, RabbitizerOperandType operand) { + size_t i; + + for (i = 0; i < ARRAY_COUNT(self->descriptor->operands) && self->descriptor->operands[i] != RAB_OPERAND_ALL_INVALID; i++) { + if (self->descriptor->operands[i] == operand) { + return true; + } + } + + return false; +} + +bool RabbitizerInstruction_hasOperandAlias(const RabbitizerInstruction *self, RabbitizerOperandType operand) { + switch (operand) { + case RAB_OPERAND_cpu_rs: + if (RabbitizerInstruction_hasOperand(self, RAB_OPERAND_cpu_immediate_base)) { + return true; + } + if (RabbitizerInstruction_hasOperand(self, RAB_OPERAND_rsp_rs)) { + return true; + } + if (RabbitizerInstruction_hasOperand(self, RAB_OPERAND_rsp_offset_rs)) { + return true; + } + if (RabbitizerInstruction_hasOperand(self, RAB_OPERAND_rsp_immediate_base)) { + return true; + } + break; + + case RAB_OPERAND_cpu_immediate: + if (RabbitizerInstruction_hasOperand(self, RAB_OPERAND_cpu_immediate_base)) { + return true; + } + if (RabbitizerInstruction_hasOperand(self, RAB_OPERAND_cpu_branch_target_label)) { + return true; + } + if (RabbitizerInstruction_hasOperand(self, RAB_OPERAND_rsp_immediate_base)) { + return true; + } + break; + + case RAB_OPERAND_cpu_rt: + if (RabbitizerInstruction_hasOperand(self, RAB_OPERAND_rsp_rt)) { + return true; + } + break; + + case RAB_OPERAND_cpu_rd: + if (RabbitizerInstruction_hasOperand(self, RAB_OPERAND_rsp_rd)) { + return true; + } + break; + + case RAB_OPERAND_cpu_sa: + case RAB_OPERAND_cpu_zero: + // case RAB_OPERAND_cpu_function: + case RAB_OPERAND_cpu_cop0d: + case RAB_OPERAND_cpu_fs: + case RAB_OPERAND_cpu_ft: + case RAB_OPERAND_cpu_fd: + case RAB_OPERAND_cpu_cop1cs: + case RAB_OPERAND_cpu_cop2t: + case RAB_OPERAND_cpu_op: + case RAB_OPERAND_cpu_code: + case RAB_OPERAND_cpu_code_lower: + case RAB_OPERAND_cpu_copraw: + case RAB_OPERAND_cpu_label: + break; + + case RAB_OPERAND_cpu_branch_target_label: + if (RabbitizerInstruction_hasOperandAlias(self, RAB_OPERAND_cpu_immediate)) { + return true; + } + break; + + case RAB_OPERAND_cpu_immediate_base: + if (RabbitizerInstruction_hasOperandAlias(self, RAB_OPERAND_cpu_rs)) { + return true; + } + if (RabbitizerInstruction_hasOperandAlias(self, RAB_OPERAND_cpu_immediate)) { + return true; + } + break; + + /* rsp */ + case RAB_OPERAND_rsp_rs: + if (RabbitizerInstruction_hasOperand(self, RAB_OPERAND_cpu_rs)) { + return true; + } + if (RabbitizerInstruction_hasOperand(self, RAB_OPERAND_rsp_offset_rs)) { + return true; + } + break; + + case RAB_OPERAND_rsp_rt: + if (RabbitizerInstruction_hasOperand(self, RAB_OPERAND_cpu_rt)) { + return true; + } + break; + + case RAB_OPERAND_rsp_rd: + if (RabbitizerInstruction_hasOperand(self, RAB_OPERAND_cpu_rd)) { + return true; + } + break; + + case RAB_OPERAND_rsp_cop0d: + case RAB_OPERAND_rsp_cop2t: + case RAB_OPERAND_rsp_cop2cd: + break; + + // case RAB_OPERAND_rsp_elementhigh: + // case RAB_OPERAND_rsp_elementlow: + // case RAB_OPERAND_rsp_index: + // case RAB_OPERAND_rsp_offset: + + case RAB_OPERAND_rsp_vs: + if (RabbitizerInstruction_hasOperand(self, RAB_OPERAND_rsp_vs_index)) { + return true; + } + break; + + case RAB_OPERAND_rsp_vt: + if (RabbitizerInstruction_hasOperand(self, RAB_OPERAND_rsp_vt_elementhigh)) { + return true; + } + if (RabbitizerInstruction_hasOperand(self, RAB_OPERAND_rsp_vt_elementlow)) { + return true; + } + break; + + case RAB_OPERAND_rsp_vd: + if (RabbitizerInstruction_hasOperand(self, RAB_OPERAND_rsp_vd_de)) { + return true; + } + break; + + case RAB_OPERAND_rsp_vt_elementhigh: + if (RabbitizerInstruction_hasOperandAlias(self, RAB_OPERAND_rsp_vt)) { + return true; + } + break; + + case RAB_OPERAND_rsp_vt_elementlow: + if (RabbitizerInstruction_hasOperandAlias(self, RAB_OPERAND_rsp_vt)) { + return true; + } + break; + + case RAB_OPERAND_rsp_vd_de: + if (RabbitizerInstruction_hasOperandAlias(self, RAB_OPERAND_rsp_vd)) { + return true; + } + break; + + case RAB_OPERAND_rsp_vs_index: + if (RabbitizerInstruction_hasOperandAlias(self, RAB_OPERAND_rsp_vs)) { + return true; + } + break; + + case RAB_OPERAND_rsp_offset_rs: + if (RabbitizerInstruction_hasOperandAlias(self, RAB_OPERAND_rsp_rs)) { + return true; + } + break; + + case RAB_OPERAND_rsp_immediate_base: + if (RabbitizerInstruction_hasOperandAlias(self, RAB_OPERAND_rsp_rs)) { + return true; + } + if (RabbitizerInstruction_hasOperandAlias(self, RAB_OPERAND_cpu_rs)) { + return true; + } + if (RabbitizerInstruction_hasOperandAlias(self, RAB_OPERAND_cpu_immediate)) { + return true; + } + break; + /* rsp */ + + /* r5900 */ + case RAB_OPERAND_r5900_I: + case RAB_OPERAND_r5900_Q: + case RAB_OPERAND_r5900_R: + break; + + case RAB_OPERAND_r5900_ACC: + if (RabbitizerInstruction_hasOperand(self, RAB_OPERAND_r5900_ACCxyzw)) { + return true; + } + break; + + case RAB_OPERAND_r5900_ACCxyzw: + if (RabbitizerInstruction_hasOperand(self, RAB_OPERAND_r5900_ACC)) { + return true; + } + break; + + case RAB_OPERAND_r5900_vfs: + if (RabbitizerInstruction_hasOperand(self, RAB_OPERAND_r5900_vfsxyzw)) { + return true; + } + if (RabbitizerInstruction_hasOperand(self, RAB_OPERAND_r5900_vfsn)) { + return true; + } + if (RabbitizerInstruction_hasOperand(self, RAB_OPERAND_r5900_vfsl)) { + return true; + } + if (RabbitizerInstruction_hasOperand(self, RAB_OPERAND_r5900_vfsm)) { + return true; + } + break; + + case RAB_OPERAND_r5900_vft: + if (RabbitizerInstruction_hasOperand(self, RAB_OPERAND_r5900_vftxyzw)) { + return true; + } + if (RabbitizerInstruction_hasOperand(self, RAB_OPERAND_r5900_vftn)) { + return true; + } + if (RabbitizerInstruction_hasOperand(self, RAB_OPERAND_r5900_vftl)) { + return true; + } + if (RabbitizerInstruction_hasOperand(self, RAB_OPERAND_r5900_vftm)) { + return true; + } + break; + + case RAB_OPERAND_r5900_vfd: + if (RabbitizerInstruction_hasOperand(self, RAB_OPERAND_r5900_vfdxyzw)) { + return true; + } + if (RabbitizerInstruction_hasOperand(self, RAB_OPERAND_r5900_vfdn)) { + return true; + } + if (RabbitizerInstruction_hasOperand(self, RAB_OPERAND_r5900_vfdl)) { + return true; + } + if (RabbitizerInstruction_hasOperand(self, RAB_OPERAND_r5900_vfdm)) { + return true; + } + break; + + case RAB_OPERAND_r5900_vfsxyzw: + if (RabbitizerInstruction_hasOperand(self, RAB_OPERAND_r5900_vfs)) { + return true; + } + if (RabbitizerInstruction_hasOperand(self, RAB_OPERAND_r5900_vfsn)) { + return true; + } + break; + + case RAB_OPERAND_r5900_vftxyzw: + if (RabbitizerInstruction_hasOperand(self, RAB_OPERAND_r5900_vft)) { + return true; + } + if (RabbitizerInstruction_hasOperand(self, RAB_OPERAND_r5900_vftn)) { + return true; + } + break; + + case RAB_OPERAND_r5900_vfdxyzw: + if (RabbitizerInstruction_hasOperand(self, RAB_OPERAND_r5900_vfd)) { + return true; + } + if (RabbitizerInstruction_hasOperand(self, RAB_OPERAND_r5900_vfdn)) { + return true; + } + break; + + case RAB_OPERAND_r5900_vfsn: + if (RabbitizerInstruction_hasOperand(self, RAB_OPERAND_r5900_vfs)) { + return true; + } + if (RabbitizerInstruction_hasOperand(self, RAB_OPERAND_r5900_vfsxyzw)) { + return true; + } + break; + + case RAB_OPERAND_r5900_vftn: + if (RabbitizerInstruction_hasOperand(self, RAB_OPERAND_r5900_vft)) { + return true; + } + if (RabbitizerInstruction_hasOperand(self, RAB_OPERAND_r5900_vftxyzw)) { + return true; + } + break; + + case RAB_OPERAND_r5900_vfdn: + if (RabbitizerInstruction_hasOperand(self, RAB_OPERAND_r5900_vfd)) { + return true; + } + if (RabbitizerInstruction_hasOperand(self, RAB_OPERAND_r5900_vfdxyzw)) { + return true; + } + break; + + case RAB_OPERAND_r5900_vfsl: + if (RabbitizerInstruction_hasOperandAlias(self, RAB_OPERAND_r5900_vfs)) { + return true; + } + break; + + case RAB_OPERAND_r5900_vftl: + if (RabbitizerInstruction_hasOperandAlias(self, RAB_OPERAND_r5900_vft)) { + return true; + } + break; + + case RAB_OPERAND_r5900_vfdl: + if (RabbitizerInstruction_hasOperandAlias(self, RAB_OPERAND_r5900_vfd)) { + return true; + } + break; + + case RAB_OPERAND_r5900_vfsm: + if (RabbitizerInstruction_hasOperandAlias(self, RAB_OPERAND_r5900_vfs)) { + return true; + } + break; + + case RAB_OPERAND_r5900_vftm: + if (RabbitizerInstruction_hasOperandAlias(self, RAB_OPERAND_r5900_vft)) { + return true; + } + break; + + case RAB_OPERAND_r5900_vfdm: + if (RabbitizerInstruction_hasOperandAlias(self, RAB_OPERAND_r5900_vfd)) { + return true; + } + break; + + case RAB_OPERAND_r5900_vis: + if (RabbitizerInstruction_hasOperand(self, RAB_OPERAND_r5900_vis_predecr)) { + return true; + } + if (RabbitizerInstruction_hasOperand(self, RAB_OPERAND_r5900_vis_postincr)) { + return true; + } + break; + + case RAB_OPERAND_r5900_vit: + if (RabbitizerInstruction_hasOperand(self, RAB_OPERAND_r5900_vit_predecr)) { + return true; + } + if (RabbitizerInstruction_hasOperand(self, RAB_OPERAND_r5900_vit_postincr)) { + return true; + } + break; + + case RAB_OPERAND_r5900_vid: + if (RabbitizerInstruction_hasOperand(self, RAB_OPERAND_r5900_vid_predecr)) { + return true; + } + if (RabbitizerInstruction_hasOperand(self, RAB_OPERAND_r5900_vid_postincr)) { + return true; + } + break; + + case RAB_OPERAND_r5900_vis_predecr: + if (RabbitizerInstruction_hasOperandAlias(self, RAB_OPERAND_r5900_vis)) { + return true; + } + break; + + case RAB_OPERAND_r5900_vit_predecr: + if (RabbitizerInstruction_hasOperandAlias(self, RAB_OPERAND_r5900_vit)) { + return true; + } + break; + + case RAB_OPERAND_r5900_vid_predecr: + if (RabbitizerInstruction_hasOperandAlias(self, RAB_OPERAND_r5900_vid)) { + return true; + } + break; + + case RAB_OPERAND_r5900_vis_postincr: + if (RabbitizerInstruction_hasOperandAlias(self, RAB_OPERAND_r5900_vis)) { + return true; + } + break; + + case RAB_OPERAND_r5900_vit_postincr: + if (RabbitizerInstruction_hasOperandAlias(self, RAB_OPERAND_r5900_vit)) { + return true; + } + break; + + case RAB_OPERAND_r5900_vid_postincr: + if (RabbitizerInstruction_hasOperandAlias(self, RAB_OPERAND_r5900_vid)) { + return true; + } + break; + + case RAB_OPERAND_r5900_immediate5: + break; + /* r5900 */ + + case RAB_OPERAND_ALL_INVALID: + case RAB_OPERAND_ALL_MAX: + assert(operand != RAB_OPERAND_ALL_INVALID && operand != RAB_OPERAND_ALL_MAX); + break; + } + + return RabbitizerInstruction_hasOperand(self, operand); +} + +uint32_t RabbitizerInstruction_getValidBits(const RabbitizerInstruction *self) { + size_t i; + uint32_t validbits; + + validbits = self->_mandatorybits; + + for (i = 0; i < ARRAY_COUNT(self->descriptor->operands) && self->descriptor->operands[i] != RAB_OPERAND_ALL_INVALID; i++) { + + switch (self->descriptor->operands[i]) { + case RAB_OPERAND_cpu_rs: + validbits = RAB_INSTR_PACK_rs(validbits, ~0); + break; + + case RAB_OPERAND_cpu_rt: + validbits = RAB_INSTR_PACK_rt(validbits, ~0); + break; + + case RAB_OPERAND_cpu_rd: + validbits = RAB_INSTR_PACK_rd(validbits, ~0); + break; + + case RAB_OPERAND_cpu_sa: + validbits = RAB_INSTR_PACK_sa(validbits, ~0); + break; + + case RAB_OPERAND_cpu_zero: + break; + + case RAB_OPERAND_cpu_cop0d: + validbits = RAB_INSTR_PACK_cop0d(validbits, ~0); + break; + + case RAB_OPERAND_cpu_fs: + validbits = RAB_INSTR_PACK_fs(validbits, ~0); + break; + + case RAB_OPERAND_cpu_ft: + validbits = RAB_INSTR_PACK_ft(validbits, ~0); + break; + + case RAB_OPERAND_cpu_fd: + validbits = RAB_INSTR_PACK_fd(validbits, ~0); + break; + + case RAB_OPERAND_cpu_cop1cs: + validbits = RAB_INSTR_PACK_cop1cs(validbits, ~0); + break; + + case RAB_OPERAND_cpu_cop2t: + validbits = RAB_INSTR_PACK_cop2t(validbits, ~0); + break; + + case RAB_OPERAND_cpu_op: + validbits = RAB_INSTR_PACK_op(validbits, ~0); + break; + + case RAB_OPERAND_cpu_code: + validbits = RAB_INSTR_PACK_code(validbits, ~0); + break; + + case RAB_OPERAND_cpu_code_lower: + validbits = RAB_INSTR_PACK_code_lower(validbits, ~0); + break; + + case RAB_OPERAND_cpu_copraw: + validbits = RAB_INSTR_PACK_copraw(validbits, ~0); + break; + + case RAB_OPERAND_cpu_label: + validbits = RAB_INSTR_PACK_instr_index(validbits, ~0); + break; + + case RAB_OPERAND_cpu_immediate: + validbits = RAB_INSTR_PACK_immediate(validbits, ~0); + break; + + case RAB_OPERAND_cpu_branch_target_label: + validbits = RAB_INSTR_PACK_immediate(validbits, ~0); + break; + + case RAB_OPERAND_cpu_immediate_base: + validbits = RAB_INSTR_PACK_immediate(validbits, ~0); + validbits = RAB_INSTR_PACK_rs(validbits, ~0); + break; + + /* rsp */ + case RAB_OPERAND_rsp_rs: + validbits = RAB_INSTR_PACK_rs(validbits, ~0); + break; + + case RAB_OPERAND_rsp_rt: + validbits = RAB_INSTR_PACK_rt(validbits, ~0); + break; + + case RAB_OPERAND_rsp_rd: + validbits = RAB_INSTR_PACK_rd(validbits, ~0); + break; + + case RAB_OPERAND_rsp_cop0d: + validbits = RAB_INSTR_PACK_cop0d(validbits, ~0); + break; + + case RAB_OPERAND_rsp_cop2t: + validbits = RAB_INSTR_RSP_PACK_cop2t(validbits, ~0); + break; + + case RAB_OPERAND_rsp_cop2cd: + validbits = RAB_INSTR_RSP_PACK_cop2cd(validbits, ~0); + break; + + case RAB_OPERAND_rsp_vs: + validbits = RAB_INSTR_RSP_PACK_vs(validbits, ~0); + break; + + case RAB_OPERAND_rsp_vt: + validbits = RAB_INSTR_RSP_PACK_vt(validbits, ~0); + break; + + case RAB_OPERAND_rsp_vd: + validbits = RAB_INSTR_RSP_PACK_vd(validbits, ~0); + break; + + case RAB_OPERAND_rsp_vt_elementhigh: + validbits = RAB_INSTR_RSP_PACK_vt(validbits, ~0); + validbits = RAB_INSTR_RSP_PACK_elementhigh(validbits, ~0); + break; + + case RAB_OPERAND_rsp_vt_elementlow: + validbits = RAB_INSTR_RSP_PACK_vt(validbits, ~0); + validbits = RAB_INSTR_RSP_PACK_elementlow(validbits, ~0); + break; + + case RAB_OPERAND_rsp_vd_de: + validbits = RAB_INSTR_RSP_PACK_vd(validbits, ~0); + validbits = RAB_INSTR_RSP_PACK_de(validbits, ~0); + break; + + case RAB_OPERAND_rsp_vs_index: + validbits = RAB_INSTR_RSP_PACK_vs(validbits, ~0); + validbits = RAB_INSTR_RSP_PACK_index(validbits, ~0); + break; + + case RAB_OPERAND_rsp_offset_rs: + validbits = RAB_INSTR_RSP_PACK_offset(validbits, ~0); + validbits = RAB_INSTR_PACK_rs(validbits, ~0); + break; + + case RAB_OPERAND_rsp_immediate_base: + validbits = RAB_INSTR_PACK_immediate(validbits, ~0); + validbits = RAB_INSTR_PACK_rs(validbits, ~0); + break; + /* rsp */ + + /* r5900 */ + case RAB_OPERAND_r5900_I: + case RAB_OPERAND_r5900_Q: + case RAB_OPERAND_r5900_R: + case RAB_OPERAND_r5900_ACC: + // Not real registers encoded on the instruction itself + break; + + case RAB_OPERAND_r5900_ACCxyzw: + validbits = RAB_INSTR_R5900_PACK_xyzw_x(validbits, ~0); + validbits = RAB_INSTR_R5900_PACK_xyzw_y(validbits, ~0); + validbits = RAB_INSTR_R5900_PACK_xyzw_z(validbits, ~0); + validbits = RAB_INSTR_R5900_PACK_xyzw_w(validbits, ~0); + break; + + case RAB_OPERAND_r5900_vfs: + validbits = RAB_INSTR_R5900_PACK_vfs(validbits, ~0); + break; + + case RAB_OPERAND_r5900_vft: + validbits = RAB_INSTR_R5900_PACK_vft(validbits, ~0); + break; + + case RAB_OPERAND_r5900_vfd: + validbits = RAB_INSTR_R5900_PACK_vfd(validbits, ~0); + break; + + case RAB_OPERAND_r5900_vfsxyzw: + validbits = RAB_INSTR_R5900_PACK_vfs(validbits, ~0); + validbits = RAB_INSTR_R5900_PACK_xyzw_x(validbits, ~0); + validbits = RAB_INSTR_R5900_PACK_xyzw_y(validbits, ~0); + validbits = RAB_INSTR_R5900_PACK_xyzw_z(validbits, ~0); + validbits = RAB_INSTR_R5900_PACK_xyzw_w(validbits, ~0); + break; + + case RAB_OPERAND_r5900_vftxyzw: + validbits = RAB_INSTR_R5900_PACK_vft(validbits, ~0); + validbits = RAB_INSTR_R5900_PACK_xyzw_x(validbits, ~0); + validbits = RAB_INSTR_R5900_PACK_xyzw_y(validbits, ~0); + validbits = RAB_INSTR_R5900_PACK_xyzw_z(validbits, ~0); + validbits = RAB_INSTR_R5900_PACK_xyzw_w(validbits, ~0); + break; + + case RAB_OPERAND_r5900_vfdxyzw: + validbits = RAB_INSTR_R5900_PACK_vfd(validbits, ~0); + validbits = RAB_INSTR_R5900_PACK_xyzw_x(validbits, ~0); + validbits = RAB_INSTR_R5900_PACK_xyzw_y(validbits, ~0); + validbits = RAB_INSTR_R5900_PACK_xyzw_z(validbits, ~0); + validbits = RAB_INSTR_R5900_PACK_xyzw_w(validbits, ~0); + break; + + case RAB_OPERAND_r5900_vfsn: + validbits = RAB_INSTR_R5900_PACK_vfs(validbits, ~0); + validbits = RAB_INSTR_R5900_PACK_n(validbits, ~0); + break; + + case RAB_OPERAND_r5900_vftn: + validbits = RAB_INSTR_R5900_PACK_vft(validbits, ~0); + validbits = RAB_INSTR_R5900_PACK_n(validbits, ~0); + break; + + case RAB_OPERAND_r5900_vfdn: + validbits = RAB_INSTR_R5900_PACK_vfd(validbits, ~0); + validbits = RAB_INSTR_R5900_PACK_n(validbits, ~0); + break; + + case RAB_OPERAND_r5900_vfsl: + validbits = RAB_INSTR_R5900_PACK_vfs(validbits, ~0); + validbits = RAB_INSTR_R5900_PACK_l(validbits, ~0); + break; + + case RAB_OPERAND_r5900_vftl: + validbits = RAB_INSTR_R5900_PACK_vft(validbits, ~0); + validbits = RAB_INSTR_R5900_PACK_l(validbits, ~0); + break; + + case RAB_OPERAND_r5900_vfdl: + validbits = RAB_INSTR_R5900_PACK_vfd(validbits, ~0); + validbits = RAB_INSTR_R5900_PACK_l(validbits, ~0); + break; + + case RAB_OPERAND_r5900_vfsm: + validbits = RAB_INSTR_R5900_PACK_vfs(validbits, ~0); + validbits = RAB_INSTR_R5900_PACK_m(validbits, ~0); + break; + + case RAB_OPERAND_r5900_vftm: + validbits = RAB_INSTR_R5900_PACK_vft(validbits, ~0); + validbits = RAB_INSTR_R5900_PACK_m(validbits, ~0); + break; + + case RAB_OPERAND_r5900_vfdm: + validbits = RAB_INSTR_R5900_PACK_vfd(validbits, ~0); + validbits = RAB_INSTR_R5900_PACK_m(validbits, ~0); + break; + + case RAB_OPERAND_r5900_vis: + validbits = RAB_INSTR_R5900_PACK_vis(validbits, ~0); + break; + + case RAB_OPERAND_r5900_vit: + validbits = RAB_INSTR_R5900_PACK_vit(validbits, ~0); + break; + + case RAB_OPERAND_r5900_vid: + validbits = RAB_INSTR_R5900_PACK_vid(validbits, ~0); + break; + + case RAB_OPERAND_r5900_vis_predecr: + validbits = RAB_INSTR_R5900_PACK_vis(validbits, ~0); + break; + + case RAB_OPERAND_r5900_vit_predecr: + validbits = RAB_INSTR_R5900_PACK_vit(validbits, ~0); + break; + + case RAB_OPERAND_r5900_vid_predecr: + validbits = RAB_INSTR_R5900_PACK_vid(validbits, ~0); + break; + + case RAB_OPERAND_r5900_vis_postincr: + validbits = RAB_INSTR_R5900_PACK_vis(validbits, ~0); + break; + + case RAB_OPERAND_r5900_vit_postincr: + validbits = RAB_INSTR_R5900_PACK_vit(validbits, ~0); + break; + + case RAB_OPERAND_r5900_vid_postincr: + validbits = RAB_INSTR_R5900_PACK_vid(validbits, ~0); + break; + + case RAB_OPERAND_r5900_immediate5: + validbits = RAB_INSTR_R5900_PACK_imm5(validbits, ~0); + break; + /* r5900 */ + + case RAB_OPERAND_ALL_INVALID: + case RAB_OPERAND_ALL_MAX: + assert(self->descriptor->operands[i] != RAB_OPERAND_ALL_INVALID && self->descriptor->operands[i] != RAB_OPERAND_ALL_MAX); + break; + } + } + + return validbits; +} + +bool RabbitizerInstruction_isValid(const RabbitizerInstruction *self) { + uint32_t validbits; + + validbits = RabbitizerInstruction_getValidBits(self); + + return ((~validbits) & self->word) == 0; +} diff --git a/tools/ido-static-recomp/tools/rabbitizer/src/instructions/RabbitizerInstruction/RabbitizerInstruction_ProcessUniqueId.c b/tools/ido-static-recomp/tools/rabbitizer/src/instructions/RabbitizerInstruction/RabbitizerInstruction_ProcessUniqueId.c new file mode 100644 index 00000000..0d71c6dd --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/src/instructions/RabbitizerInstruction/RabbitizerInstruction_ProcessUniqueId.c @@ -0,0 +1,319 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +#include "instructions/RabbitizerInstruction.h" + +#include "common/RabbitizerConfig.h" +#include "instructions/RabbitizerRegister.h" + +#define RABBITIZER_DEF_INSTR_ID(prefix, caseBits, name, ...) \ + case (caseBits): \ + self->uniqueId = RABBITIZER_INSTR_ID_##prefix##_##name; \ + break; +#define RABBITIZER_DEF_INSTR_ID_ALTNAME(prefix, caseBits, name, altname, ...) RABBITIZER_DEF_INSTR_ID(prefix, caseBits, name, __VA_ARGS__) + +void RabbitizerInstruction_processUniqueId_Normal(RabbitizerInstruction *self) { + uint32_t opcode = RAB_INSTR_GET_opcode(self); + + self->_mandatorybits = RAB_INSTR_PACK_opcode(self->_mandatorybits, opcode); + + switch (opcode) { +#include "instructions/instr_id/cpu/cpu_normal.inc" + } + + if (RabbitizerConfig_Cfg.pseudos.enablePseudos) { + switch (self->uniqueId) { + case RABBITIZER_INSTR_ID_cpu_beq: + if (RAB_INSTR_GET_rt(self) == 0) { + if (RAB_INSTR_GET_rs(self) == 0) { + if (RabbitizerConfig_Cfg.pseudos.pseudoB) { + self->uniqueId = RABBITIZER_INSTR_ID_cpu_b; + } + } else { + if (RabbitizerConfig_Cfg.pseudos.pseudoBeqz) { + self->uniqueId = RABBITIZER_INSTR_ID_cpu_beqz; + } + } + } + break; + + case RABBITIZER_INSTR_ID_cpu_bne: + if (RAB_INSTR_GET_rt(self) == 0) { + if (RabbitizerConfig_Cfg.pseudos.pseudoBnez) { + self->uniqueId = RABBITIZER_INSTR_ID_cpu_bnez; + } + } + break; + + default: + break; + } + } + + self->descriptor = &RabbitizerInstrDescriptor_Descriptors[self->uniqueId]; +} + +void RabbitizerInstruction_processUniqueId_Special(RabbitizerInstruction *self) { + uint32_t function = RAB_INSTR_GET_function(self); + + self->_mandatorybits = RAB_INSTR_PACK_function(self->_mandatorybits, function); + + switch (function) { +#include "instructions/instr_id/cpu/cpu_special.inc" + } + + if (RabbitizerInstruction_isNop(self)) { + // NOP is special enough + self->uniqueId = RABBITIZER_INSTR_ID_cpu_nop; + } else if (RabbitizerConfig_Cfg.pseudos.enablePseudos) { + switch (self->uniqueId) { + case RABBITIZER_INSTR_ID_cpu_or: + if (RAB_INSTR_GET_rt(self) == 0) { + if (RabbitizerConfig_Cfg.pseudos.pseudoMove) { + self->uniqueId = RABBITIZER_INSTR_ID_cpu_move; + } + } + break; + + case RABBITIZER_INSTR_ID_cpu_nor: + if (RAB_INSTR_GET_rt(self) == 0) { + if (RabbitizerConfig_Cfg.pseudos.pseudoNot) { + self->uniqueId = RABBITIZER_INSTR_ID_cpu_not; + } + } + break; + + case RABBITIZER_INSTR_ID_cpu_subu: + if (RAB_INSTR_GET_rs(self) == 0) { + if (RabbitizerConfig_Cfg.pseudos.pseudoNegu) { + self->uniqueId = RABBITIZER_INSTR_ID_cpu_negu; + } + } + break; + + default: + break; + } + } + + self->descriptor = &RabbitizerInstrDescriptor_Descriptors[self->uniqueId]; + + switch (self->uniqueId) { + case RABBITIZER_INSTR_ID_cpu_jalr: + self->_mandatorybits = RAB_INSTR_PACK_rd(self->_mandatorybits, RAB_INSTR_GET_rd(self)); + + if (RabbitizerConfig_Cfg.regNames.gprAbiNames == RABBITIZER_ABI_NUMERIC || RabbitizerConfig_Cfg.regNames.gprAbiNames == RABBITIZER_ABI_O32) { + if (RAB_INSTR_GET_rd(self) != RABBITIZER_REG_GPR_O32_ra) { + self->descriptor = &RabbitizerInstrDescriptor_Descriptors[RABBITIZER_INSTR_ID_cpu_jalr_rd]; + } + } else { + if (RAB_INSTR_GET_rd(self) != RABBITIZER_REG_GPR_N32_ra) { + self->descriptor = &RabbitizerInstrDescriptor_Descriptors[RABBITIZER_INSTR_ID_cpu_jalr_rd]; + } + } + break; + + case RABBITIZER_INSTR_ID_cpu_div: + if (RabbitizerConfig_Cfg.toolchainTweaks.sn64DivFix && !self->inHandwrittenFunction) { + self->descriptor = &RabbitizerInstrDescriptor_Descriptors[RABBITIZER_INSTR_ID_cpu_sn64_div]; + } + break; + + case RABBITIZER_INSTR_ID_cpu_divu: + if (RabbitizerConfig_Cfg.toolchainTweaks.sn64DivFix && !self->inHandwrittenFunction) { + self->descriptor = &RabbitizerInstrDescriptor_Descriptors[RABBITIZER_INSTR_ID_cpu_sn64_divu]; + } + break; + + default: + break; + } +} + +void RabbitizerInstruction_processUniqueId_Regimm(RabbitizerInstruction *self) { + uint32_t rt = RAB_INSTR_GET_rt(self); + + self->_mandatorybits = RAB_INSTR_PACK_rt(self->_mandatorybits, rt); + + switch (rt) { +#include "instructions/instr_id/cpu/cpu_regimm.inc" + } + + if (RabbitizerConfig_Cfg.pseudos.enablePseudos) { + switch (self->uniqueId) { + case RABBITIZER_INSTR_ID_cpu_bgezal: + if (RAB_INSTR_GET_rs(self) == 0) { + if (RabbitizerConfig_Cfg.pseudos.pseudoBal) { + self->uniqueId = RABBITIZER_INSTR_ID_cpu_bal; + } + } + break; + + default: + break; + } + } + + self->descriptor = &RabbitizerInstrDescriptor_Descriptors[self->uniqueId]; +} + +void RabbitizerInstruction_processUniqueId_Coprocessor0_BC0(RabbitizerInstruction *self) { + uint32_t fmt = RAB_INSTR_GET_bc_fmt(self); + + self->_mandatorybits = RAB_INSTR_PACK_bc_fmt(self->_mandatorybits, fmt); + + switch (fmt) { +#include "instructions/instr_id/cpu/cpu_cop0_bc0.inc" + } +} + +void RabbitizerInstruction_processUniqueId_Coprocessor0_Tlb(RabbitizerInstruction *self) { + uint32_t function = RAB_INSTR_GET_function(self); + + self->_mandatorybits = RAB_INSTR_PACK_function(self->_mandatorybits, function); + + switch (function) { +#include "instructions/instr_id/cpu/cpu_cop0_tlb.inc" + } +} + +void RabbitizerInstruction_processUniqueId_Coprocessor0(RabbitizerInstruction *self) { + uint32_t fmt = RAB_INSTR_GET_fmt(self); + + self->_mandatorybits = RAB_INSTR_PACK_fmt(self->_mandatorybits, fmt); + self->_handwrittenCategory = true; + + switch (fmt) { +#include "instructions/instr_id/cpu/cpu_cop0.inc" + + case 0x08: + RabbitizerInstruction_processUniqueId_Coprocessor0_BC0(self); + break; + + case 0x10: + RabbitizerInstruction_processUniqueId_Coprocessor0_Tlb(self); + break; + } + + self->descriptor = &RabbitizerInstrDescriptor_Descriptors[self->uniqueId]; +} + +void RabbitizerInstruction_processUniqueId_Coprocessor1_BC1(RabbitizerInstruction *self) { + uint32_t fmt = RAB_INSTR_GET_bc_fmt(self); + + self->_mandatorybits = RAB_INSTR_PACK_bc_fmt(self->_mandatorybits, fmt); + + switch (fmt) { +#include "instructions/instr_id/cpu/cpu_cop1_bc1.inc" + } +} + +void RabbitizerInstruction_processUniqueId_Coprocessor1_FpuS(RabbitizerInstruction *self) { + uint32_t function = RAB_INSTR_GET_function(self); + + self->_mandatorybits = RAB_INSTR_PACK_function(self->_mandatorybits, function); + + switch (function) { +#include "instructions/instr_id/cpu/cpu_cop1_fpu_s.inc" + } +} + +void RabbitizerInstruction_processUniqueId_Coprocessor1_FpuD(RabbitizerInstruction *self) { + uint32_t function = RAB_INSTR_GET_function(self); + + self->_mandatorybits = RAB_INSTR_PACK_function(self->_mandatorybits, function); + + switch (function) { +#include "instructions/instr_id/cpu/cpu_cop1_fpu_d.inc" + } +} + +void RabbitizerInstruction_processUniqueId_Coprocessor1_FpuW(RabbitizerInstruction *self) { + uint32_t function = RAB_INSTR_GET_function(self); + + self->_mandatorybits = RAB_INSTR_PACK_function(self->_mandatorybits, function); + + switch (function) { +#include "instructions/instr_id/cpu/cpu_cop1_fpu_w.inc" + } +} + +void RabbitizerInstruction_processUniqueId_Coprocessor1_FpuL(RabbitizerInstruction *self) { + uint32_t function = RAB_INSTR_GET_function(self); + + self->_mandatorybits = RAB_INSTR_PACK_function(self->_mandatorybits, function); + + switch (function) { +#include "instructions/instr_id/cpu/cpu_cop1_fpu_l.inc" + } +} + +void RabbitizerInstruction_processUniqueId_Coprocessor1(RabbitizerInstruction *self) { + uint8_t fmt = RAB_INSTR_GET_fmt(self); + + self->_mandatorybits = RAB_INSTR_PACK_fmt(self->_mandatorybits, fmt); + + switch (fmt) { +#include "instructions/instr_id/cpu/cpu_cop1.inc" + + case 0x08: // fmt = BC + RabbitizerInstruction_processUniqueId_Coprocessor1_BC1(self); + break; + + case 0x10: + RabbitizerInstruction_processUniqueId_Coprocessor1_FpuS(self); + break; + + case 0x11: + RabbitizerInstruction_processUniqueId_Coprocessor1_FpuD(self); + break; + + case 0x14: + RabbitizerInstruction_processUniqueId_Coprocessor1_FpuW(self); + break; + + case 0x15: + RabbitizerInstruction_processUniqueId_Coprocessor1_FpuL(self); + break; + } + + self->descriptor = &RabbitizerInstrDescriptor_Descriptors[self->uniqueId]; +} + +void RabbitizerInstruction_processUniqueId_Coprocessor2(RabbitizerInstruction *self) { + self->_handwrittenCategory = true; + + self->descriptor = &RabbitizerInstrDescriptor_Descriptors[self->uniqueId]; +} + +#undef RABBITIZER_DEF_INSTR_ID +#undef RABBITIZER_DEF_INSTR_ID_ALTNAME + +void RabbitizerInstruction_processUniqueId(RabbitizerInstruction *self) { + uint32_t opcode = RAB_INSTR_GET_opcode(self); + + self->_mandatorybits = RAB_INSTR_PACK_opcode(self->_mandatorybits, opcode); + + self->uniqueId = RABBITIZER_INSTR_ID_cpu_INVALID; + + switch (opcode) { + default: + RabbitizerInstruction_processUniqueId_Normal(self); + break; + case 0x00: + RabbitizerInstruction_processUniqueId_Special(self); + break; + case 0x01: + RabbitizerInstruction_processUniqueId_Regimm(self); + break; + case 0x10: + RabbitizerInstruction_processUniqueId_Coprocessor0(self); + break; + case 0x11: + RabbitizerInstruction_processUniqueId_Coprocessor1(self); + break; + case 0x12: + RabbitizerInstruction_processUniqueId_Coprocessor2(self); + break; + } +} diff --git a/tools/ido-static-recomp/tools/rabbitizer/src/instructions/RabbitizerInstructionR5900/RabbitizerInstructionR5900.c b/tools/ido-static-recomp/tools/rabbitizer/src/instructions/RabbitizerInstructionR5900/RabbitizerInstructionR5900.c new file mode 100644 index 00000000..3b9bd2ce --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/src/instructions/RabbitizerInstructionR5900/RabbitizerInstructionR5900.c @@ -0,0 +1,17 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +#include "instructions/RabbitizerInstructionR5900.h" + +void RabbitizerInstructionR5900_init(RabbitizerInstruction *self, uint32_t word, uint32_t vram) { + RabbitizerInstruction_init(self, word, vram); + + self->uniqueId = RABBITIZER_INSTR_ID_r5900_INVALID; + self->descriptor = &RabbitizerInstrDescriptor_Descriptors[self->uniqueId]; + + self->category = RABBITIZER_INSTRCAT_R5900; +} + +void RabbitizerInstructionR5900_destroy(RabbitizerInstruction *self) { + RabbitizerInstruction_destroy(self); +} diff --git a/tools/ido-static-recomp/tools/rabbitizer/src/instructions/RabbitizerInstructionR5900/RabbitizerInstructionR5900_ProcessUniqueId.c b/tools/ido-static-recomp/tools/rabbitizer/src/instructions/RabbitizerInstructionR5900/RabbitizerInstructionR5900_ProcessUniqueId.c new file mode 100644 index 00000000..1972f3fa --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/src/instructions/RabbitizerInstructionR5900/RabbitizerInstructionR5900_ProcessUniqueId.c @@ -0,0 +1,328 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +#include "instructions/RabbitizerInstructionR5900.h" + +#define RABBITIZER_DEF_INSTR_ID(prefix, caseBits, name, ...) \ + case (caseBits): \ + self->uniqueId = RABBITIZER_INSTR_ID_##prefix##_##name; \ + break; +#define RABBITIZER_DEF_INSTR_ID_ALTNAME(prefix, caseBits, name, altname, ...) RABBITIZER_DEF_INSTR_ID(prefix, caseBits, name, __VA_ARGS__) + +void RabbitizerInstructionR5900_processUniqueId_Normal(RabbitizerInstruction *self) { + uint32_t opcode = RAB_INSTR_GET_opcode(self); + bool fetchDescriptor = true; + + self->_mandatorybits = RAB_INSTR_PACK_opcode(self->_mandatorybits, opcode); + + switch (opcode) { +#include "instructions/instr_id/r5900/r5900_normal.inc" + + default: + RabbitizerInstruction_processUniqueId_Normal(self); + fetchDescriptor = false; + break; + } + + if (fetchDescriptor) { + self->descriptor = &RabbitizerInstrDescriptor_Descriptors[self->uniqueId]; + } +} + +void RabbitizerInstructionR5900_processUniqueId_Special(RabbitizerInstruction *self) { + uint32_t function = RAB_INSTR_GET_function(self); + bool fetchDescriptor = true; + uint32_t stype; + + self->_mandatorybits = RAB_INSTR_PACK_function(self->_mandatorybits, function); + + switch (function) { +#include "instructions/instr_id/r5900/r5900_special.inc" + + default: + RabbitizerInstruction_processUniqueId_Special(self); + fetchDescriptor = false; + break; + } + + switch (self->uniqueId) { + case RABBITIZER_INSTR_ID_cpu_sync: + stype = RAB_INSTR_GET_stype(self); + self->_mandatorybits = RAB_INSTR_PACK_stype(self->_mandatorybits, stype); + if ((stype & 0x10) == 0x10) { + self->uniqueId = RABBITIZER_INSTR_ID_r5900_sync_p; + fetchDescriptor = true; + } + break; + + default: + break; + } + + if (fetchDescriptor) { + self->descriptor = &RabbitizerInstrDescriptor_Descriptors[self->uniqueId]; + } +} + +void RabbitizerInstructionR5900_processUniqueId_Regimm(RabbitizerInstruction *self) { + uint32_t rt = RAB_INSTR_GET_rt(self); + bool fetchDescriptor = true; + + self->_mandatorybits = RAB_INSTR_PACK_rt(self->_mandatorybits, rt); + + switch (rt) { +#include "instructions/instr_id/r5900/r5900_regimm.inc" + + default: + RabbitizerInstruction_processUniqueId_Regimm(self); + fetchDescriptor = false; + break; + } + + if (fetchDescriptor) { + self->descriptor = &RabbitizerInstrDescriptor_Descriptors[self->uniqueId]; + } +} + +void RabbitizerInstructionR5900_processUniqueId_Coprocessor0_Tlb(RabbitizerInstruction *self) { + uint32_t function = RAB_INSTR_GET_function(self); + + self->_mandatorybits = RAB_INSTR_PACK_function(self->_mandatorybits, function); + + switch (function) { +#include "instructions/instr_id/r5900/r5900_cop0_tlb.inc" + + default: + RabbitizerInstruction_processUniqueId_Coprocessor0_Tlb(self); + break; + } +} + +void RabbitizerInstructionR5900_processUniqueId_Coprocessor0(RabbitizerInstruction *self) { + uint32_t fmt = RAB_INSTR_GET_fmt(self); + + self->_mandatorybits = RAB_INSTR_PACK_fmt(self->_mandatorybits, fmt); + self->_handwrittenCategory = true; + + switch (fmt) { +#include "instructions/instr_id/cpu/cpu_cop0.inc" + + case 0x08: + RabbitizerInstruction_processUniqueId_Coprocessor0_BC0(self); + break; + + case 0x10: + RabbitizerInstructionR5900_processUniqueId_Coprocessor0_Tlb(self); + break; + } + + self->descriptor = &RabbitizerInstrDescriptor_Descriptors[self->uniqueId]; +} + +void RabbitizerInstructionR5900_processUniqueId_Coprocessor1_FpuS(RabbitizerInstruction *self) { + uint32_t function = RAB_INSTR_GET_function(self); + + self->_mandatorybits = RAB_INSTR_PACK_function(self->_mandatorybits, function); + + switch (function) { +#include "instructions/instr_id/r5900/r5900_cop1_fpu_s.inc" + + default: + RabbitizerInstruction_processUniqueId_Coprocessor1_FpuS(self); + break; + } +} + +void RabbitizerInstructionR5900_processUniqueId_Coprocessor1(RabbitizerInstruction *self) { + uint8_t fmt = RAB_INSTR_GET_fmt(self); + + self->_mandatorybits = RAB_INSTR_PACK_fmt(self->_mandatorybits, fmt); + + switch (fmt) { +#include "instructions/instr_id/cpu/cpu_cop1.inc" + + case 0x08: // fmt = BC + RabbitizerInstruction_processUniqueId_Coprocessor1_BC1(self); + break; + + case 0x10: + RabbitizerInstructionR5900_processUniqueId_Coprocessor1_FpuS(self); + break; + + case 0x14: + RabbitizerInstruction_processUniqueId_Coprocessor1_FpuW(self); + break; + } + + self->descriptor = &RabbitizerInstrDescriptor_Descriptors[self->uniqueId]; +} + +void RabbitizerInstruction_processUniqueId_Coprocessor2_BC2(RabbitizerInstruction *self) { + uint32_t fmt = RAB_INSTR_GET_bc_fmt(self); + + self->_mandatorybits = RAB_INSTR_PACK_bc_fmt(self->_mandatorybits, fmt); + + switch (fmt) { +#include "instructions/instr_id/r5900/r5900_cop2_bc2.inc" + } +} + +void RabbitizerInstructionR5900_processUniqueId_Coprocessor2_Special2(UNUSED RabbitizerInstruction *self) { + uint32_t fhiflo = RAB_INSTR_R5900_GET_fhi_flo(self); + + self->_mandatorybits = RAB_INSTR_R5900_PACK_fhi_flo(self->_mandatorybits, fhiflo); + + switch (fhiflo) { +#include "instructions/instr_id/r5900/r5900_cop2_special2.inc" + } +} + +void RabbitizerInstructionR5900_processUniqueId_Coprocessor2_Special1(RabbitizerInstruction *self) { + uint32_t function = RAB_INSTR_GET_function(self); + + self->_mandatorybits = RAB_INSTR_PACK_function(self->_mandatorybits, function); + + switch (function) { +#include "instructions/instr_id/r5900/r5900_cop2_special1.inc" + + case 0x3C: + case 0x3D: + case 0x3E: + case 0x3F: + RabbitizerInstructionR5900_processUniqueId_Coprocessor2_Special2(self); + break; + } +} + +void RabbitizerInstructionR5900_processUniqueId_Coprocessor2(RabbitizerInstruction *self) { + uint8_t fmt = RAB_INSTR_GET_fmt(self); + + self->_mandatorybits = RAB_INSTR_PACK_fmt(self->_mandatorybits, fmt); + + switch (fmt) { +#include "instructions/instr_id/r5900/r5900_cop2.inc" + + case 0x08: + RabbitizerInstruction_processUniqueId_Coprocessor2_BC2(self); + break; + + case 0x10: + case 0x11: + case 0x12: + case 0x13: + case 0x14: + case 0x15: + case 0x16: + case 0x17: + case 0x18: + case 0x19: + case 0x1A: + case 0x1B: + case 0x1C: + case 0x1D: + case 0x1E: + case 0x1F: + RabbitizerInstructionR5900_processUniqueId_Coprocessor2_Special1(self); + break; + } + + self->descriptor = &RabbitizerInstrDescriptor_Descriptors[self->uniqueId]; +} + +void RabbitizerInstructionR5900_processUniqueId_MMI_0(RabbitizerInstruction *self) { + uint32_t function = RAB_INSTR_R5900_GET_mmi_function(self); + + self->_mandatorybits = RAB_INSTR_R5900_PACK_mmi_function(self->_mandatorybits, function); + + switch (function) { +#include "instructions/instr_id/r5900/r5900_mmi_0.inc" + } +} + +void RabbitizerInstructionR5900_processUniqueId_MMI_1(RabbitizerInstruction *self) { + uint32_t function = RAB_INSTR_R5900_GET_mmi_function(self); + + self->_mandatorybits = RAB_INSTR_R5900_PACK_mmi_function(self->_mandatorybits, function); + + switch (function) { +#include "instructions/instr_id/r5900/r5900_mmi_1.inc" + } +} + +void RabbitizerInstructionR5900_processUniqueId_MMI_2(RabbitizerInstruction *self) { + uint32_t function = RAB_INSTR_R5900_GET_mmi_function(self); + + self->_mandatorybits = RAB_INSTR_R5900_PACK_mmi_function(self->_mandatorybits, function); + + switch (function) { +#include "instructions/instr_id/r5900/r5900_mmi_2.inc" + } +} + +void RabbitizerInstructionR5900_processUniqueId_MMI_3(RabbitizerInstruction *self) { + uint32_t function = RAB_INSTR_R5900_GET_mmi_function(self); + + self->_mandatorybits = RAB_INSTR_R5900_PACK_mmi_function(self->_mandatorybits, function); + + switch (function) { +#include "instructions/instr_id/r5900/r5900_mmi_3.inc" + } +} + +void RabbitizerInstructionR5900_processUniqueId_MMI(RabbitizerInstruction *self) { + uint32_t function = RAB_INSTR_GET_function(self); + + self->_mandatorybits = RAB_INSTR_PACK_function(self->_mandatorybits, function); + + switch (function) { +#include "instructions/instr_id/r5900/r5900_mmi.inc" + + case 0x08: + RabbitizerInstructionR5900_processUniqueId_MMI_0(self); + break; + case 0x09: + RabbitizerInstructionR5900_processUniqueId_MMI_2(self); + break; + case 0x28: + RabbitizerInstructionR5900_processUniqueId_MMI_1(self); + break; + case 0x29: + RabbitizerInstructionR5900_processUniqueId_MMI_3(self); + break; + } + + self->descriptor = &RabbitizerInstrDescriptor_Descriptors[self->uniqueId]; +} + +#undef RABBITIZER_DEF_INSTR_ID +#undef RABBITIZER_DEF_INSTR_ID_ALTNAME + +void RabbitizerInstructionR5900_processUniqueId(RabbitizerInstruction *self) { + uint32_t opcode = RAB_INSTR_GET_opcode(self); + + self->_mandatorybits = RAB_INSTR_PACK_opcode(self->_mandatorybits, opcode); + + switch (opcode) { + default: + RabbitizerInstructionR5900_processUniqueId_Normal(self); + break; + case 0x00: + RabbitizerInstructionR5900_processUniqueId_Special(self); + break; + case 0x01: + RabbitizerInstructionR5900_processUniqueId_Regimm(self); + break; + case 0x10: + RabbitizerInstructionR5900_processUniqueId_Coprocessor0(self); + break; + case 0x11: + RabbitizerInstructionR5900_processUniqueId_Coprocessor1(self); + break; + case 0x12: + RabbitizerInstructionR5900_processUniqueId_Coprocessor2(self); + break; + case 0x1C: + RabbitizerInstructionR5900_processUniqueId_MMI(self); + break; + } +} diff --git a/tools/ido-static-recomp/tools/rabbitizer/src/instructions/RabbitizerInstructionRsp/RabbitizerInstructionRsp.c b/tools/ido-static-recomp/tools/rabbitizer/src/instructions/RabbitizerInstructionRsp/RabbitizerInstructionRsp.c new file mode 100644 index 00000000..1e63453c --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/src/instructions/RabbitizerInstructionRsp/RabbitizerInstructionRsp.c @@ -0,0 +1,56 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +#include "instructions/RabbitizerInstructionRsp.h" + +void RabbitizerInstructionRsp_init(RabbitizerInstruction *self, uint32_t word, uint32_t vram) { + RabbitizerInstruction_init(self, word, vram); + + self->uniqueId = RABBITIZER_INSTR_ID_rsp_INVALID; + self->descriptor = &RabbitizerInstrDescriptor_Descriptors[self->uniqueId]; + + self->_handwrittenCategory = true; + self->category = RABBITIZER_INSTRCAT_RSP; +} + +void RabbitizerInstructionRsp_destroy(RabbitizerInstruction *self) { + RabbitizerInstruction_destroy(self); +} + +uint16_t RabbitizerInstructionRsp_GetOffsetVector(const RabbitizerInstruction *self) { + uint16_t offset = RAB_INSTR_RSP_GET_OFFSET_VECTOR_RAW(self); + + switch (self->uniqueId) { + case RABBITIZER_INSTR_ID_rsp_lsv: + case RABBITIZER_INSTR_ID_rsp_ssv: + return offset << 1; + + case RABBITIZER_INSTR_ID_rsp_llv: + case RABBITIZER_INSTR_ID_rsp_slv: + return offset << 2; + + case RABBITIZER_INSTR_ID_rsp_ldv: + case RABBITIZER_INSTR_ID_rsp_sdv: + case RABBITIZER_INSTR_ID_rsp_lpv: + case RABBITIZER_INSTR_ID_rsp_spv: + case RABBITIZER_INSTR_ID_rsp_luv: + case RABBITIZER_INSTR_ID_rsp_suv: + return offset << 3; + + case RABBITIZER_INSTR_ID_rsp_lqv: + case RABBITIZER_INSTR_ID_rsp_sqv: + case RABBITIZER_INSTR_ID_rsp_lrv: + case RABBITIZER_INSTR_ID_rsp_srv: + case RABBITIZER_INSTR_ID_rsp_lhv: + case RABBITIZER_INSTR_ID_rsp_shv: + case RABBITIZER_INSTR_ID_rsp_lfv: + case RABBITIZER_INSTR_ID_rsp_sfv: + case RABBITIZER_INSTR_ID_rsp_ltv: + case RABBITIZER_INSTR_ID_rsp_stv: + case RABBITIZER_INSTR_ID_rsp_swv: + return offset << 4; + + default: + return offset; + } +} diff --git a/tools/ido-static-recomp/tools/rabbitizer/src/instructions/RabbitizerInstructionRsp/RabbitizerInstructionRsp_ProcessUniqueId.c b/tools/ido-static-recomp/tools/rabbitizer/src/instructions/RabbitizerInstructionRsp/RabbitizerInstructionRsp_ProcessUniqueId.c new file mode 100644 index 00000000..e491f1be --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/src/instructions/RabbitizerInstructionRsp/RabbitizerInstructionRsp_ProcessUniqueId.c @@ -0,0 +1,233 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +#include "instructions/RabbitizerInstructionRsp.h" + +#include "common/RabbitizerConfig.h" + +#define RABBITIZER_DEF_INSTR_ID(prefix, caseBits, name, ...) \ + case (caseBits): \ + self->uniqueId = RABBITIZER_INSTR_ID_##prefix##_##name; \ + break; +#define RABBITIZER_DEF_INSTR_ID_ALTNAME(prefix, caseBits, name, altname, ...) RABBITIZER_DEF_INSTR_ID(prefix, caseBits, name, __VA_ARGS__) + +void RabbitizerInstructionRsp_processUniqueId_Normal_Lwc2(RabbitizerInstruction *self) { + uint32_t rd = RAB_INSTR_GET_rd(self); + + self->_mandatorybits = RAB_INSTR_PACK_rd(self->_mandatorybits, rd); + + switch (rd) { +#include "instructions/instr_id/rsp/rsp_normal_lwc2.inc" + } +} + +void RabbitizerInstructionRsp_processUniqueId_Normal_Swc2(RabbitizerInstruction *self) { + uint32_t rd = RAB_INSTR_GET_rd(self); + uint32_t elementlow; + + self->_mandatorybits = RAB_INSTR_PACK_rd(self->_mandatorybits, rd); + + switch (rd) { +#include "instructions/instr_id/rsp/rsp_normal_swc2.inc" + } + + switch (self->uniqueId) { + case RABBITIZER_INSTR_ID_rsp_suv: + elementlow = RAB_INSTR_RSP_GET_elementlow(self); + self->_mandatorybits = RAB_INSTR_RSP_PACK_elementlow(self->_mandatorybits, elementlow); + if (elementlow != 0) { + self->uniqueId = RABBITIZER_INSTR_ID_rsp_swv; + } + break; + + default: + break; + } +} + +void RabbitizerInstructionRsp_processUniqueId_Normal(RabbitizerInstruction *self) { + uint32_t opcode = RAB_INSTR_GET_opcode(self); + + self->_mandatorybits = RAB_INSTR_PACK_opcode(self->_mandatorybits, opcode); + + switch (opcode) { +#include "instructions/instr_id/rsp/rsp_normal.inc" + + // new rsp stuff + case 0x32: + RabbitizerInstructionRsp_processUniqueId_Normal_Lwc2(self); + break; + + case 0x3A: + RabbitizerInstructionRsp_processUniqueId_Normal_Swc2(self); + break; + } + + if (RabbitizerConfig_Cfg.pseudos.enablePseudos) { + if (RAB_INSTR_GET_rt(self) == 0) { + if (self->uniqueId == RABBITIZER_INSTR_ID_rsp_beq) { + if (RAB_INSTR_GET_rs(self) == 0) { + if (RabbitizerConfig_Cfg.pseudos.pseudoB) { + self->uniqueId = RABBITIZER_INSTR_ID_rsp_b; + } + } else { + if (RabbitizerConfig_Cfg.pseudos.pseudoBeqz) { + self->uniqueId = RABBITIZER_INSTR_ID_rsp_beqz; + } + } + } else if (self->uniqueId == RABBITIZER_INSTR_ID_rsp_bne) { + if (RabbitizerConfig_Cfg.pseudos.pseudoBnez) { + self->uniqueId = RABBITIZER_INSTR_ID_rsp_bnez; + } + } + } + } + + self->descriptor = &RabbitizerInstrDescriptor_Descriptors[self->uniqueId]; +} + +void RabbitizerInstructionRsp_processUniqueId_Special(RabbitizerInstruction *self) { + uint32_t function = RAB_INSTR_GET_function(self); + + self->_mandatorybits = RAB_INSTR_PACK_function(self->_mandatorybits, function); + + switch (function) { +#include "instructions/instr_id/rsp/rsp_special.inc" + } + + if (RabbitizerInstruction_isNop(self)) { + // NOP is special enough + self->uniqueId = RABBITIZER_INSTR_ID_rsp_nop; + } else if (RabbitizerConfig_Cfg.pseudos.enablePseudos) { + if (RAB_INSTR_GET_rt(self) == 0) { + if (self->uniqueId == RABBITIZER_INSTR_ID_rsp_or) { + if (RabbitizerConfig_Cfg.pseudos.pseudoMove) { + self->uniqueId = RABBITIZER_INSTR_ID_rsp_move; + } + } else if (self->uniqueId == RABBITIZER_INSTR_ID_rsp_nor) { + if (RabbitizerConfig_Cfg.pseudos.pseudoNot) { + self->uniqueId = RABBITIZER_INSTR_ID_rsp_not; + } + } + } else if (self->uniqueId == RABBITIZER_INSTR_ID_rsp_subu) { + if (RAB_INSTR_GET_rs(self) == 0) { + if (RabbitizerConfig_Cfg.pseudos.pseudoNegu) { + self->uniqueId = RABBITIZER_INSTR_ID_rsp_negu; + } + } + } + } + + self->descriptor = &RabbitizerInstrDescriptor_Descriptors[self->uniqueId]; + + if (self->uniqueId == RABBITIZER_INSTR_ID_rsp_jalr) { + // $ra + if (RAB_INSTR_GET_rd(self) != 31) { + self->descriptor = &RabbitizerInstrDescriptor_Descriptors[RABBITIZER_INSTR_ID_rsp_jalr_rd]; + } + } +} + +void RabbitizerInstructionRsp_processUniqueId_Regimm(RabbitizerInstruction *self) { + uint32_t rt = RAB_INSTR_GET_rt(self); + + self->_mandatorybits = RAB_INSTR_PACK_rt(self->_mandatorybits, rt); + + switch (rt) { +#include "instructions/instr_id/rsp/rsp_regimm.inc" + } + + if (RabbitizerConfig_Cfg.pseudos.enablePseudos) { + switch (self->uniqueId) { + case RABBITIZER_INSTR_ID_rsp_bgezal: + if (RAB_INSTR_GET_rs(self) == 0) { + if (RabbitizerConfig_Cfg.pseudos.pseudoBal) { + self->uniqueId = RABBITIZER_INSTR_ID_rsp_bal; + } + } + break; + + default: + break; + } + } + + self->descriptor = &RabbitizerInstrDescriptor_Descriptors[self->uniqueId]; +} + +void RabbitizerInstructionRsp_processUniqueId_Coprocessor0(RabbitizerInstruction *self) { + uint32_t fmt = RAB_INSTR_GET_fmt(self); + + self->_mandatorybits = RAB_INSTR_PACK_fmt(self->_mandatorybits, fmt); + + switch (fmt) { +#include "instructions/instr_id/cpu/cpu_cop0.inc" + } + + self->descriptor = &RabbitizerInstrDescriptor_Descriptors[self->uniqueId]; +} + +void RabbitizerInstructionRsp_processUniqueId_Coprocessor2_Vu(RabbitizerInstruction *self) { + uint32_t aux = SHIFTR(self->word, 25, 1); + uint32_t function = RAB_INSTR_GET_function(self); + + if (aux != 1) { + return; + } + + // TODO: name this bit range + self->_mandatorybits = BITREPACK(self->_mandatorybits, aux, 25, 1); + self->_mandatorybits = RAB_INSTR_PACK_function(self->_mandatorybits, function); + + switch (function) { +#include "instructions/instr_id/rsp/rsp_cop2_vu.inc" + } +} + +void RabbitizerInstructionRsp_processUniqueId_Coprocessor2(RabbitizerInstruction *self) { + uint32_t fmt = RAB_INSTR_GET_fmt(self); + + self->_mandatorybits = RAB_INSTR_PACK_fmt(self->_mandatorybits, fmt); + + switch (fmt) { +#include "instructions/instr_id/cpu/cpu_cop0.inc" + + default: + RabbitizerInstructionRsp_processUniqueId_Coprocessor2_Vu(self); + break; + } + + self->descriptor = &RabbitizerInstrDescriptor_Descriptors[self->uniqueId]; +} + +#undef RABBITIZER_DEF_INSTR_ID +#undef RABBITIZER_DEF_INSTR_ID_ALTNAME + +void RabbitizerInstructionRsp_processUniqueId(RabbitizerInstruction *self) { + uint32_t opcode = RAB_INSTR_GET_opcode(self); + + self->_mandatorybits = RAB_INSTR_PACK_opcode(self->_mandatorybits, opcode); + + self->uniqueId = RABBITIZER_INSTR_ID_rsp_INVALID; + + switch (opcode) { + default: + RabbitizerInstructionRsp_processUniqueId_Normal(self); + break; + case 0x00: + RabbitizerInstructionRsp_processUniqueId_Special(self); + break; + case 0x01: + RabbitizerInstructionRsp_processUniqueId_Regimm(self); + break; + case 0x10: + RabbitizerInstructionRsp_processUniqueId_Coprocessor0(self); + break; + // case 0x11: + // RabbitizerInstructionRsp_processUniqueId_Coprocessor1(self); + // break; + case 0x12: + RabbitizerInstructionRsp_processUniqueId_Coprocessor2(self); + break; + } +} diff --git a/tools/ido-static-recomp/tools/rabbitizer/src/instructions/RabbitizerRegister.c b/tools/ido-static-recomp/tools/rabbitizer/src/instructions/RabbitizerRegister.c new file mode 100644 index 00000000..4d16024f --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/src/instructions/RabbitizerRegister.c @@ -0,0 +1,181 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +#include "instructions/RabbitizerRegister.h" + +#include + +#include "common/Utils.h" +#include "common/RabbitizerConfig.h" + +#define RABBITIZER_DEF_REG(prefix, name, numeric) [RABBITIZER_REG_##prefix##_##name] = { "$" #numeric, "$" #name } + +#define RABBITIZER_DEF_REG_NODOLLAR(prefix, name, numeric) [RABBITIZER_REG_##prefix##_##name] = { "$" #numeric, #name } + +// numeric, named + +const char *RabbitizerRegister_GprO32_Names[][2] = { +#include "instructions/registers/RabbitizerRegister_GprO32.inc" +}; + +const char *RabbitizerRegister_GprN32_Names[][2] = { +#include "instructions/registers/RabbitizerRegister_GprN32.inc" +}; + +const char *RabbitizerRegister_Cop0_Names[][2] = { +#include "instructions/registers/RabbitizerRegister_Cop0.inc" +}; + +const char *RabbitizerRegister_Cop1O32_Names[][2] = { +#include "instructions/registers/RabbitizerRegister_Cop1O32.inc" +}; + +const char *RabbitizerRegister_Cop1N32_Names[][2] = { +#include "instructions/registers/RabbitizerRegister_Cop1N32.inc" +}; + +const char *RabbitizerRegister_Cop1N64_Names[][2] = { +#include "instructions/registers/RabbitizerRegister_Cop1N64.inc" +}; + +const char *RabbitizerRegister_Cop1Control_Names[][2] = { +#include "instructions/registers/RabbitizerRegister_Cop1Control.inc" +}; + +const char *RabbitizerRegister_Cop2_Names[][2] = { +#include "instructions/registers/RabbitizerRegister_Cop2.inc" +}; + +/* RSP */ + +const char *RabbitizerRegister_RspGpr_Names[][2] = { +#include "instructions/registers/RabbitizerRegister_RspGpr.inc" +}; + +const char *RabbitizerRegister_RspCop0_Names[][2] = { +#include "instructions/registers/RabbitizerRegister_RspCop0.inc" +}; + +const char *RabbitizerRegister_RspCop2_Names[][2] = { +#include "instructions/registers/RabbitizerRegister_RspCop2.inc" +}; + +const char *RabbitizerRegister_RspCop2Control_Names[][2] = { +#include "instructions/registers/RabbitizerRegister_RspCop2Control.inc" +}; + +const char *RabbitizerRegister_RspVector_Names[][2] = { +#include "instructions/registers/RabbitizerRegister_RspVector.inc" +}; + +/* RSP */ + +/* R5900 */ + +const char *RabbitizerRegister_R5900VF_Names[][2] = { +#include "instructions/registers/RabbitizerRegister_R5900VF.inc" +}; + +const char *RabbitizerRegister_R5900VI_Names[][2] = { +#include "instructions/registers/RabbitizerRegister_R5900VI.inc" +}; + +/* R5900 */ + +const char *RabbitizerRegister_getNameGpr(uint8_t regValue) { + assert(regValue < ARRAY_COUNT(RabbitizerRegister_GprO32_Names)); + + switch (RabbitizerConfig_Cfg.regNames.gprAbiNames) { + case RABBITIZER_ABI_NUMERIC: + return RabbitizerRegister_GprO32_Names[regValue][0]; + + default: + case RABBITIZER_ABI_O32: + return RabbitizerRegister_GprO32_Names[regValue][RabbitizerConfig_Cfg.regNames.namedRegisters ? 1 : 0]; + + case RABBITIZER_ABI_N32: + case RABBITIZER_ABI_N64: + return RabbitizerRegister_GprN32_Names[regValue][RabbitizerConfig_Cfg.regNames.namedRegisters ? 1 : 0]; + } +} + +const char *RabbitizerRegister_getNameCop0(uint8_t regValue) { + assert(regValue < ARRAY_COUNT(RabbitizerRegister_Cop0_Names)); + + return RabbitizerRegister_Cop0_Names[regValue] + [RabbitizerConfig_Cfg.regNames.namedRegisters && RabbitizerConfig_Cfg.regNames.vr4300Cop0NamedRegisters ? 1 : 0]; +} + +const char *RabbitizerRegister_getNameCop1(uint8_t regValue) { + assert(regValue < ARRAY_COUNT(RabbitizerRegister_Cop1O32_Names)); + + switch (RabbitizerConfig_Cfg.regNames.fprAbiNames) { + default: + case RABBITIZER_ABI_NUMERIC: + return RabbitizerRegister_Cop1O32_Names[regValue][0]; + + case RABBITIZER_ABI_O32: + return RabbitizerRegister_Cop1O32_Names[regValue][RabbitizerConfig_Cfg.regNames.namedRegisters ? 1 : 0]; + + case RABBITIZER_ABI_N32: + return RabbitizerRegister_Cop1N32_Names[regValue][RabbitizerConfig_Cfg.regNames.namedRegisters ? 1 : 0]; + + case RABBITIZER_ABI_N64: + return RabbitizerRegister_Cop1N64_Names[regValue][RabbitizerConfig_Cfg.regNames.namedRegisters ? 1 : 0]; + } +} + +const char *RabbitizerRegister_getNameCop1Control(uint8_t regValue) { + assert(regValue < ARRAY_COUNT(RabbitizerRegister_Cop1Control_Names)); + + return RabbitizerRegister_Cop1Control_Names[regValue][RabbitizerConfig_Cfg.regNames.namedRegisters && RabbitizerConfig_Cfg.regNames.userFpcCsr ? 1 : 0]; +} + +const char *RabbitizerRegister_getNameCop2(uint8_t regValue) { + assert(regValue < ARRAY_COUNT(RabbitizerRegister_Cop2_Names)); + + return RabbitizerRegister_Cop2_Names[regValue][RabbitizerConfig_Cfg.regNames.namedRegisters ? 1 : 0]; +} + +const char *RabbitizerRegister_getNameRspGpr(uint8_t regValue) { + assert(regValue < ARRAY_COUNT(RabbitizerRegister_RspGpr_Names)); + + return RabbitizerRegister_RspGpr_Names[regValue][RabbitizerConfig_Cfg.regNames.namedRegisters ? 1 : 0]; +} + +const char *RabbitizerRegister_getNameRspCop0(uint8_t regValue) { + assert(regValue < ARRAY_COUNT(RabbitizerRegister_RspCop0_Names)); + + return RabbitizerRegister_RspCop0_Names[regValue] + [RabbitizerConfig_Cfg.regNames.namedRegisters && RabbitizerConfig_Cfg.regNames.vr4300RspCop0NamedRegisters ? 1 : 0]; +} + +const char *RabbitizerRegister_getNameRspCop2(uint8_t regValue) { + assert(regValue < ARRAY_COUNT(RabbitizerRegister_RspCop2_Names)); + + return RabbitizerRegister_RspCop2_Names[regValue][RabbitizerConfig_Cfg.regNames.namedRegisters ? 1 : 0]; +} + +const char *RabbitizerRegister_getNameRspCop2Control(uint8_t regValue) { + assert(regValue < ARRAY_COUNT(RabbitizerRegister_RspCop2Control_Names)); + + return RabbitizerRegister_RspCop2Control_Names[regValue][RabbitizerConfig_Cfg.regNames.namedRegisters ? 1 : 0]; +} + +const char *RabbitizerRegister_getNameRspVector(uint8_t regValue) { + assert(regValue < ARRAY_COUNT(RabbitizerRegister_RspVector_Names)); + + return RabbitizerRegister_RspVector_Names[regValue][RabbitizerConfig_Cfg.regNames.namedRegisters ? 1 : 0]; +} + +const char *RabbitizerRegister_getNameR5900VF(uint8_t regValue) { + assert(regValue < ARRAY_COUNT(RabbitizerRegister_R5900VF_Names)); + + return RabbitizerRegister_R5900VF_Names[regValue][RabbitizerConfig_Cfg.regNames.namedRegisters ? 1 : 0]; +} + +const char *RabbitizerRegister_getNameR5900VI(uint8_t regValue) { + assert(regValue < ARRAY_COUNT(RabbitizerRegister_R5900VI_Names)); + + return RabbitizerRegister_R5900VI_Names[regValue][RabbitizerConfig_Cfg.regNames.namedRegisters ? 1 : 0]; +} diff --git a/tools/ido-static-recomp/tools/rabbitizer/test.c b/tools/ido-static-recomp/tools/rabbitizer/test.c new file mode 100644 index 00000000..e968dfaf --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/test.c @@ -0,0 +1,40 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +#include "instructions/RabbitizerInstruction.h" + +#include +#include +#include +#include + + +int main() { + uint32_t word; + RabbitizerInstruction instr; + char *buffer; + int extraLJust = 5; + size_t bufferSize; + size_t disassembledSize; + + word = 0x8D4A7E18; // lw + //word = 0x00004010; // mfhi + + RabbitizerInstruction_init(&instr, word, 0x80000000); + + RabbitizerInstruction_processUniqueId(&instr); + + bufferSize = RabbitizerInstruction_getSizeForBuffer(&instr, 0, extraLJust); + buffer = malloc(bufferSize + 1); + assert(buffer != NULL); + + disassembledSize = RabbitizerInstruction_disassemble(&instr, buffer, NULL, 0, extraLJust); + assert(disassembledSize <= bufferSize); + + printf("%08X: %s\n", word, buffer); + + free(buffer); + RabbitizerInstruction_destroy(&instr); + + return 0; +} diff --git a/tools/ido-static-recomp/tools/rabbitizer/tests/cplusplus/test.cpp b/tools/ido-static-recomp/tools/rabbitizer/tests/cplusplus/test.cpp new file mode 100644 index 00000000..689e12b3 --- /dev/null +++ b/tools/ido-static-recomp/tools/rabbitizer/tests/cplusplus/test.cpp @@ -0,0 +1,16 @@ +/* SPDX-FileCopyrightText: © 2022 Decompollaborate */ +/* SPDX-License-Identifier: MIT */ + +#include "instructions/InstructionCpu.hpp" + + +int main() { + uint32_t word = 0x8D4A7E18; // lw + uint32_t vram = 0x80000000; + int extraLJust = 5; + rabbitizer::InstructionCpu instr(word, vram); + + printf("%08X: %s\n", word, instr.disassemble(extraLJust).c_str()); + + return 0; +} diff --git a/tools/ido5.3_recomp/.gitignore b/tools/ido5.3_recomp/.gitignore deleted file mode 100644 index 6b747aba..00000000 --- a/tools/ido5.3_recomp/.gitignore +++ /dev/null @@ -1,16 +0,0 @@ -/recomp -/recomp-conservative - -/cc* -/cfe* -/uopt* -/ugen* -/as1* -/acpp* -/copt* -/ujoin* -/uld* -/umerge* -/usplit* - -/err.english.cc diff --git a/tools/ido5.3_recomp/Makefile b/tools/ido5.3_recomp/Makefile deleted file mode 100644 index 84a5de31..00000000 --- a/tools/ido5.3_recomp/Makefile +++ /dev/null @@ -1,37 +0,0 @@ -IRIX_ROOT := ../ido5.3_compiler - -cc: OPT_CFLAGS := -O2 -cfe: OPT_CFLAGS := -O2 -uopt: OPT_CFLAGS := -O2 -ugen: OPT_CFLAGS := -O2 -as1: OPT_CFLAGS := -O2 -acpp: OPT_CFLAGS := -O2 - -RECOMP := recomp - -ugen_c.c: RECOMP_FLAGS := --conservative - -all: cc cfe uopt ugen as1 acpp copt ujoin uld umerge usplit err.english.cc - -clean: - $(RM) cc* cfe* uopt* ugen* as1* acpp* copt* ujoin* uld* umerge* usplit* err.english.cc $(RECOMP) libc_impl.o - -$(RECOMP): recomp.cpp - $(CXX) $^ -o $@ -std=c++11 -O2 -Wno-switch `pkg-config --cflags --libs capstone` - -libc_impl.o: libc_impl.c libc_impl.h - $(CC) $< -c -fno-strict-aliasing -O2 -DIDO53 - -err.english.cc: $(IRIX_ROOT)/usr/lib/err.english.cc - cp $^ $@ - -cc_c.c: $(IRIX_ROOT)/usr/bin/cc $(RECOMP) - ./$(RECOMP) $(RECOMP_FLAGS) $< > $@ - -%_c.c: $(IRIX_ROOT)/usr/lib/% $(RECOMP) - ./$(RECOMP) $(RECOMP_FLAGS) $< > $@ - -%: %_c.c libc_impl.o - $(CC) libc_impl.o $< -o $@ $(OPT_CFLAGS) -fno-strict-aliasing -lm -no-pie - -.PHONY: all clean diff --git a/tools/ido5.3_recomp/recomp.cpp b/tools/ido5.3_recomp/recomp.cpp deleted file mode 100644 index 2bf6e132..00000000 --- a/tools/ido5.3_recomp/recomp.cpp +++ /dev/null @@ -1,2938 +0,0 @@ -#include -#include -#include -#include -#include - -#include -#include -#include -#include -#include - -#include - -#include "elf.h" - -#define INSPECT_FUNCTION_POINTERS 0 // set this to 1 when testing a new program, to verify that no false function pointers are found - -#ifndef TRACE -#define TRACE 0 -#endif - -#define LABELS_64_BIT 1 - -#define u32be(x) (uint32_t)(((x & 0xff) << 24) + ((x & 0xff00) << 8) + ((x & 0xff0000) >> 8) + ((uint32_t)(x) >> 24)) -#define u16be(x) (uint16_t)(((x & 0xff) << 8) + ((x & 0xff00) >> 8)) -#define read_u32_be(buf) (uint32_t)(((buf)[0] << 24) + ((buf)[1] << 16) + ((buf)[2] << 8) + ((buf)[3])) - -using namespace std; - -struct Edge { - uint32_t i; - uint8_t function_entry: 1; - uint8_t function_exit: 1; - uint8_t extern_function: 1; - uint8_t function_pointer: 1; -}; - -struct Insn { - uint32_t id; - uint8_t op_count; - string mnemonic; - string op_str; - cs_mips_op operands[8]; - - uint8_t is_jump: 1; - uint8_t is_global_got_memop: 1; - uint8_t no_following_successor: 1; - int linked_insn; - union { - uint32_t linked_value; - float linked_float; - }; - uint32_t jtbl_addr; - uint32_t num_cases; - mips_reg index_reg; - vector successors; - vector predecessors; - uint64_t b_liveout; - uint64_t b_livein; - uint64_t f_livein; - uint64_t f_liveout; -}; - -struct Function { - vector returns; //points to delay slots - uint32_t end_addr; //address after end - uint32_t nargs; - uint32_t nret; - bool v0_in; - bool referenced_by_function_pointer; -}; - -static bool conservative; - -static csh handle; - -static const uint8_t *text_section; -static uint32_t text_section_len; -static uint32_t text_vaddr; - -static const uint8_t *rodata_section; -static uint32_t rodata_section_len; -static uint32_t rodata_vaddr; - -static const uint8_t *data_section; -static uint32_t data_section_len; -static uint32_t data_vaddr; - -static uint32_t bss_section_len; -static uint32_t bss_vaddr; - -static vector insns; -static set label_addresses; -static vector got_globals; -static vector got_locals; -static uint32_t gp_value; -static uint32_t gp_value_adj; - -static map symbol_names; - -static vector> data_function_pointers; -static set li_function_pointers; -static map functions; -static uint32_t main_addr; -static uint32_t mcount_addr; -static uint32_t procedure_table_start; -static uint32_t procedure_table_len; - -#define FLAG_NO_MEM 1 -#define FLAG_VARARG 2 - -static const struct { - const char *name; - const char *params; - int flags; -} extern_functions[] = { - {"exit", "vi"}, // override exit from application - {"abort", "v"}, - {"sbrk", "pi"}, - {"malloc", "pu"}, - {"calloc", "puu"}, - {"realloc", "ppu"}, - {"free", "vp"}, - {"fscanf", "ipp", FLAG_VARARG}, - {"printf", "ip", FLAG_VARARG}, - {"sprintf", "ipp", FLAG_VARARG}, - {"fprintf", "ipp", FLAG_VARARG}, - {"_doprnt", "ippp"}, - {"strlen", "up"}, - {"open", "ipii"}, - {"creat", "ipi"}, - {"access", "ipi"}, - {"rename", "ipp"}, - {"utime", "ipp"}, - {"flock", "iii"}, - {"chmod", "ipu"}, - {"umask", "ii", FLAG_NO_MEM}, - {"ecvt", "pdipp"}, - {"fcvt", "pdipp"}, - {"sqrt", "dd", FLAG_NO_MEM}, - {"sqrtf", "ff", FLAG_NO_MEM}, - {"atoi", "ip"}, - {"atol", "ip"}, - {"atof", "dp"}, - {"strtol", "ippi"}, - {"strtoul", "uppi"}, - {"strtod", "dpp"}, - {"strchr", "ppi"}, - {"strrchr", "ppi"}, - {"strcspn", "upp"}, - {"strpbrk", "ppp"}, - {"fstat", "iip"}, - {"stat", "ipp"}, - {"ftruncate", "iii"}, - {"bcopy", "vppu"}, - {"memcpy", "pppu"}, - {"memccpy", "pppiu"}, - {"read", "iipu"}, - {"write", "iipu"}, - {"fopen", "ppp"}, - {"freopen", "pppp"}, - {"fclose", "ip"}, - {"ftell", "ip"}, - {"rewind", "vp"}, - {"fseek", "ipii"}, - {"lseek", "iiii"}, - {"fflush", "ip"}, - {"dup", "ii"}, - {"dup2", "iii"}, - {"pipe", "ip"}, - {"perror", "vp"}, - {"fdopen", "iip"}, - {"memset", "ppiu"}, - {"bcmp", "ippu"}, - {"memcmp", "ippu"}, - {"getpid", "i", FLAG_NO_MEM}, - {"getpgrp", "i"}, - {"remove", "ip"}, - {"unlink", "ip"}, - {"close", "ii"}, - {"strcmp", "ipp"}, - {"strncmp", "ippu"}, - {"strcpy", "ppp"}, - {"strncpy", "pppu"}, - {"strcat", "ppp"}, - {"strncat", "pppu"}, - {"strtok", "ppp"}, - {"strstr", "ppp"}, - {"strdup", "pp"}, - {"toupper", "ii", FLAG_NO_MEM}, - {"tolower", "ii", FLAG_NO_MEM}, - {"gethostname", "ipu"}, - {"isatty", "ii"}, - {"strftime", "upupp"}, - {"times", "ip"}, - {"clock", "i", FLAG_NO_MEM}, - {"ctime", "pp"}, - {"localtime", "pp"}, - {"setvbuf", "ippiu"}, - {"__semgetc", "ip"}, - {"__semputc", "iip"}, - {"fgetc", "ip"}, - {"fgets", "ipip"}, - {"__filbuf", "ip"}, - {"__flsbuf", "iip"}, - {"ungetc", "iip"}, - {"gets", "pp"}, - {"fread", "upuup"}, - {"fwrite", "upuup"}, - {"fputs", "ipp"}, - {"puts", "ip"}, - {"getcwd", "ppu"}, - {"time", "ip"}, - {"bzero", "vpu"}, - {"fp_class_d", "id", FLAG_NO_MEM}, - {"ldexp", "ddi", FLAG_NO_MEM}, - {"__ll_mul", "lll", FLAG_NO_MEM}, - {"__ll_div", "lll", FLAG_NO_MEM}, - {"__ll_rem", "ljl", FLAG_NO_MEM}, - {"__ll_lshift", "llj", FLAG_NO_MEM}, - {"__ll_rshift", "llj", FLAG_NO_MEM}, - {"__ull_div", "jjj", FLAG_NO_MEM}, - {"__ull_rem", "jjj", FLAG_NO_MEM}, - {"__ull_rshift", "jjj", FLAG_NO_MEM}, - {"__d_to_ull", "jd", FLAG_NO_MEM}, - {"__d_to_ll", "ld", FLAG_NO_MEM}, - {"__f_to_ull", "jf", FLAG_NO_MEM}, - {"__f_to_ll", "lf", FLAG_NO_MEM}, - {"__ull_to_f", "fj", FLAG_NO_MEM}, - {"__ll_to_f", "fl", FLAG_NO_MEM}, - {"__ull_to_d", "dj", FLAG_NO_MEM}, - {"__ll_to_d", "dl", FLAG_NO_MEM}, - {"_exit", "vi"}, - {"_cleanup", "v"}, - {"_rld_new_interface", "pu", FLAG_VARARG}, - {"_exithandle", "v"}, - {"_prctl", "ii", FLAG_VARARG}, - {"_atod", "dpii"}, - {"pathconf", "ipi"}, - {"getenv", "pp"}, - {"gettxt", "ppp"}, - {"setlocale", "pip"}, - {"mmap", "ppuiiii"}, - {"munmap", "ipu"}, - {"mprotect", "ipui"}, - {"sysconf", "ii"}, - {"getpagesize", "i"}, - {"strerror", "pi"}, - {"ioctl", "iiu", FLAG_VARARG}, - {"fcntl", "iii", FLAG_VARARG}, - {"signal", "pit"}, - {"sigset", "pit"}, - {"get_fpc_csr", "i"}, - {"set_fpc_csr", "ii"}, - {"setjmp", "ip"}, - {"longjmp", "vpi"}, - {"tempnam", "ppp"}, - {"tmpnam", "pp"}, - {"mktemp", "pp"}, - {"mkstemp", "ip"}, - {"tmpfile", "p"}, - {"wait", "ip"}, - {"kill", "iii"}, - {"execlp", "ip", FLAG_VARARG}, - {"execv", "ipp"}, - {"execvp", "ipp"}, - {"fork", "i"}, - {"system", "ip"}, - {"tsearch", "pppp"}, - {"tfind", "pppp"}, - {"qsort", "vpuut"}, - {"regcmp", "pp", FLAG_VARARG}, - {"regex", "ppp", FLAG_VARARG}, - {"__assert", "vppi"}, -}; - -static void disassemble(void) { - csh handle; - cs_insn *disasm; - size_t disasm_size = 0; - assert(cs_open(CS_ARCH_MIPS, (cs_mode)(CS_MODE_MIPS64 | CS_MODE_BIG_ENDIAN), &handle) == CS_ERR_OK); - cs_option(handle, CS_OPT_DETAIL, CS_OPT_ON); - insns.reserve(1 + text_section_len / sizeof(uint32_t)); // +1 for dummy instruction - while (text_section_len > disasm_size * sizeof(uint32_t)) { - size_t disasm_len = disasm_size * sizeof(uint32_t); - size_t remaining = text_section_len - disasm_len; - size_t current_len = std::min(remaining, 1024); - size_t cur_disasm_size = cs_disasm(handle, &text_section[disasm_len], current_len, text_vaddr + disasm_len, 0, &disasm); - disasm_size += cur_disasm_size; - for (size_t i = 0; i < cur_disasm_size; i++) { - insns.push_back(Insn()); - Insn& insn = insns.back(); - insn.id = disasm[i].id; - insn.mnemonic = disasm[i].mnemonic; - insn.op_str = disasm[i].op_str; - if (disasm[i].detail != nullptr && disasm[i].detail->mips.op_count > 0) { - insn.op_count = disasm[i].detail->mips.op_count; - memcpy(insn.operands, disasm[i].detail->mips.operands, sizeof(insn.operands)); - } - insn.is_jump = cs_insn_group(handle, &disasm[i], MIPS_GRP_JUMP) || insn.id == MIPS_INS_JAL || insn.id == MIPS_INS_BAL || insn.id == MIPS_INS_JALR; - insn.linked_insn = -1; - } - cs_free(disasm, cur_disasm_size); - } - cs_close(&handle); - - { - // Add dummy instruction to avoid out of bounds - insns.push_back(Insn()); - Insn& insn = insns.back(); - insn.id = MIPS_INS_NOP; - insn.mnemonic = "nop"; - insn.no_following_successor = true; - } -} - -static void add_function(uint32_t addr) { - if (addr >= text_vaddr && addr < text_vaddr + text_section_len) { - functions[addr]; - } -} - -static map::iterator find_function(uint32_t addr) { - if (functions.size() == 0) { - return functions.end(); - } - auto it = functions.upper_bound(addr); - if (it == functions.begin()) { - return functions.end(); - } - --it; - return it; -} - -// try to find a matching LUI for a given register -static void link_with_lui(int offset, uint32_t reg, int mem_imm) -{ -#define MAX_LOOKBACK 128 - // don't attempt to compute addresses for zero offset - // end search after some sane max number of instructions - int end_search = std::max(0, offset - MAX_LOOKBACK); - for (int search = offset - 1; search >= end_search; search--) { - // use an `if` instead of `case` block to allow breaking out of the `for` loop - if (insns[search].id == MIPS_INS_LUI) { - uint32_t rd = insns[search].operands[0].reg; - if (reg == rd) { - break; - } - } else if (insns[search].id == MIPS_INS_LW || - insns[search].id == MIPS_INS_LD || - insns[search].id == MIPS_INS_ADDIU || - //insns[search].id == MIPS_INS_ADDU || used in jump tables for offset - insns[search].id == MIPS_INS_ADD || - insns[search].id == MIPS_INS_SUB || - insns[search].id == MIPS_INS_SUBU) { - uint32_t rd = insns[search].operands[0].reg; - if (reg == rd) { - if (insns[search].id == MIPS_INS_LW && insns[search].operands[1].mem.base == MIPS_REG_GP) { - int mem_imm0 = (int)insns[search].operands[1].mem.disp; - uint32_t got_entry = (mem_imm0 + gp_value_adj) / sizeof(uint32_t); - if (got_entry < got_locals.size()) { - // used for static functions - char buf[32]; - uint32_t addr = got_locals[got_entry] + mem_imm; - insns[search].linked_insn = offset; - insns[search].linked_value = addr; - insns[offset].linked_insn = search; - insns[offset].linked_value = addr; - - //vaddr_references[addr].insert(text_vaddr + offset * 4); - - insns[search].id = MIPS_INS_LI; - insns[search].mnemonic = "li"; - sprintf(buf, "$%s, 0x%x", cs_reg_name(handle, rd), addr); - insns[search].op_str = buf; - insns[search].operands[1].type = MIPS_OP_IMM; - insns[search].operands[1].imm = addr; - - switch (insns[offset].id) { - case MIPS_INS_ADDIU: - insns[offset].id = MIPS_INS_MOVE; - insns[offset].operands[1].type = MIPS_OP_REG; - insns[offset].mnemonic = "move"; - sprintf(buf, "$%s, $%s", cs_reg_name(handle, insns[offset].operands[0].reg), cs_reg_name(handle, rd)); - insns[offset].op_str = buf; - if (addr >= text_vaddr && addr < text_vaddr + text_section_len) { - add_function(addr); - } - break; - case MIPS_INS_LB: - case MIPS_INS_LBU: - case MIPS_INS_SB: - case MIPS_INS_LH: - case MIPS_INS_LHU: - case MIPS_INS_SH: - case MIPS_INS_LW: - case MIPS_INS_SW: - case MIPS_INS_LDC1: - case MIPS_INS_LWC1: - case MIPS_INS_SWC1: - insns[offset].operands[1].mem.disp = 0; - sprintf(buf, "$%s, ($%s)", cs_reg_name(handle, insns[offset].operands[0].reg), cs_reg_name(handle, rd)); - insns[offset].op_str = buf; - break; - default: - assert(0); - } - } - break; - } else { - // ignore: reg is pointer, offset is probably struct data member - break; - } - } - } else if (insns[search].id == MIPS_INS_JR && - insns[search].operands[0].reg == MIPS_REG_RA && offset - search >= 2) { - // stop looking when previous `jr ra` is hit, - // but ignore if `offset` is branch delay slot for this `jr ra` - break; - } - } -} - -// for a given `jalr t9`, find the matching t9 load -static void link_with_jalr(int offset) -{ - // end search after some sane max number of instructions - int end_search = std::max(0, offset - MAX_LOOKBACK); - for (int search = offset - 1; search >= end_search; search--) { - if (insns[search].operands[0].reg == MIPS_REG_T9) { - if (insns[search].id == MIPS_INS_LW || insns[search].id == MIPS_INS_LI) { - if (insns[search].is_global_got_memop || insns[search].id == MIPS_INS_LI) { - char buf[32]; - sprintf(buf, "0x%x", insns[search].linked_value); - insns[search].linked_insn = offset; - insns[offset].linked_insn = search; - insns[offset].linked_value = insns[search].linked_value; - //insns[offset].label = insns[search].label; - //function_entry_points.insert(insns[search].linked_value); - insns[offset].id = MIPS_INS_JAL; - insns[offset].mnemonic = "jal"; - insns[offset].op_str = buf; - insns[offset].operands[0].type = MIPS_OP_IMM; - insns[offset].operands[0].imm = insns[search].linked_value; - insns[search].id = MIPS_INS_NOP; - insns[search].mnemonic = "nop"; - insns[search].op_str = ""; - insns[search].is_global_got_memop = false; - add_function(insns[search].linked_value); - } - break; - } else if (insns[search].id == MIPS_INS_ADDIU) { - if (insns[search].linked_insn != -1) { - //function_entry_points.insert(insns[search].linked_value); - uint32_t first = insns[search].linked_insn; - insns[search].linked_insn = offset; - insns[offset].linked_insn = first; - insns[offset].linked_value = insns[search].linked_value; - } - break; - } else if (insns[search].id == MIPS_INS_LI) { - if (insns[search].linked_insn != -1) { - //function_entry_points.insert(insns[search].linked_value); - uint32_t first = insns[search].linked_insn; - insns[search].linked_insn = offset; - insns[offset].linked_insn = first; - insns[offset].linked_value = insns[search].linked_value; - insns[search].id = MIPS_INS_NOP; - insns[search].mnemonic = "nop"; - insns[search].op_str = ""; - } - break; - } else if (insns[search].id == MIPS_INS_LD || - insns[search].id == MIPS_INS_ADDU || - insns[search].id == MIPS_INS_ADD || - insns[search].id == MIPS_INS_SUB || - insns[search].id == MIPS_INS_SUBU) { - break; - } - } else if (insns[search].id == MIPS_INS_JR && - insns[search].operands[0].reg == MIPS_REG_RA) - { - // stop looking when previous `jr ra` is hit - break; - } - } -} - -static void pass1(void) { - for (size_t i = 0; i < insns.size(); i++) { - Insn& insn = insns[i]; - if (insn.id == MIPS_INS_BAL) { - insn.id = MIPS_INS_JAL; - insn.mnemonic = "jal"; - } - if (insn.is_jump) { - if (insn.id == MIPS_INS_JAL || insn.id == MIPS_INS_J) { - uint32_t target = (uint32_t)insn.operands[0].imm; - label_addresses.insert(target); - add_function(target); - } else if (insn.id == MIPS_INS_JR) { - // sltiu $at, $ty, z - // sw $reg, offset($sp) (very seldom, one or more, usually in func entry) - // lw $gp, offset($sp) (if PIC, and very seldom) - // beqz $at, .L - // some other instruction (not always) - // lui $at, %hi(jtbl) - // sll $tx, $ty, 2 - // addu $at, $at, $tx - // lw $tx, %lo(jtbl)($at) - // nop (code compiled with 5.3) - // addu $tx, $tx, $gp (if PIC) - // jr $tx - - // IDO 7.1: - //lw at,offset(gp) - //andi t9,t8,0x3f - //sll t9,t9,0x2 - //addu at,at,t9 - //lw t9,offset(at) - //addu t9,t9,gp - //jr t9 - - // IDO 5.3: - //lw at,offset(gp) - //andi t3,t2,0x3f - //sll t3,t3,0x2 - //addu at,at,t3 - //something - //lw t3,offset(at) - //something - //addu t3,t3,gp - //jr t3 - if (i >= 7 && rodata_section != NULL) { - bool is_pic = insns[i - 1].id == MIPS_INS_ADDU && insns[i - 1].operands[2].reg == MIPS_REG_GP; - bool has_nop = insns[i - is_pic - 1].id == MIPS_INS_NOP; - bool has_extra = insns[i - is_pic - has_nop - 5].id != MIPS_INS_BEQZ; - int lw = i - is_pic - has_nop - 1; - if (insns[lw].id != MIPS_INS_LW) { - --lw; - } - if (insns[lw].id == MIPS_INS_LW && insns[lw].linked_insn != -1) { - int sltiu_index = -1; - int andi_index = -1; - uint32_t addu_index = lw - 1; - uint32_t num_cases; - bool found = false; - bool and_variant = false; - int end = 14; - if (insns[addu_index].id != MIPS_INS_ADDU) { - --addu_index; - } - mips_reg index_reg = (mips_reg)insns[addu_index - 1].operands[1].reg; - if (insns[addu_index].id != MIPS_INS_ADDU) { - goto skip; - } - if (insns[addu_index - 1].id != MIPS_INS_SLL) { - goto skip; - } - if (insns[addu_index - 1].operands[0].reg != insn.operands[0].reg) { - goto skip; - } - for (int j = 3; j <= 4; j++) { - if (insns[lw - j].id == MIPS_INS_ANDI) { - andi_index = lw - j; - break; - } - } - if (i == 368393) { - // In copt - end = 18; - } - for (int j = 5; j <= end; j++) { - if (insns[lw - has_extra - j].id == MIPS_INS_SLTIU && - insns[lw - has_extra - j].operands[0].reg == MIPS_REG_AT) - { - sltiu_index = j; - break; - } - if (insns[lw - has_extra - j].id == MIPS_INS_JR) { - // Prevent going into a previous switch - break; - } - } - if (sltiu_index != -1) { - andi_index = -1; - } - if (sltiu_index != -1 && insns[lw - has_extra - sltiu_index].id == MIPS_INS_SLTIU) { - num_cases = insns[lw - has_extra - sltiu_index].operands[2].imm; - found = true; - } else if (andi_index != -1) { - num_cases = insns[andi_index].operands[2].imm + 1; - found = true; - and_variant = true; - } else if (i == 219382) { - // Special hard case in copt where the initial sltiu is in another basic block - found = true; - num_cases = 13; - } else if (i == 370995) { - // Special hard case in copt where the initial sltiu is in another basic block - found = true; - num_cases = 12; - } - if (found) { - uint32_t jtbl_addr = insns[lw].linked_value; - if (is_pic) { - insns[i - 1].id = MIPS_INS_NOP; - } - //printf("jump table at %08x, size %u\n", jtbl_addr, num_cases); - insn.jtbl_addr = jtbl_addr; - insn.num_cases = num_cases; - insn.index_reg = index_reg; - insns[lw].id = MIPS_INS_NOP; - insns[addu_index].id = MIPS_INS_NOP; - insns[addu_index - 1].id = MIPS_INS_NOP; - if (!and_variant) { - insns[addu_index - 2].id = MIPS_INS_NOP; - } - - if (jtbl_addr < rodata_vaddr || jtbl_addr + num_cases * sizeof(uint32_t) > rodata_vaddr + rodata_section_len) { - fprintf(stderr, "jump table outside rodata\n"); - exit(EXIT_FAILURE); - } - for (uint32_t i = 0; i < num_cases; i++) { - uint32_t target_addr = read_u32_be(rodata_section + (jtbl_addr - rodata_vaddr) + i * sizeof(uint32_t)); - target_addr += gp_value; - //printf("%08X\n", target_addr); - label_addresses.insert(target_addr); - } - } - skip:; - } - } - } else { - for (int j = 0; j < insn.op_count; j++) { - if (insn.operands[j].type == MIPS_OP_IMM) { - uint32_t target = (uint32_t)insn.operands[j].imm; - label_addresses.insert(target); - } - } - } - } - switch (insns[i].id) { - // find floating point LI - case MIPS_INS_MTC1: - { - unsigned int rt = insns[i].operands[0].reg; - for (int s = i - 1; s >= 0; s--) { - if (insns[s].id == MIPS_INS_LUI && insns[s].operands[0].reg == rt) { - float f; - uint32_t lui_imm = (uint32_t)(insns[s].operands[1].imm << 16); - memcpy(&f, &lui_imm, sizeof(f)); - insns[s].operands[1].imm <<= 16; - // link up the LUI with this instruction and the float - insns[s].linked_insn = i; - insns[s].linked_float = f; - // rewrite LUI instruction to be LI - insns[s].id = MIPS_INS_LI; - insns[s].mnemonic = "li"; - break; - } else if (insns[s].id == MIPS_INS_LW || - insns[s].id == MIPS_INS_LD || - insns[s].id == MIPS_INS_LH || - insns[s].id == MIPS_INS_LHU || - insns[s].id == MIPS_INS_LB || - insns[s].id == MIPS_INS_LBU || - insns[s].id == MIPS_INS_ADDIU || - insns[s].id == MIPS_INS_ADD || - insns[s].id == MIPS_INS_SUB || - insns[s].id == MIPS_INS_SUBU) { - unsigned int rd = insns[s].operands[0].reg; - if (rt == rd) { - break; - } - } else if (insns[s].id == MIPS_INS_JR && - insns[s].operands[0].reg == MIPS_REG_RA) { - // stop looking when previous `jr ra` is hit - break; - } - } - break; - } - case MIPS_INS_SD: - case MIPS_INS_SW: - case MIPS_INS_SH: - case MIPS_INS_SB: - case MIPS_INS_LB: - case MIPS_INS_LBU: - case MIPS_INS_LD: - case MIPS_INS_LDL: - case MIPS_INS_LDR: - case MIPS_INS_LH: - case MIPS_INS_LHU: - case MIPS_INS_LW: - case MIPS_INS_LWU: - case MIPS_INS_LDC1: - case MIPS_INS_LWC1: - case MIPS_INS_LWC2: - case MIPS_INS_LWC3: - case MIPS_INS_SWC1: - case MIPS_INS_SWC2: - case MIPS_INS_SWC3: - { - unsigned int mem_rs = insns[i].operands[1].mem.base; - int mem_imm = (int)insns[i].operands[1].mem.disp; - if (mem_rs == MIPS_REG_GP) { - unsigned int got_entry = (mem_imm + gp_value_adj) / sizeof(unsigned int); - if (got_entry >= got_locals.size()) { - got_entry -= got_locals.size(); - if (got_entry < got_globals.size()) { - assert(insn.id == MIPS_INS_LW); - //printf("gp 0x%08x %s\n", mem_imm, got_globals[got_entry].name); - unsigned int dest_vaddr = got_globals[got_entry]; - insns[i].is_global_got_memop = true; - insns[i].linked_value = dest_vaddr; - //insns[i].label = got_globals[got_entry].name; - - //vaddr_references[dest_vaddr].insert(vaddr + i * 4); - //disasm_add_data_addr(state, dest_vaddr); - insns[i].id = MIPS_INS_LI; - insns[i].operands[1].imm = dest_vaddr; - char buf[32]; - sprintf(buf, "$%s, 0x%x", cs_reg_name(handle, insn.operands[0].reg), dest_vaddr); - insns[i].op_str = buf; - } - } - } else { - link_with_lui(i, mem_rs, mem_imm); - } - break; - } - case MIPS_INS_ADDIU: - case MIPS_INS_ORI: - { - unsigned int rd = insns[i].operands[0].reg; - unsigned int rs = insns[i].operands[1].reg; - int64_t imm = insns[i].operands[2].imm; - if (rs == MIPS_REG_ZERO) { // becomes LI - char buf[32]; - insns[i].id = MIPS_INS_LI; - insns[i].operands[1].imm = imm; - insns[i].mnemonic = "li"; - sprintf(buf, "$%s, %" PRIi64, cs_reg_name(handle, rd), imm); - insns[i].op_str = buf; - } else if (/*rd == rs &&*/ rd != MIPS_REG_GP) { // only look for LUI if rd and rs are the same - link_with_lui(i, rs, (int)imm); - } - break; - } - case MIPS_INS_JALR: - { - unsigned int r = insn.operands[0].reg; - if (r == MIPS_REG_T9) { - link_with_jalr(i); - if (insn.linked_insn != -1) { - char buf[32]; - sprintf(buf, "0x%x", insn.linked_value); - insn.id = MIPS_INS_JAL; - insn.mnemonic = "jal"; - insn.op_str = buf; - insn.operands[0].type = MIPS_OP_IMM; - insn.operands[0].imm = insn.linked_value; - label_addresses.insert(insn.linked_value); - add_function(insn.linked_value); - } - } - break; - } - } - if (insn.id == MIPS_INS_ADDU && insn.operands[0].reg == MIPS_REG_GP && insn.operands[1].reg == MIPS_REG_GP && insn.operands[2].reg == MIPS_REG_T9 && i >= 2) { - //state->function_entry_points.insert(vaddr + (i - 2) * 4); - for (int j = i - 2; j <= i; j++) { - insns[j].id = MIPS_INS_NOP; - insns[j].mnemonic = "nop"; - insns[j].op_str = ""; - } - } - } -} - -static uint32_t addr_to_i(uint32_t addr) { - return (addr - text_vaddr) / 4; -} - -static void pass2(void) { - // Find returns in each function - for (size_t i = 0; i < insns.size(); i++) { - uint32_t addr = text_vaddr + i * 4; - Insn& insn = insns[i]; - if (insn.id == MIPS_INS_JR && insn.operands[0].reg == MIPS_REG_RA) { - auto it = find_function(addr); - assert(it != functions.end()); - it->second.returns.push_back(addr + 4); - } - if (insn.is_global_got_memop && text_vaddr <= insn.operands[1].imm && insn.operands[1].imm < text_vaddr + text_section_len) { - uint32_t faddr = insn.operands[1].imm; - li_function_pointers.insert(faddr); - functions[faddr].referenced_by_function_pointer = true; -#if INSPECT_FUNCTION_POINTERS - fprintf(stderr, "li function pointer: 0x%x at 0x%x\n", faddr, addr); -#endif - } - } - for (auto it = functions.begin(); it != functions.end(); ++it) { - if (it->second.returns.size() == 0) { - uint32_t i = addr_to_i(it->first); - auto str_it = symbol_names.find(it->first); - if (str_it != symbol_names.end() && str_it->second == "__start") { - - } else if (str_it != symbol_names.end() && str_it->second == "xmalloc") { - // orig 5.3: - /* - 496bf4: 3c1c0fb9 lui gp,0xfb9 - 496bf8: 279c366c addiu gp,gp,13932 - 496bfc: 0399e021 addu gp,gp,t9 - 496c00: 27bdffd8 addiu sp,sp,-40 - 496c04: 8f858de8 lw a1,-29208(gp) - 496c08: 10000006 b 496c24 - 496c0c: afbf0020 sw ra,32(sp) - */ - - // jal alloc_new - // lui $a1, malloc_scb - // jr $ra - // nop - uint32_t alloc_new_addr = text_vaddr + (i + 7) * 4; - insns[i].id = MIPS_INS_JAL; - insns[i].op_count = 1; - insns[i].mnemonic = "jal"; - insns[i].op_str = "alloc_new"; - insns[i].operands[0].imm = alloc_new_addr; - assert(symbol_names.count(alloc_new_addr) && symbol_names[alloc_new_addr] == "alloc_new"); - i++; - if (insns[i + 5].id == MIPS_INS_LI) { - // 7.1 - insns[i] = insns[i + 5]; - } else { - // 5.3 - insns[i] = insns[i + 3]; - } - i++; - insns[i].id = MIPS_INS_JR; - insns[i].op_count = 1; - insns[i].mnemonic = "jr"; - insns[i].op_str = "$ra"; - insns[i].operands[0].reg = MIPS_REG_RA; - it->second.returns.push_back(text_vaddr + i * 4 + 4); - i++; - for (uint32_t j = 0; j < 4; j++) { - insns[i].id = MIPS_INS_NOP; - insns[i].op_count = 0; - insns[i].mnemonic = "nop"; - i++; - } - } else if (str_it != symbol_names.end() && str_it->second == "xfree") { - // jal alloc_dispose - // lui $a1, malloc_scb - // jr $ra - // nop - uint32_t alloc_dispose_addr = text_vaddr + (i + 4) * 4; - if (symbol_names.count(alloc_dispose_addr + 4) && symbol_names[alloc_dispose_addr + 4] == "alloc_dispose") { - alloc_dispose_addr += 4; - } - insns[i].id = MIPS_INS_JAL; - insns[i].op_count = 1; - insns[i].mnemonic = "jal"; - insns[i].op_str = "alloc_dispose"; - insns[i].operands[0].imm = alloc_dispose_addr; - assert(symbol_names.count(alloc_dispose_addr) && symbol_names[alloc_dispose_addr] == "alloc_dispose"); - i++; - insns[i] = insns[i + 2]; - i++; - insns[i].id = MIPS_INS_JR; - insns[i].op_count = 1; - insns[i].mnemonic = "jr"; - insns[i].op_str = "$ra"; - insns[i].operands[0].reg = MIPS_REG_RA; - it->second.returns.push_back(text_vaddr + i * 4 + 4); - i++; - insns[i].id = MIPS_INS_NOP; - insns[i].op_count = 0; - insns[i].mnemonic = "nop"; - } else if (insns[i].id == MIPS_INS_LW && insns[i + 1].id == MIPS_INS_MOVE && insns[i + 2].id == MIPS_INS_JALR) { - /* - 408f50: 8f998010 lw t9,-32752(gp) - 408f54: 03e07821 move t7,ra - 408f58: 0320f809 jalr t9 - */ - } else if (it->first > mcount_addr) { - fprintf(stderr, "no ret: 0x%x\n", it->first); - abort(); - } - } - auto next = it; - ++next; - if (next == functions.end()) { - it->second.end_addr = text_vaddr + text_section_len; - } else { - it->second.end_addr = next->first; - } - } -} - -static void add_edge(uint32_t from, uint32_t to, bool function_entry = false, bool function_exit = false, bool extern_function = false, bool function_pointer = false) { - Edge fe = Edge(), be = Edge(); - fe.i = to; - be.i = from; - fe.function_entry = function_entry; - be.function_entry = function_entry; - fe.function_exit = function_exit; - be.function_exit = function_exit; - fe.extern_function = extern_function; - be.extern_function = extern_function; - fe.function_pointer = function_pointer; - be.function_pointer = function_pointer; - insns[from].successors.push_back(fe); - insns[to].predecessors.push_back(be); -} - -static void pass3(void) { - // Build graph - for (size_t i = 0; i < insns.size(); i++) { - uint32_t addr = text_vaddr + i * 4; - Insn& insn = insns[i]; - if (insn.no_following_successor) { - continue; - } - switch (insn.id) { - case MIPS_INS_BEQ: - case MIPS_INS_BGEZ: - case MIPS_INS_BGTZ: - case MIPS_INS_BLEZ: - case MIPS_INS_BLTZ: - case MIPS_INS_BNE: - case MIPS_INS_BEQZ: - case MIPS_INS_BNEZ: - case MIPS_INS_BC1F: - case MIPS_INS_BC1T: - add_edge(i, i + 1); - add_edge(i + 1, addr_to_i((uint32_t)insn.operands[insn.op_count - 1].imm)); - break; - - case MIPS_INS_BEQL: - case MIPS_INS_BGEZL: - case MIPS_INS_BGTZL: - case MIPS_INS_BLEZL: - case MIPS_INS_BLTZL: - case MIPS_INS_BNEL: - case MIPS_INS_BC1FL: - case MIPS_INS_BC1TL: - add_edge(i, i + 1); - add_edge(i, i + 2); - add_edge(i + 1, addr_to_i((uint32_t)insn.operands[insn.op_count - 1].imm)); - insns[i + 1].no_following_successor = true; // don't inspect delay slot - break; - - case MIPS_INS_B: - case MIPS_INS_J: - add_edge(i, i + 1); - add_edge(i + 1, addr_to_i((uint32_t)insn.operands[0].imm)); - insns[i + 1].no_following_successor = true; // don't inspect delay slot - break; - - case MIPS_INS_JR: { - add_edge(i, i + 1); - if (insn.jtbl_addr != 0) { - uint32_t jtbl_pos = insn.jtbl_addr - rodata_vaddr; - assert(jtbl_pos < rodata_section_len && jtbl_pos + insn.num_cases * 4 <= rodata_section_len); - for (uint32_t j = 0; j < insn.num_cases; j++) { - uint32_t dest_addr = read_u32_be(rodata_section + jtbl_pos + j * 4) + gp_value; - add_edge(i + 1, addr_to_i(dest_addr)); - } - } else { - assert(insn.operands[0].reg == MIPS_REG_RA && "jump to address in register not supported"); - } - insns[i + 1].no_following_successor = true; // don't inspect delay slot - break; - } - - case MIPS_INS_JAL: { - add_edge(i, i + 1); - uint32_t dest = (uint32_t)insn.operands[0].imm; - if (dest > mcount_addr && dest >= text_vaddr && dest < text_vaddr + text_section_len) { - add_edge(i + 1, addr_to_i(dest), true); - auto it = functions.find(dest); - assert(it != functions.end()); - for (uint32_t ret_instr : it->second.returns) { - add_edge(addr_to_i(ret_instr), i + 2, false, true); - } - } else { - add_edge(i + 1, i + 2, false, false, true); - } - insns[i + 1].no_following_successor = true; // don't inspect delay slot - break; - } - - case MIPS_INS_JALR: - // function pointer - add_edge(i, i + 1); - add_edge(i + 1, i + 2, false, false, false, true); - insns[i + 1].no_following_successor = true; // don't inspect delay slot - break; - - default: - add_edge(i, i + 1); - break; - } - } -} - -static uint64_t map_reg(int32_t reg) { - if (reg > MIPS_REG_31) { - if (reg == MIPS_REG_HI) { - reg = MIPS_REG_31 + 1; - } else if (reg == MIPS_REG_LO) { - reg = MIPS_REG_31 + 2; - } else { - return 0; - } - } - return (uint64_t)1 << (reg - MIPS_REG_0 + 1); -} - -static uint64_t temporary_regs(void) { - return - map_reg(MIPS_REG_T0) | - map_reg(MIPS_REG_T1) | - map_reg(MIPS_REG_T2) | - map_reg(MIPS_REG_T3) | - map_reg(MIPS_REG_T4) | - map_reg(MIPS_REG_T5) | - map_reg(MIPS_REG_T6) | - map_reg(MIPS_REG_T7) | - map_reg(MIPS_REG_T8) | - map_reg(MIPS_REG_T9); -} - -typedef enum { - TYPE_NOP, - TYPE_1S, - TYPE_2S, - TYPE_1D, - TYPE_1D_1S, - TYPE_1D_2S, - TYPE_D_LO_HI_2S, - TYPE_1S_POS1 -} TYPE; -static TYPE insn_to_type(Insn& i) { - switch (i.id) { - case MIPS_INS_ADD: - case MIPS_INS_ADDU: - if (i.mnemonic != "add.s" && i.mnemonic != "add.d") { - return TYPE_1D_2S; - } else { - return TYPE_NOP; - } - - case MIPS_INS_ADDI: - case MIPS_INS_ADDIU: - case MIPS_INS_ANDI: - case MIPS_INS_ORI: - case MIPS_INS_LB: - case MIPS_INS_LBU: - case MIPS_INS_LH: - case MIPS_INS_LHU: - case MIPS_INS_LW: - case MIPS_INS_LWL: - //case MIPS_INS_LWR: - case MIPS_INS_MOVE: - case MIPS_INS_NEGU: - case MIPS_INS_NOT: - case MIPS_INS_SLL: - case MIPS_INS_SLTI: - case MIPS_INS_SLTIU: - case MIPS_INS_SRA: - case MIPS_INS_SRL: - case MIPS_INS_XORI: - return TYPE_1D_1S; - - case MIPS_INS_MFHI: - i.operands[1].reg = MIPS_REG_HI; - return TYPE_1D_1S; - - case MIPS_INS_MFLO: - i.operands[1].reg = MIPS_REG_LO; - return TYPE_1D_1S; - - case MIPS_INS_AND: - case MIPS_INS_OR: - case MIPS_INS_NOR: - case MIPS_INS_SLLV: - case MIPS_INS_SLT: - case MIPS_INS_SLTU: - case MIPS_INS_SRAV: - case MIPS_INS_SRLV: - case MIPS_INS_SUBU: - case MIPS_INS_XOR: - return TYPE_1D_2S; - - case MIPS_INS_CFC1: - case MIPS_INS_MFC1: - case MIPS_INS_LI: - case MIPS_INS_LUI: - return TYPE_1D; - - case MIPS_INS_CTC1: - case MIPS_INS_BGEZ: - case MIPS_INS_BGEZL: - case MIPS_INS_BGTZ: - case MIPS_INS_BGTZL: - case MIPS_INS_BLEZ: - case MIPS_INS_BLEZL: - case MIPS_INS_BLTZ: - case MIPS_INS_BLTZL: - case MIPS_INS_BEQZ: - case MIPS_INS_BNEZ: - case MIPS_INS_MTC1: - return TYPE_1S; - - case MIPS_INS_BEQ: - case MIPS_INS_BEQL: - case MIPS_INS_BNE: - case MIPS_INS_BNEL: - case MIPS_INS_SB: - case MIPS_INS_SH: - case MIPS_INS_SW: - case MIPS_INS_SWL: - //case MIPS_INS_SWR: - case MIPS_INS_TNE: - case MIPS_INS_TEQ: - case MIPS_INS_TGE: - case MIPS_INS_TGEU: - case MIPS_INS_TLT: - return TYPE_2S; - - case MIPS_INS_DIV: - if (i.mnemonic != "div.s" && i.mnemonic != "div.d") { - return TYPE_D_LO_HI_2S; - } else { - return TYPE_NOP; - } - - case MIPS_INS_DIVU: - case MIPS_INS_MULT: - case MIPS_INS_MULTU: - return TYPE_D_LO_HI_2S; - - case MIPS_INS_NEG: - if (i.mnemonic != "neg.s" && i.mnemonic != "neg.d") { - return TYPE_1D_1S; - } else { - return TYPE_NOP; - } - - case MIPS_INS_JALR: - return TYPE_1S; - - case MIPS_INS_JR: - if (i.jtbl_addr != 0) { - i.operands[0].reg = i.index_reg; - } - if (i.operands[0].reg == MIPS_REG_RA) { - return TYPE_NOP; - } - return TYPE_1S; - - case MIPS_INS_LWC1: - case MIPS_INS_LDC1: - case MIPS_INS_SWC1: - case MIPS_INS_SDC1: - return TYPE_1S_POS1; - - default: - return TYPE_NOP; - } -} - -static void pass4(void) { - vector q; - uint64_t livein_func_start = 1U | map_reg(MIPS_REG_A0) | map_reg(MIPS_REG_A1) | map_reg(MIPS_REG_SP) | map_reg(MIPS_REG_ZERO); - - q.push_back(main_addr); - insns[addr_to_i(main_addr)].f_livein = livein_func_start; - - for (auto& it : data_function_pointers) { - q.push_back(it.second); - insns[addr_to_i(it.second)].f_livein = livein_func_start | map_reg(MIPS_REG_A2) | map_reg(MIPS_REG_A3); - } - for (auto& addr : li_function_pointers) { - q.push_back(addr); - insns[addr_to_i(addr)].f_livein = livein_func_start | map_reg(MIPS_REG_A2) | map_reg(MIPS_REG_A3); - } - - while (!q.empty()) { - uint32_t addr = q.back(); - q.pop_back(); - uint32_t idx = addr_to_i(addr); - Insn& i = insns[idx]; - uint64_t live = i.f_livein | 1; - switch (insn_to_type(i)) { - case TYPE_1D: - live |= map_reg(i.operands[0].reg); - break; - - case TYPE_1D_1S: - if (live & map_reg(i.operands[1].reg)) { - live |= map_reg(i.operands[0].reg); - } - break; - - case TYPE_1D_2S: - if ((live & map_reg(i.operands[1].reg)) && (live & map_reg(i.operands[2].reg))) { - live |= map_reg(i.operands[0].reg); - } - break; - - case TYPE_D_LO_HI_2S: - if ((live & map_reg(i.operands[0].reg)) && (live & map_reg(i.operands[1].reg))) { - live |= map_reg(MIPS_REG_LO); - live |= map_reg(MIPS_REG_HI); - } - break; - } - if ((i.f_liveout | live) == i.f_liveout) { - // No new bits - continue; - } - live |= i.f_liveout; - i.f_liveout = live; - - bool function_entry = false; - for (Edge& e : i.successors) { - uint64_t new_live = live; - if (e.function_exit) { - new_live &= 1U | map_reg(MIPS_REG_V0) | map_reg(MIPS_REG_V1) | map_reg(MIPS_REG_ZERO); - } else if (e.function_entry) { - new_live &= 1U | map_reg(MIPS_REG_V0) | map_reg(MIPS_REG_A0) | map_reg(MIPS_REG_A1) | - map_reg(MIPS_REG_A2) | map_reg(MIPS_REG_A3) | map_reg(MIPS_REG_SP) | map_reg(MIPS_REG_ZERO); - function_entry = true; - } else if (e.extern_function) { - string name; - bool is_extern_function = false; - size_t extern_function_id; - auto it = symbol_names.find(insns[idx - 1].operands[0].imm); - if (it != symbol_names.end()) { - name = it->second; - for (size_t i = 0; i < sizeof(extern_functions) / sizeof(extern_functions[0]); i++) { - if (name == extern_functions[i].name) { - is_extern_function = true; - extern_function_id = i; - break; - } - } - if (!is_extern_function) { - fprintf(stderr, "missing extern function: %s\n", name.c_str()); - } - } - assert(is_extern_function); - auto& fn = extern_functions[extern_function_id]; - char ret_type = fn.params[0]; - new_live &= ~(map_reg(MIPS_REG_V0) | map_reg(MIPS_REG_A0) | map_reg(MIPS_REG_A1) | - map_reg(MIPS_REG_A2) | map_reg(MIPS_REG_A3) | map_reg(MIPS_REG_V1) | temporary_regs()); - switch (ret_type) { - case 'i': - case 'u': - case 'p': - new_live |= map_reg(MIPS_REG_V0); - break; - case 'f': - break; - case 'd': - break; - case 'v': - break; - case 'l': - case 'j': - new_live |= map_reg(MIPS_REG_V0) | map_reg(MIPS_REG_V1); - break; - } - } else if (e.function_pointer) { - new_live &= ~(map_reg(MIPS_REG_V0) | map_reg(MIPS_REG_A0) | map_reg(MIPS_REG_A1) | - map_reg(MIPS_REG_A2) | map_reg(MIPS_REG_A3) | map_reg(MIPS_REG_V1) | temporary_regs()); - new_live |= map_reg(MIPS_REG_V0) | map_reg(MIPS_REG_V1); - } - if ((insns[e.i].f_livein | new_live) != insns[e.i].f_livein) { - insns[e.i].f_livein |= new_live; - q.push_back(text_vaddr + e.i * 4); - } - } - if (function_entry) { - // add one edge that skips the function call, for callee-saved register liveness propagation - live &= ~(map_reg(MIPS_REG_V0) | map_reg(MIPS_REG_A0) | map_reg(MIPS_REG_A1) | - map_reg(MIPS_REG_A2) | map_reg(MIPS_REG_A3) | map_reg(MIPS_REG_V1) | temporary_regs()); - if ((insns[idx + 1].f_livein | live) != insns[idx + 1].f_livein) { - insns[idx + 1].f_livein |= live; - q.push_back(text_vaddr + (idx + 1) * 4); - } - } - } -} - -static void pass5(void) { - vector q; - - assert(functions.count(main_addr)); - - q = functions[main_addr].returns; - for (auto addr : q) { - insns[addr_to_i(addr)].b_liveout = 1U | map_reg(MIPS_REG_V0); - } - for (auto& it : data_function_pointers) { - for (auto addr : functions[it.second].returns) { - q.push_back(addr); - insns[addr_to_i(addr)].b_liveout = 1U | map_reg(MIPS_REG_V0) | map_reg(MIPS_REG_V1); - } - } - for (auto& func_addr : li_function_pointers) { - for (auto addr : functions[func_addr].returns) { - q.push_back(addr); - insns[addr_to_i(addr)].b_liveout = 1U | map_reg(MIPS_REG_V0) | map_reg(MIPS_REG_V1); - } - } - for (size_t i = 0; i < insns.size(); i++) { - if (insns[i].f_livein != 0) { - // Instruction is reachable - q.push_back(text_vaddr + i * 4); - } - } - - while (!q.empty()) { - uint32_t addr = q.back(); - q.pop_back(); - uint32_t idx = addr_to_i(addr); - Insn& i = insns[idx]; - uint64_t live = i.b_liveout | 1; - switch (insn_to_type(i)) { - case TYPE_1S: - live |= map_reg(i.operands[0].reg); - break; - - case TYPE_1S_POS1: - live |= map_reg(i.operands[1].reg); - break; - - case TYPE_2S: - live |= map_reg(i.operands[0].reg); - live |= map_reg(i.operands[1].reg); - break; - - case TYPE_1D: - live &= ~map_reg(i.operands[0].reg); - break; - - case TYPE_1D_1S: - if (live & map_reg(i.operands[0].reg)) { - live &= ~map_reg(i.operands[0].reg); - live |= map_reg(i.operands[1].reg); - } - break; - - case TYPE_1D_2S: - if (live & map_reg(i.operands[0].reg)) { - live &= ~map_reg(i.operands[0].reg); - live |= map_reg(i.operands[1].reg); - live |= map_reg(i.operands[2].reg); - } - break; - - case TYPE_D_LO_HI_2S: { - bool used = (live & map_reg(MIPS_REG_LO)) || (live & map_reg(MIPS_REG_HI)); - live &= ~map_reg(MIPS_REG_LO); - live &= ~map_reg(MIPS_REG_HI); - if (used) { - live |= map_reg(i.operands[0].reg); - live |= map_reg(i.operands[1].reg); - } - break; - } - } - if ((i.b_livein | live) == i.b_livein) { - // No new bits - continue; - } - live |= i.b_livein; - i.b_livein = live; - - bool function_exit = false; - for (Edge& e : i.predecessors) { - uint64_t new_live = live; - if (e.function_exit) { - new_live &= 1U | map_reg(MIPS_REG_V0) | map_reg(MIPS_REG_V1); - function_exit = true; - } else if (e.function_entry) { - new_live &= 1U | map_reg(MIPS_REG_V0) | map_reg(MIPS_REG_A0) | map_reg(MIPS_REG_A1) | - map_reg(MIPS_REG_A2) | map_reg(MIPS_REG_A3) | map_reg(MIPS_REG_SP); - } else if (e.extern_function) { - string name; - bool is_extern_function = false; - size_t extern_function_id; - auto it = symbol_names.find(insns[idx - 2].operands[0].imm); - if (it != symbol_names.end()) { - name = it->second; - for (size_t i = 0; i < sizeof(extern_functions) / sizeof(extern_functions[0]); i++) { - if (name == extern_functions[i].name) { - is_extern_function = true; - extern_function_id = i; - break; - } - } - } - assert(is_extern_function); - auto& fn = extern_functions[extern_function_id]; - uint64_t args = 1U; - if (fn.flags & FLAG_VARARG) { - // Assume the worst, that all four registers are used - for (int j = 0; j < 4; j++) { - args |= map_reg(MIPS_REG_A0 + j); - } - } - int pos = 0; - int pos_float = 0; - bool only_floats_so_far = true; - for (const char *p = fn.params + 1; *p != '\0'; ++p) { - switch (*p) { - case 'i': - case 'u': - case 'p': - case 't': - only_floats_so_far = false; - if (pos < 4) { - args |= map_reg(MIPS_REG_A0 + pos); - } - ++pos; - break; - case 'f': - if (only_floats_so_far && pos_float < 4) { - pos_float += 2; - } else if (pos < 4) { - args |= map_reg(MIPS_REG_A0 + pos); - } - ++pos; - break; - case 'd': - if (pos % 1 != 0) { - ++pos; - } - if (only_floats_so_far && pos_float < 4) { - pos_float += 2; - } else if (pos < 4) { - args |= map_reg(MIPS_REG_A0 + pos) | map_reg(MIPS_REG_A0 + pos + 1); - } - pos += 2; - break; - case 'l': - case 'j': - if (pos % 1 != 0) { - ++pos; - } - only_floats_so_far = false; - if (pos < 4) { - args |= map_reg(MIPS_REG_A0 + pos) | map_reg(MIPS_REG_A0 + pos + 1); - } - pos += 2; - break; - } - } - args |= map_reg(MIPS_REG_SP); - new_live &= ~(map_reg(MIPS_REG_V0) | map_reg(MIPS_REG_A0) | map_reg(MIPS_REG_A1) | - map_reg(MIPS_REG_A2) | map_reg(MIPS_REG_A3) | map_reg(MIPS_REG_V1) | temporary_regs()); - new_live |= args; - } else if (e.function_pointer) { - new_live &= ~(map_reg(MIPS_REG_V0) | map_reg(MIPS_REG_A0) | map_reg(MIPS_REG_A1) | - map_reg(MIPS_REG_A2) | map_reg(MIPS_REG_A3) | map_reg(MIPS_REG_V1) | temporary_regs()); - new_live |= map_reg(MIPS_REG_A0) | map_reg(MIPS_REG_A1) | map_reg(MIPS_REG_A2) | map_reg(MIPS_REG_A3); - } - if ((insns[e.i].b_liveout | new_live) != insns[e.i].b_liveout) { - insns[e.i].b_liveout |= new_live; - q.push_back(text_vaddr + e.i * 4); - } - } - if (function_exit) { - // add one edge that skips the function call, for callee-saved register liveness propagation - live &= ~(map_reg(MIPS_REG_V0) | map_reg(MIPS_REG_A0) | map_reg(MIPS_REG_A1) | - map_reg(MIPS_REG_A2) | map_reg(MIPS_REG_A3) | map_reg(MIPS_REG_V1) | temporary_regs()); - if ((insns[idx - 1].b_liveout | live) != insns[idx - 1].b_liveout) { - insns[idx - 1].b_liveout |= live; - q.push_back(text_vaddr + (idx - 1) * 4); - } - } - } -} - -static void pass6(void) { - for (auto& it : functions) { - uint32_t addr = it.first; - Function& f = it.second; - for (uint32_t ret : f.returns) { - Insn& i = insns[addr_to_i(ret)]; - if (i.f_liveout & i.b_liveout & map_reg(MIPS_REG_V1)) { - f.nret = 2; - } else if ((i.f_liveout & i.b_liveout & map_reg(MIPS_REG_V0)) && f.nret == 0) { - f.nret = 1; - } - } - Insn& insn = insns.at(addr_to_i(addr)); - for (int i = 0; i < 4; i++) { - if (insn.f_livein & insn.b_livein & map_reg(MIPS_REG_A0 + i)) { - f.nargs = 1 + i; - } - } - f.v0_in = (insn.f_livein & insn.b_livein & map_reg(MIPS_REG_V0)) != 0 && !f.referenced_by_function_pointer; - } -} - -static void dump(void) { - for (size_t i = 0; i < insns.size(); i++) { - Insn& insn = insns[i]; - uint32_t vaddr = text_vaddr + i * 4; - if (label_addresses.count(vaddr)) { - if (symbol_names.count(vaddr)) { - printf("L%08x: //%s\n", vaddr, symbol_names[vaddr].c_str()); - } else { - printf("L%08x:\n", vaddr); - } - } - printf("\t%s %s\n", insn.mnemonic.c_str(), insn.op_str.c_str()); - } -} - -static const char *r(uint32_t reg) { - return cs_reg_name(handle, reg); -} - -static const char *wr(uint32_t reg) { - static const char *regs[] = { - "f0.w[0]", "f0.w[1]", - "f2.w[0]", "f2.w[1]", - "f4.w[0]", "f4.w[1]", - "f6.w[0]", "f6.w[1]", - "f8.w[0]", "f8.w[1]", - "f10.w[0]", "f10.w[1]", - "f12.w[0]", "f12.w[1]", - "f14.w[0]", "f14.w[1]", - "f16.w[0]", "f16.w[1]", - "f18.w[0]", "f18.w[1]", - "f20.w[0]", "f20.w[1]", - "f22.w[0]", "f22.w[1]", - "f24.w[0]", "f24.w[1]", - "f26.w[0]", "f26.w[1]", - "f28.w[0]", "f28.w[1]", - "f30.w[0]", "f30.w[1]" - }; - assert(reg >= MIPS_REG_F0 && reg <= MIPS_REG_F31); - return regs[reg - MIPS_REG_F0]; -} - -static const char *fr(uint32_t reg) { - static const char *regs[] = { - "f0.f[0]", "f0.f[1]", - "f2.f[0]", "f2.f[1]", - "f4.f[0]", "f4.f[1]", - "f6.f[0]", "f6.f[1]", - "f8.f[0]", "f8.f[1]", - "f10.f[0]", "f10.f[1]", - "f12.f[0]", "f12.f[1]", - "f14.f[0]", "f14.f[1]", - "f16.f[0]", "f16.f[1]", - "f18.f[0]", "f18.f[1]", - "f20.f[0]", "f20.f[1]", - "f22.f[0]", "f22.f[1]", - "f24.f[0]", "f24.f[1]", - "f26.f[0]", "f26.f[1]", - "f28.f[0]", "f28.f[1]", - "f30.f[0]", "f30.f[1]" - }; - assert(reg >= MIPS_REG_F0 && reg <= MIPS_REG_F31); - return regs[reg - MIPS_REG_F0]; -} - -static const char *dr(uint32_t reg) { - static const char *regs[] = { - "f0.d", - "f2.d", - "f4.d", - "f6.d", - "f8.d", - "f10.d", - "f12.d", - "f14.d", - "f16.d", - "f18.d", - "f20.d", - "f22.d", - "f24.d", - "f26.d", - "f28.d", - "f30.d" - }; - assert(reg >= MIPS_REG_F0 && reg <= MIPS_REG_F31 && (reg - MIPS_REG_F0) % 2 == 0); - return regs[(reg - MIPS_REG_F0) / 2]; -} - -static void dump_instr(int i); - -static void dump_cond_branch(int i, const char *lhs, const char *op, const char *rhs) { - Insn& insn = insns[i]; - const char *cast1 = ""; - const char *cast2 = ""; - if (strcmp(op, "==") && strcmp(op, "!=")) { - cast1 = "(int)"; - if (strcmp(rhs, "0")) { - cast2 = "(int)"; - } - } - printf("if (%s%s %s %s%s) {", cast1, lhs, op, cast2, rhs); - dump_instr(i + 1); - printf("goto L%x;}\n", (uint32_t)insn.operands[insn.op_count - 1].imm); -} - -static void dump_cond_branch_likely(int i, const char *lhs, const char *op, const char *rhs) { - uint32_t target = text_vaddr + (i + 2) * 4; - dump_cond_branch(i, lhs, op, rhs); - if (!TRACE) { - printf("else goto L%x;\n", target); - } else { - printf("else {printf(\"pc=0x%08x (ignored)\\n\"); goto L%x;}\n", text_vaddr + (i + 1) * 4, target); - } - label_addresses.insert(target); -} - -static void dump_instr(int i) { - const char *symbol_name = NULL; - if (symbol_names.count(text_vaddr + i * 4) != 0) { - symbol_name = symbol_names[text_vaddr + i * 4].c_str(); - printf("//%s:\n", symbol_name); - } - if (TRACE) { - printf("++cnt; printf(\"pc=0x%08x%s%s\\n\"); ", text_vaddr + i * 4, symbol_name ? " " : "", symbol_name ? symbol_name : ""); - } - Insn& insn = insns[i]; - if (!insn.is_jump && !conservative) { - switch (insn_to_type(insn)) { - case TYPE_1S: - if (!(insn.f_livein & map_reg(insn.operands[0].reg))) { - printf("// fdead %llx ", (unsigned long long)insn.f_livein); - } - break; - case TYPE_1S_POS1: - if (!(insn.f_livein & map_reg(insn.operands[1].reg))) { - printf("// fdead %llx ", (unsigned long long)insn.f_livein); - } - break; - case TYPE_2S: - if (!(insn.f_livein & map_reg(insn.operands[0].reg)) || !(insn.f_livein & map_reg(insn.operands[1].reg))) { - printf("// fdead %llx ", (unsigned long long)insn.f_livein); - } - break; - case TYPE_1D_2S: - if (!(insn.f_livein & map_reg(insn.operands[2].reg))) { - printf("// fdead %llx ", (unsigned long long)insn.f_livein); - break; - } - // fallthrough - case TYPE_1D_1S: - if (!(insn.f_livein & map_reg(insn.operands[1].reg))) { - printf("// fdead %llx ", (unsigned long long)insn.f_livein); - break; - } - // fallthrough - case TYPE_1D: - if (!(insn.b_liveout & map_reg(insn.operands[0].reg))) { - printf("// bdead %llx ", (unsigned long long)insn.b_liveout); - } - break; - case TYPE_D_LO_HI_2S: - if (!(insn.f_livein & map_reg(insn.operands[0].reg)) || !(insn.f_livein & map_reg(insn.operands[1].reg))) { - printf("// fdead %llx ", (unsigned long long)insn.f_livein); - break; - } - if (!(insn.b_liveout & (map_reg(MIPS_REG_LO) | map_reg(MIPS_REG_HI)))) { - printf("// bdead %llx ", (unsigned long long)insn.b_liveout); - } - break; - } - } - switch (insn.id) { - case MIPS_INS_ADD: - case MIPS_INS_ADDU: - if (insn.mnemonic == "add.s") { - printf("%s = %s + %s;\n", fr(insn.operands[0].reg), fr(insn.operands[1].reg), fr(insn.operands[2].reg)); - } else if (insn.mnemonic == "add.d") { - printf("%s = %s + %s;\n", dr(insn.operands[0].reg), dr(insn.operands[1].reg), dr(insn.operands[2].reg)); - } else { - printf("%s = %s + %s;\n", r(insn.operands[0].reg), r(insn.operands[1].reg), r(insn.operands[2].reg)); - } - break; - case MIPS_INS_ADDI: - case MIPS_INS_ADDIU: - printf("%s = %s + 0x%x;\n", r(insn.operands[0].reg), r(insn.operands[1].reg), (uint32_t)insn.operands[2].imm); - break; - case MIPS_INS_AND: - printf("%s = %s & %s;\n", r(insn.operands[0].reg), r(insn.operands[1].reg), r(insn.operands[2].reg)); - break; - case MIPS_INS_ANDI: - printf("%s = %s & 0x%x;\n", r(insn.operands[0].reg), r(insn.operands[1].reg), (uint32_t)insn.operands[2].imm); - break; - case MIPS_INS_BEQ: - dump_cond_branch(i, r(insn.operands[0].reg), "==", r(insn.operands[1].reg)); - break; - case MIPS_INS_BEQL: - dump_cond_branch_likely(i, r(insn.operands[0].reg), "==", r(insn.operands[1].reg)); - break; - case MIPS_INS_BGEZ: - dump_cond_branch(i, r(insn.operands[0].reg), ">=", "0"); - break; - case MIPS_INS_BGEZL: - dump_cond_branch_likely(i, r(insn.operands[0].reg), ">=", "0"); - break; - case MIPS_INS_BGTZ: - dump_cond_branch(i, r(insn.operands[0].reg), ">", "0"); - break; - case MIPS_INS_BGTZL: - dump_cond_branch_likely(i, r(insn.operands[0].reg), ">", "0"); - break; - case MIPS_INS_BLEZ: - dump_cond_branch(i, r(insn.operands[0].reg), "<=", "0"); - break; - case MIPS_INS_BLEZL: - dump_cond_branch_likely(i, r(insn.operands[0].reg), "<=", "0"); - break; - case MIPS_INS_BLTZ: - dump_cond_branch(i, r(insn.operands[0].reg), "<", "0"); - break; - case MIPS_INS_BLTZL: - dump_cond_branch_likely(i, r(insn.operands[0].reg), "<", "0"); - break; - case MIPS_INS_BNE: - dump_cond_branch(i, r(insn.operands[0].reg), "!=", r(insn.operands[1].reg)); - break; - case MIPS_INS_BNEL: - dump_cond_branch_likely(i, r(insn.operands[0].reg), "!=", insn.mnemonic == "bnezl" ? "0" : r(insn.operands[1].reg)); - break; - case MIPS_INS_BREAK: - printf("abort();\n"); - break; - case MIPS_INS_BEQZ: - dump_cond_branch(i, r(insn.operands[0].reg), "==", "0"); - break; - /*case MIPS_INS_BEQZL: - dump_cond_branch_likely(i, r(insn.operands[0].reg), "==", "0"); - break;*/ - case MIPS_INS_B: - dump_instr(i + 1); - printf("goto L%x;\n", (int32_t)insn.operands[0].imm); - break; - case MIPS_INS_BC1F: - case MIPS_INS_BC1T: - printf("if (%scf) {", insn.id == MIPS_INS_BC1F ? "!" : ""); - dump_instr(i + 1); - printf("goto L%x;}\n", (int32_t)insn.operands[0].imm); - break; - case MIPS_INS_BC1FL: - case MIPS_INS_BC1TL: - { - uint32_t target = text_vaddr + (i + 2) * 4; - printf("if (%scf) {", insn.id == MIPS_INS_BC1FL ? "!" : ""); - dump_instr(i + 1); - printf("goto L%x;}\n", (int32_t)insn.operands[0].imm); - if (!TRACE) { - printf("else goto L%x;\n", target); - } else { - printf("else {printf(\"pc=0x%08x (ignored)\\n\"); goto L%x;}\n", text_vaddr + (i + 1) * 4, target); - } - label_addresses.insert(target); - break; - } - case MIPS_INS_BNEZ: - dump_cond_branch(i, r(insn.operands[0].reg), "!=", "0"); - break; - /*case MIPS_INS_BNEZL: - dump_cond_branch_likely(i, r(insn.operands[0].reg), "!=", "0"); - break;*/ - case MIPS_INS_C: - if (insn.mnemonic == "c.lt.s") { - printf("cf = %s < %s;\n", fr(insn.operands[0].reg), fr(insn.operands[1].reg)); - } else if (insn.mnemonic == "c.le.s") { - printf("cf = %s <= %s;\n", fr(insn.operands[0].reg), fr(insn.operands[1].reg)); - } else if (insn.mnemonic == "c.eq.s") { - printf("cf = %s == %s;\n", fr(insn.operands[0].reg), fr(insn.operands[1].reg)); - } else if (insn.mnemonic == "c.lt.d") { - printf("cf = %s < %s;\n", dr(insn.operands[0].reg), dr(insn.operands[1].reg)); - } else if (insn.mnemonic == "c.le.d") { - printf("cf = %s <= %s;\n", dr(insn.operands[0].reg), dr(insn.operands[1].reg)); - } else if (insn.mnemonic == "c.eq.d") { - printf("cf = %s == %s;\n", dr(insn.operands[0].reg), dr(insn.operands[1].reg)); - } - break; - case MIPS_INS_CVT: - if (insn.mnemonic == "cvt.s.w") { - printf("%s = (int)%s;\n", fr(insn.operands[0].reg), wr(insn.operands[1].reg)); - } else if (insn.mnemonic == "cvt.d.w") { - printf("%s = (int)%s;\n", dr(insn.operands[0].reg), wr(insn.operands[1].reg)); - } else if (insn.mnemonic == "cvt.d.s") { - printf("%s = %s;\n", dr(insn.operands[0].reg), fr(insn.operands[1].reg)); - } else if (insn.mnemonic == "cvt.s.d") { - printf("%s = %s;\n", fr(insn.operands[0].reg), dr(insn.operands[1].reg)); - } else if (insn.mnemonic == "cvt.w.d") { - printf("%s = cvt_w_d(%s);\n", wr(insn.operands[0].reg), dr(insn.operands[1].reg)); - } else if (insn.mnemonic == "cvt.w.s") { - printf("%s = cvt_w_s(%s);\n", wr(insn.operands[0].reg), fr(insn.operands[1].reg)); - } else { - goto unimplemented; - } - break; - case MIPS_INS_CFC1: - assert(insn.operands[1].reg == MIPS_REG_31); - printf("%s = fcsr;\n", r(insn.operands[0].reg)); - break; - case MIPS_INS_CTC1: - assert(insn.operands[1].reg == MIPS_REG_31); - printf("fcsr = %s;\n", r(insn.operands[0].reg)); - break; - case MIPS_INS_DIV: - if (insn.mnemonic == "div.s") { - assert(insn.op_count == 3); - printf("%s = %s / %s;\n", fr(insn.operands[0].reg), fr(insn.operands[1].reg), fr(insn.operands[2].reg)); - } else if (insn.mnemonic == "div.d") { - assert(insn.op_count == 3); - printf("%s = %s / %s;\n", dr(insn.operands[0].reg), dr(insn.operands[1].reg), dr(insn.operands[2].reg)); - } else { - assert(insn.op_count == 2); - printf("lo = (int)%s / (int)%s; ", r(insn.operands[0].reg), r(insn.operands[1].reg)); - printf("hi = (int)%s %% (int)%s;\n", r(insn.operands[0].reg), r(insn.operands[1].reg)); - } - break; - case MIPS_INS_DIVU: - assert(insn.op_count == 2); - printf("lo = %s / %s; ", r(insn.operands[0].reg), r(insn.operands[1].reg)); - printf("hi = %s %% %s;\n", r(insn.operands[0].reg), r(insn.operands[1].reg)); - break; - case MIPS_INS_MOV: - if (insn.mnemonic == "mov.s") { - printf("%s = %s;\n", fr(insn.operands[0].reg), fr(insn.operands[1].reg)); - } else if (insn.mnemonic == "mov.d") { - printf("%s = %s;\n", dr(insn.operands[0].reg), dr(insn.operands[1].reg)); - } else { - goto unimplemented; - } - break; - case MIPS_INS_MUL: - if (insn.mnemonic == "mul.s") { - printf("%s = %s * %s;\n", fr(insn.operands[0].reg), fr(insn.operands[1].reg), fr(insn.operands[2].reg)); - } else if (insn.mnemonic == "mul.d") { - printf("%s = %s * %s;\n", dr(insn.operands[0].reg), dr(insn.operands[1].reg), dr(insn.operands[2].reg)); - } else { - goto unimplemented; - } - break; - case MIPS_INS_NEG: - if (insn.mnemonic == "neg.s") { - printf("%s = -%s;\n", fr(insn.operands[0].reg), fr(insn.operands[1].reg)); - } else if (insn.mnemonic == "neg.d") { - printf("%s = -%s;\n", dr(insn.operands[0].reg), dr(insn.operands[1].reg)); - } else { - printf("%s = -%s;\n", r(insn.operands[0].reg), r(insn.operands[1].reg)); - } - break; - case MIPS_INS_SUB: - if (insn.mnemonic == "sub.s") { - printf("%s = %s - %s;\n", fr(insn.operands[0].reg), fr(insn.operands[1].reg), fr(insn.operands[2].reg)); - } else if (insn.mnemonic == "sub.d") { - printf("%s = %s - %s;\n", dr(insn.operands[0].reg), dr(insn.operands[1].reg), dr(insn.operands[2].reg)); - } else { - goto unimplemented; - } - break; - case MIPS_INS_J: - dump_instr(i + 1); - printf("goto L%x;\n", (uint32_t)insn.operands[0].imm); - break; - case MIPS_INS_JAL: - { - string name; - bool is_extern_function = false; - size_t extern_function_id; - auto it = symbol_names.find(insn.operands[0].imm); - if (it != symbol_names.end()) { - name = it->second; - for (size_t i = 0; i < sizeof(extern_functions) / sizeof(extern_functions[0]); i++) { - if (name == extern_functions[i].name) { - is_extern_function = true; - extern_function_id = i; - break; - } - } - } - dump_instr(i + 1); - if (is_extern_function) { - auto& fn = extern_functions[extern_function_id]; - if (fn.flags & FLAG_VARARG) { - for (int j = 0; j < 4; j++) { - printf("MEM_U32(sp + %d) = %s;\n", j * 4, r(MIPS_REG_A0 + j)); - } - } - char ret_type = fn.params[0]; - if (ret_type != 'v') { - switch (ret_type) { - case 'i': - case 'u': - case 'p': - printf("%s = ", r(MIPS_REG_V0)); - break; - case 'f': - printf("%s = ", fr(MIPS_REG_F0)); - break; - case 'd': - printf("%s = ", dr(MIPS_REG_F0)); - break; - case 'l': - case 'j': - printf("temp64 = "); - break; - } - } - printf("wrapper_%s(", name.c_str()); - bool first = true; - if (!(fn.flags & FLAG_NO_MEM)) { - printf("mem"); - first = false; - } - int pos = 0; - int pos_float = 0; - bool only_floats_so_far = true; - bool needs_sp = false; - for (const char *p = fn.params + 1; *p != '\0'; ++p) { - if (!first) { - printf(", "); - } - first = false; - switch (*p) { - case 't': - printf("trampoline, "); - needs_sp = true; - // fallthrough - case 'i': - case 'u': - case 'p': - only_floats_so_far = false; - if (pos < 4) { - printf("%s", r(MIPS_REG_A0 + pos)); - } else { - printf("MEM_%c32(sp + %d)", *p == 'i' ? 'S' : 'U', pos * 4); - } - ++pos; - break; - case 'f': - if (only_floats_so_far && pos_float < 4) { - printf("%s", fr(MIPS_REG_F12 + pos_float)); - pos_float += 2; - } else if (pos < 4) { - printf("BITCAST_U32_TO_F32(%s)", r(MIPS_REG_A0 + pos)); - } else { - printf("BITCAST_U32_TO_F32(MEM_U32(sp + %d))", pos * 4); - } - ++pos; - break; - case 'd': - if (pos % 1 != 0) { - ++pos; - } - if (only_floats_so_far && pos_float < 4) { - printf("%s", dr(MIPS_REG_F12 + pos_float)); - pos_float += 2; - } else if (pos < 4) { - printf("BITCAST_U64_TO_F64(((uint64_t)%s << 32) | (uint64_t)%s)", r(MIPS_REG_A0 + pos), r(MIPS_REG_A0 + pos + 1)); - } else { - printf("BITCAST_U64_TO_F64(((uint64_t)MEM_U32(sp + %d) << 32) | (uint64_t)MEM_U32(sp + %d))", pos * 4, (pos + 1) * 4); - } - pos += 2; - break; - case 'l': - case 'j': - if (pos % 1 != 0) { - ++pos; - } - only_floats_so_far = false; - if (*p == 'l') { - printf("(int64_t)"); - } - if (pos < 4) { - printf("(((uint64_t)%s << 32) | (uint64_t)%s)", r(MIPS_REG_A0 + pos), r(MIPS_REG_A0 + pos + 1)); - } else { - printf("(((uint64_t)MEM_U32(sp + %d) << 32) | (uint64_t)MEM_U32(sp + %d))", pos * 4, (pos + 1) * 4); - } - pos += 2; - break; - } - } - if ((fn.flags & FLAG_VARARG) || needs_sp) { - printf("%s%s", first ? "" : ", ", r(MIPS_REG_SP)); - } - printf(");\n"); - if (ret_type == 'l' || ret_type == 'j') { - printf("%s = (uint32_t)(temp64 >> 32);\n", r(MIPS_REG_V0)); - printf("%s = (uint32_t)temp64;\n", r(MIPS_REG_V1)); - } - if (!name.empty()) { - //printf("printf(\"%s %%x\\n\", %s);\n", name.c_str(), r(MIPS_REG_A0)); - } - } else { - Function& f = functions.find((uint32_t)insn.operands[0].imm)->second; - if (f.nret == 1) { - printf("v0 = "); - } else if (f.nret == 2) { - printf("temp64 = "); - } - if (!name.empty()) { - //printf("printf(\"%s %%x\\n\", %s);\n", name.c_str(), r(MIPS_REG_A0)); - printf("f_%s", name.c_str()); - } else { - printf("func_%x", (uint32_t)insn.operands[0].imm); - } - printf("(mem, sp"); - if (f.v0_in) { - printf(", %s", r(MIPS_REG_V0)); - } - for (uint32_t i = 0; i < f.nargs; i++) { - printf(", %s", r(MIPS_REG_A0 + i)); - } - printf(");\n"); - if (f.nret == 2) { - printf("%s = (uint32_t)(temp64 >> 32);\n", r(MIPS_REG_V0)); - printf("%s = (uint32_t)temp64;\n", r(MIPS_REG_V1)); - } - } - printf("goto L%x;\n", text_vaddr + (i + 2) * 4); - label_addresses.insert(text_vaddr + (i + 2) * 4); - break; - } - case MIPS_INS_JALR: - printf("fp_dest = %s;\n", r(insn.operands[0].reg)); - dump_instr(i + 1); - printf("temp64 = trampoline(mem, sp, %s, %s, %s, %s, fp_dest);\n", - r(MIPS_REG_A0), r(MIPS_REG_A1), r(MIPS_REG_A2), r(MIPS_REG_A3)); - printf("%s = (uint32_t)(temp64 >> 32);\n", r(MIPS_REG_V0)); - printf("%s = (uint32_t)temp64;\n", r(MIPS_REG_V1)); - printf("goto L%x;\n", text_vaddr + (i + 2) * 4); - label_addresses.insert(text_vaddr + (i + 2) * 4); - break; - case MIPS_INS_JR: - if (insn.jtbl_addr != 0) { - uint32_t jtbl_pos = insn.jtbl_addr - rodata_vaddr; - assert(jtbl_pos < rodata_section_len && jtbl_pos + insn.num_cases * 4 <= rodata_section_len); -#if 1 - printf(";static void *const Lswitch%x[] = {\n", insn.jtbl_addr); - for (uint32_t i = 0; i < insn.num_cases; i++) { - uint32_t dest_addr = read_u32_be(rodata_section + jtbl_pos + i * 4) + gp_value; - printf("&&L%x,\n", dest_addr); - label_addresses.insert(dest_addr); - } - printf("};\n"); - printf("dest = Lswitch%x[%s];\n", insn.jtbl_addr, r(insn.index_reg)); - dump_instr(i + 1); - printf("goto *dest;\n"); -#else - assert(insns[i + 1].id == MIPS_INS_NOP); - printf("switch (%s) {\n", r(insn.index_reg)); - for (uint32_t i = 0; i < insn.num_cases; i++) { - uint32_t dest_addr = read_u32_be(rodata_section + jtbl_pos + i * 4) + gp_value; - printf("case %u: goto L%x;\n", i, dest_addr); - label_addresses.insert(dest_addr); - } - printf("}\n"); -#endif - } else { - if (insn.operands[0].reg != MIPS_REG_RA) { - printf("UNSUPPORTED JR %s %s\n", insn.op_str.c_str(), r(insn.operands[0].reg)); - } else { - dump_instr(i + 1); - switch (find_function(text_vaddr + i * 4)->second.nret) { - case 0: - printf("return;\n"); - break; - case 1: - printf("return v0;\n"); - break; - case 2: - printf("return ((uint64_t)v0 << 32) | v1;\n"); - break; - } - } - } - break; - case MIPS_INS_LB: - printf("%s = MEM_S8(%s + %d);\n", r(insn.operands[0].reg), r(insn.operands[1].mem.base), (int)insn.operands[1].mem.disp); - break; - case MIPS_INS_LBU: - printf("%s = MEM_U8(%s + %d);\n", r(insn.operands[0].reg), r(insn.operands[1].mem.base), (int)insn.operands[1].mem.disp); - break; - case MIPS_INS_LH: - printf("%s = MEM_S16(%s + %d);\n", r(insn.operands[0].reg), r(insn.operands[1].mem.base), (int)insn.operands[1].mem.disp); - break; - case MIPS_INS_LHU: - printf("%s = MEM_U16(%s + %d);\n", r(insn.operands[0].reg), r(insn.operands[1].mem.base), (int)insn.operands[1].mem.disp); - break; - case MIPS_INS_LUI: - printf("%s = 0x%x;\n", r(insn.operands[0].reg), ((uint32_t)insn.operands[1].imm) << 16); - break; - case MIPS_INS_LW: - printf("%s = MEM_U32(%s + %d);\n", r(insn.operands[0].reg), r(insn.operands[1].mem.base), (int)insn.operands[1].mem.disp); - break; - case MIPS_INS_LWC1: - printf("%s = MEM_U32(%s + %d);\n", wr(insn.operands[0].reg), r(insn.operands[1].mem.base), (int)insn.operands[1].mem.disp); - break; - case MIPS_INS_LDC1: - assert((insn.operands[0].reg - MIPS_REG_F0) % 2 == 0); - printf("%s = MEM_U32(%s + %d);\n", wr(insn.operands[0].reg + 1), r(insn.operands[1].mem.base), (int)insn.operands[1].mem.disp); - printf("%s = MEM_U32(%s + %d + 4);\n", wr(insn.operands[0].reg), r(insn.operands[1].mem.base), (int)insn.operands[1].mem.disp); - break; - case MIPS_INS_LWL: - { - const char *reg = r(insn.operands[0].reg); - printf("%s = %s + %d; ", reg, r(insn.operands[1].mem.base), (int)insn.operands[1].mem.disp); - printf("%s = (MEM_U8(%s) << 24) | (MEM_U8(%s + 1) << 16) | (MEM_U8(%s + 2) << 8) | MEM_U8(%s + 3);\n", reg, reg, reg, reg, reg); - break; - } - case MIPS_INS_LWR: - printf("//lwr %s\n", insn.op_str.c_str()); - break; - case MIPS_INS_LI: - if (insn.is_global_got_memop && text_vaddr <= insn.operands[1].imm && insn.operands[1].imm < text_vaddr + text_section_len) { - printf("%s = 0x%x; // function pointer\n", r(insn.operands[0].reg), (uint32_t)insn.operands[1].imm); - label_addresses.insert((uint32_t)insn.operands[1].imm); - } else { - printf("%s = 0x%x;\n", r(insn.operands[0].reg), (uint32_t)insn.operands[1].imm); - } - break; - case MIPS_INS_MFC1: - printf("%s = %s;\n", r(insn.operands[0].reg), wr(insn.operands[1].reg)); - break; - case MIPS_INS_MFHI: - printf("%s = hi;\n", r(insn.operands[0].reg)); - break; - case MIPS_INS_MFLO: - printf("%s = lo;\n", r(insn.operands[0].reg)); - break; - case MIPS_INS_MOVE: - printf("%s = %s;\n", r(insn.operands[0].reg), r(insn.operands[1].reg)); - break; - case MIPS_INS_MTC1: - printf("%s = %s;\n", wr(insn.operands[1].reg), r(insn.operands[0].reg)); - break; - case MIPS_INS_MULT: - printf("lo = %s * %s;\n", r(insn.operands[0].reg), r(insn.operands[1].reg)); - printf("hi = (uint32_t)((int64_t)(int)%s * (int64_t)(int)%s >> 32);\n", r(insn.operands[0].reg), r(insn.operands[1].reg)); - break; - case MIPS_INS_MULTU: - printf("lo = %s * %s;\n", r(insn.operands[0].reg), r(insn.operands[1].reg)); - printf("hi = (uint32_t)((uint64_t)%s * (uint64_t)%s >> 32);\n", r(insn.operands[0].reg), r(insn.operands[1].reg)); - break; - case MIPS_INS_NEGU: - printf("%s = -%s;\n", r(insn.operands[0].reg), r(insn.operands[1].reg)); - break; - case MIPS_INS_NOR: - printf("%s = ~(%s | %s);\n", r(insn.operands[0].reg), r(insn.operands[1].reg), r(insn.operands[2].reg)); - break; - case MIPS_INS_NOT: - printf("%s = ~%s;\n", r(insn.operands[0].reg), r(insn.operands[1].reg)); - break; - case MIPS_INS_OR: - printf("%s = %s | %s;\n", r(insn.operands[0].reg), r(insn.operands[1].reg), r(insn.operands[2].reg)); - break; - case MIPS_INS_ORI: - printf("%s = %s | 0x%x;\n", r(insn.operands[0].reg), r(insn.operands[1].reg), (uint32_t)insn.operands[2].imm); - break; - case MIPS_INS_SB: - printf("MEM_U8(%s + %d) = (uint8_t)%s;\n", r(insn.operands[1].mem.base), (int)insn.operands[1].mem.disp, r(insn.operands[0].reg)); - break; - case MIPS_INS_SH: - printf("MEM_U16(%s + %d) = (uint16_t)%s;\n", r(insn.operands[1].mem.base), (int)insn.operands[1].mem.disp, r(insn.operands[0].reg)); - break; - case MIPS_INS_SLL: - printf("%s = %s << %d;\n", r(insn.operands[0].reg), r(insn.operands[1].reg), (uint32_t)insn.operands[2].imm); - break; - case MIPS_INS_SLLV: - printf("%s = %s << (%s & 0x1f);\n", r(insn.operands[0].reg), r(insn.operands[1].reg), r(insn.operands[2].reg)); - break; - case MIPS_INS_SLT: - printf("%s = (int)%s < (int)%s;\n", r(insn.operands[0].reg), r(insn.operands[1].reg), r(insn.operands[2].reg)); - break; - case MIPS_INS_SLTI: - printf("%s = (int)%s < (int)0x%x;\n", r(insn.operands[0].reg), r(insn.operands[1].reg), (uint32_t)insn.operands[2].imm); - break; - case MIPS_INS_SLTIU: - printf("%s = %s < 0x%x;\n", r(insn.operands[0].reg), r(insn.operands[1].reg), (uint32_t)insn.operands[2].imm); - break; - case MIPS_INS_SLTU: - printf("%s = %s < %s;\n", r(insn.operands[0].reg), r(insn.operands[1].reg), r(insn.operands[2].reg)); - break; - case MIPS_INS_SRA: - printf("%s = (int)%s >> %d;\n", r(insn.operands[0].reg), r(insn.operands[1].reg), (uint32_t)insn.operands[2].imm); - break; - case MIPS_INS_SRAV: - printf("%s = (int)%s >> (%s & 0x1f);\n", r(insn.operands[0].reg), r(insn.operands[1].reg), r(insn.operands[2].reg)); - break; - case MIPS_INS_SRL: - printf("%s = %s >> %d;\n", r(insn.operands[0].reg), r(insn.operands[1].reg), (uint32_t)insn.operands[2].imm); - break; - case MIPS_INS_SRLV: - printf("%s = %s >> (%s & 0x1f);\n", r(insn.operands[0].reg), r(insn.operands[1].reg), r(insn.operands[2].reg)); - break; - case MIPS_INS_SUBU: - printf("%s = %s - %s;\n", r(insn.operands[0].reg), r(insn.operands[1].reg), r(insn.operands[2].reg)); - break; - case MIPS_INS_SW: - printf("MEM_U32(%s + %d) = %s;\n", r(insn.operands[1].mem.base), (int)insn.operands[1].mem.disp, r(insn.operands[0].reg)); - break; - case MIPS_INS_SWC1: - printf("MEM_U32(%s + %d) = %s;\n", r(insn.operands[1].mem.base), (int)insn.operands[1].mem.disp, wr(insn.operands[0].reg)); - break; - case MIPS_INS_SDC1: - assert((insn.operands[0].reg - MIPS_REG_F0) % 2 == 0); - printf("MEM_U32(%s + %d) = %s;\n", r(insn.operands[1].mem.base), (int)insn.operands[1].mem.disp, wr(insn.operands[0].reg + 1)); - printf("MEM_U32(%s + %d + 4) = %s;\n", r(insn.operands[1].mem.base), (int)insn.operands[1].mem.disp, wr(insn.operands[0].reg)); - break; - case MIPS_INS_SWL: - for (int i = 0; i < 4; i++) { - printf("MEM_U8(%s + %d + %d) = (uint8_t)(%s >> %d);\n", r(insn.operands[1].mem.base), (int)insn.operands[1].mem.disp, i, r(insn.operands[0].reg), (3 - i) * 8); - } - break; - case MIPS_INS_SWR: - printf("//swr %s\n", insn.op_str.c_str()); - break; - case MIPS_INS_TRUNC: - if (insn.mnemonic == "trunc.w.s") { - printf("%s = (int)%s;\n", wr(insn.operands[0].reg), fr(insn.operands[1].reg)); - } else if (insn.mnemonic == "trunc.w.d") { - printf("%s = (int)%s;\n", wr(insn.operands[0].reg), dr(insn.operands[1].reg)); - } else { - goto unimplemented; - } - break; - case MIPS_INS_XOR: - printf("%s = %s ^ %s;\n", r(insn.operands[0].reg), r(insn.operands[1].reg), r(insn.operands[2].reg)); - break; - case MIPS_INS_XORI: - printf("%s = %s ^ 0x%x;\n", r(insn.operands[0].reg), r(insn.operands[1].reg), (uint32_t)insn.operands[2].imm); - break; - case MIPS_INS_TNE: - printf("assert(%s == %s && \"tne %d\");\n", r(insn.operands[0].reg), r(insn.operands[1].reg), (int)insn.operands[2].imm); - break; - case MIPS_INS_TEQ: - printf("assert(%s != %s && \"teq %d\");\n", r(insn.operands[0].reg), r(insn.operands[1].reg), (int)insn.operands[2].imm); - break; - case MIPS_INS_TGE: - printf("assert((int)%s < (int)%s && \"tge %d\");\n", r(insn.operands[0].reg), r(insn.operands[1].reg), (int)insn.operands[2].imm); - break; - case MIPS_INS_TGEU: - printf("assert(%s < %s && \"tgeu %d\");\n", r(insn.operands[0].reg), r(insn.operands[1].reg), (int)insn.operands[2].imm); - break; - case MIPS_INS_TLT: - printf("assert((int)%s >= (int)%s && \"tlt %d\");\n", r(insn.operands[0].reg), r(insn.operands[1].reg), (int)insn.operands[2].imm); - break; - case MIPS_INS_NOP: - printf("//nop;\n"); - break; - default: - unimplemented: - printf("UNIMPLEMENTED %s %s\n", insn.mnemonic.c_str(), insn.op_str.c_str()); - break; - } -} - -static void inspect_data_function_pointers(vector>& ret, const uint8_t *section, uint32_t section_vaddr, uint32_t len) { - for (uint32_t i = 0; i < len; i += 4) { - uint32_t addr = read_u32_be(section + i); - if (addr == 0x430b00 || addr == 0x433b00) { - // in as1, not function pointers (normal integers) - continue; - } - if (addr == 0x4a0000) { - // in copt - continue; - } - if (section_vaddr + i >= procedure_table_start && section_vaddr + i < procedure_table_start + procedure_table_len) { - // some linking table with a "all" functions, in as1 5.3 - continue; - } - if (addr >= text_vaddr && addr < text_vaddr + text_section_len && addr % 4 == 0) { -#if INSPECT_FUNCTION_POINTERS - fprintf(stderr, "assuming function pointer 0x%x at 0x%x\n", addr, section_vaddr + i); -#endif - ret.push_back(make_pair(section_vaddr + i, addr)); - label_addresses.insert(addr); - functions[addr].referenced_by_function_pointer = true; - } - } -} - -static void dump_function_signature(Function& f, uint32_t vaddr) { - printf("static "); - switch (f.nret) { - case 0: - printf("void "); - break; - case 1: - printf("uint32_t "); - break; - case 2: - printf("uint64_t "); - break; - } - auto name_it = symbol_names.find(vaddr); - if (name_it != symbol_names.end()) { - printf("f_%s", name_it->second.c_str()); - } else { - printf("func_%x", vaddr); - } - printf("(uint8_t *mem, uint32_t sp"); - if (f.v0_in) { - printf(", uint32_t %s", r(MIPS_REG_V0)); - } - for (uint32_t i = 0; i < f.nargs; i++) { - printf(", uint32_t %s", r(MIPS_REG_A0 + i)); - } - printf(")"); -} - -static void dump_c(void) { - map symbol_names_inv; - for (auto& it : symbol_names) { - symbol_names_inv[it.second] = it.first; - } - - uint32_t min_addr = ~0; - uint32_t max_addr = 0; - - if (data_section_len > 0) { - min_addr = std::min(min_addr, data_vaddr); - max_addr = std::max(max_addr, data_vaddr + data_section_len); - } - if (rodata_section_len > 0) { - min_addr = std::min(min_addr, rodata_vaddr); - max_addr = std::max(max_addr, rodata_vaddr + rodata_section_len); - } - if (bss_section_len) { - min_addr = std::min(min_addr, bss_vaddr); - max_addr = std::max(max_addr, bss_vaddr + bss_section_len); - } - - min_addr = min_addr & ~0xfff; - max_addr = (max_addr + 0xfff) & ~0xfff; - - uint32_t stack_bottom = min_addr; - min_addr -= 1 * 1024 * 1024; // 1 MB stack - stack_bottom -= 16; // for main's stack frame - - printf("#include \"header.h\"\n"); - if (conservative) { - printf("static uint32_t s0, s1, s2, s3, s4, s5, s6, s7, fp;\n"); - } - printf("static const uint32_t rodata[] = {\n"); - for (size_t i = 0; i < rodata_section_len; i += 4) { - printf("0x%x,%s", read_u32_be(rodata_section + i), i % 32 == 28 ? "\n" : ""); - } - printf("};\n"); - printf("static const uint32_t data[] = {\n"); - for (size_t i = 0; i < data_section_len; i += 4) { - printf("0x%x,%s", read_u32_be(data_section + i), i % 32 == 28 ? "\n" : ""); - } - printf("};\n"); - - /*if (!data_function_pointers.empty()) { - printf("static const struct { uint32_t orig_addr; void *recompiled_addr; } data_function_pointers[] = {\n"); - for (auto item : data_function_pointers) { - printf("{0x%x, &&L%x},\n", item.first, item.second); - } - printf("};\n"); - }*/ - - if (TRACE) { - printf("static unsigned long long int cnt = 0;\n"); - } - - for (auto& f_it : functions) { - if (insns[addr_to_i(f_it.first)].f_livein != 0) { - // Function is used - dump_function_signature(f_it.second, f_it.first); - printf(";\n"); - } - } - - if (!data_function_pointers.empty() || !li_function_pointers.empty()) { - printf("uint64_t trampoline(uint8_t *mem, uint32_t sp, uint32_t a0, uint32_t a1, uint32_t a2, uint32_t a3, uint32_t fp_dest) {\n"); - printf("switch (fp_dest) {\n"); - for (auto& it : functions) { - Function& f = it.second; - if (f.referenced_by_function_pointer) { - printf("case 0x%x: ", it.first); - if (f.nret == 1) { - printf("return (uint64_t)"); - } else if (f.nret == 2) { - printf("return "); - } - auto name_it = symbol_names.find(it.first); - if (name_it != symbol_names.end()) { - printf("f_%s", name_it->second.c_str()); - } else { - printf("func_%x", it.first); - } - printf("(mem, sp"); - for (int i = 0; i < f.nargs; i++) { - printf(", a%d", i); - } - printf(")"); - if (f.nret == 1) { - printf(" << 32"); - } - printf(";"); - if (f.nret == 0) { - printf(" return 0;"); - } - printf("\n"); - } - } - printf("default: abort();"); - printf("}\n"); - printf("}\n"); - } - - printf("int run(uint8_t *mem, int argc, char *argv[]) {\n"); - printf("mmap_initial_data_range(mem, 0x%x, 0x%x);\n", min_addr, max_addr); - - printf("memcpy(mem + 0x%x, rodata, 0x%x);\n", rodata_vaddr, rodata_section_len); - printf("memcpy(mem + 0x%x, data, 0x%x);\n", data_vaddr, data_section_len); - - /*if (!data_function_pointers.empty()) { - if (!LABELS_64_BIT) { - printf("for (int i = 0; i < %d; i++) MEM_U32(data_function_pointers[i].orig_addr) = (uint32_t)(uintptr_t)data_function_pointers[i].recompiled_addr;\n", (int)data_function_pointers.size()); - } else { - printf("for (int i = 0; i < %d; i++) MEM_U32(data_function_pointers[i].orig_addr) = (uint32_t)((uintptr_t)data_function_pointers[i].recompiled_addr - (uintptr_t)&&Loffset);\n", (int)data_function_pointers.size()); - } - }*/ - - printf("MEM_S32(0x%x) = argc;\n", symbol_names_inv.at("__Argc")); - printf("MEM_S32(0x%x) = argc;\n", stack_bottom); - printf("uint32_t al = argc * 4; for (int i = 0; i < argc; i++) al += strlen(argv[i]) + 1;\n"); - printf("uint32_t arg_addr = wrapper_malloc(mem, al);\n"); - printf("MEM_U32(0x%x) = arg_addr;\n", symbol_names_inv.at("__Argv")); - printf("MEM_U32(0x%x) = arg_addr;\n", stack_bottom + 4); - printf("uint32_t arg_strpos = arg_addr + argc * 4;\n"); - printf("for (int i = 0; i < argc; i++) {MEM_U32(arg_addr + i * 4) = arg_strpos; uint32_t p = 0; do { MEM_S8(arg_strpos) = argv[i][p]; ++arg_strpos; } while (argv[i][p++] != '\\0');}\n"); - - printf("setup_libc_data(mem);\n"); - - //printf("gp = 0x%x;\n", gp_value); // only to recreate the outcome when ugen reads uninitialized stack memory - - printf("int ret = f_main(mem, 0x%x", stack_bottom); - Function& main_func = functions[main_addr]; - if (main_func.nargs >= 1) { - printf(", argc"); - } - if (main_func.nargs >= 2) { - printf(", arg_addr"); - } - printf(");\n"); - if (TRACE) { - printf("end: fprintf(stderr, \"cnt: %%llu\\n\", cnt);\n"); - } - printf("return ret;\n"); - printf("}\n"); - - for (auto& f_it : functions) { - Function& f = f_it.second; - uint32_t start_addr = f_it.first; - uint32_t end_addr = f.end_addr; - - if (insns[addr_to_i(start_addr)].f_livein == 0) { - // Non-used function, skip - continue; - } - - printf("\n"); - dump_function_signature(f, start_addr); - printf(" {\n"); - printf("const uint32_t zero = 0;\n"); - if (!conservative) { - printf("uint32_t at = 0, v1 = 0, t0 = 0, t1 = 0, t2 = 0,\n"); - printf("t3 = 0, t4 = 0, t5 = 0, t6 = 0, t7 = 0, s0 = 0, s1 = 0, s2 = 0, s3 = 0, s4 = 0, s5 = 0,\n"); - printf("s6 = 0, s7 = 0, t8 = 0, t9 = 0, gp = 0, fp = 0, s8 = 0, ra = 0;\n"); - } else { - printf("uint32_t at = 0, v1 = 0, t0 = 0, t1 = 0, t2 = 0,\n"); - printf("t3 = 0, t4 = 0, t5 = 0, t6 = 0, t7 = 0, t8 = 0, t9 = 0, gp = 0x10000, ra = 0x10000;\n"); - } - printf("uint32_t lo = 0, hi = 0;\n"); - printf("int cf = 0;\n"); - printf("uint64_t temp64;\n"); - printf("uint32_t fp_dest;\n"); - printf("void *dest;\n"); - if (!f.v0_in) { - printf("uint32_t v0 = 0;\n"); - } - for (uint32_t j = f.nargs; j < 4; j++) { - printf("uint32_t %s = 0;\n", r(MIPS_REG_A0 + j)); - } - - for (size_t i = addr_to_i(start_addr), end_i = addr_to_i(end_addr); i < end_i; i++) { - Insn& insn = insns[i]; - uint32_t vaddr = text_vaddr + i * 4; - if (label_addresses.count(vaddr)) { - printf("L%x:\n", vaddr); - } - dump_instr(i); - } - - printf("}\n"); - } - /*for (size_t i = 0; i < insns.size(); i++) { - Insn& insn = insns[i]; - uint32_t vaddr = text_vaddr + i * 4; - auto fn_it = functions.find(vaddr); - if (fn_it != functions.end()) { - Function& f = fn_it->second; - printf("}\n\n"); - switch (f.nret) { - case 0: - printf("void "); - break; - case 1: - printf("uint32_t "); - break; - case 2: - printf("uint64_t "); - break; - } - auto name_it = symbol_names.find(vaddr); - if (name_it != symbol_names.end()) { - printf("%s", name_it->second.c_str()); - } else { - printf("func_%x", vaddr); - } - printf("(uint8_t *mem, uint32_t sp"); - if (f.v0_in) { - printf(", uint32_t %s", r(MIPS_REG_V0)); - } - for (uint32_t i = 0; i < f.nargs; i++) { - printf(", uint32_t %s", r(MIPS_REG_A0 + i)); - } - printf(") {\n"); - printf("const uint32_t zero = 0;\n"); - printf("uint32_t at = 0, v1 = 0, t0 = 0, t1 = 0, t2 = 0,\n"); - printf("t3 = 0, t4 = 0, t5 = 0, t6 = 0, t7 = 0, s0 = 0, s1 = 0, s2 = 0, s3 = 0, s4 = 0, s5 = 0,\n"); - printf("s6 = 0, s7 = 0, t8 = 0, t9 = 0, gp = 0, fp = 0, s8 = 0, ra = 0;\n"); - printf("uint32_t lo = 0, hi = 0;\n"); - printf("int cf = 0;\n"); - if (!f.v0_in) { - printf("uint32_t v0 = 0;\n"); - } - for (uint32_t j = f.nargs; j < 4; j++) { - printf("uint32_t %s = 0;\n", r(MIPS_REG_A0 + j)); - } - } - if (label_addresses.count(vaddr)) { - printf("L%x:\n", vaddr); - } - dump_instr(i); - }*/ -} - -static void parse_elf(const uint8_t *data, size_t file_len) { - Elf32_Ehdr *ehdr; - Elf32_Shdr *shdr, *str_shdr, *sym_shdr = NULL, *dynsym_shdr, *dynamic_shdr, *reginfo_shdr, *got_shdr, *sym_strtab, *sym_dynstr; - int text_section_index = -1; - int symtab_section_index = -1; - int dynsym_section_index = -1; - int reginfo_section_index = -1; - int dynamic_section_index = -1; - int got_section_index = -1; - int rodata_section_index = -1; - int data_section_index = -1; - int bss_section_index = -1; - uint32_t text_offset = 0; - uint32_t vaddr_adj = 0; - - if (file_len < 4 || data[0] != 0x7f || data[1] != 'E' || data[2] != 'L' || data[3] != 'F') { - fprintf(stderr, "Not an ELF file.\n"); - exit(EXIT_FAILURE); - } - - ehdr = (Elf32_Ehdr *) data; - if (ehdr->e_ident[EI_DATA] != 2 || u16be(ehdr->e_machine) != 8) { - fprintf(stderr, "Not big-endian MIPS.\n"); - exit(EXIT_FAILURE); - } - - if (u16be(ehdr->e_shstrndx) == 0) { - // (We could look at program headers instead in this case.) - fprintf(stderr, "Missing section headers; stripped binaries are not yet supported.\n"); - exit(EXIT_FAILURE); - } - -#define SECTION(index) (Elf32_Shdr *)(data + u32be(ehdr->e_shoff) + (index) * u16be(ehdr->e_shentsize)) -#define STR(strtab, offset) (const char *)(data + u32be(strtab->sh_offset) + offset) - - str_shdr = SECTION(u16be(ehdr->e_shstrndx)); - for (int i = 0; i < u16be(ehdr->e_shnum); i++) { - shdr = SECTION(i); - const char *name = STR(str_shdr, u32be(shdr->sh_name)); - if (strcmp(name, ".text") == 0) { - text_offset = u32be(shdr->sh_offset); - text_vaddr = u32be(shdr->sh_addr); - vaddr_adj = text_vaddr - u32be(shdr->sh_addr); - text_section_len = u32be(shdr->sh_size); - text_section = data + text_offset; - text_section_index = i; - } - if (u32be(shdr->sh_type) == SHT_SYMTAB) { - symtab_section_index = i; - } - if (u32be(shdr->sh_type) == SHT_DYNSYM) { - dynsym_section_index = i; - } - if (u32be(shdr->sh_type) == SHT_MIPS_REGINFO) { - reginfo_section_index = i; - } - if (u32be(shdr->sh_type) == SHT_DYNAMIC) { - dynamic_section_index = i; - } - if (strcmp(name, ".got") == 0) { - got_section_index = i; - } - if (strcmp(name, ".rodata") == 0) { - rodata_section_index = i; - } - if (strcmp(name, ".data") == 0) { - data_section_index = i; - } - if (strcmp(name, ".bss") == 0) { - bss_section_index = i; - } - } - - if (text_section_index == -1) { - fprintf(stderr, "Missing .text section.\n"); - exit(EXIT_FAILURE); - } - - if (symtab_section_index == -1 && dynsym_section_index == -1) { - fprintf(stderr, "Missing .symtab or .dynsym section.\n"); - exit(EXIT_FAILURE); - } - - if (dynsym_section_index != -1) { - if (reginfo_section_index == -1) { - fprintf(stderr, "Missing .reginfo section.\n"); - exit(EXIT_FAILURE); - } - if (dynamic_section_index == -1) { - fprintf(stderr, "Missing .dynamic section.\n"); - exit(EXIT_FAILURE); - } - if (got_section_index == -1) { - fprintf(stderr, "Missing .got section.\n"); - exit(EXIT_FAILURE); - } - } - - if (rodata_section_index != -1) { - shdr = SECTION(rodata_section_index); - uint32_t size = u32be(shdr->sh_size); - rodata_section = data + u32be(shdr->sh_offset); - rodata_section_len = size; - rodata_vaddr = u32be(shdr->sh_addr); - } - - if (data_section_index != -1) { - shdr = SECTION(data_section_index); - uint32_t size = u32be(shdr->sh_size); - data_section = data + u32be(shdr->sh_offset); - data_section_len = size; - data_vaddr = u32be(shdr->sh_addr); - } - - if (bss_section_index != -1) { - shdr = SECTION(bss_section_index); - uint32_t size = u32be(shdr->sh_size); - bss_section_len = size; - bss_vaddr = u32be(shdr->sh_addr); - } - - - // add symbols - if (symtab_section_index != -1) { - sym_shdr = SECTION(symtab_section_index); - sym_strtab = SECTION(u32be(sym_shdr->sh_link)); - assert(0 && ".symtab not supported - use a program with .dynsym instead"); - - assert(u32be(sym_shdr->sh_entsize) == sizeof(Elf32_Sym)); - for (uint32_t i = 0; i < u32be(sym_shdr->sh_size); i += sizeof(Elf32_Sym)) { - Elf32_Sym *sym = (Elf32_Sym *)(data + u32be(sym_shdr->sh_offset) + i); - const char *name = STR(sym_strtab, u32be(sym->st_name)); - uint32_t addr = u32be(sym->st_value); - if (u16be(sym->st_shndx) != text_section_index || name[0] == '.') { - continue; - } - addr += vaddr_adj; - //disasm_label_add(state, name, addr, u32be(sym->st_size), true); - } - } - - if (dynsym_section_index != -1) { - dynsym_shdr = SECTION(dynsym_section_index); - sym_dynstr = SECTION(u32be(dynsym_shdr->sh_link)); - reginfo_shdr = SECTION(reginfo_section_index); - dynamic_shdr = SECTION(dynamic_section_index); - got_shdr = SECTION(got_section_index); - - Elf32_RegInfo *reg_info = (Elf32_RegInfo *)(data + u32be(reginfo_shdr->sh_offset)); - uint32_t gp_base = u32be(reg_info->ri_gp_value); // gp should have this value through the program run - uint32_t got_start = 0; - uint32_t local_got_no = 0; - uint32_t first_got_sym = 0; - uint32_t dynsym_no = 0; // section size can't be used due to alignment 16 padding - - assert(u32be(dynamic_shdr->sh_entsize) == sizeof(Elf32_Dyn)); - for (uint32_t i = 0; i < u32be(dynamic_shdr->sh_size); i += sizeof(Elf32_Dyn)) { - Elf32_Dyn *dyn = (Elf32_Dyn *)(data + u32be(dynamic_shdr->sh_offset) + i); - if (u32be(dyn->d_tag) == DT_PLTGOT) { - got_start = u32be(dyn->d_un.d_ptr); - } - if (u32be(dyn->d_tag) == DT_MIPS_LOCAL_GOTNO) { - local_got_no = u32be(dyn->d_un.d_val); - } - if (u32be(dyn->d_tag) == DT_MIPS_GOTSYM) { - first_got_sym = u32be(dyn->d_un.d_val); - } - if (u32be(dyn->d_tag) == DT_MIPS_SYMTABNO) { - dynsym_no = u32be(dyn->d_un.d_val); - } - } - - assert(got_start != 0); - - // value to add to asm gp offset, for example 32752, if -32752(gp) refers to the first entry in got. - uint32_t gp_adj = gp_base - got_start; - assert(gp_adj < 0x10000); - - assert(u32be(dynsym_shdr->sh_entsize) == sizeof(Elf32_Sym)); - uint32_t global_got_no = dynsym_no - first_got_sym; - //global_got_entry *global_entries = (global_got_entry *)calloc(global_got_no, sizeof(global_got_entry)); - got_globals.resize(global_got_no); - - uint32_t common_start = ~0U; - vector common_order; - - for (uint32_t i = 0; i < dynsym_no; i++) { - Elf32_Sym *sym = (Elf32_Sym *)(data + u32be(dynsym_shdr->sh_offset) + i * sizeof(Elf32_Sym)); - const char *name = STR(sym_dynstr, u32be(sym->st_name)); - uint32_t addr = u32be(sym->st_value); - addr += vaddr_adj; - uint8_t type = ELF32_ST_TYPE(sym->st_info); - if (!strcmp(name, "_procedure_table")) { - procedure_table_start = addr; - } else if (!strcmp(name, "_procedure_table_size")) { - procedure_table_len = 40 * u32be(sym->st_value); - } - if ((u16be(sym->st_shndx) == SHN_MIPS_TEXT && type == STT_FUNC) || - (type == STT_OBJECT && (u16be(sym->st_shndx) == SHN_MIPS_ACOMMON || u16be(sym->st_shndx) == SHN_MIPS_DATA))) - { - //disasm_label_add(state, name, addr, u32be(sym->st_size), true); - if (type == STT_OBJECT) { - } - if (u16be(sym->st_shndx) == SHN_MIPS_ACOMMON) { - if (addr < common_start) { - common_start = addr; - } - common_order.push_back(name); - } - if (type == STT_FUNC) { - add_function(addr); - if (strcmp(name, "main") == 0) { - main_addr = addr; - } - if (strcmp(name, "_mcount") == 0) { - mcount_addr = addr; - } - symbol_names[addr] = name; - } - } - if (i >= first_got_sym) { - uint32_t got_value = u32be(*(uint32_t *)(data + u32be(got_shdr->sh_offset) + (local_got_no + (i - first_got_sym)) * sizeof(uint32_t))); - if (u16be(sym->st_shndx) == SHN_MIPS_TEXT && type == STT_FUNC) { - //got_globals[i - first_got_sym] = got_value; - //label_addresses.insert(got_value); - got_globals[i - first_got_sym] = addr; // to include the 3 instr gp header thing - label_addresses.insert(addr); - } else if (type == STT_OBJECT && (u16be(sym->st_shndx) == SHN_UNDEF || u16be(sym->st_shndx) == SHN_COMMON)) { - // symbol defined externally (for example in libc) - got_globals[i - first_got_sym] = got_value; - } else { - got_globals[i - first_got_sym] = addr; - } - symbol_names[got_globals[i - first_got_sym]] = name; - } - } - - uint32_t *local_entries = (uint32_t *)calloc(local_got_no, sizeof(uint32_t)); - got_locals.resize(local_got_no); - for (uint32_t i = 0; i < local_got_no; i++) { - uint32_t *entry = (uint32_t *)(data + u32be(got_shdr->sh_offset) + i * sizeof(uint32_t)); - got_locals[i] = u32be(*entry); - } - - gp_value = gp_base; - gp_value_adj = gp_adj; - //disasm_got_entries_set(state, gp_base, gp_adj, local_entries, local_got_no, global_entries, global_got_no); - - //out_range.common_start = common_start; - //out_range.common_order.swap(common_order); - } - - // add relocations - for (int i = 0; i < u16be(ehdr->e_shnum); i++) { - Elf32_Rel *prevHi = NULL; - shdr = SECTION(i); - if (u32be(shdr->sh_type) != SHT_REL || u32be(shdr->sh_info) != (uint32_t) text_section_index) - continue; - - if (sym_shdr == NULL) { - fprintf(stderr, "Relocations without .symtab section\n"); - exit(EXIT_FAILURE); - } - - assert(u32be(shdr->sh_link) == (uint32_t) symtab_section_index); - assert(u32be(shdr->sh_entsize) == sizeof(Elf32_Rel)); - for (uint32_t i = 0; i < u32be(shdr->sh_size); i += sizeof(Elf32_Rel)) { - Elf32_Rel *rel = (Elf32_Rel *)(data + u32be(shdr->sh_offset) + i); - uint32_t offset = text_offset + u32be(rel->r_offset); - uint32_t symIndex = ELF32_R_SYM(u32be(rel->r_info)); - uint32_t rtype = ELF32_R_TYPE(u32be(rel->r_info)); - const char *symName = "0"; - if (symIndex != STN_UNDEF) { - Elf32_Sym *sym = (Elf32_Sym *)(data + u32be(sym_shdr->sh_offset) + symIndex * sizeof(Elf32_Sym)); - symName = STR(sym_strtab, u32be(sym->st_name)); - } - - if (rtype == R_MIPS_HI16) { - if (prevHi != NULL) { - fprintf(stderr, "Consecutive R_MIPS_HI16.\n"); - exit(EXIT_FAILURE); - } - prevHi = rel; - continue; - } - if (rtype == R_MIPS_LO16) { - int32_t addend = (int16_t)((data[offset + 2] << 8) + data[offset + 3]); - if (prevHi != NULL) { - uint32_t offset2 = text_offset + u32be(prevHi->r_offset); - addend += (uint32_t)((data[offset2 + 2] << 8) + data[offset2 + 3]) << 16; - //add_reloc(state, offset2, symName, addend, out_range.vaddr); - } - prevHi = NULL; - //add_reloc(state, offset, symName, addend, out_range.vaddr); - } - else if (rtype == R_MIPS_26) { - int32_t addend = (u32be(*(uint32_t*)(data + offset)) & ((1 << 26) - 1)) << 2; - if (addend >= (1 << 27)) { - addend -= 1 << 28; - } - //add_reloc(state, offset, symName, addend, out_range.vaddr); - } - else { - fprintf(stderr, "Bad relocation type %d.\n", rtype); - exit(EXIT_FAILURE); - } - } - if (prevHi != NULL) { - fprintf(stderr, "R_MIPS_HI16 without matching R_MIPS_LO16.\n"); - exit(EXIT_FAILURE); - } - } -} -#undef SECTION -#undef STR - -size_t read_file(const char *file_name, uint8_t **data) { - FILE *in; - uint8_t *in_buf = NULL; - long file_size; - long bytes_read; - in = fopen(file_name, "rb"); - assert(in != nullptr); - - // allocate buffer to read from offset to end of file - fseek(in, 0, SEEK_END); - file_size = ftell(in); - assert(file_size != -1L); - - in_buf = (uint8_t *)malloc(file_size); - fseek(in, 0, SEEK_SET); - - // read bytes - bytes_read = fread(in_buf, 1, file_size, in); - assert(bytes_read == file_size); - - fclose(in); - *data = in_buf; - return bytes_read; -} - -int main(int argc, char *argv[]) { - const char *filename = argv[1]; - if (strcmp(filename, "--conservative") == 0) { - conservative = true; - filename = argv[2]; - } - - uint8_t *data; - size_t len = read_file(filename, &data); - parse_elf(data, len); - assert(cs_open(CS_ARCH_MIPS, (cs_mode)(CS_MODE_MIPS64 | CS_MODE_BIG_ENDIAN), &handle) == CS_ERR_OK); - cs_option(handle, CS_OPT_DETAIL, CS_OPT_ON); - disassemble(); - inspect_data_function_pointers(data_function_pointers, rodata_section, rodata_vaddr, rodata_section_len); - inspect_data_function_pointers(data_function_pointers, data_section, data_vaddr, data_section_len); - pass1(); - pass2(); - pass3(); - pass4(); - pass5(); - pass6(); - //dump(); - dump_c(); - free(data); - cs_close(&handle); -} - diff --git a/tools/ique_egcs/as b/tools/ique_egcs/as new file mode 100755 index 00000000..fac563c2 Binary files /dev/null and b/tools/ique_egcs/as differ diff --git a/tools/ique_egcs/cc1 b/tools/ique_egcs/cc1 new file mode 100755 index 00000000..48913cd6 Binary files /dev/null and b/tools/ique_egcs/cc1 differ diff --git a/tools/ique_egcs/cpp b/tools/ique_egcs/cpp new file mode 100755 index 00000000..18d304c6 Binary files /dev/null and b/tools/ique_egcs/cpp differ diff --git a/tools/ique_egcs/gcc b/tools/ique_egcs/gcc new file mode 100755 index 00000000..b9462347 Binary files /dev/null and b/tools/ique_egcs/gcc differ diff --git a/tools/ique_ld/mips64-elf-ld b/tools/ique_ld/mips64-elf-ld new file mode 100755 index 00000000..d5f52b07 Binary files /dev/null and b/tools/ique_ld/mips64-elf-ld differ diff --git a/tools/rasm2armips.py b/tools/rasm2armips.py index ae92d586..168b02a6 100755 --- a/tools/rasm2armips.py +++ b/tools/rasm2armips.py @@ -1,5 +1,25 @@ #!/usr/bin/env python +# Copyright (c) 2020 queueRAM +# +# Permission is hereby granted, free of charge, to any person obtaining a copy +# of this software and associated documentation files (the "Software"), to deal +# in the Software without restriction, including without limitation the rights +# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +# copies of the Software, and to permit persons to whom the Software is +# furnished to do so, subject to the following conditions: +# +# The above copyright notice and this permission notice shall be included in +# all copies or substantial portions of the Software. +# +# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +# AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +# SOFTWARE. + import argparse import re import sys diff --git a/tools/sdk-tools/adpcm/vadpcm_enc.c b/tools/sdk-tools/adpcm/vadpcm_enc.c index 0fd3a11f..a203d21d 100644 --- a/tools/sdk-tools/adpcm/vadpcm_enc.c +++ b/tools/sdk-tools/adpcm/vadpcm_enc.c @@ -56,7 +56,11 @@ int main(int argc, char **argv) ALADPCMloop *aloops; Marker *markers; CodeChunk cChunk; +#ifdef __sgi char filename[1024]; +#else + const char *filename; +#endif FILE *fhandle; FILE *ifile; FILE *ofile; @@ -72,7 +76,12 @@ int main(int argc, char **argv) switch (c) { case 'c': +#ifdef __sgi if (sscanf(optarg, "%s", filename) == 1) +#else + // Allow filenames with spaces + filename = optarg; +#endif { if ((fhandle = fopen(filename, "r")) == NULL) { diff --git a/tools/seq_decoder.py b/tools/seq_decoder.py index 9329e702..d4546cd3 100755 --- a/tools/seq_decoder.py +++ b/tools/seq_decoder.py @@ -267,7 +267,7 @@ if sys.argv[1] == "--emit-asm-macros": emit_cmd(key, 0xc0, ['delay_long', 'var_long']) emit_cmd(key, 0x40, ['note1_long', 'bits:4', 'var_long', 'u8']) if eu_sh or us_jp or sh or non_sh: - print("#ifdef VERSION_SH\n") + print("#if defined(VERSION_SH) || defined(VERSION_CN)\n") for (op, cmd) in eu_sh: emit_cmd(key, op, cmd) for (op, cmd) in sh: diff --git a/tools/skyconv.c b/tools/skyconv.c index 79d6f041..6152b0fb 100644 --- a/tools/skyconv.c +++ b/tools/skyconv.c @@ -10,8 +10,8 @@ #include #include -#include "n64graphics.h" -#include "utils.h" +#include "sm64tools/n64graphics.h" +#include "sm64tools/utils.h" #define SKYCONV_ENCODING ENCODING_U8 @@ -26,6 +26,7 @@ typedef enum { Skybox, Cake, CakeEU, + CakeCN, ImageType_MAX } ImageType; @@ -56,6 +57,10 @@ static const ImageProps IMAGE_PROPERTIES[ImageType_MAX][2] = { {320, 224, 64, 32, 5, 7, false, false}, {320, 224, 64, 32, 5, 7, false, false}, }, + [CakeCN] = { + {316, 228, 79, 19, 4, 12, false, false}, + {320, 240, 80, 20, 4, 12, false, false}, + }, }; typedef struct { @@ -66,6 +71,7 @@ static const TableDimension TABLE_DIMENSIONS[ImageType_MAX] = { [Skybox] = {8, 10}, [Cake] = {4, 12}, [CakeEU] = {5, 7}, + [CakeCN] = {4, 12}, }; TextureTile *tiles; @@ -242,6 +248,9 @@ void write_tiles() { case CakeEU: strcat(buffer, "cake_eu"); break; + case CakeCN: + strcat(buffer, "cake_cn"); + break; default: exit(EXIT_FAILURE); break; @@ -324,7 +333,10 @@ static void write_cake_c() { exit(EXIT_FAILURE); } - if (type == CakeEU) { + if (type == CakeCN) { + strcat(buffer, "/cake_cn.inc.c"); + } + else if (type == CakeEU) { strcat(buffer, "/cake_eu.inc.c"); } else { @@ -408,9 +420,9 @@ fail: exit(1); } -void combine_cakeimg(const char *input, const char *output, bool eu) { +void combine_cakeimg(const char *input, const char *output) { int W, H, SMALLH, SMALLW; - if (eu) { + if (type == CakeEU) { W = 5; H = 7; SMALLH = 32; @@ -426,7 +438,7 @@ void combine_cakeimg(const char *input, const char *output, bool eu) { if (!file) goto fail; rgba *combined; - if (!eu) { + if (type == Cake) { combined = malloc((SMALLH-1)*H * (SMALLW-1)*W * sizeof(rgba)); for (int i = 0; i < H; i++) { for (int j = 0; j < W; j++) { @@ -476,7 +488,7 @@ fail: // Modified from n64split static void usage() { fprintf(stderr, - "Usage: %s --type sky|cake|cake_eu {--combine INPUT OUTPUT | --split INPUT OUTPUT}\n" + "Usage: %s --type sky|cake|cake-eu|cake-cn {--combine INPUT OUTPUT | --split INPUT OUTPUT}\n" "\n" "Optional arguments:\n" " --write-tiles OUTDIR Also create the individual tiles' PNG files\n", programName); @@ -513,7 +525,7 @@ static int parse_arguments(int argc, char *argv[]) { output = argv[i]; } - + if (strcmp(argv[i], "--type") == 0) { if (++i >= argc || type != InvalidType) { goto invalid; @@ -521,6 +533,8 @@ static int parse_arguments(int argc, char *argv[]) { if (strcmp(argv[i], "sky") == 0) { type = Skybox; + } else if(strcmp(argv[i], "cake-cn") == 0) { + type = CakeCN; } else if(strcmp(argv[i], "cake-eu") == 0) { type = CakeEU; } else if(strcmp(argv[i], "cake") == 0) { @@ -597,10 +611,9 @@ int main(int argc, char *argv[]) { combine_skybox(input, output); break; case Cake: - combine_cakeimg(input, output, 0); - break; case CakeEU: - combine_cakeimg(input, output, 1); + case CakeCN: + combine_cakeimg(input, output); break; default: usage(); @@ -631,6 +644,7 @@ int main(int argc, char *argv[]) { break; case Cake: case CakeEU: + case CakeCN: assign_tile_positions(); write_cake_c(); break; diff --git a/tools/sm64tools/.gitignore b/tools/sm64tools/.gitignore new file mode 100644 index 00000000..0192cfcf --- /dev/null +++ b/tools/sm64tools/.gitignore @@ -0,0 +1,4 @@ +/mio0 +/n64cksum +/n64graphics +/n64graphics_ci diff --git a/tools/sm64tools/Makefile b/tools/sm64tools/Makefile new file mode 100644 index 00000000..3ab2eeb5 --- /dev/null +++ b/tools/sm64tools/Makefile @@ -0,0 +1,39 @@ +include ../../util.mk + +HOST_ENV := $(shell uname 2>/dev/null || echo Unknown) +HOST_ENV := $(patsubst MINGW%,MinGW,$(HOST_ENV)) + +CC := gcc +CXX := g++ +CFLAGS := -I . -Wall -Wextra -Wno-unused-parameter -pedantic -O2 -s +LDFLAGS := -lm +ALL_PROGRAMS := n64graphics n64graphics_ci mio0 n64cksum + +BUILD_PROGRAMS := $(ALL_PROGRAMS) + +default: all + +n64graphics_SOURCES := n64graphics.c utils.c +n64graphics_CFLAGS := -DN64GRAPHICS_STANDALONE + +n64graphics_ci_SOURCES := n64graphics_ci_dir/n64graphics_ci.c n64graphics_ci_dir/exoquant/exoquant.c n64graphics_ci_dir/utils.c + +mio0_SOURCES := libmio0.c +mio0_CFLAGS := -DMIO0_STANDALONE + +n64cksum_SOURCES := n64cksum.c utils.c +n64cksum_CFLAGS := -DN64CKSUM_STANDALONE + +all: $(BUILD_PROGRAMS) + +clean: + $(RM) $(ALL_PROGRAMS) + +define COMPILE +$(1): $($1_SOURCES) + $$(CC) $(CFLAGS) $($1_CFLAGS) $$^ -o $$@ $($1_LDFLAGS) $(LDFLAGS) +endef + +$(foreach p,$(BUILD_PROGRAMS),$(eval $(call COMPILE,$(p)))) + +.PHONY: all clean default diff --git a/tools/libmio0.c b/tools/sm64tools/libmio0.c similarity index 100% rename from tools/libmio0.c rename to tools/sm64tools/libmio0.c diff --git a/tools/libmio0.h b/tools/sm64tools/libmio0.h similarity index 100% rename from tools/libmio0.h rename to tools/sm64tools/libmio0.h diff --git a/tools/n64cksum.c b/tools/sm64tools/n64cksum.c similarity index 100% rename from tools/n64cksum.c rename to tools/sm64tools/n64cksum.c diff --git a/tools/n64cksum.h b/tools/sm64tools/n64cksum.h similarity index 100% rename from tools/n64cksum.h rename to tools/sm64tools/n64cksum.h diff --git a/tools/n64graphics.c b/tools/sm64tools/n64graphics.c similarity index 100% rename from tools/n64graphics.c rename to tools/sm64tools/n64graphics.c diff --git a/tools/n64graphics.h b/tools/sm64tools/n64graphics.h similarity index 100% rename from tools/n64graphics.h rename to tools/sm64tools/n64graphics.h diff --git a/tools/n64graphics_ci_dir/LICENSE b/tools/sm64tools/n64graphics_ci_dir/LICENSE similarity index 100% rename from tools/n64graphics_ci_dir/LICENSE rename to tools/sm64tools/n64graphics_ci_dir/LICENSE diff --git a/tools/n64graphics_ci_dir/README.md b/tools/sm64tools/n64graphics_ci_dir/README.md similarity index 100% rename from tools/n64graphics_ci_dir/README.md rename to tools/sm64tools/n64graphics_ci_dir/README.md diff --git a/tools/n64graphics_ci_dir/exoquant/exoquant.c b/tools/sm64tools/n64graphics_ci_dir/exoquant/exoquant.c similarity index 100% rename from tools/n64graphics_ci_dir/exoquant/exoquant.c rename to tools/sm64tools/n64graphics_ci_dir/exoquant/exoquant.c diff --git a/tools/n64graphics_ci_dir/exoquant/exoquant.h b/tools/sm64tools/n64graphics_ci_dir/exoquant/exoquant.h similarity index 100% rename from tools/n64graphics_ci_dir/exoquant/exoquant.h rename to tools/sm64tools/n64graphics_ci_dir/exoquant/exoquant.h diff --git a/tools/n64graphics_ci_dir/n64graphics_ci.c b/tools/sm64tools/n64graphics_ci_dir/n64graphics_ci.c similarity index 100% rename from tools/n64graphics_ci_dir/n64graphics_ci.c rename to tools/sm64tools/n64graphics_ci_dir/n64graphics_ci.c diff --git a/tools/n64graphics_ci_dir/n64graphics_ci.h b/tools/sm64tools/n64graphics_ci_dir/n64graphics_ci.h similarity index 100% rename from tools/n64graphics_ci_dir/n64graphics_ci.h rename to tools/sm64tools/n64graphics_ci_dir/n64graphics_ci.h diff --git a/tools/n64graphics_ci_dir/utils.c b/tools/sm64tools/n64graphics_ci_dir/utils.c similarity index 100% rename from tools/n64graphics_ci_dir/utils.c rename to tools/sm64tools/n64graphics_ci_dir/utils.c diff --git a/tools/n64graphics_ci_dir/utils.h b/tools/sm64tools/n64graphics_ci_dir/utils.h similarity index 100% rename from tools/n64graphics_ci_dir/utils.h rename to tools/sm64tools/n64graphics_ci_dir/utils.h diff --git a/tools/sm64tools.LICENSE b/tools/sm64tools/sm64tools.LICENSE similarity index 100% rename from tools/sm64tools.LICENSE rename to tools/sm64tools/sm64tools.LICENSE diff --git a/tools/stb/stb_image.h b/tools/sm64tools/stb/stb_image.h similarity index 100% rename from tools/stb/stb_image.h rename to tools/sm64tools/stb/stb_image.h diff --git a/tools/stb/stb_image_write.h b/tools/sm64tools/stb/stb_image_write.h similarity index 100% rename from tools/stb/stb_image_write.h rename to tools/sm64tools/stb/stb_image_write.h diff --git a/tools/utils.c b/tools/sm64tools/utils.c similarity index 100% rename from tools/utils.c rename to tools/sm64tools/utils.c diff --git a/tools/utils.h b/tools/sm64tools/utils.h similarity index 100% rename from tools/utils.h rename to tools/sm64tools/utils.h diff --git a/tools/textconv.c b/tools/textconv.c index 867a944a..c1fd72fb 100644 --- a/tools/textconv.c +++ b/tools/textconv.c @@ -11,12 +11,14 @@ #define ARRAY_COUNT(arr) (sizeof(arr) / sizeof(arr[0])) +#define INVALID_CHAR 0xFFFFFFFF + struct CharmapEntry { uint32_t unicode[3]; int length; // length of the unicode array. TODO: use dynamic memory allocation int bytesCount; - uint8_t bytes[2]; // bytes to convert unicode array to, (e.g. 'A' = 0x0A) + uint8_t bytes[4]; // bytes to convert unicode array to, (e.g. 'A' = 0x0A) }; static struct HashTable *charmap; @@ -156,10 +158,11 @@ static int is_identifier_char(char c) return isalnum(c) || c == '_'; } -static int get_escape_char(int c) +static uint32_t get_escape_char(int c) { const uint8_t escapeTable[] = { + ['0'] = '\0', ['a'] = '\a', ['b'] = '\b', ['f'] = '\f', @@ -172,10 +175,10 @@ static int get_escape_char(int c) ['"'] = '"', }; - if ((unsigned int)c < ARRAY_COUNT(escapeTable) && escapeTable[c] != 0) + if ((unsigned int)c < ARRAY_COUNT(escapeTable) && (escapeTable[c] != 0 || c == '0')) return escapeTable[c]; else - return 0; + return INVALID_CHAR; } static void read_charmap(const char *filename) @@ -189,9 +192,10 @@ static void read_charmap(const char *filename) char *nextLine = line_split(line); struct CharmapEntry entry; + struct CharmapEntry *existing; line = skip_whitespace(line); - if (line[0] != 0 && line[0] != '#') // ignore empty lines and comments + if (line[0] != 0 && !(line[0] == '/' && line[1] == '/')) // ignore empty lines and comments { int len = 0; /* Read Character */ @@ -225,7 +229,7 @@ static void read_charmap(const char *filename) continue; } entry.unicode[len] = get_escape_char(*line); - if (entry.unicode[len] == 0) + if (entry.unicode[len] == INVALID_CHAR) parse_error(filename, lineNum, "unknown escape sequence \\%c", *line); line++; // increment again to get past the escape sequence. } @@ -252,8 +256,8 @@ static void read_charmap(const char *filename) { uint32_t value; - if (entry.bytesCount >= 2) - parse_error(filename, lineNum, "more than 2 values specified"); + if (entry.bytesCount >= 4) + parse_error(filename, lineNum, "more than 4 values specified"); line = skip_whitespace(line); @@ -274,9 +278,25 @@ static void read_charmap(const char *filename) line++; } - if (hashtable_query(charmap, &entry) != NULL) - parse_error(filename, lineNum, "entry for character already exists"); - hashtable_insert(charmap, &entry); + existing = hashtable_query(charmap, &entry); + + if (existing != NULL) { + const char *fmt = "0x%02X, "; + int fmtlen = 6; + + char str[32]; + int i; + + for (i = 0; i < existing->bytesCount; i++) { + sprintf(&str[fmtlen * i], fmt, existing->bytes[i]); + } + + str[fmtlen * i - 2] = '\0'; + + parse_error(filename, lineNum, "entry for character already exists (%s)", str); + } else { + hashtable_insert(charmap, &entry); + } } line = nextLine; @@ -299,9 +319,12 @@ static int count_line_num(const char *start, const char *pos) return lineNum; } -static char *convert_string(char *pos, FILE *fout, const char *inputFileName, char *start, int uncompressed) +static char *convert_string(char *pos, FILE *fout, const char *inputFileName, char *start, int uncompressed, int cnOneByte) { + const struct CharmapEntry terminatorInput = {.unicode = {'\0'}, .length = 1}; + struct CharmapEntry *terminator; int hasString = 0; + int i; while (1) { @@ -325,10 +348,9 @@ static char *convert_string(char *pos, FILE *fout, const char *inputFileName, ch struct CharmapEntry input; struct CharmapEntry *last_valid_entry = NULL; struct CharmapEntry *entry; - int i, c; + uint32_t c; int length = 0; char* last_valid_pos = NULL; - // safely erase the unicode area before use memset(input.unicode, 0, sizeof (input.unicode)); input.length = 0; @@ -350,7 +372,7 @@ static char *convert_string(char *pos, FILE *fout, const char *inputFileName, ch { pos++; c = get_escape_char(*pos); - if (c == 0) + if (c == INVALID_CHAR) parse_error(inputFileName, count_line_num(start, pos), "unknown escape sequence \\%c", *pos); input.unicode[length] = c; pos++; @@ -376,13 +398,26 @@ static char *convert_string(char *pos, FILE *fout, const char *inputFileName, ch pos = last_valid_pos; if (entry == NULL) parse_error(inputFileName, count_line_num(start, pos), "no charmap entry for U+%X", input.unicode[0]); - for (i = 0; i < entry->bytesCount; i++) + + for (i = 0; i < entry->bytesCount; i++) { + if (entry->bytesCount > 1 && cnOneByte && i % 2 == 0) { + continue; + } fprintf(fout, "0x%02X,", entry->bytes[i]); + } } pos++; // skip over closing '"' } pos++; // skip over closing ')' - fputs("0xFF", fout); + // use terminator \0 from charmap if provided, otherwise default 0xFF + terminator = hashtable_query(charmap, &terminatorInput); + if (terminator == NULL) + fputs("0xFF", fout); + else + { + for (i = 0; i < (cnOneByte ? 1 : terminator->bytesCount); i++) + fprintf(fout, "0x%02X,", terminator->bytes[i]); + } return pos; } @@ -451,6 +486,7 @@ static void convert_file(const char *infilename, const char *outfilename) else if ((*pos == '_') && (pos == in || !is_identifier_char(pos[-1]))) { int uncompressed = 0; + int cnOneByte = 0; end = pos; pos++; if (*pos == '_') // an extra _ signifies uncompressed strings. Enable uncompressed flag @@ -458,11 +494,16 @@ static void convert_file(const char *infilename, const char *outfilename) pos++; uncompressed = 1; } + if (*pos == '%') // an extra % signifies a one-byte long characters on iQue instead of two-byte + { + pos++; + cnOneByte = 1; + } if (*pos == '(') { pos++; fwrite(start, end - start, 1, fout); - pos = convert_string(pos, fout, infilename, in, uncompressed); + pos = convert_string(pos, fout, infilename, in, uncompressed, cnOneByte); start = pos; } } diff --git a/undefined_syms.txt b/undefined_syms.txt index 057abcec..938137ac 100644 --- a/undefined_syms.txt +++ b/undefined_syms.txt @@ -1,7 +1,6 @@ /* libultra OS symbols */ /* boot and osException symbols */ -/* most of these should be in hardware.h */ /* exceptions */ @@ -16,6 +15,9 @@ SP_IMEM = 0xA4001000; SP_STATUS_REG = 0xA4040010; SP_PC = 0xA4080000; +D_CN_0400049C = 0x0400049C; +D_CN_0400074C = 0x0400074C; + /* MI */ MI_MODE_REG = 0xA4300000; @@ -52,10 +54,21 @@ RI_REFRESH_REG = 0xA4700010; SI_STATUS_REG = 0xA4800018; /* Unknown */ - D_B0000008 = 0xB0000008; D_B0000010 = 0xB0000010; D_B0000014 = 0xB0000014; D_C0000000 = 0xC0000000; D_C0000008 = 0xC0000008; D_C000000C = 0xC000000C; + +/* iQue symbols */ +__osBbEepromAddress = 0x8000035C; +__osBbEepromSize = 0x80000360; +__osBbFlashAddress = 0x80000364; +__osBbFlashSize = 0x80000368; +__osBbSramAddress = 0x8000036C; +__osBbSramSize = 0x80000370; +__osBbPakAddress = 0x80000374; +__osBbPakSize = 0x80000384; +__osBbIsBb = 0x80000388; +__osBbHackFlags = 0x8000038C;