This commit is contained in:
KadeDeveloper 2021-07-19 22:14:19 -07:00
commit a763f20ba1
3 changed files with 28 additions and 4 deletions

View File

@ -324,6 +324,26 @@ class AntialiasingOption extends Option
}
}
class MissSoundsOption extends Option
{
public function new(desc:String)
{
super();
description = desc;
}
public override function press():Bool
{
FlxG.save.data.missSounds = !FlxG.save.data.missSounds;
display = updateDisplay();
return true;
}
private override function updateDisplay():String
{
return "Miss Sounds " + (!FlxG.save.data.missSounds ? "off" : "on");
}
}
class ShowInput extends Option
{
public function new(desc:String)

View File

@ -55,8 +55,9 @@ class OptionsMenu extends MusicBeatState
new FlashingLightsOption("Toggle flashing lights that can cause epileptic seizures and strain."),
new WatermarkOption("Enable and disable all watermarks from the engine."),
new AntialiasingOption("Toggle antialiasing, improving graphics quality at a slight performance penalty."),
new MissSoundsOption("Toggle miss sounds playing when you don't hit a note."),
new ScoreScreen("Show the score screen after the end of a song"),
new ShowInput("Display every single input in the score screen."),
new ShowInput("Display every single input on the score screen."),
new Optimization("No characters or backgrounds. Just a rhythm game, with none of the extra bells and whistles."),
new GraphicLoading("On startup, cache every character. Significantly decrease load times. (HIGH MEMORY)"),
new BotPlay("Showcase your charts and mods with autoplay.")

View File

@ -4035,9 +4035,12 @@ class PlayState extends MusicBeatState
else
songScore -= 10;
FlxG.sound.play(Paths.soundRandom('missnote', 1, 3), FlxG.random.float(0.1, 0.2));
// FlxG.sound.play(Paths.sound('missnote1'), 1, false);
// FlxG.log.add('played imss note');
if(FlxG.save.data.missSounds)
{
FlxG.sound.play(Paths.soundRandom('missnote', 1, 3), FlxG.random.float(0.1, 0.2));
// FlxG.sound.play(Paths.sound('missnote1'), 1, false);
// FlxG.log.add('played imss note');
}
// Hole switch statement replaced with a single line :)
boyfriend.playAnim('sing' + dataSuffix[direction] + 'miss', true);