fix tooltip problem

(cherry picked from commit e467ff809a)
This commit is contained in:
vfyjxf authored and Martin Robertz committed 2022-02-07 19:04:04 +01:00
1 parent 15a6344ba2
commit ecfefdfd83
2 files changed
+12 -6

No files matched your search

@@ -85,7 +85,9 @@ public class NEEContainerDrawHandler {
if (this.isCraftingTerm || this.isPatternTerm) {
GuiRecipe gui = (GuiRecipe) event.gui;
if (gui.getHandler() != null && NEECraftingHandler.isCraftingTableRecipe(gui.getHandler())) {
IRecipeHandler currentHandler = gui.currenthandlers.get(gui.recipetype);
if (NEECraftingHandler.isCraftingTableRecipe(currentHandler)) {
if (this.trackerMap.isEmpty()) {
initIngredientTracker(gui);
@@ -208,11 +210,11 @@ public class NEEContainerDrawHandler {
if (this.drawRequestTooltip) {
if (NEECraftingHelper.isIsPatternInterfaceExists()) {
tooltips.add(String.format("%s" + EnumChatFormatting.GRAY + " + " +
EnumChatFormatting.BLUE + I18n.format("neenergistics.gui.tooltip.helper.crafting.text1"),
EnumChatFormatting.BLUE + I18n.format("neenergistics.gui.tooltip.helper.crafting.text2"),
EnumChatFormatting.YELLOW + Keyboard.getKeyName(NEIClientConfig.getKeyBinding("nee.preview"))));
} else {
tooltips.add(String.format("%s" + EnumChatFormatting.GRAY + " + " +
EnumChatFormatting.BLUE + I18n.format("neenergistics.gui.tooltip.helper.crafting.text2"),
EnumChatFormatting.BLUE + I18n.format("neenergistics.gui.tooltip.helper.crafting.text1"),
EnumChatFormatting.YELLOW + Keyboard.getKeyName(NEIClientConfig.getKeyBinding("nee.preview"))));
}
}