mirror of
https://github.com/zeldaret/tp
synced 2026-07-09 14:55:32 -04:00
obj_magLiftRot mostly done, obj_suisya / obj_tgake OK (#1895)
* obj_magLiftRot mostly done, obj_suisya / obj_tgake OK * remove asm
This commit is contained in:
@@ -110,7 +110,7 @@ public:
|
||||
/* 800D00DC */ void ClrGroundHit();
|
||||
/* 80141404 */ bool ChkGroundHit() const;
|
||||
|
||||
/* 80075F94 */ virtual ~dBgS_Acch() {}
|
||||
/* 80075F94 */ virtual ~dBgS_Acch();
|
||||
|
||||
cXyz* GetPos() { return pm_pos; }
|
||||
cXyz* GetOldPos() { return pm_old_pos; }
|
||||
|
||||
@@ -98,6 +98,8 @@ public:
|
||||
void SetRoomId(int id) { m_roomId = id; }
|
||||
bool ChkPriority(int prio) { return m_priority == prio; }
|
||||
void SetPriority(PRIORITY priority) { m_priority = priority; }
|
||||
void onStickWall() { field_0xb |= 1; }
|
||||
void onStickRoof() { field_0xb |= 2; }
|
||||
|
||||
private:
|
||||
/* 0x08 */ u8 m_priority;
|
||||
|
||||
@@ -52,6 +52,7 @@ public:
|
||||
u8 getMapToolId() { return mMapToolId; }
|
||||
s16 getEventId() { return mEventId; }
|
||||
s16 getIdx() { return mIndex; }
|
||||
void setIdx(u8 i_idx) { mIndex = i_idx; }
|
||||
char* getArchiveName() { return mArchiveName; }
|
||||
BOOL chkCondition(u16 condition) { return (mCondition & condition) == condition; }
|
||||
void i_onCondition(u16 cond) { mCondition |= cond; }
|
||||
|
||||
+149
-10
@@ -111,41 +111,180 @@ class mDoMtx_stack_c {
|
||||
public:
|
||||
/* 8000CCC8 */ static bool push();
|
||||
/* 8000CD14 */ static bool pop();
|
||||
/* 8000CD64 */ static void transS(cXyz const&);
|
||||
/* 8000CDD4 */ static void transM(cXyz const&);
|
||||
/* 8000CD9C */ static void transM(f32, f32, f32);
|
||||
/* 8000CE00 */ static void scaleS(cXyz const&);
|
||||
/* 8000CE70 */ static void scaleM(cXyz const&);
|
||||
/* 8000CE38 */ static void scaleM(f32, f32, f32);
|
||||
/* 8000CE9C */ static void XYZrotS(csXyz const&);
|
||||
/* 8000CED4 */ static void XYZrotM(csXyz const&);
|
||||
/* 8000CF0C */ static void ZXYrotS(csXyz const&);
|
||||
/* 8000CF44 */ static void ZXYrotM(csXyz const&);
|
||||
|
||||
/**
|
||||
* Translates the `now` Matrix by the given cXyz
|
||||
* @param xyz The xyz translation vector
|
||||
*/
|
||||
/* 8000CD64 */ static void transS(cXyz const& xyz);
|
||||
|
||||
/**
|
||||
* Translates a new Matrix by the given cXyz and then concatenates it with the `now` matrix
|
||||
* @param xyz The xyz translation vector
|
||||
*/
|
||||
/* 8000CDD4 */ static void transM(cXyz const& xyz);
|
||||
|
||||
/**
|
||||
* Translates a new Matrix by the given X, Y, and Z values and then concatenates it with the `now` matrix
|
||||
* @param x The x-axis translation value
|
||||
* @param y The y-axis translation value
|
||||
* @param z The z-axis translation value
|
||||
*/
|
||||
/* 8000CD9C */ static void transM(f32 x, f32 y, f32 z);
|
||||
|
||||
/**
|
||||
* Scales the `now` Matrix by the given cXyz
|
||||
* @param xyz The xyz scale vector
|
||||
*/
|
||||
/* 8000CE00 */ static void scaleS(cXyz const& xyz);
|
||||
|
||||
/**
|
||||
* Scales a new Matrix by the given cXyz and then concatenates it with the `now` matrix
|
||||
* @param xyz The xyz scale vector
|
||||
*/
|
||||
/* 8000CE70 */ static void scaleM(cXyz const& xyz);
|
||||
|
||||
/**
|
||||
* Scales a new Matrix by the given X, Y, and Z values and then concatenates it with the `now` matrix
|
||||
* @param x The x-axis scale value
|
||||
* @param y The y-axis scale value
|
||||
* @param z The z-axis scale value
|
||||
*/
|
||||
/* 8000CE38 */ static void scaleM(f32 x, f32 y, f32 z);
|
||||
|
||||
/* 8000CE9C */ static void XYZrotS(csXyz const& xyz);
|
||||
|
||||
/**
|
||||
* Rotates the `now` matrix by the given csXyz in the order Z, Y, X
|
||||
* @param xyz The xyz rotation vector
|
||||
*/
|
||||
/* 8000CED4 */ static void XYZrotM(csXyz const& xyz);
|
||||
|
||||
/* 8000CF0C */ static void ZXYrotS(csXyz const& xyz);
|
||||
|
||||
/**
|
||||
* Rotates the `now` matrix by the given csXyz in the order X, Y, Z
|
||||
* @param xyz The xyz rotation vector
|
||||
*/
|
||||
/* 8000CF44 */ static void ZXYrotM(csXyz const& xyz);
|
||||
|
||||
/* 8000CF7C */ static void quatM(Quaternion const*);
|
||||
/* 8000D070 */ ~mDoMtx_stack_c(); // inline
|
||||
|
||||
/**
|
||||
* Returns the `now` Matrix
|
||||
* @return The `now` Matrix
|
||||
*/
|
||||
static MtxP get() { return now; }
|
||||
|
||||
/**
|
||||
* Translates the `now` Matrix by the given X, Y, and Z values
|
||||
* @param x The x-axis translation value
|
||||
* @param y The y-axis translation value
|
||||
* @param z The z-axis translation value
|
||||
*/
|
||||
static void transS(f32 x, f32 y, f32 z) { PSMTXTrans(now, x, y, z); }
|
||||
|
||||
/**
|
||||
* Scales the `now` Matrix by the given X, Y, and Z values
|
||||
* @param x The x-axis scale value
|
||||
* @param y The y-axis scale value
|
||||
* @param z The z-axis scale value
|
||||
*/
|
||||
static void scaleS(f32 x, f32 y, f32 z) { PSMTXScale(now, x, y, z); }
|
||||
|
||||
/**
|
||||
* Multiplies a given Vec `a` by the `now` Matrix and places the result into Vec `b`
|
||||
* @param a The source Vec
|
||||
* @param b The output Vec
|
||||
*/
|
||||
static void multVec(const Vec* a, Vec* b) { PSMTXMultVec(now, a, b); }
|
||||
|
||||
/**
|
||||
* Multiplies a given Vec `a` by the `now` Matrix's "Scale-and-Rotate" component and places the result into Vec `b`
|
||||
* @param a The source Vec
|
||||
* @param b The output Vec
|
||||
*/
|
||||
static void multVecSR(const Vec* a, Vec* b) { PSMTXMultVecSR(now, a, b); }
|
||||
|
||||
static void multVecZero(Vec* v) { mDoMtx_multVecZero(now, v); }
|
||||
|
||||
/**
|
||||
* Multiplies a given Vec array `src` by the `now` Matrix and places the result into Vec array `dst`
|
||||
* @param src The source Vec array
|
||||
* @param dst The output Vec array
|
||||
* @param count The size of the array
|
||||
*/
|
||||
static void multVecArray(const Vec* src, Vec* dst, u32 count) {
|
||||
PSMTXMultVecArray(now, src, dst, count);
|
||||
}
|
||||
|
||||
static void XYZrotS(s16 x, s16 y, s16 z) { mDoMtx_XYZrotS(now, x, y, z); }
|
||||
|
||||
/**
|
||||
* Rotates the `now` matrix by the given X, Y, and Z values in the order Z, Y, X
|
||||
* @param x The x-axis rotation value
|
||||
* @param y The y-axis rotation value
|
||||
* @param z The z-axis rotation value
|
||||
*/
|
||||
static void XYZrotM(s16 x, s16 y, s16 z) { mDoMtx_XYZrotM(now, x, y, z); }
|
||||
|
||||
static void ZXYrotS(s16 x, s16 y, s16 z) { mDoMtx_ZXYrotS(now, x, y, z); }
|
||||
|
||||
/**
|
||||
* Rotates the `now` matrix by the given X, Y, and Z values in the order X, Y, Z
|
||||
* @param x The x-axis rotation value
|
||||
* @param y The y-axis rotation value
|
||||
* @param z The z-axis rotation value
|
||||
*/
|
||||
static void ZXYrotM(s16 x, s16 y, s16 z) { mDoMtx_ZXYrotM(now, x, y, z); }
|
||||
|
||||
/**
|
||||
* Rotates a new matrix on the Y-axis then concatenates it with the `now` matrix
|
||||
* @param y The rotation value
|
||||
*/
|
||||
static void YrotM(s16 y) { mDoMtx_YrotM(now, y); }
|
||||
|
||||
/**
|
||||
* Rotates the `now` matrix on the Y-axis
|
||||
* @param y The rotation value
|
||||
*/
|
||||
static void YrotS(s16 y) { mDoMtx_YrotS(now, y); }
|
||||
|
||||
/**
|
||||
* Rotates the `now` matrix on the X-axis
|
||||
* @param x The rotation value
|
||||
*/
|
||||
static void XrotS(s16 x) { mDoMtx_XrotS(now, x); }
|
||||
|
||||
/**
|
||||
* Rotates a new matrix on the X-axis then concatenates it with the `now` matrix
|
||||
* @param x The rotation value
|
||||
*/
|
||||
static void XrotM(s16 x) { mDoMtx_XrotM(now, x); }
|
||||
|
||||
/**
|
||||
* Rotates a new matrix on the z-axis then concatenates it with the `now` matrix
|
||||
* @param z The rotation value
|
||||
*/
|
||||
static void ZrotM(s16 z) { mDoMtx_ZrotM(now, z); }
|
||||
|
||||
static void inverse() { PSMTXInverse(now, now); }
|
||||
|
||||
static void inverseTranspose() { mDoMtx_inverseTranspose(now, now); }
|
||||
|
||||
/**
|
||||
* Concatenates the `now` matrix with the given Matrix `m`
|
||||
* @param m The matrix to concatenate with `now`
|
||||
*/
|
||||
static void concat(const Mtx m) { PSMTXConcat(now, m, now); }
|
||||
|
||||
static void revConcat(const Mtx m) { PSMTXConcat(m, now, now); }
|
||||
|
||||
/**
|
||||
* Copies a given matrix `m` to the `now` matrix
|
||||
* @param m The source matrix to copy
|
||||
*/
|
||||
static void copy(const Mtx m) { PSMTXCopy(m, now); }
|
||||
|
||||
static Mtx now;
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
#ifndef D_A_OBJ_MAGLIFTROT_H
|
||||
#define D_A_OBJ_MAGLIFTROT_H
|
||||
|
||||
#include "dolphin/types.h"
|
||||
#include "d/bg/d_bg_s_movebg_actor.h"
|
||||
#include "f_op/f_op_actor_mng.h"
|
||||
|
||||
#endif /* D_A_OBJ_MAGLIFTROT_H */
|
||||
|
||||
@@ -1,6 +1,22 @@
|
||||
#ifndef D_A_OBJ_SUISYA_H
|
||||
#define D_A_OBJ_SUISYA_H
|
||||
|
||||
#include "dolphin/types.h"
|
||||
#include "f_op/f_op_actor_mng.h"
|
||||
#include "d/bg/d_bg_s_acch.h"
|
||||
|
||||
class daObj_Suisya_c : public fopAc_ac_c {
|
||||
public:
|
||||
/* 80CF0078 */ int draw();
|
||||
/* 80CF0168 */ int execute();
|
||||
/* 80CF0234 */ int _delete();
|
||||
/* 80CF0284 */ int CreateHeap();
|
||||
/* 80CF0310 */ int create();
|
||||
|
||||
/* 0x568 */ request_of_phase_process_class mPhase;
|
||||
/* 0x570 */ J3DModel* mpModel;
|
||||
/* 0x574 */ u32 mShadowKey;
|
||||
/* 0x578 */ dBgS_AcchCir mAcchCir;
|
||||
/* 0x5B8 */ dBgS_ObjAcch mAcch;
|
||||
};
|
||||
|
||||
#endif /* D_A_OBJ_SUISYA_H */
|
||||
|
||||
@@ -1,6 +1,30 @@
|
||||
#ifndef D_A_OBJ_TGAKE_H
|
||||
#define D_A_OBJ_TGAKE_H
|
||||
|
||||
#include "dolphin/types.h"
|
||||
#include "f_op/f_op_actor_mng.h"
|
||||
#include "d/bg/d_bg_s_movebg_actor.h"
|
||||
|
||||
class daObjGake_c : public dBgS_MoveBgActor {
|
||||
public:
|
||||
/* 80D0BC18 */ void initBaseMtx();
|
||||
/* 80D0BC54 */ void setBaseMtx();
|
||||
/* 80D0BDA0 */ int create1st();
|
||||
|
||||
/* 80D0BD30 */ virtual int CreateHeap();
|
||||
/* 80D0BCB8 */ virtual int Create();
|
||||
/* 80D0BE24 */ virtual int Execute(Mtx**);
|
||||
/* 80D0BF7C */ virtual int Draw();
|
||||
/* 80D0C034 */ virtual int Delete();
|
||||
|
||||
u16 getEventBit1() { return fopAcM_GetParamBit(this, 0, 10); }
|
||||
u16 getEventBit2() { return fopAcM_GetParamBit(this, 10, 10); }
|
||||
u8 getType() { return fopAcM_GetParamBit(this, 0x14, 8); }
|
||||
|
||||
/* 0x5A0 */ request_of_phase_process_class mPhase;
|
||||
/* 0x5A8 */ J3DModel* mpModel;
|
||||
/* 0x5AC */ u16 mEventBit1;
|
||||
/* 0x5AE */ u16 mEventBit2;
|
||||
/* 0x5B0 */ u8 mHide;
|
||||
};
|
||||
|
||||
#endif /* D_A_OBJ_TGAKE_H */
|
||||
|
||||
Reference in New Issue
Block a user