From 463269dbe497d82b14f70d5745869bfc74d3e8ee Mon Sep 17 00:00:00 2001 From: Detoria <44783518+theDetourist@users.noreply.github.com> Date: Thu, 25 Mar 2021 15:59:39 -0300 Subject: [PATCH] Update Note.hx --- source/Note.hx | 58 +++++++++++++++++--------------------------------- 1 file changed, 19 insertions(+), 39 deletions(-) diff --git a/source/Note.hx b/source/Note.hx index 88793ec..c7cde28 100644 --- a/source/Note.hx +++ b/source/Note.hx @@ -40,9 +40,8 @@ class Note extends FlxSprite if (prevNote == null) prevNote = this; - // And have up and down arrows flipped too? Nop - /* if (FlxG.save.data.downscroll) - flipY = true; */ + if (FlxG.save.data.downscroll) + flipY = true; this.prevNote = prevNote; isSustainNote = sustainNote; @@ -50,7 +49,6 @@ class Note extends FlxSprite x += 50; // MAKE SURE ITS DEFINITELY OFF SCREEN? y -= 2000; - this.strumTime = strumTime + FlxG.save.data.offset; this.noteData = noteData; @@ -66,30 +64,20 @@ class Note extends FlxSprite animation.add('redScroll', [7]); animation.add('blueScroll', [5]); animation.add('purpleScroll', [4]); - - // Hold piece - animation.add('purplehold', [0]); - animation.add('greenhold', [2]); - animation.add('redhold', [3]); - animation.add('bluehold', [1]); - + if (isSustainNote) { loadGraphic(Paths.image('weeb/pixelUI/arrowEnds'), true, 7, 6); - if(!FlxG.save.data.downscroll) - { - // Trail end - animation.add('purpleholdend', [4]); - animation.add('greenholdend', [6]); - animation.add('redholdend', [7]); - animation.add('blueholdend', [5]); - }else { - animation.add('purpleholdend', [4], 0, false, false, true); - animation.add('greenholdend', [6], 0, false, false, true); - animation.add('redholdend', [7], 0, false, false, true); - animation.add('blueholdend', [5], 0, false, false, true); - } + animation.add('purpleholdend', [4]); + animation.add('greenholdend', [6]); + animation.add('redholdend', [7]); + animation.add('blueholdend', [5]); + + animation.add('purplehold', [0]); + animation.add('greenhold', [2]); + animation.add('redhold', [3]); + animation.add('bluehold', [1]); } setGraphicSize(Std.int(width * PlayState.daPixelZoom)); @@ -102,24 +90,16 @@ class Note extends FlxSprite animation.addByPrefix('redScroll', 'red0'); animation.addByPrefix('blueScroll', 'blue0'); animation.addByPrefix('purpleScroll', 'purple0'); - + + animation.addByPrefix('purpleholdend', 'pruple end hold'); + animation.addByPrefix('greenholdend', 'green hold end'); + animation.addByPrefix('redholdend', 'red hold end'); + animation.addByPrefix('blueholdend', 'blue hold end'); + animation.addByPrefix('purplehold', 'purple hold piece'); animation.addByPrefix('greenhold', 'green hold piece'); animation.addByPrefix('redhold', 'red hold piece'); animation.addByPrefix('bluehold', 'blue hold piece'); - - if(!FlxG.save.data.downscroll) - { - animation.addByPrefix('purpleholdend', 'pruple end hold'); - animation.addByPrefix('greenholdend', 'green hold end'); - animation.addByPrefix('redholdend', 'red hold end'); - animation.addByPrefix('blueholdend', 'blue hold end'); - }else { - animation.addByPrefix('purpleholdend', 'pruple end hold', 0, false, false, true); - animation.addByPrefix('greenholdend', 'green hold end', 0, false, false, true); - animation.addByPrefix('redholdend', 'red hold end', 0, false, false, true); - animation.addByPrefix('blueholdend', 'blue hold end', 0, false, false, true); - } setGraphicSize(Std.int(width * 0.7)); updateHitbox(); @@ -184,7 +164,7 @@ class Note extends FlxSprite prevNote.animation.play('redhold'); } - prevNote.scale.y *= Conductor.stepCrochet / 100 * 1.5 * FlxG.save.data.noteSpeed; + prevNote.scale.y *= Conductor.stepCrochet / 100 * 1.5 * PlayState.SONG.speed; prevNote.updateHitbox(); // prevNote.setGraphicSize(); }