shane020482
Members-
Posts
72 -
Joined
-
Last visited
Everything posted by shane020482
-
Im creating a custom recipe class and cant figure out how to use items with meta. I know that in a reg recipe you do ModItems.itemname, #of items, item# however that is not working http://pastebin.com/3n0aRsVj
-
Yea I just grabed a dummy from your example for testing now that things are working Ill be cleaning up the code. Thanks so Much this is a very unfriendly method to use however once you figure it out it makes things so much easier. Have you thought about doing a tutorial on forge blockstates because for such a powerful method theirs almost no docs for it, and you seem to know quite a bit about it. Finally heres a finished variant
-
I have no clue how you found the need to use a dummy value, because that is such an unintuitive requirement. I had the texture model there because I was using the MC cube method which uses cube_all for the textures, cube for the model, and block for the display. Its nice to know you can combine all of them into one file. Still having probs with the item Sry i grabed the wrong error Heres the full log http://pastebin.com/sdz01d0g and a copy of my new blockstate http://pastebin.com/92M4ZMD3
-
I know this is a older topic but Iv ran into a small prob. When using custom models the default model method doesent work and the item blocks dont render. If I put the model in each of the variants the blocks look fine but nothing I do makes the item render. I have used this method for other blocks that use the MC cube model and it works fine its just when I use a custom model. Item error //blockstate https://github.com/Shane2482/Deadly-World/blob/master/src/main/resources/assets/deadlyworld/blockstates/block_lamp.json //model https://github.com/Shane2482/Deadly-World/blob/master/src/main/resources/assets/deadlyworld/models/block/lamp.json //texture map for model https://github.com/Shane2482/Deadly-World/blob/master/src/main/resources/assets/deadlyworld/models/block/lamp_textures.json
-
Im no expert but yes to both, but thats why Im asking for help like I said I have reworked this code every which way I can. The posted codes are by no means all that I have done, and so far i have been able to get ether one slot or the other to smelt but not the other, or both slots smelt together but only if you have items in both input slots, and more but those werent even close. So right now I know Im missing something simple because Iv gotten close I just cant figure out why.
-
Please Help someone has to know how to do this
-
Thanks that got me looking a a few things first I didnt set cookTime2 which meant I needed another isBurning to account for cookTime2 because you cant have a || inside of a bool so I redid the update and Im still having no luck and yes Iv tried merging them into || statements and Iv also changed around the order as well. This cant be all that hard the Grey Ghost did it sequentially so there has to be a way to do it in parallel. https://github.com/TheGreyGhost/MinecraftByExample/tree/1-10-2-inprogress/src/main/java/minecraftbyexample/mbe31_inventory_furnace public void update() { boolean flag = this.isBurning1(); boolean flag1 = this.isBurning2(); boolean flag2 = false; if (this.isBurning1() || this.isBurning2()) { --this.furnaceBurnTime; } if (!this.worldObj.isRemote) { if (this.isBurning1() || this.slots[2] != null && this.slots[0] != null) { if (!this.isBurning1() && this.canSmeltSlot1()) { this.furnaceBurnTime = getItemBurnTime(this.slots[2]); this.currentItemBurnTime = this.furnaceBurnTime; if (this.isBurning1()) { flag2 = true; if (this.slots[2] != null) { --this.slots[2].stackSize; if (this.slots[2].stackSize == 0) { this.slots[2] = slots[2].getItem().getContainerItem(slots[2]); } } } } if (this.isBurning1() && this.canSmeltSlot1()) { ++this.cookTime1; if (this.cookTime1 == this.totalCookTime) { this.cookTime1 = 0; this.totalCookTime = this.getCookTime(this.slots[0]); this.smeltItemSlot2(); ; flag2 = true; } } else { this.cookTime1 = 0; } } else if (!this.isBurning1() && this.cookTime1 > 0) { this.cookTime1 = MathHelper.clamp_int(this.cookTime1 - 2, 0, this.totalCookTime); } if (this.isBurning2() || this.slots[2] != null && this.slots[1] != null) { if (!this.isBurning2() && this.canSmeltSlot2()) { this.furnaceBurnTime = getItemBurnTime(this.slots[2]); this.currentItemBurnTime = this.furnaceBurnTime; if (this.isBurning2()) { flag2 = true; if (this.slots[2] != null) { --this.slots[2].stackSize; if (this.slots[2].stackSize == 0) { this.slots[2] = slots[1].getItem().getContainerItem(slots[2]); } } } } if (this.isBurning2() && this.canSmeltSlot2()) { ++this.cookTime2; if (this.cookTime2 == this.totalCookTime) { this.cookTime2 = 0; this.totalCookTime = this.getCookTime(this.slots[1]); this.smeltItemSlot2(); ; flag2 = true; } } else { this.cookTime2 = 0; } } else if (!this.isBurning2() && this.cookTime2 > 0) { this.cookTime2 = MathHelper.clamp_int(this.cookTime2 - 2, 0, this.totalCookTime); } if (flag1 != this.isBurning1() || this.isBurning2()) { flag2 = true; BlockFurnace.setState(this.isBurning1(), this.worldObj, this.pos); } } if (flag2) { this.markDirty(); } }
-
Thats what i did i have 2 canSmelts and 2 smeltItems one for each input output iv also got 2 cookTimes thats why i think my prob is in my update method public void update() { boolean flag = this.isBurning(); boolean flag1 = false; if (this.isBurning()) { --this.furnaceBurnTime; } if (!this.worldObj.isRemote) { if (this.isBurning() || this.furnaceItemStacks[2] != null && this.furnaceItemStacks[1] != null) { if (!this.isBurning() && this.canSmelt1()) { this.furnaceBurnTime = getItemBurnTime(this.furnaceItemStacks[2]); this.currentItemBurnTime = this.furnaceBurnTime; if (this.isBurning()) { flag1 = true; if (this.furnaceItemStacks[2] != null) { --this.furnaceItemStacks[2].stackSize; if (this.furnaceItemStacks[2].stackSize == 0) { this.furnaceItemStacks[2] = furnaceItemStacks[2].getItem() .getContainerItem(furnaceItemStacks[2]); } } } } if (this.isBurning() && this.canSmelt1()) { ++this.cookTime; if (this.cookTime == this.totalCookTime) { this.cookTime = 0; this.totalCookTime = this.getCookTime(this.furnaceItemStacks[0]); this.smeltItem2(); flag1 = true; } } else { this.cookTime = 0; } } if (this.isBurning() || this.furnaceItemStacks[2] != null && this.furnaceItemStacks[1] != null) { if (!this.isBurning() && this.canSmelt2()) { this.furnaceBurnTime = getItemBurnTime(this.furnaceItemStacks[2]); this.currentItemBurnTime = this.furnaceBurnTime; if (this.isBurning()) { flag1 = true; if (this.furnaceItemStacks[2] != null) { --this.furnaceItemStacks[2].stackSize; if (this.furnaceItemStacks[2].stackSize == 0) { this.furnaceItemStacks[2] = furnaceItemStacks[1].getItem() .getContainerItem(furnaceItemStacks[2]); } } } } if (this.isBurning() && this.canSmelt2()) { ++this.cookTime2; if (this.cookTime2 == this.totalCookTime) { this.cookTime2 = 0; this.totalCookTime = this.getCookTime(this.furnaceItemStacks[1]); this.smeltItem2(); flag1 = true; } } else { this.cookTime2 = 0; } } else if (!this.isBurning() && this.cookTime > 0) { this.cookTime = MathHelper.clamp_int(this.cookTime - 2, 0, this.totalCookTime); } else if (!this.isBurning() && this.cookTime2 > 0) { this.cookTime2 = MathHelper.clamp_int(this.cookTime2 - 2, 0, this.totalCookTime); } if (flag != this.isBurning()) { flag1 = true; BlockFurnace.setState(this.isBurning(), this.worldObj, this.pos); } } if (flag1) { this.markDirty(); } }
-
I'm wanting to make a Double Furnace that runs in parallel not an Alloy Smelter and I put the slot set up there that way ppl could see what slot numbers I was using just in case Iv got a slot number out of place
-
Im trying to create a furnace with 2 inputs, 2 outputs, and 1 fuel that will smelt both items at the same time and I cant figure out the update method to get this to work. I can get one slot or the other to smelt but not at the same time. Any help would be greatly appreciated Heres my Tile http://pastebin.com/yUScx40u and this is how i have my slots setup this.addSlotToContainer(new Slot(furnaceInventory, 0, 70, 21)); this.addSlotToContainer(new Slot(furnaceInventory, 1, 70, 48)); this.addSlotToContainer(new SlotFurnaceFuel(furnaceInventory, 2, 14, 53)); this.addSlotToContainer(new SlotFurnaceOutput(playerInventory.player, furnaceInventory, 3, 132, 35)); this.addSlotToContainer(new SlotFurnaceOutput(playerInventory.player, furnaceInventory, 4, 132, 55));
-
[Solved]Enum blocks not placing corectly
shane020482 replied to shane020482's topic in Modder Support
Yep 3 days of beating my head against a wall for one small mistake -
[Solved]Enum blocks not placing corectly
shane020482 replied to shane020482's topic in Modder Support
NM i found the prob in the itemblock class i had public int getMeta(int damage) { return damage; } not public int getMetadata(int damage) { return damage; } -
[Solved]Enum blocks not placing corectly
shane020482 replied to shane020482's topic in Modder Support
please don't think me an idiot but Iv been following a tutorial and have no idea how to use ItemMultiTexture -
I have created a block with different meta data using enums and Im having trouble with it always placing the default block and I cant find the cause here's what I have http://pastebin.com/GEiRdhBX Any help would be appreciate thanks