make claps based on time instead of y positions

This commit is contained in:
KadeDeveloper 2021-08-13 15:00:37 -07:00
parent b749f10957
commit 94b6cba78d

View File

@ -2134,17 +2134,11 @@ class ChartingState extends MusicBeatState
{ {
curRenderedNotes.forEach(function(note:Note) curRenderedNotes.forEach(function(note:Note)
{ {
if (FlxG.sound.music.playing) if (note.strumTime <= Conductor.songPosition && !claps.contains(note))
{
if (strumLine.overlaps(note))
{
if(!claps.contains(note))
{ {
claps.push(note); claps.push(note);
FlxG.sound.play(Paths.sound('SNAP')); FlxG.sound.play(Paths.sound('SNAP'));
} }
}
}
}); });
} }
/*curRenderedNotes.forEach(function(note:Note) { /*curRenderedNotes.forEach(function(note:Note) {