d_lyt_pause_text OK

This commit is contained in:
robojumper
2025-08-03 22:08:11 +02:00
parent 90866457f1
commit 66a653a2f6
12 changed files with 682 additions and 96 deletions
+2
View File
@@ -69,6 +69,8 @@ public:
static s32 getRupeeCounter();
static u32 getCurrentWalletCapacity();
static u32 getHeartContainerHealthCount();
static u32 getKeyPieceCount();
static u32 getSmallKeyCount();
+5
View File
@@ -6,6 +6,11 @@
#include "s/s_State.hpp"
#include "sized_string.h"
/**
* 2D UI - Common - Title
*
* Used on title screen and pause menu.
*/
class dLytCommonTitle_c {
public:
dLytCommonTitle_c();
+32 -1
View File
@@ -22,18 +22,49 @@ public:
return field_0x083B;
}
bool getField_0x0841() const {
return field_0x0841;
}
enum SelectionType_e {
SELECT_DOWSING = 2,
SELECT_ITEM = 6,
SELECT_CATEGORY = 7,
SELECT_FIRE = 8,
SELECT_RING = 9,
};
SelectionType_e getCurrentSelectionType() const {
return mCurrentSelectionType;
}
s32 getCurrentSelectionId() const {
return mCurrentSelectionId;
}
private:
static dLytPauseMgr_c *sInstance;
/* 0x0000 */ u8 _0x0000[0x00C8 - 0x0000];
/* 0x00C8 */ d2d::ResAccIf_c mResAcc1;
/* 0x0438 */ u8 _0x0438[0x0814 - 0x0438];
/* 0x0814 */ EGG::CpuTexture *mpBgTexture;
/* 0x0818 */ SelectionType_e mCurrentSelectionType;
/* 0x0818 */ u8 _0x0818[0x083B - 0x0818];
/* 0x081C */ u8 _0x081C[0x082C - 0x081C];
/* 0x082C */ u16 mCurrentSelectionId;
/* 0x0830 */ u8 _0x0830[0x083B - 0x082E];
/* 0x083B */ bool field_0x083B;
/* 0x083D */ u8 _0x083D[0x0841 - 0x083C];
/* 0x0841 */ bool field_0x0841;
};
#endif
+1
View File
@@ -4,6 +4,7 @@
#include "d/lyt/d2d.h"
#include "s/s_State.hpp"
/** 2D UI - Pause menu - Background */
class dLytPauseBack_c {
public:
dLytPauseBack_c();
+1
View File
@@ -6,6 +6,7 @@
class dLytCommonTitle_c;
/** 2D UI - Pause menu - title and button help */
class dLytPauseInfo_c {
public:
dLytPauseInfo_c();
+44
View File
@@ -1,13 +1,57 @@
#ifndef D_LYT_PAUSE_TEXT_H
#define D_LYT_PAUSE_TEXT_H
#include "common.h"
#include "d/lyt/d2d.h"
#include "d/lyt/d_lyt_common_a_btn.h"
#include "s/s_State.hpp"
#include "sized_string.h"
/** 2D UI - Pause menu - item info popup */
class dLytPauseText_c {
public:
static const char *getCurrentPauseLabel(SizedString<32> &buf);
static const wchar_t *getCurrentPausePopupName();
static const wchar_t *getCurrentPausePopupCaption();
dLytPauseText_c();
virtual ~dLytPauseText_c() {}
bool build();
bool remove();
bool execute();
bool draw();
void requestIn();
void requestOut();
private:
void startAnim(int idx);
void stopAnim(int idx);
void updateText();
bool isCurrentItemWallet() const;
void calcTextLines(dTextBox_c *textBox, const wchar_t *text);
STATE_FUNC_DECLARE(dLytPauseText_c, None);
STATE_FUNC_DECLARE(dLytPauseText_c, In);
STATE_FUNC_DECLARE(dLytPauseText_c, Wait);
STATE_FUNC_DECLARE(dLytPauseText_c, Out);
/* 0x004 */ UI_STATE_MGR_DECLARE(dLytPauseText_c);
/* 0x040 */ d2d::LytBase_c mLyt;
/* 0x0D0 */ d2d::AnmGroup_c mAnm[3];
/* 0x190 */ d2d::ResAccIf_c mResAcc;
/* 0x500 */ dLytCommonABtn_c mABtn;
/* 0x6B0 */ d2d::SubPaneList mSubpaneList;
/* 0x6BC */ d2d::SubPaneListNode mSubpanes[1];
/* 0x6CC */ UNKWORD mStep;
/* 0x6D0 */ f32 mLineSpace;
/* 0x6D4 */ u8 mNumTextLines;
/* 0x6D5 */ bool mInRequest;
/* 0x6D6 */ bool mOutRequest;
/* 0x6D7 */ bool field_0x6D7;
/* 0x6D8 */ bool field_0x6D8;
};
#endif
+8
View File
@@ -6,6 +6,14 @@
#include "toBeSorted/dowsing_target.h"
void getItemLabel(s32 itemId, SizedString<32> &buf);
void getCaptionItemLabel(s32 itemId, SizedString<32> &buf);
void getDowsingLabel(s32 itemId, SizedString<32> &buf);
void getPauseCategoryLabel(s32 itemId, SizedString<32> &buf);
const wchar_t *getItemText(s32 itemId);
const wchar_t *getCaptionItemText(s32 itemId);
const wchar_t *getDowsingText(s32 itemId);
const wchar_t *getPauseCategoryText(s32 itemId);
bool isPouchBocoburinLocked();