3#include <lib/egg/heap/eggFrmHeap.hpp>
6#include <game/framework/f_helper_unk.hpp>
7#include <game/framework/f_manager.hpp>
8#include <game/framework/f_list_mg.hpp>
207 static void *
operator new(size_t);
208 static void operator delete(
void *);
[Unused]. [A helper class for fBase_c with unknown purpose].
The base class for all scenes, actors and various other processes.
int commonPack(int(fBase_c::*doFunc)(), int(fBase_c::*preFunc)(), void(fBase_c::*postFunc)(MAIN_STATE_e))
Executes an operation. See here for more details.
u8 mGroupType
The base's group type. Value is a GROUP_TYPE_e.
fBase_c * getChildProcessCreateState() const
Gets a child of the base in the CREATING state.
MAIN_STATE_e
The possible operation results.
@ ERROR
The operation could not be completed.
@ SUCCESS
The operation was completed successfully.
@ CANCELED
The operation was canceled early.
@ WAITING
The operation is waiting for something and cannot be completed yet.
static ProfileName m_tmpCtProfName
Temporary storage for the next constructed base's profile name. See mProfName.
virtual int preCreate()
pre method for the create operation.
static int(* sLoadAsyncCallback)()
[Unused]. See Unused Content.
virtual int draw()
do method for the draw operation.
virtual int preDelete()
pre method for the delete operation.
fLiMgBa_c mUnusedList
[Unused]. See Unused Content.
bool mDeferExecute
If the create operation was completed, but scheduling the execute and draw operations isn't possible ...
static fBase_c * createChild(ProfileName profName, fBase_c *parent, unsigned long param, u8 groupType)
Creates a child base under the given parent.
static fBaseID_e m_rootUniqueID
Unique ID counter for base construction. See mUniqueID.
EGG::FrmHeap * mHeap
[Unused]. The base's dedicated heap.
int createPack()
Executes the create operation. See commonPack.
void runCreate()
Kickstarts the base's lifecycle by running the create operation.
virtual ~fBase_c()
Destroys the base.
fBase_c * getConnectChild() const
Gets the base's first child.
fBase_c * getConnectBrNext() const
Gets the base's next sibling.
void deleteRequest()
Requests deletion of the base.
int connectProc()
Executes the connect operation.
virtual int create()
do method for the create operation.
static fBase_c * fBase_make(ProfileName profName, fTrNdBa_c *connectParent, unsigned long param, u8 groupType)
Internal function for base construction.
GROUP_TYPE_e
The possible group types.
@ SCENE
The base is a scene.
@ OTHER
The base is a generic process.
@ ACTOR
The base is an actor.
virtual int preExecute()
pre method for the execute operation.
fManager_c mMng
The base's process manager.
static u8 m_tmpCtGroupType
Temporary storage for the next constructed base's group type. See mGroupType.
virtual bool entryFrmHeap(unsigned long size, EGG::Heap *parentHeap)
[Unused]. Creates a heap of the given size for the base.
virtual bool createHeap()
[Unused]. [Does nothing].
virtual void postCreate(MAIN_STATE_e state)
post method for the create operation.
static u32 m_tmpCtParam
Temporary storage for the next constructed base's params. See mParam.
ProfileName mProfName
The base's profile name.
bool checkChildProcessCreateState() const
Checks if the base has at least one child in the CREATING state.
bool mDeferRetryCreate
If the create operation has not been completed, and rescheduling it isn't possible at this time.
fBaHelper_c * mpUnusedHelper
[Unused]. See Unused Content.
LIFECYCLE_e
The possible lifecycle states.
@ CREATING
The base's create operation has yet to conclude.
@ DELETING
The base's delete operation is about to run.
@ ACTIVE
The base is in the main execution cycle.
u32 mParam
A bitfield that configures the base's behaviour. Its usage varies from profile to profile.
bool mDeleteRequested
If deletion of the base was requested, but the delete operation has not been scheduled yet.
virtual void postExecute(MAIN_STATE_e state)
post method for the execute operation.
virtual int preDraw()
pre method for the draw operation.
void clearProcControlFlag(u8 flag)
Clears a flag in mProcControl.
int deletePack()
Executes the delete operation. See commonPack.
virtual int execute()
do method for the execute operation.
void setProcControlFlag(u8 flag)
Sets a flag in mProcControl.
int executePack()
Executes the execute operation. See commonPack.
static fBase_c * createRoot(ProfileName profName, unsigned long param, u8 groupType)
Creates a root base.
PROC_DISABLE_e
Controls if the execute and draw operations should be skipped.
@ DISABLE_DRAW
Drawing is disabled.
@ ROOT_DISABLE_EXECUTE
Execution is disabled, and this is a root base.
@ DISABLE_EXECUTE
Execution is disabled.
@ ROOT_DISABLE_DRAW
Drawing is disabled, and this is a root base.
virtual bool entryFrmHeapNonAdjust(unsigned long size, EGG::Heap *parentHeap)
[Unused]. Creates a heap of the given size for the base.
u8 mLifecycleState
The base's lifecycle state. Value is a LIFECYCLE_e.
virtual void postDraw(MAIN_STATE_e state)
post method for the draw operation.
virtual void postDelete(MAIN_STATE_e state)
post method for the delete operation.
fBase_c * getConnectParent() const
Gets the base's parent.
PACK_RESULT_e
The possible operation step results.
@ NOT_READY
The step could not completed at this time.
@ SUCCEEDED
The step was completed successfully.
@ FAILED
The step could not be completed.
int drawPack()
Executes the draw operation. See commonPack.
u8 mProcControl
The operations to be skipped. Value is a PROC_DISABLE_e.
static void setTmpCtData(ProfileName profName, fTrNdBa_c *connectParent, unsigned long param, u8 groupType)
Sets temporary data to be used for the next base's construction.
virtual void deleteReady()
Informs the base that it's about to be deleted.
static fTrNdBa_c * m_tmpCtConnectParent
Temporary storage for the next constructed base's parent connect node.
virtual int doDelete()
do method for the delete operation.
static void(* sUnloadCallback)()
[Unused]. See Unused Content.
fBaseID_e mUniqueID
The base's unique identifier.
bool isProcControlFlag(u8 flag) const
Checks if a flag is set in mProcControl.
fBase_c()
Constructs a new base.
A base list, made of fLiNdBa_c nodes.
Manages the execution of base operations.
A base tree, made of fTrNdBa_c nodes.
fBaseID_e
A unique identifier for each base.
u16 ProfileName
The name of a profile. Value is a fProfile::PROFILE_NAME_e.