chore: fix some code style warnings alongside
@@ -124,8 +124,8 @@ public void setDirty(boolean dirty) {
@Override
public int getEstimatedMemoryConsumptionInBytes() {
int extraDataSize = 0;
- for (int i = 0; i < extraData.length; i++) {
- extraDataSize += extraData[i].getEstimatedMemoryConsumptionInBytes();
+ for (TeraArray extraDatum : extraData) {
+ extraDataSize += extraDatum.getEstimatedMemoryConsumptionInBytes();
}
return blockData.getEstimatedMemoryConsumptionInBytes()
+ sunlightData.getEstimatedMemoryConsumptionInBytes()
@@ -315,8 +315,8 @@ public void deflate() {
int sunlightRegenSize = sunlightRegenData.getEstimatedMemoryConsumptionInBytes();
int lightSize = lightData.getEstimatedMemoryConsumptionInBytes();
int extraSize = 0;
- for (int i = 0; i < extraData.length; i++) {
- extraSize += extraData[i].getEstimatedMemoryConsumptionInBytes();
+ for (TeraArray extraDatum : extraData) {
+ extraSize += extraDatum.getEstimatedMemoryConsumptionInBytes();
}
int totalSize = blocksSize + sunlightRegenSize + sunlightSize + lightSize + extraSize;
@@ -329,8 +329,8 @@ public void deflate() {
int blocksReduced = blockData.getEstimatedMemoryConsumptionInBytes();
int lightReduced = lightData.getEstimatedMemoryConsumptionInBytes();
int extraReduced = 0;
- for (int i = 0; i < extraData.length; i++) {
- extraReduced += extraData[i].getEstimatedMemoryConsumptionInBytes();
+ for (TeraArray extraDatum : extraData) {
+ extraReduced += extraDatum.getEstimatedMemoryConsumptionInBytes();
}
int totalReduced = blocksReduced + sunlightRegenSize + sunlightSize + lightReduced + extraReduced;
@@ -391,7 +391,7 @@ public void deflateSunlight() {
"bytes, size-after: {} " +
"bytes, total-deflated-by: {}%, " +
"sunlight-deflated-by={}%, " +
- "sunlight-regen-deflated-by={}%, " +
+ "sunlight-regen-deflated-by={}%",
chunkPos,
SIZE_FORMAT.format(totalSize),
SIZE_FORMAT.format(totalReduced),
