Compare commits

...
Author SHA1 Message Date
Martin Robertz 3d5e9aecf0 update 2025-06-08 11:59:07 +02:00
FalsePattern 07cec30f3e allow setOverrideName to remove name overrides (#643) 2025-06-06 14:11:33 +00:00
koolkrafter5 f3add01e74 Too Many (Hidden) Items (#641) 2025-06-03 08:26:44 +02:00
Maya d469fdc90d update 2025-06-01 18:05:04 -06:00
abel1502 763d9b8cd4 Fix Incorrect handleDragNDrop Implementation (#639) 2025-06-01 18:04:55 -06:00
4 changed files with 14 additions and 8 deletions

No files matched your search

+2 -2
View File
@@ -1,8 +1,8 @@
// Add your dependencies here
dependencies {
api('com.github.GTNewHorizons:CodeChickenCore:1.4.2:dev')
implementation('com.github.GTNewHorizons:GTNHLib:0.6.24:dev')
api('com.github.GTNewHorizons:CodeChickenCore:1.4.3:dev')
implementation('com.github.GTNewHorizons:GTNHLib:0.6.30:dev')
shadowImplementation('org.apache.commons:commons-csv:1.10.0')
+8 -2
View File
@@ -3,6 +3,7 @@ package codechicken.nei.api;
import java.util.Collections;
import java.util.Comparator;
import java.util.List;
import java.util.Objects;
import net.minecraft.block.Block;
import net.minecraft.client.gui.inventory.GuiContainer;
@@ -164,8 +165,13 @@ public class API {
* Add or replace the name normally shown on the item tooltip
*/
public static void setOverrideName(ItemStack item, String name) {
if (!name.equals(ItemInfo.nameOverrides.get(item))) {
ItemInfo.nameOverrides.put(item, name);
String existing = ItemInfo.nameOverrides.get(item);
if (!Objects.equals(name, existing)) {
if (name == null) {
ItemInfo.nameOverrides.remove(item);
} else {
ItemInfo.nameOverrides.put(item, name);
}
LayoutManager.markItemsDirty();
}
}
@@ -36,11 +36,10 @@ public class CheatItemHandler extends INEIGuiAdapter {
draggedStack.stackSize -= total - contents;
}
return true;
} else {
draggedStack.stackSize = 0;
}
return true;
}
return false;
@@ -16,8 +16,9 @@
#
minecraft:portal
minecraft:end_portal
minecraft:fire
minecraft:lava
r/minecraft:fire$/
r/minecraft:water$/
r/minecraft:lava$/
minecraft:mob_spawner
minecraft:anvil !0
minecraft:flowing_water