From 85b19de4ab93ac0d36ff7e37a1a130b44c02316a Mon Sep 17 00:00:00 2001 From: Derek Hensley Date: Mon, 11 Jul 2022 20:06:21 -0700 Subject: General Cleanup 4 (#871) * PartTimerWorker -> PartTimer * cleanup * format * objChan draw macro * Fix macro * Fix warning * PR Review * Missed 1 ull * UINT16_MAX * Remove todo from footmark * Remove * from tex in AnimatedMat_DrawTexCycle --- docs/tutorial/documenting.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'docs/tutorial') diff --git a/docs/tutorial/documenting.md b/docs/tutorial/documenting.md index 8268398af..2e98e1efd 100644 --- a/docs/tutorial/documenting.md +++ b/docs/tutorial/documenting.md @@ -420,7 +420,7 @@ This leaves one piece of data unnamed, `D_80C106C8`. This is initially set to `0 What is this doing? We need to understand that to name this variable. -The N64's processors cannot use segmented addresses: they need actual RAM addresses. Therefore the segmented addresses have to be converted before being placed on a segment: this is what `Lib_SegmentedToVirtual` does. So (somewhat unusually) this loop is modifying the addresses in the actor's actual data in RAM. Having converted the addresses once, it wouldn't make any sense to convert them again, but `Init` would run every time an instantiation of the actor is created. Therefore `D_80C106C8` is present to ensure that the addresses only get converted once: it is really a boolean that indicates if the addresses have been converted. So let's call it `texturesDesegmented`, and replace its values by `true` and `false`. +The N64's processors cannot use segmented addresses: they need actual RAM addresses. Therefore the segmented addresses have to be converted before being placed on a segment: this is what `Lib_SegmentedToVirtual` does. So (somewhat unusually) this loop is modifying the addresses in the actor's actual data in RAM. Having converted the addresses once, it wouldn't make any sense to convert them again, but `Init` would run every time an instantiation of the actor is created. Therefore `D_80C106C8` is present to ensure that the addresses only get converted once: it is really a boolean that indicates if the addresses have been converted. So let's call it `sTexturesDesegmented`, and replace its values by `true` and `false`. Finally, clearly `4` is linked to the data over which we're iterating: namely it's the size of the array. We have a macro for this, `ARRAY_COUNT(sEyeTextures)`. -- cgit v1.2.3