mirror of
https://github.com/zeldaret/oot
synced 2026-07-09 14:45:41 -04:00
Fix misc 8 (#1150)
* 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 c45b3611e7.
This commit is contained in:
+1
-1
@@ -59,7 +59,7 @@ void Mio0_Decompress(Yaz0Header* hdr, u8* dst);
|
||||
void StackCheck_Init(StackEntry* entry, void* stackTop, void* stackBottom, u32 initValue, s32 minSpace,
|
||||
const char* name);
|
||||
void StackCheck_Cleanup(StackEntry* entry);
|
||||
StackStatus StackCheck_GetState(StackEntry* entry);
|
||||
s32 StackCheck_GetState(StackEntry* entry);
|
||||
u32 StackCheck_CheckAll(void);
|
||||
u32 StackCheck_Check(StackEntry* entry);
|
||||
f32 LogUtils_CheckFloatRange(const char* exp, s32 line, const char* valueName, f32 value, const char* minName, f32 min,
|
||||
|
||||
+1
-1
@@ -96,7 +96,7 @@ extern u32 gGsFlagsMasks[4];
|
||||
extern u32 gGsFlagsShifts[4];
|
||||
extern void* gItemIcons[0x82];
|
||||
extern u8 gItemSlots[56];
|
||||
extern void (*gSceneCmdHandlers[26])(GlobalContext*, SceneCmd*);
|
||||
extern void (*gSceneCmdHandlers[SCENE_CMD_ID_MAX])(GlobalContext*, SceneCmd*);
|
||||
extern s16 gLinkObjectIds[2];
|
||||
extern u32 gObjectTableSize;
|
||||
extern RomFile gObjectTable[OBJECT_ID_MAX];
|
||||
|
||||
+2
-2
@@ -77,7 +77,7 @@ typedef struct {
|
||||
|
||||
typedef struct {
|
||||
/* 0x00 */ DamageTable* damageTable;
|
||||
/* 0x04 */ Vec3f displacement; // Amount to correct velocity (0x5C) by when colliding into a body
|
||||
/* 0x04 */ Vec3f displacement; // Amount to correct actor velocity by when colliding into a body
|
||||
/* 0x10 */ s16 cylRadius; // Used for various purposes
|
||||
/* 0x12 */ s16 cylHeight; // Used for various purposes
|
||||
/* 0x14 */ s16 cylYShift; // Unused. Purpose inferred from Cylinder16 and CollisionCheck_CylSideVsLineSeg
|
||||
@@ -167,7 +167,7 @@ typedef struct Actor {
|
||||
/* 0x084 */ f32 yDistToWater; // Distance to the surface of active waterbox. Negative value means above water
|
||||
/* 0x088 */ u16 bgCheckFlags; // Flags indicating how the actor is interacting with collision
|
||||
/* 0x08A */ s16 yawTowardsPlayer; // Y rotation difference between the actor and the player
|
||||
/* 0x08C */ f32 xyzDistToPlayerSq; // Squared distance between the actor and the player in the x,y,z axis
|
||||
/* 0x08C */ f32 xyzDistToPlayerSq; // Squared distance between the actor and the player
|
||||
/* 0x090 */ f32 xzDistToPlayer; // Distance between the actor and the player in the XZ plane
|
||||
/* 0x094 */ f32 yDistToPlayer; // Dist is negative if the actor is above the player
|
||||
/* 0x098 */ CollisionCheckInfo colChkInfo; // Variables related to the Collision Check system
|
||||
|
||||
@@ -23,7 +23,7 @@ typedef enum {
|
||||
/* 3 */ ANIMMODE_ONCE_INTERP,
|
||||
/* 4 */ ANIMMODE_LOOP_PARTIAL,
|
||||
/* 5 */ ANIMMODE_LOOP_PARTIAL_INTERP
|
||||
} AnimationModes;
|
||||
} AnimationMode;
|
||||
|
||||
typedef enum {
|
||||
/* -1 */ ANIMTAPER_DECEL = -1,
|
||||
@@ -241,21 +241,21 @@ typedef s32 (*AnimUpdateFunc)();
|
||||
|
||||
typedef struct SkelAnime {
|
||||
/* 0x00 */ u8 limbCount; // Number of limbs in the skeleton
|
||||
/* 0x01 */ u8 mode; // 0: loop, 2: play once, 4: partial loop. +1 to interpolate between frames.
|
||||
/* 0x01 */ u8 mode; // See `AnimationMode`
|
||||
/* 0x02 */ u8 dListCount; // Number of display lists in a flexible skeleton
|
||||
/* 0x03 */ s8 taper; // Tapering to use when morphing between animations. Only used by Door_Warp1.
|
||||
/* 0x04 */ void** skeleton; // An array of pointers to limbs. Can be StandardLimb, LodLimb, or SkinLimb.
|
||||
/* 0x08 */ void* animation; // Can be an AnimationHeader or LinkAnimationHeader.
|
||||
/* 0x0C */ f32 startFrame; // In mode 4, start of partial loop.
|
||||
/* 0x10 */ f32 endFrame; // In mode 2, Update returns true when curFrame is equal to this. In mode 4, end of partial loop.
|
||||
/* 0x14 */ f32 animLength; // Total number of frames in the current animation's file.
|
||||
/* 0x0C */ f32 startFrame; // In mode ANIMMODE_LOOP_PARTIAL*, start of partial loop.
|
||||
/* 0x10 */ f32 endFrame; // In mode ANIMMODE_ONCE*, Update returns true when curFrame is equal to this. In mode ANIMMODE_LOOP_PARTIAL*, end of partial loop.
|
||||
/* 0x14 */ f32 animLength; // Total number of frames in the current animation.
|
||||
/* 0x18 */ f32 curFrame; // Current frame in the animation
|
||||
/* 0x1C */ f32 playSpeed; // Multiplied by R_UPDATE_RATE / 3 to get the animation's frame rate.
|
||||
/* 0x20 */ Vec3s* jointTable; // Current translation of model and rotations of all limbs
|
||||
/* 0x24 */ Vec3s* morphTable; // Table of values used to morph between animations
|
||||
/* 0x28 */ f32 morphWeight; // Weight of the current animation morph as a fraction in [0,1]
|
||||
/* 0x2C */ f32 morphRate; // Reciprocal of the number of frames in the morph
|
||||
/* 0x30 */ s32 (*update)(); // Can be Loop, Partial loop, Play once, Morph, or Tapered morph. Link only has Loop, Play once, and Morph
|
||||
/* 0x30 */ s32 (*update)(); // Can be Loop, Partial loop, Play once, Morph, or Tapered morph. Link only has Loop, Play once, and Morph.
|
||||
/* 0x34 */ s8 initFlags; // Flags used when initializing Link's skeleton
|
||||
/* 0x35 */ u8 moveFlags; // Flags used for animations that move the actor in worldspace.
|
||||
/* 0x36 */ s16 prevRot; // Previous rotation in worldspace.
|
||||
|
||||
+2
-1
@@ -339,7 +339,8 @@ typedef enum {
|
||||
/* 0x16 */ SCENE_CMD_ID_ECHO_SETTINGS,
|
||||
/* 0x17 */ SCENE_CMD_ID_CUTSCENE_DATA,
|
||||
/* 0x18 */ SCENE_CMD_ID_ALTERNATE_HEADER_LIST,
|
||||
/* 0x19 */ SCENE_CMD_ID_MISC_SETTINGS
|
||||
/* 0x19 */ SCENE_CMD_ID_MISC_SETTINGS,
|
||||
/* 0x20 */ SCENE_CMD_ID_MAX
|
||||
} SceneCommandTypeID;
|
||||
|
||||
#define SCENE_CMD_SPAWN_LIST(numSpawns, spawnList) \
|
||||
|
||||
Reference in New Issue
Block a user