Furnace Cook Speed
7ekhed opened this issue ยท 5 comments
Hello! I love the mod, and you've coded it expertly. I have taken inspiration and made my own mod using the same kind of methods you did, but I am unsure how to change how long it takes to smelt things in the furnace. How do I change the speed of which, and where would that be found? Would that be found under the BrickFurnaceTileEntity, or somewhere else?
Thank you for you consideration in my request, it is greatly appreciated.
In every tile entity there is such a method. The multiplication of the return value should be enough.
protected int func_214005_h() {
AbstractCookingRecipe rec = getRecipe();
if (rec == null) return 200 * 0.5;
return rec.getCookTime() * 0.5;
}
should be enough. If it does not work, than I cannot help you sorry.
for anyone else who may read this, this addition requires the variable to be converted to an integer as such:
protected int func_214005_h()
{
AbstractCookingRecipe rec = getRecipe();
if (rec == null) return (int) (200 * 0.1);
return (int) (rec.getCookTime() * 0.1);
}
Hey, thanks a lot! :)
There is a method in the tile entities where the cooking time is returned. The normal cooking time of a furnace is 200. So you can multiply 0.5 or 2 to half or double this value for example.
In the brick furnace tile entity the method is called func_214005_h()
Good luck. And if you share a link to you repository will be awesome :)