Making Fireworks explode instantly

Discussion in 'Plugin Development' started by MineCrypt, Mar 29, 2013.

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

    MineCrypt

    Alright Im trying to make it so I can spawn a firework and it will explode right as it spawns. I want it to look like it explodes right at the feet, so heres my code, if anyone can help me it would really help Thanks!

    Code:
    Firework fw = player.getWorld().spawn(player.getLocation(), Firework.class);
                            FireworkMeta fwm = fw.getFireworkMeta();
                                   
                            FireworkEffect effect = FireworkEffect.builder().withColor(Color.BLUE.mixColors(Color.YELLOW.mixColors(Color.GREEN))).with(Type.BALL_LARGE).withFade(Color.RED).build();       
                               
                            fwm.addEffects(effect);   
                            fw.setFireworkMeta(fwm);
     
  2. Offline

    c0mp

    Moved to Plugin Development
     
  3. Offline

    chasechocolate

  4. Offline

    NerdsWBNerds

    http://forums.bukkit.org/threads/in...ible-rocket-just-the-explosion-effect.269919/
     
Thread Status:
Not open for further replies.

Share This Page