Tame a pet to the player's real UUID, not an unset placeholder
acting_uuid() falls back to [0, 0, 0, 0] while level.player_uuid is unset (a new world before its first save); the owner saved then never matches the UUID the world gets, so the player could no longer command the pet after a reload. acting_player_uuid() assigns the world's player UUID first, as dropped items do. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
@@ -2739,7 +2739,7 @@ impl Game<'_> {
|
||||
.items()
|
||||
.get(&item)
|
||||
.is_some_and(|i| i.max_damage > 0);
|
||||
let acting = self.acting_uuid();
|
||||
let acting = self.acting_player_uuid();
|
||||
let m = &mut self.mobs[index];
|
||||
if !m.alive() {
|
||||
return Ok(false);
|
||||
|
||||
Reference in New Issue
Block a user