summaryrefslogtreecommitdiff
path: root/src/koopatlas/hud.cpp
diff options
context:
space:
mode:
authorTreeki <treeki@gmail.com>2013-01-17 09:23:55 +0100
committerTreeki <treeki@gmail.com>2013-01-17 09:23:55 +0100
commit1e2fe2181af8215e6da3f55d0350385d0af2f7e0 (patch)
tree697f2105ceedd031f901c896d2747ccdfc2b43bb /src/koopatlas/hud.cpp
parent4a51200b922d2ed0896562d95d1d9e390a014db3 (diff)
downloadkamek-1e2fe2181af8215e6da3f55d0350385d0af2f7e0.tar.gz
kamek-1e2fe2181af8215e6da3f55d0350385d0af2f7e0.zip
myriad updates and fixes to EVERYTHING
Diffstat (limited to 'src/koopatlas/hud.cpp')
-rw-r--r--src/koopatlas/hud.cpp27
1 files changed, 22 insertions, 5 deletions
diff --git a/src/koopatlas/hud.cpp b/src/koopatlas/hud.cpp
index 4d678c6..1032512 100644
--- a/src/koopatlas/hud.cpp
+++ b/src/koopatlas/hud.cpp
@@ -24,7 +24,9 @@ dWMHud_c::dWMHud_c() {
enum WMHudAnimation {
SHOW_LIVES = 0,
SHOW_HEADER,
- SHOW_FOOTER
+ SHOW_FOOTER,
+ HIDE_ALL,
+ UNHIDE_ALL,
};
@@ -46,16 +48,23 @@ int dWMHud_c::onCreate() {
layout.layout.rootPane->scale.y = 0.7711f;
}
- static const char *brlanNames[2] = {"MapHUD_ShowMain.brlan", "MapHUD_ShowHeader.brlan"};
- static const char *groupNames[3] = {"G_Lives", "G_Header", "G_Footer"};
+ static const char *brlanNames[] = {
+ "MapHUD_ShowMain.brlan", "MapHUD_ShowHeader.brlan",
+ "MapHUD_HideAll.brlan", "MapHUD_UnhideAll.brlan",
+ };
+ static const char *groupNames[] = {
+ "G_Lives", "G_Header", "G_Footer",
+ "G_Hideables", "G_Hideables",
+ };
- layout.loadAnimations(brlanNames, 2);
- layout.loadGroups(groupNames, (int[3]){0, 1, 0}, 3);
+ layout.loadAnimations(brlanNames, 4);
+ layout.loadGroups(groupNames, (int[5]){0, 1, 0, 2, 3}, 5);
layout.disableAllAnimations();
layout.enableNonLoopAnim(SHOW_LIVES);
layout.resetAnim(SHOW_FOOTER);
layout.resetAnim(SHOW_HEADER);
+ layout.resetAnim(HIDE_ALL);
static const char *tbNames[2] = {"MenuButtonInfo", "ItemsButtonInfo"};
layout.setLangStrings(tbNames, (int[2]){12, 15}, 4, 2);
@@ -162,6 +171,14 @@ int dWMHud_c::onDraw() {
}
+void dWMHud_c::hideAll() {
+ layout.enableNonLoopAnim(HIDE_ALL);
+}
+void dWMHud_c::unhideAll() {
+ layout.enableNonLoopAnim(UNHIDE_ALL);
+}
+
+
void dWMHud_c::playShowAnim(int id) {