Minecraft:Interactable blocks: Difference between revisions
More actions
imported>Aloi4 |
Fix template calls: add MC/ prefix |
||
| (One intermediate revision by the same user not shown) | |||
| Line 1: | Line 1: | ||
{{Distinguish|Workstation}} | {{MC/Distinguish|Workstation}} | ||
{{set index}} | {{set index}} | ||
'''Interactable blocks''' are blocks with functionalities accessed with pressing {{ | '''Interactable blocks''' are blocks with functionalities accessed with pressing {{MC/Control|use}} while looking at it. | ||
== Mechanics of use on block == | == Mechanics of use on block == | ||
When a player is pressing {{ | When a player is pressing {{MC/Control|use}} and is looking at an interaction box of a block within its interaction range, and there are no mob hitboxes in between, then they attempt to interact with the block. | ||
There are three types of interaction. The first two are defined by the block (although the item in hand can influence the first) and the last is defined by the item (although the interacted block can influence it). In order of attempted interaction: | There are three types of interaction. The first two are defined by the block (although the item in hand can influence the first) and the last is defined by the item (although the interacted block can influence it). In order of attempted interaction: | ||
| Line 20: | Line 20: | ||
The swing animation is only applied when there is some success (in any of the use). | The swing animation is only applied when there is some success (in any of the use). | ||
Using a block without an item does not necessarily mean the player has no item in hand; instead it simply means using the block without considering the item. Similarly, it is possible to use an item on a block even when the hand is empty.{{note|When there is no item in hand, the item considered is [[Minecraft:air]]; {{ | Using a block without an item does not necessarily mean the player has no item in hand; instead it simply means using the block without considering the item. Similarly, it is possible to use an item on a block even when the hand is empty.{{note|When there is no item in hand, the item considered is [[Minecraft:air]]; {{MC/In|je}} this can have an effect if {{MC/Cd|minicraft:air}} is in certain item tag.}} | ||
{{ | {{MC/In|Java}}, when the first or third attempt is successful, the advancement trigger {{MC/Cd|minecraft:item_used_on_block}} is activated, and if the second case is a success, trigger {{MC/Cd|minecraft:default_block_use}} is activated. Subsequently, in any successful case, the {{MC/Cd|minecraft:any_block_use}} trigger is activated. | ||
== Interactable blocks without items == | == Interactable blocks without items == | ||
| Line 28: | Line 28: | ||
=== Blocks with GUI === | === Blocks with GUI === | ||
Blocks with GUI, show a menu that you can use to interact with it. These Interactions include [[Minecraft:crafting]], smelting, [[Minecraft:Inventory#External inventories|storing]], [[Minecraft:brewing]], smithing, enchanting, and other functions. | |||
Chests only open if there is no | Chests only open if there is no redstone conductor block above them or a cat sitting on top of them{{note|A cat is considered to be on top of a chest if any part of there hitbox is inside a 1×1×1 box above the chest.}}, in the case of a double chest, the same condition is necessary for a connected chest. Shulker boxes only open if their opening (0.5 blocks towards the top) does not have any collision with the collision box of another block. Ender chests only open if there is no redstone conductor block above them. | ||
These, and only these, blocks can be integrated in | These, and only these, blocks can be integrated in spectator mode, except for the blocked chests and ender chests. | ||
Open a barrel, any chest (incluid ender chest), or a shulker box also anger nearby [[Minecraft:piglin]]s. {{ | Open a barrel, any chest (incluid ender chest), or a shulker box also anger nearby [[Minecraft:piglin]]s. {{MC/In|JE}}, interacting with these blocks also increases the associated status, exect the crafting table and the enchanting table. | ||
'''Blocks whose GUI depends on the [[Minecraft:block entity]]''' | '''Blocks whose GUI depends on the [[Minecraft:block entity]]''' | ||
* {{ | * {{MC/Blocklink|Furnace}} | ||
** {{ | ** {{MC/Blocklink|Blast Furnace}} | ||
**{{ | **{{MC/Blocklink|Smoker}} | ||
*{{ | *{{MC/Blocklink|Barrel}} | ||
*{{ | *{{MC/Blocklink|Beacon}} | ||
*{{ | *{{MC/Blocklink|Brewing Stand}} | ||
*{{ | *{{MC/Blocklink|Chest}} | ||
**{{ | **{{MC/Blocklink|Copper Chests|link=Copper Chest}} | ||
**{{ | **{{MC/Blocklink|Trapped Chest}} | ||
*{{ | *{{MC/Blocklink|Crafter}} | ||
*{{ | *{{MC/Blocklink|Dispenser}} | ||
**{{ | **{{MC/Blocklink|Dropper}}<!--Use the same useWithoutItem(...) method--> | ||
*{{ | *{{MC/Blocklink|Enchanting Table}} | ||
*{{ | *{{MC/Blocklink|Hopper}} | ||
*{{ | *{{MC/Blocklink|Lectern}} | ||
*{{ | *{{MC/Blocklink|Shulker Boxes}} | ||
'''Blocks whose GUI depends on the player''' | '''Blocks whose GUI depends on the player''' | ||
*{{ | *{{MC/Blocklink|Ender Chest}} | ||
'''Other''' | '''Other''' | ||
*{{ | *{{MC/Blocklink|Anvils}} | ||
*{{ | *{{MC/Blocklink|Cartography Table}} | ||
*{{ | *{{MC/Blocklink|Crafting Table}} | ||
*{{ | *{{MC/Blocklink|Grindstone}} | ||
*{{ | *{{MC/Blocklink|Loom}} | ||
*{{ | *{{MC/Blocklink|Smithing Table}} | ||
*{{ | *{{MC/Blocklink|Stonecutter}} | ||
=== Other === | === Other === | ||
Interacting blocks without item that don't open a menu. Blocks like signs, command blocks, and structure blocks set a new screen, but these are not considered menus. Unlike menus, they are opened by the local player and not the server player{{More info|If there's a wiki article explaining the difference, please link it here.<!--If it doesn't exist, it's an important article to create.-->}}. | Interacting blocks without item that don't open a menu. Blocks like signs, command blocks, and structure blocks set a new screen, but these are not considered menus. Unlike menus, they are opened by the local player and not the server player{{MC/More info|If there's a wiki article explaining the difference, please link it here.<!--If it doesn't exist, it's an important article to create.-->}}. | ||
*{{ | *{{MC/Blocklink|Beds}} | ||
*{{ | *{{MC/Blocklink|Bell}} | ||
*{{ | *{{MC/Blocklink|Buttons}} | ||
*{{ | *{{MC/Blocklink|Cake}} | ||
*{{ | *{{MC/Blocklink|Cake with Candle}} | ||
**{{ | **{{MC/Blocklink|Cake with Cyan Candle|Cake with Dyed Candles}} | ||
*{{ | *{{MC/Blocklink|Cave Vines}} | ||
**{{ | **{{MC/Blocklink|Cave Vines Plant|link=Technical_blocks}} | ||
*{{ | *{{MC/Blocklink|Chiseled Bookshelf}} | ||
*{{ | *{{MC/Blocklink|Command Blocks}} | ||
*{{ | *{{MC/Blocklink|Comparator|id=Redstone Comparator}} | ||
*{{ | *{{MC/Blocklink|Composter}} (level {{MC/Cd|8}}) | ||
*{{ | *{{MC/Blocklink|Daylight Detector}} | ||
*{{ | *{{MC/Blocklink|Decorated Pot}} | ||
*{{ | *{{MC/Blocklink|Doors}} | ||
*{{ | *{{MC/Blocklink|Dragon Egg}} | ||
*{{ | *{{MC/Blocklink|Fences}}{{note|Try binding player leashed mobs}} | ||
* {{ | * {{MC/Blocklink|Fence Gates}} | ||
* {{ | * {{MC/Blocklink|Potted Acacia Sapling|text=‌}}{{MC/Blocklink|Potted Poppy|text=‌}}{{MC/Blocklink|Potted Bamboo|text=‌}}{{MC/Blocklink|Potted Crimson Fungus|text=‌}}⋯ [[Minecraft:Flower Pot|All Potted Plants/Fungi]] | ||
*{{ | *{{MC/Blocklink|Jigsaw Block}} | ||
*{{ | *{{MC/Blocklink|Jukebox}} | ||
*{{ | *{{MC/Blocklink|Lever}} | ||
*{{ | *{{MC/Blocklink|Light|link=Light (block)}}{{note|Technically, the light is interacting without items; however, its interaction box is empty when not holding a light, making interaction impossible.}} | ||
*{{ | *{{MC/Blocklink|Note Block}} | ||
*{{ | *{{MC/Blocklink|Redstone Wire}} | ||
*{{ | *{{MC/Blocklink|Repeater|id=Redstone Repeater}} | ||
*{{ | *{{MC/Blocklink|Respawn Anchor}} | ||
<!--*{{ | <!--*{{MC/Blocklink|Shelves}} only with itens--> | ||
*{{ | *{{MC/Blocklink|Signs}} ({{MC/Blocklink|Wall Signs|link=Technical_blocks}}) | ||
** {{ | ** {{MC/Blocklink|Hanging Signs}} ({{MC/Blocklink|Wall Hanging Signs|link=Technical_blocks}}) | ||
*{{ | *{{MC/Blocklink|Structure Block}} | ||
*{{ | *{{MC/Blocklink|Sweet Berry Bush}} | ||
*{{ | *{{MC/Blocklink|Test Block}} | ||
*{{ | *{{MC/Blocklink|Test Instance Block}} | ||
*{{ | *{{MC/Blocklink|Wooden Trapdoors|text=‌}}{{MC/Blocklink|Copper Trapdoors|text=‌}}Trapdoors (except iron) | ||
*{{ | *{{MC/Blocklink|Moving Piston}} (practically never{{Note|When interacting with a moving piston, if there is no [[Minecraft:block entity]] in the position, it is removed. However, its interaction box is always empty, and it is expected that there will always be a block entity in the position. This interaction is probably only for bug fixes and not for gameplayer functionality.}}) | ||
== Interactable blocks with item == | == Interactable blocks with item == | ||
| Line 116: | Line 116: | ||
Some blocks use a certain item, it doesn't create a specific block behavior, but rather blocks or allows another interaction. For example, using the plant/fungi in a pot already prevents the plant/fungi from being removed from the pot, or uses a block in a redstone ore, could try placing it beyond the usual interaction (using other items, like a bucket of water, doesn't attempt use 3). | Some blocks use a certain item, it doesn't create a specific block behavior, but rather blocks or allows another interaction. For example, using the plant/fungi in a pot already prevents the plant/fungi from being removed from the pot, or uses a block in a redstone ore, could try placing it beyond the usual interaction (using other items, like a bucket of water, doesn't attempt use 3). | ||
* {{ | * {{MC/Blocklink|Cauldron}} | ||
** {{ | ** {{MC/Blocklink|Water Cauldron}} | ||
** {{ | ** {{MC/Blocklink|Lava Cauldron}} | ||
** {{ | ** {{MC/Blocklink|Powder Snow Cauldron}} | ||
* {{ | * {{MC/Blocklink|Beehive}} | ||
** {{ | ** {{MC/Blocklink|Bee Nest}} | ||
* {{ | * {{MC/Blocklink|Cake}} | ||
* {{ | * {{MC/Blocklink|Campfire}} | ||
** {{ | ** {{MC/Blocklink|Soul Campfire}} | ||
* {{ | * {{MC/Blocklink|Candle}} | ||
** {{ | ** {{MC/Blocklink|Dyed Candles|id=Candles}} | ||
* {{ | * {{MC/Blocklink|Cake with Candle}} | ||
** {{ | ** {{MC/Blocklink|Cake with Cyan Candle|Cakes with Dyed Candle}} | ||
* {{ | * {{MC/Blocklink|Chiseled Bookshelf}} | ||
* {{ | * {{MC/Blocklink|Composter}} | ||
* {{ | * {{MC/Blocklink|Copper Golem Statues}} | ||
* {{ | * {{MC/Blocklink|Decorated Pot}} | ||
* {{ | * {{MC/Blocklink|Flower Pot}} | ||
** {{ | ** {{MC/Blocklink|Potted Acacia Sapling|text=‌}}{{MC/Blocklink|Potted Poppy|text=‌}}{{MC/Blocklink|Potted Bamboo|text=‌}}{{MC/Blocklink|Potted Crimson Fungus|text=‌}}⋯ [[Minecraft:Flower Pot|All Potted Plants/Fungi]] | ||
* {{ | * {{MC/Blocklink|Jukebox}} | ||
* {{ | * {{MC/Blocklink|Lectern}} | ||
* {{ | * {{MC/Blocklink|Note Block}} | ||
* {{ | * {{MC/Blocklink|Pumpkin}} | ||
* {{ | * {{MC/Blocklink|all-redstone-ore|Redstone Ores|link=Redstone Ore}} | ||
* {{ | * {{MC/Blocklink|Respawn Anchor}} | ||
* {{ | * {{MC/Blocklink|Shelves}} | ||
* {{ | * {{MC/Blocklink|Signs}} ({{MC/Blocklink|Wall Signs|link=Technical blocks}}) | ||
** {{ | ** {{MC/Blocklink|Hanging Signs}} ({{MC/Blocklink|Wall Hanging Signs|link=Technical blocks}}) | ||
* {{ | * {{MC/Blocklink|Sweet Berry Bush}} | ||
* {{ | * {{MC/Blocklink|TNT}} | ||
* {{ | * {{MC/Blocklink|Vault}} | ||
== Items that can be used in blocks == | == Items that can be used in blocks == | ||
| Line 157: | Line 157: | ||
== Navigation == | == Navigation == | ||
{{Navbox blocks|Utility}}__DISAMBIG__ | {{MC/Navbox blocks|Utility}}__DISAMBIG__ | ||
ko:상호작용할 수 있는 블록 | |||
pt:Blocos interativos | |||
Latest revision as of 20:29, 9 April 2026
Template:Hatnote Template:Set index
Interactable blocks are blocks with functionalities accessed with pressing {{#vardefine: control | right click on mouse or left trigger on gamepad }}use while looking at it.
Mechanics of use on block
When a player is pressing {{#vardefine: control | right click on mouse or left trigger on gamepad }}use and is looking at an interaction box of a block within its interaction range, and there are no mob hitboxes in between, then they attempt to interact with the block.
There are three types of interaction. The first two are defined by the block (although the item in hand can influence the first) and the last is defined by the item (although the interacted block can influence it). In order of attempted interaction:
- Use item on block (focused on the block)
- Use block without item
- Use item on block (focused on the item)
If the player Template:Ctrl and has an item in hand, the first two uses of the blocks are ignored and the attempt directly goes to the last one. Otherwise, the player attempts use one; if successful, the interaction ends. Otherwise, depending on the result of the use one, they may have to perform use two or skip straight to use three. If they attempt use two, and fail, they will attempt use three, otherwise if successful, the interaction ends.
Only some blocks have a specific effect for use with an item (1) or use without items (2), and only some items have use on blocks (3). If a block does not have a specific interaction for using an item on it (1), using an item on it will simply attempt to use the block without an item (2). For (2) and (3), if a block or item does not have a specific use, attempting to use it will fail.
The swing animation is only applied when there is some success (in any of the use).
Using a block without an item does not necessarily mean the player has no item in hand; instead it simply means using the block without considering the item. Similarly, it is possible to use an item on a block even when the hand is empty.Template:Note
in Template:Editions, when the first or third attempt is successful, the advancement trigger
- REDIRECT Template:Code
Template:Redr is activated, and if the second case is a success, trigger
- REDIRECT Template:Code
Template:Redr is activated. Subsequently, in any successful case, the
- REDIRECT Template:Code
Template:Redr trigger is activated.
Interactable blocks without items
Blocks with GUI
Blocks with GUI, show a menu that you can use to interact with it. These Interactions include Minecraft:crafting, smelting, storing, Minecraft:brewing, smithing, enchanting, and other functions.
Chests only open if there is no redstone conductor block above them or a cat sitting on top of themTemplate:Note, in the case of a double chest, the same condition is necessary for a connected chest. Shulker boxes only open if their opening (0.5 blocks towards the top) does not have any collision with the collision box of another block. Ender chests only open if there is no redstone conductor block above them.
These, and only these, blocks can be integrated in spectator mode, except for the blocked chests and ender chests.
Open a barrel, any chest (incluid ender chest), or a shulker box also anger nearby Minecraft:piglins. in Template:Editions, interacting with these blocks also increases the associated status, exect the crafting table and the enchanting table.
Blocks whose GUI depends on the Minecraft:block entity
- redirect Template:blockLink
- redirect Template:blockLink
- redirect Template:blockLink
- redirect Template:blockLink
- redirect Template:blockLink
- redirect Template:blockLink
- redirect Template:blockLink
- redirect Template:blockLink
- redirect Template:blockLink
- redirect Template:blockLink
- redirect Template:blockLink
- redirect Template:blockLink
- redirect Template:blockLink
- redirect Template:blockLink
- redirect Template:blockLink
- redirect Template:blockLink
Blocks whose GUI depends on the player
- redirect Template:blockLink
Other
- redirect Template:blockLink
- redirect Template:blockLink
- redirect Template:blockLink
- redirect Template:blockLink
- redirect Template:blockLink
- redirect Template:blockLink
- redirect Template:blockLink
Other
Interacting blocks without item that don't open a menu. Blocks like signs, command blocks, and structure blocks set a new screen, but these are not considered menus. Unlike menus, they are opened by the local player and not the server player
- REDIRECT Template:Info needed
- redirect Template:blockLink
- redirect Template:blockLink
- redirect Template:blockLink
- redirect Template:blockLink
- redirect Template:blockLink
- redirect Template:blockLink
- redirect Template:blockLink
- redirect Template:blockLink
- redirect Template:blockLink
- redirect Template:blockLink
- redirect Template:blockLink
- redirect Template:blockLink
Template:Redr (level
- REDIRECT Template:Code
- redirect Template:blockLink
- redirect Template:blockLink
- redirect Template:blockLink
- redirect Template:blockLink
- redirect Template:blockLink
- redirect Template:blockLink
- redirect Template:blockLink
- redirect Template:blockLink
- redirect Template:blockLink
- redirect Template:blockLink
Template:Redr⋯ All Potted Plants/Fungi
- redirect Template:blockLink
- redirect Template:blockLink
- redirect Template:blockLink
- redirect Template:blockLink
- redirect Template:blockLink
- redirect Template:blockLink
- redirect Template:blockLink
- redirect Template:blockLink
- redirect Template:blockLink
- redirect Template:blockLink
- redirect Template:blockLink
- redirect Template:blockLink
- redirect Template:blockLink
- redirect Template:blockLink
- redirect Template:blockLink
- redirect Template:blockLink
- redirect Template:blockLink
- redirect Template:blockLink
Template:RedrTrapdoors (except iron)
- redirect Template:blockLink
Template:Redr (practically neverTemplate:Note)
Interactable blocks with item
Blocks that can be interacted with while holding an item, and the behavior is defined by the block.
Some blocks use a certain item, it doesn't create a specific block behavior, but rather blocks or allows another interaction. For example, using the plant/fungi in a pot already prevents the plant/fungi from being removed from the pot, or uses a block in a redstone ore, could try placing it beyond the usual interaction (using other items, like a bucket of water, doesn't attempt use 3).
- redirect Template:blockLink
- redirect Template:blockLink
- redirect Template:blockLink
- redirect Template:blockLink
- redirect Template:blockLink
- redirect Template:blockLink
- redirect Template:blockLink
- redirect Template:blockLink
- redirect Template:blockLink
- redirect Template:blockLink
- redirect Template:blockLink
- redirect Template:blockLink
- redirect Template:blockLink
- redirect Template:blockLink
- redirect Template:blockLink
- redirect Template:blockLink
- redirect Template:blockLink
- redirect Template:blockLink
- redirect Template:blockLink
- redirect Template:blockLink
- redirect Template:blockLink
- redirect Template:blockLink
Template:Redr⋯ All Potted Plants/Fungi
- redirect Template:blockLink
- redirect Template:blockLink
- redirect Template:blockLink
- redirect Template:blockLink
- redirect Template:blockLink
- redirect Template:blockLink
- redirect Template:blockLink
- redirect Template:blockLink
- redirect Template:blockLink
- redirect Template:blockLink
- redirect Template:blockLink
- redirect Template:blockLink
- redirect Template:blockLink
- redirect Template:blockLink
Items that can be used in blocks
An item that can be interacted with blocks, and whose behavior is determined by the item.
Notes
Template:Article otherTemplate:Article other__DISAMBIG__
ko:상호작용할 수 있는 블록 pt:Blocos interativos