mirror of
https://github.com/zeldaret/tp
synced 2026-06-19 16:00:01 -04:00
Various Matches, J2DTextBoxEx and J2DTevs OK (#2025)
* Work on src/d/bg * misc work * J2dTextBoxEx OK * J2DTevs OK * Better return values for bool
This commit is contained in:
@@ -444,8 +444,6 @@ struct J2DAlphaCompInfo {
|
||||
/* 0x7 */ u8 field_0x7;
|
||||
};
|
||||
|
||||
extern u16 j2dDefaultAlphaCmp;
|
||||
|
||||
inline u16 J2DCalcAlphaCmp(s32 param_1, u32 param_2, u32 param_3) {
|
||||
return ((param_1) << 5) | ((param_2 & 0xff) << 3) | (param_3 & 0xff);
|
||||
}
|
||||
@@ -486,7 +484,7 @@ struct J2DBlendInfo {
|
||||
/* 0x3 */ u8 mOp;
|
||||
};
|
||||
|
||||
extern J2DBlendInfo j2dDefaultBlendInfo;
|
||||
extern const J2DBlendInfo j2dDefaultBlendInfo;
|
||||
|
||||
struct J2DBlend {
|
||||
J2DBlend() { mBlendInfo = j2dDefaultBlendInfo; }
|
||||
@@ -595,7 +593,7 @@ struct J2DColorChanInfo {
|
||||
};
|
||||
|
||||
inline u8 J2DCalcColorChanID(u8 param_1) { return param_1; }
|
||||
extern J2DColorChanInfo j2dDefaultColorChanInfo;
|
||||
extern const J2DColorChanInfo j2dDefaultColorChanInfo;
|
||||
|
||||
class J2DColorChan {
|
||||
public:
|
||||
|
||||
@@ -2,6 +2,7 @@
|
||||
#define J2DTEVS_H
|
||||
|
||||
#include "dolphin/gx/GXEnum.h"
|
||||
#include "dolphin/gx/GXStruct.h"
|
||||
#include "dolphin/mtx/mtxvec.h"
|
||||
|
||||
struct J2DTextureSRTInfo {
|
||||
@@ -244,7 +245,7 @@ struct J2DTevOrderInfo {
|
||||
}
|
||||
};
|
||||
|
||||
extern J2DTevOrderInfo j2dDefaultTevOrderInfoNull;
|
||||
extern const J2DTevOrderInfo j2dDefaultTevOrderInfoNull;
|
||||
|
||||
class J2DTevOrder {
|
||||
public:
|
||||
@@ -294,6 +295,8 @@ struct J2DTevSwapModeInfo {
|
||||
/* 0x3 */ u8 field_0x3;
|
||||
};
|
||||
|
||||
extern const J2DTevSwapModeInfo j2dDefaultTevSwapMode;
|
||||
|
||||
class J2DTevStage {
|
||||
public:
|
||||
/* 802F4110 */ J2DTevStage(J2DTevStageInfo const&);
|
||||
@@ -455,4 +458,12 @@ private:
|
||||
/* 0x0 */ u8 field_0x0;
|
||||
};
|
||||
|
||||
extern const GXColor j2dDefaultColInfo;
|
||||
extern const GXColorS10 j2dDefaultTevColor;
|
||||
extern const GXColor j2dDefaultTevKColor;
|
||||
extern const J2DTevOrderInfo j2dDefaultTevOrderInfoNull;
|
||||
extern const u8 j2dDefaultPEBlockDither;
|
||||
extern const u8 data_804561AC;
|
||||
extern const u16 j2dDefaultAlphaCmp;
|
||||
|
||||
#endif /* J2DTEVS_H */
|
||||
|
||||
@@ -7,7 +7,7 @@ struct cBgD_Vtx_t : public Vec {};
|
||||
|
||||
class cBgS_GrpPassChk {
|
||||
public:
|
||||
virtual ~cBgS_GrpPassChk();
|
||||
virtual ~cBgS_GrpPassChk() {}
|
||||
};
|
||||
|
||||
class cBgS_PolyPassChk;
|
||||
|
||||
@@ -38,6 +38,7 @@ public:
|
||||
bool GetPreWallChk() const { return mPreWallChk; }
|
||||
bool GetPreGroundChk() const { return mPreGroundChk; }
|
||||
bool GetPreRoofChk() const { return mPreRoofChk; }
|
||||
cXyz* GetStartP() { return &mLin.GetStartP(); }
|
||||
};
|
||||
|
||||
#endif /* C_BG_S_LIN_CHK_H */
|
||||
|
||||
@@ -26,6 +26,7 @@ public:
|
||||
bool Cross(cM3dGCyl const* cyl, cXyz* xyz) const { return cM3d_Cross_CpsCyl(*this, *cyl, xyz); }
|
||||
bool Cross(cM3dGSph const* sph, cXyz* xyz) const { return cM3d_Cross_CpsSph(*this, *sph, xyz); }
|
||||
void SetR(f32 r) { mRadius = r; }
|
||||
f32 GetR() const { return mRadius; }
|
||||
|
||||
}; // Size = 0x20
|
||||
|
||||
|
||||
@@ -32,10 +32,10 @@ public:
|
||||
void setCode(sBgPc&);
|
||||
|
||||
u32 getHorseNoEntry() const { return m_code.code0 >> 0x15 & 1; }
|
||||
u32 getSpl() const { return m_code.code0 >> 0x18 & 0xF; }
|
||||
s32 getSpl() const { return m_code.code0 >> 0x18 & 0xF; }
|
||||
u32 getMagnet() const { return m_code.code0 >> 0x1C & 0x3; }
|
||||
u32 getMonkeyBars() const { return m_code.code0 >> 0x1F; }
|
||||
u32 getWallCode() const { return m_code.code1 >> 0x8 & 0xF; }
|
||||
s32 getWallCode() const { return m_code.code1 >> 0x8 & 0xF; }
|
||||
u32 getAtt0Code() const { return m_code.code1 >> 0xC & 0xF; }
|
||||
u32 getAtt1Code() const { return m_code.code1 >> 0x10 & 0x7; }
|
||||
u32 getGroundCode() const { return m_code.code1 >> 0x13 & 0x1F; }
|
||||
@@ -61,8 +61,14 @@ public:
|
||||
u8 getRoomPathPnt() const { return m_code.code2 >> 0x18; }
|
||||
u8 getRoomInf() const { return m_code.code4; }
|
||||
u8 getSnd() const { return m_code.code4 >> 0xB; }
|
||||
u32 maskNrm() { return m_code.code4 & 0x100; }
|
||||
|
||||
// BUG: Seems like this uses the same mask as maskNrm
|
||||
u32 getWtr() { return m_code.code4 & 0x100; }
|
||||
u32 getObjThrough() { return m_code.code0 & 0x4000; }
|
||||
u32 getCamThrough() { return m_code.code0 & 0x8000; }
|
||||
u32 getLinkThrough() { return m_code.code0 & 0x10000; }
|
||||
|
||||
private:
|
||||
/* 0x0 */ sBgPc m_code;
|
||||
};
|
||||
|
||||
|
||||
@@ -2,8 +2,7 @@
|
||||
#define D_BG_D_BG_PLC_H
|
||||
|
||||
#include "dolphin/types.h"
|
||||
|
||||
struct sBgPc;
|
||||
#include "d/bg/d_bg_pc.h"
|
||||
|
||||
enum {
|
||||
/* 0x14 */ ZELDA_CODE_SIZE = 0x14
|
||||
@@ -13,7 +12,7 @@ struct PLC {
|
||||
/* 0x0 */ u32 magic;
|
||||
/* 0x4 */ u16 m_code_size;
|
||||
/* 0x6 */ u16 m_num;
|
||||
/* 0x8 */ sBgPc* field_0x8;
|
||||
/* 0x8 */ sBgPc field_0x8[0];
|
||||
};
|
||||
|
||||
class dBgPlc {
|
||||
@@ -21,11 +20,11 @@ public:
|
||||
/* 80074074 */ dBgPlc();
|
||||
/* 80074080 */ ~dBgPlc();
|
||||
/* 800740BC */ void setBase(void*);
|
||||
/* 800740C4 */ void getCode(int, sBgPc**) const;
|
||||
/* 800740C4 */ sBgPc* getCode(int, sBgPc**) const;
|
||||
/* 800740DC */ u32 getGrpCode(int) const;
|
||||
|
||||
private:
|
||||
/* 0x00 */ void* m_base;
|
||||
/* 0x00 */ PLC* m_base;
|
||||
};
|
||||
|
||||
#endif /* D_BG_D_BG_PLC_H */
|
||||
|
||||
@@ -11,7 +11,7 @@ struct dBgPc;
|
||||
struct dBgS_CaptPoly;
|
||||
|
||||
struct KC_PrismData {
|
||||
/* 0x0 */ u16 field_0x0[2];
|
||||
/* 0x0 */ f32 field_0x0;
|
||||
/* 0x4 */ u16 field_0x4;
|
||||
/* 0x6 */ u16 field_0x6;
|
||||
/* 0x8 */ u16 field_0x8;
|
||||
|
||||
@@ -171,7 +171,7 @@ public:
|
||||
void offStateFlg0(daHorse_FLG0 flag) { mStateFlg0 &= ~flag; }
|
||||
void onEndResetStateFlg0(daHorse_ERFLG0 i_flag) { mEndResetStateFlg0 |= i_flag;}
|
||||
void offNoDrawWait() { offStateFlg0(NO_DRAW_WAIT); }
|
||||
int checkSpecialWallHit(const cXyz& param_0) { return (this->*mpCheckSpecialWallHitFn)(param_0); }
|
||||
bool checkSpecialWallHit(const cXyz& param_0) { return (this->*mpCheckSpecialWallHitFn)(param_0); }
|
||||
MtxP getSaddleMtx() { return field_0x570->i_getAnmMtx(21); }
|
||||
MtxP getRootMtx() { return field_0x570->i_getAnmMtx(0); }
|
||||
f32 getAnmFrameMax(int i_idx) const { return field_0x5b0[i_idx].getEnd(); }
|
||||
@@ -279,7 +279,7 @@ public:
|
||||
/* 0x17C4 */ cXyz mDemoPos0;
|
||||
/* 0x17D0 */ u8 field_0x17d0[0x18A4 - 0x17D0];
|
||||
/* 0x18A4 */ int (daHorse_c::*mpProcFn)();
|
||||
/* 0x18B0 */ int (daHorse_c::*mpCheckSpecialWallHitFn)(const cXyz&);
|
||||
/* 0x18B0 */ bool (daHorse_c::*mpCheckSpecialWallHitFn)(const cXyz&);
|
||||
/* 0x18BC */ void (daHorse_c::*mpSetReinPosHandFn)(int);
|
||||
/* 0x18C8 */ void (daHorse_c::*mpSetReinPosNormalFn)();
|
||||
/* 0x18D4 */ int (daHorse_c::*mpCallHorseFn)(const cXyz*);
|
||||
|
||||
Reference in New Issue
Block a user