Merge 08e7319e5c into c4d5a5631f
|
|
@ -6,97 +6,90 @@
|
||||||
******************************************************************************/
|
******************************************************************************/
|
||||||
package cpw.mods.ironchest;
|
package cpw.mods.ironchest;
|
||||||
|
|
||||||
import static cpw.mods.ironchest.IronChestType.COPPER;
|
import static cpw.mods.ironchest.IronChestTypeSimple.COPPER;
|
||||||
import static cpw.mods.ironchest.IronChestType.CRYSTAL;
|
import static cpw.mods.ironchest.IronChestTypeSimple.CRYSTAL;
|
||||||
import static cpw.mods.ironchest.IronChestType.DIAMOND;
|
import static cpw.mods.ironchest.IronChestTypeSimple.DIAMOND;
|
||||||
import static cpw.mods.ironchest.IronChestType.GOLD;
|
import static cpw.mods.ironchest.IronChestTypeSimple.GOLD;
|
||||||
import static cpw.mods.ironchest.IronChestType.IRON;
|
import static cpw.mods.ironchest.IronChestTypeSimple.IRON;
|
||||||
import static cpw.mods.ironchest.IronChestType.OBSIDIAN;
|
import static cpw.mods.ironchest.IronChestTypeSimple.OBSIDIAN;
|
||||||
import static cpw.mods.ironchest.IronChestType.SILVER;
|
import static cpw.mods.ironchest.IronChestTypeSimple.SILVER;
|
||||||
import static cpw.mods.ironchest.IronChestType.WOOD;
|
import static cpw.mods.ironchest.IronChestTypeSimple.WOOD;
|
||||||
import net.minecraft.init.Blocks;
|
import net.minecraft.init.Blocks;
|
||||||
import net.minecraft.item.ItemStack;
|
import net.minecraft.item.ItemStack;
|
||||||
import net.minecraftforge.fml.common.FMLCommonHandler;
|
import net.minecraftforge.fml.common.FMLCommonHandler;
|
||||||
import net.minecraftforge.fml.common.registry.GameRegistry;
|
import net.minecraftforge.fml.common.registry.GameRegistry;
|
||||||
import cpw.mods.ironchest.client.ModelHelper;
|
|
||||||
import net.minecraftforge.fml.relauncher.Side;
|
import net.minecraftforge.fml.relauncher.Side;
|
||||||
|
import cpw.mods.ironchest.client.ModelHelper;
|
||||||
|
|
||||||
public enum ChestChangerType {
|
public enum ChestChangerType {
|
||||||
IRONGOLD(IRON, GOLD, "ironGoldUpgrade", "Iron to Gold Chest Upgrade", "mmm", "msm", "mmm"),
|
WOOD_UPGRADE(WOOD, new IronChestTypeSimple[] {IRON, GOLD, DIAMOND, OBSIDIAN}, "woodUpgrade", new String[][] {{"ttt", "tst", "ttt"}, {"ttt", "tst", "ttt"}, {"GGG", "tst", "GGG"}, {"tst", "tGt", "ttt"}}),
|
||||||
GOLDDIAMOND(GOLD, DIAMOND, "goldDiamondUpgrade", "Gold to Diamond Chest Upgrade", "GGG", "msm", "GGG"),
|
IRON_UPGRADE(IRON, new IronChestTypeSimple[] {GOLD, DIAMOND, OBSIDIAN}, "ironUpgrade", new String[][] {{"ttt", "tst", "ttt"}, {"GGG", "tst", "GGG"}, {"tst", "tGt", "ttt"}}),
|
||||||
COPPERSILVER(COPPER, SILVER, "copperSilverUpgrade", "Copper to Silver Chest Upgrade", "mmm", "msm", "mmm"),
|
GOLD_UPGRADE(GOLD, new IronChestTypeSimple[] {DIAMOND, OBSIDIAN}, "goldUpgrade", new String[][] {{"GGG", "tst", "GGG"}, {"tst", "tGt", "ttt"}}),
|
||||||
SILVERGOLD(SILVER, GOLD, "silverGoldUpgrade", "Silver to Gold Chest Upgrade", "mGm", "GsG", "mGm"),
|
DIAMOND_OBSIDIAN_UPGRADE(DIAMOND, new IronChestTypeSimple[] {OBSIDIAN}, "diamondObsidianUpgrade", new String[][] {{"tst", "tGt", "ttt"}}),
|
||||||
COPPERIRON(COPPER, IRON, "copperIronUpgrade", "Copper to Iron Chest Upgrade", "mGm", "GsG", "mGm"),
|
DIAMOND_CRYSTAL_UPGRADE(DIAMOND, new IronChestTypeSimple[] {CRYSTAL}, "diamondCrystalUpgrade", new String[][] {{"GsG", "GOG", "GGG"}}),
|
||||||
DIAMONDCRYSTAL(DIAMOND, CRYSTAL, "diamondCrystalUpgrade", "Diamond to Crystal Chest Upgrade", "GGG", "GOG", "GGG"),
|
COPPER_UPGRADE(COPPER, new IronChestTypeSimple[] {IRON, GOLD, DIAMOND, OBSIDIAN}, "copperUpgrade", new String[][] {{"tGt", "GsG", "tGt"}, {"ttt", "tst", "ttt"}, {"GGG", "tst", "GGG"}, {"tst", "tGt", "ttt"}}),
|
||||||
WOODIRON(WOOD, IRON, "woodIronUpgrade", "Normal chest to Iron Chest Upgrade", "mmm", "msm", "mmm"),
|
SILVER_UPGRADE(SILVER, new IronChestTypeSimple[] {GOLD, DIAMOND, OBSIDIAN}, "silverUpgrade", new String[][] {{"tGt", "GsG", "tGt"}, {"GGG", "tst", "GGG"}, {"tst", "tGt", "ttt"}});
|
||||||
WOODCOPPER(WOOD, COPPER, "woodCopperUpgrade", "Normal chest to Copper Chest Upgrade", "mmm", "msm", "mmm"),
|
|
||||||
DIAMONDOBSIDIAN(DIAMOND, OBSIDIAN, "diamondObsidianUpgrade", "Diamond to Obsidian Chest Upgrade", "mmm", "mGm", "mmm");
|
private IronChestTypeSimple source;
|
||||||
|
IronChestTypeSimple[] upgradeChain;
|
||||||
private IronChestType source;
|
public ItemChestChanger item;
|
||||||
private IronChestType target;
|
public String itemName;
|
||||||
public String itemName;
|
private String[][] recipe;
|
||||||
public String descriptiveName;
|
|
||||||
public ItemChestChanger item;
|
private ChestChangerType(IronChestTypeSimple source, IronChestTypeSimple[] upgradeChain, String itemName, String[][] recipes) {
|
||||||
private String[] recipe;
|
this.source = source;
|
||||||
|
this.upgradeChain = upgradeChain;
|
||||||
private ChestChangerType(IronChestType source, IronChestType target, String itemName, String descriptiveName, String... recipe)
|
this.itemName = itemName;
|
||||||
{
|
this.recipe = recipes;
|
||||||
this.source = source;
|
}
|
||||||
this.target = target;
|
|
||||||
this.itemName = itemName;
|
public IronChestTypeSimple getSource() {
|
||||||
this.descriptiveName = descriptiveName;
|
return source;
|
||||||
this.recipe = recipe;
|
}
|
||||||
}
|
|
||||||
|
public boolean canUpgrade(IronChestTypeSimple from) {
|
||||||
public IronChestType getSource(){
|
return from == this.source;
|
||||||
return source;
|
}
|
||||||
}
|
|
||||||
|
public int getTarget(int meta) {
|
||||||
public boolean canUpgrade(IronChestType from)
|
return this.upgradeChain[meta].ordinal();
|
||||||
{
|
}
|
||||||
return from == this.source;
|
|
||||||
}
|
public String getTargetName(int meta) {
|
||||||
|
return this.upgradeChain[meta].getName();
|
||||||
public int getTarget()
|
}
|
||||||
{
|
|
||||||
return this.target.ordinal();
|
public ItemChestChanger buildItem() {
|
||||||
}
|
item = new ItemChestChanger(this);
|
||||||
|
GameRegistry.registerItem(item, itemName);
|
||||||
public ItemChestChanger buildItem()
|
if (FMLCommonHandler.instance().getEffectiveSide() == Side.CLIENT) {
|
||||||
{
|
for (int i = 0; i < this.upgradeChain.length; i ++) {
|
||||||
item = new ItemChestChanger(this);
|
String targetName = this.upgradeChain[i].getName().substring(0, 1).toUpperCase() + this.upgradeChain[i].getName().substring(1);
|
||||||
GameRegistry.registerItem(item, itemName);
|
ModelHelper.registerItem(item, i, itemName + targetName);
|
||||||
if(FMLCommonHandler.instance().getEffectiveSide() == Side.CLIENT)
|
}
|
||||||
ModelHelper.registerItem(item, "ironchest:" + itemName);
|
}
|
||||||
return item;
|
return item;
|
||||||
}
|
}
|
||||||
|
|
||||||
public void addRecipes()
|
public void addRecipes() {
|
||||||
{
|
Object sourceMaterial = this.source.toObject();
|
||||||
for (String sourceMat : source.getMatList())
|
Object targetMaterial = this.upgradeChain[0].toObject();
|
||||||
{
|
IronChestType.addRecipe(new ItemStack(item), recipe[0], 's', sourceMaterial, 't', targetMaterial, 'G', "blockGlass", 'O', Blocks.obsidian);
|
||||||
for (String targetMat : target.getMatList())
|
for (int i = 1; i < this.upgradeChain.length; i ++) {
|
||||||
{
|
targetMaterial = this.upgradeChain[i].toObject();
|
||||||
Object targetMaterial = IronChestType.translateOreName(targetMat);
|
IronChestType.addRecipe(new ItemStack(item, 1, i), recipe[i], 's', new ItemStack(this.item, 1, i - 1), 't', targetMaterial, 'G', "blockGlass", 'O', Blocks.obsidian);
|
||||||
Object sourceMaterial = IronChestType.translateOreName(sourceMat);
|
}
|
||||||
IronChestType.addRecipe(new ItemStack(item), recipe, 'm', targetMaterial, 's', sourceMaterial, 'G', "blockGlass", 'O', Blocks.obsidian);
|
}
|
||||||
}
|
|
||||||
}
|
public static void buildItems() {
|
||||||
}
|
for (ChestChangerType type : values()) {
|
||||||
|
type.buildItem();
|
||||||
public static void buildItems()
|
}
|
||||||
{
|
}
|
||||||
for (ChestChangerType type : values())
|
|
||||||
{
|
public static void generateRecipes() {
|
||||||
type.buildItem();
|
for (ChestChangerType item : values()) {
|
||||||
}
|
item.addRecipes();
|
||||||
}
|
}
|
||||||
|
}
|
||||||
public static void generateRecipes()
|
|
||||||
{
|
|
||||||
for (ChestChangerType item : values())
|
|
||||||
{
|
|
||||||
item.addRecipes();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -10,14 +10,7 @@
|
||||||
******************************************************************************/
|
******************************************************************************/
|
||||||
package cpw.mods.ironchest;
|
package cpw.mods.ironchest;
|
||||||
|
|
||||||
import io.netty.buffer.ByteBuf;
|
|
||||||
import net.minecraft.client.renderer.entity.Render;
|
|
||||||
import net.minecraft.client.renderer.entity.RenderFireball;
|
|
||||||
import net.minecraft.client.renderer.entity.RenderManager;
|
|
||||||
import net.minecraft.entity.projectile.EntitySmallFireball;
|
|
||||||
import net.minecraftforge.common.MinecraftForge;
|
import net.minecraftforge.common.MinecraftForge;
|
||||||
import net.minecraftforge.fml.client.registry.IRenderFactory;
|
|
||||||
import net.minecraftforge.fml.client.registry.RenderingRegistry;
|
|
||||||
import net.minecraftforge.fml.common.Mod;
|
import net.minecraftforge.fml.common.Mod;
|
||||||
import net.minecraftforge.fml.common.Mod.EventHandler;
|
import net.minecraftforge.fml.common.Mod.EventHandler;
|
||||||
import net.minecraftforge.fml.common.Mod.Instance;
|
import net.minecraftforge.fml.common.Mod.Instance;
|
||||||
|
|
@ -25,12 +18,7 @@ import net.minecraftforge.fml.common.SidedProxy;
|
||||||
import net.minecraftforge.fml.common.event.FMLInitializationEvent;
|
import net.minecraftforge.fml.common.event.FMLInitializationEvent;
|
||||||
import net.minecraftforge.fml.common.event.FMLPreInitializationEvent;
|
import net.minecraftforge.fml.common.event.FMLPreInitializationEvent;
|
||||||
import net.minecraftforge.fml.common.network.NetworkRegistry;
|
import net.minecraftforge.fml.common.network.NetworkRegistry;
|
||||||
import net.minecraftforge.fml.common.network.simpleimpl.IMessage;
|
|
||||||
import net.minecraftforge.fml.common.network.simpleimpl.IMessageHandler;
|
|
||||||
import net.minecraftforge.fml.common.network.simpleimpl.MessageContext;
|
|
||||||
import net.minecraftforge.fml.common.network.simpleimpl.SimpleNetworkWrapper;
|
|
||||||
import net.minecraftforge.fml.common.registry.GameRegistry;
|
import net.minecraftforge.fml.common.registry.GameRegistry;
|
||||||
import net.minecraftforge.fml.relauncher.Side;
|
|
||||||
|
|
||||||
@Mod(modid = "IronChest", name = "Iron Chests", dependencies = "required-after:Forge@[11.15.0,12.0]", acceptedMinecraftVersions="[1.8,1.8.9]")
|
@Mod(modid = "IronChest", name = "Iron Chests", dependencies = "required-after:Forge@[11.15.0,12.0]", acceptedMinecraftVersions="[1.8,1.8.9]")
|
||||||
public class IronChest
|
public class IronChest
|
||||||
|
|
|
||||||
|
|
@ -26,18 +26,19 @@ import net.minecraftforge.oredict.ShapedOreRecipe;
|
||||||
|
|
||||||
public enum IronChestType implements IStringSerializable
|
public enum IronChestType implements IStringSerializable
|
||||||
{
|
{
|
||||||
IRON(54, 9, true, "Iron Chest", "ironchest.png", 0, Arrays.asList("ingotIron", "ingotRefinedIron"), TileEntityIronChest.class, "mmmmPmmmm", "mGmG3GmGm"),
|
IRON(54, 9, true, "Iron Chest", "ironchest.png", 0, Arrays.asList("ingotIron", "ingotRefinedIron"), TileEntityIronChest.class, "mmmmPmmmm", "mGmG3GmGm"),
|
||||||
GOLD(81, 9, true, "Gold Chest", "goldchest.png", 1, Arrays.asList("ingotGold"), TileEntityGoldChest.class, "mmmmPmmmm", "mGmG4GmGm"),
|
GOLD(81, 9, true, "Gold Chest", "goldchest.png", 1, Arrays.asList("ingotGold"), TileEntityGoldChest.class, "mmmmPmmmm", "mGmG4GmGm"),
|
||||||
DIAMOND(108, 12, true, "Diamond Chest", "diamondchest.png", 2, Arrays.asList("gemDiamond"), TileEntityDiamondChest.class, "GGGmPmGGG", "GGGG4Gmmm"),
|
DIAMOND(108, 12, true, "Diamond Chest", "diamondchest.png", 2, Arrays.asList("gemDiamond"), TileEntityDiamondChest.class, "GGGmPmGGG", "GGGG4Gmmm"),
|
||||||
COPPER(45, 9, false, "Copper Chest", "copperchest.png", 3, Arrays.asList("ingotCopper"), TileEntityCopperChest.class, "mmmmCmmmm"),
|
COPPER(45, 9, false, "Copper Chest", "copperchest.png", 3, Arrays.asList("ingotCopper"), TileEntityCopperChest.class, "mmmmCmmmm"),
|
||||||
SILVER(72, 9, false, "Silver Chest", "silverchest.png", 4, Arrays.asList("ingotSilver"), TileEntitySilverChest.class, "mmmm3mmmm", "mGmG0GmGm"),
|
SILVER(72, 9, false, "Silver Chest", "silverchest.png", 4, Arrays.asList("ingotSilver"), TileEntitySilverChest.class, "mmmm3mmmm", "mGmG0GmGm"),
|
||||||
CRYSTAL(108, 12, true, "Crystal Chest", "crystalchest.png", 5, Arrays.asList("blockGlass"), TileEntityCrystalChest.class, "GGGGPGGGG"),
|
CRYSTAL(108, 12, true, "Crystal Chest", "crystalchest.png", 5, Arrays.asList("blockGlass"), TileEntityCrystalChest.class, "GGGGPGGGG"),
|
||||||
OBSIDIAN(108, 12, false, "Obsidian Chest", "obsidianchest.png", 6, Arrays.asList("obsidian"), TileEntityObsidianChest.class, "mmmm2mmmm"),
|
OBSIDIAN(108, 12, false, "Obsidian Chest", "obsidianchest.png", 6, Arrays.asList("obsidian"), TileEntityObsidianChest.class, "mmmm2mmmm"),
|
||||||
DIRTCHEST9000(1, 1, false, "Dirt Chest 9000", "dirtchest.png",7,Arrays.asList("dirt"), TileEntityDirtChest.class,Item.getItemFromBlock(Blocks.dirt),"mmmmCmmmm"),
|
DIRTCHEST9000(1, 1, false, "Dirt Chest 9000", "dirtchest.png",7,Arrays.asList("dirt"), TileEntityDirtChest.class,Item.getItemFromBlock(Blocks.dirt),"mmmmCmmmm"),
|
||||||
WOOD(0, 0, false, "", "", -1, Arrays.asList("plankWood"), null);
|
WOOD(0, 0, false, "", "", -1, Arrays.asList("plankWood"), null);
|
||||||
int size;
|
int size;
|
||||||
private int rowLength;
|
private int rowLength;
|
||||||
public String friendlyName;
|
public String friendlyName;
|
||||||
|
public String tierName;
|
||||||
private boolean tieredChest;
|
private boolean tieredChest;
|
||||||
private String modelTexture;
|
private String modelTexture;
|
||||||
private int textureRow;
|
private int textureRow;
|
||||||
|
|
@ -58,6 +59,7 @@ public enum IronChestType implements IStringSerializable
|
||||||
this.rowLength = rowLength;
|
this.rowLength = rowLength;
|
||||||
this.tieredChest = tieredChest;
|
this.tieredChest = tieredChest;
|
||||||
this.friendlyName = friendlyName;
|
this.friendlyName = friendlyName;
|
||||||
|
this.tierName = friendlyName.replace(" Chest", "").replace(" 9000", "");
|
||||||
this.modelTexture = modelTexture;
|
this.modelTexture = modelTexture;
|
||||||
this.textureRow = textureRow;
|
this.textureRow = textureRow;
|
||||||
this.clazz = clazz;
|
this.clazz = clazz;
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,33 @@
|
||||||
|
package cpw.mods.ironchest;
|
||||||
|
|
||||||
|
import net.minecraft.init.Blocks;
|
||||||
|
|
||||||
|
|
||||||
|
public enum IronChestTypeSimple {
|
||||||
|
IRON("ingotIron"),
|
||||||
|
GOLD("ingotGold"),
|
||||||
|
DIAMOND("gemDiamond"),
|
||||||
|
COPPER("ingotCopper"),
|
||||||
|
SILVER("ingotSilver"),
|
||||||
|
CRYSTAL("blockGlass"),
|
||||||
|
OBSIDIAN("obsidian"),
|
||||||
|
DIRTCHEST9000("dirt"),
|
||||||
|
WOOD("plankWood");
|
||||||
|
|
||||||
|
private String material;
|
||||||
|
|
||||||
|
IronChestTypeSimple(String material) {
|
||||||
|
this.material = material;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getMaterial() { return this.material; }
|
||||||
|
public Object toObject() {
|
||||||
|
if (this == OBSIDIAN) return Blocks.obsidian;
|
||||||
|
if (this == DIRTCHEST9000) return Blocks.dirt;
|
||||||
|
return this.material;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getName() {
|
||||||
|
return name().toLowerCase();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
@ -10,7 +10,10 @@
|
||||||
******************************************************************************/
|
******************************************************************************/
|
||||||
package cpw.mods.ironchest;
|
package cpw.mods.ironchest;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
import net.minecraft.block.BlockChest;
|
import net.minecraft.block.BlockChest;
|
||||||
|
import net.minecraft.block.state.IBlockState;
|
||||||
import net.minecraft.creativetab.CreativeTabs;
|
import net.minecraft.creativetab.CreativeTabs;
|
||||||
import net.minecraft.entity.player.EntityPlayer;
|
import net.minecraft.entity.player.EntityPlayer;
|
||||||
import net.minecraft.item.Item;
|
import net.minecraft.item.Item;
|
||||||
|
|
@ -20,88 +23,88 @@ import net.minecraft.tileentity.TileEntityChest;
|
||||||
import net.minecraft.util.BlockPos;
|
import net.minecraft.util.BlockPos;
|
||||||
import net.minecraft.util.EnumFacing;
|
import net.minecraft.util.EnumFacing;
|
||||||
import net.minecraft.world.World;
|
import net.minecraft.world.World;
|
||||||
|
import net.minecraftforge.fml.relauncher.Side;
|
||||||
|
import net.minecraftforge.fml.relauncher.SideOnly;
|
||||||
|
|
||||||
public class ItemChestChanger extends Item
|
public class ItemChestChanger extends Item {
|
||||||
{
|
private ChestChangerType type;
|
||||||
private ChestChangerType type;
|
|
||||||
|
public ItemChestChanger(ChestChangerType type) {
|
||||||
public ItemChestChanger(ChestChangerType type)
|
this.type = type;
|
||||||
{
|
|
||||||
this.type = type;
|
this.setHasSubtypes(true);
|
||||||
|
this.setMaxStackSize(1);
|
||||||
this.setMaxStackSize(1);
|
this.setUnlocalizedName("ironchest:" + type.name());
|
||||||
this.setUnlocalizedName("ironchest:" + type.name());
|
this.setCreativeTab(CreativeTabs.tabMisc);
|
||||||
this.setCreativeTab(CreativeTabs.tabMisc);
|
}
|
||||||
}
|
|
||||||
|
@Override public boolean onItemUseFirst(ItemStack stack, EntityPlayer player, World world, BlockPos pos, EnumFacing side, float hitX, float hitY, float hitZ) {
|
||||||
@Override
|
if (world.isRemote) return false;
|
||||||
public boolean onItemUseFirst (ItemStack stack, EntityPlayer player, World world, BlockPos pos, EnumFacing side, float hitX, float hitY, float hitZ)
|
if (this.type.canUpgrade(IronChestTypeSimple.WOOD)) {
|
||||||
{
|
if (!(world.getBlockState(pos).getBlock() instanceof BlockChest)) { return false; }
|
||||||
if (world.isRemote)
|
} else {
|
||||||
return false;
|
if (world.getBlockState(pos) != IronChest.ironChestBlock.getStateFromMeta(IronChestType.valueOf(type.getSource().getName().toUpperCase()).ordinal())) { return false; }
|
||||||
if(this.type.canUpgrade(IronChestType.WOOD)){
|
}
|
||||||
if(!(world.getBlockState(pos).getBlock() instanceof BlockChest)){
|
TileEntity te = world.getTileEntity(pos);
|
||||||
return false;
|
TileEntityIronChest newchest = new TileEntityIronChest();
|
||||||
}
|
ItemStack[] chestContents = new ItemStack[27];
|
||||||
}else{
|
int chestFacing = 0;
|
||||||
if(world.getBlockState(pos) != IronChest.ironChestBlock.getStateFromMeta(IronChestType.valueOf(type.getSource().getName().toUpperCase()).ordinal())){
|
if (te != null) {
|
||||||
return false;
|
if (te instanceof TileEntityIronChest) {
|
||||||
}
|
chestContents = ((TileEntityIronChest) te).chestContents;
|
||||||
}
|
chestFacing = ((TileEntityIronChest) te).getFacing();
|
||||||
TileEntity te = world.getTileEntity(pos);
|
newchest = IronChestType.makeEntity(this.getTargetChestOrdinal(this.type.ordinal(), stack.getItemDamage()));
|
||||||
TileEntityIronChest newchest = new TileEntityIronChest();
|
if (newchest == null) return false;
|
||||||
ItemStack[] chestContents = new ItemStack[27];
|
} else if (te instanceof TileEntityChest) {
|
||||||
if (te != null)
|
IBlockState chestState = world.getBlockState(pos);
|
||||||
{
|
EnumFacing facing = chestState.getValue(BlockChest.FACING);
|
||||||
if (te instanceof TileEntityIronChest)
|
if (facing == EnumFacing.NORTH) chestFacing = 2;
|
||||||
{
|
if (facing == EnumFacing.EAST) chestFacing = 5;
|
||||||
chestContents = ((TileEntityIronChest) te).chestContents;
|
if (facing == EnumFacing.SOUTH) chestFacing = 3;
|
||||||
newchest = IronChestType.makeEntity(this.getTargetChestOrdinal(this.type.ordinal()));
|
if (facing == EnumFacing.WEST) chestFacing = 4;
|
||||||
if (newchest == null)
|
if (((TileEntityChest) te).numPlayersUsing > 0) return false;
|
||||||
return false;
|
if (!getType().canUpgrade(IronChestTypeSimple.WOOD)) return false;
|
||||||
}
|
chestContents = new ItemStack[((TileEntityChest) te).getSizeInventory()];
|
||||||
else if (te instanceof TileEntityChest)
|
for (int i = 0; i < chestContents.length; i ++)
|
||||||
{
|
chestContents[i] = ((TileEntityChest) te).getStackInSlot(i);
|
||||||
if (((TileEntityChest) te).numPlayersUsing > 0)
|
newchest = IronChestType.makeEntity(this.getTargetChestOrdinal(this.type.ordinal(), stack.getItemDamage()));
|
||||||
return false;
|
}
|
||||||
if (!getType().canUpgrade(IronChestType.WOOD))
|
}
|
||||||
return false;
|
|
||||||
chestContents = new ItemStack[((TileEntityChest) te).getSizeInventory()];
|
te.updateContainingBlockInfo();
|
||||||
for (int i = 0; i < chestContents.length; i++)
|
if (te instanceof TileEntityChest) ((TileEntityChest) te).checkForAdjacentChests();
|
||||||
chestContents[i] = ((TileEntityChest) te).getStackInSlot(i);
|
|
||||||
newchest = IronChestType.makeEntity(this.getTargetChestOrdinal(this.type.ordinal()));
|
world.removeTileEntity(pos);
|
||||||
}
|
world.setBlockToAir(pos);
|
||||||
}
|
|
||||||
|
world.setTileEntity(pos, newchest);
|
||||||
te.updateContainingBlockInfo();
|
world.setBlockState(pos, IronChest.ironChestBlock.getStateFromMeta(newchest.getType().ordinal()), 3);
|
||||||
if (te instanceof TileEntityChest)
|
|
||||||
((TileEntityChest) te).checkForAdjacentChests();
|
world.markBlockForUpdate(pos);
|
||||||
|
|
||||||
world.removeTileEntity(pos);
|
TileEntity te2 = world.getTileEntity(pos);
|
||||||
world.setBlockToAir(pos);
|
if (te2 instanceof TileEntityIronChest) {
|
||||||
|
((TileEntityIronChest) te2).setContents(chestContents);
|
||||||
world.setTileEntity(pos, newchest);
|
((TileEntityIronChest) te2).setFacing((byte) chestFacing);
|
||||||
world.setBlockState(pos, IronChest.ironChestBlock.getStateFromMeta(newchest.getType().ordinal()), 3);
|
}
|
||||||
|
|
||||||
world.markBlockForUpdate(pos);
|
stack.stackSize = player.capabilities.isCreativeMode ? stack.stackSize : stack.stackSize - 1;
|
||||||
|
return true;
|
||||||
TileEntity te2 = world.getTileEntity(pos);
|
}
|
||||||
if (te2 instanceof TileEntityIronChest)
|
|
||||||
{
|
@Override @SideOnly(Side.CLIENT) public void getSubItems(Item item, CreativeTabs tab, List<ItemStack> list) {
|
||||||
((TileEntityIronChest) te2).setContents(chestContents);
|
for (int i = 0; i < this.type.upgradeChain.length; i ++) list.add(new ItemStack(item, 1, i));
|
||||||
}
|
}
|
||||||
|
|
||||||
stack.stackSize = player.capabilities.isCreativeMode ? stack.stackSize : stack.stackSize - 1;
|
@Override public String getUnlocalizedName(ItemStack stack) {
|
||||||
return true;
|
return super.getUnlocalizedName(stack) + "_" + this.type.getTargetName(stack.getItemDamage()).toUpperCase();
|
||||||
}
|
}
|
||||||
|
|
||||||
public int getTargetChestOrdinal(int sourceOrdinal)
|
public int getTargetChestOrdinal(int sourceOrdinal, int meta) {
|
||||||
{
|
return type.getTarget(meta);
|
||||||
return type.getTarget();
|
}
|
||||||
}
|
|
||||||
|
public ChestChangerType getType() {
|
||||||
public ChestChangerType getType()
|
return type;
|
||||||
{
|
}
|
||||||
return type;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -10,35 +10,41 @@
|
||||||
******************************************************************************/
|
******************************************************************************/
|
||||||
package cpw.mods.ironchest.client;
|
package cpw.mods.ironchest.client;
|
||||||
|
|
||||||
import net.minecraft.block.Block;
|
import java.util.ArrayList;
|
||||||
|
|
||||||
import net.minecraft.client.Minecraft;
|
import net.minecraft.client.Minecraft;
|
||||||
import net.minecraft.client.renderer.ItemModelMesher;
|
import net.minecraft.client.renderer.ItemModelMesher;
|
||||||
|
import net.minecraft.client.resources.model.ModelBakery;
|
||||||
import net.minecraft.client.resources.model.ModelResourceLocation;
|
import net.minecraft.client.resources.model.ModelResourceLocation;
|
||||||
import net.minecraft.item.Item;
|
import net.minecraft.item.Item;
|
||||||
|
import net.minecraft.util.ResourceLocation;
|
||||||
import net.minecraftforge.fml.relauncher.Side;
|
import net.minecraftforge.fml.relauncher.Side;
|
||||||
import net.minecraftforge.fml.relauncher.SideOnly;
|
import net.minecraftforge.fml.relauncher.SideOnly;
|
||||||
|
|
||||||
@SideOnly(Side.CLIENT)
|
@SideOnly(Side.CLIENT)
|
||||||
public class ModelHelper
|
public class ModelHelper {
|
||||||
{
|
public static void registerItemInternal(Item item, String[] registryNames, int[] registryMetas) {
|
||||||
public static void registerItem(Item item, int metadata, String itemName)
|
if (registryNames.length != registryMetas.length) { return; }
|
||||||
{
|
ItemModelMesher mesher = Minecraft.getMinecraft().getRenderItem().getItemModelMesher();
|
||||||
ItemModelMesher mesher = Minecraft.getMinecraft().getRenderItem().getItemModelMesher();
|
for (int i = 0; i < registryNames.length; i ++) {
|
||||||
mesher.register(item, metadata, new ModelResourceLocation(itemName, "inventory"));
|
mesher.register(item, registryMetas[i], new ModelResourceLocation("ironchest:" + registryNames[i], "inventory"));
|
||||||
}
|
}
|
||||||
|
}
|
||||||
public static void registerBlock(Block block, int metadata, String blockName)
|
|
||||||
{
|
public static void registerItem(Item item, String[] registryNames, int[] registryMetas) {
|
||||||
registerItem(Item.getItemFromBlock(block), metadata, blockName);
|
ModelBakery.registerItemVariants(item, generateVariants(registryNames));
|
||||||
}
|
registerItemInternal(item, registryNames, registryMetas);
|
||||||
|
}
|
||||||
public static void registerBlock(Block block, String blockName)
|
|
||||||
{
|
public static void registerItem(Item item, int meta, String registryName) {
|
||||||
registerBlock(block, 0, blockName);
|
registerItem(item, new String[] {registryName}, new int[] {meta});
|
||||||
}
|
}
|
||||||
|
|
||||||
public static void registerItem(Item item, String itemName)
|
static ResourceLocation[] generateVariants(String[] registryNames) {
|
||||||
{
|
ArrayList<ResourceLocation> ret = new ArrayList<ResourceLocation>();
|
||||||
registerItem(item, 0, itemName);
|
for (String aString : registryNames) {
|
||||||
}
|
ret.add(new ResourceLocation("ironchest", aString.contains("ironchest:") ? aString.replace("ironchest:", "") : aString));
|
||||||
}
|
}
|
||||||
|
return ret.toArray(new ResourceLocation[] {});
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
@ -7,19 +7,28 @@ tile.ironchest:CRYSTAL.name=Crystal Chest
|
||||||
tile.ironchest:OBSIDIAN.name=Obsidian Chest
|
tile.ironchest:OBSIDIAN.name=Obsidian Chest
|
||||||
tile.ironchest:DIRTCHEST9000.name=DirtChest 9000!
|
tile.ironchest:DIRTCHEST9000.name=DirtChest 9000!
|
||||||
|
|
||||||
item.ironchest:IRONGOLD.name=Iron to Gold Chest Upgrade
|
item.ironchest:WOOD_UPGRADE_IRON.name=Wood to Iron Chest Upgrade
|
||||||
item.ironchest:GOLDDIAMOND.name=Gold to Diamond Chest Upgrade
|
item.ironchest:WOOD_UPGRADE_GOLD.name=Wood to Gold Chest Upgrade
|
||||||
item.ironchest:COPPERSILVER.name=Copper to Silver Chest Upgrade
|
item.ironchest:WOOD_UPGRADE_DIAMOND.name=Wood to Diamond Chest Upgrade
|
||||||
item.ironchest:SILVERGOLD.name=Silver to Gold Chest Upgrade
|
item.ironchest:WOOD_UPGRADE_OBSIDIAN.name=Wood to Obsidian Chest Upgrade
|
||||||
item.ironchest:COPPERIRON.name=Copper to Iron Chest Upgrade
|
item.ironchest:IRON_UPGRADE_GOLD.name=Iron to Gold Chest Upgrade
|
||||||
item.ironchest:DIAMONDCRYSTAL.name=Diamond to Crystal Chest Upgrade
|
item.ironchest:IRON_UPGRADE_DIAMOND.name=Iron to Diamond Chest Upgrade
|
||||||
item.ironchest:WOODIRON.name=Wood to Iron Chest Upgrade
|
item.ironchest:IRON_UPGRADE_OBSIDIAN.name=Iron to Obsidian Chest Upgrade
|
||||||
item.ironchest:WOODCOPPER.name=Wood to Copper Chest Upgrade
|
item.ironchest:GOLD_UPGRADE_DIAMOND.name=Gold to Diamond Chest Upgrade
|
||||||
item.ironchest:DIAMONDOBSIDIAN.name=Diamond to Obsidian Chest Upgrade
|
item.ironchest:GOLD_UPGRADE_OBSIDIAN.name=Gold to Obsidian Chest Upgrade
|
||||||
|
item.ironchest:DIAMOND_OBSIDIAN_UPGRADE_OBSIDIAN.name=Diamond to Obsidian Chest Upgrade
|
||||||
|
item.ironchest:DIAMOND_CRYSTAL_UPGRADE_CRYSTAL.name=Diamond to Crystal Chest Upgrade
|
||||||
|
item.ironchest:COPPER_UPGRADE_IRON.name=Copper to Iron Chest Upgrade
|
||||||
|
item.ironchest:COPPER_UPGRADE_GOLD.name=Copper to Gold Chest Upgrade
|
||||||
|
item.ironchest:COPPER_UPGRADE_DIAMOND.name=Copper to Diamond Chest Upgrade
|
||||||
|
item.ironchest:COPPER_UPGRADE_OBSIDIAN.name=Copper to Obsidian Chest Upgrade
|
||||||
|
item.ironchest:SILVER_UPGRADE_GOLD.name=Silver to Gold Chest Upgrade
|
||||||
|
item.ironchest:SILVER_UPGRADE_DIAMOND.name=Silver to Diamond Chest Upgrade
|
||||||
|
item.ironchest:SILVER_UPGRADE_OBSIDIAN.name=Silver to Obsidian Chest Upgrade
|
||||||
|
|
||||||
book.ironchest:dirtchest9000.title=How to use your DirtChest 9000!
|
book.ironchest:dirtchest9000.title=How to use your DirtChest 9000!
|
||||||
book.ironchest:dirtchest9000.page1=Welcome to your new DirtChest 9000! We hope you will enjoy many happy years of storing your stack of dirt in our storage utility.
|
book.ironchest:dirtchest9000.page1=Welcome to your new DirtChest 9000! We hope you will enjoy many happy years of storing your stack of dirt in our storage utility.
|
||||||
book.ironchest:dirtchest9000.page2=Usage: simply insert the stack of dirt of your choice into the highly receptive slot and enjoy the great convenience of having that dirt available to you, any time you pass by this chest!
|
book.ironchest:dirtchest9000.page2=Usage: simply insert the stack of dirt of your choice into the highly receptive slot and enjoy the great convenience of having that dirt available to you, any time you pass by this chest!
|
||||||
book.ironchest:dirtchest9000.page3=We hope you have enjoyed reviewing this instruction manual, and hope you will consider using our products in future! Kind regards, The DirtChest 9000 manual writers incorporated.
|
book.ironchest:dirtchest9000.page3=We hope you have enjoyed reviewing this instruction manual, and hope you will consider using our products in future! Kind regards, The DirtChest 9000 manual writers incorporated.
|
||||||
book.ironchest:dirtchest9000.page4=Warranty: This product has no warranty of any kind. Your dirt may not be stored, it may slowly leech into the environment, or alternatively, it may not do anything at all.
|
book.ironchest:dirtchest9000.page4=Warranty: This product has no warranty of any kind. Your dirt may not be stored, it may slowly leech into the environment, or alternatively, it may not do anything at all.
|
||||||
book.ironchest:dirtchest9000.page5=DirtChest 9000 is kind to the environment. Please dispose of this guide book responsibly, and do not whatever you do just chuck it into some lava. We would be very sad.
|
book.ironchest:dirtchest9000.page5=DirtChest 9000 is kind to the environment. Please dispose of this guide book responsibly, and do not whatever you do just chuck it into some lava. We would be very sad.
|
||||||
|
|
@ -0,0 +1,19 @@
|
||||||
|
{
|
||||||
|
"parent": "builtin/generated",
|
||||||
|
"textures": {
|
||||||
|
"layer0": "ironchest:items/copperChest",
|
||||||
|
"layer1": "ironchest:items/diamondUpgrade"
|
||||||
|
},
|
||||||
|
"display": {
|
||||||
|
"thirdperson": {
|
||||||
|
"rotation": [ -90, 0, 0 ],
|
||||||
|
"translation": [ 0, 1, -3 ],
|
||||||
|
"scale": [ 0.55, 0.55, 0.55 ]
|
||||||
|
},
|
||||||
|
"firstperson": {
|
||||||
|
"rotation": [ 0, -135, 25 ],
|
||||||
|
"translation": [ 0, 4, 2 ],
|
||||||
|
"scale": [ 1.7, 1.7, 1.7 ]
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
@ -1,18 +1,19 @@
|
||||||
{
|
{
|
||||||
"parent": "builtin/generated",
|
"parent": "builtin/generated",
|
||||||
"textures": {
|
"textures": {
|
||||||
"layer0": "ironchest:items/diamondObsidianUpgrade"
|
"layer0": "ironchest:items/copperChest",
|
||||||
},
|
"layer1": "ironchest:items/goldUpgrade"
|
||||||
"display": {
|
},
|
||||||
"thirdperson": {
|
"display": {
|
||||||
"rotation": [ -90, 0, 0 ],
|
"thirdperson": {
|
||||||
"translation": [ 0, 1, -3 ],
|
"rotation": [ -90, 0, 0 ],
|
||||||
"scale": [ 0.55, 0.55, 0.55 ]
|
"translation": [ 0, 1, -3 ],
|
||||||
},
|
"scale": [ 0.55, 0.55, 0.55 ]
|
||||||
"firstperson": {
|
},
|
||||||
"rotation": [ 0, -135, 25 ],
|
"firstperson": {
|
||||||
"translation": [ 0, 4, 2 ],
|
"rotation": [ 0, -135, 25 ],
|
||||||
"scale": [ 1.7, 1.7, 1.7 ]
|
"translation": [ 0, 4, 2 ],
|
||||||
}
|
"scale": [ 1.7, 1.7, 1.7 ]
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,19 @@
|
||||||
|
{
|
||||||
|
"parent": "builtin/generated",
|
||||||
|
"textures": {
|
||||||
|
"layer0": "ironchest:items/copperChest",
|
||||||
|
"layer1": "ironchest:items/ironUpgrade"
|
||||||
|
},
|
||||||
|
"display": {
|
||||||
|
"thirdperson": {
|
||||||
|
"rotation": [ -90, 0, 0 ],
|
||||||
|
"translation": [ 0, 1, -3 ],
|
||||||
|
"scale": [ 0.55, 0.55, 0.55 ]
|
||||||
|
},
|
||||||
|
"firstperson": {
|
||||||
|
"rotation": [ 0, -135, 25 ],
|
||||||
|
"translation": [ 0, 4, 2 ],
|
||||||
|
"scale": [ 1.7, 1.7, 1.7 ]
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,19 @@
|
||||||
|
{
|
||||||
|
"parent": "builtin/generated",
|
||||||
|
"textures": {
|
||||||
|
"layer0": "ironchest:items/copperChest",
|
||||||
|
"layer1": "ironchest:items/obsidianUpgrade"
|
||||||
|
},
|
||||||
|
"display": {
|
||||||
|
"thirdperson": {
|
||||||
|
"rotation": [ -90, 0, 0 ],
|
||||||
|
"translation": [ 0, 1, -3 ],
|
||||||
|
"scale": [ 0.55, 0.55, 0.55 ]
|
||||||
|
},
|
||||||
|
"firstperson": {
|
||||||
|
"rotation": [ 0, -135, 25 ],
|
||||||
|
"translation": [ 0, 4, 2 ],
|
||||||
|
"scale": [ 1.7, 1.7, 1.7 ]
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,19 @@
|
||||||
|
{
|
||||||
|
"parent": "builtin/generated",
|
||||||
|
"textures": {
|
||||||
|
"layer0": "ironchest:items/diamondChest",
|
||||||
|
"layer1": "ironchest:items/crystalUpgrade"
|
||||||
|
},
|
||||||
|
"display": {
|
||||||
|
"thirdperson": {
|
||||||
|
"rotation": [ -90, 0, 0 ],
|
||||||
|
"translation": [ 0, 1, -3 ],
|
||||||
|
"scale": [ 0.55, 0.55, 0.55 ]
|
||||||
|
},
|
||||||
|
"firstperson": {
|
||||||
|
"rotation": [ 0, -135, 25 ],
|
||||||
|
"translation": [ 0, 4, 2 ],
|
||||||
|
"scale": [ 1.7, 1.7, 1.7 ]
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,19 @@
|
||||||
|
{
|
||||||
|
"parent": "builtin/generated",
|
||||||
|
"textures": {
|
||||||
|
"layer0": "ironchest:items/diamondChest",
|
||||||
|
"layer1": "ironchest:items/obsidianUpgrade"
|
||||||
|
},
|
||||||
|
"display": {
|
||||||
|
"thirdperson": {
|
||||||
|
"rotation": [ -90, 0, 0 ],
|
||||||
|
"translation": [ 0, 1, -3 ],
|
||||||
|
"scale": [ 0.55, 0.55, 0.55 ]
|
||||||
|
},
|
||||||
|
"firstperson": {
|
||||||
|
"rotation": [ 0, -135, 25 ],
|
||||||
|
"translation": [ 0, 4, 2 ],
|
||||||
|
"scale": [ 1.7, 1.7, 1.7 ]
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
@ -1,18 +0,0 @@
|
||||||
{
|
|
||||||
"parent": "builtin/generated",
|
|
||||||
"textures": {
|
|
||||||
"layer0": "ironchest:items/goldDiamondUpgrade"
|
|
||||||
},
|
|
||||||
"display": {
|
|
||||||
"thirdperson": {
|
|
||||||
"rotation": [ -90, 0, 0 ],
|
|
||||||
"translation": [ 0, 1, -3 ],
|
|
||||||
"scale": [ 0.55, 0.55, 0.55 ]
|
|
||||||
},
|
|
||||||
"firstperson": {
|
|
||||||
"rotation": [ 0, -135, 25 ],
|
|
||||||
"translation": [ 0, 4, 2 ],
|
|
||||||
"scale": [ 1.7, 1.7, 1.7 ]
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
@ -0,0 +1,19 @@
|
||||||
|
{
|
||||||
|
"parent": "builtin/generated",
|
||||||
|
"textures": {
|
||||||
|
"layer0": "ironchest:items/goldChest",
|
||||||
|
"layer1": "ironchest:items/diamondUpgrade"
|
||||||
|
},
|
||||||
|
"display": {
|
||||||
|
"thirdperson": {
|
||||||
|
"rotation": [ -90, 0, 0 ],
|
||||||
|
"translation": [ 0, 1, -3 ],
|
||||||
|
"scale": [ 0.55, 0.55, 0.55 ]
|
||||||
|
},
|
||||||
|
"firstperson": {
|
||||||
|
"rotation": [ 0, -135, 25 ],
|
||||||
|
"translation": [ 0, 4, 2 ],
|
||||||
|
"scale": [ 1.7, 1.7, 1.7 ]
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,19 @@
|
||||||
|
{
|
||||||
|
"parent": "builtin/generated",
|
||||||
|
"textures": {
|
||||||
|
"layer0": "ironchest:items/goldChest",
|
||||||
|
"layer1": "ironchest:items/obsidianUpgrade"
|
||||||
|
},
|
||||||
|
"display": {
|
||||||
|
"thirdperson": {
|
||||||
|
"rotation": [ -90, 0, 0 ],
|
||||||
|
"translation": [ 0, 1, -3 ],
|
||||||
|
"scale": [ 0.55, 0.55, 0.55 ]
|
||||||
|
},
|
||||||
|
"firstperson": {
|
||||||
|
"rotation": [ 0, -135, 25 ],
|
||||||
|
"translation": [ 0, 4, 2 ],
|
||||||
|
"scale": [ 1.7, 1.7, 1.7 ]
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
@ -1,18 +0,0 @@
|
||||||
{
|
|
||||||
"parent": "builtin/generated",
|
|
||||||
"textures": {
|
|
||||||
"layer0": "ironchest:items/ironGoldUpgrade"
|
|
||||||
},
|
|
||||||
"display": {
|
|
||||||
"thirdperson": {
|
|
||||||
"rotation": [ -90, 0, 0 ],
|
|
||||||
"translation": [ 0, 1, -3 ],
|
|
||||||
"scale": [ 0.55, 0.55, 0.55 ]
|
|
||||||
},
|
|
||||||
"firstperson": {
|
|
||||||
"rotation": [ 0, -135, 25 ],
|
|
||||||
"translation": [ 0, 4, 2 ],
|
|
||||||
"scale": [ 1.7, 1.7, 1.7 ]
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
@ -0,0 +1,19 @@
|
||||||
|
{
|
||||||
|
"parent": "builtin/generated",
|
||||||
|
"textures": {
|
||||||
|
"layer0": "ironchest:items/ironChest",
|
||||||
|
"layer1": "ironchest:items/diamondUpgrade"
|
||||||
|
},
|
||||||
|
"display": {
|
||||||
|
"thirdperson": {
|
||||||
|
"rotation": [ -90, 0, 0 ],
|
||||||
|
"translation": [ 0, 1, -3 ],
|
||||||
|
"scale": [ 0.55, 0.55, 0.55 ]
|
||||||
|
},
|
||||||
|
"firstperson": {
|
||||||
|
"rotation": [ 0, -135, 25 ],
|
||||||
|
"translation": [ 0, 4, 2 ],
|
||||||
|
"scale": [ 1.7, 1.7, 1.7 ]
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
@ -1,18 +1,19 @@
|
||||||
{
|
{
|
||||||
"parent": "builtin/generated",
|
"parent": "builtin/generated",
|
||||||
"textures": {
|
"textures": {
|
||||||
"layer0": "ironchest:items/copperIronUpgrade"
|
"layer0": "ironchest:items/ironChest",
|
||||||
},
|
"layer1": "ironchest:items/goldUpgrade"
|
||||||
"display": {
|
},
|
||||||
"thirdperson": {
|
"display": {
|
||||||
"rotation": [ -90, 0, 0 ],
|
"thirdperson": {
|
||||||
"translation": [ 0, 1, -3 ],
|
"rotation": [ -90, 0, 0 ],
|
||||||
"scale": [ 0.55, 0.55, 0.55 ]
|
"translation": [ 0, 1, -3 ],
|
||||||
},
|
"scale": [ 0.55, 0.55, 0.55 ]
|
||||||
"firstperson": {
|
},
|
||||||
"rotation": [ 0, -135, 25 ],
|
"firstperson": {
|
||||||
"translation": [ 0, 4, 2 ],
|
"rotation": [ 0, -135, 25 ],
|
||||||
"scale": [ 1.7, 1.7, 1.7 ]
|
"translation": [ 0, 4, 2 ],
|
||||||
}
|
"scale": [ 1.7, 1.7, 1.7 ]
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,19 @@
|
||||||
|
{
|
||||||
|
"parent": "builtin/generated",
|
||||||
|
"textures": {
|
||||||
|
"layer0": "ironchest:items/ironChest",
|
||||||
|
"layer1": "ironchest:items/obsidianUpgrade"
|
||||||
|
},
|
||||||
|
"display": {
|
||||||
|
"thirdperson": {
|
||||||
|
"rotation": [ -90, 0, 0 ],
|
||||||
|
"translation": [ 0, 1, -3 ],
|
||||||
|
"scale": [ 0.55, 0.55, 0.55 ]
|
||||||
|
},
|
||||||
|
"firstperson": {
|
||||||
|
"rotation": [ 0, -135, 25 ],
|
||||||
|
"translation": [ 0, 4, 2 ],
|
||||||
|
"scale": [ 1.7, 1.7, 1.7 ]
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
@ -1,18 +0,0 @@
|
||||||
{
|
|
||||||
"parent": "builtin/generated",
|
|
||||||
"textures": {
|
|
||||||
"layer0": "ironchest:items/silverGoldUpgrade"
|
|
||||||
},
|
|
||||||
"display": {
|
|
||||||
"thirdperson": {
|
|
||||||
"rotation": [ -90, 0, 0 ],
|
|
||||||
"translation": [ 0, 1, -3 ],
|
|
||||||
"scale": [ 0.55, 0.55, 0.55 ]
|
|
||||||
},
|
|
||||||
"firstperson": {
|
|
||||||
"rotation": [ 0, -135, 25 ],
|
|
||||||
"translation": [ 0, 4, 2 ],
|
|
||||||
"scale": [ 1.7, 1.7, 1.7 ]
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
@ -0,0 +1,19 @@
|
||||||
|
{
|
||||||
|
"parent": "builtin/generated",
|
||||||
|
"textures": {
|
||||||
|
"layer0": "ironchest:items/silverChest",
|
||||||
|
"layer1": "ironchest:items/diamondUpgrade"
|
||||||
|
},
|
||||||
|
"display": {
|
||||||
|
"thirdperson": {
|
||||||
|
"rotation": [ -90, 0, 0 ],
|
||||||
|
"translation": [ 0, 1, -3 ],
|
||||||
|
"scale": [ 0.55, 0.55, 0.55 ]
|
||||||
|
},
|
||||||
|
"firstperson": {
|
||||||
|
"rotation": [ 0, -135, 25 ],
|
||||||
|
"translation": [ 0, 4, 2 ],
|
||||||
|
"scale": [ 1.7, 1.7, 1.7 ]
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,19 @@
|
||||||
|
{
|
||||||
|
"parent": "builtin/generated",
|
||||||
|
"textures": {
|
||||||
|
"layer0": "ironchest:items/silverChest",
|
||||||
|
"layer1": "ironchest:items/goldUpgrade"
|
||||||
|
},
|
||||||
|
"display": {
|
||||||
|
"thirdperson": {
|
||||||
|
"rotation": [ -90, 0, 0 ],
|
||||||
|
"translation": [ 0, 1, -3 ],
|
||||||
|
"scale": [ 0.55, 0.55, 0.55 ]
|
||||||
|
},
|
||||||
|
"firstperson": {
|
||||||
|
"rotation": [ 0, -135, 25 ],
|
||||||
|
"translation": [ 0, 4, 2 ],
|
||||||
|
"scale": [ 1.7, 1.7, 1.7 ]
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,19 @@
|
||||||
|
{
|
||||||
|
"parent": "builtin/generated",
|
||||||
|
"textures": {
|
||||||
|
"layer0": "ironchest:items/silverChest",
|
||||||
|
"layer1": "ironchest:items/obsidianUpgrade"
|
||||||
|
},
|
||||||
|
"display": {
|
||||||
|
"thirdperson": {
|
||||||
|
"rotation": [ -90, 0, 0 ],
|
||||||
|
"translation": [ 0, 1, -3 ],
|
||||||
|
"scale": [ 0.55, 0.55, 0.55 ]
|
||||||
|
},
|
||||||
|
"firstperson": {
|
||||||
|
"rotation": [ 0, -135, 25 ],
|
||||||
|
"translation": [ 0, 4, 2 ],
|
||||||
|
"scale": [ 1.7, 1.7, 1.7 ]
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
@ -1,18 +0,0 @@
|
||||||
{
|
|
||||||
"parent": "builtin/generated",
|
|
||||||
"textures": {
|
|
||||||
"layer0": "ironchest:items/woodCopperUpgrade"
|
|
||||||
},
|
|
||||||
"display": {
|
|
||||||
"thirdperson": {
|
|
||||||
"rotation": [ -90, 0, 0 ],
|
|
||||||
"translation": [ 0, 1, -3 ],
|
|
||||||
"scale": [ 0.55, 0.55, 0.55 ]
|
|
||||||
},
|
|
||||||
"firstperson": {
|
|
||||||
"rotation": [ 0, -135, 25 ],
|
|
||||||
"translation": [ 0, 4, 2 ],
|
|
||||||
"scale": [ 1.7, 1.7, 1.7 ]
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
@ -1,18 +0,0 @@
|
||||||
{
|
|
||||||
"parent": "builtin/generated",
|
|
||||||
"textures": {
|
|
||||||
"layer0": "ironchest:items/woodIronUpgrade"
|
|
||||||
},
|
|
||||||
"display": {
|
|
||||||
"thirdperson": {
|
|
||||||
"rotation": [ -90, 0, 0 ],
|
|
||||||
"translation": [ 0, 1, -3 ],
|
|
||||||
"scale": [ 0.55, 0.55, 0.55 ]
|
|
||||||
},
|
|
||||||
"firstperson": {
|
|
||||||
"rotation": [ 0, -135, 25 ],
|
|
||||||
"translation": [ 0, 4, 2 ],
|
|
||||||
"scale": [ 1.7, 1.7, 1.7 ]
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
@ -0,0 +1,19 @@
|
||||||
|
{
|
||||||
|
"parent": "builtin/generated",
|
||||||
|
"textures": {
|
||||||
|
"layer0": "ironchest:items/woodChest",
|
||||||
|
"layer1": "ironchest:items/diamondUpgrade"
|
||||||
|
},
|
||||||
|
"display": {
|
||||||
|
"thirdperson": {
|
||||||
|
"rotation": [ -90, 0, 0 ],
|
||||||
|
"translation": [ 0, 1, -3 ],
|
||||||
|
"scale": [ 0.55, 0.55, 0.55 ]
|
||||||
|
},
|
||||||
|
"firstperson": {
|
||||||
|
"rotation": [ 0, -135, 25 ],
|
||||||
|
"translation": [ 0, 4, 2 ],
|
||||||
|
"scale": [ 1.7, 1.7, 1.7 ]
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
@ -1,18 +1,19 @@
|
||||||
{
|
{
|
||||||
"parent": "builtin/generated",
|
"parent": "builtin/generated",
|
||||||
"textures": {
|
"textures": {
|
||||||
"layer0": "ironchest:items/copperSilverUpgrade"
|
"layer0": "ironchest:items/woodChest",
|
||||||
},
|
"layer1": "ironchest:items/goldUpgrade"
|
||||||
"display": {
|
},
|
||||||
"thirdperson": {
|
"display": {
|
||||||
"rotation": [ -90, 0, 0 ],
|
"thirdperson": {
|
||||||
"translation": [ 0, 1, -3 ],
|
"rotation": [ -90, 0, 0 ],
|
||||||
"scale": [ 0.55, 0.55, 0.55 ]
|
"translation": [ 0, 1, -3 ],
|
||||||
},
|
"scale": [ 0.55, 0.55, 0.55 ]
|
||||||
"firstperson": {
|
},
|
||||||
"rotation": [ 0, -135, 25 ],
|
"firstperson": {
|
||||||
"translation": [ 0, 4, 2 ],
|
"rotation": [ 0, -135, 25 ],
|
||||||
"scale": [ 1.7, 1.7, 1.7 ]
|
"translation": [ 0, 4, 2 ],
|
||||||
}
|
"scale": [ 1.7, 1.7, 1.7 ]
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
@ -1,18 +1,19 @@
|
||||||
{
|
{
|
||||||
"parent": "builtin/generated",
|
"parent": "builtin/generated",
|
||||||
"textures": {
|
"textures": {
|
||||||
"layer0": "ironchest:items/diamondCrystalUpgrade"
|
"layer0": "ironchest:items/woodChest",
|
||||||
},
|
"layer1": "ironchest:items/ironUpgrade"
|
||||||
"display": {
|
},
|
||||||
"thirdperson": {
|
"display": {
|
||||||
"rotation": [ -90, 0, 0 ],
|
"thirdperson": {
|
||||||
"translation": [ 0, 1, -3 ],
|
"rotation": [ -90, 0, 0 ],
|
||||||
"scale": [ 0.55, 0.55, 0.55 ]
|
"translation": [ 0, 1, -3 ],
|
||||||
},
|
"scale": [ 0.55, 0.55, 0.55 ]
|
||||||
"firstperson": {
|
},
|
||||||
"rotation": [ 0, -135, 25 ],
|
"firstperson": {
|
||||||
"translation": [ 0, 4, 2 ],
|
"rotation": [ 0, -135, 25 ],
|
||||||
"scale": [ 1.7, 1.7, 1.7 ]
|
"translation": [ 0, 4, 2 ],
|
||||||
}
|
"scale": [ 1.7, 1.7, 1.7 ]
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,19 @@
|
||||||
|
{
|
||||||
|
"parent": "builtin/generated",
|
||||||
|
"textures": {
|
||||||
|
"layer0": "ironchest:items/woodChest",
|
||||||
|
"layer1": "ironchest:items/obsidianUpgrade"
|
||||||
|
},
|
||||||
|
"display": {
|
||||||
|
"thirdperson": {
|
||||||
|
"rotation": [ -90, 0, 0 ],
|
||||||
|
"translation": [ 0, 1, -3 ],
|
||||||
|
"scale": [ 0.55, 0.55, 0.55 ]
|
||||||
|
},
|
||||||
|
"firstperson": {
|
||||||
|
"rotation": [ 0, -135, 25 ],
|
||||||
|
"translation": [ 0, 4, 2 ],
|
||||||
|
"scale": [ 1.7, 1.7, 1.7 ]
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
After Width: | Height: | Size: 511 B |
|
Before Width: | Height: | Size: 480 B |
|
Before Width: | Height: | Size: 480 B |
|
After Width: | Height: | Size: 280 B |
|
After Width: | Height: | Size: 503 B |
|
Before Width: | Height: | Size: 418 B |
|
Before Width: | Height: | Size: 466 B |
|
After Width: | Height: | Size: 351 B |
|
After Width: | Height: | Size: 511 B |
|
Before Width: | Height: | Size: 480 B |
|
After Width: | Height: | Size: 375 B |
|
After Width: | Height: | Size: 499 B |
|
Before Width: | Height: | Size: 526 B |
|
After Width: | Height: | Size: 335 B |
|
After Width: | Height: | Size: 319 B |
|
After Width: | Height: | Size: 447 B |
|
Before Width: | Height: | Size: 526 B |
|
After Width: | Height: | Size: 553 B |
|
Before Width: | Height: | Size: 542 B |
|
Before Width: | Height: | Size: 540 B |