From 13d97af5bfb4498de5f9bef5880c5aecb53cae82 Mon Sep 17 00:00:00 2001 From: "yrsegal@gmail.com" Date: Wed, 15 Jun 2022 16:54:09 -0400 Subject: [PATCH] fix looking at an old cleric impetus with a lens crashing --- .../common/blocks/entity/BlockEntityStoredPlayerImpetus.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Common/src/main/java/at/petrak/hexcasting/common/blocks/entity/BlockEntityStoredPlayerImpetus.java b/Common/src/main/java/at/petrak/hexcasting/common/blocks/entity/BlockEntityStoredPlayerImpetus.java index 05a41e97..076f4ffe 100644 --- a/Common/src/main/java/at/petrak/hexcasting/common/blocks/entity/BlockEntityStoredPlayerImpetus.java +++ b/Common/src/main/java/at/petrak/hexcasting/common/blocks/entity/BlockEntityStoredPlayerImpetus.java @@ -85,9 +85,9 @@ public class BlockEntityStoredPlayerImpetus extends BlockEntityAbstractImpetus { var name = this.getPlayerName(); if (name != null) { var head = new ItemStack(Items.PLAYER_HEAD); - NBTHelper.put(head, "SkullOwner", NbtUtils.writeGameProfile(new CompoundTag(), storedPlayerProfile)); + NBTHelper.put(head, "SkullOwner", NbtUtils.writeGameProfile(new CompoundTag(), name)); lines.add( - new Pair<>(head, new TranslatableComponent("hexcasting.tooltip.lens.impetus.storedplayer", name))); + new Pair<>(head, new TranslatableComponent("hexcasting.tooltip.lens.impetus.storedplayer", name.getName()))); } else { lines.add(new Pair<>(new ItemStack(Items.BARRIER), new TranslatableComponent("hexcasting.tooltip.lens.impetus.storedplayer.none")));