Commit Graph

17 Commits

Author SHA1 Message Date
engineer124
0e441520cc
Document Actor_TalkOfferAccepted (#1502)
* rename

* PR Review
2023-11-21 12:36:02 +11:00
Anghelo Carvajal
cf41eeb3ac
Remove (ActorFunc) cast on InitVars (#1148)
* Remove ActorFunc cast

* Format

* Revert "Format"

This reverts commit a6e89b3969.

* Messing with formatting

* format header a bit

* Revert "Messing with formatting"

This reverts commit c8db520278.

* comment

* format

* more comments

* format

* format

* format

* properly format
2023-10-27 10:03:02 -03:00
Derek Hensley
99dd8a41f9
Docs namefixer (#1378) 2023-09-14 23:24:39 -03:00
engineer124
9c0fc94fe3
Audio Sfx Functions Decompiled and Documented (code_8019AF00.c) (#1242)
* sfx decomp and docs

* function headers

* namefixer

* oops

* better sfx name

* PR review

* namefixer

* PR review

* float

* namefixer

* namefixer

* namefixer

* PR Suggestions
2023-06-20 23:13:51 -04:00
engineer124
92bdfe68c2
z_rcp.c setupDL docs/cleanup (#1253)
* SetupDL enum

* name functions

* namefixer

* cleanup

* small cleanup

* PR Review

* don't need address of array

* PR Suggestion
2023-05-28 19:08:29 -04:00
Anghelo Carvajal
3c107cb148
Add SaveInfo substruct to SaveContext (#1191)
* SaveInfo

* fix accesses in sram_NES.c

* some more fixing

* more fixes

* format

* fix unk

* namefixer

* format

* bss

* review

* weekeventregconvert

* namefixer

* bss
2023-04-18 18:54:32 -04:00
engineer124
a17949e730
Document z_en_time_tag (#1140)
* time-tag docs

* simplify enums

* PR Reviews

* PR Suggestions

* small change

* small fix

* PR Suggestions

* add extra func ref

* rm raw text from first actor I decompiled

* Stock Pot Inn

* fix master merge
2023-03-16 13:47:38 +11:00
Anghelo Carvajal
c833969ea7
z_actor documentation pass (#1154)
* ActorContext_unk_1F4

* a

* ACTOR_FLAG_IGNORE_QUAKE

* ACTOR_FLAG_TALK_REQUESTED and ACTOR_FLAG_CANT_LOCK_ON

* actorCtx->unkC => ctorCtx->halfDaysBit

* HALFDAYBIT defines

* actor.halfDaysBits

* format

* Actor_InitHalfDaysBit

* Name actor-killing functions

* cleanup variables.h a bit

* DAWN

* bss

* Actor_RequestRumble and Actor_GetArrowDmgFlags

* name vars of func_800BC620

* format

* fix missing PLAYER_IA

* Actor_OfferGetItem

* Actor_SetClosestSecretDistance

* freezeCategoryPlayerFlags1

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

* DROPFLAG_

* a

* COLORFILTER

* format

* sCategoryFreezeMasks

* Actor_OfferCarry

* review

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

* change hex to dec

* COLORFILTER_INTENSITY_FLAG

* format

* review

Co-authored-by: Derek Hensley <hensley.derek58@gmail.com>

* shiftedHalfDaysBit

Co-authored-by: Derek Hensley <hensley.derek58@gmail.com>

* cleanup

* Undo Actor_RequestRumble

* Undo ACTOR_FLAG_IGNORE_QUAKE

* format

* Remove COLORFILTER_GET_BUFFLAG

* Undo Actor_KillAllFromUnloadedRooms

* format

* Update Actor_OfferGetItem comment

* Update Actor_OfferGetItem description

* diving

* bss

* namefixer

* format

* speed

* review

---------

Co-authored-by: Dragorn421 <Dragorn421@users.noreply.github.com>
Co-authored-by: Derek Hensley <hensley.derek58@gmail.com>
2023-03-09 12:35:23 -05:00
engineer124
e8f3039264
speedXZ -> speed (#1186)
* speedXZ to speed

* brackets
2023-03-03 11:07:51 -03:00
Anghelo Carvajal
8a714af8d0
Introduce actor_table.h (#985)
* Make actor_table.h

* DECLARE_OVERLAY_SEGMENT

* InitVars

* Remove InitVars from actor headers

* format

* Use table for ActorID enum

* Move segment symbols declarations back to segment_symbols.h

* add newline to actor_table.h

* Add effects back to segnt_symbols.h

* Update include/tables/actor_table.h

Co-authored-by: engineer124 <47598039+engineer124@users.noreply.github.com>

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

Co-authored-by: EllipticEllipsis <elliptic.ellipsis@gmail.com>

* name unused parameters

Co-authored-by: EllipticEllipsis <elliptic.ellipsis@gmail.com>

* format

* Revert "name unused parameters"

This reverts commit 14fe63313a.

* Remove `const` from InitVars

* Add underscore to unused parameters

* ActorID -> ActorId

* bss

* missing symbols and bss

* lower diff a bit

Co-authored-by: engineer124 <47598039+engineer124@users.noreply.github.com>
Co-authored-by: EllipticEllipsis <elliptic.ellipsis@gmail.com>
2022-10-16 20:06:47 -03:00
engineer124
8e45eb7b1f
z_parameter: Items & Import Data (#799)
* Import Data

* More functions

* cleanup

* Add Enum

* Many changes, PR and add-ons

* Fix bss

* Better data

* Extra space

* DoubleDefense is boolean

* Missed a macro

* More enums missed

* macro -> enum

* More item cleanup...

* missing/wrong quest items

* Next PR Review

* Revert Interface_AddMagic to Parameter_AddMagic

* Remove QUEST_HEART_CONTAINER

* Fix bss

* Move Color_RGB16 up + fix incorrect numbers

* Add texture pointers

* Add comment

* EQUIP_SLOT_A

* rm redundant comment

* Fix merge

* PR Suggestions

* fix bss
2022-07-12 00:45:55 -04:00
Parker Burnett
3503163a64
Adding Git information to tutorial (#862)
* Adding an intro to git with helpful commands for someone unfamiliar
with git.

Co-authored by: EllipticEllipsis <elliptic.ellipsis@gmail.com>

* Adding an intro to git with helpful commands for someone unfamiliar
with git.

Co-authored-by: EllipticEllipsis <elliptic.ellipsis@gmail.com>

* ovl_Obj_Y2lift decompiled (#856)

* ovl_Obj_Y2lift decompiled

* format

* pr review fixes

* clean up

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

* Formating files and moving contributing.md
Also fixes links.

* Adding an intro to git with helpful commands for someone unfamiliar
with git.

formating files too

Co-authored-by: EllipticEllipsis <elliptic.ellipsis@gmail.com>

* pr fixes

Co-authored-by: EllipticEllipsis <elliptic.ellipsis@gmail.com>
Co-authored-by: Alejandro Asenjo <96613413+sonicdcer@users.noreply.github.com>
Co-authored-by: SonicDcer <noreply@github.com>
2022-07-11 20:27:49 -04:00
Tom Overton
158d1b26b0
PlayState rename (#835)
* PlayState rename

* Make this work with the latest master and run format

* Respond to hensldm's review

* Respond to Elliptic's review

* Add Effect_GetPlayState to namefixer.py

* Add missed comma
2022-06-26 11:57:37 -04:00
Anghelo Carvajal
b08880f7a7
z_sram_NES with 2 NON_MATCHINGs and 1 NON_EQUIVALENTs (#531)
* Rename Sram_InitDebugSave

* Sram_InitDebugSave

* err

* Sram_IncrementDay

* non_matchings

* func_80146F5C and protos

* func_80146EE8

* func_80145698

* func_80143A54

* Split SaveContext

* problems with bss

* Fix bss

* more

* a small bunch

* Fix warnings

* almost everything

* two attempts

* at least compiles

* import data

* bss

* format

* stuff?

* Progress?

* More progress

* clean up data a little

* More progress

* disaster

* re split data

* A bit less of a disaster

* Fix renamed stuff

* data stuff

* fix conflicts

* format

* CycleSceneFlags

* some enums

* cleanup

* Fix merge issues

* format

* some changes

* format

* Lots of progress on z_sram_NES, but no matches yet

* SaveContent Documentation

* Oops

* Oops2

* Document more SaveContext

* Oops, don't need that anymore

* add small comment

* Another comment

* dekuPlaygroundPlayerName

* Fix merge issues

* format

* Update src/code/z_sram_NES.c

Co-authored-by: engineer124 <47598039+engineer124@users.noreply.github.com>

* Update src/code/z_sram_NES.c

Co-authored-by: engineer124 <47598039+engineer124@users.noreply.github.com>

* Update src/code/z_sram_NES.c

Co-authored-by: engineer124 <47598039+engineer124@users.noreply.github.com>

* Update src/code/z_sram_NES.c

Co-authored-by: engineer124 <47598039+engineer124@users.noreply.github.com>

* Update src/code/z_sram_NES.c

Co-authored-by: engineer124 <47598039+engineer124@users.noreply.github.com>

* Update src/code/z_sram_NES.c

Co-authored-by: engineer124 <47598039+engineer124@users.noreply.github.com>

* Update src/code/z_sram_NES.c

Co-authored-by: engineer124 <47598039+engineer124@users.noreply.github.com>

* Update src/code/z_sram_NES.c

Co-authored-by: engineer124 <47598039+engineer124@users.noreply.github.com>

* Update src/code/z_sram_NES.c

Co-authored-by: engineer124 <47598039+engineer124@users.noreply.github.com>

* Update src/code/z_sram_NES.c

Co-authored-by: engineer124 <47598039+engineer124@users.noreply.github.com>

* Update src/code/z_sram_NES.c

Co-authored-by: engineer124 <47598039+engineer124@users.noreply.github.com>

* Update src/code/z_sram_NES.c

Co-authored-by: engineer124 <47598039+engineer124@users.noreply.github.com>

* remove magic number

* format

* fix merge issues

* bss

* format

* macro cleanup

* review

* merge issues

* review

* cleanup

* UNK_TYPE1

* Fix

* Remove comment

* small change

* conflicts

* review

* fix

* fixes

* format

* Update actorCtx renames part

* Match func_80143B0C thanks to Petrie and Anon

* minor cleaning pass

* format

* cleanup

* more minor cleanups

* Macros for accessing gSaveContext.save.stolenItems

* Introduce STOLEN_ITEM_NONE and remove CLEAR_STOLEN_ITEM_

* format

* Update include/macros.h

Co-authored-by: Derek Hensley <hensley.derek58@gmail.com>

* Update src/code/z_sram_NES.c

Co-authored-by: Derek Hensley <hensley.derek58@gmail.com>

* Update src/code/z_sram_NES.c

Co-authored-by: Derek Hensley <hensley.derek58@gmail.com>

* Update src/code/z_sram_NES.c

Co-authored-by: Derek Hensley <hensley.derek58@gmail.com>

* Update src/code/z_sram_NES.c

Co-authored-by: Derek Hensley <hensley.derek58@gmail.com>

* Update src/code/z_sram_NES.c

Co-authored-by: Derek Hensley <hensley.derek58@gmail.com>

* Update src/code/z_sram_NES.c

Co-authored-by: Derek Hensley <hensley.derek58@gmail.com>

* Update src/code/z_sram_NES.c

Co-authored-by: Derek Hensley <hensley.derek58@gmail.com>

* @hensldm review

* Update include/functions.h

Co-authored-by: engineer124 <47598039+engineer124@users.noreply.github.com>

* Update include/functions.h

Co-authored-by: engineer124 <47598039+engineer124@users.noreply.github.com>

* Rename QUEST_SONG_NEW_WAVE

* Add scene name comments to D_801C5FC0

* rename horseData.yaw

* Update include/functions.h

Co-authored-by: engineer124 <47598039+engineer124@users.noreply.github.com>

* Update src/code/z_sram_NES.c

Co-authored-by: engineer124 <47598039+engineer124@users.noreply.github.com>

* Update src/code/z_sram_NES.c

Co-authored-by: engineer124 <47598039+engineer124@users.noreply.github.com>

* Update src/code/z_sram_NES.c

Co-authored-by: engineer124 <47598039+engineer124@users.noreply.github.com>

* Update src/code/z_sram_NES.c

Co-authored-by: engineer124 <47598039+engineer124@users.noreply.github.com>

* Update src/code/z_sram_NES.c

Co-authored-by: engineer124 <47598039+engineer124@users.noreply.github.com>

* // = CUR_UPG_VALUE(UPG_WALLET);

* run actorfixer and format

* fix bss

* Fix merge problems and run format

* Some improvements to func_801457CC by anon

* bss

* format

* run actorfixer

* actorfixer, bss and format

* Use original names for the RESPAWN_MODE enum because the current ones are bad

* QUEST_SONG_BOSSA_NOVA

* some minor fixes on the SaveContext struct according to the debug rom

* Merge Inventory.items and Inventory.masks

* a

* simplify saveBuf accesses

* A few func renames

* actorfixer

* bss

* fixes

* bss

* actorfixer

* actorfixer and format

* actorfixer

* whoops

* whops

* bss

Co-authored-by: engineer124 <engineer124engineer124@gmail.com>
Co-authored-by: engineer124 <47598039+engineer124@users.noreply.github.com>
Co-authored-by: Derek Hensley <hensley.derek58@gmail.com>
2022-03-27 12:37:02 -03:00
Andzura
4f3202fd7e
z_message progress (#701)
* 8 functions matching, 1 non-matching, 45 untouched

* match func_801518B0

* match func_8014CC14

* matching 8 func, 1 non-matching

* matched func_80148CBC

* matched func_80156758

* matched func_80147564

* matched func_80151BB4

* matched func80152EC0/Message_Spawn_Song_Effect

* matched func_80151C9C

* WIP func_80148B98

* WIP func_80151938

* matched func_80151938

* matched func_80148B98

* matched func_80147734

* matched func_80147624

* WIP func_8014EBC

* match func_801518B0

* matched func_80147564

* matched func80152EC0/Message_Spawn_Song_Effect

* matched func_80151C9C

* WIP func_80148B98

* matched func_80151938

* matched func_80148B98

* matched func_80147734

* matched func_80147624

* WIP#2 func_8014EBC

* matched func_80149EBC

* WIP func_8014CCB4

* matched func_8014CCB4

* matched func_80151A68

* WIP func_8014D62C

* fix func_8015A68 signature

* z_message_nes & z_message_staff progress

* z_message_nes & z_message_staff renaming

* documenting z_message

* cleaning & renaming

* documenting MessageContext

* matched func_80151A68

* format

* naming convention fix

* re-add func_80147564

* apply renaming of Message_ShouldAdvanceSilent on the whole project

* re-format, add clang-format off/on in z_message.c needed for matching

* rename staff => credits; add renames in actorfixer.

* change rupees array to ascii

* remove useless comments

* change MessageContext.decodedBuffer to a union

* remove decodedBuffer from actorfixer

* applied AngheloAlf suggestions & ran sfxconvert on z_message.c

* rename message_struct => message_data_static; revert decodedBuffer as union creating differences.

* use true/false instead of 1/0

* use SET_FULLSCREEN_VIEWPORT macro in func_80152c64

* AngheloAlf suggestions.

* extract assign from dayTime calculation for readability in Message_LoadTimeNES

* remove bss_reordering from osFlash, idle & boot_main to typedef MessageTableEntry in message_data_static & make decodedBuffer an union.

* remove useless casts

* Changes hexa to ascii chars when it's meaningful;
add comments to func_8014CCB4 to show what hexa constant means.

* Hensldm suggestions

* ran actorfixer on new changes; fix new bss reordering error introduced with rebase

* use new TIME_TO_MINUTES_F macro

* re-ran format.sh

* hensldm suggestions #2 + overall cleaning

* remove useless parenthesis

* Update include/message_data_static.h

Co-authored-by: Anghelo Carvajal <angheloalf95@gmail.com>

* actorfixer and format

* more fixes

Co-authored-by: Andzura <andzura@andzura.fr>
Co-authored-by: abaud <adrien.baud@inria.fr>
Co-authored-by: Anghelo Carvajal <angheloalf95@gmail.com>
2022-03-27 12:09:47 -03:00
Anghelo Carvajal
6069a1585f
z_actor with some documentation, with 1 NON_EQUIVALENTs (#401)
* Match Player_GetHeight

* Another bunch

* Fix merge conflict

* rename Gfx_DrawDListXlu

* add WEEROR

* Actor_Spawn

* almost Actor_SpawnTransitionActors  and Actor_Delete

* A bunch of small actors

* More renames

* format

* Some Player renames

* a few more

* import data

* run formatter

* func_800B7170

* whoops

* Fix merge issues

* Whoops 2

* func_800B83BC and func_800B83F8

* Actor_IsActorFacingPlayerAndWithinRange

* add some prototypes

* match Actor_UpdateBgCheckInfo

* func_800B7678

* mark Actor_SpawnAsChildAndCutscene as non_matching

* Actor_Draw

* Update is chaotic

* 2 new matches

* func_800BC8B8

* Another bunch

* function renames

* run formatter

* cleanup

* remove unnecesary casts

* add missing sfx

* Fix renames

* fix merge

* func_800BF7CC

* small bunch

* another bunch

* func_800BE184 non_matching

* two more

* split z_cheap_proc

* Another bunch

* another bunch

* a few and a non matching

* yeee

* a

* Actor_DrawAll non_equivalent

* Actor_RecordUndrawnActor

* i don't know what to put in this commit message

* func_800B4B50 non matching

* func_800B42F8 non matching

* func_800B5040

* func_800B5814 non_equiv

* func_800B6584

* func_800B6608

* func_800B6680

* func_800B7E04

* func_800B8118

* func_800b9170

* ,

* func_800BC4EC

* func_800BA6FC

* func_800BA798

* func_800BA8B8

* Actor_LoadOverlay

* small cleanup

* func_800BB2D0

* meh

* func_800BBAC0

* func_800BC270

* func_800B5208 non matching

* Fix warnings

* meh

* rename some ActorShadow_ functions

* fairy

* Flags_

* fix warnings

* format

* Actor_PickUp and family

* func_800B8E58

* match Actor_RemoveFromCategory

* another bit of docs

* Match func_800B86C8

* And another bit

* rename Player_GetRunSpeedLimit

* func_800B9E84

* func_800BE63C

* func_800BB8EC

* match func_800B5814

* match func_800B9334

* cleanup

* fix conflicts: first pass

* another fix

* actorfixer fix

* fix conflicts

* func_800BE680 non_equivalent

* Improve func_800BE680 a bit

* func_800BE680 equivalent (?)

* func_800BE680 equivalent

* Actor_UpdateActor equivalent

* format

* use some  ExchangeItemID enum values

* Some more cleaning

* more cleanup

* More name stealing from OoT

* match func_800B82EC

* match func_800B9D1C and a bit of cleanup

* Add ACTOR_FLAGS placeholders

* Renames and match func_800BE184

* last pass of name stealing

* format

* fix conflicts

* more cleanup

* more cleanup

* cleanup and OVERLAY_RELOCATION_OFFSET macro

* Remove prototypes of obviously internal-only functions,
update variable names,
forward declare where necessary,
remove all `param_\d`s

* remove newlines

* minor rename

* Use ACTOR_FLAGS in z_actor

* Match func_800BE3D0

* Rename movement functions

* Document Actor_CalcOffsetOrientedToDrawRotation

* velX -> horizontalSpeed

* A bit of documentation for actor movement functions

* format

* Fix merge issues

* format

* Format

* Fix renames

* fix warnings

* fix conflicts

* review :D

* Update src/overlays/actors/ovl_En_Ma4/z_en_ma4.c

Co-authored-by: Derek Hensley <hensley.derek58@gmail.com>

* Fix

* format

* Actor_SpawnSetupActors

* engineer review

* Update src/code/z_actor.c

Co-authored-by: engineer124 <47598039+engineer124@users.noreply.github.com>

* A bunch of Engineer's reviews

* more Engineer's review

* a

* whoops

* run actorfixer

* c'mon

* 😮‍💨

* whoops

* warning

* More engineer's review

* run format

* I'm dumb

* a

* match func_800BE680

* Match Actor_DrawZTarget

* Match Actor_SpawnAsChildAndCutscene, fix non-equivalent in Actor_UpdateActor

* Fix merge issue

* format

* update actor

* Steal a bit of @Thar0 documentation from OoT's z_message

* Run actorfixer

* Fix renames

* Match func_800B4B50 thanks to @hensldm

* Improve ActorShadow_DrawFeet thanks to @hensldm

* whoops

* Actor_PlaySfxAtProjectedPos

* Actor_UpdateActor matched by @hensldm

* Match func_800BA2FC by @hensldm

* Match Actor_SpawnTransitionActors by @hensldm

* Match func_800BB604 by @hensldm

* Match Actor_DrawAll by @hensldm

* ActorShadow_DrawFeet by @hensldm

* Actor_UpdateAll by @hensldm

* Match func_800BCCDC by @engineer124

* Small Actor_PlaySfxAtPos by @engineer124

* ACTOR_FLAGS_ALL and a bit of cleanup

* Add invisible comment

* Small docs pass

* Fix merge

* Engineer's review

* format lol

* Actor_DrawDoorLock docs

* Actor_SpawnShieldParticlesMetal

* fix merge issues

* sActorFaultClient

* fix

* commit message

* Run actorfixer.py && format.sh

* Fix warnings

* fixes

* format

* bss

* Update include/functions.h

Co-authored-by: Derek Hensley <hensley.derek58@gmail.com>

* Address review

* Fix merge issues, format and such

* fix merge issues

* Add ACTORCAT_MAX

* actorList -> actorLists

* Fix merge issues

* format

* Enable WERROR on jenkinsfile

* Fix merge

* Use object symbols

* address review

* format

* review

* fix merge issues

* fix

* VRAM_PTR_SIZE, small cleanup and format

* review

Co-authored-by: Elliptic Ellipsis <elliptic.ellipsis@gmail.com>
Co-authored-by: Derek Hensley <hensley.derek58@gmail.com>
Co-authored-by: engineer124 <47598039+engineer124@users.noreply.github.com>
Co-authored-by: engineer124 <engineer124engineer124@gmail.com>
2022-01-10 12:04:28 -05:00
EllipticEllipsis
d5b71bd0f5
Tutorial (#362)
* ObjTree OK, data imported

* EnMs OK, data imported

* And the spec

* OK

* Some minor edits

* A lot of preliminary stuff

* Mostly complete beginning

* First draft of other functions doc

* Whoops, forgot the GlobalContext pad

* Draw functions (minus colour), create Data

* Data

* gitignore, some progress on documenting

* Review comments, continue documenting

* spec

* Finish off documentation

* undefined_syms

* Add a couple of todos

* One more

* At least add tools for object decomp

* Start conversion table stuff

* Document ObjTree

* Document EnMs

* Add more tables to conversions

* Maide's review

* Review

* Review

* Typos and incomplete thoughts

* Update vscode.md

* Correct function/variable names

* Review suggestions

* Format

* Missed one

* Rename functions and format

* Fix ObjTree

* Update actorfixer.py, fix some variable names

* Some review

* Review suggestions

* More review

* Hopefully fix all the thisx references

* Missed one
2021-12-16 18:47:18 -05:00