Merge pull request #209 from yugecin/aspire-fix

Aspire fix
This commit is contained in:
Jeffrey Han 2016-12-09 23:11:42 -05:00 committed by GitHub
commit 8186236556
3 changed files with 15 additions and 2 deletions

View File

@ -98,7 +98,7 @@ public class TimingPoint {
/**
* Returns the slider multiplier. [INHERITED]
*/
public float getSliderMultiplier() { return velocity / -100f; }
public float getSliderMultiplier() { return Utils.clamp(-velocity, 10, 1000) / 100f; }
/**
* Returns the meter.

View File

@ -109,6 +109,11 @@ public abstract class EqualDistanceMultiCurve extends Curve {
// if (hitObject.getRepeatCount() > 1) {
Vec2f c1 = curve[0];
int cnt = 1;
if (cnt > ncurve) {
return;
}
Vec2f c2 = curve[cnt++];
while (cnt <= ncurve && c2.cpy().sub(c1).len() < 1)
c2 = curve[cnt++];

View File

@ -465,7 +465,15 @@ public class Game extends BasicGameState {
// letterbox effect (black bars on top/bottom)
if (beatmap.letterboxInBreaks && breakLength >= 4000) {
// let it fade in/out
float a = Color.black.a;
if (trackPosition - breakTime > breakLength / 2) {
Color.black.a = (Math.min(500f, breakTime + breakLength - trackPosition)) / 500f;
} else {
Color.black.a = Math.min(500, trackPosition - breakTime) / 500f;
}
g.setColor(Color.black);
Color.black.a = a;
g.fillRect(0, 0, width, height * 0.125f);
g.fillRect(0, height * 0.875f, width, height * 0.125f);
}
@ -865,7 +873,7 @@ public class Game extends BasicGameState {
if (beatmap.breaks != null && breakIndex < beatmap.breaks.size()) {
int breakValue = beatmap.breaks.get(breakIndex);
if (breakTime > 0) { // in a break period
if (trackPosition < breakValue)
if (trackPosition < breakValue && trackPosition < beatmap.objects[objectIndex].getTime() - approachTime)
return;
else {
// break is over