diff --git a/source/backend/ClientPrefs.hx b/source/backend/ClientPrefs.hx index 3bffed3d..69fe497e 100644 --- a/source/backend/ClientPrefs.hx +++ b/source/backend/ClientPrefs.hx @@ -111,6 +111,7 @@ import states.TitleState; 'healthgain' => 1.0, 'healthloss' => 1.0, 'instakill' => false, + 'instacrash' => false, 'practice' => false, 'botplay' => false, 'opponentplay' => false diff --git a/source/options/GameplayChangersSubstate.hx b/source/options/GameplayChangersSubstate.hx index 6b5eec58..6139dd2e 100644 --- a/source/options/GameplayChangersSubstate.hx +++ b/source/options/GameplayChangersSubstate.hx @@ -78,7 +78,8 @@ class GameplayChangersSubstate extends MusicBeatSubstate option.displayFormat = '%vX'; optionsArray.push(option); - optionsArray.push(new GameplayOption('Instakill on Miss', 'instakill', BOOL, false)); + optionsArray.push(new GameplayOption('Instant kill on Miss', 'instakill', BOOL, false)); + optionsArray.push(new GameplayOption('Instant crash on Miss', 'instacrash', BOOL, false)); optionsArray.push(new GameplayOption('Practice Mode', 'practice', BOOL, false)); optionsArray.push(new GameplayOption('Botplay', 'botplay', BOOL, false)); } diff --git a/source/options/GameplaySettingsSubState.hx b/source/options/GameplaySettingsSubState.hx index 95b28d2e..03ba74db 100644 --- a/source/options/GameplaySettingsSubState.hx +++ b/source/options/GameplaySettingsSubState.hx @@ -248,7 +248,7 @@ class GameplaySettingsSubState extends BaseOptionsMenu function onStepUpdateRate(){ stepRate.scrollSpeed = interpolate(20.0, 1000.0, (holdTime - 0.5) / 3.0, 3.0); descText.text = stepRate.description = - 'In this settings, Accurate up to ${ + 'In this settings, you can set the stepHit to be accurate up to ${ stepRate.getValue() != 0 ? Std.string(stepRate.getValue() * defaultBPM * ClientPrefs.data.framerate) : "Infinite" } BPM.'; diff --git a/source/states/PlayState.hx b/source/states/PlayState.hx index 096a79e8..d0e8e3e9 100644 --- a/source/states/PlayState.hx +++ b/source/states/PlayState.hx @@ -239,6 +239,7 @@ class PlayState extends MusicBeatState public final guitarHeroSustains:Bool = false; public var instakillOnMiss:Bool = false; + public var instacrashOnMiss:Bool = false; public var cpuControlled:Bool = false; public var practiceMode:Bool = false; public var pressMissDamage:Float = 0.05; @@ -427,6 +428,7 @@ class PlayState extends MusicBeatState healthGain = ClientPrefs.getGameplaySetting('healthgain'); healthLoss = ClientPrefs.getGameplaySetting('healthloss'); instakillOnMiss = ClientPrefs.getGameplaySetting('instakill'); + instacrashOnMiss = ClientPrefs.getGameplaySetting('instacrash'); practiceMode = ClientPrefs.getGameplaySetting('practice'); cpuControlled = ClientPrefs.getGameplaySetting('botplay') || ffmpegMode; @@ -1466,7 +1468,7 @@ class PlayState extends MusicBeatState hpShowStr = numFormat(targetHealth, 4 - Std.string(Math.floor(targetHealth)).length, true) + (targetHealth >= 0.001 ? ' %' : ''); if (!cpuControlled) { - if (!instakillOnMiss) { + if (!instakillOnMiss && !instacrashOnMiss) { if (!practiceMode) { tempScoreStr = Language.getPhrase( 'score_text', @@ -4529,49 +4531,6 @@ Average NPS in loading: ${numFormat(notes / takenNoteTime, 3)}'); if (note != null) subtract = note.missHealth; - // GUITAR HERO SUSTAIN CHECK LOL!!!! - // if (guitarHeroSustains && note != null) { - // if (note.parent == null) { - // if (note.tail.length > 0) - // { - // note.alpha = 0.35; - // for (childNote in note.tail) - // { - // childNote.alpha = note.alpha; - // childNote.missed = true; - // childNote.canBeHit = false; - // childNote.ignoreNote = true; - // childNote.tooLate = true; - // } - // note.missed = true; - // note.canBeHit = false; - - // // subtract += 0.385; // you take more damage if playing with this gameplay changer enabled. - // // i mean its fair :p -Crow - // subtract *= note.tail.length + 1; - // // i think it would be fair if damage multiplied based on how long the sustain is -Tahir - // } - - // if (note.missed) return; - // } else if (note.isSustainNote) { - // if (note.missed) return; - - // var parentNote:Note = note.parent; - // if (parentNote.wasGoodHit && parentNote.tail.length > 0) - // { - // for (child in parentNote.tail) { - // if (child != note) { - // child.missed = true; - // child.canBeHit = false; - // child.ignoreNote = true; - // child.tooLate = true; - // } - // } - // } - // parentNote = null; - // } - // } - if (instakillOnMiss) { if (bfVocal) vocals.volume = 0; @@ -4579,6 +4538,10 @@ Average NPS in loading: ${numFormat(notes / takenNoteTime, 3)}'); doDeathCheck(true); } + if (instacrashOnMiss) { + throw "You missed the NOTE! HAHAHA"; + } + var lastCombo:Float = combo; combo = 0;