use of com.simibubi.create.foundation.ponder.element.InputWindowElement in project Create by Creators-of-Create.
the class FluidTankScenes method sizes.
public static void sizes(SceneBuilder scene, SceneBuildingUtil util) {
scene.title("fluid_tank_sizes", "Dimensions of a Fluid tank");
scene.configureBasePlate(0, 0, 6);
scene.scaleSceneView(0.9f);
scene.showBasePlate();
scene.idle(5);
Selection single = util.select.position(0, 3, 0);
Selection single2 = util.select.fromTo(1, 2, 1, 0, 2, 0);
Selection single3 = util.select.fromTo(2, 1, 0, 0, 1, 2);
ElementLink<WorldSectionElement> s1 = scene.world.showIndependentSection(single, Direction.DOWN);
scene.world.moveSection(s1, util.vector.of(2, -2, 2), 0);
scene.idle(10);
scene.overlay.showText(60).text("Fluid Tanks can be combined to increase the total capacity").attachKeyFrame().placeNearTarget().pointAt(util.vector.topOf(2, 1, 2));
scene.idle(40);
ElementLink<WorldSectionElement> s2 = scene.world.showIndependentSection(single, Direction.DOWN);
scene.world.moveSection(s2, util.vector.of(2, -2, 3), 0);
scene.idle(5);
ElementLink<WorldSectionElement> s3 = scene.world.showIndependentSection(single, Direction.DOWN);
scene.world.moveSection(s3, util.vector.of(3, -2, 3), 0);
scene.idle(5);
ElementLink<WorldSectionElement> s4 = scene.world.showIndependentSection(single, Direction.DOWN);
scene.world.moveSection(s4, util.vector.of(3, -2, 2), 0);
scene.idle(10);
scene.world.moveSection(s1, util.vector.of(0, -100, 0), 0);
scene.world.moveSection(s2, util.vector.of(0, -100, 0), 0);
scene.world.moveSection(s3, util.vector.of(0, -100, 0), 0);
scene.world.moveSection(s4, util.vector.of(0, -100, 0), 0);
ElementLink<WorldSectionElement> d = scene.world.showIndependentSectionImmediately(single2);
scene.world.moveSection(d, util.vector.of(2, -1, 2), 0);
scene.effects.indicateSuccess(util.grid.at(2, 1, 2));
scene.effects.indicateSuccess(util.grid.at(3, 1, 2));
scene.effects.indicateSuccess(util.grid.at(2, 1, 3));
scene.effects.indicateSuccess(util.grid.at(3, 1, 3));
scene.world.hideIndependentSection(s1, Direction.DOWN);
scene.world.hideIndependentSection(s2, Direction.DOWN);
scene.world.hideIndependentSection(s3, Direction.DOWN);
scene.world.hideIndependentSection(s4, Direction.DOWN);
scene.idle(25);
scene.overlay.showText(60).text("Their base square can be up to 3 blocks wide...").attachKeyFrame().placeNearTarget().pointAt(util.vector.topOf(2, 1, 2));
scene.idle(40);
s1 = scene.world.showIndependentSection(single, Direction.DOWN);
scene.world.moveSection(s1, util.vector.of(2, -2, 4), 0);
scene.idle(3);
s2 = scene.world.showIndependentSection(single, Direction.DOWN);
scene.world.moveSection(s2, util.vector.of(3, -2, 4), 0);
scene.idle(3);
s3 = scene.world.showIndependentSection(single, Direction.DOWN);
scene.world.moveSection(s3, util.vector.of(4, -2, 4), 0);
scene.idle(3);
s4 = scene.world.showIndependentSection(single, Direction.DOWN);
scene.world.moveSection(s4, util.vector.of(4, -2, 3), 0);
scene.idle(3);
ElementLink<WorldSectionElement> s5 = scene.world.showIndependentSection(single, Direction.DOWN);
scene.world.moveSection(s5, util.vector.of(4, -2, 2), 0);
scene.idle(10);
scene.world.moveSection(d, util.vector.of(0, -100, 0), 0);
scene.world.moveSection(s1, util.vector.of(0, -100, 0), 0);
scene.world.moveSection(s2, util.vector.of(0, -100, 0), 0);
scene.world.moveSection(s3, util.vector.of(0, -100, 0), 0);
scene.world.moveSection(s4, util.vector.of(0, -100, 0), 0);
scene.world.moveSection(s5, util.vector.of(0, -100, 0), 0);
ElementLink<WorldSectionElement> t = scene.world.showIndependentSectionImmediately(single3);
scene.world.moveSection(t, util.vector.of(2, 0, 2), 0);
for (int i = 2; i < 5; i++) for (int j = 2; j < 5; j++) scene.effects.indicateSuccess(util.grid.at(i, 1, j));
scene.world.hideIndependentSection(d, Direction.DOWN);
scene.world.hideIndependentSection(s1, Direction.DOWN);
scene.world.hideIndependentSection(s2, Direction.DOWN);
scene.world.hideIndependentSection(s3, Direction.DOWN);
scene.world.hideIndependentSection(s4, Direction.DOWN);
scene.world.hideIndependentSection(s5, Direction.DOWN);
scene.idle(25);
scene.world.hideIndependentSection(t, Direction.DOWN);
scene.idle(10);
Selection full1 = util.select.fromTo(5, 1, 0, 5, 6, 0);
Selection full2 = util.select.fromTo(4, 1, 1, 3, 6, 2);
Selection full3 = util.select.fromTo(0, 6, 5, 2, 1, 3);
scene.world.showSection(full1, Direction.DOWN);
scene.idle(5);
scene.world.showSection(full2, Direction.DOWN);
scene.idle(5);
scene.world.showSection(full3, Direction.DOWN);
scene.idle(10);
Vec3 blockSurface = util.vector.blockSurface(util.grid.at(3, 3, 1), Direction.WEST);
scene.overlay.showText(60).text("...and grow in height by more than 30 additional layers").attachKeyFrame().placeNearTarget().pointAt(blockSurface);
scene.idle(70);
scene.overlay.showControls(new InputWindowElement(util.vector.blockSurface(util.grid.at(3, 3, 1), Direction.NORTH), Pointing.RIGHT).rightClick().withWrench(), 60);
scene.idle(7);
scene.world.modifyBlocks(full2, s -> s.setValue(FluidTankBlock.SHAPE, FluidTankBlock.Shape.PLAIN), false);
scene.idle(30);
scene.overlay.showText(60).text("Using a Wrench, a tanks' window can be toggled").attachKeyFrame().placeNearTarget().pointAt(blockSurface);
scene.idle(50);
}
use of com.simibubi.create.foundation.ponder.element.InputWindowElement in project Create by Creators-of-Create.
the class PipeScenes method smart.
public static void smart(SceneBuilder scene, SceneBuildingUtil util) {
scene.title("smart_pipe", "Controlling Fluid flow using Smart Pipes");
scene.configureBasePlate(1, 0, 5);
scene.showBasePlate();
scene.idle(5);
Selection tank1 = util.select.fromTo(4, 1, 3, 4, 2, 3);
Selection tank2 = util.select.fromTo(4, 1, 4, 4, 2, 4);
Selection additionalPipes = util.select.fromTo(3, 1, 4, 1, 1, 4);
Selection mainPipes = util.select.fromTo(3, 1, 3, 1, 1, 1);
Selection kinetics1 = util.select.fromTo(0, 0, 2, 0, 0, 5);
Selection kinetics2 = util.select.position(1, 0, 5);
BlockPos basinPos = util.grid.at(4, 1, 1);
BlockPos pumpPos = util.grid.at(1, 1, 2);
Selection pump = util.select.position(1, 1, 2);
Selection basin = util.select.position(basinPos);
BlockPos smartPos = util.grid.at(3, 1, 1);
scene.world.modifyTileEntity(basinPos, BasinTileEntity.class, te -> te.getCapability(CapabilityFluidHandler.FLUID_HANDLER_CAPABILITY).ifPresent(ifh -> ifh.fill(new FluidStack(ForgeMod.MILK.get(), 1000), FluidAction.EXECUTE)));
scene.world.setBlock(util.grid.at(3, 1, 3), AllBlocks.FLUID_PIPE.get().getAxisState(Axis.X), false);
scene.world.setBlock(smartPos, AllBlocks.FLUID_PIPE.get().getAxisState(Axis.X), false);
scene.world.setBlock(util.grid.at(2, 1, 3), AllBlocks.GLASS_FLUID_PIPE.getDefaultState().setValue(GlassFluidPipeBlock.AXIS, Axis.X), false);
scene.world.setBlock(util.grid.at(1, 1, 3), AllBlocks.FLUID_PIPE.get().getAxisState(Axis.X).setValue(FluidPipeBlock.NORTH, true).setValue(FluidPipeBlock.WEST, false), false);
scene.world.showSection(basin, Direction.DOWN);
scene.idle(5);
scene.world.showSection(tank1, Direction.DOWN);
scene.idle(5);
scene.world.showSection(mainPipes, Direction.EAST);
scene.idle(15);
scene.world.destroyBlock(smartPos);
scene.world.restoreBlocks(util.select.position(smartPos));
Vec3 filterVec = util.vector.topOf(smartPos).subtract(0.25, 0, 0);
scene.overlay.showText(50).placeNearTarget().text("Smart pipes can help control flows by fluid type").attachKeyFrame().pointAt(filterVec);
scene.idle(60);
scene.overlay.showSelectionWithText(util.select.position(basinPos), 80).placeNearTarget().colored(PonderPalette.GREEN).text("When placed directly at the source, they can specify the type of fluid to extract").attachKeyFrame().pointAt(filterVec);
scene.idle(90);
FluidStack chocolate = new FluidStack(FluidHelper.convertToStill(AllFluids.CHOCOLATE.get()), 1000);
ItemStack bucket = AllFluids.CHOCOLATE.get().getAttributes().getBucket(chocolate);
ItemStack milkBucket = new ItemStack(Items.MILK_BUCKET);
scene.overlay.showControls(new InputWindowElement(filterVec, Pointing.DOWN).rightClick().withItem(bucket), 80);
scene.idle(7);
scene.world.setFilterData(util.select.position(3, 1, 1), SmartFluidPipeTileEntity.class, bucket);
scene.idle(10);
scene.overlay.showText(60).placeNearTarget().attachKeyFrame().text("Simply Right-Click their filter slot with any item containing the desired fluid").pointAt(filterVec);
scene.idle(50);
scene.world.showSection(kinetics2, Direction.WEST);
scene.world.setKineticSpeed(kinetics2, 64);
scene.idle(5);
scene.world.showSection(kinetics1, Direction.EAST);
scene.world.setKineticSpeed(kinetics1, -64);
scene.idle(10);
scene.world.setKineticSpeed(pump, 128);
scene.world.propagatePipeChange(pumpPos);
scene.idle(120);
scene.world.setKineticSpeed(util.select.everywhere(), 0);
scene.world.propagatePipeChange(pumpPos);
scene.effects.rotationSpeedIndicator(pumpPos);
scene.idle(15);
scene.world.showSection(tank2, Direction.DOWN);
scene.world.showSection(additionalPipes, Direction.NORTH);
scene.world.setBlock(util.grid.at(3, 1, 1), AllBlocks.FLUID_PIPE.get().getAxisState(Axis.X), true);
scene.idle(10);
for (int i = 0; i < 3; i++) {
BlockPos pos = util.grid.at(1 + i, 1, 3);
scene.world.destroyBlock(pos);
scene.world.restoreBlocks(util.select.position(pos));
scene.idle(2);
}
scene.idle(15);
scene.world.modifyTileEntity(basinPos, BasinTileEntity.class, te -> te.getCapability(CapabilityFluidHandler.FLUID_HANDLER_CAPABILITY).ifPresent(ifh -> ifh.fill(chocolate, FluidAction.EXECUTE)));
scene.idle(10);
scene.overlay.showText(80).placeNearTarget().colored(PonderPalette.GREEN).text("When placed further down a pipe network, smart pipes will only let matching fluids continue").attachKeyFrame().pointAt(filterVec.add(-1, 0, 2));
scene.idle(90);
scene.overlay.showControls(new InputWindowElement(filterVec.add(-1, 0, 3), Pointing.DOWN).rightClick().withItem(milkBucket), 30);
scene.idle(7);
scene.world.setFilterData(util.select.position(2, 1, 4), SmartFluidPipeTileEntity.class, milkBucket);
scene.idle(30);
scene.overlay.showControls(new InputWindowElement(filterVec.add(-1, 0, 2), Pointing.DOWN).rightClick().withItem(bucket), 30);
scene.idle(7);
scene.world.setFilterData(util.select.position(2, 1, 3), SmartFluidPipeTileEntity.class, bucket);
scene.idle(30);
scene.world.setKineticSpeed(kinetics2, 64);
scene.world.setKineticSpeed(kinetics1, -64);
scene.world.setKineticSpeed(pump, 128);
scene.world.propagatePipeChange(pumpPos);
scene.effects.rotationSpeedIndicator(pumpPos);
scene.idle(40);
}
use of com.simibubi.create.foundation.ponder.element.InputWindowElement in project Create by Creators-of-Create.
the class PipeScenes method encasing.
public static void encasing(SceneBuilder scene, SceneBuildingUtil util) {
scene.title("encased_fluid_pipe", "Encasing Fluid Pipes");
scene.configureBasePlate(0, 0, 5);
scene.showBasePlate();
scene.idle(5);
scene.world.showSection(util.select.position(2, 0, 5), Direction.UP);
scene.idle(5);
scene.world.showSection(util.select.layer(1), Direction.DOWN);
scene.idle(15);
BlockState copperEncased = AllBlocks.ENCASED_FLUID_PIPE.getDefaultState().setValue(FluidPipeBlock.SOUTH, true).setValue(FluidPipeBlock.WEST, true);
ItemStack casingItem = AllBlocks.COPPER_CASING.asStack();
scene.overlay.showControls(new InputWindowElement(util.vector.topOf(3, 1, 1), Pointing.DOWN).rightClick().withItem(casingItem), 60);
scene.idle(7);
scene.world.setBlock(util.grid.at(3, 1, 1), copperEncased, true);
scene.idle(10);
scene.overlay.showText(60).placeNearTarget().text("Copper Casing can be used to decorate Fluid Pipes").attachKeyFrame().pointAt(util.vector.topOf(3, 1, 1));
scene.idle(70);
scene.world.destroyBlock(util.grid.at(2, 1, 1));
scene.world.modifyBlock(util.grid.at(1, 1, 1), s -> s.setValue(FluidPipeBlock.EAST, false).setValue(FluidPipeBlock.NORTH, true), false);
scene.idle(5);
scene.overlay.showLine(PonderPalette.RED, util.vector.of(1.5, 1.75, 1), util.vector.of(1.5, 1.75, 2), 80);
scene.idle(5);
scene.addKeyframe();
scene.overlay.showLine(PonderPalette.GREEN, util.vector.of(3.5, 2, 1.5), util.vector.of(3.5, 2, 2), 80);
scene.overlay.showLine(PonderPalette.GREEN, util.vector.of(3, 2, 1.5), util.vector.of(3.5, 2, 1.5), 80);
scene.idle(25);
scene.overlay.showText(60).placeNearTarget().text("Aside from being conceiled, Encased Pipes are locked into their connectivity state").pointAt(util.vector.blockSurface(util.grid.at(3, 1, 1), Direction.WEST));
scene.idle(70);
BlockState defaultState = AllBlocks.FLUID_PIPE.getDefaultState();
for (BooleanProperty booleanProperty : FluidPipeBlock.PROPERTY_BY_DIRECTION.values()) defaultState = defaultState.setValue(booleanProperty, false);
scene.world.setBlock(util.grid.at(3, 2, 1), defaultState.setValue(FluidPipeBlock.EAST, true).setValue(FluidPipeBlock.WEST, true), false);
scene.world.setBlock(util.grid.at(1, 2, 1), defaultState.setValue(FluidPipeBlock.UP, true).setValue(FluidPipeBlock.DOWN, true), false);
scene.world.showSection(util.select.layer(2), Direction.DOWN);
scene.idle(10);
scene.world.modifyBlock(util.grid.at(1, 1, 1), s -> s.setValue(FluidPipeBlock.UP, true).setValue(FluidPipeBlock.NORTH, false), false);
scene.idle(20);
scene.overlay.showText(60).placeNearTarget().colored(PonderPalette.RED).text("It will no longer react to any neighbouring blocks being added or removed").attachKeyFrame().pointAt(util.vector.centerOf(3, 2, 1));
scene.idle(20);
}
use of com.simibubi.create.foundation.ponder.element.InputWindowElement in project Create by Creators-of-Create.
the class PumpScenes method flow.
public static void flow(SceneBuilder scene, SceneBuildingUtil util) {
scene.title("mechanical_pump_flow", "Fluid Transportation using Mechanical Pumps");
scene.configureBasePlate(0, 0, 5);
scene.showBasePlate();
scene.world.multiplyKineticSpeed(util.select.everywhere(), -1);
scene.idle(5);
BlockPos pumpPos = util.grid.at(2, 1, 1);
Selection tank1 = util.select.fromTo(0, 2, 3, 0, 1, 3);
Selection tank2 = util.select.fromTo(4, 2, 3, 4, 1, 3);
Selection pipes = util.select.fromTo(3, 1, 3, 1, 1, 1);
Selection largeCog = util.select.position(5, 0, 1);
Selection kinetics = util.select.fromTo(5, 1, 0, 2, 1, 0);
BlockPos leverPos = util.grid.at(4, 2, 0);
Selection pump = util.select.position(pumpPos);
scene.world.setBlock(pumpPos, AllBlocks.FLUID_PIPE.get().getAxisState(Axis.X), false);
scene.world.showSection(tank1, Direction.DOWN);
scene.idle(5);
scene.world.showSection(tank2, Direction.DOWN);
scene.idle(5);
scene.world.showSection(pipes, Direction.NORTH);
scene.idle(15);
scene.world.destroyBlock(pumpPos);
scene.world.restoreBlocks(pump);
scene.world.setKineticSpeed(pump, 0);
scene.idle(15);
scene.overlay.showText(60).text("Mechanical Pumps govern the flow of their attached pipe networks").attachKeyFrame().placeNearTarget().pointAt(util.vector.topOf(pumpPos));
scene.idle(70);
scene.world.showSection(largeCog, Direction.UP);
scene.idle(5);
scene.world.showSection(kinetics, Direction.SOUTH);
scene.world.showSection(util.select.position(leverPos), Direction.SOUTH);
scene.idle(10);
scene.world.setKineticSpeed(pump, 64);
scene.world.propagatePipeChange(pumpPos);
scene.effects.rotationDirectionIndicator(pumpPos.north());
scene.idle(15);
scene.overlay.showText(60).text("When powered, their arrow indicates the direction of flow").attachKeyFrame().placeNearTarget().pointAt(util.vector.topOf(pumpPos).subtract(0.5f, 0.125f, 0));
AABB bb1 = new AABB(Vec3.ZERO, Vec3.ZERO).inflate(.25, .25, 0).move(0, 0, .25);
AABB bb2 = new AABB(Vec3.ZERO, Vec3.ZERO).inflate(.25, .25, 1.25);
scene.idle(65);
Object in = new Object();
Object out = new Object();
scene.overlay.chaseBoundingBoxOutline(PonderPalette.INPUT, in, bb1.move(util.vector.centerOf(3, 1, 3)), 3);
scene.idle(2);
scene.overlay.chaseBoundingBoxOutline(PonderPalette.INPUT, in, bb2.move(util.vector.centerOf(3, 1, 2)), 50);
scene.idle(10);
scene.overlay.showText(50).text("The network behind is now pulling fluids...").attachKeyFrame().placeNearTarget().colored(PonderPalette.INPUT).pointAt(util.vector.centerOf(3, 1, 2));
scene.idle(60);
scene.overlay.chaseBoundingBoxOutline(PonderPalette.OUTPUT, out, bb1.move(util.vector.centerOf(1, 1, 1).add(0, 0, -.5)), 3);
scene.idle(2);
scene.overlay.chaseBoundingBoxOutline(PonderPalette.OUTPUT, out, bb2.move(util.vector.centerOf(1, 1, 2)), 50);
scene.idle(10);
scene.overlay.showText(50).text("...while the network in front is transferring it outward").placeNearTarget().colored(PonderPalette.OUTPUT).pointAt(util.vector.centerOf(1, 1, 2));
scene.idle(70);
scene.world.toggleRedstonePower(util.select.fromTo(4, 2, 0, 4, 1, 0));
scene.effects.indicateRedstone(leverPos);
scene.world.multiplyKineticSpeed(util.select.fromTo(3, 1, 0, 2, 1, 1), -1);
scene.effects.rotationDirectionIndicator(pumpPos.north());
scene.world.propagatePipeChange(pumpPos);
scene.idle(15);
scene.overlay.showText(70).text("Reversing the input rotation reverses the direction of flow").placeNearTarget().attachKeyFrame().pointAt(util.vector.topOf(pumpPos).subtract(0.5f, 0.125f, 0));
scene.idle(25);
scene.overlay.chaseBoundingBoxOutline(PonderPalette.INPUT, in, bb1.move(util.vector.centerOf(1, 1, 3)), 3);
scene.idle(2);
scene.overlay.chaseBoundingBoxOutline(PonderPalette.INPUT, in, bb2.move(util.vector.centerOf(1, 1, 2)), 30);
scene.idle(15);
scene.overlay.chaseBoundingBoxOutline(PonderPalette.OUTPUT, out, bb1.move(util.vector.centerOf(3, 1, 1).add(0, 0, -.5)), 3);
scene.idle(2);
scene.overlay.chaseBoundingBoxOutline(PonderPalette.OUTPUT, out, bb2.move(util.vector.centerOf(3, 1, 2)), 30);
scene.idle(55);
scene.overlay.showControls(new InputWindowElement(util.vector.topOf(pumpPos), Pointing.DOWN).rightClick().withWrench(), 40);
scene.idle(7);
scene.world.modifyBlock(pumpPos, s -> s.setValue(PumpBlock.FACING, Direction.EAST), true);
scene.overlay.showText(70).attachKeyFrame().pointAt(util.vector.centerOf(2, 1, 1)).placeNearTarget().text("Use a Wrench to reverse the orientation of pumps manually");
scene.world.propagatePipeChange(pumpPos);
scene.idle(40);
scene.overlay.chaseBoundingBoxOutline(PonderPalette.INPUT, in, bb1.move(util.vector.centerOf(3, 1, 3)), 3);
scene.idle(2);
scene.overlay.chaseBoundingBoxOutline(PonderPalette.INPUT, in, bb2.move(util.vector.centerOf(3, 1, 2)), 30);
scene.idle(15);
scene.overlay.chaseBoundingBoxOutline(PonderPalette.OUTPUT, out, bb1.move(util.vector.centerOf(1, 1, 1).add(0, 0, -.5)), 3);
scene.idle(2);
scene.overlay.chaseBoundingBoxOutline(PonderPalette.OUTPUT, out, bb2.move(util.vector.centerOf(1, 1, 2)), 30);
scene.idle(25);
}
use of com.simibubi.create.foundation.ponder.element.InputWindowElement in project createaddition by mrh0.
the class PonderScenes method rollingMill.
public static void rollingMill(SceneBuilder scene, SceneBuildingUtil util) {
scene.title("rolling_mill", "Rolling metals into Rods and Wires");
scene.configureBasePlate(1, 0, 4);
scene.world.showSection(util.select.layer(0), Direction.UP);
BlockPos mill = util.grid.at(3, 1, 2);
for (int i = 0; i < 6; i++) {
scene.idle(5);
scene.world.showSection(util.select.position(i, 1, 2), Direction.DOWN);
}
scene.idle(10);
scene.overlay.showText(50).text("The Rolling Mill uses rotational force to roll metals into Rods and Wires").placeNearTarget().pointAt(util.vector.topOf(mill));
scene.idle(60);
scene.overlay.showText(50).text("To manualy input items, drop Ingots or Plates on the top of the Mill").placeNearTarget().pointAt(util.vector.topOf(mill));
scene.idle(60);
scene.overlay.showControls(new InputWindowElement(util.vector.topOf(mill), Pointing.DOWN).rightClick(), 50);
scene.overlay.showText(50).text("Manualy retrieve the rolled output by R-clicking the Mill").placeNearTarget().pointAt(util.vector.topOf(mill));
scene.idle(60);
}
Aggregations