diff --git a/CraftingGUI.cs b/CraftingGUI.cs index 6cf092f5..22bbfd2f 100644 --- a/CraftingGUI.cs +++ b/CraftingGUI.cs @@ -817,24 +817,39 @@ private static void UpdateCraftButton() } else if (curMouse.LeftButton == ButtonState.Pressed && selectedRecipe != null && IsAvailable(selectedRecipe, false) && PassesBlock(selectedRecipe)) { - if (craftTimer <= 0) + if (Main.keyState.IsKeyDown(Keys.LeftControl)) { - craftTimer = maxCraftTimer; - maxCraftTimer = maxCraftTimer * 3 / 4; - if (maxCraftTimer <= 0) - maxCraftTimer = 1; - TryCraft(); - if (RecursiveCraftIntegration.Enabled) - if (RecursiveCraftIntegration.UpdateRecipe(selectedRecipe)) - SetSelectedRecipe(selectedRecipe); - RefreshItems(); + while (IsAvailable(selectedRecipe, false) && PassesBlock(selectedRecipe)) + { + TryCraft(); + if (RecursiveCraftIntegration.Enabled) + if (RecursiveCraftIntegration.UpdateRecipe(selectedRecipe)) + SetSelectedRecipe(selectedRecipe); + RefreshItems(); + } Main.PlaySound(SoundID.Grab); } + else + { + if (craftTimer <= 0) + { + craftTimer = maxCraftTimer; + maxCraftTimer = maxCraftTimer * 3 / 4; + if (maxCraftTimer <= 0) + maxCraftTimer = 1; + TryCraft(); + if (RecursiveCraftIntegration.Enabled) + if (RecursiveCraftIntegration.UpdateRecipe(selectedRecipe)) + SetSelectedRecipe(selectedRecipe); + RefreshItems(); + Main.PlaySound(SoundID.Grab); + } - craftTimer--; - flag = true; - if (ModPlayer.AddToCraftedRecipes(selectedRecipe.createItem)) - RefreshItems(); + craftTimer--; + flag = true; + if (ModPlayer.AddToCraftedRecipes(selectedRecipe.createItem)) + RefreshItems(); + } } } else diff --git a/MagicStorageExtra.Translations.cs b/MagicStorageExtra.Translations.cs index 496ebad9..4e318cf6 100644 --- a/MagicStorageExtra.Translations.cs +++ b/MagicStorageExtra.Translations.cs @@ -248,7 +248,7 @@ private void AddTranslations() AddTranslation(text); text = CreateTranslation("CraftTooltip"); - text.SetDefault("Left click to Craft, Right click to get item for a test (only for new items)"); + text.SetDefault("Left click to Craft (ctrl to get max), Right click to get item for a test (only for new items)"); AddTranslation(text); text = CreateTranslation("TestItemSuffix");