mirror of
https://github.com/ninjamuffin99/Funkin.git
synced 2025-03-21 01:19:26 +00:00
unhardcode notestyledropdown
This commit is contained in:
parent
7a0c7ade35
commit
fbcc73dcee
|
@ -126,10 +126,7 @@ class ChartEditorDropdowns
|
||||||
{
|
{
|
||||||
dropDown.dataSource.clear();
|
dropDown.dataSource.clear();
|
||||||
|
|
||||||
// hardcoding this because i dont want note kind styles to be shown as well
|
var noteStyleIds:Array<String> = NoteStyleRegistry.instance.listEntryIds();
|
||||||
// there is probably a better solution
|
|
||||||
// var noteStyleIds:Array<String> = NoteStyleRegistry.instance.listEntryIds();
|
|
||||||
var noteStyleIds:Array<String> = ['funkin', 'pixel'];
|
|
||||||
|
|
||||||
var returnValue:DropDownEntry = {id: "funkin", text: "Funkin'"};
|
var returnValue:DropDownEntry = {id: "funkin", text: "Funkin'"};
|
||||||
|
|
||||||
|
@ -138,6 +135,14 @@ class ChartEditorDropdowns
|
||||||
var noteStyle:Null<NoteStyle> = NoteStyleRegistry.instance.fetchEntry(noteStyleId);
|
var noteStyle:Null<NoteStyle> = NoteStyleRegistry.instance.fetchEntry(noteStyleId);
|
||||||
if (noteStyle == null) continue;
|
if (noteStyle == null) continue;
|
||||||
|
|
||||||
|
// check if the note style has all necessary assets (strums, notes, holdNotes)
|
||||||
|
if (noteStyle._data?.assets?.noteStrumline == null
|
||||||
|
|| noteStyle._data?.assets?.note == null
|
||||||
|
|| noteStyle._data?.assets?.holdNote == null)
|
||||||
|
{
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
|
||||||
var value = {id: noteStyleId, text: noteStyle.getName()};
|
var value = {id: noteStyleId, text: noteStyle.getName()};
|
||||||
if (startingStyleId == noteStyleId) returnValue = value;
|
if (startingStyleId == noteStyleId) returnValue = value;
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue