How To Make Clickable Displays (Right Click Detection) in Minecraft

Channel:
Subscribers:
4,670
Published on ● Video Link: https://www.youtube.com/watch?v=Bo7_WaW6g2I



Minecraft
Game:
Minecraft (2011)
Category:
Tutorial
Duration: 8:52
419 views
24


It's like a button that can look like anything you want (item, block, text) and can trigger anything you want. Definitely a valuable tool for any mapmaker, and I'll be showing you how to easily create this wonderful clickable display.

00:06 Step 1: The Display
- Item: /execute summon minecraft:item_display run data merge entity @s {brightness:{sky:15,block:15},transformation:{scale:[0.2,0.2,0.2]},item:{id:"purple_concrete",Count:1},billboard:"center",Tags:[your_tag]}
- or Block (delete align xyz if you don't want it to snap to grid: /execute align xyz summon minecraft:block_display run data merge entity @s {brightness:{sky:15,block:15},transformation:{scale:[1.0,1.0,1.0]},block_state:{Name:"purple_concrete"},billboard:"fixed",Tags:[your_tag]}
- or Text: /execute summon minecraft:text_display run data merge entity @s {brightness:{sky:15,block:15},transformation:{scale:[1.0,1.0,1.0]},text:'"purple_concrete"',billboard:"center",Tags:[your_tag]}

- Advanced Display Options: https://minecraft.wiki/w/Display#Entity_data

03:14 Step 2: Right Click Detection
- Change item_display to be block_display or text_display respectively.
- Interaction Entity: /execute as @e[type=minecraft:item_display,sort=nearest,limit=1] at @s positioned ~ ~ ~ summon interaction run data merge entity @s {width:0.2,height:0.2,response:1,Tags:[your_tag]}

- Note: Each display entity has a DIFFERENT origin point and therefore you will have to adjust the positioned parameter a little differently for each one (block displays need half added in the x and y and text displays need nothing). If you need to delete and try again use this command: /kill @e[type=interaction,sort=nearest,limit=1]

05:29 Step 3: Advancement Trigger
- Template Datapack: https://www.planetminecraft.com/data-pack/basic-template-6096089/
- Compact Advancement: {"criteria": {"example": {"trigger": "minecraft:player_interacted_with_entity","conditions": {"entity": {"type": "minecraft:interaction","nbt": "{Tags:[\"your_tag\"]}"}}}},"rewards": {"function": "template:example"}}

- Note: If you change the file names or the namespace, don't forget to update template:example with the new namespace:file_name.

6:22 Step 4: The Output Code
- "Reset Button": advancement revoke @s only template:example

- Advanced Technique: You can use @e[type=interaction,nbt={interaction:{}},sort=nearest,limit=1] to track closest interacted entity from the player's position (who triggered the advancement). And then at the end of the file you can clean it up with /data remove entity @e[type=interaction,nbt={interaction:{}},sort=nearest,limit=1] interaction. This is useful if you have a lot of clickable displays next to each other and you need to only trigger one. And don't forget you can use tag=your_tag to track specific interaction entities if you need to narrow it down further.


My Main Let's Play:
Talon's Oasis Season 3: https://www.youtube.com/playlist?list=PLlBKpA-F_inGo3_j1lEuEIOWYGd5wZkJf
Original (Old) Talon's Oasis: https://www.youtube.com/playlist?list=PLlBKpA-F_inEvT1CF9srKkl9R4Ecs7ueL

Ending Music:
"Pamgaea" Kevin MacLeod (incompetech.com)
Licensed under Creative Commons: By Attribution 3.0
http://creativecommons.org/licenses/by/3.0/

Not an official Minecraft product. Not approved by or associated with Mojang.

Chapters:
00:00 Step 1: The Display
03:14 Step 2: Right Click Detection
05:29 Step 3: Advancement Trigger
06:22 Step 4: The Output Code
07:17 Finished Product


#CommandBlockTutorial #MinecraftHowTo #Talon2863




Other Videos By Talon


2024-01-05A Noob Tries Blitz Survival (Hypixel PvP)
2023-12-29Trying Out /Return - Talon's Oasis - Ep 118
2023-12-23Exploring New Jigsaw Changes in 1.20.3 - Talon's Oasis - Ep 117
2023-12-14Is the Primo(Rocket Pass Season 13) Better Than the Skyline?
2023-12-07Is the Ace (Rocket Pass Season 13) Better Than the Breakout?
2023-12-01Would a Command Block Say I'm Inside or Outside? - Talon's Oasis - Ep 116
2023-11-23The Challenge of Building an EXPOSED Coral Structure - Talon's Oasis - Ep 115
2023-11-17I Try Making A Sniffer Farm - Talon's Oasis - Ep 114
2023-11-08Is Lightning McQueen Better Than The Dominus?
2023-10-27The Item Every Minecraft World Needs - Talon's Oasis - Ep 113
2023-10-20How To Make Clickable Displays (Right Click Detection) in Minecraft
2023-10-13Playing My Original Main Car - Rocket League Doubles (2v2)
2023-10-06Turning Blocks Into Holograms - Talon's Oasis - Ep 112
2023-09-29The Simplest Way To Make Minecraft More Difficult - Talon's Oasis - Ep 111
2023-09-22Making Macros for Fun - Talon's Oasis - Ep 110
2023-09-15Improve Possession or No Rewards - Solo Queue Standard Tournament (3v3)
2023-09-06Is the Porsche 911 Turbo Better Than the Dominus? (Showcase and Review)
2023-08-25Making The Structure Block Swapper Automatic - Talon's Oasis - Ep 109
2023-08-19Some Randomizer Fun in Ranked - Rocket League Doubles (2v2)
2023-08-112nd Floor At the Mushroom Resort - Talon's Oasis - Ep 108
2023-08-04Explaining my Thought Process Behind Being a Better Teammate - Rocket League Doubles (2v2)



Tags:
talon
talon2863
minecraft command blocks
minecraft right click detection
minecraft click on display entities
minecraft interaction display
minecraft floating item that can be clicked
minecraft click on text to trigger commands
minecraft how to make right click detection
minecraft how to make a clickable item display
minecraft how to click on interaction entity
minecraft how to make clickable floating displays



Other Statistics

Minecraft Statistics For Talon

Talon presently has 461,370 views for Minecraft across 180 videos, with the game making up over 3 days of published video on his channel. This is 61.38% of the total watchable video for Minecraft on Talon's YouTube channel.