Files
bigmak94andClaude Opus 5.5 4b395efe5c Add the Petari decompilation (SMGCommunity/Petari@0a5c660)
The sources of Petari (https://github.com/SMGCommunity/Petari), the
Super Mario Galaxy decompilation by the SMGCommunity, at commit
0a5c6608dc3b4c44a9aa68c2535d1793dc565f02, unchanged but for LF line
endings: LICENSE (as LICENSE-Petari.txt; CC0 1.0), include/, libs/ and
src/.  Left out: the game data Petari keeps from the original
executable, the error message archive (include/Game/System/
ErrorArchive.hpp) and two tables (src/Game/System/GalaxyID.bcsv and
StoryEvent.bcsv); GalaxyQuest's converter takes them from the player's
own disc.  The port's changes follow in the next commit, so
`git diff petari-base -- decomp` shows them.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-01 01:59:38 +02:00

83 lines
1.9 KiB
C++

#pragma once
#include <JSystem/JGeometry.hpp>
#include <revolution.h>
class LiveActor;
class JointController;
struct JointControllerInfo;
class JointCtrlRate {
public:
JointCtrlRate();
void update();
void startCtrl(s32);
void endCtrl(s32);
/* 0x00 */ f32 _0;
/* 0x04 */ s32 _4;
/* 0x08 */ s32 _8;
/* 0x0C */ s32 _C;
};
struct DynamicJointCtrlParam {
/* 0x00 */ f32 mGravity;
/* 0x04 */ f32 mFriction;
/* 0x08 */ f32 mAccelRatetoBckPos;
/* 0x0C */ f32 mBendMaxDegree;
/* 0x10 */ s32 mCtrlJointNumMax;
};
class DynamicJointCtrlNode;
class DynamicJointCtrl {
public:
DynamicJointCtrl(LiveActor*, const char*, const DynamicJointCtrlParam*);
void init();
void update();
void reset();
void setCallBackFunction();
/* 0x00 */ LiveActor* mActor;
/* 0x04 */ const char* mName;
/* 0x08 */ s32 _8;
/* 0x0C */ DynamicJointCtrlNode** mCtrlNodes;
/* 0x10 */ const DynamicJointCtrlParam* mParams;
/* 0x14 */ JointCtrlRate* mControlRate;
};
class DynamicJointCtrlNode {
public:
DynamicJointCtrlNode(const DynamicJointCtrl*, MtxPtr, f32);
void update(LiveActor*, const DynamicJointCtrlNode*);
void reset();
bool updateJointMtxCallBack(TPos3f*, const JointControllerInfo&);
/* 0x00 */ f32 _0;
/* 0x04 */ TVec3f _4;
/* 0x10 */ TVec3f _10;
/* 0x1C */ TVec3f _1C;
/* 0x28 */ MtxPtr _28;
/* 0x2C */ JointController* mJointController;
/* 0x30 */ DynamicJointCtrlNode* mChild;
/* 0x34 */ const DynamicJointCtrl* mParentControl;
};
class DynamicJointCtrlKeeper {
public:
DynamicJointCtrlKeeper(LiveActor*);
void update();
void setCallBackFunction();
void startCtrl(const char*, s32);
void endCtrl(const char*, s32);
void reset();
DynamicJointCtrl* findJointCtrl(const char*);
/* 0x00 */ LiveActor* mActor;
/* 0x04 */ s32 _4;
/* 0x08 */ DynamicJointCtrl** mControls;
};