This commit is contained in:
gnembon committed 2020-12-14 02:51:01 -04:00
1 parent 50a0e4b886
commit 00ad9eccc7
5 files changed
+6 -6

No files matched your search

+1 -1
View File
@@ -5,7 +5,7 @@ org.gradle.jvmargs=-Xmx1G
# check these on https://fabricmc.net/use # check these on https://fabricmc.net/use
# or better: https://modmuss50.me/fabric.html # or better: https://modmuss50.me/fabric.html
minecraft_version=20w49a minecraft_version=20w49a
yarn_mappings=20w49a+build.1 yarn_mappings=20w49a+build.8
loader_version=0.10.8 loader_version=0.10.8
# Mod Properties # Mod Properties
@@ -35,12 +35,12 @@ public class InventoryHelper
changed = true; changed = true;
} }
if (bet.method_33133()) // isEmpty if (bet.isEmpty())
{ {
tag.remove("BlockEntityTag"); tag.remove("BlockEntityTag");
changed = true; changed = true;
} }
if (tag.method_33133()) if (tag.isEmpty())
{ {
stack.setTag(null); stack.setTag(null);
changed = true; changed = true;
@@ -27,7 +27,7 @@ public abstract class ContainerMixin
@Shadow @Final public DefaultedList<Slot> slots; @Shadow @Final public DefaultedList<Slot> slots;
@Inject( method = "method_30010", at = @At(value = "HEAD"), cancellable = true) // on slot click @Inject( method = "removeStack", at = @At(value = "HEAD"), cancellable = true)
private void onThrowClick( int slotId, int clickData, SlotActionType actionType, PlayerEntity playerEntity, CallbackInfoReturnable<ItemStack> cir) private void onThrowClick( int slotId, int clickData, SlotActionType actionType, PlayerEntity playerEntity, CallbackInfoReturnable<ItemStack> cir)
{ {
if (actionType == SlotActionType.THROW && CarpetSettings.ctrlQCraftingFix && playerEntity.getInventory().getCursorStack().isEmpty() && slotId >= 0) if (actionType == SlotActionType.THROW && CarpetSettings.ctrlQCraftingFix && playerEntity.getInventory().getCursorStack().isEmpty() && slotId >= 0)
@@ -108,7 +108,7 @@ public class BlockValue extends Value
{ {
if (data != null) if (data != null)
{ {
if (data.method_33133()) if (data.isEmpty())
return null; return null;
return data; return data;
} }
@@ -392,7 +392,7 @@ public class NBTSerializableValue extends Value implements ContainerValueInterfa
{ {
Tag tag = getTag(); Tag tag = getTag();
if (tag instanceof CompoundTag) if (tag instanceof CompoundTag)
return !((CompoundTag) tag).method_33133(); return !((CompoundTag) tag).isEmpty();
if (tag instanceof AbstractListTag) if (tag instanceof AbstractListTag)
return ((AbstractListTag) tag).isEmpty(); return ((AbstractListTag) tag).isEmpty();
if (tag instanceof AbstractNumberTag) if (tag instanceof AbstractNumberTag)