TransWikia.com

Is there a way to run a command if a player is holding a specific players head?

Arqade Asked on July 24, 2021

I’m trying to make a datapack that makes player heads drop on kills that give you abilities if you use them. Right now I’m trying to make a line where if you right-click the specific player head then it will continue the rest of the function and I’m starting out by making sure that you’re holding the specific head and so far I have this:

execute at @a[nbt={SelectedItem:{id:"minecraft:player_head{SkullOwner:{Name:shaeno}}"}}] run say hi

and I’ve also tried this:

execute at @a[nbt={SelectedItem:{id:"minecraft:player_head{SkullOwner:Wumpter}"}}] run say hi

but neither seem to work. Any suggestions?

Add your own answers!

Ask a Question

Get help from others!

© 2024 TransWikia.com. All rights reserved. Sites we Love: PCI Database, UKBizDB, Menu Kuliner, Sharing RPP