+64 in crafting start GUI now gives 64 from the first time instead of 65, fixes #334
This commit is contained in:
@@ -3,6 +3,7 @@
|
|||||||
### 1.0.2
|
### 1.0.2
|
||||||
- Fixed processing patterns not handling item insertion sometimes (raoulvdberge)
|
- Fixed processing patterns not handling item insertion sometimes (raoulvdberge)
|
||||||
- Removed crafting task limit in crafting start GUI (raoulvdberge)
|
- Removed crafting task limit in crafting start GUI (raoulvdberge)
|
||||||
|
- +64 in crafting start GUI now gives 64 from the first time instead of 65 (raoulvdberge)
|
||||||
|
|
||||||
### 1.0.1
|
### 1.0.1
|
||||||
- Fixed advanced tooltips showing in Grid when not configured to do so (raoulvdberge)
|
- Fixed advanced tooltips showing in Grid when not configured to do so (raoulvdberge)
|
||||||
|
|||||||
@@ -14,7 +14,7 @@ import refinedstorage.network.MessageGridCraftingStart;
|
|||||||
|
|
||||||
import java.io.IOException;
|
import java.io.IOException;
|
||||||
|
|
||||||
public class GuiCraftingSettings extends GuiBase {
|
public class GuiCraftingStart extends GuiBase {
|
||||||
private static final int DEFAULT_AMOUNT = 1;
|
private static final int DEFAULT_AMOUNT = 1;
|
||||||
|
|
||||||
private GuiTextField amountField;
|
private GuiTextField amountField;
|
||||||
@@ -24,7 +24,7 @@ public class GuiCraftingSettings extends GuiBase {
|
|||||||
private GuiButton cancelButton;
|
private GuiButton cancelButton;
|
||||||
private GuiButton[] incrementButtons = new GuiButton[6];
|
private GuiButton[] incrementButtons = new GuiButton[6];
|
||||||
|
|
||||||
public GuiCraftingSettings(GuiGrid gui, EntityPlayer player, ClientStackItem stack) {
|
public GuiCraftingStart(GuiGrid gui, EntityPlayer player, ClientStackItem stack) {
|
||||||
super(new ContainerCraftingSettings(player, stack.getStack()), 172, 99);
|
super(new ContainerCraftingSettings(player, stack.getStack()), 172, 99);
|
||||||
|
|
||||||
this.gui = gui;
|
this.gui = gui;
|
||||||
@@ -110,7 +110,7 @@ public class GuiCraftingSettings extends GuiBase {
|
|||||||
|
|
||||||
int newAmount = Integer.parseInt(incrementButton.displayString);
|
int newAmount = Integer.parseInt(incrementButton.displayString);
|
||||||
|
|
||||||
newAmount = Math.max(DEFAULT_AMOUNT, oldAmount + newAmount);
|
newAmount = Math.max(DEFAULT_AMOUNT, ((oldAmount == 1 && newAmount != 1) ? 0 : oldAmount) + newAmount);
|
||||||
|
|
||||||
amountField.setText(String.valueOf(newAmount));
|
amountField.setText(String.valueOf(newAmount));
|
||||||
|
|
||||||
@@ -373,7 +373,7 @@ public class GuiGrid extends GuiBase {
|
|||||||
ClientStackItem stack = (ClientStackItem) STACKS.get(slotNumber);
|
ClientStackItem stack = (ClientStackItem) STACKS.get(slotNumber);
|
||||||
|
|
||||||
if (stack.isCraftable() && (stack.getQuantity() == 0 || (GuiScreen.isShiftKeyDown() && GuiScreen.isCtrlKeyDown()))) {
|
if (stack.isCraftable() && (stack.getQuantity() == 0 || (GuiScreen.isShiftKeyDown() && GuiScreen.isCtrlKeyDown()))) {
|
||||||
FMLCommonHandler.instance().showGuiScreen(new GuiCraftingSettings(this, container.getPlayer(), stack));
|
FMLCommonHandler.instance().showGuiScreen(new GuiCraftingStart(this, container.getPlayer(), stack));
|
||||||
} else {
|
} else {
|
||||||
int flags = 0;
|
int flags = 0;
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user