fix shrinking sliders for fallback sliders

This commit is contained in:
yugecin 2016-12-05 00:35:11 +01:00
parent 7e82b05a56
commit d5296d51fa

View File

@ -416,14 +416,18 @@ public class Slider extends GameObject {
} }
game.setSlidercurveTo(baseSliderFrom + (int) (curveIntervalTo * curve.getCurvePoints().length)); game.setSlidercurveTo(baseSliderFrom + (int) (curveIntervalTo * curve.getCurvePoints().length));
} else { } else {
if (Options.isShrinkingSliders() && curveIntervalFrom > 0) { if (Options.isFallbackSliders() && curveIntervalFrom > 0 && repeats % 2 == 0) {
int curvelen = curve.getCurvePoints().length; curve.draw(curveColor, 1f - curveIntervalTo, 1f - curveIntervalFrom);
if (repeats % 2 == 0) { } else {
curve.splice((int) ((1f - curveIntervalFrom) * curvelen), curvelen); if (Options.isShrinkingSliders() && curveIntervalFrom > 0 && !Options.isFallbackSliders()) {
curveIntervalFrom = 0f; int curvelen = curve.getCurvePoints().length;
if (repeats % 2 == 0) {
curve.splice((int) ((1f - curveIntervalFrom) * curvelen), curvelen);
curveIntervalFrom = 0f;
}
} }
curve.draw(curveColor, curveIntervalFrom, curveIntervalTo);
} }
curve.draw(curveColor, curveIntervalFrom, curveIntervalTo);
} }
return curveIntervalTo == 1f; return curveIntervalTo == 1f;
} }