Skip to content

Commit

Permalink
Fix build (again)
Browse files Browse the repository at this point in the history
  • Loading branch information
IMS212 committed Jun 29, 2024
1 parent e7f2150 commit e71b44a
Showing 1 changed file with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,8 @@ public class MixinEntityRenderer<T extends Entity> {
@Unique
private int lastId = -100;

@Inject(method = "renderNameTag", at = @At(value = "INVOKE", target = "Lnet/minecraft/world/entity/Entity;getNameTagOffsetY()F"))
private void setNameTagId(T entity, Component component, PoseStack poseStack, MultiBufferSource multiBufferSource, int i, CallbackInfo ci) {
@Inject(method = "renderNameTag", at = @At(value = "INVOKE", target = "Lnet/minecraft/world/entity/Entity;getViewYRot(F)F"))
private void setNameTagId(T entity, Component component, PoseStack poseStack, MultiBufferSource multiBufferSource, int i, float f, CallbackInfo ci) {
Object2IntFunction<NamespacedId> entityIds = WorldRenderingSettings.INSTANCE.getEntityIds();

if (entityIds == null) {
Expand All @@ -39,7 +39,7 @@ private void setNameTagId(T entity, Component component, PoseStack poseStack, Mu
}

@Inject(method = "renderNameTag", at = @At("RETURN"))
private void resetId(T entity, Component component, PoseStack poseStack, MultiBufferSource multiBufferSource, int i, CallbackInfo ci) {
private void resetId(T entity, Component component, PoseStack poseStack, MultiBufferSource multiBufferSource, int i, float f, CallbackInfo ci) {
if (lastId != -100) {
CapturedRenderingState.INSTANCE.setCurrentEntity(lastId);
lastId = -100 ;
Expand Down

0 comments on commit e71b44a

Please sign in to comment.