15 lines
417 B
TypeScript
15 lines
417 B
TypeScript
import { Bar, Course, HitNote } from "tja-parser";
|
|
|
|
export function filterHitNotes(course: Course): HitNote[] {
|
|
const notes: HitNote[] = [];
|
|
course.noteGroups.forEach((g) => {
|
|
if (g instanceof Bar) {
|
|
for (const note of g.getNotes()) {
|
|
if (note instanceof HitNote) {
|
|
notes.push(note);
|
|
}
|
|
}
|
|
}
|
|
});
|
|
return notes;
|
|
} |