I've watched many videos, and tried some myself, but none of it seems to work, what I'm trying to do here is make a row of hidden barrels. Obviously there are many way to hide it but I'm trying to do this.
Arqade is a question and answer site for passionate videogamers on all platforms. It only takes a minute to sign up.Sign up to join this community
Currently in Java Edition without mods (like Carpet mod with the movableBlockEntities rule enabled) this is impossible - no block with persistent inventory is pushable by pistons. Chests, barrels, furnaces, dispensers, hoppers, brewing stands, and a range of others - anything you can put some items on, leave the GUI, come back later and pull some items out - behaves like obsidian where it comes to pushing.
There's a range of designs of "hidden storage" where a segment of a wall or floor is retracted, revealing the containers hidden behind it. But where it comes to "pop-up containers" the way classic "pop-up crafting tables" are done, the closest you can get is to drop (or bounce on slime) a minecart with chest into place, or dispense a shulker box using a dispenser, then break it with a piston and suck it in with a hopper / minecart w/hopper. Or you could leave the barrels in place and move the entire remainder of the house... as you can bet this is no small feat, but there are madmen who built "moving houses" in Minecraft.
Of course with movable block entities ( installing Carpet mod and executing
/carpet movableBlockEntities true and
/carpet setDefault movableBlockEntities true ) this becomes quite doable with a decently simple contraption.
An ABBA circuit with its A output negated with a torch. The negated A output goes into two rows of pistons retracting the wall (powering the upper row directly you assure the bottom row will also work through quasi-connectivity), and another row (connected to B) below pushing the barrels into place after the wall has retracted or removes them to make room for the wall. (obviously use barrels in place of the crafting tables; used here because I don't have Carpet mod.)
This will also work in Bedrock Edition without any mods - the only change would be moving the top redstone line one block lower (no quasi-connectivity so all pistons must be powered directly, but top pistons redirecting redstone will be able to grab their power directly from the dust line.)
Important see this before reading Important
Ok, to start, I will say that in java edition, chests and furnaces etc are immovable objects, so they cannot be moved using a piston/sticky piston. If you want to hide something that is movable, replace the crafting tables with the movable object.
So, when I made this contraption, the problem I faced was timing the movement of the 2 sets of pistons, so the repeaters that I added were to make them sync with each other perfectly, If you don't keep the same ticks, then it will not work. It won't work if you increase the number of pistons that send the crafting tables up as the redstone signal will not be able to reach till there, and if you add repeaters, the timings will be disturbed. Also, as @SF said, you could put minecart with chests in place of the crafting tables, though I didn't try it.
Please note that I am not good at redstone, in fact this is my first contraption that I made myself without the help of redstone tutorials. Maybe my contraption could be made better and if so, please tell me so I could get better. I tried my best to make a compact machine.
I hope this helped. :D
A row of barrels would make it too obvious that your hiding your stuff in the walls and floor, so 1 barrel would be VERY sneaky, or use map art or trapdoors, cause those cover entire blocks, enabling you to hide that enchanted netherite sword right under a map, and thieves will have no clue where to look, keeping your diamonds safe and sound right under the wallpaper.