I'm trying to programmatically "un-tame" a cat using the `data set` command. According to an Arqade answer, you just have to remove the `OwnerUUID` property of the animal NBT data. I tried the following commands with no success:
/data modify entity 71cfdc75-9cfa-4989-be66-3f481ed9baa7 OwnerUUID set value ""
/data remove entity 71cfdc75-9cfa-4989-be66-3f481ed9baa7 OwnerUUID
In both cases, the command seems successful, with a message saying the entity was modified. But there was no observable change and the target animal remains associated with the same OwnerUUID.
I did some testing and the game always reverts the value of the OwnerUUID NBT tag to its original value. I also noticed that if you set the value to something random such as "text", the game will revert the value back to the UUID of the player again but the cat won't have a collar anymore, you can't control it and it will follow you around like it is tamed. Maybe there's another tag that has to be reset in order for this to work or maybe it's not even possible because the UUID is stored in memory or something.
I'm trying to programmatically "un-tame" a cat using the `data set` command. According to an Arqade answer, you just have to remove the `OwnerUUID` property of the animal NBT data. I tried the following commands with no success:
In both cases, the command seems successful, with a message saying the entity was modified. But there was no observable change and the target animal remains associated with the same OwnerUUID.
Any suggestion to untame an animal in MC15.2?
Please, support the sledgehammer tool!
I ♥ Linux. Thanks Mojang for providing a game that runs natively on that OS!
I did some testing and the game always reverts the value of the OwnerUUID NBT tag to its original value. I also noticed that if you set the value to something random such as "text", the game will revert the value back to the UUID of the player again but the cat won't have a collar anymore, you can't control it and it will follow you around like it is tamed. Maybe there's another tag that has to be reset in order for this to work or maybe it's not even possible because the UUID is stored in memory or something.
Command block engineer // Developer // #TeamTrees
Thanks for the reply Megacrafter.
I've made some similar experiments since my initial post, with the same conclusions, unfortunately :/
Please, support the sledgehammer tool!
I ♥ Linux. Thanks Mojang for providing a game that runs natively on that OS!
/data merge entity (entity) {CustomName:"\"NAME\""}
Indeed it changes the animal custom name, but it's still tamed by the same user. Or did I miss something?
https://minecraft.fandom.com/wiki/Taming
Please, support the sledgehammer tool!
I ♥ Linux. Thanks Mojang for providing a game that runs natively on that OS!
you can just kill this animal and spawn second