diff --git a/src/main/java/com/simibubi/create/AllBlocks.java b/src/main/java/com/simibubi/create/AllBlocks.java index 10cde1866..84d8351a0 100644 --- a/src/main/java/com/simibubi/create/AllBlocks.java +++ b/src/main/java/com/simibubi/create/AllBlocks.java @@ -74,6 +74,7 @@ import com.simibubi.create.modules.logistics.block.diodes.ToggleLatchBlock; import com.simibubi.create.modules.logistics.block.extractor.ExtractorBlock; import com.simibubi.create.modules.logistics.block.extractor.LinkedExtractorBlock; import com.simibubi.create.modules.logistics.block.funnel.FunnelBlock; +import com.simibubi.create.modules.logistics.block.inventories.CrateBlock; import com.simibubi.create.modules.logistics.block.inventories.FlexcrateBlock; import com.simibubi.create.modules.logistics.block.transposer.LinkedTransposerBlock; import com.simibubi.create.modules.logistics.block.transposer.TransposerBlock; @@ -85,7 +86,6 @@ import com.simibubi.create.modules.palettes.HorizontalCTGlassBlock; import com.simibubi.create.modules.palettes.LayeredCTBlock; import com.simibubi.create.modules.palettes.ScoriaBlock; import com.simibubi.create.modules.palettes.VerticalCTGlassBlock; -import com.simibubi.create.modules.schematics.block.CreativeCrateBlock; import com.simibubi.create.modules.schematics.block.SchematicTableBlock; import com.simibubi.create.modules.schematics.block.SchematicannonBlock; @@ -115,7 +115,6 @@ public enum AllBlocks { __SCHEMATICS__(), SCHEMATICANNON(new SchematicannonBlock()), - CREATIVE_CRATE(new CreativeCrateBlock()), SCHEMATIC_TABLE(new SchematicTableBlock()), __CONTRAPTIONS__(), @@ -183,7 +182,10 @@ public enum AllBlocks { CONTACT(new ContactBlock()), REDSTONE_BRIDGE(new RedstoneLinkBlock()), STOCKSWITCH(new StockswitchBlock()), + WAREHOUSE_CRATE(new CrateBlock(Properties.from(Blocks.ANDESITE))), FLEXCRATE(new FlexcrateBlock()), + FILTERED_CRATE(new CrateBlock(Properties.from(Blocks.ANDESITE))), + CREATIVE_CRATE(new CrateBlock(Properties.from(Blocks.ANDESITE))), EXTRACTOR(new ExtractorBlock()), VERTICAL_EXTRACTOR(new ExtractorBlock.Vertical()), LINKED_EXTRACTOR(new LinkedExtractorBlock()), diff --git a/src/main/java/com/simibubi/create/data/CreateAdvancements.java b/src/main/java/com/simibubi/create/data/CreateAdvancements.java new file mode 100644 index 000000000..6c8dd3608 --- /dev/null +++ b/src/main/java/com/simibubi/create/data/CreateAdvancements.java @@ -0,0 +1,314 @@ +package com.simibubi.create.data; + +import java.io.IOException; +import java.nio.file.Path; +import java.util.Set; +import java.util.function.Consumer; + +import org.apache.logging.log4j.LogManager; +import org.apache.logging.log4j.Logger; + +import com.google.common.collect.Sets; +import com.google.gson.Gson; +import com.google.gson.GsonBuilder; +import com.simibubi.create.AllBlocks; +import com.simibubi.create.AllItems; +import com.simibubi.create.Create; +import com.simibubi.create.foundation.advancement.AllTriggers; +import com.simibubi.create.foundation.advancement.KineticBlockTrigger; + +import net.minecraft.advancements.Advancement; +import net.minecraft.advancements.Advancement.Builder; +import net.minecraft.advancements.FrameType; +import net.minecraft.advancements.IRequirementsStrategy; +import net.minecraft.advancements.criterion.InventoryChangeTrigger; +import net.minecraft.advancements.criterion.PlacedBlockTrigger; +import net.minecraft.block.Block; +import net.minecraft.block.Blocks; +import net.minecraft.data.DataGenerator; +import net.minecraft.data.DirectoryCache; +import net.minecraft.data.IDataProvider; +import net.minecraft.item.Items; +import net.minecraft.util.IItemProvider; +import net.minecraft.util.ResourceLocation; +import net.minecraft.util.text.TranslationTextComponent; + +@SuppressWarnings("unused") // dont warn about unused avancements +public class CreateAdvancements implements IDataProvider { + + static final String LANG = "advancement." + Create.ID + "."; + + public void register(Consumer t) { + String id = Create.ID; + + Advancement root = Advancement.Builder + .builder() + .withDisplay(AllItems.BRASS_HAND.asStack(), new TranslationTextComponent(LANG + "root"), + new TranslationTextComponent(LANG + "root.desc"), + new ResourceLocation(Create.ID, "textures/block/scoria_bricks.png"), FrameType.TASK, false, + false, false) + .withCriterion("0", InventoryChangeTrigger.Instance.forItems(new IItemProvider[] {})) + .register(t, id + ":root"); + + Advancement andesite_alloy = advancement("andesite_alloy", AllItems.ANDESITE_ALLOY.get(), TaskType.NORMAL) + .withParent(root) + .withCriterion("0", itemGathered(AllItems.ANDESITE_ALLOY.get())) + .register(t, id + ":andesite_alloy"); + + + kineticsBranch(t, andesite_alloy); + + Advancement water_wheel = advancement("water_wheel", AllBlocks.WATER_WHEEL.get(), TaskType.NORMAL) + .withParent(andesite_alloy) + .withCriterion("0", placeBlock(AllBlocks.WATER_WHEEL.get())) + .withCriterion("1", AllTriggers.WATER_WHEEL.instance()) + .register(t, id + ":water_wheel"); + + Advancement lava_wheel = advancement("lava_wheel", Items.LAVA_BUCKET, TaskType.SECRET) + .withParent(water_wheel) + .withCriterion("0", AllTriggers.LAVA_WHEEL.instance()) + .register(t, id + ":lava_wheel"); + + Advancement millstone = kinecticAdvancement("millstone", AllBlocks.MILLSTONE, TaskType.NORMAL) + .withParent(andesite_alloy) + .register(t, id + ":millstone"); + + Advancement andesite_casing = advancement("andesite_casing", AllBlocks.ANDESITE_CASING.get(), TaskType.GOAL) + .withParent(andesite_alloy) + .withCriterion("0", itemGathered(AllBlocks.ANDESITE_CASING.get())) + .register(t, id + ":andesite_casing"); + + andesiteExpertLane(t, andesite_casing); + + Advancement drill = kinecticAdvancement("drill", AllBlocks.DRILL, TaskType.NORMAL) + .withParent(andesite_casing) + .register(t, id + ":drill"); + + Advancement press = advancement("press", AllBlocks.MECHANICAL_PRESS.get(), TaskType.MILESTONE) + .withParent(andesite_casing) + .withCriterion("0", AllTriggers.BONK.instance()) + .register(t, id + ":press"); + + Advancement rose_quartz = itemAdvancement("polished_rose_quartz", AllItems.POLISHED_ROSE_QUARTZ, TaskType.NORMAL) + .withParent(andesite_casing) + .register(t, id + ":polished_rose_quartz"); + + Advancement electron_tube = itemAdvancement("electron_tube", AllItems.ELECTRON_TUBE, TaskType.NORMAL) + .withParent(rose_quartz) + .register(t, id + ":electron_tube"); + + Advancement saw = + kinecticAdvancement("saw", AllBlocks.SAW, TaskType.NORMAL).withParent(press).register(t, id + ":saw"); + + Advancement basin = advancement("basin", AllBlocks.BASIN.get(), TaskType.NORMAL) + .withParent(press) + .withCriterion("0", placeBlock(AllBlocks.BASIN.get())) + .withCriterion("1", AllTriggers.BASIN_THROW.instance()) + .register(t, id + ":basin"); + + Advancement mixer = advancement("mixer", AllBlocks.MECHANICAL_MIXER.get(), TaskType.MILESTONE) + .withCriterion("0", placeBlock(AllBlocks.MECHANICAL_MIXER.get())) + .withCriterion("1", isPowered(AllBlocks.MECHANICAL_MIXER.get())) + .withCriterion("2", AllTriggers.MIXER_MIX.instance()) + .withParent(basin) + .register(t, id + ":mixer"); + + Advancement compact = advancement("compact", Blocks.IRON_BLOCK, TaskType.NORMAL) + .withCriterion("0", AllTriggers.PRESS_COMPACT.instance()) + .withParent(basin) + .register(t, id + ":compact"); + + Advancement brass = itemAdvancement("brass", AllItems.BRASS_INGOT, TaskType.NORMAL) + .withParent(mixer) + .register(t, id + ":brass"); + + brassAge(t, brass); + } + + void kineticsBranch(Consumer t, Advancement root) { + String id = Create.ID; + + Advancement its_alive = advancement("its_alive", AllBlocks.COGWHEEL.get(), TaskType.NORMAL) + .withParent(root) + .withCriterion("0", AllTriggers.ROTATION.instance()) + .register(t, id + ":its_alive"); + + Advancement belt = advancement("belt", AllItems.BELT_CONNECTOR.get(), TaskType.NORMAL) + .withParent(its_alive) + .withCriterion("0", AllTriggers.CONNECT_BELT.instance()) + .register(t, id + ":belt"); + + Advancement wrench = itemAdvancement("wrench", AllItems.WRENCH, TaskType.NORMAL) + .withParent(its_alive) + .register(t, id + ":wrench"); + + Advancement goggles = itemAdvancement("goggles", AllItems.GOGGLES, TaskType.NORMAL) + .withParent(its_alive) + .register(t, id + ":goggles"); + + Advancement speed_gauge = kinecticAdvancement("speed_gauge", AllBlocks.SPEED_GAUGE, TaskType.NORMAL) + .withParent(goggles) + .register(t, id + ":speed_gauge"); + + Advancement stress_gauge = kinecticAdvancement("stress_gauge", AllBlocks.STRESS_GAUGE, TaskType.NORMAL) + .withParent(goggles) + .register(t, id + ":stress_gauge"); + + Advancement shifting_gears = advancement("shifting_gears", AllBlocks.LARGE_COGWHEEL.get(), TaskType.NORMAL) + .withParent(its_alive) + .withCriterion("0", AllTriggers.SHIFTING_GEARS.instance()) + .register(t, id + ":shifting_gears"); + + Advancement overstressed = advancement("overstressed", Items.BARRIER, TaskType.SECRET) + .withParent(its_alive) + .withCriterion("0", AllTriggers.OVERSTRESSED.instance()) + .register(t, id + ":overstressed"); + + } + + void brassAge(Consumer t, Advancement root) { + String id = Create.ID; + + Advancement brass_casing = advancement("brass_casing", AllBlocks.BRASS_CASING.get(), TaskType.GOAL) + .withParent(root) + .withCriterion("0", itemGathered(AllBlocks.BRASS_CASING.get())) + .register(t, id + ":brass_casing"); + + Advancement crafter = kinecticAdvancement("crafter", AllBlocks.MECHANICAL_CRAFTER, TaskType.MILESTONE) + .withParent(brass_casing) + .register(t, id + ":crafter"); + + Advancement deployer = kinecticAdvancement("deployer", AllBlocks.DEPLOYER, TaskType.GOAL) + .withParent(brass_casing) + .register(t, id + ":deployer"); + + Advancement fist_bump = advancement("fist_bump", AllBlocks.LARGE_COGWHEEL.get(), TaskType.SECRET) + .withParent(deployer) + .withCriterion("0", AllTriggers.DEPLOYER_BOOP.instance()) + .register(t, id + ":fist_bump"); + + Advancement crushing_wheel = advancement("crushing_wheel", AllBlocks.CRUSHING_WHEEL.get(), TaskType.MILESTONE) + .withParent(crafter) + .withCriterion("0", itemGathered(AllBlocks.CRUSHING_WHEEL.get())) + .register(t, id + ":crushing_wheel"); + + Advancement chromatic_compound = + itemAdvancement("chromatic_compound", AllItems.CHROMATIC_COMPOUND, TaskType.NORMAL) + .withParent(crushing_wheel) + .register(t, id + ":chromatic_compound"); + + Advancement shadow_steel = + itemAdvancement("shadow_steel", AllItems.SHADOW_STEEL, TaskType.GOAL) + .withParent(chromatic_compound) + .register(t, id + ":shadow_steel"); + + Advancement refined_radiance = + itemAdvancement("refined_radiance", AllItems.REFINED_RADIANCE, TaskType.GOAL) + .withParent(chromatic_compound) + .register(t, id + ":refined_radiance"); + } + + private void andesiteExpertLane(Consumer t, Advancement root) { + String id = Create.ID; + + Advancement expert_lane_1 = advancement("expert_lane_1", Blocks.ANDESITE, TaskType.SILENT_GATE) + .withParent(root) + .withCriterion("0", itemGathered(AllBlocks.ANDESITE_CASING.get())) + .register(t, id + ":expert_lane_1"); + } + + // Datagen + + private static final Logger LOGGER = LogManager.getLogger(); + private static final Gson GSON = (new GsonBuilder()).setPrettyPrinting().create(); + private final DataGenerator generator; + + public CreateAdvancements(DataGenerator generatorIn) { + this.generator = generatorIn; + } + + @Override + public void act(DirectoryCache cache) throws IOException { + Path path = this.generator.getOutputFolder(); + Set set = Sets.newHashSet(); + Consumer consumer = (p_204017_3_) -> { + if (!set.add(p_204017_3_.getId())) + throw new IllegalStateException("Duplicate advancement " + p_204017_3_.getId()); + + Path path1 = getPath(path, p_204017_3_); + + try { + IDataProvider.save(GSON, cache, p_204017_3_.copy().serialize(), path1); + } catch (IOException ioexception) { + LOGGER.error("Couldn't save advancement {}", path1, ioexception); + } + }; + + register(consumer); + } + + private static Path getPath(Path pathIn, Advancement advancementIn) { + return pathIn + .resolve("data/" + advancementIn.getId().getNamespace() + "/advancements/" + + advancementIn.getId().getPath() + ".json"); + } + + @Override + public String getName() { + return "CreateAdvancements"; + } + + public PlacedBlockTrigger.Instance placeBlock(Block block) { + return PlacedBlockTrigger.Instance.placedBlock(block); + } + + public KineticBlockTrigger.Instance isPowered(Block block) { + return AllTriggers.KINETIC_BLOCK.forBlock(block); + } + + public InventoryChangeTrigger.Instance itemGathered(IItemProvider itemprovider) { + return InventoryChangeTrigger.Instance.forItems(itemprovider); + } + + static enum TaskType { + + NORMAL(FrameType.TASK, true, false, false), + MILESTONE(FrameType.TASK, true, true, false), + GOAL(FrameType.GOAL, true, true, false), + SECRET(FrameType.GOAL, true, true, true), + SILENT_GATE(FrameType.CHALLENGE, false, false, false), + + ; + + private FrameType frame; + private boolean toast; + private boolean announce; + private boolean hide; + + private TaskType(FrameType frame, boolean toast, boolean announce, boolean hide) { + this.frame = frame; + this.toast = toast; + this.announce = announce; + this.hide = hide; + } + } + + public Builder kinecticAdvancement(String name, AllBlocks block, TaskType type) { + return advancement(name, block.get(), type) + .withCriterion("0", placeBlock(block.get())) + .withCriterion("1", isPowered(block.get())); + } + + public Builder advancement(String name, IItemProvider icon, TaskType type) { + return Advancement.Builder + .builder() + .withDisplay(icon, new TranslationTextComponent(LANG + name), + new TranslationTextComponent(LANG + name + ".desc"), null, type.frame, type.toast, + type.announce, type.hide); + } + + public Builder itemAdvancement(String name, AllItems item, TaskType type) { + return advancement(name, item.get(), type).withCriterion("0", itemGathered(item.get())); + } + +} diff --git a/src/main/java/com/simibubi/create/foundation/advancement/AllTriggers.java b/src/main/java/com/simibubi/create/foundation/advancement/AllTriggers.java index cb8ae3705..99adb7a55 100644 --- a/src/main/java/com/simibubi/create/foundation/advancement/AllTriggers.java +++ b/src/main/java/com/simibubi/create/foundation/advancement/AllTriggers.java @@ -15,17 +15,27 @@ public class AllTriggers { private static List> triggers = new LinkedList<>(); - public static SandpaperUseTrigger SANDPAPER_USE = add(new SandpaperUseTrigger("sandpaper_use")); - public static SimpleTrigger DEPLOYER_BOOP = simple("deployer"); - public static SimpleTrigger ABSORBED_LIGHT = simple("light_absorbed"); - public static SimpleTrigger SPEED_READ = simple("speed_read"); - public static SimpleTrigger OVERSTRESSED = simple("overstressed"); - public static SimpleTrigger ROTATION = simple("rotation"); + public static KineticBlockTrigger KINETIC_BLOCK = add(new KineticBlockTrigger("kinetic_block")); + + public static SimpleTrigger + ROTATION = simple("rotation"), + OVERSTRESSED = simple("overstressed"), + SHIFTING_GEARS = simple("shifting_gears"), + CONNECT_BELT = simple("connect_belt"), + BONK = simple("bonk"), + WATER_WHEEL = simple("water_wheel"), + LAVA_WHEEL = simple("lava_wheel"), + DEPLOYER_BOOP = simple("deployer"), + ABSORBED_LIGHT = simple("light_absorbed"), + SPEED_READ = simple("speed_read"), + BASIN_THROW = simple("basin"), + PRESS_COMPACT = simple("compact"), + MIXER_MIX = simple("mixer"); private static SimpleTrigger simple(String id) { return add(new SimpleTrigger(id)); } - + private static > T add(T instance) { triggers.add(instance); return instance; @@ -35,19 +45,29 @@ public class AllTriggers { triggers.forEach(CriteriaTriggers::register); } - public static void triggerForNearbyPlayers(SimpleTrigger trigger, World world, BlockPos pos, int range) { + public static void triggerFor(ITriggerable trigger, PlayerEntity player) { + if (player instanceof ServerPlayerEntity) + trigger.trigger((ServerPlayerEntity) player); + } + + public static void triggerForNearbyPlayers(ITriggerable trigger, World world, BlockPos pos, int range) { triggerForNearbyPlayers(trigger, world, pos, range, player -> true); } - public static void triggerForNearbyPlayers(SimpleTrigger trigger, World world, BlockPos pos, int range, + public static void triggerForNearbyPlayers(ITriggerable trigger, World world, BlockPos pos, int range, Predicate playerFilter) { if (world == null) return; if (world.isRemote) return; - List players = - world.getEntitiesWithinAABB(ServerPlayerEntity.class, new AxisAlignedBB(pos).grow(range)); + List players = getPlayersInRange(world, pos, range); players.stream().filter(playerFilter).forEach(trigger::trigger); } + public static List getPlayersInRange(World world, BlockPos pos, int range) { + List players = + world.getEntitiesWithinAABB(ServerPlayerEntity.class, new AxisAlignedBB(pos).grow(range)); + return players; + } + } diff --git a/src/main/java/com/simibubi/create/foundation/advancement/ITriggerable.java b/src/main/java/com/simibubi/create/foundation/advancement/ITriggerable.java new file mode 100644 index 000000000..3356815d2 --- /dev/null +++ b/src/main/java/com/simibubi/create/foundation/advancement/ITriggerable.java @@ -0,0 +1,9 @@ +package com.simibubi.create.foundation.advancement; + +import net.minecraft.entity.player.ServerPlayerEntity; + +public interface ITriggerable { + + public void trigger(ServerPlayerEntity player); + +} diff --git a/src/main/java/com/simibubi/create/foundation/advancement/KineticBlockTrigger.java b/src/main/java/com/simibubi/create/foundation/advancement/KineticBlockTrigger.java new file mode 100644 index 000000000..a72bc6f78 --- /dev/null +++ b/src/main/java/com/simibubi/create/foundation/advancement/KineticBlockTrigger.java @@ -0,0 +1,76 @@ +package com.simibubi.create.foundation.advancement; + +import java.util.Arrays; +import java.util.List; +import java.util.function.Supplier; + +import com.google.gson.JsonDeserializationContext; +import com.google.gson.JsonElement; +import com.google.gson.JsonObject; +import com.google.gson.JsonSyntaxException; +import com.simibubi.create.Create; + +import net.minecraft.block.Block; +import net.minecraft.block.BlockState; +import net.minecraft.entity.player.ServerPlayerEntity; +import net.minecraft.util.JSONUtils; +import net.minecraft.util.ResourceLocation; +import net.minecraft.util.registry.Registry; + +public class KineticBlockTrigger extends CriterionTriggerBase { + + private static final ResourceLocation ID = new ResourceLocation(Create.ID, "kinetic_block"); + + public KineticBlockTrigger(String id) { + super(id); + } + + public Instance forBlock(Block block) { + return new Instance(block); + } + + @Override + @SuppressWarnings("deprecation") + public Instance deserializeInstance(JsonObject json, JsonDeserializationContext context) { + Block block = null; + if (json.has("block")) { + ResourceLocation resourcelocation = new ResourceLocation(JSONUtils.getString(json, "block")); + block = Registry.BLOCK.getValue(resourcelocation).orElseThrow(() -> { + return new JsonSyntaxException("Unknown block type '" + resourcelocation + "'"); + }); + } + + return new Instance(block); + } + + public void trigger(ServerPlayerEntity player, BlockState state) { + trigger(player, Arrays.asList(() -> state.getBlock())); + } + + public static class Instance extends CriterionTriggerBase.Instance { + private final Block block; + + public Instance(Block block) { + super(KineticBlockTrigger.ID); + this.block = block; + } + + @Override + protected boolean test(List> suppliers) { + if (suppliers.isEmpty()) + return false; + return block == suppliers.get(0).get(); + } + + @Override + @SuppressWarnings("deprecation") + public JsonElement serialize() { + JsonObject jsonobject = new JsonObject(); + if (this.block != null) + jsonobject.addProperty("block", Registry.BLOCK.getKey(this.block).toString()); + return jsonobject; + } + } + + +} diff --git a/src/main/java/com/simibubi/create/foundation/advancement/SandpaperUseTrigger.java b/src/main/java/com/simibubi/create/foundation/advancement/SandpaperUseTrigger.java deleted file mode 100644 index 24b33c26e..000000000 --- a/src/main/java/com/simibubi/create/foundation/advancement/SandpaperUseTrigger.java +++ /dev/null @@ -1,47 +0,0 @@ -package com.simibubi.create.foundation.advancement; - -import java.util.Arrays; -import java.util.List; -import java.util.function.Supplier; - -import com.google.gson.JsonDeserializationContext; -import com.google.gson.JsonObject; - -import net.minecraft.advancements.criterion.ItemPredicate; -import net.minecraft.entity.player.ServerPlayerEntity; -import net.minecraft.item.ItemStack; -import net.minecraft.util.ResourceLocation; - -public class SandpaperUseTrigger extends CriterionTriggerBase { - - public SandpaperUseTrigger(String id) { - super(id); - } - - @Override - public Instance deserializeInstance(JsonObject json, JsonDeserializationContext context) { - return new SandpaperUseTrigger.Instance(getId(), ItemPredicate.deserialize(json.get("target")),ItemPredicate.deserialize(json.get("result"))); - } - - public void trigger(ServerPlayerEntity player, ItemStack target, ItemStack result){ - trigger(player, Arrays.asList(() -> target, () -> result)); - } - - public static class Instance extends CriterionTriggerBase.Instance { - private final ItemPredicate target; - private final ItemPredicate result; - - public Instance(ResourceLocation idIn, ItemPredicate target, ItemPredicate result) { - super(idIn); - this.target = target; - this.result = result; - - } - - @Override - protected boolean test(List> suppliers) { - return this.target.test((ItemStack) suppliers.get(0).get()) && - this.result.test((ItemStack) suppliers.get(1).get()); - } - } -} diff --git a/src/main/java/com/simibubi/create/foundation/advancement/SimpleTrigger.java b/src/main/java/com/simibubi/create/foundation/advancement/SimpleTrigger.java index e9df1c110..375bdb3a2 100644 --- a/src/main/java/com/simibubi/create/foundation/advancement/SimpleTrigger.java +++ b/src/main/java/com/simibubi/create/foundation/advancement/SimpleTrigger.java @@ -9,7 +9,7 @@ import com.google.gson.JsonObject; import net.minecraft.entity.player.ServerPlayerEntity; import net.minecraft.util.ResourceLocation; -public class SimpleTrigger extends CriterionTriggerBase { +public class SimpleTrigger extends CriterionTriggerBase implements ITriggerable { public SimpleTrigger(String id) { super(id); @@ -23,6 +23,10 @@ public class SimpleTrigger extends CriterionTriggerBase public void trigger(ServerPlayerEntity player){ super.trigger(player, null); } + + public Instance instance() { + return new Instance(getId()); + } public static class Instance extends CriterionTriggerBase.Instance { diff --git a/src/main/java/com/simibubi/create/foundation/utility/data/Generator.java b/src/main/java/com/simibubi/create/foundation/utility/data/Generator.java index 2a0f91586..4c95945fe 100644 --- a/src/main/java/com/simibubi/create/foundation/utility/data/Generator.java +++ b/src/main/java/com/simibubi/create/foundation/utility/data/Generator.java @@ -1,5 +1,7 @@ package com.simibubi.create.foundation.utility.data; +import com.simibubi.create.data.CreateAdvancements; + import net.minecraft.data.DataGenerator; import net.minecraftforge.eventbus.api.SubscribeEvent; import net.minecraftforge.fml.common.Mod; @@ -11,9 +13,9 @@ public class Generator { @SubscribeEvent public static void gatherData(GatherDataEvent event){ DataGenerator gen = event.getGenerator(); - //gen.addProvider(AllSoundEvents.CUCKOO_PIG); gen.addProvider(new AllBlocksTagProvider(gen)); gen.addProvider(new AllItemsTagProvider(gen)); + gen.addProvider(new CreateAdvancements(gen)); } } diff --git a/src/main/java/com/simibubi/create/modules/contraptions/base/KineticTileEntity.java b/src/main/java/com/simibubi/create/modules/contraptions/base/KineticTileEntity.java index 21b8f0e60..f0804b5e4 100644 --- a/src/main/java/com/simibubi/create/modules/contraptions/base/KineticTileEntity.java +++ b/src/main/java/com/simibubi/create/modules/contraptions/base/KineticTileEntity.java @@ -166,9 +166,13 @@ public abstract class KineticTileEntity extends SmartTileEntity public void onSpeedChanged(float previousSpeed) { boolean fromOrToZero = (previousSpeed == 0) != (getSpeed() == 0); boolean directionSwap = !fromOrToZero && Math.signum(previousSpeed) != Math.signum(getSpeed()); - if (fromOrToZero || directionSwap) { + if (fromOrToZero || directionSwap) flickerTally = getFlickerScore() + 5; - } + + if (fromOrToZero && previousSpeed == 0 && !world.isRemote) + AllTriggers + .getPlayersInRange(world, pos, 4) + .forEach(p -> AllTriggers.KINETIC_BLOCK.trigger(p, getBlockState())); } @Override @@ -368,8 +372,7 @@ public abstract class KineticTileEntity extends SmartTileEntity } @Override - public void addBehaviours(List behaviours) { - } + public void addBehaviours(List behaviours) {} @Override public boolean hasFastRenderer() { @@ -382,8 +385,9 @@ public abstract class KineticTileEntity extends SmartTileEntity if (overStressed && AllConfigs.CLIENT.enableOverstressedTooltip.get()) { tooltip.add(spacing + GOLD + Lang.translate("gui.stress_gauge.overstressed")); - String hint = Lang.translate("gui.contraptions.network_overstressed", - I18n.format(getBlockState().getBlock().getTranslationKey())); + String hint = Lang + .translate("gui.contraptions.network_overstressed", + I18n.format(getBlockState().getBlock().getTranslationKey())); List cutString = TooltipHelper.cutString(spacing + hint, GRAY, TextFormatting.WHITE); for (int i = 0; i < cutString.size(); i++) tooltip.add((i == 0 ? "" : spacing) + cutString.get(i)); @@ -392,8 +396,9 @@ public abstract class KineticTileEntity extends SmartTileEntity if (notFastEnough) { tooltip.add(spacing + GOLD + Lang.translate("tooltip.speedRequirement")); - String hint = Lang.translate("gui.contraptions.not_fast_enough", - I18n.format(getBlockState().getBlock().getTranslationKey())); + String hint = Lang + .translate("gui.contraptions.not_fast_enough", + I18n.format(getBlockState().getBlock().getTranslationKey())); List cutString = TooltipHelper.cutString(spacing + hint, GRAY, TextFormatting.WHITE); for (int i = 0; i < cutString.size(); i++) tooltip.add((i == 0 ? "" : spacing) + cutString.get(i)); @@ -417,10 +422,14 @@ public abstract class KineticTileEntity extends SmartTileEntity String stressString = spacing + "%s%s" + Lang.translate("generic.unit.stress") + " " + TextFormatting.DARK_GRAY + "%s"; - tooltip.add(String.format(stressString, TextFormatting.AQUA, IHaveGoggleInformation.format(stressAtBase), - Lang.translate("gui.goggles.base_value"))); - tooltip.add(String.format(stressString, TextFormatting.GRAY, IHaveGoggleInformation.format(stressTotal), - Lang.translate("gui.goggles.at_current_speed"))); + tooltip + .add(String + .format(stressString, TextFormatting.AQUA, IHaveGoggleInformation.format(stressAtBase), + Lang.translate("gui.goggles.base_value"))); + tooltip + .add(String + .format(stressString, TextFormatting.GRAY, IHaveGoggleInformation.format(stressTotal), + Lang.translate("gui.goggles.at_current_speed"))); added = true; } diff --git a/src/main/java/com/simibubi/create/modules/contraptions/components/press/MechanicalPressTileEntity.java b/src/main/java/com/simibubi/create/modules/contraptions/components/press/MechanicalPressTileEntity.java index e7e48ee0f..5f7e5529b 100644 --- a/src/main/java/com/simibubi/create/modules/contraptions/components/press/MechanicalPressTileEntity.java +++ b/src/main/java/com/simibubi/create/modules/contraptions/components/press/MechanicalPressTileEntity.java @@ -7,6 +7,7 @@ import java.util.Optional; import com.simibubi.create.AllRecipes; import com.simibubi.create.AllSoundEvents; import com.simibubi.create.AllTileEntities; +import com.simibubi.create.foundation.advancement.AllTriggers; import com.simibubi.create.foundation.item.ItemHelper; import com.simibubi.create.foundation.utility.VecHelper; import com.simibubi.create.modules.contraptions.processing.BasinOperatingTileEntity; @@ -163,8 +164,10 @@ public class MechanicalPressTileEntity extends BasinOperatingTileEntity { pressedItems.add(itemEntity.getItem()); sendData(); Optional recipe = getRecipe(itemEntity.getItem()); - if (recipe.isPresent()) + if (recipe.isPresent()) { InWorldProcessing.applyRecipeOn(itemEntity, recipe.get()); + AllTriggers.triggerForNearbyPlayers(AllTriggers.BONK, world, pos, 4); + } } } } diff --git a/src/main/java/com/simibubi/create/modules/contraptions/components/waterwheel/WaterWheelBlock.java b/src/main/java/com/simibubi/create/modules/contraptions/components/waterwheel/WaterWheelBlock.java index dbb8723ae..09800ca42 100644 --- a/src/main/java/com/simibubi/create/modules/contraptions/components/waterwheel/WaterWheelBlock.java +++ b/src/main/java/com/simibubi/create/modules/contraptions/components/waterwheel/WaterWheelBlock.java @@ -2,11 +2,13 @@ package com.simibubi.create.modules.contraptions.components.waterwheel; import com.simibubi.create.AllBlocks; import com.simibubi.create.config.AllConfigs; +import com.simibubi.create.foundation.advancement.AllTriggers; import com.simibubi.create.foundation.block.ITE; import com.simibubi.create.modules.contraptions.base.HorizontalKineticBlock; import net.minecraft.block.BlockState; import net.minecraft.block.Blocks; +import net.minecraft.fluid.Fluids; import net.minecraft.fluid.IFluidState; import net.minecraft.item.BlockItemUseContext; import net.minecraft.tileentity.TileEntity; @@ -109,6 +111,12 @@ public class WaterWheelBlock extends HorizontalKineticBlock implements ITE 0 ^ !clockwise ? -flow.y * clockwiseMultiplier : -flow.y; } + + if (te.getSpeed() == 0 && flowStrength != 0 && !world.isRemote) { + AllTriggers.triggerForNearbyPlayers(AllTriggers.WATER_WHEEL, world, pos, 5); + if (fluid.getFluid() == Fluids.FLOWING_LAVA ||fluid.getFluid() == Fluids.LAVA) + AllTriggers.triggerForNearbyPlayers(AllTriggers.LAVA_WHEEL, world, pos, 5); + } te.setFlow(f, (float) (flowStrength * AllConfigs.SERVER.kinetics.waterWheelSpeed.get() / 2f)); }); @@ -125,8 +133,8 @@ public class WaterWheelBlock extends HorizontalKineticBlock implements ITE { if (insertItem.isEmpty()) { itemEntity.remove(); + + if (!itemEntity.world.isRemote) + AllTriggers + .triggerForNearbyPlayers(AllTriggers.BASIN_THROW, itemEntity.world, + itemEntity.getPosition(), 3); return; } diff --git a/src/main/java/com/simibubi/create/modules/contraptions/processing/BasinOperatingTileEntity.java b/src/main/java/com/simibubi/create/modules/contraptions/processing/BasinOperatingTileEntity.java index e2d21cbe1..e09fa863b 100644 --- a/src/main/java/com/simibubi/create/modules/contraptions/processing/BasinOperatingTileEntity.java +++ b/src/main/java/com/simibubi/create/modules/contraptions/processing/BasinOperatingTileEntity.java @@ -5,6 +5,9 @@ import java.util.List; import java.util.Optional; import java.util.stream.Collectors; +import com.simibubi.create.AllTileEntities; +import com.simibubi.create.foundation.advancement.AllTriggers; +import com.simibubi.create.foundation.advancement.SimpleTrigger; import com.simibubi.create.foundation.behaviour.base.TileEntityBehaviour; import com.simibubi.create.foundation.behaviour.simple.DeferralBehaviour; import com.simibubi.create.foundation.utility.recipe.RecipeFinder; @@ -149,6 +152,13 @@ public abstract class BasinOperatingTileEntity extends KineticTileEntity { // something wasn't found return; } + + if (!world.isRemote) { + SimpleTrigger trigger = AllTriggers.MIXER_MIX; + if (getType() == AllTileEntities.MECHANICAL_PRESS.type) + trigger = AllTriggers.PRESS_COMPACT; + AllTriggers.triggerForNearbyPlayers(trigger, world, pos, 4); + } ItemHandlerHelper.insertItemStacked(outputs, lastRecipe.getRecipeOutput().copy(), false); containers.forEach(stack -> ItemHandlerHelper.insertItemStacked(outputs, stack, false)); diff --git a/src/main/java/com/simibubi/create/modules/contraptions/relays/belt/item/BeltConnectorItem.java b/src/main/java/com/simibubi/create/modules/contraptions/relays/belt/item/BeltConnectorItem.java index 5adcbd64d..92f64ae5f 100644 --- a/src/main/java/com/simibubi/create/modules/contraptions/relays/belt/item/BeltConnectorItem.java +++ b/src/main/java/com/simibubi/create/modules/contraptions/relays/belt/item/BeltConnectorItem.java @@ -5,6 +5,7 @@ import java.util.List; import com.simibubi.create.AllBlocks; import com.simibubi.create.config.AllConfigs; +import com.simibubi.create.foundation.advancement.AllTriggers; import com.simibubi.create.foundation.item.IAddedByOther; import com.simibubi.create.modules.contraptions.base.KineticTileEntity; import com.simibubi.create.modules.contraptions.relays.belt.BeltBlock; @@ -71,9 +72,9 @@ public class BeltConnectorItem extends BlockItem implements IAddedByOther { if (!canConnect(world, firstPulley, pos)) return ActionResultType.FAIL; - if (firstPulley != null && !firstPulley.equals(pos)) { + if (firstPulley != null && !firstPulley.equals(pos) && !world.isRemote) { createBelts(world, firstPulley, pos); - + AllTriggers.triggerFor(AllTriggers.CONNECT_BELT, context.getPlayer()); if (!context.getPlayer().isCreative()) context.getItem().shrink(1); } diff --git a/src/main/java/com/simibubi/create/modules/contraptions/relays/elementary/CogwheelBlockItem.java b/src/main/java/com/simibubi/create/modules/contraptions/relays/elementary/CogwheelBlockItem.java index ef1f12939..f3b8b94eb 100644 --- a/src/main/java/com/simibubi/create/modules/contraptions/relays/elementary/CogwheelBlockItem.java +++ b/src/main/java/com/simibubi/create/modules/contraptions/relays/elementary/CogwheelBlockItem.java @@ -1,10 +1,13 @@ package com.simibubi.create.modules.contraptions.relays.elementary; import com.simibubi.create.AllBlocks; +import com.simibubi.create.foundation.advancement.AllTriggers; +import com.simibubi.create.foundation.utility.Iterate; import com.simibubi.create.foundation.utility.VecHelper; import net.minecraft.block.Block; import net.minecraft.block.BlockState; +import net.minecraft.entity.player.PlayerEntity; import net.minecraft.item.BlockItem; import net.minecraft.item.BlockItemUseContext; import net.minecraft.util.ActionResultType; @@ -13,6 +16,7 @@ import net.minecraft.util.Direction.Axis; import net.minecraft.util.Direction.AxisDirection; import net.minecraft.util.math.BlockPos; import net.minecraft.util.math.Vec3d; +import net.minecraft.world.World; public class CogwheelBlockItem extends BlockItem { @@ -54,8 +58,8 @@ public class CogwheelBlockItem extends BlockItem { hitVec = hitVec .mul(new Vec3d(Direction.getFacingFromAxis(AxisDirection.POSITIVE, offsetAxis).getDirectionVec())); - BlockPos correctPos = context.getPos().add(Math.signum(hitVec.x), Math.signum(hitVec.y), - Math.signum(hitVec.z)); + BlockPos correctPos = + context.getPos().add(Math.signum(hitVec.x), Math.signum(hitVec.y), Math.signum(hitVec.z)); if (context.getWorld().getBlockState(correctPos).getMaterial().isReplaceable()) context = BlockItemUseContext.func_221536_a(context, correctPos, largeOnLarge ? face @@ -67,4 +71,41 @@ public class CogwheelBlockItem extends BlockItem { return super.tryPlace(context); } + @Override + // Trigger cogwheel criterion + protected boolean placeBlock(BlockItemUseContext context, BlockState state) { + World world = context.getWorld(); + PlayerEntity player = context.getPlayer(); + + if (!world.isRemote && player != null) { + Axis axis = state.get(CogWheelBlock.AXIS); + for (Axis perpendicular1 : Iterate.axes) { + if (perpendicular1 == axis) + continue; + Direction d1 = Direction.getFacingFromAxis(AxisDirection.POSITIVE, perpendicular1); + for (Axis perpendicular2 : Iterate.axes) { + if (perpendicular1 == perpendicular2) + continue; + if (axis == perpendicular2) + continue; + Direction d2 = Direction.getFacingFromAxis(AxisDirection.POSITIVE, perpendicular2); + for (int offset1 : Iterate.positiveAndNegative) { + for (int offset2 : Iterate.positiveAndNegative) { + BlockPos connectedPos = context.getPos().offset(d1, offset1).offset(d2, offset2); + BlockState blockState = world.getBlockState(connectedPos); + if (!(blockState.getBlock() instanceof CogWheelBlock)) + continue; + if (blockState.get(CogWheelBlock.AXIS) != axis) + continue; + if (AllBlocks.LARGE_COGWHEEL.typeOf(blockState) == large) + continue; + AllTriggers.triggerFor(AllTriggers.SHIFTING_GEARS, player); + } + } + } + } + } + return super.placeBlock(context, state); + } + } diff --git a/src/main/java/com/simibubi/create/modules/curiosities/tools/SandPaperItem.java b/src/main/java/com/simibubi/create/modules/curiosities/tools/SandPaperItem.java index b80f3c34b..6747f1f5a 100644 --- a/src/main/java/com/simibubi/create/modules/curiosities/tools/SandPaperItem.java +++ b/src/main/java/com/simibubi/create/modules/curiosities/tools/SandPaperItem.java @@ -1,10 +1,8 @@ package com.simibubi.create.modules.curiosities.tools; -import com.simibubi.create.foundation.advancement.AllTriggers; import com.simibubi.create.foundation.block.render.CustomRenderedItemModel; import com.simibubi.create.foundation.item.IHaveCustomItemModel; import com.simibubi.create.foundation.utility.VecHelper; -import com.simibubi.create.modules.contraptions.components.deployer.DeployerFakePlayer; import com.simibubi.create.modules.curiosities.tools.SandPaperItemRenderer.SandPaperModel; import net.minecraft.client.renderer.model.IBakedModel; @@ -12,7 +10,6 @@ import net.minecraft.enchantment.Enchantment; import net.minecraft.entity.LivingEntity; import net.minecraft.entity.item.ItemEntity; import net.minecraft.entity.player.PlayerEntity; -import net.minecraft.entity.player.ServerPlayerEntity; import net.minecraft.item.Item; import net.minecraft.item.ItemStack; import net.minecraft.item.ItemUseContext; @@ -31,6 +28,7 @@ import net.minecraft.util.math.Vec3d; import net.minecraft.world.World; import net.minecraftforge.api.distmarker.Dist; import net.minecraftforge.api.distmarker.OnlyIn; +import net.minecraftforge.common.util.FakePlayer; public class SandPaperItem extends Item implements IHaveCustomItemModel { @@ -136,11 +134,9 @@ public class SandPaperItem extends Item implements IHaveCustomItemModel { } if (!polished.isEmpty()) { - if (player instanceof DeployerFakePlayer) { + if (player instanceof FakePlayer) { player.dropItem(polished, false, false); } else { - AllTriggers.SANDPAPER_USE.trigger((ServerPlayerEntity) player, toPolish, polished); - player.inventory.placeItemBackInInventory(worldIn, polished); } } diff --git a/src/main/java/com/simibubi/create/modules/logistics/block/inventories/CrateBlock.java b/src/main/java/com/simibubi/create/modules/logistics/block/inventories/CrateBlock.java new file mode 100644 index 000000000..bb355a6c4 --- /dev/null +++ b/src/main/java/com/simibubi/create/modules/logistics/block/inventories/CrateBlock.java @@ -0,0 +1,81 @@ +package com.simibubi.create.modules.logistics.block.inventories; + +import com.simibubi.create.foundation.block.ProperDirectionalBlock; +import com.simibubi.create.foundation.utility.AllShapes; + +import net.minecraft.block.Block; +import net.minecraft.block.BlockState; +import net.minecraft.item.BlockItemUseContext; +import net.minecraft.state.BooleanProperty; +import net.minecraft.state.StateContainer.Builder; +import net.minecraft.util.Direction; +import net.minecraft.util.math.BlockPos; +import net.minecraft.util.math.shapes.ISelectionContext; +import net.minecraft.util.math.shapes.VoxelShape; +import net.minecraft.world.IBlockReader; +import net.minecraft.world.IWorld; +import net.minecraft.world.World; + +public class CrateBlock extends ProperDirectionalBlock { + + public static final BooleanProperty DOUBLE = BooleanProperty.create("double"); + + public CrateBlock(Properties p_i48415_1_) { + super(p_i48415_1_); + setDefaultState(getDefaultState().with(FACING, Direction.UP).with(DOUBLE, false)); + } + + @Override + public VoxelShape getShape(BlockState state, IBlockReader worldIn, BlockPos pos, ISelectionContext context) { + return AllShapes.CRATE_BLOCK_SHAPE; + } + + @Override + public BlockState updatePostPlacement(BlockState stateIn, Direction facing, BlockState facingState, IWorld worldIn, + BlockPos currentPos, BlockPos facingPos) { + + boolean isDouble = stateIn.get(DOUBLE); + Direction blockFacing = stateIn.get(FACING); + boolean isFacingOther = facingState.getBlock() == this && facingState.get(DOUBLE) + && facingState.get(FACING) == facing.getOpposite(); + + if (!isDouble) { + if (!isFacingOther) + return stateIn; + return stateIn.with(DOUBLE, true).with(FACING, facing); + } + + if (facing != blockFacing) + return stateIn; + if (!isFacingOther) + return stateIn.with(DOUBLE, false); + + return stateIn; + } + + @Override + public BlockState getStateForPlacement(BlockItemUseContext context) { + BlockPos pos = context.getPos(); + World world = context.getWorld(); + + if (!context.isPlacerSneaking()) { + for (Direction d : Direction.values()) { + BlockState state = world.getBlockState(pos.offset(d)); + if (state.getBlock() == this && !state.get(DOUBLE)) + return getDefaultState().with(FACING, d).with(DOUBLE, true); + } + } + + Direction placedOnFace = context.getFace().getOpposite(); + BlockState state = world.getBlockState(pos.offset(placedOnFace)); + if (state.getBlock() == this && !state.get(DOUBLE)) + return getDefaultState().with(FACING, placedOnFace).with(DOUBLE, true); + return getDefaultState(); + } + + @Override + protected void fillStateContainer(Builder builder) { + super.fillStateContainer(builder.add(DOUBLE)); + } + +} diff --git a/src/main/java/com/simibubi/create/modules/logistics/block/inventories/FlexcrateBlock.java b/src/main/java/com/simibubi/create/modules/logistics/block/inventories/FlexcrateBlock.java index bf70659a3..b5371a0b1 100644 --- a/src/main/java/com/simibubi/create/modules/logistics/block/inventories/FlexcrateBlock.java +++ b/src/main/java/com/simibubi/create/modules/logistics/block/inventories/FlexcrateBlock.java @@ -1,74 +1,36 @@ package com.simibubi.create.modules.logistics.block.inventories; import com.simibubi.create.AllBlocks; -import com.simibubi.create.foundation.block.ProperDirectionalBlock; import com.simibubi.create.foundation.item.ItemHelper; -import com.simibubi.create.foundation.utility.AllShapes; -import net.minecraft.block.Block; import net.minecraft.block.BlockState; import net.minecraft.block.Blocks; import net.minecraft.entity.player.PlayerEntity; import net.minecraft.entity.player.ServerPlayerEntity; -import net.minecraft.item.BlockItemUseContext; import net.minecraft.item.ItemStack; -import net.minecraft.state.BooleanProperty; -import net.minecraft.state.StateContainer.Builder; import net.minecraft.tileentity.TileEntity; -import net.minecraft.util.Direction; import net.minecraft.util.Direction.AxisDirection; import net.minecraft.util.Hand; import net.minecraft.util.math.BlockPos; import net.minecraft.util.math.BlockRayTraceResult; -import net.minecraft.util.math.shapes.ISelectionContext; -import net.minecraft.util.math.shapes.VoxelShape; import net.minecraft.world.IBlockReader; -import net.minecraft.world.IWorld; import net.minecraft.world.World; import net.minecraftforge.fml.network.NetworkHooks; -public class FlexcrateBlock extends ProperDirectionalBlock { - - public static final BooleanProperty DOUBLE = BooleanProperty.create("double"); +public class FlexcrateBlock extends CrateBlock { public FlexcrateBlock() { super(Properties.from(Blocks.ANDESITE)); - setDefaultState(getDefaultState().with(FACING, Direction.UP).with(DOUBLE, false)); - } - - @Override - public VoxelShape getShape(BlockState state, IBlockReader worldIn, BlockPos pos, ISelectionContext context) { - return AllShapes.CRATE_BLOCK_SHAPE; - } - - @Override - protected void fillStateContainer(Builder builder) { - super.fillStateContainer(builder.add(DOUBLE)); } @Override public boolean hasTileEntity(BlockState state) { return true; } - + @Override - public BlockState getStateForPlacement(BlockItemUseContext context) { - BlockPos pos = context.getPos(); - World world = context.getWorld(); - - if (!context.isPlacerSneaking()) { - for (Direction d : Direction.values()) { - BlockState state = world.getBlockState(pos.offset(d)); - if (AllBlocks.FLEXCRATE.typeOf(state) && !state.get(DOUBLE)) - return getDefaultState().with(FACING, d).with(DOUBLE, true); - } - } - - Direction placedOnFace = context.getFace().getOpposite(); - BlockState state = world.getBlockState(pos.offset(placedOnFace)); - if (AllBlocks.FLEXCRATE.typeOf(state) && !state.get(DOUBLE)) - return getDefaultState().with(FACING, placedOnFace).with(DOUBLE, true); - return getDefaultState(); + public TileEntity createTileEntity(BlockState state, IBlockReader world) { + return new FlexcrateTileEntity(); } @Override @@ -93,29 +55,6 @@ public class FlexcrateBlock extends ProperDirectionalBlock { } } - @Override - public BlockState updatePostPlacement(BlockState stateIn, Direction facing, BlockState facingState, IWorld worldIn, - BlockPos currentPos, BlockPos facingPos) { - - boolean isDouble = stateIn.get(DOUBLE); - Direction blockFacing = stateIn.get(FACING); - boolean isFacingOther = AllBlocks.FLEXCRATE.typeOf(facingState) && facingState.get(DOUBLE) - && facingState.get(FACING) == facing.getOpposite(); - - if (!isDouble) { - if (!isFacingOther) - return stateIn; - return stateIn.with(DOUBLE, true).with(FACING, facing); - } - - if (facing != blockFacing) - return stateIn; - if (!isFacingOther) - return stateIn.with(DOUBLE, false); - - return stateIn; - } - @Override public boolean onBlockActivated(BlockState state, World worldIn, BlockPos pos, PlayerEntity player, Hand handIn, BlockRayTraceResult hit) { @@ -133,11 +72,6 @@ public class FlexcrateBlock extends ProperDirectionalBlock { } } - @Override - public TileEntity createTileEntity(BlockState state, IBlockReader world) { - return new FlexcrateTileEntity(); - } - public static void splitCrate(World world, BlockPos pos) { BlockState state = world.getBlockState(pos); if (!AllBlocks.FLEXCRATE.typeOf(state)) diff --git a/src/main/java/com/simibubi/create/modules/schematics/block/CreativeCrateBlock.java b/src/main/java/com/simibubi/create/modules/schematics/block/CreativeCrateBlock.java deleted file mode 100644 index b8a328bfe..000000000 --- a/src/main/java/com/simibubi/create/modules/schematics/block/CreativeCrateBlock.java +++ /dev/null @@ -1,36 +0,0 @@ -package com.simibubi.create.modules.schematics.block; - -import com.simibubi.create.foundation.utility.AllShapes; - -import net.minecraft.block.Block; -import net.minecraft.block.BlockState; -import net.minecraft.block.material.Material; -import net.minecraft.item.ItemGroup; -import net.minecraft.item.ItemStack; -import net.minecraft.util.NonNullList; -import net.minecraft.util.math.BlockPos; -import net.minecraft.util.math.shapes.ISelectionContext; -import net.minecraft.util.math.shapes.VoxelShape; -import net.minecraft.world.IBlockReader; - -public class CreativeCrateBlock extends Block { - - public CreativeCrateBlock() { - super(Properties.create(Material.WOOD)); - } - - @Override - public boolean isSolid(BlockState state) { - return false; - } - - @Override - public void fillItemGroup(ItemGroup group, NonNullList items) { - } - - @Override - public VoxelShape getShape(BlockState state, IBlockReader worldIn, BlockPos pos, ISelectionContext context) { - return AllShapes.CRATE_BLOCK_SHAPE; - } - -} diff --git a/src/main/resources/assets/create/blockstates/creative_crate.json b/src/main/resources/assets/create/blockstates/creative_crate.json index e2e554c11..e8c3b0338 100644 --- a/src/main/resources/assets/create/blockstates/creative_crate.json +++ b/src/main/resources/assets/create/blockstates/creative_crate.json @@ -1,6 +1,17 @@ { - "forgemarker": 1, "variants": { - "": { "model": "create:block/creative_crate" } + "double=true,facing=up": { "model": "create:block/crate/creative/double_bottom" }, + "double=true,facing=down": { "model": "create:block/crate/creative/double_top" }, + "double=true,facing=west": { "model": "create:block/crate/creative/double_left", "y": 90 }, + "double=true,facing=east": { "model": "create:block/crate/creative/double_right", "y": 90 }, + "double=true,facing=north": { "model": "create:block/crate/creative/double_right" }, + "double=true,facing=south": { "model": "create:block/crate/creative/double_left" }, + + "double=false,facing=up": { "model": "create:block/crate/creative/single" }, + "double=false,facing=down": { "model": "create:block/crate/creative/single" }, + "double=false,facing=west": { "model": "create:block/crate/creative/single" }, + "double=false,facing=east": { "model": "create:block/crate/creative/single" }, + "double=false,facing=north": { "model": "create:block/crate/creative/single" }, + "double=false,facing=south": { "model": "create:block/crate/creative/single" } } -} +} \ No newline at end of file diff --git a/src/main/resources/assets/create/blockstates/filtered_crate.json b/src/main/resources/assets/create/blockstates/filtered_crate.json new file mode 100644 index 000000000..4a297e253 --- /dev/null +++ b/src/main/resources/assets/create/blockstates/filtered_crate.json @@ -0,0 +1,17 @@ +{ + "variants": { + "double=true,facing=up": { "model": "create:block/crate/copper/double_bottom" }, + "double=true,facing=down": { "model": "create:block/crate/copper/double_top" }, + "double=true,facing=west": { "model": "create:block/crate/copper/double_left", "y": 90 }, + "double=true,facing=east": { "model": "create:block/crate/copper/double_right", "y": 90 }, + "double=true,facing=north": { "model": "create:block/crate/copper/double_right" }, + "double=true,facing=south": { "model": "create:block/crate/copper/double_left" }, + + "double=false,facing=up": { "model": "create:block/crate/copper/single" }, + "double=false,facing=down": { "model": "create:block/crate/copper/single" }, + "double=false,facing=west": { "model": "create:block/crate/copper/single" }, + "double=false,facing=east": { "model": "create:block/crate/copper/single" }, + "double=false,facing=north": { "model": "create:block/crate/copper/single" }, + "double=false,facing=south": { "model": "create:block/crate/copper/single" } + } +} \ No newline at end of file diff --git a/src/main/resources/assets/create/blockstates/flexcrate.json b/src/main/resources/assets/create/blockstates/flexcrate.json index cb94c53e6..887558a53 100644 --- a/src/main/resources/assets/create/blockstates/flexcrate.json +++ b/src/main/resources/assets/create/blockstates/flexcrate.json @@ -1,17 +1,17 @@ { "variants": { - "double=true,facing=up": { "model": "create:block/flexcrate/double_bottom" }, - "double=true,facing=down": { "model": "create:block/flexcrate/double_top" }, - "double=true,facing=west": { "model": "create:block/flexcrate/double_left", "y": 90 }, - "double=true,facing=east": { "model": "create:block/flexcrate/double_right", "y": 90 }, - "double=true,facing=north": { "model": "create:block/flexcrate/double_right" }, - "double=true,facing=south": { "model": "create:block/flexcrate/double_left" }, + "double=true,facing=up": { "model": "create:block/crate/brass/double_bottom" }, + "double=true,facing=down": { "model": "create:block/crate/brass/double_top" }, + "double=true,facing=west": { "model": "create:block/crate/brass/double_left", "y": 90 }, + "double=true,facing=east": { "model": "create:block/crate/brass/double_right", "y": 90 }, + "double=true,facing=north": { "model": "create:block/crate/brass/double_right" }, + "double=true,facing=south": { "model": "create:block/crate/brass/double_left" }, - "double=false,facing=up": { "model": "create:block/flexcrate/single" }, - "double=false,facing=down": { "model": "create:block/flexcrate/single" }, - "double=false,facing=west": { "model": "create:block/flexcrate/single" }, - "double=false,facing=east": { "model": "create:block/flexcrate/single" }, - "double=false,facing=north": { "model": "create:block/flexcrate/single" }, - "double=false,facing=south": { "model": "create:block/flexcrate/single" } + "double=false,facing=up": { "model": "create:block/crate/brass/single" }, + "double=false,facing=down": { "model": "create:block/crate/brass/single" }, + "double=false,facing=west": { "model": "create:block/crate/brass/single" }, + "double=false,facing=east": { "model": "create:block/crate/brass/single" }, + "double=false,facing=north": { "model": "create:block/crate/brass/single" }, + "double=false,facing=south": { "model": "create:block/crate/brass/single" } } } \ No newline at end of file diff --git a/src/main/resources/assets/create/blockstates/warehouse_crate.json b/src/main/resources/assets/create/blockstates/warehouse_crate.json new file mode 100644 index 000000000..0d6635db5 --- /dev/null +++ b/src/main/resources/assets/create/blockstates/warehouse_crate.json @@ -0,0 +1,17 @@ +{ + "variants": { + "double=true,facing=up": { "model": "create:block/crate/andesite/double_bottom" }, + "double=true,facing=down": { "model": "create:block/crate/andesite/double_top" }, + "double=true,facing=west": { "model": "create:block/crate/andesite/double_left", "y": 90 }, + "double=true,facing=east": { "model": "create:block/crate/andesite/double_right", "y": 90 }, + "double=true,facing=north": { "model": "create:block/crate/andesite/double_right" }, + "double=true,facing=south": { "model": "create:block/crate/andesite/double_left" }, + + "double=false,facing=up": { "model": "create:block/crate/andesite/single" }, + "double=false,facing=down": { "model": "create:block/crate/andesite/single" }, + "double=false,facing=west": { "model": "create:block/crate/andesite/single" }, + "double=false,facing=east": { "model": "create:block/crate/andesite/single" }, + "double=false,facing=north": { "model": "create:block/crate/andesite/single" }, + "double=false,facing=south": { "model": "create:block/crate/andesite/single" } + } +} \ No newline at end of file diff --git a/src/main/resources/assets/create/lang/en_us.json b/src/main/resources/assets/create/lang/en_us.json index 9afcf6b02..b6bd3b61f 100644 --- a/src/main/resources/assets/create/lang/en_us.json +++ b/src/main/resources/assets/create/lang/en_us.json @@ -131,7 +131,10 @@ "block.create.contact": "Redstone Contact", "block.create.redstone_bridge": "Redstone Link", "block.create.stockswitch": "Stockpile Switch", + "block.create.warehouse_crate": "Warehouse Crate", "block.create.flexcrate": "Adjustable Crate", + "block.create.filtered_crate": "Filtered Crate", + "block.create.creative_crate": "The Endless Crate", "block.create.extractor": "Extractor", "block.create.belt_funnel": "Funnel", "block.create.linked_extractor": "Linked Extractor", @@ -256,7 +259,6 @@ "block.create.schematicannon": "Schematicannon", "block.create.schematic_table": "Schematic Table", - "block.create.creative_crate": "Schematicannon Creatifier", "block.create.cocoa_log": "Cocoa Jungle Log", @@ -272,7 +274,6 @@ "death.attack.create.drill": "%1$s was impaled by Mechanical Drill", "death.attack.create.saw": "%1$s got cut in half by Mechanical Saw", "create.block.deployer.damage_source_name": "a rogue Deployer", - "death.attack.create.curse_polish": "%1$s tried to polish a cursed item", "death.attack.create.cuckoo_clock_explosion": "%1$s was blown up by tampered cuckoo clock", "create.recipe.crushing": "Crushing", @@ -628,47 +629,77 @@ "create.command.killTPSCommand.status.usage.1": "[Create]: use /killtps start to artificially slow down the server tick", "create.command.killTPSCommand.argument.tickTime": "tickTime", - "advancement.create:root": "In the beginning, let's Create!", - "advancement.create:root.desc": "It's time to start building some amazing Contraptions!", - "advancement.create:andesite_alloy": "Alliterations Aplenty", - "advancement.create:andesite_alloy.desc": "Create's materials have weird names, Andesite Alloy is one of them.", - "advancement.create:andesite_casing": "The Andesite Age ", - "advancement.create:andesite_casing.desc": "Use some Andesite, Meta, and Wood to create a basic Casing.", - "advancement.create:crushing_wheel": "A Pair of Giants", - "advancement.create:crushing_wheel.desc": "Create some Crushing Wheels to break down materials.", - "advancement.create:rotation": "It's Alive!", - "advancement.create:rotation.desc": "Watch your first kinetic component spin.", - "advancement.create:overstressed": "Overstressed", - "advancement.create:overstressed.desc": "Experience the laws of physics firsthand.", - "advancement.create:sand_paper": "Power Polish", - "advancement.create:sand_paper.desc": "Create some Sand Paper to make things pretty.", - "advancement.create:polished_rose_quartz": "Pink Diamonds", - "advancement.create:polished_rose_quartz.desc": "Polish Rose Quartz until you can see through it.", - "advancement.create:sand_paper_secret": "9001 Grit Sand Paper", - "advancement.create:sand_paper_secret.desc": "Use your Sand Paper to sand some Sand Paper.", - "advancement.create:press": "'Bonk!'", - "advancement.create:press.desc": "Make a Mechanical Press and use it to create some Plates.", - "advancement.create:mixer": "Mixin' it Up", - "advancement.create:mixer.desc": "Create a Mechanical Mixer.", - "advancement.create:brass": "An Actual Alloy", - "advancement.create:brass.desc": "Use Copper and Zinc to create some Brass.", - "advancement.create:brass_casing": "The Brass Age", - "advancement.create:brass_casing.desc": "Use newly obtained Brass and some Wood to create a more advanced Casing.", - "advancement.create:deployer": "Poke, Place, and Attack", - "advancement.create:deployer.desc": "Create a Deployer, the perfect reflection of yourself.", - "advancement.create:deployer_secret": "Pound It, Bro!", - "advancement.create:deployer_secret.desc": "Make two Deployers fist-bump.", - "advancement.create:chromatic_compound": "Bipolar Materials", - "advancement.create:chromatic_compound.desc": "Craft a Bar of Chromatic Compound.", - "advancement.create:shadow_steel": "Void Returner", - "advancement.create:shadow_steel.desc": "Create Shadow Steel, a metal bar of nothingness.", - "advancement.create:refined_radiance": "Bright and Inspiring", - "advancement.create:refined_radiance.desc": "Create Refined Radiance, a powerful chromatic substance.", - "advancement.create:refined_radiance_secret": "Forged by the Beam of Light", - "advancement.create:refined_radiance_secret.desc": "Find the alternative way to make Refined Radiance.", - "advancement.create:speed_secret": "Nice ", - "advancement.create:speed_secret.desc": "Watch a Speedometer reach exactly 69 rpm.", + "advancement.create.root": "Welcome to Create", + "advancement.create.root.desc": "It's time to start building some amazing Contraptions!", + "advancement.create.andesite_alloy": "Alliterations Aplenty", + "advancement.create.andesite_alloy.desc": "Create's materials have weird names, Andesite Alloy is one of them.", + "advancement.create.its_alive": "It's Alive!", + "advancement.create.its_alive.desc": "Watch your first kinetic component spin.", + "advancement.create.shifting_gears": "Shifting Gear", + "advancement.create.shifting_gears.desc": "Connect a large to a small cogwheel allowing you to change the speed of your contraption.", + "advancement.create.overstressed": "Overstressed", + "advancement.create.overstressed.desc": "Experience the limits of stress firsthand.", + "advancement.create.belt": "Convey it all", + "advancement.create.belt.desc": "Connect two shafts with a Mechanical Belt.", + "advancement.create.wrench": "Configure Conveniently", + "advancement.create.wrench.desc": "Create a Wrench to aid you in building your contraptions.", + "advancement.create.goggles": "Stress-o-vision", + "advancement.create.goggles.desc": "Create some goggles to aid you in getting more kinetic information for components.", + "advancement.create.speed_gauge": "But how fast exactly?", + "advancement.create.speed_gauge.desc": "Place and power a Speedometer. Look at it through your goggles to read its exact value.", + "advancement.create.stress_gauge": "But how stressed exactly?", + "advancement.create.stress_gauge.desc": "Place and power a Stressometer. Look at it through your goggles to read its exact value.", + + "advancement.create.water_wheel": "Harnessing Hydraulics", + "advancement.create.water_wheel.desc": "Place a Water Wheel and try getting it to spin!", + "advancement.create.lava_wheel": "Magma Wheel", + "advancement.create.lava_wheel.desc": "This shouldn't have worked.", + "advancement.create.millstone": "Pocket Crusher", + "advancement.create.millstone.desc": "Place and power a Millstone", + "advancement.create.andesite_casing": "The Andesite Age", + "advancement.create.andesite_casing.desc": "Use some Andesite Alloy and Wood to create a basic Casing.", + "advancement.create.drill": "Stationary breakers", + "advancement.create.drill.desc": "Place and power a Mechanical Drill", + "advancement.create.press": "Press goes 'Bonk!'", + "advancement.create.press.desc": "Power a Mechanical Press and use it to create some Plates.", + "advancement.create.polished_rose_quartz": "Pink Diamonds", + "advancement.create.polished_rose_quartz.desc": "Use a piece of sand paper to polish Rose Quartz until it becomes transparent.", + "advancement.create.electron_tube": "Beep boop", + "advancement.create.electron_tube.desc": "Make some Electron Tubes, useful in crafting less primitive machinery.", + "advancement.create.saw": "Stationary Chopping", + "advancement.create.saw.desc": "Place and power a Mechanical Saw", + "advancement.create.basin": "Basin Operation", + "advancement.create.basin.desc": "Place a basin and try throwing items into it.", + "advancement.create.mixer": "Mixin' it Up", + "advancement.create.mixer.desc": "Place a Mechanical Mixer above the basin, power it, and start mixing some ingredients.", + "advancement.create.compact": "Automated Compacting", + "advancement.create.compact.desc": "Use a press and a basin to compact some items.", + + "advancement.create.expert_lane_1": "The Andesite Expert Lane", + "advancement.create.expert_lane_1.desc": "Work in Progress", + + "advancement.create.brass": "An Actual Alloy", + "advancement.create.brass.desc": "Use Crushed Copper and Crushed Zinc to create some Brass.", + "advancement.create.brass_casing": "The Brass Age", + "advancement.create.brass_casing.desc": "Use newly obtained Brass and some Wood to create a more advanced Casing.", + + "advancement.create.crafter": "Automated Assembly", + "advancement.create.crafter.desc": "Place and power some Mechanical Crafters", + "advancement.create.deployer": "Poke, Place, and Attack", + "advancement.create.deployer.desc": "Place and power a Deployer, the perfect reflection of yourself.", + "advancement.create.fist_bump": "Pound It, Bro!", + "advancement.create.fist_bump.desc": "Make two Deployers fist-bump.", + "advancement.create.crushing_wheel": "A Pair of Giants", + "advancement.create.crushing_wheel.desc": "Create some Crushing Wheels to break down more materials more effectively.", + + "advancement.create.chromatic_compound": "Bipolar Minerals", + "advancement.create.chromatic_compound.desc": "Create a Bar of Chromatic Compound.", + "advancement.create.shadow_steel": "Void Returner", + "advancement.create.shadow_steel.desc": "Create Shadow Steel, a metal bar of nothingness.", + "advancement.create.refined_radiance": "Bright and Inspiring", + "advancement.create.refined_radiance.desc": "Create Refined Radiance, a powerful chromatic substance.", + "create.subtitle.schematicannon_launch_block": "Schematicannon shoots", "create.subtitle.schematicannon_finish": "Schematicannon finishes", "create.subtitle.slime_added": "Slime squishes", @@ -769,9 +800,6 @@ "item.create.blueprint_and_quill.tooltip.control3": "R-Click while Sneaking", "item.create.blueprint_and_quill.tooltip.action3": "_Resets_ and removes the selection.", - "block.create.creative_crate.tooltip": "CREATIVE CRATE", - "block.create.creative_crate.tooltip.summary": "Provides an endless supply of blocks to adjacent _Schematicannons_.", - "block.create.schematicannon.tooltip": "SCHEMATICANNON", "block.create.schematicannon.tooltip.summary": "Shoots blocks to recreate a deployed _Schematic_ in the World. Uses items from adjacent Inventories and _Gunpowder_ as fuel.", "block.create.schematicannon.tooltip.control1": "When R-Clicked", @@ -1176,5 +1204,9 @@ "tool.create.rose_quartz.tooltip": "ROSE QUARTZ TOOLS", "tool.create.rose_quartz.tooltip.summary": "This tool grants you a _greater_ _reach_ for _breaking_ _blocks_ or _placing_ _blocks_ from the off-hand.", + "block.create.warehouse_crate.tooltip": "WIP", + "block.create.filtered_crate.tooltip": "WIP", + "block.create.creative_crate.tooltip": "WIP", + "itemGroup.create": "Create" } diff --git a/src/main/resources/assets/create/models/block/crate/andesite/double_bottom.json b/src/main/resources/assets/create/models/block/crate/andesite/double_bottom.json new file mode 100644 index 000000000..1f64b86a4 --- /dev/null +++ b/src/main/resources/assets/create/models/block/crate/andesite/double_bottom.json @@ -0,0 +1,8 @@ +{ + "parent": "create:block/crate/double_bottom", + "textures": { + "side": "create:block/crate_andesite_side", + "crate": "create:block/crate_andesite", + "casing": "create:block/andesite_casing" + } +} \ No newline at end of file diff --git a/src/main/resources/assets/create/models/block/crate/andesite/double_left.json b/src/main/resources/assets/create/models/block/crate/andesite/double_left.json new file mode 100644 index 000000000..7e80d3c0f --- /dev/null +++ b/src/main/resources/assets/create/models/block/crate/andesite/double_left.json @@ -0,0 +1,8 @@ +{ + "parent": "create:block/crate/double_left", + "textures": { + "side": "create:block/crate_andesite_side", + "crate": "create:block/crate_andesite", + "casing": "create:block/andesite_casing" + } +} \ No newline at end of file diff --git a/src/main/resources/assets/create/models/block/crate/andesite/double_right.json b/src/main/resources/assets/create/models/block/crate/andesite/double_right.json new file mode 100644 index 000000000..ef4e4879b --- /dev/null +++ b/src/main/resources/assets/create/models/block/crate/andesite/double_right.json @@ -0,0 +1,8 @@ +{ + "parent": "create:block/crate/double_right", + "textures": { + "side": "create:block/crate_andesite_side", + "crate": "create:block/crate_andesite", + "casing": "create:block/andesite_casing" + } +} \ No newline at end of file diff --git a/src/main/resources/assets/create/models/block/crate/andesite/double_top.json b/src/main/resources/assets/create/models/block/crate/andesite/double_top.json new file mode 100644 index 000000000..1365289d2 --- /dev/null +++ b/src/main/resources/assets/create/models/block/crate/andesite/double_top.json @@ -0,0 +1,8 @@ +{ + "parent": "create:block/crate/double_top", + "textures": { + "side": "create:block/crate_andesite_side", + "crate": "create:block/crate_andesite", + "casing": "create:block/andesite_casing" + } +} \ No newline at end of file diff --git a/src/main/resources/assets/create/models/block/crate/andesite/single.json b/src/main/resources/assets/create/models/block/crate/andesite/single.json new file mode 100644 index 000000000..fd13c504e --- /dev/null +++ b/src/main/resources/assets/create/models/block/crate/andesite/single.json @@ -0,0 +1,8 @@ +{ + "parent": "create:block/crate/single", + "textures": { + "side": "create:block/crate_andesite_side", + "crate": "create:block/crate_andesite", + "casing": "create:block/andesite_casing" + } +} \ No newline at end of file diff --git a/src/main/resources/assets/create/models/block/crate/brass/double_bottom.json b/src/main/resources/assets/create/models/block/crate/brass/double_bottom.json new file mode 100644 index 000000000..17421d454 --- /dev/null +++ b/src/main/resources/assets/create/models/block/crate/brass/double_bottom.json @@ -0,0 +1,8 @@ +{ + "parent": "create:block/crate/double_bottom", + "textures": { + "side": "create:block/crate_brass_side", + "crate": "create:block/crate_brass", + "casing": "create:block/brass_casing" + } +} \ No newline at end of file diff --git a/src/main/resources/assets/create/models/block/crate/brass/double_left.json b/src/main/resources/assets/create/models/block/crate/brass/double_left.json new file mode 100644 index 000000000..1bafd8483 --- /dev/null +++ b/src/main/resources/assets/create/models/block/crate/brass/double_left.json @@ -0,0 +1,8 @@ +{ + "parent": "create:block/crate/double_left", + "textures": { + "side": "create:block/crate_brass_side", + "crate": "create:block/crate_brass", + "casing": "create:block/brass_casing" + } +} \ No newline at end of file diff --git a/src/main/resources/assets/create/models/block/crate/brass/double_right.json b/src/main/resources/assets/create/models/block/crate/brass/double_right.json new file mode 100644 index 000000000..8a2fae584 --- /dev/null +++ b/src/main/resources/assets/create/models/block/crate/brass/double_right.json @@ -0,0 +1,8 @@ +{ + "parent": "create:block/crate/double_right", + "textures": { + "side": "create:block/crate_brass_side", + "crate": "create:block/crate_brass", + "casing": "create:block/brass_casing" + } +} \ No newline at end of file diff --git a/src/main/resources/assets/create/models/block/crate/brass/double_top.json b/src/main/resources/assets/create/models/block/crate/brass/double_top.json new file mode 100644 index 000000000..1f143378e --- /dev/null +++ b/src/main/resources/assets/create/models/block/crate/brass/double_top.json @@ -0,0 +1,8 @@ +{ + "parent": "create:block/crate/double_top", + "textures": { + "side": "create:block/crate_brass_side", + "crate": "create:block/crate_brass", + "casing": "create:block/brass_casing" + } +} \ No newline at end of file diff --git a/src/main/resources/assets/create/models/block/crate/brass/single.json b/src/main/resources/assets/create/models/block/crate/brass/single.json new file mode 100644 index 000000000..b1caf4cf2 --- /dev/null +++ b/src/main/resources/assets/create/models/block/crate/brass/single.json @@ -0,0 +1,8 @@ +{ + "parent": "create:block/crate/single", + "textures": { + "side": "create:block/crate_brass_side", + "crate": "create:block/crate_brass", + "casing": "create:block/brass_casing" + } +} \ No newline at end of file diff --git a/src/main/resources/assets/create/models/block/crate/copper/double_bottom.json b/src/main/resources/assets/create/models/block/crate/copper/double_bottom.json new file mode 100644 index 000000000..8f3c1d55f --- /dev/null +++ b/src/main/resources/assets/create/models/block/crate/copper/double_bottom.json @@ -0,0 +1,8 @@ +{ + "parent": "create:block/crate/double_bottom", + "textures": { + "side": "create:block/crate_copper_side", + "crate": "create:block/crate_copper", + "casing": "create:block/copper_casing" + } +} \ No newline at end of file diff --git a/src/main/resources/assets/create/models/block/crate/copper/double_left.json b/src/main/resources/assets/create/models/block/crate/copper/double_left.json new file mode 100644 index 000000000..6cb52e843 --- /dev/null +++ b/src/main/resources/assets/create/models/block/crate/copper/double_left.json @@ -0,0 +1,8 @@ +{ + "parent": "create:block/crate/double_left", + "textures": { + "side": "create:block/crate_copper_side", + "crate": "create:block/crate_copper", + "casing": "create:block/copper_casing" + } +} \ No newline at end of file diff --git a/src/main/resources/assets/create/models/block/crate/copper/double_right.json b/src/main/resources/assets/create/models/block/crate/copper/double_right.json new file mode 100644 index 000000000..fc4f8230b --- /dev/null +++ b/src/main/resources/assets/create/models/block/crate/copper/double_right.json @@ -0,0 +1,8 @@ +{ + "parent": "create:block/crate/double_right", + "textures": { + "side": "create:block/crate_copper_side", + "crate": "create:block/crate_copper", + "casing": "create:block/copper_casing" + } +} \ No newline at end of file diff --git a/src/main/resources/assets/create/models/block/crate/copper/double_top.json b/src/main/resources/assets/create/models/block/crate/copper/double_top.json new file mode 100644 index 000000000..a1c05fdf4 --- /dev/null +++ b/src/main/resources/assets/create/models/block/crate/copper/double_top.json @@ -0,0 +1,8 @@ +{ + "parent": "create:block/crate/double_top", + "textures": { + "side": "create:block/crate_copper_side", + "crate": "create:block/crate_copper", + "casing": "create:block/copper_casing" + } +} \ No newline at end of file diff --git a/src/main/resources/assets/create/models/block/crate/copper/single.json b/src/main/resources/assets/create/models/block/crate/copper/single.json new file mode 100644 index 000000000..9424436d3 --- /dev/null +++ b/src/main/resources/assets/create/models/block/crate/copper/single.json @@ -0,0 +1,8 @@ +{ + "parent": "create:block/crate/single", + "textures": { + "side": "create:block/crate_copper_side", + "crate": "create:block/crate_copper", + "casing": "create:block/copper_casing" + } +} \ No newline at end of file diff --git a/src/main/resources/assets/create/models/block/crate/creative/double_bottom.json b/src/main/resources/assets/create/models/block/crate/creative/double_bottom.json new file mode 100644 index 000000000..a6a52312c --- /dev/null +++ b/src/main/resources/assets/create/models/block/crate/creative/double_bottom.json @@ -0,0 +1,8 @@ +{ + "parent": "create:block/crate/double_bottom", + "textures": { + "side": "create:block/crate_creative_side", + "crate": "create:block/crate_creative", + "casing": "create:block/chorus_chrome_mesh" + } +} \ No newline at end of file diff --git a/src/main/resources/assets/create/models/block/crate/creative/double_left.json b/src/main/resources/assets/create/models/block/crate/creative/double_left.json new file mode 100644 index 000000000..17188e56f --- /dev/null +++ b/src/main/resources/assets/create/models/block/crate/creative/double_left.json @@ -0,0 +1,8 @@ +{ + "parent": "create:block/crate/double_left", + "textures": { + "side": "create:block/crate_creative_side", + "crate": "create:block/crate_creative", + "casing": "create:block/chorus_chrome_mesh" + } +} \ No newline at end of file diff --git a/src/main/resources/assets/create/models/block/crate/creative/double_right.json b/src/main/resources/assets/create/models/block/crate/creative/double_right.json new file mode 100644 index 000000000..e23a11c5e --- /dev/null +++ b/src/main/resources/assets/create/models/block/crate/creative/double_right.json @@ -0,0 +1,8 @@ +{ + "parent": "create:block/crate/double_right", + "textures": { + "side": "create:block/crate_creative_side", + "crate": "create:block/crate_creative", + "casing": "create:block/chorus_chrome_mesh" + } +} \ No newline at end of file diff --git a/src/main/resources/assets/create/models/block/crate/creative/double_top.json b/src/main/resources/assets/create/models/block/crate/creative/double_top.json new file mode 100644 index 000000000..fe10d5395 --- /dev/null +++ b/src/main/resources/assets/create/models/block/crate/creative/double_top.json @@ -0,0 +1,8 @@ +{ + "parent": "create:block/crate/double_top", + "textures": { + "side": "create:block/crate_creative_side", + "crate": "create:block/crate_creative", + "casing": "create:block/chorus_chrome_mesh" + } +} \ No newline at end of file diff --git a/src/main/resources/assets/create/models/block/crate/creative/single.json b/src/main/resources/assets/create/models/block/crate/creative/single.json new file mode 100644 index 000000000..bf83bf254 --- /dev/null +++ b/src/main/resources/assets/create/models/block/crate/creative/single.json @@ -0,0 +1,8 @@ +{ + "parent": "create:block/crate/single", + "textures": { + "side": "create:block/crate_creative_side", + "crate": "create:block/crate_creative", + "casing": "create:block/chorus_chrome_mesh" + } +} \ No newline at end of file diff --git a/src/main/resources/assets/create/models/block/flexcrate/double_bottom.json b/src/main/resources/assets/create/models/block/crate/double_bottom.json similarity index 67% rename from src/main/resources/assets/create/models/block/flexcrate/double_bottom.json rename to src/main/resources/assets/create/models/block/crate/double_bottom.json index 3d3ec3d4e..36ead3ace 100644 --- a/src/main/resources/assets/create/models/block/flexcrate/double_bottom.json +++ b/src/main/resources/assets/create/models/block/crate/double_bottom.json @@ -2,9 +2,9 @@ "credit": "Made with Blockbench", "parent": "block/block", "textures": { - "0": "create:block/double_flexcrate_side", - "3": "create:block/brass_casing_14", - "particle": "create:block/flex_crate" + "0": "#side", + "4": "#crate", + "particle": "#casing" }, "elements": [ { @@ -15,7 +15,7 @@ "east": {"uv": [8.5, 8, 15.5, 16], "texture": "#0"}, "south": {"uv": [8.5, 8, 15.5, 16], "texture": "#0"}, "west": {"uv": [8.5, 8, 15.5, 16], "texture": "#0"}, - "down": {"uv": [1, 1, 15, 15], "rotation": 270, "texture": "#3"} + "down": {"uv": [8.5, 8.5, 15.5, 15.5], "rotation": 270, "texture": "#4"} } } ] diff --git a/src/main/resources/assets/create/models/block/flexcrate/double_left.json b/src/main/resources/assets/create/models/block/crate/double_left.json similarity index 66% rename from src/main/resources/assets/create/models/block/flexcrate/double_left.json rename to src/main/resources/assets/create/models/block/crate/double_left.json index 4055d2672..f1e327587 100644 --- a/src/main/resources/assets/create/models/block/flexcrate/double_left.json +++ b/src/main/resources/assets/create/models/block/crate/double_left.json @@ -2,17 +2,16 @@ "credit": "Made with Blockbench", "parent": "block/block", "textures": { - "0": "create:block/double_flexcrate_side", - "1": "create:block/double_flexcrate_bottom", - "2": "create:block/flex_crate", - "particle": "create:block/flex_crate" + "0": "#side", + "1": "#crate", + "particle": "#casing" }, "elements": [ { "from": [1, 0, 1], "to": [15, 14, 16], "faces": { - "north": {"uv": [1, 1, 15, 15], "texture": "#2"}, + "north": {"uv": [0.5, 8.5, 7.5, 15.5], "texture": "#1"}, "east": {"uv": [8, 0.5, 15.5, 7.5], "texture": "#0"}, "west": {"uv": [0.5, 0.5, 8, 7.5], "texture": "#0"}, "up": {"uv": [0.5, 0.5, 8, 7.5], "rotation": 90, "texture": "#1"}, diff --git a/src/main/resources/assets/create/models/block/flexcrate/double_right.json b/src/main/resources/assets/create/models/block/crate/double_right.json similarity index 66% rename from src/main/resources/assets/create/models/block/flexcrate/double_right.json rename to src/main/resources/assets/create/models/block/crate/double_right.json index 92b457020..8d7a73675 100644 --- a/src/main/resources/assets/create/models/block/flexcrate/double_right.json +++ b/src/main/resources/assets/create/models/block/crate/double_right.json @@ -2,10 +2,9 @@ "credit": "Made with Blockbench", "parent": "block/block", "textures": { - "0": "create:block/double_flexcrate_side", - "1": "create:block/double_flexcrate_bottom", - "2": "create:block/flex_crate", - "particle": "create:block/flex_crate" + "0": "#side", + "1": "#crate", + "particle": "#casing" }, "elements": [ { @@ -13,7 +12,7 @@ "to": [15, 14, 15], "faces": { "east": {"uv": [0.5, 0.5, 8, 7.5], "texture": "#0"}, - "south": {"uv": [1, 1, 15, 15], "texture": "#2"}, + "south": {"uv": [0.5, 8.5, 7.5, 15.5], "texture": "#1"}, "west": {"uv": [8, 0.5, 15.5, 7.5], "texture": "#0"}, "up": {"uv": [8, 0.5, 15.5, 7.5], "rotation": 90, "texture": "#1"}, "down": {"uv": [8, 0.5, 15.5, 7.5], "rotation": 270, "texture": "#1"} diff --git a/src/main/resources/assets/create/models/block/flexcrate/double_top.json b/src/main/resources/assets/create/models/block/crate/double_top.json similarity index 68% rename from src/main/resources/assets/create/models/block/flexcrate/double_top.json rename to src/main/resources/assets/create/models/block/crate/double_top.json index 8defc54ef..ce2106e66 100644 --- a/src/main/resources/assets/create/models/block/flexcrate/double_top.json +++ b/src/main/resources/assets/create/models/block/crate/double_top.json @@ -2,9 +2,9 @@ "credit": "Made with Blockbench", "parent": "block/block", "textures": { - "0": "create:block/double_flexcrate_side", - "3": "create:block/brass_casing_14", - "particle": "create:block/flex_crate" + "0": "#side", + "2": "#crate", + "particle": "#casing" }, "elements": [ { @@ -15,7 +15,7 @@ "east": {"uv": [0.5, 8.5, 7.5, 15.5], "texture": "#0"}, "south": {"uv": [0.5, 8.5, 7.5, 15.5], "texture": "#0"}, "west": {"uv": [0.5, 8.5, 7.5, 15.5], "texture": "#0"}, - "up": {"uv": [1, 1, 15, 15], "rotation": 90, "texture": "#3"} + "up": {"uv": [8.5, 8.5, 15.5, 15.5], "rotation": 90, "texture": "#2"} } } ] diff --git a/src/main/resources/assets/create/models/block/crate/single.json b/src/main/resources/assets/create/models/block/crate/single.json new file mode 100644 index 000000000..acc71e720 --- /dev/null +++ b/src/main/resources/assets/create/models/block/crate/single.json @@ -0,0 +1,23 @@ +{ + "credit": "Made with Blockbench", + "parent": "block/block", + "textures": { + "2": "#crate", + "particle": "#casing" + }, + "elements": [ + { + "name": "Crate", + "from": [1, 0, 1], + "to": [15, 14, 15], + "faces": { + "north": {"uv": [0.5, 8.5, 7.5, 15.5], "texture": "#2"}, + "east": {"uv": [0.5, 8.5, 7.5, 15.5], "texture": "#2"}, + "south": {"uv": [0.5, 8.5, 7.5, 15.5], "texture": "#2"}, + "west": {"uv": [0.5, 8.5, 7.5, 15.5], "texture": "#2"}, + "up": {"uv": [8.5, 8.5, 15.5, 15.5], "texture": "#2"}, + "down": {"uv": [8.5, 8.5, 15.5, 15.5], "texture": "#2"} + } + } + ] +} \ No newline at end of file diff --git a/src/main/resources/assets/create/models/block/flexcrate/single.json b/src/main/resources/assets/create/models/block/flexcrate/single.json deleted file mode 100644 index c397bfad0..000000000 --- a/src/main/resources/assets/create/models/block/flexcrate/single.json +++ /dev/null @@ -1,23 +0,0 @@ -{ - "parent": "block/block", - "textures": { - "particle": "create:block/flex_crate", - "side": "create:block/flex_crate", - "top": "create:block/brass_casing_14" - }, - "elements": [ - { - "name": "Crate", - "from": [ 1, 0, 1 ], - "to": [ 15, 14, 15 ], - "faces": { - "north": { "texture": "#side", "uv": [ 1, 1, 15, 15 ] }, - "east": { "texture": "#side", "uv": [ 1, 1, 15, 15 ] }, - "south": { "texture": "#side", "uv": [ 1, 1, 15, 15 ] }, - "west": { "texture": "#side", "uv": [ 1, 1, 15, 15 ] }, - "up": { "texture": "#top", "uv": [ 1, 1, 15, 15 ] }, - "down": { "texture": "#top", "uv": [ 1, 1, 15, 15 ] } - } - } - ] -} \ No newline at end of file diff --git a/src/main/resources/assets/create/models/item/creative_crate.json b/src/main/resources/assets/create/models/item/creative_crate.json index 5cea86295..b206b9358 100644 --- a/src/main/resources/assets/create/models/item/creative_crate.json +++ b/src/main/resources/assets/create/models/item/creative_crate.json @@ -1,3 +1,3 @@ { - "parent": "create:block/creative_crate" + "parent": "create:block/crate/creative/single" } \ No newline at end of file diff --git a/src/main/resources/assets/create/models/item/filtered_crate.json b/src/main/resources/assets/create/models/item/filtered_crate.json new file mode 100644 index 000000000..9478a7f23 --- /dev/null +++ b/src/main/resources/assets/create/models/item/filtered_crate.json @@ -0,0 +1,3 @@ +{ + "parent": "create:block/crate/copper/single" +} \ No newline at end of file diff --git a/src/main/resources/assets/create/models/item/flexcrate.json b/src/main/resources/assets/create/models/item/flexcrate.json index 90610cbde..2f1d31d32 100644 --- a/src/main/resources/assets/create/models/item/flexcrate.json +++ b/src/main/resources/assets/create/models/item/flexcrate.json @@ -1,3 +1,3 @@ { - "parent": "create:block/flexcrate/single" + "parent": "create:block/crate/brass/single" } \ No newline at end of file diff --git a/src/main/resources/assets/create/models/item/warehouse_crate.json b/src/main/resources/assets/create/models/item/warehouse_crate.json new file mode 100644 index 000000000..20c00f2c1 --- /dev/null +++ b/src/main/resources/assets/create/models/item/warehouse_crate.json @@ -0,0 +1,3 @@ +{ + "parent": "create:block/crate/andesite/single" +} \ No newline at end of file diff --git a/src/main/resources/assets/create/textures/block/brass_casing_14.png b/src/main/resources/assets/create/textures/block/brass_casing_14.png deleted file mode 100644 index 3f5d6ab98..000000000 Binary files a/src/main/resources/assets/create/textures/block/brass_casing_14.png and /dev/null differ diff --git a/src/main/resources/assets/create/textures/block/crate_andesite.png b/src/main/resources/assets/create/textures/block/crate_andesite.png new file mode 100644 index 000000000..f79955709 Binary files /dev/null and b/src/main/resources/assets/create/textures/block/crate_andesite.png differ diff --git a/src/main/resources/assets/create/textures/block/crate_andesite_side.png b/src/main/resources/assets/create/textures/block/crate_andesite_side.png new file mode 100644 index 000000000..b291afe77 Binary files /dev/null and b/src/main/resources/assets/create/textures/block/crate_andesite_side.png differ diff --git a/src/main/resources/assets/create/textures/block/crate_brass.png b/src/main/resources/assets/create/textures/block/crate_brass.png new file mode 100644 index 000000000..4b73d00f6 Binary files /dev/null and b/src/main/resources/assets/create/textures/block/crate_brass.png differ diff --git a/src/main/resources/assets/create/textures/block/double_flexcrate_side.png b/src/main/resources/assets/create/textures/block/crate_brass_side.png similarity index 100% rename from src/main/resources/assets/create/textures/block/double_flexcrate_side.png rename to src/main/resources/assets/create/textures/block/crate_brass_side.png diff --git a/src/main/resources/assets/create/textures/block/crate_copper.png b/src/main/resources/assets/create/textures/block/crate_copper.png new file mode 100644 index 000000000..993ef7007 Binary files /dev/null and b/src/main/resources/assets/create/textures/block/crate_copper.png differ diff --git a/src/main/resources/assets/create/textures/block/crate_copper_side.png b/src/main/resources/assets/create/textures/block/crate_copper_side.png new file mode 100644 index 000000000..37213e3c3 Binary files /dev/null and b/src/main/resources/assets/create/textures/block/crate_copper_side.png differ diff --git a/src/main/resources/assets/create/textures/block/crate_creative.png b/src/main/resources/assets/create/textures/block/crate_creative.png new file mode 100644 index 000000000..18803da26 Binary files /dev/null and b/src/main/resources/assets/create/textures/block/crate_creative.png differ diff --git a/src/main/resources/assets/create/textures/block/crate_creative_side.png b/src/main/resources/assets/create/textures/block/crate_creative_side.png new file mode 100644 index 000000000..ba4103477 Binary files /dev/null and b/src/main/resources/assets/create/textures/block/crate_creative_side.png differ diff --git a/src/main/resources/assets/create/textures/block/creative_crate_side.png b/src/main/resources/assets/create/textures/block/creative_crate_side.png deleted file mode 100644 index b5273f68d..000000000 Binary files a/src/main/resources/assets/create/textures/block/creative_crate_side.png and /dev/null differ diff --git a/src/main/resources/assets/create/textures/block/creative_crate_top.png b/src/main/resources/assets/create/textures/block/creative_crate_top.png deleted file mode 100644 index 525326b71..000000000 Binary files a/src/main/resources/assets/create/textures/block/creative_crate_top.png and /dev/null differ diff --git a/src/main/resources/assets/create/textures/block/double_flexcrate_bottom.png b/src/main/resources/assets/create/textures/block/double_flexcrate_bottom.png deleted file mode 100644 index 9b95e424b..000000000 Binary files a/src/main/resources/assets/create/textures/block/double_flexcrate_bottom.png and /dev/null differ diff --git a/src/main/resources/assets/create/textures/block/flex_crate.png b/src/main/resources/assets/create/textures/block/flex_crate.png deleted file mode 100644 index 27e78bb33..000000000 Binary files a/src/main/resources/assets/create/textures/block/flex_crate.png and /dev/null differ diff --git a/src/main/resources/data/create/advancements/andesite_alloy.json b/src/main/resources/data/create/advancements/andesite_alloy.json index 82a8a22b1..044362e9c 100644 --- a/src/main/resources/data/create/advancements/andesite_alloy.json +++ b/src/main/resources/data/create/advancements/andesite_alloy.json @@ -1,30 +1,35 @@ { - "display": { - "title": { - "translate": "advancement.create:andesite_alloy" - }, - "description": { - "translate": "advancement.create:andesite_alloy.desc" - }, - "icon": { + "parent": "create:root", + "display": { + "icon": { + "item": "create:andesite_alloy" + }, + "title": { + "translate": "advancement.create.andesite_alloy" + }, + "description": { + "translate": "advancement.create.andesite_alloy.desc" + }, + "frame": "task", + "show_toast": true, + "announce_to_chat": false, + "hidden": false + }, + "criteria": { + "0": { + "trigger": "minecraft:inventory_changed", + "conditions": { + "items": [ + { "item": "create:andesite_alloy" - }, - "frame": "task", - "show_toast": true, - "announce_to_chat": false, - "hidden": true - }, - "criteria": { - "alloy": { - "trigger": "minecraft:inventory_changed", - "conditions": { - "items": [ - { - "item": "create:andesite_alloy" - } - ] - } - } - }, - "parent": "create:root" + } + ] + } + } + }, + "requirements": [ + [ + "0" + ] + ] } \ No newline at end of file diff --git a/src/main/resources/data/create/advancements/andesite_casing.json b/src/main/resources/data/create/advancements/andesite_casing.json index 0d2396e9f..a0b4a7b9a 100644 --- a/src/main/resources/data/create/advancements/andesite_casing.json +++ b/src/main/resources/data/create/advancements/andesite_casing.json @@ -1,30 +1,35 @@ { - "display": { - "title": { - "translate": "advancement.create:andesite_casing" - }, - "description": { - "translate": "advancement.create:andesite_casing.desc" - }, - "icon": { + "parent": "create:andesite_alloy", + "display": { + "icon": { + "item": "create:andesite_casing" + }, + "title": { + "translate": "advancement.create.andesite_casing" + }, + "description": { + "translate": "advancement.create.andesite_casing.desc" + }, + "frame": "goal", + "show_toast": true, + "announce_to_chat": true, + "hidden": false + }, + "criteria": { + "0": { + "trigger": "minecraft:inventory_changed", + "conditions": { + "items": [ + { "item": "create:andesite_casing" - }, - "frame": "task", - "show_toast": true, - "announce_to_chat": false, - "hidden": false - }, - "criteria": { - "casing": { - "trigger": "minecraft:inventory_changed", - "conditions": { - "items": [ - { - "item": "create:andesite_casing" - } - ] - } - } - }, - "parent": "create:andesite_alloy" + } + ] + } + } + }, + "requirements": [ + [ + "0" + ] + ] } \ No newline at end of file diff --git a/src/main/resources/data/create/advancements/basin.json b/src/main/resources/data/create/advancements/basin.json new file mode 100644 index 000000000..8d31e5f81 --- /dev/null +++ b/src/main/resources/data/create/advancements/basin.json @@ -0,0 +1,37 @@ +{ + "parent": "create:press", + "display": { + "icon": { + "item": "create:basin" + }, + "title": { + "translate": "advancement.create.basin" + }, + "description": { + "translate": "advancement.create.basin.desc" + }, + "frame": "task", + "show_toast": true, + "announce_to_chat": false, + "hidden": false + }, + "criteria": { + "0": { + "trigger": "minecraft:placed_block", + "conditions": { + "block": "create:basin" + } + }, + "1": { + "trigger": "create:basin" + } + }, + "requirements": [ + [ + "0" + ], + [ + "1" + ] + ] +} \ No newline at end of file diff --git a/src/main/resources/data/create/advancements/belt.json b/src/main/resources/data/create/advancements/belt.json new file mode 100644 index 000000000..a19fd4674 --- /dev/null +++ b/src/main/resources/data/create/advancements/belt.json @@ -0,0 +1,28 @@ +{ + "parent": "create:its_alive", + "display": { + "icon": { + "item": "create:belt_connector" + }, + "title": { + "translate": "advancement.create.belt" + }, + "description": { + "translate": "advancement.create.belt.desc" + }, + "frame": "task", + "show_toast": true, + "announce_to_chat": false, + "hidden": false + }, + "criteria": { + "0": { + "trigger": "create:connect_belt" + } + }, + "requirements": [ + [ + "0" + ] + ] +} \ No newline at end of file diff --git a/src/main/resources/data/create/advancements/brass.json b/src/main/resources/data/create/advancements/brass.json index b43592d94..105ed5831 100644 --- a/src/main/resources/data/create/advancements/brass.json +++ b/src/main/resources/data/create/advancements/brass.json @@ -1,31 +1,35 @@ { - "display": { - "title": { - "translate": "advancement.create:brass", - "color": "gold" - }, - "description": { - "translate": "advancement.create:brass.desc" - }, - "icon": { - "item": "create:crushed_brass" - }, - "frame": "task", - "show_toast": true, - "announce_to_chat": false, - "hidden": false + "parent": "create:mixer", + "display": { + "icon": { + "item": "create:brass_ingot" }, - "criteria": { - "brass": { - "trigger": "minecraft:inventory_changed", - "conditions": { - "items": [ - { - "item": "create:crushed_brass" - } - ] - } - } + "title": { + "translate": "advancement.create.brass" }, - "parent": "create:mechanical_mixer" + "description": { + "translate": "advancement.create.brass.desc" + }, + "frame": "task", + "show_toast": true, + "announce_to_chat": false, + "hidden": false + }, + "criteria": { + "0": { + "trigger": "minecraft:inventory_changed", + "conditions": { + "items": [ + { + "item": "create:brass_ingot" + } + ] + } + } + }, + "requirements": [ + [ + "0" + ] + ] } \ No newline at end of file diff --git a/src/main/resources/data/create/advancements/brass_casing.json b/src/main/resources/data/create/advancements/brass_casing.json index a91749db6..f3161f63e 100644 --- a/src/main/resources/data/create/advancements/brass_casing.json +++ b/src/main/resources/data/create/advancements/brass_casing.json @@ -1,30 +1,35 @@ { - "display": { - "title": { - "translate": "advancement.create:brass_casing" - }, - "description": { - "translate": "advancement.create:brass_casing.desc" - }, - "icon": { + "parent": "create:brass", + "display": { + "icon": { + "item": "create:brass_casing" + }, + "title": { + "translate": "advancement.create.brass_casing" + }, + "description": { + "translate": "advancement.create.brass_casing.desc" + }, + "frame": "goal", + "show_toast": true, + "announce_to_chat": true, + "hidden": false + }, + "criteria": { + "0": { + "trigger": "minecraft:inventory_changed", + "conditions": { + "items": [ + { "item": "create:brass_casing" - }, - "frame": "task", - "show_toast": true, - "announce_to_chat": false, - "hidden": false - }, - "criteria": { - "casing": { - "trigger": "minecraft:inventory_changed", - "conditions": { - "items": [ - { - "item": "create:brass_casing" - } - ] - } - } - }, - "parent": "create:brass" + } + ] + } + } + }, + "requirements": [ + [ + "0" + ] + ] } \ No newline at end of file diff --git a/src/main/resources/data/create/advancements/chromatic_compound.json b/src/main/resources/data/create/advancements/chromatic_compound.json index 65e496c4d..6091139ea 100644 --- a/src/main/resources/data/create/advancements/chromatic_compound.json +++ b/src/main/resources/data/create/advancements/chromatic_compound.json @@ -1,31 +1,35 @@ { - "display": { - "title": { - "translate": "advancement.create:chromatic_compound", - "color": "dark_purple" - }, - "description": { - "translate": "advancement.create:chromatic_compound.desc" - }, - "icon": { + "parent": "create:crushing_wheel", + "display": { + "icon": { + "item": "create:chromatic_compound" + }, + "title": { + "translate": "advancement.create.chromatic_compound" + }, + "description": { + "translate": "advancement.create.chromatic_compound.desc" + }, + "frame": "task", + "show_toast": true, + "announce_to_chat": false, + "hidden": false + }, + "criteria": { + "0": { + "trigger": "minecraft:inventory_changed", + "conditions": { + "items": [ + { "item": "create:chromatic_compound" - }, - "frame": "task", - "show_toast": true, - "announce_to_chat": false, - "hidden": false - }, - "criteria": { - "alloy": { - "trigger": "minecraft:inventory_changed", - "conditions": { - "items": [ - { - "item": "create:chromatic_compound" - } - ] - } - } - }, - "parent": "create:mechanical_mixer" + } + ] + } + } + }, + "requirements": [ + [ + "0" + ] + ] } \ No newline at end of file diff --git a/src/main/resources/data/create/advancements/compact.json b/src/main/resources/data/create/advancements/compact.json new file mode 100644 index 000000000..e83071815 --- /dev/null +++ b/src/main/resources/data/create/advancements/compact.json @@ -0,0 +1,28 @@ +{ + "parent": "create:basin", + "display": { + "icon": { + "item": "minecraft:iron_block" + }, + "title": { + "translate": "advancement.create.compact" + }, + "description": { + "translate": "advancement.create.compact.desc" + }, + "frame": "task", + "show_toast": true, + "announce_to_chat": false, + "hidden": false + }, + "criteria": { + "0": { + "trigger": "create:compact" + } + }, + "requirements": [ + [ + "0" + ] + ] +} \ No newline at end of file diff --git a/src/main/resources/data/create/advancements/crafter.json b/src/main/resources/data/create/advancements/crafter.json new file mode 100644 index 000000000..24ef66ee9 --- /dev/null +++ b/src/main/resources/data/create/advancements/crafter.json @@ -0,0 +1,40 @@ +{ + "parent": "create:brass_casing", + "display": { + "icon": { + "item": "create:mechanical_crafter" + }, + "title": { + "translate": "advancement.create.crafter" + }, + "description": { + "translate": "advancement.create.crafter.desc" + }, + "frame": "task", + "show_toast": true, + "announce_to_chat": true, + "hidden": false + }, + "criteria": { + "0": { + "trigger": "minecraft:placed_block", + "conditions": { + "block": "create:mechanical_crafter" + } + }, + "1": { + "trigger": "create:kinetic_block", + "conditions": { + "block": "create:mechanical_crafter" + } + } + }, + "requirements": [ + [ + "0" + ], + [ + "1" + ] + ] +} \ No newline at end of file diff --git a/src/main/resources/data/create/advancements/crushing_wheel.json b/src/main/resources/data/create/advancements/crushing_wheel.json index 26af94ec9..5660cae98 100644 --- a/src/main/resources/data/create/advancements/crushing_wheel.json +++ b/src/main/resources/data/create/advancements/crushing_wheel.json @@ -1,34 +1,35 @@ { - "display": { - "title": { - "translate": "advancement.create:crushing_wheel" - }, - "description": { - "translate": "advancement.create:crushing_wheel.desc" - }, - "icon": { + "parent": "create:crafter", + "display": { + "icon": { + "item": "create:crushing_wheel" + }, + "title": { + "translate": "advancement.create.crushing_wheel" + }, + "description": { + "translate": "advancement.create.crushing_wheel.desc" + }, + "frame": "task", + "show_toast": true, + "announce_to_chat": true, + "hidden": false + }, + "criteria": { + "0": { + "trigger": "minecraft:inventory_changed", + "conditions": { + "items": [ + { "item": "create:crushing_wheel" - }, - "frame": "task", - "show_toast": true, - "announce_to_chat": false, - "hidden": false - }, - "criteria": { - "crushers": { - "trigger": "minecraft:inventory_changed", - "conditions": { - "items": [ - { - "item": "create:crushing_wheel", - "count": { - "min": 2, - "max": 64 - } - } - ] - } - } - }, - "parent": "create:andesite_alloy" + } + ] + } + } + }, + "requirements": [ + [ + "0" + ] + ] } \ No newline at end of file diff --git a/src/main/resources/data/create/advancements/deployer.json b/src/main/resources/data/create/advancements/deployer.json index 88169d3a7..44b4cf6e6 100644 --- a/src/main/resources/data/create/advancements/deployer.json +++ b/src/main/resources/data/create/advancements/deployer.json @@ -1,30 +1,40 @@ { - "display": { - "title": { - "translate": "advancement.create:deployer" - }, - "description": { - "translate": "advancement.create:deployer.desc" - }, - "icon": { - "item": "create:deployer" - }, - "frame": "task", - "show_toast": true, - "announce_to_chat": false, - "hidden": false + "parent": "create:brass_casing", + "display": { + "icon": { + "item": "create:deployer" }, - "criteria": { - "deployer": { - "trigger": "minecraft:inventory_changed", - "conditions": { - "items": [ - { - "item": "create:deployer" - } - ] - } - } + "title": { + "translate": "advancement.create.deployer" }, - "parent": "create:brass" + "description": { + "translate": "advancement.create.deployer.desc" + }, + "frame": "goal", + "show_toast": true, + "announce_to_chat": true, + "hidden": false + }, + "criteria": { + "0": { + "trigger": "minecraft:placed_block", + "conditions": { + "block": "create:deployer" + } + }, + "1": { + "trigger": "create:kinetic_block", + "conditions": { + "block": "create:deployer" + } + } + }, + "requirements": [ + [ + "0" + ], + [ + "1" + ] + ] } \ No newline at end of file diff --git a/src/main/resources/data/create/advancements/deployer_secret.json b/src/main/resources/data/create/advancements/deployer_secret.json deleted file mode 100644 index b87806234..000000000 --- a/src/main/resources/data/create/advancements/deployer_secret.json +++ /dev/null @@ -1,23 +0,0 @@ -{ - "display": { - "title": { - "translate": "advancement.create:deployer_secret" - }, - "description": { - "translate": "advancement.create:deployer_secret.desc" - }, - "icon": { - "item": "create:deployer" - }, - "frame": "goal", - "show_toast": true, - "announce_to_chat": true, - "hidden": true - }, - "criteria": { - "touching": { - "trigger": "create:deployer" - } - }, - "parent": "create:deployer" -} \ No newline at end of file diff --git a/src/main/resources/data/create/advancements/drill.json b/src/main/resources/data/create/advancements/drill.json new file mode 100644 index 000000000..efae45af5 --- /dev/null +++ b/src/main/resources/data/create/advancements/drill.json @@ -0,0 +1,40 @@ +{ + "parent": "create:andesite_casing", + "display": { + "icon": { + "item": "create:drill" + }, + "title": { + "translate": "advancement.create.drill" + }, + "description": { + "translate": "advancement.create.drill.desc" + }, + "frame": "task", + "show_toast": true, + "announce_to_chat": false, + "hidden": false + }, + "criteria": { + "0": { + "trigger": "minecraft:placed_block", + "conditions": { + "block": "create:drill" + } + }, + "1": { + "trigger": "create:kinetic_block", + "conditions": { + "block": "create:drill" + } + } + }, + "requirements": [ + [ + "0" + ], + [ + "1" + ] + ] +} \ No newline at end of file diff --git a/src/main/resources/data/create/advancements/electron_tube.json b/src/main/resources/data/create/advancements/electron_tube.json new file mode 100644 index 000000000..6070eb238 --- /dev/null +++ b/src/main/resources/data/create/advancements/electron_tube.json @@ -0,0 +1,35 @@ +{ + "parent": "create:polished_rose_quartz", + "display": { + "icon": { + "item": "create:electron_tube" + }, + "title": { + "translate": "advancement.create.electron_tube" + }, + "description": { + "translate": "advancement.create.electron_tube.desc" + }, + "frame": "task", + "show_toast": true, + "announce_to_chat": false, + "hidden": false + }, + "criteria": { + "0": { + "trigger": "minecraft:inventory_changed", + "conditions": { + "items": [ + { + "item": "create:electron_tube" + } + ] + } + } + }, + "requirements": [ + [ + "0" + ] + ] +} \ No newline at end of file diff --git a/src/main/resources/data/create/advancements/expert_lane_1.json b/src/main/resources/data/create/advancements/expert_lane_1.json new file mode 100644 index 000000000..aeca3d781 --- /dev/null +++ b/src/main/resources/data/create/advancements/expert_lane_1.json @@ -0,0 +1,35 @@ +{ + "parent": "create:andesite_casing", + "display": { + "icon": { + "item": "minecraft:andesite" + }, + "title": { + "translate": "advancement.create.expert_lane_1" + }, + "description": { + "translate": "advancement.create.expert_lane_1.desc" + }, + "frame": "challenge", + "show_toast": false, + "announce_to_chat": false, + "hidden": false + }, + "criteria": { + "0": { + "trigger": "minecraft:inventory_changed", + "conditions": { + "items": [ + { + "item": "create:andesite_casing" + } + ] + } + } + }, + "requirements": [ + [ + "0" + ] + ] +} \ No newline at end of file diff --git a/src/main/resources/data/create/advancements/fist_bump.json b/src/main/resources/data/create/advancements/fist_bump.json new file mode 100644 index 000000000..8bd15daf2 --- /dev/null +++ b/src/main/resources/data/create/advancements/fist_bump.json @@ -0,0 +1,28 @@ +{ + "parent": "create:deployer", + "display": { + "icon": { + "item": "create:large_cogwheel" + }, + "title": { + "translate": "advancement.create.fist_bump" + }, + "description": { + "translate": "advancement.create.fist_bump.desc" + }, + "frame": "goal", + "show_toast": true, + "announce_to_chat": true, + "hidden": true + }, + "criteria": { + "0": { + "trigger": "create:deployer" + } + }, + "requirements": [ + [ + "0" + ] + ] +} \ No newline at end of file diff --git a/src/main/resources/data/create/advancements/goggles.json b/src/main/resources/data/create/advancements/goggles.json new file mode 100644 index 000000000..e4c06682c --- /dev/null +++ b/src/main/resources/data/create/advancements/goggles.json @@ -0,0 +1,35 @@ +{ + "parent": "create:its_alive", + "display": { + "icon": { + "item": "create:goggles" + }, + "title": { + "translate": "advancement.create.goggles" + }, + "description": { + "translate": "advancement.create.goggles.desc" + }, + "frame": "task", + "show_toast": true, + "announce_to_chat": false, + "hidden": false + }, + "criteria": { + "0": { + "trigger": "minecraft:inventory_changed", + "conditions": { + "items": [ + { + "item": "create:goggles" + } + ] + } + } + }, + "requirements": [ + [ + "0" + ] + ] +} \ No newline at end of file diff --git a/src/main/resources/data/create/advancements/its_alive.json b/src/main/resources/data/create/advancements/its_alive.json new file mode 100644 index 000000000..b826055f1 --- /dev/null +++ b/src/main/resources/data/create/advancements/its_alive.json @@ -0,0 +1,28 @@ +{ + "parent": "create:andesite_alloy", + "display": { + "icon": { + "item": "create:cogwheel" + }, + "title": { + "translate": "advancement.create.its_alive" + }, + "description": { + "translate": "advancement.create.its_alive.desc" + }, + "frame": "task", + "show_toast": true, + "announce_to_chat": false, + "hidden": false + }, + "criteria": { + "0": { + "trigger": "create:rotation" + } + }, + "requirements": [ + [ + "0" + ] + ] +} \ No newline at end of file diff --git a/src/main/resources/data/create/advancements/lava_wheel.json b/src/main/resources/data/create/advancements/lava_wheel.json new file mode 100644 index 000000000..16aff1ad9 --- /dev/null +++ b/src/main/resources/data/create/advancements/lava_wheel.json @@ -0,0 +1,28 @@ +{ + "parent": "create:water_wheel", + "display": { + "icon": { + "item": "minecraft:lava_bucket" + }, + "title": { + "translate": "advancement.create.lava_wheel" + }, + "description": { + "translate": "advancement.create.lava_wheel.desc" + }, + "frame": "goal", + "show_toast": true, + "announce_to_chat": true, + "hidden": true + }, + "criteria": { + "0": { + "trigger": "create:lava_wheel" + } + }, + "requirements": [ + [ + "0" + ] + ] +} \ No newline at end of file diff --git a/src/main/resources/data/create/advancements/mechanical_mixer.json b/src/main/resources/data/create/advancements/mechanical_mixer.json deleted file mode 100644 index 8c633569e..000000000 --- a/src/main/resources/data/create/advancements/mechanical_mixer.json +++ /dev/null @@ -1,30 +0,0 @@ -{ - "display": { - "title": { - "translate": "advancement.create:mixer" - }, - "description": { - "translate": "advancement.create:mixer.desc" - }, - "icon": { - "item": "create:mechanical_mixer" - }, - "frame": "task", - "show_toast": true, - "announce_to_chat": false, - "hidden": false - }, - "criteria": { - "mixer": { - "trigger": "minecraft:inventory_changed", - "conditions": { - "items": [ - { - "item": "create:mechanical_mixer" - } - ] - } - } - }, - "parent": "create:mechanical_press" -} \ No newline at end of file diff --git a/src/main/resources/data/create/advancements/mechanical_press.json b/src/main/resources/data/create/advancements/mechanical_press.json deleted file mode 100644 index aff99de88..000000000 --- a/src/main/resources/data/create/advancements/mechanical_press.json +++ /dev/null @@ -1,48 +0,0 @@ -{ - "display": { - "title": { - "translate": "advancement.create:press" - }, - "description": { - "translate": "advancement.create:press.desc" - }, - "icon": { - "item": "create:mechanical_press" - }, - "frame": "goal", - "show_toast": true, - "announce_to_chat": true, - "hidden": false - }, - "criteria": { - "press": { - "trigger": "minecraft:inventory_changed", - "conditions": { - "items": [ - { - "item": "create:mechanical_press" - } - ] - } - }, - "plate": { - "trigger": "minecraft:inventory_changed", - "conditions": { - "items": [ - { - "tag": "forge:plates" - } - ] - } - } - }, - "requirements": [ - [ - "press" - ], - [ - "plate" - ] - ], - "parent": "create:andesite_casing" -} \ No newline at end of file diff --git a/src/main/resources/data/create/advancements/millstone.json b/src/main/resources/data/create/advancements/millstone.json new file mode 100644 index 000000000..eaca3ad04 --- /dev/null +++ b/src/main/resources/data/create/advancements/millstone.json @@ -0,0 +1,40 @@ +{ + "parent": "create:andesite_alloy", + "display": { + "icon": { + "item": "create:millstone" + }, + "title": { + "translate": "advancement.create.millstone" + }, + "description": { + "translate": "advancement.create.millstone.desc" + }, + "frame": "task", + "show_toast": true, + "announce_to_chat": false, + "hidden": false + }, + "criteria": { + "0": { + "trigger": "minecraft:placed_block", + "conditions": { + "block": "create:millstone" + } + }, + "1": { + "trigger": "create:kinetic_block", + "conditions": { + "block": "create:millstone" + } + } + }, + "requirements": [ + [ + "0" + ], + [ + "1" + ] + ] +} \ No newline at end of file diff --git a/src/main/resources/data/create/advancements/mixer.json b/src/main/resources/data/create/advancements/mixer.json new file mode 100644 index 000000000..5988c6b10 --- /dev/null +++ b/src/main/resources/data/create/advancements/mixer.json @@ -0,0 +1,46 @@ +{ + "parent": "create:basin", + "display": { + "icon": { + "item": "create:mechanical_mixer" + }, + "title": { + "translate": "advancement.create.mixer" + }, + "description": { + "translate": "advancement.create.mixer.desc" + }, + "frame": "task", + "show_toast": true, + "announce_to_chat": true, + "hidden": false + }, + "criteria": { + "0": { + "trigger": "minecraft:placed_block", + "conditions": { + "block": "create:mechanical_mixer" + } + }, + "1": { + "trigger": "create:kinetic_block", + "conditions": { + "block": "create:mechanical_mixer" + } + }, + "2": { + "trigger": "create:mixer" + } + }, + "requirements": [ + [ + "0" + ], + [ + "1" + ], + [ + "2" + ] + ] +} \ No newline at end of file diff --git a/src/main/resources/data/create/advancements/overstressed.json b/src/main/resources/data/create/advancements/overstressed.json index 614d5d50c..54dc44251 100644 --- a/src/main/resources/data/create/advancements/overstressed.json +++ b/src/main/resources/data/create/advancements/overstressed.json @@ -1,24 +1,28 @@ { - "display": { - "title": { - "translate": "advancement.create:overstressed", - "color": "red" - }, - "description": { - "translate": "advancement.create:overstressed.desc" - }, - "icon": { - "item": "minecraft:barrier" - }, - "frame": "task", - "show_toast": true, - "announce_to_chat": false, - "hidden": true + "parent": "create:its_alive", + "display": { + "icon": { + "item": "minecraft:barrier" }, - "criteria": { - "alloy": { - "trigger": "create:overstressed" - } + "title": { + "translate": "advancement.create.overstressed" }, - "parent": "create:rotation" + "description": { + "translate": "advancement.create.overstressed.desc" + }, + "frame": "goal", + "show_toast": true, + "announce_to_chat": true, + "hidden": true + }, + "criteria": { + "0": { + "trigger": "create:overstressed" + } + }, + "requirements": [ + [ + "0" + ] + ] } \ No newline at end of file diff --git a/src/main/resources/data/create/advancements/polished_rose_quartz.json b/src/main/resources/data/create/advancements/polished_rose_quartz.json index 1684697b4..b1decb17f 100644 --- a/src/main/resources/data/create/advancements/polished_rose_quartz.json +++ b/src/main/resources/data/create/advancements/polished_rose_quartz.json @@ -1,32 +1,35 @@ { - "display": { - "title": { - "translate": "advancement.create:polished_rose_quartz", - "color": "red" - }, - "description": { - "translate": "advancement.create:polished_rose_quartz.desc" - }, - "icon": { + "parent": "create:andesite_casing", + "display": { + "icon": { + "item": "create:polished_rose_quartz" + }, + "title": { + "translate": "advancement.create.polished_rose_quartz" + }, + "description": { + "translate": "advancement.create.polished_rose_quartz.desc" + }, + "frame": "task", + "show_toast": true, + "announce_to_chat": false, + "hidden": false + }, + "criteria": { + "0": { + "trigger": "minecraft:inventory_changed", + "conditions": { + "items": [ + { "item": "create:polished_rose_quartz" - }, - "frame": "task", - "show_toast": true, - "announce_to_chat": false, - "hidden": true - }, - "criteria": { - "quartz": { - "trigger": "create:sandpaper_use", - "conditions": { - "target": { - "item": "create:rose_quartz" - }, - "result": { - "item": "create:polished_rose_quartz" - } - } - } - }, - "parent": "create:sand_paper" + } + ] + } + } + }, + "requirements": [ + [ + "0" + ] + ] } \ No newline at end of file diff --git a/src/main/resources/data/create/advancements/press.json b/src/main/resources/data/create/advancements/press.json new file mode 100644 index 000000000..500a857a2 --- /dev/null +++ b/src/main/resources/data/create/advancements/press.json @@ -0,0 +1,28 @@ +{ + "parent": "create:andesite_casing", + "display": { + "icon": { + "item": "create:mechanical_press" + }, + "title": { + "translate": "advancement.create.press" + }, + "description": { + "translate": "advancement.create.press.desc" + }, + "frame": "task", + "show_toast": true, + "announce_to_chat": true, + "hidden": false + }, + "criteria": { + "0": { + "trigger": "create:bonk" + } + }, + "requirements": [ + [ + "0" + ] + ] +} \ No newline at end of file diff --git a/src/main/resources/data/create/advancements/refined_radiance.json b/src/main/resources/data/create/advancements/refined_radiance.json index 6b3a5adfe..ade3d9379 100644 --- a/src/main/resources/data/create/advancements/refined_radiance.json +++ b/src/main/resources/data/create/advancements/refined_radiance.json @@ -1,31 +1,35 @@ { - "display": { - "title": { - "translate": "advancement.create:refined_radiance", - "color": "white" - }, - "description": { - "translate": "advancement.create:refined_radiance.desc" - }, - "icon": { + "parent": "create:chromatic_compound", + "display": { + "icon": { + "item": "create:refined_radiance" + }, + "title": { + "translate": "advancement.create.refined_radiance" + }, + "description": { + "translate": "advancement.create.refined_radiance.desc" + }, + "frame": "goal", + "show_toast": true, + "announce_to_chat": true, + "hidden": false + }, + "criteria": { + "0": { + "trigger": "minecraft:inventory_changed", + "conditions": { + "items": [ + { "item": "create:refined_radiance" - }, - "frame": "goal", - "show_toast": true, - "announce_to_chat": true, - "hidden": false - }, - "criteria": { - "radiance": { - "trigger": "minecraft:inventory_changed", - "conditions": { - "items": [ - { - "item": "create:refined_radiance" - } - ] - } - } - }, - "parent": "create:chromatic_compound" + } + ] + } + } + }, + "requirements": [ + [ + "0" + ] + ] } \ No newline at end of file diff --git a/src/main/resources/data/create/advancements/refined_radiance_secret.json b/src/main/resources/data/create/advancements/refined_radiance_secret.json deleted file mode 100644 index 02272aa91..000000000 --- a/src/main/resources/data/create/advancements/refined_radiance_secret.json +++ /dev/null @@ -1,24 +0,0 @@ -{ - "display": { - "title": { - "translate": "advancement.create:refined_radiance_secret", - "color": "white" - }, - "description": { - "translate": "advancement.create:refined_radiance_secret.desc" - }, - "icon": { - "item": "create:refined_radiance" - }, - "frame": "challenge", - "show_toast": true, - "announce_to_chat": true, - "hidden": true - }, - "criteria": { - "ritual": { - "trigger": "create:light_absorbed" - } - }, - "parent": "create:chromatic_compound" -} \ No newline at end of file diff --git a/src/main/resources/data/create/advancements/root.json b/src/main/resources/data/create/advancements/root.json index bb037c316..8242acf23 100644 --- a/src/main/resources/data/create/advancements/root.json +++ b/src/main/resources/data/create/advancements/root.json @@ -1,21 +1,29 @@ { "display": { "icon": { - "item": "create:brass_ingot" + "item": "create:brass_hand" }, "title": { - "translate": "advancement.create:root" + "translate": "advancement.create.root" }, "description": { - "translate": "advancement.create:root.desc" + "translate": "advancement.create.root.desc" }, - "background": "create:textures/block/scoria_bricks.png", + "frame": "task", "show_toast": false, - "announce_to_chat": false + "announce_to_chat": false, + "hidden": false, + "background": "create:textures/block/scoria_bricks.png" }, "criteria": { - "flower": { - "trigger": "minecraft:inventory_changed" + "0": { + "trigger": "minecraft:inventory_changed", + "conditions": {} } - } + }, + "requirements": [ + [ + "0" + ] + ] } \ No newline at end of file diff --git a/src/main/resources/data/create/advancements/rotation.json b/src/main/resources/data/create/advancements/rotation.json deleted file mode 100644 index 5f987ec18..000000000 --- a/src/main/resources/data/create/advancements/rotation.json +++ /dev/null @@ -1,23 +0,0 @@ -{ - "display": { - "title": { - "translate": "advancement.create:rotation" - }, - "description": { - "translate": "advancement.create:rotation.desc" - }, - "icon": { - "item": "create:cogwheel" - }, - "frame": "task", - "show_toast": true, - "announce_to_chat": true, - "hidden": true - }, - "criteria": { - "alloy": { - "trigger": "create:rotation" - } - }, - "parent": "create:andesite_alloy" -} \ No newline at end of file diff --git a/src/main/resources/data/create/advancements/sand_paper.json b/src/main/resources/data/create/advancements/sand_paper.json deleted file mode 100644 index fd289f9dd..000000000 --- a/src/main/resources/data/create/advancements/sand_paper.json +++ /dev/null @@ -1,47 +0,0 @@ -{ - "display": { - "title": { - "translate": "advancement.create:sand_paper", - "color": "yellow" - }, - "description": { - "translate": "advancement.create:sand_paper.desc" - }, - "icon": { - "item": "create:sand_paper" - }, - "frame": "task", - "show_toast": true, - "announce_to_chat": false, - "hidden": true - }, - "criteria": { - "paperNormal": { - "trigger": "minecraft:inventory_changed", - "conditions": { - "items": [ - { - "item": "create:sand_paper" - } - ] - } - }, - "paperRed": { - "trigger": "minecraft:inventory_changed", - "conditions": { - "items": [ - { - "item": "create:red_sand_paper" - } - ] - } - } - }, - "requirements": [ - [ - "paperNormal", - "paperRed" - ] - ], - "parent": "create:root" -} \ No newline at end of file diff --git a/src/main/resources/data/create/advancements/sand_paper_secret.json b/src/main/resources/data/create/advancements/sand_paper_secret.json deleted file mode 100644 index 79097b1a2..000000000 --- a/src/main/resources/data/create/advancements/sand_paper_secret.json +++ /dev/null @@ -1,43 +0,0 @@ -{ - "display": { - "title": { - "translate": "advancement.create:sand_paper_secret", - "color": "yellow" - }, - "description": { - "translate": "advancement.create:sand_paper_secret.desc" - }, - "icon": { - "item": "create:red_sand_paper" - }, - "frame": "goal", - "show_toast": true, - "announce_to_chat": true, - "hidden": true - }, - "criteria": { - "normal": { - "trigger": "create:sandpaper_use", - "conditions": { - "result": { - "item": "create:sand_paper" - } - } - }, - "red": { - "trigger": "create:sandpaper_use", - "conditions": { - "result": { - "item": "create:red_sand_paper" - } - } - } - }, - "requirements": [ - [ - "normal", - "red" - ] - ], - "parent": "create:sand_paper" -} \ No newline at end of file diff --git a/src/main/resources/data/create/advancements/saw.json b/src/main/resources/data/create/advancements/saw.json new file mode 100644 index 000000000..575553fc8 --- /dev/null +++ b/src/main/resources/data/create/advancements/saw.json @@ -0,0 +1,40 @@ +{ + "parent": "create:press", + "display": { + "icon": { + "item": "create:saw" + }, + "title": { + "translate": "advancement.create.saw" + }, + "description": { + "translate": "advancement.create.saw.desc" + }, + "frame": "task", + "show_toast": true, + "announce_to_chat": false, + "hidden": false + }, + "criteria": { + "0": { + "trigger": "minecraft:placed_block", + "conditions": { + "block": "create:saw" + } + }, + "1": { + "trigger": "create:kinetic_block", + "conditions": { + "block": "create:saw" + } + } + }, + "requirements": [ + [ + "0" + ], + [ + "1" + ] + ] +} \ No newline at end of file diff --git a/src/main/resources/data/create/advancements/shadow_steel.json b/src/main/resources/data/create/advancements/shadow_steel.json index 8c4f7b7a1..a9df6c1c0 100644 --- a/src/main/resources/data/create/advancements/shadow_steel.json +++ b/src/main/resources/data/create/advancements/shadow_steel.json @@ -1,30 +1,35 @@ { - "display": { - "title": { - "translate": "advancement.create:shadow_steel" - }, - "description": { - "translate": "advancement.create:shadow_steel.desc" - }, - "icon": { + "parent": "create:chromatic_compound", + "display": { + "icon": { + "item": "create:shadow_steel" + }, + "title": { + "translate": "advancement.create.shadow_steel" + }, + "description": { + "translate": "advancement.create.shadow_steel.desc" + }, + "frame": "goal", + "show_toast": true, + "announce_to_chat": true, + "hidden": false + }, + "criteria": { + "0": { + "trigger": "minecraft:inventory_changed", + "conditions": { + "items": [ + { "item": "create:shadow_steel" - }, - "frame": "goal", - "show_toast": true, - "announce_to_chat": true, - "hidden": false - }, - "criteria": { - "alloy": { - "trigger": "minecraft:inventory_changed", - "conditions": { - "items": [ - { - "item": "create:shadow_steel" - } - ] - } - } - }, - "parent": "create:chromatic_compound" + } + ] + } + } + }, + "requirements": [ + [ + "0" + ] + ] } \ No newline at end of file diff --git a/src/main/resources/data/create/advancements/shifting_gears.json b/src/main/resources/data/create/advancements/shifting_gears.json new file mode 100644 index 000000000..5c1039659 --- /dev/null +++ b/src/main/resources/data/create/advancements/shifting_gears.json @@ -0,0 +1,28 @@ +{ + "parent": "create:its_alive", + "display": { + "icon": { + "item": "create:large_cogwheel" + }, + "title": { + "translate": "advancement.create.shifting_gears" + }, + "description": { + "translate": "advancement.create.shifting_gears.desc" + }, + "frame": "task", + "show_toast": true, + "announce_to_chat": false, + "hidden": false + }, + "criteria": { + "0": { + "trigger": "create:shifting_gears" + } + }, + "requirements": [ + [ + "0" + ] + ] +} \ No newline at end of file diff --git a/src/main/resources/data/create/advancements/speed_gauge.json b/src/main/resources/data/create/advancements/speed_gauge.json new file mode 100644 index 000000000..3b738054c --- /dev/null +++ b/src/main/resources/data/create/advancements/speed_gauge.json @@ -0,0 +1,40 @@ +{ + "parent": "create:goggles", + "display": { + "icon": { + "item": "create:speed_gauge" + }, + "title": { + "translate": "advancement.create.speed_gauge" + }, + "description": { + "translate": "advancement.create.speed_gauge.desc" + }, + "frame": "task", + "show_toast": true, + "announce_to_chat": false, + "hidden": false + }, + "criteria": { + "0": { + "trigger": "minecraft:placed_block", + "conditions": { + "block": "create:speed_gauge" + } + }, + "1": { + "trigger": "create:kinetic_block", + "conditions": { + "block": "create:speed_gauge" + } + } + }, + "requirements": [ + [ + "0" + ], + [ + "1" + ] + ] +} \ No newline at end of file diff --git a/src/main/resources/data/create/advancements/speed_secret.json b/src/main/resources/data/create/advancements/speed_secret.json deleted file mode 100644 index d867129ad..000000000 --- a/src/main/resources/data/create/advancements/speed_secret.json +++ /dev/null @@ -1,24 +0,0 @@ -{ - "display": { - "title": { - "translate": "advancement.create:speed_secret", - "color": "red" - }, - "description": { - "translate": "advancement.create:speed_secret.desc" - }, - "icon": { - "item": "create:speed_gauge" - }, - "frame": "goal", - "show_toast": true, - "announce_to_chat": true, - "hidden": true - }, - "criteria": { - "alloy": { - "trigger": "create:speed_read" - } - }, - "parent": "create:root" -} \ No newline at end of file diff --git a/src/main/resources/data/create/advancements/stress_gauge.json b/src/main/resources/data/create/advancements/stress_gauge.json new file mode 100644 index 000000000..cb6bd9b88 --- /dev/null +++ b/src/main/resources/data/create/advancements/stress_gauge.json @@ -0,0 +1,40 @@ +{ + "parent": "create:goggles", + "display": { + "icon": { + "item": "create:stress_gauge" + }, + "title": { + "translate": "advancement.create.stress_gauge" + }, + "description": { + "translate": "advancement.create.stress_gauge.desc" + }, + "frame": "task", + "show_toast": true, + "announce_to_chat": false, + "hidden": false + }, + "criteria": { + "0": { + "trigger": "minecraft:placed_block", + "conditions": { + "block": "create:stress_gauge" + } + }, + "1": { + "trigger": "create:kinetic_block", + "conditions": { + "block": "create:stress_gauge" + } + } + }, + "requirements": [ + [ + "0" + ], + [ + "1" + ] + ] +} \ No newline at end of file diff --git a/src/main/resources/data/create/advancements/water_wheel.json b/src/main/resources/data/create/advancements/water_wheel.json new file mode 100644 index 000000000..677d41082 --- /dev/null +++ b/src/main/resources/data/create/advancements/water_wheel.json @@ -0,0 +1,28 @@ +{ + "parent": "create:andesite_alloy", + "display": { + "icon": { + "item": "create:water_wheel" + }, + "title": { + "translate": "advancement.create.water_wheel" + }, + "description": { + "translate": "advancement.create.water_wheel.desc" + }, + "frame": "task", + "show_toast": true, + "announce_to_chat": false, + "hidden": false + }, + "criteria": { + "0": { + "trigger": "create:water_wheel" + } + }, + "requirements": [ + [ + "0" + ] + ] +} \ No newline at end of file diff --git a/src/main/resources/data/create/advancements/wrench.json b/src/main/resources/data/create/advancements/wrench.json new file mode 100644 index 000000000..9c50bf400 --- /dev/null +++ b/src/main/resources/data/create/advancements/wrench.json @@ -0,0 +1,35 @@ +{ + "parent": "create:its_alive", + "display": { + "icon": { + "item": "create:wrench" + }, + "title": { + "translate": "advancement.create.wrench" + }, + "description": { + "translate": "advancement.create.wrench.desc" + }, + "frame": "task", + "show_toast": true, + "announce_to_chat": false, + "hidden": false + }, + "criteria": { + "0": { + "trigger": "minecraft:inventory_changed", + "conditions": { + "items": [ + { + "item": "create:wrench" + } + ] + } + } + }, + "requirements": [ + [ + "0" + ] + ] +} \ No newline at end of file