1
0
mirror of https://github.com/zeldaret/oot.git synced 2024-09-21 12:54:51 +00:00
Commit Graph

176 Commits

Author SHA1 Message Date
Roman971
106f7a3f6a
Match and improve some non matchings (#254) 2020-07-15 11:23:57 -04:00
snablu
4e1fc875c3
Decompiled z_en_md.c (#246)
* Decompile z_bg_haka_trap.c

* Update spec

delete old .reloc.s file

Co-authored-by: Random <28494085+Random06457@users.noreply.github.com>

* Deleted reloc.s and made style changes to function pointers and local vars

* Renamed timer field, added more useful temp names

* Implemented Roman's suggestions, including moving enum to header file, moving some static variables inside functions, removing unnecessary casts, removing unnecessary temps, and fixing a few style issues

* Commented dual purpose of unk_16A and formatted file again

* Decompiled z_en_md.c

decompiled EnMd_Init

Decompiled EnMd_Draw

Decompiled EnMd_Destroy and EnMd_Update

Decompiled func_80AAC104

Decompiled func_80AAA92C

Decompiled func_80AAA93C

Decompiled func_80AAA274

Decompiled func_80AAA308

Decompiled func_80AAA39C

Decompiled func_80AAA474

Decompiled func_80AAA508

Decompiled func_80AAA5A4

Decompiled func_80AAA638

Decompiled func_80AAA6D4

Decompiled func_80AAA768

Decompiled func_80AAA7FC

Decompiled func_80AAA890

Decompiled func_80AAA93C

Decompiled func_80AAA250

Decompiled func_80AAB874

Decompile func_80AAAA24

Decompiled func_80AABD0C

Decompiled func_80AAB8F8

Decompiled func_80AAAE94

Decompiled func_80AAACF8

Decompiled func_80AAADE0

Decompiled func_80AAAE14

Decompiled func_80AAB03C

Decompiled func_80AAB0E0

Decompiled func_80AAB370

Decompiled func_80AAB4DC

Decompiled func_80AAB5A4

Decompiled func_80AABC10

Decompiled func_80AAAC78

Decompiled func_80AABEF0

Decompiled func_80AAB158

Decompiled func_80AAAF04

Decompiled func_80AAB948

Migrated data into C file

Commented out data file (migrated data)

Removed data file from spec

about to try changing alpha type

cleaned up functions except for last two

fixed player and player2 issue

Decompiled z_en_md.c

* updated actor field names to match upstream changes

* deleted old asm nonmatchings (whoops)

* Update src/overlays/actors/ovl_En_Md/z_en_md.h

Co-authored-by: Roman971 <32455037+Roman971@users.noreply.github.com>

* Update src/overlays/actors/ovl_En_Md/z_en_md.c

Co-authored-by: Roman971 <32455037+Roman971@users.noreply.github.com>

* Update src/overlays/actors/ovl_En_Md/z_en_md.c

Co-authored-by: Roman971 <32455037+Roman971@users.noreply.github.com>

* Update src/overlays/actors/ovl_En_Md/z_en_md.c

Co-authored-by: Roman971 <32455037+Roman971@users.noreply.github.com>

* Update src/overlays/actors/ovl_En_Md/z_en_md.c

Co-authored-by: Roman971 <32455037+Roman971@users.noreply.github.com>

* Update src/overlays/actors/ovl_En_Md/z_en_md.c

Co-authored-by: Roman971 <32455037+Roman971@users.noreply.github.com>

* removed unnecessary forward declarations

* got rid of unnecessary temps in path functions, added names based on strong copy paste similarity with en_kz, minor formatting changes

* Update src/overlays/actors/ovl_En_Md/z_en_md.c

Co-authored-by: Roman971 <32455037+Roman971@users.noreply.github.com>

* Update src/overlays/actors/ovl_En_Md/z_en_md.c

Co-authored-by: Roman971 <32455037+Roman971@users.noreply.github.com>

* pass EnMd* to appropriate functions instead of Actor*

* Update src/overlays/actors/ovl_En_Md/z_en_md.c

Co-authored-by: Roman971 <32455037+Roman971@users.noreply.github.com>

* Update src/overlays/actors/ovl_En_Md/z_en_md.c

Co-authored-by: Roman971 <32455037+Roman971@users.noreply.github.com>

* finish renaming limb draw funcs

* inlined vector data and moved static data

* Update src/overlays/actors/ovl_En_Md/z_en_md.c

Co-authored-by: Roman971 <32455037+Roman971@users.noreply.github.com>

* ran formatter and completed name change in PostLimbDraw

* removed address-of array for sAnimations

Co-authored-by: Random <28494085+Random06457@users.noreply.github.com>
Co-authored-by: Roman971 <32455037+Roman971@users.noreply.github.com>
2020-07-14 15:59:45 -04:00
Ethan Roseman
eb10acb8ed
Decompiled ovl_En_Blkobj (#242)
* Decompiled ovl_En_Blkobj

* PR suggestions

* gfx commands
2020-07-14 01:15:43 -04:00
Sirius902
8c72e1dea6
Decompiled ovl_Shot_Sun (#236)
* match ShotSun_Init

* match ShotSun_Destroy

* match func_80BADDCC

* break up unk_19C to add spawnTimer

* ShotSun_Update

* func_80BADE74

* work on func_80BAE05C

* make func_80BAE05C closer

* use proper macros for osSyncPrintf

* format if statement better and add temp player pointer func_80BAE05C

* Reorder spawnPos to match stack args later

* match func_80BAE05C

* almost match func_80BADF0C

* Remove temporary and add parenthesis

* change part of comment and move last unk_1A4 assignment to be similar to decompiler

* Change do while(false) to if (1)

* func_80BADF0C

* change comment

* update spec

* fix vt macro

* cleanup and name

* remove asm

* remove data

* remove extern

Co-authored-by: Random <28494085+Random06457@users.noreply.github.com>

* remove & for function pointers

* rename and retype D_02007020

* format

* remove tiny whitespace

* reorder if statement

* finish renaming

* replace cast with bitwise operation

* move globally used functions to functions.h

* reorder description

* move headers for EnItem00 and EnAObj to z64actor.h

* retype Item_DropCollectible and Item_DropCollectible2 to return EnItem00*

* rename ShotSun_StartFairyCountdown to ShotSun_TriggerFairy

* rename ShotSun_FairyCountdown to ShotSun_SpawnFairy

* add unk_E3EC field to MessageContext

* rename to ShotSun_UpdateHyliaSun for now

* remove != 0 on flag check

* remove unsigned suffix and use enum constant for Item_DropCollectible call

* add unk_95C field to Player

* add ub comment

* retype unk_1A4 and remove explicit struct padding

* Update src/overlays/actors/ovl_Shot_Sun/z_shot_sun.c

Co-authored-by: Roman971 <32455037+Roman971@users.noreply.github.com>

Co-authored-by: Random <28494085+Random06457@users.noreply.github.com>
Co-authored-by: Roman971 <32455037+Roman971@users.noreply.github.com>
2020-07-12 19:03:38 -04:00
fig02
8b6e86649d
En_Heishi1 and Eff_Ss_Solder_Srch_Ball OK (#234)
* progress

* init ok and merge master

* enheishi1 and srchball OK

* cleanup

* cleanup

* cleanup

* more cleanup

* done

* more comments

* add file headers

* some review comments

* move vectors

* more review comments

* angle in decimal

* add prototype

* semicolon would be good

* fix

* make unset actor ids 0

* reword comment

* no &
2020-07-09 15:12:03 -04:00
Random
b4a7ac9d71
Decompile shrink_window.c (#232) 2020-07-08 21:54:39 -04:00
Ethan Roseman
7f6e9d55fe
Decompiled ovl_Demo_Sa (#231)
* Decompiled ovl_Demo_Sa

* PR suggestions

* ff -> alpha

* PR suggestions

* Reverting cutscene data
2020-07-08 19:40:09 -04:00
Ethan Roseman
f3edd3ee77
Decompiled ovl_En_Si (#239)
* Decompiled ovl_En_Si

* Description

* Update src/overlays/actors/ovl_En_Si/z_en_si.c

Co-authored-by: Roman971 <32455037+Roman971@users.noreply.github.com>

* Update src/overlays/actors/ovl_En_Si/z_en_si.c

Co-authored-by: Roman971 <32455037+Roman971@users.noreply.github.com>

* Update src/overlays/actors/ovl_En_Si/z_en_si.c

Co-authored-by: Roman971 <32455037+Roman971@users.noreply.github.com>

Co-authored-by: Roman971 <32455037+Roman971@users.noreply.github.com>
2020-07-07 06:39:06 -04:00
Lucas Shaw
7e195a3562
Matched most remaining libultra files (#221)
* osPfsIsPlug.c and osContSetCh.c OK

* update

* __osPfsGetStatus.c OK

* removed unused asm

* Updated all libultra controller files to use new structs instead of the temporary structs. Added os_pfs.h

* controller updates

* fixed header guard

* Made suggested changes

* guLookAt.c OK

* commit

* __osPfsSelectBank.c OK

* osPfsDeleteFile.c OK

* pfsreadwritefile.c OK

* osPfsFreeBlocks.c OK

* cleaned up ospfsfreeblocks

* started pfsinitpak.c

* pfsallocatefile.c OK

* contpfs.c decompiled with 1 non matching

* osPfsFindFile.c OK

* pfsinitpak.c decompiled. one non-matching

* Actually fixed merge conflict

* sins.c OK

* cosf.c sinf.c and sins.c OK

* moved osAfterPreNMI to its own file. Renamed code_801031F0 to contquery.c

* pfschecker.c OK

* final update and rename

* Removed makefile testing thing that i accidentally added

* Made suggested changes
2020-07-06 20:15:01 -04:00
Ethan Roseman
a5aee3d691
Decompiled ovl_En_Zl2 (2 nonmatchings) (#223)
* Almost dun

* 3 more, progress...

* 2 more

* Fixing field rename

* improvement

* 1 more

* progress

* more

* work

* Preparing for PR

* Comments

* tidbits

* more tidbits

* fixes

* PR comments

* Nonmatching reloc

* PR suggestions

* PR suggestions
2020-07-04 14:34:51 +02:00
Roman971
4a64c556b0
Fix and improve some non matchings (#229) 2020-06-30 14:44:07 -04:00
louist103
7946d6698c
Decomp BgJyaLift (#216)
* Re upload

* Decomp BgJyaLift

* Fixed issues

Fixed issues from review

* Edits after review

* Review Fixes

Made some fixes and also changed an unknown variable name

* Fixes to file

Fixed some styling things and renamed the last function

* Added fixes

Added roman's fixes

* Delete filemap.pyc

* Fixes

Removed ctx.c and replaced tabs with spaces spec.
2020-06-24 18:34:31 -04:00
Ethan Roseman
054f6dc04d
Fail the Jenkins build if there's any unused asm (#222)
* Check for unused asm

* Deleting some unused asm
2020-06-23 13:59:59 -04:00
Random
ab1ec89f22
Decompile jpegdecoder.c, padsetup.c and code_800C3C20.c (#217)
* Decompile jpegdecoder.c, padsetup.c and code_800C3C20.c

* change func_800C3C20's prototype and rename some fields in jpeg related structs

* Fix comment in Jpeg_GetU16 and change func_800C3C20

* use a switch in padsetup.c
2020-06-21 18:43:14 -04:00
Ethan Roseman
5f61c105b4
Decompiled ovl_Bg_Spot01_Idohashira (1 non-matching) (#213)
* Almost done

* one non-matching

* PR suggestions

* Further suggestions

* minor correction
2020-06-21 17:50:01 -04:00
Random
4940621679
Decompile pausemgr.c (#211)
* Decompile pausemgr.c

* rename pausemgr to z_kaleido_setup

* replace 0x4b with SCENE_BOWLING

* fix conflict
2020-06-17 15:23:42 -04:00
Ethan Roseman
dcdaf850b6
Decompiled ovl_Bg_Spot18_Obj (#204)
* Decompiled ovl_Bg_Spot18_Obj

* quick fix

* Added description to c file

* Update z_bg_spot18_obj.c

* PR suggestions

* PR suggestion
2020-06-17 08:02:28 -04:00
Lucas Shaw
b86edcf92c
Matched some controller files (#178)
* osPfsIsPlug.c and osContSetCh.c OK

* update

* __osPfsGetStatus.c OK

* removed unused asm

* Updated all libultra controller files to use new structs instead of the temporary structs. Added os_pfs.h

* controller updates

* fixed header guard

* Made suggested changes
2020-06-17 07:16:30 -04:00
Roman971
229e0c8629
Update asm processor and migrate/improve rodata for a few files (#209)
* Update asm processor

* Migrate or improve rodata for a few files
2020-06-14 19:24:09 -04:00
fig02
031d946db7
z_select decompiled, 1 non matching left (#202)
* First pass z_select

* lots of progress. 2 non matchings and data stuff needed

* match Select_LoadGame

* z_select almost ok, 1 func left

* remove comments

* remove comments and add description

* remove unused flg_set asm

* set_next_gamestate macro

* pr suggestions 1

* pr suggestions 2

* map -> scene

* pr suggestions 3

Co-authored-by: Kelebek1 <eeeedddccc@hotmail.co.uk>
2020-06-13 22:59:58 -04:00
snablu
4e70a24274
Decompile z_bg_haka_trap.c (#201)
* Decompile z_bg_haka_trap.c

* Update spec

delete old .reloc.s file

Co-authored-by: Random <28494085+Random06457@users.noreply.github.com>

* Deleted reloc.s and made style changes to function pointers and local vars

* Renamed timer field, added more useful temp names

* Implemented Roman's suggestions, including moving enum to header file, moving some static variables inside functions, removing unnecessary casts, removing unnecessary temps, and fixing a few style issues

* Commented dual purpose of unk_16A and formatted file again

Co-authored-by: Random <28494085+Random06457@users.noreply.github.com>
2020-06-11 17:39:47 -04:00
Lucas Shaw
a0ef48e987
Migrated rodata (#199) 2020-06-09 12:06:23 -04:00
Random
8afab54c23
Decompile mempak.c (#191) 2020-06-07 19:38:33 -04:00
Random
8705d40e54
Split ovl_file_choose and ovl_kaleido_scope (#167)
* Split ovl_file_choose and ovl_kaleido_scope

* Split ovl_kaleido_scope's rodata/data/bss

* fix

* fix spec

* spec fix

* hopefully last spec fix

* hopefully last spec fix 2

* fix

* Add comments on file boundaries

* fix
2020-06-07 13:52:43 -04:00
Roman971
93e8dbcc9e
Decompile the last function in z_en_heishi2.c (#195) 2020-06-07 12:37:44 -04:00
Tharo
b2df45ae06
Decompile ovl_Bg_Spot16_Doughnut (#187)
* Decompile ovl_Bg_Spot16_Doughnut

* Ran formatter

* Shorten float values

Co-authored-by: Roman971 <32455037+Roman971@users.noreply.github.com>

* Fix last float values

* Rename Update2 and Draw2

Co-authored-by: Roman971 <32455037+Roman971@users.noreply.github.com>
2020-06-07 10:54:44 -04:00
Roman971
68f5d212a7
Fix remaining rom/ram pointers (#190) 2020-06-05 17:09:43 -04:00
Random
94d810193a
ucode_disas.c progress (#188)
* ucode_disas.c progress

* fix

* minor fixes

* minor comment changes
2020-06-05 13:18:39 -04:00
krimtonz
c78d93ad78
Remove hard-coded pointers in several files (#186)
* fix hard-coded pointers in code_800DACC0.data.s

* fix hard coded pointer in code_800E11F0.data.s

* fix hard coded pointers in code_800EC960.data.s

* remove fixed pointers in code_800F7260.data.s

* fix hard coded pointers in code_800F9280.data.s

* remove accidental comment

* fix hard coded jump table in Camera_Unique9.s
2020-06-04 17:51:14 -04:00
Robin Allen
69e30364b9
Convert z_map_data to C (#183)
* Convert z_map_data to C

* Style

Co-authored-by: Random <28494085+Random06457@users.noreply.github.com>

* Cleanup

Co-authored-by: Random <28494085+Random06457@users.noreply.github.com>

* Convert the whole file

* Cleanup

* Cleanup

Co-authored-by: Roman971 <32455037+Roman971@users.noreply.github.com>

* floorNames → floorID

* Style

* Format & fix switch array padding

* Remove trailing zeroes

* Cleanup

Co-authored-by: Random <28494085+Random06457@users.noreply.github.com>
Co-authored-by: Roman971 <32455037+Roman971@users.noreply.github.com>
2020-06-03 16:52:10 -04:00
Roman971
78049aa5c5
Fix some missed and fake pointers in code (#180) 2020-06-01 18:55:34 -04:00
krimtonz
77137f5a04
Decompile z_camera data, and some camera WIP (#173)
* cleanup

* name camera action functions

* decompile a few small functions, name a few Camera struct members

* decompile camera data, decompile a few camera functions

* Split ASM for code_800BB0A0

* removing code_800BB0A0.s

* PR Requests, Camera WIP

* remove #define NON_MATCHING from db_camera
2020-06-01 17:54:47 -04:00
krimtonz
08aaba0d2c
Fix hard coded pointers in db_camera (#179) 2020-06-01 14:37:53 -04:00
fig02
78d0883f04
Actor Cleanups (#177)
* rename init chains, colchkinfo, colider inits, damage tables

* actor cleanups

* fix collider init script names

* small fixes

* ichain arg name

* change dynapoly types and names

* revert enru1 data name

* and the type

* pr suggestions
2020-05-31 05:55:48 -04:00
Ethan Roseman
13a94482e5
Decompiled ovl_En_Zl1 (#169)
* Some progress

* progs

* More

* 1 more

* Init

* Slightly better score on one function

* 1 down!

* some progress

* Prep for PR

* PR suggestions

* OK!

* Formatting

* formatting again

* PR comments

* updating ZAP2
2020-05-30 09:33:29 -04:00
fig02
ac97807762
En_Kz OK (#176)
* start kz

* remove irrelevant file

* kz progress

* en_kz progress

* match kz switch

* progress

* kz OK

* kz OK

* sync

* kz done

* delete asm files

* pr suggestions 1
2020-05-29 17:20:00 -04:00
Ethan Roseman
038ab888f6
Decompiled ovl_Bg_Treemouth (#168)
* Almost done

* header

* Decompiled ovl_Bg_Treemouth

* fixing undefined sims

* PR suggestions

* PR suggestions
2020-05-29 17:08:40 -04:00
Tharo
5937aea1d5
Migrate rodata for z_message_PAL and code_80110450 (#174)
* Migrate rodata for z_message_PAL and code_80110450

* Delete code_80110450.rodata.s
2020-05-28 03:49:58 -04:00
Tharo
db987db9f8
Decompile flg_set data (#172)
* Decompile data for flg_set

* Ran formatter

* Remove data/ files
2020-05-27 12:46:59 -04:00
Lucas Shaw
248c0587d6
ovl_End_Title OK (#161)
* One non matching left in ovl_End_Title

* ovl_End_Title OK

* formatting

* removed unused asm files

* changed 0xFF to 255

* updated dlist

* made suggested changes
2020-05-27 11:51:11 -04:00
Roman971
235b0b8e0b
Fix more raw pointers (rsp and part of .data) (#170)
Known files left with pointers in .data after this (possibly the only ones since I checked roughly everything):
- flg_set.c
- z_camera.c
- db_camera.c
- code_800D7CD0.c (ucode_disas.c)
- audio (not sure which ones, see the structure sheet)
2020-05-27 09:06:37 -04:00
Lucas Shaw
02fc5287cc
code_80106550 / llcvt.c and code_80104450 / ortho.c OK (#163)
* llcvt.c OK, added script from mm decomp to set mips3

* ortho.c OK

* added entries to functions.h

* named guNormalize.s
2020-05-27 03:48:07 -04:00
gamestabled
c68d752813
EnHata OK (#155)
* EnHata OK

* made/attempted suggested changes. still havent been able to fix the THIS in Update
2020-05-26 20:05:09 -04:00
Roman971
53ceea717d
Properly align asm & data (+ minor fixes) (#165)
* Add .align 4 directives to all data/ files (+ minor alignment fixes)

* Use .balign for everything and fix typo
2020-05-26 18:09:00 -04:00
fig02
442b15c79f
en_sb OK (#159)
* en_sb OK

* en_sb done

* remove asm

* remove diff.txt

* pr changes

* pr changes 2

* merge master and add description
2020-05-26 11:57:54 -04:00
krimtonz
d48792870c
Decompiles sched.c (#145)
* decompile sched.c

* rename Game_AllocEnd to Game_Alloc in z_effect_soft_sprite.c

* pr updates
2020-05-26 11:39:27 -04:00
Half-asian
3175f5c988
En_Skjneedle OK (#162)
* En_Skjneedle OK

* fix

* file deletions

* file deletions 2

* fix extern

* fix

* cleanup
2020-05-26 10:53:27 -04:00
Roman971
1bb3e006cd
Move last 3 functions in z_message_PAL.c to a separate file (#158)
There is padding in 1.0 here, and rodata is also 16 bytes aligned at this point.
2020-05-26 10:32:18 -04:00
Roman971
2c5ad24c3f
Migrate z_common_data.c's .bss to C (#157) 2020-05-26 08:50:51 -04:00
Random
3d050f2861
Decompile a bunch of small files (#160)
* Decompile a bunch of small files

* Rename dacrate to dacRate

* Run format.sh

* Minor fixes in PR #160
2020-05-25 23:18:14 +02:00