summaryrefslogtreecommitdiff
path: root/src/code/z_kankyo.c
AgeCommit message (Collapse)Author
2024-08-08gc-us OK (#2018)cadmic
Match BSS order and delete disassembly data
2024-08-02Automate fixing BSS ordering (#2009)cadmic
* Automate fixing BSS ordering * Typo * Some cleanups * Move pragma check after printing BSS info * Some proofreading * multiprocessing, require version, some colors * Tweak output * Black + mypy * Move logging and sys.exit out of helper functions * Use stdout instead of stderr in fix_bss.py * Add suggestion to conflicting offsets error Co-authored-by: Dragorn421 <Dragorn421@users.noreply.github.com> * Remove var = list[T]() * Improve error handling Co-authored-by: Dragorn421 <Dragorn421@users.noreply.github.com> * Add error if no pointers to BSS * Add comment about process_file_worker * Only print updates if stdout is a tty * Use new binary-search-esque candidate generation algorithm Co-authored-by: Dragorn421 <Dragorn421@users.noreply.github.com> * Add Wikipedia link * More comment tweaks --------- Co-authored-by: Dragorn421 <Dragorn421@users.noreply.github.com>
2024-07-06Set up build system and disassembly for gc-us (#1982)cadmic
* Build gc-us * Set up gc-us disassembly * Don't disasm unchanged overlays * Fix gc-eu-mq BSS * romalign link_animetion for NTSC * Explicitly set CPP defines to 0/1 * Add #ifs to segment_symbols.h * Add sButtonTextures now * Fix message _SHIFTL usage * Don't ifdef LANGUAGE_MAX
2024-06-25Move `PlayState` to a new `z64play.h` (#1966)Anghelo Carvajal
* ActorContext * frameadvance * SfxSource * GameOverContext * RoomContext * TransitionActorContext * fix bss * Move PlayState * Move play functions to new header * SAC_ENABLE * no longer needed * SAC_ENABLE again * z_demo being silly * comment * format headers * fix retail bss * actually fix bss * Cutscene_ProcessScript comment * bss again * Update src/code/z_demo.c Co-authored-by: cadmic <cadmic24@gmail.com> * rename to frame_advance and remove it from z64.h * move macros too * review * Rename SequenceContext to SceneSequences --------- Co-authored-by: cadmic <cadmic24@gmail.com>
2024-06-20Add point lighting gbi features (#1962)Tharo
* Add point lighting gbi features * Maybe fix bss ordering
2024-06-19Experiment: remove global.h dependency from sys_math, sys_math3d, z_lib (#1956)mzxrules
* split sys_math, sys_math3d, z_lib from global.h * suggestions * forgot this * more math stuff * nit fix * re-add ichain.h * resolve tharo's comments
2024-04-14Match retail BSS ordering (#1927)cadmic
* Match retail BSS ordering * Revert moving some global variables to headers * Adjust block numbers after header changes * Fix debug build * Overlay bss ordering * Fix BSS ordering after header changes * gc-eu-mq OK * Implement preprocessor for #pragma increment_block_number * Transfer usage comment from reencode.sh * Use temporary directory instead of temporary file * Move ColChkMassType back
2024-02-08Retail kankyo OK (#1735)engineer124
* only Environment_Update plus 1 fake match * more WIP * remove fake matches * Environment_Update OK * void * add fake comment * better match for update * cleanup * fix fake match * more fixes * add comment
2024-01-31Gamealloc, Graph, and Graphalloc retail OK (#1675)Derek Hensley
* Gamealloc OK * Graph + Graphalloc OK * PR review * gfxalloc * new lines * Remove imposter
2024-01-12Replace most osSyncPrintf calls with PRINTF macro (#1598)cadmic
* Replace most osSyncPrintf calls with PRINTF macro * DEBUG -> OOT_DEBUG
2024-01-09Create debug macros for common functions (#1597)cadmic
* Create debug macros for common functions * Revert NDEBUG change * MALLOCR -> MALLOC_R * DEBUG -> OOT_DEBUG * Use the same name for debug and non-debug matrix functions * Fix file/line argument order * Revert g[s]DPNoOp[Tag] * Use SystemArena_MallocDebug directly in GameAlloc_MallocDebug * MTXF_TO_MTX -> MATRIX_TO_MTX
2023-11-22Misc Cleanup (#1585)engineer124
* misc cleanup * more fake matches * revert for sym
2023-11-19More Camera Flags (#1453)engineer124
* Generic Camera Flags * New flag names * Add flags to functions * Finish flag docs * More docs * More cleanup * More clarity * Better shrinkwindow flag docs * Improve name * CAM_INTERFACE_FLAGS * Better approach to edge cases * Change ordering for consistency * Oops * Add masks to macro * PR/Discord discussions * cleanup comment * Oops * PR Suggestions * More PR Feedback * More PR Suggestions * More Camera Flags * PR Suggestions * More flag style change * Small cleanup * More flag docs * Another flag * Fix flags * sync names with other PRs * more fixes * fix comments * update with hud visibility mode docs * missed one * fix comments * Roman PR Suggestions * interfaceField * small fix * letterbox cleanup * cleanup * fix macro arg * fix func declaration * many more docs * better docs? * missed some * oops, revert * add flags to name * cleanup * flag * double signal * simplify cam func name * more suggestions * PR Suggestion
2023-09-19Doc/Cleanup pass on object handling (#1227)Dragorn421
* `Object_InitBank` -> `Object_InitContext` * Add and use `OBJECT_SPACE_SIZE_BASE` * Remove `OBJECT_EXCHANGE_BANK_MAX` -> use `ARRAY_COUNT()` instead * "object status" -> "object load entry" * Misc. cleanup/renames * Partial docs and way too much batch renaming and cleanup for a single commit * ctrl shift h * format * format clang-11.1 * fix regressions * Improve a `@bug` comment * Move `OBJECT_SPACE_SIZE_BASE` from header to near `Object_InitContext` * "objectID" -> "objectId" * Revert iterator index to `i` in `Actor_KillActorsWithUnloadedObject` * "object load entry index" -> "object entry" * `Object_UpdateLoadEntries` -> `Object_UpdateEntries` * Run format.sh * "object entry" -> "object slot" (except internal usage) * Proper `Object_SpawnPersistent` doc Co-authored-by: fig02 <fig02srl@gmail.com> * fixup one comment "object bank index" -> "object slot" * Amend `Object_SpawnPersistent` comment to mention running out of free slots * `Actor_KillActorsWithUnloadedObject` -> `Actor_KillAllWithMissingObject` * Remove useless mention of what uses `Object_SpawnPersistent` * Fix mistake on `Object_SpawnPersistent` doing sync dma, not async * run formatter * `Object_InitContext` -> `Object_Init` * `waitObjectSlot` -> `requiredObjectSlot` * `Object_Init` -> `func_80097DD8` * one objectIndex -> objectSlot * Remove `OBJECT_SPACE_SIZE_BASE` * light fix on the merge (rm OBJECT_EXCHANGE_BANK_MAX) * `func_80097DD8` -> `Object_InitContext` --------- Co-authored-by: fig02 <fig02srl@gmail.com>
2023-09-06Document pause states (excluding gameover) (#1483)Dragorn421
* Document PauseContext.state * Very light docs surrounding pause states * PAUSE_STATE_UNPAUSE -> PAUSE_STATE_RESUME_GAMEPLAY and comment on purpose in the enum * PAUSE_STATE_MAIN -> PAUSE_STATE_6 * format * Player_InitDrawPause -> Player_InitPauseDrawData
2023-08-15Document z_lib Sfx Functions (#1470)engineer124
* document lib sfx * rename functions
2023-08-13Split `SaveContext` into sub-structs (#1393)Dragorn421
* Split SaveContext struct * run formatter * Remove temporary-until-split stuff in z_sram * . * run formatter
2023-07-05Minor Misc Cleanup 3 (#1502)engineer124
* more misc cleanup * remove z64 conflicts * undo ISVDbg
2023-07-05Reduce hardcoded constants in Lights_GlowCheck, some more comments on the ↵Tharo
CPU driven depth test and z-buffer value conversion (#1506)
2022-12-24z_demo documentation (#1327)fig02
* commit old stuff * progress * progress * progress * progress * more progress, renaming cues next * small changes * enum values added for all actions * hardcoded values removed when possible * commands renamed * first pass of action -> cue * fix some matches * some more cleanup * scriptPtr * forgot one * remove cue rot union * more changes * some more stuff * more stuff * fix matching issues * some more things * progress, starting to rename destinations * small changes * name some destinations * more names * need to switch branch * progress * first pass of destination names * usages fixed * use destination enum * fix csdis * format * command descriptions * revert accidental zap changes * forgot some things * use a single macro for CutsceneCameraPoint (idk why i didnt think of this sooner) * typo * review1 * clarify ruby/sapphire comment * remove endframe for commands that dont use it * some more review * most review, but not all * scriptPtr -> script, and another small change * ocarina action * remove +1 from light settings command, change comment * actionIndex -> cueIdTemp (i guess) * _SetCueX -> _SetXFromCue * format * tweak fade out seq arg names * use spline terminology * more dragorn and engineer review * misc start/end frame note * cleanup StartPosRotFromCue vs PosRotFromCue * cleanup spline terminology * sPrevCamId -> sReturnToCamId * comment on debug cs data address * Cutscene_Init -> Cutscene_InitContext * single point types are not a list * remove todo comment * some more review * rumble struct names * some review * more review * missed one * reword pointer comment * even more review * match transition terminology with z_play * change condition and format * frame count * command specific structs with alignment * anon review * remove unneeded arg from time macro * yeet `CsCmdGeneric` * remove unused from single point types * typo * compromise attempt -- name endFrame everywhere * fixes * fix again * copied the wrong note * cutscene data note * review, format * compat defines * idk whats going on man Co-authored-by: Dragorn421 <Dragorn421@users.noreply.github.com>
2022-12-04Camera Flags (#1225)engineer124
* Generic Camera Flags * New flag names * Add flags to functions * Finish flag docs * More docs * More cleanup * More clarity * Better shrinkwindow flag docs * Improve name * CAM_INTERFACE_FLAGS * Better approach to edge cases * Change ordering for consistency * Oops * Add masks to macro * PR/Discord discussions * cleanup comment * Oops * PR Suggestions * More PR Feedback * More PR Suggestions * PR Suggestions * More flag style change * Small cleanup * sync names with other PRs * more fixes * fix comments * update with hud visibility mode docs * missed one * fix comments * Roman PR Suggestions * interfaceField * small fix * letterbox cleanup * fix macro arg * fix func declaration
2022-11-26Name scenes (scene enum, entrance enum, various identifiers) (#1343)Dragorn421
* Comment names on titled scenes * Comment some more scene names * Comment some map assets symbol prefixes * Name collapse sequence scenes (from the non-collapse equivalent scene's name + `_COLLAPSE`) * Name ganon/ganondorf boss scenes (symbol prefix suffixed with `Scene` to prevent confusion with boss actors) * Fix symbol prefix for back alley night scene * Name the two grave scenes (normal and fairy's fountain variant) * Name most houses, name/update misc scenes Co-authored-by: fig02 <fig02srl@gmail.com> * (hakaana) `GRAVE` -> `REDEAD_GRAVE` to be more specific Co-authored-by: fig02 <fig02srl@gmail.com> * `miharigoya_scene`: `market_guard_house` * `kakariko_scene` -> `kakariko_center_house` * `richards_house` -> `dog_lady_house` (for localization differences) * Revert "Comment some map assets symbol prefixes" This reverts commit 210a38a6288d5d2fa318059f31988ca7ceb5c708. * remove other xml prefixes * ganon_boss, ganondorf_boss * comments to namefixer * `KAKARIKO_CENTER_HOUSE` -> `KAKARIKO_CENTER_GUEST_HOUSE` * two collapse sequence scenes -> `GANONS_TOWER_COLLAPSE_`interior/exterior * Run namefixer `find src include -type f -exec ./tools/namefixer.py {} \;` * run formatter Co-authored-by: fig02 <fig02srl@gmail.com>
2022-11-16More documentation for `z_std_dma.c` (#1415)Tharo
* More documentation for z_std_dma * uintptr casts for rom symbols in z64animation.h and z_kanfont.c * Format * Suggested changes, more defines for static texture sizes * PI Interface -> PI * Further suggested changes * Format * Comments about item_name and map_name texture assumptions
2022-11-01Rename `vt.h` to `terminal.h` (#1339)Dragorn421
* `vt.h` -> `terminal.h` * `VT_` -> `T_` (as in Terminal) * `vt.h` -> `terminal.h` in includes too Pepega * Sort out tiny terminal.h include inconsistencies * Format * -> `TE_` * format * `TE_` -> back to `VT_` (parkour!) * explicit VT
2022-11-01Some doc on env light settings (#1307)Dragorn421
* remove `LightSettings` struct, typedef for zapd * more decimal * fog far -> z far * `LIGHTCTX_FOGNEAR_MAX`, `LIGHTCTX_ZFAR_MAX` * name sp88,sp8C in `Environment_Update` * `EnvLightSettings.fogNear` -> `blendRateAndFogNear` and macros * A different struct for `EnvironmentContext.lightSettings` * Uniform zapd compat typedefs todos * `LIGHTCTX_` -> `ENV_` * Comment on `blendRateAndFogNear` + "fogFar" * Move fogFar~1000 comment to zFar * comment rewrite attempt * move relevant macros down Co-authored-by: fig02 <fig02srl@gmail.com>
2022-10-29Doc speed_meter timers and misc. low-ish level stuff (#1364)Dragorn421
* Misc docs (somewhat lower level) * Run formatter * Simplify comment * `a = a +` -> `a +=` with pad removal Co-authored-by: Roman971 <32455037+Roman971@users.noreply.github.com> * `isPreNMIStateRunning` -> `inPreNMIState` * line breaks Co-authored-by: Roman971 <32455037+Roman971@users.noreply.github.com> Co-authored-by: fig02 <fig02srl@gmail.com>
2022-10-09Document Scene Sequences and Remaining SeqFlags (#1308)engineer124
* Begin scene sequence docs * Better docs * cleanup * Better Docs * cleanup * Move flag * Off -> None * Fix comment * spacing * address pr, spot -> resumePoint * SEQ_IO_VAL_NONE * missed one
2022-10-07Document code_800F9280.c -> audio_seqcmd.c i.e. (Audio_QueueSeqCmd) (#1234)engineer124
* Document SoundSources * PR Suggestions * Duration timers to dec * `PlaySfxByPosAndId` -> `PlaySoundByPosition` * Begin importing docs from MM * Finish cleanup using code from MM * Start documenting commands * First attempt at thorough AudioSeqCmd wrappers * Improve names * Merge branch 'master' into audio_seqCmd fix name to minimize conflicts * Combine macros, implement them through repo * Improve docs * More progress, begin sequence command docs * seqcmd.h * More documentation of seqcmd.h * More docs * cleanup * More cleanup * More docs * VOL_SCALE_INDEX enum * missed enums * More Cleanup * docs * More docs * Add comments about sfxChannelLayout * More cleanup * Even better docs * Add a file description * small touchups * More cleanup of comments * more * More cleanup * More cleanup * Missing space * typos * Audio_SetVolumeScaleNow * More cleanup * Fill in enum * one more cleanup * Capitalize macros * remove AUDIO_ * cleanup * more cleanup * Small Fix * Add a lot of backticks for docs * Restructuring docs * More cleanup * swap channel args, cleanup * Typos * Many suggestions, revert filename * pr suggestions * even more PR * more pr suggestions * pr suggestion
2022-09-27Rumble doc (#1375)Tharo
* Rumble doc * Fixes, suggested changes * Improve padmgr retrace callback related code * Name some rumble-adjacent things, further suggested changes * Further suggested changes * Suggested changes
2022-08-29Doc pass on bgcheck-waterbox properties (#1288)Dragorn421
* Doc pass on bgcheck-waterbox properties * `WATERBOX_ROOM_INDEX...` -> `WATERBOX_ROOM...` * Fix `WATERBOX_PROPERTIES` macro (was completely wrong) * `((setFlag19) & 1) << WATERBOX_FLAG_19_SHIFT` instead of ternary * Fix `WATERBOX_PROPERTIES` macro (hopefully for good)
2022-07-31sceneNum -> sceneId (#1338)Derek Hensley
* sceneNum -> sceneId * forgot to save play * scene -> sceneId where appropriate * Missed 1 + format * Update src/code/z_sram.c Co-authored-by: mzxrules <mzxrules@gmail.com> * Update src/code/z_sram.c Co-authored-by: mzxrules <mzxrules@gmail.com> * PR * Fix Co-authored-by: mzxrules <mzxrules@gmail.com>
2022-07-30Fix various small gfx issues (#1313)Tharo
* Fix various small gfx issues * Use 0xFFFF instead of -1 for max prim depth * More fixed point numbers * scale -> texCoordScale, better cycle 2 render mode in z_title * GFXP_CHAR_* defines renamed to SPACING * Fix some gDPLoadMultiBlock uses
2022-07-30Rename "Scene Setup Index" to "Scene Layer" (#1300)fig02
* setup -> layer * IS_CUTSCENE_LAYER * review * backtick * remove some more mentions of setup * alt header block * clarifying comment
2022-06-24Fix misc 15 (#1298)Dragorn421
* Use `SCENE_` enum more * Decimal for pos in `D_8011F9B8` * `__osEventStateTab`: length `OS_NUM_EVENTS + 1` -> `OS_NUM_EVENTS` * thone -> throne * `s` on local data * minor sfxId cleanup * Run formatter * Fixup 0x19 + 1 = 0x1A, not 0x20 lol * Tlut -> TLUT * DemoKankyo params usage cleanup * Some proofreading (up to z_actor.c) * Revert 0 -> sfxId, add todo comment (sfxId=0 is weird apparently) * `sZdWaterBox` -> `sZorasDomainWaterBox` * `msgMode == MSGMODE_`, not `GAMEMODE_` (my bad Sadge)
2022-06-23Document `SaveContext.gameMode` (#1295)Dragorn421
* Document `SaveContext.gameMode` * end credits * Remove no longer needed comment
2022-06-20Document Viewpoints and Scene Cam Types (#1285)engineer124
* Document bgCamData * More changes and cleanup * More docs * Clarify comments * PR Feedback, rename bgcheck functions * remove fallthrough cleanup (other pr that deals with that) * PR Suggestions * bug report * bgCamDataIndexBeforeUnderwater * PR/Discord Discussions * Missed some * sync function header args * Another suggestion * cleanup * Comments * Indoor BgCamData * Change bgCamData to s16 for now * PR suggestions * the * use "info" * Missed a suggestion * Update and sync docs * More docs * Even more docs * Revert macro * Add comment * Better comments * More cleanup * Better Cam Scene Docs * Small change * Market -> Pivot * "only" * swap * Better comment * Another comment * to * Implement suggestions from discord * Discord Discussion * Revert bgCamFuncData to Vec3s * cleanup * Remaining cleanup * docs cleanup * format * More docs * Improve notes * Cleanup * Change enum * PR Suggestions * Improve comment * Rephrase * Implement discussion from discord * Discord discussion * fixed to locked * Update comments * Few more comments * Update include/z64.h Co-authored-by: Dragorn421 <Dragorn421@users.noreply.github.com> * Update include/z64camera.h Co-authored-by: Dragorn421 <Dragorn421@users.noreply.github.com> * Better comments * PR Suggestions * rm numbers * Update src/code/z_play.c Co-authored-by: Dragorn421 <Dragorn421@users.noreply.github.com> Co-authored-by: Dragorn421 <Dragorn421@users.noreply.github.com>
2022-06-11Minor cleanups in z_std_dma.c and yaz0.c (#1269)Roman971
* Cleanup dma and yaz0 functions using pointers for ram Also includes a minor cleanup of yaz0 names to better fit their purpose * Run formatter * Additional cleanups on dma and yaz0 functions
2022-06-06Fix asset file includes to always start with assets/ (#1260)Roman971
* Fix asset includes to consistently start with assets/ * Fix header paths in asset xmls to start with assets/ * Remove -Iassets from compiler options
2022-06-03Add enum for setup dls and name `z_rcp.c` functions (#1196)Dragorn421
* Introduce `SetupDL` enum * wip * wip * Remove comments on each setupdl index * Name setup dl functions by setupdl index * `Gfx_SetupDl` -> `Gfx_SetupDL` * Run formatter * globalctx -> play * fix regressions * `Gfx_SetupDL` -> `Gfx_SetupDL_` (add separating underscore) * `CallSetupDL` -> `SetupDL`
2022-05-21PlayState Rename (#1231)fig02
* global context -> play * fix PlayState* PlayState
2022-05-21Documentation pass on scene/room commands (#1226)Dragorn421
* Rename handler functions * Rename cmd_id enum names for consistency * `char` -> `s8` for explicit padding in cmd structs * `Room.unk03/03` -> `behaviorType2/1` * `UNK_PTR` -> `void*` * `showInvisActors` -> `lensActorsMode` + enum * Add `ROOM_BEHAVIOR_TYPE1/2_` enums * "mesh" -> "mesh header" * `Polygon polygon` -> `PolygonBase base` (for now...) * Misc cleanup * "lens actors mode" -> "lens actor mode" * Revert "`char` -> `s8` for explicit padding in cmd structs" This reverts commit 59b9295828d0fa341b0f05fbe9d660adb04476aa. * `LENS_ACTOR_MODE_` -> `LENS_MODE_HIDE/SHOW_ACTORS`
2022-05-20Environment documentation pass (#1115)fig02
* some docs, start introducing time macro * most usages of CLOCK_TIME * finish up clock time defines, format * saving incase i need to revert * more docs * more docs progress * some more docs * format with 11 * change sos to storm * update functions.h * some depth stuff * review 1 and 2 * whoops * update zbuf stuff * most of review 3 * enum name * storm state enum * review 4 * fix enum * add comment to skyboxischanging * review * things dont match, committing so i can change branches * revert struct changes * define for override_full_control * new clock_time macro * fill alpha -> glare strength * update comment * remove indoor/outdoor, new name for underwater light variable * remove copy pasted comment * fix comments * remove whitespave * review
2022-05-15Fix misc 12 (#1222)Dragorn421
* (light) `src` to `src/code/code_8006C510.c` * `setup + entrance` -> `entrance + setup` * Decimal for `gdSPDefLights1` args (colors, unit vector) * Run formatter * `firstDone` bool -> `materialFlag` * `ENTR_MAX`: 0x613 -> 0x614 * revert `materialFlag` to bool++ for now
2022-05-09Introduce DEFINE_ENTRANCE for entrance table and create entrance enum (#1213)fig02
* entrance table OK * entrance enum fixed * most entrances using enum, still need to do conditionals * more entrances * entrance_table.h cleanups * some review * remove _0 from first entrance in a group of setups * change table description * typo * wens spellcheck in vscode * remove extra line
2022-04-29Defines for `SaveContext` flags (`eventChkInf`, `itemGetInf`, `infTable`, ↵Dragorn421
`eventInf`) (#1094) * script-assisted `itemGetInf` flags * comment near non-trivial `itemGetInf` usage * Run formatter * Try something with the itemgetinf flags that can't use the packed value * Add defines for `eventChkInf` (direct access) * Add defines for `eventChkInf` (access through `Flags_GetEventChkInf`) * Add defines for `eventChkInf` (access through `Flags_SetEventChkInf`) * Add defines for `infTable` (direct access) * Add defines for `infTable` (used by `Flags_GetInfTable`) * Add defines for `infTable` (used by `Flags_SetInfTable`) * Add defines for `eventInf` * parenthesis cleanup near `GET_EVENTCHKINF` usage * parenthesis cleanup near `GET_ITEMGETINF` usage * parenthesis cleanup near `GET_INFTABLE` usage * fixup one `eventInf` usage * parenthesis cleanup near `GET_EVENTINF` usage * parenthesis cleanup near `Flags_GetEventChkInf` usage * slight `z64save.h` formatting improvement * Improve itemGetInf flags in z_bg_dy_yoseizo * Questionable improvement in z_en_ge2 * Questionable improvement in z_en_daiku * Questionable improvement in z_en_mu * Run formatter * Parentheses around `gSaveContext` macros arguments * Move individual flags define to the end of z64save.h, and improve comments separating the groups
2022-04-27Document Transition System (#1131)fig02
* transition type enum * mode enum, start documenting some types * some more * use enums for entrance table * entrance table filled out * sceneLoadFlag -> transitionTrigger * sandstorm state/mode/type * done i think * fixes * clean up circle weirdness * circle use enum + fix texture names * fix * how did that even happen lol * jesus * review2 * some more review * most review, still some more to do * new transition trigger names * some of review * next type default
2022-04-08Message Queues, Threads, and surroundings cleanup (#1178)Tharo
* message queues, threads, and surroundings cleanup * Format, make the formatter prefer clang-format-11 if found * Fix __osThreadTail type * Q -> Queue, thread defines renamed * Reformat, add missing NULL * Suggested changes and further casting cleanup * Reformat * padmgr name fixes
2022-04-09Names for some view things (#1191)Robin Allen
* Names for some view things * Review: ORTHOGRAPHIC → ORTHO * Review: dirty → dirtyFlags * Review: Doc comment style * Review: Define constants in terms of each other * Review: Rename the ApplyToOverlay functions * Update include/z64.h Co-authored-by: fig02 <fig02srl@gmail.com> * Review: Better View_LookAtInternal doc * arg1 → mask * View_LookAtInternal → View_LookAtUnsafe * Review: View_SanityCheckEyePosition → View_ErrorCheckEyePosition * sViewNotInitialized → sLogOnNextViewInit * Remove VIEW_FORCE_ALL * near/far → zNear/zFar Co-authored-by: engineer124 <47598039+engineer124@users.noreply.github.com> * lookAt → at Co-authored-by: engineer124 <47598039+engineer124@users.noreply.github.com> * near/far → zNear/zFar * View_ApplyPerspective/Ortho: Remove from header instead of commenting * lookAt → at * Add fwd decls * Fix external view->at accesses * Missed these somehow * lookAt → at * Omit "Apply" in comments * dirtyFlags → flags * View_ApplyScissor → View_ApplyShrinkWindow * Update src/code/z_view.c Co-authored-by: Dragorn421 <Dragorn421@users.noreply.github.com> Co-authored-by: fig02 <fig02srl@gmail.com> Co-authored-by: engineer124 <47598039+engineer124@users.noreply.github.com> Co-authored-by: Dragorn421 <Dragorn421@users.noreply.github.com>
2022-03-20Angle cleanup - `DEG_TO_RAD` (#1157)Dragorn421
* Run formatter * Touch up angle macros (parentheses and hex constants) * Remove `DEGF_TO_RADF`, use `DEG_TO_RAD` instead * Remove `DEGTORAD`, use `DEG_TO_RAD` instead * Use `DEG_TO_RAD` more
2022-03-16Fix misc 8 (#1150)Dragorn421
* Use `s32` as type instead of `StackStatus` enum type * `bossLimbDl` -> `bossLimbDL` * Fixup comment refering to `Actor.velocity` by struct offset * Fixup `feetFloorFlags` doc and -> `feetFloorFlag` * Fixup `xyzDistToPlayerSq` comment * Make `SkelAnime.mode` comment refer to `AnimationMode` (<- `AnimationModes`) * Use enum names to refer to anim modes and break long lines in z64animation.h * `EnDha_OverridePostDraw` -> `EnDha_PostLimbDraw` * ichains cleanup * Scene command ids usage cleanup * Properly name unkXXX members as unk_XXX * change `gSceneCmdHandlers` length in variables.h too * Revert Unknown flags to unk0 & unk1 * Remove "current scene" mention from `Flags_*Unknown` as they aren't saved or loaded so not scene-specific * `Struct_8011FAF0`: unk_00, unk_04 * Run formatter * Do not break long lines in headers * Revert "Fixup `feetFloorFlags` doc and -> `feetFloorFlag`" This reverts commit c45b3611e7c8997d27807cfd1c9e1fbdaeb026fe.