MarkusBordihn / BOs-Player-Companions

Player Companions adds additional NPC which will follow, protect or help you...
Other
3 stars 5 forks source link

change ownership of companion #10

Closed DentyTxR closed 2 years ago

DentyTxR commented 2 years ago

could be a nice feature, the reason im asking this is because I had my UUID changed and I no longer can control my companions, tried modifying data with NBT but I couldn't find anything related to the owners UUID

MarkusBordihn commented 2 years ago

Unfortunately that's not so easy as long the companion is still alive in the world, because the entity itself is also stored inside the world data which you should not modify.

The best way is to use an NBT editor to change the corresponding values. image

You need to change the following two entries inside the data/player_companions.dat file:

The UUID is encoded as an int-array. There are some converter which allows an easy conversion like: https://www.soltoder.com/mc-uuid-converter/

Just enter your new username and you will get the UUID in the right format under UUID: [I;.

It's important that you kill your companion (if it still in the world) and to end the game before modifying the data, to make sure that there are not any artifacts left with mismatching data.