Skip to content

Commit

Permalink
fix: sort fails when hits land on same index
Browse files Browse the repository at this point in the history
  • Loading branch information
jason committed Nov 24, 2022
1 parent c981a95 commit 11db9bf
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion osu_dreamer/osu/beatmap.py
Original file line number Diff line number Diff line change
Expand Up @@ -267,6 +267,10 @@ def slider_duration(self, slider):

return slider.length / (smult * 100) * blen * slider.slides


def timing_signal(self, frame_times: "L,") -> ",L":
pass


def hit_signal(self, frame_times: "L,") -> "4,L":
"""
Expand Down Expand Up @@ -424,7 +428,7 @@ def get_ctrl_pts(a,b, step=1):
new_combo_idxs,
) = hit_frame_idxs

sorted_hits.extend([ (t, None, 0, False) for t in tap_idxs ])
sorted_hits.extend([ (t, t, 0, False) for t in tap_idxs ])
sorted_hits.extend([ (s, e, 1, False) for s,e in zip(sorted(slider_start_idxs), sorted(slider_end_idxs)) ])
sorted_hits.extend([ (s, e, 2, False) for s,e in zip(sorted(spinner_start_idxs), sorted(spinner_end_idxs)) ])

Expand Down

0 comments on commit 11db9bf

Please sign in to comment.