Skip to content

Commit

Permalink
More kando, link seConstants.cpp, updateMgr.cpp
Browse files Browse the repository at this point in the history
  • Loading branch information
HeartPiece44 committed Sep 17, 2024
1 parent 0640134 commit 952246f
Show file tree
Hide file tree
Showing 45 changed files with 948 additions and 2,951 deletions.
4 changes: 2 additions & 2 deletions configure.py
Original file line number Diff line number Diff line change
Expand Up @@ -443,9 +443,9 @@ def DolphinLib(lib_name: str, objects: List[Object]) -> Dict[str, Any]:
Object(NonMatching, "plugPikiKando/workObject.cpp"),
Object(NonMatching, "plugPikiKando/routeMgr.cpp"),
Object(NonMatching, "plugPikiKando/seMgr.cpp"),
Object(NonMatching, "plugPikiKando/seConstants.cpp"),
Object(Matching, "plugPikiKando/seConstants.cpp"),
Object(NonMatching, "plugPikiKando/soundMgr.cpp"),
Object(NonMatching, "plugPikiKando/updateMgr.cpp"),
Object(Matching, "plugPikiKando/updateMgr.cpp"),
Object(NonMatching, "plugPikiKando/cPlate.cpp"),
Object(NonMatching, "plugPikiKando/aiStone.cpp"),
Object(NonMatching, "plugPikiKando/aiActions.cpp"),
Expand Down
61 changes: 61 additions & 0 deletions include/CPlate.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,61 @@
#ifndef _CPLATE_H
#define _CPLATE_H

#include "types.h"
#include "Traversable.h"
#include "Node.h"

struct MapMgr;
struct Piki;
struct SlotChangeListner;

/**
* @brief TODO
*/
struct CPlate : public Traversable, public Node {

/**
* @brief TODO
*/
struct Slot {
Slot();

// TODO: members
};

CPlate(MapMgr*);

virtual Creature* getCreature(int); // _08
virtual int getFirst(); // _0C
virtual int getNext(int); // _10
virtual bool isDone(int); // _14
virtual void read(RandomAccessStream&); // _48
virtual void update(); // _4C
virtual void render(Graphics&); // _50

bool canNaviRunFast();
void init(Vector3f&);
void setPos(Vector3f&, f32, Vector3f&);
void setPosGray(Vector3f&, f32, Vector3f&);
void getSlot(Creature*, SlotChangeListner*);
void changeFlower(Piki*);
void releaseSlot(Creature*, int);
void validSlot(int);
void sortByColor(Piki*);
void rearrangeSlot(Vector3f&, f32, Vector3f&);
void refresh(int, f32);
void refreshSlot();

// unused/inlined:
void setPosNeutral(Vector3f&, f32, Vector3f&);
void swapSlot(int, int);
void postUpdate(f32);

// _00 = VTBL 1
// _08 = VTBL 2
// _00-_08 = Traversable
// _08-_28 = Node
// TODO: members
};

#endif
78 changes: 78 additions & 0 deletions include/GoalItem.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,78 @@
#ifndef _GOALITEM_H
#define _GOALITEM_H

#include "types.h"
#include "Suckable.h"
#include "zen/CallBack.h"
#include "zen/particle.h"
#include "CreatureProp.h"

namespace zen {
struct particleGenerator;
struct particleMdl;
} // namespace zen

struct ItemShapeObject;
struct Piki;
struct SimpleAI;

/**
* @brief TODO
*/
struct GoalItemProp : public CreatureProp {

// _54 = VTBL
// _00-_58 = CreatureProp
// TODO: members
};

/**
* @brief TODO
*/
struct GoalItem : public Suckable, public zen::CallBack2<zen::particleGenerator*, zen::particleMdl*> {
GoalItem(CreatureProp*, ItemShapeObject*, ItemShapeObject*, ItemShapeObject*, SimpleAI*);

virtual bool insideSafeArea(Vector3f&); // _10
virtual void startAI(int); // _34
virtual f32 getiMass(); // _38
virtual f32 getSize(); // _3C
virtual bool isVisible(); // _74
virtual bool isAlive(); // _88
virtual bool needShadow(); // _90
virtual bool ignoreAtari(Creature*); // _98
virtual void update(); // _E0
virtual void refresh(Graphics&); // _EC
virtual void playEffect(int); // _12C
virtual void getGoalPos(); // _15C
virtual void getGoalPosRadius(); // _160
virtual void getSuckPos(); // _164
virtual void suckMe(Pellet*); // _168
virtual void getRouteIndex(); // _170
virtual bool invoke(zen::particleGenerator*, zen::particleMdl*); // _180

void setFlowEffect(bool);
void setSpotActive(bool);
void setFlightLight(bool);
void enterGoal(Piki*);
void exitPikis(int);
void exitPiki();
void setColorType(int);
void startTakeoff();
void startLand();
void startConeShrink();
void startConeEmit();
void startBoot();
void emitPiki();

// unused/inlined:
void updateConeShrink();
void updateConeEmit();

static u8 demoHideFlag;

// _00 = VTBL
// _00-_3C8 = Suckable
// TODO: members
};

#endif
10 changes: 10 additions & 0 deletions include/ItemMgr.h
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,16 @@ struct ItemObject : public ItemCreature {
* @brief TODO.
*/
struct ItemMgr : public PolyObjectMgr {

/**
* @brief TODO.
*/
struct UseNode : public CoreNode {
// _00 = VTBL
// _00-_14 = CoreNode
// TODO: members
};

ItemMgr();

virtual ~ItemMgr(); // _48 (weak)
Expand Down
45 changes: 44 additions & 1 deletion include/PaniAnimator.h
Original file line number Diff line number Diff line change
Expand Up @@ -62,9 +62,14 @@ struct PaniItemAnimator : public PaniAnimator {
* @brief TODO
*/
struct PaniPelletAnimator : public PaniAnimator {
PaniPelletAnimator();

PaniMotionTable* createMotionTable();

// _30 = VTBL
// _00-_34 = PaniAnimator
// TODO: members
u8 _34[0x54 - 0x34]; // _34, unknown
// TODO: members
};

/**
Expand Down Expand Up @@ -128,4 +133,42 @@ struct PaniPikiAnimMgr {
// TODO: members
};

/**
* @brief TODO
*/
struct PaniMotionInfo {
PaniMotionInfo(int);
PaniMotionInfo(int, PaniAnimKeyListener*);

void init(int, PaniAnimKeyListener*);

// TODO: members
};

/**
* @brief TODO
*
* @note Size: 0x8.
*/
struct PaniMotion {
PaniMotion(int);

void init(int, int);

int _00; // _00
int _04; // _04
};

/**
* @brief TODO
*
* @note Size: 0x8.
*/
struct PaniMotionTable {
PaniMotionTable(int);

int _00; // _00
PaniMotion** _04; // _04
};

#endif
40 changes: 0 additions & 40 deletions include/PaniMotion.h

This file was deleted.

8 changes: 8 additions & 0 deletions include/Pellet.h
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
struct PaniAnimKeyEvent;
struct PelletShapeObject;
struct PelletView;
struct Shape;

/**
* @brief TODO
Expand Down Expand Up @@ -138,4 +139,11 @@ struct PelletMgr : public MonoObjectMgr {
// TODO: members
};

/**
* @brief TODO
*/
struct PelletShapeObject {
PelletShapeObject(char*, Shape*, char*, char*, int);
};

#endif
55 changes: 55 additions & 0 deletions include/PelletAnimator.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,55 @@
#ifndef _PELLETANIMATOR_H
#define _PELLETANIMATOR_H

#include "types.h"
#include "CoreNode.h"
#include "Parameters.h"
#include "PaniAnimator.h"
#include "String.h"

struct PaniAnimKeyListener;
struct PaniMotionInfo;
struct PaniMotionTable;

/**
* @brief TODO
*
* @note Size: 0x5C.
*/
struct PelletAnimInfo : public Parameters, public CoreNode {
PelletAnimInfo();

void createShapeObject();

// _04 = VTBL 1
// _58 = VTBL 2
// _00-_04 = Parameters
// _04-_18 = CoreNode
ID32 mID; // _18
u8 _24[0x58 - 0x24]; // _24, unknown

virtual void read(RandomAccessStream&); // _18
};

/**
* @brief TODO
*/
struct PelletAnimator {
PelletAnimator();

void init(AnimContext*, AnimContext*, AnimMgr*, PaniMotionTable*);
void finishMotion(PaniMotionInfo*, PaniMotionInfo*);
void startMotion(PaniMotionInfo&, PaniMotionInfo&);
void startMotion(PaniMotionInfo&);
void updateAnimation(f32, f32);
void updateContext();

// unused/inlined:
void startMotion(PaniMotionInfo*, PaniMotionInfo*);
void finishMotion(PaniAnimKeyListener*);

PaniPelletAnimator _00; // _00
PaniPelletAnimator _54; // _54
};

#endif
Loading

0 comments on commit 952246f

Please sign in to comment.