Merge branch 'master' into master
This commit is contained in:
@ -180,10 +180,12 @@ class FreeplayState extends MusicBeatState
|
||||
if (curDifficulty > 2)
|
||||
curDifficulty = 0;
|
||||
|
||||
|
||||
#if !switch
|
||||
intendedScore = Highscore.getScore(songs[curSelected], curDifficulty);
|
||||
#end
|
||||
|
||||
|
||||
switch (curDifficulty)
|
||||
{
|
||||
case 0:
|
||||
@ -197,6 +199,7 @@ class FreeplayState extends MusicBeatState
|
||||
|
||||
function changeSelection(change:Int = 0)
|
||||
{
|
||||
|
||||
#if !switch
|
||||
NGio.logEvent('Fresh');
|
||||
#end
|
||||
@ -213,11 +216,13 @@ class FreeplayState extends MusicBeatState
|
||||
|
||||
// selector.y = (70 * curSelected) + 30;
|
||||
|
||||
|
||||
#if !switch
|
||||
intendedScore = Highscore.getScore(songs[curSelected], curDifficulty);
|
||||
// lerpScore = 0;
|
||||
#end
|
||||
|
||||
|
||||
FlxG.sound.playMusic('assets/music/' + songs[curSelected] + "_Inst" + TitleState.soundExt, 0);
|
||||
|
||||
var bullShit:Int = 0;
|
||||
|
@ -10,14 +10,17 @@ class Highscore
|
||||
public static var songScores:Map<String, Int> = new Map<String, Int>();
|
||||
#end
|
||||
|
||||
|
||||
public static function saveScore(song:String, score:Int = 0, ?diff:Int = 0):Void
|
||||
{
|
||||
var daSong:String = formatSong(song, diff);
|
||||
|
||||
|
||||
#if !switch
|
||||
NGio.postScore(score, song);
|
||||
#end
|
||||
|
||||
|
||||
if (songScores.exists(daSong))
|
||||
{
|
||||
if (songScores.get(daSong) < score)
|
||||
@ -29,10 +32,12 @@ class Highscore
|
||||
|
||||
public static function saveWeekScore(week:Int = 1, score:Int = 0, ?diff:Int = 0):Void
|
||||
{
|
||||
|
||||
#if !switch
|
||||
NGio.postScore(score, "Week " + week);
|
||||
#end
|
||||
|
||||
|
||||
var daWeek:String = formatSong('week' + week, diff);
|
||||
|
||||
if (songScores.exists(daWeek))
|
||||
|
@ -116,8 +116,10 @@ class MainMenuState extends MusicBeatState
|
||||
#if linux
|
||||
Sys.command('/usr/bin/xdg-open', ["https://ninja-muffin24.itch.io/funkin", "&"]);
|
||||
#else
|
||||
|
||||
FlxG.openURL('https://ninja-muffin24.itch.io/funkin');
|
||||
#end
|
||||
|
||||
}
|
||||
else
|
||||
{
|
||||
@ -151,7 +153,9 @@ class MainMenuState extends MusicBeatState
|
||||
trace("Story Menu Selected");
|
||||
case 'freeplay':
|
||||
FlxG.switchState(new FreeplayState());
|
||||
|
||||
trace("Freeplay Menu Selected");
|
||||
|
||||
case 'options':
|
||||
FlxG.switchState(new OptionsMenu());
|
||||
}
|
||||
|
@ -598,9 +598,6 @@ class PlayState extends MusicBeatState
|
||||
{
|
||||
super.update(elapsed);
|
||||
|
||||
trace("FlxG.sound.music.time: " + FlxG.sound.music.time);
|
||||
trace("Conductor.songPosition: " + Conductor.songPosition);
|
||||
|
||||
scoreTxt.text = "Score:" + songScore;
|
||||
|
||||
if (FlxG.keys.justPressed.ENTER && startedCountdown && canPause)
|
||||
@ -854,6 +851,7 @@ class PlayState extends MusicBeatState
|
||||
{
|
||||
canPause = false;
|
||||
|
||||
|
||||
#if !switch
|
||||
Highscore.saveScore(SONG.song, songScore, storyDifficulty);
|
||||
#end
|
||||
@ -872,10 +870,9 @@ class PlayState extends MusicBeatState
|
||||
|
||||
StoryMenuState.weekUnlocked[2] = true;
|
||||
|
||||
#if !switch
|
||||
NGio.unlockMedal(60961);
|
||||
Highscore.saveWeekScore(storyWeek, campaignScore, storyDifficulty);
|
||||
#end
|
||||
|
||||
|
||||
FlxG.save.data.weekUnlocked = StoryMenuState.weekUnlocked;
|
||||
FlxG.save.flush();
|
||||
|
@ -296,6 +296,7 @@ class StoryMenuState extends MusicBeatState
|
||||
|
||||
// USING THESE WEIRD VALUES SO THAT IT DOESNT FLOAT UP
|
||||
sprDifficulty.y = leftArrow.y - 15;
|
||||
intendedScore = Highscore.getWeekScore(curWeek, curDifficulty);
|
||||
|
||||
#if !switch
|
||||
intendedScore = Highscore.getWeekScore(curWeek, curDifficulty);
|
||||
@ -351,9 +352,10 @@ class StoryMenuState extends MusicBeatState
|
||||
|
||||
txtTracklist.screenCenter(X);
|
||||
txtTracklist.x -= FlxG.width * 0.35;
|
||||
|
||||
|
||||
#if !switch
|
||||
intendedScore = Highscore.getWeekScore(curWeek, curDifficulty);
|
||||
#end
|
||||
|
||||
}
|
||||
}
|
||||
|
@ -51,7 +51,8 @@ class TitleState extends MusicBeatState
|
||||
|
||||
super.create();
|
||||
|
||||
#if (web && !debug && NG_LOGIN)
|
||||
#if (!switch && !debug && NG_LOGIN)
|
||||
|
||||
var ng:NGio = new NGio(APIStuff.API, APIStuff.EncKey);
|
||||
#end
|
||||
|
||||
|
Reference in New Issue
Block a user