fixing saving in character editor
This commit is contained in:
@@ -51,6 +51,7 @@ class CharacterEditor extends UIState {
|
||||
public override function create() {
|
||||
super.create();
|
||||
|
||||
WindowTitle.endfix = " (Character Editor)";
|
||||
topMenu = [
|
||||
{
|
||||
label: "File",
|
||||
@@ -323,7 +324,7 @@ class CharacterEditor extends UIState {
|
||||
function _file_save(_) {
|
||||
#if sys
|
||||
sys.io.File.saveContent(
|
||||
Assets.getPath(Paths.xml('characters/${character.curCharacter}')),
|
||||
'${Paths.getAssetsRoot()}/data/characters/${character.curCharacter}.xml',
|
||||
buildCharacter()
|
||||
);
|
||||
return;
|
||||
|
||||
@@ -464,7 +464,6 @@ class Charter extends UIState {
|
||||
Framerate.memoryCounter.alpha = 1;
|
||||
Framerate.codenameBuildField.alpha = 1;
|
||||
}
|
||||
WindowTitle.reset();
|
||||
super.destroy();
|
||||
}
|
||||
|
||||
@@ -954,7 +953,7 @@ class Charter extends UIState {
|
||||
updateDisplaySprites();
|
||||
}
|
||||
|
||||
WindowTitle.prefix = undos.unsaved ? "UNSAVED | " : "";
|
||||
WindowTitle.prefix = undos.unsaved ? "● " : "";
|
||||
}
|
||||
|
||||
public static var startTime:Float = 0;
|
||||
|
||||
@@ -120,6 +120,7 @@ class UIState extends MusicBeatState {
|
||||
|
||||
public override function destroy() {
|
||||
super.destroy();
|
||||
WindowTitle.reset();
|
||||
__mousePos.put();
|
||||
FlxG.stage.window.onKeyDown.remove(onKeyDown);
|
||||
FlxG.stage.window.onKeyUp.remove(onKeyUp);
|
||||
|
||||
Reference in New Issue
Block a user