fixed up some jack things

This commit is contained in:
Kade M
2021-06-05 16:44:43 -07:00
parent 4154de886d
commit 666d96ea57

View File

@ -2872,13 +2872,17 @@ class PlayState extends MusicBeatState
var possibleNotes:Array<Note> = []; // notes that can be hit var possibleNotes:Array<Note> = []; // notes that can be hit
var directionList:Array<Int> = []; // directions that can be hit var directionList:Array<Int> = []; // directions that can be hit
var dumbNotes:Array<Note> = []; // notes to kill later var dumbNotes:Array<Note> = []; // notes to kill later
var directionsAccounted:Array<Bool> = [false,false,false,false]; // we don't want to do judgments for more than one presses
notes.forEachAlive(function(daNote:Note) notes.forEachAlive(function(daNote:Note)
{ {
if (daNote.canBeHit && daNote.mustPress && !daNote.tooLate && !daNote.wasGoodHit) if (daNote.canBeHit && daNote.mustPress && !daNote.tooLate && !daNote.wasGoodHit)
{
if (!directionsAccounted[daNote.noteData])
{ {
if (directionList.contains(daNote.noteData)) if (directionList.contains(daNote.noteData))
{ {
directionsAccounted[daNote.noteData] = true;
for (coolNote in possibleNotes) for (coolNote in possibleNotes)
{ {
if (coolNote.noteData == daNote.noteData && Math.abs(daNote.strumTime - coolNote.strumTime) < 10) if (coolNote.noteData == daNote.noteData && Math.abs(daNote.strumTime - coolNote.strumTime) < 10)
@ -2901,8 +2905,11 @@ class PlayState extends MusicBeatState
directionList.push(daNote.noteData); directionList.push(daNote.noteData);
} }
} }
}
}); });
trace('\nCURRENT LINE:\n' + directionsAccounted);
for (note in dumbNotes) for (note in dumbNotes)
{ {
FlxG.log.add("killing dumb ass note at " + note.strumTime); FlxG.log.add("killing dumb ass note at " + note.strumTime);