ContentTweaker

ContentTweaker

27M Downloads

[1.12.2] Trying to access ghost liquid before it's ready

ParzivalWolfram opened this issue ยท 2 comments

commented

Trying to modify liquids from other mods, or other ContentTweaker scripts, in scripts, results in ERROR: Trying to access Ghost liquid before it's ready: <liquid:whatever>. I need to set the temperature of some liquids for Tinker's purposes. The liquids do exist, and I have not misspelled them.

import crafttweaker.liquid.ILiquidDefinition;

val definition = <liquid:lycanitesmobs:moglava>.definition;
definition.temperature = 1000;
commented

Are you trying to do this in a script with the contenttweaker loader? If so, that's why- the contenttweaker loader runs before crafttweaker and the other initialization events, so those liquids wouldn't be ready yet. It seems like you're using a crafttweaker bracket handler, so if you are using a contenttweaker loader, use a contenttweaker bracket handler to access the liquid, or move your code to a separate script without the contenttweaker loader.

commented

Apologies, this isn't loaded with ContentTweaker. The code block is the entire script. I put the issue on the wrong repo.