Kikisito / GoldenHeads

A configurable GoldenHeads plugin made for the latest Minecraft versions.
GNU General Public License v3.0
0 stars 1 forks source link

Deprecation of getOfflinePlayer making golden heads not have skin #14

Closed Arcaneist closed 2 months ago

Arcaneist commented 3 months ago

The skin of the golden head is not working correctly on 1.21

Arcaneist commented 3 months ago

20240825_171956

Reddishye commented 2 months ago

I'll check, will probably be something related with components

Reddishye commented 2 months ago

Issue confirmed.

Reddishye commented 2 months ago

image

Reddishye commented 2 months ago

Suspected issue: Deprecation of method getOfflinePlayer.

        // Set owner
        if(goldenhead.getType() == Material.PLAYER_HEAD){
            if(player.isPresent()){
                ((SkullMeta) itemMeta).setOwningPlayer(player.get());
            } else {
                ((SkullMeta) itemMeta).setOwningPlayer(Bukkit.getOfflinePlayer(config.goldenHeads.getSkullOwner()));
            }
        }
Reddishye commented 2 months ago

Done, this issue will close as soon as #15 gets accepted by @Kikisito