|
From: Tapio V. <aa...@us...> - 2009-11-15 11:00:21
|
Module: performous
Branch: dance
Commit: ca2e7b7c75c26cc6cb251d6d77cff3e5e62e6b1c
Author: Tapio Vierros <tap...@gm...>
Date: Sun Nov 15 12:56:29 2009 +0200
Dance tracks are now correctly reported in the songs screen.
Also removed a temporary hack.
---
game/screen_sing.cc | 3 +--
game/screen_songs.cc | 3 +--
2 files changed, 2 insertions(+), 4 deletions(-)
diff --git a/game/screen_sing.cc b/game/screen_sing.cc
index 129180e..5b0ad26 100644
--- a/game/screen_sing.cc
+++ b/game/screen_sing.cc
@@ -88,12 +88,11 @@ void ScreenSing::enter() {
}
}
// Load dance tracks
- m_dancers.push_back(new DanceGraph(m_audio, *m_song)); // REMOVEME
if ( !m_song->danceTracks.empty() ) {
while(1) {
try {
m_dancers.push_back(new DanceGraph(m_audio, *m_song));
- break; // REMOVEME
+ break; // REMOVEME (when input assignement is correctly implemented)
} catch (std::runtime_error&) { break; }
}
}
diff --git a/game/screen_songs.cc b/game/screen_songs.cc
index 77a6883..8e798ca 100644
--- a/game/screen_songs.cc
+++ b/game/screen_songs.cc
@@ -320,8 +320,7 @@ void ScreenSongs::draw() {
}
{
// dancing
- // TODO: test for dance track
- alpha = 0.25;
+ alpha = !song_display.danceTracks.empty() ? 1.00 : 0.25;
glutil::Begin block(GL_TRIANGLE_STRIP);
glColor4f(1.0, 1.0, 1.0, alpha);
x = dim.x1()+4*xincr*(dim.x2()-dim.x1());
|