mirror of
https://github.com/GTNewHorizons/TinkersConstruct.git
synced 2026-11-22 05:02:39 +00:00
Change StencilTable from hardcoded patterns to a flexible system
This commit is contained in:
1 parent
49764fd251
commit
5dd0e0c8fa
4 files changed
+92
-36
No files matched your search
@@ -7,6 +7,7 @@ import net.minecraft.inventory.ISidedInventory;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.util.StatCollector;
|
||||
import net.minecraft.world.World;
|
||||
import tconstruct.library.crafting.StencilBuilder;
|
||||
import tconstruct.tools.TinkerTools;
|
||||
import tconstruct.tools.inventory.PatternShaperContainer;
|
||||
|
||||
@@ -47,12 +48,9 @@ public class StencilTableLogic extends InventoryLogic implements ISidedInventory
|
||||
public void setInventorySlotContents (int slot, ItemStack itemstack)
|
||||
{
|
||||
super.setInventorySlotContents(slot, itemstack);
|
||||
if (slot == 0 && itemstack != null && itemstack.getItem() == TinkerTools.blankPattern)//instanceof tconstruct.items.Pattern)
|
||||
if (slot == 0 && itemstack != null && StencilBuilder.isBlank(itemstack))
|
||||
{
|
||||
if (itemstack.getItemDamage() == 0)
|
||||
setInventorySlotContents(1, new ItemStack(TinkerTools.woodPattern, 1, 1));
|
||||
/*else if (itemstack.getItemDamage() == 1)
|
||||
setInventorySlotContents(1, new ItemStack(TContent.metalPattern, 1, 0));*/
|
||||
setInventorySlotContents(1, new ItemStack(TinkerTools.woodPattern, 1, 1));
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user