Nearly match DispObject

temp_parent and temp_cluster are swapped in stack allocation order
This commit is contained in:
gamemasterplc 2023-12-04 10:23:10 -06:00
parent afac7f1f7b
commit 1574109c8e
3 changed files with 363 additions and 8 deletions

View file

@ -67,8 +67,8 @@ typedef struct hsf_bitmap {
typedef struct hsf_palette {
char *name;
int unk;
int palSize;
s32 unk;
s32 palSize;
void *data;
} HsfPalette;
@ -161,17 +161,23 @@ typedef struct hsf_object_data {
struct hsf_object **children;
HsfTransform base;
HsfTransform curr;
Vec min;
Vec max;
u8 unk[136];
union {
struct {
HsfVector3f min;
HsfVector3f max;
u8 unk[136];
} mesh;
struct hsf_object *unk64;
};
HsfBuffer *face;
HsfBuffer *vertex;
HsfBuffer *normal;
HsfBuffer *st;
HsfBuffer *color;
HsfBuffer *st;
HsfMaterial *material;
HsfAttribute *attribute;
u8 unk2[12];
u8 unk2[4];
u32 vertexShapeCnt;
HsfBuffer **vertexShape;
u32 clusterCnt;

18
include/string.h Normal file
View file

@ -0,0 +1,18 @@
#ifndef _STRING_H_
#define _STRING_H_
typedef unsigned long size_t;
void* memcpy(void* dst, const void* src, size_t n);
void* memset(void* dst, int val, size_t n);
char* strrchr(const char* str, int c);
char* strchr(const char* str, int c);
int strncmp(const char* str1, const char* str2, size_t n);
int strcmp(const char* str1, const char* str2);
char* strcat(char* dst, const char* src);
char* strncpy(char* dst, const char* src, size_t n);
char* strcpy(char* dst, const char* src);
size_t strlen(const char* str);
#endif