mirror of https://github.com/n64decomp/mk64.git
very cool debug display list (#348)
* added a very cool debug display list ^^ (prints variables to screen) * Decompiled various functions
This commit is contained in:
parent
2e5b2737f3
commit
9d716d921a
20
Makefile
20
Makefile
|
|
@ -25,7 +25,8 @@ TARGET_N64 ?= 1
|
|||
COMPILER ?= ido
|
||||
$(eval $(call validate-option,COMPILER,ido gcc))
|
||||
|
||||
|
||||
# options for debuging. Set this to 1 and modify the macros in include/debug.h
|
||||
DEBUG ?= 0
|
||||
|
||||
# VERSION - selects the version of the game to build
|
||||
# us - builds the 1997 North American version
|
||||
|
|
@ -43,6 +44,11 @@ else ifeq ($(VERSION), eu)
|
|||
VERSION_ASFLAGS := --defsym VERSION_EU=1
|
||||
endif
|
||||
|
||||
ifeq ($(DEBUG),1)
|
||||
DEFINES += DEBUG=1
|
||||
COMPARE ?= 0
|
||||
endif
|
||||
|
||||
TARGET := mk64.$(VERSION)
|
||||
|
||||
BASEROM := baserom.$(VERSION).z64
|
||||
|
|
@ -193,7 +199,7 @@ DATA_DIR := data
|
|||
INCLUDE_DIRS := include
|
||||
|
||||
# Directories containing source files
|
||||
SRC_DIRS := src src/audio src/os src/os/math courses
|
||||
SRC_DIRS := src src/audio src/debug src/os src/os/math courses
|
||||
ASM_DIRS := asm asm/audio asm/os asm/os/non_matchings $(DATA_DIR) $(DATA_DIR)/sound_data $(DATA_DIR)/karts
|
||||
|
||||
|
||||
|
|
@ -561,9 +567,6 @@ $(GLOBAL_ASM_O_FILES): CC := $(PYTHON) tools/asm_processor/build.py $(CC) -- $(A
|
|||
|
||||
$(GLOBAL_ASM_AUDIO_O_FILES): CC := $(PYTHON) tools/asm_processor/build.py $(CC) -- $(AS) $(ASFLAGS) --
|
||||
|
||||
$(BUILD_DIR)/$(LD_SCRIPT): $(LD_SCRIPT) #repeat for other files
|
||||
$(V)$(CPP) $(CPPFLAGS) $(DEF_INC_CFLAGS) -DBUILD_DIR=$(BUILD_DIR) -MMD -MP -MT $@ -MF $@.d -o $@ $<
|
||||
|
||||
|
||||
|
||||
#==============================================================================#
|
||||
|
|
@ -622,11 +625,10 @@ $(BUILD_DIR)/src/common_textures.inc.mio0.o: $(BUILD_DIR)/src/common_textures.in
|
|||
printf ".include \"macros.inc\"\n\n.section .data\n\n.balign 4\n\n.incbin \"src/common_textures.inc.mio0\"\n\n" > build/us/src/common_textures.inc.mio0.s
|
||||
$(AS) $(ASFLAGS) -o $(BUILD_DIR)/src/common_textures.inc.mio0.o $(BUILD_DIR)/src/common_textures.inc.mio0.s
|
||||
|
||||
# todo: Make this work
|
||||
# Run linker script through the C preprocessor
|
||||
#$(BUILD_DIR)/$(LD_SCRIPT): $(LD_SCRIPT)
|
||||
# $(call print,Preprocessing linker script:,$<,$@)
|
||||
# $(V)$(CPP) $(CPPFLAGS) -DBUILD_DIR=$(BUILD_DIR) -MMD -MP -MT $@ -MF $@.d -o $@ $<
|
||||
$(BUILD_DIR)/$(LD_SCRIPT): $(LD_SCRIPT)
|
||||
$(call print,Preprocessing linker script:,$<,$@)
|
||||
$(V)$(CPP) $(CPPFLAGS) -DBUILD_DIR=$(BUILD_DIR) -MMD -MP -MT $@ -MF $@.d -o $@ $<
|
||||
|
||||
# Link MK64 ELF file
|
||||
$(ELF): $(COURSE_DATA_TARGETS) $(O_FILES) $(COURSE_MIO0_OBJ_FILES) $(BUILD_DIR)/$(LD_SCRIPT) $(BUILD_DIR)/src/startup_logo.inc.mio0.o $(BUILD_DIR)/src/trophy_model.inc.mio0.o $(BUILD_DIR)/src/common_textures.inc.mio0.o $(COURSE_MODEL_TARGETS) undefined_syms.txt
|
||||
|
|
|
|||
|
|
@ -91,6 +91,7 @@ Some menu textures are compressed using a format called tkmk00. A byte-matching
|
|||
├── lib: SDK library code
|
||||
├── music: sequences
|
||||
├── src: C source code for the game
|
||||
| ├── debug: custom debug code
|
||||
│ ├── audio: sample tables and audio source
|
||||
│ └── os: libultra
|
||||
├── textures: texture data, bitmaps
|
||||
|
|
|
|||
|
|
@ -124,7 +124,7 @@ glabel D_8015F6FA
|
|||
glabel D_8015F6FC
|
||||
.skip 2
|
||||
|
||||
glabel D_8015F6FE
|
||||
glabel gNumSpawnedShells
|
||||
.skip 2
|
||||
|
||||
glabel D_8015F700
|
||||
|
|
|
|||
|
|
@ -89,7 +89,7 @@ glabel D_80164038
|
|||
glabel D_801640F4
|
||||
.skip 260
|
||||
|
||||
glabel D_801641F8
|
||||
glabel gUnexpiredActorsList
|
||||
.skip 224
|
||||
|
||||
glabel D_801642D8
|
||||
|
|
|
|||
|
|
@ -55,7 +55,7 @@ glabel func_8001EE98
|
|||
/* 01FB58 8001EF58 24020003 */ li $v0, 3
|
||||
/* 01FB5C 8001EF5C 95EFC51C */ lhu $t7, %lo(D_800DC51C)($t7)
|
||||
/* 01FB60 8001EF60 24030001 */ li $v1, 1
|
||||
/* 01FB64 8001EF64 3C19800E */ lui $t9, %hi(D_800DC5FC) # $t9, 0x800e
|
||||
/* 01FB64 8001EF64 3C19800E */ lui $t9, %hi(gIsGamePaused) # $t9, 0x800e
|
||||
/* 01FB68 8001EF68 146F0006 */ bne $v1, $t7, .L8001EF84
|
||||
.L8001EF6C:
|
||||
/* 01FB6C 8001EF6C 0010C040 */ sll $t8, $s0, 1
|
||||
|
|
@ -65,7 +65,7 @@ glabel func_8001EE98
|
|||
/* 01FB7C 8001EF7C 100000BB */ b .L8001F26C
|
||||
/* 01FB80 8001EF80 24030001 */ li $v1, 1
|
||||
.L8001EF84:
|
||||
/* 01FB84 8001EF84 9739C5FC */ lhu $t9, %lo(D_800DC5FC)($t9)
|
||||
/* 01FB84 8001EF84 9739C5FC */ lhu $t9, %lo(gIsGamePaused)($t9)
|
||||
/* 01FB88 8001EF88 3C0B8015 */ lui $t3, %hi(D_80152300) # $t3, 0x8015
|
||||
/* 01FB8C 8001EF8C 256B2300 */ addiu $t3, %lo(D_80152300) # addiu $t3, $t3, 0x2300
|
||||
/* 01FB90 8001EF90 1479000C */ bne $v1, $t9, .L8001EFC4
|
||||
|
|
@ -124,8 +124,8 @@ glabel func_8001EE98
|
|||
/* 01FC54 8001F054 10000085 */ b .L8001F26C
|
||||
/* 01FC58 8001F058 A4820006 */ sh $v0, 6($a0)
|
||||
.L8001F05C:
|
||||
/* 01FC5C 8001F05C 3C18800E */ lui $t8, %hi(D_800DC5FC) # $t8, 0x800e
|
||||
/* 01FC60 8001F060 9718C5FC */ lhu $t8, %lo(D_800DC5FC)($t8)
|
||||
/* 01FC5C 8001F05C 3C18800E */ lui $t8, %hi(gIsGamePaused) # $t8, 0x800e
|
||||
/* 01FC60 8001F060 9718C5FC */ lhu $t8, %lo(gIsGamePaused)($t8)
|
||||
/* 01FC64 8001F064 3C018016 */ lui $at, %hi(D_80164A88) # $at, 0x8016
|
||||
/* 01FC68 8001F068 A0204A88 */ sb $zero, %lo(D_80164A88)($at)
|
||||
/* 01FC6C 8001F06C 1478000D */ bne $v1, $t8, .L8001F0A4
|
||||
|
|
@ -169,7 +169,7 @@ glabel func_8001EE98
|
|||
/* 01FCF8 8001F0F8 11C10004 */ beq $t6, $at, .L8001F10C
|
||||
/* 01FCFC 8001F0FC 00000000 */ nop
|
||||
/* 01FD00 8001F100 95EFC51C */ lhu $t7, %lo(D_800DC51C)($t7)
|
||||
/* 01FD04 8001F104 3C18800E */ lui $t8, %hi(D_800DC5FC) # $t8, 0x800e
|
||||
/* 01FD04 8001F104 3C18800E */ lui $t8, %hi(gIsGamePaused) # $t8, 0x800e
|
||||
/* 01FD08 8001F108 146F0009 */ bne $v1, $t7, .L8001F130
|
||||
.L8001F10C:
|
||||
/* 01FD0C 8001F10C 3C018015 */ lui $at, %hi(D_80152300) # $at, 0x8015
|
||||
|
|
@ -182,7 +182,7 @@ glabel func_8001EE98
|
|||
/* 01FD28 8001F128 10000050 */ b .L8001F26C
|
||||
/* 01FD2C 8001F12C A4222306 */ sh $v0, %lo(D_80152300+0x6)($at)
|
||||
.L8001F130:
|
||||
/* 01FD30 8001F130 9718C5FC */ lhu $t8, %lo(D_800DC5FC)($t8)
|
||||
/* 01FD30 8001F130 9718C5FC */ lhu $t8, %lo(gIsGamePaused)($t8)
|
||||
/* 01FD34 8001F134 3C0A8015 */ lui $t2, %hi(D_80152300) # $t2, 0x8015
|
||||
/* 01FD38 8001F138 254A2300 */ addiu $t2, %lo(D_80152300) # addiu $t2, $t2, 0x2300
|
||||
/* 01FD3C 8001F13C 1478000E */ bne $v1, $t8, .L8001F178
|
||||
|
|
@ -228,7 +228,7 @@ glabel func_8001EE98
|
|||
/* 01FDD0 8001F1D0 0010C840 */ sll $t9, $s0, 1
|
||||
/* 01FDD4 8001F1D4 9718F894 */ lhu $t8, %lo(D_8015F894)($t8)
|
||||
/* 01FDD8 8001F1D8 24010002 */ li $at, 2
|
||||
/* 01FDDC 8001F1DC 3C08800E */ lui $t0, %hi(D_800DC5FC) # $t0, 0x800e
|
||||
/* 01FDDC 8001F1DC 3C08800E */ lui $t0, %hi(gIsGamePaused) # $t0, 0x800e
|
||||
/* 01FDE0 8001F1E0 17010005 */ bne $t8, $at, .L8001F1F8
|
||||
.L8001F1E4:
|
||||
/* 01FDE4 8001F1E4 0010C840 */ sll $t9, $s0, 1
|
||||
|
|
@ -238,7 +238,7 @@ glabel func_8001EE98
|
|||
/* 01FDF0 8001F1F0 1000001E */ b .L8001F26C
|
||||
/* 01FDF4 8001F1F4 A4222300 */ sh $v0, %lo(D_80152300)($at) # 0x2300
|
||||
.L8001F1F8:
|
||||
/* 01FDF8 8001F1F8 9508C5FC */ lhu $t0, %lo(D_800DC5FC)($t0)
|
||||
/* 01FDF8 8001F1F8 9508C5FC */ lhu $t0, %lo(gIsGamePaused)($t0)
|
||||
/* 01FDFC 8001F1FC 3C0C8015 */ lui $t4, %hi(D_80152300) # $t4, 0x8015
|
||||
/* 01FE00 8001F200 258C2300 */ addiu $t4, %lo(D_80152300) # addiu $t4, $t4, 0x2300
|
||||
/* 01FE04 8001F204 1468000E */ bne $v1, $t0, .L8001F240
|
||||
|
|
@ -270,8 +270,8 @@ glabel func_8001EE98
|
|||
/* 01FE64 8001F264 240D0001 */ li $t5, 1
|
||||
/* 01FE68 8001F268 A48D0000 */ sh $t5, ($a0)
|
||||
.L8001F26C:
|
||||
/* 01FE6C 8001F26C 3C0E800E */ lui $t6, %hi(D_800DC5FC) # $t6, 0x800e
|
||||
/* 01FE70 8001F270 95CEC5FC */ lhu $t6, %lo(D_800DC5FC)($t6)
|
||||
/* 01FE6C 8001F26C 3C0E800E */ lui $t6, %hi(gIsGamePaused) # $t6, 0x800e
|
||||
/* 01FE70 8001F270 95CEC5FC */ lhu $t6, %lo(gIsGamePaused)($t6)
|
||||
/* 01FE74 8001F274 3C188015 */ lui $t8, %hi(D_80152300) # $t8, 0x8015
|
||||
/* 01FE78 8001F278 27182300 */ addiu $t8, %lo(D_80152300) # addiu $t8, $t8, 0x2300
|
||||
/* 01FE7C 8001F27C 15C00040 */ bnez $t6, .L8001F380
|
||||
|
|
|
|||
|
|
@ -114,8 +114,8 @@ glabel func_8000DD78
|
|||
/* 00EB28 8000DF28 02402025 */ move $a0, $s2
|
||||
/* 00EB2C 8000DF2C 0C0AB772 */ jal func_802ADDC8
|
||||
/* 00EB30 8000DF30 A6090044 */ sh $t1, 0x44($s0)
|
||||
/* 00EB34 8000DF34 3C0B8016 */ lui $t3, %hi(D_801641F8) # $t3, 0x8016
|
||||
/* 00EB38 8000DF38 256B41F8 */ addiu $t3, %lo(D_801641F8) # addiu $t3, $t3, 0x41f8
|
||||
/* 00EB34 8000DF34 3C0B8016 */ lui $t3, %hi(gUnexpiredActorsList) # $t3, 0x8016
|
||||
/* 00EB38 8000DF38 256B41F8 */ addiu $t3, %lo(gUnexpiredActorsList) # addiu $t3, $t3, 0x41f8
|
||||
/* 00EB3C 8000DF3C 26520040 */ addiu $s2, $s2, 0x40
|
||||
/* 00EB40 8000DF40 26730018 */ addiu $s3, $s3, 0x18
|
||||
/* 00EB44 8000DF44 164BFFAC */ bne $s2, $t3, .L8000DDF8
|
||||
|
|
|
|||
|
|
@ -1,83 +0,0 @@
|
|||
glabel func_80027DA8
|
||||
/* 0289A8 80027DA8 3C188016 */ lui $t8, %hi(D_8015F890) # $t8, 0x8016
|
||||
/* 0289AC 80027DAC 9718F890 */ lhu $t8, %lo(D_8015F890)($t8)
|
||||
/* 0289B0 80027DB0 27BDFFE8 */ addiu $sp, $sp, -0x18
|
||||
/* 0289B4 80027DB4 00057600 */ sll $t6, $a1, 0x18
|
||||
/* 0289B8 80027DB8 000E7E03 */ sra $t7, $t6, 0x18
|
||||
/* 0289BC 80027DBC AFA5001C */ sw $a1, 0x1c($sp)
|
||||
/* 0289C0 80027DC0 24030001 */ li $v1, 1
|
||||
/* 0289C4 80027DC4 01E02825 */ move $a1, $t7
|
||||
/* 0289C8 80027DC8 AFBF0014 */ sw $ra, 0x14($sp)
|
||||
/* 0289CC 80027DCC 10780021 */ beq $v1, $t8, .L80027E54
|
||||
/* 0289D0 80027DD0 00803025 */ move $a2, $a0
|
||||
/* 0289D4 80027DD4 94820000 */ lhu $v0, ($a0)
|
||||
/* 0289D8 80027DD8 24010010 */ li $at, 16
|
||||
/* 0289DC 80027DDC 3C088019 */ lui $t0, %hi(D_8018D168) # $t0, 0x8019
|
||||
/* 0289E0 80027DE0 30590010 */ andi $t9, $v0, 0x10
|
||||
/* 0289E4 80027DE4 5321003A */ beql $t9, $at, .L80027ED0
|
||||
/* 0289E8 80027DE8 8FBF0014 */ lw $ra, 0x14($sp)
|
||||
/* 0289EC 80027DEC 8D08D168 */ lw $t0, %lo(D_8018D168)($t0)
|
||||
/* 0289F0 80027DF0 30494000 */ andi $t1, $v0, 0x4000
|
||||
/* 0289F4 80027DF4 24014000 */ li $at, 16384
|
||||
/* 0289F8 80027DF8 1468000D */ bne $v1, $t0, .L80027E30
|
||||
/* 0289FC 80027DFC 304D2000 */ andi $t5, $v0, 0x2000
|
||||
/* 028A00 80027E00 1521000B */ bne $t1, $at, .L80027E30
|
||||
/* 028A04 80027E04 304A0100 */ andi $t2, $v0, 0x100
|
||||
/* 028A08 80027E08 24010100 */ li $at, 256
|
||||
/* 028A0C 80027E0C 11410008 */ beq $t2, $at, .L80027E30
|
||||
/* 028A10 80027E10 31E400FF */ andi $a0, $t7, 0xff
|
||||
/* 028A14 80027E14 0C032529 */ jal func_800C94A4
|
||||
/* 028A18 80027E18 AFA60018 */ sw $a2, 0x18($sp)
|
||||
/* 028A1C 80027E1C 8FA60018 */ lw $a2, 0x18($sp)
|
||||
/* 028A20 80027E20 94CB0000 */ lhu $t3, ($a2)
|
||||
/* 028A24 80027E24 356C0010 */ ori $t4, $t3, 0x10
|
||||
/* 028A28 80027E28 10000028 */ b .L80027ECC
|
||||
/* 028A2C 80027E2C A4CC0000 */ sh $t4, ($a2)
|
||||
.L80027E30:
|
||||
/* 028A30 80027E30 15A00026 */ bnez $t5, .L80027ECC
|
||||
/* 028A34 80027E34 30A400FF */ andi $a0, $a1, 0xff
|
||||
/* 028A38 80027E38 0C0326A2 */ jal func_800C9A88
|
||||
/* 028A3C 80027E3C AFA60018 */ sw $a2, 0x18($sp)
|
||||
/* 028A40 80027E40 8FA60018 */ lw $a2, 0x18($sp)
|
||||
/* 028A44 80027E44 94CE0000 */ lhu $t6, ($a2)
|
||||
/* 028A48 80027E48 35CF0010 */ ori $t7, $t6, 0x10
|
||||
/* 028A4C 80027E4C 1000001F */ b .L80027ECC
|
||||
/* 028A50 80027E50 A4CF0000 */ sh $t7, ($a2)
|
||||
.L80027E54:
|
||||
/* 028A54 80027E54 94C20000 */ lhu $v0, ($a2)
|
||||
/* 028A58 80027E58 24010010 */ li $at, 16
|
||||
/* 028A5C 80027E5C 3C198019 */ lui $t9, %hi(D_8018D168) # $t9, 0x8019
|
||||
/* 028A60 80027E60 30580010 */ andi $t8, $v0, 0x10
|
||||
/* 028A64 80027E64 5301001A */ beql $t8, $at, .L80027ED0
|
||||
/* 028A68 80027E68 8FBF0014 */ lw $ra, 0x14($sp)
|
||||
/* 028A6C 80027E6C 8F39D168 */ lw $t9, %lo(D_8018D168)($t9)
|
||||
/* 028A70 80027E70 3C08800E */ lui $t0, %hi(gPlayerOne) # $t0, 0x800e
|
||||
/* 028A74 80027E74 304B2000 */ andi $t3, $v0, 0x2000
|
||||
/* 028A78 80027E78 1479000C */ bne $v1, $t9, .L80027EAC
|
||||
/* 028A7C 80027E7C 00000000 */ nop
|
||||
/* 028A80 80027E80 8D08C4DC */ lw $t0, %lo(gPlayerOne)($t0)
|
||||
/* 028A84 80027E84 30A400FF */ andi $a0, $a1, 0xff
|
||||
/* 028A88 80027E88 14C80008 */ bne $a2, $t0, .L80027EAC
|
||||
/* 028A8C 80027E8C 00000000 */ nop
|
||||
/* 028A90 80027E90 0C032529 */ jal func_800C94A4
|
||||
/* 028A94 80027E94 AFA60018 */ sw $a2, 0x18($sp)
|
||||
/* 028A98 80027E98 8FA60018 */ lw $a2, 0x18($sp)
|
||||
/* 028A9C 80027E9C 94C90000 */ lhu $t1, ($a2)
|
||||
/* 028AA0 80027EA0 352A0010 */ ori $t2, $t1, 0x10
|
||||
/* 028AA4 80027EA4 10000009 */ b .L80027ECC
|
||||
/* 028AA8 80027EA8 A4CA0000 */ sh $t2, ($a2)
|
||||
.L80027EAC:
|
||||
/* 028AAC 80027EAC 15600007 */ bnez $t3, .L80027ECC
|
||||
/* 028AB0 80027EB0 30A400FF */ andi $a0, $a1, 0xff
|
||||
/* 028AB4 80027EB4 0C0326A2 */ jal func_800C9A88
|
||||
/* 028AB8 80027EB8 AFA60018 */ sw $a2, 0x18($sp)
|
||||
/* 028ABC 80027EBC 8FA60018 */ lw $a2, 0x18($sp)
|
||||
/* 028AC0 80027EC0 94CC0000 */ lhu $t4, ($a2)
|
||||
/* 028AC4 80027EC4 358D0010 */ ori $t5, $t4, 0x10
|
||||
/* 028AC8 80027EC8 A4CD0000 */ sh $t5, ($a2)
|
||||
.L80027ECC:
|
||||
/* 028ACC 80027ECC 8FBF0014 */ lw $ra, 0x14($sp)
|
||||
.L80027ED0:
|
||||
/* 028AD0 80027ED0 27BD0018 */ addiu $sp, $sp, 0x18
|
||||
/* 028AD4 80027ED4 03E00008 */ jr $ra
|
||||
/* 028AD8 80027ED8 00000000 */ nop
|
||||
|
|
@ -1,269 +0,0 @@
|
|||
glabel func_80028864
|
||||
/* 029464 80028864 27BDFFE0 */ addiu $sp, $sp, -0x20
|
||||
/* 029468 80028868 AFBF0014 */ sw $ra, 0x14($sp)
|
||||
/* 02946C 8002886C AFA50024 */ sw $a1, 0x24($sp)
|
||||
/* 029470 80028870 AFA60028 */ sw $a2, 0x28($sp)
|
||||
/* 029474 80028874 AFA7002C */ sw $a3, 0x2c($sp)
|
||||
/* 029478 80028878 94820000 */ lhu $v0, ($a0)
|
||||
/* 02947C 8002887C 24010200 */ li $at, 512
|
||||
/* 029480 80028880 304E2000 */ andi $t6, $v0, 0x2000
|
||||
/* 029484 80028884 55C000CD */ bnel $t6, $zero, .L80028BBC
|
||||
/* 029488 80028888 304E0200 */ andi $t6, $v0, 0x200
|
||||
/* 02948C 8002888C 3C02800E */ lui $v0, %hi(gActiveScreenMode) # $v0, 0x800e
|
||||
/* 029490 80028890 8C42C52C */ lw $v0, %lo(gActiveScreenMode)($v0)
|
||||
/* 029494 80028894 24030001 */ li $v1, 1
|
||||
/* 029498 80028898 3C0F8016 */ lui $t7, %hi(D_8016557C) # $t7, 0x8016
|
||||
/* 02949C 8002889C 10400009 */ beqz $v0, .L800288C4
|
||||
/* 0294A0 800288A0 00000000 */ nop
|
||||
/* 0294A4 800288A4 10430015 */ beq $v0, $v1, .L800288FC
|
||||
/* 0294A8 800288A8 24010002 */ li $at, 2
|
||||
/* 0294AC 800288AC 10410013 */ beq $v0, $at, .L800288FC
|
||||
/* 0294B0 800288B0 24010003 */ li $at, 3
|
||||
/* 0294B4 800288B4 10410031 */ beq $v0, $at, .L8002897C
|
||||
/* 0294B8 800288B8 3C088016 */ lui $t0, %hi(D_8016557C) # $t0, 0x8016
|
||||
/* 0294BC 800288BC 10000070 */ b .L80028A80
|
||||
/* 0294C0 800288C0 97AC001E */ lhu $t4, 0x1e($sp)
|
||||
.L800288C4:
|
||||
/* 0294C4 800288C4 85EF557C */ lh $t7, %lo(D_8016557C)($t7)
|
||||
/* 0294C8 800288C8 3C05800E */ lui $a1, %hi(camera1) # $a1, 0x800e
|
||||
/* 0294CC 800288CC 8CA5DB40 */ lw $a1, %lo(camera1)($a1)
|
||||
/* 0294D0 800288D0 448F2000 */ mtc1 $t7, $f4
|
||||
/* 0294D4 800288D4 24070000 */ li $a3, 0
|
||||
/* 0294D8 800288D8 AFA40020 */ sw $a0, 0x20($sp)
|
||||
/* 0294DC 800288DC 46802120 */ cvt.s.w $f4, $f4
|
||||
/* 0294E0 800288E0 44062000 */ mfc1 $a2, $f4
|
||||
/* 0294E4 800288E4 0C007EC3 */ jal func_8001FB0C
|
||||
/* 0294E8 800288E8 00000000 */ nop
|
||||
/* 0294EC 800288EC 8FA40020 */ lw $a0, 0x20($sp)
|
||||
/* 0294F0 800288F0 A7A2001E */ sh $v0, 0x1e($sp)
|
||||
/* 0294F4 800288F4 10000061 */ b .L80028A7C
|
||||
/* 0294F8 800288F8 24030001 */ li $v1, 1
|
||||
.L800288FC:
|
||||
/* 0294FC 800288FC 3C188016 */ lui $t8, %hi(D_8016557C) # $t8, 0x8016
|
||||
/* 029500 80028900 8718557C */ lh $t8, %lo(D_8016557C)($t8)
|
||||
/* 029504 80028904 3C05800E */ lui $a1, %hi(camera1) # $a1, 0x800e
|
||||
/* 029508 80028908 8CA5DB40 */ lw $a1, %lo(camera1)($a1)
|
||||
/* 02950C 8002890C 44983000 */ mtc1 $t8, $f6
|
||||
/* 029510 80028910 24070000 */ li $a3, 0
|
||||
/* 029514 80028914 AFA40020 */ sw $a0, 0x20($sp)
|
||||
/* 029518 80028918 468031A0 */ cvt.s.w $f6, $f6
|
||||
/* 02951C 8002891C 44063000 */ mfc1 $a2, $f6
|
||||
/* 029520 80028920 0C007EC3 */ jal func_8001FB0C
|
||||
/* 029524 80028924 00000000 */ nop
|
||||
/* 029528 80028928 24010001 */ li $at, 1
|
||||
/* 02952C 8002892C 8FA40020 */ lw $a0, 0x20($sp)
|
||||
/* 029530 80028930 14410003 */ bne $v0, $at, .L80028940
|
||||
/* 029534 80028934 A7A2001E */ sh $v0, 0x1e($sp)
|
||||
/* 029538 80028938 10000050 */ b .L80028A7C
|
||||
/* 02953C 8002893C 24030001 */ li $v1, 1
|
||||
.L80028940:
|
||||
/* 029540 80028940 3C198016 */ lui $t9, %hi(D_8016557C) # $t9, 0x8016
|
||||
/* 029544 80028944 8739557C */ lh $t9, %lo(D_8016557C)($t9)
|
||||
/* 029548 80028948 3C05800E */ lui $a1, %hi(camera2) # $a1, 0x800e
|
||||
/* 02954C 8002894C 8CA5DB44 */ lw $a1, %lo(camera2)($a1)
|
||||
/* 029550 80028950 44994000 */ mtc1 $t9, $f8
|
||||
/* 029554 80028954 24070000 */ li $a3, 0
|
||||
/* 029558 80028958 AFA40020 */ sw $a0, 0x20($sp)
|
||||
/* 02955C 8002895C 46804220 */ cvt.s.w $f8, $f8
|
||||
/* 029560 80028960 44064000 */ mfc1 $a2, $f8
|
||||
/* 029564 80028964 0C007EC3 */ jal func_8001FB0C
|
||||
/* 029568 80028968 00000000 */ nop
|
||||
/* 02956C 8002896C 8FA40020 */ lw $a0, 0x20($sp)
|
||||
/* 029570 80028970 A7A2001E */ sh $v0, 0x1e($sp)
|
||||
/* 029574 80028974 10000041 */ b .L80028A7C
|
||||
/* 029578 80028978 24030001 */ li $v1, 1
|
||||
.L8002897C:
|
||||
/* 02957C 8002897C 8508557C */ lh $t0, %lo(D_8016557C)($t0)
|
||||
/* 029580 80028980 3C05800E */ lui $a1, %hi(camera1) # $a1, 0x800e
|
||||
/* 029584 80028984 8CA5DB40 */ lw $a1, %lo(camera1)($a1)
|
||||
/* 029588 80028988 44885000 */ mtc1 $t0, $f10
|
||||
/* 02958C 8002898C 24070000 */ li $a3, 0
|
||||
/* 029590 80028990 AFA40020 */ sw $a0, 0x20($sp)
|
||||
/* 029594 80028994 468052A0 */ cvt.s.w $f10, $f10
|
||||
/* 029598 80028998 44065000 */ mfc1 $a2, $f10
|
||||
/* 02959C 8002899C 0C007EC3 */ jal func_8001FB0C
|
||||
/* 0295A0 800289A0 00000000 */ nop
|
||||
/* 0295A4 800289A4 24010001 */ li $at, 1
|
||||
/* 0295A8 800289A8 8FA40020 */ lw $a0, 0x20($sp)
|
||||
/* 0295AC 800289AC 14410003 */ bne $v0, $at, .L800289BC
|
||||
/* 0295B0 800289B0 A7A2001E */ sh $v0, 0x1e($sp)
|
||||
/* 0295B4 800289B4 10000031 */ b .L80028A7C
|
||||
/* 0295B8 800289B8 24030001 */ li $v1, 1
|
||||
.L800289BC:
|
||||
/* 0295BC 800289BC 3C098016 */ lui $t1, %hi(D_8016557C) # $t1, 0x8016
|
||||
/* 0295C0 800289C0 8529557C */ lh $t1, %lo(D_8016557C)($t1)
|
||||
/* 0295C4 800289C4 3C05800E */ lui $a1, %hi(camera2) # $a1, 0x800e
|
||||
/* 0295C8 800289C8 8CA5DB44 */ lw $a1, %lo(camera2)($a1)
|
||||
/* 0295CC 800289CC 44898000 */ mtc1 $t1, $f16
|
||||
/* 0295D0 800289D0 24070000 */ li $a3, 0
|
||||
/* 0295D4 800289D4 AFA40020 */ sw $a0, 0x20($sp)
|
||||
/* 0295D8 800289D8 46808420 */ cvt.s.w $f16, $f16
|
||||
/* 0295DC 800289DC 44068000 */ mfc1 $a2, $f16
|
||||
/* 0295E0 800289E0 0C007EC3 */ jal func_8001FB0C
|
||||
/* 0295E4 800289E4 00000000 */ nop
|
||||
/* 0295E8 800289E8 24010001 */ li $at, 1
|
||||
/* 0295EC 800289EC 8FA40020 */ lw $a0, 0x20($sp)
|
||||
/* 0295F0 800289F0 14410003 */ bne $v0, $at, .L80028A00
|
||||
/* 0295F4 800289F4 A7A2001E */ sh $v0, 0x1e($sp)
|
||||
/* 0295F8 800289F8 10000020 */ b .L80028A7C
|
||||
/* 0295FC 800289FC 24030001 */ li $v1, 1
|
||||
.L80028A00:
|
||||
/* 029600 80028A00 3C0A8016 */ lui $t2, %hi(D_8016557C) # $t2, 0x8016
|
||||
/* 029604 80028A04 854A557C */ lh $t2, %lo(D_8016557C)($t2)
|
||||
/* 029608 80028A08 3C05800E */ lui $a1, %hi(camera3) # $a1, 0x800e
|
||||
/* 02960C 80028A0C 8CA5DB48 */ lw $a1, %lo(camera3)($a1)
|
||||
/* 029610 80028A10 448A9000 */ mtc1 $t2, $f18
|
||||
/* 029614 80028A14 24070000 */ li $a3, 0
|
||||
/* 029618 80028A18 AFA40020 */ sw $a0, 0x20($sp)
|
||||
/* 02961C 80028A1C 468094A0 */ cvt.s.w $f18, $f18
|
||||
/* 029620 80028A20 44069000 */ mfc1 $a2, $f18
|
||||
/* 029624 80028A24 0C007EC3 */ jal func_8001FB0C
|
||||
/* 029628 80028A28 00000000 */ nop
|
||||
/* 02962C 80028A2C 24010001 */ li $at, 1
|
||||
/* 029630 80028A30 8FA40020 */ lw $a0, 0x20($sp)
|
||||
/* 029634 80028A34 14410003 */ bne $v0, $at, .L80028A44
|
||||
/* 029638 80028A38 A7A2001E */ sh $v0, 0x1e($sp)
|
||||
/* 02963C 80028A3C 1000000F */ b .L80028A7C
|
||||
/* 029640 80028A40 24030001 */ li $v1, 1
|
||||
.L80028A44:
|
||||
/* 029644 80028A44 3C0B8016 */ lui $t3, %hi(D_8016557C) # $t3, 0x8016
|
||||
/* 029648 80028A48 856B557C */ lh $t3, %lo(D_8016557C)($t3)
|
||||
/* 02964C 80028A4C 3C05800E */ lui $a1, %hi(camera4) # $a1, 0x800e
|
||||
/* 029650 80028A50 8CA5DB4C */ lw $a1, %lo(camera4)($a1)
|
||||
/* 029654 80028A54 448B2000 */ mtc1 $t3, $f4
|
||||
/* 029658 80028A58 24070000 */ li $a3, 0
|
||||
/* 02965C 80028A5C AFA40020 */ sw $a0, 0x20($sp)
|
||||
/* 029660 80028A60 46802120 */ cvt.s.w $f4, $f4
|
||||
/* 029664 80028A64 44062000 */ mfc1 $a2, $f4
|
||||
/* 029668 80028A68 0C007EC3 */ jal func_8001FB0C
|
||||
/* 02966C 80028A6C 00000000 */ nop
|
||||
/* 029670 80028A70 8FA40020 */ lw $a0, 0x20($sp)
|
||||
/* 029674 80028A74 A7A2001E */ sh $v0, 0x1e($sp)
|
||||
/* 029678 80028A78 24030001 */ li $v1, 1
|
||||
.L80028A7C:
|
||||
/* 02967C 80028A7C 97AC001E */ lhu $t4, 0x1e($sp)
|
||||
.L80028A80:
|
||||
/* 029680 80028A80 506C001A */ beql $v1, $t4, .L80028AEC
|
||||
/* 029684 80028A84 8C8B00BC */ lw $t3, 0xbc($a0)
|
||||
/* 029688 80028A88 948D0000 */ lhu $t5, ($a0)
|
||||
/* 02968C 80028A8C 24010100 */ li $at, 256
|
||||
/* 029690 80028A90 3C0F800E */ lui $t7, %hi(gModeSelection) # $t7, 0x800e
|
||||
/* 029694 80028A94 31AE0100 */ andi $t6, $t5, 0x100
|
||||
/* 029698 80028A98 51C10014 */ beql $t6, $at, .L80028AEC
|
||||
/* 02969C 80028A9C 8C8B00BC */ lw $t3, 0xbc($a0)
|
||||
/* 0296A0 80028AA0 8DEFC53C */ lw $t7, %lo(gModeSelection)($t7)
|
||||
/* 0296A4 80028AA4 24010003 */ li $at, 3
|
||||
/* 0296A8 80028AA8 51E10010 */ beql $t7, $at, .L80028AEC
|
||||
/* 0296AC 80028AAC 8C8B00BC */ lw $t3, 0xbc($a0)
|
||||
/* 0296B0 80028AB0 848200CA */ lh $v0, 0xca($a0)
|
||||
/* 0296B4 80028AB4 30580002 */ andi $t8, $v0, 2
|
||||
/* 0296B8 80028AB8 1700000B */ bnez $t8, .L80028AE8
|
||||
/* 0296BC 80028ABC 30590008 */ andi $t9, $v0, 8
|
||||
/* 0296C0 80028AC0 17200009 */ bnez $t9, .L80028AE8
|
||||
/* 0296C4 80028AC4 83A8002B */ lb $t0, 0x2b($sp)
|
||||
/* 0296C8 80028AC8 00084840 */ sll $t1, $t0, 1
|
||||
/* 0296CC 80028ACC 3C0A8016 */ lui $t2, %hi(D_801633F8) # 0x8016
|
||||
/* 0296D0 80028AD0 01495021 */ addu $t2, $t2, $t1
|
||||
/* 0296D4 80028AD4 854A33F8 */ lh $t2, %lo(D_801633F8)($t2) # 0x33f8($t2)
|
||||
/* 0296D8 80028AD8 8FA50024 */ lw $a1, 0x24($sp)
|
||||
/* 0296DC 80028ADC 83A6002F */ lb $a2, 0x2f($sp)
|
||||
/* 0296E0 80028AE0 146A0031 */ bne $v1, $t2, .L80028BA8
|
||||
/* 0296E4 80028AE4 00000000 */ nop
|
||||
.L80028AE8:
|
||||
/* 0296E8 80028AE8 8C8B00BC */ lw $t3, 0xbc($a0)
|
||||
.L80028AEC:
|
||||
/* 0296EC 80028AEC 2401EFFF */ li $at, -4097
|
||||
/* 0296F0 80028AF0 01616024 */ and $t4, $t3, $at
|
||||
/* 0296F4 80028AF4 318D0080 */ andi $t5, $t4, 0x80
|
||||
/* 0296F8 80028AF8 24010080 */ li $at, 128
|
||||
/* 0296FC 80028AFC 11A10020 */ beq $t5, $at, .L80028B80
|
||||
/* 029700 80028B00 AC8C00BC */ sw $t4, 0xbc($a0)
|
||||
/* 029704 80028B04 318E0040 */ andi $t6, $t4, 0x40
|
||||
/* 029708 80028B08 24010040 */ li $at, 64
|
||||
/* 02970C 80028B0C 11C1001C */ beq $t6, $at, .L80028B80
|
||||
/* 029710 80028B10 318F0400 */ andi $t7, $t4, 0x400
|
||||
/* 029714 80028B14 24010400 */ li $at, 1024
|
||||
/* 029718 80028B18 11E10019 */ beq $t7, $at, .L80028B80
|
||||
/* 02971C 80028B1C 31984000 */ andi $t8, $t4, 0x4000
|
||||
/* 029720 80028B20 24014000 */ li $at, 16384
|
||||
/* 029724 80028B24 13010016 */ beq $t8, $at, .L80028B80
|
||||
/* 029728 80028B28 3C030008 */ lui $v1, 8
|
||||
/* 02972C 80028B2C 0183C824 */ and $t9, $t4, $v1
|
||||
/* 029730 80028B30 10790013 */ beq $v1, $t9, .L80028B80
|
||||
/* 029734 80028B34 3C030080 */ lui $v1, 0x80
|
||||
/* 029738 80028B38 01834024 */ and $t0, $t4, $v1
|
||||
/* 02973C 80028B3C 10680010 */ beq $v1, $t0, .L80028B80
|
||||
/* 029740 80028B40 3C030100 */ lui $v1, 0x100
|
||||
/* 029744 80028B44 01834824 */ and $t1, $t4, $v1
|
||||
/* 029748 80028B48 1069000D */ beq $v1, $t1, .L80028B80
|
||||
/* 02974C 80028B4C 3C030200 */ lui $v1, 0x200
|
||||
/* 029750 80028B50 01835024 */ and $t2, $t4, $v1
|
||||
/* 029754 80028B54 106A000A */ beq $v1, $t2, .L80028B80
|
||||
/* 029758 80028B58 3C030002 */ lui $v1, 2
|
||||
/* 02975C 80028B5C 01835824 */ and $t3, $t4, $v1
|
||||
/* 029760 80028B60 506B0008 */ beql $v1, $t3, .L80028B84
|
||||
/* 029764 80028B64 8FA50024 */ lw $a1, 0x24($sp)
|
||||
/* 029768 80028B68 848C0044 */ lh $t4, 0x44($a0)
|
||||
/* 02976C 80028B6C 8FA50024 */ lw $a1, 0x24($sp)
|
||||
/* 029770 80028B70 83A6002F */ lb $a2, 0x2f($sp)
|
||||
/* 029774 80028B74 318D0800 */ andi $t5, $t4, 0x800
|
||||
/* 029778 80028B78 11A00007 */ beqz $t5, .L80028B98
|
||||
/* 02977C 80028B7C 00000000 */ nop
|
||||
.L80028B80:
|
||||
/* 029780 80028B80 8FA50024 */ lw $a1, 0x24($sp)
|
||||
.L80028B84:
|
||||
/* 029784 80028B84 83A6002F */ lb $a2, 0x2f($sp)
|
||||
/* 029788 80028B88 0C00B965 */ jal func_8002E594
|
||||
/* 02978C 80028B8C 83A7002B */ lb $a3, 0x2b($sp)
|
||||
/* 029790 80028B90 10000029 */ b .L80028C38
|
||||
/* 029794 80028B94 8FBF0014 */ lw $ra, 0x14($sp)
|
||||
.L80028B98:
|
||||
/* 029798 80028B98 0C00B49A */ jal func_8002D268
|
||||
/* 02979C 80028B9C 83A7002B */ lb $a3, 0x2b($sp)
|
||||
/* 0297A0 80028BA0 10000025 */ b .L80028C38
|
||||
/* 0297A4 80028BA4 8FBF0014 */ lw $ra, 0x14($sp)
|
||||
.L80028BA8:
|
||||
/* 0297A8 80028BA8 0C00BCD7 */ jal control_cpu_movement
|
||||
/* 0297AC 80028BAC 83A7002B */ lb $a3, 0x2b($sp)
|
||||
/* 0297B0 80028BB0 10000021 */ b .L80028C38
|
||||
/* 0297B4 80028BB4 8FBF0014 */ lw $ra, 0x14($sp)
|
||||
/* 0297B8 80028BB8 304E0200 */ andi $t6, $v0, 0x200
|
||||
.L80028BBC:
|
||||
/* 0297BC 80028BBC 15C1000B */ bne $t6, $at, .L80028BEC
|
||||
/* 0297C0 80028BC0 304F0080 */ andi $t7, $v0, 0x80
|
||||
/* 0297C4 80028BC4 83A5002B */ lb $a1, 0x2b($sp)
|
||||
/* 0297C8 80028BC8 0C00B40A */ jal func_8002D028
|
||||
/* 0297CC 80028BCC AFA40020 */ sw $a0, 0x20($sp)
|
||||
/* 0297D0 80028BD0 8FA40020 */ lw $a0, 0x20($sp)
|
||||
/* 0297D4 80028BD4 8FA50024 */ lw $a1, 0x24($sp)
|
||||
/* 0297D8 80028BD8 83A6002F */ lb $a2, 0x2f($sp)
|
||||
/* 0297DC 80028BDC 0C00BDCC */ jal func_8002F730
|
||||
/* 0297E0 80028BE0 83A7002B */ lb $a3, 0x2b($sp)
|
||||
/* 0297E4 80028BE4 10000014 */ b .L80028C38
|
||||
/* 0297E8 80028BE8 8FBF0014 */ lw $ra, 0x14($sp)
|
||||
.L80028BEC:
|
||||
/* 0297EC 80028BEC 11E00007 */ beqz $t7, .L80028C0C
|
||||
/* 0297F0 80028BF0 30584000 */ andi $t8, $v0, 0x4000
|
||||
/* 0297F4 80028BF4 8FA50024 */ lw $a1, 0x24($sp)
|
||||
/* 0297F8 80028BF8 83A6002F */ lb $a2, 0x2f($sp)
|
||||
/* 0297FC 80028BFC 0C00B49A */ jal func_8002D268
|
||||
/* 029800 80028C00 83A7002B */ lb $a3, 0x2b($sp)
|
||||
/* 029804 80028C04 1000000C */ b .L80028C38
|
||||
/* 029808 80028C08 8FBF0014 */ lw $ra, 0x14($sp)
|
||||
.L80028C0C:
|
||||
/* 02980C 80028C0C 24014000 */ li $at, 16384
|
||||
/* 029810 80028C10 13010004 */ beq $t8, $at, .L80028C24
|
||||
/* 029814 80028C14 3C014248 */ li $at, 0x42480000 # 50.000000
|
||||
/* 029818 80028C18 44813000 */ mtc1 $at, $f6
|
||||
/* 02981C 80028C1C 00000000 */ nop
|
||||
/* 029820 80028C20 E486009C */ swc1 $f6, 0x9c($a0)
|
||||
.L80028C24:
|
||||
/* 029824 80028C24 8C9900BC */ lw $t9, 0xbc($a0)
|
||||
/* 029828 80028C28 2401FFF7 */ li $at, -9
|
||||
/* 02982C 80028C2C 03214024 */ and $t0, $t9, $at
|
||||
/* 029830 80028C30 AC8800BC */ sw $t0, 0xbc($a0)
|
||||
/* 029834 80028C34 8FBF0014 */ lw $ra, 0x14($sp)
|
||||
.L80028C38:
|
||||
/* 029838 80028C38 27BD0020 */ addiu $sp, $sp, 0x20
|
||||
/* 02983C 80028C3C 03E00008 */ jr $ra
|
||||
/* 029840 80028C40 00000000 */ nop
|
||||
|
|
@ -1,68 +0,0 @@
|
|||
glabel func_80028C44
|
||||
/* 029844 80028C44 27BDFFE8 */ addiu $sp, $sp, -0x18
|
||||
/* 029848 80028C48 AFBF0014 */ sw $ra, 0x14($sp)
|
||||
/* 02984C 80028C4C AFA60020 */ sw $a2, 0x20($sp)
|
||||
/* 029850 80028C50 AFA70024 */ sw $a3, 0x24($sp)
|
||||
/* 029854 80028C54 948E0000 */ lhu $t6, ($a0)
|
||||
/* 029858 80028C58 31CF2000 */ andi $t7, $t6, 0x2000
|
||||
/* 02985C 80028C5C 55E00030 */ bnel $t7, $zero, .L80028D20
|
||||
/* 029860 80028C60 8C8900BC */ lw $t1, 0xbc($a0)
|
||||
/* 029864 80028C64 8C9800BC */ lw $t8, 0xbc($a0)
|
||||
/* 029868 80028C68 2401EFFF */ li $at, -4097
|
||||
/* 02986C 80028C6C 0301C824 */ and $t9, $t8, $at
|
||||
/* 029870 80028C70 33280080 */ andi $t0, $t9, 0x80
|
||||
/* 029874 80028C74 24010080 */ li $at, 128
|
||||
/* 029878 80028C78 1101001F */ beq $t0, $at, .L80028CF8
|
||||
/* 02987C 80028C7C AC9900BC */ sw $t9, 0xbc($a0)
|
||||
/* 029880 80028C80 33290040 */ andi $t1, $t9, 0x40
|
||||
/* 029884 80028C84 24010040 */ li $at, 64
|
||||
/* 029888 80028C88 1121001B */ beq $t1, $at, .L80028CF8
|
||||
/* 02988C 80028C8C 332A0400 */ andi $t2, $t9, 0x400
|
||||
/* 029890 80028C90 24010400 */ li $at, 1024
|
||||
/* 029894 80028C94 11410018 */ beq $t2, $at, .L80028CF8
|
||||
/* 029898 80028C98 332B4000 */ andi $t3, $t9, 0x4000
|
||||
/* 02989C 80028C9C 24014000 */ li $at, 16384
|
||||
/* 0298A0 80028CA0 11610015 */ beq $t3, $at, .L80028CF8
|
||||
/* 0298A4 80028CA4 3C030008 */ lui $v1, 8
|
||||
/* 0298A8 80028CA8 03236024 */ and $t4, $t9, $v1
|
||||
/* 0298AC 80028CAC 106C0012 */ beq $v1, $t4, .L80028CF8
|
||||
/* 0298B0 80028CB0 3C030080 */ lui $v1, 0x80
|
||||
/* 0298B4 80028CB4 03236824 */ and $t5, $t9, $v1
|
||||
/* 0298B8 80028CB8 106D000F */ beq $v1, $t5, .L80028CF8
|
||||
/* 0298BC 80028CBC 3C030100 */ lui $v1, 0x100
|
||||
/* 0298C0 80028CC0 03237024 */ and $t6, $t9, $v1
|
||||
/* 0298C4 80028CC4 106E000C */ beq $v1, $t6, .L80028CF8
|
||||
/* 0298C8 80028CC8 3C030200 */ lui $v1, 0x200
|
||||
/* 0298CC 80028CCC 03237824 */ and $t7, $t9, $v1
|
||||
/* 0298D0 80028CD0 106F0009 */ beq $v1, $t7, .L80028CF8
|
||||
/* 0298D4 80028CD4 3C030002 */ lui $v1, 2
|
||||
/* 0298D8 80028CD8 0323C024 */ and $t8, $t9, $v1
|
||||
/* 0298DC 80028CDC 50780007 */ beql $v1, $t8, .L80028CFC
|
||||
/* 0298E0 80028CE0 83A60027 */ lb $a2, 0x27($sp)
|
||||
/* 0298E4 80028CE4 84990044 */ lh $t9, 0x44($a0)
|
||||
/* 0298E8 80028CE8 83A60027 */ lb $a2, 0x27($sp)
|
||||
/* 0298EC 80028CEC 33280800 */ andi $t0, $t9, 0x800
|
||||
/* 0298F0 80028CF0 11000006 */ beqz $t0, .L80028D0C
|
||||
/* 0298F4 80028CF4 00000000 */ nop
|
||||
.L80028CF8:
|
||||
/* 0298F8 80028CF8 83A60027 */ lb $a2, 0x27($sp)
|
||||
.L80028CFC:
|
||||
/* 0298FC 80028CFC 0C00B965 */ jal func_8002E594
|
||||
/* 029900 80028D00 83A70023 */ lb $a3, 0x23($sp)
|
||||
/* 029904 80028D04 1000000A */ b .L80028D30
|
||||
/* 029908 80028D08 8FBF0014 */ lw $ra, 0x14($sp)
|
||||
.L80028D0C:
|
||||
/* 02990C 80028D0C 0C00B49A */ jal func_8002D268
|
||||
/* 029910 80028D10 83A70023 */ lb $a3, 0x23($sp)
|
||||
/* 029914 80028D14 10000006 */ b .L80028D30
|
||||
/* 029918 80028D18 8FBF0014 */ lw $ra, 0x14($sp)
|
||||
/* 02991C 80028D1C 8C8900BC */ lw $t1, 0xbc($a0)
|
||||
.L80028D20:
|
||||
/* 029920 80028D20 2401FFF7 */ li $at, -9
|
||||
/* 029924 80028D24 01215024 */ and $t2, $t1, $at
|
||||
/* 029928 80028D28 AC8A00BC */ sw $t2, 0xbc($a0)
|
||||
/* 02992C 80028D2C 8FBF0014 */ lw $ra, 0x14($sp)
|
||||
.L80028D30:
|
||||
/* 029930 80028D30 27BD0018 */ addiu $sp, $sp, 0x18
|
||||
/* 029934 80028D34 03E00008 */ jr $ra
|
||||
/* 029938 80028D38 00000000 */ nop
|
||||
|
|
@ -1,86 +0,0 @@
|
|||
glabel func_80028D3C
|
||||
/* 02993C 80028D3C 27BDFFE8 */ addiu $sp, $sp, -0x18
|
||||
/* 029940 80028D40 AFBF0014 */ sw $ra, 0x14($sp)
|
||||
/* 029944 80028D44 AFA60020 */ sw $a2, 0x20($sp)
|
||||
/* 029948 80028D48 AFA70024 */ sw $a3, 0x24($sp)
|
||||
/* 02994C 80028D4C 948E0000 */ lhu $t6, ($a0)
|
||||
/* 029950 80028D50 3C18800E */ lui $t8, %hi(D_800DC510) # $t8, 0x800e
|
||||
/* 029954 80028D54 31CF2000 */ andi $t7, $t6, 0x2000
|
||||
/* 029958 80028D58 55E00006 */ bnel $t7, $zero, .L80028D74
|
||||
/* 02995C 80028D5C 848200CA */ lh $v0, 0xca($a0)
|
||||
/* 029960 80028D60 8F18C510 */ lw $t8, %lo(D_800DC510)($t8)
|
||||
/* 029964 80028D64 24010005 */ li $at, 5
|
||||
/* 029968 80028D68 5701000E */ bnel $t8, $at, .L80028DA4
|
||||
/* 02996C 80028D6C 8C8A00BC */ lw $t2, 0xbc($a0)
|
||||
/* 029970 80028D70 848200CA */ lh $v0, 0xca($a0)
|
||||
.L80028D74:
|
||||
/* 029974 80028D74 30590002 */ andi $t9, $v0, 2
|
||||
/* 029978 80028D78 17200009 */ bnez $t9, .L80028DA0
|
||||
/* 02997C 80028D7C 30480008 */ andi $t0, $v0, 8
|
||||
/* 029980 80028D80 55000008 */ bnel $t0, $zero, .L80028DA4
|
||||
/* 029984 80028D84 8C8A00BC */ lw $t2, 0xbc($a0)
|
||||
/* 029988 80028D88 8C8200BC */ lw $v0, 0xbc($a0)
|
||||
/* 02998C 80028D8C 3C014F01 */ lui $at, (0x4F010CC0 >> 16) # lui $at, 0x4f01
|
||||
/* 029990 80028D90 34210CC0 */ ori $at, (0x4F010CC0 & 0xFFFF) # ori $at, $at, 0xcc0
|
||||
/* 029994 80028D94 00414824 */ and $t1, $v0, $at
|
||||
/* 029998 80028D98 1120002F */ beqz $t1, .L80028E58
|
||||
/* 02999C 80028D9C 2401FFF7 */ li $at, -9
|
||||
.L80028DA0:
|
||||
/* 0299A0 80028DA0 8C8A00BC */ lw $t2, 0xbc($a0)
|
||||
.L80028DA4:
|
||||
/* 0299A4 80028DA4 2401EFFF */ li $at, -4097
|
||||
/* 0299A8 80028DA8 01415824 */ and $t3, $t2, $at
|
||||
/* 0299AC 80028DAC 316C0080 */ andi $t4, $t3, 0x80
|
||||
/* 0299B0 80028DB0 24010080 */ li $at, 128
|
||||
/* 0299B4 80028DB4 1181001F */ beq $t4, $at, .L80028E34
|
||||
/* 0299B8 80028DB8 AC8B00BC */ sw $t3, 0xbc($a0)
|
||||
/* 0299BC 80028DBC 316D0040 */ andi $t5, $t3, 0x40
|
||||
/* 0299C0 80028DC0 24010040 */ li $at, 64
|
||||
/* 0299C4 80028DC4 11A1001B */ beq $t5, $at, .L80028E34
|
||||
/* 0299C8 80028DC8 316E0400 */ andi $t6, $t3, 0x400
|
||||
/* 0299CC 80028DCC 24010400 */ li $at, 1024
|
||||
/* 0299D0 80028DD0 11C10018 */ beq $t6, $at, .L80028E34
|
||||
/* 0299D4 80028DD4 316F4000 */ andi $t7, $t3, 0x4000
|
||||
/* 0299D8 80028DD8 24014000 */ li $at, 16384
|
||||
/* 0299DC 80028DDC 11E10015 */ beq $t7, $at, .L80028E34
|
||||
/* 0299E0 80028DE0 3C030008 */ lui $v1, 8
|
||||
/* 0299E4 80028DE4 0163C024 */ and $t8, $t3, $v1
|
||||
/* 0299E8 80028DE8 10780012 */ beq $v1, $t8, .L80028E34
|
||||
/* 0299EC 80028DEC 3C030080 */ lui $v1, 0x80
|
||||
/* 0299F0 80028DF0 0163C824 */ and $t9, $t3, $v1
|
||||
/* 0299F4 80028DF4 1079000F */ beq $v1, $t9, .L80028E34
|
||||
/* 0299F8 80028DF8 3C030100 */ lui $v1, 0x100
|
||||
/* 0299FC 80028DFC 01634024 */ and $t0, $t3, $v1
|
||||
/* 029A00 80028E00 1068000C */ beq $v1, $t0, .L80028E34
|
||||
/* 029A04 80028E04 3C030200 */ lui $v1, 0x200
|
||||
/* 029A08 80028E08 01634824 */ and $t1, $t3, $v1
|
||||
/* 029A0C 80028E0C 10690009 */ beq $v1, $t1, .L80028E34
|
||||
/* 029A10 80028E10 3C030002 */ lui $v1, 2
|
||||
/* 029A14 80028E14 01635024 */ and $t2, $t3, $v1
|
||||
/* 029A18 80028E18 506A0007 */ beql $v1, $t2, .L80028E38
|
||||
/* 029A1C 80028E1C 83A60027 */ lb $a2, 0x27($sp)
|
||||
/* 029A20 80028E20 848B0044 */ lh $t3, 0x44($a0)
|
||||
/* 029A24 80028E24 83A60027 */ lb $a2, 0x27($sp)
|
||||
/* 029A28 80028E28 316C0800 */ andi $t4, $t3, 0x800
|
||||
/* 029A2C 80028E2C 11800006 */ beqz $t4, .L80028E48
|
||||
/* 029A30 80028E30 00000000 */ nop
|
||||
.L80028E34:
|
||||
/* 029A34 80028E34 83A60027 */ lb $a2, 0x27($sp)
|
||||
.L80028E38:
|
||||
/* 029A38 80028E38 0C00B965 */ jal func_8002E594
|
||||
/* 029A3C 80028E3C 83A70023 */ lb $a3, 0x23($sp)
|
||||
/* 029A40 80028E40 10000008 */ b .L80028E64
|
||||
/* 029A44 80028E44 8FBF0014 */ lw $ra, 0x14($sp)
|
||||
.L80028E48:
|
||||
/* 029A48 80028E48 0C00B49A */ jal func_8002D268
|
||||
/* 029A4C 80028E4C 83A70023 */ lb $a3, 0x23($sp)
|
||||
/* 029A50 80028E50 10000004 */ b .L80028E64
|
||||
/* 029A54 80028E54 8FBF0014 */ lw $ra, 0x14($sp)
|
||||
.L80028E58:
|
||||
/* 029A58 80028E58 00416824 */ and $t5, $v0, $at
|
||||
/* 029A5C 80028E5C AC8D00BC */ sw $t5, 0xbc($a0)
|
||||
/* 029A60 80028E60 8FBF0014 */ lw $ra, 0x14($sp)
|
||||
.L80028E64:
|
||||
/* 029A64 80028E64 27BD0018 */ addiu $sp, $sp, 0x18
|
||||
/* 029A68 80028E68 03E00008 */ jr $ra
|
||||
/* 029A6C 80028E6C 00000000 */ nop
|
||||
|
|
@ -1,67 +0,0 @@
|
|||
glabel func_80028E70
|
||||
/* 029A70 80028E70 27BDFFE8 */ addiu $sp, $sp, -0x18
|
||||
/* 029A74 80028E74 AFBF0014 */ sw $ra, 0x14($sp)
|
||||
/* 029A78 80028E78 AFA5001C */ sw $a1, 0x1c($sp)
|
||||
/* 029A7C 80028E7C AFA60020 */ sw $a2, 0x20($sp)
|
||||
/* 029A80 80028E80 AFA70024 */ sw $a3, 0x24($sp)
|
||||
/* 029A84 80028E84 94820000 */ lhu $v0, ($a0)
|
||||
/* 029A88 80028E88 34018000 */ li $at, 32768
|
||||
/* 029A8C 80028E8C 3C0F800E */ lui $t7, %hi(gGamestate) # $t7, 0x800e
|
||||
/* 029A90 80028E90 304E8000 */ andi $t6, $v0, 0x8000
|
||||
/* 029A94 80028E94 55C1002E */ bnel $t6, $at, .L80028F50
|
||||
/* 029A98 80028E98 8FBF0014 */ lw $ra, 0x14($sp)
|
||||
/* 029A9C 80028E9C 8DEFC50C */ lw $t7, %lo(gGamestate)($t7)
|
||||
/* 029AA0 80028EA0 24010005 */ li $at, 5
|
||||
/* 029AA4 80028EA4 30582000 */ andi $t8, $v0, 0x2000
|
||||
/* 029AA8 80028EA8 55E1000D */ bnel $t7, $at, .L80028EE0
|
||||
/* 029AAC 80028EAC 83A50023 */ lb $a1, 0x23($sp)
|
||||
/* 029AB0 80028EB0 17000005 */ bnez $t8, .L80028EC8
|
||||
/* 029AB4 80028EB4 83A60027 */ lb $a2, 0x27($sp)
|
||||
/* 029AB8 80028EB8 0C00E31B */ jal func_80038C6C
|
||||
/* 029ABC 80028EBC 83A70023 */ lb $a3, 0x23($sp)
|
||||
/* 029AC0 80028EC0 10000023 */ b .L80028F50
|
||||
/* 029AC4 80028EC4 8FBF0014 */ lw $ra, 0x14($sp)
|
||||
.L80028EC8:
|
||||
/* 029AC8 80028EC8 8C9900BC */ lw $t9, 0xbc($a0)
|
||||
/* 029ACC 80028ECC 2401FFF7 */ li $at, -9
|
||||
/* 029AD0 80028ED0 03214024 */ and $t0, $t9, $at
|
||||
/* 029AD4 80028ED4 1000001D */ b .L80028F4C
|
||||
/* 029AD8 80028ED8 AC8800BC */ sw $t0, 0xbc($a0)
|
||||
/* 029ADC 80028EDC 83A50023 */ lb $a1, 0x23($sp)
|
||||
.L80028EE0:
|
||||
/* 029AE0 80028EE0 0C009F6A */ jal func_80027DA8
|
||||
/* 029AE4 80028EE4 AFA40018 */ sw $a0, 0x18($sp)
|
||||
/* 029AE8 80028EE8 3C02800E */ lui $v0, %hi(gModeSelection) # $v0, 0x800e
|
||||
/* 029AEC 80028EEC 8C42C53C */ lw $v0, %lo(gModeSelection)($v0)
|
||||
/* 029AF0 80028EF0 24010001 */ li $at, 1
|
||||
/* 029AF4 80028EF4 8FA40018 */ lw $a0, 0x18($sp)
|
||||
/* 029AF8 80028EF8 8FA5001C */ lw $a1, 0x1c($sp)
|
||||
/* 029AFC 80028EFC 83A60023 */ lb $a2, 0x23($sp)
|
||||
/* 029B00 80028F00 10410008 */ beq $v0, $at, .L80028F24
|
||||
/* 029B04 80028F04 83A70027 */ lb $a3, 0x27($sp)
|
||||
/* 029B08 80028F08 24010002 */ li $at, 2
|
||||
/* 029B0C 80028F0C 10410005 */ beq $v0, $at, .L80028F24
|
||||
/* 029B10 80028F10 24010003 */ li $at, 3
|
||||
/* 029B14 80028F14 10410007 */ beq $v0, $at, .L80028F34
|
||||
/* 029B18 80028F18 00000000 */ nop
|
||||
/* 029B1C 80028F1C 10000009 */ b .L80028F44
|
||||
/* 029B20 80028F20 00000000 */ nop
|
||||
.L80028F24:
|
||||
/* 029B24 80028F24 0C00A311 */ jal func_80028C44
|
||||
/* 029B28 80028F28 00000000 */ nop
|
||||
/* 029B2C 80028F2C 10000008 */ b .L80028F50
|
||||
/* 029B30 80028F30 8FBF0014 */ lw $ra, 0x14($sp)
|
||||
.L80028F34:
|
||||
/* 029B34 80028F34 0C00A34F */ jal func_80028D3C
|
||||
/* 029B38 80028F38 00000000 */ nop
|
||||
/* 029B3C 80028F3C 10000004 */ b .L80028F50
|
||||
/* 029B40 80028F40 8FBF0014 */ lw $ra, 0x14($sp)
|
||||
.L80028F44:
|
||||
/* 029B44 80028F44 0C00A219 */ jal func_80028864
|
||||
/* 029B48 80028F48 00000000 */ nop
|
||||
.L80028F4C:
|
||||
/* 029B4C 80028F4C 8FBF0014 */ lw $ra, 0x14($sp)
|
||||
.L80028F50:
|
||||
/* 029B50 80028F50 27BD0018 */ addiu $sp, $sp, 0x18
|
||||
/* 029B54 80028F54 03E00008 */ jr $ra
|
||||
/* 029B58 80028F58 00000000 */ nop
|
||||
|
|
@ -1,126 +0,0 @@
|
|||
glabel func_8002BF4C
|
||||
/* 02CB4C 8002BF4C 27BDFFB8 */ addiu $sp, $sp, -0x48
|
||||
/* 02CB50 8002BF50 AFBF002C */ sw $ra, 0x2c($sp)
|
||||
/* 02CB54 8002BF54 AFB40028 */ sw $s4, 0x28($sp)
|
||||
/* 02CB58 8002BF58 AFB30024 */ sw $s3, 0x24($sp)
|
||||
/* 02CB5C 8002BF5C AFB20020 */ sw $s2, 0x20($sp)
|
||||
/* 02CB60 8002BF60 AFB1001C */ sw $s1, 0x1c($sp)
|
||||
/* 02CB64 8002BF64 AFB00018 */ sw $s0, 0x18($sp)
|
||||
/* 02CB68 8002BF68 AFA5004C */ sw $a1, 0x4c($sp)
|
||||
/* 02CB6C 8002BF6C 3C014190 */ li $at, 0x41900000 # 18.000000
|
||||
/* 02CB70 8002BF70 44813000 */ mtc1 $at, $f6
|
||||
/* 02CB74 8002BF74 C4840094 */ lwc1 $f4, 0x94($a0)
|
||||
/* 02CB78 8002BF78 3C014358 */ li $at, 0x43580000 # 216.000000
|
||||
/* 02CB7C 8002BF7C 44815000 */ mtc1 $at, $f10
|
||||
/* 02CB80 8002BF80 46062203 */ div.s $f8, $f4, $f6
|
||||
/* 02CB84 8002BF84 3C014248 */ li $at, 0x42480000 # 50.000000
|
||||
/* 02CB88 8002BF88 44819000 */ mtc1 $at, $f18
|
||||
/* 02CB8C 8002BF8C 3C02800E */ lui $v0, %hi(gPlayerOne) # $v0, 0x800e
|
||||
/* 02CB90 8002BF90 00809025 */ move $s2, $a0
|
||||
/* 02CB94 8002BF94 8C42C4DC */ lw $v0, %lo(gPlayerOne)($v0)
|
||||
/* 02CB98 8002BF98 00003025 */ move $a2, $zero
|
||||
/* 02CB9C 8002BF9C 3C01FFDF */ lui $at, (0xFFDFFFFF >> 16) # lui $at, 0xffdf
|
||||
/* 02CBA0 8002BFA0 460A4402 */ mul.s $f16, $f8, $f10
|
||||
/* 02CBA4 8002BFA4 4612803C */ c.lt.s $f16, $f18
|
||||
/* 02CBA8 8002BFA8 00000000 */ nop
|
||||
/* 02CBAC 8002BFAC 45020008 */ bc1fl .L8002BFD0
|
||||
/* 02CBB0 8002BFB0 8E5800BC */ lw $t8, 0xbc($s2)
|
||||
/* 02CBB4 8002BFB4 8C8E00BC */ lw $t6, 0xbc($a0)
|
||||
/* 02CBB8 8002BFB8 3421FFFF */ ori $at, (0xFFDFFFFF & 0xFFFF) # ori $at, $at, 0xffff
|
||||
/* 02CBBC 8002BFBC A48000E2 */ sh $zero, 0xe2($a0)
|
||||
/* 02CBC0 8002BFC0 01C17824 */ and $t7, $t6, $at
|
||||
/* 02CBC4 8002BFC4 1000004D */ b .L8002C0FC
|
||||
/* 02CBC8 8002BFC8 AC8F00BC */ sw $t7, 0xbc($a0)
|
||||
/* 02CBCC 8002BFCC 8E5800BC */ lw $t8, 0xbc($s2)
|
||||
.L8002BFD0:
|
||||
/* 02CBD0 8002BFD0 3C010020 */ lui $at, 0x20
|
||||
/* 02CBD4 8002BFD4 00008825 */ move $s1, $zero
|
||||
/* 02CBD8 8002BFD8 0301C824 */ and $t9, $t8, $at
|
||||
/* 02CBDC 8002BFDC 1721000D */ bne $t9, $at, .L8002C014
|
||||
/* 02CBE0 8002BFE0 00408025 */ move $s0, $v0
|
||||
/* 02CBE4 8002BFE4 864800E2 */ lh $t0, 0xe2($s2)
|
||||
/* 02CBE8 8002BFE8 2509FFFF */ addiu $t1, $t0, -1
|
||||
/* 02CBEC 8002BFEC A64900E2 */ sh $t1, 0xe2($s2)
|
||||
/* 02CBF0 8002BFF0 864A00E2 */ lh $t2, 0xe2($s2)
|
||||
/* 02CBF4 8002BFF4 5D400042 */ bgtzl $t2, .L8002C100
|
||||
/* 02CBF8 8002BFF8 8FBF002C */ lw $ra, 0x2c($sp)
|
||||
/* 02CBFC 8002BFFC 8E4B00BC */ lw $t3, 0xbc($s2)
|
||||
/* 02CC00 8002C000 3C01FFDF */ lui $at, (0xFFDFFFFF >> 16) # lui $at, 0xffdf
|
||||
/* 02CC04 8002C004 3421FFFF */ ori $at, (0xFFDFFFFF & 0xFFFF) # ori $at, $at, 0xffff
|
||||
/* 02CC08 8002C008 01616024 */ and $t4, $t3, $at
|
||||
/* 02CC0C 8002C00C 1000003B */ b .L8002C0FC
|
||||
/* 02CC10 8002C010 AE4C00BC */ sw $t4, 0xbc($s2)
|
||||
.L8002C014:
|
||||
/* 02CC14 8002C014 24146EC0 */ li $s4, 28352
|
||||
/* 02CC18 8002C018 24130001 */ li $s3, 1
|
||||
.L8002C01C:
|
||||
/* 02CC1C 8002C01C 52500032 */ beql $s2, $s0, .L8002C0E8
|
||||
/* 02CC20 8002C020 26310DD8 */ addiu $s1, $s1, 0xdd8
|
||||
/* 02CC24 8002C024 96020000 */ lhu $v0, ($s0)
|
||||
/* 02CC28 8002C028 304D0100 */ andi $t5, $v0, 0x100
|
||||
/* 02CC2C 8002C02C 15A0002D */ bnez $t5, .L8002C0E4
|
||||
/* 02CC30 8002C030 304E8000 */ andi $t6, $v0, 0x8000
|
||||
/* 02CC34 8002C034 11C0002B */ beqz $t6, .L8002C0E4
|
||||
/* 02CC38 8002C038 02402025 */ move $a0, $s2
|
||||
/* 02CC3C 8002C03C 8E050014 */ lw $a1, 0x14($s0)
|
||||
/* 02CC40 8002C040 8E060018 */ lw $a2, 0x18($s0)
|
||||
/* 02CC44 8002C044 0C007F5E */ jal func_8001FD78
|
||||
/* 02CC48 8002C048 8E07001C */ lw $a3, 0x1c($s0)
|
||||
/* 02CC4C 8002C04C 16620025 */ bne $s3, $v0, .L8002C0E4
|
||||
/* 02CC50 8002C050 00403025 */ move $a2, $v0
|
||||
/* 02CC54 8002C054 864F00E2 */ lh $t7, 0xe2($s2)
|
||||
/* 02CC58 8002C058 24100100 */ li $s0, 256
|
||||
/* 02CC5C 8002C05C 25F80001 */ addiu $t8, $t7, 1
|
||||
/* 02CC60 8002C060 A65800E2 */ sh $t8, 0xe2($s2)
|
||||
/* 02CC64 8002C064 865900E2 */ lh $t9, 0xe2($s2)
|
||||
/* 02CC68 8002C068 2B21003D */ slti $at, $t9, 0x3d
|
||||
/* 02CC6C 8002C06C 14200020 */ bnez $at, .L8002C0F0
|
||||
/* 02CC70 8002C070 00000000 */ nop
|
||||
/* 02CC74 8002C074 8E4800BC */ lw $t0, 0xbc($s2)
|
||||
/* 02CC78 8002C078 96420000 */ lhu $v0, ($s2)
|
||||
/* 02CC7C 8002C07C 3C010020 */ lui $at, 0x20
|
||||
/* 02CC80 8002C080 01014825 */ or $t1, $t0, $at
|
||||
/* 02CC84 8002C084 304A0100 */ andi $t2, $v0, 0x100
|
||||
/* 02CC88 8002C088 AE4900BC */ sw $t1, 0xbc($s2)
|
||||
/* 02CC8C 8002C08C 120A000D */ beq $s0, $t2, .L8002C0C4
|
||||
/* 02CC90 8002C090 01401025 */ move $v0, $t2
|
||||
/* 02CC94 8002C094 96450254 */ lhu $a1, 0x254($s2)
|
||||
/* 02CC98 8002C098 3C012900 */ lui $at, (0x29008001 >> 16) # lui $at, 0x2900
|
||||
/* 02CC9C 8002C09C 34218001 */ ori $at, (0x29008001 & 0xFFFF) # ori $at, $at, 0x8001
|
||||
/* 02CCA0 8002C0A0 00055900 */ sll $t3, $a1, 4
|
||||
/* 02CCA4 8002C0A4 01612821 */ addu $a1, $t3, $at
|
||||
/* 02CCA8 8002C0A8 AFA60030 */ sw $a2, 0x30($sp)
|
||||
/* 02CCAC 8002C0AC 0C03243D */ jal func_800C90F4
|
||||
/* 02CCB0 8002C0B0 93A4004F */ lbu $a0, 0x4f($sp)
|
||||
/* 02CCB4 8002C0B4 96420000 */ lhu $v0, ($s2)
|
||||
/* 02CCB8 8002C0B8 8FA60030 */ lw $a2, 0x30($sp)
|
||||
/* 02CCBC 8002C0BC 304C0100 */ andi $t4, $v0, 0x100
|
||||
/* 02CCC0 8002C0C0 01801025 */ move $v0, $t4
|
||||
.L8002C0C4:
|
||||
/* 02CCC4 8002C0C4 1202000A */ beq $s0, $v0, .L8002C0F0
|
||||
/* 02CCC8 8002C0C8 93A4004F */ lbu $a0, 0x4f($sp)
|
||||
/* 02CCCC 8002C0CC 3C051900 */ lui $a1, (0x19008011 >> 16) # lui $a1, 0x1900
|
||||
/* 02CCD0 8002C0D0 34A58011 */ ori $a1, (0x19008011 & 0xFFFF) # ori $a1, $a1, 0x8011
|
||||
/* 02CCD4 8002C0D4 0C032418 */ jal func_800C9060
|
||||
/* 02CCD8 8002C0D8 AFA60030 */ sw $a2, 0x30($sp)
|
||||
/* 02CCDC 8002C0DC 10000004 */ b .L8002C0F0
|
||||
/* 02CCE0 8002C0E0 8FA60030 */ lw $a2, 0x30($sp)
|
||||
.L8002C0E4:
|
||||
/* 02CCE4 8002C0E4 26310DD8 */ addiu $s1, $s1, 0xdd8
|
||||
.L8002C0E8:
|
||||
/* 02CCE8 8002C0E8 1634FFCC */ bne $s1, $s4, .L8002C01C
|
||||
/* 02CCEC 8002C0EC 26100DD8 */ addiu $s0, $s0, 0xdd8
|
||||
.L8002C0F0:
|
||||
/* 02CCF0 8002C0F0 54C00003 */ bnel $a2, $zero, .L8002C100
|
||||
/* 02CCF4 8002C0F4 8FBF002C */ lw $ra, 0x2c($sp)
|
||||
/* 02CCF8 8002C0F8 A64000E2 */ sh $zero, 0xe2($s2)
|
||||
.L8002C0FC:
|
||||
/* 02CCFC 8002C0FC 8FBF002C */ lw $ra, 0x2c($sp)
|
||||
.L8002C100:
|
||||
/* 02CD00 8002C100 8FB00018 */ lw $s0, 0x18($sp)
|
||||
/* 02CD04 8002C104 8FB1001C */ lw $s1, 0x1c($sp)
|
||||
/* 02CD08 8002C108 8FB20020 */ lw $s2, 0x20($sp)
|
||||
/* 02CD0C 8002C10C 8FB30024 */ lw $s3, 0x24($sp)
|
||||
/* 02CD10 8002C110 8FB40028 */ lw $s4, 0x28($sp)
|
||||
/* 02CD14 8002C114 03E00008 */ jr $ra
|
||||
/* 02CD18 8002C118 27BD0048 */ addiu $sp, $sp, 0x48
|
||||
|
|
@ -1,100 +0,0 @@
|
|||
glabel func_8002C7E4
|
||||
/* 02D3E4 8002C7E4 27BDFFE0 */ addiu $sp, $sp, -0x20
|
||||
/* 02D3E8 8002C7E8 AFBF001C */ sw $ra, 0x1c($sp)
|
||||
/* 02D3EC 8002C7EC AFB00018 */ sw $s0, 0x18($sp)
|
||||
/* 02D3F0 8002C7F0 AFA50024 */ sw $a1, 0x24($sp)
|
||||
/* 02D3F4 8002C7F4 AFA60028 */ sw $a2, 0x28($sp)
|
||||
/* 02D3F8 8002C7F8 94830046 */ lhu $v1, 0x46($a0)
|
||||
/* 02D3FC 8002C7FC 00057600 */ sll $t6, $a1, 0x18
|
||||
/* 02D400 8002C800 0006C600 */ sll $t8, $a2, 0x18
|
||||
/* 02D404 8002C804 24010001 */ li $at, 1
|
||||
/* 02D408 8002C808 30680001 */ andi $t0, $v1, 1
|
||||
/* 02D40C 8002C80C 00183603 */ sra $a2, $t8, 0x18
|
||||
/* 02D410 8002C810 000E2E03 */ sra $a1, $t6, 0x18
|
||||
/* 02D414 8002C814 1101002B */ beq $t0, $at, .L8002C8C4
|
||||
/* 02D418 8002C818 00808025 */ move $s0, $a0
|
||||
/* 02D41C 8002C81C 8C8200BC */ lw $v0, 0xbc($a0)
|
||||
/* 02D420 8002C820 34018000 */ li $at, 32768
|
||||
/* 02D424 8002C824 30498000 */ andi $t1, $v0, 0x8000
|
||||
/* 02D428 8002C828 15210026 */ bne $t1, $at, .L8002C8C4
|
||||
/* 02D42C 8002C82C 304A2000 */ andi $t2, $v0, 0x2000
|
||||
/* 02D430 8002C830 24012000 */ li $at, 8192
|
||||
/* 02D434 8002C834 51410005 */ beql $t2, $at, .L8002C84C
|
||||
/* 02D438 8002C838 860B0044 */ lh $t3, 0x44($s0)
|
||||
/* 02D43C 8002C83C 0C00AE73 */ jal func_8002B9CC
|
||||
/* 02D440 8002C840 00000000 */ nop
|
||||
/* 02D444 8002C844 96030046 */ lhu $v1, 0x46($s0)
|
||||
/* 02D448 8002C848 860B0044 */ lh $t3, 0x44($s0)
|
||||
.L8002C84C:
|
||||
/* 02D44C 8002C84C 96180000 */ lhu $t8, ($s0)
|
||||
/* 02D450 8002C850 346E0001 */ ori $t6, $v1, 1
|
||||
/* 02D454 8002C854 A60E0046 */ sh $t6, 0x46($s0)
|
||||
/* 02D458 8002C858 35CF0008 */ ori $t7, $t6, 8
|
||||
/* 02D45C 8002C85C 24014000 */ li $at, 16384
|
||||
/* 02D460 8002C860 316CFFFE */ andi $t4, $t3, 0xfffe
|
||||
/* 02D464 8002C864 33194000 */ andi $t9, $t8, 0x4000
|
||||
/* 02D468 8002C868 A60C0044 */ sh $t4, 0x44($s0)
|
||||
/* 02D46C 8002C86C 17210005 */ bne $t9, $at, .L8002C884
|
||||
/* 02D470 8002C870 A60F0046 */ sh $t7, 0x46($s0)
|
||||
/* 02D474 8002C874 3C054033 */ lui $a1, (0x40333333 >> 16) # lui $a1, 0x4033
|
||||
/* 02D478 8002C878 34A53333 */ ori $a1, (0x40333333 & 0xFFFF) # ori $a1, $a1, 0x3333
|
||||
/* 02D47C 8002C87C 0C007289 */ jal func_8001CA24
|
||||
/* 02D480 8002C880 02002025 */ move $a0, $s0
|
||||
.L8002C884:
|
||||
/* 02D484 8002C884 96030046 */ lhu $v1, 0x46($s0)
|
||||
/* 02D488 8002C888 24010002 */ li $at, 2
|
||||
/* 02D48C 8002C88C 30680002 */ andi $t0, $v1, 2
|
||||
/* 02D490 8002C890 1501000C */ bne $t0, $at, .L8002C8C4
|
||||
/* 02D494 8002C894 30690004 */ andi $t1, $v1, 4
|
||||
/* 02D498 8002C898 24010004 */ li $at, 4
|
||||
/* 02D49C 8002C89C 11210009 */ beq $t1, $at, .L8002C8C4
|
||||
/* 02D4A0 8002C8A0 346B0004 */ ori $t3, $v1, 4
|
||||
/* 02D4A4 8002C8A4 8E0D00BC */ lw $t5, 0xbc($s0)
|
||||
/* 02D4A8 8002C8A8 A60B0046 */ sh $t3, 0x46($s0)
|
||||
/* 02D4AC 8002C8AC 356C0040 */ ori $t4, $t3, 0x40
|
||||
/* 02D4B0 8002C8B0 31AE2000 */ andi $t6, $t5, 0x2000
|
||||
/* 02D4B4 8002C8B4 11C00003 */ beqz $t6, .L8002C8C4
|
||||
/* 02D4B8 8002C8B8 A60C0046 */ sh $t4, 0x46($s0)
|
||||
/* 02D4BC 8002C8BC 0C023555 */ jal func_8008D554
|
||||
/* 02D4C0 8002C8C0 02002025 */ move $a0, $s0
|
||||
.L8002C8C4:
|
||||
/* 02D4C4 8002C8C4 8E0200BC */ lw $v0, 0xbc($s0)
|
||||
/* 02D4C8 8002C8C8 34018000 */ li $at, 32768
|
||||
/* 02D4CC 8002C8CC 24190001 */ li $t9, 1
|
||||
/* 02D4D0 8002C8D0 304F8000 */ andi $t7, $v0, 0x8000
|
||||
/* 02D4D4 8002C8D4 55E1000B */ bnel $t7, $at, .L8002C904
|
||||
/* 02D4D8 8002C8D8 960A0046 */ lhu $t2, 0x46($s0)
|
||||
/* 02D4DC 8002C8DC 86080044 */ lh $t0, 0x44($s0)
|
||||
/* 02D4E0 8002C8E0 3C01FFFF */ lui $at, (0xFFFF7FFF >> 16) # lui $at, 0xffff
|
||||
/* 02D4E4 8002C8E4 34217FFF */ ori $at, (0xFFFF7FFF & 0xFFFF) # ori $at, $at, 0x7fff
|
||||
/* 02D4E8 8002C8E8 0041C024 */ and $t8, $v0, $at
|
||||
/* 02D4EC 8002C8EC 3109FFFE */ andi $t1, $t0, 0xfffe
|
||||
/* 02D4F0 8002C8F0 AE1800BC */ sw $t8, 0xbc($s0)
|
||||
/* 02D4F4 8002C8F4 A619010C */ sh $t9, 0x10c($s0)
|
||||
/* 02D4F8 8002C8F8 10000011 */ b .L8002C940
|
||||
/* 02D4FC 8002C8FC A6090044 */ sh $t1, 0x44($s0)
|
||||
/* 02D500 8002C900 960A0046 */ lhu $t2, 0x46($s0)
|
||||
.L8002C904:
|
||||
/* 02D504 8002C904 8603010C */ lh $v1, 0x10c($s0)
|
||||
/* 02D508 8002C908 3C01FFFF */ lui $at, (0xFFFF7FFF >> 16) # lui $at, 0xffff
|
||||
/* 02D50C 8002C90C 34217FFF */ ori $at, (0xFFFF7FFF & 0xFFFF) # ori $at, $at, 0x7fff
|
||||
/* 02D510 8002C910 00416024 */ and $t4, $v0, $at
|
||||
/* 02D514 8002C914 314BFFFE */ andi $t3, $t2, 0xfffe
|
||||
/* 02D518 8002C918 A60B0046 */ sh $t3, 0x46($s0)
|
||||
/* 02D51C 8002C91C 18600004 */ blez $v1, .L8002C930
|
||||
/* 02D520 8002C920 AE0C00BC */ sw $t4, 0xbc($s0)
|
||||
/* 02D524 8002C924 246D0001 */ addiu $t5, $v1, 1
|
||||
/* 02D528 8002C928 A60D010C */ sh $t5, 0x10c($s0)
|
||||
/* 02D52C 8002C92C 8603010C */ lh $v1, 0x10c($s0)
|
||||
.L8002C930:
|
||||
/* 02D530 8002C930 2861000A */ slti $at, $v1, 0xa
|
||||
/* 02D534 8002C934 54200003 */ bnel $at, $zero, .L8002C944
|
||||
/* 02D538 8002C938 8FBF001C */ lw $ra, 0x1c($sp)
|
||||
/* 02D53C 8002C93C A600010C */ sh $zero, 0x10c($s0)
|
||||
.L8002C940:
|
||||
/* 02D540 8002C940 8FBF001C */ lw $ra, 0x1c($sp)
|
||||
.L8002C944:
|
||||
/* 02D544 8002C944 8FB00018 */ lw $s0, 0x18($sp)
|
||||
/* 02D548 8002C948 27BD0020 */ addiu $sp, $sp, 0x20
|
||||
/* 02D54C 8002C94C 03E00008 */ jr $ra
|
||||
/* 02D550 8002C950 00000000 */ nop
|
||||
|
|
@ -1,210 +0,0 @@
|
|||
glabel func_8002CD48
|
||||
/* 02D948 8002CD48 27BDFFE0 */ addiu $sp, $sp, -0x20
|
||||
/* 02D94C 8002CD4C AFBF001C */ sw $ra, 0x1c($sp)
|
||||
/* 02D950 8002CD50 AFB00018 */ sw $s0, 0x18($sp)
|
||||
/* 02D954 8002CD54 AFA50024 */ sw $a1, 0x24($sp)
|
||||
/* 02D958 8002CD58 AFA60028 */ sw $a2, 0x28($sp)
|
||||
/* 02D95C 8002CD5C 848200CA */ lh $v0, 0xca($a0)
|
||||
/* 02D960 8002CD60 00067600 */ sll $t6, $a2, 0x18
|
||||
/* 02D964 8002CD64 24010002 */ li $at, 2
|
||||
/* 02D968 8002CD68 30580002 */ andi $t8, $v0, 2
|
||||
/* 02D96C 8002CD6C 000E3603 */ sra $a2, $t6, 0x18
|
||||
/* 02D970 8002CD70 13010004 */ beq $t8, $at, .L8002CD84
|
||||
/* 02D974 8002CD74 00808025 */ move $s0, $a0
|
||||
/* 02D978 8002CD78 30590008 */ andi $t9, $v0, 8
|
||||
/* 02D97C 8002CD7C 24010008 */ li $at, 8
|
||||
/* 02D980 8002CD80 17210003 */ bne $t9, $at, .L8002CD90
|
||||
.L8002CD84:
|
||||
/* 02D984 8002CD84 02002025 */ move $a0, $s0
|
||||
/* 02D988 8002CD88 0C02425C */ jal func_80090970
|
||||
/* 02D98C 8002CD8C 83A50027 */ lb $a1, 0x27($sp)
|
||||
.L8002CD90:
|
||||
/* 02D990 8002CD90 8E0800BC */ lw $t0, 0xbc($s0)
|
||||
/* 02D994 8002CD94 24010800 */ li $at, 2048
|
||||
/* 02D998 8002CD98 31090800 */ andi $t1, $t0, 0x800
|
||||
/* 02D99C 8002CD9C 15210003 */ bne $t1, $at, .L8002CDAC
|
||||
/* 02D9A0 8002CDA0 02002025 */ move $a0, $s0
|
||||
/* 02D9A4 8002CDA4 0C0233AC */ jal func_8008CEB0
|
||||
/* 02D9A8 8002CDA8 83A50027 */ lb $a1, 0x27($sp)
|
||||
.L8002CDAC:
|
||||
/* 02D9AC 8002CDAC 860A0044 */ lh $t2, 0x44($s0)
|
||||
/* 02D9B0 8002CDB0 314B4000 */ andi $t3, $t2, 0x4000
|
||||
/* 02D9B4 8002CDB4 11600003 */ beqz $t3, .L8002CDC4
|
||||
/* 02D9B8 8002CDB8 02002025 */ move $a0, $s0
|
||||
/* 02D9BC 8002CDBC 0C02345C */ jal func_8008D170
|
||||
/* 02D9C0 8002CDC0 83A50027 */ lb $a1, 0x27($sp)
|
||||
.L8002CDC4:
|
||||
/* 02D9C4 8002CDC4 8E0200BC */ lw $v0, 0xbc($s0)
|
||||
/* 02D9C8 8002CDC8 24012000 */ li $at, 8192
|
||||
/* 02D9CC 8002CDCC 304C2000 */ andi $t4, $v0, 0x2000
|
||||
/* 02D9D0 8002CDD0 55810005 */ bnel $t4, $at, .L8002CDE8
|
||||
/* 02D9D4 8002CDD4 3C030010 */ lui $v1, 0x10
|
||||
/* 02D9D8 8002CDD8 0C02352D */ jal func_8008D4B4
|
||||
/* 02D9DC 8002CDDC 02002025 */ move $a0, $s0
|
||||
/* 02D9E0 8002CDE0 8E0200BC */ lw $v0, 0xbc($s0)
|
||||
/* 02D9E4 8002CDE4 3C030010 */ lui $v1, 0x10
|
||||
.L8002CDE8:
|
||||
/* 02D9E8 8002CDE8 00436824 */ and $t5, $v0, $v1
|
||||
/* 02D9EC 8002CDEC 546D0005 */ bnel $v1, $t5, .L8002CE04
|
||||
/* 02D9F0 8002CDF0 304E0004 */ andi $t6, $v0, 4
|
||||
/* 02D9F4 8002CDF4 0C023B70 */ jal func_8008EDC0
|
||||
/* 02D9F8 8002CDF8 02002025 */ move $a0, $s0
|
||||
/* 02D9FC 8002CDFC 8E0200BC */ lw $v0, 0xbc($s0)
|
||||
/* 02DA00 8002CE00 304E0004 */ andi $t6, $v0, 4
|
||||
.L8002CE04:
|
||||
/* 02DA04 8002CE04 24010004 */ li $at, 4
|
||||
/* 02DA08 8002CE08 55C10005 */ bnel $t6, $at, .L8002CE20
|
||||
/* 02DA0C 8002CE0C 3C010400 */ lui $at, 0x400
|
||||
/* 02DA10 8002CE10 0C023C02 */ jal func_8008F008
|
||||
/* 02DA14 8002CE14 02002025 */ move $a0, $s0
|
||||
/* 02DA18 8002CE18 8E0200BC */ lw $v0, 0xbc($s0)
|
||||
/* 02DA1C 8002CE1C 3C010400 */ lui $at, 0x400
|
||||
.L8002CE20:
|
||||
/* 02DA20 8002CE20 00417824 */ and $t7, $v0, $at
|
||||
/* 02DA24 8002CE24 15E10004 */ bne $t7, $at, .L8002CE38
|
||||
/* 02DA28 8002CE28 02002025 */ move $a0, $s0
|
||||
/* 02DA2C 8002CE2C 0C023702 */ jal func_8008DC08
|
||||
/* 02DA30 8002CE30 83A50027 */ lb $a1, 0x27($sp)
|
||||
/* 02DA34 8002CE34 8E0200BC */ lw $v0, 0xbc($s0)
|
||||
.L8002CE38:
|
||||
/* 02DA38 8002CE38 3C034000 */ lui $v1, 0x4000
|
||||
/* 02DA3C 8002CE3C 0043C024 */ and $t8, $v0, $v1
|
||||
/* 02DA40 8002CE40 14780004 */ bne $v1, $t8, .L8002CE54
|
||||
/* 02DA44 8002CE44 02002025 */ move $a0, $s0
|
||||
/* 02DA48 8002CE48 0C023846 */ jal func_8008E118
|
||||
/* 02DA4C 8002CE4C 83A50027 */ lb $a1, 0x27($sp)
|
||||
/* 02DA50 8002CE50 8E0200BC */ lw $v0, 0xbc($s0)
|
||||
.L8002CE54:
|
||||
/* 02DA54 8002CE54 3C030001 */ lui $v1, 1
|
||||
/* 02DA58 8002CE58 0043C824 */ and $t9, $v0, $v1
|
||||
/* 02DA5C 8002CE5C 14790004 */ bne $v1, $t9, .L8002CE70
|
||||
/* 02DA60 8002CE60 02002025 */ move $a0, $s0
|
||||
/* 02DA64 8002CE64 0C023CFD */ jal func_8008F3F4
|
||||
/* 02DA68 8002CE68 83A50027 */ lb $a1, 0x27($sp)
|
||||
/* 02DA6C 8002CE6C 8E0200BC */ lw $v0, 0xbc($s0)
|
||||
.L8002CE70:
|
||||
/* 02DA70 8002CE70 30480200 */ andi $t0, $v0, 0x200
|
||||
/* 02DA74 8002CE74 24010200 */ li $at, 512
|
||||
/* 02DA78 8002CE78 15010004 */ bne $t0, $at, .L8002CE8C
|
||||
/* 02DA7C 8002CE7C 02002025 */ move $a0, $s0
|
||||
/* 02DA80 8002CE80 0C023D94 */ jal func_8008F650
|
||||
/* 02DA84 8002CE84 83A50027 */ lb $a1, 0x27($sp)
|
||||
/* 02DA88 8002CE88 8E0200BC */ lw $v0, 0xbc($s0)
|
||||
.L8002CE8C:
|
||||
/* 02DA8C 8002CE8C 3C038000 */ lui $v1, 0x8000
|
||||
/* 02DA90 8002CE90 00434824 */ and $t1, $v0, $v1
|
||||
/* 02DA94 8002CE94 14690004 */ bne $v1, $t1, .L8002CEA8
|
||||
/* 02DA98 8002CE98 02002025 */ move $a0, $s0
|
||||
/* 02DA9C 8002CE9C 0C023E37 */ jal func_8008F8DC
|
||||
/* 02DAA0 8002CEA0 83A50027 */ lb $a1, 0x27($sp)
|
||||
/* 02DAA4 8002CEA4 8E0200BC */ lw $v0, 0xbc($s0)
|
||||
.L8002CEA8:
|
||||
/* 02DAA8 8002CEA8 3C032000 */ lui $v1, 0x2000
|
||||
/* 02DAAC 8002CEAC 00435024 */ and $t2, $v0, $v1
|
||||
/* 02DAB0 8002CEB0 546A000A */ bnel $v1, $t2, .L8002CEDC
|
||||
/* 02DAB4 8002CEB4 304C0080 */ andi $t4, $v0, 0x80
|
||||
/* 02DAB8 8002CEB8 860B0228 */ lh $t3, 0x228($s0)
|
||||
/* 02DABC 8002CEBC 02002025 */ move $a0, $s0
|
||||
/* 02DAC0 8002CEC0 29610064 */ slti $at, $t3, 0x64
|
||||
/* 02DAC4 8002CEC4 54200005 */ bnel $at, $zero, .L8002CEDC
|
||||
/* 02DAC8 8002CEC8 304C0080 */ andi $t4, $v0, 0x80
|
||||
/* 02DACC 8002CECC 0C00C7D2 */ jal func_80031F48
|
||||
/* 02DAD0 8002CED0 3C054080 */ lui $a1, 0x4080
|
||||
/* 02DAD4 8002CED4 8E0200BC */ lw $v0, 0xbc($s0)
|
||||
/* 02DAD8 8002CED8 304C0080 */ andi $t4, $v0, 0x80
|
||||
.L8002CEDC:
|
||||
/* 02DADC 8002CEDC 24010080 */ li $at, 128
|
||||
/* 02DAE0 8002CEE0 11810003 */ beq $t4, $at, .L8002CEF0
|
||||
/* 02DAE4 8002CEE4 304D0040 */ andi $t5, $v0, 0x40
|
||||
/* 02DAE8 8002CEE8 24010040 */ li $at, 64
|
||||
/* 02DAEC 8002CEEC 15A10004 */ bne $t5, $at, .L8002CF00
|
||||
.L8002CEF0:
|
||||
/* 02DAF0 8002CEF0 02002025 */ move $a0, $s0
|
||||
/* 02DAF4 8002CEF4 0C02327B */ jal func_8008C9EC
|
||||
/* 02DAF8 8002CEF8 83A50027 */ lb $a1, 0x27($sp)
|
||||
/* 02DAFC 8002CEFC 8E0200BC */ lw $v0, 0xbc($s0)
|
||||
.L8002CF00:
|
||||
/* 02DB00 8002CF00 304E0400 */ andi $t6, $v0, 0x400
|
||||
/* 02DB04 8002CF04 24010400 */ li $at, 1024
|
||||
/* 02DB08 8002CF08 15C10004 */ bne $t6, $at, .L8002CF1C
|
||||
/* 02DB0C 8002CF0C 02002025 */ move $a0, $s0
|
||||
/* 02DB10 8002CF10 0C02318B */ jal func_8008C62C
|
||||
/* 02DB14 8002CF14 83A50027 */ lb $a1, 0x27($sp)
|
||||
/* 02DB18 8002CF18 8E0200BC */ lw $v0, 0xbc($s0)
|
||||
.L8002CF1C:
|
||||
/* 02DB1C 8002CF1C 3C030100 */ lui $v1, 0x100
|
||||
/* 02DB20 8002CF20 00437824 */ and $t7, $v0, $v1
|
||||
/* 02DB24 8002CF24 146F0004 */ bne $v1, $t7, .L8002CF38
|
||||
/* 02DB28 8002CF28 02002025 */ move $a0, $s0
|
||||
/* 02DB2C 8002CF2C 0C023929 */ jal func_8008E4A4
|
||||
/* 02DB30 8002CF30 83A50027 */ lb $a1, 0x27($sp)
|
||||
/* 02DB34 8002CF34 8E0200BC */ lw $v0, 0xbc($s0)
|
||||
.L8002CF38:
|
||||
/* 02DB38 8002CF38 3C030200 */ lui $v1, 0x200
|
||||
/* 02DB3C 8002CF3C 0043C024 */ and $t8, $v0, $v1
|
||||
/* 02DB40 8002CF40 14780004 */ bne $v1, $t8, .L8002CF54
|
||||
/* 02DB44 8002CF44 02002025 */ move $a0, $s0
|
||||
/* 02DB48 8002CF48 0C023A36 */ jal func_8008E8D8
|
||||
/* 02DB4C 8002CF4C 83A50027 */ lb $a1, 0x27($sp)
|
||||
/* 02DB50 8002CF50 8E0200BC */ lw $v0, 0xbc($s0)
|
||||
.L8002CF54:
|
||||
/* 02DB54 8002CF54 30594000 */ andi $t9, $v0, 0x4000
|
||||
/* 02DB58 8002CF58 24014000 */ li $at, 16384
|
||||
/* 02DB5C 8002CF5C 17210004 */ bne $t9, $at, .L8002CF70
|
||||
/* 02DB60 8002CF60 02002025 */ move $a0, $s0
|
||||
/* 02DB64 8002CF64 0C023C6E */ jal func_8008F1B8
|
||||
/* 02DB68 8002CF68 83A50027 */ lb $a1, 0x27($sp)
|
||||
/* 02DB6C 8002CF6C 8E0200BC */ lw $v0, 0xbc($s0)
|
||||
.L8002CF70:
|
||||
/* 02DB70 8002CF70 3C030008 */ lui $v1, 8
|
||||
/* 02DB74 8002CF74 00434024 */ and $t0, $v0, $v1
|
||||
/* 02DB78 8002CF78 14680004 */ bne $v1, $t0, .L8002CF8C
|
||||
/* 02DB7C 8002CF7C 02002025 */ move $a0, $s0
|
||||
/* 02DB80 8002CF80 0C0235A6 */ jal func_8008D698
|
||||
/* 02DB84 8002CF84 83A50027 */ lb $a1, 0x27($sp)
|
||||
/* 02DB88 8002CF88 8E0200BC */ lw $v0, 0xbc($s0)
|
||||
.L8002CF8C:
|
||||
/* 02DB8C 8002CF8C 3C030080 */ lui $v1, 0x80
|
||||
/* 02DB90 8002CF90 00434824 */ and $t1, $v0, $v1
|
||||
/* 02DB94 8002CF94 14690006 */ bne $v1, $t1, .L8002CFB0
|
||||
/* 02DB98 8002CF98 02002025 */ move $a0, $s0
|
||||
/* 02DB9C 8002CF9C 0C02362D */ jal func_8008D8B4
|
||||
/* 02DBA0 8002CFA0 83A50027 */ lb $a1, 0x27($sp)
|
||||
/* 02DBA4 8002CFA4 02002025 */ move $a0, $s0
|
||||
/* 02DBA8 8002CFA8 0C00C7D2 */ jal func_80031F48
|
||||
/* 02DBAC 8002CFAC 3C054120 */ lui $a1, 0x4120
|
||||
.L8002CFB0:
|
||||
/* 02DBB0 8002CFB0 3C0A800E */ lui $t2, %hi(D_800DC510) # $t2, 0x800e
|
||||
/* 02DBB4 8002CFB4 8D4AC510 */ lw $t2, %lo(D_800DC510)($t2)
|
||||
/* 02DBB8 8002CFB8 24010005 */ li $at, 5
|
||||
/* 02DBBC 8002CFBC 5141000F */ beql $t2, $at, .L8002CFFC
|
||||
/* 02DBC0 8002CFC0 860D0044 */ lh $t5, 0x44($s0)
|
||||
/* 02DBC4 8002CFC4 8E02000C */ lw $v0, 0xc($s0)
|
||||
/* 02DBC8 8002CFC8 02002025 */ move $a0, $s0
|
||||
/* 02DBCC 8002CFCC 00025940 */ sll $t3, $v0, 5
|
||||
/* 02DBD0 8002CFD0 05630005 */ bgezl $t3, .L8002CFE8
|
||||
/* 02DBD4 8002CFD4 00026100 */ sll $t4, $v0, 4
|
||||
/* 02DBD8 8002CFD8 0C023F19 */ jal func_8008FC64
|
||||
/* 02DBDC 8002CFDC 83A50027 */ lb $a1, 0x27($sp)
|
||||
/* 02DBE0 8002CFE0 8E02000C */ lw $v0, 0xc($s0)
|
||||
/* 02DBE4 8002CFE4 00026100 */ sll $t4, $v0, 4
|
||||
.L8002CFE8:
|
||||
/* 02DBE8 8002CFE8 05810003 */ bgez $t4, .L8002CFF8
|
||||
/* 02DBEC 8002CFEC 02002025 */ move $a0, $s0
|
||||
/* 02DBF0 8002CFF0 0C023F37 */ jal func_8008FCDC
|
||||
/* 02DBF4 8002CFF4 83A50027 */ lb $a1, 0x27($sp)
|
||||
.L8002CFF8:
|
||||
/* 02DBF8 8002CFF8 860D0044 */ lh $t5, 0x44($s0)
|
||||
.L8002CFFC:
|
||||
/* 02DBFC 8002CFFC 02002025 */ move $a0, $s0
|
||||
/* 02DC00 8002D000 31AE0800 */ andi $t6, $t5, 0x800
|
||||
/* 02DC04 8002D004 51C00004 */ beql $t6, $zero, .L8002D018
|
||||
/* 02DC08 8002D008 8FBF001C */ lw $ra, 0x1c($sp)
|
||||
/* 02DC0C 8002D00C 0C0244A6 */ jal func_80091298
|
||||
/* 02DC10 8002D010 83A50027 */ lb $a1, 0x27($sp)
|
||||
/* 02DC14 8002D014 8FBF001C */ lw $ra, 0x1c($sp)
|
||||
.L8002D018:
|
||||
/* 02DC18 8002D018 8FB00018 */ lw $s0, 0x18($sp)
|
||||
/* 02DC1C 8002D01C 27BD0020 */ addiu $sp, $sp, 0x20
|
||||
/* 02DC20 8002D020 03E00008 */ jr $ra
|
||||
/* 02DC24 8002D024 00000000 */ nop
|
||||
|
|
@ -1,54 +0,0 @@
|
|||
glabel func_80033884
|
||||
/* 034484 80033884 8CA20000 */ lw $v0, ($a1)
|
||||
/* 034488 80033888 8FAE0010 */ lw $t6, 0x10($sp)
|
||||
/* 03448C 8003388C 004E082A */ slt $at, $v0, $t6
|
||||
/* 034490 80033890 10200004 */ beqz $at, .L800338A4
|
||||
/* 034494 80033894 000E7823 */ negu $t7, $t6
|
||||
/* 034498 80033898 01E2082A */ slt $at, $t7, $v0
|
||||
/* 03449C 8003389C 14200026 */ bnez $at, .L80033938
|
||||
/* 0344A0 800338A0 00000000 */ nop
|
||||
.L800338A4:
|
||||
/* 0344A4 800338A4 8C830200 */ lw $v1, 0x200($a0)
|
||||
/* 0344A8 800338A8 3C01F000 */ lui $at, 0xf000
|
||||
/* 0344AC 800338AC 2478F800 */ addiu $t8, $v1, -0x800
|
||||
/* 0344B0 800338B0 0301082B */ sltu $at, $t8, $at
|
||||
/* 0344B4 800338B4 00601025 */ move $v0, $v1
|
||||
/* 0344B8 800338B8 AC980200 */ sw $t8, 0x200($a0)
|
||||
/* 0344BC 800338BC 14200003 */ bnez $at, .L800338CC
|
||||
/* 0344C0 800338C0 03001825 */ move $v1, $t8
|
||||
/* 0344C4 800338C4 AC820200 */ sw $v0, 0x200($a0)
|
||||
/* 0344C8 800338C8 00401825 */ move $v1, $v0
|
||||
.L800338CC:
|
||||
/* 0344CC 800338CC 8FA20014 */ lw $v0, 0x14($sp)
|
||||
/* 0344D0 800338D0 0043082A */ slt $at, $v0, $v1
|
||||
/* 0344D4 800338D4 54200004 */ bnel $at, $zero, .L800338E8
|
||||
/* 0344D8 800338D8 8CC20000 */ lw $v0, ($a2)
|
||||
/* 0344DC 800338DC AC820200 */ sw $v0, 0x200($a0)
|
||||
/* 0344E0 800338E0 00401825 */ move $v1, $v0
|
||||
/* 0344E4 800338E4 8CC20000 */ lw $v0, ($a2)
|
||||
.L800338E8:
|
||||
/* 0344E8 800338E8 00E2082A */ slt $at, $a3, $v0
|
||||
/* 0344EC 800338EC 10200004 */ beqz $at, .L80033900
|
||||
/* 0344F0 800338F0 00434021 */ addu $t0, $v0, $v1
|
||||
/* 0344F4 800338F4 0043C823 */ subu $t9, $v0, $v1
|
||||
/* 0344F8 800338F8 10000002 */ b .L80033904
|
||||
/* 0344FC 800338FC ACD90000 */ sw $t9, ($a2)
|
||||
.L80033900:
|
||||
/* 034500 80033900 ACC80000 */ sw $t0, ($a2)
|
||||
.L80033904:
|
||||
/* 034504 80033904 8FA20018 */ lw $v0, 0x18($sp)
|
||||
/* 034508 80033908 C4840090 */ lwc1 $f4, 0x90($a0)
|
||||
/* 03450C 8003390C 44823000 */ mtc1 $v0, $f6
|
||||
/* 034510 80033910 00024823 */ negu $t1, $v0
|
||||
/* 034514 80033914 46803220 */ cvt.s.w $f8, $f6
|
||||
/* 034518 80033918 4608203C */ c.lt.s $f4, $f8
|
||||
/* 03451C 8003391C 00000000 */ nop
|
||||
/* 034520 80033920 45000005 */ bc1f .L80033938
|
||||
/* 034524 80033924 00000000 */ nop
|
||||
/* 034528 80033928 44895000 */ mtc1 $t1, $f10
|
||||
/* 03452C 8003392C 00000000 */ nop
|
||||
/* 034530 80033930 46805420 */ cvt.s.w $f16, $f10
|
||||
/* 034534 80033934 E4900090 */ swc1 $f16, 0x90($a0)
|
||||
.L80033938:
|
||||
/* 034538 80033938 03E00008 */ jr $ra
|
||||
/* 03453C 8003393C 00000000 */ nop
|
||||
|
|
@ -1,40 +0,0 @@
|
|||
|
||||
glabel func_80033940
|
||||
/* 034540 80033940 8C830200 */ lw $v1, 0x200($a0)
|
||||
/* 034544 80033944 3C01F000 */ lui $at, 0xf000
|
||||
/* 034548 80033948 246EF800 */ addiu $t6, $v1, -0x800
|
||||
/* 03454C 8003394C 01C1082B */ sltu $at, $t6, $at
|
||||
/* 034550 80033950 00601025 */ move $v0, $v1
|
||||
/* 034554 80033954 AC8E0200 */ sw $t6, 0x200($a0)
|
||||
/* 034558 80033958 14200003 */ bnez $at, .L80033968
|
||||
/* 03455C 8003395C 01C01825 */ move $v1, $t6
|
||||
/* 034560 80033960 AC820200 */ sw $v0, 0x200($a0)
|
||||
/* 034564 80033964 00401825 */ move $v1, $v0
|
||||
.L80033968:
|
||||
/* 034568 80033968 00E3082A */ slt $at, $a3, $v1
|
||||
/* 03456C 8003396C 54200004 */ bnel $at, $zero, .L80033980
|
||||
/* 034570 80033970 8CA20000 */ lw $v0, ($a1)
|
||||
/* 034574 80033974 AC870200 */ sw $a3, 0x200($a0)
|
||||
/* 034578 80033978 00E01825 */ move $v1, $a3
|
||||
/* 03457C 8003397C 8CA20000 */ lw $v0, ($a1)
|
||||
.L80033980:
|
||||
/* 034580 80033980 00C2082A */ slt $at, $a2, $v0
|
||||
/* 034584 80033984 10200004 */ beqz $at, .L80033998
|
||||
/* 034588 80033988 0043C021 */ addu $t8, $v0, $v1
|
||||
/* 03458C 8003398C 00437823 */ subu $t7, $v0, $v1
|
||||
/* 034590 80033990 10000002 */ b .L8003399C
|
||||
/* 034594 80033994 ACAF0000 */ sw $t7, ($a1)
|
||||
.L80033998:
|
||||
/* 034598 80033998 ACB80000 */ sw $t8, ($a1)
|
||||
.L8003399C:
|
||||
/* 03459C 8003399C C7A00010 */ lwc1 $f0, 0x10($sp)
|
||||
/* 0345A0 800339A0 C4840090 */ lwc1 $f4, 0x90($a0)
|
||||
/* 0345A4 800339A4 4600203C */ c.lt.s $f4, $f0
|
||||
/* 0345A8 800339A8 00000000 */ nop
|
||||
/* 0345AC 800339AC 45000003 */ bc1f .L800339BC
|
||||
/* 0345B0 800339B0 00000000 */ nop
|
||||
/* 0345B4 800339B4 46000187 */ neg.s $f6, $f0
|
||||
/* 0345B8 800339B8 E4860090 */ swc1 $f6, 0x90($a0)
|
||||
.L800339BC:
|
||||
/* 0345BC 800339BC 03E00008 */ jr $ra
|
||||
/* 0345C0 800339C0 00000000 */ nop
|
||||
|
|
@ -1,36 +0,0 @@
|
|||
glabel func_800339C4
|
||||
/* 0345C4 800339C4 27BDFFE8 */ addiu $sp, $sp, -0x18
|
||||
/* 0345C8 800339C8 AFBF0014 */ sw $ra, 0x14($sp)
|
||||
/* 0345CC 800339CC 8C820200 */ lw $v0, 0x200($a0)
|
||||
/* 0345D0 800339D0 3C01F000 */ lui $at, 0xf000
|
||||
/* 0345D4 800339D4 244EF800 */ addiu $t6, $v0, -0x800
|
||||
/* 0345D8 800339D8 01C1082B */ sltu $at, $t6, $at
|
||||
/* 0345DC 800339DC 00401825 */ move $v1, $v0
|
||||
/* 0345E0 800339E0 AC8E0200 */ sw $t6, 0x200($a0)
|
||||
/* 0345E4 800339E4 14200003 */ bnez $at, .L800339F4
|
||||
/* 0345E8 800339E8 01C01025 */ move $v0, $t6
|
||||
/* 0345EC 800339EC AC830200 */ sw $v1, 0x200($a0)
|
||||
/* 0345F0 800339F0 00601025 */ move $v0, $v1
|
||||
.L800339F4:
|
||||
/* 0345F4 800339F4 00E2082A */ slt $at, $a3, $v0
|
||||
/* 0345F8 800339F8 54200004 */ bnel $at, $zero, .L80033A0C
|
||||
/* 0345FC 800339FC 8CA30000 */ lw $v1, ($a1)
|
||||
/* 034600 80033A00 AC870200 */ sw $a3, 0x200($a0)
|
||||
/* 034604 80033A04 00E01025 */ move $v0, $a3
|
||||
/* 034608 80033A08 8CA30000 */ lw $v1, ($a1)
|
||||
.L80033A0C:
|
||||
/* 03460C 80033A0C 00C3082A */ slt $at, $a2, $v1
|
||||
/* 034610 80033A10 10200004 */ beqz $at, .L80033A24
|
||||
/* 034614 80033A14 0062C021 */ addu $t8, $v1, $v0
|
||||
/* 034618 80033A18 00627823 */ subu $t7, $v1, $v0
|
||||
/* 03461C 80033A1C 10000002 */ b .L80033A28
|
||||
/* 034620 80033A20 ACAF0000 */ sw $t7, ($a1)
|
||||
.L80033A24:
|
||||
/* 034624 80033A24 ACB80000 */ sw $t8, ($a1)
|
||||
.L80033A28:
|
||||
/* 034628 80033A28 0C00CE14 */ jal func_80033850
|
||||
/* 03462C 80033A2C 8FA50028 */ lw $a1, 0x28($sp)
|
||||
/* 034630 80033A30 8FBF0014 */ lw $ra, 0x14($sp)
|
||||
/* 034634 80033A34 27BD0018 */ addiu $sp, $sp, 0x18
|
||||
/* 034638 80033A38 03E00008 */ jr $ra
|
||||
/* 03463C 80033A3C 00000000 */ nop
|
||||
|
|
@ -1,47 +0,0 @@
|
|||
glabel func_80033A40
|
||||
/* 034640 80033A40 27BDFFE8 */ addiu $sp, $sp, -0x18
|
||||
/* 034644 80033A44 AFBF0014 */ sw $ra, 0x14($sp)
|
||||
/* 034648 80033A48 8CA20000 */ lw $v0, ($a1)
|
||||
/* 03464C 80033A4C 8FAE0028 */ lw $t6, 0x28($sp)
|
||||
/* 034650 80033A50 004E082A */ slt $at, $v0, $t6
|
||||
/* 034654 80033A54 10200004 */ beqz $at, .L80033A68
|
||||
/* 034658 80033A58 000E7823 */ negu $t7, $t6
|
||||
/* 03465C 80033A5C 01E2082A */ slt $at, $t7, $v0
|
||||
/* 034660 80033A60 5420001C */ bnel $at, $zero, .L80033AD4
|
||||
/* 034664 80033A64 8FBF0014 */ lw $ra, 0x14($sp)
|
||||
.L80033A68:
|
||||
/* 034668 80033A68 8C820200 */ lw $v0, 0x200($a0)
|
||||
/* 03466C 80033A6C 3C01F000 */ lui $at, 0xf000
|
||||
/* 034670 80033A70 2458F800 */ addiu $t8, $v0, -0x800
|
||||
/* 034674 80033A74 0301082B */ sltu $at, $t8, $at
|
||||
/* 034678 80033A78 00401825 */ move $v1, $v0
|
||||
/* 03467C 80033A7C AC980200 */ sw $t8, 0x200($a0)
|
||||
/* 034680 80033A80 14200003 */ bnez $at, .L80033A90
|
||||
/* 034684 80033A84 03001025 */ move $v0, $t8
|
||||
/* 034688 80033A88 AC830200 */ sw $v1, 0x200($a0)
|
||||
/* 03468C 80033A8C 00601025 */ move $v0, $v1
|
||||
.L80033A90:
|
||||
/* 034690 80033A90 8FA3002C */ lw $v1, 0x2c($sp)
|
||||
/* 034694 80033A94 0062082A */ slt $at, $v1, $v0
|
||||
/* 034698 80033A98 54200004 */ bnel $at, $zero, .L80033AAC
|
||||
/* 03469C 80033A9C 8CC30000 */ lw $v1, ($a2)
|
||||
/* 0346A0 80033AA0 AC830200 */ sw $v1, 0x200($a0)
|
||||
/* 0346A4 80033AA4 00601025 */ move $v0, $v1
|
||||
/* 0346A8 80033AA8 8CC30000 */ lw $v1, ($a2)
|
||||
.L80033AAC:
|
||||
/* 0346AC 80033AAC 00E3082A */ slt $at, $a3, $v1
|
||||
/* 0346B0 80033AB0 10200004 */ beqz $at, .L80033AC4
|
||||
/* 0346B4 80033AB4 00624021 */ addu $t0, $v1, $v0
|
||||
/* 0346B8 80033AB8 0062C823 */ subu $t9, $v1, $v0
|
||||
/* 0346BC 80033ABC 10000002 */ b .L80033AC8
|
||||
/* 0346C0 80033AC0 ACD90000 */ sw $t9, ($a2)
|
||||
.L80033AC4:
|
||||
/* 0346C4 80033AC4 ACC80000 */ sw $t0, ($a2)
|
||||
.L80033AC8:
|
||||
/* 0346C8 80033AC8 0C00CE14 */ jal func_80033850
|
||||
/* 0346CC 80033ACC 8FA50030 */ lw $a1, 0x30($sp)
|
||||
/* 0346D0 80033AD0 8FBF0014 */ lw $ra, 0x14($sp)
|
||||
.L80033AD4:
|
||||
/* 0346D4 80033AD4 27BD0018 */ addiu $sp, $sp, 0x18
|
||||
/* 0346D8 80033AD8 03E00008 */ jr $ra
|
||||
/* 0346DC 80033ADC 00000000 */ nop
|
||||
|
|
@ -1,87 +0,0 @@
|
|||
glabel func_800381AC
|
||||
/* 038DAC 800381AC 27BDFFE8 */ addiu $sp, $sp, -0x18
|
||||
/* 038DB0 800381B0 AFBF0014 */ sw $ra, 0x14($sp)
|
||||
/* 038DB4 800381B4 AFA60020 */ sw $a2, 0x20($sp)
|
||||
/* 038DB8 800381B8 94820000 */ lhu $v0, ($a0)
|
||||
/* 038DBC 800381BC 00067600 */ sll $t6, $a2, 0x18
|
||||
/* 038DC0 800381C0 34018000 */ li $at, 32768
|
||||
/* 038DC4 800381C4 30588000 */ andi $t8, $v0, 0x8000
|
||||
/* 038DC8 800381C8 17010040 */ bne $t8, $at, .L800382CC
|
||||
/* 038DCC 800381CC 000E3603 */ sra $a2, $t6, 0x18
|
||||
/* 038DD0 800381D0 30594000 */ andi $t9, $v0, 0x4000
|
||||
/* 038DD4 800381D4 24014000 */ li $at, 16384
|
||||
/* 038DD8 800381D8 1721003C */ bne $t9, $at, .L800382CC
|
||||
/* 038DDC 800381DC 30481000 */ andi $t0, $v0, 0x1000
|
||||
/* 038DE0 800381E0 24011000 */ li $at, 4096
|
||||
/* 038DE4 800381E4 11010039 */ beq $t0, $at, .L800382CC
|
||||
/* 038DE8 800381E8 30492000 */ andi $t1, $v0, 0x2000
|
||||
/* 038DEC 800381EC 24012000 */ li $at, 8192
|
||||
/* 038DF0 800381F0 1121001B */ beq $t1, $at, .L80038260
|
||||
/* 038DF4 800381F4 3C0E8019 */ lui $t6, %hi(D_8018D168) # $t6, 0x8019
|
||||
/* 038DF8 800381F8 848200CA */ lh $v0, 0xca($a0)
|
||||
/* 038DFC 800381FC 24010002 */ li $at, 2
|
||||
/* 038E00 80038200 304A0002 */ andi $t2, $v0, 2
|
||||
/* 038E04 80038204 11410004 */ beq $t2, $at, .L80038218
|
||||
/* 038E08 80038208 304B0008 */ andi $t3, $v0, 8
|
||||
/* 038E0C 8003820C 24010008 */ li $at, 8
|
||||
/* 038E10 80038210 1561000D */ bne $t3, $at, .L80038248
|
||||
/* 038E14 80038214 00000000 */ nop
|
||||
.L80038218:
|
||||
/* 038E18 80038218 94AC0004 */ lhu $t4, 4($a1)
|
||||
/* 038E1C 8003821C 318D8000 */ andi $t5, $t4, 0x8000
|
||||
/* 038E20 80038220 11A00005 */ beqz $t5, .L80038238
|
||||
/* 038E24 80038224 00000000 */ nop
|
||||
/* 038E28 80038228 0C00CB65 */ jal func_80032D94
|
||||
/* 038E2C 8003822C 00000000 */ nop
|
||||
/* 038E30 80038230 10000008 */ b .L80038254
|
||||
/* 038E34 80038234 24020001 */ li $v0, 1
|
||||
.L80038238:
|
||||
/* 038E38 80038238 0C00CCA0 */ jal func_80033280
|
||||
/* 038E3C 8003823C 3C0540A0 */ lui $a1, 0x40A0 # 5.0
|
||||
/* 038E40 80038240 10000004 */ b .L80038254
|
||||
/* 038E44 80038244 24020001 */ li $v0, 1
|
||||
.L80038248:
|
||||
/* 038E48 80038248 0C00DF3F */ jal func_80037CFC
|
||||
/* 038E4C 8003824C 00000000 */ nop
|
||||
/* 038E50 80038250 24020001 */ li $v0, 1
|
||||
.L80038254:
|
||||
/* 038E54 80038254 3C018016 */ lui $at, %hi(D_80164A89) # $at, 0x8016
|
||||
/* 038E58 80038258 1000001C */ b .L800382CC
|
||||
/* 038E5C 8003825C A0224A89 */ sb $v0, %lo(D_80164A89)($at)
|
||||
.L80038260:
|
||||
/* 038E60 80038260 8DCED168 */ lw $t6, %lo(D_8018D168)($t6)
|
||||
/* 038E64 80038264 24020001 */ li $v0, 1
|
||||
/* 038E68 80038268 3C0F8016 */ lui $t7, %hi(D_801656F0) # $t7, 0x8016
|
||||
/* 038E6C 8003826C 544E0018 */ bnel $v0, $t6, .L800382D0
|
||||
/* 038E70 80038270 8FBF0014 */ lw $ra, 0x14($sp)
|
||||
/* 038E74 80038274 85EF56F0 */ lh $t7, %lo(D_801656F0)($t7)
|
||||
/* 038E78 80038278 3C198016 */ lui $t9, %hi(D_801652E0) # $t9, 0x8016
|
||||
/* 038E7C 8003827C 273952E0 */ addiu $t9, %lo(D_801652E0) # addiu $t9, $t9, 0x52e0
|
||||
/* 038E80 80038280 144F0008 */ bne $v0, $t7, .L800382A4
|
||||
/* 038E84 80038284 0006C080 */ sll $t8, $a2, 2
|
||||
/* 038E88 80038288 03191021 */ addu $v0, $t8, $t9
|
||||
/* 038E8C 8003828C 8C480000 */ lw $t0, ($v0)
|
||||
/* 038E90 80038290 3C098019 */ lui $t1, %hi(gRaceFrameCounter) # $t1, 0x8019
|
||||
/* 038E94 80038294 55000004 */ bnel $t0, $zero, .L800382A8
|
||||
/* 038E98 80038298 94AA0004 */ lhu $t2, 4($a1)
|
||||
/* 038E9C 8003829C 8D29D3FC */ lw $t1, %lo(gRaceFrameCounter)($t1)
|
||||
/* 038EA0 800382A0 AC490000 */ sw $t1, ($v0)
|
||||
.L800382A4:
|
||||
/* 038EA4 800382A4 94AA0004 */ lhu $t2, 4($a1)
|
||||
.L800382A8:
|
||||
/* 038EA8 800382A8 314B8000 */ andi $t3, $t2, 0x8000
|
||||
/* 038EAC 800382AC 11600005 */ beqz $t3, .L800382C4
|
||||
/* 038EB0 800382B0 00000000 */ nop
|
||||
/* 038EB4 800382B4 0C00C9C0 */ jal func_80032700
|
||||
/* 038EB8 800382B8 00000000 */ nop
|
||||
/* 038EBC 800382BC 10000004 */ b .L800382D0
|
||||
/* 038EC0 800382C0 8FBF0014 */ lw $ra, 0x14($sp)
|
||||
.L800382C4:
|
||||
/* 038EC4 800382C4 0C00CB2C */ jal func_80032CB0
|
||||
/* 038EC8 800382C8 3C0540A0 */ lui $a1, 0x40a0 # 5.0
|
||||
.L800382CC:
|
||||
/* 038ECC 800382CC 8FBF0014 */ lw $ra, 0x14($sp)
|
||||
.L800382D0:
|
||||
/* 038ED0 800382D0 27BD0018 */ addiu $sp, $sp, 0x18
|
||||
/* 038ED4 800382D4 03E00008 */ jr $ra
|
||||
/* 038ED8 800382D8 00000000 */ nop
|
||||
|
|
@ -1,7 +1,7 @@
|
|||
glabel func_80059AC8
|
||||
/* 05A6C8 80059AC8 27BDFFD0 */ addiu $sp, $sp, -0x30
|
||||
/* 05A6CC 80059ACC 3C0E800E */ lui $t6, %hi(D_800DC5FC) # $t6, 0x800e
|
||||
/* 05A6D0 80059AD0 95CEC5FC */ lhu $t6, %lo(D_800DC5FC)($t6)
|
||||
/* 05A6CC 80059ACC 3C0E800E */ lui $t6, %hi(gIsGamePaused) # $t6, 0x800e
|
||||
/* 05A6D0 80059AD0 95CEC5FC */ lhu $t6, %lo(gIsGamePaused)($t6)
|
||||
/* 05A6D4 80059AD4 AFBF002C */ sw $ra, 0x2c($sp)
|
||||
/* 05A6D8 80059AD8 AFB40028 */ sw $s4, 0x28($sp)
|
||||
/* 05A6DC 80059ADC AFB30024 */ sw $s3, 0x24($sp)
|
||||
|
|
|
|||
|
|
@ -30,8 +30,8 @@ glabel func_8006F824
|
|||
/* 070494 8006F894 A0490000 */ sb $t1, ($v0)
|
||||
/* 070498 8006F898 10800008 */ beqz $a0, .L8006F8BC
|
||||
/* 07049C 8006F89C A04A0001 */ sb $t2, 1($v0)
|
||||
/* 0704A0 8006F8A0 3C0B800E */ lui $t3, %hi(D_800DC5FC) # $t3, 0x800e
|
||||
/* 0704A4 8006F8A4 956BC5FC */ lhu $t3, %lo(D_800DC5FC)($t3)
|
||||
/* 0704A0 8006F8A0 3C0B800E */ lui $t3, %hi(gIsGamePaused) # $t3, 0x800e
|
||||
/* 0704A4 8006F8A4 956BC5FC */ lhu $t3, %lo(gIsGamePaused)($t3)
|
||||
/* 0704A8 8006F8A8 3C044900 */ lui $a0, (0x4900801C >> 16) # lui $a0, 0x4900
|
||||
/* 0704AC 8006F8AC 55600004 */ bnel $t3, $zero, .L8006F8C0
|
||||
/* 0704B0 8006F8B0 8FBF0014 */ lw $ra, 0x14($sp)
|
||||
|
|
|
|||
|
|
@ -48,8 +48,8 @@ glabel func_8009CA6C
|
|||
/* 09D720 8009CB20 AC6F0000 */ sw $t7, ($v1)
|
||||
/* 09D724 8009CB24 10C10006 */ beq $a2, $at, .L8009CB40
|
||||
/* 09D728 8009CB28 AC780004 */ sw $t8, 4($v1)
|
||||
/* 09D72C 8009CB2C 3C19800E */ lui $t9, %hi(D_800DC5FC) # $t9, 0x800e
|
||||
/* 09D730 8009CB30 9739C5FC */ lhu $t9, %lo(D_800DC5FC)($t9)
|
||||
/* 09D72C 8009CB2C 3C19800E */ lui $t9, %hi(gIsGamePaused) # $t9, 0x800e
|
||||
/* 09D730 8009CB30 9739C5FC */ lhu $t9, %lo(gIsGamePaused)($t9)
|
||||
/* 09D734 8009CB34 13200002 */ beqz $t9, .L8009CB40
|
||||
/* 09D738 8009CB38 00000000 */ nop
|
||||
/* 09D73C 8009CB3C 24050001 */ li $a1, 1
|
||||
|
|
|
|||
|
|
@ -169,8 +169,8 @@ glabel L8009D0AC
|
|||
/* 09DCB4 8009D0B4 A3380000 */ sb $t8, ($t9)
|
||||
.L8009D0B8:
|
||||
/* 09DCB8 8009D0B8 10A00002 */ beqz $a1, .L8009D0C4
|
||||
/* 09DCBC 8009D0BC 3C01800E */ lui $at, %hi(D_800DC5FC) # $at, 0x800e
|
||||
/* 09DCC0 8009D0C0 A420C5FC */ sh $zero, %lo(D_800DC5FC)($at)
|
||||
/* 09DCBC 8009D0BC 3C01800E */ lui $at, %hi(gIsGamePaused) # $at, 0x800e
|
||||
/* 09DCC0 8009D0C0 A420C5FC */ sh $zero, %lo(gIsGamePaused)($at)
|
||||
.L8009D0C4:
|
||||
/* 09DCC4 8009D0C4 0C02ABCC */ jal find_8018D9E0_entry
|
||||
/* 09DCC8 8009D0C8 240400BD */ li $a0, 189
|
||||
|
|
|
|||
|
|
@ -1,8 +1,8 @@
|
|||
glabel func_800A4EF8
|
||||
/* 0A5AF8 800A4EF8 27BDFFA8 */ addiu $sp, $sp, -0x58
|
||||
/* 0A5AFC 800A4EFC AFB00038 */ sw $s0, 0x38($sp)
|
||||
/* 0A5B00 800A4F00 3C10800E */ lui $s0, %hi(D_800DC5FC) # $s0, 0x800e
|
||||
/* 0A5B04 800A4F04 2610C5FC */ addiu $s0, %lo(D_800DC5FC) # addiu $s0, $s0, -0x3a04
|
||||
/* 0A5B00 800A4F00 3C10800E */ lui $s0, %hi(gIsGamePaused) # $s0, 0x800e
|
||||
/* 0A5B04 800A4F04 2610C5FC */ addiu $s0, %lo(gIsGamePaused) # addiu $s0, $s0, -0x3a04
|
||||
/* 0A5B08 800A4F08 960E0000 */ lhu $t6, ($s0)
|
||||
/* 0A5B0C 800A4F0C 3C198016 */ lui $t9, %hi(D_8015F480) # $t9, 0x8016
|
||||
/* 0A5B10 800A4F10 2739F480 */ addiu $t9, %lo(D_8015F480) # addiu $t9, $t9, -0xb80
|
||||
|
|
|
|||
|
|
@ -1,8 +1,8 @@
|
|||
glabel func_800A5084
|
||||
/* 0A5C84 800A5084 27BDFFB0 */ addiu $sp, $sp, -0x50
|
||||
/* 0A5C88 800A5088 AFB00034 */ sw $s0, 0x34($sp)
|
||||
/* 0A5C8C 800A508C 3C10800E */ lui $s0, %hi(D_800DC5FC) # $s0, 0x800e
|
||||
/* 0A5C90 800A5090 2610C5FC */ addiu $s0, %lo(D_800DC5FC) # addiu $s0, $s0, -0x3a04
|
||||
/* 0A5C8C 800A508C 3C10800E */ lui $s0, %hi(gIsGamePaused) # $s0, 0x800e
|
||||
/* 0A5C90 800A5090 2610C5FC */ addiu $s0, %lo(gIsGamePaused) # addiu $s0, $s0, -0x3a04
|
||||
/* 0A5C94 800A5094 960E0000 */ lhu $t6, ($s0)
|
||||
/* 0A5C98 800A5098 3C198016 */ lui $t9, %hi(D_8015F480) # $t9, 0x8016
|
||||
/* 0A5C9C 800A509C 2739F480 */ addiu $t9, %lo(D_8015F480) # addiu $t9, $t9, -0xb80
|
||||
|
|
|
|||
|
|
@ -1,8 +1,8 @@
|
|||
glabel func_800A5360
|
||||
/* 0A5F60 800A5360 27BDFFA8 */ addiu $sp, $sp, -0x58
|
||||
/* 0A5F64 800A5364 AFB00038 */ sw $s0, 0x38($sp)
|
||||
/* 0A5F68 800A5368 3C10800E */ lui $s0, %hi(D_800DC5FC) # $s0, 0x800e
|
||||
/* 0A5F6C 800A536C 2610C5FC */ addiu $s0, %lo(D_800DC5FC) # addiu $s0, $s0, -0x3a04
|
||||
/* 0A5F68 800A5368 3C10800E */ lui $s0, %hi(gIsGamePaused) # $s0, 0x800e
|
||||
/* 0A5F6C 800A536C 2610C5FC */ addiu $s0, %lo(gIsGamePaused) # addiu $s0, $s0, -0x3a04
|
||||
/* 0A5F70 800A5370 960E0000 */ lhu $t6, ($s0)
|
||||
/* 0A5F74 800A5374 3C198016 */ lui $t9, %hi(D_8015F480) # $t9, 0x8016
|
||||
/* 0A5F78 800A5378 2739F480 */ addiu $t9, %lo(D_8015F480) # addiu $t9, $t9, -0xb80
|
||||
|
|
|
|||
|
|
@ -1,6 +1,6 @@
|
|||
glabel func_800A54EC
|
||||
/* 0A60EC 800A54EC 3C0B800E */ lui $t3, %hi(D_800DC5FC) # $t3, 0x800e
|
||||
/* 0A60F0 800A54F0 256BC5FC */ addiu $t3, %lo(D_800DC5FC) # addiu $t3, $t3, -0x3a04
|
||||
/* 0A60EC 800A54EC 3C0B800E */ lui $t3, %hi(gIsGamePaused) # $t3, 0x800e
|
||||
/* 0A60F0 800A54F0 256BC5FC */ addiu $t3, %lo(gIsGamePaused) # addiu $t3, $t3, -0x3a04
|
||||
/* 0A60F4 800A54F4 956E0000 */ lhu $t6, ($t3)
|
||||
/* 0A60F8 800A54F8 27BDFFA8 */ addiu $sp, $sp, -0x58
|
||||
/* 0A60FC 800A54FC AFBF0024 */ sw $ra, 0x24($sp)
|
||||
|
|
@ -76,8 +76,8 @@ glabel func_800A54EC
|
|||
/* 0A6214 800A5614 0301C824 */ and $t9, $t8, $at
|
||||
/* 0A6218 800A5618 AC790004 */ sw $t9, 4($v1)
|
||||
/* 0A621C 800A561C 852E0000 */ lh $t6, ($t1)
|
||||
/* 0A6220 800A5620 3C0B800E */ lui $t3, %hi(D_800DC5FC) # $t3, 0x800e
|
||||
/* 0A6224 800A5624 256BC5FC */ addiu $t3, %lo(D_800DC5FC) # addiu $t3, $t3, -0x3a04
|
||||
/* 0A6220 800A5620 3C0B800E */ lui $t3, %hi(gIsGamePaused) # $t3, 0x800e
|
||||
/* 0A6224 800A5624 256BC5FC */ addiu $t3, %lo(gIsGamePaused) # addiu $t3, $t3, -0x3a04
|
||||
/* 0A6228 800A5628 25CC0001 */ addiu $t4, $t6, 1
|
||||
/* 0A622C 800A562C 11400018 */ beqz $t2, .L800A5690
|
||||
/* 0A6230 800A5630 A52C0000 */ sh $t4, ($t1)
|
||||
|
|
|
|||
|
|
@ -1,6 +1,6 @@
|
|||
glabel func_800ADF48
|
||||
/* 0AEB48 800ADF48 3C0E800E */ lui $t6, %hi(D_800DC5FC) # $t6, 0x800e
|
||||
/* 0AEB4C 800ADF4C 95CEC5FC */ lhu $t6, %lo(D_800DC5FC)($t6)
|
||||
/* 0AEB48 800ADF48 3C0E800E */ lui $t6, %hi(gIsGamePaused) # $t6, 0x800e
|
||||
/* 0AEB4C 800ADF4C 95CEC5FC */ lhu $t6, %lo(gIsGamePaused)($t6)
|
||||
/* 0AEB50 800ADF50 27BDFFE0 */ addiu $sp, $sp, -0x20
|
||||
/* 0AEB54 800ADF54 AFBF0014 */ sw $ra, 0x14($sp)
|
||||
/* 0AEB58 800ADF58 11C000AA */ beqz $t6, .L800AE204
|
||||
|
|
@ -27,8 +27,8 @@ glabel L800ADFA0
|
|||
/* 0AEBA4 800ADFA4 AFA50020 */ sw $a1, 0x20($sp)
|
||||
/* 0AEBA8 800ADFA8 14400097 */ bnez $v0, .L800AE208
|
||||
/* 0AEBAC 800ADFAC 8FA50020 */ lw $a1, 0x20($sp)
|
||||
/* 0AEBB0 800ADFB0 3C08800E */ lui $t0, %hi(D_800DC5FC) # $t0, 0x800e
|
||||
/* 0AEBB4 800ADFB4 9508C5FC */ lhu $t0, %lo(D_800DC5FC)($t0)
|
||||
/* 0AEBB0 800ADFB0 3C08800E */ lui $t0, %hi(gIsGamePaused) # $t0, 0x800e
|
||||
/* 0AEBB4 800ADFB4 9508C5FC */ lhu $t0, %lo(gIsGamePaused)($t0)
|
||||
/* 0AEBB8 800ADFB8 3C0B800F */ lui $t3, %hi(gControllers) # $t3, 0x800f
|
||||
/* 0AEBBC 800ADFBC 256B6910 */ addiu $t3, %lo(gControllers) # addiu $t3, $t3, 0x6910
|
||||
/* 0AEBC0 800ADFC0 00084900 */ sll $t1, $t0, 4
|
||||
|
|
@ -146,13 +146,13 @@ glabel L800ADFA0
|
|||
/* 0AED6C 800AE16C 8CA80004 */ lw $t0, 4($a1)
|
||||
/* 0AED70 800AE170 01495021 */ addu $t2, $t2, $t1
|
||||
/* 0AED74 800AE174 814A0B50 */ lb $t2, %lo(D_800F0B50)($t2) # 0xb50($t2)
|
||||
/* 0AED78 800AE178 3C01800E */ lui $at, %hi(D_800DC5FC) # $at, 0x800e
|
||||
/* 0AED78 800AE178 3C01800E */ lui $at, %hi(gIsGamePaused) # $at, 0x800e
|
||||
/* 0AED7C 800AE17C 2404001E */ li $a0, 30
|
||||
/* 0AED80 800AE180 150A0008 */ bne $t0, $t2, .L800AE1A4
|
||||
/* 0AED84 800AE184 00000000 */ nop
|
||||
/* 0AED88 800AE188 ACA00004 */ sw $zero, 4($a1)
|
||||
/* 0AED8C 800AE18C 0C0A37CE */ jal func_8028DF38
|
||||
/* 0AED90 800AE190 A420C5FC */ sh $zero, %lo(D_800DC5FC)($at)
|
||||
/* 0AED90 800AE190 A420C5FC */ sh $zero, %lo(gIsGamePaused)($at)
|
||||
/* 0AED94 800AE194 0C0327E4 */ jal func_800C9F90
|
||||
/* 0AED98 800AE198 00002025 */ move $a0, $zero
|
||||
/* 0AED9C 800AE19C 1000001B */ b .L800AE20C
|
||||
|
|
|
|||
|
|
@ -25,8 +25,8 @@ glabel func_80055164
|
|||
/* 055DC0 800551C0 24640004 */ addiu $a0, $v1, 4
|
||||
/* 055DC4 800551C4 0C010B80 */ jal func_80042E00
|
||||
/* 055DC8 800551C8 246500BE */ addiu $a1, $v1, 0xbe
|
||||
/* 055DCC 800551CC 3C0B800E */ lui $t3, %hi(D_800DC5FC) # $t3, 0x800e
|
||||
/* 055DD0 800551D0 956BC5FC */ lhu $t3, %lo(D_800DC5FC)($t3)
|
||||
/* 055DCC 800551CC 3C0B800E */ lui $t3, %hi(gIsGamePaused) # $t3, 0x800e
|
||||
/* 055DD0 800551D0 956BC5FC */ lhu $t3, %lo(gIsGamePaused)($t3)
|
||||
/* 055DD4 800551D4 8FA30018 */ lw $v1, 0x18($sp)
|
||||
/* 055DD8 800551D8 00003025 */ move $a2, $zero
|
||||
/* 055DDC 800551DC 5560000B */ bnel $t3, $zero, .L8005520C
|
||||
|
|
|
|||
|
|
@ -24,10 +24,10 @@ glabel func_800552BC
|
|||
/* 055F14 80055314 ACB90000 */ sw $t9, ($a1)
|
||||
/* 055F18 80055318 252977D0 */ addiu $t1, %lo(D_0D0077D0) # addiu $t1, $t1, 0x77d0
|
||||
/* 055F1C 8005531C 3C080600 */ lui $t0, 0x600
|
||||
/* 055F20 80055320 3C0A800E */ lui $t2, %hi(D_800DC5FC) # $t2, 0x800e
|
||||
/* 055F20 80055320 3C0A800E */ lui $t2, %hi(gIsGamePaused) # $t2, 0x800e
|
||||
/* 055F24 80055324 AC880000 */ sw $t0, ($a0)
|
||||
/* 055F28 80055328 AC890004 */ sw $t1, 4($a0)
|
||||
/* 055F2C 8005532C 954AC5FC */ lhu $t2, %lo(D_800DC5FC)($t2)
|
||||
/* 055F2C 8005532C 954AC5FC */ lhu $t2, %lo(gIsGamePaused)($t2)
|
||||
/* 055F30 80055330 00003025 */ move $a2, $zero
|
||||
/* 055F34 80055334 5540000B */ bnel $t2, $zero, .L80055364
|
||||
/* 055F38 80055338 8C640070 */ lw $a0, 0x70($v1)
|
||||
|
|
|
|||
|
|
@ -66,12 +66,12 @@ glabel func_8028F970
|
|||
/* 0F9070 8028FA60 00000000 */ nop
|
||||
/* 0F9074 8028FA64 3C0B800E */ lui $t3, %hi(gControllerOne) # $t3, 0x800e
|
||||
/* 0F9078 8028FA68 8D6BC4BC */ lw $t3, %lo(gControllerOne)($t3)
|
||||
/* 0F907C 8028FA6C 3C01800E */ lui $at, %hi(D_800DC5FC) # $at, 0x800e
|
||||
/* 0F907C 8028FA6C 3C01800E */ lui $at, %hi(gIsGamePaused) # $at, 0x800e
|
||||
/* 0F9080 8028FA70 24040001 */ li $a0, 1
|
||||
/* 0F9084 8028FA74 020B6023 */ subu $t4, $s0, $t3
|
||||
/* 0F9088 8028FA78 000C6903 */ sra $t5, $t4, 4
|
||||
/* 0F908C 8028FA7C 25AE0001 */ addiu $t6, $t5, 1
|
||||
/* 0F9090 8028FA80 A42EC5FC */ sh $t6, %lo(D_800DC5FC)($at)
|
||||
/* 0F9090 8028FA80 A42EC5FC */ sh $t6, %lo(gIsGamePaused)($at)
|
||||
/* 0F9094 8028FA84 0C0327E4 */ jal func_800C9F90
|
||||
/* 0F9098 8028FA88 A6000006 */ sh $zero, 6($s0)
|
||||
/* 0F909C 8028FA8C 3C0F800E */ lui $t7, %hi(gModeSelection) # $t7, 0x800e
|
||||
|
|
|
|||
|
|
@ -65,6 +65,32 @@ exactly what you're doing.
|
|||
|
||||
#define ACTOR_LIST_SIZE 100
|
||||
|
||||
// Actor flags
|
||||
#define ACTOR_IS_NOT_EXPIRED 0xF // The actor possesses some kind of collision and can be removed
|
||||
|
||||
// Actor shell->state (green, red and blue)
|
||||
#define HELD_SHELL 0 // Single shell that has not been dropped. (probably holding Z).
|
||||
#define RELEASED_SHELL 1 // This is the short window where single shells aren't being held or launched.
|
||||
#define MOVING_SHELL 2 // Moving towards its target after being shot.
|
||||
#define RED_SHELL_LOCK_ON 3 // Red shell is targeting.
|
||||
#define TRIPLE_GREEN_SHELL 4 // Loses triple shell state when shot.
|
||||
#define GREEN_SHELL_HIT_A_RACER 5 // A racer has been hit by a green shell.
|
||||
#define TRIPLE_RED_SHELL 6 // Loses triple shell state when shot.
|
||||
#define DESTROYED_SHELL 7 // Collision with the shell.
|
||||
#define BLUE_SHELL_LOCK_ON 8 // A blue shell has found a target and is hastily approaching it.
|
||||
#define BLUE_SHELL_TARGET_ELIMINATED 9 // Mission completed, well done boss.
|
||||
// Actor banana->state
|
||||
#define HELD_BANANA 0 // Single banana that has not been dropped.
|
||||
#define DROPPED_BANANA 1 // A banana in the state of being dropped on the ground (it only last for a few frames).
|
||||
#define FIRST_BANANA_BUNCH_BANANA 2 // The first banana of the banana bunch
|
||||
#define BANANA_BUNCH_BANANA 3 // Every banana of the banana bunch except the first one.
|
||||
#define BANANA_ON_GROUND 4 // A banana sitting on the ground.
|
||||
#define DESTROYED_BANANA 5 // Collision with the banana.
|
||||
// Actor fakeItemBox->state
|
||||
#define HELD_FAKE_ITEM_BOX 0 // Item box is being held be Z.
|
||||
#define FAKE_ITEM_BOX_ON_GROUND 1 // Item box is on the ground.
|
||||
#define DESTROYED_FAKE_ITEM_BOX 2 // Collision with fake item box.
|
||||
|
||||
struct Actor {
|
||||
/* 0x00 */ s16 type;
|
||||
/* 0x02 */ s16 flags;
|
||||
|
|
|
|||
|
|
@ -0,0 +1,77 @@
|
|||
#ifndef _DEBUG_H_
|
||||
#define _DEBUG_H_
|
||||
|
||||
#include <ultra64.h>
|
||||
#include <defines.h>
|
||||
|
||||
/**
|
||||
* Debug Variable Display List (DVDL), display variables and address at runtime.
|
||||
* to enable it change DVDL to 1 or 0 to disable it
|
||||
* and compile with DEBUG=1 "make DEBUG=1".
|
||||
* To edit the variables displayed edit the structure array in src/debug/debug.inc.c.
|
||||
*
|
||||
* Additional features
|
||||
* Holding L + R + Z + A will start the creditis sequence.
|
||||
* Holding L + R + Z + B will start the ending sequence.
|
||||
*/
|
||||
#define DVDL 0
|
||||
#if DVDL
|
||||
|
||||
#define CHARACTER_BUFFER_SIZE 200 // size of the string buffer
|
||||
|
||||
/**
|
||||
* This is the position of the displayed text.
|
||||
* It's calculated from the top left.
|
||||
*/
|
||||
#define TEXT_Y_POSSITION -0x8
|
||||
#define TEXT_X_POSSITION -0x5
|
||||
|
||||
// flags
|
||||
#define DISPLAY_DECIMAL_NUMBER 0x1
|
||||
#define DISPLAY_HEXIDECIMAL_NUMBER 0x2
|
||||
#define DISPLAY_OCTAL_NUMBER 0x4
|
||||
#define DISPLAY_BINARY_NUMBER 0x8
|
||||
#define DISPLAY_SIGNED_NUMBER 0x10
|
||||
#define DISPLAY_FLOAT_AS_TYPE 0x20
|
||||
#define DISPLAY_FLOAT_WITH_ROUNDING 0x40
|
||||
#define DISPLAY_FLOAT_NUMBER 0x80
|
||||
|
||||
#define HEXIDECIMAL 16
|
||||
#define DECIMAL 10
|
||||
#define OCTAL 8
|
||||
#define BINARY 2
|
||||
|
||||
/**
|
||||
* This structure is the heart of the DVDL.
|
||||
* only the first 4 attributes should be set by the user, the other 2 are used by the program.
|
||||
*/
|
||||
typedef struct
|
||||
{
|
||||
char *variableName; // name of the variable to be displayed
|
||||
void *variablePointer; // pointer to the variable so it can display it
|
||||
u8 variableSize; // size of the variable to make up for templates from C++
|
||||
u8 variableFlag; // flag to change how the variable is displayed
|
||||
char buffer[CHARACTER_BUFFER_SIZE]; // when converting a variable to string this will be filled
|
||||
char *characterBuffer; // silly pointer so i don't need to do stuff
|
||||
} variableWatchAttributes;
|
||||
|
||||
/**
|
||||
* This structure array is what you edit to display in the list.
|
||||
* First index is the variable name, second is a pointer to the variable and
|
||||
* third is the size of the variable.
|
||||
*
|
||||
* initilized in debug/debug.inc.c
|
||||
*/
|
||||
extern variableWatchAttributes gMainVariableWatchList[];
|
||||
|
||||
/**
|
||||
* This is what calls the debug watch list. Because of how mk64 was programed,
|
||||
* It's called at 4 different parts of the code. One for menus, race,
|
||||
* ending sequence and creditis. It does not display during loading time because
|
||||
* the RSP is not initialized during that portion of the code.
|
||||
*/
|
||||
void display_dvdl(void);
|
||||
|
||||
#endif
|
||||
|
||||
#endif
|
||||
|
|
@ -15,7 +15,7 @@
|
|||
*
|
||||
* Toggle resource meters by holding R and tapping B. L must not be held.
|
||||
*
|
||||
* Reset to start screen by holding A, B, R, and R.
|
||||
* Reset to start screen by holding A, B, R, and L.
|
||||
*
|
||||
* View player direction and currentPathPoint in a single player race during staging tap L while holding A and B.
|
||||
* Turn off this UI by tapping R while holding A and B.
|
||||
|
|
|
|||
|
|
@ -106,7 +106,7 @@ extern Gfx D_0D0077A0[];
|
|||
extern s32 gGamestate;
|
||||
extern u16 D_800DC51C;
|
||||
extern s32 D_800DC540;
|
||||
extern u16 D_800DC5FC;
|
||||
extern u16 gIsGamePaused;
|
||||
|
||||
extern u16 D_80150112;
|
||||
|
||||
|
|
|
|||
19
mk64.ld
19
mk64.ld
|
|
@ -115,7 +115,10 @@ SECTIONS
|
|||
BUILD_DIR/src/audio/seqplayer.o(.text);
|
||||
BUILD_DIR/src/audio/external.o(.text);
|
||||
BUILD_DIR/src/audio/port_eu.o(.text);
|
||||
|
||||
#if DEBUG
|
||||
BUILD_DIR/src/debug/debug.o(.text);
|
||||
BUILD_DIR/src/os/sprintf.o(.text);
|
||||
#endif
|
||||
BUILD_DIR/src/os/osCreateThread.o(.text);
|
||||
BUILD_DIR/src/os/osInitialize.o(.text);
|
||||
BUILD_DIR/src/os/osStartThread.o(.text);
|
||||
|
|
@ -259,7 +262,11 @@ SECTIONS
|
|||
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/effects.o(.data);
|
||||
#if DEBUG
|
||||
BUILD_DIR/src/debug/debug.o(.data);
|
||||
BUILD_DIR/src/os/sprintf.o(.data);
|
||||
#endif
|
||||
BUILD_DIR/data/data_0DD0A0_2_1_1.o(.rodata);
|
||||
BUILD_DIR/src/os/osInitialize.o(.data*);
|
||||
BUILD_DIR/src/os/osCreateViManager.o(.data);
|
||||
|
|
@ -301,6 +308,10 @@ SECTIONS
|
|||
BUILD_DIR/src/audio/seqplayer.o(.rodata);
|
||||
BUILD_DIR/src/audio/external.o(.rodata);
|
||||
BUILD_DIR/src/audio/port_eu.o(.rodata);
|
||||
#if DEBUG
|
||||
BUILD_DIR/src/debug/debug.o(.rodata);
|
||||
BUILD_DIR/src/os/sprintf.o(.rodata);
|
||||
#endif
|
||||
BUILD_DIR/src/os/guRotateF.o(.rodata);
|
||||
BUILD_DIR/src/os/guPerspectiveF.o(.rodata);
|
||||
BUILD_DIR/asm/os/__osException.o(.rodata);
|
||||
|
|
@ -332,6 +343,10 @@ SECTIONS
|
|||
BUILD_DIR/asm/bss_8001C4D0_1.o(.bss);
|
||||
BUILD_DIR/src/code_800AF9B0.o(.bss);
|
||||
BUILD_DIR/src/menus.o(.bss);
|
||||
#if DEBUG
|
||||
BUILD_DIR/src/debug/debug.o(.bss);
|
||||
BUILD_DIR/src/os/sprintf.o(.bss);
|
||||
#endif
|
||||
BUILD_DIR/asm/bss_main_audio.o(.bss);
|
||||
BUILD_DIR/src/os/osCreateViManager.o(.bss);
|
||||
BUILD_DIR/src/os/osCreatePiManager.o(.bss);
|
||||
|
|
|
|||
540
src/actors.c
540
src/actors.c
|
|
@ -20,7 +20,6 @@
|
|||
#include "audio/external.h"
|
||||
#include "common_textures.h"
|
||||
|
||||
|
||||
// Appears to be textures
|
||||
// or tluts
|
||||
u8 *D_802BA050;
|
||||
|
|
@ -32,17 +31,21 @@ struct Actor *D_802BA05C;
|
|||
s8 D_802BA060[512]; // tlut 256
|
||||
u16 D_802BA260;
|
||||
|
||||
void func_80296A50(struct ShellActor *shell) {
|
||||
/**
|
||||
* Once the amount of spawned player red and green shell count has reached 21 or higher
|
||||
* the game will cleanup any dead red or green shells by deleting their actors.
|
||||
*/
|
||||
void cleanup_red_and_green_shells(struct ShellActor *shell) {
|
||||
s32 actorIndex;
|
||||
struct ShellActor *compare;
|
||||
|
||||
for (actorIndex = gNumPermanentActors; actorIndex < ACTOR_LIST_SIZE; actorIndex++) {
|
||||
compare = (struct ShellActor *)&gActorList[actorIndex];
|
||||
if ((shell != compare) && !(compare->flags & 0xF) && (compare->type == ACTOR_GREEN_SHELL)) {
|
||||
if (compare->state == 2) {
|
||||
if ((shell != compare) && !(compare->flags & ACTOR_IS_NOT_EXPIRED) && (compare->type == ACTOR_GREEN_SHELL)) {
|
||||
if (compare->state == MOVING_SHELL) {
|
||||
func_8000EE58(actorIndex);
|
||||
}
|
||||
D_8015F6FE -= 1;
|
||||
gNumSpawnedShells -= 1;
|
||||
destroy_actor((struct Actor *)compare);
|
||||
return;
|
||||
}
|
||||
|
|
@ -50,21 +53,21 @@ void func_80296A50(struct ShellActor *shell) {
|
|||
|
||||
for (actorIndex = gNumPermanentActors; actorIndex < ACTOR_LIST_SIZE; actorIndex++) {
|
||||
compare = (struct ShellActor *) &gActorList[actorIndex];
|
||||
if ((shell != compare) && !(compare->flags & 0xF) && (compare->type == ACTOR_RED_SHELL)) {
|
||||
if ((shell != compare) && !(compare->flags & ACTOR_IS_NOT_EXPIRED) && (compare->type == ACTOR_RED_SHELL)) {
|
||||
switch(compare->state) {
|
||||
case 2:
|
||||
case 3:
|
||||
case 4:
|
||||
case 5:
|
||||
case 8:
|
||||
case 9:
|
||||
func_8000EE58(actorIndex);
|
||||
case 7:
|
||||
D_8015F6FE -= 1;
|
||||
destroy_actor((struct Actor *)compare);
|
||||
return;
|
||||
default:
|
||||
break;
|
||||
case MOVING_SHELL:
|
||||
case RED_SHELL_LOCK_ON:
|
||||
case TRIPLE_GREEN_SHELL:
|
||||
case GREEN_SHELL_HIT_A_RACER:
|
||||
case BLUE_SHELL_LOCK_ON:
|
||||
case BLUE_SHELL_TARGET_ELIMINATED:
|
||||
func_8000EE58(actorIndex);
|
||||
case DESTROYED_SHELL:
|
||||
gNumSpawnedShells -= 1;
|
||||
destroy_actor((struct Actor *)compare);
|
||||
return;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -73,12 +76,12 @@ void func_80296A50(struct ShellActor *shell) {
|
|||
compare = (struct ShellActor *) &gActorList[actorIndex];
|
||||
if ((shell != compare) && (compare->type == ACTOR_GREEN_SHELL)) {
|
||||
switch(compare->state) {
|
||||
case 2:
|
||||
func_8000EE58(actorIndex);
|
||||
case 7:
|
||||
D_8015F6FE -= 1;
|
||||
destroy_actor((struct Actor *)compare);
|
||||
return;
|
||||
case MOVING_SHELL:
|
||||
func_8000EE58(actorIndex);
|
||||
case DESTROYED_SHELL:
|
||||
gNumSpawnedShells -= 1;
|
||||
destroy_actor((struct Actor *)compare);
|
||||
return;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -87,17 +90,17 @@ void func_80296A50(struct ShellActor *shell) {
|
|||
compare = (struct ShellActor *)&gActorList[actorIndex];
|
||||
if ((shell != compare) && (compare->type == ACTOR_RED_SHELL)) {
|
||||
switch(compare->state) {
|
||||
case 2:
|
||||
case 3:
|
||||
case 4:
|
||||
case 5:
|
||||
case 8:
|
||||
case 9:
|
||||
func_8000EE58(actorIndex);
|
||||
case 7:
|
||||
D_8015F6FE -= 1;
|
||||
destroy_actor((struct Actor *)compare);
|
||||
return;
|
||||
case MOVING_SHELL:
|
||||
case RED_SHELL_LOCK_ON:
|
||||
case TRIPLE_GREEN_SHELL:
|
||||
case GREEN_SHELL_HIT_A_RACER:
|
||||
case BLUE_SHELL_LOCK_ON:
|
||||
case BLUE_SHELL_TARGET_ELIMINATED:
|
||||
func_8000EE58(actorIndex);
|
||||
case DESTROYED_SHELL:
|
||||
gNumSpawnedShells -= 1;
|
||||
destroy_actor((struct Actor *)compare);
|
||||
return;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -119,7 +122,7 @@ void actor_init(struct Actor *actor, Vec3f startingPos, Vec3s startingRot, Vec3f
|
|||
case ACTOR_BOX_TRUCK:
|
||||
if ((s32) D_802BA260 >= 3) {
|
||||
D_802BA260 = 0;
|
||||
}
|
||||
}
|
||||
actor->state = (s16) D_802BA260;
|
||||
D_802BA260 += 1;
|
||||
break;
|
||||
|
|
@ -150,25 +153,25 @@ void actor_init(struct Actor *actor, Vec3f startingPos, Vec3s startingRot, Vec3f
|
|||
actor->boundingBoxSize = 2.0f;
|
||||
break;
|
||||
case ACTOR_GREEN_SHELL:
|
||||
D_8015F6FE += 1;
|
||||
gNumSpawnedShells += 1;
|
||||
actor->unk_04 = 0;
|
||||
actor->boundingBoxSize = 4.0f;
|
||||
actor->flags = actor->flags | 0x4000 | 0x2000 | 0x1000;
|
||||
if ((s32) D_8015F6FE >= 0x15) {
|
||||
func_80296A50((struct ShellActor *) actor);
|
||||
if ((s32) gNumSpawnedShells >= 0x15) {
|
||||
cleanup_red_and_green_shells((struct ShellActor *) actor);
|
||||
}
|
||||
break;
|
||||
case ACTOR_RED_SHELL:
|
||||
D_8015F6FE += 1;
|
||||
gNumSpawnedShells += 1;
|
||||
actor->unk_04 = 0;
|
||||
actor->boundingBoxSize = 4.0f;
|
||||
actor->flags = actor->flags | 0x4000 | 0x2000 | 0x1000;
|
||||
if ((s32) D_8015F6FE >= 0x15) {
|
||||
func_80296A50((struct ShellActor *) actor);
|
||||
if ((s32) gNumSpawnedShells >= 0x15) {
|
||||
cleanup_red_and_green_shells((struct ShellActor *) actor);
|
||||
}
|
||||
break;
|
||||
case 2:
|
||||
D_8015F6FE += 1;
|
||||
gNumSpawnedShells += 1;
|
||||
actor->flags |= 0x4000;
|
||||
actor->state = 0x0043;
|
||||
actor->boundingBoxSize = 3.0f;
|
||||
|
|
@ -286,7 +289,7 @@ void func_80297230(Camera *arg0, struct Actor *arg1) {
|
|||
}
|
||||
|
||||
void func_802972B8(Camera *arg0, struct Actor *arg1) {
|
||||
switch(arg0 - camera1) {
|
||||
switch(arg0 - camera1) {
|
||||
case 0:
|
||||
arg1->flags |= 1;
|
||||
break;
|
||||
|
|
@ -881,7 +884,7 @@ void func_80298D7C(Camera *camera, Mat4 arg1, UNUSED struct Actor *actor) {
|
|||
continue;
|
||||
}
|
||||
|
||||
if ((test & 0x0400) && ((D_800DC5FC == 0) || (camera == camera1))) {
|
||||
if ((test & 0x0400) && ((gIsGamePaused == 0) || (camera == camera1))) {
|
||||
var_s1->pos[1] += 0xA;
|
||||
if (var_s1->pos[1] >= 0x321) {
|
||||
var_s1->someId |= 0x0800;
|
||||
|
|
@ -1222,6 +1225,7 @@ void func_8029A3AC(Camera *camera, Mat4 matrix, struct ShellActor *shell) {
|
|||
func_80297230(camera, (struct Actor *)shell);
|
||||
return;
|
||||
}
|
||||
|
||||
func_802972B8(camera, (struct Actor *) shell);
|
||||
if (temp_f0 < 40000.0f) {
|
||||
func_802979F8((struct Actor *) shell, 3.4f);
|
||||
|
|
@ -1297,6 +1301,7 @@ void func_8029A8F4(Camera *camera, UNUSED Mat4 arg1, struct BananaActor *banana)
|
|||
func_80297230(camera, (struct Actor *) banana);
|
||||
return;
|
||||
}
|
||||
|
||||
func_802972B8(camera, (struct Actor *) banana);
|
||||
|
||||
if (banana->state == 5) {
|
||||
|
|
@ -2520,56 +2525,56 @@ s16 func_8029E890(Vec3f pos, Vec3s rot, Vec3f velocity, s16 actorType) {
|
|||
|
||||
for (actorIndex = gNumPermanentActors; actorIndex < ACTOR_LIST_SIZE; actorIndex++) {
|
||||
compare = (struct ShellActor *) &gActorList[actorIndex];
|
||||
if (!(compare->flags & 0xF)) {
|
||||
if (!(compare->flags & ACTOR_IS_NOT_EXPIRED)) {
|
||||
switch(compare->type) {
|
||||
case ACTOR_RED_SHELL:
|
||||
switch(compare->state) {
|
||||
case 2:
|
||||
case 3:
|
||||
case 4:
|
||||
case 5:
|
||||
case 8:
|
||||
case 9:
|
||||
func_8000EE58(actorIndex);
|
||||
case 7:
|
||||
func_8029E7DC((struct Actor *) compare);
|
||||
actor_init((struct Actor *) compare, pos, rot, velocity, actorType);
|
||||
return actorIndex;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
break;
|
||||
case ACTOR_GREEN_SHELL:
|
||||
switch(compare->state) {
|
||||
case 2:
|
||||
func_8000EE58(actorIndex);
|
||||
case 7:
|
||||
func_8029E7DC((struct Actor *) compare);
|
||||
actor_init((struct Actor *) compare, pos, rot, velocity, actorType);
|
||||
return actorIndex;
|
||||
}
|
||||
break;
|
||||
case ACTOR_BANANA:
|
||||
switch(compare->state) {
|
||||
case 1:
|
||||
case 4:
|
||||
case 5:
|
||||
func_8029E7DC((struct Actor *) compare);
|
||||
actor_init((struct Actor *) compare, pos, rot, velocity, actorType);
|
||||
return actorIndex;
|
||||
}
|
||||
break;
|
||||
case ACTOR_FAKE_ITEM_BOX:
|
||||
switch(compare->state) {
|
||||
case 1:
|
||||
case 2:
|
||||
func_8029E7DC((struct Actor *) compare);
|
||||
actor_init((struct Actor *) compare, pos, rot, velocity, actorType);
|
||||
return actorIndex;
|
||||
}
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
case ACTOR_RED_SHELL:
|
||||
switch(compare->state) {
|
||||
case MOVING_SHELL:
|
||||
case RED_SHELL_LOCK_ON:
|
||||
case TRIPLE_GREEN_SHELL:
|
||||
case GREEN_SHELL_HIT_A_RACER:
|
||||
case BLUE_SHELL_LOCK_ON:
|
||||
case BLUE_SHELL_TARGET_ELIMINATED:
|
||||
func_8000EE58(actorIndex);
|
||||
case DESTROYED_SHELL:
|
||||
func_8029E7DC((struct Actor *) compare);
|
||||
actor_init((struct Actor *) compare, pos, rot, velocity, actorType);
|
||||
return actorIndex;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
break;
|
||||
case ACTOR_GREEN_SHELL:
|
||||
switch(compare->state) {
|
||||
case MOVING_SHELL:
|
||||
func_8000EE58(actorIndex);
|
||||
case DESTROYED_SHELL:
|
||||
func_8029E7DC((struct Actor *) compare);
|
||||
actor_init((struct Actor *) compare, pos, rot, velocity, actorType);
|
||||
return actorIndex;
|
||||
}
|
||||
break;
|
||||
case ACTOR_BANANA:
|
||||
switch(compare->state) {
|
||||
case DROPPED_BANANA:
|
||||
case BANANA_ON_GROUND:
|
||||
case DESTROYED_BANANA:
|
||||
func_8029E7DC((struct Actor *) compare);
|
||||
actor_init((struct Actor *) compare, pos, rot, velocity, actorType);
|
||||
return actorIndex;
|
||||
}
|
||||
break;
|
||||
case ACTOR_FAKE_ITEM_BOX:
|
||||
switch(compare->state) {
|
||||
case FAKE_ITEM_BOX_ON_GROUND:
|
||||
case DESTROYED_FAKE_ITEM_BOX:
|
||||
func_8029E7DC((struct Actor *) compare);
|
||||
actor_init((struct Actor *) compare, pos, rot, velocity, actorType);
|
||||
return actorIndex;
|
||||
}
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -2577,54 +2582,54 @@ s16 func_8029E890(Vec3f pos, Vec3s rot, Vec3f velocity, s16 actorType) {
|
|||
for (actorIndex = gNumPermanentActors; actorIndex < ACTOR_LIST_SIZE; actorIndex++) {
|
||||
compare = (struct ShellActor *) &gActorList[actorIndex];
|
||||
switch(compare->type) {
|
||||
case ACTOR_RED_SHELL:
|
||||
switch(compare->state) {
|
||||
case 2:
|
||||
case 3:
|
||||
case 4:
|
||||
case 5:
|
||||
case 8:
|
||||
case 9:
|
||||
func_8000EE58(actorIndex);
|
||||
case 7:
|
||||
func_8029E7DC((struct Actor *) compare);
|
||||
actor_init((struct Actor *) compare, pos, rot, velocity, actorType);
|
||||
return actorIndex;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
break;
|
||||
case ACTOR_GREEN_SHELL:
|
||||
switch(compare->state) {
|
||||
case 2:
|
||||
func_8000EE58(actorIndex);
|
||||
case 7:
|
||||
func_8029E7DC((struct Actor *) compare);
|
||||
actor_init((struct Actor *) compare, pos, rot, velocity, actorType);
|
||||
return actorIndex;
|
||||
}
|
||||
break;
|
||||
case ACTOR_BANANA:
|
||||
switch(compare->state) {
|
||||
case 1:
|
||||
case 4:
|
||||
case 5:
|
||||
func_8029E7DC((struct Actor *) compare);
|
||||
actor_init((struct Actor *) compare, pos, rot, velocity, actorType);
|
||||
return actorIndex;
|
||||
}
|
||||
break;
|
||||
case ACTOR_FAKE_ITEM_BOX:
|
||||
switch(compare->state) {
|
||||
case 1:
|
||||
case 2:
|
||||
func_8029E7DC((struct Actor *) compare);
|
||||
actor_init((struct Actor *) compare, pos, rot, velocity, actorType);
|
||||
return actorIndex;
|
||||
}
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
case ACTOR_RED_SHELL:
|
||||
switch(compare->state) {
|
||||
case MOVING_SHELL:
|
||||
case RED_SHELL_LOCK_ON:
|
||||
case TRIPLE_GREEN_SHELL:
|
||||
case GREEN_SHELL_HIT_A_RACER:
|
||||
case BLUE_SHELL_LOCK_ON:
|
||||
case BLUE_SHELL_TARGET_ELIMINATED:
|
||||
func_8000EE58(actorIndex);
|
||||
case DESTROYED_SHELL:
|
||||
func_8029E7DC((struct Actor *) compare);
|
||||
actor_init((struct Actor *) compare, pos, rot, velocity, actorType);
|
||||
return actorIndex;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
break;
|
||||
case ACTOR_GREEN_SHELL:
|
||||
switch(compare->state) {
|
||||
case MOVING_SHELL:
|
||||
func_8000EE58(actorIndex);
|
||||
case DESTROYED_SHELL:
|
||||
func_8029E7DC((struct Actor *) compare);
|
||||
actor_init((struct Actor *) compare, pos, rot, velocity, actorType);
|
||||
return actorIndex;
|
||||
}
|
||||
break;
|
||||
case ACTOR_BANANA:
|
||||
switch(compare->state) {
|
||||
case DROPPED_BANANA:
|
||||
case BANANA_ON_GROUND:
|
||||
case DESTROYED_BANANA:
|
||||
func_8029E7DC((struct Actor *) compare);
|
||||
actor_init((struct Actor *) compare, pos, rot, velocity, actorType);
|
||||
return actorIndex;
|
||||
}
|
||||
break;
|
||||
case ACTOR_FAKE_ITEM_BOX:
|
||||
switch(compare->state) {
|
||||
case FAKE_ITEM_BOX_ON_GROUND:
|
||||
case DESTROYED_FAKE_ITEM_BOX:
|
||||
func_8029E7DC((struct Actor *) compare);
|
||||
actor_init((struct Actor *) compare, pos, rot, velocity, actorType);
|
||||
return actorIndex;
|
||||
}
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -3028,144 +3033,144 @@ void func_8029FDC8(struct Actor *actor) {
|
|||
Player *player;
|
||||
|
||||
switch (actor->type) {
|
||||
case ACTOR_BANANA:
|
||||
banana = (struct BananaActor *)actor;
|
||||
switch (banana->state) {
|
||||
case 2:
|
||||
case 3:
|
||||
func_802B0570(banana);
|
||||
break;
|
||||
case 0:
|
||||
player = &gPlayers[banana->playerId];
|
||||
player->statusEffects &= ~0x00040000;
|
||||
/* fallthrough */
|
||||
case 4:
|
||||
banana->flags = -0x8000;
|
||||
banana->unk_04 = 0x003C;
|
||||
banana->state = 5;
|
||||
banana->velocity[1] = 3.0f;
|
||||
break;
|
||||
case 1:
|
||||
case 5:
|
||||
default:
|
||||
break;
|
||||
}
|
||||
break;
|
||||
case ACTOR_GREEN_SHELL:
|
||||
shell = (struct ShellActor *)actor;
|
||||
if (shell->state != 5) {
|
||||
switch (shell->state) {
|
||||
case 2:
|
||||
func_8000EE58(actor - gActorList);
|
||||
/* fallthrough */
|
||||
case 0:
|
||||
case 1:
|
||||
shell->flags = -0x8000;
|
||||
shell->rotAngle = 0;
|
||||
shell->someTimer = 0x003C;
|
||||
shell->state = 5;
|
||||
shell->velocity[1] = 3.0f;
|
||||
break;
|
||||
case 4:
|
||||
func_802B02B4(shell, ACTOR_GREEN_SHELL);
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
}
|
||||
break;
|
||||
case ACTOR_BLUE_SPINY_SHELL:
|
||||
shell = (struct ShellActor *)actor;
|
||||
if (shell->state != 7) {
|
||||
switch (shell->state) {
|
||||
case 2:
|
||||
case 3:
|
||||
case 4:
|
||||
case 5:
|
||||
case 8:
|
||||
case 9:
|
||||
func_800C9EF4(shell->pos, 0x51018008);
|
||||
func_8000EE58(actor - gActorList);
|
||||
/* fallthrough */
|
||||
case 0:
|
||||
case 1:
|
||||
shell->flags = -0x8000;
|
||||
shell->rotAngle = 0;
|
||||
shell->someTimer = 0x003C;
|
||||
shell->state = 7;
|
||||
shell->velocity[1] = 3.0f;
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
}
|
||||
break;
|
||||
case ACTOR_RED_SHELL:
|
||||
shell = (struct ShellActor *)actor;
|
||||
if (shell->state != 7) {
|
||||
switch (shell->state) {
|
||||
case 2:
|
||||
case 3:
|
||||
case 4:
|
||||
case 5:
|
||||
case 8:
|
||||
case 9:
|
||||
func_8000EE58(actor - gActorList);
|
||||
/* fallthrough */
|
||||
case 0:
|
||||
case 1:
|
||||
shell->flags = -0x8000;
|
||||
shell->rotAngle = 0;
|
||||
shell->someTimer = 0x003C;
|
||||
shell->state = 7;
|
||||
shell->velocity[1] = 3.0f;
|
||||
break;
|
||||
case 6:
|
||||
func_802B02B4(shell, ACTOR_RED_SHELL);
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
}
|
||||
break;
|
||||
case ACTOR_FAKE_ITEM_BOX:
|
||||
fakeItemBox = (struct FakeItemBox *)actor;
|
||||
player = &gPlayers[(s16)fakeItemBox->playerId];
|
||||
if (fakeItemBox->state == 0) {
|
||||
player->statusEffects &= ~0x00040000;
|
||||
}
|
||||
fakeItemBox->state = 2;
|
||||
fakeItemBox->flags = -0x8000;
|
||||
fakeItemBox->someTimer = 0;
|
||||
break;
|
||||
case ACTOR_BANANA:
|
||||
banana = (struct BananaActor *)actor;
|
||||
switch (banana->state) {
|
||||
case FIRST_BANANA_BUNCH_BANANA:
|
||||
case BANANA_BUNCH_BANANA:
|
||||
func_802B0570(banana);
|
||||
break;
|
||||
case HELD_BANANA:
|
||||
player = &gPlayers[banana->playerId];
|
||||
player->statusEffects &= ~0x00040000;
|
||||
/* fallthrough */
|
||||
case BANANA_ON_GROUND:
|
||||
banana->flags = -0x8000;
|
||||
banana->unk_04 = 0x003C;
|
||||
banana->state = 5;
|
||||
banana->velocity[1] = 3.0f;
|
||||
break;
|
||||
case DROPPED_BANANA:
|
||||
case DESTROYED_BANANA:
|
||||
default:
|
||||
break;
|
||||
}
|
||||
break;
|
||||
case ACTOR_GREEN_SHELL:
|
||||
shell = (struct ShellActor *)actor;
|
||||
if (shell->state != GREEN_SHELL_HIT_A_RACER) {
|
||||
switch (shell->state) {
|
||||
case MOVING_SHELL:
|
||||
func_8000EE58(actor - gActorList);
|
||||
/* fallthrough */
|
||||
case HELD_SHELL:
|
||||
case RELEASED_SHELL:
|
||||
shell->flags = -0x8000;
|
||||
shell->rotAngle = 0;
|
||||
shell->someTimer = 0x003C;
|
||||
shell->state = GREEN_SHELL_HIT_A_RACER;
|
||||
shell->velocity[1] = 3.0f;
|
||||
break;
|
||||
case TRIPLE_GREEN_SHELL:
|
||||
func_802B02B4(shell, ACTOR_GREEN_SHELL);
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
}
|
||||
break;
|
||||
case ACTOR_BLUE_SPINY_SHELL:
|
||||
shell = (struct ShellActor *)actor;
|
||||
if (shell->state != DESTROYED_SHELL) {
|
||||
switch (shell->state) {
|
||||
case MOVING_SHELL:
|
||||
case RED_SHELL_LOCK_ON:
|
||||
case TRIPLE_GREEN_SHELL:
|
||||
case GREEN_SHELL_HIT_A_RACER:
|
||||
case BLUE_SHELL_LOCK_ON:
|
||||
case BLUE_SHELL_TARGET_ELIMINATED:
|
||||
func_800C9EF4(shell->pos, 0x51018008);
|
||||
func_8000EE58(actor - gActorList);
|
||||
/* fallthrough */
|
||||
case HELD_SHELL:
|
||||
case RELEASED_SHELL:
|
||||
shell->flags = -0x8000;
|
||||
shell->rotAngle = 0;
|
||||
shell->someTimer = 0x003C;
|
||||
shell->state = DESTROYED_SHELL;
|
||||
shell->velocity[1] = 3.0f;
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
}
|
||||
break;
|
||||
case ACTOR_RED_SHELL:
|
||||
shell = (struct ShellActor *)actor;
|
||||
if (shell->state != DESTROYED_SHELL) {
|
||||
switch (shell->state) {
|
||||
case MOVING_SHELL:
|
||||
case RED_SHELL_LOCK_ON:
|
||||
case TRIPLE_GREEN_SHELL:
|
||||
case GREEN_SHELL_HIT_A_RACER:
|
||||
case BLUE_SHELL_LOCK_ON:
|
||||
case BLUE_SHELL_TARGET_ELIMINATED:
|
||||
func_8000EE58(actor - gActorList);
|
||||
/* fallthrough */
|
||||
case HELD_SHELL:
|
||||
case RELEASED_SHELL:
|
||||
shell->flags = -0x8000;
|
||||
shell->rotAngle = 0;
|
||||
shell->someTimer = 0x003C;
|
||||
shell->state = DESTROYED_SHELL;
|
||||
shell->velocity[1] = 3.0f;
|
||||
break;
|
||||
case TRIPLE_RED_SHELL:
|
||||
func_802B02B4(shell, ACTOR_RED_SHELL);
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
}
|
||||
break;
|
||||
case ACTOR_FAKE_ITEM_BOX:
|
||||
fakeItemBox = (struct FakeItemBox *)actor;
|
||||
player = &gPlayers[(s16)fakeItemBox->playerId];
|
||||
if (fakeItemBox->state == HELD_FAKE_ITEM_BOX) {
|
||||
player->statusEffects &= ~0x00040000;
|
||||
}
|
||||
fakeItemBox->state = DESTROYED_FAKE_ITEM_BOX;
|
||||
fakeItemBox->flags = -0x8000;
|
||||
fakeItemBox->someTimer = 0;
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
void func_802A00E8(struct Actor *arg0, struct Actor *arg1) {
|
||||
switch(arg0->type) {
|
||||
case ACTOR_GREEN_SHELL:
|
||||
if ((arg0->state == 0) || (arg0->state == 4)) {
|
||||
if ((arg0->state == HELD_SHELL) || (arg0->state == TRIPLE_GREEN_SHELL)) {
|
||||
arg0->flags |= 0x200;
|
||||
func_800C98B8(arg0->pos, arg0->velocity, 0x19019053);
|
||||
return;
|
||||
}
|
||||
break;
|
||||
case ACTOR_RED_SHELL:
|
||||
if ((arg0->state == 0) || (arg0->state == 6)) {
|
||||
if ((arg0->state == HELD_SHELL) || (arg0->state == TRIPLE_RED_SHELL)) {
|
||||
arg0->flags |= 0x200;
|
||||
func_800C98B8(arg0->pos, arg0->velocity, 0x19019053);
|
||||
return;
|
||||
return;
|
||||
}
|
||||
break;
|
||||
case ACTOR_BLUE_SPINY_SHELL:
|
||||
if (arg0->state == 0) {
|
||||
if (arg0->state == HELD_SHELL) {
|
||||
arg0->flags |= 0x200;
|
||||
func_800C98B8(arg0->pos, arg0->velocity, 0x19019053);
|
||||
return;
|
||||
}
|
||||
break;
|
||||
case ACTOR_FAKE_ITEM_BOX:
|
||||
if (arg0->state == 0) {
|
||||
if (arg0->state == HELD_FAKE_ITEM_BOX) {
|
||||
arg0->flags |= 0x200;
|
||||
func_800C98B8(arg0->pos, arg0->velocity, 0x19019053);
|
||||
return;
|
||||
|
|
@ -3175,28 +3180,28 @@ void func_802A00E8(struct Actor *arg0, struct Actor *arg1) {
|
|||
|
||||
switch(arg1->type) {
|
||||
case ACTOR_GREEN_SHELL:
|
||||
if ((arg1->state == 0) || (arg1->state == 4)) {
|
||||
arg1->flags |= 0x200;
|
||||
func_800C98B8(arg1->pos, arg1->velocity, 0x19019053);
|
||||
return;
|
||||
if ((arg1->state == HELD_SHELL) || (arg1->state == TRIPLE_GREEN_SHELL)) {
|
||||
arg1->flags |= 0x200;
|
||||
func_800C98B8(arg1->pos, arg1->velocity, 0x19019053);
|
||||
return;
|
||||
}
|
||||
break;
|
||||
case ACTOR_RED_SHELL:
|
||||
if ((arg1->state == 0) || (arg1->state == 6)) {
|
||||
if ((arg1->state == HELD_SHELL) || (arg1->state == TRIPLE_RED_SHELL)) {
|
||||
arg1->flags |= 0x200;
|
||||
func_800C98B8(arg1->pos, arg1->velocity, 0x19019053);
|
||||
return;
|
||||
}
|
||||
break;
|
||||
case ACTOR_BLUE_SPINY_SHELL:
|
||||
if (arg1->state == 0) {
|
||||
if (arg1->state == HELD_SHELL) {
|
||||
arg1->flags |= 0x200;
|
||||
func_800C98B8(arg1->pos, arg1->velocity, 0x19019053);
|
||||
return;
|
||||
}
|
||||
break;
|
||||
case ACTOR_FAKE_ITEM_BOX:
|
||||
if (arg1->state == 0) {
|
||||
if (arg1->state == HELD_FAKE_ITEM_BOX) {
|
||||
arg1->flags |= 0x200;
|
||||
func_800C98B8(arg1->pos, arg1->velocity, 0x19019053);
|
||||
return;
|
||||
|
|
@ -3218,14 +3223,14 @@ void func_802A0350(struct Actor *arg0, struct Actor *arg1) {
|
|||
return;
|
||||
}
|
||||
if (arg0->type == ACTOR_BLUE_SPINY_SHELL) {
|
||||
if (arg0->state == 0) {
|
||||
if (arg0->state == HELD_SHELL) {
|
||||
func_8029FDC8(arg0);
|
||||
}
|
||||
} else {
|
||||
func_8029FDC8(arg0);
|
||||
}
|
||||
if (arg1->type == ACTOR_BLUE_SPINY_SHELL) {
|
||||
if (arg1->state == 0) {
|
||||
if (arg1->state == HELD_SHELL) {
|
||||
func_8029FDC8(arg1);
|
||||
}
|
||||
} else {
|
||||
|
|
@ -3692,6 +3697,7 @@ void func_802A171C(Camera *camera, struct FakeItemBox *fakeItemBox) {
|
|||
func_80297230(camera, (struct Actor *) fakeItemBox);
|
||||
return;
|
||||
}
|
||||
|
||||
func_802972B8(camera, (struct Actor *) fakeItemBox);
|
||||
someRot[0] = 0;
|
||||
someRot[1] = fakeItemBox->rot[1];
|
||||
|
|
|
|||
11
src/actors.h
11
src/actors.h
|
|
@ -5,7 +5,7 @@
|
|||
#include "actor_types.h"
|
||||
|
||||
void func_8029E158(void);
|
||||
void func_80296A50(struct ShellActor*);
|
||||
void cleanup_red_and_green_shells(struct ShellActor*);
|
||||
void actor_init(struct Actor*, f32*, s16*, f32*, s16);
|
||||
void func_80297230(Camera*, struct Actor*);
|
||||
void func_802972B8(Camera*, struct Actor*);
|
||||
|
|
@ -129,7 +129,12 @@ extern struct Actor gActorList[];
|
|||
extern Player gPlayers[];
|
||||
extern u16 gNumActors;
|
||||
extern u16 gNumPermanentActors;
|
||||
extern u16 D_8015F6FE; // Shell count? But why does actor type 2 (some kind of shrub?) increase it and not blue shells?
|
||||
|
||||
/**
|
||||
* Incremented by one every time the player spawns a new shell actor.
|
||||
* A cleaning routine runs once twenty-one shells have spawned.
|
||||
*/
|
||||
extern u16 gNumSpawnedShells;
|
||||
extern u16 D_802BA260; // Box Truck sub-type?
|
||||
|
||||
extern Player *gPlayerOne;
|
||||
|
|
@ -388,7 +393,7 @@ extern u8 gTextureShrub[];
|
|||
|
||||
extern s8 D_800DC628[];
|
||||
extern s8 D_800DC630[];
|
||||
extern u16 D_800DC5FC;
|
||||
extern u16 gIsGamePaused;
|
||||
extern s8 D_802B8864[];
|
||||
|
||||
extern u16 D_800DC5BC;
|
||||
|
|
|
|||
|
|
@ -54,10 +54,10 @@ void func_802B02B4(struct ShellActor *shell, s32 shellType) {
|
|||
|
||||
switch(shellType) {
|
||||
case ACTOR_GREEN_SHELL:
|
||||
shell->state = 5;
|
||||
shell->state = GREEN_SHELL_HIT_A_RACER;
|
||||
break;
|
||||
case ACTOR_RED_SHELL:
|
||||
shell->state = 7;
|
||||
shell->state = DESTROYED_SHELL;
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
|
@ -65,7 +65,7 @@ void func_802B02B4(struct ShellActor *shell, s32 shellType) {
|
|||
// Sets velocities for a banana, used when a racer runs into
|
||||
// a banana bunch.
|
||||
void func_802B039C(struct BananaActor *banana) {
|
||||
banana->state = 1;
|
||||
banana->state = DROPPED_BANANA;
|
||||
banana->unk_04 = 0x00B4;
|
||||
banana->velocity[0] = ((f32) (random_int(0x00C8) - 0x64) * 0.015);
|
||||
banana->velocity[1] = ((f32) random_int(0x00C8)) * 0.015;
|
||||
|
|
@ -103,7 +103,7 @@ void func_802B0570(struct BananaActor *banana) {
|
|||
}
|
||||
banana->flags = -0x8000;
|
||||
banana->unk_04 = 0x003C;
|
||||
banana->state = 5;
|
||||
banana->state = DESTROYED_BANANA;
|
||||
banana->velocity[1] = 3.0f;
|
||||
temp_v0_2 = (struct BananaBunchParent *) &gActorList[banana->parentIndex];
|
||||
temp_v0_2->bananaIndices[0] = -1;
|
||||
|
|
@ -138,7 +138,7 @@ void func_802B0648(struct BananaBunchParent *banana_bunch) {
|
|||
return;
|
||||
}
|
||||
|
||||
banana->state = 1;
|
||||
banana->state = DROPPED_BANANA;
|
||||
banana->unk_04 = 0x00B4;
|
||||
banana->velocity[0] = 0.0f;
|
||||
banana->velocity[1] = 1.5f;
|
||||
|
|
@ -177,7 +177,7 @@ void func_802B0788(s16 rawStickY, struct BananaBunchParent *banana_bunch, Player
|
|||
return;
|
||||
}
|
||||
|
||||
banana->state = 1;
|
||||
banana->state = DROPPED_BANANA;
|
||||
banana->unk_04 = 0x001E;
|
||||
if (banana->elderIndex != -1) {
|
||||
elderBanana = (struct BananaActor*)&gActorList[banana->elderIndex];
|
||||
|
|
@ -203,10 +203,10 @@ s32 func_802B09C0(s16 bananaId) {
|
|||
return 0;
|
||||
}
|
||||
banana = (struct BananaActor*) &gActorList[bananaId];
|
||||
if (banana->state == 2) {
|
||||
if (banana->state == FIRST_BANANA_BUNCH_BANANA) {
|
||||
return 1;
|
||||
}
|
||||
if (banana->state == 3) {
|
||||
if (banana->state == BANANA_BUNCH_BANANA) {
|
||||
return 1;
|
||||
}
|
||||
return 0;
|
||||
|
|
@ -317,12 +317,12 @@ s32 func_802B0E14(s16 arg0) {
|
|||
}
|
||||
temp = (struct ShellActor*) &gActorList[arg0];
|
||||
if (temp->type == ACTOR_GREEN_SHELL) {
|
||||
if (temp->state == 4) {
|
||||
if (temp->state == TRIPLE_GREEN_SHELL) {
|
||||
return 1;
|
||||
}
|
||||
return 0;
|
||||
}
|
||||
if (temp->state == 6) {
|
||||
if (temp->state == TRIPLE_RED_SHELL) {
|
||||
return 1;
|
||||
}
|
||||
return 0;
|
||||
|
|
@ -432,7 +432,7 @@ void update_obj_triple_shell(TripleShellParent *parent, s16 shellType) {
|
|||
shell->velocity[0] = someVelocity[0];
|
||||
shell->velocity[1] = someVelocity[1];
|
||||
shell->velocity[2] = someVelocity[2];
|
||||
shell->state = 2;
|
||||
shell->state = MOVING_SHELL;
|
||||
shell->someTimer = 0x001E;
|
||||
func_800C9060(parent->playerId, 0x19008004);
|
||||
func_800C90F4(parent->playerId, (player->characterId * 0x10) + 0x29008000);
|
||||
|
|
@ -457,7 +457,7 @@ void update_obj_triple_shell(TripleShellParent *parent, s16 shellType) {
|
|||
shell->velocity[0] = someVelocity[0];
|
||||
shell->velocity[1] = someVelocity[1];
|
||||
shell->velocity[2] = someVelocity[2];
|
||||
shell->state = 2;
|
||||
shell->state = MOVING_SHELL;
|
||||
shell->someTimer = 0x001E;
|
||||
func_800C90F4(parent->playerId, (player->characterId * 0x10) + 0x29008000);
|
||||
func_800C9060(parent->playerId, 0x19008004);
|
||||
|
|
@ -482,7 +482,7 @@ void update_obj_triple_shell(TripleShellParent *parent, s16 shellType) {
|
|||
shell->velocity[0] = someVelocity[0];
|
||||
shell->velocity[1] = someVelocity[1];
|
||||
shell->velocity[2] = someVelocity[2];
|
||||
shell->state = 2;
|
||||
shell->state = MOVING_SHELL;
|
||||
shell->someTimer = 0x001E;
|
||||
func_800C9060(parent->playerId, 0x19008004);
|
||||
func_800C90F4(parent->playerId, (player->characterId * 0x10) + 0x29008000);
|
||||
|
|
@ -576,10 +576,10 @@ s32 func_802B19EC(TripleShellParent *parent, Player *player, s16 shellType, u16
|
|||
shell->flags = 0x9000;
|
||||
switch (shellType) {
|
||||
case ACTOR_GREEN_SHELL:
|
||||
shell->state = 4;
|
||||
shell->state = TRIPLE_GREEN_SHELL;
|
||||
break;
|
||||
case ACTOR_RED_SHELL:
|
||||
shell->state = 6;
|
||||
shell->state = TRIPLE_RED_SHELL;
|
||||
break;
|
||||
}
|
||||
shell->rotVelocity = 0;
|
||||
|
|
@ -617,7 +617,7 @@ s32 func_802B1C9C(Player *player) {
|
|||
startingPos[2] = player->pos[2];
|
||||
func_802AD950(&shell->unk30, shell->boundingBoxSize + 1.0f, shell->pos[0], shell->pos[1], shell->pos[2], startingPos[0], startingPos[1], startingPos[2]);
|
||||
func_802B4E30((struct Actor *)shell);
|
||||
shell->state = 0;
|
||||
shell->state = HELD_SHELL;
|
||||
shell->rotVelocity = 0;
|
||||
shell->rotAngle = -0x8000;
|
||||
shell->playerId = player - gPlayerOne;
|
||||
|
|
@ -650,7 +650,7 @@ s32 func_802B1E48(Player *player) {
|
|||
startingPos[2] = player->pos[2];
|
||||
func_802AD950(&shell->unk30, shell->boundingBoxSize + 1.0f, shell->pos[0], shell->pos[1], shell->pos[2], startingPos[0], startingPos[1], startingPos[2]);
|
||||
func_802B4E30((struct Actor *)shell);
|
||||
shell->state = 0;
|
||||
shell->state = HELD_SHELL;
|
||||
shell->rotVelocity = 0;
|
||||
shell->rotAngle = player->unk_02C[1] - 0x8000;
|
||||
shell->playerId = player - gPlayerOne;
|
||||
|
|
@ -686,7 +686,7 @@ void update_obj_banana(struct BananaActor *banana) {
|
|||
|
||||
player = &gPlayers[banana->rot[0]];
|
||||
switch (banana->state) {
|
||||
case 0:
|
||||
case HELD_BANANA:
|
||||
temp_f2 = player->pos[0] - banana->pos[0];
|
||||
temp_f14 = player->pos[1] - banana->pos[1];
|
||||
temp_f16 = player->pos[2] - banana->pos[2];
|
||||
|
|
@ -739,7 +739,7 @@ void update_obj_banana(struct BananaActor *banana) {
|
|||
}
|
||||
}
|
||||
break;
|
||||
case 1:
|
||||
case DROPPED_BANANA:
|
||||
if (banana->unk_04 != 0) {
|
||||
banana->unk_04 -= 1;
|
||||
if (banana->unk_04 == 0) {
|
||||
|
|
@ -769,7 +769,7 @@ void update_obj_banana(struct BananaActor *banana) {
|
|||
}
|
||||
}
|
||||
break;
|
||||
case 2:
|
||||
case FIRST_BANANA_BUNCH_BANANA:
|
||||
someVelocity[0] = 0.0f;
|
||||
someVelocity[1] = 0.0f;
|
||||
someVelocity[2] = -5.0f;
|
||||
|
|
@ -796,7 +796,7 @@ void update_obj_banana(struct BananaActor *banana) {
|
|||
func_802ADDC8(&banana->unk30, banana->boundingBoxSize + 1.0f, banana->pos[0], banana->pos[1], banana->pos[2]);
|
||||
func_802B4E30((struct Actor *) banana);
|
||||
break;
|
||||
case 3:
|
||||
case BANANA_BUNCH_BANANA:
|
||||
elderBanana = (struct BananaActor*)&gActorList[banana->elderIndex];
|
||||
temp_f2 = elderBanana->pos[0] - banana->pos[0];
|
||||
temp_f14 = elderBanana->pos[1] - banana->pos[1];
|
||||
|
|
@ -818,7 +818,7 @@ void update_obj_banana(struct BananaActor *banana) {
|
|||
func_802ADDC8(&banana->unk30, banana->boundingBoxSize + 1.0f, banana->pos[0], banana->pos[1], banana->pos[2]);
|
||||
func_802B4E30((struct Actor *) banana);
|
||||
break;
|
||||
case 5:
|
||||
case DESTROYED_BANANA:
|
||||
banana->velocity[1] -= 0.3f;
|
||||
if (banana->velocity[1] < -5.0f) {
|
||||
banana->velocity[1] = -5.0f;
|
||||
|
|
@ -832,7 +832,7 @@ void update_obj_banana(struct BananaActor *banana) {
|
|||
destroy_actor((struct Actor *) banana);
|
||||
}
|
||||
break;
|
||||
case 4:
|
||||
case BANANA_ON_GROUND:
|
||||
banana->flags |= 0xC000;
|
||||
banana->flags &= ~0x1000;
|
||||
break;
|
||||
|
|
@ -987,7 +987,7 @@ s32 func_802B2D70(Player *player) {
|
|||
}
|
||||
banana = (struct BananaActor *) &gActorList[actorIndex];
|
||||
banana->playerId = playerId;
|
||||
banana->state = 0;
|
||||
banana->state = HELD_BANANA;
|
||||
banana->unk_04 = 0x0014;
|
||||
player->statusEffects |= 0x40000;
|
||||
return actorIndex;
|
||||
|
|
@ -1129,7 +1129,7 @@ void update_obj_green_shell(struct ShellActor *shell) {
|
|||
}
|
||||
shell->rotVelocity += 0x71C;
|
||||
switch (shell->state) {
|
||||
case 0:
|
||||
case HELD_SHELL:
|
||||
player = &gPlayers[shell->playerId];
|
||||
func_802B0210(&player->unk_110, &shell->unk30);
|
||||
somePosVel[0] = 0.0f;
|
||||
|
|
@ -1178,7 +1178,7 @@ void update_obj_green_shell(struct ShellActor *shell) {
|
|||
}
|
||||
}
|
||||
break;
|
||||
case 1:
|
||||
case RELEASED_SHELL:
|
||||
player = &gPlayers[shell->playerId];
|
||||
if (shell->rotAngle > 0) {
|
||||
shell->rotAngle -= 0xE38;
|
||||
|
|
@ -1221,7 +1221,7 @@ void update_obj_green_shell(struct ShellActor *shell) {
|
|||
shell->pos[2] = player->pos[2] + somePosVel[2];
|
||||
}
|
||||
break;
|
||||
case 2:
|
||||
case MOVING_SHELL:
|
||||
if (shell->parentIndex > 0) {
|
||||
shell->parentIndex -= 1;
|
||||
if (shell->parentIndex == 0) {
|
||||
|
|
@ -1246,7 +1246,7 @@ void update_obj_green_shell(struct ShellActor *shell) {
|
|||
shell->flags |= 0x80;
|
||||
}
|
||||
break;
|
||||
case 4:
|
||||
case TRIPLE_GREEN_SHELL:
|
||||
player = &gPlayers[shell->playerId];
|
||||
parent = (TripleShellParent *) &gActorList[shell->parentIndex];
|
||||
if (parent->type != ACTOR_TRIPLE_GREEN_SHELL) {
|
||||
|
|
@ -1267,7 +1267,7 @@ void update_obj_green_shell(struct ShellActor *shell) {
|
|||
func_802B4E30((struct Actor *) shell);
|
||||
}
|
||||
break;
|
||||
case 5:
|
||||
case GREEN_SHELL_HIT_A_RACER:
|
||||
// Somehow, this fake match affects stack management up in case 2
|
||||
shell->velocity[1] -= (0, 0.3f);
|
||||
if (shell->velocity[1] < -5.0f) {
|
||||
|
|
@ -1508,7 +1508,7 @@ void update_obj_red_blue_shell(struct ShellActor *shell) {
|
|||
|
||||
shell->rotVelocity += 0x71C;
|
||||
switch (shell->state) {
|
||||
case 0:
|
||||
case HELD_SHELL:
|
||||
player = &gPlayers[shell->playerId];
|
||||
func_802B0210(&player->unk_110, &shell->unk30);
|
||||
somePosVel[0] = 0.0f;
|
||||
|
|
@ -1539,7 +1539,7 @@ void update_obj_red_blue_shell(struct ShellActor *shell) {
|
|||
|
||||
if ((controller->buttonDepressed & 0x2000) != 0) {
|
||||
controller->buttonDepressed &= ~0x2000;
|
||||
shell->state = 1;
|
||||
shell->state = RELEASED_SHELL;
|
||||
if (player->unk_0C0 > 0) {
|
||||
shell->rotAngle = 0x78E3;
|
||||
} else {
|
||||
|
|
@ -1547,12 +1547,12 @@ void update_obj_red_blue_shell(struct ShellActor *shell) {
|
|||
}
|
||||
}
|
||||
break;
|
||||
case 1:
|
||||
case RELEASED_SHELL:
|
||||
player = &gPlayers[shell->playerId];
|
||||
if (shell->rotAngle > 0) {
|
||||
shell->rotAngle -= 0x71C;
|
||||
if (shell->rotAngle < 0) {
|
||||
shell->state = 2;
|
||||
shell->state = MOVING_SHELL;
|
||||
func_800C9060(shell->playerId, 0x19008004U);
|
||||
func_800C90F4(shell->playerId, (player->characterId * 0x10) + 0x29008000);
|
||||
if (pad13 == ACTOR_RED_SHELL) {
|
||||
|
|
@ -1565,7 +1565,7 @@ void update_obj_red_blue_shell(struct ShellActor *shell) {
|
|||
} else {
|
||||
shell->rotAngle += 0x71C;
|
||||
if (shell->rotAngle > 0) {
|
||||
shell->state = 2;
|
||||
shell->state = MOVING_SHELL;
|
||||
func_800C9060(shell->playerId, 0x19008004U);
|
||||
func_800C90F4(shell->playerId, (player->characterId * 0x10) + 0x29008000);
|
||||
if (pad13 == ACTOR_RED_SHELL) {
|
||||
|
|
@ -1576,7 +1576,7 @@ void update_obj_red_blue_shell(struct ShellActor *shell) {
|
|||
}
|
||||
}
|
||||
}
|
||||
if (shell->state == 2) {
|
||||
if (shell->state == MOVING_SHELL) {
|
||||
shell->someTimer = 0x001E;
|
||||
temp_f0 = 8.0f;
|
||||
if (player->unk_094 > 8.0f) {
|
||||
|
|
@ -1599,14 +1599,14 @@ void update_obj_red_blue_shell(struct ShellActor *shell) {
|
|||
shell->pos[2] = player->pos[2] + somePosVel[2];
|
||||
}
|
||||
break;
|
||||
case 2:
|
||||
case MOVING_SHELL:
|
||||
player = &gPlayers[shell->playerId];
|
||||
shell->someTimer -= 1;
|
||||
if (shell->someTimer == 0) {
|
||||
shell->flags &= 0xEFFF;
|
||||
if (shell->type == ACTOR_BLUE_SPINY_SHELL) {
|
||||
shell->targetPlayer = gPlayerPositionLUT[0];
|
||||
shell->state = 8;
|
||||
shell->state = BLUE_SHELL_LOCK_ON;
|
||||
shell->shellId = 1000.0f;
|
||||
temp_v0 = gNearestWaypointByPlayerId[player - gPlayerOne] + 8;
|
||||
if ((s32) D_80164430 < temp_v0) {
|
||||
|
|
@ -1621,13 +1621,13 @@ void update_obj_red_blue_shell(struct ShellActor *shell) {
|
|||
shell->velocity[1] = 3.0f;
|
||||
shell->pathIndex = 0;
|
||||
shell->someTimer = 0x003C;
|
||||
shell->state = 7;
|
||||
shell->state = DESTROYED_SHELL;
|
||||
} else {
|
||||
shell->state = 3;
|
||||
shell->state = RED_SHELL_LOCK_ON;
|
||||
}
|
||||
} else {
|
||||
if (player->currentRank == 0) {
|
||||
shell->state = 4;
|
||||
shell->state = TRIPLE_GREEN_SHELL;
|
||||
shell->someTimer = 0x0258;
|
||||
temp_v0 = gNearestWaypointByPlayerId[player - gPlayerOne] + 8;
|
||||
if ((s32) D_80164430 < temp_v0) {
|
||||
|
|
@ -1635,7 +1635,7 @@ void update_obj_red_blue_shell(struct ShellActor *shell) {
|
|||
}
|
||||
shell->pathIndex = temp_v0;
|
||||
} else if (player->currentRank >= 5) {
|
||||
shell->state = 5;
|
||||
shell->state = GREEN_SHELL_HIT_A_RACER;
|
||||
shell->shellId = 1000.0f;
|
||||
temp_v0 = gNearestWaypointByPlayerId[player - gPlayerOne] + 8;
|
||||
if ((s32) D_80164430 < temp_v0) {
|
||||
|
|
@ -1644,7 +1644,7 @@ void update_obj_red_blue_shell(struct ShellActor *shell) {
|
|||
shell->pathIndex = temp_v0;
|
||||
shell->targetPlayer = gPlayerPositionLUT[player->currentRank - 1];
|
||||
} else {
|
||||
shell->state = 3;
|
||||
shell->state = RED_SHELL_LOCK_ON;
|
||||
shell->shellId = 1000.0f;
|
||||
shell->targetPlayer = gPlayerPositionLUT[player->currentRank - 1];
|
||||
}
|
||||
|
|
@ -1664,10 +1664,10 @@ void update_obj_red_blue_shell(struct ShellActor *shell) {
|
|||
func_802B4E30((struct Actor *) shell);
|
||||
func_802B4104(shell);
|
||||
break;
|
||||
case 3:
|
||||
case RED_SHELL_LOCK_ON:
|
||||
func_802B3E7C(shell, &gPlayers[shell->targetPlayer]);
|
||||
break;
|
||||
case 4:
|
||||
case TRIPLE_GREEN_SHELL:
|
||||
func_802B3B44(shell);
|
||||
if (shell->someTimer == 0) {
|
||||
if ((shell->flags & 0xF) == 0) {
|
||||
|
|
@ -1677,7 +1677,7 @@ void update_obj_red_blue_shell(struct ShellActor *shell) {
|
|||
}
|
||||
}
|
||||
break;
|
||||
case 5:
|
||||
case GREEN_SHELL_HIT_A_RACER:
|
||||
func_802B3B44(shell);
|
||||
player = &gPlayers[shell->targetPlayer];
|
||||
temp_f0 = player->pos[0];
|
||||
|
|
@ -1685,10 +1685,10 @@ void update_obj_red_blue_shell(struct ShellActor *shell) {
|
|||
temp_f2 = player->pos[2];
|
||||
temp_f2 -= shell->pos[2];
|
||||
if (((temp_f0 * temp_f0) + (temp_f2 * temp_f2)) < 40000.0f) {
|
||||
shell->state = 3;
|
||||
shell->state = RED_SHELL_LOCK_ON;
|
||||
}
|
||||
break;
|
||||
case 6:
|
||||
case TRIPLE_RED_SHELL:
|
||||
player = &gPlayers[shell->playerId];
|
||||
parent = (TripleShellParent *) &gActorList[shell->parentIndex];
|
||||
if (parent->type != ACTOR_TRIPLE_RED_SHELL) {
|
||||
|
|
@ -1709,7 +1709,7 @@ void update_obj_red_blue_shell(struct ShellActor *shell) {
|
|||
func_802B4E30((struct Actor *) shell);
|
||||
}
|
||||
break;
|
||||
case 7:
|
||||
case DESTROYED_SHELL:
|
||||
shell->velocity[1] -= 0.3f;
|
||||
if (shell->velocity[1] < -5.0f) {
|
||||
shell->velocity[1] = -5.0f;
|
||||
|
|
@ -1721,7 +1721,7 @@ void update_obj_red_blue_shell(struct ShellActor *shell) {
|
|||
destroy_actor((struct Actor *) shell);
|
||||
}
|
||||
break;
|
||||
case 8:
|
||||
case BLUE_SHELL_LOCK_ON:
|
||||
func_802B3B44(shell);
|
||||
shell->targetPlayer = gPlayerPositionLUT[0];
|
||||
player = &gPlayers[gPlayerPositionLUT[0]];
|
||||
|
|
@ -1730,7 +1730,7 @@ void update_obj_red_blue_shell(struct ShellActor *shell) {
|
|||
temp_f2 = player->pos[2];
|
||||
temp_f2 -= shell->pos[2];
|
||||
if (((temp_f0 * temp_f0) + (temp_f2 * temp_f2)) < 40000.0f) {
|
||||
shell->state = 9;
|
||||
shell->state = BLUE_SHELL_TARGET_ELIMINATED;
|
||||
}
|
||||
break;
|
||||
case 9:
|
||||
|
|
|
|||
10
src/camera.c
10
src/camera.c
|
|
@ -1099,7 +1099,7 @@ void func_8001EE98(Player *player, Camera *camera, s8 arg2) {
|
|||
case 0:
|
||||
if (((player->unk_000 & 0x800) == 0x800) || (D_800DC51C == 1)) {
|
||||
D_80152300[var_s0] = 3;
|
||||
} else if (D_800DC5FC == 1) {
|
||||
} else if (gIsGamePaused == 1) {
|
||||
func_8001A0A4((s32) &D_80152300[var_s0], (s32) camera, (s32) player, (s32) arg2, var_s0);
|
||||
} else {
|
||||
func_8001A0DC((s16 *) &D_80152300[var_s0], camera, player, arg2, var_s0);
|
||||
|
|
@ -1117,7 +1117,7 @@ void func_8001EE98(Player *player, Camera *camera, s8 arg2) {
|
|||
D_80152300->unk6 = 3U;
|
||||
} else {
|
||||
D_80164A88 = 0;
|
||||
if (D_800DC5FC == (u16) 1) {
|
||||
if (gIsGamePaused == (u16) 1) {
|
||||
temp_a0 = &D_80152300[var_s0];
|
||||
sp2C = temp_a0;
|
||||
func_8001A0A4((s32) temp_a0, (s32) camera, (s32) player, (s32) arg2, var_s0);
|
||||
|
|
@ -1136,7 +1136,7 @@ void func_8001EE98(Player *player, Camera *camera, s8 arg2) {
|
|||
*(D_80152300 + 4) = 3;
|
||||
*(D_80152300 + 6) = 3;
|
||||
} else {
|
||||
if (D_800DC5FC == (u16) 1) {
|
||||
if (gIsGamePaused == (u16) 1) {
|
||||
temp_a0_3 = &D_80152300[var_s0];
|
||||
sp2C = temp_a0_3;
|
||||
func_8001A0A4((s32) temp_a0_3, (s32) camera, (s32) player, (s32) arg2, var_s0);
|
||||
|
|
@ -1152,7 +1152,7 @@ void func_8001EE98(Player *player, Camera *camera, s8 arg2) {
|
|||
if (((player->unk_000 & 0x800) == 0x800) || (D_800DC51C == (u16) 1) || (D_8015F894 == 2)) {
|
||||
D_80152300[var_s0] = 3;
|
||||
} else {
|
||||
if (D_800DC5FC == (u16) 1) {
|
||||
if (gIsGamePaused == (u16) 1) {
|
||||
temp_a0_5 = &D_80152300[var_s0];
|
||||
sp2C = temp_a0_5;
|
||||
func_8001A0A4((s32) temp_a0_5, (s32) camera, (s32) player, (s32) arg2, var_s0);
|
||||
|
|
@ -1165,7 +1165,7 @@ void func_8001EE98(Player *player, Camera *camera, s8 arg2) {
|
|||
}
|
||||
break;
|
||||
}
|
||||
if (D_800DC5FC == 0) {
|
||||
if (gIsGamePaused == 0) {
|
||||
temp_a0_7 = &D_80152300[var_s0];
|
||||
temp_v0 = *temp_a0_7;
|
||||
switch (temp_v0) { /* switch 1; irregular */
|
||||
|
|
|
|||
|
|
@ -22,7 +22,7 @@
|
|||
extern u16 D_800DC5A8;
|
||||
|
||||
extern s32 D_800DC510;
|
||||
extern u16 D_8015F6FE;
|
||||
extern u16 gNumSpawnedShells;
|
||||
extern u16 D_80152308;
|
||||
extern s32 D_802BA038;
|
||||
extern s16 D_802BA048;
|
||||
|
|
@ -64,7 +64,7 @@ struct UnkStruct_800DC5EC *D_800DC5EC = &D_8015F480[0];
|
|||
struct UnkStruct_800DC5EC *D_800DC5F0 = &D_8015F480[1];
|
||||
struct UnkStruct_800DC5EC *D_800DC5F4 = &D_8015F480[2];
|
||||
struct UnkStruct_800DC5EC *D_800DC5F8 = &D_8015F480[3];
|
||||
u16 D_800DC5FC = 0;
|
||||
u16 gIsGamePaused = 0;
|
||||
u8 *pAppNmiBuffer = (u8 *) &osAppNmiBuffer;
|
||||
s32 gIsMirrorMode = 0;
|
||||
f32 vtxStretchY = 1.0f;
|
||||
|
|
@ -122,7 +122,7 @@ void setup_race(void) {
|
|||
func_8003D080();
|
||||
func_8006E9C0();
|
||||
D_800DC510 = 0;
|
||||
D_8015F6FE = 0;
|
||||
gNumSpawnedShells = 0;
|
||||
D_800DC5B8 = 0;
|
||||
D_80152308 = 0;
|
||||
D_802BA038 = -1;
|
||||
|
|
|
|||
|
|
@ -4314,7 +4314,7 @@ GLOBAL_ASM("asm/non_matchings/code_80005FD0/func_8000DBAC.s")
|
|||
//generated by m2c commit 3b40ab93768f52ac241c5ae84ef58ef6bc4cb1de
|
||||
extern ? D_80163DE8;
|
||||
extern UnkActorInner D_80164038;
|
||||
extern ? D_801641F8;
|
||||
extern ? gUnexpiredActorsList;
|
||||
static struct _struct_D_800DCC08_0xA8 D_800DCC08[0]; /* unable to generate initializer */
|
||||
s16 gCurrentCourseId; /* unable to generate initializer */
|
||||
|
||||
|
|
@ -4380,7 +4380,7 @@ void func_8000DD78(void) {
|
|||
var_s2 += 0x40;
|
||||
var_s3 += 0x18;
|
||||
var_s0 += 0x54;
|
||||
} while (var_s2 != &D_801641F8);
|
||||
} while (var_s2 != &gUnexpiredActorsList);
|
||||
}
|
||||
#else
|
||||
GLOBAL_ASM("asm/non_matchings/code_80005FD0/func_8000DD78.s")
|
||||
|
|
@ -4736,17 +4736,17 @@ void func_8000DF8C(s32 arg0) {
|
|||
GLOBAL_ASM("asm/non_matchings/code_80005FD0/func_8000DF8C.s")
|
||||
#endif
|
||||
|
||||
s32 func_8000ED14(s32 arg0, s16 arg1) {
|
||||
s32 func_8000ED14(s32 actorIndex, s16 arg1) {
|
||||
s32 i;
|
||||
s32 a2 = 0;
|
||||
|
||||
for (i = 0; i < 8; i++) {
|
||||
|
||||
if (D_801641F8[i].unkC == 0) {
|
||||
D_801641F8[i].unkC = 1;
|
||||
D_801641F8[i].unkE = arg0;
|
||||
D_801641F8[i].unk10 = arg1;
|
||||
D_801641F8[i].unk14 = 0;
|
||||
if (gUnexpiredActorsList[i].unkC == 0) {
|
||||
gUnexpiredActorsList[i].unkC = 1;
|
||||
gUnexpiredActorsList[i].actorIndex = actorIndex;
|
||||
gUnexpiredActorsList[i].unk10 = arg1;
|
||||
gUnexpiredActorsList[i].unk14 = 0;
|
||||
a2 = 1;
|
||||
break;
|
||||
}
|
||||
|
|
@ -4757,20 +4757,20 @@ s32 func_8000ED14(s32 arg0, s16 arg1) {
|
|||
return 0;
|
||||
}
|
||||
|
||||
s32 func_8000ED80(s32 arg0) {
|
||||
struct Actor *actor = &gActorList[arg0];
|
||||
s32 func_8000ED80(s32 actorIndex) {
|
||||
struct Actor *actor = &gActorList[actorIndex];
|
||||
if (actor->type != 8) {
|
||||
return -1;
|
||||
}
|
||||
return func_8000ED14(arg0, 0);
|
||||
return func_8000ED14(actorIndex, 0);
|
||||
}
|
||||
|
||||
s32 func_8000EDC8(s32 arg0) {
|
||||
struct Actor *actor = &gActorList[arg0];
|
||||
s32 func_8000EDC8(s32 actorIndex) {
|
||||
struct Actor *actor = &gActorList[actorIndex];
|
||||
if (actor->type != 7) {
|
||||
return -1;
|
||||
}
|
||||
return func_8000ED14(arg0, 1);
|
||||
return func_8000ED14(actorIndex, 1);
|
||||
}
|
||||
|
||||
s32 func_8000EE10(s32 arg0) {
|
||||
|
|
@ -4781,27 +4781,27 @@ s32 func_8000EE10(s32 arg0) {
|
|||
return func_8000ED14(arg0, 2);
|
||||
}
|
||||
|
||||
void func_8000EE58(s32 arg0) {
|
||||
struct unk_41F8 *phi;
|
||||
void func_8000EE58(s32 actorIndex) {
|
||||
struct unexpiredActors *phi;
|
||||
s32 i;
|
||||
|
||||
for (i = 0; i < 8; i++) {
|
||||
phi = &D_801641F8[i];
|
||||
if (arg0 == phi->unkE) {
|
||||
phi = &gUnexpiredActorsList[i];
|
||||
if (actorIndex == phi->actorIndex) {
|
||||
phi->unkC = 0;
|
||||
phi->unkE = 1000;
|
||||
phi->actorIndex = 1000; // out of bounds
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
void func_8000EEDC(void) {
|
||||
struct unk_41F8 *phi;
|
||||
struct unexpiredActors *phi;
|
||||
s32 i;
|
||||
|
||||
for (i = 0; i < 8; i++) {
|
||||
phi = &D_801641F8[i];
|
||||
phi = &gUnexpiredActorsList[i];
|
||||
phi->unkC = 0;
|
||||
phi->unkE = 1000;
|
||||
phi->actorIndex = 1000; // out of bounds
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -4809,12 +4809,12 @@ void func_8000EF20(void) {
|
|||
s32 someIndex;
|
||||
f32 var_f20;
|
||||
struct Actor *temp_s1;
|
||||
struct unk_41F8 *var_s0;
|
||||
struct unexpiredActors *var_s0;
|
||||
|
||||
for (someIndex = 0; someIndex < 8; someIndex++) {
|
||||
var_s0 = &D_801641F8[someIndex];
|
||||
var_s0 = &gUnexpiredActorsList[someIndex];
|
||||
if (var_s0->unkC == 1) {
|
||||
temp_s1 = &gActorList[var_s0->unkE];
|
||||
temp_s1 = &gActorList[var_s0->actorIndex];
|
||||
var_s0->unk14++;
|
||||
switch (var_s0->unk10) {
|
||||
case 0:
|
||||
|
|
|
|||
|
|
@ -14,12 +14,12 @@ struct struct_801642D8 {
|
|||
/* 0xC */ s32 unkC;
|
||||
};
|
||||
|
||||
struct unk_41F8 {
|
||||
struct unexpiredActors {
|
||||
s32 unk0;
|
||||
s32 unk4;
|
||||
s32 unk8;
|
||||
u16 unkC;
|
||||
u16 unkE;
|
||||
u16 actorIndex;
|
||||
s16 unk10;
|
||||
// s16 compilerPadding;
|
||||
u32 unk14;
|
||||
|
|
@ -144,7 +144,7 @@ extern s32 D_80163488;
|
|||
|
||||
extern s32 D_8016337C;
|
||||
extern s32 gModeSelection;
|
||||
extern struct unk_41F8 D_801641F8[];
|
||||
extern struct unexpiredActors gUnexpiredActorsList[];
|
||||
extern s16 D_80164670;
|
||||
extern s16 D_80164672;
|
||||
extern s16 D_80164674;
|
||||
|
|
|
|||
File diff suppressed because it is too large
Load Diff
|
|
@ -910,7 +910,7 @@ void func_80059AC8(void) {
|
|||
s32 var_s0;
|
||||
s32 var_s1;
|
||||
|
||||
if (D_800DC5FC == 0) {
|
||||
if (gIsGamePaused == 0) {
|
||||
func_8008C1D8(&D_80165678);
|
||||
gRaceFrameCounter += 1;
|
||||
var_s2 = D_8018CF68;
|
||||
|
|
@ -1082,7 +1082,7 @@ void func_8005A070(void) {
|
|||
D_8018D120 = 0;
|
||||
D_801655C0 = 0;
|
||||
func_80041D34();
|
||||
if (D_800DC5FC == 0) {
|
||||
if (gIsGamePaused == 0) {
|
||||
func_8005C728();
|
||||
if (gGamestate == ENDING_SEQUENCE) {
|
||||
func_80086604();
|
||||
|
|
|
|||
|
|
@ -234,7 +234,7 @@ extern struct UnkStruct_800DC5EC *D_800DC5F0;
|
|||
extern struct UnkStruct_800DC5EC *D_800DC5F4;
|
||||
extern struct UnkStruct_800DC5EC *D_800DC5F8;
|
||||
|
||||
extern u16 D_800DC5FC;
|
||||
extern u16 gIsGamePaused;
|
||||
|
||||
extern s32 D_80164394;
|
||||
extern s32 D_80164398;
|
||||
|
|
|
|||
|
|
@ -599,7 +599,7 @@ GLOBAL_ASM("asm/non_matchings/code_8006E9C0/func_8006F008.s")
|
|||
//#ifdef MIPS_TO_C
|
||||
//generated by mips_to_c commit 3c3b0cede1a99430bfd3edf8d385802b94f91307
|
||||
//void play_sound2(?); // extern
|
||||
extern u16 D_800DC5FC;
|
||||
extern u16 gIsGamePaused;
|
||||
extern s8 D_801657E4;
|
||||
extern s8 D_801657E6;
|
||||
extern s8 D_801657E8;
|
||||
|
|
@ -627,7 +627,7 @@ void func_8006F824(s32 arg0) {
|
|||
D_80165828 = D_801657F8;
|
||||
D_80165832.unk0 = D_80165800.unk0;
|
||||
D_80165832.unk1 = D_80165800.unk1;
|
||||
if ((arg0 != 0) && (D_800DC5FC == 0)) {
|
||||
if ((arg0 != 0) && (gIsGamePaused == 0)) {
|
||||
play_sound2(SOUND_ACTION_PING);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -5188,7 +5188,7 @@ void func_8009CA6C(s32 arg0) {
|
|||
temp_v1->words.w0 = 0x06000000;
|
||||
temp_v1->words.w1 = (u32) &D_0D0076F8;
|
||||
phi_a1 = 0;
|
||||
if ((arg0 != 4) && (D_800DC5FC != 0)) {
|
||||
if ((arg0 != 4) && (gIsGamePaused != 0)) {
|
||||
phi_a1 = 1;
|
||||
}
|
||||
temp_t0 = *(&D_8018E7AC + arg0);
|
||||
|
|
@ -5444,7 +5444,7 @@ void func_8009CE64(s32 *arg0, s32 arg2, s32 arg3) {
|
|||
break;
|
||||
}
|
||||
if (var_a1_2 != 0) {
|
||||
D_800DC5FC = 0;
|
||||
gIsGamePaused = 0;
|
||||
}
|
||||
}
|
||||
temp_v0_5 = find_8018D9E0_entry(0x000000BD);
|
||||
|
|
@ -9877,7 +9877,7 @@ GLOBAL_ASM("asm/non_matchings/code_80091750/func_800A4A24.s")
|
|||
#endif
|
||||
|
||||
void func_800A4B38(struct_8018D9E0_entry *arg0) {
|
||||
if (D_800DC5FC != 0) {
|
||||
if (gIsGamePaused != 0) {
|
||||
switch (gModeSelection) {
|
||||
case TIME_TRIALS:
|
||||
func_800A4BC8(arg0);
|
||||
|
|
@ -10002,13 +10002,13 @@ void func_800A4EF8(struct_8018D9E0_entry *arg0) {
|
|||
s32 phi_s1;
|
||||
s32 phi_s0;
|
||||
|
||||
temp_v0 = (D_800DC5FC << 6) - 0x40 + &D_8015F480;
|
||||
temp_v0 = (gIsGamePaused << 6) - 0x40 + &D_8015F480;
|
||||
temp_v1 = temp_v0->unk30;
|
||||
temp_t0 = temp_v0->unk32;
|
||||
temp_t3 = (s32) temp_v0->unk2C / 2;
|
||||
temp_t4 = (s32) temp_v0->unk2E / 2;
|
||||
gDisplayListHead = draw_box(gDisplayListHead, temp_v1 - temp_t3, temp_t0 - temp_t4, temp_v1 + temp_t3, temp_t0 + temp_t4, 0, 0, 0, 0x8C);
|
||||
temp_s3 = ((gScreenModeSelection << 5) + (D_800DC5FC * 8)) - 8 + &D_800E8540;
|
||||
temp_s3 = ((gScreenModeSelection << 5) + (gIsGamePaused * 8)) - 8 + &D_800E8540;
|
||||
phi_a1 = 0;
|
||||
phi_s2 = 0;
|
||||
do {
|
||||
|
|
@ -10082,13 +10082,13 @@ void func_800A5084(struct_8018D9E0_entry *arg0) {
|
|||
s32 phi_s1;
|
||||
s8 **phi_s2;
|
||||
|
||||
temp_v0 = (D_800DC5FC << 6) - 0x40 + &D_8015F480;
|
||||
temp_v0 = (gIsGamePaused << 6) - 0x40 + &D_8015F480;
|
||||
temp_v1 = temp_v0->unk30;
|
||||
temp_t0 = temp_v0->unk32;
|
||||
temp_t3 = (s32) temp_v0->unk2C / 2;
|
||||
temp_t4 = (s32) temp_v0->unk2E / 2;
|
||||
gDisplayListHead = draw_box(gDisplayListHead, temp_v1 - temp_t3, temp_t0 - temp_t4, temp_v1 + temp_t3, temp_t0 + temp_t4, 0, 0, 0, 0x8C);
|
||||
temp_s3 = ((gScreenModeSelection << 5) + (D_800DC5FC * 8)) - 8 + &D_800E85C0;
|
||||
temp_s3 = ((gScreenModeSelection << 5) + (gIsGamePaused * 8)) - 8 + &D_800E85C0;
|
||||
temp_s0 = (s32) ((((f32) get_string_width(D_800E7500[gCupSelection]) * 1.0f) + 10.0f) / 2.0f);
|
||||
temp_s1 = (s32) ((((f32) get_string_width(D_800E76CC[gCCSelection]) * 1.0f) + 10.0f) / 2.0f);
|
||||
set_text_color(3);
|
||||
|
|
@ -10141,13 +10141,13 @@ void func_800A5360(struct_8018D9E0_entry *arg0) {
|
|||
s32 phi_s1;
|
||||
s32 phi_s0;
|
||||
|
||||
temp_v0 = (D_800DC5FC << 6) - 0x40 + &D_8015F480;
|
||||
temp_v0 = (gIsGamePaused << 6) - 0x40 + &D_8015F480;
|
||||
temp_v1 = temp_v0->unk30;
|
||||
temp_t0 = temp_v0->unk32;
|
||||
temp_t3 = (s32) temp_v0->unk2C / 2;
|
||||
temp_t4 = (s32) temp_v0->unk2E / 2;
|
||||
gDisplayListHead = draw_box(gDisplayListHead, temp_v1 - temp_t3, temp_t0 - temp_t4, temp_v1 + temp_t3, temp_t0 + temp_t4, 0, 0, 0, 0x8C);
|
||||
temp_s3 = ((gScreenModeSelection << 5) + (D_800DC5FC * 8)) - 8 + &D_800E8600;
|
||||
temp_s3 = ((gScreenModeSelection << 5) + (gIsGamePaused * 8)) - 8 + &D_800E8600;
|
||||
phi_a1 = 0;
|
||||
phi_s2 = 0;
|
||||
do {
|
||||
|
|
@ -10190,7 +10190,7 @@ void func_800A54EC(void) {
|
|||
s32 temp_t2;
|
||||
? *phi_v1;
|
||||
|
||||
if (D_800DC5FC != 0) {
|
||||
if (gIsGamePaused != 0) {
|
||||
temp_t2 = gModeSelection;
|
||||
sp40 = temp_t2;
|
||||
temp_v1 = gDisplayListHead;
|
||||
|
|
@ -10213,13 +10213,13 @@ void func_800A54EC(void) {
|
|||
phi_v1 = &D_800E8538;
|
||||
break;
|
||||
case VERSUS:
|
||||
phi_v1 = ((gScreenModeSelection << 5) + (D_800DC5FC * 8)) - 8 + &D_800E8540;
|
||||
phi_v1 = ((gScreenModeSelection << 5) + (gIsGamePaused * 8)) - 8 + &D_800E8540;
|
||||
break;
|
||||
case GRAND_PRIX:
|
||||
phi_v1 = ((gScreenModeSelection << 5) + (D_800DC5FC * 8)) - 8 + &D_800E85C0;
|
||||
phi_v1 = ((gScreenModeSelection << 5) + (gIsGamePaused * 8)) - 8 + &D_800E85C0;
|
||||
break;
|
||||
case BATTLE:
|
||||
phi_v1 = ((gScreenModeSelection << 5) + (D_800DC5FC * 8)) - 8 + &D_800E8600;
|
||||
phi_v1 = ((gScreenModeSelection << 5) + (gIsGamePaused * 8)) - 8 + &D_800E8600;
|
||||
break;
|
||||
}
|
||||
sp50 = phi_v1->unk0 - 8;
|
||||
|
|
@ -14873,7 +14873,7 @@ void func_800ADF48(struct_8018D9E0_entry *arg0) {
|
|||
s32 stackPadding;
|
||||
struct Controller *controller;
|
||||
|
||||
if (D_800DC5FC != 0) {
|
||||
if (gIsGamePaused != 0) {
|
||||
switch (arg0->unk4) {
|
||||
case 0:
|
||||
arg0->unk4 = D_800F0B50[gModeSelection];
|
||||
|
|
@ -14894,7 +14894,7 @@ void func_800ADF48(struct_8018D9E0_entry *arg0) {
|
|||
case 43:
|
||||
case 44:
|
||||
if (func_800B4520() == 0) {
|
||||
controller = &gControllers[D_800DC5FC - 1];
|
||||
controller = &gControllers[gIsGamePaused - 1];
|
||||
if ((controller->buttonPressed | controller->stickPressed) & 0x800) {
|
||||
if (D_800F0B50[gModeSelection] < arg0->unk4) {
|
||||
arg0->unk4--;
|
||||
|
|
@ -14925,7 +14925,7 @@ void func_800ADF48(struct_8018D9E0_entry *arg0) {
|
|||
if (controller->buttonPressed & 0x9000) {
|
||||
if (arg0->unk4 == D_800F0B50[gModeSelection]) {
|
||||
arg0->unk4 = 0;
|
||||
D_800DC5FC = 0;
|
||||
gIsGamePaused = 0;
|
||||
func_8028DF38();
|
||||
func_800C9F90(0U);
|
||||
} else {
|
||||
|
|
|
|||
|
|
@ -878,31 +878,25 @@ s32 func_800B6088(s32 arg0) {
|
|||
return osPfsReadWriteFile(&gControllerPak1FileHandle, gControllerPak1FileNote, PFS_WRITE, arg0 * 0x80 /* 0x80 == sizeof(struct_8018EE10_entry) */, sizeof(struct_8018EE10_entry), (u8*) temp_v1);
|
||||
}
|
||||
|
||||
#ifdef MIPS_TO_C
|
||||
//generated by mips_to_c commit 3c3b0cede1a99430bfd3edf8d385802b94f91307
|
||||
extern s32 D_800DC714;
|
||||
#ifdef NON_MATCHING
|
||||
|
||||
s32 func_800B60E8(s32 arg0) {
|
||||
s32 temp_a2;
|
||||
s32 temp_v0;
|
||||
s32 temp_v1;
|
||||
s32 phi_v0;
|
||||
s32 phi_v1;
|
||||
void *phi_a1;
|
||||
struct struct_D_800DC714
|
||||
{
|
||||
u8 filler[0x100];
|
||||
};
|
||||
|
||||
temp_a2 = arg0 + 1;
|
||||
phi_v0 = 0;
|
||||
phi_v1 = 0;
|
||||
phi_a1 = D_800DC714 + (arg0 << 8);
|
||||
do {
|
||||
temp_v0 = phi_v0 + 4;
|
||||
temp_v1 = phi_v1 + ((phi_a1->unk0 * temp_a2) + phi_v0) + ((phi_a1->unk1 * temp_a2) + phi_v0) + 1 + ((phi_a1->unk2 * temp_a2) + phi_v0) + 2 + ((phi_a1->unk3 * temp_a2) + phi_v0) + 3;
|
||||
phi_v0 = temp_v0;
|
||||
phi_v1 = temp_v1;
|
||||
phi_a1 += 4;
|
||||
} while (temp_v0 != 0x100);
|
||||
return temp_v1 & 0xFF;
|
||||
u8 func_800B60E8(s32 arg0)
|
||||
{
|
||||
u8 *addr = *(s32 *)&D_800DC714 + (arg0 << 8);
|
||||
s32 checksum = 0, i;
|
||||
|
||||
for (i = 0; i < sizeof(struct struct_D_800DC714); i++)
|
||||
{
|
||||
checksum = i + ((arg0 + 1) * *addr++) + checksum;
|
||||
}
|
||||
return checksum;
|
||||
}
|
||||
|
||||
#else
|
||||
GLOBAL_ASM("asm/non_matchings/menus/func_800B60E8.s")
|
||||
#endif
|
||||
|
|
|
|||
|
|
@ -1,6 +1,7 @@
|
|||
#include <ultra64.h>
|
||||
#include <macros.h>
|
||||
#include <defines.h>
|
||||
#include <debug.h>
|
||||
#include <PR/gu.h>
|
||||
|
||||
#include "main.h"
|
||||
|
|
@ -75,7 +76,7 @@ void func_80280268(s32 arg0) {
|
|||
|
||||
void credits_loop(void) {
|
||||
Camera *camera = &cameras[0];
|
||||
|
||||
|
||||
f32 temp_f12;
|
||||
f32 temp;
|
||||
f32 temp_f14;
|
||||
|
|
@ -103,6 +104,9 @@ void credits_loop(void) {
|
|||
} else {
|
||||
func_80280000();
|
||||
func_80280038();
|
||||
#if DVDL
|
||||
display_dvdl();
|
||||
#endif
|
||||
gDPFullSync(gDisplayListHead++);
|
||||
gSPEndDisplayList(gDisplayListHead++);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,6 +1,7 @@
|
|||
#include <ultra64.h>
|
||||
#include <macros.h>
|
||||
#include <types.h>
|
||||
#include <debug.h>
|
||||
#include <common_structs.h>
|
||||
#include "main.h"
|
||||
#include "memory.h"
|
||||
|
|
@ -483,6 +484,9 @@ void ending_sequence_loop(void) {
|
|||
}
|
||||
func_80281D00();
|
||||
func_80281540();
|
||||
#if VARIABLE_WATCH_DEBUG_LIST
|
||||
display_dvdl();
|
||||
#endif
|
||||
gDPFullSync(gDisplayListHead++);
|
||||
gSPEndDisplayList(gDisplayListHead++);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -0,0 +1,78 @@
|
|||
/**
|
||||
* please do not include this file.
|
||||
* ONLY FOR DEBUG PURPOSE
|
||||
*/
|
||||
#ifndef _VARIABLES_H_
|
||||
#define _VARIABLES_H_
|
||||
|
||||
// #include <actors_extended.h> does not work
|
||||
#include <actors.h>
|
||||
#include <camera.h>
|
||||
#include <camera_junk.h>
|
||||
#include <ceremony_and_credits.h>
|
||||
#include <code_800029B0.h>
|
||||
#include <code_80004740.h>
|
||||
#include <code_80005FD0.h>
|
||||
#include <code_8001F980.h>
|
||||
#include <code_80027D00.h>
|
||||
#include <code_8003DC40.h>
|
||||
#include <code_80057C60.h>
|
||||
#include <code_8006E9C0.h>
|
||||
#include <code_80071F00.h>
|
||||
#include <code_80086E70.h>
|
||||
#include <code_8008C1D0.h>
|
||||
#include <code_80091440.h>
|
||||
#include <code_80091750.h>
|
||||
#include <code_800AF9B0.h>
|
||||
#include <code_800B45E0.h>
|
||||
#include <code_80280000.h>
|
||||
#include <code_80280650.h>
|
||||
#include <code_80281780.h>
|
||||
#include <code_80281C40.h>
|
||||
#include <code_802AAA70.h>
|
||||
#include <common_textures.h>
|
||||
#include <credits.h>
|
||||
#include <data_segment2.h>
|
||||
#include <framebuffers.h>
|
||||
#include <hud_renderer.h>
|
||||
#include <kart_dma.h>
|
||||
#include <main.h>
|
||||
#include <math_util_2.h>
|
||||
#include <math_util.h>
|
||||
#include <memory.h>
|
||||
#include <menus.h>
|
||||
#include <profiler.h>
|
||||
#include <race_logic.h>
|
||||
#include <render_courses.h>
|
||||
#include <skybox_and_splitscreen.h>
|
||||
#include <spawn_players.h>
|
||||
#include <staff_ghosts.h>
|
||||
#include <textures.h>
|
||||
|
||||
#include <actor_types.h>
|
||||
#include <common_structs.h>
|
||||
#include <config.h>
|
||||
#include <course.h>
|
||||
#include <course_offsets.h>
|
||||
#include <debug.h>
|
||||
#include <defines.h>
|
||||
#include <functions.h>
|
||||
#include <global.h>
|
||||
#include <kart_attributes.h>
|
||||
#include <macros.h>
|
||||
#include <mk64.h>
|
||||
#include <objects.h>
|
||||
// #include <packed_displaylist_symbols_gen.h> does not work
|
||||
#include <packed_displaylist_symbols.h>
|
||||
#include <segments.h>
|
||||
#include <segment_symbols.h>
|
||||
#include <sounds.h>
|
||||
#include <trig_tables.h>
|
||||
#include <types.h>
|
||||
#include <ultra64.h>
|
||||
#include <variables.h>
|
||||
#include <vehicles.h>
|
||||
#include <vertice_count_gen.h>
|
||||
#include <waypoints.h>
|
||||
|
||||
#endif
|
||||
|
|
@ -0,0 +1,251 @@
|
|||
#include <ultra64.h>
|
||||
#include <debug.h>
|
||||
#include "debug.inc.c"
|
||||
#include <libc/stdio.h>
|
||||
|
||||
#if DVDL
|
||||
|
||||
u8 sDisplayListState = OK;
|
||||
|
||||
static u32 variable_to_u64(variableWatchAttributes *);
|
||||
static void round_up_float(u32 *, u8);
|
||||
static void u64_to_string(variableWatchAttributes *, u32, u8);
|
||||
static u32 _strlen(const char *);
|
||||
static void _memcpy(char *, const char *, u32);
|
||||
|
||||
void display_dvdl(void) {
|
||||
u32 variable;
|
||||
u32 i, vNameLen;
|
||||
u32 arraySize = sizeof(gMainVariableWatchList) / sizeof(variableWatchAttributes);
|
||||
s32 text_y_possition = TEXT_Y_POSSITION;
|
||||
u8 base;
|
||||
char *vName, *cBuffer;
|
||||
|
||||
load_debug_font();
|
||||
for (i = 0; i < arraySize; i++) {
|
||||
variableWatchAttributes *currentAttribute = &gMainVariableWatchList[i];
|
||||
currentAttribute->characterBuffer = currentAttribute->buffer;
|
||||
cBuffer = currentAttribute->characterBuffer;
|
||||
vName = currentAttribute->variableName;
|
||||
|
||||
variable = variable_to_u64(currentAttribute);
|
||||
base = 0;
|
||||
|
||||
if (currentAttribute->variableFlag & (DISPLAY_FLOAT_AS_TYPE | DISPLAY_FLOAT_WITH_ROUNDING)) {
|
||||
if (currentAttribute->variableFlag & DISPLAY_FLOAT_NUMBER) {
|
||||
sDisplayListState = BAD;
|
||||
} else if (currentAttribute->variableFlag & DISPLAY_FLOAT_WITH_ROUNDING) {
|
||||
round_up_float(&variable, currentAttribute->variableSize);
|
||||
}
|
||||
}
|
||||
|
||||
switch (currentAttribute->variableFlag & 0x8F) {
|
||||
case DISPLAY_FLOAT_NUMBER:
|
||||
sprintf(cBuffer, "%.3f", *(f32*)&variable);
|
||||
break;
|
||||
case DISPLAY_HEXIDECIMAL_NUMBER:
|
||||
base = HEXIDECIMAL;
|
||||
break;
|
||||
case DISPLAY_DECIMAL_NUMBER:
|
||||
base = DECIMAL;
|
||||
break;
|
||||
case DISPLAY_OCTAL_NUMBER:
|
||||
base = OCTAL;
|
||||
break;
|
||||
case DISPLAY_BINARY_NUMBER:
|
||||
base = BINARY;
|
||||
break;
|
||||
default:
|
||||
sDisplayListState = BAD;
|
||||
}
|
||||
if (base) {
|
||||
u64_to_string(currentAttribute, variable, base);
|
||||
}
|
||||
|
||||
if (sDisplayListState == BAD) {
|
||||
cBuffer = "NaN";
|
||||
}
|
||||
sDisplayListState = OK;
|
||||
|
||||
vNameLen = _strlen(vName);
|
||||
|
||||
debug_print_str2(TEXT_X_POSSITION, text_y_possition, vName);
|
||||
debug_print_str2(TEXT_X_POSSITION + (vNameLen * 0x8), text_y_possition, cBuffer);
|
||||
text_y_possition += 0x8;
|
||||
}
|
||||
gSPDisplayList(gDisplayListHead++, D_0D007EB8);
|
||||
gSPDisplayList(gDisplayListHead++, D_020076E0);
|
||||
func_80093C98(1);
|
||||
}
|
||||
|
||||
static u32 variable_to_u64(variableWatchAttributes *attribute) {
|
||||
u32 variable;
|
||||
|
||||
switch (attribute->variableSize) {
|
||||
case sizeof(u8):
|
||||
variable = *((u8*) attribute->variablePointer);
|
||||
break;
|
||||
case sizeof(u16):
|
||||
variable = *((u16*) attribute->variablePointer);
|
||||
break;
|
||||
case sizeof(u32):
|
||||
case sizeof(u64):
|
||||
variable = *((u32*) attribute->variablePointer); // no floating point rounding
|
||||
break;
|
||||
default:
|
||||
sDisplayListState = BAD;
|
||||
}
|
||||
|
||||
return variable;
|
||||
}
|
||||
|
||||
static void round_up_float(u32 *variable, u8 variableSize) {
|
||||
switch (variableSize) {
|
||||
case sizeof(u64):
|
||||
case sizeof(u32):
|
||||
*variable = (u32) (*(f32*) &*variable);
|
||||
break;
|
||||
default:
|
||||
sDisplayListState = BAD;
|
||||
}
|
||||
}
|
||||
|
||||
static void u64_to_string(variableWatchAttributes *attribute, u32 variable, u8 base) {
|
||||
s32 signedVariable;
|
||||
u32 stringDifference, indexesToFillAVariable, stringLengthWithZero;
|
||||
u32 indexesToFillAByte, upperIndex, remainder;
|
||||
u32 stringLength, lowerIndex, i;
|
||||
u8 variableSize;
|
||||
char *bufferedString;
|
||||
char swapRegister;
|
||||
|
||||
if (sDisplayListState == BAD) {
|
||||
return;
|
||||
}
|
||||
|
||||
bufferedString = attribute->characterBuffer;
|
||||
variableSize = attribute->variableSize;
|
||||
|
||||
// converts a minus number into it's unsigned equivalent for proper string conversion
|
||||
if (attribute->variableFlag & DISPLAY_SIGNED_NUMBER) {
|
||||
switch (variableSize) {
|
||||
case sizeof(u8):
|
||||
signedVariable = (s8) variable;
|
||||
if (signedVariable < 0) {
|
||||
signedVariable = -signedVariable;
|
||||
variable = (u8) signedVariable;
|
||||
*bufferedString = '-';
|
||||
bufferedString++;
|
||||
}
|
||||
break;
|
||||
case sizeof(u16):
|
||||
signedVariable = (s16) variable;
|
||||
if (signedVariable < 0) {
|
||||
signedVariable = -signedVariable;
|
||||
variable = (u16) signedVariable;
|
||||
*bufferedString = '-';
|
||||
bufferedString++;
|
||||
}
|
||||
break;
|
||||
case sizeof(u32):
|
||||
case sizeof(u64):
|
||||
signedVariable = (s32) variable;
|
||||
if (signedVariable < 0) {
|
||||
signedVariable = -signedVariable;
|
||||
variable = (u32) signedVariable;
|
||||
*bufferedString = '-';
|
||||
bufferedString++;
|
||||
}
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
stringLength = 0;
|
||||
|
||||
// convert u64 into a string but it gets put in reverse
|
||||
if (base != HEXIDECIMAL) {
|
||||
do {
|
||||
stringLength++;
|
||||
*bufferedString = variable % base + '0';
|
||||
bufferedString++;
|
||||
variable /= base;
|
||||
} while (variable != 0);
|
||||
} else {
|
||||
do {
|
||||
stringLength++;
|
||||
remainder = variable % 16;
|
||||
|
||||
if ((remainder >= 0) && (remainder <= 9)) {
|
||||
*bufferedString = '0' + remainder;
|
||||
} else {
|
||||
*bufferedString = 'A' + (remainder - 10);
|
||||
}
|
||||
|
||||
bufferedString++;
|
||||
variable /= 16;
|
||||
} while (variable != 0);
|
||||
}
|
||||
|
||||
bufferedString -= stringLength;
|
||||
upperIndex = stringLength - 1;
|
||||
|
||||
// flip string 4321 --> 1234
|
||||
for (lowerIndex = 0; lowerIndex < stringLength >> 1; lowerIndex++) {
|
||||
swapRegister = bufferedString[lowerIndex];
|
||||
bufferedString[lowerIndex] = bufferedString[upperIndex];
|
||||
bufferedString[upperIndex] = swapRegister;
|
||||
upperIndex--;
|
||||
}
|
||||
|
||||
switch (base) {
|
||||
case BINARY:
|
||||
indexesToFillAByte = 8;
|
||||
break;
|
||||
case OCTAL:
|
||||
indexesToFillAByte = 3;
|
||||
break;
|
||||
case DECIMAL:
|
||||
bufferedString[stringLength] = '\0';
|
||||
return;
|
||||
case HEXIDECIMAL:
|
||||
indexesToFillAByte = 2;
|
||||
break;
|
||||
}
|
||||
|
||||
stringLengthWithZero = stringLength - 1;
|
||||
indexesToFillAVariable = indexesToFillAByte * variableSize;
|
||||
stringDifference = indexesToFillAVariable - stringLengthWithZero;
|
||||
|
||||
// makes space and fills in extra space. u32 FE -> 000000FE
|
||||
for (i = stringLength; i > 0; i--) {
|
||||
bufferedString[stringDifference + i - 2] = bufferedString[i - 1];
|
||||
}
|
||||
for (i = 0; i < stringDifference - 1; i++) {
|
||||
bufferedString[i] = '0';
|
||||
}
|
||||
bufferedString[indexesToFillAVariable] = '\0';
|
||||
}
|
||||
|
||||
static u32 _strlen(const char *str) {
|
||||
u32 len;
|
||||
|
||||
len = 0;
|
||||
for (; *str != '\0'; str++) {
|
||||
len++;
|
||||
}
|
||||
|
||||
return len;
|
||||
}
|
||||
|
||||
// unused but may be useful
|
||||
static void _memcpy(char *destStr, const char *copyStr, u32 copySize) {
|
||||
u32 i;
|
||||
|
||||
for (i = 0; i < copySize; i++) {
|
||||
*destStr = *copyStr;
|
||||
destStr++;
|
||||
copyStr++;
|
||||
}
|
||||
}
|
||||
|
||||
#endif
|
||||
|
|
@ -0,0 +1,58 @@
|
|||
#include <ultra64.h>
|
||||
#include <debug.h>
|
||||
#include "all_variables.h"
|
||||
|
||||
#if DVDL
|
||||
|
||||
extern s32 gGlobalTimer;
|
||||
|
||||
/**
|
||||
* Edit this to edit what displays on the screen while the DVDL is active.
|
||||
* The Size of the structure array is calculated at compile time.
|
||||
*/
|
||||
variableWatchAttributes gMainVariableWatchList[] = {
|
||||
{
|
||||
"Global Timer: ",
|
||||
&gGlobalTimer,
|
||||
sizeof(gGlobalTimer),
|
||||
DISPLAY_DECIMAL_NUMBER | DISPLAY_SIGNED_NUMBER,
|
||||
0, 0
|
||||
},
|
||||
{
|
||||
"Actors: ",
|
||||
&gNumActors,
|
||||
sizeof(gNumActors),
|
||||
DISPLAY_DECIMAL_NUMBER,
|
||||
0, 0
|
||||
},
|
||||
{
|
||||
"Player Type: ",
|
||||
&gPlayers[0].unk_000,
|
||||
sizeof(gPlayerOne->unk_000),
|
||||
DISPLAY_HEXIDECIMAL_NUMBER,
|
||||
0, 0
|
||||
},
|
||||
{
|
||||
"X ",
|
||||
&gPlayers[0].pos[0],
|
||||
sizeof(gPlayerOne->pos[0]),
|
||||
DISPLAY_FLOAT_NUMBER,
|
||||
0, 0
|
||||
},
|
||||
{
|
||||
"Y ",
|
||||
&gPlayers[0].pos[1],
|
||||
sizeof(gPlayerOne->pos[1]),
|
||||
DISPLAY_FLOAT_NUMBER,
|
||||
0, 0
|
||||
},
|
||||
{
|
||||
"Z ",
|
||||
&gPlayers[0].pos[2],
|
||||
sizeof(gPlayerOne->pos[2]),
|
||||
DISPLAY_FLOAT_NUMBER,
|
||||
0, 0
|
||||
},
|
||||
};
|
||||
|
||||
#endif
|
||||
|
|
@ -5202,7 +5202,7 @@ void func_80055164(s32 objectIndex) {
|
|||
temp_a3->words.w1 = (u32) D_0D0077A0;
|
||||
sp18 = temp_v1;
|
||||
func_80042E00(temp_v1->unk_004, (s16 *) temp_v1->unk_0BE, temp_v1->unk_000);
|
||||
if (D_800DC5FC == 0) {
|
||||
if (gIsGamePaused == 0) {
|
||||
sp18 = temp_v1;
|
||||
temp_v1->unk_0A2 = func_80004DFC(temp_v1->unk_070, temp_v1->unk_074, 0, temp_v1->unk_0A2);
|
||||
return;
|
||||
|
|
@ -5254,7 +5254,7 @@ void func_800552BC(s32 objectIndex) {
|
|||
gDisplayListHead = temp_a0 + 8;
|
||||
temp_a0->words.w0 = 0x06000000;
|
||||
temp_a0->words.w1 = (u32) D_0D0077D0;
|
||||
if (D_800DC5FC == 0) {
|
||||
if (gIsGamePaused == 0) {
|
||||
sp18 = temp_v1;
|
||||
temp_v1->unk_0A2 = func_80004DFC(temp_v1->unk_070, temp_v1->unk_074, 0, temp_v1->unk_0A2);
|
||||
return;
|
||||
|
|
@ -6198,8 +6198,8 @@ void func_80057778(void) {
|
|||
gSPDisplayList(gDisplayListHead++, D_0D007EB8);
|
||||
}
|
||||
|
||||
void debug_print_str2(s32 arg0, s32 arg1, char *arg2) {
|
||||
debug_print_string(&arg0, &arg1, arg2);
|
||||
void debug_print_str2(s32 xPos, s32 yPos, char *str) {
|
||||
debug_print_string(&xPos, &yPos, str);
|
||||
}
|
||||
|
||||
void print_str_num(s32 arg0, s32 arg1, char *arg2, u32 arg3) {
|
||||
|
|
|
|||
33
src/main.c
33
src/main.c
|
|
@ -32,7 +32,7 @@
|
|||
#include "render_courses.h"
|
||||
#include "actors.h"
|
||||
#include "staff_ghosts.h"
|
||||
#include <defines.h>
|
||||
#include <debug.h>
|
||||
|
||||
// Declarations (not in this file)
|
||||
void func_80091B78(void);
|
||||
|
|
@ -538,7 +538,7 @@ void race_logic_loop(void) {
|
|||
|
||||
D_80150112 = 0;
|
||||
D_80164AF0 = 0;
|
||||
if (D_800DC5FC != 0) {
|
||||
if (gIsGamePaused != 0) {
|
||||
func_80290B14();
|
||||
}
|
||||
if (gIsInQuitToMenuTransition != 0) {
|
||||
|
|
@ -557,8 +557,7 @@ void race_logic_loop(void) {
|
|||
case SCREEN_MODE_1P:
|
||||
gTickSpeed = 2;
|
||||
staff_ghosts_loop();
|
||||
if (D_800DC5FC == 0) {
|
||||
|
||||
if (gIsGamePaused == 0) {
|
||||
for (i = 0; i < gTickSpeed; i++) {
|
||||
if (D_8015011E) {
|
||||
gCourseTimer += 0.01666666; // 1 / 60
|
||||
|
|
@ -623,7 +622,7 @@ void race_logic_loop(void) {
|
|||
} else {
|
||||
gTickSpeed = 2;
|
||||
}
|
||||
if (D_800DC5FC == 0) {
|
||||
if (gIsGamePaused == 0) {
|
||||
for (i = 0; i < gTickSpeed; i++) {
|
||||
if (D_8015011E != 0) {
|
||||
gCourseTimer += 0.01666666;
|
||||
|
|
@ -669,7 +668,7 @@ void race_logic_loop(void) {
|
|||
gTickSpeed = 2;
|
||||
}
|
||||
|
||||
if (D_800DC5FC == 0) {
|
||||
if (gIsGamePaused == 0) {
|
||||
for (i = 0; i < gTickSpeed; i++) {
|
||||
if (D_8015011E != 0) {
|
||||
gCourseTimer += 0.01666666;
|
||||
|
|
@ -737,7 +736,7 @@ void race_logic_loop(void) {
|
|||
break;
|
||||
}
|
||||
}
|
||||
if (D_800DC5FC == 0) {
|
||||
if (gIsGamePaused == 0) {
|
||||
for (i = 0; i < gTickSpeed; i++) {
|
||||
if (D_8015011E != 0) {
|
||||
gCourseTimer += 0.01666666;
|
||||
|
|
@ -815,6 +814,9 @@ void race_logic_loop(void) {
|
|||
func_802A4300();
|
||||
func_800591B4();
|
||||
func_80093E20();
|
||||
#if DVDL
|
||||
display_dvdl();
|
||||
#endif
|
||||
gDPFullSync(gDisplayListHead++);
|
||||
gSPEndDisplayList(gDisplayListHead++);
|
||||
}
|
||||
|
|
@ -833,6 +835,20 @@ void race_logic_loop(void) {
|
|||
*/
|
||||
|
||||
void game_state_handler(void) {
|
||||
#if DVDL
|
||||
if ((gControllerOne->button & L_TRIG) &&
|
||||
(gControllerOne->button & R_TRIG) &&
|
||||
(gControllerOne->button & Z_TRIG) &&
|
||||
(gControllerOne->button & A_BUTTON)) {
|
||||
gGamestateNext = CREDITS_SEQUENCE;
|
||||
} else if ((gControllerOne->button & L_TRIG) &&
|
||||
(gControllerOne->button & R_TRIG) &&
|
||||
(gControllerOne->button & Z_TRIG) &&
|
||||
(gControllerOne->button & B_BUTTON)) {
|
||||
gGamestateNext = ENDING_SEQUENCE;
|
||||
}
|
||||
#endif
|
||||
|
||||
switch (gGamestate) {
|
||||
case 7:
|
||||
game_init_clear_framebuffer();
|
||||
|
|
@ -847,6 +863,9 @@ void game_state_handler(void) {
|
|||
init_rcp();
|
||||
// gGfxPool->mtxPool->m or gGfxPool?
|
||||
func_80094A64((Mtx *) gGfxPool->mtxPool->m);
|
||||
#if DVDL
|
||||
display_dvdl();
|
||||
#endif
|
||||
break;
|
||||
case RACING:
|
||||
race_logic_loop();
|
||||
|
|
|
|||
|
|
@ -116,7 +116,7 @@ extern s16 gCurrentlyLoadedCourseId;
|
|||
extern s16 gCurrentCourseId;
|
||||
|
||||
extern s16 D_80164AF0;
|
||||
extern u16 D_800DC5FC;
|
||||
extern u16 gIsGamePaused; // 1 if the game is paused and 0 if the game is not paused
|
||||
extern u16 gIsInQuitToMenuTransition;
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -3,6 +3,12 @@
|
|||
#include <string.h>
|
||||
#include "printf.h"
|
||||
|
||||
#if DEBUG
|
||||
#define STATIC
|
||||
#else
|
||||
#define STATIC static
|
||||
#endif
|
||||
|
||||
#define ATOI(i, a) \
|
||||
for (i = 0; *a >= '0' && *a <= '9'; a++) \
|
||||
if (i < 999) \
|
||||
|
|
@ -31,7 +37,7 @@ const u32 flags_arr[] = { FLAGS_SPACE, FLAGS_PLUS, FLAGS_MINUS, FLAGS_HASH, FLAG
|
|||
char _spaces[] = " ";
|
||||
char _zeroes[] = "00000000000000000000000000000000";
|
||||
|
||||
static void _Putfld(printf_struct *, va_list *, u8, u8 *);
|
||||
STATIC void _Putfld(printf_struct *, va_list *, u8, u8 *);
|
||||
|
||||
s32 _Printf(char *(*prout)(char *, const char *, size_t), char *dst, const char *fmt, va_list args) {
|
||||
printf_struct sp78;
|
||||
|
|
@ -111,7 +117,7 @@ s32 _Printf(char *(*prout)(char *, const char *, size_t), char *dst, const char
|
|||
}
|
||||
}
|
||||
|
||||
static void _Putfld(printf_struct *a0, va_list *args, u8 type, u8 *buff) {
|
||||
STATIC void _Putfld(printf_struct *a0, va_list *args, u8 type, u8 *buff) {
|
||||
a0->part1_len = a0->num_leading_zeros = a0->part2_len = a0->num_mid_zeros = a0->part3_len =
|
||||
a0->num_trailing_zeros = 0;
|
||||
|
||||
|
|
|
|||
|
|
@ -9,7 +9,7 @@ int sprintf(char *dst, const char *fmt, ...) {
|
|||
s32 written;
|
||||
va_list args;
|
||||
va_start(args, fmt);
|
||||
written = _Putfld(proutSprintf, dst, fmt, args);
|
||||
written = _Printf(proutSprintf, dst, fmt, args);
|
||||
if (written >= 0) {
|
||||
dst[written] = 0;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -886,7 +886,7 @@ loop_2:
|
|||
}
|
||||
if ((temp_s0->buttonPressed & START_BUTTON) && (temp_v0_3 = temp_s0->button, ((temp_v0_3 & R_TRIG) == 0)) && !(temp_v0_3 & L_TRIG)) {
|
||||
func_8028DF00();
|
||||
D_800DC5FC = ((s32) (temp_s0 - gControllerOne) >> 4) + 1;
|
||||
gIsGamePaused = ((s32) (temp_s0 - gControllerOne) >> 4) + 1;
|
||||
temp_s0->buttonPressed = 0;
|
||||
func_800C9F90(1);
|
||||
D_80162DF0 = 1;
|
||||
|
|
|
|||
Loading…
Reference in New Issue