mirror of
https://github.com/filoghost/HolographicDisplays.git
synced 2024-11-22 10:25:41 +01:00
Updated Power Ups (markdown)
parent
40f965b9ee
commit
61d2e07655
@ -10,7 +10,9 @@ A power up is very simple, is made of a floating item (the icon) and a hologram.
|
||||
``` java
|
||||
String text = ChatColor.GOLD + "" + ChatColor.BOLD + "Fire Resistance"
|
||||
Location where = ... // Suppose you have a random location in your minigame
|
||||
FloatingItem floatingItem = HolographicDisplaysAPI.createFloatingItem(this, where.add(0.0, 0.2, 0.0), new ItemStack(Material.BLAZE_POWDER));
|
||||
|
||||
ItemStack powder = new ItemStack(Material.BLAZE_POWDER);
|
||||
FloatingItem floatingItem = HolographicDisplaysAPI.createFloatingItem(this, where.add(0.0, 0.2, 0.0), powder);
|
||||
final Hologram hologram = HolographicDisplaysAPI.createHologram(this, where.add(0.0, 0.6, 0.0), text);
|
||||
|
||||
floatingItem.setPickupHandler(new PickupHandler() {
|
||||
|
Loading…
Reference in New Issue
Block a user