This commit is contained in:
gnembon committed 2020-01-27 23:30:31 -04:00
1 parent 26a038041e
commit bd637d5d6b
3 files changed
+6 -6

No files matched your search

+2 -2
View File
@@ -5,8 +5,8 @@ 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=1.15.2 minecraft_version=1.15.2
yarn_mappings=1.15.2+build.1 yarn_mappings=1.15.2+build.7
loader_version=0.7.5+build.178 loader_version=0.7.6+build.180
# Mod Properties # Mod Properties
mod_version = 1.3.7+v200127 mod_version = 1.3.7+v200127
@@ -19,7 +19,7 @@ import java.util.List;
@Mixin(Container.class) @Mixin(Container.class)
public abstract class ContainerMixin public abstract class ContainerMixin
{ {
@Shadow @Final public List<Slot> slotList; @Shadow @Final public List<Slot> slots;
@Shadow public abstract ItemStack onSlotClick(int int_1, int int_2, SlotActionType slotActionType_1, PlayerEntity playerEntity_1); @Shadow public abstract ItemStack onSlotClick(int int_1, int int_2, SlotActionType slotActionType_1, PlayerEntity playerEntity_1);
@@ -31,7 +31,7 @@ public abstract class ContainerMixin
if (actionType == SlotActionType.THROW && CarpetSettings.ctrlQCraftingFix && playerEntity.inventory.getCursorStack().isEmpty() && slotId >= 0) if (actionType == SlotActionType.THROW && CarpetSettings.ctrlQCraftingFix && playerEntity.inventory.getCursorStack().isEmpty() && slotId >= 0)
{ {
ItemStack itemStack_1 = ItemStack.EMPTY; ItemStack itemStack_1 = ItemStack.EMPTY;
Slot slot_4 = slotList.get(slotId); Slot slot_4 = slots.get(slotId);
if (slot_4 != null && slot_4.hasStack() && slot_4.canTakeItems(playerEntity)) if (slot_4 != null && slot_4.hasStack() && slot_4.canTakeItems(playerEntity))
{ {
if(slotId == 0 && clickData == 1) if(slotId == 0 && clickData == 1)
@@ -43,7 +43,7 @@ import net.minecraft.block.CommandBlock;
import net.minecraft.block.JigsawBlock; import net.minecraft.block.JigsawBlock;
import net.minecraft.block.StructureBlock; import net.minecraft.block.StructureBlock;
import net.minecraft.block.entity.BlockEntity; import net.minecraft.block.entity.BlockEntity;
import net.minecraft.client.network.packet.GuiSlotUpdateS2CPacket; import net.minecraft.client.network.packet.ContainerSlotUpdateS2CPacket;
import net.minecraft.client.network.packet.PlaySoundIdS2CPacket; import net.minecraft.client.network.packet.PlaySoundIdS2CPacket;
import net.minecraft.command.arguments.ItemStackArgument; import net.minecraft.command.arguments.ItemStackArgument;
import net.minecraft.command.arguments.ParticleArgumentType; import net.minecraft.command.arguments.ParticleArgumentType;
@@ -1890,7 +1890,7 @@ public class CarpetExpression
if (inventory.owner instanceof ServerPlayerEntity && !inventory.isEnder) if (inventory.owner instanceof ServerPlayerEntity && !inventory.isEnder)
{ {
ServerPlayerEntity player = (ServerPlayerEntity) inventory.owner; ServerPlayerEntity player = (ServerPlayerEntity) inventory.owner;
player.networkHandler.sendPacket(new GuiSlotUpdateS2CPacket( player.networkHandler.sendPacket(new ContainerSlotUpdateS2CPacket(
-2, -2,
int_1, int_1,
inventory.inventory.getInvStack(int_1) inventory.inventory.getInvStack(int_1)