Giter Site home page Giter Site logo

craftingcosts's People

Contributors

adaptivity avatar fnuecke avatar guro2 avatar

Stargazers

 avatar  avatar  avatar

Watchers

 avatar

craftingcosts's Issues

Don't compute any costs until the Alt key is actually pressed.

When browsing through NEI, it seems that moving my mouse over multiple items causes rather massive lag. I've had a quick look through the code and if my understanding is correct, we're looking up the cost even before the Alt key is pressed - great for responsiveness, bad for NEI.

Perhaps this could be toggled with a config option?

I'd be willing to fork and refresh my Scala if this is low / not on your priority list. ;)

enhancement: add the ability to blacklist items for use in crafting

Would it be possible to add a blacklist to disable certain items from being used to craft for the cost.
An example where this would be useful would be with the thermal expansion sawmill's ability to turn shovels into wood, or the use of oreberrys from tinkers construct for ingots.
This enhancement would make it much nicer for modpacks to be able to make cleaner crafting cost tooltips.

Issue with infinite loops

In testing CraftingCosts with Per Fabrica Ad Astra and GregTech, I found that the mod gets caught up in infinite loops because these mods add recipes for things like cobble and metals (i.e. Stone in a Macerator creates Cobblestone, GregTech adds several recipes for converting iron and other metals between various mods' versions), as well as CraftingCosts looking up recipes for tools used in recipes leading to even more infinite loops (i.e. there's a recipe for sticks that uses a saw, but a saw is made with sticks).

In discussing with the other players on the server at the time, we came up with the idea of allowing a config that sets certain materials (i.e. cobblestone, tools, etc.) as absolute base states, so that CraftingCosts won't look up recipes for these items as defined in the config file. :-)

Thread-safety problem with NEI Blood Magic add-on

There seems to be a compatibility problem with NEI's Blood Magic add-on - most complex recipes show their costs as "java.util.ConcurrentModificationException". Stack trace:

java.util.ConcurrentModificationException
at java.util.ArrayList$Itr.checkForComodification(ArrayList.java:859)
at java.util.ArrayList$Itr.next(ArrayList.java:831)
at joshie.alchemicalWizardy.nei.NEIBloodOrbShapedHandler$CachedBloodOrbRecipe.setIngredients(NEIBloodOrbShapedHandler.java:41)
at codechicken.nei.recipe.ShapedRecipeHandler$CachedShapedRecipe.(ShapedRecipeHandler.java:35)
at joshie.alchemicalWizardy.nei.NEIBloodOrbShapedHandler$CachedBloodOrbRecipe.(NEIBloodOrbShapedHandler.java:24)
at joshie.alchemicalWizardy.nei.NEIBloodOrbShapedHandler.forgeShapedRecipe(NEIBloodOrbShapedHandler.java:124)
at joshie.alchemicalWizardy.nei.NEIBloodOrbShapedHandler.loadCraftingRecipes(NEIBloodOrbShapedHandler.java:78)
at codechicken.nei.recipe.TemplateRecipeHandler.loadCraftingRecipes(TemplateRecipeHandler.java:327)
at codechicken.nei.recipe.ShapedRecipeHandler.loadCraftingRecipes(ShapedRecipeHandler.java:107)
at joshie.alchemicalWizardy.nei.NEIBloodOrbShapedHandler.loadCraftingRecipes(NEIBloodOrbShapedHandler.java:70)
at codechicken.nei.recipe.TemplateRecipeHandler.getRecipeHandler(TemplateRecipeHandler.java:465)
at li.cil.cc.ClientProxy$$anonfun$4.apply(ClientProxy.scala:177)
at li.cil.cc.ClientProxy$$anonfun$4.apply(ClientProxy.scala:177)
at scala.collection.TraversableLike$$anonfun$map$1.apply(TraversableLike.scala:245)
at scala.collection.TraversableLike$$anonfun$map$1.apply(TraversableLike.scala:245)
at scala.collection.Iterator$class.foreach(Iterator.scala:743)
at scala.collection.AbstractIterator.foreach(Iterator.scala:1174)
at scala.collection.IterableLike$class.foreach(IterableLike.scala:72)
at scala.collection.AbstractIterable.foreach(Iterable.scala:54)
at scala.collection.TraversableLike$class.map(TraversableLike.scala:245)
at scala.collection.AbstractTraversable.map(Traversable.scala:104)
at li.cil.cc.ClientProxy.li$cil$cc$ClientProxy$$computeCosts(ClientProxy.scala:177)
at li.cil.cc.ClientProxy$$anonfun$21.apply(ClientProxy.scala:243)
at li.cil.cc.ClientProxy$$anonfun$21.apply(ClientProxy.scala:243)
at li.cil.cc.ClientProxy$$anonfun$1.liftedTree1$1(ClientProxy.scala:131)
at li.cil.cc.ClientProxy$$anonfun$1.apply(ClientProxy.scala:131)
at li.cil.cc.ClientProxy$$anonfun$1.apply(ClientProxy.scala:127)
at scala.concurrent.impl.Future$PromiseCompletingRunnable.liftedTree1$1(Future.scala:24)
at scala.concurrent.impl.Future$PromiseCompletingRunnable.run(Future.scala:24)
at scala.concurrent.impl.ExecutionContextImpl$AdaptedForkJoinTask.exec(ExecutionContextImpl.scala:121)
at scala.concurrent.forkjoin.ForkJoinTask.doExec(ForkJoinTask.java:260)
at scala.concurrent.forkjoin.ForkJoinPool$WorkQueue.runTask(ForkJoinPool.java:1339)
at scala.concurrent.forkjoin.ForkJoinPool.runWorker(ForkJoinPool.java:1979)
at scala.concurrent.forkjoin.ForkJoinWorkerThread.run(ForkJoinWorkerThread.java:107)

enhancement: add the ability to blacklist items for use in crafting

Would it be possible to add a blacklist to disable certain items from being used to craft for the cost.
An example where this would be useful would be with the thermal expansion sawmill's ability to turn shovels into wood, or the use of oreberrys from tinkers construct for ingots.
This enhancement would make it much nicer for modpacks to be able to make cleaner crafting cost tooltips.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.