mirror of
https://github.com/ninjamuffin99/Funkin.git
synced 2024-12-30 16:56:47 +00:00
Merge branch 'master' of github.com:ninjamuffin99/Funkin-secret
This commit is contained in:
commit
3c538395fa
|
@ -350,6 +350,23 @@ class ChartingState extends MusicBeatState
|
|||
// vocals.stop();
|
||||
}
|
||||
|
||||
var pathShit = Paths.inst(daSong);
|
||||
|
||||
if (!openfl.utils.Assets.cache.hasSound(pathShit))
|
||||
{
|
||||
var library = Assets.getLibrary("songs");
|
||||
var symbolPath = pathShit.split(":").pop();
|
||||
// @:privateAccess
|
||||
// library.types.set(symbolPath, SOUND);
|
||||
// @:privateAccess
|
||||
// library.pathGroups.set(symbolPath, [library.__cacheBreak(symbolPath)]);
|
||||
// var callback = callbacks.add("song:" + pathShit);
|
||||
openfl.utils.Assets.loadSound(pathShit).onComplete(function(_)
|
||||
{
|
||||
// callback();
|
||||
});
|
||||
}
|
||||
|
||||
FlxG.sound.playMusic(Paths.inst(daSong), 0.6);
|
||||
|
||||
// WONT WORK FOR TUTORIAL OR TEST SONG!!! REDO LATER
|
||||
|
@ -549,7 +566,8 @@ class ChartingState extends MusicBeatState
|
|||
PlayState.SONG = _song;
|
||||
FlxG.sound.music.stop();
|
||||
vocals.stop();
|
||||
FlxG.switchState(new PlayState());
|
||||
LoadingState.loadAndSwitchState(new PlayState());
|
||||
// FlxG.switchState(new PlayState());
|
||||
}
|
||||
|
||||
if (FlxG.keys.justPressed.E)
|
||||
|
@ -1064,6 +1082,10 @@ class ChartingState extends MusicBeatState
|
|||
|
||||
var data:String = Json.stringify(json);
|
||||
|
||||
#if hl
|
||||
var filename = _song.song.toLowerCase();
|
||||
sys.io.File.saveContent('./$filename.json', data);
|
||||
#else
|
||||
if ((data != null) && (data.length > 0))
|
||||
{
|
||||
_file = new FileReference();
|
||||
|
@ -1072,6 +1094,7 @@ class ChartingState extends MusicBeatState
|
|||
_file.addEventListener(IOErrorEvent.IO_ERROR, onSaveError);
|
||||
_file.save(data.trim(), _song.song.toLowerCase() + ".json");
|
||||
}
|
||||
#end
|
||||
}
|
||||
|
||||
function onSaveComplete(_):Void
|
||||
|
|
|
@ -69,8 +69,8 @@ class DebugBoundingState extends FlxState
|
|||
|
||||
FlxG.cameras.add(hudCam, false);
|
||||
|
||||
// bg = FlxGridOverlay.create(10, 10);
|
||||
bg = new FlxSprite().makeGraphic(FlxG.width, FlxG.height, FlxColor.GREEN);
|
||||
bg = FlxGridOverlay.create(10, 10);
|
||||
// bg = new FlxSprite().makeGraphic(FlxG.width, FlxG.height, FlxColor.GREEN);
|
||||
|
||||
bg.scrollFactor.set();
|
||||
add(bg);
|
||||
|
|
Loading…
Reference in a new issue