mirror of
https://github.com/PodeCaradox/GalaxyQuest-SteamFrame.git
synced 2026-10-18 18:02:04 +02:00
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>
104 lines
3.4 KiB
C++
104 lines
3.4 KiB
C++
#pragma once
|
|
|
|
#include "Game/System/NerveExecutor.hpp"
|
|
#include <JSystem/JGeometry/TVec.hpp>
|
|
|
|
class JMapInfoIter;
|
|
class LiveActor;
|
|
class ModelObj;
|
|
class NPCActor;
|
|
class NPCActorItem;
|
|
class PartsModel;
|
|
class TalkMessageCtrl;
|
|
|
|
namespace MR {
|
|
bool getNPCItemData(NPCActorItem*, s32);
|
|
bool isNPCItemFileExist(const char*);
|
|
void initDefaultPose(NPCActor*, const JMapInfoIter&);
|
|
void turnPlayerToActor(const LiveActor*, f32);
|
|
void decidePose(NPCActor*, const TVec3f&, const TVec3f&, const TVec3f&, f32, f32, f32) NO_INLINE;
|
|
void setNPCActorPos(NPCActor*, const char*);
|
|
void setNPCActorPos(NPCActor*, const TVec3f&);
|
|
void setNPCActorPose(NPCActor*, const TVec3f&, const TVec3f&, const TVec3f&);
|
|
void followRailPose(NPCActor*, f32, f32);
|
|
void followRailPoseOnGround(NPCActor*, f32);
|
|
void followRailPoseOnGround(NPCActor*, const LiveActor*, f32);
|
|
void setDefaultPose(NPCActor*);
|
|
bool convertPosOnGround(TVec3f*, const TVec3f&);
|
|
void timeKeepDemoFadeIn();
|
|
void timeKeepDemoFadeOut();
|
|
void startNPCTalkCamera(const TalkMessageCtrl*, MtxPtr, f32, s32);
|
|
void startNPCTalkCamera(const TalkMessageCtrl*, MtxPtr, MtxPtr, f32, s32);
|
|
void endNPCTalkCamera(bool, s32);
|
|
void initDefaultPosAndQuat(NPCActor*, const JMapInfoIter&);
|
|
PartsModel* createNPCGoods(LiveActor*, const char*, const char*);
|
|
PartsModel* createIndirectNPCGoods(LiveActor*, const char*, const char*);
|
|
bool calcPlayerFaceStareVector(TVec3f*, MtxPtr, MtxPtr);
|
|
bool calcPlayerFaceStarePos(TVec3f*, MtxPtr, MtxPtr);
|
|
bool isActionContinuous(const LiveActor*);
|
|
bool isActionLoopedOrStopped(const LiveActor*);
|
|
void invalidateLodCtrl(const NPCActor*);
|
|
void startMoveAction(NPCActor*);
|
|
bool tryStartTalkAction(NPCActor*);
|
|
bool tryStartMoveTalkAction(NPCActor*);
|
|
bool tryStartTurnAction(NPCActor*);
|
|
bool tryStartMoveTurnAction(NPCActor*);
|
|
bool tryStartReaction(NPCActor*);
|
|
bool tryTalkNearPlayerAndStartTalkAction(NPCActor*);
|
|
bool tryTalkNearPlayerAndStartMoveTalkAction(NPCActor*);
|
|
bool tryTalkNearPlayerAtEndAndStartTalkAction(NPCActor*);
|
|
bool tryTalkNearPlayerAtEndAndStartMoveTalkAction(NPCActor*);
|
|
bool tryTalkForceAndStartMoveTalkAction(NPCActor*);
|
|
bool tryTalkForceAtEndAndStartTalkAction(NPCActor*);
|
|
bool tryStartReactionAndPushNerve(NPCActor*, const Nerve*);
|
|
bool tryStartReactionAndPopNerve(NPCActor*);
|
|
bool tryChangeTalkActionRandom(NPCActor*, const char*, const char*, const char*);
|
|
f32 calcFloatOffset(const NPCActor*, f32, f32);
|
|
void calcAndSetFloatBaseMtx(NPCActor*, f32);
|
|
}; // namespace MR
|
|
|
|
class TakeOutStar : public NerveExecutor {
|
|
public:
|
|
TakeOutStar(NPCActor*, const char*, const char*, const Nerve*);
|
|
|
|
bool takeOut();
|
|
bool isFirstStep();
|
|
bool isLastStep();
|
|
void exeAnim();
|
|
void exeDemo();
|
|
void exeTerm();
|
|
|
|
/* 0x08 */ ModelObj* mStarModel;
|
|
/* 0x0C */ NPCActor* mActor;
|
|
/* 0x10 */ const Nerve* mNerve;
|
|
/* 0x14 */ const char* mActionName;
|
|
/* 0x18 */ const char* mAnimName;
|
|
};
|
|
|
|
class FadeStarter : public NerveExecutor {
|
|
public:
|
|
FadeStarter(NPCActor*, s32);
|
|
|
|
bool update();
|
|
void exeFade();
|
|
void exeTerm();
|
|
|
|
/* 0x08 */ NPCActor* mActor;
|
|
/* 0x0C */ const Nerve* _C;
|
|
/* 0x10 */ s32 _10;
|
|
};
|
|
|
|
class DemoStarter : public NerveExecutor {
|
|
public:
|
|
DemoStarter(NPCActor*);
|
|
|
|
bool update();
|
|
void start();
|
|
void exeInit();
|
|
void exeFade();
|
|
void exeWait();
|
|
void exeTerm();
|
|
|
|
/* 0x08 */ NPCActor* mActor;
|
|
};
|