icons and changelog and newgrounds
This commit is contained in:
@@ -14,6 +14,8 @@ import io.newgrounds.objects.events.Result.GetVersionResult;
|
||||
import lime.app.Application;
|
||||
import openfl.display.Stage;
|
||||
|
||||
using StringTools;
|
||||
|
||||
/**
|
||||
* MADE BY GEOKURELI THE LEGENED GOD HERO MVP
|
||||
*/
|
||||
@@ -28,6 +30,7 @@ class NGio
|
||||
public static var ngScoresLoaded(default, null):FlxSignal = new FlxSignal();
|
||||
|
||||
public static var GAME_VER:String = "";
|
||||
public static var GAME_VER_NUMS:String = '';
|
||||
public static var gotOnlineVer:Bool = false;
|
||||
|
||||
public static function noLogin(api:String)
|
||||
@@ -43,7 +46,8 @@ class NGio
|
||||
{
|
||||
var call = NG.core.calls.app.getCurrentVersion(GAME_VER).addDataHandler(function(response:Response<GetCurrentVersionResult>)
|
||||
{
|
||||
GAME_VER = response.result.data.current_version;
|
||||
GAME_VER = response.result.data.currentVersion;
|
||||
GAME_VER_NUMS = GAME_VER.split(" ")[0].trim();
|
||||
trace('CURRENT NG VERSION: ' + GAME_VER);
|
||||
gotOnlineVer = true;
|
||||
});
|
||||
|
||||
@@ -88,7 +88,10 @@ class TitleState extends MusicBeatState
|
||||
#elseif CHARTING
|
||||
FlxG.switchState(new ChartingState());
|
||||
#else
|
||||
startIntro();
|
||||
new FlxTimer().start(1, function(tmr:FlxTimer)
|
||||
{
|
||||
startIntro();
|
||||
});
|
||||
#end
|
||||
}
|
||||
|
||||
@@ -223,7 +226,8 @@ class TitleState extends MusicBeatState
|
||||
|
||||
override function update(elapsed:Float)
|
||||
{
|
||||
Conductor.songPosition = FlxG.sound.music.time;
|
||||
if (FlxG.sound.music != null)
|
||||
Conductor.songPosition = FlxG.sound.music.time;
|
||||
// FlxG.watch.addQuick('amp', FlxG.sound.music.amplitude);
|
||||
|
||||
if (FlxG.keys.justPressed.F)
|
||||
@@ -270,7 +274,7 @@ class TitleState extends MusicBeatState
|
||||
|
||||
var version:String = "v" + Application.current.meta.get('version');
|
||||
|
||||
if (version.trim() != NGio.GAME_VER.trim() && !OutdatedSubState.leftState)
|
||||
if (version.trim() != NGio.GAME_VER_NUMS && !OutdatedSubState.leftState)
|
||||
{
|
||||
trace('OLD VERSION!');
|
||||
FlxG.switchState(new OutdatedSubState());
|
||||
|
||||
Reference in New Issue
Block a user