From 3f2d35730cd0cc394c0fdb76bd4bca10f81706eb Mon Sep 17 00:00:00 2001 From: NeeEoo Date: Fri, 16 Feb 2024 10:10:24 +0100 Subject: [PATCH] Fixed --- source/funkin/backend/chart/ChartData.hx | 1 - source/funkin/game/Note.hx | 6 +++++- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/source/funkin/backend/chart/ChartData.hx b/source/funkin/backend/chart/ChartData.hx index 0c004aaa..fc293475 100644 --- a/source/funkin/backend/chart/ChartData.hx +++ b/source/funkin/backend/chart/ChartData.hx @@ -51,7 +51,6 @@ typedef ChartNote = { var id:Int; // strum id of the note var type:Int; // type (int) of the note var sLen:Float; // sustain length of the note (ms) - var ?extra:Map; } typedef ChartEvent = { diff --git a/source/funkin/game/Note.hx b/source/funkin/game/Note.hx index 5a3a8369..e72d62ec 100644 --- a/source/funkin/game/Note.hx +++ b/source/funkin/game/Note.hx @@ -117,7 +117,11 @@ class Note extends FlxSprite this.isSustainNote = sustain; this.sustainLength = sustainLength; this.strumLine = strumLine; - this.extra = noteData.extra; + for(field in Reflect.fields(noteData)) { + if(!["time", "id", "type", "sLen"].contains(field)) { + this.extra.set(field, Reflect.field(noteData, field)); + } + } x += 50; // MAKE SURE ITS DEFINITELY OFF SCREEN?