diff options
author | Treeki <treeki@gmail.com> | 2012-09-27 16:58:43 +0200 |
---|---|---|
committer | Treeki <treeki@gmail.com> | 2012-09-27 16:58:43 +0200 |
commit | 624a89dc12d88973486b39937871c5facf6b9bb6 (patch) | |
tree | ff7614e780d13162d1749e4f57478dc16b9226d7 /src/koopatlas/hud.h | |
parent | 3268b1fab87a34897289faa8a1f5ee0679f74e19 (diff) | |
parent | 0fc70778c02671e64b8360b7ebdbb0e8c29f0a05 (diff) | |
download | kamek-624a89dc12d88973486b39937871c5facf6b9bb6.tar.gz kamek-624a89dc12d88973486b39937871c5facf6b9bb6.zip |
Merge branch 'new-hud' into level-select
Diffstat (limited to 'src/koopatlas/hud.h')
-rw-r--r-- | src/koopatlas/hud.h | 69 |
1 files changed, 55 insertions, 14 deletions
diff --git a/src/koopatlas/hud.h b/src/koopatlas/hud.h index 347fcb4..c0079af 100644 --- a/src/koopatlas/hud.h +++ b/src/koopatlas/hud.h @@ -3,6 +3,23 @@ #include "koopatlas/core.h" +// Colourises an IA8 texture +class dTexMapColouriser_c { + public: + dTexMapColouriser_c(); + ~dTexMapColouriser_c(); + + void resetAndClear(); + void setTexMap(nw4r::lyt::TexMap *tm); + void applyAlso(nw4r::lyt::TexMap *tm); + void colourise(int h, int s, int l); + + private: + nw4r::lyt::TexMap *texmap; + u16 *original; + u16 *mine; +}; + class dWMHud_c : public dBase_c { public: dWMHud_c(); @@ -15,25 +32,49 @@ class dWMHud_c : public dBase_c { bool layoutLoaded; m2d::EmbedLayout_c layout; - void updateLives(); + static dWMHud_c *build(); + static dWMHud_c *instance; - void showPointBar(); - void hidePointBar(); + void enteredNode(dKPNode_s *node = 0); + void leftNode(); - void setPointName(); - void checkPointStatus(); - void setLevelText(const char *str, int length = -1); - void setLevelText(const wchar_t *str, int length = -1); + void hideAndShowFooter(); - void setWorldName(); - void setWorldText(const char *str, int length = -1); - void setWorldText(const wchar_t *str, int length = -1); - - static dWMHud_c *build(); - static dWMHud_c *instance; + void setupLives(); private: - bool isPointBarShown; + void playShowAnim(int id); + void playHideAnim(int id); + void loadHeaderInfo(); + + bool willShowHeader; + dKPNode_s *nodeForHeader; + + int displayedControllerType; + void updatePressableButtonThingies(); + + void loadFooterInfo(); + bool willShowFooter; + + dTexMapColouriser_c headerCol, footerCol; + + + nw4r::lyt::Pane + *N_IconPosXP_00[4]; + + nw4r::lyt::Picture + *Header_Centre, *Header_Right, *Footer, + *NormalExitFlag, *SecretExitFlag, + *StarCoinOn[3], + *P_marioFace_00, *P_luigiFace_00, + *P_BkinoFace_00, *P_YkinoFace_00; + + nw4r::lyt::TextBox + *LevelName, *LevelNameS, + *LevelNumber, *LevelNumberS, + *WorldName, *WorldNameS, + *StarCoinCounter, + *T_lifeNumber[4]; }; #endif |