summaryrefslogtreecommitdiff
path: root/song.cpp
diff options
context:
space:
mode:
authorsimong4 <gags2431@usherbrooke.ca>2023-04-04 20:38:06 -0400
committersimong4 <gags2431@usherbrooke.ca>2023-04-04 20:38:06 -0400
commit3180cb7584c037463ee5c2047aea3e3ed0f0b364 (patch)
tree9bfd6b6df4666491295b30088a6bf7bec6f61757 /song.cpp
parentdf76819c0cffaa0bab2376a60eecd5b7e62b54cf (diff)
Gestion Muons + Ecran de fin de chanson
-Gestion du multiplicateur des muons (Divine Intervention) -Ajout d'un ecran de fin de chanson indiquant le nombre de points et le pourcentage de notes reussies -Correction d'un bug lors du "parse" des .chart
Diffstat (limited to 'song.cpp')
-rw-r--r--song.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/song.cpp b/song.cpp
index 6fc03a2..ced9187 100644
--- a/song.cpp
+++ b/song.cpp
@@ -296,13 +296,13 @@ void Song::consolidateChords(int difficulty){
int chordSize = chords->size();
// Go through all the chords
for (int i=0; i<chordSize; i++){
- ChordNote currentChord = chords->at(i);
+ ChordNote * currentChord = &chords->at(i);
// Check if any other chord past the current one
// has the same start and end time
for (int j=i+1; j<chordSize; j++){
ChordNote nextChord = chords->at(j);
- if (currentChord.getStart() == nextChord.getStart() &&
- currentChord.getEnd() == nextChord.getEnd()){
+ if (currentChord->getStart() == nextChord.getStart() &&
+ currentChord->getEnd() == nextChord.getEnd()){
// If so:
// - add the fret to the current chord
// - remove the next one
@@ -316,7 +316,7 @@ void Song::consolidateChords(int difficulty){
nextChord.print();
std::cout << " =";
#endif // DEBUG
- currentChord.merge(nextChord);
+ currentChord->merge(nextChord);
#ifdef DEBUG
currentChord.print();
#endif