From 4c30c0da1602c51ebb1f8806e7c5bd7aa3ac4cd8 Mon Sep 17 00:00:00 2001 From: Yoshman29 <81191621+YoshiCrafter29@users.noreply.github.com> Date: Sat, 21 Jan 2023 16:47:41 +0100 Subject: [PATCH] moved game/NOTE_assets to game/notes/default --- .../game/{NOTE_assets.png => notes/default.png} | Bin .../game/{NOTE_assets.xml => notes/default.xml} | 0 buildnumber.txt | 2 +- source/funkin/game/Note.hx | 2 +- source/funkin/game/PlayState.hx | 4 ++-- source/funkin/options/keybinds/KeybindsOptions.hx | 2 +- .../funkin/scripting/events/StrumCreationEvent.hx | 2 +- source/funkin/system/Paths.hx | 4 ++-- 8 files changed, 8 insertions(+), 8 deletions(-) rename assets/images/game/{NOTE_assets.png => notes/default.png} (100%) rename assets/images/game/{NOTE_assets.xml => notes/default.xml} (100%) diff --git a/assets/images/game/NOTE_assets.png b/assets/images/game/notes/default.png similarity index 100% rename from assets/images/game/NOTE_assets.png rename to assets/images/game/notes/default.png diff --git a/assets/images/game/NOTE_assets.xml b/assets/images/game/notes/default.xml similarity index 100% rename from assets/images/game/NOTE_assets.xml rename to assets/images/game/notes/default.xml diff --git a/buildnumber.txt b/buildnumber.txt index 7637952e..1bf1dcc8 100644 --- a/buildnumber.txt +++ b/buildnumber.txt @@ -1 +1 @@ -2136 \ No newline at end of file +2140 \ No newline at end of file diff --git a/source/funkin/game/Note.hx b/source/funkin/game/Note.hx index 71c5270a..afe512fa 100644 --- a/source/funkin/game/Note.hx +++ b/source/funkin/game/Note.hx @@ -113,7 +113,7 @@ class Note extends FlxSprite this.noteData = noteData; var customType = Paths.image('game/notes/${this.noteType}'); - var event = EventManager.get(NoteCreationEvent).recycle(this, strumID, this.noteType, noteTypeID, strumLineID, mustPress, Assets.exists(customType) ? 'game/notes/${this.noteType}' : 'game/NOTE_assets', 0.7, animSuffix); + var event = EventManager.get(NoteCreationEvent).recycle(this, strumID, this.noteType, noteTypeID, strumLineID, mustPress, Assets.exists(customType) ? 'game/notes/${this.noteType}' : 'game/notes/default', 0.7, animSuffix); if (PlayState.instance != null) event = PlayState.instance.scripts.event("onNoteCreation", event); diff --git a/source/funkin/game/PlayState.hx b/source/funkin/game/PlayState.hx index fa2d6c8f..1269284e 100644 --- a/source/funkin/game/PlayState.hx +++ b/source/funkin/game/PlayState.hx @@ -937,14 +937,14 @@ class PlayState extends MusicBeatState curSong = songData.song.toLowerCase(); - inst = FlxG.sound.load(Paths.inst(PlayState.SONG.song)); + inst = FlxG.sound.load(Paths.inst(SONG.song, difficulty)); vocals = FlxG.sound.list.recycle(FlxSound); @:privateAccess { vocals.reset(); vocals.exists = true; } if (SONG.needsVoices) - vocals.loadEmbedded(Paths.voices(PlayState.SONG.song)); + vocals.loadEmbedded(Paths.voices(SONG.song, difficulty)); FlxG.sound.list.add(vocals); inst.persist = vocals.persist = false; diff --git a/source/funkin/options/keybinds/KeybindsOptions.hx b/source/funkin/options/keybinds/KeybindsOptions.hx index 7bbdae4a..fb8b0292 100644 --- a/source/funkin/options/keybinds/KeybindsOptions.hx +++ b/source/funkin/options/keybinds/KeybindsOptions.hx @@ -152,7 +152,7 @@ class KeybindsOptions extends MusicBeatSubstate { var sparrowIcon:String = null; var sparrowAnim:String = null; if (e.name.startsWith('{note')) {// is actually a note!! - sparrowIcon = "game/NOTE_assets"; + sparrowIcon = "game/notes/default"; sparrowAnim = switch(e.name) { case '{noteLeft}': "purple0"; diff --git a/source/funkin/scripting/events/StrumCreationEvent.hx b/source/funkin/scripting/events/StrumCreationEvent.hx index 5b986c20..1a8c1cce 100644 --- a/source/funkin/scripting/events/StrumCreationEvent.hx +++ b/source/funkin/scripting/events/StrumCreationEvent.hx @@ -24,7 +24,7 @@ class StrumCreationEvent extends CancellableEvent { /** * Sprite path, in case you only want to change the sprite. */ - public var sprite:String = "game/NOTE_assets"; + public var sprite:String = "game/notes/default"; /** * Cancels the animation that makes the strum "land" in the strumline. diff --git a/source/funkin/system/Paths.hx b/source/funkin/system/Paths.hx index 274c0cbd..61ceabaf 100644 --- a/source/funkin/system/Paths.hx +++ b/source/funkin/system/Paths.hx @@ -110,13 +110,13 @@ class Paths inline static public function voices(song:String, difficulty:String = "normal") { - var diff = getPath('songs/${song.toLowerCase()}/song/Voices-$difficulty.$SOUND_EXT', MUSIC, null); + var diff = getPath('songs/${song.toLowerCase()}/song/Voices-${difficulty.toLowerCase()}.$SOUND_EXT', MUSIC, null); return OpenFlAssets.exists(diff) ? diff : getPath('songs/${song.toLowerCase()}/song/Voices.$SOUND_EXT', MUSIC, null); } inline static public function inst(song:String, difficulty:String = "normal") { - var diff = getPath('songs/${song.toLowerCase()}/song/Inst-$difficulty.$SOUND_EXT', MUSIC, null); + var diff = getPath('songs/${song.toLowerCase()}/song/Inst-${difficulty.toLowerCase()}.$SOUND_EXT', MUSIC, null); return OpenFlAssets.exists(diff) ? diff : getPath('songs/${song.toLowerCase()}/song/Inst.$SOUND_EXT', MUSIC, null); }