1#include <game/bases/d_a_wm_peach_castle.hpp>
2#include <game/bases/d_a_wm_player.hpp>
3#include <game/bases/d_a_wm_map.hpp>
4#include <game/bases/d_cs_seq_manager.hpp>
5#include <game/bases/d_info.hpp>
7#include <game/bases/d_save_mng.hpp>
8#include <game/bases/d_unk_anim_class.hpp>
9#include <game/bases/d_wm_lib.hpp>
10#include <game/bases/d_wm_se_manager.hpp>
34 for (
int i = 0; i < ANIM_COUNT; i++) {
51 dCsSeqMng_c::ms_instance->FUN_801017c0(dCsSeqMng_c::SMC_DEMO_CASTLE_CLR,
this, daWmPlayer_c::ms_instance, 200);
67 nw4r::g3d::ResMdl resMdl =
mResFile.GetResMdl(
"cobPeachCastle");
70 static const char *resAnmNames[ANIM_COUNT] = {
82 for (
int i = 0; i < ANIM_COUNT; i++) {
83 nw4r::g3d::ResAnmChr resAnmChr =
mResFile.GetResAnmChr(resAnmNames[i]);
85 mChrAnim[i].mPlayMode = playModes[i];
106 if (cutsceneCommandId == dCsSeqMng_c::CUTSCENE_CMD_NONE) {
116 switch (cutsceneCommandId) {
117 case dCsSeqMng_c::CUTSCENE_CMD_17:
118 case dCsSeqMng_c::CUTSCENE_CMD_19:
122 dWmSeManager_c::m_pInstance->playSound(dWmSeManager_c::WM_SE_OBJ_CS_DOOR_OPEN_PEACH,
mPos, 1);
125 case dCsSeqMng_c::CUTSCENE_CMD_78:
128 case dCsSeqMng_c::CUTSCENE_CMD_20:
132 dWmSeManager_c::m_pInstance->playSound(dWmSeManager_c::WM_SE_OBJ_CS_DOOR_CLOSE_PEACH,
mPos, 1);
140 switch (cutsceneCommandId) {
141 case dCsSeqMng_c::CUTSCENE_CMD_17:
142 case dCsSeqMng_c::CUTSCENE_CMD_19:
148 case dCsSeqMng_c::CUTSCENE_CMD_78:
149 case dCsSeqMng_c::CUTSCENE_CMD_20:
162 static const char *nodeNames[] = {
163 "FlagA0",
"FlagA1",
"FlagA2",
164 "FlagB0",
"FlagB1",
"FlagB2",
165 "FlagC0",
"FlagC1",
"FlagC2",
166 "FlagD0",
"FlagD1",
"FlagD2",
167 "FlagE0",
"FlagE1",
"FlagE2",
199 dMj2dGame_c *save = dSaveMng_c::m_instance->getSaveGame(-1);
201 dInfo_c::m_instance->m_60 = 2;
mMtx_c mMatrix
The actor's partial transformation matrix. See makeMtx() for details.
mVec3_c mScale
The actor's scale (defaults to 1).
mVec3_c mPos
The actor's position.
mAng3_c mAngle
The actor's rotation (for 2D actors).
Represents the slot-specific save data for the game.
void onCourseDataFlag(int world, int level, ulong flag)
Sets the completion flag(s) for the given world/level. See COURSE_COMPLETION_e.
@ GOAL_NORMAL
The regular exit was cleared.
static dResMng_c * m_instance
The instance of this class.
static void setSoftLight_MapObj(m3d::bmdl_c &mdl)
Sets the soft light effect for map objects.
mSphere_c mClipSphere
A sphere representing the actor's visible area.
int mResNodeIdx
The index of the model's root resource node.
int GetCurrentPlayResultStatus()
The actor for Peach's Castle found on the World Map.
dHeapAllocator_c mAllocator
The allocator.
@ cobPeachCastleOpen
The door open animation.
@ cobPeachCastleFlag
The flag animation.
@ cobPeachCastleClose
The door close animation.
void ensureCourseClear()
Ensures the course associated to the actor is cleared.
daWmPeachCastle_c()
Constructs a new object.
virtual int execute()
do method for the execute operation.
nw4r::g3d::ResFile mResFile
The resource file.
void initState()
Sets up the actor's initial state.
void calcModel()
Updates the model's transformation matrix.
virtual void processCutsceneCommand(int cutsceneCommandId, bool isFirstFrame)
Contains the actor-specific logic for processing the current world map cutscene.
~daWmPeachCastle_c()
Destroys the object.
void initDoorCloseAnim()
Initializes the door close animation.
static const char * smc_doorNodeNames[]
The node names for the door open/close animations.
m3d::anmChrBlend_c mChrBlendAnim
The blended animation.
void initDoorOpenAnim()
Initializes the door open animation.
virtual int doDelete()
do method for the delete operation.
void initUnk()
Initializes mUnk2B8.
virtual int create()
do method for the create operation.
virtual int draw()
do method for the draw operation.
void initFlagAnim()
Initializes the flag animation.
m3d::anmChr_c mChrAnim[ANIM_COUNT]
The model animations.
m3d::mdl_c mModel
The model.
void createModel()
Initializes the resources for the actor.
@ SUCCEEDED
The step was completed successfully.
A three-dimensional short angle vector.
A three-dimensional floating point vector.
#define ACTOR_PROFILE(profName, className, properties)
Creates an actor profile, using the profile number as the execute and draw order value.
@ FORWARD_ONCE
Play the animation forward once.
@ FORWARD_LOOP
Play the animation forward in a loop.
@ GAME_HEAP_DEFAULT
The default game heap (alias of MEM1 or MEM2).
EGG::ExpHeap * g_gameHeaps[GAME_HEAP_COUNT]
The game heaps.