|
From: Tapio V. <aa...@us...> - 2010-01-27 13:52:55
|
Module: performous
Branch: master
Commit: b6624441328a630ee75fbe23c67c9f33bd0e03a9
Author: Tapio Vierros <tap...@gm...>
Date: Wed Jan 27 15:41:25 2010 +0200
Add a hack to bring SM parser to the memory saving bussiness.
---
game/songparser-sm.cc | 1 +
game/songparser.hh | 2 +-
2 files changed, 2 insertions(+), 1 deletions(-)
diff --git a/game/songparser-sm.cc b/game/songparser-sm.cc
index ba60e40..811d398 100644
--- a/game/songparser-sm.cc
+++ b/game/songparser-sm.cc
@@ -55,6 +55,7 @@ reaches value #NOTES.
/// Parse header data for Songs screen
// TODO: This actually parses the whole thing
+// TODO: Songparser drops parsed notes, remove it when smParseHeader is more intelligent
void SongParser::smParseHeader() {
Song& s = m_song;
std::string line;
diff --git a/game/songparser.hh b/game/songparser.hh
index 842dd75..14f3f37 100644
--- a/game/songparser.hh
+++ b/game/songparser.hh
@@ -59,7 +59,7 @@ class SongParser {
try {
if (type == TXT) txtParseHeader();
else if (type == INI) iniParseHeader();
- else if (type == SM) smParseHeader();
+ else if (type == SM) { smParseHeader(); s.dropNotes(); } // Hack: drop notes here
} catch (std::runtime_error& e) {
throw SongParserException(e.what(), m_linenum);
}
|