How can I make a wolf tamed by an arbitrary player using command blocks?

How can I make a wolf tamed by an arbitrary player using command blocks? - Content female customer with long curly hair wearing casual outfit sitting at wooden table with netbook in classic interior restaurant while making online order

In a map I'm making, I have a shop where players can buy rewards for collecting points (things like upgraded stats, items, etc.). One thing I'd like to have is a pet shop, where the player can buy a dog, cat, horse, or skeleton horse. When they buy one, it should become tamed by the player who bought it. There's a data tag on these mobs called OwnerUUID, which must be set to the owner's UUID to make this work...so how can I set it to a player's UUID when anyone could be playing the map, and any player could buy an animal? In other words, how do I calculate the player's UUID and set a data tag to it if their username/account is unknown? If there's no way to do this, how can I make an animal tamed another way with command blocks?



Best Answer

I don't know why so many players say this isn't possible. In fact, it is simple!

Just enter this command into a command block:

/summon Wolf ~ ~1 ~ {Owner:Notch}

Of course, the name Notch could be replaced with the player's name that you wanted to have it tamed to. @p does not work! (The command will generate a tamed wolf one block above the command block, tamed to the person of your liking.)




Pictures about "How can I make a wolf tamed by an arbitrary player using command blocks?"

How can I make a wolf tamed by an arbitrary player using command blocks? - Crop hacker silhouette typing on computer keyboard while hacking system
How can I make a wolf tamed by an arbitrary player using command blocks? - Focused ethnic female DJ playing music at nightclub
How can I make a wolf tamed by an arbitrary player using command blocks? - Woman playing piano at free time



How do you summon a tamed wolf with command blocks?

The syntax to summon a tamed wolf is "/summon wolf [pos] {Owner: <PlayerName>}" and for a tamed cat is "/summon cat [pos] {Owner:<PlayerName>}".

What is the command to turn into a wolf in Minecraft?

put a lever on a command block and make it on repeat then type without the quotation marks- "tp @e[type=wolf] @p" then put a repeater next to that command block and but another command block on the powering side of the repeater, leave the 2nd command block on impulse then type(without quotation marks)- "effect @p ...



3 Deadly Command Blocks (Minecraft PE)




More answers regarding how can I make a wolf tamed by an arbitrary player using command blocks?

Answer 2

Summon a willed wolf with a command block then have the same circuit that activated the first command block to activate another command block which will give the player some bones.

Sorry for not getting the exact answer you wanted, but this will still work because this way you don't need to know the players name and they still get their pet wolf.

example

command block one          command block two
/summon wolf ~ ~1 ~         /give @p bone 15

Sources: Stack Exchange - This article follows the attribution requirements of Stack Exchange and is licensed under CC BY-SA 3.0.

Images: Yan Krukov, Anete Lusina, Fardad Postwala, Charles Parker