Blue Wither Skulls

Discussion in 'Plugin Development' started by luc99a, May 10, 2014.

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

    luc99a

    Hi, I was wondering if exists a way to spawn a blue wither skull entity by player.launchProjectile().
    I searched on the documentations, but I haven't found anything.
     
  2. luc99a Sorry for the wait, it took me a while to research and debug this:
    Code:
    ((WitherSkull) player.launchProjectile(WitherSkull.class)).setCharged(true);
    You need to have a 'recent' build of Bukkit, I had to get 1.7.5 to use the 'setCharged' method.
     
  3. Offline

    luc99a

    Thank you it works. I wrote the code on two lines anyway:

    Code:java
    1. WitherSkull ws = (WitherSkull)p.launchProjectile(WitherSkull.class);
    2. ws.setCharged(true);
     
  4. Offline

    Videogamer555

    I'm curious. In vanilla Minecraft, how is the WitherSkull's charge state stored? I assume it's in a DataTag (like the Creeper's charged state). But what is the name of the DataTag variable that holds its charged state info? I'm curious, because I don't have Bukkit, and am hoping that some of the Bukkit devs will be able to help me here. I plan on creating a charged WitherSkull using the "/summon" command.
     
  5. Offline

    teej107

    Videogamer555 Bukkit isn't Vanilla. But I would assume the charge tag for creeper is the same for a wither skull.
     
  6. Offline

    Videogamer555

    It's not. I've already tried that, and it doesn't work. It doesn't blow up Obsidian (which is the best test to see if a Wither Skull is the charged version).
     
Thread Status:
Not open for further replies.

Share This Page