How to get the head of a certain player?

Discussion in 'Plugin Development' started by Gonmarte, Oct 4, 2015.

Thread Status:
Not open for further replies.
  1. Offline

    Gonmarte

    There is any method or any thing that allows me to get the head of a certain player like an item stack and i would be able to add it to a inventory?
    Thank you =)
     
  2. Offline

    Gonmarte

    @bwfcwalshy I need to be using the 1.8 bukkit?
    No i dont sorry xD im going to try and ill tell you if i have any issue

    @bwfcwalshy I cant add the skull to my inventory because its not a item stack. What should i do?
    Code:
    Player target = Bukkit.getServer().getPlayer(args[0]);
                      
                        Inventory inv = Bukkit.getServer().createInventory(null, 27, "");
                  
                        Skull skull =  (Skull) new org.bukkit.material.Skull();
                      
                            if(skull.getOwner()==target.getName()) {
                              //error
                                inv.addItem(skull);
                              
                            }
    
    
    <Edited by bwfcwalshy: Merged posts, please use the edit button rather than double posting.>
     
    Last edited by a moderator: Oct 4, 2015
Thread Status:
Not open for further replies.

Share This Page