xt9 / inworldcrafting Goto Github PK
View Code? Open in Web Editor NEWCrafttweaker integration that lets you craft in the world with Fluids, Fire or Explosions.
Crafttweaker integration that lets you craft in the world with Fluids, Fire or Explosions.
There are mods that add things like mud blocks or adobe that start out wet and dry over time when placed in-world. Similarly there are mods that add blocks that change over time when placed adjacent to water like Forestry bog earth to peat or vanilla concrete powder (see #17).
It would be neat to be able to have such transformations via crafttweaker like provide an input block, number of ticks, output block, and whether the block should/should not be adjacent to water.
As a nice-to-have, but not really needed option maybe being able to specify whether the block needs to see sky above it or specific biome dictionary tags would also be useful.
i.e. specification of more than one input item per recipe
So while looking through code for suggestions for #8 .
I found the "AnvilRepairEvent" which lets you modify a few things:
Itemstack "left"
Itemstack "right"
Itemstack "output"
float "breakChance"
Might be something worth looking into supporting?
Might be a bit out of scope since it's not an in-world interaction.
The FluidtiItem won't take the IIngredient*n and multiples of the same IIngredient would load, but wouldn't work. (I know it's in documentation not to have duplicate ingredients). Logs throw out:
"[INITIALIZATION][CLIENT][ERROR] add.zs:30 > 3 methods available but none matches the parameters (ZenTypeNative: crafttweaker.item.IItemStack, ZenTypeNative: crafttweaker.liquid.ILiquidStack, any[], bool)
This is usually an error in your script, not in the mod
transform(ZenTypeNative: crafttweaker.item.IItemStack, ZenTypeNative: crafttweaker.liquid.ILiquidStack, ZenTypeNative: crafttweaker.item.IIngredient, bool)
transform(ZenTypeNative: crafttweaker.item.IItemStack, ZenTypeNative: crafttweaker.liquid.ILiquidStack, ZenTypeNative: crafttweaker.item.IIngredient)
transform(ZenTypeNative: crafttweaker.item.IItemStack, ZenTypeNative: crafttweaker.liquid.ILiquidStack, ZenTypeNative: crafttweaker.item.IItemStack)"
"astralsorcery", "logWood"
"astralsorcery", "astralsorcery:itemrockcrystalsimple"
"astralsorcery", "astralsorcery:itemcelestialcrystal"
"appliedenergistics2", "appliedenergistics2:material:1"
"appliedenergistics2", "appliedenergistics2:crystal_seed:*"
"actuallyadditions", "actuallyadditions:item_misc:23"
"actuallyadditions", "actuallyadditions:item_misc:24"
"deepmoblearning", "deepmoblearning:glitch_fragment"
If you know of an item that needs their own EntityItem for crafting logic or you have noticed some feature being broken as a result of adding a InWorldCrafting recipe then you can post about it here.
The mod Repose adds a variety of falling blocks. I would like to make it so that when dirt falls into water it becomes mud.
What I'd like to see is a script to change fluids into either blocks or other fluids if they are touching a specific block, such as water turning into brine if it touches a salt ore block (with the option of changing the salt ore block as well), then changing the adjacent water into brine in a chain reaction, meaning that those salt blocks on the bottom of ponds would turn the ponds into brine.
To prevent this from turning whole oceans into a different fluid, this would have to limit the chain reactions to only occur within a certain distance from the original block that triggered the first change.
The explosion and burn crafting have a percentage based chance to consume the materials or successfully transform. It would be nice if the fluid transform or item transform had something similar.
in vanilla - a block of concretepowder is transformed into a block of concrete if it touches water.
is it possible to do the same for the transformation of other blocks to other blocks?
not throwed items, but inworld blocks, like vanilla concrete powder to concrete
JavaFX is not included so it is not able to find the class so nothing happens.
Version 0.11
Error that shows in CraftTweaker Log: https://pastebin.com/mmydfq56
Script
import mods.inworldcrafting.FluidToFluid;
FluidToFluid.transform(<liquid:lava>, <liquid:water>, <minecraft:blaze_powder>);
I'd like to be able to craft a block or item by dropping an anvil on it.
Details:
I'd like both blocks and items to be supported. Blocks must be placed in the world to work.
Turning an item into a block might be difficult because there might not be an empty block space. This doesn't need to be supported.
I'd like an option to set a minimum and maximum distance. The anvil must fall a number of blocks between these two values to count.
Setting a minimum fall distance would make automation slightly more interesting. Setting it to a high number would also make the anvil degrade, making it more expensive.
Being able to set a maximum means we could theoretically set two different versions of the same recipe. If the anvil falls from less than 3 blocks, it gives less output items than it it dropped from more than 3.
Similar to how flint can be knapped on hard blocks in certain survival mods (Primitive Tools, PrimalCore) or how Corrupted Glitch Hearts can be broken into fragments on obsidian in your other mod (Deep Mob Learning).
Being able to right-click on fluid blocks instead of dropping items in would also be nice, but I can see how that might be redundant.
I'm not sure which mod is causing this issue, so I'm posting this issue to both Astral Sorcery and InWorldCrafting's issue pages.
Forge Version: 14.23.5.2847
Astral Sorcery Version: 1.12.2-1.10.22
InWorldCrafting Version: 1.12.2-0.13.0
I have made recipes using InWorldCrafting that use Liquid Starlight as a fluid catalyst for the recipe. For some reason, this causes Celestial Crystal growth to not function. I can still grow Dynamism Gems, but Celestial Crystal Clusters won't form. Below I'll paste my InWorldCrafting script if that helps.
// In-World Crafting
// Get Yer Imports!
import mods.inworldcrafting.FluidToItem;
// Liquid Starlight
FluidToItem.transform(<minecraft:iron_ingot>, <liquid:astralsorcery.liquidstarlight>, <minecraft:gold_ingot>, false);
FluidToItem.transform(<astralsorcery:itemcraftingcomponent:2>, <liquid:astralsorcery.liquidstarlight>, <contenttweaker:iron_dust>, false);
FluidToItem.transform(<minecraft:redstone>, <liquid:astralsorcery.liquidstarlight>, <arcanearchives:radiant_dust>, false);
FluidToItem.transform(<minecraft:glowstone_dust>, <liquid:astralsorcery.liquidstarlight>, <contenttweaker:gold_dust>, false);
FluidToItem.transform(<minecraft:prismarine_crystals>, <liquid:astralsorcery.liquidstarlight>, <minecraft:prismarine_shard>, false);
FluidToItem.transform(<minecraft:quartz>, <liquid:astralsorcery.liquidstarlight>, <arcanearchives:raw_quartz>, false);
FluidToItem.transform(<contenttweaker:enchanted_clock>, <liquid:astralsorcery.liquidstarlight>, <minecraft:clock>, false);
FluidToItem.transform(<minecraft:diamond>, <liquid:astralsorcery.liquidstarlight>, <minecraft:dye:4>, false);
// Water
FluidToItem.transform(<contenttweaker:white_dye>, <liquid:water>, <minecraft:sugar>, false);
FluidToItem.transform(<extrautils2:ingredients:14>, <liquid:water>, <astralsorcery:itemcraftingcomponent:2>, false);
FluidToItem.transform(<minecraft:dye:11>, <liquid:water>, <minecraft:glowstone_dust>, false);
FluidToItem.transform(<minecraft:dye:1>, <liquid:water>, <minecraft:redstone>, false);
FluidToItem.transform(<contenttweaker:black_dye>, <liquid:water>, <contenttweaker:charcoal_dust>, false);
I would like to suggest adding Shift + Right Click crafting in-world.
Example would be holding a stack of string, holding Shift then right clicking would use 4 string and craft a block of wool.
Hello, I am writing this to notify the creator of a possible mistype within the wiki or a change that caused the documentation to be slightly incorrect.
When using []'s within item parameters, it comes up with errors, thanks to a discord member I was able to figure out how and why this happened.
This was my code:
(And yes, before asking, the import code was applied first as well. Also, 'wooda' is just a contenttweaker fluid.)
mods.inworldcrafting.FluidToFluid.transform(liquid:wooda, liquid:water, [rustic:grape_stem]);;
But, in making it, this error occurred. Pastebin Link
Thanks to a discord user, they found out that the []'s were causing this error, in some examples on the wiki, items are shown with this bracket, and on removing them:
mods.inworldcrafting.FluidToFluid.transform(liquid:wooda, liquid:water, rustic:grape_stem);
This error was fixed, I am not too sure if this is selective in my case, but if this exsists still with the current versions of craftttweaker: (CraftTweaker2-1.12-4.1.20.jar) Then this might want to be fixed within the wiki.
as of 0.12.0, the recipes completely ignore the tags of an inputstack
FluidToItem And FluidToFluid Won't Accept 2 or more items inside of inworldcrafting Array, InWorldCrafting can only be used with <>.. doesn't work with [] brackets therefore can't use more than 1 item InWorld
Just wondering why it didn't work..
Script:
https://pastebin.com/AzMgSEpe
CraftTweaker Log:
https://pastebin.com/xpaYTpEf
I've gotten several reports that for fluid/fire crafting users can pick up both the inputs & outputs if they time pickup at precisely the time that the item transforms. Let me know if you need more information
-Recipes for when a block is burnt by fire (such as a log dropping charcoal if it is destroyed by fire)
-Recipes for when a fire on a block is extinguished (such as Ender IO's method for getting grains of infinity)
When using Fire burning in world crafting, the fire destroys the items before they can craft... any way to avoid this?
turning a fluid into a block. having a fluid go over another fluid and then the said fluid turns into a block
I had two ideas so am just using the second one of them but figured I should report this as not working anyways.
With version 0.13.0 trying to do FluidToItem transforms do not work if the fluid is lava. The item lights on fire and bounces out of the lava in its original state. (Happens when consume is true and false.)
Its possible that I just don't see how to do it, but it would be nice if there were a way to combine the fluid and item transformations. Example: using a filter item on dirty water would result in clean water and a dirty filter.
Fluidlogged API makes it possible to, in 1.12.2, place any fluid in any block (like water-logging of 1.13+). It would be nice if InWorldCrafting's Fluid To Fluid and Fluid To Item recognized a waterlogged block as a fluid for the purpose of crafting. It currently doesn't
This would work like the Fluid to Fluid recipes, except that the output is a solid block that replaces the fluid.
For example, I throw dirt into water and the water is replaced with mud, which is a solid block.
im trying to change the recipe for the coils from thermal but, it keeps saying ERROR: reception coil.zs:1: Could not resolve liquid : fluid_redstone
i think its because i have the id wrong but everywhere i look this is all i can find. ive tried using HWYLA and advanced tool tips with jei and they all lead to the same id.
here is the script im trying to use
mods.inworldcrafting.FluidToItem.transform(thermalfoundation:material:513, liquid:fluid_redstone, [minecraft:gold_ingot]);
I would like the option for the fluid to fluid or the item to item transitions to occur over a set period of time or, better yet, have a chance to happen within a range of time, similar to how ae2 seeds or astral sorcery crystals grow.
in Fluid to Item crafting, it recognizes flowing liquids as valid for the transformation. This means that no recipe can be successfully set to consume the block since players can just toss it in the flowing liquid to avoid the cost.
There seems to be an issue with Fluid to Item. I have the consume parameter set to true, and when I put my input item inside the source fluid then the gets consumed, which is how it's supposed to work. However, when I put an item inside of a fluid that ISN'T the source fluid (the flowing fluid), the item still converts, but the fluid isn't consumed.
Here's my script.
import mods.inworldcrafting.FluidToItem;
import mods.inworldcrafting.FluidToFluid;
FluidToItem.transform(<contenttweaker:charged_wart_item>, <liquid:liquid_xp>, <minecraft:nether_wart>, true);
FluidToFluid.transform(<liquid:liquid_xp>, <liquid:water>, <minecraft:experience_bottle>, true);
What I was hoping to happen is FluidToItem would only work if it's the source fluid.
FluidToFluid handles this right. If you put the input item in a flowing fluid instead of a source fluid then no conversion happens.
Specifically looking at explosion crafting; I want to shatter ore blocks into multiple pieces;
mods.inworldcrafting.ExplosionCrafting.explodeBlockRecipe([<output array>], <block input>);
The % survival chance could be moved to the array
mods.inworldcrafting.ExplosionCrafting.explodeBlockRecipe([
<ore:gemDiamond>*1, 100,
<ore:crushedDiamond>*1, 50,
<ore:dustImpureDiamond>*1, 50], <ore:oreDiamond>);
Or (if its easier to implement) you could define each output in a new recipe;
mods.inworldcrafting.ExplosionCrafting.explodeBlockRecipe(<minecraft:diamond>, <minecraft:stone>);
mods.inworldcrafting.ExplosionCrafting.explodeBlockRecipe(<minecraft:emerald>, <minecraft:stone>);
(Just tested this with IWC v1.13.0, sadly it only dropped diamonds although it showed the diamond and emerald in JEI)
No errors in crafttweaker, but when I use this script with modded liquid (Fluid Block extends BlockFluidFinite):
FluidToItem.transform(<minecraft:spawn_egg>.withTag({EntityTag: {id: "minecraft:cow"}}), <liquid:alivewater>, [<minecraft:egg>, <minecraft:wheat>], true);
it doesn't work at all (I don't get the resulting item), but if I omit the last argument:
FluidToItem.transform(<minecraft:spawn_egg>.withTag({EntityTag: {id: "minecraft:cow"}}), <liquid:alivewater>, [<minecraft:egg>, <minecraft:wheat>]);
it works fine, but the liquid doesn't get consumed of course.
If I change liquid to vanilla water - everything works as intended.
Forge: 2847
Mod version: 1.2.0
Crash log: https://gist.github.com/Hjaldar/ab91dbc4270a1e4166d8a7890ba8c46b
Crash seems to occur as the 3rd stack of gravel hits the creosote.
This occurred in your in-dev pack, v 0.2
Crash occurs on logging into the world again. Fixed world by editing out the creosote in MCEdit, then was able to reproduce the crash once more.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.