Commit Graph

2729 Commits

Author SHA1 Message Date
LagoLunatic 8a602cb87f fix compilation error 2026-08-03 16:37:34 -04:00
Anders Gjerde cb6a9205db d_a_salvage_tbox - 100% (GZLJ01, GZLE01, GZLP01) (#1113)
* First attempts at d_a_salvage_tbox

* CreateHeap match

* set_mtx 87%

* set_mtx 100%

* initWaitGetItem 93%

* initWaitGetItem 98.24%

* initWaitGetItem 98.24% - removed comments

* Removed unecessary fields

* actWait02 78.04%

* daSTBox_Draw 100%

* _create 39.71%

* _create 80.10%

* _create 98.50%

* Some changes in class members to be done, _create 99.99%, started on shadowEcallBack.

* _create 100%, shadowEcallBack.getMaxWaterY 84.93%, shadowEcallBack.setup 100%

* shadowEcallBack.getMaxWaterY 93.68%

* shadowEcallBack.getMaxWaterY 94.64%

* shadowEcallBack.getMaxWaterY 99.32%

* getWaterY 99.62%

* Swap position of mpAngle to get setup back to 100%

* actWait02 81.50%

* actDrop 74.60%

* actDrop 98.80%

* actWait 32.54%

* actWait 84.60%

* actWait 88.69%

* actWait 99.35%

* actWait02 100%

* _delete 55.71%

* _delete 97.57%

* _delete 99.12%

* shadowEcallBack_c::execute 79.13%

* shadowEcallBack_c::execute 99.70%

* CreateInit 94.92%

* CreateInit 98.64%

* shadowEcallBack_c::draw 21.24%

* shadowEcallBack_c::draw 34.81%

* shadowEcallBack_c::draw 54.72%

* shadowEcallBack_c::draw 69.86%

* shadowEcallBack_c::draw 97.99%

* shadowEcallBack_c::draw 99.10%

* actWait 99.43%

* _execute 40.58%

* _execute 73.14%

* _execute 98.29%

* initWaitGetItem improvements 98.24%

* initWaitGetItem 100%

* Removed unnecessary this->

* _delete 100%

* actWait 99.82%

* CreateInit 99.52%

* shadowEcallBack_c::getMaxWaterY 99.32%

* CreateInit 99.52%

* Simplified getStaffId in _execute

* shadowEcallBack_c::draw 99.11%

* shadowEcallBack_c::draw 99.23%

* shadowEcallBack_c::draw 99.48%

* actWait 99.85%

* Named shadowCallback

* actDrop 99.60%

* Renamed m_arc_name to m_arcname

* actWait 99.97% - using dComIfGp_particle_setShipTail

* _execute 99.58% - changed actIdx type to s16

* _execute 98.43% - reverting actIdx type back to int.

* CreateInit 99.92% - created cXyz position in shadowEcallBack.

* _execute 100% - cast on ship.

* .rodata 100% - Moved crane_offset above actWait where it first is used.

* Hoisted alpha_arr in shadowEcallBack_c::execute but to no avail.

* shadowEcallBack_c::execute 100% - emitter->setGlobalTranslation for regswap and used inline emitter->setGlobalRotation

* shadowEcallBack_c::draw 100% - moved fVar3 down a few lines to fix regswap

* shadowEcallBack_c::execute 100% - getting global translation object, only modifying its y property, and setting it again.

* Removed Nonmatching from matching functions and fixed memory offsets in shadowEcallBack_c.

* Linked - Added destructor for shadowEcallBack and added Matching in configure.py

* Set MatchingFor Japanese, United Statian and European versions - demo differs quite a bit.

* Removed incorrectly added include d_a_ship.h from d_com_inf_game.h

---------

Co-authored-by: Anders Gjerde <mail@mail.com>
2026-08-03 16:36:40 -04:00
LagoLunatic 27e65e0f29 "control stick" -> "main stick" for consistency 2026-08-03 15:11:57 -04:00
LagoLunatic b8c26428ed Use CPad macros when accessing controller fields 2026-08-03 14:35:16 -04:00
LagoLunatic 15b181b15c Add enums for msg icons and control codes 2026-08-03 14:08:19 -04:00
LagoLunatic 7d10c4357a p1 cleanup 2026-08-03 02:08:28 -04:00
LagoLunatic 537b6cfc3b use 4 spaces for indentation instead of 2/8/etc 2026-08-03 01:53:25 -04:00
WilliamArnett 11f4940d74 d_a_npc_p1 100% Matching (#1098)
* 99% match

* Rewrote _execute to increase accuracy. Only issue in .text is a label not loading correctly. I have no idea how to fix this.

* Equivalent. Weak func ordering.

* 7% text

* 28% text

* 41% text

* 65% text

* Rewrote _execute to increase accuracy. Only issue in .text is a label not loading correctly. I have no idea how to fix this.

* Equivalent. Weak func ordering.

* 82% text

* Equivalent. A lot of work is needed to name variables and clean up functions. Weak function ordering is wrong.

* Cleaned some functions, named several variables, and began documenting dialog tree.

* Naming a couple more variables

* 21% text

* change out getMySubstanceP for getMyIntegerP inline

* 100% text

* Refactor to use JUT_ASSERT macro

* #181: d_a_tag_attention matching; TODO: implement chk_inside and dComIfGp_att_Look2RequestF

* #181: continue working on d_a_tag_attention, matching almost complete

* #181: revert naming class member (not certain enough)

* #181: preliminary changes to resolve #784 comments regarding usage of debug maps

* #181: commit suggestion by @WilliamArnett, fixing regalloc error

Co-authored-by: WilliamArnett <149556961+WilliamArnett@users.noreply.github.com>

* #181: fix missing curly bracket

* #181: resolve #784 comments with the kind help of @WilliamArnett;
 move `daTagAttention::Act_c::chk_inside` to header file; split `plyrToObjVec` definition to match assembly;
 remove temp variable, use values directly and swap operands;
 implement `Look2RequestF` in `include/d/d_attention.h`;
 remove non-matching use of temp variable `iVar1` and replace `current.pos` with uninitialized variable in `daTagAttention::Act_c::_execute`

* Update fork to match upstream

* some changes

* 73% text

* 100% Matching minus kaji_anm

* Delete debug/m2cdecomp

* revert unnecessary file changes

* remove d_a_npc_p2_cut.inc

* Match kaji_anm

* swap declaration order of l_msg and l_msgId

* Naming many fields

* Implement GetKajiID inline

* Enum and variable names

* Remove virtual genMessage function

* Implement @LagoLunatic 's suggested changes

* Revert array changes in d_camera.h (@LagoLunatic suggested change)

* Whitespace

* Rename dSnap enum

---------

Co-authored-by: Skelp <skelp@pm.me>
Co-authored-by: Skelp <59535863+Skelp@users.noreply.github.com>
2026-08-03 01:40:12 -04:00
LagoLunatic 380407dd26 msg work (#1143)
* fopMsgM_msgDataProc_c::stringSet work

* Fix JPN

* More stringSet work

* work

* get rid of fake temps

* stringSet 99.99%

* fopMsgM_msgDataProc_c::stringLength 100%

* d_msg work

* fix pal

* fix message_paper, d_meter version diff fixes
2026-08-02 21:04:29 -04:00
Benjamin ROELANDT dbc093a3cf d_scope 100% (#1112)
* First version of d_scope, everything is matching on all version, probably missing a few inline on undocumented field that i did not manage to find

* Readd stuff previously deleted but badly tested

* Rename some fields and a few more inline

doesn't improve matching but i think it looks more genuine

* clean up syntax

* move d_scptyp enum and add forgotten inline

* build fix

* replace seStart call with proper enum
2026-08-02 11:45:21 -04:00
LagoLunatic 6b911411f0 Actually fix debug_map_diff.py paths 2026-07-31 19:12:55 -04:00
LagoLunatic fa73747971 Fix paths in debug_map_diff.py 2026-07-31 19:02:36 -04:00
Mattias Blum d46b64f9cb d_menu work (#1141)
* more progress

* more progress

* more progress

* more progress

* d_menu work

d_menu_collect class members cleaned up, some functions at 100% matching

* added `Nonmatching` tag to unmatched functions

* more functions at 100%

* more functions matching

* more functions matching
2026-07-31 13:33:36 -04:00
LagoLunatic 45718d8ccc Compiler compat fix: Passing of rvalue GXColors to non-const reference parameters (#1142) 2026-07-31 13:20:48 -04:00
LagoLunatic 641268e340 TVec template fixes (#1140)
* TVec template fixes

* Fix cubic
2026-07-31 13:14:06 -04:00
LagoLunatic c9b2970033 obj_drift minor cleanup 2026-07-31 12:01:12 -04:00
Teddy Heidmann 5063d3433c zeldaret/tww#385 d_a_obj_drift (#1100)
* zeldaret/tww#385 d_a_obj_drift

* configure changes

* GZLJ01

* D44J01

* Not matching D44J01

* demo support

* variable cleanup

* revert new helper

* revert again

* Attempt 2

* Try to fix non-deterministic issue

* Revert tide fix

* debug mapping

* more map fixes

* Update src/d/actor/d_a_obj_drift.cpp

Co-authored-by: LagoLunatic <LagoLunatic@users.noreply.github.com>

* review comments

---------

Co-authored-by: LagoLunatic <LagoLunatic@users.noreply.github.com>
2026-07-30 22:46:56 -04:00
LagoLunatic 2bebe68302 majyuu door inlines 2026-07-30 17:17:14 -04:00
Teddy Heidmann 32cd6f7080 d_a_obj_majyuu_door 100% Matching (#1138)
* Initial structure

* More progress

* fix index

* _create()

* more progress

* modeProcCall

* fix smoke_set

* Matching

* add demo support, remove current.roomNo

* cleanup
2026-07-30 17:11:54 -04:00
LagoLunatic be8da688fc zl1 cleanup, inline cleanup 2026-07-27 12:14:38 -04:00
Zeclos 7fae08bcd1 Hi1_demo zl1 cleanup (#1136)
* matching

* cleanup

* d_a_npc_tt matching outside of _create and rodata

* matching

* demo matching + cleanup zl1

* undo removed line

* sorry
2026-07-26 11:32:13 -04:00
LagoLunatic 2091385155 Demo matches 2026-07-24 14:25:28 -04:00
LagoLunatic 5faa15219c Add camera profiles, fix camera struct sizes 2026-07-24 11:57:07 -04:00
LagoLunatic 26d9efe3b6 Unindent some namespaces 2026-07-24 11:30:45 -04:00
LagoLunatic 7efaae45c7 A couple demo matches 2026-07-24 11:25:35 -04:00
LagoLunatic af1c8e261e Add enum for pearls/symbols 2026-07-23 22:07:02 -04:00
LagoLunatic 4efda6f355 Minor cleanup
Inlines, wrong indentation, enums, private fields, etc
2026-07-23 17:48:51 -04:00
LagoLunatic 2115d05965 d_a_npc_ls1 anim field naming pass, add enums 2026-07-22 21:28:12 -04:00
LagoLunatic 96347ab502 Clean up angle constants and conversions (#1135)
* Add angle conversion constants and macros

* Replace angle literals with hex instead of decimal
2026-07-22 20:13:31 -04:00
WilliamArnett bf372802ca d_a_npc_bm1 100% Matching Retail (#1107)
* 99% match

* Rewrote _execute to increase accuracy. Only issue in .text is a label not loading correctly. I have no idea how to fix this.

* Equivalent. Weak func ordering.

* 7% text

* 28% text

* 41% text

* 65% text

* Rewrote _execute to increase accuracy. Only issue in .text is a label not loading correctly. I have no idea how to fix this.

* Equivalent. Weak func ordering.

* 82% text

* Equivalent. A lot of work is needed to name variables and clean up functions. Weak function ordering is wrong.

* Cleaned some functions, named several variables, and began documenting dialog tree.

* Naming a couple more variables

* 21% text

* change out getMySubstanceP for getMyIntegerP inline

* 100% text

* Refactor to use JUT_ASSERT macro

* #181: d_a_tag_attention matching; TODO: implement chk_inside and dComIfGp_att_Look2RequestF

* #181: continue working on d_a_tag_attention, matching almost complete

* #181: revert naming class member (not certain enough)

* #181: preliminary changes to resolve #784 comments regarding usage of debug maps

* #181: commit suggestion by @WilliamArnett, fixing regalloc error

Co-authored-by: WilliamArnett <149556961+WilliamArnett@users.noreply.github.com>

* #181: fix missing curly bracket

* #181: resolve #784 comments with the kind help of @WilliamArnett;
 move `daTagAttention::Act_c::chk_inside` to header file; split `plyrToObjVec` definition to match assembly;
 remove temp variable, use values directly and swap operands;
 implement `Look2RequestF` in `include/d/d_attention.h`;
 remove non-matching use of temp variable `iVar1` and replace `current.pos` with uninitialized variable in `daTagAttention::Act_c::_execute`

* Update fork to match upstream

* some changes

* 12% text

* 21% text

* 26% text

* 43% text

* 51% text

* Revert unnecessary file changes

* Update d_a_tag_attention.cpp

* 55% text

* 52% text

* 52% text

* 56% text

* 68%

* 77% text

* 100% matching minus regswap

* 100% matching for retail

* Many more demo matches

* Fix broken match in _create()

* Demo Match

* Add some missing inlines

* Fix dComIfGp_setMesgCameraInfoActor

* More inline matching

* fix broken demo match

* Name some fields

* Utilize EventBit enum

* Name more fields, and add inline calls to d_a_npc_ls1

* Remove comments

* Implement @LagoLunatic suggested changes

* remove actor cast from dSnap_RegistFig calls

* Fix broken match in eInit_ATTENTION_

* Second round of @LagoLunatic 's suggested changes

---------

Co-authored-by: Skelp <skelp@pm.me>
Co-authored-by: Skelp <59535863+Skelp@users.noreply.github.com>
2026-07-22 20:10:59 -04:00
LagoLunatic 5c556d3c53 Enum usage 2026-07-22 12:36:48 -04:00
LagoLunatic ebc8cd2caf d_cam_param OK 2026-07-20 21:48:48 -04:00
Mattias Blum 61a3a0ac17 d_cam_param 100% for GZLE01 (#1126)
* initial progress

* more progress

* more progress

* more progress

* more progress

* more progress

* more progress

* more progress

* more progress

* more progress

* more progress

* more progress

* fix outdated member names

* more progress

* more progress

* more progress

* more progress

* more progress

* more progress

* fixed deprecated member references

* more progress

* more progress

* more progress

* fix deprecated member references

* more progress

* more progress

* more progress

* more progress

* more progress

* check in for review

* remove comment

* initial PR changes

* more PR changes

* more PR changes

* added anonymous struct as class member

* reverted changes to `stage_camera2_data_class`

* added `dCamera_event_data`, `dCamera_monitoring_things` and `dCamera_DMC_system` from debug maps

* more progress

* more progress

* realmatch for `camera_draw`

* PR changes

* fix broken merge

* formatting

* Reverted change to `camSphChkdata` that caused  `sph_chk_callback` match to regress

* Reverted change to `BG` struct that caused ctor and dtor match to regress

* more progress

* more progress

* more progress

* more progress

* more progress

* more progress

* more progress

* more progress

* more progress

* more progress

* more progress

* PR changes

* corrected size comment

* fixed broken member references

* more d_camera work

* remove comment

* update symbols

* d_cam_param 100% for GZLE01

Code is 100% matching

* Update math.h
2026-07-19 17:00:55 -04:00
LagoLunatic 0fdc3a3f3b Cleanup/documentation for various photo-related code 2026-07-19 15:54:06 -04:00
LagoLunatic 9f18a6f34c d_picture_box closer to matching for other versions 2026-07-18 21:31:38 -04:00
Mattias Blum db61d31022 d_picture_box mostly matching for GZLE01 (#1125)
* initial progress

* more progress

* more progress

* d_picture_box mostly matching for GZLE01

Unable to resolve the regswap in dJle_Pb_c::draw()

* reverted some changes to member names

* filled missing enum value

* PR changes made

* renamed some fields
2026-07-18 17:37:31 -04:00
LagoLunatic c1513e97e5 Some npc/ship inline fixes from debug map 2026-07-17 16:08:55 -04:00
Zeclos d3d65a4d8c d_a_npc_mk matching (#1115)
* matching

* cleanup

* d_a_npc_tt matching outside of _create and rodata

* matching

* all symbols matching order wrong fake inline usage

* matching

* cleanup, naming of some fields and enums

* undo changes
2026-07-16 17:23:52 -04:00
LagoLunatic c562f05ffa Merge pull request #1120 from LagoLunatic/clib-limit
Improve cLib limit inlines
2026-07-16 17:21:09 -04:00
LagoLunatic c30c494a15 Some demo matches and fake inline fixes 2026-07-14 17:06:45 -04:00
LagoLunatic 0f8be7a620 debug_map_diff.py: Diff alignment 2026-07-14 16:52:49 -04:00
LagoLunatic a498fbb50e Make debug_map_diff.py much more accurate for main.dol TUs
Functions are now marked as "FAKE?" instead of "FAKE" in cases where it's possible that they only seem fake due to the linker map not showing duplicate symbols multiple times (inlines used in multiple TUs).

"UNREFERENCED DUPLICATE" data in the base maps are now also taken into account. Also, limited linkage diffing can be done for main.dol symbols (based on the naming convention of l_ and g_ prefixes).
2026-07-14 16:38:20 -04:00
LagoLunatic 43b5e42feb Extract float formatting to separate function to reduce logic duplication 2026-07-14 11:02:06 -04:00
LagoLunatic 2833539046 Asset extraction: Raise error for wrong-sized symbols 2026-07-14 10:57:34 -04:00
LagoLunatic 2fdc8f35cc Asset extractor: Include headers that define Vec/cXy/GXColor 2026-07-14 10:55:14 -04:00
LagoLunatic a1ef9f163e Fix tn sjis error again 2026-07-14 10:53:58 -04:00
LagoLunatic c06b3874cc Extract Embedded Model Data (#1117)
* Add Model Extraction Script

- Support extraction of Vec/cXy/GXColor data

* Extract Embedded Model Data
2026-07-14 10:45:53 -04:00
SuperDude88 fbf39c24c9 Extract Embedded Model Data 2026-07-13 17:09:49 -04:00
SuperDude88 99f93ebe98 Add Model Extraction Script
- Support extraction of Vec/cXy/GXColor data
2026-07-13 17:09:42 -04:00
LagoLunatic 5319b0e006 Update dtk-template and tools (#1116) 2026-07-13 14:04:37 -04:00