Remove wrong palette label

This commit is contained in:
DizzyEggg
2025-03-20 15:01:35 +01:00
parent 9c9182b78d
commit 76fc258b2a
3 changed files with 14 additions and 14 deletions

View File

@@ -64,7 +64,7 @@ typedef struct axdata
/* 0x8 */ axdata1 sub1;
/* 0x28 */ ax_anim *nextAnimData; // next animation data (if flags&0x1000)
/* 0x2C */ ax_anim *activeAnimData; // current animation data
/* 0x30 */ void *paletteData; // ?
/* 0x30 */ DungeonPos *positions;
/* 0x34 */ ax_pose **poseData;
/* 0x38 */ UnkSpriteMem **spriteData;
} axdata;
@@ -75,8 +75,8 @@ typedef struct axmain
/* 0x0 */ ax_pose **poses;
/* 0x4 */ ax_anim ***animations;
/* 0x8 */ u32 animCount;
/* 0xC */ void *spriteData; // ?
/* 0x10 */ void *palettes; // ?
/* 0xC */ UnkSpriteMem **spriteData;
/* 0x10 */ DungeonPos *positions;
} axmain;
// size: 0x4C

View File

@@ -74,10 +74,10 @@ void sub_800569C(DungeonPos *a0, struct axObject *a1, u8 a2)
if (!(a1->axdata.flags >> 15) || a2 >= 4)
return;
if (a1->axdata.paletteData != NULL) {
ptr = &((DungeonPos*)a1->axdata.paletteData)[a1->axdata.sub1.poseId * 4];
if (a1->axdata.positions != NULL) {
ptr = &(a1->axdata.positions)[a1->axdata.sub1.poseId * 4];
ptr2 = &ptr[a2];
if (*&ptr2->x == 99 && *&ptr2->y == 99) {
if (*&ptr2->x == 99 && ptr2->y == 99) {
a0->x = 99;
a0->y = 99;
}
@@ -96,21 +96,21 @@ void sub_800569C(DungeonPos *a0, struct axObject *a1, u8 a2)
void sub_8005700(DungeonPos *a0, struct axObject *a1)
{
s32 i;
DungeonPos *ptr;
if (!(a1->axdata.flags >> 15))
return;
if (a1->axdata.paletteData != NULL) {
ptr = &((DungeonPos*)a1->axdata.paletteData)[a1->axdata.sub1.poseId * 4];
if (a1->axdata.positions != NULL) {
DungeonPos *positions = &(a1->axdata.positions)[a1->axdata.sub1.poseId * 4];
for (i = 0; i < 4; i++) {
if (*&ptr[i].x == 99 && *&ptr[i].y == 99) {
s32 x = positions[i].x;
if (x == 99 && positions[i].y == 99) {
a0->x = 99;
a0->y = 99;
}
else {
a0->x = a1->axdata.sub1.offset.x + ptr[i].x;
a0->y = a1->axdata.sub1.offset.y + ptr[i].y;
a0->x = a1->axdata.sub1.offset.x + positions[i].x;
a0->y = a1->axdata.sub1.offset.y + positions[i].y;
}
a0++;
}

View File

@@ -487,7 +487,7 @@ void AxResInit(axdata *a0, axmain *a1, u32 a2, u32 direction, u32 a4, u32 sprite
a0->activeAnimData = a0->nextAnimData;
a0->poseData = a1->poses;
a0->spriteData = a1->spriteData;
a0->paletteData = a1->palettes;
a0->positions = a1->positions;
}
void AxResInitUnorientedFile(axdata *a0, OpenedFile *a1, u32 a2, u32 a3, u32 spriteAnimIndex, bool8 a5)
@@ -514,7 +514,7 @@ static void AxResInitUnoriented(axdata *a0, axmain *a1, u32 a2, u32 a3, u32 spri
a0->nextAnimData = a1->animations[a2][0];
a0->activeAnimData = a0->nextAnimData;
a0->poseData = a1->poses;
a0->paletteData = 0;
a0->positions = NULL;
}
static inline s16 check_flag_for_80054BC(u16 flags) {