Merge pull request #447 from theDetourist/patchnotes

Preparations to 1.4.3, add Patch Notes to Outdated screen and others
This commit is contained in:
Puyo 2021-05-14 09:09:45 +02:00 committed by GitHub
commit 582d0e41d8
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
5 changed files with 825 additions and 764 deletions

Binary file not shown.

After

Width:  |  Height:  |  Size: 102 KiB

View File

@ -155,9 +155,9 @@ class MainMenuState extends MusicBeatState
if (optionShit[curSelected] == 'donate') if (optionShit[curSelected] == 'donate')
{ {
#if linux #if linux
Sys.command('/usr/bin/xdg-open', ["https://ninja-muffin24.itch.io/funkin", "&"]); Sys.command('/usr/bin/xdg-open', ["https://www.kickstarter.com/projects/funkin/friday-night-funkin-the-full-ass-game", "&"]);
#else #else
FlxG.openURL('https://ninja-muffin24.itch.io/funkin'); FlxG.openURL('https://www.kickstarter.com/projects/funkin/friday-night-funkin-the-full-ass-game');
#end #end
} }
else else

View File

@ -4,7 +4,10 @@ import flixel.FlxG;
import flixel.FlxSprite; import flixel.FlxSprite;
import flixel.FlxSubState; import flixel.FlxSubState;
import flixel.text.FlxText; import flixel.text.FlxText;
import flixel.tweens.FlxEase;
import flixel.tweens.FlxTween;
import flixel.util.FlxColor; import flixel.util.FlxColor;
import flixel.util.FlxTimer;
import lime.app.Application; import lime.app.Application;
class OutdatedSubState extends MusicBeatState class OutdatedSubState extends MusicBeatState
@ -12,28 +15,78 @@ class OutdatedSubState extends MusicBeatState
public static var leftState:Bool = false; public static var leftState:Bool = false;
public static var needVer:String = "IDFK LOL"; public static var needVer:String = "IDFK LOL";
public static var currChanges:String = "dk";
private var bgColors:Array<String> = [
'#314d7f',
'#4e7093',
'#70526e',
'#594465'
];
private var colorRotation:Int = 1;
override function create() override function create()
{ {
super.create(); super.create();
var bg:FlxSprite = new FlxSprite().makeGraphic(FlxG.width, FlxG.height, FlxColor.BLACK); var bg:FlxSprite = new FlxSprite().loadGraphic(Paths.image('week54prototype', 'shared'));
bg.scale.x *= 1.55;
bg.scale.y *= 1.55;
bg.screenCenter();
add(bg); add(bg);
var kadeLogo:FlxSprite = new FlxSprite(FlxG.width, 0).loadGraphic(Paths.image('KadeEngineLogo'));
kadeLogo.scale.y = 0.3;
kadeLogo.scale.x = 0.3;
kadeLogo.x -= kadeLogo.frameHeight;
kadeLogo.y -= 180;
kadeLogo.alpha = 0.8;
add(kadeLogo);
var txt:FlxText = new FlxText(0, 0, FlxG.width, var txt:FlxText = new FlxText(0, 0, FlxG.width,
"Kade Engine is Outdated!\n" "Your Kade Engine is outdated!\nYou are on "
+ MainMenuState.kadeEngineVer + MainMenuState.kadeEngineVer
+ " is your current version\nwhile the most recent version is " + needVer + "\nwhile the most recent version is " + needVer + "."
+ "!\nPress Space to go to the github or ESCAPE to ignore this!!", + "\n\nWhat's new:\n\n"
+ currChanges
+ "\n& more changes and bugfixes in the full changelog"
+ "\n\nPress Space to view the full changelog and update\nor ESCAPE to ignore this",
32); 32);
txt.setFormat("VCR OSD Mono", 32, FlxColor.WHITE, CENTER);
txt.setFormat("VCR OSD Mono", 32, FlxColor.fromRGB(200, 200, 200), CENTER);
txt.borderColor = FlxColor.BLACK;
txt.borderSize = 3;
txt.borderStyle = FlxTextBorderStyle.OUTLINE;
txt.screenCenter(); txt.screenCenter();
add(txt); add(txt);
FlxTween.color(bg, 2, bg.color, FlxColor.fromString(bgColors[colorRotation]));
FlxTween.angle(kadeLogo, kadeLogo.angle, -10, 2, {ease: FlxEase.quartInOut});
new FlxTimer().start(2, function(tmr:FlxTimer)
{
FlxTween.color(bg, 2, bg.color, FlxColor.fromString(bgColors[colorRotation]));
if(colorRotation < (bgColors.length - 1)) colorRotation++;
else colorRotation = 0;
}, 0);
new FlxTimer().start(2, function(tmr:FlxTimer)
{
if(kadeLogo.angle == -10) FlxTween.angle(kadeLogo, kadeLogo.angle, 10, 2, {ease: FlxEase.quartInOut});
else FlxTween.angle(kadeLogo, kadeLogo.angle, -10, 2, {ease: FlxEase.quartInOut});
}, 0);
new FlxTimer().start(0.8, function(tmr:FlxTimer)
{
if(kadeLogo.alpha == 0.8) FlxTween.tween(kadeLogo, {alpha: 1}, 0.8, {ease: FlxEase.quartInOut});
else FlxTween.tween(kadeLogo, {alpha: 0.8}, 0.8, {ease: FlxEase.quartInOut});
}, 0);
} }
override function update(elapsed:Float) override function update(elapsed:Float)
{ {
if (controls.ACCEPT) if (controls.ACCEPT)
{ {
FlxG.openURL("https://github.com/KadeDev/Kade-Engine/releases/latest"); FlxG.openURL("https://kadedev.github.io/Kade-Engine/changelogs/changelog-" + needVer);
} }
if (controls.BACK) if (controls.BACK)
{ {

View File

@ -306,17 +306,21 @@ class TitleState extends MusicBeatState
new FlxTimer().start(2, function(tmr:FlxTimer) new FlxTimer().start(2, function(tmr:FlxTimer)
{ {
// Get current version of Kade Engine // Get current version of Kade Engine
var http = new haxe.Http("https://raw.githubusercontent.com/KadeDev/Kade-Engine/master/version.downloadMe"); //var http = new haxe.Http("https://raw.githubusercontent.com/KadeDev/Kade-Engine/master/version.downloadMe");
var http = new haxe.Http("https://raw.githubusercontent.com/theDetourist/Kade-Engine/patchnotes/version.downloadMe");
var returnedData:Array<String> = [];
http.onData = function (data:String) { http.onData = function (data:String)
{
if (!MainMenuState.kadeEngineVer.contains(data.trim()) && !OutdatedSubState.leftState && MainMenuState.nightly == "") returnedData[0] = data.substring(0, data.indexOf(';'));
returnedData[1] = data.substring(data.indexOf('-'), data.length);
if (!MainMenuState.kadeEngineVer.contains(returnedData[0].trim()) && !OutdatedSubState.leftState && MainMenuState.nightly == "")
{ {
trace('outdated lmao! ' + data.trim() + ' != ' + MainMenuState.kadeEngineVer); trace('outdated lmao! ' + returnedData[0] + ' != ' + MainMenuState.kadeEngineVer);
OutdatedSubState.needVer = data; OutdatedSubState.needVer = returnedData[0];
OutdatedSubState.currChanges = returnedData[1];
FlxG.switchState(new OutdatedSubState()); FlxG.switchState(new OutdatedSubState());
} }
else else
@ -331,7 +335,6 @@ class TitleState extends MusicBeatState
} }
http.request(); http.request();
}); });
// FlxG.sound.play(Paths.music('titleShoot'), 0.7); // FlxG.sound.play(Paths.music('titleShoot'), 0.7);
} }

View File

@ -1 +1,6 @@
1.4.2 1.4.2;
- Put the most
- important changes
- on these lines
- to make people update