use of com.simibubi.create.foundation.ponder.element.BeltItemElement in project Create by Creators-of-Create.
the class FanScenes method processing.
public static void processing(SceneBuilder scene, SceneBuildingUtil util) {
scene.title("fan_processing", "Processing Items using Encased Fans");
scene.configureBasePlate(1, 0, 5);
scene.world.showSection(util.select.layer(0).substract(util.select.position(0, 0, 4)), Direction.UP);
scene.idle(5);
scene.world.showSection(util.select.fromTo(6, 1, 2, 5, 1, 2).add(util.select.position(1, 1, 2)), Direction.DOWN);
scene.idle(25);
BlockPos blockPos = util.grid.at(4, 1, 2);
// blasting start
ElementLink<WorldSectionElement> blockInFront = scene.world.showIndependentSection(util.select.position(3, 1, 0), Direction.SOUTH);
scene.world.moveSection(blockInFront, util.vector.of(1, 0, 2), 0);
scene.world.setBlock(blockPos, Blocks.LAVA.defaultBlockState(), false);
scene.idle(10);
scene.overlay.showSelectionWithText(util.select.fromTo(blockPos, blockPos.west(2)), 80).colored(PonderPalette.RED).text("When passing through lava, the Air Flow becomes Heated");
scene.idle(80);
ItemStack stack = new ItemStack(Items.GOLD_ORE);
ItemStack smelted = new ItemStack(Items.GOLD_INGOT);
ElementLink<EntityElement> entityLink = scene.world.createItemEntity(util.vector.centerOf(blockPos.west(2).above(2)), util.vector.of(0, 0.1, 0), stack);
scene.idle(15);
scene.world.modifyEntity(entityLink, e -> e.setDeltaMovement(-0.2f, 0, 0));
Vec3 itemVec = util.vector.blockSurface(util.grid.at(1, 1, 2), Direction.EAST).add(0.1, 0, 0);
scene.overlay.showControls(new InputWindowElement(itemVec, Pointing.DOWN).withItem(stack), 20);
scene.idle(20);
scene.effects.emitParticles(itemVec.add(0, 0.2f, 0), Emitter.simple(ParticleTypes.LARGE_SMOKE, Vec3.ZERO), 1, 60);
scene.overlay.showText(80).colored(PonderPalette.WHITE).pointAt(itemVec).placeNearTarget().attachKeyFrame().text("Items caught in the area will be smelted");
scene.idle(60);
scene.world.modifyEntities(ItemEntity.class, ie -> ie.setItem(smelted));
scene.idle(40);
scene.overlay.showControls(new InputWindowElement(itemVec, Pointing.DOWN).withItem(smelted), 20);
scene.idle(20);
scene.world.modifyEntities(ItemEntity.class, Entity::discard);
scene.idle(20);
scene.overlay.showText(80).colored(PonderPalette.RED).pointAt(itemVec).placeNearTarget().text("Food items thrown here would be incinerated");
scene.idle(40);
// smoking start
BlockState campfire = Blocks.FIRE.defaultBlockState();
scene.world.hideIndependentSection(blockInFront, Direction.NORTH);
scene.idle(15);
scene.world.setBlock(util.grid.at(3, 1, 0), campfire, false);
scene.world.setBlock(blockPos, campfire, true);
blockInFront = scene.world.showIndependentSection(util.select.position(3, 1, 0), Direction.NORTH);
scene.world.moveSection(blockInFront, util.vector.of(1, 0, 2), 0);
scene.idle(50);
scene.overlay.showSelectionWithText(util.select.fromTo(blockPos, blockPos.west(2)), 60).colored(PonderPalette.BLACK).attachKeyFrame().text("Instead, a setup for Smoking using Fire should be used for them");
scene.idle(80);
// washing start
BlockState water = Blocks.WATER.defaultBlockState();
scene.world.hideIndependentSection(blockInFront, Direction.NORTH);
scene.idle(15);
scene.world.setBlock(util.grid.at(3, 1, 0), water, false);
scene.world.setBlock(blockPos, water, true);
blockInFront = scene.world.showIndependentSection(util.select.position(3, 1, 0), Direction.NORTH);
scene.world.moveSection(blockInFront, util.vector.of(1, 0, 2), 0);
scene.idle(20);
scene.overlay.showSelectionWithText(util.select.fromTo(blockPos, blockPos.west(2)), 60).colored(PonderPalette.MEDIUM).attachKeyFrame().text("Air Flows passing through water create a Washing Setup");
scene.idle(70);
stack = new ItemStack(Items.RED_SAND, 16);
ItemStack washed = new ItemStack(Items.GOLD_NUGGET, 16);
entityLink = scene.world.createItemEntity(util.vector.centerOf(blockPos.west(2).above(2)), util.vector.of(0, 0.1, 0), stack);
scene.idle(15);
scene.world.modifyEntity(entityLink, e -> e.setDeltaMovement(-0.2f, 0, 0));
scene.overlay.showControls(new InputWindowElement(itemVec, Pointing.DOWN).withItem(stack), 20);
scene.idle(20);
scene.effects.emitParticles(itemVec.add(0, 0.2f, 0), Emitter.simple(ParticleTypes.SPIT, Vec3.ZERO), 1, 60);
scene.overlay.showText(50).colored(PonderPalette.WHITE).pointAt(itemVec).placeNearTarget().text("Some interesting new processing can be done with it");
scene.idle(60);
scene.world.modifyEntities(ItemEntity.class, ie -> ie.setItem(washed));
scene.overlay.showControls(new InputWindowElement(itemVec, Pointing.DOWN).withItem(washed), 20);
scene.idle(20);
scene.world.modifyEntities(ItemEntity.class, Entity::discard);
scene.idle(20);
scene.overlay.showText(100).colored(PonderPalette.RED).pointAt(util.vector.topOf(blockPos.east())).placeNearTarget().attachKeyFrame().text("The Speed of the Fan does NOT affect the processing speed, only its range");
scene.world.destroyBlock(util.grid.at(1, 1, 2));
scene.idle(110);
ElementLink<WorldSectionElement> cogs = scene.world.makeSectionIndependent(util.select.fromTo(6, 1, 2, 6, 0, 3).add(util.select.fromTo(4, 0, 2, 5, 0, 2)));
scene.world.modifyKineticSpeed(util.select.position(5, 2, 2), f -> f / 3f);
scene.world.moveSection(cogs, util.vector.of(0, 1, 0), 15);
scene.world.moveSection(blockInFront, util.vector.of(0, 1, 0), 15);
scene.world.destroyBlock(blockPos.east());
scene.world.showSection(util.select.position(blockPos.east().above()), Direction.DOWN);
scene.world.setBlock(blockPos.above(), Blocks.WATER.defaultBlockState(), false);
ItemStack sand = new ItemStack(Items.SAND);
ItemStack clay = new ItemStack(Items.CLAY_BALL);
scene.idle(20);
BlockPos depos = util.grid.at(3, 4, 2);
ElementLink<WorldSectionElement> depot = scene.world.showIndependentSection(util.select.position(depos), Direction.DOWN);
scene.world.moveSection(depot, util.vector.of(-1, -3, 0), 0);
scene.world.createItemOnBeltLike(depos, Direction.NORTH, sand);
scene.idle(10);
Vec3 depotTop = util.vector.topOf(2, 1, 2).add(0, 0.25, 0);
scene.effects.emitParticles(depotTop, Emitter.simple(ParticleTypes.SPIT, Vec3.ZERO), .5f, 30);
scene.idle(30);
scene.world.modifyTileNBT(util.select.position(depos), DepotTileEntity.class, nbt -> nbt.put("HeldItem", new TransportedItemStack(clay).serializeNBT()));
scene.effects.emitParticles(depotTop, Emitter.simple(ParticleTypes.SPIT, Vec3.ZERO), .5f, 30);
scene.overlay.showText(90).pointAt(depotTop).attachKeyFrame().text("Fan Processing can also be applied to Items on Depots and Belts");
scene.idle(100);
scene.world.moveSection(depot, util.vector.of(-1, 0, 0), 15);
scene.idle(15);
ElementLink<WorldSectionElement> largeCog = scene.world.showIndependentSection(util.select.position(1, 2, 4), Direction.UP);
ElementLink<WorldSectionElement> belt = scene.world.showIndependentSection(util.select.fromTo(3, 3, 1, 1, 3, 3), Direction.DOWN);
scene.world.moveSection(largeCog, util.vector.of(-1, -2, 0), 0);
scene.world.moveSection(belt, util.vector.of(-1, -2, 0), 0);
ElementLink<BeltItemElement> transported = scene.world.createItemOnBelt(util.grid.at(3, 3, 3), Direction.SOUTH, sand);
scene.idle(60);
scene.effects.emitParticles(depotTop, Emitter.simple(ParticleTypes.SPIT, Vec3.ZERO), .5f, 25);
scene.idle(25);
scene.world.changeBeltItemTo(transported, new ItemStack(Items.CLAY_BALL));
scene.effects.emitParticles(depotTop, Emitter.simple(ParticleTypes.SPIT, Vec3.ZERO), .5f, 25);
scene.idle(60);
scene.world.setKineticSpeed(util.select.position(1, 2, 4).add(util.select.fromTo(3, 3, 1, 1, 3, 3)), 0);
}
use of com.simibubi.create.foundation.ponder.element.BeltItemElement in project Create by Creators-of-Create.
the class ProcessingScenes method pressing.
public static void pressing(SceneBuilder scene, SceneBuildingUtil util) {
scene.title("mechanical_press", "Processing Items with the Mechanical Press");
scene.configureBasePlate(0, 0, 5);
scene.world.showSection(util.select.layer(0), Direction.UP);
scene.idle(5);
ElementLink<WorldSectionElement> depot = scene.world.showIndependentSection(util.select.position(2, 1, 1), Direction.DOWN);
scene.world.moveSection(depot, util.vector.of(0, 0, 1), 0);
scene.idle(10);
Selection pressS = util.select.position(2, 3, 2);
BlockPos pressPos = util.grid.at(2, 3, 2);
BlockPos depotPos = util.grid.at(2, 1, 1);
scene.world.setKineticSpeed(pressS, 0);
scene.world.showSection(pressS, Direction.DOWN);
scene.idle(10);
scene.world.showSection(util.select.fromTo(2, 1, 3, 2, 1, 5), Direction.NORTH);
scene.idle(3);
scene.world.showSection(util.select.position(2, 2, 3), Direction.SOUTH);
scene.idle(3);
scene.world.showSection(util.select.position(2, 3, 3), Direction.NORTH);
scene.world.setKineticSpeed(pressS, -32);
scene.effects.indicateSuccess(pressPos);
scene.idle(10);
Vec3 pressSide = util.vector.blockSurface(pressPos, Direction.WEST);
scene.overlay.showText(60).pointAt(pressSide).placeNearTarget().attachKeyFrame().text("The Mechanical Press can process items provided beneath it");
scene.idle(70);
scene.overlay.showText(60).pointAt(pressSide.subtract(0, 2, 0)).placeNearTarget().text("The Input items can be dropped or placed on a Depot under the Press");
scene.idle(50);
ItemStack copper = new ItemStack(Items.COPPER_INGOT);
scene.world.createItemOnBeltLike(depotPos, Direction.NORTH, copper);
Vec3 depotCenter = util.vector.centerOf(depotPos.south());
scene.overlay.showControls(new InputWindowElement(depotCenter, Pointing.UP).withItem(copper), 30);
scene.idle(10);
Class<MechanicalPressTileEntity> type = MechanicalPressTileEntity.class;
scene.world.modifyTileEntity(pressPos, type, pte -> pte.start(Mode.BELT));
scene.idle(30);
scene.world.modifyTileEntity(pressPos, type, pte -> pte.makePressingParticleEffect(depotCenter.add(0, 8 / 16f, 0), copper));
scene.world.removeItemsFromBelt(depotPos);
ItemStack sheet = AllItems.COPPER_SHEET.asStack();
scene.world.createItemOnBeltLike(depotPos, Direction.UP, sheet);
scene.idle(10);
scene.overlay.showControls(new InputWindowElement(depotCenter, Pointing.UP).withItem(sheet), 50);
scene.idle(60);
scene.world.hideIndependentSection(depot, Direction.NORTH);
scene.idle(5);
scene.world.showSection(util.select.fromTo(0, 1, 3, 0, 2, 3), Direction.DOWN);
scene.idle(10);
scene.world.showSection(util.select.fromTo(4, 1, 2, 0, 2, 2), Direction.SOUTH);
scene.idle(20);
BlockPos beltPos = util.grid.at(0, 1, 2);
scene.overlay.showText(40).pointAt(util.vector.blockSurface(beltPos, Direction.WEST)).placeNearTarget().attachKeyFrame().text("When items are provided on a belt...");
scene.idle(30);
ElementLink<BeltItemElement> ingot = scene.world.createItemOnBelt(beltPos, Direction.SOUTH, copper);
scene.idle(15);
ElementLink<BeltItemElement> ingot2 = scene.world.createItemOnBelt(beltPos, Direction.SOUTH, copper);
scene.idle(15);
scene.world.stallBeltItem(ingot, true);
scene.world.modifyTileEntity(pressPos, type, pte -> pte.start(Mode.BELT));
scene.overlay.showText(50).pointAt(pressSide).placeNearTarget().attachKeyFrame().text("The Press will hold and process them automatically");
scene.idle(30);
scene.world.modifyTileEntity(pressPos, type, pte -> pte.makePressingParticleEffect(depotCenter.add(0, 8 / 16f, 0), copper));
scene.world.removeItemsFromBelt(pressPos.below(2));
ingot = scene.world.createItemOnBelt(pressPos.below(2), Direction.UP, sheet);
scene.world.stallBeltItem(ingot, true);
scene.idle(15);
scene.world.stallBeltItem(ingot, false);
scene.idle(15);
scene.world.stallBeltItem(ingot2, true);
scene.world.modifyTileEntity(pressPos, type, pte -> pte.start(Mode.BELT));
scene.idle(30);
scene.world.modifyTileEntity(pressPos, type, pte -> pte.makePressingParticleEffect(depotCenter.add(0, 8 / 16f, 0), copper));
scene.world.removeItemsFromBelt(pressPos.below(2));
ingot2 = scene.world.createItemOnBelt(pressPos.below(2), Direction.UP, sheet);
scene.world.stallBeltItem(ingot2, true);
scene.idle(15);
scene.world.stallBeltItem(ingot2, false);
}
use of com.simibubi.create.foundation.ponder.element.BeltItemElement in project Create by Creators-of-Create.
the class DebugScenes method itemScene.
public static void itemScene(SceneBuilder scene, SceneBuildingUtil util) {
scene.title("debug_items", "Manipulating Items");
scene.configureBasePlate(0, 0, 6);
scene.world.showSection(util.select.layer(0), Direction.UP);
scene.idle(10);
scene.world.showSection(util.select.layersFrom(1), Direction.DOWN);
ItemStack brassItem = AllItems.BRASS_INGOT.asStack();
ItemStack copperItem = new ItemStack(Items.COPPER_INGOT);
for (int z = 4; z >= 2; z--) {
scene.world.createItemEntity(util.vector.centerOf(0, 4, z), Vec3.ZERO, brassItem.copy());
scene.idle(10);
}
BlockPos beltPos = util.grid.at(2, 1, 3);
ElementLink<BeltItemElement> itemOnBelt = scene.world.createItemOnBelt(beltPos, Direction.EAST, copperItem.copy());
scene.idle(10);
scene.world.stallBeltItem(itemOnBelt, true);
scene.idle(5);
scene.overlay.showText(40).colored(PonderPalette.FAST).text("Belt Items can only be force-stalled on the belt they were created on.").pointAt(util.vector.topOf(2, 1, 2));
scene.idle(45);
scene.world.stallBeltItem(itemOnBelt, false);
scene.idle(20);
scene.world.modifyEntities(ItemEntity.class, entity -> {
if (copperItem.sameItem(entity.getItem()))
entity.setNoGravity(true);
});
scene.idle(20);
scene.world.modifyEntities(ItemEntity.class, entity -> {
if (brassItem.sameItem(entity.getItem()))
entity.setDeltaMovement(util.vector.of(-.15f, .5f, 0));
});
scene.idle(27);
scene.world.modifyEntities(ItemEntity.class, Entity::discard);
}
use of com.simibubi.create.foundation.ponder.element.BeltItemElement in project Create by Creators-of-Create.
the class DeployerScenes method processing.
public static void processing(SceneBuilder scene, SceneBuildingUtil util) {
scene.title("deployer_processing", "Processing Items using Deployers");
scene.configureBasePlate(0, 0, 5);
scene.world.showSection(util.select.layer(0), Direction.UP);
scene.idle(5);
ElementLink<WorldSectionElement> depot = scene.world.showIndependentSection(util.select.position(2, 1, 1), Direction.DOWN);
scene.world.moveSection(depot, util.vector.of(0, 0, 1), 0);
scene.idle(10);
Selection pressS = util.select.position(2, 3, 2);
BlockPos pressPos = util.grid.at(2, 3, 2);
BlockPos depotPos = util.grid.at(2, 1, 1);
scene.world.setKineticSpeed(pressS, 0);
scene.world.showSection(pressS, Direction.DOWN);
scene.idle(10);
scene.world.showSection(util.select.fromTo(2, 1, 3, 2, 1, 5), Direction.NORTH);
scene.idle(3);
scene.world.showSection(util.select.position(2, 2, 3), Direction.SOUTH);
scene.idle(3);
scene.world.showSection(util.select.position(2, 3, 3), Direction.NORTH);
scene.world.setKineticSpeed(pressS, -32);
scene.effects.indicateSuccess(pressPos);
scene.idle(10);
ItemStack tool = AllItems.SAND_PAPER.asStack();
scene.overlay.showControls(new InputWindowElement(util.vector.blockSurface(pressPos.below(), Direction.EAST).add(0, 0.15, 0), Pointing.RIGHT).withItem(tool), 30);
scene.idle(7);
scene.world.modifyTileNBT(pressS, DeployerTileEntity.class, nbt -> nbt.put("HeldItem", tool.serializeNBT()));
scene.idle(25);
Vec3 pressSide = util.vector.blockSurface(pressPos, Direction.WEST);
scene.overlay.showText(60).pointAt(pressSide).placeNearTarget().attachKeyFrame().text("With a fitting held item, Deployers can process items provided beneath them");
scene.idle(80);
scene.overlay.showText(60).pointAt(pressSide.subtract(0, 2, 0)).placeNearTarget().text("The Input items can be dropped or placed on a Depot under the Deployer");
scene.idle(50);
ItemStack quartz = AllItems.ROSE_QUARTZ.asStack();
scene.world.createItemOnBeltLike(depotPos, Direction.NORTH, quartz);
Vec3 depotCenter = util.vector.centerOf(depotPos.south());
scene.overlay.showControls(new InputWindowElement(depotCenter, Pointing.UP).withItem(quartz), 30);
scene.idle(10);
Vec3 targetV = util.vector.centerOf(pressPos).subtract(0, 1.65, 0);
scene.world.moveDeployer(pressPos, 1, 30);
scene.idle(30);
scene.world.moveDeployer(pressPos, -1, 30);
scene.debug.enqueueCallback(s -> SandPaperItem.spawnParticles(targetV, quartz, s.getWorld()));
// particle
scene.world.removeItemsFromBelt(depotPos);
ItemStack polished = AllItems.POLISHED_ROSE_QUARTZ.asStack();
scene.world.createItemOnBeltLike(depotPos, Direction.UP, polished);
scene.idle(10);
scene.overlay.showControls(new InputWindowElement(depotCenter, Pointing.UP).withItem(polished), 50);
scene.idle(60);
scene.world.hideIndependentSection(depot, Direction.NORTH);
scene.idle(5);
scene.world.showSection(util.select.fromTo(0, 1, 3, 0, 2, 3), Direction.DOWN);
scene.idle(10);
scene.world.showSection(util.select.fromTo(4, 1, 2, 0, 2, 2), Direction.SOUTH);
scene.idle(20);
BlockPos beltPos = util.grid.at(0, 1, 2);
scene.overlay.showText(40).pointAt(util.vector.blockSurface(beltPos, Direction.WEST)).placeNearTarget().attachKeyFrame().text("When items are provided on a belt...");
scene.idle(30);
ElementLink<BeltItemElement> ingot = scene.world.createItemOnBelt(beltPos, Direction.SOUTH, quartz);
scene.idle(15);
ElementLink<BeltItemElement> ingot2 = scene.world.createItemOnBelt(beltPos, Direction.SOUTH, quartz);
scene.idle(15);
scene.world.stallBeltItem(ingot, true);
scene.world.moveDeployer(pressPos, 1, 30);
scene.overlay.showText(50).pointAt(pressSide).placeNearTarget().attachKeyFrame().text("The Deployer will hold and process them automatically");
scene.idle(30);
scene.world.moveDeployer(pressPos, -1, 30);
scene.debug.enqueueCallback(s -> SandPaperItem.spawnParticles(targetV, quartz, s.getWorld()));
scene.world.removeItemsFromBelt(pressPos.below(2));
ingot = scene.world.createItemOnBelt(pressPos.below(2), Direction.UP, polished);
scene.world.stallBeltItem(ingot, true);
scene.idle(15);
scene.world.stallBeltItem(ingot, false);
scene.idle(15);
scene.world.stallBeltItem(ingot2, true);
scene.world.moveDeployer(pressPos, 1, 30);
scene.idle(30);
scene.world.moveDeployer(pressPos, -1, 30);
scene.debug.enqueueCallback(s -> SandPaperItem.spawnParticles(targetV, quartz, s.getWorld()));
scene.world.removeItemsFromBelt(pressPos.below(2));
ingot2 = scene.world.createItemOnBelt(pressPos.below(2), Direction.UP, polished);
scene.world.stallBeltItem(ingot2, true);
scene.idle(15);
scene.world.stallBeltItem(ingot2, false);
}
use of com.simibubi.create.foundation.ponder.element.BeltItemElement in project Create by Creators-of-Create.
the class SpoutScenes method filling.
public static void filling(SceneBuilder scene, SceneBuildingUtil util) {
scene.title("spout_filling", "Filling Items using a Spout");
scene.configureBasePlate(0, 0, 5);
scene.showBasePlate();
scene.idle(5);
ElementLink<WorldSectionElement> depot = scene.world.showIndependentSection(util.select.position(2, 1, 1), Direction.DOWN);
scene.world.moveSection(depot, util.vector.of(0, 0, 1), 0);
scene.idle(10);
Selection largeCog = util.select.position(3, 0, 5);
Selection kinetics = util.select.fromTo(2, 1, 5, 2, 2, 3);
Selection tank = util.select.fromTo(1, 1, 4, 1, 2, 4);
Selection pipes = util.select.fromTo(1, 3, 4, 2, 3, 3);
Selection spoutS = util.select.position(2, 3, 2);
BlockPos spoutPos = util.grid.at(2, 3, 2);
BlockPos depotPos = util.grid.at(2, 1, 1);
scene.world.showSection(spoutS, Direction.DOWN);
scene.idle(10);
Vec3 spoutSide = util.vector.blockSurface(spoutPos, Direction.WEST);
scene.overlay.showText(60).pointAt(spoutSide).placeNearTarget().attachKeyFrame().text("The Spout can fill fluid holding items provided beneath it");
scene.idle(50);
scene.world.showSection(tank, Direction.DOWN);
scene.idle(5);
scene.world.showSection(largeCog, Direction.UP);
scene.world.showSection(kinetics, Direction.NORTH);
scene.world.showSection(pipes, Direction.NORTH);
scene.idle(20);
FluidStack honey = new FluidStack(FluidHelper.convertToStill(AllFluids.HONEY.get()), 1000);
ItemStack bucket = AllFluids.HONEY.get().getAttributes().getBucket(honey);
scene.overlay.showControls(new InputWindowElement(util.vector.blockSurface(util.grid.at(2, 3, 2), Direction.NORTH), Pointing.RIGHT).showing(AllIcons.I_MTD_CLOSE).withItem(bucket), 40);
scene.idle(7);
scene.overlay.showSelectionWithText(util.select.position(2, 3, 2), 50).pointAt(util.vector.blockSurface(util.grid.at(2, 3, 2), Direction.WEST)).attachKeyFrame().colored(PonderPalette.RED).placeNearTarget().text("The content of a Spout cannot be accessed manually");
scene.idle(60);
scene.overlay.showText(70).pointAt(util.vector.blockSurface(util.grid.at(2, 3, 3), Direction.WEST)).colored(PonderPalette.GREEN).placeNearTarget().text("Instead, Pipes can be used to supply it with fluids");
scene.idle(90);
scene.overlay.showText(60).pointAt(spoutSide.subtract(0, 2, 0)).attachKeyFrame().placeNearTarget().text("The Input items can be placed on a Depot under the Spout");
scene.idle(50);
ItemStack bottle = new ItemStack(Items.GLASS_BOTTLE);
scene.world.createItemOnBeltLike(depotPos, Direction.NORTH, bottle);
Vec3 depotCenter = util.vector.centerOf(depotPos.south());
scene.overlay.showControls(new InputWindowElement(depotCenter, Pointing.UP).withItem(bottle), 30);
scene.idle(10);
scene.idle(20);
scene.world.modifyTileNBT(spoutS, SpoutTileEntity.class, nbt -> nbt.putInt("ProcessingTicks", 20));
scene.idle(20);
scene.world.removeItemsFromBelt(depotPos);
ItemStack potion = new ItemStack(Items.HONEY_BOTTLE);
scene.world.createItemOnBeltLike(depotPos, Direction.UP, potion);
ParticleOptions fluidParticle = FluidFX.getFluidParticle(new FluidStack(AllFluids.HONEY.get(), 1000));
for (int i = 0; i < 10; i++) {
scene.effects.emitParticles(util.vector.topOf(depotPos.south()).add(0, 1 / 16f, 0), Emitter.simple(fluidParticle, VecHelper.offsetRandomly(Vec3.ZERO, Create.RANDOM, .1f)), 1, 1);
}
scene.idle(10);
scene.overlay.showControls(new InputWindowElement(depotCenter, Pointing.UP).withItem(potion), 50);
scene.idle(60);
scene.world.hideIndependentSection(depot, Direction.NORTH);
scene.idle(5);
scene.world.showSection(util.select.fromTo(0, 1, 3, 0, 2, 3), Direction.DOWN);
scene.idle(10);
scene.world.showSection(util.select.fromTo(4, 1, 2, 0, 2, 2), Direction.SOUTH);
scene.idle(20);
BlockPos beltPos = util.grid.at(0, 1, 2);
scene.overlay.showText(40).pointAt(util.vector.blockSurface(beltPos, Direction.WEST)).placeNearTarget().attachKeyFrame().text("When items are provided on a belt...");
scene.idle(30);
ElementLink<BeltItemElement> ingot = scene.world.createItemOnBelt(beltPos, Direction.SOUTH, bottle);
scene.idle(15);
ElementLink<BeltItemElement> ingot2 = scene.world.createItemOnBelt(beltPos, Direction.SOUTH, bottle);
scene.idle(15);
scene.world.stallBeltItem(ingot, true);
scene.world.modifyTileNBT(spoutS, SpoutTileEntity.class, nbt -> nbt.putInt("ProcessingTicks", 20));
scene.overlay.showText(50).pointAt(spoutSide).placeNearTarget().attachKeyFrame().text("The Spout will hold and process them automatically");
scene.idle(20);
for (int i = 0; i < 10; i++) {
scene.effects.emitParticles(util.vector.topOf(depotPos.south()).add(0, 1 / 16f, 0), Emitter.simple(fluidParticle, VecHelper.offsetRandomly(Vec3.ZERO, Create.RANDOM, .1f)), 1, 1);
}
scene.world.removeItemsFromBelt(spoutPos.below(2));
ingot = scene.world.createItemOnBelt(spoutPos.below(2), Direction.UP, potion);
scene.world.stallBeltItem(ingot, true);
scene.idle(5);
scene.world.stallBeltItem(ingot, false);
scene.idle(15);
scene.world.stallBeltItem(ingot2, true);
scene.world.modifyTileNBT(spoutS, SpoutTileEntity.class, nbt -> nbt.putInt("ProcessingTicks", 20));
scene.idle(20);
for (int i = 0; i < 10; i++) {
scene.effects.emitParticles(util.vector.topOf(depotPos.south()).add(0, 1 / 16f, 0), Emitter.simple(fluidParticle, VecHelper.offsetRandomly(Vec3.ZERO, Create.RANDOM, .1f)), 1, 1);
}
scene.world.removeItemsFromBelt(spoutPos.below(2));
ingot2 = scene.world.createItemOnBelt(spoutPos.below(2), Direction.UP, potion);
scene.world.stallBeltItem(ingot2, true);
scene.idle(5);
scene.world.stallBeltItem(ingot2, false);
}
Aggregations