mirror of
https://github.com/ninjamuffin99/Funkin.git
synced 2025-02-06 03:28:08 +00:00
difficulty selecting
This commit is contained in:
parent
6ad175b0dd
commit
0966adf06a
|
@ -5,8 +5,6 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
|
||||||
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
|
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
|
||||||
|
|
||||||
## [Unreleased]
|
## [Unreleased]
|
||||||
### Added
|
|
||||||
|
|
||||||
|
|
||||||
## [0.2.1] - 2020-11-06
|
## [0.2.1] - 2020-11-06
|
||||||
### Added
|
### Added
|
||||||
|
@ -14,10 +12,10 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
||||||
- A few new intro boot messages.
|
- A few new intro boot messages.
|
||||||
- Lightning effect in Spooky stages
|
- Lightning effect in Spooky stages
|
||||||
- Campaign scores, can now compete on scoreboards for campaign!
|
- Campaign scores, can now compete on scoreboards for campaign!
|
||||||
- Can now change difficulties in
|
- Can now change difficulties in Freeplay mode
|
||||||
|
|
||||||
### Changed
|
### Changed
|
||||||
- Balanced out Normal mode for all songs. Should be much easier all around.
|
- Balanced out Normal mode for the harder songs. 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.
|
- 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
|
### Fixed
|
||||||
|
|
|
@ -20,6 +20,7 @@ class FreeplayState extends MusicBeatState
|
||||||
var curDifficulty:Int = 1;
|
var curDifficulty:Int = 1;
|
||||||
|
|
||||||
var scoreText:FlxText;
|
var scoreText:FlxText;
|
||||||
|
var diffText:FlxText;
|
||||||
var lerpScore:Int = 0;
|
var lerpScore:Int = 0;
|
||||||
var intendedScore:Int = 0;
|
var intendedScore:Int = 0;
|
||||||
|
|
||||||
|
@ -71,10 +72,14 @@ class FreeplayState extends MusicBeatState
|
||||||
scoreText.setFormat("assets/fonts/vcr.ttf", 32, FlxColor.WHITE, RIGHT);
|
scoreText.setFormat("assets/fonts/vcr.ttf", 32, FlxColor.WHITE, RIGHT);
|
||||||
// scoreText.alignment = RIGHT;
|
// scoreText.alignment = RIGHT;
|
||||||
|
|
||||||
var scoreBG:FlxSprite = new FlxSprite(scoreText.x - 6, 0).makeGraphic(Std.int(FlxG.width * 0.35), 40, 0xFF000000);
|
var scoreBG:FlxSprite = new FlxSprite(scoreText.x - 6, 0).makeGraphic(Std.int(FlxG.width * 0.35), 66, 0xFF000000);
|
||||||
scoreBG.alpha = 0.6;
|
scoreBG.alpha = 0.6;
|
||||||
add(scoreBG);
|
add(scoreBG);
|
||||||
|
|
||||||
|
diffText = new FlxText(scoreText.x, scoreText.y + 36, 0, "", 24);
|
||||||
|
diffText.font = scoreText.font;
|
||||||
|
add(diffText);
|
||||||
|
|
||||||
add(scoreText);
|
add(scoreText);
|
||||||
|
|
||||||
changeSelection();
|
changeSelection();
|
||||||
|
@ -130,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());
|
||||||
|
@ -137,7 +147,9 @@ 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);
|
||||||
|
|
||||||
|
PlayState.SONG = Song.loadFromJson(poop, songs[curSelected].toLowerCase());
|
||||||
PlayState.isStoryMode = false;
|
PlayState.isStoryMode = false;
|
||||||
FlxG.switchState(new PlayState());
|
FlxG.switchState(new PlayState());
|
||||||
if (FlxG.sound.music != null)
|
if (FlxG.sound.music != null)
|
||||||
|
@ -153,6 +165,18 @@ class FreeplayState extends MusicBeatState
|
||||||
curDifficulty = 2;
|
curDifficulty = 2;
|
||||||
if (curDifficulty > 2)
|
if (curDifficulty > 2)
|
||||||
curDifficulty = 0;
|
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)
|
||||||
|
@ -168,7 +192,7 @@ class FreeplayState extends MusicBeatState
|
||||||
|
|
||||||
// selector.y = (70 * curSelected) + 30;
|
// selector.y = (70 * curSelected) + 30;
|
||||||
|
|
||||||
intendedScore = Highscore.getScore(songs[curSelected], 1);
|
intendedScore = Highscore.getScore(songs[curSelected], curDifficulty);
|
||||||
// lerpScore = 0;
|
// lerpScore = 0;
|
||||||
|
|
||||||
var bullShit:Int = 0;
|
var bullShit:Int = 0;
|
||||||
|
|
Loading…
Reference in a new issue