1

Basically, I'm trying to make a piston door that is activated by a lever (and an elevator), and what I want is to be able to switch on a lever, which will set a red stone block behind the pistons, then when it's switched off, to summon air behind them.

However the best I could get was a repeat one with the red stone command attached to a chain with the air one and it created some spooky demonic piston doors (the red stone block was flashing while being reset so fast)

So like is there a way that I can set the pistons to activate (or the redstone block to be set) when the lever is turned on, and to replace it with air when it is switched off? I have been having trouble trying to find anything that is remotely close to what I'm trying to do for info. Hopefully I can get some help here, thanks!

2
  • Can't you just power the pistons directly with the lever (and some redstone)?
    – dly
    Apr 5, 2017 at 7:18
  • Well it would work but if I'm making something much larger it can be inconvenient
    – Shelilla
    Apr 5, 2017 at 13:58

1 Answer 1

1

Ah, this requires some help from our friend, the NOT gate. NOT gates will turn on when the lever is off... and turn off when the lever is on. Basically, you should build something like this:

enter image description here

And from the back:

enter image description here

The command block on the far left should contain the command

/setblock * * * minecraft:redstone_block

And the one on the far right:

/setblock * * * minecraft:air

Replace the * * * in both commands with the coordinates of where the redstone block should be placed.

Hope this helps!

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .