mirror of
https://github.com/GTNewHorizons/NotEnoughItems.git
synced 2026-11-13 17:04:03 +00:00
Add config to ignore overlap with potion effect HUD (#255)
This commit is contained in:
1 parent
ae21012ea2
commit
68b9453328
3 files changed
+13
No files matched your search
@@ -240,6 +240,9 @@ public class NEIClientConfig {
|
||||
tag.getTag("inventory.creative_tab_style").setComment("Creative or JEI style tabs").getBooleanValue(false);
|
||||
API.addOption(new OptionToggleButton("inventory.creative_tab_style", true));
|
||||
|
||||
tag.getTag("inventory.ignore_potion_overlap").setComment("Ignore overlap with potion effect HUD").getBooleanValue(false);
|
||||
API.addOption(new OptionToggleButton("inventory.ignore_potion_overlap", true));
|
||||
|
||||
tag.getTag("tools.handler_load_from_config").setComment("ADVANCED: Load handlers from config").getBooleanValue(false);
|
||||
API.addOption(new OptionToggleButton("tools.handler_load_from_config", true) {
|
||||
@Override
|
||||
@@ -471,6 +474,9 @@ public class NEIClientConfig {
|
||||
public static boolean useCreativeTabStyle() {
|
||||
return getBooleanSetting("inventory.creative_tab_style");
|
||||
}
|
||||
public static boolean ignorePotionOverlap() {
|
||||
return getBooleanSetting("inventory.ignore_potion_overlap");
|
||||
}
|
||||
public static boolean isEnabled() {
|
||||
return enabledOverride && getBooleanSetting("inventory.widgetsenabled");
|
||||
}
|
||||
|
||||
@@ -16,6 +16,10 @@ import java.util.Collection;
|
||||
public class NEIPotionGuiHandler extends INEIGuiAdapter {
|
||||
@Override
|
||||
public boolean hideItemPanelSlot(GuiContainer guiContainer, int slotX, int slotY, int slotW, int slotH) {
|
||||
if (NEIClientConfig.ignorePotionOverlap()) {
|
||||
return false;
|
||||
}
|
||||
|
||||
if(guiContainer instanceof InventoryEffectRenderer) {
|
||||
int x = guiContainer.guiLeft - 124;
|
||||
int y = guiContainer.guiTop;
|
||||
|
||||
Reference in new issue
Block a user