diff --git a/mod-shared/src/mixin/java/net/kyori/adventure/platform/modcommon/impl/mixin/minecraft/world/entity/player/PlayerMixin.java b/mod-shared/src/mixin/java/net/kyori/adventure/platform/modcommon/impl/mixin/minecraft/world/entity/player/PlayerMixin.java index a8d343dd..c6a4b29d 100644 --- a/mod-shared/src/mixin/java/net/kyori/adventure/platform/modcommon/impl/mixin/minecraft/world/entity/player/PlayerMixin.java +++ b/mod-shared/src/mixin/java/net/kyori/adventure/platform/modcommon/impl/mixin/minecraft/world/entity/player/PlayerMixin.java @@ -71,8 +71,7 @@ protected PlayerMixin(final EntityType entityType, final final Pointers.Builder builder = Pointers.builder() .withDynamic(Identity.NAME, () -> this.shadow$getGameProfile().getName()) .withDynamic(Identity.UUID, this::getUUID) - // Hope this isn't a registry-aware component :) - .withDynamic(Identity.DISPLAY_NAME, () -> NonWrappingComponentSerializer.INSTANCE.deserialize(this.getDisplayName())); + .withDynamic(Identity.DISPLAY_NAME, () -> new NonWrappingComponentSerializer(this.level()::registryAccess).deserialize(this.getDisplayName())); // add any extra data if (this instanceof Pointered p) {