Commit Graph

217 Commits

Author SHA1 Message Date
LagoLunatic eca6bd2d13 Minor cleanup 2025-09-28 13:57:06 -04:00
LagoLunatic 048d242eef bpw partial cleanup, fix inline usage across several actors 2025-09-18 20:17:27 -04:00
LagoLunatic c2d26ab17d m_Do_ext work 2025-09-17 12:41:00 -04:00
maimai0254 6980cbaa21 d_a_bdk (#888)
* d_a_bdk - 98%

* C-style

* maybe 100%

* Resolve protected access violation

* Set configure.py to matching
2025-09-17 10:56:12 -04:00
LagoLunatic 065f517021 Make m_Do_ext fields private, more bmd cleanup 2025-09-15 11:14:19 -04:00
LagoLunatic 3fa09b0dde himo2 closer to matching 2025-09-09 15:23:57 -04:00
LagoLunatic d47ee0ab88 Add empty placeholders to fix HIO funcs missing when linking debug version 2025-09-02 15:25:01 -04:00
Maide 7f22dd203f d_a_cc (#867) 2025-08-26 12:49:28 -04:00
Maide be52be166b d_a_boko (#864)
* d_a_boko

* PR
2025-08-23 23:48:47 -04:00
Jcw87 cd4ae74b8c d_map (#771) 2025-08-22 22:00:46 -04:00
LagoLunatic bb80f9c41e Fix weak func order of m_Do_ext 2025-08-22 13:57:53 -04:00
Kelebek1 661d0b41d2 d_a_tag_light 2025-08-13 20:11:18 +01:00
Maide 1ab3619dbf d_a_stone (#846) 2025-08-11 17:19:18 -04:00
LagoLunatic ab74582059 Fix clangd error with HIO macro 2025-08-06 00:02:22 -04:00
Maide efc93e2fa5 d_a_obj_ohatch (#834)
* d_a_obj_ohatch

* PR
2025-08-05 22:47:01 -04:00
Maide 3f39078485 d_a_majuu_flag (#824)
* d_a_majuu_flag

* PR

* PR

* Fix demo

* Replace .clang-format

---------

Co-authored-by: LagoLunatic <LagoLunatic@users.noreply.github.com>
2025-08-03 20:24:55 -04:00
LagoLunatic 8c07fc8579 Fix JORReflexible 2025-07-28 23:43:44 -04:00
LagoLunatic f449791a8a Match knob00 for JPN, fix knob00 weak func order for all versions 2025-07-28 18:58:36 -04:00
Maide b93c7993da d_a_ki (#821)
* d_a_ki

* PR
2025-07-27 17:19:15 -04:00
LagoLunatic 719ac3f748 Misc cleanup 2025-07-25 22:24:57 -04:00
Maide 9461730b10 d_a_bridge (#811)
* d_a_bridge

* PR
2025-07-22 01:44:41 -04:00
Maide b324f4b1fc d_a_bb (#810)
* d_a_bb

* PR
2025-07-19 22:39:35 -04:00
LagoLunatic cabd8356fe Misc demo work 2025-06-23 18:36:53 -04:00
LagoLunatic 32e5848095 d_a_npc_ji1 a bit closer 2025-06-20 16:36:56 -04:00
SuperDude88 4aadd65d72 Match Most of daNpc_ji1_c (#796)
* More npc_ji1 Work

- Match most remaining code

Still need to fix setHairAngle and do a ton of cleanup

* setHairAngle Closer

* Oops

Why was this not causing an error locally

* More Field Names
2025-06-20 13:45:04 -04:00
LagoLunatic efc33c5fc4 Various inline cleanup 2025-06-19 19:03:11 -04:00
LagoLunatic 3d0aff6a84 daPy_lk_c::dProcTool and daDemo00_c::execute matched, fix up various inlines and template classes, stb OK 2025-06-17 22:30:17 -04:00
LagoLunatic 0146d0b91f d_a_player_main cleanup and inlines 2025-06-15 13:59:16 -04:00
LagoLunatic 92a094ef6d d_file_select matching for JPN and demo 2025-06-14 19:09:05 -04:00
SuperDude88 947a9a05b1 d_file_select Matching on US (#795)
* d_file_select Almost Matching

Down to 3 regswaps and probably weak func ordering

* Fix Remaining Nonmatches

Regswaps figured out by @ammaraskar
2025-06-14 17:09:40 -04:00
LagoLunatic a27e5b3379 Some enum/define cleanup 2025-06-09 16:14:24 -04:00
LagoLunatic e24cbed367 Demo work (#786)
* Demo work

* Fix PAL

* Fix d_door weak func order and link it

* Fix d_door for demo

* JKernel OK on demo + misc

* tag_attention 100% on demo

* More demo work and fix some retail fakematches
2025-06-04 16:50:49 -04:00
LagoLunatic 4e7f5de0f3 d_a_npc_fa1 100% with weak order, add inlines 2025-06-01 19:09:57 -04:00
LagoLunatic 63a92eaa88 More demo work 2025-05-31 23:53:05 -04:00
LagoLunatic b9190842b7 Demo work 2025-05-28 01:39:07 -04:00
LagoLunatic 99c78680de Fix version defines 2025-05-19 20:17:13 -04:00
Mattias Blum c71bb1dafb d_camera 45% (#747)
* 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
2025-05-06 21:02:35 -04:00
LagoLunatic c4eb26b2a1 d_attention cleanup, add mDoCPd inlines 2025-04-27 16:38:29 -04:00
Mm2PL 4d1cb33cd8 d_attention 100% (#701)
* Add helper functions for d_attention

* Copy and adapt code from TP

* Move for better matching layout

* Clean up includes for d_attention.cpp

* Give dAttention_c::nextAttention a return

* Use enums in dAttention_c::getActionBtnB and slight reformat

* Change return types for comparison code to match
I don't love this

* Implement dAttList_c::calcWeight

* Implement dAttention_c::sortList

* Implement dAttDraw_c::draw

* Implement dAttDraw_c::setAnm

* Implement dAttention_c::chaseAttention

* Implement judgement related functions

* Implement dAttention_c::Run and runDrawProc

* Implement dAttention_c::Draw

Actually finish Draw

* Looks like dAttention_c::stockAttention had an unused return value

* Give d_Attention_c::mLockOnState an enum

* Rename field_0x02c to mDrawAttnPos based on TP

* Add comments for fields of d_attention

* Give d_attention's flags an enum (although without names)

* Undo type change for dAttention_c::{chk,set,clr}Flag

Co-Authored-By: LagoLunatic <LagoLunatic@users.noreply.github.com>

* Do not spell the `this` pointer

Co-Authored-By: LagoLunatic <LagoLunatic@users.noreply.github.com>

* Deal with resource enums and inlines

* Move PLAYER_STATUS_FLAG_MAGIC_JUDGEMENT to daPy__PlayerStatus0 enum

* Use inlines and macros

* Add mDoCPd_L_LOCK_BUTTON inline, debug maps claim it exists

Nothing else uses it

* Update TODO comments

* Debug maps claim runXyCheckCB was used but it only makes sense if modified

* Use dComIfGp_getPlayer instead of directly indexing the array

* Locate a few more inlines

* Do not cast to AttentionFlags enum type

* Update configure script

---------

Co-authored-by: LagoLunatic <LagoLunatic@users.noreply.github.com>
2025-04-27 15:12:46 -04:00
Zeclos 0c6c84d675 D_a_obj_doguu (#741)
* createInit for now

* _create almost _draw

* push for now, some functions finished progress on others

* _execute matches

* privatecute matching

* cleanup, almost matched

* data almost matching

* added getStartFrame to mDoExt_baseAnm, everything but data 100% matching

* cleanup and marked as Equivalent in configure.py

* cleanup
2025-04-25 17:12:32 -04:00
LagoLunatic fa7d4d2896 Fix relocation and data value mismatches 2025-04-24 14:53:58 -04:00
Jcw87 be0f59f361 d_mesg 2025-04-17 12:16:48 -07:00
LagoLunatic 36a3a2b660 More inlines, use sizeof for memcard structs 2025-04-16 13:53:30 -04:00
SuperDude88 1f1900bf66 f_op_msg_mng Work (#685)
* f_op_msg_mng work

* Fix Some Conflicts

Haven't had much chance to work on actual progress, still looking to do more matching before merge

* Tiny bit of Work

Little bit of cleanup, start on a couple more functions

* More Matches

Also add back some missing nonmatch comments

* Fixes

* JPN ifdefs

* Inline Fix

Also force one match (there's no way that casting is real)

* Reorder Strings

Fix rodata, I think this order is also slightly more accurate to the function (but I'm not really trying to match it right now anyways)
2025-04-12 21:02:24 -04:00
Mattias Blum 5f287fcaee d_camera 28% (#732)
* 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
2025-04-11 16:37:42 -04:00
LagoLunatic db2c5ef978 Cleanp a bunch of stuff 2025-03-28 20:44:06 -04:00
LagoLunatic bf2a5b9808 shand OK, ship 99.8%, add some missing inlines 2025-03-28 18:15:14 -04:00
mattias-blum d945c14cac d_a_ship 95% (#706)
* Initial Progress

Basic functions at 100% matching

100% Matching:
- `daShip_Draw`
- `daShip_Execute`
- `daShip_IsDelete`
- `daShip_Delete`
- `daShip_createHeap`
- `daShip_Create`

* implemented `getJointPos` inlines in `daTornado_c` needed for d_a_ship

* implemented `Center()` inline in `dCamera_c` needed for d_a_ship

* added `setTranslationX` inline to `J3DTexMtx` needed for match in d_a_ship

* parameters set to `const` for certain inlines in `m_Do_mtx.h`

* added `dComIfGp_onMenuCollect` inline

* changed `shipSpecialDemoStart` return type to `BOOL`

* added member functions to `dPa_waveEcallBack`, `dPa_splashEcallBack `, `dPa_trackEcallBack`

also modified member type of `mRotMtx` of `dPa_waveEcallBack`  and `mPos` of `dPa_trackEcallBack`

* added member to `daGrid_c` that is used in d_a_ship

* added `mDoAud_setShipSailState` and `mDoAud_shipCruiseSePlay` inline functions

* added `fopAcM_seenPlayerAngleY` inline

* d_a_ship mostly matching

approx. 90% matching, mostly regalloc issues. , `checkNextMode`, `setRopePos`, `setHeadAnm`, and `execute` need to have their logic fixer

* replace `unknown_inline_TODO ` from `daShip_c` with `checkForceMove`

* .data match

* .rodata matching

* more inline return type changes from `bool` to `BOOL`

Also changed the array size of `mPlayerStatus`

* implemented `force_calc_wind_rel_angle` inline in `daGrid_c`

* fix `d_a_ship_static`

* fixed `getEmitterAxis`, might need review but works for now

* more progress

* reverted change to `getEmitterAxis`, moved casts to function call in `dPa_waveEcallBack::executeAfter`

* more progress

* change return types of certain inlines from `BOOL` to `u32`

`dComIfGp_checkCameraAttentionStatus`, `dComIfGp_checkPlayerStatus0`, `dComIfGp_checkPlayerStatus1` needed for match in d_a_ship

* fixed memory addresses in `daGrid_c`

* more progress

* resolving symbols

* Initial PR changes

* Removed unnecessary cast

* replaced instances of `PSVECSquareMag` with corresponding inline functions

* update memory layout in `d_a_grid` for consistency

* More PR changes

`checkNextMode` and `procZevDemo` now at 100% matching
2025-03-28 14:17:21 -04:00
LagoLunatic 5cb5fe848b Clean up mDoAud_seStart inline
The devs apparently made 4 versions of this inline instead of just using default arguments.
2025-03-17 15:57:18 -04:00
mattias-blum ae528dc3d9 d_a_fganon 100% (#695)
* added `cBgS_Chk::OffSameActorChk`inline function

* initial progress of d_a_fganon

100% Matching:
- `anim_init`
- `tama_draw`
- `daFganon_Draw`
- `daFganon_IsDelete`

Partial Matching:
- `daFganon_Hio_C::daFganon_HIO_c` (88%)
- `deru_brk` (98%, code is matching, variable memory locations needed for 100% match)
- `kieru_brk` (98%, code is matching, variable memory locations needed for 100% match)
- `deru_brk2` (98%, code is matching, variable memory locations needed for 100% match)
- `kieru_brk2` (98%, code is matching, variable memory locations needed for 100% match)
- `pos_move` (73%)
- `move` (80%)
- `mahou_se_set` (82%)
- `daFganon_Delete` (94%, code is matching, variable memory locations needed for 100% match)
- `useHeapInit` (92%)
- `daFganon_Create` (77%)
- `fgannon_class::fganon_class()` (88%)

Remainder haven't been started

* Additional progress, more functions at 100% matching

100% Matching:
- `daFganon_Hio_C::daFganon_HIO_c`
- `anim_init`
- `tama_draw`
- `daFganon_Draw`
- `deru_brk`
- `kieru_brk`
- `deru_brk2`
- `kieru_brk2`
- `pos_move`
- `fly_se_set`
- `mahou_set`
- `mahou_se_set`
- `daFganon_IsDelete`
- `daFganon_Delete`
- `useHeapInit`

Partial Matching:
- `fly` (60%)
- `shot` (46%)
- `move` (92%)
- `daFganon_Execute` (11%)
- `daFganon_Create` (60%)
- `fgannon_class::fganon_class()` (93%)

* More functions at 100% matching

- Added a `cXyz` member to `mant_class` that is referenced in this TU.
- Changed 'fganon_class` to inherit from `fopEn_enemy_c` instead of `fopAc_ac_c`

100% Matching:
- `daFganon_Hio_C::daFganon_HIO_c`
- `anim_init`
- `tama_draw`
- `daFganon_Draw`
- `deru_brk`
- `kieru_brk`
- `deru_brk2`
- `kieru_brk2`
- `pos_move`
- `fly_se_set`
- `fly`
- `shot`
- `spinattack`
- `fly2`
- `tama_set`
- `mahou_set`
- `mahou_set`
- `mahou_se_set`
- `daFganon_IsDelete`
- `daFganon_Delete`
- `useHeapInit`
- `fgannon_class::fganon_class()`

Partial Matching:
- `move` (96%, code is matching, variable memory locations needed for 100% match)
- `daFganon_Execute` (96%, code is matching, variable memory locations needed for 100% match)
- `daFganon_Create` (96%, code is matching, variable memory locations needed for 100% match)

* additional functions at 100% matching

Cleaned up the values of the static globals, will resolve their symbols later

100% Matching:
- `daFganon_Hio_C::daFganon_HIO_c`
- `anim_init`
- `tama_draw`
- `daFganon_Draw`
- `deru_brk`
- `kieru_brk`
- `deru_brk2`
- `kieru_brk2`
- `pos_move`
- `fly_se_set`
- `fly`
- `shot`
- `spinattack`
- `fly2`
- `tama_set`
- `mahou_set`
- `shot2`
- `spinattack2`
- `down`
- `kabe_check`
- `deru`
- `kieru`
- `fail`
- `standby`
- `start`
- `last_end`
- `damage_check`
- `ball_tg_check`
- `mahou_se_set`
- `daFganon_IsDelete`
- `daFganon_Delete`
- `useHeapInit`
- `fgannon_class::fganon_class()`

Partial Matching:
- `end` (97%, code is matching, variable memory locations needed for 100% match)
- `move` (97%, code is matching, variable memory locations needed for 100% match)
- `demo_camera` (63%)
- `daFganon_Execute` (97%, code is matching, variable memory locations needed for 100% match)
- `daFganon_Create` (98%, code is matching, variable memory locations needed for 100% match)

* added `mDoAud_changeSubBgmStatus` inline

* changed return type of `dComIfGp_getPlayerCameraID` inline

needed this change to get a match for this `d_a_fganon`

* d_a_fganon 100% matching

Currently the checksum fails but I have some theories as to why that might be. I'll continue to cleanup the symbols.

* symbol cleanup

* fixed `mDoAud_changeSubBgmStatus` calling wrong function

* 100% matching now, checksum passes

There is a weak function ordering issue so I included the param in `configure.py`

* PR changes made

* Additional PR changes, better naming of class members
2025-03-16 19:04:00 -04:00