Skip to content

Commit

Permalink
Add some interaction debug for holograms
Browse files Browse the repository at this point in the history
  • Loading branch information
fullwall committed Apr 15, 2024
1 parent b0ba7b2 commit ccce76d
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion main/src/main/java/net/citizensnpcs/trait/HologramTrait.java
Expand Up @@ -468,6 +468,7 @@ protected NPC createNPC(Entity base, String name, Vector3d offset) {
public void onSeenByPlayer(Player player) {
if (lastOffset == null)
return;
Messaging.debug("Linking", player, hologram.getEntity());
NMS.linkTextInteraction(player, hologram.getEntity(), npc.getEntity(), lastOffset.y);
}

Expand Down Expand Up @@ -658,7 +659,7 @@ public void render0(NPC base, Vector3d offset) {
TextDisplay disp = (TextDisplay) hologram.getEntity();
disp.setBillboard(Billboard.CENTER);
Transformation tf = disp.getTransformation();
tf.getTranslation().y = (float) offset.y + 0.1f;
tf.getTranslation().y = (float) offset.y + 0.2f;
disp.setTransformation(tf);
if (hologram.getEntity().getVehicle() == null) {
base.getEntity().addPassenger(hologram.getEntity());
Expand Down

0 comments on commit ccce76d

Please sign in to comment.