Feature: #0675 - Drag'n'Drop functionality when making patterns
Fixed a bug where pattern would not properly re-populate the pattern terminal when they were re-inserted. Shift clicking into the inscriber is more intelligent.
This commit is contained in:
@@ -4,6 +4,7 @@ import net.minecraft.entity.player.EntityPlayer;
|
||||
import net.minecraft.inventory.IInventory;
|
||||
import net.minecraft.inventory.Slot;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import appeng.container.AEBaseContainer;
|
||||
import appeng.tile.inventory.AppEngInternalInventory;
|
||||
|
||||
public class AppEngSlot extends Slot
|
||||
@@ -16,6 +17,7 @@ public class AppEngSlot extends Slot
|
||||
|
||||
public boolean isDraggable = true;
|
||||
public boolean isPlayerSide = false;
|
||||
public AEBaseContainer myContainer = null;
|
||||
|
||||
public Slot setNotDraggable()
|
||||
{
|
||||
@@ -90,7 +92,12 @@ public class AppEngSlot extends Slot
|
||||
public void putStack(ItemStack par1ItemStack)
|
||||
{
|
||||
if ( isEnabled() )
|
||||
{
|
||||
super.putStack( par1ItemStack );
|
||||
|
||||
if ( myContainer != null )
|
||||
myContainer.onSlotChange( this );
|
||||
}
|
||||
}
|
||||
|
||||
public void clearStack()
|
||||
@@ -139,4 +146,9 @@ public class AppEngSlot extends Slot
|
||||
return isPlayerSide;
|
||||
}
|
||||
|
||||
public boolean shouldDisplay()
|
||||
{
|
||||
return isEnabled();
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user