Skip to content

Commit

Permalink
Merge pull request #446 from Team-EnderIO/fix/alloysmeltermodpersistance
Browse files Browse the repository at this point in the history
undo #blamerover
  • Loading branch information
justliliandev authored Aug 10, 2023
2 parents b58890c + 4387337 commit 80aadb7
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -339,7 +339,7 @@ protected Optional<AlloySmeltingRecipe> findRecipe() {
public void saveAdditional(CompoundTag pTag) {
craftingTaskHost.save(pTag);

if (isPrimitiveSmelter()) {
if (!isPrimitiveSmelter()) {
pTag.putInt(MachineNBTKeys.MACHINE_MODE, this.mode.ordinal());
}
pTag.putInt(MachineNBTKeys.PROCESSED_INPUTS, craftingTaskHost.getContainer().getInputsTaken());
Expand All @@ -350,7 +350,7 @@ public void saveAdditional(CompoundTag pTag) {
public void load(CompoundTag pTag) {
craftingTaskHost.load(pTag);

if (isPrimitiveSmelter()) {
if (!isPrimitiveSmelter()) {
try {
mode = AlloySmelterMode.values()[pTag.getInt(MachineNBTKeys.MACHINE_MODE)];
} catch (IndexOutOfBoundsException ex) { // In case something happens in the future.
Expand Down

0 comments on commit 80aadb7

Please sign in to comment.