crash on story menu

This commit is contained in:
Brandon 2020-11-07 00:05:58 -05:00
parent 673ed0d7fd
commit 602cf4c574
6 changed files with 14 additions and 7 deletions

View File

@ -29,7 +29,7 @@ class Preloader extends FlxBasePreloader
this._width = Lib.current.stage.stageWidth;
this._height = Lib.current.stage.stageHeight;
var ratio:Float = this._width / 800; //This allows us to scale assets depending on the size of the screen.
var ratio:Float = this._width / 1920; //This allows us to scale assets depending on the size of the screen.
logo = new Sprite();
logo.addChild(new Bitmap(new LogoImage(0,0))); //Sets the graphic of the sprite to a Bitmap object, which uses our embedded BitmapData class.

View File

@ -37,8 +37,8 @@
<classpath name="source" />
<assets path="assets/images"/>
<assets path="assets/data"/>
<assets path="assets/images" />
<assets path="assets/data" />
<assets path="assets/music" include="*.mp3" if="web" />
<assets path="assets/music" include="*.ogg" unless="web" />
@ -59,7 +59,8 @@
<!--In case you want to use the ui package-->
<haxelib name="flixel-ui" />
<haxelib name="newgrounds" unless="switch" />
<haxelib name="newgrounds" />
<haxelib name="faxe" />
<!-- <haxelib name="markdown" /> -->
<!-- <haxelib name="HtmlParser" /> -->

View File

@ -4,3 +4,5 @@ This is the repository for Friday Night Funkin, a game originally made for Ludum
Play the Ludum Dare prototype here: https://ninja-muffin24.itch.io/friday-night-funkin
Play the Newgrounds one here: https://www.newgrounds.com/portal/view/770371
## BrandyBuizel porting this shit like a G to Nintendo Switch

Binary file not shown.

Before

Width:  |  Height:  |  Size: 200 KiB

After

Width:  |  Height:  |  Size: 434 KiB

View File

@ -184,7 +184,9 @@ class FreeplayState extends MusicBeatState
function changeSelection(change:Int = 0)
{
#if !switch
NGio.logEvent('Fresh');
#end
curSelected += change;

View File

@ -30,6 +30,9 @@ import flixel.util.FlxTimer;
import haxe.Json;
import lime.utils.Assets;
//New Audio BS
//import faxe.Faxe;
using StringTools;
class PlayState extends MusicBeatState
@ -841,9 +844,7 @@ class PlayState extends MusicBeatState
function endSong():Void
{
#if !switch
Highscore.saveScore(SONG.song, songScore, storyDifficulty);
#end
if (isStoryMode)
{
@ -861,9 +862,10 @@ class PlayState extends MusicBeatState
#if !switch
NGio.unlockMedal(60961);
Highscore.saveWeekScore(storyWeek, campaignScore, storyDifficulty);
#end
Highscore.saveWeekScore(storyWeek, campaignScore, storyDifficulty);
FlxG.save.data.weekUnlocked = StoryMenuState.weekUnlocked;
FlxG.save.flush();
}