Minecraft:Piston: Difference between revisions
More actions
Sync: updated from Minecraft |
Sync: updated from Minecraft |
||
| (5 intermediate revisions by the same user not shown) | |||
| Line 7: | Line 7: | ||
| image2caption = {{BE}} | | image2caption = {{BE}} | ||
| invimage = Piston | | invimage = Piston | ||
| waterloggable = {{jebe|No|Yes}} | |||
| transparent = {{jebe|No|Yes}} | | transparent = {{jebe|No|Yes}} | ||
| light = No | | light = No | ||
| Line 50: | Line 51: | ||
When a piston loses power, its head retracts. Like the extension, the retraction starts after a [[#Start delay|start delay]] and takes {{convert|2|game tick|second}} to finish. | When a piston loses power, its head retracts. Like the extension, the retraction starts after a [[#Start delay|start delay]] and takes {{convert|2|game tick|second}} to finish. | ||
A piston that pushes a [[Minecraft:slime block]] bounces any entity that it displaces in the direction the piston is facing. Entities on top of a moving [[Minecraft:honey block]], or any other moving block,{{only|bedrock|short=1}} will also move with it. In addition, when a slime block or a honey block is moved by a piston, any movable block adjacent (not diagonally) to it also moves. See | {{IN|je}}, a piston that is de-powered during the extension process aborts its extension and starts to retract (assuming it can detect the signal change). Any block which was being pushed by that piston continues to move as if the piston was still pushing it. | ||
A piston that pushes a [[Minecraft:slime block]] bounces any entity that it displaces in the direction the piston is facing. Entities on top of a moving [[Minecraft:honey block]], or any other moving block,{{only|bedrock|short=1}} will also move with it. In addition, when a slime block or a honey block is moved by a piston, any movable block adjacent (not diagonally) to it also moves. See [[#Sticky blocks|§ Sticky blocks]] for more details. | |||
{{IN|be}}, blocks that require a support (such as levers) can be placed on the back or sides of a piston without being destroyed when that piston extends. {{IN|je}}, on the other hand, the majority of blocks that require a support are only safe to place on the back of pistons. | {{IN|be}}, blocks that require a support (such as levers) can be placed on the back or sides of a piston without being destroyed when that piston extends. {{IN|je}}, on the other hand, the majority of blocks that require a support are only safe to place on the back of pistons. | ||
{{IN|be}}, comparators can read the fullness of containers through pistons, despite them not being [[Minecraft:conductive]]. | |||
<!--=== Basic behavior === | <!--=== Basic behavior === | ||
* Extension: Pushes up to 12 blocks in front of the head. | * Extension: Pushes up to 12 blocks in front of the head. | ||
| Line 63: | Line 68: | ||
--> | --> | ||
=== Start delay === | === Powering pistons === | ||
[[File:Stacked pistons powered by one redstone line.png|alt=|thumb|200px|Pistons powered by one line of redstone.]] | |||
Pistons can be activated from any side, excluding from the head. | |||
{{IN|BE}}, redstone dust gets automatically redirected toward pistons if placed next to them (except for the head's side). | |||
==== Start delay ==== | |||
A piston won't extend or retract immediately when it is activated: this phenomenon is known as "start delay". | A piston won't extend or retract immediately when it is activated: this phenomenon is known as "start delay". | ||
| Line 71: | Line 83: | ||
! Java | ! Java | ||
| 0 or 1 game tick | | 0 or 1 game tick | ||
| 0 ticks if powered | | 0 ticks if powered during the scheduled tick, random tick or block event phase; 1 tick if powered during the entity or block entity phase, or during player input handling. | ||
|- | |- | ||
! Bedrock | ! Bedrock | ||
| Line 84: | Line 96: | ||
{{IN|be}}, the start delay is fixed at {{convert|2|game tick|second}}, meaning that the piston starts to extend or retract 2 game ticks after it is activated. Pistons can only activate on the input/consumer redstone tick ([[Minecraft:C-tick]]). | {{IN|be}}, the start delay is fixed at {{convert|2|game tick|second}}, meaning that the piston starts to extend or retract 2 game ticks after it is activated. Pistons can only activate on the input/consumer redstone tick ([[Minecraft:C-tick]]). | ||
=== | ==== Quasi-Connectivity ==== | ||
{{see also|Tutorial:Quasi-connectivity}} | {{see also|Tutorial:Quasi-connectivity}} | ||
{{exclusive|java|section=1}} | {{exclusive|java|section=1}} | ||
{{Schematic|caption=''' | {{Schematic|caption='''A lamp that's being powered normally on top of a piston that's being powered through quasi-connectivity. ''' | ||
|SB|rt-$w!|RL-!||- | |SB|rt-$w!|RL-!||- | ||
|||pi-e!|pe-e | |||pi-e!|pe-e | ||
}} | }} | ||
Pistons powered from one block above compared to most redstone components: this property is called [[Minecraft:quasi-connectivity]] | Pistons can be powered from one block above compared to most redstone components: this property is called [[Minecraft:quasi-connectivity]] (QC). With quasi-connectivity, a piston facing up can also be powered from the head's direction, which is otherwise impossible. Due to quasi-connectivity, a piston facing up that has a [[Minecraft:block of redstone]] on top of itself can extend but not retract: this happens because after the piston extends, it keeps receiving power from the redstone block. | ||
=== Soft inversion === | Quasi-connectivity can be used to make a [[Minecraft:Tutorial:Block update detector|BUD switch]], taking advantage of the fact that a piston powered through QC doesn't always get immediately [[Minecraft:block update|updated]]. | ||
==== Soft inversion ==== | |||
{{see also|Tutorial:Soft inversion}} | {{see also|Tutorial:Soft inversion}} | ||
{{exclusive|bedrock|section=1}} | {{exclusive|bedrock|section=1}} | ||
{{Schematic|caption=''' | {{Schematic|caption='''Flicking the lever caused the piston to extend and the redstone torch to turn off.''' | ||
|||pe-n|||- | |||pe-n|||- | ||
|le-$e!|SB|pi-n!|rt-$w|RL|- | |le-$e!|SB|pi-n!|rt-$w|RL|- | ||
| Line 111: | Line 116: | ||
When a piston that has a [[Minecraft:redstone torch]] attached to it is powered, the redstone torch turns off, and when said piston is depowered, the redstone torch turns back on: this property is called ''[[Minecraft:soft inversion]]''.<ref>{{bug|MCPE-17909|||WF}}</ref><ref>"Explaining soft inversion: the Minecraft Bedrock Redstone bug that won't get fixed" – https://www.youtube.com/watch?v=zUgKXTsLOA0</ref> Since soft inversion works even if the piston is being powered indirectly through a block, it can be used to toggle the state of a redstone torch from farther away compared to other powering methods. It's still possible to take advantage of soft inversion even if the piston cannot extend or retract. | When a piston that has a [[Minecraft:redstone torch]] attached to it is powered, the redstone torch turns off, and when said piston is depowered, the redstone torch turns back on: this property is called ''[[Minecraft:soft inversion]]''.<ref>{{bug|MCPE-17909|||WF}}</ref><ref>"Explaining soft inversion: the Minecraft Bedrock Redstone bug that won't get fixed" – https://www.youtube.com/watch?v=zUgKXTsLOA0</ref> Since soft inversion works even if the piston is being powered indirectly through a block, it can be used to toggle the state of a redstone torch from farther away compared to other powering methods. It's still possible to take advantage of soft inversion even if the piston cannot extend or retract. | ||
=== | === Sticky blocks === | ||
{{ | {{Schematic | ||
Despite not being a | |caption=Piston A extends because the slime block can't stick to the adjacent obsidian. Piston B fails because the obsidian blocks the block attached to the slime block. | ||
|clear=right | |||
|le-$e!|pi-e!+A|pe-e|SL|le-$e!|pi-e+B|SL||- | |||
|||obsidian|obsidian|||MB|obsidian | |||
}} | |||
[[Minecraft:slime block|Slime]] and [[Minecraft:honey block|honey]] blocks are sticky: when either block is moved by a piston, adjacent (non-diagonal) blocks stick to and move with it.{{note|Despite their name, [[Minecraft:sticky pistons]] do not fall under this definition.}} For example, a slime block sitting on the ground attempts to move the ground block underneath itself, which in turn has to push additional ground blocks in the direction of motion just as if they were being pushed directly by a piston. The same occurs when a sticky block is moved by another adjacent sticky block of the same kind. For example, a 2×2×2 cube of honey blocks may be pushed as a single unit by a piston acting on any of the blocks in the cube. Any block that cannot be moved or can be broken by a piston does not stick to sticky blocks. However, if an adjacent block could be moved but is prevented from being moved by the presence of an immovable block, the sticky block is prevented from moving as well, and the piston does not extend. | |||
Slime and honey blocks do not stick to each other. This allows redstone contraptions to use alternating slime and honey blocks side by side without interfering with each other. | |||
Slime and honey blocks' stickiness is unilateral. They can't be pulled by a non-[[Minecraft:sticky piston]], and they are not moved if an adjacent (non-sticky) block is moved by a piston. The maximum of 12 blocks moved by a piston still applies. For example, a 2×2×3 structure of slime blocks may be pushed by a piston as long as no other movable block is adjacent to it. A piston cannot move itself via a "hook" constructed of sticky blocks, but [[Minecraft:flying machines]] can be created with multiple pistons. | |||
[[Minecraft:Glazed terracotta]] and the [[Minecraft:heavy core]]{{only|bedrock|short=1}} do not stick to adjacent slime or honey blocks, even though they can be pushed by pistons. | |||
=== Sculk detection === | |||
Pistons emit vibrations detectable by [[Minecraft:sculk sensor]]s. A [[Minecraft:calibrated sculk sensor]] tuned to signal strength '''10''' detects piston retraction; strength '''11''' detects extension; strength '''12''' detects a block broken by a piston. | |||
== Limitations == | |||
<!-- [[Minecraft:Push reaction]] redirects here. --> | <!-- [[Minecraft:Push reaction]] redirects here. --> | ||
Pistons cannot push: | Pistons cannot push: | ||
| Line 126: | Line 145: | ||
{{:Piston/Table}} | {{:Piston/Table}} | ||
== Technical components == | == Technical components == | ||
| Line 233: | Line 234: | ||
|{{HistoryLine||June 7, 2011|link={{tweet|jeb|78167135435759617}}|[[Minecraft:Jeb]] tweets an image of pistons in development. | |{{HistoryLine||June 7, 2011|link={{tweet|jeb|78167135435759617}}|[[Minecraft:Jeb]] tweets an image of pistons in development. | ||
|[[File:Piston (U) pJE20110607.png|32px]] The piston texture as screen-captured while in development had iron bands running over the head. The bands were removed for the release, leaving only iron brackets around the corners and edges.}} | |[[File:Piston (U) pJE20110607.png|32px]] The piston texture as screen-captured while in development had iron bands running over the head. The bands were removed for the release, leaving only iron brackets around the corners and edges.}} | ||
|{{HistoryLine||June 14, 2011|link={{YouTube link|uZJr86d2IUo}}|A video showing pistons being worked on is posted on the official Minecraft YouTube channel.}} | |||
}} | }} | ||
| Line 244: | Line 246: | ||
|{{HistoryLine|java}} | |{{HistoryLine|java}} | ||
|{{HistoryLine||1.2.4|dev=release|Spruce, birch, and jungle [[Minecraft:planks]] can now be used to craft pistons.}} | |{{HistoryLine||1.2.4|dev=release|Spruce, birch, and jungle [[Minecraft:planks]] can now be used to craft pistons.}} | ||
|{{HistoryLine||1.3.1|dev=12w26a|Pistons now schedule extensions and retractions rather than executing them as soon as they are | |{{HistoryLine||1.3.1|dev=12w26a|Pistons now schedule extensions and retractions rather than executing them as soon as they realize they are (un)powered.}} | ||
|{{HistoryLine||1.5|dev=13w10a|Pistons changing their {{code|extended}} state from {{code|false}} to {{code|true}} is now the ''last'' step of (the start of) the extension process, rather then the first. This change affects some redstone contraptions.}} | |{{HistoryLine||1.5|dev=13w10a|Pistons changing their {{code|extended}} state from {{code|false}} to {{code|true}} is now the ''last'' step of (the start of) the extension process, rather then the first. This change affects some redstone contraptions.}} | ||
|{{HistoryLine||1.7.2|dev=1.7.1|Acacia and dark oak [[Minecraft:planks]] can now be used to craft pistons.}} | |{{HistoryLine||1.7.2|dev=1.7.1|Acacia and dark oak [[Minecraft:planks]] can now be used to craft pistons.}} | ||
| Line 346: | Line 348: | ||
|date=January 3, 2019}} | |date=January 3, 2019}} | ||
</ref> | </ref> | ||
* | * Carpets can be placed on top of [[Minecraft:moving piston|moving blocks]]. | ||
== Gallery == | == Gallery == | ||
| Line 360: | Line 361: | ||
<gallery> | <gallery> | ||
Pistonscreen.png|First screenshot of pistons | Pistonscreen.png|First screenshot of pistons | ||
Pistons.png|Another screenshot of in-development pistons | |||
Piston Light.png|Light shining through an extended piston | Piston Light.png|Light shining through an extended piston | ||
Pocket Edition Pistons.jpg|Redstone connecting to pistons in ''Bedrock Edition'' | Pocket Edition Pistons.jpg|Redstone connecting to pistons in ''Bedrock Edition'' | ||
Latest revision as of 11:11, 9 July 2026
Template:For Template:Earth hatnote Template:Infobox block A piston is a Minecraft:block capable of pushing most Minecraft:entities and blocks when given a Minecraft:redstone signal.
Some blocks cannot be moved, break when pushed or have other interactions with pistons. A piston can move up to twelve blocks at once.
Obtaining
Breaking
A piston can be broken using any Minecraft:tool with equal efficiency, and always drops itself. It is faster to break them with a Minecraft:pickaxe. The pickaxe is also the preferred tool for breaking the head when extended.<ref>Template:Bug</ref> Template:Breaking row
Crafting
Usage
Crafting ingredient
Redstone component
Pistons are always placed facing toward the player. When powered, the piston's wooden surface (the "head") tries to start extending after a start delay. The extension takes Template:Convert to finish. When it extends, it pushes at most 12 blocks. The piston makes a sound that can be heard within a 31×31×31 cube centered on the activating piston. Any entities in the path of an extending piston (or any block it might be moving) are pushed along, when possible. If the entities cannot be moved, the block is pushed inside them, suffocating Minecraft:mobs when pushed into their Minecraft:eye height (assuming said block is solid).
When a piston loses power, its head retracts. Like the extension, the retraction starts after a start delay and takes Template:Convert to finish.
Template:IN, a piston that is de-powered during the extension process aborts its extension and starts to retract (assuming it can detect the signal change). Any block which was being pushed by that piston continues to move as if the piston was still pushing it.
A piston that pushes a Minecraft:slime block bounces any entity that it displaces in the direction the piston is facing. Entities on top of a moving Minecraft:honey block, or any other moving block,Template:Only will also move with it. In addition, when a slime block or a honey block is moved by a piston, any movable block adjacent (not diagonally) to it also moves. See § Sticky blocks for more details.
Template:IN, blocks that require a support (such as levers) can be placed on the back or sides of a piston without being destroyed when that piston extends. Template:IN, on the other hand, the majority of blocks that require a support are only safe to place on the back of pistons.
Template:IN, comparators can read the fullness of containers through pistons, despite them not being Minecraft:conductive.
Powering pistons
Pistons can be activated from any side, excluding from the head.
Template:IN, redstone dust gets automatically redirected toward pistons if placed next to them (except for the head's side).
Start delay
A piston won't extend or retract immediately when it is activated: this phenomenon is known as "start delay".
| Edition | Start delay | Notes |
|---|---|---|
| Java | 0 or 1 game tick | 0 ticks if powered during the scheduled tick, random tick or block event phase; 1 tick if powered during the entity or block entity phase, or during player input handling. |
| Bedrock | Fixed 2 game ticks | Activation occurs only on a consume tick (Minecraft:C-tick). |
Template:IN, the start delay can be 0 (activation in the same tick) or Template:Convert (activation in the next tick) depending on the game process in which the piston is powered:
- If the piston is powered and updated in the scheduled tick phase, Minecraft:random tick phase or block event phase, the piston activates in this game tick's block event phase, which means the start delay in this case is 0.
- If the piston is powered and updated during the Minecraft:entity phase or the Minecraft:block entity phase, or by player actions, the piston activates in the next game tick's block event phase, which means the start delay in this case is 1 tick. Notably, because blocks pushed by pistons arrive during the block entity phase (except when dropped by a sticky piston), in a chain of pistons each pushing a redstone block to activate the next, successive activations will happen 3 ticks apart.
Template:IN, the start delay is fixed at Template:Convert, meaning that the piston starts to extend or retract 2 game ticks after it is activated. Pistons can only activate on the input/consumer redstone tick (Minecraft:C-tick).
Quasi-Connectivity
Template:See also Template:Exclusive Template:Schematic Pistons can be powered from one block above compared to most redstone components: this property is called Minecraft:quasi-connectivity (QC). With quasi-connectivity, a piston facing up can also be powered from the head's direction, which is otherwise impossible. Due to quasi-connectivity, a piston facing up that has a Minecraft:block of redstone on top of itself can extend but not retract: this happens because after the piston extends, it keeps receiving power from the redstone block.
Quasi-connectivity can be used to make a BUD switch, taking advantage of the fact that a piston powered through QC doesn't always get immediately updated.
Soft inversion
Template:See also Template:Exclusive Template:Schematic When a piston that has a Minecraft:redstone torch attached to it is powered, the redstone torch turns off, and when said piston is depowered, the redstone torch turns back on: this property is called Minecraft:soft inversion.<ref>Template:Bug</ref><ref>"Explaining soft inversion: the Minecraft Bedrock Redstone bug that won't get fixed" – https://www.youtube.com/watch?v=zUgKXTsLOA0</ref> Since soft inversion works even if the piston is being powered indirectly through a block, it can be used to toggle the state of a redstone torch from farther away compared to other powering methods. It's still possible to take advantage of soft inversion even if the piston cannot extend or retract.
Sticky blocks
Template:Schematic Slime and honey blocks are sticky: when either block is moved by a piston, adjacent (non-diagonal) blocks stick to and move with it.Template:Note For example, a slime block sitting on the ground attempts to move the ground block underneath itself, which in turn has to push additional ground blocks in the direction of motion just as if they were being pushed directly by a piston. The same occurs when a sticky block is moved by another adjacent sticky block of the same kind. For example, a 2×2×2 cube of honey blocks may be pushed as a single unit by a piston acting on any of the blocks in the cube. Any block that cannot be moved or can be broken by a piston does not stick to sticky blocks. However, if an adjacent block could be moved but is prevented from being moved by the presence of an immovable block, the sticky block is prevented from moving as well, and the piston does not extend.
Slime and honey blocks do not stick to each other. This allows redstone contraptions to use alternating slime and honey blocks side by side without interfering with each other.
Slime and honey blocks' stickiness is unilateral. They can't be pulled by a non-Minecraft:sticky piston, and they are not moved if an adjacent (non-sticky) block is moved by a piston. The maximum of 12 blocks moved by a piston still applies. For example, a 2×2×3 structure of slime blocks may be pushed by a piston as long as no other movable block is adjacent to it. A piston cannot move itself via a "hook" constructed of sticky blocks, but Minecraft:flying machines can be created with multiple pistons.
Minecraft:Glazed terracotta and the Minecraft:heavy coreTemplate:Only do not stick to adjacent slime or honey blocks, even though they can be pushed by pistons.
Sculk detection
Pistons emit vibrations detectable by Minecraft:sculk sensors. A Minecraft:calibrated sculk sensor tuned to signal strength 10 detects piston retraction; strength 11 detects extension; strength 12 detects a block broken by a piston.
Limitations
Pistons cannot push:
- Blocks listed as such in the table below.
- Blocks into the Minecraft:void or above the Minecraft:build limit.
- More than 12 blocks at once.
- Template:IN, blocks beyond the Minecraft:world border.
If the requirements for a block to be pushed are not met, the piston will not extend.
Technical components
Template:Main Pistons have 2 technical blocks that cannot be obtained. These include the piston head and moving piston blocks.
Sounds
Generic
Template:Edition: Template:Sound table/Block/Stone/JE Template:Edition (piston): Template:Sound table/Block/Stone/BE Template:Edition (arm): Template:Sound table/Block/Normal/BE
Unique
Data values
ID
Template:Edition: Template:ID table
Template:Edition: Template:ID table Template:ID table
Block states
Template:See also
The piston block uses following block states:
<section begin="block states"/>Template:El: Template:Bst Template:Bst
Template:El: Template:Bst<section end="block states"/>
Block data
Template:Exclusive Template:IN, a piston has a Minecraft:block entity associated with it that holds additional data about the block.
Achievements
Videos
History
Development
Java Edition
Bedrock Edition
Legacy Console Edition
New Nintendo 3DS Edition
Data history
Java Edition
Bedrock Edition
Legacy Console Edition
Issues
Trivia
- Mojang stated that the 12-block push limit for pistons would not be changed, because "the current limitations are by design".<ref>
Template:Cite </ref>
- Carpets can be placed on top of moving blocks.
Gallery
Screenshots
-
Fundamental logic gates, implemented purely with pistons and Minecraft:redstone repeaters, clockwise from upper left: AND, OR, XOR, and NOT
-
Slow clock generator with pistons and redstone
-
An example of a piston-controlled waterflow
Mojang screenshots
-
First screenshot of pistons
-
Another screenshot of in-development pistons
-
Light shining through an extended piston
-
Redstone connecting to pistons in Bedrock Edition
-
A piston being crafted with a fish. This is a joke about the piston sounds heard in Java Edition 24w20a, which have been said to sound wet.
-
"Minecraft:Makena tinkering with a Redstone contraption made up of Pistons pushing a Lime Wool block"<ref>Template:Mcnet</ref>
Concept artwork
-
Notch's explanation on how the rod (a full block long when extended) fits into the piston box (whose depth is a block minus the face's thickness)<ref>Template:Tweet</ref>
In other media
-
Artwork of an incorrectly-rotated piston connected to a Minecraft:lever via Minecraft:redstone dust
-
Pistons as they appear in Minecraft: Shape Your World
-
Pistons as they appear in Template:AMCM.
-
A duo dressed as a piston and Minecraft:End crystal
See also
Notes
References
External links
Template:Navbox redstone Template:Navbox blocks
Minecraft:de:Kolben Minecraft:es:Pistón Minecraft:fr:Piston Minecraft:hu:Dugattyú Minecraft:it:Pistone Minecraft:ja:ピストン Minecraft:ko:피스톤 Minecraft:nl:Zuiger Minecraft:pl:Tłok Minecraft:pt:Pistão Minecraft:ru:Поршень Minecraft:th:ลูกสูบ Minecraft:uk:Поршень Minecraft:zh:活塞