bar data set and fixed index mistake

This commit is contained in:
2017-07-16 02:15:00 -05:00
parent cecec88df0
commit 8db65566c9
12 changed files with 9 additions and 5 deletions

View File

@@ -96,8 +96,10 @@ public class GamePlayMap {
int howMuchLess = -(index - amount);
index = 0;
return howMuchLess;
} else {
index -= amount;
return amount;
}
return amount;
}
public void goForward(int amount) {

View File

@@ -72,8 +72,9 @@ public class RhythmMapAlgorithm implements Runnable {
map.resetIndex();
}
if (bassPeaks.get(index) != 0) {
int spawnLocations = (Polyjet.GAME_AREA_WIDTH-8)/8;
map.addToMap(Entities.BAR,
MathUtils.round(1.5f+rand.nextFloat()*(Polyjet.GAME_AREA_WIDTH-3)),
MathUtils.round(rand.nextFloat()*spawnLocations)*8,
(8f/avgSPB)*speedMod);
} else {
if (UMPeaks.get(index) != 0) {