@Deprecated public static String getPlayerSkullURL(String playerName) { return SkinUtils.getOnlineSkinURL(playerName); }
public static String getOnlineSkinURL(String playerName) { Player player = DeprecatedUtils.getPlayerExact(playerName); String url = null; if (player != null) { url = getOnlineSkinURL(player); } return url; }
public RegisterTask(Plugin plugin, Player player, String code) { logger = plugin.getLogger(); File dataFolder = new File(plugin.getDataFolder(), "data"); registerFile = new File(dataFolder, "registered.yml"); playerId = player.getUniqueId().toString(); playerName = player.getName(); skinURL = SkinUtils.getOnlineSkinURL(playerName); this.code = code; }
@Nullable protected Waypoint getFriend(String uuid) { Player onlinePlayer = Bukkit.getPlayer(UUID.fromString(uuid)); if (onlinePlayer == null) return null; String playerName = onlinePlayer.getDisplayName(); String castMessage = context.getMessage("cast_friend").replace("$name", playerName); String failMessage = context.getMessage("no_target_friend").replace("$name", playerName); String title = context.getMessage("title_friend", "$name").replace("$name", playerName); String iconURL = SkinUtils.getOnlineSkinURL(onlinePlayer); return new Waypoint(RecallType.WARP, onlinePlayer.getLocation(), title, castMessage, failMessage, "", null, iconURL); }
/** * Get an ItemStack that is a headshot of a player's skin. */ @Nullable @Override public ItemStack getPlayerPortrait(String worldName, String playerName, Integer priority, String photoLabel) { photoLabel = photoLabel == null ? playerName : photoLabel; String url = SkinUtils.getOnlineSkinURL(playerName); if (url != null) { MapView mapView = getURL(worldName, url, photoLabel, 8, 8, 40, 8, 8, 8, priority, playerName); return getMapItem(photoLabel, mapView); } MapView mapView = getURL(worldName, null, photoLabel, 8, 8, 40, 8, 8, 8, priority, playerName); return getMapItem(photoLabel, mapView); }