use of com.simibubi.create.foundation.ponder.element.InputWindowElement in project Create by Creators-of-Create.
the class ProcessingScenes method compacting.
public static void compacting(SceneBuilder scene, SceneBuildingUtil util) {
scene.title("mechanical_press_compacting", "Compacting items with the Mechanical Press");
scene.configureBasePlate(0, 0, 5);
scene.world.setBlock(util.grid.at(1, 1, 2), AllBlocks.ANDESITE_CASING.getDefaultState(), false);
scene.world.showSection(util.select.layer(0), Direction.UP);
scene.idle(5);
scene.world.showSection(util.select.fromTo(1, 4, 3, 1, 1, 5), Direction.DOWN);
scene.idle(5);
scene.world.showSection(util.select.position(1, 1, 2), Direction.DOWN);
scene.idle(5);
scene.world.showSection(util.select.position(1, 2, 2), Direction.DOWN);
scene.idle(5);
scene.world.showSection(util.select.position(1, 4, 2), Direction.SOUTH);
scene.idle(5);
scene.world.showSection(util.select.fromTo(3, 1, 1, 1, 1, 1), Direction.SOUTH);
scene.world.showSection(util.select.fromTo(3, 1, 5, 3, 1, 2), Direction.SOUTH);
scene.idle(20);
BlockPos basin = util.grid.at(1, 2, 2);
BlockPos pressPos = util.grid.at(1, 4, 2);
Vec3 basinSide = util.vector.blockSurface(basin, Direction.WEST);
ItemStack copper = new ItemStack(Items.COPPER_INGOT);
ItemStack copperBlock = new ItemStack(Items.COPPER_BLOCK);
scene.overlay.showText(60).pointAt(basinSide).placeNearTarget().attachKeyFrame().text("Pressing items held in a Basin will cause them to be Compacted");
scene.idle(40);
scene.overlay.showControls(new InputWindowElement(util.vector.topOf(basin), Pointing.DOWN).withItem(copper), 30);
scene.idle(30);
Class<MechanicalPressTileEntity> type = MechanicalPressTileEntity.class;
scene.world.modifyTileEntity(pressPos, type, pte -> pte.start(Mode.BASIN));
scene.idle(30);
scene.world.modifyTileEntity(pressPos, type, pte -> pte.makeCompactingParticleEffect(util.vector.centerOf(basin), copper));
scene.world.modifyTileNBT(util.select.position(basin), BasinTileEntity.class, nbt -> {
nbt.put("VisualizedItems", NBTHelper.writeCompoundList(ImmutableList.of(IntAttached.with(1, copperBlock)), ia -> ia.getValue().serializeNBT()));
});
scene.idle(4);
scene.world.createItemOnBelt(util.grid.at(1, 1, 1), Direction.UP, copperBlock);
scene.idle(30);
scene.overlay.showText(80).pointAt(basinSide).placeNearTarget().attachKeyFrame().text("Compacting includes any filled 2x2 or 3x3 Crafting Recipe, plus a couple extra ones");
scene.idle(30);
ItemStack log = new ItemStack(Items.OAK_LOG);
ItemStack bark = new ItemStack(Items.OAK_WOOD);
scene.overlay.showControls(new InputWindowElement(util.vector.topOf(basin), Pointing.DOWN).withItem(log), 30);
scene.idle(30);
scene.world.modifyTileEntity(pressPos, type, pte -> pte.start(Mode.BASIN));
scene.idle(30);
scene.world.modifyTileEntity(pressPos, type, pte -> pte.makeCompactingParticleEffect(util.vector.centerOf(basin), log));
scene.world.modifyTileNBT(util.select.position(basin), BasinTileEntity.class, nbt -> {
nbt.put("VisualizedItems", NBTHelper.writeCompoundList(ImmutableList.of(IntAttached.with(1, bark)), ia -> ia.getValue().serializeNBT()));
});
scene.idle(4);
scene.world.createItemOnBelt(util.grid.at(1, 1, 1), Direction.UP, bark);
scene.idle(30);
scene.rotateCameraY(-30);
scene.idle(10);
scene.world.setBlock(util.grid.at(1, 1, 2), AllBlocks.BLAZE_BURNER.getDefaultState().setValue(BlazeBurnerBlock.HEAT_LEVEL, HeatLevel.KINDLED), true);
scene.idle(10);
scene.overlay.showText(80).pointAt(basinSide.subtract(0, 1, 0)).placeNearTarget().text("Some of those recipes may require the heat of a Blaze Burner");
scene.idle(40);
scene.rotateCameraY(30);
scene.idle(60);
Vec3 filterPos = util.vector.of(1, 2.75f, 2.5f);
scene.overlay.showFilterSlotInput(filterPos, 100);
scene.overlay.showText(120).pointAt(filterPos).placeNearTarget().attachKeyFrame().text("The filter slot can be used in case two recipes are conflicting.");
scene.idle(60);
}
use of com.simibubi.create.foundation.ponder.element.InputWindowElement in project Create by Creators-of-Create.
the class ProcessingScenes method blazeBurner.
public static void blazeBurner(SceneBuilder scene, SceneBuildingUtil util) {
scene.title("blaze_burner", "Feeding Blaze Burners");
scene.configureBasePlate(0, 0, 5);
scene.showBasePlate();
scene.idle(10);
BlockPos burner = util.grid.at(2, 1, 2);
scene.world.showSection(util.select.position(burner), Direction.DOWN);
scene.idle(10);
scene.world.showSection(util.select.position(burner.above()), Direction.DOWN);
scene.idle(10);
scene.overlay.showText(70).attachKeyFrame().text("Blaze Burners can provide Heat to Items processed in a Basin").pointAt(util.vector.blockSurface(burner, Direction.WEST)).placeNearTarget();
scene.idle(80);
scene.world.hideSection(util.select.position(burner.above()), Direction.UP);
scene.idle(20);
scene.world.setBlock(burner.above(), Blocks.AIR.defaultBlockState(), false);
scene.overlay.showControls(new InputWindowElement(util.vector.topOf(burner), Pointing.DOWN).rightClick().withItem(new ItemStack(Items.OAK_PLANKS)), 15);
scene.idle(7);
scene.world.modifyBlock(burner, s -> s.setValue(BlazeBurnerBlock.HEAT_LEVEL, HeatLevel.FADING), false);
scene.idle(15);
scene.overlay.showControls(new InputWindowElement(util.vector.topOf(burner), Pointing.DOWN).rightClick().withItem(new ItemStack(Items.OAK_PLANKS)), 15);
scene.idle(7);
scene.world.modifyBlock(burner, s -> s.setValue(BlazeBurnerBlock.HEAT_LEVEL, HeatLevel.KINDLED), false);
scene.idle(20);
scene.overlay.showText(70).attachKeyFrame().text("For this, the Blaze has to be fed with flammable items").pointAt(util.vector.blockSurface(burner, Direction.WEST)).placeNearTarget();
scene.idle(80);
scene.idle(20);
scene.overlay.showControls(new InputWindowElement(util.vector.topOf(burner), Pointing.DOWN).rightClick().withItem(AllItems.BLAZE_CAKE.asStack()), 30);
scene.idle(7);
scene.world.modifyBlock(burner, s -> s.setValue(BlazeBurnerBlock.HEAT_LEVEL, HeatLevel.SEETHING), false);
scene.idle(20);
scene.overlay.showText(80).attachKeyFrame().colored(PonderPalette.MEDIUM).text("With a Blaze Cake, the Burner can reach an even stronger level of heat").pointAt(util.vector.blockSurface(burner, Direction.WEST)).placeNearTarget();
scene.idle(90);
Class<DeployerTileEntity> teType = DeployerTileEntity.class;
scene.world.modifyTileNBT(util.select.position(4, 1, 2), teType, nbt -> nbt.put("HeldItem", AllItems.BLAZE_CAKE.asStack().serializeNBT()));
scene.world.showSection(util.select.fromTo(3, 0, 5, 2, 0, 5), Direction.UP);
scene.idle(5);
scene.world.showSection(util.select.fromTo(4, 1, 2, 4, 1, 5), Direction.DOWN);
scene.idle(5);
scene.world.showSection(util.select.fromTo(2, 1, 4, 2, 1, 5), Direction.DOWN);
scene.idle(10);
scene.overlay.showText(80).attachKeyFrame().text("The feeding process can be automated using Deployers or Mechanical Arms").pointAt(util.vector.blockSurface(burner.east(2), Direction.UP));
scene.idle(90);
}
use of com.simibubi.create.foundation.ponder.element.InputWindowElement in project Create by Creators-of-Create.
the class ProcessingScenes method mixing.
public static void mixing(SceneBuilder scene, SceneBuildingUtil util) {
scene.title("mechanical_mixer", "Processing Items with the Mechanical Mixer");
scene.configureBasePlate(0, 0, 5);
scene.world.setBlock(util.grid.at(1, 1, 2), AllBlocks.ANDESITE_CASING.getDefaultState(), false);
scene.world.showSection(util.select.layer(0), Direction.UP);
scene.idle(5);
scene.world.showSection(util.select.fromTo(1, 4, 3, 1, 1, 5), Direction.DOWN);
scene.idle(5);
scene.world.showSection(util.select.position(1, 1, 2), Direction.DOWN);
scene.idle(5);
scene.world.showSection(util.select.position(1, 2, 2), Direction.DOWN);
scene.idle(5);
scene.world.showSection(util.select.position(1, 4, 2), Direction.SOUTH);
scene.idle(5);
scene.world.showSection(util.select.fromTo(3, 1, 1, 1, 1, 1), Direction.SOUTH);
scene.world.showSection(util.select.fromTo(3, 1, 5, 3, 1, 2), Direction.SOUTH);
scene.idle(20);
BlockPos basin = util.grid.at(1, 2, 2);
BlockPos pressPos = util.grid.at(1, 4, 2);
Vec3 basinSide = util.vector.blockSurface(basin, Direction.WEST);
ItemStack blue = new ItemStack(Items.BLUE_DYE);
ItemStack red = new ItemStack(Items.RED_DYE);
ItemStack purple = new ItemStack(Items.PURPLE_DYE);
scene.overlay.showText(60).pointAt(basinSide).placeNearTarget().attachKeyFrame().text("With a Mixer and Basin, some Crafting Recipes can be automated");
scene.idle(40);
scene.overlay.showControls(new InputWindowElement(util.vector.topOf(basin), Pointing.LEFT).withItem(blue), 30);
scene.overlay.showControls(new InputWindowElement(util.vector.topOf(basin), Pointing.RIGHT).withItem(red), 30);
scene.idle(30);
Class<MechanicalMixerTileEntity> type = MechanicalMixerTileEntity.class;
scene.world.modifyTileEntity(pressPos, type, pte -> pte.startProcessingBasin());
scene.world.createItemOnBeltLike(basin, Direction.UP, red);
scene.world.createItemOnBeltLike(basin, Direction.UP, blue);
scene.idle(80);
scene.world.modifyTileNBT(util.select.position(basin), BasinTileEntity.class, nbt -> {
nbt.put("VisualizedItems", NBTHelper.writeCompoundList(ImmutableList.of(IntAttached.with(1, purple)), ia -> ia.getValue().serializeNBT()));
});
scene.idle(4);
scene.world.createItemOnBelt(util.grid.at(1, 1, 1), Direction.UP, purple);
scene.idle(30);
scene.overlay.showText(80).pointAt(basinSide).placeNearTarget().attachKeyFrame().text("Available recipes include any Shapeless Crafting Recipe, plus a couple extra ones");
scene.idle(80);
scene.rotateCameraY(-30);
scene.idle(10);
scene.world.setBlock(util.grid.at(1, 1, 2), AllBlocks.BLAZE_BURNER.getDefaultState().setValue(BlazeBurnerBlock.HEAT_LEVEL, HeatLevel.KINDLED), true);
scene.idle(10);
scene.overlay.showText(80).pointAt(basinSide.subtract(0, 1, 0)).placeNearTarget().text("Some of those recipes may require the heat of a Blaze Burner");
scene.idle(40);
scene.rotateCameraY(30);
scene.idle(60);
Vec3 filterPos = util.vector.of(1, 2.75f, 2.5f);
scene.overlay.showFilterSlotInput(filterPos, 100);
scene.overlay.showText(120).pointAt(filterPos).placeNearTarget().attachKeyFrame().text("The filter slot can be used in case two recipes are conflicting.");
scene.idle(60);
}
use of com.simibubi.create.foundation.ponder.element.InputWindowElement in project Create by Creators-of-Create.
the class ProcessingScenes method crushingWheels.
public static void crushingWheels(SceneBuilder scene, SceneBuildingUtil util) {
scene.title("crushing_wheels", "Processing Items with Crushing Wheels");
scene.configureBasePlate(0, 0, 5);
scene.scaleSceneView(.9f);
Selection wheels = util.select.fromTo(3, 2, 2, 1, 2, 2);
Selection kinetics = util.select.fromTo(0, 1, 5, 4, 1, 3);
Selection kinetics2 = util.select.fromTo(0, 2, 5, 4, 2, 3);
Selection beltCog = util.select.position(5, 0, 1);
scene.world.setKineticSpeed(wheels, 0);
scene.world.setBlock(util.grid.at(2, 3, 2), Blocks.AIR.defaultBlockState(), false);
scene.world.showSection(util.select.layer(0).substract(beltCog), Direction.UP);
scene.idle(5);
Selection belt = util.select.fromTo(4, 1, 2, 4, 4, 2).add(util.select.fromTo(4, 3, 3, 4, 4, 3)).add(util.select.position(3, 3, 2)).add(util.select.position(2, 3, 2));
Selection bottomBelt = util.select.fromTo(5, 1, 0, 2, 1, 0).add(util.select.fromTo(2, 1, 2, 2, 1, 1));
BlockPos center = util.grid.at(2, 2, 2);
Selection wWheel = util.select.position(center.west());
Selection eWheel = util.select.position(center.east());
scene.world.showSection(wWheel, Direction.SOUTH);
scene.idle(3);
scene.world.showSection(eWheel, Direction.SOUTH);
scene.idle(10);
Vec3 centerTop = util.vector.topOf(center);
scene.overlay.showText(60).attachKeyFrame().text("A pair of Crushing Wheels can grind items very effectively").pointAt(centerTop).placeNearTarget();
scene.idle(70);
scene.world.showSection(kinetics, Direction.DOWN);
scene.idle(3);
scene.world.showSection(kinetics2, Direction.DOWN);
scene.world.setKineticSpeed(wWheel, -16);
scene.world.setKineticSpeed(eWheel, 16);
scene.idle(5);
scene.effects.rotationDirectionIndicator(center.west());
scene.effects.rotationDirectionIndicator(center.east());
scene.idle(10);
scene.overlay.showText(60).attachKeyFrame().text("Their Rotational Input has to make them spin into each other").pointAt(util.vector.blockSurface(center.west(), Direction.NORTH)).placeNearTarget();
scene.idle(40);
scene.effects.rotationDirectionIndicator(center.west());
scene.effects.rotationDirectionIndicator(center.east());
scene.idle(30);
ItemStack input = new ItemStack(Items.GOLD_ORE);
ItemStack output = new ItemStack(Items.RAW_GOLD);
Vec3 entitySpawn = util.vector.topOf(center.above(2));
ElementLink<EntityElement> entity1 = scene.world.createItemEntity(entitySpawn, util.vector.of(0, 0.2, 0), input);
scene.idle(18);
scene.world.modifyEntity(entity1, Entity::discard);
Emitter blockSpace = Emitter.withinBlockSpace(new ItemParticleOption(ParticleTypes.ITEM, input), util.vector.of(0, 0, 0));
scene.effects.emitParticles(util.vector.centerOf(center).add(0, -0.2, 0), blockSpace, 3, 40);
scene.idle(10);
scene.overlay.showControls(new InputWindowElement(centerTop, Pointing.DOWN).withItem(input), 30);
scene.idle(7);
scene.overlay.showText(50).attachKeyFrame().text("Items thrown or inserted into the top will get processed").pointAt(centerTop).placeNearTarget();
scene.idle(60);
scene.world.createItemEntity(centerTop.add(0, -1.4, 0), util.vector.of(0, 0, 0), output);
scene.idle(10);
scene.world.createItemEntity(centerTop.add(0, -1.4, 0), util.vector.of(0, 0, 0), output);
scene.overlay.showControls(new InputWindowElement(centerTop.add(0, -2, 0), Pointing.UP).withItem(output), 30);
scene.idle(40);
scene.world.restoreBlocks(util.select.position(2, 3, 2));
scene.world.showSection(belt, Direction.DOWN);
scene.idle(5);
scene.world.showSection(beltCog, Direction.UP);
scene.idle(5);
scene.world.modifyEntities(ItemEntity.class, Entity::discard);
scene.world.showSection(bottomBelt, Direction.SOUTH);
scene.idle(5);
scene.overlay.showText(50).attachKeyFrame().text("Items can be inserted and picked up through automated means as well").pointAt(centerTop.add(0, .5, 0)).placeNearTarget();
scene.idle(40);
for (int i = 0; i < 5; i++) {
if (i < 4)
scene.world.createItemOnBelt(util.grid.at(4, 4, 2), Direction.EAST, input);
scene.idle(15);
if (i < 3)
scene.world.createItemOnBelt(util.grid.at(4, 4, 2), Direction.EAST, input);
scene.idle(15);
if (i > 0) {
scene.world.createItemOnBelt(center.below(), Direction.UP, output);
scene.idle(15);
scene.world.createItemOnBelt(center.below(), Direction.UP, output);
}
scene.world.removeItemsFromBelt(util.grid.at(3, 3, 2));
if (i < 4)
scene.effects.emitParticles(util.vector.centerOf(center).add(0, -0.2, 0), blockSpace, 3, 28);
if (i == 0)
scene.markAsFinished();
}
}
use of com.simibubi.create.foundation.ponder.element.InputWindowElement in project Create by Creators-of-Create.
the class PulleyScenes method movementModes.
public static void movementModes(SceneBuilder scene, SceneBuildingUtil util) {
scene.title("rope_pulley_modes", "Movement Modes of the Rope Pulley");
scene.configureBasePlate(0, 0, 5);
scene.scaleSceneView(0.95f);
scene.setSceneOffsetY(-1);
Selection reversable = util.select.fromTo(2, 3, 4, 2, 4, 2);
BlockPos leverPos = util.grid.at(1, 2, 4);
BlockPos pulleyPos = util.grid.at(2, 4, 2);
Selection redstoneStuff = util.select.fromTo(leverPos, leverPos.east());
BlockPos flowerPos = util.grid.at(2, 1, 2);
scene.world.showSection(util.select.layer(0), Direction.UP);
scene.world.showSection(util.select.position(flowerPos), Direction.UP);
scene.idle(5);
scene.world.showSection(util.select.fromTo(1, 4, 3, 2, 1, 4), Direction.DOWN);
scene.idle(10);
scene.world.showSection(util.select.position(pulleyPos), Direction.SOUTH);
ElementLink<WorldSectionElement> glass = scene.world.showIndependentSection(util.select.position(pulleyPos.below()), Direction.UP);
scene.idle(20);
scene.world.toggleRedstonePower(redstoneStuff);
scene.effects.indicateRedstone(leverPos);
scene.world.modifyKineticSpeed(reversable, f -> -f);
scene.effects.rotationDirectionIndicator(pulleyPos.south());
scene.world.movePulley(pulleyPos, 2, 40);
scene.world.moveSection(glass, util.vector.of(0, -2, 0), 40);
scene.idle(40);
scene.world.destroyBlock(flowerPos);
scene.idle(10);
scene.overlay.showSelectionWithText(util.select.position(flowerPos), 70).text("Whenever Pulleys stop moving, the moved structure reverts to blocks").attachKeyFrame().placeNearTarget().colored(PonderPalette.RED);
scene.idle(80);
scene.world.toggleRedstonePower(redstoneStuff);
scene.effects.indicateRedstone(leverPos);
scene.world.modifyKineticSpeed(reversable, f -> -f);
scene.effects.rotationDirectionIndicator(pulleyPos.south());
scene.world.movePulley(pulleyPos, -2, 40);
scene.world.moveSection(glass, util.vector.of(0, 2, 0), 40);
scene.world.hideSection(util.select.position(flowerPos), Direction.DOWN);
scene.idle(40);
scene.world.setBlock(flowerPos, Blocks.BLUE_ORCHID.defaultBlockState(), false);
scene.world.showSection(util.select.position(flowerPos), Direction.DOWN);
scene.overlay.showCenteredScrollInput(pulleyPos, Direction.UP, 60);
scene.overlay.showControls(new InputWindowElement(util.vector.topOf(pulleyPos), Pointing.DOWN).scroll().withWrench(), 60);
scene.overlay.showText(70).pointAt(util.vector.topOf(pulleyPos)).placeNearTarget().attachKeyFrame().sharedText("behaviour_modify_wrench");
scene.idle(80);
scene.world.toggleRedstonePower(redstoneStuff);
scene.effects.indicateRedstone(leverPos);
scene.world.modifyKineticSpeed(reversable, f -> -f);
scene.effects.rotationDirectionIndicator(pulleyPos.south());
scene.world.movePulley(pulleyPos, 2, 40);
scene.world.moveSection(glass, util.vector.of(0, -2, 0), 40);
scene.idle(50);
scene.overlay.showText(120).colored(PonderPalette.GREEN).pointAt(util.vector.blockSurface(flowerPos, Direction.WEST)).placeNearTarget().text("It can be configured never to revert to solid blocks, or only at the location it started at");
}
Aggregations