caught up to cam
This commit is contained in:
41
CHANGELOG.md
41
CHANGELOG.md
@@ -1,16 +1,37 @@
|
|||||||
# Changelog
|
# Changelog
|
||||||
All notable changes will be documented in this file.
|
All notable changes will be documented in this file.
|
||||||
|
|
||||||
## [1.1.0]
|
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
|
||||||
### Added
|
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
|
||||||
- 32bit support
|
|
||||||
- Controller (dancepads) support
|
|
||||||
- Pause screen
|
|
||||||
- Main Menu overhaul
|
|
||||||
- Cool intro screen thing
|
|
||||||
- Uh lots of bullshit
|
|
||||||
- Remind me to actually add this later lmaooo
|
|
||||||
|
|
||||||
## [1.0.0] - 2020-10-05
|
## [0.2.1.2] - 2020-11-06
|
||||||
|
### Fixed
|
||||||
|
- Story mode scores not properly resetting, leading to VERY inflated highscores on the leaderboards. This also requires me to clear the scores that are on the leaderboard right now, sorry!
|
||||||
|
- Difficulty on storymode and in freeplay scores
|
||||||
|
|
||||||
|
## [0.2.1.1] - 2020-11-06
|
||||||
|
### Fixed
|
||||||
|
- Week 2 not unlocking properly
|
||||||
|
|
||||||
|
## [0.2.1] - 2020-11-06
|
||||||
|
### Added
|
||||||
|
- Scores to the freeplay menu
|
||||||
|
- A few new intro boot messages.
|
||||||
|
- Lightning effect in Spooky stages
|
||||||
|
- Campaign scores, can now compete on scoreboards for campaign!
|
||||||
|
- Can now change difficulties in Freeplay mode
|
||||||
|
|
||||||
|
### Changed
|
||||||
|
- Balanced out Normal mode for the harder songs(Dadbattle and Spookeez, not South yet). Should be much easier all around.
|
||||||
|
- Put tutorial in it's own 'week', so that if you want to play week 1, you don't have to play the tutorial.
|
||||||
|
|
||||||
|
### Fixed
|
||||||
|
- One of the charting bits on South and Spookeez during the intro.
|
||||||
|
|
||||||
|
## [0.2.0] - 2020-11-01
|
||||||
|
### Added
|
||||||
|
- Uhh Newgrounds release lolol I always lose track of shit.
|
||||||
|
|
||||||
|
## [0.1.0] - 2020-10-05
|
||||||
### Added
|
### Added
|
||||||
- Uh, everything. This the game's initial gamejam release. We put it out
|
- Uh, everything. This the game's initial gamejam release. We put it out
|
||||||
12
Project.xml
12
Project.xml
@@ -2,7 +2,7 @@
|
|||||||
<project>
|
<project>
|
||||||
<!-- _________________________ Application Settings _________________________ -->
|
<!-- _________________________ Application Settings _________________________ -->
|
||||||
|
|
||||||
<app title="Friday Night Funkin" file="Funkin" packageName="com.ninjamuffin99.funkin" main="Main" version="0.0.1" company="ninjamuffin99" />
|
<app title="Friday Night Funkin" file="Funkin" packageName="com.ninjamuffin99.funkin" main="Main" version="0.2.1.2" company="ninjamuffin99" />
|
||||||
|
|
||||||
<!--The flixel preloader is not accurate in Chrome. You can use it regularly if you embed the swf into a html file
|
<!--The flixel preloader is not accurate in Chrome. You can use it regularly if you embed the swf into a html file
|
||||||
or you can set the actual size of your file manually at "FlxPreloaderBase-onUpdate-bytesTotal"-->
|
or you can set the actual size of your file manually at "FlxPreloaderBase-onUpdate-bytesTotal"-->
|
||||||
@@ -45,8 +45,9 @@
|
|||||||
<assets path="assets/sounds" include="*.mp3" if="web" />
|
<assets path="assets/sounds" include="*.mp3" if="web" />
|
||||||
<assets path="assets/sounds" include="*.ogg" unless="web" />
|
<assets path="assets/sounds" include="*.ogg" unless="web" />
|
||||||
|
|
||||||
<assets path="assets/fonts/vcr.ttf" embed="true" />
|
<assets path="CHANGELOG.md"/>
|
||||||
|
|
||||||
|
<assets path="assets/fonts/vcr.ttf" embed="true" />
|
||||||
|
|
||||||
<!-- _______________________________ Libraries ______________________________ -->
|
<!-- _______________________________ Libraries ______________________________ -->
|
||||||
|
|
||||||
@@ -58,6 +59,9 @@
|
|||||||
|
|
||||||
<!--In case you want to use the ui package-->
|
<!--In case you want to use the ui package-->
|
||||||
<haxelib name="flixel-ui" />
|
<haxelib name="flixel-ui" />
|
||||||
|
<haxelib name="newgrounds" />
|
||||||
|
<haxelib name="markdown" />
|
||||||
|
<haxelib name="HtmlParser" />
|
||||||
|
|
||||||
<!--In case you want to use nape with flixel-->
|
<!--In case you want to use nape with flixel-->
|
||||||
<!--<haxelib name="nape-haxe4" />-->
|
<!--<haxelib name="nape-haxe4" />-->
|
||||||
@@ -100,7 +104,5 @@
|
|||||||
|
|
||||||
<icon path="art/icon.png" />
|
<icon path="art/icon.png" />
|
||||||
<!-- <haxedef name="SKIP_TO_PLAYSTATE" if="debug" /> -->
|
<!-- <haxedef name="SKIP_TO_PLAYSTATE" if="debug" /> -->
|
||||||
<haxedef name="NG_LOGIN" />
|
<haxedef name="NG_LOGIN" if="newgrounds" />
|
||||||
|
|
||||||
|
|
||||||
</project>
|
</project>
|
||||||
|
|||||||
Binary file not shown.
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
Binary file not shown.
|
Before Width: | Height: | Size: 64 KiB After Width: | Height: | Size: 64 KiB |
@@ -5,19 +5,18 @@
|
|||||||
<SubTexture name="EASY0000" x="0" y="0" width="196" height="65"/>
|
<SubTexture name="EASY0000" x="0" y="0" width="196" height="65"/>
|
||||||
<SubTexture name="HARD0000" x="206" y="0" width="211" height="67"/>
|
<SubTexture name="HARD0000" x="206" y="0" width="211" height="67"/>
|
||||||
<SubTexture name="NORMAL0000" x="427" y="0" width="308" height="67"/>
|
<SubTexture name="NORMAL0000" x="427" y="0" width="308" height="67"/>
|
||||||
|
<SubTexture name="WEEK10000" x="0" y="77" width="360" height="89"/>
|
||||||
<SubTexture name="WEEK1 select0000" x="0" y="77" width="360" height="89"/>
|
<SubTexture name="WEEK1 select0000" x="0" y="77" width="360" height="89"/>
|
||||||
<SubTexture name="WEEK1 select0001" x="370" y="77" width="360" height="89"/>
|
<SubTexture name="WEEK1 select0001" x="370" y="77" width="360" height="89"/>
|
||||||
|
<SubTexture name="WEEK20000" x="0" y="279" width="361" height="87"/>
|
||||||
<SubTexture name="arrow left0000" x="740" y="77" width="48" height="85"/>
|
<SubTexture name="arrow left0000" x="740" y="77" width="48" height="85"/>
|
||||||
<SubTexture name="arrow push left0000" x="798" y="77" width="42" height="75"/>
|
<SubTexture name="arrow push left0000" x="798" y="77" width="42" height="75"/>
|
||||||
<SubTexture name="arrow push right0000" x="850" y="77" width="41" height="74"/>
|
<SubTexture name="arrow push right0000" x="850" y="77" width="41" height="74"/>
|
||||||
<SubTexture name="arrow right0000" x="901" y="77" width="47" height="85"/>
|
<SubTexture name="arrow right0000" x="901" y="77" width="47" height="85"/>
|
||||||
<SubTexture name="lock0000" x="0" y="176" width="67" height="93"/>
|
<SubTexture name="lock0000" x="0" y="176" width="67" height="93"/>
|
||||||
<SubTexture name="week 2 CANNOT select0000" x="77" y="176" width="361" height="87" frameX="-10" frameY="0" frameWidth="383" frameHeight="87"/>
|
<SubTexture name="tutorial0000" x="77" y="176" width="443" height="82"/>
|
||||||
<SubTexture name="week 2 CANNOT select0001" x="448" y="176" width="361" height="87" frameX="0" frameY="0" frameWidth="383" frameHeight="87"/>
|
<SubTexture name="tutorial selected0000" x="77" y="176" width="443" height="82"/>
|
||||||
<SubTexture name="week 2 CANNOT select0002" x="0" y="279" width="362" height="87" frameX="-21" frameY="0" frameWidth="383" frameHeight="87"/>
|
<SubTexture name="tutorial selected0001" x="530" y="176" width="443" height="82"/>
|
||||||
<SubTexture name="week 2 CANNOT select0003" x="448" y="176" width="361" height="87" frameX="-7" frameY="0" frameWidth="383" frameHeight="87"/>
|
<SubTexture name="week2 select0000" x="0" y="279" width="361" height="87"/>
|
||||||
<SubTexture name="week 2 CANNOT select0004" x="77" y="176" width="361" height="87" frameX="-11" frameY="0" frameWidth="383" frameHeight="87"/>
|
<SubTexture name="week2 select0001" x="371" y="279" width="361" height="87"/>
|
||||||
<SubTexture name="week 2 CANNOT select0005" x="77" y="176" width="361" height="87" frameX="-11" frameY="0" frameWidth="383" frameHeight="87"/>
|
|
||||||
<SubTexture name="week2 select0000" x="77" y="176" width="361" height="87" frameX="0" frameY="0" frameWidth="383" frameHeight="87"/>
|
|
||||||
<SubTexture name="week2 select0001" x="372" y="279" width="361" height="87"/>
|
|
||||||
</TextureAtlas>
|
</TextureAtlas>
|
||||||
|
|||||||
BIN
assets/images/menuDesat.png
Normal file
BIN
assets/images/menuDesat.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 350 KiB |
@@ -28,7 +28,9 @@ import openfl.events.Event;
|
|||||||
import openfl.events.IOErrorEvent;
|
import openfl.events.IOErrorEvent;
|
||||||
import openfl.events.IOErrorEvent;
|
import openfl.events.IOErrorEvent;
|
||||||
import openfl.events.IOErrorEvent;
|
import openfl.events.IOErrorEvent;
|
||||||
|
import openfl.media.Sound;
|
||||||
import openfl.net.FileReference;
|
import openfl.net.FileReference;
|
||||||
|
import openfl.utils.ByteArray;
|
||||||
|
|
||||||
using StringTools;
|
using StringTools;
|
||||||
|
|
||||||
@@ -762,6 +764,13 @@ class ChartingState extends MusicBeatState
|
|||||||
FlxG.resetState();
|
FlxG.resetState();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
var mp3File:Sound;
|
||||||
|
var waveForm:FlxSprite;
|
||||||
|
|
||||||
|
function drawWave():Void
|
||||||
|
{
|
||||||
|
}
|
||||||
|
|
||||||
private function saveLevel()
|
private function saveLevel()
|
||||||
{
|
{
|
||||||
var json = {
|
var json = {
|
||||||
|
|||||||
@@ -1,10 +1,15 @@
|
|||||||
package;
|
package;
|
||||||
|
|
||||||
|
import flash.text.TextField;
|
||||||
import flixel.FlxG;
|
import flixel.FlxG;
|
||||||
import flixel.FlxSprite;
|
import flixel.FlxSprite;
|
||||||
import flixel.addons.display.FlxGridOverlay;
|
import flixel.addons.display.FlxGridOverlay;
|
||||||
import flixel.group.FlxGroup.FlxTypedGroup;
|
import flixel.group.FlxGroup.FlxTypedGroup;
|
||||||
|
import flixel.math.FlxMath;
|
||||||
import flixel.text.FlxText;
|
import flixel.text.FlxText;
|
||||||
|
import flixel.util.FlxColor;
|
||||||
|
import htmlparser.HtmlDocument;
|
||||||
|
import lime.utils.Assets;
|
||||||
|
|
||||||
class FreeplayState extends MusicBeatState
|
class FreeplayState extends MusicBeatState
|
||||||
{
|
{
|
||||||
@@ -12,13 +17,22 @@ class FreeplayState extends MusicBeatState
|
|||||||
|
|
||||||
var selector:FlxText;
|
var selector:FlxText;
|
||||||
var curSelected:Int = 0;
|
var curSelected:Int = 0;
|
||||||
|
var curDifficulty:Int = 1;
|
||||||
|
|
||||||
|
var scoreText:FlxText;
|
||||||
|
var diffText:FlxText;
|
||||||
|
var lerpScore:Int = 0;
|
||||||
|
var intendedScore:Int = 0;
|
||||||
|
|
||||||
private var grpSongs:FlxTypedGroup<Alphabet>;
|
private var grpSongs:FlxTypedGroup<Alphabet>;
|
||||||
|
|
||||||
override function create()
|
override function create()
|
||||||
|
{
|
||||||
|
if (FlxG.sound.music != null)
|
||||||
{
|
{
|
||||||
if (!FlxG.sound.music.playing)
|
if (!FlxG.sound.music.playing)
|
||||||
FlxG.sound.playMusic('assets/music/freakyMenu' + TitleState.soundExt);
|
FlxG.sound.playMusic('assets/music/freakyMenu' + TitleState.soundExt);
|
||||||
|
}
|
||||||
|
|
||||||
var isDebug:Bool = false;
|
var isDebug:Bool = false;
|
||||||
|
|
||||||
@@ -53,7 +67,23 @@ class FreeplayState extends MusicBeatState
|
|||||||
// songText.screenCenter(X);
|
// songText.screenCenter(X);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
scoreText = new FlxText(FlxG.width * 0.7, 5, 0, "", 32);
|
||||||
|
// scoreText.autoSize = false;
|
||||||
|
scoreText.setFormat("assets/fonts/vcr.ttf", 32, FlxColor.WHITE, RIGHT);
|
||||||
|
// scoreText.alignment = RIGHT;
|
||||||
|
|
||||||
|
var scoreBG:FlxSprite = new FlxSprite(scoreText.x - 6, 0).makeGraphic(Std.int(FlxG.width * 0.35), 66, 0xFF000000);
|
||||||
|
scoreBG.alpha = 0.6;
|
||||||
|
add(scoreBG);
|
||||||
|
|
||||||
|
diffText = new FlxText(scoreText.x, scoreText.y + 36, 0, "", 24);
|
||||||
|
diffText.font = scoreText.font;
|
||||||
|
add(diffText);
|
||||||
|
|
||||||
|
add(scoreText);
|
||||||
|
|
||||||
changeSelection();
|
changeSelection();
|
||||||
|
changeDiff();
|
||||||
|
|
||||||
// FlxG.sound.playMusic('assets/music/title' + TitleState.soundExt, 0);
|
// FlxG.sound.playMusic('assets/music/title' + TitleState.soundExt, 0);
|
||||||
// FlxG.sound.music.fadeIn(2, 0, 0.8);
|
// FlxG.sound.music.fadeIn(2, 0, 0.8);
|
||||||
@@ -65,12 +95,33 @@ class FreeplayState extends MusicBeatState
|
|||||||
|
|
||||||
var swag:Alphabet = new Alphabet(1, 0, "swag");
|
var swag:Alphabet = new Alphabet(1, 0, "swag");
|
||||||
|
|
||||||
|
// JUST DOIN THIS SHIT FOR TESTING!!!
|
||||||
|
/*
|
||||||
|
var md:String = Markdown.markdownToHtml(Assets.getText('CHANGELOG.md'));
|
||||||
|
|
||||||
|
var texFel:TextField = new TextField();
|
||||||
|
texFel.width = FlxG.width;
|
||||||
|
texFel.height = FlxG.height;
|
||||||
|
// texFel.
|
||||||
|
texFel.htmlText = md;
|
||||||
|
|
||||||
|
FlxG.stage.addChild(texFel);
|
||||||
|
|
||||||
|
// scoreText.textField.htmlText = md;
|
||||||
|
|
||||||
|
trace(md);
|
||||||
|
*/
|
||||||
|
|
||||||
super.create();
|
super.create();
|
||||||
}
|
}
|
||||||
|
|
||||||
override function update(elapsed:Float)
|
override function update(elapsed:Float)
|
||||||
{
|
{
|
||||||
super.update(elapsed);
|
super.update(elapsed);
|
||||||
|
|
||||||
|
lerpScore = Math.floor(FlxMath.lerp(lerpScore, intendedScore, 0.4));
|
||||||
|
scoreText.text = "PERSONAL BEST:" + lerpScore;
|
||||||
|
|
||||||
var upP = controls.UP_P;
|
var upP = controls.UP_P;
|
||||||
var downP = controls.DOWN_P;
|
var downP = controls.DOWN_P;
|
||||||
var accepted = controls.ACCEPT;
|
var accepted = controls.ACCEPT;
|
||||||
@@ -84,6 +135,11 @@ class FreeplayState extends MusicBeatState
|
|||||||
changeSelection(1);
|
changeSelection(1);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (controls.LEFT_P)
|
||||||
|
changeDiff(-1);
|
||||||
|
if (controls.RIGHT_P)
|
||||||
|
changeDiff(1);
|
||||||
|
|
||||||
if (controls.BACK)
|
if (controls.BACK)
|
||||||
{
|
{
|
||||||
FlxG.switchState(new MainMenuState());
|
FlxG.switchState(new MainMenuState());
|
||||||
@@ -91,15 +147,45 @@ class FreeplayState extends MusicBeatState
|
|||||||
|
|
||||||
if (accepted)
|
if (accepted)
|
||||||
{
|
{
|
||||||
PlayState.SONG = Song.loadFromJson(songs[curSelected].toLowerCase(), songs[curSelected].toLowerCase());
|
var poop:String = Highscore.formatSong(songs[curSelected].toLowerCase(), curDifficulty);
|
||||||
|
|
||||||
|
trace(poop);
|
||||||
|
|
||||||
|
PlayState.SONG = Song.loadFromJson(poop, songs[curSelected].toLowerCase());
|
||||||
PlayState.isStoryMode = false;
|
PlayState.isStoryMode = false;
|
||||||
|
PlayState.storyDifficulty = curDifficulty;
|
||||||
FlxG.switchState(new PlayState());
|
FlxG.switchState(new PlayState());
|
||||||
|
if (FlxG.sound.music != null)
|
||||||
FlxG.sound.music.stop();
|
FlxG.sound.music.stop();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
function changeDiff(change:Int = 0)
|
||||||
|
{
|
||||||
|
curDifficulty += change;
|
||||||
|
|
||||||
|
if (curDifficulty < 0)
|
||||||
|
curDifficulty = 2;
|
||||||
|
if (curDifficulty > 2)
|
||||||
|
curDifficulty = 0;
|
||||||
|
|
||||||
|
intendedScore = Highscore.getScore(songs[curSelected], curDifficulty);
|
||||||
|
|
||||||
|
switch (curDifficulty)
|
||||||
|
{
|
||||||
|
case 0:
|
||||||
|
diffText.text = "EASY";
|
||||||
|
case 1:
|
||||||
|
diffText.text = 'NORMAL';
|
||||||
|
case 2:
|
||||||
|
diffText.text = "HARD";
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
function changeSelection(change:Int = 0)
|
function changeSelection(change:Int = 0)
|
||||||
{
|
{
|
||||||
|
NGio.logEvent('Fresh');
|
||||||
|
|
||||||
curSelected += change;
|
curSelected += change;
|
||||||
|
|
||||||
if (curSelected < 0)
|
if (curSelected < 0)
|
||||||
@@ -109,6 +195,9 @@ class FreeplayState extends MusicBeatState
|
|||||||
|
|
||||||
// selector.y = (70 * curSelected) + 30;
|
// selector.y = (70 * curSelected) + 30;
|
||||||
|
|
||||||
|
intendedScore = Highscore.getScore(songs[curSelected], curDifficulty);
|
||||||
|
// lerpScore = 0;
|
||||||
|
|
||||||
var bullShit:Int = 0;
|
var bullShit:Int = 0;
|
||||||
|
|
||||||
for (item in grpSongs.members)
|
for (item in grpSongs.members)
|
||||||
|
|||||||
85
source/Highscore.hx
Normal file
85
source/Highscore.hx
Normal file
@@ -0,0 +1,85 @@
|
|||||||
|
package;
|
||||||
|
|
||||||
|
import flixel.FlxG;
|
||||||
|
|
||||||
|
class Highscore
|
||||||
|
{
|
||||||
|
public static var songScores:Map<String, Int> = new Map();
|
||||||
|
|
||||||
|
public static function saveScore(song:String, score:Int = 0, ?diff:Int = 0):Void
|
||||||
|
{
|
||||||
|
var daSong:String = formatSong(song, diff);
|
||||||
|
|
||||||
|
NGio.postScore(score, song);
|
||||||
|
|
||||||
|
if (songScores.exists(daSong))
|
||||||
|
{
|
||||||
|
if (songScores.get(daSong) < score)
|
||||||
|
setScore(daSong, score);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
setScore(daSong, score);
|
||||||
|
}
|
||||||
|
|
||||||
|
public static function saveWeekScore(week:Int = 1, score:Int = 0, ?diff:Int = 0):Void
|
||||||
|
{
|
||||||
|
NGio.postScore(score, "Week " + week);
|
||||||
|
|
||||||
|
var daWeek:String = formatSong('week' + week, diff);
|
||||||
|
|
||||||
|
if (songScores.exists(daWeek))
|
||||||
|
{
|
||||||
|
if (songScores.get(daWeek) < score)
|
||||||
|
setScore(daWeek, score);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
setScore(daWeek, score);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* YOU SHOULD FORMAT SONG WITH formatSong() BEFORE TOSSING IN SONG VARIABLE
|
||||||
|
*/
|
||||||
|
static function setScore(song:String, score:Int):Void
|
||||||
|
{
|
||||||
|
// Reminder that I don't need to format this song, it should come formatted!
|
||||||
|
songScores.set(song, score);
|
||||||
|
FlxG.save.data.songScores = songScores;
|
||||||
|
FlxG.save.flush();
|
||||||
|
}
|
||||||
|
|
||||||
|
public static function formatSong(song:String, diff:Int):String
|
||||||
|
{
|
||||||
|
var daSong:String = song;
|
||||||
|
|
||||||
|
if (diff == 0)
|
||||||
|
daSong += '-easy';
|
||||||
|
else if (diff == 2)
|
||||||
|
daSong += '-hard';
|
||||||
|
|
||||||
|
return daSong;
|
||||||
|
}
|
||||||
|
|
||||||
|
public static function getScore(song:String, diff:Int):Int
|
||||||
|
{
|
||||||
|
if (!songScores.exists(formatSong(song, diff)))
|
||||||
|
setScore(formatSong(song, diff), 0);
|
||||||
|
|
||||||
|
return songScores.get(formatSong(song, diff));
|
||||||
|
}
|
||||||
|
|
||||||
|
public static function getWeekScore(week:Int, diff:Int):Int
|
||||||
|
{
|
||||||
|
if (!songScores.exists(formatSong('week' + week, diff)))
|
||||||
|
setScore(formatSong('week' + week, diff), 0);
|
||||||
|
|
||||||
|
return songScores.get(formatSong('week' + week, diff));
|
||||||
|
}
|
||||||
|
|
||||||
|
public static function load():Void
|
||||||
|
{
|
||||||
|
if (FlxG.save.data.songScores != null)
|
||||||
|
{
|
||||||
|
songScores = FlxG.save.data.songScores;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -6,8 +6,11 @@ import flixel.FlxSprite;
|
|||||||
import flixel.effects.FlxFlicker;
|
import flixel.effects.FlxFlicker;
|
||||||
import flixel.graphics.frames.FlxAtlasFrames;
|
import flixel.graphics.frames.FlxAtlasFrames;
|
||||||
import flixel.group.FlxGroup.FlxTypedGroup;
|
import flixel.group.FlxGroup.FlxTypedGroup;
|
||||||
|
import flixel.text.FlxText;
|
||||||
import flixel.tweens.FlxEase;
|
import flixel.tweens.FlxEase;
|
||||||
import flixel.tweens.FlxTween;
|
import flixel.tweens.FlxTween;
|
||||||
|
import flixel.util.FlxColor;
|
||||||
|
import lime.app.Application;
|
||||||
|
|
||||||
class MainMenuState extends MusicBeatState
|
class MainMenuState extends MusicBeatState
|
||||||
{
|
{
|
||||||
@@ -40,7 +43,7 @@ class MainMenuState extends MusicBeatState
|
|||||||
camFollow = new FlxObject(0, 0, 1, 1);
|
camFollow = new FlxObject(0, 0, 1, 1);
|
||||||
add(camFollow);
|
add(camFollow);
|
||||||
|
|
||||||
magenta = new FlxSprite(-80).loadGraphic(AssetPaths.menuBGMagenta__png);
|
magenta = new FlxSprite(-80).loadGraphic(AssetPaths.menuDesat__png);
|
||||||
magenta.scrollFactor.x = 0;
|
magenta.scrollFactor.x = 0;
|
||||||
magenta.scrollFactor.y = 0.18;
|
magenta.scrollFactor.y = 0.18;
|
||||||
magenta.setGraphicSize(Std.int(magenta.width * 1.1));
|
magenta.setGraphicSize(Std.int(magenta.width * 1.1));
|
||||||
@@ -48,6 +51,7 @@ class MainMenuState extends MusicBeatState
|
|||||||
magenta.screenCenter();
|
magenta.screenCenter();
|
||||||
magenta.visible = false;
|
magenta.visible = false;
|
||||||
magenta.antialiasing = true;
|
magenta.antialiasing = true;
|
||||||
|
magenta.color = 0xFFfd719b;
|
||||||
add(magenta);
|
add(magenta);
|
||||||
// magenta.scrollFactor.set();
|
// magenta.scrollFactor.set();
|
||||||
|
|
||||||
@@ -72,6 +76,11 @@ class MainMenuState extends MusicBeatState
|
|||||||
|
|
||||||
FlxG.camera.follow(camFollow, null, 0.06);
|
FlxG.camera.follow(camFollow, null, 0.06);
|
||||||
|
|
||||||
|
var versionShit:FlxText = new FlxText(5, FlxG.height - 18, 0, "v" + Application.current.meta.get('version'));
|
||||||
|
versionShit.scrollFactor.set();
|
||||||
|
versionShit.setFormat("VCR OSD Mono", 16, FlxColor.WHITE, LEFT, FlxTextBorderStyle.OUTLINE, FlxColor.BLACK);
|
||||||
|
add(versionShit);
|
||||||
|
|
||||||
changeItem();
|
changeItem();
|
||||||
|
|
||||||
super.create();
|
super.create();
|
||||||
@@ -137,6 +146,8 @@ class MainMenuState extends MusicBeatState
|
|||||||
FlxG.switchState(new StoryMenuState());
|
FlxG.switchState(new StoryMenuState());
|
||||||
case 'freeplay':
|
case 'freeplay':
|
||||||
FlxG.switchState(new FreeplayState());
|
FlxG.switchState(new FreeplayState());
|
||||||
|
case 'options':
|
||||||
|
FlxG.switchState(new OptionsMenu());
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -10,7 +10,7 @@ class MenuItem extends FlxSpriteGroup
|
|||||||
public var targetY:Float = 0;
|
public var targetY:Float = 0;
|
||||||
public var week:FlxSprite;
|
public var week:FlxSprite;
|
||||||
|
|
||||||
public function new(x:Float, y:Float, weekNum:Int = 0, unlocked:Bool = false)
|
public function new(x:Float, y:Float, weekNum:Int = 0)
|
||||||
{
|
{
|
||||||
super(x, y);
|
super(x, y);
|
||||||
|
|
||||||
@@ -18,18 +18,15 @@ class MenuItem extends FlxSpriteGroup
|
|||||||
|
|
||||||
week = new FlxSprite();
|
week = new FlxSprite();
|
||||||
week.frames = tex;
|
week.frames = tex;
|
||||||
week.animation.addByPrefix('week0', "WEEK1 select", 24);
|
// TUTORIAL IS WEEK 0
|
||||||
week.animation.addByPrefix('week1', "week2 select", 24);
|
week.animation.addByPrefix('week0', 'tutorial selected', 24);
|
||||||
|
week.animation.addByPrefix('week1', "WEEK1 select", 24);
|
||||||
|
week.animation.addByPrefix('week2', "week2 select", 24);
|
||||||
add(week);
|
add(week);
|
||||||
|
|
||||||
week.animation.play('week' + weekNum);
|
week.animation.play('week' + weekNum);
|
||||||
week.animation.pause();
|
week.animation.pause();
|
||||||
week.updateHitbox();
|
week.updateHitbox();
|
||||||
|
|
||||||
if (!unlocked)
|
|
||||||
{
|
|
||||||
week.alpha = 0.6;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
override function update(elapsed:Float)
|
override function update(elapsed:Float)
|
||||||
|
|||||||
@@ -1,5 +1,6 @@
|
|||||||
package;
|
package;
|
||||||
|
|
||||||
|
import flixel.FlxG;
|
||||||
import flixel.FlxSubState;
|
import flixel.FlxSubState;
|
||||||
|
|
||||||
class MusicBeatSubstate extends FlxSubState
|
class MusicBeatSubstate extends FlxSubState
|
||||||
|
|||||||
@@ -146,6 +146,15 @@ class NGio
|
|||||||
// NGio.scoreboardArray = NG.core.scoreBoards.get(8004).scores;
|
// NGio.scoreboardArray = NG.core.scoreBoards.get(8004).scores;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
inline static public function logEvent(event:String)
|
||||||
|
{
|
||||||
|
if (isLoggedIn)
|
||||||
|
{
|
||||||
|
NG.core.calls.event.logEvent(event);
|
||||||
|
trace('should have logged: ' + event);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
inline static public function unlockMedal(id:Int)
|
inline static public function unlockMedal(id:Int)
|
||||||
{
|
{
|
||||||
if (isLoggedIn)
|
if (isLoggedIn)
|
||||||
|
|||||||
29
source/OptionsMenu.hx
Normal file
29
source/OptionsMenu.hx
Normal file
@@ -0,0 +1,29 @@
|
|||||||
|
package;
|
||||||
|
|
||||||
|
import flixel.FlxG;
|
||||||
|
import flixel.FlxSprite;
|
||||||
|
import flixel.util.FlxColor;
|
||||||
|
|
||||||
|
class OptionsMenu extends MusicBeatState
|
||||||
|
{
|
||||||
|
override function create()
|
||||||
|
{
|
||||||
|
var menuBG:FlxSprite = new FlxSprite().loadGraphic(AssetPaths.menuDesat__png);
|
||||||
|
menuBG.color = 0xFFea71fd;
|
||||||
|
menuBG.setGraphicSize(Std.int(menuBG.width * 1.1));
|
||||||
|
menuBG.updateHitbox();
|
||||||
|
menuBG.screenCenter();
|
||||||
|
menuBG.antialiasing = true;
|
||||||
|
add(menuBG);
|
||||||
|
|
||||||
|
super.create();
|
||||||
|
}
|
||||||
|
|
||||||
|
override function update(elapsed:Float)
|
||||||
|
{
|
||||||
|
if (controls.BACK)
|
||||||
|
FlxG.switchState(new MainMenuState());
|
||||||
|
|
||||||
|
super.update(elapsed);
|
||||||
|
}
|
||||||
|
}
|
||||||
11
source/OptionsSubState.hx
Normal file
11
source/OptionsSubState.hx
Normal file
@@ -0,0 +1,11 @@
|
|||||||
|
package;
|
||||||
|
|
||||||
|
class OptionsSubState extends MusicBeatSubstate
|
||||||
|
{
|
||||||
|
var textMenuItems:Array<String> = ['Master Volume', 'Sound Volume'];
|
||||||
|
|
||||||
|
public function new()
|
||||||
|
{
|
||||||
|
super();
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -37,6 +37,7 @@ class PlayState extends MusicBeatState
|
|||||||
public static var curLevel:String = 'Tutorial';
|
public static var curLevel:String = 'Tutorial';
|
||||||
public static var SONG:SwagSong;
|
public static var SONG:SwagSong;
|
||||||
public static var isStoryMode:Bool = false;
|
public static var isStoryMode:Bool = false;
|
||||||
|
public static var storyWeek:Int = 0;
|
||||||
public static var storyPlaylist:Array<String> = [];
|
public static var storyPlaylist:Array<String> = [];
|
||||||
public static var storyDifficulty:Int = 1;
|
public static var storyDifficulty:Int = 1;
|
||||||
|
|
||||||
@@ -83,6 +84,8 @@ class PlayState extends MusicBeatState
|
|||||||
var talking:Bool = true;
|
var talking:Bool = true;
|
||||||
var songScore:Int = 0;
|
var songScore:Int = 0;
|
||||||
|
|
||||||
|
public static var campaignScore:Int = 0;
|
||||||
|
|
||||||
override public function create()
|
override public function create()
|
||||||
{
|
{
|
||||||
// var gameCam:FlxCamera = FlxG.camera;
|
// var gameCam:FlxCamera = FlxG.camera;
|
||||||
@@ -460,7 +463,7 @@ class PlayState extends MusicBeatState
|
|||||||
daBeats += 1;
|
daBeats += 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
trace(unspawnNotes.length);
|
// trace(unspawnNotes.length);
|
||||||
// playerCounter += 1;
|
// playerCounter += 1;
|
||||||
|
|
||||||
unspawnNotes.sort(sortByShit);
|
unspawnNotes.sort(sortByShit);
|
||||||
@@ -562,7 +565,7 @@ class PlayState extends MusicBeatState
|
|||||||
{
|
{
|
||||||
if (FlxG.sound.music != null)
|
if (FlxG.sound.music != null)
|
||||||
{
|
{
|
||||||
vocals.time = FlxG.sound.music.time;
|
vocals.time = Conductor.songPosition;
|
||||||
|
|
||||||
FlxG.sound.music.play();
|
FlxG.sound.music.play();
|
||||||
vocals.play();
|
vocals.play();
|
||||||
@@ -602,9 +605,9 @@ class PlayState extends MusicBeatState
|
|||||||
openSubState(new PauseSubState(boyfriend.getScreenPosition().x, boyfriend.getScreenPosition().y));
|
openSubState(new PauseSubState(boyfriend.getScreenPosition().x, boyfriend.getScreenPosition().y));
|
||||||
}
|
}
|
||||||
|
|
||||||
if (FlxG.keys.justPressed.ESCAPE)
|
if (FlxG.keys.justPressed.SEVEN)
|
||||||
{
|
{
|
||||||
// FlxG.switchState(new ChartingState());
|
FlxG.switchState(new ChartingState());
|
||||||
}
|
}
|
||||||
|
|
||||||
// FlxG.watch.addQuick('VOL', vocals.amplitudeLeft);
|
// FlxG.watch.addQuick('VOL', vocals.amplitudeLeft);
|
||||||
@@ -641,8 +644,7 @@ class PlayState extends MusicBeatState
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
//Conductor.songPosition = FlxG.sound.music.time;
|
Conductor.songPosition = FlxG.sound.music.time;
|
||||||
Conductor.songPosition += FlxG.elapsed * 1000;
|
|
||||||
|
|
||||||
if (!paused)
|
if (!paused)
|
||||||
{
|
{
|
||||||
@@ -812,6 +814,7 @@ class PlayState extends MusicBeatState
|
|||||||
}
|
}
|
||||||
|
|
||||||
daNote.y = (strumLine.y - (Conductor.songPosition - daNote.strumTime) * (0.45 * PlayState.SONG.speed));
|
daNote.y = (strumLine.y - (Conductor.songPosition - daNote.strumTime) * (0.45 * PlayState.SONG.speed));
|
||||||
|
|
||||||
// WIP interpolation shit? Need to fix the pause issue
|
// WIP interpolation shit? Need to fix the pause issue
|
||||||
// daNote.y = (strumLine.y - (songTime - daNote.strumTime) * (0.45 * PlayState.SONG.speed));
|
// daNote.y = (strumLine.y - (songTime - daNote.strumTime) * (0.45 * PlayState.SONG.speed));
|
||||||
|
|
||||||
@@ -838,16 +841,12 @@ class PlayState extends MusicBeatState
|
|||||||
|
|
||||||
function endSong():Void
|
function endSong():Void
|
||||||
{
|
{
|
||||||
trace('SONG DONE' + isStoryMode);
|
Highscore.saveScore(SONG.song, songScore, storyDifficulty);
|
||||||
|
|
||||||
|
|
||||||
#if !switch
|
|
||||||
NGio.postScore(songScore, SONG.song);
|
|
||||||
#end
|
|
||||||
|
|
||||||
|
|
||||||
if (isStoryMode)
|
if (isStoryMode)
|
||||||
{
|
{
|
||||||
|
campaignScore += songScore;
|
||||||
|
|
||||||
storyPlaylist.remove(storyPlaylist[0]);
|
storyPlaylist.remove(storyPlaylist[0]);
|
||||||
|
|
||||||
if (storyPlaylist.length <= 0)
|
if (storyPlaylist.length <= 0)
|
||||||
@@ -856,12 +855,12 @@ class PlayState extends MusicBeatState
|
|||||||
|
|
||||||
FlxG.switchState(new StoryMenuState());
|
FlxG.switchState(new StoryMenuState());
|
||||||
|
|
||||||
StoryMenuState.weekUnlocked[1] = true;
|
StoryMenuState.weekUnlocked[2] = true;
|
||||||
|
|
||||||
#if !switch
|
#if !switch
|
||||||
NGio.unlockMedal(60961);
|
NGio.unlockMedal(60961);
|
||||||
#end
|
#end
|
||||||
|
Highscore.saveWeekScore(storyWeek, campaignScore, storyDifficulty);
|
||||||
|
|
||||||
FlxG.save.data.weekUnlocked = StoryMenuState.weekUnlocked;
|
FlxG.save.data.weekUnlocked = StoryMenuState.weekUnlocked;
|
||||||
FlxG.save.flush();
|
FlxG.save.flush();
|
||||||
@@ -1041,7 +1040,6 @@ class PlayState extends MusicBeatState
|
|||||||
if (daNote.canBeHit && daNote.mustPress && !daNote.tooLate)
|
if (daNote.canBeHit && daNote.mustPress && !daNote.tooLate)
|
||||||
{
|
{
|
||||||
possibleNotes.push(daNote);
|
possibleNotes.push(daNote);
|
||||||
trace('NOTE-' + daNote.strumTime + ' ADDED');
|
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
@@ -1234,7 +1232,6 @@ class PlayState extends MusicBeatState
|
|||||||
|
|
||||||
function noteCheck(keyP:Bool, note:Note):Void
|
function noteCheck(keyP:Bool, note:Note):Void
|
||||||
{
|
{
|
||||||
trace(note.noteData + ' note check here ' + keyP);
|
|
||||||
if (keyP)
|
if (keyP)
|
||||||
goodNoteHit(note);
|
goodNoteHit(note);
|
||||||
else
|
else
|
||||||
@@ -1304,9 +1301,9 @@ class PlayState extends MusicBeatState
|
|||||||
if (vocals.time > Conductor.songPosition + Conductor.stepCrochet
|
if (vocals.time > Conductor.songPosition + Conductor.stepCrochet
|
||||||
|| vocals.time < Conductor.songPosition - Conductor.stepCrochet)
|
|| vocals.time < Conductor.songPosition - Conductor.stepCrochet)
|
||||||
{
|
{
|
||||||
//vocals.pause();
|
vocals.pause();
|
||||||
vocals.time = Conductor.songPosition;
|
vocals.time = Conductor.songPosition;
|
||||||
//vocals.play();
|
vocals.play();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -5,6 +5,7 @@ import flixel.FlxSprite;
|
|||||||
import flixel.graphics.frames.FlxAtlasFrames;
|
import flixel.graphics.frames.FlxAtlasFrames;
|
||||||
import flixel.group.FlxGroup.FlxTypedGroup;
|
import flixel.group.FlxGroup.FlxTypedGroup;
|
||||||
import flixel.group.FlxGroup;
|
import flixel.group.FlxGroup;
|
||||||
|
import flixel.math.FlxMath;
|
||||||
import flixel.text.FlxText;
|
import flixel.text.FlxText;
|
||||||
import flixel.tweens.FlxTween;
|
import flixel.tweens.FlxTween;
|
||||||
import flixel.util.FlxTimer;
|
import flixel.util.FlxTimer;
|
||||||
@@ -16,12 +17,12 @@ class StoryMenuState extends MusicBeatState
|
|||||||
{
|
{
|
||||||
var scoreText:FlxText;
|
var scoreText:FlxText;
|
||||||
|
|
||||||
var weekData:Array<Dynamic> = [['Tutorial', 'Bopeebo', 'Fresh', 'Dadbattle'], ['Spookeez', 'South']];
|
var weekData:Array<Dynamic> = [['Tutorial'], ['Bopeebo', 'Fresh', 'Dadbattle'], ['Spookeez', 'South']];
|
||||||
var curDifficulty:Int = 1;
|
var curDifficulty:Int = 1;
|
||||||
|
|
||||||
public static var weekUnlocked:Array<Bool> = [true, false];
|
public static var weekUnlocked:Array<Bool> = [true, true, false];
|
||||||
|
|
||||||
var weekCharacters:Array<Dynamic> = [['dad', 'bf', 'gf'], ['spooky', 'bf', 'gf']];
|
var weekCharacters:Array<Dynamic> = [['dad', 'bf', 'gf'], ['dad', 'bf', 'gf'], ['spooky', 'bf', 'gf']];
|
||||||
var curWeek:Int = 0;
|
var curWeek:Int = 0;
|
||||||
|
|
||||||
var txtTracklist:FlxText;
|
var txtTracklist:FlxText;
|
||||||
@@ -37,9 +38,12 @@ class StoryMenuState extends MusicBeatState
|
|||||||
var rightArrow:FlxSprite;
|
var rightArrow:FlxSprite;
|
||||||
|
|
||||||
override function create()
|
override function create()
|
||||||
|
{
|
||||||
|
if (FlxG.sound.music != null)
|
||||||
{
|
{
|
||||||
if (!FlxG.sound.music.playing)
|
if (!FlxG.sound.music.playing)
|
||||||
FlxG.sound.playMusic('assets/music/freakyMenu' + TitleState.soundExt);
|
FlxG.sound.playMusic('assets/music/freakyMenu' + TitleState.soundExt);
|
||||||
|
}
|
||||||
|
|
||||||
persistentUpdate = persistentDraw = true;
|
persistentUpdate = persistentDraw = true;
|
||||||
|
|
||||||
@@ -65,12 +69,7 @@ class StoryMenuState extends MusicBeatState
|
|||||||
|
|
||||||
for (i in 0...weekData.length)
|
for (i in 0...weekData.length)
|
||||||
{
|
{
|
||||||
var unlocked:Bool = true;
|
var weekThing:MenuItem = new MenuItem(0, yellowBG.y + yellowBG.height + 10, i);
|
||||||
|
|
||||||
if (i == 1)
|
|
||||||
unlocked = false;
|
|
||||||
|
|
||||||
var weekThing:MenuItem = new MenuItem(0, yellowBG.y + yellowBG.height + 10, i, unlocked);
|
|
||||||
weekThing.y += ((weekThing.height + 20) * i);
|
weekThing.y += ((weekThing.height + 20) * i);
|
||||||
weekThing.targetY = i;
|
weekThing.targetY = i;
|
||||||
grpWeekText.add(weekThing);
|
grpWeekText.add(weekThing);
|
||||||
@@ -79,6 +78,7 @@ class StoryMenuState extends MusicBeatState
|
|||||||
weekThing.antialiasing = true;
|
weekThing.antialiasing = true;
|
||||||
// weekThing.updateHitbox();
|
// weekThing.updateHitbox();
|
||||||
|
|
||||||
|
// Needs an offset thingie
|
||||||
if (!weekUnlocked[i])
|
if (!weekUnlocked[i])
|
||||||
{
|
{
|
||||||
var lock:FlxSprite = new FlxSprite(weekThing.width + 10 + weekThing.x);
|
var lock:FlxSprite = new FlxSprite(weekThing.width + 10 + weekThing.x);
|
||||||
@@ -117,7 +117,7 @@ class StoryMenuState extends MusicBeatState
|
|||||||
difficultySelectors = new FlxGroup();
|
difficultySelectors = new FlxGroup();
|
||||||
add(difficultySelectors);
|
add(difficultySelectors);
|
||||||
|
|
||||||
leftArrow = new FlxSprite(grpWeekText.members[0].x + 370, grpWeekText.members[0].y + 10);
|
leftArrow = new FlxSprite(grpWeekText.members[0].x + grpWeekText.members[0].width + 10, grpWeekText.members[0].y + 10);
|
||||||
leftArrow.frames = ui_tex;
|
leftArrow.frames = ui_tex;
|
||||||
leftArrow.animation.addByPrefix('idle', "arrow left");
|
leftArrow.animation.addByPrefix('idle', "arrow left");
|
||||||
leftArrow.animation.addByPrefix('press', "arrow push left");
|
leftArrow.animation.addByPrefix('press', "arrow push left");
|
||||||
@@ -150,7 +150,7 @@ class StoryMenuState extends MusicBeatState
|
|||||||
txtTracklist.color = 0xFFe55777;
|
txtTracklist.color = 0xFFe55777;
|
||||||
add(txtTracklist);
|
add(txtTracklist);
|
||||||
// add(rankText);
|
// add(rankText);
|
||||||
// add(scoreText);
|
add(scoreText);
|
||||||
|
|
||||||
updateText();
|
updateText();
|
||||||
|
|
||||||
@@ -160,7 +160,9 @@ class StoryMenuState extends MusicBeatState
|
|||||||
override function update(elapsed:Float)
|
override function update(elapsed:Float)
|
||||||
{
|
{
|
||||||
// scoreText.setFormat('VCR OSD Mono', 32);
|
// scoreText.setFormat('VCR OSD Mono', 32);
|
||||||
// scoreText.text = "Score SHIT";
|
lerpScore = Math.floor(FlxMath.lerp(lerpScore, intendedScore, 0.5));
|
||||||
|
|
||||||
|
scoreText.text = "WEEK SCORE:" + lerpScore;
|
||||||
// FlxG.watch.addQuick('font', scoreText.font);
|
// FlxG.watch.addQuick('font', scoreText.font);
|
||||||
|
|
||||||
difficultySelectors.visible = weekUnlocked[curWeek];
|
difficultySelectors.visible = weekUnlocked[curWeek];
|
||||||
@@ -245,6 +247,8 @@ class StoryMenuState extends MusicBeatState
|
|||||||
PlayState.storyDifficulty = curDifficulty;
|
PlayState.storyDifficulty = curDifficulty;
|
||||||
|
|
||||||
PlayState.SONG = Song.loadFromJson(PlayState.storyPlaylist[0].toLowerCase() + diffic, PlayState.storyPlaylist[0].toLowerCase());
|
PlayState.SONG = Song.loadFromJson(PlayState.storyPlaylist[0].toLowerCase() + diffic, PlayState.storyPlaylist[0].toLowerCase());
|
||||||
|
PlayState.storyWeek = curWeek;
|
||||||
|
PlayState.campaignScore = 0;
|
||||||
new FlxTimer().start(1, function(tmr:FlxTimer)
|
new FlxTimer().start(1, function(tmr:FlxTimer)
|
||||||
{
|
{
|
||||||
if (FlxG.sound.music != null)
|
if (FlxG.sound.music != null)
|
||||||
@@ -282,10 +286,14 @@ class StoryMenuState extends MusicBeatState
|
|||||||
|
|
||||||
// USING THESE WEIRD VALUES SO THAT IT DOESNT FLOAT UP
|
// USING THESE WEIRD VALUES SO THAT IT DOESNT FLOAT UP
|
||||||
sprDifficulty.y = leftArrow.y - 15;
|
sprDifficulty.y = leftArrow.y - 15;
|
||||||
|
intendedScore = Highscore.getWeekScore(curWeek, curDifficulty);
|
||||||
|
|
||||||
FlxTween.tween(sprDifficulty, {y: leftArrow.y + 15, alpha: 1}, 0.07);
|
FlxTween.tween(sprDifficulty, {y: leftArrow.y + 15, alpha: 1}, 0.07);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
var lerpScore:Int = 0;
|
||||||
|
var intendedScore:Int = 0;
|
||||||
|
|
||||||
function changeWeek(change:Int = 0):Void
|
function changeWeek(change:Int = 0):Void
|
||||||
{
|
{
|
||||||
curWeek += change;
|
curWeek += change;
|
||||||
@@ -300,6 +308,10 @@ class StoryMenuState extends MusicBeatState
|
|||||||
for (item in grpWeekText.members)
|
for (item in grpWeekText.members)
|
||||||
{
|
{
|
||||||
item.targetY = bullShit - curWeek;
|
item.targetY = bullShit - curWeek;
|
||||||
|
if (item.targetY == Std.int(0) && weekUnlocked[curWeek])
|
||||||
|
item.alpha = 1;
|
||||||
|
else
|
||||||
|
item.alpha = 0.6;
|
||||||
bullShit++;
|
bullShit++;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -326,5 +338,7 @@ class StoryMenuState extends MusicBeatState
|
|||||||
|
|
||||||
txtTracklist.screenCenter(X);
|
txtTracklist.screenCenter(X);
|
||||||
txtTracklist.x -= FlxG.width * 0.35;
|
txtTracklist.x -= FlxG.width * 0.35;
|
||||||
|
|
||||||
|
intendedScore = Highscore.getWeekScore(curWeek, curDifficulty);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -36,13 +36,13 @@ class TitleState extends MusicBeatState
|
|||||||
['Ritz dx', 'rest in peace'], ['rate five', 'pls no blam'], ['rhythm gaming', 'ultimate'], ['game of the year', 'forever'],
|
['Ritz dx', 'rest in peace'], ['rate five', 'pls no blam'], ['rhythm gaming', 'ultimate'], ['game of the year', 'forever'],
|
||||||
['you already know', 'we really out here'], ['rise and grind', 'love to luis'], ['like parappa', 'but cooler'],
|
['you already know', 'we really out here'], ['rise and grind', 'love to luis'], ['like parappa', 'but cooler'],
|
||||||
['album of the year', 'chuckie finster'], ["free gitaroo man", "with love to wandaboy"], ['better than geometry dash', 'fight me robtop'],
|
['album of the year', 'chuckie finster'], ["free gitaroo man", "with love to wandaboy"], ['better than geometry dash', 'fight me robtop'],
|
||||||
['kiddbrute for president', 'vote now']];
|
['kiddbrute for president', 'vote now'], ['play dead estate', 'on newgrounds'], ['this is a god damn prototype', 'we workin on it okay'],
|
||||||
|
['WOMEN ARE real', 'this is official']];
|
||||||
|
|
||||||
var curWacky:Array<String> = [];
|
var curWacky:Array<String> = [];
|
||||||
|
|
||||||
var wackyImage:FlxSprite;
|
var wackyImage:FlxSprite;
|
||||||
|
|
||||||
|
|
||||||
override public function create():Void
|
override public function create():Void
|
||||||
{
|
{
|
||||||
#if (!web)
|
#if (!web)
|
||||||
@@ -57,11 +57,22 @@ class TitleState extends MusicBeatState
|
|||||||
|
|
||||||
super.create();
|
super.create();
|
||||||
|
|
||||||
|
|
||||||
#if (!switch && !debug && NG_LOGIN)
|
#if (!switch && !debug && NG_LOGIN)
|
||||||
var ng:NGio = new NGio(APIStuff.API, APIStuff.EncKey);
|
var ng:NGio = new NGio(APIStuff.API, APIStuff.EncKey);
|
||||||
#end
|
#end
|
||||||
|
|
||||||
|
FlxG.save.bind('funkin', 'ninjamuffin99');
|
||||||
|
|
||||||
|
Highscore.load();
|
||||||
|
|
||||||
|
if (FlxG.save.data.weekUnlocked != null)
|
||||||
|
{
|
||||||
|
StoryMenuState.weekUnlocked = FlxG.save.data.weekUnlocked;
|
||||||
|
|
||||||
|
if (StoryMenuState.weekUnlocked.length < 3)
|
||||||
|
StoryMenuState.weekUnlocked.insert(0, true);
|
||||||
|
}
|
||||||
|
|
||||||
#if SKIP_TO_PLAYSTATE
|
#if SKIP_TO_PLAYSTATE
|
||||||
FlxG.switchState(new StoryMenuState());
|
FlxG.switchState(new StoryMenuState());
|
||||||
#else
|
#else
|
||||||
@@ -76,10 +87,6 @@ class TitleState extends MusicBeatState
|
|||||||
|
|
||||||
function startIntro()
|
function startIntro()
|
||||||
{
|
{
|
||||||
#if switch
|
|
||||||
initialized = true;
|
|
||||||
#end
|
|
||||||
|
|
||||||
if (!initialized)
|
if (!initialized)
|
||||||
{
|
{
|
||||||
var diamond:FlxGraphic = FlxGraphic.fromClass(GraphicTransTileDiamond);
|
var diamond:FlxGraphic = FlxGraphic.fromClass(GraphicTransTileDiamond);
|
||||||
@@ -100,13 +107,6 @@ class TitleState extends MusicBeatState
|
|||||||
FlxG.sound.playMusic('assets/music/freakyMenu' + TitleState.soundExt, 0);
|
FlxG.sound.playMusic('assets/music/freakyMenu' + TitleState.soundExt, 0);
|
||||||
|
|
||||||
FlxG.sound.music.fadeIn(4, 0, 0.7);
|
FlxG.sound.music.fadeIn(4, 0, 0.7);
|
||||||
|
|
||||||
FlxG.save.bind('funkin', 'ninjamuffin99');
|
|
||||||
|
|
||||||
if (FlxG.save.data.weekUnlocked != null)
|
|
||||||
{
|
|
||||||
StoryMenuState.weekUnlocked = FlxG.save.data.weekUnlocked;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
Conductor.changeBPM(102);
|
Conductor.changeBPM(102);
|
||||||
@@ -192,6 +192,12 @@ class TitleState extends MusicBeatState
|
|||||||
override function update(elapsed:Float)
|
override function update(elapsed:Float)
|
||||||
{
|
{
|
||||||
Conductor.songPosition = FlxG.sound.music.time;
|
Conductor.songPosition = FlxG.sound.music.time;
|
||||||
|
// FlxG.watch.addQuick('amp', FlxG.sound.music.amplitude);
|
||||||
|
|
||||||
|
if (FlxG.keys.justPressed.F)
|
||||||
|
{
|
||||||
|
FlxG.fullscreen = !FlxG.fullscreen;
|
||||||
|
}
|
||||||
|
|
||||||
var pressedEnter:Bool = FlxG.keys.justPressed.ENTER;
|
var pressedEnter:Bool = FlxG.keys.justPressed.ENTER;
|
||||||
|
|
||||||
@@ -212,6 +218,10 @@ class TitleState extends MusicBeatState
|
|||||||
{
|
{
|
||||||
#if !switch
|
#if !switch
|
||||||
NGio.unlockMedal(60960);
|
NGio.unlockMedal(60960);
|
||||||
|
|
||||||
|
// If it's Friday according to da clock
|
||||||
|
if (Date.now().getDay() == 5)
|
||||||
|
NGio.unlockMedal(61034);
|
||||||
#end
|
#end
|
||||||
|
|
||||||
titleText.animation.play('press');
|
titleText.animation.play('press');
|
||||||
|
|||||||
Reference in New Issue
Block a user