Compare commits

..
Author SHA1 Message Date
slprime 09e3846bea Rebuild recipe catalysts only when something changes (#1157) 2026-11-23 21:12:03 +02:00
gorbit99andslprime d73df3aedc Clear bookmark group tooltip when pulling items or changing quantities (#1152)
Co-authored-by: slprime <[email protected]>
2026-11-22 10:11:37 +02:00
slprime f84b24724a Fix autocraft crash when started from the recipe screen (#1108) (#1150) 2026-11-21 19:57:06 +02:00
OrderedSet86 1bb550305c Less hacky light overlay fix for light opacity 0 blocks (#1124) 2026-11-19 16:26:46 +00:00
gorbit99 6649d28708 Change layout recalculation order (#1125) 2026-11-19 14:55:18 +01:00
slprime 6b7e465306 Copy fluid registry name instead of the display item id (#1122) 2026-11-17 21:53:30 +02:00
ab1e8153f5 Add NEI mob spawn overlay variants (#1111)
- Add multiple light level overlay modes (Connected, Square, GTNH Logo, Pufferfish, X)
- Set default F7 overlay to Connected
- Allow changing horizontal and vertical radius of light level overlay (before it was stuck at 16 blocks)
- Set default horizontal radius to 32 blocks
- Optimize performance by 10-30x compared to master
- Works with shaders (tested Complementary Unbound + Euphoria patches)

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Co-authored-by: Martin Robertz <[email protected]>
2026-11-16 19:51:42 +02:00
slprime 4257235e6e Don't toggle handler info widget while typing in recipe search (#1121) 2026-11-15 16:20:26 +02:00
slprime 1c33a5b7d6 Add recipe text search with ~ prefix (#1120) 2026-11-15 15:43:35 +02:00
slprime 8e6b31de18 Speed up GUID cache and bookmark recipe lookups (#1119) 2026-11-13 23:25:20 +02:00
DarkShadow44andslprime 1a27b02412 Don't copy stack unless it changed (#1116)
Co-authored-by: slprime <[email protected]>
2026-11-13 01:53:07 +02:00
slprime 0185cd64b1 Optimize GUI overlap scan for item panels (#1118) 2026-11-12 01:35:53 +02:00
slprime fbbeafcd79 Fix WorldClient leak after leaving the world (#1115) 2026-11-10 19:22:17 +02:00
UltraProdigy 9839d1d08f ci: run build and test on release branches 2026-11-09 01:11:38 -05:00
slprime 84d42de15f Make name optional in API.addCollapsibleGroup (#1114) 2026-11-08 18:13:37 +02:00
slprime d04e1c8e83 Add API.addCollapsibleGroup for registering collapsible item groups (#1113) 2026-11-08 17:37:44 +02:00
slprime 514af5669c Rollback fluent setters in PositionedStack added in #1106 (#1110) 2026-11-06 21:26:08 +01:00
slprime 41c2b96c88 Fix NPE in StackInfo.getItemStackWithMinimumDamage for unregistered items (#1109) 2026-11-05 18:19:48 +02:00
slprime 8e1541eab1 Remove creative tab style option for recipe tabs (#1107) 2026-11-04 16:34:56 +02:00
slprime 9411541fd8 Move RecipeTransferRectHandler out of TemplateRecipeHandler and tidy up PositionedStack (#1106) 2026-11-03 20:35:40 +02:00
slprime ae0d6c6108 Add getResultStacks/getAuxiliaryStacks to IRecipeHandler (#1105) 2026-11-03 17:33:07 +02:00
slprime aea4c2866a Stop auto-creating NEI config files, add export buttons instead (#1104) 2026-11-02 22:20:09 +02:00
slprime c1a525594c Fix ConcurrentModificationException when iterating the crafting recipe list (#1103) 2026-11-02 19:38:18 +02:00
slprimeandMartin Robertz afc8a2380b Remove per-world config override (#1094)
Co-authored-by: Martin Robertz <[email protected]>
2026-11-02 18:20:18 +02:00
slprime a0b2430458 Remove hardcoded vanilla block name overrides (#1102) 2026-11-01 21:53:37 +02:00
Armisael5 4dc6be839b Add NEI Recipe Exporting (#1100) 2026-11-01 15:25:25 +02:00
4 changed files with 28 additions and 7 deletions

No files matched your search

@@ -1073,6 +1073,7 @@ public class BookmarkPanel extends PanelWidget<BookmarkGrid> {
}
this.grid.shiftGroupAmount(groupId, multiplier * shift);
clearTooltips();
return true;
}
}
@@ -1226,6 +1227,8 @@ public class BookmarkPanel extends PanelWidget<BookmarkGrid> {
if (helmStackIndex != -1) {
FastTransferManager.clickSlot(guiContainer, helmStackIndex, 0, 0);
}
clearTooltips();
}
}
@@ -111,6 +111,7 @@ public abstract class GuiRecipe<H extends IRecipeHandler> extends GuiContainer i
private Rectangle pageArea = new Rectangle();
private int lastPage = -1;
private int catalystsVersion = -1;
private final GuiRecipeTabs recipeTabs;
private final GuiRecipeCatalyst recipeCatalyst;
private SearchRecipeHandler<H> handler;
@@ -549,7 +550,11 @@ public abstract class GuiRecipe<H extends IRecipeHandler> extends GuiContainer i
}
}
this.recipeCatalyst.setCatalysts(RecipeCatalysts.getRecipeCatalysts(this.handler.original));
if (this.catalystsVersion != RecipeCatalysts.getVersion()) {
this.catalystsVersion = RecipeCatalysts.getVersion();
this.recipeCatalyst.setCatalysts(RecipeCatalysts.getRecipeCatalysts(this.handler.original));
}
this.container.update();
}
@@ -580,6 +585,8 @@ public abstract class GuiRecipe<H extends IRecipeHandler> extends GuiContainer i
this.recipetype = (this.currenthandlers.size() + idx) % this.currenthandlers.size();
this.handler = new SearchRecipeHandler<>(this.currenthandlers.get(this.recipetype));
this.handlerInfo = GuiRecipeTab.getHandlerInfo(this.handler.original);
this.catalystsVersion = RecipeCatalysts.getVersion();
this.recipeCatalyst.setCatalysts(RecipeCatalysts.getRecipeCatalysts(this.handler.original));
updateContainerSize();
this.handlerPages = new RecipePageManager(this.handler, this.handlerInfo, this.container);
this.prevpage.enabled = this.nextpage.enabled = this.handlerPages.getNumPages() > 1;
@@ -1,6 +1,7 @@
package codechicken.nei.recipe;
import java.util.ArrayList;
import java.util.Collections;
import java.util.List;
import org.lwjgl.opengl.GL11;
@@ -71,21 +72,22 @@ public class GuiRecipeCatalyst extends ScrollContainer {
.setOverflowType(ScrollBar.OverflowType.AUTO).setTrackPadding(0, BORDER_PADDING, -13, BORDER_PADDING)
.setScrollPlace(ScrollBar.ScrollPlace.START);
private PositionedStack[] items = new PositionedStack[0];
private List<PositionedStack> items = Collections.emptyList();
private boolean showWidget = false;
private int availableHeight = 0;
private int style = -1;
public GuiRecipeCatalyst() {
setPaddingBlock(BORDER_PADDING + 1, BORDER_PADDING + 1);
}
public void setCatalysts(List<PositionedStack> items) {
this.items = items.toArray(new PositionedStack[0]);
this.items = items;
createWidgets();
}
public void setAvailableHeight(int height) {
if (this.availableHeight != height) {
if (this.availableHeight != height || this.style != NEIClientConfig.getJEIStyleRecipeCatalysts()) {
this.availableHeight = height;
createWidgets();
}
@@ -102,14 +104,14 @@ public class GuiRecipeCatalyst extends ScrollContainer {
public int getColumnCount() {
if (NEIClientConfig.getJEIStyleRecipeCatalysts() == 1) {
final int maxItemsPerColumn = Math.max(0, this.availableHeight - 2 - BORDER_PADDING * 2) / SLOT_SIZE;
return maxItemsPerColumn > 0 ? NEIServerUtils.divideCeil(this.items.length, maxItemsPerColumn) : 0;
return maxItemsPerColumn > 0 ? NEIServerUtils.divideCeil(this.items.size(), maxItemsPerColumn) : 0;
}
return 1;
}
public int getRowCount() {
final int columnCount = getColumnCount();
return columnCount > 0 ? NEIServerUtils.divideCeil(this.items.length, columnCount) : 0;
return columnCount > 0 ? NEIServerUtils.divideCeil(this.items.size(), columnCount) : 0;
}
protected void createWidgets() {
@@ -119,10 +121,11 @@ public class GuiRecipeCatalyst extends ScrollContainer {
setVerticalScroll(null);
setPaddingInline(BORDER_PADDING + 1, BORDER_PADDING - 3);
this.style = NEIClientConfig.getJEIStyleRecipeCatalysts();
this.h = rows * SLOT_SIZE + this.paddingBlockStart + this.paddingBlockEnd;
this.w = columns * SLOT_SIZE + this.paddingInlineStart + this.paddingInlineEnd;
if (NEIClientConfig.getJEIStyleRecipeCatalysts() == 2
if (this.style == 2
&& rows * SLOT_SIZE + this.paddingBlockStart + this.paddingBlockEnd > this.availableHeight) {
this.h = Math.min(this.h, this.availableHeight);
this.w += VERTICAL_SCROLLBAR.getTrackWidth();
@@ -134,6 +137,7 @@ public class GuiRecipeCatalyst extends ScrollContainer {
this.showWidget = rows * columns > 0;
if (rows == 0 || columns == 0) {
clear();
return;
}
@@ -36,6 +36,11 @@ public class RecipeCatalysts {
public static final Map<String, List<ItemStack>> catalystsRemoverFromIMC = new HashMap<>();
private static final Map<String, List<PositionedStack>> recipeCatalystMap = new HashMap<>();
private static final List<String> forceClassNameList = new ArrayList<>();
private static int version = 0;
public static int getVersion() {
return version;
}
public static void addRecipeCatalyst(String handlerID, CatalystInfo catalystInfo) {
if (handlerID == null || handlerID.isEmpty() || catalystInfo.getStack() == null) return;
@@ -69,6 +74,7 @@ public class RecipeCatalysts {
if (handlerID == null || handlerID.isEmpty()) return;
catalystsAdderFromAPI.put(handlerID, catalystInfoList);
recipeCatalystMap.put(handlerID, convertToPositionedStackList(catalystInfoList));
version++;
}
public static List<PositionedStack> getRecipeCatalysts(IRecipeHandler handler) {
@@ -176,6 +182,7 @@ public class RecipeCatalysts {
recipeCatalystMap.put(entry.getKey(), convertToPositionedStackList(entry.getValue()));
}
version++;
}
private static void resolveAdderQueue(Map<String, CatalystInfoList> recipeCatalystMap) {