master
n64 3 years ago
parent 9a801cb96d
commit 06ec56df7f
  1. 40
      CHANGES
  2. 51
      Makefile
  3. 2
      Makefile.split
  4. 5
      README.md
  5. 2
      actors/boo/geo.inc.c
  6. 2
      actors/boo_castle/geo.inc.c
  7. 22
      actors/bowser/geo.inc.c
  8. 2
      actors/bowser_key/geo.inc.c
  9. 2
      actors/chuckya/geo.inc.c
  10. 2
      actors/group0.c
  11. 20
      actors/group0.h
  12. 2
      actors/group0_geo.c
  13. 2
      actors/impact_ring/geo.inc.c
  14. 2
      actors/impact_smoke/geo.inc.c
  15. 2
      actors/king_bobomb/geo.inc.c
  16. 8
      actors/klepto/geo.inc.c
  17. 2
      actors/lakitu_enemy/geo.inc.c
  18. 24
      actors/mario/geo.inc.c
  19. 8
      actors/mario_cap/geo.inc.c
  20. 4
      actors/mist/geo.inc.c
  21. 2
      actors/moneybag/geo.inc.c
  22. 2
      actors/monty_mole/geo.inc.c
  23. 2
      actors/peach/geo.inc.c
  24. 2
      actors/snowman/geo.inc.c
  25. 4
      actors/snufit/geo.inc.c
  26. 3
      actors/stomp_smoke/geo.inc.c
  27. 2
      actors/sushi/geo.inc.c
  28. 2
      actors/toad/geo.inc.c
  29. 2
      actors/water_ring/geo.inc.c
  30. 29
      actors/water_wave/geo.inc.c
  31. 54
      actors/water_wave/model.inc.c
  32. 29
      actors/water_waves/geo.inc.c
  33. 6
      asm/entry.s
  34. 303
      asm/non_matchings/alloc_bank_or_seq.s
  35. 151
      asm/non_matchings/eu/append_bubble_vertex_buffer.s
  36. 156
      asm/non_matchings/eu/append_snowflake_vertex_buffer.s
  37. 269
      asm/non_matchings/eu/audio/alloc_bank_or_seq.s
  38. 88
      asm/non_matchings/eu/audio/func_eu_802e00d8.s
  39. 263
      asm/non_matchings/eu/audio/note_apply_headset_pan_effects.s
  40. 179
      asm/non_matchings/eu/audio/prepare_reverb_ring_buffer.s
  41. 6
      asm/non_matchings/eu/audio/seq_channel_layer_process_script.s
  42. 56
      asm/non_matchings/eu/audio/sequence_channel_enable.s
  43. 698
      asm/non_matchings/eu/audio/sequence_player_process_sequence.s
  44. 331
      asm/non_matchings/eu/audio/synthesis_do_one_audio_update.s
  45. 178
      asm/non_matchings/eu/audio/synthesis_execute.s
  46. 220
      asm/non_matchings/eu/audio/synthesis_resample_and_mix_reverb.s
  47. 370
      asm/non_matchings/eu/handle_dialog_text_and_pages.s
  48. 55
      asm/non_matchings/eu/libultra_unk_802aeeb0.s
  49. 87
      asm/non_matchings/eu/libultra_unk_802aef80.s
  50. 86
      asm/non_matchings/eu/play_sequence.s
  51. 36
      asm/non_matchings/eu/player_performed_grab_escape_action.s
  52. 12
      asm/rom_header.s
  53. 11
      assets.json
  54. 321
      bin/segment2.c
  55. 5
      bin/spooky.c
  56. 156
      data/behavior_data.c
  57. 0
      diff.py
  58. 6
      enhancements/mem_error_screen.patch
  59. 4
      extract_assets.py
  60. 6
      include/PR/os_pi.h
  61. 28
      include/behavior_data.h
  62. 8
      include/eu_translation.h
  63. 6
      include/model_ids.h
  64. 99
      include/object_constants.h
  65. 58
      include/object_fields.h
  66. 2
      include/segments.h
  67. 40
      include/sm64.h
  68. 2
      include/text_strings.h.in
  69. 2
      levels/bbh/areas/1/geo.inc.c
  70. 2
      levels/bitdw/areas/1/geo.inc.c
  71. 2
      levels/bitfs/areas/1/geo.inc.c
  72. 2
      levels/bits/areas/1/geo.inc.c
  73. 2
      levels/bob/areas/1/geo.inc.c
  74. 2
      levels/bowser_1/areas/1/geo.inc.c
  75. 2
      levels/bowser_2/areas/1/geo.inc.c
  76. 2
      levels/bowser_3/areas/1/geo.inc.c
  77. 2
      levels/castle_courtyard/areas/1/geo.inc.c
  78. 2
      levels/castle_grounds/areas/1/geo.inc.c
  79. 34
      levels/castle_inside/areas/1/geo.inc.c
  80. 58
      levels/castle_inside/areas/2/geo.inc.c
  81. 40
      levels/castle_inside/areas/3/geo.inc.c
  82. 490
      levels/castle_inside/painting.inc.c
  83. 2
      levels/ccm/areas/1/geo.inc.c
  84. 2
      levels/ccm/areas/2/geo.inc.c
  85. 2
      levels/cotmc/areas/1/geo.inc.c
  86. 2
      levels/ddd/areas/1/geo.inc.c
  87. 2
      levels/ddd/areas/2/geo.inc.c
  88. 10
      levels/hmc/areas/1/geo.inc.c
  89. 48
      levels/hmc/areas/1/painting.inc.c
  90. 2
      levels/jrb/areas/1/geo.inc.c
  91. 2
      levels/jrb/areas/2/geo.inc.c
  92. 4
      levels/jrb/wooden_ship/geo.inc.c
  93. 2
      levels/lll/areas/1/geo.inc.c
  94. 2
      levels/lll/areas/2/geo.inc.c
  95. 2
      levels/pss/areas/1/geo.inc.c
  96. 2
      levels/rr/areas/1/geo.inc.c
  97. 2
      levels/sa/areas/1/geo.inc.c
  98. 6
      levels/scripts.c
  99. 2
      levels/sl/areas/1/geo.inc.c
  100. 2
      levels/sl/areas/2/geo.inc.c
  101. Some files were not shown because too many files have changed in this diff Show More

@ -1,3 +1,43 @@
Refresh #7
1.) update README.md (#861)
2.) [eu] fix decompilation bugs in synthesis_process_note (#862)
3.) Label and document Snufit.inc.c (#863)
4.) Label and document Snufit.inc.c (#863)
5.) Match append_bubble_vertex_buffer, append_snowflake_vertex_buffer (#860)
6.) Compile audio/effects.c with -sopt (#870)
7.) Match handle_dialog_text_and_pages (#872)
8.) Remove improperly used LEVEL_SA define. (#875)
9.) Remove unused EU ASM files (#873)
10.) Shindou build flag support (#876)
11.) The Big Function PR (Part 1) (#864)
12.) "Re-document" file_select and star_select for EU (#877)
13.) Document paintings.c (#868)
14.) Minor interaction.c labelling/documentation. (#882)
15.) Match synthesis_execute, prepare_reverb_ring_buffer, func_eu_802e00d8 (#886)
16.) The Big Function PR (Part 2) (#874)
17.) Additional painting documentation (#883)
18.) Some EU audio labelling (#885)
19.) Bring synthesis_do_one_audio_update a bit closer to matching (#887)
20.) Misleading comment, this actually contols Bowser's init action (#889)
21.) Match synthesis_do_one_audio_update (#890)
22.) Remove unneeded if(1) in synthesis_do_one_audio_update (#891)
23.) Match synthesis_resample_and_mix_reverb (#893)
24.) Set LANG=C (#896)
25.) Match note_apply_headset_pan_effects (#897)
26.) Match play_sequence (#898)
27.) Match sequence_channel_enable (#899)
28.) Match sequence_player_process_sequence (#900)
29.) Match (eu) alloc_bank_or_seq (#901)
30.) Match alloc_bank_or_seq (#903)
31.) Update README.md (again)
32.) Documented behaviour/fish.inc.c & blue_fish.inc.c (#894)
33.) Labelled 4 behavior files, made object_helper functions consistent (#881)
34.) Add a make target for .copt (#902)
35.) The Big Function PR (Part 3) (#888)
36.) The Big Function PR (Part 4) (#906)
37.) Rename src/audio/memory.c -> heap.c (#907)
38.) Fix BBH texture (#908)
Refresh #6
1.) Make tools work on MinGW (#804)
2.) Document mario_misc (#628)

@ -42,11 +42,22 @@ ifeq ($(VERSION),eu)
GRUCODE_CFLAGS := -DF3D_NEW
GRUCODE_ASFLAGS := --defsym F3D_NEW=1
TARGET := sm64.eu
else
ifeq ($(VERSION),sh)
$(warning Building SH is experimental and is prone to breaking. Try at your own risk.)
VERSION_CFLAGS := -DVERSION_SH
VERSION_ASFLAGS := --defsym VERSION_SH=1
GRUCODE_CFLAGS := -DF3D_NEW
GRUCODE_ASFLAGS := --defsym F3D_NEW=1
TARGET := sm64.sh
# TODO: GET RID OF THIS!!! We should mandate assets for Shindou like EU but we dont have the addresses extracted yet so we'll just pretend you have everything extracted for now.
NOEXTRACT := 1
else
$(error unknown version "$(VERSION)")
endif
endif
endif
endif
# Microcode
@ -147,9 +158,13 @@ MIPSISET := -mips2 -32
ifeq ($(VERSION),eu)
OPT_FLAGS := -O2
else
ifeq ($(VERSION),sh)
OPT_FLAGS := -O2
else
OPT_FLAGS := -g
endif
endif
# File dependencies and variables for specific files
include Makefile.split
@ -163,11 +178,20 @@ GODDARD_C_FILES := $(foreach dir,$(GODDARD_SRC_DIRS),$(wildcard $(dir)/*.c))
ULTRA_S_FILES := $(foreach dir,$(ULTRA_ASM_DIRS),$(wildcard $(dir)/*.s))
GENERATED_C_FILES := $(BUILD_DIR)/assets/mario_anim_data.c $(BUILD_DIR)/assets/demo_data.c
ifeq ($(VERSION),sh)
SOUND_BANK_FILES := $(wildcard sound/sound_banks/*.json)
SOUND_SEQUENCE_FILES := $(wildcard sound/sequences/jp/*.m64) \
$(wildcard sound/sequences/*.m64) \
$(foreach file,$(wildcard sound/sequences/jp/*.s),$(BUILD_DIR)/$(file:.s=.m64)) \
$(foreach file,$(wildcard sound/sequences/*.s),$(BUILD_DIR)/$(file:.s=.m64))
else
SOUND_BANK_FILES := $(wildcard sound/sound_banks/*.json)
SOUND_SEQUENCE_FILES := $(wildcard sound/sequences/$(VERSION)/*.m64) \
$(wildcard sound/sequences/*.m64) \
$(foreach file,$(wildcard sound/sequences/$(VERSION)/*.s),$(BUILD_DIR)/$(file:.s=.m64)) \
$(foreach file,$(wildcard sound/sequences/*.s),$(BUILD_DIR)/$(file:.s=.m64))
endif
SOUND_SAMPLE_DIRS := $(wildcard sound/samples/*)
SOUND_SAMPLE_AIFFS := $(foreach dir,$(SOUND_SAMPLE_DIRS),$(wildcard $(dir)/*.aiff))
SOUND_SAMPLE_TABLES := $(foreach file,$(SOUND_SAMPLE_AIFFS),$(BUILD_DIR)/$(file:.aiff=.table))
@ -233,7 +257,7 @@ endif
INCLUDE_CFLAGS := -I include -I $(BUILD_DIR) -I $(BUILD_DIR)/include -I src -I .
# Check code syntax with host compiler
CC_CHECK := gcc -fsyntax-only -fsigned-char $(CC_CFLAGS) $(TARGET_CFLAGS) $(INCLUDE_CFLAGS) -std=gnu90 -Wall -Wextra -Wno-format-security -DNON_MATCHING -DAVOID_UB $(VERSION_CFLAGS) $(GRUCODE_CFLAGS)
CC_CHECK := gcc -fsyntax-only -fsigned-char $(CC_CFLAGS) $(TARGET_CFLAGS) $(INCLUDE_CFLAGS) -std=gnu90 -Wall -Wextra -Wno-format-security -Wno-main -DNON_MATCHING -DAVOID_UB $(VERSION_CFLAGS) $(GRUCODE_CFLAGS)
ASFLAGS := -march=vr4300 -mabi=32 -I include -I $(BUILD_DIR) $(VERSION_ASFLAGS) $(GRUCODE_ASFLAGS)
CFLAGS = -Wab,-r4300_mul -non_shared -G 0 -Xcpluscomm -Xfullwarn -signed $(OPT_FLAGS) $(TARGET_CFLAGS) $(INCLUDE_CFLAGS) $(VERSION_CFLAGS) $(MIPSISET) $(GRUCODE_CFLAGS)
@ -250,6 +274,9 @@ else
CC_CHECK += -m32
endif
# Prevent a crash with -sopt
export LANG := C
####################### Other Tools #########################
# N64 tools
@ -324,12 +351,18 @@ $(BUILD_DIR)/levels/menu/leveldata.o: $(BUILD_DIR)/text/us/define_courses.inc.c
$(BUILD_DIR)/levels/menu/leveldata.o: $(BUILD_DIR)/text/de/define_courses.inc.c
$(BUILD_DIR)/levels/menu/leveldata.o: $(BUILD_DIR)/text/fr/define_courses.inc.c
else
ifeq ($(VERSION),sh)
TEXT_DIRS := text/jp
$(BUILD_DIR)/bin/segment2.o: $(BUILD_DIR)/text/jp/define_text.inc.c
else
TEXT_DIRS := text/$(VERSION)
# non-EU encoded text inserted into segment 0x02
$(BUILD_DIR)/bin/segment2.o: $(BUILD_DIR)/text/$(VERSION)/define_text.inc.c
endif
endif
$(BUILD_DIR)/text/%/define_courses.inc.c: text/define_courses.inc.c text/%/courses.h
$(CPP) $(VERSION_CFLAGS) $< -o $@ -I text/$*/
@ -422,8 +455,13 @@ $(SOUND_BIN_DIR)/sound_data.ctl: sound/sound_banks/ $(SOUND_BANK_FILES) $(SOUND_
$(SOUND_BIN_DIR)/sound_data.tbl: $(SOUND_BIN_DIR)/sound_data.ctl
@true
ifeq ($(VERSION),sh)
$(SOUND_BIN_DIR)/sequences.bin: $(SOUND_BANK_FILES) sound/sequences.json sound/sequences/ sound/sequences/jp/ $(SOUND_SEQUENCE_FILES) $(ENDIAN_BITWIDTH)
$(PYTHON) tools/assemble_sound.py --sequences $@ $(SOUND_BIN_DIR)/bank_sets sound/sound_banks/ sound/sequences.json $(SOUND_SEQUENCE_FILES) $(VERSION_CFLAGS) $$(cat $(ENDIAN_BITWIDTH))
else
$(SOUND_BIN_DIR)/sequences.bin: $(SOUND_BANK_FILES) sound/sequences.json sound/sequences/ sound/sequences/$(VERSION)/ $(SOUND_SEQUENCE_FILES) $(ENDIAN_BITWIDTH)
$(PYTHON) tools/assemble_sound.py --sequences $@ $(SOUND_BIN_DIR)/bank_sets sound/sound_banks/ sound/sequences.json $(SOUND_SEQUENCE_FILES) $(VERSION_CFLAGS) $$(cat $(ENDIAN_BITWIDTH))
endif
$(SOUND_BIN_DIR)/bank_sets: $(SOUND_BIN_DIR)/sequences.bin
@true
@ -477,6 +515,17 @@ $(BUILD_DIR)/lib/src/sprintf.o: OPT_FLAGS := -O3
$(BUILD_DIR)/src/audio/%.o: OPT_FLAGS := -O2
$(BUILD_DIR)/src/audio/load.o: OPT_FLAGS := -O2
$(BUILD_DIR)/src/audio/external.o: OPT_FLAGS := -O2 -Wo,-loopunroll,0
else
# The source-to-source optimizer copt is enabled for audio. This makes it use
# acpp, which needs -Wp,-+ to handle C++-style comments.
$(BUILD_DIR)/src/audio/effects.o: OPT_FLAGS := -O2 -Wo,-loopunroll,0 -sopt,-inline=sequence_channel_process_sound,-scalaroptimize=1 -Wp,-+
# Add a target for build/eu/src/audio/*.copt to make it easier to see debug
$(BUILD_DIR)/src/audio/%.acpp: src/audio/%.c
$(QEMU_IRIX) -silent -L $(IRIX_ROOT) $(IRIX_ROOT)/usr/lib/acpp $(TARGET_CFLAGS) $(INCLUDE_CFLAGS) $(VERSION_CFLAGS) $(GRUCODE_CFLAGS) -D__sgi -+ $< > $@
$(BUILD_DIR)/src/audio/%.copt: $(BUILD_DIR)/src/audio/%.acpp
$(QEMU_IRIX) -silent -L $(IRIX_ROOT) $(IRIX_ROOT)/usr/lib/copt -signed -I=$< -CMP=$@ -cp=i -scalaroptimize=1
endif
ifeq ($(NON_MATCHING),0)

@ -63,7 +63,7 @@ MOLE_DIRS := monty_mole_hole monty_mole smoke ukiki fwoosh
LAKITU_DIRS := lakitu_cameraman toad mips boo_castle
PEACH_DIRS := bird peach yoshi
BOWSER_DIRS := bowser_flame impact_ring yellow_sphere bowser bomb impact_smoke
MARIO_DIRS := mario bubble walk_smoke burn_smoke stomp_smoke water_waves sparkle water_splash white_particle_small sparkle_animation
MARIO_DIRS := mario bubble walk_smoke burn_smoke stomp_smoke water_wave sparkle water_splash white_particle_small sparkle_animation
# Actor Files
AMP_CHUCKYA_FILES := $(foreach dir,$(addprefix $(ACTOR_DIR)/,$(AMP_DIRS)),$(patsubst %.png,%.inc.c,$(wildcard $(dir)/*.png)))

@ -1,14 +1,15 @@
# Super Mario 64
This repo contains a full decompilation of Super Mario 64 (J) and (U).
This repo contains a full decompilation of Super Mario 64 (J), (U), and (E).
The source and data have been decompiled but complete naming and documentation
all of the code and data is still a work in progress. Decompiling the (E) ROM
all of the code and data is still a work in progress. Decompiling the Shindou ROM
is also an ongoing effort.
It builds the following ROMs:
* sm64.jp.z64 `sha1: 8a20a5c83d6ceb0f0506cfc9fa20d8f438cafe51`
* sm64.us.z64 `sha1: 9bef1128717f958171a4afac3ed78ee2bb4e86ce`
* sm64.eu.z64 `sha1: 4ac5721683d0e0b6bbb561b58a71740845dceea9`
This repo does not include all assets necessary for compiling the ROMs.
A prior copy of the game is required to extract the required assets.

@ -4,7 +4,7 @@ const GeoLayout boo_geo[] = {
GEO_OPEN_NODE(),
GEO_SCALE(0x00, 26214),
GEO_OPEN_NODE(),
GEO_ASM(0, Geo18_8029D924),
GEO_ASM(0, geo_update_layer_transparency),
GEO_SWITCH_CASE(2, geo_switch_anim_state),
GEO_OPEN_NODE(),
GEO_DISPLAY_LIST(LAYER_OPAQUE, boo_seg5_dl_0500C1B0),

@ -4,7 +4,7 @@ const GeoLayout boo_castle_geo[] = {
GEO_OPEN_NODE(),
GEO_SCALE(0x00, 26214),
GEO_OPEN_NODE(),
GEO_ASM(0, Geo18_8029D924),
GEO_ASM(0, geo_update_layer_transparency),
GEO_SWITCH_CASE(2, geo_switch_anim_state),
GEO_OPEN_NODE(),
GEO_DISPLAY_LIST(LAYER_OPAQUE, boo_castle_seg6_dl_06017CE0),

@ -23,7 +23,7 @@ const GeoLayout bowser_geo_0000D8[] = {
GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL),
GEO_OPEN_NODE(),
GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, bowser_seg6_dl_06043698),
GEO_ASM(0, Geo18_802B798C),
GEO_ASM(0, geo_update_body_rot_from_parent),
GEO_CLOSE_NODE(),
GEO_CLOSE_NODE(),
GEO_ANIMATED_PART(LAYER_OPAQUE, 118, 67, 105, NULL),
@ -135,7 +135,7 @@ const GeoLayout bowser_geo_000424[] = {
GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, NULL),
GEO_OPEN_NODE(),
GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, bowser_seg6_dl_06043698),
GEO_ASM(0, Geo18_802B798C),
GEO_ASM(0, geo_update_body_rot_from_parent),
GEO_CLOSE_NODE(),
GEO_CLOSE_NODE(),
GEO_ANIMATED_PART(LAYER_TRANSPARENT, 118, 67, 105, NULL),
@ -251,7 +251,7 @@ const GeoLayout bowser_geo_000770[] = {
GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, NULL),
GEO_OPEN_NODE(),
GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, bowser_seg6_dl_06043698),
GEO_ASM(0, Geo18_802B798C),
GEO_ASM(0, geo_update_body_rot_from_parent),
GEO_CLOSE_NODE(),
GEO_CLOSE_NODE(),
GEO_ANIMATED_PART(LAYER_TRANSPARENT, 118, 67, 105, NULL),
@ -350,7 +350,7 @@ const GeoLayout bowser_shadow_geo[] = {
const GeoLayout bowser_geo[] = {
GEO_NODE_START(),
GEO_OPEN_NODE(),
GEO_ASM(0, Geo18_8029D924),
GEO_ASM(0, geo_update_layer_transparency),
#ifdef VERSION_JP
GEO_SWITCH_CASE(2, geo_switch_anim_state),
#endif
@ -360,20 +360,20 @@ const GeoLayout bowser_geo[] = {
GEO_OPEN_NODE(),
GEO_NODE_START(),
GEO_OPEN_NODE(),
GEO_ASM(0, Geo18_802B7D44),
GEO_ASM(0, geo_bits_bowser_coloring),
GEO_BRANCH(1, bowser_geo_0000D8),
GEO_CLOSE_NODE(),
GEO_NODE_START(),
GEO_OPEN_NODE(),
GEO_ASM(0, Geo18_802B7D44),
GEO_ASM(0, geo_bits_bowser_coloring),
GEO_BRANCH(1, bowser_geo_000424),
GEO_CLOSE_NODE(),
#ifndef VERSION_JP
GEO_NODE_START(),
GEO_OPEN_NODE(),
GEO_ASM(0, Geo18_802B7D44),
GEO_ASM(0, geo_bits_bowser_coloring),
GEO_BRANCH(1, bowser_shadow_geo),
GEO_CLOSE_NODE(),
#endif
@ -387,7 +387,7 @@ const GeoLayout bowser_geo[] = {
const GeoLayout bowser2_geo[] = {
GEO_NODE_START(),
GEO_OPEN_NODE(),
GEO_ASM(0, Geo18_8029D924),
GEO_ASM(0, geo_update_layer_transparency),
#ifdef VERSION_JP
GEO_SWITCH_CASE(2, geo_switch_anim_state),
@ -399,20 +399,20 @@ const GeoLayout bowser2_geo[] = {
GEO_NODE_START(),
GEO_OPEN_NODE(),
GEO_ASM(0, Geo18_802B7D44),
GEO_ASM(0, geo_bits_bowser_coloring),
GEO_BRANCH(1, bowser_geo_0000D8),
GEO_CLOSE_NODE(),
GEO_NODE_START(),
GEO_OPEN_NODE(),
GEO_ASM(0, Geo18_802B7D44),
GEO_ASM(0, geo_bits_bowser_coloring),
GEO_BRANCH(1, bowser_geo_000770),
GEO_CLOSE_NODE(),
#ifndef VERSION_JP
GEO_NODE_START(),
GEO_OPEN_NODE(),
GEO_ASM(0, Geo18_802B7D44),
GEO_ASM(0, geo_bits_bowser_coloring),
GEO_BRANCH(1, bowser_shadow_geo),
GEO_CLOSE_NODE(),
#endif

@ -18,7 +18,7 @@ const GeoLayout bowser_key_cutscene_geo[] = {
GEO_OPEN_NODE(),
GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL),
GEO_OPEN_NODE(),
GEO_ASM(0, Geo18_802BA2B0),
GEO_ASM(0, geo_scale_bowser_key),
GEO_SCALE(0x00, 65536),
GEO_OPEN_NODE(),
GEO_DISPLAY_LIST(LAYER_OPAQUE, bowser_key_dl),

@ -99,7 +99,7 @@ const GeoLayout chuckya_geo[] = {
GEO_DISPLAY_LIST(LAYER_ALPHA, chuckya_seg8_dl_0800A510),
GEO_CLOSE_NODE(),
GEO_CLOSE_NODE(),
GEO_ASM(0, Geo18_802A719C),
GEO_ASM(0, geo_update_held_mario_pos),
GEO_CLOSE_NODE(),
GEO_CLOSE_NODE(),
GEO_CLOSE_NODE(),

@ -16,7 +16,7 @@
#include "stomp_smoke/model.inc.c"
#include "water_waves/model.inc.c"
#include "water_wave/model.inc.c"
#include "sparkle/model.inc.c"

@ -283,7 +283,7 @@ extern const Gfx sparkles_animation_seg4_dl_04035348[];
extern const Gfx sparkles_animation_seg4_dl_04035360[];
// stomp_smoke
extern const GeoLayout spot_on_ground_geo[];
extern const GeoLayout small_water_splash_geo[];
extern const GeoLayout mario_TODO_geo_0000E0[];
extern const Gfx stomp_smoke_seg4_dl_04025148[];
extern const Gfx stomp_smoke_seg4_dl_04025190[];
@ -326,15 +326,15 @@ extern const Gfx water_splash_seg4_dl_040326D0[];
extern const Gfx water_splash_seg4_dl_040326E8[];
// water_waves
extern const GeoLayout water_waves_surface_geo[];
extern const GeoLayout water_waves_geo[];
extern const Gfx water_waves_seg4_dl_04027358[];
extern const Gfx water_waves_seg4_dl_040273A0[];
extern const Gfx water_waves_seg4_dl_040273D8[];
extern const Gfx water_waves_seg4_dl_040273F0[];
extern const Gfx water_waves_seg4_dl_04027408[];
extern const Gfx water_waves_seg4_dl_04027420[];
extern const Gfx water_waves_seg4_dl_04027438[];
extern const GeoLayout idle_water_wave_geo[];
extern const GeoLayout wave_trail_geo[];
extern const Gfx water_wave_seg4_dl_04027358[];
extern const Gfx water_wave_seg4_dl_040273A0[];
extern const Gfx water_wave_seg4_dl_040273D8[];
extern const Gfx water_wave_seg4_dl_040273F0[];
extern const Gfx water_wave_seg4_dl_04027408[];
extern const Gfx water_wave_seg4_dl_04027420[];
extern const Gfx water_wave_seg4_dl_04027438[];
// white_particle_small
extern const Gfx white_particle_small_dl_begin[];

@ -11,7 +11,7 @@
#include "walk_smoke/geo.inc.c"
#include "burn_smoke/geo.inc.c"
#include "stomp_smoke/geo.inc.c"
#include "water_waves/geo.inc.c"
#include "water_wave/geo.inc.c"
#include "sparkle/geo.inc.c"
#include "water_splash/geo.inc.c"
#include "sparkle_animation/geo.inc.c"

@ -2,7 +2,7 @@
const GeoLayout invisible_bowser_accessory_geo[] = {
GEO_CULLING_RADIUS(10000),
GEO_OPEN_NODE(),
GEO_ASM(20, Geo18_8029D924),
GEO_ASM(20, geo_update_layer_transparency),
GEO_DISPLAY_LIST(LAYER_TRANSPARENT_DECAL, impact_ring_seg6_dl_0601EAC0),
GEO_CLOSE_NODE(),
GEO_END(),

@ -2,7 +2,7 @@
const GeoLayout bowser_impact_smoke_geo[] = {
GEO_NODE_START(),
GEO_OPEN_NODE(),
GEO_ASM(0, Geo18_8029D924),
GEO_ASM(0, geo_update_layer_transparency),
GEO_SWITCH_CASE(5, geo_switch_anim_state),
GEO_OPEN_NODE(),
GEO_DISPLAY_LIST(LAYER_TRANSPARENT, impact_smoke_seg6_dl_06062B38),

@ -80,7 +80,7 @@ const GeoLayout king_bobomb_geo[] = {
GEO_DISPLAY_LIST(LAYER_ALPHA, king_bobomb_seg5_dl_0500A6C0),
GEO_CLOSE_NODE(),
GEO_CLOSE_NODE(),
GEO_ASM(0, Geo18_802A719C),
GEO_ASM(0, geo_update_held_mario_pos),
GEO_CLOSE_NODE(),
GEO_CLOSE_NODE(),
GEO_CLOSE_NODE(),

@ -31,7 +31,7 @@ const GeoLayout klepto_geo[] = {
GEO_OPEN_NODE(),
GEO_SCALE(0x00, 16384),
GEO_OPEN_NODE(),
GEO_ASM(0, Geo18_802A45E4),
GEO_ASM(0, geo_offset_klepto_held_object),
GEO_TRANSLATE_ROTATE_WITH_DL(LAYER_OPAQUE, 0, 100, 0, 180, 270, 0, mario_cap_seg3_dl_03022F48),
GEO_CLOSE_NODE(),
GEO_CLOSE_NODE(),
@ -39,9 +39,9 @@ const GeoLayout klepto_geo[] = {
GEO_OPEN_NODE(),
GEO_SCALE(0x00, 16384),
GEO_OPEN_NODE(),
GEO_ASM(0, Geo18_802A45E4),
GEO_ASM(0, geo_offset_klepto_held_object),
GEO_TRANSLATE_ROTATE_WITH_DL(LAYER_OPAQUE, 0, 100, 0, 180, 270, 0, star_seg3_dl_0302B870),
GEO_ASM(0, Geo18_802A45E4),
GEO_ASM(0, geo_offset_klepto_held_object),
GEO_TRANSLATE_ROTATE_WITH_DL(LAYER_ALPHA, 0, 100, 0, 180, 270, 0, star_seg3_dl_0302BA18),
GEO_CLOSE_NODE(),
GEO_CLOSE_NODE(),
@ -49,7 +49,7 @@ const GeoLayout klepto_geo[] = {
GEO_OPEN_NODE(),
GEO_SCALE(0x00, 16384),
GEO_OPEN_NODE(),
GEO_ASM(0, Geo18_802A45E4),
GEO_ASM(0, geo_offset_klepto_held_object),
GEO_TRANSLATE_ROTATE_WITH_DL(LAYER_OPAQUE, 0, 100, 0, 180, 270, 0, transparent_star_seg3_dl_0302C620),
GEO_CLOSE_NODE(),
GEO_CLOSE_NODE(),

@ -23,7 +23,7 @@ const GeoLayout enemy_lakitu_geo[] = {
GEO_ANIMATED_PART(LAYER_OPAQUE, 87, 18, -72, NULL),
GEO_OPEN_NODE(),
GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, lakitu_enemy_seg5_dl_050134A8),
GEO_ASM(0, Geo18_8029D890),
GEO_ASM(0, geo_update_projectile_pos_from_parent),
GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL),
GEO_CLOSE_NODE(),
GEO_CLOSE_NODE(),

@ -105,7 +105,7 @@ const GeoLayout mario_geo_body[] = {
GEO_OPEN_NODE(),
GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, mario_butt), // starts sharing solid color with mario_torso (blue)
GEO_OPEN_NODE(),
GEO_ASM(0, Geo18_802B1BB0),
GEO_ASM(0, geo_move_mario_part_from_parent),
GEO_ASM(0, geo_mario_tilt_torso),
GEO_ROTATION_NODE(0x00, 0, 0, 0),
GEO_OPEN_NODE(),
@ -222,7 +222,7 @@ const GeoLayout mario_geo_medium_poly_body[] = {
GEO_OPEN_NODE(),
GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, mario_medium_poly_butt), // starts sharing solid color with mario_torso (blue)
GEO_OPEN_NODE(),
GEO_ASM(0, Geo18_802B1BB0),
GEO_ASM(0, geo_move_mario_part_from_parent),
GEO_ASM(0, geo_mario_tilt_torso),
GEO_ROTATION_NODE(0x00, 0, 0, 0),
GEO_OPEN_NODE(),
@ -389,7 +389,7 @@ const GeoLayout mario_geo_low_poly_body[] = {
GEO_OPEN_NODE(),
GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, mario_low_poly_butt), // starts sharing solid color with mario_torso (blue)
GEO_OPEN_NODE(),
GEO_ASM(0, Geo18_802B1BB0),
GEO_ASM(0, geo_move_mario_part_from_parent),
GEO_ASM(0, geo_mario_tilt_torso),
GEO_ROTATION_NODE(0x00, 0, 0, 0),
GEO_OPEN_NODE(),
@ -560,7 +560,7 @@ const GeoLayout mario_vanish_geo_body[] = {
GEO_OPEN_NODE(),
GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, mario_butt),
GEO_OPEN_NODE(),
GEO_ASM(0, Geo18_802B1BB0),
GEO_ASM(0, geo_move_mario_part_from_parent),
GEO_ASM(0, geo_mario_tilt_torso),
GEO_ROTATION_NODE(0x00, 0, 0, 0),
GEO_OPEN_NODE(),
@ -677,7 +677,7 @@ const GeoLayout mario_vanish_geo_medium_poly_body[] = {
GEO_OPEN_NODE(),
GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, mario_medium_poly_butt),
GEO_OPEN_NODE(),
GEO_ASM(0, Geo18_802B1BB0),
GEO_ASM(0, geo_move_mario_part_from_parent),
GEO_ASM(0, geo_mario_tilt_torso),
GEO_ROTATION_NODE(0x00, 0, 0, 0),
GEO_OPEN_NODE(),
@ -844,7 +844,7 @@ const GeoLayout mario_vanish_geo_low_poly_body[] = {
GEO_OPEN_NODE(),
GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, mario_low_poly_butt),
GEO_OPEN_NODE(),
GEO_ASM(0, Geo18_802B1BB0),
GEO_ASM(0, geo_move_mario_part_from_parent),
GEO_ASM(0, geo_mario_tilt_torso),
GEO_ROTATION_NODE(0x00, 0, 0, 0),
GEO_OPEN_NODE(),
@ -995,7 +995,7 @@ const GeoLayout mario_metal_geo_body[] = {
GEO_OPEN_NODE(),
GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, mario_metal_butt), // starts sharing metal texture with the dls below
GEO_OPEN_NODE(),
GEO_ASM(0, Geo18_802B1BB0),
GEO_ASM(0, geo_move_mario_part_from_parent),
GEO_ASM(0, geo_mario_tilt_torso),
GEO_ROTATION_NODE(0x00, 0, 0, 0),
GEO_OPEN_NODE(),
@ -1112,7 +1112,7 @@ const GeoLayout mario_metal_geo_medium_poly_body[] = {
GEO_OPEN_NODE(),
GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, mario_metal_medium_poly_butt),
GEO_OPEN_NODE(),
GEO_ASM(0, Geo18_802B1BB0),
GEO_ASM(0, geo_move_mario_part_from_parent),
GEO_ASM(0, geo_mario_tilt_torso),
GEO_ROTATION_NODE(0x00, 0, 0, 0),
GEO_OPEN_NODE(),
@ -1259,7 +1259,7 @@ const GeoLayout mario_metal_geo_low_poly_body[] = {
GEO_OPEN_NODE(),
GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, mario_metal_low_poly_butt),
GEO_OPEN_NODE(),
GEO_ASM(0, Geo18_802B1BB0),
GEO_ASM(0, geo_move_mario_part_from_parent),
GEO_ASM(0, geo_mario_tilt_torso),
GEO_ROTATION_NODE(0x00, 0, 0, 0),
GEO_OPEN_NODE(),
@ -1410,7 +1410,7 @@ const GeoLayout mario_metal_vanish_geo_body[] = {
GEO_OPEN_NODE(),
GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, mario_metal_butt),
GEO_OPEN_NODE(),
GEO_ASM(0, Geo18_802B1BB0),
GEO_ASM(0, geo_move_mario_part_from_parent),
GEO_ASM(0, geo_mario_tilt_torso),
GEO_ROTATION_NODE(0x00, 0, 0, 0),
GEO_OPEN_NODE(),
@ -1527,7 +1527,7 @@ const GeoLayout mario_metal_vanish_geo_medium_poly_body[] = {
GEO_OPEN_NODE(),
GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, mario_metal_medium_poly_butt),
GEO_OPEN_NODE(),
GEO_ASM(0, Geo18_802B1BB0),
GEO_ASM(0, geo_move_mario_part_from_parent),
GEO_ASM(0, geo_mario_tilt_torso),
GEO_ROTATION_NODE(0x00, 0, 0, 0),
GEO_OPEN_NODE(),
@ -1677,7 +1677,7 @@ const GeoLayout mario_metal_vanish_geo_low_poly_body[] = {
GEO_OPEN_NODE(),
GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, mario_metal_low_poly_butt),
GEO_OPEN_NODE(),
GEO_ASM(0, Geo18_802B1BB0),
GEO_ASM(0, geo_move_mario_part_from_parent),
GEO_ASM(0, geo_mario_tilt_torso),
GEO_ROTATION_NODE(0x00, 0, 0, 0),
GEO_OPEN_NODE(),

@ -4,7 +4,7 @@ const GeoLayout marios_cap_geo[] = {
GEO_OPEN_NODE(),
GEO_SCALE(0x00, 16384),
GEO_OPEN_NODE(),
GEO_ASM(10, Geo18_8029D924),
GEO_ASM(10, geo_update_layer_transparency),
GEO_SWITCH_CASE(2, geo_switch_anim_state),
GEO_OPEN_NODE(),
GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_cap_seg3_dl_03022F48),
@ -21,7 +21,7 @@ const GeoLayout marios_metal_cap_geo[] = {
GEO_OPEN_NODE(),
GEO_SCALE(0x00, 16384),
GEO_OPEN_NODE(),
GEO_ASM(10, Geo18_8029D924),
GEO_ASM(10, geo_update_layer_transparency),
GEO_SWITCH_CASE(2, geo_switch_anim_state),
GEO_OPEN_NODE(),
GEO_DISPLAY_LIST(LAYER_OPAQUE, mario_cap_seg3_dl_03022FF8),
@ -38,7 +38,7 @@ const GeoLayout marios_wing_cap_geo[] = {
GEO_OPEN_NODE(),
GEO_SCALE(0x00, 16384),
GEO_OPEN_NODE(),
GEO_ASM(10, Geo18_8029D924),
GEO_ASM(10, geo_update_layer_transparency),
GEO_SWITCH_CASE(2, geo_switch_anim_state),
GEO_OPEN_NODE(),
GEO_NODE_START(),
@ -62,7 +62,7 @@ const GeoLayout marios_winged_metal_cap_geo[] = {
GEO_OPEN_NODE(),
GEO_SCALE(0x00, 16384),
GEO_OPEN_NODE(),
GEO_ASM(10, Geo18_8029D924),
GEO_ASM(10, geo_update_layer_transparency),
GEO_SWITCH_CASE(2, geo_switch_anim_state),
GEO_OPEN_NODE(),
GEO_NODE_START(),

@ -2,7 +2,7 @@
const GeoLayout mist_geo[] = {
GEO_NODE_START(),
GEO_OPEN_NODE(),
GEO_ASM(0, Geo18_8029D924),
GEO_ASM(0, geo_update_layer_transparency),
GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mist_seg3_dl_03000880),
GEO_CLOSE_NODE(),
GEO_END(),
@ -12,7 +12,7 @@ const GeoLayout mist_geo[] = {
const GeoLayout white_puff_geo[] = {
GEO_NODE_START(),
GEO_OPEN_NODE(),
GEO_ASM(0, Geo18_8029D924),
GEO_ASM(0, geo_update_layer_transparency),
GEO_DISPLAY_LIST(LAYER_TRANSPARENT, mist_seg3_dl_03000920),
GEO_CLOSE_NODE(),
GEO_END(),

@ -44,7 +44,7 @@ const GeoLayout moneybag_geo[] = {
GEO_OPEN_NODE(),
GEO_SCALE(0x00, 16384),
GEO_OPEN_NODE(),
GEO_ASM(0, Geo18_8029D924),
GEO_ASM(0, geo_update_layer_transparency),
GEO_SWITCH_CASE(2, geo_switch_anim_state),
GEO_OPEN_NODE(),
GEO_BRANCH(1, moneybag_geo_000000),

@ -30,7 +30,7 @@ const GeoLayout monty_mole_geo[] = {
GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, monty_mole_seg5_dl_050039D0),
GEO_OPEN_NODE(),
GEO_ANIMATED_PART(LAYER_OPAQUE, 80, 0, 0, monty_mole_seg5_dl_05003F50),
GEO_ASM(0, Geo18_8029D890),
GEO_ASM(0, geo_update_projectile_pos_from_parent),
GEO_CLOSE_NODE(),
GEO_CLOSE_NODE(),
GEO_CLOSE_NODE(),

@ -140,7 +140,7 @@ const GeoLayout peach_geo[] = {
GEO_OPEN_NODE(),
GEO_SCALE(0x00, 16384),
GEO_OPEN_NODE(),
GEO_ASM(10, Geo18_8029D924),
GEO_ASM(10, geo_update_layer_transparency),
GEO_SWITCH_CASE(2, geo_switch_anim_state),
GEO_OPEN_NODE(),
GEO_BRANCH(1, peach_geo_000098),

@ -37,7 +37,7 @@ const GeoLayout mr_blizzard_hidden_geo[] = {
GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, snowman_seg5_dl_0500C500),
GEO_OPEN_NODE(),
GEO_ANIMATED_PART(LAYER_OPAQUE, 68, 0, 0, snowman_seg5_dl_0500CAA8),
GEO_ASM(0, Geo18_8029D890),
GEO_ASM(0, geo_update_projectile_pos_from_parent),
GEO_CLOSE_NODE(),
GEO_CLOSE_NODE(),
GEO_ANIMATED_PART(LAYER_OPAQUE, 356, 0, 0, NULL),

@ -4,7 +4,7 @@ const GeoLayout snufit_geo[] = {
GEO_OPEN_NODE(),
GEO_SCALE(0x00, 16384),
GEO_OPEN_NODE(),
GEO_ASM(0, Geo18_8030D93C),
GEO_ASM(0, geo_snufit_move_mask),
GEO_TRANSLATE_NODE(0x00, 0, 0, 0),
GEO_OPEN_NODE(),
GEO_DISPLAY_LIST(LAYER_OPAQUE, snufit_seg6_dl_06009748),
@ -14,7 +14,7 @@ const GeoLayout snufit_geo[] = {
GEO_DISPLAY_LIST(LAYER_OPAQUE, snufit_seg6_dl_06009B68),
GEO_BILLBOARD(),
GEO_OPEN_NODE(),
GEO_ASM(0, Geo18_8030D9AC),
GEO_ASM(0, geo_snufit_scale_body),
GEO_SCALE(0x00, 0),
GEO_OPEN_NODE(),
GEO_DISPLAY_LIST(LAYER_ALPHA, snufit_seg6_dl_06009A10),

@ -1,7 +1,8 @@
// 0x1700009C
const GeoLayout spot_on_ground_geo[] = {
const GeoLayout small_water_splash_geo[] = {
GEO_SWITCH_CASE(6, geo_switch_anim_state),
GEO_OPEN_NODE(),
// TODO: Rename these display lists
GEO_DISPLAY_LIST(LAYER_TRANSPARENT, stomp_smoke_seg4_dl_040251F8),
GEO_DISPLAY_LIST(LAYER_TRANSPARENT, stomp_smoke_seg4_dl_04025210),
GEO_DISPLAY_LIST(LAYER_TRANSPARENT, stomp_smoke_seg4_dl_04025228),

@ -8,7 +8,7 @@ const GeoLayout sushi_geo[] = {
GEO_OPEN_NODE(),
GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, sushi_seg5_dl_0500A768),
GEO_OPEN_NODE(),
GEO_ASM(0, Geo18_802B798C),
GEO_ASM(0, geo_update_body_rot_from_parent),
GEO_CLOSE_NODE(),
GEO_OPEN_NODE(),
GEO_ANIMATED_PART(LAYER_OPAQUE, 201, 0, 0, sushi_seg5_dl_05009DD0),

@ -126,7 +126,7 @@ const GeoLayout toad_geo[] = {
GEO_OPEN_NODE(),
GEO_SCALE(0x00, 16384),
GEO_OPEN_NODE(),
GEO_ASM(10, Geo18_8029D924),
GEO_ASM(10, geo_update_layer_transparency),
GEO_SWITCH_CASE(2, geo_switch_anim_state),
GEO_OPEN_NODE(),
GEO_BRANCH(1, toad_geo_000114),

@ -4,7 +4,7 @@ const GeoLayout water_ring_geo[] = {
GEO_OPEN_NODE(),
GEO_ANIMATED_PART(LAYER_OPAQUE, 0, 0, 0, NULL),
GEO_OPEN_NODE(),
GEO_ASM(0, Geo18_8029D924),
GEO_ASM(0, geo_update_layer_transparency),
GEO_ANIMATED_PART(LAYER_TRANSPARENT, 0, 0, 0, water_ring_seg6_dl_06013AC0),
GEO_CLOSE_NODE(),
GEO_CLOSE_NODE(),

@ -0,0 +1,29 @@
// 0x17000124
const GeoLayout idle_water_wave_geo[] = {
GEO_SWITCH_CASE(6, geo_switch_anim_state),
GEO_OPEN_NODE(),
GEO_DISPLAY_LIST(LAYER_TRANSPARENT, water_wave_seg4_dl_040273F0),
GEO_DISPLAY_LIST(LAYER_TRANSPARENT, water_wave_seg4_dl_04027408),
GEO_DISPLAY_LIST(LAYER_TRANSPARENT, water_wave_seg4_dl_04027420),
GEO_DISPLAY_LIST(LAYER_TRANSPARENT, water_wave_seg4_dl_04027438),
GEO_DISPLAY_LIST(LAYER_TRANSPARENT, water_wave_seg4_dl_04027420),
GEO_DISPLAY_LIST(LAYER_TRANSPARENT, water_wave_seg4_dl_04027408),
GEO_CLOSE_NODE(),
GEO_END(),
};
// 0x17000168
const GeoLayout wave_trail_geo[] = {
GEO_SWITCH_CASE(8, geo_switch_anim_state),
GEO_OPEN_NODE(),
GEO_DISPLAY_LIST(LAYER_TRANSPARENT, water_wave_seg4_dl_040273F0),
GEO_DISPLAY_LIST(LAYER_TRANSPARENT, water_wave_seg4_dl_04027408),
GEO_DISPLAY_LIST(LAYER_TRANSPARENT, water_wave_seg4_dl_04027420),
GEO_DISPLAY_LIST(LAYER_TRANSPARENT, water_wave_seg4_dl_04027438),
GEO_DISPLAY_LIST(LAYER_TRANSPARENT, water_wave_seg4_dl_04027438),
GEO_DISPLAY_LIST(LAYER_TRANSPARENT, water_wave_seg4_dl_04027438),
GEO_DISPLAY_LIST(LAYER_TRANSPARENT, water_wave_seg4_dl_04027438),
GEO_DISPLAY_LIST(LAYER_TRANSPARENT, water_wave_seg4_dl_04027438),
GEO_CLOSE_NODE(),
GEO_END(),
};

@ -1,7 +1,7 @@
// Water Waves
// 0x04025318
static const Vtx water_waves_seg4_vertex_04025318[] = {
static const Vtx water_wave_seg4_vertex_04025318[] = {
{{{ -64, 0, 64}, 0, { 0, 0}, {0xff, 0xff, 0xff, 0xc8}}},
{{{ 64, 0, 64}, 0, { 992, 0}, {0xff, 0xff, 0xff, 0xc8}}},
{{{ 64, 0, -64}, 0, { 992, 992}, {0xff, 0xff, 0xff, 0xc8}}},
@ -9,27 +9,27 @@ static const Vtx water_waves_seg4_vertex_04025318[] = {
};
// 0x04025358
ALIGNED8 static const u8 water_waves_seg4_texture_04025358[] = {
#include "actors/water_waves/water_waves_0.ia16.inc.c"
ALIGNED8 static const u8 water_wave_seg4_texture_04025358[] = {
#include "actors/water_wave/water_wave_0.ia16.inc.c"
};
// 0x04025B58
ALIGNED8 static const u8 water_waves_seg4_texture_04025B58[] = {
#include "actors/water_waves/water_waves_1.ia16.inc.c"
ALIGNED8 static const u8 water_wave_seg4_texture_04025B58[] = {
#include "actors/water_wave/water_wave_1.ia16.inc.c"
};
// 0x04026358
ALIGNED8 static const u8 water_waves_seg4_texture_04026358[] = {
#include "actors/water_waves/water_waves_2.ia16.inc.c"
ALIGNED8 static const u8 water_wave_seg4_texture_04026358[] = {
#include "actors/water_wave/water_wave_2.ia16.inc.c"
};
// 0x04026B58
ALIGNED8 static const u8 water_waves_seg4_texture_04026B58[] = {
#include "actors/water_waves/water_waves_3.ia16.inc.c"
ALIGNED8 static const u8 water_wave_seg4_texture_04026B58[] = {
#include "actors/water_wave/water_wave_3.ia16.inc.c"
};
// 0x04027358 - 0x040273A0
const Gfx water_waves_seg4_dl_04027358[] = {
const Gfx water_wave_seg4_dl_04027358[] = {
gsSPClearGeometryMode(G_LIGHTING),
gsDPSetCombineMode(G_CC_MODULATEIA, G_CC_MODULATEIA),
gsSPTexture(0xFFFF, 0xFFFF, 0, G_TX_RENDERTILE, G_ON),
@ -42,7 +42,7 @@ const Gfx water_waves_seg4_dl_04027358[] = {
};
// 0x040273A0 - 0x040273D8
const Gfx water_waves_seg4_dl_040273A0[] = {
const Gfx water_wave_seg4_dl_040273A0[] = {
gsSP2Triangles( 0, 1, 2, 0x0, 0, 2, 3, 0x0),
gsDPPipeSync(),
gsSPTexture(0x0001, 0x0001, 0, G_TX_RENDERTILE, G_OFF),
@ -52,36 +52,36 @@ const Gfx water_waves_seg4_dl_040273A0[] = {
};
// 0x040273D8 - 0x040273F0
const Gfx water_waves_seg4_dl_040273D8[] = {
gsSPDisplayList(water_waves_seg4_dl_04027358),
gsSPVertex(water_waves_seg4_vertex_04025318, 4, 0),
gsSPBranchList(water_waves_seg4_dl_040273A0),
const Gfx water_wave_seg4_dl_040273D8[] = {
gsSPDisplayList(water_wave_seg4_dl_04027358),
gsSPVertex(water_wave_seg4_vertex_04025318, 4, 0),
gsSPBranchList(water_wave_seg4_dl_040273A0),
};
// 0x040273F0 - 0x04027408
const Gfx water_waves_seg4_dl_040273F0[] = {
const Gfx water_wave_seg4_dl_040273F0[] = {
gsDPPipeSync(),
gsDPSetTextureImage(G_IM_FMT_IA, G_IM_SIZ_16b, 1, water_waves_seg4_texture_04025358),
gsSPBranchList(water_waves_seg4_dl_040273D8),
gsDPSetTextureImage(G_IM_FMT_IA, G_IM_SIZ_16b, 1, water_wave_seg4_texture_04025358),
gsSPBranchList(water_wave_seg4_dl_040273D8),
};
// 0x04027408 - 0x04027420
const Gfx water_waves_seg4_dl_04027408[] = {
const Gfx water_wave_seg4_dl_04027408[] = {
gsDPPipeSync(),
gsDPSetTextureImage(G_IM_FMT_IA, G_IM_SIZ_16b, 1, water_waves_seg4_texture_04025B58),
gsSPBranchList(water_waves_seg4_dl_040273D8),
gsDPSetTextureImage(G_IM_FMT_IA, G_IM_SIZ_16b, 1, water_wave_seg4_texture_04025B58),
gsSPBranchList(water_wave_seg4_dl_040273D8),
};
// 0x04027420 - 0x04027438
const Gfx water_waves_seg4_dl_04027420[] = {
const Gfx water_wave_seg4_dl_04027420[] = {
gsDPPipeSync(),
gsDPSetTextureImage(G_IM_FMT_IA, G_IM_SIZ_16b, 1, water_waves_seg4_texture_04026358),
gsSPBranchList(water_waves_seg4_dl_040273D8),
gsDPSetTextureImage(G_IM_FMT_IA, G_IM_SIZ_16b, 1, water_wave_seg4_texture_04026358),
gsSPBranchList(water_wave_seg4_dl_040273D8),
};
// 0x04027438 - 0x04027450
const Gfx water_waves_seg4_dl_04027438[] = {
const Gfx water_wave_seg4_dl_04027438[] = {
gsDPPipeSync(),
gsDPSetTextureImage(G_IM_FMT_IA, G_IM_SIZ_16b, 1, water_waves_seg4_texture_04026B58),
gsSPBranchList(water_waves_seg4_dl_040273D8),
gsDPSetTextureImage(G_IM_FMT_IA, G_IM_SIZ_16b, 1, water_wave_seg4_texture_04026B58),
gsSPBranchList(water_wave_seg4_dl_040273D8),
};

@ -1,29 +0,0 @@
// 0x17000124
const GeoLayout water_waves_surface_geo[] = {
GEO_SWITCH_CASE(6, geo_switch_anim_state),
GEO_OPEN_NODE(),
GEO_DISPLAY_LIST(LAYER_TRANSPARENT, water_waves_seg4_dl_040273F0),
GEO_DISPLAY_LIST(LAYER_TRANSPARENT, water_waves_seg4_dl_04027408),
GEO_DISPLAY_LIST(LAYER_TRANSPARENT, water_waves_seg4_dl_04027420),
GEO_DISPLAY_LIST(LAYER_TRANSPARENT, water_waves_seg4_dl_04027438),
GEO_DISPLAY_LIST(LAYER_TRANSPARENT, water_waves_seg4_dl_04027420),
GEO_DISPLAY_LIST(LAYER_TRANSPARENT, water_waves_seg4_dl_04027408),
GEO_CLOSE_NODE(),
GEO_END(),
};
// 0x17000168
const GeoLayout water_waves_geo[] = {
GEO_SWITCH_CASE(8, geo_switch_anim_state),
GEO_OPEN_NODE(),
GEO_DISPLAY_LIST(LAYER_TRANSPARENT, water_waves_seg4_dl_040273F0),
GEO_DISPLAY_LIST(LAYER_TRANSPARENT, water_waves_seg4_dl_04027408),
GEO_DISPLAY_LIST(LAYER_TRANSPARENT, water_waves_seg4_dl_04027420),
GEO_DISPLAY_LIST(LAYER_TRANSPARENT, water_waves_seg4_dl_04027438),
GEO_DISPLAY_LIST(LAYER_TRANSPARENT, water_waves_seg4_dl_04027438),
GEO_DISPLAY_LIST(LAYER_TRANSPARENT, water_waves_seg4_dl_04027438),
GEO_DISPLAY_LIST(LAYER_TRANSPARENT, water_waves_seg4_dl_04027438),
GEO_DISPLAY_LIST(LAYER_TRANSPARENT, water_waves_seg4_dl_04027438),
GEO_CLOSE_NODE(),
GEO_END(),
};

@ -8,7 +8,7 @@
.section .text, "ax"
glabel EntryPoint
glabel entry_point
lui $t0, %hi(_mainSegmentNoloadStart) # $t0, 0x8034
lui $t1, %lo(_mainSegmentNoloadSizeHi) # lui $t1, 2
addiu $t0, %lo(_mainSegmentNoloadStart) # addiu $t0, $t0, -0x6df0
@ -19,9 +19,9 @@ glabel EntryPoint
sw $zero, 4($t0)
bnez $t1, .L80246010
addi $t0, $t0, 8
lui $t2, %hi(Main) # $t2, 0x8024
lui $t2, %hi(main_func) # $t2, 0x8024
lui $sp, %hi(gIdleThreadStack) # $sp, 0x8020
addiu $t2, %lo(Main) # addiu $t2, $t2, 0x6dc4
addiu $t2, %lo(main_func) # addiu $t2, $t2, 0x6dc4
jr $t2
addiu $sp, %lo(gIdleThreadStack) # addiu $sp, $sp, 0xa00
nop

@ -1,303 +0,0 @@
glabel alloc_bank_or_seq
/* 0D13DC 803163DC 27BDFF88 */ addiu $sp, $sp, -0x78
/* 0D13E0 803163E0 AFB00020 */ sw $s0, 0x20($sp)
/* 0D13E4 803163E4 00808025 */ move $s0, $a0
/* 0D13E8 803163E8 AFBF0024 */ sw $ra, 0x24($sp)
/* 0D13EC 803163EC AFA5007C */ sw $a1, 0x7c($sp)
/* 0D13F0 803163F0 14E000CC */ bnez $a3, .L80316724
/* 0D13F4 803163F4 AFA60080 */ sw $a2, 0x80($sp)
/* 0D13F8 803163F8 3C0E8022 */ lui $t6, %hi(gSeqLoadedPool) # $t6, 0x8022
/* 0D13FC 803163FC 25CE1328 */ addiu $t6, %lo(gSeqLoadedPool) # addiu $t6, $t6, 0x1328
/* 0D1400 80316400 148E0006 */ bne $a0, $t6, .L8031641C
/* 0D1404 80316404 26030194 */ addiu $v1, $s0, 0x194
/* 0D1408 80316408 3C0A8022 */ lui $t2, %hi(gSeqLoadStatus) # $t2, 0x8022
/* 0D140C 8031640C 254A1910 */ addiu $t2, %lo(gSeqLoadStatus) # addiu $t2, $t2, 0x1910
/* 0D1410 80316410 AFAA005C */ sw $t2, 0x5c($sp)
/* 0D1414 80316414 10000009 */ b .L8031643C
/* 0D1418 80316418 A3A0005B */ sb $zero, 0x5b($sp)
.L8031641C:
/* 0D141C 8031641C 3C0F8022 */ lui $t7, %hi(gBankLoadedPool) # $t7, 0x8022
/* 0D1420 80316420 25EF14F8 */ addiu $t7, %lo(gBankLoadedPool) # addiu $t7, $t7, 0x14f8
/* 0D1424 80316424 160F0005 */ bne $s0, $t7, .L8031643C
/* 0D1428 80316428 3C0A8022 */ lui $t2, %hi(gBankLoadStatus) # $t2, 0x8022
/* 0D142C 8031642C 254A18D0 */ addiu $t2, %lo(gBankLoadStatus) # addiu $t2, $t2, 0x18d0
/* 0D1430 80316430 240C0001 */ li $t4, 1
/* 0D1434 80316434 A3AC005B */ sb $t4, 0x5b($sp)
/* 0D1438 80316438 AFAA005C */ sw $t2, 0x5c($sp)
.L8031643C:
/* 0D143C 8031643C 8C62001C */ lw $v0, 0x1c($v1)
/* 0D1440 80316440 240BFFFF */ li $t3, -1
/* 0D1444 80316444 8FAA005C */ lw $t2, 0x5c($sp)
/* 0D1448 80316448 15620003 */ bne $t3, $v0, .L80316458
/* 0D144C 8031644C 93AC005B */ lbu $t4, 0x5b($sp)
/* 0D1450 80316450 10000003 */ b .L80316460
/* 0D1454 80316454 00003825 */ move $a3, $zero
.L80316458:
/* 0D1458 80316458 004AC021 */ addu $t8, $v0, $t2
/* 0D145C 8031645C 93070000 */ lbu $a3, ($t8)
.L80316460:
/* 0D1460 80316460 8C620028 */ lw $v0, 0x28($v1)
/* 0D1464 80316464 24090003 */ li $t1, 3
/* 0D1468 80316468 01274026 */ xor $t0, $t1, $a3
/* 0D146C 8031646C 15620003 */ bne $t3, $v0, .L8031647C
/* 0D1470 80316470 2D080001 */ sltiu $t0, $t0, 1
/* 0D1474 80316474 10000003 */ b .L80316484
/* 0D1478 80316478 00002825 */ move $a1, $zero
.L8031647C:
/* 0D147C 8031647C 004AC821 */ addu $t9, $v0, $t2
/* 0D1480 80316480 93250000 */ lbu $a1, ($t9)
.L80316484:
/* 0D1484 80316484 0008202B */ sltu $a0, $zero, $t0
/* 0D1488 80316488 10800005 */ beqz $a0, .L803164A0
/* 0D148C 8031648C 00E03025 */ move $a2, $a3
/* 0D1490 80316490 01252026 */ xor $a0, $t1, $a1
/* 0D1494 80316494 2C840001 */ sltiu $a0, $a0, 1
/* 0D1498 80316498 0004682B */ sltu $t5, $zero, $a0
/* 0D149C 8031649C 01A02025 */ move $a0, $t5
.L803164A0:
/* 0D14A0 803164A0 2CCE0001 */ sltiu $t6, $a2, 1
/* 0D14A4 803164A4 11C00004 */ beqz $t6, .L803164B8
/* 0D14A8 803164A8 2CAF0001 */ sltiu $t7, $a1, 1
/* 0D14AC 803164AC AC600000 */ sw $zero, ($v1)
/* 0D14B0 803164B0 10000020 */ b .L80316534
/* 0D14B4 803164B4 24080001 */ li $t0, 1
.L803164B8:
/* 0D14B8 803164B8 11E00005 */ beqz $t7, .L803164D0
/* 0D14BC 803164BC 00A01025 */ move $v0, $a1
/* 0D14C0 803164C0 24180001 */ li $t8, 1
/* 0D14C4 803164C4 AC780000 */ sw $t8, ($v1)
/* 0D14C8 803164C8 1000001A */ b .L80316534
/* 0D14CC 803164CC 24080001 */ li $t0, 1
.L803164D0:
/* 0D14D0 803164D0 10800003 */ beqz $a0, .L803164E0
/* 0D14D4 803164D4 00000000 */ nop
/* 0D14D8 803164D8 10000016 */ b .L80316534
/* 0D14DC 803164DC 24080001 */ li $t0, 1
.L803164E0:
/* 0D14E0 803164E0 11000004 */ beqz $t0, .L803164F4
/* 0D14E4 803164E4 00000000 */ nop
/* 0D14E8 803164E8 AC600000 */ sw $zero, ($v1)
/* 0D14EC 803164EC 10000011 */ b .L80316534
/* 0D14F0 803164F0 24080001 */ li $t0, 1
.L803164F4:
/* 0D14F4 803164F4 15220005 */ bne $t1, $v0, .L8031650C
/* 0D14F8 803164F8 24080001 */ li $t0, 1
/* 0D14FC 803164FC 240D0001 */ li $t5, 1
/* 0D1500 80316500 AC6D0000 */ sw $t5, ($v1)
/* 0D1504 80316504 1000000B */ b .L80316534
/* 0D1508 80316508 24080001 */ li $t0, 1
.L8031650C:
/* 0D150C 8031650C 11060003 */ beq $t0, $a2, .L8031651C
/* 0D1510 80316510 00000000 */ nop
/* 0D1514 80316514 10000007 */ b .L80316534
/* 0D1518 80316518 AC600000 */ sw $zero, ($v1)
.L8031651C:
/* 0D151C 8031651C 11020003 */ beq $t0, $v0, .L8031652C
/* 0D1520 80316520 24180001 */ li $t8, 1
/* 0D1524 80316524 10000003 */ b .L80316534
/* 0D1528 80316528 AC780000 */ sw $t8, ($v1)
.L8031652C:
/* 0D152C 8031652C 100000B2 */ b .L803167F8
/* 0D1530 80316530 00001025 */ move $v0, $zero
.L80316534:
/* 0D1534 80316534 8C790000 */ lw $t9, ($v1)
/* 0D1538 80316538 2405000C */ li $a1, 12
/* 0D153C 8031653C 03250019 */ multu $t9, $a1
/* 0D1540 80316540 00006812 */ mflo $t5
/* 0D1544 80316544 006D7021 */ addu $t6, $v1, $t5
/* 0D1548 80316548 8DC2001C */ lw $v0, 0x1c($t6)
/* 0D154C 8031654C 11620010 */ beq $t3, $v0, .L80316590
/* 0D1550 80316550 01427821 */ addu $t7, $t2, $v0
/* 0D1554 80316554 150C000E */ bne $t0, $t4, .L80316590
/* 0D1558 80316558 A1E00000 */ sb $zero, ($t7)
/* 0D155C 8031655C 8C780000 */ lw $t8, ($v1)
/* 0D1560 80316560 03050019 */ multu $t8, $a1
/* 0D1564 80316564 0000C812 */ mflo $t9
/* 0D1568 80316568 00796821 */ addu $t5, $v1, $t9
/* 0D156C 8031656C 8DA4001C */ lw $a0, 0x1c($t5)
/* 0D1570 80316570 A3AC005B */ sb $t4, 0x5b($sp)
/* 0D1574 80316574 AFAA005C */ sw $t2, 0x5c($sp)
/* 0D1578 80316578 0C0C57A9 */ jal discard_bank
/* 0D157C 8031657C AFA30030 */ sw $v1, 0x30($sp)
/* 0D1580 80316580 8FA30030 */ lw $v1, 0x30($sp)
/* 0D1584 80316584 24080001 */ li $t0, 1
/* 0D1588 80316588 8FAA005C */ lw $t2, 0x5c($sp)
/* 0D158C 8031658C 93AC005B */ lbu $t4, 0x5b($sp)
.L80316590:
/* 0D1590 80316590 8C640000 */ lw $a0, ($v1)
/* 0D1594 80316594 24010001 */ li $at, 1
/* 0D1598 80316598 26050198 */ addiu $a1, $s0, 0x198
/* 0D159C 8031659C 50800006 */ beql $a0, $zero, .L803165B8
/* 0D15A0 803165A0 8CAE0000 */ lw $t6, ($a1)
/* 0D15A4 803165A4 10810032 */ beq $a0, $at, .L80316670
/* 0D15A8 803165A8 26050198 */ addiu $a1, $s0, 0x198
/* 0D15AC 803165AC 10000092 */ b .L803167F8
/* 0D15B0 803165B0 00001025 */ move $v0, $zero
/* 0D15B4 803165B4 8CAE0000 */ lw $t6, ($a1)
.L803165B8:
/* 0D15B8 803165B8 AC6E0014 */ sw $t6, 0x14($v1)
/* 0D15BC 803165BC 8FAF0088 */ lw $t7, 0x88($sp)
/* 0D15C0 803165C0 AC6F001C */ sw $t7, 0x1c($v1)
/* 0D15C4 803165C4 8FB80080 */ lw $t8, 0