#How to get player head?`
1 messages · Page 1 of 1 (latest)
<@&1201956957406109788>
💬 While you wait, take this time to provide more context and details.
🙇 If nobody has answered you by <t:1740246064:t>, feel free to use the Summon Helpers button to ping our helper team.
✅ Once your question has been resolved (or you no longer need it), please click Resolve Question or run /resolve
the entity exists and is summoned before hand.
It looks like you're doing only part of a loot table, you're missing what the item actually is, how many rolls, etc
execute if entity @a[team=P1] run summon armor_stand 8 -60 8 {Small:true,ShowArms:1b,Tags:[p1.controller]}
execute as @a[team=P1] run loot replace entity @e[tag=p1.controller] armor.head loot {"function": "minecraft:fill_player_head","entity": "this"}
item replace entity @e[tag=p1.controller] armor.body with leather_chestplate[dyed_color={rgb:17053}]
item replace entity @e[tag=p1.controller] armor.legs with leather_leggings[dyed_color={rgb:17053}]
item replace entity @e[tag=p1.controller] armor.feet with leather_boots[dyed_color={rgb:17053}]``` if you want to see full control
{
"type": "minecraft:command",
"pools": [
{
"rolls": 1,
"entries": [],
"functions": [
{
"function": "minecraft:fill_player_head",
"entity": "this"
}
]
}
]
}```
I had one but it did not work
Yeah you’re putting an inline item modifier in a place where a loot table should go
It's still missing an entry...
If it’s easier you can just /item replace a player head in the slot beforehand and then run the item modifier you already have
this should be in datapack wiki
Maybe it should
what should i set the entries to?
Use https://misode.github.io generate this, and it’ll be a lot easier
Just have one entry for a player head item
The entries define what the output item should be, and the functions will then do stuff to the output item before it gets outputted
"type": "minecraft:command",
"pools": [
{
"rolls": 0,
"entries": [
{
"type": "minecraft:loot_table",
"value": "minecraft:blocks/player_head",
"functions": []
}
],
"functions": [
{
"function": "minecraft:fill_player_head",
"entity": "this"
}
]
}
]
}```
so this looks fine?
"type": "minecraft:command",
"pools": [
{
"rolls": 0,
"entries": [
{
"type": "minecraft:item",
"name": "minecraft:player_head",
"functions": []
}
],
"functions": [
{
"function": "minecraft:fill_player_head",
"entity": "this"
}
]
}
]
}``` okay solved it
That looks more correct yeah