mirror of
https://github.com/zDevelopers/ImageOnMap.git
synced 2024-11-10 20:40:16 +01:00
Changed the images display in the GUI a little bit.
* NEW: The title of the tooltip of an image is now the name of this image (currently, “Map” everywhere). * NEW: moved the map ID in the tooltip.
This commit is contained in:
parent
bebac6e621
commit
cd9b310aa2
@ -30,13 +30,11 @@ import org.bukkit.inventory.meta.*;
|
||||
import java.util.*;
|
||||
|
||||
|
||||
public class MapListGui extends AbstractGui {
|
||||
|
||||
public class MapListGui extends AbstractGui
|
||||
{
|
||||
private final Integer MAPS_PER_PAGE = 7 * 3;
|
||||
|
||||
|
||||
private ImageMap.Type mapsType;
|
||||
|
||||
private List<ImageMap> maps = new ArrayList<>();
|
||||
|
||||
private int currentPage = 0;
|
||||
@ -231,11 +229,13 @@ public class MapListGui extends AbstractGui {
|
||||
|
||||
ItemMeta meta = icon.getItemMeta();
|
||||
|
||||
meta.setDisplayName(ChatColor.GREEN + "" + ChatColor.BOLD + map.getId().replace("-", " "));
|
||||
meta.setDisplayName(ChatColor.GREEN + "" + ChatColor.BOLD + map.getName());
|
||||
|
||||
meta.setLore(Arrays.asList(
|
||||
ChatColor.WHITE + "" + map.getMapCount() + " map" + (map.getMapCount() != 1 ? "s" : ""),
|
||||
"",
|
||||
ChatColor.GRAY + "Map ID: " + map.getId(),
|
||||
"",
|
||||
ChatColor.GRAY + "» Left-click to get this map",
|
||||
ChatColor.GRAY + "» Right-click for details"
|
||||
));
|
||||
|
Loading…
Reference in New Issue
Block a user