mirror of
https://github.com/zeldaret/ss
synced 2026-09-04 02:09:59 -04:00
d_lyt_pause_disp_01 OK
This commit is contained in:
@@ -70,6 +70,7 @@ public:
|
||||
static u32 getCurrentWalletCapacity();
|
||||
|
||||
static u32 getHeartContainerHealthCount();
|
||||
static u32 getGratitudeCrystalCount();
|
||||
|
||||
static u32 getKeyPieceCount();
|
||||
static u32 getSmallKeyCount();
|
||||
@@ -96,7 +97,13 @@ public:
|
||||
|
||||
static void healLink(u32 amount, bool); // move to dAcPy_c
|
||||
|
||||
static bool isPerformingInitialCollection() {
|
||||
return sIsPerformingInitialCollection;
|
||||
}
|
||||
|
||||
private:
|
||||
static bool sIsPerformingInitialCollection;
|
||||
|
||||
/* 0x334 */ UNKTYPE *mpMdl; // Model has its own handling system
|
||||
/* 0x338 */ dShadowCircle_c mShdw;
|
||||
/* 0x340 */ mVec3_c mField_0x340;
|
||||
|
||||
@@ -148,7 +148,7 @@ enum ITEM_ID {
|
||||
/* 0x08C */ ITEM_BIG_BUG_NET = 140,
|
||||
/* 0x08D */ ITEM_FARON_GRASSHOPPER = 141,
|
||||
/* 0x08E */ ITEM_WOODLAND_RHINO_BEETLE = 142,
|
||||
/* 0x08F */ ITEM_DEKU_HORNET_ = 143,
|
||||
/* 0x08F */ ITEM_DEKU_HORNET = 143,
|
||||
/* 0x090 */ ITEM_SKYLOFT_MANTIS = 144,
|
||||
/* 0x091 */ ITEM_VOLCANIC_LADYBUG = 145,
|
||||
/* 0x092 */ ITEM_BLESSED_BUTTERFLY = 146,
|
||||
|
||||
@@ -9,6 +9,7 @@
|
||||
#include "m/m2d.h"
|
||||
#include "m/m_angle.h"
|
||||
#include "m/m_vec.h"
|
||||
#include "nw4r/lyt/lyt_pane.h"
|
||||
|
||||
class dCsBase_c : public dCs_c {
|
||||
public:
|
||||
@@ -47,6 +48,10 @@ public:
|
||||
mCursorStick.setShouldBeOn(visible);
|
||||
}
|
||||
|
||||
void setCursorStickTargetPane(const nw4r::lyt::Pane *target) {
|
||||
mCursorStick.setTargetPane(target);
|
||||
}
|
||||
|
||||
private:
|
||||
static dCsBase_c *sInstance;
|
||||
void setCurrentLyt(int lyt);
|
||||
|
||||
@@ -38,10 +38,18 @@ inline bool isPointerVisible() {
|
||||
return sIsPointerVisible;
|
||||
}
|
||||
|
||||
inline bool isPrevPointerVisible() {
|
||||
return sPrevIsPointerVisible;
|
||||
}
|
||||
|
||||
inline bool isCursorStickVisible() {
|
||||
return sIsCursorStickVisible;
|
||||
}
|
||||
|
||||
inline s32 getFSStickNavDirection() {
|
||||
return sFSStickNavDirection;
|
||||
}
|
||||
|
||||
void init();
|
||||
void calc();
|
||||
void setNavEnabled(bool navEnabled, bool autoReturnToPointerNav);
|
||||
|
||||
@@ -36,24 +36,24 @@ private:
|
||||
void unbindAt(s32);
|
||||
void tickDown(d2d::AnmGroup_c *);
|
||||
void fn_80168880();
|
||||
UI_STATE_MGR_DECLARE(dLytCommonArrow_c);
|
||||
|
||||
/* 0x04 */ UI_STATE_MGR_DECLARE(dLytCommonArrow_c);
|
||||
/* 0x40 */ d2d::LytBase_c mLytBase;
|
||||
d2d::ResAccIf_c mResAcc;
|
||||
d2d::AnmGroup_c mAnmGroups[0x9];
|
||||
d2d::AnmGroup_c mAnmGroups[9];
|
||||
dCursorHitCheckLyt_c mCsHitCheck;
|
||||
nw4r::lyt::Bounding *mBoundingL;
|
||||
nw4r::lyt::Bounding *mBoundingR;
|
||||
s32 mType;
|
||||
s32 field_0x6B4;
|
||||
s32 field_0x6B8;
|
||||
s32 field_0x6BC;
|
||||
s32 field_0x6C0;
|
||||
s32 mTimer;
|
||||
u8 mInRequested;
|
||||
u8 mOutRequested;
|
||||
u8 field_0x6CA;
|
||||
u8 field_0x6CB;
|
||||
u8 field_0x6CC;
|
||||
/* 0x6A8 */ nw4r::lyt::Bounding *mpBoundings[2];
|
||||
/* 0x6B0 */ s32 mType;
|
||||
/* 0x6B4 */ s32 mTargetedBounding;
|
||||
/* 0x6B8 */ s32 field_0x6B8;
|
||||
/* 0x6BC */ s32 field_0x6BC;
|
||||
/* 0x6C0 */ s32 field_0x6C0;
|
||||
/* 0x6C4 */ s32 mTimer;
|
||||
/* 0x6C8 */ bool mInRequested;
|
||||
/* 0x6C9 */ bool mOutRequested;
|
||||
/* 0x6CA */ u8 field_0x6CA;
|
||||
/* 0x6CB */ u8 field_0x6CB;
|
||||
/* 0x6CC */ u8 field_0x6CC;
|
||||
};
|
||||
|
||||
#endif
|
||||
|
||||
@@ -15,6 +15,24 @@
|
||||
#define LYT_CMN_BugLanayruAnt (10) // [10] tr_bugIcon_10.tpl
|
||||
#define LYT_CMN_BugEldinRoller (11) // [11] tr_bugIcon_11.tpl
|
||||
|
||||
// Treasure
|
||||
#define LYT_CMN_HORNET_LARVAE (0) // [ 1] uk_soaHachisu_00.tpl
|
||||
#define LYT_CMN_BIRD_FEATHER (1) // [ 2] uk_sobHaneA_00.tpl
|
||||
#define LYT_CMN_TUMBLEWEED (2) // [ 3] uk_socTumble_00.tpl
|
||||
#define LYT_CMN_LIZALFOS_TAIL (3) // [ 0] tr_sozaiIcon_03.tpl
|
||||
#define LYT_CMN_ELDIN_ORE (4) // [ 4] uk_soeKoseki_00.tpl
|
||||
#define LYT_CMN_ANCIENT_FLOWER (5) // [ 5] uk_sofHana_00.tpl
|
||||
#define LYT_CMN_AMBER_RELIC (6) // [ 6] uk_sogMagatamaA_00.tpl
|
||||
#define LYT_CMN_DUSK_RELOC (7) // [ 7] uk_sohMagatamaB_00.tpl
|
||||
#define LYT_CMN_JELLY_BLOB (8) // [ 8] uk_soiPuyo_00.tpl
|
||||
#define LYT_CMN_MONSTER_CLAW (9) // [ 9] uk_sojClaw_00.tpl
|
||||
#define LYT_CMN_MONSTER_HORN (10) // [11] uk_solHorn_00.tpl
|
||||
#define LYT_CMN_ORNAMENTAL_SKULL (11) // [10] uk_sokDokuroA_00.tpl
|
||||
#define LYT_CMN_EVIL_CRYSTAL (12) // [12] uk_somEvil_00.tpl
|
||||
#define LYT_CMN_BLUE_BIRD_FEATHER (13) // [13] uk_sonHaneB_00.tpl
|
||||
#define LYT_CMN_GOLDEN_SKULL (14) // [14] uk_sooDokuroB_00.tpl
|
||||
#define LYT_CMN_GODDESS_PLUME (15) // [15] uk_sopGoddess_00.tpl
|
||||
|
||||
// Items
|
||||
#define LYT_CMN_ItemBombBag (0) // [ 8] uc_bomb_00.tpl
|
||||
#define LYT_CMN_ItemBow (1) // [ 9] uc_bowA_00.tpl
|
||||
@@ -34,7 +52,7 @@
|
||||
#define LYT_CMN_ItemBigBugnet (15) // [14] uc_netB_00.tpl
|
||||
#define LYT_CMN_ItemBoatCannon (16) // [ 7] uc_boatCannon_00.tpl
|
||||
#define LYT_CMN_ItemHarp (17) // [ 0] tr_tategoto_00.tpl
|
||||
#define LYT_CMN_ItemInvalid (18) // -------------------------
|
||||
#define LYT_CMN_ItemInvalid (18) // -------------------------
|
||||
|
||||
// Pouch Items
|
||||
#define LYT_CMN_PouchPotionHealyh (0) // [12] uc_bottleKusuriA_00.tpl
|
||||
@@ -113,6 +131,6 @@
|
||||
#define LYT_CMN_DowsingZelda (19) // [13] tr_dauzTarget_19.tpl
|
||||
#define LYT_CMN_DowsingTrialGate (20) // [14] tr_dauzTarget_20.tpl
|
||||
#define LYT_CMN_DowsingNewPlantSpecies (21) // [15] tr_dauzTarget_21.tpl
|
||||
#define LYT_CMN_DowsingInvalid (22) // -------------------------
|
||||
#define LYT_CMN_DowsingInvalid (22) // -------------------------
|
||||
|
||||
#endif
|
||||
|
||||
@@ -8,26 +8,18 @@
|
||||
#include "nw4r/lyt/lyt_bounding.h"
|
||||
#include "s/s_State.hpp"
|
||||
|
||||
class dLytCommonIconMaterialPartBase_c {
|
||||
public:
|
||||
virtual ~dLytCommonIconMaterialPartBase_c() {}
|
||||
virtual nw4r::lyt::Pane *getPane() = 0;
|
||||
virtual d2d::LytBase_c *getLyt() = 0;
|
||||
virtual const char *getName() const = 0;
|
||||
};
|
||||
|
||||
/** Material - Bug */
|
||||
class dLytCommonIconMaterialPart1_c : public dLytCommonIconMaterialPartBase_c {
|
||||
class dLytCommonIconMaterialPart1_c {
|
||||
public:
|
||||
dLytCommonIconMaterialPart1_c() {}
|
||||
virtual ~dLytCommonIconMaterialPart1_c() {}
|
||||
virtual nw4r::lyt::Pane *getPane() override {
|
||||
virtual nw4r::lyt::Pane *getPane() {
|
||||
return mLyt.getLayout()->GetRootPane();
|
||||
}
|
||||
virtual d2d::LytBase_c *getLyt() override {
|
||||
virtual d2d::LytBase_c *getLyt() {
|
||||
return &mLyt;
|
||||
}
|
||||
virtual const char *getName() const override {
|
||||
virtual const char *getName() const {
|
||||
return mLyt.getName();
|
||||
}
|
||||
|
||||
@@ -78,17 +70,17 @@ private:
|
||||
};
|
||||
|
||||
/** Material - Treasure */
|
||||
class dLytCommonIconMaterialPart2_c : public dLytCommonIconMaterialPartBase_c {
|
||||
class dLytCommonIconMaterialPart2_c {
|
||||
public:
|
||||
dLytCommonIconMaterialPart2_c() {}
|
||||
virtual ~dLytCommonIconMaterialPart2_c() {}
|
||||
virtual nw4r::lyt::Pane *getPane() override {
|
||||
virtual nw4r::lyt::Pane *getPane() {
|
||||
return mLyt.getLayout()->GetRootPane();
|
||||
}
|
||||
virtual d2d::LytBase_c *getLyt() override {
|
||||
virtual d2d::LytBase_c *getLyt() {
|
||||
return &mLyt;
|
||||
}
|
||||
virtual const char *getName() const override {
|
||||
virtual const char *getName() const {
|
||||
return mLyt.getName();
|
||||
}
|
||||
|
||||
@@ -185,6 +177,9 @@ public:
|
||||
|
||||
const nw4r::lyt::Bounding *getBounding() const;
|
||||
|
||||
STATE_MGR_DEFINE_UTIL_CHANGESTATE(dLytCommonIconMaterial_c);
|
||||
STATE_MGR_DEFINE_UTIL_ISSTATE(dLytCommonIconMaterial_c);
|
||||
|
||||
private:
|
||||
STATE_FUNC_DECLARE(dLytCommonIconMaterial_c, None);
|
||||
STATE_FUNC_DECLARE(dLytCommonIconMaterial_c, In);
|
||||
|
||||
@@ -29,6 +29,10 @@ public:
|
||||
return mItemForPauseDemo;
|
||||
}
|
||||
|
||||
u16 getItemCountForPauseDemo() const {
|
||||
return mItemCountForPauseDemo;
|
||||
}
|
||||
|
||||
bool getField_0x15C67() const {
|
||||
return field_0x15C67;
|
||||
}
|
||||
@@ -57,8 +61,10 @@ private:
|
||||
|
||||
/* 0x15C60 */ u16 mItemForPauseDemo;
|
||||
|
||||
/* 0x15C62 */ u8 _0x15C62[0x15C67 - 0x15C62];
|
||||
/* 0x15C62 */ u8 _0x15C62[0x15C64 - 0x15C62];
|
||||
|
||||
/* 0x15C64 */ u16 mItemCountForPauseDemo;
|
||||
/* 0x15C66 */ u8 field_0x15C66;
|
||||
/* 0x15C67 */ bool field_0x15C67;
|
||||
|
||||
static dLytControlGame_c *sInstance;
|
||||
|
||||
@@ -23,7 +23,7 @@ public:
|
||||
static bool drawDirectly();
|
||||
|
||||
void setPriority(u8 priority);
|
||||
void setTargetPane(nw4r::lyt::Pane *pane);
|
||||
void setTargetPane(const nw4r::lyt::Pane *pane);
|
||||
|
||||
void setShouldBeOn(bool value) {
|
||||
mShouldBeOn = value;
|
||||
@@ -47,7 +47,7 @@ private:
|
||||
/* 0x3AC */ d2d::dLytSub mLyt;
|
||||
/* 0x440 */ d2d::AnmGroup_c mAnm[1];
|
||||
/* 0x480 */ nw4r::lyt::Pane *mpPanes[5];
|
||||
/* 0x494 */ nw4r::lyt::Pane *mpTargetPane;
|
||||
/* 0x494 */ const nw4r::lyt::Pane *mpTargetPane;
|
||||
/* 0x498 */ bool mShouldBeOn;
|
||||
};
|
||||
|
||||
|
||||
+49
-10
@@ -3,6 +3,7 @@
|
||||
|
||||
#include "d/lyt/d2d.h"
|
||||
#include "egg/gfx/eggCpuTexture.h"
|
||||
#include "nw4r/lyt/lyt_pane.h"
|
||||
|
||||
class dLytPauseMgr_c {
|
||||
public:
|
||||
@@ -14,26 +15,52 @@ public:
|
||||
return &mResAcc1;
|
||||
}
|
||||
|
||||
d2d::ResAccIf_c *getResAcc2() {
|
||||
return &mResAcc2;
|
||||
}
|
||||
|
||||
EGG::CpuTexture *getBgTexture() {
|
||||
return mpBgTexture;
|
||||
}
|
||||
|
||||
bool getField_0x0831() const {
|
||||
return field_0x0831;
|
||||
}
|
||||
|
||||
bool getField_0x0832() const {
|
||||
return field_0x0832;
|
||||
}
|
||||
|
||||
bool getField_0x083B() const {
|
||||
return field_0x083B;
|
||||
}
|
||||
|
||||
bool getField_0x0841() const {
|
||||
return field_0x0841;
|
||||
bool getField_0x083E() const {
|
||||
return field_0x083E;
|
||||
}
|
||||
|
||||
bool getField_0x0840() const {
|
||||
return field_0x0840;
|
||||
}
|
||||
|
||||
bool isStateWait() const;
|
||||
|
||||
enum SelectionType_e {
|
||||
SELECT_DOWSING = 2,
|
||||
SELECT_INSECT = 4,
|
||||
SELECT_QUEST_MATERIAL = 5,
|
||||
SELECT_ITEM = 6,
|
||||
SELECT_CATEGORY = 7,
|
||||
SELECT_FIRE = 8,
|
||||
SELECT_RING = 9,
|
||||
SELECT_NONE = 10,
|
||||
};
|
||||
|
||||
void setSelection(SelectionType_e type, s32 id, bool restricted);
|
||||
|
||||
bool isCurrentSelectionRestricted() const {
|
||||
return mCurrentSelectionIsRestricted;
|
||||
}
|
||||
SelectionType_e getCurrentSelectionType() const {
|
||||
return mCurrentSelectionType;
|
||||
}
|
||||
@@ -42,29 +69,41 @@ public:
|
||||
return mCurrentSelectionId;
|
||||
}
|
||||
|
||||
nw4r::lyt::Pane *getArrowBounding(int idx) const;
|
||||
nw4r::lyt::Pane *setSelectedArrowBounding(int idx) const;
|
||||
|
||||
private:
|
||||
static dLytPauseMgr_c *sInstance;
|
||||
|
||||
/* 0x0000 */ u8 _0x0000[0x00C8 - 0x0000];
|
||||
|
||||
/* 0x00C8 */ d2d::ResAccIf_c mResAcc1;
|
||||
|
||||
/* 0x0438 */ u8 _0x0438[0x0814 - 0x0438];
|
||||
/* 0x00C8 */ d2d::ResAccIf_c mResAcc1;
|
||||
/* 0x0438 */ d2d::ResAccIf_c mResAcc2;
|
||||
|
||||
/* 0x07A8 */ u8 _0x0438[0x0814 - 0x07A8];
|
||||
|
||||
/* 0x0814 */ EGG::CpuTexture *mpBgTexture;
|
||||
/* 0x0818 */ SelectionType_e mCurrentSelectionType;
|
||||
|
||||
/* 0x081C */ u8 _0x081C[0x082C - 0x081C];
|
||||
|
||||
|
||||
/* 0x082C */ u16 mCurrentSelectionId;
|
||||
|
||||
/* 0x0830 */ u8 _0x0830[0x083B - 0x082E];
|
||||
|
||||
/* 0x082E */ u8 _0x082E[0x0831 - 0x082E];
|
||||
|
||||
/* 0x0831 */ bool field_0x0831;
|
||||
/* 0x0832 */ bool field_0x0832;
|
||||
|
||||
/* 0x0832 */ u8 _0x0832[0x083B - 0x0833];
|
||||
|
||||
/* 0x083B */ bool field_0x083B;
|
||||
|
||||
/* 0x083D */ u8 _0x083D[0x0841 - 0x083C];
|
||||
/* 0x083C */ u8 _0x083C[0x083E - 0x083C];
|
||||
|
||||
/* 0x0841 */ bool field_0x0841;
|
||||
/* 0x083E */ bool field_0x083E;
|
||||
/* 0x083F */ bool field_0x083F;
|
||||
/* 0x0840 */ bool field_0x0840;
|
||||
/* 0x0841 */ bool mCurrentSelectionIsRestricted;
|
||||
};
|
||||
|
||||
#endif
|
||||
|
||||
@@ -1,9 +1,11 @@
|
||||
#ifndef LYT_PAUSE_DISP_01_H
|
||||
#define LYT_PAUSE_DISP_01_H
|
||||
|
||||
#include "common.h"
|
||||
#include "d/d_cursor_hit_check.h"
|
||||
#include "d/lyt/d2d.h"
|
||||
#include "d/lyt/d_lyt_common_icon_material.h"
|
||||
#include "nw4r/lyt/lyt_pane.h"
|
||||
#include "s/s_State.hpp"
|
||||
|
||||
class dLytPauseDisp01_c {
|
||||
@@ -11,7 +13,16 @@ public:
|
||||
dLytPauseDisp01_c();
|
||||
virtual ~dLytPauseDisp01_c() {}
|
||||
|
||||
void init();
|
||||
bool build();
|
||||
bool remove();
|
||||
bool execute();
|
||||
bool draw();
|
||||
|
||||
void drawDirectly();
|
||||
void requestIn(bool scroll);
|
||||
void requestOut(bool scroll);
|
||||
void requestSelect();
|
||||
void requestUnselect();
|
||||
|
||||
STATE_FUNC_DECLARE(dLytPauseDisp01_c, None);
|
||||
STATE_FUNC_DECLARE(dLytPauseDisp01_c, In);
|
||||
@@ -21,15 +32,49 @@ public:
|
||||
STATE_FUNC_DECLARE(dLytPauseDisp01_c, Out);
|
||||
|
||||
private:
|
||||
void displayElement(int idx, float value);
|
||||
void setAnm(int idx, f32 value);
|
||||
void stopAnm(int idx);
|
||||
|
||||
/* 0x0004 */ STATE_MGR_DECLARE(dLytPauseDisp01_c);
|
||||
/* 0x0040 */ d2d::LytBase_c mLytBase;
|
||||
/* 0x00D0 */ d2d::AnmGroup_c field_0x00D0[15];
|
||||
/* 0x0490 */ dLytCommonIconMaterial_c field_0x2050[28];
|
||||
/* 0x96B0 */ d2d::SubPaneList mSubpanes;
|
||||
/* 0x96BC */ d2d::SubPaneListNode field_0xE11C[28];
|
||||
/* 0x987C */ dCursorHitCheckLyt_c field_0xE29C;
|
||||
void setupDisp();
|
||||
void setupInsects();
|
||||
void setupMaterials();
|
||||
|
||||
void showInsectsAndMaterials();
|
||||
s32 updateSelection();
|
||||
s32 getPointerPane() const;
|
||||
void hideInsectsAndMaterials();
|
||||
|
||||
bool shouldInsectBeDisplayed(s32 insectIdx) const;
|
||||
u16 getInsectItemId(s32 insectIdx) const;
|
||||
s32 getInsectIcon(s32 insectIdx) const;
|
||||
s32 getInsectCountByIndex(s32 insectIdx) const;
|
||||
|
||||
u16 getQuestItemId(s32 questItemIndex) const;
|
||||
|
||||
bool shouldMaterialBeDisplayed(s32 materialIdx) const;
|
||||
u16 getMaterialItemId(s32 materialIdx) const;
|
||||
s32 getMaterialIcon(s32 materialIdx) const;
|
||||
s32 getMaterialCountByIndex(s32 materialIdx) const;
|
||||
|
||||
/* 0x0004 */ UI_STATE_MGR_DECLARE(dLytPauseDisp01_c);
|
||||
/* 0x0040 */ d2d::LytBase_c mLyt;
|
||||
/* 0x00D0 */ d2d::AnmGroup_c mAnm[15];
|
||||
/* 0x0490 */ dLytCommonIconMaterial_c mIcons[28];
|
||||
/* 0x96B0 */ d2d::SubPaneList mSubpaneList;
|
||||
/* 0x96BC */ d2d::SubPaneListNode mSubpanes[28];
|
||||
/* 0x987C */ dCursorHitCheckLyt_c mCsHitCheck;
|
||||
/* 0x98A4 */ nw4r::lyt::Pane *mpPanes[6];
|
||||
/* 0x98BC */ s32 mStep;
|
||||
/* 0x98C0 */ s32 mPrevNavTarget;
|
||||
/* 0x98C4 */ s32 mCurrentNavTarget;
|
||||
/* 0x98C8 */ s32 mTimer;
|
||||
/* 0x98CC */ bool mInRequest;
|
||||
/* 0x98CD */ bool mOutRequest;
|
||||
/* 0x98CE */ bool field_0x98CE;
|
||||
/* 0x98CF */ bool mIsVisible;
|
||||
/* 0x98D0 */ bool mDoScrollAnim;
|
||||
/* 0x98D1 */ bool field_0x98D1;
|
||||
/* 0x98D2 */ bool mSelectToggle;
|
||||
};
|
||||
|
||||
#endif
|
||||
|
||||
Reference in New Issue
Block a user