A few changes

Show MS has been moved to the Optimization menu
Show Ratings & Combo has been split into 2 options
Removed the health tween when a song starts, it's cool but people don't need that
Fixed notes stretching in EditorPlayState, and strums not being colored properly
This commit is contained in:
JordanSantiagoYT
2024-08-29 15:27:31 -04:00
parent 5e95e6ffbc
commit e784702cff
5 changed files with 189 additions and 174 deletions

View File

@@ -80,7 +80,6 @@ class ClientPrefs { //default settings if it can't find a save file containing y
public static var longFCName:Bool = false;
public static var healthDisplay:Bool = false;
public static var opponentRateCount:Bool = true;
public static var showMS:Bool = false;
public static var flashing:Bool = true;
public static var camZooms:Bool = true;
public static var ratingCounter:Bool = false;
@@ -118,7 +117,9 @@ class ClientPrefs { //default settings if it can't find a save file containing y
public static var opponentLightStrum:Bool = true;
public static var botLightStrum:Bool = true;
public static var playerLightStrum:Bool = true;
public static var ratesAndCombo:Bool = false;
public static var ratingPopups:Bool = true;
public static var comboPopups:Bool = true;
public static var showMS:Bool = false;
public static var songLoading:Bool = true;
public static var noSpawnFunc:Bool = false;
public static var noHitFuncs:Bool = false;

View File

@@ -359,9 +359,6 @@ class PlayState extends MusicBeatState
public var singDurMult:Int = 1;
public static var disableCoolHealthTween:Bool = false;
public var iconsShouldGoUp:Bool = false;
//ms timing popup shit
public var msTxt:FlxText;
public var msTimer:FlxTimer = null;
@@ -1332,14 +1329,14 @@ class PlayState extends MusicBeatState
healthBarBG = new AttachedSprite('healthBar');
}
}
healthBarBG.y = (disableCoolHealthTween ? FlxG.height * 0.89 : FlxG.height * 1.13);
healthBarBG.y = FlxG.height * 0.89;
healthBarBG.screenCenter(X);
healthBarBG.scrollFactor.set();
healthBarBG.visible = !ClientPrefs.hideHud || !ClientPrefs.showcaseMode;
healthBarBG.xAdd = -4;
healthBarBG.yAdd = -4;
add(healthBarBG);
if(ClientPrefs.downScroll) healthBarBG.y = (disableCoolHealthTween ? 0.11 * FlxG.height : -0.13 * FlxG.height);
if(ClientPrefs.downScroll) healthBarBG.y = 0.11 * FlxG.height;
healthBar = new FlxBar(healthBarBG.x + 4, healthBarBG.y + 4, RIGHT_TO_LEFT, Std.int(healthBarBG.width - 8), Std.int(healthBarBG.height - 8), this,
'displayedHealth', 0, maxHealth);
@@ -2823,30 +2820,6 @@ class PlayState extends MusicBeatState
FlxTween.tween(timeTxt, {alpha: 1}, 0.5, {ease: FlxEase.circOut});
}
if (!disableCoolHealthTween && !ClientPrefs.hideHud && !ClientPrefs.showcaseMode)
{
iconsShouldGoUp = true;
var renderedTxtY = -70;
if (ClientPrefs.downScroll) renderedTxtY = 70;
if (ClientPrefs.botTxtStyle == 'VS Impostor') renderedTxtY = (ClientPrefs.downScroll ? 70 : -100);
var scoreTxtY = 50;
switch (ClientPrefs.scoreStyle)
{
case 'Dave and Bambi', 'Forever Engine': scoreTxtY = 40;
case 'Psych Engine', 'VS Impostor': scoreTxtY = 36;
case 'Tails Gets Trolled V4', 'Doki Doki+': scoreTxtY = 48;
}
var healthBarElements:Array<Dynamic> = [healthBarBG, healthBar, scoreTxt, iconP1, iconP2, renderedTxt, botplayTxt];
var yTweens:Array<Dynamic> = [0, 4, scoreTxtY, -75, -75, renderedTxtY];
if (ClientPrefs.botTxtStyle == 'VS Impostor')
{
if (ClientPrefs.downScroll) healthBarElements = [healthBarBG, healthBar, scoreTxt, iconP1, iconP2, renderedTxt];
yTweens = [0, 4, scoreTxtY, -75, -75, renderedTxtY, -55];
}
for (i in 0...healthBarElements.length)
if (healthBarElements[i] != null && i < yTweens.length) FlxTween.tween(healthBarElements[i], {y: (FlxG.height * (ClientPrefs.downScroll ? 0.11 : 0.89)) + yTweens[i]}, 1, {ease: FlxEase.expoOut, onComplete: function(tween:FlxTween) {iconsShouldGoUp = false;}});
}
if (ClientPrefs.ratingCounter && judgeCountUpdateFrame <= 4 && judgementCounter != null) updateRatingCounter();
if (!ClientPrefs.hideScore && scoreTxtUpdateFrame <= 4 && scoreTxt != null) updateScore();
if (ClientPrefs.compactNumbers && compactUpdateFrame <= 4) updateCompactNumbers();
@@ -3616,8 +3589,6 @@ class PlayState extends MusicBeatState
if (ClientPrefs.showRendered) renderedTxt.text = 'Rendered Notes: ${FlxStringUtil.formatMoney(amountOfRenderedNotes, false)}/${FlxStringUtil.formatMoney(maxRenderedNotes, false)}/${FlxStringUtil.formatMoney(notes.members.length + sustainNotes.members.length, false)}';
if (iconsShouldGoUp) iconP1.y = iconP2.y = healthBarBG.y - 75;
callOnLuas('onUpdate', [elapsed]);
if (tankmanAscend && curStep > 895 && curStep < 1151)
@@ -5020,7 +4991,7 @@ class PlayState extends MusicBeatState
return 0.05;
}
function calculateResetTime(?sustainNote:Bool = false):Float {
function calculateResetTime():Float {
if (ClientPrefs.strumLitStyle == 'BPM Based') return (Conductor.stepCrochet * 1.5 / 1000) / playbackRate;
return 0.15 / playbackRate;
}
@@ -5080,7 +5051,6 @@ class PlayState extends MusicBeatState
if (storyPlaylist.length <= 0)
{
disableCoolHealthTween = false;
WeekData.loadTheFirstEnabledMod();
FlxG.sound.playMusic(Paths.music('freakyMenu-' + ClientPrefs.daMenuMusic));
#if DISCORD_ALLOWED DiscordClient.resetClientID(); #end
@@ -5128,13 +5098,11 @@ class PlayState extends MusicBeatState
PlayState.SONG = Song.loadFromJson(PlayState.storyPlaylist[0] + difficulty, PlayState.storyPlaylist[0]);
}
FlxG.sound.music.stop();
disableCoolHealthTween = true;
LoadingState.loadAndSwitchState(new PlayState());
}
}
else
{
disableCoolHealthTween = false;
trace('WENT BACK TO FREEPLAY??');
WeekData.loadTheFirstEnabledMod();
#if DISCORD_ALLOWED DiscordClient.resetClientID(); #end
@@ -5171,7 +5139,6 @@ class PlayState extends MusicBeatState
{
FlxTransitionableState.skipNextTransOut = true;
FlxG.resetState();
disableCoolHealthTween = true;
}
else
{
@@ -5284,7 +5251,7 @@ class PlayState extends MusicBeatState
}
}
if (ClientPrefs.ratesAndCombo && ClientPrefs.ratingType != 'Simple' && popUpsFrame <= 3) {
if (ClientPrefs.ratingPopups && ClientPrefs.ratingType != 'Simple' && popUpsFrame <= 3) {
if (PlayState.isPixelStage)
{
pixelShitPart1 = 'pixelUI/';
@@ -5342,6 +5309,27 @@ class PlayState extends MusicBeatState
rating.updateHitbox();
FlxTween.tween(rating, {alpha: 0}, 0.2 / playbackRate, {
startDelay: Conductor.crochet * 0.001 / playbackRate,
onComplete: function(tween:FlxTween)
{
rating.destroy();
}
});
if (!ClientPrefs.comboStacking)
{
if (lastRating != null)
{
FlxTween.cancelTweensOf(lastRating);
remove(lastRating, true);
lastRating.destroy();
}
lastRating = rating;
}
}
if (ClientPrefs.comboPopups && ClientPrefs.ratingType != 'Simple' && popUpsFrame <= 3)
{
final separatedScore:Array<Dynamic> = [];
if (combo < 0) {
separatedScore.push("neg");
@@ -5357,13 +5345,6 @@ class PlayState extends MusicBeatState
if (!ClientPrefs.comboStacking)
{
if (lastRating != null)
{
FlxTween.cancelTweensOf(lastRating);
remove(lastRating, true);
lastRating.destroy();
}
lastRating = rating;
if (lastScore != null) {
for (sprite in lastScore) {
FlxTween.cancelTweensOf(sprite);
@@ -5384,7 +5365,18 @@ class PlayState extends MusicBeatState
numScore.x += ClientPrefs.comboOffset[2];
numScore.y -= ClientPrefs.comboOffset[3];
if (ClientPrefs.colorRatingHit && ClientPrefs.ratingType != 'Tails Gets Trolled V4' && ClientPrefs.ratingType != 'Doki Doki+' && noteDiff >= ClientPrefs.perfectWindow) numScore.color = rating.color;
if (ClientPrefs.colorRatingHit && ClientPrefs.ratingType != 'Tails Gets Trolled V4' && ClientPrefs.ratingType != 'Doki Doki+' && !miss)
{
switch (daRating.name) //This is so stupid, but it works
{
case 'sick': numScore.color = FlxColor.CYAN;
case 'good': numScore.color = FlxColor.LIME;
case 'bad': numScore.color = FlxColor.ORANGE;
case 'shit': numScore.color = FlxColor.RED;
default: numScore.color = FlxColor.WHITE;
}
}
if (!ClientPrefs.comboStacking)
lastScore.push(numScore);
@@ -5416,98 +5408,90 @@ class PlayState extends MusicBeatState
startDelay: Conductor.crochet * 0.002 / playbackRate
});
}
}
FlxTween.tween(rating, {alpha: 0}, 0.2 / playbackRate, {
startDelay: Conductor.crochet * 0.001 / playbackRate,
onComplete: function(tween:FlxTween)
{
rating.destroy();
if (ClientPrefs.showMS && !ClientPrefs.hideHud && popUpsFrame <= 3) {
FlxTween.cancelTweensOf(msTxt);
msTxt.cameras = [camHUD];
msTxt.visible = true;
msTxt.screenCenter();
msTxt.x = offset + 80;
msTxt.alpha = 1;
msTxt.text = FlxMath.roundDecimal(-noteDiff, 3) + " MS";
if (cpuControlled) msTxt.text = "0 MS (Bot)";
msTxt.x += ClientPrefs.comboOffset[0];
msTxt.y -= ClientPrefs.comboOffset[1];
if (combo >= 1000000) msTxt.x += 30;
if (combo >= 100000) msTxt.x += 30;
if (combo >= 10000) msTxt.x += 30;
FlxTween.tween(msTxt,
{y: msTxt.y + 8},
0.1 / playbackRate,
{onComplete: function(_){
FlxTween.tween(msTxt, {alpha: 0}, 0.2 / playbackRate, {
// ease: FlxEase.circOut,
onComplete: function(_){msTxt.visible = false;},
startDelay: Conductor.stepCrochet * 0.005 / playbackRate
});
}
});
switch (daRating.name) //This is so stupid, but it works
{
case 'perfect': msTxt.color = FlxColor.YELLOW;
case 'sick': msTxt.color = FlxColor.CYAN;
case 'good': msTxt.color = FlxColor.LIME;
case 'bad': msTxt.color = FlxColor.ORANGE;
case 'shit': msTxt.color = FlxColor.RED;
default: msTxt.color = FlxColor.WHITE;
}
if (miss) msTxt.color = FlxColor.fromRGB(204, 66, 66);
}
if (ClientPrefs.ratesAndCombo && ClientPrefs.showMS && !ClientPrefs.hideHud && popUpsFrame <= 3) {
FlxTween.cancelTweensOf(msTxt);
msTxt.cameras = [camHUD];
msTxt.visible = true;
msTxt.screenCenter();
msTxt.x = offset + 80;
msTxt.alpha = 1;
msTxt.text = FlxMath.roundDecimal(-noteDiff, 3) + " MS";
if (cpuControlled) msTxt.text = "0 MS (Bot)";
msTxt.x += ClientPrefs.comboOffset[0];
msTxt.y -= ClientPrefs.comboOffset[1];
if (combo >= 1000000) msTxt.x += 30;
if (combo >= 100000) msTxt.x += 30;
if (combo >= 10000) msTxt.x += 30;
FlxTween.tween(msTxt,
{y: msTxt.y + 8},
0.1 / playbackRate,
{onComplete: function(_){
FlxTween.tween(msTxt, {alpha: 0}, 0.2 / playbackRate, {
// ease: FlxEase.circOut,
onComplete: function(_){msTxt.visible = false;},
startDelay: Conductor.stepCrochet * 0.005 / playbackRate
});
}
});
switch (daRating.name) //This is so stupid, but it works
{
case 'perfect': msTxt.color = FlxColor.YELLOW;
case 'sick': msTxt.color = FlxColor.CYAN;
case 'good': msTxt.color = FlxColor.LIME;
case 'bad': msTxt.color = FlxColor.ORANGE;
case 'shit': msTxt.color = FlxColor.RED;
default: msTxt.color = FlxColor.WHITE;
}
if (miss) msTxt.color = FlxColor.fromRGB(204, 66, 66);
if (ClientPrefs.ratingPopups && ClientPrefs.ratingType == 'Simple' && popUpsFrame <= 3 && !ClientPrefs.hideHud) {
FlxTween.cancelTweensOf(judgeTxt);
FlxTween.cancelTweensOf(judgeTxt.scale);
judgeTxt.cameras = [camHUD];
judgeTxt.visible = true;
judgeTxt.screenCenter(X);
judgeTxt.y = !ClientPrefs.downScroll ? botplayTxt.y + 60 : botplayTxt.y - 60;
judgeTxt.alpha = 1;
if (!miss) switch (daRating.name)
{
case 'perfect':
judgeTxt.color = FlxColor.YELLOW;
judgeTxt.text = hitStrings[0] + '\n' + FlxStringUtil.formatMoney(combo, false);
case 'sick':
judgeTxt.color = FlxColor.CYAN;
judgeTxt.text = hitStrings[1] + '\n' + FlxStringUtil.formatMoney(combo, false);
case 'good':
judgeTxt.color = FlxColor.LIME;
judgeTxt.text = hitStrings[2] + '\n' + FlxStringUtil.formatMoney(combo, false);
case 'bad':
judgeTxt.color = FlxColor.ORANGE;
judgeTxt.text = hitStrings[3] + '\n' + FlxStringUtil.formatMoney(combo, false);
case 'shit':
judgeTxt.color = FlxColor.RED;
judgeTxt.text = hitStrings[4] + '\n' + FlxStringUtil.formatMoney(combo, false);
default: judgeTxt.color = FlxColor.WHITE;
}
if (ClientPrefs.ratesAndCombo && ClientPrefs.ratingType == 'Simple' && popUpsFrame <= 3 && !ClientPrefs.hideHud) {
FlxTween.cancelTweensOf(judgeTxt);
FlxTween.cancelTweensOf(judgeTxt.scale);
judgeTxt.cameras = [camHUD];
judgeTxt.visible = true;
judgeTxt.screenCenter(X);
judgeTxt.y = !ClientPrefs.downScroll ? botplayTxt.y + 60 : botplayTxt.y - 60;
judgeTxt.alpha = 1;
if (!miss) switch (daRating.name)
{
case 'perfect':
judgeTxt.color = FlxColor.YELLOW;
judgeTxt.text = hitStrings[0] + '\n' + FlxStringUtil.formatMoney(combo, false);
case 'sick':
judgeTxt.color = FlxColor.CYAN;
judgeTxt.text = hitStrings[1] + '\n' + FlxStringUtil.formatMoney(combo, false);
case 'good':
judgeTxt.color = FlxColor.LIME;
judgeTxt.text = hitStrings[2] + '\n' + FlxStringUtil.formatMoney(combo, false);
case 'bad':
judgeTxt.color = FlxColor.ORANGE;
judgeTxt.text = hitStrings[3] + '\n' + FlxStringUtil.formatMoney(combo, false);
case 'shit':
judgeTxt.color = FlxColor.RED;
judgeTxt.text = hitStrings[4] + '\n' + FlxStringUtil.formatMoney(combo, false);
default: judgeTxt.color = FlxColor.WHITE;
}
else
{
judgeTxt.color = FlxColor.fromRGB(204, 66, 66);
judgeTxt.text = hitStrings[5] + '\n' + FlxStringUtil.formatMoney(combo, false);
}
judgeTxt.scale.x = 1.075;
judgeTxt.scale.y = 1.075;
FlxTween.tween(judgeTxt.scale,
{x: 1, y: 1},
0.1 / playbackRate,
{onComplete: function(_){
FlxTween.tween(judgeTxt.scale, {x: 0, y: 0}, 0.1 / playbackRate, {
onComplete: function(_){judgeTxt.visible = false;},
startDelay: Conductor.stepCrochet * 0.005 / playbackRate
});
}
});
else
{
judgeTxt.color = FlxColor.fromRGB(204, 66, 66);
judgeTxt.text = hitStrings[5] + '\n' + FlxStringUtil.formatMoney(combo, false);
}
judgeTxt.scale.x = 1.075;
judgeTxt.scale.y = 1.075;
FlxTween.tween(judgeTxt.scale,
{x: 1, y: 1},
0.1 / playbackRate,
{onComplete: function(_){
FlxTween.tween(judgeTxt.scale, {x: 0, y: 0}, 0.1 / playbackRate, {
onComplete: function(_){judgeTxt.visible = false;},
startDelay: Conductor.stepCrochet * 0.005 / playbackRate
});
}
});
}
}
@@ -6074,7 +6058,7 @@ class PlayState extends MusicBeatState
} else {
inline playerStrums.members[note.noteData].playAnim('confirm', true);
}
playerStrums.members[note.noteData].resetAnim = calculateResetTime(note.isSustainNote);
playerStrums.members[note.noteData].resetAnim = calculateResetTime();
}
} else if (ClientPrefs.playerLightStrum && !cpuControlled) {
final spr = playerStrums.members[note.noteData];
@@ -6151,7 +6135,7 @@ class PlayState extends MusicBeatState
{
strumsHit[(noteAlt.noteData % 4) + 4] = true;
inline playerStrums.members[noteAlt.noteData].playAnim('confirm', true);
playerStrums.members[noteAlt.noteData].resetAnim = calculateResetTime(noteAlt.isSustainNote);
playerStrums.members[noteAlt.noteData].resetAnim = calculateResetTime();
}
}
if (!noteAlt.isSustainNote && cpuControlled)
@@ -6238,7 +6222,7 @@ class PlayState extends MusicBeatState
} else {
inline opponentStrums.members[daNote.noteData].playAnim('confirm', true);
}
opponentStrums.members[daNote.noteData].resetAnim = calculateResetTime(daNote.isSustainNote);
opponentStrums.members[daNote.noteData].resetAnim = calculateResetTime();
}
daNote.hitByOpponent = true;
@@ -6305,7 +6289,7 @@ class PlayState extends MusicBeatState
{
strumsHit[noteAlt.noteData % 4] = true;
inline opponentStrums.members[noteAlt.noteData].playAnim('confirm', true);
opponentStrums.members[noteAlt.noteData].resetAnim = calculateResetTime(noteAlt.isSustainNote);
opponentStrums.members[noteAlt.noteData].resetAnim = calculateResetTime();
}
if (!noteAlt.isSustainNote && cpuControlled)
{

View File

@@ -35,6 +35,7 @@ class EditorPlayState extends MusicBeatState
public var playerStrums:FlxTypedGroup<StrumNote>;
public var grpNoteSplashes:FlxTypedGroup<NoteSplash>;
public var sustainNotes:NoteGroup;
public var notes:NoteGroup;
public var unspawnNotes:Array<PreloadedChartNote> = [];
@@ -93,6 +94,9 @@ class EditorPlayState extends MusicBeatState
comboGroup = new FlxTypedGroup<FlxSprite>();
add(comboGroup);
sustainNotes = new NoteGroup();
add(sustainNotes);
strumLineNotes = new FlxTypedGroup<StrumNote>();
opponentStrums = new FlxTypedGroup<StrumNote>();
playerStrums = new FlxTypedGroup<StrumNote>();
@@ -380,25 +384,25 @@ class EditorPlayState extends MusicBeatState
notesAddedCount -= (notesAddedCount - unspawnNotes.length);
while (unspawnNotes[notesAddedCount] != null && unspawnNotes[notesAddedCount].strumTime - Conductor.songPosition < (1500 / PlayState.SONG.speed / unspawnNotes[notesAddedCount].multSpeed)) {
if (ClientPrefs.fastNoteSpawn) notes.spawnNote(unspawnNotes[notesAddedCount]);
if (ClientPrefs.fastNoteSpawn) (unspawnNotes[notesAddedCount].isSustainNote ? sustainNotes : notes).spawnNote(unspawnNotes[notesAddedCount]);
else
{
notes.recycle(Note).setupNoteData(unspawnNotes[notesAddedCount]);
}
(unspawnNotes[notesAddedCount].isSustainNote ? sustainNotes : notes).recycle(Note).setupNoteData(unspawnNotes[notesAddedCount]);
notesAddedCount++;
}
if (notesAddedCount > 0)
unspawnNotes.splice(0, notesAddedCount);
if (notesAddedCount > 0)
unspawnNotes.splice(0, notesAddedCount);
}
if (generatedMusic)
{
var noteIndex:Int = notes.members.length;
while (noteIndex >= 0)
for (group in [notes, sustainNotes])
{
var daNote:Note = notes.members[noteIndex--];
if (daNote != null) daNote.update(elapsed);
updateNote(daNote);
group.forEach(function(daNote)
{
updateNote(daNote);
});
group.sort(FlxSort.byY, ClientPrefs.downScroll ? FlxSort.ASCENDING : FlxSort.DESCENDING);
}
if (Conductor.songPosition >= FlxG.sound.music.length) endSong();
}
@@ -434,7 +438,8 @@ class EditorPlayState extends MusicBeatState
if (generatedMusic)
{
notes.sort(FlxSort.byY, ClientPrefs.downScroll ? FlxSort.ASCENDING : FlxSort.DESCENDING);
for (group in [notes, sustainNotes])
group.sort(FlxSort.byY, ClientPrefs.downScroll ? FlxSort.ASCENDING : FlxSort.DESCENDING);
}
}
@@ -493,7 +498,7 @@ class EditorPlayState extends MusicBeatState
//trace('test!');
var sortedNotesList:Array<Note> = [];
notes.forEachAlive(function(daNote:Note)
for (group in [notes, sustainNotes]) group.forEachAlive(function(daNote:Note)
{
if (daNote.canBeHit && daNote.mustPress && !daNote.tooLate && !daNote.wasGoodHit && !daNote.isSustainNote)
{
@@ -613,7 +618,7 @@ class EditorPlayState extends MusicBeatState
if (generatedMusic)
{
// rewritten inputs???
notes.forEachAlive(function(daNote:Note)
for (group in [notes, sustainNotes]) group.forEachAlive(function(daNote:Note)
{
// hold note functions
if (daNote.isSustainNote && controlHoldArray[daNote.noteData] && daNote.canBeHit
@@ -657,7 +662,12 @@ class EditorPlayState extends MusicBeatState
if(daNote.isSustainNote && !daNote.animation.curAnim.name.endsWith('end')) {
time += 0.15;
}
StrumPlayAnim(true, Std.int(Math.abs(daNote.noteData)) % 4, time);
if (ClientPrefs.noteColorStyle != 'Normal' && ClientPrefs.showNotes && ClientPrefs.enableColorShader) {
inline opponentStrums.members[daNote.noteData].playAnim('confirm', true, daNote.rgbShader.r, daNote.rgbShader.g, daNote.rgbShader.b);
} else {
inline opponentStrums.members[daNote.noteData].playAnim('confirm', true);
}
opponentStrums.members[daNote.noteData].resetAnim = calculateResetTime(daNote.isSustainNote);
daNote.hitByOpponent = true;
if (!daNote.isSustainNote)
@@ -672,7 +682,6 @@ class EditorPlayState extends MusicBeatState
if (PlayState.SONG.needsVoices)
vocals.volume = 1;
goodNoteHit(daNote);
if (ClientPrefs.fastNoteSpawn) notes.pushToPool(daNote);
}
if (!daNote.exists) return;
@@ -683,10 +692,10 @@ class EditorPlayState extends MusicBeatState
if (daNote.tooLate || !daNote.wasGoodHit)
{
//Dupe note remove
notes.forEachAlive(function(note:Note) {
for (group in [notes, sustainNotes]) group.forEachAlive(function(note:Note) {
if (daNote != note && daNote.mustPress && daNote.noteData == note.noteData && daNote.isSustainNote == note.isSustainNote && Math.abs(daNote.strumTime - note.strumTime) < 10) {
daNote.exists = false;
if (ClientPrefs.fastNoteSpawn) notes.pushToPool(daNote);
if (ClientPrefs.fastNoteSpawn) (daNote.isSustainNote ? sustainNotes : notes).pushToPool(daNote);
}
});
@@ -697,7 +706,7 @@ class EditorPlayState extends MusicBeatState
}
}
daNote.exists = false;
if (ClientPrefs.fastNoteSpawn) notes.pushToPool(daNote);
if (ClientPrefs.fastNoteSpawn) (daNote.isSustainNote ? sustainNotes : notes).pushToPool(daNote);
}
}
}
@@ -723,6 +732,7 @@ class EditorPlayState extends MusicBeatState
if (!note.isSustainNote)
{
note.exists = false;
if (ClientPrefs.fastNoteSpawn) notes.pushToPool(note);
}
return;
}
@@ -736,20 +746,27 @@ class EditorPlayState extends MusicBeatState
if (cpuControlled)
{
var time:Float = 0.15;
if(note.isSustainNote && !note.animation.curAnim.name.endsWith('end')) {
time += 0.15;
if(playerStrums.members[note.noteData] != null) {
if (ClientPrefs.noteColorStyle != 'Normal' && ClientPrefs.showNotes && ClientPrefs.enableColorShader) {
inline playerStrums.members[note.noteData].playAnim('confirm', true, note.rgbShader.r, note.rgbShader.g, note.rgbShader.b);
} else {
inline playerStrums.members[note.noteData].playAnim('confirm', true);
}
playerStrums.members[note.noteData].resetAnim = calculateResetTime(note.isSustainNote);
}
StrumPlayAnim(false, Std.int(Math.abs(note.noteData)) % 4, time);
}
else
playerStrums.forEach(function(spr:StrumNote)
{
if (Math.abs(note.noteData) == spr.ID)
final spr = playerStrums.members[note.noteData];
if(spr != null)
{
spr.playAnim('confirm', true);
if (ClientPrefs.noteColorStyle != 'Normal' && ClientPrefs.showNotes && ClientPrefs.enableColorShader) {
inline spr.playAnim('confirm', true, note.rgbShader.r, note.rgbShader.g, note.rgbShader.b);
} else {
inline spr.playAnim('confirm', true);
}
}
});
}
note.wasGoodHit = true;
vocals.volume = 1;
@@ -757,6 +774,7 @@ class EditorPlayState extends MusicBeatState
if (!note.isSustainNote)
{
note.exists = false;
if (ClientPrefs.fastNoteSpawn) notes.pushToPool(note);
}
}
}
@@ -772,6 +790,11 @@ class EditorPlayState extends MusicBeatState
vocals.volume = 0;
}
function calculateResetTime(?sustainNote:Bool = false):Float {
if (ClientPrefs.strumLitStyle == 'BPM Based') return (Conductor.stepCrochet * 1.5 / 1000) * (!sustainNote ? 1 : 2);
return 0.15 * (!sustainNote ? 1 : 2);
}
var COMBO_X:Float = 400;
var COMBO_Y:Float = 340;
private function popUpScore(note:Note = null):Void

View File

@@ -43,9 +43,23 @@ class OptimizationSubState extends BaseOptionsMenu
true);
addOption(option);
var option:Option = new Option('Show Ratings & Combo',
"If checked, shows the ratings & combo. Kinda defeats the purpose of this engine though...",
'ratesAndCombo',
var option:Option = new Option('Show Ratings',
"If unchecked, the game will not show a rating sprite when hitting a note.",
'ratingPopups',
'bool',
true);
addOption(option);
var option:Option = new Option('Show Combo Numbers',
"If unchecked, the game will not show combo numbers when hitting a note.",
'comboPopups',
'bool',
true);
addOption(option);
var option:Option = new Option('Show MS Popup',
"If checked, hitting a note will also show how late/early you hit it.",
'showMS',
'bool',
false);
addOption(option);

View File

@@ -442,13 +442,6 @@ class VisualsUISubState extends BaseOptionsMenu
true);
addOption(option);
var option:Option = new Option('Show MS Popup',
"If checked, hitting a note will also show how late/early you hit it.",
'showMS',
'bool',
false);
addOption(option);
var option:Option = new Option('Flashing Lights',
"Uncheck this if you're sensitive to flashing lights!",
'flashing',