Skip to content

Commit

Permalink
check if cyclic content is enabled for registry (#209)
Browse files Browse the repository at this point in the history
  • Loading branch information
WaitingIdly authored Jul 26, 2024
1 parent 6f49410 commit 491264c
Show file tree
Hide file tree
Showing 5 changed files with 30 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@
import com.cleanroommc.groovyscript.helper.SimpleObjectStream;
import com.cleanroommc.groovyscript.helper.recipe.AbstractRecipeBuilder;
import com.cleanroommc.groovyscript.registry.VirtualizedRegistry;
import com.lothrazar.cyclicmagic.CyclicContent;
import com.lothrazar.cyclicmagic.block.dehydrator.RecipeDeHydrate;
import net.minecraft.item.ItemStack;
import org.jetbrains.annotations.Nullable;
Expand All @@ -23,6 +24,11 @@ public RecipeBuilder recipeBuilder() {
return new RecipeBuilder();
}

@Override
public boolean isEnabled() {
return CyclicContent.dehydrator.enabled();
}

@Override
@GroovyBlacklist
public void onReload() {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
import com.cleanroommc.groovyscript.helper.recipe.AbstractRecipeBuilder;
import com.cleanroommc.groovyscript.registry.VirtualizedRegistry;
import com.google.common.collect.Lists;
import com.lothrazar.cyclicmagic.CyclicContent;
import com.lothrazar.cyclicmagic.block.hydrator.RecipeHydrate;
import net.minecraft.item.ItemStack;
import org.jetbrains.annotations.Nullable;
Expand All @@ -28,6 +29,11 @@ public RecipeBuilder recipeBuilder() {
return new RecipeBuilder();
}

@Override
public boolean isEnabled() {
return CyclicContent.hydrator.enabled();
}

@Override
@GroovyBlacklist
public void onReload() {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
import com.cleanroommc.groovyscript.helper.recipe.AbstractRecipeBuilder;
import com.cleanroommc.groovyscript.registry.VirtualizedRegistry;
import com.google.common.collect.Lists;
import com.lothrazar.cyclicmagic.CyclicContent;
import com.lothrazar.cyclicmagic.block.melter.RecipeMelter;
import net.minecraft.item.ItemStack;
import org.jetbrains.annotations.Nullable;
Expand All @@ -28,6 +29,11 @@ public RecipeBuilder recipeBuilder() {
return new RecipeBuilder();
}

@Override
public boolean isEnabled() {
return CyclicContent.melter.enabled();
}

@Override
@GroovyBlacklist
public void onReload() {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
import com.cleanroommc.groovyscript.helper.recipe.AbstractRecipeBuilder;
import com.cleanroommc.groovyscript.registry.VirtualizedRegistry;
import com.google.common.collect.Lists;
import com.lothrazar.cyclicmagic.CyclicContent;
import com.lothrazar.cyclicmagic.block.packager.RecipePackager;
import net.minecraft.item.ItemStack;
import org.jetbrains.annotations.Nullable;
Expand All @@ -28,6 +29,11 @@ public RecipeBuilder recipeBuilder() {
return new RecipeBuilder();
}

@Override
public boolean isEnabled() {
return CyclicContent.packager.enabled();
}

@Override
@GroovyBlacklist
public void onReload() {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
import com.cleanroommc.groovyscript.helper.recipe.AbstractRecipeBuilder;
import com.cleanroommc.groovyscript.registry.VirtualizedRegistry;
import com.google.common.collect.Lists;
import com.lothrazar.cyclicmagic.CyclicContent;
import com.lothrazar.cyclicmagic.block.solidifier.RecipeSolidifier;
import net.minecraft.item.ItemStack;
import org.jetbrains.annotations.Nullable;
Expand All @@ -28,6 +29,11 @@ public RecipeBuilder recipeBuilder() {
return new RecipeBuilder();
}

@Override
public boolean isEnabled() {
return CyclicContent.solidifier.enabled();
}

@Override
@GroovyBlacklist
public void onReload() {
Expand Down

0 comments on commit 491264c

Please sign in to comment.