Skip to content

Commit

Permalink
Merge remote-tracking branch 'origin/main' into mobile
Browse files Browse the repository at this point in the history
  • Loading branch information
mcagabe19 committed Nov 13, 2024
2 parents 88fa730 + 1b37951 commit ec7357d
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 2 deletions.
2 changes: 1 addition & 1 deletion Project.xml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
<project>
<!-- _________________________ Application Settings _________________________ -->

<app title="Friday Night Funkin': JS Engine" file="JSEngine" packageName="com.JordanSantiago.JSengine" package="com.JordanSantiago.JSengine" main="Main" version="0.2.8" company="JordanSantiago" />
<app title="Friday Night Funkin': JS Engine" file="JSEngine" packageName="com.JordanSantiago.JSengine" package="com.JordanSantiago.JSengine" main="Main" version="0.3.0" company="JordanSantiago" />
<app preloader="flixel.system.FlxPreloader" />

<!-- ____________________________ Window Settings ___________________________ -->
Expand Down
11 changes: 10 additions & 1 deletion source/UpdateState.hx
Original file line number Diff line number Diff line change
Expand Up @@ -153,6 +153,7 @@ class UpdateState extends MusicBeatState
progressText.text = FlxMath.roundDecimal(entire_progress, 2) + "%";
download_info.text = currentFile;
download_info.x = (progBar_bg.x + progBar_bg.width) - download_info.width;
default:
}
}

Expand Down Expand Up @@ -314,7 +315,7 @@ class UpdateState extends MusicBeatState
File.saveBytes(path + "JS Engine v" + TitleState.updateVersion + ".zip", fileBytes);
text.text = "Unpacking update file...";
text.screenCenter(X);
// Uncompress.run(File.getBytes(path + "JS Engine v" + TitleState.updateVersion + ".zip"))

JSEZip.unzip(path + "JS Engine v" + TitleState.updateVersion + ".zip", "./update/raw/");
text.text = "Update has finished! The update will be installed shortly..";
text.screenCenter(X);
Expand All @@ -327,6 +328,14 @@ class UpdateState extends MusicBeatState
text.screenCenter(X);
#end

zip.removeEventListener(ProgressEvent.PROGRESS, onDownloadProgress);
zip.removeEventListener(openfl.events.Event.COMPLETE, onDownloadComplete);

progressText.text = 'Complete';
progressText.screenCenter(X);

currentTask = 'complete';

FlxG.sound.play(Paths.sound('confirmMenu'));

new FlxTimer().start(3, function(e:FlxTimer)
Expand Down

0 comments on commit ec7357d

Please sign in to comment.