Skip to content
This repository has been archived by the owner on May 25, 2024. It is now read-only.

Commit

Permalink
Fixes Large Essentia Smeltery autoplace in survival (#182)
Browse files Browse the repository at this point in the history
* Fixes Large Essentia Smeltery Autoplace

* corrects the typo
  • Loading branch information
Lyfts authored Jul 21, 2023
1 parent bf7f9ca commit 235f9b0
Showing 1 changed file with 6 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -533,32 +533,32 @@ public int survivalConstruct(ItemStack stackSize, int elementBudget, IItemSource
actor,
false,
true);
int lenght = stackSize.stackSize + 2;
if (lenght > MAX_CONFIGURABLE_LENGTH) lenght = MAX_CONFIGURABLE_LENGTH + 2;
int length = stackSize.stackSize + 2;
if (length > MAX_CONFIGURABLE_LENGTH) length = MAX_CONFIGURABLE_LENGTH + 2;
built += survivialBuildPiece(
STRUCTURE_PIECE_LAST,
stackSize,
2,
2,
lenght + 1,
-length - 1,
elementBudget - built,
source,
actor,
false,
true);
while (lenght > 0) {
while (length > 0) {
built += survivialBuildPiece(
STRUCTURE_PIECE_LATER,
stackSize,
2,
2,
lenght,
-length,
elementBudget - built,
source,
actor,
false,
true);
lenght--;
length--;
}
return built;
}
Expand Down

0 comments on commit 235f9b0

Please sign in to comment.