Add vtable for ModelRender

This commit is contained in:
Aetias
2024-04-08 23:32:48 +02:00
parent 9ce588a4b8
commit a61011c82f
3 changed files with 29 additions and 2 deletions
+2 -2
View File
@@ -9,6 +9,7 @@
#include "Player/EquipItem.hpp"
#include "System/SysNew.hpp"
#include "System/OverlayManager.hpp"
#include "Render/ModelRender.hpp"
#define MAX_HOURGLASS_SECONDS 1500 // 25 minutes
@@ -143,7 +144,6 @@ enum DungeonItemModelId_ {
DungeonItemModelId_TriangleCrystal, // switch_cstl_t_c
DungeonItemModelId_COUNT,
};
struct ItemModel;
struct SaveItemManager {
/* 00 */ ItemFlags itemFlags;
@@ -202,7 +202,7 @@ private:
/* 0be */ unk8 mUnk_0be[2]; // padding?
/* 0c0 */ ItemModel *mItemModels[ItemModelId_COUNT];
/* 100 */ ItemModel *mDungeonItemModels[DungeonItemModelId_COUNT]; // non-null in dungeons/caves
/* 114 */ void *mUnk_114;
/* 114 */ ModelRender *mUnk_114;
/* 118 */ ItemId mFanfareItem;
/* 11c */ unk32 mUnk_11c;
/* 120 */ void *mFanfareItemModel;
+20
View File
@@ -5,7 +5,10 @@
#include "System/SysNew.hpp"
class ItemModel;
class ModelRender : public SysObject {
public:
/* 00 (vtable) */
/* 04 */ u32 mUnk_04;
/* 08 */ void *mLcdcAddr;
@@ -17,4 +20,21 @@ class ModelRender : public SysObject {
/* 20 */ unk8 mUnk_20[0x38];
/* 58 */ void *mUnk_58;
/* 5c */
/* 00 */ virtual ~ModelRender();
/* 08 */ virtual void* GetLcdcAddress();
/* 0c */ virtual void vfunc_0c(ItemModel *model);
/* 10 */ virtual void SetTransform(Vec3p *scale, Mat3p *rotation, Vec3p *translation);
/* 14 */ virtual void SetRotationTranslation(Mat3p *rotation, Vec3p *translation);
/* 18 */ virtual void SetTranslation(Vec3p *translation);
/* 1c */ virtual void PushGeometryCommands();
/* 20 */ virtual void vfunc_20();
/* 24 */ virtual void vfunc_24(unk32 param1);
/* 28 */ virtual void vfunc_28();
/* 2c */ virtual void vfunc_2c();
/* 30 */ virtual void vfunc_30();
/* 34 */ virtual void vfunc_34();
/* 38 */ virtual void vfunc_38();
/* 3c */ virtual void vfunc_3c();
/* 40 */
};
+7
View File
@@ -28,6 +28,13 @@ typedef struct {
/* 10 */
} Vec4p;
typedef struct {
/* 00 */ Vec3p xColumn;
/* 0c */ Vec3p yColumn;
/* 18 */ Vec3p zColumn;
/* 24 */
} Mat3p;
extern "C" u32 FastDivide(u32 a, u32 b);
extern "C" u32 Divide(u32 a, u32 b);
extern "C" bool Approach(unk32 *src, unk32 dest, unk32 step);