CI fixes.

This commit is contained in:
smoogipooo 2017-05-22 13:43:53 +09:00
parent 4556ead3b6
commit f70bfd5378
2 changed files with 4 additions and 4 deletions

View File

@ -62,7 +62,7 @@ protected override IEnumerable<ManiaHitObject> ConvertHitObject(HitObject origin
yield return obj;
}
private List<double> prevNoteTimes = new List<double>(max_notes_for_density);
private readonly List<double> prevNoteTimes = new List<double>(max_notes_for_density);
private double density = int.MaxValue;
private void computeDensity(double newNoteTime)
{

View File

@ -89,7 +89,7 @@ public override Pattern Generate()
{
int lastColumn = PreviousPattern.HitObjects.First().Column;
if ((convertType & PatternType.Reverse) > 0 && PreviousPattern.HitObjects.Count() > 0)
if ((convertType & PatternType.Reverse) > 0 && PreviousPattern.HitObjects.Any())
{
// Generate a new pattern by copying the last hit objects in reverse-column order
var pattern = new Pattern();
@ -116,7 +116,7 @@ public override Pattern Generate()
return pattern;
}
if ((convertType & PatternType.ForceStack) > 0 && PreviousPattern.HitObjects.Count() > 0)
if ((convertType & PatternType.ForceStack) > 0 && PreviousPattern.HitObjects.Any())
{
// Generate a new pattern by placing on the already filled columns
var pattern = new Pattern();
@ -217,7 +217,7 @@ private Pattern generateRandomNotes(int noteCount)
int nextColumn = GetColumn((HitObject as IHasXPosition)?.X ?? 0, true);
for (int i = 0; i < noteCount; i++)
{
while (pattern.ColumnHasObject(nextColumn) || (PreviousPattern.ColumnHasObject(nextColumn) && !allowStacking))
while (pattern.ColumnHasObject(nextColumn) || PreviousPattern.ColumnHasObject(nextColumn) && !allowStacking)
{
if ((convertType & PatternType.Gathered) > 0)
{