Fix for row interval

This commit is contained in:
Fabrizio La Rosa 2020-08-03 18:30:05 +02:00
parent 094228501b
commit f633b7dab2
2 changed files with 3 additions and 3 deletions

View File

@ -41,7 +41,7 @@ class Driver extends BukkitRunnable {
for(int i = 1; i<16; i++) {
List<String> rowLines = config.getStringList("Rows." + i + ".Content");
if(!rowLines.isEmpty()) {
Row row = new Row(rowLines, config.getInt("Interval"));
Row row = new Row(rowLines, config.getInt("Rows." + i + ".Interval"));
rows.add(row);
}
}

View File

@ -17,7 +17,7 @@ class Row {
public Row(List<String> lines, int interval) {
this.lines = lines;
this.interval = interval;
this.current = 1;
this.current = 0;
this.count = 0;
if(interval < 0) {
@ -29,7 +29,7 @@ class Row {
if(lines.isEmpty()) {
line = "";
} else {
line = TextUtils.formatText(lines.get(0));
line = TextUtils.formatText(lines.get(current));
}
}