Holograms don't hide
DevSchmidtchen opened this issue · 5 comments
Hej
I use this code:
`Hologram hologram = HologramsAPI.createHologram(plugin, plugin.getLocation("HOLOGRAM"));
VisibilityManager visibilityManager = hologram.getVisibilityManager();
visibilityManager.showTo(p);
visibilityManager.setVisibleByDefault(false);
ItemStack is = new ItemStack(Material.SKULL_ITEM, 1, (short)3);
SkullMeta sm = (SkullMeta) is.getItemMeta();
sm.setOwner(p.getName());
is.setItemMeta(sm);
hologram.appendItemLine(is);
hologram.appendTextLine("§7» §6§lStats §7«");
hologram.appendTextLine("§7↠ §9gespielte Spiele: §c" + plugin.getMySQLStats().getPlayed(p.getUniqueId().toString()));
hologram.appendTextLine("§7↠ §9gewonnene Spiele: §c" + plugin.getMySQLStats().getWins(p.getUniqueId().toString()));
hologram.appendTextLine("§7↠ §9deaktivierte Energiekerne: §c" + plugin.getMySQLStats().getDisabled(p.getUniqueId().toString()));
hologram.appendTextLine("§7↠ §9Kills: §c" + plugin.getMySQLStats().getKills(p.getUniqueId().toString()));
hologram.appendTextLine("§7↠ §9Tode: §c" + plugin.getMySQLStats().getDeaths(p.getUniqueId().toString()));
hologram.appendTextLine("§7↠ §9Punkte: §c" + plugin.getMySQLStats().getPoints(p.getUniqueId().toString()));
`
If a new player joins, both players see both holograms. But when I used isVisibleTo it says they can only see one of them!
Version: 1.10
Sorry for my bad English, I am from Germany!