Skip to content

Commit

Permalink
xskull methods update
Browse files Browse the repository at this point in the history
  • Loading branch information
kiranhart committed Jun 13, 2024
1 parent fd32390 commit 13f0f2e
Showing 1 changed file with 5 additions and 9 deletions.
14 changes: 5 additions & 9 deletions src/main/java/ca/tweetzy/flight/utils/QuickItem.java
Original file line number Diff line number Diff line change
Expand Up @@ -36,12 +36,7 @@
import org.bukkit.inventory.meta.SkullMeta;
import org.bukkit.material.MaterialData;

import java.util.ArrayList;
import java.util.Arrays;
import java.util.Base64;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
import java.util.*;

/**
* Date Created: April 07 2022
Expand Down Expand Up @@ -426,8 +421,7 @@ public static QuickItem of(final OfflinePlayer player) {

assert meta != null;

XSkull.applySkin(meta, player);

XSkull.of(meta).profile(player).apply();
itemStack.setItemMeta(meta);

return of(itemStack);
Expand All @@ -439,8 +433,10 @@ public static ItemStack createTexturedHead(String url) {
return CompMaterial.STONE.parseItem();

SkullMeta sm = (SkullMeta) item.getItemMeta();
assert sm != null;

XSkull.applySkin(sm, encodeURL(url));
XSkull.of(sm).profile(XSkull.SkullInputType.TEXTURE_URL, url);
// XSkull.applySkin(sm, encodeURL(url));
item.setItemMeta(sm);

return item;
Expand Down

0 comments on commit 13f0f2e

Please sign in to comment.