Fix a bug where making one selection and then making a different one would leave the original highlighted

This commit is contained in:
EliteMasterEric
2023-12-13 23:11:19 -05:00
parent 18ffb9fc36
commit e2b0ed98dd
3 changed files with 82 additions and 8 deletions
@@ -80,11 +80,24 @@ class ChartEditorNotePreview extends FlxSprite
* @param notes The data for the notes.
* @param songLengthInMs The total length of the song in milliseconds.
*/
public function addNotes(notes:Array<SongNoteData>, songLengthInMs:Int, ?isSelection:Bool = false):Void
public function addNotes(notes:Array<SongNoteData>, songLengthInMs:Int):Void
{
for (note in notes)
{
addNote(note, songLengthInMs, isSelection);
addNote(note, songLengthInMs, false);
}
}
/**
* Add an array of selected notes to the preview.
* @param notes The data for the notes.
* @param songLengthInMs The total length of the song in milliseconds.
*/
public function addSelectedNotes(notes:Array<SongNoteData>, songLengthInMs:Int):Void
{
for (note in notes)
{
addNote(note, songLengthInMs, true);
}
}