Currently the C preprocessor is used to remove comments from the text
files before encoding them.
However the option used (`-fpreprocessed`) is only supported by gcc –
but not by clang, which breaks the macOS build.
By using Python to remove comments, we can remove the use of this
gcc-specific option, and fix the macOS build.
* Document `func_800D1694` as `Matrix_TranslateRotateYXZ`
* Document `func_800D1FD4` as `Matrix_ReplaceRotation`
* Cleanup `Matrix_RotateAxis`
* Document `func_800A7EC0` as `SkinMatrix_SetRotateAxis`
* Document `func_800D2A34` and `func_800D2A98` as `Matrix_SetTranslateScaleMtx`(`F`)
* Document mostly unused functions at the end of `sys_matrix.c`
* Add in-use renamed functions to `namefixer.py`
* Add `Matrix_SetTranslateScaleMtx2` to `namefixer.py`
* Run formatter
* Fix namefixer.py mistake from #952
* Format clang-11.1
* Fix `Matrix_TranslateRotateYXZ` wrongly documented, it actually is `Matrix_SetTranslateRotateYXZ`
* VS Code is stellar at refactoring (no)
* Run formatter
* Come on VS Code
* Improve `Matrix_ReplaceRotation` docs
* Fix typo
* Fix namefixer.py
* Add pad_text to mkldscript and update progress.py
Implements `pad_text` from MM and uses it instead of asm nops for the padding in ucode_disas.
Also updates `progress.py` to account for the change (RIP 1000000 code size), and to have a green badge for 100%.
* Remove 1.00mb comment in progress.py
Co-authored-by: Anghelo Carvajal <angheloalf95@gmail.com>
Co-authored-by: Anghelo Carvajal <angheloalf95@gmail.com>
* Initial progress on z_message_PAL, very messy
* Fix merge
* Some more progress
* Fix merge
* More z_message_PAL
* Small progress
* More small progress
* message_data_static files OK
* Prepare z_message_tables
* Matched another function, small updates
* Attempt to use asm-processor static-symbols branch
* Refactor text id declarations
* Begin large text codes parser function
* Fix merge
* Refactor done
* Build OK, add color and highscore names
* Remove encoded text headers and automatically encode during build
* Fix kanfont
* Various cleanups
* DISP macros
* Another match aside data
* Further progress
* Small improvements
* Deduplicate magic values for text control codes, small improvements
* Tiny progress
* Minor cleanups
* Clean up z_message_PAL comment
* Progress on large functions
* Further progress on large functions
* Changes to mkldscript to link .data in the .rodata section
* data OK
* Few improvements
* Use gDPLoadTextureBlock macros where appropriate
* rm z_message_tables, progress on large functions
* 2 more matches
* Improvements
* Small progress
* More progress on big function
* progress
* match func_80107980
* match Message_Update
* match func_8010BED8
* done
* Progress on remaining large functions
* Small progress on largest function
* Another match, extract text and move to assets, improve text build system
* Small nonmatchings improvements
* docs wip
* Largest function maybe equivalent
* Fix merge
* Document do_action values, largest function is almost instruction-matching
* Rename NAVI do_action to NONE, as that appears to be how that value is used in practice
* Fix merge
* one match
* Last function is instruction-matching
* Fix
* Improvements thanks to engineer124
* Stack matched thanks to petrie911, now just a/v/low t regalloc issues, some cleanup
* More variables labeled, use text state enum everywhere
* More labels and names
* Fix
* Actor_IsTalking -> Actor_TalkRequested
* Match func_8010C39C and remove unused asm
* More docs
* Mostly ocarina related docs
* All msgModes named
* Fix assetclean
* Cleanup
* Extraction fixes and headers
* Suggestions
* Review suggestions
* Change text extraction again, only extract if the headers do not already exist
* Fix
* Use ast for charmap, fix assetclean for real this time
* Review suggestions
* BGM ids and ran formatter
* Review comments
* rename include_readonly to include_data_with_rodata
* Remove leading 0s in number directives
* Review suggestions for message_data_static
* textbox pos enum comments, rename several enum names from Message to TextBox
Co-authored-by: Thar0 <maximilianc64@gmail.com>
Co-authored-by: Zelllll <56516451+Zelllll@users.noreply.github.com>
Co-authored-by: petrie911 <pmontag@DESKTOP-LG8A167.localdomain>
Co-authored-by: Roman971 <romanlasnier@hotmail.com>
* Update names and doc of `Matrix_RotateRPY` and `SkinMatrix_SetRotateRPY` to ZYX Tait-Bryan angles
* Update name and doc of `Matrix_JointPosition` to `Matrix_TranslateRotateZYX`
* `Euler ***` -> `Tait-Bryan *** angles`
* Update docs of `SkinMatrix_Vec3fMtxFMultXYZW` and `SkinMatrix_Vec3fMtxFMultXYZ`
* Fix doc of `SkinMatrix_MtxFMtxFMult`
* Update docs of `SkinMatrix_Invert`
* Change name and docs of `SkinMatrix_SetRotateYRP` to `SkinMatrix_SetRotateYXZ`
* Change name and docs of `SkinMatrix_SetScaleRotateRPYTranslate` to `SkinMatrix_SetScaleRotateZYXTranslate`
* Change name and docs of `SkinMatrix_SetScaleRotateYRPTranslate` to `SkinMatrix_SetScaleRotateYXZTranslate`
* Change name and docs of `SkinMatrix_SetRotateRPYTranslate` to `SkinMatrix_SetRotateZYXTranslate`
* Add renamed functions to `namefixer.py`
* Run formatter
* Consistent function names (`ABC()` if equivalent to `A() B() C()`)
* Automatic XML for link_animetion
* Make sure tutorial images are not gitignored
* OK
* Correct ovl_Boss_Sst RangeEnd
* ExternalFiles
* Remove Segment="128"
* Remove segments from place_title_cards
* format, newlines, remove previous xml
* Implement a single Object Table for the enum and the segments
* Implement a single Actor Table for the enum and the overlays
* Implement a single Effect SS Table for the enum and the overlays
* Remove initvars.h and move its content to relevant files
* Update object 0 to use OBJECT_NONE and document it in the table
* Rename OBJECT_NONE to OBJECT_INVALID to avoid confusion
* Document EnGoroiwa and BgJyaGoroiwa
* Run format.sh
* Add renamed functions to actorfixer script
* no more calling out "the devs" for bad code
* `EnGoroiwa#flags` -> `stateFlags`
* `Matrix_MtxFToRotS` -> `Matrix_MtxFToYXZRotS` (and not ZXY oops), `func_800D2264` -> `Matrix_MtxFToZYXRotS`
* Document Moblins (EnMb)
* Use actual decomp-style function names
* Add renamed functions to actorfixer.py
* Add general documentation and add EnMbType enum to check moblin subtype
* Add fig's doc comment on Actor_TestFloorInDirection
* Revert documentation on z_eff_ss_dead.c
* remove `gSPFogPosition(?,?)` comments on `gSPFogFactor` uses in z_rcp.c
* run formatter
* 13 functions left, data imported
* 2 left
* 1 left
* OK
* Begin naming
* sfx rename
* spec
* Begin naming, add LINK_IS_CHILD to EnDu
* Fix spelling of its/it's
* Document most of object_dekubaba, import symbols
* Document draw functions, begin on actionfuncs
* New actor function names, some float constants
* Name almost everything
* Delete asm
* Name size, format
* Review changes
* Review changes
* Brackets, format
* Mostly done but shifted
* still messed up
* Almost OK
* OBJECT_JYA_OBJ OK, OBJECT_GR OK
* Done
* Merge master and format
* Cleanup
* Cleanup 2
* Start object MB dont merge yet
* Object_MB OK
* Object_ydan_objects OK
* General 'ydan' actor cleanup
* Forgot some small things
* Object_EC OK
* add .gitkeep and run format
* Object_sd OK but no textures cause of a zap issue
* PR fixes
* Fix object_sd
* fix ydan
* delete .gitkeep files
* OBJECT_BOX as far as it can go with current ZAP
* Fix undefined_syms
* Start child link object
* Push progress, dont merge yet
* Object_mori_objects OK
* Fixed?
* Fix conflicts again
* Seems like i missed some textures
* Extract data for BgBombwall
* More field
* ZAP YEP 2.0
* Object_Box OK
* Object_SD ok. Ready to merge
* remove ASM and merge master
* remove ASM
* remove files wrongfully added to docs/
* Almost done
* Change comment in z_player_lib.c
* forgot some DLists in player_lib.c
* Fix conflict, run format
* Same as before but this time with Tex and TLUT
* Last few things
* fix object_GR and add limbs to object_sd
* Nane -> Name
* gChildDekuShieldMtx is now a matrix and not a blob
* PR fixes (Fig)
* add a space for comment in z_player_lib.c
* re push and new lines
* PR fixes (AngheloAlf)
* PR fixes (Roman)
* Fix Heishi2
* PR fixes (Fig)
* Replace spacing in a file
* PR fixes (Roman)
* ViMode OK
* Fix variable name in regconvert tool
* ViMode: fix formatting
* Add nonmatching impl for ViMode_Configure, respond to PR
- Fixed struct field naming (unkXX -> unk_XX)
- ViMode_Configure args are not flags for top/left etc; seem to be for
video mode
- Used @Random06457's implementation of `ViMode_LogPrint`
* Use plain LOG_ADDRESS in ViMode_LogPrint
* Incorporate PR feedback from Roman971
* Decompile ovl_kaleido_scope + minor cleanups
* Add a common header for ovl_kaleido_scope
* Start cleaning up and documenting kaleido_scope (+ some interface docs)
* Improve and fix some kaleido_scope non matchings
* Match KaleidoSetup_Init
* Extract icon_item_fra/ger_static files
* Add more documentation and matches to kaleido_scope
* Improve the z_kaleido_collect.c non matching
* Rename z_kaleido_8081EFF0.c to z_kaleido_prompt.c
* Update most kaleido variables to be static
* Improve GS flag macros
* Improve z_lmap_mark.c and extract z_lmap_mark_data.c with a script
* Various minor fixes and improvements
* Minor fixes and review changes
* Review changes part 2
* Rename gSetTileCustom to gDPSetTileCustom
* Review changes part 3
* Initial xml
* most of in-code references
* Add limbs and evrything else
* Functions used by EnRiverSound
* Fix forearm and use void* for textures
* Run formatter