mirror of https://github.com/zeldaret/tp.git
cleanup d_meter2_info / little JMessage work (#2460)
* d_meter2_info cleanup * parseBlock_next matching
This commit is contained in:
parent
9a98863aff
commit
e8e36445ba
|
|
@ -231,6 +231,7 @@ struct TLinkList_factory : public TLinkList<T, I> {
|
|||
inline virtual ~TLinkList_factory() = 0;
|
||||
virtual T* Do_create() = 0;
|
||||
virtual void Do_destroy(T*) = 0;
|
||||
|
||||
void Clear_destroy() {
|
||||
while (!this->empty()) {
|
||||
T* item = &this->front();
|
||||
|
|
@ -238,6 +239,12 @@ struct TLinkList_factory : public TLinkList<T, I> {
|
|||
Do_destroy(item);
|
||||
}
|
||||
}
|
||||
|
||||
TLinkList<T, I>::iterator Erase_destroy(T* param_0) {
|
||||
TLinkList<T, I>::iterator spC(Erase(param_0));
|
||||
Do_destroy(param_0);
|
||||
return spC;
|
||||
}
|
||||
};
|
||||
|
||||
template <typename T, int I>
|
||||
|
|
|
|||
|
|
@ -247,8 +247,8 @@ inline void JKRUnmountArchive(JKRArchive* arc) {
|
|||
arc->unmount();
|
||||
}
|
||||
|
||||
inline void JKRReadIdxResource(void* param_1, u32 param_2, u32 param_3, JKRArchive* param_4) {
|
||||
param_4->readIdxResource(param_1, param_2, param_3);
|
||||
inline u32 JKRReadIdxResource(void* buffer, u32 bufsize, u32 resIdx, JKRArchive* archive) {
|
||||
return archive->readIdxResource(buffer, bufsize, resIdx);
|
||||
}
|
||||
|
||||
#endif
|
||||
|
|
|
|||
|
|
@ -0,0 +1,41 @@
|
|||
#ifndef JMESSAGE_H
|
||||
#define JMESSAGE_H
|
||||
|
||||
#include <dolphin.h>
|
||||
|
||||
// Struct definitions might be wrong
|
||||
typedef struct bmg_header_t {
|
||||
/* 0x00 */ char magic[8]; // "MESGbmg1"
|
||||
/* 0x08 */ u32 size; // total size of file not including FLW1/FLI1 sections
|
||||
/* 0x0C */ u32 n_sections; // number of sections
|
||||
/* 0x10 */ u8 encoding; // text encoding
|
||||
/* 0x11 */ u8 padding[0x20 - 0x11]; // padding
|
||||
} bmg_header_t;
|
||||
|
||||
typedef struct bmg_section_t {
|
||||
/* 0x0 */ u32 magic; // four character magic string
|
||||
/* 0x4 */ u32 size; // total size of the section
|
||||
} bmg_section_t;
|
||||
|
||||
typedef struct inf1_entry_t {
|
||||
/* 0x0 */ u32 string_offset; // offset into DAT1 section entries, pointing to where message text starts
|
||||
/* 0x4 */ // attributes // attribute data. size fills up the rest of defined INF1 "entry_size"
|
||||
} inf1_entry_t;
|
||||
|
||||
typedef struct inf1_section_t {
|
||||
/* 0x00 */ bmg_section_t header; // section header
|
||||
/* 0x08 */ u16 entry_num; // number of entries in this section
|
||||
/* 0x0A */ u16 entry_size; // size of an entry
|
||||
/* 0x0C */ u8 padding[4]; // padding
|
||||
} inf1_section_t;
|
||||
|
||||
typedef struct str1_entry_t {
|
||||
char str[0];
|
||||
} str1_entry_t;
|
||||
|
||||
typedef struct str1_section_t {
|
||||
/* 0x00 */ bmg_section_t header; // section header
|
||||
/* 0x08 */ str1_entry_t entries[0];
|
||||
} str1_section_t;
|
||||
|
||||
#endif /* JMESSAGE_H */
|
||||
|
|
@ -24,6 +24,11 @@ struct data {
|
|||
|
||||
struct TParse_TBlock : public JGadget::binary::TParseData_aligned<4> {
|
||||
TParse_TBlock(const void* data) : TParseData_aligned(data) {}
|
||||
|
||||
const char* get() const { return (char*)getRaw(); }
|
||||
u32 get_size() const { return *(u32*)(get() + 0x4); }
|
||||
const void* getNext() const { return (char*)getRaw() + get_size(); }
|
||||
u32 get_type() const { return *(u32*)(get() + 0x0); }
|
||||
};
|
||||
|
||||
struct TParse_TBlock_info : public TParse_TBlock {
|
||||
|
|
@ -55,6 +60,18 @@ struct data {
|
|||
TParse_TBlock_color(const void* data) : TParse_TBlock(data) {}
|
||||
};
|
||||
|
||||
struct TParse_TBlock_messageText : public TParse_TBlock {
|
||||
TParse_TBlock_messageText(const void* data) : TParse_TBlock(data) {}
|
||||
|
||||
char* getContent() const { return (char*)getRaw() + 0x8; }
|
||||
};
|
||||
|
||||
struct TParse_TBlock_stringAttribute : public TParse_TBlock {
|
||||
TParse_TBlock_stringAttribute(const void* data) : TParse_TBlock(data) {}
|
||||
|
||||
char* getContent() const { return (char*)getRaw() + 0x8; }
|
||||
};
|
||||
|
||||
static u32 getTagCode(u32 tag) { return tag & 0xFFFF; }
|
||||
static u32 getTagGroup(u32 tag) { return (tag >> 0x10) & 0xFF; }
|
||||
|
||||
|
|
|
|||
|
|
@ -13,7 +13,7 @@ namespace JMessage {
|
|||
*/
|
||||
struct TResource {
|
||||
TResource()
|
||||
: field_0x8(NULL), field_0xc(NULL), field_0x10(NULL), field_0x14(0), mMessageID(NULL) {}
|
||||
: field_0x8(NULL), field_0xc(NULL), field_0x10(NULL), field_0x14(NULL), mMessageID(NULL) {}
|
||||
|
||||
/* 802A8CDC */ u16 toMessageIndex_messageID(u32, u32, bool*) const;
|
||||
|
||||
|
|
@ -50,11 +50,28 @@ struct TResource {
|
|||
void setData_header(const void* pData) {
|
||||
field_0x8.setRaw(pData);
|
||||
}
|
||||
|
||||
void setData_block_info(const void* pData) {
|
||||
field_0xc.setRaw(pData);
|
||||
}
|
||||
|
||||
void setData_block_messageText(const void* pData) {
|
||||
field_0x10 = data::TParse_TBlock_messageText(pData).getContent();
|
||||
}
|
||||
|
||||
void setData_block_stringAttribute(const void* pData) {
|
||||
field_0x14 = data::TParse_TBlock_stringAttribute(pData).getContent();
|
||||
}
|
||||
|
||||
void setData_block_messageID(const void* pData) {
|
||||
mMessageID.setRaw(pData);
|
||||
}
|
||||
|
||||
JGadget::TLinkListNode ocObject_;
|
||||
/* 0x08 */ data::TParse_THeader field_0x8;
|
||||
/* 0x0C */ data::TParse_TBlock_info field_0xc;
|
||||
/* 0x10 */ char* field_0x10;
|
||||
/* 0x14 */ int field_0x14;
|
||||
/* 0x14 */ char* field_0x14;
|
||||
/* 0x18 */ data::TParse_TBlock_messageID mMessageID;
|
||||
};
|
||||
|
||||
|
|
|
|||
|
|
@ -166,15 +166,9 @@ public:
|
|||
/* 0xC0 */ f32 field_0xc0;
|
||||
/* 0xC4 */ f32 field_0xc4;
|
||||
};
|
||||
|
||||
#include "f_op/f_op_actor_mng.h"
|
||||
|
||||
class JMSMesgEntry_c : public fopEn_enemy_c {
|
||||
private:
|
||||
/* 0x5ac */ u8 field_0x5ac[0x748 - 0x5ac];
|
||||
};
|
||||
|
||||
STATIC_ASSERT(sizeof(JMSMesgEntry_c) == 0x748);
|
||||
|
||||
struct JKRExpHeap {};
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -41,110 +41,117 @@ public:
|
|||
/* 0x08 */ cXyz mPosition;
|
||||
/* 0x14 */ s16 mAngle;
|
||||
/* 0x16 */ u8 mRoomNo;
|
||||
/* 0x17 */ u8 unk79;
|
||||
/* 0x18 */ u8 mWarpPlayerNo;
|
||||
/* 0x17 */ u8 unk_0x17;
|
||||
/* 0x18 */ u8 mPlayerNo;
|
||||
};
|
||||
|
||||
dMeter2Info_c();
|
||||
virtual ~dMeter2Info_c();
|
||||
void init(void);
|
||||
int setFloatingMessage(u16, s16, bool);
|
||||
int setFloatingFlow(u16, s16, bool);
|
||||
bool isFloatingMessageVisible(void);
|
||||
s16 decFloatingMessageTimer(void);
|
||||
void resetFloatingMessage(void);
|
||||
void decMsgKeyWaitTimer(void);
|
||||
void getString(u32, char*, JMSMesgEntry_c*); // define JMSMesgEntry
|
||||
void getStringKana(u32, char*, JMSMesgEntry_c*);
|
||||
void getStringKanji(u32, char*, JMSMesgEntry_c*);
|
||||
f32 getStringLength(J2DTextBox*, char*);
|
||||
f32 getStringLength(JUTFont*, f32, f32, char*);
|
||||
|
||||
void init();
|
||||
int setFloatingMessage(u16 i_msgID, s16 i_msgTimer, bool i_wakuVisible);
|
||||
int setFloatingFlow(u16 i_flowID, s16 i_msgTimer, bool i_wakuVisible);
|
||||
bool isFloatingMessageVisible();
|
||||
s16 decFloatingMessageTimer();
|
||||
void resetFloatingMessage();
|
||||
void decMsgKeyWaitTimer();
|
||||
void getString(u32 i_stringID, char* o_string, JMSMesgEntry_c* i_msgEntry);
|
||||
void getStringKana(u32 i_stringID, char* o_string, JMSMesgEntry_c* i_msgEntry);
|
||||
void getStringKanji(u32 i_stringID, char* o_string, JMSMesgEntry_c* i_msgEntry);
|
||||
f32 getStringLength(J2DTextBox* i_textbox, char* i_string);
|
||||
f32 getStringLength(JUTFont* i_font, f32 param_2, f32 param_3, char* i_string);
|
||||
void onDirectUseItem(int);
|
||||
BOOL isDirectUseItem(int);
|
||||
int setMeterString(s32);
|
||||
void resetWarpStatus(void);
|
||||
void warpInProc(void);
|
||||
void warpOutProc(void);
|
||||
void resetMeterString(void);
|
||||
void setWarpInfo(const char*, const cXyz&, s16, u8, u8, u8);
|
||||
u8 getItemType(u8);
|
||||
int readItemTexture(u8, void*, J2DPicture*, void*, J2DPicture*, void*, J2DPicture*, void*,
|
||||
J2DPicture*, int);
|
||||
void setItemColor(u8, J2DPicture*, J2DPicture*, J2DPicture*, J2DPicture*);
|
||||
s16 get2ndTexture(u8);
|
||||
s16 get3rdTexture(u8);
|
||||
s16 get4thTexture(u8);
|
||||
void set1stColor(u8, J2DPicture*);
|
||||
void set2ndColor(u8, J2DPicture*);
|
||||
void set3rdColor(u8, J2DPicture*);
|
||||
void set4thColor(u8, J2DPicture*);
|
||||
void setHotSpringTimer(u8);
|
||||
void decHotSpringTimer(void);
|
||||
void changeWater(u8);
|
||||
void setMiniGameItem(u8);
|
||||
void resetMiniGameItem(bool);
|
||||
void setMiniGameCount(s8);
|
||||
void setSaveStageName(const char*);
|
||||
int setMeterString(s32 i_string);
|
||||
void resetWarpStatus();
|
||||
void warpInProc();
|
||||
void warpOutProc();
|
||||
void resetMeterString();
|
||||
void setWarpInfo(const char* i_stageName, const cXyz& i_position, s16 i_angle,
|
||||
u8 i_roomNo, u8 param_4, u8 i_warpPlayerNo);
|
||||
u8 getItemType(u8 i_itemNo);
|
||||
int readItemTexture(u8 i_itemNo, void* i_texBuf1, J2DPicture* i_pic1, void* i_texBuf2,
|
||||
J2DPicture* i_pic2, void* i_texBuf3, J2DPicture* i_pic3,
|
||||
void* i_texBuf4, J2DPicture* i_pic4, int param_9);
|
||||
void setItemColor(u8 i_itemNo, J2DPicture* i_pic1, J2DPicture* i_pic2,
|
||||
J2DPicture* i_pic3, J2DPicture* i_pic4);
|
||||
s16 get2ndTexture(u8 i_itemType);
|
||||
s16 get3rdTexture(u8 i_itemType);
|
||||
s16 get4thTexture(u8 i_itemType);
|
||||
void set1stColor(u8 i_itemType, J2DPicture* i_pic);
|
||||
void set2ndColor(u8 i_itemType, J2DPicture* i_pic);
|
||||
void set3rdColor(u8 i_itemType, J2DPicture* i_pic);
|
||||
void set4thColor(u8 i_itemType, J2DPicture* i_pic);
|
||||
void setHotSpringTimer(u8 i_slotNo);
|
||||
void decHotSpringTimer();
|
||||
void changeWater(u8 i_slotNo);
|
||||
void setMiniGameItem(u8 i_minigameFlag);
|
||||
void resetMiniGameItem(bool i_saveItem);
|
||||
void setMiniGameCount(s8 i_count);
|
||||
void setSaveStageName(const char* i_stageName);
|
||||
|
||||
void setWindowStatus(u8 status) {
|
||||
unk186 = mWindowStatus;
|
||||
mWindowStatus = status;
|
||||
void setWindowStatus(u8 i_status) {
|
||||
unk_0xba = mWindowStatus;
|
||||
mWindowStatus = i_status;
|
||||
}
|
||||
|
||||
u8& getDirectUseItem() { return mDirectUseItem; }
|
||||
dMeterMap_c* getMeterMapClass() { return mMeterMap; }
|
||||
void setMenuWindowClass(dMw_c* p_menu) { mMenuWindowClass = p_menu; }
|
||||
void setMenuWindowClass(dMw_c* i_menu) { mMenuWindowClass = i_menu; }
|
||||
dMw_c* getMenuWindowClass() { return mMenuWindowClass; }
|
||||
CPaneMgr* getMeterItemPanePtr(s32 i_idx) { return mMeterItemPanePtr[i_idx]; }
|
||||
void offUseButton(int pButton) { mUseButton &= ~(u16)pButton; }
|
||||
void offUseButton(int i_buttonBit) { mUseButton &= ~(u16)i_buttonBit; }
|
||||
u16 getOilGaugeBackUp() { return mOilGaugeBackUp; }
|
||||
u8 getInsectSelectType() { return mInsectSelectType; }
|
||||
void setInsectSelectType(u8 i_type) { mInsectSelectType = i_type; }
|
||||
u8 getWarpStatus() { return mWarpStatus; }
|
||||
void setWarpStatus(u8 status) { mWarpStatus = status; }
|
||||
void setWarpStatus(u8 i_status) { mWarpStatus = i_status; }
|
||||
u8 getWarpRoomNo() { return mWarpInfo.mRoomNo; }
|
||||
u8 getWarpPlayerNo() { return mWarpInfo.mWarpPlayerNo; }
|
||||
u8 getWarpPlayerNo() { return mWarpInfo.mPlayerNo; }
|
||||
cXyz& getWarpPos() { return mWarpInfo.mPosition; }
|
||||
const char* getWarpStageName() { return mWarpInfo.mStageName; }
|
||||
void setNowCount(u8 count) { mNowCount = count; }
|
||||
void setMaxCount(u8 count) { mMaxCount = count; }
|
||||
void allUseButton() { mUseButton = -1; }
|
||||
bool isUseButton(int param_0) { return param_0 & mUseButton; }
|
||||
void setMeterMapClass(dMeterMap_c* p_map) { mMeterMap = p_map; }
|
||||
void setNowCount(u8 i_count) { mNowCount = i_count; }
|
||||
void setMaxCount(u8 i_count) { mMaxCount = i_count; }
|
||||
void allUseButton() { mUseButton = 0xFFFF; }
|
||||
bool isUseButton(int i_buttonBit) { return i_buttonBit & mUseButton; }
|
||||
void setMeterMapClass(dMeterMap_c* i_map) { mMeterMap = i_map; }
|
||||
void resetGameStatus() { mGameStatus = 0; }
|
||||
void onGameStatus(int status) { mGameStatus |= status; }
|
||||
void setMapStatus(u8 status) { mMapStatus = status; }
|
||||
void onGameStatus(int i_status) { mGameStatus |= i_status; }
|
||||
void setMapStatus(u8 i_status) { mMapStatus = i_status; }
|
||||
u8 getMapStatus() { return mMapStatus; }
|
||||
void setPauseStatus(u8 status) { mPauseStatus = status; }
|
||||
void setPauseStatus(u8 i_status) { mPauseStatus = i_status; }
|
||||
void resetPauseStatus() { mPauseStatus = 0; }
|
||||
u8 getPauseStatus() { return mPauseStatus; }
|
||||
bool isGameStatus(int status) { return mGameStatus & status; }
|
||||
bool isGameStatus(int i_status) { return mGameStatus & i_status; }
|
||||
bool isTouchKeyCheck(int i_status) { return mTouchKeyCheck & (1 << i_status); }
|
||||
|
||||
// fake function, should be isTouchKeyCheck
|
||||
bool isTouchKeyCheck_alt(int i_status) { return (mTouchKeyCheck >> i_status) & 1; }
|
||||
void setMapKeyDirection(u16 direction) { mMapKeyDirection = direction; }
|
||||
bool isSub2DStatus(int flag) { return mSub2DStatus & (1 << flag); }
|
||||
void offMenuInForce(int flag) { unk152 &= ~(1 << flag); }
|
||||
bool isMenuInForce(int flag) { return unk152 & (1 << flag); }
|
||||
|
||||
void setMapKeyDirection(u16 i_direction) { mMapKeyDirection = i_direction; }
|
||||
bool isSub2DStatus(int i_flag) { return mSub2DStatus & (1 << i_flag); }
|
||||
void offMenuInForce(int i_flag) { unk_0x98 &= ~(1 << i_flag); }
|
||||
bool isMenuInForce(int i_flag) { return unk_0x98 & (1 << i_flag); }
|
||||
u16 getMapKeyDirection() { return mMapKeyDirection; }
|
||||
u8 getWindowStatus() { return mWindowStatus; }
|
||||
void setMsgResource(void* res) { mMsgResource = res; }
|
||||
void setStageMsgResource(void* res) { mStageMsgResource = res; }
|
||||
void setMsgUnitResource(void* res) { mMsgUnitResource = res; }
|
||||
void setMsgResource(void* i_res) { mMsgResource = i_res; }
|
||||
void setStageMsgResource(void* i_res) { mStageMsgResource = i_res; }
|
||||
void setMsgUnitResource(void* i_res) { mMsgUnitResource = i_res; }
|
||||
void* getMsgResource() { return mMsgResource; }
|
||||
void* getStageMsgResource() { return mStageMsgResource; }
|
||||
void* getMsgUnitResource() { return mMsgUnitResource; }
|
||||
u8 getLightDropGetFlag(int i) { return mLightDropGetFlag[i]; }
|
||||
u8 getLightDropGetFlag(int i_no) { return mLightDropGetFlag[i_no]; }
|
||||
u32 getMeterStringType() { return mMeterString; }
|
||||
void setMeterClass(dMeter2_c* meter) { mMeterClass = meter; }
|
||||
void setMeterClass(dMeter2_c* i_meter) { mMeterClass = i_meter; }
|
||||
void onLifeGaugeSE() { mLifeGaugeSE = 1; }
|
||||
void offLifeGaugeSE() { mLifeGaugeSE = 0; }
|
||||
u8 getLifeGaugeSE() { return mLifeGaugeSE; }
|
||||
const char* getSaveStageName() { return mSaveStageName; }
|
||||
void onShopTalkFlag() { mShopTalkFlag = true; }
|
||||
void offShopTalkFlag() { mShopTalkFlag = false; }
|
||||
void setLightDropGetFlag(int index, u8 flag) { mLightDropGetFlag[index] = flag; }
|
||||
void setLightDropGetFlag(int i_no, u8 i_flag) { mLightDropGetFlag[i_no] = i_flag; }
|
||||
u8 getRentalBombBag() { return mRentalBombBagIdx; }
|
||||
void setTableMapRegionNo(u8 regionNo) { mTableMapRegionNo = regionNo; }
|
||||
void setTableMapRegionNo(u8 i_regionNo) { mTableMapRegionNo = i_regionNo; }
|
||||
void setGoldWolfMapType(u8 i_mapType) { mGoldWolfMapType = i_mapType; }
|
||||
dMeter2_c* getMeterClass() { return mMeterClass; }
|
||||
u8 getMiniGameItemSetFlag() { return mMiniGameItemSetFlag; }
|
||||
|
|
@ -153,7 +160,7 @@ public:
|
|||
void setGameOverType(u8 i_gameoverType) { mGameOverType = i_gameoverType; }
|
||||
void setMsgKeyWaitTimer(s16 i_waitTimer) { mMsgKeyWaitTimer = i_waitTimer; }
|
||||
s32 getMsgTimeMs() { return mMsgTimeMs; }
|
||||
void setMsgTimeMs(s32 msgTime) { mMsgTimeMs = msgTime; }
|
||||
void setMsgTimeMs(s32 i_msgTime) { mMsgTimeMs = i_msgTime; }
|
||||
void setTimeMs(s32 i_time) { mTimeMs = i_time; }
|
||||
s32 getTimeMs() { return mTimeMs; }
|
||||
u8 getNowCount() { return mNowCount; }
|
||||
|
|
@ -178,16 +185,16 @@ public:
|
|||
mCollectCursorPosX = x;
|
||||
mCollectCursorPosY = y;
|
||||
}
|
||||
void setMapDrugFlag(bool flag) { mMapDrugFlag = flag; }
|
||||
void setMapDrugFlag(bool i_flag) { mMapDrugFlag = i_flag; }
|
||||
void offTempBit(int i_bit) { mTempBits &= ~(1 << i_bit); }
|
||||
void onTempBit(int i_bit) { mTempBits |= (1 << i_bit); }
|
||||
bool isTempBit(int bit) { return mTempBits & (1 << bit); }
|
||||
void offSub2DStatus(int bit) { mSub2DStatus &= ~(1 << bit); }
|
||||
void onSub2DStatus(int bit) { mSub2DStatus |= 1 << bit; }
|
||||
void set2DWidth(float width) { m2DWidth = width; }
|
||||
void set2DHeight(float height) { m2DHeight = height; }
|
||||
void set2DPosH(float posH) { m2DPosH = posH; }
|
||||
void set2DPosV(float posV) { m2DPosV = posV; }
|
||||
bool isTempBit(int i_bit) { return mTempBits & (1 << i_bit); }
|
||||
void offSub2DStatus(int i_bit) { mSub2DStatus &= ~(1 << i_bit); }
|
||||
void onSub2DStatus(int i_bit) { mSub2DStatus |= 1 << i_bit; }
|
||||
void set2DWidth(f32 i_width) { m2DWidth = i_width; }
|
||||
void set2DHeight(f32 i_height) { m2DHeight = i_height; }
|
||||
void set2DPosH(f32 i_posH) { m2DPosH = i_posH; }
|
||||
void set2DPosV(f32 i_posV) { m2DPosV = i_posV; }
|
||||
void onUseButton(int i_button) { mUseButton |= i_button; }
|
||||
f32 get2DWidth() { return m2DWidth; }
|
||||
f32 get2DHeight() { return m2DHeight; }
|
||||
|
|
@ -195,10 +202,12 @@ public:
|
|||
u8 getGoldWolfMapType() { return mGoldWolfMapType; }
|
||||
bool isWindowAccept(int param_0) { return mWindowAccept & (1 << param_0); }
|
||||
void setHorseLifeCount(s16 i_count) { mHorseLifeCount = i_count; }
|
||||
void resetTouchKeyCheck() { mTouchKeyCheck = 0; }
|
||||
void resetWindowAccept() { mWindowAccept = 0xFFFF; }
|
||||
|
||||
public:
|
||||
/* 0x04 */ u8 unk4[4];
|
||||
/* 0x08 */ u64 unk8;
|
||||
/* 0x04 */ u8 unk_0x4[4];
|
||||
/* 0x08 */ u64 unk_0x8;
|
||||
/* 0x10 */ void* mMsgResource;
|
||||
/* 0x14 */ void* mStageMsgResource;
|
||||
/* 0x18 */ void* mMsgUnitResource;
|
||||
|
|
@ -207,25 +216,25 @@ public:
|
|||
/* 0x24 */ dMw_c* mMenuWindowClass;
|
||||
/* 0x28 */ CPaneMgr* mMeterItemPanePtr[4];
|
||||
/* 0x38 */ WarpInfo_c mWarpInfo;
|
||||
/* 0x54 */ f32 unk84;
|
||||
/* 0x58 */ f32 unk88;
|
||||
/* 0x5C */ f32 unk92;
|
||||
/* 0x60 */ f32 unk96;
|
||||
/* 0x64 */ f32 unk100;
|
||||
/* 0x68 */ f32 unk104;
|
||||
/* 0x6C */ f32 unk108;
|
||||
/* 0x54 */ f32 unk_0x54;
|
||||
/* 0x58 */ f32 unk_0x58;
|
||||
/* 0x5C */ f32 unk_0x5c;
|
||||
/* 0x60 */ f32 unk_0x60;
|
||||
/* 0x64 */ f32 unk_0x64;
|
||||
/* 0x68 */ f32 unk_0x68;
|
||||
/* 0x6C */ f32 unk_0x6c;
|
||||
/* 0x70 */ f32 m2DWidth;
|
||||
/* 0x74 */ f32 m2DHeight;
|
||||
/* 0x78 */ f32 m2DPosH;
|
||||
/* 0x7C */ f32 m2DPosV;
|
||||
/* 0x80 */ f32 unk128;
|
||||
/* 0x80 */ f32 unk_0x80;
|
||||
/* 0x84 */ s32 mTimeMs;
|
||||
/* 0x88 */ s32 mMsgTimeMs;
|
||||
/* 0x8C */ s32 mMeterString;
|
||||
/* 0x90 */ u32 mTempBits;
|
||||
/* 0x94 */ s16 mMsgKeyWaitTimer;
|
||||
/* 0x96 */ s16 mHorseLifeCount;
|
||||
/* 0x98 */ u16 unk152;
|
||||
/* 0x98 */ u16 unk_0x98;
|
||||
/* 0x9A */ u16 mHotSpringTimer[4];
|
||||
/* 0xA2 */ u16 mSub2DStatus;
|
||||
/* 0xA4 */ u16 mFloatingFlowID;
|
||||
|
|
@ -239,13 +248,12 @@ public:
|
|||
/* 0xB4 */ u16 mWindowAccept;
|
||||
/* 0xB6 */ u16 mOilGaugeBackUp;
|
||||
/* 0xB8 */ u8 mDirectUseItem;
|
||||
/* 0xB9 */ u8 mWindowStatus; // 0: normal play, 2: item wheel, 3: pause menu, 4: map, 10: pause
|
||||
// menu submenus, 11: map in dungeon
|
||||
/* 0xBA */ u8 unk186;
|
||||
/* 0xB9 */ u8 mWindowStatus; // 0: normal play, 2: item wheel, 3: pause menu, 4: map, 10: pause menu submenus, 11: map in dungeon
|
||||
/* 0xBA */ u8 unk_0xba;
|
||||
/* 0xBB */ u8 mMaxCount;
|
||||
/* 0xBC */ u8 mNowCount;
|
||||
/* 0xBD */ bool mShopTalkFlag;
|
||||
/* 0xBE */ u8 unk190;
|
||||
/* 0xBE */ u8 unk_0xbe;
|
||||
/* 0xBF */ u8 mMapStatus;
|
||||
/* 0xC0 */ u8 mWarpStatus;
|
||||
/* 0xC1 */ u8 mPauseStatus;
|
||||
|
|
@ -265,7 +273,7 @@ public:
|
|||
/* 0xDB */ u8 mSaveBombItemMG;
|
||||
/* 0xDC */ u8 mRentalBombBagIdx;
|
||||
/* 0xDD */ u8 mMiniGameItemSetFlag; // 1: rented in game, 3: rented not in game
|
||||
/* 0xDE */ u8 mMiniGameCount;
|
||||
/* 0xDE */ s8 mMiniGameCount;
|
||||
/* 0xDF */ u8 mCollectCursorPosX;
|
||||
/* 0xE0 */ u8 mCollectCursorPosY;
|
||||
/* 0xE1 */ u8 mTableMapRegionNo;
|
||||
|
|
@ -277,21 +285,28 @@ public:
|
|||
/* 0xE9 */ char mSaveStageName[8];
|
||||
/* 0xF1 */ bool mFloatingMessageWakuVisible;
|
||||
/* 0xF2 */ bool mMapDrugFlag;
|
||||
/* 0xF3 */ u8 unk243[5];
|
||||
/* 0xF3 */ u8 unk_0xf3[5];
|
||||
};
|
||||
|
||||
extern dMeter2Info_c g_meter2_info;
|
||||
|
||||
void dMeter2Info_setSword(u8, bool);
|
||||
void dMeter2Info_setCloth(u8 i_clothId, bool param_1);
|
||||
void dMeter2Info_setShield(u8 i_itemId, bool param_1);
|
||||
void dMeter2Info_setSword(u8 i_itemId, bool i_offItemBit);
|
||||
void dMeter2Info_setCloth(u8 i_clothId, bool i_offItemBit);
|
||||
void dMeter2Info_setShield(u8 i_itemId, bool i_offItemBit);
|
||||
void dMeter2Info_set2DVibration();
|
||||
void dMeter2Info_set2DVibrationM();
|
||||
void dMeter2Info_offUseButton(int pButton);
|
||||
bool dMeter2Info_is2DActiveTouchArea();
|
||||
u8 dMeter2Info_getRecieveLetterNum();
|
||||
bool dMeter2Info_getPixel(f32 param_0, f32 param_1, f32 param_2, f32 param_3, f32 param_4,
|
||||
f32 param_5, struct ResTIMG const* param_6);
|
||||
bool dMeter2Info_getPixel(f32 i_posX, f32 i_posY, f32 param_2, f32 param_3, f32 i_sizeX,
|
||||
f32 i_sizeY, struct ResTIMG const* i_resTimg);
|
||||
const char* dMeter2Info_getPlusTextureName();
|
||||
const char* dMeter2Info_getNumberTextureName(int i_num);
|
||||
int dMeter2Info_recieveLetter();
|
||||
u8 dMeter2Info_getNewLetterNum();
|
||||
int dMeter2Info_setNewLetterSender();
|
||||
bool dMeter2Info_isItemOpenCheck();
|
||||
bool dMeter2Info_isMapOpenCheck();
|
||||
|
||||
inline void dMeter2Info_Initialize() {
|
||||
g_meter2_info.init();
|
||||
|
|
@ -305,44 +320,44 @@ inline dMw_c* dMeter2Info_getMenuWindowClass() {
|
|||
return g_meter2_info.getMenuWindowClass();
|
||||
}
|
||||
|
||||
inline void dMeter2Info_setWindowStatus(u8 status) {
|
||||
g_meter2_info.setWindowStatus(status);
|
||||
inline void dMeter2Info_setWindowStatus(u8 i_status) {
|
||||
g_meter2_info.setWindowStatus(i_status);
|
||||
}
|
||||
|
||||
inline CPaneMgr* dMeter2Info_getMeterItemPanePtr(s32 i_idx) {
|
||||
return g_meter2_info.getMeterItemPanePtr(i_idx);
|
||||
}
|
||||
|
||||
inline void dMeter2Info_getString(u32 param_0, char* param_1, JMSMesgEntry_c* param_2) {
|
||||
g_meter2_info.getString(param_0, param_1, param_2);
|
||||
inline void dMeter2Info_getString(u32 i_stringID, char* o_string, JMSMesgEntry_c* i_msgEntry) {
|
||||
g_meter2_info.getString(i_stringID, o_string, i_msgEntry);
|
||||
}
|
||||
|
||||
inline void dMeter2Info_getStringKanji(u32 param_0, char* param_1, JMSMesgEntry_c* param_2) {
|
||||
g_meter2_info.getStringKanji(param_0, param_1, param_2);
|
||||
inline void dMeter2Info_getStringKanji(u32 i_stringID, char* o_string, JMSMesgEntry_c* i_msgEntry) {
|
||||
g_meter2_info.getStringKanji(i_stringID, o_string, i_msgEntry);
|
||||
}
|
||||
|
||||
inline void dMeter2Info_getStringKana(u32 param_0, char* param_1, JMSMesgEntry_c* param_2) {
|
||||
g_meter2_info.getStringKana(param_0, param_1, param_2);
|
||||
inline void dMeter2Info_getStringKana(u32 i_stringID, char* o_string, JMSMesgEntry_c* i_msgEntry) {
|
||||
g_meter2_info.getStringKana(i_stringID, o_string, i_msgEntry);
|
||||
}
|
||||
|
||||
inline f32 dMeter2Info_getStringLength(JUTFont* param_0, f32 param_1, f32 param_2, char* param_3) {
|
||||
return g_meter2_info.getStringLength(param_0, param_1, param_2, param_3);
|
||||
inline f32 dMeter2Info_getStringLength(JUTFont* i_font, f32 param_2, f32 param_3, char* i_string) {
|
||||
return g_meter2_info.getStringLength(i_font, param_2, param_3, i_string);
|
||||
}
|
||||
|
||||
inline f32 dMeter2Info_getStringLength(J2DTextBox* param_0, char* param_1) {
|
||||
return g_meter2_info.getStringLength(param_0, param_1);
|
||||
inline f32 dMeter2Info_getStringLength(J2DTextBox* i_textbox, char* i_string) {
|
||||
return g_meter2_info.getStringLength(i_textbox, i_string);
|
||||
}
|
||||
|
||||
inline void dMeter2Info_setHotSpringTimer(u8 time) {
|
||||
g_meter2_info.setHotSpringTimer(time);
|
||||
inline void dMeter2Info_setHotSpringTimer(u8 i_slotNo) {
|
||||
g_meter2_info.setHotSpringTimer(i_slotNo);
|
||||
}
|
||||
|
||||
inline u16 dMeter2Info_getOilGaugeBackUp() {
|
||||
return g_meter2_info.getOilGaugeBackUp();
|
||||
}
|
||||
|
||||
inline void dMeter2Info_setSaveStageName(const char* name) {
|
||||
g_meter2_info.setSaveStageName(name);
|
||||
inline void dMeter2Info_setSaveStageName(const char* i_stageName) {
|
||||
g_meter2_info.setSaveStageName(i_stageName);
|
||||
}
|
||||
|
||||
inline u8 dMeter2Info_getInsectSelectType() {
|
||||
|
|
@ -357,21 +372,20 @@ inline u8 dMeter2Info_getWarpStatus() {
|
|||
return g_meter2_info.getWarpStatus();
|
||||
}
|
||||
|
||||
inline void dMeter2Info_setWarpStatus(u8 status) {
|
||||
return g_meter2_info.setWarpStatus(status);
|
||||
inline void dMeter2Info_setWarpStatus(u8 i_status) {
|
||||
return g_meter2_info.setWarpStatus(i_status);
|
||||
}
|
||||
|
||||
inline int dMeter2Info_readItemTexture(u8 i_itemNo, void* param_1, J2DPicture* param_2,
|
||||
void* param_3, J2DPicture* param_4, void* param_5,
|
||||
J2DPicture* param_6, void* param_7, J2DPicture* param_8,
|
||||
int param_9) {
|
||||
return g_meter2_info.readItemTexture(i_itemNo, param_1, param_2, param_3, param_4, param_5,
|
||||
param_6, param_7, param_8, param_9);
|
||||
inline int dMeter2Info_readItemTexture(u8 i_itemNo, void* i_texBuf1, J2DPicture* i_pic1, void* i_texBuf2,
|
||||
J2DPicture* i_pic2, void* i_texBuf3, J2DPicture* i_pic3,
|
||||
void* i_texBuf4, J2DPicture* i_pic4, int param_9) {
|
||||
return g_meter2_info.readItemTexture(i_itemNo, i_texBuf1, i_pic1, i_texBuf2, i_pic2, i_texBuf3,
|
||||
i_pic3, i_texBuf4, i_pic4, param_9);
|
||||
}
|
||||
|
||||
inline void dMeter2Info_setItemColor(u8 param_0, J2DPicture* param_1, J2DPicture* param_2,
|
||||
J2DPicture* param_3, J2DPicture* param_4) {
|
||||
g_meter2_info.setItemColor(param_0, param_1, param_2, param_3, param_4);
|
||||
inline void dMeter2Info_setItemColor(u8 i_itemNo, J2DPicture* i_pic1, J2DPicture* i_pic2,
|
||||
J2DPicture* i_pic3, J2DPicture* i_pic4) {
|
||||
g_meter2_info.setItemColor(i_itemNo, i_pic1, i_pic2, i_pic3, i_pic4);
|
||||
}
|
||||
|
||||
inline u8 dMeter2Info_getWarpRoomNo() {
|
||||
|
|
@ -390,24 +404,24 @@ inline const char* dMeter2Info_getWarpStageName() {
|
|||
return g_meter2_info.getWarpStageName();
|
||||
}
|
||||
|
||||
inline void dMeter2Info_setNowCount(u8 count) {
|
||||
g_meter2_info.setNowCount(count);
|
||||
inline void dMeter2Info_setNowCount(u8 i_count) {
|
||||
g_meter2_info.setNowCount(i_count);
|
||||
}
|
||||
|
||||
inline void dMeter2Info_setMaxCount(u8 count) {
|
||||
g_meter2_info.setMaxCount(count);
|
||||
inline void dMeter2Info_setMaxCount(u8 i_count) {
|
||||
g_meter2_info.setMaxCount(i_count);
|
||||
}
|
||||
|
||||
inline BOOL dMeter2Info_isDirectUseItem(int param_0) {
|
||||
return g_meter2_info.isDirectUseItem(param_0);
|
||||
}
|
||||
|
||||
inline bool dMeter2Info_isUseButton(int param_0) {
|
||||
return g_meter2_info.isUseButton(param_0);
|
||||
inline bool dMeter2Info_isUseButton(int i_buttonBit) {
|
||||
return g_meter2_info.isUseButton(i_buttonBit);
|
||||
}
|
||||
|
||||
inline void dMeter2Info_setMeterMapClass(dMeterMap_c* p_map) {
|
||||
g_meter2_info.setMeterMapClass(p_map);
|
||||
inline void dMeter2Info_setMeterMapClass(dMeterMap_c* i_map) {
|
||||
g_meter2_info.setMeterMapClass(i_map);
|
||||
}
|
||||
|
||||
inline void dMeter2Info_decHotSpringTimer() {
|
||||
|
|
@ -418,28 +432,28 @@ inline void dMeter2Info_allUseButton() {
|
|||
g_meter2_info.allUseButton();
|
||||
}
|
||||
|
||||
inline void dMeter2Info_offUseButton(int flag) {
|
||||
g_meter2_info.offUseButton(flag);
|
||||
inline void dMeter2Info_offUseButton(int i_buttonBit) {
|
||||
g_meter2_info.offUseButton(i_buttonBit);
|
||||
}
|
||||
|
||||
inline void dMeter2Info_resetGameStatus() {
|
||||
g_meter2_info.resetGameStatus();
|
||||
}
|
||||
|
||||
inline void dMeter2Info_onGameStatus(int status) {
|
||||
g_meter2_info.onGameStatus(status);
|
||||
inline void dMeter2Info_onGameStatus(int i_status) {
|
||||
g_meter2_info.onGameStatus(i_status);
|
||||
}
|
||||
|
||||
inline void dMeter2Info_setMapStatus(u8 status) {
|
||||
g_meter2_info.setMapStatus(status);
|
||||
inline void dMeter2Info_setMapStatus(u8 i_status) {
|
||||
g_meter2_info.setMapStatus(i_status);
|
||||
}
|
||||
|
||||
inline u8 dMeter2Info_getMapStatus() {
|
||||
return g_meter2_info.getMapStatus();
|
||||
}
|
||||
|
||||
inline void dMeter2Info_setPauseStatus(u8 status) {
|
||||
g_meter2_info.setPauseStatus(status);
|
||||
inline void dMeter2Info_setPauseStatus(u8 i_status) {
|
||||
g_meter2_info.setPauseStatus(i_status);
|
||||
}
|
||||
|
||||
inline void dMeter2Info_resetPauseStatus() {
|
||||
|
|
@ -450,8 +464,8 @@ inline u8 dMeter2Info_getPauseStatus() {
|
|||
return g_meter2_info.getPauseStatus();
|
||||
}
|
||||
|
||||
inline bool dMeter2Info_isGameStatus(int status) {
|
||||
return g_meter2_info.isGameStatus(status);
|
||||
inline bool dMeter2Info_isGameStatus(int i_status) {
|
||||
return g_meter2_info.isGameStatus(i_status);
|
||||
}
|
||||
|
||||
inline bool dMeter2Info_isTouchKeyCheck(int i_status) {
|
||||
|
|
@ -463,24 +477,24 @@ inline bool dMeter2Info_isTouchKeyCheck_alt(int i_status) {
|
|||
return g_meter2_info.isTouchKeyCheck_alt(i_status);
|
||||
}
|
||||
|
||||
inline void dMeter2Info_setMapKeyDirection(u16 direction) {
|
||||
g_meter2_info.setMapKeyDirection(direction);
|
||||
inline void dMeter2Info_setMapKeyDirection(u16 i_direction) {
|
||||
g_meter2_info.setMapKeyDirection(i_direction);
|
||||
}
|
||||
|
||||
inline bool dMeter2Info_isSub2DStatus(int flag) {
|
||||
return g_meter2_info.isSub2DStatus(flag);
|
||||
inline bool dMeter2Info_isSub2DStatus(int i_flag) {
|
||||
return g_meter2_info.isSub2DStatus(i_flag);
|
||||
}
|
||||
|
||||
inline void dMeter2Info_offMenuInForce(int flag) {
|
||||
g_meter2_info.offMenuInForce(flag);
|
||||
inline void dMeter2Info_offMenuInForce(int i_flag) {
|
||||
g_meter2_info.offMenuInForce(i_flag);
|
||||
}
|
||||
|
||||
inline bool dMeter2Info_isMenuInForce(int flag) {
|
||||
return g_meter2_info.isMenuInForce(flag);
|
||||
inline bool dMeter2Info_isMenuInForce(int i_flag) {
|
||||
return g_meter2_info.isMenuInForce(i_flag);
|
||||
}
|
||||
|
||||
inline void dMeter2Info_setMenuWindowClass(dMw_c* p_menu) {
|
||||
g_meter2_info.setMenuWindowClass(p_menu);
|
||||
inline void dMeter2Info_setMenuWindowClass(dMw_c* i_menu) {
|
||||
g_meter2_info.setMenuWindowClass(i_menu);
|
||||
}
|
||||
|
||||
inline void dMeter2Info_resetWarpStatus() {
|
||||
|
|
@ -495,16 +509,16 @@ inline u8 dMeter2Info_getWindowStatus() {
|
|||
return g_meter2_info.getWindowStatus();
|
||||
}
|
||||
|
||||
inline void dMeter2Info_setMsgResource(void* res) {
|
||||
g_meter2_info.setMsgResource(res);
|
||||
inline void dMeter2Info_setMsgResource(void* i_res) {
|
||||
g_meter2_info.setMsgResource(i_res);
|
||||
}
|
||||
|
||||
inline void dMeter2Info_setStageMsgResource(void* res) {
|
||||
g_meter2_info.setStageMsgResource(res);
|
||||
inline void dMeter2Info_setStageMsgResource(void* i_res) {
|
||||
g_meter2_info.setStageMsgResource(i_res);
|
||||
}
|
||||
|
||||
inline void dMeter2Info_setMsgUnitResource(void* res) {
|
||||
g_meter2_info.setMsgUnitResource(res);
|
||||
inline void dMeter2Info_setMsgUnitResource(void* i_res) {
|
||||
g_meter2_info.setMsgUnitResource(i_res);
|
||||
}
|
||||
|
||||
inline void* dMeter2Info_getMsgResource() {
|
||||
|
|
@ -519,16 +533,16 @@ inline void* dMeter2Info_getMsgUnitResource() {
|
|||
return g_meter2_info.getMsgUnitResource();
|
||||
}
|
||||
|
||||
inline u8 dMeter2Info_getLightDropGetFlag(int i) {
|
||||
return g_meter2_info.getLightDropGetFlag(i);
|
||||
inline u8 dMeter2Info_getLightDropGetFlag(int i_no) {
|
||||
return g_meter2_info.getLightDropGetFlag(i_no);
|
||||
}
|
||||
|
||||
inline s32 dMeter2Info_getMeterStringType() {
|
||||
return g_meter2_info.getMeterStringType();
|
||||
}
|
||||
|
||||
inline void dMeter2Info_setMeterClass(dMeter2_c* meter) {
|
||||
g_meter2_info.setMeterClass(meter);
|
||||
inline void dMeter2Info_setMeterClass(dMeter2_c* i_meter) {
|
||||
g_meter2_info.setMeterClass(i_meter);
|
||||
}
|
||||
|
||||
inline void dMeter2Info_onLifeGaugeSE() {
|
||||
|
|
@ -551,8 +565,8 @@ inline void dMeter2Info_onShopTalkFlag() {
|
|||
g_meter2_info.onShopTalkFlag();
|
||||
}
|
||||
|
||||
inline void dMeter2Info_setLightDropGetFlag(int index, u8 flag) {
|
||||
g_meter2_info.setLightDropGetFlag(index, flag);
|
||||
inline void dMeter2Info_setLightDropGetFlag(int i_no, u8 i_flag) {
|
||||
g_meter2_info.setLightDropGetFlag(i_no, i_flag);
|
||||
}
|
||||
|
||||
inline u8 dMeter2Info_getRentalBombBag() {
|
||||
|
|
@ -563,24 +577,24 @@ inline u8 dMeter2Info_getMiniGameItemSetFlag() {
|
|||
return g_meter2_info.getMiniGameItemSetFlag();
|
||||
}
|
||||
|
||||
inline void dMeter2Info_setMiniGameItem(u8 item) {
|
||||
g_meter2_info.setMiniGameItem(item);
|
||||
inline void dMeter2Info_setMiniGameItem(u8 i_minigameFlag) {
|
||||
g_meter2_info.setMiniGameItem(i_minigameFlag);
|
||||
}
|
||||
|
||||
inline void dMeter2Info_resetMiniGameItem(bool param_0) {
|
||||
g_meter2_info.resetMiniGameItem(param_0);
|
||||
inline void dMeter2Info_resetMiniGameItem(bool i_saveItem) {
|
||||
g_meter2_info.resetMiniGameItem(i_saveItem);
|
||||
}
|
||||
|
||||
inline void dMeter2Info_setTableMapRegionNo(u8 regionNo) {
|
||||
g_meter2_info.setTableMapRegionNo(regionNo);
|
||||
inline void dMeter2Info_setTableMapRegionNo(u8 i_regionNo) {
|
||||
g_meter2_info.setTableMapRegionNo(i_regionNo);
|
||||
}
|
||||
|
||||
inline void dMeter2Info_setGoldWolfMapType(u8 i_mapType) {
|
||||
g_meter2_info.setGoldWolfMapType(i_mapType);
|
||||
}
|
||||
|
||||
inline void dMeter2Info_changeWater(u8 bottleIdx) {
|
||||
g_meter2_info.changeWater(bottleIdx);
|
||||
inline void dMeter2Info_changeWater(u8 i_slotNo) {
|
||||
g_meter2_info.changeWater(i_slotNo);
|
||||
}
|
||||
|
||||
inline void dMeter2Info_warpInProc() {
|
||||
|
|
@ -603,8 +617,8 @@ inline void dMeter2Info_onDirectUseItem(int param_0) {
|
|||
g_meter2_info.onDirectUseItem(param_0);
|
||||
}
|
||||
|
||||
inline void dMeter2Info_setFloatingFlow(u16 param_0, s16 param_1, bool param_2) {
|
||||
g_meter2_info.setFloatingFlow(param_0, param_1, param_2);
|
||||
inline void dMeter2Info_setFloatingFlow(u16 i_flowID, s16 i_msgTimer, bool i_wakuVisible) {
|
||||
g_meter2_info.setFloatingFlow(i_flowID, i_msgTimer, i_wakuVisible);
|
||||
}
|
||||
|
||||
inline u8 dMeter2Info_getGameOverType() {
|
||||
|
|
@ -627,8 +641,8 @@ inline s32 dMeter2Info_getTimeMs() {
|
|||
return g_meter2_info.getTimeMs();
|
||||
}
|
||||
|
||||
inline void dMeter2Info_setMsgTimeMs(s32 msgTime) {
|
||||
g_meter2_info.setMsgTimeMs(msgTime);
|
||||
inline void dMeter2Info_setMsgTimeMs(s32 i_msgTime) {
|
||||
g_meter2_info.setMsgTimeMs(i_msgTime);
|
||||
}
|
||||
|
||||
inline void dMeter2Info_setTimeMs(s32 i_time) {
|
||||
|
|
@ -731,36 +745,36 @@ inline bool dMeter2Info_isShopTalkFlag() {
|
|||
return g_meter2_info.isShopTalkFlag();
|
||||
}
|
||||
|
||||
inline void dMeter2Info_setMapDrugFlag(bool flag) {
|
||||
g_meter2_info.setMapDrugFlag(flag);
|
||||
inline void dMeter2Info_setMapDrugFlag(bool i_flag) {
|
||||
g_meter2_info.setMapDrugFlag(i_flag);
|
||||
}
|
||||
|
||||
inline bool dMeter2Info_isTempBit(int bit) {
|
||||
return g_meter2_info.isTempBit(bit);
|
||||
inline bool dMeter2Info_isTempBit(int i_bit) {
|
||||
return g_meter2_info.isTempBit(i_bit);
|
||||
}
|
||||
|
||||
inline void dMeter2Info_offSub2DStatus(int bit) {
|
||||
g_meter2_info.offSub2DStatus(bit);
|
||||
inline void dMeter2Info_offSub2DStatus(int i_bit) {
|
||||
g_meter2_info.offSub2DStatus(i_bit);
|
||||
}
|
||||
|
||||
inline void dMeter2Info_onSub2DStatus(int bit) {
|
||||
g_meter2_info.onSub2DStatus(bit);
|
||||
inline void dMeter2Info_onSub2DStatus(int i_bit) {
|
||||
g_meter2_info.onSub2DStatus(i_bit);
|
||||
}
|
||||
|
||||
inline void dMeter2Info_set2DWidth(float width) {
|
||||
g_meter2_info.set2DWidth(width);
|
||||
inline void dMeter2Info_set2DWidth(f32 i_width) {
|
||||
g_meter2_info.set2DWidth(i_width);
|
||||
}
|
||||
|
||||
inline void dMeter2Info_set2DHeight(float height) {
|
||||
g_meter2_info.set2DHeight(height);
|
||||
inline void dMeter2Info_set2DHeight(f32 i_height) {
|
||||
g_meter2_info.set2DHeight(i_height);
|
||||
}
|
||||
|
||||
inline void dMeter2Info_set2DPosH(float posH) {
|
||||
g_meter2_info.set2DPosH(posH);
|
||||
inline void dMeter2Info_set2DPosH(f32 i_posH) {
|
||||
g_meter2_info.set2DPosH(i_posH);
|
||||
}
|
||||
|
||||
inline void dMeter2Info_set2DPosV(float posV) {
|
||||
g_meter2_info.set2DPosV(posV);
|
||||
inline void dMeter2Info_set2DPosV(f32 i_posV) {
|
||||
g_meter2_info.set2DPosV(i_posV);
|
||||
}
|
||||
|
||||
inline void dMeter2Info_offShopTalkFlag() {
|
||||
|
|
@ -780,7 +794,7 @@ inline f32 dMeter2Info_get2DHeight() {
|
|||
}
|
||||
|
||||
inline void dMeter2Info_setWarpInfo(const char* i_stageName, const cXyz& i_position, s16 i_angle,
|
||||
u8 i_roomNo, u8 param_4, u8 i_warpPlayerNo) {
|
||||
u8 i_roomNo, u8 param_4, u8 i_warpPlayerNo) {
|
||||
g_meter2_info.setWarpInfo(i_stageName, i_position, i_angle, i_roomNo, param_4, i_warpPlayerNo);
|
||||
}
|
||||
|
||||
|
|
@ -812,20 +826,12 @@ inline bool dMeter2Info_isNextStage(const char*, s16, s16, s16) {
|
|||
return false;
|
||||
}
|
||||
|
||||
inline void dMeter2Info_setFloatingMessage(u16 pMessageID, s16 pMessageTimer, bool pWakuVisible) {
|
||||
g_meter2_info.setFloatingMessage(pMessageID, pMessageTimer, pWakuVisible);
|
||||
inline void dMeter2Info_setFloatingMessage(u16 i_msgID, s16 i_msgTimer, bool i_wakuVisible) {
|
||||
g_meter2_info.setFloatingMessage(i_msgID, i_msgTimer, i_wakuVisible);
|
||||
}
|
||||
|
||||
inline void dMeter2Info_setMiniGameCount(s8 i_count) {
|
||||
g_meter2_info.setMiniGameCount(i_count);
|
||||
}
|
||||
|
||||
const char* dMeter2Info_getPlusTextureName();
|
||||
const char* dMeter2Info_getNumberTextureName(int pIndex);
|
||||
int dMeter2Info_recieveLetter();
|
||||
u8 dMeter2Info_getNewLetterNum();
|
||||
int dMeter2Info_setNewLetterSender();
|
||||
bool dMeter2Info_isItemOpenCheck();
|
||||
bool dMeter2Info_isMapOpenCheck();
|
||||
|
||||
#endif /* D_METER_D_METER2_INFO_H */
|
||||
|
|
|
|||
|
|
@ -2,37 +2,40 @@
|
|||
#define D_MSG_D_MSG_CLASS_H
|
||||
|
||||
#include "JSystem/JMessage/control.h"
|
||||
#include "JSystem/JMessage/JMessage.h"
|
||||
#include "SSystem/SComponent/c_xyz.h"
|
||||
|
||||
class JMSMesgEntry_c {
|
||||
public:
|
||||
/* 0x0 */ u32 string_offset;
|
||||
|
||||
// Attributes
|
||||
/* 0x04 */ u16 message_id;
|
||||
/* 0x06 */ u16 unk_0x6;
|
||||
/* 0x08 */ u8 unk_0x8;
|
||||
/* 0x09 */ u8 display_style;
|
||||
/* 0x0A */ u8 print_style;
|
||||
/* 0x0B */ u8 position;
|
||||
/* 0x0C */ u8 unk_0xc;
|
||||
/* 0x0D */ u8 unk_0xd;
|
||||
/* 0x0E */ u8 unk_0xe;
|
||||
/* 0x0F */ u8 camera_id;
|
||||
/* 0x10 */ u32 unk_0x10;
|
||||
};
|
||||
|
||||
class JMSMesgInfo_c {
|
||||
public:
|
||||
/* 0x00 */ bmg_section_t header; // section header
|
||||
/* 0x08 */ u16 entry_num; // number of entries in this section
|
||||
/* 0x0A */ u16 entry_size; // size of an entry
|
||||
/* 0x0C */ u8 padding[4]; // padding
|
||||
/* 0x10 */ JMSMesgEntry_c entries[0];
|
||||
};
|
||||
|
||||
class COutFont_c;
|
||||
class J2DTextBox;
|
||||
class JUTFont;
|
||||
|
||||
struct JMSMesgEntry_c {
|
||||
/* 0x00 */ u32 mStringOffset;
|
||||
/* 0x04 */ u16 mStringId;
|
||||
/* 0x06 */ u16 field_0x06;
|
||||
/* 0x08 */ u8 field_0x08;
|
||||
/* 0x09 */ u8 field_0x09;
|
||||
/* 0x0A */ u8 field_0x0a;
|
||||
/* 0x0B */ u8 field_0x0b;
|
||||
/* 0x0C */ u8 field_0x0c;
|
||||
/* 0x0D */ u8 field_0x0d;
|
||||
/* 0x0E */ u8 field_0x0e;
|
||||
/* 0x0F */ u8 field_0x0f;
|
||||
/* 0x10 */ u32 field_0x10;
|
||||
}; // Size: 0x14
|
||||
|
||||
struct JMSMesgHeader_c {
|
||||
/* 0x00 */ u32 magic;
|
||||
/* 0x04 */ u32 sectionSize;
|
||||
/* 0x08 */ u16 entryCount;
|
||||
/* 0x0A */ u16 entrySize;
|
||||
/* 0x0C */ u16 field_0xc;
|
||||
/* 0x0E */ u16 field_0xe;
|
||||
/* 0x10 */ JMSMesgEntry_c entries[0];
|
||||
}; // Size: 0x10
|
||||
|
||||
class STControl;
|
||||
class dMsgObject_c;
|
||||
struct jmessage_tReference : public JMessage::TReference {
|
||||
|
|
|
|||
|
|
@ -1,48 +1,7 @@
|
|||
#ifndef D_MSG_D_MSG_UNIT_H
|
||||
#define D_MSG_D_MSG_UNIT_H
|
||||
|
||||
#include "global.h"
|
||||
|
||||
// Struct definitions might be wrong
|
||||
typedef struct bmg_section_t {
|
||||
u32 msgType; // sectionType
|
||||
u32 size; // total size of the section
|
||||
u8 data[0]; // section data
|
||||
} bmg_section_t;
|
||||
|
||||
typedef struct bmg_header_t {
|
||||
/* 0x00 */ char magic[8]; // = BMG_MAGIC
|
||||
/* 0x08 */ u32 size; // total size of file
|
||||
/* 0x0c */ u32 n_sections; // number of sections
|
||||
/* 0x10 */ u32 encoding; // text encoding
|
||||
/* 0x11 */ u8 unknown[12]; // unknown data
|
||||
/* 0x20 */ bmg_section_t section[0]; // first section header
|
||||
} bmg_header_t;
|
||||
|
||||
typedef struct inf1_entry_t {
|
||||
u32 dat1EntryOffset;
|
||||
u16 startFrame;
|
||||
u16 endFrame;
|
||||
} inf1_entry_t;
|
||||
|
||||
typedef struct inf1_section_t {
|
||||
/* 0x00 */ u32 msgType; // sectionType
|
||||
/* 0x04 */ u32 size; // total size of the section
|
||||
/* 0x08 */ u16 entryCount;
|
||||
/* 0x0A */ u16 entryLength;
|
||||
/* 0x0C */ u16 msgArchiveId;
|
||||
/* 0x0E */ inf1_entry_t entries[0];
|
||||
} inf1_section_t;
|
||||
|
||||
typedef struct str1_entry_t {
|
||||
char str[0];
|
||||
} str1_entry_t;
|
||||
|
||||
typedef struct str1_section_t {
|
||||
/* 0x00 */ u32 msgType; // sectionType
|
||||
/* 0x04 */ u32 size; // total size of the section
|
||||
/* 0x08 */ str1_entry_t entries[0];
|
||||
} str1_section_t;
|
||||
#include "JSystem/JMessage/JMessage.h"
|
||||
|
||||
class dMsgUnit_c {
|
||||
public:
|
||||
|
|
|
|||
|
|
@ -5,6 +5,7 @@
|
|||
|
||||
#include "JSystem/JMessage/resource.h"
|
||||
#include "JSystem/JGadget/search.h"
|
||||
#include "JSystem/JGadget/define.h"
|
||||
#include <algorithm.h>
|
||||
#include "string.h"
|
||||
|
||||
|
|
@ -205,8 +206,73 @@ bool JMessage::TParse::parseHeader_next(void const** ppData_inout, u32* puBlock_
|
|||
|
||||
/* 802A92F4-802A9490 2A3C34 019C+00 1/0 0/0 0/0 .text
|
||||
* parseBlock_next__Q28JMessage6TParseFPPCvPUlUl */
|
||||
bool JMessage::TParse::parseBlock_next(void const** param_0, u32* param_1, u32 param_2) {
|
||||
// NONMATCHING
|
||||
bool JMessage::TParse::parseBlock_next(void const** ppData_inout, u32* puData_out, u32 param_2) {
|
||||
JUT_ASSERT(401, ppData_inout!=0);
|
||||
JUT_ASSERT(402, puData_out!=0);
|
||||
|
||||
const void* pData = *ppData_inout;
|
||||
JUT_ASSERT(404, pData!=0);
|
||||
|
||||
data::TParse_TBlock sp34(pData);
|
||||
|
||||
*ppData_inout = sp34.getNext();
|
||||
*puData_out = sp34.get_size();
|
||||
|
||||
TResourceContainer::TCResource& rcResource = pContainer_->resContainer_;
|
||||
JUT_ASSERT(412, pResource_==&*--(rcResource.end()));
|
||||
|
||||
u32 sp30 = sp34.get_type();
|
||||
switch (sp30) {
|
||||
case 'INF1':
|
||||
pResource_->setData_block_info(pData);
|
||||
break;
|
||||
case 'FLI1':
|
||||
break;
|
||||
case 'FLW1':
|
||||
break;
|
||||
case 'DAT1':
|
||||
pResource_->setData_block_messageText(pData);
|
||||
u16 temp_r26 = pResource_->getGroupID();
|
||||
|
||||
if (param_2 & 0x80) {
|
||||
JGadget::TLinkList<JMessage::TResource, 0>::iterator sp2C(rcResource.begin());
|
||||
JMessage::TResource* sp28;
|
||||
while ((sp28 = &*sp2C) != pResource_) {
|
||||
if ((u16)temp_r26 != sp28->getGroupID()) {
|
||||
++sp2C;
|
||||
} else {
|
||||
sp2C = rcResource.Erase_destroy(sp28);
|
||||
}
|
||||
}
|
||||
} else {
|
||||
#ifdef DEBUG
|
||||
JMessage::TResource* sp24 = rcResource.Get_groupID(temp_r26);
|
||||
if (sp24 != pResource_) {
|
||||
JGadget_outMessage sp148(JGadget_outMessage::warning, __FILE__, 444);
|
||||
sp148 << "group-ID already exist : " << temp_r26;
|
||||
}
|
||||
#endif
|
||||
}
|
||||
break;
|
||||
case 'STR1':
|
||||
pResource_->setData_block_stringAttribute(pData);
|
||||
break;
|
||||
case 'MID1':
|
||||
pResource_->setData_block_messageID(pData);
|
||||
break;
|
||||
default:
|
||||
#ifdef DEBUG
|
||||
JGadget_outMessage sp148(JGadget_outMessage::warning, __FILE__, 463);
|
||||
sp148 << "unknown block : " << sp30;
|
||||
#endif
|
||||
|
||||
if (!(param_2 & 0x40)) {
|
||||
return 0;
|
||||
}
|
||||
break;
|
||||
}
|
||||
|
||||
return 1;
|
||||
}
|
||||
|
||||
/* 802A9490-802A94A8 2A3DD0 0018+00 1/0 0/0 0/0 .text
|
||||
|
|
|
|||
|
|
@ -684,7 +684,7 @@ extern actor_process_profile_definition g_profile_BALLOON2D = {
|
|||
fpcPi_CURRENT_e, // mListPrio
|
||||
PROC_BALLOON2D, // mProcName
|
||||
&g_fpcLf_Method.base, // sub_method
|
||||
sizeof(JMSMesgEntry_c), // mSize
|
||||
sizeof(daBalloon2D_c), // mSize
|
||||
0, // mSizeOther
|
||||
0, // mParameters
|
||||
&g_fopAc_Method.base, // sub_method
|
||||
|
|
|
|||
|
|
@ -3346,7 +3346,7 @@ char* dMeter2Draw_c::getActionString(u8 i_action, u8 i_type, u8* param_2) {
|
|||
}
|
||||
|
||||
if (param_2 != NULL) {
|
||||
*param_2 = mesg_entry.field_0x0a;
|
||||
*param_2 = mesg_entry.print_style;
|
||||
|
||||
if (g_drawHIO.mButtonATextActionID == 0x3E6) {
|
||||
*param_2 = 7;
|
||||
|
|
@ -3363,7 +3363,7 @@ char* dMeter2Draw_c::getActionString(u8 i_action, u8 i_type, u8* param_2) {
|
|||
}
|
||||
|
||||
if (param_2 != NULL) {
|
||||
*param_2 = mesg_entry.field_0x0a;
|
||||
*param_2 = mesg_entry.print_style;
|
||||
|
||||
if (i_action_num[i_action] == 0x3E6) {
|
||||
*param_2 = 7;
|
||||
|
|
|
|||
File diff suppressed because it is too large
Load Diff
|
|
@ -620,9 +620,9 @@ void dMsgObject_c::setMessageIndex(u32 param_1, u32 param_2, bool param_3) {
|
|||
field_0x172 = 0;
|
||||
mpRefer->setPageNum(field_0x172);
|
||||
|
||||
JMSMesgHeader_c* pMsg = (JMSMesgHeader_c*)((char*)mpMsgDt + 0x20);
|
||||
u8* iVar2 = (u8*)pMsg + pMsg->sectionSize;
|
||||
dComIfGp_setMesgCameraAttrInfo(pMsg->entries[getMessageIndex(revoIndex)].field_0x0f);
|
||||
JMSMesgInfo_c* pMsg = (JMSMesgInfo_c*)((char*)mpMsgDt + 0x20);
|
||||
u8* iVar2 = (u8*)pMsg + pMsg->header.size;
|
||||
dComIfGp_setMesgCameraAttrInfo(pMsg->entries[getMessageIndex(revoIndex)].camera_id);
|
||||
if (field_0x15c == 1000) {
|
||||
mpRefer->setSelMsgPtr(NULL);
|
||||
} else {
|
||||
|
|
@ -630,7 +630,7 @@ void dMsgObject_c::setMessageIndex(u32 param_1, u32 param_2, bool param_3) {
|
|||
if (msgIndex == 0x264) {
|
||||
mpRefer->setSelMsgPtr(NULL);
|
||||
} else {
|
||||
mpRefer->setSelMsgPtr(((char*)iVar2 + pMsg->entries[msgIndex].mStringOffset + 8));
|
||||
mpRefer->setSelMsgPtr(((char*)iVar2 + pMsg->entries[msgIndex].string_offset + 8));
|
||||
}
|
||||
}
|
||||
if (param_3) {
|
||||
|
|
@ -659,10 +659,10 @@ void dMsgObject_c::setMessageIndexDemo(u32 param_1, bool param_2) {
|
|||
changeGroup(groupID);
|
||||
field_0x172 = 0;
|
||||
mpRefer->setPageNum(field_0x172);
|
||||
JMSMesgHeader_c* info_header_p = (JMSMesgHeader_c*)((char*)mpMsgDt + 0x20);
|
||||
JMSMesgInfo_c* info_header_p = (JMSMesgInfo_c*)((char*)mpMsgDt + 0x20);
|
||||
int ind = getMessageIndex(revoMsgIndex);
|
||||
JMSMesgEntry_c* info_entries = (JMSMesgEntry_c*)((char*)info_header_p + 0x10);
|
||||
dComIfGp_setMesgCameraAttrInfo(info_entries[ind].field_0x0f);
|
||||
dComIfGp_setMesgCameraAttrInfo(info_entries[ind].camera_id);
|
||||
mpRefer->setSelMsgPtr(NULL);
|
||||
if (param_2) {
|
||||
mpCtrl->setMessageID(mMessageID, 0, NULL);
|
||||
|
|
@ -673,11 +673,11 @@ void dMsgObject_c::setMessageIndexDemo(u32 param_1, bool param_2) {
|
|||
*/
|
||||
u32 dMsgObject_c::getMessageIndex(u32 param_0) {
|
||||
u32 i = 0;
|
||||
JMSMesgHeader_c* pMsg = (JMSMesgHeader_c*)((char*)mpMsgDt + 0x20);
|
||||
JMSMesgInfo_c* pMsg = (JMSMesgInfo_c*)((char*)mpMsgDt + 0x20);
|
||||
u32 msgIndexCount = *((u16*)((char*)mpMsgDt + 0x28));
|
||||
int rv;
|
||||
for (; i < msgIndexCount; i++) {
|
||||
if (pMsg->entries[i].mStringId == param_0) {
|
||||
if (pMsg->entries[i].message_id == param_0) {
|
||||
rv = i;
|
||||
break;
|
||||
}
|
||||
|
|
@ -695,19 +695,19 @@ u32 dMsgObject_c::getRevoMessageIndex(u32 param_1) {
|
|||
return param_1;
|
||||
}
|
||||
u32 msgIndexCount;
|
||||
JMSMesgHeader_c* pMsg;
|
||||
JMSMesgInfo_c* pMsg;
|
||||
int i = 0;
|
||||
int rv;
|
||||
s16 groupID = getMessageGroup(param_1);
|
||||
JUT_ASSERT(1916, groupID==s_groupID || groupID == 0)
|
||||
changeGroup(groupID);
|
||||
pMsg = (JMSMesgHeader_c*)((char*)mpMsgDt + 0x20);
|
||||
pMsg = (JMSMesgInfo_c*)((char*)mpMsgDt + 0x20);
|
||||
msgIndexCount = *((u16*)((char*)mpMsgDt + 0x28));
|
||||
for (; i < msgIndexCount; i++) {
|
||||
if (pMsg->entries[i].mStringId == param_1) {
|
||||
s8* ptr = (s8*)pMsg + pMsg->sectionSize + pMsg->entries[i].mStringOffset + 8;
|
||||
if (pMsg->entries[i].message_id == param_1) {
|
||||
s8* ptr = (s8*)pMsg + pMsg->header.size + pMsg->entries[i].string_offset + 8;
|
||||
if (ptr[0] == 26 && ptr[2] == 3 && (s8)ptr[4] == 0) {
|
||||
rv = pMsg->entries[*(int*)(ptr + 5)].mStringId;
|
||||
rv = pMsg->entries[*(int*)(ptr + 5)].message_id;
|
||||
} else {
|
||||
rv = param_1;
|
||||
}
|
||||
|
|
@ -725,11 +725,11 @@ u32 dMsgObject_c::getRevoMessageIndex(u32 param_1) {
|
|||
/* 802340D4-80234128 22EA14 0054+00 3/3 0/0 0/0 .text getMessageIndexAlways__12dMsgObject_cFUl */
|
||||
u32 dMsgObject_c::getMessageIndexAlways(u32 param_0) {
|
||||
u32 i = 0;
|
||||
JMSMesgHeader_c* pMsg = (JMSMesgHeader_c*)((char*)mpMsgRes + 0x20);
|
||||
JMSMesgInfo_c* pMsg = (JMSMesgInfo_c*)((char*)mpMsgRes + 0x20);
|
||||
u32 msgIndexCount = *((u16*)((char*)mpMsgRes + 0x28));
|
||||
int rv;
|
||||
for (; i < msgIndexCount; i++) {
|
||||
if (pMsg->entries[i].mStringId == param_0) {
|
||||
if (pMsg->entries[i].message_id == param_0) {
|
||||
rv = i;
|
||||
break;
|
||||
}
|
||||
|
|
@ -743,7 +743,7 @@ u32 dMsgObject_c::getMessageIndexAlways(u32 param_0) {
|
|||
|
||||
/* 80234128-8023413C 22EA68 0014+00 1/1 0/0 0/0 .text getMessageIDAlways__12dMsgObject_cFUl */
|
||||
u32 dMsgObject_c::getMessageIDAlways(u32 param_0) {
|
||||
return ((JMSMesgHeader_c*)((u8*)mpMsgRes + 0x20))->entries[param_0].mStringId;
|
||||
return ((JMSMesgInfo_c*)((u8*)mpMsgRes + 0x20))->entries[param_0].message_id;
|
||||
}
|
||||
|
||||
/* 8023413C-80234150 22EA7C 0014+00 4/4 0/0 0/0 .text getMessageGroup__12dMsgObject_cFUl
|
||||
|
|
@ -1859,22 +1859,22 @@ bool dMsgObject_c::isTalkMessage() {
|
|||
|
||||
/* 802372CC-80237334 231C0C 0068+00 0/0 5/5 0/0 .text getSmellName__12dMsgObject_cFv */
|
||||
const char* dMsgObject_c::getSmellName() {
|
||||
JMSMesgHeader_c* info_header_p = (JMSMesgHeader_c*)((char*)mpMsgRes + 0x20);
|
||||
char* data_ptr = (char*)info_header_p + info_header_p->sectionSize;
|
||||
JMSMesgInfo_c* info_header_p = (JMSMesgInfo_c*)((char*)mpMsgRes + 0x20);
|
||||
char* data_ptr = (char*)info_header_p + info_header_p->header.size;
|
||||
JMSMesgEntry_c* info_entries = (JMSMesgEntry_c*)((char*)info_header_p + 0x10);
|
||||
|
||||
JMSMesgEntry_c* msg_entry = &info_entries[(u16)getMessageIndex(getSmellTypeMessageID())];
|
||||
return data_ptr + msg_entry->mStringOffset + 8;
|
||||
return data_ptr + msg_entry->string_offset + 8;
|
||||
}
|
||||
|
||||
/* 80237334-8023738C 231C74 0058+00 0/0 5/5 0/0 .text getPortalName__12dMsgObject_cFv */
|
||||
const char* dMsgObject_c::getPortalName() {
|
||||
JMSMesgHeader_c* info_header_p = (JMSMesgHeader_c*)((char*)mpMsgRes + 0x20);
|
||||
char* data_ptr = (char*)info_header_p + info_header_p->sectionSize;
|
||||
JMSMesgInfo_c* info_header_p = (JMSMesgInfo_c*)((char*)mpMsgRes + 0x20);
|
||||
char* data_ptr = (char*)info_header_p + info_header_p->header.size;
|
||||
JMSMesgEntry_c* info_entries = (JMSMesgEntry_c*)((char*)info_header_p + 0x10);
|
||||
|
||||
JMSMesgEntry_c* msg_entry = &info_entries[getMessageIndex(getPortalMessageID())];
|
||||
return data_ptr + msg_entry->mStringOffset + 8;
|
||||
return data_ptr + msg_entry->string_offset + 8;
|
||||
}
|
||||
|
||||
/* 8023738C-8023741C 231CCC 0090+00 0/0 5/5 0/0 .text getBombName__12dMsgObject_cFv */
|
||||
|
|
@ -1888,32 +1888,32 @@ const char* dMsgObject_c::getBombName() {
|
|||
i_cursorPos = i_selectPos;
|
||||
}
|
||||
JUT_ASSERT(4083, i_cursorPos >= 0 && i_cursorPos < dSv_player_item_c::BOMB_BAG_MAX);
|
||||
JMSMesgHeader_c* info_header_p = (JMSMesgHeader_c*)((char*)mpMsgRes + 0x20);
|
||||
char* data_ptr = (char*)info_header_p + info_header_p->sectionSize;
|
||||
JMSMesgInfo_c* info_header_p = (JMSMesgInfo_c*)((char*)mpMsgRes + 0x20);
|
||||
char* data_ptr = (char*)info_header_p + info_header_p->header.size;
|
||||
JMSMesgEntry_c* info_entries = (JMSMesgEntry_c*)((char*)info_header_p + 0x10);
|
||||
|
||||
JMSMesgEntry_c* msg_entry = &info_entries[getMessageIndexAlways(getBombMessageIDLocal(i_cursorPos) + 0x165)];
|
||||
return data_ptr + msg_entry->mStringOffset + 8;
|
||||
return data_ptr + msg_entry->string_offset + 8;
|
||||
}
|
||||
|
||||
/* 8023741C-80237478 231D5C 005C+00 0/0 5/5 0/0 .text getInsectName__12dMsgObject_cFv */
|
||||
const char* dMsgObject_c::getInsectName() {
|
||||
JMSMesgHeader_c* info_header_p = (JMSMesgHeader_c*)((char*)mpMsgRes + 0x20);
|
||||
char* data_ptr = (char*)info_header_p + info_header_p->sectionSize;
|
||||
JMSMesgInfo_c* info_header_p = (JMSMesgInfo_c*)((char*)mpMsgRes + 0x20);
|
||||
char* data_ptr = (char*)info_header_p + info_header_p->header.size;
|
||||
JMSMesgEntry_c* info_entries = (JMSMesgEntry_c*)((char*)info_header_p + 0x10);
|
||||
|
||||
JMSMesgEntry_c* msg_entry = &info_entries[getMessageIndexAlways(getInsectItemNoLocal() + 0x165)];
|
||||
return data_ptr + msg_entry->mStringOffset + 8;
|
||||
return data_ptr + msg_entry->string_offset + 8;
|
||||
}
|
||||
|
||||
/* 80237478-802374D0 231DB8 0058+00 0/0 5/5 0/0 .text getLetterName__12dMsgObject_cFv */
|
||||
const char* dMsgObject_c::getLetterName() {
|
||||
JMSMesgHeader_c* info_header_p = (JMSMesgHeader_c*)((char*)mpMsgRes + 0x20);
|
||||
char* data_ptr = (char*)info_header_p + info_header_p->sectionSize;
|
||||
JMSMesgInfo_c* info_header_p = (JMSMesgInfo_c*)((char*)mpMsgRes + 0x20);
|
||||
char* data_ptr = (char*)info_header_p + info_header_p->header.size;
|
||||
JMSMesgEntry_c* info_entries = (JMSMesgEntry_c*)((char*)info_header_p + 0x10);
|
||||
|
||||
JMSMesgEntry_c* msg_entry = &info_entries[getMessageIndexAlways(getLetterNameIDLocal())];
|
||||
return data_ptr + msg_entry->mStringOffset + 8;
|
||||
return data_ptr + msg_entry->string_offset + 8;
|
||||
}
|
||||
|
||||
/* 802374D0-80237520 231E10 0050+00 1/1 5/5 0/0 .text getSelectBombNum__12dMsgObject_cFv
|
||||
|
|
|
|||
|
|
@ -9,6 +9,22 @@
|
|||
#include "d/d_kankyo.h"
|
||||
#include "d/d_meter2_info.h"
|
||||
|
||||
// temporary until a better solution is found
|
||||
typedef struct dMsgUnit_inf1_entry {
|
||||
u32 dat1EntryOffset;
|
||||
u16 startFrame;
|
||||
u16 endFrame;
|
||||
} dMsgUnit_inf1_entry;
|
||||
|
||||
typedef struct dMsgUnit_inf1_section_t {
|
||||
/* 0x00 */ u32 msgType; // sectionType
|
||||
/* 0x04 */ u32 size; // total size of the section
|
||||
/* 0x08 */ u16 entryCount;
|
||||
/* 0x0A */ u16 entryLength;
|
||||
/* 0x0C */ u16 msgArchiveId;
|
||||
/* 0x0E */ dMsgUnit_inf1_entry entries[0];
|
||||
} dMsgUnit_inf1_section_t;
|
||||
|
||||
/* 80238C94-80238CA4 2335D4 0010+00 1/1 0/0 0/0 .text __ct__10dMsgUnit_cFv */
|
||||
dMsgUnit_c::dMsgUnit_c() {}
|
||||
|
||||
|
|
@ -57,20 +73,20 @@ void dMsgUnit_c::setTag(int param_1, int param_2, char* param_3, bool param_4) {
|
|||
|
||||
if (!stack9) {
|
||||
bmg_header_t* iVar9 = (bmg_header_t*)dMeter2Info_getMsgUnitResource();
|
||||
inf1_section_t* inf1 = NULL;
|
||||
dMsgUnit_inf1_section_t* inf1 = NULL;
|
||||
const void* dat1 = NULL;
|
||||
str1_section_t* str1 = NULL;
|
||||
int local_114 = sizeof(bmg_header_t);
|
||||
u32 size = iVar9->size;
|
||||
bmg_section_t* piVar12 = (bmg_section_t*)(((u8*)iVar9) + local_114);
|
||||
for (; local_114 < size; local_114 += piVar12->size) {
|
||||
switch(piVar12->msgType) {
|
||||
switch(piVar12->magic) {
|
||||
case 'FLW1':
|
||||
break;
|
||||
case 'FLI1':
|
||||
break;
|
||||
case 'INF1':
|
||||
inf1 = (inf1_section_t*)piVar12;
|
||||
inf1 = (dMsgUnit_inf1_section_t*)piVar12;
|
||||
break;
|
||||
case 'DAT1':
|
||||
dat1 = piVar12;
|
||||
|
|
@ -86,7 +102,7 @@ void dMsgUnit_c::setTag(int param_1, int param_2, char* param_3, bool param_4) {
|
|||
// but the normal build doesn't really work with that. Same for inf1->entries.
|
||||
|
||||
#ifdef DEBUG
|
||||
inf1_entry_t* entry = &inf1->entries[param_1];
|
||||
dMsgUnit_inf1_entry* entry = &inf1->entries[param_1];
|
||||
u32 dat1EntryOffset = entry->dat1EntryOffset;
|
||||
u16 startFrame = entry->startFrame;
|
||||
u16 endFrame = entry->endFrame;
|
||||
|
|
|
|||
Loading…
Reference in New Issue